From 1dccce439691061d0e2c49d96e1b5da327cd2162 Mon Sep 17 00:00:00 2001 From: miladsoft Date: Wed, 27 Nov 2024 18:34:02 +0000 Subject: [PATCH] Auto-generated commit Triggered by commit: https://github.com/block-core/angor-hub/commit/938a60b9943789809d821034b4b06f02f04fbdbd --- 394.513ca13c1ebf9f48.js | 1 - 394.76c49ed2cbb10995.js | 1 + 404.html | 2 +- 512.21e2f0687bbf0a15.js | 1 - 512.5c8e193aa51cd3ec.js | 1 + 544.8d04d0914a5c873b.js => 544.eda92231287fa498.js | 2 +- index.html | 2 +- main.9a08e516e999a8fa.js | 1 + main.bb8bd8bc84452c78.js | 1 - ngsw.json | 2 +- runtime.4b8589ab227394d2.js => runtime.20d23fb106aeceea.js | 2 +- 11 files changed, 8 insertions(+), 8 deletions(-) delete mode 100644 394.513ca13c1ebf9f48.js create mode 100644 394.76c49ed2cbb10995.js delete mode 100644 512.21e2f0687bbf0a15.js create mode 100644 512.5c8e193aa51cd3ec.js rename 544.8d04d0914a5c873b.js => 544.eda92231287fa498.js (54%) create mode 100644 main.9a08e516e999a8fa.js delete mode 100644 main.bb8bd8bc84452c78.js rename runtime.4b8589ab227394d2.js => runtime.20d23fb106aeceea.js (55%) diff --git a/394.513ca13c1ebf9f48.js b/394.513ca13c1ebf9f48.js deleted file mode 100644 index c2b4877..0000000 --- a/394.513ca13c1ebf9f48.js +++ /dev/null @@ -1 +0,0 @@ -"use strict";(self.webpackChunkangor=self.webpackChunkangor||[]).push([[394],{5394:(Ue,h,r)=>{r.r(h),r.d(h,{default:()=>ve});var c=r(3014),y=r(7785),v=r(708),m=r(4460),j=r(936),d=r(9471),b=r(7702),k=r(6071),x=r(3904),_=r(6389),p=r(7818),P=r(1054),I=r(1371),U=r(7712),f=r(8716),F=r(1556),E=r(9363),R=r(8447),G=r(2835),$=r(5785),C=r(1211),S=r(5727),e=r(3107),w=r(8078),Y=r(3149),T=r(6388),B=r(7859),M=r(7544),X=r(1109),A=r(7153),N=r(5616),V=r(5506),L=r(4160),D=r(9207),z=r(7112);const K=["eventInput"],Z=["commentInput"],O=()=>["hex","npub"],W=(i,a)=>({height:i,overflow:a}),J=(i,a)=>({"white-space":i,"max-height":a,overflow:"hidden"}),H=i=>({"large-font":i});function Q(i,a){if(1&i&&(e.qex(0),e.nrm(1,"img",33),e.bVm()),2&i){const t=e.XpG();e.R7$(),e.FS9("alt",(null==t.profileUser?null:t.profileUser.display_name)||(null==t.profileUser?null:t.profileUser.name)||""),e.Y8G("src",t.getSafeUrl(null==t.profileUser?null:t.profileUser.picture),e.B4B)}}function q(i,a){if(1&i&&e.nrm(0,"img",34),2&i){const t=e.XpG();e.FS9("alt",(null==t.profileUser?null:t.profileUser.display_name)||(null==t.profileUser?null:t.profileUser.name)||"")}}function ee(i,a){if(1&i){const t=e.RV6();e.j41(0,"button",35),e.bIt("click",function(){e.eBV(t);const o=e.XpG();return e.Njj(o.openZapDialog())}),e.j41(1,"span",36),e.nrm(2,"mat-icon",37),e.j41(3,"span"),e.EFF(4),e.k0s()()()}if(2&i){const t=e.XpG();e.R7$(2),e.Y8G("svgIcon",t.isCurrentUserProfile?"heroicons_outline:qr-code":"feather:zap"),e.R7$(2),e.JRh(t.isCurrentUserProfile?"Receive Zap":"Send Zap")}}function te(i,a){if(1&i){const t=e.RV6();e.qex(0),e.j41(1,"button",35),e.bIt("click",function(){const o=e.eBV(t).$implicit,s=e.XpG();return e.Njj(s.copyKey(o))}),e.j41(2,"span",36),e.nrm(3,"mat-icon",37),e.j41(4,"span"),e.EFF(5),e.k0s()()(),e.bVm()}if(2&i){const t=a.$implicit;e.R7$(3),e.Y8G("svgIcon","heroicons_outline:clipboard-document"),e.R7$(2),e.SpI("Copy Public key (",t,")")}}function oe(i,a){1&i&&(e.j41(0,"button",38)(1,"span",36),e.nrm(2,"mat-icon",37),e.j41(3,"span"),e.EFF(4,"Edit your profile"),e.k0s()()()),2&i&&(e.Y8G("routerLink","/settings/profile"),e.R7$(2),e.Y8G("svgIcon","heroicons_outline:pencil-square"))}function ne(i,a){1&i&&(e.qex(0),e.j41(1,"button",39)(2,"span",36),e.nrm(3,"mat-icon",37),e.j41(4,"span"),e.EFF(5,"Report"),e.k0s()()(),e.j41(6,"button",39)(7,"span",36),e.nrm(8,"mat-icon",37),e.j41(9,"span"),e.EFF(10,"Turn on notifications"),e.k0s()()(),e.bVm()),2&i&&(e.R7$(3),e.Y8G("svgIcon","heroicons_solid:exclamation-triangle"),e.R7$(5),e.Y8G("svgIcon","heroicons_solid:bell"))}function ie(i,a){1&i&&(e.j41(0,"span",47),e.EFF(1,"..."),e.k0s())}function re(i,a){if(1&i){const t=e.RV6();e.j41(0,"angor-card",40)(1,"div",41)(2,"div",42),e.EFF(3," About "),e.k0s(),e.j41(4,"button",43),e.bIt("click",function(){e.eBV(t);const o=e.XpG();return e.Njj(o.toggleAbout())}),e.nrm(5,"mat-icon",44),e.k0s()(),e.j41(6,"div",45),e.EFF(7),e.DNE(8,ie,2,0,"span",46),e.k0s()()}if(2&i){const t=e.XpG();e.Y8G("ngStyle",e.l_i(5,W,t.aboutExpanded?"auto":"80px",t.aboutExpanded?"visible":"hidden")),e.R7$(5),e.Y8G("svgIcon",t.aboutExpanded?"heroicons_outline:chevron-up":"heroicons_outline:chevron-down"),e.R7$(),e.Y8G("ngStyle",e.l_i(8,J,t.aboutExpanded?"normal":"nowrap",t.aboutExpanded?"none":"1.5em")),e.R7$(),e.SpI(" ",(null==t.profileUser?null:t.profileUser.about)||""," "),e.R7$(),e.Y8G("ngIf",!t.aboutExpanded)}}function se(i,a){if(1&i){const t=e.RV6();e.j41(0,"div",63)(1,"emoji-mart",64),e.bIt("emojiClick",function(o){e.eBV(t);const s=e.XpG(2);return e.Njj(s.addEmoji(o))}),e.k0s()()}if(2&i){const t=e.XpG(2);e.R7$(),e.Y8G("darkMode",t.darkMode)}}function ae(i,a){if(1&i){const t=e.RV6();e.j41(0,"angor-card",48)(1,"div",49)(2,"div",50),e.EFF(3,"Create Post"),e.k0s(),e.j41(4,"mat-slide-toggle",51),e.bIt("change",function(){e.eBV(t);const o=e.XpG();return e.Njj(o.togglePreview())}),e.EFF(5," Preview "),e.k0s()(),e.j41(6,"div",52)(7,"mat-form-field",53),e.nrm(8,"textarea",54,2),e.k0s()(),e.j41(10,"div",55)(11,"div",36)(12,"button",56),e.bIt("click",function(){e.eBV(t);const o=e.XpG();return e.Njj(o.toggleEmojiPicker())}),e.nrm(13,"mat-icon",18),e.j41(14,"span",57),e.EFF(15,"Feeling"),e.k0s()(),e.DNE(16,se,2,1,"div",58),e.j41(17,"button",59),e.nrm(18,"mat-icon",18),e.j41(19,"span",57),e.EFF(20,"Media"),e.k0s()(),e.j41(21,"button",59),e.nrm(22,"mat-icon",18),e.j41(23,"span",57),e.EFF(24,"Tag"),e.k0s()(),e.j41(25,"button",60),e.nrm(26,"mat-icon",18),e.k0s(),e.j41(27,"mat-menu",null,3)(29,"button",61)(30,"span",36),e.nrm(31,"mat-icon",37),e.j41(32,"span"),e.EFF(33,"Tag"),e.k0s()()(),e.j41(34,"button",61)(35,"span",36),e.nrm(36,"mat-icon",37),e.j41(37,"span"),e.EFF(38,"Feeling"),e.k0s()()(),e.j41(39,"button",39)(40,"span",36),e.nrm(41,"mat-icon",37),e.j41(42,"span"),e.EFF(43,"Live"),e.k0s()()(),e.j41(44,"button",39)(45,"span",36),e.nrm(46,"mat-icon",37),e.j41(47,"span"),e.EFF(48,"Gif"),e.k0s()()(),e.j41(49,"button",39)(50,"span",36),e.nrm(51,"mat-icon",37),e.j41(52,"span"),e.EFF(53,"Check in"),e.k0s()()()()(),e.j41(54,"button",62),e.bIt("click",function(){e.eBV(t);const o=e.XpG();return e.Njj(o.sendEvent())}),e.nrm(55,"mat-icon",18),e.j41(56,"span",57),e.EFF(57,"Send"),e.k0s()()()()}if(2&i){const t=e.sdS(28),n=e.XpG();e.R7$(4),e.Y8G("color","primary"),e.R7$(3),e.Y8G("subscriptSizing","dynamic"),e.R7$(),e.Y8G("placeholder","What's on your mind?")("rows",3),e.R7$(5),e.Y8G("svgIcon","heroicons_solid:face-smile"),e.R7$(3),e.Y8G("ngIf",n.showEmojiPicker),e.R7$(2),e.Y8G("svgIcon","heroicons_solid:photo"),e.R7$(4),e.Y8G("svgIcon","heroicons_solid:user-circle"),e.R7$(3),e.Y8G("matMenuTriggerFor",t),e.R7$(),e.Y8G("svgIcon","heroicons_solid:ellipsis-horizontal"),e.R7$(5),e.Y8G("svgIcon","heroicons_solid:user-circle"),e.R7$(5),e.Y8G("svgIcon","heroicons_solid:face-smile"),e.R7$(5),e.Y8G("svgIcon","heroicons_solid:play"),e.R7$(5),e.Y8G("svgIcon","heroicons_solid:sparkles"),e.R7$(5),e.Y8G("svgIcon","heroicons_solid:map-pin"),e.R7$(4),e.Y8G("svgIcon","heroicons_solid:paper-airplane")}}function le(i,a){if(1&i&&(e.qex(0),e.j41(1,"div",87),e.nrm(2,"img",88),e.k0s(),e.bVm()),2&i){const t=e.XpG().$implicit;e.R7$(2),e.Y8G("src",t.safeWord,e.B4B)}}function ce(i,a){if(1&i&&(e.qex(0),e.j41(1,"div",87)(2,"video",89),e.nrm(3,"source",90),e.EFF(4," Your browser does not support the video tag. "),e.k0s()(),e.bVm()),2&i){const t=e.XpG().$implicit;e.R7$(3),e.Y8G("src",t.safeWord,e.B4B)}}function me(i,a){if(1&i&&(e.qex(0),e.j41(1,"div",87)(2,"audio",91),e.nrm(3,"source",92),e.EFF(4," Your browser does not support the audio element. "),e.k0s()(),e.bVm()),2&i){const t=e.XpG().$implicit;e.R7$(3),e.Y8G("src",t.safeWord,e.B4B)}}function ue(i,a){if(1&i&&(e.qex(0),e.j41(1,"div",93)(2,"a",94)(3,"span",95),e.EFF(4),e.k0s()()(),e.bVm()),2&i){const t=e.XpG().$implicit;e.R7$(2),e.Y8G("href",t.word,e.B4B),e.R7$(2),e.JRh(t.word)}}function pe(i,a){if(1&i&&(e.qex(0),e.j41(1,"div",93)(2,"span",96),e.EFF(3),e.k0s()(),e.bVm()),2&i){const t=e.XpG().$implicit,n=e.XpG(2);e.R7$(2),e.Y8G("ngClass",e.eq3(2,H,n.isSingleEmojiOrWord(t))),e.R7$(),e.SpI(" ",t.trim()," ")}}function de(i,a){if(1&i&&(e.j41(0,"div",86),e.DNE(1,le,3,1,"ng-container",25)(2,ce,5,1,"ng-container",25)(3,me,5,1,"ng-container",25)(4,ue,5,2,"ng-container",25)(5,pe,4,4,"ng-container",25),e.k0s()),2&i){const t=a.$implicit;e.R7$(),e.Y8G("ngIf","image"===t.token),e.R7$(),e.Y8G("ngIf","video"===t.token),e.R7$(),e.Y8G("ngIf","audio"===t.token),e.R7$(),e.Y8G("ngIf","link"===t.token),e.R7$(),e.Y8G("ngIf",!t.token)}}function fe(i,a){if(1&i&&(e.j41(0,"angor-card",65,4)(2,"div",66),e.nrm(3,"img",67),e.j41(4,"div",68)(5,"span",69),e.EFF(6),e.k0s(),e.j41(7,"span",70),e.EFF(8,"1 minutes ago"),e.k0s()()(),e.DNE(9,de,6,5,"div",71),e.j41(10,"div",72)(11,"button",73),e.nrm(12,"mat-icon",74),e.j41(13,"span",57),e.EFF(14,"Unlike"),e.k0s()(),e.j41(15,"button",73),e.nrm(16,"mat-icon",75),e.j41(17,"span",57),e.EFF(18,"Comment"),e.k0s()(),e.j41(19,"button",73),e.nrm(20,"mat-icon",76),e.j41(21,"span",57),e.EFF(22,"Share"),e.k0s()(),e.j41(23,"button",73),e.nrm(24,"mat-icon",77),e.j41(25,"span",57),e.EFF(26,"Zap"),e.k0s()()(),e.nrm(27,"hr",78),e.j41(28,"div",79)(29,"div",36)(30,"div",80),e.EFF(31,"0 Zap"),e.k0s()(),e.nrm(32,"div",81),e.j41(33,"div",82)(34,"button",83),e.EFF(35," 0 Like "),e.k0s(),e.j41(36,"button",83),e.EFF(37," 0 shares "),e.k0s(),e.j41(38,"button",84)(39,"span",85),e.EFF(40,"0 Comments"),e.k0s()()()()()),2&i){const t=e.XpG();e.R7$(3),e.FS9("alt",(null==t.profileUser?null:t.profileUser.display_name)||(null==t.profileUser?null:t.profileUser.name)||""),e.Y8G("src",t.getSafeUrl(null==t.profileUser?null:t.profileUser.picture),e.B4B),e.R7$(3),e.JRh((null==t.profileUser?null:t.profileUser.display_name)||(null==t.profileUser?null:t.profileUser.name)||""),e.R7$(3),e.Y8G("ngForOf",t.parseContent.parseContent(t.eventInput.nativeElement.value))("ngForTrackBy",t.trackByFn),e.R7$(3),e.Y8G("svgIcon","heroicons_solid:heart"),e.R7$(4),e.Y8G("svgIcon","heroicons_solid:chat-bubble-left-ellipsis"),e.R7$(4),e.Y8G("svgIcon","heroicons_solid:share"),e.R7$(4),e.Y8G("svgIcon","heroicons_solid:bolt")}}function ge(i,a){1&i&&e.nrm(0,"app-post",31),2&i&&e.Y8G("item",a.$implicit)}function he(i,a){if(1&i){const t=e.RV6();e.j41(0,"div",32)(1,"button",97),e.bIt("click",function(){e.eBV(t);const o=e.XpG();return e.Njj(o.loadNextPage())}),e.EFF(2),e.k0s()()}if(2&i){const t=e.XpG();e.R7$(),e.Y8G("disabled",t.loading),e.R7$(),e.SpI(" ",t.loading?"Loading...":"Load More Posts"," ")}}const ve=[{path:"",component:(()=>{class i{constructor(t,n,o,s,l,u,g,be,ke,xe,_e,ye,je,Pe,Ie){this._changeDetectorRef=t,this._signerService=n,this._storageService=o,this._sanitizer=s,this._route=l,this._router=u,this._snackBar=g,this._dialog=be,this._angorConfigService=ke,this._angorConfirmationService=xe,this._eventService=_e,this._subscriptionService=ye,this._clipboard=je,this.parseContent=Pe,this._bookmarkService=Ie,this.darkMode=!1,this.isLoading=!0,this.errorMessage=null,this._unsubscribeAll=new R.B,this.allPublicKeys=[],this.isCurrentUserProfile=!1,this.isFollowing=!1,this.showEmojiPicker=!1,this.showCommentEmojiPicker=!1,this.paymentInvoice="",this.invoiceAmount="?",this.isLiked=!1,this.isPreview=!1,this.posts=[],this.currentPage=1,this.loading=!1,this.myLikes=[],this.myLikedNoteIds=[],this.isLoadingPosts=!0,this.noEventsMessage="",this.hasMorePosts=!0,this.followersList=[],this.followingList=[],this.aboutExpanded=!0,this.bookmarkedProjectNpubs=[],this.bookmarks$=this._bookmarkService.bookmarks$}ngOnInit(){var t=this;return(0,c.A)(function*(){t.initializeTheme(),t.processRouteParams(),t.loadInitialPosts(),t.subscribeToNewPosts()})()}initializeTheme(){this._angorConfigService.config$.subscribe(t=>{"auto"===t.scheme?this.detectSystemTheme():this.darkMode="dark"===t.scheme})}checkIfRoutePubKeyIsFollowing(){this.isFollowing=!(!this.routePubKey||!this.followersList)&&this.followersList.some(t=>t.pubkey===this.routePubKey)}processRouteParams(){this._route.paramMap.subscribe(t=>{const n=t.get("pubkey")||"";if(n){const o=this._signerService.processKey(n);o?(this.routePubKey=o,this.isCurrentUserProfile=!1):(this.errorMessage="Public key is invalid. Please check your input.",this.setCurrentUserProfile())}else this.setCurrentUserProfile();this.loadUserProfileData(this.routePubKey)})}setCurrentUserProfile(){this.isCurrentUserProfile=!0,this.routePubKey=this._signerService.getPublicKey()}loadUserProfileData(t){this.loadUserProfile(t)}isValidHexPubkey(t){return/^[a-fA-F0-9]{64}$/.test(t)}loadInitialPosts(){var t=this;return(0,c.A)(function*(){t.loading=!0;let n=0;try{for(;n<5;){const l=yield t._storageService.getPostsByPubKeysWithPagination([t.routePubKey],t.currentPage,10);if(l.length>0){t.posts=[...t.posts,...l],t.posts.sort((u,g)=>g.created_at-u.created_at);break}n++,n<5&&(yield t.delay(3e3))}t.hasMorePosts=t.posts.length>0,t.hasMorePosts||console.log("This user has no posts.")}catch(l){console.error("Error loading posts:",l)}finally{t.loading=!1}t.refreshUI()})()}delay(t){return new Promise(n=>setTimeout(n,t))}subscribeToNewPosts(){var t=this;this.isCurrentUserProfile?this._storageService.posts$.subscribe(n=>{n&&n.pubkey===this.routePubKey&&(this.posts.unshift(n),this.posts.sort((o,s)=>s.created_at-o.created_at),this.refreshUI())}):this.postsSubscriptionId=this._subscriptionService.addSubscriptions([{authors:[this.routePubKey],kinds:[1]}],function(){var o=(0,c.A)(function*(s){t.isReply(s)||t._storageService.savePost(s)});return function(s){return o.apply(this,arguments)}}())}isReply(t){return t.tags.filter(o=>"e"===o[0]||"p"===o[0]).length>0}loadNextPage(){this.loading||(this.currentPage++,this.loadInitialPosts())}toggleAbout(){this.aboutExpanded=!this.aboutExpanded}ngOnDestroy(){this.subscriptionId&&this._subscriptionService.removeSubscriptionById(this.subscriptionId),this.postsSubscriptionId&&this._subscriptionService.removeSubscriptionById(this.postsSubscriptionId),this._unsubscribeAll.next(null),this._unsubscribeAll.complete()}loadUserProfile(t){var n=this;return(0,c.A)(function*(){if(n.isLoading=!0,n.errorMessage=null,n.profileUser=null,n.refreshUI(),!t)return n.errorMessage="No public key found. Please log in again.",n.isLoading=!1,void n.refreshUI();try{const o=yield n._storageService.getProfile(t);o&&(n.profileUser=o,n.refreshUI()),n.subscribeToUserProfileAndContacts(t)}catch(o){console.error("Error loading user profile:",o)}})()}subscribeToUserProfileAndContacts(t){var n=this;return(0,c.A)(function*(){n.subscriptionId=n._subscriptionService.addSubscriptions([{authors:[t],kinds:[0],limit:1}],function(){var s=(0,c.A)(function*(l){yield n.processProfileMetadata(l,t)});return function(l){return s.apply(this,arguments)}}())})()}processProfileMetadata(t,n){var o=this;return(0,c.A)(function*(){try{const s=JSON.parse(t.content);o.profileUser=s,yield o._storageService.saveProfile(n,s),o._changeDetectorRef.markForCheck()}catch(s){console.error("Error processing metadata event:",s)}})()}getSafeUrl(t){return this._sanitizer.bypassSecurityTrustUrl(t)}refreshUI(){this._changeDetectorRef.detectChanges()}openSnackBar(t,n="dismiss"){this._snackBar.open(t,n,{duration:3e3})}canUseZap(){var t=this;return(0,c.A)(function*(){return!(!t.profileUser||!t.profileUser.lud06&&!t.profileUser.lud16)||(t.openSnackBar("Using Zap is not possible. Please complete your profile to include lud06 or lud16."),!1)})()}openZapDialog(t=""){var n=this;return(0,c.A)(function*(){(yield n.canUseZap())&&n._dialog.open(C.r,{width:"405px",maxHeight:"90vh",data:{lud16:n.profileUser.lud16,lud06:n.profileUser.lud06,pubkey:n.profileUser.pubkey,eventId:t}})})()}toggleLike(){this.isLiked=!this.isLiked,this.isLiked&&setTimeout(()=>{this.isLiked=!1,this.isLiked=!0},300)}addEmoji(t){this.eventInput.nativeElement.value+=t.emoji.native,this.showEmojiPicker=!1}toggleEmojiPicker(){this.showCommentEmojiPicker=!1,this.showEmojiPicker=!this.showEmojiPicker}addEmojiTocomment(t){this.commentInput.nativeElement.value+=t.emoji.native,this.showCommentEmojiPicker=!1}detectSystemTheme(){const t=window.matchMedia("(prefers-color-scheme: dark)");this.darkMode=t.matches,t.addEventListener("change",n=>{this.darkMode=n.matches})}togglePreview(){this.isPreview=!this.isPreview}sendEvent(){""!=this.eventInput.nativeElement.value&&this._eventService.sendTextEvent(this.eventInput.nativeElement.value).then(()=>{this.eventInput.nativeElement.value="",this._changeDetectorRef.markForCheck()}).catch(t=>{console.error("Failed to send Event:",t)})}copyHex(){this._clipboard.copy(this.routePubKey),this.openSnackBar("hex public key copied","dismiss")}copyNpub(){var t=this._signerService.getNpubFromPubkey(this.routePubKey);this._clipboard.copy(t),this.openSnackBar("npub public key copied","dismiss")}copyKey(t){if("hex"===t)this._clipboard.copy(this.routePubKey),this.openSnackBar("hex public key copied","dismiss");else if("npub"===t){const n=this._signerService.getNpubFromPubkey(this.routePubKey);this._clipboard.copy(n),this.openSnackBar("npub public key copied","dismiss")}}isSingleEmojiOrWord(t){const n=t.trim(),o=/^\w+$/.test(n),s=/^[\p{Emoji}]+$/u.test(n);return o||s}openPost(t){this._router.navigate(["/post",t])}toggleBookmark(t){var n=this;return(0,c.A)(function*(){(yield n._bookmarkService.isBookmarked(t))?yield n._bookmarkService.removeBookmark(t):yield n._bookmarkService.addBookmark(t)})()}isProjectBookmarked(t){var n=this;return(0,c.A)(function*(){return yield n._bookmarkService.isBookmarked(t)})()}static{this.\u0275fac=function(n){return new(n||i)(e.rXU(e.gRc),e.rXU(w.A),e.rXU(Y.n),e.rXU(T.up),e.rXU(f.nX),e.rXU(f.Ix),e.rXU(B.UG),e.rXU(M.bZ),e.rXU(X.P),e.rXU(A.m),e.rXU(N.U),e.rXU(V.n),e.rXU(L.B0),e.rXU(D.m),e.rXU(z.U))}}static{this.\u0275cmp=e.VBU({type:i,selectors:[["profile"]],viewQuery:function(n,o){if(1&n&&(e.GBs(K,5),e.GBs(Z,5)),2&n){let s;e.mGM(s=e.lsd())&&(o.eventInput=s.first),e.mGM(s=e.lsd())&&(o.commentInput=s.first)}},decls:41,vars:21,consts:[["defaultAvatar",""],["profileMenu","matMenu"],["eventInput",""],["postCardMenu01","matMenu"],["expandableComments","angorCard"],[1,"flex","min-w-0","flex-auto","flex-col"],[1,"bg-card","flex","flex-col","shadow"],["onerror","this.onerror=null; this.src='/images/pages/profile/cover.jpg';",1,"h-40","object-cover","lg:h-80",3,"src","alt"],[1,"bg-card","mx-auto","flex","w-full","max-w-5xl","flex-0","flex-col","items-center","px-8","lg:h-18","lg:flex-row"],[1,"-mt-26","flex-shrink-0","rounded-full","lg:-mt-22"],[4,"ngIf","ngIfElse"],[1,"mt-4","flex","flex-grow","flex-col","items-center","lg:ml-8","lg:mt-0","lg:items-start"],[1,"max-w-full","truncate","text-lg","font-bold","leading-tight","lg:max-w-[25rem]",2,"white-space","nowrap","overflow","hidden","text-overflow","ellipsis"],[1,"text-secondary","max-w-full","truncate","leading-tight","lg:max-w-[25rem]",2,"white-space","nowrap","overflow","hidden","text-overflow","ellipsis"],[1,"flex","flex-shrink-0","items-center","space-x-6","lg:mt-0"],[1,"mb-4","mt-8","flex","flex-shrink-0","items-center","space-x-6","lg:m-0","lg:ml-auto"],[1,"flex","h-10","w-10","items-center","justify-center","rounded-full","border","bg-white","shadow-md"],["mat-icon-button",""],[1,"icon-size-5",3,"svgIcon"],["mat-icon-button","",3,"click"],["mat-icon-button","",3,"matMenuTriggerFor"],["mat-menu-item","",3,"click",4,"ngIf"],[4,"ngFor","ngForOf"],[1,"my-2"],["mat-menu-item","",3,"routerLink",4,"ngIf"],[4,"ngIf"],[1,"mx-auto","w-full","max-w-5xl","p-6","sm:p-8"],[1,"m-auto","flex","w-full","max-w-140","flex-col","items-start"],["class","about-section mb-8 flex w-full flex-col items-start p-6 pb-6 transition-all duration-300 sm:p-8","style","position: relative",3,"ngStyle",4,"ngIf"],["class","mb-8 flex w-full flex-col p-6 pb-6 sm:p-8",4,"ngIf"],["class","mb-8 flex w-full flex-col bg-primary-50 dark:bg-primary-800",4,"ngIf"],[1,"mb-8","flex","w-full","flex-col",3,"item"],[1,"m-auto","mt-4","flex","justify-center"],["onerror","this.onerror=null; this.src='/images/avatars/avatar-placeholder.png';",1,"ring-bg-card","h-32","min-h-32","w-32","min-w-32","max-w-fit","rounded-full","object-cover","ring-4",3,"src","alt"],["src","/images/avatars/avatar-placeholder.png","onerror","this.onerror=null; this.src='/images/avatars/avatar-placeholder.png';",1,"ring-bg-card","h-32","min-h-32","w-32","min-w-32","rounded-full","object-cover","ring-4",3,"alt"],["mat-menu-item","",3,"click"],[1,"flex","items-center"],[1,"mr-3","icon-size-5",3,"svgIcon"],["mat-menu-item","",3,"routerLink"],["mat-menu-item",""],[1,"about-section","mb-8","flex","w-full","flex-col","items-start","p-6","pb-6","transition-all","duration-300","sm:p-8",2,"position","relative",3,"ngStyle"],[1,"mb-2","flex","w-full","items-center","justify-between"],[1,"text-2xl","font-semibold","leading-tight"],["mat-icon-button","","color","primary","aria-label","Toggle about section",2,"position","absolute","top","16px","right","16px",3,"click"],[3,"svgIcon"],[1,"about-content","text-base","text-gray-700","dark:text-gray-50","transition-all","duration-300",3,"ngStyle"],["class","text-gray-500",4,"ngIf"],[1,"text-gray-500"],[1,"mb-8","flex","w-full","flex-col","p-6","pb-6","sm:p-8"],[1,"flex","justify-between"],[1,"text-xl","font-semibold"],[1,"-mr-4","ml-auto",3,"change","color"],[1,"mt-8","flex","flex-col","items-start","sm:flex-row"],[1,"w-full",3,"subscriptSizing"],["matInput","","cdkTextareaAutosize","",3,"placeholder","rows"],[1,"-mx-3","mt-6","flex","items-center","justify-between","sm:mt-8"],["mat-button","",1,"mr-1","px-3",3,"click"],[1,"ml-2"],["class","emoji-picker-container-global",4,"ngIf"],["mat-button","",1,"mr-1","hidden","px-3","sm:inline-flex"],["mat-button","",1,"px-3",3,"matMenuTriggerFor"],["mat-menu-item","",1,"sm:hidden"],["mat-button","",1,"mr-1","flex","px-3",3,"click"],[1,"emoji-picker-container-global"],[3,"emojiClick","darkMode"],[1,"mb-8","flex","w-full","flex-col","bg-primary-50","dark:bg-primary-800"],[1,"mx-6","mb-4","mt-6","flex","items-center","sm:mx-8"],["onerror","this.onerror=null; this.src='/images/avatars/avatar-placeholder.png';",1,"mr-4","h-10","w-10","rounded-full","object-cover",3,"src","alt"],[1,"flex","flex-col"],[1,"font-semibold","leading-none"],[1,"text-secondary","mt-1","text-sm","leading-none"],["class","inline-block whitespace-pre-wrap break-words",4,"ngFor","ngForOf","ngForTrackBy"],[1,"mx-3","flex","items-center","sm:mx-5"],["mat-button","",1,"mr-1","px-3"],[1,"text-red-500","icon-size-5",3,"svgIcon"],[1,"text-blue-500","icon-size-5",3,"svgIcon"],[1,"text-green-500","icon-size-5",3,"svgIcon"],[1,"text-orange-500","icon-size-5",3,"svgIcon"],[1,"mx-6","mb-6","mt-4","border-b","sm:mx-8"],[1,"mx-6","mb-4","flex","flex-col","sm:mx-8","sm:mb-6","sm:flex-row","sm:items-center"],[1,"ml-3","text-md","tracking-tight"],[1,"hidden","flex-auto","sm:flex"],[1,"mt-4","flex","items-center","sm:mt-0"],["mat-button","",1,"-ml-2","mr-1","px-3","sm:ml-0"],["mat-button","",1,"px-3","sm:-mr-4"],[1,"mr-1"],[1,"inline-block","whitespace-pre-wrap","break-words"],[1,"relative","mb-4","block"],["alt","Embedded Image",1,"max-h-140","object-cover",2,"width","100%",3,"src"],["controls","",2,"width","100%"],["type","video/mp4",3,"src"],["controls",""],["type","audio/mpeg",3,"src"],[1,"mx-6","mb-6","mt-2","sm:mx-8"],["target","_blank",1,"inline-block","break-words","text-blue-500","underline",3,"href"],[1,"inline-block","break-words"],[1,"inline-block","break-words",3,"ngClass"],["mat-raised-button","","color","primary",1,"bg-card","text-gray-700","hover:bg-gray-200","dark:text-gray-300","dark:hover:bg-gray-700",3,"click","disabled"]],template:function(n,o){if(1&n){const s=e.RV6();e.j41(0,"div",5)(1,"div",6)(2,"div"),e.nrm(3,"img",7),e.k0s(),e.j41(4,"div",8)(5,"div",9),e.DNE(6,Q,2,2,"ng-container",10)(7,q,1,1,"ng-template",null,0,e.C5r),e.k0s(),e.j41(9,"div",11)(10,"div",12),e.EFF(11),e.k0s(),e.j41(12,"div",13),e.EFF(13),e.k0s()(),e.j41(14,"div",14)(15,"div",15)(16,"div",16)(17,"button",17),e.nrm(18,"mat-icon",18),e.k0s()(),e.j41(19,"div",16)(20,"button",19),e.bIt("click",function(){return e.eBV(s),e.Njj(o.toggleBookmark(o.routePubKey))}),e.nrm(21,"mat-icon",18),e.nI1(22,"async"),e.k0s()(),e.j41(23,"div")(24,"button",20),e.nrm(25,"mat-icon",18),e.k0s(),e.j41(26,"mat-menu",null,1),e.DNE(28,ee,5,2,"button",21)(29,te,6,2,"ng-container",22),e.nrm(30,"mat-divider",23),e.DNE(31,oe,5,2,"button",24)(32,ne,11,2,"ng-container",25),e.k0s()()()()()(),e.j41(33,"div",26)(34,"div",27),e.DNE(35,re,9,11,"angor-card",28)(36,ae,58,16,"angor-card",29)(37,fe,41,9,"angor-card",30),e.Z7z(38,ge,1,1,"app-post",31,e.Vm6),e.DNE(40,he,3,2,"div",32),e.k0s()()()}if(2&n){let s;const l=e.sdS(8),u=e.sdS(27);e.R7$(3),e.FS9("alt",(null==o.profileUser?null:o.profileUser.display_name)||(null==o.profileUser?null:o.profileUser.name)||"Banner"),e.Y8G("src",(null==o.profileUser?null:o.profileUser.banner)||"/images/pages/profile/cover.jpg",e.B4B),e.R7$(3),e.Y8G("ngIf",null==o.profileUser?null:o.profileUser.picture)("ngIfElse",l),e.R7$(5),e.SpI(" ",(null==o.profileUser?null:o.profileUser.display_name)||(null==o.profileUser?null:o.profileUser.name)||"Unknown User"," "),e.R7$(2),e.SpI(" ",(null==o.profileUser?null:o.profileUser.username)||(null==o.profileUser?null:o.profileUser.name)," "),e.R7$(5),e.Y8G("svgIcon","heroicons_outline:chat-bubble-left-right"),e.R7$(3),e.Y8G("svgIcon",null!=(s=e.bMT(22,18,o.bookmarks$))&&s.includes(o.routePubKey)?"heroicons_solid:bookmark":"heroicons_outline:bookmark"),e.R7$(3),e.Y8G("matMenuTriggerFor",u),e.R7$(),e.Y8G("svgIcon","heroicons_solid:ellipsis-vertical"),e.R7$(3),e.Y8G("ngIf",!o.isCurrentUserProfile||o.isCurrentUserProfile),e.R7$(),e.Y8G("ngForOf",e.lJ4(20,O)),e.R7$(2),e.Y8G("ngIf",o.isCurrentUserProfile),e.R7$(),e.Y8G("ngIf",!o.isCurrentUserProfile),e.R7$(3),e.Y8G("ngIf",(null==o.profileUser?null:o.profileUser.about)&&""!==o.profileUser.about.trim()),e.R7$(),e.Y8G("ngIf",o.isCurrentUserProfile),e.R7$(),e.Y8G("ngIf",o.isPreview),e.R7$(),e.Dyx(o.posts),e.R7$(2),e.vxM(o.hasMorePosts?40:-1)}},dependencies:[f.Wk,y.n,x.m_,x.An,d.Hl,d.$z,d.iY,p.Cn,p.kk,p.fb,p.Cp,k.RG,k.rl,_.fS,_.fg,v.xb,v.EE,b.w,b.q,U.uc,m.YU,m.MD,m.Sq,m.bT,m.B3,m.Jj,j.YN,F.Ic,I.sG,P.D6,E.e,G.MY,$.vg,S.q],styles:[".emoji-picker-container-global{position:fixed;top:50%;left:50%;transform:translate(-50%,-50%);z-index:9999;width:350px;max-width:100%}.heart-beat{animation:heartBeatAnimation .3s ease-in-out}@keyframes heartBeatAnimation{0%{transform:scale(1)}30%{transform:scale(2)}60%{transform:scale(1)}to{transform:scale(1)}}.loading-spinner{display:flex;justify-content:center;align-items:center;margin:20px 0}.loading-spinner .spinner{border:4px solid rgba(0,0,0,.1);border-left-color:#009fb5;border-radius:50%;width:30px;height:30px;animation:spin 1s linear infinite}@keyframes spin{0%{transform:rotate(0)}to{transform:rotate(360deg)}}.about-section{overflow:hidden;transition:height .3s ease}.c-img,.c-video{max-width:100%;border-radius:10px}\n"],encapsulation:2,changeDetection:0})}}return i})()}]}}]); \ No newline at end of file diff --git a/394.76c49ed2cbb10995.js b/394.76c49ed2cbb10995.js new file mode 100644 index 0000000..418cee1 --- /dev/null +++ b/394.76c49ed2cbb10995.js @@ -0,0 +1 @@ +"use strict";(self.webpackChunkangor=self.webpackChunkangor||[]).push([[394],{5394:(Ue,h,r)=>{r.r(h),r.d(h,{default:()=>ve});var c=r(3014),y=r(7785),v=r(708),m=r(4460),j=r(936),d=r(9471),b=r(7702),P=r(2835),k=r(6071),x=r(3904),_=r(6389),p=r(7818),I=r(1054),U=r(5785),F=r(1371),E=r(7712),f=r(8716),R=r(1556),G=r(5727),$=r(1211),C=r(9363),S=r(8447),e=r(3107),w=r(8078),Y=r(3149),T=r(6388),B=r(7859),M=r(7544),X=r(1109),A=r(7153),N=r(5616),V=r(5506),L=r(4160),D=r(9207),z=r(7112);const K=["eventInput"],Z=["commentInput"],O=()=>["hex","npub"],W=(i,a)=>({height:i,overflow:a}),J=(i,a)=>({"white-space":i,"max-height":a,overflow:"hidden"}),H=i=>({"large-font":i});function Q(i,a){if(1&i&&(e.qex(0),e.nrm(1,"img",33),e.bVm()),2&i){const t=e.XpG();e.R7$(),e.FS9("alt",(null==t.profileUser?null:t.profileUser.display_name)||(null==t.profileUser?null:t.profileUser.name)||""),e.Y8G("src",t.getSafeUrl(null==t.profileUser?null:t.profileUser.picture),e.B4B)}}function q(i,a){if(1&i&&e.nrm(0,"img",34),2&i){const t=e.XpG();e.FS9("alt",(null==t.profileUser?null:t.profileUser.display_name)||(null==t.profileUser?null:t.profileUser.name)||"")}}function ee(i,a){if(1&i){const t=e.RV6();e.j41(0,"button",35),e.bIt("click",function(){e.eBV(t);const o=e.XpG();return e.Njj(o.openZapDialog())}),e.j41(1,"span",36),e.nrm(2,"mat-icon",37),e.j41(3,"span"),e.EFF(4),e.k0s()()()}if(2&i){const t=e.XpG();e.R7$(2),e.Y8G("svgIcon",t.isCurrentUserProfile?"heroicons_outline:qr-code":"feather:zap"),e.R7$(2),e.JRh(t.isCurrentUserProfile?"Receive Zap":"Send Zap")}}function te(i,a){if(1&i){const t=e.RV6();e.qex(0),e.j41(1,"button",35),e.bIt("click",function(){const o=e.eBV(t).$implicit,s=e.XpG();return e.Njj(s.copyKey(o))}),e.j41(2,"span",36),e.nrm(3,"mat-icon",37),e.j41(4,"span"),e.EFF(5),e.k0s()()(),e.bVm()}if(2&i){const t=a.$implicit;e.R7$(3),e.Y8G("svgIcon","heroicons_outline:clipboard-document"),e.R7$(2),e.SpI("Copy Public key (",t,")")}}function oe(i,a){1&i&&(e.j41(0,"button",38)(1,"span",36),e.nrm(2,"mat-icon",37),e.j41(3,"span"),e.EFF(4,"Edit your profile"),e.k0s()()()),2&i&&(e.Y8G("routerLink","/settings/profile"),e.R7$(2),e.Y8G("svgIcon","heroicons_outline:pencil-square"))}function ne(i,a){1&i&&(e.qex(0),e.j41(1,"button",39)(2,"span",36),e.nrm(3,"mat-icon",37),e.j41(4,"span"),e.EFF(5,"Report"),e.k0s()()(),e.j41(6,"button",39)(7,"span",36),e.nrm(8,"mat-icon",37),e.j41(9,"span"),e.EFF(10,"Turn on notifications"),e.k0s()()(),e.bVm()),2&i&&(e.R7$(3),e.Y8G("svgIcon","heroicons_solid:exclamation-triangle"),e.R7$(5),e.Y8G("svgIcon","heroicons_solid:bell"))}function ie(i,a){1&i&&(e.j41(0,"span",47),e.EFF(1,"..."),e.k0s())}function re(i,a){if(1&i){const t=e.RV6();e.j41(0,"angor-card",40)(1,"div",41)(2,"div",42),e.EFF(3," About "),e.k0s(),e.j41(4,"button",43),e.bIt("click",function(){e.eBV(t);const o=e.XpG();return e.Njj(o.toggleAbout())}),e.nrm(5,"mat-icon",44),e.k0s()(),e.j41(6,"div",45),e.EFF(7),e.DNE(8,ie,2,0,"span",46),e.k0s()()}if(2&i){const t=e.XpG();e.Y8G("ngStyle",e.l_i(5,W,t.aboutExpanded?"auto":"80px",t.aboutExpanded?"visible":"hidden")),e.R7$(5),e.Y8G("svgIcon",t.aboutExpanded?"heroicons_outline:chevron-up":"heroicons_outline:chevron-down"),e.R7$(),e.Y8G("ngStyle",e.l_i(8,J,t.aboutExpanded?"normal":"nowrap",t.aboutExpanded?"none":"1.5em")),e.R7$(),e.SpI(" ",(null==t.profileUser?null:t.profileUser.about)||""," "),e.R7$(),e.Y8G("ngIf",!t.aboutExpanded)}}function se(i,a){if(1&i){const t=e.RV6();e.j41(0,"div",63)(1,"emoji-mart",64),e.bIt("emojiClick",function(o){e.eBV(t);const s=e.XpG(2);return e.Njj(s.addEmoji(o))}),e.k0s()()}if(2&i){const t=e.XpG(2);e.R7$(),e.Y8G("darkMode",t.darkMode)}}function ae(i,a){if(1&i){const t=e.RV6();e.j41(0,"angor-card",48)(1,"div",49)(2,"div",50),e.EFF(3,"Create Post"),e.k0s(),e.j41(4,"mat-slide-toggle",51),e.bIt("change",function(){e.eBV(t);const o=e.XpG();return e.Njj(o.togglePreview())}),e.EFF(5," Preview "),e.k0s()(),e.j41(6,"div",52)(7,"mat-form-field",53),e.nrm(8,"textarea",54,2),e.k0s()(),e.j41(10,"div",55)(11,"div",36)(12,"button",56),e.bIt("click",function(){e.eBV(t);const o=e.XpG();return e.Njj(o.toggleEmojiPicker())}),e.nrm(13,"mat-icon",18),e.j41(14,"span",57),e.EFF(15,"Feeling"),e.k0s()(),e.DNE(16,se,2,1,"div",58),e.j41(17,"button",59),e.nrm(18,"mat-icon",18),e.j41(19,"span",57),e.EFF(20,"Media"),e.k0s()(),e.j41(21,"button",59),e.nrm(22,"mat-icon",18),e.j41(23,"span",57),e.EFF(24,"Tag"),e.k0s()(),e.j41(25,"button",60),e.nrm(26,"mat-icon",18),e.k0s(),e.j41(27,"mat-menu",null,3)(29,"button",61)(30,"span",36),e.nrm(31,"mat-icon",37),e.j41(32,"span"),e.EFF(33,"Tag"),e.k0s()()(),e.j41(34,"button",61)(35,"span",36),e.nrm(36,"mat-icon",37),e.j41(37,"span"),e.EFF(38,"Feeling"),e.k0s()()(),e.j41(39,"button",39)(40,"span",36),e.nrm(41,"mat-icon",37),e.j41(42,"span"),e.EFF(43,"Live"),e.k0s()()(),e.j41(44,"button",39)(45,"span",36),e.nrm(46,"mat-icon",37),e.j41(47,"span"),e.EFF(48,"Gif"),e.k0s()()(),e.j41(49,"button",39)(50,"span",36),e.nrm(51,"mat-icon",37),e.j41(52,"span"),e.EFF(53,"Check in"),e.k0s()()()()(),e.j41(54,"button",62),e.bIt("click",function(){e.eBV(t);const o=e.XpG();return e.Njj(o.sendEvent())}),e.nrm(55,"mat-icon",18),e.j41(56,"span",57),e.EFF(57,"Send"),e.k0s()()()()}if(2&i){const t=e.sdS(28),n=e.XpG();e.R7$(4),e.Y8G("color","primary"),e.R7$(3),e.Y8G("subscriptSizing","dynamic"),e.R7$(),e.Y8G("placeholder","What's on your mind?")("rows",3),e.R7$(5),e.Y8G("svgIcon","heroicons_solid:face-smile"),e.R7$(3),e.Y8G("ngIf",n.showEmojiPicker),e.R7$(2),e.Y8G("svgIcon","heroicons_solid:photo"),e.R7$(4),e.Y8G("svgIcon","heroicons_solid:user-circle"),e.R7$(3),e.Y8G("matMenuTriggerFor",t),e.R7$(),e.Y8G("svgIcon","heroicons_solid:ellipsis-horizontal"),e.R7$(5),e.Y8G("svgIcon","heroicons_solid:user-circle"),e.R7$(5),e.Y8G("svgIcon","heroicons_solid:face-smile"),e.R7$(5),e.Y8G("svgIcon","heroicons_solid:play"),e.R7$(5),e.Y8G("svgIcon","heroicons_solid:sparkles"),e.R7$(5),e.Y8G("svgIcon","heroicons_solid:map-pin"),e.R7$(4),e.Y8G("svgIcon","heroicons_solid:paper-airplane")}}function le(i,a){if(1&i&&(e.qex(0),e.j41(1,"div",87),e.nrm(2,"img",88),e.k0s(),e.bVm()),2&i){const t=e.XpG().$implicit;e.R7$(2),e.Y8G("src",t.safeWord,e.B4B)}}function ce(i,a){if(1&i&&(e.qex(0),e.j41(1,"div",87)(2,"video",89),e.nrm(3,"source",90),e.EFF(4," Your browser does not support the video tag. "),e.k0s()(),e.bVm()),2&i){const t=e.XpG().$implicit;e.R7$(3),e.Y8G("src",t.safeWord,e.B4B)}}function me(i,a){if(1&i&&(e.qex(0),e.j41(1,"div",87)(2,"audio",91),e.nrm(3,"source",92),e.EFF(4," Your browser does not support the audio element. "),e.k0s()(),e.bVm()),2&i){const t=e.XpG().$implicit;e.R7$(3),e.Y8G("src",t.safeWord,e.B4B)}}function ue(i,a){if(1&i&&(e.qex(0),e.j41(1,"div",93)(2,"a",94)(3,"span",95),e.EFF(4),e.k0s()()(),e.bVm()),2&i){const t=e.XpG().$implicit;e.R7$(2),e.Y8G("href",t.word,e.B4B),e.R7$(2),e.JRh(t.word)}}function pe(i,a){if(1&i&&(e.qex(0),e.j41(1,"div",93)(2,"span",96),e.EFF(3),e.k0s()(),e.bVm()),2&i){const t=e.XpG().$implicit,n=e.XpG(2);e.R7$(2),e.Y8G("ngClass",e.eq3(2,H,n.isSingleEmojiOrWord(t))),e.R7$(),e.SpI(" ",t.trim()," ")}}function de(i,a){if(1&i&&(e.j41(0,"div",86),e.DNE(1,le,3,1,"ng-container",25)(2,ce,5,1,"ng-container",25)(3,me,5,1,"ng-container",25)(4,ue,5,2,"ng-container",25)(5,pe,4,4,"ng-container",25),e.k0s()),2&i){const t=a.$implicit;e.R7$(),e.Y8G("ngIf","image"===t.token),e.R7$(),e.Y8G("ngIf","video"===t.token),e.R7$(),e.Y8G("ngIf","audio"===t.token),e.R7$(),e.Y8G("ngIf","link"===t.token),e.R7$(),e.Y8G("ngIf",!t.token)}}function fe(i,a){if(1&i&&(e.j41(0,"angor-card",65,4)(2,"div",66),e.nrm(3,"img",67),e.j41(4,"div",68)(5,"span",69),e.EFF(6),e.k0s(),e.j41(7,"span",70),e.EFF(8,"1 minutes ago"),e.k0s()()(),e.DNE(9,de,6,5,"div",71),e.j41(10,"div",72)(11,"button",73),e.nrm(12,"mat-icon",74),e.j41(13,"span",57),e.EFF(14,"Unlike"),e.k0s()(),e.j41(15,"button",73),e.nrm(16,"mat-icon",75),e.j41(17,"span",57),e.EFF(18,"Comment"),e.k0s()(),e.j41(19,"button",73),e.nrm(20,"mat-icon",76),e.j41(21,"span",57),e.EFF(22,"Share"),e.k0s()(),e.j41(23,"button",73),e.nrm(24,"mat-icon",77),e.j41(25,"span",57),e.EFF(26,"Zap"),e.k0s()()(),e.nrm(27,"hr",78),e.j41(28,"div",79)(29,"div",36)(30,"div",80),e.EFF(31,"0 Zap"),e.k0s()(),e.nrm(32,"div",81),e.j41(33,"div",82)(34,"button",83),e.EFF(35," 0 Like "),e.k0s(),e.j41(36,"button",83),e.EFF(37," 0 shares "),e.k0s(),e.j41(38,"button",84)(39,"span",85),e.EFF(40,"0 Comments"),e.k0s()()()()()),2&i){const t=e.XpG();e.R7$(3),e.FS9("alt",(null==t.profileUser?null:t.profileUser.display_name)||(null==t.profileUser?null:t.profileUser.name)||""),e.Y8G("src",t.getSafeUrl(null==t.profileUser?null:t.profileUser.picture),e.B4B),e.R7$(3),e.JRh((null==t.profileUser?null:t.profileUser.display_name)||(null==t.profileUser?null:t.profileUser.name)||""),e.R7$(3),e.Y8G("ngForOf",t.parseContent.parseContent(t.eventInput.nativeElement.value))("ngForTrackBy",t.trackByFn),e.R7$(3),e.Y8G("svgIcon","heroicons_solid:heart"),e.R7$(4),e.Y8G("svgIcon","heroicons_solid:chat-bubble-left-ellipsis"),e.R7$(4),e.Y8G("svgIcon","heroicons_solid:share"),e.R7$(4),e.Y8G("svgIcon","heroicons_solid:bolt")}}function ge(i,a){1&i&&e.nrm(0,"app-post",31),2&i&&e.Y8G("item",a.$implicit)}function he(i,a){if(1&i){const t=e.RV6();e.j41(0,"div",32)(1,"button",97),e.bIt("click",function(){e.eBV(t);const o=e.XpG();return e.Njj(o.loadNextPage())}),e.EFF(2),e.k0s()()}if(2&i){const t=e.XpG();e.R7$(),e.Y8G("disabled",t.loading),e.R7$(),e.SpI(" ",t.loading?"Loading...":"Load More Posts"," ")}}const ve=[{path:"",component:(()=>{class i{constructor(t,n,o,s,l,u,g,be,ke,xe,_e,ye,je,Pe,Ie){this._changeDetectorRef=t,this._signerService=n,this._storageService=o,this._sanitizer=s,this._route=l,this._router=u,this._snackBar=g,this._dialog=be,this._angorConfigService=ke,this._angorConfirmationService=xe,this._eventService=_e,this._subscriptionService=ye,this._clipboard=je,this.parseContent=Pe,this._bookmarkService=Ie,this.darkMode=!1,this.isLoading=!0,this.errorMessage=null,this._unsubscribeAll=new S.B,this.allPublicKeys=[],this.isCurrentUserProfile=!1,this.isFollowing=!1,this.showEmojiPicker=!1,this.showCommentEmojiPicker=!1,this.paymentInvoice="",this.invoiceAmount="?",this.isLiked=!1,this.isPreview=!1,this.posts=[],this.currentPage=1,this.loading=!1,this.myLikes=[],this.myLikedNoteIds=[],this.isLoadingPosts=!0,this.noEventsMessage="",this.hasMorePosts=!0,this.followersList=[],this.followingList=[],this.aboutExpanded=!0,this.bookmarkedProjectNpubs=[],this.bookmarks$=this._bookmarkService.bookmarks$}ngOnInit(){var t=this;return(0,c.A)(function*(){t.initializeTheme(),t.processRouteParams(),t.loadInitialPosts(),t.subscribeToNewPosts()})()}initializeTheme(){this._angorConfigService.config$.subscribe(t=>{"auto"===t.scheme?this.detectSystemTheme():this.darkMode="dark"===t.scheme})}trackByFn(t,n){return t}checkIfRoutePubKeyIsFollowing(){this.isFollowing=!(!this.routePubKey||!this.followersList)&&this.followersList.some(t=>t.pubkey===this.routePubKey)}processRouteParams(){this._route.paramMap.subscribe(t=>{const n=t.get("pubkey")||"";if(n){const o=this._signerService.processKey(n);o?(this.routePubKey=o,this.isCurrentUserProfile=!1):(this.errorMessage="Public key is invalid. Please check your input.",this.setCurrentUserProfile())}else this.setCurrentUserProfile();this.loadUserProfileData(this.routePubKey)})}setCurrentUserProfile(){this.isCurrentUserProfile=!0,this.routePubKey=this._signerService.getPublicKey()}loadUserProfileData(t){this.loadUserProfile(t)}isValidHexPubkey(t){return/^[a-fA-F0-9]{64}$/.test(t)}loadInitialPosts(){var t=this;return(0,c.A)(function*(){t.loading=!0;let n=0;try{for(;n<5;){const l=yield t._storageService.getPostsByPubKeysWithPagination([t.routePubKey],t.currentPage,10);if(l.length>0){t.posts=[...t.posts,...l],t.posts.sort((u,g)=>g.created_at-u.created_at);break}n++,n<5&&(yield t.delay(3e3))}t.hasMorePosts=t.posts.length>0,t.hasMorePosts||console.log("This user has no posts.")}catch(l){console.error("Error loading posts:",l)}finally{t.loading=!1}t.refreshUI()})()}delay(t){return new Promise(n=>setTimeout(n,t))}subscribeToNewPosts(){var t=this;this.isCurrentUserProfile?this._storageService.posts$.subscribe(n=>{n&&n.pubkey===this.routePubKey&&(this.posts.unshift(n),this.posts.sort((o,s)=>s.created_at-o.created_at),this.refreshUI())}):this.postsSubscriptionId=this._subscriptionService.addSubscriptions([{authors:[this.routePubKey],kinds:[1]}],function(){var o=(0,c.A)(function*(s){t.isReply(s)||t._storageService.savePost(s)});return function(s){return o.apply(this,arguments)}}())}isReply(t){return t.tags.filter(o=>"e"===o[0]||"p"===o[0]).length>0}loadNextPage(){this.loading||(this.currentPage++,this.loadInitialPosts())}toggleAbout(){this.aboutExpanded=!this.aboutExpanded}ngOnDestroy(){this.subscriptionId&&this._subscriptionService.removeSubscriptionById(this.subscriptionId),this.postsSubscriptionId&&this._subscriptionService.removeSubscriptionById(this.postsSubscriptionId),this._unsubscribeAll.next(null),this._unsubscribeAll.complete()}loadUserProfile(t){var n=this;return(0,c.A)(function*(){if(n.isLoading=!0,n.errorMessage=null,n.profileUser=null,n.refreshUI(),!t)return n.errorMessage="No public key found. Please log in again.",n.isLoading=!1,void n.refreshUI();try{const o=yield n._storageService.getProfile(t);o&&(n.profileUser=o,n.refreshUI()),n.subscribeToUserProfileAndContacts(t)}catch(o){console.error("Error loading user profile:",o)}})()}subscribeToUserProfileAndContacts(t){var n=this;return(0,c.A)(function*(){n.subscriptionId=n._subscriptionService.addSubscriptions([{authors:[t],kinds:[0],limit:1}],function(){var s=(0,c.A)(function*(l){yield n.processProfileMetadata(l,t)});return function(l){return s.apply(this,arguments)}}())})()}processProfileMetadata(t,n){var o=this;return(0,c.A)(function*(){try{const s=JSON.parse(t.content);o.profileUser=s,yield o._storageService.saveProfile(n,s),o._changeDetectorRef.markForCheck()}catch(s){console.error("Error processing metadata event:",s)}})()}getSafeUrl(t){return this._sanitizer.bypassSecurityTrustUrl(t)}refreshUI(){this._changeDetectorRef.detectChanges()}openSnackBar(t,n="dismiss"){this._snackBar.open(t,n,{duration:3e3})}canUseZap(){var t=this;return(0,c.A)(function*(){return!(!t.profileUser||!t.profileUser.lud06&&!t.profileUser.lud16)||(t.openSnackBar("Using Zap is not possible. Please complete your profile to include lud06 or lud16."),!1)})()}openZapDialog(t=""){var n=this;return(0,c.A)(function*(){(yield n.canUseZap())&&n._dialog.open($.r,{width:"405px",maxHeight:"90vh",data:{lud16:n.profileUser.lud16,lud06:n.profileUser.lud06,pubkey:n.profileUser.pubkey,eventId:t}})})()}toggleLike(){this.isLiked=!this.isLiked,this.isLiked&&setTimeout(()=>{this.isLiked=!1,this.isLiked=!0},300)}addEmoji(t){this.eventInput.nativeElement.value+=t.emoji.native,this.showEmojiPicker=!1}toggleEmojiPicker(){this.showCommentEmojiPicker=!1,this.showEmojiPicker=!this.showEmojiPicker}addEmojiTocomment(t){this.commentInput.nativeElement.value+=t.emoji.native,this.showCommentEmojiPicker=!1}detectSystemTheme(){const t=window.matchMedia("(prefers-color-scheme: dark)");this.darkMode=t.matches,t.addEventListener("change",n=>{this.darkMode=n.matches})}togglePreview(){this.isPreview=!this.isPreview}sendEvent(){""!=this.eventInput.nativeElement.value&&this._eventService.sendTextEvent(this.eventInput.nativeElement.value).then(()=>{this.eventInput.nativeElement.value="",this._changeDetectorRef.markForCheck()}).catch(t=>{console.error("Failed to send Event:",t)})}copyHex(){this._clipboard.copy(this.routePubKey),this.openSnackBar("hex public key copied","dismiss")}copyNpub(){var t=this._signerService.getNpubFromPubkey(this.routePubKey);this._clipboard.copy(t),this.openSnackBar("npub public key copied","dismiss")}copyKey(t){if("hex"===t)this._clipboard.copy(this.routePubKey),this.openSnackBar("hex public key copied","dismiss");else if("npub"===t){const n=this._signerService.getNpubFromPubkey(this.routePubKey);this._clipboard.copy(n),this.openSnackBar("npub public key copied","dismiss")}}isSingleEmojiOrWord(t){const n=t.trim(),o=/^\w+$/.test(n),s=/^[\p{Emoji}]+$/u.test(n);return o||s}openPost(t){this._router.navigate(["/post",t])}toggleBookmark(t){var n=this;return(0,c.A)(function*(){(yield n._bookmarkService.isBookmarked(t))?yield n._bookmarkService.removeBookmark(t):yield n._bookmarkService.addBookmark(t)})()}isProjectBookmarked(t){var n=this;return(0,c.A)(function*(){return yield n._bookmarkService.isBookmarked(t)})()}static{this.\u0275fac=function(n){return new(n||i)(e.rXU(e.gRc),e.rXU(w.A),e.rXU(Y.n),e.rXU(T.up),e.rXU(f.nX),e.rXU(f.Ix),e.rXU(B.UG),e.rXU(M.bZ),e.rXU(X.P),e.rXU(A.m),e.rXU(N.U),e.rXU(V.n),e.rXU(L.B0),e.rXU(D.m),e.rXU(z.U))}}static{this.\u0275cmp=e.VBU({type:i,selectors:[["profile"]],viewQuery:function(n,o){if(1&n&&(e.GBs(K,5),e.GBs(Z,5)),2&n){let s;e.mGM(s=e.lsd())&&(o.eventInput=s.first),e.mGM(s=e.lsd())&&(o.commentInput=s.first)}},decls:41,vars:21,consts:[["defaultAvatar",""],["profileMenu","matMenu"],["eventInput",""],["postCardMenu01","matMenu"],["expandableComments","angorCard"],[1,"flex","min-w-0","flex-auto","flex-col"],[1,"bg-card","flex","flex-col","shadow"],["onerror","this.onerror=null; this.src='/images/pages/profile/cover.jpg';",1,"h-40","object-cover","lg:h-80",3,"src","alt"],[1,"bg-card","mx-auto","flex","w-full","max-w-5xl","flex-0","flex-col","items-center","px-8","lg:h-18","lg:flex-row"],[1,"-mt-26","flex-shrink-0","rounded-full","lg:-mt-22"],[4,"ngIf","ngIfElse"],[1,"mt-4","flex","flex-grow","flex-col","items-center","lg:ml-8","lg:mt-0","lg:items-start"],[1,"max-w-full","truncate","text-lg","font-bold","leading-tight","lg:max-w-[25rem]",2,"white-space","nowrap","overflow","hidden","text-overflow","ellipsis"],[1,"text-secondary","max-w-full","truncate","leading-tight","lg:max-w-[25rem]",2,"white-space","nowrap","overflow","hidden","text-overflow","ellipsis"],[1,"flex","flex-shrink-0","items-center","space-x-6","lg:mt-0"],[1,"mb-4","mt-8","flex","flex-shrink-0","items-center","space-x-6","lg:m-0","lg:ml-auto"],[1,"flex","h-10","w-10","items-center","justify-center","rounded-full","border","bg-white","shadow-md"],["mat-icon-button",""],[1,"icon-size-5",3,"svgIcon"],["mat-icon-button","",3,"click"],["mat-icon-button","",3,"matMenuTriggerFor"],["mat-menu-item","",3,"click",4,"ngIf"],[4,"ngFor","ngForOf"],[1,"my-2"],["mat-menu-item","",3,"routerLink",4,"ngIf"],[4,"ngIf"],[1,"mx-auto","w-full","max-w-5xl","p-6","sm:p-8"],[1,"m-auto","flex","w-full","max-w-140","flex-col","items-start"],["class","about-section mb-8 flex w-full flex-col items-start p-6 pb-6 transition-all duration-300 sm:p-8","style","position: relative",3,"ngStyle",4,"ngIf"],["class","mb-8 flex w-full flex-col p-6 pb-6 sm:p-8",4,"ngIf"],["class","mb-8 flex w-full flex-col bg-primary-50 dark:bg-primary-800",4,"ngIf"],[1,"mb-8","flex","w-full","flex-col",3,"item"],[1,"m-auto","mt-4","flex","justify-center"],["onerror","this.onerror=null; this.src='/images/avatars/avatar-placeholder.png';",1,"ring-bg-card","h-32","min-h-32","w-32","min-w-32","max-w-fit","rounded-full","object-cover","ring-4",3,"src","alt"],["src","/images/avatars/avatar-placeholder.png","onerror","this.onerror=null; this.src='/images/avatars/avatar-placeholder.png';",1,"ring-bg-card","h-32","min-h-32","w-32","min-w-32","rounded-full","object-cover","ring-4",3,"alt"],["mat-menu-item","",3,"click"],[1,"flex","items-center"],[1,"mr-3","icon-size-5",3,"svgIcon"],["mat-menu-item","",3,"routerLink"],["mat-menu-item",""],[1,"about-section","mb-8","flex","w-full","flex-col","items-start","p-6","pb-6","transition-all","duration-300","sm:p-8",2,"position","relative",3,"ngStyle"],[1,"mb-2","flex","w-full","items-center","justify-between"],[1,"text-2xl","font-semibold","leading-tight"],["mat-icon-button","","color","primary","aria-label","Toggle about section",2,"position","absolute","top","16px","right","16px",3,"click"],[3,"svgIcon"],[1,"about-content","text-base","text-gray-700","dark:text-gray-50","transition-all","duration-300",3,"ngStyle"],["class","text-gray-500",4,"ngIf"],[1,"text-gray-500"],[1,"mb-8","flex","w-full","flex-col","p-6","pb-6","sm:p-8"],[1,"flex","justify-between"],[1,"text-xl","font-semibold"],[1,"-mr-4","ml-auto",3,"change","color"],[1,"mt-8","flex","flex-col","items-start","sm:flex-row"],[1,"w-full",3,"subscriptSizing"],["matInput","","cdkTextareaAutosize","",3,"placeholder","rows"],[1,"-mx-3","mt-6","flex","items-center","justify-between","sm:mt-8"],["mat-button","",1,"mr-1","px-3",3,"click"],[1,"ml-2"],["class","emoji-picker-container-global",4,"ngIf"],["mat-button","",1,"mr-1","hidden","px-3","sm:inline-flex"],["mat-button","",1,"px-3",3,"matMenuTriggerFor"],["mat-menu-item","",1,"sm:hidden"],["mat-button","",1,"mr-1","flex","px-3",3,"click"],[1,"emoji-picker-container-global"],[3,"emojiClick","darkMode"],[1,"mb-8","flex","w-full","flex-col","bg-primary-50","dark:bg-primary-800"],[1,"mx-6","mb-4","mt-6","flex","items-center","sm:mx-8"],["onerror","this.onerror=null; this.src='/images/avatars/avatar-placeholder.png';",1,"mr-4","h-10","w-10","rounded-full","object-cover",3,"src","alt"],[1,"flex","flex-col"],[1,"font-semibold","leading-none"],[1,"text-secondary","mt-1","text-sm","leading-none"],["class","inline-block whitespace-pre-wrap break-words",4,"ngFor","ngForOf","ngForTrackBy"],[1,"mx-3","flex","items-center","sm:mx-5"],["mat-button","",1,"mr-1","px-3"],[1,"text-red-500","icon-size-5",3,"svgIcon"],[1,"text-blue-500","icon-size-5",3,"svgIcon"],[1,"text-green-500","icon-size-5",3,"svgIcon"],[1,"text-orange-500","icon-size-5",3,"svgIcon"],[1,"mx-6","mb-6","mt-4","border-b","sm:mx-8"],[1,"mx-6","mb-4","flex","flex-col","sm:mx-8","sm:mb-6","sm:flex-row","sm:items-center"],[1,"ml-3","text-md","tracking-tight"],[1,"hidden","flex-auto","sm:flex"],[1,"mt-4","flex","items-center","sm:mt-0"],["mat-button","",1,"-ml-2","mr-1","px-3","sm:ml-0"],["mat-button","",1,"px-3","sm:-mr-4"],[1,"mr-1"],[1,"inline-block","whitespace-pre-wrap","break-words"],[1,"relative","mb-4","block"],["alt","Embedded Image",1,"max-h-140","object-cover",2,"width","100%",3,"src"],["controls","",2,"width","100%"],["type","video/mp4",3,"src"],["controls",""],["type","audio/mpeg",3,"src"],[1,"mx-6","mb-6","mt-2","sm:mx-8"],["target","_blank",1,"inline-block","break-words","text-blue-500","underline",3,"href"],[1,"inline-block","break-words"],[1,"inline-block","break-words",3,"ngClass"],["mat-raised-button","","color","primary",1,"bg-card","text-gray-700","hover:bg-gray-200","dark:text-gray-300","dark:hover:bg-gray-700",3,"click","disabled"]],template:function(n,o){if(1&n){const s=e.RV6();e.j41(0,"div",5)(1,"div",6)(2,"div"),e.nrm(3,"img",7),e.k0s(),e.j41(4,"div",8)(5,"div",9),e.DNE(6,Q,2,2,"ng-container",10)(7,q,1,1,"ng-template",null,0,e.C5r),e.k0s(),e.j41(9,"div",11)(10,"div",12),e.EFF(11),e.k0s(),e.j41(12,"div",13),e.EFF(13),e.k0s()(),e.j41(14,"div",14)(15,"div",15)(16,"div",16)(17,"button",17),e.nrm(18,"mat-icon",18),e.k0s()(),e.j41(19,"div",16)(20,"button",19),e.bIt("click",function(){return e.eBV(s),e.Njj(o.toggleBookmark(o.routePubKey))}),e.nrm(21,"mat-icon",18),e.nI1(22,"async"),e.k0s()(),e.j41(23,"div")(24,"button",20),e.nrm(25,"mat-icon",18),e.k0s(),e.j41(26,"mat-menu",null,1),e.DNE(28,ee,5,2,"button",21)(29,te,6,2,"ng-container",22),e.nrm(30,"mat-divider",23),e.DNE(31,oe,5,2,"button",24)(32,ne,11,2,"ng-container",25),e.k0s()()()()()(),e.j41(33,"div",26)(34,"div",27),e.DNE(35,re,9,11,"angor-card",28)(36,ae,58,16,"angor-card",29)(37,fe,41,9,"angor-card",30),e.Z7z(38,ge,1,1,"app-post",31,e.Vm6),e.DNE(40,he,3,2,"div",32),e.k0s()()()}if(2&n){let s;const l=e.sdS(8),u=e.sdS(27);e.R7$(3),e.FS9("alt",(null==o.profileUser?null:o.profileUser.display_name)||(null==o.profileUser?null:o.profileUser.name)||"Banner"),e.Y8G("src",(null==o.profileUser?null:o.profileUser.banner)||"/images/pages/profile/cover.jpg",e.B4B),e.R7$(3),e.Y8G("ngIf",null==o.profileUser?null:o.profileUser.picture)("ngIfElse",l),e.R7$(5),e.SpI(" ",(null==o.profileUser?null:o.profileUser.display_name)||(null==o.profileUser?null:o.profileUser.name)||"Unknown User"," "),e.R7$(2),e.SpI(" ",(null==o.profileUser?null:o.profileUser.username)||(null==o.profileUser?null:o.profileUser.name)," "),e.R7$(5),e.Y8G("svgIcon","heroicons_outline:chat-bubble-left-right"),e.R7$(3),e.Y8G("svgIcon",null!=(s=e.bMT(22,18,o.bookmarks$))&&s.includes(o.routePubKey)?"heroicons_solid:bookmark":"heroicons_outline:bookmark"),e.R7$(3),e.Y8G("matMenuTriggerFor",u),e.R7$(),e.Y8G("svgIcon","heroicons_solid:ellipsis-vertical"),e.R7$(3),e.Y8G("ngIf",!o.isCurrentUserProfile||o.isCurrentUserProfile),e.R7$(),e.Y8G("ngForOf",e.lJ4(20,O)),e.R7$(2),e.Y8G("ngIf",o.isCurrentUserProfile),e.R7$(),e.Y8G("ngIf",!o.isCurrentUserProfile),e.R7$(3),e.Y8G("ngIf",(null==o.profileUser?null:o.profileUser.about)&&""!==o.profileUser.about.trim()),e.R7$(),e.Y8G("ngIf",o.isCurrentUserProfile),e.R7$(),e.Y8G("ngIf",o.isPreview),e.R7$(),e.Dyx(o.posts),e.R7$(2),e.vxM(o.hasMorePosts?40:-1)}},dependencies:[f.Wk,y.n,x.m_,x.An,d.Hl,d.$z,d.iY,p.Cn,p.kk,p.fb,p.Cp,k.RG,k.rl,_.fS,_.fg,v.xb,v.EE,b.w,b.q,E.uc,m.YU,m.MD,m.Sq,m.bT,m.B3,m.Jj,j.YN,R.Ic,F.sG,I.D6,C.e,P.MY,U.vg,G.q],styles:[".emoji-picker-container-global{position:fixed;top:50%;left:50%;transform:translate(-50%,-50%);z-index:9999;width:350px;max-width:100%}.heart-beat{animation:heartBeatAnimation .3s ease-in-out}@keyframes heartBeatAnimation{0%{transform:scale(1)}30%{transform:scale(2)}60%{transform:scale(1)}to{transform:scale(1)}}.loading-spinner{display:flex;justify-content:center;align-items:center;margin:20px 0}.loading-spinner .spinner{border:4px solid rgba(0,0,0,.1);border-left-color:#009fb5;border-radius:50%;width:30px;height:30px;animation:spin 1s linear infinite}@keyframes spin{0%{transform:rotate(0)}to{transform:rotate(360deg)}}.about-section{overflow:hidden;transition:height .3s ease}.c-img,.c-video{max-width:100%;border-radius:10px}\n"],encapsulation:2,changeDetection:0})}}return i})()}]}}]); \ No newline at end of file diff --git a/404.html b/404.html index 977b185..5d113ad 100644 --- a/404.html +++ b/404.html @@ -41,5 +41,5 @@ - + diff --git a/512.21e2f0687bbf0a15.js b/512.21e2f0687bbf0a15.js deleted file mode 100644 index 56aa46f..0000000 --- a/512.21e2f0687bbf0a15.js +++ /dev/null @@ -1 +0,0 @@ -"use strict";(self.webpackChunkangor=self.webpackChunkangor||[]).push([[512],{1512:(xe,Y,c)=>{c.r(Y),c.d(Y,{default:()=>_e});var t=c(3107),v=c(8716);let O=(()=>{class i{constructor(){}static{this.\u0275fac=function(n){return new(n||i)}}static{this.\u0275cmp=t.VBU({type:i,selectors:[["chat"]],decls:3,vars:0,consts:[[1,"absolute","inset-0","flex","min-w-0","flex-col","overflow-hidden"],[1,"flex","flex-auto","overflow-hidden"]],template:function(n,o){1&n&&(t.j41(0,"div",0)(1,"div",1),t.nrm(2,"router-outlet"),t.k0s()())},dependencies:[v.n3],encapsulation:2,changeDetection:0})}}return i})();var _=c(3014),F=c(1217),I=c(8447),V=c(1698),R=c(8915),N=c(1787),K=c(3016),B=c(1483),X=c(7610),G=c(2867),D=c(7947),S=c(7178),L=c(5492),$=c(3797),H=c(8078),z=c(3149),W=c(3125),Q=c(7121);let x=(()=>{class i{constructor(e,n,o,r){this._signerService=e,this._storageService=n,this._relayService=o,this._metadataQueueService=r,this.chatList=[],this.latestMessageTimestamps={},this.messageQueue=[],this.isDecrypting=!1,this.decryptedPrivateKey="",this._chat=new F.t(null),this._chats=new F.t(null),this._contact=new F.t(null),this._contacts=new F.t(null),this._profile=new F.t(null),this._unsubscribeAll=new I.B}get profile$(){return this._profile.asObservable()}get chat$(){return this._chat.asObservable()}get chats$(){return this._chats.asObservable()}get contact$(){return this._contact.asObservable()}get contacts$(){return this._contacts.asObservable()}checkCurrentChatOnPageRefresh(e){e&&this.getChatById(e).subscribe(o=>{o&&(this._chat.next(o),this.loadAndFetchChatHistory(e))})}getContact(e){var n=this;return(0,_.A)(function*(){try{if(!e)return;n._storageService.profile$.subscribe(o=>{o&&o.pubKey&&o.metadata&&o.pubKey===e&&n._contact.next({pubKey:e,displayName:o.metadata.name?o.metadata.name:"Unknown",picture:o.metadata.picture,about:o.metadata.about})})}catch(o){console.error("Error fetching contact metadata:",o)}})()}getContacts(){return new V.c(e=>(this._storageService.getAllProfiles().then(n=>{if(n&&n.length>0){const o=n.map(r=>(r.pubKey||console.error("Contact is missing pubKey:",r),r));this._contacts.next(o),e.next(o)}else e.next([]);e.complete()}).catch(n=>{console.error("Error loading cached contacts from IndexedDB:",n),e.next([]),e.complete()}),{unsubscribe(){}}))}getProfile(){var e=this;return(0,_.A)(function*(){try{e._storageService.profile$.subscribe(n=>{n&&n.pubKey&&n.metadata&&n.pubKey===e._signerService.getPublicKey()&&e._profile.next(n.metadata)}),e._storageService.getProfile(e._signerService.getPublicKey()).then(n=>{e._profile.next(n)})}catch(n){console.error("Error fetching profile metadata:",n)}})()}getChats(){var e=this;return(0,_.A)(function*(){const n=e._signerService.getPublicKey(),o=yield e._signerService.isUsingExtension(),r=yield e._signerService.isUsingSecretKey();return e.decryptedPrivateKey=r?yield e._signerService.getDecryptedSecretKey():"",yield Promise.all([e.subscribeToChatList(n,o,r,e.decryptedPrivateKey)]),e.getChatListStream()})()}subscribeToChatList(e,n,o,r){var a=this;return this._relayService.ensureConnectedRelays().then((0,_.A)(function*(){const u=[{kinds:[$.rV],authors:[e],limit:1500},{kinds:[$.rV],"#p":[e],limit:1500}];var l;a._relayService.getPool().subscribeMany(a._relayService.getConnectedRelays(),u,{onevent:(l=(0,_.A)(function*(d){const m=d.pubkey===e?d.tags.find(M=>"p"===M[0])?.[1]||"":d.pubkey;m&&d.created_at>(a.latestMessageTimestamps[m]||0)&&(a.messageQueue.push(d),a.processNextMessage(e,n,o,r))}),function(m){return l.apply(this,arguments)}),oneose:()=>{(a.chatList||[]).length>0&&a._chats.next(a.chatList)}})})),this.getChatListStream()}processNextMessage(e,n,o,r){var a=this;return(0,_.A)(function*(){if(!a.isDecrypting&&0!==a.messageQueue.length){a.isDecrypting=!0;try{for(;a.messageQueue.length>0;){const u=a.messageQueue.shift();if(!u)continue;const l=u.pubkey===e,d=l?u.tags.find(w=>"p"===w[0])?.[1]||"":u.pubkey;if(!d)continue;const m=yield a.decryptReceivedMessage(u,n,o,r,d);m&&a.addOrUpdateChatList(d,m,u.created_at,l)}}catch{}finally{a.isDecrypting=!1}}})()}addOrUpdateChatList(e,n,o,r){const a=this.chatList.find(l=>l.contact?.pubKey===e),u={id:`${e}-${o}`,chatId:e,contactId:e,isMine:r,value:n,createdAt:new Date(1e3*o).toISOString()};if(a)a.messages?.some(d=>d.id===u.id)||(a.messages=[...a.messages||[],u].sort((d,m)=>new Date(d.createdAt).getTime()-new Date(m.createdAt).getTime()),Number(a.lastMessageAt)m.pubKey===e)||{pubKey:e},d={id:e,contact:{pubKey:l.pubKey,name:l.name||"Unknown",picture:l.picture||"/images/avatars/avatar-placeholder.png",about:l.about||"",displayName:l.displayName||l.name||"Unknown"},lastMessage:n,lastMessageAt:o.toString(),messages:[u]};this.chatList.push(d)}this.chatList.sort((l,d)=>Number(d.lastMessageAt)-Number(l.lastMessageAt)),this._chats.next(this.chatList),this._storageService.profile$.pipe((0,B.p)(l=>l&&l.pubKey===e)).subscribe(l=>{const d=this.chatList.find(m=>m.contact?.pubKey===e);d&&(d.contact={...d.contact,name:l.metadata?.name||d.contact.name,picture:l.metadata?.picture||d.contact.picture,about:l.metadata?.about||d.contact.about,displayName:l.metadata?.displayName||l.metadata?.name||d.contact.displayName},this._chats.next(this.chatList))})}getChatListStream(){return this._chats.asObservable()}decryptReceivedMessage(e,n,o,r,a){var u=this;return(0,_.A)(function*(){return n&&!o?yield u._signerService.decryptMessageWithExtension(a,e.content):o&&!n?yield u._signerService.decryptMessage(r,a,e.content):void 0})()}loadAndFetchChatHistory(e,n=!1){var o=this;return(0,_.A)(function*(){const r=o._signerService.getPublicKey(),a=[{kinds:[$.rV],authors:[r],"#p":[e],limit:10},{kinds:[$.rV],authors:[e],"#p":[r],limit:10}],u=[];if(o._relayService.getPool().subscribeMany(o._relayService.getConnectedRelays(),a,{onevent:(l=(0,_.A)(function*(d){const m=d.pubkey===r,w=m?e:d.pubkey,M=yield o._signerService.isUsingExtension(),ve=yield o._signerService.isUsingSecretKey(),T=yield o.decryptReceivedMessage(d,M,ve,o.decryptedPrivateKey,w);if(T){const U=Math.floor(d.created_at),Ce={id:d.id,chatId:e,contactId:w,isMine:m,value:T,createdAt:new Date(1e3*U).toISOString()};n&&u.push(Ce),o.addOrUpdateChatList(e,T,U,m),o._chat.next(o.chatList.find(be=>be.id===e))}}),function(m){return l.apply(this,arguments)}),oneose:()=>{}}),n)return yield new Promise(l=>setTimeout(l,1e3)),u;var l})()}updateChat(e,n){return this.chats$.pipe((0,X.s)(1),(0,G.n)(o=>{const r=n.contact?.pubKey;if(!r)return(0,R.$)("No public key found for this chat");const a={kind:4,pubkey:r,content:JSON.stringify(n),created_at:Math.floor(Date.now()/1e3),tags:[["p",r]]};return a.id=(0,L.dq)(a),(0,N.H)(this._relayService.publishEventToWriteRelays(a)).pipe((0,D.T)(()=>{if(o){const u=o.findIndex(l=>l.id===e);-1!==u&&(o[u]=n,this._chats.next(o))}return n}),(0,S.W)(u=>(console.error("Failed to update chat via Nostr:",u),(0,R.$)(u))))}))}getChatById(e,n=null){return this.recipientPublicKey=e,(0,N.H)(Promise.all([this._signerService.getPublicKey()])).pipe((0,G.n)(()=>this.chats$.pipe((0,X.s)(1),(0,G.n)(o=>{if(!o||0===o.length)return this.createNewChat(e,n);const r=o.find(a=>a.id===e);return r?(this._chat.next(r),this.loadAndFetchChatHistory(this.recipientPublicKey),(0,K.of)(r)):this.createNewChat(e,n)}))),(0,S.W)(o=>(console.error("Error fetching chat by id from Nostr:",o),(0,R.$)(o))))}createNewChat(e,n=null){const o={id:e||"",contact:n?{pubKey:n.pubKey||e,name:n.name||"Unknown",picture:n.picture||"/images/avatars/avatar-placeholder.png"}:{pubKey:e,name:"Unknown",picture:"/images/avatars/avatar-placeholder.png"},lastMessage:"new chat...",lastMessageAt:Math.floor(Date.now()/1e3).toString()||"0",messages:[]};return this._metadataQueueService.addPublicKey(e),this._storageService.profile$.pipe((0,B.p)(r=>r&&r.pubKey===e),(0,D.T)(r=>(o.contact={pubKey:e,name:r.metadata?.name||"Unknown",picture:r.metadata?.picture||"/images/avatars/avatar-placeholder.png",about:r.metadata?.about||"",displayName:r.metadata?.displayName||r.metadata?.name||"Unknown"},o)))}resetChat(){this._chat.next(null)}sendPrivateMessage(e){var n=this;return(0,_.A)(function*(){try{n.message=e;const o=yield n._signerService.isUsingExtension(),r=yield n._signerService.isUsingSecretKey();if(o&&!r)yield n.handleMessageSendingWithExtension();else if(!o&&r){if(!n.isValidMessageSetup())return void console.error("Message, sender private key, or recipient public key is not properly set.");const a=yield n._signerService.encryptMessage(n.decryptedPrivateKey,n.recipientPublicKey,n.message),u=n._signerService.getUnsignedEvent(4,[["p",n.recipientPublicKey]],a),l=n._signerService.getSignedEvent(u,n.decryptedPrivateKey);(yield n._relayService.publishEventToWriteRelays(l))?n.message="":console.error("Failed to send the message.")}}catch(o){console.error("Error sending private message:",o)}})()}handleMessageSendingWithExtension(){var e=this;return(0,_.A)(function*(){try{const n=yield e._signerService.encryptMessageWithExtension(e.message,e.recipientPublicKey),o=yield e._signerService.signEventWithExtension({kind:4,pubkey:e._signerService.getPublicKey(),tags:[["p",e.recipientPublicKey]],content:n,created_at:Math.floor(Date.now()/1e3)});(yield e._relayService.publishEventToWriteRelays(o))?e.message="":console.error("Failed to send the message with extension.")}catch(n){console.error("Error sending message with extension:",n)}})()}isValidMessageSetup(){return""!==this.message.trim()&&""!==this.recipientPublicKey}ngOnDestroy(){this._unsubscribeAll.next(),this._unsubscribeAll.complete()}static{this.\u0275fac=function(n){return new(n||i)(t.KVO(H.A),t.KVO(z.n),t.KVO(W.b),t.KVO(Q.T))}}static{this.\u0275prov=t.jDH({token:i,factory:i.\u0275fac,providedIn:"root"})}}return i})();var f=c(4460),h=c(9471),p=c(6071),g=c(3904),y=c(6389),k=c(7818),C=c(5785),Z=c(9561);let J=(()=>{class i{transform(e){return/\.(jpeg|jpg|gif|png|bmp|svg|webp|tiff)$/i.test(e)?"\u{1f304} image":/\.(mp4|mov|avi|mkv|webm|flv|wmv|mpeg|3gp)$/i.test(e)?"\u{1f3ac} video":/\.(mp3|wav|ogg|m4a|aac|flac)$/i.test(e)?"\u{1f3b5} audio":/\.pdf$/i.test(e)?"\u{1f4c1} pdf":/(?:https?:\/\/)?(?:www\.)?(?:youtube\.com\/(?:[^\/\n\s]+\/\S+\/|(?:v|e(?:mbed)?)\/|\S*?[?&]v=)|youtu\.be\/)([a-zA-Z0-9_-]{11})/.test(e)?"\u{1f4fd}\ufe0f youtube":/https?:\/\/(www\.)?vimeo.com\/(\d+)/.test(e)?"\u{1f4fd}\ufe0f vimeo":/https?:\/\/(www\.)?instagram.com\/p\/[a-zA-Z0-9_-]+/.test(e)?"\u{1f52e} instagram":/https?:\/\/(www\.)?twitter.com\/[a-zA-Z0-9_]+\/status\/[0-9]+/.test(e)?"\u{1f426} twitter":/(https?:\/\/[^\s]+)/.test(e)?"\u{1f310} url":e}static{this.\u0275fac=function(n){return new(n||i)}}static{this.\u0275pipe=t.EJ8({name:"checkmessage",type:i,pure:!0})}}return i})();var j=c(5424);function q(i,s){if(1&i){const e=t.RV6();t.j41(0,"div",15),t.bIt("click",function(){t.eBV(e);const o=t.XpG().$implicit,r=t.XpG(2);return t.Njj(r.openChat(o))}),t.EFF(1),t.k0s()}if(2&i){const e=t.XpG().$implicit;t.R7$(),t.SpI(" ",e.name.charAt(0)," ")}}function tt(i,s){if(1&i&&t.nrm(0,"img",10),2&i){const e=t.XpG().$implicit;t.Y8G("src",e.picture,t.B4B)}}function et(i,s){if(1&i&&(t.j41(0,"div",11),t.EFF(1),t.k0s()),2&i){const e=t.XpG().$implicit;t.R7$(),t.SpI(" ",e.name.charAt(0)," ")}}function nt(i,s){if(1&i){const e=t.RV6();t.DNE(0,q,2,1,"div",7),t.j41(1,"div",8),t.bIt("click",function(){const o=t.eBV(e).$implicit,r=t.XpG(2);return t.Njj(r.openChat(o))}),t.j41(2,"div",9),t.DNE(3,tt,1,1,"img",10)(4,et,2,1,"div",11),t.k0s(),t.j41(5,"div",12)(6,"div",13),t.EFF(7),t.k0s(),t.j41(8,"div",14),t.EFF(9),t.k0s()()()}if(2&i){const e=s.$implicit,n=s.$index,o=t.XpG(2);t.vxM(0===n||e.name.charAt(0)!==o.contacts[n-1].name.charAt(0)?0:-1),t.R7$(3),t.vxM(e.picture?3:-1),t.R7$(),t.vxM(e.picture?-1:4),t.R7$(3),t.SpI(" ",e.name," "),t.R7$(2),t.SpI(" ",e.about," ")}}function it(i,s){if(1&i&&t.Z7z(0,nt,10,5,null,null,t.BUC().trackByFn,!0),2&i){const e=t.XpG();t.Dyx(e.contacts)}}function ot(i,s){1&i&&(t.j41(0,"div",6),t.EFF(1," There are no contacts! "),t.k0s())}let rt=(()=>{class i{constructor(e,n){this._chatService=e,this.router=n,this.contacts=[],this._unsubscribeAll=new I.B}ngOnInit(){this._chatService.contacts$.pipe((0,j.Q)(this._unsubscribeAll)).subscribe(e=>{this.contacts=e})}ngOnDestroy(){this._unsubscribeAll.next(null),this._unsubscribeAll.complete()}trackByFn(e,n){return n.id||e}openChat(e){this._chatService.getChatById(e.pubKey,e).subscribe({next:n=>{console.log("Chat loaded or created:",n),this.router.navigate(["/chat",e.pubKey])},error:n=>{console.error("Error loading or creating chat:",n)},complete:()=>{this.drawer.close()}})}static{this.\u0275fac=function(n){return new(n||i)(t.rXU(x),t.rXU(v.Ix))}}static{this.\u0275cmp=t.VBU({type:i,selectors:[["chat-new-chat"]],inputs:{drawer:"drawer"},decls:9,vars:2,consts:[[1,"bg-card","flex","h-full","flex-auto","flex-col","overflow-hidden","dark:bg-default"],[1,"-mb-px","flex","h-18","flex-0","items-center","bg-gray-50","px-6","dark:bg-transparent"],["mat-icon-button","",3,"click"],[3,"svgIcon"],[1,"ml-2","text-2xl","font-semibold"],[1,"relative","overflow-y-auto"],[1,"border-t","p-8","text-center","text-4xl","font-semibold","tracking-tight","sm:p-16"],[1,"text-secondary","sticky","top-0","z-10","-mt-px","border-b","border-t","bg-gray-100","px-6","py-1","font-medium","uppercase","dark:bg-gray-900","md:px-8"],[1,"z-20","flex","cursor-pointer","items-center","border-b","px-6","py-4","dark:hover:bg-hover","hover:bg-gray-100","md:px-8",3,"click"],[1,"flex","h-10","w-10","flex-0","items-center","justify-center","overflow-hidden","rounded-full"],["onerror","this.onerror=null; this.src='/images/avatars/avatar-placeholder.png';","alt","Contact picture",1,"h-full","w-full","object-cover",3,"src"],[1,"flex","h-full","w-full","items-center","justify-center","rounded-full","bg-gray-200","text-lg","uppercase","text-gray-600","dark:bg-gray-700","dark:text-gray-200"],[1,"ml-4","min-w-0"],[1,"truncate","font-medium","leading-5"],[1,"text-secondary","truncate","leading-5"],[1,"text-secondary","sticky","top-0","z-10","-mt-px","border-b","border-t","bg-gray-100","px-6","py-1","font-medium","uppercase","dark:bg-gray-900","md:px-8",3,"click"]],template:function(n,o){1&n&&(t.j41(0,"div",0)(1,"div",1)(2,"button",2),t.bIt("click",function(){return o.drawer.close()}),t.nrm(3,"mat-icon",3),t.k0s(),t.j41(4,"div",4),t.EFF(5,"New chat"),t.k0s()(),t.j41(6,"div",5),t.DNE(7,it,2,0)(8,ot,2,0,"div",6),t.k0s()()),2&n&&(t.R7$(3),t.Y8G("svgIcon","heroicons_outline:arrow-long-left"),t.R7$(4),t.vxM(o.contacts.length?7:8))},dependencies:[h.Hl,h.iY,g.m_,g.An],encapsulation:2,changeDetection:0})}}return i})();var b=c(936);function st(i,s){if(1&i&&t.nrm(0,"img",10),2&i){const e=t.XpG();t.Y8G("src",e.profile.picture,t.B4B)("alt","Profile picture")}}function at(i,s){if(1&i&&(t.j41(0,"div",11),t.EFF(1),t.k0s()),2&i){const e=t.XpG();t.R7$(),t.SpI(" ",e.profile.name.charAt(0)," ")}}let ct=(()=>{class i{constructor(e){this._chatService=e,this._unsubscribeAll=new I.B}ngOnInit(){this._chatService.profile$.pipe((0,j.Q)(this._unsubscribeAll)).subscribe(e=>{this.profile=e})}ngOnDestroy(){this._unsubscribeAll.next(null),this._unsubscribeAll.complete()}static{this.\u0275fac=function(n){return new(n||i)(t.rXU(x))}}static{this.\u0275cmp=t.VBU({type:i,selectors:[["chat-profile"]],inputs:{drawer:"drawer"},decls:35,vars:11,consts:[[1,"bg-card","flex","flex-auto","flex-col","overflow-y-auto","dark:bg-default"],[1,"flex","h-18","flex-0","items-center","border-b","bg-gray-50","px-6","dark:bg-transparent"],["mat-icon-button","",3,"click"],[3,"svgIcon"],[1,"ml-2","text-2xl","font-semibold"],[1,"px-6"],[1,"group","relative","mx-auto","mt-8","flex","h-40","w-40","flex-0","rounded-full"],[1,"absolute","inset-0","hidden","cursor-pointer","flex-col","items-center","justify-center","rounded-full","bg-gray-800","bg-opacity-80","backdrop-blur","backdrop-filter","group-hover:flex"],[1,"text-white",3,"svgIcon"],[1,"mx-6","mt-2","text-center","font-medium","text-white"],["onerror","this.onerror=null; this.src='/images/avatars/avatar-placeholder.png';",1,"h-full","w-full","rounded-full","object-cover",3,"src","alt"],[1,"flex","h-full","w-full","items-center","justify-center","rounded-full","bg-gray-200","text-8xl","font-semibold","uppercase","text-gray-600","dark:bg-gray-700","dark:text-gray-200"],[1,"mx-2","mt-8","flex","flex-col"],["matPrefix","",1,"icon-size-5",3,"svgIcon"],["matInput","",3,"ngModel"],[1,"mt-4","flex","items-center","justify-end"],["mat-button","",3,"click"],["mat-flat-button","",1,"ml-2",3,"color"]],template:function(n,o){1&n&&(t.j41(0,"div",0)(1,"div",1)(2,"button",2),t.bIt("click",function(){return o.drawer.close()}),t.nrm(3,"mat-icon",3),t.k0s(),t.j41(4,"div",4),t.EFF(5,"Profile"),t.k0s()(),t.j41(6,"div",5)(7,"div",6)(8,"div",7),t.nrm(9,"mat-icon",8),t.j41(10,"div",9),t.EFF(11," Change Profile Photo "),t.k0s()(),t.DNE(12,st,1,2,"img",10)(13,at,2,1,"div",11),t.k0s(),t.j41(14,"div",12)(15,"mat-form-field")(16,"mat-label"),t.EFF(17,"Name"),t.k0s(),t.nrm(18,"mat-icon",13)(19,"input",14),t.k0s(),t.j41(20,"mat-form-field")(21,"mat-label"),t.EFF(22,"Username"),t.k0s(),t.nrm(23,"mat-icon",13)(24,"input",14),t.k0s(),t.j41(25,"mat-form-field")(26,"mat-label"),t.EFF(27,"About"),t.k0s(),t.nrm(28,"mat-icon",13)(29,"input",14),t.k0s(),t.j41(30,"div",15)(31,"button",16),t.bIt("click",function(){return o.drawer.close()}),t.EFF(32,"Cancel"),t.k0s(),t.j41(33,"button",17),t.EFF(34," Save "),t.k0s()()()()()),2&n&&(t.R7$(3),t.Y8G("svgIcon","heroicons_outline:arrow-long-left"),t.R7$(6),t.Y8G("svgIcon","heroicons_outline:camera"),t.R7$(3),t.vxM(o.profile.picture?12:-1),t.R7$(),t.vxM(o.profile.picture?-1:13),t.R7$(5),t.Y8G("svgIcon","heroicons_solid:user-circle"),t.R7$(),t.Y8G("ngModel",o.profile.name),t.R7$(4),t.Y8G("svgIcon","heroicons_solid:envelope"),t.R7$(),t.Y8G("ngModel",o.profile.username),t.R7$(4),t.Y8G("svgIcon","heroicons_solid:identification"),t.R7$(),t.Y8G("ngModel",o.profile.about),t.R7$(4),t.Y8G("color","primary"))},dependencies:[h.Hl,h.$z,h.iY,g.m_,g.An,p.RG,p.rl,p.nJ,p.JW,y.fS,y.fg,b.YN,b.me,b.BC,b.vS],encapsulation:2,changeDetection:0})}}return i})();var lt=c(3871);const dt=(i,s)=>({"dark:hover:bg-hover hover:bg-gray-100":i,"bg-primary-50 dark:bg-hover":s}),ut=i=>[i],mt=(i,s)=>({"absolute inset-0 z-20 flex lg:static lg:inset-auto":i,"hidden lg:flex":s});function ht(i,s){if(1&i&&t.nrm(0,"chat-new-chat",6),2&i){t.XpG();const e=t.sdS(3);t.Y8G("drawer",e)}}function pt(i,s){if(1&i&&t.nrm(0,"chat-profile",6),2&i){t.XpG();const e=t.sdS(3);t.Y8G("drawer",e)}}function gt(i,s){if(1&i&&t.nrm(0,"img",15),2&i){const e=t.XpG(2);t.Y8G("src",null==e.profile?null:e.profile.picture,t.B4B)}}function ft(i,s){if(1&i&&(t.j41(0,"div",16),t.EFF(1),t.k0s()),2&i){const e=t.XpG(2);t.R7$(),t.SpI(" ",null==e.profile||null==e.profile.name?null:e.profile.name.charAt(0)," ")}}function _t(i,s){if(1&i&&t.nrm(0,"div",39),2&i){const e=t.XpG().$implicit,n=t.XpG(3);t.AVh("ring-primary-50",n.selectedChat&&n.selectedChat.id===e.id)}}function vt(i,s){if(1&i){const e=t.RV6();t.j41(0,"img",40),t.bIt("error",function(){t.eBV(e);const o=t.XpG(4);return t.Njj(o.src="/images/avatars/avatar-placeholder.png")}),t.k0s()}if(2&i){const e=t.XpG().$implicit;t.Y8G("src",null==e.contact?null:e.contact.picture,t.B4B)}}function Ct(i,s){if(1&i&&(t.j41(0,"div",16),t.EFF(1),t.k0s()),2&i){const e=t.XpG().$implicit;t.R7$(),t.SpI(" ",null==e.contact||null==e.contact.name?null:e.contact.name.charAt(0)," ")}}function bt(i,s){1&i&&t.nrm(0,"mat-icon",38),2&i&&t.Y8G("svgIcon","heroicons_solid:speaker-x-mark")}function xt(i,s){if(1&i&&(t.j41(0,"a",28)(1,"div",29),t.DNE(2,_t,1,2,"div",30)(3,vt,1,1,"img",31)(4,Ct,2,1,"div",32),t.k0s(),t.j41(5,"div",33)(6,"div",34),t.EFF(7),t.k0s(),t.j41(8,"div",35),t.EFF(9),t.nI1(10,"checkmessage"),t.k0s()(),t.j41(11,"div",36)(12,"div",37),t.EFF(13),t.nI1(14,"ago"),t.k0s(),t.DNE(15,bt,1,1,"mat-icon",38),t.k0s()()),2&i){const e=s.$implicit,n=t.XpG(3);t.Y8G("ngClass",t.l_i(17,dt,!n.selectedChat||n.selectedChat.id!==e.id,n.selectedChat&&n.selectedChat.id===e.id))("routerLink",t.eq3(20,ut,e.id)),t.R7$(2),t.vxM(e.unreadCount>0?2:-1),t.R7$(),t.Y8G("ngIf",null==e.contact?null:e.contact.picture),t.R7$(),t.Y8G("ngIf",!(null!=e.contact&&e.contact.picture)),t.R7$(3),t.SpI(" ",null==e.contact?null:e.contact.name," "),t.R7$(),t.AVh("text-primary",e.unreadCount>0)("dark:text-primary-500",e.unreadCount>0),t.R7$(),t.SpI(" ",t.bMT(10,13,e.lastMessage)," "),t.R7$(4),t.SpI(" ",t.bMT(14,15,e.lastMessageAt)," "),t.R7$(2),t.vxM(e.muted?15:-1)}}function yt(i,s){if(1&i&&t.Z7z(0,xt,16,22,"a",28,t.BUC().trackByFn,!0),2&i){const e=t.XpG(2);t.Dyx(e.filteredChats)}}function kt(i,s){1&i&&(t.j41(0,"div",9),t.nrm(1,"mat-icon",41),t.j41(2,"div",42),t.EFF(3," No chats "),t.k0s()()),2&i&&(t.R7$(),t.Y8G("svgIcon","heroicons_outline:chat-bubble-oval-left-ellipsis"))}function wt(i,s){if(1&i){const e=t.RV6();t.j41(0,"div",8)(1,"div",11)(2,"div",12)(3,"div",13),t.bIt("click",function(){t.eBV(e);const o=t.XpG();return t.Njj(o.openProfile())}),t.j41(4,"div",14),t.DNE(5,gt,1,1,"img",15)(6,ft,2,1,"div",16),t.k0s(),t.j41(7,"div",17),t.EFF(8),t.k0s()(),t.j41(9,"button",18),t.bIt("click",function(){t.eBV(e);const o=t.XpG();return t.Njj(o.openNewChat())}),t.nrm(10,"mat-icon",19),t.k0s(),t.j41(11,"button",20),t.nrm(12,"mat-icon",19),t.j41(13,"mat-menu",null,1)(15,"button",21),t.nrm(16,"mat-icon",19),t.EFF(17," New group "),t.k0s(),t.j41(18,"button",21),t.nrm(19,"mat-icon",19),t.EFF(20," Create a room "),t.k0s(),t.j41(21,"button",22),t.bIt("click",function(){t.eBV(e);const o=t.XpG();return t.Njj(o.openProfile())}),t.nrm(22,"mat-icon",19),t.EFF(23," Profile "),t.k0s(),t.j41(24,"button",21),t.nrm(25,"mat-icon",19),t.EFF(26," Archived "),t.k0s(),t.j41(27,"button",21),t.nrm(28,"mat-icon",19),t.EFF(29," Starred "),t.k0s(),t.j41(30,"button",21),t.nrm(31,"mat-icon",19),t.EFF(32," Settings "),t.k0s()()()(),t.j41(33,"div",23)(34,"mat-form-field",24),t.nrm(35,"mat-icon",25),t.j41(36,"input",26,2),t.bIt("input",function(){t.eBV(e);const o=t.sdS(37),r=t.XpG();return t.Njj(r.filterChats(o.value))}),t.k0s()()()(),t.j41(38,"div",27),t.DNE(39,yt,2,0)(40,kt,4,1,"div",9),t.k0s()()}if(2&i){const e=t.sdS(14),n=t.XpG();t.R7$(5),t.vxM(null!=n.profile&&n.profile.picture?5:-1),t.R7$(),t.vxM(null!=n.profile&&n.profile.picture?-1:6),t.R7$(2),t.SpI(" ",null==n.profile?null:n.profile.name," "),t.R7$(2),t.Y8G("svgIcon","heroicons_outline:plus-circle"),t.R7$(),t.Y8G("matMenuTriggerFor",e),t.R7$(),t.Y8G("svgIcon","heroicons_outline:ellipsis-vertical"),t.R7$(4),t.Y8G("svgIcon","heroicons_outline:user-group"),t.R7$(3),t.Y8G("svgIcon","heroicons_outline:chat-bubble-left-right"),t.R7$(3),t.Y8G("svgIcon","heroicons_outline:user-circle"),t.R7$(3),t.Y8G("svgIcon","heroicons_outline:archive-box"),t.R7$(3),t.Y8G("svgIcon","heroicons_outline:star"),t.R7$(3),t.Y8G("svgIcon","heroicons_outline:cog-8-tooth"),t.R7$(3),t.Y8G("subscriptSizing","dynamic"),t.R7$(),t.Y8G("svgIcon","heroicons_solid:magnifying-glass"),t.R7$(),t.Y8G("autocomplete","off")("placeholder","Search or start new chat"),t.R7$(3),t.vxM(n.filteredChats.length>0?39:40)}}function jt(i,s){1&i&&(t.j41(0,"div",9),t.nrm(1,"mat-icon",41),t.j41(2,"div",42),t.EFF(3," No chats "),t.k0s()()),2&i&&(t.R7$(),t.Y8G("svgIcon","heroicons_outline:chat-bubble-oval-left-ellipsis"))}function Ft(i,s){if(1&i&&(t.j41(0,"div",10),t.nrm(1,"router-outlet"),t.k0s()),2&i){const e=t.XpG();t.Y8G("ngClass",t.l_i(1,mt,e.selectedChat&&e.selectedChat.id,!e.selectedChat||!e.selectedChat.id))}}let It=(()=>{class i{constructor(e,n,o,r){this._chatService=e,this._changeDetectorRef=n,this.route=o,this._angorNavigationService=r,this.chats=[],this.filteredChats=[],this.drawerOpened=!1,this._unsubscribeAll=new I.B}updateNavigationBadge(){const e=this._angorNavigationService.getComponent("mainNavigation");e&&(this._angorNavigationService.getItem("chat",e.navigation).badge.title="0",e.refresh())}ngOnInit(){this.updateNavigationBadge(),this._chatService.chats$.pipe((0,j.Q)(this._unsubscribeAll)).subscribe(n=>{this.chats=this.filteredChats=n,this._markForCheck()}),this._chatService.profile$.pipe((0,j.Q)(this._unsubscribeAll)).subscribe(n=>{this.profile=n,this._markForCheck()}),this._chatService.chat$.pipe((0,j.Q)(this._unsubscribeAll)).subscribe(n=>{this.selectedChat=n,this._markForCheck()});const e=localStorage.getItem("currentChatId");e&&this._chatService.checkCurrentChatOnPageRefresh(e)}ngOnDestroy(){this._unsubscribeAll.next(),this._unsubscribeAll.complete(),this._chatService.resetChat(),localStorage.removeItem("currentChatId")}filterChats(e){if(e){const n=e.toLowerCase();this.filteredChats=this.chats.filter(o=>o.contact?.name.toLowerCase().includes(n))}else this.filteredChats=this.chats;this._markForCheck()}openNewChat(){this.drawerComponent="new-chat",this.drawerOpened=!0,this._markForCheck()}openProfile(){this.drawerComponent="profile",this.drawerOpened=!0,this._markForCheck()}trackByFn(e,n){return n.id||e}_markForCheck(){this._changeDetectorRef.markForCheck()}static{this.\u0275fac=function(n){return new(n||i)(t.rXU(x),t.rXU(t.gRc),t.rXU(v.nX),t.rXU(lt.lX))}}static{this.\u0275cmp=t.VBU({type:i,selectors:[["chat-chats"]],decls:10,vars:7,consts:[["drawer",""],["chatsHeaderMenu",""],["searchField",""],[1,"bg-card","relative","flex","w-full","flex-auto","dark:bg-transparent"],[1,"h-full","flex-auto",3,"hasBackdrop"],[1,"w-full","dark:bg-gray-900","sm:w-100","lg:border-r","lg:shadow-none",3,"openedChange","autoFocus","opened"],[3,"drawer"],[1,"flex","overflow-hidden"],[1,"bg-card","relative","flex","w-full","min-w-0","flex-auto","flex-col","dark:bg-transparent","lg:min-w-100","lg:max-w-100"],[1,"flex","h-full","flex-auto","flex-col","items-center","justify-center"],[1,"flex-auto","border-l",3,"ngClass"],[1,"flex","flex-0","flex-col","border-b","bg-gray-50","px-8","py-4","dark:bg-transparent"],[1,"flex","items-center"],[1,"mr-1","flex","cursor-pointer","items-center",3,"click"],[1,"h-10","w-10"],["onerror","this.onerror=null; this.src='/images/avatars/avatar-placeholder.png';","alt","Profile picture",1,"h-full","w-full","rounded-full","object-cover",3,"src"],[1,"flex","h-full","w-full","items-center","justify-center","rounded-full","bg-gray-200","text-lg","uppercase","text-gray-600","dark:bg-gray-700","dark:text-gray-200"],[1,"ml-4","truncate","font-medium"],["mat-icon-button","",1,"ml-auto",3,"click"],[3,"svgIcon"],["mat-icon-button","",1,"-mr-4","ml-1",3,"matMenuTriggerFor"],["mat-menu-item",""],["mat-menu-item","",3,"click"],[1,"mt-4"],[1,"angor-mat-rounded","angor-mat-dense","w-full",3,"subscriptSizing"],["matPrefix","",1,"icon-size-5",3,"svgIcon"],["matInput","",3,"input","autocomplete","placeholder"],[1,"flex-auto","overflow-y-auto"],[1,"z-20","flex","cursor-pointer","items-center","border-b","px-8","py-5",3,"ngClass","routerLink"],[1,"relative","flex","h-10","w-10","flex-0","items-center","justify-center"],[1,"ring-bg-card","absolute","bottom-0","right-0","-ml-0.5","h-2","w-2","flex-0","rounded-full","bg-primary","text-on-primary","ring-2","dark:bg-primary-500","dark:ring-gray-900",3,"ring-primary-50"],["class","h-full w-full rounded-full object-cover","alt","Contact picture",3,"src","error",4,"ngIf"],["class","flex h-full w-full items-center justify-center rounded-full bg-gray-200 text-lg uppercase text-gray-600 dark:bg-gray-700 dark:text-gray-200",4,"ngIf"],[1,"ml-4","min-w-0"],[1,"truncate","font-medium","leading-5"],[1,"text-secondary","truncate","leading-5"],[1,"ml-auto","flex","flex-col","items-end","self-start","pl-2"],[1,"text-secondary","overflow-hidden","whitespace-nowrap","text-sm","leading-5"],[1,"text-hint","icon-size-5",3,"svgIcon"],[1,"ring-bg-card","absolute","bottom-0","right-0","-ml-0.5","h-2","w-2","flex-0","rounded-full","bg-primary","text-on-primary","ring-2","dark:bg-primary-500","dark:ring-gray-900"],["alt","Contact picture",1,"h-full","w-full","rounded-full","object-cover",3,"error","src"],[1,"icon-size-24",3,"svgIcon"],[1,"text-secondary","mt-4","text-2xl","font-semibold","tracking-tight"]],template:function(n,o){if(1&n){const r=t.RV6();t.j41(0,"div",3)(1,"mat-drawer-container",4)(2,"mat-drawer",5,0),t.mxI("openedChange",function(u){return t.eBV(r),t.DH7(o.drawerOpened,u)||(o.drawerOpened=u),t.Njj(u)}),t.DNE(4,ht,1,1,"chat-new-chat",6)(5,pt,1,1,"chat-profile",6),t.k0s(),t.j41(6,"mat-drawer-content",7),t.DNE(7,wt,41,17,"div",8)(8,jt,4,1,"div",9)(9,Ft,2,4,"div",10),t.k0s()()()}2&n&&(t.R7$(),t.Y8G("hasBackdrop",!1),t.R7$(),t.Y8G("autoFocus",!1),t.R50("opened",o.drawerOpened),t.R7$(2),t.vxM("new-chat"===o.drawerComponent?4:-1),t.R7$(),t.vxM("profile"===o.drawerComponent?5:-1),t.R7$(2),t.vxM(o.chats&&o.chats.length>0?7:8),t.R7$(2),t.vxM(o.chats&&o.chats.length>0?9:-1))},dependencies:[C.vg,C.qe,C.$C,C.$l,rt,ct,h.Hl,h.iY,g.m_,g.An,k.Cn,k.kk,k.fb,k.Cp,p.RG,p.rl,p.JW,y.fS,y.fg,f.YU,v.Wk,v.n3,Z.g,f.MD,f.bT,J],encapsulation:2,changeDetection:0})}}return i})(),Rt=(()=>{class i{constructor(){}static{this.\u0275fac=function(n){return new(n||i)}}static{this.\u0275cmp=t.VBU({type:i,selectors:[["chat-empty-conversation"]],decls:5,vars:1,consts:[[1,"bg-card","flex","flex-auto","flex-col","overflow-y-auto","dark:bg-default","lg:overflow-hidden"],[1,"flex","flex-auto","flex-col","items-center","justify-center","bg-gray-100","dark:bg-transparent"],[1,"icon-size-24",3,"svgIcon"],[1,"text-secondary","mt-4","text-2xl","font-semibold","tracking-tight"]],template:function(n,o){1&n&&(t.j41(0,"div",0)(1,"div",1),t.nrm(2,"mat-icon",2),t.j41(3,"div",3),t.EFF(4," Select a conversation or start a new chat "),t.k0s()()()),2&n&&(t.R7$(2),t.Y8G("svgIcon","heroicons_outline:chat-bubble-oval-left-ellipsis"))},dependencies:[g.m_,g.An],encapsulation:2,changeDetection:0})}}return i})();var A=c(708),$t=c(1556),E=c(7544),Gt=c(4375),P=c(7691);let St=(()=>{class i{constructor(e){this.http=e}getTopGifs(e,n){const r=(new P.Nl).append("key",n).append("q",e);return this.http.get("https://g.tenor.com/v1/search",{params:r})}static{this.\u0275fac=function(n){return new(n||i)(t.KVO(P.Qq))}}static{this.\u0275prov=t.jDH({token:i,factory:i.\u0275fac,providedIn:"root"})}}return i})();function Et(i,s){if(1&i){const e=t.RV6();t.j41(0,"div",8),t.bIt("click",function(){const o=t.eBV(e).$implicit,r=t.XpG(2);return t.Njj(r.selectGif(o))}),t.nrm(1,"img",9),t.k0s()}if(2&i){const e=s.$implicit;t.R7$(),t.Y8G("src",e,t.B4B)}}function Mt(i,s){if(1&i&&(t.j41(0,"div",6),t.DNE(1,Et,2,1,"div",7),t.k0s()),2&i){const e=t.XpG();t.R7$(),t.Y8G("ngForOf",e.gifsFound)}}let Tt=(()=>{class i{constructor(e,n,o,r){this.gifService=e,this.dialogRef=n,this._changeDetectorRef=o,this.data=r,this.gifSearch="",this.gifsFound=[]}searchGif(){this.gifSearch&&""!==this.gifSearch.trim()?this.data.apiKey?this.gifService.getTopGifs(this.gifSearch,this.data.apiKey).subscribe(e=>{this.gifsFound=e.results.map(n=>n.media[0].gif.url),this._changeDetectorRef.detectChanges()},e=>{console.error("Error fetching GIFs:",e)}):console.error("API key is missing."):console.error("Search term is empty.")}selectGif(e){this.dialogRef.close(e)}closeDialog(){this.dialogRef.close()}static{this.\u0275fac=function(n){return new(n||i)(t.rXU(St),t.rXU(E.CP),t.rXU(t.gRc),t.rXU(E.Vh))}}static{this.\u0275cmp=t.VBU({type:i,selectors:[["gif-dialog"]],decls:10,vars:3,consts:[["mat-dialog-content",""],["appearance","outline",1,"full-width"],["matInput","","placeholder","keyword...",3,"ngModelChange","keyup.enter","ngModel"],["mat-icon-button","","matSuffix","",1,"ml-2","mr-2",3,"click"],[3,"svgIcon"],["class","results-container mt-4 grid grid-cols-3 gap-4",4,"ngIf"],[1,"results-container","mt-4","grid","grid-cols-3","gap-4"],["class","gif-preview h-24 w-full cursor-pointer",3,"click",4,"ngFor","ngForOf"],[1,"gif-preview","h-24","w-full","cursor-pointer",3,"click"],[1,"h-full","w-full","object-cover",3,"src"]],template:function(n,o){1&n&&(t.j41(0,"div",0)(1,"mat-form-field",1)(2,"mat-label"),t.EFF(3,"Search GIF"),t.k0s(),t.j41(4,"input",2),t.mxI("ngModelChange",function(a){return t.DH7(o.gifSearch,a)||(o.gifSearch=a),a}),t.bIt("keyup.enter",function(){return o.searchGif()}),t.k0s(),t.j41(5,"button",3),t.bIt("click",function(){return o.searchGif()}),t.nrm(6,"mat-icon",4),t.k0s(),t.j41(7,"mat-hint"),t.EFF(8,'Enter a keyword like "funny" or "cat" and hit search!'),t.k0s()(),t.DNE(9,Mt,2,1,"div",5),t.k0s()),2&n&&(t.R7$(4),t.R50("ngModel",o.gifSearch),t.R7$(2),t.Y8G("svgIcon","heroicons_outline:magnifying-glass"),t.R7$(3),t.Y8G("ngIf",o.gifsFound.length>0))},dependencies:[C.vg,h.Hl,h.iY,g.m_,g.An,b.YN,b.me,b.BC,b.vS,p.nJ,p.rl,b.X1,f.MD,f.Sq,f.bT,Gt.Ve,p.MV,p.yw,p.RG,y.fS,y.fg],styles:[".full-width[_ngcontent-%COMP%]{width:100%}.results-container[_ngcontent-%COMP%]{max-height:300px;overflow-y:auto;overflow-x:hidden}.gif-preview[_ngcontent-%COMP%]{transition:transform .2s}.gif-preview[_ngcontent-%COMP%]:hover{transform:scale(1.1)}"],changeDetection:0})}}return i})();const Yt=i=>["/profile",i];function Nt(i,s){if(1&i&&t.nrm(0,"img",8),2&i){const e=t.XpG();t.Y8G("src",null==e.chat.contact?null:e.chat.contact.picture,t.B4B)("alt","Contact picture")}}function Bt(i,s){if(1&i&&(t.j41(0,"div",9),t.EFF(1),t.k0s()),2&i){const e=t.XpG();t.R7$(),t.SpI(" ",null==e.chat.contact?null:e.chat.contact.name.charAt(0)," ")}}let Xt=(()=>{class i{constructor(){}static{this.\u0275fac=function(n){return new(n||i)}}static{this.\u0275cmp=t.VBU({type:i,selectors:[["chat-contact-info"]],inputs:{chat:"chat",drawer:"drawer"},decls:16,vars:8,consts:[[1,"bg-card","flex","h-full","flex-auto","flex-col","dark:bg-default"],[1,"flex","h-18","flex-0","items-center","border-b","bg-gray-50","px-4","dark:bg-transparent"],["mat-icon-button","",3,"click"],[3,"svgIcon"],[1,"ml-2","text-lg","font-medium"],[1,"overflow-y-auto"],[1,"mt-8","flex","flex-col","items-center"],[1,"h-40","w-40","rounded-full"],["onerror","this.onerror=null; this.src='/images/avatars/avatar-placeholder.png';",1,"h-full","w-full","rounded-full","object-cover",3,"src","alt"],[1,"flex","h-full","w-full","items-center","justify-center","rounded-full","bg-gray-200","text-8xl","font-semibold","uppercase","text-gray-600","dark:bg-gray-700","dark:text-gray-200"],[1,"mt-4","text-lg","font-medium"],[3,"routerLink"],[1,"text-secondary","ml-4","mr-4","mt-0.5","text-md"]],template:function(n,o){1&n&&(t.j41(0,"div",0)(1,"div",1)(2,"button",2),t.bIt("click",function(){return o.drawer.close()}),t.nrm(3,"mat-icon",3),t.k0s(),t.j41(4,"div",4),t.EFF(5,"Contact info"),t.k0s()(),t.j41(6,"div",5)(7,"div",6)(8,"div",7),t.DNE(9,Nt,1,2,"img",8)(10,Bt,2,1,"div",9),t.k0s(),t.j41(11,"div",10)(12,"a",11),t.EFF(13),t.k0s()(),t.j41(14,"div",12),t.EFF(15),t.k0s()()()()),2&n&&(t.R7$(3),t.Y8G("svgIcon","heroicons_outline:x-mark"),t.R7$(6),t.vxM(null!=o.chat.contact&&o.chat.contact.picture?9:-1),t.R7$(),t.vxM(null!=o.chat.contact&&o.chat.contact.picture?-1:10),t.R7$(2),t.Y8G("routerLink",t.eq3(6,Yt,null==o.chat.contact?null:o.chat.contact.pubKey)),t.R7$(),t.SpI(" ",null==o.chat.contact?null:o.chat.contact.name," "),t.R7$(2),t.SpI(" ",null==o.chat.contact?null:o.chat.contact.about," "))},dependencies:[h.Hl,h.iY,g.m_,g.An,v.iI,v.Wk],encapsulation:2,changeDetection:0})}}return i})();var Dt=c(2012),At=c(1109),Pt=c(6388),Ut=c(9207);const Ot=["messageInput"],Vt=()=>["./"],Kt=i=>({active:i}),Lt=(i,s,e,n)=>({"items-end":i,"items-start":s,"mt-0.5":e,"mt-3":n}),Ht=(i,s)=>({"bg-gray-400 text-blue-50":i,"bg-gray-500 text-gray-50":s}),zt=(i,s)=>({"-right-1 -mr-px mb-px text-gray-400":i,"-left-1 -ml-px mb-px -scale-x-1 text-gray-500":s}),Wt=(i,s)=>({"mr-3":i,"ml-3":s});function Qt(i,s){if(1&i&&t.nrm(0,"img",15),2&i){const e=t.XpG(2);t.Y8G("src",null==e.chat.contact?null:e.chat.contact.picture,t.B4B)}}function Zt(i,s){if(1&i&&(t.j41(0,"div",16),t.EFF(1),t.k0s()),2&i){const e=t.XpG(2);t.R7$(),t.SpI(" ",null==e.chat.contact?null:e.chat.contact.name.charAt(0)," ")}}function Jt(i,s){1&i&&(t.nrm(0,"mat-icon",12),t.EFF(1," Mute notifications ")),2&i&&t.Y8G("svgIcon","heroicons_outline:speaker-x-mark")}function qt(i,s){1&i&&(t.nrm(0,"mat-icon",12),t.EFF(1," Unmute notifications ")),2&i&&t.Y8G("svgIcon","heroicons_outline:speaker-wave")}function te(i,s){if(1&i&&(t.j41(0,"div",31),t.nrm(1,"div",33),t.j41(2,"div",34),t.EFF(3),t.nI1(4,"date"),t.k0s(),t.nrm(5,"div",33),t.k0s()),2&i){const e=t.XpG().$implicit;t.R7$(3),t.SpI(" ",t.i5U(4,1,e.createdAt,"longDate")," ")}}function ee(i,s){1&i&&t.eu8(0)}function ne(i,s){if(1&i&&(t.j41(0,"div",37),t.DNE(1,ee,1,0,"ng-container",40),t.k0s()),2&i){const e=t.XpG(2).$implicit;t.XpG(2);const n=t.sdS(4);t.Y8G("ngClass",t.l_i(2,zt,e.isMine,!e.isMine)),t.R7$(),t.Y8G("ngTemplateOutlet",n)}}function ie(i,s){if(1&i&&(t.j41(0,"div",44),t.nrm(1,"iframe",45),t.k0s()),2&i){const e=t.XpG().$implicit;t.R7$(),t.Y8G("src",e.safeWord,t.f$h)}}function oe(i,s){if(1&i&&(t.j41(0,"div",44),t.nrm(1,"img",46),t.k0s()),2&i){const e=t.XpG().$implicit;t.R7$(),t.Y8G("src",e.safeWord,t.B4B)}}function re(i,s){if(1&i&&(t.j41(0,"div",44)(1,"video",47),t.nrm(2,"source",48),t.EFF(3," Your browser does not support the video tag. "),t.k0s()()),2&i){const e=t.XpG().$implicit;t.R7$(2),t.Y8G("src",e.safeWord,t.B4B)}}function se(i,s){if(1&i&&(t.j41(0,"div",44)(1,"audio",49),t.nrm(2,"source",50),t.EFF(3," Your browser does not support the audio element. "),t.k0s()()),2&i){const e=t.XpG().$implicit;t.R7$(2),t.Y8G("src",e.safeWord,t.B4B)}}function ae(i,s){if(1&i&&(t.j41(0,"div",51)(1,"a",52),t.EFF(2),t.k0s()()),2&i){const e=t.XpG().$implicit;t.R7$(),t.Y8G("href",e.word,t.B4B),t.R7$(),t.JRh(e.word)}}function ce(i,s){if(1&i&&(t.j41(0,"span",51),t.EFF(1),t.k0s()),2&i){const e=t.XpG().$implicit;t.R7$(),t.JRh(e)}}function le(i,s){if(1&i&&(t.j41(0,"div",41),t.DNE(1,ie,2,1,"div",42)(2,oe,2,1,"div",42)(3,re,4,1,"div",42)(4,se,4,1,"div",42)(5,ae,3,2,"div",43)(6,ce,2,1,"span",43),t.k0s()),2&i){const e=s.$implicit;t.R7$(),t.Y8G("ngIf","youtube"===e.token),t.R7$(),t.Y8G("ngIf","image"===e.token),t.R7$(),t.Y8G("ngIf","video"===e.token),t.R7$(),t.Y8G("ngIf","audio"===e.token),t.R7$(),t.Y8G("ngIf","link"===e.token),t.R7$(),t.Y8G("ngIf",!e.token)}}function de(i,s){if(1&i&&(t.j41(0,"div",39),t.EFF(1),t.nI1(2,"date"),t.k0s()),2&i){const e=t.XpG(2).$implicit;t.Y8G("ngClass",t.l_i(5,Wt,e.isMine,!e.isMine)),t.R7$(),t.SpI(" ",t.i5U(2,2,e.createdAt,"HH:mm")," ")}}function ue(i,s){if(1&i&&(t.j41(0,"div")(1,"div",35)(2,"div",36),t.DNE(3,ne,2,5,"div",37)(4,le,7,6,"div",38),t.k0s(),t.DNE(5,de,3,8,"div",39),t.k0s()()),2&i){const e=t.XpG(),n=e.$implicit,o=e.$index,r=e.$count,a=t.XpG(2);t.R7$(),t.Y8G("ngClass",t.ziG(6,Lt,n.isMine,!n.isMine,o>0&&a.chat.messages[o-1].isMine===n.isMine,o>0&&a.chat.messages[o-1].isMine!==n.isMine)),t.R7$(),t.Y8G("ngClass",t.l_i(11,Ht,n.isMine,!n.isMine)),t.R7$(),t.vxM(o===r-1||a.chat.messages[o+1].isMine!==n.isMine?3:-1),t.R7$(),t.Y8G("ngForOf",a.parseContent.parseContent(n.value))("ngForTrackBy",a.trackByFn),t.R7$(),t.vxM(0===o||o===r-1||a.chat.messages[o+1].isMine!==n.isMine||a.chat.messages[o+1].createdAt!==n.createdAt?5:-1)}}function me(i,s){if(1&i&&(t.DNE(0,te,6,4,"div",31),t.nI1(1,"date"),t.nI1(2,"date"),t.DNE(3,ue,6,14,"div",32)),2&i){const e=s.$implicit,n=s.$index,o=t.XpG(2);t.vxM(0===n||t.i5U(1,2,o.chat.messages[n-1].createdAt,"d")!==t.i5U(2,5,e.createdAt,"d")?0:-1),t.R7$(3),t.Y8G("ngIf",!e.id.includes("new-chat"))}}function he(i,s){if(1&i){const e=t.RV6();t.j41(0,"div",53)(1,"emoji-mart",54),t.bIt("emojiClick",function(o){t.eBV(e);const r=t.XpG(2);return t.Njj(r.addEmoji(o))}),t.k0s()()}if(2&i){const e=t.XpG(2);t.R7$(),t.Y8G("darkMode",e.darkMode)}}function pe(i,s){if(1&i){const e=t.RV6();t.j41(0,"mat-drawer-container",5)(1,"mat-drawer",7,1),t.mxI("openedChange",function(o){t.eBV(e);const r=t.XpG();return t.DH7(r.drawerOpened,o)||(r.drawerOpened=o),t.Njj(o)}),t.nrm(3,"chat-contact-info",8),t.k0s(),t.j41(4,"mat-drawer-content",9)(5,"div",10)(6,"a",11),t.bIt("click",function(){t.eBV(e);const o=t.XpG();return t.Njj(o.resetChat())}),t.nrm(7,"mat-icon",12),t.k0s(),t.j41(8,"div",13),t.bIt("click",function(){t.eBV(e);const o=t.XpG();return t.Njj(o.openContactInfo())}),t.j41(9,"div",14),t.DNE(10,Qt,1,1,"img",15)(11,Zt,2,1,"div",16),t.k0s(),t.j41(12,"div",17),t.EFF(13),t.k0s()(),t.j41(14,"button",18),t.nrm(15,"mat-icon",12),t.j41(16,"mat-menu",null,2)(18,"button",19),t.bIt("click",function(){t.eBV(e);const o=t.XpG();return t.Njj(o.openContactInfo())}),t.nrm(19,"mat-icon",12),t.EFF(20," Contact info "),t.k0s(),t.j41(21,"button",20),t.nrm(22,"mat-icon",12),t.EFF(23," Select messages "),t.k0s(),t.j41(24,"button",19),t.bIt("click",function(){t.eBV(e);const o=t.XpG();return t.Njj(o.toggleMuteNotifications())}),t.DNE(25,Jt,2,1)(26,qt,2,1),t.k0s(),t.j41(27,"button",20),t.nrm(28,"mat-icon",12),t.EFF(29," Clear messages "),t.k0s(),t.j41(30,"button",20),t.nrm(31,"mat-icon",12),t.EFF(32," Delete chat "),t.k0s()()()(),t.j41(33,"div",21)(34,"div",22),t.Z7z(35,me,4,8,null,null,t.BUC().trackByFn,!0),t.k0s()(),t.j41(37,"div",23)(38,"div",24)(39,"button",25),t.bIt("click",function(){t.eBV(e);const o=t.XpG();return t.Njj(o.openGifDialog())}),t.nrm(40,"mat-icon",12),t.k0s(),t.j41(41,"button",25),t.bIt("click",function(){t.eBV(e);const o=t.XpG();return t.Njj(o.toggleEmojiPicker())}),t.nrm(42,"mat-icon",12),t.k0s(),t.DNE(43,he,2,1,"div",26),t.j41(44,"button",25),t.bIt("click",function(){t.eBV(e);const o=t.XpG();return t.Njj(o.toggleSpeechRecognition())}),t.nrm(45,"mat-icon",27),t.k0s()(),t.j41(46,"mat-form-field",28)(47,"textarea",29,3),t.bIt("keydown",function(o){t.eBV(e);const r=t.XpG();return t.Njj(r.handleKeyDown(o))}),t.k0s()(),t.j41(49,"div",30)(50,"button",25),t.bIt("click",function(){t.eBV(e);const o=t.XpG();return t.Njj(o.sendMessage())}),t.nrm(51,"mat-icon",12),t.k0s()()()()()}if(2&i){const e=t.sdS(2),n=t.sdS(17),o=t.XpG();t.Y8G("hasBackdrop",!1),t.R7$(),t.Y8G("autoFocus",!1)("mode",o.drawerMode)("position","end"),t.R50("opened",o.drawerOpened),t.R7$(2),t.Y8G("drawer",e)("chat",o.chat),t.R7$(3),t.Y8G("routerLink",t.lJ4(26,Vt)),t.R7$(),t.Y8G("svgIcon","heroicons_outline:arrow-long-left"),t.R7$(3),t.vxM(null!=o.chat.contact&&o.chat.contact.picture?10:-1),t.R7$(),t.vxM(null!=o.chat.contact&&o.chat.contact.picture?-1:11),t.R7$(2),t.SpI(" ",null==o.chat.contact?null:o.chat.contact.name," "),t.R7$(),t.Y8G("matMenuTriggerFor",n),t.R7$(),t.Y8G("svgIcon","heroicons_outline:ellipsis-vertical"),t.R7$(4),t.Y8G("svgIcon","heroicons_outline:user-circle"),t.R7$(3),t.Y8G("svgIcon","heroicons_outline:check-circle"),t.R7$(3),t.vxM(o.chat.muted?-1:25),t.R7$(),t.vxM(o.chat.muted?26:-1),t.R7$(2),t.Y8G("svgIcon","heroicons_outline:backspace"),t.R7$(3),t.Y8G("svgIcon","heroicons_outline:trash"),t.R7$(4),t.Dyx(o.chat.messages),t.R7$(5),t.Y8G("svgIcon","heroicons_outline:gif"),t.R7$(2),t.Y8G("svgIcon","heroicons_outline:face-smile"),t.R7$(),t.Y8G("ngIf",o.showEmojiPicker),t.R7$(2),t.Y8G("ngClass",t.eq3(27,Kt,o.isListening))("svgIcon",o.isListening?"heroicons_solid:microphone":"heroicons_outline:microphone"),t.R7$(6),t.Y8G("svgIcon","heroicons_outline:paper-airplane")}}function ge(i,s){1&i&&(t.j41(0,"div",6),t.nrm(1,"mat-icon",55),t.j41(2,"div",56),t.EFF(3," Select a conversation or start a new chat "),t.k0s()()),2&i&&(t.R7$(),t.Y8G("svgIcon","heroicons_outline:chat-bubble-oval-left-ellipsis"))}function fe(i,s){1&i&&(t.qSk(),t.j41(0,"svg",57)(1,"g",58),t.nrm(2,"path",59),t.k0s()())}const _e=[{path:"",component:O,resolve:{chats:()=>(0,t.WQX)(x).getChats(),contacts:()=>(0,t.WQX)(x).getContacts(),profile:()=>(0,t.WQX)(x).getProfile()},children:[{path:"",component:It,children:[{path:"",pathMatch:"full",component:Rt},{path:":id",component:(()=>{class i{constructor(e,n,o,r,a,u,l,d){this._changeDetectorRef=e,this._chatService=n,this._angorMediaWatcherService=o,this._ngZone=r,this._angorConfigService=a,this.dialog=u,this.sanitizer=l,this.parseContent=d,this.drawerMode="side",this.drawerOpened=!1,this._unsubscribeAll=new I.B,this.showEmojiPicker=!1,this.darkMode=!1,this.finalTranscript="",this.isListening=!1,this.userEdited=!1;const m=window.SpeechRecognition||window.webkitSpeechRecognition;m?(this.recognition=new m,this.recognition.lang="en-US",this.recognition.continuous=!0,this.recognition.interimResults=!0,this.setupRecognitionEvents()):console.error("Speech recognition is not supported in this browser.")}openGifDialog(){this.dialog.open(Tt,{width:"600px",maxHeight:"80vh",data:{apiKey:"LIVDSRZULELA"}}).afterClosed().subscribe(n=>{if(n){const o=n;o&&(this.messageInput.nativeElement.value="",this._chatService.sendPrivateMessage(o).then(()=>{this.messageInput.nativeElement.value="",this.finalTranscript=""}).catch(r=>{console.error("Failed to send message:",r)}),this.finalTranscript="",this.userEdited=!1)}})}ngOnInit(){this._angorConfigService.config$.subscribe(e=>{"auto"===e.scheme?this.detectSystemTheme():this.darkMode="dark"===e.scheme}),this._chatService.chat$.pipe((0,j.Q)(this._unsubscribeAll)).subscribe(e=>{this.chat=e,this._changeDetectorRef.markForCheck()}),this._angorMediaWatcherService.onMediaChange$.pipe((0,j.Q)(this._unsubscribeAll)).subscribe(({matchingAliases:e})=>{this.drawerMode=e.includes("lg")?"side":"over",this._changeDetectorRef.markForCheck()})}_resizeMessageInput(){this._ngZone.runOutsideAngular(()=>{setTimeout(()=>{this.messageInput.nativeElement.style.height="auto",this._changeDetectorRef.detectChanges(),this.messageInput.nativeElement.style.height=`${this.messageInput.nativeElement.scrollHeight}px`,this._changeDetectorRef.detectChanges()})})}setupRecognitionEvents(){this.recognition.onresult=e=>{let n="";for(let o=e.resultIndex;o{console.error("Speech recognition error detected: ",e.error)},this.recognition.onend=()=>{this.isListening=!1}}toggleSpeechRecognition(){this.finalTranscript="",this.isListening?(this.recognition.stop(),this.isListening=!1):(this.recognition.start(),this.isListening=!0,this.userEdited=!1)}handleUserInput(e){this.userEdited=!0}ngOnDestroy(){this._unsubscribeAll.next(null),this._unsubscribeAll.complete()}openContactInfo(){this.drawerOpened=!0,this._changeDetectorRef.markForCheck()}resetChat(){this._chatService.resetChat(),this.drawerOpened=!1,this._changeDetectorRef.markForCheck()}toggleMuteNotifications(){this.chat.muted=!this.chat.muted,this._chatService.updateChat(this.chat.id,this.chat).subscribe()}trackByFn(e,n){return n.id||e}detectSystemTheme(){const e=window.matchMedia("(prefers-color-scheme: dark)");this.darkMode=e.matches,e.addEventListener("change",n=>{this.darkMode=n.matches})}handleKeyDown(e){"Enter"===e.key&&!e.shiftKey&&(e.preventDefault(),this.sendMessage())}sendMessage(){const e=this.messageInput.nativeElement.value.trim();e&&(this.messageInput.nativeElement.value="",this._chatService.sendPrivateMessage(e).then(()=>{this.messageInput.nativeElement.value="",this.finalTranscript=""}).catch(n=>{console.error("Failed to send message:",n)}),this.finalTranscript="",this.userEdited=!1)}addEmoji(e){this.messageInput.nativeElement.value+=e.emoji.native,this.showEmojiPicker=!1}toggleEmojiPicker(){this.showEmojiPicker=!this.showEmojiPicker}static{this.\u0275fac=function(n){return new(n||i)(t.rXU(t.gRc),t.rXU(x),t.rXU(Dt.l),t.rXU(t.SKi),t.rXU(At.P),t.rXU(E.bZ),t.rXU(Pt.up),t.rXU(Ut.m))}}static{this.\u0275cmp=t.VBU({type:i,selectors:[["chat-conversation"]],viewQuery:function(n,o){if(1&n&&t.GBs(Ot,5),2&n){let r;t.mGM(r=t.lsd())&&(o.messageInput=r.first)}},hostBindings:function(n,o){1&n&&t.bIt("input",function(){return o._resizeMessageInput()})("ngModelChange",function(){return o._resizeMessageInput()})},decls:5,vars:1,consts:[["speechBubbleExtension",""],["drawer",""],["conversationHeaderMenu",""],["messageInput",""],[1,"bg-card","flex","flex-auto","flex-col","overflow-y-auto","dark:bg-default","lg:overflow-hidden"],[1,"h-full","flex-auto",3,"hasBackdrop"],[1,"flex","flex-auto","flex-col","items-center","justify-center","bg-gray-100","dark:bg-transparent"],[1,"w-full","dark:bg-gray-900","sm:w-100","lg:border-l","lg:shadow-none",3,"openedChange","autoFocus","mode","position","opened"],[3,"drawer","chat"],[1,"flex","flex-col","overflow-hidden"],[1,"flex","h-18","flex-0","items-center","border-b","bg-gray-50","px-4","dark:bg-transparent","md:px-6"],["mat-icon-button","",1,"md:-ml-2","lg:hidden",3,"click","routerLink"],[3,"svgIcon"],[1,"ml-2","mr-2","flex","cursor-pointer","items-center","lg:ml-0",3,"click"],[1,"relative","flex","h-10","w-10","flex-0","items-center","justify-center"],["onerror","this.onerror=null; this.src='/images/avatars/avatar-placeholder.png';","alt","Contact picture",1,"h-full","w-full","rounded-full","object-cover",3,"src"],[1,"flex","h-full","w-full","items-center","justify-center","rounded-full","bg-gray-200","text-lg","uppercase","text-gray-600","dark:bg-gray-700","dark:text-gray-200"],[1,"ml-4","truncate","text-lg","font-medium","leading-5"],["mat-icon-button","",1,"ml-auto",3,"matMenuTriggerFor"],["mat-menu-item","",3,"click"],["mat-menu-item",""],[1,"flex","h-full","flex-col-reverse","overflow-y-auto"],[1,"bg-card","flex","flex-auto","shrink","flex-col","p-6","dark:bg-transparent"],[1,"flex","items-end","border-t","bg-gray-50","p-4","dark:bg-transparent"],[1,"my-px","flex","h-11","items-center"],["mat-icon-button","",3,"click"],["class","emoji-picker-container",4,"ngIf"],[3,"ngClass","svgIcon"],["subscriptSizing","dynamic",1,"angor-mat-dense","angor-mat-rounded","angor-mat-bold","ml-4","w-full"],["matInput","","cdkTextareaAutosize","",1,"max-h-20",3,"keydown"],[1,"my-px","ml-4","flex","h-11","items-center"],[1,"-mx-6","my-3","flex","items-center","justify-center"],[4,"ngIf"],[1,"flex-auto","border-b"],[1,"text-secondary","mx-4","flex-0","text-sm","font-medium","leading-5"],[1,"flex","flex-col",3,"ngClass"],[1,"relative","max-w-3/4","rounded-lg","px-2","py-2",3,"ngClass"],[1,"absolute","bottom-0","w-3",3,"ngClass"],["style","display: inline-block; overflow-wrap: break-word; white-space: pre-wrap;",4,"ngFor","ngForOf","ngForTrackBy"],[1,"text-secondary","my-0.5","text-sm","font-medium",3,"ngClass"],[4,"ngTemplateOutlet"],[2,"display","inline-block","overflow-wrap","break-word","white-space","pre-wrap"],["style","display: block;",4,"ngIf"],["style","display: inline-block; overflow-wrap: break-word;",4,"ngIf"],[2,"display","block"],["width","560","height","315","frameborder","0","allowfullscreen","",3,"src"],["alt","Embedded Image",2,"max-width","100%",3,"src"],["controls","",2,"max-width","100%"],["type","video/mp4",3,"src"],["controls",""],["type","audio/mpeg",3,"src"],[2,"display","inline-block","overflow-wrap","break-word"],["target","_blank",3,"href"],[1,"emoji-picker-container"],[3,"emojiClick","darkMode"],[1,"icon-size-24",3,"svgIcon"],[1,"text-secondary","mt-4","text-2xl","font-semibold","tracking-tight"],["width","100%","height","100%","viewBox","0 0 66 66","xmlns","http://www.w3.org/2000/svg"],["id","Page-1","stroke","none","stroke-width","1","fill","none","fill-rule","evenodd"],["d","M1.01522827,0.516204834 C-8.83532715,54.3062744 61.7609863,70.5215302 64.8009949,64.3061218 C68.8074951,54.8859711 30.1663208,52.9997559 37.5036011,0.516204834 L1.01522827,0.516204834 Z","fill","currentColor","fill-rule","nonzero"]],template:function(n,o){1&n&&(t.j41(0,"div",4),t.DNE(1,pe,52,29,"mat-drawer-container",5)(2,ge,4,1,"div",6)(3,fe,3,0,"ng-template",null,0,t.C5r),t.k0s()),2&n&&(t.R7$(),t.vxM(o.chat?1:2))},dependencies:[C.vg,C.qe,C.$C,C.$l,Xt,h.Hl,h.pQ,h.iY,v.Wk,g.m_,g.An,k.Cn,k.kk,k.fb,k.Cp,f.YU,f.T3,p.RG,p.rl,y.fS,y.fg,A.xb,A.EE,f.vh,$t.Ic,f.MD,f.Sq,f.bT],styles:[".c-img,.c-video{max-width:100%;border-radius:10px}\n"],encapsulation:2,changeDetection:0})}}return i})(),resolve:{conversation:(i,s)=>{const e=(0,t.WQX)(x),n=(0,t.WQX)(v.Ix);let o=i.paramMap.get("id")||localStorage.getItem("currentChatId");if(!o){const r=s.url.split("/").slice(0,-1).join("/");return n.navigateByUrl(r),(0,R.$)("No chat ID provided")}return localStorage.setItem("currentChatId",o),e.getChatById(o).pipe((0,S.W)(r=>{console.error("Error fetching conversation:",r);const a=s.url.split("/").slice(0,-1).join("/");return n.navigateByUrl(a),(0,R.$)(r)}))}}}]}]}]}}]); \ No newline at end of file diff --git a/512.5c8e193aa51cd3ec.js b/512.5c8e193aa51cd3ec.js new file mode 100644 index 0000000..5f60517 --- /dev/null +++ b/512.5c8e193aa51cd3ec.js @@ -0,0 +1 @@ +"use strict";(self.webpackChunkangor=self.webpackChunkangor||[]).push([[512],{1512:(xe,Y,c)=>{c.r(Y),c.d(Y,{default:()=>_e});var t=c(3107),v=c(8716);let O=(()=>{class i{constructor(){}static{this.\u0275fac=function(n){return new(n||i)}}static{this.\u0275cmp=t.VBU({type:i,selectors:[["chat"]],decls:3,vars:0,consts:[[1,"absolute","inset-0","flex","min-w-0","flex-col","overflow-hidden"],[1,"flex","flex-auto","overflow-hidden"]],template:function(n,o){1&n&&(t.j41(0,"div",0)(1,"div",1),t.nrm(2,"router-outlet"),t.k0s()())},dependencies:[v.n3],encapsulation:2,changeDetection:0})}}return i})();var _=c(3014),I=c(1217),j=c(8447),V=c(1698),R=c(8915),N=c(1787),K=c(3016),B=c(1483),X=c(7610),G=c(2867),D=c(7947),S=c(7178),L=c(5492),$=c(3797),H=c(8078),z=c(3149),W=c(3125),Q=c(7121);let x=(()=>{class i{constructor(e,n,o,r){this._signerService=e,this._storageService=n,this._relayService=o,this._metadataQueueService=r,this.chatList=[],this.latestMessageTimestamps={},this.messageQueue=[],this.isDecrypting=!1,this.decryptedPrivateKey="",this._chat=new I.t(null),this._chats=new I.t(null),this._contact=new I.t(null),this._contacts=new I.t(null),this._profile=new I.t(null),this._unsubscribeAll=new j.B}get profile$(){return this._profile.asObservable()}get chat$(){return this._chat.asObservable()}get chats$(){return this._chats.asObservable()}get contact$(){return this._contact.asObservable()}get contacts$(){return this._contacts.asObservable()}checkCurrentChatOnPageRefresh(e){e&&this.getChatById(e).subscribe(o=>{o&&(this._chat.next(o),this.loadAndFetchChatHistory(e))})}getContact(e){var n=this;return(0,_.A)(function*(){try{if(!e)return;n._storageService.profile$.subscribe(o=>{o&&o.pubKey&&o.metadata&&o.pubKey===e&&n._contact.next({pubKey:e,displayName:o.metadata.name?o.metadata.name:"Unknown",picture:o.metadata.picture,about:o.metadata.about})})}catch(o){console.error("Error fetching contact metadata:",o)}})()}getContacts(){return new V.c(e=>(this._storageService.getAllProfiles().then(n=>{if(n&&n.length>0){const o=n.map(r=>(r.pubKey||console.error("Contact is missing pubKey:",r),r));this._contacts.next(o),e.next(o)}else e.next([]);e.complete()}).catch(n=>{console.error("Error loading cached contacts from IndexedDB:",n),e.next([]),e.complete()}),{unsubscribe(){}}))}getProfile(){var e=this;return(0,_.A)(function*(){try{e._storageService.profile$.subscribe(n=>{n&&n.pubKey&&n.metadata&&n.pubKey===e._signerService.getPublicKey()&&e._profile.next(n.metadata)}),e._storageService.getProfile(e._signerService.getPublicKey()).then(n=>{e._profile.next(n)})}catch(n){console.error("Error fetching profile metadata:",n)}})()}getChats(){var e=this;return(0,_.A)(function*(){const n=e._signerService.getPublicKey(),o=yield e._signerService.isUsingExtension(),r=yield e._signerService.isUsingSecretKey();return e.decryptedPrivateKey=r?yield e._signerService.getDecryptedSecretKey():"",yield Promise.all([e.subscribeToChatList(n,o,r,e.decryptedPrivateKey)]),e.getChatListStream()})()}subscribeToChatList(e,n,o,r){var a=this;return this._relayService.ensureConnectedRelays().then((0,_.A)(function*(){const u=[{kinds:[$.rV],authors:[e],limit:1500},{kinds:[$.rV],"#p":[e],limit:1500}];var l;a._relayService.getPool().subscribeMany(a._relayService.getConnectedRelays(),u,{onevent:(l=(0,_.A)(function*(d){const m=d.pubkey===e?d.tags.find(M=>"p"===M[0])?.[1]||"":d.pubkey;m&&d.created_at>(a.latestMessageTimestamps[m]||0)&&(a.messageQueue.push(d),a.processNextMessage(e,n,o,r))}),function(m){return l.apply(this,arguments)}),oneose:()=>{(a.chatList||[]).length>0&&a._chats.next(a.chatList)}})})),this.getChatListStream()}processNextMessage(e,n,o,r){var a=this;return(0,_.A)(function*(){if(!a.isDecrypting&&0!==a.messageQueue.length){a.isDecrypting=!0;try{for(;a.messageQueue.length>0;){const u=a.messageQueue.shift();if(!u)continue;const l=u.pubkey===e,d=l?u.tags.find(w=>"p"===w[0])?.[1]||"":u.pubkey;if(!d)continue;const m=yield a.decryptReceivedMessage(u,n,o,r,d);m&&a.addOrUpdateChatList(d,m,u.created_at,l)}}catch{}finally{a.isDecrypting=!1}}})()}addOrUpdateChatList(e,n,o,r){const a=this.chatList.find(l=>l.contact?.pubKey===e),u={id:`${e}-${o}`,chatId:e,contactId:e,isMine:r,value:n,createdAt:new Date(1e3*o).toISOString()};if(a)a.messages?.some(d=>d.id===u.id)||(a.messages=[...a.messages||[],u].sort((d,m)=>new Date(d.createdAt).getTime()-new Date(m.createdAt).getTime()),Number(a.lastMessageAt)m.pubKey===e)||{pubKey:e};this.chatList.push({id:e,contact:{pubKey:l.pubKey,name:l.name||"Unknown",picture:l.picture||"/images/avatars/avatar-placeholder.png",about:l.about||"",displayName:l.displayName||l.name||"Unknown"},lastMessage:n,lastMessageAt:o,messages:[u]})}this.chatList.sort((l,d)=>Number(d.lastMessageAt)-Number(l.lastMessageAt)),this._chats.next(this.chatList),this._storageService.profile$.pipe((0,B.p)(l=>l&&l.pubKey===e)).subscribe(l=>{const d=this.chatList.find(m=>m.contact?.pubKey===e);d&&(d.contact={...d.contact,name:l.metadata?.name||d.contact.name,picture:l.metadata?.picture||d.contact.picture,about:l.metadata?.about||d.contact.about,displayName:l.metadata?.displayName||l.metadata?.name||d.contact.displayName},this._chats.next(this.chatList))})}getChatListStream(){return this._chats.asObservable()}decryptReceivedMessage(e,n,o,r,a){var u=this;return(0,_.A)(function*(){return n&&!o?yield u._signerService.decryptMessageWithExtension(a,e.content):o&&!n?yield u._signerService.decryptMessage(r,a,e.content):void 0})()}loadAndFetchChatHistory(e,n=!1){var o=this;return(0,_.A)(function*(){const r=o._signerService.getPublicKey(),a=[{kinds:[$.rV],authors:[r],"#p":[e],limit:10},{kinds:[$.rV],authors:[e],"#p":[r],limit:10}],u=[];if(o._relayService.getPool().subscribeMany(o._relayService.getConnectedRelays(),a,{onevent:(l=(0,_.A)(function*(d){const m=d.pubkey===r,w=m?e:d.pubkey,M=yield o._signerService.isUsingExtension(),ve=yield o._signerService.isUsingSecretKey(),T=yield o.decryptReceivedMessage(d,M,ve,o.decryptedPrivateKey,w);if(T){const U=Math.floor(d.created_at),Ce={id:d.id,chatId:e,contactId:w,isMine:m,value:T,createdAt:new Date(1e3*U).toISOString()};n&&u.push(Ce),o.addOrUpdateChatList(e,T,U,m),o._chat.next(o.chatList.find(be=>be.id===e))}}),function(m){return l.apply(this,arguments)}),oneose:()=>{}}),n)return yield new Promise(l=>setTimeout(l,1e3)),u;var l})()}updateChat(e,n){return this.chats$.pipe((0,X.s)(1),(0,G.n)(o=>{const r=n.contact?.pubKey;if(!r)return(0,R.$)("No public key found for this chat");const a={kind:4,pubkey:r,content:JSON.stringify(n),created_at:Math.floor(Date.now()/1e3),tags:[["p",r]]};return a.id=(0,L.dq)(a),(0,N.H)(this._relayService.publishEventToWriteRelays(a)).pipe((0,D.T)(()=>{if(o){const u=o.findIndex(l=>l.id===e);-1!==u&&(o[u]=n,this._chats.next(o))}return n}),(0,S.W)(u=>(console.error("Failed to update chat via Nostr:",u),(0,R.$)(u))))}))}getChatById(e,n=null){return this.recipientPublicKey=e,(0,N.H)(Promise.all([this._signerService.getPublicKey()])).pipe((0,G.n)(()=>this.chats$.pipe((0,X.s)(1),(0,G.n)(o=>{if(!o||0===o.length)return this.createNewChat(e,n);const r=o.find(a=>a.id===e);return r?(this._chat.next(r),this.loadAndFetchChatHistory(this.recipientPublicKey),(0,K.of)(r)):this.createNewChat(e,n)}))),(0,S.W)(o=>(console.error("Error fetching chat by id from Nostr:",o),(0,R.$)(o))))}createNewChat(e,n=null){const o={id:e||"",contact:n?{pubKey:n.pubKey||e,name:n.name||"Unknown",picture:n.picture||"/images/avatars/avatar-placeholder.png"}:{pubKey:e,name:"Unknown",picture:"/images/avatars/avatar-placeholder.png"},lastMessage:"new chat...",lastMessageAt:Math.floor(Date.now()/1e3)||0,messages:[]};return this._metadataQueueService.addPublicKey(e),this._storageService.profile$.pipe((0,B.p)(r=>r&&r.pubKey===e),(0,D.T)(r=>(o.contact={pubKey:e,name:r.metadata?.name||"Unknown",picture:r.metadata?.picture||"/images/avatars/avatar-placeholder.png",about:r.metadata?.about||"",displayName:r.metadata?.displayName||r.metadata?.name||"Unknown"},o)))}resetChat(){this._chat.next(null)}sendPrivateMessage(e){var n=this;return(0,_.A)(function*(){try{n.message=e;const o=yield n._signerService.isUsingExtension(),r=yield n._signerService.isUsingSecretKey();if(o&&!r)yield n.handleMessageSendingWithExtension();else if(!o&&r){if(!n.isValidMessageSetup())return void console.error("Message, sender private key, or recipient public key is not properly set.");const a=yield n._signerService.encryptMessage(n.decryptedPrivateKey,n.recipientPublicKey,n.message),u=n._signerService.getUnsignedEvent(4,[["p",n.recipientPublicKey]],a),l=n._signerService.getSignedEvent(u,n.decryptedPrivateKey);(yield n._relayService.publishEventToWriteRelays(l))?n.message="":console.error("Failed to send the message.")}}catch(o){console.error("Error sending private message:",o)}})()}handleMessageSendingWithExtension(){var e=this;return(0,_.A)(function*(){try{const n=yield e._signerService.encryptMessageWithExtension(e.message,e.recipientPublicKey),o=yield e._signerService.signEventWithExtension({kind:4,pubkey:e._signerService.getPublicKey(),tags:[["p",e.recipientPublicKey]],content:n,created_at:Math.floor(Date.now()/1e3)});(yield e._relayService.publishEventToWriteRelays(o))?e.message="":console.error("Failed to send the message with extension.")}catch(n){console.error("Error sending message with extension:",n)}})()}isValidMessageSetup(){return""!==this.message.trim()&&""!==this.recipientPublicKey}ngOnDestroy(){this._unsubscribeAll.next(),this._unsubscribeAll.complete()}static{this.\u0275fac=function(n){return new(n||i)(t.KVO(H.A),t.KVO(z.n),t.KVO(W.b),t.KVO(Q.T))}}static{this.\u0275prov=t.jDH({token:i,factory:i.\u0275fac,providedIn:"root"})}}return i})();var f=c(4460),h=c(9471),p=c(6071),g=c(3904),y=c(6389),k=c(7818),C=c(5785),Z=c(9561);let J=(()=>{class i{transform(e){return/\.(jpeg|jpg|gif|png|bmp|svg|webp|tiff)$/i.test(e)?"\u{1f304} image":/\.(mp4|mov|avi|mkv|webm|flv|wmv|mpeg|3gp)$/i.test(e)?"\u{1f3ac} video":/\.(mp3|wav|ogg|m4a|aac|flac)$/i.test(e)?"\u{1f3b5} audio":/\.pdf$/i.test(e)?"\u{1f4c1} pdf":/(?:https?:\/\/)?(?:www\.)?(?:youtube\.com\/(?:[^\/\n\s]+\/\S+\/|(?:v|e(?:mbed)?)\/|\S*?[?&]v=)|youtu\.be\/)([a-zA-Z0-9_-]{11})/.test(e)?"\u{1f4fd}\ufe0f youtube":/https?:\/\/(www\.)?vimeo.com\/(\d+)/.test(e)?"\u{1f4fd}\ufe0f vimeo":/https?:\/\/(www\.)?instagram.com\/p\/[a-zA-Z0-9_-]+/.test(e)?"\u{1f52e} instagram":/https?:\/\/(www\.)?twitter.com\/[a-zA-Z0-9_]+\/status\/[0-9]+/.test(e)?"\u{1f426} twitter":/(https?:\/\/[^\s]+)/.test(e)?"\u{1f310} url":e}static{this.\u0275fac=function(n){return new(n||i)}}static{this.\u0275pipe=t.EJ8({name:"checkmessage",type:i,pure:!0})}}return i})();var F=c(5424);function q(i,s){if(1&i){const e=t.RV6();t.j41(0,"div",15),t.bIt("click",function(){t.eBV(e);const o=t.XpG().$implicit,r=t.XpG(2);return t.Njj(r.openChat(o))}),t.EFF(1),t.k0s()}if(2&i){const e=t.XpG().$implicit;t.R7$(),t.SpI(" ",e.name.charAt(0)," ")}}function tt(i,s){if(1&i&&t.nrm(0,"img",10),2&i){const e=t.XpG().$implicit;t.Y8G("src",e.picture,t.B4B)}}function et(i,s){if(1&i&&(t.j41(0,"div",11),t.EFF(1),t.k0s()),2&i){const e=t.XpG().$implicit;t.R7$(),t.SpI(" ",e.name.charAt(0)," ")}}function nt(i,s){if(1&i){const e=t.RV6();t.DNE(0,q,2,1,"div",7),t.j41(1,"div",8),t.bIt("click",function(){const o=t.eBV(e).$implicit,r=t.XpG(2);return t.Njj(r.openChat(o))}),t.j41(2,"div",9),t.DNE(3,tt,1,1,"img",10)(4,et,2,1,"div",11),t.k0s(),t.j41(5,"div",12)(6,"div",13),t.EFF(7),t.k0s(),t.j41(8,"div",14),t.EFF(9),t.k0s()()()}if(2&i){const e=s.$implicit,n=s.$index,o=t.XpG(2);t.vxM(0===n||e.name.charAt(0)!==o.contacts[n-1].name.charAt(0)?0:-1),t.R7$(3),t.vxM(e.picture?3:-1),t.R7$(),t.vxM(e.picture?-1:4),t.R7$(3),t.SpI(" ",e.name," "),t.R7$(2),t.SpI(" ",e.about," ")}}function it(i,s){if(1&i&&t.Z7z(0,nt,10,5,null,null,t.BUC().trackByFn,!0),2&i){const e=t.XpG();t.Dyx(e.contacts)}}function ot(i,s){1&i&&(t.j41(0,"div",6),t.EFF(1," There are no contacts! "),t.k0s())}let rt=(()=>{class i{constructor(e,n){this._chatService=e,this.router=n,this.contacts=[],this._unsubscribeAll=new j.B}ngOnInit(){this._chatService.contacts$.pipe((0,F.Q)(this._unsubscribeAll)).subscribe(e=>{this.contacts=e})}ngOnDestroy(){this._unsubscribeAll.next(null),this._unsubscribeAll.complete()}trackByFn(e,n){return n.id||e}openChat(e){this._chatService.getChatById(e.pubKey,e).subscribe({next:n=>{console.log("Chat loaded or created:",n),this.router.navigate(["/chat",e.pubKey])},error:n=>{console.error("Error loading or creating chat:",n)},complete:()=>{this.drawer.close()}})}static{this.\u0275fac=function(n){return new(n||i)(t.rXU(x),t.rXU(v.Ix))}}static{this.\u0275cmp=t.VBU({type:i,selectors:[["chat-new-chat"]],inputs:{drawer:"drawer"},decls:9,vars:2,consts:[[1,"bg-card","flex","h-full","flex-auto","flex-col","overflow-hidden","dark:bg-default"],[1,"-mb-px","flex","h-18","flex-0","items-center","bg-gray-50","px-6","dark:bg-transparent"],["mat-icon-button","",3,"click"],[3,"svgIcon"],[1,"ml-2","text-2xl","font-semibold"],[1,"relative","overflow-y-auto"],[1,"border-t","p-8","text-center","text-4xl","font-semibold","tracking-tight","sm:p-16"],[1,"text-secondary","sticky","top-0","z-10","-mt-px","border-b","border-t","bg-gray-100","px-6","py-1","font-medium","uppercase","dark:bg-gray-900","md:px-8"],[1,"z-20","flex","cursor-pointer","items-center","border-b","px-6","py-4","dark:hover:bg-hover","hover:bg-gray-100","md:px-8",3,"click"],[1,"flex","h-10","w-10","flex-0","items-center","justify-center","overflow-hidden","rounded-full"],["onerror","this.onerror=null; this.src='/images/avatars/avatar-placeholder.png';","alt","Contact picture",1,"h-full","w-full","object-cover",3,"src"],[1,"flex","h-full","w-full","items-center","justify-center","rounded-full","bg-gray-200","text-lg","uppercase","text-gray-600","dark:bg-gray-700","dark:text-gray-200"],[1,"ml-4","min-w-0"],[1,"truncate","font-medium","leading-5"],[1,"text-secondary","truncate","leading-5"],[1,"text-secondary","sticky","top-0","z-10","-mt-px","border-b","border-t","bg-gray-100","px-6","py-1","font-medium","uppercase","dark:bg-gray-900","md:px-8",3,"click"]],template:function(n,o){1&n&&(t.j41(0,"div",0)(1,"div",1)(2,"button",2),t.bIt("click",function(){return o.drawer.close()}),t.nrm(3,"mat-icon",3),t.k0s(),t.j41(4,"div",4),t.EFF(5,"New chat"),t.k0s()(),t.j41(6,"div",5),t.DNE(7,it,2,0)(8,ot,2,0,"div",6),t.k0s()()),2&n&&(t.R7$(3),t.Y8G("svgIcon","heroicons_outline:arrow-long-left"),t.R7$(4),t.vxM(o.contacts.length?7:8))},dependencies:[h.Hl,h.iY,g.m_,g.An],encapsulation:2,changeDetection:0})}}return i})();var b=c(936);function st(i,s){if(1&i&&t.nrm(0,"img",10),2&i){const e=t.XpG();t.Y8G("src",e.profile.picture,t.B4B)("alt","Profile picture")}}function at(i,s){if(1&i&&(t.j41(0,"div",11),t.EFF(1),t.k0s()),2&i){const e=t.XpG();t.R7$(),t.SpI(" ",e.profile.name.charAt(0)," ")}}let ct=(()=>{class i{constructor(e){this._chatService=e,this._unsubscribeAll=new j.B}ngOnInit(){this._chatService.profile$.pipe((0,F.Q)(this._unsubscribeAll)).subscribe(e=>{this.profile=e})}ngOnDestroy(){this._unsubscribeAll.next(null),this._unsubscribeAll.complete()}static{this.\u0275fac=function(n){return new(n||i)(t.rXU(x))}}static{this.\u0275cmp=t.VBU({type:i,selectors:[["chat-profile"]],inputs:{drawer:"drawer"},decls:35,vars:11,consts:[[1,"bg-card","flex","flex-auto","flex-col","overflow-y-auto","dark:bg-default"],[1,"flex","h-18","flex-0","items-center","border-b","bg-gray-50","px-6","dark:bg-transparent"],["mat-icon-button","",3,"click"],[3,"svgIcon"],[1,"ml-2","text-2xl","font-semibold"],[1,"px-6"],[1,"group","relative","mx-auto","mt-8","flex","h-40","w-40","flex-0","rounded-full"],[1,"absolute","inset-0","hidden","cursor-pointer","flex-col","items-center","justify-center","rounded-full","bg-gray-800","bg-opacity-80","backdrop-blur","backdrop-filter","group-hover:flex"],[1,"text-white",3,"svgIcon"],[1,"mx-6","mt-2","text-center","font-medium","text-white"],["onerror","this.onerror=null; this.src='/images/avatars/avatar-placeholder.png';",1,"h-full","w-full","rounded-full","object-cover",3,"src","alt"],[1,"flex","h-full","w-full","items-center","justify-center","rounded-full","bg-gray-200","text-8xl","font-semibold","uppercase","text-gray-600","dark:bg-gray-700","dark:text-gray-200"],[1,"mx-2","mt-8","flex","flex-col"],["matPrefix","",1,"icon-size-5",3,"svgIcon"],["matInput","",3,"ngModel"],[1,"mt-4","flex","items-center","justify-end"],["mat-button","",3,"click"],["mat-flat-button","",1,"ml-2",3,"color"]],template:function(n,o){1&n&&(t.j41(0,"div",0)(1,"div",1)(2,"button",2),t.bIt("click",function(){return o.drawer.close()}),t.nrm(3,"mat-icon",3),t.k0s(),t.j41(4,"div",4),t.EFF(5,"Profile"),t.k0s()(),t.j41(6,"div",5)(7,"div",6)(8,"div",7),t.nrm(9,"mat-icon",8),t.j41(10,"div",9),t.EFF(11," Change Profile Photo "),t.k0s()(),t.DNE(12,st,1,2,"img",10)(13,at,2,1,"div",11),t.k0s(),t.j41(14,"div",12)(15,"mat-form-field")(16,"mat-label"),t.EFF(17,"Name"),t.k0s(),t.nrm(18,"mat-icon",13)(19,"input",14),t.k0s(),t.j41(20,"mat-form-field")(21,"mat-label"),t.EFF(22,"Username"),t.k0s(),t.nrm(23,"mat-icon",13)(24,"input",14),t.k0s(),t.j41(25,"mat-form-field")(26,"mat-label"),t.EFF(27,"About"),t.k0s(),t.nrm(28,"mat-icon",13)(29,"input",14),t.k0s(),t.j41(30,"div",15)(31,"button",16),t.bIt("click",function(){return o.drawer.close()}),t.EFF(32,"Cancel"),t.k0s(),t.j41(33,"button",17),t.EFF(34," Save "),t.k0s()()()()()),2&n&&(t.R7$(3),t.Y8G("svgIcon","heroicons_outline:arrow-long-left"),t.R7$(6),t.Y8G("svgIcon","heroicons_outline:camera"),t.R7$(3),t.vxM(o.profile.picture?12:-1),t.R7$(),t.vxM(o.profile.picture?-1:13),t.R7$(5),t.Y8G("svgIcon","heroicons_solid:user-circle"),t.R7$(),t.Y8G("ngModel",o.profile.name),t.R7$(4),t.Y8G("svgIcon","heroicons_solid:envelope"),t.R7$(),t.Y8G("ngModel",o.profile.username),t.R7$(4),t.Y8G("svgIcon","heroicons_solid:identification"),t.R7$(),t.Y8G("ngModel",o.profile.about),t.R7$(4),t.Y8G("color","primary"))},dependencies:[h.Hl,h.$z,h.iY,g.m_,g.An,p.RG,p.rl,p.nJ,p.JW,y.fS,y.fg,b.YN,b.me,b.BC,b.vS],encapsulation:2,changeDetection:0})}}return i})();var lt=c(3871);const dt=(i,s)=>({"dark:hover:bg-hover hover:bg-gray-100":i,"bg-primary-50 dark:bg-hover":s}),ut=i=>[i],mt=(i,s)=>({"absolute inset-0 z-20 flex lg:static lg:inset-auto":i,"hidden lg:flex":s});function ht(i,s){if(1&i&&t.nrm(0,"chat-new-chat",6),2&i){t.XpG();const e=t.sdS(3);t.Y8G("drawer",e)}}function pt(i,s){if(1&i&&t.nrm(0,"chat-profile",6),2&i){t.XpG();const e=t.sdS(3);t.Y8G("drawer",e)}}function gt(i,s){if(1&i&&t.nrm(0,"img",15),2&i){const e=t.XpG(2);t.Y8G("src",null==e.profile?null:e.profile.picture,t.B4B)}}function ft(i,s){if(1&i&&(t.j41(0,"div",16),t.EFF(1),t.k0s()),2&i){const e=t.XpG(2);t.R7$(),t.SpI(" ",null==e.profile||null==e.profile.name?null:e.profile.name.charAt(0)," ")}}function _t(i,s){if(1&i&&t.nrm(0,"div",39),2&i){const e=t.XpG().$implicit,n=t.XpG(3);t.AVh("ring-primary-50",n.selectedChat&&n.selectedChat.id===e.id)}}function vt(i,s){if(1&i&&t.nrm(0,"img",40),2&i){const e=t.XpG().$implicit;t.Y8G("src",null==e.contact?null:e.contact.picture,t.B4B)}}function Ct(i,s){if(1&i&&(t.j41(0,"div",16),t.EFF(1),t.k0s()),2&i){const e=t.XpG().$implicit;t.R7$(),t.SpI(" ",null==e.contact||null==e.contact.name?null:e.contact.name.charAt(0)," ")}}function bt(i,s){1&i&&t.nrm(0,"mat-icon",38),2&i&&t.Y8G("svgIcon","heroicons_solid:speaker-x-mark")}function xt(i,s){if(1&i&&(t.j41(0,"a",28)(1,"div",29),t.DNE(2,_t,1,2,"div",30)(3,vt,1,1,"img",31)(4,Ct,2,1,"div",32),t.k0s(),t.j41(5,"div",33)(6,"div",34),t.EFF(7),t.k0s(),t.j41(8,"div",35),t.EFF(9),t.nI1(10,"checkmessage"),t.k0s()(),t.j41(11,"div",36)(12,"div",37),t.EFF(13),t.nI1(14,"ago"),t.k0s(),t.DNE(15,bt,1,1,"mat-icon",38),t.k0s()()),2&i){const e=s.$implicit,n=t.XpG(3);t.Y8G("ngClass",t.l_i(17,dt,!n.selectedChat||n.selectedChat.id!==e.id,n.selectedChat&&n.selectedChat.id===e.id))("routerLink",t.eq3(20,ut,e.id)),t.R7$(2),t.vxM(e.unreadCount>0?2:-1),t.R7$(),t.Y8G("ngIf",null==e.contact?null:e.contact.picture),t.R7$(),t.Y8G("ngIf",!(null!=e.contact&&e.contact.picture)),t.R7$(3),t.SpI(" ",null==e.contact?null:e.contact.name," "),t.R7$(),t.AVh("text-primary",e.unreadCount>0)("dark:text-primary-500",e.unreadCount>0),t.R7$(),t.SpI(" ",t.bMT(10,13,e.lastMessage)," "),t.R7$(4),t.SpI(" ",t.bMT(14,15,e.lastMessageAt)," "),t.R7$(2),t.vxM(e.muted?15:-1)}}function yt(i,s){if(1&i&&t.Z7z(0,xt,16,22,"a",28,t.BUC().trackByFn,!0),2&i){const e=t.XpG(2);t.Dyx(e.filteredChats)}}function kt(i,s){1&i&&(t.j41(0,"div",9),t.nrm(1,"mat-icon",41),t.j41(2,"div",42),t.EFF(3," No chats "),t.k0s()()),2&i&&(t.R7$(),t.Y8G("svgIcon","heroicons_outline:chat-bubble-oval-left-ellipsis"))}function wt(i,s){if(1&i){const e=t.RV6();t.j41(0,"div",8)(1,"div",11)(2,"div",12)(3,"div",13),t.bIt("click",function(){t.eBV(e);const o=t.XpG();return t.Njj(o.openProfile())}),t.j41(4,"div",14),t.DNE(5,gt,1,1,"img",15)(6,ft,2,1,"div",16),t.k0s(),t.j41(7,"div",17),t.EFF(8),t.k0s()(),t.j41(9,"button",18),t.bIt("click",function(){t.eBV(e);const o=t.XpG();return t.Njj(o.openNewChat())}),t.nrm(10,"mat-icon",19),t.k0s(),t.j41(11,"button",20),t.nrm(12,"mat-icon",19),t.j41(13,"mat-menu",null,1)(15,"button",21),t.nrm(16,"mat-icon",19),t.EFF(17," New group "),t.k0s(),t.j41(18,"button",21),t.nrm(19,"mat-icon",19),t.EFF(20," Create a room "),t.k0s(),t.j41(21,"button",22),t.bIt("click",function(){t.eBV(e);const o=t.XpG();return t.Njj(o.openProfile())}),t.nrm(22,"mat-icon",19),t.EFF(23," Profile "),t.k0s(),t.j41(24,"button",21),t.nrm(25,"mat-icon",19),t.EFF(26," Archived "),t.k0s(),t.j41(27,"button",21),t.nrm(28,"mat-icon",19),t.EFF(29," Starred "),t.k0s(),t.j41(30,"button",21),t.nrm(31,"mat-icon",19),t.EFF(32," Settings "),t.k0s()()()(),t.j41(33,"div",23)(34,"mat-form-field",24),t.nrm(35,"mat-icon",25),t.j41(36,"input",26,2),t.bIt("input",function(){t.eBV(e);const o=t.sdS(37),r=t.XpG();return t.Njj(r.filterChats(o.value))}),t.k0s()()()(),t.j41(38,"div",27),t.DNE(39,yt,2,0)(40,kt,4,1,"div",9),t.k0s()()}if(2&i){const e=t.sdS(14),n=t.XpG();t.R7$(5),t.vxM(null!=n.profile&&n.profile.picture?5:-1),t.R7$(),t.vxM(null!=n.profile&&n.profile.picture?-1:6),t.R7$(2),t.SpI(" ",null==n.profile?null:n.profile.name," "),t.R7$(2),t.Y8G("svgIcon","heroicons_outline:plus-circle"),t.R7$(),t.Y8G("matMenuTriggerFor",e),t.R7$(),t.Y8G("svgIcon","heroicons_outline:ellipsis-vertical"),t.R7$(4),t.Y8G("svgIcon","heroicons_outline:user-group"),t.R7$(3),t.Y8G("svgIcon","heroicons_outline:chat-bubble-left-right"),t.R7$(3),t.Y8G("svgIcon","heroicons_outline:user-circle"),t.R7$(3),t.Y8G("svgIcon","heroicons_outline:archive-box"),t.R7$(3),t.Y8G("svgIcon","heroicons_outline:star"),t.R7$(3),t.Y8G("svgIcon","heroicons_outline:cog-8-tooth"),t.R7$(3),t.Y8G("subscriptSizing","dynamic"),t.R7$(),t.Y8G("svgIcon","heroicons_solid:magnifying-glass"),t.R7$(),t.Y8G("autocomplete","off")("placeholder","Search or start new chat"),t.R7$(3),t.vxM(n.filteredChats.length>0?39:40)}}function Ft(i,s){1&i&&(t.j41(0,"div",9),t.nrm(1,"mat-icon",41),t.j41(2,"div",42),t.EFF(3," No chats "),t.k0s()()),2&i&&(t.R7$(),t.Y8G("svgIcon","heroicons_outline:chat-bubble-oval-left-ellipsis"))}function It(i,s){if(1&i&&(t.j41(0,"div",10),t.nrm(1,"router-outlet"),t.k0s()),2&i){const e=t.XpG();t.Y8G("ngClass",t.l_i(1,mt,e.selectedChat&&e.selectedChat.id,!e.selectedChat||!e.selectedChat.id))}}let jt=(()=>{class i{constructor(e,n,o,r){this._chatService=e,this._changeDetectorRef=n,this.route=o,this._angorNavigationService=r,this.chats=[],this.filteredChats=[],this.drawerOpened=!1,this._unsubscribeAll=new j.B}updateNavigationBadge(){const e=this._angorNavigationService.getComponent("mainNavigation");e&&(this._angorNavigationService.getItem("chat",e.navigation).badge.title="0",e.refresh())}ngOnInit(){this.updateNavigationBadge(),this._chatService.chats$.pipe((0,F.Q)(this._unsubscribeAll)).subscribe(n=>{this.chats=this.filteredChats=n,this._markForCheck()}),this._chatService.profile$.pipe((0,F.Q)(this._unsubscribeAll)).subscribe(n=>{this.profile=n,this._markForCheck()}),this._chatService.chat$.pipe((0,F.Q)(this._unsubscribeAll)).subscribe(n=>{this.selectedChat=n,this._markForCheck()});const e=localStorage.getItem("currentChatId");e&&this._chatService.checkCurrentChatOnPageRefresh(e)}ngOnDestroy(){this._unsubscribeAll.next(),this._unsubscribeAll.complete(),this._chatService.resetChat(),localStorage.removeItem("currentChatId")}filterChats(e){if(e){const n=e.toLowerCase();this.filteredChats=this.chats.filter(o=>o.contact?.name.toLowerCase().includes(n))}else this.filteredChats=this.chats;this._markForCheck()}openNewChat(){this.drawerComponent="new-chat",this.drawerOpened=!0,this._markForCheck()}openProfile(){this.drawerComponent="profile",this.drawerOpened=!0,this._markForCheck()}trackByFn(e,n){return n.id||e}_markForCheck(){this._changeDetectorRef.markForCheck()}static{this.\u0275fac=function(n){return new(n||i)(t.rXU(x),t.rXU(t.gRc),t.rXU(v.nX),t.rXU(lt.lX))}}static{this.\u0275cmp=t.VBU({type:i,selectors:[["chat-chats"]],decls:10,vars:7,consts:[["drawer",""],["chatsHeaderMenu",""],["searchField",""],[1,"bg-card","relative","flex","w-full","flex-auto","dark:bg-transparent"],[1,"h-full","flex-auto",3,"hasBackdrop"],[1,"w-full","dark:bg-gray-900","sm:w-100","lg:border-r","lg:shadow-none",3,"openedChange","autoFocus","opened"],[3,"drawer"],[1,"flex","overflow-hidden"],[1,"bg-card","relative","flex","w-full","min-w-0","flex-auto","flex-col","dark:bg-transparent","lg:min-w-100","lg:max-w-100"],[1,"flex","h-full","flex-auto","flex-col","items-center","justify-center"],[1,"flex-auto","border-l",3,"ngClass"],[1,"flex","flex-0","flex-col","border-b","bg-gray-50","px-8","py-4","dark:bg-transparent"],[1,"flex","items-center"],[1,"mr-1","flex","cursor-pointer","items-center",3,"click"],[1,"h-10","w-10"],["onerror","this.onerror=null; this.src='/images/avatars/avatar-placeholder.png';","alt","Profile picture",1,"h-full","w-full","rounded-full","object-cover",3,"src"],[1,"flex","h-full","w-full","items-center","justify-center","rounded-full","bg-gray-200","text-lg","uppercase","text-gray-600","dark:bg-gray-700","dark:text-gray-200"],[1,"ml-4","truncate","font-medium"],["mat-icon-button","",1,"ml-auto",3,"click"],[3,"svgIcon"],["mat-icon-button","",1,"-mr-4","ml-1",3,"matMenuTriggerFor"],["mat-menu-item",""],["mat-menu-item","",3,"click"],[1,"mt-4"],[1,"angor-mat-rounded","angor-mat-dense","w-full",3,"subscriptSizing"],["matPrefix","",1,"icon-size-5",3,"svgIcon"],["matInput","",3,"input","autocomplete","placeholder"],[1,"flex-auto","overflow-y-auto"],[1,"z-20","flex","cursor-pointer","items-center","border-b","px-8","py-5",3,"ngClass","routerLink"],[1,"relative","flex","h-10","w-10","flex-0","items-center","justify-center"],[1,"ring-bg-card","absolute","bottom-0","right-0","-ml-0.5","h-2","w-2","flex-0","rounded-full","bg-primary","text-on-primary","ring-2","dark:bg-primary-500","dark:ring-gray-900",3,"ring-primary-50"],["class","h-full w-full rounded-full object-cover","alt","Contact picture",3,"src",4,"ngIf"],["class","flex h-full w-full items-center justify-center rounded-full bg-gray-200 text-lg uppercase text-gray-600 dark:bg-gray-700 dark:text-gray-200",4,"ngIf"],[1,"ml-4","min-w-0"],[1,"truncate","font-medium","leading-5"],[1,"text-secondary","truncate","leading-5"],[1,"ml-auto","flex","flex-col","items-end","self-start","pl-2"],[1,"text-secondary","overflow-hidden","whitespace-nowrap","text-sm","leading-5"],[1,"text-hint","icon-size-5",3,"svgIcon"],[1,"ring-bg-card","absolute","bottom-0","right-0","-ml-0.5","h-2","w-2","flex-0","rounded-full","bg-primary","text-on-primary","ring-2","dark:bg-primary-500","dark:ring-gray-900"],["alt","Contact picture",1,"h-full","w-full","rounded-full","object-cover",3,"src"],[1,"icon-size-24",3,"svgIcon"],[1,"text-secondary","mt-4","text-2xl","font-semibold","tracking-tight"]],template:function(n,o){if(1&n){const r=t.RV6();t.j41(0,"div",3)(1,"mat-drawer-container",4)(2,"mat-drawer",5,0),t.mxI("openedChange",function(u){return t.eBV(r),t.DH7(o.drawerOpened,u)||(o.drawerOpened=u),t.Njj(u)}),t.DNE(4,ht,1,1,"chat-new-chat",6)(5,pt,1,1,"chat-profile",6),t.k0s(),t.j41(6,"mat-drawer-content",7),t.DNE(7,wt,41,17,"div",8)(8,Ft,4,1,"div",9)(9,It,2,4,"div",10),t.k0s()()()}2&n&&(t.R7$(),t.Y8G("hasBackdrop",!1),t.R7$(),t.Y8G("autoFocus",!1),t.R50("opened",o.drawerOpened),t.R7$(2),t.vxM("new-chat"===o.drawerComponent?4:-1),t.R7$(),t.vxM("profile"===o.drawerComponent?5:-1),t.R7$(2),t.vxM(o.chats&&o.chats.length>0?7:8),t.R7$(2),t.vxM(o.chats&&o.chats.length>0?9:-1))},dependencies:[C.vg,C.qe,C.$C,C.$l,rt,ct,h.Hl,h.iY,g.m_,g.An,k.Cn,k.kk,k.fb,k.Cp,p.RG,p.rl,p.JW,y.fS,y.fg,f.YU,v.Wk,v.n3,Z.g,f.MD,f.bT,J],encapsulation:2,changeDetection:0})}}return i})(),Rt=(()=>{class i{constructor(){}static{this.\u0275fac=function(n){return new(n||i)}}static{this.\u0275cmp=t.VBU({type:i,selectors:[["chat-empty-conversation"]],decls:5,vars:1,consts:[[1,"bg-card","flex","flex-auto","flex-col","overflow-y-auto","dark:bg-default","lg:overflow-hidden"],[1,"flex","flex-auto","flex-col","items-center","justify-center","bg-gray-100","dark:bg-transparent"],[1,"icon-size-24",3,"svgIcon"],[1,"text-secondary","mt-4","text-2xl","font-semibold","tracking-tight"]],template:function(n,o){1&n&&(t.j41(0,"div",0)(1,"div",1),t.nrm(2,"mat-icon",2),t.j41(3,"div",3),t.EFF(4," Select a conversation or start a new chat "),t.k0s()()()),2&n&&(t.R7$(2),t.Y8G("svgIcon","heroicons_outline:chat-bubble-oval-left-ellipsis"))},dependencies:[g.m_,g.An],encapsulation:2,changeDetection:0})}}return i})();var A=c(708),$t=c(1556),E=c(7544),Gt=c(4375),P=c(7691);let St=(()=>{class i{constructor(e){this.http=e}getTopGifs(e,n){const r=(new P.Nl).append("key",n).append("q",e);return this.http.get("https://g.tenor.com/v1/search",{params:r})}static{this.\u0275fac=function(n){return new(n||i)(t.KVO(P.Qq))}}static{this.\u0275prov=t.jDH({token:i,factory:i.\u0275fac,providedIn:"root"})}}return i})();function Et(i,s){if(1&i){const e=t.RV6();t.j41(0,"div",8),t.bIt("click",function(){const o=t.eBV(e).$implicit,r=t.XpG(2);return t.Njj(r.selectGif(o))}),t.nrm(1,"img",9),t.k0s()}if(2&i){const e=s.$implicit;t.R7$(),t.Y8G("src",e,t.B4B)}}function Mt(i,s){if(1&i&&(t.j41(0,"div",6),t.DNE(1,Et,2,1,"div",7),t.k0s()),2&i){const e=t.XpG();t.R7$(),t.Y8G("ngForOf",e.gifsFound)}}let Tt=(()=>{class i{constructor(e,n,o,r){this.gifService=e,this.dialogRef=n,this._changeDetectorRef=o,this.data=r,this.gifSearch="",this.gifsFound=[]}searchGif(){this.gifSearch&&""!==this.gifSearch.trim()?this.data.apiKey?this.gifService.getTopGifs(this.gifSearch,this.data.apiKey).subscribe(e=>{this.gifsFound=e.results.map(n=>n.media[0].gif.url),this._changeDetectorRef.detectChanges()},e=>{console.error("Error fetching GIFs:",e)}):console.error("API key is missing."):console.error("Search term is empty.")}selectGif(e){this.dialogRef.close(e)}closeDialog(){this.dialogRef.close()}static{this.\u0275fac=function(n){return new(n||i)(t.rXU(St),t.rXU(E.CP),t.rXU(t.gRc),t.rXU(E.Vh))}}static{this.\u0275cmp=t.VBU({type:i,selectors:[["gif-dialog"]],decls:10,vars:3,consts:[["mat-dialog-content",""],["appearance","outline",1,"full-width"],["matInput","","placeholder","keyword...",3,"ngModelChange","keyup.enter","ngModel"],["mat-icon-button","","matSuffix","",1,"ml-2","mr-2",3,"click"],[3,"svgIcon"],["class","results-container mt-4 grid grid-cols-3 gap-4",4,"ngIf"],[1,"results-container","mt-4","grid","grid-cols-3","gap-4"],["class","gif-preview h-24 w-full cursor-pointer",3,"click",4,"ngFor","ngForOf"],[1,"gif-preview","h-24","w-full","cursor-pointer",3,"click"],[1,"h-full","w-full","object-cover",3,"src"]],template:function(n,o){1&n&&(t.j41(0,"div",0)(1,"mat-form-field",1)(2,"mat-label"),t.EFF(3,"Search GIF"),t.k0s(),t.j41(4,"input",2),t.mxI("ngModelChange",function(a){return t.DH7(o.gifSearch,a)||(o.gifSearch=a),a}),t.bIt("keyup.enter",function(){return o.searchGif()}),t.k0s(),t.j41(5,"button",3),t.bIt("click",function(){return o.searchGif()}),t.nrm(6,"mat-icon",4),t.k0s(),t.j41(7,"mat-hint"),t.EFF(8,'Enter a keyword like "funny" or "cat" and hit search!'),t.k0s()(),t.DNE(9,Mt,2,1,"div",5),t.k0s()),2&n&&(t.R7$(4),t.R50("ngModel",o.gifSearch),t.R7$(2),t.Y8G("svgIcon","heroicons_outline:magnifying-glass"),t.R7$(3),t.Y8G("ngIf",o.gifsFound.length>0))},dependencies:[C.vg,h.Hl,h.iY,g.m_,g.An,b.YN,b.me,b.BC,b.vS,p.nJ,p.rl,b.X1,f.MD,f.Sq,f.bT,Gt.Ve,p.MV,p.yw,p.RG,y.fS,y.fg],styles:[".full-width[_ngcontent-%COMP%]{width:100%}.results-container[_ngcontent-%COMP%]{max-height:300px;overflow-y:auto;overflow-x:hidden}.gif-preview[_ngcontent-%COMP%]{transition:transform .2s}.gif-preview[_ngcontent-%COMP%]:hover{transform:scale(1.1)}"],changeDetection:0})}}return i})();const Yt=i=>["/profile",i];function Nt(i,s){if(1&i&&t.nrm(0,"img",8),2&i){const e=t.XpG();t.Y8G("src",null==e.chat.contact?null:e.chat.contact.picture,t.B4B)("alt","Contact picture")}}function Bt(i,s){if(1&i&&(t.j41(0,"div",9),t.EFF(1),t.k0s()),2&i){const e=t.XpG();t.R7$(),t.SpI(" ",null==e.chat.contact?null:e.chat.contact.name.charAt(0)," ")}}let Xt=(()=>{class i{constructor(){}static{this.\u0275fac=function(n){return new(n||i)}}static{this.\u0275cmp=t.VBU({type:i,selectors:[["chat-contact-info"]],inputs:{chat:"chat",drawer:"drawer"},decls:16,vars:8,consts:[[1,"bg-card","flex","h-full","flex-auto","flex-col","dark:bg-default"],[1,"flex","h-18","flex-0","items-center","border-b","bg-gray-50","px-4","dark:bg-transparent"],["mat-icon-button","",3,"click"],[3,"svgIcon"],[1,"ml-2","text-lg","font-medium"],[1,"overflow-y-auto"],[1,"mt-8","flex","flex-col","items-center"],[1,"h-40","w-40","rounded-full"],["onerror","this.onerror=null; this.src='/images/avatars/avatar-placeholder.png';",1,"h-full","w-full","rounded-full","object-cover",3,"src","alt"],[1,"flex","h-full","w-full","items-center","justify-center","rounded-full","bg-gray-200","text-8xl","font-semibold","uppercase","text-gray-600","dark:bg-gray-700","dark:text-gray-200"],[1,"mt-4","text-lg","font-medium"],[3,"routerLink"],[1,"text-secondary","ml-4","mr-4","mt-0.5","text-md"]],template:function(n,o){1&n&&(t.j41(0,"div",0)(1,"div",1)(2,"button",2),t.bIt("click",function(){return o.drawer.close()}),t.nrm(3,"mat-icon",3),t.k0s(),t.j41(4,"div",4),t.EFF(5,"Contact info"),t.k0s()(),t.j41(6,"div",5)(7,"div",6)(8,"div",7),t.DNE(9,Nt,1,2,"img",8)(10,Bt,2,1,"div",9),t.k0s(),t.j41(11,"div",10)(12,"a",11),t.EFF(13),t.k0s()(),t.j41(14,"div",12),t.EFF(15),t.k0s()()()()),2&n&&(t.R7$(3),t.Y8G("svgIcon","heroicons_outline:x-mark"),t.R7$(6),t.vxM(null!=o.chat.contact&&o.chat.contact.picture?9:-1),t.R7$(),t.vxM(null!=o.chat.contact&&o.chat.contact.picture?-1:10),t.R7$(2),t.Y8G("routerLink",t.eq3(6,Yt,null==o.chat.contact?null:o.chat.contact.pubKey)),t.R7$(),t.SpI(" ",null==o.chat.contact?null:o.chat.contact.name," "),t.R7$(2),t.SpI(" ",null==o.chat.contact?null:o.chat.contact.about," "))},dependencies:[h.Hl,h.iY,g.m_,g.An,v.iI,v.Wk],encapsulation:2,changeDetection:0})}}return i})();var Dt=c(2012),At=c(1109),Pt=c(6388),Ut=c(9207);const Ot=["messageInput"],Vt=()=>["./"],Kt=i=>({active:i}),Lt=(i,s,e,n)=>({"items-end":i,"items-start":s,"mt-0.5":e,"mt-3":n}),Ht=(i,s)=>({"bg-gray-400 text-blue-50":i,"bg-gray-500 text-gray-50":s}),zt=(i,s)=>({"-right-1 -mr-px mb-px text-gray-400":i,"-left-1 -ml-px mb-px -scale-x-1 text-gray-500":s}),Wt=(i,s)=>({"mr-3":i,"ml-3":s});function Qt(i,s){if(1&i&&t.nrm(0,"img",15),2&i){const e=t.XpG(2);t.Y8G("src",null==e.chat.contact?null:e.chat.contact.avatar,t.B4B)}}function Zt(i,s){if(1&i&&(t.j41(0,"div",16),t.EFF(1),t.k0s()),2&i){const e=t.XpG(2);t.R7$(),t.SpI(" ",null==e.chat.contact?null:e.chat.contact.name.charAt(0)," ")}}function Jt(i,s){1&i&&(t.nrm(0,"mat-icon",12),t.EFF(1," Mute notifications ")),2&i&&t.Y8G("svgIcon","heroicons_outline:speaker-x-mark")}function qt(i,s){1&i&&(t.nrm(0,"mat-icon",12),t.EFF(1," Unmute notifications ")),2&i&&t.Y8G("svgIcon","heroicons_outline:speaker-wave")}function te(i,s){if(1&i&&(t.j41(0,"div",31),t.nrm(1,"div",33),t.j41(2,"div",34),t.EFF(3),t.nI1(4,"date"),t.k0s(),t.nrm(5,"div",33),t.k0s()),2&i){const e=t.XpG().$implicit;t.R7$(3),t.SpI(" ",t.i5U(4,1,e.createdAt,"longDate")," ")}}function ee(i,s){1&i&&t.eu8(0)}function ne(i,s){if(1&i&&(t.j41(0,"div",37),t.DNE(1,ee,1,0,"ng-container",40),t.k0s()),2&i){const e=t.XpG(2).$implicit;t.XpG(2);const n=t.sdS(4);t.Y8G("ngClass",t.l_i(2,zt,e.isMine,!e.isMine)),t.R7$(),t.Y8G("ngTemplateOutlet",n)}}function ie(i,s){if(1&i&&(t.j41(0,"div",44),t.nrm(1,"iframe",45),t.k0s()),2&i){const e=t.XpG().$implicit;t.R7$(),t.Y8G("src",e.safeWord,t.f$h)}}function oe(i,s){if(1&i&&(t.j41(0,"div",44),t.nrm(1,"img",46),t.k0s()),2&i){const e=t.XpG().$implicit;t.R7$(),t.Y8G("src",e.safeWord,t.B4B)}}function re(i,s){if(1&i&&(t.j41(0,"div",44)(1,"video",47),t.nrm(2,"source",48),t.EFF(3," Your browser does not support the video tag. "),t.k0s()()),2&i){const e=t.XpG().$implicit;t.R7$(2),t.Y8G("src",e.safeWord,t.B4B)}}function se(i,s){if(1&i&&(t.j41(0,"div",44)(1,"audio",49),t.nrm(2,"source",50),t.EFF(3," Your browser does not support the audio element. "),t.k0s()()),2&i){const e=t.XpG().$implicit;t.R7$(2),t.Y8G("src",e.safeWord,t.B4B)}}function ae(i,s){if(1&i&&(t.j41(0,"div",51)(1,"a",52),t.EFF(2),t.k0s()()),2&i){const e=t.XpG().$implicit;t.R7$(),t.Y8G("href",e.word,t.B4B),t.R7$(),t.JRh(e.word)}}function ce(i,s){if(1&i&&(t.j41(0,"span",51),t.EFF(1),t.k0s()),2&i){const e=t.XpG().$implicit;t.R7$(),t.JRh(e)}}function le(i,s){if(1&i&&(t.j41(0,"div",41),t.DNE(1,ie,2,1,"div",42)(2,oe,2,1,"div",42)(3,re,4,1,"div",42)(4,se,4,1,"div",42)(5,ae,3,2,"div",43)(6,ce,2,1,"span",43),t.k0s()),2&i){const e=s.$implicit;t.R7$(),t.Y8G("ngIf","youtube"===e.token),t.R7$(),t.Y8G("ngIf","image"===e.token),t.R7$(),t.Y8G("ngIf","video"===e.token),t.R7$(),t.Y8G("ngIf","audio"===e.token),t.R7$(),t.Y8G("ngIf","link"===e.token),t.R7$(),t.Y8G("ngIf",!e.token)}}function de(i,s){if(1&i&&(t.j41(0,"div",39),t.EFF(1),t.nI1(2,"date"),t.k0s()),2&i){const e=t.XpG(2).$implicit;t.Y8G("ngClass",t.l_i(5,Wt,e.isMine,!e.isMine)),t.R7$(),t.SpI(" ",t.i5U(2,2,e.createdAt,"HH:mm")," ")}}function ue(i,s){if(1&i&&(t.j41(0,"div")(1,"div",35)(2,"div",36),t.DNE(3,ne,2,5,"div",37)(4,le,7,6,"div",38),t.k0s(),t.DNE(5,de,3,8,"div",39),t.k0s()()),2&i){const e=t.XpG(),n=e.$implicit,o=e.$index,r=e.$count,a=t.XpG(2);t.R7$(),t.Y8G("ngClass",t.ziG(6,Lt,n.isMine,!n.isMine,o>0&&a.chat.messages[o-1].isMine===n.isMine,o>0&&a.chat.messages[o-1].isMine!==n.isMine)),t.R7$(),t.Y8G("ngClass",t.l_i(11,Ht,n.isMine,!n.isMine)),t.R7$(),t.vxM(o===r-1||a.chat.messages[o+1].isMine!==n.isMine?3:-1),t.R7$(),t.Y8G("ngForOf",a.parseContent.parseContent(n.value))("ngForTrackBy",a.trackByFn),t.R7$(),t.vxM(0===o||o===r-1||a.chat.messages[o+1].isMine!==n.isMine||a.chat.messages[o+1].createdAt!==n.createdAt?5:-1)}}function me(i,s){if(1&i&&(t.DNE(0,te,6,4,"div",31),t.nI1(1,"date"),t.nI1(2,"date"),t.DNE(3,ue,6,14,"div",32)),2&i){const e=s.$implicit,n=s.$index,o=t.XpG(2);t.vxM(0===n||t.i5U(1,2,o.chat.messages[n-1].createdAt,"d")!==t.i5U(2,5,e.createdAt,"d")?0:-1),t.R7$(3),t.Y8G("ngIf",!e.id.includes("new-chat"))}}function he(i,s){if(1&i){const e=t.RV6();t.j41(0,"div",53)(1,"emoji-mart",54),t.bIt("emojiClick",function(o){t.eBV(e);const r=t.XpG(2);return t.Njj(r.addEmoji(o))}),t.k0s()()}if(2&i){const e=t.XpG(2);t.R7$(),t.Y8G("darkMode",e.darkMode)}}function pe(i,s){if(1&i){const e=t.RV6();t.j41(0,"mat-drawer-container",5)(1,"mat-drawer",7,1),t.mxI("openedChange",function(o){t.eBV(e);const r=t.XpG();return t.DH7(r.drawerOpened,o)||(r.drawerOpened=o),t.Njj(o)}),t.nrm(3,"chat-contact-info",8),t.k0s(),t.j41(4,"mat-drawer-content",9)(5,"div",10)(6,"a",11),t.bIt("click",function(){t.eBV(e);const o=t.XpG();return t.Njj(o.resetChat())}),t.nrm(7,"mat-icon",12),t.k0s(),t.j41(8,"div",13),t.bIt("click",function(){t.eBV(e);const o=t.XpG();return t.Njj(o.openContactInfo())}),t.j41(9,"div",14),t.DNE(10,Qt,1,1,"img",15)(11,Zt,2,1,"div",16),t.k0s(),t.j41(12,"div",17),t.EFF(13),t.k0s()(),t.j41(14,"button",18),t.nrm(15,"mat-icon",12),t.j41(16,"mat-menu",null,2)(18,"button",19),t.bIt("click",function(){t.eBV(e);const o=t.XpG();return t.Njj(o.openContactInfo())}),t.nrm(19,"mat-icon",12),t.EFF(20," Contact info "),t.k0s(),t.j41(21,"button",20),t.nrm(22,"mat-icon",12),t.EFF(23," Select messages "),t.k0s(),t.j41(24,"button",19),t.bIt("click",function(){t.eBV(e);const o=t.XpG();return t.Njj(o.toggleMuteNotifications())}),t.DNE(25,Jt,2,1)(26,qt,2,1),t.k0s(),t.j41(27,"button",20),t.nrm(28,"mat-icon",12),t.EFF(29," Clear messages "),t.k0s(),t.j41(30,"button",20),t.nrm(31,"mat-icon",12),t.EFF(32," Delete chat "),t.k0s()()()(),t.j41(33,"div",21)(34,"div",22),t.Z7z(35,me,4,8,null,null,t.BUC().trackByFn,!0),t.k0s()(),t.j41(37,"div",23)(38,"div",24)(39,"button",25),t.bIt("click",function(){t.eBV(e);const o=t.XpG();return t.Njj(o.openGifDialog())}),t.nrm(40,"mat-icon",12),t.k0s(),t.j41(41,"button",25),t.bIt("click",function(){t.eBV(e);const o=t.XpG();return t.Njj(o.toggleEmojiPicker())}),t.nrm(42,"mat-icon",12),t.k0s(),t.DNE(43,he,2,1,"div",26),t.j41(44,"button",25),t.bIt("click",function(){t.eBV(e);const o=t.XpG();return t.Njj(o.toggleSpeechRecognition())}),t.nrm(45,"mat-icon",27),t.k0s()(),t.j41(46,"mat-form-field",28)(47,"textarea",29,3),t.bIt("keydown",function(o){t.eBV(e);const r=t.XpG();return t.Njj(r.handleKeyDown(o))}),t.k0s()(),t.j41(49,"div",30)(50,"button",25),t.bIt("click",function(){t.eBV(e);const o=t.XpG();return t.Njj(o.sendMessage())}),t.nrm(51,"mat-icon",12),t.k0s()()()()()}if(2&i){const e=t.sdS(2),n=t.sdS(17),o=t.XpG();t.Y8G("hasBackdrop",!1),t.R7$(),t.Y8G("autoFocus",!1)("mode",o.drawerMode)("position","end"),t.R50("opened",o.drawerOpened),t.R7$(2),t.Y8G("drawer",e)("chat",o.chat),t.R7$(3),t.Y8G("routerLink",t.lJ4(26,Vt)),t.R7$(),t.Y8G("svgIcon","heroicons_outline:arrow-long-left"),t.R7$(3),t.vxM(null!=o.chat.contact&&o.chat.contact.avatar?10:-1),t.R7$(),t.vxM(null!=o.chat.contact&&o.chat.contact.avatar?-1:11),t.R7$(2),t.SpI(" ",null==o.chat.contact?null:o.chat.contact.name," "),t.R7$(),t.Y8G("matMenuTriggerFor",n),t.R7$(),t.Y8G("svgIcon","heroicons_outline:ellipsis-vertical"),t.R7$(4),t.Y8G("svgIcon","heroicons_outline:user-circle"),t.R7$(3),t.Y8G("svgIcon","heroicons_outline:check-circle"),t.R7$(3),t.vxM(o.chat.muted?-1:25),t.R7$(),t.vxM(o.chat.muted?26:-1),t.R7$(2),t.Y8G("svgIcon","heroicons_outline:backspace"),t.R7$(3),t.Y8G("svgIcon","heroicons_outline:trash"),t.R7$(4),t.Dyx(o.chat.messages),t.R7$(5),t.Y8G("svgIcon","heroicons_outline:gif"),t.R7$(2),t.Y8G("svgIcon","heroicons_outline:face-smile"),t.R7$(),t.Y8G("ngIf",o.showEmojiPicker),t.R7$(2),t.Y8G("ngClass",t.eq3(27,Kt,o.isListening))("svgIcon",o.isListening?"heroicons_solid:microphone":"heroicons_outline:microphone"),t.R7$(6),t.Y8G("svgIcon","heroicons_outline:paper-airplane")}}function ge(i,s){1&i&&(t.j41(0,"div",6),t.nrm(1,"mat-icon",55),t.j41(2,"div",56),t.EFF(3," Select a conversation or start a new chat "),t.k0s()()),2&i&&(t.R7$(),t.Y8G("svgIcon","heroicons_outline:chat-bubble-oval-left-ellipsis"))}function fe(i,s){1&i&&(t.qSk(),t.j41(0,"svg",57)(1,"g",58),t.nrm(2,"path",59),t.k0s()())}const _e=[{path:"",component:O,resolve:{chats:()=>(0,t.WQX)(x).getChats(),contacts:()=>(0,t.WQX)(x).getContacts(),profile:()=>(0,t.WQX)(x).getProfile()},children:[{path:"",component:jt,children:[{path:"",pathMatch:"full",component:Rt},{path:":id",component:(()=>{class i{constructor(e,n,o,r,a,u,l,d){this._changeDetectorRef=e,this._chatService=n,this._angorMediaWatcherService=o,this._ngZone=r,this._angorConfigService=a,this.dialog=u,this.sanitizer=l,this.parseContent=d,this.drawerMode="side",this.drawerOpened=!1,this._unsubscribeAll=new j.B,this.showEmojiPicker=!1,this.darkMode=!1,this.finalTranscript="",this.isListening=!1,this.userEdited=!1;const m=window.SpeechRecognition||window.webkitSpeechRecognition;m?(this.recognition=new m,this.recognition.lang="en-US",this.recognition.continuous=!0,this.recognition.interimResults=!0,this.setupRecognitionEvents()):console.error("Speech recognition is not supported in this browser.")}openGifDialog(){this.dialog.open(Tt,{width:"600px",maxHeight:"80vh",data:{apiKey:"LIVDSRZULELA"}}).afterClosed().subscribe(n=>{if(n){const o=n;o&&(this.messageInput.nativeElement.value="",this._chatService.sendPrivateMessage(o).then(()=>{this.messageInput.nativeElement.value="",this.finalTranscript=""}).catch(r=>{console.error("Failed to send message:",r)}),this.finalTranscript="",this.userEdited=!1)}})}ngOnInit(){this._angorConfigService.config$.subscribe(e=>{"auto"===e.scheme?this.detectSystemTheme():this.darkMode="dark"===e.scheme}),this._chatService.chat$.pipe((0,F.Q)(this._unsubscribeAll)).subscribe(e=>{this.chat=e,this._changeDetectorRef.markForCheck()}),this._angorMediaWatcherService.onMediaChange$.pipe((0,F.Q)(this._unsubscribeAll)).subscribe(({matchingAliases:e})=>{this.drawerMode=e.includes("lg")?"side":"over",this._changeDetectorRef.markForCheck()})}_resizeMessageInput(){this._ngZone.runOutsideAngular(()=>{setTimeout(()=>{this.messageInput.nativeElement.style.height="auto",this._changeDetectorRef.detectChanges(),this.messageInput.nativeElement.style.height=`${this.messageInput.nativeElement.scrollHeight}px`,this._changeDetectorRef.detectChanges()})})}setupRecognitionEvents(){this.recognition.onresult=e=>{let n="";for(let o=e.resultIndex;o{console.error("Speech recognition error detected: ",e.error)},this.recognition.onend=()=>{this.isListening=!1}}toggleSpeechRecognition(){this.finalTranscript="",this.isListening?(this.recognition.stop(),this.isListening=!1):(this.recognition.start(),this.isListening=!0,this.userEdited=!1)}handleUserInput(e){this.userEdited=!0}ngOnDestroy(){this._unsubscribeAll.next(null),this._unsubscribeAll.complete()}openContactInfo(){this.drawerOpened=!0,this._changeDetectorRef.markForCheck()}resetChat(){this._chatService.resetChat(),this.drawerOpened=!1,this._changeDetectorRef.markForCheck()}toggleMuteNotifications(){this.chat.muted=!this.chat.muted,this._chatService.updateChat(this.chat.id,this.chat).subscribe()}trackByFn(e,n){return n.id||e}detectSystemTheme(){const e=window.matchMedia("(prefers-color-scheme: dark)");this.darkMode=e.matches,e.addEventListener("change",n=>{this.darkMode=n.matches})}handleKeyDown(e){"Enter"===e.key&&!e.shiftKey&&(e.preventDefault(),this.sendMessage())}sendMessage(){const e=this.messageInput.nativeElement.value.trim();e&&(this.messageInput.nativeElement.value="",this._chatService.sendPrivateMessage(e).then(()=>{this.messageInput.nativeElement.value="",this.finalTranscript=""}).catch(n=>{console.error("Failed to send message:",n)}),this.finalTranscript="",this.userEdited=!1)}addEmoji(e){this.messageInput.nativeElement.value+=e.emoji.native,this.showEmojiPicker=!1}toggleEmojiPicker(){this.showEmojiPicker=!this.showEmojiPicker}static{this.\u0275fac=function(n){return new(n||i)(t.rXU(t.gRc),t.rXU(x),t.rXU(Dt.l),t.rXU(t.SKi),t.rXU(At.P),t.rXU(E.bZ),t.rXU(Pt.up),t.rXU(Ut.m))}}static{this.\u0275cmp=t.VBU({type:i,selectors:[["chat-conversation"]],viewQuery:function(n,o){if(1&n&&t.GBs(Ot,5),2&n){let r;t.mGM(r=t.lsd())&&(o.messageInput=r.first)}},hostBindings:function(n,o){1&n&&t.bIt("input",function(){return o._resizeMessageInput()})("ngModelChange",function(){return o._resizeMessageInput()})},decls:5,vars:1,consts:[["speechBubbleExtension",""],["drawer",""],["conversationHeaderMenu",""],["messageInput",""],[1,"bg-card","flex","flex-auto","flex-col","overflow-y-auto","dark:bg-default","lg:overflow-hidden"],[1,"h-full","flex-auto",3,"hasBackdrop"],[1,"flex","flex-auto","flex-col","items-center","justify-center","bg-gray-100","dark:bg-transparent"],[1,"w-full","dark:bg-gray-900","sm:w-100","lg:border-l","lg:shadow-none",3,"openedChange","autoFocus","mode","position","opened"],[3,"drawer","chat"],[1,"flex","flex-col","overflow-hidden"],[1,"flex","h-18","flex-0","items-center","border-b","bg-gray-50","px-4","dark:bg-transparent","md:px-6"],["mat-icon-button","",1,"md:-ml-2","lg:hidden",3,"click","routerLink"],[3,"svgIcon"],[1,"ml-2","mr-2","flex","cursor-pointer","items-center","lg:ml-0",3,"click"],[1,"relative","flex","h-10","w-10","flex-0","items-center","justify-center"],["onerror","this.onerror=null; this.src='/images/avatars/avatar-placeholder.png';","alt","Contact picture",1,"h-full","w-full","rounded-full","object-cover",3,"src"],[1,"flex","h-full","w-full","items-center","justify-center","rounded-full","bg-gray-200","text-lg","uppercase","text-gray-600","dark:bg-gray-700","dark:text-gray-200"],[1,"ml-4","truncate","text-lg","font-medium","leading-5"],["mat-icon-button","",1,"ml-auto",3,"matMenuTriggerFor"],["mat-menu-item","",3,"click"],["mat-menu-item",""],[1,"flex","h-full","flex-col-reverse","overflow-y-auto"],[1,"bg-card","flex","flex-auto","shrink","flex-col","p-6","dark:bg-transparent"],[1,"flex","items-end","border-t","bg-gray-50","p-4","dark:bg-transparent"],[1,"my-px","flex","h-11","items-center"],["mat-icon-button","",3,"click"],["class","emoji-picker-container",4,"ngIf"],[3,"ngClass","svgIcon"],["subscriptSizing","dynamic",1,"angor-mat-dense","angor-mat-rounded","angor-mat-bold","ml-4","w-full"],["matInput","","cdkTextareaAutosize","",1,"max-h-20",3,"keydown"],[1,"my-px","ml-4","flex","h-11","items-center"],[1,"-mx-6","my-3","flex","items-center","justify-center"],[4,"ngIf"],[1,"flex-auto","border-b"],[1,"text-secondary","mx-4","flex-0","text-sm","font-medium","leading-5"],[1,"flex","flex-col",3,"ngClass"],[1,"relative","max-w-3/4","rounded-lg","px-2","py-2",3,"ngClass"],[1,"absolute","bottom-0","w-3",3,"ngClass"],["style","display: inline-block; overflow-wrap: break-word; white-space: pre-wrap;",4,"ngFor","ngForOf","ngForTrackBy"],[1,"text-secondary","my-0.5","text-sm","font-medium",3,"ngClass"],[4,"ngTemplateOutlet"],[2,"display","inline-block","overflow-wrap","break-word","white-space","pre-wrap"],["style","display: block;",4,"ngIf"],["style","display: inline-block; overflow-wrap: break-word;",4,"ngIf"],[2,"display","block"],["width","560","height","315","frameborder","0","allowfullscreen","",3,"src"],["alt","Embedded Image",2,"max-width","100%",3,"src"],["controls","",2,"max-width","100%"],["type","video/mp4",3,"src"],["controls",""],["type","audio/mpeg",3,"src"],[2,"display","inline-block","overflow-wrap","break-word"],["target","_blank",3,"href"],[1,"emoji-picker-container"],[3,"emojiClick","darkMode"],[1,"icon-size-24",3,"svgIcon"],[1,"text-secondary","mt-4","text-2xl","font-semibold","tracking-tight"],["width","100%","height","100%","viewBox","0 0 66 66","xmlns","http://www.w3.org/2000/svg"],["id","Page-1","stroke","none","stroke-width","1","fill","none","fill-rule","evenodd"],["d","M1.01522827,0.516204834 C-8.83532715,54.3062744 61.7609863,70.5215302 64.8009949,64.3061218 C68.8074951,54.8859711 30.1663208,52.9997559 37.5036011,0.516204834 L1.01522827,0.516204834 Z","fill","currentColor","fill-rule","nonzero"]],template:function(n,o){1&n&&(t.j41(0,"div",4),t.DNE(1,pe,52,29,"mat-drawer-container",5)(2,ge,4,1,"div",6)(3,fe,3,0,"ng-template",null,0,t.C5r),t.k0s()),2&n&&(t.R7$(),t.vxM(o.chat?1:2))},dependencies:[C.vg,C.qe,C.$C,C.$l,Xt,h.Hl,h.pQ,h.iY,v.Wk,g.m_,g.An,k.Cn,k.kk,k.fb,k.Cp,f.YU,f.T3,p.RG,p.rl,y.fS,y.fg,A.xb,A.EE,f.vh,$t.Ic,f.MD,f.Sq,f.bT],styles:[".c-img,.c-video{max-width:100%;border-radius:10px}\n"],encapsulation:2,changeDetection:0})}}return i})(),resolve:{conversation:(i,s)=>{const e=(0,t.WQX)(x),n=(0,t.WQX)(v.Ix);let o=i.paramMap.get("id")||localStorage.getItem("currentChatId");if(!o){const r=s.url.split("/").slice(0,-1).join("/");return n.navigateByUrl(r),(0,R.$)("No chat ID provided")}return localStorage.setItem("currentChatId",o),e.getChatById(o).pipe((0,S.W)(r=>{console.error("Error fetching conversation:",r);const a=s.url.split("/").slice(0,-1).join("/");return n.navigateByUrl(a),(0,R.$)(r)}))}}}]}]}]}}]); \ No newline at end of file diff --git a/544.8d04d0914a5c873b.js b/544.eda92231287fa498.js similarity index 54% rename from 544.8d04d0914a5c873b.js rename to 544.eda92231287fa498.js index 4ebdbd4..b062a12 100644 --- a/544.8d04d0914a5c873b.js +++ b/544.eda92231287fa498.js @@ -1 +1 @@ -"use strict";(self.webpackChunkangor=self.webpackChunkangor||[]).push([[544],{6544:(vt,f,o)=>{o.r(f),o.d(f,{default:()=>mt});var m=o(3014),d=o(4460),R=o(8447),y=o(5710),E=o(5424),I=o(7785),h=o(708),u=o(9471),C=o(7702),G=o(2835),g=o(6071),_=o(3904),$=o(7818),b=o(1054),p=o(936),S=o(9363),P=o(9561),x=o(6389),F=o(5785),Y=o(7712),t=o(3107),k=o(3149),T=o(7121);let X=(()=>{class i{constructor(e,n,s){this._changeDetectorRef=e,this._storageService=n,this._metadatasService=s}ngOnInit(){this.loadUserProfile(),this._metadatasService.addPublicKey(this.pubkey),this.subscription=this._storageService.profile$.subscribe(e=>{e&&e.pubKey===this.pubkey&&(this.user=e.metadata,console.log(this.user),this._changeDetectorRef.detectChanges())})}loadUserProfile(){var e=this;return(0,m.A)(function*(){const n=yield e._storageService.getProfile(e.pubkey);e.user=n||{},e._changeDetectorRef.detectChanges()})()}get displayName(){return this.user?.display_name||this.user?.name||this.shortenPubkey(this.pubkey)}get displayAvatar(){return this.user?.picture||this.avatarUrl||"/images/avatars/avatar-placeholder.png"}shortenPubkey(e){return e?`${e.slice(0,8)}...${e.slice(-8)}`:""}ngOnDestroy(){this.subscription&&this.subscription.unsubscribe()}static{this.\u0275fac=function(n){return new(n||i)(t.rXU(t.gRc),t.rXU(k.n),t.rXU(T.T))}}static{this.\u0275cmp=t.VBU({type:i,selectors:[["app-replay-profile"]],inputs:{pubkey:"pubkey",avatarUrl:"avatarUrl"},decls:5,vars:4,consts:[[1,"flex","items-center"],[1,"flex","items-center","group",3,"href"],[1,"mr-4","h-10","w-10","rounded-full","border","border-gray-300","group-hover:shadow-md","object-cover",3,"src","alt"],[1,"font-bold","text-gray-800","group-hover:text-blue-500"]],template:function(n,s){1&n&&(t.j41(0,"div",0)(1,"a",1),t.nrm(2,"img",2),t.j41(3,"span",3),t.EFF(4),t.k0s()()()),2&n&&(t.R7$(),t.Y8G("href","/profile/"+s.pubkey,t.B4B),t.R7$(),t.Y8G("src",s.displayAvatar,t.B4B)("alt",s.displayName),t.R7$(2),t.SpI(" ",s.displayName," "))},dependencies:[d.MD],encapsulation:2})}}return i})();var D=o(5727),U=o(1556),j=o(8716),B=o(5506),N=o(9207),V=o(6388),w=o(5616),z=o(7153),L=o(3303);const A=i=>({"heart-beat":i}),M=i=>({"rotate-180":i}),O=()=>[];function W(i,r){1&i&&(t.j41(0,"div",5),t.nrm(1,"mat-progress-spinner",6),t.k0s()),2&i&&(t.R7$(),t.Y8G("diameter",50))}function Z(i,r){1&i&&(t.j41(0,"span"),t.EFF(1,"s"),t.k0s())}function H(i,r){1&i&&(t.j41(0,"span"),t.EFF(1,"s"),t.k0s())}function J(i,r){1&i&&(t.j41(0,"span"),t.EFF(1,"s"),t.k0s())}function K(i,r){if(1&i){const e=t.RV6();t.j41(0,"div",34)(1,"div",27)(2,"div",35),t.EFF(3),t.DNE(4,Z,2,0,"span",4),t.k0s()(),t.nrm(5,"div",36),t.j41(6,"div",37)(7,"button",38),t.EFF(8),t.DNE(9,H,2,0,"span",4),t.k0s(),t.j41(10,"button",38),t.EFF(11),t.DNE(12,J,2,0,"span",4),t.k0s(),t.j41(13,"button",39),t.bIt("click",function(){t.eBV(e),t.XpG();const s=t.sdS(4);return t.Njj(s.expanded=!s.expanded)}),t.j41(14,"span",40),t.EFF(15),t.k0s(),t.nrm(16,"mat-icon",41),t.k0s()()()}if(2&i){t.XpG();const e=t.sdS(4),n=t.XpG();t.R7$(3),t.SpI(" ",n.zaps.length," Zap"),t.R7$(),t.Y8G("ngIf",n.zaps.length>1),t.R7$(4),t.SpI(" ",n.likes.length," Like"),t.R7$(),t.Y8G("ngIf",n.likes.length>1),t.R7$(2),t.SpI(" ",n.reposts.length," Share"),t.R7$(),t.Y8G("ngIf",n.reposts.length>1),t.R7$(3),t.SpI("",n.replies.length," Comments"),t.R7$(),t.Y8G("ngClass",t.eq3(9,M,e.expanded))("svgIcon","heroicons_mini:chevron-down")}}function Q(i,r){1&i&&(t.j41(0,"div",42),t.nrm(1,"mat-progress-spinner",6),t.k0s()),2&i&&(t.R7$(),t.Y8G("diameter",40))}function q(i,r){if(1&i){const e=t.RV6();t.j41(0,"div",43)(1,"emoji-mart",44),t.bIt("emojiClick",function(s){t.eBV(e);const a=t.XpG(2);return t.Njj(a.addEmoji(s))}),t.k0s()()}if(2&i){const e=t.XpG(2);t.R7$(),t.Y8G("darkMode",e.darkMode)}}function tt(i,r){if(1&i&&(t.qex(0),t.j41(1,"div",55),t.nrm(2,"iframe",56),t.k0s(),t.bVm()),2&i){const e=t.XpG().$implicit;t.R7$(2),t.Y8G("src",null==e?null:e.safeWord,t.f$h)}}function et(i,r){if(1&i&&(t.qex(0),t.j41(1,"div",55),t.nrm(2,"img",57),t.k0s(),t.bVm()),2&i){const e=t.XpG().$implicit;t.R7$(2),t.Y8G("src",null==e?null:e.safeWord,t.B4B)}}function nt(i,r){if(1&i&&(t.qex(0),t.j41(1,"div",55)(2,"video",58),t.nrm(3,"source",59),t.EFF(4," Your browser does not support the video tag. "),t.k0s()(),t.bVm()),2&i){const e=t.XpG().$implicit;t.R7$(3),t.Y8G("src",null==e?null:e.safeWord,t.B4B)}}function it(i,r){if(1&i&&(t.qex(0),t.j41(1,"div",55)(2,"audio",60),t.nrm(3,"source",61),t.EFF(4," Your browser does not support the audio element. "),t.k0s()(),t.bVm()),2&i){const e=t.XpG().$implicit;t.R7$(3),t.Y8G("src",null==e?null:e.safeWord,t.B4B)}}function st(i,r){if(1&i&&(t.qex(0),t.j41(1,"div",62)(2,"a",63)(3,"span",64),t.EFF(4),t.k0s()()(),t.bVm()),2&i){const e=t.XpG().$implicit;t.R7$(2),t.Y8G("href",null==e?null:e.word,t.B4B),t.R7$(2),t.SpI(" ",null==e?null:e.word," ")}}function ot(i,r){if(1&i&&(t.qex(0),t.j41(1,"div",65)(2,"span",64),t.EFF(3),t.k0s()(),t.bVm()),2&i){const e=t.XpG().$implicit;t.R7$(3),t.SpI(" ",null==e?null:e.trim()," ")}}function rt(i,r){if(1&i&&(t.j41(0,"div",54),t.DNE(1,tt,3,1,"ng-container",4)(2,et,3,1,"ng-container",4)(3,nt,5,1,"ng-container",4)(4,it,5,1,"ng-container",4)(5,st,5,2,"ng-container",4)(6,ot,4,1,"ng-container",4),t.k0s()),2&i){const e=r.$implicit;t.R7$(),t.Y8G("ngIf","youtube"===(null==e?null:e.token)),t.R7$(),t.Y8G("ngIf","image"===(null==e?null:e.token)),t.R7$(),t.Y8G("ngIf","video"===(null==e?null:e.token)),t.R7$(),t.Y8G("ngIf","audio"===(null==e?null:e.token)),t.R7$(),t.Y8G("ngIf","link"===(null==e?null:e.token)),t.R7$(),t.Y8G("ngIf",!(null!=e&&e.token))}}function at(i,r){if(1&i&&(t.j41(0,"div",49),t.nrm(1,"app-replay-profile",50),t.j41(2,"div",51)(3,"span"),t.DNE(4,rt,7,6,"div",52),t.k0s(),t.j41(5,"div",53)(6,"span"),t.EFF(7),t.nI1(8,"ago"),t.k0s()()()()),2&i){const e=r.$implicit,n=t.XpG(3);t.R7$(),t.Y8G("pubkey",null==e?null:e.pubkey)("avatarUrl","/images/avatars/avatar-placeholder.png"),t.R7$(3),t.Y8G("ngForOf",n._parseContent.parseContent(null==e?null:e.content)||t.lJ4(6,O)),t.R7$(3),t.JRh(t.bMT(8,4,null==e?null:e.created_at))}}function ct(i,r){if(1&i&&(t.j41(0,"div"),t.nrm(1,"hr",45),t.j41(2,"div",46)(3,"div",47),t.DNE(4,at,9,7,"div",48),t.k0s()()()),2&i){const e=t.XpG(2);t.R7$(4),t.Y8G("ngForOf",e.replies)}}function lt(i,r){if(1&i){const e=t.RV6();t.j41(0,"div")(1,"div",7),t.nrm(2,"app-post",8),t.j41(3,"angor-card",9,0)(5,"div",10)(6,"button",11),t.bIt("click",function(){t.eBV(e);const s=t.XpG();return t.Njj(s.toggleLike(s.post))}),t.nrm(7,"mat-icon",12),t.j41(8,"span",13),t.EFF(9),t.k0s()(),t.j41(10,"button",11),t.bIt("click",function(){t.eBV(e);const s=t.sdS(4);return t.Njj(s.expanded=!s.expanded)}),t.nrm(11,"mat-icon",14),t.j41(12,"span",13),t.EFF(13,"Comment"),t.k0s()(),t.j41(14,"button",11),t.bIt("click",function(){t.eBV(e);const s=t.XpG();return t.Njj(s.onShare(s.post))}),t.nrm(15,"mat-icon",15),t.j41(16,"span",13),t.EFF(17,"Share"),t.k0s()(),t.j41(18,"button",11),t.bIt("click",function(){t.eBV(e);const s=t.XpG();return t.Njj(s.openZapDialog())}),t.nrm(19,"mat-icon",16),t.j41(20,"span",13),t.EFF(21,"Zap"),t.k0s()()(),t.nrm(22,"hr",17),t.DNE(23,K,17,11,"div",18)(24,Q,2,1,"div",19),t.qex(25,20),t.nrm(26,"hr",21),t.j41(27,"div",22)(28,"div",23)(29,"mat-form-field",24)(30,"textarea",25),t.mxI("ngModelChange",function(s){t.eBV(e);const a=t.XpG();return t.DH7(a.comment,s)||(a.comment=s),t.Njj(s)}),t.k0s()()(),t.j41(31,"div",26)(32,"div",27)(33,"button",28),t.bIt("click",function(){t.eBV(e);const s=t.XpG();return t.Njj(s.toggleEmojiPicker())}),t.nrm(34,"mat-icon",29),t.k0s(),t.DNE(35,q,2,1,"div",30),t.j41(36,"button",31),t.nrm(37,"mat-icon",29),t.k0s(),t.j41(38,"button",31),t.nrm(39,"mat-icon",29),t.k0s()(),t.j41(40,"button",32),t.bIt("click",function(){t.eBV(e);const s=t.XpG();return t.Njj(s.sendComment(s.post))}),t.nrm(41,"mat-icon",33),t.j41(42,"span",13),t.EFF(43,"Send"),t.k0s()()()(),t.DNE(44,ct,5,1,"div",4),t.bVm(),t.k0s()()()}if(2&i){const e=t.XpG();t.R7$(2),t.Y8G("item",e.post)("more",!1)("actions",!1),t.R7$(5),t.Y8G("ngClass",t.eq3(21,A,e.isLiked))("svgIcon",e.isLiked?"heroicons_solid:heart":"heroicons_outline:heart"),t.R7$(2),t.SpI("",e.isLiked?"Liked":"Like"," "),t.R7$(2),t.Y8G("svgIcon","heroicons_solid:chat-bubble-left-ellipsis"),t.R7$(4),t.Y8G("svgIcon","heroicons_solid:share"),t.R7$(4),t.Y8G("svgIcon","heroicons_solid:bolt"),t.R7$(4),t.Y8G("ngIf",!e.loadingReactions),t.R7$(),t.Y8G("ngIf",e.loadingReactions),t.R7$(5),t.Y8G("subscriptSizing","dynamic"),t.R7$(),t.Y8G("placeholder","Write a comment...")("rows",3),t.R50("ngModel",e.comment),t.R7$(4),t.Y8G("svgIcon","heroicons_solid:face-smile"),t.R7$(),t.Y8G("ngIf",e.showEmojiPicker),t.R7$(2),t.Y8G("svgIcon","heroicons_solid:photo"),t.R7$(2),t.Y8G("svgIcon","heroicons_solid:sparkles"),t.R7$(2),t.Y8G("svgIcon","heroicons_solid:paper-airplane"),t.R7$(3),t.Y8G("ngIf",e.replies.length>0)}}const mt=[{path:"",component:(()=>{class i{constructor(e,n,s,a,l,c,v,dt,pt,ut){this._route=e,this._router=n,this._storageService=s,this._subscriptionService=a,this._changeDetectorRef=l,this._parseContent=c,this._sanitizer=v,this._eventService=dt,this._angorConfirmationService=pt,this._zapService=ut,this.postId=null,this.post=null,this.user=null,this.loading=!0,this.loadingReactions=!0,this._unsubscribeAll=new R.B,this.subscription=new y.yU,this.likes=[],this.reposts=[],this.zaps=[],this.replies=[],this.isLiked=!1}ngOnInit(){this._route.paramMap.pipe((0,E.Q)(this._unsubscribeAll)).subscribe(e=>{this.postId=e.get("id"),this.postId&&(this.loadPost(this.postId),this.subscribeToReactions(this.postId))}),this.subscription=this._storageService.myLikes$.subscribe(e=>{e&&e.includes(this.postId)?(this.isLiked=!0,this._changeDetectorRef.detectChanges()):this.isLiked=!1})}loadUserProfile(){var e=this;return(0,m.A)(function*(){e._storageService.getProfile(e.post.pubkey).then(n=>{e.user=n,e._changeDetectorRef.detectChanges()})})()}loadPost(e){var n=this;return(0,m.A)(function*(){try{if(n.loading=!0,n.post=yield n._storageService.getPostById(e),n.post)n.loading=!1,yield n.loadUserProfile();else{const a=n._subscriptionService.addSubscriptions([{ids:[e],kinds:[1],limit:1}],function(){var l=(0,m.A)(function*(c){n.post=c,console.log(n.post),n._changeDetectorRef.detectChanges(),yield n._storageService.savePost(c),n._changeDetectorRef.detectChanges(),a&&n._subscriptionService.removeSubscriptionById(a),n.loading=!1});return function(c){return l.apply(this,arguments)}}())}}catch(s){console.error("Error loading post:",s),n._router.navigate(["/404"])}})()}getSafeUrl(e){return this._sanitizer.bypassSecurityTrustUrl(e)}subscribeToReactions(e){var n=this;let s;this.loadingReactions=!0,s=setTimeout(()=>{this.loadingReactions=!1},3e3),this.subscriptionId=this._subscriptionService.addSubscriptions([{"#e":[e],kinds:[1,7,9735,6]}],function(){var l=(0,m.A)(function*(c){n.loadingReactions&&(n.loadingReactions=!1,clearTimeout(s)),n.addReaction(e,c.kind,{pubkey:c.pubkey,created_at:c.created_at,content:1===c.kind?c.content:void 0})});return function(c){return l.apply(this,arguments)}}())}addReaction(e,n,s){switch(n){case 1:this.replies.push(s),this.replies.sort((a,l)=>l.created_at-a.created_at);break;case 7:this.likes.push(s);break;case 9735:this.zaps.push(s);break;case 6:this.reposts.push(s)}this._changeDetectorRef.detectChanges()}isSingleEmojiOrWord(e){const n=e.trim(),s=/^\w+$/.test(n),a=/^[\p{Emoji}]+$/u.test(n);return s||a}sendLike(e){this.isLiked||this._eventService.sendLikeEvent(e).then(()=>{this.isLiked=!0,this._changeDetectorRef.detectChanges()}).catch(n=>console.error("Failed to send like:",n))}toggleLike(e){this.sendLike(e)}onShare(e){this._angorConfirmationService.open({title:"Share",message:'Are you sure you want to share this post on your profile? This action is permanent and cannot be undone.',icon:{show:!0,name:"heroicons_solid:share",color:"primary"},actions:{confirm:{show:!0,label:"Yes, Share",color:"primary"},cancel:{show:!0,label:"Cancel"}},dismissible:!0}).afterClosed().subscribe(s=>{console.log(s),"confirmed"===s&&this._eventService.shareEvent(e).then(()=>{this._changeDetectorRef.detectChanges()}).catch(a=>console.error("Failed to share post",a))})}openZapDialog(){this._zapService.openZapDialog(this.postId,this.user)}sendComment(e){""!==this.comment.trim()&&this._eventService.sendReplyEvent(e,this.comment).then(()=>{this.comment="",this._changeDetectorRef.markForCheck()})}toggleEmojiPicker(){this.showEmojiPicker=!this.showEmojiPicker}addEmoji(e){e&&e.emoji&&e.emoji.native&&(this.comment=(this.comment||"")+e.emoji.native),this.showEmojiPicker=!1}ngOnDestroy(){this.subscriptionId&&this._subscriptionService.removeSubscriptionById(this.subscriptionId),this.subscription&&this.subscription.unsubscribe(),this._unsubscribeAll.next(),this._unsubscribeAll.complete()}static{this.\u0275fac=function(n){return new(n||i)(t.rXU(j.nX),t.rXU(j.Ix),t.rXU(k.n),t.rXU(B.n),t.rXU(t.gRc),t.rXU(N.m),t.rXU(V.up),t.rXU(w.U),t.rXU(z.m),t.rXU(L.D))}}static{this.\u0275cmp=t.VBU({type:i,selectors:[["app-post-event"]],decls:4,vars:2,consts:[["expandableReplay","angorCard"],[1,"mx-auto","w-full","max-w-5xl","px-6","sm:px-8"],[1,"flex","min-w-0","flex-auto","flex-col"],["class","flex justify-center items-center py-8",4,"ngIf"],[4,"ngIf"],[1,"flex","justify-center","items-center","py-8"],["mode","indeterminate",3,"diameter"],[1,"m-auto","flex","w-full","max-w-140","flex-col","items-start"],[1,"mb-1","mt-8","flex","w-full","flex-col",3,"item","more","actions"],[1,"mb-8","mt-1","flex","w-full","flex-col","pt-4"],[1,"mx-3","flex","items-center","sm:mx-5"],["mat-button","",1,"mr-1","px-3",3,"click"],[1,"text-red-500","icon-size-5",3,"ngClass","svgIcon"],[1,"ml-2"],[1,"text-blue-500","icon-size-5",3,"svgIcon"],[1,"text-green-500","icon-size-5",3,"svgIcon"],[1,"text-orange-500","icon-size-5",3,"svgIcon"],[1,"mx-6","mb-6","mt-4","border-b","sm:mx-8"],["class","mx-6 mb-4 flex flex-col sm:mx-8 sm:mb-6 sm:flex-row sm:items-center",4,"ngIf"],["class","flex mx-auto justify-center items-center mb-4",4,"ngIf"],["angorCardExpansion",""],[1,"m-0","border-b"],[1,"mx-4","mb-3","mt-6","flex","flex-col","sm:mx-8"],[1,"flex","items-start"],[1,"w-full",3,"subscriptSizing"],["matInput","","cdkTextareaAutosize","",3,"ngModelChange","placeholder","rows","ngModel"],[1,"mt-3","flex","items-center","justify-between"],[1,"flex","items-center"],["mat-icon-button","",3,"click"],[1,"icon-size-5",3,"svgIcon"],["class","emoji-picker-container-global",4,"ngIf"],["mat-icon-button",""],["mat-button","",3,"click"],[3,"svgIcon"],[1,"mx-6","mb-4","flex","flex-col","sm:mx-8","sm:mb-6","sm:flex-row","sm:items-center"],[1,"ml-3","text-md","tracking-tight"],[1,"hidden","flex-auto","sm:flex"],[1,"mt-4","flex","items-center","justify-end","sm:mt-0"],["mat-button","",1,"-ml-2","mr-1","px-3","sm:ml-0"],["mat-button","",1,"px-3","sm:-mr-4",3,"click"],[1,"mr-1"],[1,"rotate-0","transition-transform","duration-150","ease-in-out","icon-size-5",3,"ngClass","svgIcon"],[1,"flex","mx-auto","justify-center","items-center","mb-4"],[1,"emoji-picker-container-global"],[3,"emojiClick","darkMode"],[1,"mx-4","my-0","border-b","sm:mx-8"],[1,"max-h-120","overflow-y-auto"],[1,"relative","mx-4","my-6","flex","flex-col","sm:mx-8"],["class","mb-6 flex flex-col items-start",4,"ngFor","ngForOf"],[1,"mb-6","flex","flex-col","items-start"],[3,"pubkey","avatarUrl"],[1,"mt-0.5","flex","flex-col"],["class","inline-block whitespace-pre-wrap break-words",4,"ngFor","ngForOf"],[1,"text-secondary","mt-2","flex","items-center","text-sm"],[1,"inline-block","whitespace-pre-wrap","break-words"],[1,"relative","mb-4","block"],["width","560","height","315","frameborder","0","allowfullscreen","",3,"src"],["alt","Embedded Image",1,"max-h-140","object-cover",2,"width","100%",3,"src"],["controls","",2,"width","100%"],["type","video/mp4",3,"src"],["controls",""],["type","audio/mpeg",3,"src"],[1,"mx-6","mb-6","mt-2","sm:mx-1"],["target","_blank",1,"inline-block","break-words","text-blue-500","underline",3,"href"],[1,"inline-block","break-words"],[1,"mt-2","sm:mx-1"]],template:function(n,s){1&n&&(t.j41(0,"div",1)(1,"div",2),t.DNE(2,W,2,1,"div",3)(3,lt,45,23,"div",4),t.k0s()()),2&n&&(t.R7$(2),t.Y8G("ngIf",s.loading),t.R7$(),t.Y8G("ngIf",!s.loading&&s.post))},dependencies:[I.n,_.m_,_.An,u.Hl,u.$z,u.iY,$.Cn,g.RG,g.rl,x.fS,x.fg,h.xb,h.EE,C.w,Y.uc,d.MD,d.YU,d.Sq,d.bT,p.YN,p.me,p.BC,p.vS,b.D6,b.LG,S.e,G.MY,F.vg,P.g,X,D.q,U.Ic],styles:[".emoji-picker-container-global[_ngcontent-%COMP%]{position:fixed;top:50%;left:50%;transform:translate(-50%,-50%);z-index:9999;width:350px;max-width:100%}"]})}}return i})()}]}}]); \ No newline at end of file +"use strict";(self.webpackChunkangor=self.webpackChunkangor||[]).push([[544],{6544:(vt,f,o)=>{o.r(f),o.d(f,{default:()=>mt});var m=o(3014),d=o(4460),R=o(8447),y=o(5710),E=o(5424),I=o(7785),h=o(708),u=o(9471),C=o(7702),G=o(2835),g=o(6071),_=o(3904),$=o(7818),b=o(1054),p=o(936),S=o(9363),P=o(9561),x=o(6389),F=o(5785),Y=o(7712),t=o(3107),k=o(3149),T=o(7121);let X=(()=>{class i{constructor(e,n,s){this._changeDetectorRef=e,this._storageService=n,this._metadatasService=s}ngOnInit(){this.loadUserProfile(),this._metadatasService.addPublicKey(this.pubkey),this.subscription=this._storageService.profile$.subscribe(e=>{e&&e.pubKey===this.pubkey&&(this.user=e.metadata,console.log(this.user),this._changeDetectorRef.detectChanges())})}loadUserProfile(){var e=this;return(0,m.A)(function*(){const n=yield e._storageService.getProfile(e.pubkey);e.user=n||{},e._changeDetectorRef.detectChanges()})()}get displayName(){return this.user?.display_name||this.user?.name||this.shortenPubkey(this.pubkey)}get displayAvatar(){return this.user?.picture||this.avatarUrl||"/images/avatars/avatar-placeholder.png"}shortenPubkey(e){return e?`${e.slice(0,8)}...${e.slice(-8)}`:""}ngOnDestroy(){this.subscription&&this.subscription.unsubscribe()}static{this.\u0275fac=function(n){return new(n||i)(t.rXU(t.gRc),t.rXU(k.n),t.rXU(T.T))}}static{this.\u0275cmp=t.VBU({type:i,selectors:[["app-replay-profile"]],inputs:{pubkey:"pubkey",avatarUrl:"avatarUrl"},decls:5,vars:4,consts:[[1,"flex","items-center"],[1,"flex","items-center","group",3,"href"],[1,"mr-4","h-10","w-10","rounded-full","border","border-gray-300","group-hover:shadow-md","object-cover",3,"src","alt"],[1,"font-bold","text-gray-800","group-hover:text-blue-500"]],template:function(n,s){1&n&&(t.j41(0,"div",0)(1,"a",1),t.nrm(2,"img",2),t.j41(3,"span",3),t.EFF(4),t.k0s()()()),2&n&&(t.R7$(),t.Y8G("href","/profile/"+s.pubkey,t.B4B),t.R7$(),t.Y8G("src",s.displayAvatar,t.B4B)("alt",s.displayName),t.R7$(2),t.SpI(" ",s.displayName," "))},dependencies:[d.MD],encapsulation:2})}}return i})();var D=o(5727),U=o(1556),j=o(8716),B=o(5506),N=o(9207),V=o(6388),w=o(5616),z=o(7153),L=o(3303);const M=i=>({"heart-beat":i}),A=i=>({"rotate-180":i}),O=()=>[];function W(i,r){1&i&&(t.j41(0,"div",5),t.nrm(1,"mat-progress-spinner",6),t.k0s()),2&i&&(t.R7$(),t.Y8G("diameter",50))}function Z(i,r){1&i&&(t.j41(0,"span"),t.EFF(1,"s"),t.k0s())}function H(i,r){1&i&&(t.j41(0,"span"),t.EFF(1,"s"),t.k0s())}function J(i,r){1&i&&(t.j41(0,"span"),t.EFF(1,"s"),t.k0s())}function K(i,r){if(1&i){const e=t.RV6();t.j41(0,"div",34)(1,"div",27)(2,"div",35),t.EFF(3),t.DNE(4,Z,2,0,"span",4),t.k0s()(),t.nrm(5,"div",36),t.j41(6,"div",37)(7,"button",38),t.EFF(8),t.DNE(9,H,2,0,"span",4),t.k0s(),t.j41(10,"button",38),t.EFF(11),t.DNE(12,J,2,0,"span",4),t.k0s(),t.j41(13,"button",39),t.bIt("click",function(){t.eBV(e),t.XpG();const s=t.sdS(4);return t.Njj(s.expanded=!s.expanded)}),t.j41(14,"span",40),t.EFF(15),t.k0s(),t.nrm(16,"mat-icon",41),t.k0s()()()}if(2&i){t.XpG();const e=t.sdS(4),n=t.XpG();t.R7$(3),t.SpI(" ",n.zaps.length," Zap"),t.R7$(),t.Y8G("ngIf",n.zaps.length>1),t.R7$(4),t.SpI(" ",n.likes.length," Like"),t.R7$(),t.Y8G("ngIf",n.likes.length>1),t.R7$(2),t.SpI(" ",n.reposts.length," Share"),t.R7$(),t.Y8G("ngIf",n.reposts.length>1),t.R7$(3),t.SpI("",n.replies.length," Comments"),t.R7$(),t.Y8G("ngClass",t.eq3(9,A,e.expanded))("svgIcon","heroicons_mini:chevron-down")}}function Q(i,r){1&i&&(t.j41(0,"div",42),t.nrm(1,"mat-progress-spinner",6),t.k0s()),2&i&&(t.R7$(),t.Y8G("diameter",40))}function q(i,r){if(1&i){const e=t.RV6();t.j41(0,"div",43)(1,"emoji-mart",44),t.bIt("emojiClick",function(s){t.eBV(e);const a=t.XpG(2);return t.Njj(a.addEmoji(s))}),t.k0s()()}if(2&i){const e=t.XpG(2);t.R7$(),t.Y8G("darkMode",e.darkMode)}}function tt(i,r){if(1&i&&(t.qex(0),t.j41(1,"div",55),t.nrm(2,"iframe",56),t.k0s(),t.bVm()),2&i){const e=t.XpG().$implicit;t.R7$(2),t.Y8G("src",null==e?null:e.safeWord,t.f$h)}}function et(i,r){if(1&i&&(t.qex(0),t.j41(1,"div",55),t.nrm(2,"img",57),t.k0s(),t.bVm()),2&i){const e=t.XpG().$implicit;t.R7$(2),t.Y8G("src",null==e?null:e.safeWord,t.B4B)}}function nt(i,r){if(1&i&&(t.qex(0),t.j41(1,"div",55)(2,"video",58),t.nrm(3,"source",59),t.EFF(4," Your browser does not support the video tag. "),t.k0s()(),t.bVm()),2&i){const e=t.XpG().$implicit;t.R7$(3),t.Y8G("src",null==e?null:e.safeWord,t.B4B)}}function it(i,r){if(1&i&&(t.qex(0),t.j41(1,"div",55)(2,"audio",60),t.nrm(3,"source",61),t.EFF(4," Your browser does not support the audio element. "),t.k0s()(),t.bVm()),2&i){const e=t.XpG().$implicit;t.R7$(3),t.Y8G("src",null==e?null:e.safeWord,t.B4B)}}function st(i,r){if(1&i&&(t.qex(0),t.j41(1,"div",62)(2,"a",63)(3,"span",64),t.EFF(4),t.k0s()()(),t.bVm()),2&i){const e=t.XpG().$implicit;t.R7$(2),t.Y8G("href",null==e?null:e.word,t.B4B),t.R7$(2),t.SpI(" ",null==e?null:e.word," ")}}function ot(i,r){if(1&i&&(t.qex(0),t.j41(1,"div",65)(2,"span",64),t.EFF(3),t.k0s()(),t.bVm()),2&i){const e=t.XpG().$implicit;t.R7$(3),t.SpI(" ",null==e?null:e.trim()," ")}}function rt(i,r){if(1&i&&(t.j41(0,"div",54),t.DNE(1,tt,3,1,"ng-container",4)(2,et,3,1,"ng-container",4)(3,nt,5,1,"ng-container",4)(4,it,5,1,"ng-container",4)(5,st,5,2,"ng-container",4)(6,ot,4,1,"ng-container",4),t.k0s()),2&i){const e=r.$implicit;t.R7$(),t.Y8G("ngIf","youtube"===(null==e?null:e.token)),t.R7$(),t.Y8G("ngIf","image"===(null==e?null:e.token)),t.R7$(),t.Y8G("ngIf","video"===(null==e?null:e.token)),t.R7$(),t.Y8G("ngIf","audio"===(null==e?null:e.token)),t.R7$(),t.Y8G("ngIf","link"===(null==e?null:e.token)),t.R7$(),t.Y8G("ngIf",!(null!=e&&e.token))}}function at(i,r){if(1&i&&(t.j41(0,"div",49),t.nrm(1,"app-replay-profile",50),t.j41(2,"div",51)(3,"span"),t.DNE(4,rt,7,6,"div",52),t.k0s(),t.j41(5,"div",53)(6,"span"),t.EFF(7),t.nI1(8,"ago"),t.k0s()()()()),2&i){const e=r.$implicit,n=t.XpG(3);t.R7$(),t.Y8G("pubkey",null==e?null:e.pubkey)("avatarUrl","/images/avatars/avatar-placeholder.png"),t.R7$(3),t.Y8G("ngForOf",n._parseContent.parseContent(null==e?null:e.content)||t.lJ4(6,O)),t.R7$(3),t.JRh(t.bMT(8,4,null==e?null:e.created_at))}}function ct(i,r){if(1&i&&(t.j41(0,"div"),t.nrm(1,"hr",45),t.j41(2,"div",46)(3,"div",47),t.DNE(4,at,9,7,"div",48),t.k0s()()()),2&i){const e=t.XpG(2);t.R7$(4),t.Y8G("ngForOf",e.replies)}}function lt(i,r){if(1&i){const e=t.RV6();t.j41(0,"div")(1,"div",7),t.nrm(2,"app-post",8),t.j41(3,"angor-card",9,0)(5,"div",10)(6,"button",11),t.bIt("click",function(){t.eBV(e);const s=t.XpG();return t.Njj(s.toggleLike(s.post))}),t.nrm(7,"mat-icon",12),t.j41(8,"span",13),t.EFF(9),t.k0s()(),t.j41(10,"button",11),t.bIt("click",function(){t.eBV(e);const s=t.sdS(4);return t.Njj(s.expanded=!s.expanded)}),t.nrm(11,"mat-icon",14),t.j41(12,"span",13),t.EFF(13,"Comment"),t.k0s()(),t.j41(14,"button",11),t.bIt("click",function(){t.eBV(e);const s=t.XpG();return t.Njj(s.onShare(s.post))}),t.nrm(15,"mat-icon",15),t.j41(16,"span",13),t.EFF(17,"Share"),t.k0s()(),t.j41(18,"button",11),t.bIt("click",function(){t.eBV(e);const s=t.XpG();return t.Njj(s.openZapDialog())}),t.nrm(19,"mat-icon",16),t.j41(20,"span",13),t.EFF(21,"Zap"),t.k0s()()(),t.nrm(22,"hr",17),t.DNE(23,K,17,11,"div",18)(24,Q,2,1,"div",19),t.qex(25,20),t.nrm(26,"hr",21),t.j41(27,"div",22)(28,"div",23)(29,"mat-form-field",24)(30,"textarea",25),t.mxI("ngModelChange",function(s){t.eBV(e);const a=t.XpG();return t.DH7(a.comment,s)||(a.comment=s),t.Njj(s)}),t.k0s()()(),t.j41(31,"div",26)(32,"div",27)(33,"button",28),t.bIt("click",function(){t.eBV(e);const s=t.XpG();return t.Njj(s.toggleEmojiPicker())}),t.nrm(34,"mat-icon",29),t.k0s(),t.DNE(35,q,2,1,"div",30),t.j41(36,"button",31),t.nrm(37,"mat-icon",29),t.k0s(),t.j41(38,"button",31),t.nrm(39,"mat-icon",29),t.k0s()(),t.j41(40,"button",32),t.bIt("click",function(){t.eBV(e);const s=t.XpG();return t.Njj(s.sendComment(s.post))}),t.nrm(41,"mat-icon",33),t.j41(42,"span",13),t.EFF(43,"Send"),t.k0s()()()(),t.DNE(44,ct,5,1,"div",4),t.bVm(),t.k0s()()()}if(2&i){const e=t.XpG();t.R7$(2),t.Y8G("item",e.post)("more",!1)("actions",!1),t.R7$(5),t.Y8G("ngClass",t.eq3(21,M,e.isLiked))("svgIcon",e.isLiked?"heroicons_solid:heart":"heroicons_outline:heart"),t.R7$(2),t.SpI("",e.isLiked?"Liked":"Like"," "),t.R7$(2),t.Y8G("svgIcon","heroicons_solid:chat-bubble-left-ellipsis"),t.R7$(4),t.Y8G("svgIcon","heroicons_solid:share"),t.R7$(4),t.Y8G("svgIcon","heroicons_solid:bolt"),t.R7$(4),t.Y8G("ngIf",!e.loadingReactions),t.R7$(),t.Y8G("ngIf",e.loadingReactions),t.R7$(5),t.Y8G("subscriptSizing","dynamic"),t.R7$(),t.Y8G("placeholder","Write a comment...")("rows",3),t.R50("ngModel",e.comment),t.R7$(4),t.Y8G("svgIcon","heroicons_solid:face-smile"),t.R7$(),t.Y8G("ngIf",e.showEmojiPicker),t.R7$(2),t.Y8G("svgIcon","heroicons_solid:photo"),t.R7$(2),t.Y8G("svgIcon","heroicons_solid:sparkles"),t.R7$(2),t.Y8G("svgIcon","heroicons_solid:paper-airplane"),t.R7$(3),t.Y8G("ngIf",e.replies.length>0)}}const mt=[{path:"",component:(()=>{class i{constructor(e,n,s,a,l,c,v,dt,pt,ut){this._route=e,this._router=n,this._storageService=s,this._subscriptionService=a,this._changeDetectorRef=l,this._parseContent=c,this._sanitizer=v,this._eventService=dt,this._angorConfirmationService=pt,this._zapService=ut,this.postId=null,this.post=null,this.user=null,this.loading=!0,this.loadingReactions=!0,this._unsubscribeAll=new R.B,this.subscription=new y.yU,this.darkMode=!1,this.likes=[],this.reposts=[],this.zaps=[],this.replies=[],this.isLiked=!1}ngOnInit(){this._route.paramMap.pipe((0,E.Q)(this._unsubscribeAll)).subscribe(e=>{this.postId=e.get("id"),this.postId&&(this.loadPost(this.postId),this.subscribeToReactions(this.postId))}),this.subscription=this._storageService.myLikes$.subscribe(e=>{e&&e.includes(this.postId)?(this.isLiked=!0,this._changeDetectorRef.detectChanges()):this.isLiked=!1})}loadUserProfile(){var e=this;return(0,m.A)(function*(){e._storageService.getProfile(e.post.pubkey).then(n=>{e.user=n,e._changeDetectorRef.detectChanges()})})()}loadPost(e){var n=this;return(0,m.A)(function*(){try{if(n.loading=!0,n.post=yield n._storageService.getPostById(e),n.post)n.loading=!1,yield n.loadUserProfile();else{const a=n._subscriptionService.addSubscriptions([{ids:[e],kinds:[1],limit:1}],function(){var l=(0,m.A)(function*(c){n.post=c,console.log(n.post),n._changeDetectorRef.detectChanges(),yield n._storageService.savePost(c),n._changeDetectorRef.detectChanges(),a&&n._subscriptionService.removeSubscriptionById(a),n.loading=!1});return function(c){return l.apply(this,arguments)}}())}}catch(s){console.error("Error loading post:",s),n._router.navigate(["/404"])}})()}getSafeUrl(e){return this._sanitizer.bypassSecurityTrustUrl(e)}subscribeToReactions(e){var n=this;let s;this.loadingReactions=!0,s=setTimeout(()=>{this.loadingReactions=!1},3e3),this.subscriptionId=this._subscriptionService.addSubscriptions([{"#e":[e],kinds:[1,7,9735,6]}],function(){var l=(0,m.A)(function*(c){n.loadingReactions&&(n.loadingReactions=!1,clearTimeout(s)),n.addReaction(e,c.kind,{pubkey:c.pubkey,created_at:c.created_at,content:1===c.kind?c.content:void 0})});return function(c){return l.apply(this,arguments)}}())}addReaction(e,n,s){switch(n){case 1:this.replies.push(s),this.replies.sort((a,l)=>l.created_at-a.created_at);break;case 7:this.likes.push(s);break;case 9735:this.zaps.push(s);break;case 6:this.reposts.push(s)}this._changeDetectorRef.detectChanges()}isSingleEmojiOrWord(e){const n=e.trim(),s=/^\w+$/.test(n),a=/^[\p{Emoji}]+$/u.test(n);return s||a}sendLike(e){this.isLiked||this._eventService.sendLikeEvent(e).then(()=>{this.isLiked=!0,this._changeDetectorRef.detectChanges()}).catch(n=>console.error("Failed to send like:",n))}toggleLike(e){this.sendLike(e)}onShare(e){this._angorConfirmationService.open({title:"Share",message:'Are you sure you want to share this post on your profile? This action is permanent and cannot be undone.',icon:{show:!0,name:"heroicons_solid:share",color:"primary"},actions:{confirm:{show:!0,label:"Yes, Share",color:"primary"},cancel:{show:!0,label:"Cancel"}},dismissible:!0}).afterClosed().subscribe(s=>{console.log(s),"confirmed"===s&&this._eventService.shareEvent(e).then(()=>{this._changeDetectorRef.detectChanges()}).catch(a=>console.error("Failed to share post",a))})}openZapDialog(){this._zapService.openZapDialog(this.postId,this.user)}sendComment(e){""!==this.comment.trim()&&this._eventService.sendReplyEvent(e,this.comment).then(()=>{this.comment="",this._changeDetectorRef.markForCheck()})}toggleEmojiPicker(){this.showEmojiPicker=!this.showEmojiPicker}addEmoji(e){e&&e.emoji&&e.emoji.native&&(this.comment=(this.comment||"")+e.emoji.native),this.showEmojiPicker=!1}ngOnDestroy(){this.subscriptionId&&this._subscriptionService.removeSubscriptionById(this.subscriptionId),this.subscription&&this.subscription.unsubscribe(),this._unsubscribeAll.next(),this._unsubscribeAll.complete()}static{this.\u0275fac=function(n){return new(n||i)(t.rXU(j.nX),t.rXU(j.Ix),t.rXU(k.n),t.rXU(B.n),t.rXU(t.gRc),t.rXU(N.m),t.rXU(V.up),t.rXU(w.U),t.rXU(z.m),t.rXU(L.D))}}static{this.\u0275cmp=t.VBU({type:i,selectors:[["app-post-event"]],decls:4,vars:2,consts:[["expandableReplay","angorCard"],[1,"mx-auto","w-full","max-w-5xl","px-6","sm:px-8"],[1,"flex","min-w-0","flex-auto","flex-col"],["class","flex justify-center items-center py-8",4,"ngIf"],[4,"ngIf"],[1,"flex","justify-center","items-center","py-8"],["mode","indeterminate",3,"diameter"],[1,"m-auto","flex","w-full","max-w-140","flex-col","items-start"],[1,"mb-1","mt-8","flex","w-full","flex-col",3,"item","more","actions"],[1,"mb-8","mt-1","flex","w-full","flex-col","pt-4"],[1,"mx-3","flex","items-center","sm:mx-5"],["mat-button","",1,"mr-1","px-3",3,"click"],[1,"text-red-500","icon-size-5",3,"ngClass","svgIcon"],[1,"ml-2"],[1,"text-blue-500","icon-size-5",3,"svgIcon"],[1,"text-green-500","icon-size-5",3,"svgIcon"],[1,"text-orange-500","icon-size-5",3,"svgIcon"],[1,"mx-6","mb-6","mt-4","border-b","sm:mx-8"],["class","mx-6 mb-4 flex flex-col sm:mx-8 sm:mb-6 sm:flex-row sm:items-center",4,"ngIf"],["class","flex mx-auto justify-center items-center mb-4",4,"ngIf"],["angorCardExpansion",""],[1,"m-0","border-b"],[1,"mx-4","mb-3","mt-6","flex","flex-col","sm:mx-8"],[1,"flex","items-start"],[1,"w-full",3,"subscriptSizing"],["matInput","","cdkTextareaAutosize","",3,"ngModelChange","placeholder","rows","ngModel"],[1,"mt-3","flex","items-center","justify-between"],[1,"flex","items-center"],["mat-icon-button","",3,"click"],[1,"icon-size-5",3,"svgIcon"],["class","emoji-picker-container-global",4,"ngIf"],["mat-icon-button",""],["mat-button","",3,"click"],[3,"svgIcon"],[1,"mx-6","mb-4","flex","flex-col","sm:mx-8","sm:mb-6","sm:flex-row","sm:items-center"],[1,"ml-3","text-md","tracking-tight"],[1,"hidden","flex-auto","sm:flex"],[1,"mt-4","flex","items-center","justify-end","sm:mt-0"],["mat-button","",1,"-ml-2","mr-1","px-3","sm:ml-0"],["mat-button","",1,"px-3","sm:-mr-4",3,"click"],[1,"mr-1"],[1,"rotate-0","transition-transform","duration-150","ease-in-out","icon-size-5",3,"ngClass","svgIcon"],[1,"flex","mx-auto","justify-center","items-center","mb-4"],[1,"emoji-picker-container-global"],[3,"emojiClick","darkMode"],[1,"mx-4","my-0","border-b","sm:mx-8"],[1,"max-h-120","overflow-y-auto"],[1,"relative","mx-4","my-6","flex","flex-col","sm:mx-8"],["class","mb-6 flex flex-col items-start",4,"ngFor","ngForOf"],[1,"mb-6","flex","flex-col","items-start"],[3,"pubkey","avatarUrl"],[1,"mt-0.5","flex","flex-col"],["class","inline-block whitespace-pre-wrap break-words",4,"ngFor","ngForOf"],[1,"text-secondary","mt-2","flex","items-center","text-sm"],[1,"inline-block","whitespace-pre-wrap","break-words"],[1,"relative","mb-4","block"],["width","560","height","315","frameborder","0","allowfullscreen","",3,"src"],["alt","Embedded Image",1,"max-h-140","object-cover",2,"width","100%",3,"src"],["controls","",2,"width","100%"],["type","video/mp4",3,"src"],["controls",""],["type","audio/mpeg",3,"src"],[1,"mx-6","mb-6","mt-2","sm:mx-1"],["target","_blank",1,"inline-block","break-words","text-blue-500","underline",3,"href"],[1,"inline-block","break-words"],[1,"mt-2","sm:mx-1"]],template:function(n,s){1&n&&(t.j41(0,"div",1)(1,"div",2),t.DNE(2,W,2,1,"div",3)(3,lt,45,23,"div",4),t.k0s()()),2&n&&(t.R7$(2),t.Y8G("ngIf",s.loading),t.R7$(),t.Y8G("ngIf",!s.loading&&s.post))},dependencies:[I.n,_.m_,_.An,u.Hl,u.$z,u.iY,$.Cn,g.RG,g.rl,x.fS,x.fg,h.xb,h.EE,C.w,Y.uc,d.MD,d.YU,d.Sq,d.bT,p.YN,p.me,p.BC,p.vS,b.D6,b.LG,S.e,G.MY,F.vg,P.g,X,D.q,U.Ic],styles:[".emoji-picker-container-global[_ngcontent-%COMP%]{position:fixed;top:50%;left:50%;transform:translate(-50%,-50%);z-index:9999;width:350px;max-width:100%}"]})}}return i})()}]}}]); \ No newline at end of file diff --git a/index.html b/index.html index 977b185..5d113ad 100644 --- a/index.html +++ b/index.html @@ -41,5 +41,5 @@ - + diff --git a/main.9a08e516e999a8fa.js b/main.9a08e516e999a8fa.js new file mode 100644 index 0000000..7868531 --- /dev/null +++ b/main.9a08e516e999a8fa.js @@ -0,0 +1 @@ +(self.webpackChunkangor=self.webpackChunkangor||[]).push([[792],{6146:(o,s,r)=>{"use strict";r.d(s,{F:()=>i.F});var i=r(799)},799:(o,s,r)=>{"use strict";r.d(s,{F:()=>at});let i=(()=>{class dt{static{this.standard="cubic-bezier(0.4, 0.0, 0.2, 1)"}static{this.deceleration="cubic-bezier(0.0, 0.0, 0.2, 1)"}static{this.acceleration="cubic-bezier(0.4, 0.0, 1, 1)"}static{this.sharp="cubic-bezier(0.4, 0.0, 0.6, 1)"}}return dt})(),a=(()=>{class dt{static{this.complex="375ms"}static{this.entering="225ms"}static{this.exiting="195ms"}}return dt})();var c=r(1204);const ue=(dt,bt,lt,rn,gn=`${a.entering} ${i.deceleration}`,bn=`${a.exiting} ${i.acceleration}`)=>(0,c.hZ)(dt,[(0,c.wk)("void",(0,c.iF)(bt)),(0,c.wk)("*",(0,c.iF)(lt)),(0,c.kY)("void => false, * => false",[]),(0,c.kY)("void => *",(0,c.i0)(rn||gn),{params:{timings:gn}}),(0,c.kY)("* => void",(0,c.i0)(rn||bn),{params:{timings:bn}})]),at=[(0,c.hZ)("expandCollapse",[(0,c.wk)("void, collapsed",(0,c.iF)({height:"0"})),(0,c.wk)("*, expanded",(0,c.iF)("*")),(0,c.kY)("void <=> false, collapsed <=> false, expanded <=> false",[]),(0,c.kY)("void <=> *, collapsed <=> expanded",(0,c.i0)("{{timings}}"),{params:{timings:`${a.entering} ${i.deceleration}`}})]),(0,c.hZ)("fadeIn",[(0,c.wk)("void",(0,c.iF)({opacity:0})),(0,c.wk)("*",(0,c.iF)({opacity:1})),(0,c.kY)("void => false",[]),(0,c.kY)("void => *",(0,c.i0)("{{timings}}"),{params:{timings:`${a.entering} ${i.deceleration}`}})]),(0,c.hZ)("fadeInTop",[(0,c.wk)("void",(0,c.iF)({opacity:0,transform:"translate3d(0, -100%, 0)"})),(0,c.wk)("*",(0,c.iF)({opacity:1,transform:"translate3d(0, 0, 0)"})),(0,c.kY)("void => false",[]),(0,c.kY)("void => *",(0,c.i0)("{{timings}}"),{params:{timings:`${a.entering} ${i.deceleration}`}})]),(0,c.hZ)("fadeInBottom",[(0,c.wk)("void",(0,c.iF)({opacity:0,transform:"translate3d(0, 100%, 0)"})),(0,c.wk)("*",(0,c.iF)({opacity:1,transform:"translate3d(0, 0, 0)"})),(0,c.kY)("void => false",[]),(0,c.kY)("void => *",(0,c.i0)("{{timings}}"),{params:{timings:`${a.entering} ${i.deceleration}`}})]),(0,c.hZ)("fadeInLeft",[(0,c.wk)("void",(0,c.iF)({opacity:0,transform:"translate3d(-100%, 0, 0)"})),(0,c.wk)("*",(0,c.iF)({opacity:1,transform:"translate3d(0, 0, 0)"})),(0,c.kY)("void => false",[]),(0,c.kY)("void => *",(0,c.i0)("{{timings}}"),{params:{timings:`${a.entering} ${i.deceleration}`}})]),(0,c.hZ)("fadeInRight",[(0,c.wk)("void",(0,c.iF)({opacity:0,transform:"translate3d(100%, 0, 0)"})),(0,c.wk)("*",(0,c.iF)({opacity:1,transform:"translate3d(0, 0, 0)"})),(0,c.kY)("void => false",[]),(0,c.kY)("void => *",(0,c.i0)("{{timings}}"),{params:{timings:`${a.entering} ${i.deceleration}`}})]),(0,c.hZ)("fadeOut",[(0,c.wk)("*",(0,c.iF)({opacity:1})),(0,c.wk)("void",(0,c.iF)({opacity:0})),(0,c.kY)("false => void",[]),(0,c.kY)("* => void",(0,c.i0)("{{timings}}"),{params:{timings:`${a.exiting} ${i.acceleration}`}})]),(0,c.hZ)("fadeOutTop",[(0,c.wk)("*",(0,c.iF)({opacity:1,transform:"translate3d(0, 0, 0)"})),(0,c.wk)("void",(0,c.iF)({opacity:0,transform:"translate3d(0, -100%, 0)"})),(0,c.kY)("false => void",[]),(0,c.kY)("* => void",(0,c.i0)("{{timings}}"),{params:{timings:`${a.exiting} ${i.acceleration}`}})]),(0,c.hZ)("fadeOutBottom",[(0,c.wk)("*",(0,c.iF)({opacity:1,transform:"translate3d(0, 0, 0)"})),(0,c.wk)("void",(0,c.iF)({opacity:0,transform:"translate3d(0, 100%, 0)"})),(0,c.kY)("false => void",[]),(0,c.kY)("* => void",(0,c.i0)("{{timings}}"),{params:{timings:`${a.exiting} ${i.acceleration}`}})]),(0,c.hZ)("fadeOutLeft",[(0,c.wk)("*",(0,c.iF)({opacity:1,transform:"translate3d(0, 0, 0)"})),(0,c.wk)("void",(0,c.iF)({opacity:0,transform:"translate3d(-100%, 0, 0)"})),(0,c.kY)("false => void",[]),(0,c.kY)("* => void",(0,c.i0)("{{timings}}"),{params:{timings:`${a.exiting} ${i.acceleration}`}})]),(0,c.hZ)("fadeOutRight",[(0,c.wk)("*",(0,c.iF)({opacity:1,transform:"translate3d(0, 0, 0)"})),(0,c.wk)("void",(0,c.iF)({opacity:0,transform:"translate3d(100%, 0, 0)"})),(0,c.kY)("false => void",[]),(0,c.kY)("* => void",(0,c.i0)("{{timings}}"),{params:{timings:`${a.exiting} ${i.acceleration}`}})]),(0,c.hZ)("shake",[(0,c.kY)("void => false",[]),(0,c.kY)("void => *, * => true",[(0,c.i0)("{{timings}}",(0,c.i7)([(0,c.iF)({transform:"translate3d(0, 0, 0)",offset:0}),(0,c.iF)({transform:"translate3d(-10px, 0, 0)",offset:.1}),(0,c.iF)({transform:"translate3d(10px, 0, 0)",offset:.2}),(0,c.iF)({transform:"translate3d(-10px, 0, 0)",offset:.3}),(0,c.iF)({transform:"translate3d(10px, 0, 0)",offset:.4}),(0,c.iF)({transform:"translate3d(-10px, 0, 0)",offset:.5}),(0,c.iF)({transform:"translate3d(10px, 0, 0)",offset:.6}),(0,c.iF)({transform:"translate3d(-10px, 0, 0)",offset:.7}),(0,c.iF)({transform:"translate3d(10px, 0, 0)",offset:.8}),(0,c.iF)({transform:"translate3d(-10px, 0, 0)",offset:.9}),(0,c.iF)({transform:"translate3d(0, 0, 0)",offset:1})]))],{params:{timings:"0.8s cubic-bezier(0.455, 0.03, 0.515, 0.955)"}})]),(0,c.hZ)("slideInTop",[(0,c.wk)("void",(0,c.iF)({transform:"translate3d(0, -100%, 0)"})),(0,c.wk)("*",(0,c.iF)({transform:"translate3d(0, 0, 0)"})),(0,c.kY)("void => false",[]),(0,c.kY)("void => *",(0,c.i0)("{{timings}}"),{params:{timings:`${a.entering} ${i.deceleration}`}})]),(0,c.hZ)("slideInBottom",[(0,c.wk)("void",(0,c.iF)({transform:"translate3d(0, 100%, 0)"})),(0,c.wk)("*",(0,c.iF)({transform:"translate3d(0, 0, 0)"})),(0,c.kY)("void => false",[]),(0,c.kY)("void => *",(0,c.i0)("{{timings}}"),{params:{timings:`${a.entering} ${i.deceleration}`}})]),(0,c.hZ)("slideInLeft",[(0,c.wk)("void",(0,c.iF)({transform:"translate3d(-100%, 0, 0)"})),(0,c.wk)("*",(0,c.iF)({transform:"translate3d(0, 0, 0)"})),(0,c.kY)("void => false",[]),(0,c.kY)("void => *",(0,c.i0)("{{timings}}"),{params:{timings:`${a.entering} ${i.deceleration}`}})]),(0,c.hZ)("slideInRight",[(0,c.wk)("void",(0,c.iF)({transform:"translate3d(100%, 0, 0)"})),(0,c.wk)("*",(0,c.iF)({transform:"translate3d(0, 0, 0)"})),(0,c.kY)("void => false",[]),(0,c.kY)("void => *",(0,c.i0)("{{timings}}"),{params:{timings:`${a.entering} ${i.deceleration}`}})]),(0,c.hZ)("slideOutTop",[(0,c.wk)("*",(0,c.iF)({transform:"translate3d(0, 0, 0)"})),(0,c.wk)("void",(0,c.iF)({transform:"translate3d(0, -100%, 0)"})),(0,c.kY)("false => void",[]),(0,c.kY)("* => void",(0,c.i0)("{{timings}}"),{params:{timings:`${a.exiting} ${i.acceleration}`}})]),(0,c.hZ)("slideOutBottom",[(0,c.wk)("*",(0,c.iF)({transform:"translate3d(0, 0, 0)"})),(0,c.wk)("void",(0,c.iF)({transform:"translate3d(0, 100%, 0)"})),(0,c.kY)("false => void",[]),(0,c.kY)("* => void",(0,c.i0)("{{timings}}"),{params:{timings:`${a.exiting} ${i.acceleration}`}})]),(0,c.hZ)("slideOutLeft",[(0,c.wk)("*",(0,c.iF)({transform:"translate3d(0, 0, 0)"})),(0,c.wk)("void",(0,c.iF)({transform:"translate3d(-100%, 0, 0)"})),(0,c.kY)("false => void",[]),(0,c.kY)("* => void",(0,c.i0)("{{timings}}"),{params:{timings:`${a.exiting} ${i.acceleration}`}})]),(0,c.hZ)("slideOutRight",[(0,c.wk)("*",(0,c.iF)({transform:"translate3d(0, 0, 0)"})),(0,c.wk)("void",(0,c.iF)({transform:"translate3d(100%, 0, 0)"})),(0,c.kY)("false => void",[]),(0,c.kY)("* => void",(0,c.i0)("{{timings}}"),{params:{timings:`${a.exiting} ${i.acceleration}`}})]),ue("zoomIn",{opacity:0,transform:"scale(0.5)"},{opacity:1,transform:"scale(1)"},""),ue("zoomOut",{opacity:1,transform:"scale(1)"},{opacity:0,transform:"scale(0.5)"},"")]},3871:(o,s,r)=>{"use strict";r.d(s,{$w:()=>Rn,lX:()=>c,Tv:()=>Aa});var i=r(6146),a=r(3107);let c=(()=>{class Q{constructor(){this._componentRegistry=new Map,this._navigationStore=new Map}registerComponent(te,ot){this._componentRegistry.set(te,ot)}deregisterComponent(te){this._componentRegistry.delete(te)}getComponent(te){return this._componentRegistry.get(te)}storeNavigation(te,ot){this._navigationStore.set(te,ot)}getNavigation(te){return this._navigationStore.get(te)??[]}deleteNavigation(te){this._navigationStore.has(te)||console.warn(`Navigation with the key '${te}' does not exist.`),this._navigationStore.delete(te)}getFlatNavigation(te,ot=[]){for(const Ct of te)"basic"===Ct.type?ot.push(Ct):Ct.children&&this.getFlatNavigation(Ct.children,ot);return ot}getItem(te,ot){for(const Ct of ot){if(Ct.id===te)return Ct;if(Ct.children){const Bn=this.getItem(te,Ct.children);if(Bn)return Bn}}return null}getItemParent(te,ot,Ct){for(const Bn of ot){if(Bn.id===te)return Ct;if(Bn.children){const On=this.getItemParent(te,Bn.children,Bn);if(On)return On}}return null}static{this.\u0275fac=function(ot){return new(ot||Q)}}static{this.\u0275prov=a.jDH({token:Q,factory:Q.\u0275fac,providedIn:"root"})}}return Q})();var y=r(3939),w=r(7838),C=r(8447),T=r(4460),S=r(3904),M=r(7818),O=r(7712),L=r(8716),Z=r(5424);const q=Q=>({"angor-horizontal-navigation-item-active-forced":Q}),re=Q=>[Q];function pe(Q,et){1&Q&&a.eu8(0)}function se(Q,et){if(1&Q&&(a.j41(0,"div",2),a.DNE(1,pe,1,0,"ng-container",7),a.k0s()),2&Q){let te,ot,Ct,Bn;const On=a.XpG(),Wn=a.sdS(9);a.Y8G("ngClass",a.eq3(10,q,On.item.active))("routerLink",a.eq3(12,re,On.item.link))("fragment",null!==(te=On.item.fragment)&&void 0!==te?te:null)("preserveFragment",null!==(ot=On.item.preserveFragment)&&void 0!==ot&&ot)("queryParams",null!==(Ct=On.item.queryParams)&&void 0!==Ct?Ct:null)("queryParamsHandling",null!==(Bn=On.item.queryParamsHandling)&&void 0!==Bn?Bn:null)("routerLinkActive","angor-horizontal-navigation-item-active")("routerLinkActiveOptions",On.isActiveMatchOptions)("matTooltip",On.item.tooltip||""),a.R7$(),a.Y8G("ngTemplateOutlet",Wn)}}function ae(Q,et){1&Q&&a.eu8(0)}function me(Q,et){if(1&Q&&(a.j41(0,"a",3),a.DNE(1,ae,1,0,"ng-container",7),a.k0s()),2&Q){const te=a.XpG(),ot=a.sdS(9);a.Y8G("href",te.item.link,a.B4B)("target",te.item.target||"_self")("matTooltip",te.item.tooltip||""),a.R7$(),a.Y8G("ngTemplateOutlet",ot)}}function be(Q,et){1&Q&&a.eu8(0)}function Oe(Q,et){if(1&Q){const te=a.RV6();a.j41(0,"div",8),a.bIt("click",function(){a.eBV(te);const Ct=a.XpG();return a.Njj(Ct.item.function(Ct.item))}),a.DNE(1,be,1,0,"ng-container",7),a.k0s()}if(2&Q){const te=a.XpG(),ot=a.sdS(9);a.Y8G("ngClass",a.eq3(3,q,te.item.active))("matTooltip",te.item.tooltip||""),a.R7$(),a.Y8G("ngTemplateOutlet",ot)}}function xe(Q,et){1&Q&&a.eu8(0)}function De(Q,et){if(1&Q){const te=a.RV6();a.j41(0,"div",9),a.bIt("click",function(){a.eBV(te);const Ct=a.XpG();return a.Njj(Ct.item.function(Ct.item))}),a.DNE(1,xe,1,0,"ng-container",7),a.k0s()}if(2&Q){let te,ot,Ct,Bn;const On=a.XpG(),Wn=a.sdS(9);a.Y8G("ngClass",a.eq3(10,q,On.item.active))("routerLink",a.eq3(12,re,On.item.link))("fragment",null!==(te=On.item.fragment)&&void 0!==te?te:null)("preserveFragment",null!==(ot=On.item.preserveFragment)&&void 0!==ot&&ot)("queryParams",null!==(Ct=On.item.queryParams)&&void 0!==Ct?Ct:null)("queryParamsHandling",null!==(Bn=On.item.queryParamsHandling)&&void 0!==Bn?Bn:null)("routerLinkActive","angor-horizontal-navigation-item-active")("routerLinkActiveOptions",On.isActiveMatchOptions)("matTooltip",On.item.tooltip||""),a.R7$(),a.Y8G("ngTemplateOutlet",Wn)}}function ce(Q,et){1&Q&&a.eu8(0)}function ue(Q,et){if(1&Q){const te=a.RV6();a.j41(0,"a",10),a.bIt("click",function(){a.eBV(te);const Ct=a.XpG();return a.Njj(Ct.item.function(Ct.item))}),a.DNE(1,ce,1,0,"ng-container",7),a.k0s()}if(2&Q){const te=a.XpG(),ot=a.sdS(9);a.Y8G("href",te.item.link,a.B4B)("target",te.item.target||"_self")("matTooltip",te.item.tooltip||""),a.R7$(),a.Y8G("ngTemplateOutlet",ot)}}function Ce(Q,et){1&Q&&a.eu8(0)}function Be(Q,et){if(1&Q&&(a.j41(0,"div",4),a.DNE(1,Ce,1,0,"ng-container",7),a.k0s()),2&Q){const te=a.XpG(),ot=a.sdS(9);a.Y8G("ngClass",a.eq3(3,q,te.item.active))("matTooltip",te.item.tooltip||""),a.R7$(),a.Y8G("ngTemplateOutlet",ot)}}function at(Q,et){1&Q&&a.eu8(0)}function dt(Q,et){if(1&Q&&(a.j41(0,"div",6),a.DNE(1,at,1,0,"ng-container",7),a.k0s()),2&Q){a.XpG();const te=a.sdS(9);a.R7$(),a.Y8G("ngTemplateOutlet",te)}}function bt(Q,et){if(1&Q&&a.nrm(0,"mat-icon",11),2&Q){const te=a.XpG(2);a.Y8G("ngClass",null==te.item.classes?null:te.item.classes.icon)("svgIcon",te.item.icon)}}function lt(Q,et){if(1&Q&&(a.j41(0,"div",15)(1,"span",14),a.EFF(2),a.k0s()()),2&Q){const te=a.XpG(2);a.R7$(),a.Y8G("ngClass",null==te.item.classes?null:te.item.classes.subtitle),a.R7$(),a.SpI(" ",te.item.subtitle," ")}}function rn(Q,et){if(1&Q&&(a.j41(0,"div",16)(1,"div",17),a.EFF(2),a.k0s()()),2&Q){const te=a.XpG(2);a.R7$(),a.Y8G("ngClass",te.item.badge.classes),a.R7$(),a.SpI(" ",te.item.badge.title," ")}}function gn(Q,et){if(1&Q&&(a.DNE(0,bt,1,2,"mat-icon",11),a.j41(1,"div",12)(2,"div",13)(3,"span",14),a.EFF(4),a.k0s()(),a.DNE(5,lt,3,2,"div",15),a.k0s(),a.DNE(6,rn,3,2,"div",16)),2&Q){const te=a.XpG();a.vxM(te.item.icon?0:-1),a.R7$(3),a.Y8G("ngClass",null==te.item.classes?null:te.item.classes.title),a.R7$(),a.SpI(" ",te.item.title," "),a.R7$(),a.vxM(te.item.subtitle?5:-1),a.R7$(),a.vxM(te.item.badge?6:-1)}}let bn=(()=>{class Q{constructor(){this._changeDetectorRef=(0,a.WQX)(a.gRc),this._angorNavigationService=(0,a.WQX)(c),this._angorUtilsService=(0,a.WQX)(y.Q),this.isActiveMatchOptions=this._angorUtilsService.subsetMatchOptions,this._unsubscribeAll=new C.B}ngOnInit(){this.isActiveMatchOptions=this.item.isActiveMatchOptions??this.item.exactMatch?this._angorUtilsService.exactMatchOptions:this._angorUtilsService.subsetMatchOptions,this._angorHorizontalNavigationComponent=this._angorNavigationService.getComponent(this.name),this._changeDetectorRef.markForCheck(),this._angorHorizontalNavigationComponent.onRefreshed.pipe((0,Z.Q)(this._unsubscribeAll)).subscribe(()=>{this._changeDetectorRef.markForCheck()})}ngOnDestroy(){this._unsubscribeAll.next(null),this._unsubscribeAll.complete()}static{this.\u0275fac=function(ot){return new(ot||Q)}}static{this.\u0275cmp=a.VBU({type:Q,selectors:[["angor-horizontal-navigation-basic-item"]],inputs:{item:"item",name:"name"},decls:10,vars:10,consts:[["itemTemplate",""],[1,"angor-horizontal-navigation-item-wrapper",3,"ngClass"],[1,"angor-horizontal-navigation-item",3,"ngClass","routerLink","fragment","preserveFragment","queryParams","queryParamsHandling","routerLinkActive","routerLinkActiveOptions","matTooltip"],[1,"angor-horizontal-navigation-item",3,"href","target","matTooltip"],[1,"angor-horizontal-navigation-item",3,"ngClass","matTooltip"],["mat-menu-item","",1,"angor-horizontal-navigation-item",3,"href","target","matTooltip"],[1,"angor-horizontal-navigation-item","angor-horizontal-navigation-item-disabled"],[4,"ngTemplateOutlet"],[1,"angor-horizontal-navigation-item",3,"click","ngClass","matTooltip"],[1,"angor-horizontal-navigation-item",3,"click","ngClass","routerLink","fragment","preserveFragment","queryParams","queryParamsHandling","routerLinkActive","routerLinkActiveOptions","matTooltip"],["mat-menu-item","",1,"angor-horizontal-navigation-item",3,"click","href","target","matTooltip"],[1,"angor-horizontal-navigation-item-icon",3,"ngClass","svgIcon"],[1,"angor-horizontal-navigation-item-title-wrapper"],[1,"angor-horizontal-navigation-item-title"],[3,"ngClass"],[1,"angor-horizontal-navigation-item-subtitle","text-hint"],[1,"angor-horizontal-navigation-item-badge"],[1,"angor-horizontal-navigation-item-badge-content",3,"ngClass"]],template:function(ot,Ct){1&ot&&(a.j41(0,"div",1),a.DNE(1,se,2,14,"div",2)(2,me,2,4,"a",3)(3,Oe,2,5,"div",4)(4,De,2,14,"div",2)(5,ue,2,4,"a",5)(6,Be,2,5,"div",4)(7,dt,2,1,"div",6),a.k0s(),a.DNE(8,gn,7,5,"ng-template",null,0,a.C5r)),2&ot&&(a.AVh("angor-horizontal-navigation-item-has-subtitle",!!Ct.item.subtitle),a.Y8G("ngClass",null==Ct.item.classes?null:Ct.item.classes.wrapper),a.R7$(),a.vxM(!Ct.item.link||Ct.item.externalLink||Ct.item.function||Ct.item.disabled?-1:1),a.R7$(),a.vxM(Ct.item.link&&Ct.item.externalLink&&!Ct.item.function&&!Ct.item.disabled?2:-1),a.R7$(),a.vxM(Ct.item.link||!Ct.item.function||Ct.item.disabled?-1:3),a.R7$(),a.vxM(Ct.item.link&&!Ct.item.externalLink&&Ct.item.function&&!Ct.item.disabled?4:-1),a.R7$(),a.vxM(Ct.item.link&&Ct.item.externalLink&&Ct.item.function&&!Ct.item.disabled?5:-1),a.R7$(),a.vxM(Ct.item.link||Ct.item.function||Ct.item.disabled?-1:6),a.R7$(),a.vxM(Ct.item.disabled?7:-1))},dependencies:[T.YU,L.Wk,L.wQ,O.uc,O.oV,T.T3,M.Cn,M.fb,S.m_,S.An],encapsulation:2,changeDetection:0})}}return Q})(),Vn=(()=>{class Q{constructor(){this._changeDetectorRef=(0,a.WQX)(a.gRc),this._angorNavigationService=(0,a.WQX)(c),this._unsubscribeAll=new C.B}ngOnInit(){this._angorHorizontalNavigationComponent=this._angorNavigationService.getComponent(this.name),this._angorHorizontalNavigationComponent.onRefreshed.pipe((0,Z.Q)(this._unsubscribeAll)).subscribe(()=>{this._changeDetectorRef.markForCheck()})}ngOnDestroy(){this._unsubscribeAll.next(null),this._unsubscribeAll.complete()}static{this.\u0275fac=function(ot){return new(ot||Q)}}static{this.\u0275cmp=a.VBU({type:Q,selectors:[["angor-horizontal-navigation-divider-item"]],inputs:{item:"item",name:"name"},decls:1,vars:1,consts:[[1,"angor-horizontal-navigation-item-wrapper","divider",3,"ngClass"]],template:function(ot,Ct){1&ot&&a.nrm(0,"div",0),2&ot&&a.Y8G("ngClass",null==Ct.item.classes?null:Ct.item.classes.wrapper)},dependencies:[T.YU],encapsulation:2,changeDetection:0})}}return Q})();const yn=["matMenu"],qe=(Q,et)=>({"angor-horizontal-navigation-menu-active":Q,"angor-horizontal-navigation-menu-active-forced":et}),_t=Q=>({$implicit:Q}),ze=(Q,et)=>({"angor-horizontal-navigation-item-disabled":Q,"angor-horizontal-navigation-item-active-forced":et});function $e(Q,et){1&Q&&a.eu8(0)}function Ft(Q,et){if(1&Q){const te=a.RV6();a.j41(0,"div",6,2),a.bIt("onMenuOpen",function(){a.eBV(te);const Ct=a.XpG();return a.Njj(Ct.triggerChangeDetection())})("onMenuClose",function(){a.eBV(te);const Ct=a.XpG();return a.Njj(Ct.triggerChangeDetection())}),a.DNE(2,$e,1,0,"ng-container",7),a.k0s()}if(2&Q){const te=a.sdS(1),ot=a.XpG(),Ct=a.sdS(2),Bn=a.sdS(6);a.Y8G("ngClass",a.l_i(4,qe,te.menuOpen,ot.item.active))("matMenuTriggerFor",Ct),a.R7$(2),a.Y8G("ngTemplateOutlet",Bn)("ngTemplateOutletContext",a.eq3(7,_t,ot.item))}}function Ke(Q,et){if(1&Q&&(a.j41(0,"div",8),a.nrm(1,"angor-horizontal-navigation-basic-item",11),a.k0s()),2&Q){const te=a.XpG(2).$implicit,ot=a.XpG();a.Y8G("disabled",te.disabled),a.R7$(),a.Y8G("item",te)("name",ot.name)}}function Ze(Q,et){1&Q&&a.eu8(0)}function it(Q,et){if(1&Q&&(a.j41(0,"div",9),a.DNE(1,Ze,1,0,"ng-container",7),a.nrm(2,"angor-horizontal-navigation-branch-item",12,3),a.k0s()),2&Q){const te=a.sdS(3),ot=a.XpG(2).$implicit,Ct=a.XpG(),Bn=a.sdS(6);a.Y8G("disabled",ot.disabled)("matMenuTriggerFor",te.matMenu),a.R7$(),a.Y8G("ngTemplateOutlet",Bn)("ngTemplateOutletContext",a.eq3(7,_t,ot)),a.R7$(),a.Y8G("child",!0)("item",ot)("name",Ct.name)}}function Ot(Q,et){if(1&Q&&(a.j41(0,"div",10),a.nrm(1,"angor-horizontal-navigation-divider-item",11),a.k0s()),2&Q){const te=a.XpG(2).$implicit,ot=a.XpG();a.R7$(),a.Y8G("item",te)("name",ot.name)}}function $t(Q,et){if(1&Q&&a.DNE(0,Ke,2,3,"div",8)(1,it,4,9,"div",9)(2,Ot,2,2,"div",10),2&Q){const te=a.XpG().$implicit;a.vxM("basic"===te.type?0:-1),a.R7$(),a.vxM("aside"===te.type||"collapsable"===te.type||"group"===te.type?1:-1),a.R7$(),a.vxM("divider"===te.type?2:-1)}}function Te(Q,et){if(1&Q&&a.DNE(0,$t,3,3),2&Q){const te=et.$implicit;a.vxM(te.hidden&&!te.hidden(te)||!te.hidden?0:-1)}}function Ee(Q,et){if(1&Q&&a.nrm(0,"mat-icon",15),2&Q){const te=a.XpG().$implicit;a.Y8G("ngClass",null==te.classes?null:te.classes.icon)("svgIcon",te.icon)}}function st(Q,et){if(1&Q&&(a.j41(0,"div",19)(1,"span",18),a.EFF(2),a.k0s()()),2&Q){const te=a.XpG().$implicit;a.R7$(),a.Y8G("ngClass",null==te.classes?null:te.classes.subtitle),a.R7$(),a.SpI(" ",te.subtitle," ")}}function Xt(Q,et){if(1&Q&&(a.j41(0,"div",20)(1,"div",21),a.EFF(2),a.k0s()()),2&Q){const te=a.XpG().$implicit;a.R7$(),a.Y8G("ngClass",te.badge.classes),a.R7$(),a.SpI(" ",te.badge.title," ")}}function Mt(Q,et){if(1&Q&&(a.j41(0,"div",13)(1,"div",14),a.DNE(2,Ee,1,2,"mat-icon",15),a.j41(3,"div",16)(4,"div",17)(5,"span",18),a.EFF(6),a.k0s()(),a.DNE(7,st,3,2,"div",19),a.k0s(),a.DNE(8,Xt,3,2,"div",20),a.k0s()()),2&Q){const te=et.$implicit;a.AVh("angor-horizontal-navigation-item-has-subtitle",!!te.subtitle),a.Y8G("ngClass",null==te.classes?null:te.classes.wrapper),a.R7$(),a.Y8G("ngClass",a.l_i(10,ze,te.disabled,te.active))("matTooltip",te.tooltip||""),a.R7$(),a.vxM(te.icon?2:-1),a.R7$(3),a.Y8G("ngClass",null==te.classes?null:te.classes.title),a.R7$(),a.SpI(" ",te.title," "),a.R7$(),a.vxM(te.subtitle?7:-1),a.R7$(),a.vxM(te.badge?8:-1)}}let Kt=(()=>{class Q{constructor(){this._changeDetectorRef=(0,a.WQX)(a.gRc),this._angorNavigationService=(0,a.WQX)(c),this.child=!1,this._unsubscribeAll=new C.B}ngOnInit(){this._angorHorizontalNavigationComponent=this._angorNavigationService.getComponent(this.name),this._angorHorizontalNavigationComponent.onRefreshed.pipe((0,Z.Q)(this._unsubscribeAll)).subscribe(()=>{this._changeDetectorRef.markForCheck()})}ngOnDestroy(){this._unsubscribeAll.next(null),this._unsubscribeAll.complete()}triggerChangeDetection(){this._changeDetectorRef.markForCheck()}trackByFn(te,ot){return ot.id||te}static{this.\u0275fac=function(ot){return new(ot||Q)}}static{this.\u0275cmp=a.VBU({type:Q,selectors:[["angor-horizontal-navigation-branch-item"]],viewQuery:function(ot,Ct){if(1&ot&&a.GBs(yn,7),2&ot){let Bn;a.mGM(Bn=a.lsd())&&(Ct.matMenu=Bn.first)}},inputs:{child:"child",item:"item",name:"name"},decls:7,vars:2,consts:[["matMenu","matMenu"],["itemTemplate",""],["trigger","matMenuTrigger"],["branch",""],[3,"ngClass","matMenuTriggerFor"],[1,"angor-horizontal-navigation-menu-panel",3,"overlapTrigger"],[3,"onMenuOpen","onMenuClose","ngClass","matMenuTriggerFor"],[4,"ngTemplateOutlet","ngTemplateOutletContext"],["mat-menu-item","",1,"angor-horizontal-navigation-menu-item",3,"disabled"],["mat-menu-item","",1,"angor-horizontal-navigation-menu-item",3,"disabled","matMenuTriggerFor"],["mat-menu-item","",1,"angor-horizontal-navigation-menu-item"],[3,"item","name"],[3,"child","item","name"],[1,"angor-horizontal-navigation-item-wrapper",3,"ngClass"],[1,"angor-horizontal-navigation-item",3,"ngClass","matTooltip"],[1,"angor-horizontal-navigation-item-icon",3,"ngClass","svgIcon"],[1,"angor-horizontal-navigation-item-title-wrapper"],[1,"angor-horizontal-navigation-item-title"],[3,"ngClass"],[1,"angor-horizontal-navigation-item-subtitle","text-hint"],[1,"angor-horizontal-navigation-item-badge"],[1,"angor-horizontal-navigation-item-badge-content",3,"ngClass"]],template:function(ot,Ct){1&ot&&(a.DNE(0,Ft,3,9,"div",4),a.j41(1,"mat-menu",5,0),a.Z7z(3,Te,1,1,null,null,Ct.trackByFn,!0),a.k0s(),a.DNE(5,Mt,9,13,"ng-template",null,1,a.C5r)),2&ot&&(a.vxM(Ct.child?-1:0),a.R7$(),a.Y8G("overlapTrigger",!1),a.R7$(2),a.Dyx(Ct.item.children))},dependencies:()=>[Q,T.YU,M.Cn,M.kk,M.fb,M.Cp,T.T3,bn,Vn,O.uc,O.oV,S.m_,S.An],encapsulation:2,changeDetection:0})}}return Q})(),rt=(()=>{class Q{constructor(){this._changeDetectorRef=(0,a.WQX)(a.gRc),this._angorNavigationService=(0,a.WQX)(c),this._unsubscribeAll=new C.B}ngOnInit(){this._angorHorizontalNavigationComponent=this._angorNavigationService.getComponent(this.name),this._angorHorizontalNavigationComponent.onRefreshed.pipe((0,Z.Q)(this._unsubscribeAll)).subscribe(()=>{this._changeDetectorRef.markForCheck()})}ngOnDestroy(){this._unsubscribeAll.next(null),this._unsubscribeAll.complete()}static{this.\u0275fac=function(ot){return new(ot||Q)}}static{this.\u0275cmp=a.VBU({type:Q,selectors:[["angor-horizontal-navigation-spacer-item"]],inputs:{item:"item",name:"name"},decls:1,vars:1,consts:[[1,"angor-horizontal-navigation-item-wrapper",3,"ngClass"]],template:function(ot,Ct){1&ot&&a.nrm(0,"div",0),2&ot&&a.Y8G("ngClass",null==Ct.item.classes?null:Ct.item.classes.wrapper)},dependencies:[T.YU],encapsulation:2,changeDetection:0})}}return Q})();function Vt(Q,et){if(1&Q&&a.nrm(0,"angor-horizontal-navigation-basic-item",1),2&Q){const te=a.XpG(2).$implicit,ot=a.XpG();a.Y8G("item",te)("name",ot.name)}}function en(Q,et){if(1&Q&&a.nrm(0,"angor-horizontal-navigation-branch-item",1),2&Q){const te=a.XpG(2).$implicit,ot=a.XpG();a.Y8G("item",te)("name",ot.name)}}function kn(Q,et){if(1&Q&&a.nrm(0,"angor-horizontal-navigation-spacer-item",1),2&Q){const te=a.XpG(2).$implicit,ot=a.XpG();a.Y8G("item",te)("name",ot.name)}}function Kn(Q,et){if(1&Q&&a.DNE(0,Vt,1,2,"angor-horizontal-navigation-basic-item",1)(1,en,1,2,"angor-horizontal-navigation-branch-item",1)(2,kn,1,2,"angor-horizontal-navigation-spacer-item",1),2&Q){const te=a.XpG().$implicit;a.vxM("basic"===te.type?0:-1),a.R7$(),a.vxM("aside"===te.type||"collapsable"===te.type||"group"===te.type?1:-1),a.R7$(),a.vxM("spacer"===te.type?2:-1)}}function Nr(Q,et){if(1&Q&&a.DNE(0,Kn,3,3),2&Q){const te=et.$implicit;a.vxM(te.hidden&&!te.hidden(te)||!te.hidden?0:-1)}}let Rn=(()=>{class Q{constructor(){this._changeDetectorRef=(0,a.WQX)(a.gRc),this._angorNavigationService=(0,a.WQX)(c),this._angorUtilsService=(0,a.WQX)(y.Q),this.name=this._angorUtilsService.randomId(),this.onRefreshed=new w.m(1),this._unsubscribeAll=new C.B}ngOnChanges(te){"navigation"in te&&this._changeDetectorRef.markForCheck()}ngOnInit(){""===this.name&&(this.name=this._angorUtilsService.randomId()),this._angorNavigationService.registerComponent(this.name,this)}ngOnDestroy(){this._angorNavigationService.deregisterComponent(this.name),this._unsubscribeAll.next(null),this._unsubscribeAll.complete()}refresh(){this._changeDetectorRef.markForCheck(),this.onRefreshed.next(!0)}trackByFn(te,ot){return ot.id||te}static{this.\u0275fac=function(ot){return new(ot||Q)}}static{this.\u0275cmp=a.VBU({type:Q,selectors:[["angor-horizontal-navigation"]],inputs:{name:"name",navigation:"navigation"},exportAs:["angorHorizontalNavigation"],features:[a.OA$],decls:3,vars:0,consts:[[1,"angor-horizontal-navigation-wrapper"],[1,"angor-horizontal-navigation-menu-item",3,"item","name"]],template:function(ot,Ct){1&ot&&(a.j41(0,"div",0),a.Z7z(1,Nr,1,1,null,null,Ct.trackByFn,!0),a.k0s()),2&ot&&(a.R7$(),a.Dyx(Ct.navigation))},dependencies:[bn,Kt,rt],styles:["angor-horizontal-navigation .angor-horizontal-navigation-wrapper{display:flex;align-items:center}@media (min-width: 600px){angor-horizontal-navigation .angor-horizontal-navigation-wrapper angor-horizontal-navigation-basic-item:hover .angor-horizontal-navigation-item-wrapper,angor-horizontal-navigation .angor-horizontal-navigation-wrapper angor-horizontal-navigation-branch-item:hover .angor-horizontal-navigation-item-wrapper{background-color:var(--angor-bg-hover)}}angor-horizontal-navigation .angor-horizontal-navigation-wrapper angor-horizontal-navigation-basic-item .angor-horizontal-navigation-item-wrapper,angor-horizontal-navigation .angor-horizontal-navigation-wrapper angor-horizontal-navigation-branch-item .angor-horizontal-navigation-item-wrapper{border-radius:4px;overflow:hidden}angor-horizontal-navigation .angor-horizontal-navigation-wrapper angor-horizontal-navigation-basic-item .angor-horizontal-navigation-item-wrapper .angor-horizontal-navigation-item,angor-horizontal-navigation .angor-horizontal-navigation-wrapper angor-horizontal-navigation-branch-item .angor-horizontal-navigation-item-wrapper .angor-horizontal-navigation-item{padding:0 16px;cursor:pointer;-webkit-user-select:none;user-select:none}angor-horizontal-navigation .angor-horizontal-navigation-wrapper angor-horizontal-navigation-basic-item .angor-horizontal-navigation-item-wrapper .angor-horizontal-navigation-item .angor-horizontal-navigation-item-icon,angor-horizontal-navigation .angor-horizontal-navigation-wrapper angor-horizontal-navigation-branch-item .angor-horizontal-navigation-item-wrapper .angor-horizontal-navigation-item .angor-horizontal-navigation-item-icon{margin-right:12px}angor-horizontal-navigation .angor-horizontal-navigation-wrapper angor-horizontal-navigation-basic-item .angor-horizontal-navigation-item-active .angor-horizontal-navigation-item-title,angor-horizontal-navigation .angor-horizontal-navigation-wrapper angor-horizontal-navigation-basic-item .angor-horizontal-navigation-item-active-forced .angor-horizontal-navigation-item-title{--tw-text-opacity: 1 !important;color:rgba(var(--angor-primary-rgb),var(--tw-text-opacity, 1))!important}angor-horizontal-navigation .angor-horizontal-navigation-wrapper angor-horizontal-navigation-basic-item .angor-horizontal-navigation-item-active .angor-horizontal-navigation-item-subtitle,angor-horizontal-navigation .angor-horizontal-navigation-wrapper angor-horizontal-navigation-basic-item .angor-horizontal-navigation-item-active-forced .angor-horizontal-navigation-item-subtitle{--tw-text-opacity: 1 !important;color:rgba(var(--angor-primary-400-rgb),var(--tw-text-opacity, 1))!important}.dark angor-horizontal-navigation .angor-horizontal-navigation-wrapper angor-horizontal-navigation-basic-item .angor-horizontal-navigation-item-active .angor-horizontal-navigation-item-subtitle,.dark angor-horizontal-navigation .angor-horizontal-navigation-wrapper angor-horizontal-navigation-basic-item .angor-horizontal-navigation-item-active-forced .angor-horizontal-navigation-item-subtitle{--tw-text-opacity: 1 !important;color:rgba(var(--angor-primary-600-rgb),var(--tw-text-opacity, 1))!important}angor-horizontal-navigation .angor-horizontal-navigation-wrapper angor-horizontal-navigation-basic-item .angor-horizontal-navigation-item-active .angor-horizontal-navigation-item-icon,angor-horizontal-navigation .angor-horizontal-navigation-wrapper angor-horizontal-navigation-basic-item .angor-horizontal-navigation-item-active-forced .angor-horizontal-navigation-item-icon{--tw-text-opacity: 1 !important;color:rgba(var(--angor-primary-rgb),var(--tw-text-opacity, 1))!important}angor-horizontal-navigation .angor-horizontal-navigation-wrapper angor-horizontal-navigation-branch-item .angor-horizontal-navigation-menu-active .angor-horizontal-navigation-item-wrapper,angor-horizontal-navigation .angor-horizontal-navigation-wrapper angor-horizontal-navigation-branch-item .angor-horizontal-navigation-menu-active-forced .angor-horizontal-navigation-item-wrapper{background-color:var(--angor-bg-hover)}angor-horizontal-navigation .angor-horizontal-navigation-wrapper angor-horizontal-navigation-spacer-item{margin:12px 0}.angor-horizontal-navigation-menu-panel .angor-horizontal-navigation-menu-item{height:auto;min-height:0;line-height:normal;white-space:normal}.angor-horizontal-navigation-menu-panel .angor-horizontal-navigation-menu-item angor-horizontal-navigation-basic-item,.angor-horizontal-navigation-menu-panel .angor-horizontal-navigation-menu-item angor-horizontal-navigation-branch-item,.angor-horizontal-navigation-menu-panel .angor-horizontal-navigation-menu-item angor-horizontal-navigation-divider-item{display:flex;flex:1 1 auto}.angor-horizontal-navigation-menu-panel .angor-horizontal-navigation-menu-item angor-horizontal-navigation-divider-item{margin:8px -16px}.angor-horizontal-navigation-menu-panel .angor-horizontal-navigation-menu-item angor-horizontal-navigation-divider-item .angor-horizontal-navigation-item-wrapper{height:1px;box-shadow:0 1px}.angor-horizontal-navigation-menu-item angor-horizontal-navigation-basic-item .angor-horizontal-navigation-item-active .angor-horizontal-navigation-item-title,.angor-horizontal-navigation-menu-item angor-horizontal-navigation-basic-item .angor-horizontal-navigation-item-active-forced .angor-horizontal-navigation-item-title{--tw-text-opacity: 1 !important;color:rgba(var(--angor-primary-rgb),var(--tw-text-opacity, 1))!important}.angor-horizontal-navigation-menu-item angor-horizontal-navigation-basic-item .angor-horizontal-navigation-item-active .angor-horizontal-navigation-item-subtitle,.angor-horizontal-navigation-menu-item angor-horizontal-navigation-basic-item .angor-horizontal-navigation-item-active-forced .angor-horizontal-navigation-item-subtitle{--tw-text-opacity: 1 !important;color:rgba(var(--angor-primary-400-rgb),var(--tw-text-opacity, 1))!important}.dark .angor-horizontal-navigation-menu-item angor-horizontal-navigation-basic-item .angor-horizontal-navigation-item-active .angor-horizontal-navigation-item-subtitle,.dark .angor-horizontal-navigation-menu-item angor-horizontal-navigation-basic-item .angor-horizontal-navigation-item-active-forced .angor-horizontal-navigation-item-subtitle{--tw-text-opacity: 1 !important;color:rgba(var(--angor-primary-600-rgb),var(--tw-text-opacity, 1))!important}.angor-horizontal-navigation-menu-item angor-horizontal-navigation-basic-item .angor-horizontal-navigation-item-active .angor-horizontal-navigation-item-icon,.angor-horizontal-navigation-menu-item angor-horizontal-navigation-basic-item .angor-horizontal-navigation-item-active-forced .angor-horizontal-navigation-item-icon{--tw-text-opacity: 1 !important;color:rgba(var(--angor-primary-rgb),var(--tw-text-opacity, 1))!important}.angor-horizontal-navigation-menu-item .angor-horizontal-navigation-item-wrapper{width:100%}.angor-horizontal-navigation-menu-item .angor-horizontal-navigation-item-wrapper.angor-horizontal-navigation-item-has-subtitle .angor-horizontal-navigation-item{min-height:56px}.angor-horizontal-navigation-menu-item .angor-horizontal-navigation-item-wrapper .angor-horizontal-navigation-item{position:relative;display:flex;align-items:center;justify-content:flex-start;min-height:48px;width:100%;font-size:13px;font-weight:500;text-decoration:none}.angor-horizontal-navigation-menu-item .angor-horizontal-navigation-item-wrapper .angor-horizontal-navigation-item .angor-horizontal-navigation-item-title-wrapper .angor-horizontal-navigation-item-subtitle{font-size:12px}.angor-horizontal-navigation-menu-item .angor-horizontal-navigation-item-wrapper .angor-horizontal-navigation-item .angor-horizontal-navigation-item-badge{margin-left:auto}.angor-horizontal-navigation-menu-item .angor-horizontal-navigation-item-wrapper .angor-horizontal-navigation-item .angor-horizontal-navigation-item-badge .angor-horizontal-navigation-item-badge-content{display:flex;align-items:center;justify-content:center;font-size:10px;font-weight:600;white-space:nowrap;height:20px}\n"],encapsulation:2,data:{animation:i.F},changeDetection:0})}}return Q})();const pr=Q=>({"angor-vertical-navigation-item-active-forced":Q}),cn=Q=>[Q];function Fe(Q,et){1&Q&&a.eu8(0)}function ke(Q,et){if(1&Q&&(a.j41(0,"a",2),a.DNE(1,Fe,1,0,"ng-container",6),a.k0s()),2&Q){let te,ot,Ct,Bn;const On=a.XpG(),Wn=a.sdS(9);a.Y8G("ngClass",a.eq3(10,pr,On.item.active))("routerLink",a.eq3(12,cn,On.item.link))("fragment",null!==(te=On.item.fragment)&&void 0!==te?te:null)("preserveFragment",null!==(ot=On.item.preserveFragment)&&void 0!==ot&&ot)("queryParams",null!==(Ct=On.item.queryParams)&&void 0!==Ct?Ct:null)("queryParamsHandling",null!==(Bn=On.item.queryParamsHandling)&&void 0!==Bn?Bn:null)("routerLinkActive","angor-vertical-navigation-item-active")("routerLinkActiveOptions",On.isActiveMatchOptions)("matTooltip",On.item.tooltip||""),a.R7$(),a.Y8G("ngTemplateOutlet",Wn)}}function Je(Q,et){1&Q&&a.eu8(0)}function z(Q,et){if(1&Q&&(a.j41(0,"a",3),a.DNE(1,Je,1,0,"ng-container",6),a.k0s()),2&Q){const te=a.XpG(),ot=a.sdS(9);a.Y8G("href",te.item.link,a.B4B)("target",te.item.target||"_self")("matTooltip",te.item.tooltip||""),a.R7$(),a.Y8G("ngTemplateOutlet",ot)}}function N(Q,et){1&Q&&a.eu8(0)}function W(Q,et){if(1&Q){const te=a.RV6();a.j41(0,"div",7),a.bIt("click",function(){a.eBV(te);const Ct=a.XpG();return a.Njj(Ct.item.function(Ct.item))}),a.DNE(1,N,1,0,"ng-container",6),a.k0s()}if(2&Q){const te=a.XpG(),ot=a.sdS(9);a.Y8G("ngClass",a.eq3(3,pr,te.item.active))("matTooltip",te.item.tooltip||""),a.R7$(),a.Y8G("ngTemplateOutlet",ot)}}function Le(Q,et){1&Q&&a.eu8(0)}function ft(Q,et){if(1&Q){const te=a.RV6();a.j41(0,"a",8),a.bIt("click",function(){a.eBV(te);const Ct=a.XpG();return a.Njj(Ct.item.function(Ct.item))}),a.DNE(1,Le,1,0,"ng-container",6),a.k0s()}if(2&Q){let te,ot,Ct,Bn;const On=a.XpG(),Wn=a.sdS(9);a.Y8G("ngClass",a.eq3(10,pr,On.item.active))("routerLink",a.eq3(12,cn,On.item.link))("fragment",null!==(te=On.item.fragment)&&void 0!==te?te:null)("preserveFragment",null!==(ot=On.item.preserveFragment)&&void 0!==ot&&ot)("queryParams",null!==(Ct=On.item.queryParams)&&void 0!==Ct?Ct:null)("queryParamsHandling",null!==(Bn=On.item.queryParamsHandling)&&void 0!==Bn?Bn:null)("routerLinkActive","angor-vertical-navigation-item-active")("routerLinkActiveOptions",On.isActiveMatchOptions)("matTooltip",On.item.tooltip||""),a.R7$(),a.Y8G("ngTemplateOutlet",Wn)}}function mt(Q,et){1&Q&&a.eu8(0)}function St(Q,et){if(1&Q){const te=a.RV6();a.j41(0,"a",9),a.bIt("click",function(){a.eBV(te);const Ct=a.XpG();return a.Njj(Ct.item.function(Ct.item))}),a.DNE(1,mt,1,0,"ng-container",6),a.k0s()}if(2&Q){const te=a.XpG(),ot=a.sdS(9);a.Y8G("href",te.item.link,a.B4B)("target",te.item.target||"_self")("matTooltip",te.item.tooltip||""),a.R7$(),a.Y8G("ngTemplateOutlet",ot)}}function Tn(Q,et){1&Q&&a.eu8(0)}function an(Q,et){if(1&Q&&(a.j41(0,"div",4),a.DNE(1,Tn,1,0,"ng-container",6),a.k0s()),2&Q){const te=a.XpG(),ot=a.sdS(9);a.Y8G("ngClass",a.eq3(3,pr,te.item.active))("matTooltip",te.item.tooltip||""),a.R7$(),a.Y8G("ngTemplateOutlet",ot)}}function dn(Q,et){1&Q&&a.eu8(0)}function In(Q,et){if(1&Q&&(a.j41(0,"div",5),a.DNE(1,dn,1,0,"ng-container",6),a.k0s()),2&Q){const te=a.XpG(),ot=a.sdS(9);a.Y8G("matTooltip",te.item.tooltip||""),a.R7$(),a.Y8G("ngTemplateOutlet",ot)}}function sr(Q,et){if(1&Q&&a.nrm(0,"mat-icon",10),2&Q){const te=a.XpG(2);a.Y8G("ngClass",null==te.item.classes?null:te.item.classes.icon)("svgIcon",te.item.icon)}}function xn(Q,et){if(1&Q&&(a.j41(0,"div",14)(1,"span",13),a.EFF(2),a.k0s()()),2&Q){const te=a.XpG(2);a.R7$(),a.Y8G("ngClass",null==te.item.classes?null:te.item.classes.subtitle),a.R7$(),a.SpI(" ",te.item.subtitle," ")}}function Hr(Q,et){if(1&Q&&(a.j41(0,"div",15)(1,"div",16),a.EFF(2),a.k0s()()),2&Q){const te=a.XpG(2);a.R7$(),a.Y8G("ngClass",te.item.badge.classes),a.R7$(),a.SpI(" ",te.item.badge.title," ")}}function Tr(Q,et){if(1&Q&&(a.DNE(0,sr,1,2,"mat-icon",10),a.j41(1,"div",11)(2,"div",12)(3,"span",13),a.EFF(4),a.k0s()(),a.DNE(5,xn,3,2,"div",14),a.k0s(),a.DNE(6,Hr,3,2,"div",15)),2&Q){const te=a.XpG();a.vxM(te.item.icon?0:-1),a.R7$(3),a.Y8G("ngClass",null==te.item.classes?null:te.item.classes.title),a.R7$(),a.SpI(" ",te.item.title," "),a.R7$(),a.vxM(te.item.subtitle?5:-1),a.R7$(),a.vxM(te.item.badge?6:-1)}}let Vr=(()=>{class Q{constructor(){this._changeDetectorRef=(0,a.WQX)(a.gRc),this._angorNavigationService=(0,a.WQX)(c),this._angorUtilsService=(0,a.WQX)(y.Q),this.isActiveMatchOptions=this._angorUtilsService.subsetMatchOptions,this._unsubscribeAll=new C.B}ngOnInit(){this.isActiveMatchOptions=this.item.isActiveMatchOptions??this.item.exactMatch?this._angorUtilsService.exactMatchOptions:this._angorUtilsService.subsetMatchOptions,this._angorVerticalNavigationComponent=this._angorNavigationService.getComponent(this.name),this._changeDetectorRef.markForCheck(),this._angorVerticalNavigationComponent.onRefreshed.pipe((0,Z.Q)(this._unsubscribeAll)).subscribe(()=>{this._changeDetectorRef.markForCheck()})}ngOnDestroy(){this._unsubscribeAll.next(null),this._unsubscribeAll.complete()}static{this.\u0275fac=function(ot){return new(ot||Q)}}static{this.\u0275cmp=a.VBU({type:Q,selectors:[["angor-vertical-navigation-basic-item"]],inputs:{item:"item",name:"name"},decls:10,vars:10,consts:[["itemTemplate",""],[1,"angor-vertical-navigation-item-wrapper",3,"ngClass"],[1,"angor-vertical-navigation-item",3,"ngClass","routerLink","fragment","preserveFragment","queryParams","queryParamsHandling","routerLinkActive","routerLinkActiveOptions","matTooltip"],[1,"angor-vertical-navigation-item",3,"href","target","matTooltip"],[1,"angor-vertical-navigation-item",3,"ngClass","matTooltip"],[1,"angor-vertical-navigation-item","angor-vertical-navigation-item-disabled",3,"matTooltip"],[4,"ngTemplateOutlet"],[1,"angor-vertical-navigation-item",3,"click","ngClass","matTooltip"],[1,"angor-vertical-navigation-item",3,"click","ngClass","routerLink","fragment","preserveFragment","queryParams","queryParamsHandling","routerLinkActive","routerLinkActiveOptions","matTooltip"],[1,"angor-vertical-navigation-item",3,"click","href","target","matTooltip"],[1,"angor-vertical-navigation-item-icon",3,"ngClass","svgIcon"],[1,"angor-vertical-navigation-item-title-wrapper"],[1,"angor-vertical-navigation-item-title"],[3,"ngClass"],[1,"angor-vertical-navigation-item-subtitle"],[1,"angor-vertical-navigation-item-badge"],[1,"angor-vertical-navigation-item-badge-content",3,"ngClass"]],template:function(ot,Ct){1&ot&&(a.j41(0,"div",1),a.DNE(1,ke,2,14,"a",2)(2,z,2,4,"a",3)(3,W,2,5,"div",4)(4,ft,2,14,"a",2)(5,St,2,4,"a",3)(6,an,2,5,"div",4)(7,In,2,2,"div",5),a.k0s(),a.DNE(8,Tr,7,5,"ng-template",null,0,a.C5r)),2&ot&&(a.AVh("angor-vertical-navigation-item-has-subtitle",!!Ct.item.subtitle),a.Y8G("ngClass",null==Ct.item.classes?null:Ct.item.classes.wrapper),a.R7$(),a.vxM(!Ct.item.link||Ct.item.externalLink||Ct.item.function||Ct.item.disabled?-1:1),a.R7$(),a.vxM(Ct.item.link&&Ct.item.externalLink&&!Ct.item.function&&!Ct.item.disabled?2:-1),a.R7$(),a.vxM(Ct.item.link||!Ct.item.function||Ct.item.disabled?-1:3),a.R7$(),a.vxM(Ct.item.link&&!Ct.item.externalLink&&Ct.item.function&&!Ct.item.disabled?4:-1),a.R7$(),a.vxM(Ct.item.link&&Ct.item.externalLink&&Ct.item.function&&!Ct.item.disabled?5:-1),a.R7$(),a.vxM(Ct.item.link||Ct.item.function||Ct.item.disabled?-1:6),a.R7$(),a.vxM(Ct.item.disabled?7:-1))},dependencies:[T.YU,L.Wk,L.wQ,O.uc,O.oV,T.T3,S.m_,S.An],encapsulation:2,changeDetection:0})}}return Q})(),vt=(()=>{class Q{constructor(){this._changeDetectorRef=(0,a.WQX)(a.gRc),this._angorNavigationService=(0,a.WQX)(c),this._unsubscribeAll=new C.B}ngOnInit(){this._angorVerticalNavigationComponent=this._angorNavigationService.getComponent(this.name),this._angorVerticalNavigationComponent.onRefreshed.pipe((0,Z.Q)(this._unsubscribeAll)).subscribe(()=>{this._changeDetectorRef.markForCheck()})}ngOnDestroy(){this._unsubscribeAll.next(null),this._unsubscribeAll.complete()}static{this.\u0275fac=function(ot){return new(ot||Q)}}static{this.\u0275cmp=a.VBU({type:Q,selectors:[["angor-vertical-navigation-divider-item"]],inputs:{item:"item",name:"name"},decls:1,vars:1,consts:[[1,"angor-vertical-navigation-item-wrapper","divider",3,"ngClass"]],template:function(ot,Ct){1&ot&&a.nrm(0,"div",0),2&ot&&a.Y8G("ngClass",null==Ct.item.classes?null:Ct.item.classes.wrapper)},dependencies:[T.YU],encapsulation:2,changeDetection:0})}}return Q})(),Wt=(()=>{class Q{constructor(){this._changeDetectorRef=(0,a.WQX)(a.gRc),this._angorNavigationService=(0,a.WQX)(c),this._unsubscribeAll=new C.B}ngOnInit(){this._angorVerticalNavigationComponent=this._angorNavigationService.getComponent(this.name),this._angorVerticalNavigationComponent.onRefreshed.pipe((0,Z.Q)(this._unsubscribeAll)).subscribe(()=>{this._changeDetectorRef.markForCheck()})}ngOnDestroy(){this._unsubscribeAll.next(null),this._unsubscribeAll.complete()}static{this.\u0275fac=function(ot){return new(ot||Q)}}static{this.\u0275cmp=a.VBU({type:Q,selectors:[["angor-vertical-navigation-spacer-item"]],inputs:{item:"item",name:"name"},decls:1,vars:1,consts:[[1,"angor-vertical-navigation-item-wrapper",3,"ngClass"]],template:function(ot,Ct){1&ot&&a.nrm(0,"div",0),2&ot&&a.Y8G("ngClass",null==Ct.item.classes?null:Ct.item.classes.wrapper)},dependencies:[T.YU],encapsulation:2,changeDetection:0})}}return Q})();function Re(Q,et){if(1&Q&&a.nrm(0,"mat-icon",2),2&Q){const te=a.XpG();a.Y8G("ngClass",null==te.item.classes?null:te.item.classes.icon)("svgIcon",te.item.icon)}}function Ge(Q,et){if(1&Q&&(a.j41(0,"div",6)(1,"span",5),a.EFF(2),a.k0s()()),2&Q){const te=a.XpG();a.R7$(),a.Y8G("ngClass",null==te.item.classes?null:te.item.classes.subtitle),a.R7$(),a.SpI(" ",te.item.subtitle," ")}}function Ve(Q,et){if(1&Q&&(a.j41(0,"div",7)(1,"div",8),a.EFF(2),a.k0s()()),2&Q){const te=a.XpG();a.R7$(),a.Y8G("ngClass",te.item.badge.classes),a.R7$(),a.SpI(" ",te.item.badge.title," ")}}function Dt(Q,et){if(1&Q&&a.nrm(0,"angor-vertical-navigation-basic-item",9),2&Q){const te=a.XpG(2).$implicit,ot=a.XpG();a.Y8G("item",te)("name",ot.name)}}function ct(Q,et){if(1&Q&&a.nrm(0,"angor-vertical-navigation-collapsable-item",10),2&Q){const te=a.XpG(2).$implicit,ot=a.XpG();a.Y8G("item",te)("name",ot.name)("autoCollapse",ot.autoCollapse)}}function Bt(Q,et){if(1&Q&&a.nrm(0,"angor-vertical-navigation-divider-item",9),2&Q){const te=a.XpG(2).$implicit,ot=a.XpG();a.Y8G("item",te)("name",ot.name)}}function wn(Q,et){if(1&Q&&a.nrm(0,"angor-vertical-navigation-group-item",9),2&Q){const te=a.XpG(2).$implicit,ot=a.XpG();a.Y8G("item",te)("name",ot.name)}}function qn(Q,et){if(1&Q&&a.nrm(0,"angor-vertical-navigation-spacer-item",9),2&Q){const te=a.XpG(2).$implicit,ot=a.XpG();a.Y8G("item",te)("name",ot.name)}}function Er(Q,et){if(1&Q&&a.DNE(0,Dt,1,2,"angor-vertical-navigation-basic-item",9)(1,ct,1,3,"angor-vertical-navigation-collapsable-item",10)(2,Bt,1,2,"angor-vertical-navigation-divider-item",9)(3,wn,1,2,"angor-vertical-navigation-group-item",9)(4,qn,1,2,"angor-vertical-navigation-spacer-item",9),2&Q){const te=a.XpG().$implicit;a.vxM("basic"===te.type?0:-1),a.R7$(),a.vxM("collapsable"===te.type?1:-1),a.R7$(),a.vxM("divider"===te.type?2:-1),a.R7$(),a.vxM("group"===te.type?3:-1),a.R7$(),a.vxM("spacer"===te.type?4:-1)}}function si(Q,et){if(1&Q&&a.DNE(0,Er,5,5),2&Q){const te=et.$implicit;a.vxM(te.hidden&&!te.hidden(te)||!te.hidden?0:-1)}}let hi=(()=>{class Q{constructor(){this._changeDetectorRef=(0,a.WQX)(a.gRc),this._angorNavigationService=(0,a.WQX)(c),this._unsubscribeAll=new C.B}ngOnInit(){this._angorVerticalNavigationComponent=this._angorNavigationService.getComponent(this.name),this._angorVerticalNavigationComponent.onRefreshed.pipe((0,Z.Q)(this._unsubscribeAll)).subscribe(()=>{this._changeDetectorRef.markForCheck()})}ngOnDestroy(){this._unsubscribeAll.next(null),this._unsubscribeAll.complete()}trackByFn(te,ot){return ot.id||te}static{this.\u0275fac=function(ot){return new(ot||Q)}}static{this.\u0275cmp=a.VBU({type:Q,selectors:[["angor-vertical-navigation-group-item"]],inputs:{autoCollapse:"autoCollapse",item:"item",name:"name"},decls:11,vars:8,consts:[[1,"angor-vertical-navigation-item-wrapper",3,"ngClass"],[1,"angor-vertical-navigation-item"],[1,"angor-vertical-navigation-item-icon",3,"ngClass","svgIcon"],[1,"angor-vertical-navigation-item-title-wrapper"],[1,"angor-vertical-navigation-item-title"],[3,"ngClass"],[1,"angor-vertical-navigation-item-subtitle"],[1,"angor-vertical-navigation-item-badge"],[1,"angor-vertical-navigation-item-badge-content",3,"ngClass"],[3,"item","name"],[3,"item","name","autoCollapse"]],template:function(ot,Ct){1&ot&&(a.j41(0,"div",0)(1,"div",1),a.DNE(2,Re,1,2,"mat-icon",2),a.j41(3,"div",3)(4,"div",4)(5,"span",5),a.EFF(6),a.k0s()(),a.DNE(7,Ge,3,2,"div",6),a.k0s(),a.DNE(8,Ve,3,2,"div",7),a.k0s()(),a.Z7z(9,si,1,1,null,null,Ct.trackByFn,!0)),2&ot&&(a.AVh("angor-vertical-navigation-item-has-subtitle",!!Ct.item.subtitle),a.Y8G("ngClass",null==Ct.item.classes?null:Ct.item.classes.wrapper),a.R7$(2),a.vxM(Ct.item.icon?2:-1),a.R7$(3),a.Y8G("ngClass",null==Ct.item.classes?null:Ct.item.classes.title),a.R7$(),a.SpI(" ",Ct.item.title," "),a.R7$(),a.vxM(Ct.item.subtitle?7:-1),a.R7$(),a.vxM(Ct.item.badge?8:-1),a.R7$(),a.Dyx(Ct.item.children))},dependencies:()=>[Q,T.YU,S.m_,S.An,Vr,qo,vt,Wt],encapsulation:2,changeDetection:0})}}return Q})();var Zi=r(1483);const Jt=Q=>({"angor-vertical-navigation-item-disabled":Q});function Tt(Q,et){if(1&Q&&a.nrm(0,"mat-icon",2),2&Q){const te=a.XpG();a.Y8G("ngClass",null==te.item.classes?null:te.item.classes.icon)("svgIcon",te.item.icon)}}function nt(Q,et){if(1&Q&&(a.j41(0,"div",6)(1,"span",5),a.EFF(2),a.k0s()()),2&Q){const te=a.XpG();a.R7$(),a.Y8G("ngClass",null==te.item.classes?null:te.item.classes.subtitle),a.R7$(),a.SpI(" ",te.item.subtitle," ")}}function Rt(Q,et){if(1&Q&&(a.j41(0,"div",7)(1,"div",10),a.EFF(2),a.k0s()()),2&Q){const te=a.XpG();a.R7$(),a.Y8G("ngClass",te.item.badge.classes),a.R7$(),a.SpI(" ",te.item.badge.title," ")}}function sn(Q,et){if(1&Q&&a.nrm(0,"angor-vertical-navigation-basic-item",11),2&Q){const te=a.XpG(2).$implicit,ot=a.XpG(2);a.Y8G("item",te)("name",ot.name)}}function mn(Q,et){if(1&Q&&a.nrm(0,"angor-vertical-navigation-collapsable-item",12),2&Q){const te=a.XpG(2).$implicit,ot=a.XpG(2);a.Y8G("item",te)("name",ot.name)("autoCollapse",ot.autoCollapse)}}function dr(Q,et){if(1&Q&&a.nrm(0,"angor-vertical-navigation-divider-item",11),2&Q){const te=a.XpG(2).$implicit,ot=a.XpG(2);a.Y8G("item",te)("name",ot.name)}}function Co(Q,et){if(1&Q&&a.nrm(0,"angor-vertical-navigation-group-item",11),2&Q){const te=a.XpG(2).$implicit,ot=a.XpG(2);a.Y8G("item",te)("name",ot.name)}}function Ni(Q,et){if(1&Q&&a.nrm(0,"angor-vertical-navigation-spacer-item",11),2&Q){const te=a.XpG(2).$implicit,ot=a.XpG(2);a.Y8G("item",te)("name",ot.name)}}function ds(Q,et){if(1&Q&&a.DNE(0,sn,1,2,"angor-vertical-navigation-basic-item",11)(1,mn,1,3,"angor-vertical-navigation-collapsable-item",12)(2,dr,1,2,"angor-vertical-navigation-divider-item",11)(3,Co,1,2,"angor-vertical-navigation-group-item",11)(4,Ni,1,2,"angor-vertical-navigation-spacer-item",11),2&Q){const te=a.XpG().$implicit;a.vxM("basic"===te.type?0:-1),a.R7$(),a.vxM("collapsable"===te.type?1:-1),a.R7$(),a.vxM("divider"===te.type?2:-1),a.R7$(),a.vxM("group"===te.type?3:-1),a.R7$(),a.vxM("spacer"===te.type?4:-1)}}function $o(Q,et){if(1&Q&&a.DNE(0,ds,5,5),2&Q){const te=et.$implicit;a.vxM(te.hidden&&!te.hidden(te)||!te.hidden?0:-1)}}function ai(Q,et){if(1&Q&&(a.j41(0,"div",9),a.Z7z(1,$o,1,1,null,null,a.BUC().trackByFn,!0),a.k0s()),2&Q){const te=a.XpG();a.Y8G("@expandCollapse",void 0),a.R7$(),a.Dyx(te.item.children)}}let qo=(()=>{class Q{constructor(){this._changeDetectorRef=(0,a.WQX)(a.gRc),this._router=(0,a.WQX)(L.Ix),this._angorNavigationService=(0,a.WQX)(c),this.isCollapsed=!0,this.isExpanded=!1,this._unsubscribeAll=new C.B}get classList(){return{"angor-vertical-navigation-item-collapsed":this.isCollapsed,"angor-vertical-navigation-item-expanded":this.isExpanded}}ngOnInit(){this._angorVerticalNavigationComponent=this._angorNavigationService.getComponent(this.name),this._hasActiveChild(this.item,this._router.url)?this.expand():this.autoCollapse&&this.collapse(),this._angorVerticalNavigationComponent.onCollapsableItemCollapsed.pipe((0,Z.Q)(this._unsubscribeAll)).subscribe(te=>{null!==te&&this._isChildrenOf(te,this.item)&&this.collapse()}),this.autoCollapse&&this._angorVerticalNavigationComponent.onCollapsableItemExpanded.pipe((0,Z.Q)(this._unsubscribeAll)).subscribe(te=>{null!==te&&(this._isChildrenOf(this.item,te)||this._hasActiveChild(this.item,this._router.url)||this.item!==te&&this.collapse())}),this._router.events.pipe((0,Zi.p)(te=>te instanceof L.wF),(0,Z.Q)(this._unsubscribeAll)).subscribe(te=>{this._hasActiveChild(this.item,te.urlAfterRedirects)?this.expand():this.autoCollapse&&this.collapse()}),this._angorVerticalNavigationComponent.onRefreshed.pipe((0,Z.Q)(this._unsubscribeAll)).subscribe(()=>{this._changeDetectorRef.markForCheck()})}ngOnDestroy(){this._unsubscribeAll.next(null),this._unsubscribeAll.complete()}collapse(){this.item.disabled||this.isCollapsed||(this.isCollapsed=!0,this.isExpanded=!this.isCollapsed,this._changeDetectorRef.markForCheck(),this._angorVerticalNavigationComponent.onCollapsableItemCollapsed.next(this.item))}expand(){this.item.disabled||this.isCollapsed&&(this.isCollapsed=!1,this.isExpanded=!this.isCollapsed,this._changeDetectorRef.markForCheck(),this._angorVerticalNavigationComponent.onCollapsableItemExpanded.next(this.item))}toggleCollapsable(){this.isCollapsed?this.expand():this.collapse()}trackByFn(te,ot){return ot.id||te}_hasActiveChild(te,ot){const Ct=te.children;if(!Ct)return!1;for(const Bn of Ct)if(Bn.children&&this._hasActiveChild(Bn,ot)||Bn.link&&this._router.isActive(Bn.link,Bn.exactMatch||!1))return!0;return!1}_isChildrenOf(te,ot){const Ct=te.children;if(!Ct)return!1;if(Ct.indexOf(ot)>-1)return!0;for(const Bn of Ct)if(Bn.children&&this._isChildrenOf(Bn,ot))return!0;return!1}static{this.\u0275fac=function(ot){return new(ot||Q)}}static{this.\u0275cmp=a.VBU({type:Q,selectors:[["angor-vertical-navigation-collapsable-item"]],hostVars:2,hostBindings:function(ot,Ct){2&ot&&a.HbH(Ct.classList)},inputs:{autoCollapse:"autoCollapse",item:"item",name:"name"},decls:11,vars:14,consts:[[1,"angor-vertical-navigation-item-wrapper",3,"ngClass"],[1,"angor-vertical-navigation-item",3,"click","ngClass","matTooltip"],[1,"angor-vertical-navigation-item-icon",3,"ngClass","svgIcon"],[1,"angor-vertical-navigation-item-title-wrapper"],[1,"angor-vertical-navigation-item-title"],[3,"ngClass"],[1,"angor-vertical-navigation-item-subtitle"],[1,"angor-vertical-navigation-item-badge"],[1,"angor-vertical-navigation-item-arrow","icon-size-4",3,"svgIcon"],[1,"angor-vertical-navigation-item-children"],[1,"angor-vertical-navigation-item-badge-content",3,"ngClass"],[3,"item","name"],[3,"item","name","autoCollapse"]],template:function(ot,Ct){1&ot&&(a.j41(0,"div",0)(1,"div",1),a.bIt("click",function(){return Ct.toggleCollapsable()}),a.DNE(2,Tt,1,2,"mat-icon",2),a.j41(3,"div",3)(4,"div",4)(5,"span",5),a.EFF(6),a.k0s()(),a.DNE(7,nt,3,2,"div",6),a.k0s(),a.DNE(8,Rt,3,2,"div",7),a.nrm(9,"mat-icon",8),a.k0s()(),a.DNE(10,ai,3,1,"div",9)),2&ot&&(a.AVh("angor-vertical-navigation-item-has-subtitle",!!Ct.item.subtitle),a.Y8G("ngClass",null==Ct.item.classes?null:Ct.item.classes.wrapper),a.R7$(),a.Y8G("ngClass",a.eq3(12,Jt,Ct.item.disabled))("matTooltip",Ct.item.tooltip||""),a.R7$(),a.vxM(Ct.item.icon?2:-1),a.R7$(3),a.Y8G("ngClass",null==Ct.item.classes?null:Ct.item.classes.title),a.R7$(),a.SpI(" ",Ct.item.title," "),a.R7$(),a.vxM(Ct.item.subtitle?7:-1),a.R7$(),a.vxM(Ct.item.badge?8:-1),a.R7$(),a.Y8G("svgIcon","heroicons_solid:chevron-right"),a.R7$(),a.vxM(Ct.isCollapsed?-1:10))},dependencies:()=>[Q,T.YU,O.uc,O.oV,S.m_,S.An,Vr,vt,hi,Wt],encapsulation:2,data:{animation:i.F},changeDetection:0})}}return Q})();const fo=(Q,et,te)=>({"angor-vertical-navigation-item-active":Q,"angor-vertical-navigation-item-disabled":et,"angor-vertical-navigation-item-active-forced":te});function Jo(Q,et){if(1&Q&&a.nrm(0,"mat-icon",2),2&Q){const te=a.XpG();a.Y8G("ngClass",null==te.item.classes?null:te.item.classes.icon)("svgIcon",te.item.icon)}}function Fo(Q,et){if(1&Q&&(a.j41(0,"div",6)(1,"span",5),a.EFF(2),a.k0s()()),2&Q){const te=a.XpG();a.R7$(),a.Y8G("ngClass",null==te.item.classes?null:te.item.classes.subtitle),a.R7$(),a.SpI(" ",te.item.subtitle," ")}}function oa(Q,et){if(1&Q&&(a.j41(0,"div",7)(1,"div",9),a.EFF(2),a.k0s()()),2&Q){const te=a.XpG();a.R7$(),a.Y8G("ngClass",te.item.badge.classes),a.R7$(),a.SpI(" ",te.item.badge.title," ")}}function ao(Q,et){if(1&Q&&a.nrm(0,"angor-vertical-navigation-basic-item",10),2&Q){const te=a.XpG(2).$implicit,ot=a.XpG(2);a.Y8G("item",te)("name",ot.name)}}function po(Q,et){if(1&Q&&a.nrm(0,"angor-vertical-navigation-collapsable-item",11),2&Q){const te=a.XpG(2).$implicit,ot=a.XpG(2);a.Y8G("item",te)("name",ot.name)("autoCollapse",ot.autoCollapse)}}function Ii(Q,et){if(1&Q&&a.nrm(0,"angor-vertical-navigation-divider-item",10),2&Q){const te=a.XpG(2).$implicit,ot=a.XpG(2);a.Y8G("item",te)("name",ot.name)}}function Io(Q,et){if(1&Q&&a.nrm(0,"angor-vertical-navigation-group-item",10),2&Q){const te=a.XpG(2).$implicit,ot=a.XpG(2);a.Y8G("item",te)("name",ot.name)}}function tt(Q,et){if(1&Q&&a.nrm(0,"angor-vertical-navigation-spacer-item",10),2&Q){const te=a.XpG(2).$implicit,ot=a.XpG(2);a.Y8G("item",te)("name",ot.name)}}function xt(Q,et){if(1&Q&&a.DNE(0,ao,1,2,"angor-vertical-navigation-basic-item",10)(1,po,1,3,"angor-vertical-navigation-collapsable-item",11)(2,Ii,1,2,"angor-vertical-navigation-divider-item",10)(3,Io,1,2,"angor-vertical-navigation-group-item",10)(4,tt,1,2,"angor-vertical-navigation-spacer-item",10),2&Q){const te=a.XpG().$implicit;a.vxM("basic"===te.type?0:-1),a.R7$(),a.vxM("collapsable"===te.type?1:-1),a.R7$(),a.vxM("divider"===te.type?2:-1),a.R7$(),a.vxM("group"===te.type?3:-1),a.R7$(),a.vxM("spacer"===te.type?4:-1)}}function ht(Q,et){if(1&Q&&a.DNE(0,xt,5,5),2&Q){const te=et.$implicit;a.vxM(te.hidden&&!te.hidden(te)||!te.hidden?0:-1)}}function ve(Q,et){if(1&Q&&(a.j41(0,"div",8),a.Z7z(1,ht,1,1,null,null,a.BUC().trackByFn,!0),a.k0s()),2&Q){const te=a.XpG();a.R7$(),a.Dyx(te.item.children)}}let Ye=(()=>{class Q{constructor(){this._changeDetectorRef=(0,a.WQX)(a.gRc),this._router=(0,a.WQX)(L.Ix),this._angorNavigationService=(0,a.WQX)(c),this.active=!1,this._unsubscribeAll=new C.B}ngOnChanges(te){"activeItemId"in te&&this._markIfActive(this._router.url)}ngOnInit(){this._markIfActive(this._router.url),this._router.events.pipe((0,Zi.p)(te=>te instanceof L.wF),(0,Z.Q)(this._unsubscribeAll)).subscribe(te=>{this._markIfActive(te.urlAfterRedirects)}),this._angorVerticalNavigationComponent=this._angorNavigationService.getComponent(this.name),this._angorVerticalNavigationComponent.onRefreshed.pipe((0,Z.Q)(this._unsubscribeAll)).subscribe(()=>{this._changeDetectorRef.markForCheck()})}ngOnDestroy(){this._unsubscribeAll.next(null),this._unsubscribeAll.complete()}trackByFn(te,ot){return ot.id||te}_hasActiveChild(te,ot){const Ct=te.children;if(!Ct)return!1;for(const Bn of Ct){if(Bn.children&&this._hasActiveChild(Bn,ot))return!0;if("basic"===Bn.type&&Bn.link&&this._router.isActive(Bn.link,Bn.exactMatch||!1))return!0}return!1}_markIfActive(te){this.active=this.activeItemId===this.item.id,this._hasActiveChild(this.item,te)&&(this.active=!0),this._changeDetectorRef.markForCheck()}static{this.\u0275fac=function(ot){return new(ot||Q)}}static{this.\u0275cmp=a.VBU({type:Q,selectors:[["angor-vertical-navigation-aside-item"]],inputs:{activeItemId:"activeItemId",autoCollapse:"autoCollapse",item:"item",name:"name",skipChildren:"skipChildren"},features:[a.OA$],decls:10,vars:15,consts:[[1,"angor-vertical-navigation-item-wrapper",3,"ngClass"],[1,"angor-vertical-navigation-item",3,"ngClass","matTooltip"],[1,"angor-vertical-navigation-item-icon",3,"ngClass","svgIcon"],[1,"angor-vertical-navigation-item-title-wrapper"],[1,"angor-vertical-navigation-item-title"],[3,"ngClass"],[1,"angor-vertical-navigation-item-subtitle"],[1,"angor-vertical-navigation-item-badge"],[1,"angor-vertical-navigation-item-children"],[1,"angor-vertical-navigation-item-badge-content",3,"ngClass"],[3,"item","name"],[3,"item","name","autoCollapse"]],template:function(ot,Ct){1&ot&&(a.j41(0,"div",0)(1,"div",1),a.DNE(2,Jo,1,2,"mat-icon",2),a.j41(3,"div",3)(4,"div",4)(5,"span",5),a.EFF(6),a.k0s()(),a.DNE(7,Fo,3,2,"div",6),a.k0s(),a.DNE(8,oa,3,2,"div",7),a.k0s()(),a.DNE(9,ve,3,0,"div",8)),2&ot&&(a.AVh("angor-vertical-navigation-item-has-subtitle",!!Ct.item.subtitle),a.Y8G("ngClass",null==Ct.item.classes?null:Ct.item.classes.wrapper),a.R7$(),a.Y8G("ngClass",a.sMw(11,fo,Ct.active,Ct.item.disabled,Ct.item.active))("matTooltip",Ct.item.tooltip||""),a.R7$(),a.vxM(Ct.item.icon?2:-1),a.R7$(3),a.Y8G("ngClass",null==Ct.item.classes?null:Ct.item.classes.title),a.R7$(),a.SpI(" ",Ct.item.title," "),a.R7$(),a.vxM(Ct.item.subtitle?7:-1),a.R7$(),a.vxM(Ct.item.badge?8:-1),a.R7$(),a.vxM(Ct.skipChildren?-1:9))},dependencies:[T.YU,O.uc,O.oV,S.m_,S.An,Vr,qo,vt,hi,Wt],encapsulation:2,changeDetection:0})}}return Q})();class Ne{constructor(et,te,ot,Ct){this.x=et,this.y=te,this.w=ot,this.h=Ct}}class gt{constructor(et,te){this.x=et,this.y=te}}var Ht=r(3022),kt=r(2147),hn=r(4819);function Dn(Q){return getComputedStyle(Q)}function Cn(Q,et){for(var te in et){var ot=et[te];"number"==typeof ot&&(ot+="px"),Q.style[te]=ot}return Q}function Nn(Q){var et=document.createElement("div");return et.className=Q,et}var jn=typeof Element<"u"&&(Element.prototype.matches||Element.prototype.webkitMatchesSelector||Element.prototype.mozMatchesSelector||Element.prototype.msMatchesSelector);function Jn(Q,et){if(!jn)throw new Error("No element matching method supported");return jn.call(Q,et)}function ar(Q){Q.remove?Q.remove():Q.parentNode&&Q.parentNode.removeChild(Q)}function wr(Q,et){return Array.prototype.filter.call(Q.children,function(te){return Jn(te,et)})}var xr={main:"ps",rtl:"ps__rtl",element:{thumb:function(Q){return"ps__thumb-"+Q},rail:function(Q){return"ps__rail-"+Q},consuming:"ps__child--consume"},state:{focus:"ps--focus",clicking:"ps--clicking",active:function(Q){return"ps--active-"+Q},scrolling:function(Q){return"ps--scrolling-"+Q}}},gi={x:null,y:null};function ni(Q,et){var te=Q.element.classList,ot=xr.state.scrolling(et);te.contains(ot)?clearTimeout(gi[et]):te.add(ot)}function Mi(Q,et){gi[et]=setTimeout(function(){return Q.isAlive&&Q.element.classList.remove(xr.state.scrolling(et))},Q.settings.scrollingThreshold)}var Qr=function(et){this.element=et,this.handlers={}},Pr={isEmpty:{configurable:!0}};Qr.prototype.bind=function(et,te){typeof this.handlers[et]>"u"&&(this.handlers[et]=[]),this.handlers[et].push(te),this.element.addEventListener(et,te,!1)},Qr.prototype.unbind=function(et,te){var ot=this;this.handlers[et]=this.handlers[et].filter(function(Ct){return!(!te||Ct===te)||(ot.element.removeEventListener(et,Ct,!1),!1)})},Qr.prototype.unbindAll=function(){for(var et in this.handlers)this.unbind(et)},Pr.isEmpty.get=function(){var Q=this;return Object.keys(this.handlers).every(function(et){return 0===Q.handlers[et].length})},Object.defineProperties(Qr.prototype,Pr);var Do=function(){this.eventElements=[]};function es(Q){if("function"==typeof window.CustomEvent)return new CustomEvent(Q);var et=document.createEvent("CustomEvent");return et.initCustomEvent(Q,!1,!1,void 0),et}function zs(Q,et,te,ot,Ct){var Bn;if(void 0===ot&&(ot=!0),void 0===Ct&&(Ct=!1),"top"===et)Bn=["contentHeight","containerHeight","scrollTop","y","up","down"];else{if("left"!==et)throw new Error("A proper axis should be provided");Bn=["contentWidth","containerWidth","scrollLeft","x","left","right"]}!function sa(Q,et,te,ot,Ct){var Bn=te[0],On=te[1],Wn=te[2],Qn=te[3],qr=te[4],zi=te[5];void 0===ot&&(ot=!0),void 0===Ct&&(Ct=!1);var Mr=Q.element;Q.reach[Qn]=null,Mr[Wn]<1&&(Q.reach[Qn]="start"),Mr[Wn]>Q[Bn]-Q[On]-1&&(Q.reach[Qn]="end"),et&&(Mr.dispatchEvent(es("ps-scroll-"+Qn)),et<0?Mr.dispatchEvent(es("ps-scroll-"+qr)):et>0&&Mr.dispatchEvent(es("ps-scroll-"+zi)),ot&&function Or(Q,et){ni(Q,et),Mi(Q,et)}(Q,Qn)),Q.reach[Qn]&&(et||Ct)&&Mr.dispatchEvent(es("ps-"+Qn+"-reach-"+Q.reach[Qn]))}(Q,te,Bn,ot,Ct)}function Li(Q){return parseInt(Q,10)||0}Do.prototype.eventElement=function(et){var te=this.eventElements.filter(function(ot){return ot.element===et})[0];return te||(te=new Qr(et),this.eventElements.push(te)),te},Do.prototype.bind=function(et,te,ot){this.eventElement(et).bind(te,ot)},Do.prototype.unbind=function(et,te,ot){var Ct=this.eventElement(et);Ct.unbind(te,ot),Ct.isEmpty&&this.eventElements.splice(this.eventElements.indexOf(Ct),1)},Do.prototype.unbindAll=function(){this.eventElements.forEach(function(et){return et.unbindAll()}),this.eventElements=[]},Do.prototype.once=function(et,te,ot){var Ct=this.eventElement(et),Bn=function(On){Ct.unbind(te,Bn),ot(On)};Ct.bind(te,Bn)};var Ks={isWebKit:typeof document<"u"&&"WebkitAppearance"in document.documentElement.style,supportsTouch:typeof window<"u"&&("ontouchstart"in window||"maxTouchPoints"in window.navigator&&window.navigator.maxTouchPoints>0||window.DocumentTouch&&document instanceof window.DocumentTouch),supportsIePointer:typeof navigator<"u"&&navigator.msMaxTouchPoints,isChrome:typeof navigator<"u"&&/Chrome/i.test(navigator&&navigator.userAgent)};function Oo(Q){var et=Q.element,te=Math.floor(et.scrollTop),ot=et.getBoundingClientRect();Q.containerWidth=Math.floor(ot.width),Q.containerHeight=Math.floor(ot.height),Q.contentWidth=et.scrollWidth,Q.contentHeight=et.scrollHeight,et.contains(Q.scrollbarXRail)||(wr(et,xr.element.rail("x")).forEach(function(Ct){return ar(Ct)}),et.appendChild(Q.scrollbarXRail)),et.contains(Q.scrollbarYRail)||(wr(et,xr.element.rail("y")).forEach(function(Ct){return ar(Ct)}),et.appendChild(Q.scrollbarYRail)),!Q.settings.suppressScrollX&&Q.containerWidth+Q.settings.scrollXMarginOffset=Q.railXWidth-Q.scrollbarXWidth&&(Q.scrollbarXLeft=Q.railXWidth-Q.scrollbarXWidth),Q.scrollbarYTop>=Q.railYHeight-Q.scrollbarYHeight&&(Q.scrollbarYTop=Q.railYHeight-Q.scrollbarYHeight),function No(Q,et){var te={width:et.railXWidth},ot=Math.floor(Q.scrollTop);te.left=et.isRtl?et.negativeScrollAdjustment+Q.scrollLeft+et.containerWidth-et.contentWidth:Q.scrollLeft,et.isScrollbarXUsingBottom?te.bottom=et.scrollbarXBottom-ot:te.top=et.scrollbarXTop+ot,Cn(et.scrollbarXRail,te);var Ct={top:ot,height:et.railYHeight};et.isScrollbarYUsingRight?Ct.right=et.isRtl?et.contentWidth-(et.negativeScrollAdjustment+Q.scrollLeft)-et.scrollbarYRight-et.scrollbarYOuterWidth-9:et.scrollbarYRight-Q.scrollLeft:Ct.left=et.isRtl?et.negativeScrollAdjustment+Q.scrollLeft+2*et.containerWidth-et.contentWidth-et.scrollbarYLeft-et.scrollbarYOuterWidth:et.scrollbarYLeft+Q.scrollLeft,Cn(et.scrollbarYRail,Ct),Cn(et.scrollbarX,{left:et.scrollbarXLeft,width:et.scrollbarXWidth-et.railBorderXWidth}),Cn(et.scrollbarY,{top:et.scrollbarYTop,height:et.scrollbarYHeight-et.railBorderYWidth})}(et,Q),Q.scrollbarXActive?et.classList.add(xr.state.active("x")):(et.classList.remove(xr.state.active("x")),Q.scrollbarXWidth=0,Q.scrollbarXLeft=0,et.scrollLeft=!0===Q.isRtl?Q.contentWidth:0),Q.scrollbarYActive?et.classList.add(xr.state.active("y")):(et.classList.remove(xr.state.active("y")),Q.scrollbarYHeight=0,Q.scrollbarYTop=0,et.scrollTop=0)}function Cs(Q,et){return Q.settings.minScrollbarLength&&(et=Math.max(et,Q.settings.minScrollbarLength)),Q.settings.maxScrollbarLength&&(et=Math.min(et,Q.settings.maxScrollbarLength)),et}var Ko=null;function Go(Q,et){var te=et[0],ot=et[1],Ct=et[2],Bn=et[3],On=et[4],Wn=et[5],Qn=et[6],qr=et[7],zi=et[8],Mr=Q.element,fi=null,zr=null,di=null;function Fi(Ho){Ho.touches&&Ho.touches[0]&&(Ho[Ct]=Ho.touches[0]["page"+qr.toUpperCase()]),Ko===On&&(Mr[Qn]=fi+di*(Ho[Ct]-zr),ni(Q,qr),Oo(Q),Ho.stopPropagation(),Ho.preventDefault())}function Ro(){Mi(Q,qr),Q[zi].classList.remove(xr.state.clicking),document.removeEventListener("mousemove",Fi),document.removeEventListener("mouseup",Ro),document.removeEventListener("touchmove",Fi),document.removeEventListener("touchend",Ro),Ko=null}function jo(Ho){null===Ko&&(Ko=On,fi=Mr[Qn],Ho.touches&&(Ho[Ct]=Ho.touches[0]["page"+qr.toUpperCase()]),zr=Ho[Ct],di=(Q[ot]-Q[te])/(Q[Bn]-Q[Wn]),Ho.touches?(document.addEventListener("touchmove",Fi,{passive:!1}),document.addEventListener("touchend",Ro)):(document.addEventListener("mousemove",Fi),document.addEventListener("mouseup",Ro)),Q[zi].classList.add(xr.state.clicking)),Ho.stopPropagation(),Ho.cancelable&&Ho.preventDefault()}Q[On].addEventListener("mousedown",jo),Q[On].addEventListener("touchstart",jo)}var io={"click-rail":function hs(Q){Q.event.bind(Q.scrollbarY,"mousedown",function(et){return et.stopPropagation()}),Q.event.bind(Q.scrollbarYRail,"mousedown",function(et){var te=et.pageY-window.pageYOffset-Q.scrollbarYRail.getBoundingClientRect().top;Q.element.scrollTop+=(te>Q.scrollbarYTop?1:-1)*Q.containerHeight,Oo(Q),et.stopPropagation()}),Q.event.bind(Q.scrollbarX,"mousedown",function(et){return et.stopPropagation()}),Q.event.bind(Q.scrollbarXRail,"mousedown",function(et){var te=et.pageX-window.pageXOffset-Q.scrollbarXRail.getBoundingClientRect().left;Q.element.scrollLeft+=(te>Q.scrollbarXLeft?1:-1)*Q.containerWidth,Oo(Q),et.stopPropagation()})},"drag-thumb":function mo(Q){Go(Q,["containerHeight","contentHeight","pageY","railYHeight","scrollbarY","scrollbarYHeight","scrollTop","y","scrollbarYRail"]),Go(Q,["containerWidth","contentWidth","pageX","railXWidth","scrollbarX","scrollbarXWidth","scrollLeft","x","scrollbarXRail"])},keyboard:function Rs(Q){var et=Q.element;Q.event.bind(Q.ownerDocument,"keydown",function(Bn){if(!(Bn.isDefaultPrevented&&Bn.isDefaultPrevented()||Bn.defaultPrevented)&&(Jn(et,":hover")||Jn(Q.scrollbarX,":focus")||Jn(Q.scrollbarY,":focus"))){var On=document.activeElement?document.activeElement:Q.ownerDocument.activeElement;if(On){if("IFRAME"===On.tagName)On=On.contentDocument.activeElement;else for(;On.shadowRoot;)On=On.shadowRoot.activeElement;if(function bi(Q){return Jn(Q,"input,[contenteditable]")||Jn(Q,"select,[contenteditable]")||Jn(Q,"textarea,[contenteditable]")||Jn(Q,"button,[contenteditable]")}(On))return}var Wn=0,Qn=0;switch(Bn.which){case 37:Wn=Bn.metaKey?-Q.contentWidth:Bn.altKey?-Q.containerWidth:-30;break;case 38:Qn=Bn.metaKey?Q.contentHeight:Bn.altKey?Q.containerHeight:30;break;case 39:Wn=Bn.metaKey?Q.contentWidth:Bn.altKey?Q.containerWidth:30;break;case 40:Qn=Bn.metaKey?-Q.contentHeight:Bn.altKey?-Q.containerHeight:-30;break;case 32:Qn=Bn.shiftKey?Q.containerHeight:-Q.containerHeight;break;case 33:Qn=Q.containerHeight;break;case 34:Qn=-Q.containerHeight;break;case 36:Qn=Q.contentHeight;break;case 35:Qn=-Q.contentHeight;break;default:return}Q.settings.suppressScrollX&&0!==Wn||Q.settings.suppressScrollY&&0!==Qn||(et.scrollTop-=Qn,et.scrollLeft+=Wn,Oo(Q),function Ct(Bn,On){var Wn=Math.floor(et.scrollTop);if(0===Bn){if(!Q.scrollbarYActive)return!1;if(0===Wn&&On>0||Wn>=Q.contentHeight-Q.containerHeight&&On<0)return!Q.settings.wheelPropagation}var Qn=et.scrollLeft;if(0===On){if(!Q.scrollbarXActive)return!1;if(0===Qn&&Bn<0||Qn>=Q.contentWidth-Q.containerWidth&&Bn>0)return!Q.settings.wheelPropagation}return!0}(Wn,Qn)&&Bn.preventDefault())}})},wheel:function Xr(Q){var et=Q.element;function Bn(On){var Wn=function ot(On){var Wn=On.deltaX,Qn=-1*On.deltaY;return(typeof Wn>"u"||typeof Qn>"u")&&(Wn=-1*On.wheelDeltaX/6,Qn=On.wheelDeltaY/6),On.deltaMode&&1===On.deltaMode&&(Wn*=10,Qn*=10),Wn!=Wn&&Qn!=Qn&&(Wn=0,Qn=On.wheelDelta),On.shiftKey?[-Qn,-Wn]:[Wn,Qn]}(On),Qn=Wn[0],qr=Wn[1];if(!function Ct(On,Wn,Qn){if(!Ks.isWebKit&&et.querySelector("select:focus"))return!0;if(!et.contains(On))return!1;for(var qr=On;qr&&qr!==et;){if(qr.classList.contains(xr.element.consuming))return!0;var zi=Dn(qr);if(Qn&&zi.overflowY.match(/(scroll|auto)/)){var Mr=qr.scrollHeight-qr.clientHeight;if(Mr>0&&(qr.scrollTop>0&&Qn<0||qr.scrollTop0))return!0}if(Wn&&zi.overflowX.match(/(scroll|auto)/)){var fi=qr.scrollWidth-qr.clientWidth;if(fi>0&&(qr.scrollLeft>0&&Wn<0||qr.scrollLeft0))return!0}qr=qr.parentNode}return!1}(On.target,Qn,qr)){var zi=!1;Q.settings.useBothWheelAxes?Q.scrollbarYActive&&!Q.scrollbarXActive?(qr?et.scrollTop-=qr*Q.settings.wheelSpeed:et.scrollTop+=Qn*Q.settings.wheelSpeed,zi=!0):Q.scrollbarXActive&&!Q.scrollbarYActive&&(Qn?et.scrollLeft+=Qn*Q.settings.wheelSpeed:et.scrollLeft-=qr*Q.settings.wheelSpeed,zi=!0):(et.scrollTop-=qr*Q.settings.wheelSpeed,et.scrollLeft+=Qn*Q.settings.wheelSpeed),Oo(Q),zi=zi||function te(On,Wn){var Qn=Math.floor(et.scrollTop),qr=0===et.scrollTop,zi=Qn+et.offsetHeight===et.scrollHeight,Mr=0===et.scrollLeft,fi=et.scrollLeft+et.offsetWidth===et.scrollWidth;return!(Math.abs(Wn)>Math.abs(On)?qr||zi:Mr||fi)||!Q.settings.wheelPropagation}(Qn,qr),zi&&!On.ctrlKey&&(On.stopPropagation(),On.preventDefault())}}typeof window.onwheel<"u"?Q.event.bind(et,"wheel",Bn):typeof window.onmousewheel<"u"&&Q.event.bind(et,"mousewheel",Bn)},touch:function Ds(Q){if(Ks.supportsTouch||Ks.supportsIePointer){var et=Q.element,te={startOffset:{},startTime:0,speed:{},easingLoop:null};Ks.supportsTouch?(Q.event.bind(et,"touchstart",Wn),Q.event.bind(et,"touchmove",qr),Q.event.bind(et,"touchend",zi)):Ks.supportsIePointer&&(window.PointerEvent?(Q.event.bind(et,"pointerdown",Wn),Q.event.bind(et,"pointermove",qr),Q.event.bind(et,"pointerup",zi)):window.MSPointerEvent&&(Q.event.bind(et,"MSPointerDown",Wn),Q.event.bind(et,"MSPointerMove",qr),Q.event.bind(et,"MSPointerUp",zi)))}function Ct(Mr,fi){et.scrollTop-=fi,et.scrollLeft-=Mr,Oo(Q)}function Bn(Mr){return Mr.targetTouches?Mr.targetTouches[0]:Mr}function On(Mr){return!(Mr.target===Q.scrollbarX||Mr.target===Q.scrollbarY||Mr.pointerType&&"pen"===Mr.pointerType&&0===Mr.buttons||!(Mr.targetTouches&&1===Mr.targetTouches.length||Mr.pointerType&&"mouse"!==Mr.pointerType&&Mr.pointerType!==Mr.MSPOINTER_TYPE_MOUSE))}function Wn(Mr){if(On(Mr)){var fi=Bn(Mr);te.startOffset.pageX=fi.pageX,te.startOffset.pageY=fi.pageY,te.startTime=(new Date).getTime(),null!==te.easingLoop&&clearInterval(te.easingLoop)}}function qr(Mr){if(On(Mr)){var fi=Bn(Mr),zr={pageX:fi.pageX,pageY:fi.pageY},di=zr.pageX-te.startOffset.pageX,Fi=zr.pageY-te.startOffset.pageY;if(function Qn(Mr,fi,zr){if(!et.contains(Mr))return!1;for(var di=Mr;di&&di!==et;){if(di.classList.contains(xr.element.consuming))return!0;var Fi=Dn(di);if(zr&&Fi.overflowY.match(/(scroll|auto)/)){var Ro=di.scrollHeight-di.clientHeight;if(Ro>0&&(di.scrollTop>0&&zr<0||di.scrollTop0))return!0}if(fi&&Fi.overflowX.match(/(scroll|auto)/)){var jo=di.scrollWidth-di.clientWidth;if(jo>0&&(di.scrollLeft>0&&fi<0||di.scrollLeft0))return!0}di=di.parentNode}return!1}(Mr.target,di,Fi))return;Ct(di,Fi),te.startOffset=zr;var Ro=(new Date).getTime(),jo=Ro-te.startTime;jo>0&&(te.speed.x=di/jo,te.speed.y=Fi/jo,te.startTime=Ro),function ot(Mr,fi){var zr=Math.floor(et.scrollTop),di=et.scrollLeft,Fi=Math.abs(Mr),Ro=Math.abs(fi);if(Ro>Fi){if(fi<0&&zr===Q.contentHeight-Q.containerHeight||fi>0&&0===zr)return 0===window.scrollY&&fi>0&&Ks.isChrome}else if(Fi>Ro&&(Mr<0&&di===Q.contentWidth-Q.containerWidth||Mr>0&&0===di))return!0;return!0}(di,Fi)&&Mr.cancelable&&Mr.preventDefault()}}function zi(){Q.settings.swipeEasing&&(clearInterval(te.easingLoop),te.easingLoop=setInterval(function(){Q.isInitialized?clearInterval(te.easingLoop):te.speed.x||te.speed.y?Math.abs(te.speed.x)<.01&&Math.abs(te.speed.y)<.01?clearInterval(te.easingLoop):(Ct(30*te.speed.x,30*te.speed.y),te.speed.x*=.8,te.speed.y*=.8):clearInterval(te.easingLoop)},10))}}},fs=function(et,te){var ot=this;if(void 0===te&&(te={}),"string"==typeof et&&(et=document.querySelector(et)),!et||!et.nodeName)throw new Error("no element is specified to initialize PerfectScrollbar");for(var Ct in this.element=et,et.classList.add(xr.main),this.settings={handlers:["click-rail","drag-thumb","keyboard","wheel","touch"],maxScrollbarLength:null,minScrollbarLength:null,scrollingThreshold:1e3,scrollXMarginOffset:0,scrollYMarginOffset:0,suppressScrollX:!1,suppressScrollY:!1,swipeEasing:!0,useBothWheelAxes:!1,wheelPropagation:!0,wheelSpeed:1},te)this.settings[Ct]=te[Ct];this.containerWidth=null,this.containerHeight=null,this.contentWidth=null,this.contentHeight=null;var zi,qr,Bn=function(){return et.classList.add(xr.state.focus)},On=function(){return et.classList.remove(xr.state.focus)};this.isRtl="rtl"===Dn(et).direction,!0===this.isRtl&&et.classList.add(xr.rtl),this.isNegativeScroll=(qr=et.scrollLeft,et.scrollLeft=-1,zi=et.scrollLeft<0,et.scrollLeft=qr,zi),this.negativeScrollAdjustment=this.isNegativeScroll?et.scrollWidth-et.clientWidth:0,this.event=new Do,this.ownerDocument=et.ownerDocument||document,this.scrollbarXRail=Nn(xr.element.rail("x")),et.appendChild(this.scrollbarXRail),this.scrollbarX=Nn(xr.element.thumb("x")),this.scrollbarXRail.appendChild(this.scrollbarX),this.scrollbarX.setAttribute("tabindex",0),this.event.bind(this.scrollbarX,"focus",Bn),this.event.bind(this.scrollbarX,"blur",On),this.scrollbarXActive=null,this.scrollbarXWidth=null,this.scrollbarXLeft=null;var Wn=Dn(this.scrollbarXRail);this.scrollbarXBottom=parseInt(Wn.bottom,10),isNaN(this.scrollbarXBottom)?(this.isScrollbarXUsingBottom=!1,this.scrollbarXTop=Li(Wn.top)):this.isScrollbarXUsingBottom=!0,this.railBorderXWidth=Li(Wn.borderLeftWidth)+Li(Wn.borderRightWidth),Cn(this.scrollbarXRail,{display:"block"}),this.railXMarginWidth=Li(Wn.marginLeft)+Li(Wn.marginRight),Cn(this.scrollbarXRail,{display:""}),this.railXWidth=null,this.railXRatio=null,this.scrollbarYRail=Nn(xr.element.rail("y")),et.appendChild(this.scrollbarYRail),this.scrollbarY=Nn(xr.element.thumb("y")),this.scrollbarYRail.appendChild(this.scrollbarY),this.scrollbarY.setAttribute("tabindex",0),this.event.bind(this.scrollbarY,"focus",Bn),this.event.bind(this.scrollbarY,"blur",On),this.scrollbarYActive=null,this.scrollbarYHeight=null,this.scrollbarYTop=null;var Qn=Dn(this.scrollbarYRail);this.scrollbarYRight=parseInt(Qn.right,10),isNaN(this.scrollbarYRight)?(this.isScrollbarYUsingRight=!1,this.scrollbarYLeft=Li(Qn.left)):this.isScrollbarYUsingRight=!0,this.scrollbarYOuterWidth=this.isRtl?function aa(Q){var et=Dn(Q);return Li(et.width)+Li(et.paddingLeft)+Li(et.paddingRight)+Li(et.borderLeftWidth)+Li(et.borderRightWidth)}(this.scrollbarY):null,this.railBorderYWidth=Li(Qn.borderTopWidth)+Li(Qn.borderBottomWidth),Cn(this.scrollbarYRail,{display:"block"}),this.railYMarginHeight=Li(Qn.marginTop)+Li(Qn.marginBottom),Cn(this.scrollbarYRail,{display:""}),this.railYHeight=null,this.railYRatio=null,this.reach={x:et.scrollLeft<=0?"start":et.scrollLeft>=this.contentWidth-this.containerWidth?"end":null,y:et.scrollTop<=0?"start":et.scrollTop>=this.contentHeight-this.containerHeight?"end":null},this.isAlive=!0,this.settings.handlers.forEach(function(qr){return io[qr](ot)}),this.lastScrollTop=Math.floor(et.scrollTop),this.lastScrollLeft=et.scrollLeft,this.event.bind(this.element,"scroll",function(qr){return ot.onScroll(qr)}),Oo(this)};fs.prototype.update=function(){this.isAlive&&(this.negativeScrollAdjustment=this.isNegativeScroll?this.element.scrollWidth-this.element.clientWidth:0,Cn(this.scrollbarXRail,{display:"block"}),Cn(this.scrollbarYRail,{display:"block"}),this.railXMarginWidth=Li(Dn(this.scrollbarXRail).marginLeft)+Li(Dn(this.scrollbarXRail).marginRight),this.railYMarginHeight=Li(Dn(this.scrollbarYRail).marginTop)+Li(Dn(this.scrollbarYRail).marginBottom),Cn(this.scrollbarXRail,{display:"none"}),Cn(this.scrollbarYRail,{display:"none"}),Oo(this),zs(this,"top",0,!1,!0),zs(this,"left",0,!1,!0),Cn(this.scrollbarXRail,{display:""}),Cn(this.scrollbarYRail,{display:""}))},fs.prototype.onScroll=function(et){this.isAlive&&(Oo(this),zs(this,"top",this.element.scrollTop-this.lastScrollTop),zs(this,"left",this.element.scrollLeft-this.lastScrollLeft),this.lastScrollTop=Math.floor(this.element.scrollTop),this.lastScrollLeft=this.element.scrollLeft)},fs.prototype.destroy=function(){this.isAlive&&(this.event.unbindAll(),ar(this.scrollbarX),ar(this.scrollbarY),ar(this.scrollbarXRail),ar(this.scrollbarYRail),this.removePsClasses(),this.element=null,this.scrollbarX=null,this.scrollbarY=null,this.scrollbarXRail=null,this.scrollbarYRail=null,this.isAlive=!1)},fs.prototype.removePsClasses=function(){this.element.className=this.element.className.split(" ").filter(function(et){return!et.match(/^ps([-_].+|)$/)}).join(" ")};const Xo=fs;var Qa=r(909),_o=r(8627);let Ao=(()=>{class Q{constructor(){this._elementRef=(0,a.WQX)(a.aKT),this._platform=(0,a.WQX)(kt.OD),this.angorScrollbar=!0,this._ps=null,this._unsubscribeAll=new C.B}get elementRef(){return this._elementRef}get ps(){return this._ps}ngOnChanges(te){"angorScrollbar"in te&&(this.angorScrollbar=(0,Ht.he)(te.angorScrollbar.currentValue),this.angorScrollbar?this._initScrollbar():this._destroyScrollbar()),"angorScrollbarOptions"in te&&(this._options=(0,hn.A)({},this._options,te.angorScrollbarOptions.currentValue),this._reinitializeScrollbar())}ngOnInit(){(0,Qa.R)(window,"resize").pipe((0,Z.Q)(this._unsubscribeAll),(0,_o.B)(150)).subscribe(()=>this.update())}ngOnDestroy(){this._destroyScrollbar(),this._unsubscribeAll.next(),this._unsubscribeAll.complete()}isEnabled(){return this.angorScrollbar}update(){this._ps?.update()}destroy(){this.ngOnDestroy()}geometry(te="scroll"){return new Ne(this._elementRef.nativeElement[`${te}Left`],this._elementRef.nativeElement[`${te}Top`],this._elementRef.nativeElement[`${te}Width`],this._elementRef.nativeElement[`${te}Height`])}position(te=!1){return!te&&this._ps?new gt(this._ps.reach.x||0,this._ps.reach.y||0):new gt(this._elementRef.nativeElement.scrollLeft,this._elementRef.nativeElement.scrollTop)}scrollTo(te,ot,Ct){null==ot&&null==Ct?this.animateScrolling("scrollTop",te,Ct):(null!=te&&this.scrollToX(te,Ct),null!=ot&&this.scrollToY(ot,Ct))}scrollToX(te,ot){this.animateScrolling("scrollLeft",te,ot)}scrollToY(te,ot){this.animateScrolling("scrollTop",te,ot)}scrollToTop(te=0,ot){this.animateScrolling("scrollTop",te,ot)}scrollToBottom(te=0,ot){this.animateScrolling("scrollTop",this._elementRef.nativeElement.scrollHeight-this._elementRef.nativeElement.clientHeight-te,ot)}scrollToLeft(te=0,ot){this.animateScrolling("scrollLeft",te,ot)}scrollToRight(te=0,ot){this.animateScrolling("scrollLeft",this._elementRef.nativeElement.scrollWidth-this._elementRef.nativeElement.clientWidth-te,ot)}scrollToElement(te,ot=0,Ct=!1,Bn){const On=this._elementRef.nativeElement.querySelector(te);if(!On)return;const Wn=On.getBoundingClientRect(),Qn=this._elementRef.nativeElement.getBoundingClientRect();this._elementRef.nativeElement.classList.contains("ps--active-x")&&this._scrollToInAxis(Wn.left,Qn.left,"scrollLeft",ot,Ct,Bn),this._elementRef.nativeElement.classList.contains("ps--active-y")&&this._scrollToInAxis(Wn.top,Qn.top,"scrollTop",ot,Ct,Bn)}animateScrolling(te,ot,Ct){this._animation&&window.cancelAnimationFrame(this._animation),!Ct||typeof window>"u"?this._elementRef.nativeElement[te]=ot:ot!==this._elementRef.nativeElement[te]&&this._smoothScroll(te,ot,Ct)}_initScrollbar(){this._ps||this._platform.ANDROID||this._platform.IOS||!this._platform.isBrowser||(this._ps=new Xo(this._elementRef.nativeElement,{...this._options}))}_destroyScrollbar(){this._ps?.destroy(),this._ps=null}_reinitializeScrollbar(){setTimeout(()=>this._destroyScrollbar()),setTimeout(()=>this._initScrollbar())}_scrollToInAxis(te,ot,Ct,Bn,On,Wn){On&&te<=ot-Math.abs(Bn)||this.animateScrolling(Ct,te-ot+this._elementRef.nativeElement[Ct]+Bn,Wn)}_smoothScroll(te,ot,Ct){let Bn=0,On=this._elementRef.nativeElement[te];const Wn=(On-ot)/2;let Qn=performance.now();const qr=zi=>{Bn+=Math.PI/(Ct/(zi-Qn));const Mr=Math.round(ot+Wn+Wn*Math.cos(Bn));this._elementRef.nativeElement[te]===On&&(Bn>=Math.PI?this.animateScrolling(te,ot,0):(this._elementRef.nativeElement[te]=Mr,On=this._elementRef.nativeElement[te],Qn=zi,this._animation=window.requestAnimationFrame(qr)))};window.requestAnimationFrame(qr)}static{this.\u0275fac=function(ot){return new(ot||Q)}}static{this.\u0275dir=a.FsC({type:Q,selectors:[["","angorScrollbar",""]],inputs:{angorScrollbar:"angorScrollbar",angorScrollbarOptions:"angorScrollbarOptions"},exportAs:["angorScrollbar"],features:[a.OA$]})}}return Q})();var lr=r(1204),As=r(9666),Gs=r(7509),_s=r(8136);const la=["navigationContent"],ls=[[["","angorVerticalNavigationHeader",""]],[["","angorVerticalNavigationContentHeader",""]],[["","angorVerticalNavigationFooter",""]]],Vi=["[angorVerticalNavigationHeader]","[angorVerticalNavigationContentHeader]","[angorVerticalNavigationFooter]"],ll=Q=>({wheelPropagation:Q,suppressScrollX:!0}),ca=()=>({wheelPropagation:!1,suppressScrollX:!0});function Ss(Q,et){if(1&Q){const te=a.RV6();a.j41(0,"angor-vertical-navigation-aside-item",10),a.bIt("click",function(){a.eBV(te);const Ct=a.XpG(2).$implicit,Bn=a.XpG();return a.Njj(Bn.toggleAside(Ct))}),a.k0s()}if(2&Q){const te=a.XpG(2).$implicit,ot=a.XpG();a.Y8G("item",te)("name",ot.name)("activeItemId",ot.activeAsideItemId)("autoCollapse",ot.autoCollapse)("skipChildren",!0)}}function Ts(Q,et){if(1&Q&&a.nrm(0,"angor-vertical-navigation-basic-item",8),2&Q){const te=a.XpG(2).$implicit,ot=a.XpG();a.Y8G("item",te)("name",ot.name)}}function Ns(Q,et){if(1&Q&&a.nrm(0,"angor-vertical-navigation-collapsable-item",9),2&Q){const te=a.XpG(2).$implicit,ot=a.XpG();a.Y8G("item",te)("name",ot.name)("autoCollapse",ot.autoCollapse)}}function So(Q,et){if(1&Q&&a.nrm(0,"angor-vertical-navigation-divider-item",8),2&Q){const te=a.XpG(2).$implicit,ot=a.XpG();a.Y8G("item",te)("name",ot.name)}}function Bo(Q,et){if(1&Q&&a.nrm(0,"angor-vertical-navigation-group-item",9),2&Q){const te=a.XpG(2).$implicit,ot=a.XpG();a.Y8G("item",te)("name",ot.name)("autoCollapse",ot.autoCollapse)}}function lo(Q,et){if(1&Q&&a.nrm(0,"angor-vertical-navigation-spacer-item",8),2&Q){const te=a.XpG(2).$implicit,ot=a.XpG();a.Y8G("item",te)("name",ot.name)}}function ps(Q,et){if(1&Q&&a.DNE(0,Ss,1,5,"angor-vertical-navigation-aside-item",7)(1,Ts,1,2,"angor-vertical-navigation-basic-item",8)(2,Ns,1,3,"angor-vertical-navigation-collapsable-item",9)(3,So,1,2,"angor-vertical-navigation-divider-item",8)(4,Bo,1,3,"angor-vertical-navigation-group-item",9)(5,lo,1,2,"angor-vertical-navigation-spacer-item",8),2&Q){const te=a.XpG().$implicit;a.vxM("aside"===te.type?0:-1),a.R7$(),a.vxM("basic"===te.type?1:-1),a.R7$(),a.vxM("collapsable"===te.type?2:-1),a.R7$(),a.vxM("divider"===te.type?3:-1),a.R7$(),a.vxM("group"===te.type?4:-1),a.R7$(),a.vxM("spacer"===te.type?5:-1)}}function Da(Q,et){if(1&Q&&a.DNE(0,ps,6,6),2&Q){const te=et.$implicit;a.vxM(te.hidden&&!te.hidden(te)||!te.hidden?0:-1)}}function Ms(Q,et){if(1&Q&&a.nrm(0,"angor-vertical-navigation-aside-item",9),2&Q){const te=a.XpG(2).$implicit,ot=a.XpG(2);a.Y8G("item",te)("name",ot.name)("autoCollapse",ot.autoCollapse)}}function Us(Q,et){if(1&Q&&a.DNE(0,Ms,1,3,"angor-vertical-navigation-aside-item",9),2&Q){const te=a.XpG().$implicit,ot=a.XpG(2);a.vxM("aside"===te.type&&te.id===ot.activeAsideItemId?0:-1)}}function ua(Q,et){if(1&Q&&a.DNE(0,Us,1,1),2&Q){const te=et.$implicit;a.vxM(te.hidden&&!te.hidden(te)||!te.hidden?0:-1)}}function Ba(Q,et){if(1&Q&&(a.j41(0,"div",6),a.Z7z(1,ua,1,1,null,null,a.BUC().trackByFn,!0),a.k0s()),2&Q){const te=a.XpG();a.Y8G("angorScrollbarOptions",a.lJ4(5,ca))("@fadeInLeft","left"===te.position)("@fadeInRight","right"===te.position)("@fadeOutLeft","left"===te.position)("@fadeOutRight","right"===te.position),a.R7$(),a.Dyx(te.navigation)}}let Aa=(()=>{class Q{constructor(){this._animationBuilder=(0,a.WQX)(lr.S6),this._changeDetectorRef=(0,a.WQX)(a.gRc),this._document=(0,a.WQX)(T.qQ),this._elementRef=(0,a.WQX)(a.aKT),this._renderer2=(0,a.WQX)(a.sFG),this._router=(0,a.WQX)(L.Ix),this._scrollStrategyOptions=(0,a.WQX)(As.Tv),this._angorNavigationService=(0,a.WQX)(c),this._angorUtilsService=(0,a.WQX)(y.Q),this.appearance="default",this.autoCollapse=!0,this.inner=!1,this.mode="side",this.name=this._angorUtilsService.randomId(),this.opened=!0,this.position="left",this.transparentOverlay=!1,this.appearanceChanged=new a.bkB,this.modeChanged=new a.bkB,this.openedChanged=new a.bkB,this.positionChanged=new a.bkB,this.activeAsideItemId=null,this.onCollapsableItemCollapsed=new w.m(1),this.onCollapsableItemExpanded=new w.m(1),this.onRefreshed=new w.m(1),this._animationsEnabled=!1,this._hovered=!1,this._scrollStrategy=this._scrollStrategyOptions.block(),this._unsubscribeAll=new C.B,this._handleAsideOverlayClick=()=>{this.closeAside()},this._handleOverlayClick=()=>{this.close()}}get classList(){return{"angor-vertical-navigation-animations-enabled":this._animationsEnabled,[`angor-vertical-navigation-appearance-${this.appearance}`]:!0,"angor-vertical-navigation-hover":this._hovered,"angor-vertical-navigation-inner":this.inner,"angor-vertical-navigation-mode-over":"over"===this.mode,"angor-vertical-navigation-mode-side":"side"===this.mode,"angor-vertical-navigation-opened":this.opened,"angor-vertical-navigation-position-left":"left"===this.position,"angor-vertical-navigation-position-right":"right"===this.position}}get styleList(){return{visibility:this.opened?"visible":"hidden"}}set angorScrollbarDirectives(te){this._angorScrollbarDirectives=te,0!==te.length&&(this._angorScrollbarDirectivesSubscription&&this._angorScrollbarDirectivesSubscription.unsubscribe(),this._angorScrollbarDirectivesSubscription=(0,Gs.h)(this.onCollapsableItemCollapsed,this.onCollapsableItemExpanded).pipe((0,Z.Q)(this._unsubscribeAll),(0,_s.c)(250)).subscribe(()=>{te.forEach(ot=>{ot.update()})}))}_onMouseenter(){this._enableAnimations(),this._hovered=!0}_onMouseleave(){this._enableAnimations(),this._hovered=!1}ngOnChanges(te){if("appearance"in te&&this.appearanceChanged.next(te.appearance.currentValue),"inner"in te&&(this.inner=(0,Ht.he)(te.inner.currentValue)),"mode"in te){const ot=te.mode.currentValue,Ct=te.mode.previousValue;this._disableAnimations(),"over"===Ct&&"side"===ot&&this._hideOverlay(),"side"===Ct&&"over"===ot&&(this.closeAside(),this.opened&&this._showOverlay()),this.modeChanged.next(ot),setTimeout(()=>{this._enableAnimations()},500)}"navigation"in te&&this._changeDetectorRef.markForCheck(),"opened"in te&&(this.opened=(0,Ht.he)(te.opened.currentValue),this._toggleOpened(this.opened)),"position"in te&&this.positionChanged.next(te.position.currentValue),"transparentOverlay"in te&&(this.transparentOverlay=(0,Ht.he)(te.transparentOverlay.currentValue))}ngOnInit(){""===this.name&&(this.name=this._angorUtilsService.randomId()),this._angorNavigationService.registerComponent(this.name,this),this._router.events.pipe((0,Zi.p)(te=>te instanceof L.wF),(0,Z.Q)(this._unsubscribeAll)).subscribe(()=>{"over"===this.mode&&this.opened&&this.close(),"side"===this.mode&&this.activeAsideItemId&&this.closeAside()})}ngAfterViewInit(){this._mutationObserver=new MutationObserver(te=>{te.forEach(ot=>{const Ct=ot.target;if("class"===ot.attributeName)if(Ct.classList.contains("cdk-global-scrollblock")){const Bn=parseInt(Ct.style.top,10);this._renderer2.setStyle(this._elementRef.nativeElement,"margin-top",`${Math.abs(Bn)}px`)}else this._renderer2.setStyle(this._elementRef.nativeElement,"margin-top",null)})}),this._mutationObserver.observe(this._document.documentElement,{attributes:!0,attributeFilter:["class"]}),setTimeout(()=>{if(this._navigationContentEl)if(this._navigationContentEl.nativeElement.classList.contains("ps"))this._angorScrollbarDirectives.forEach(te=>{te.isEnabled()&&te.scrollToElement(".angor-vertical-navigation-item-active",-120,!0)});else{const te=this._navigationContentEl.nativeElement.querySelector(".angor-vertical-navigation-item-active");te&&te.scrollIntoView()}})}ngOnDestroy(){this._mutationObserver.disconnect(),this.close(),this.closeAside(),this._angorNavigationService.deregisterComponent(this.name),this._unsubscribeAll.next(null),this._unsubscribeAll.complete()}refresh(){this._changeDetectorRef.markForCheck(),this.onRefreshed.next(!0)}open(){this.opened||this._toggleOpened(!0)}close(){this.opened&&(this.closeAside(),this._toggleOpened(!1))}toggle(){this.opened?this.close():this.open()}openAside(te){te.disabled||!te.id||(this.activeAsideItemId=te.id,this._showAsideOverlay(),this._changeDetectorRef.markForCheck())}closeAside(){this.activeAsideItemId=null,this._hideAsideOverlay(),this._changeDetectorRef.markForCheck()}toggleAside(te){this.activeAsideItemId===te.id?this.closeAside():this.openAside(te)}trackByFn(te,ot){return ot.id||te}_enableAnimations(){this._animationsEnabled||(this._animationsEnabled=!0)}_disableAnimations(){this._animationsEnabled&&(this._animationsEnabled=!1)}_showOverlay(){this._asideOverlay||(this._overlay=this._renderer2.createElement("div"),this._overlay.classList.add("angor-vertical-navigation-overlay"),this.transparentOverlay&&this._overlay.classList.add("angor-vertical-navigation-overlay-transparent"),this._renderer2.appendChild(this._elementRef.nativeElement.parentElement,this._overlay),this._scrollStrategy.enable(),this._player=this._animationBuilder.build([(0,lr.i0)("300ms cubic-bezier(0.25, 0.8, 0.25, 1)",(0,lr.iF)({opacity:1}))]).create(this._overlay),this._player.play(),this._overlay.addEventListener("click",this._handleOverlayClick))}_hideOverlay(){this._overlay&&(this._player=this._animationBuilder.build([(0,lr.i0)("300ms cubic-bezier(0.25, 0.8, 0.25, 1)",(0,lr.iF)({opacity:0}))]).create(this._overlay),this._player.play(),this._player.onDone(()=>{this._overlay&&(this._overlay.removeEventListener("click",this._handleOverlayClick),this._overlay.parentNode.removeChild(this._overlay),this._overlay=null),this._scrollStrategy.disable()}))}_showAsideOverlay(){this._asideOverlay||(this._asideOverlay=this._renderer2.createElement("div"),this._asideOverlay.classList.add("angor-vertical-navigation-aside-overlay"),this._renderer2.appendChild(this._elementRef.nativeElement.parentElement,this._asideOverlay),this._player=this._animationBuilder.build([(0,lr.i0)("300ms cubic-bezier(0.25, 0.8, 0.25, 1)",(0,lr.iF)({opacity:1}))]).create(this._asideOverlay),this._player.play(),this._asideOverlay.addEventListener("click",this._handleAsideOverlayClick))}_hideAsideOverlay(){this._asideOverlay&&(this._player=this._animationBuilder.build([(0,lr.i0)("300ms cubic-bezier(0.25, 0.8, 0.25, 1)",(0,lr.iF)({opacity:0}))]).create(this._asideOverlay),this._player.play(),this._player.onDone(()=>{this._asideOverlay&&(this._asideOverlay.removeEventListener("click",this._handleAsideOverlayClick),this._asideOverlay.parentNode.removeChild(this._asideOverlay),this._asideOverlay=null)}))}_toggleOpened(te){this.opened=te,this._enableAnimations(),"over"===this.mode&&(this.opened?this._showOverlay():this._hideOverlay()),this.openedChanged.next(te)}static{this.\u0275fac=function(ot){return new(ot||Q)}}static{this.\u0275cmp=a.VBU({type:Q,selectors:[["angor-vertical-navigation"]],viewQuery:function(ot,Ct){if(1&ot&&(a.GBs(la,5),a.GBs(Ao,5)),2&ot){let Bn;a.mGM(Bn=a.lsd())&&(Ct._navigationContentEl=Bn.first),a.mGM(Bn=a.lsd())&&(Ct.angorScrollbarDirectives=Bn)}},hostVars:4,hostBindings:function(ot,Ct){1&ot&&a.bIt("mouseenter",function(){return Ct._onMouseenter()})("mouseleave",function(){return Ct._onMouseleave()}),2&ot&&(a.Aen(Ct.styleList),a.HbH(Ct.classList))},inputs:{appearance:"appearance",autoCollapse:"autoCollapse",inner:"inner",mode:"mode",name:"name",navigation:"navigation",opened:"opened",position:"position",transparentOverlay:"transparentOverlay"},outputs:{appearanceChanged:"appearanceChanged",modeChanged:"modeChanged",openedChanged:"openedChanged",positionChanged:"positionChanged"},exportAs:["angorVerticalNavigation"],features:[a.OA$],ngContentSelectors:Vi,decls:12,vars:4,consts:[["navigationContent",""],[1,"angor-vertical-navigation-wrapper"],[1,"angor-vertical-navigation-header"],["angorScrollbar","",1,"angor-vertical-navigation-content",3,"angorScrollbarOptions"],[1,"angor-vertical-navigation-content-header"],[1,"angor-vertical-navigation-footer"],["angorScrollbar","",1,"angor-vertical-navigation-aside-wrapper",3,"angorScrollbarOptions"],[3,"item","name","activeItemId","autoCollapse","skipChildren"],[3,"item","name"],[3,"item","name","autoCollapse"],[3,"click","item","name","activeItemId","autoCollapse","skipChildren"]],template:function(ot,Ct){1&ot&&(a.NAR(ls),a.j41(0,"div",1)(1,"div",2),a.SdG(2),a.k0s(),a.j41(3,"div",3,0)(5,"div",4),a.SdG(6,1),a.k0s(),a.Z7z(7,Da,1,1,null,null,Ct.trackByFn,!0),a.k0s(),a.j41(9,"div",5),a.SdG(10,2),a.k0s()(),a.DNE(11,Ba,3,6,"div",6)),2&ot&&(a.R7$(3),a.Y8G("angorScrollbarOptions",a.eq3(2,ll,Ct.inner)),a.R7$(4),a.Dyx(Ct.navigation),a.R7$(4),a.vxM(Ct.activeAsideItemId?11:-1))},dependencies:[Ao,Ye,Vr,qo,vt,hi,Wt],styles:[':root{--angor-vertical-navigation-width: 280px}angor-vertical-navigation{position:sticky;display:flex;flex-direction:column;flex:1 0 auto;top:0;width:var(--angor-vertical-navigation-width);min-width:var(--angor-vertical-navigation-width);max-width:var(--angor-vertical-navigation-width);height:100vh;min-height:100vh;max-height:100vh;z-index:200}angor-vertical-navigation.angor-vertical-navigation-animations-enabled{transition-duration:.4s;transition-timing-function:cubic-bezier(.25,.8,.25,1);transition-property:visibility,margin-left,margin-right,transform,width,max-width,min-width}angor-vertical-navigation.angor-vertical-navigation-animations-enabled .angor-vertical-navigation-wrapper{transition-duration:.4s;transition-timing-function:cubic-bezier(.25,.8,.25,1);transition-property:width,max-width,min-width}angor-vertical-navigation.angor-vertical-navigation-mode-over{position:fixed;top:0;bottom:0}angor-vertical-navigation.angor-vertical-navigation-position-left.angor-vertical-navigation-mode-side{margin-left:calc(var(--angor-vertical-navigation-width) * -1)}angor-vertical-navigation.angor-vertical-navigation-position-left.angor-vertical-navigation-mode-side.angor-vertical-navigation-opened{margin-left:0}angor-vertical-navigation.angor-vertical-navigation-position-left.angor-vertical-navigation-mode-over{left:0;transform:translate3d(-100%,0,0)}angor-vertical-navigation.angor-vertical-navigation-position-left.angor-vertical-navigation-mode-over.angor-vertical-navigation-opened{transform:translateZ(0)}angor-vertical-navigation.angor-vertical-navigation-position-left .angor-vertical-navigation-wrapper{left:0}angor-vertical-navigation.angor-vertical-navigation-position-right.angor-vertical-navigation-mode-side{margin-right:calc(var(--angor-vertical-navigation-width) * -1)}angor-vertical-navigation.angor-vertical-navigation-position-right.angor-vertical-navigation-mode-side.angor-vertical-navigation-opened{margin-right:0}angor-vertical-navigation.angor-vertical-navigation-position-right.angor-vertical-navigation-mode-over{right:0;transform:translate3d(100%,0,0)}angor-vertical-navigation.angor-vertical-navigation-position-right.angor-vertical-navigation-mode-over.angor-vertical-navigation-opened{transform:translateZ(0)}angor-vertical-navigation.angor-vertical-navigation-position-right .angor-vertical-navigation-wrapper{right:0}angor-vertical-navigation.angor-vertical-navigation-inner{position:relative;width:auto;min-width:0;max-width:none;height:auto;min-height:0;max-height:none;box-shadow:none}angor-vertical-navigation.angor-vertical-navigation-inner .angor-vertical-navigation-wrapper{position:relative;overflow:visible;height:auto}angor-vertical-navigation.angor-vertical-navigation-inner .angor-vertical-navigation-wrapper .angor-vertical-navigation-content{overflow:visible!important}angor-vertical-navigation .angor-vertical-navigation-wrapper{position:absolute;display:flex;flex:1 1 auto;flex-direction:column;top:0;bottom:0;width:100%;height:100%;overflow:hidden;z-index:10;background:inherit;box-shadow:inset -1px 0 0 var(--angor-border)}angor-vertical-navigation .angor-vertical-navigation-wrapper .angor-vertical-navigation-content{flex:1 1 auto;overflow-x:hidden;overflow-y:auto;overscroll-behavior:contain}angor-vertical-navigation .angor-vertical-navigation-wrapper .angor-vertical-navigation-content>angor-vertical-navigation-divider-item{margin:24px 0}angor-vertical-navigation .angor-vertical-navigation-wrapper .angor-vertical-navigation-content>angor-vertical-navigation-group-item{margin-top:24px}angor-vertical-navigation .angor-vertical-navigation-aside-wrapper{position:absolute;display:flex;flex:1 1 auto;flex-direction:column;top:0;bottom:0;left:var(--angor-vertical-navigation-width);width:var(--angor-vertical-navigation-width);height:100%;z-index:5;overflow-x:hidden;overflow-y:auto;-webkit-overflow-scrolling:touch;transition-duration:.4s;transition-property:left,right;transition-timing-function:cubic-bezier(.25,.8,.25,1);background:inherit}angor-vertical-navigation .angor-vertical-navigation-aside-wrapper>angor-vertical-navigation-aside-item{padding:24px 0}angor-vertical-navigation .angor-vertical-navigation-aside-wrapper>angor-vertical-navigation-aside-item>.angor-vertical-navigation-item-wrapper{display:none!important}angor-vertical-navigation.angor-vertical-navigation-position-right .angor-vertical-navigation-aside-wrapper{left:auto;right:var(--angor-vertical-navigation-width)}angor-vertical-navigation angor-vertical-navigation-aside-item,angor-vertical-navigation angor-vertical-navigation-basic-item,angor-vertical-navigation angor-vertical-navigation-collapsable-item,angor-vertical-navigation angor-vertical-navigation-divider-item,angor-vertical-navigation angor-vertical-navigation-group-item,angor-vertical-navigation angor-vertical-navigation-spacer-item{display:flex;flex-direction:column;flex:1 0 auto;-webkit-user-select:none;user-select:none}angor-vertical-navigation angor-vertical-navigation-aside-item .angor-vertical-navigation-item-wrapper .angor-vertical-navigation-item,angor-vertical-navigation angor-vertical-navigation-basic-item .angor-vertical-navigation-item-wrapper .angor-vertical-navigation-item,angor-vertical-navigation angor-vertical-navigation-collapsable-item .angor-vertical-navigation-item-wrapper .angor-vertical-navigation-item,angor-vertical-navigation angor-vertical-navigation-divider-item .angor-vertical-navigation-item-wrapper .angor-vertical-navigation-item,angor-vertical-navigation angor-vertical-navigation-group-item .angor-vertical-navigation-item-wrapper .angor-vertical-navigation-item,angor-vertical-navigation angor-vertical-navigation-spacer-item .angor-vertical-navigation-item-wrapper .angor-vertical-navigation-item{position:relative;display:flex;align-items:center;justify-content:flex-start;padding:10px 16px;font-size:13px;font-weight:500;line-height:20px;text-decoration:none;border-radius:6px}angor-vertical-navigation angor-vertical-navigation-aside-item .angor-vertical-navigation-item-wrapper .angor-vertical-navigation-item.angor-vertical-navigation-item-disabled,angor-vertical-navigation angor-vertical-navigation-basic-item .angor-vertical-navigation-item-wrapper .angor-vertical-navigation-item.angor-vertical-navigation-item-disabled,angor-vertical-navigation angor-vertical-navigation-collapsable-item .angor-vertical-navigation-item-wrapper .angor-vertical-navigation-item.angor-vertical-navigation-item-disabled,angor-vertical-navigation angor-vertical-navigation-divider-item .angor-vertical-navigation-item-wrapper .angor-vertical-navigation-item.angor-vertical-navigation-item-disabled,angor-vertical-navigation angor-vertical-navigation-group-item .angor-vertical-navigation-item-wrapper .angor-vertical-navigation-item.angor-vertical-navigation-item-disabled,angor-vertical-navigation angor-vertical-navigation-spacer-item .angor-vertical-navigation-item-wrapper .angor-vertical-navigation-item.angor-vertical-navigation-item-disabled{cursor:default;opacity:.4}angor-vertical-navigation angor-vertical-navigation-aside-item .angor-vertical-navigation-item-wrapper .angor-vertical-navigation-item .angor-vertical-navigation-item-icon,angor-vertical-navigation angor-vertical-navigation-basic-item .angor-vertical-navigation-item-wrapper .angor-vertical-navigation-item .angor-vertical-navigation-item-icon,angor-vertical-navigation angor-vertical-navigation-collapsable-item .angor-vertical-navigation-item-wrapper .angor-vertical-navigation-item .angor-vertical-navigation-item-icon,angor-vertical-navigation angor-vertical-navigation-divider-item .angor-vertical-navigation-item-wrapper .angor-vertical-navigation-item .angor-vertical-navigation-item-icon,angor-vertical-navigation angor-vertical-navigation-group-item .angor-vertical-navigation-item-wrapper .angor-vertical-navigation-item .angor-vertical-navigation-item-icon,angor-vertical-navigation angor-vertical-navigation-spacer-item .angor-vertical-navigation-item-wrapper .angor-vertical-navigation-item .angor-vertical-navigation-item-icon{margin-right:16px}angor-vertical-navigation angor-vertical-navigation-aside-item .angor-vertical-navigation-item-wrapper .angor-vertical-navigation-item .angor-vertical-navigation-item-title-wrapper .angor-vertical-navigation-item-subtitle,angor-vertical-navigation angor-vertical-navigation-basic-item .angor-vertical-navigation-item-wrapper .angor-vertical-navigation-item .angor-vertical-navigation-item-title-wrapper .angor-vertical-navigation-item-subtitle,angor-vertical-navigation angor-vertical-navigation-collapsable-item .angor-vertical-navigation-item-wrapper .angor-vertical-navigation-item .angor-vertical-navigation-item-title-wrapper .angor-vertical-navigation-item-subtitle,angor-vertical-navigation angor-vertical-navigation-divider-item .angor-vertical-navigation-item-wrapper .angor-vertical-navigation-item .angor-vertical-navigation-item-title-wrapper .angor-vertical-navigation-item-subtitle,angor-vertical-navigation angor-vertical-navigation-group-item .angor-vertical-navigation-item-wrapper .angor-vertical-navigation-item .angor-vertical-navigation-item-title-wrapper .angor-vertical-navigation-item-subtitle,angor-vertical-navigation angor-vertical-navigation-spacer-item .angor-vertical-navigation-item-wrapper .angor-vertical-navigation-item .angor-vertical-navigation-item-title-wrapper .angor-vertical-navigation-item-subtitle{font-size:11px;line-height:1.5}angor-vertical-navigation angor-vertical-navigation-aside-item .angor-vertical-navigation-item-wrapper .angor-vertical-navigation-item .angor-vertical-navigation-item-badge,angor-vertical-navigation angor-vertical-navigation-basic-item .angor-vertical-navigation-item-wrapper .angor-vertical-navigation-item .angor-vertical-navigation-item-badge,angor-vertical-navigation angor-vertical-navigation-collapsable-item .angor-vertical-navigation-item-wrapper .angor-vertical-navigation-item .angor-vertical-navigation-item-badge,angor-vertical-navigation angor-vertical-navigation-divider-item .angor-vertical-navigation-item-wrapper .angor-vertical-navigation-item .angor-vertical-navigation-item-badge,angor-vertical-navigation angor-vertical-navigation-group-item .angor-vertical-navigation-item-wrapper .angor-vertical-navigation-item .angor-vertical-navigation-item-badge,angor-vertical-navigation angor-vertical-navigation-spacer-item .angor-vertical-navigation-item-wrapper .angor-vertical-navigation-item .angor-vertical-navigation-item-badge{margin-left:auto}angor-vertical-navigation angor-vertical-navigation-aside-item .angor-vertical-navigation-item-wrapper .angor-vertical-navigation-item .angor-vertical-navigation-item-badge .angor-vertical-navigation-item-badge-content,angor-vertical-navigation angor-vertical-navigation-basic-item .angor-vertical-navigation-item-wrapper .angor-vertical-navigation-item .angor-vertical-navigation-item-badge .angor-vertical-navigation-item-badge-content,angor-vertical-navigation angor-vertical-navigation-collapsable-item .angor-vertical-navigation-item-wrapper .angor-vertical-navigation-item .angor-vertical-navigation-item-badge .angor-vertical-navigation-item-badge-content,angor-vertical-navigation angor-vertical-navigation-divider-item .angor-vertical-navigation-item-wrapper .angor-vertical-navigation-item .angor-vertical-navigation-item-badge .angor-vertical-navigation-item-badge-content,angor-vertical-navigation angor-vertical-navigation-group-item .angor-vertical-navigation-item-wrapper .angor-vertical-navigation-item .angor-vertical-navigation-item-badge .angor-vertical-navigation-item-badge-content,angor-vertical-navigation angor-vertical-navigation-spacer-item .angor-vertical-navigation-item-wrapper .angor-vertical-navigation-item .angor-vertical-navigation-item-badge .angor-vertical-navigation-item-badge-content{display:flex;align-items:center;justify-content:center;font-size:10px;font-weight:600;white-space:nowrap;height:20px}angor-vertical-navigation angor-vertical-navigation-aside-item>.angor-vertical-navigation-item-wrapper,angor-vertical-navigation angor-vertical-navigation-basic-item>.angor-vertical-navigation-item-wrapper,angor-vertical-navigation angor-vertical-navigation-collapsable-item>.angor-vertical-navigation-item-wrapper,angor-vertical-navigation angor-vertical-navigation-group-item>.angor-vertical-navigation-item-wrapper{margin:0 12px}angor-vertical-navigation angor-vertical-navigation-aside-item,angor-vertical-navigation angor-vertical-navigation-basic-item,angor-vertical-navigation angor-vertical-navigation-collapsable-item{margin-bottom:4px}angor-vertical-navigation angor-vertical-navigation-aside-item .angor-vertical-navigation-item,angor-vertical-navigation angor-vertical-navigation-basic-item .angor-vertical-navigation-item,angor-vertical-navigation angor-vertical-navigation-collapsable-item .angor-vertical-navigation-item{cursor:pointer}angor-vertical-navigation angor-vertical-navigation-collapsable-item>.angor-vertical-navigation-item-wrapper .angor-vertical-navigation-item .angor-vertical-navigation-item-badge+.angor-vertical-navigation-item-arrow{margin-left:8px}angor-vertical-navigation angor-vertical-navigation-collapsable-item>.angor-vertical-navigation-item-wrapper .angor-vertical-navigation-item .angor-vertical-navigation-item-arrow{height:20px;line-height:20px;margin-left:auto;transition:transform .3s cubic-bezier(.25,.8,.25,1),color 375ms cubic-bezier(.25,.8,.25,1)}angor-vertical-navigation angor-vertical-navigation-collapsable-item.angor-vertical-navigation-item-expanded>.angor-vertical-navigation-item-wrapper .angor-vertical-navigation-item .angor-vertical-navigation-item-arrow{transform:rotate(90deg)}angor-vertical-navigation angor-vertical-navigation-collapsable-item>.angor-vertical-navigation-item-children>*:first-child{margin-top:6px}angor-vertical-navigation angor-vertical-navigation-collapsable-item>.angor-vertical-navigation-item-children>*:last-child{padding-bottom:6px}angor-vertical-navigation angor-vertical-navigation-collapsable-item>.angor-vertical-navigation-item-children>*:last-child>.angor-vertical-navigation-item-children>*:last-child{padding-bottom:0}angor-vertical-navigation angor-vertical-navigation-collapsable-item>.angor-vertical-navigation-item-children .angor-vertical-navigation-item{padding:10px 16px}angor-vertical-navigation angor-vertical-navigation-collapsable-item .angor-vertical-navigation-item-children{overflow:hidden}angor-vertical-navigation angor-vertical-navigation-collapsable-item .angor-vertical-navigation-item-children .angor-vertical-navigation-item{padding-left:56px}angor-vertical-navigation angor-vertical-navigation-collapsable-item .angor-vertical-navigation-item-children .angor-vertical-navigation-item-children .angor-vertical-navigation-item{padding-left:72px}angor-vertical-navigation angor-vertical-navigation-collapsable-item .angor-vertical-navigation-item-children .angor-vertical-navigation-item-children .angor-vertical-navigation-item-children .angor-vertical-navigation-item{padding-left:88px}angor-vertical-navigation angor-vertical-navigation-collapsable-item .angor-vertical-navigation-item-children .angor-vertical-navigation-item-children .angor-vertical-navigation-item-children .angor-vertical-navigation-item-children .angor-vertical-navigation-item{padding-left:104px}angor-vertical-navigation angor-vertical-navigation-divider-item{margin:12px 0}angor-vertical-navigation angor-vertical-navigation-divider-item .angor-vertical-navigation-item-wrapper{height:1px;box-shadow:0 1px}angor-vertical-navigation angor-vertical-navigation-group-item>.angor-vertical-navigation-item-wrapper .angor-vertical-navigation-item .angor-vertical-navigation-item-badge,angor-vertical-navigation angor-vertical-navigation-group-item>.angor-vertical-navigation-item-wrapper .angor-vertical-navigation-item .angor-vertical-navigation-item-icon{display:none!important}angor-vertical-navigation angor-vertical-navigation-group-item>.angor-vertical-navigation-item-wrapper .angor-vertical-navigation-item .angor-vertical-navigation-item-title-wrapper .angor-vertical-navigation-item-title{font-size:12px;font-weight:600;letter-spacing:.05em;text-transform:uppercase}angor-vertical-navigation angor-vertical-navigation-spacer-item{margin:6px 0}.angor-vertical-navigation-overlay{position:absolute;inset:0;z-index:170;opacity:0;background-color:#0009}.angor-vertical-navigation-overlay+.angor-vertical-navigation-aside-overlay{background-color:transparent}.angor-vertical-navigation-aside-overlay{position:absolute;inset:0;z-index:169;opacity:0;background-color:#0000004d}angor-vertical-navigation-aside-item .angor-vertical-navigation-item-wrapper .angor-vertical-navigation-item,angor-vertical-navigation-basic-item .angor-vertical-navigation-item-wrapper .angor-vertical-navigation-item,angor-vertical-navigation-collapsable-item .angor-vertical-navigation-item-wrapper .angor-vertical-navigation-item,angor-vertical-navigation-group-item .angor-vertical-navigation-item-wrapper .angor-vertical-navigation-item{color:currentColor}angor-vertical-navigation-aside-item .angor-vertical-navigation-item-wrapper .angor-vertical-navigation-item .angor-vertical-navigation-item-icon,angor-vertical-navigation-basic-item .angor-vertical-navigation-item-wrapper .angor-vertical-navigation-item .angor-vertical-navigation-item-icon,angor-vertical-navigation-collapsable-item .angor-vertical-navigation-item-wrapper .angor-vertical-navigation-item .angor-vertical-navigation-item-icon,angor-vertical-navigation-group-item .angor-vertical-navigation-item-wrapper .angor-vertical-navigation-item .angor-vertical-navigation-item-icon{color:currentColor;opacity:.6}angor-vertical-navigation-aside-item .angor-vertical-navigation-item-wrapper .angor-vertical-navigation-item .angor-vertical-navigation-item-title-wrapper .angor-vertical-navigation-item-title,angor-vertical-navigation-basic-item .angor-vertical-navigation-item-wrapper .angor-vertical-navigation-item .angor-vertical-navigation-item-title-wrapper .angor-vertical-navigation-item-title,angor-vertical-navigation-collapsable-item .angor-vertical-navigation-item-wrapper .angor-vertical-navigation-item .angor-vertical-navigation-item-title-wrapper .angor-vertical-navigation-item-title,angor-vertical-navigation-group-item .angor-vertical-navigation-item-wrapper .angor-vertical-navigation-item .angor-vertical-navigation-item-title-wrapper .angor-vertical-navigation-item-title{color:currentColor;opacity:.8}angor-vertical-navigation-aside-item .angor-vertical-navigation-item-wrapper .angor-vertical-navigation-item .angor-vertical-navigation-item-title-wrapper .angor-vertical-navigation-item-subtitle,angor-vertical-navigation-basic-item .angor-vertical-navigation-item-wrapper .angor-vertical-navigation-item .angor-vertical-navigation-item-title-wrapper .angor-vertical-navigation-item-subtitle,angor-vertical-navigation-collapsable-item .angor-vertical-navigation-item-wrapper .angor-vertical-navigation-item .angor-vertical-navigation-item-title-wrapper .angor-vertical-navigation-item-subtitle,angor-vertical-navigation-group-item .angor-vertical-navigation-item-wrapper .angor-vertical-navigation-item .angor-vertical-navigation-item-title-wrapper .angor-vertical-navigation-item-subtitle{color:currentColor;opacity:.5}angor-vertical-navigation-aside-item>.angor-vertical-navigation-item-wrapper .angor-vertical-navigation-item:not(.angor-vertical-navigation-item-disabled).angor-vertical-navigation-item-active,angor-vertical-navigation-aside-item>.angor-vertical-navigation-item-wrapper .angor-vertical-navigation-item:not(.angor-vertical-navigation-item-disabled).angor-vertical-navigation-item-active-forced,angor-vertical-navigation-basic-item>.angor-vertical-navigation-item-wrapper .angor-vertical-navigation-item:not(.angor-vertical-navigation-item-disabled).angor-vertical-navigation-item-active,angor-vertical-navigation-basic-item>.angor-vertical-navigation-item-wrapper .angor-vertical-navigation-item:not(.angor-vertical-navigation-item-disabled).angor-vertical-navigation-item-active-forced,angor-vertical-navigation-collapsable-item>.angor-vertical-navigation-item-wrapper .angor-vertical-navigation-item:not(.angor-vertical-navigation-item-disabled).angor-vertical-navigation-item-active,angor-vertical-navigation-collapsable-item>.angor-vertical-navigation-item-wrapper .angor-vertical-navigation-item:not(.angor-vertical-navigation-item-disabled).angor-vertical-navigation-item-active-forced{background-color:rgb(3 33 40 / var(--tw-bg-opacity, 1));--tw-bg-opacity: .05}angor-vertical-navigation-aside-item>.angor-vertical-navigation-item-wrapper .angor-vertical-navigation-item:not(.angor-vertical-navigation-item-disabled).angor-vertical-navigation-item-active:is(.dark *),angor-vertical-navigation-aside-item>.angor-vertical-navigation-item-wrapper .angor-vertical-navigation-item:not(.angor-vertical-navigation-item-disabled).angor-vertical-navigation-item-active-forced:is(.dark *),angor-vertical-navigation-basic-item>.angor-vertical-navigation-item-wrapper .angor-vertical-navigation-item:not(.angor-vertical-navigation-item-disabled).angor-vertical-navigation-item-active:is(.dark *),angor-vertical-navigation-basic-item>.angor-vertical-navigation-item-wrapper .angor-vertical-navigation-item:not(.angor-vertical-navigation-item-disabled).angor-vertical-navigation-item-active-forced:is(.dark *),angor-vertical-navigation-collapsable-item>.angor-vertical-navigation-item-wrapper .angor-vertical-navigation-item:not(.angor-vertical-navigation-item-disabled).angor-vertical-navigation-item-active:is(.dark *),angor-vertical-navigation-collapsable-item>.angor-vertical-navigation-item-wrapper .angor-vertical-navigation-item:not(.angor-vertical-navigation-item-disabled).angor-vertical-navigation-item-active-forced:is(.dark *){background-color:rgb(255 255 255 / var(--tw-bg-opacity, 1));--tw-bg-opacity: .12}angor-vertical-navigation-aside-item>.angor-vertical-navigation-item-wrapper .angor-vertical-navigation-item:not(.angor-vertical-navigation-item-disabled).angor-vertical-navigation-item-active .angor-vertical-navigation-item-icon,angor-vertical-navigation-aside-item>.angor-vertical-navigation-item-wrapper .angor-vertical-navigation-item:not(.angor-vertical-navigation-item-disabled).angor-vertical-navigation-item-active-forced .angor-vertical-navigation-item-icon,angor-vertical-navigation-basic-item>.angor-vertical-navigation-item-wrapper .angor-vertical-navigation-item:not(.angor-vertical-navigation-item-disabled).angor-vertical-navigation-item-active .angor-vertical-navigation-item-icon,angor-vertical-navigation-basic-item>.angor-vertical-navigation-item-wrapper .angor-vertical-navigation-item:not(.angor-vertical-navigation-item-disabled).angor-vertical-navigation-item-active-forced .angor-vertical-navigation-item-icon,angor-vertical-navigation-collapsable-item>.angor-vertical-navigation-item-wrapper .angor-vertical-navigation-item:not(.angor-vertical-navigation-item-disabled).angor-vertical-navigation-item-active .angor-vertical-navigation-item-icon,angor-vertical-navigation-collapsable-item>.angor-vertical-navigation-item-wrapper .angor-vertical-navigation-item:not(.angor-vertical-navigation-item-disabled).angor-vertical-navigation-item-active-forced .angor-vertical-navigation-item-icon{opacity:1}angor-vertical-navigation-aside-item>.angor-vertical-navigation-item-wrapper .angor-vertical-navigation-item:not(.angor-vertical-navigation-item-disabled).angor-vertical-navigation-item-active .angor-vertical-navigation-item-title,angor-vertical-navigation-aside-item>.angor-vertical-navigation-item-wrapper .angor-vertical-navigation-item:not(.angor-vertical-navigation-item-disabled).angor-vertical-navigation-item-active-forced .angor-vertical-navigation-item-title,angor-vertical-navigation-basic-item>.angor-vertical-navigation-item-wrapper .angor-vertical-navigation-item:not(.angor-vertical-navigation-item-disabled).angor-vertical-navigation-item-active .angor-vertical-navigation-item-title,angor-vertical-navigation-basic-item>.angor-vertical-navigation-item-wrapper .angor-vertical-navigation-item:not(.angor-vertical-navigation-item-disabled).angor-vertical-navigation-item-active-forced .angor-vertical-navigation-item-title,angor-vertical-navigation-collapsable-item>.angor-vertical-navigation-item-wrapper .angor-vertical-navigation-item:not(.angor-vertical-navigation-item-disabled).angor-vertical-navigation-item-active .angor-vertical-navigation-item-title,angor-vertical-navigation-collapsable-item>.angor-vertical-navigation-item-wrapper .angor-vertical-navigation-item:not(.angor-vertical-navigation-item-disabled).angor-vertical-navigation-item-active-forced .angor-vertical-navigation-item-title{opacity:1}angor-vertical-navigation-aside-item>.angor-vertical-navigation-item-wrapper .angor-vertical-navigation-item:not(.angor-vertical-navigation-item-disabled).angor-vertical-navigation-item-active .angor-vertical-navigation-item-subtitle,angor-vertical-navigation-aside-item>.angor-vertical-navigation-item-wrapper .angor-vertical-navigation-item:not(.angor-vertical-navigation-item-disabled).angor-vertical-navigation-item-active-forced .angor-vertical-navigation-item-subtitle,angor-vertical-navigation-basic-item>.angor-vertical-navigation-item-wrapper .angor-vertical-navigation-item:not(.angor-vertical-navigation-item-disabled).angor-vertical-navigation-item-active .angor-vertical-navigation-item-subtitle,angor-vertical-navigation-basic-item>.angor-vertical-navigation-item-wrapper .angor-vertical-navigation-item:not(.angor-vertical-navigation-item-disabled).angor-vertical-navigation-item-active-forced .angor-vertical-navigation-item-subtitle,angor-vertical-navigation-collapsable-item>.angor-vertical-navigation-item-wrapper .angor-vertical-navigation-item:not(.angor-vertical-navigation-item-disabled).angor-vertical-navigation-item-active .angor-vertical-navigation-item-subtitle,angor-vertical-navigation-collapsable-item>.angor-vertical-navigation-item-wrapper .angor-vertical-navigation-item:not(.angor-vertical-navigation-item-disabled).angor-vertical-navigation-item-active-forced .angor-vertical-navigation-item-subtitle{opacity:1}angor-vertical-navigation-aside-item>.angor-vertical-navigation-item-wrapper .angor-vertical-navigation-item:not(.angor-vertical-navigation-item-active-forced):not(.angor-vertical-navigation-item-active):not(.angor-vertical-navigation-item-disabled):hover,angor-vertical-navigation-basic-item>.angor-vertical-navigation-item-wrapper .angor-vertical-navigation-item:not(.angor-vertical-navigation-item-active-forced):not(.angor-vertical-navigation-item-active):not(.angor-vertical-navigation-item-disabled):hover,angor-vertical-navigation-collapsable-item>.angor-vertical-navigation-item-wrapper .angor-vertical-navigation-item:not(.angor-vertical-navigation-item-active-forced):not(.angor-vertical-navigation-item-active):not(.angor-vertical-navigation-item-disabled):hover{background-color:rgb(3 33 40 / var(--tw-bg-opacity, 1));--tw-bg-opacity: .05}angor-vertical-navigation-aside-item>.angor-vertical-navigation-item-wrapper .angor-vertical-navigation-item:not(.angor-vertical-navigation-item-active-forced):not(.angor-vertical-navigation-item-active):not(.angor-vertical-navigation-item-disabled):hover:is(.dark *),angor-vertical-navigation-basic-item>.angor-vertical-navigation-item-wrapper .angor-vertical-navigation-item:not(.angor-vertical-navigation-item-active-forced):not(.angor-vertical-navigation-item-active):not(.angor-vertical-navigation-item-disabled):hover:is(.dark *),angor-vertical-navigation-collapsable-item>.angor-vertical-navigation-item-wrapper .angor-vertical-navigation-item:not(.angor-vertical-navigation-item-active-forced):not(.angor-vertical-navigation-item-active):not(.angor-vertical-navigation-item-disabled):hover:is(.dark *){background-color:rgb(255 255 255 / var(--tw-bg-opacity, 1));--tw-bg-opacity: .12}angor-vertical-navigation-aside-item>.angor-vertical-navigation-item-wrapper .angor-vertical-navigation-item:not(.angor-vertical-navigation-item-active-forced):not(.angor-vertical-navigation-item-active):not(.angor-vertical-navigation-item-disabled):hover .angor-vertical-navigation-item-icon,angor-vertical-navigation-basic-item>.angor-vertical-navigation-item-wrapper .angor-vertical-navigation-item:not(.angor-vertical-navigation-item-active-forced):not(.angor-vertical-navigation-item-active):not(.angor-vertical-navigation-item-disabled):hover .angor-vertical-navigation-item-icon,angor-vertical-navigation-collapsable-item>.angor-vertical-navigation-item-wrapper .angor-vertical-navigation-item:not(.angor-vertical-navigation-item-active-forced):not(.angor-vertical-navigation-item-active):not(.angor-vertical-navigation-item-disabled):hover .angor-vertical-navigation-item-icon{opacity:1}angor-vertical-navigation-aside-item>.angor-vertical-navigation-item-wrapper .angor-vertical-navigation-item:not(.angor-vertical-navigation-item-active-forced):not(.angor-vertical-navigation-item-active):not(.angor-vertical-navigation-item-disabled):hover .angor-vertical-navigation-item-title,angor-vertical-navigation-aside-item>.angor-vertical-navigation-item-wrapper .angor-vertical-navigation-item:not(.angor-vertical-navigation-item-active-forced):not(.angor-vertical-navigation-item-active):not(.angor-vertical-navigation-item-disabled):hover .angor-vertical-navigation-item-arrow,angor-vertical-navigation-basic-item>.angor-vertical-navigation-item-wrapper .angor-vertical-navigation-item:not(.angor-vertical-navigation-item-active-forced):not(.angor-vertical-navigation-item-active):not(.angor-vertical-navigation-item-disabled):hover .angor-vertical-navigation-item-title,angor-vertical-navigation-basic-item>.angor-vertical-navigation-item-wrapper .angor-vertical-navigation-item:not(.angor-vertical-navigation-item-active-forced):not(.angor-vertical-navigation-item-active):not(.angor-vertical-navigation-item-disabled):hover .angor-vertical-navigation-item-arrow,angor-vertical-navigation-collapsable-item>.angor-vertical-navigation-item-wrapper .angor-vertical-navigation-item:not(.angor-vertical-navigation-item-active-forced):not(.angor-vertical-navigation-item-active):not(.angor-vertical-navigation-item-disabled):hover .angor-vertical-navigation-item-title,angor-vertical-navigation-collapsable-item>.angor-vertical-navigation-item-wrapper .angor-vertical-navigation-item:not(.angor-vertical-navigation-item-active-forced):not(.angor-vertical-navigation-item-active):not(.angor-vertical-navigation-item-disabled):hover .angor-vertical-navigation-item-arrow{opacity:1}angor-vertical-navigation-aside-item>.angor-vertical-navigation-item-wrapper .angor-vertical-navigation-item:not(.angor-vertical-navigation-item-active-forced):not(.angor-vertical-navigation-item-active):not(.angor-vertical-navigation-item-disabled):hover .angor-vertical-navigation-item-subtitle,angor-vertical-navigation-basic-item>.angor-vertical-navigation-item-wrapper .angor-vertical-navigation-item:not(.angor-vertical-navigation-item-active-forced):not(.angor-vertical-navigation-item-active):not(.angor-vertical-navigation-item-disabled):hover .angor-vertical-navigation-item-subtitle,angor-vertical-navigation-collapsable-item>.angor-vertical-navigation-item-wrapper .angor-vertical-navigation-item:not(.angor-vertical-navigation-item-active-forced):not(.angor-vertical-navigation-item-active):not(.angor-vertical-navigation-item-disabled):hover .angor-vertical-navigation-item-subtitle{opacity:1}angor-vertical-navigation-collapsable-item.angor-vertical-navigation-item-expanded>.angor-vertical-navigation-item-wrapper .angor-vertical-navigation-item .angor-vertical-navigation-item-icon{opacity:1}angor-vertical-navigation-collapsable-item.angor-vertical-navigation-item-expanded>.angor-vertical-navigation-item-wrapper .angor-vertical-navigation-item .angor-vertical-navigation-item-title,angor-vertical-navigation-collapsable-item.angor-vertical-navigation-item-expanded>.angor-vertical-navigation-item-wrapper .angor-vertical-navigation-item .angor-vertical-navigation-item-arrow{opacity:1}angor-vertical-navigation-collapsable-item.angor-vertical-navigation-item-expanded>.angor-vertical-navigation-item-wrapper .angor-vertical-navigation-item .angor-vertical-navigation-item-subtitle{opacity:1}angor-vertical-navigation-group-item>.angor-vertical-navigation-item-wrapper .angor-vertical-navigation-item .angor-vertical-navigation-item-title-wrapper .angor-vertical-navigation-item-title{--tw-text-opacity: 1;color:rgba(var(--angor-primary-600-rgb),var(--tw-text-opacity, 1));opacity:1}angor-vertical-navigation-group-item>.angor-vertical-navigation-item-wrapper .angor-vertical-navigation-item .angor-vertical-navigation-item-title-wrapper .angor-vertical-navigation-item-title:is(.dark *){--tw-text-opacity: 1;color:rgba(var(--angor-primary-400-rgb),var(--tw-text-opacity, 1))}:root{--angor-vertical-navigation-compact-width: 112px}angor-vertical-navigation.angor-vertical-navigation-appearance-compact{width:var(--angor-vertical-navigation-compact-width);min-width:var(--angor-vertical-navigation-compact-width);max-width:var(--angor-vertical-navigation-compact-width)}angor-vertical-navigation.angor-vertical-navigation-appearance-compact.angor-vertical-navigation-position-left.angor-vertical-navigation-mode-side{margin-left:calc(var(--angor-vertical-navigation-compact-width) * -1)}angor-vertical-navigation.angor-vertical-navigation-appearance-compact.angor-vertical-navigation-position-left.angor-vertical-navigation-opened{margin-left:0}angor-vertical-navigation.angor-vertical-navigation-appearance-compact.angor-vertical-navigation-position-right.angor-vertical-navigation-mode-side{margin-right:calc(var(--angor-vertical-navigation-compact-width) * -1)}angor-vertical-navigation.angor-vertical-navigation-appearance-compact.angor-vertical-navigation-position-right.angor-vertical-navigation-opened{margin-right:0}angor-vertical-navigation.angor-vertical-navigation-appearance-compact.angor-vertical-navigation-position-right .angor-vertical-navigation-aside-wrapper{left:auto;right:var(--angor-vertical-navigation-compact-width)}angor-vertical-navigation.angor-vertical-navigation-appearance-compact .angor-vertical-navigation-wrapper .angor-vertical-navigation-content>angor-vertical-navigation-aside-item .angor-vertical-navigation-item-wrapper,angor-vertical-navigation.angor-vertical-navigation-appearance-compact .angor-vertical-navigation-wrapper .angor-vertical-navigation-content>angor-vertical-navigation-basic-item .angor-vertical-navigation-item-wrapper{margin:4px 8px 0}angor-vertical-navigation.angor-vertical-navigation-appearance-compact .angor-vertical-navigation-wrapper .angor-vertical-navigation-content>angor-vertical-navigation-aside-item .angor-vertical-navigation-item-wrapper .angor-vertical-navigation-item,angor-vertical-navigation.angor-vertical-navigation-appearance-compact .angor-vertical-navigation-wrapper .angor-vertical-navigation-content>angor-vertical-navigation-basic-item .angor-vertical-navigation-item-wrapper .angor-vertical-navigation-item{flex-direction:column;justify-content:center;padding:12px;border-radius:6px}angor-vertical-navigation.angor-vertical-navigation-appearance-compact .angor-vertical-navigation-wrapper .angor-vertical-navigation-content>angor-vertical-navigation-aside-item .angor-vertical-navigation-item-wrapper .angor-vertical-navigation-item .angor-vertical-navigation-item-icon,angor-vertical-navigation.angor-vertical-navigation-appearance-compact .angor-vertical-navigation-wrapper .angor-vertical-navigation-content>angor-vertical-navigation-basic-item .angor-vertical-navigation-item-wrapper .angor-vertical-navigation-item .angor-vertical-navigation-item-icon{margin-right:0}angor-vertical-navigation.angor-vertical-navigation-appearance-compact .angor-vertical-navigation-wrapper .angor-vertical-navigation-content>angor-vertical-navigation-aside-item .angor-vertical-navigation-item-wrapper .angor-vertical-navigation-item .angor-vertical-navigation-item-title-wrapper,angor-vertical-navigation.angor-vertical-navigation-appearance-compact .angor-vertical-navigation-wrapper .angor-vertical-navigation-content>angor-vertical-navigation-basic-item .angor-vertical-navigation-item-wrapper .angor-vertical-navigation-item .angor-vertical-navigation-item-title-wrapper{margin-top:8px}angor-vertical-navigation.angor-vertical-navigation-appearance-compact .angor-vertical-navigation-wrapper .angor-vertical-navigation-content>angor-vertical-navigation-aside-item .angor-vertical-navigation-item-wrapper .angor-vertical-navigation-item .angor-vertical-navigation-item-title-wrapper .angor-vertical-navigation-item-title,angor-vertical-navigation.angor-vertical-navigation-appearance-compact .angor-vertical-navigation-wrapper .angor-vertical-navigation-content>angor-vertical-navigation-basic-item .angor-vertical-navigation-item-wrapper .angor-vertical-navigation-item .angor-vertical-navigation-item-title-wrapper .angor-vertical-navigation-item-title{font-size:12px;font-weight:500;text-align:center;line-height:16px}angor-vertical-navigation.angor-vertical-navigation-appearance-compact .angor-vertical-navigation-wrapper .angor-vertical-navigation-content>angor-vertical-navigation-aside-item .angor-vertical-navigation-item-wrapper .angor-vertical-navigation-item .angor-vertical-navigation-item-title-wrapper .angor-vertical-navigation-item-subtitle,angor-vertical-navigation.angor-vertical-navigation-appearance-compact .angor-vertical-navigation-wrapper .angor-vertical-navigation-content>angor-vertical-navigation-basic-item .angor-vertical-navigation-item-wrapper .angor-vertical-navigation-item .angor-vertical-navigation-item-title-wrapper .angor-vertical-navigation-item-subtitle{display:none!important}angor-vertical-navigation.angor-vertical-navigation-appearance-compact .angor-vertical-navigation-wrapper .angor-vertical-navigation-content>angor-vertical-navigation-aside-item .angor-vertical-navigation-item-wrapper .angor-vertical-navigation-item .angor-vertical-navigation-item-badge,angor-vertical-navigation.angor-vertical-navigation-appearance-compact .angor-vertical-navigation-wrapper .angor-vertical-navigation-content>angor-vertical-navigation-basic-item .angor-vertical-navigation-item-wrapper .angor-vertical-navigation-item .angor-vertical-navigation-item-badge{position:absolute;top:12px;left:64px}angor-vertical-navigation.angor-vertical-navigation-appearance-compact .angor-vertical-navigation-wrapper .angor-vertical-navigation-content>angor-vertical-navigation-aside-item>angor-vertical-navigation-collapsable-item,angor-vertical-navigation.angor-vertical-navigation-appearance-compact .angor-vertical-navigation-wrapper .angor-vertical-navigation-content>angor-vertical-navigation-basic-item>angor-vertical-navigation-collapsable-item{display:none}angor-vertical-navigation.angor-vertical-navigation-appearance-compact .angor-vertical-navigation-wrapper .angor-vertical-navigation-content>angor-vertical-navigation-aside-item>angor-vertical-navigation-group-item>.angor-vertical-navigation-item-wrapper,angor-vertical-navigation.angor-vertical-navigation-appearance-compact .angor-vertical-navigation-wrapper .angor-vertical-navigation-content>angor-vertical-navigation-basic-item>angor-vertical-navigation-group-item>.angor-vertical-navigation-item-wrapper{display:none}angor-vertical-navigation.angor-vertical-navigation-appearance-compact .angor-vertical-navigation-aside-wrapper{left:var(--angor-vertical-navigation-compact-width)}:root{--angor-vertical-navigation-width: 280px;--angor-vertical-navigation-dense-width: 80px}angor-vertical-navigation.angor-vertical-navigation-appearance-dense:not(.angor-vertical-navigation-mode-over){width:var(--angor-vertical-navigation-dense-width);min-width:var(--angor-vertical-navigation-dense-width);max-width:var(--angor-vertical-navigation-dense-width)}angor-vertical-navigation.angor-vertical-navigation-appearance-dense:not(.angor-vertical-navigation-mode-over).angor-vertical-navigation-position-left.angor-vertical-navigation-mode-side{margin-left:calc(var(--angor-vertical-navigation-dense-width) * -1)}angor-vertical-navigation.angor-vertical-navigation-appearance-dense:not(.angor-vertical-navigation-mode-over).angor-vertical-navigation-position-left.angor-vertical-navigation-opened{margin-left:0}angor-vertical-navigation.angor-vertical-navigation-appearance-dense:not(.angor-vertical-navigation-mode-over).angor-vertical-navigation-position-right.angor-vertical-navigation-mode-side{margin-right:calc(var(--angor-vertical-navigation-dense-width) * -1)}angor-vertical-navigation.angor-vertical-navigation-appearance-dense:not(.angor-vertical-navigation-mode-over).angor-vertical-navigation-position-right.angor-vertical-navigation-opened{margin-right:0}angor-vertical-navigation.angor-vertical-navigation-appearance-dense:not(.angor-vertical-navigation-mode-over).angor-vertical-navigation-position-right .angor-vertical-navigation-aside-wrapper{left:auto;right:var(--angor-vertical-navigation-dense-width)}angor-vertical-navigation.angor-vertical-navigation-appearance-dense:not(.angor-vertical-navigation-mode-over).angor-vertical-navigation-position-right.angor-vertical-navigation-hover .angor-vertical-navigation-aside-wrapper{left:auto;right:var(--angor-vertical-navigation-width)}angor-vertical-navigation.angor-vertical-navigation-appearance-dense .angor-vertical-navigation-wrapper .angor-vertical-navigation-content angor-vertical-navigation-aside-item .angor-vertical-navigation-item-wrapper .angor-vertical-navigation-item,angor-vertical-navigation.angor-vertical-navigation-appearance-dense .angor-vertical-navigation-wrapper .angor-vertical-navigation-content angor-vertical-navigation-basic-item .angor-vertical-navigation-item-wrapper .angor-vertical-navigation-item,angor-vertical-navigation.angor-vertical-navigation-appearance-dense .angor-vertical-navigation-wrapper .angor-vertical-navigation-content angor-vertical-navigation-collapsable-item .angor-vertical-navigation-item-wrapper .angor-vertical-navigation-item,angor-vertical-navigation.angor-vertical-navigation-appearance-dense .angor-vertical-navigation-wrapper .angor-vertical-navigation-content angor-vertical-navigation-group-item .angor-vertical-navigation-item-wrapper .angor-vertical-navigation-item{width:calc(var(--angor-vertical-navigation-dense-width) - 24px);min-width:calc(var(--angor-vertical-navigation-dense-width) - 24px);max-width:calc(var(--angor-vertical-navigation-dense-width) - 24px)}angor-vertical-navigation.angor-vertical-navigation-appearance-dense .angor-vertical-navigation-wrapper .angor-vertical-navigation-content angor-vertical-navigation-aside-item .angor-vertical-navigation-item-wrapper .angor-vertical-navigation-item .angor-vertical-navigation-item-arrow,angor-vertical-navigation.angor-vertical-navigation-appearance-dense .angor-vertical-navigation-wrapper .angor-vertical-navigation-content angor-vertical-navigation-aside-item .angor-vertical-navigation-item-wrapper .angor-vertical-navigation-item .angor-vertical-navigation-item-badge,angor-vertical-navigation.angor-vertical-navigation-appearance-dense .angor-vertical-navigation-wrapper .angor-vertical-navigation-content angor-vertical-navigation-aside-item .angor-vertical-navigation-item-wrapper .angor-vertical-navigation-item .angor-vertical-navigation-item-title-wrapper,angor-vertical-navigation.angor-vertical-navigation-appearance-dense .angor-vertical-navigation-wrapper .angor-vertical-navigation-content angor-vertical-navigation-basic-item .angor-vertical-navigation-item-wrapper .angor-vertical-navigation-item .angor-vertical-navigation-item-arrow,angor-vertical-navigation.angor-vertical-navigation-appearance-dense .angor-vertical-navigation-wrapper .angor-vertical-navigation-content angor-vertical-navigation-basic-item .angor-vertical-navigation-item-wrapper .angor-vertical-navigation-item .angor-vertical-navigation-item-badge,angor-vertical-navigation.angor-vertical-navigation-appearance-dense .angor-vertical-navigation-wrapper .angor-vertical-navigation-content angor-vertical-navigation-basic-item .angor-vertical-navigation-item-wrapper .angor-vertical-navigation-item .angor-vertical-navigation-item-title-wrapper,angor-vertical-navigation.angor-vertical-navigation-appearance-dense .angor-vertical-navigation-wrapper .angor-vertical-navigation-content angor-vertical-navigation-collapsable-item .angor-vertical-navigation-item-wrapper .angor-vertical-navigation-item .angor-vertical-navigation-item-arrow,angor-vertical-navigation.angor-vertical-navigation-appearance-dense .angor-vertical-navigation-wrapper .angor-vertical-navigation-content angor-vertical-navigation-collapsable-item .angor-vertical-navigation-item-wrapper .angor-vertical-navigation-item .angor-vertical-navigation-item-badge,angor-vertical-navigation.angor-vertical-navigation-appearance-dense .angor-vertical-navigation-wrapper .angor-vertical-navigation-content angor-vertical-navigation-collapsable-item .angor-vertical-navigation-item-wrapper .angor-vertical-navigation-item .angor-vertical-navigation-item-title-wrapper,angor-vertical-navigation.angor-vertical-navigation-appearance-dense .angor-vertical-navigation-wrapper .angor-vertical-navigation-content angor-vertical-navigation-group-item .angor-vertical-navigation-item-wrapper .angor-vertical-navigation-item .angor-vertical-navigation-item-arrow,angor-vertical-navigation.angor-vertical-navigation-appearance-dense .angor-vertical-navigation-wrapper .angor-vertical-navigation-content angor-vertical-navigation-group-item .angor-vertical-navigation-item-wrapper .angor-vertical-navigation-item .angor-vertical-navigation-item-badge,angor-vertical-navigation.angor-vertical-navigation-appearance-dense .angor-vertical-navigation-wrapper .angor-vertical-navigation-content angor-vertical-navigation-group-item .angor-vertical-navigation-item-wrapper .angor-vertical-navigation-item .angor-vertical-navigation-item-title-wrapper{transition:opacity .4s cubic-bezier(.25,.8,.25,1)}angor-vertical-navigation.angor-vertical-navigation-appearance-dense .angor-vertical-navigation-wrapper .angor-vertical-navigation-content angor-vertical-navigation-group-item:first-of-type{margin-top:0}angor-vertical-navigation.angor-vertical-navigation-appearance-dense:not(.angor-vertical-navigation-hover):not(.angor-vertical-navigation-mode-over) .angor-vertical-navigation-wrapper .angor-vertical-navigation-content .angor-vertical-navigation-item-wrapper .angor-vertical-navigation-item{padding:10px 16px}angor-vertical-navigation.angor-vertical-navigation-appearance-dense:not(.angor-vertical-navigation-hover):not(.angor-vertical-navigation-mode-over) .angor-vertical-navigation-wrapper .angor-vertical-navigation-content .angor-vertical-navigation-item-wrapper .angor-vertical-navigation-item .angor-vertical-navigation-item-arrow,angor-vertical-navigation.angor-vertical-navigation-appearance-dense:not(.angor-vertical-navigation-hover):not(.angor-vertical-navigation-mode-over) .angor-vertical-navigation-wrapper .angor-vertical-navigation-content .angor-vertical-navigation-item-wrapper .angor-vertical-navigation-item .angor-vertical-navigation-item-badge,angor-vertical-navigation.angor-vertical-navigation-appearance-dense:not(.angor-vertical-navigation-hover):not(.angor-vertical-navigation-mode-over) .angor-vertical-navigation-wrapper .angor-vertical-navigation-content .angor-vertical-navigation-item-wrapper .angor-vertical-navigation-item .angor-vertical-navigation-item-title-wrapper{white-space:nowrap;opacity:0}angor-vertical-navigation.angor-vertical-navigation-appearance-dense:not(.angor-vertical-navigation-hover):not(.angor-vertical-navigation-mode-over) .angor-vertical-navigation-wrapper .angor-vertical-navigation-content angor-vertical-navigation-collapsable-item .angor-vertical-navigation-item-children{display:none}angor-vertical-navigation.angor-vertical-navigation-appearance-dense:not(.angor-vertical-navigation-hover):not(.angor-vertical-navigation-mode-over) .angor-vertical-navigation-wrapper .angor-vertical-navigation-content angor-vertical-navigation-group-item>.angor-vertical-navigation-item-wrapper .angor-vertical-navigation-item:before{content:"";position:absolute;top:20px;width:23px;border-top-width:2px}angor-vertical-navigation.angor-vertical-navigation-appearance-dense .angor-vertical-navigation-aside-wrapper{left:var(--angor-vertical-navigation-dense-width)}angor-vertical-navigation.angor-vertical-navigation-appearance-dense.angor-vertical-navigation-hover .angor-vertical-navigation-wrapper{width:var(--angor-vertical-navigation-width)}angor-vertical-navigation.angor-vertical-navigation-appearance-dense.angor-vertical-navigation-hover .angor-vertical-navigation-wrapper .angor-vertical-navigation-content .angor-vertical-navigation-item-wrapper .angor-vertical-navigation-item{width:calc(var(--angor-vertical-navigation-width) - 24px);min-width:calc(var(--angor-vertical-navigation-width) - 24px);max-width:calc(var(--angor-vertical-navigation-width) - 24px)}angor-vertical-navigation.angor-vertical-navigation-appearance-dense.angor-vertical-navigation-hover .angor-vertical-navigation-wrapper .angor-vertical-navigation-content .angor-vertical-navigation-item-wrapper .angor-vertical-navigation-item .angor-vertical-navigation-item-arrow,angor-vertical-navigation.angor-vertical-navigation-appearance-dense.angor-vertical-navigation-hover .angor-vertical-navigation-wrapper .angor-vertical-navigation-content .angor-vertical-navigation-item-wrapper .angor-vertical-navigation-item .angor-vertical-navigation-item-badge,angor-vertical-navigation.angor-vertical-navigation-appearance-dense.angor-vertical-navigation-hover .angor-vertical-navigation-wrapper .angor-vertical-navigation-content .angor-vertical-navigation-item-wrapper .angor-vertical-navigation-item .angor-vertical-navigation-item-title-wrapper{white-space:nowrap;animation:removeWhiteSpaceNoWrap 1ms linear .35s;animation-fill-mode:forwards}angor-vertical-navigation.angor-vertical-navigation-appearance-dense.angor-vertical-navigation-hover .angor-vertical-navigation-aside-wrapper{left:var(--angor-vertical-navigation-width)}@keyframes removeWhiteSpaceNoWrap{0%{white-space:nowrap}99%{white-space:nowrap}to{white-space:normal}}:root{--angor-vertical-navigation-thin-width: 80px}angor-vertical-navigation.angor-vertical-navigation-appearance-thin{width:var(--angor-vertical-navigation-thin-width);min-width:var(--angor-vertical-navigation-thin-width);max-width:var(--angor-vertical-navigation-thin-width)}angor-vertical-navigation.angor-vertical-navigation-appearance-thin.angor-vertical-navigation-position-left.angor-vertical-navigation-mode-side{margin-left:calc(var(--angor-vertical-navigation-thin-width) * -1)}angor-vertical-navigation.angor-vertical-navigation-appearance-thin.angor-vertical-navigation-position-left.angor-vertical-navigation-opened{margin-left:0}angor-vertical-navigation.angor-vertical-navigation-appearance-thin.angor-vertical-navigation-position-right.angor-vertical-navigation-mode-side{margin-right:calc(var(--angor-vertical-navigation-thin-width) * -1)}angor-vertical-navigation.angor-vertical-navigation-appearance-thin.angor-vertical-navigation-position-right.angor-vertical-navigation-opened{margin-right:0}angor-vertical-navigation.angor-vertical-navigation-appearance-thin.angor-vertical-navigation-position-right .angor-vertical-navigation-aside-wrapper{left:auto;right:var(--angor-vertical-navigation-thin-width)}angor-vertical-navigation.angor-vertical-navigation-appearance-thin .angor-vertical-navigation-wrapper .angor-vertical-navigation-content>angor-vertical-navigation-aside-item,angor-vertical-navigation.angor-vertical-navigation-appearance-thin .angor-vertical-navigation-wrapper .angor-vertical-navigation-content>angor-vertical-navigation-basic-item{flex-direction:column;justify-content:center;height:64px;min-height:64px;max-height:64px;padding:0 16px}angor-vertical-navigation.angor-vertical-navigation-appearance-thin .angor-vertical-navigation-wrapper .angor-vertical-navigation-content>angor-vertical-navigation-aside-item .angor-vertical-navigation-item-wrapper,angor-vertical-navigation.angor-vertical-navigation-appearance-thin .angor-vertical-navigation-wrapper .angor-vertical-navigation-content>angor-vertical-navigation-basic-item .angor-vertical-navigation-item-wrapper{display:flex;align-items:center;justify-content:center}angor-vertical-navigation.angor-vertical-navigation-appearance-thin .angor-vertical-navigation-wrapper .angor-vertical-navigation-content>angor-vertical-navigation-aside-item .angor-vertical-navigation-item-wrapper .angor-vertical-navigation-item,angor-vertical-navigation.angor-vertical-navigation-appearance-thin .angor-vertical-navigation-wrapper .angor-vertical-navigation-content>angor-vertical-navigation-basic-item .angor-vertical-navigation-item-wrapper .angor-vertical-navigation-item{justify-content:center;padding:12px;border-radius:4px}angor-vertical-navigation.angor-vertical-navigation-appearance-thin .angor-vertical-navigation-wrapper .angor-vertical-navigation-content>angor-vertical-navigation-aside-item .angor-vertical-navigation-item-wrapper .angor-vertical-navigation-item .angor-vertical-navigation-item-icon,angor-vertical-navigation.angor-vertical-navigation-appearance-thin .angor-vertical-navigation-wrapper .angor-vertical-navigation-content>angor-vertical-navigation-basic-item .angor-vertical-navigation-item-wrapper .angor-vertical-navigation-item .angor-vertical-navigation-item-icon{margin:0}angor-vertical-navigation.angor-vertical-navigation-appearance-thin .angor-vertical-navigation-wrapper .angor-vertical-navigation-content>angor-vertical-navigation-aside-item .angor-vertical-navigation-item-wrapper .angor-vertical-navigation-item .angor-vertical-navigation-item-arrow,angor-vertical-navigation.angor-vertical-navigation-appearance-thin .angor-vertical-navigation-wrapper .angor-vertical-navigation-content>angor-vertical-navigation-aside-item .angor-vertical-navigation-item-wrapper .angor-vertical-navigation-item .angor-vertical-navigation-item-badge-content,angor-vertical-navigation.angor-vertical-navigation-appearance-thin .angor-vertical-navigation-wrapper .angor-vertical-navigation-content>angor-vertical-navigation-aside-item .angor-vertical-navigation-item-wrapper .angor-vertical-navigation-item .angor-vertical-navigation-item-title-wrapper,angor-vertical-navigation.angor-vertical-navigation-appearance-thin .angor-vertical-navigation-wrapper .angor-vertical-navigation-content>angor-vertical-navigation-basic-item .angor-vertical-navigation-item-wrapper .angor-vertical-navigation-item .angor-vertical-navigation-item-arrow,angor-vertical-navigation.angor-vertical-navigation-appearance-thin .angor-vertical-navigation-wrapper .angor-vertical-navigation-content>angor-vertical-navigation-basic-item .angor-vertical-navigation-item-wrapper .angor-vertical-navigation-item .angor-vertical-navigation-item-badge-content,angor-vertical-navigation.angor-vertical-navigation-appearance-thin .angor-vertical-navigation-wrapper .angor-vertical-navigation-content>angor-vertical-navigation-basic-item .angor-vertical-navigation-item-wrapper .angor-vertical-navigation-item .angor-vertical-navigation-item-title-wrapper{display:none}angor-vertical-navigation.angor-vertical-navigation-appearance-thin .angor-vertical-navigation-wrapper .angor-vertical-navigation-content>angor-vertical-navigation-collapsable-item{display:none}angor-vertical-navigation.angor-vertical-navigation-appearance-thin .angor-vertical-navigation-wrapper .angor-vertical-navigation-content>angor-vertical-navigation-group-item>.angor-vertical-navigation-item-wrapper{display:none}angor-vertical-navigation.angor-vertical-navigation-appearance-thin .angor-vertical-navigation-aside-wrapper{left:var(--angor-vertical-navigation-thin-width)}\n'],encapsulation:2,data:{animation:i.F},changeDetection:0})}}return Q})()},7891:(o,s,r)=>{"use strict";r.d(s,{t:()=>a});const a=new(r(3107).nKC)("ANGOR_APP_CONFIG")},1109:(o,s,r)=>{"use strict";r.d(s,{P:()=>w});var i=r(7891),a=r(3107),c=r(4819),y=r(1217);let w=(()=>{class C{constructor(){this._defaultConfig=(0,a.WQX)(i.t),this._configSubject=new y.t(this._defaultConfig)}get config$(){return this._configSubject.asObservable()}set config(S){const M=(0,c.A)({},this._configSubject.getValue(),S);this._configSubject.next(M)}reset(){this._configSubject.next(this._defaultConfig)}static{this.\u0275fac=function(M){return new(M||C)}}static{this.\u0275prov=a.jDH({token:C,factory:C.\u0275fac,providedIn:"root"})}}return C})()},7153:(o,s,r)=>{"use strict";r.d(s,{m:()=>ae});var i=r(4460),a=r(3107),c=r(9471),y=r(7544),w=r(3904);const C=(me,be,Oe,xe,De,ce,ue,Ce)=>({"bg-primary-100 text-primary-600 dark:bg-primary-600 dark:text-primary-50":me,"bg-accent-100 text-accent-600 dark:bg-accent-600 dark:text-accent-50":be,"bg-warn-100 text-warn-600 dark:bg-warn-600 dark:text-warn-50":Oe,"bg-gray-100 text-gray-600 dark:bg-gray-600 dark:text-gray-50":xe,"bg-blue-100 text-blue-600 dark:bg-blue-600 dark:text-blue-50":De,"bg-green-100 text-green-500 dark:bg-green-500 dark:text-green-50":ce,"bg-amber-100 text-amber-500 dark:bg-amber-500 dark:text-amber-50":ue,"bg-red-100 text-red-600 dark:bg-red-600 dark:text-red-50":Ce});function T(me,be){1&me&&(a.j41(0,"div",1)(1,"button",6),a.nrm(2,"mat-icon",7),a.k0s()()),2&me&&(a.R7$(),a.Y8G("matDialogClose",void 0),a.R7$(),a.Y8G("svgIcon","heroicons_outline:x-mark"))}function S(me,be){if(1&me&&(a.j41(0,"div",3),a.nrm(1,"mat-icon",8),a.k0s()),2&me){const Oe=a.XpG();a.Y8G("ngClass",a.lV(2,C,"primary"===Oe.data.icon.color,"accent"===Oe.data.icon.color,"warn"===Oe.data.icon.color,"basic"===Oe.data.icon.color,"info"===Oe.data.icon.color,"success"===Oe.data.icon.color,"warning"===Oe.data.icon.color,"error"===Oe.data.icon.color)),a.R7$(),a.Y8G("svgIcon",Oe.data.icon.name)}}function M(me,be){if(1&me&&a.nrm(0,"div",9),2&me){const Oe=a.XpG(2);a.Y8G("innerHTML",Oe.data.title,a.npT)}}function O(me,be){if(1&me&&a.nrm(0,"div",10),2&me){const Oe=a.XpG(2);a.Y8G("innerHTML",Oe.data.message,a.npT)}}function L(me,be){if(1&me&&(a.j41(0,"div",4),a.DNE(1,M,1,1,"div",9)(2,O,1,1,"div",10),a.k0s()),2&me){const Oe=a.XpG();a.R7$(),a.vxM(Oe.data.title?1:-1),a.R7$(),a.vxM(Oe.data.message?2:-1)}}function Z(me,be){if(1&me&&(a.j41(0,"button",11),a.EFF(1),a.k0s()),2&me){const Oe=a.XpG(2);a.Y8G("matDialogClose","cancelled"),a.R7$(),a.SpI(" ",Oe.data.actions.cancel.label," ")}}function q(me,be){if(1&me&&(a.j41(0,"button",12),a.EFF(1),a.k0s()),2&me){const Oe=a.XpG(2);a.Y8G("color",Oe.data.actions.confirm.color)("matDialogClose","confirmed"),a.R7$(),a.SpI(" ",Oe.data.actions.confirm.label," ")}}function re(me,be){if(1&me&&(a.j41(0,"div",5),a.DNE(1,Z,2,2,"button",11)(2,q,2,3,"button",12),a.k0s()),2&me){const Oe=a.XpG();a.R7$(),a.vxM(Oe.data.actions.cancel.show?1:-1),a.R7$(),a.vxM(Oe.data.actions.confirm.show?2:-1)}}let pe=(()=>{class me{constructor(){this.data=(0,a.WQX)(y.Vh)}static{this.\u0275fac=function(xe){return new(xe||me)}}static{this.\u0275cmp=a.VBU({type:me,selectors:[["angor-confirmation-dialog"]],decls:6,vars:4,consts:[[1,"relative","flex","h-full","w-full","flex-col"],[1,"absolute","right-0","top-0","pr-4","pt-4"],[1,"flex","flex-auto","flex-col","items-center","p-8","pb-6","sm:flex-row","sm:items-start","sm:pb-8"],[1,"flex","h-10","w-10","flex-0","items-center","justify-center","rounded-full","sm:mr-4",3,"ngClass"],[1,"mt-4","flex","flex-col","items-center","space-y-1","text-center","sm:mt-0","sm:items-start","sm:pr-8","sm:text-left"],[1,"flex","items-center","justify-center","space-x-3","bg-gray-50","px-6","py-4","dark:bg-black","dark:bg-opacity-10","sm:justify-end"],["mat-icon-button","",3,"matDialogClose"],[1,"text-secondary",3,"svgIcon"],[1,"text-current",3,"svgIcon"],[1,"text-xl","font-medium","leading-6",3,"innerHTML"],[1,"text-secondary",3,"innerHTML"],["mat-stroked-button","",3,"matDialogClose"],["mat-flat-button","",3,"color","matDialogClose"]],template:function(xe,De){1&xe&&(a.j41(0,"div",0),a.DNE(1,T,3,2,"div",1),a.j41(2,"div",2),a.DNE(3,S,2,11,"div",3)(4,L,3,2,"div",4),a.k0s(),a.DNE(5,re,3,2,"div",5),a.k0s()),2&xe&&(a.R7$(),a.vxM(De.data.dismissible?1:-1),a.R7$(2),a.vxM(De.data.icon.show?3:-1),a.R7$(),a.vxM(De.data.title||De.data.message?4:-1),a.R7$(),a.vxM(De.data.actions.confirm.show||De.data.actions.cancel.show?5:-1))},dependencies:[c.Hl,c.$z,c.iY,y.hM,y.tx,w.m_,w.An,i.YU],styles:["@media (min-width: 960px){.angor-confirmation-dialog-panel{width:32rem}}.angor-confirmation-dialog-panel .mat-mdc-dialog-container .mat-mdc-dialog-surface{padding:0!important}\n"],encapsulation:2})}}return me})();var se=r(4819);let ae=(()=>{class me{constructor(){this._matDialog=(0,a.WQX)(y.bZ),this._defaultConfig={title:"Confirm action",message:"Are you sure you want to confirm this action?",icon:{show:!0,name:"heroicons_outline:exclamation-triangle",color:"warn"},actions:{confirm:{show:!0,label:"Confirm",color:"warn"},cancel:{show:!0,label:"Cancel"}},dismissible:!1}}open(Oe={}){const xe=(0,se.A)({},this._defaultConfig,Oe);return this._matDialog.open(pe,{autoFocus:!1,disableClose:!xe.dismissible,data:xe,panelClass:"angor-confirmation-dialog-panel"})}static{this.\u0275fac=function(xe){return new(xe||me)}}static{this.\u0275prov=a.jDH({token:me,factory:me.\u0275fac,providedIn:"root"})}}return me})()},2012:(o,s,r)=>{"use strict";r.d(s,{l:()=>S});var i=r(1109),a=r(6520),c=r(3107),y=r(6143),w=r(7838),C=r(7947),T=r(2867);let S=(()=>{class M{constructor(){this._breakpointObserver=(0,c.WQX)(a.QP),this._angorConfigService=(0,c.WQX)(i.P),this._onMediaChange=new w.m(1),this._angorConfigService.config$.pipe((0,C.T)(L=>(0,y.A)(Object.entries(L.screens).map(([Z,q])=>[Z,`(min-width: ${q})`]))),(0,T.n)(L=>this._breakpointObserver.observe(Object.values(L)).pipe((0,C.T)(Z=>{const q=[],re={},pe=Object.entries(Z.breakpoints).filter(([se,ae])=>ae)??[];for(const[se]of pe){const ae=Object.entries(L).find(([me,be])=>be===se)[0];ae&&(q.push(ae),re[ae]=se)}this._onMediaChange.next({matchingAliases:q,matchingQueries:re})})))).subscribe()}get onMediaChange$(){return this._onMediaChange.asObservable()}onMediaQueryChange$(L){return this._breakpointObserver.observe(L)}static{this.\u0275fac=function(Z){return new(Z||M)}}static{this.\u0275prov=c.jDH({token:M,factory:M.\u0275fac,providedIn:"root"})}}return M})()},3939:(o,s,r)=>{"use strict";r.d(s,{Q:()=>a});var i=r(3107);let a=(()=>{class c{get exactMatchOptions(){return{paths:"exact",fragment:"ignored",matrixParams:"ignored",queryParams:"exact"}}get subsetMatchOptions(){return{paths:"subset",fragment:"ignored",matrixParams:"ignored",queryParams:"subset"}}randomId(w=10){let T="";for(let S=0;S<10;S++)T+="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789".charAt(Math.floor(62*Math.random()));return T}static{this.\u0275fac=function(C){return new(C||c)}}static{this.\u0275prov=i.jDH({token:c,factory:c.\u0275fac,providedIn:"root"})}}return c})()},4482:(o,s,r)=>{"use strict";r.d(s,{v:()=>y});var i=r(3024),a=r(8447),c=r(3107);let y=(()=>{class w{constructor(){this.publicKeySubject=new a.B,this.previousPublicKey=null,this.initializeNostrLogin(),this.setupEventListeners()}initializeNostrLogin(){(0,i.Ts)({theme:"ocean",noBanner:!0,title:"Angor Hub",onAuth:(T,S)=>{this.handleAuthSuccess(T,S)}})}setupEventListeners(){document.addEventListener("nlAuth",this.handleNlAuthEvent.bind(this)),document.addEventListener("nlLogout",this.handleNlLogoutEvent.bind(this)),document.addEventListener("nlDarkMode",this.handleNlDarkModeEvent.bind(this)),document.addEventListener("nlLaunch",this.handleNlLaunchEvent.bind(this))}handleNlLogoutEvent(){console.log("Logout event detected"),this.handleLogout()}handleNlAuthEvent(T){const{type:S,pubkey:M,options:O}=T.detail;switch(S){case"login":console.log("User logged in:",M),this.handleAuthSuccess(M,O);break;case"signup":console.log("User signed up:",M),this.handleSignupSuccess(M,O);break;case"logout":console.log("User logged out"),this.handleLogout();break;case"switch-account":console.log("User switched account:",M),this.handleAccountSwitch(M,O);break;default:console.warn("Unknown nlAuth event type:",S)}this.previousPublicKey&&this.previousPublicKey!==M&&(console.log("Account switched to:",M),this.handleAccountSwitch(M,O)),this.previousPublicKey=M}handleAuthSuccess(T,S){console.log("Authenticated successfully with public key:",T),this.publicKeySubject.next(T)}handleSignupSuccess(T,S){console.log("Signup successful with public key:",T),this.publicKeySubject.next(T)}handleAccountSwitch(T,S){console.log("Account switched to:",T),this.publicKeySubject.next(T),window.location.reload()}handleLogout(){console.log("Logged out"),this.publicKeySubject.next("")}handleNlDarkModeEvent(T){const S=T.detail;console.log("Dark mode changed to:",S?"enabled":"disabled"),this.updateDarkMode(S)}handleNlLaunchEvent(T){const S=T.detail||"welcome";console.log(`Launching Nostr login screen: ${S}`),this.launchScreen(S)}launchScreen(T){(0,i.ql)(T)}updateDarkMode(T){document.body.classList.toggle("dark-mode",T),console.log("Dark mode is now "+(T?"enabled":"disabled"))}getPublicKeyObservable(){return this.publicKeySubject.asObservable()}launchWelcomeScreen(){(0,i.ql)("welcome")}launchSignupScreen(){(0,i.ql)("welcome-signup")}launchLoginScreen(){(0,i.ql)("welcome-login")}switchAccount(){document.dispatchEvent(new CustomEvent("nlLaunch",{detail:"switch-account"}))}logout(){document.dispatchEvent(new Event("nlLogout"))}toggleDarkMode(T){document.dispatchEvent(new CustomEvent("nlDarkMode",{detail:T}))}static{this.\u0275fac=function(S){return new(S||w)}}static{this.\u0275prov=c.jDH({token:w,factory:w.\u0275fac,providedIn:"root"})}}return w})()},3125:(o,s,r)=>{"use strict";r.d(s,{b:()=>T});var i=r(3014),a=r(3107),c=r(5492),y=r(1217),w=r(8447),C=r(4460);let T=(()=>{class S{constructor(O,L){this.document=O,this.platformId=L,this.pool=new c.lo,this.relays=[],this.maxRetries=10,this.retryDelay=15e3,this.eventSubject=new y.t(null),this.relaysSubject=new y.t([]),this.destroy$=new w.B,this.initializeRelays(),this.setupVisibilityHandling()}initializeRelays(){this.relays=this.loadRelaysFromLocalStorage(),this.connectToRelays(),this.relaysSubject.next(this.relays)}loadRelaysFromLocalStorage(){const O=JSON.parse(localStorage.getItem("nostrRelays")||"[]");return O.length>0?O.map(Z=>({...Z,connected:!1,retries:0,retryTimeout:null,ws:void 0})):[{url:"wss://relay.primal.net",connected:!1,retries:0,retryTimeout:null,accessType:"read-write"},{url:"wss://nos.lol",connected:!1,retries:0,retryTimeout:null,accessType:"read-write"},{url:"wss://relay.angor.io",connected:!1,retries:0,retryTimeout:null,accessType:"read-write"},{url:"wss://relay2.angor.io",connected:!1,retries:0,retryTimeout:null,accessType:"read-write"}]}saveRelaysToLocalStorage(){const O=this.relays.map(L=>({url:L.url,accessType:L.accessType,connected:L.connected,retries:L.retries,retryTimeout:L.retryTimeout}));localStorage.setItem("nostrRelays",JSON.stringify(O)),this.relaysSubject.next(this.relays)}connectToRelay(O){O.connected||(O.ws=new WebSocket(O.url),O.ws.onopen=()=>{O.connected=!0,O.retries=0,clearTimeout(O.retryTimeout),this.saveRelaysToLocalStorage()},O.ws.onerror=()=>this.handleRelayError(O),O.ws.onclose=()=>{O.connected=!1,this.handleRelayError(O)},O.ws.onmessage=({data:L})=>{try{const Z=JSON.parse("string"==typeof L?L:L.toString("utf-8"));this.eventSubject.next(Z)}catch(Z){console.warn("Error parsing WebSocket message:",Z)}})}handleRelayError(O){O.retries>=this.maxRetries?console.warn(`Max retries reached for relay: ${O.url}. No further attempts will be made.`):(O.retries++,O.retryTimeout=setTimeout(()=>this.connectToRelay(O),this.retryDelay*O.retries))}connectToRelays(){this.relays.forEach(O=>!O.connected&&this.connectToRelay(O))}ensureConnectedRelays(){var O=this;return(0,i.A)(function*(){return O.connectToRelays(),new Promise(L=>{const Z=setInterval(()=>{O.getConnectedRelays().length>0&&(clearInterval(Z),L())},1e3)})})()}setupVisibilityHandling(){(0,C.UE)(this.platformId)&&(this.document.addEventListener("visibilitychange",()=>{"visible"===this.document.visibilityState&&this.connectToRelays()}),window.addEventListener("beforeunload",()=>{this.relays.forEach(O=>O.ws?.close())}))}getConnectedRelays(){return this.relays.filter(O=>O.connected).map(O=>O.url)}getRelays(){return this.relaysSubject.asObservable()}publishEventToWriteRelays(O){var L=this;return(0,i.A)(function*(){const Z=L.relays.filter(q=>["write","read-write"].includes(q.accessType)&&q.connected);if(!Z.length)throw new Error("No connected write relays available");try{return yield Promise.any(Z.map(q=>L.pool.publish([q.url],O))),L.eventSubject.next(O),O}catch(q){throw console.error("Failed to publish event to relays:",q),q}})()}addRelay(O,L="read-write"){if(!this.relays.some(Z=>Z.url===O)){const Z={url:O,connected:!1,retries:0,retryTimeout:null,accessType:L};this.relays.push(Z),this.connectToRelay(Z),this.saveRelaysToLocalStorage()}}removeRelay(O){const L=this.relays.find(Z=>Z.url===O);L&&(L.ws?.close(),clearTimeout(L.retryTimeout)),this.relays=this.relays.filter(Z=>Z.url!==O),this.saveRelaysToLocalStorage()}removeAllCustomRelays(){const O=["wss://relay.angor.io","wss://relay2.angor.io"];this.relays.forEach(L=>{O.includes(L.url)||(L.ws?.close(),clearTimeout(L.retryTimeout))}),this.relays=this.relays.filter(L=>O.includes(L.url)),this.saveRelaysToLocalStorage()}updateRelayAccessType(O,L){const Z=this.relays.find(q=>q.url===O);Z&&(Z.accessType=L,this.saveRelaysToLocalStorage())}getPool(){return this.pool}getEventStream(){return this.eventSubject.asObservable()}ngOnDestroy(){this.destroy$.next(),this.destroy$.complete(),this.relays.forEach(O=>O.ws?.close())}static{this.\u0275fac=function(L){return new(L||S)(a.KVO(C.qQ,8),a.KVO(a.Agw))}}static{this.\u0275prov=a.jDH({token:S,factory:S.\u0275fac,providedIn:"root"})}}return S})()},8078:(o,s,r)=>{"use strict";r.d(s,{A:()=>yd});var i={};r.r(i),r.d(i,{OG:()=>Xs,My:()=>ha,Ph:()=>oo,lX:()=>Fn,Id:()=>so,fg:()=>vo,qj:()=>Qi,aT:()=>Wo,lq:()=>Sr,z:()=>Oi,Q5:()=>Vs});var a=r(3014),c=r(8378),y=r(2226),w=r(871),C=r(5492);function M(I){if(!Number.isSafeInteger(I)||I<0)throw new Error(`Wrong positive integer: ${I}`)}function Z(I,...P){if(!function L(I){return I instanceof Uint8Array||null!=I&&"object"==typeof I&&"Uint8Array"===I.constructor.name}(I))throw new Error("Expected Uint8Array");if(P.length>0&&!P.includes(I.length))throw new Error(`Expected Uint8Array of length ${P}, not of length=${I.length}`)}function q(I){if("function"!=typeof I||"function"!=typeof I.create)throw new Error("Hash should be wrapped by utils.wrapConstructor");M(I.outputLen),M(I.blockLen)}function re(I,P=!0){if(I.destroyed)throw new Error("Hash instance has been destroyed");if(P&&I.finished)throw new Error("Hash#digest() has already been called")}r(4704),"abandon\nability\nable\nabout\nabove\nabsent\nabsorb\nabstract\nabsurd\nabuse\naccess\naccident\naccount\naccuse\nachieve\nacid\nacoustic\nacquire\nacross\nact\naction\nactor\nactress\nactual\nadapt\nadd\naddict\naddress\nadjust\nadmit\nadult\nadvance\nadvice\naerobic\naffair\nafford\nafraid\nagain\nage\nagent\nagree\nahead\naim\nair\nairport\naisle\nalarm\nalbum\nalcohol\nalert\nalien\nall\nalley\nallow\nalmost\nalone\nalpha\nalready\nalso\nalter\nalways\namateur\namazing\namong\namount\namused\nanalyst\nanchor\nancient\nanger\nangle\nangry\nanimal\nankle\nannounce\nannual\nanother\nanswer\nantenna\nantique\nanxiety\nany\napart\napology\nappear\napple\napprove\napril\narch\narctic\narea\narena\nargue\narm\narmed\narmor\narmy\naround\narrange\narrest\narrive\narrow\nart\nartefact\nartist\nartwork\nask\naspect\nassault\nasset\nassist\nassume\nasthma\nathlete\natom\nattack\nattend\nattitude\nattract\nauction\naudit\naugust\naunt\nauthor\nauto\nautumn\naverage\navocado\navoid\nawake\naware\naway\nawesome\nawful\nawkward\naxis\nbaby\nbachelor\nbacon\nbadge\nbag\nbalance\nbalcony\nball\nbamboo\nbanana\nbanner\nbar\nbarely\nbargain\nbarrel\nbase\nbasic\nbasket\nbattle\nbeach\nbean\nbeauty\nbecause\nbecome\nbeef\nbefore\nbegin\nbehave\nbehind\nbelieve\nbelow\nbelt\nbench\nbenefit\nbest\nbetray\nbetter\nbetween\nbeyond\nbicycle\nbid\nbike\nbind\nbiology\nbird\nbirth\nbitter\nblack\nblade\nblame\nblanket\nblast\nbleak\nbless\nblind\nblood\nblossom\nblouse\nblue\nblur\nblush\nboard\nboat\nbody\nboil\nbomb\nbone\nbonus\nbook\nboost\nborder\nboring\nborrow\nboss\nbottom\nbounce\nbox\nboy\nbracket\nbrain\nbrand\nbrass\nbrave\nbread\nbreeze\nbrick\nbridge\nbrief\nbright\nbring\nbrisk\nbroccoli\nbroken\nbronze\nbroom\nbrother\nbrown\nbrush\nbubble\nbuddy\nbudget\nbuffalo\nbuild\nbulb\nbulk\nbullet\nbundle\nbunker\nburden\nburger\nburst\nbus\nbusiness\nbusy\nbutter\nbuyer\nbuzz\ncabbage\ncabin\ncable\ncactus\ncage\ncake\ncall\ncalm\ncamera\ncamp\ncan\ncanal\ncancel\ncandy\ncannon\ncanoe\ncanvas\ncanyon\ncapable\ncapital\ncaptain\ncar\ncarbon\ncard\ncargo\ncarpet\ncarry\ncart\ncase\ncash\ncasino\ncastle\ncasual\ncat\ncatalog\ncatch\ncategory\ncattle\ncaught\ncause\ncaution\ncave\nceiling\ncelery\ncement\ncensus\ncentury\ncereal\ncertain\nchair\nchalk\nchampion\nchange\nchaos\nchapter\ncharge\nchase\nchat\ncheap\ncheck\ncheese\nchef\ncherry\nchest\nchicken\nchief\nchild\nchimney\nchoice\nchoose\nchronic\nchuckle\nchunk\nchurn\ncigar\ncinnamon\ncircle\ncitizen\ncity\ncivil\nclaim\nclap\nclarify\nclaw\nclay\nclean\nclerk\nclever\nclick\nclient\ncliff\nclimb\nclinic\nclip\nclock\nclog\nclose\ncloth\ncloud\nclown\nclub\nclump\ncluster\nclutch\ncoach\ncoast\ncoconut\ncode\ncoffee\ncoil\ncoin\ncollect\ncolor\ncolumn\ncombine\ncome\ncomfort\ncomic\ncommon\ncompany\nconcert\nconduct\nconfirm\ncongress\nconnect\nconsider\ncontrol\nconvince\ncook\ncool\ncopper\ncopy\ncoral\ncore\ncorn\ncorrect\ncost\ncotton\ncouch\ncountry\ncouple\ncourse\ncousin\ncover\ncoyote\ncrack\ncradle\ncraft\ncram\ncrane\ncrash\ncrater\ncrawl\ncrazy\ncream\ncredit\ncreek\ncrew\ncricket\ncrime\ncrisp\ncritic\ncrop\ncross\ncrouch\ncrowd\ncrucial\ncruel\ncruise\ncrumble\ncrunch\ncrush\ncry\ncrystal\ncube\nculture\ncup\ncupboard\ncurious\ncurrent\ncurtain\ncurve\ncushion\ncustom\ncute\ncycle\ndad\ndamage\ndamp\ndance\ndanger\ndaring\ndash\ndaughter\ndawn\nday\ndeal\ndebate\ndebris\ndecade\ndecember\ndecide\ndecline\ndecorate\ndecrease\ndeer\ndefense\ndefine\ndefy\ndegree\ndelay\ndeliver\ndemand\ndemise\ndenial\ndentist\ndeny\ndepart\ndepend\ndeposit\ndepth\ndeputy\nderive\ndescribe\ndesert\ndesign\ndesk\ndespair\ndestroy\ndetail\ndetect\ndevelop\ndevice\ndevote\ndiagram\ndial\ndiamond\ndiary\ndice\ndiesel\ndiet\ndiffer\ndigital\ndignity\ndilemma\ndinner\ndinosaur\ndirect\ndirt\ndisagree\ndiscover\ndisease\ndish\ndismiss\ndisorder\ndisplay\ndistance\ndivert\ndivide\ndivorce\ndizzy\ndoctor\ndocument\ndog\ndoll\ndolphin\ndomain\ndonate\ndonkey\ndonor\ndoor\ndose\ndouble\ndove\ndraft\ndragon\ndrama\ndrastic\ndraw\ndream\ndress\ndrift\ndrill\ndrink\ndrip\ndrive\ndrop\ndrum\ndry\nduck\ndumb\ndune\nduring\ndust\ndutch\nduty\ndwarf\ndynamic\neager\neagle\nearly\nearn\nearth\neasily\neast\neasy\necho\necology\neconomy\nedge\nedit\neducate\neffort\negg\neight\neither\nelbow\nelder\nelectric\nelegant\nelement\nelephant\nelevator\nelite\nelse\nembark\nembody\nembrace\nemerge\nemotion\nemploy\nempower\nempty\nenable\nenact\nend\nendless\nendorse\nenemy\nenergy\nenforce\nengage\nengine\nenhance\nenjoy\nenlist\nenough\nenrich\nenroll\nensure\nenter\nentire\nentry\nenvelope\nepisode\nequal\nequip\nera\nerase\nerode\nerosion\nerror\nerupt\nescape\nessay\nessence\nestate\neternal\nethics\nevidence\nevil\nevoke\nevolve\nexact\nexample\nexcess\nexchange\nexcite\nexclude\nexcuse\nexecute\nexercise\nexhaust\nexhibit\nexile\nexist\nexit\nexotic\nexpand\nexpect\nexpire\nexplain\nexpose\nexpress\nextend\nextra\neye\neyebrow\nfabric\nface\nfaculty\nfade\nfaint\nfaith\nfall\nfalse\nfame\nfamily\nfamous\nfan\nfancy\nfantasy\nfarm\nfashion\nfat\nfatal\nfather\nfatigue\nfault\nfavorite\nfeature\nfebruary\nfederal\nfee\nfeed\nfeel\nfemale\nfence\nfestival\nfetch\nfever\nfew\nfiber\nfiction\nfield\nfigure\nfile\nfilm\nfilter\nfinal\nfind\nfine\nfinger\nfinish\nfire\nfirm\nfirst\nfiscal\nfish\nfit\nfitness\nfix\nflag\nflame\nflash\nflat\nflavor\nflee\nflight\nflip\nfloat\nflock\nfloor\nflower\nfluid\nflush\nfly\nfoam\nfocus\nfog\nfoil\nfold\nfollow\nfood\nfoot\nforce\nforest\nforget\nfork\nfortune\nforum\nforward\nfossil\nfoster\nfound\nfox\nfragile\nframe\nfrequent\nfresh\nfriend\nfringe\nfrog\nfront\nfrost\nfrown\nfrozen\nfruit\nfuel\nfun\nfunny\nfurnace\nfury\nfuture\ngadget\ngain\ngalaxy\ngallery\ngame\ngap\ngarage\ngarbage\ngarden\ngarlic\ngarment\ngas\ngasp\ngate\ngather\ngauge\ngaze\ngeneral\ngenius\ngenre\ngentle\ngenuine\ngesture\nghost\ngiant\ngift\ngiggle\nginger\ngiraffe\ngirl\ngive\nglad\nglance\nglare\nglass\nglide\nglimpse\nglobe\ngloom\nglory\nglove\nglow\nglue\ngoat\ngoddess\ngold\ngood\ngoose\ngorilla\ngospel\ngossip\ngovern\ngown\ngrab\ngrace\ngrain\ngrant\ngrape\ngrass\ngravity\ngreat\ngreen\ngrid\ngrief\ngrit\ngrocery\ngroup\ngrow\ngrunt\nguard\nguess\nguide\nguilt\nguitar\ngun\ngym\nhabit\nhair\nhalf\nhammer\nhamster\nhand\nhappy\nharbor\nhard\nharsh\nharvest\nhat\nhave\nhawk\nhazard\nhead\nhealth\nheart\nheavy\nhedgehog\nheight\nhello\nhelmet\nhelp\nhen\nhero\nhidden\nhigh\nhill\nhint\nhip\nhire\nhistory\nhobby\nhockey\nhold\nhole\nholiday\nhollow\nhome\nhoney\nhood\nhope\nhorn\nhorror\nhorse\nhospital\nhost\nhotel\nhour\nhover\nhub\nhuge\nhuman\nhumble\nhumor\nhundred\nhungry\nhunt\nhurdle\nhurry\nhurt\nhusband\nhybrid\nice\nicon\nidea\nidentify\nidle\nignore\nill\nillegal\nillness\nimage\nimitate\nimmense\nimmune\nimpact\nimpose\nimprove\nimpulse\ninch\ninclude\nincome\nincrease\nindex\nindicate\nindoor\nindustry\ninfant\ninflict\ninform\ninhale\ninherit\ninitial\ninject\ninjury\ninmate\ninner\ninnocent\ninput\ninquiry\ninsane\ninsect\ninside\ninspire\ninstall\nintact\ninterest\ninto\ninvest\ninvite\ninvolve\niron\nisland\nisolate\nissue\nitem\nivory\njacket\njaguar\njar\njazz\njealous\njeans\njelly\njewel\njob\njoin\njoke\njourney\njoy\njudge\njuice\njump\njungle\njunior\njunk\njust\nkangaroo\nkeen\nkeep\nketchup\nkey\nkick\nkid\nkidney\nkind\nkingdom\nkiss\nkit\nkitchen\nkite\nkitten\nkiwi\nknee\nknife\nknock\nknow\nlab\nlabel\nlabor\nladder\nlady\nlake\nlamp\nlanguage\nlaptop\nlarge\nlater\nlatin\nlaugh\nlaundry\nlava\nlaw\nlawn\nlawsuit\nlayer\nlazy\nleader\nleaf\nlearn\nleave\nlecture\nleft\nleg\nlegal\nlegend\nleisure\nlemon\nlend\nlength\nlens\nleopard\nlesson\nletter\nlevel\nliar\nliberty\nlibrary\nlicense\nlife\nlift\nlight\nlike\nlimb\nlimit\nlink\nlion\nliquid\nlist\nlittle\nlive\nlizard\nload\nloan\nlobster\nlocal\nlock\nlogic\nlonely\nlong\nloop\nlottery\nloud\nlounge\nlove\nloyal\nlucky\nluggage\nlumber\nlunar\nlunch\nluxury\nlyrics\nmachine\nmad\nmagic\nmagnet\nmaid\nmail\nmain\nmajor\nmake\nmammal\nman\nmanage\nmandate\nmango\nmansion\nmanual\nmaple\nmarble\nmarch\nmargin\nmarine\nmarket\nmarriage\nmask\nmass\nmaster\nmatch\nmaterial\nmath\nmatrix\nmatter\nmaximum\nmaze\nmeadow\nmean\nmeasure\nmeat\nmechanic\nmedal\nmedia\nmelody\nmelt\nmember\nmemory\nmention\nmenu\nmercy\nmerge\nmerit\nmerry\nmesh\nmessage\nmetal\nmethod\nmiddle\nmidnight\nmilk\nmillion\nmimic\nmind\nminimum\nminor\nminute\nmiracle\nmirror\nmisery\nmiss\nmistake\nmix\nmixed\nmixture\nmobile\nmodel\nmodify\nmom\nmoment\nmonitor\nmonkey\nmonster\nmonth\nmoon\nmoral\nmore\nmorning\nmosquito\nmother\nmotion\nmotor\nmountain\nmouse\nmove\nmovie\nmuch\nmuffin\nmule\nmultiply\nmuscle\nmuseum\nmushroom\nmusic\nmust\nmutual\nmyself\nmystery\nmyth\nnaive\nname\nnapkin\nnarrow\nnasty\nnation\nnature\nnear\nneck\nneed\nnegative\nneglect\nneither\nnephew\nnerve\nnest\nnet\nnetwork\nneutral\nnever\nnews\nnext\nnice\nnight\nnoble\nnoise\nnominee\nnoodle\nnormal\nnorth\nnose\nnotable\nnote\nnothing\nnotice\nnovel\nnow\nnuclear\nnumber\nnurse\nnut\noak\nobey\nobject\noblige\nobscure\nobserve\nobtain\nobvious\noccur\nocean\noctober\nodor\noff\noffer\noffice\noften\noil\nokay\nold\nolive\nolympic\nomit\nonce\none\nonion\nonline\nonly\nopen\nopera\nopinion\noppose\noption\norange\norbit\norchard\norder\nordinary\norgan\norient\noriginal\norphan\nostrich\nother\noutdoor\nouter\noutput\noutside\noval\noven\nover\nown\nowner\noxygen\noyster\nozone\npact\npaddle\npage\npair\npalace\npalm\npanda\npanel\npanic\npanther\npaper\nparade\nparent\npark\nparrot\nparty\npass\npatch\npath\npatient\npatrol\npattern\npause\npave\npayment\npeace\npeanut\npear\npeasant\npelican\npen\npenalty\npencil\npeople\npepper\nperfect\npermit\nperson\npet\nphone\nphoto\nphrase\nphysical\npiano\npicnic\npicture\npiece\npig\npigeon\npill\npilot\npink\npioneer\npipe\npistol\npitch\npizza\nplace\nplanet\nplastic\nplate\nplay\nplease\npledge\npluck\nplug\nplunge\npoem\npoet\npoint\npolar\npole\npolice\npond\npony\npool\npopular\nportion\nposition\npossible\npost\npotato\npottery\npoverty\npowder\npower\npractice\npraise\npredict\nprefer\nprepare\npresent\npretty\nprevent\nprice\npride\nprimary\nprint\npriority\nprison\nprivate\nprize\nproblem\nprocess\nproduce\nprofit\nprogram\nproject\npromote\nproof\nproperty\nprosper\nprotect\nproud\nprovide\npublic\npudding\npull\npulp\npulse\npumpkin\npunch\npupil\npuppy\npurchase\npurity\npurpose\npurse\npush\nput\npuzzle\npyramid\nquality\nquantum\nquarter\nquestion\nquick\nquit\nquiz\nquote\nrabbit\nraccoon\nrace\nrack\nradar\nradio\nrail\nrain\nraise\nrally\nramp\nranch\nrandom\nrange\nrapid\nrare\nrate\nrather\nraven\nraw\nrazor\nready\nreal\nreason\nrebel\nrebuild\nrecall\nreceive\nrecipe\nrecord\nrecycle\nreduce\nreflect\nreform\nrefuse\nregion\nregret\nregular\nreject\nrelax\nrelease\nrelief\nrely\nremain\nremember\nremind\nremove\nrender\nrenew\nrent\nreopen\nrepair\nrepeat\nreplace\nreport\nrequire\nrescue\nresemble\nresist\nresource\nresponse\nresult\nretire\nretreat\nreturn\nreunion\nreveal\nreview\nreward\nrhythm\nrib\nribbon\nrice\nrich\nride\nridge\nrifle\nright\nrigid\nring\nriot\nripple\nrisk\nritual\nrival\nriver\nroad\nroast\nrobot\nrobust\nrocket\nromance\nroof\nrookie\nroom\nrose\nrotate\nrough\nround\nroute\nroyal\nrubber\nrude\nrug\nrule\nrun\nrunway\nrural\nsad\nsaddle\nsadness\nsafe\nsail\nsalad\nsalmon\nsalon\nsalt\nsalute\nsame\nsample\nsand\nsatisfy\nsatoshi\nsauce\nsausage\nsave\nsay\nscale\nscan\nscare\nscatter\nscene\nscheme\nschool\nscience\nscissors\nscorpion\nscout\nscrap\nscreen\nscript\nscrub\nsea\nsearch\nseason\nseat\nsecond\nsecret\nsection\nsecurity\nseed\nseek\nsegment\nselect\nsell\nseminar\nsenior\nsense\nsentence\nseries\nservice\nsession\nsettle\nsetup\nseven\nshadow\nshaft\nshallow\nshare\nshed\nshell\nsheriff\nshield\nshift\nshine\nship\nshiver\nshock\nshoe\nshoot\nshop\nshort\nshoulder\nshove\nshrimp\nshrug\nshuffle\nshy\nsibling\nsick\nside\nsiege\nsight\nsign\nsilent\nsilk\nsilly\nsilver\nsimilar\nsimple\nsince\nsing\nsiren\nsister\nsituate\nsix\nsize\nskate\nsketch\nski\nskill\nskin\nskirt\nskull\nslab\nslam\nsleep\nslender\nslice\nslide\nslight\nslim\nslogan\nslot\nslow\nslush\nsmall\nsmart\nsmile\nsmoke\nsmooth\nsnack\nsnake\nsnap\nsniff\nsnow\nsoap\nsoccer\nsocial\nsock\nsoda\nsoft\nsolar\nsoldier\nsolid\nsolution\nsolve\nsomeone\nsong\nsoon\nsorry\nsort\nsoul\nsound\nsoup\nsource\nsouth\nspace\nspare\nspatial\nspawn\nspeak\nspecial\nspeed\nspell\nspend\nsphere\nspice\nspider\nspike\nspin\nspirit\nsplit\nspoil\nsponsor\nspoon\nsport\nspot\nspray\nspread\nspring\nspy\nsquare\nsqueeze\nsquirrel\nstable\nstadium\nstaff\nstage\nstairs\nstamp\nstand\nstart\nstate\nstay\nsteak\nsteel\nstem\nstep\nstereo\nstick\nstill\nsting\nstock\nstomach\nstone\nstool\nstory\nstove\nstrategy\nstreet\nstrike\nstrong\nstruggle\nstudent\nstuff\nstumble\nstyle\nsubject\nsubmit\nsubway\nsuccess\nsuch\nsudden\nsuffer\nsugar\nsuggest\nsuit\nsummer\nsun\nsunny\nsunset\nsuper\nsupply\nsupreme\nsure\nsurface\nsurge\nsurprise\nsurround\nsurvey\nsuspect\nsustain\nswallow\nswamp\nswap\nswarm\nswear\nsweet\nswift\nswim\nswing\nswitch\nsword\nsymbol\nsymptom\nsyrup\nsystem\ntable\ntackle\ntag\ntail\ntalent\ntalk\ntank\ntape\ntarget\ntask\ntaste\ntattoo\ntaxi\nteach\nteam\ntell\nten\ntenant\ntennis\ntent\nterm\ntest\ntext\nthank\nthat\ntheme\nthen\ntheory\nthere\nthey\nthing\nthis\nthought\nthree\nthrive\nthrow\nthumb\nthunder\nticket\ntide\ntiger\ntilt\ntimber\ntime\ntiny\ntip\ntired\ntissue\ntitle\ntoast\ntobacco\ntoday\ntoddler\ntoe\ntogether\ntoilet\ntoken\ntomato\ntomorrow\ntone\ntongue\ntonight\ntool\ntooth\ntop\ntopic\ntopple\ntorch\ntornado\ntortoise\ntoss\ntotal\ntourist\ntoward\ntower\ntown\ntoy\ntrack\ntrade\ntraffic\ntragic\ntrain\ntransfer\ntrap\ntrash\ntravel\ntray\ntreat\ntree\ntrend\ntrial\ntribe\ntrick\ntrigger\ntrim\ntrip\ntrophy\ntrouble\ntruck\ntrue\ntruly\ntrumpet\ntrust\ntruth\ntry\ntube\ntuition\ntumble\ntuna\ntunnel\nturkey\nturn\nturtle\ntwelve\ntwenty\ntwice\ntwin\ntwist\ntwo\ntype\ntypical\nugly\numbrella\nunable\nunaware\nuncle\nuncover\nunder\nundo\nunfair\nunfold\nunhappy\nuniform\nunique\nunit\nuniverse\nunknown\nunlock\nuntil\nunusual\nunveil\nupdate\nupgrade\nuphold\nupon\nupper\nupset\nurban\nurge\nusage\nuse\nused\nuseful\nuseless\nusual\nutility\nvacant\nvacuum\nvague\nvalid\nvalley\nvalve\nvan\nvanish\nvapor\nvarious\nvast\nvault\nvehicle\nvelvet\nvendor\nventure\nvenue\nverb\nverify\nversion\nvery\nvessel\nveteran\nviable\nvibrant\nvicious\nvictory\nvideo\nview\nvillage\nvintage\nviolin\nvirtual\nvirus\nvisa\nvisit\nvisual\nvital\nvivid\nvocal\nvoice\nvoid\nvolcano\nvolume\nvote\nvoyage\nwage\nwagon\nwait\nwalk\nwall\nwalnut\nwant\nwarfare\nwarm\nwarrior\nwash\nwasp\nwaste\nwater\nwave\nway\nwealth\nweapon\nwear\nweasel\nweather\nweb\nwedding\nweekend\nweird\nwelcome\nwest\nwet\nwhale\nwhat\nwheat\nwheel\nwhen\nwhere\nwhip\nwhisper\nwide\nwidth\nwife\nwild\nwill\nwin\nwindow\nwine\nwing\nwink\nwinner\nwinter\nwire\nwisdom\nwise\nwish\nwitness\nwolf\nwoman\nwonder\nwood\nwool\nword\nwork\nworld\nworry\nworth\nwrap\nwreck\nwrestle\nwrist\nwrite\nwrong\nyard\nyear\nyellow\nyou\nyoung\nyouth\nzebra\nzero\nzone\nzoo".split("\n");const xe=I=>new DataView(I.buffer,I.byteOffset,I.byteLength);if(68!==new Uint8Array(new Uint32Array([287454020]).buffer)[0])throw new Error("Non little-endian hardware is not supported");function bn(I){if("string"==typeof I&&(I=function gn(I){if("string"!=typeof I)throw new Error("utf8ToBytes expected string, got "+typeof I);return new Uint8Array((new TextEncoder).encode(I))}(I)),!function Oe(I){return I instanceof Uint8Array||null!=I&&"object"==typeof I&&"Uint8Array"===I.constructor.name}(I))throw new Error("expected Uint8Array, got "+typeof I);return I}class yn{clone(){return this._cloneInto()}}const qe={}.toString;function ze(I){const P=oe=>I().update(bn(oe)).digest(),$=I();return P.outputLen=$.outputLen,P.blockLen=$.blockLen,P.create=()=>I(),P}class Ze extends yn{constructor(P,$){super(),this.finished=!1,this.destroyed=!1,q(P);const oe=bn($);if(this.iHash=P.create(),"function"!=typeof this.iHash.update)throw new Error("Expected instance of class which extends utils.Hash");this.blockLen=this.iHash.blockLen,this.outputLen=this.iHash.outputLen;const Ae=this.blockLen,je=new Uint8Array(Ae);je.set(oe.length>Ae?P.create().update(oe).digest():oe);for(let pt=0;ptnew Ze(I,P).update($).digest();it.create=(I,P)=>new Ze(I,P);class Mt extends yn{constructor(P,$,oe,Ae){super(),this.blockLen=P,this.outputLen=$,this.padOffset=oe,this.isLE=Ae,this.finished=!1,this.length=0,this.pos=0,this.destroyed=!1,this.buffer=new Uint8Array(P),this.view=xe(this.buffer)}update(P){re(this);const{view:$,buffer:oe,blockLen:Ae}=this,je=(P=bn(P)).length;for(let pt=0;ptAe-pt&&(this.process(oe,0),pt=0);for(let Qt=pt;Qt>Ae&je),It=Number($&je),ln=oe?0:4;I.setUint32(P+(oe?4:0),pt,oe),I.setUint32(P+ln,It,oe)})(oe,Ae-8,BigInt(8*this.length),je),this.process(oe,0);const It=xe(P),zt=this.outputLen;if(zt%4)throw new Error("_sha2: outputLen should be aligned to 32bit");const ln=zt/4,An=this.get();if(ln>An.length)throw new Error("_sha2: outputLen bigger than state");for(let Qt=0;Qt>rt&Kt)}:{h:0|Number(I>>rt&Kt),l:0|Number(I&Kt)}}const xn_split=function en(I,P=!1){let $=new Uint32Array(I.length),oe=new Uint32Array(I.length);for(let Ae=0;AeI>>>$,xn_shrSL=(I,P,$)=>I<<32-$|P>>>$,xn_rotrSH=(I,P,$)=>I>>>$|P<<32-$,xn_rotrSL=(I,P,$)=>I<<32-$|P>>>$,xn_rotrBH=(I,P,$)=>I<<64-$|P>>>$-32,xn_rotrBL=(I,P,$)=>I>>>$-32|P<<64-$,xn_add=function ft(I,P,$,oe){const Ae=(P>>>0)+(oe>>>0);return{h:I+$+(Ae/2**32|0)|0,l:0|Ae}},xn_add3L=(I,P,$)=>(I>>>0)+(P>>>0)+($>>>0),xn_add3H=(I,P,$,oe)=>P+$+oe+(I/2**32|0)|0,xn_add4L=(I,P,$,oe)=>(I>>>0)+(P>>>0)+($>>>0)+(oe>>>0),xn_add4H=(I,P,$,oe,Ae)=>P+$+oe+Ae+(I/2**32|0)|0,xn_add5H=(I,P,$,oe,Ae,je)=>P+$+oe+Ae+je+(I/2**32|0)|0,xn_add5L=(I,P,$,oe,Ae)=>(I>>>0)+(P>>>0)+($>>>0)+(oe>>>0)+(Ae>>>0),[Hr,Tr]=xn_split(["0x428a2f98d728ae22","0x7137449123ef65cd","0xb5c0fbcfec4d3b2f","0xe9b5dba58189dbbc","0x3956c25bf348b538","0x59f111f1b605d019","0x923f82a4af194f9b","0xab1c5ed5da6d8118","0xd807aa98a3030242","0x12835b0145706fbe","0x243185be4ee4b28c","0x550c7dc3d5ffb4e2","0x72be5d74f27b896f","0x80deb1fe3b1696b1","0x9bdc06a725c71235","0xc19bf174cf692694","0xe49b69c19ef14ad2","0xefbe4786384f25e3","0x0fc19dc68b8cd5b5","0x240ca1cc77ac9c65","0x2de92c6f592b0275","0x4a7484aa6ea6e483","0x5cb0a9dcbd41fbd4","0x76f988da831153b5","0x983e5152ee66dfab","0xa831c66d2db43210","0xb00327c898fb213f","0xbf597fc7beef0ee4","0xc6e00bf33da88fc2","0xd5a79147930aa725","0x06ca6351e003826f","0x142929670a0e6e70","0x27b70a8546d22ffc","0x2e1b21385c26c926","0x4d2c6dfc5ac42aed","0x53380d139d95b3df","0x650a73548baf63de","0x766a0abb3c77b2a8","0x81c2c92e47edaee6","0x92722c851482353b","0xa2bfe8a14cf10364","0xa81a664bbc423001","0xc24b8b70d0f89791","0xc76c51a30654be30","0xd192e819d6ef5218","0xd69906245565a910","0xf40e35855771202a","0x106aa07032bbd1b8","0x19a4c116b8d2d0c8","0x1e376c085141ab53","0x2748774cdf8eeb99","0x34b0bcb5e19b48a8","0x391c0cb3c5c95a63","0x4ed8aa4ae3418acb","0x5b9cca4f7763e373","0x682e6ff3d6b2b8a3","0x748f82ee5defb2fc","0x78a5636f43172f60","0x84c87814a1f0ab72","0x8cc702081a6439ec","0x90befffa23631e28","0xa4506cebde82bde9","0xbef9a3f7b2c67915","0xc67178f2e372532b","0xca273eceea26619c","0xd186b8c721c0c207","0xeada7dd6cde0eb1e","0xf57d4f7fee6ed178","0x06f067aa72176fba","0x0a637dc5a2c898a6","0x113f9804bef90dae","0x1b710b35131c471b","0x28db77f523047d84","0x32caab7b40c72493","0x3c9ebe0a15c9bebc","0x431d67c49c100d4c","0x4cc5d4becb3e42b6","0x597f299cfc657e2a","0x5fcb6fab3ad6faec","0x6c44198c4a475817"].map(I=>BigInt(I))),Vr=new Uint32Array(80),vt=new Uint32Array(80);class Wt extends Mt{constructor(){super(128,64,16,!1),this.Ah=1779033703,this.Al=-205731576,this.Bh=-1150833019,this.Bl=-2067093701,this.Ch=1013904242,this.Cl=-23791573,this.Dh=-1521486534,this.Dl=1595750129,this.Eh=1359893119,this.El=-1377402159,this.Fh=-1694144372,this.Fl=725511199,this.Gh=528734635,this.Gl=-79577749,this.Hh=1541459225,this.Hl=327033209}get(){const{Ah:P,Al:$,Bh:oe,Bl:Ae,Ch:je,Cl:pt,Dh:It,Dl:zt,Eh:ln,El:An,Fh:Qt,Fl:Gn,Gh:zn,Gl:nr,Hh:Mn,Hl:Hn}=this;return[P,$,oe,Ae,je,pt,It,zt,ln,An,Qt,Gn,zn,nr,Mn,Hn]}set(P,$,oe,Ae,je,pt,It,zt,ln,An,Qt,Gn,zn,nr,Mn,Hn){this.Ah=0|P,this.Al=0|$,this.Bh=0|oe,this.Bl=0|Ae,this.Ch=0|je,this.Cl=0|pt,this.Dh=0|It,this.Dl=0|zt,this.Eh=0|ln,this.El=0|An,this.Fh=0|Qt,this.Fl=0|Gn,this.Gh=0|zn,this.Gl=0|nr,this.Hh=0|Mn,this.Hl=0|Hn}process(P,$){for(let $n=0;$n<16;$n++,$+=4)Vr[$n]=P.getUint32($),vt[$n]=P.getUint32($+=4);for(let $n=16;$n<80;$n++){const Ir=0|Vr[$n-15],ir=0|vt[$n-15],Cr=xn_rotrSH(Ir,ir,1)^xn_rotrSH(Ir,ir,8)^xn_shrSH(Ir,ir,7),Gr=xn_rotrSL(Ir,ir,1)^xn_rotrSL(Ir,ir,8)^xn_shrSL(Ir,ir,7),Br=0|Vr[$n-2],ro=0|vt[$n-2],Ji=xn_rotrSH(Br,ro,19)^xn_rotrBH(Br,ro,61)^xn_shrSH(Br,ro,6),Xi=xn_rotrSL(Br,ro,19)^xn_rotrBL(Br,ro,61)^xn_shrSL(Br,ro,6),bo=xn_add4L(Gr,Xi,vt[$n-7],vt[$n-16]),To=xn_add4H(bo,Cr,Ji,Vr[$n-7],Vr[$n-16]);Vr[$n]=0|To,vt[$n]=0|bo}let{Ah:oe,Al:Ae,Bh:je,Bl:pt,Ch:It,Cl:zt,Dh:ln,Dl:An,Eh:Qt,El:Gn,Fh:zn,Fl:nr,Gh:Mn,Gl:Hn,Hh:Xn,Hl:vr}=this;for(let $n=0;$n<80;$n++){const Ir=xn_rotrSH(Qt,Gn,14)^xn_rotrSH(Qt,Gn,18)^xn_rotrBH(Qt,Gn,41),ir=xn_rotrSL(Qt,Gn,14)^xn_rotrSL(Qt,Gn,18)^xn_rotrBL(Qt,Gn,41),Cr=Qt&zn^~Qt&Mn,Br=xn_add5L(vr,ir,Gn&nr^~Gn&Hn,Tr[$n],vt[$n]),ro=xn_add5H(Br,Xn,Ir,Cr,Hr[$n],Vr[$n]),Ji=0|Br,Xi=xn_rotrSH(oe,Ae,28)^xn_rotrBH(oe,Ae,34)^xn_rotrBH(oe,Ae,39),bo=xn_rotrSL(oe,Ae,28)^xn_rotrBL(oe,Ae,34)^xn_rotrBL(oe,Ae,39),To=oe&je^oe&It^je&It,ga=Ae&pt^Ae&zt^pt&zt;Xn=0|Mn,vr=0|Hn,Mn=0|zn,Hn=0|nr,zn=0|Qt,nr=0|Gn,({h:Qt,l:Gn}=xn_add(0|ln,0|An,0|ro,0|Ji)),ln=0|It,An=0|zt,It=0|je,zt=0|pt,je=0|oe,pt=0|Ae;const _r=xn_add3L(Ji,bo,ga);oe=xn_add3H(_r,ro,Xi,To),Ae=0|_r}({h:oe,l:Ae}=xn_add(0|this.Ah,0|this.Al,0|oe,0|Ae)),({h:je,l:pt}=xn_add(0|this.Bh,0|this.Bl,0|je,0|pt)),({h:It,l:zt}=xn_add(0|this.Ch,0|this.Cl,0|It,0|zt)),({h:ln,l:An}=xn_add(0|this.Dh,0|this.Dl,0|ln,0|An)),({h:Qt,l:Gn}=xn_add(0|this.Eh,0|this.El,0|Qt,0|Gn)),({h:zn,l:nr}=xn_add(0|this.Fh,0|this.Fl,0|zn,0|nr)),({h:Mn,l:Hn}=xn_add(0|this.Gh,0|this.Gl,0|Mn,0|Hn)),({h:Xn,l:vr}=xn_add(0|this.Hh,0|this.Hl,0|Xn,0|vr)),this.set(oe,Ae,je,pt,It,zt,ln,An,Qt,Gn,zn,nr,Mn,Hn,Xn,vr)}roundClean(){Vr.fill(0),vt.fill(0)}destroy(){this.buffer.fill(0),this.set(0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0)}}const Dt=ze(()=>new Wt);function Er(I){if("string"!=typeof I)throw new TypeError("Invalid mnemonic type: "+typeof I);return I.normalize("NFKD")}function Co(I,P=""){return function Te(I,P,$,oe){const{c:Ae,dkLen:je,DK:pt,PRF:It,PRFSalt:zt}=function Ot(I,P,$,oe){q(I);const Ae=function _t(I,P){if(void 0!==P&&"[object Object]"!==qe.call(P))throw new Error("Options should be object or undefined");return Object.assign(I,P)}({dkLen:32,asyncTick:10},oe),{c:je,dkLen:pt,asyncTick:It}=Ae;if(M(je),M(pt),M(It),je<1)throw new Error("PBKDF2: iterations (c) should be >= 1");const zt=bn(P),ln=bn($),An=new Uint8Array(pt),Qt=it.create(I,zt),Gn=Qt._cloneInto().update(ln);return{c:je,dkLen:pt,asyncTick:It,DK:An,PRF:Qt,PRFSalt:Gn}}(I,P,$,oe);let ln;const An=new Uint8Array(4),Qt=xe(An),Gn=new Uint8Array(It.outputLen);for(let zn=1,nr=0;nrEr(`mnemonic${I}`))(P),{c:2048,dkLen:64})}function Ni(I){if(!Number.isSafeInteger(I)||I<0)throw new Error(`Wrong positive integer: ${I}`)}function ai(I,...P){if(!function $o(I){return I instanceof Uint8Array||null!=I&&"object"==typeof I&&"Uint8Array"===I.constructor.name}(I))throw new Error("Expected Uint8Array");if(P.length>0&&!P.includes(I.length))throw new Error(`Expected Uint8Array of length ${P}, not of length=${I.length}`)}function fo(I,P=!0){if(I.destroyed)throw new Error("Hash instance has been destroyed");if(P&&I.finished)throw new Error("Hash#digest() has already been called")}function Ii(I){return I instanceof Uint8Array||null!=I&&"object"==typeof I&&"Uint8Array"===I.constructor.name}const Io=I=>new DataView(I.buffer,I.byteOffset,I.byteLength),tt=(I,P)=>I<<32-P|I>>>P;if(68!==new Uint8Array(new Uint32Array([287454020]).buffer)[0])throw new Error("Non little-endian hardware is not supported");const ht=Array.from({length:256},(I,P)=>P.toString(16).padStart(2,"0")),Ye={_0:48,_9:57,_A:65,_F:70,_a:97,_f:102};function Ne(I){return I>=Ye._0&&I<=Ye._9?I-Ye._0:I>=Ye._A&&I<=Ye._F?I-(Ye._A-10):I>=Ye._a&&I<=Ye._f?I-(Ye._a-10):void 0}function Dn(I){if("string"!=typeof I)throw new Error("utf8ToBytes expected string, got "+typeof I);return new Uint8Array((new TextEncoder).encode(I))}function Cn(I){if("string"==typeof I&&(I=Dn(I)),!Ii(I))throw new Error("expected Uint8Array, got "+typeof I);return I}function Nn(...I){let P=0;for(let oe=0;oeI().update(Cn(oe)).digest(),$=I();return P.outputLen=$.outputLen,P.blockLen=$.blockLen,P.create=()=>I(),P}class Mi extends jn{constructor(P,$){super(),this.finished=!1,this.destroyed=!1,function qo(I){if("function"!=typeof I||"function"!=typeof I.create)throw new Error("Hash should be wrapped by utils.wrapConstructor");Ni(I.outputLen),Ni(I.blockLen)}(P);const oe=Cn($);if(this.iHash=P.create(),"function"!=typeof this.iHash.update)throw new Error("Expected instance of class which extends utils.Hash");this.blockLen=this.iHash.blockLen,this.outputLen=this.iHash.outputLen;const Ae=this.blockLen,je=new Uint8Array(Ae);je.set(oe.length>Ae?P.create().update(oe).digest():oe);for(let pt=0;ptnew Mi(I,P).update($).digest();Or.create=(I,P)=>new Mi(I,P);class Pr extends jn{constructor(P,$,oe,Ae){super(),this.blockLen=P,this.outputLen=$,this.padOffset=oe,this.isLE=Ae,this.finished=!1,this.length=0,this.pos=0,this.destroyed=!1,this.buffer=new Uint8Array(P),this.view=Io(this.buffer)}update(P){fo(this);const{view:$,buffer:oe,blockLen:Ae}=this,je=(P=Cn(P)).length;for(let pt=0;ptAe-pt&&(this.process(oe,0),pt=0);for(let Qt=pt;Qt>Ae&je),It=Number($&je),ln=oe?0:4;I.setUint32(P+(oe?4:0),pt,oe),I.setUint32(P+ln,It,oe)})(oe,Ae-8,BigInt(8*this.length),je),this.process(oe,0);const It=Io(P),zt=this.outputLen;if(zt%4)throw new Error("_sha2: outputLen should be aligned to 32bit");const ln=zt/4,An=this.get();if(ln>An.length)throw new Error("_sha2: outputLen bigger than state");for(let Qt=0;QtP);let sa=[es],Li=[es.map(I=>(9*I+5)%16)];for(let I=0;I<4;I++)for(let P of[sa,Li])P.push(P[I].map($=>Do[$]));const bi=[[11,14,15,12,5,8,7,9,11,13,14,15,6,7,9,8],[12,13,11,15,6,9,9,7,12,15,11,13,7,8,7,7],[13,15,14,11,7,7,6,8,13,14,13,12,5,5,6,9],[14,11,12,14,8,6,5,5,15,12,15,14,9,9,8,6],[15,12,13,13,9,5,8,6,14,11,12,11,8,6,5,5]].map(I=>new Uint8Array(I)),aa=sa.map((I,P)=>I.map($=>bi[P][$])),Ks=Li.map((I,P)=>I.map($=>bi[P][$])),Oo=new Uint32Array([0,1518500249,1859775393,2400959708,2840853838]),Cs=new Uint32Array([1352829926,1548603684,1836072691,2053994217,0]),No=(I,P)=>I<>>32-P;function hs(I,P,$,oe){return 0===I?P^$^oe:1===I?P&$|~P&oe:2===I?(P|~$)^oe:3===I?P&oe|$&~oe:P^($|~oe)}const Ko=new Uint32Array(16);class mo extends Pr{constructor(){super(64,20,8,!0),this.h0=1732584193,this.h1=-271733879,this.h2=-1732584194,this.h3=271733878,this.h4=-1009589776}get(){const{h0:P,h1:$,h2:oe,h3:Ae,h4:je}=this;return[P,$,oe,Ae,je]}set(P,$,oe,Ae,je){this.h0=0|P,this.h1=0|$,this.h2=0|oe,this.h3=0|Ae,this.h4=0|je}process(P,$){for(let zn=0;zn<16;zn++,$+=4)Ko[zn]=P.getUint32($,!0);let oe=0|this.h0,Ae=oe,je=0|this.h1,pt=je,It=0|this.h2,zt=It,ln=0|this.h3,An=ln,Qt=0|this.h4,Gn=Qt;for(let zn=0;zn<5;zn++){const nr=4-zn,Mn=Oo[zn],Hn=Cs[zn],Xn=sa[zn],vr=Li[zn],$n=aa[zn],Ir=Ks[zn];for(let ir=0;ir<16;ir++){const Cr=No(oe+hs(zn,je,It,ln)+Ko[Xn[ir]]+Mn,$n[ir])+Qt|0;oe=Qt,Qt=ln,ln=0|No(It,10),It=je,je=Cr}for(let ir=0;ir<16;ir++){const Cr=No(Ae+hs(nr,pt,zt,An)+Ko[vr[ir]]+Hn,Ir[ir])+Gn|0;Ae=Gn,Gn=An,An=0|No(zt,10),zt=pt,pt=Cr}}this.set(this.h1+It+An|0,this.h2+ln+Gn|0,this.h3+Qt+Ae|0,this.h4+oe+pt|0,this.h0+je+zt|0)}roundClean(){Ko.fill(0)}destroy(){this.destroyed=!0,this.buffer.fill(0),this.set(0,0,0,0,0)}}const Go=wr(()=>new mo),Rs=(I,P,$)=>I&P^~I&$,Xr=(I,P,$)=>I&P^I&$^P&$,Ds=new Uint32Array([1116352408,1899447441,3049323471,3921009573,961987163,1508970993,2453635748,2870763221,3624381080,310598401,607225278,1426881987,1925078388,2162078206,2614888103,3248222580,3835390401,4022224774,264347078,604807628,770255983,1249150122,1555081692,1996064986,2554220882,2821834349,2952996808,3210313671,3336571891,3584528711,113926993,338241895,666307205,773529912,1294757372,1396182291,1695183700,1986661051,2177026350,2456956037,2730485921,2820302411,3259730800,3345764771,3516065817,3600352804,4094571909,275423344,430227734,506948616,659060556,883997877,958139571,1322822218,1537002063,1747873779,1955562222,2024104815,2227730452,2361852424,2428436474,2756734187,3204031479,3329325298]),go=new Uint32Array([1779033703,3144134277,1013904242,2773480762,1359893119,2600822924,528734635,1541459225]),io=new Uint32Array(64);class fs extends Pr{constructor(){super(64,32,8,!1),this.A=0|go[0],this.B=0|go[1],this.C=0|go[2],this.D=0|go[3],this.E=0|go[4],this.F=0|go[5],this.G=0|go[6],this.H=0|go[7]}get(){const{A:P,B:$,C:oe,D:Ae,E:je,F:pt,G:It,H:zt}=this;return[P,$,oe,Ae,je,pt,It,zt]}set(P,$,oe,Ae,je,pt,It,zt){this.A=0|P,this.B=0|$,this.C=0|oe,this.D=0|Ae,this.E=0|je,this.F=0|pt,this.G=0|It,this.H=0|zt}process(P,$){for(let Qt=0;Qt<16;Qt++,$+=4)io[Qt]=P.getUint32($,!1);for(let Qt=16;Qt<64;Qt++){const Gn=io[Qt-15],zn=io[Qt-2],nr=tt(Gn,7)^tt(Gn,18)^Gn>>>3,Mn=tt(zn,17)^tt(zn,19)^zn>>>10;io[Qt]=Mn+io[Qt-7]+nr+io[Qt-16]|0}let{A:oe,B:Ae,C:je,D:pt,E:It,F:zt,G:ln,H:An}=this;for(let Qt=0;Qt<64;Qt++){const zn=An+(tt(It,6)^tt(It,11)^tt(It,25))+Rs(It,zt,ln)+Ds[Qt]+io[Qt]|0,Mn=(tt(oe,2)^tt(oe,13)^tt(oe,22))+Xr(oe,Ae,je)|0;An=ln,ln=zt,zt=It,It=pt+zn|0,pt=je,je=Ae,Ae=oe,oe=zn+Mn|0}oe=oe+this.A|0,Ae=Ae+this.B|0,je=je+this.C|0,pt=pt+this.D|0,It=It+this.E|0,zt=zt+this.F|0,ln=ln+this.G|0,An=An+this.H|0,this.set(oe,Ae,je,pt,It,zt,ln,An)}roundClean(){io.fill(0)}destroy(){this.set(0,0,0,0,0,0,0,0),this.buffer.fill(0)}}const Qa=wr(()=>new fs),Ao=BigInt(2**32-1),lr=BigInt(32);function As(I,P=!1){return P?{h:Number(I&Ao),l:Number(I>>lr&Ao)}:{h:0|Number(I>>lr&Ao),l:0|Number(I&Ao)}}const te_split=function Gs(I,P=!1){let $=new Uint32Array(I.length),oe=new Uint32Array(I.length);for(let Ae=0;AeI>>>$,te_shrSL=(I,P,$)=>I<<32-$|P>>>$,te_rotrSH=(I,P,$)=>I>>>$|P<<32-$,te_rotrSL=(I,P,$)=>I<<32-$|P>>>$,te_rotrBH=(I,P,$)=>I<<64-$|P>>>$-32,te_rotrBL=(I,P,$)=>I>>>$-32|P<<64-$,te_add=function Da(I,P,$,oe){const Ae=(P>>>0)+(oe>>>0);return{h:I+$+(Ae/2**32|0)|0,l:0|Ae}},te_add3L=(I,P,$)=>(I>>>0)+(P>>>0)+($>>>0),te_add3H=(I,P,$,oe)=>P+$+oe+(I/2**32|0)|0,te_add4L=(I,P,$,oe)=>(I>>>0)+(P>>>0)+($>>>0)+(oe>>>0),te_add4H=(I,P,$,oe,Ae)=>P+$+oe+Ae+(I/2**32|0)|0,te_add5H=(I,P,$,oe,Ae,je)=>P+$+oe+Ae+je+(I/2**32|0)|0,te_add5L=(I,P,$,oe,Ae)=>(I>>>0)+(P>>>0)+($>>>0)+(oe>>>0)+(Ae>>>0),[ot,Ct]=te_split(["0x428a2f98d728ae22","0x7137449123ef65cd","0xb5c0fbcfec4d3b2f","0xe9b5dba58189dbbc","0x3956c25bf348b538","0x59f111f1b605d019","0x923f82a4af194f9b","0xab1c5ed5da6d8118","0xd807aa98a3030242","0x12835b0145706fbe","0x243185be4ee4b28c","0x550c7dc3d5ffb4e2","0x72be5d74f27b896f","0x80deb1fe3b1696b1","0x9bdc06a725c71235","0xc19bf174cf692694","0xe49b69c19ef14ad2","0xefbe4786384f25e3","0x0fc19dc68b8cd5b5","0x240ca1cc77ac9c65","0x2de92c6f592b0275","0x4a7484aa6ea6e483","0x5cb0a9dcbd41fbd4","0x76f988da831153b5","0x983e5152ee66dfab","0xa831c66d2db43210","0xb00327c898fb213f","0xbf597fc7beef0ee4","0xc6e00bf33da88fc2","0xd5a79147930aa725","0x06ca6351e003826f","0x142929670a0e6e70","0x27b70a8546d22ffc","0x2e1b21385c26c926","0x4d2c6dfc5ac42aed","0x53380d139d95b3df","0x650a73548baf63de","0x766a0abb3c77b2a8","0x81c2c92e47edaee6","0x92722c851482353b","0xa2bfe8a14cf10364","0xa81a664bbc423001","0xc24b8b70d0f89791","0xc76c51a30654be30","0xd192e819d6ef5218","0xd69906245565a910","0xf40e35855771202a","0x106aa07032bbd1b8","0x19a4c116b8d2d0c8","0x1e376c085141ab53","0x2748774cdf8eeb99","0x34b0bcb5e19b48a8","0x391c0cb3c5c95a63","0x4ed8aa4ae3418acb","0x5b9cca4f7763e373","0x682e6ff3d6b2b8a3","0x748f82ee5defb2fc","0x78a5636f43172f60","0x84c87814a1f0ab72","0x8cc702081a6439ec","0x90befffa23631e28","0xa4506cebde82bde9","0xbef9a3f7b2c67915","0xc67178f2e372532b","0xca273eceea26619c","0xd186b8c721c0c207","0xeada7dd6cde0eb1e","0xf57d4f7fee6ed178","0x06f067aa72176fba","0x0a637dc5a2c898a6","0x113f9804bef90dae","0x1b710b35131c471b","0x28db77f523047d84","0x32caab7b40c72493","0x3c9ebe0a15c9bebc","0x431d67c49c100d4c","0x4cc5d4becb3e42b6","0x597f299cfc657e2a","0x5fcb6fab3ad6faec","0x6c44198c4a475817"].map(I=>BigInt(I))),Bn=new Uint32Array(80),On=new Uint32Array(80);class Wn extends Pr{constructor(){super(128,64,16,!1),this.Ah=1779033703,this.Al=-205731576,this.Bh=-1150833019,this.Bl=-2067093701,this.Ch=1013904242,this.Cl=-23791573,this.Dh=-1521486534,this.Dl=1595750129,this.Eh=1359893119,this.El=-1377402159,this.Fh=-1694144372,this.Fl=725511199,this.Gh=528734635,this.Gl=-79577749,this.Hh=1541459225,this.Hl=327033209}get(){const{Ah:P,Al:$,Bh:oe,Bl:Ae,Ch:je,Cl:pt,Dh:It,Dl:zt,Eh:ln,El:An,Fh:Qt,Fl:Gn,Gh:zn,Gl:nr,Hh:Mn,Hl:Hn}=this;return[P,$,oe,Ae,je,pt,It,zt,ln,An,Qt,Gn,zn,nr,Mn,Hn]}set(P,$,oe,Ae,je,pt,It,zt,ln,An,Qt,Gn,zn,nr,Mn,Hn){this.Ah=0|P,this.Al=0|$,this.Bh=0|oe,this.Bl=0|Ae,this.Ch=0|je,this.Cl=0|pt,this.Dh=0|It,this.Dl=0|zt,this.Eh=0|ln,this.El=0|An,this.Fh=0|Qt,this.Fl=0|Gn,this.Gh=0|zn,this.Gl=0|nr,this.Hh=0|Mn,this.Hl=0|Hn}process(P,$){for(let $n=0;$n<16;$n++,$+=4)Bn[$n]=P.getUint32($),On[$n]=P.getUint32($+=4);for(let $n=16;$n<80;$n++){const Ir=0|Bn[$n-15],ir=0|On[$n-15],Cr=te_rotrSH(Ir,ir,1)^te_rotrSH(Ir,ir,8)^te_shrSH(Ir,ir,7),Gr=te_rotrSL(Ir,ir,1)^te_rotrSL(Ir,ir,8)^te_shrSL(Ir,ir,7),Br=0|Bn[$n-2],ro=0|On[$n-2],Ji=te_rotrSH(Br,ro,19)^te_rotrBH(Br,ro,61)^te_shrSH(Br,ro,6),Xi=te_rotrSL(Br,ro,19)^te_rotrBL(Br,ro,61)^te_shrSL(Br,ro,6),bo=te_add4L(Gr,Xi,On[$n-7],On[$n-16]),To=te_add4H(bo,Cr,Ji,Bn[$n-7],Bn[$n-16]);Bn[$n]=0|To,On[$n]=0|bo}let{Ah:oe,Al:Ae,Bh:je,Bl:pt,Ch:It,Cl:zt,Dh:ln,Dl:An,Eh:Qt,El:Gn,Fh:zn,Fl:nr,Gh:Mn,Gl:Hn,Hh:Xn,Hl:vr}=this;for(let $n=0;$n<80;$n++){const Ir=te_rotrSH(Qt,Gn,14)^te_rotrSH(Qt,Gn,18)^te_rotrBH(Qt,Gn,41),ir=te_rotrSL(Qt,Gn,14)^te_rotrSL(Qt,Gn,18)^te_rotrBL(Qt,Gn,41),Cr=Qt&zn^~Qt&Mn,Br=te_add5L(vr,ir,Gn&nr^~Gn&Hn,Ct[$n],On[$n]),ro=te_add5H(Br,Xn,Ir,Cr,ot[$n],Bn[$n]),Ji=0|Br,Xi=te_rotrSH(oe,Ae,28)^te_rotrBH(oe,Ae,34)^te_rotrBH(oe,Ae,39),bo=te_rotrSL(oe,Ae,28)^te_rotrBL(oe,Ae,34)^te_rotrBL(oe,Ae,39),To=oe&je^oe&It^je&It,ga=Ae&pt^Ae&zt^pt&zt;Xn=0|Mn,vr=0|Hn,Mn=0|zn,Hn=0|nr,zn=0|Qt,nr=0|Gn,({h:Qt,l:Gn}=te_add(0|ln,0|An,0|ro,0|Ji)),ln=0|It,An=0|zt,It=0|je,zt=0|pt,je=0|oe,pt=0|Ae;const _r=te_add3L(Ji,bo,ga);oe=te_add3H(_r,ro,Xi,To),Ae=0|_r}({h:oe,l:Ae}=te_add(0|this.Ah,0|this.Al,0|oe,0|Ae)),({h:je,l:pt}=te_add(0|this.Bh,0|this.Bl,0|je,0|pt)),({h:It,l:zt}=te_add(0|this.Ch,0|this.Cl,0|It,0|zt)),({h:ln,l:An}=te_add(0|this.Dh,0|this.Dl,0|ln,0|An)),({h:Qt,l:Gn}=te_add(0|this.Eh,0|this.El,0|Qt,0|Gn)),({h:zn,l:nr}=te_add(0|this.Fh,0|this.Fl,0|zn,0|nr)),({h:Mn,l:Hn}=te_add(0|this.Gh,0|this.Gl,0|Mn,0|Hn)),({h:Xn,l:vr}=te_add(0|this.Hh,0|this.Hl,0|Xn,0|vr)),this.set(oe,Ae,je,pt,It,zt,ln,An,Qt,Gn,zn,nr,Mn,Hn,Xn,vr)}roundClean(){Bn.fill(0),On.fill(0)}destroy(){this.buffer.fill(0),this.set(0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0)}}const Mr=wr(()=>new Wn);function Fi(I){if(!Number.isSafeInteger(I)||I<0)throw new Error(`Wrong positive integer: ${I}`)}function jo(I,...P){if(!(I instanceof Uint8Array))throw new Error("Expected Uint8Array");if(P.length>0&&!P.includes(I.length))throw new Error(`Expected Uint8Array of length ${P}, not of length=${I.length}`)}const de={number:Fi,bool:function Ro(I){if("boolean"!=typeof I)throw new Error(`Expected boolean, not ${I}`)},bytes:jo,hash:function Ho(I){if("function"!=typeof I||"function"!=typeof I.create)throw new Error("Hash should be wrapped by utils.wrapConstructor");Fi(I.outputLen),Fi(I.blockLen)},exists:function Ua(I,P=!0){if(I.destroyed)throw new Error("Hash instance has been destroyed");if(P&&I.finished)throw new Error("Hash#digest() has already been called")},output:function $a(I,P){jo(I);const $=P.outputLen;if(I.length<$)throw new Error(`digestInto() expects output buffer of length at least ${$}`)}},he="object"==typeof globalThis&&"crypto"in globalThis?globalThis.crypto:void 0,Y=I=>I instanceof Uint8Array,br=I=>new DataView(I.buffer,I.byteOffset,I.byteLength),Jr=(I,P)=>I<<32-P|I>>>P;if(68!==new Uint8Array(new Uint32Array([287454020]).buffer)[0])throw new Error("Non little-endian hardware is not supported");function vs(I){if("string"==typeof I&&(I=function cs(I){if("string"!=typeof I)throw new Error("utf8ToBytes expected string, got "+typeof I);return new Uint8Array((new TextEncoder).encode(I))}(I)),!Y(I))throw new Error("expected Uint8Array, got "+typeof I);return I}Array.from({length:256},(I,P)=>P.toString(16).padStart(2,"0"));class bl{clone(){return this._cloneInto()}}function ul(I){const P=oe=>I().update(vs(oe)).digest(),$=I();return P.outputLen=$.outputLen,P.blockLen=$.blockLen,P.create=()=>I(),P}function eu(I=32){if(he&&"function"==typeof he.getRandomValues)return he.getRandomValues(new Uint8Array(I));throw new Error("crypto.getRandomValues must be defined")}class dl extends bl{constructor(P,$,oe,Ae){super(),this.blockLen=P,this.outputLen=$,this.padOffset=oe,this.isLE=Ae,this.finished=!1,this.length=0,this.pos=0,this.destroyed=!1,this.buffer=new Uint8Array(P),this.view=br(this.buffer)}update(P){de.exists(this);const{view:$,buffer:oe,blockLen:Ae}=this,je=(P=vs(P)).length;for(let pt=0;ptAe-pt&&(this.process(oe,0),pt=0);for(let Qt=pt;Qt>Ae&je),It=Number($&je),ln=oe?0:4;I.setUint32(P+(oe?4:0),pt,oe),I.setUint32(P+ln,It,oe)})(oe,Ae-8,BigInt(8*this.length),je),this.process(oe,0);const It=br(P),zt=this.outputLen;if(zt%4)throw new Error("_sha2: outputLen should be aligned to 32bit");const ln=zt/4,An=this.get();if(ln>An.length)throw new Error("_sha2: outputLen bigger than state");for(let Qt=0;QtI&P^~I&$,Ol=(I,P,$)=>I&P^I&$^P&$,Sa=new Uint32Array([1116352408,1899447441,3049323471,3921009573,961987163,1508970993,2453635748,2870763221,3624381080,310598401,607225278,1426881987,1925078388,2162078206,2614888103,3248222580,3835390401,4022224774,264347078,604807628,770255983,1249150122,1555081692,1996064986,2554220882,2821834349,2952996808,3210313671,3336571891,3584528711,113926993,338241895,666307205,773529912,1294757372,1396182291,1695183700,1986661051,2177026350,2456956037,2730485921,2820302411,3259730800,3345764771,3516065817,3600352804,4094571909,275423344,430227734,506948616,659060556,883997877,958139571,1322822218,1537002063,1747873779,1955562222,2024104815,2227730452,2361852424,2428436474,2756734187,3204031479,3329325298]),ks=new Uint32Array([1779033703,3144134277,1013904242,2773480762,1359893119,2600822924,528734635,1541459225]),js=new Uint32Array(64);class nu extends dl{constructor(){super(64,32,8,!1),this.A=0|ks[0],this.B=0|ks[1],this.C=0|ks[2],this.D=0|ks[3],this.E=0|ks[4],this.F=0|ks[5],this.G=0|ks[6],this.H=0|ks[7]}get(){const{A:P,B:$,C:oe,D:Ae,E:je,F:pt,G:It,H:zt}=this;return[P,$,oe,Ae,je,pt,It,zt]}set(P,$,oe,Ae,je,pt,It,zt){this.A=0|P,this.B=0|$,this.C=0|oe,this.D=0|Ae,this.E=0|je,this.F=0|pt,this.G=0|It,this.H=0|zt}process(P,$){for(let Qt=0;Qt<16;Qt++,$+=4)js[Qt]=P.getUint32($,!1);for(let Qt=16;Qt<64;Qt++){const Gn=js[Qt-15],zn=js[Qt-2],nr=Jr(Gn,7)^Jr(Gn,18)^Gn>>>3,Mn=Jr(zn,17)^Jr(zn,19)^zn>>>10;js[Qt]=Mn+js[Qt-7]+nr+js[Qt-16]|0}let{A:oe,B:Ae,C:je,D:pt,E:It,F:zt,G:ln,H:An}=this;for(let Qt=0;Qt<64;Qt++){const zn=An+(Jr(It,6)^Jr(It,11)^Jr(It,25))+$s(It,zt,ln)+Sa[Qt]+js[Qt]|0,Mn=(Jr(oe,2)^Jr(oe,13)^Jr(oe,22))+Ol(oe,Ae,je)|0;An=ln,ln=zt,zt=It,It=pt+zn|0,pt=je,je=Ae,Ae=oe,oe=zn+Mn|0}oe=oe+this.A|0,Ae=Ae+this.B|0,je=je+this.C|0,pt=pt+this.D|0,It=It+this.E|0,zt=zt+this.F|0,ln=ln+this.G|0,An=An+this.H|0,this.set(oe,Ae,je,pt,It,zt,ln,An)}roundClean(){js.fill(0)}destroy(){this.set(0,0,0,0,0,0,0,0),this.buffer.fill(0)}}class ns extends nu{constructor(){super(),this.A=-1056596264,this.B=914150663,this.C=812702999,this.D=-150054599,this.E=-4191439,this.F=1750603025,this.G=1694076839,this.H=-1090891868,this.outputLen=28}}const ru=ul(()=>new nu),jl=(ul(()=>new ns),BigInt(0),BigInt(1)),hl=BigInt(2),Vl=I=>I instanceof Uint8Array,Hl=Array.from({length:256},(I,P)=>P.toString(16).padStart(2,"0"));function ha(I){if(!Vl(I))throw new Error("Uint8Array expected");let P="";for(let $=0;$oe+Ae.length,0));let $=0;return I.forEach(oe=>{if(!Vl(oe))throw new Error("Uint8Array expected");P.set(oe,$),$+=oe.length}),P}const Xs=I=>(hl<new Uint8Array(I),Uo=I=>Uint8Array.from(I);function vo(I,P,$){if("number"!=typeof I||I<2)throw new Error("hashLen must be a number");if("number"!=typeof P||P<2)throw new Error("qByteLen must be a number");if("function"!=typeof $)throw new Error("hmacFn must be a function");let oe=Za(I),Ae=Za(I),je=0;const pt=()=>{oe.fill(1),Ae.fill(0),je=0},It=(...Qt)=>$(Ae,oe,...Qt),zt=(Qt=Za())=>{Ae=It(Uo([0]),Qt),oe=It(),0!==Qt.length&&(Ae=It(Uo([1]),Qt),oe=It())},ln=()=>{if(je++>=1e3)throw new Error("drbg: tried 1000 values");let Qt=0;const Gn=[];for(;Qt{let zn;for(pt(),zt(Qt);!(zn=Gn(ln()));)zt();return pt(),zn}}const Ci={bigint:I=>"bigint"==typeof I,function:I=>"function"==typeof I,boolean:I=>"boolean"==typeof I,string:I=>"string"==typeof I,isSafeInteger:I=>Number.isSafeInteger(I),array:I=>Array.isArray(I),field:(I,P)=>P.Fp.isValid(I),hash:I=>"function"==typeof I&&Number.isSafeInteger(I.outputLen)};function Vs(I,P,$={}){const oe=(Ae,je,pt)=>{const It=Ci[je];if("function"!=typeof It)throw new Error(`Invalid validator "${je}", expected function`);const zt=I[Ae];if(!(pt&&void 0===zt||It(zt,I)))throw new Error(`Invalid param ${String(Ae)}=${zt} (${typeof zt}), expected ${je}`)};for(const[Ae,je]of Object.entries(P))oe(Ae,je,!1);for(const[Ae,je]of Object.entries($))oe(Ae,je,!0);return I}const uo=BigInt(0),Ui=BigInt(1),U=BigInt(2),Ie=BigInt(3),ne=BigInt(4),ye=BigInt(5),Et=BigInt(8);function tr(I,P){const $=I%P;return $>=uo?$:P+$}function ci(I,P,$){if($<=uo||P 0");if($===Ui)return uo;let oe=Ui;for(;P>uo;)P&Ui&&(oe=oe*I%$),I=I*I%$,P>>=Ui;return oe}function ki(I,P,$){let oe=I;for(;P-- >uo;)oe*=oe,oe%=$;return oe}function Di(I,P){if(I===uo||P<=uo)throw new Error(`invert: expected positive integers, got n=${I} mod=${P}`);let $=tr(I,P),oe=P,Ae=uo,je=Ui,pt=Ui,It=uo;for(;$!==uo;){const ln=oe/$,An=oe%$,Qt=Ae-pt*ln,Gn=je-It*ln;oe=$,$=An,Ae=pt,je=It,pt=Qt,It=Gn}if(oe!==Ui)throw new Error("invert: does not exist");return tr(Ae,P)}BigInt(9),BigInt(16);const wi=["create","isValid","is0","neg","inv","sqrt","sqr","eql","add","sub","mul","pow","div","addN","subN","mulN","sqrN"];function Ls(I,P){const $=void 0!==P?P:I.toString(2).length;return{nBitLength:$,nByteLength:Math.ceil($/8)}}const ka=BigInt(0),Ia=BigInt(1);function su(I){return function bs(I){Vs(I,wi.reduce((oe,Ae)=>(oe[Ae]="function",oe),{ORDER:"bigint",MASK:"bigint",BYTES:"isSafeInteger",BITS:"isSafeInteger"}))}(I.Fp),Vs(I,{n:"bigint",h:"bigint",Gx:"field",Gy:"field"},{nBitLength:"isSafeInteger",nByteLength:"isSafeInteger"}),Object.freeze({...Ls(I.n,I.nBitLength),...I,p:I.Fp.ORDER})}const{Ph:Wl,aT:pc}=i,fl={Err:class extends Error{constructor(P=""){super(P)}},_parseInt(I){const{Err:P}=fl;if(I.length<2||2!==I[0])throw new P("Invalid signature integer tag");const $=I[1],oe=I.subarray(2,$+2);if(!$||oe.length!==$)throw new P("Invalid signature integer: wrong length");if(128&oe[0])throw new P("Invalid signature integer: negative");if(0===oe[0]&&!(128&oe[1]))throw new P("Invalid signature integer: unnecessary leading zero");return{d:Wl(oe),l:I.subarray($+2)}},toSig(I){const{Err:P}=fl,$="string"==typeof I?pc(I):I;if(!($ instanceof Uint8Array))throw new Error("ui8a expected");let oe=$.length;if(oe<2||48!=$[0])throw new P("Invalid signature tag");if($[1]!==oe-2)throw new P("Invalid signature: incorrect length");const{d:Ae,l:je}=fl._parseInt($.subarray(2)),{d:pt,l:It}=fl._parseInt(je);if(It.length)throw new P("Invalid signature: left bytes after parsing");return{r:Ae,s:pt}},hexFromSig(I){const P=ln=>8&Number.parseInt(ln[0],16)?"00"+ln:ln,$=ln=>{const An=ln.toString(16);return 1&An.length?`0${An}`:An},oe=P($(I.s)),Ae=P($(I.r)),je=oe.length/2,pt=Ae.length/2,It=$(je),zt=$(pt);return`30${$(pt+je+4)}02${zt}${Ae}02${It}${oe}`}},yo=BigInt(0),zo=BigInt(1),au=(BigInt(2),BigInt(3));function ah(I){const P=function Bu(I){const P=su(I);return Vs(P,{hash:"hash",hmac:"function",randomBytes:"function"},{bits2int:"function",bits2int_modN:"function",lowS:"boolean"}),Object.freeze({lowS:!0,...P})}(I),{Fp:$,n:oe}=P,Ae=$.BYTES+1,je=2*$.BYTES+1;function It(_r){return tr(_r,oe)}function zt(_r){return Di(_r,oe)}const{ProjectivePoint:ln,normPrivateKeyToScalar:An,weierstrassEquation:Qt,isWithinCurveOrder:Gn}=function lu(I){const P=function Fu(I){const P=su(I);Vs(P,{a:"field",b:"field"},{allowedPrivateKeyLengths:"array",wrapPrivateKey:"boolean",isTorsionFree:"function",clearCofactor:"function",allowInfinityPoint:"boolean",fromBytes:"function",toBytes:"function"});const{endo:$,Fp:oe,a:Ae}=P;if($){if(!oe.eql(Ae,oe.ZERO))throw new Error("Endomorphism can only be defined for Koblitz curves that have a=0");if("object"!=typeof $||"bigint"!=typeof $.beta||"function"!=typeof $.splitScalar)throw new Error("Expected endomorphism with beta: bigint and splitScalar: function")}return Object.freeze({...P})}(I),{Fp:$}=P,oe=P.toBytes||((nr,Mn,Hn)=>{const Xn=Mn.toAffine();return so(Uint8Array.from([4]),$.toBytes(Xn.x),$.toBytes(Xn.y))}),Ae=P.fromBytes||(nr=>{const Mn=nr.subarray(1);return{x:$.fromBytes(Mn.subarray(0,$.BYTES)),y:$.fromBytes(Mn.subarray($.BYTES,2*$.BYTES))}});function je(nr){const{a:Mn,b:Hn}=P,Xn=$.sqr(nr),vr=$.mul(Xn,nr);return $.add($.add(vr,$.mul(nr,Mn)),Hn)}if(!$.eql($.sqr(P.Gy),je(P.Gx)))throw new Error("bad generator point: equation left != right");function pt(nr){return"bigint"==typeof nr&&yo$.eql($n,$.ZERO);return vr(Hn)&&vr(Xn)?Qt.ZERO:new Qt(Hn,Xn,$.ONE)}get x(){return this.toAffine().x}get y(){return this.toAffine().y}static normalizeZ(Mn){const Hn=$.invertBatch(Mn.map(Xn=>Xn.pz));return Mn.map((Xn,vr)=>Xn.toAffine(Hn[vr])).map(Qt.fromAffine)}static fromHex(Mn){const Hn=Qt.fromAffine(Ae(Qi("pointHex",Mn)));return Hn.assertValidity(),Hn}static fromPrivateKey(Mn){return Qt.BASE.multiply(zt(Mn))}_setWindowSize(Mn){this._WINDOW_SIZE=Mn,ln.delete(this)}assertValidity(){if(this.is0()){if(P.allowInfinityPoint)return;throw new Error("bad point: ZERO")}const{x:Mn,y:Hn}=this.toAffine();if(!$.isValid(Mn)||!$.isValid(Hn))throw new Error("bad point: x or y not FE");const Xn=$.sqr(Hn),vr=je(Mn);if(!$.eql(Xn,vr))throw new Error("bad point: equation left != right");if(!this.isTorsionFree())throw new Error("bad point: not in prime-order subgroup")}hasEvenY(){const{y:Mn}=this.toAffine();if($.isOdd)return!$.isOdd(Mn);throw new Error("Field doesn't support isOdd")}equals(Mn){An(Mn);const{px:Hn,py:Xn,pz:vr}=this,{px:$n,py:Ir,pz:ir}=Mn,Cr=$.eql($.mul(Hn,ir),$.mul($n,vr)),Gr=$.eql($.mul(Xn,ir),$.mul(Ir,vr));return Cr&&Gr}negate(){return new Qt(this.px,$.neg(this.py),this.pz)}double(){const{a:Mn,b:Hn}=P,Xn=$.mul(Hn,au),{px:vr,py:$n,pz:Ir}=this;let ir=$.ZERO,Cr=$.ZERO,Gr=$.ZERO,Br=$.mul(vr,vr),ro=$.mul($n,$n),Ji=$.mul(Ir,Ir),Xi=$.mul(vr,$n);return Xi=$.add(Xi,Xi),Gr=$.mul(vr,Ir),Gr=$.add(Gr,Gr),ir=$.mul(Mn,Gr),Cr=$.mul(Xn,Ji),Cr=$.add(ir,Cr),ir=$.sub(ro,Cr),Cr=$.add(ro,Cr),Cr=$.mul(ir,Cr),ir=$.mul(Xi,ir),Gr=$.mul(Xn,Gr),Ji=$.mul(Mn,Ji),Xi=$.sub(Br,Ji),Xi=$.mul(Mn,Xi),Xi=$.add(Xi,Gr),Gr=$.add(Br,Br),Br=$.add(Gr,Br),Br=$.add(Br,Ji),Br=$.mul(Br,Xi),Cr=$.add(Cr,Br),Ji=$.mul($n,Ir),Ji=$.add(Ji,Ji),Br=$.mul(Ji,Xi),ir=$.sub(ir,Br),Gr=$.mul(Ji,ro),Gr=$.add(Gr,Gr),Gr=$.add(Gr,Gr),new Qt(ir,Cr,Gr)}add(Mn){An(Mn);const{px:Hn,py:Xn,pz:vr}=this,{px:$n,py:Ir,pz:ir}=Mn;let Cr=$.ZERO,Gr=$.ZERO,Br=$.ZERO;const ro=P.a,Ji=$.mul(P.b,au);let Xi=$.mul(Hn,$n),bo=$.mul(Xn,Ir),To=$.mul(vr,ir),ga=$.add(Hn,Xn),_r=$.add($n,Ir);ga=$.mul(ga,_r),_r=$.add(Xi,bo),ga=$.sub(ga,_r),_r=$.add(Hn,vr);let jr=$.add($n,ir);return _r=$.mul(_r,jr),jr=$.add(Xi,To),_r=$.sub(_r,jr),jr=$.add(Xn,vr),Cr=$.add(Ir,ir),jr=$.mul(jr,Cr),Cr=$.add(bo,To),jr=$.sub(jr,Cr),Br=$.mul(ro,_r),Cr=$.mul(Ji,To),Br=$.add(Cr,Br),Cr=$.sub(bo,Br),Br=$.add(bo,Br),Gr=$.mul(Cr,Br),bo=$.add(Xi,Xi),bo=$.add(bo,Xi),To=$.mul(ro,To),_r=$.mul(Ji,_r),bo=$.add(bo,To),To=$.sub(Xi,To),To=$.mul(ro,To),_r=$.add(_r,To),Xi=$.mul(bo,_r),Gr=$.add(Gr,Xi),Xi=$.mul(jr,_r),Cr=$.mul(ga,Cr),Cr=$.sub(Cr,Xi),Xi=$.mul(ga,bo),Br=$.mul(jr,Br),Br=$.add(Br,Xi),new Qt(Cr,Gr,Br)}subtract(Mn){return this.add(Mn.negate())}is0(){return this.equals(Qt.ZERO)}wNAF(Mn){return zn.wNAFCached(this,ln,Mn,Hn=>{const Xn=$.invertBatch(Hn.map(vr=>vr.pz));return Hn.map((vr,$n)=>vr.toAffine(Xn[$n])).map(Qt.fromAffine)})}multiplyUnsafe(Mn){const Hn=Qt.ZERO;if(Mn===yo)return Hn;if(It(Mn),Mn===zo)return this;const{endo:Xn}=P;if(!Xn)return zn.unsafeLadder(this,Mn);let{k1neg:vr,k1:$n,k2neg:Ir,k2:ir}=Xn.splitScalar(Mn),Cr=Hn,Gr=Hn,Br=this;for(;$n>yo||ir>yo;)$n&zo&&(Cr=Cr.add(Br)),ir&zo&&(Gr=Gr.add(Br)),Br=Br.double(),$n>>=zo,ir>>=zo;return vr&&(Cr=Cr.negate()),Ir&&(Gr=Gr.negate()),Gr=new Qt($.mul(Gr.px,Xn.beta),Gr.py,Gr.pz),Cr.add(Gr)}multiply(Mn){It(Mn);let Xn,vr,Hn=Mn;const{endo:$n}=P;if($n){const{k1neg:Ir,k1:ir,k2neg:Cr,k2:Gr}=$n.splitScalar(Hn);let{p:Br,f:ro}=this.wNAF(ir),{p:Ji,f:Xi}=this.wNAF(Gr);Br=zn.constTimeNegate(Ir,Br),Ji=zn.constTimeNegate(Cr,Ji),Ji=new Qt($.mul(Ji.px,$n.beta),Ji.py,Ji.pz),Xn=Br.add(Ji),vr=ro.add(Xi)}else{const{p:Ir,f:ir}=this.wNAF(Hn);Xn=Ir,vr=ir}return Qt.normalizeZ([Xn,vr])[0]}multiplyAndAddUnsafe(Mn,Hn,Xn){const vr=Qt.BASE,$n=(ir,Cr)=>Cr!==yo&&Cr!==zo&&ir.equals(vr)?ir.multiply(Cr):ir.multiplyUnsafe(Cr),Ir=$n(this,Hn).add($n(Mn,Xn));return Ir.is0()?void 0:Ir}toAffine(Mn){const{px:Hn,py:Xn,pz:vr}=this,$n=this.is0();null==Mn&&(Mn=$n?$.ONE:$.inv(vr));const Ir=$.mul(Hn,Mn),ir=$.mul(Xn,Mn),Cr=$.mul(vr,Mn);if($n)return{x:$.ZERO,y:$.ZERO};if(!$.eql(Cr,$.ONE))throw new Error("invZ was invalid");return{x:Ir,y:ir}}isTorsionFree(){const{h:Mn,isTorsionFree:Hn}=P;if(Mn===zo)return!0;if(Hn)return Hn(Qt,this);throw new Error("isTorsionFree() has not been declared for the elliptic curve")}clearCofactor(){const{h:Mn,clearCofactor:Hn}=P;return Mn===zo?this:Hn?Hn(Qt,this):this.multiplyUnsafe(P.h)}toRawBytes(Mn=!0){return this.assertValidity(),oe(Qt,this,Mn)}toHex(Mn=!0){return ha(this.toRawBytes(Mn))}}Qt.BASE=new Qt(P.Gx,P.Gy,$.ONE),Qt.ZERO=new Qt($.ZERO,$.ONE,$.ZERO);const Gn=P.nBitLength,zn=function Rl(I,P){const $=(Ae,je)=>{const pt=je.negate();return Ae?pt:je},oe=Ae=>({windows:Math.ceil(P/Ae)+1,windowSize:2**(Ae-1)});return{constTimeNegate:$,unsafeLadder(Ae,je){let pt=I.ZERO,It=Ae;for(;je>ka;)je&Ia&&(pt=pt.add(It)),It=It.double(),je>>=Ia;return pt},precomputeWindow(Ae,je){const{windows:pt,windowSize:It}=oe(je),zt=[];let ln=Ae,An=ln;for(let Qt=0;Qt>=zn,Hn>zt&&(Hn-=Gn,pt+=Ia);const Xn=Mn,vr=Mn+Math.abs(Hn)-1,Ir=Hn<0;0===Hn?An=An.add($(nr%2!=0,je[Xn])):ln=ln.add($(Ir,je[vr]))}return{p:ln,f:An}},wNAFCached(Ae,je,pt,It){const zt=Ae._WINDOW_SIZE||1;let ln=je.get(Ae);return ln||(ln=this.precomputeWindow(Ae,zt),1!==zt&&je.set(Ae,It(ln))),this.wNAF(zt,ln,pt)}}}(Qt,P.endo?Math.ceil(Gn/2):Gn);return{CURVE:P,ProjectivePoint:Qt,normPrivateKeyToScalar:zt,weierstrassEquation:je,isWithinCurveOrder:pt}}({...P,toBytes(_r,jr,Hi){const Yi=jr.toAffine(),Mo=$.toBytes(Yi.x),gs=so;return Hi?gs(Uint8Array.from([jr.hasEvenY()?2:3]),Mo):gs(Uint8Array.from([4]),Mo,$.toBytes(Yi.y))},fromBytes(_r){const jr=_r.length,Hi=_r[0],Yi=_r.subarray(1);if(jr!==Ae||2!==Hi&&3!==Hi){if(jr===je&&4===Hi)return{x:$.fromBytes(Yi.subarray(0,$.BYTES)),y:$.fromBytes(Yi.subarray($.BYTES,2*$.BYTES))};throw new Error(`Point of length ${jr} was invalid. Expected ${Ae} compressed bytes or ${je} uncompressed bytes`)}{const Mo=oo(Yi);if(!function pt(_r){return yo<_r&&_r<$.ORDER}(Mo))throw new Error("Point is not on curve");const gs=Qt(Mo);let qs=$.sqrt(gs);return!(1&~Hi)!=((qs&zo)===zo)&&(qs=$.neg(qs)),{x:Mo,y:qs}}}}),zn=_r=>ha(Sr(_r,P.nByteLength));function nr(_r){return _r>oe>>zo}const Hn=(_r,jr,Hi)=>oo(_r.slice(jr,Hi));class Xn{constructor(jr,Hi,Yi){this.r=jr,this.s=Hi,this.recovery=Yi,this.assertValidity()}static fromCompact(jr){const Hi=P.nByteLength;return jr=Qi("compactSignature",jr,2*Hi),new Xn(Hn(jr,0,Hi),Hn(jr,Hi,2*Hi))}static fromDER(jr){const{r:Hi,s:Yi}=fl.toSig(Qi("DER",jr));return new Xn(Hi,Yi)}assertValidity(){if(!Gn(this.r))throw new Error("r must be 0 < r < CURVE.n");if(!Gn(this.s))throw new Error("s must be 0 < s < CURVE.n")}addRecoveryBit(jr){return new Xn(this.r,this.s,jr)}recoverPublicKey(jr){const{r:Hi,s:Yi,recovery:Mo}=this,gs=Gr(Qi("msgHash",jr));if(null==Mo||![0,1,2,3].includes(Mo))throw new Error("recovery id invalid");const qs=2===Mo||3===Mo?Hi+P.n:Hi;if(qs>=$.ORDER)throw new Error("recovery id 2 or 3 invalid");const el=ln.fromHex((1&Mo?"03":"02")+zn(qs)),Dl=zt(qs),Jl=It(-gs*Dl),vc=It(Yi*Dl),ec=ln.BASE.multiplyAndAddUnsafe(el,Jl,vc);if(!ec)throw new Error("point at infinify");return ec.assertValidity(),ec}hasHighS(){return nr(this.s)}normalizeS(){return this.hasHighS()?new Xn(this.r,It(-this.s),this.recovery):this}toDERRawBytes(){return Wo(this.toDERHex())}toDERHex(){return fl.hexFromSig({r:this.r,s:this.s})}toCompactRawBytes(){return Wo(this.toCompactHex())}toCompactHex(){return zn(this.r)+zn(this.s)}}const vr={isValidPrivateKey(_r){try{return An(_r),!0}catch{return!1}},normPrivateKeyToScalar:An,randomPrivateKey:()=>{const jr=function ou(I,P,$=!1){const oe=(I=Qi("privateHash",I)).length,Ae=Ls(P).nByteLength+8;if(Ae<24||oe1024)throw new Error(`hashToPrivateScalar: expected ${Ae}-1024 bytes of input, got ${oe}`);return tr($?Fn(I):oo(I),P-Ui)+Ui}(P.randomBytes($.BYTES+8),oe);return Sr(jr,P.nByteLength)},precompute:(_r=8,jr=ln.BASE)=>(jr._setWindowSize(_r),jr.multiply(BigInt(3)),jr)};function Ir(_r){const jr=_r instanceof Uint8Array,Hi="string"==typeof _r,Yi=(jr||Hi)&&_r.length;return jr?Yi===Ae||Yi===je:Hi?Yi===2*Ae||Yi===2*je:_r instanceof ln}const Cr=P.bits2int||function(_r){const jr=oo(_r),Hi=8*_r.length-P.nBitLength;return Hi>0?jr>>BigInt(Hi):jr},Gr=P.bits2int_modN||function(_r){return It(Cr(_r))},Br=Xs(P.nBitLength);function ro(_r){if("bigint"!=typeof _r)throw new Error("bigint expected");if(!(yo<=_r&&_rtc in Hi))throw new Error("sign() legacy options not supported");const{hash:Yi,randomBytes:Mo}=P;let{lowS:gs,prehash:qs,extraEntropy:Ps}=Hi;null==gs&&(gs=!0),_r=Qi("msgHash",_r),qs&&(_r=Qi("prehashed msgHash",Yi(_r)));const el=Gr(_r),Dl=An(jr),Jl=[ro(Dl),ro(el)];if(null!=Ps){const tc=!0===Ps?Mo($.BYTES):Ps;Jl.push(Qi("extraEntropy",tc,$.BYTES))}const vc=so(...Jl),ec=el;return{seed:vc,k2sig:function yc(tc){const Rc=Cr(tc);if(!Gn(Rc))return;const mh=zt(Rc),Js=ln.BASE.multiply(Rc).toAffine(),ml=It(Js.x);if(ml===yo)return;const bc=It(mh*It(ec+ml*Dl));if(bc===yo)return;let nc=(Js.x===ml?0:2)|Number(Js.y&zo),ju=bc;return gs&&nr(bc)&&(ju=function Mn(_r){return nr(_r)?It(-_r):_r}(bc),nc^=1),new Xn(ml,ju,nc)}}}(_r,jr,Hi);return vo(P.hash.outputLen,P.nByteLength,P.hmac)(Yi,Mo)},verify:function ga(_r,jr,Hi,Yi=bo){const Mo=_r;if(jr=Qi("msgHash",jr),Hi=Qi("publicKey",Hi),"strict"in Yi)throw new Error("options.strict was renamed to lowS");const{lowS:gs,prehash:qs}=Yi;let Ps,el;try{if("string"==typeof Mo||Mo instanceof Uint8Array)try{Ps=Xn.fromDER(Mo)}catch(Js){if(!(Js instanceof fl.Err))throw Js;Ps=Xn.fromCompact(Mo)}else{if("object"!=typeof Mo||"bigint"!=typeof Mo.r||"bigint"!=typeof Mo.s)throw new Error("PARSE");{const{r:Js,s:ml}=Mo;Ps=new Xn(Js,ml)}}el=ln.fromHex(Hi)}catch(Js){if("PARSE"===Js.message)throw new Error("signature must be Signature instance, Uint8Array or hex string");return!1}if(gs&&Ps.hasHighS())return!1;qs&&(jr=P.hash(jr));const{r:Dl,s:Jl}=Ps,vc=Gr(jr),ec=zt(Jl),yc=It(vc*ec),tc=It(Dl*ec),Rc=ln.BASE.multiplyAndAddUnsafe(el,yc,tc)?.toAffine();return!!Rc&&It(Rc.x)===Dl},ProjectivePoint:ln,Signature:Xn,utils:vr}}BigInt(4);class Yl extends bl{constructor(P,$){super(),this.finished=!1,this.destroyed=!1,de.hash(P);const oe=vs($);if(this.iHash=P.create(),"function"!=typeof this.iHash.update)throw new Error("Expected instance of class which extends utils.Hash");this.blockLen=this.iHash.blockLen,this.outputLen=this.iHash.outputLen;const Ae=this.blockLen,je=new Uint8Array(Ae);je.set(oe.length>Ae?P.create().update(oe).digest():oe);for(let pt=0;ptnew Yl(I,P).update($).digest();function lh(I){return{hash:I,hmac:(P,...$)=>za(I,P,function Va(...I){const P=new Uint8Array(I.reduce((oe,Ae)=>oe+Ae.length,0));let $=0;return I.forEach(oe=>{if(!Y(oe))throw new Error("Uint8Array expected");P.set(oe,$),$+=oe.length}),P}(...$)),randomBytes:eu}}za.create=(I,P)=>new Yl(I,P);const qi=BigInt("0xfffffffffffffffffffffffffffffffffffffffffffffffffffffffefffffc2f"),Dr=BigInt("0xfffffffffffffffffffffffffffffffebaaedce6af48a03bbfd25e8cd0364141"),gc=BigInt(1),rs=BigInt(2),R=(I,P)=>(I+P/rs)/P;const F=function Ta(I,P,$=!1,oe={}){if(I<=uo)throw new Error(`Expected Fp ORDER > 0, got ${I}`);const{nBitLength:Ae,nByteLength:je}=Ls(I,P);if(je>2048)throw new Error("Field lengths over 2048 bytes are not supported");const pt=function li(I){if(I%ne===Ie){const P=(I+Ui)/ne;return function(oe,Ae){const je=oe.pow(Ae,P);if(!oe.eql(oe.sqr(je),Ae))throw new Error("Cannot find square root");return je}}if(I%Et===ye){const P=(I-ye)/Et;return function(oe,Ae){const je=oe.mul(Ae,U),pt=oe.pow(je,P),It=oe.mul(Ae,pt),zt=oe.mul(oe.mul(It,U),pt),ln=oe.mul(It,oe.sub(zt,oe.ONE));if(!oe.eql(oe.sqr(ln),Ae))throw new Error("Cannot find square root");return ln}}return function Rr(I){const P=(I-Ui)/U;let $,oe,Ae;for($=I-Ui,oe=0;$%U===uo;$/=U,oe++);for(Ae=U;Aetr(zt,I),isValid:zt=>{if("bigint"!=typeof zt)throw new Error("Invalid field element: expected bigint, got "+typeof zt);return uo<=zt&&ztzt===uo,isOdd:zt=>(zt&Ui)===Ui,neg:zt=>tr(-zt,I),eql:(zt,ln)=>zt===ln,sqr:zt=>tr(zt*zt,I),add:(zt,ln)=>tr(zt+ln,I),sub:(zt,ln)=>tr(zt-ln,I),mul:(zt,ln)=>tr(zt*ln,I),pow:(zt,ln)=>function Lo(I,P,$){if($ 0");if($===uo)return I.ONE;if($===Ui)return P;let oe=I.ONE,Ae=P;for(;$>uo;)$&Ui&&(oe=I.mul(oe,Ae)),Ae=I.sqr(Ae),$>>=Ui;return oe}(It,zt,ln),div:(zt,ln)=>tr(zt*Di(ln,I),I),sqrN:zt=>zt*zt,addN:(zt,ln)=>zt+ln,subN:(zt,ln)=>zt-ln,mulN:(zt,ln)=>zt*ln,inv:zt=>Di(zt,I),sqrt:oe.sqrt||(zt=>pt(It,zt)),invertBatch:zt=>function fa(I,P){const $=new Array(P.length),oe=P.reduce((je,pt,It)=>I.is0(pt)?je:($[It]=je,I.mul(je,pt)),I.ONE),Ae=I.inv(oe);return P.reduceRight((je,pt,It)=>I.is0(pt)?je:($[It]=I.mul(je,$[It]),I.mul(je,pt)),Ae),$}(It,zt),cmov:(zt,ln,An)=>An?ln:zt,toBytes:zt=>$?Oi(zt,je):Sr(zt,je),fromBytes:zt=>{if(zt.length!==je)throw new Error(`Fp.fromBytes: expected ${je}, got ${zt.length}`);return $?Fn(zt):oo(zt)}});return Object.freeze(It)}(qi,void 0,void 0,{sqrt:function G(I){const P=qi,$=BigInt(3),oe=BigInt(6),Ae=BigInt(11),je=BigInt(22),pt=BigInt(23),It=BigInt(44),zt=BigInt(88),ln=I*I*I%P,An=ln*ln*I%P,Qt=ki(An,$,P)*An%P,Gn=ki(Qt,$,P)*An%P,zn=ki(Gn,rs,P)*ln%P,nr=ki(zn,Ae,P)*zn%P,Mn=ki(nr,je,P)*nr%P,Hn=ki(Mn,It,P)*Mn%P,Xn=ki(Hn,zt,P)*Hn%P,vr=ki(Xn,It,P)*Mn%P,$n=ki(vr,$,P)*An%P,Ir=ki($n,pt,P)*nr%P,ir=ki(Ir,oe,P)*ln%P,Cr=ki(ir,rs,P);if(!F.eql(F.sqr(Cr),I))throw new Error("Cannot find square root");return Cr}}),K=function ch(I,P){const $=oe=>ah({...I,...lh(oe)});return Object.freeze({...$(P),create:$})}({a:BigInt(0),b:BigInt(7),Fp:F,n:Dr,Gx:BigInt("55066263022277343669578718895168534326250603453777594175500187360389116729240"),Gy:BigInt("32670510020758816978083085130507043184471273380659243275938904335757337482424"),h:BigInt(1),lowS:!0,endo:{beta:BigInt("0x7ae96a2b657c07106e64479eac3434e99cf0497512f58995c1396c28719501ee"),splitScalar:I=>{const P=Dr,$=BigInt("0x3086d221a7d46bcde86c90e49284eb15"),oe=-gc*BigInt("0xe4437ed6010e88286f547fa90abfe4c3"),Ae=BigInt("0x114ca50f7a8e2f3f657c1108d9d44cfd8"),je=$,pt=BigInt("0x100000000000000000000000000000000"),It=R(je*I,P),zt=R(-oe*I,P);let ln=tr(I-It*$-zt*Ae,P),An=tr(-It*oe-zt*je,P);const Qt=ln>pt,Gn=An>pt;if(Qt&&(ln=P-ln),Gn&&(An=P-An),ln>pt||An>pt)throw new Error("splitScalar: Endomorphism failed, k="+I);return{k1neg:Qt,k1:ln,k2neg:Gn,k2:An}}}},ru);BigInt(0);var Ql=r(1998);const Zl=K.ProjectivePoint,uu=(0,Ql.Tq)(Qa);function du(I){return BigInt(`0x${function ve(I){if(!Ii(I))throw new Error("Uint8Array expected");let P="";for(let $=0;${if(!Number.isSafeInteger(I)||I<0||I>2**32-1)throw new Error(`Invalid number=${I}. Should be from 0 to 2 ** 32 - 1`);const P=new Uint8Array(4);return Io(P).setUint32(0,I,!1),P};class Ra{get fingerprint(){if(!this.pubHash)throw new Error("No publicKey set!");return Io(this.pubHash).getUint32(0,!1)}get identifier(){return this.pubHash}get pubKeyHash(){return this.pubHash}get privateKey(){return this.privKeyBytes||null}get publicKey(){return this.pubKey||null}get privateExtendedKey(){const P=this.privateKey;if(!P)throw new Error("No private key");return uu.encode(this.serialize(this.versions.private,Nn(new Uint8Array([0]),P)))}get publicExtendedKey(){if(!this.pubKey)throw new Error("No public key");return uu.encode(this.serialize(this.versions.public,this.pubKey))}static fromMasterSeed(P,$=pi){if(ai(P),8*P.length<128||8*P.length>512)throw new Error(`HDKey: wrong seed length=${P.length}. Should be between 128 and 512 bits; 256 bits is advised)`);const oe=Or(Mr,En,P);return new Ra({versions:$,chainCode:oe.slice(32),privateKey:oe.slice(0,32)})}static fromExtendedKey(P,$=pi){const oe=uu.decode(P),Ae=Io(oe),je=Ae.getUint32(0,!1),pt={versions:$,depth:oe[4],parentFingerprint:Ae.getUint32(5,!1),index:Ae.getUint32(9,!1),chainCode:oe.slice(13,45)},It=oe.slice(45),zt=0===It[0];if(je!==$[zt?"private":"public"])throw new Error("Version mismatch");return new Ra(zt?{...pt,privateKey:It.slice(1)}:{...pt,publicKey:It})}static fromJSON(P){return Ra.fromExtendedKey(P.xpriv)}constructor(P){if(this.depth=0,this.index=0,this.chainCode=null,this.parentFingerprint=0,!P||"object"!=typeof P)throw new Error("HDKey.constructor must not be called directly");if(this.versions=P.versions||pi,this.depth=P.depth||0,this.chainCode=P.chainCode,this.index=P.index||0,this.parentFingerprint=P.parentFingerprint||0,!this.depth&&(this.parentFingerprint||this.index))throw new Error("HDKey: zero depth with non-zero index/parent fingerprint");if(P.publicKey&&P.privateKey)throw new Error("HDKey: publicKey and privateKey at same time.");if(P.privateKey){if(!K.utils.isValidPrivateKey(P.privateKey))throw new Error("Invalid private key");this.privKey="bigint"==typeof P.privateKey?P.privateKey:du(P.privateKey),this.privKeyBytes=function Ja(I){return function gt(I){if("string"!=typeof I)throw new Error("hex string expected, got "+typeof I);const P=I.length,$=P/2;if(P%2)throw new Error("padded hex string expected, got unpadded hex of length "+P);const oe=new Uint8Array($);for(let Ae=0,je=0;Ae<$;Ae++,je+=2){const pt=Ne(I.charCodeAt(je)),It=Ne(I.charCodeAt(je+1));if(void 0===pt||void 0===It)throw new Error('hex string expected, got non-hex character "'+(I[je]+I[je+1])+'" at index '+je);oe[Ae]=16*pt+It}return oe}(I.toString(16).padStart(64,"0"))}(this.privKey),this.pubKey=K.getPublicKey(P.privateKey,!0)}else{if(!P.publicKey)throw new Error("HDKey: no public or private key provided");this.pubKey=Zl.fromHex(P.publicKey).toRawBytes(!0)}this.pubHash=Go(Qa(this.pubKey))}derive(P){if(!/^[mM]'?/.test(P))throw new Error('Path must start with "m" or "M"');if(/^[mM]'?$/.test(P))return this;const $=P.replace(/^[mM]'?\//,"").split("/");let oe=this;for(const Ae of $){const je=/^(\d+)('?)$/.exec(Ae);if(!je||3!==je.length)throw new Error(`Invalid child index: ${Ae}`);let pt=+je[1];if(!Number.isSafeInteger(pt)||pt>=Ic)throw new Error("Invalid index");"'"===je[2]&&(pt+=Ic),oe=oe.deriveChild(pt)}return oe}deriveChild(P){if(!this.pubKey||!this.chainCode)throw new Error("No publicKey or chainCode set");let $=Nl(P);if(P>=Ic){const It=this.privateKey;if(!It)throw new Error("Could not derive hardened child key");$=Nn(new Uint8Array([0]),It,$)}else $=Nn(this.pubKey,$);const oe=Or(Mr,this.chainCode,$),Ae=du(oe.slice(0,32)),je=oe.slice(32);if(!K.utils.isValidPrivateKey(Ae))throw new Error("Tweak bigger than curve order");const pt={versions:this.versions,chainCode:je,depth:this.depth+1,parentFingerprint:this.fingerprint,index:P};try{if(this.privateKey){const It=tr(this.privKey+Ae,K.CURVE.n);if(!K.utils.isValidPrivateKey(It))throw new Error("The tweak was out of range or the resulted private key is invalid");pt.privateKey=It}else{const It=Zl.fromHex(this.pubKey).add(Zl.fromPrivateKey(Ae));if(It.equals(Zl.ZERO))throw new Error("The tweak was equal to negative P, which made the result key invalid");pt.publicKey=It.toRawBytes(!0)}return new Ra(pt)}catch{return this.deriveChild(P+1)}}sign(P){if(!this.privateKey)throw new Error("No privateKey set!");return ai(P,32),K.sign(P,this.privKey).toCompactRawBytes()}verify(P,$){if(ai(P,32),ai($,64),!this.publicKey)throw new Error("No publicKey set!");let oe;try{oe=K.Signature.fromCompact($)}catch{return!1}return K.verify(oe,P,this.publicKey)}wipePrivateData(){return this.privKey=void 0,this.privKeyBytes&&(this.privKeyBytes.fill(0),this.privKeyBytes=void 0),this}toJSON(){return{xpriv:this.privateExtendedKey,xpub:this.publicExtendedKey}}serialize(P,$){if(!this.chainCode)throw new Error("No chainCode set");return ai($,33),Nn(Nl(P),new Uint8Array([this.depth]),Nl(this.parentFingerprint),Nl(this.index),this.chainCode,$)}}var ma=r(3107);let ql=(()=>{class I{constructor(){this.encoder=new TextEncoder,this.decoder=new TextDecoder}getPasswordKey($){var oe=this;return(0,a.A)(function*(){return window.crypto.subtle.importKey("raw",oe.encoder.encode($),"PBKDF2",!1,["deriveKey"])})()}deriveKey($,oe,Ae){return(0,a.A)(function*(){return window.crypto.subtle.deriveKey({name:"PBKDF2",salt:oe,iterations:25e4,hash:"SHA-256"},$,{name:"AES-GCM",length:256},!1,Ae)})()}encryptData($,oe){var Ae=this;return(0,a.A)(function*(){try{const je=window.crypto.getRandomValues(new Uint8Array(16)),pt=window.crypto.getRandomValues(new Uint8Array(12)),It=yield Ae.getPasswordKey(oe),zt=yield Ae.deriveKey(It,je,["encrypt"]),ln=new Uint8Array(yield window.crypto.subtle.encrypt({name:"AES-GCM",iv:pt},zt,Ae.encoder.encode($))),An=new Uint8Array(je.length+pt.length+ln.length);return An.set(je,0),An.set(pt,je.length),An.set(ln,je.length+pt.length),Ql.K3.encode(An)}catch(je){throw console.error("Encryption failed:",je),new Error("Failed to encrypt data.")}})()}decryptData($,oe){var Ae=this;return(0,a.A)(function*(){try{const je=Ql.K3.decode($),pt=je.slice(0,16),It=je.slice(16,28),zt=je.slice(28),ln=yield Ae.getPasswordKey(oe),An=yield Ae.deriveKey(ln,pt,["decrypt"]),Qt=yield window.crypto.subtle.decrypt({name:"AES-GCM",iv:It},An,zt);return Ae.decoder.decode(Qt)}catch(je){throw console.error("Decryption failed:",je),new Error("Failed to decrypt data.")}})()}static{this.\u0275fac=function(oe){return new(oe||I)}}static{this.\u0275prov=ma.jDH({token:I,factory:I.\u0275fac,providedIn:"root"})}}return I})();var Zs=r(7544),Cl=r(4482);let yd=(()=>{class I{constructor($,oe,Ae){this.securityService=$,this.dialog=oe,this._nostrLoginService=Ae,this.localStorageSecretKeyName="secretKey",this.localStoragePublicKeyName="publicKey",this.localStorageNpubName="npub",this.localStorageNsecName="nsec",this.storageKey="userPassword"}savePassword($,oe){const Ae=Date.now()+60*oe*1e3;sessionStorage.setItem(this.storageKey,JSON.stringify({password:$,expirationTime:Ae}))}getPassword(){const $=sessionStorage.getItem(this.storageKey);if(!$)return null;const{password:oe,expirationTime:Ae}=JSON.parse($);return Date.now()>Ae?(this.clearPassword(),null):oe}clearPassword(){sessionStorage.removeItem(this.storageKey)}changePassword($,oe,Ae){var je=this;return(0,a.A)(function*(){try{const pt=yield je.getSecretKey($);if(!pt)throw new Error("Incorrect current password.");yield je.setSecretKey(pt,oe);const It=yield je.getNsec($);return It&&(yield je.setNsec(It,oe)),je.clearPassword(),Ae&&je.savePassword(oe,60),!0}catch(pt){return console.error("Failed to change password: ",pt),!1}})()}getUsername($){return $.startsWith("npub")&&($=C.Qe.decode($).data.toString()),`@${localStorage.getItem(`${$}`)||C.Qe.npubEncode($)}`}npub(){let $=this.getPublicKey();return C.Qe.npubEncode($)}requestPassword(){var $=this;return(0,a.A)(function*(){return $.dialog.open(y.b,{width:"300px",disableClose:!0}).afterClosed().toPromise()})()}nsec($){var oe=this;return(0,a.A)(function*(){if(oe.usingSecretKey()){let Ae=yield oe.getSecretKey($);const je=Uint8Array.from(w.hp.from(Ae,"hex"));return C.Qe.nsecEncode(je)}return""})()}pubkey($){return C.Qe.decode($).data.toString()}setPublicKey($){const oe=C.Qe.npubEncode($);window.localStorage.setItem(this.localStoragePublicKeyName,$),window.localStorage.setItem(this.localStorageNpubName,oe)}getPublicKey(){const $=localStorage.getItem("__nostrlogin_nip46");if($)try{return JSON.parse($).pubkey||""}catch(oe){console.error("Error parsing nostr login data:",oe)}return localStorage.getItem(this.localStoragePublicKeyName)||""}setNpub($){localStorage.setItem(this.localStorageNpubName,$)}getNpub(){return window.localStorage.getItem(this.localStorageNpubName)||""}setSecretKey($,oe=""){var Ae=this;return(0,a.A)(function*(){if(""===oe)localStorage.setItem(Ae.localStorageSecretKeyName,$),localStorage.setItem("usePassword","false");else{const je=yield Ae.securityService.encryptData($,oe);localStorage.setItem(Ae.localStorageSecretKeyName,je),localStorage.setItem("usePassword","true")}})()}getSecretKey($=""){var oe=this;return(0,a.A)(function*(){const Ae=localStorage.getItem(oe.localStorageSecretKeyName),je="true"===localStorage.getItem("usePassword");return Ae?je?yield oe.securityService.decryptData(Ae,$):Ae:null})()}getDecryptedSecretKey(){var $=this;return(0,a.A)(function*(){try{if("true"!==localStorage.getItem("usePassword"))return $.getSecretKey();const Ae=$.getPassword();if(Ae)return yield $.getSecretKey(Ae);const je=yield $.requestPassword();if(je?.password){const pt=yield $.getSecretKey(je.password);return 0!==je.duration&&$.savePassword(je.password,je.duration),pt}return console.error("Password not provided"),null}catch(oe){return console.error("Error decrypting private key:",oe),null}})()}setNsec($,oe=""){var Ae=this;return(0,a.A)(function*(){if(""===oe)localStorage.setItem(Ae.localStorageNsecName,$),localStorage.setItem("usePassword","false");else{const je=yield Ae.securityService.encryptData($,oe);localStorage.setItem(Ae.localStorageNsecName,je),localStorage.setItem("usePassword","true")}})()}getNsec($=""){var oe=this;return(0,a.A)(function*(){const Ae=localStorage.getItem(oe.localStorageNsecName),je="true"===localStorage.getItem("usePassword");return Ae?je?yield oe.securityService.decryptData(Ae,$):Ae:null})()}setPublicKeyFromExtension($){this.setPublicKey($)}handleLoginWithKey($,oe=""){let Ae,je,pt,It;try{if($.startsWith(this.localStorageNsecName)){const ln=C.Qe.decode($);if(ln.type!==this.localStorageNsecName)throw new Error("Invalid nsec key.");Ae=w.hp.from(ln.data).toString("hex")}else{if(!/^[0-9a-fA-F]{64}$/.test($))throw new Error("Invalid key format. Must be either nsec or hex.");Ae=$}const zt=new Uint8Array(w.hp.from(Ae,"hex"));return je=(0,C.lG)(zt),It=C.Qe.npubEncode(je),pt=C.Qe.nsecEncode(zt),this.setSecretKey(Ae,oe),this.setNsec(It,oe),this.setPublicKey(je),this.setNpub(It),!0}catch(zt){return console.error("Error during key handling: ",zt),!1}}handleLoginWithMnemonic($,oe="",Ae=""){try{const pt=function Oc(I,P,$=0){let Ae=Ra.fromMasterSeed(Co(I,P)).derive(`m/44'/1237'/${$}'/0/0`).privateKey;if(!Ae)throw new Error("could not derive private key");return Ae}($,oe,0),It=(0,c.My)(pt),zt=(0,C.lG)(pt),ln=C.Qe.npubEncode(zt),An=C.Qe.nsecEncode(pt);return this.setSecretKey(It,Ae),this.setNsec(An,Ae),this.setPublicKey(zt),this.setNpub(ln),window.localStorage.setItem(this.localStorageNsecName,An),!0}catch(je){return console.error("Error during login with mnemonic:",je),!1}}logout(){window.localStorage.removeItem(this.localStorageSecretKeyName),window.localStorage.removeItem(this.localStoragePublicKeyName),window.localStorage.removeItem(this.localStorageNpubName),window.localStorage.removeItem(this.localStorageNsecName),this._nostrLoginService.logout()}usingNostrBrowserExtension(){return!this.usingSecretKey()&&!!globalThis.nostr}usingSecretKey(){return!!localStorage.getItem(this.localStorageSecretKeyName)}generateAndStoreKeys($=""){try{const oe=(0,C.Bq)(),Ae=w.hp.from(oe).toString("hex"),je=(0,C.lG)(oe),pt=C.Qe.npubEncode(je),It=C.Qe.nsecEncode(oe);return this.setSecretKey(Ae,$),this.setNsec(It,$),this.setPublicKey(je),this.setNpub(pt),{secretKey:Ae,pubkey:je,npub:pt,nsec:It}}catch(oe){return console.error("Error during key generation:",oe),null}}handleLoginWithExtension(){var $=this;return(0,a.A)(function*(){const oe=globalThis;if(!oe.nostr)return!1;try{const Ae=yield oe.nostr.getPublicKey();if(!Ae)throw new Error("Public key not available from Nostr extension.");return $.setPublicKeyFromExtension(Ae),!0}catch(Ae){return console.error("Failed to connect to Nostr extension:",Ae),!1}})()}encryptMessage($,oe,Ae){return(0,a.A)(function*(){console.log(Ae);try{return yield C.sh.encrypt($,oe,Ae)}catch(je){throw console.error("Error encrypting message:",je),je}})()}encryptMessageWithExtension($,oe){return(0,a.A)(function*(){return yield globalThis.nostr.nip04.encrypt(oe,$)})()}decryptMessageWithExtension($,oe){return(0,a.A)(function*(){const Ae=globalThis;if(Ae.nostr&&"function"==typeof Ae.nostr.nip04?.decrypt)try{return yield Ae.nostr.nip04.decrypt($,oe)}catch(je){return console.error("Decryption failed:",je),"*Failed to decrypt content: "+je.message+"*"}return console.warn("Nostr extension or decrypt method is unavailable"),"Attempted Nostr Window decryption and failed."})()}decryptMessage($,oe,Ae){return(0,a.A)(function*(){try{if(!$||!oe||!Ae)throw new Error("Private key, public key, or encrypted message is missing or undefined.");const je=yield C.sh.decrypt($,oe,Ae);if(!je)throw new Error("Decryption returned an empty message.");return je}catch(je){throw je}})()}getUnsignedEvent($,oe,Ae){return{kind:$,pubkey:this.getPublicKey(),tags:oe,content:Ae,created_at:Math.floor(Date.now()/1e3)}}getSignedEvent($,oe){const Ae=(0,c.aT)(oe);return(0,C.pC)($,Ae)}getMuteList(){return(localStorage.getItem("muteList")||"").split(",")}setMuteListFromTags($){let oe=[];$.forEach(Ae=>{oe.push(Ae[1])}),this.setMuteList(oe)}setMuteList($){if(0===$.length)localStorage.setItem("muteList","");else{let oe=Array.from(new Set($));localStorage.setItem("muteList",oe.filter(Ae=>Ae).join(","))}}signEventWithExtension($){return(0,a.A)(function*(){const oe=globalThis;if(oe.nostr)return yield oe.nostr.signEvent($);throw new Error("Tried to sign event with extension but failed")})()}signDMWithExtension($,oe){return(0,a.A)(function*(){const Ae=globalThis;if(Ae.nostr&&Ae.nostr.nip04?.encrypt)return yield Ae.nostr.nip04.encrypt($,oe);throw new Error("Failed to Sign with extension")})()}isUsingExtension(){var $=this;return(0,a.A)(function*(){const oe=globalThis;if(oe.nostr&&oe.nostr.getPublicKey)try{return!localStorage.getItem($.localStorageSecretKeyName)}catch(Ae){return console.error("Failed to check Nostr extension:",Ae),!1}return!1})()}isUsingSecretKey(){return!!localStorage.getItem(this.localStorageSecretKeyName)}getNpubFromPubkey($){try{return C.Qe.npubEncode($)}catch(oe){return console.error("Error converting hex to npub:",oe),""}}getNsecFromSeckey($){try{const oe=Uint8Array.from(w.hp.from($,"hex"));return C.Qe.nsecEncode(oe)}catch(oe){return console.error("Error converting hex to nsec:",oe),""}}getHexFromNpub($){try{const oe=C.Qe.decode($);if("npub"!==oe.type)throw new Error("Invalid npub format.");return oe.data.toString()}catch(oe){return console.error("Error converting npub to hex:",oe),""}}processKey($){try{if($.startsWith("npub")){const oe=this.getHexFromNpub($);if(!oe)throw new Error("Failed to convert npub to hex.");return oe}if(/^[0-9a-fA-F]{64}$/.test($))return $;throw new Error("Invalid key format. Must be either hex or npub.")}catch(oe){return console.error("Error processing key:",oe),""}}static{this.\u0275fac=function(oe){return new(oe||I)(ma.KVO(ql),ma.KVO(Zs.bZ),ma.KVO(Cl.v))}}static{this.\u0275prov=ma.jDH({token:I,factory:I.\u0275fac,providedIn:"root"})}}return I})()},6433:(o,s,r)=>{"use strict";r.d(s,{d:()=>C});var i=r(3014),a=r(3797),c=r(3107),y=r(5506),w=r(3149);let C=(()=>{class T{constructor(M,O){this.subscriptionService=M,this.storageService=O,this.isProfileLoaded=!1}loadUserProfile(M){var O=this;return(0,i.A)(function*(){O.isProfileLoaded||(yield O.subscribeToUserProfile(M),yield O.subscribeToUserChats(M),yield O.subscribeToUserPosts(M),yield O.subscribeToMyLikes(M),O.isProfileLoaded=!0)})()}subscribeToUserProfile(M){var O=this;return(0,i.A)(function*(){const L=yield O.storageService.getLastUpdateDate("users"),Z={kinds:[0],authors:[M],limit:1};L&&(Z.since=parseInt(L,10)),O.subscriptionService.addSubscriptions([Z],q=>{const re=O.parseMetadataEvent(q);O.storageService.saveProfile(M,re)})})()}subscribeToUserChats(M){var O=this;return(0,i.A)(function*(){const L=yield O.storageService.getLastUpdateDate("chats"),Z=[{kinds:[a.rV],authors:[M],limit:300},{kinds:[a.rV],"#p":[M],limit:300}];if(L){const q=parseInt(L,10);Z.forEach(re=>re.since=q)}else O.storageService.removeAllChats();O.subscriptionService.addSubscriptions(Z,q=>{const re=O.parseChatEvent(q);O.storageService.saveChatEvent(re)})})()}subscribeToUserPosts(M){var O=this;return(0,i.A)(function*(){const L=yield O.storageService.getLastUpdateDate("posts"),Z={kinds:[a.av],authors:[M]};L&&(Z.since=parseInt(L,10)),O.subscriptionService.addSubscriptions([Z],q=>{O.isReply(q)||O.storageService.savePost(q)})})()}isReply(M){return M.tags.filter(L=>"e"===L[0]||"p"===L[0]).length>0}subscribeToMyLikes(M){var O=this;return(0,i.A)(function*(){const L=yield O.storageService.getLastUpdateDate("myLikes"),Z={kinds:[a.qT],authors:[M]};L&&(Z.since=parseInt(L,10)),O.subscriptionService.addSubscriptions([Z],q=>{O.storageService.saveLike(q)})})()}parseMetadataEvent(M){try{return JSON.parse(M.content)}catch(O){return console.error("Error parsing metadata event:",O),null}}parseChatEvent(M){try{const O=M.content.split("?iv=");return{id:M.id,kind:M.kind,pubkey:M.pubkey,created_at:M.created_at,tags:M.tags,content:O[0],iv:O[1],IsRead:!1}}catch(O){return console.error("Error parsing chat event:",O),null}}static{this.\u0275fac=function(O){return new(O||T)(c.KVO(y.n),c.KVO(w.n))}}static{this.\u0275prov=c.jDH({token:T,factory:T.\u0275fac,providedIn:"root"})}}return T})()},3149:(o,s,r)=>{"use strict";r.d(s,{n:()=>C});var i=r(3014),a=r(230),c=r.n(a),y=r(1217),w=r(3107);let C=(()=>{class T{constructor(){this.profileSubject=new y.t(null),this.projectsSubject=new y.t([]),this.projectStatsSubject=new y.t({}),this.chatEventsSubject=new y.t([]),this.unreadChatCountSubject=new y.t(0),this.contactsSubject=new y.t({pubKey:"",contacts:[]}),this.postsSubject=new y.t(null),this.myLikesSubject=new y.t([]),this.notificationsSubject=new y.t([]),this.contactStatsSubject=new y.t({totalContacts:0,followersCount:0,followingCount:0}),this.profileStore=this.createStore("profiles"),this.updateHistoryStore=this.createStore("updateHistory"),this.contactsStore=this.createStore("contacts"),this.chatsStore=this.createStore("chats"),this.postsStore=this.createStore("posts"),this.myLikesStore=this.createStore("myLikes"),this.notificationsStore=this.createStore("notifications"),this.projectsStore=this.createStore("projects"),this.projectStatsStore=this.createStore("projectStats"),this.loadAllProjectsFromDB(),this.loadAllProjectStatsFromDB(),this.loadAllChatEventsFromDB(),this.loadAllMyLikesFromDB(),this.loadAllNotificationsFromDB(),this.loadContactStatsFromDB()}createStore(M){return c().createInstance({driver:c().INDEXEDDB,name:"angor-hub",version:1,storeName:M})}get profile$(){return this.profileSubject.asObservable()}get projects$(){return this.projectsSubject.asObservable()}get projectStats$(){return this.projectStatsSubject.asObservable()}get chatEvents$(){return this.chatEventsSubject.asObservable()}get unreadChatCount$(){return this.unreadChatCountSubject.asObservable()}get contacts$(){return this.contactsSubject.asObservable()}get posts$(){return this.postsSubject.asObservable()}get contactStats$(){return this.contactStatsSubject.asObservable()}get myLikes$(){return this.myLikesSubject.asObservable()}get notifications$(){return this.notificationsSubject.asObservable()}saveProfile(M,O){var L=this;return(0,i.A)(function*(){try{if(!M||!O)return void console.error("Invalid pubKey or metadata:",M,O);O.pubKey=M,yield L.profileStore.setItem(M,O),L.profileSubject.next({pubKey:M,metadata:O}),yield L.setUpdateHistory("profiles")}catch(Z){console.error("Error saving profile",Z)}})()}getProfile(M){var O=this;return(0,i.A)(function*(){try{return(yield O.profileStore.getItem(M))||null}catch(L){return console.error("Error retrieving profile metadata:",L),null}})()}getAllProfiles(){var M=this;return(0,i.A)(function*(){try{const O=[];return yield M.profileStore.iterate(L=>{O.push(L)}),O}catch(O){return console.error("Error retrieving all Profile:",O),[]}})()}searchProfile(M){var O=this;return(0,i.A)(function*(){try{const L=[],Z=M.toLowerCase();return yield O.profileStore.iterate((q,re)=>{JSON.stringify(q).toLowerCase().includes(Z)&&L.push({pubKey:re,profile:q})}),L}catch(L){return console.error("Error searching profiles by metadata:",L),[]}})()}getLastUpdateDate(M){var O=this;return(0,i.A)(function*(){try{return(yield O.updateHistoryStore.getItem(M))||null}catch(L){return console.error("Error retrieving last update date:",L),null}})()}saveProject(M){var O=this;return(0,i.A)(function*(){try{yield O.projectsStore.setItem(M.projectIdentifier,M);const L=yield O.getAllProjects();O.projectsSubject.next(L),yield O.setUpdateHistory("projects")}catch(L){console.error("Error saving project:",L)}})()}getProjectsByNostrPubKeys(M){var O=this;return(0,i.A)(function*(){if(!M||0===M.length)return[];const L=[],Z=yield O.projectsStore.keys();for(const q of Z){const re=yield O.projectsStore.getItem(q);re&&M.includes(re.nostrPubKey)&&L.push(re)}return L})()}getAllProjects(){var M=this;return(0,i.A)(function*(){try{const O=[];return yield M.projectsStore.iterate(L=>{O.push(L)}),O}catch(O){return console.error("Error retrieving all projects:",O),[]}})()}getProjectStats(M){var O=this;return(0,i.A)(function*(){try{return(yield O.projectStatsStore.getItem(M))||null}catch(L){return console.error("Error retrieving project stats:",L),null}})()}saveProjectStats(M,O){var L=this;return(0,i.A)(function*(){try{yield L.projectStatsStore.setItem(M,O);const Z=yield L.getAllProjectStats();L.projectStatsSubject.next(Z),yield L.setUpdateHistory("projectStats")}catch(Z){console.error("Error saving project stats:",Z)}})()}getAllProjectStats(){var M=this;return(0,i.A)(function*(){try{const O={};return yield M.projectStatsStore.iterate((L,Z)=>{O[Z]=L}),O}catch(O){return console.error("Error retrieving all project stats:",O),{}}})()}savePost(M){var O=this;return(0,i.A)(function*(){try{yield O.postsStore.setItem(M.id,M),yield O.setUpdateHistory("posts"),O.postsSubject.next(M)}catch(L){console.error("Error saving event type 1 and sending it to clients:",L)}})()}getPostsByPubKey(M){var O=this;return(0,i.A)(function*(){try{const L=[];return yield O.postsStore.iterate(Z=>{Z.pubkey===M&&1===Z.kind&&L.push(Z)}),L.sort((Z,q)=>q.createdAt-Z.createdAt)}catch(L){return console.error("Error retrieving events for pubKey:",L),[]}})()}getPostById(M){var O=this;return(0,i.A)(function*(){try{let L=null;return yield O.postsStore.iterate(Z=>{if(Z.id===M&&1===Z.kind)return L=Z,L}),L}catch(L){return console.error("Error retrieving post by ID:",L),null}})()}getAllPostsWithPagination(M,O=10){var L=this;return(0,i.A)(function*(){try{const Z=[],q=(M-1)*O;return yield L.postsStore.iterate(re=>{1===re.kind&&Z.push(re)}),Z.sort((re,pe)=>pe.created_at-re.created_at).slice(q,q+O)}catch(Z){return console.error("Error retrieving all posts with pagination:",Z),[]}})()}getPostsByPubKeysWithPagination(M,O,L=10){var Z=this;return(0,i.A)(function*(){try{const q=[],re=(O-1)*L;return yield Z.postsStore.iterate(pe=>{M.includes(pe.pubkey)&&1===pe.kind&&q.push(pe)}),q.sort((pe,se)=>se.created_at-pe.created_at).slice(re,re+L)}catch(q){return console.error("Error retrieving events for pubKeys with pagination:",q),[]}})()}saveLike(M){var O=this;return(0,i.A)(function*(){try{yield O.myLikesStore.setItem(M.id,M);const L=yield O.getAllMyLikes();O.myLikesSubject.next(L),yield O.setUpdateHistory("myLikes")}catch(L){console.error("Error saving like:",L)}})()}getAllMyLikes(){var M=this;return(0,i.A)(function*(){try{const O=[];return yield M.myLikesStore.iterate(L=>{try{const Z=L.tags.find(q=>"e"===q[0]);Z&&O.push(Z[1])}catch(Z){console.warn("Error parsing like:",L,Z)}}),O}catch(O){return console.error("Error retrieving all likes:",O),[]}})()}saveNotification(M){var O=this;return(0,i.A)(function*(){try{yield O.notificationsStore.setItem(M.id,M);const L=yield O.getAllNotifications();O.notificationsSubject.next(L),yield O.setUpdateHistory("notifications")}catch(L){console.error("Error saving notification:",L)}})()}getAllNotifications(){var M=this;return(0,i.A)(function*(){try{const O=[];return yield M.notificationsStore.iterate(L=>{O.push(L)}),O}catch(O){return console.error("Error retrieving all notifications:",O),[]}})()}saveChatEvent(M){var O=this;return(0,i.A)(function*(){try{yield O.chatsStore.setItem(M.id,M),yield O.setUpdateHistory("chats");const L=yield O.getAllChatEvents();O.chatEventsSubject.next(L),O.updateUnreadChatCount(L)}catch(L){console.error("Error saving chat event:",L)}})()}getAllChatEvents(){var M=this;return(0,i.A)(function*(){try{const O=[];return yield M.chatsStore.iterate(L=>{O.push(L)}),O}catch(O){return console.error("Error retrieving all chat events:",O),[]}})()}getChatEventsByPubKey(M){var O=this;return(0,i.A)(function*(){try{const L=[];return yield O.chatsStore.iterate(Z=>{const q=O.getReceiverPubKeyFromTags(Z.tags);(Z.pubkey===M||q===M)&&L.push(Z)}),L}catch(L){return console.error("Error retrieving chat events by pubkey:",L),[]}})()}updateChatEventReadStatus(M,O){var L=this;return(0,i.A)(function*(){try{const Z=yield L.chatsStore.getItem(M);if(Z){Z.IsRead=O,yield L.chatsStore.setItem(M,Z);const q=yield L.getAllChatEvents();L.chatEventsSubject.next(q),L.updateUnreadChatCount(q)}}catch(Z){console.error("Error updating chat event read status:",Z)}})()}markAllChatEventsAsRead(M){var O=this;return(0,i.A)(function*(){try{yield O.chatsStore.iterate(function(){var Z=(0,i.A)(function*(q,re){const pe=O.getReceiverPubKeyFromTags(q.tags);(q.pubkey===M||pe===M)&&!q.IsRead&&(q.IsRead=!0,yield O.chatsStore.setItem(re,q))});return function(q,re){return Z.apply(this,arguments)}}());const L=yield O.getAllChatEvents();O.chatEventsSubject.next(L),O.updateUnreadChatCount(L)}catch(L){console.error("Error marking all chat events as read:",L)}})()}getReceiverPubKeyFromTags(M){for(const O of M)if("p"===O[0]&&O[1])return O[1];return null}updateUnreadChatCount(M){const O=M.filter(L=>!L.IsRead).length;this.unreadChatCountSubject.next(O)}removeAllChats(){var M=this;return(0,i.A)(function*(){try{yield M.chatsStore.clear(),M.chatEventsSubject.next([]),M.unreadChatCountSubject.next(0),console.log("All chat events have been removed successfully.")}catch(O){console.error("Error removing all chat events:",O)}})()}setUpdateHistory(M){var O=this;return(0,i.A)(function*(){try{const L=Math.floor(Date.now()/1e3);yield O.updateHistoryStore.setItem(M,L)}catch(L){console.error("Error updating history:",L)}})()}loadAllProjectsFromDB(){var M=this;return(0,i.A)(function*(){try{const O=yield M.getAllProjects();M.projectsSubject.next(O)}catch(O){console.error("Error loading projects from DB:",O)}})()}loadAllProjectStatsFromDB(){var M=this;return(0,i.A)(function*(){try{const O=yield M.getAllProjectStats();M.projectStatsSubject.next(O)}catch(O){console.error("Error loading project stats from DB:",O)}})()}loadAllChatEventsFromDB(){var M=this;return(0,i.A)(function*(){try{const O=yield M.getAllChatEvents();M.chatEventsSubject.next(O)}catch(O){console.error("Error loading chat events from DB:",O)}})()}loadPostsFromDB(M,O=10,L=0){var Z=this;return(0,i.A)(function*(){try{const q=[];return yield Z.postsStore.iterate(re=>{M.includes(re.pubkey)&&q.push(re)}),q.sort((re,pe)=>pe.created_at-re.created_at).slice(L,L+O)}catch(q){return console.error("Error retrieving events from DB:",q),[]}})()}loadPosts(M,O){var L=this;return(0,i.A)(function*(){const q=10*(O-1),re=yield L.loadPostsFromDB(M,10,q);re.length>0&&re.forEach(pe=>{L.postsSubject.next(pe)})})()}loadAllMyLikesFromDB(){var M=this;return(0,i.A)(function*(){try{const O=yield M.getAllMyLikes();M.myLikesSubject.next(O)}catch(O){console.error("Error loading likes from DB:",O)}})()}loadAllNotificationsFromDB(){var M=this;return(0,i.A)(function*(){try{const O=yield M.getAllNotifications();M.notificationsSubject.next(O)}catch(O){console.error("Error loading notifications from DB:",O)}})()}loadContactStatsFromDB(){var M=this;return(0,i.A)(function*(){try{let O=0,L=0,Z=0;yield M.contactsStore.iterate((q,re)=>{const[pe]=re.split(":");O++,q.isFollower?L++:Z++}),M.contactStatsSubject.next({totalContacts:O,followersCount:L,followingCount:Z})}catch(O){console.error("Error loading contact stats from DB:",O)}})()}static{this.\u0275fac=function(O){return new(O||T)}}static{this.\u0275prov=w.jDH({token:T,factory:T.\u0275fac,providedIn:"root"})}}return T})()},5506:(o,s,r)=>{"use strict";r.d(s,{n:()=>se});var a,i=r(1217),c=new Uint8Array(16);function y(){if(!a&&!(a=typeof crypto<"u"&&crypto.getRandomValues&&crypto.getRandomValues.bind(crypto)||typeof msCrypto<"u"&&"function"==typeof msCrypto.getRandomValues&&msCrypto.getRandomValues.bind(msCrypto)))throw new Error("crypto.getRandomValues() not supported. See https://github.com/uuidjs/uuid#getrandomvalues-not-supported");return a(c)}const w=/^(?:[0-9a-f]{8}-[0-9a-f]{4}-[1-5][0-9a-f]{3}-[89ab][0-9a-f]{3}-[0-9a-f]{12}|00000000-0000-0000-0000-000000000000)$/i;for(var S=[],M=0;M<256;++M)S.push((M+256).toString(16).substr(1));const L=function O(ae){var me=arguments.length>1&&void 0!==arguments[1]?arguments[1]:0,be=(S[ae[me+0]]+S[ae[me+1]]+S[ae[me+2]]+S[ae[me+3]]+"-"+S[ae[me+4]]+S[ae[me+5]]+"-"+S[ae[me+6]]+S[ae[me+7]]+"-"+S[ae[me+8]]+S[ae[me+9]]+"-"+S[ae[me+10]]+S[ae[me+11]]+S[ae[me+12]]+S[ae[me+13]]+S[ae[me+14]]+S[ae[me+15]]).toLowerCase();if(!function C(ae){return"string"==typeof ae&&w.test(ae)}(be))throw TypeError("Stringified UUID is invalid");return be},q=function Z(ae,me,be){var Oe=(ae=ae||{}).random||(ae.rng||y)();if(Oe[6]=15&Oe[6]|64,Oe[8]=63&Oe[8]|128,me){be=be||0;for(var xe=0;xe<16;++xe)me[be+xe]=Oe[xe];return me}return L(Oe)};var re=r(3107),pe=r(3125);let se=(()=>{class ae{constructor(be){this.relayService=be,this.subscriptions=new Map,this.activeRelays=[],this.pendingSubscriptions=new Map,this.subscriptionsSubject=new i.t(new Map),this.subscriptions$=this.subscriptionsSubject.asObservable(),this.subscriptionQueue=[],this.isProcessingQueue=!1,this.queueInterval=1e3,this.maxSubscriptionsPerBatch=5,this.debounceInterval=1e3,this.lastActionTimestamp=new Map,this.connectToAllRelays(),this.processSubscriptionQueue()}addSubscriptions(be,Oe,xe){const De=this.findExistingSubscription(be);if(De)return De.callbacks.push(Oe),De.id;const ce=q();this.lastActionTimestamp.set(ce,Date.now());const ue={filter:be,callbacks:[Oe],id:ce};return this.subscriptions.set(ue.id,ue),this.subscriptionsSubject.next(this.subscriptions),this.addToQueue(ue),ue.id}findExistingSubscription(be){return Array.from(this.subscriptions.values()).find(Oe=>JSON.stringify(Oe.filter)===JSON.stringify(be))}removeSubscriptionById(be){const Oe=Date.now(),xe=this.lastActionTimestamp.get(be);xe&&Oe-xe{this.subscriptionQueue.length>0&&this.subscriptionQueue.splice(0,this.maxSubscriptionsPerBatch).forEach(xe=>this.subscribeToRelays(xe.filter,xe))},this.queueInterval))}subscribeToRelays(be,Oe){0!==this.activeRelays.length?this.relayService.ensureConnectedRelays().then(()=>{const xe=this.relayService.getConnectedRelays();this.relayService.getPool().subscribeMany(xe,be,{onevent:De=>{Oe.callbacks.forEach(ce=>ce(De))},onclose:()=>console.log("Subscription closed")})}).catch(xe=>{console.error("Error subscribing to relays:",xe)}):this.pendingSubscriptions.set(Oe.id,Oe)}subscribeToAllRelays(){this.pendingSubscriptions.forEach(be=>{this.subscribeToRelays(be.filter,be)}),this.pendingSubscriptions.clear()}connectToAllRelays(){this.relayService.ensureConnectedRelays().then(()=>{this.activeRelays=this.relayService.getConnectedRelays(),this.subscribeToAllRelays()}).catch(be=>{console.error("Error connecting to relays:",be)})}clearAllSubscriptions(){this.subscriptions.clear(),this.pendingSubscriptions.clear(),this.subscriptionsSubject.next(new Map)}getSubscriptions(){return Array.from(this.subscriptions.values())}static{this.\u0275fac=function(Oe){return new(Oe||ae)(re.KVO(pe.b))}}static{this.\u0275prov=re.jDH({token:ae,factory:ae.\u0275fac,providedIn:"root"})}}return ae})()},2226:(o,s,r)=>{"use strict";r.d(s,{b:()=>q});var i=r(4460),a=r(936),c=r(9471),y=r(2902),w=r(7544),C=r(6071),T=r(3904),S=r(6389),M=r(4375),O=r(5785),L=r(3107);function Z(re,pe){1&re&&(L.j41(0,"mat-error"),L.EFF(1," Password is required "),L.k0s())}let q=(()=>{class re{constructor(se,ae,me){this.fb=se,this.dialogRef=ae,this.data=me,this.passwordForm=this.fb.group({password:["",a.k0.required],duration:["0",a.k0.required]})}onCancel(){this.dialogRef.close()}onSubmit(){this.dialogRef.close(this.passwordForm.value)}static{this.\u0275fac=function(ae){return new(ae||re)(L.rXU(a.ok),L.rXU(w.CP),L.rXU(w.Vh))}}static{this.\u0275cmp=L.VBU({type:re,selectors:[["password-dialog"]],decls:30,vars:5,consts:[["mat-dialog-title",""],["mat-dialog-content",""],[3,"formGroup"],[1,"w-full",3,"subscriptSizing"],["matPrefix",""],["matInput","","type","password",3,"formControlName"],[4,"ngIf"],[1,"mt-5","w-full"],["formControlName","duration"],["value","0"],["value","1"],["value","5"],["value","10"],["value","60"],["mat-dialog-actions",""],["mat-button","",3,"click"],["mat-raised-button","","color","primary",3,"click","disabled"]],template:function(ae,me){1&ae&&(L.j41(0,"h1",0),L.EFF(1,"Enter Password"),L.k0s(),L.j41(2,"div",1)(3,"form",2)(4,"mat-form-field",3)(5,"mat-label"),L.EFF(6,"Password"),L.k0s(),L.j41(7,"mat-icon",4),L.EFF(8,"lock"),L.k0s(),L.nrm(9,"input",5),L.DNE(10,Z,2,0,"mat-error",6),L.k0s(),L.j41(11,"mat-form-field",7)(12,"mat-label"),L.EFF(13,"Duration"),L.k0s(),L.j41(14,"mat-select",8)(15,"mat-option",9),L.EFF(16,"0 Minute"),L.k0s(),L.j41(17,"mat-option",10),L.EFF(18,"1 Minute"),L.k0s(),L.j41(19,"mat-option",11),L.EFF(20,"5 Minutes"),L.k0s(),L.j41(21,"mat-option",12),L.EFF(22,"10 Minutes"),L.k0s(),L.j41(23,"mat-option",13),L.EFF(24,"1 Hour"),L.k0s()()()()(),L.j41(25,"div",14)(26,"button",15),L.bIt("click",function(){return me.onCancel()}),L.EFF(27,"Cancel"),L.k0s(),L.j41(28,"button",16),L.bIt("click",function(){return me.onSubmit()}),L.EFF(29," Submit "),L.k0s()()),2&ae&&(L.R7$(3),L.Y8G("formGroup",me.passwordForm),L.R7$(),L.Y8G("subscriptSizing","dynamic"),L.R7$(5),L.Y8G("formControlName","password"),L.R7$(),L.Y8G("ngIf",me.passwordForm.get("password").hasError("required")),L.R7$(18),L.Y8G("disabled",me.passwordForm.invalid))},dependencies:[O.vg,c.Hl,c.$z,T.m_,T.An,a.YN,a.qT,a.me,a.BC,a.cb,y.wT,C.nJ,C.rl,a.X1,a.j4,a.JD,i.MD,i.bT,M.Ve,C.TL,C.JW,M.VO,C.RG,S.fS,S.fg],styles:[".full-width[_ngcontent-%COMP%]{width:100%}"],changeDetection:0})}}return re})()},770:(o,s,r)=>{"use strict";var i=r(6388),a=r(8716),c=r(3107);let y=(()=>{class v{constructor(){}static{this.\u0275fac=function(_){return new(_||v)}}static{this.\u0275cmp=c.VBU({type:v,selectors:[["app-root"]],decls:1,vars:0,template:function(_,D){1&_&&c.nrm(0,"router-outlet")},dependencies:[a.n3],styles:["[_nghost-%COMP%]{display:flex;flex:1 1 auto;width:100%;height:100%}"]})}}return v})();var w=r(3014);const C=new c.nKC("ANGOR_MOCK_API_DEFAULT_DELAY");var T=r(8915),S=r(1698),M=r(7610),O=r(3016);class L{constructor(m,d){this.url=m,this.delay=d,this._replyCount=0,this._replied=0}get response(){if(this._replyCount>0&&this._replyCount<=this._replied)return(0,T.$)(()=>new Error("Execution limit has been reached!"));if(!this._reply)return(0,T.$)(()=>new Error("Response callback function does not exist!"));if(!this.request)return(0,T.$)(()=>new Error("Request does not exist!"));this._replied++;const m=this._reply({request:this.request,urlParams:this.urlParams});return m instanceof S.c?m.pipe((0,M.s)(1)):(0,O.of)(m).pipe((0,M.s)(1))}reply(m){this._reply=m}replyCount(m){this._replyCount=m}}var Z=r(6143);let q=(()=>{class v{constructor(){this._handlers={get:new Map,post:new Map,patch:new Map,delete:new Map,put:new Map,head:new Map,jsonp:new Map,options:new Map}}findHandler(d,_){const D={handler:void 0,urlParams:{}},V=_.split("/"),J=this._handlers[d.toLowerCase()];for(const[we,Xe]of J){const yt=we.split("/");if(V.length===yt.length&&yt.every((_n,gr)=>_n.startsWith(":")||_n===V[gr])){D.handler=Xe,D.urlParams=(0,Z.A)(yt.map((_n,gr)=>_n.startsWith(":")?[_n.substring(1),V[gr]]:void 0).filter(Boolean));break}}return D}onGet(d,_){return this._registerHandler("get",d,_)}onPost(d,_){return this._registerHandler("post",d,_)}onPatch(d,_){return this._registerHandler("patch",d,_)}onDelete(d,_){return this._registerHandler("delete",d,_)}onPut(d,_){return this._registerHandler("put",d,_)}onHead(d,_){return this._registerHandler("head",d,_)}onJsonp(d,_){return this._registerHandler("jsonp",d,_)}onOptions(d,_){return this._registerHandler("options",d,_)}_registerHandler(d,_,D){const V=new L(_,D);return this._handlers[d].set(_,V),V}static{this.\u0275fac=function(_){return new(_||v)}}static{this.\u0275prov=c.jDH({token:v,factory:v.\u0275fac,providedIn:"root"})}}return v})();var re=r(7691),pe=r(8136),se=r(2867);const ae=(v,m)=>{const d=(0,c.WQX)(C),_=(0,c.WQX)(q),{handler:D,urlParams:V}=_.findHandler(v.method.toUpperCase(),v.url);return D?(D.request=v,D.urlParams=V,D.response.pipe((0,pe.c)(D.delay??d??0),(0,se.n)(J=>{if(!J)return(0,T.$)(()=>new re.yz({error:"NOT FOUND",status:404,statusText:"NOT FOUND"}));const we={status:J[0],body:J[1]};return we.status>=200&&we.status<300?(0,O.of)(new re.cS({body:we.body,status:we.status,statusText:"OK"})):(0,T.$)(()=>new re.yz({error:we.body?.error,status:we.status,statusText:"ERROR"}))}))):m(v)};var me=r(7891),be=r(7153),Oe=r(1217);let xe=(()=>{class v{constructor(){this._auto$=new Oe.t(!0),this._mode$=new Oe.t("indeterminate"),this._progress$=new Oe.t(0),this._show$=new Oe.t(!1),this._urlMap=new Map}get auto$(){return this._auto$.asObservable()}get mode$(){return this._mode$.asObservable()}get progress$(){return this._progress$.asObservable()}get show$(){return this._show$.asObservable()}show(){this._show$.next(!0)}hide(){this._show$.next(!1)}setAutoMode(d){this._auto$.next(d)}setMode(d){this._mode$.next(d)}setProgress(d){d<0||d>100?console.error("Progress value must be between 0 and 100!"):this._progress$.next(d)}_setLoadingStatus(d,_){_?(!0===d?(this._urlMap.set(_,d),this._show$.next(!0)):!1===d&&this._urlMap.has(_)&&this._urlMap.delete(_),0===this._urlMap.size&&this._show$.next(!1)):console.error("The request URL must be provided!")}static{this.\u0275fac=function(_){return new(_||v)}}static{this.\u0275prov=c.jDH({token:v,factory:v.\u0275fac,providedIn:"root"})}}return v})();var De=r(4447);const ce=(v,m)=>{const d=(0,c.WQX)(xe);let _=!1;return d.auto$.pipe((0,M.s)(1)).subscribe(D=>{_=D}),_?(d._setLoadingStatus(!0,v.url),m(v).pipe((0,De.j)(()=>{d._setLoadingStatus(!1,v.url)}))):m(v)};var ue=r(2012),Ce=r(2147);let Be=(()=>{class v{constructor(){this._platform=(0,c.WQX)(Ce.OD),this.osName="os-unknown",this._platform.isBrowser&&(navigator.userAgent.includes("Win")&&(this.osName="os-windows"),navigator.userAgent.includes("Mac")&&(this.osName="os-mac"),navigator.userAgent.includes("X11")&&(this.osName="os-unix"),navigator.userAgent.includes("Linux")&&(this.osName="os-linux"),this._platform.IOS&&(this.osName="os-ios"),this._platform.ANDROID&&(this.osName="os-android"))}static{this.\u0275fac=function(_){return new(_||v)}}static{this.\u0275prov=c.jDH({token:v,factory:v.\u0275fac,providedIn:"root"})}}return v})();var at=r(4460),dt=r(1483);let bt=(()=>{class v{constructor(){this._document=(0,c.WQX)(at.qQ),this._router=(0,c.WQX)(a.Ix),this._router.events.pipe((0,dt.p)(d=>d instanceof a.wF),(0,M.s)(1)).subscribe(()=>{this.hide()})}show(){this._document.body.classList.remove("angor-splash-screen-hidden")}hide(){this._document.body.classList.add("angor-splash-screen-hidden")}static{this.\u0275fac=function(_){return new(_||v)}}static{this.\u0275prov=c.jDH({token:v,factory:v.\u0275fac,providedIn:"root"})}}return v})();var lt=r(3939),rn=r(2902),gn=r(7544),bn=r(6071);class yn extends Error{}class qe extends yn{constructor(m){super(`Invalid DateTime: ${m.toMessage()}`)}}class _t extends yn{constructor(m){super(`Invalid Interval: ${m.toMessage()}`)}}class ze extends yn{constructor(m){super(`Invalid Duration: ${m.toMessage()}`)}}class $e extends yn{}class Ft extends yn{constructor(m){super(`Invalid unit ${m}`)}}class Ke extends yn{}class Ze extends yn{constructor(){super("Zone is an abstract class")}}const it="numeric",Ot="short",$t="long",Te={year:it,month:it,day:it},Ee={year:it,month:Ot,day:it},st={year:it,month:Ot,day:it,weekday:Ot},Xt={year:it,month:$t,day:it},Mt={year:it,month:$t,day:it,weekday:$t},Kt={hour:it,minute:it},rt={hour:it,minute:it,second:it},Vt={hour:it,minute:it,second:it,timeZoneName:Ot},en={hour:it,minute:it,second:it,timeZoneName:$t},kn={hour:it,minute:it,hourCycle:"h23"},Kn={hour:it,minute:it,second:it,hourCycle:"h23"},Nr={hour:it,minute:it,second:it,hourCycle:"h23",timeZoneName:Ot},Rn={hour:it,minute:it,second:it,hourCycle:"h23",timeZoneName:$t},pr={year:it,month:it,day:it,hour:it,minute:it},cn={year:it,month:it,day:it,hour:it,minute:it,second:it},Fe={year:it,month:Ot,day:it,hour:it,minute:it},ke={year:it,month:Ot,day:it,hour:it,minute:it,second:it},Je={year:it,month:Ot,day:it,weekday:Ot,hour:it,minute:it},z={year:it,month:$t,day:it,hour:it,minute:it,timeZoneName:Ot},N={year:it,month:$t,day:it,hour:it,minute:it,second:it,timeZoneName:Ot},W={year:it,month:$t,day:it,weekday:$t,hour:it,minute:it,timeZoneName:$t},Le={year:it,month:$t,day:it,weekday:$t,hour:it,minute:it,second:it,timeZoneName:$t};class ft{get type(){throw new Ze}get name(){throw new Ze}get ianaName(){return this.name}get isUniversal(){throw new Ze}offsetName(m,d){throw new Ze}formatOffset(m,d){throw new Ze}offset(m){throw new Ze}equals(m){throw new Ze}get isValid(){throw new Ze}}let mt=null;class St extends ft{static get instance(){return null===mt&&(mt=new St),mt}get type(){return"system"}get name(){return(new Intl.DateTimeFormat).resolvedOptions().timeZone}get isUniversal(){return!1}offsetName(m,{format:d,locale:_}){return lr(m,d,_)}formatOffset(m,d){return la(this.offset(m),d)}offset(m){return-new Date(m).getTimezoneOffset()}equals(m){return"system"===m.type}get isValid(){return!0}}let Tn={};const dn={year:0,month:1,day:2,era:3,hour:4,minute:5,second:6};let xn={};class Hr extends ft{static create(m){return xn[m]||(xn[m]=new Hr(m)),xn[m]}static resetCache(){xn={},Tn={}}static isValidSpecifier(m){return this.isValidZone(m)}static isValidZone(m){if(!m)return!1;try{return new Intl.DateTimeFormat("en-US",{timeZone:m}).format(),!0}catch{return!1}}constructor(m){super(),this.zoneName=m,this.valid=Hr.isValidZone(m)}get type(){return"iana"}get name(){return this.zoneName}get isUniversal(){return!1}offsetName(m,{format:d,locale:_}){return lr(m,d,_,this.name)}formatOffset(m,d){return la(this.offset(m),d)}offset(m){const d=new Date(m);if(isNaN(d))return NaN;const _=function an(v){return Tn[v]||(Tn[v]=new Intl.DateTimeFormat("en-US",{hour12:!1,timeZone:v,year:"numeric",month:"2-digit",day:"2-digit",hour:"2-digit",minute:"2-digit",second:"2-digit",era:"short"})),Tn[v]}(this.name);let[D,V,J,we,Xe,yt,un]=_.formatToParts?function sr(v,m){const d=v.formatToParts(m),_=[];for(let D=0;D=0?fr:1e3+fr,(Xo({year:D,month:V,day:J,hour:24===Xe?0:Xe,minute:yt,second:un,millisecond:0})-er)/6e4}equals(m){return"iana"===m.type&&m.name===this.name}get isValid(){return this.valid}}let Tr={},vt={};function Wt(v,m={}){const d=JSON.stringify([v,m]);let _=vt[d];return _||(_=new Intl.DateTimeFormat(v,m),vt[d]=_),_}let Re={},Ve={},ct=null,wn={};function Jt(v,m,d,_){const D=v.listingMode();return"error"===D?null:"en"===D?d(m):_(m)}class nt{constructor(m,d,_){this.padTo=_.padTo||0,this.floor=_.floor||!1;const{padTo:D,floor:V,...J}=_;if(!d||Object.keys(J).length>0){const we={useGrouping:!1,..._};_.padTo>0&&(we.minimumIntegerDigits=_.padTo),this.inf=function Ge(v,m={}){const d=JSON.stringify([v,m]);let _=Re[d];return _||(_=new Intl.NumberFormat(v,m),Re[d]=_),_}(m,we)}}format(m){if(this.inf){const d=this.floor?Math.floor(m):m;return this.inf.format(d)}return mo(this.floor?Math.floor(m):Ds(m,3),this.padTo)}}class Rt{constructor(m,d,_){let D;if(this.opts=_,this.originalZone=void 0,this.opts.timeZone)this.dt=m;else if("fixed"===m.zone.type){const J=m.offset/60*-1,we=J>=0?`Etc/GMT+${J}`:`Etc/GMT${J}`;0!==m.offset&&Hr.create(we).valid?(D=we,this.dt=m):(D="UTC",this.dt=0===m.offset?m:m.setZone("UTC").plus({minutes:m.offset}),this.originalZone=m.zone)}else"system"===m.zone.type?this.dt=m:"iana"===m.zone.type?(this.dt=m,D=m.zone.name):(D="UTC",this.dt=m.setZone("UTC").plus({minutes:m.offset}),this.originalZone=m.zone);const V={...this.opts};V.timeZone=V.timeZone||D,this.dtf=Wt(d,V)}format(){return this.originalZone?this.formatToParts().map(({value:m})=>m).join(""):this.dtf.format(this.dt.toJSDate())}formatToParts(){const m=this.dtf.formatToParts(this.dt.toJSDate());return this.originalZone?m.map(d=>{if("timeZoneName"===d.type){const _=this.originalZone.offsetName(this.dt.ts,{locale:this.dt.locale,format:this.opts.timeZoneName});return{...d,value:_}}return d}):m}resolvedOptions(){return this.dtf.resolvedOptions()}}class sn{constructor(m,d,_){this.opts={style:"long",..._},!d&&Li()&&(this.rtf=function Dt(v,m={}){const{base:d,..._}=m,D=JSON.stringify([v,_]);let V=Ve[D];return V||(V=new Intl.RelativeTimeFormat(v,m),Ve[D]=V),V}(m,_))}format(m,d){return this.rtf?this.rtf.format(m,d):function te(v,m,d="always",_=!1){const D={years:["year","yr."],quarters:["quarter","qtr."],months:["month","mo."],weeks:["week","wk."],days:["day","day","days"],hours:["hour","hr."],minutes:["minute","min."],seconds:["second","sec."]},V=-1===["hours","minutes","seconds"].indexOf(v);if("auto"===d&&V){const _n="days"===v;switch(m){case 1:return _n?"tomorrow":`next ${D[v][0]}`;case-1:return _n?"yesterday":`last ${D[v][0]}`;case 0:return _n?"today":`this ${D[v][0]}`}}const J=Object.is(m,-0)||m<0,we=Math.abs(m),Xe=1===we,yt=D[v],un=_?Xe?yt[1]:yt[2]||yt[1]:Xe?D[v][0]:v;return J?`${we} ${un} ago`:`in ${we} ${un}`}(d,m,this.opts.numeric,"long"!==this.opts.style)}formatToParts(m,d){return this.rtf?this.rtf.formatToParts(m,d):[]}}const mn={firstDay:1,minimalDays:4,weekend:[6,7]};class dr{static fromOpts(m){return dr.create(m.locale,m.numberingSystem,m.outputCalendar,m.weekSettings,m.defaultToEN)}static create(m,d,_,D,V=!1){const J=m||Ne.defaultLocale,we=J||(V?"en-US":function Bt(){return ct||(ct=(new Intl.DateTimeFormat).resolvedOptions().locale,ct)}()),Xe=d||Ne.defaultNumberingSystem,yt=_||Ne.defaultOutputCalendar,un=No(D)||Ne.defaultWeekSettings;return new dr(we,Xe,yt,un,J)}static resetCache(){ct=null,vt={},Re={},Ve={}}static fromObject({locale:m,numberingSystem:d,outputCalendar:_,weekSettings:D}={}){return dr.create(m,d,_,D)}constructor(m,d,_,D,V){const[J,we,Xe]=function Er(v){const m=v.indexOf("-x-");-1!==m&&(v=v.substring(0,m));const d=v.indexOf("-u-");if(-1===d)return[v];{let _,D;try{_=Wt(v).resolvedOptions(),D=v}catch{const Xe=v.substring(0,d);_=Wt(Xe).resolvedOptions(),D=Xe}const{numberingSystem:V,calendar:J}=_;return[D,V,J]}}(m);this.locale=J,this.numberingSystem=d||we||null,this.outputCalendar=_||Xe||null,this.weekSettings=D,this.intl=function si(v,m,d){return(d||m)&&(v.includes("-u-")||(v+="-u"),d&&(v+=`-ca-${d}`),m&&(v+=`-nu-${m}`)),v}(this.locale,this.numberingSystem,this.outputCalendar),this.weekdaysCache={format:{},standalone:{}},this.monthsCache={format:{},standalone:{}},this.meridiemCache=null,this.eraCache={},this.specifiedLocale=V,this.fastNumbersCached=null}get fastNumbers(){return null==this.fastNumbersCached&&(this.fastNumbersCached=function Tt(v){return(!v.numberingSystem||"latn"===v.numberingSystem)&&("latn"===v.numberingSystem||!v.locale||v.locale.startsWith("en")||"latn"===new Intl.DateTimeFormat(v.intl).resolvedOptions().numberingSystem)}(this)),this.fastNumbersCached}listingMode(){return this.isEnglish()&&!(null!==this.numberingSystem&&"latn"!==this.numberingSystem||null!==this.outputCalendar&&"gregory"!==this.outputCalendar)?"en":"intl"}clone(m){return m&&0!==Object.getOwnPropertyNames(m).length?dr.create(m.locale||this.specifiedLocale,m.numberingSystem||this.numberingSystem,m.outputCalendar||this.outputCalendar,No(m.weekSettings)||this.weekSettings,m.defaultToEN||!1):this}redefaultToEN(m={}){return this.clone({...m,defaultToEN:!0})}redefaultToSystem(m={}){return this.clone({...m,defaultToEN:!1})}months(m,d=!1){return Jt(this,m,Ts,()=>{const _=d?{month:m,day:"numeric"}:{month:m},D=d?"format":"standalone";return this.monthsCache[D][m]||(this.monthsCache[D][m]=function hi(v){const m=[];for(let d=1;d<=12;d++){const _=Fr.utc(2009,d,1);m.push(v(_))}return m}(V=>this.extract(V,_,"month"))),this.monthsCache[D][m]})}weekdays(m,d=!1){return Jt(this,m,lo,()=>{const _=d?{weekday:m,year:"numeric",month:"long",day:"numeric"}:{weekday:m},D=d?"format":"standalone";return this.weekdaysCache[D][m]||(this.weekdaysCache[D][m]=function Zi(v){const m=[];for(let d=1;d<=7;d++){const _=Fr.utc(2016,11,13+d);m.push(v(_))}return m}(V=>this.extract(V,_,"weekday"))),this.weekdaysCache[D][m]})}meridiems(){return Jt(this,void 0,()=>ps,()=>{if(!this.meridiemCache){const m={hour:"numeric",hourCycle:"h12"};this.meridiemCache=[Fr.utc(2016,11,13,9),Fr.utc(2016,11,13,19)].map(d=>this.extract(d,m,"dayperiod"))}return this.meridiemCache})}eras(m){return Jt(this,m,ua,()=>{const d={era:m};return this.eraCache[m]||(this.eraCache[m]=[Fr.utc(-40,1,1),Fr.utc(2017,1,1)].map(_=>this.extract(_,d,"era"))),this.eraCache[m]})}extract(m,d,_){const J=this.dtFormatter(m,d).formatToParts().find(we=>we.type.toLowerCase()===_);return J?J.value:null}numberFormatter(m={}){return new nt(this.intl,m.forceSimple||this.fastNumbers,m)}dtFormatter(m,d={}){return new Rt(m,this.intl,d)}relFormatter(m={}){return new sn(this.intl,this.isEnglish(),m)}listFormatter(m={}){return function Vr(v,m={}){const d=JSON.stringify([v,m]);let _=Tr[d];return _||(_=new Intl.ListFormat(v,m),Tr[d]=_),_}(this.intl,m)}isEnglish(){return"en"===this.locale||"en-us"===this.locale.toLowerCase()||new Intl.DateTimeFormat(this.intl).resolvedOptions().locale.startsWith("en-us")}getWeekSettings(){return this.weekSettings?this.weekSettings:bi()?function qn(v){let m=wn[v];if(!m){const d=new Intl.Locale(v);m="getWeekInfo"in d?d.getWeekInfo():d.weekInfo,wn[v]=m}return m}(this.locale):mn}getStartOfWeek(){return this.getWeekSettings().firstDay}getMinDaysInFirstWeek(){return this.getWeekSettings().minimalDays}getWeekendDays(){return this.getWeekSettings().weekend}equals(m){return this.locale===m.locale&&this.numberingSystem===m.numberingSystem&&this.outputCalendar===m.outputCalendar}toString(){return`Locale(${this.locale}, ${this.numberingSystem}, ${this.outputCalendar})`}}let Co=null;class Ni extends ft{static get utcInstance(){return null===Co&&(Co=new Ni(0)),Co}static instance(m){return 0===m?Ni.utcInstance:new Ni(m)}static parseSpecifier(m){if(m){const d=m.match(/^utc(?:([+-]\d{1,2})(?::(\d{2}))?)?$/i);if(d)return new Ni(As(d[1],d[2]))}return null}constructor(m){super(),this.fixed=m}get type(){return"fixed"}get name(){return 0===this.fixed?"UTC":`UTC${la(this.fixed,"narrow")}`}get ianaName(){return 0===this.fixed?"Etc/UTC":`Etc/GMT${la(-this.fixed,"narrow")}`}offsetName(){return this.name}formatOffset(m,d){return la(this.fixed,d)}get isUniversal(){return!0}offset(){return this.fixed}equals(m){return"fixed"===m.type&&m.fixed===this.fixed}get isValid(){return!0}}class ds extends ft{constructor(m){super(),this.zoneName=m}get type(){return"invalid"}get name(){return this.zoneName}get isUniversal(){return!1}offsetName(){return null}formatOffset(){return""}offset(){return NaN}equals(){return!1}get isValid(){return!1}}function $o(v,m){if(Pr(v)||null===v)return m;if(v instanceof ft)return v;if(function zs(v){return"string"==typeof v}(v)){const _=v.toLowerCase();return"default"===_?m:"local"===_||"system"===_?St.instance:"utc"===_||"gmt"===_?Ni.utcInstance:Ni.parseSpecifier(_)||Hr.create(v)}return Do(v)?Ni.instance(v):"object"==typeof v&&"offset"in v&&"function"==typeof v.offset?v:new ds(v)}const ai={arab:"[\u0660-\u0669]",arabext:"[\u06f0-\u06f9]",bali:"[\u1b50-\u1b59]",beng:"[\u09e6-\u09ef]",deva:"[\u0966-\u096f]",fullwide:"[\uff10-\uff19]",gujr:"[\u0ae6-\u0aef]",hanidec:"[\u3007|\u4e00|\u4e8c|\u4e09|\u56db|\u4e94|\u516d|\u4e03|\u516b|\u4e5d]",khmr:"[\u17e0-\u17e9]",knda:"[\u0ce6-\u0cef]",laoo:"[\u0ed0-\u0ed9]",limb:"[\u1946-\u194f]",mlym:"[\u0d66-\u0d6f]",mong:"[\u1810-\u1819]",mymr:"[\u1040-\u1049]",orya:"[\u0b66-\u0b6f]",tamldec:"[\u0be6-\u0bef]",telu:"[\u0c66-\u0c6f]",thai:"[\u0e50-\u0e59]",tibt:"[\u0f20-\u0f29]",latn:"\\d"},qo={arab:[1632,1641],arabext:[1776,1785],bali:[6992,7001],beng:[2534,2543],deva:[2406,2415],fullwide:[65296,65303],gujr:[2790,2799],khmr:[6112,6121],knda:[3302,3311],laoo:[3792,3801],limb:[6470,6479],mlym:[3430,3439],mong:[6160,6169],mymr:[4160,4169],orya:[2918,2927],tamldec:[3046,3055],telu:[3174,3183],thai:[3664,3673],tibt:[3872,3881]},fo=ai.hanidec.replace(/[\[|\]]/g,"").split("");let Fo={};function ao({numberingSystem:v},m=""){const d=v||"latn";return Fo[d]||(Fo[d]={}),Fo[d][m]||(Fo[d][m]=new RegExp(`${ai[d]}${m}`)),Fo[d][m]}let ve,po=()=>Date.now(),Ii="system",Io=null,tt=null,xt=null,ht=60,Ye=null;class Ne{static get now(){return po}static set now(m){po=m}static set defaultZone(m){Ii=m}static get defaultZone(){return $o(Ii,St.instance)}static get defaultLocale(){return Io}static set defaultLocale(m){Io=m}static get defaultNumberingSystem(){return tt}static set defaultNumberingSystem(m){tt=m}static get defaultOutputCalendar(){return xt}static set defaultOutputCalendar(m){xt=m}static get defaultWeekSettings(){return Ye}static set defaultWeekSettings(m){Ye=No(m)}static get twoDigitCutoffYear(){return ht}static set twoDigitCutoffYear(m){ht=m%100}static get throwOnInvalid(){return ve}static set throwOnInvalid(m){ve=m}static resetCaches(){dr.resetCache(),Hr.resetCache(),Fr.resetCache(),function oa(){Fo={}}()}}class gt{constructor(m,d){this.reason=m,this.explanation=d}toMessage(){return this.explanation?`${this.reason}: ${this.explanation}`:this.reason}}const Ht=[0,31,59,90,120,151,181,212,243,273,304,334],kt=[0,31,60,91,121,152,182,213,244,274,305,335];function hn(v,m){return new gt("unit out of range",`you specified ${m} (of type ${typeof m}) as a ${v}, which is invalid`)}function Dn(v,m,d){const _=new Date(Date.UTC(v,m-1,d));v<100&&v>=0&&_.setUTCFullYear(_.getUTCFullYear()-1900);const D=_.getUTCDay();return 0===D?7:D}function Cn(v,m,d){return d+(go(v)?kt:Ht)[m-1]}function Nn(v,m){const d=go(v)?kt:Ht,_=d.findIndex(V=>V_o(_,m,d)?(yt=_+1,Xe=1):yt=_,{weekYear:yt,weekNumber:Xe,weekday:we,...ls(v)}}function ar(v,m=4,d=1){const{weekYear:_,weekNumber:D,weekday:V}=v,J=jn(Dn(_,1,m),d),we=io(_);let yt,Xe=7*D+V-J-7+m;Xe<1?(yt=_-1,Xe+=io(yt)):Xe>we?(yt=_+1,Xe-=io(_)):yt=_;const{month:un,day:_n}=Nn(yt,Xe);return{year:yt,month:un,day:_n,...ls(v)}}function wr(v){const{year:m,month:d,day:_}=v;return{year:m,ordinal:Cn(m,d,_),...ls(v)}}function xr(v){const{year:m,ordinal:d}=v,{month:_,day:D}=Nn(m,d);return{year:m,month:_,day:D,...ls(v)}}function gi(v,m){if(Pr(v.localWeekday)&&Pr(v.localWeekNumber)&&Pr(v.localWeekYear))return{minDaysInFirstWeek:4,startOfWeek:1};if(!Pr(v.weekday)||!Pr(v.weekNumber)||!Pr(v.weekYear))throw new $e("Cannot mix locale-based week fields with ISO-based week fields");return Pr(v.localWeekday)||(v.weekday=v.localWeekday),Pr(v.localWeekNumber)||(v.weekNumber=v.localWeekNumber),Pr(v.localWeekYear)||(v.weekYear=v.localWeekYear),delete v.localWeekday,delete v.localWeekNumber,delete v.localWeekYear,{minDaysInFirstWeek:m.getMinDaysInFirstWeek(),startOfWeek:m.getStartOfWeek()}}function Or(v){const m=es(v.year),d=hs(v.month,1,12),_=hs(v.day,1,fs(v.year,v.month));return m?d?!_&&hn("day",v.day):hn("month",v.month):hn("year",v.year)}function Qr(v){const{hour:m,minute:d,second:_,millisecond:D}=v,V=hs(m,0,23)||24===m&&0===d&&0===_&&0===D,J=hs(d,0,59),we=hs(_,0,59),Xe=hs(D,0,999);return V?J?we?!Xe&&hn("millisecond",D):hn("second",_):hn("minute",d):hn("hour",m)}function Pr(v){return typeof v>"u"}function Do(v){return"number"==typeof v}function es(v){return"number"==typeof v&&v%1==0}function Li(){try{return typeof Intl<"u"&&!!Intl.RelativeTimeFormat}catch{return!1}}function bi(){try{return typeof Intl<"u"&&!!Intl.Locale&&("weekInfo"in Intl.Locale.prototype||"getWeekInfo"in Intl.Locale.prototype)}catch{return!1}}function Ks(v,m,d){if(0!==v.length)return v.reduce((_,D)=>{const V=[m(D),D];return _&&d(_[0],V[0])===_[0]?_:V},null)[1]}function Cs(v,m){return Object.prototype.hasOwnProperty.call(v,m)}function No(v){if(null==v)return null;if("object"!=typeof v)throw new Ke("Week settings must be an object");if(!hs(v.firstDay,1,7)||!hs(v.minimalDays,1,7)||!Array.isArray(v.weekend)||v.weekend.some(m=>!hs(m,1,7)))throw new Ke("Invalid week settings");return{firstDay:v.firstDay,minimalDays:v.minimalDays,weekend:Array.from(v.weekend)}}function hs(v,m,d){return es(v)&&v>=m&&v<=d}function mo(v,m=2){let _;return _=v<0?"-"+(""+-v).padStart(m,"0"):(""+v).padStart(m,"0"),_}function Go(v){if(!Pr(v)&&null!==v&&""!==v)return parseInt(v,10)}function Rs(v){if(!Pr(v)&&null!==v&&""!==v)return parseFloat(v)}function Xr(v){if(!Pr(v)&&null!==v&&""!==v){const m=1e3*parseFloat("0."+v);return Math.floor(m)}}function Ds(v,m,d=!1){const _=10**m;return(d?Math.trunc:Math.round)(v*_)/_}function go(v){return v%4==0&&(v%100!=0||v%400==0)}function io(v){return go(v)?366:365}function fs(v,m){const d=function Ko(v,m){return v-m*Math.floor(v/m)}(m-1,12)+1;return 2===d?go(v+(m-d)/12)?29:28:[31,null,31,30,31,30,31,31,30,31,30,31][d-1]}function Xo(v){let m=Date.UTC(v.year,v.month-1,v.day,v.hour,v.minute,v.second,v.millisecond);return v.year<100&&v.year>=0&&(m=new Date(m),m.setUTCFullYear(v.year,v.month-1,v.day)),+m}function Qa(v,m,d){return-jn(Dn(v,1,m),d)+m-1}function _o(v,m=4,d=1){const _=Qa(v,m,d),D=Qa(v+1,m,d);return(io(v)-_+D)/7}function Ao(v){return v>99?v:v>Ne.twoDigitCutoffYear?1900+v:2e3+v}function lr(v,m,d,_=null){const D=new Date(v),V={hourCycle:"h23",year:"numeric",month:"2-digit",day:"2-digit",hour:"2-digit",minute:"2-digit"};_&&(V.timeZone=_);const J={timeZoneName:m,...V},we=new Intl.DateTimeFormat(d,J).formatToParts(D).find(Xe=>"timezonename"===Xe.type.toLowerCase());return we?we.value:null}function As(v,m){let d=parseInt(v,10);Number.isNaN(d)&&(d=0);const _=parseInt(m,10)||0;return 60*d+(d<0||Object.is(d,-0)?-_:_)}function Gs(v){const m=Number(v);if("boolean"==typeof v||""===v||Number.isNaN(m))throw new Ke(`Invalid unit value ${v}`);return m}function _s(v,m){const d={};for(const _ in v)if(Cs(v,_)){const D=v[_];if(null==D)continue;d[m(_)]=Gs(D)}return d}function la(v,m){const d=Math.trunc(Math.abs(v/60)),_=Math.trunc(Math.abs(v%60)),D=v>=0?"+":"-";switch(m){case"short":return`${D}${mo(d,2)}:${mo(_,2)}`;case"narrow":return`${D}${d}${_>0?`:${_}`:""}`;case"techie":return`${D}${mo(d,2)}${mo(_,2)}`;default:throw new RangeError(`Value format ${m} is out of range for property format`)}}function ls(v){return function Oo(v,m){return m.reduce((d,_)=>(d[_]=v[_],d),{})}(v,["hour","minute","second","millisecond"])}const ll=["January","February","March","April","May","June","July","August","September","October","November","December"],ca=["Jan","Feb","Mar","Apr","May","Jun","Jul","Aug","Sep","Oct","Nov","Dec"],Ss=["J","F","M","A","M","J","J","A","S","O","N","D"];function Ts(v){switch(v){case"narrow":return[...Ss];case"short":return[...ca];case"long":return[...ll];case"numeric":return["1","2","3","4","5","6","7","8","9","10","11","12"];case"2-digit":return["01","02","03","04","05","06","07","08","09","10","11","12"];default:return null}}const Ns=["Monday","Tuesday","Wednesday","Thursday","Friday","Saturday","Sunday"],So=["Mon","Tue","Wed","Thu","Fri","Sat","Sun"],Bo=["M","T","W","T","F","S","S"];function lo(v){switch(v){case"narrow":return[...Bo];case"short":return[...So];case"long":return[...Ns];case"numeric":return["1","2","3","4","5","6","7"];default:return null}}const ps=["AM","PM"],Da=["Before Christ","Anno Domini"],Ms=["BC","AD"],Us=["B","A"];function ua(v){switch(v){case"narrow":return[...Us];case"short":return[...Ms];case"long":return[...Da];default:return null}}function Ct(v,m){let d="";for(const _ of v)d+=_.literal?_.val:m(_.val);return d}const Bn={D:Te,DD:Ee,DDD:Xt,DDDD:Mt,t:Kt,tt:rt,ttt:Vt,tttt:en,T:kn,TT:Kn,TTT:Nr,TTTT:Rn,f:pr,ff:Fe,fff:z,ffff:W,F:cn,FF:ke,FFF:N,FFFF:Le};class On{static create(m,d={}){return new On(m,d)}static parseFormat(m){let d=null,_="",D=!1;const V=[];for(let J=0;J0&&V.push({literal:D||/^\s+$/.test(_),val:_}),d=null,_="",D=!D):D||we===d?_+=we:(_.length>0&&V.push({literal:/^\s+$/.test(_),val:_}),_=we,d=we)}return _.length>0&&V.push({literal:D||/^\s+$/.test(_),val:_}),V}static macroTokenToFormatOpts(m){return Bn[m]}constructor(m,d){this.opts=d,this.loc=m,this.systemLoc=null}formatWithSystemDefault(m,d){return null===this.systemLoc&&(this.systemLoc=this.loc.redefaultToSystem()),this.systemLoc.dtFormatter(m,{...this.opts,...d}).format()}dtFormatter(m,d={}){return this.loc.dtFormatter(m,{...this.opts,...d})}formatDateTime(m,d){return this.dtFormatter(m,d).format()}formatDateTimeParts(m,d){return this.dtFormatter(m,d).formatToParts()}formatInterval(m,d){return this.dtFormatter(m.start,d).dtf.formatRange(m.start.toJSDate(),m.end.toJSDate())}resolvedOptions(m,d){return this.dtFormatter(m,d).resolvedOptions()}num(m,d=0){if(this.opts.forceSimple)return mo(m,d);const _={...this.opts};return d>0&&(_.padTo=d),this.loc.numberFormatter(_).format(m)}formatDateTimeFromString(m,d){const _="en"===this.loc.listingMode(),D=this.loc.outputCalendar&&"gregory"!==this.loc.outputCalendar,V=(er,fr)=>this.loc.extract(m,er,fr),J=er=>m.isOffsetFixed&&0===m.offset&&er.allowZ?"Z":m.isValid?m.zone.formatOffset(m.ts,er.format):"",Xe=(er,fr)=>_?function Q(v,m){return Ts(m)[v.month-1]}(m,er):V(fr?{month:er}:{month:er,day:"numeric"},"month"),yt=(er,fr)=>_?function Aa(v,m){return lo(m)[v.weekday-1]}(m,er):V(fr?{weekday:er}:{weekday:er,month:"long",day:"numeric"},"weekday"),un=er=>{const fr=On.macroTokenToFormatOpts(er);return fr?this.formatWithSystemDefault(m,fr):er},_n=er=>_?function et(v,m){return ua(m)[v.year<0?0:1]}(m,er):V({era:er},"era");return Ct(On.parseFormat(d),er=>{switch(er){case"S":return this.num(m.millisecond);case"u":case"SSS":return this.num(m.millisecond,3);case"s":return this.num(m.second);case"ss":return this.num(m.second,2);case"uu":return this.num(Math.floor(m.millisecond/10),2);case"uuu":return this.num(Math.floor(m.millisecond/100));case"m":return this.num(m.minute);case"mm":return this.num(m.minute,2);case"h":return this.num(m.hour%12==0?12:m.hour%12);case"hh":return this.num(m.hour%12==0?12:m.hour%12,2);case"H":return this.num(m.hour);case"HH":return this.num(m.hour,2);case"Z":return J({format:"narrow",allowZ:this.opts.allowZ});case"ZZ":return J({format:"short",allowZ:this.opts.allowZ});case"ZZZ":return J({format:"techie",allowZ:this.opts.allowZ});case"ZZZZ":return m.zone.offsetName(m.ts,{format:"short",locale:this.loc.locale});case"ZZZZZ":return m.zone.offsetName(m.ts,{format:"long",locale:this.loc.locale});case"z":return m.zoneName;case"a":return _?function Ba(v){return ps[v.hour<12?0:1]}(m):V({hour:"numeric",hourCycle:"h12"},"dayperiod");case"d":return D?V({day:"numeric"},"day"):this.num(m.day);case"dd":return D?V({day:"2-digit"},"day"):this.num(m.day,2);case"c":case"E":return this.num(m.weekday);case"ccc":return yt("short",!0);case"cccc":return yt("long",!0);case"ccccc":return yt("narrow",!0);case"EEE":return yt("short",!1);case"EEEE":return yt("long",!1);case"EEEEE":return yt("narrow",!1);case"L":return D?V({month:"numeric",day:"numeric"},"month"):this.num(m.month);case"LL":return D?V({month:"2-digit",day:"numeric"},"month"):this.num(m.month,2);case"LLL":return Xe("short",!0);case"LLLL":return Xe("long",!0);case"LLLLL":return Xe("narrow",!0);case"M":return D?V({month:"numeric"},"month"):this.num(m.month);case"MM":return D?V({month:"2-digit"},"month"):this.num(m.month,2);case"MMM":return Xe("short",!1);case"MMMM":return Xe("long",!1);case"MMMMM":return Xe("narrow",!1);case"y":return D?V({year:"numeric"},"year"):this.num(m.year);case"yy":return D?V({year:"2-digit"},"year"):this.num(m.year.toString().slice(-2),2);case"yyyy":return D?V({year:"numeric"},"year"):this.num(m.year,4);case"yyyyyy":return D?V({year:"numeric"},"year"):this.num(m.year,6);case"G":return _n("short");case"GG":return _n("long");case"GGGGG":return _n("narrow");case"kk":return this.num(m.weekYear.toString().slice(-2),2);case"kkkk":return this.num(m.weekYear,4);case"W":return this.num(m.weekNumber);case"WW":return this.num(m.weekNumber,2);case"n":return this.num(m.localWeekNumber);case"nn":return this.num(m.localWeekNumber,2);case"ii":return this.num(m.localWeekYear.toString().slice(-2),2);case"iiii":return this.num(m.localWeekYear,4);case"o":return this.num(m.ordinal);case"ooo":return this.num(m.ordinal,3);case"q":return this.num(m.quarter);case"qq":return this.num(m.quarter,2);case"X":return this.num(Math.floor(m.ts/1e3));case"x":return this.num(m.ts);default:return un(er)}})}formatDurationFromString(m,d){const _=Xe=>{switch(Xe[0]){case"S":return"millisecond";case"s":return"second";case"m":return"minute";case"h":return"hour";case"d":return"day";case"w":return"week";case"M":return"month";case"y":return"year";default:return null}},V=On.parseFormat(d),J=V.reduce((Xe,{literal:yt,val:un})=>yt?Xe:Xe.concat(un),[]);return Ct(V,(Xe=>yt=>{const un=_(yt);return un?this.num(Xe.get(un),yt.length):yt})(m.shiftTo(...J.map(_).filter(Xe=>Xe))))}}const Wn=/[A-Za-z_+-]{1,256}(?::?\/[A-Za-z0-9_+-]{1,256}(?:\/[A-Za-z0-9_+-]{1,256})?)?/;function Qn(...v){const m=v.reduce((d,_)=>d+_.source,"");return RegExp(`^${m}$`)}function qr(...v){return m=>v.reduce(([d,_,D],V)=>{const[J,we,Xe]=V(m,D);return[{...d,...J},we||_,Xe]},[{},null,1]).slice(0,2)}function zi(v,...m){if(null==v)return[null,null];for(const[d,_]of m){const D=d.exec(v);if(D)return _(D)}return[null,null]}function Mr(...v){return(m,d)=>{const _={};let D;for(D=0;Dvoid 0!==er&&(fr||er&&un)?-er:er;return[{years:gr(Rs(d)),months:gr(Rs(_)),weeks:gr(Rs(D)),days:gr(Rs(V)),hours:gr(Rs(J)),minutes:gr(Rs(we)),seconds:gr(Rs(Xe),"-0"===Xe),milliseconds:gr(Xr(yt),_n)}]}const fc={GMT:0,EDT:-240,EST:-300,CDT:-300,CST:-360,MDT:-360,MST:-420,PDT:-420,PST:-480};function cl(v,m,d,_,D,V,J){const we={year:2===m.length?Ao(Go(m)):Go(m),month:ca.indexOf(d)+1,day:Go(_),hour:Go(D),minute:Go(V)};return J&&(we.second=Go(J)),v&&(we.weekday=v.length>3?Ns.indexOf(v)+1:So.indexOf(v)+1),we}const _i=/^(?:(Mon|Tue|Wed|Thu|Fri|Sat|Sun),\s)?(\d{1,2})\s(Jan|Feb|Mar|Apr|May|Jun|Jul|Aug|Sep|Oct|Nov|Dec)\s(\d{2,4})\s(\d\d):(\d\d)(?::(\d\d))?\s(?:(UT|GMT|[ECMP][SD]T)|([Zz])|(?:([+-]\d\d)(\d\d)))$/;function cs(v){const[,m,d,_,D,V,J,we,Xe,yt,un,_n]=v,gr=cl(m,D,_,d,V,J,we);let er;return er=Xe?fc[Xe]:yt?0:As(un,_n),[gr,new Ni(er)]}const Va=/^(Mon|Tue|Wed|Thu|Fri|Sat|Sun), (\d\d) (Jan|Feb|Mar|Apr|May|Jun|Jul|Aug|Sep|Oct|Nov|Dec) (\d{4}) (\d\d):(\d\d):(\d\d) GMT$/,bl=/^(Monday|Tuesday|Wednesday|Thursday|Friday|Saturday|Sunday), (\d\d)-(Jan|Feb|Mar|Apr|May|Jun|Jul|Aug|Sep|Oct|Nov|Dec)-(\d\d) (\d\d):(\d\d):(\d\d) GMT$/,Pu=/^(Mon|Tue|Wed|Thu|Fri|Sat|Sun) (Jan|Feb|Mar|Apr|May|Jun|Jul|Aug|Sep|Oct|Nov|Dec) ( \d|\d\d) (\d\d):(\d\d):(\d\d) (\d{4})$/;function wl(v){const[,m,d,_,D,V,J,we]=v;return[cl(m,D,_,d,V,J,we),Ni.utcInstance]}function ul(v){const[,m,d,_,D,V,J,we]=v;return[cl(m,we,d,_,D,V,J),Ni.utcInstance]}const yi=Qn(/([+-]\d{6}|\d{4})(?:-?(\d\d)(?:-?(\d\d))?)?/,Ro),Il=Qn(/(\d{4})-?W(\d\d)(?:-?(\d))?/,Ro),eu=Qn(/(\d{4})-?(\d{3})/,Ro),tu=Qn(Fi),dl=qr(function jt(v,m){return[{year:Ue(v,m),month:Ue(v,m+1,1),day:Ue(v,m+2,1)},null,m+3]},br,Jr,ts),$s=qr($a,br,Jr,ts),Ol=qr(da,br,Jr,ts),Sa=qr(br,Jr,ts),ru=qr(br),El=Qn(/(\d{4})-(\d\d)-(\d\d)/,Y),jl=Qn(he),hl=qr(br,Jr,ts),Hl="Invalid Duration",ha={weeks:{days:7,hours:168,minutes:10080,seconds:604800,milliseconds:6048e5},days:{hours:24,minutes:1440,seconds:86400,milliseconds:864e5},hours:{minutes:60,seconds:3600,milliseconds:36e5},minutes:{seconds:60,milliseconds:6e4},seconds:{milliseconds:1e3}},iu={years:{quarters:4,months:12,weeks:52,days:365,hours:8760,minutes:525600,seconds:31536e3,milliseconds:31536e6},quarters:{months:3,weeks:13,days:91,hours:2184,minutes:131040,seconds:7862400,milliseconds:78624e5},months:{weeks:4,days:30,hours:720,minutes:43200,seconds:2592e3,milliseconds:2592e6},...ha},Vo=365.2425,Wo=30.436875,oo={years:{quarters:4,months:12,weeks:Vo/7,days:Vo,hours:24*Vo,minutes:525949.2,seconds:525949.2*60,milliseconds:525949.2*60*1e3},quarters:{months:3,weeks:Vo/28,days:Vo/4,hours:24*Vo/4,minutes:131487.3,seconds:525949.2*60/4,milliseconds:7889237999.999999},months:{weeks:Wo/7,days:Wo,hours:24*Wo,minutes:43829.1,seconds:2629746,milliseconds:2629746e3},...ha},Fn=["years","quarters","months","weeks","days","hours","minutes","seconds","milliseconds"],Sr=Fn.slice(0).reverse();function Oi(v,m,d=!1){const _={values:d?m.values:{...v.values,...m.values||{}},loc:v.loc.clone(m.loc),conversionAccuracy:m.conversionAccuracy||v.conversionAccuracy,matrix:m.matrix||v.matrix};return new Bi(_)}function ys(v,m){let d=m.milliseconds??0;for(const _ of Sr.slice(1))m[_]&&(d+=m[_]*v[_].milliseconds);return d}function Qi(v,m){const d=ys(v,m)<0?-1:1;Fn.reduceRight((_,D)=>{if(Pr(m[D]))return _;if(_){const J=v[D][_],we=Math.floor(m[_]*d/J);m[D]+=we*d,m[_]-=we*J*d}return D},null),Fn.reduce((_,D)=>{if(Pr(m[D]))return _;if(_){const V=m[_]%1;m[_]-=V,m[D]+=V*v[_][D]}return D},null)}class Bi{constructor(m){const d="longterm"===m.conversionAccuracy||!1;let _=d?oo:iu;m.matrix&&(_=m.matrix),this.values=m.values,this.loc=m.loc||dr.create(),this.conversionAccuracy=d?"longterm":"casual",this.invalid=m.invalid||null,this.matrix=_,this.isLuxonDuration=!0}static fromMillis(m,d){return Bi.fromObject({milliseconds:m},d)}static fromObject(m,d={}){if(null==m||"object"!=typeof m)throw new Ke("Duration.fromObject: argument expected to be an object, got "+(null===m?"null":typeof m));return new Bi({values:_s(m,Bi.normalizeUnit),loc:dr.fromObject(d),conversionAccuracy:d.conversionAccuracy,matrix:d.matrix})}static fromDurationLike(m){if(Do(m))return Bi.fromMillis(m);if(Bi.isDuration(m))return m;if("object"==typeof m)return Bi.fromObject(m);throw new Ke(`Unknown duration argument ${m} of type ${typeof m}`)}static fromISO(m,d){const[_]=function ns(v){return zi(v,[yl,ja])}(m);return _?Bi.fromObject(_,d):Bi.invalid("unparsable",`the input "${m}" can't be parsed as ISO 8601`)}static fromISOTime(m,d){const[_]=function Mc(v){return zi(v,[kl,ru])}(m);return _?Bi.fromObject(_,d):Bi.invalid("unparsable",`the input "${m}" can't be parsed as ISO 8601`)}static invalid(m,d=null){if(!m)throw new Ke("need to specify a reason the Duration is invalid");const _=m instanceof gt?m:new gt(m,d);if(Ne.throwOnInvalid)throw new ze(_);return new Bi({invalid:_})}static normalizeUnit(m){const d={year:"years",years:"years",quarter:"quarters",quarters:"quarters",month:"months",months:"months",week:"weeks",weeks:"weeks",day:"days",days:"days",hour:"hours",hours:"hours",minute:"minutes",minutes:"minutes",second:"seconds",seconds:"seconds",millisecond:"milliseconds",milliseconds:"milliseconds"}[m&&m.toLowerCase()];if(!d)throw new Ft(m);return d}static isDuration(m){return m&&m.isLuxonDuration||!1}get locale(){return this.isValid?this.loc.locale:null}get numberingSystem(){return this.isValid?this.loc.numberingSystem:null}toFormat(m,d={}){const _={...d,floor:!1!==d.round&&!1!==d.floor};return this.isValid?On.create(this.loc,_).formatDurationFromString(this,m):Hl}toHuman(m={}){if(!this.isValid)return Hl;const d=Fn.map(_=>{const D=this.values[_];return Pr(D)?null:this.loc.numberFormatter({style:"unit",unitDisplay:"long",...m,unit:_.slice(0,-1)}).format(D)}).filter(_=>_);return this.loc.listFormatter({type:"conjunction",style:m.listStyle||"narrow",...m}).format(d)}toObject(){return this.isValid?{...this.values}:{}}toISO(){if(!this.isValid)return null;let m="P";return 0!==this.years&&(m+=this.years+"Y"),(0!==this.months||0!==this.quarters)&&(m+=this.months+3*this.quarters+"M"),0!==this.weeks&&(m+=this.weeks+"W"),0!==this.days&&(m+=this.days+"D"),(0!==this.hours||0!==this.minutes||0!==this.seconds||0!==this.milliseconds)&&(m+="T"),0!==this.hours&&(m+=this.hours+"H"),0!==this.minutes&&(m+=this.minutes+"M"),(0!==this.seconds||0!==this.milliseconds)&&(m+=Ds(this.seconds+this.milliseconds/1e3,3)+"S"),"P"===m&&(m+="T0S"),m}toISOTime(m={}){if(!this.isValid)return null;const d=this.toMillis();return d<0||d>=864e5?null:(m={suppressMilliseconds:!1,suppressSeconds:!1,includePrefix:!1,format:"extended",...m,includeOffset:!1},Fr.fromMillis(d,{zone:"UTC"}).toISOTime(m))}toJSON(){return this.toISO()}toString(){return this.toISO()}[Symbol.for("nodejs.util.inspect.custom")](){return this.isValid?`Duration { values: ${JSON.stringify(this.values)} }`:`Duration { Invalid, reason: ${this.invalidReason} }`}toMillis(){return this.isValid?ys(this.matrix,this.values):NaN}valueOf(){return this.toMillis()}plus(m){if(!this.isValid)return this;const d=Bi.fromDurationLike(m),_={};for(const D of Fn)(Cs(d.values,D)||Cs(this.values,D))&&(_[D]=d.get(D)+this.get(D));return Oi(this,{values:_},!0)}minus(m){if(!this.isValid)return this;const d=Bi.fromDurationLike(m);return this.plus(d.negate())}mapUnits(m){if(!this.isValid)return this;const d={};for(const _ of Object.keys(this.values))d[_]=Gs(m(this.values[_],_));return Oi(this,{values:d},!0)}get(m){return this[Bi.normalizeUnit(m)]}set(m){return this.isValid?Oi(this,{values:{...this.values,..._s(m,Bi.normalizeUnit)}}):this}reconfigure({locale:m,numberingSystem:d,conversionAccuracy:_,matrix:D}={}){return Oi(this,{loc:this.loc.clone({locale:m,numberingSystem:d}),matrix:D,conversionAccuracy:_})}as(m){return this.isValid?this.shiftTo(m).get(m):NaN}normalize(){if(!this.isValid)return this;const m=this.toObject();return Qi(this.matrix,m),Oi(this,{values:m},!0)}rescale(){return this.isValid?Oi(this,{values:function so(v){const m={};for(const[d,_]of Object.entries(v))0!==_&&(m[d]=_);return m}(this.normalize().shiftToAll().toObject())},!0):this}shiftTo(...m){if(!this.isValid)return this;if(0===m.length)return this;m=m.map(J=>Bi.normalizeUnit(J));const d={},_={},D=this.toObject();let V;for(const J of Fn)if(m.indexOf(J)>=0){V=J;let we=0;for(const yt in _)we+=this.matrix[yt][J]*_[yt],_[yt]=0;Do(D[J])&&(we+=D[J]);const Xe=Math.trunc(we);d[J]=Xe,_[J]=(1e3*we-1e3*Xe)/1e3}else Do(D[J])&&(_[J]=D[J]);for(const J in _)0!==_[J]&&(d[V]+=J===V?_[J]:_[J]/this.matrix[V][J]);return Qi(this.matrix,d),Oi(this,{values:d},!0)}shiftToAll(){return this.isValid?this.shiftTo("years","months","weeks","days","hours","minutes","seconds","milliseconds"):this}negate(){if(!this.isValid)return this;const m={};for(const d of Object.keys(this.values))m[d]=0===this.values[d]?0:-this.values[d];return Oi(this,{values:m},!0)}get years(){return this.isValid?this.values.years||0:NaN}get quarters(){return this.isValid?this.values.quarters||0:NaN}get months(){return this.isValid?this.values.months||0:NaN}get weeks(){return this.isValid?this.values.weeks||0:NaN}get days(){return this.isValid?this.values.days||0:NaN}get hours(){return this.isValid?this.values.hours||0:NaN}get minutes(){return this.isValid?this.values.minutes||0:NaN}get seconds(){return this.isValid?this.values.seconds||0:NaN}get milliseconds(){return this.isValid?this.values.milliseconds||0:NaN}get isValid(){return null===this.invalid}get invalidReason(){return this.invalid?this.invalid.reason:null}get invalidExplanation(){return this.invalid?this.invalid.explanation:null}equals(m){if(!this.isValid||!m.isValid||!this.loc.equals(m.loc))return!1;function d(_,D){return void 0===_||0===_?void 0===D||0===D:_===D}for(const _ of Fn)if(!d(this.values[_],m.values[_]))return!1;return!0}}const Ki="Invalid Interval";class co{constructor(m){this.s=m.start,this.e=m.end,this.invalid=m.invalid||null,this.isLuxonInterval=!0}static invalid(m,d=null){if(!m)throw new Ke("need to specify a reason the Interval is invalid");const _=m instanceof gt?m:new gt(m,d);if(Ne.throwOnInvalid)throw new _t(_);return new co({invalid:_})}static fromDateTimes(m,d){const _=Gl(m),D=Gl(d),V=function no(v,m){return v&&v.isValid?m&&m.isValid?mm}isBefore(m){return!!this.isValid&&this.e<=m}contains(m){return!!this.isValid&&this.s<=m&&this.e>m}set({start:m,end:d}={}){return this.isValid?co.fromDateTimes(m||this.s,d||this.e):this}splitAt(...m){if(!this.isValid)return[];const d=m.map(Gl).filter(J=>this.contains(J)).sort((J,we)=>J.toMillis()-we.toMillis()),_=[];let{s:D}=this,V=0;for(;D+this.e?this.e:J;_.push(co.fromDateTimes(D,we)),D=we,V+=1}return _}splitBy(m){const d=Bi.fromDurationLike(m);if(!this.isValid||!d.isValid||0===d.as("milliseconds"))return[];let V,{s:_}=this,D=1;const J=[];for(;_Xe*D));V=+we>+this.e?this.e:we,J.push(co.fromDateTimes(_,V)),_=V,D+=1}return J}divideEqually(m){return this.isValid?this.splitBy(this.length()/m).slice(0,m):[]}overlaps(m){return this.e>m.s&&this.s=m.e}equals(m){return!(!this.isValid||!m.isValid)&&this.s.equals(m.s)&&this.e.equals(m.e)}intersection(m){if(!this.isValid)return this;const d=this.s>m.s?this.s:m.s,_=this.e=_?null:co.fromDateTimes(d,_)}union(m){return this.isValid?co.fromDateTimes(this.sm.e?this.e:m.e):this}static merge(m){const[d,_]=m.sort((D,V)=>D.s-V.s).reduce(([D,V],J)=>V?V.overlaps(J)||V.abutsStart(J)?[D,V.union(J)]:[D.concat([V]),J]:[D,J],[[],null]);return _&&d.push(_),d}static xor(m){let d=null,_=0;const D=[],V=m.map(Xe=>[{time:Xe.s,type:"s"},{time:Xe.e,type:"e"}]),we=Array.prototype.concat(...V).sort((Xe,yt)=>Xe.time-yt.time);for(const Xe of we)_+="s"===Xe.type?1:-1,1===_?d=Xe.time:(d&&+d!=+Xe.time&&D.push(co.fromDateTimes(d,Xe.time)),d=null);return co.merge(D)}difference(...m){return co.xor([this].concat(m)).map(d=>this.intersection(d)).filter(d=>d&&!d.isEmpty())}toString(){return this.isValid?`[${this.s.toISO()} \u2013 ${this.e.toISO()})`:Ki}[Symbol.for("nodejs.util.inspect.custom")](){return this.isValid?`Interval { start: ${this.s.toISO()}, end: ${this.e.toISO()} }`:`Interval { Invalid, reason: ${this.invalidReason} }`}toLocaleString(m=Te,d={}){return this.isValid?On.create(this.s.loc.clone(d),m).formatInterval(this):Ki}toISO(m){return this.isValid?`${this.s.toISO(m)}/${this.e.toISO(m)}`:Ki}toISODate(){return this.isValid?`${this.s.toISODate()}/${this.e.toISODate()}`:Ki}toISOTime(m){return this.isValid?`${this.s.toISOTime(m)}/${this.e.toISOTime(m)}`:Ki}toFormat(m,{separator:d=" \u2013 "}={}){return this.isValid?`${this.s.toFormat(m)}${d}${this.e.toFormat(m)}`:Ki}toDuration(m,d){return this.isValid?this.e.diff(this.s,m,d):Bi.invalid(this.invalidReason)}mapEndpoints(m){return co.fromDateTimes(m(this.s),m(this.e))}}class ri{static hasDST(m=Ne.defaultZone){const d=Fr.now().setZone(m).set({month:12});return!m.isUniversal&&d.offset!==d.set({month:6}).offset}static isValidIANAZone(m){return Hr.isValidZone(m)}static normalizeZone(m){return $o(m,Ne.defaultZone)}static getStartOfWeek({locale:m=null,locObj:d=null}={}){return(d||dr.create(m)).getStartOfWeek()}static getMinimumDaysInFirstWeek({locale:m=null,locObj:d=null}={}){return(d||dr.create(m)).getMinDaysInFirstWeek()}static getWeekendWeekdays({locale:m=null,locObj:d=null}={}){return(d||dr.create(m)).getWeekendDays().slice()}static months(m="long",{locale:d=null,numberingSystem:_=null,locObj:D=null,outputCalendar:V="gregory"}={}){return(D||dr.create(d,_,V)).months(m)}static monthsFormat(m="long",{locale:d=null,numberingSystem:_=null,locObj:D=null,outputCalendar:V="gregory"}={}){return(D||dr.create(d,_,V)).months(m,!0)}static weekdays(m="long",{locale:d=null,numberingSystem:_=null,locObj:D=null}={}){return(D||dr.create(d,_,null)).weekdays(m)}static weekdaysFormat(m="long",{locale:d=null,numberingSystem:_=null,locObj:D=null}={}){return(D||dr.create(d,_,null)).weekdays(m,!0)}static meridiems({locale:m=null}={}){return dr.create(m).meridiems()}static eras(m="short",{locale:d=null}={}){return dr.create(d,null,"gregory").eras(m)}static features(){return{relative:Li(),localeWeek:bi()}}}function Xs(v,m){const d=D=>D.toUTC(0,{keepLocalTime:!0}).startOf("day").valueOf(),_=d(m)-d(v);return Math.floor(Bi.fromMillis(_).as("days"))}function Ci(v,m=d=>d){return{regex:v,deser:([d])=>m(function Jo(v){let m=parseInt(v,10);if(isNaN(m)){m="";for(let d=0;d=V&&_<=J&&(m+=_-V)}}return parseInt(m,10)}return m}(d))}}const uo="[ \xa0]",Ui=new RegExp(uo,"g");function U(v){return v.replace(/\./g,"\\.?").replace(Ui,uo)}function Ie(v){return v.replace(/\./g,"").replace(Ui," ").toLowerCase()}function ne(v,m){return null===v?null:{regex:RegExp(v.map(U).join("|")),deser:([d])=>v.findIndex(_=>Ie(d)===Ie(_))+m}}function ye(v,m){return{regex:v,deser:([,d,_])=>As(d,_),groups:m}}function Et(v){return{regex:v,deser:([m])=>m}}function Gt(v){return v.replace(/[\-\[\]{}()*+?.,\\\^$|#\s]/g,"\\$&")}const tr={year:{"2-digit":"yy",numeric:"yyyyy"},month:{numeric:"M","2-digit":"MM",short:"MMM",long:"MMMM"},day:{numeric:"d","2-digit":"dd"},weekday:{short:"EEE",long:"EEEE"},dayperiod:"a",dayPeriod:"a",hour12:{numeric:"h","2-digit":"hh"},hour24:{numeric:"H","2-digit":"HH"},minute:{numeric:"m","2-digit":"mm"},second:{numeric:"s","2-digit":"ss"},timeZoneName:{long:"ZZZZZ",short:"ZZZ"}};let li=null;function bs(v,m){return Array.prototype.concat(...v.map(d=>function wi(v,m){if(v.literal)return v;const _=Ha(On.macroTokenToFormatOpts(v.val),m);return null==_||_.includes(void 0)?v:_}(d,m)))}class Lo{constructor(m,d){if(this.locale=m,this.format=d,this.tokens=bs(On.parseFormat(d),m),this.units=this.tokens.map(_=>function Un(v,m){const d=ao(m),_=ao(m,"{2}"),D=ao(m,"{3}"),V=ao(m,"{4}"),J=ao(m,"{6}"),we=ao(m,"{1,2}"),Xe=ao(m,"{1,3}"),yt=ao(m,"{1,6}"),un=ao(m,"{1,9}"),_n=ao(m,"{2,4}"),gr=ao(m,"{4,6}"),er=Ai=>({regex:RegExp(Gt(Ai.val)),deser:([ko])=>ko,literal:!0}),ti=(Ai=>{if(v.literal)return er(Ai);switch(Ai.val){case"G":return ne(m.eras("short"),0);case"GG":return ne(m.eras("long"),0);case"y":return Ci(yt);case"yy":case"kk":return Ci(_n,Ao);case"yyyy":case"kkkk":return Ci(V);case"yyyyy":return Ci(gr);case"yyyyyy":return Ci(J);case"M":case"L":case"d":case"H":case"h":case"m":case"q":case"s":case"W":return Ci(we);case"MM":case"LL":case"dd":case"HH":case"hh":case"mm":case"qq":case"ss":case"WW":return Ci(_);case"MMM":return ne(m.months("short",!0),1);case"MMMM":return ne(m.months("long",!0),1);case"LLL":return ne(m.months("short",!1),1);case"LLLL":return ne(m.months("long",!1),1);case"o":case"S":return Ci(Xe);case"ooo":case"SSS":return Ci(D);case"u":return Et(un);case"uu":return Et(we);case"uuu":case"E":case"c":return Ci(d);case"a":return ne(m.meridiems(),0);case"EEE":return ne(m.weekdays("short",!1),1);case"EEEE":return ne(m.weekdays("long",!1),1);case"ccc":return ne(m.weekdays("short",!0),1);case"cccc":return ne(m.weekdays("long",!0),1);case"Z":case"ZZ":return ye(new RegExp(`([+-]${we.source})(?::(${_.source}))?`),2);case"ZZZ":return ye(new RegExp(`([+-]${we.source})(${_.source})?`),2);case"z":return Et(/[a-z_+-/]{1,256}?/i);case" ":return Et(/[^\S\n\r]/);default:return er(Ai)}})(v)||{invalidReason:"missing Intl.DateTimeFormat.formatToParts support"};return ti.token=v,ti}(_,m)),this.disqualifyingUnit=this.units.find(_=>_.invalidReason),!this.disqualifyingUnit){const[_,D]=function ki(v){return[`^${v.map(d=>d.regex).reduce((d,_)=>`${d}(${_.source})`,"")}$`,v]}(this.units);this.regex=RegExp(_,"i"),this.handlers=D}}explainFromTokens(m){if(this.isValid){const[d,_]=function Di(v,m,d){const _=v.match(m);if(_){const D={};let V=1;for(const J in d)if(Cs(d,J)){const we=d[J],Xe=we.groups?we.groups+1:1;!we.literal&&we.token&&(D[we.token.val[0]]=we.deser(_.slice(V,V+Xe))),V+=Xe}return[_,D]}return[_,{}]}(m,this.regex,this.handlers),[D,V,J]=_?function Rr(v){let _,d=null;return Pr(v.z)||(d=Hr.create(v.z)),Pr(v.Z)||(d||(d=new Ni(v.Z)),_=v.Z),Pr(v.q)||(v.M=3*(v.q-1)+1),Pr(v.h)||(v.h<12&&1===v.a?v.h+=12:12===v.h&&0===v.a&&(v.h=0)),0===v.G&&v.y&&(v.y=-v.y),Pr(v.u)||(v.S=Xr(v.u)),[Object.keys(v).reduce((V,J)=>{const we=(V=>{switch(V){case"S":return"millisecond";case"s":return"second";case"m":return"minute";case"h":case"H":return"hour";case"d":return"day";case"o":return"ordinal";case"L":case"M":return"month";case"y":return"year";case"E":case"c":return"weekday";case"W":return"weekNumber";case"k":return"weekYear";case"q":return"quarter";default:return null}})(J);return we&&(V[we]=v[J]),V},{}),d,_]}(_):[null,null,void 0];if(Cs(_,"a")&&Cs(_,"H"))throw new $e("Can't include meridiem when specifying 24-hour format");return{input:m,tokens:this.tokens,regex:this.regex,rawMatches:d,matches:_,result:D,zone:V,specificOffset:J}}return{input:m,tokens:this.tokens,invalidReason:this.invalidReason}}get isValid(){return!this.disqualifyingUnit}get invalidReason(){return this.disqualifyingUnit?this.disqualifyingUnit.invalidReason:null}}function fa(v,m,d){return new Lo(v,d).explainFromTokens(m)}function Ha(v,m){if(!v)return null;const _=On.create(m,v).dtFormatter(function ii(){return li||(li=Fr.fromMillis(1555555555555)),li}()),D=_.formatToParts(),V=_.resolvedOptions();return D.map(J=>function ci(v,m,d){const{type:_,value:D}=v;if("literal"===_){const Xe=/^\s+$/.test(D);return{literal:!Xe,val:Xe?" ":D}}let J=_;"hour"===_&&(J=null!=m.hour12?m.hour12?"hour12":"hour24":null!=m.hourCycle?"h11"===m.hourCycle||"h12"===m.hourCycle?"hour12":"hour24":d.hour12?"hour12":"hour24");let we=tr[J];if("object"==typeof we&&(we=we[m[_]]),we)return{literal:!1,val:we}}(J,v,V))}const Ls="Invalid DateTime",Ta=864e13;function Ma(v){return new gt("unsupported zone",`the zone "${v.name}" is not supported`)}function qa(v){return null===v.weekData&&(v.weekData=Jn(v.c)),v.weekData}function ou(v){return null===v.localWeekData&&(v.localWeekData=Jn(v.c,v.loc.getMinDaysInFirstWeek(),v.loc.getStartOfWeek())),v.localWeekData}function ka(v,m){const d={ts:v.ts,zone:v.zone,c:v.c,o:v.o,loc:v.loc,invalid:v.invalid};return new Fr({...d,...m,old:d})}function Ia(v,m,d){let _=v-60*m*1e3;const D=d.offset(_);if(m===D)return[_,m];_-=60*(D-m)*1e3;const V=d.offset(_);return D===V?[_,D]:[v-60*Math.min(D,V)*1e3,Math.max(D,V)]}function Rl(v,m){const d=new Date(v+=60*m*1e3);return{year:d.getUTCFullYear(),month:d.getUTCMonth()+1,day:d.getUTCDate(),hour:d.getUTCHours(),minute:d.getUTCMinutes(),second:d.getUTCSeconds(),millisecond:d.getUTCMilliseconds()}}function su(v,m,d){return Ia(Xo(v),m,d)}function Fu(v,m){const d=v.o,_=v.c.year+Math.trunc(m.years),D=v.c.month+Math.trunc(m.months)+3*Math.trunc(m.quarters),V={...v.c,year:_,month:D,day:Math.min(v.c.day,fs(_,D))+Math.trunc(m.days)+7*Math.trunc(m.weeks)},J=Bi.fromObject({years:m.years-Math.trunc(m.years),quarters:m.quarters-Math.trunc(m.quarters),months:m.months-Math.trunc(m.months),weeks:m.weeks-Math.trunc(m.weeks),days:m.days-Math.trunc(m.days),hours:m.hours,minutes:m.minutes,seconds:m.seconds,milliseconds:m.milliseconds}).as("milliseconds"),we=Xo(V);let[Xe,yt]=Ia(we,d,v.zone);return 0!==J&&(Xe+=J,yt=v.zone.offset(Xe)),{ts:Xe,o:yt}}function Wl(v,m,d,_,D,V){const{setZone:J,zone:we}=d;if(v&&0!==Object.keys(v).length||m){const Xe=m||we,yt=Fr.fromObject(v,{...d,zone:Xe,specificOffset:V});return J?yt:yt.setZone(we)}return Fr.invalid(new gt("unparsable",`the input "${D}" can't be parsed as ${_}`))}function pc(v,m,d=!0){return v.isValid?On.create(dr.create("en-US"),{allowZ:d,forceSimple:!0}).formatDateTimeFromString(v,m):null}function fl(v,m){const d=v.c.year>9999||v.c.year<0;let _="";return d&&v.c.year>=0&&(_+="+"),_+=mo(v.c.year,d?6:4),m?(_+="-",_+=mo(v.c.month),_+="-",_+=mo(v.c.day)):(_+=mo(v.c.month),_+=mo(v.c.day)),_}function yo(v,m,d,_,D,V){let J=mo(v.c.hour);return m?(J+=":",J+=mo(v.c.minute),(0!==v.c.millisecond||0!==v.c.second||!d)&&(J+=":")):J+=mo(v.c.minute),(0!==v.c.millisecond||0!==v.c.second||!d)&&(J+=mo(v.c.second),(0!==v.c.millisecond||!_)&&(J+=".",J+=mo(v.c.millisecond,3))),D&&(v.isOffsetFixed&&0===v.offset&&!V?J+="Z":v.o<0?(J+="-",J+=mo(Math.trunc(-v.o/60)),J+=":",J+=mo(Math.trunc(-v.o%60))):(J+="+",J+=mo(Math.trunc(v.o/60)),J+=":",J+=mo(Math.trunc(v.o%60)))),V&&(J+="["+v.zone.ianaName+"]"),J}const zo={month:1,day:1,hour:0,minute:0,second:0,millisecond:0},xl={weekNumber:1,weekday:1,hour:0,minute:0,second:0,millisecond:0},au={ordinal:1,hour:0,minute:0,second:0,millisecond:0},mc=["year","month","day","hour","minute","second","millisecond"],lu=["weekYear","weekNumber","weekday","hour","minute","second","millisecond"],Bu=["year","ordinal","hour","minute","second","millisecond"];function Uu(v){switch(v.toLowerCase()){case"localweekday":case"localweekdays":return"localWeekday";case"localweeknumber":case"localweeknumbers":return"localWeekNumber";case"localweekyear":case"localweekyears":return"localWeekYear";default:return function ah(v){const m={year:"year",years:"year",month:"month",months:"month",day:"day",days:"day",hour:"hour",hours:"hour",minute:"minute",minutes:"minute",quarter:"quarter",quarters:"quarter",second:"second",seconds:"second",millisecond:"millisecond",milliseconds:"millisecond",weekday:"weekday",weekdays:"weekday",weeknumber:"weekNumber",weeksnumber:"weekNumber",weeknumbers:"weekNumber",weekyear:"weekYear",weekyears:"weekYear",ordinal:"ordinal"}[v.toLowerCase()];if(!m)throw new Ft(v);return m}(v)}}function Ur(v,m){const d=$o(m.zone,Ne.defaultZone);if(!d.isValid)return Fr.invalid(Ma(d));const _=dr.fromObject(m);let D,V;if(Pr(v.year))D=Ne.now();else{for(const Xe of mc)Pr(v[Xe])&&(v[Xe]=zo[Xe]);const J=Or(v)||Qr(v);if(J)return Fr.invalid(J);const we=function Ef(v){return Wa[v]||(void 0===zl&&(zl=Ne.now()),Wa[v]=v.offset(zl)),Wa[v]}(d);[D,V]=su(v,we,d)}return new Fr({ts:D,zone:d,loc:_,o:V})}function kc(v,m,d){const _=!!Pr(d.round)||d.round,D=(J,we)=>(J=Ds(J,_||d.calendary?0:2,!0),m.loc.clone(d).relFormatter(d).format(J,we)),V=J=>d.calendary?m.hasSame(v,J)?0:m.startOf(J).diff(v.startOf(J),J).get(J):m.diff(v,J).get(J);if(d.unit)return D(V(d.unit),d.unit);for(const J of d.units){const we=V(J);if(Math.abs(we)>=1)return D(we,J)}return D(v>m?-0:0,d.units[d.units.length-1])}function Hs(v){let d,m={};return v.length>0&&"object"==typeof v[v.length-1]?(m=v[v.length-1],d=Array.from(v).slice(0,v.length-1)):d=Array.from(v),[m,d]}let zl,Wa={};class Fr{constructor(m){const d=m.zone||Ne.defaultZone;let _=m.invalid||(Number.isNaN(m.ts)?new gt("invalid input"):null)||(d.isValid?null:Ma(d));this.ts=Pr(m.ts)?Ne.now():m.ts;let D=null,V=null;if(!_)if(m.old&&m.old.ts===this.ts&&m.old.zone.equals(d))[D,V]=[m.old.c,m.old.o];else{const we=Do(m.o)&&!m.old?m.o:d.offset(this.ts);D=Rl(this.ts,we),_=Number.isNaN(D.year)?new gt("invalid input"):null,D=_?null:D,V=_?null:we}this._zone=d,this.loc=m.loc||dr.create(),this.invalid=_,this.weekData=null,this.localWeekData=null,this.c=D,this.o=V,this.isLuxonDateTime=!0}static now(){return new Fr({})}static local(){const[m,d]=Hs(arguments),[_,D,V,J,we,Xe,yt]=d;return Ur({year:_,month:D,day:V,hour:J,minute:we,second:Xe,millisecond:yt},m)}static utc(){const[m,d]=Hs(arguments),[_,D,V,J,we,Xe,yt]=d;return m.zone=Ni.utcInstance,Ur({year:_,month:D,day:V,hour:J,minute:we,second:Xe,millisecond:yt},m)}static fromJSDate(m,d={}){const _=function sa(v){return"[object Date]"===Object.prototype.toString.call(v)}(m)?m.valueOf():NaN;if(Number.isNaN(_))return Fr.invalid("invalid input");const D=$o(d.zone,Ne.defaultZone);return D.isValid?new Fr({ts:_,zone:D,loc:dr.fromObject(d)}):Fr.invalid(Ma(D))}static fromMillis(m,d={}){if(Do(m))return m<-Ta||m>Ta?Fr.invalid("Timestamp out of range"):new Fr({ts:m,zone:$o(d.zone,Ne.defaultZone),loc:dr.fromObject(d)});throw new Ke(`fromMillis requires a numerical input, but received a ${typeof m} with value ${m}`)}static fromSeconds(m,d={}){if(Do(m))return new Fr({ts:1e3*m,zone:$o(d.zone,Ne.defaultZone),loc:dr.fromObject(d)});throw new Ke("fromSeconds requires a numerical input")}static fromObject(m,d={}){m=m||{};const _=$o(d.zone,Ne.defaultZone);if(!_.isValid)return Fr.invalid(Ma(_));const D=dr.fromObject(d),V=_s(m,Uu),{minDaysInFirstWeek:J,startOfWeek:we}=gi(V,D),Xe=Ne.now(),yt=Pr(d.specificOffset)?_.offset(Xe):d.specificOffset,un=!Pr(V.ordinal),_n=!Pr(V.year),gr=!Pr(V.month)||!Pr(V.day),er=_n||gr,fr=V.weekYear||V.weekNumber;if((er||un)&&fr)throw new $e("Can't mix weekYear/weekNumber units with year/month/day or ordinals");if(gr&&un)throw new $e("Can't mix ordinal dates with month/day");const ti=fr||V.weekday&&!er;let Ai,ko,ho=Rl(Xe,yt);ti?(Ai=lu,ko=xl,ho=Jn(ho,J,we)):un?(Ai=Bu,ko=au,ho=wr(ho)):(Ai=mc,ko=zo);let Ea=!1;for(const Bl of Ai)Pr(V[Bl])?V[Bl]=Ea?ko[Bl]:ho[Bl]:Ea=!0;const ta=ti?function ni(v,m=4,d=1){const _=es(v.weekYear),D=hs(v.weekNumber,1,_o(v.weekYear,m,d)),V=hs(v.weekday,1,7);return _?D?!V&&hn("weekday",v.weekday):hn("week",v.weekNumber):hn("weekYear",v.weekYear)}(V,J,we):un?function Mi(v){const m=es(v.year),d=hs(v.ordinal,1,io(v.year));return m?!d&&hn("ordinal",v.ordinal):hn("year",v.year)}(V):Or(V),Ou=ta||Qr(V);if(Ou)return Fr.invalid(Ou);const vl=ti?ar(V,J,we):un?xr(V):V,[xa,Ya]=su(vl,yt,_),Sl=new Fr({ts:xa,zone:_,o:Ya,loc:D});return V.weekday&&er&&m.weekday!==Sl.weekday?Fr.invalid("mismatched weekday",`you can't specify both a weekday of ${V.weekday} and a date of ${Sl.toISO()}`):Sl.isValid?Sl:Fr.invalid(Sl.invalid)}static fromISO(m,d={}){const[_,D]=function ks(v){return zi(v,[yi,dl],[Il,$s],[eu,Ol],[tu,Sa])}(m);return Wl(_,D,d,"ISO 8601",m)}static fromRFC2822(m,d={}){const[_,D]=function js(v){return zi(function vs(v){return v.replace(/\([^()]*\)|[\n\t]/g," ").replace(/(\s\s+)/g," ").trim()}(v),[_i,cs])}(m);return Wl(_,D,d,"RFC 2822",m)}static fromHTTP(m,d={}){const[_,D]=function nu(v){return zi(v,[Va,wl],[bl,wl],[Pu,ul])}(m);return Wl(_,D,d,"HTTP",d)}static fromFormat(m,d,_={}){if(Pr(m)||Pr(d))throw new Ke("fromFormat requires an input string and a format");const{locale:D=null,numberingSystem:V=null}=_,J=dr.fromOpts({locale:D,numberingSystem:V,defaultToEN:!0}),[we,Xe,yt,un]=function Yo(v,m,d){const{result:_,zone:D,specificOffset:V,invalidReason:J}=fa(v,m,d);return[_,D,V,J]}(J,m,d);return un?Fr.invalid(un):Wl(we,Xe,_,`format ${d}`,m,yt)}static fromString(m,d,_={}){return Fr.fromFormat(m,d,_)}static fromSQL(m,d={}){const[_,D]=function Vl(v){return zi(v,[El,dl],[jl,hl])}(m);return Wl(_,D,d,"SQL",m)}static invalid(m,d=null){if(!m)throw new Ke("need to specify a reason the DateTime is invalid");const _=m instanceof gt?m:new gt(m,d);if(Ne.throwOnInvalid)throw new qe(_);return new Fr({invalid:_})}static isDateTime(m){return m&&m.isLuxonDateTime||!1}static parseFormatForOpts(m,d={}){const _=Ha(m,dr.fromObject(d));return _?_.map(D=>D?D.val:null).join(""):null}static expandFormat(m,d={}){return bs(On.parseFormat(m),dr.fromObject(d)).map(D=>D.val).join("")}static resetCache(){zl=void 0,Wa={}}get(m){return this[m]}get isValid(){return null===this.invalid}get invalidReason(){return this.invalid?this.invalid.reason:null}get invalidExplanation(){return this.invalid?this.invalid.explanation:null}get locale(){return this.isValid?this.loc.locale:null}get numberingSystem(){return this.isValid?this.loc.numberingSystem:null}get outputCalendar(){return this.isValid?this.loc.outputCalendar:null}get zone(){return this._zone}get zoneName(){return this.isValid?this.zone.name:null}get year(){return this.isValid?this.c.year:NaN}get quarter(){return this.isValid?Math.ceil(this.c.month/3):NaN}get month(){return this.isValid?this.c.month:NaN}get day(){return this.isValid?this.c.day:NaN}get hour(){return this.isValid?this.c.hour:NaN}get minute(){return this.isValid?this.c.minute:NaN}get second(){return this.isValid?this.c.second:NaN}get millisecond(){return this.isValid?this.c.millisecond:NaN}get weekYear(){return this.isValid?qa(this).weekYear:NaN}get weekNumber(){return this.isValid?qa(this).weekNumber:NaN}get weekday(){return this.isValid?qa(this).weekday:NaN}get isWeekend(){return this.isValid&&this.loc.getWeekendDays().includes(this.weekday)}get localWeekday(){return this.isValid?ou(this).weekday:NaN}get localWeekNumber(){return this.isValid?ou(this).weekNumber:NaN}get localWeekYear(){return this.isValid?ou(this).weekYear:NaN}get ordinal(){return this.isValid?wr(this.c).ordinal:NaN}get monthShort(){return this.isValid?ri.months("short",{locObj:this.loc})[this.month-1]:null}get monthLong(){return this.isValid?ri.months("long",{locObj:this.loc})[this.month-1]:null}get weekdayShort(){return this.isValid?ri.weekdays("short",{locObj:this.loc})[this.weekday-1]:null}get weekdayLong(){return this.isValid?ri.weekdays("long",{locObj:this.loc})[this.weekday-1]:null}get offset(){return this.isValid?+this.o:NaN}get offsetNameShort(){return this.isValid?this.zone.offsetName(this.ts,{format:"short",locale:this.locale}):null}get offsetNameLong(){return this.isValid?this.zone.offsetName(this.ts,{format:"long",locale:this.locale}):null}get isOffsetFixed(){return this.isValid?this.zone.isUniversal:null}get isInDST(){return!this.isOffsetFixed&&(this.offset>this.set({month:1,day:1}).offset||this.offset>this.set({month:5}).offset)}getPossibleOffsets(){if(!this.isValid||this.isOffsetFixed)return[this];const m=864e5,d=6e4,_=Xo(this.c),D=this.zone.offset(_-m),V=this.zone.offset(_+m),J=this.zone.offset(_-D*d),we=this.zone.offset(_-V*d);if(J===we)return[this];const Xe=_-J*d,yt=_-we*d,un=Rl(Xe,J),_n=Rl(yt,we);return un.hour===_n.hour&&un.minute===_n.minute&&un.second===_n.second&&un.millisecond===_n.millisecond?[ka(this,{ts:Xe}),ka(this,{ts:yt})]:[this]}get isInLeapYear(){return go(this.year)}get daysInMonth(){return fs(this.year,this.month)}get daysInYear(){return this.isValid?io(this.year):NaN}get weeksInWeekYear(){return this.isValid?_o(this.weekYear):NaN}get weeksInLocalWeekYear(){return this.isValid?_o(this.localWeekYear,this.loc.getMinDaysInFirstWeek(),this.loc.getStartOfWeek()):NaN}resolvedLocaleOptions(m={}){const{locale:d,numberingSystem:_,calendar:D}=On.create(this.loc.clone(m),m).resolvedOptions(this);return{locale:d,numberingSystem:_,outputCalendar:D}}toUTC(m=0,d={}){return this.setZone(Ni.instance(m),d)}toLocal(){return this.setZone(Ne.defaultZone)}setZone(m,{keepLocalTime:d=!1,keepCalendarTime:_=!1}={}){if((m=$o(m,Ne.defaultZone)).equals(this.zone))return this;if(m.isValid){let D=this.ts;if(d||_){const V=m.offset(this.ts),J=this.toObject();[D]=su(J,V,m)}return ka(this,{ts:D,zone:m})}return Fr.invalid(Ma(m))}reconfigure({locale:m,numberingSystem:d,outputCalendar:_}={}){return ka(this,{loc:this.loc.clone({locale:m,numberingSystem:d,outputCalendar:_})})}setLocale(m){return this.reconfigure({locale:m})}set(m){if(!this.isValid)return this;const d=_s(m,Uu),{minDaysInFirstWeek:_,startOfWeek:D}=gi(d,this.loc),V=!Pr(d.weekYear)||!Pr(d.weekNumber)||!Pr(d.weekday),J=!Pr(d.ordinal),we=!Pr(d.year),Xe=!Pr(d.month)||!Pr(d.day);if((we||Xe||J)&&(d.weekYear||d.weekNumber))throw new $e("Can't mix weekYear/weekNumber units with year/month/day or ordinals");if(Xe&&J)throw new $e("Can't mix ordinal dates with month/day");let _n;V?_n=ar({...Jn(this.c,_,D),...d},_,D):Pr(d.ordinal)?(_n={...this.toObject(),...d},Pr(d.day)&&(_n.day=Math.min(fs(_n.year,_n.month),_n.day))):_n=xr({...wr(this.c),...d});const[gr,er]=su(_n,this.o,this.zone);return ka(this,{ts:gr,o:er})}plus(m){return this.isValid?ka(this,Fu(this,Bi.fromDurationLike(m))):this}minus(m){return this.isValid?ka(this,Fu(this,Bi.fromDurationLike(m).negate())):this}startOf(m,{useLocaleWeeks:d=!1}={}){if(!this.isValid)return this;const _={},D=Bi.normalizeUnit(m);switch(D){case"years":_.month=1;case"quarters":case"months":_.day=1;case"weeks":case"days":_.hour=0;case"hours":_.minute=0;case"minutes":_.second=0;case"seconds":_.millisecond=0}if("weeks"===D)if(d){const V=this.loc.getStartOfWeek(),{weekday:J}=this;Jthis.valueOf(),yt=function Uo(v,m,d,_){let[D,V,J,we]=function Za(v,m,d){const _=[["years",(Xe,yt)=>yt.year-Xe.year],["quarters",(Xe,yt)=>yt.quarter-Xe.quarter+4*(yt.year-Xe.year)],["months",(Xe,yt)=>yt.month-Xe.month+12*(yt.year-Xe.year)],["weeks",(Xe,yt)=>{const un=Xs(Xe,yt);return(un-un%7)/7}],["days",Xs]],D={},V=v;let J,we;for(const[Xe,yt]of _)d.indexOf(Xe)>=0&&(J=Xe,D[Xe]=yt(v,m),we=V.plus(D),we>m?(D[Xe]--,(v=V.plus(D))>m&&(we=v,D[Xe]--,v=V.plus(D))):v=we);return[v,D,we,J]}(v,m,d);const Xe=m-D,yt=d.filter(_n=>["hours","minutes","seconds","milliseconds"].indexOf(_n)>=0);0===yt.length&&(J0?Bi.fromMillis(Xe,_).shiftTo(...yt).plus(un):un}(J?this:m,J?m:this,V,D);return J?yt.negate():yt}diffNow(m="milliseconds",d={}){return this.diff(Fr.now(),m,d)}until(m){return this.isValid?co.fromDateTimes(this,m):this}hasSame(m,d,_){if(!this.isValid)return!1;const D=m.valueOf(),V=this.setZone(m.zone,{keepLocalTime:!0});return V.startOf(d,_)<=D&&D<=V.endOf(d,_)}equals(m){return this.isValid&&m.isValid&&this.valueOf()===m.valueOf()&&this.zone.equals(m.zone)&&this.loc.equals(m.loc)}toRelative(m={}){if(!this.isValid)return null;const d=m.base||Fr.fromObject({},{zone:this.zone}),_=m.padding?thisd.valueOf(),Math.min)}static max(...m){if(!m.every(Fr.isDateTime))throw new Ke("max requires all arguments be DateTimes");return Ks(m,d=>d.valueOf(),Math.max)}static fromFormatExplain(m,d,_={}){const{locale:D=null,numberingSystem:V=null}=_;return fa(dr.fromOpts({locale:D,numberingSystem:V,defaultToEN:!0}),m,d)}static fromStringExplain(m,d,_={}){return Fr.fromFormatExplain(m,d,_)}static buildFormatParser(m,d={}){const{locale:_=null,numberingSystem:D=null}=d,V=dr.fromOpts({locale:_,numberingSystem:D,defaultToEN:!0});return new Lo(V,m)}static fromFormatParser(m,d,_={}){if(Pr(m)||Pr(d))throw new Ke("fromFormatParser requires an input string and a format parser");const{locale:D=null,numberingSystem:V=null}=_,J=dr.fromOpts({locale:D,numberingSystem:V,defaultToEN:!0});if(!J.equals(d.locale))throw new Ke(`fromFormatParser called with a locale of ${J}, but the format parser was created for ${d.locale}`);const{result:we,zone:Xe,specificOffset:yt,invalidReason:un}=d.explainFromTokens(m);return un?Fr.invalid(un):Wl(we,Xe,_,`format ${d.format}`,m,yt)}static get DATE_SHORT(){return Te}static get DATE_MED(){return Ee}static get DATE_MED_WITH_WEEKDAY(){return st}static get DATE_FULL(){return Xt}static get DATE_HUGE(){return Mt}static get TIME_SIMPLE(){return Kt}static get TIME_WITH_SECONDS(){return rt}static get TIME_WITH_SHORT_OFFSET(){return Vt}static get TIME_WITH_LONG_OFFSET(){return en}static get TIME_24_SIMPLE(){return kn}static get TIME_24_WITH_SECONDS(){return Kn}static get TIME_24_WITH_SHORT_OFFSET(){return Nr}static get TIME_24_WITH_LONG_OFFSET(){return Rn}static get DATETIME_SHORT(){return pr}static get DATETIME_SHORT_WITH_SECONDS(){return cn}static get DATETIME_MED(){return Fe}static get DATETIME_MED_WITH_SECONDS(){return ke}static get DATETIME_MED_WITH_WEEKDAY(){return Je}static get DATETIME_FULL(){return z}static get DATETIME_FULL_WITH_SECONDS(){return N}static get DATETIME_HUGE(){return W}static get DATETIME_HUGE_WITH_SECONDS(){return Le}}function Gl(v){if(Fr.isDateTime(v))return v;if(v&&v.valueOf&&Do(v.valueOf()))return Fr.fromJSDate(v);if(v&&"object"==typeof v)return Fr.fromObject(v);throw new Ke(`Unknown datetime argument: ${v}, of type ${typeof v}`)}const pl=new c.nKC("MAT_LUXON_DATE_ADAPTER_OPTIONS",{providedIn:"root",factory:function gd(){return{useUtc:!1,firstDayOfWeek:0,defaultOutputCalendar:"gregory"}}});let Yl=(()=>{class v extends rn.MJ{_useUTC;_firstDayOfWeek;_defaultOutputCalendar;constructor(){super();const d=(0,c.WQX)(rn.Ju,{optional:!0}),_=(0,c.WQX)(pl,{optional:!0});this._useUTC=!!_?.useUtc,this._firstDayOfWeek=_?.firstDayOfWeek||0,this._defaultOutputCalendar=_?.defaultOutputCalendar||"gregory",this.setLocale(d||Fr.local().locale)}getYear(d){return d.year}getMonth(d){return d.month-1}getDate(d){return d.day}getDayOfWeek(d){return d.weekday}getMonthNames(d){return ri.months(d,{locale:this.locale,outputCalendar:this._defaultOutputCalendar})}getDateNames(){const d=new Intl.DateTimeFormat(this.locale,{day:"numeric",timeZone:"utc"});return function cu(v,m){const d=Array(v);for(let _=0;_d.format(Fr.utc(2017,1,_+1).toJSDate()))}getDayOfWeekNames(d){const _=ri.weekdays(d,{locale:this.locale});return _.unshift(_.pop()),_}getYearName(d){return d.toFormat("yyyy",this._getOptions())}getFirstDayOfWeek(){return this._firstDayOfWeek}getNumDaysInMonth(d){return d.daysInMonth}clone(d){return Fr.fromObject(d.toObject(),this._getOptions())}createDate(d,_,D){const V=this._getOptions();if(_<0||_>11)throw Error(`Invalid month index "${_}". Month index has to be between 0 and 11.`);if(D<1)throw Error(`Invalid date "${D}". Date has to be greater than 0.`);const J=this._useUTC?Fr.utc(d,_+1,D,V):Fr.local(d,_+1,D,V);if(!this.isValid(J))throw Error(`Invalid date "${D}". Reason: "${J.invalidReason}".`);return J}today(){const d=this._getOptions();return this._useUTC?Fr.utc(d):Fr.local(d)}parse(d,_){const D=this._getOptions();if("string"==typeof d&&d.length>0){const V=Fr.fromISO(d,D);if(this.isValid(V))return V;const J=Array.isArray(_)?_:[_];if(!_.length)throw Error("Formats array must not be empty.");for(const we of J){const Xe=Fr.fromFormat(d,we,D);if(this.isValid(Xe))return Xe}return this.invalid()}return"number"==typeof d?Fr.fromMillis(d,D):d instanceof Date?Fr.fromJSDate(d,D):d instanceof Fr?Fr.fromMillis(d.toMillis(),D):null}format(d,_){if(!this.isValid(d))throw Error("LuxonDateAdapter: Cannot format invalid date.");return this._useUTC?d.setLocale(this.locale).setZone("utc").toFormat(_):d.setLocale(this.locale).toFormat(_)}addCalendarYears(d,_){return d.reconfigure(this._getOptions()).plus({years:_})}addCalendarMonths(d,_){return d.reconfigure(this._getOptions()).plus({months:_})}addCalendarDays(d,_){return d.reconfigure(this._getOptions()).plus({days:_})}toIso8601(d){return d.toISO()}deserialize(d){const _=this._getOptions();let D;if(d instanceof Date&&(D=Fr.fromJSDate(d,_)),"string"==typeof d){if(!d)return null;D=Fr.fromISO(d,_)}return D&&this.isValid(D)?D:super.deserialize(d)}isDateInstance(d){return d instanceof Fr}isValid(d){return d.isValid}invalid(){return Fr.invalid("Invalid Luxon DateTime object.")}setTime(d,_,D,V){return this.clone(d).set({hour:_,minute:D,second:V,millisecond:0})}getHours(d){return d.hour}getMinutes(d){return d.minute}getSeconds(d){return d.second}parseTime(d,_){const D=this.parse(d,_);return(!D||!this.isValid(D))&&"string"==typeof d&&this.parse(d.replace(/[^0-9:(AM|PM)]/gi,""),_)||D}addSeconds(d,_){return d.reconfigure(this._getOptions()).plus({seconds:_})}_getOptions(){return{zone:this._useUTC?"utc":void 0,locale:this.locale,outputCalendar:this._defaultOutputCalendar}}static \u0275fac=function(_){return new(_||v)};static \u0275prov=c.jDH({token:v,factory:v.\u0275fac})}return v})();var Dr=r(1204);function rs(v){return new c.wOt(3e3,!1)}function Si(v){switch(v.length){case 0:return new Dr.sf;case 1:return v[0];default:return new Dr.ui(v)}}function Nl(v,m,d=new Map,_=new Map){const D=[],V=[];let J=-1,we=null;if(m.forEach(Xe=>{const yt=Xe.get("offset"),un=yt==J,_n=un&&we||new Map;Xe.forEach((gr,er)=>{let fr=er,ti=gr;if("offset"!==er)switch(fr=v.normalizePropertyName(fr,D),ti){case Dr.FX:ti=d.get(er);break;case Dr.kp:ti=_.get(er);break;default:ti=v.normalizeStyleValue(er,fr,ti,D)}_n.set(fr,ti)}),un||V.push(_n),we=_n,J=yt}),D.length)throw function uh(){return new c.wOt(3502,!1)}();return V}function Ra(v,m,d,_){switch(m){case"start":v.onStart(()=>_(d&&Qs(d,"start",v)));break;case"done":v.onDone(()=>_(d&&Qs(d,"done",v)));break;case"destroy":v.onDestroy(()=>_(d&&Qs(d,"destroy",v)))}}function Qs(v,m,d){const V=Oc(v.element,v.triggerName,v.fromState,v.toState,m||v.phaseName,d.totalTime??v.totalTime,!!d.disabled),J=v._data;return null!=J&&(V._data=J),V}function Oc(v,m,d,_,D="",V=0,J){return{element:v,triggerName:m,fromState:d,toState:_,phaseName:D,totalTime:V,disabled:!!J}}function pa(v,m,d){let _=v.get(m);return _||v.set(m,_=d),_}function vd(v){const m=v.indexOf(":");return[v.substring(1,m),v.slice(m+1)]}const em=typeof document>"u"?null:document.documentElement;function fh(v){const m=v.parentNode||v.host||null;return m===em?null:m}let ma=null,ql=!1;function I(v,m){for(;m;){if(m===v)return!0;m=fh(m)}return!1}function P(v,m,d){if(d)return Array.from(v.querySelectorAll(m));const _=v.querySelector(m);return _?[_]:[]}let oe=(()=>{class v{validateStyleProperty(d){return function Zs(v){ma||(ma=function yd(){return typeof document<"u"?document.body:null}()||{},ql=!!ma.style&&"WebkitAppearance"in ma.style);let m=!0;return ma.style&&!function ph(v){return"ebkit"==v.substring(1,6)}(v)&&(m=v in ma.style,!m&&ql&&(m="Webkit"+v.charAt(0).toUpperCase()+v.slice(1)in ma.style)),m}(d)}containsElement(d,_){return I(d,_)}getParentElement(d){return fh(d)}query(d,_,D){return P(d,_,D)}computeStyle(d,_,D){return D||""}animate(d,_,D,V,J,we=[],Xe){return new Dr.sf(D,V)}static \u0275fac=function(_){return new(_||v)};static \u0275prov=c.jDH({token:v,factory:v.\u0275fac})}return v})();class Ae{static NOOP=new oe}class je{}const It=1e3,An="ng-enter",Qt="ng-leave",Gn="ng-trigger",zn=".ng-trigger",nr="ng-animating",Mn=".ng-animating";function Hn(v){if("number"==typeof v)return v;const m=v.match(/^(-?[\.\d]+)(m?s)/);return!m||m.length<2?0:Xn(parseFloat(m[1]),m[2])}function Xn(v,m){return"s"===m?v*It:v}function vr(v,m,d){return v.hasOwnProperty("duration")?v:function $n(v,m,d){let D,V=0,J="";if("string"==typeof v){const we=v.match(/^(-?[\.\d]+)(m?s)(?:\s+(-?[\.\d]+)(m?s))?(?:\s+([-a-z]+(?:\(.+?\))?))?$/i);if(null===we)return m.push(rs()),{duration:0,delay:0,easing:""};D=Xn(parseFloat(we[1]),we[2]);const Xe=we[3];null!=Xe&&(V=Xn(parseFloat(Xe),we[4]));const yt=we[5];yt&&(J=yt)}else D=v;if(!d){let we=!1,Xe=m.length;D<0&&(m.push(function R(){return new c.wOt(3100,!1)}()),we=!0),V<0&&(m.push(function G(){return new c.wOt(3101,!1)}()),we=!0),we&&m.splice(Xe,0,rs())}return{duration:D,delay:V,easing:J}}(v,m,d)}function Cr(v,m,d){m.forEach((_,D)=>{const V=ga(D);d&&!d.has(D)&&d.set(D,v.style[V]),v.style[V]=_})}function Gr(v,m){m.forEach((d,_)=>{const D=ga(_);v.style[D]=""})}function Br(v){return Array.isArray(v)?1==v.length?v[0]:(0,Dr.K2)(v):v}const Ji=new RegExp("{{\\s*(.+?)\\s*}}","g");function Xi(v){let m=[];if("string"==typeof v){let d;for(;d=Ji.exec(v);)m.push(d[1]);Ji.lastIndex=0}return m}function bo(v,m,d){const _=`${v}`,D=_.replace(Ji,(V,J)=>{let we=m[J];return null==we&&(d.push(function K(){return new c.wOt(3003,!1)}()),we=""),we.toString()});return D==_?v:D}const To=/-+([a-z0-9])/g;function ga(v){return v.replace(To,(...m)=>m[1].toUpperCase())}function Yi(v,m,d){switch(m.type){case Dr.If.Trigger:return v.visitTrigger(m,d);case Dr.If.State:return v.visitState(m,d);case Dr.If.Transition:return v.visitTransition(m,d);case Dr.If.Sequence:return v.visitSequence(m,d);case Dr.If.Group:return v.visitGroup(m,d);case Dr.If.Animate:return v.visitAnimate(m,d);case Dr.If.Keyframes:return v.visitKeyframes(m,d);case Dr.If.Style:return v.visitStyle(m,d);case Dr.If.Reference:return v.visitReference(m,d);case Dr.If.AnimateChild:return v.visitAnimateChild(m,d);case Dr.If.AnimateRef:return v.visitAnimateRef(m,d);case Dr.If.Query:return v.visitQuery(m,d);case Dr.If.Stagger:return v.visitStagger(m,d);default:throw function _e(){return new c.wOt(3004,!1)}()}}function Mo(v,m){return window.getComputedStyle(v)[m]}const gs=new Set(["width","height","minWidth","minHeight","maxWidth","maxHeight","left","top","bottom","right","fontSize","outlineWidth","outlineOffset","paddingTop","paddingLeft","paddingBottom","paddingRight","marginTop","marginLeft","marginBottom","marginRight","borderRadius","borderWidth","borderTopWidth","borderLeftWidth","borderRightWidth","borderBottomWidth","textIndent","perspective"]);class qs extends je{normalizePropertyName(m,d){return ga(m)}normalizeStyleValue(m,d,_,D){let V="";const J=_.toString().trim();if(gs.has(d)&&0!==_&&"0"!==_)if("number"==typeof _)V="px";else{const we=_.match(/^[+-]?[\d\.]+([a-z]*)$/);we&&0==we[1].length&&D.push(function We(){return new c.wOt(3005,!1)}())}return J+V}}const yc="*";const Js=new Set(["true","1"]),ml=new Set(["false","0"]);function bc(v,m){const d=Js.has(v)||ml.has(v),_=Js.has(m)||ml.has(m);return(D,V)=>{let J=v==yc||v==D,we=m==yc||m==V;return!J&&d&&"boolean"==typeof D&&(J=D?Js.has(v):ml.has(v)),!we&&_&&"boolean"==typeof V&&(we=V?Js.has(m):ml.has(m)),J&&we}}const ju=new RegExp("s*:selfs*,?","g");function Vu(v,m,d,_){return new gh(v).build(m,d,_)}class gh{_driver;constructor(m){this._driver=m}build(m,d,_){const D=new Wu(d);return this._resetContextStyleTimingState(D),Yi(this,Br(m),D)}_resetContextStyleTimingState(m){m.currentQuerySelector="",m.collectedStyles=new Map,m.collectedStyles.set("",new Map),m.currentTime=0}visitTrigger(m,d){let _=d.queryCount=0,D=d.depCount=0;const V=[],J=[];return"@"==m.name.charAt(0)&&d.errors.push(function At(){return new c.wOt(3006,!1)}()),m.definitions.forEach(we=>{if(this._resetContextStyleTimingState(d),we.type==Dr.If.State){const Xe=we,yt=Xe.name;yt.toString().split(/\s*,\s*/).forEach(un=>{Xe.name=un,V.push(this.visitState(Xe,d))}),Xe.name=yt}else if(we.type==Dr.If.Transition){const Xe=this.visitTransition(we,d);_+=Xe.queryCount,D+=Xe.depCount,J.push(Xe)}else d.errors.push(function fn(){return new c.wOt(3007,!1)}())}),{type:Dr.If.Trigger,name:m.name,states:V,transitions:J,queryCount:_,depCount:D,options:null}}visitState(m,d){const _=this.visitStyle(m.styles,d),D=m.options&&m.options.params||null;if(_.containsDynamicStyles){const V=new Set,J=D||{};_.styles.forEach(we=>{we instanceof Map&&we.forEach(Xe=>{Xi(Xe).forEach(yt=>{J.hasOwnProperty(yt)||V.add(yt)})})}),V.size&&d.errors.push(function on(){return new c.wOt(3008,!1)}(0,V.values()))}return{type:Dr.If.State,name:m.name,style:_,options:D?{params:D}:null}}visitTransition(m,d){d.queryCount=0,d.depCount=0;const _=Yi(this,Br(m.animation),d),D=function tc(v,m){const d=[];return"string"==typeof v?v.split(/\s*,\s*/).forEach(_=>function Rc(v,m,d){if(":"==v[0]){const Xe=function mh(v,m){switch(v){case":enter":return"void => *";case":leave":return"* => void";case":increment":return(d,_)=>parseFloat(_)>parseFloat(d);case":decrement":return(d,_)=>parseFloat(_) *"}}(v,d);if("function"==typeof Xe)return void m.push(Xe);v=Xe}const _=v.match(/^(\*|[-\w]+)\s*()\s*(\*|[-\w]+)$/);if(null==_||_.length<4)return d.push(function Ys(){return new c.wOt(3015,!1)}()),m;const D=_[1],V=_[2],J=_[3];m.push(bc(D,J)),"<"==V[0]&&(D!=yc||J!=yc)&&m.push(bc(J,D))}(_,d,m)):d.push(v),d}(m.expr,d.errors);return{type:Dr.If.Transition,matchers:D,animation:_,queryCount:d.queryCount,depCount:d.depCount,options:Ll(m.options)}}visitSequence(m,d){return{type:Dr.If.Sequence,steps:m.steps.map(_=>Yi(this,_,d)),options:Ll(m.options)}}visitGroup(m,d){const _=d.currentTime;let D=0;const V=m.steps.map(J=>{d.currentTime=_;const we=Yi(this,J,d);return D=Math.max(D,d.currentTime),we});return d.currentTime=D,{type:Dr.If.Group,steps:V,options:Ll(m.options)}}visitAnimate(m,d){const _=function _h(v,m){if(v.hasOwnProperty("duration"))return v;if("number"==typeof v)return xf(vr(v,m).duration,0,"");const d=v;if(d.split(/\s+/).some(V=>"{"==V.charAt(0)&&"{"==V.charAt(1))){const V=xf(0,0,"");return V.dynamic=!0,V.strValue=d,V}const D=vr(d,m);return xf(D.duration,D.delay,D.easing)}(m.timings,d.errors);d.currentAnimateTimings=_;let D,V=m.styles?m.styles:(0,Dr.iF)({});if(V.type==Dr.If.Keyframes)D=this.visitKeyframes(V,d);else{let J=m.styles,we=!1;if(!J){we=!0;const yt={};_.easing&&(yt.easing=_.easing),J=(0,Dr.iF)(yt)}d.currentTime+=_.duration+_.delay;const Xe=this.visitStyle(J,d);Xe.isEmptyStep=we,D=Xe}return d.currentAnimateTimings=null,{type:Dr.If.Animate,timings:_,style:D,options:null}}visitStyle(m,d){const _=this._makeStyleAst(m,d);return this._validateStyleAst(_,d),_}_makeStyleAst(m,d){const _=[],D=Array.isArray(m.styles)?m.styles:[m.styles];for(let we of D)"string"==typeof we?we===Dr.kp?_.push(we):d.errors.push(new c.wOt(3002,!1)):_.push(new Map(Object.entries(we)));let V=!1,J=null;return _.forEach(we=>{if(we instanceof Map&&(we.has("easing")&&(J=we.get("easing"),we.delete("easing")),!V))for(let Xe of we.values())if(Xe.toString().indexOf("{{")>=0){V=!0;break}}),{type:Dr.If.Style,styles:_,easing:J,offset:m.offset,containsDynamicStyles:V,options:null}}_validateStyleAst(m,d){const _=d.currentAnimateTimings;let D=d.currentTime,V=d.currentTime;_&&V>0&&(V-=_.duration+_.delay),m.styles.forEach(J=>{"string"!=typeof J&&J.forEach((we,Xe)=>{const yt=d.collectedStyles.get(d.currentQuerySelector),un=yt.get(Xe);let _n=!0;un&&(V!=D&&V>=un.startTime&&D<=un.endTime&&(d.errors.push(function kr(){return new c.wOt(3010,!1)}()),_n=!1),V=un.startTime),_n&&yt.set(Xe,{startTime:V,endTime:D}),d.options&&function ro(v,m,d){const _=m.params||{},D=Xi(v);D.length&&D.forEach(V=>{_.hasOwnProperty(V)||d.push(function F(){return new c.wOt(3001,!1)}())})}(we,d.options,d.errors)})})}visitKeyframes(m,d){const _={type:Dr.If.Keyframes,styles:[],options:null};if(!d.currentAnimateTimings)return d.errors.push(function Gi(){return new c.wOt(3011,!1)}()),_;let V=0;const J=[];let we=!1,Xe=!1,yt=0;const un=m.steps.map(ko=>{const ho=this._makeStyleAst(ko,d);let Ea=null!=ho.offset?ho.offset:function nm(v){if("string"==typeof v)return null;let m=null;if(Array.isArray(v))v.forEach(d=>{if(d instanceof Map&&d.has("offset")){const _=d;m=parseFloat(_.get("offset")),_.delete("offset")}});else if(v instanceof Map&&v.has("offset")){const d=v;m=parseFloat(d.get("offset")),d.delete("offset")}return m}(ho.styles),ta=0;return null!=Ea&&(V++,ta=ho.offset=Ea),Xe=Xe||ta<0||ta>1,we=we||ta0&&V<_n?d.errors.push(function Oa(){return new c.wOt(3202,!1)}()):0==V&&(gr=1/(_n-1));const er=_n-1,fr=d.currentTime,ti=d.currentAnimateTimings,Ai=ti.duration;return un.forEach((ko,ho)=>{const Ea=gr>0?ho==er?1:gr*ho:J[ho],ta=Ea*Ai;d.currentTime=fr+ti.delay+ta,ti.duration=ta,this._validateStyleAst(ko,d),ko.offset=Ea,_.styles.push(ko)}),_}visitReference(m,d){return{type:Dr.If.Reference,animation:Yi(this,Br(m.animation),d),options:Ll(m.options)}}visitAnimateChild(m,d){return d.depCount++,{type:Dr.If.AnimateChild,options:Ll(m.options)}}visitAnimateRef(m,d){return{type:Dr.If.AnimateRef,animation:this.visitReference(m.animation,d),options:Ll(m.options)}}visitQuery(m,d){const _=d.currentQuerySelector,D=m.options||{};d.queryCount++,d.currentQuery=m;const[V,J]=function Hu(v){const m=!!v.split(/\s*,\s*/).find(d=>":self"==d);return m&&(v=v.replace(ju,"")),v=v.replace(/@\*/g,zn).replace(/@\w+/g,d=>zn+"-"+d.slice(1)).replace(/:animating/g,Mn),[v,m]}(m.selector);d.currentQuerySelector=_.length?_+" "+V:V,pa(d.collectedStyles,d.currentQuerySelector,new Map);const we=Yi(this,Br(m.animation),d);return d.currentQuery=null,d.currentQuerySelector=_,{type:Dr.If.Query,selector:V,limit:D.limit||0,optional:!!D.optional,includeSelf:J,animation:we,originalSelector:m.selector,options:Ll(m.options)}}visitStagger(m,d){d.currentQuery||d.errors.push(function us(){return new c.wOt(3013,!1)}());const _="full"===m.timings?{duration:0,delay:0,easing:"full"}:vr(m.timings,d.errors,!0);return{type:Dr.If.Stagger,animation:Yi(this,Br(m.animation),d),timings:_,options:null}}}class Wu{errors;queryCount=0;depCount=0;currentTransition=null;currentQuery=null;currentQuerySelector=null;currentAnimateTimings=null;currentTime=0;collectedStyles=new Map;options=null;unsupportedCSSPropertiesFound=new Set;constructor(m){this.errors=m}}function Ll(v){return v?(v={...v}).params&&(v.params=function tm(v){return v?{...v}:null}(v.params)):v={},v}function xf(v,m,d){return{duration:v,delay:m,easing:d}}function bd(v,m,d,_,D,V,J=null,we=!1){return{type:1,element:v,keyframes:m,preStyleProps:d,postStyleProps:_,duration:D,delay:V,totalTime:D+V,easing:J,subTimeline:we}}class zu{_map=new Map;get(m){return this._map.get(m)||[]}append(m,d){let _=this._map.get(m);_||this._map.set(m,_=[]),_.push(...d)}has(m){return this._map.has(m)}clear(){this._map.clear()}}const im=new RegExp(":enter","g"),Cf=new RegExp(":leave","g");function wd(v,m,d,_,D,V=new Map,J=new Map,we,Xe,yt=[]){return(new Nc).buildKeyframes(v,m,d,_,D,V,J,we,Xe,yt)}class Nc{buildKeyframes(m,d,_,D,V,J,we,Xe,yt,un=[]){yt=yt||new zu;const _n=new Ed(m,d,yt,D,V,un,[]);_n.options=Xe;const gr=Xe.delay?Hn(Xe.delay):0;_n.currentTimeline.delayNextStep(gr),_n.currentTimeline.setStyles([J],null,_n.errors,Xe),Yi(this,_,_n);const er=_n.timelines.filter(fr=>fr.containsAnimation());if(er.length&&we.size){let fr;for(let ti=er.length-1;ti>=0;ti--){const Ai=er[ti];if(Ai.element===d){fr=Ai;break}}fr&&!fr.allowOnlyTimelineStyles()&&fr.setStyles([we],null,_n.errors,Xe)}return er.length?er.map(fr=>fr.buildKeyframes()):[bd(d,[],[],[],0,gr,"",!1)]}visitTrigger(m,d){}visitState(m,d){}visitTransition(m,d){}visitAnimateChild(m,d){const _=d.subInstructions.get(d.element);if(_){const D=d.createSubContext(m.options),V=d.currentTimeline.currentTime,J=this._visitSubInstructions(_,D,D.options);V!=J&&d.transformIntoNewTimeline(J)}d.previousNode=m}visitAnimateRef(m,d){const _=d.createSubContext(m.options);_.transformIntoNewTimeline(),this._applyAnimationRefDelays([m.options,m.animation.options],d,_),this.visitReference(m.animation,_),d.transformIntoNewTimeline(_.currentTimeline.currentTime),d.previousNode=m}_applyAnimationRefDelays(m,d,_){for(const D of m){const V=D?.delay;if(V){const J="number"==typeof V?V:Hn(bo(V,D?.params??{},d.errors));_.delayNextStep(J)}}}_visitSubInstructions(m,d,_){let V=d.currentTimeline.currentTime;const J=null!=_.duration?Hn(_.duration):null,we=null!=_.delay?Hn(_.delay):null;return 0!==J&&m.forEach(Xe=>{const yt=d.appendInstructionToTimeline(Xe,J,we);V=Math.max(V,yt.duration+yt.delay)}),V}visitReference(m,d){d.updateOptions(m.options,!0),Yi(this,m.animation,d),d.previousNode=m}visitSequence(m,d){const _=d.subContextCount;let D=d;const V=m.options;if(V&&(V.params||V.delay)&&(D=d.createSubContext(V),D.transformIntoNewTimeline(),null!=V.delay)){D.previousNode.type==Dr.If.Style&&(D.currentTimeline.snapshotCurrentStyles(),D.previousNode=Lc);const J=Hn(V.delay);D.delayNextStep(J)}m.steps.length&&(m.steps.forEach(J=>Yi(this,J,D)),D.currentTimeline.applyStylesToKeyframe(),D.subContextCount>_&&D.transformIntoNewTimeline()),d.previousNode=m}visitGroup(m,d){const _=[];let D=d.currentTimeline.currentTime;const V=m.options&&m.options.delay?Hn(m.options.delay):0;m.steps.forEach(J=>{const we=d.createSubContext(m.options);V&&we.delayNextStep(V),Yi(this,J,we),D=Math.max(D,we.currentTimeline.currentTime),_.push(we.currentTimeline)}),_.forEach(J=>d.currentTimeline.mergeTimelineCollectedStyles(J)),d.transformIntoNewTimeline(D),d.previousNode=m}_visitTiming(m,d){if(m.dynamic){const _=m.strValue;return vr(d.params?bo(_,d.params,d.errors):_,d.errors)}return{duration:m.duration,delay:m.delay,easing:m.easing}}visitAnimate(m,d){const _=d.currentAnimateTimings=this._visitTiming(m.timings,d),D=d.currentTimeline;_.delay&&(d.incrementTime(_.delay),D.snapshotCurrentStyles());const V=m.style;V.type==Dr.If.Keyframes?this.visitKeyframes(V,d):(d.incrementTime(_.duration),this.visitStyle(V,d),D.applyStylesToKeyframe()),d.currentAnimateTimings=null,d.previousNode=m}visitStyle(m,d){const _=d.currentTimeline,D=d.currentAnimateTimings;!D&&_.hasCurrentStyleProperties()&&_.forwardFrame();const V=D&&D.easing||m.easing;m.isEmptyStep?_.applyEmptyStep(V):_.setStyles(m.styles,V,d.errors,d.options),d.previousNode=m}visitKeyframes(m,d){const _=d.currentAnimateTimings,D=d.currentTimeline.duration,V=_.duration,we=d.createSubContext().currentTimeline;we.easing=_.easing,m.styles.forEach(Xe=>{we.forwardTime((Xe.offset||0)*V),we.setStyles(Xe.styles,Xe.easing,d.errors,d.options),we.applyStylesToKeyframe()}),d.currentTimeline.mergeTimelineCollectedStyles(we),d.transformIntoNewTimeline(D+V),d.previousNode=m}visitQuery(m,d){const _=d.currentTimeline.currentTime,D=m.options||{},V=D.delay?Hn(D.delay):0;V&&(d.previousNode.type===Dr.If.Style||0==_&&d.currentTimeline.hasCurrentStyleProperties())&&(d.currentTimeline.snapshotCurrentStyles(),d.previousNode=Lc);let J=_;const we=d.invokeQuery(m.selector,m.originalSelector,m.limit,m.includeSelf,!!D.optional,d.errors);d.currentQueryTotal=we.length;let Xe=null;we.forEach((yt,un)=>{d.currentQueryIndex=un;const _n=d.createSubContext(m.options,yt);V&&_n.delayNextStep(V),yt===d.element&&(Xe=_n.currentTimeline),Yi(this,m.animation,_n),_n.currentTimeline.applyStylesToKeyframe(),J=Math.max(J,_n.currentTimeline.currentTime)}),d.currentQueryIndex=0,d.currentQueryTotal=0,d.transformIntoNewTimeline(J),Xe&&(d.currentTimeline.mergeTimelineCollectedStyles(Xe),d.currentTimeline.snapshotCurrentStyles()),d.previousNode=m}visitStagger(m,d){const _=d.parentContext,D=d.currentTimeline,V=m.timings,J=Math.abs(V.duration),we=J*(d.currentQueryTotal-1);let Xe=J*d.currentQueryIndex;switch(V.duration<0?"reverse":V.easing){case"reverse":Xe=we-Xe;break;case"full":Xe=_.currentStaggerTime}const un=d.currentTimeline;Xe&&un.delayNextStep(Xe);const _n=un.currentTime;Yi(this,m.animation,d),d.previousNode=m,_.currentStaggerTime=D.currentTime-_n+(D.startTime-_.currentTimeline.startTime)}}const Lc={};class Ed{_driver;element;subInstructions;_enterClassName;_leaveClassName;errors;timelines;parentContext=null;currentTimeline;currentAnimateTimings=null;previousNode=Lc;subContextCount=0;options={};currentQueryIndex=0;currentQueryTotal=0;currentStaggerTime=0;constructor(m,d,_,D,V,J,we,Xe){this._driver=m,this.element=d,this.subInstructions=_,this._enterClassName=D,this._leaveClassName=V,this.errors=J,this.timelines=we,this.currentTimeline=Xe||new Ku(this._driver,d,0),we.push(this.currentTimeline)}get params(){return this.options.params}updateOptions(m,d){if(!m)return;const _=m;let D=this.options;null!=_.duration&&(D.duration=Hn(_.duration)),null!=_.delay&&(D.delay=Hn(_.delay));const V=_.params;if(V){let J=D.params;J||(J=this.options.params={}),Object.keys(V).forEach(we=>{(!d||!J.hasOwnProperty(we))&&(J[we]=bo(V[we],J,this.errors))})}}_copyOptions(){const m={};if(this.options){const d=this.options.params;if(d){const _=m.params={};Object.keys(d).forEach(D=>{_[D]=d[D]})}}return m}createSubContext(m=null,d,_){const D=d||this.element,V=new Ed(this._driver,D,this.subInstructions,this._enterClassName,this._leaveClassName,this.errors,this.timelines,this.currentTimeline.fork(D,_||0));return V.previousNode=this.previousNode,V.currentAnimateTimings=this.currentAnimateTimings,V.options=this._copyOptions(),V.updateOptions(m),V.currentQueryIndex=this.currentQueryIndex,V.currentQueryTotal=this.currentQueryTotal,V.parentContext=this,this.subContextCount++,V}transformIntoNewTimeline(m){return this.previousNode=Lc,this.currentTimeline=this.currentTimeline.fork(this.element,m),this.timelines.push(this.currentTimeline),this.currentTimeline}appendInstructionToTimeline(m,d,_){const D={duration:d??m.duration,delay:this.currentTimeline.currentTime+(_??0)+m.delay,easing:""},V=new Df(this._driver,m.element,m.keyframes,m.preStyleProps,m.postStyleProps,D,m.stretchStartingKeyframe);return this.timelines.push(V),D}incrementTime(m){this.currentTimeline.forwardTime(this.currentTimeline.duration+m)}delayNextStep(m){m>0&&this.currentTimeline.delayNextStep(m)}invokeQuery(m,d,_,D,V,J){let we=[];if(D&&we.push(this.element),m.length>0){m=(m=m.replace(im,"."+this._enterClassName)).replace(Cf,"."+this._leaveClassName);let yt=this._driver.query(this.element,m,1!=_);0!==_&&(yt=_<0?yt.slice(yt.length+_,yt.length):yt.slice(0,_)),we.push(...yt)}return!V&&0==we.length&&J.push(function Wr(){return new c.wOt(3014,!1)}()),we}}class Ku{_driver;element;startTime;_elementTimelineStylesLookup;duration=0;easing=null;_previousKeyframe=new Map;_currentKeyframe=new Map;_keyframes=new Map;_styleSummary=new Map;_localTimelineStyles=new Map;_globalTimelineStyles;_pendingStyles=new Map;_backFill=new Map;_currentEmptyStepKeyframe=null;constructor(m,d,_,D){this._driver=m,this.element=d,this.startTime=_,this._elementTimelineStylesLookup=D,this._elementTimelineStylesLookup||(this._elementTimelineStylesLookup=new Map),this._globalTimelineStyles=this._elementTimelineStylesLookup.get(d),this._globalTimelineStyles||(this._globalTimelineStyles=this._localTimelineStyles,this._elementTimelineStylesLookup.set(d,this._localTimelineStyles)),this._loadKeyframe()}containsAnimation(){switch(this._keyframes.size){case 0:return!1;case 1:return this.hasCurrentStyleProperties();default:return!0}}hasCurrentStyleProperties(){return this._currentKeyframe.size>0}get currentTime(){return this.startTime+this.duration}delayNextStep(m){const d=1===this._keyframes.size&&this._pendingStyles.size;this.duration||d?(this.forwardTime(this.currentTime+m),d&&this.snapshotCurrentStyles()):this.startTime+=m}fork(m,d){return this.applyStylesToKeyframe(),new Ku(this._driver,m,d||this.currentTime,this._elementTimelineStylesLookup)}_loadKeyframe(){this._currentKeyframe&&(this._previousKeyframe=this._currentKeyframe),this._currentKeyframe=this._keyframes.get(this.duration),this._currentKeyframe||(this._currentKeyframe=new Map,this._keyframes.set(this.duration,this._currentKeyframe))}forwardFrame(){this.duration+=1,this._loadKeyframe()}forwardTime(m){this.applyStylesToKeyframe(),this.duration=m,this._loadKeyframe()}_updateStyle(m,d){this._localTimelineStyles.set(m,d),this._globalTimelineStyles.set(m,d),this._styleSummary.set(m,{time:this.currentTime,value:d})}allowOnlyTimelineStyles(){return this._currentEmptyStepKeyframe!==this._currentKeyframe}applyEmptyStep(m){m&&this._previousKeyframe.set("easing",m);for(let[d,_]of this._globalTimelineStyles)this._backFill.set(d,_||Dr.kp),this._currentKeyframe.set(d,Dr.kp);this._currentEmptyStepKeyframe=this._currentKeyframe}setStyles(m,d,_,D){d&&this._previousKeyframe.set("easing",d);const V=D&&D.params||{},J=function Af(v,m){const d=new Map;let _;return v.forEach(D=>{if("*"===D){_??=m.keys();for(let V of _)d.set(V,Dr.kp)}else for(let[V,J]of D)d.set(V,J)}),d}(m,this._globalTimelineStyles);for(let[we,Xe]of J){const yt=bo(Xe,V,_);this._pendingStyles.set(we,yt),this._localTimelineStyles.has(we)||this._backFill.set(we,this._globalTimelineStyles.get(we)??Dr.kp),this._updateStyle(we,yt)}}applyStylesToKeyframe(){0!=this._pendingStyles.size&&(this._pendingStyles.forEach((m,d)=>{this._currentKeyframe.set(d,m)}),this._pendingStyles.clear(),this._localTimelineStyles.forEach((m,d)=>{this._currentKeyframe.has(d)||this._currentKeyframe.set(d,m)}))}snapshotCurrentStyles(){for(let[m,d]of this._localTimelineStyles)this._pendingStyles.set(m,d),this._updateStyle(m,d)}getFinalKeyframe(){return this._keyframes.get(this.duration)}get properties(){const m=[];for(let d in this._currentKeyframe)m.push(d);return m}mergeTimelineCollectedStyles(m){m._styleSummary.forEach((d,_)=>{const D=this._styleSummary.get(_);(!D||d.time>D.time)&&this._updateStyle(_,d.value)})}buildKeyframes(){this.applyStylesToKeyframe();const m=new Set,d=new Set,_=1===this._keyframes.size&&0===this.duration;let D=[];this._keyframes.forEach((we,Xe)=>{const yt=new Map([...this._backFill,...we]);yt.forEach((un,_n)=>{un===Dr.FX?m.add(_n):un===Dr.kp&&d.add(_n)}),_||yt.set("offset",Xe/this.duration),D.push(yt)});const V=[...m.values()],J=[...d.values()];if(_){const we=D[0],Xe=new Map(we);we.set("offset",0),Xe.set("offset",1),D=[we,Xe]}return bd(this.element,D,V,J,this.duration,this.startTime,this.easing,!1)}}class Df extends Ku{keyframes;preStyleProps;postStyleProps;_stretchStartingKeyframe;timings;constructor(m,d,_,D,V,J,we=!1){super(m,d,J.delay),this.keyframes=_,this.preStyleProps=D,this.postStyleProps=V,this._stretchStartingKeyframe=we,this.timings={duration:J.duration,delay:J.delay,easing:J.easing}}containsAnimation(){return this.keyframes.length>1}buildKeyframes(){let m=this.keyframes,{delay:d,duration:_,easing:D}=this.timings;if(this._stretchStartingKeyframe&&d){const V=[],J=_+d,we=d/J,Xe=new Map(m[0]);Xe.set("offset",0),V.push(Xe);const yt=new Map(m[0]);yt.set("offset",yh(we)),V.push(yt);const un=m.length-1;for(let _n=1;_n<=un;_n++){let gr=new Map(m[_n]);const er=gr.get("offset");gr.set("offset",yh((d+er*_)/J)),V.push(gr)}_=J,d=0,D="",m=V}return bd(this.element,m,this.preStyleProps,this.postStyleProps,_,d,D,!0)}}function yh(v,m=3){const d=Math.pow(10,m-1);return Math.round(v*d)/d}function bh(v,m,d,_,D,V,J,we,Xe,yt,un,_n,gr){return{type:0,element:v,triggerName:m,isRemovalTransition:D,fromState:d,fromStyles:V,toState:_,toStyles:J,timelines:we,queriedElements:Xe,preStyleProps:yt,postStyleProps:un,totalTime:_n,errors:gr}}const fu={};class Fl{_triggerName;ast;_stateStyles;constructor(m,d,_){this._triggerName=m,this.ast=d,this._stateStyles=_}match(m,d,_,D){return function xd(v,m,d,_,D){return v.some(V=>V(m,d,_,D))}(this.ast.matchers,m,d,_,D)}buildStyles(m,d,_){let D=this._stateStyles.get("*");return void 0!==m&&(D=this._stateStyles.get(m?.toString())||D),D?D.buildStyles(d,_):new Map}build(m,d,_,D,V,J,we,Xe,yt,un){const _n=[],gr=this.ast.options&&this.ast.options.params||fu,fr=this.buildStyles(_,we&&we.params||fu,_n),ti=Xe&&Xe.params||fu,Ai=this.buildStyles(D,ti,_n),ko=new Set,ho=new Map,Ea=new Map,ta="void"===D,Ou={params:wh(ti,gr),delay:this.ast.options?.delay},vl=un?[]:wd(m,d,this.ast.animation,V,J,fr,Ai,Ou,yt,_n);let xa=0;return vl.forEach(Ya=>{xa=Math.max(Ya.duration+Ya.delay,xa)}),_n.length?bh(d,this._triggerName,_,D,ta,fr,Ai,[],[],ho,Ea,xa,_n):(vl.forEach(Ya=>{const Sl=Ya.element,Bl=pa(ho,Sl,new Set);Ya.preStyleProps.forEach(pd=>Bl.add(pd));const ff=pa(Ea,Sl,new Set);Ya.postStyleProps.forEach(pd=>ff.add(pd)),Sl!==d&&ko.add(Sl)}),bh(d,this._triggerName,_,D,ta,fr,Ai,vl,[...ko.values()],ho,Ea,xa))}}function wh(v,m){const d={...m};return Object.entries(v).forEach(([_,D])=>{null!=D&&(d[_]=D)}),d}class Pc{styles;defaultParams;normalizer;constructor(m,d,_){this.styles=m,this.defaultParams=d,this.normalizer=_}buildStyles(m,d){const _=new Map,D=wh(m,this.defaultParams);return this.styles.styles.forEach(V=>{"string"!=typeof V&&V.forEach((J,we)=>{J&&(J=bo(J,D,d));const Xe=this.normalizer.normalizePropertyName(we,d);J=this.normalizer.normalizeStyleValue(we,Xe,J,d),_.set(we,J)})}),_}}class Fs{name;ast;_normalizer;transitionFactories=[];fallbackTransition;states=new Map;constructor(m,d,_){this.name=m,this.ast=d,this._normalizer=_,d.states.forEach(D=>{this.states.set(D.name,new Pc(D.style,D.options&&D.options.params||{},_))}),Eh(this.states,"true","1"),Eh(this.states,"false","0"),d.transitions.forEach(D=>{this.transitionFactories.push(new Fl(m,D,this.states))}),this.fallbackTransition=function Sf(v,m){return new Fl(v,{type:Dr.If.Transition,animation:{type:Dr.If.Sequence,steps:[],options:null},matchers:[(J,we)=>!0],options:null,queryCount:0,depCount:0},m)}(m,this.states)}get containsQueries(){return this.ast.queryCount>0}matchTransition(m,d,_,D){return this.transitionFactories.find(J=>J.match(m,d,_,D))||null}matchStyles(m,d,_){return this.fallbackTransition.buildStyles(m,d,_)}}function Eh(v,m,d){v.has(m)?v.has(d)||v.set(d,v.get(m)):v.has(d)&&v.set(m,v.get(d))}const Cd=new zu;class om{bodyNode;_driver;_normalizer;_animations=new Map;_playersById=new Map;players=[];constructor(m,d,_){this.bodyNode=m,this._driver=d,this._normalizer=_}register(m,d){const _=[],V=Vu(this._driver,d,_,[]);if(_.length)throw function dh(){return new c.wOt(3503,!1)}();this._animations.set(m,V)}_buildPlayer(m,d,_){const D=m.element,V=Nl(this._normalizer,m.keyframes,d,_);return this._driver.animate(D,V,m.duration,m.delay,m.easing,[],!0)}create(m,d,_={}){const D=[],V=this._animations.get(m);let J;const we=new Map;if(V?(J=wd(this._driver,d,V,An,Qt,new Map,new Map,_,Cd,D),J.forEach(un=>{const _n=pa(we,un.element,new Map);un.postStyleProps.forEach(gr=>_n.set(gr,null))})):(D.push(function hh(){return new c.wOt(3300,!1)}()),J=[]),D.length)throw function _c(){return new c.wOt(3504,!1)}();we.forEach((un,_n)=>{un.forEach((gr,er)=>{un.set(er,this._driver.computeStyle(_n,er,Dr.kp))})});const yt=Si(J.map(un=>{const _n=we.get(un.element);return this._buildPlayer(un,new Map,_n)}));return this._playersById.set(m,yt),yt.onDestroy(()=>this.destroy(m)),this.players.push(yt),yt}destroy(m){const d=this._getPlayer(m);d.destroy(),this._playersById.delete(m);const _=this.players.indexOf(d);_>=0&&this.players.splice(_,1)}_getPlayer(m){const d=this._playersById.get(m);if(!d)throw function Ql(){return new c.wOt(3301,!1)}();return d}listen(m,d,_,D){const V=Oc(d,"","","");return Ra(this._getPlayer(m),_,V,D),()=>{}}command(m,d,_,D){if("register"==_)return void this.register(m,D[0]);if("create"==_)return void this.create(m,d,D[0]||{});const V=this._getPlayer(m);switch(_){case"play":V.play();break;case"pause":V.pause();break;case"reset":V.reset();break;case"restart":V.restart();break;case"finish":V.finish();break;case"init":V.init();break;case"setPosition":V.setPosition(parseFloat(D[0]));break;case"destroy":this.destroy(m)}}}const Gu="ng-animate-queued",xh="ng-animate-disabled",Tf=[],Mf={namespaceId:"",setForRemoval:!1,setForMove:!1,hasAnimation:!1,removedBeforeQueried:!1},Ad={namespaceId:"",setForMove:!1,setForRemoval:!1,hasAnimation:!1,removedBeforeQueried:!0},Ga="__ng_removed";class Sd{namespaceId;value;options;get params(){return this.options.params}constructor(m,d=""){this.namespaceId=d;const _=m&&m.hasOwnProperty("value");if(this.value=function Ah(v){return v??null}(_?m.value:m),_){const{value:V,...J}=m;this.options=J}else this.options={};this.options.params||(this.options.params={})}absorbOptions(m){const d=m.params;if(d){const _=this.options.params;Object.keys(d).forEach(D=>{null==_[D]&&(_[D]=d[D])})}}}const Qu="void",Td=new Sd(Qu);class Ch{id;hostElement;_engine;players=[];_triggers=new Map;_queue=[];_elementListeners=new Map;_hostClassName;constructor(m,d,_){this.id=m,this.hostElement=d,this._engine=_,this._hostClassName="ng-tns-"+m,ws(d,this._hostClassName)}listen(m,d,_,D){if(!this._triggers.has(d))throw function Zl(){return new c.wOt(3302,!1)}();if(null==_||0==_.length)throw function uu(){return new c.wOt(3303,!1)}();if(!function lm(v){return"start"==v||"done"==v}(_))throw function du(){return new c.wOt(3400,!1)}();const V=pa(this._elementListeners,m,[]),J={name:d,phase:_,callback:D};V.push(J);const we=pa(this._engine.statesByElement,m,new Map);return we.has(d)||(ws(m,Gn),ws(m,Gn+"-"+d),we.set(d,Td)),()=>{this._engine.afterFlush(()=>{const Xe=V.indexOf(J);Xe>=0&&V.splice(Xe,1),this._triggers.has(d)||we.delete(d)})}}register(m,d){return!this._triggers.has(m)&&(this._triggers.set(m,d),!0)}_getTrigger(m){const d=this._triggers.get(m);if(!d)throw function Ja(){return new c.wOt(3401,!1)}();return d}trigger(m,d,_,D=!0){const V=this._getTrigger(d),J=new am(this.id,d,m);let we=this._engine.statesByElement.get(m);we||(ws(m,Gn),ws(m,Gn+"-"+d),this._engine.statesByElement.set(m,we=new Map));let Xe=we.get(d);const yt=new Sd(_,this.id);if(!(_&&_.hasOwnProperty("value"))&&Xe&&yt.absorbOptions(Xe.options),we.set(d,yt),Xe||(Xe=Td),yt.value!==Qu&&Xe.value===yt.value){if(!function If(v,m){const d=Object.keys(v),_=Object.keys(m);if(d.length!=_.length)return!1;for(let D=0;D{Gr(m,Ai),Cr(m,ko)})}return}const gr=pa(this._engine.playersByElement,m,[]);gr.forEach(ti=>{ti.namespaceId==this.id&&ti.triggerName==d&&ti.queued&&ti.destroy()});let er=V.matchTransition(Xe.value,yt.value,m,yt.params),fr=!1;if(!er){if(!D)return;er=V.fallbackTransition,fr=!0}return this._engine.totalQueuedPlayers++,this._queue.push({element:m,triggerName:d,transition:er,fromState:Xe,toState:yt,player:J,isFallbackTransition:fr}),fr||(ws(m,Gu),J.onStart(()=>{Fc(m,Gu)})),J.onDone(()=>{let ti=this.players.indexOf(J);ti>=0&&this.players.splice(ti,1);const Ai=this._engine.playersByElement.get(m);if(Ai){let ko=Ai.indexOf(J);ko>=0&&Ai.splice(ko,1)}}),this.players.push(J),gr.push(J),J}deregister(m){this._triggers.delete(m),this._engine.statesByElement.forEach(d=>d.delete(m)),this._elementListeners.forEach((d,_)=>{this._elementListeners.set(_,d.filter(D=>D.name!=m))})}clearElementCache(m){this._engine.statesByElement.delete(m),this._elementListeners.delete(m);const d=this._engine.playersByElement.get(m);d&&(d.forEach(_=>_.destroy()),this._engine.playersByElement.delete(m))}_signalRemovalForInnerTriggers(m,d){const _=this._engine.driver.query(m,zn,!0);_.forEach(D=>{if(D[Ga])return;const V=this._engine.fetchNamespacesByElement(D);V.size?V.forEach(J=>J.triggerLeaveAnimation(D,d,!1,!0)):this.clearElementCache(D)}),this._engine.afterFlushAnimationsDone(()=>_.forEach(D=>this.clearElementCache(D)))}triggerLeaveAnimation(m,d,_,D){const V=this._engine.statesByElement.get(m),J=new Map;if(V){const we=[];if(V.forEach((Xe,yt)=>{if(J.set(yt,Xe.value),this._triggers.has(yt)){const un=this.trigger(m,yt,Qu,D);un&&we.push(un)}}),we.length)return this._engine.markElementAsRemoved(this.id,m,!0,d,J),_&&Si(we).onDone(()=>this._engine.processLeaveNode(m)),!0}return!1}prepareLeaveAnimationListeners(m){const d=this._elementListeners.get(m),_=this._engine.statesByElement.get(m);if(d&&_){const D=new Set;d.forEach(V=>{const J=V.name;if(D.has(J))return;D.add(J);const Xe=this._triggers.get(J).fallbackTransition,yt=_.get(J)||Td,un=new Sd(Qu),_n=new am(this.id,J,m);this._engine.totalQueuedPlayers++,this._queue.push({element:m,triggerName:J,transition:Xe,fromState:yt,toState:un,player:_n,isFallbackTransition:!0})})}}removeNode(m,d){const _=this._engine;if(m.childElementCount&&this._signalRemovalForInnerTriggers(m,d),this.triggerLeaveAnimation(m,d,!0))return;let D=!1;if(_.totalAnimations){const V=_.players.length?_.playersByQueriedElement.get(m):[];if(V&&V.length)D=!0;else{let J=m;for(;J=J.parentNode;)if(_.statesByElement.get(J)){D=!0;break}}}if(this.prepareLeaveAnimationListeners(m),D)_.markElementAsRemoved(this.id,m,!1,d);else{const V=m[Ga];(!V||V===Mf)&&(_.afterFlush(()=>this.clearElementCache(m)),_.destroyInnerAnimations(m),_._onRemovalComplete(m,d))}}insertNode(m,d){ws(m,this._hostClassName)}drainQueuedTransitions(m){const d=[];return this._queue.forEach(_=>{const D=_.player;if(D.destroyed)return;const V=_.element,J=this._elementListeners.get(V);J&&J.forEach(we=>{if(we.name==_.triggerName){const Xe=Oc(V,_.triggerName,_.fromState.value,_.toState.value);Xe._data=m,Ra(_.player,we.phase,Xe,we.callback)}}),D.markedForDestroy?this._engine.afterFlush(()=>{D.destroy()}):d.push(_)}),this._queue=[],d.sort((_,D)=>{const V=_.transition.ast.depCount,J=D.transition.ast.depCount;return 0==V||0==J?V-J:this._engine.driver.containsElement(_.element,D.element)?1:-1})}destroy(m){this.players.forEach(d=>d.destroy()),this._signalRemovalForInnerTriggers(this.hostElement,m)}}class sm{bodyNode;driver;_normalizer;players=[];newHostElements=new Map;playersByElement=new Map;playersByQueriedElement=new Map;statesByElement=new Map;disabledNodes=new Set;totalAnimations=0;totalQueuedPlayers=0;_namespaceLookup={};_namespaceList=[];_flushFns=[];_whenQuietFns=[];namespacesByHostElement=new Map;collectedEnterElements=[];collectedLeaveElements=[];onRemovalComplete=(m,d)=>{};_onRemovalComplete(m,d){this.onRemovalComplete(m,d)}constructor(m,d,_){this.bodyNode=m,this.driver=d,this._normalizer=_}get queuedPlayers(){const m=[];return this._namespaceList.forEach(d=>{d.players.forEach(_=>{_.queued&&m.push(_)})}),m}createNamespace(m,d){const _=new Ch(m,d,this);return this.bodyNode&&this.driver.containsElement(this.bodyNode,d)?this._balanceNamespaceList(_,d):(this.newHostElements.set(d,_),this.collectEnterElement(d)),this._namespaceLookup[m]=_}_balanceNamespaceList(m,d){const _=this._namespaceList,D=this.namespacesByHostElement;if(_.length-1>=0){let J=!1,we=this.driver.getParentElement(d);for(;we;){const Xe=D.get(we);if(Xe){const yt=_.indexOf(Xe);_.splice(yt+1,0,m),J=!0;break}we=this.driver.getParentElement(we)}J||_.unshift(m)}else _.push(m);return D.set(d,m),m}register(m,d){let _=this._namespaceLookup[m];return _||(_=this.createNamespace(m,d)),_}registerTrigger(m,d,_){let D=this._namespaceLookup[m];D&&D.register(d,_)&&this.totalAnimations++}destroy(m,d){m&&(this.afterFlush(()=>{}),this.afterFlushAnimationsDone(()=>{const _=this._fetchNamespace(m);this.namespacesByHostElement.delete(_.hostElement);const D=this._namespaceList.indexOf(_);D>=0&&this._namespaceList.splice(D,1),_.destroy(d),delete this._namespaceLookup[m]}))}_fetchNamespace(m){return this._namespaceLookup[m]}fetchNamespacesByElement(m){const d=new Set,_=this.statesByElement.get(m);if(_)for(let D of _.values())if(D.namespaceId){const V=this._fetchNamespace(D.namespaceId);V&&d.add(V)}return d}trigger(m,d,_,D){if(Qo(d)){const V=this._fetchNamespace(m);if(V)return V.trigger(d,_,D),!0}return!1}insertNode(m,d,_,D){if(!Qo(d))return;const V=d[Ga];if(V&&V.setForRemoval){V.setForRemoval=!1,V.setForMove=!0;const J=this.collectedLeaveElements.indexOf(d);J>=0&&this.collectedLeaveElements.splice(J,1)}if(m){const J=this._fetchNamespace(m);J&&J.insertNode(d,_)}D&&this.collectEnterElement(d)}collectEnterElement(m){this.collectedEnterElements.push(m)}markElementAsDisabled(m,d){d?this.disabledNodes.has(m)||(this.disabledNodes.add(m),ws(m,xh)):this.disabledNodes.has(m)&&(this.disabledNodes.delete(m),Fc(m,xh))}removeNode(m,d,_){if(Qo(d)){const D=m?this._fetchNamespace(m):null;D?D.removeNode(d,_):this.markElementAsRemoved(m,d,!1,_);const V=this.namespacesByHostElement.get(d);V&&V.id!==m&&V.removeNode(d,_)}else this._onRemovalComplete(d,_)}markElementAsRemoved(m,d,_,D,V){this.collectedLeaveElements.push(d),d[Ga]={namespaceId:m,setForRemoval:D,hasAnimation:_,removedBeforeQueried:!1,previousTriggersValues:V}}listen(m,d,_,D,V){return Qo(d)?this._fetchNamespace(m).listen(d,_,D,V):()=>{}}_buildInstruction(m,d,_,D,V){return m.transition.build(this.driver,m.element,m.fromState.value,m.toState.value,_,D,m.fromState.options,m.toState.options,d,V)}destroyInnerAnimations(m){let d=this.driver.query(m,zn,!0);d.forEach(_=>this.destroyActiveAnimationsForElement(_)),0!=this.playersByQueriedElement.size&&(d=this.driver.query(m,Mn,!0),d.forEach(_=>this.finishActiveQueriedAnimationOnElement(_)))}destroyActiveAnimationsForElement(m){const d=this.playersByElement.get(m);d&&d.forEach(_=>{_.queued?_.markedForDestroy=!0:_.destroy()})}finishActiveQueriedAnimationOnElement(m){const d=this.playersByQueriedElement.get(m);d&&d.forEach(_=>_.finish())}whenRenderingDone(){return new Promise(m=>{if(this.players.length)return Si(this.players).onDone(()=>m());m()})}processLeaveNode(m){const d=m[Ga];if(d&&d.setForRemoval){if(m[Ga]=Mf,d.namespaceId){this.destroyInnerAnimations(m);const _=this._fetchNamespace(d.namespaceId);_&&_.clearElementCache(m)}this._onRemovalComplete(m,d.setForRemoval)}m.classList?.contains(xh)&&this.markElementAsDisabled(m,!1),this.driver.query(m,".ng-animate-disabled",!0).forEach(_=>{this.markElementAsDisabled(_,!1)})}flush(m=-1){let d=[];if(this.newHostElements.size&&(this.newHostElements.forEach((_,D)=>this._balanceNamespaceList(_,D)),this.newHostElements.clear()),this.totalAnimations&&this.collectedEnterElements.length)for(let _=0;__()),this._flushFns=[],this._whenQuietFns.length){const _=this._whenQuietFns;this._whenQuietFns=[],d.length?Si(d).onDone(()=>{_.forEach(D=>D())}):_.forEach(D=>D())}}reportError(m){throw function En(){return new c.wOt(3402,!1)}()}_flushAnimations(m,d){const _=new zu,D=[],V=new Map,J=[],we=new Map,Xe=new Map,yt=new Map,un=new Set;this.disabledNodes.forEach(Zr=>{un.add(Zr);const vi=this.driver.query(Zr,".ng-animate-queued",!0);for(let Ti=0;Ti{const Ti=An+ti++;fr.set(vi,Ti),Zr.forEach(xo=>ws(xo,Ti))});const Ai=[],ko=new Set,ho=new Set;for(let Zr=0;Zrko.add(xo)):ho.add(vi))}const Ea=new Map,ta=Sh(gr,Array.from(ko));ta.forEach((Zr,vi)=>{const Ti=Qt+ti++;Ea.set(vi,Ti),Zr.forEach(xo=>ws(xo,Ti))}),m.push(()=>{er.forEach((Zr,vi)=>{const Ti=fr.get(vi);Zr.forEach(xo=>Fc(xo,Ti))}),ta.forEach((Zr,vi)=>{const Ti=Ea.get(vi);Zr.forEach(xo=>Fc(xo,Ti))}),Ai.forEach(Zr=>{this.processLeaveNode(Zr)})});const Ou=[],vl=[];for(let Zr=this._namespaceList.length-1;Zr>=0;Zr--)this._namespaceList[Zr].drainQueuedTransitions(d).forEach(Ti=>{const xo=Ti.player,Ca=Ti.element;if(Ou.push(xo),this.collectedEnterElements.length){const ra=Ca[Ga];if(ra&&ra.setForMove){if(ra.previousTriggersValues&&ra.previousTriggersValues.has(Ti.triggerName)){const Qc=ra.previousTriggersValues.get(Ti.triggerName),dc=this.statesByElement.get(Ti.element);if(dc&&dc.has(Ti.triggerName)){const pf=dc.get(Ti.triggerName);pf.value=Qc,dc.set(Ti.triggerName,pf)}}return void xo.destroy()}}const na=!_n||!this.driver.containsElement(_n,Ca),sl=Ea.get(Ca),Ru=fr.get(Ca),xs=this._buildInstruction(Ti,_,Ru,sl,na);if(xs.errors&&xs.errors.length)return void vl.push(xs);if(na)return xo.onStart(()=>Gr(Ca,xs.fromStyles)),xo.onDestroy(()=>Cr(Ca,xs.toStyles)),void D.push(xo);if(Ti.isFallbackTransition)return xo.onStart(()=>Gr(Ca,xs.fromStyles)),xo.onDestroy(()=>Cr(Ca,xs.toStyles)),void D.push(xo);const ng=[];xs.timelines.forEach(ra=>{ra.stretchStartingKeyframe=!0,this.disabledNodes.has(ra.element)||ng.push(ra)}),xs.timelines=ng,_.append(Ca,xs.timelines),J.push({instruction:xs,player:xo,element:Ca}),xs.queriedElements.forEach(ra=>pa(we,ra,[]).push(xo)),xs.preStyleProps.forEach((ra,Qc)=>{if(ra.size){let dc=Xe.get(Qc);dc||Xe.set(Qc,dc=new Set),ra.forEach((pf,Dp)=>dc.add(Dp))}}),xs.postStyleProps.forEach((ra,Qc)=>{let dc=yt.get(Qc);dc||yt.set(Qc,dc=new Set),ra.forEach((pf,Dp)=>dc.add(Dp))})});if(vl.length){const Zr=[];vl.forEach(vi=>{Zr.push(function Ic(){return new c.wOt(3505,!1)}())}),Ou.forEach(vi=>vi.destroy()),this.reportError(Zr)}const xa=new Map,Ya=new Map;J.forEach(Zr=>{const vi=Zr.element;_.has(vi)&&(Ya.set(vi,vi),this._beforeAnimationBuild(Zr.player.namespaceId,Zr.instruction,xa))}),D.forEach(Zr=>{const vi=Zr.element;this._getPreviousPlayers(vi,!1,Zr.namespaceId,Zr.triggerName,null).forEach(xo=>{pa(xa,vi,[]).push(xo),xo.destroy()})});const Sl=Ai.filter(Zr=>Od(Zr,Xe,yt)),Bl=new Map;kf(Bl,this.driver,ho,yt,Dr.kp).forEach(Zr=>{Od(Zr,Xe,yt)&&Sl.push(Zr)});const pd=new Map;er.forEach((Zr,vi)=>{kf(pd,this.driver,new Set(Zr),Xe,Dr.FX)}),Sl.forEach(Zr=>{const vi=Bl.get(Zr),Ti=pd.get(Zr);Bl.set(Zr,new Map([...vi?.entries()??[],...Ti?.entries()??[]]))});const tg=[],Cp=[],ov={};J.forEach(Zr=>{const{element:vi,player:Ti,instruction:xo}=Zr;if(_.has(vi)){if(un.has(vi))return Ti.onDestroy(()=>Cr(vi,xo.toStyles)),Ti.disabled=!0,Ti.overrideTotalTime(xo.totalTime),void D.push(Ti);let Ca=ov;if(Ya.size>1){let sl=vi;const Ru=[];for(;sl=sl.parentNode;){const xs=Ya.get(sl);if(xs){Ca=xs;break}Ru.push(sl)}Ru.forEach(xs=>Ya.set(xs,Ca))}const na=this._buildAnimation(Ti.namespaceId,xo,xa,V,pd,Bl);if(Ti.setRealPlayer(na),Ca===ov)tg.push(Ti);else{const sl=this.playersByElement.get(Ca);sl&&sl.length&&(Ti.parentPlayer=Si(sl)),D.push(Ti)}}else Gr(vi,xo.fromStyles),Ti.onDestroy(()=>Cr(vi,xo.toStyles)),Cp.push(Ti),un.has(vi)&&D.push(Ti)}),Cp.forEach(Zr=>{const vi=V.get(Zr.element);if(vi&&vi.length){const Ti=Si(vi);Zr.setRealPlayer(Ti)}}),D.forEach(Zr=>{Zr.parentPlayer?Zr.syncPlayerEvents(Zr.parentPlayer):Zr.destroy()});for(let Zr=0;Zr!na.destroyed);Ca.length?kd(this,vi,Ca):this.processLeaveNode(vi)}return Ai.length=0,tg.forEach(Zr=>{this.players.push(Zr),Zr.onDone(()=>{Zr.destroy();const vi=this.players.indexOf(Zr);this.players.splice(vi,1)}),Zr.play()}),tg}afterFlush(m){this._flushFns.push(m)}afterFlushAnimationsDone(m){this._whenQuietFns.push(m)}_getPreviousPlayers(m,d,_,D,V){let J=[];if(d){const we=this.playersByQueriedElement.get(m);we&&(J=we)}else{const we=this.playersByElement.get(m);if(we){const Xe=!V||V==Qu;we.forEach(yt=>{yt.queued||!Xe&&yt.triggerName!=D||J.push(yt)})}}return(_||D)&&(J=J.filter(we=>!(_&&_!=we.namespaceId||D&&D!=we.triggerName))),J}_beforeAnimationBuild(m,d,_){const V=d.element,J=d.isRemovalTransition?void 0:m,we=d.isRemovalTransition?void 0:d.triggerName;for(const Xe of d.timelines){const yt=Xe.element,un=yt!==V,_n=pa(_,yt,[]);this._getPreviousPlayers(yt,un,J,we,d.toState).forEach(er=>{const fr=er.getRealPlayer();fr.beforeDestroy&&fr.beforeDestroy(),er.destroy(),_n.push(er)})}Gr(V,d.fromStyles)}_buildAnimation(m,d,_,D,V,J){const we=d.triggerName,Xe=d.element,yt=[],un=new Set,_n=new Set,gr=d.timelines.map(fr=>{const ti=fr.element;un.add(ti);const Ai=ti[Ga];if(Ai&&Ai.removedBeforeQueried)return new Dr.sf(fr.duration,fr.delay);const ko=ti!==Xe,ho=function rc(v){const m=[];return gu(v,m),m}((_.get(ti)||Tf).map(xa=>xa.getRealPlayer())).filter(xa=>!!xa.element&&xa.element===ti),Ea=V.get(ti),ta=J.get(ti),Ou=Nl(this._normalizer,fr.keyframes,Ea,ta),vl=this._buildPlayer(fr,Ou,ho);if(fr.subTimeline&&D&&_n.add(ti),ko){const xa=new am(m,we,ti);xa.setRealPlayer(vl),yt.push(xa)}return vl});yt.forEach(fr=>{pa(this.playersByQueriedElement,fr.element,[]).push(fr),fr.onDone(()=>function Dh(v,m,d){let _=v.get(m);if(_){if(_.length){const D=_.indexOf(d);_.splice(D,1)}0==_.length&&v.delete(m)}return _}(this.playersByQueriedElement,fr.element,fr))}),un.forEach(fr=>ws(fr,nr));const er=Si(gr);return er.onDestroy(()=>{un.forEach(fr=>Fc(fr,nr)),Cr(Xe,d.toStyles)}),_n.forEach(fr=>{pa(D,fr,[]).push(er)}),er}_buildPlayer(m,d,_){return d.length>0?this.driver.animate(m.element,d,m.duration,m.delay,m.easing,_):new Dr.sf(m.duration,m.delay)}}class am{namespaceId;triggerName;element;_player=new Dr.sf;_containsRealPlayer=!1;_queuedCallbacks=new Map;destroyed=!1;parentPlayer=null;markedForDestroy=!1;disabled=!1;queued=!0;totalTime=0;constructor(m,d,_){this.namespaceId=m,this.triggerName=d,this.element=_}setRealPlayer(m){this._containsRealPlayer||(this._player=m,this._queuedCallbacks.forEach((d,_)=>{d.forEach(D=>Ra(m,_,void 0,D))}),this._queuedCallbacks.clear(),this._containsRealPlayer=!0,this.overrideTotalTime(m.totalTime),this.queued=!1)}getRealPlayer(){return this._player}overrideTotalTime(m){this.totalTime=m}syncPlayerEvents(m){const d=this._player;d.triggerCallback&&m.onStart(()=>d.triggerCallback("start")),m.onDone(()=>this.finish()),m.onDestroy(()=>this.destroy())}_queueEvent(m,d){pa(this._queuedCallbacks,m,[]).push(d)}onDone(m){this.queued&&this._queueEvent("done",m),this._player.onDone(m)}onStart(m){this.queued&&this._queueEvent("start",m),this._player.onStart(m)}onDestroy(m){this.queued&&this._queueEvent("destroy",m),this._player.onDestroy(m)}init(){this._player.init()}hasStarted(){return!this.queued&&this._player.hasStarted()}play(){!this.queued&&this._player.play()}pause(){!this.queued&&this._player.pause()}restart(){!this.queued&&this._player.restart()}finish(){this._player.finish()}destroy(){this.destroyed=!0,this._player.destroy()}reset(){!this.queued&&this._player.reset()}setPosition(m){this.queued||this._player.setPosition(m)}getPosition(){return this.queued?0:this._player.getPosition()}triggerCallback(m){const d=this._player;d.triggerCallback&&d.triggerCallback(m)}}function Qo(v){return v&&1===v.nodeType}function Md(v,m){const d=v.style.display;return v.style.display=m??"none",d}function kf(v,m,d,_,D){const V=[];d.forEach(Xe=>V.push(Md(Xe)));const J=[];_.forEach((Xe,yt)=>{const un=new Map;Xe.forEach(_n=>{const gr=m.computeStyle(yt,_n,D);un.set(_n,gr),(!gr||0==gr.length)&&(yt[Ga]=Ad,J.push(yt))}),v.set(yt,un)});let we=0;return d.forEach(Xe=>Md(Xe,V[we++])),J}function Sh(v,m){const d=new Map;if(v.forEach(we=>d.set(we,[])),0==m.length)return d;const D=new Set(m),V=new Map;function J(we){if(!we)return 1;let Xe=V.get(we);if(Xe)return Xe;const yt=we.parentNode;return Xe=d.has(yt)?yt:D.has(yt)?1:J(yt),V.set(we,Xe),Xe}return m.forEach(we=>{const Xe=J(we);1!==Xe&&d.get(Xe).push(we)}),d}function ws(v,m){v.classList?.add(m)}function Fc(v,m){v.classList?.remove(m)}function kd(v,m,d){Si(d).onDone(()=>v.processLeaveNode(m))}function gu(v,m){for(let d=0;dD.add(V)):m.set(v,_),d.delete(v),!0}class ic{_driver;_normalizer;_transitionEngine;_timelineEngine;_triggerCache={};onRemovalComplete=(m,d)=>{};constructor(m,d,_){this._driver=d,this._normalizer=_,this._transitionEngine=new sm(m.body,d,_),this._timelineEngine=new om(m.body,d,_),this._transitionEngine.onRemovalComplete=(D,V)=>this.onRemovalComplete(D,V)}registerTrigger(m,d,_,D,V){const J=m+"-"+D;let we=this._triggerCache[J];if(!we){const Xe=[],un=Vu(this._driver,V,Xe,[]);if(Xe.length)throw function _d(){return new c.wOt(3404,!1)}();we=function pu(v,m,d){return new Fs(v,m,d)}(D,un,this._normalizer),this._triggerCache[J]=we}this._transitionEngine.registerTrigger(d,D,we)}register(m,d){this._transitionEngine.register(m,d)}destroy(m,d){this._transitionEngine.destroy(m,d)}onInsert(m,d,_,D){this._transitionEngine.insertNode(m,d,_,D)}onRemove(m,d,_){this._transitionEngine.removeNode(m,d,_)}disableAnimations(m,d){this._transitionEngine.markElementAsDisabled(m,d)}process(m,d,_,D){if("@"==_.charAt(0)){const[V,J]=vd(_);this._timelineEngine.command(V,d,J,D)}else this._transitionEngine.trigger(m,d,_,D)}listen(m,d,_,D,V){if("@"==_.charAt(0)){const[J,we]=vd(_);return this._timelineEngine.listen(J,d,we,V)}return this._transitionEngine.listen(m,d,_,D,V)}flush(m=-1){this._transitionEngine.flush(m)}get players(){return[...this._transitionEngine.players,...this._timelineEngine.players]}whenRenderingDone(){return this._transitionEngine.whenRenderingDone()}afterFlushAnimationsDone(m){this._transitionEngine.afterFlushAnimationsDone(m)}}let Th=(()=>{class v{_element;_startStyles;_endStyles;static initialStylesByElement=new WeakMap;_state=0;_initialStyles;constructor(d,_,D){this._element=d,this._startStyles=_,this._endStyles=D;let V=v.initialStylesByElement.get(d);V||v.initialStylesByElement.set(d,V=new Map),this._initialStyles=V}start(){this._state<1&&(this._startStyles&&Cr(this._element,this._startStyles,this._initialStyles),this._state=1)}finish(){this.start(),this._state<2&&(Cr(this._element,this._initialStyles),this._endStyles&&(Cr(this._element,this._endStyles),this._endStyles=null),this._state=1)}destroy(){this.finish(),this._state<3&&(v.initialStylesByElement.delete(this._element),this._startStyles&&(Gr(this._element,this._startStyles),this._endStyles=null),this._endStyles&&(Gr(this._element,this._endStyles),this._endStyles=null),Cr(this._element,this._initialStyles),this._state=3)}}return v})();function Mh(v){let m=null;return v.forEach((d,_)=>{(function oc(v){return"display"===v||"position"===v})(_)&&(m=m||new Map,m.set(_,d))}),m}class _u{element;keyframes;options;_specialStyles;_onDoneFns=[];_onStartFns=[];_onDestroyFns=[];_duration;_delay;_initialized=!1;_finished=!1;_started=!1;_destroyed=!1;_finalKeyframe;_originalOnDoneFns=[];_originalOnStartFns=[];domPlayer;time=0;parentPlayer=null;currentSnapshot=new Map;constructor(m,d,_,D){this.element=m,this.keyframes=d,this.options=_,this._specialStyles=D,this._duration=_.duration,this._delay=_.delay||0,this.time=this._duration+this._delay}_onFinish(){this._finished||(this._finished=!0,this._onDoneFns.forEach(m=>m()),this._onDoneFns=[])}init(){this._buildPlayer(),this._preparePlayerBeforeStart()}_buildPlayer(){if(this._initialized)return;this._initialized=!0;const m=this.keyframes;this.domPlayer=this._triggerWebAnimation(this.element,m,this.options),this._finalKeyframe=m.length?m[m.length-1]:new Map;const d=()=>this._onFinish();this.domPlayer.addEventListener("finish",d),this.onDestroy(()=>{this.domPlayer.removeEventListener("finish",d)})}_preparePlayerBeforeStart(){this._delay?this._resetDomPlayerState():this.domPlayer.pause()}_convertKeyframesToObject(m){const d=[];return m.forEach(_=>{d.push(Object.fromEntries(_))}),d}_triggerWebAnimation(m,d,_){return m.animate(this._convertKeyframesToObject(d),_)}onStart(m){this._originalOnStartFns.push(m),this._onStartFns.push(m)}onDone(m){this._originalOnDoneFns.push(m),this._onDoneFns.push(m)}onDestroy(m){this._onDestroyFns.push(m)}play(){this._buildPlayer(),this.hasStarted()||(this._onStartFns.forEach(m=>m()),this._onStartFns=[],this._started=!0,this._specialStyles&&this._specialStyles.start()),this.domPlayer.play()}pause(){this.init(),this.domPlayer.pause()}finish(){this.init(),this._specialStyles&&this._specialStyles.finish(),this._onFinish(),this.domPlayer.finish()}reset(){this._resetDomPlayerState(),this._destroyed=!1,this._finished=!1,this._started=!1,this._onStartFns=this._originalOnStartFns,this._onDoneFns=this._originalOnDoneFns}_resetDomPlayerState(){this.domPlayer&&this.domPlayer.cancel()}restart(){this.reset(),this.play()}hasStarted(){return this._started}destroy(){this._destroyed||(this._destroyed=!0,this._resetDomPlayerState(),this._onFinish(),this._specialStyles&&this._specialStyles.destroy(),this._onDestroyFns.forEach(m=>m()),this._onDestroyFns=[])}setPosition(m){void 0===this.domPlayer&&this.init(),this.domPlayer.currentTime=m*this.time}getPosition(){return+(this.domPlayer.currentTime??0)/this.time}get totalTime(){return this._delay+this._duration}beforeDestroy(){const m=new Map;this.hasStarted()&&this._finalKeyframe.forEach((_,D)=>{"offset"!==D&&m.set(D,this._finished?_:Mo(this.element,D))}),this.currentSnapshot=m}triggerCallback(m){const d="start"===m?this._onStartFns:this._onDoneFns;d.forEach(_=>_()),d.length=0}}class Rd{validateStyleProperty(m){return!0}validateAnimatableStyleProperty(m){return!0}containsElement(m,d){return I(m,d)}getParentElement(m){return fh(m)}query(m,d,_){return P(m,d,_)}computeStyle(m,d,_){return Mo(m,d)}animate(m,d,_,D,V,J=[]){const Xe={duration:_,delay:D,fill:0==D?"both":"forwards"};V&&(Xe.easing=V);const yt=new Map,un=J.filter(er=>er instanceof _u);(function jr(v,m){return 0===v||0===m})(_,D)&&un.forEach(er=>{er.currentSnapshot.forEach((fr,ti)=>yt.set(ti,fr))});let _n=function Ir(v){return v.length?v[0]instanceof Map?v:v.map(m=>new Map(Object.entries(m))):[]}(d).map(er=>new Map(er));_n=function Hi(v,m,d){if(d.size&&m.length){let _=m[0],D=[];if(d.forEach((V,J)=>{_.has(J)||D.push(J),_.set(J,V)}),D.length)for(let V=1;VJ.set(we,Mo(v,we)))}}return m}(m,_n,yt);const gr=function Ec(v,m){let d=null,_=null;return Array.isArray(m)&&m.length?(d=Mh(m[0]),m.length>1&&(_=Mh(m[m.length-1]))):m instanceof Map&&(d=Mh(m)),d||_?new Th(v,d,_):null}(m,_n);return new _u(m,_n,Xe,gr)}}const Zu="@.disabled";class kh{namespaceId;delegate;engine;_onDestroy;\u0275type=0;constructor(m,d,_,D){this.namespaceId=m,this.delegate=d,this.engine=_,this._onDestroy=D}get data(){return this.delegate.data}destroyNode(m){this.delegate.destroyNode?.(m)}destroy(){this.engine.destroy(this.namespaceId,this.delegate),this.engine.afterFlushAnimationsDone(()=>{queueMicrotask(()=>{this.delegate.destroy()})}),this._onDestroy?.()}createElement(m,d){return this.delegate.createElement(m,d)}createComment(m){return this.delegate.createComment(m)}createText(m){return this.delegate.createText(m)}appendChild(m,d){this.delegate.appendChild(m,d),this.engine.onInsert(this.namespaceId,d,m,!1)}insertBefore(m,d,_,D=!0){this.delegate.insertBefore(m,d,_),this.engine.onInsert(this.namespaceId,d,m,D)}removeChild(m,d,_){this.parentNode(d)&&this.engine.onRemove(this.namespaceId,d,this.delegate)}selectRootElement(m,d){return this.delegate.selectRootElement(m,d)}parentNode(m){return this.delegate.parentNode(m)}nextSibling(m){return this.delegate.nextSibling(m)}setAttribute(m,d,_,D){this.delegate.setAttribute(m,d,_,D)}removeAttribute(m,d,_){this.delegate.removeAttribute(m,d,_)}addClass(m,d){this.delegate.addClass(m,d)}removeClass(m,d){this.delegate.removeClass(m,d)}setStyle(m,d,_,D){this.delegate.setStyle(m,d,_,D)}removeStyle(m,d,_){this.delegate.removeStyle(m,d,_)}setProperty(m,d,_){"@"==d.charAt(0)&&d==Zu?this.disableAnimations(m,!!_):this.delegate.setProperty(m,d,_)}setValue(m,d){this.delegate.setValue(m,d)}listen(m,d,_){return this.delegate.listen(m,d,_)}disableAnimations(m,d){this.engine.disableAnimations(m,d)}}class os extends kh{factory;constructor(m,d,_,D,V){super(d,_,D,V),this.factory=m,this.namespaceId=d}setProperty(m,d,_){"@"==d.charAt(0)?"."==d.charAt(1)&&d==Zu?this.disableAnimations(m,_=void 0===_||!!_):this.engine.process(this.namespaceId,m,d.slice(1),_):this.delegate.setProperty(m,d,_)}listen(m,d,_){if("@"==d.charAt(0)){const D=function Of(v){switch(v){case"body":return document.body;case"document":return document;case"window":return window;default:return v}}(m);let V=d.slice(1),J="";return"@"!=V.charAt(0)&&([V,J]=function Ih(v){const m=v.indexOf(".");return[v.substring(0,m),v.slice(m+1)]}(V)),this.engine.listen(this.namespaceId,D,V,J,we=>{this.factory.scheduleListenerCallback(we._data||-1,_,we)})}return this.delegate.listen(m,d,_)}}class um{delegate;engine;_zone;_currentId=0;_microtaskId=1;_animationCallbacksBuffer=[];_rendererCache=new Map;_cdRecurDepth=0;constructor(m,d,_){this.delegate=m,this.engine=d,this._zone=_,d.onRemovalComplete=(D,V)=>{V?.removeChild(null,D)}}createRenderer(m,d){const D=this.delegate.createRenderer(m,d);if(!m||!d?.data?.animation){const yt=this._rendererCache;let un=yt.get(D);return un||(un=new kh("",D,this.engine,()=>yt.delete(D)),yt.set(D,un)),un}const V=d.id,J=d.id+"-"+this._currentId;this._currentId++,this.engine.register(J,m);const we=yt=>{Array.isArray(yt)?yt.forEach(we):this.engine.registerTrigger(V,J,m,yt.name,yt)};return d.data.animation.forEach(we),new os(this,J,D,this.engine)}begin(){this._cdRecurDepth++,this.delegate.begin&&this.delegate.begin()}_scheduleCountTask(){queueMicrotask(()=>{this._microtaskId++})}scheduleListenerCallback(m,d,_){if(m>=0&&md(_));const D=this._animationCallbacksBuffer;0==D.length&&queueMicrotask(()=>{this._zone.run(()=>{D.forEach(V=>{const[J,we]=V;J(we)}),this._animationCallbacksBuffer=[]})}),D.push([d,_])}end(){this._cdRecurDepth--,0==this._cdRecurDepth&&this._zone.runOutsideAngular(()=>{this._scheduleCountTask(),this.engine.flush(this._microtaskId)}),this.delegate.end&&this.delegate.end()}whenRenderingDone(){return this.engine.whenRenderingDone()}}const vu=[{provide:je,useFactory:function Oh(){return new qs}},{provide:ic,useClass:(()=>{class v extends ic{constructor(d,_,D){super(d,_,D)}ngOnDestroy(){this.flush()}static \u0275fac=function(_){return new(_||v)(c.KVO(at.qQ),c.KVO(Ae),c.KVO(je))};static \u0275prov=c.jDH({token:v,factory:v.\u0275fac})}return v})()},{provide:c._9s,useFactory:function Nf(v,m,d){return new um(v,m,d)},deps:[i.B7,ic,c.SKi]}],Rh=[{provide:Ae,useFactory:()=>new Rd},{provide:c.bc$,useValue:"BrowserAnimations"},...vu];var qu=r(6381),yu=r(909),Ug=r(3569),tl=r(8447),Pf=r(850);const bu=new S.c(Pf.l);var wu=r(7509),Dc=r(1787),Os=r(7947),Nh=r(1642),Nd=r(1126),Ff=r(7225),Ju=r(5351);const ed={connector:()=>new tl.B};function Lh(v,m=ed){const{connector:d}=m;return(0,Ju.N)((_,D)=>{const V=d();(0,Ff.Tg)(v(function hm(v){return new S.c(m=>v.subscribe(m))}(V))).subscribe(D),D.add(_.subscribe(V))})}var Eu=r(2040);const sc="Service workers are disabled or not supported by this browser";class xu{serviceWorker;worker;registration;events;constructor(m){if(this.serviceWorker=m,m){const _=(0,yu.R)(m,"controllerchange").pipe((0,Os.T)(()=>m.controller)),D=(0,qu.v)(()=>(0,O.of)(m.controller)),V=(0,Ug.x)(D,_);this.worker=V.pipe((0,dt.p)(un=>!!un)),this.registration=this.worker.pipe((0,se.n)(()=>m.getRegistration()));const yt=(0,yu.R)(m,"message").pipe((0,Os.T)(un=>un.data)).pipe((0,dt.p)(un=>un&&un.type)).pipe(function Bc(v){return v?m=>Lh(v)(m):m=>function td(v,m){const d=(0,Nd.T)(v)?v:()=>v;return(0,Nd.T)(m)?Lh(m,{connector:d}):_=>new Nh.G(_,d)}(new tl.B)(m)}());yt.connect(),this.events=yt}else this.worker=this.events=this.registration=function nd(v){return(0,qu.v)(()=>(0,T.$)(new Error(v)))}(sc)}postMessage(m,d){return this.worker.pipe((0,M.s)(1),(0,Eu.M)(_=>{_.postMessage({action:m,...d})})).toPromise().then(()=>{})}postMessageWithOperation(m,d,_){const D=this.waitForOperationCompleted(_),V=this.postMessage(m,d);return Promise.all([V,D]).then(([,J])=>J)}generateNonce(){return Math.round(1e7*Math.random())}eventsOfType(m){let d;return d="string"==typeof m?_=>_.type===m:_=>m.includes(_.type),this.events.pipe((0,dt.p)(d))}nextEventOfType(m){return this.eventsOfType(m).pipe((0,M.s)(1))}waitForOperationCompleted(m){return this.eventsOfType("OPERATION_COMPLETED").pipe((0,dt.p)(d=>d.nonce===m),(0,M.s)(1),(0,Os.T)(d=>{if(void 0!==d.result)return d.result;throw new Error(d.error)})).toPromise()}get isEnabled(){return!!this.serviceWorker}}let Bf=(()=>{class v{sw;messages;notificationClicks;subscription;get isEnabled(){return this.sw.isEnabled}pushManager=null;subscriptionChanges=new tl.B;constructor(d){if(this.sw=d,!d.isEnabled)return this.messages=bu,this.notificationClicks=bu,void(this.subscription=bu);this.messages=this.sw.eventsOfType("PUSH").pipe((0,Os.T)(D=>D.data)),this.notificationClicks=this.sw.eventsOfType("NOTIFICATION_CLICK").pipe((0,Os.T)(D=>D.data)),this.pushManager=this.sw.registration.pipe((0,Os.T)(D=>D.pushManager));const _=this.pushManager.pipe((0,se.n)(D=>D.getSubscription()));this.subscription=(0,wu.h)(_,this.subscriptionChanges)}requestSubscription(d){if(!this.sw.isEnabled||null===this.pushManager)return Promise.reject(new Error(sc));const _={userVisibleOnly:!0};let D=this.decodeBase64(d.serverPublicKey.replace(/_/g,"/").replace(/-/g,"+")),V=new Uint8Array(new ArrayBuffer(D.length));for(let J=0;JJ.subscribe(_)),(0,M.s)(1)).toPromise().then(J=>(this.subscriptionChanges.next(J),J))}unsubscribe(){return this.sw.isEnabled?this.subscription.pipe((0,M.s)(1),(0,se.n)(_=>{if(null===_)throw new Error("Not subscribed to push notifications.");return _.unsubscribe().then(D=>{if(!D)throw new Error("Unsubscribe failed!");this.subscriptionChanges.next(null)})})).toPromise():Promise.reject(new Error(sc))}decodeBase64(d){return atob(d)}static \u0275fac=function(_){return new(_||v)(c.KVO(xu))};static \u0275prov=c.jDH({token:v,factory:v.\u0275fac})}return v})(),Ld=(()=>{class v{sw;versionUpdates;unrecoverable;get isEnabled(){return this.sw.isEnabled}constructor(d){if(this.sw=d,!d.isEnabled)return this.versionUpdates=bu,void(this.unrecoverable=bu);this.versionUpdates=this.sw.eventsOfType(["VERSION_DETECTED","VERSION_INSTALLATION_FAILED","VERSION_READY","NO_NEW_VERSION_DETECTED"]),this.unrecoverable=this.sw.eventsOfType("UNRECOVERABLE_STATE")}checkForUpdate(){if(!this.sw.isEnabled)return Promise.reject(new Error(sc));const d=this.sw.generateNonce();return this.sw.postMessageWithOperation("CHECK_FOR_UPDATES",{nonce:d},d)}activateUpdate(){if(!this.sw.isEnabled)return Promise.reject(new Error(sc));const d=this.sw.generateNonce();return this.sw.postMessageWithOperation("ACTIVATE_UPDATE",{nonce:d},d)}static \u0275fac=function(_){return new(_||v)(c.KVO(xu))};static \u0275prov=c.jDH({token:v,factory:v.\u0275fac})}return v})();const Ph=new c.nKC("");function Fh(v,m,d,_){return()=>{if(!(0,at.UE)(_)||!("serviceWorker"in navigator)||!1===d.enabled)return;const D=v.get(c.SKi),V=v.get(c.o8S);let J;if(D.runOutsideAngular(()=>{const we=navigator.serviceWorker,Xe=()=>we.controller?.postMessage({action:"INITIALIZE"});we.addEventListener("controllerchange",Xe),V.onDestroy(()=>{we.removeEventListener("controllerchange",Xe)})}),"function"==typeof d.registrationStrategy)J=d.registrationStrategy();else{const[we,...Xe]=(d.registrationStrategy||"registerWhenStable:30000").split(":");switch(we){case"registerImmediately":J=(0,O.of)(null);break;case"registerWithDelay":J=Uf(+Xe[0]||0);break;case"registerWhenStable":const yt=(0,Dc.H)(v.get(c.o8S).whenStable());J=Xe[0]?(0,wu.h)(yt,Uf(+Xe[0])):yt;break;default:throw new Error(`Unknown ServiceWorker registration strategy: ${d.registrationStrategy}`)}}D.runOutsideAngular(()=>J.pipe((0,M.s)(1)).subscribe(()=>navigator.serviceWorker.register(m,{scope:d.scope}).catch(we=>console.error("Service worker registration failed with:",we))))}}function Uf(v){return(0,O.of)(null).pipe((0,pe.c)(v))}function $f(v,m){return new xu((0,at.UE)(m)&&!1!==v.enabled?navigator.serviceWorker:void 0)}class va{enabled;scope;registrationStrategy}var Uc=r(2653),jg=r(5903),fm=r(7178),ya=r(8249),ac=r(6627),Uh=r(6564);function id(v){return v&&v.constructor&&"function"==typeof v.constructor.isBuffer&&v.constructor.isBuffer(v)}function jf(v){return v}function $h(v,m){const d=(m=m||{}).delimiter||".",_=m.maxDepth,D=m.transformKey||jf,V={};return function J(we,Xe,yt){yt=yt||1,Object.keys(we).forEach(function(un){const _n=we[un],gr=m.safe&&Array.isArray(_n),er=Object.prototype.toString.call(_n),fr=id(_n),ti="[object Object]"===er||"[object Array]"===er,Ai=Xe?Xe+d+D(un):D(un);if(!gr&&!fr&&ti&&Object.keys(_n).length&&(!m.maxDepth||yt<_))return J(_n,Ai,yt+1);V[Ai]=_n})}(v),V}function Pd(v,m){const d=(m=m||{}).delimiter||".",_=m.overwrite||!1,D=m.transformKey||jf,V={};if(id(v)||"[object Object]"!==Object.prototype.toString.call(v))return v;function we(un){const _n=Number(un);return isNaN(_n)||-1!==un.indexOf(".")||m.object?un:_n}return v=Object.keys(v).reduce(function(un,_n){const gr=Object.prototype.toString.call(v[_n]);return"[object Object]"!==gr&&"[object Array]"!==gr||function yt(un){const _n=Object.prototype.toString.call(un);return!un||("[object Array]"===_n?!un.length:"[object Object]"===_n?!Object.keys(un).length:void 0)}(v[_n])?(un[_n]=v[_n],un):function Xe(un,_n,gr){return Object.keys(gr).reduce(function(er,fr){return er[un+d+fr]=gr[fr],er},_n)}(_n,un,$h(v[_n],m))},{}),Object.keys(v).forEach(function(un){const _n=un.split(d).map(D);let gr=we(_n.shift()),er=we(_n[0]),fr=V;for(;void 0!==er;){if("__proto__"===gr)return;const ti=Object.prototype.toString.call(fr[gr]),Ai="[object Object]"===ti||"[object Array]"===ti;if(!_&&!Ai&&typeof fr[gr]<"u")return;(_&&!Ai||!_&&null==fr[gr])&&(fr[gr]="number"!=typeof er||m.object?{}:[]),fr=fr[gr],_n.length>0&&(gr=we(_n.shift()),er=we(_n[0]))}fr[gr]=Pd(v[un],m)}),V}class Vf{translations;constructor(m){this.translations=m}getTranslation(m){return(0,O.of)(this.translations.get(m)||{})}}const Hf=new c.nKC("TRANSLOCO_LOADER");function jh(v,m){return v&&(Object.prototype.hasOwnProperty.call(v,m)?v[m]:m.split(".").reduce((d,_)=>d?.[_],v))}function Wf(v){return v?Array.isArray(v)?v.length:od(v)?Object.keys(v).length:v?v.length:0:0}function lc(v){return"string"==typeof v}function od(v){return!!v&&"object"==typeof v&&!Array.isArray(v)}function Cu(v){return null==v}function Hh(v){return!1===Cu(v)}function Wh(v){return v&&"string"==typeof v.scope}function zh(v){return $h(v,{safe:!0})}const $c=new c.nKC("TRANSLOCO_CONFIG",{providedIn:"root",factory:()=>jc}),jc={defaultLang:"en",reRenderOnLangChange:!1,prodMode:!1,failedRetries:2,fallbackLang:[],availableLangs:[],missingHandler:{logMissingKey:!0,useFallbackTranslation:!1,allowEmpty:!1},flatten:{aot:!1},interpolation:["{{","}}"]};function Yf(v={}){return{...jc,...v,missingHandler:{...jc.missingHandler,...v.missingHandler},flatten:{...jc.flatten,...v.flatten}}}const Kh=new c.nKC("TRANSLOCO_TRANSPILER");let Qf=(()=>{class v{interpolationMatcher;constructor(d){this.interpolationMatcher=function Gh(v){const[m,d]=v.interpolation;return new RegExp(`${m}(.*?)${d}`,"g")}(d??jc)}transpile(d,_={},D,V){return lc(d)?d.replace(this.interpolationMatcher,(J,we)=>(we=we.trim(),Hh(_[we])?_[we]:Hh(D[we])?this.transpile(D[we],_,D,V):"")):(_&&(od(d)?d=this.handleObject(d,_,D,V):Array.isArray(d)&&(d=this.handleArray(d,_,D,V))),d)}handleObject(d,_={},D,V){let J=d;return Object.keys(_).forEach(we=>{const Xe=jh(J,we),yt=jh(_,we),un=this.transpile(Xe,yt,D,V);J=function pm(v,m,d){v={...v};const _=m.split("."),D=_.length-1;return _.reduce((V,J,we)=>(V[J]=we===D?d:Array.isArray(V[J])?V[J].slice():{...V[J]},V&&V[J]),v),v}(J,we,un)}),J}handleArray(d,_={},D,V){return d.map(J=>this.transpile(J,_,D,V))}static \u0275fac=function(_){return new(_||v)(c.KVO($c,8))};static \u0275prov=c.jDH({token:v,factory:v.\u0275fac})}return v})();const nl=new c.nKC("TRANSLOCO_MISSING_HANDLER");let Du=(()=>{class v{handle(d,_){return _.missingHandler.logMissingKey&&!_.prodMode&&console.warn(`%c Missing translation for '${d}'`,"font-size: 12px; color: red"),d}static \u0275fac=function(_){return new(_||v)};static \u0275prov=c.jDH({token:v,factory:v.\u0275fac})}return v})();const Yh=new c.nKC("TRANSLOCO_INTERCEPTOR");let sd=(()=>{class v{preSaveTranslation(d){return d}preSaveTranslationKey(d,_){return _}static \u0275fac=function(_){return new(_||v)};static \u0275prov=c.jDH({token:v,factory:v.\u0275fac})}return v})();const b=new c.nKC("TRANSLOCO_FALLBACK_STRATEGY");let nn,E=(()=>{class v{userConfig;constructor(d){this.userConfig=d}getNextLangs(){const d=this.userConfig.fallbackLang;if(!d)throw new Error("When using the default fallback, a fallback language must be provided in the config!");return Array.isArray(d)?d:[d]}static \u0275fac=function(_){return new(_||v)(c.KVO($c))};static \u0275prov=c.jDH({token:v,factory:v.\u0275fac})}return v})();function A(v){if(!v)return"";const m=v.split("/");return m.pop(),m.join("/")}function j(v){return v?v.split("/").pop():""}function wt(v){return{scope:A(v)||null,langName:j(v)}}function Pt(v){const{path:m,inlineLoader:d,mainLoader:_,data:D}=v;if(d){if(!1===function Kf(v){return"function"==typeof v}(d[m]))throw`You're using an inline loader but didn't provide a loader for ${m}`;return d[m]().then(J=>J.default?J.default:J)}return _.getTranslation(m,D)}let Yt=(()=>{class v{loader;parser;missingHandler;interceptor;fallbackStrategy;langChanges$;subscription=null;translations=new Map;cache=new Map;firstFallbackLang;defaultLang="";availableLangs=[];isResolvedMissingOnce=!1;lang;failedLangs=new Set;events=new tl.B;events$=this.events.asObservable();config;constructor(d,_,D,V,J,we){this.loader=d,this.parser=_,this.missingHandler=D,this.interceptor=V,this.fallbackStrategy=we,this.loader||(this.loader=new Vf(this.translations)),nn=this,this.config=JSON.parse(JSON.stringify(J)),this.setAvailableLangs(this.config.availableLangs||[]),this.setFallbackLangForMissingTranslation(this.config),this.setDefaultLang(this.config.defaultLang),this.lang=new Oe.t(this.getDefaultLang()),this.langChanges$=this.lang.asObservable(),this.subscription=this.events$.subscribe(Xe=>{"translationLoadSuccess"===Xe.type&&Xe.wasFailure&&this.setActiveLang(Xe.payload.langName)})}getDefaultLang(){return this.defaultLang}setDefaultLang(d){this.defaultLang=d}getActiveLang(){return this.lang.getValue()}setActiveLang(d){return this.parser.onLangChanged?.(d),this.lang.next(d),this.events.next({type:"langChanged",payload:wt(d)}),this}setAvailableLangs(d){this.availableLangs=d}getAvailableLangs(){return this.availableLangs}load(d,_={}){const D=this.cache.get(d);if(D)return D;let V;const J=this._isLangScoped(d);let we;J&&(we=A(d));const Xe={path:d,mainLoader:this.loader,inlineLoader:_.inlineLoader,data:J?{scope:we}:void 0};if(this.useFallbackTranslation(d)){const un=J?`${we}/${this.firstFallbackLang}`:this.firstFallbackLang,_n=function Lt({mainLoader:v,path:m,data:d,fallbackPath:_,inlineLoader:D}){return(_?[m,_]:[m]).map(J=>{const we=Pt({path:J,mainLoader:v,inlineLoader:D,data:d});return(0,Dc.H)(we).pipe((0,Os.T)(Xe=>({translation:Xe,lang:J})))})}({...Xe,fallbackPath:un});V=(0,Uc.p)(_n)}else{const un=Pt(Xe);V=(0,Dc.H)(un)}const yt=V.pipe((0,jg.L)(this.config.failedRetries),(0,Eu.M)(un=>{Array.isArray(un)?un.forEach(_n=>{this.handleSuccess(_n.lang,_n.translation),_n.lang!==d&&this.cache.set(_n.lang,(0,O.of)({}))}):this.handleSuccess(d,un)}),(0,fm.W)(un=>(this.config.prodMode||console.error(`Error while trying to load "${d}"`,un),this.handleFailure(d,_))),(0,ya.t)(1));return this.cache.set(d,yt),yt}translate(d,_={},D=this.getActiveLang()){if(!d)return d;const{scope:V,resolveLang:J}=this.resolveLangAndScope(D);if(Array.isArray(d))return d.map(yt=>this.translate(V?`${V}.${yt}`:yt,_,J));d=V?`${V}.${d}`:d;const we=this.getTranslation(J),Xe=we[d];return Xe?this.parser.transpile(Xe,_,we,d):this._handleMissingKey(d,Xe,_)}selectTranslate(d,_,D,V=!1){let J;const we=(yt,un)=>this.load(yt,un).pipe((0,Os.T)(()=>V?this.translateObject(d,_,yt):this.translate(d,_,yt)));if(Cu(D))return this.langChanges$.pipe((0,se.n)(yt=>we(yt)));if(function gm(v){return Array.isArray(v)&&v.every(Wh)}(D)||Wh(D)){const yt=Array.isArray(D)?D[0]:D;D=yt.scope,J=function Qe(v,m){return function Gf(v){return v&&od(v.loader)}(v)?function Pe(v,m){return Object.keys(v).reduce((d,_)=>(d[`${m}/${_}`]=v[_],d),{})}(v.loader,m):void 0}(yt,yt.scope)}if(this.isLang(D)||this.isScopeWithLang(D))return we(D);const Xe=D;return this.langChanges$.pipe((0,se.n)(yt=>we(`${Xe}/${yt}`,{inlineLoader:J})))}isScopeWithLang(d){return this.isLang(j(d))}translateObject(d,_={},D=this.getActiveLang()){if(lc(d)||Array.isArray(d)){const{resolveLang:J,scope:we}=this.resolveLangAndScope(D);if(Array.isArray(d))return d.map(un=>this.translateObject(we?`${we}.${un}`:un,_,J));const Xe=this.getTranslation(J),yt=function Xf(v){return Pd(v)}(this.getObjectByKey(Xe,d=we?`${we}.${d}`:d));return function zf(v){return 0===Wf(v)}(yt)?this.translate(d,_,D):this.parser.transpile(yt,_,Xe,d)}const V=[];for(const[J,we]of this.getEntries(d))V.push(this.translateObject(J,we,D));return V}selectTranslateObject(d,_,D){if(lc(d)||Array.isArray(d))return this.selectTranslate(d,_,D,!0);const[[V,J],...we]=this.getEntries(d);return this.selectTranslateObject(V,J,D).pipe((0,Os.T)(Xe=>{const yt=[Xe];for(const[un,_n]of we)yt.push(this.translateObject(un,_n,D));return yt}))}getTranslation(d){if(d){if(this.isLang(d))return this.translations.get(d)||{};{const{scope:_,resolveLang:D}=this.resolveLangAndScope(d),V=this.translations.get(D)||{};return this.getObjectByKey(V,_)}}return this.translations}selectTranslation(d){let _=this.langChanges$;if(d){const D=j(d)!==d;_=this.isLang(d)||D?(0,O.of)(d):this.langChanges$.pipe((0,Os.T)(V=>`${d}/${V}`))}return _.pipe((0,se.n)(D=>this.load(D).pipe((0,Os.T)(()=>this.getTranslation(D)))))}setTranslation(d,_=this.getActiveLang(),D={}){const J={merge:!0,emitChange:!0,...D},we=A(_);let Xe=d;if(we){const er=this.getMappedScope(we);Xe=zh({[er]:d})}const yt=we?j(_):_,un={...J.merge&&this.getTranslation(yt),...Xe},_n=this.config.flatten.aot?un:zh(un),gr=this.interceptor.preSaveTranslation(_n,yt);this.translations.set(yt,gr),J.emitChange&&this.setActiveLang(this.getActiveLang())}setTranslationKey(d,_,D=this.getActiveLang(),V={}){const J=this.interceptor.preSaveTranslationKey(d,_,D);this.setTranslation({[d]:J},D,{...V,merge:!0})}setFallbackLangForMissingTranslation({fallbackLang:d}){const _=Array.isArray(d)?d[0]:d;d&&this.useFallbackTranslation(_)&&(this.firstFallbackLang=_)}_handleMissingKey(d,_,D){if(this.config.missingHandler.allowEmpty&&""===_)return"";if(!this.isResolvedMissingOnce&&this.useFallbackTranslation()){this.isResolvedMissingOnce=!0;const V=this.translate(d,D,this.firstFallbackLang);return this.isResolvedMissingOnce=!1,V}return this.missingHandler.handle(d,this.getMissingHandlerData(),D)}_isLangScoped(d){return-1===this.getAvailableLangsIds().indexOf(d)}isLang(d){return-1!==this.getAvailableLangsIds().indexOf(d)}_loadDependencies(d,_){const D=j(d);return this._isLangScoped(d)&&!this.isLoadedTranslation(D)?(0,ac.z)([this.load(D),this.load(d,{inlineLoader:_})]):this.load(d,{inlineLoader:_})}_completeScopeWithLang(d){return this._isLangScoped(d)&&!this.isLang(j(d))?`${d}/${this.getActiveLang()}`:d}_setScopeAlias(d,_){this.config.scopeMapping||(this.config.scopeMapping={}),this.config.scopeMapping[d]=_}ngOnDestroy(){this.subscription&&(this.subscription.unsubscribe(),this.subscription=null),this.cache.clear()}isLoadedTranslation(d){return Wf(this.getTranslation(d))}getAvailableLangsIds(){return lc(this.getAvailableLangs()[0])?this.getAvailableLangs():this.getAvailableLangs().map(_=>_.id)}getMissingHandlerData(){return{...this.config,activeLang:this.getActiveLang(),availableLangs:this.availableLangs,defaultLang:this.defaultLang}}useFallbackTranslation(d){return this.config.missingHandler.useFallbackTranslation&&d!==this.firstFallbackLang}handleSuccess(d,_){this.setTranslation(_,d,{emitChange:!1}),this.events.next({wasFailure:!!this.failedLangs.size,type:"translationLoadSuccess",payload:wt(d)}),this.failedLangs.forEach(D=>this.cache.delete(D)),this.failedLangs.clear()}handleFailure(d,_){Cu(_.failedCounter)&&(_.failedCounter=0,_.fallbackLangs||(_.fallbackLangs=this.fallbackStrategy.getNextLangs(d)));const D=d.split("/"),J=_.fallbackLangs[_.failedCounter];if(this.failedLangs.add(d),this.cache.has(J))return this.handleSuccess(J,this.getTranslation(J)),Uh.w;if(!J||J===D[D.length-1]){let yt="Unable to load translation and all the fallback languages";throw D.length>1&&(yt+=", did you misspelled the scope name?"),new Error(yt)}let Xe=J;return D.length>1&&(D[D.length-1]=J,Xe=D.join("/")),_.failedCounter++,this.events.next({type:"translationLoadFailure",payload:wt(d)}),this.load(Xe,_)}getMappedScope(d){const{scopeMapping:_={}}=this.config;return _[d]||function Bd(v){return v.replace(/(?:^\w|[A-Z]|\b\w)/g,(m,d)=>0==d?m.toLowerCase():m.toUpperCase()).replace(/\s+|_|-|\//g,"")}(d)}resolveLangAndScope(d){let D,_=d;if(this._isLangScoped(d)){const V=j(d),J=this.isLang(V);_=J?V:this.getActiveLang(),D=this.getMappedScope(J?A(d):d)}return{scope:D,resolveLang:_}}getObjectByKey(d,_){const D={},V=`${_}.`;for(const J in d)J.startsWith(V)&&(D[J.replace(V,"")]=d[J]);return D}getEntries(d){return d instanceof Map?d.entries():Object.entries(d)}static \u0275fac=function(_){return new(_||v)(c.KVO(Hf,8),c.KVO(Kh),c.KVO(nl),c.KVO(Yh),c.KVO($c),c.KVO(b))};static \u0275prov=c.jDH({token:v,factory:v.\u0275fac,providedIn:"root"})}return v})();function hr(v){return(0,c.EmA)([{provide:Kh,useClass:v,deps:[$c]}])}function Yr(v){return(0,c.EmA)([{provide:b,useClass:v,deps:[$c]}])}function mi(v){return(0,c.EmA)([{provide:nl,useClass:v}])}function yr(v){return(0,c.EmA)([{provide:Yh,useClass:v}])}new c.nKC("TRANSLOCO_LANG"),new c.nKC("TRANSLOCO_LOADING_TEMPLATE"),new c.nKC("TRANSLOCO_SCOPE"),new c.nKC("TRANSLOCO_TEST_LANGS - Available testing languages"),new c.nKC("TRANSLOCO_TEST_OPTIONS - Testing options");var Xa=r(7838);let wa=(()=>{class v{constructor(){this._httpClient=(0,c.WQX)(re.Qq),this._navigation=new Xa.m(1)}get navigation$(){return this._navigation.asObservable()}get(){return this._httpClient.get("api/navigation").pipe((0,Eu.M)(d=>{this._navigation.next(d)}))}static{this.\u0275fac=function(_){return new(_||v)}}static{this.\u0275prov=c.jDH({token:v,factory:v.\u0275fac,providedIn:"root"})}}return v})(),Vc=(()=>{class v{constructor(d){this._httpClient=d,this._chat=new Oe.t(null),this._chats=new Oe.t(null)}get chat$(){return this._chat.asObservable()}get chats$(){return this._chats.asObservable()}getChats(){return this._httpClient.get("api/apps/chat/chats").pipe((0,Eu.M)(d=>{this._chats.next(d)}))}getChatById(d){return this._httpClient.get("api/apps/chat/chat",{params:{id:d}}).pipe((0,Os.T)(_=>(this._chat.next(_),_)),(0,se.n)(_=>_?(0,O.of)(_):(0,T.$)("Could not found chat with id of "+d+"!")))}static{this.\u0275fac=function(_){return new(_||v)(c.KVO(re.Qq))}}static{this.\u0275prov=c.jDH({token:v,factory:v.\u0275fac,providedIn:"root"})}}return v})();const cc=new class Po{constructor(m){this.version=m,this.full=m,this.major=m.split(".")[0],this.minor=m.split(".")[1],this.patch=m.split(".").slice(2).join(".")}}("0.0.12").full;var ea=r(5424),Zo=r(3022),Hc=r(2322);function jd(v,m){if(1&v&&c.nrm(0,"mat-progress-bar",0),2&v){const d=c.XpG();c.Y8G("mode",d.mode)("value",d.progress)}}let Wc=(()=>{class v{constructor(){this._angorLoadingService=(0,c.WQX)(xe),this.autoMode=!0,this.progress=0,this.show=!1,this._unsubscribeAll=new tl.B}ngOnChanges(d){"autoMode"in d&&this._angorLoadingService.setAutoMode((0,Zo.he)(d.autoMode.currentValue))}ngOnInit(){this._angorLoadingService.mode$.pipe((0,ea.Q)(this._unsubscribeAll)).subscribe(d=>{this.mode=d}),this._angorLoadingService.progress$.pipe((0,ea.Q)(this._unsubscribeAll)).subscribe(d=>{this.progress=d}),this._angorLoadingService.show$.pipe((0,ea.Q)(this._unsubscribeAll)).subscribe(d=>{this.show=d})}ngOnDestroy(){this._unsubscribeAll.next(null),this._unsubscribeAll.complete()}static{this.\u0275fac=function(_){return new(_||v)}}static{this.\u0275cmp=c.VBU({type:v,selectors:[["angor-loading-bar"]],inputs:{autoMode:"autoMode"},exportAs:["angorLoadingBar"],features:[c.OA$],decls:1,vars:1,consts:[[3,"mode","value"]],template:function(_,D){1&_&&c.DNE(0,jd,1,2,"mat-progress-bar",0),2&_&&c.vxM(D.show?0:-1)},dependencies:[Hc.PO,Hc.HM],styles:["angor-loading-bar{position:fixed;top:0;z-index:999;width:100%;height:6px}\n"],encapsulation:2})}}return v})();function Qh(v,m){1&v&&c.nrm(0,"router-outlet")}let Zf=(()=>{class v{constructor(){this._unsubscribeAll=new tl.B}ngOnDestroy(){this._unsubscribeAll.next(null),this._unsubscribeAll.complete()}static{this.\u0275fac=function(_){return new(_||v)}}static{this.\u0275cmp=c.VBU({type:v,selectors:[["empty-layout"]],decls:4,vars:1,consts:[[1,"flex","w-full","flex-auto","flex-col"],[1,"flex","flex-auto","flex-col"]],template:function(_,D){1&_&&(c.nrm(0,"angor-loading-bar"),c.j41(1,"div",0)(2,"div",1),c.DNE(3,Qh,1,0,"router-outlet"),c.k0s()()),2&_&&(c.R7$(3),c.vxM(3))},dependencies:[Wc,a.n3],encapsulation:2})}}return v})();var _l=r(9471),il=r(3904),zc=r(7712);function vm(v,m){1&v&&c.nrm(0,"mat-icon",3)}let Ac=(()=>{class v{constructor(){this._document=(0,c.WQX)(at.qQ)}toggleFullscreen(){this._document.fullscreenEnabled?this._document.fullscreenElement?this._document.exitFullscreen():this._document.documentElement.requestFullscreen().catch(()=>{console.error("Entering fullscreen mode failed.")}):console.log("Fullscreen is not available in this browser.")}static{this.\u0275fac=function(_){return new(_||v)}}static{this.\u0275cmp=c.VBU({type:v,selectors:[["angor-fullscreen"]],inputs:{iconTpl:"iconTpl",tooltip:"tooltip"},exportAs:["angorFullscreen"],decls:4,vars:2,consts:[["defaultIconTpl",""],["mat-icon-button","",3,"click","matTooltip"],[3,"ngTemplateOutlet"],["svgIcon","heroicons_outline:arrows-pointing-out"]],template:function(_,D){if(1&_){const V=c.RV6();c.j41(0,"button",1),c.bIt("click",function(){return c.eBV(V),c.Njj(D.toggleFullscreen())}),c.eu8(1,2),c.k0s(),c.DNE(2,vm,1,0,"ng-template",null,0,c.C5r)}if(2&_){const V=c.sdS(3);c.Y8G("matTooltip",D.tooltip||"Toggle Fullscreen"),c.R7$(),c.Y8G("ngTemplateOutlet",D.iconTpl||V)}},dependencies:[_l.Hl,_l.iY,zc.uc,zc.oV,at.T3,il.m_,il.An],encapsulation:2,changeDetection:0})}}return v})();var Zh=r(3871),ym=r(6192),qh=r(3125);let qf=(()=>{class v{constructor(d){this.relayService=d,this.notificationSubject=new Oe.t([]),this.notificationCount=new Oe.t(0),this.lastNotificationTimestamp=null,this.initializeNotificationData()}initializeNotificationData(){this.notificationCount.next(this.loadCountFromLocalStorage()),this.lastNotificationTimestamp=this.loadTimestampFromLocalStorage()}loadCountFromLocalStorage(){const d=localStorage.getItem("notificationCount");return d?parseInt(d,10):0}loadTimestampFromLocalStorage(){const d=localStorage.getItem("lastNotificationTimestamp");return d?parseInt(d,10):null}saveNotificationData(d,_){localStorage.setItem("notificationCount",d.toString()),localStorage.setItem("lastNotificationTimestamp",_.toString())}getNotificationObservable(){return this.notificationSubject.asObservable()}getNotificationCount(){return this.notificationCount.asObservable()}loadFilterPreferences(){const d=localStorage.getItem("notificationSettings");return d?JSON.parse(d):[1,3,4,7,9735]}subscribeToNotifications(d){var _=this;return(0,w.A)(function*(){yield _.relayService.ensureConnectedRelays();const D=_.relayService.getPool(),V=_.relayService.getConnectedRelays();if(0===V.length)throw new Error("No connected relays");const J=_.loadTimestampFromLocalStorage(),we=_.loadFilterPreferences();0===we.length&&we.push(1,3,4,7,9735);const Xe={kinds:we,"#p":[d],limit:50,since:J||void 0};return new Promise(yt=>{D.subscribeMany(V,[Xe],{onevent:_n=>_.handleNotificationEvent(_n,d),oneose(){yt()}})})})()}handleNotificationEvent(d,_){if(this.isNotificationEvent(d,_)){const V=new Date(1e3*d.created_at);let J="",we="",Xe="";switch(d.kind){case 1:J="Mention",we="Mentioned you in an event.",Xe="heroicons_outline:at-symbol";break;case 4:J="Private Message",we="Sent a private message.",Xe="heroicons_outline:envelope-open";break;case 9735:J="Zap",we="Received a zap event.",Xe="feather:zap";break;case 3:J="New Follower",we="You have a new follower.",Xe="heroicons_outline:user-plus";break;case 7:J="New Like",we="You have a new Like.",Xe="heroicons_outline:hand-thumb-up";break;default:J="Notification",Xe="heroicons_outline:bell"}const _n=[{id:d.id,icon:Xe,title:J,description:we,time:V,kind:d.kind,read:!1},...this.notificationSubject.value].slice(0,50);this.notificationSubject.next(_n),this.incrementNotificationCount(d.created_at)}}incrementNotificationCount(d){const _=this.notificationCount.value+1;this.notificationCount.next(_),this.saveNotificationData(_,d)}markAllAsRead(){const d=this.notificationSubject.value.map(D=>({...D,read:!0}));this.notificationSubject.next(d),this.notificationCount.next(0);const _=Math.floor(Date.now()/1e3);this.saveNotificationData(0,_)}isNotificationEvent(d,_){return d.tags.some(D=>"p"===D[0]&&D[1]===_)}static{this.\u0275fac=function(_){return new(_||v)(c.KVO(qh.b))}}static{this.\u0275prov=c.jDH({token:v,factory:v.\u0275fac,providedIn:"root"})}}return v})();var Au=r(9666),Vd=r(8078);const Jh=["notificationsOrigin"],La=["notificationsPanel"],sy=v=>({unread:v}),Es=(v,m)=>({"bg-gray-400 dark:bg-gray-500 sm:opacity-0 sm:group-hover:opacity-100":v,"bg-primary":m});function ay(v,m){if(1&v&&(c.j41(0,"span",4)(1,"span",6),c.EFF(2),c.k0s()()),2&v){const d=c.XpG();c.R7$(2),c.SpI(" ",d.unreadCount," ")}}function ly(v,m){1&v&&c.eu8(0)}function bm(v,m){if(1&v&&(c.j41(0,"a",23),c.DNE(1,ly,1,0,"ng-container",25),c.k0s()),2&v){const d=c.XpG(2).$implicit,_=c.sdS(9);c.Y8G("href",d.link,c.B4B),c.R7$(),c.Y8G("ngTemplateOutlet",_)}}function Vg(v,m){1&v&&c.eu8(0)}function Hg(v,m){if(1&v&&(c.j41(0,"a",24),c.DNE(1,Vg,1,0,"ng-container",25),c.k0s()),2&v){const d=c.XpG(2).$implicit,_=c.sdS(9);c.Y8G("routerLink",d.link),c.R7$(),c.Y8G("ngTemplateOutlet",_)}}function cy(v,m){if(1&v&&c.DNE(0,bm,2,2,"a",23)(1,Hg,2,2,"a",24),2&v){const d=c.XpG().$implicit;c.vxM(d.useRouter?-1:0),c.R7$(),c.vxM(d.useRouter?1:-1)}}function Tw(v,m){1&v&&c.eu8(0)}function Wg(v,m){if(1&v&&(c.j41(0,"div",17),c.DNE(1,Tw,1,0,"ng-container",25),c.k0s()),2&v){c.XpG();const d=c.sdS(9);c.R7$(),c.Y8G("ngTemplateOutlet",d)}}function uy(v,m){if(1&v&&(c.j41(0,"div",26),c.nrm(1,"mat-icon",32),c.k0s()),2&v){const d=c.XpG(2).$implicit;c.R7$(),c.Y8G("svgIcon",d.icon)}}function Jf(v,m){if(1&v&&c.nrm(0,"img",27),2&v){const d=c.XpG(2).$implicit;c.Y8G("src",d.image,c.B4B)("alt","Notification image")}}function wm(v,m){if(1&v&&c.nrm(0,"div",29),2&v){const d=c.XpG(2).$implicit;c.Y8G("innerHTML",d.title,c.npT)}}function Em(v,m){if(1&v&&c.nrm(0,"div",30),2&v){const d=c.XpG(2).$implicit;c.Y8G("innerHTML",d.description,c.npT)}}function Hd(v,m){if(1&v&&(c.DNE(0,uy,2,1,"div",26)(1,Jf,1,2,"img",27),c.j41(2,"div",28),c.DNE(3,wm,1,1,"div",29)(4,Em,1,1,"div",30),c.j41(5,"div",31),c.EFF(6),c.nI1(7,"date"),c.k0s()()),2&v){const d=c.XpG().$implicit;c.vxM(d.icon&&!d.image?0:-1),c.R7$(),c.vxM(d.image?1:-1),c.R7$(2),c.vxM(d.title?3:-1),c.R7$(),c.vxM(d.description?4:-1),c.R7$(2),c.SpI(" ",c.i5U(7,5,d.time,"MMM dd, h:mm a")," ")}}function ep(v,m){if(1&v){const d=c.RV6();c.j41(0,"div",16),c.DNE(1,cy,2,2)(2,Wg,2,1,"div",17),c.j41(3,"div",18)(4,"button",19),c.bIt("click",function(){const D=c.eBV(d).$implicit,V=c.XpG(2);return c.Njj(V.toggleRead(D))}),c.nrm(5,"span",20),c.k0s(),c.j41(6,"button",21),c.bIt("click",function(){const D=c.eBV(d).$implicit,V=c.XpG(2);return c.Njj(V.deleteNotification(D))}),c.nrm(7,"mat-icon",22),c.k0s()()(),c.DNE(8,Hd,8,8,"ng-template",null,2,c.C5r)}if(2&v){const d=m.$implicit;c.Y8G("ngClass",c.eq3(7,sy,!d.read)),c.R7$(),c.vxM(d.link?1:-1),c.R7$(),c.vxM(d.link?-1:2),c.R7$(2),c.Y8G("matTooltip",d.read?"Mark as unread":"Mark as read"),c.R7$(),c.Y8G("ngClass",c.l_i(9,Es,d.read,!d.read)),c.R7$(),c.Y8G("matTooltip","Remove"),c.R7$(),c.Y8G("svgIcon","heroicons_solid:x-mark")}}function tp(v,m){1&v&&(c.j41(0,"div",15)(1,"div",33),c.nrm(2,"mat-icon",34),c.k0s(),c.j41(3,"div",35),c.EFF(4," No notifications "),c.k0s(),c.j41(5,"div",36),c.EFF(6," When you have notifications, they will appear here. "),c.k0s()()),2&v&&(c.R7$(2),c.Y8G("svgIcon","heroicons_outline:bell"))}function Wd(v,m){if(1&v){const d=c.RV6();c.j41(0,"div",7)(1,"div",8)(2,"div",9)(3,"button",3),c.bIt("click",function(){c.eBV(d);const D=c.XpG();return c.Njj(D.closePanel())}),c.nrm(4,"mat-icon",10),c.k0s()(),c.j41(5,"div",11),c.EFF(6,"Notifications"),c.k0s(),c.j41(7,"div",12)(8,"button",13),c.bIt("click",function(){c.eBV(d);const D=c.XpG();return c.Njj(D.markAllAsRead())}),c.nrm(9,"mat-icon",10),c.k0s()()(),c.j41(10,"div",14),c.Z7z(11,ep,10,12,null,null,c.BUC().trackByFn,!0),c.DNE(13,tp,7,1,"div",15),c.k0s()()}if(2&v){const d=c.XpG();c.R7$(4),c.Y8G("svgIcon","heroicons_solid:x-mark"),c.R7$(4),c.Y8G("matTooltip","Mark all as read")("disabled",0===d.unreadCount),c.R7$(),c.Y8G("svgIcon","heroicons_solid:envelope-open"),c.R7$(2),c.Dyx(d.notifications),c.R7$(2),c.vxM(d.notifications&&d.notifications.length?-1:13)}}let np=(()=>{class v{constructor(d,_,D,V,J){this._notificationService=d,this._changeDetectorRef=_,this._overlay=D,this._viewContainerRef=V,this._signerService=J,this.notifications=[],this.unreadCount=0,this._unsubscribeAll=new tl.B}ngOnInit(){const d=this._signerService.getPublicKey();this._notificationService.subscribeToNotifications(d).then(()=>{this._notificationService.getNotificationObservable().pipe((0,ea.Q)(this._unsubscribeAll)).subscribe(_=>{this.notifications=_,this._changeDetectorRef.markForCheck()}),this._notificationService.getNotificationCount().pipe((0,ea.Q)(this._unsubscribeAll)).subscribe(_=>{this.unreadCount=_,this._changeDetectorRef.markForCheck()})})}deleteNotification(d){throw new Error("Method not implemented.")}ngOnDestroy(){this._unsubscribeAll.next(null),this._unsubscribeAll.complete()}openPanel(){!this._notificationsPanel||!this._notificationsOrigin||(this._overlayRef||this._createOverlay(),this._overlayRef.attach(new ym.VA(this._notificationsPanel,this._viewContainerRef)))}closePanel(){this._overlayRef&&this._overlayRef.detach()}markAllAsRead(){this._notificationService.markAllAsRead()}toggleRead(d){d.read=!d.read}trackByFn(d,_){return _.id}_createOverlay(){this._overlayRef=this._overlay.create({hasBackdrop:!0,backdropClass:"angor-backdrop-on-mobile",scrollStrategy:this._overlay.scrollStrategies.block(),positionStrategy:this._overlay.position().flexibleConnectedTo(this._notificationsOrigin._elementRef.nativeElement).withLockedPosition(!0).withPush(!0).withPositions([{originX:"start",originY:"bottom",overlayX:"start",overlayY:"top"},{originX:"start",originY:"top",overlayX:"start",overlayY:"bottom"}])}),this._overlayRef.backdropClick().subscribe(()=>{this._overlayRef.detach()})}static{this.\u0275fac=function(_){return new(_||v)(c.rXU(qf),c.rXU(c.gRc),c.rXU(Au.hJ),c.rXU(c.c1b),c.rXU(Vd.A))}}static{this.\u0275cmp=c.VBU({type:v,selectors:[["notifications"]],viewQuery:function(_,D){if(1&_&&(c.GBs(Jh,5),c.GBs(La,5)),2&_){let V;c.mGM(V=c.lsd())&&(D._notificationsOrigin=V.first),c.mGM(V=c.lsd())&&(D._notificationsPanel=V.first)}},exportAs:["notifications"],decls:6,vars:2,consts:[["notificationsOrigin",""],["notificationsPanel",""],["notificationContent",""],["mat-icon-button","",3,"click"],[1,"absolute","left-0","right-0","top-0","flex","h-3","items-center","justify-center"],[3,"svgIcon"],[1,"ml-4","mt-2.5","flex","h-4","min-w-4","shrink-0","items-center","justify-center","rounded-full","bg-teal-600","px-1","text-xs","font-medium","text-indigo-50"],[1,"fixed","inset-0","flex","flex-col","overflow-hidden","shadow-lg","sm:static","sm:inset-auto","sm:w-90","sm:min-w-90","sm:rounded-2xl"],[1,"flex","shrink-0","items-center","bg-primary","py-4","pl-6","pr-4","text-on-primary"],[1,"-ml-1","mr-3","sm:hidden"],[1,"text-current","icon-size-5",3,"svgIcon"],[1,"text-lg","font-medium","leading-10"],[1,"ml-auto"],["mat-icon-button","",1,"dark:text-white",3,"click","matTooltip","disabled"],[1,"bg-card","relative","flex","flex-auto","flex-col","divide-y","overflow-y-auto","sm:max-h-120"],[1,"flex","flex-auto","flex-col","items-center","justify-center","px-8","py-12","sm:justify-start"],[1,"group","flex","hover:bg-gray-50","dark:hover:bg-black","dark:hover:bg-opacity-5",3,"ngClass"],[1,"flex","flex-auto","py-5","pl-6"],[1,"relative","my-5","ml-2","mr-6","flex","flex-col"],["mat-icon-button","",1,"h-6","min-h-6","w-6",3,"click","matTooltip"],[1,"h-2","w-2","rounded-full",3,"ngClass"],["mat-icon-button","",1,"h-6","min-h-6","w-6","sm:opacity-0","sm:group-hover:opacity-100",3,"click","matTooltip"],[1,"icon-size-4",3,"svgIcon"],[1,"flex","flex-auto","cursor-pointer","py-5","pl-6",3,"href"],[1,"flex","flex-auto","cursor-pointer","py-5","pl-6",3,"routerLink"],[4,"ngTemplateOutlet"],[1,"mr-4","flex","h-8","w-8","shrink-0","items-center","justify-center","rounded-full","bg-gray-100","dark:bg-gray-700"],[1,"mr-4","h-8","w-8","shrink-0","overflow-hidden","rounded-full","object-cover","object-center",3,"src","alt"],[1,"flex","flex-auto","flex-col"],[1,"line-clamp-1","font-semibold",3,"innerHTML"],[1,"line-clamp-2",3,"innerHTML"],[1,"text-secondary","mt-2","text-sm","leading-none"],[1,"icon-size-5",3,"svgIcon"],[1,"flex","h-14","w-14","flex-0","items-center","justify-center","rounded-full","bg-primary-100","dark:bg-primary-600"],[1,"text-primary-700","dark:text-primary-50",3,"svgIcon"],[1,"mt-5","text-2xl","font-semibold","tracking-tight"],[1,"text-secondary","mt-1","w-full","max-w-60","text-center","text-md"]],template:function(_,D){if(1&_){const V=c.RV6();c.j41(0,"button",3,0),c.bIt("click",function(){return c.eBV(V),c.Njj(D.openPanel())}),c.DNE(2,ay,3,1,"span",4),c.nrm(3,"mat-icon",5),c.k0s(),c.DNE(4,Wd,14,5,"ng-template",null,1,c.C5r)}2&_&&(c.R7$(2),c.vxM(D.unreadCount>0?2:-1),c.R7$(),c.Y8G("svgIcon","heroicons_outline:bell"))},dependencies:[_l.Hl,_l.iY,il.m_,il.An,zc.uc,zc.oV,at.YU,at.T3,a.Wk,at.vh],encapsulation:2,changeDetection:0})}}return v})();var xm=r(799),Su=r(936),Cm=r(8108),Kc=r(8559),Dm=r(5710),dy=r(2944),ol=r(5919),zd=r(6520),Mw=r(593);const zg=["panel"],hy=["*"];function Kg(v,m){if(1&v){const d=c.RV6();c.j41(0,"div",1,0),c.bIt("@panelAnimation.done",function(D){c.eBV(d);const V=c.XpG();return c.Njj(V._animationDone.next(D))}),c.SdG(2),c.k0s()}if(2&v){const d=m.id,_=c.XpG();c.HbH(_._classList),c.AVh("mat-mdc-autocomplete-visible",_.showPanel)("mat-mdc-autocomplete-hidden",!_.showPanel)("mat-primary","primary"===_._color)("mat-accent","accent"===_._color)("mat-warn","warn"===_._color),c.Y8G("id",_.id)("@panelAnimation",_.isOpen?"visible":"hidden"),c.BMQ("aria-label",_.ariaLabel||null)("aria-labelledby",_._getPanelAriaLabelledby(d))}}const kw=(0,Dr.hZ)("panelAnimation",[(0,Dr.wk)("void, hidden",(0,Dr.iF)({opacity:0,transform:"scaleY(0.8)"})),(0,Dr.kY)(":enter, hidden => visible",[(0,Dr.Os)([(0,Dr.i0)("0.03s linear",(0,Dr.iF)({opacity:1})),(0,Dr.i0)("0.12s cubic-bezier(0, 0, 0.2, 1)",(0,Dr.iF)({transform:"scaleY(1)"}))])]),(0,Dr.kY)(":leave, visible => hidden",[(0,Dr.i0)("0.075s linear",(0,Dr.iF)({opacity:0}))])]);class Gg{source;option;constructor(m,d){this.source=m,this.option=d}}const Xg=new c.nKC("mat-autocomplete-default-options",{providedIn:"root",factory:function Yg(){return{autoActiveFirstOption:!1,autoSelectActiveOption:!1,hideSingleSelectionIndicator:!1,requireSelection:!1}}});let Tu=(()=>{class v{_changeDetectorRef=(0,c.WQX)(c.gRc);_elementRef=(0,c.WQX)(c.aKT);_defaults=(0,c.WQX)(Xg);_activeOptionChanges=Dm.yU.EMPTY;_animationDone=new c.bkB;_keyManager;showPanel=!1;get isOpen(){return this._isOpen&&this.showPanel}_isOpen=!1;_latestOpeningTrigger;_setColor(d){this._color=d,this._changeDetectorRef.markForCheck()}_color;template;panel;options;optionGroups;ariaLabel;ariaLabelledby;displayWith=null;autoActiveFirstOption;autoSelectActiveOption;requireSelection;panelWidth;disableRipple;optionSelected=new c.bkB;opened=new c.bkB;closed=new c.bkB;optionActivated=new c.bkB;set classList(d){this._classList=d,this._elementRef.nativeElement.className=""}_classList;get hideSingleSelectionIndicator(){return this._hideSingleSelectionIndicator}set hideSingleSelectionIndicator(d){this._hideSingleSelectionIndicator=d,this._syncParentProperties()}_hideSingleSelectionIndicator;_syncParentProperties(){if(this.options)for(const d of this.options)d._changeDetectorRef.markForCheck()}id=(0,c.WQX)(Kc.g7).getId("mat-autocomplete-");inertGroups;constructor(){const d=(0,c.WQX)(Ce.OD);this.inertGroups=d?.SAFARI||!1,this.autoActiveFirstOption=!!this._defaults.autoActiveFirstOption,this.autoSelectActiveOption=!!this._defaults.autoSelectActiveOption,this.requireSelection=!!this._defaults.requireSelection,this._hideSingleSelectionIndicator=this._defaults.hideSingleSelectionIndicator??!1}ngAfterContentInit(){this._keyManager=new Kc.Au(this.options).withWrap().skipPredicate(this._skipPredicate),this._activeOptionChanges=this._keyManager.change.subscribe(d=>{this.isOpen&&this.optionActivated.emit({source:this,option:this.options.toArray()[d]||null})}),this._setVisibility()}ngOnDestroy(){this._keyManager?.destroy(),this._activeOptionChanges.unsubscribe(),this._animationDone.complete()}_setScrollTop(d){this.panel&&(this.panel.nativeElement.scrollTop=d)}_getScrollTop(){return this.panel?this.panel.nativeElement.scrollTop:0}_setVisibility(){this.showPanel=!!this.options.length,this._changeDetectorRef.markForCheck()}_emitSelectEvent(d){const _=new Gg(this,d);this.optionSelected.emit(_)}_getPanelAriaLabelledby(d){return this.ariaLabel?null:this.ariaLabelledby?(d?d+" ":"")+this.ariaLabelledby:d}_skipPredicate(){return!1}static \u0275fac=function(_){return new(_||v)};static \u0275cmp=c.VBU({type:v,selectors:[["mat-autocomplete"]],contentQueries:function(_,D,V){if(1&_&&(c.wni(V,rn.wT,5),c.wni(V,rn.QC,5)),2&_){let J;c.mGM(J=c.lsd())&&(D.options=J),c.mGM(J=c.lsd())&&(D.optionGroups=J)}},viewQuery:function(_,D){if(1&_&&(c.GBs(c.C4Q,7),c.GBs(zg,5)),2&_){let V;c.mGM(V=c.lsd())&&(D.template=V.first),c.mGM(V=c.lsd())&&(D.panel=V.first)}},hostAttrs:[1,"mat-mdc-autocomplete"],inputs:{ariaLabel:[0,"aria-label","ariaLabel"],ariaLabelledby:[0,"aria-labelledby","ariaLabelledby"],displayWith:"displayWith",autoActiveFirstOption:[2,"autoActiveFirstOption","autoActiveFirstOption",c.L39],autoSelectActiveOption:[2,"autoSelectActiveOption","autoSelectActiveOption",c.L39],requireSelection:[2,"requireSelection","requireSelection",c.L39],panelWidth:"panelWidth",disableRipple:[2,"disableRipple","disableRipple",c.L39],classList:[0,"class","classList"],hideSingleSelectionIndicator:[2,"hideSingleSelectionIndicator","hideSingleSelectionIndicator",c.L39]},outputs:{optionSelected:"optionSelected",opened:"opened",closed:"closed",optionActivated:"optionActivated"},exportAs:["matAutocomplete"],features:[c.Jv_([{provide:rn.is,useExisting:v}]),c.GFd],ngContentSelectors:hy,decls:1,vars:0,consts:[["panel",""],["role","listbox",1,"mat-mdc-autocomplete-panel","mdc-menu-surface","mdc-menu-surface--open",3,"id"]],template:function(_,D){1&_&&(c.NAR(),c.DNE(0,Kg,3,16,"ng-template"))},styles:["div.mat-mdc-autocomplete-panel{width:100%;max-height:256px;visibility:hidden;transform-origin:center top;overflow:auto;padding:8px 0;box-sizing:border-box;position:static;border-radius:var(--mat-autocomplete-container-shape, var(--mat-sys-corner-extra-small));box-shadow:var(--mat-autocomplete-container-elevation-shadow, 0px 3px 1px -2px rgba(0, 0, 0, 0.2), 0px 2px 2px 0px rgba(0, 0, 0, 0.14), 0px 1px 5px 0px rgba(0, 0, 0, 0.12));background-color:var(--mat-autocomplete-background-color, var(--mat-sys-surface-container))}@media(forced-colors: active){div.mat-mdc-autocomplete-panel{outline:solid 1px}}.cdk-overlay-pane:not(.mat-mdc-autocomplete-panel-above) div.mat-mdc-autocomplete-panel{border-top-left-radius:0;border-top-right-radius:0}.mat-mdc-autocomplete-panel-above div.mat-mdc-autocomplete-panel{border-bottom-left-radius:0;border-bottom-right-radius:0;transform-origin:center bottom}div.mat-mdc-autocomplete-panel.mat-mdc-autocomplete-visible{visibility:visible}div.mat-mdc-autocomplete-panel.mat-mdc-autocomplete-hidden{visibility:hidden;pointer-events:none}mat-autocomplete{display:none}"],encapsulation:2,data:{animation:[kw]},changeDetection:0})}return v})();const Ow={provide:Su.kq,useExisting:(0,c.Rfq)(()=>qg),multi:!0},Zg=new c.nKC("mat-autocomplete-scroll-strategy",{providedIn:"root",factory:()=>{const v=(0,c.WQX)(Au.hJ);return()=>v.scrollStrategies.reposition()}}),ef={provide:Zg,deps:[Au.hJ],useFactory:function rp(v){return()=>v.scrollStrategies.reposition()}};let qg=(()=>{class v{_element=(0,c.WQX)(c.aKT);_overlay=(0,c.WQX)(Au.hJ);_viewContainerRef=(0,c.WQX)(c.c1b);_zone=(0,c.WQX)(c.SKi);_changeDetectorRef=(0,c.WQX)(c.gRc);_dir=(0,c.WQX)(dy.dS,{optional:!0});_formField=(0,c.WQX)(bn.xb,{optional:!0,host:!0});_document=(0,c.WQX)(at.qQ);_viewportRuler=(0,c.WQX)(Cm.Xj);_defaults=(0,c.WQX)(Xg,{optional:!0});_overlayRef;_portal;_componentDestroyed=!1;_scrollStrategy=(0,c.WQX)(Zg);_keydownSubscription;_outsideClickSubscription;_previousValue;_valueOnAttach;_valueOnLastKeydown;_positionStrategy;_manuallyFloatingLabel=!1;_closingActionsSubscription;_viewportSubscription=Dm.yU.EMPTY;_breakpointObserver=(0,c.WQX)(zd.QP);_handsetLandscapeSubscription=Dm.yU.EMPTY;_canOpenOnNextFocus=!0;_valueBeforeAutoSelection;_pendingAutoselectedOption;_closeKeyEventStream=new tl.B;_windowBlurHandler=()=>{this._canOpenOnNextFocus=this._document.activeElement!==this._element.nativeElement||this.panelOpen};_onChange=()=>{};_onTouched=()=>{};autocomplete;position="auto";connectedTo;autocompleteAttribute="off";autocompleteDisabled;_initialized=new tl.B;_injector=(0,c.WQX)(c.zZn);constructor(){}_aboveClass="mat-mdc-autocomplete-panel-above";ngAfterViewInit(){this._initialized.next(),this._initialized.complete();const d=this._getWindow();typeof d<"u"&&this._zone.runOutsideAngular(()=>d.addEventListener("blur",this._windowBlurHandler))}ngOnChanges(d){d.position&&this._positionStrategy&&(this._setStrategyPositions(this._positionStrategy),this.panelOpen&&this._overlayRef.updatePosition())}ngOnDestroy(){const d=this._getWindow();typeof d<"u"&&d.removeEventListener("blur",this._windowBlurHandler),this._handsetLandscapeSubscription.unsubscribe(),this._viewportSubscription.unsubscribe(),this._componentDestroyed=!0,this._destroyPanel(),this._closeKeyEventStream.complete(),this._clearFromModal()}get panelOpen(){return this._overlayAttached&&this.autocomplete.showPanel}_overlayAttached=!1;openPanel(){this._openPanelInternal()}closePanel(){this._resetLabel(),this._overlayAttached&&(this.panelOpen&&this._zone.run(()=>{this.autocomplete.closed.emit()}),this.autocomplete._latestOpeningTrigger===this&&(this.autocomplete._isOpen=!1,this.autocomplete._latestOpeningTrigger=null),this._overlayAttached=!1,this._pendingAutoselectedOption=null,this._overlayRef&&this._overlayRef.hasAttached()&&(this._overlayRef.detach(),this._closingActionsSubscription.unsubscribe()),this._updatePanelState(),this._componentDestroyed||this._changeDetectorRef.detectChanges(),this._trackedModal&&(0,Kc.Ae)(this._trackedModal,"aria-owns",this.autocomplete.id))}updatePosition(){this._overlayAttached&&this._overlayRef.updatePosition()}get panelClosingActions(){return(0,wu.h)(this.optionSelections,this.autocomplete._keyManager.tabOut.pipe((0,dt.p)(()=>this._overlayAttached)),this._closeKeyEventStream,this._getOutsideClickStream(),this._overlayRef?this._overlayRef.detachments().pipe((0,dt.p)(()=>this._overlayAttached)):(0,O.of)()).pipe((0,Os.T)(d=>d instanceof rn.MI?d:null))}optionSelections=(0,qu.v)(()=>{const d=this.autocomplete?this.autocomplete.options:null;return d?d.changes.pipe((0,Mw.Z)(d),(0,se.n)(()=>(0,wu.h)(...d.map(_=>_.onSelectionChange)))):this._initialized.pipe((0,se.n)(()=>this.optionSelections))});get activeOption(){return this.autocomplete&&this.autocomplete._keyManager?this.autocomplete._keyManager.activeItem:null}_getOutsideClickStream(){return(0,wu.h)((0,yu.R)(this._document,"click"),(0,yu.R)(this._document,"auxclick"),(0,yu.R)(this._document,"touchend")).pipe((0,dt.p)(d=>{const _=(0,Ce.Fb)(d),D=this._formField?this._formField.getConnectedOverlayOrigin().nativeElement:null,V=this.connectedTo?this.connectedTo.elementRef.nativeElement:null;return this._overlayAttached&&_!==this._element.nativeElement&&this._document.activeElement!==this._element.nativeElement&&(!D||!D.contains(_))&&(!V||!V.contains(_))&&!!this._overlayRef&&!this._overlayRef.overlayElement.contains(_)}))}writeValue(d){Promise.resolve(null).then(()=>this._assignOptionValue(d))}registerOnChange(d){this._onChange=d}registerOnTouched(d){this._onTouched=d}setDisabledState(d){this._element.nativeElement.disabled=d}_handleKeydown(d){const _=d.keyCode,D=(0,ol.rp)(d);if(_===ol._f&&!D&&d.preventDefault(),this._valueOnLastKeydown=this._element.nativeElement.value,this.activeOption&&_===ol.Fm&&this.panelOpen&&!D)this.activeOption._selectViaInteraction(),this._resetActiveItem(),d.preventDefault();else if(this.autocomplete){const V=this.autocomplete._keyManager.activeItem,J=_===ol.i7||_===ol.n6;_===ol.wn||J&&!D&&this.panelOpen?this.autocomplete._keyManager.onKeydown(d):J&&this._canOpen()&&this._openPanelInternal(this._valueOnLastKeydown),(J||this.autocomplete._keyManager.activeItem!==V)&&(this._scrollToOption(this.autocomplete._keyManager.activeItemIndex||0),this.autocomplete.autoSelectActiveOption&&this.activeOption&&(this._pendingAutoselectedOption||(this._valueBeforeAutoSelection=this._valueOnLastKeydown),this._pendingAutoselectedOption=this.activeOption,this._assignOptionValue(this.activeOption.value)))}}_handleInput(d){let _=d.target,D=_.value;if("number"===_.type&&(D=""==D?null:parseFloat(D)),this._previousValue!==D){if(this._previousValue=D,this._pendingAutoselectedOption=null,(!this.autocomplete||!this.autocomplete.requireSelection)&&this._onChange(D),D){if(this.panelOpen&&!this.autocomplete.requireSelection){const V=this.autocomplete.options?.find(J=>J.selected);V&&D!==this._getDisplayValue(V.value)&&V.deselect(!1)}}else this._clearPreviousSelectedOption(null,!1);if(this._canOpen()&&this._document.activeElement===d.target){const V=this._valueOnLastKeydown??this._element.nativeElement.value;this._valueOnLastKeydown=null,this._openPanelInternal(V)}}}_handleFocus(){this._canOpenOnNextFocus?this._canOpen()&&(this._previousValue=this._element.nativeElement.value,this._attachOverlay(this._previousValue),this._floatLabel(!0)):this._canOpenOnNextFocus=!0}_handleClick(){this._canOpen()&&!this.panelOpen&&this._openPanelInternal()}_floatLabel(d=!1){this._formField&&"auto"===this._formField.floatLabel&&(d?this._formField._animateAndLockLabel():this._formField.floatLabel="always",this._manuallyFloatingLabel=!0)}_resetLabel(){this._manuallyFloatingLabel&&(this._formField&&(this._formField.floatLabel="auto"),this._manuallyFloatingLabel=!1)}_subscribeToClosingActions(){const d=new S.c(D=>{(0,c.mal)(()=>{D.next()},{injector:this._injector})}),_=this.autocomplete.options.changes.pipe((0,Eu.M)(()=>this._positionStrategy.reapplyLastPosition()),(0,pe.c)(0));return(0,wu.h)(d,_).pipe((0,se.n)(()=>this._zone.run(()=>{const D=this.panelOpen;return this._resetActiveItem(),this._updatePanelState(),this._changeDetectorRef.detectChanges(),this.panelOpen&&this._overlayRef.updatePosition(),D!==this.panelOpen&&(this.panelOpen?this._emitOpened():this.autocomplete.closed.emit()),this.panelClosingActions})),(0,M.s)(1)).subscribe(D=>this._setValueAndClose(D))}_emitOpened(){this.autocomplete.opened.emit()}_destroyPanel(){this._overlayRef&&(this.closePanel(),this._overlayRef.dispose(),this._overlayRef=null)}_getDisplayValue(d){const _=this.autocomplete;return _&&_.displayWith?_.displayWith(d):d}_assignOptionValue(d){const _=this._getDisplayValue(d);null==d&&this._clearPreviousSelectedOption(null,!1),this._updateNativeInputValue(_??"")}_updateNativeInputValue(d){this._formField?this._formField._control.value=d:this._element.nativeElement.value=d,this._previousValue=d}_setValueAndClose(d){const _=this.autocomplete,D=d?d.source:this._pendingAutoselectedOption;D?(this._clearPreviousSelectedOption(D),this._assignOptionValue(D.value),this._onChange(D.value),_._emitSelectEvent(D),this._element.nativeElement.focus()):_.requireSelection&&this._element.nativeElement.value!==this._valueOnAttach&&(this._clearPreviousSelectedOption(null),this._assignOptionValue(null),_._animationDone?_._animationDone.pipe((0,M.s)(1)).subscribe(()=>this._onChange(null)):this._onChange(null)),this.closePanel()}_clearPreviousSelectedOption(d,_){this.autocomplete?.options?.forEach(D=>{D!==d&&D.selected&&D.deselect(_)})}_openPanelInternal(d=this._element.nativeElement.value){this._attachOverlay(d),this._floatLabel(),this._trackedModal&&(0,Kc.px)(this._trackedModal,"aria-owns",this.autocomplete.id)}_attachOverlay(d){let _=this._overlayRef;_?(this._positionStrategy.setOrigin(this._getConnectedElement()),_.updateSize({width:this._getPanelWidth()})):(this._portal=new ym.VA(this.autocomplete.template,this._viewContainerRef,{id:this._formField?.getLabelId()}),_=this._overlay.create(this._getOverlayConfig()),this._overlayRef=_,this._viewportSubscription=this._viewportRuler.change().subscribe(()=>{this.panelOpen&&_&&_.updateSize({width:this._getPanelWidth()})}),this._handsetLandscapeSubscription=this._breakpointObserver.observe(zd.Rp.HandsetLandscape).subscribe(V=>{V.matches?this._positionStrategy.withFlexibleDimensions(!0).withGrowAfterOpen(!0).withViewportMargin(8):this._positionStrategy.withFlexibleDimensions(!1).withGrowAfterOpen(!1).withViewportMargin(0)})),_&&!_.hasAttached()&&(_.attach(this._portal),this._valueOnAttach=d,this._valueOnLastKeydown=null,this._closingActionsSubscription=this._subscribeToClosingActions());const D=this.panelOpen;this.autocomplete._isOpen=this._overlayAttached=!0,this.autocomplete._latestOpeningTrigger=this,this.autocomplete._setColor(this._formField?.color),this._updatePanelState(),this._applyModalPanelOwnership(),this.panelOpen&&D!==this.panelOpen&&this._emitOpened()}_handlePanelKeydown=d=>{(d.keyCode===ol._f&&!(0,ol.rp)(d)||d.keyCode===ol.i7&&(0,ol.rp)(d,"altKey"))&&(this._pendingAutoselectedOption&&(this._updateNativeInputValue(this._valueBeforeAutoSelection??""),this._pendingAutoselectedOption=null),this._closeKeyEventStream.next(),this._resetActiveItem(),d.stopPropagation(),d.preventDefault())};_updatePanelState(){if(this.autocomplete._setVisibility(),this.panelOpen){const d=this._overlayRef;this._keydownSubscription||(this._keydownSubscription=d.keydownEvents().subscribe(this._handlePanelKeydown)),this._outsideClickSubscription||(this._outsideClickSubscription=d.outsidePointerEvents().subscribe())}else this._keydownSubscription?.unsubscribe(),this._outsideClickSubscription?.unsubscribe(),this._keydownSubscription=this._outsideClickSubscription=null}_getOverlayConfig(){return new Au.rR({positionStrategy:this._getOverlayPosition(),scrollStrategy:this._scrollStrategy(),width:this._getPanelWidth(),direction:this._dir??void 0,panelClass:this._defaults?.overlayPanelClass})}_getOverlayPosition(){const d=this._overlay.position().flexibleConnectedTo(this._getConnectedElement()).withFlexibleDimensions(!1).withPush(!1);return this._setStrategyPositions(d),this._positionStrategy=d,d}_setStrategyPositions(d){const _=[{originX:"start",originY:"bottom",overlayX:"start",overlayY:"top"},{originX:"end",originY:"bottom",overlayX:"end",overlayY:"top"}],D=this._aboveClass,V=[{originX:"start",originY:"top",overlayX:"start",overlayY:"bottom",panelClass:D},{originX:"end",originY:"top",overlayX:"end",overlayY:"bottom",panelClass:D}];let J;J="above"===this.position?V:"below"===this.position?_:[..._,...V],d.withPositions(J)}_getConnectedElement(){return this.connectedTo?this.connectedTo.elementRef:this._formField?this._formField.getConnectedOverlayOrigin():this._element}_getPanelWidth(){return this.autocomplete.panelWidth||this._getHostWidth()}_getHostWidth(){return this._getConnectedElement().nativeElement.getBoundingClientRect().width}_resetActiveItem(){const d=this.autocomplete;if(d.autoActiveFirstOption){let _=-1;for(let D=0;D .cdk-overlay-container [aria-modal="true"]');if(!d)return;const _=this.autocomplete.id;this._trackedModal&&(0,Kc.Ae)(this._trackedModal,"aria-owns",_),(0,Kc.px)(d,"aria-owns",_),this._trackedModal=d}_clearFromModal(){this._trackedModal&&((0,Kc.Ae)(this._trackedModal,"aria-owns",this.autocomplete.id),this._trackedModal=null)}static \u0275fac=function(_){return new(_||v)};static \u0275dir=c.FsC({type:v,selectors:[["input","matAutocomplete",""],["textarea","matAutocomplete",""]],hostAttrs:[1,"mat-mdc-autocomplete-trigger"],hostVars:7,hostBindings:function(_,D){1&_&&c.bIt("focusin",function(){return D._handleFocus()})("blur",function(){return D._onTouched()})("input",function(J){return D._handleInput(J)})("keydown",function(J){return D._handleKeydown(J)})("click",function(){return D._handleClick()}),2&_&&c.BMQ("autocomplete",D.autocompleteAttribute)("role",D.autocompleteDisabled?null:"combobox")("aria-autocomplete",D.autocompleteDisabled?null:"list")("aria-activedescendant",D.panelOpen&&D.activeOption?D.activeOption.id:null)("aria-expanded",D.autocompleteDisabled?null:D.panelOpen.toString())("aria-controls",D.autocompleteDisabled||!D.panelOpen||null==D.autocomplete?null:D.autocomplete.id)("aria-haspopup",D.autocompleteDisabled?null:"listbox")},inputs:{autocomplete:[0,"matAutocomplete","autocomplete"],position:[0,"matAutocompletePosition","position"],connectedTo:[0,"matAutocompleteConnectedTo","connectedTo"],autocompleteAttribute:[0,"autocomplete","autocompleteAttribute"],autocompleteDisabled:[2,"matAutocompleteDisabled","autocompleteDisabled",c.L39]},exportAs:["matAutocompleteTrigger"],features:[c.Jv_([Ow]),c.GFd,c.OA$]})}return v})(),Jg=(()=>{class v{static \u0275fac=function(_){return new(_||v)};static \u0275mod=c.$C({type:v});static \u0275inj=c.G2t({providers:[ef],imports:[Au.z_,rn.Sy,rn.yE,Cm.Gj,rn.Sy,rn.yE]})}return v})();var fy=r(6389),py=r(8627),ip=r(3149);const e_=["barSearchInput"],my=["matAutocomplete"];function gy(v,m){if(1&v){const d=c.RV6();c.j41(0,"button",5),c.bIt("click",function(){c.eBV(d);const D=c.XpG(2);return c.Njj(D.open())}),c.nrm(1,"mat-icon",6),c.k0s()}2&v&&(c.R7$(),c.Y8G("svgIcon","heroicons_outline:magnifying-glass"))}function tf(v,m){1&v&&(c.j41(0,"mat-option",14),c.EFF(1," No results found! "),c.k0s())}function t_(v,m){if(1&v){const d=c.RV6();c.j41(0,"img",22),c.bIt("error",function(D){c.eBV(d);const V=c.XpG(5);return c.Njj(V.handleImageError(D))}),c.k0s()}if(2&v){const d=c.XpG().$implicit;c.Mz_("alt","",d.name,"'s avatar"),c.Y8G("src",d.avatar,c.B4B)}}function Am(v,m){1&v&&(c.qex(0),c.nrm(1,"mat-icon",23),c.bVm()),2&v&&(c.R7$(),c.Y8G("svgIcon","heroicons_outline:user-circle"))}function _y(v,m){if(1&v&&(c.j41(0,"div",24),c.EFF(1),c.k0s()),2&v){const d=c.XpG().$implicit;c.R7$(),c.SpI(" ",d.about," ")}}function Rw(v,m){if(1&v&&(c.qex(0),c.j41(1,"mat-option",15)(2,"div",16)(3,"div",17),c.DNE(4,t_,1,3,"img",18)(5,Am,2,1,"ng-container",2),c.k0s(),c.j41(6,"div",19)(7,"span",20),c.EFF(8),c.k0s(),c.DNE(9,_y,2,1,"div",21),c.k0s()()(),c.bVm()),2&v){const d=m.$implicit;c.R7$(),c.Y8G("routerLink",d.link)("value",d.name),c.R7$(3),c.Y8G("ngIf",d.avatar),c.R7$(),c.Y8G("ngIf",!d.avatar),c.R7$(3),c.JRh(d.name),c.R7$(),c.Y8G("ngIf",d.about)}}function Nw(v,m){if(1&v&&(c.qex(0),c.DNE(1,Rw,10,6,"ng-container",12),c.bVm()),2&v){const d=m.$implicit,_=c.XpG(3);c.R7$(),c.Y8G("ngForOf",d.results)("ngForTrackBy",_.trackByFn)}}function nf(v,m){if(1&v){const d=c.RV6();c.j41(0,"div",7),c.nrm(1,"mat-icon",8),c.j41(2,"input",9,0),c.bIt("keydown",function(D){c.eBV(d);const V=c.XpG(2);return c.Njj(V.onKeydown(D))}),c.k0s(),c.j41(4,"mat-autocomplete",10,1),c.DNE(6,tf,2,0,"mat-option",11)(7,Nw,2,2,"ng-container",12),c.k0s(),c.j41(8,"button",13),c.bIt("click",function(){c.eBV(d);const D=c.XpG(2);return c.Njj(D.close())}),c.nrm(9,"mat-icon",6),c.k0s()()}if(2&v){const d=c.sdS(5),_=c.XpG(2);c.Y8G("@slideInTop",void 0)("@slideOutTop",void 0),c.R7$(),c.Y8G("svgIcon","heroicons_outline:magnifying-glass"),c.R7$(),c.Y8G("formControl",_.searchControl)("matAutocomplete",d)("placeholder","Search..."),c.R7$(2),c.Y8G("autoSelectActiveOption",!0)("disableRipple",!0),c.R7$(2),c.Y8G("ngIf",_.resultSets&&!_.resultSets.length),c.R7$(),c.Y8G("ngForOf",_.resultSets)("ngForTrackBy",_.trackByFn),c.R7$(2),c.Y8G("svgIcon","heroicons_outline:x-mark")}}function vy(v,m){if(1&v&&(c.j41(0,"div"),c.DNE(1,gy,2,1,"button",3)(2,nf,10,12,"div",4),c.k0s()),2&v){const d=c.XpG();c.R7$(),c.Y8G("ngIf",!d.opened),c.R7$(),c.Y8G("ngIf",d.opened)}}let rf=(()=>{class v{constructor(d,_){this._storageService=d,this._sanitizer=_,this.appearance="basic",this.debounce=300,this.minLength=2,this.search=new c.bkB,this.opened=!1,this.searchControl=new Su.hs,this._unsubscribeAll=new tl.B}set barSearchInput(d){d&&setTimeout(()=>{d.nativeElement.focus()})}set matAutocomplete(d){this._matAutocomplete=d}ngOnChanges(d){"appearance"in d&&this.close()}ngOnInit(){var d=this;this.searchControl.valueChanges.pipe((0,py.B)(this.debounce),(0,ea.Q)(this._unsubscribeAll),(0,Os.T)(_=>((!_||_.length_&&_.length>=this.minLength)).subscribe(function(){var _=(0,w.A)(function*(D){const V=yield d._storageService.searchProfile(D);d.resultSets=V.map(J=>({label:"Project",results:[{name:J.profile.name||J.profile.displayName||J.pubKey,pubkey:J.pubKey,username:J.profile.username||"",website:J.profile.website||"",about:J.profile.about?J.profile.about.replace(/<\/?[^>]+(>|$)/g,""):"",avatar:J.profile.picture||null,banner:J.profile.banner||null,link:`/profile/${J.pubKey}`}]})),d.search.next(d.resultSets)});return function(D){return _.apply(this,arguments)}}())}ngOnDestroy(){this._unsubscribeAll.next(null),this._unsubscribeAll.complete()}onKeydown(d){"Escape"===d.code&&"bar"===this.appearance&&!this._matAutocomplete.isOpen&&this.close()}open(){this.opened||(this.opened=!0)}close(){this.opened&&(this.searchControl.setValue(""),this.opened=!1)}trackByFn(d,_){return _.id||d}handleImageError(d){const _=d.target;_.onerror=null,_.src="images/avatars/avatar-placeholder.png"}static{this.\u0275fac=function(_){return new(_||v)(c.rXU(ip.n),c.rXU(i.up))}}static{this.\u0275cmp=c.VBU({type:v,selectors:[["search"]],viewQuery:function(_,D){if(1&_&&(c.GBs(e_,5),c.GBs(my,5)),2&_){let V;c.mGM(V=c.lsd())&&(D.barSearchInput=V.first),c.mGM(V=c.lsd())&&(D.matAutocomplete=V.first)}},inputs:{appearance:"appearance",debounce:"debounce",minLength:"minLength"},outputs:{search:"search"},exportAs:["angorSearch"],features:[c.Jv_([{provide:Zg,useFactory:()=>{const d=(0,c.WQX)(Au.hJ);return()=>d.scrollStrategies.block()}}]),c.OA$],decls:1,vars:1,consts:[["barSearchInput",""],["matAutocomplete","matAutocomplete"],[4,"ngIf"],["mat-icon-button","",3,"click",4,"ngIf"],["class","bg-card absolute inset-0 z-99 flex shrink-0 items-center",4,"ngIf"],["mat-icon-button","",3,"click"],[3,"svgIcon"],[1,"bg-card","absolute","inset-0","z-99","flex","shrink-0","items-center"],[1,"absolute","ml-6","sm:ml-8",3,"svgIcon"],[1,"h-full","w-full","px-16","sm:px-18",3,"keydown","formControl","matAutocomplete","placeholder"],[1,"max-h-128","rounded-b","border-t","shadow-md","sm:px-2",3,"autoSelectActiveOption","disableRipple"],["class","text-secondary pointer-events-none bg-transparent px-6 py-0 text-md",4,"ngIf"],[4,"ngFor","ngForOf","ngForTrackBy"],["mat-icon-button","",1,"absolute","right-5","top-1/2","-mt-5","h-10","w-10","shrink-0","sm:right-7",3,"click"],[1,"text-secondary","pointer-events-none","bg-transparent","px-6","py-0","text-md"],[1,"group","relative","mb-1","rounded-md","px-6","py-0","text-md","dark:hover:bg-hover","hover:bg-gray-100",3,"routerLink","value"],[1,"flex","items-center"],[1,"flex","h-8","w-8","shrink-0","items-center","justify-center","overflow-hidden","rounded-full","bg-primary-100","dark:bg-primary-800"],["class","h-full w-full object-cover",3,"src","alt","error",4,"ngIf"],[1,"ml-3","truncate"],[1,"font-semibold"],["class","text-sm text-gray-500",4,"ngIf"],[1,"h-full","w-full","object-cover",3,"error","src","alt"],[1,"m-0","text-primary","icon-size-5","dark:text-primary-400",3,"svgIcon"],[1,"text-sm","text-gray-500"]],template:function(_,D){1&_&&c.DNE(0,vy,3,2,"div",2),2&_&&c.Y8G("ngIf","bar"===D.appearance)},dependencies:[_l.Hl,_l.iY,il.m_,il.An,Su.YN,Su.me,Su.BC,Jg,Tu,rn.wT,qg,Su.X1,Su.l_,rn.Sy,a.Wk,bn.RG,fy.fS,at.MD,at.Sq,at.bT],encapsulation:2,data:{animation:xm.F}})}}return v})();var op=r(7702),Mu=r(7818),yy=r(1109),Lw=r(4482);const n_=()=>["/settings"];function by(v,m){if(1&v&&(c.qex(0),c.nrm(1,"img",15),c.bVm()),2&v){const d=c.XpG();c.R7$(),c.Y8G("src",d.getSafeUrl(null==d.user?null:d.user.picture),c.B4B)}}function r_(v,m){1&v&&c.nrm(0,"mat-icon",12),2&v&&c.Y8G("svgIcon","heroicons_outline:user-circle")}let sp=(()=>{class v{constructor(d,_,D,V,J,we,Xe){this._changeDetectorRef=d,this._router=_,this._angorConfigService=D,this._signerService=V,this._storageService=J,this.sanitizer=we,this._nostrLoginService=Xe,this.isLoading=!0,this.errorMessage=null,this._unsubscribeAll=new tl.B}ngOnInit(){this.userPubKey=this._signerService.getPublicKey(),this._angorConfigService.config$.pipe((0,ea.Q)(this._unsubscribeAll)).subscribe(d=>{localStorage.setItem("angorConfig",JSON.stringify(d)),this.config=d,this._changeDetectorRef.detectChanges()}),this.loadUserProfile(),this._storageService.profile$.subscribe(d=>{d&&d.pubKey===this.userPubKey&&(this.user=d.metadata,this._changeDetectorRef.detectChanges())})}ngOnDestroy(){this._unsubscribeAll.next(null),this._unsubscribeAll.complete()}loadUserProfile(){var d=this;return(0,w.A)(function*(){d._storageService.getProfile(d.userPubKey).then(_=>{d.user=_,d._changeDetectorRef.detectChanges()})})()}logout(){this._router.navigate(["/logout"])}profile(){this._router.navigate(["/profile"])}setLayout(d){this._angorConfigService.config={layout:d},this._changeDetectorRef.detectChanges()}setScheme(d){this._angorConfigService.config={scheme:d},this._changeDetectorRef.detectChanges()}setTheme(d){this._angorConfigService.config={theme:d},this._changeDetectorRef.detectChanges()}getSafeUrl(d){return this.sanitizer.bypassSecurityTrustUrl(d)}Switch(){this._nostrLoginService.switchAccount()}static{this.\u0275fac=function(_){return new(_||v)(c.rXU(c.gRc),c.rXU(a.Ix),c.rXU(yy.P),c.rXU(Vd.A),c.rXU(ip.n),c.rXU(i.up),c.rXU(Lw.v))}}static{this.\u0275cmp=c.VBU({type:v,selectors:[["user"]],decls:50,vars:16,consts:[["defaultAvatar",""],["userActions","matMenu"],["settingsMenu","matMenu"],["mat-icon-button","",3,"matMenuTriggerFor"],[1,"relative"],[4,"ngIf","ngIfElse"],[3,"xPosition"],["mat-menu-item",""],[1,"flex","flex-col","leading-none"],[1,"mt-1.5","text-md","font-medium"],[1,"my-2"],["mat-menu-item","",3,"click"],[3,"svgIcon"],["mat-menu-item","",3,"matMenuTriggerFor"],["mat-menu-item","",3,"routerLink"],["alt","","onerror","this.onerror=null; this.src='/images/avatars/avatar-placeholder.png';",1,"h-7","w-7","rounded-full","object-cover",3,"src"]],template:function(_,D){if(1&_){const V=c.RV6();c.j41(0,"button",3)(1,"span",4),c.DNE(2,by,2,1,"ng-container",5)(3,r_,1,1,"ng-template",null,0,c.C5r),c.k0s()(),c.j41(5,"mat-menu",6,1)(7,"button",7)(8,"span",8)(9,"span"),c.EFF(10,"Logged in as"),c.k0s(),c.j41(11,"span",9),c.EFF(12),c.k0s()()(),c.nrm(13,"mat-divider",10),c.j41(14,"button",11),c.bIt("click",function(){return c.eBV(V),c.Njj(D.Switch())}),c.nrm(15,"mat-icon",12),c.j41(16,"span"),c.EFF(17,"Switch account"),c.k0s()(),c.j41(18,"button",11),c.bIt("click",function(){return c.eBV(V),c.Njj(D.profile())}),c.nrm(19,"mat-icon",12),c.j41(20,"span"),c.EFF(21,"Profile"),c.k0s()(),c.j41(22,"button",13),c.nrm(23,"mat-icon",12),c.j41(24,"span"),c.EFF(25,"Options"),c.k0s()(),c.nrm(26,"mat-divider",10),c.j41(27,"button",11),c.bIt("click",function(){return c.eBV(V),c.Njj(D.logout())}),c.nrm(28,"mat-icon",12),c.j41(29,"span"),c.EFF(30,"logout"),c.k0s()()(),c.j41(31,"mat-menu",null,2)(33,"button",11),c.bIt("click",function(){return c.eBV(V),c.Njj(D.setScheme("auto"))}),c.nrm(34,"mat-icon",12),c.j41(35,"span"),c.EFF(36,"Auto Theme"),c.k0s()(),c.j41(37,"button",11),c.bIt("click",function(){return c.eBV(V),c.Njj(D.setScheme("light"))}),c.nrm(38,"mat-icon",12),c.j41(39,"span"),c.EFF(40,"Light Theme"),c.k0s()(),c.j41(41,"button",11),c.bIt("click",function(){return c.eBV(V),c.Njj(D.setScheme("dark"))}),c.nrm(42,"mat-icon",12),c.j41(43,"span"),c.EFF(44,"Dark Theme"),c.k0s()(),c.nrm(45,"mat-divider"),c.j41(46,"button",14),c.nrm(47,"mat-icon",12),c.j41(48,"span"),c.EFF(49,"Settings"),c.k0s()()()}if(2&_){const V=c.sdS(4),J=c.sdS(6),we=c.sdS(32);c.Y8G("matMenuTriggerFor",J),c.R7$(2),c.Y8G("ngIf",null==D.user?null:D.user.picture)("ngIfElse",V),c.R7$(3),c.Y8G("xPosition","before"),c.R7$(7),c.JRh((null==D.user?null:D.user.display_name)||(null==D.user?null:D.user.name)||"Unknown User"),c.R7$(3),c.Y8G("svgIcon","heroicons_outline:user-circle"),c.R7$(4),c.Y8G("svgIcon","heroicons_outline:user-circle"),c.R7$(3),c.Y8G("matMenuTriggerFor",we),c.R7$(),c.Y8G("svgIcon","heroicons_outline:cog-8-tooth"),c.R7$(5),c.Y8G("svgIcon","heroicons_outline:arrow-right-on-rectangle"),c.R7$(6),c.Y8G("svgIcon","heroicons_solid:bolt"),c.R7$(4),c.Y8G("svgIcon","heroicons_solid:sun"),c.R7$(4),c.Y8G("svgIcon","heroicons_solid:moon"),c.R7$(4),c.Y8G("routerLink",c.lJ4(15,n_)),c.R7$(),c.Y8G("svgIcon","heroicons_outline:cog-8-tooth")}},dependencies:[_l.Hl,_l.iY,Mu.Cn,Mu.kk,Mu.fb,Mu.Cp,il.m_,il.An,op.w,op.q,at.MD,at.bT,a.iI,a.Wk],encapsulation:2,changeDetection:0})}}return v})();var i_=r(6061),ad=r(9587);let wy=(()=>{class v{constructor(d,_){this.swUpdate=d,this.zone=_,this.newVersionAvailableSubject=new Oe.t(!1),this.isNewVersionAvailable$=this.newVersionAvailableSubject.asObservable(),this.intervalSource=function o_(v=0,m=i_.E){return v<0&&(v=0),(0,ad.O)(v,v,m)}(9e5),this.checkForUpdateOnLoad(),this.checkForUpdateOnInterval()}applyUpdate(){this.swUpdate.activateUpdate().then(()=>document.location.reload()).catch(d=>console.error("Failed to apply updates:",d))}checkForUpdateOnInterval(){var d=this;this.unsubscribeInterval(),this.swUpdate.isEnabled&&this.zone.runOutsideAngular(()=>{this.intervalSubscription=this.intervalSource.subscribe((0,w.A)(function*(){try{(yield d.swUpdate.checkForUpdate())&&d.newVersionAvailableSubject.next(!0)}catch(_){console.error("Failed to check for updates:",_)}}))})}checkForUpdateOnLoad(){this.unsubscribeNewVersion(),this.swUpdate.isEnabled&&(this.newVersionSubscription=this.swUpdate.versionUpdates.subscribe(d=>{switch(d.type){case"VERSION_DETECTED":break;case"VERSION_READY":this.newVersionAvailableSubject.next(!0);break;case"VERSION_INSTALLATION_FAILED":console.error(`Failed to install app version '${d.version.hash}': ${d.error}`)}}))}unsubscribeInterval(){this.intervalSubscription&&this.intervalSubscription.unsubscribe()}unsubscribeNewVersion(){this.newVersionSubscription&&this.newVersionSubscription.unsubscribe()}static{this.\u0275fac=function(_){return new(_||v)(c.KVO(Ld),c.KVO(c.SKi))}}static{this.\u0275prov=c.jDH({token:v,factory:v.\u0275fac,providedIn:"root"})}}return v})();function Ey(v,m){if(1&v){const d=c.RV6();c.j41(0,"button",1),c.bIt("click",function(){c.eBV(d);const D=c.XpG();return c.Njj(D.applyUpdate())}),c.nrm(1,"mat-icon",2),c.k0s()}if(2&v){const d=c.XpG();c.Y8G("matTooltip",d.tooltip||"Update App"),c.R7$(),c.Y8G("svgIcon","heroicons_outline:cloud-arrow-down")}}let s_=(()=>{class v{constructor(d,_){this.updateService=d,this._changeDetectorRef=_,this.updateService.isNewVersionAvailable$.subscribe(D=>{D&&this._changeDetectorRef.detectChanges()})}applyUpdate(){this.updateService.applyUpdate()}static{this.\u0275fac=function(_){return new(_||v)(c.rXU(wy),c.rXU(c.gRc))}}static{this.\u0275cmp=c.VBU({type:v,selectors:[["update"]],inputs:{tooltip:"tooltip"},exportAs:["update"],decls:2,vars:3,consts:[["mat-icon-button","",3,"matTooltip","click",4,"ngIf"],["mat-icon-button","",3,"click","matTooltip"],[3,"svgIcon"]],template:function(_,D){1&_&&(c.DNE(0,Ey,2,2,"button",0),c.nI1(1,"async")),2&_&&c.Y8G("ngIf",c.bMT(1,1,D.updateService.isNewVersionAvailable$))},dependencies:[_l.Hl,_l.iY,il.m_,il.An,zc.uc,zc.oV,at.MD,at.bT,at.Jj],encapsulation:2,changeDetection:0})}}return v})();function xy(v,m){if(1&v&&(c.j41(0,"angor-vertical-navigation",0),c.qex(1,10),c.j41(2,"div",11),c.nrm(3,"img",12),c.k0s(),c.bVm(),c.k0s()),2&v){const d=c.XpG();c.Y8G("mode","over")("name","mainNavigation")("navigation",d.navigation.default)("opened",!1)}}function a_(v,m){if(1&v&&(c.j41(0,"div",13)(1,"div",14),c.nrm(2,"img",15)(3,"img",16),c.k0s(),c.nrm(4,"img",17),c.k0s(),c.nrm(5,"angor-horizontal-navigation",18)),2&v){const d=c.XpG();c.R7$(5),c.Y8G("name","mainNavigation")("navigation",d.navigation.horizontal)}}function Cy(v,m){if(1&v){const d=c.RV6();c.j41(0,"button",19),c.bIt("click",function(){c.eBV(d);const D=c.XpG();return c.Njj(D.toggleNavigation("mainNavigation"))}),c.nrm(1,"mat-icon",20),c.k0s()}2&v&&(c.R7$(),c.Y8G("svgIcon","heroicons_outline:bars-3"))}function Dy(v,m){1&v&&c.nrm(0,"router-outlet")}let Ay=(()=>{class v{constructor(d,_,D,V,J){this._activatedRoute=d,this._router=_,this._navigationService=D,this._angorMediaWatcherService=V,this._angorNavigationService=J,this._unsubscribeAll=new tl.B,this.version=cc}ngOnInit(){this._navigationService.navigation$.pipe((0,ea.Q)(this._unsubscribeAll)).subscribe(d=>{this.navigation=d}),this._angorMediaWatcherService.onMediaChange$.pipe((0,ea.Q)(this._unsubscribeAll)).subscribe(({matchingAliases:d})=>{this.isScreenSmall=!d.includes("md")})}ngOnDestroy(){this._unsubscribeAll.next(null),this._unsubscribeAll.complete()}toggleNavigation(d){const _=this._angorNavigationService.getComponent(d);_&&_.toggle()}static{this.\u0275fac=function(_){return new(_||v)(c.rXU(a.nX),c.rXU(a.Ix),c.rXU(wa),c.rXU(ue.l),c.rXU(Zh.lX))}}static{this.\u0275cmp=c.VBU({type:v,selectors:[["modern-layout"]],decls:17,vars:6,consts:[[1,"dark","bg-gray-900","print:hidden",3,"mode","name","navigation","opened"],[1,"flex","w-full","min-w-0","flex-auto","flex-col"],[1,"bg-card","relative","z-49","flex","h-16","w-full","flex-0","items-center","px-4","shadow","dark:border-b","dark:bg-transparent","dark:shadow-none","sm:h-20","md:px-6","print:hidden"],["mat-icon-button",""],[1,"ml-auto","flex","items-center","space-x-0.5","pl-2","sm:space-x-2"],[1,"hidden","md:block"],[3,"appearance"],[1,"flex","w-full","flex-auto","flex-col"],[1,"bg-card","relative","z-49","flex","h-14","w-full","flex-0","items-center","border-t","px-4","dark:bg-transparent","sm:h-20","md:px-6","print:hidden"],[1,"text-secondary","font-medium"],["angorVerticalNavigationContentHeader",""],[1,"flex","h-20","items-center","px-8","pt-6"],["src","images/logo/logo-text-on-dark.svg","alt","Angor Hub",1,"h-10","w-24"],[1,"mx-2","flex","items-center","lg:mr-8"],[1,"hidden","lg:flex"],["src","images/logo/logo-text.svg",1,"h-10","w-24","dark:hidden"],["src","images/logo/logo-text-on-dark.svg",1,"hidden","h-10","w-24","dark:flex"],["src","images/logo/logo.svg",1,"flex","w-8","lg:hidden"],[1,"mr-2",3,"name","navigation"],["mat-icon-button","",3,"click"],[3,"svgIcon"]],template:function(_,D){1&_&&(c.nrm(0,"angor-loading-bar"),c.DNE(1,xy,4,4,"angor-vertical-navigation",0),c.j41(2,"div",1)(3,"div",2),c.DNE(4,a_,6,2)(5,Cy,2,1,"button",3),c.j41(6,"div",4),c.nrm(7,"update")(8,"angor-fullscreen",5)(9,"search",6)(10,"notifications")(11,"user"),c.k0s()(),c.j41(12,"div",7),c.DNE(13,Dy,1,0,"router-outlet"),c.k0s(),c.j41(14,"div",8)(15,"span",9),c.EFF(16),c.k0s()()()),2&_&&(c.R7$(),c.vxM(D.isScreenSmall?1:-1),c.R7$(3),c.vxM(D.isScreenSmall?-1:4),c.R7$(),c.vxM(D.isScreenSmall?5:-1),c.R7$(4),c.Y8G("appearance","bar"),c.R7$(4),c.vxM(13),c.R7$(3),c.SpI("Angor Hub - version ",D.version,""))},dependencies:[Wc,Zh.Tv,Zh.$w,_l.Hl,_l.iY,il.m_,il.An,Ac,rf,np,sp,a.n3,s_],encapsulation:2})}}return v})();function Sy(v,m){1&v&&c.nrm(0,"router-outlet")}let Ty=(()=>{class v{constructor(d,_,D,V,J){this._activatedRoute=d,this._router=_,this._navigationService=D,this._angorMediaWatcherService=V,this._angorNavigationService=J,this._unsubscribeAll=new tl.B,this.version=cc}ngOnInit(){this._navigationService.navigation$.pipe((0,ea.Q)(this._unsubscribeAll)).subscribe(d=>{this.navigation=d}),this._angorMediaWatcherService.onMediaChange$.pipe((0,ea.Q)(this._unsubscribeAll)).subscribe(({matchingAliases:d})=>{this.isScreenSmall=!d.includes("md")})}ngOnDestroy(){this._unsubscribeAll.next(null),this._unsubscribeAll.complete()}toggleNavigation(d){const _=this._angorNavigationService.getComponent(d);_&&_.toggle()}static{this.\u0275fac=function(_){return new(_||v)(c.rXU(a.nX),c.rXU(a.Ix),c.rXU(wa),c.rXU(ue.l),c.rXU(Zh.lX))}}static{this.\u0275cmp=c.VBU({type:v,selectors:[["classic-layout"]],decls:21,vars:8,consts:[[1,"dark","bg-gray-900","print:hidden",3,"mode","name","navigation","opened"],["angorVerticalNavigationContentHeader",""],[1,"flex","h-20","items-center","p-6"],["src","images/logo/logo-text.svg","alt","Angor Hub",1,"w-30","dark:hidden"],["src","images/logo/logo-text-on-dark.svg","alt","Angor Hub",1,"hidden","w-30","dark:flex"],[1,"flex","w-full","min-w-0","flex-auto","flex-col"],[1,"bg-card","relative","z-49","flex","h-16","w-full","flex-0","items-center","px-4","shadow","dark:border-b","dark:bg-transparent","dark:shadow-none","md:px-6","print:hidden"],["mat-icon-button","",3,"click"],[3,"svgIcon"],[1,"ml-auto","flex","items-center","space-x-0.5","pl-2","sm:space-x-2"],[1,"hidden","md:block"],[3,"appearance"],[1,"flex","flex-auto","flex-col"],[1,"bg-card","relative","z-49","flex","h-14","w-full","flex-0","items-center","justify-start","border-t","px-4","dark:bg-transparent","md:px-6","print:hidden"],[1,"text-secondary","font-medium"]],template:function(_,D){1&_&&(c.nrm(0,"angor-loading-bar"),c.j41(1,"angor-vertical-navigation",0),c.qex(2,1),c.j41(3,"div",2),c.nrm(4,"img",3)(5,"img",4),c.k0s(),c.bVm(),c.k0s(),c.j41(6,"div",5)(7,"div",6)(8,"button",7),c.bIt("click",function(){return D.toggleNavigation("mainNavigation")}),c.nrm(9,"mat-icon",8),c.k0s(),c.j41(10,"div",9),c.nrm(11,"update")(12,"angor-fullscreen",10)(13,"search",11)(14,"notifications")(15,"user"),c.k0s()(),c.j41(16,"div",12),c.DNE(17,Sy,1,0,"router-outlet"),c.k0s(),c.j41(18,"div",13)(19,"span",14),c.EFF(20),c.k0s()()()),2&_&&(c.R7$(),c.Y8G("mode",D.isScreenSmall?"over":"side")("name","mainNavigation")("navigation",D.navigation.default)("opened",!D.isScreenSmall),c.R7$(8),c.Y8G("svgIcon","heroicons_outline:bars-3"),c.R7$(4),c.Y8G("appearance","bar"),c.R7$(4),c.vxM(17),c.R7$(3),c.SpI("Angor Hub - version ",D.version,""))},dependencies:[Wc,Zh.Tv,_l.Hl,_l.iY,il.m_,il.An,Ac,rf,np,sp,a.n3,s_],encapsulation:2})}}return v})();function Sm(v,m){1&v&&c.nrm(0,"empty-layout")}function My(v,m){1&v&&c.nrm(0,"modern-layout")}function ky(v,m){1&v&&c.nrm(0,"classic-layout")}let Sc=(()=>{class v{constructor(d,_,D,V,J,we,Xe){this._activatedRoute=d,this._document=_,this._renderer2=D,this._router=V,this._angorConfigService=J,this._angorMediaWatcherService=we,this._angorPlatformService=Xe,this._unsubscribeAll=new tl.B}ngOnInit(){(0,ac.z)([this._angorConfigService.config$,this._angorMediaWatcherService.onMediaQueryChange$(["(prefers-color-scheme: dark)","(prefers-color-scheme: light)"])]).pipe((0,ea.Q)(this._unsubscribeAll),(0,Os.T)(([d,_])=>{const D={scheme:d.scheme,theme:d.theme};return"auto"===d.scheme&&(D.scheme=_.breakpoints["(prefers-color-scheme: dark)"]?"dark":"light"),D})).subscribe(d=>{this.scheme=d.scheme,this.theme=d.theme,this._updateScheme(),this._updateTheme()}),this._angorConfigService.config$.pipe((0,ea.Q)(this._unsubscribeAll)).subscribe(d=>{this.config=d,this._updateLayout()}),this._router.events.pipe((0,dt.p)(d=>d instanceof a.wF),(0,ea.Q)(this._unsubscribeAll)).subscribe(()=>{this._updateLayout()}),this._renderer2.setAttribute(this._document.querySelector("[ng-version]"),"angor-version",cc),this._renderer2.addClass(this._document.body,this._angorPlatformService.osName)}ngOnDestroy(){this._unsubscribeAll.next(null),this._unsubscribeAll.complete()}_updateLayout(){let d=this._activatedRoute;for(;d.firstChild;)d=d.firstChild;this.layout=this.config.layout;const _=d.snapshot.queryParamMap.get("layout");_&&(this.layout=_,this.config&&(this.config.layout=_)),d.pathFromRoot.forEach(V=>{V.routeConfig&&V.routeConfig.data&&V.routeConfig.data.layout&&(this.layout=V.routeConfig.data.layout)})}_updateScheme(){this._document.body.classList.remove("light","dark"),this._document.body.classList.add(this.scheme)}_updateTheme(){this._document.body.classList.forEach(d=>{d.startsWith("theme-")&&this._document.body.classList.remove(d,d.split("-")[1])}),this._document.body.classList.add(this.theme)}static{this.\u0275fac=function(_){return new(_||v)(c.rXU(a.nX),c.rXU(at.qQ),c.rXU(c.sFG),c.rXU(a.Ix),c.rXU(yy.P),c.rXU(ue.l),c.rXU(Be))}}static{this.\u0275cmp=c.VBU({type:v,selectors:[["layout"]],decls:3,vars:3,template:function(_,D){1&_&&c.DNE(0,Sm,1,0,"empty-layout")(1,My,1,0,"modern-layout")(2,ky,1,0,"classic-layout"),2&_&&(c.vxM("empty"===D.layout?0:-1),c.R7$(),c.vxM("modern"===D.layout?1:-1),c.R7$(),c.vxM("classic"===D.layout?2:-1))},dependencies:[Zf,Ay,Ty],styles:["layout{display:flex;flex:1 1 auto;width:100%;max-width:100%;min-width:0}layout>*{position:relative;display:flex;flex:1 1 auto;width:100%}layout router-outlet+*{position:relative;display:flex;flex:1 1 auto;width:100%}\n"],encapsulation:2})}}return v})();const ld=()=>{const v=(0,c.WQX)(Vd.A),m=(0,c.WQX)(a.Ix);return""!==v.getPublicKey()||m.parseUrl("/login")},Tm=[{path:"",pathMatch:"full",redirectTo:"home"},{path:"project/:pubkey",pathMatch:"full",redirectTo:"explore"},{path:"login-redirect",pathMatch:"full",redirectTo:"explore"},{path:"",component:Sc,data:{layout:"empty"},children:[{path:"login",loadChildren:()=>Promise.all([r.e(87),r.e(232)]).then(r.bind(r,6232))},{path:"create",loadChildren:()=>Promise.all([r.e(87),r.e(664)]).then(r.bind(r,9664))}]},{path:"",canActivate:[ld],canActivateChild:[ld],component:Sc,data:{layout:"empty"},children:[{path:"logout",loadChildren:()=>r.e(957).then(r.bind(r,7957))}]},{path:"",canActivate:[ld],canActivateChild:[ld],component:Sc,resolve:{initialData:()=>{const v=(0,c.WQX)(wa);return(0,c.WQX)(Vc),(0,Uc.p)([v.get()])}},children:[{path:"home",loadChildren:()=>Promise.all([r.e(859),r.e(523),r.e(900),r.e(836)]).then(r.bind(r,836))},{path:"explore",loadChildren:()=>Promise.all([r.e(371),r.e(76),r.e(907)]).then(r.bind(r,8288))},{path:"zap",loadChildren:()=>Promise.all([r.e(859),r.e(785)]).then(r.bind(r,8166))},{path:"bookmark",loadChildren:()=>Promise.all([r.e(371),r.e(76),r.e(767)]).then(r.bind(r,6767))},{path:"profile",loadChildren:()=>Promise.all([r.e(859),r.e(523),r.e(371),r.e(556),r.e(900),r.e(76),r.e(394)]).then(r.bind(r,5394))},{path:"profile/:pubkey",loadChildren:()=>Promise.all([r.e(859),r.e(523),r.e(371),r.e(556),r.e(900),r.e(76),r.e(394)]).then(r.bind(r,5394))},{path:"post",loadChildren:()=>Promise.all([r.e(859),r.e(523),r.e(556),r.e(900),r.e(544)]).then(r.bind(r,6544))},{path:"post/:id",loadChildren:()=>Promise.all([r.e(859),r.e(523),r.e(556),r.e(900),r.e(544)]).then(r.bind(r,6544))},{path:"settings",loadChildren:()=>Promise.all([r.e(859),r.e(371),r.e(76),r.e(126)]).then(r.bind(r,6126))},{path:"settings/:id",loadChildren:()=>Promise.all([r.e(859),r.e(371),r.e(76),r.e(126)]).then(r.bind(r,6126))},{path:"chat",loadChildren:()=>Promise.all([r.e(859),r.e(523),r.e(556),r.e(512)]).then(r.bind(r,1512))},{path:"404-not-found",pathMatch:"full",loadChildren:()=>r.e(256).then(r.bind(r,9256))},{path:"**",redirectTo:"404-not-found"}]}];let Kd=(()=>{class v{constructor(){const d=(0,c.WQX)(i.up),_=(0,c.WQX)(il.tp);_.addSvgIconSet(d.bypassSecurityTrustResourceUrl("icons/material-twotone.svg")),_.addSvgIconSetInNamespace("mat_outline",d.bypassSecurityTrustResourceUrl("icons/material-outline.svg")),_.addSvgIconSetInNamespace("mat_solid",d.bypassSecurityTrustResourceUrl("icons/material-solid.svg")),_.addSvgIconSetInNamespace("feather",d.bypassSecurityTrustResourceUrl("icons/feather.svg")),_.addSvgIconSetInNamespace("heroicons_outline",d.bypassSecurityTrustResourceUrl("icons/heroicons-outline.svg")),_.addSvgIconSetInNamespace("heroicons_solid",d.bypassSecurityTrustResourceUrl("icons/heroicons-solid.svg")),_.addSvgIconSetInNamespace("heroicons_mini",d.bypassSecurityTrustResourceUrl("icons/heroicons-mini.svg"))}static{this.\u0275fac=function(_){return new(_||v)}}static{this.\u0275prov=c.jDH({token:v,factory:v.\u0275fac,providedIn:"root"})}}return v})();var Oy=r(8747),Pw=r(1540);let Mm=(()=>{class v{constructor(d){this.httpClient=d}getTranslation(d){return this.httpClient.get(`./i18n/${d}.json`)}static{this.\u0275fac=function(_){return new(_||v)(c.KVO(re.Qq))}}static{this.\u0275prov=c.jDH({token:v,factory:v.\u0275fac,providedIn:"root"})}}return v})();const l_=[{id:"home",title:"Home",type:"basic",icon:"heroicons_outline:home",link:"/home"},{id:"explore",title:"Explore",type:"basic",icon:"heroicons_outline:magnifying-glass",link:"/explore"},{id:"bookmark",title:"Bookmark",type:"basic",icon:"heroicons_outline:bookmark",link:"/bookmark"},{id:"chat",title:"Chat",type:"basic",icon:"heroicons_outline:chat-bubble-left-right",link:"/chat",badge:{title:"0",classes:"px-2 bg-[#086c81] text-white rounded-full"}},{id:"profile",title:"Profile",type:"basic",icon:"heroicons_outline:user",link:"/profile"},{id:"settings",title:"Settings",type:"basic",icon:"heroicons_outline:cog-6-tooth",link:"/settings"}],c_=[{id:"home",title:"Home",type:"basic",icon:"heroicons_outline:home",link:"/home"},{id:"explore",title:"Explore",type:"basic",icon:"heroicons_outline:magnifying-glass",link:"/explore"},{id:"bookmark",title:"Bookmark",type:"basic",icon:"heroicons_outline:bookmark",link:"/bookmark"},{id:"chat",title:"Chat",type:"basic",icon:"heroicons_outline:chat-bubble-left-right",link:"/chat",badge:{title:"27",classes:"px-2 bg-[#086c81] text-white rounded-full"}},{id:"profile",title:"Profile",type:"basic",icon:"heroicons_outline:user",link:"/profile"},{id:"settings",title:"Settings",type:"basic",icon:"heroicons_outline:cog-6-tooth",link:"/settings"}];var u_=r(1238);var Ny=r(2065),lp=r(101),Ly=r(6259),Py=r(1561);const Fy=(0,r(5717).A)(Object.keys,Object);var Uy=Object.prototype.hasOwnProperty;var Vy=r(2808);const km=function d_(v){return(0,Vy.A)(v)?(0,Ly.A)(v):function $y(v){if(!(0,Py.A)(v))return Fy(v);var m=[];for(var d in Object(v))Uy.call(v,d)&&"constructor"!=d&&m.push(d);return m}(v)};var Im=r(3959);var sf=r(4224),h_=r(1369);const zy=function Fw(){return[]};var Om=Object.prototype.propertyIsEnumerable,up=Object.getOwnPropertySymbols;const m_=up?function(v){return null==v?[]:(v=Object(v),function f_(v,m){for(var d=-1,_=null==v?0:v.length,D=0,V=[];++d<_;){var J=v[d];m(J,d,v)&&(V[D++]=J)}return V}(up(v),function(m){return Om.call(v,m)}))}:zy,__=function Gy(v,m){for(var d=-1,_=m.length,D=v.length;++d<_;)v[D+d]=m[d];return v};var Xy=r(5749);const Rm=Object.getOwnPropertySymbols?function(v){for(var m=[];v;)__(m,m_(v)),v=(0,Xy.A)(v);return m}:zy;var Nm=r(9007);const Lm=function dp(v,m,d){var _=m(v);return(0,Nm.A)(v)?_:__(_,d(v))},qy=function Pm(v){return Lm(v,km,m_)},y_=function ud(v){return Lm(v,Im.A,Rm)};var hp=r(3121),Xd=r(9311);const Bm=(0,hp.A)(Xd.A,"DataView");var Um=r(2769);const $m=(0,hp.A)(Xd.A,"Promise"),w_=(0,hp.A)(Xd.A,"Set"),dd=(0,hp.A)(Xd.A,"WeakMap");var E_=r(5688),Yd=r(4435),x_="[object Map]",D_="[object Promise]",A_="[object Set]",S_="[object WeakMap]",T_="[object DataView]",eb=(0,Yd.A)(Bm),tb=(0,Yd.A)(Um.A),jm=(0,Yd.A)($m),jw=(0,Yd.A)(w_),Vw=(0,Yd.A)(dd),Yc=E_.A;(Bm&&Yc(new Bm(new ArrayBuffer(1)))!=T_||Um.A&&Yc(new Um.A)!=x_||$m&&Yc($m.resolve())!=D_||w_&&Yc(new w_)!=A_||dd&&Yc(new dd)!=S_)&&(Yc=function(v){var m=(0,E_.A)(v),d="[object Object]"==m?v.constructor:void 0,_=d?(0,Yd.A)(d):"";if(_)switch(_){case eb:return T_;case tb:return x_;case jm:return D_;case jw:return A_;case Vw:return S_}return m});const M_=Yc;var Ww=Object.prototype.hasOwnProperty;var k_=r(3031);var I_=/\w*$/;var N_=r(4883),L_=N_.A?N_.A.prototype:void 0,Vm=L_?L_.valueOf:void 0;var P_=r(7383);const ob=function j_(v,m,d){var _=v.constructor;switch(m){case"[object ArrayBuffer]":return(0,k_.A)(v);case"[object Boolean]":case"[object Date]":return new _(+v);case"[object DataView]":return function fp(v,m){var d=m?(0,k_.A)(v.buffer):v.buffer;return new v.constructor(d,v.byteOffset,v.byteLength)}(v,d);case"[object Float32Array]":case"[object Float64Array]":case"[object Int8Array]":case"[object Int16Array]":case"[object Int32Array]":case"[object Uint8Array]":case"[object Uint8ClampedArray]":case"[object Uint16Array]":case"[object Uint32Array]":return(0,P_.A)(v,d);case"[object Map]":case"[object Set]":return new _;case"[object Number]":case"[object String]":return new _(v);case"[object RegExp]":return function O_(v){var m=new v.constructor(v.source,I_.exec(v));return m.lastIndex=v.lastIndex,m}(v);case"[object Symbol]":return function Qd(v){return Vm?Object(Vm.call(v)):{}}(v)}};var sb=r(223),V_=r(5303),_p=r(2312);var H_=r(4975),vp=r(8583),yp=vp.A&&vp.A.isMap;const hd=yp?(0,H_.A)(yp):function lf(v){return(0,_p.A)(v)&&"[object Map]"==M_(v)};var z_=r(7999);var Ym=vp.A&&vp.A.isSet;const X_=Ym?(0,H_.A)(Ym):function Xm(v){return(0,_p.A)(v)&&"[object Set]"==M_(v)};var Iu="[object Arguments]",wp="[object Function]",J_="[object Object]",ss={};ss[Iu]=ss["[object Array]"]=ss["[object ArrayBuffer]"]=ss["[object DataView]"]=ss["[object Boolean]"]=ss["[object Date]"]=ss["[object Float32Array]"]=ss["[object Float64Array]"]=ss["[object Int8Array]"]=ss["[object Int16Array]"]=ss["[object Int32Array]"]=ss["[object Map]"]=ss["[object Number]"]=ss[J_]=ss["[object RegExp]"]=ss["[object Set]"]=ss["[object String]"]=ss["[object Symbol]"]=ss["[object Uint8Array]"]=ss["[object Uint8ClampedArray]"]=ss["[object Uint16Array]"]=ss["[object Uint32Array]"]=!0,ss["[object Error]"]=ss[wp]=ss["[object WeakMap]"]=!1;const yb=function uf(v,m,d,_,D,V){var J,we=1&m,Xe=2&m,yt=4&m;if(d&&(J=D?d(v,_,D,V):d(v)),void 0!==J)return J;if(!(0,z_.A)(v))return v;var un=(0,Nm.A)(v);if(un){if(J=function zw(v){var m=v.length,d=new v.constructor(m);return m&&"string"==typeof v[0]&&Ww.call(v,"index")&&(d.index=v.index,d.input=v.input),d}(v),!we)return(0,h_.A)(v,J)}else{var _n=M_(v),gr=_n==wp||"[object GeneratorFunction]"==_n;if((0,V_.A)(v))return(0,sf.A)(v,we);if(_n==J_||_n==Iu||gr&&!D){if(J=Xe||gr?{}:(0,sb.A)(v),!we)return Xe?function Qy(v,m){return(0,lp.A)(v,Rm(v),m)}(v,function cp(v,m){return v&&(0,lp.A)(m,(0,Im.A)(m),v)}(J,v)):function g_(v,m){return(0,lp.A)(v,m_(v),m)}(v,function Hy(v,m){return v&&(0,lp.A)(m,km(m),v)}(J,v))}else{if(!ss[_n])return D?v:{};J=ob(v,_n,we)}}V||(V=new u_.A);var er=V.get(v);if(er)return er;V.set(v,J),X_(v)?v.forEach(function(Ai){J.add(uf(Ai,m,d,Ai,v,V))}):hd(v)&&v.forEach(function(Ai,ko){J.set(ko,uf(Ai,m,d,ko,v,V))});var ti=un?void 0:(yt?Xe?y_:qy:Xe?Im.A:km)(v);return function cd(v,m){for(var d=-1,_=null==v?0:v.length;++d<_&&!1!==m(v[d],d,v););}(ti||v,function(Ai,ko){ti&&(Ai=v[ko=Ai]),(0,Ny.A)(J,ko,uf(Ai,m,d,ko,v,V))}),J},xp=function $i(v){return yb(v,5)},qd=[(()=>{class v{constructor(d){this._angorMockApiService=d,this._defaultNavigation=l_,this._horizontalNavigation=c_,this.registerHandlers()}registerHandlers(){this._angorMockApiService.onGet("api/navigation").reply(()=>(this._horizontalNavigation.forEach(d=>{this._defaultNavigation.forEach(_=>{_.id===d.id&&(d.children=xp(_.children))})}),[200,{default:xp(this._defaultNavigation),horizontal:xp(this._horizontalNavigation)}]))}static{this.\u0275fac=function(_){return new(_||v)(c.KVO(q))}}static{this.\u0275prov=c.jDH({token:v,factory:v.\u0275fac,providedIn:"root"})}}return v})()];let iv=(()=>{class v{constructor(d){this.http=d,this.timestamp=null,this.ngswFilePath="/ngsw.json"}load(){var d=this;return(0,w.A)(function*(){try{const _=yield d.http.get(d.ngswFilePath).toPromise();_&&_.timestamp?(d.timestamp=_.timestamp,console.log("Timestamp successfully loaded:",d.timestamp)):console.error("Invalid data format in ngsw.json")}catch(_){console.error("Error loading ngsw.json:",_)}})()}getTimestamp(){return this.timestamp}loadHash(){return this.http.get(this.ngswFilePath).pipe((0,Os.T)(d=>d.timestamp||null),(0,fm.W)(d=>(console.error("Error fetching ngsw.json hash:",d),(0,T.$)(()=>new Error("Failed to load hash.")))))}static{this.\u0275fac=function(_){return new(_||v)(c.KVO(re.Qq))}}static{this.\u0275prov=c.jDH({token:v,factory:v.\u0275fac,providedIn:"root"})}}return v})();var Jm=r(6433),xb=r(3024);const hf={providers:[function Lf(){return(0,c.ngT)("NgEagerAnimations"),[...Rh]}(),(0,re.$R)(),function rd(v,m={}){return(0,c.EmA)([Bf,Ld,{provide:Ph,useValue:v},{provide:va,useValue:m},{provide:xu,useFactory:$f,deps:[va,c.Agw]},{provide:c.hnV,useFactory:Fh,deps:[c.zZn,Ph,va,c.Agw],multi:!0}])}("ngsw-worker.js",{enabled:!(0,c.naY)(),registrationStrategy:"registerWhenStable:30000"}),{provide:c.hnV,useFactory:function eg(v){return()=>v.load()},deps:[iv,Vd.A,Jm.d],multi:!0},{provide:c.hnV,useFactory:function df(v,m){return(0,w.A)(function*(){const d=v.getPublicKey();d&&(yield m.loadUserProfile(d))})},deps:[Vd.A,Jm.d],multi:!0},{provide:c.hnV,useFactory:function fd(){return()=>{(0,xb.Ts)({theme:"ocean",noBanner:!0,title:"Angor Hub",onAuth:(v,m)=>{}})}},multi:!0},(0,a.lh)(Tm,(0,a.oH)({scrollPositionRestoration:"enabled"})),{provide:rn.MJ,useClass:Yl},{provide:rn.de,useValue:{parse:{dateInput:"D"},display:{dateInput:"DDD",monthYearLabel:"LLL yyyy",dateA11yLabel:"DD",monthYearA11yLabel:"LLLL yyyy"}}},function ei(v){const m=[hr(Qf),mi(Du),yr(sd),Yr(E)];return v.config&&m.push(function eo(v){return(0,c.EmA)([{provide:$c,useValue:Yf(v)}])}(v.config)),v.loader&&m.push(function to(v){return(0,c.EmA)([{provide:Hf,useClass:v}])}(v.loader)),m}({config:{availableLangs:[{id:"en",label:"English"}],defaultLang:"en",fallbackLang:"en",reRenderOnLangChange:!0,prodMode:!0},loader:Mm}),{provide:c.hnV,useFactory:()=>{const v=(0,c.WQX)(Yt),m=v.getDefaultLang();return v.setActiveLang(m),()=>function ap(v,m){const d="object"==typeof m;return new Promise((_,D)=>{const V=new Pw.Ms({next:J=>{_(J),V.unsubscribe()},error:D,complete:()=>{d?_(m.defaultValue):D(new Oy.G)}});v.subscribe(V)})}(v.load(m))},multi:!0},[{provide:c.Z63,useValue:()=>(0,c.WQX)(Kd),multi:!0}],(v=>{const m=[{provide:rn.N,useValue:{doctype:!0,theme:!1,version:!0}},{provide:bn.U$,useValue:{appearance:"fill"}},{provide:C,useValue:v?.mockApi?.delay??0},{provide:me.t,useValue:v?.angor??{}},(0,c.oKB)(gn.hM),{provide:c.Z63,useValue:()=>(0,c.WQX)(be.m),multi:!0},(0,re.$R)((0,re.b$)([ce])),{provide:c.Z63,useValue:()=>(0,c.WQX)(xe),multi:!0},{provide:c.Z63,useValue:()=>(0,c.WQX)(ue.l),multi:!0},{provide:c.Z63,useValue:()=>(0,c.WQX)(Be),multi:!0},{provide:c.Z63,useValue:()=>(0,c.WQX)(bt),multi:!0},{provide:c.Z63,useValue:()=>(0,c.WQX)(lt.Q),multi:!0}];return v?.mockApi?.services&&m.push((0,re.$R)((0,re.b$)([ae])),{provide:c.hnV,deps:[...v.mockApi.services],useFactory:()=>()=>null,multi:!0}),m})({mockApi:{delay:0,services:qd},angor:JSON.parse(localStorage.getItem("angorConfig"))??{layout:"classic",scheme:"light",screens:{sm:"600px",md:"960px",lg:"1280px",xl:"1440px"},theme:"theme-brand",themes:[{id:"theme-brand",name:"Brand"},{id:"theme-default",name:"Default"},{id:"theme-teal",name:"Teal"},{id:"theme-rose",name:"Rose"},{id:"theme-purple",name:"Purple"},{id:"theme-amber",name:"Amber"}]}})]};(0,i.B8)(y,hf).catch(v=>console.error(v))},9566:(o,s)=>{"use strict";s.byteLength=function T(q){var re=C(q),se=re[1];return 3*(re[0]+se)/4-se},s.toByteArray=function M(q){var re,xe,pe=C(q),se=pe[0],ae=pe[1],me=new a(function S(q,re,pe){return 3*(re+pe)/4-pe}(0,se,ae)),be=0,Oe=ae>0?se-4:se;for(xe=0;xe>16&255,me[be++]=re>>8&255,me[be++]=255&re;return 2===ae&&(re=i[q.charCodeAt(xe)]<<2|i[q.charCodeAt(xe+1)]>>4,me[be++]=255&re),1===ae&&(re=i[q.charCodeAt(xe)]<<10|i[q.charCodeAt(xe+1)]<<4|i[q.charCodeAt(xe+2)]>>2,me[be++]=re>>8&255,me[be++]=255&re),me},s.fromByteArray=function Z(q){for(var re,pe=q.length,se=pe%3,ae=[],be=0,Oe=pe-se;beOe?Oe:be+16383));return 1===se?ae.push(r[(re=q[pe-1])>>2]+r[re<<4&63]+"=="):2===se&&ae.push(r[(re=(q[pe-2]<<8)+q[pe-1])>>10]+r[re>>4&63]+r[re<<2&63]+"="),ae.join("")};for(var r=[],i=[],a=typeof Uint8Array<"u"?Uint8Array:Array,c="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/",y=0;y<64;++y)r[y]=c[y],i[c.charCodeAt(y)]=y;function C(q){var re=q.length;if(re%4>0)throw new Error("Invalid string. Length must be a multiple of 4");var pe=q.indexOf("=");return-1===pe&&(pe=re),[pe,pe===re?0:4-pe%4]}function O(q){return r[q>>18&63]+r[q>>12&63]+r[q>>6&63]+r[63&q]}function L(q,re,pe){for(var ae=[],me=re;me{"use strict";const a=r(9566),c=r(9859),y="function"==typeof Symbol&&"function"==typeof Symbol.for?Symbol.for("nodejs.util.inspect.custom"):null;s.hp=S,s.IS=50;const w=2147483647;function T(z){if(z>w)throw new RangeError('The value "'+z+'" is invalid for option "size"');const N=new Uint8Array(z);return Object.setPrototypeOf(N,S.prototype),N}function S(z,N,W){if("number"==typeof z){if("string"==typeof N)throw new TypeError('The "string" argument must be of type string. Received type number');return Z(z)}return M(z,N,W)}function M(z,N,W){if("string"==typeof z)return function q(z,N){if(("string"!=typeof N||""===N)&&(N="utf8"),!S.isEncoding(N))throw new TypeError("Unknown encoding: "+N);const W=0|Oe(z,N);let Le=T(W);const ft=Le.write(z,N);return ft!==W&&(Le=Le.slice(0,ft)),Le}(z,N);if(ArrayBuffer.isView(z))return function pe(z){if(pr(z,Uint8Array)){const N=new Uint8Array(z);return se(N.buffer,N.byteOffset,N.byteLength)}return re(z)}(z);if(null==z)throw new TypeError("The first argument must be one of type string, Buffer, ArrayBuffer, Array, or Array-like Object. Received type "+typeof z);if(pr(z,ArrayBuffer)||z&&pr(z.buffer,ArrayBuffer)||typeof SharedArrayBuffer<"u"&&(pr(z,SharedArrayBuffer)||z&&pr(z.buffer,SharedArrayBuffer)))return se(z,N,W);if("number"==typeof z)throw new TypeError('The "value" argument must not be of type number. Received type number');const Le=z.valueOf&&z.valueOf();if(null!=Le&&Le!==z)return S.from(Le,N,W);const ft=function ae(z){if(S.isBuffer(z)){const N=0|me(z.length),W=T(N);return 0===W.length||z.copy(W,0,0,N),W}return void 0!==z.length?"number"!=typeof z.length||cn(z.length)?T(0):re(z):"Buffer"===z.type&&Array.isArray(z.data)?re(z.data):void 0}(z);if(ft)return ft;if(typeof Symbol<"u"&&null!=Symbol.toPrimitive&&"function"==typeof z[Symbol.toPrimitive])return S.from(z[Symbol.toPrimitive]("string"),N,W);throw new TypeError("The first argument must be one of type string, Buffer, ArrayBuffer, Array, or Array-like Object. Received type "+typeof z)}function O(z){if("number"!=typeof z)throw new TypeError('"size" argument must be of type number');if(z<0)throw new RangeError('The value "'+z+'" is invalid for option "size"')}function Z(z){return O(z),T(z<0?0:0|me(z))}function re(z){const N=z.length<0?0:0|me(z.length),W=T(N);for(let Le=0;Le=w)throw new RangeError("Attempt to allocate Buffer larger than maximum size: 0x"+w.toString(16)+" bytes");return 0|z}function Oe(z,N){if(S.isBuffer(z))return z.length;if(ArrayBuffer.isView(z)||pr(z,ArrayBuffer))return z.byteLength;if("string"!=typeof z)throw new TypeError('The "string" argument must be one of type string, Buffer, or ArrayBuffer. Received type '+typeof z);const W=z.length,Le=arguments.length>2&&!0===arguments[2];if(!Le&&0===W)return 0;let ft=!1;for(;;)switch(N){case"ascii":case"latin1":case"binary":return W;case"utf8":case"utf-8":return en(z).length;case"ucs2":case"ucs-2":case"utf16le":case"utf-16le":return 2*W;case"hex":return W>>>1;case"base64":return Nr(z).length;default:if(ft)return Le?-1:en(z).length;N=(""+N).toLowerCase(),ft=!0}}function xe(z,N,W){let Le=!1;if((void 0===N||N<0)&&(N=0),N>this.length||((void 0===W||W>this.length)&&(W=this.length),W<=0)||(W>>>=0)<=(N>>>=0))return"";for(z||(z="utf8");;)switch(z){case"hex":return qe(this,N,W);case"utf8":case"utf-8":return rn(this,N,W);case"ascii":return Vn(this,N,W);case"latin1":case"binary":return yn(this,N,W);case"base64":return lt(this,N,W);case"ucs2":case"ucs-2":case"utf16le":case"utf-16le":return _t(this,N,W);default:if(Le)throw new TypeError("Unknown encoding: "+z);z=(z+"").toLowerCase(),Le=!0}}function De(z,N,W){const Le=z[N];z[N]=z[W],z[W]=Le}function ce(z,N,W,Le,ft){if(0===z.length)return-1;if("string"==typeof W?(Le=W,W=0):W>2147483647?W=2147483647:W<-2147483648&&(W=-2147483648),cn(W=+W)&&(W=ft?0:z.length-1),W<0&&(W=z.length+W),W>=z.length){if(ft)return-1;W=z.length-1}else if(W<0){if(!ft)return-1;W=0}if("string"==typeof N&&(N=S.from(N,Le)),S.isBuffer(N))return 0===N.length?-1:ue(z,N,W,Le,ft);if("number"==typeof N)return N&=255,"function"==typeof Uint8Array.prototype.indexOf?ft?Uint8Array.prototype.indexOf.call(z,N,W):Uint8Array.prototype.lastIndexOf.call(z,N,W):ue(z,[N],W,Le,ft);throw new TypeError("val must be string, number or Buffer")}function ue(z,N,W,Le,ft){let dn,mt=1,St=z.length,Tn=N.length;if(void 0!==Le&&("ucs2"===(Le=String(Le).toLowerCase())||"ucs-2"===Le||"utf16le"===Le||"utf-16le"===Le)){if(z.length<2||N.length<2)return-1;mt=2,St/=2,Tn/=2,W/=2}function an(In,sr){return 1===mt?In[sr]:In.readUInt16BE(sr*mt)}if(ft){let In=-1;for(dn=W;dnSt&&(W=St-Tn),dn=W;dn>=0;dn--){let In=!0;for(let sr=0;srft&&(Le=ft):Le=ft;const mt=N.length;let St;for(Le>mt/2&&(Le=mt/2),St=0;St>8,ft=W%256,mt.push(ft),mt.push(Le);return mt}(N,z.length-W),z,W,Le)}function lt(z,N,W){return a.fromByteArray(0===N&&W===z.length?z:z.slice(N,W))}function rn(z,N,W){W=Math.min(z.length,W);const Le=[];let ft=N;for(;ft239?4:mt>223?3:mt>191?2:1;if(ft+Tn<=W){let an,dn,In,sr;switch(Tn){case 1:mt<128&&(St=mt);break;case 2:an=z[ft+1],128==(192&an)&&(sr=(31&mt)<<6|63&an,sr>127&&(St=sr));break;case 3:an=z[ft+1],dn=z[ft+2],128==(192&an)&&128==(192&dn)&&(sr=(15&mt)<<12|(63&an)<<6|63&dn,sr>2047&&(sr<55296||sr>57343)&&(St=sr));break;case 4:an=z[ft+1],dn=z[ft+2],In=z[ft+3],128==(192&an)&&128==(192&dn)&&128==(192&In)&&(sr=(15&mt)<<18|(63&an)<<12|(63&dn)<<6|63&In,sr>65535&&sr<1114112&&(St=sr))}}null===St?(St=65533,Tn=1):St>65535&&(St-=65536,Le.push(St>>>10&1023|55296),St=56320|1023&St),Le.push(St),ft+=Tn}return function bn(z){const N=z.length;if(N<=gn)return String.fromCharCode.apply(String,z);let W="",Le=0;for(;Left.length?(S.isBuffer(St)||(St=S.from(St)),St.copy(ft,mt)):Uint8Array.prototype.set.call(ft,St,mt);else{if(!S.isBuffer(St))throw new TypeError('"list" argument must be an Array of Buffers');St.copy(ft,mt)}mt+=St.length}return ft},S.byteLength=Oe,S.prototype._isBuffer=!0,S.prototype.swap16=function(){const N=this.length;if(N%2!=0)throw new RangeError("Buffer size must be a multiple of 16-bits");for(let W=0;WW&&(N+=" ... "),""},y&&(S.prototype[y]=S.prototype.inspect),S.prototype.compare=function(N,W,Le,ft,mt){if(pr(N,Uint8Array)&&(N=S.from(N,N.offset,N.byteLength)),!S.isBuffer(N))throw new TypeError('The "target" argument must be one of type Buffer or Uint8Array. Received type '+typeof N);if(void 0===W&&(W=0),void 0===Le&&(Le=N?N.length:0),void 0===ft&&(ft=0),void 0===mt&&(mt=this.length),W<0||Le>N.length||ft<0||mt>this.length)throw new RangeError("out of range index");if(ft>=mt&&W>=Le)return 0;if(ft>=mt)return-1;if(W>=Le)return 1;if(this===N)return 0;let St=(mt>>>=0)-(ft>>>=0),Tn=(Le>>>=0)-(W>>>=0);const an=Math.min(St,Tn),dn=this.slice(ft,mt),In=N.slice(W,Le);for(let sr=0;sr>>=0,isFinite(Le)?(Le>>>=0,void 0===ft&&(ft="utf8")):(ft=Le,Le=void 0)}const mt=this.length-W;if((void 0===Le||Le>mt)&&(Le=mt),N.length>0&&(Le<0||W<0)||W>this.length)throw new RangeError("Attempt to write outside buffer bounds");ft||(ft="utf8");let St=!1;for(;;)switch(ft){case"hex":return Ce(this,N,W,Le);case"utf8":case"utf-8":return Be(this,N,W,Le);case"ascii":case"latin1":case"binary":return at(this,N,W,Le);case"base64":return dt(this,N,W,Le);case"ucs2":case"ucs-2":case"utf16le":case"utf-16le":return bt(this,N,W,Le);default:if(St)throw new TypeError("Unknown encoding: "+ft);ft=(""+ft).toLowerCase(),St=!0}},S.prototype.toJSON=function(){return{type:"Buffer",data:Array.prototype.slice.call(this._arr||this,0)}};const gn=4096;function Vn(z,N,W){let Le="";W=Math.min(z.length,W);for(let ft=N;ftLe)&&(W=Le);let ft="";for(let mt=N;mtW)throw new RangeError("Trying to access beyond buffer length")}function $e(z,N,W,Le,ft,mt){if(!S.isBuffer(z))throw new TypeError('"buffer" argument must be a Buffer instance');if(N>ft||Nz.length)throw new RangeError("Index out of range")}function Ft(z,N,W,Le,ft){Xt(N,Le,ft,z,W,7);let mt=Number(N&BigInt(4294967295));z[W++]=mt,mt>>=8,z[W++]=mt,mt>>=8,z[W++]=mt,mt>>=8,z[W++]=mt;let St=Number(N>>BigInt(32)&BigInt(4294967295));return z[W++]=St,St>>=8,z[W++]=St,St>>=8,z[W++]=St,St>>=8,z[W++]=St,W}function Ke(z,N,W,Le,ft){Xt(N,Le,ft,z,W,7);let mt=Number(N&BigInt(4294967295));z[W+7]=mt,mt>>=8,z[W+6]=mt,mt>>=8,z[W+5]=mt,mt>>=8,z[W+4]=mt;let St=Number(N>>BigInt(32)&BigInt(4294967295));return z[W+3]=St,St>>=8,z[W+2]=St,St>>=8,z[W+1]=St,St>>=8,z[W]=St,W+8}function Ze(z,N,W,Le,ft,mt){if(W+Le>z.length)throw new RangeError("Index out of range");if(W<0)throw new RangeError("Index out of range")}function it(z,N,W,Le,ft){return N=+N,W>>>=0,ft||Ze(z,0,W,4),c.write(z,N,W,Le,23,4),W+4}function Ot(z,N,W,Le,ft){return N=+N,W>>>=0,ft||Ze(z,0,W,8),c.write(z,N,W,Le,52,8),W+8}S.prototype.slice=function(N,W){const Le=this.length;(N=~~N)<0?(N+=Le)<0&&(N=0):N>Le&&(N=Le),(W=void 0===W?Le:~~W)<0?(W+=Le)<0&&(W=0):W>Le&&(W=Le),W>>=0,W>>>=0,Le||ze(N,W,this.length);let ft=this[N],mt=1,St=0;for(;++St>>=0,W>>>=0,Le||ze(N,W,this.length);let ft=this[N+--W],mt=1;for(;W>0&&(mt*=256);)ft+=this[N+--W]*mt;return ft},S.prototype.readUint8=S.prototype.readUInt8=function(N,W){return N>>>=0,W||ze(N,1,this.length),this[N]},S.prototype.readUint16LE=S.prototype.readUInt16LE=function(N,W){return N>>>=0,W||ze(N,2,this.length),this[N]|this[N+1]<<8},S.prototype.readUint16BE=S.prototype.readUInt16BE=function(N,W){return N>>>=0,W||ze(N,2,this.length),this[N]<<8|this[N+1]},S.prototype.readUint32LE=S.prototype.readUInt32LE=function(N,W){return N>>>=0,W||ze(N,4,this.length),(this[N]|this[N+1]<<8|this[N+2]<<16)+16777216*this[N+3]},S.prototype.readUint32BE=S.prototype.readUInt32BE=function(N,W){return N>>>=0,W||ze(N,4,this.length),16777216*this[N]+(this[N+1]<<16|this[N+2]<<8|this[N+3])},S.prototype.readBigUInt64LE=ke(function(N){Mt(N>>>=0,"offset");const W=this[N],Le=this[N+7];(void 0===W||void 0===Le)&&Kt(N,this.length-8);const ft=W+256*this[++N]+65536*this[++N]+this[++N]*2**24,mt=this[++N]+256*this[++N]+65536*this[++N]+Le*2**24;return BigInt(ft)+(BigInt(mt)<>>=0,"offset");const W=this[N],Le=this[N+7];(void 0===W||void 0===Le)&&Kt(N,this.length-8);const ft=W*2**24+65536*this[++N]+256*this[++N]+this[++N],mt=this[++N]*2**24+65536*this[++N]+256*this[++N]+Le;return(BigInt(ft)<>>=0,W>>>=0,Le||ze(N,W,this.length);let ft=this[N],mt=1,St=0;for(;++St=mt&&(ft-=Math.pow(2,8*W)),ft},S.prototype.readIntBE=function(N,W,Le){N>>>=0,W>>>=0,Le||ze(N,W,this.length);let ft=W,mt=1,St=this[N+--ft];for(;ft>0&&(mt*=256);)St+=this[N+--ft]*mt;return mt*=128,St>=mt&&(St-=Math.pow(2,8*W)),St},S.prototype.readInt8=function(N,W){return N>>>=0,W||ze(N,1,this.length),128&this[N]?-1*(255-this[N]+1):this[N]},S.prototype.readInt16LE=function(N,W){N>>>=0,W||ze(N,2,this.length);const Le=this[N]|this[N+1]<<8;return 32768&Le?4294901760|Le:Le},S.prototype.readInt16BE=function(N,W){N>>>=0,W||ze(N,2,this.length);const Le=this[N+1]|this[N]<<8;return 32768&Le?4294901760|Le:Le},S.prototype.readInt32LE=function(N,W){return N>>>=0,W||ze(N,4,this.length),this[N]|this[N+1]<<8|this[N+2]<<16|this[N+3]<<24},S.prototype.readInt32BE=function(N,W){return N>>>=0,W||ze(N,4,this.length),this[N]<<24|this[N+1]<<16|this[N+2]<<8|this[N+3]},S.prototype.readBigInt64LE=ke(function(N){Mt(N>>>=0,"offset");const W=this[N],Le=this[N+7];return(void 0===W||void 0===Le)&&Kt(N,this.length-8),(BigInt(this[N+4]+256*this[N+5]+65536*this[N+6]+(Le<<24))<>>=0,"offset");const W=this[N],Le=this[N+7];(void 0===W||void 0===Le)&&Kt(N,this.length-8);const ft=(W<<24)+65536*this[++N]+256*this[++N]+this[++N];return(BigInt(ft)<>>=0,W||ze(N,4,this.length),c.read(this,N,!0,23,4)},S.prototype.readFloatBE=function(N,W){return N>>>=0,W||ze(N,4,this.length),c.read(this,N,!1,23,4)},S.prototype.readDoubleLE=function(N,W){return N>>>=0,W||ze(N,8,this.length),c.read(this,N,!0,52,8)},S.prototype.readDoubleBE=function(N,W){return N>>>=0,W||ze(N,8,this.length),c.read(this,N,!1,52,8)},S.prototype.writeUintLE=S.prototype.writeUIntLE=function(N,W,Le,ft){N=+N,W>>>=0,Le>>>=0,ft||$e(this,N,W,Le,Math.pow(2,8*Le)-1,0);let mt=1,St=0;for(this[W]=255&N;++St>>=0,Le>>>=0,ft||$e(this,N,W,Le,Math.pow(2,8*Le)-1,0);let mt=Le-1,St=1;for(this[W+mt]=255&N;--mt>=0&&(St*=256);)this[W+mt]=N/St&255;return W+Le},S.prototype.writeUint8=S.prototype.writeUInt8=function(N,W,Le){return N=+N,W>>>=0,Le||$e(this,N,W,1,255,0),this[W]=255&N,W+1},S.prototype.writeUint16LE=S.prototype.writeUInt16LE=function(N,W,Le){return N=+N,W>>>=0,Le||$e(this,N,W,2,65535,0),this[W]=255&N,this[W+1]=N>>>8,W+2},S.prototype.writeUint16BE=S.prototype.writeUInt16BE=function(N,W,Le){return N=+N,W>>>=0,Le||$e(this,N,W,2,65535,0),this[W]=N>>>8,this[W+1]=255&N,W+2},S.prototype.writeUint32LE=S.prototype.writeUInt32LE=function(N,W,Le){return N=+N,W>>>=0,Le||$e(this,N,W,4,4294967295,0),this[W+3]=N>>>24,this[W+2]=N>>>16,this[W+1]=N>>>8,this[W]=255&N,W+4},S.prototype.writeUint32BE=S.prototype.writeUInt32BE=function(N,W,Le){return N=+N,W>>>=0,Le||$e(this,N,W,4,4294967295,0),this[W]=N>>>24,this[W+1]=N>>>16,this[W+2]=N>>>8,this[W+3]=255&N,W+4},S.prototype.writeBigUInt64LE=ke(function(N,W=0){return Ft(this,N,W,BigInt(0),BigInt("0xffffffffffffffff"))}),S.prototype.writeBigUInt64BE=ke(function(N,W=0){return Ke(this,N,W,BigInt(0),BigInt("0xffffffffffffffff"))}),S.prototype.writeIntLE=function(N,W,Le,ft){if(N=+N,W>>>=0,!ft){const an=Math.pow(2,8*Le-1);$e(this,N,W,Le,an-1,-an)}let mt=0,St=1,Tn=0;for(this[W]=255&N;++mt>>=0,!ft){const an=Math.pow(2,8*Le-1);$e(this,N,W,Le,an-1,-an)}let mt=Le-1,St=1,Tn=0;for(this[W+mt]=255&N;--mt>=0&&(St*=256);)N<0&&0===Tn&&0!==this[W+mt+1]&&(Tn=1),this[W+mt]=(N/St|0)-Tn&255;return W+Le},S.prototype.writeInt8=function(N,W,Le){return N=+N,W>>>=0,Le||$e(this,N,W,1,127,-128),N<0&&(N=255+N+1),this[W]=255&N,W+1},S.prototype.writeInt16LE=function(N,W,Le){return N=+N,W>>>=0,Le||$e(this,N,W,2,32767,-32768),this[W]=255&N,this[W+1]=N>>>8,W+2},S.prototype.writeInt16BE=function(N,W,Le){return N=+N,W>>>=0,Le||$e(this,N,W,2,32767,-32768),this[W]=N>>>8,this[W+1]=255&N,W+2},S.prototype.writeInt32LE=function(N,W,Le){return N=+N,W>>>=0,Le||$e(this,N,W,4,2147483647,-2147483648),this[W]=255&N,this[W+1]=N>>>8,this[W+2]=N>>>16,this[W+3]=N>>>24,W+4},S.prototype.writeInt32BE=function(N,W,Le){return N=+N,W>>>=0,Le||$e(this,N,W,4,2147483647,-2147483648),N<0&&(N=4294967295+N+1),this[W]=N>>>24,this[W+1]=N>>>16,this[W+2]=N>>>8,this[W+3]=255&N,W+4},S.prototype.writeBigInt64LE=ke(function(N,W=0){return Ft(this,N,W,-BigInt("0x8000000000000000"),BigInt("0x7fffffffffffffff"))}),S.prototype.writeBigInt64BE=ke(function(N,W=0){return Ke(this,N,W,-BigInt("0x8000000000000000"),BigInt("0x7fffffffffffffff"))}),S.prototype.writeFloatLE=function(N,W,Le){return it(this,N,W,!0,Le)},S.prototype.writeFloatBE=function(N,W,Le){return it(this,N,W,!1,Le)},S.prototype.writeDoubleLE=function(N,W,Le){return Ot(this,N,W,!0,Le)},S.prototype.writeDoubleBE=function(N,W,Le){return Ot(this,N,W,!1,Le)},S.prototype.copy=function(N,W,Le,ft){if(!S.isBuffer(N))throw new TypeError("argument should be a Buffer");if(Le||(Le=0),!ft&&0!==ft&&(ft=this.length),W>=N.length&&(W=N.length),W||(W=0),ft>0&&ft=this.length)throw new RangeError("Index out of range");if(ft<0)throw new RangeError("sourceEnd out of bounds");ft>this.length&&(ft=this.length),N.length-W>>=0,Le=void 0===Le?this.length:Le>>>0,N||(N=0),"number"==typeof N)for(mt=W;mt=Le+4;W-=3)N=`_${z.slice(W-3,W)}${N}`;return`${z.slice(0,W)}${N}`}function Xt(z,N,W,Le,ft,mt){if(z>W||z3?0===N||N===BigInt(0)?`>= 0${St} and < 2${St} ** ${8*(mt+1)}${St}`:`>= -(2${St} ** ${8*(mt+1)-1}${St}) and < 2 ** ${8*(mt+1)-1}${St}`:`>= ${N}${St} and <= ${W}${St}`,new $t.ERR_OUT_OF_RANGE("value",Tn,z)}!function st(z,N,W){Mt(N,"offset"),(void 0===z[N]||void 0===z[N+W])&&Kt(N,z.length-(W+1))}(Le,ft,mt)}function Mt(z,N){if("number"!=typeof z)throw new $t.ERR_INVALID_ARG_TYPE(N,"number",z)}function Kt(z,N,W){throw Math.floor(z)!==z?(Mt(z,W),new $t.ERR_OUT_OF_RANGE(W||"offset","an integer",z)):N<0?new $t.ERR_BUFFER_OUT_OF_BOUNDS:new $t.ERR_OUT_OF_RANGE(W||"offset",`>= ${W?1:0} and <= ${N}`,z)}Te("ERR_BUFFER_OUT_OF_BOUNDS",function(z){return z?`${z} is outside of buffer bounds`:"Attempt to access memory outside buffer bounds"},RangeError),Te("ERR_INVALID_ARG_TYPE",function(z,N){return`The "${z}" argument must be of type number. Received type ${typeof N}`},TypeError),Te("ERR_OUT_OF_RANGE",function(z,N,W){let Le=`The value of "${z}" is out of range.`,ft=W;return Number.isInteger(W)&&Math.abs(W)>2**32?ft=Ee(String(W)):"bigint"==typeof W&&(ft=String(W),(W>BigInt(2)**BigInt(32)||W<-(BigInt(2)**BigInt(32)))&&(ft=Ee(ft)),ft+="n"),Le+=` It must be ${N}. Received ${ft}`,Le},RangeError);const rt=/[^+/0-9A-Za-z-_]/g;function en(z,N){let W;N=N||1/0;const Le=z.length;let ft=null;const mt=[];for(let St=0;St55295&&W<57344){if(!ft){if(W>56319){(N-=3)>-1&&mt.push(239,191,189);continue}if(St+1===Le){(N-=3)>-1&&mt.push(239,191,189);continue}ft=W;continue}if(W<56320){(N-=3)>-1&&mt.push(239,191,189),ft=W;continue}W=65536+(ft-55296<<10|W-56320)}else ft&&(N-=3)>-1&&mt.push(239,191,189);if(ft=null,W<128){if((N-=1)<0)break;mt.push(W)}else if(W<2048){if((N-=2)<0)break;mt.push(W>>6|192,63&W|128)}else if(W<65536){if((N-=3)<0)break;mt.push(W>>12|224,W>>6&63|128,63&W|128)}else{if(!(W<1114112))throw new Error("Invalid code point");if((N-=4)<0)break;mt.push(W>>18|240,W>>12&63|128,W>>6&63|128,63&W|128)}}return mt}function Nr(z){return a.toByteArray(function Vt(z){if((z=(z=z.split("=")[0]).trim().replace(rt,"")).length<2)return"";for(;z.length%4!=0;)z+="=";return z}(z))}function Rn(z,N,W,Le){let ft;for(ft=0;ft=N.length||ft>=z.length);++ft)N[ft+W]=z[ft];return ft}function pr(z,N){return z instanceof N||null!=z&&null!=z.constructor&&null!=z.constructor.name&&z.constructor.name===N.name}function cn(z){return z!=z}const Fe=function(){const z="0123456789abcdef",N=new Array(256);for(let W=0;W<16;++W){const Le=16*W;for(let ft=0;ft<16;++ft)N[Le+ft]=z[W]+z[ft]}return N}();function ke(z){return typeof BigInt>"u"?Je:z}function Je(){throw new Error("BigInt not supported")}},9859:(o,s)=>{s.read=function(r,i,a,c,y){var w,C,T=8*y-c-1,S=(1<>1,O=-7,L=a?y-1:0,Z=a?-1:1,q=r[i+L];for(L+=Z,w=q&(1<<-O)-1,q>>=-O,O+=T;O>0;w=256*w+r[i+L],L+=Z,O-=8);for(C=w&(1<<-O)-1,w>>=-O,O+=c;O>0;C=256*C+r[i+L],L+=Z,O-=8);if(0===w)w=1-M;else{if(w===S)return C?NaN:1/0*(q?-1:1);C+=Math.pow(2,c),w-=M}return(q?-1:1)*C*Math.pow(2,w-c)},s.write=function(r,i,a,c,y,w){var C,T,S,M=8*w-y-1,O=(1<>1,Z=23===y?Math.pow(2,-24)-Math.pow(2,-77):0,q=c?0:w-1,re=c?1:-1,pe=i<0||0===i&&1/i<0?1:0;for(i=Math.abs(i),isNaN(i)||i===1/0?(T=isNaN(i)?1:0,C=O):(C=Math.floor(Math.log(i)/Math.LN2),i*(S=Math.pow(2,-C))<1&&(C--,S*=2),(i+=C+L>=1?Z/S:Z*Math.pow(2,1-L))*S>=2&&(C++,S/=2),C+L>=O?(T=0,C=O):C+L>=1?(T=(i*S-1)*Math.pow(2,y),C+=L):(T=i*Math.pow(2,L-1)*Math.pow(2,y),C=0));y>=8;r[a+q]=255&T,q+=re,T/=256,y-=8);for(C=C<0;r[a+q]=255&C,q+=re,C/=256,M-=8);r[a+q-re]|=128*pe}},230:o=>{o.exports=function a(c,y,w){function C(M,O){if(!y[M]){if(!c[M]){if(T)return T(M,!0);var Z=new Error("Cannot find module '"+M+"'");throw Z.code="MODULE_NOT_FOUND",Z}var q=y[M]={exports:{}};c[M][0].call(q.exports,function(re){return C(c[M][1][re]||re)},q,q.exports,a,c,y,w)}return y[M].exports}for(var T=void 0,S=0;S"u"&&a(3);var L=Promise;function Z(ve,Ye){Ye&&ve.then(function(Ne){Ye(null,Ne)},function(Ne){Ye(Ne)})}function q(ve,Ye,Ne){"function"==typeof Ye&&ve.then(Ye),"function"==typeof Ne&&ve.catch(Ne)}function re(ve){return"string"!=typeof ve&&(console.warn(ve+" used as a key, but it is not a string."),ve=String(ve)),ve}function pe(){if(arguments.length&&"function"==typeof arguments[arguments.length-1])return arguments[arguments.length-1]}var se="local-forage-detect-blob-support",ae=void 0,me={},be=Object.prototype.toString,Oe="readonly",xe="readwrite";function De(ve){for(var Ye=ve.length,Ne=new ArrayBuffer(Ye),gt=new Uint8Array(Ne),Ht=0;Ht=43)}}).catch(function(){return!1})}(ve).then(function(Ye){return ae=Ye})}function Ce(ve){var Ye=me[ve.name],Ne={};Ne.promise=new L(function(gt,Ht){Ne.resolve=gt,Ne.reject=Ht}),Ye.deferredOperations.push(Ne),Ye.dbReady=Ye.dbReady?Ye.dbReady.then(function(){return Ne.promise}):Ne.promise}function Be(ve){var Ne=me[ve.name].deferredOperations.pop();if(Ne)return Ne.resolve(),Ne.promise}function at(ve,Ye){var gt=me[ve.name].deferredOperations.pop();if(gt)return gt.reject(Ye),gt.promise}function dt(ve,Ye){return new L(function(Ne,gt){if(me[ve.name]=me[ve.name]||{forages:[],db:null,dbReady:null,deferredOperations:[]},ve.db){if(!Ye)return Ne(ve.db);Ce(ve),ve.db.close()}var Ht=[ve.name];Ye&&Ht.push(ve.version);var kt=S.open.apply(S,Ht);Ye&&(kt.onupgradeneeded=function(hn){var Dn=kt.result;try{Dn.createObjectStore(ve.storeName),hn.oldVersion<=1&&Dn.createObjectStore(se)}catch(Cn){if("ConstraintError"!==Cn.name)throw Cn;console.warn('The database "'+ve.name+'" has been upgraded from version '+hn.oldVersion+" to version "+hn.newVersion+', but the storage "'+ve.storeName+'" already exists.')}}),kt.onerror=function(hn){hn.preventDefault(),gt(kt.error)},kt.onsuccess=function(){var hn=kt.result;hn.onversionchange=function(Dn){Dn.target.close()},Ne(hn),Be(ve)}})}function bt(ve){return dt(ve,!1)}function lt(ve){return dt(ve,!0)}function rn(ve,Ye){if(!ve.db)return!0;var Ne=!ve.db.objectStoreNames.contains(ve.storeName),Ht=ve.version>ve.db.version;if(ve.versionve.version&&(ve.version=kt)}return!0}return!1}function bn(ve){return O([De(atob(ve.data))],{type:ve.type})}function Vn(ve){return ve&&ve.__local_forage_encoded_blob}function yn(ve){var Ye=this,Ne=Ye._initReady().then(function(){var gt=me[Ye._dbInfo.name];if(gt&>.dbReady)return gt.dbReady});return q(Ne,ve,ve),Ne}function _t(ve,Ye,Ne,gt){void 0===gt&&(gt=1);try{var Ht=ve.db.transaction(ve.storeName,Ye);Ne(null,Ht)}catch(kt){if(gt>0&&(!ve.db||"InvalidStateError"===kt.name||"NotFoundError"===kt.name))return L.resolve().then(function(){if(!ve.db||"NotFoundError"===kt.name&&!ve.db.objectStoreNames.contains(ve.storeName)&&ve.version<=ve.db.version)return ve.db&&(ve.version=ve.db.version+1),lt(ve)}).then(function(){return function qe(ve){Ce(ve);for(var Ye=me[ve.name],Ne=Ye.forages,gt=0;gt>4,jn[Ht++]=(15&hn)<<4|Dn>>2,jn[Ht++]=(3&Dn)<<6|63&Cn;return Nn}function St(ve){var gt,Ye=new Uint8Array(ve),Ne="";for(gt=0;gt>2],Ne+=Kt[(3&Ye[gt])<<4|Ye[gt+1]>>4],Ne+=Kt[(15&Ye[gt+1])<<2|Ye[gt+2]>>6],Ne+=Kt[63&Ye[gt+2]];return Ye.length%3==2?Ne=Ne.substring(0,Ne.length-1)+"=":Ye.length%3==1&&(Ne=Ne.substring(0,Ne.length-2)+"=="),Ne}var dn={serialize:function Tn(ve,Ye){var Ne="";if(ve&&(Ne=ft.call(ve)),ve&&("[object ArrayBuffer]"===Ne||ve.buffer&&"[object ArrayBuffer]"===ft.call(ve.buffer))){var gt,Ht=en;ve instanceof ArrayBuffer?(gt=ve,Ht+=Kn):(gt=ve.buffer,"[object Int8Array]"===Ne?Ht+="si08":"[object Uint8Array]"===Ne?Ht+="ui08":"[object Uint8ClampedArray]"===Ne?Ht+="uic8":"[object Int16Array]"===Ne?Ht+="si16":"[object Uint16Array]"===Ne?Ht+="ur16":"[object Int32Array]"===Ne?Ht+="si32":"[object Uint32Array]"===Ne?Ht+=z:"[object Float32Array]"===Ne?Ht+=N:"[object Float64Array]"===Ne?Ht+=W:Ye(new Error("Failed to get type for BinaryArray"))),Ye(Ht+St(gt))}else if("[object Blob]"===Ne){var kt=new FileReader;kt.onload=function(){var hn="~~local_forage_type~"+ve.type+"~"+St(this.result);Ye(en+Nr+hn)},kt.readAsArrayBuffer(ve)}else try{Ye(JSON.stringify(ve))}catch(hn){console.error("Couldn't convert value into a JSON string: ",ve),Ye(null,hn)}},deserialize:function an(ve){if(ve.substring(0,9)!==en)return JSON.parse(ve);var gt,Ye=ve.substring(13),Ne=ve.substring(9,13);if(Ne===Nr&&Vt.test(Ye)){var Ht=Ye.match(Vt);gt=Ht[1],Ye=Ye.substring(Ht[0].length)}var kt=mt(Ye);switch(Ne){case Kn:return kt;case Nr:return O([kt],{type:gt});case"si08":return new Int8Array(kt);case"ui08":return new Uint8Array(kt);case"uic8":return new Uint8ClampedArray(kt);case"si16":return new Int16Array(kt);case"ur16":return new Uint16Array(kt);case"si32":return new Int32Array(kt);case z:return new Uint32Array(kt);case N:return new Float32Array(kt);case W:return new Float64Array(kt);default:throw new Error("Unkown type: "+Ne)}},stringToBuffer:mt,bufferToString:St};function In(ve,Ye,Ne,gt){ve.executeSql("CREATE TABLE IF NOT EXISTS "+Ye.storeName+" (id INTEGER PRIMARY KEY, key unique, value)",[],Ne,gt)}function xn(ve,Ye,Ne,gt,Ht,kt){ve.executeSql(Ne,gt,Ht,function(hn,Dn){Dn.code===Dn.SYNTAX_ERR?hn.executeSql("SELECT name FROM sqlite_master WHERE type='table' AND name = ?",[Ye.storeName],function(Cn,Nn){Nn.rows.length?kt(Cn,Dn):In(Cn,Ye,function(){Cn.executeSql(Ne,gt,Ht,kt)},kt)},kt):kt(hn,Dn)},kt)}function Vr(ve,Ye,Ne,gt){var Ht=this;ve=re(ve);var kt=new L(function(hn,Dn){Ht.ready().then(function(){void 0===Ye&&(Ye=null);var Cn=Ye,Nn=Ht._dbInfo;Nn.serializer.serialize(Ye,function(jn,Jn){Jn?Dn(Jn):Nn.db.transaction(function(ar){xn(ar,Nn,"INSERT OR REPLACE INTO "+Nn.storeName+" (key, value) VALUES (?, ?)",[ve,jn],function(){hn(Cn)},function(wr,xr){Dn(xr)})},function(ar){if(ar.code===ar.QUOTA_ERR){if(gt>0)return void hn(Vr.apply(Ht,[ve,Cn,Ne,gt-1]));Dn(ar)}})})}).catch(Dn)});return Z(kt,Ne),kt}var wn={_driver:"webSQLStorage",_initStorage:function sr(ve){var Ye=this,Ne={db:null};if(ve)for(var gt in ve)Ne[gt]="string"!=typeof ve[gt]?ve[gt].toString():ve[gt];var Ht=new L(function(kt,hn){try{Ne.db=openDatabase(Ne.name,String(Ne.version),Ne.description,Ne.size)}catch(Dn){return hn(Dn)}Ne.db.transaction(function(Dn){In(Dn,Ne,function(){Ye._dbInfo=Ne,kt()},function(Cn,Nn){hn(Nn)})},hn)});return Ne.serializer=dn,Ht},_support:function Mt(){return"function"==typeof openDatabase}(),iterate:function Tr(ve,Ye){var Ne=this,gt=new L(function(Ht,kt){Ne.ready().then(function(){var hn=Ne._dbInfo;hn.db.transaction(function(Dn){xn(Dn,hn,"SELECT * FROM "+hn.storeName,[],function(Cn,Nn){for(var jn=Nn.rows,Jn=jn.length,ar=0;ar '__WebKitDatabaseInfoTable__'",[],function(Ht,kt){for(var hn=[],Dn=0;Dn0}var ds={_driver:"localStorageWrapper",_initStorage:function Zi(ve){var Ne={};if(ve)for(var gt in ve)Ne[gt]=ve[gt];return Ne.keyPrefix=Er(ve,this._defaultConfig),hi()?(this._dbInfo=Ne,Ne.serializer=dn,L.resolve()):L.reject()},_support:function qn(){try{return typeof localStorage<"u"&&"setItem"in localStorage&&!!localStorage.setItem}catch{return!1}}(),iterate:function nt(ve,Ye){var Ne=this,gt=Ne.ready().then(function(){for(var Ht=Ne._dbInfo,kt=Ht.keyPrefix,hn=kt.length,Dn=localStorage.length,Cn=1,Nn=0;Nn=0;Ht--){var kt=localStorage.key(Ht);0===kt.indexOf(gt)&&localStorage.removeItem(kt)}});return Z(Ne,ve),Ne},length:function mn(ve){var Ne=this.keys().then(function(gt){return gt.length});return Z(Ne,ve),Ne},key:function Rt(ve,Ye){var Ne=this,gt=Ne.ready().then(function(){var kt,Ht=Ne._dbInfo;try{kt=localStorage.key(ve)}catch{kt=null}return kt&&(kt=kt.substring(Ht.keyPrefix.length)),kt});return Z(gt,Ye),gt},keys:function sn(ve){var Ye=this,Ne=Ye.ready().then(function(){for(var gt=Ye._dbInfo,Ht=localStorage.length,kt=[],hn=0;hn=0;hn--){var Dn=localStorage.key(hn);0===Dn.indexOf(kt)&&localStorage.removeItem(Dn)}}):L.reject("Invalid arguments"),Ye),Ht}},$o=function(Ye,Ne){return Ye===Ne||"number"==typeof Ye&&"number"==typeof Ne&&isNaN(Ye)&&isNaN(Ne)},ai=function(Ye,Ne){for(var gt=Ye.length,Ht=0;Ht"u"?"undefined":w(Ne))){if(this._ready)return new Error("Can't call config() after localforage has been used.");for(var gt in Ne){if("storeName"===gt&&(Ne[gt]=Ne[gt].replace(/\W/g,"_")),"version"===gt&&"number"!=typeof Ne[gt])return new Error("Database version must be a number.");this._config[gt]=Ne[gt]}return!("driver"in Ne)||!Ne.driver||this.setDriver(this._config.driver)}return"string"==typeof Ne?this._config[Ne]:this._config},ve.prototype.defineDriver=function(Ne,gt,Ht){var kt=new L(function(hn,Dn){try{var Cn=Ne._driver,Nn=new Error("Custom driver not compliant; see https://mozilla.github.io/localForage/#definedriver");if(!Ne._driver)return void Dn(Nn);for(var jn=po.concat("_initStorage"),Jn=0,ar=jn.length;Jn{"use strict";r.d(s,{t:()=>a});var i=r(8447);class a extends i.B{constructor(y){super(),this._value=y}get value(){return this.getValue()}_subscribe(y){const w=super._subscribe(y);return!w.closed&&y.next(this._value),w}getValue(){const{hasError:y,thrownError:w,_value:C}=this;if(y)throw w;return this._throwIfClosed(),C}next(y){super.next(this._value=y)}}},1698:(o,s,r)=>{"use strict";r.d(s,{c:()=>S});var i=r(1540),a=r(5710),c=r(2563),y=r(6742),w=r(3305),C=r(1126),T=r(4171);let S=(()=>{class Z{constructor(re){re&&(this._subscribe=re)}lift(re){const pe=new Z;return pe.source=this,pe.operator=re,pe}subscribe(re,pe,se){const ae=function L(Z){return Z&&Z instanceof i.vU||function O(Z){return Z&&(0,C.T)(Z.next)&&(0,C.T)(Z.error)&&(0,C.T)(Z.complete)}(Z)&&(0,a.Uv)(Z)}(re)?re:new i.Ms(re,pe,se);return(0,T.Y)(()=>{const{operator:me,source:be}=this;ae.add(me?me.call(ae,be):be?this._subscribe(ae):this._trySubscribe(ae))}),ae}_trySubscribe(re){try{return this._subscribe(re)}catch(pe){re.error(pe)}}forEach(re,pe){return new(pe=M(pe))((se,ae)=>{const me=new i.Ms({next:be=>{try{re(be)}catch(Oe){ae(Oe),me.unsubscribe()}},error:ae,complete:se});this.subscribe(me)})}_subscribe(re){var pe;return null===(pe=this.source)||void 0===pe?void 0:pe.subscribe(re)}[c.s](){return this}pipe(...re){return(0,y.m)(re)(this)}toPromise(re){return new(re=M(re))((pe,se)=>{let ae;this.subscribe(me=>ae=me,me=>se(me),()=>pe(ae))})}}return Z.create=q=>new Z(q),Z})();function M(Z){var q;return null!==(q=Z??w.$.Promise)&&void 0!==q?q:Promise}},7838:(o,s,r)=>{"use strict";r.d(s,{m:()=>c});var i=r(8447),a=r(6188);class c extends i.B{constructor(w=1/0,C=1/0,T=a.U){super(),this._bufferSize=w,this._windowTime=C,this._timestampProvider=T,this._buffer=[],this._infiniteTimeWindow=!0,this._infiniteTimeWindow=C===1/0,this._bufferSize=Math.max(1,w),this._windowTime=Math.max(1,C)}next(w){const{isStopped:C,_buffer:T,_infiniteTimeWindow:S,_timestampProvider:M,_windowTime:O}=this;C||(T.push(w),!S&&T.push(M.now()+O)),this._trimBuffer(),super.next(w)}_subscribe(w){this._throwIfClosed(),this._trimBuffer();const C=this._innerSubscribe(w),{_infiniteTimeWindow:T,_buffer:S}=this,M=S.slice();for(let O=0;O{"use strict";r.d(s,{B:()=>T});var i=r(1698),a=r(5710);const y=(0,r(5644).L)(M=>function(){M(this),this.name="ObjectUnsubscribedError",this.message="object unsubscribed"});var w=r(5891),C=r(4171);let T=(()=>{class M extends i.c{constructor(){super(),this.closed=!1,this.currentObservers=null,this.observers=[],this.isStopped=!1,this.hasError=!1,this.thrownError=null}lift(L){const Z=new S(this,this);return Z.operator=L,Z}_throwIfClosed(){if(this.closed)throw new y}next(L){(0,C.Y)(()=>{if(this._throwIfClosed(),!this.isStopped){this.currentObservers||(this.currentObservers=Array.from(this.observers));for(const Z of this.currentObservers)Z.next(L)}})}error(L){(0,C.Y)(()=>{if(this._throwIfClosed(),!this.isStopped){this.hasError=this.isStopped=!0,this.thrownError=L;const{observers:Z}=this;for(;Z.length;)Z.shift().error(L)}})}complete(){(0,C.Y)(()=>{if(this._throwIfClosed(),!this.isStopped){this.isStopped=!0;const{observers:L}=this;for(;L.length;)L.shift().complete()}})}unsubscribe(){this.isStopped=this.closed=!0,this.observers=this.currentObservers=null}get observed(){var L;return(null===(L=this.observers)||void 0===L?void 0:L.length)>0}_trySubscribe(L){return this._throwIfClosed(),super._trySubscribe(L)}_subscribe(L){return this._throwIfClosed(),this._checkFinalizedStatuses(L),this._innerSubscribe(L)}_innerSubscribe(L){const{hasError:Z,isStopped:q,observers:re}=this;return Z||q?a.Kn:(this.currentObservers=null,re.push(L),new a.yU(()=>{this.currentObservers=null,(0,w.o)(re,L)}))}_checkFinalizedStatuses(L){const{hasError:Z,thrownError:q,isStopped:re}=this;Z?L.error(q):re&&L.complete()}asObservable(){const L=new i.c;return L.source=this,L}}return M.create=(O,L)=>new S(O,L),M})();class S extends T{constructor(O,L){super(),this.destination=O,this.source=L}next(O){var L,Z;null===(Z=null===(L=this.destination)||void 0===L?void 0:L.next)||void 0===Z||Z.call(L,O)}error(O){var L,Z;null===(Z=null===(L=this.destination)||void 0===L?void 0:L.error)||void 0===Z||Z.call(L,O)}complete(){var O,L;null===(L=null===(O=this.destination)||void 0===O?void 0:O.complete)||void 0===L||L.call(O)}_subscribe(O){var L,Z;return null!==(Z=null===(L=this.source)||void 0===L?void 0:L.subscribe(O))&&void 0!==Z?Z:a.Kn}}},1540:(o,s,r)=>{"use strict";r.d(s,{Ms:()=>se,vU:()=>Z});var i=r(1126),a=r(5710),c=r(3305),y=r(191),w=r(850);const C=M("C",void 0,void 0);function M(xe,De,ce){return{kind:xe,value:De,error:ce}}var O=r(3695),L=r(4171);class Z extends a.yU{constructor(De){super(),this.isStopped=!1,De?(this.destination=De,(0,a.Uv)(De)&&De.add(this)):this.destination=Oe}static create(De,ce,ue){return new se(De,ce,ue)}next(De){this.isStopped?be(function S(xe){return M("N",xe,void 0)}(De),this):this._next(De)}error(De){this.isStopped?be(function T(xe){return M("E",void 0,xe)}(De),this):(this.isStopped=!0,this._error(De))}complete(){this.isStopped?be(C,this):(this.isStopped=!0,this._complete())}unsubscribe(){this.closed||(this.isStopped=!0,super.unsubscribe(),this.destination=null)}_next(De){this.destination.next(De)}_error(De){try{this.destination.error(De)}finally{this.unsubscribe()}}_complete(){try{this.destination.complete()}finally{this.unsubscribe()}}}const q=Function.prototype.bind;function re(xe,De){return q.call(xe,De)}class pe{constructor(De){this.partialObserver=De}next(De){const{partialObserver:ce}=this;if(ce.next)try{ce.next(De)}catch(ue){ae(ue)}}error(De){const{partialObserver:ce}=this;if(ce.error)try{ce.error(De)}catch(ue){ae(ue)}else ae(De)}complete(){const{partialObserver:De}=this;if(De.complete)try{De.complete()}catch(ce){ae(ce)}}}class se extends Z{constructor(De,ce,ue){let Ce;if(super(),(0,i.T)(De)||!De)Ce={next:De??void 0,error:ce??void 0,complete:ue??void 0};else{let Be;this&&c.$.useDeprecatedNextContext?(Be=Object.create(De),Be.unsubscribe=()=>this.unsubscribe(),Ce={next:De.next&&re(De.next,Be),error:De.error&&re(De.error,Be),complete:De.complete&&re(De.complete,Be)}):Ce=De}this.destination=new pe(Ce)}}function ae(xe){c.$.useDeprecatedSynchronousErrorHandling?(0,L.l)(xe):(0,y.m)(xe)}function be(xe,De){const{onStoppedNotification:ce}=c.$;ce&&O.f.setTimeout(()=>ce(xe,De))}const Oe={closed:!0,next:w.l,error:function me(xe){throw xe},complete:w.l}},5710:(o,s,r)=>{"use strict";r.d(s,{Kn:()=>C,yU:()=>w,Uv:()=>T});var i=r(1126);const c=(0,r(5644).L)(M=>function(L){M(this),this.message=L?`${L.length} errors occurred during unsubscription:\n${L.map((Z,q)=>`${q+1}) ${Z.toString()}`).join("\n ")}`:"",this.name="UnsubscriptionError",this.errors=L});var y=r(5891);class w{constructor(O){this.initialTeardown=O,this.closed=!1,this._parentage=null,this._finalizers=null}unsubscribe(){let O;if(!this.closed){this.closed=!0;const{_parentage:L}=this;if(L)if(this._parentage=null,Array.isArray(L))for(const re of L)re.remove(this);else L.remove(this);const{initialTeardown:Z}=this;if((0,i.T)(Z))try{Z()}catch(re){O=re instanceof c?re.errors:[re]}const{_finalizers:q}=this;if(q){this._finalizers=null;for(const re of q)try{S(re)}catch(pe){O=O??[],pe instanceof c?O=[...O,...pe.errors]:O.push(pe)}}if(O)throw new c(O)}}add(O){var L;if(O&&O!==this)if(this.closed)S(O);else{if(O instanceof w){if(O.closed||O._hasParent(this))return;O._addParent(this)}(this._finalizers=null!==(L=this._finalizers)&&void 0!==L?L:[]).push(O)}}_hasParent(O){const{_parentage:L}=this;return L===O||Array.isArray(L)&&L.includes(O)}_addParent(O){const{_parentage:L}=this;this._parentage=Array.isArray(L)?(L.push(O),L):L?[L,O]:O}_removeParent(O){const{_parentage:L}=this;L===O?this._parentage=null:Array.isArray(L)&&(0,y.o)(L,O)}remove(O){const{_finalizers:L}=this;L&&(0,y.o)(L,O),O instanceof w&&O._removeParent(this)}}w.EMPTY=(()=>{const M=new w;return M.closed=!0,M})();const C=w.EMPTY;function T(M){return M instanceof w||M&&"closed"in M&&(0,i.T)(M.remove)&&(0,i.T)(M.add)&&(0,i.T)(M.unsubscribe)}function S(M){(0,i.T)(M)?M():M.unsubscribe()}},3305:(o,s,r)=>{"use strict";r.d(s,{$:()=>i});const i={onUnhandledError:null,onStoppedNotification:null,Promise:void 0,useDeprecatedSynchronousErrorHandling:!1,useDeprecatedNextContext:!1}},1642:(o,s,r)=>{"use strict";r.d(s,{G:()=>C});var i=r(1698),a=r(5710),c=r(3589),y=r(2483),w=r(5351);class C extends i.c{constructor(S,M){super(),this.source=S,this.subjectFactory=M,this._subject=null,this._refCount=0,this._connection=null,(0,w.S)(S)&&(this.lift=S.lift)}_subscribe(S){return this.getSubject().subscribe(S)}getSubject(){const S=this._subject;return(!S||S.isStopped)&&(this._subject=this.subjectFactory()),this._subject}_teardown(){this._refCount=0;const{_connection:S}=this;this._subject=this._connection=null,S?.unsubscribe()}connect(){let S=this._connection;if(!S){S=this._connection=new a.yU;const M=this.getSubject();S.add(this.source.subscribe((0,y._)(M,void 0,()=>{this._teardown(),M.complete()},O=>{this._teardown(),M.error(O)},()=>this._teardown()))),S.closed&&(this._connection=null,S=a.yU.EMPTY)}return S}refCount(){return(0,c.B)()(this)}}},6627:(o,s,r)=>{"use strict";r.d(s,{z:()=>O});var i=r(1698),a=r(3740),c=r(1787),y=r(9220),w=r(3759),C=r(4327),T=r(9321),S=r(2483),M=r(8266);function O(...q){const re=(0,C.lI)(q),pe=(0,C.ms)(q),{args:se,keys:ae}=(0,a.D)(q);if(0===se.length)return(0,c.H)([],re);const me=new i.c(function L(q,re,pe=y.D){return se=>{Z(re,()=>{const{length:ae}=q,me=new Array(ae);let be=ae,Oe=ae;for(let xe=0;xe{const De=(0,c.H)(q[xe],re);let ce=!1;De.subscribe((0,S._)(se,ue=>{me[xe]=ue,ce||(ce=!0,Oe--),Oe||se.next(pe(me.slice()))},()=>{--be||se.complete()}))},se)},se)}}(se,re,ae?be=>(0,T.e)(ae,be):y.D));return pe?me.pipe((0,w.I)(pe)):me}function Z(q,re,pe){q?(0,M.N)(pe,q,re):re()}},3569:(o,s,r)=>{"use strict";r.d(s,{x:()=>w});var i=r(1890),c=r(4327),y=r(1787);function w(...C){return function a(){return(0,i.U)(1)}()((0,y.H)(C,(0,c.lI)(C)))}},6381:(o,s,r)=>{"use strict";r.d(s,{v:()=>c});var i=r(1698),a=r(7225);function c(y){return new i.c(w=>{(0,a.Tg)(y()).subscribe(w)})}},6564:(o,s,r)=>{"use strict";r.d(s,{w:()=>a});const a=new(r(1698).c)(w=>w.complete())},2653:(o,s,r)=>{"use strict";r.d(s,{p:()=>S});var i=r(1698),a=r(3740),c=r(7225),y=r(4327),w=r(2483),C=r(3759),T=r(9321);function S(...M){const O=(0,y.ms)(M),{args:L,keys:Z}=(0,a.D)(M),q=new i.c(re=>{const{length:pe}=L;if(!pe)return void re.complete();const se=new Array(pe);let ae=pe,me=pe;for(let be=0;be{Oe||(Oe=!0,me--),se[be]=xe},()=>ae--,void 0,()=>{(!ae||!Oe)&&(me||re.next(Z?(0,T.e)(Z,se):se),re.complete())}))}});return O?q.pipe((0,C.I)(O)):q}},1787:(o,s,r)=>{"use strict";r.d(s,{H:()=>ue});var i=r(7225),a=r(8266),c=r(5351),y=r(2483);function w(Ce,Be=0){return(0,c.N)((at,dt)=>{at.subscribe((0,y._)(dt,bt=>(0,a.N)(dt,Ce,()=>dt.next(bt),Be),()=>(0,a.N)(dt,Ce,()=>dt.complete(),Be),bt=>(0,a.N)(dt,Ce,()=>dt.error(bt),Be)))})}function C(Ce,Be=0){return(0,c.N)((at,dt)=>{dt.add(Ce.schedule(()=>at.subscribe(dt),Be))})}var M=r(1698),L=r(6952),Z=r(1126);function re(Ce,Be){if(!Ce)throw new Error("Iterable cannot be null");return new M.c(at=>{(0,a.N)(at,Be,()=>{const dt=Ce[Symbol.asyncIterator]();(0,a.N)(at,Be,()=>{dt.next().then(bt=>{bt.done?at.complete():at.next(bt.value)})},0,!0)})})}var pe=r(6600),se=r(6505),ae=r(6786),me=r(4876),be=r(8394),Oe=r(8810),xe=r(3173);function ue(Ce,Be){return Be?function ce(Ce,Be){if(null!=Ce){if((0,pe.l)(Ce))return function T(Ce,Be){return(0,i.Tg)(Ce).pipe(C(Be),w(Be))}(Ce,Be);if((0,ae.X)(Ce))return function O(Ce,Be){return new M.c(at=>{let dt=0;return Be.schedule(function(){dt===Ce.length?at.complete():(at.next(Ce[dt++]),at.closed||this.schedule())})})}(Ce,Be);if((0,se.y)(Ce))return function S(Ce,Be){return(0,i.Tg)(Ce).pipe(C(Be),w(Be))}(Ce,Be);if((0,be.T)(Ce))return re(Ce,Be);if((0,me.x)(Ce))return function q(Ce,Be){return new M.c(at=>{let dt;return(0,a.N)(at,Be,()=>{dt=Ce[L.l](),(0,a.N)(at,Be,()=>{let bt,lt;try{({value:bt,done:lt}=dt.next())}catch(rn){return void at.error(rn)}lt?at.complete():at.next(bt)},0,!0)}),()=>(0,Z.T)(dt?.return)&&dt.return()})}(Ce,Be);if((0,xe.U)(Ce))return function De(Ce,Be){return re((0,xe.C)(Ce),Be)}(Ce,Be)}throw(0,Oe.L)(Ce)}(Ce,Be):(0,i.Tg)(Ce)}},909:(o,s,r)=>{"use strict";r.d(s,{R:()=>O});var i=r(7225),a=r(1698),c=r(5823),y=r(6786),w=r(1126),C=r(3759);const T=["addListener","removeListener"],S=["addEventListener","removeEventListener"],M=["on","off"];function O(pe,se,ae,me){if((0,w.T)(ae)&&(me=ae,ae=void 0),me)return O(pe,se,ae).pipe((0,C.I)(me));const[be,Oe]=function re(pe){return(0,w.T)(pe.addEventListener)&&(0,w.T)(pe.removeEventListener)}(pe)?S.map(xe=>De=>pe[xe](se,De,ae)):function Z(pe){return(0,w.T)(pe.addListener)&&(0,w.T)(pe.removeListener)}(pe)?T.map(L(pe,se)):function q(pe){return(0,w.T)(pe.on)&&(0,w.T)(pe.off)}(pe)?M.map(L(pe,se)):[];if(!be&&(0,y.X)(pe))return(0,c.Z)(xe=>O(xe,se,ae))((0,i.Tg)(pe));if(!be)throw new TypeError("Invalid event target");return new a.c(xe=>{const De=(...ce)=>xe.next(1Oe(De)})}function L(pe,se){return ae=>me=>pe[ae](se,me)}},7225:(o,s,r)=>{"use strict";r.d(s,{Tg:()=>q});var i=r(1635),a=r(6786),c=r(6505),y=r(1698),w=r(6600),C=r(8394),T=r(8810),S=r(4876),M=r(3173),O=r(1126),L=r(191),Z=r(2563);function q(xe){if(xe instanceof y.c)return xe;if(null!=xe){if((0,w.l)(xe))return function re(xe){return new y.c(De=>{const ce=xe[Z.s]();if((0,O.T)(ce.subscribe))return ce.subscribe(De);throw new TypeError("Provided object does not correctly implement Symbol.observable")})}(xe);if((0,a.X)(xe))return function pe(xe){return new y.c(De=>{for(let ce=0;ce{xe.then(ce=>{De.closed||(De.next(ce),De.complete())},ce=>De.error(ce)).then(null,L.m)})}(xe);if((0,C.T)(xe))return me(xe);if((0,S.x)(xe))return function ae(xe){return new y.c(De=>{for(const ce of xe)if(De.next(ce),De.closed)return;De.complete()})}(xe);if((0,M.U)(xe))return function be(xe){return me((0,M.C)(xe))}(xe)}throw(0,T.L)(xe)}function me(xe){return new y.c(De=>{(function Oe(xe,De){var ce,ue,Ce,Be;return(0,i.sH)(this,void 0,void 0,function*(){try{for(ce=(0,i.xN)(xe);!(ue=yield ce.next()).done;)if(De.next(ue.value),De.closed)return}catch(at){Ce={error:at}}finally{try{ue&&!ue.done&&(Be=ce.return)&&(yield Be.call(ce))}finally{if(Ce)throw Ce.error}}De.complete()})})(xe,De).catch(ce=>De.error(ce))})}},7509:(o,s,r)=>{"use strict";r.d(s,{h:()=>C});var i=r(1890),a=r(7225),c=r(6564),y=r(4327),w=r(1787);function C(...T){const S=(0,y.lI)(T),M=(0,y.R0)(T,1/0),O=T;return O.length?1===O.length?(0,a.Tg)(O[0]):(0,i.U)(M)((0,w.H)(O,S)):c.w}},3016:(o,s,r)=>{"use strict";r.d(s,{of:()=>c});var i=r(4327),a=r(1787);function c(...y){const w=(0,i.lI)(y);return(0,a.H)(y,w)}},8915:(o,s,r)=>{"use strict";r.d(s,{$:()=>c});var i=r(1698),a=r(1126);function c(y,w){const C=(0,a.T)(y)?y:()=>y,T=S=>S.error(C());return new i.c(w?S=>w.schedule(T,0,S):T)}},9587:(o,s,r)=>{"use strict";r.d(s,{O:()=>w});var i=r(1698),a=r(6061),c=r(9921);function w(C=0,T,S=a.b){let M=-1;return null!=T&&((0,c.m)(T)?S=T:M=T),new i.c(O=>{let L=function y(C){return C instanceof Date&&!isNaN(C)}(C)?+C-S.now():C;L<0&&(L=0);let Z=0;return S.schedule(function(){O.closed||(O.next(Z++),0<=M?this.schedule(void 0,M):O.complete())},L)})}},2483:(o,s,r)=>{"use strict";r.d(s,{_:()=>a});var i=r(1540);function a(y,w,C,T,S){return new c(y,w,C,T,S)}class c extends i.vU{constructor(w,C,T,S,M,O){super(w),this.onFinalize=M,this.shouldUnsubscribe=O,this._next=C?function(L){try{C(L)}catch(Z){w.error(Z)}}:super._next,this._error=S?function(L){try{S(L)}catch(Z){w.error(Z)}finally{this.unsubscribe()}}:super._error,this._complete=T?function(){try{T()}catch(L){w.error(L)}finally{this.unsubscribe()}}:super._complete}unsubscribe(){var w;if(!this.shouldUnsubscribe||this.shouldUnsubscribe()){const{closed:C}=this;super.unsubscribe(),!C&&(null===(w=this.onFinalize)||void 0===w||w.call(this))}}}},5684:(o,s,r)=>{"use strict";r.d(s,{Z:()=>T});var i=r(6061),a=r(5351),c=r(7225),y=r(2483),C=r(9587);function T(S,M=i.E){return function w(S){return(0,a.N)((M,O)=>{let L=!1,Z=null,q=null,re=!1;const pe=()=>{if(q?.unsubscribe(),q=null,L){L=!1;const ae=Z;Z=null,O.next(ae)}re&&O.complete()},se=()=>{q=null,re&&O.complete()};M.subscribe((0,y._)(O,ae=>{L=!0,Z=ae,q||(0,c.Tg)(S(ae)).subscribe(q=(0,y._)(O,pe,se))},()=>{re=!0,(!L||!q||q.closed)&&O.complete()}))})}(()=>(0,C.O)(S,M))}},7178:(o,s,r)=>{"use strict";r.d(s,{W:()=>y});var i=r(7225),a=r(2483),c=r(5351);function y(w){return(0,c.N)((C,T)=>{let O,S=null,M=!1;S=C.subscribe((0,a._)(T,void 0,void 0,L=>{O=(0,i.Tg)(w(L,y(w)(C))),S?(S.unsubscribe(),S=null,O.subscribe(T)):M=!0})),M&&(S.unsubscribe(),S=null,O.subscribe(T))})}},1459:(o,s,r)=>{"use strict";r.d(s,{H:()=>c});var i=r(5823),a=r(1126);function c(y,w){return(0,a.T)(w)?(0,i.Z)(y,w,1):(0,i.Z)(y,1)}},8627:(o,s,r)=>{"use strict";r.d(s,{B:()=>y});var i=r(6061),a=r(5351),c=r(2483);function y(w,C=i.E){return(0,a.N)((T,S)=>{let M=null,O=null,L=null;const Z=()=>{if(M){M.unsubscribe(),M=null;const re=O;O=null,S.next(re)}};function q(){const re=L+w,pe=C.now();if(pe{O=re,L=C.now(),M||(M=C.schedule(q,w),S.add(M))},()=>{Z(),S.complete()},void 0,()=>{O=M=null}))})}},5670:(o,s,r)=>{"use strict";r.d(s,{U:()=>c});var i=r(5351),a=r(2483);function c(y){return(0,i.N)((w,C)=>{let T=!1;w.subscribe((0,a._)(C,S=>{T=!0,C.next(S)},()=>{T||C.next(y),C.complete()}))})}},8136:(o,s,r)=>{"use strict";r.d(s,{c:()=>q});var i=r(6061),a=r(3569),c=r(7610),y=r(5351),w=r(2483),C=r(850),S=r(6590),M=r(5823),O=r(7225);function L(re,pe){return pe?se=>(0,a.x)(pe.pipe((0,c.s)(1),function T(){return(0,y.N)((re,pe)=>{re.subscribe((0,w._)(pe,C.l))})}()),se.pipe(L(re))):(0,M.Z)((se,ae)=>(0,O.Tg)(re(se,ae)).pipe((0,c.s)(1),(0,S.u)(se)))}var Z=r(9587);function q(re,pe=i.E){const se=(0,Z.O)(re,pe);return L(()=>se)}},6645:(o,s,r)=>{"use strict";r.d(s,{F:()=>y});var i=r(9220),a=r(5351),c=r(2483);function y(C,T=i.D){return C=C??w,(0,a.N)((S,M)=>{let O,L=!0;S.subscribe((0,c._)(M,Z=>{const q=T(Z);(L||!C(O,q))&&(L=!1,O=q,M.next(Z))}))})}function w(C,T){return C===T}},1483:(o,s,r)=>{"use strict";r.d(s,{p:()=>c});var i=r(5351),a=r(2483);function c(y,w){return(0,i.N)((C,T)=>{let S=0;C.subscribe((0,a._)(T,M=>y.call(w,M,S++)&&T.next(M)))})}},4447:(o,s,r)=>{"use strict";r.d(s,{j:()=>a});var i=r(5351);function a(c){return(0,i.N)((y,w)=>{try{y.subscribe(w)}finally{w.add(c)}})}},1703:(o,s,r)=>{"use strict";r.d(s,{$:()=>T});var i=r(8747),a=r(1483),c=r(7610),y=r(5670),w=r(5017),C=r(9220);function T(S,M){const O=arguments.length>=2;return L=>L.pipe(S?(0,a.p)((Z,q)=>S(Z,q,L)):C.D,(0,c.s)(1),O?(0,y.U)(M):(0,w.v)(()=>new i.G))}},7947:(o,s,r)=>{"use strict";r.d(s,{T:()=>c});var i=r(5351),a=r(2483);function c(y,w){return(0,i.N)((C,T)=>{let S=0;C.subscribe((0,a._)(T,M=>{T.next(y.call(w,M,S++))}))})}},6590:(o,s,r)=>{"use strict";r.d(s,{u:()=>a});var i=r(7947);function a(c){return(0,i.T)(()=>c)}},1890:(o,s,r)=>{"use strict";r.d(s,{U:()=>c});var i=r(5823),a=r(9220);function c(y=1/0){return(0,i.Z)(a.D,y)}},5823:(o,s,r)=>{"use strict";r.d(s,{Z:()=>S});var i=r(7947),a=r(7225),c=r(5351),y=r(8266),w=r(2483),T=r(1126);function S(M,O,L=1/0){return(0,T.T)(O)?S((Z,q)=>(0,i.T)((re,pe)=>O(Z,re,q,pe))((0,a.Tg)(M(Z,q))),L):("number"==typeof O&&(L=O),(0,c.N)((Z,q)=>function C(M,O,L,Z,q,re,pe,se){const ae=[];let me=0,be=0,Oe=!1;const xe=()=>{Oe&&!ae.length&&!me&&O.complete()},De=ue=>me{re&&O.next(ue),me++;let Ce=!1;(0,a.Tg)(L(ue,be++)).subscribe((0,w._)(O,Be=>{q?.(Be),re?De(Be):O.next(Be)},()=>{Ce=!0},void 0,()=>{if(Ce)try{for(me--;ae.length&&mece(Be)):ce(Be)}xe()}catch(Be){O.error(Be)}}))};return M.subscribe((0,w._)(O,De,()=>{Oe=!0,xe()})),()=>{se?.()}}(Z,q,M,L)))}},3589:(o,s,r)=>{"use strict";r.d(s,{B:()=>c});var i=r(5351),a=r(2483);function c(){return(0,i.N)((y,w)=>{let C=null;y._refCount++;const T=(0,a._)(w,void 0,void 0,void 0,()=>{if(!y||y._refCount<=0||0<--y._refCount)return void(C=null);const S=y._connection,M=C;C=null,S&&(!M||S===M)&&S.unsubscribe(),w.unsubscribe()});y.subscribe(T),T.closed||(C=y.connect())})}},5903:(o,s,r)=>{"use strict";r.d(s,{L:()=>C});var i=r(5351),a=r(2483),c=r(9220),y=r(9587),w=r(7225);function C(T=1/0){let S;S=T&&"object"==typeof T?T:{count:T};const{count:M=1/0,delay:O,resetOnSuccess:L=!1}=S;return M<=0?c.D:(0,i.N)((Z,q)=>{let pe,re=0;const se=()=>{let ae=!1;pe=Z.subscribe((0,a._)(q,me=>{L&&(re=0),q.next(me)},void 0,me=>{if(re++{pe?(pe.unsubscribe(),pe=null,se()):ae=!0};if(null!=O){const Oe="number"==typeof O?(0,y.O)(O):(0,w.Tg)(O(me,re)),xe=(0,a._)(q,()=>{xe.unsubscribe(),be()},()=>{q.complete()});Oe.subscribe(xe)}else be()}else q.error(me)})),ae&&(pe.unsubscribe(),pe=null,se())};se()})}},36:(o,s,r)=>{"use strict";r.d(s,{S:()=>a});var i=r(2483);function a(c,y,w,C,T){return(S,M)=>{let O=w,L=y,Z=0;S.subscribe((0,i._)(M,q=>{const re=Z++;L=O?c(L,q,re):(O=!0,q),C&&M.next(L)},T&&(()=>{O&&M.next(L),M.complete()})))}}},6218:(o,s,r)=>{"use strict";r.d(s,{u:()=>w});var i=r(7225),a=r(8447),c=r(1540),y=r(5351);function w(T={}){const{connector:S=()=>new a.B,resetOnError:M=!0,resetOnComplete:O=!0,resetOnRefCountZero:L=!0}=T;return Z=>{let q,re,pe,se=0,ae=!1,me=!1;const be=()=>{re?.unsubscribe(),re=void 0},Oe=()=>{be(),q=pe=void 0,ae=me=!1},xe=()=>{const De=q;Oe(),De?.unsubscribe()};return(0,y.N)((De,ce)=>{se++,!me&&!ae&&be();const ue=pe=pe??S();ce.add(()=>{se--,0===se&&!me&&!ae&&(re=C(xe,L))}),ue.subscribe(ce),!q&&se>0&&(q=new c.Ms({next:Ce=>ue.next(Ce),error:Ce=>{me=!0,be(),re=C(Oe,M,Ce),ue.error(Ce)},complete:()=>{ae=!0,be(),re=C(Oe,O),ue.complete()}}),(0,i.Tg)(De).subscribe(q))})(Z)}}function C(T,S,...M){if(!0===S)return void T();if(!1===S)return;const O=new c.Ms({next:()=>{O.unsubscribe(),T()}});return(0,i.Tg)(S(...M)).subscribe(O)}},8249:(o,s,r)=>{"use strict";r.d(s,{t:()=>c});var i=r(7838),a=r(6218);function c(y,w,C){let T,S=!1;return y&&"object"==typeof y?({bufferSize:T=1/0,windowTime:w=1/0,refCount:S=!1,scheduler:C}=y):T=y??1/0,(0,a.u)({connector:()=>new i.m(T,w,C),resetOnError:!0,resetOnComplete:!1,resetOnRefCountZero:S})}},1866:(o,s,r)=>{"use strict";r.d(s,{i:()=>a});var i=r(1483);function a(c){return(0,i.p)((y,w)=>c<=w)}},593:(o,s,r)=>{"use strict";r.d(s,{Z:()=>y});var i=r(3569),a=r(4327),c=r(5351);function y(...w){const C=(0,a.lI)(w);return(0,c.N)((T,S)=>{(C?(0,i.x)(w,T,C):(0,i.x)(w,T)).subscribe(S)})}},2867:(o,s,r)=>{"use strict";r.d(s,{n:()=>y});var i=r(7225),a=r(5351),c=r(2483);function y(w,C){return(0,a.N)((T,S)=>{let M=null,O=0,L=!1;const Z=()=>L&&!M&&S.complete();T.subscribe((0,c._)(S,q=>{M?.unsubscribe();let re=0;const pe=O++;(0,i.Tg)(w(q,pe)).subscribe(M=(0,c._)(S,se=>S.next(C?C(q,se,pe,re++):se),()=>{M=null,Z()}))},()=>{L=!0,Z()}))})}},7610:(o,s,r)=>{"use strict";r.d(s,{s:()=>y});var i=r(6564),a=r(5351),c=r(2483);function y(w){return w<=0?()=>i.w:(0,a.N)((C,T)=>{let S=0;C.subscribe((0,c._)(T,M=>{++S<=w&&(T.next(M),w<=S&&T.complete())}))})}},5424:(o,s,r)=>{"use strict";r.d(s,{Q:()=>w});var i=r(5351),a=r(2483),c=r(7225),y=r(850);function w(C){return(0,i.N)((T,S)=>{(0,c.Tg)(C).subscribe((0,a._)(S,()=>S.complete(),y.l)),!S.closed&&T.subscribe(S)})}},8445:(o,s,r)=>{"use strict";r.d(s,{v:()=>c});var i=r(5351),a=r(2483);function c(y,w=!1){return(0,i.N)((C,T)=>{let S=0;C.subscribe((0,a._)(T,M=>{const O=y(M,S++);(O||w)&&T.next(M),!O&&T.complete()}))})}},2040:(o,s,r)=>{"use strict";r.d(s,{M:()=>w});var i=r(1126),a=r(5351),c=r(2483),y=r(9220);function w(C,T,S){const M=(0,i.T)(C)||T||S?{next:C,error:T,complete:S}:C;return M?(0,a.N)((O,L)=>{var Z;null===(Z=M.subscribe)||void 0===Z||Z.call(M);let q=!0;O.subscribe((0,c._)(L,re=>{var pe;null===(pe=M.next)||void 0===pe||pe.call(M,re),L.next(re)},()=>{var re;q=!1,null===(re=M.complete)||void 0===re||re.call(M),L.complete()},re=>{var pe;q=!1,null===(pe=M.error)||void 0===pe||pe.call(M,re),L.error(re)},()=>{var re,pe;q&&(null===(re=M.unsubscribe)||void 0===re||re.call(M)),null===(pe=M.finalize)||void 0===pe||pe.call(M)}))}):y.D}},5017:(o,s,r)=>{"use strict";r.d(s,{v:()=>y});var i=r(8747),a=r(5351),c=r(2483);function y(C=w){return(0,a.N)((T,S)=>{let M=!1;T.subscribe((0,c._)(S,O=>{M=!0,S.next(O)},()=>M?S.complete():S.error(C())))})}function w(){return new i.G}},9899:(o,s,r)=>{"use strict";r.d(s,{R:()=>w});var i=r(5710);class a extends i.yU{constructor(T,S){super()}schedule(T,S=0){return this}}const c={setInterval(C,T,...S){const{delegate:M}=c;return M?.setInterval?M.setInterval(C,T,...S):setInterval(C,T,...S)},clearInterval(C){const{delegate:T}=c;return(T?.clearInterval||clearInterval)(C)},delegate:void 0};var y=r(5891);class w extends a{constructor(T,S){super(T,S),this.scheduler=T,this.work=S,this.pending=!1}schedule(T,S=0){var M;if(this.closed)return this;this.state=T;const O=this.id,L=this.scheduler;return null!=O&&(this.id=this.recycleAsyncId(L,O,S)),this.pending=!0,this.delay=S,this.id=null!==(M=this.id)&&void 0!==M?M:this.requestAsyncId(L,this.id,S),this}requestAsyncId(T,S,M=0){return c.setInterval(T.flush.bind(T,this),M)}recycleAsyncId(T,S,M=0){if(null!=M&&this.delay===M&&!1===this.pending)return S;null!=S&&c.clearInterval(S)}execute(T,S){if(this.closed)return new Error("executing a cancelled action");this.pending=!1;const M=this._execute(T,S);if(M)return M;!1===this.pending&&null!=this.id&&(this.id=this.recycleAsyncId(this.scheduler,this.id,null))}_execute(T,S){let O,M=!1;try{this.work(T)}catch(L){M=!0,O=L||new Error("Scheduled action threw falsy error")}if(M)return this.unsubscribe(),O}unsubscribe(){if(!this.closed){const{id:T,scheduler:S}=this,{actions:M}=S;this.work=this.state=this.scheduler=null,this.pending=!1,(0,y.o)(M,this),null!=T&&(this.id=this.recycleAsyncId(S,T,null)),this.delay=null,super.unsubscribe()}}}},8050:(o,s,r)=>{"use strict";r.d(s,{q:()=>c});var i=r(6188);class a{constructor(w,C=a.now){this.schedulerActionCtor=w,this.now=C}schedule(w,C=0,T){return new this.schedulerActionCtor(this,w).schedule(T,C)}}a.now=i.U.now;class c extends a{constructor(w,C=a.now){super(w,C),this.actions=[],this._active=!1}flush(w){const{actions:C}=this;if(this._active)return void C.push(w);let T;this._active=!0;do{if(T=w.execute(w.state,w.delay))break}while(w=C.shift());if(this._active=!1,T){for(;w=C.shift();)w.unsubscribe();throw T}}}},4984:(o,s,r)=>{"use strict";r.d(s,{$:()=>re});var i=r(9899);let c,a=1;const y={};function w(se){return se in y&&(delete y[se],!0)}const C={setImmediate(se){const ae=a++;return y[ae]=!0,c||(c=Promise.resolve()),c.then(()=>w(ae)&&se()),ae},clearImmediate(se){w(se)}},{setImmediate:S,clearImmediate:M}=C,O={setImmediate(...se){const{delegate:ae}=O;return(ae?.setImmediate||S)(...se)},clearImmediate(se){const{delegate:ae}=O;return(ae?.clearImmediate||M)(se)},delegate:void 0};var Z=r(8050);const re=new class q extends Z.q{flush(ae){this._active=!0;const me=this._scheduled;this._scheduled=void 0;const{actions:be}=this;let Oe;ae=ae||be.shift();do{if(Oe=ae.execute(ae.state,ae.delay))break}while((ae=be[0])&&ae.id===me&&be.shift());if(this._active=!1,Oe){for(;(ae=be[0])&&ae.id===me&&be.shift();)ae.unsubscribe();throw Oe}}}(class L extends i.R{constructor(ae,me){super(ae,me),this.scheduler=ae,this.work=me}requestAsyncId(ae,me,be=0){return null!==be&&be>0?super.requestAsyncId(ae,me,be):(ae.actions.push(this),ae._scheduled||(ae._scheduled=O.setImmediate(ae.flush.bind(ae,void 0))))}recycleAsyncId(ae,me,be=0){var Oe;if(null!=be?be>0:this.delay>0)return super.recycleAsyncId(ae,me,be);const{actions:xe}=ae;null!=me&&(null===(Oe=xe[xe.length-1])||void 0===Oe?void 0:Oe.id)!==me&&(O.clearImmediate(me),ae._scheduled===me&&(ae._scheduled=void 0))}})},6061:(o,s,r)=>{"use strict";r.d(s,{E:()=>c,b:()=>y});var i=r(9899);const c=new(r(8050).q)(i.R),y=c},6188:(o,s,r)=>{"use strict";r.d(s,{U:()=>i});const i={now:()=>(i.delegate||Date).now(),delegate:void 0}},3695:(o,s,r)=>{"use strict";r.d(s,{f:()=>i});const i={setTimeout(a,c,...y){const{delegate:w}=i;return w?.setTimeout?w.setTimeout(a,c,...y):setTimeout(a,c,...y)},clearTimeout(a){const{delegate:c}=i;return(c?.clearTimeout||clearTimeout)(a)},delegate:void 0}},6952:(o,s,r)=>{"use strict";r.d(s,{l:()=>a});const a=function i(){return"function"==typeof Symbol&&Symbol.iterator?Symbol.iterator:"@@iterator"}()},2563:(o,s,r)=>{"use strict";r.d(s,{s:()=>i});const i="function"==typeof Symbol&&Symbol.observable||"@@observable"},8747:(o,s,r)=>{"use strict";r.d(s,{G:()=>a});const a=(0,r(5644).L)(c=>function(){c(this),this.name="EmptyError",this.message="no elements in sequence"})},4327:(o,s,r)=>{"use strict";r.d(s,{R0:()=>C,lI:()=>w,ms:()=>y});var i=r(1126),a=r(9921);function c(T){return T[T.length-1]}function y(T){return(0,i.T)(c(T))?T.pop():void 0}function w(T){return(0,a.m)(c(T))?T.pop():void 0}function C(T,S){return"number"==typeof c(T)?T.pop():S}},3740:(o,s,r)=>{"use strict";r.d(s,{D:()=>w});const{isArray:i}=Array,{getPrototypeOf:a,prototype:c,keys:y}=Object;function w(T){if(1===T.length){const S=T[0];if(i(S))return{args:S,keys:null};if(function C(T){return T&&"object"==typeof T&&a(T)===c}(S)){const M=y(S);return{args:M.map(O=>S[O]),keys:M}}}return{args:T,keys:null}}},5891:(o,s,r)=>{"use strict";function i(a,c){if(a){const y=a.indexOf(c);0<=y&&a.splice(y,1)}}r.d(s,{o:()=>i})},5644:(o,s,r)=>{"use strict";function i(a){const y=a(w=>{Error.call(w),w.stack=(new Error).stack});return y.prototype=Object.create(Error.prototype),y.prototype.constructor=y,y}r.d(s,{L:()=>i})},9321:(o,s,r)=>{"use strict";function i(a,c){return a.reduce((y,w,C)=>(y[w]=c[C],y),{})}r.d(s,{e:()=>i})},4171:(o,s,r)=>{"use strict";r.d(s,{Y:()=>c,l:()=>y});var i=r(3305);let a=null;function c(w){if(i.$.useDeprecatedSynchronousErrorHandling){const C=!a;if(C&&(a={errorThrown:!1,error:null}),w(),C){const{errorThrown:T,error:S}=a;if(a=null,T)throw S}}else w()}function y(w){i.$.useDeprecatedSynchronousErrorHandling&&a&&(a.errorThrown=!0,a.error=w)}},8266:(o,s,r)=>{"use strict";function i(a,c,y,w=0,C=!1){const T=c.schedule(function(){y(),C?a.add(this.schedule(null,w)):this.unsubscribe()},w);if(a.add(T),!C)return T}r.d(s,{N:()=>i})},9220:(o,s,r)=>{"use strict";function i(a){return a}r.d(s,{D:()=>i})},6786:(o,s,r)=>{"use strict";r.d(s,{X:()=>i});const i=a=>a&&"number"==typeof a.length&&"function"!=typeof a},8394:(o,s,r)=>{"use strict";r.d(s,{T:()=>a});var i=r(1126);function a(c){return Symbol.asyncIterator&&(0,i.T)(c?.[Symbol.asyncIterator])}},1126:(o,s,r)=>{"use strict";function i(a){return"function"==typeof a}r.d(s,{T:()=>i})},6600:(o,s,r)=>{"use strict";r.d(s,{l:()=>c});var i=r(2563),a=r(1126);function c(y){return(0,a.T)(y[i.s])}},4876:(o,s,r)=>{"use strict";r.d(s,{x:()=>c});var i=r(6952),a=r(1126);function c(y){return(0,a.T)(y?.[i.l])}},1531:(o,s,r)=>{"use strict";r.d(s,{A:()=>c});var i=r(1698),a=r(1126);function c(y){return!!y&&(y instanceof i.c||(0,a.T)(y.lift)&&(0,a.T)(y.subscribe))}},6505:(o,s,r)=>{"use strict";r.d(s,{y:()=>a});var i=r(1126);function a(c){return(0,i.T)(c?.then)}},3173:(o,s,r)=>{"use strict";r.d(s,{C:()=>c,U:()=>y});var i=r(1635),a=r(1126);function c(w){return(0,i.AQ)(this,arguments,function*(){const T=w.getReader();try{for(;;){const{value:S,done:M}=yield(0,i.N3)(T.read());if(M)return yield(0,i.N3)(void 0);yield yield(0,i.N3)(S)}}finally{T.releaseLock()}})}function y(w){return(0,a.T)(w?.getReader)}},9921:(o,s,r)=>{"use strict";r.d(s,{m:()=>a});var i=r(1126);function a(c){return c&&(0,i.T)(c.schedule)}},5351:(o,s,r)=>{"use strict";r.d(s,{N:()=>c,S:()=>a});var i=r(1126);function a(y){return(0,i.T)(y?.lift)}function c(y){return w=>{if(a(w))return w.lift(function(C){try{return y(C,this)}catch(T){this.error(T)}});throw new TypeError("Unable to lift unknown Observable type")}}},3759:(o,s,r)=>{"use strict";r.d(s,{I:()=>y});var i=r(7947);const{isArray:a}=Array;function y(w){return(0,i.T)(C=>function c(w,C){return a(C)?w(...C):w(C)}(w,C))}},850:(o,s,r)=>{"use strict";function i(){}r.d(s,{l:()=>i})},6742:(o,s,r)=>{"use strict";r.d(s,{F:()=>a,m:()=>c});var i=r(9220);function a(...y){return c(y)}function c(y){return 0===y.length?i.D:1===y.length?y[0]:function(C){return y.reduce((T,S)=>S(T),C)}}},191:(o,s,r)=>{"use strict";r.d(s,{m:()=>c});var i=r(3305),a=r(3695);function c(y){a.f.setTimeout(()=>{const{onUnhandledError:w}=i.$;if(!w)throw y;w(y)})}},8810:(o,s,r)=>{"use strict";function i(a){return new TypeError(`You provided ${null!==a&&"object"==typeof a?"an invalid object":`'${a}'`} where a stream was expected. You can provide an Observable, Promise, ReadableStream, Array, AsyncIterable, or Iterable.`)}r.d(s,{L:()=>i})},1204:(o,s,r)=>{"use strict";r.d(s,{FX:()=>dt,If:()=>c,K2:()=>S,MA:()=>re,Os:()=>T,P:()=>se,S6:()=>me,hZ:()=>w,i0:()=>C,i7:()=>L,iF:()=>M,kY:()=>Z,kp:()=>y,sf:()=>Be,ui:()=>at,wk:()=>O});var i=r(4460),a=r(3107),c=function(bt){return bt[bt.State=0]="State",bt[bt.Transition=1]="Transition",bt[bt.Sequence=2]="Sequence",bt[bt.Group=3]="Group",bt[bt.Animate=4]="Animate",bt[bt.Keyframes=5]="Keyframes",bt[bt.Style=6]="Style",bt[bt.Trigger=7]="Trigger",bt[bt.Reference=8]="Reference",bt[bt.AnimateChild=9]="AnimateChild",bt[bt.AnimateRef=10]="AnimateRef",bt[bt.Query=11]="Query",bt[bt.Stagger=12]="Stagger",bt}(c||{});const y="*";function w(bt,lt){return{type:c.Trigger,name:bt,definitions:lt,options:{}}}function C(bt,lt=null){return{type:c.Animate,styles:lt,timings:bt}}function T(bt,lt=null){return{type:c.Group,steps:bt,options:lt}}function S(bt,lt=null){return{type:c.Sequence,steps:bt,options:lt}}function M(bt){return{type:c.Style,styles:bt,offset:null}}function O(bt,lt,rn){return{type:c.State,name:bt,styles:lt,options:rn}}function L(bt){return{type:c.Keyframes,steps:bt}}function Z(bt,lt,rn=null){return{type:c.Transition,expr:bt,animation:lt,options:rn}}function re(bt=null){return{type:c.AnimateChild,options:bt}}function se(bt,lt,rn=null){return{type:c.Query,selector:bt,animation:lt,options:rn}}let me=(()=>{class bt{static \u0275fac=function(gn){return new(gn||bt)};static \u0275prov=a.jDH({token:bt,factory:()=>(0,a.WQX)(Oe),providedIn:"root"})}return bt})();class be{}let Oe=(()=>{class bt extends me{animationModuleType=(0,a.WQX)(a.bc$,{optional:!0});_nextAnimationId=0;_renderer;constructor(rn,gn){if(super(),this._renderer=rn.createRenderer(gn.body,{id:"0",encapsulation:a.gXe.None,styles:[],data:{animation:[]}}),null===this.animationModuleType&&!function Ce(bt){const lt=bt.\u0275type;return 0===lt||1===lt}(this._renderer))throw new a.wOt(3600,!1)}build(rn){const gn=this._nextAnimationId;this._nextAnimationId++;const bn=Array.isArray(rn)?S(rn):rn;return ce(this._renderer,null,gn,"register",[bn]),new xe(gn,this._renderer)}static \u0275fac=function(gn){return new(gn||bt)(a.KVO(a._9s),a.KVO(i.qQ))};static \u0275prov=a.jDH({token:bt,factory:bt.\u0275fac,providedIn:"root"})}return bt})();class xe extends be{_id;_renderer;constructor(lt,rn){super(),this._id=lt,this._renderer=rn}create(lt,rn){return new De(this._id,lt,rn||{},this._renderer)}}class De{id;element;_renderer;parentPlayer=null;_started=!1;constructor(lt,rn,gn,bn){this.id=lt,this.element=rn,this._renderer=bn,this._command("create",gn)}_listen(lt,rn){return this._renderer.listen(this.element,`@@${this.id}:${lt}`,rn)}_command(lt,...rn){ce(this._renderer,this.element,this.id,lt,rn)}onDone(lt){this._listen("done",lt)}onStart(lt){this._listen("start",lt)}onDestroy(lt){this._listen("destroy",lt)}init(){this._command("init")}hasStarted(){return this._started}play(){this._command("play"),this._started=!0}pause(){this._command("pause")}restart(){this._command("restart")}finish(){this._command("finish")}destroy(){this._command("destroy")}reset(){this._command("reset"),this._started=!1}setPosition(lt){this._command("setPosition",lt)}getPosition(){return function ue(bt){const lt=bt.\u0275type;return 0===lt?bt:1===lt?bt.animationRenderer:null}(this._renderer)?.engine?.players[this.id]?.getPosition()??0}totalTime=0}function ce(bt,lt,rn,gn,bn){bt.setProperty(lt,`@@${rn}:${gn}`,bn)}class Be{_onDoneFns=[];_onStartFns=[];_onDestroyFns=[];_originalOnDoneFns=[];_originalOnStartFns=[];_started=!1;_destroyed=!1;_finished=!1;_position=0;parentPlayer=null;totalTime;constructor(lt=0,rn=0){this.totalTime=lt+rn}_onFinish(){this._finished||(this._finished=!0,this._onDoneFns.forEach(lt=>lt()),this._onDoneFns=[])}onStart(lt){this._originalOnStartFns.push(lt),this._onStartFns.push(lt)}onDone(lt){this._originalOnDoneFns.push(lt),this._onDoneFns.push(lt)}onDestroy(lt){this._onDestroyFns.push(lt)}hasStarted(){return this._started}init(){}play(){this.hasStarted()||(this._onStart(),this.triggerMicrotask()),this._started=!0}triggerMicrotask(){queueMicrotask(()=>this._onFinish())}_onStart(){this._onStartFns.forEach(lt=>lt()),this._onStartFns=[]}pause(){}restart(){}finish(){this._onFinish()}destroy(){this._destroyed||(this._destroyed=!0,this.hasStarted()||this._onStart(),this.finish(),this._onDestroyFns.forEach(lt=>lt()),this._onDestroyFns=[])}reset(){this._started=!1,this._finished=!1,this._onStartFns=this._originalOnStartFns,this._onDoneFns=this._originalOnDoneFns}setPosition(lt){this._position=this.totalTime?lt*this.totalTime:1}getPosition(){return this.totalTime?this._position/this.totalTime:1}triggerCallback(lt){const rn="start"==lt?this._onStartFns:this._onDoneFns;rn.forEach(gn=>gn()),rn.length=0}}class at{_onDoneFns=[];_onStartFns=[];_finished=!1;_started=!1;_destroyed=!1;_onDestroyFns=[];parentPlayer=null;totalTime=0;players;constructor(lt){this.players=lt;let rn=0,gn=0,bn=0;const Vn=this.players.length;0==Vn?queueMicrotask(()=>this._onFinish()):this.players.forEach(yn=>{yn.onDone(()=>{++rn==Vn&&this._onFinish()}),yn.onDestroy(()=>{++gn==Vn&&this._onDestroy()}),yn.onStart(()=>{++bn==Vn&&this._onStart()})}),this.totalTime=this.players.reduce((yn,qe)=>Math.max(yn,qe.totalTime),0)}_onFinish(){this._finished||(this._finished=!0,this._onDoneFns.forEach(lt=>lt()),this._onDoneFns=[])}init(){this.players.forEach(lt=>lt.init())}onStart(lt){this._onStartFns.push(lt)}_onStart(){this.hasStarted()||(this._started=!0,this._onStartFns.forEach(lt=>lt()),this._onStartFns=[])}onDone(lt){this._onDoneFns.push(lt)}onDestroy(lt){this._onDestroyFns.push(lt)}hasStarted(){return this._started}play(){this.parentPlayer||this.init(),this._onStart(),this.players.forEach(lt=>lt.play())}pause(){this.players.forEach(lt=>lt.pause())}restart(){this.players.forEach(lt=>lt.restart())}finish(){this._onFinish(),this.players.forEach(lt=>lt.finish())}destroy(){this._onDestroy()}_onDestroy(){this._destroyed||(this._destroyed=!0,this._onFinish(),this.players.forEach(lt=>lt.destroy()),this._onDestroyFns.forEach(lt=>lt()),this._onDestroyFns=[])}reset(){this.players.forEach(lt=>lt.reset()),this._destroyed=!1,this._finished=!1,this._started=!1}setPosition(lt){const rn=lt*this.totalTime;this.players.forEach(gn=>{const bn=gn.totalTime?Math.min(1,rn/gn.totalTime):1;gn.setPosition(bn)})}getPosition(){const lt=this.players.reduce((rn,gn)=>null===rn||gn.totalTime>rn.totalTime?gn:rn,null);return null!=lt?lt.getPosition():0}beforeDestroy(){this.players.forEach(lt=>{lt.beforeDestroy&<.beforeDestroy()})}triggerCallback(lt){const rn="start"==lt?this._onStartFns:this._onDoneFns;rn.forEach(gn=>gn()),rn.length=0}}const dt="!"},8559:(o,s,r)=>{"use strict";r.d(s,{Pd:()=>si,Au:()=>_t,vr:()=>rn,Bu:()=>ze,FN:()=>Ve,GX:()=>Fe,Q_:()=>Er,Z7:()=>Ee,Ai:()=>Vr,g7:()=>Zi,px:()=>ue,_G:()=>ft,w6:()=>mt,Ae:()=>Ce});var i=r(4460),a=r(3107),c=r(2147),y=r(5467),w=r(5919),C=r(8447),T=r(5710),M=(r(1531),r(3016)),O=r(1217),L=r(2040),Z=r(8627),q=r(1483),re=r(7947),se=(r(7610),r(1866)),ae=r(6645),me=r(5424),Oe=r(7747),xe=r(3022),De=r(6520);const ce=" ";function ue(Jt,Tt,nt){const Rt=Be(Jt,Tt);nt=nt.trim(),!Rt.some(sn=>sn.trim()===nt)&&(Rt.push(nt),Jt.setAttribute(Tt,Rt.join(ce)))}function Ce(Jt,Tt,nt){const Rt=Be(Jt,Tt);nt=nt.trim();const sn=Rt.filter(mn=>mn!==nt);sn.length?Jt.setAttribute(Tt,sn.join(ce)):Jt.removeAttribute(Tt)}function Be(Jt,Tt){return Jt.getAttribute(Tt)?.match(/\S+/g)??[]}const dt="cdk-describedby-message",bt="cdk-describedby-host";let lt=0,rn=(()=>{class Jt{_platform=(0,a.WQX)(c.OD);_document=(0,a.WQX)(i.qQ);_messageRegistry=new Map;_messagesContainer=null;_id=""+lt++;constructor(){(0,a.WQX)(y.l).load(y.Y),this._id=(0,a.WQX)(a.sZ2)+"-"+lt++}describe(nt,Rt,sn){if(!this._canBeDescribed(nt,Rt))return;const mn=gn(Rt,sn);"string"!=typeof Rt?(bn(Rt,this._id),this._messageRegistry.set(mn,{messageElement:Rt,referenceCount:0})):this._messageRegistry.has(mn)||this._createMessageElement(Rt,sn),this._isElementDescribedByMessage(nt,mn)||this._addMessageReference(nt,mn)}removeDescription(nt,Rt,sn){if(!Rt||!this._isElementNode(nt))return;const mn=gn(Rt,sn);if(this._isElementDescribedByMessage(nt,mn)&&this._removeMessageReference(nt,mn),"string"==typeof Rt){const dr=this._messageRegistry.get(mn);dr&&0===dr.referenceCount&&this._deleteMessageElement(mn)}0===this._messagesContainer?.childNodes.length&&(this._messagesContainer.remove(),this._messagesContainer=null)}ngOnDestroy(){const nt=this._document.querySelectorAll(`[${bt}="${this._id}"]`);for(let Rt=0;Rt0!=sn.indexOf(dt));nt.setAttribute("aria-describedby",Rt.join(" "))}_addMessageReference(nt,Rt){const sn=this._messageRegistry.get(Rt);ue(nt,"aria-describedby",sn.messageElement.id),nt.setAttribute(bt,this._id),sn.referenceCount++}_removeMessageReference(nt,Rt){const sn=this._messageRegistry.get(Rt);sn.referenceCount--,Ce(nt,"aria-describedby",sn.messageElement.id),nt.removeAttribute(bt)}_isElementDescribedByMessage(nt,Rt){const sn=Be(nt,"aria-describedby"),mn=this._messageRegistry.get(Rt),dr=mn&&mn.messageElement.id;return!!dr&&-1!=sn.indexOf(dr)}_canBeDescribed(nt,Rt){if(!this._isElementNode(nt))return!1;if(Rt&&"object"==typeof Rt)return!0;const sn=null==Rt?"":`${Rt}`.trim(),mn=nt.getAttribute("aria-label");return!(!sn||mn&&mn.trim()===sn)}_isElementNode(nt){return nt.nodeType===this._document.ELEMENT_NODE}static \u0275fac=function(Rt){return new(Rt||Jt)};static \u0275prov=a.jDH({token:Jt,factory:Jt.\u0275fac,providedIn:"root"})}return Jt})();function gn(Jt,Tt){return"string"==typeof Jt?`${Tt||""}/${Jt}`:Jt}function bn(Jt,Tt){Jt.id||(Jt.id=`${dt}-${Tt}-${lt++}`)}class yn{_letterKeyStream=new C.B;_items=[];_selectedItemIndex=-1;_pressedLetters=[];_skipPredicateFn;_selectedItem=new C.B;selectedItem=this._selectedItem;constructor(Tt,nt){const Rt="number"==typeof nt?.debounceInterval?nt.debounceInterval:200;nt?.skipPredicate&&(this._skipPredicateFn=nt.skipPredicate),this.setItems(Tt),this._setupKeyHandler(Rt)}destroy(){this._pressedLetters=[],this._letterKeyStream.complete(),this._selectedItem.complete()}setCurrentSelectedItemIndex(Tt){this._selectedItemIndex=Tt}setItems(Tt){this._items=Tt}handleKey(Tt){const nt=Tt.keyCode;Tt.key&&1===Tt.key.length?this._letterKeyStream.next(Tt.key.toLocaleUpperCase()):(nt>=w.A&&nt<=w.Z||nt>=w.f2&&nt<=w.bn)&&this._letterKeyStream.next(String.fromCharCode(nt))}isTyping(){return this._pressedLetters.length>0}reset(){this._pressedLetters=[]}_setupKeyHandler(Tt){this._letterKeyStream.pipe((0,L.M)(nt=>this._pressedLetters.push(nt)),(0,Z.B)(Tt),(0,q.p)(()=>this._pressedLetters.length>0),(0,re.T)(()=>this._pressedLetters.join("").toLocaleUpperCase())).subscribe(nt=>{for(let Rt=1;RtTt.disabled;constructor(Tt,nt){this._items=Tt,Tt instanceof a.rOR?this._itemChangesSubscription=Tt.changes.subscribe(Rt=>this._itemsChanged(Rt.toArray())):(0,a.Hps)(Tt)&&(this._effectRef=(0,a.QZP)(()=>this._itemsChanged(Tt()),{injector:nt}))}tabOut=new C.B;change=new C.B;skipPredicate(Tt){return this._skipPredicateFn=Tt,this}withWrap(Tt=!0){return this._wrap=Tt,this}withVerticalOrientation(Tt=!0){return this._vertical=Tt,this}withHorizontalOrientation(Tt){return this._horizontal=Tt,this}withAllowedModifierKeys(Tt){return this._allowedModifierKeys=Tt,this}withTypeAhead(Tt=200){this._typeaheadSubscription.unsubscribe();const nt=this._getItemsArray();return this._typeahead=new yn(nt,{debounceInterval:"number"==typeof Tt?Tt:void 0,skipPredicate:Rt=>this._skipPredicateFn(Rt)}),this._typeaheadSubscription=this._typeahead.selectedItem.subscribe(Rt=>{this.setActiveItem(Rt)}),this}cancelTypeahead(){return this._typeahead?.reset(),this}withHomeAndEnd(Tt=!0){return this._homeAndEnd=Tt,this}withPageUpDown(Tt=!0,nt=10){return this._pageUpAndDown={enabled:Tt,delta:nt},this}setActiveItem(Tt){const nt=this._activeItem();this.updateActiveItem(Tt),this._activeItem()!==nt&&this.change.next(this._activeItemIndex)}onKeydown(Tt){const nt=Tt.keyCode,sn=["altKey","ctrlKey","metaKey","shiftKey"].every(mn=>!Tt[mn]||this._allowedModifierKeys.indexOf(mn)>-1);switch(nt){case w.wn:return void this.tabOut.next();case w.n6:if(this._vertical&&sn){this.setNextItemActive();break}return;case w.i7:if(this._vertical&&sn){this.setPreviousItemActive();break}return;case w.LE:if(this._horizontal&&sn){"rtl"===this._horizontal?this.setPreviousItemActive():this.setNextItemActive();break}return;case w.UQ:if(this._horizontal&&sn){"rtl"===this._horizontal?this.setNextItemActive():this.setPreviousItemActive();break}return;case w.yZ:if(this._homeAndEnd&&sn){this.setFirstItemActive();break}return;case w.Kp:if(this._homeAndEnd&&sn){this.setLastItemActive();break}return;case w.w_:if(this._pageUpAndDown.enabled&&sn){const mn=this._activeItemIndex-this._pageUpAndDown.delta;this._setActiveItemByIndex(mn>0?mn:0,1);break}return;case w.dB:if(this._pageUpAndDown.enabled&&sn){const mn=this._activeItemIndex+this._pageUpAndDown.delta,dr=this._getItemsArray().length;this._setActiveItemByIndex(mn-1&&Rt!==this._activeItemIndex&&(this._activeItemIndex=Rt,this._typeahead?.setCurrentSelectedItemIndex(Rt))}}}class _t extends qe{setActiveItem(Tt){this.activeItem&&this.activeItem.setInactiveStyles(),super.setActiveItem(Tt),this.activeItem&&this.activeItem.setActiveStyles()}}class ze extends qe{_origin="program";setFocusOrigin(Tt){return this._origin=Tt,this}setActiveItem(Tt){super.setActiveItem(Tt),this.activeItem&&this.activeItem.focus(this._origin)}}let Ee=(()=>{class Jt{_platform=(0,a.WQX)(c.OD);constructor(){}isDisabled(nt){return nt.hasAttribute("disabled")}isVisible(nt){return function Xt(Jt){return!!(Jt.offsetWidth||Jt.offsetHeight||"function"==typeof Jt.getClientRects&&Jt.getClientRects().length)}(nt)&&"visible"===getComputedStyle(nt).visibility}isTabbable(nt){if(!this._platform.isBrowser)return!1;const Rt=function st(Jt){try{return Jt.frameElement}catch{return null}}(function pr(Jt){return Jt.ownerDocument&&Jt.ownerDocument.defaultView||window}(nt));if(Rt&&(-1===Kn(Rt)||!this.isVisible(Rt)))return!1;let sn=nt.nodeName.toLowerCase(),mn=Kn(nt);return nt.hasAttribute("contenteditable")?-1!==mn:!("iframe"===sn||"object"===sn||this._platform.WEBKIT&&this._platform.IOS&&!function Nr(Jt){let Tt=Jt.nodeName.toLowerCase(),nt="input"===Tt&&Jt.type;return"text"===nt||"password"===nt||"select"===Tt||"textarea"===Tt}(nt))&&("audio"===sn?!!nt.hasAttribute("controls")&&-1!==mn:"video"===sn?-1!==mn&&(null!==mn||this._platform.FIREFOX||nt.hasAttribute("controls")):nt.tabIndex>=0)}isFocusable(nt,Rt){return function Rn(Jt){return!function Kt(Jt){return function Vt(Jt){return"input"==Jt.nodeName.toLowerCase()}(Jt)&&"hidden"==Jt.type}(Jt)&&(function Mt(Jt){let Tt=Jt.nodeName.toLowerCase();return"input"===Tt||"select"===Tt||"button"===Tt||"textarea"===Tt}(Jt)||function rt(Jt){return function en(Jt){return"a"==Jt.nodeName.toLowerCase()}(Jt)&&Jt.hasAttribute("href")}(Jt)||Jt.hasAttribute("contenteditable")||kn(Jt))}(nt)&&!this.isDisabled(nt)&&(Rt?.ignoreVisibility||this.isVisible(nt))}static \u0275fac=function(Rt){return new(Rt||Jt)};static \u0275prov=a.jDH({token:Jt,factory:Jt.\u0275fac,providedIn:"root"})}return Jt})();function kn(Jt){if(!Jt.hasAttribute("tabindex")||void 0===Jt.tabIndex)return!1;let Tt=Jt.getAttribute("tabindex");return!(!Tt||isNaN(parseInt(Tt,10)))}function Kn(Jt){if(!kn(Jt))return null;const Tt=parseInt(Jt.getAttribute("tabindex")||"",10);return isNaN(Tt)?-1:Tt}class cn{_element;_checker;_ngZone;_document;_injector;_startAnchor;_endAnchor;_hasAttached=!1;startAnchorListener=()=>this.focusLastTabbableElement();endAnchorListener=()=>this.focusFirstTabbableElement();get enabled(){return this._enabled}set enabled(Tt){this._enabled=Tt,this._startAnchor&&this._endAnchor&&(this._toggleAnchorTabIndex(Tt,this._startAnchor),this._toggleAnchorTabIndex(Tt,this._endAnchor))}_enabled=!0;constructor(Tt,nt,Rt,sn,mn=!1,dr){this._element=Tt,this._checker=nt,this._ngZone=Rt,this._document=sn,this._injector=dr,mn||this.attachAnchors()}destroy(){const Tt=this._startAnchor,nt=this._endAnchor;Tt&&(Tt.removeEventListener("focus",this.startAnchorListener),Tt.remove()),nt&&(nt.removeEventListener("focus",this.endAnchorListener),nt.remove()),this._startAnchor=this._endAnchor=null,this._hasAttached=!1}attachAnchors(){return!!this._hasAttached||(this._ngZone.runOutsideAngular(()=>{this._startAnchor||(this._startAnchor=this._createAnchor(),this._startAnchor.addEventListener("focus",this.startAnchorListener)),this._endAnchor||(this._endAnchor=this._createAnchor(),this._endAnchor.addEventListener("focus",this.endAnchorListener))}),this._element.parentNode&&(this._element.parentNode.insertBefore(this._startAnchor,this._element),this._element.parentNode.insertBefore(this._endAnchor,this._element.nextSibling),this._hasAttached=!0),this._hasAttached)}focusInitialElementWhenReady(Tt){return new Promise(nt=>{this._executeOnStable(()=>nt(this.focusInitialElement(Tt)))})}focusFirstTabbableElementWhenReady(Tt){return new Promise(nt=>{this._executeOnStable(()=>nt(this.focusFirstTabbableElement(Tt)))})}focusLastTabbableElementWhenReady(Tt){return new Promise(nt=>{this._executeOnStable(()=>nt(this.focusLastTabbableElement(Tt)))})}_getRegionBoundary(Tt){const nt=this._element.querySelectorAll(`[cdk-focus-region-${Tt}], [cdkFocusRegion${Tt}], [cdk-focus-${Tt}]`);return"start"==Tt?nt.length?nt[0]:this._getFirstTabbableElement(this._element):nt.length?nt[nt.length-1]:this._getLastTabbableElement(this._element)}focusInitialElement(Tt){const nt=this._element.querySelector("[cdk-focus-initial], [cdkFocusInitial]");if(nt){if(!this._checker.isFocusable(nt)){const Rt=this._getFirstTabbableElement(nt);return Rt?.focus(Tt),!!Rt}return nt.focus(Tt),!0}return this.focusFirstTabbableElement(Tt)}focusFirstTabbableElement(Tt){const nt=this._getRegionBoundary("start");return nt&&nt.focus(Tt),!!nt}focusLastTabbableElement(Tt){const nt=this._getRegionBoundary("end");return nt&&nt.focus(Tt),!!nt}hasAttached(){return this._hasAttached}_getFirstTabbableElement(Tt){if(this._checker.isFocusable(Tt)&&this._checker.isTabbable(Tt))return Tt;const nt=Tt.children;for(let Rt=0;Rt=0;Rt--){const sn=nt[Rt].nodeType===this._document.ELEMENT_NODE?this._getLastTabbableElement(nt[Rt]):null;if(sn)return sn}return null}_createAnchor(){const Tt=this._document.createElement("div");return this._toggleAnchorTabIndex(this._enabled,Tt),Tt.classList.add("cdk-visually-hidden"),Tt.classList.add("cdk-focus-trap-anchor"),Tt.setAttribute("aria-hidden","true"),Tt}_toggleAnchorTabIndex(Tt,nt){Tt?nt.setAttribute("tabindex","0"):nt.removeAttribute("tabindex")}toggleAnchors(Tt){this._startAnchor&&this._endAnchor&&(this._toggleAnchorTabIndex(Tt,this._startAnchor),this._toggleAnchorTabIndex(Tt,this._endAnchor))}_executeOnStable(Tt){this._injector?(0,a.mal)(Tt,{injector:this._injector}):setTimeout(Tt)}}let Fe=(()=>{class Jt{_checker=(0,a.WQX)(Ee);_ngZone=(0,a.WQX)(a.SKi);_document=(0,a.WQX)(i.qQ);_injector=(0,a.WQX)(a.zZn);constructor(){(0,a.WQX)(y.l).load(y.Y)}create(nt,Rt=!1){return new cn(nt,this._checker,this._ngZone,this._document,Rt,this._injector)}static \u0275fac=function(Rt){return new(Rt||Jt)};static \u0275prov=a.jDH({token:Jt,factory:Jt.\u0275fac,providedIn:"root"})}return Jt})();function ft(Jt){return 0===Jt.buttons||0===Jt.detail}function mt(Jt){const Tt=Jt.touches&&Jt.touches[0]||Jt.changedTouches&&Jt.changedTouches[0];return!(!Tt||-1!==Tt.identifier||null!=Tt.radiusX&&1!==Tt.radiusX||null!=Tt.radiusY&&1!==Tt.radiusY)}const St=new a.nKC("cdk-input-modality-detector-options"),Tn={ignoreKeys:[w.A$,w.W3,w.eg,w.Ge,w.FX]},dn=(0,c.BQ)({passive:!0,capture:!0});let In=(()=>{class Jt{_platform=(0,a.WQX)(c.OD);modalityDetected;modalityChanged;get mostRecentModality(){return this._modality.value}_mostRecentTarget=null;_modality=new O.t(null);_options;_lastTouchMs=0;_onKeydown=nt=>{this._options?.ignoreKeys?.some(Rt=>Rt===nt.keyCode)||(this._modality.next("keyboard"),this._mostRecentTarget=(0,c.Fb)(nt))};_onMousedown=nt=>{Date.now()-this._lastTouchMs<650||(this._modality.next(ft(nt)?"keyboard":"mouse"),this._mostRecentTarget=(0,c.Fb)(nt))};_onTouchstart=nt=>{mt(nt)?this._modality.next("keyboard"):(this._lastTouchMs=Date.now(),this._modality.next("touch"),this._mostRecentTarget=(0,c.Fb)(nt))};constructor(){const nt=(0,a.WQX)(a.SKi),Rt=(0,a.WQX)(i.qQ),sn=(0,a.WQX)(St,{optional:!0});this._options={...Tn,...sn},this.modalityDetected=this._modality.pipe((0,se.i)(1)),this.modalityChanged=this.modalityDetected.pipe((0,ae.F)()),this._platform.isBrowser&&nt.runOutsideAngular(()=>{Rt.addEventListener("keydown",this._onKeydown,dn),Rt.addEventListener("mousedown",this._onMousedown,dn),Rt.addEventListener("touchstart",this._onTouchstart,dn)})}ngOnDestroy(){this._modality.complete(),this._platform.isBrowser&&(document.removeEventListener("keydown",this._onKeydown,dn),document.removeEventListener("mousedown",this._onMousedown,dn),document.removeEventListener("touchstart",this._onTouchstart,dn))}static \u0275fac=function(Rt){return new(Rt||Jt)};static \u0275prov=a.jDH({token:Jt,factory:Jt.\u0275fac,providedIn:"root"})}return Jt})();const sr=new a.nKC("liveAnnouncerElement",{providedIn:"root",factory:function xn(){return null}}),Hr=new a.nKC("LIVE_ANNOUNCER_DEFAULT_OPTIONS");let Tr=0,Vr=(()=>{class Jt{_ngZone=(0,a.WQX)(a.SKi);_defaultOptions=(0,a.WQX)(Hr,{optional:!0});_liveElement;_document=(0,a.WQX)(i.qQ);_previousTimeout;_currentPromise;_currentResolve;constructor(){const nt=(0,a.WQX)(sr,{optional:!0});this._liveElement=nt||this._createLiveElement()}announce(nt,...Rt){const sn=this._defaultOptions;let mn,dr;return 1===Rt.length&&"number"==typeof Rt[0]?dr=Rt[0]:[mn,dr]=Rt,this.clear(),clearTimeout(this._previousTimeout),mn||(mn=sn&&sn.politeness?sn.politeness:"polite"),null==dr&&sn&&(dr=sn.duration),this._liveElement.setAttribute("aria-live",mn),this._liveElement.id&&this._exposeAnnouncerToModals(this._liveElement.id),this._ngZone.runOutsideAngular(()=>(this._currentPromise||(this._currentPromise=new Promise(Co=>this._currentResolve=Co)),clearTimeout(this._previousTimeout),this._previousTimeout=setTimeout(()=>{this._liveElement.textContent=nt,"number"==typeof dr&&(this._previousTimeout=setTimeout(()=>this.clear(),dr)),this._currentResolve?.(),this._currentPromise=this._currentResolve=void 0},100),this._currentPromise))}clear(){this._liveElement&&(this._liveElement.textContent="")}ngOnDestroy(){clearTimeout(this._previousTimeout),this._liveElement?.remove(),this._liveElement=null,this._currentResolve?.(),this._currentPromise=this._currentResolve=void 0}_createLiveElement(){const nt="cdk-live-announcer-element",Rt=this._document.getElementsByClassName(nt),sn=this._document.createElement("div");for(let mn=0;mn .cdk-overlay-container [aria-modal="true"]');for(let sn=0;sn{class Jt{_ngZone=(0,a.WQX)(a.SKi);_platform=(0,a.WQX)(c.OD);_inputModalityDetector=(0,a.WQX)(In);_origin=null;_lastFocusOrigin;_windowFocused=!1;_windowFocusTimeoutId;_originTimeoutId;_originFromTouchInteraction=!1;_elementInfo=new Map;_monitoredElementCount=0;_rootNodeFocusListenerCount=new Map;_detectionMode;_windowFocusListener=()=>{this._windowFocused=!0,this._windowFocusTimeoutId=window.setTimeout(()=>this._windowFocused=!1)};_document=(0,a.WQX)(i.qQ,{optional:!0});_stopInputModalityDetector=new C.B;constructor(){const nt=(0,a.WQX)(Re,{optional:!0});this._detectionMode=nt?.detectionMode||Wt.IMMEDIATE}_rootNodeFocusAndBlurListener=nt=>{for(let sn=(0,c.Fb)(nt);sn;sn=sn.parentElement)"focus"===nt.type?this._onFocus(nt,sn):this._onBlur(nt,sn)};monitor(nt,Rt=!1){const sn=(0,xe.i8)(nt);if(!this._platform.isBrowser||1!==sn.nodeType)return(0,M.of)();const mn=(0,c.KT)(sn)||this._getDocument(),dr=this._elementInfo.get(sn);if(dr)return Rt&&(dr.checkChildren=!0),dr.subject;const Co={checkChildren:Rt,subject:new C.B,rootNode:mn};return this._elementInfo.set(sn,Co),this._registerGlobalListeners(Co),Co.subject}stopMonitoring(nt){const Rt=(0,xe.i8)(nt),sn=this._elementInfo.get(Rt);sn&&(sn.subject.complete(),this._setClasses(Rt),this._elementInfo.delete(Rt),this._removeGlobalListeners(sn))}focusVia(nt,Rt,sn){const mn=(0,xe.i8)(nt);mn===this._getDocument().activeElement?this._getClosestElementsInfo(mn).forEach(([Co,Ni])=>this._originChanged(Co,Rt,Ni)):(this._setOrigin(Rt),"function"==typeof mn.focus&&mn.focus(sn))}ngOnDestroy(){this._elementInfo.forEach((nt,Rt)=>this.stopMonitoring(Rt))}_getDocument(){return this._document||document}_getWindow(){return this._getDocument().defaultView||window}_getFocusOrigin(nt){return this._origin?this._originFromTouchInteraction?this._shouldBeAttributedToTouch(nt)?"touch":"program":this._origin:this._windowFocused&&this._lastFocusOrigin?this._lastFocusOrigin:nt&&this._isLastInteractionFromInputLabel(nt)?"mouse":"program"}_shouldBeAttributedToTouch(nt){return this._detectionMode===Wt.EVENTUAL||!!nt?.contains(this._inputModalityDetector._mostRecentTarget)}_setClasses(nt,Rt){nt.classList.toggle("cdk-focused",!!Rt),nt.classList.toggle("cdk-touch-focused","touch"===Rt),nt.classList.toggle("cdk-keyboard-focused","keyboard"===Rt),nt.classList.toggle("cdk-mouse-focused","mouse"===Rt),nt.classList.toggle("cdk-program-focused","program"===Rt)}_setOrigin(nt,Rt=!1){this._ngZone.runOutsideAngular(()=>{this._origin=nt,this._originFromTouchInteraction="touch"===nt&&Rt,this._detectionMode===Wt.IMMEDIATE&&(clearTimeout(this._originTimeoutId),this._originTimeoutId=setTimeout(()=>this._origin=null,this._originFromTouchInteraction?650:1))})}_onFocus(nt,Rt){const sn=this._elementInfo.get(Rt),mn=(0,c.Fb)(nt);!sn||!sn.checkChildren&&Rt!==mn||this._originChanged(Rt,this._getFocusOrigin(mn),sn)}_onBlur(nt,Rt){const sn=this._elementInfo.get(Rt);!sn||sn.checkChildren&&nt.relatedTarget instanceof Node&&Rt.contains(nt.relatedTarget)||(this._setClasses(Rt),this._emitOrigin(sn,null))}_emitOrigin(nt,Rt){nt.subject.observers.length&&this._ngZone.run(()=>nt.subject.next(Rt))}_registerGlobalListeners(nt){if(!this._platform.isBrowser)return;const Rt=nt.rootNode,sn=this._rootNodeFocusListenerCount.get(Rt)||0;sn||this._ngZone.runOutsideAngular(()=>{Rt.addEventListener("focus",this._rootNodeFocusAndBlurListener,Ge),Rt.addEventListener("blur",this._rootNodeFocusAndBlurListener,Ge)}),this._rootNodeFocusListenerCount.set(Rt,sn+1),1==++this._monitoredElementCount&&(this._ngZone.runOutsideAngular(()=>{this._getWindow().addEventListener("focus",this._windowFocusListener)}),this._inputModalityDetector.modalityDetected.pipe((0,me.Q)(this._stopInputModalityDetector)).subscribe(mn=>{this._setOrigin(mn,!0)}))}_removeGlobalListeners(nt){const Rt=nt.rootNode;if(this._rootNodeFocusListenerCount.has(Rt)){const sn=this._rootNodeFocusListenerCount.get(Rt);sn>1?this._rootNodeFocusListenerCount.set(Rt,sn-1):(Rt.removeEventListener("focus",this._rootNodeFocusAndBlurListener,Ge),Rt.removeEventListener("blur",this._rootNodeFocusAndBlurListener,Ge),this._rootNodeFocusListenerCount.delete(Rt))}--this._monitoredElementCount||(this._getWindow().removeEventListener("focus",this._windowFocusListener),this._stopInputModalityDetector.next(),clearTimeout(this._windowFocusTimeoutId),clearTimeout(this._originTimeoutId))}_originChanged(nt,Rt,sn){this._setClasses(nt,Rt),this._emitOrigin(sn,Rt),this._lastFocusOrigin=Rt}_getClosestElementsInfo(nt){const Rt=[];return this._elementInfo.forEach((sn,mn)=>{(mn===nt||sn.checkChildren&&mn.contains(nt))&&Rt.push([mn,sn])}),Rt}_isLastInteractionFromInputLabel(nt){const{_mostRecentTarget:Rt,mostRecentModality:sn}=this._inputModalityDetector;if("mouse"!==sn||!Rt||Rt===nt||"INPUT"!==nt.nodeName&&"TEXTAREA"!==nt.nodeName||nt.disabled)return!1;const mn=nt.labels;if(mn)for(let dr=0;dr{class Jt{_platform=(0,a.WQX)(c.OD);_hasCheckedHighContrastMode;_document=(0,a.WQX)(i.qQ);_breakpointSubscription;constructor(){this._breakpointSubscription=(0,a.WQX)(De.QP).observe("(forced-colors: active)").subscribe(()=>{this._hasCheckedHighContrastMode&&(this._hasCheckedHighContrastMode=!1,this._applyBodyHighContrastModeCssClasses())})}getHighContrastMode(){if(!this._platform.isBrowser)return ct.NONE;const nt=this._document.createElement("div");nt.style.backgroundColor="rgb(1,2,3)",nt.style.position="absolute",this._document.body.appendChild(nt);const Rt=this._document.defaultView||window,sn=Rt&&Rt.getComputedStyle?Rt.getComputedStyle(nt):null,mn=(sn&&sn.backgroundColor||"").replace(/ /g,"");switch(nt.remove(),mn){case"rgb(0,0,0)":case"rgb(45,50,54)":case"rgb(32,32,32)":return ct.WHITE_ON_BLACK;case"rgb(255,255,255)":case"rgb(255,250,239)":return ct.BLACK_ON_WHITE}return ct.NONE}ngOnDestroy(){this._breakpointSubscription.unsubscribe()}_applyBodyHighContrastModeCssClasses(){if(!this._hasCheckedHighContrastMode&&this._platform.isBrowser&&this._document.body){const nt=this._document.body.classList;nt.remove(qn,Bt,wn),this._hasCheckedHighContrastMode=!0;const Rt=this.getHighContrastMode();Rt===ct.BLACK_ON_WHITE?nt.add(qn,Bt):Rt===ct.WHITE_ON_BLACK&&nt.add(qn,wn)}}static \u0275fac=function(Rt){return new(Rt||Jt)};static \u0275prov=a.jDH({token:Jt,factory:Jt.\u0275fac,providedIn:"root"})}return Jt})(),si=(()=>{class Jt{constructor(){(0,a.WQX)(Er)._applyBodyHighContrastModeCssClasses()}static \u0275fac=function(Rt){return new(Rt||Jt)};static \u0275mod=a.$C({type:Jt});static \u0275inj=a.G2t({imports:[Oe.w5]})}return Jt})();const hi={};let Zi=(()=>{class Jt{_appId=(0,a.WQX)(a.sZ2);getId(nt){return"ng"!==this._appId&&(nt+=this._appId),hi.hasOwnProperty(nt)||(hi[nt]=0),`${nt}${hi[nt]++}`}static \u0275fac=function(Rt){return new(Rt||Jt)};static \u0275prov=a.jDH({token:Jt,factory:Jt.\u0275fac,providedIn:"root"})}return Jt})()},2944:(o,s,r)=>{"use strict";r.d(s,{dS:()=>T,jI:()=>M});var i=r(3107),a=r(4460);const c=new i.nKC("cdk-dir-doc",{providedIn:"root",factory:function y(){return(0,i.WQX)(a.qQ)}}),w=/^(ar|ckb|dv|he|iw|fa|nqo|ps|sd|ug|ur|yi|.*[-_](Adlm|Arab|Hebr|Nkoo|Rohg|Thaa))(?!.*[-_](Latn|Cyrl)($|-|_))($|-|_)/i;let T=(()=>{class O{value="ltr";change=new i.bkB;constructor(){const Z=(0,i.WQX)(c,{optional:!0});Z&&(this.value=function C(O){const L=O?.toLowerCase()||"";return"auto"===L&&typeof navigator<"u"&&navigator?.language?w.test(navigator.language)?"rtl":"ltr":"rtl"===L?"rtl":"ltr"}((Z.body?Z.body.dir:null)||(Z.documentElement?Z.documentElement.dir:null)||"ltr"))}ngOnDestroy(){this.change.complete()}static \u0275fac=function(q){return new(q||O)};static \u0275prov=i.jDH({token:O,factory:O.\u0275fac,providedIn:"root"})}return O})(),M=(()=>{class O{static \u0275fac=function(q){return new(q||O)};static \u0275mod=i.$C({type:O});static \u0275inj=i.G2t({})}return O})()},3022:(o,s,r)=>{"use strict";r.d(s,{FG:()=>w,OE:()=>c,a1:()=>C,he:()=>a,i8:()=>T});var i=r(3107);function a(M){return null!=M&&"false"!=`${M}`}function c(M,O=0){return function y(M){return!isNaN(parseFloat(M))&&!isNaN(Number(M))}(M)?Number(M):2===arguments.length?O:0}function w(M){return Array.isArray(M)?M:[M]}function C(M){return null==M?"":"string"==typeof M?M:`${M}px`}function T(M){return M instanceof i.aKT?M.nativeElement:M}},1349:(o,s,r)=>{"use strict";r.d(s,{CB:()=>Z,zP:()=>re}),r(1531),r(3016);var c=r(8447),y=r(3107);class Z{_multiple;_emitChanges;compareWith;_selection=new Set;_deselectedToEmit=[];_selectedToEmit=[];_selected;get selected(){return this._selected||(this._selected=Array.from(this._selection.values())),this._selected}changed=new c.B;constructor(se=!1,ae,me=!0,be){this._multiple=se,this._emitChanges=me,this.compareWith=be,ae&&ae.length&&(se?ae.forEach(Oe=>this._markSelected(Oe)):this._markSelected(ae[0]),this._selectedToEmit.length=0)}select(...se){this._verifyValueAssignment(se),se.forEach(me=>this._markSelected(me));const ae=this._hasQueuedChanges();return this._emitChangeEvent(),ae}deselect(...se){this._verifyValueAssignment(se),se.forEach(me=>this._unmarkSelected(me));const ae=this._hasQueuedChanges();return this._emitChangeEvent(),ae}setSelection(...se){this._verifyValueAssignment(se);const ae=this.selected,me=new Set(se);se.forEach(Oe=>this._markSelected(Oe)),ae.filter(Oe=>!me.has(this._getConcreteValue(Oe,me))).forEach(Oe=>this._unmarkSelected(Oe));const be=this._hasQueuedChanges();return this._emitChangeEvent(),be}toggle(se){return this.isSelected(se)?this.deselect(se):this.select(se)}clear(se=!0){this._unmarkAll();const ae=this._hasQueuedChanges();return se&&this._emitChangeEvent(),ae}isSelected(se){return this._selection.has(this._getConcreteValue(se))}isEmpty(){return 0===this._selection.size}hasValue(){return!this.isEmpty()}sort(se){this._multiple&&this.selected&&this._selected.sort(se)}isMultipleSelection(){return this._multiple}_emitChangeEvent(){this._selected=null,(this._selectedToEmit.length||this._deselectedToEmit.length)&&(this.changed.next({source:this,added:this._selectedToEmit,removed:this._deselectedToEmit}),this._deselectedToEmit=[],this._selectedToEmit=[])}_markSelected(se){se=this._getConcreteValue(se),this.isSelected(se)||(this._multiple||this._unmarkAll(),this.isSelected(se)||this._selection.add(se),this._emitChanges&&this._selectedToEmit.push(se))}_unmarkSelected(se){se=this._getConcreteValue(se),this.isSelected(se)&&(this._selection.delete(se),this._emitChanges&&this._deselectedToEmit.push(se))}_unmarkAll(){this.isEmpty()||this._selection.forEach(se=>this._unmarkSelected(se))}_verifyValueAssignment(se){}_hasQueuedChanges(){return!(!this._deselectedToEmit.length&&!this._selectedToEmit.length)}_getConcreteValue(se,ae){if(this.compareWith){ae=ae??this._selection;for(let me of ae)if(this.compareWith(se,me))return me;return se}return se}}let re=(()=>{class pe{_listeners=[];notify(ae,me){for(let be of this._listeners)be(ae,me)}listen(ae){return this._listeners.push(ae),()=>{this._listeners=this._listeners.filter(me=>ae!==me)}}ngOnDestroy(){this._listeners=[]}static \u0275fac=function(me){return new(me||pe)};static \u0275prov=y.jDH({token:pe,factory:pe.\u0275fac,providedIn:"root"})}return pe})()},5919:(o,s,r)=>{"use strict";r.d(s,{A:()=>$e,A$:()=>S,FX:()=>C,Fm:()=>w,Ge:()=>N,Kp:()=>pe,LE:()=>be,UQ:()=>ae,W3:()=>T,Z:()=>z,_f:()=>L,bn:()=>Vn,dB:()=>re,eg:()=>Ye,f2:()=>Ce,i7:()=>me,n6:()=>Oe,rp:()=>Ne,t6:()=>Z,w_:()=>q,wn:()=>c,yZ:()=>se});const c=9,w=13,C=16,T=17,S=18,L=27,Z=32,q=33,re=34,pe=35,se=36,ae=37,me=38,be=39,Oe=40,Ce=48,Vn=57,$e=65,z=90,N=91,Ye=224;function Ne(gt,...Ht){return Ht.length?Ht.some(kt=>gt[kt]):gt.altKey||gt.shiftKey||gt.ctrlKey||gt.metaKey}},6520:(o,s,r)=>{"use strict";r.d(s,{QP:()=>Oe,Rp:()=>De});var i=r(3107),a=r(3022),c=r(8447),y=r(6627),w=r(3569),C=r(1698),T=r(7610),S=r(1866),M=r(8627),O=r(7947),L=r(593),Z=r(5424),q=r(2147);const pe=new Set;let se,ae=(()=>{class ce{_platform=(0,i.WQX)(q.OD);_nonce=(0,i.WQX)(i.BIS,{optional:!0});_matchMedia;constructor(){this._matchMedia=this._platform.isBrowser&&window.matchMedia?window.matchMedia.bind(window):be}matchMedia(Ce){return(this._platform.WEBKIT||this._platform.BLINK)&&function me(ce,ue){if(!pe.has(ce))try{se||(se=document.createElement("style"),ue&&se.setAttribute("nonce",ue),se.setAttribute("type","text/css"),document.head.appendChild(se)),se.sheet&&(se.sheet.insertRule(`@media ${ce} {body{ }}`,0),pe.add(ce))}catch(Ce){console.error(Ce)}}(Ce,this._nonce),this._matchMedia(Ce)}static \u0275fac=function(Be){return new(Be||ce)};static \u0275prov=i.jDH({token:ce,factory:ce.\u0275fac,providedIn:"root"})}return ce})();function be(ce){return{matches:"all"===ce||""===ce,media:ce,addListener:()=>{},removeListener:()=>{}}}let Oe=(()=>{class ce{_mediaMatcher=(0,i.WQX)(ae);_zone=(0,i.WQX)(i.SKi);_queries=new Map;_destroySubject=new c.B;constructor(){}ngOnDestroy(){this._destroySubject.next(),this._destroySubject.complete()}isMatched(Ce){return xe((0,a.FG)(Ce)).some(at=>this._registerQuery(at).mql.matches)}observe(Ce){const at=xe((0,a.FG)(Ce)).map(bt=>this._registerQuery(bt).observable);let dt=(0,y.z)(at);return dt=(0,w.x)(dt.pipe((0,T.s)(1)),dt.pipe((0,S.i)(1),(0,M.B)(0))),dt.pipe((0,O.T)(bt=>{const lt={matches:!1,breakpoints:{}};return bt.forEach(({matches:rn,query:gn})=>{lt.matches=lt.matches||rn,lt.breakpoints[gn]=rn}),lt}))}_registerQuery(Ce){if(this._queries.has(Ce))return this._queries.get(Ce);const Be=this._mediaMatcher.matchMedia(Ce),dt={observable:new C.c(bt=>{const lt=rn=>this._zone.run(()=>bt.next(rn));return Be.addListener(lt),()=>{Be.removeListener(lt)}}).pipe((0,L.Z)(Be),(0,O.T)(({matches:bt})=>({query:Ce,matches:bt})),(0,Z.Q)(this._destroySubject)),mql:Be};return this._queries.set(Ce,dt),dt}static \u0275fac=function(Be){return new(Be||ce)};static \u0275prov=i.jDH({token:ce,factory:ce.\u0275fac,providedIn:"root"})}return ce})();function xe(ce){return ce.map(ue=>ue.split(",")).reduce((ue,Ce)=>ue.concat(Ce)).map(ue=>ue.trim())}const De={XSmall:"(max-width: 599.98px)",Small:"(min-width: 600px) and (max-width: 959.98px)",Medium:"(min-width: 960px) and (max-width: 1279.98px)",Large:"(min-width: 1280px) and (max-width: 1919.98px)",XLarge:"(min-width: 1920px)",Handset:"(max-width: 599.98px) and (orientation: portrait), (max-width: 959.98px) and (orientation: landscape)",Tablet:"(min-width: 600px) and (max-width: 839.98px) and (orientation: portrait), (min-width: 960px) and (max-width: 1279.98px) and (orientation: landscape)",Web:"(min-width: 840px) and (orientation: portrait), (min-width: 1280px) and (orientation: landscape)",HandsetPortrait:"(max-width: 599.98px) and (orientation: portrait)",TabletPortrait:"(min-width: 600px) and (max-width: 839.98px) and (orientation: portrait)",WebPortrait:"(min-width: 840px) and (orientation: portrait)",HandsetLandscape:"(max-width: 959.98px) and (orientation: landscape)",TabletLandscape:"(min-width: 960px) and (max-width: 1279.98px) and (orientation: landscape)",WebLandscape:"(min-width: 1280px) and (orientation: landscape)"}},7747:(o,s,r)=>{"use strict";r.d(s,{w5:()=>C});var i=r(3107);let c=(()=>{class T{create(M){return typeof MutationObserver>"u"?null:new MutationObserver(M)}static \u0275fac=function(O){return new(O||T)};static \u0275prov=i.jDH({token:T,factory:T.\u0275fac,providedIn:"root"})}return T})(),C=(()=>{class T{static \u0275fac=function(O){return new(O||T)};static \u0275mod=i.$C({type:T});static \u0275inj=i.G2t({providers:[c]})}return T})()},9666:(o,s,r)=>{"use strict";r.d(s,{$Q:()=>en,Sf:()=>_t,Tv:()=>Ce,WB:()=>kn,hJ:()=>Kt,rR:()=>Be,yY:()=>ze,z_:()=>Rn});var i=r(8108),a=r(4460),c=r(3107),y=r(3022),w=r(2147),C=r(1483),T=r(5424),S=r(8445),M=r(2944),O=r(6192),L=r(8559),Z=r(5467),q=r(8447),re=r(5710),pe=r(7509),se=r(5919);const ae=(0,w.CZ)();class me{_viewportRuler;_previousHTMLStyles={top:"",left:""};_previousScrollPosition;_isEnabled=!1;_document;constructor(Fe,ke){this._viewportRuler=Fe,this._document=ke}attach(){}enable(){if(this._canBeEnabled()){const Fe=this._document.documentElement;this._previousScrollPosition=this._viewportRuler.getViewportScrollPosition(),this._previousHTMLStyles.left=Fe.style.left||"",this._previousHTMLStyles.top=Fe.style.top||"",Fe.style.left=(0,y.a1)(-this._previousScrollPosition.left),Fe.style.top=(0,y.a1)(-this._previousScrollPosition.top),Fe.classList.add("cdk-global-scrollblock"),this._isEnabled=!0}}disable(){if(this._isEnabled){const Fe=this._document.documentElement,Je=Fe.style,z=this._document.body.style,N=Je.scrollBehavior||"",W=z.scrollBehavior||"";this._isEnabled=!1,Je.left=this._previousHTMLStyles.left,Je.top=this._previousHTMLStyles.top,Fe.classList.remove("cdk-global-scrollblock"),ae&&(Je.scrollBehavior=z.scrollBehavior="auto"),window.scroll(this._previousScrollPosition.left,this._previousScrollPosition.top),ae&&(Je.scrollBehavior=N,z.scrollBehavior=W)}}_canBeEnabled(){if(this._document.documentElement.classList.contains("cdk-global-scrollblock")||this._isEnabled)return!1;const ke=this._document.body,Je=this._viewportRuler.getViewportSize();return ke.scrollHeight>Je.height||ke.scrollWidth>Je.width}}class Oe{_scrollDispatcher;_ngZone;_viewportRuler;_config;_scrollSubscription=null;_overlayRef;_initialScrollPosition;constructor(Fe,ke,Je,z){this._scrollDispatcher=Fe,this._ngZone=ke,this._viewportRuler=Je,this._config=z}attach(Fe){this._overlayRef=Fe}enable(){if(this._scrollSubscription)return;const Fe=this._scrollDispatcher.scrolled(0).pipe((0,C.p)(ke=>!ke||!this._overlayRef.overlayElement.contains(ke.getElementRef().nativeElement)));this._config&&this._config.threshold&&this._config.threshold>1?(this._initialScrollPosition=this._viewportRuler.getViewportScrollPosition().top,this._scrollSubscription=Fe.subscribe(()=>{const ke=this._viewportRuler.getViewportScrollPosition().top;Math.abs(ke-this._initialScrollPosition)>this._config.threshold?this._detach():this._overlayRef.updatePosition()})):this._scrollSubscription=Fe.subscribe(this._detach)}disable(){this._scrollSubscription&&(this._scrollSubscription.unsubscribe(),this._scrollSubscription=null)}detach(){this.disable(),this._overlayRef=null}_detach=()=>{this.disable(),this._overlayRef.hasAttached()&&this._ngZone.run(()=>this._overlayRef.detach())}}class xe{enable(){}disable(){}attach(){}}function De(cn,Fe){return Fe.some(ke=>cn.bottomke.bottom||cn.rightke.right)}function ce(cn,Fe){return Fe.some(ke=>cn.topke.bottom||cn.leftke.right)}class ue{_scrollDispatcher;_viewportRuler;_ngZone;_config;_scrollSubscription=null;_overlayRef;constructor(Fe,ke,Je,z){this._scrollDispatcher=Fe,this._viewportRuler=ke,this._ngZone=Je,this._config=z}attach(Fe){this._overlayRef=Fe}enable(){this._scrollSubscription||(this._scrollSubscription=this._scrollDispatcher.scrolled(this._config?this._config.scrollThrottle:0).subscribe(()=>{if(this._overlayRef.updatePosition(),this._config&&this._config.autoClose){const ke=this._overlayRef.overlayElement.getBoundingClientRect(),{width:Je,height:z}=this._viewportRuler.getViewportSize();De(ke,[{width:Je,height:z,bottom:z,right:Je,top:0,left:0}])&&(this.disable(),this._ngZone.run(()=>this._overlayRef.detach()))}}))}disable(){this._scrollSubscription&&(this._scrollSubscription.unsubscribe(),this._scrollSubscription=null)}detach(){this.disable(),this._overlayRef=null}}let Ce=(()=>{class cn{_scrollDispatcher=(0,c.WQX)(i.R);_viewportRuler=(0,c.WQX)(i.Xj);_ngZone=(0,c.WQX)(c.SKi);_document=(0,c.WQX)(a.qQ);constructor(){}noop=()=>new xe;close=ke=>new Oe(this._scrollDispatcher,this._ngZone,this._viewportRuler,ke);block=()=>new me(this._viewportRuler,this._document);reposition=ke=>new ue(this._scrollDispatcher,this._viewportRuler,this._ngZone,ke);static \u0275fac=function(Je){return new(Je||cn)};static \u0275prov=c.jDH({token:cn,factory:cn.\u0275fac,providedIn:"root"})}return cn})();class Be{positionStrategy;scrollStrategy=new xe;panelClass="";hasBackdrop=!1;backdropClass="cdk-overlay-dark-backdrop";width;height;minWidth;minHeight;maxWidth;maxHeight;direction;disposeOnNavigation=!1;constructor(Fe){if(Fe){const ke=Object.keys(Fe);for(const Je of ke)void 0!==Fe[Je]&&(this[Je]=Fe[Je])}}}class bt{connectionPair;scrollableViewProperties;constructor(Fe,ke){this.connectionPair=Fe,this.scrollableViewProperties=ke}}let gn=(()=>{class cn{_attachedOverlays=[];_document=(0,c.WQX)(a.qQ);_isAttached;constructor(){}ngOnDestroy(){this.detach()}add(ke){this.remove(ke),this._attachedOverlays.push(ke)}remove(ke){const Je=this._attachedOverlays.indexOf(ke);Je>-1&&this._attachedOverlays.splice(Je,1),0===this._attachedOverlays.length&&this.detach()}static \u0275fac=function(Je){return new(Je||cn)};static \u0275prov=c.jDH({token:cn,factory:cn.\u0275fac,providedIn:"root"})}return cn})(),bn=(()=>{class cn extends gn{_ngZone=(0,c.WQX)(c.SKi,{optional:!0});add(ke){super.add(ke),this._isAttached||(this._ngZone?this._ngZone.runOutsideAngular(()=>this._document.body.addEventListener("keydown",this._keydownListener)):this._document.body.addEventListener("keydown",this._keydownListener),this._isAttached=!0)}detach(){this._isAttached&&(this._document.body.removeEventListener("keydown",this._keydownListener),this._isAttached=!1)}_keydownListener=ke=>{const Je=this._attachedOverlays;for(let z=Je.length-1;z>-1;z--)if(Je[z]._keydownEvents.observers.length>0){const N=Je[z]._keydownEvents;this._ngZone?this._ngZone.run(()=>N.next(ke)):N.next(ke);break}};static \u0275fac=(()=>{let ke;return function(z){return(ke||(ke=c.xGo(cn)))(z||cn)}})();static \u0275prov=c.jDH({token:cn,factory:cn.\u0275fac,providedIn:"root"})}return cn})(),Vn=(()=>{class cn extends gn{_platform=(0,c.WQX)(w.OD);_ngZone=(0,c.WQX)(c.SKi,{optional:!0});_cursorOriginalValue;_cursorStyleIsSet=!1;_pointerDownEventTarget;add(ke){if(super.add(ke),!this._isAttached){const Je=this._document.body;this._ngZone?this._ngZone.runOutsideAngular(()=>this._addEventListeners(Je)):this._addEventListeners(Je),this._platform.IOS&&!this._cursorStyleIsSet&&(this._cursorOriginalValue=Je.style.cursor,Je.style.cursor="pointer",this._cursorStyleIsSet=!0),this._isAttached=!0}}detach(){if(this._isAttached){const ke=this._document.body;ke.removeEventListener("pointerdown",this._pointerDownListener,!0),ke.removeEventListener("click",this._clickListener,!0),ke.removeEventListener("auxclick",this._clickListener,!0),ke.removeEventListener("contextmenu",this._clickListener,!0),this._platform.IOS&&this._cursorStyleIsSet&&(ke.style.cursor=this._cursorOriginalValue,this._cursorStyleIsSet=!1),this._isAttached=!1}}_addEventListeners(ke){ke.addEventListener("pointerdown",this._pointerDownListener,!0),ke.addEventListener("click",this._clickListener,!0),ke.addEventListener("auxclick",this._clickListener,!0),ke.addEventListener("contextmenu",this._clickListener,!0)}_pointerDownListener=ke=>{this._pointerDownEventTarget=(0,w.Fb)(ke)};_clickListener=ke=>{const Je=(0,w.Fb)(ke),z="click"===ke.type&&this._pointerDownEventTarget?this._pointerDownEventTarget:Je;this._pointerDownEventTarget=null;const N=this._attachedOverlays.slice();for(let W=N.length-1;W>-1;W--){const Le=N[W];if(Le._outsidePointerEvents.observers.length<1||!Le.hasAttached())continue;if(yn(Le.overlayElement,Je)||yn(Le.overlayElement,z))break;const ft=Le._outsidePointerEvents;this._ngZone?this._ngZone.run(()=>ft.next(ke)):ft.next(ke)}};static \u0275fac=(()=>{let ke;return function(z){return(ke||(ke=c.xGo(cn)))(z||cn)}})();static \u0275prov=c.jDH({token:cn,factory:cn.\u0275fac,providedIn:"root"})}return cn})();function yn(cn,Fe){const ke=typeof ShadowRoot<"u"&&ShadowRoot;let Je=Fe;for(;Je;){if(Je===cn)return!0;Je=ke&&Je instanceof ShadowRoot?Je.host:Je.parentNode}return!1}let qe=(()=>{class cn{static \u0275fac=function(Je){return new(Je||cn)};static \u0275cmp=c.VBU({type:cn,selectors:[["ng-component"]],hostAttrs:["cdk-overlay-style-loader",""],decls:0,vars:0,template:function(Je,z){},styles:[".cdk-overlay-container,.cdk-global-overlay-wrapper{pointer-events:none;top:0;left:0;height:100%;width:100%}.cdk-overlay-container{position:fixed}@layer cdk-overlay{.cdk-overlay-container{z-index:1000}}.cdk-overlay-container:empty{display:none}.cdk-global-overlay-wrapper{display:flex;position:absolute}@layer cdk-overlay{.cdk-global-overlay-wrapper{z-index:1000}}.cdk-overlay-pane{position:absolute;pointer-events:auto;box-sizing:border-box;display:flex;max-width:100%;max-height:100%}@layer cdk-overlay{.cdk-overlay-pane{z-index:1000}}.cdk-overlay-backdrop{position:absolute;top:0;bottom:0;left:0;right:0;pointer-events:auto;-webkit-tap-highlight-color:rgba(0,0,0,0);opacity:0}@layer cdk-overlay{.cdk-overlay-backdrop{z-index:1000;transition:opacity 400ms cubic-bezier(0.25, 0.8, 0.25, 1)}}.cdk-overlay-backdrop-showing{opacity:1}@media(forced-colors: active){.cdk-overlay-backdrop-showing{opacity:.6}}@layer cdk-overlay{.cdk-overlay-dark-backdrop{background:rgba(0,0,0,.32)}}.cdk-overlay-transparent-backdrop{transition:visibility 1ms linear,opacity 1ms linear;visibility:hidden;opacity:1}.cdk-overlay-transparent-backdrop.cdk-overlay-backdrop-showing,.cdk-high-contrast-active .cdk-overlay-transparent-backdrop{opacity:0;visibility:visible}.cdk-overlay-backdrop-noop-animation{transition:none}.cdk-overlay-connected-position-bounding-box{position:absolute;display:flex;flex-direction:column;min-width:1px;min-height:1px}@layer cdk-overlay{.cdk-overlay-connected-position-bounding-box{z-index:1000}}.cdk-global-scrollblock{position:fixed;width:100%;overflow-y:scroll}"],encapsulation:2,changeDetection:0})}return cn})(),_t=(()=>{class cn{_platform=(0,c.WQX)(w.OD);_containerElement;_document=(0,c.WQX)(a.qQ);_styleLoader=(0,c.WQX)(Z.l);constructor(){}ngOnDestroy(){this._containerElement?.remove()}getContainerElement(){return this._loadStyles(),this._containerElement||this._createContainer(),this._containerElement}_createContainer(){const ke="cdk-overlay-container";if(this._platform.isBrowser||(0,w.v8)()){const z=this._document.querySelectorAll(`.${ke}[platform="server"], .${ke}[platform="test"]`);for(let N=0;Nthis._backdropClick.next(Fe);_backdropTransitionendHandler=Fe=>{this._disposeBackdrop(Fe.target)};_previousHostParent;_keydownEvents=new q.B;_outsidePointerEvents=new q.B;_renders=new q.B;_afterRenderRef;_afterNextRenderRef;constructor(Fe,ke,Je,z,N,W,Le,ft,mt,St=!1,Tn){this._portalOutlet=Fe,this._host=ke,this._pane=Je,this._config=z,this._ngZone=N,this._keyboardDispatcher=W,this._document=Le,this._location=ft,this._outsideClickDispatcher=mt,this._animationsDisabled=St,this._injector=Tn,z.scrollStrategy&&(this._scrollStrategy=z.scrollStrategy,this._scrollStrategy.attach(this)),this._positionStrategy=z.positionStrategy,this._afterRenderRef=(0,c.O8t)(()=>(0,c.Tzd)(()=>{this._renders.next()},{injector:this._injector}))}get overlayElement(){return this._pane}get backdropElement(){return this._backdropElement}get hostElement(){return this._host}attach(Fe){!this._host.parentElement&&this._previousHostParent&&this._previousHostParent.appendChild(this._host);const ke=this._portalOutlet.attach(Fe);return this._positionStrategy&&this._positionStrategy.attach(this),this._updateStackingOrder(),this._updateElementSize(),this._updateElementDirection(),this._scrollStrategy&&this._scrollStrategy.enable(),this._afterNextRenderRef?.destroy(),this._afterNextRenderRef=(0,c.mal)(()=>{this.hasAttached()&&this.updatePosition()},{injector:this._injector}),this._togglePointerEvents(!0),this._config.hasBackdrop&&this._attachBackdrop(),this._config.panelClass&&this._toggleClasses(this._pane,this._config.panelClass,!0),this._attachments.next(),this._keyboardDispatcher.add(this),this._config.disposeOnNavigation&&(this._locationChanges=this._location.subscribe(()=>this.dispose())),this._outsideClickDispatcher.add(this),"function"==typeof ke?.onDestroy&&ke.onDestroy(()=>{this.hasAttached()&&this._ngZone.runOutsideAngular(()=>Promise.resolve().then(()=>this.detach()))}),ke}detach(){if(!this.hasAttached())return;this.detachBackdrop(),this._togglePointerEvents(!1),this._positionStrategy&&this._positionStrategy.detach&&this._positionStrategy.detach(),this._scrollStrategy&&this._scrollStrategy.disable();const Fe=this._portalOutlet.detach();return this._detachments.next(),this._keyboardDispatcher.remove(this),this._detachContentWhenEmpty(),this._locationChanges.unsubscribe(),this._outsideClickDispatcher.remove(this),Fe}dispose(){const Fe=this.hasAttached();this._positionStrategy&&this._positionStrategy.dispose(),this._disposeScrollStrategy(),this._disposeBackdrop(this._backdropElement),this._locationChanges.unsubscribe(),this._keyboardDispatcher.remove(this),this._portalOutlet.dispose(),this._attachments.complete(),this._backdropClick.complete(),this._keydownEvents.complete(),this._outsidePointerEvents.complete(),this._outsideClickDispatcher.remove(this),this._host?.remove(),this._afterNextRenderRef?.destroy(),this._previousHostParent=this._pane=this._host=null,Fe&&this._detachments.next(),this._detachments.complete(),this._afterRenderRef.destroy(),this._renders.complete()}hasAttached(){return this._portalOutlet.hasAttached()}backdropClick(){return this._backdropClick}attachments(){return this._attachments}detachments(){return this._detachments}keydownEvents(){return this._keydownEvents}outsidePointerEvents(){return this._outsidePointerEvents}getConfig(){return this._config}updatePosition(){this._positionStrategy&&this._positionStrategy.apply()}updatePositionStrategy(Fe){Fe!==this._positionStrategy&&(this._positionStrategy&&this._positionStrategy.dispose(),this._positionStrategy=Fe,this.hasAttached()&&(Fe.attach(this),this.updatePosition()))}updateSize(Fe){this._config={...this._config,...Fe},this._updateElementSize()}setDirection(Fe){this._config={...this._config,direction:Fe},this._updateElementDirection()}addPanelClass(Fe){this._pane&&this._toggleClasses(this._pane,Fe,!0)}removePanelClass(Fe){this._pane&&this._toggleClasses(this._pane,Fe,!1)}getDirection(){const Fe=this._config.direction;return Fe?"string"==typeof Fe?Fe:Fe.value:"ltr"}updateScrollStrategy(Fe){Fe!==this._scrollStrategy&&(this._disposeScrollStrategy(),this._scrollStrategy=Fe,this.hasAttached()&&(Fe.attach(this),Fe.enable()))}_updateElementDirection(){this._host.setAttribute("dir",this.getDirection())}_updateElementSize(){if(!this._pane)return;const Fe=this._pane.style;Fe.width=(0,y.a1)(this._config.width),Fe.height=(0,y.a1)(this._config.height),Fe.minWidth=(0,y.a1)(this._config.minWidth),Fe.minHeight=(0,y.a1)(this._config.minHeight),Fe.maxWidth=(0,y.a1)(this._config.maxWidth),Fe.maxHeight=(0,y.a1)(this._config.maxHeight)}_togglePointerEvents(Fe){this._pane.style.pointerEvents=Fe?"":"none"}_attachBackdrop(){const Fe="cdk-overlay-backdrop-showing";this._backdropElement=this._document.createElement("div"),this._backdropElement.classList.add("cdk-overlay-backdrop"),this._animationsDisabled&&this._backdropElement.classList.add("cdk-overlay-backdrop-noop-animation"),this._config.backdropClass&&this._toggleClasses(this._backdropElement,this._config.backdropClass,!0),this._host.parentElement.insertBefore(this._backdropElement,this._host),this._backdropElement.addEventListener("click",this._backdropClickHandler),!this._animationsDisabled&&typeof requestAnimationFrame<"u"?this._ngZone.runOutsideAngular(()=>{requestAnimationFrame(()=>{this._backdropElement&&this._backdropElement.classList.add(Fe)})}):this._backdropElement.classList.add(Fe)}_updateStackingOrder(){this._host.nextSibling&&this._host.parentNode.appendChild(this._host)}detachBackdrop(){const Fe=this._backdropElement;if(Fe){if(this._animationsDisabled)return void this._disposeBackdrop(Fe);Fe.classList.remove("cdk-overlay-backdrop-showing"),this._ngZone.runOutsideAngular(()=>{Fe.addEventListener("transitionend",this._backdropTransitionendHandler)}),Fe.style.pointerEvents="none",this._backdropTimeout=this._ngZone.runOutsideAngular(()=>setTimeout(()=>{this._disposeBackdrop(Fe)},500))}}_toggleClasses(Fe,ke,Je){const z=(0,y.FG)(ke||[]).filter(N=>!!N);z.length&&(Je?Fe.classList.add(...z):Fe.classList.remove(...z))}_detachContentWhenEmpty(){this._ngZone.runOutsideAngular(()=>{const Fe=this._renders.pipe((0,T.Q)((0,pe.h)(this._attachments,this._detachments))).subscribe(()=>{(!this._pane||!this._host||0===this._pane.children.length)&&(this._pane&&this._config.panelClass&&this._toggleClasses(this._pane,this._config.panelClass,!1),this._host&&this._host.parentElement&&(this._previousHostParent=this._host.parentElement,this._host.remove()),Fe.unsubscribe())})})}_disposeScrollStrategy(){const Fe=this._scrollStrategy;Fe&&(Fe.disable(),Fe.detach&&Fe.detach())}_disposeBackdrop(Fe){Fe&&(Fe.removeEventListener("click",this._backdropClickHandler),Fe.removeEventListener("transitionend",this._backdropTransitionendHandler),Fe.remove(),this._backdropElement===Fe&&(this._backdropElement=null)),this._backdropTimeout&&(clearTimeout(this._backdropTimeout),this._backdropTimeout=void 0)}}const $e="cdk-overlay-connected-position-bounding-box",Ft=/([A-Za-z%]+)$/;class Ke{_viewportRuler;_document;_platform;_overlayContainer;_overlayRef;_isInitialRender;_lastBoundingBoxSize={width:0,height:0};_isPushed=!1;_canPush=!0;_growAfterOpen=!1;_hasFlexibleDimensions=!0;_positionLocked=!1;_originRect;_overlayRect;_viewportRect;_containerRect;_viewportMargin=0;_scrollables=[];_preferredPositions=[];_origin;_pane;_isDisposed;_boundingBox;_lastPosition;_lastScrollVisibility;_positionChanges=new q.B;_resizeSubscription=re.yU.EMPTY;_offsetX=0;_offsetY=0;_transformOriginSelector;_appliedPanelClasses=[];_previousPushAmount;positionChanges=this._positionChanges;get positions(){return this._preferredPositions}constructor(Fe,ke,Je,z,N){this._viewportRuler=ke,this._document=Je,this._platform=z,this._overlayContainer=N,this.setOrigin(Fe)}attach(Fe){this._validatePositions(),Fe.hostElement.classList.add($e),this._overlayRef=Fe,this._boundingBox=Fe.hostElement,this._pane=Fe.overlayElement,this._isDisposed=!1,this._isInitialRender=!0,this._lastPosition=null,this._resizeSubscription.unsubscribe(),this._resizeSubscription=this._viewportRuler.change().subscribe(()=>{this._isInitialRender=!0,this.apply()})}apply(){if(this._isDisposed||!this._platform.isBrowser)return;if(!this._isInitialRender&&this._positionLocked&&this._lastPosition)return void this.reapplyLastPosition();this._clearPanelClasses(),this._resetOverlayElementStyles(),this._resetBoundingBoxStyles(),this._viewportRect=this._getNarrowedViewportRect(),this._originRect=this._getOriginRect(),this._overlayRect=this._pane.getBoundingClientRect(),this._containerRect=this._overlayContainer.getContainerElement().getBoundingClientRect();const Fe=this._originRect,ke=this._overlayRect,Je=this._viewportRect,z=this._containerRect,N=[];let W;for(let Le of this._preferredPositions){let ft=this._getOriginPoint(Fe,z,Le),mt=this._getOverlayPoint(ft,ke,Le),St=this._getOverlayFit(mt,ke,Je,Le);if(St.isCompletelyWithinViewport)return this._isPushed=!1,void this._applyPosition(Le,ft);this._canFitWithFlexibleDimensions(St,mt,Je)?N.push({position:Le,origin:ft,overlayRect:ke,boundingBoxRect:this._calculateBoundingBoxRect(ft,Le)}):(!W||W.overlayFit.visibleAreaft&&(ft=St,Le=mt)}return this._isPushed=!1,void this._applyPosition(Le.position,Le.origin)}if(this._canPush)return this._isPushed=!0,void this._applyPosition(W.position,W.originPoint);this._applyPosition(W.position,W.originPoint)}detach(){this._clearPanelClasses(),this._lastPosition=null,this._previousPushAmount=null,this._resizeSubscription.unsubscribe()}dispose(){this._isDisposed||(this._boundingBox&&Ze(this._boundingBox.style,{top:"",left:"",right:"",bottom:"",height:"",width:"",alignItems:"",justifyContent:""}),this._pane&&this._resetOverlayElementStyles(),this._overlayRef&&this._overlayRef.hostElement.classList.remove($e),this.detach(),this._positionChanges.complete(),this._overlayRef=this._boundingBox=null,this._isDisposed=!0)}reapplyLastPosition(){if(this._isDisposed||!this._platform.isBrowser)return;const Fe=this._lastPosition;if(Fe){this._originRect=this._getOriginRect(),this._overlayRect=this._pane.getBoundingClientRect(),this._viewportRect=this._getNarrowedViewportRect(),this._containerRect=this._overlayContainer.getContainerElement().getBoundingClientRect();const ke=this._getOriginPoint(this._originRect,this._containerRect,Fe);this._applyPosition(Fe,ke)}else this.apply()}withScrollableContainers(Fe){return this._scrollables=Fe,this}withPositions(Fe){return this._preferredPositions=Fe,-1===Fe.indexOf(this._lastPosition)&&(this._lastPosition=null),this._validatePositions(),this}withViewportMargin(Fe){return this._viewportMargin=Fe,this}withFlexibleDimensions(Fe=!0){return this._hasFlexibleDimensions=Fe,this}withGrowAfterOpen(Fe=!0){return this._growAfterOpen=Fe,this}withPush(Fe=!0){return this._canPush=Fe,this}withLockedPosition(Fe=!0){return this._positionLocked=Fe,this}setOrigin(Fe){return this._origin=Fe,this}withDefaultOffsetX(Fe){return this._offsetX=Fe,this}withDefaultOffsetY(Fe){return this._offsetY=Fe,this}withTransformOriginOn(Fe){return this._transformOriginSelector=Fe,this}_getOriginPoint(Fe,ke,Je){let z,N;if("center"==Je.originX)z=Fe.left+Fe.width/2;else{const W=this._isRtl()?Fe.right:Fe.left,Le=this._isRtl()?Fe.left:Fe.right;z="start"==Je.originX?W:Le}return ke.left<0&&(z-=ke.left),N="center"==Je.originY?Fe.top+Fe.height/2:"top"==Je.originY?Fe.top:Fe.bottom,ke.top<0&&(N-=ke.top),{x:z,y:N}}_getOverlayPoint(Fe,ke,Je){let z,N;return z="center"==Je.overlayX?-ke.width/2:"start"===Je.overlayX?this._isRtl()?-ke.width:0:this._isRtl()?0:-ke.width,N="center"==Je.overlayY?-ke.height/2:"top"==Je.overlayY?0:-ke.height,{x:Fe.x+z,y:Fe.y+N}}_getOverlayFit(Fe,ke,Je,z){const N=Ot(ke);let{x:W,y:Le}=Fe,ft=this._getOffset(z,"x"),mt=this._getOffset(z,"y");ft&&(W+=ft),mt&&(Le+=mt);let an=0-Le,dn=Le+N.height-Je.height,In=this._subtractOverflows(N.width,0-W,W+N.width-Je.width),sr=this._subtractOverflows(N.height,an,dn),xn=In*sr;return{visibleArea:xn,isCompletelyWithinViewport:N.width*N.height===xn,fitsInViewportVertically:sr===N.height,fitsInViewportHorizontally:In==N.width}}_canFitWithFlexibleDimensions(Fe,ke,Je){if(this._hasFlexibleDimensions){const z=Je.bottom-ke.y,N=Je.right-ke.x,W=it(this._overlayRef.getConfig().minHeight),Le=it(this._overlayRef.getConfig().minWidth);return(Fe.fitsInViewportVertically||null!=W&&W<=z)&&(Fe.fitsInViewportHorizontally||null!=Le&&Le<=N)}return!1}_pushOverlayOnScreen(Fe,ke,Je){if(this._previousPushAmount&&this._positionLocked)return{x:Fe.x+this._previousPushAmount.x,y:Fe.y+this._previousPushAmount.y};const z=Ot(ke),N=this._viewportRect,W=Math.max(Fe.x+z.width-N.width,0),Le=Math.max(Fe.y+z.height-N.height,0),ft=Math.max(N.top-Je.top-Fe.y,0),mt=Math.max(N.left-Je.left-Fe.x,0);let St=0,Tn=0;return St=z.width<=N.width?mt||-W:Fe.xIn&&!this._isInitialRender&&!this._growAfterOpen&&(W=Fe.y-In/2)}if("end"===ke.overlayX&&!z||"start"===ke.overlayX&&z)an=Je.width-Fe.x+2*this._viewportMargin,St=Fe.x-this._viewportMargin;else if("start"===ke.overlayX&&!z||"end"===ke.overlayX&&z)Tn=Fe.x,St=Je.right-Fe.x;else{const dn=Math.min(Je.right-Fe.x+Je.left,Fe.x),In=this._lastBoundingBoxSize.width;St=2*dn,Tn=Fe.x-dn,St>In&&!this._isInitialRender&&!this._growAfterOpen&&(Tn=Fe.x-In/2)}return{top:W,left:Tn,bottom:Le,right:an,width:St,height:N}}_setBoundingBoxStyles(Fe,ke){const Je=this._calculateBoundingBoxRect(Fe,ke);!this._isInitialRender&&!this._growAfterOpen&&(Je.height=Math.min(Je.height,this._lastBoundingBoxSize.height),Je.width=Math.min(Je.width,this._lastBoundingBoxSize.width));const z={};if(this._hasExactPosition())z.top=z.left="0",z.bottom=z.right=z.maxHeight=z.maxWidth="",z.width=z.height="100%";else{const N=this._overlayRef.getConfig().maxHeight,W=this._overlayRef.getConfig().maxWidth;z.height=(0,y.a1)(Je.height),z.top=(0,y.a1)(Je.top),z.bottom=(0,y.a1)(Je.bottom),z.width=(0,y.a1)(Je.width),z.left=(0,y.a1)(Je.left),z.right=(0,y.a1)(Je.right),z.alignItems="center"===ke.overlayX?"center":"end"===ke.overlayX?"flex-end":"flex-start",z.justifyContent="center"===ke.overlayY?"center":"bottom"===ke.overlayY?"flex-end":"flex-start",N&&(z.maxHeight=(0,y.a1)(N)),W&&(z.maxWidth=(0,y.a1)(W))}this._lastBoundingBoxSize=Je,Ze(this._boundingBox.style,z)}_resetBoundingBoxStyles(){Ze(this._boundingBox.style,{top:"0",left:"0",right:"0",bottom:"0",height:"",width:"",alignItems:"",justifyContent:""})}_resetOverlayElementStyles(){Ze(this._pane.style,{top:"",left:"",bottom:"",right:"",position:"",transform:""})}_setOverlayElementStyles(Fe,ke){const Je={},z=this._hasExactPosition(),N=this._hasFlexibleDimensions,W=this._overlayRef.getConfig();if(z){const St=this._viewportRuler.getViewportScrollPosition();Ze(Je,this._getExactOverlayY(ke,Fe,St)),Ze(Je,this._getExactOverlayX(ke,Fe,St))}else Je.position="static";let Le="",ft=this._getOffset(ke,"x"),mt=this._getOffset(ke,"y");ft&&(Le+=`translateX(${ft}px) `),mt&&(Le+=`translateY(${mt}px)`),Je.transform=Le.trim(),W.maxHeight&&(z?Je.maxHeight=(0,y.a1)(W.maxHeight):N&&(Je.maxHeight="")),W.maxWidth&&(z?Je.maxWidth=(0,y.a1)(W.maxWidth):N&&(Je.maxWidth="")),Ze(this._pane.style,Je)}_getExactOverlayY(Fe,ke,Je){let z={top:"",bottom:""},N=this._getOverlayPoint(ke,this._overlayRect,Fe);return this._isPushed&&(N=this._pushOverlayOnScreen(N,this._overlayRect,Je)),"bottom"===Fe.overlayY?z.bottom=this._document.documentElement.clientHeight-(N.y+this._overlayRect.height)+"px":z.top=(0,y.a1)(N.y),z}_getExactOverlayX(Fe,ke,Je){let W,z={left:"",right:""},N=this._getOverlayPoint(ke,this._overlayRect,Fe);return this._isPushed&&(N=this._pushOverlayOnScreen(N,this._overlayRect,Je)),W=this._isRtl()?"end"===Fe.overlayX?"left":"right":"end"===Fe.overlayX?"right":"left","right"===W?z.right=this._document.documentElement.clientWidth-(N.x+this._overlayRect.width)+"px":z.left=(0,y.a1)(N.x),z}_getScrollVisibility(){const Fe=this._getOriginRect(),ke=this._pane.getBoundingClientRect(),Je=this._scrollables.map(z=>z.getElementRef().nativeElement.getBoundingClientRect());return{isOriginClipped:ce(Fe,Je),isOriginOutsideView:De(Fe,Je),isOverlayClipped:ce(ke,Je),isOverlayOutsideView:De(ke,Je)}}_subtractOverflows(Fe,...ke){return ke.reduce((Je,z)=>Je-Math.max(z,0),Fe)}_getNarrowedViewportRect(){const Fe=this._document.documentElement.clientWidth,ke=this._document.documentElement.clientHeight,Je=this._viewportRuler.getViewportScrollPosition();return{top:Je.top+this._viewportMargin,left:Je.left+this._viewportMargin,right:Je.left+Fe-this._viewportMargin,bottom:Je.top+ke-this._viewportMargin,width:Fe-2*this._viewportMargin,height:ke-2*this._viewportMargin}}_isRtl(){return"rtl"===this._overlayRef.getDirection()}_hasExactPosition(){return!this._hasFlexibleDimensions||this._isPushed}_getOffset(Fe,ke){return"x"===ke?null==Fe.offsetX?this._offsetX:Fe.offsetX:null==Fe.offsetY?this._offsetY:Fe.offsetY}_validatePositions(){}_addPanelClasses(Fe){this._pane&&(0,y.FG)(Fe).forEach(ke=>{""!==ke&&-1===this._appliedPanelClasses.indexOf(ke)&&(this._appliedPanelClasses.push(ke),this._pane.classList.add(ke))})}_clearPanelClasses(){this._pane&&(this._appliedPanelClasses.forEach(Fe=>{this._pane.classList.remove(Fe)}),this._appliedPanelClasses=[])}_getOriginRect(){const Fe=this._origin;if(Fe instanceof c.aKT)return Fe.nativeElement.getBoundingClientRect();if(Fe instanceof Element)return Fe.getBoundingClientRect();const ke=Fe.width||0,Je=Fe.height||0;return{top:Fe.y,bottom:Fe.y+Je,left:Fe.x,right:Fe.x+ke,height:Je,width:ke}}}function Ze(cn,Fe){for(let ke in Fe)Fe.hasOwnProperty(ke)&&(cn[ke]=Fe[ke]);return cn}function it(cn){if("number"!=typeof cn&&null!=cn){const[Fe,ke]=cn.split(Ft);return ke&&"px"!==ke?null:parseFloat(Fe)}return cn||null}function Ot(cn){return{top:Math.floor(cn.top),right:Math.floor(cn.right),bottom:Math.floor(cn.bottom),left:Math.floor(cn.left),width:Math.floor(cn.width),height:Math.floor(cn.height)}}const st="cdk-global-overlay-wrapper";class Xt{_overlayRef;_cssPosition="static";_topOffset="";_bottomOffset="";_alignItems="";_xPosition="";_xOffset="";_width="";_height="";_isDisposed=!1;attach(Fe){const ke=Fe.getConfig();this._overlayRef=Fe,this._width&&!ke.width&&Fe.updateSize({width:this._width}),this._height&&!ke.height&&Fe.updateSize({height:this._height}),Fe.hostElement.classList.add(st),this._isDisposed=!1}top(Fe=""){return this._bottomOffset="",this._topOffset=Fe,this._alignItems="flex-start",this}left(Fe=""){return this._xOffset=Fe,this._xPosition="left",this}bottom(Fe=""){return this._topOffset="",this._bottomOffset=Fe,this._alignItems="flex-end",this}right(Fe=""){return this._xOffset=Fe,this._xPosition="right",this}start(Fe=""){return this._xOffset=Fe,this._xPosition="start",this}end(Fe=""){return this._xOffset=Fe,this._xPosition="end",this}width(Fe=""){return this._overlayRef?this._overlayRef.updateSize({width:Fe}):this._width=Fe,this}height(Fe=""){return this._overlayRef?this._overlayRef.updateSize({height:Fe}):this._height=Fe,this}centerHorizontally(Fe=""){return this.left(Fe),this._xPosition="center",this}centerVertically(Fe=""){return this.top(Fe),this._alignItems="center",this}apply(){if(!this._overlayRef||!this._overlayRef.hasAttached())return;const Fe=this._overlayRef.overlayElement.style,ke=this._overlayRef.hostElement.style,Je=this._overlayRef.getConfig(),{width:z,height:N,maxWidth:W,maxHeight:Le}=Je,ft=!("100%"!==z&&"100vw"!==z||W&&"100%"!==W&&"100vw"!==W),mt=!("100%"!==N&&"100vh"!==N||Le&&"100%"!==Le&&"100vh"!==Le),St=this._xPosition,Tn=this._xOffset,an="rtl"===this._overlayRef.getConfig().direction;let dn="",In="",sr="";ft?sr="flex-start":"center"===St?(sr="center",an?In=Tn:dn=Tn):an?"left"===St||"end"===St?(sr="flex-end",dn=Tn):("right"===St||"start"===St)&&(sr="flex-start",In=Tn):"left"===St||"start"===St?(sr="flex-start",dn=Tn):("right"===St||"end"===St)&&(sr="flex-end",In=Tn),Fe.position=this._cssPosition,Fe.marginLeft=ft?"0":dn,Fe.marginTop=mt?"0":this._topOffset,Fe.marginBottom=this._bottomOffset,Fe.marginRight=ft?"0":In,ke.justifyContent=sr,ke.alignItems=mt?"flex-start":this._alignItems}dispose(){if(this._isDisposed||!this._overlayRef)return;const Fe=this._overlayRef.overlayElement.style,ke=this._overlayRef.hostElement,Je=ke.style;ke.classList.remove(st),Je.justifyContent=Je.alignItems=Fe.marginTop=Fe.marginBottom=Fe.marginLeft=Fe.marginRight=Fe.position="",this._overlayRef=null,this._isDisposed=!0}}let Mt=(()=>{class cn{_viewportRuler=(0,c.WQX)(i.Xj);_document=(0,c.WQX)(a.qQ);_platform=(0,c.WQX)(w.OD);_overlayContainer=(0,c.WQX)(_t);constructor(){}global(){return new Xt}flexibleConnectedTo(ke){return new Ke(ke,this._viewportRuler,this._document,this._platform,this._overlayContainer)}static \u0275fac=function(Je){return new(Je||cn)};static \u0275prov=c.jDH({token:cn,factory:cn.\u0275fac,providedIn:"root"})}return cn})(),Kt=(()=>{class cn{scrollStrategies=(0,c.WQX)(Ce);_overlayContainer=(0,c.WQX)(_t);_positionBuilder=(0,c.WQX)(Mt);_keyboardDispatcher=(0,c.WQX)(bn);_injector=(0,c.WQX)(c.zZn);_ngZone=(0,c.WQX)(c.SKi);_document=(0,c.WQX)(a.qQ);_directionality=(0,c.WQX)(M.dS);_location=(0,c.WQX)(a.aZ);_outsideClickDispatcher=(0,c.WQX)(Vn);_animationsModuleType=(0,c.WQX)(c.bc$,{optional:!0});_idGenerator=(0,c.WQX)(L.g7);_appRef;_styleLoader=(0,c.WQX)(Z.l);constructor(){}create(ke){this._styleLoader.load(qe);const Je=this._createHostElement(),z=this._createPaneElement(Je),N=this._createPortalOutlet(z),W=new Be(ke);return W.direction=W.direction||this._directionality.value,new ze(N,Je,z,W,this._ngZone,this._keyboardDispatcher,this._document,this._location,this._outsideClickDispatcher,"NoopAnimations"===this._animationsModuleType,this._injector.get(c.uvJ))}position(){return this._positionBuilder}_createPaneElement(ke){const Je=this._document.createElement("div");return Je.id=this._idGenerator.getId("cdk-overlay-"),Je.classList.add("cdk-overlay-pane"),ke.appendChild(Je),Je}_createHostElement(){const ke=this._document.createElement("div");return this._overlayContainer.getContainerElement().appendChild(ke),ke}_createPortalOutlet(ke){return this._appRef||(this._appRef=this._injector.get(c.o8S)),new O.aI(ke,null,this._appRef,this._injector,this._document)}static \u0275fac=function(Je){return new(Je||cn)};static \u0275prov=c.jDH({token:cn,factory:cn.\u0275fac,providedIn:"root"})}return cn})();const rt=[{originX:"start",originY:"bottom",overlayX:"start",overlayY:"top"},{originX:"start",originY:"top",overlayX:"start",overlayY:"bottom"},{originX:"end",originY:"top",overlayX:"end",overlayY:"bottom"},{originX:"end",originY:"bottom",overlayX:"end",overlayY:"top"}],Vt=new c.nKC("cdk-connected-overlay-scroll-strategy",{providedIn:"root",factory:()=>{const cn=(0,c.WQX)(Kt);return()=>cn.scrollStrategies.reposition()}});let en=(()=>{class cn{elementRef=(0,c.WQX)(c.aKT);constructor(){}static \u0275fac=function(Je){return new(Je||cn)};static \u0275dir=c.FsC({type:cn,selectors:[["","cdk-overlay-origin",""],["","overlay-origin",""],["","cdkOverlayOrigin",""]],exportAs:["cdkOverlayOrigin"]})}return cn})(),kn=(()=>{class cn{_overlay=(0,c.WQX)(Kt);_dir=(0,c.WQX)(M.dS,{optional:!0});_overlayRef;_templatePortal;_backdropSubscription=re.yU.EMPTY;_attachSubscription=re.yU.EMPTY;_detachSubscription=re.yU.EMPTY;_positionSubscription=re.yU.EMPTY;_offsetX;_offsetY;_position;_scrollStrategyFactory=(0,c.WQX)(Vt);_disposeOnNavigation=!1;_ngZone=(0,c.WQX)(c.SKi);origin;positions;positionStrategy;get offsetX(){return this._offsetX}set offsetX(ke){this._offsetX=ke,this._position&&this._updatePositionStrategy(this._position)}get offsetY(){return this._offsetY}set offsetY(ke){this._offsetY=ke,this._position&&this._updatePositionStrategy(this._position)}width;height;minWidth;minHeight;backdropClass;panelClass;viewportMargin=0;scrollStrategy;open=!1;disableClose=!1;transformOriginSelector;hasBackdrop=!1;lockPosition=!1;flexibleDimensions=!1;growAfterOpen=!1;push=!1;get disposeOnNavigation(){return this._disposeOnNavigation}set disposeOnNavigation(ke){this._disposeOnNavigation=ke}backdropClick=new c.bkB;positionChange=new c.bkB;attach=new c.bkB;detach=new c.bkB;overlayKeydown=new c.bkB;overlayOutsideClick=new c.bkB;constructor(){const ke=(0,c.WQX)(c.C4Q),Je=(0,c.WQX)(c.c1b);this._templatePortal=new O.VA(ke,Je),this.scrollStrategy=this._scrollStrategyFactory()}get overlayRef(){return this._overlayRef}get dir(){return this._dir?this._dir.value:"ltr"}ngOnDestroy(){this._attachSubscription.unsubscribe(),this._detachSubscription.unsubscribe(),this._backdropSubscription.unsubscribe(),this._positionSubscription.unsubscribe(),this._overlayRef&&this._overlayRef.dispose()}ngOnChanges(ke){this._position&&(this._updatePositionStrategy(this._position),this._overlayRef.updateSize({width:this.width,minWidth:this.minWidth,height:this.height,minHeight:this.minHeight}),ke.origin&&this.open&&this._position.apply()),ke.open&&(this.open?this._attachOverlay():this._detachOverlay())}_createOverlay(){(!this.positions||!this.positions.length)&&(this.positions=rt);const ke=this._overlayRef=this._overlay.create(this._buildConfig());this._attachSubscription=ke.attachments().subscribe(()=>this.attach.emit()),this._detachSubscription=ke.detachments().subscribe(()=>this.detach.emit()),ke.keydownEvents().subscribe(Je=>{this.overlayKeydown.next(Je),Je.keyCode===se._f&&!this.disableClose&&!(0,se.rp)(Je)&&(Je.preventDefault(),this._detachOverlay())}),this._overlayRef.outsidePointerEvents().subscribe(Je=>{const z=this._getOriginElement(),N=(0,w.Fb)(Je);(!z||z!==N&&!z.contains(N))&&this.overlayOutsideClick.next(Je)})}_buildConfig(){const ke=this._position=this.positionStrategy||this._createPositionStrategy(),Je=new Be({direction:this._dir||"ltr",positionStrategy:ke,scrollStrategy:this.scrollStrategy,hasBackdrop:this.hasBackdrop,disposeOnNavigation:this.disposeOnNavigation});return(this.width||0===this.width)&&(Je.width=this.width),(this.height||0===this.height)&&(Je.height=this.height),(this.minWidth||0===this.minWidth)&&(Je.minWidth=this.minWidth),(this.minHeight||0===this.minHeight)&&(Je.minHeight=this.minHeight),this.backdropClass&&(Je.backdropClass=this.backdropClass),this.panelClass&&(Je.panelClass=this.panelClass),Je}_updatePositionStrategy(ke){const Je=this.positions.map(z=>({originX:z.originX,originY:z.originY,overlayX:z.overlayX,overlayY:z.overlayY,offsetX:z.offsetX||this.offsetX,offsetY:z.offsetY||this.offsetY,panelClass:z.panelClass||void 0}));return ke.setOrigin(this._getOrigin()).withPositions(Je).withFlexibleDimensions(this.flexibleDimensions).withPush(this.push).withGrowAfterOpen(this.growAfterOpen).withViewportMargin(this.viewportMargin).withLockedPosition(this.lockPosition).withTransformOriginOn(this.transformOriginSelector)}_createPositionStrategy(){const ke=this._overlay.position().flexibleConnectedTo(this._getOrigin());return this._updatePositionStrategy(ke),ke}_getOrigin(){return this.origin instanceof en?this.origin.elementRef:this.origin}_getOriginElement(){return this.origin instanceof en?this.origin.elementRef.nativeElement:this.origin instanceof c.aKT?this.origin.nativeElement:typeof Element<"u"&&this.origin instanceof Element?this.origin:null}_attachOverlay(){this._overlayRef?this._overlayRef.getConfig().hasBackdrop=this.hasBackdrop:this._createOverlay(),this._overlayRef.hasAttached()||this._overlayRef.attach(this._templatePortal),this.hasBackdrop?this._backdropSubscription=this._overlayRef.backdropClick().subscribe(ke=>{this.backdropClick.emit(ke)}):this._backdropSubscription.unsubscribe(),this._positionSubscription.unsubscribe(),this.positionChange.observers.length>0&&(this._positionSubscription=this._position.positionChanges.pipe((0,S.v)(()=>this.positionChange.observers.length>0)).subscribe(ke=>{this._ngZone.run(()=>this.positionChange.emit(ke)),0===this.positionChange.observers.length&&this._positionSubscription.unsubscribe()}))}_detachOverlay(){this._overlayRef&&this._overlayRef.detach(),this._backdropSubscription.unsubscribe(),this._positionSubscription.unsubscribe()}static \u0275fac=function(Je){return new(Je||cn)};static \u0275dir=c.FsC({type:cn,selectors:[["","cdk-connected-overlay",""],["","connected-overlay",""],["","cdkConnectedOverlay",""]],inputs:{origin:[0,"cdkConnectedOverlayOrigin","origin"],positions:[0,"cdkConnectedOverlayPositions","positions"],positionStrategy:[0,"cdkConnectedOverlayPositionStrategy","positionStrategy"],offsetX:[0,"cdkConnectedOverlayOffsetX","offsetX"],offsetY:[0,"cdkConnectedOverlayOffsetY","offsetY"],width:[0,"cdkConnectedOverlayWidth","width"],height:[0,"cdkConnectedOverlayHeight","height"],minWidth:[0,"cdkConnectedOverlayMinWidth","minWidth"],minHeight:[0,"cdkConnectedOverlayMinHeight","minHeight"],backdropClass:[0,"cdkConnectedOverlayBackdropClass","backdropClass"],panelClass:[0,"cdkConnectedOverlayPanelClass","panelClass"],viewportMargin:[0,"cdkConnectedOverlayViewportMargin","viewportMargin"],scrollStrategy:[0,"cdkConnectedOverlayScrollStrategy","scrollStrategy"],open:[0,"cdkConnectedOverlayOpen","open"],disableClose:[0,"cdkConnectedOverlayDisableClose","disableClose"],transformOriginSelector:[0,"cdkConnectedOverlayTransformOriginOn","transformOriginSelector"],hasBackdrop:[2,"cdkConnectedOverlayHasBackdrop","hasBackdrop",c.L39],lockPosition:[2,"cdkConnectedOverlayLockPosition","lockPosition",c.L39],flexibleDimensions:[2,"cdkConnectedOverlayFlexibleDimensions","flexibleDimensions",c.L39],growAfterOpen:[2,"cdkConnectedOverlayGrowAfterOpen","growAfterOpen",c.L39],push:[2,"cdkConnectedOverlayPush","push",c.L39],disposeOnNavigation:[2,"cdkConnectedOverlayDisposeOnNavigation","disposeOnNavigation",c.L39]},outputs:{backdropClick:"backdropClick",positionChange:"positionChange",attach:"attach",detach:"detach",overlayKeydown:"overlayKeydown",overlayOutsideClick:"overlayOutsideClick"},exportAs:["cdkConnectedOverlay"],features:[c.GFd,c.OA$]})}return cn})();const Nr={provide:Vt,deps:[Kt],useFactory:function Kn(cn){return()=>cn.scrollStrategies.reposition()}};let Rn=(()=>{class cn{static \u0275fac=function(Je){return new(Je||cn)};static \u0275mod=c.$C({type:cn});static \u0275inj=c.G2t({providers:[Kt,Nr],imports:[M.jI,O.jc,i.E9,i.E9]})}return cn})()},2147:(o,s,r)=>{"use strict";r.d(s,{BD:()=>se,BQ:()=>L,CZ:()=>pe,Fb:()=>xe,KT:()=>be,MU:()=>S,OD:()=>y,r5:()=>Z,v8:()=>De,vc:()=>Oe});var i=r(3107),a=r(4460);let c;try{c=typeof Intl<"u"&&Intl.v8BreakIterator}catch{c=!1}let C,y=(()=>{class ce{_platformId=(0,i.WQX)(i.Agw);isBrowser=this._platformId?(0,a.UE)(this._platformId):"object"==typeof document&&!!document;EDGE=this.isBrowser&&/(edge)/i.test(navigator.userAgent);TRIDENT=this.isBrowser&&/(msie|trident)/i.test(navigator.userAgent);BLINK=this.isBrowser&&!(!window.chrome&&!c)&&typeof CSS<"u"&&!this.EDGE&&!this.TRIDENT;WEBKIT=this.isBrowser&&/AppleWebKit/i.test(navigator.userAgent)&&!this.BLINK&&!this.EDGE&&!this.TRIDENT;IOS=this.isBrowser&&/iPad|iPhone|iPod/.test(navigator.userAgent)&&!("MSStream"in window);FIREFOX=this.isBrowser&&/(firefox|minefield)/i.test(navigator.userAgent);ANDROID=this.isBrowser&&/android/i.test(navigator.userAgent)&&!this.TRIDENT;SAFARI=this.isBrowser&&/safari/i.test(navigator.userAgent)&&this.WEBKIT;constructor(){}static \u0275fac=function(Be){return new(Be||ce)};static \u0275prov=i.jDH({token:ce,factory:ce.\u0275fac,providedIn:"root"})}return ce})();const T=["color","button","checkbox","date","datetime-local","email","file","hidden","image","month","number","password","radio","range","reset","search","submit","tel","text","time","url","week"];function S(){if(C)return C;if("object"!=typeof document||!document)return C=new Set(T),C;let ce=document.createElement("input");return C=new Set(T.filter(ue=>(ce.setAttribute("type",ue),ce.type===ue))),C}let M;function L(ce){return function O(){if(null==M&&typeof window<"u")try{window.addEventListener("test",null,Object.defineProperty({},"passive",{get:()=>M=!0}))}finally{M=M||!1}return M}()?ce:!!ce.capture}var Z=function(ce){return ce[ce.NORMAL=0]="NORMAL",ce[ce.NEGATED=1]="NEGATED",ce[ce.INVERTED=2]="INVERTED",ce}(Z||{});let q,re,ae;function pe(){if(null==re){if("object"!=typeof document||!document||"function"!=typeof Element||!Element)return re=!1,re;if("scrollBehavior"in document.documentElement.style)re=!0;else{const ce=Element.prototype.scrollTo;re=!!ce&&!/\{\s*\[native code\]\s*\}/.test(ce.toString())}}return re}function se(){if("object"!=typeof document||!document)return Z.NORMAL;if(null==q){const ce=document.createElement("div"),ue=ce.style;ce.dir="rtl",ue.width="1px",ue.overflow="auto",ue.visibility="hidden",ue.pointerEvents="none",ue.position="absolute";const Ce=document.createElement("div"),Be=Ce.style;Be.width="2px",Be.height="1px",ce.appendChild(Ce),document.body.appendChild(ce),q=Z.NORMAL,0===ce.scrollLeft&&(ce.scrollLeft=1,q=0===ce.scrollLeft?Z.NEGATED:Z.INVERTED),ce.remove()}return q}function be(ce){if(function me(){if(null==ae){const ce=typeof document<"u"?document.head:null;ae=!(!ce||!ce.createShadowRoot&&!ce.attachShadow)}return ae}()){const ue=ce.getRootNode?ce.getRootNode():null;if(typeof ShadowRoot<"u"&&ShadowRoot&&ue instanceof ShadowRoot)return ue}return null}function Oe(){let ce=typeof document<"u"&&document?document.activeElement:null;for(;ce&&ce.shadowRoot;){const ue=ce.shadowRoot.activeElement;if(ue===ce)break;ce=ue}return ce}function xe(ce){return ce.composedPath?ce.composedPath()[0]:ce.target}function De(){return typeof __karma__<"u"&&!!__karma__||typeof jasmine<"u"&&!!jasmine||typeof jest<"u"&&!!jest||typeof Mocha<"u"&&!!Mocha}},6192:(o,s,r)=>{"use strict";r.d(s,{A8:()=>O,I3:()=>be,VA:()=>L,aI:()=>pe,jc:()=>xe,lb:()=>q});var i=r(3107),a=r(4460);class M{_attachedHost;attach(ue){return this._attachedHost=ue,ue.attach(this)}detach(){let ue=this._attachedHost;null!=ue&&(this._attachedHost=null,ue.detach())}get isAttached(){return null!=this._attachedHost}setAttachedHost(ue){this._attachedHost=ue}}class O extends M{component;viewContainerRef;injector;componentFactoryResolver;projectableNodes;constructor(ue,Ce,Be,at,dt){super(),this.component=ue,this.viewContainerRef=Ce,this.injector=Be,this.projectableNodes=dt}}class L extends M{templateRef;viewContainerRef;context;injector;constructor(ue,Ce,Be,at){super(),this.templateRef=ue,this.viewContainerRef=Ce,this.context=Be,this.injector=at}get origin(){return this.templateRef.elementRef}attach(ue,Ce=this.context){return this.context=Ce,super.attach(ue)}detach(){return this.context=void 0,super.detach()}}class Z extends M{element;constructor(ue){super(),this.element=ue instanceof i.aKT?ue.nativeElement:ue}}class q{_attachedPortal;_disposeFn;_isDisposed=!1;hasAttached(){return!!this._attachedPortal}attach(ue){return ue instanceof O?(this._attachedPortal=ue,this.attachComponentPortal(ue)):ue instanceof L?(this._attachedPortal=ue,this.attachTemplatePortal(ue)):this.attachDomPortal&&ue instanceof Z?(this._attachedPortal=ue,this.attachDomPortal(ue)):void 0}attachDomPortal=null;detach(){this._attachedPortal&&(this._attachedPortal.setAttachedHost(null),this._attachedPortal=null),this._invokeDisposeFn()}dispose(){this.hasAttached()&&this.detach(),this._invokeDisposeFn(),this._isDisposed=!0}setDisposeFn(ue){this._disposeFn=ue}_invokeDisposeFn(){this._disposeFn&&(this._disposeFn(),this._disposeFn=null)}}class pe extends q{outletElement;_appRef;_defaultInjector;_document;constructor(ue,Ce,Be,at,dt){super(),this.outletElement=ue,this._appRef=Be,this._defaultInjector=at,this._document=dt}attachComponentPortal(ue){let Ce;if(ue.viewContainerRef){const Be=ue.injector||ue.viewContainerRef.injector,at=Be.get(i.Vns,null,{optional:!0})||void 0;Ce=ue.viewContainerRef.createComponent(ue.component,{index:ue.viewContainerRef.length,injector:Be,ngModuleRef:at,projectableNodes:ue.projectableNodes||void 0}),this.setDisposeFn(()=>Ce.destroy())}else Ce=(0,i.a0P)(ue.component,{elementInjector:ue.injector||this._defaultInjector||i.zZn.NULL,environmentInjector:this._appRef.injector,projectableNodes:ue.projectableNodes||void 0}),this._appRef.attachView(Ce.hostView),this.setDisposeFn(()=>{this._appRef.viewCount>0&&this._appRef.detachView(Ce.hostView),Ce.destroy()});return this.outletElement.appendChild(this._getComponentRootNode(Ce)),this._attachedPortal=ue,Ce}attachTemplatePortal(ue){let Ce=ue.viewContainerRef,Be=Ce.createEmbeddedView(ue.templateRef,ue.context,{injector:ue.injector});return Be.rootNodes.forEach(at=>this.outletElement.appendChild(at)),Be.detectChanges(),this.setDisposeFn(()=>{let at=Ce.indexOf(Be);-1!==at&&Ce.remove(at)}),this._attachedPortal=ue,Be}attachDomPortal=ue=>{const Ce=ue.element,Be=this._document.createComment("dom-portal");Ce.parentNode.insertBefore(Be,Ce),this.outletElement.appendChild(Ce),this._attachedPortal=ue,super.setDisposeFn(()=>{Be.parentNode&&Be.parentNode.replaceChild(Ce,Be)})};dispose(){super.dispose(),this.outletElement.remove()}_getComponentRootNode(ue){return ue.hostView.rootNodes[0]}}let be=(()=>{class ce extends q{_moduleRef=(0,i.WQX)(i.Vns,{optional:!0});_document=(0,i.WQX)(a.qQ);_viewContainerRef=(0,i.WQX)(i.c1b);_isInitialized=!1;_attachedRef;constructor(){super()}get portal(){return this._attachedPortal}set portal(Ce){this.hasAttached()&&!Ce&&!this._isInitialized||(this.hasAttached()&&super.detach(),Ce&&super.attach(Ce),this._attachedPortal=Ce||null)}attached=new i.bkB;get attachedRef(){return this._attachedRef}ngOnInit(){this._isInitialized=!0}ngOnDestroy(){super.dispose(),this._attachedRef=this._attachedPortal=null}attachComponentPortal(Ce){Ce.setAttachedHost(this);const Be=null!=Ce.viewContainerRef?Ce.viewContainerRef:this._viewContainerRef,at=Be.createComponent(Ce.component,{index:Be.length,injector:Ce.injector||Be.injector,projectableNodes:Ce.projectableNodes||void 0,ngModuleRef:this._moduleRef||void 0});return Be!==this._viewContainerRef&&this._getRootNode().appendChild(at.hostView.rootNodes[0]),super.setDisposeFn(()=>at.destroy()),this._attachedPortal=Ce,this._attachedRef=at,this.attached.emit(at),at}attachTemplatePortal(Ce){Ce.setAttachedHost(this);const Be=this._viewContainerRef.createEmbeddedView(Ce.templateRef,Ce.context,{injector:Ce.injector});return super.setDisposeFn(()=>this._viewContainerRef.clear()),this._attachedPortal=Ce,this._attachedRef=Be,this.attached.emit(Be),Be}attachDomPortal=Ce=>{const Be=Ce.element,at=this._document.createComment("dom-portal");Ce.setAttachedHost(this),Be.parentNode.insertBefore(at,Be),this._getRootNode().appendChild(Be),this._attachedPortal=Ce,super.setDisposeFn(()=>{at.parentNode&&at.parentNode.replaceChild(Be,at)})};_getRootNode(){const Ce=this._viewContainerRef.element.nativeElement;return Ce.nodeType===Ce.ELEMENT_NODE?Ce:Ce.parentNode}static \u0275fac=function(Be){return new(Be||ce)};static \u0275dir=i.FsC({type:ce,selectors:[["","cdkPortalOutlet",""]],inputs:{portal:[0,"cdkPortalOutlet","portal"]},outputs:{attached:"attached"},exportAs:["cdkPortalOutlet"],features:[i.Vt3]})}return ce})(),xe=(()=>{class ce{static \u0275fac=function(Be){return new(Be||ce)};static \u0275mod=i.$C({type:ce});static \u0275inj=i.G2t({})}return ce})()},5467:(o,s,r)=>{"use strict";r.d(s,{Y:()=>y,l:()=>c});var i=r(3107);const a=new WeakMap;let c=(()=>{class w{_appRef;_injector=(0,i.WQX)(i.zZn);_environmentInjector=(0,i.WQX)(i.uvJ);load(T){const S=this._appRef=this._appRef||this._injector.get(i.o8S);let M=a.get(S);M||(M={loaders:new Set,refs:[]},a.set(S,M),S.onDestroy(()=>{a.get(S)?.refs.forEach(O=>O.destroy()),a.delete(S)})),M.loaders.has(T)||(M.loaders.add(T),M.refs.push((0,i.a0P)(T,{environmentInjector:this._environmentInjector})))}static \u0275fac=function(S){return new(S||w)};static \u0275prov=i.jDH({token:w,factory:w.\u0275fac,providedIn:"root"})}return w})(),y=(()=>{class w{static \u0275fac=function(S){return new(S||w)};static \u0275cmp=i.VBU({type:w,selectors:[["ng-component"]],exportAs:["cdkVisuallyHidden"],decls:0,vars:0,template:function(S,M){},styles:[".cdk-visually-hidden{border:0;clip:rect(0 0 0 0);height:1px;margin:-1px;overflow:hidden;padding:0;position:absolute;width:1px;white-space:nowrap;outline:0;-webkit-appearance:none;-moz-appearance:none;left:0}[dir=rtl] .cdk-visually-hidden{left:auto;right:0}"],encapsulation:2,changeDetection:0})}return w})()},8108:(o,s,r)=>{"use strict";r.d(s,{uv:()=>lt,Gj:()=>Ze,R:()=>bt,E9:()=>it,Xj:()=>gn});var i=r(3022),a=r(3107),c=r(8447),y=r(3016),w=r(1698),C=r(909),T=r(9899),S=r(5710);const M={schedule(Ot){let $t=requestAnimationFrame,Te=cancelAnimationFrame;const{delegate:Ee}=M;Ee&&($t=Ee.requestAnimationFrame,Te=Ee.cancelAnimationFrame);const st=$t(Xt=>{Te=void 0,Ot(Xt)});return new S.yU(()=>Te?.(st))},requestAnimationFrame(...Ot){const{delegate:$t}=M;return($t?.requestAnimationFrame||requestAnimationFrame)(...Ot)},cancelAnimationFrame(...Ot){const{delegate:$t}=M;return($t?.cancelAnimationFrame||cancelAnimationFrame)(...Ot)},delegate:void 0};var L=r(8050);new class Z extends L.q{flush($t){this._active=!0;const Te=this._scheduled;this._scheduled=void 0;const{actions:Ee}=this;let st;$t=$t||Ee.shift();do{if(st=$t.execute($t.state,$t.delay))break}while(($t=Ee[0])&&$t.id===Te&&Ee.shift());if(this._active=!1,st){for(;($t=Ee[0])&&$t.id===Te&&Ee.shift();)$t.unsubscribe();throw st}}}(class O extends T.R{constructor($t,Te){super($t,Te),this.scheduler=$t,this.work=Te}requestAsyncId($t,Te,Ee=0){return null!==Ee&&Ee>0?super.requestAsyncId($t,Te,Ee):($t.actions.push(this),$t._scheduled||($t._scheduled=M.requestAnimationFrame(()=>$t.flush(void 0))))}recycleAsyncId($t,Te,Ee=0){var st;if(null!=Ee?Ee>0:this.delay>0)return super.recycleAsyncId($t,Te,Ee);const{actions:Xt}=$t;null!=Te&&(null===(st=Xt[Xt.length-1])||void 0===st?void 0:st.id)!==Te&&(M.cancelAnimationFrame(Te),$t._scheduled=void 0)}});r(4984);var se=r(5684),ae=r(1483),me=r(5424),be=r(2147),Oe=r(4460),xe=r(2944);let bt=(()=>{class Ot{_ngZone=(0,a.WQX)(a.SKi);_platform=(0,a.WQX)(be.OD);_document=(0,a.WQX)(Oe.qQ,{optional:!0});constructor(){}_scrolled=new c.B;_globalSubscription=null;_scrolledCount=0;scrollContainers=new Map;register(Te){this.scrollContainers.has(Te)||this.scrollContainers.set(Te,Te.elementScrolled().subscribe(()=>this._scrolled.next(Te)))}deregister(Te){const Ee=this.scrollContainers.get(Te);Ee&&(Ee.unsubscribe(),this.scrollContainers.delete(Te))}scrolled(Te=20){return this._platform.isBrowser?new w.c(Ee=>{this._globalSubscription||this._addGlobalListener();const st=Te>0?this._scrolled.pipe((0,se.Z)(Te)).subscribe(Ee):this._scrolled.subscribe(Ee);return this._scrolledCount++,()=>{st.unsubscribe(),this._scrolledCount--,this._scrolledCount||this._removeGlobalListener()}}):(0,y.of)()}ngOnDestroy(){this._removeGlobalListener(),this.scrollContainers.forEach((Te,Ee)=>this.deregister(Ee)),this._scrolled.complete()}ancestorScrolled(Te,Ee){const st=this.getAncestorScrollContainers(Te);return this.scrolled(Ee).pipe((0,ae.p)(Xt=>!Xt||st.indexOf(Xt)>-1))}getAncestorScrollContainers(Te){const Ee=[];return this.scrollContainers.forEach((st,Xt)=>{this._scrollableContainsElement(Xt,Te)&&Ee.push(Xt)}),Ee}_getWindow(){return this._document.defaultView||window}_scrollableContainsElement(Te,Ee){let st=(0,i.i8)(Ee),Xt=Te.getElementRef().nativeElement;do{if(st==Xt)return!0}while(st=st.parentElement);return!1}_addGlobalListener(){this._globalSubscription=this._ngZone.runOutsideAngular(()=>{const Te=this._getWindow();return(0,C.R)(Te.document,"scroll").subscribe(()=>this._scrolled.next())})}_removeGlobalListener(){this._globalSubscription&&(this._globalSubscription.unsubscribe(),this._globalSubscription=null)}static \u0275fac=function(Ee){return new(Ee||Ot)};static \u0275prov=a.jDH({token:Ot,factory:Ot.\u0275fac,providedIn:"root"})}return Ot})(),lt=(()=>{class Ot{elementRef=(0,a.WQX)(a.aKT);scrollDispatcher=(0,a.WQX)(bt);ngZone=(0,a.WQX)(a.SKi);dir=(0,a.WQX)(xe.dS,{optional:!0});_destroyed=new c.B;_elementScrolled=new w.c(Te=>this.ngZone.runOutsideAngular(()=>(0,C.R)(this.elementRef.nativeElement,"scroll").pipe((0,me.Q)(this._destroyed)).subscribe(Te)));constructor(){}ngOnInit(){this.scrollDispatcher.register(this)}ngOnDestroy(){this.scrollDispatcher.deregister(this),this._destroyed.next(),this._destroyed.complete()}elementScrolled(){return this._elementScrolled}getElementRef(){return this.elementRef}scrollTo(Te){const Ee=this.elementRef.nativeElement,st=this.dir&&"rtl"==this.dir.value;null==Te.left&&(Te.left=st?Te.end:Te.start),null==Te.right&&(Te.right=st?Te.start:Te.end),null!=Te.bottom&&(Te.top=Ee.scrollHeight-Ee.clientHeight-Te.bottom),st&&(0,be.BD)()!=be.r5.NORMAL?(null!=Te.left&&(Te.right=Ee.scrollWidth-Ee.clientWidth-Te.left),(0,be.BD)()==be.r5.INVERTED?Te.left=Te.right:(0,be.BD)()==be.r5.NEGATED&&(Te.left=Te.right?-Te.right:Te.right)):null!=Te.right&&(Te.left=Ee.scrollWidth-Ee.clientWidth-Te.right),this._applyScrollToOptions(Te)}_applyScrollToOptions(Te){const Ee=this.elementRef.nativeElement;(0,be.CZ)()?Ee.scrollTo(Te):(null!=Te.top&&(Ee.scrollTop=Te.top),null!=Te.left&&(Ee.scrollLeft=Te.left))}measureScrollOffset(Te){const Ee="left",Xt=this.elementRef.nativeElement;if("top"==Te)return Xt.scrollTop;if("bottom"==Te)return Xt.scrollHeight-Xt.clientHeight-Xt.scrollTop;const Mt=this.dir&&"rtl"==this.dir.value;return"start"==Te?Te=Mt?"right":Ee:"end"==Te&&(Te=Mt?Ee:"right"),Mt&&(0,be.BD)()==be.r5.INVERTED?Te==Ee?Xt.scrollWidth-Xt.clientWidth-Xt.scrollLeft:Xt.scrollLeft:Mt&&(0,be.BD)()==be.r5.NEGATED?Te==Ee?Xt.scrollLeft+Xt.scrollWidth-Xt.clientWidth:-Xt.scrollLeft:Te==Ee?Xt.scrollLeft:Xt.scrollWidth-Xt.clientWidth-Xt.scrollLeft}static \u0275fac=function(Ee){return new(Ee||Ot)};static \u0275dir=a.FsC({type:Ot,selectors:[["","cdk-scrollable",""],["","cdkScrollable",""]]})}return Ot})(),gn=(()=>{class Ot{_platform=(0,a.WQX)(be.OD);_viewportSize;_change=new c.B;_changeListener=Te=>{this._change.next(Te)};_document=(0,a.WQX)(Oe.qQ,{optional:!0});constructor(){(0,a.WQX)(a.SKi).runOutsideAngular(()=>{if(this._platform.isBrowser){const Ee=this._getWindow();Ee.addEventListener("resize",this._changeListener),Ee.addEventListener("orientationchange",this._changeListener)}this.change().subscribe(()=>this._viewportSize=null)})}ngOnDestroy(){if(this._platform.isBrowser){const Te=this._getWindow();Te.removeEventListener("resize",this._changeListener),Te.removeEventListener("orientationchange",this._changeListener)}this._change.complete()}getViewportSize(){this._viewportSize||this._updateViewportSize();const Te={width:this._viewportSize.width,height:this._viewportSize.height};return this._platform.isBrowser||(this._viewportSize=null),Te}getViewportRect(){const Te=this.getViewportScrollPosition(),{width:Ee,height:st}=this.getViewportSize();return{top:Te.top,left:Te.left,bottom:Te.top+st,right:Te.left+Ee,height:st,width:Ee}}getViewportScrollPosition(){if(!this._platform.isBrowser)return{top:0,left:0};const Te=this._document,Ee=this._getWindow(),st=Te.documentElement,Xt=st.getBoundingClientRect();return{top:-Xt.top||Te.body.scrollTop||Ee.scrollY||st.scrollTop||0,left:-Xt.left||Te.body.scrollLeft||Ee.scrollX||st.scrollLeft||0}}change(Te=20){return Te>0?this._change.pipe((0,se.Z)(Te)):this._change}_getWindow(){return this._document.defaultView||window}_updateViewportSize(){const Te=this._getWindow();this._viewportSize=this._platform.isBrowser?{width:Te.innerWidth,height:Te.innerHeight}:{width:0,height:0}}static \u0275fac=function(Ee){return new(Ee||Ot)};static \u0275prov=a.jDH({token:Ot,factory:Ot.\u0275fac,providedIn:"root"})}return Ot})(),Ze=(()=>{class Ot{static \u0275fac=function(Ee){return new(Ee||Ot)};static \u0275mod=a.$C({type:Ot});static \u0275inj=a.G2t({})}return Ot})(),it=(()=>{class Ot{static \u0275fac=function(Ee){return new(Ee||Ot)};static \u0275mod=a.$C({type:Ot});static \u0275inj=a.G2t({imports:[xe.jI,Ze,xe.jI,Ze]})}return Ot})()},708:(o,s,r)=>{"use strict";r.d(s,{EE:()=>se,P8:()=>q,xb:()=>pe});var i=r(2147),a=r(3107),c=r(5467),y=r(3022),w=r(6564),C=r(8447),T=r(909),S=r(4460),M=r(5684),O=r(5424);let L=(()=>{class ae{static \u0275fac=function(Oe){return new(Oe||ae)};static \u0275cmp=a.VBU({type:ae,selectors:[["ng-component"]],hostAttrs:["cdk-text-field-style-loader",""],decls:0,vars:0,template:function(Oe,xe){},styles:["textarea.cdk-textarea-autosize{resize:none}textarea.cdk-textarea-autosize-measuring{padding:2px 0 !important;box-sizing:content-box !important;height:auto !important;overflow:hidden !important}textarea.cdk-textarea-autosize-measuring-firefox{padding:2px 0 !important;box-sizing:content-box !important;height:0 !important}@keyframes cdk-text-field-autofill-start{/*!*/}@keyframes cdk-text-field-autofill-end{/*!*/}.cdk-text-field-autofill-monitored:-webkit-autofill{animation:cdk-text-field-autofill-start 0s 1ms}.cdk-text-field-autofill-monitored:not(:-webkit-autofill){animation:cdk-text-field-autofill-end 0s 1ms}"],encapsulation:2,changeDetection:0})}return ae})();const Z=(0,i.BQ)({passive:!0});let q=(()=>{class ae{_platform=(0,a.WQX)(i.OD);_ngZone=(0,a.WQX)(a.SKi);_styleLoader=(0,a.WQX)(c.l);_monitoredElements=new Map;constructor(){}monitor(be){if(!this._platform.isBrowser)return w.w;this._styleLoader.load(L);const Oe=(0,y.i8)(be),xe=this._monitoredElements.get(Oe);if(xe)return xe.subject;const De=new C.B,ce="cdk-text-field-autofilled",ue=Ce=>{"cdk-text-field-autofill-start"!==Ce.animationName||Oe.classList.contains(ce)?"cdk-text-field-autofill-end"===Ce.animationName&&Oe.classList.contains(ce)&&(Oe.classList.remove(ce),this._ngZone.run(()=>De.next({target:Ce.target,isAutofilled:!1}))):(Oe.classList.add(ce),this._ngZone.run(()=>De.next({target:Ce.target,isAutofilled:!0})))};return this._ngZone.runOutsideAngular(()=>{Oe.addEventListener("animationstart",ue,Z),Oe.classList.add("cdk-text-field-autofill-monitored")}),this._monitoredElements.set(Oe,{subject:De,unlisten:()=>{Oe.removeEventListener("animationstart",ue,Z)}}),De}stopMonitoring(be){const Oe=(0,y.i8)(be),xe=this._monitoredElements.get(Oe);xe&&(xe.unlisten(),xe.subject.complete(),Oe.classList.remove("cdk-text-field-autofill-monitored"),Oe.classList.remove("cdk-text-field-autofilled"),this._monitoredElements.delete(Oe))}ngOnDestroy(){this._monitoredElements.forEach((be,Oe)=>this.stopMonitoring(Oe))}static \u0275fac=function(Oe){return new(Oe||ae)};static \u0275prov=a.jDH({token:ae,factory:ae.\u0275fac,providedIn:"root"})}return ae})(),pe=(()=>{class ae{_elementRef=(0,a.WQX)(a.aKT);_platform=(0,a.WQX)(i.OD);_ngZone=(0,a.WQX)(a.SKi);_previousValue;_initialHeight;_destroyed=new C.B;_minRows;_maxRows;_enabled=!0;_previousMinRows=-1;_textareaElement;get minRows(){return this._minRows}set minRows(be){this._minRows=(0,y.OE)(be),this._setMinHeight()}get maxRows(){return this._maxRows}set maxRows(be){this._maxRows=(0,y.OE)(be),this._setMaxHeight()}get enabled(){return this._enabled}set enabled(be){this._enabled!==be&&((this._enabled=be)?this.resizeToFitContent(!0):this.reset())}get placeholder(){return this._textareaElement.placeholder}set placeholder(be){this._cachedPlaceholderHeight=void 0,be?this._textareaElement.setAttribute("placeholder",be):this._textareaElement.removeAttribute("placeholder"),this._cacheTextareaPlaceholderHeight()}_cachedLineHeight;_cachedPlaceholderHeight;_document=(0,a.WQX)(S.qQ,{optional:!0});_hasFocus;_isViewInited=!1;constructor(){(0,a.WQX)(c.l).load(L),this._textareaElement=this._elementRef.nativeElement}_setMinHeight(){const be=this.minRows&&this._cachedLineHeight?this.minRows*this._cachedLineHeight+"px":null;be&&(this._textareaElement.style.minHeight=be)}_setMaxHeight(){const be=this.maxRows&&this._cachedLineHeight?this.maxRows*this._cachedLineHeight+"px":null;be&&(this._textareaElement.style.maxHeight=be)}ngAfterViewInit(){this._platform.isBrowser&&(this._initialHeight=this._textareaElement.style.height,this.resizeToFitContent(),this._ngZone.runOutsideAngular(()=>{const be=this._getWindow();(0,T.R)(be,"resize").pipe((0,M.Z)(16),(0,O.Q)(this._destroyed)).subscribe(()=>this.resizeToFitContent(!0)),this._textareaElement.addEventListener("focus",this._handleFocusEvent),this._textareaElement.addEventListener("blur",this._handleFocusEvent)}),this._isViewInited=!0,this.resizeToFitContent(!0))}ngOnDestroy(){this._textareaElement.removeEventListener("focus",this._handleFocusEvent),this._textareaElement.removeEventListener("blur",this._handleFocusEvent),this._destroyed.next(),this._destroyed.complete()}_cacheTextareaLineHeight(){if(this._cachedLineHeight)return;let be=this._textareaElement.cloneNode(!1);be.rows=1,be.style.position="absolute",be.style.visibility="hidden",be.style.border="none",be.style.padding="0",be.style.height="",be.style.minHeight="",be.style.maxHeight="",be.style.overflow="hidden",this._textareaElement.parentNode.appendChild(be),this._cachedLineHeight=be.clientHeight,be.remove(),this._setMinHeight(),this._setMaxHeight()}_measureScrollHeight(){const be=this._textareaElement,Oe=be.style.marginBottom||"",xe=this._platform.FIREFOX,De=xe&&this._hasFocus,ce=xe?"cdk-textarea-autosize-measuring-firefox":"cdk-textarea-autosize-measuring";De&&(be.style.marginBottom=`${be.clientHeight}px`),be.classList.add(ce);const ue=be.scrollHeight-4;return be.classList.remove(ce),De&&(be.style.marginBottom=Oe),ue}_cacheTextareaPlaceholderHeight(){if(!this._isViewInited||null!=this._cachedPlaceholderHeight)return;if(!this.placeholder)return void(this._cachedPlaceholderHeight=0);const be=this._textareaElement.value;this._textareaElement.value=this._textareaElement.placeholder,this._cachedPlaceholderHeight=this._measureScrollHeight(),this._textareaElement.value=be}_handleFocusEvent=be=>{this._hasFocus="focus"===be.type};ngDoCheck(){this._platform.isBrowser&&this.resizeToFitContent()}resizeToFitContent(be=!1){if(!this._enabled||(this._cacheTextareaLineHeight(),this._cacheTextareaPlaceholderHeight(),!this._cachedLineHeight))return;const Oe=this._elementRef.nativeElement,xe=Oe.value;if(!be&&this._minRows===this._previousMinRows&&xe===this._previousValue)return;const De=this._measureScrollHeight(),ce=Math.max(De,this._cachedPlaceholderHeight||0);Oe.style.height=`${ce}px`,this._ngZone.runOutsideAngular(()=>{typeof requestAnimationFrame<"u"?requestAnimationFrame(()=>this._scrollToCaretPosition(Oe)):setTimeout(()=>this._scrollToCaretPosition(Oe))}),this._previousValue=xe,this._previousMinRows=this._minRows}reset(){void 0!==this._initialHeight&&(this._textareaElement.style.height=this._initialHeight)}_noopInputHandler(){}_getDocument(){return this._document||document}_getWindow(){return this._getDocument().defaultView||window}_scrollToCaretPosition(be){const{selectionStart:Oe,selectionEnd:xe}=be;!this._destroyed.isStopped&&this._hasFocus&&be.setSelectionRange(Oe,xe)}static \u0275fac=function(Oe){return new(Oe||ae)};static \u0275dir=a.FsC({type:ae,selectors:[["textarea","cdkTextareaAutosize",""]],hostAttrs:["rows","1",1,"cdk-textarea-autosize"],hostBindings:function(Oe,xe){1&Oe&&a.bIt("input",function(){return xe._noopInputHandler()})},inputs:{minRows:[0,"cdkAutosizeMinRows","minRows"],maxRows:[0,"cdkAutosizeMaxRows","maxRows"],enabled:[2,"cdkTextareaAutosize","enabled",a.L39],placeholder:"placeholder"},exportAs:["cdkTextareaAutosize"],features:[a.GFd]})}return ae})(),se=(()=>{class ae{static \u0275fac=function(Oe){return new(Oe||ae)};static \u0275mod=a.$C({type:ae});static \u0275inj=a.G2t({})}return ae})()},4460:(o,s,r)=>{"use strict";r.d(s,{AJ:()=>lr,B3:()=>xr,Jj:()=>es,MD:()=>Ao,N0:()=>Ss,PV:()=>Li,QT:()=>y,Sm:()=>ae,Sq:()=>ve,T3:()=>gi,UE:()=>Gs,VF:()=>C,Vy:()=>_s,Xr:()=>ls,YU:()=>Io,ZD:()=>w,_b:()=>ao,aZ:()=>be,bT:()=>gt,fw:()=>me,hb:()=>pe,hj:()=>O,jo:()=>hs,qQ:()=>S,vh:()=>Cs});var i=r(3107),a=r(8447);let c=null;function y(){return c}function w(U){c??=U}class C{}const S=new i.nKC("");let M=(()=>{class U{historyGo(ne){throw new Error("")}static \u0275fac=function(ye){return new(ye||U)};static \u0275prov=i.jDH({token:U,factory:()=>(0,i.WQX)(L),providedIn:"platform"})}return U})();const O=new i.nKC("");let L=(()=>{class U extends M{_location;_history;_doc=(0,i.WQX)(S);constructor(){super(),this._location=window.location,this._history=window.history}getBaseHrefFromDOM(){return y().getBaseHref(this._doc)}onPopState(ne){const ye=y().getGlobalEventTarget(this._doc,"window");return ye.addEventListener("popstate",ne,!1),()=>ye.removeEventListener("popstate",ne)}onHashChange(ne){const ye=y().getGlobalEventTarget(this._doc,"window");return ye.addEventListener("hashchange",ne,!1),()=>ye.removeEventListener("hashchange",ne)}get href(){return this._location.href}get protocol(){return this._location.protocol}get hostname(){return this._location.hostname}get port(){return this._location.port}get pathname(){return this._location.pathname}get search(){return this._location.search}get hash(){return this._location.hash}set pathname(ne){this._location.pathname=ne}pushState(ne,ye,Et){this._history.pushState(ne,ye,Et)}replaceState(ne,ye,Et){this._history.replaceState(ne,ye,Et)}forward(){this._history.forward()}back(){this._history.back()}historyGo(ne=0){this._history.go(ne)}getState(){return this._history.state}static \u0275fac=function(ye){return new(ye||U)};static \u0275prov=i.jDH({token:U,factory:()=>new U,providedIn:"platform"})}return U})();function Z(U,Ie){if(0==U.length)return Ie;if(0==Ie.length)return U;let ne=0;return U.endsWith("/")&&ne++,Ie.startsWith("/")&&ne++,2==ne?U+Ie.substring(1):1==ne?U+Ie:U+"/"+Ie}function q(U){const Ie=U.match(/#|\?|$/),ne=Ie&&Ie.index||U.length;return U.slice(0,ne-("/"===U[ne-1]?1:0))+U.slice(ne)}function re(U){return U&&"?"!==U[0]?"?"+U:U}let pe=(()=>{class U{historyGo(ne){throw new Error("")}static \u0275fac=function(ye){return new(ye||U)};static \u0275prov=i.jDH({token:U,factory:()=>(0,i.WQX)(ae),providedIn:"root"})}return U})();const se=new i.nKC("");let ae=(()=>{class U extends pe{_platformLocation;_baseHref;_removeListenerFns=[];constructor(ne,ye){super(),this._platformLocation=ne,this._baseHref=ye??this._platformLocation.getBaseHrefFromDOM()??(0,i.WQX)(S).location?.origin??""}ngOnDestroy(){for(;this._removeListenerFns.length;)this._removeListenerFns.pop()()}onPopState(ne){this._removeListenerFns.push(this._platformLocation.onPopState(ne),this._platformLocation.onHashChange(ne))}getBaseHref(){return this._baseHref}prepareExternalUrl(ne){return Z(this._baseHref,ne)}path(ne=!1){const ye=this._platformLocation.pathname+re(this._platformLocation.search),Et=this._platformLocation.hash;return Et&&ne?`${ye}${Et}`:ye}pushState(ne,ye,Et,Gt){const Un=this.prepareExternalUrl(Et+re(Gt));this._platformLocation.pushState(ne,ye,Un)}replaceState(ne,ye,Et,Gt){const Un=this.prepareExternalUrl(Et+re(Gt));this._platformLocation.replaceState(ne,ye,Un)}forward(){this._platformLocation.forward()}back(){this._platformLocation.back()}getState(){return this._platformLocation.getState()}historyGo(ne=0){this._platformLocation.historyGo?.(ne)}static \u0275fac=function(ye){return new(ye||U)(i.KVO(M),i.KVO(se,8))};static \u0275prov=i.jDH({token:U,factory:U.\u0275fac,providedIn:"root"})}return U})(),me=(()=>{class U extends pe{_platformLocation;_baseHref="";_removeListenerFns=[];constructor(ne,ye){super(),this._platformLocation=ne,null!=ye&&(this._baseHref=ye)}ngOnDestroy(){for(;this._removeListenerFns.length;)this._removeListenerFns.pop()()}onPopState(ne){this._removeListenerFns.push(this._platformLocation.onPopState(ne),this._platformLocation.onHashChange(ne))}getBaseHref(){return this._baseHref}path(ne=!1){const ye=this._platformLocation.hash??"#";return ye.length>0?ye.substring(1):ye}prepareExternalUrl(ne){const ye=Z(this._baseHref,ne);return ye.length>0?"#"+ye:ye}pushState(ne,ye,Et,Gt){let Un=this.prepareExternalUrl(Et+re(Gt));0==Un.length&&(Un=this._platformLocation.pathname),this._platformLocation.pushState(ne,ye,Un)}replaceState(ne,ye,Et,Gt){let Un=this.prepareExternalUrl(Et+re(Gt));0==Un.length&&(Un=this._platformLocation.pathname),this._platformLocation.replaceState(ne,ye,Un)}forward(){this._platformLocation.forward()}back(){this._platformLocation.back()}getState(){return this._platformLocation.getState()}historyGo(ne=0){this._platformLocation.historyGo?.(ne)}static \u0275fac=function(ye){return new(ye||U)(i.KVO(M),i.KVO(se,8))};static \u0275prov=i.jDH({token:U,factory:U.\u0275fac})}return U})(),be=(()=>{class U{_subject=new a.B;_basePath;_locationStrategy;_urlChangeListeners=[];_urlChangeSubscription=null;constructor(ne){this._locationStrategy=ne;const ye=this._locationStrategy.getBaseHref();this._basePath=function ce(U){if(new RegExp("^(https?:)?//").test(U)){const[,ne]=U.split(/\/\/[^\/]+/);return ne}return U}(q(De(ye))),this._locationStrategy.onPopState(Et=>{this._subject.next({url:this.path(!0),pop:!0,state:Et.state,type:Et.type})})}ngOnDestroy(){this._urlChangeSubscription?.unsubscribe(),this._urlChangeListeners=[]}path(ne=!1){return this.normalize(this._locationStrategy.path(ne))}getState(){return this._locationStrategy.getState()}isCurrentPathEqualTo(ne,ye=""){return this.path()==this.normalize(ne+re(ye))}normalize(ne){return U.stripTrailingSlash(function xe(U,Ie){if(!U||!Ie.startsWith(U))return Ie;const ne=Ie.substring(U.length);return""===ne||["/",";","?","#"].includes(ne[0])?ne:Ie}(this._basePath,De(ne)))}prepareExternalUrl(ne){return ne&&"/"!==ne[0]&&(ne="/"+ne),this._locationStrategy.prepareExternalUrl(ne)}go(ne,ye="",Et=null){this._locationStrategy.pushState(Et,"",ne,ye),this._notifyUrlChangeListeners(this.prepareExternalUrl(ne+re(ye)),Et)}replaceState(ne,ye="",Et=null){this._locationStrategy.replaceState(Et,"",ne,ye),this._notifyUrlChangeListeners(this.prepareExternalUrl(ne+re(ye)),Et)}forward(){this._locationStrategy.forward()}back(){this._locationStrategy.back()}historyGo(ne=0){this._locationStrategy.historyGo?.(ne)}onUrlChange(ne){return this._urlChangeListeners.push(ne),this._urlChangeSubscription??=this.subscribe(ye=>{this._notifyUrlChangeListeners(ye.url,ye.state)}),()=>{const ye=this._urlChangeListeners.indexOf(ne);this._urlChangeListeners.splice(ye,1),0===this._urlChangeListeners.length&&(this._urlChangeSubscription?.unsubscribe(),this._urlChangeSubscription=null)}}_notifyUrlChangeListeners(ne="",ye){this._urlChangeListeners.forEach(Et=>Et(ne,ye))}subscribe(ne,ye,Et){return this._subject.subscribe({next:ne,error:ye??void 0,complete:Et??void 0})}static normalizeQueryParams=re;static joinWithSlash=Z;static stripTrailingSlash=q;static \u0275fac=function(ye){return new(ye||U)(i.KVO(pe))};static \u0275prov=i.jDH({token:U,factory:()=>function Oe(){return new be((0,i.KVO)(pe))}(),providedIn:"root"})}return U})();function De(U){return U.replace(/\/index.html$/,"")}var Be=function(U){return U[U.Zero=0]="Zero",U[U.One=1]="One",U[U.Two=2]="Two",U[U.Few=3]="Few",U[U.Many=4]="Many",U[U.Other=5]="Other",U}(Be||{}),at=function(U){return U[U.Format=0]="Format",U[U.Standalone=1]="Standalone",U}(at||{}),dt=function(U){return U[U.Narrow=0]="Narrow",U[U.Abbreviated=1]="Abbreviated",U[U.Wide=2]="Wide",U[U.Short=3]="Short",U}(dt||{}),bt=function(U){return U[U.Short=0]="Short",U[U.Medium=1]="Medium",U[U.Long=2]="Long",U[U.Full=3]="Full",U}(bt||{});const lt={Decimal:0,Group:1,List:2,PercentSign:3,PlusSign:4,MinusSign:5,Exponential:6,SuperscriptingExponent:7,PerMille:8,Infinity:9,NaN:10,TimeSeparator:11,CurrencyDecimal:12,CurrencyGroup:13};function $e(U,Ie){return Vt((0,i.H5H)(U)[i.KH2.DateFormat],Ie)}function Ft(U,Ie){return Vt((0,i.H5H)(U)[i.KH2.TimeFormat],Ie)}function Ke(U,Ie){return Vt((0,i.H5H)(U)[i.KH2.DateTimeFormat],Ie)}function Ze(U,Ie){const ne=(0,i.H5H)(U),ye=ne[i.KH2.NumberSymbols][Ie];if(typeof ye>"u"){if(Ie===lt.CurrencyDecimal)return ne[i.KH2.NumberSymbols][lt.Decimal];if(Ie===lt.CurrencyGroup)return ne[i.KH2.NumberSymbols][lt.Group]}return ye}const st=i.mq5;function Xt(U){if(!U[i.KH2.ExtraData])throw new Error(`Missing extra locale data for the locale "${U[i.KH2.LocaleId]}". Use "registerLocaleData" to load new data. See the "I18n guide" on angular.io to know more.`)}function Vt(U,Ie){for(let ne=Ie;ne>-1;ne--)if(typeof U[ne]<"u")return U[ne];throw new Error("Locale data API: locale data undefined")}function en(U){const[Ie,ne]=U.split(":");return{hours:+Ie,minutes:+ne}}const Rn=/^(\d{4,})-?(\d\d)-?(\d\d)(?:T(\d\d)(?::?(\d\d)(?::?(\d\d)(?:\.(\d+))?)?)?(Z|([+-])(\d\d):?(\d\d))?)?$/,pr={},cn=/((?:[^BEGHLMOSWYZabcdhmswyz']+)|(?:'(?:[^']|'')*')|(?:G{1,5}|y{1,4}|Y{1,4}|M{1,5}|L{1,5}|w{1,2}|W{1}|d{1,2}|E{1,6}|c{1,6}|a{1,5}|b{1,5}|B{1,5}|h{1,2}|H{1,2}|m{1,2}|s{1,2}|S{1,3}|z{1,4}|Z{1,5}|O{1,4}))([\s\S]*)/;var Fe=function(U){return U[U.Short=0]="Short",U[U.ShortGMT=1]="ShortGMT",U[U.Long=2]="Long",U[U.Extended=3]="Extended",U}(Fe||{}),ke=function(U){return U[U.FullYear=0]="FullYear",U[U.Month=1]="Month",U[U.Date=2]="Date",U[U.Hours=3]="Hours",U[U.Minutes=4]="Minutes",U[U.Seconds=5]="Seconds",U[U.FractionalSeconds=6]="FractionalSeconds",U[U.Day=7]="Day",U}(ke||{}),Je=function(U){return U[U.DayPeriods=0]="DayPeriods",U[U.Days=1]="Days",U[U.Months=2]="Months",U[U.Eras=3]="Eras",U}(Je||{});function z(U,Ie,ne,ye){let Et=function ct(U){if(wn(U))return U;if("number"==typeof U&&!isNaN(U))return new Date(U);if("string"==typeof U){if(U=U.trim(),/^(\d{4}(-\d{1,2}(-\d{1,2})?)?)$/.test(U)){const[Et,Gt=1,Un=1]=U.split("-").map(tr=>+tr);return N(Et,Gt-1,Un)}const ne=parseFloat(U);if(!isNaN(U-ne))return new Date(ne);let ye;if(ye=U.match(Rn))return function Bt(U){const Ie=new Date(0);let ne=0,ye=0;const Et=U[8]?Ie.setUTCFullYear:Ie.setFullYear,Gt=U[8]?Ie.setUTCHours:Ie.setHours;U[9]&&(ne=Number(U[9]+U[10]),ye=Number(U[9]+U[11])),Et.call(Ie,Number(U[1]),Number(U[2])-1,Number(U[3]));const Un=Number(U[4]||0)-ne,tr=Number(U[5]||0)-ye,ci=Number(U[6]||0),ki=Math.floor(1e3*parseFloat("0."+(U[7]||0)));return Gt.call(Ie,Un,tr,ci,ki),Ie}(ye)}const Ie=new Date(U);if(!wn(Ie))throw new Error(`Unable to convert "${U}" into a date`);return Ie}(U);Ie=W(ne,Ie)||Ie;let tr,Un=[];for(;Ie;){if(tr=cn.exec(Ie),!tr){Un.push(Ie);break}{Un=Un.concat(tr.slice(1));const Di=Un.pop();if(!Di)break;Ie=Di}}let ci=Et.getTimezoneOffset();ye&&(ci=Ge(ye,ci),Et=function Dt(U,Ie,ne){const ye=ne?-1:1,Et=U.getTimezoneOffset();return function Ve(U,Ie){return(U=new Date(U.getTime())).setMinutes(U.getMinutes()+Ie),U}(U,ye*(Ge(Ie,Et)-Et))}(Et,ye,!0));let ki="";return Un.forEach(Di=>{const Rr=function Re(U){if(Wt[U])return Wt[U];let Ie;switch(U){case"G":case"GG":case"GGG":Ie=an(Je.Eras,dt.Abbreviated);break;case"GGGG":Ie=an(Je.Eras,dt.Wide);break;case"GGGGG":Ie=an(Je.Eras,dt.Narrow);break;case"y":Ie=St(ke.FullYear,1,0,!1,!0);break;case"yy":Ie=St(ke.FullYear,2,0,!0,!0);break;case"yyy":Ie=St(ke.FullYear,3,0,!1,!0);break;case"yyyy":Ie=St(ke.FullYear,4,0,!1,!0);break;case"Y":Ie=vt(1);break;case"YY":Ie=vt(2,!0);break;case"YYY":Ie=vt(3);break;case"YYYY":Ie=vt(4);break;case"M":case"L":Ie=St(ke.Month,1,1);break;case"MM":case"LL":Ie=St(ke.Month,2,1);break;case"MMM":Ie=an(Je.Months,dt.Abbreviated);break;case"MMMM":Ie=an(Je.Months,dt.Wide);break;case"MMMMM":Ie=an(Je.Months,dt.Narrow);break;case"LLL":Ie=an(Je.Months,dt.Abbreviated,at.Standalone);break;case"LLLL":Ie=an(Je.Months,dt.Wide,at.Standalone);break;case"LLLLL":Ie=an(Je.Months,dt.Narrow,at.Standalone);break;case"w":Ie=Vr(1);break;case"ww":Ie=Vr(2);break;case"W":Ie=Vr(1,!0);break;case"d":Ie=St(ke.Date,1);break;case"dd":Ie=St(ke.Date,2);break;case"c":case"cc":Ie=St(ke.Day,1);break;case"ccc":Ie=an(Je.Days,dt.Abbreviated,at.Standalone);break;case"cccc":Ie=an(Je.Days,dt.Wide,at.Standalone);break;case"ccccc":Ie=an(Je.Days,dt.Narrow,at.Standalone);break;case"cccccc":Ie=an(Je.Days,dt.Short,at.Standalone);break;case"E":case"EE":case"EEE":Ie=an(Je.Days,dt.Abbreviated);break;case"EEEE":Ie=an(Je.Days,dt.Wide);break;case"EEEEE":Ie=an(Je.Days,dt.Narrow);break;case"EEEEEE":Ie=an(Je.Days,dt.Short);break;case"a":case"aa":case"aaa":Ie=an(Je.DayPeriods,dt.Abbreviated);break;case"aaaa":Ie=an(Je.DayPeriods,dt.Wide);break;case"aaaaa":Ie=an(Je.DayPeriods,dt.Narrow);break;case"b":case"bb":case"bbb":Ie=an(Je.DayPeriods,dt.Abbreviated,at.Standalone,!0);break;case"bbbb":Ie=an(Je.DayPeriods,dt.Wide,at.Standalone,!0);break;case"bbbbb":Ie=an(Je.DayPeriods,dt.Narrow,at.Standalone,!0);break;case"B":case"BB":case"BBB":Ie=an(Je.DayPeriods,dt.Abbreviated,at.Format,!0);break;case"BBBB":Ie=an(Je.DayPeriods,dt.Wide,at.Format,!0);break;case"BBBBB":Ie=an(Je.DayPeriods,dt.Narrow,at.Format,!0);break;case"h":Ie=St(ke.Hours,1,-12);break;case"hh":Ie=St(ke.Hours,2,-12);break;case"H":Ie=St(ke.Hours,1);break;case"HH":Ie=St(ke.Hours,2);break;case"m":Ie=St(ke.Minutes,1);break;case"mm":Ie=St(ke.Minutes,2);break;case"s":Ie=St(ke.Seconds,1);break;case"ss":Ie=St(ke.Seconds,2);break;case"S":Ie=St(ke.FractionalSeconds,1);break;case"SS":Ie=St(ke.FractionalSeconds,2);break;case"SSS":Ie=St(ke.FractionalSeconds,3);break;case"Z":case"ZZ":case"ZZZ":Ie=In(Fe.Short);break;case"ZZZZZ":Ie=In(Fe.Extended);break;case"O":case"OO":case"OOO":case"z":case"zz":case"zzz":Ie=In(Fe.ShortGMT);break;case"OOOO":case"ZZZZ":case"zzzz":Ie=In(Fe.Long);break;default:return null}return Wt[U]=Ie,Ie}(Di);ki+=Rr?Rr(Et,ne,ci):"''"===Di?"'":Di.replace(/(^'|'$)/g,"").replace(/''/g,"'")}),ki}function N(U,Ie,ne){const ye=new Date(0);return ye.setFullYear(U,Ie,ne),ye.setHours(0,0,0),ye}function W(U,Ie){const ne=function gn(U){return(0,i.H5H)(U)[i.KH2.LocaleId]}(U);if(pr[ne]??={},pr[ne][Ie])return pr[ne][Ie];let ye="";switch(Ie){case"shortDate":ye=$e(U,bt.Short);break;case"mediumDate":ye=$e(U,bt.Medium);break;case"longDate":ye=$e(U,bt.Long);break;case"fullDate":ye=$e(U,bt.Full);break;case"shortTime":ye=Ft(U,bt.Short);break;case"mediumTime":ye=Ft(U,bt.Medium);break;case"longTime":ye=Ft(U,bt.Long);break;case"fullTime":ye=Ft(U,bt.Full);break;case"short":const Et=W(U,"shortTime"),Gt=W(U,"shortDate");ye=Le(Ke(U,bt.Short),[Et,Gt]);break;case"medium":const Un=W(U,"mediumTime"),tr=W(U,"mediumDate");ye=Le(Ke(U,bt.Medium),[Un,tr]);break;case"long":const ci=W(U,"longTime"),ki=W(U,"longDate");ye=Le(Ke(U,bt.Long),[ci,ki]);break;case"full":const Di=W(U,"fullTime"),Rr=W(U,"fullDate");ye=Le(Ke(U,bt.Full),[Di,Rr])}return ye&&(pr[ne][Ie]=ye),ye}function Le(U,Ie){return Ie&&(U=U.replace(/\{([^}]+)}/g,function(ne,ye){return null!=Ie&&ye in Ie?Ie[ye]:ne})),U}function ft(U,Ie,ne="-",ye,Et){let Gt="";(U<0||Et&&U<=0)&&(Et?U=1-U:(U=-U,Gt=ne));let Un=String(U);for(;Un.length0||tr>-ne)&&(tr+=ne),U===ke.Hours)0===tr&&-12===ne&&(tr=12);else if(U===ke.FractionalSeconds)return function mt(U,Ie){return ft(U,3).substring(0,Ie)}(tr,Ie);const ci=Ze(Un,lt.MinusSign);return ft(tr,Ie,ci,ye,Et)}}function an(U,Ie,ne=at.Format,ye=!1){return function(Et,Gt){return function dn(U,Ie,ne,ye,Et,Gt){switch(ne){case Je.Months:return function yn(U,Ie,ne){const ye=(0,i.H5H)(U),Gt=Vt([ye[i.KH2.MonthsFormat],ye[i.KH2.MonthsStandalone]],Ie);return Vt(Gt,ne)}(Ie,Et,ye)[U.getMonth()];case Je.Days:return function Vn(U,Ie,ne){const ye=(0,i.H5H)(U),Gt=Vt([ye[i.KH2.DaysFormat],ye[i.KH2.DaysStandalone]],Ie);return Vt(Gt,ne)}(Ie,Et,ye)[U.getDay()];case Je.DayPeriods:const Un=U.getHours(),tr=U.getMinutes();if(Gt){const ki=function Mt(U){const Ie=(0,i.H5H)(U);return Xt(Ie),(Ie[i.KH2.ExtraData][2]||[]).map(ye=>"string"==typeof ye?en(ye):[en(ye[0]),en(ye[1])])}(Ie),Di=function Kt(U,Ie,ne){const ye=(0,i.H5H)(U);Xt(ye);const Gt=Vt([ye[i.KH2.ExtraData][0],ye[i.KH2.ExtraData][1]],Ie)||[];return Vt(Gt,ne)||[]}(Ie,Et,ye),Rr=ki.findIndex(li=>{if(Array.isArray(li)){const[ii,wi]=li,bs=Un>=ii.hours&&tr>=ii.minutes,Lo=Un0?Math.floor(Et/60):Math.ceil(Et/60);switch(U){case Fe.Short:return(Et>=0?"+":"")+ft(Un,2,Gt)+ft(Math.abs(Et%60),2,Gt);case Fe.ShortGMT:return"GMT"+(Et>=0?"+":"")+ft(Un,1,Gt);case Fe.Long:return"GMT"+(Et>=0?"+":"")+ft(Un,2,Gt)+":"+ft(Math.abs(Et%60),2,Gt);case Fe.Extended:return 0===ye?"Z":(Et>=0?"+":"")+ft(Un,2,Gt)+":"+ft(Math.abs(Et%60),2,Gt);default:throw new Error(`Unknown zone width "${U}"`)}}}const sr=0,xn=4;function Tr(U){const Ie=U.getDay(),ne=0===Ie?-3:xn-Ie;return N(U.getFullYear(),U.getMonth(),U.getDate()+ne)}function Vr(U,Ie=!1){return function(ne,ye){let Et;if(Ie){const Gt=new Date(ne.getFullYear(),ne.getMonth(),1).getDay()-1,Un=ne.getDate();Et=1+Math.floor((Un+Gt)/7)}else{const Gt=Tr(ne),Un=function Hr(U){const Ie=N(U,sr,1).getDay();return N(U,0,1+(Ie<=xn?xn:xn+7)-Ie)}(Gt.getFullYear()),tr=Gt.getTime()-Un.getTime();Et=1+Math.round(tr/6048e5)}return ft(Et,U,Ze(ye,lt.MinusSign))}}function vt(U,Ie=!1){return function(ne,ye){return ft(Tr(ne).getFullYear(),U,Ze(ye,lt.MinusSign),Ie)}}const Wt={};function Ge(U,Ie){U=U.replace(/:/g,"");const ne=Date.parse("Jan 01, 1970 00:00:00 "+U)/6e4;return isNaN(ne)?Ie:ne}function wn(U){return U instanceof Date&&!isNaN(U.valueOf())}let fo=(()=>{class U{static \u0275fac=function(ye){return new(ye||U)};static \u0275prov=i.jDH({token:U,factory:function(ye){let Et=null;return ye?Et=new ye:(Gt=i.KVO(i.xe9),Et=new Fo(Gt)),Et;var Gt},providedIn:"root"})}return U})();let Fo=(()=>{class U extends fo{locale;constructor(ne){super(),this.locale=ne}getPluralCategory(ne,ye){switch(st(ye||this.locale)(ne)){case Be.Zero:return"zero";case Be.One:return"one";case Be.Two:return"two";case Be.Few:return"few";case Be.Many:return"many";default:return"other"}}static \u0275fac=function(ye){return new(ye||U)(i.KVO(i.xe9))};static \u0275prov=i.jDH({token:U,factory:U.\u0275fac})}return U})();function ao(U,Ie){Ie=encodeURIComponent(Ie);for(const ne of U.split(";")){const ye=ne.indexOf("="),[Et,Gt]=-1==ye?[ne,""]:[ne.slice(0,ye),ne.slice(ye+1)];if(Et.trim()===Ie)return decodeURIComponent(Gt)}return null}const po=/\s+/,Ii=[];let Io=(()=>{class U{_ngEl;_renderer;initialClasses=Ii;rawClass;stateMap=new Map;constructor(ne,ye){this._ngEl=ne,this._renderer=ye}set klass(ne){this.initialClasses=null!=ne?ne.trim().split(po):Ii}set ngClass(ne){this.rawClass="string"==typeof ne?ne.trim().split(po):ne}ngDoCheck(){for(const ye of this.initialClasses)this._updateState(ye,!0);const ne=this.rawClass;if(Array.isArray(ne)||ne instanceof Set)for(const ye of ne)this._updateState(ye,!0);else if(null!=ne)for(const ye of Object.keys(ne))this._updateState(ye,!!ne[ye]);this._applyStateDiff()}_updateState(ne,ye){const Et=this.stateMap.get(ne);void 0!==Et?(Et.enabled!==ye&&(Et.changed=!0,Et.enabled=ye),Et.touched=!0):this.stateMap.set(ne,{enabled:ye,changed:!0,touched:!0})}_applyStateDiff(){for(const ne of this.stateMap){const ye=ne[0],Et=ne[1];Et.changed?(this._toggleClass(ye,Et.enabled),Et.changed=!1):Et.touched||(Et.enabled&&this._toggleClass(ye,!1),this.stateMap.delete(ye)),Et.touched=!1}}_toggleClass(ne,ye){(ne=ne.trim()).length>0&&ne.split(po).forEach(Et=>{ye?this._renderer.addClass(this._ngEl.nativeElement,Et):this._renderer.removeClass(this._ngEl.nativeElement,Et)})}static \u0275fac=function(ye){return new(ye||U)(i.rXU(i.aKT),i.rXU(i.sFG))};static \u0275dir=i.FsC({type:U,selectors:[["","ngClass",""]],inputs:{klass:[0,"class","klass"],ngClass:"ngClass"}})}return U})();class ht{$implicit;ngForOf;index;count;constructor(Ie,ne,ye,Et){this.$implicit=Ie,this.ngForOf=ne,this.index=ye,this.count=Et}get first(){return 0===this.index}get last(){return this.index===this.count-1}get even(){return this.index%2==0}get odd(){return!this.even}}let ve=(()=>{class U{_viewContainer;_template;_differs;set ngForOf(ne){this._ngForOf=ne,this._ngForOfDirty=!0}set ngForTrackBy(ne){this._trackByFn=ne}get ngForTrackBy(){return this._trackByFn}_ngForOf=null;_ngForOfDirty=!0;_differ=null;_trackByFn;constructor(ne,ye,Et){this._viewContainer=ne,this._template=ye,this._differs=Et}set ngForTemplate(ne){ne&&(this._template=ne)}ngDoCheck(){if(this._ngForOfDirty){this._ngForOfDirty=!1;const ne=this._ngForOf;!this._differ&&ne&&(this._differ=this._differs.find(ne).create(this.ngForTrackBy))}if(this._differ){const ne=this._differ.diff(this._ngForOf);ne&&this._applyChanges(ne)}}_applyChanges(ne){const ye=this._viewContainer;ne.forEachOperation((Et,Gt,Un)=>{if(null==Et.previousIndex)ye.createEmbeddedView(this._template,new ht(Et.item,this._ngForOf,-1,-1),null===Un?void 0:Un);else if(null==Un)ye.remove(null===Gt?void 0:Gt);else if(null!==Gt){const tr=ye.get(Gt);ye.move(tr,Un),Ye(tr,Et)}});for(let Et=0,Gt=ye.length;Et{Ye(ye.get(Et.currentIndex),Et)})}static ngTemplateContextGuard(ne,ye){return!0}static \u0275fac=function(ye){return new(ye||U)(i.rXU(i.c1b),i.rXU(i.C4Q),i.rXU(i._q3))};static \u0275dir=i.FsC({type:U,selectors:[["","ngFor","","ngForOf",""]],inputs:{ngForOf:"ngForOf",ngForTrackBy:"ngForTrackBy",ngForTemplate:"ngForTemplate"}})}return U})();function Ye(U,Ie){U.context.$implicit=Ie.item}let gt=(()=>{class U{_viewContainer;_context=new Ht;_thenTemplateRef=null;_elseTemplateRef=null;_thenViewRef=null;_elseViewRef=null;constructor(ne,ye){this._viewContainer=ne,this._thenTemplateRef=ye}set ngIf(ne){this._context.$implicit=this._context.ngIf=ne,this._updateView()}set ngIfThen(ne){kt("ngIfThen",ne),this._thenTemplateRef=ne,this._thenViewRef=null,this._updateView()}set ngIfElse(ne){kt("ngIfElse",ne),this._elseTemplateRef=ne,this._elseViewRef=null,this._updateView()}_updateView(){this._context.$implicit?this._thenViewRef||(this._viewContainer.clear(),this._elseViewRef=null,this._thenTemplateRef&&(this._thenViewRef=this._viewContainer.createEmbeddedView(this._thenTemplateRef,this._context))):this._elseViewRef||(this._viewContainer.clear(),this._thenViewRef=null,this._elseTemplateRef&&(this._elseViewRef=this._viewContainer.createEmbeddedView(this._elseTemplateRef,this._context)))}static ngIfUseIfTypeGuard;static ngTemplateGuard_ngIf;static ngTemplateContextGuard(ne,ye){return!0}static \u0275fac=function(ye){return new(ye||U)(i.rXU(i.c1b),i.rXU(i.C4Q))};static \u0275dir=i.FsC({type:U,selectors:[["","ngIf",""]],inputs:{ngIf:"ngIf",ngIfThen:"ngIfThen",ngIfElse:"ngIfElse"}})}return U})();class Ht{$implicit=null;ngIf=null}function kt(U,Ie){if(Ie&&!Ie.createEmbeddedView)throw new Error(`${U} must be a TemplateRef, but received '${(0,i.Tbb)(Ie)}'.`)}let xr=(()=>{class U{_ngEl;_differs;_renderer;_ngStyle=null;_differ=null;constructor(ne,ye,Et){this._ngEl=ne,this._differs=ye,this._renderer=Et}set ngStyle(ne){this._ngStyle=ne,!this._differ&&ne&&(this._differ=this._differs.find(ne).create())}ngDoCheck(){if(this._differ){const ne=this._differ.diff(this._ngStyle);ne&&this._applyChanges(ne)}}_setStyle(ne,ye){const[Et,Gt]=ne.split("."),Un=-1===Et.indexOf("-")?void 0:i.czy.DashCase;null!=ye?this._renderer.setStyle(this._ngEl.nativeElement,Et,Gt?`${ye}${Gt}`:ye,Un):this._renderer.removeStyle(this._ngEl.nativeElement,Et,Un)}_applyChanges(ne){ne.forEachRemovedItem(ye=>this._setStyle(ye.key,null)),ne.forEachAddedItem(ye=>this._setStyle(ye.key,ye.currentValue)),ne.forEachChangedItem(ye=>this._setStyle(ye.key,ye.currentValue))}static \u0275fac=function(ye){return new(ye||U)(i.rXU(i.aKT),i.rXU(i.MKu),i.rXU(i.sFG))};static \u0275dir=i.FsC({type:U,selectors:[["","ngStyle",""]],inputs:{ngStyle:"ngStyle"}})}return U})(),gi=(()=>{class U{_viewContainerRef;_viewRef=null;ngTemplateOutletContext=null;ngTemplateOutlet=null;ngTemplateOutletInjector=null;constructor(ne){this._viewContainerRef=ne}ngOnChanges(ne){if(this._shouldRecreateView(ne)){const ye=this._viewContainerRef;if(this._viewRef&&ye.remove(ye.indexOf(this._viewRef)),!this.ngTemplateOutlet)return void(this._viewRef=null);const Et=this._createContextForwardProxy();this._viewRef=ye.createEmbeddedView(this.ngTemplateOutlet,Et,{injector:this.ngTemplateOutletInjector??void 0})}}_shouldRecreateView(ne){return!!ne.ngTemplateOutlet||!!ne.ngTemplateOutletInjector}_createContextForwardProxy(){return new Proxy({},{set:(ne,ye,Et)=>!!this.ngTemplateOutletContext&&Reflect.set(this.ngTemplateOutletContext,ye,Et),get:(ne,ye,Et)=>{if(this.ngTemplateOutletContext)return Reflect.get(this.ngTemplateOutletContext,ye,Et)}})}static \u0275fac=function(ye){return new(ye||U)(i.rXU(i.c1b))};static \u0275dir=i.FsC({type:U,selectors:[["","ngTemplateOutlet",""]],inputs:{ngTemplateOutletContext:"ngTemplateOutletContext",ngTemplateOutlet:"ngTemplateOutlet",ngTemplateOutletInjector:"ngTemplateOutletInjector"},features:[i.OA$]})}return U})();function Mi(U,Ie){return new i.wOt(2100,!1)}class Or{createSubscription(Ie,ne){return(0,i.O8t)(()=>Ie.subscribe({next:ne,error:ye=>{throw ye}}))}dispose(Ie){(0,i.O8t)(()=>Ie.unsubscribe())}}class Qr{createSubscription(Ie,ne){return Ie.then(ne,ye=>{throw ye})}dispose(Ie){}}const Pr=new Qr,Do=new Or;let es=(()=>{class U{_ref;_latestValue=null;markForCheckOnValueUpdate=!0;_subscription=null;_obj=null;_strategy=null;constructor(ne){this._ref=ne}ngOnDestroy(){this._subscription&&this._dispose(),this._ref=null}transform(ne){if(!this._obj){if(ne)try{this.markForCheckOnValueUpdate=!1,this._subscribe(ne)}finally{this.markForCheckOnValueUpdate=!0}return this._latestValue}return ne!==this._obj?(this._dispose(),this.transform(ne)):this._latestValue}_subscribe(ne){this._obj=ne,this._strategy=this._selectStrategy(ne),this._subscription=this._strategy.createSubscription(ne,ye=>this._updateLatestValue(ne,ye))}_selectStrategy(ne){if((0,i.jNT)(ne))return Pr;if((0,i.zjR)(ne))return Do;throw Mi()}_dispose(){this._strategy.dispose(this._subscription),this._latestValue=null,this._subscription=null,this._obj=null}_updateLatestValue(ne,ye){ne===this._obj&&(this._latestValue=ye,this.markForCheckOnValueUpdate&&this._ref?.markForCheck())}static \u0275fac=function(ye){return new(ye||U)(i.rXU(i.gRc,16))};static \u0275pipe=i.EJ8({name:"async",type:U,pure:!1})}return U})();const sa=/(?:[0-9A-Za-z\xAA\xB5\xBA\xC0-\xD6\xD8-\xF6\xF8-\u02C1\u02C6-\u02D1\u02E0-\u02E4\u02EC\u02EE\u0370-\u0374\u0376\u0377\u037A-\u037D\u037F\u0386\u0388-\u038A\u038C\u038E-\u03A1\u03A3-\u03F5\u03F7-\u0481\u048A-\u052F\u0531-\u0556\u0559\u0560-\u0588\u05D0-\u05EA\u05EF-\u05F2\u0620-\u064A\u066E\u066F\u0671-\u06D3\u06D5\u06E5\u06E6\u06EE\u06EF\u06FA-\u06FC\u06FF\u0710\u0712-\u072F\u074D-\u07A5\u07B1\u07CA-\u07EA\u07F4\u07F5\u07FA\u0800-\u0815\u081A\u0824\u0828\u0840-\u0858\u0860-\u086A\u0870-\u0887\u0889-\u088E\u08A0-\u08C9\u0904-\u0939\u093D\u0950\u0958-\u0961\u0971-\u0980\u0985-\u098C\u098F\u0990\u0993-\u09A8\u09AA-\u09B0\u09B2\u09B6-\u09B9\u09BD\u09CE\u09DC\u09DD\u09DF-\u09E1\u09F0\u09F1\u09FC\u0A05-\u0A0A\u0A0F\u0A10\u0A13-\u0A28\u0A2A-\u0A30\u0A32\u0A33\u0A35\u0A36\u0A38\u0A39\u0A59-\u0A5C\u0A5E\u0A72-\u0A74\u0A85-\u0A8D\u0A8F-\u0A91\u0A93-\u0AA8\u0AAA-\u0AB0\u0AB2\u0AB3\u0AB5-\u0AB9\u0ABD\u0AD0\u0AE0\u0AE1\u0AF9\u0B05-\u0B0C\u0B0F\u0B10\u0B13-\u0B28\u0B2A-\u0B30\u0B32\u0B33\u0B35-\u0B39\u0B3D\u0B5C\u0B5D\u0B5F-\u0B61\u0B71\u0B83\u0B85-\u0B8A\u0B8E-\u0B90\u0B92-\u0B95\u0B99\u0B9A\u0B9C\u0B9E\u0B9F\u0BA3\u0BA4\u0BA8-\u0BAA\u0BAE-\u0BB9\u0BD0\u0C05-\u0C0C\u0C0E-\u0C10\u0C12-\u0C28\u0C2A-\u0C39\u0C3D\u0C58-\u0C5A\u0C5D\u0C60\u0C61\u0C80\u0C85-\u0C8C\u0C8E-\u0C90\u0C92-\u0CA8\u0CAA-\u0CB3\u0CB5-\u0CB9\u0CBD\u0CDD\u0CDE\u0CE0\u0CE1\u0CF1\u0CF2\u0D04-\u0D0C\u0D0E-\u0D10\u0D12-\u0D3A\u0D3D\u0D4E\u0D54-\u0D56\u0D5F-\u0D61\u0D7A-\u0D7F\u0D85-\u0D96\u0D9A-\u0DB1\u0DB3-\u0DBB\u0DBD\u0DC0-\u0DC6\u0E01-\u0E30\u0E32\u0E33\u0E40-\u0E46\u0E81\u0E82\u0E84\u0E86-\u0E8A\u0E8C-\u0EA3\u0EA5\u0EA7-\u0EB0\u0EB2\u0EB3\u0EBD\u0EC0-\u0EC4\u0EC6\u0EDC-\u0EDF\u0F00\u0F40-\u0F47\u0F49-\u0F6C\u0F88-\u0F8C\u1000-\u102A\u103F\u1050-\u1055\u105A-\u105D\u1061\u1065\u1066\u106E-\u1070\u1075-\u1081\u108E\u10A0-\u10C5\u10C7\u10CD\u10D0-\u10FA\u10FC-\u1248\u124A-\u124D\u1250-\u1256\u1258\u125A-\u125D\u1260-\u1288\u128A-\u128D\u1290-\u12B0\u12B2-\u12B5\u12B8-\u12BE\u12C0\u12C2-\u12C5\u12C8-\u12D6\u12D8-\u1310\u1312-\u1315\u1318-\u135A\u1380-\u138F\u13A0-\u13F5\u13F8-\u13FD\u1401-\u166C\u166F-\u167F\u1681-\u169A\u16A0-\u16EA\u16F1-\u16F8\u1700-\u1711\u171F-\u1731\u1740-\u1751\u1760-\u176C\u176E-\u1770\u1780-\u17B3\u17D7\u17DC\u1820-\u1878\u1880-\u1884\u1887-\u18A8\u18AA\u18B0-\u18F5\u1900-\u191E\u1950-\u196D\u1970-\u1974\u1980-\u19AB\u19B0-\u19C9\u1A00-\u1A16\u1A20-\u1A54\u1AA7\u1B05-\u1B33\u1B45-\u1B4C\u1B83-\u1BA0\u1BAE\u1BAF\u1BBA-\u1BE5\u1C00-\u1C23\u1C4D-\u1C4F\u1C5A-\u1C7D\u1C80-\u1C88\u1C90-\u1CBA\u1CBD-\u1CBF\u1CE9-\u1CEC\u1CEE-\u1CF3\u1CF5\u1CF6\u1CFA\u1D00-\u1DBF\u1E00-\u1F15\u1F18-\u1F1D\u1F20-\u1F45\u1F48-\u1F4D\u1F50-\u1F57\u1F59\u1F5B\u1F5D\u1F5F-\u1F7D\u1F80-\u1FB4\u1FB6-\u1FBC\u1FBE\u1FC2-\u1FC4\u1FC6-\u1FCC\u1FD0-\u1FD3\u1FD6-\u1FDB\u1FE0-\u1FEC\u1FF2-\u1FF4\u1FF6-\u1FFC\u2071\u207F\u2090-\u209C\u2102\u2107\u210A-\u2113\u2115\u2119-\u211D\u2124\u2126\u2128\u212A-\u212D\u212F-\u2139\u213C-\u213F\u2145-\u2149\u214E\u2183\u2184\u2C00-\u2CE4\u2CEB-\u2CEE\u2CF2\u2CF3\u2D00-\u2D25\u2D27\u2D2D\u2D30-\u2D67\u2D6F\u2D80-\u2D96\u2DA0-\u2DA6\u2DA8-\u2DAE\u2DB0-\u2DB6\u2DB8-\u2DBE\u2DC0-\u2DC6\u2DC8-\u2DCE\u2DD0-\u2DD6\u2DD8-\u2DDE\u2E2F\u3005\u3006\u3031-\u3035\u303B\u303C\u3041-\u3096\u309D-\u309F\u30A1-\u30FA\u30FC-\u30FF\u3105-\u312F\u3131-\u318E\u31A0-\u31BF\u31F0-\u31FF\u3400-\u4DBF\u4E00-\uA48C\uA4D0-\uA4FD\uA500-\uA60C\uA610-\uA61F\uA62A\uA62B\uA640-\uA66E\uA67F-\uA69D\uA6A0-\uA6E5\uA717-\uA71F\uA722-\uA788\uA78B-\uA7CA\uA7D0\uA7D1\uA7D3\uA7D5-\uA7D9\uA7F2-\uA801\uA803-\uA805\uA807-\uA80A\uA80C-\uA822\uA840-\uA873\uA882-\uA8B3\uA8F2-\uA8F7\uA8FB\uA8FD\uA8FE\uA90A-\uA925\uA930-\uA946\uA960-\uA97C\uA984-\uA9B2\uA9CF\uA9E0-\uA9E4\uA9E6-\uA9EF\uA9FA-\uA9FE\uAA00-\uAA28\uAA40-\uAA42\uAA44-\uAA4B\uAA60-\uAA76\uAA7A\uAA7E-\uAAAF\uAAB1\uAAB5\uAAB6\uAAB9-\uAABD\uAAC0\uAAC2\uAADB-\uAADD\uAAE0-\uAAEA\uAAF2-\uAAF4\uAB01-\uAB06\uAB09-\uAB0E\uAB11-\uAB16\uAB20-\uAB26\uAB28-\uAB2E\uAB30-\uAB5A\uAB5C-\uAB69\uAB70-\uABE2\uAC00-\uD7A3\uD7B0-\uD7C6\uD7CB-\uD7FB\uF900-\uFA6D\uFA70-\uFAD9\uFB00-\uFB06\uFB13-\uFB17\uFB1D\uFB1F-\uFB28\uFB2A-\uFB36\uFB38-\uFB3C\uFB3E\uFB40\uFB41\uFB43\uFB44\uFB46-\uFBB1\uFBD3-\uFD3D\uFD50-\uFD8F\uFD92-\uFDC7\uFDF0-\uFDFB\uFE70-\uFE74\uFE76-\uFEFC\uFF21-\uFF3A\uFF41-\uFF5A\uFF66-\uFFBE\uFFC2-\uFFC7\uFFCA-\uFFCF\uFFD2-\uFFD7\uFFDA-\uFFDC]|\uD800[\uDC00-\uDC0B\uDC0D-\uDC26\uDC28-\uDC3A\uDC3C\uDC3D\uDC3F-\uDC4D\uDC50-\uDC5D\uDC80-\uDCFA\uDE80-\uDE9C\uDEA0-\uDED0\uDF00-\uDF1F\uDF2D-\uDF40\uDF42-\uDF49\uDF50-\uDF75\uDF80-\uDF9D\uDFA0-\uDFC3\uDFC8-\uDFCF]|\uD801[\uDC00-\uDC9D\uDCB0-\uDCD3\uDCD8-\uDCFB\uDD00-\uDD27\uDD30-\uDD63\uDD70-\uDD7A\uDD7C-\uDD8A\uDD8C-\uDD92\uDD94\uDD95\uDD97-\uDDA1\uDDA3-\uDDB1\uDDB3-\uDDB9\uDDBB\uDDBC\uDE00-\uDF36\uDF40-\uDF55\uDF60-\uDF67\uDF80-\uDF85\uDF87-\uDFB0\uDFB2-\uDFBA]|\uD802[\uDC00-\uDC05\uDC08\uDC0A-\uDC35\uDC37\uDC38\uDC3C\uDC3F-\uDC55\uDC60-\uDC76\uDC80-\uDC9E\uDCE0-\uDCF2\uDCF4\uDCF5\uDD00-\uDD15\uDD20-\uDD39\uDD80-\uDDB7\uDDBE\uDDBF\uDE00\uDE10-\uDE13\uDE15-\uDE17\uDE19-\uDE35\uDE60-\uDE7C\uDE80-\uDE9C\uDEC0-\uDEC7\uDEC9-\uDEE4\uDF00-\uDF35\uDF40-\uDF55\uDF60-\uDF72\uDF80-\uDF91]|\uD803[\uDC00-\uDC48\uDC80-\uDCB2\uDCC0-\uDCF2\uDD00-\uDD23\uDE80-\uDEA9\uDEB0\uDEB1\uDF00-\uDF1C\uDF27\uDF30-\uDF45\uDF70-\uDF81\uDFB0-\uDFC4\uDFE0-\uDFF6]|\uD804[\uDC03-\uDC37\uDC71\uDC72\uDC75\uDC83-\uDCAF\uDCD0-\uDCE8\uDD03-\uDD26\uDD44\uDD47\uDD50-\uDD72\uDD76\uDD83-\uDDB2\uDDC1-\uDDC4\uDDDA\uDDDC\uDE00-\uDE11\uDE13-\uDE2B\uDE80-\uDE86\uDE88\uDE8A-\uDE8D\uDE8F-\uDE9D\uDE9F-\uDEA8\uDEB0-\uDEDE\uDF05-\uDF0C\uDF0F\uDF10\uDF13-\uDF28\uDF2A-\uDF30\uDF32\uDF33\uDF35-\uDF39\uDF3D\uDF50\uDF5D-\uDF61]|\uD805[\uDC00-\uDC34\uDC47-\uDC4A\uDC5F-\uDC61\uDC80-\uDCAF\uDCC4\uDCC5\uDCC7\uDD80-\uDDAE\uDDD8-\uDDDB\uDE00-\uDE2F\uDE44\uDE80-\uDEAA\uDEB8\uDF00-\uDF1A\uDF40-\uDF46]|\uD806[\uDC00-\uDC2B\uDCA0-\uDCDF\uDCFF-\uDD06\uDD09\uDD0C-\uDD13\uDD15\uDD16\uDD18-\uDD2F\uDD3F\uDD41\uDDA0-\uDDA7\uDDAA-\uDDD0\uDDE1\uDDE3\uDE00\uDE0B-\uDE32\uDE3A\uDE50\uDE5C-\uDE89\uDE9D\uDEB0-\uDEF8]|\uD807[\uDC00-\uDC08\uDC0A-\uDC2E\uDC40\uDC72-\uDC8F\uDD00-\uDD06\uDD08\uDD09\uDD0B-\uDD30\uDD46\uDD60-\uDD65\uDD67\uDD68\uDD6A-\uDD89\uDD98\uDEE0-\uDEF2\uDFB0]|\uD808[\uDC00-\uDF99]|\uD809[\uDC80-\uDD43]|\uD80B[\uDF90-\uDFF0]|[\uD80C\uD81C-\uD820\uD822\uD840-\uD868\uD86A-\uD86C\uD86F-\uD872\uD874-\uD879\uD880-\uD883][\uDC00-\uDFFF]|\uD80D[\uDC00-\uDC2E]|\uD811[\uDC00-\uDE46]|\uD81A[\uDC00-\uDE38\uDE40-\uDE5E\uDE70-\uDEBE\uDED0-\uDEED\uDF00-\uDF2F\uDF40-\uDF43\uDF63-\uDF77\uDF7D-\uDF8F]|\uD81B[\uDE40-\uDE7F\uDF00-\uDF4A\uDF50\uDF93-\uDF9F\uDFE0\uDFE1\uDFE3]|\uD821[\uDC00-\uDFF7]|\uD823[\uDC00-\uDCD5\uDD00-\uDD08]|\uD82B[\uDFF0-\uDFF3\uDFF5-\uDFFB\uDFFD\uDFFE]|\uD82C[\uDC00-\uDD22\uDD50-\uDD52\uDD64-\uDD67\uDD70-\uDEFB]|\uD82F[\uDC00-\uDC6A\uDC70-\uDC7C\uDC80-\uDC88\uDC90-\uDC99]|\uD835[\uDC00-\uDC54\uDC56-\uDC9C\uDC9E\uDC9F\uDCA2\uDCA5\uDCA6\uDCA9-\uDCAC\uDCAE-\uDCB9\uDCBB\uDCBD-\uDCC3\uDCC5-\uDD05\uDD07-\uDD0A\uDD0D-\uDD14\uDD16-\uDD1C\uDD1E-\uDD39\uDD3B-\uDD3E\uDD40-\uDD44\uDD46\uDD4A-\uDD50\uDD52-\uDEA5\uDEA8-\uDEC0\uDEC2-\uDEDA\uDEDC-\uDEFA\uDEFC-\uDF14\uDF16-\uDF34\uDF36-\uDF4E\uDF50-\uDF6E\uDF70-\uDF88\uDF8A-\uDFA8\uDFAA-\uDFC2\uDFC4-\uDFCB]|\uD837[\uDF00-\uDF1E]|\uD838[\uDD00-\uDD2C\uDD37-\uDD3D\uDD4E\uDE90-\uDEAD\uDEC0-\uDEEB]|\uD839[\uDFE0-\uDFE6\uDFE8-\uDFEB\uDFED\uDFEE\uDFF0-\uDFFE]|\uD83A[\uDC00-\uDCC4\uDD00-\uDD43\uDD4B]|\uD83B[\uDE00-\uDE03\uDE05-\uDE1F\uDE21\uDE22\uDE24\uDE27\uDE29-\uDE32\uDE34-\uDE37\uDE39\uDE3B\uDE42\uDE47\uDE49\uDE4B\uDE4D-\uDE4F\uDE51\uDE52\uDE54\uDE57\uDE59\uDE5B\uDE5D\uDE5F\uDE61\uDE62\uDE64\uDE67-\uDE6A\uDE6C-\uDE72\uDE74-\uDE77\uDE79-\uDE7C\uDE7E\uDE80-\uDE89\uDE8B-\uDE9B\uDEA1-\uDEA3\uDEA5-\uDEA9\uDEAB-\uDEBB]|\uD869[\uDC00-\uDEDF\uDF00-\uDFFF]|\uD86D[\uDC00-\uDF38\uDF40-\uDFFF]|\uD86E[\uDC00-\uDC1D\uDC20-\uDFFF]|\uD873[\uDC00-\uDEA1\uDEB0-\uDFFF]|\uD87A[\uDC00-\uDFE0]|\uD87E[\uDC00-\uDE1D]|\uD884[\uDC00-\uDF4A])\S*/g;let Li=(()=>{class U{transform(ne){if(null==ne)return null;if("string"!=typeof ne)throw Mi();return ne.replace(sa,ye=>ye[0].toUpperCase()+ye.slice(1).toLowerCase())}static \u0275fac=function(ye){return new(ye||U)};static \u0275pipe=i.EJ8({name:"titlecase",type:U,pure:!0})}return U})();const Ks=new i.nKC(""),Oo=new i.nKC("");let Cs=(()=>{class U{locale;defaultTimezone;defaultOptions;constructor(ne,ye,Et){this.locale=ne,this.defaultTimezone=ye,this.defaultOptions=Et}transform(ne,ye,Et,Gt){if(null==ne||""===ne||ne!=ne)return null;try{return z(ne,ye??this.defaultOptions?.dateFormat??"mediumDate",Gt||this.locale,Et??this.defaultOptions?.timezone??this.defaultTimezone??void 0)}catch(Un){throw Mi()}}static \u0275fac=function(ye){return new(ye||U)(i.rXU(i.xe9,16),i.rXU(Ks,24),i.rXU(Oo,24))};static \u0275pipe=i.EJ8({name:"date",type:U,pure:!0})}return U})();const No=/#/g;let hs=(()=>{class U{_localization;constructor(ne){this._localization=ne}transform(ne,ye,Et){if(null==ne)return"";if("object"!=typeof ye||null===ye)throw Mi();return ye[function Jo(U,Ie,ne,ye){let Et=`=${U}`;if(Ie.indexOf(Et)>-1||(Et=ne.getPluralCategory(U,ye),Ie.indexOf(Et)>-1))return Et;if(Ie.indexOf("other")>-1)return"other";throw new Error(`No plural message found for value "${U}"`)}(ne,Object.keys(ye),this._localization,Et)].replace(No,ne.toString())}static \u0275fac=function(ye){return new(ye||U)(i.rXU(fo,16))};static \u0275pipe=i.EJ8({name:"i18nPlural",type:U,pure:!0})}return U})(),Ao=(()=>{class U{static \u0275fac=function(ye){return new(ye||U)};static \u0275mod=i.$C({type:U});static \u0275inj=i.G2t({})}return U})();const lr="browser",As="server";function Gs(U){return U===lr}function _s(U){return U===As}let ls=(()=>{class U{static \u0275prov=(0,i.jDH)({token:U,providedIn:"root",factory:()=>Gs((0,i.WQX)(i.Agw))?new Vi((0,i.WQX)(S),window):new ca})}return U})();class Vi{document;window;offset=()=>[0,0];constructor(Ie,ne){this.document=Ie,this.window=ne}setOffset(Ie){this.offset=Array.isArray(Ie)?()=>Ie:Ie}getScrollPosition(){return[this.window.scrollX,this.window.scrollY]}scrollToPosition(Ie){this.window.scrollTo(Ie[0],Ie[1])}scrollToAnchor(Ie){const ne=function ll(U,Ie){const ne=U.getElementById(Ie)||U.getElementsByName(Ie)[0];if(ne)return ne;if("function"==typeof U.createTreeWalker&&U.body&&"function"==typeof U.body.attachShadow){const ye=U.createTreeWalker(U.body,NodeFilter.SHOW_ELEMENT);let Et=ye.currentNode;for(;Et;){const Gt=Et.shadowRoot;if(Gt){const Un=Gt.getElementById(Ie)||Gt.querySelector(`[name="${Ie}"]`);if(Un)return Un}Et=ye.nextNode()}}return null}(this.document,Ie);ne&&(this.scrollToElement(ne),ne.focus())}setHistoryScrollRestoration(Ie){this.window.history.scrollRestoration=Ie}scrollToElement(Ie){const ne=Ie.getBoundingClientRect(),ye=ne.left+this.window.pageXOffset,Et=ne.top+this.window.pageYOffset,Gt=this.offset();this.window.scrollTo(ye-Gt[0],Et-Gt[1])}}class ca{setOffset(Ie){}getScrollPosition(){return[0,0]}scrollToPosition(Ie){}scrollToAnchor(Ie){}setHistoryScrollRestoration(Ie){}}class Ss{}},7691:(o,s,r)=>{"use strict";r.d(s,{$R:()=>Ve,Nl:()=>De,Qq:()=>Ft,b$:()=>Dt,cS:()=>Vn,yz:()=>yn});var i=r(3014),a=r(3107),c=r(3016),y=r(1698),w=r(1787),C=r(1459),T=r(1483),S=r(7947),M=r(4447),O=r(2867),L=r(4460);class Z{}class q{}class re{headers;normalizedNames=new Map;lazyInit;lazyUpdate=null;constructor(xt){xt?"string"==typeof xt?this.lazyInit=()=>{this.headers=new Map,xt.split("\n").forEach(ht=>{const ve=ht.indexOf(":");if(ve>0){const Ye=ht.slice(0,ve),Ne=ht.slice(ve+1).trim();this.addHeaderEntry(Ye,Ne)}})}:typeof Headers<"u"&&xt instanceof Headers?(this.headers=new Map,xt.forEach((ht,ve)=>{this.addHeaderEntry(ve,ht)})):this.lazyInit=()=>{this.headers=new Map,Object.entries(xt).forEach(([ht,ve])=>{this.setHeaderEntries(ht,ve)})}:this.headers=new Map}has(xt){return this.init(),this.headers.has(xt.toLowerCase())}get(xt){this.init();const ht=this.headers.get(xt.toLowerCase());return ht&&ht.length>0?ht[0]:null}keys(){return this.init(),Array.from(this.normalizedNames.values())}getAll(xt){return this.init(),this.headers.get(xt.toLowerCase())||null}append(xt,ht){return this.clone({name:xt,value:ht,op:"a"})}set(xt,ht){return this.clone({name:xt,value:ht,op:"s"})}delete(xt,ht){return this.clone({name:xt,value:ht,op:"d"})}maybeSetNormalizedName(xt,ht){this.normalizedNames.has(ht)||this.normalizedNames.set(ht,xt)}init(){this.lazyInit&&(this.lazyInit instanceof re?this.copyFrom(this.lazyInit):this.lazyInit(),this.lazyInit=null,this.lazyUpdate&&(this.lazyUpdate.forEach(xt=>this.applyUpdate(xt)),this.lazyUpdate=null))}copyFrom(xt){xt.init(),Array.from(xt.headers.keys()).forEach(ht=>{this.headers.set(ht,xt.headers.get(ht)),this.normalizedNames.set(ht,xt.normalizedNames.get(ht))})}clone(xt){const ht=new re;return ht.lazyInit=this.lazyInit&&this.lazyInit instanceof re?this.lazyInit:this,ht.lazyUpdate=(this.lazyUpdate||[]).concat([xt]),ht}applyUpdate(xt){const ht=xt.name.toLowerCase();switch(xt.op){case"a":case"s":let ve=xt.value;if("string"==typeof ve&&(ve=[ve]),0===ve.length)return;this.maybeSetNormalizedName(xt.name,ht);const Ye=("a"===xt.op?this.headers.get(ht):void 0)||[];Ye.push(...ve),this.headers.set(ht,Ye);break;case"d":const Ne=xt.value;if(Ne){let gt=this.headers.get(ht);if(!gt)return;gt=gt.filter(Ht=>-1===Ne.indexOf(Ht)),0===gt.length?(this.headers.delete(ht),this.normalizedNames.delete(ht)):this.headers.set(ht,gt)}else this.headers.delete(ht),this.normalizedNames.delete(ht)}}addHeaderEntry(xt,ht){const ve=xt.toLowerCase();this.maybeSetNormalizedName(xt,ve),this.headers.has(ve)?this.headers.get(ve).push(ht):this.headers.set(ve,[ht])}setHeaderEntries(xt,ht){const ve=(Array.isArray(ht)?ht:[ht]).map(Ne=>Ne.toString()),Ye=xt.toLowerCase();this.headers.set(Ye,ve),this.maybeSetNormalizedName(xt,Ye)}forEach(xt){this.init(),Array.from(this.normalizedNames.keys()).forEach(ht=>xt(this.normalizedNames.get(ht),this.headers.get(ht)))}}class se{encodeKey(xt){return Oe(xt)}encodeValue(xt){return Oe(xt)}decodeKey(xt){return decodeURIComponent(xt)}decodeValue(xt){return decodeURIComponent(xt)}}const me=/%(\d[a-f0-9])/gi,be={40:"@","3A":":",24:"$","2C":",","3B":";","3D":"=","3F":"?","2F":"/"};function Oe(tt){return encodeURIComponent(tt).replace(me,(xt,ht)=>be[ht]??xt)}function xe(tt){return`${tt}`}class De{map;encoder;updates=null;cloneFrom=null;constructor(xt={}){if(this.encoder=xt.encoder||new se,xt.fromString){if(xt.fromObject)throw new Error("Cannot specify both fromString and fromObject.");this.map=function ae(tt,xt){const ht=new Map;return tt.length>0&&tt.replace(/^\?/,"").split("&").forEach(Ye=>{const Ne=Ye.indexOf("="),[gt,Ht]=-1==Ne?[xt.decodeKey(Ye),""]:[xt.decodeKey(Ye.slice(0,Ne)),xt.decodeValue(Ye.slice(Ne+1))],kt=ht.get(gt)||[];kt.push(Ht),ht.set(gt,kt)}),ht}(xt.fromString,this.encoder)}else xt.fromObject?(this.map=new Map,Object.keys(xt.fromObject).forEach(ht=>{const ve=xt.fromObject[ht],Ye=Array.isArray(ve)?ve.map(xe):[xe(ve)];this.map.set(ht,Ye)})):this.map=null}has(xt){return this.init(),this.map.has(xt)}get(xt){this.init();const ht=this.map.get(xt);return ht?ht[0]:null}getAll(xt){return this.init(),this.map.get(xt)||null}keys(){return this.init(),Array.from(this.map.keys())}append(xt,ht){return this.clone({param:xt,value:ht,op:"a"})}appendAll(xt){const ht=[];return Object.keys(xt).forEach(ve=>{const Ye=xt[ve];Array.isArray(Ye)?Ye.forEach(Ne=>{ht.push({param:ve,value:Ne,op:"a"})}):ht.push({param:ve,value:Ye,op:"a"})}),this.clone(ht)}set(xt,ht){return this.clone({param:xt,value:ht,op:"s"})}delete(xt,ht){return this.clone({param:xt,value:ht,op:"d"})}toString(){return this.init(),this.keys().map(xt=>{const ht=this.encoder.encodeKey(xt);return this.map.get(xt).map(ve=>ht+"="+this.encoder.encodeValue(ve)).join("&")}).filter(xt=>""!==xt).join("&")}clone(xt){const ht=new De({encoder:this.encoder});return ht.cloneFrom=this.cloneFrom||this,ht.updates=(this.updates||[]).concat(xt),ht}init(){null===this.map&&(this.map=new Map),null!==this.cloneFrom&&(this.cloneFrom.init(),this.cloneFrom.keys().forEach(xt=>this.map.set(xt,this.cloneFrom.map.get(xt))),this.updates.forEach(xt=>{switch(xt.op){case"a":case"s":const ht=("a"===xt.op?this.map.get(xt.param):void 0)||[];ht.push(xe(xt.value)),this.map.set(xt.param,ht);break;case"d":if(void 0===xt.value){this.map.delete(xt.param);break}{let ve=this.map.get(xt.param)||[];const Ye=ve.indexOf(xe(xt.value));-1!==Ye&&ve.splice(Ye,1),ve.length>0?this.map.set(xt.param,ve):this.map.delete(xt.param)}}}),this.cloneFrom=this.updates=null)}}class ue{map=new Map;set(xt,ht){return this.map.set(xt,ht),this}get(xt){return this.map.has(xt)||this.map.set(xt,xt.defaultValue()),this.map.get(xt)}delete(xt){return this.map.delete(xt),this}has(xt){return this.map.has(xt)}keys(){return this.map.keys()}}function Be(tt){return typeof ArrayBuffer<"u"&&tt instanceof ArrayBuffer}function at(tt){return typeof Blob<"u"&&tt instanceof Blob}function dt(tt){return typeof FormData<"u"&&tt instanceof FormData}class lt{url;body=null;headers;context;reportProgress=!1;withCredentials=!1;responseType="json";method;params;urlWithParams;transferCache;constructor(xt,ht,ve,Ye){let Ne;if(this.url=ht,this.method=xt.toUpperCase(),function Ce(tt){switch(tt){case"DELETE":case"GET":case"HEAD":case"OPTIONS":case"JSONP":return!1;default:return!0}}(this.method)||Ye?(this.body=void 0!==ve?ve:null,Ne=Ye):Ne=ve,Ne&&(this.reportProgress=!!Ne.reportProgress,this.withCredentials=!!Ne.withCredentials,Ne.responseType&&(this.responseType=Ne.responseType),Ne.headers&&(this.headers=Ne.headers),Ne.context&&(this.context=Ne.context),Ne.params&&(this.params=Ne.params),this.transferCache=Ne.transferCache),this.headers??=new re,this.context??=new ue,this.params){const gt=this.params.toString();if(0===gt.length)this.urlWithParams=ht;else{const Ht=ht.indexOf("?");this.urlWithParams=ht+(-1===Ht?"?":HtNn.set(jn,xt.setHeaders[jn]),hn)),xt.setParams&&(Dn=Object.keys(xt.setParams).reduce((Nn,jn)=>Nn.set(jn,xt.setParams[jn]),Dn)),new lt(ht,ve,gt,{params:Dn,headers:hn,context:Cn,reportProgress:kt,responseType:Ye,withCredentials:Ht,transferCache:Ne})}}var rn=function(tt){return tt[tt.Sent=0]="Sent",tt[tt.UploadProgress=1]="UploadProgress",tt[tt.ResponseHeader=2]="ResponseHeader",tt[tt.DownloadProgress=3]="DownloadProgress",tt[tt.Response=4]="Response",tt[tt.User=5]="User",tt}(rn||{});class gn{headers;status;statusText;url;ok;type;constructor(xt,ht=200,ve="OK"){this.headers=xt.headers||new re,this.status=void 0!==xt.status?xt.status:ht,this.statusText=xt.statusText||ve,this.url=xt.url||null,this.ok=this.status>=200&&this.status<300}}class bn extends gn{constructor(xt={}){super(xt)}type=rn.ResponseHeader;clone(xt={}){return new bn({headers:xt.headers||this.headers,status:void 0!==xt.status?xt.status:this.status,statusText:xt.statusText||this.statusText,url:xt.url||this.url||void 0})}}class Vn extends gn{body;constructor(xt={}){super(xt),this.body=void 0!==xt.body?xt.body:null}type=rn.Response;clone(xt={}){return new Vn({body:void 0!==xt.body?xt.body:this.body,headers:xt.headers||this.headers,status:void 0!==xt.status?xt.status:this.status,statusText:xt.statusText||this.statusText,url:xt.url||this.url||void 0})}}class yn extends gn{name="HttpErrorResponse";message;error;ok=!1;constructor(xt){super(xt,0,"Unknown Error"),this.message=this.status>=200&&this.status<300?`Http failure during parsing for ${xt.url||"(unknown url)"}`:`Http failure response for ${xt.url||"(unknown url)"}: ${xt.status} ${xt.statusText}`,this.error=xt.error||null}}function $e(tt,xt){return{body:xt,headers:tt.headers,context:tt.context,observe:tt.observe,params:tt.params,reportProgress:tt.reportProgress,responseType:tt.responseType,withCredentials:tt.withCredentials,transferCache:tt.transferCache}}let Ft=(()=>{class tt{handler;constructor(ht){this.handler=ht}request(ht,ve,Ye={}){let Ne;if(ht instanceof lt)Ne=ht;else{let kt,hn;kt=Ye.headers instanceof re?Ye.headers:new re(Ye.headers),Ye.params&&(hn=Ye.params instanceof De?Ye.params:new De({fromObject:Ye.params})),Ne=new lt(ht,ve,void 0!==Ye.body?Ye.body:null,{headers:kt,context:Ye.context,params:hn,reportProgress:Ye.reportProgress,responseType:Ye.responseType||"json",withCredentials:Ye.withCredentials,transferCache:Ye.transferCache})}const gt=(0,c.of)(Ne).pipe((0,C.H)(kt=>this.handler.handle(kt)));if(ht instanceof lt||"events"===Ye.observe)return gt;const Ht=gt.pipe((0,T.p)(kt=>kt instanceof Vn));switch(Ye.observe||"body"){case"body":switch(Ne.responseType){case"arraybuffer":return Ht.pipe((0,S.T)(kt=>{if(null!==kt.body&&!(kt.body instanceof ArrayBuffer))throw new Error("Response is not an ArrayBuffer.");return kt.body}));case"blob":return Ht.pipe((0,S.T)(kt=>{if(null!==kt.body&&!(kt.body instanceof Blob))throw new Error("Response is not a Blob.");return kt.body}));case"text":return Ht.pipe((0,S.T)(kt=>{if(null!==kt.body&&"string"!=typeof kt.body)throw new Error("Response is not a string.");return kt.body}));default:return Ht.pipe((0,S.T)(kt=>kt.body))}case"response":return Ht;default:throw new Error(`Unreachable: unhandled observe type ${Ye.observe}}`)}}delete(ht,ve={}){return this.request("DELETE",ht,ve)}get(ht,ve={}){return this.request("GET",ht,ve)}head(ht,ve={}){return this.request("HEAD",ht,ve)}jsonp(ht,ve){return this.request("JSONP",ht,{params:(new De).append(ve,"JSONP_CALLBACK"),observe:"body",responseType:"json"})}options(ht,ve={}){return this.request("OPTIONS",ht,ve)}patch(ht,ve,Ye={}){return this.request("PATCH",ht,$e(Ye,ve))}post(ht,ve,Ye={}){return this.request("POST",ht,$e(Ye,ve))}put(ht,ve,Ye={}){return this.request("PUT",ht,$e(Ye,ve))}static \u0275fac=function(ve){return new(ve||tt)(a.KVO(Z))};static \u0275prov=a.jDH({token:tt,factory:tt.\u0275fac})}return tt})();const Ke=/^\)\]\}',?\n/;function it(tt){if(tt.url)return tt.url;const xt="X-Request-URL".toLocaleLowerCase();return tt.headers.get(xt)}let Ot=(()=>{class tt{fetchImpl=(0,a.WQX)($t,{optional:!0})?.fetch??((...ht)=>globalThis.fetch(...ht));ngZone=(0,a.WQX)(a.SKi);handle(ht){return new y.c(ve=>{const Ye=new AbortController;return this.doRequest(ht,Ye.signal,ve).then(Te,Ne=>ve.error(new yn({error:Ne}))),()=>Ye.abort()})}doRequest(ht,ve,Ye){var Ne=this;return(0,i.A)(function*(){const gt=Ne.createRequestInit(ht);let Ht;try{const Jn=Ne.ngZone.runOutsideAngular(()=>Ne.fetchImpl(ht.urlWithParams,{signal:ve,...gt}));(function Ee(tt){tt.then(Te,Te)})(Jn),Ye.next({type:rn.Sent}),Ht=yield Jn}catch(Jn){return void Ye.error(new yn({error:Jn,status:Jn.status??0,statusText:Jn.statusText,url:ht.urlWithParams,headers:Jn.headers}))}const kt=new re(Ht.headers),hn=Ht.statusText,Dn=it(Ht)??ht.urlWithParams;let Cn=Ht.status,Nn=null;if(ht.reportProgress&&Ye.next(new bn({headers:kt,status:Cn,statusText:hn,url:Dn})),Ht.body){const Jn=Ht.headers.get("content-length"),ar=[],wr=Ht.body.getReader();let gi,ni,xr=0;const Mi=typeof Zone<"u"&&Zone.current;yield Ne.ngZone.runOutsideAngular((0,i.A)(function*(){for(;;){const{done:Qr,value:Pr}=yield wr.read();if(Qr)break;if(ar.push(Pr),xr+=Pr.length,ht.reportProgress){ni="text"===ht.responseType?(ni??"")+(gi??=new TextDecoder).decode(Pr,{stream:!0}):void 0;const Do=()=>Ye.next({type:rn.DownloadProgress,total:Jn?+Jn:void 0,loaded:xr,partialText:ni});Mi?Mi.run(Do):Do()}}}));const Or=Ne.concatChunks(ar,xr);try{const Qr=Ht.headers.get("Content-Type")??"";Nn=Ne.parseBody(ht,Or,Qr)}catch(Qr){return void Ye.error(new yn({error:Qr,headers:new re(Ht.headers),status:Ht.status,statusText:Ht.statusText,url:it(Ht)??ht.urlWithParams}))}}0===Cn&&(Cn=Nn?200:0),Cn>=200&&Cn<300?(Ye.next(new Vn({body:Nn,headers:kt,status:Cn,statusText:hn,url:Dn})),Ye.complete()):Ye.error(new yn({error:Nn,headers:kt,status:Cn,statusText:hn,url:Dn}))})()}parseBody(ht,ve,Ye){switch(ht.responseType){case"json":const Ne=(new TextDecoder).decode(ve).replace(Ke,"");return""===Ne?null:JSON.parse(Ne);case"text":return(new TextDecoder).decode(ve);case"blob":return new Blob([ve],{type:Ye});case"arraybuffer":return ve.buffer}}createRequestInit(ht){const ve={},Ye=ht.withCredentials?"include":void 0;if(ht.headers.forEach((Ne,gt)=>ve[Ne]=gt.join(",")),ht.headers.has("Accept")||(ve.Accept="application/json, text/plain, */*"),!ht.headers.has("Content-Type")){const Ne=ht.detectContentTypeHeader();null!==Ne&&(ve["Content-Type"]=Ne)}return{body:ht.serializeBody(),method:ht.method,headers:ve,credentials:Ye}}concatChunks(ht,ve){const Ye=new Uint8Array(ve);let Ne=0;for(const gt of ht)Ye.set(gt,Ne),Ne+=gt.length;return Ye}static \u0275fac=function(ve){return new(ve||tt)};static \u0275prov=a.jDH({token:tt,factory:tt.\u0275fac})}return tt})();class $t{}function Te(){}function st(tt,xt){return xt(tt)}const rt=new a.nKC(""),Vt=new a.nKC(""),en=new a.nKC("",{providedIn:"root",factory:()=>!0});let Rn=(()=>{class tt extends Z{backend;injector;chain=null;pendingTasks=(0,a.WQX)(a.TgB);contributeToStability=(0,a.WQX)(en);constructor(ht,ve){super(),this.backend=ht,this.injector=ve}handle(ht){if(null===this.chain){const ve=Array.from(new Set([...this.injector.get(rt),...this.injector.get(Vt,[])]));this.chain=ve.reduceRight((Ye,Ne)=>function Mt(tt,xt,ht){return(ve,Ye)=>(0,a.N4e)(ht,()=>xt(ve,Ne=>tt(Ne,Ye)))}(Ye,Ne,this.injector),st)}if(this.contributeToStability){const ve=this.pendingTasks.add();return this.chain(ht,Ye=>this.backend.handle(Ye)).pipe((0,M.j)(()=>this.pendingTasks.remove(ve)))}return this.chain(ht,ve=>this.backend.handle(ve))}static \u0275fac=function(ve){return new(ve||tt)(a.KVO(q),a.KVO(a.uvJ))};static \u0275prov=a.jDH({token:tt,factory:tt.\u0275fac})}return tt})();const St=/^\)\]\}',?\n/;let an=(()=>{class tt{xhrFactory;constructor(ht){this.xhrFactory=ht}handle(ht){if("JSONP"===ht.method)throw new a.wOt(-2800,!1);const ve=this.xhrFactory;return(ve.\u0275loadImpl?(0,w.H)(ve.\u0275loadImpl()):(0,c.of)(null)).pipe((0,O.n)(()=>new y.c(Ne=>{const gt=ve.build();if(gt.open(ht.method,ht.urlWithParams),ht.withCredentials&&(gt.withCredentials=!0),ht.headers.forEach((ar,wr)=>gt.setRequestHeader(ar,wr.join(","))),ht.headers.has("Accept")||gt.setRequestHeader("Accept","application/json, text/plain, */*"),!ht.headers.has("Content-Type")){const ar=ht.detectContentTypeHeader();null!==ar&>.setRequestHeader("Content-Type",ar)}if(ht.responseType){const ar=ht.responseType.toLowerCase();gt.responseType="json"!==ar?ar:"text"}const Ht=ht.serializeBody();let kt=null;const hn=()=>{if(null!==kt)return kt;const ar=gt.statusText||"OK",wr=new re(gt.getAllResponseHeaders()),xr=function Tn(tt){return"responseURL"in tt&&tt.responseURL?tt.responseURL:/^X-Request-URL:/m.test(tt.getAllResponseHeaders())?tt.getResponseHeader("X-Request-URL"):null}(gt)||ht.url;return kt=new bn({headers:wr,status:gt.status,statusText:ar,url:xr}),kt},Dn=()=>{let{headers:ar,status:wr,statusText:xr,url:gi}=hn(),ni=null;204!==wr&&(ni=typeof gt.response>"u"?gt.responseText:gt.response),0===wr&&(wr=ni?200:0);let Mi=wr>=200&&wr<300;if("json"===ht.responseType&&"string"==typeof ni){const Or=ni;ni=ni.replace(St,"");try{ni=""!==ni?JSON.parse(ni):null}catch(Qr){ni=Or,Mi&&(Mi=!1,ni={error:Qr,text:ni})}}Mi?(Ne.next(new Vn({body:ni,headers:ar,status:wr,statusText:xr,url:gi||void 0})),Ne.complete()):Ne.error(new yn({error:ni,headers:ar,status:wr,statusText:xr,url:gi||void 0}))},Cn=ar=>{const{url:wr}=hn(),xr=new yn({error:ar,status:gt.status||0,statusText:gt.statusText||"Unknown Error",url:wr||void 0});Ne.error(xr)};let Nn=!1;const jn=ar=>{Nn||(Ne.next(hn()),Nn=!0);let wr={type:rn.DownloadProgress,loaded:ar.loaded};ar.lengthComputable&&(wr.total=ar.total),"text"===ht.responseType&>.responseText&&(wr.partialText=gt.responseText),Ne.next(wr)},Jn=ar=>{let wr={type:rn.UploadProgress,loaded:ar.loaded};ar.lengthComputable&&(wr.total=ar.total),Ne.next(wr)};return gt.addEventListener("load",Dn),gt.addEventListener("error",Cn),gt.addEventListener("timeout",Cn),gt.addEventListener("abort",Cn),ht.reportProgress&&(gt.addEventListener("progress",jn),null!==Ht&>.upload&>.upload.addEventListener("progress",Jn)),gt.send(Ht),Ne.next({type:rn.Sent}),()=>{gt.removeEventListener("error",Cn),gt.removeEventListener("abort",Cn),gt.removeEventListener("load",Dn),gt.removeEventListener("timeout",Cn),ht.reportProgress&&(gt.removeEventListener("progress",jn),null!==Ht&>.upload&>.upload.removeEventListener("progress",Jn)),gt.readyState!==gt.DONE&>.abort()}})))}static \u0275fac=function(ve){return new(ve||tt)(a.KVO(L.N0))};static \u0275prov=a.jDH({token:tt,factory:tt.\u0275fac})}return tt})();const dn=new a.nKC(""),sr=new a.nKC("",{providedIn:"root",factory:()=>"XSRF-TOKEN"}),Hr=new a.nKC("",{providedIn:"root",factory:()=>"X-XSRF-TOKEN"});class Tr{}let Vr=(()=>{class tt{doc;platform;cookieName;lastCookieString="";lastToken=null;parseCount=0;constructor(ht,ve,Ye){this.doc=ht,this.platform=ve,this.cookieName=Ye}getToken(){if("server"===this.platform)return null;const ht=this.doc.cookie||"";return ht!==this.lastCookieString&&(this.parseCount++,this.lastToken=(0,L._b)(ht,this.cookieName),this.lastCookieString=ht),this.lastToken}static \u0275fac=function(ve){return new(ve||tt)(a.KVO(L.qQ),a.KVO(a.Agw),a.KVO(sr))};static \u0275prov=a.jDH({token:tt,factory:tt.\u0275fac})}return tt})();function vt(tt,xt){const ht=tt.url.toLowerCase();if(!(0,a.WQX)(dn)||"GET"===tt.method||"HEAD"===tt.method||ht.startsWith("http://")||ht.startsWith("https://"))return xt(tt);const ve=(0,a.WQX)(Tr).getToken(),Ye=(0,a.WQX)(Hr);return null!=ve&&!tt.headers.has(Ye)&&(tt=tt.clone({headers:tt.headers.set(Ye,ve)})),xt(tt)}var Re=function(tt){return tt[tt.Interceptors=0]="Interceptors",tt[tt.LegacyInterceptors=1]="LegacyInterceptors",tt[tt.CustomXsrfConfiguration=2]="CustomXsrfConfiguration",tt[tt.NoXsrfProtection=3]="NoXsrfProtection",tt[tt.JsonpSupport=4]="JsonpSupport",tt[tt.RequestsMadeViaParent=5]="RequestsMadeViaParent",tt[tt.Fetch=6]="Fetch",tt}(Re||{});function Ve(...tt){const xt=[Ft,an,Rn,{provide:Z,useExisting:Rn},{provide:q,useFactory:()=>(0,a.WQX)(Ot,{optional:!0})??(0,a.WQX)(an)},{provide:rt,useValue:vt,multi:!0},{provide:dn,useValue:!0},{provide:Tr,useClass:Vr}];for(const ht of tt)xt.push(...ht.\u0275providers);return(0,a.EmA)(xt)}function Dt(tt){return function Ge(tt,xt){return{\u0275kind:tt,\u0275providers:xt}}(Re.Interceptors,tt.map(xt=>({provide:rt,useValue:xt,multi:!0})))}},3107:(o,s,r)=>{"use strict";function a(e,t){return Object.is(e,t)}r.d(s,{bc$:()=>A,iLQ:()=>pg,sZ2:()=>Du,hnV:()=>Vb,wjH:()=>Wi,o8S:()=>hc,BIS:()=>j,gRc:()=>C2,Ql9:()=>FI,Ocv:()=>WI,Z63:()=>Qn,aKT:()=>Os,uvJ:()=>cs,zcH:()=>Cc,bkB:()=>oc,ES_:()=>lm,$GK:()=>bi,nKC:()=>ht,zZn:()=>Qo,_q3:()=>_w,MKu:()=>vw,xe9:()=>dw,Co$:()=>c1,Vns:()=>gf,SKi:()=>os,Xx1:()=>ca,Agw:()=>b,PLl:()=>sd,rOR:()=>Ff,sFG:()=>jD,_9s:()=>Ib,czy:()=>mp,WPN:()=>ud,kdw:()=>Ts,C4Q:()=>sg,NYb:()=>LA,giA:()=>I1,RxE:()=>f2,c1b:()=>Cv,gXe:()=>Sc,mal:()=>Xa,Tzd:()=>ba,L39:()=>GO,EWP:()=>xw,sbv:()=>$S,a0P:()=>vR,Ol2:()=>Pb,w6W:()=>tA,QZP:()=>Dw,Rfq:()=>Re,oKB:()=>Ua,WQX:()=>lr,hFB:()=>$g,naY:()=>JI,Hps:()=>Bb,QuC:()=>Ro,EmA:()=>jo,Udg:()=>XO,HJs:()=>yR,N4e:()=>$s,vPA:()=>kp,O8t:()=>Zp,H3F:()=>x1,H8p:()=>yl,KH2:()=>Xp,TgB:()=>Ec,wOt:()=>Rn,WHO:()=>M1,e01:()=>k1,lNU:()=>Nr,h9k:()=>Lm,$MX:()=>cp,ZF7:()=>Gd,Kcf:()=>By,e5t:()=>Vy,UyX:()=>$y,cWb:()=>Uy,osQ:()=>jy,H5H:()=>V0,Zy3:()=>pr,mq5:()=>Dx,JZv:()=>dn,TL3:()=>CO,LfX:()=>Fo,plB:()=>Jd,jNT:()=>jb,zjR:()=>O1,ngT:()=>oi,hVU:()=>NA,TL$:()=>_m,Tbb:()=>Tr,rcV:()=>Gc,nM4:()=>TE,Vt3:()=>h0,GFd:()=>RE,OA$:()=>zl,Jv_:()=>LC,R7$:()=>xp,BMQ:()=>A0,HbH:()=>sx,ZvI:()=>fx,AVh:()=>R0,BUC:()=>px,vxM:()=>vx,wni:()=>oC,C6U:()=>cC,VBU:()=>g1,FsC:()=>v1,jDH:()=>ai,G2t:()=>fo,$C:()=>Fb,EJ8:()=>y1,rXU:()=>qd,nrm:()=>B0,eu8:()=>U0,bVm:()=>Fv,qex:()=>Pv,k0s:()=>Lv,j41:()=>Nv,RV6:()=>Cx,xGo:()=>Eh,Mr5:()=>$0,KVO:()=>_o,kS0:()=>Xu,QTQ:()=>iv,bIt:()=>z0,lsd:()=>lC,joV:()=>Br,qSk:()=>Cr,XpG:()=>Xx,nI1:()=>XC,bMT:()=>YC,i5U:()=>QC,SdG:()=>Qx,NAR:()=>Yx,Y8G:()=>k0,FS9:()=>X0,Mz_:()=>Vv,lJ4:()=>FC,eq3:()=>BC,l_i:()=>UC,sMw:()=>$C,ziG:()=>jC,lV:()=>VC,NyB:()=>uC,mGM:()=>aC,sdS:()=>dC,Dyx:()=>wx,Z7z:()=>bx,Vm6:()=>yx,Njj:()=>hu,eBV:()=>Ic,npT:()=>y_,f$h:()=>Fm,B4B:()=>Xd,n$t:()=>b_,Aen:()=>Zc,xc7:()=>O0,Kam:()=>K0,zvX:()=>j0,DNE:()=>m0,C5r:()=>ZC,EFF:()=>wC,JRh:()=>Q0,SpI:()=>Hv,DH7:()=>IC,mxI:()=>q0,R50:()=>Z0,GBs:()=>sC}),r(3014);let c=null,y=!1,w=1;const C=Symbol("SIGNAL");function T(e){const t=c;return c=e,t}const L={version:0,lastCleanEpoch:0,dirty:!1,producerNode:void 0,producerLastReadVersion:void 0,producerIndexOfThis:void 0,nextProducerIndex:0,liveConsumerNode:void 0,liveConsumerIndexOfThis:void 0,consumerAllowSignalWrites:!1,consumerIsAlwaysLive:!1,producerMustRecompute:()=>!1,producerRecomputeValue:()=>{},consumerMarkedDirty:()=>{},consumerOnSignalRead:()=>{}};function Z(e){if(y)throw new Error("");if(null===c)return;c.consumerOnSignalRead(e);const t=c.nextProducerIndex++;Be(c),te.nextProducerIndex;)e.producerNode.pop(),e.producerLastReadVersion.pop(),e.producerIndexOfThis.pop()}}function xe(e){Be(e);for(let t=0;t0}function Be(e){e.producerNode??=[],e.producerIndexOfThis??=[],e.producerLastReadVersion??=[]}function at(e){e.liveConsumerNode??=[],e.liveConsumerIndexOfThis??=[]}function dt(e){return void 0!==e.producerNode}function bt(e){const t=Object.create(bn);t.computation=e;const n=()=>{if(re(t),Z(t),t.value===gn)throw t.error;return t.value};return n[C]=t,n}const lt=Symbol("UNSET"),rn=Symbol("COMPUTING"),gn=Symbol("ERRORED"),bn={...L,value:lt,dirty:!0,error:null,equal:a,producerMustRecompute:e=>e.value===lt||e.value===rn,producerRecomputeValue(e){if(e.value===rn)throw new Error("Detected cycle in computations.");const t=e.value;e.value=rn;const n=be(e);let l;try{l=e.computation()}catch(p){l=gn,e.error=p}finally{Oe(e,n)}t!==lt&&t!==gn&&l!==gn&&e.equal(t,l)?e.value=t:(e.value=l,e.version++)}};let yn=function Vn(){throw new Error};function qe(){yn()}let ze=null;function Ze(e,t){se()||qe(),e.equal(e.value,t)||(e.value=t,function Te(e){e.version++,function q(){w++}(),pe(e),ze?.()}(e))}const $t={...L,equal:a,value:void 0};const st=()=>{},Xt={...L,consumerIsAlwaysLive:!0,consumerAllowSignalWrites:!1,consumerMarkedDirty:e=>{null!==e.schedule&&e.schedule(e.ref)},hasRun:!1,cleanupFn:st};var Kt=r(1217),rt=r(8447),Vt=r(5710),en=r(7947);r(1703);const Nr="https://g.co/ng/security#xss";class Rn extends Error{code;constructor(t,n){super(pr(t,n)),this.code=t}}function pr(e,t){return`NG0${Math.abs(e)}${t?": "+t:""}`}const cn=Symbol("InputSignalNode#UNSET"),Fe={...$t,transformFn:void 0,applyValueToInputSignal(e,t){Ze(e,t)}};function z(e,t){const n=Object.create(Fe);function l(){if(Z(n),n.value===cn)throw new Rn(-950,!1);return n.value}return n.value=e,n.transformFn=t?.transform,l[C]=n,l}function N(e){return{toString:e}.toString()}const Le="__parameters__";function Tn(e,t,n){return N(()=>{const l=function St(e){return function(...n){if(e){const l=e(...n);for(const p in l)this[p]=l[p]}}}(t);function p(...g){if(this instanceof p)return l.apply(this,g),this;const x=new p(...g);return k.annotation=x,k;function k(B,ie,Se){const He=B.hasOwnProperty(Le)?B[Le]:Object.defineProperty(B,Le,{value:[]})[Le];for(;He.length<=Se;)He.push(null);return(He[Se]=He[Se]||[]).push(x),B}}return n&&(p.prototype=Object.create(n.prototype)),p.prototype.ngMetadataName=e,p.annotationCls=p,p})}const dn=globalThis;function xn(e){for(let t in e)if(e[t]===xn)return t;throw Error("Could not find renamed property on target object.")}function Hr(e,t){for(const n in t)t.hasOwnProperty(n)&&!e.hasOwnProperty(n)&&(e[n]=t[n])}function Tr(e){if("string"==typeof e)return e;if(Array.isArray(e))return"["+e.map(Tr).join(", ")+"]";if(null==e)return""+e;if(e.overriddenName)return`${e.overriddenName}`;if(e.name)return`${e.name}`;const t=e.toString();if(null==t)return""+t;const n=t.indexOf("\n");return-1===n?t:t.substring(0,n)}function Vr(e,t){return null==e||""===e?null===t?"":t:null==t||""===t?e:e+" "+t}const Wt=xn({__forward_ref__:xn});function Re(e){return e.__forward_ref__=Re,e.toString=function(){return Tr(this())},e}function Ge(e){return Ve(e)?e():e}function Ve(e){return"function"==typeof e&&e.hasOwnProperty(Wt)&&e.__forward_ref__===Re}function ai(e){return{token:e.token,providedIn:e.providedIn||null,factory:e.factory,value:void 0}}function fo(e){return{providers:e.providers||[],imports:e.imports||[]}}function Jo(e){return oa(e,Ii)||oa(e,tt)}function Fo(e){return null!==Jo(e)}function oa(e,t){return e.hasOwnProperty(t)?e[t]:null}function po(e){return e&&(e.hasOwnProperty(Io)||e.hasOwnProperty(xt))?e[Io]:null}const Ii=xn({\u0275prov:xn}),Io=xn({\u0275inj:xn}),tt=xn({ngInjectableDef:xn}),xt=xn({ngInjectorDef:xn});class ht{_desc;ngMetadataName="InjectionToken";\u0275prov;constructor(t,n){this._desc=t,this.\u0275prov=void 0,"number"==typeof n?this.__NG_ELEMENT_ID__=n:void 0!==n&&(this.\u0275prov=ai({token:this,providedIn:n.providedIn||"root",factory:n.factory}))}get multi(){return this}toString(){return`InjectionToken ${this._desc}`}}function jn(e){return e&&!!e.\u0275providers}const Jn=xn({\u0275cmp:xn}),ar=xn({\u0275dir:xn}),wr=xn({\u0275pipe:xn}),xr=xn({\u0275mod:xn}),gi=xn({\u0275fac:xn}),ni=xn({__NG_ELEMENT_ID__:xn}),Mi=xn({__NG_ENV_ID__:xn});function Or(e){return"string"==typeof e?e:null==e?"":String(e)}function Li(e,t){throw new Rn(-201,!1)}var bi=function(e){return e[e.Default=0]="Default",e[e.Host=1]="Host",e[e.Self=2]="Self",e[e.SkipSelf=4]="SkipSelf",e[e.Optional=8]="Optional",e}(bi||{});let aa;function Ks(){return aa}function Oo(e){const t=aa;return aa=e,t}function Cs(e,t,n){const l=Jo(e);return l&&"root"==l.providedIn?void 0===l.value?l.value=l.factory():l.value:n&bi.Optional?null:void 0!==t?t:void Li()}const Ko={},mo="__NG_DI_FLAG__",Go="ngTempTokenPath",Xr=/\n/gm,go="__source";let io;function Xo(e){const t=io;return io=e,t}function Qa(e,t=bi.Default){if(void 0===io)throw new Rn(-203,!1);return null===io?Cs(e,void 0,t):io.get(e,t&bi.Optional?null:void 0,t)}function _o(e,t=bi.Default){return(Ks()||Qa)(Ge(e),t)}function lr(e,t=bi.Default){return _o(e,As(t))}function As(e){return typeof e>"u"||"number"==typeof e?e:(e.optional&&8)|(e.host&&1)|(e.self&&2)|(e.skipSelf&&4)}function Gs(e){const t=[];for(let n=0;nArray.isArray(n)?ps(n,t):t(n))}function Da(e,t,n){t>=e.length?e.push(n):e.splice(t,0,n)}function Ms(e,t){return t>=e.length-1?e.pop():e.splice(t,1)[0]}function et(e,t,n){let l=ot(e,t);return l>=0?e[1|l]=n:(l=~l,function Aa(e,t,n,l){let p=e.length;if(p==t)e.push(n,l);else if(1===p)e.push(l,e[0]),e[0]=n;else{for(p--,e.push(e[p-1],e[p]);p>t;)e[p]=e[p-2],p--;e[t]=n,e[t+1]=l}}(e,l,t,n)),l}function te(e,t){const n=ot(e,t);if(n>=0)return e[1|n]}function ot(e,t){return function Bn(e,t,n){let l=0,p=e.length>>n;for(;p!==l;){const g=l+(p-l>>1),x=e[g<t?p=g:l=g+1}return~(p<{n.push(x)};return ps(t,x=>{const k=x;de(k,g,[],l)&&(p||=[],p.push(k))}),void 0!==p&&da(p,g),n}function da(e,t){for(let n=0;n{t(g,l)})}}function de(e,t,n,l){if(!(e=Ge(e)))return!1;let p=null,g=po(e);const x=!g&&zr(e);if(g||x){if(x&&!x.standalone)return!1;p=e}else{const B=e.ngModule;if(g=po(B),!g)return!1;p=B}const k=l.has(p);if(x){if(k)return!1;if(l.add(p),x.dependencies){const B="function"==typeof x.dependencies?x.dependencies():x.dependencies;for(const ie of B)de(ie,t,n,l)}}else{if(!g)return!1;{if(null!=g.imports&&!k){let ie;l.add(p);try{ps(g.imports,Se=>{de(Se,t,n,l)&&(ie||=[],ie.push(Se))})}finally{}void 0!==ie&&da(ie,t)}if(!k){const ie=So(p)||(()=>new p);t({provide:p,useFactory:ie,deps:Wn},p),t({provide:zi,useValue:p,multi:!0},p),t({provide:Qn,useValue:()=>_o(p),multi:!0},p)}const B=g.providers;if(null!=B&&!k){const ie=e;Y(B,Se=>{t(Se,ie)})}}}return p!==e&&void 0!==e.providers}function Y(e,t){for(let n of e)jn(n)&&(n=n.\u0275providers),Array.isArray(n)?Y(n,t):t(n)}const Ue=xn({provide:String,useValue:xn});function jt(e){return null!==e&&"object"==typeof e&&Ue in e}function ts(e){return"function"==typeof e}const yl=new ht(""),ja={},fc={};let cl;function _i(){return void 0===cl&&(cl=new Mr),cl}class cs{}class vs extends cs{parent;source;scopes;records=new Map;_ngOnDestroyHooks=new Set;_onDestroyHooks=[];get destroyed(){return this._destroyed}_destroyed=!1;injectorDefTypes;constructor(t,n,l,p){super(),this.parent=n,this.source=l,this.scopes=p,dl(t,x=>this.processProvider(x)),this.records.set(qr,yi(void 0,this)),p.has("environment")&&this.records.set(cs,yi(void 0,this));const g=this.records.get(yl);null!=g&&"string"==typeof g.value&&this.scopes.add(g.value),this.injectorDefTypes=new Set(this.get(zi,Wn,bi.Self))}destroy(){ul(this),this._destroyed=!0;const t=T(null);try{for(const l of this._ngOnDestroyHooks)l.ngOnDestroy();const n=this._onDestroyHooks;this._onDestroyHooks=[];for(const l of n)l()}finally{this.records.clear(),this._ngOnDestroyHooks.clear(),this.injectorDefTypes.clear(),T(t)}}onDestroy(t){return ul(this),this._onDestroyHooks.push(t),()=>this.removeOnDestroy(t)}runInContext(t){ul(this);const n=Xo(this),l=Oo(void 0);try{return t()}finally{Xo(n),Oo(l)}}get(t,n=Ko,l=bi.Default){if(ul(this),t.hasOwnProperty(Mi))return t[Mi](this);l=As(l);const g=Xo(this),x=Oo(void 0);try{if(!(l&bi.SkipSelf)){let B=this.records.get(t);if(void 0===B){const ie=function tu(e){return"function"==typeof e||"object"==typeof e&&e instanceof ht}(t)&&Jo(t);B=ie&&this.injectableDefInScope(ie)?yi(Va(t),ja):null,this.records.set(t,B)}if(null!=B)return this.hydrate(t,B)}return(l&bi.Self?_i():this.parent).get(t,n=l&bi.Optional&&n===Ko?null:n)}catch(k){if("NullInjectorError"===k.name){if((k[Go]=k[Go]||[]).unshift(Tr(t)),g)throw k;return function ls(e,t,n,l){const p=e[Go];throw t[go]&&p.unshift(t[go]),e.message=function Vi(e,t,n,l=null){e=e&&"\n"===e.charAt(0)&&"\u0275"==e.charAt(1)?e.slice(2):e;let p=Tr(t);if(Array.isArray(t))p=t.map(Tr).join(" -> ");else if("object"==typeof t){let g=[];for(let x in t)if(t.hasOwnProperty(x)){let k=t[x];g.push(x+":"+("string"==typeof k?JSON.stringify(k):Tr(k)))}p=`{${g.join(", ")}}`}return`${n}${l?"("+l+")":""}[${p}]: ${e.replace(Xr,"\n ")}`}("\n"+e.message,p,n,l),e.ngTokenPath=p,e[Go]=null,e}(k,t,"R3InjectorError",this.source)}throw k}finally{Oo(x),Xo(g)}}resolveInjectorInitializers(){const t=T(null),n=Xo(this),l=Oo(void 0);try{const g=this.get(Qn,Wn,bi.Self);for(const x of g)x()}finally{Xo(n),Oo(l),T(t)}}toString(){const t=[],n=this.records;for(const l of n.keys())t.push(Tr(l));return`R3Injector[${t.join(", ")}]`}processProvider(t){let n=ts(t=Ge(t))?t:Ge(t&&t.provide);const l=function Pu(e){return jt(e)?yi(void 0,e.useValue):yi(wl(e),ja)}(t);if(!ts(t)&&!0===t.multi){let p=this.records.get(n);p||(p=yi(void 0,ja,!0),p.factory=()=>Gs(p.multi),this.records.set(n,p)),n=t,p.multi.push(t)}this.records.set(n,l)}hydrate(t,n){const l=T(null);try{return n.value===ja&&(n.value=fc,n.value=n.factory()),"object"==typeof n.value&&n.value&&function eu(e){return null!==e&&"object"==typeof e&&"function"==typeof e.ngOnDestroy}(n.value)&&this._ngOnDestroyHooks.add(n.value),n.value}finally{T(l)}}injectableDefInScope(t){if(!t.providedIn)return!1;const n=Ge(t.providedIn);return"string"==typeof n?"any"===n||this.scopes.has(n):this.injectorDefTypes.has(n)}removeOnDestroy(t){const n=this._onDestroyHooks.indexOf(t);-1!==n&&this._onDestroyHooks.splice(n,1)}}function Va(e){const t=Jo(e),n=null!==t?t.factory:So(e);if(null!==n)return n;if(e instanceof ht)throw new Rn(204,!1);if(e instanceof Function)return function bl(e){if(e.length>0)throw new Rn(204,!1);const n=function ao(e){return e&&(e[Ii]||e[tt])||null}(e);return null!==n?()=>n.factory(e):()=>new e}(e);throw new Rn(204,!1)}function wl(e,t,n){let l;if(ts(e)){const p=Ge(e);return So(p)||Va(p)}if(jt(e))l=()=>Ge(e.useValue);else if(function Jr(e){return!(!e||!e.useFactory)}(e))l=()=>e.useFactory(...Gs(e.deps||[]));else if(function br(e){return!(!e||!e.useExisting)}(e))l=()=>_o(Ge(e.useExisting));else{const p=Ge(e&&(e.useClass||e.provide));if(!function Il(e){return!!e.deps}(e))return So(p)||Va(p);l=()=>new p(...Gs(e.deps))}return l}function ul(e){if(e.destroyed)throw new Rn(205,!1)}function yi(e,t,n=!1){return{factory:e,value:t,multi:n?[]:void 0}}function dl(e,t){for(const n of e)Array.isArray(n)?dl(n,t):n&&jn(n)?dl(n.\u0275providers,t):t(n)}function $s(e,t){e instanceof vs&&ul(e);const l=Xo(e),p=Oo(void 0);try{return t()}finally{Xo(l),Oo(p)}}function Ol(){return void 0!==Ks()||null!=function fs(){return io}()}function Sa(e){if(!Ol())throw new Rn(-203,!1)}const oo=0,Fn=1,Sr=2,Oi=3,ys=4,Qi=5,so=6,Bi=7,Ki=8,no=9,co=10,ri=11,Xs=12,Za=13,Uo=14,vo=15,Ci=16,Vs=17,uo=18,Ui=19,U=20,Ie=21,ne=22,ye=23,Et=24,Gt=25,Un=1,ci=7,Di=9,Rr=10;var li=function(e){return e[e.None=0]="None",e[e.HasTransplantedViews=2]="HasTransplantedViews",e}(li||{});function ii(e){return Array.isArray(e)&&"object"==typeof e[Un]}function wi(e){return Array.isArray(e)&&!0===e[Un]}function bs(e){return!!(4&e.flags)}function Lo(e){return e.componentOffset>-1}function fa(e){return!(1&~e.flags)}function Yo(e){return!!e.template}function Ha(e){return!!(512&e[Sr])}class kc{previousValue;currentValue;firstChange;constructor(t,n,l){this.previousValue=t,this.currentValue=n,this.firstChange=l}isFirstChange(){return this.firstChange}}function Hs(e,t,n,l){null!==t?t.applyValueToInputSignal(t,l):e[n]=l}const zl=(()=>{const e=()=>Wa;return e.ngInherit=!0,e})();function Wa(e){return e.type.prototype.ngOnChanges&&(e.setInput=Gl),Fr}function Fr(){const e=pl(this),t=e?.current;if(t){const n=e.previous;if(n===On)e.previous=t;else for(let l in t)n[l]=t[l];e.current=null,this.ngOnChanges(t)}}function Gl(e,t,n,l,p){const g=this.declaredInputs[l],x=pl(e)||function gd(e,t){return e[Xl]=t}(e,{previous:On,current:null}),k=x.current||(x.current={}),B=x.previous,ie=B[g];k[g]=new kc(ie&&ie.currentValue,n,B===On),Hs(e,t,p,n)}const Xl="__ngSimpleChanges__";function pl(e){return e[Xl]||null}const za=function(e,t,n){},lh="svg";function qi(e){for(;Array.isArray(e);)e=e[oo];return e}function gc(e,t){return qi(t[e])}function rs(e,t){return qi(t[e.index])}function G(e,t){return e.data[t]}function F(e,t){return e[t]}function K(e,t){const n=t[e];return ii(n)?n:n[oo]}function We(e){return!(128&~e[Sr])}function fn(e,t){return null==t?null:e[t]}function on(e){e[Vs]=0}function ur(e){1024&e[Sr]||(e[Sr]|=1024,We(e)&&Is(e))}function kr(e){return!!(9216&e[Sr]||e[Et]?.dirty)}function Gi(e){e[co].changeDetectionScheduler?.notify(9),64&e[Sr]&&(e[Sr]|=1024),kr(e)&&Is(e)}function Is(e){e[co].changeDetectionScheduler?.notify(0);let t=us(e);for(;null!==t&&!(8192&t[Sr])&&(t[Sr]|=8192,We(t));)t=us(t)}function is(e,t){if(!(256&~e[Sr]))throw new Rn(911,!1);null===e[Ie]&&(e[Ie]=[]),e[Ie].push(t)}function us(e){const t=e[Oi];return wi(t)?t[Oi]:t}const Wr={lFrame:nr(null),bindingsEnabled:!0,skipHydrationRootTNode:null};let $u=!1;function hh(){return Wr.bindingsEnabled}function _c(){return null!==Wr.skipHydrationRootTNode}function En(){return Wr.lFrame.lView}function pi(){return Wr.lFrame.tView}function Ic(e){return Wr.lFrame.contextLView=e,e[Ki]}function hu(e){return Wr.lFrame.contextLView=null,e}function Si(){let e=Nl();for(;null!==e&&64===e.type;)e=e.parent;return e}function Nl(){return Wr.lFrame.currentTNode}function Qs(e,t){const n=Wr.lFrame;n.currentTNode=e,n.isParent=t}function Oc(){return Wr.lFrame.isParent}function pa(){Wr.lFrame.isParent=!1}function ma(){return $u}function ql(e){const t=$u;return $u=e,t}function Zs(){const e=Wr.lFrame;let t=e.bindingRootIndex;return-1===t&&(t=e.bindingRootIndex=e.tView.bindingStartIndex),t}function I(){return Wr.lFrame.bindingIndex++}function P(e){const t=Wr.lFrame,n=t.bindingIndex;return t.bindingIndex=t.bindingIndex+e,n}function Ae(e,t){const n=Wr.lFrame;n.bindingIndex=n.bindingRootIndex=e,pt(t)}function pt(e){Wr.lFrame.currentDirectiveIndex=e}function It(e){const t=Wr.lFrame.currentDirectiveIndex;return-1===t?null:e[t]}function zt(){return Wr.lFrame.currentQueryIndex}function ln(e){Wr.lFrame.currentQueryIndex=e}function An(e){const t=e[Fn];return 2===t.type?t.declTNode:1===t.type?e[Qi]:null}function Qt(e,t,n){if(n&bi.SkipSelf){let p=t,g=e;for(;!(p=p.parent,null!==p||n&bi.Host||(p=An(g),null===p||(g=g[Uo],10&p.type))););if(null===p)return!1;t=p,e=g}const l=Wr.lFrame=zn();return l.currentTNode=t,l.lView=e,!0}function Gn(e){const t=zn(),n=e[Fn];Wr.lFrame=t,t.currentTNode=n.firstChild,t.lView=e,t.tView=n,t.contextLView=e,t.bindingIndex=n.bindingStartIndex,t.inI18n=!1}function zn(){const e=Wr.lFrame,t=null===e?null:e.child;return null===t?nr(e):t}function nr(e){const t={currentTNode:null,isParent:!0,lView:null,tView:null,selectedIndex:-1,contextLView:null,elementDepthCount:0,currentNamespace:null,currentDirectiveIndex:-1,bindingRootIndex:-1,bindingIndex:-1,currentQueryIndex:0,parent:e,child:null,inI18n:!1};return null!==e&&(e.child=t),t}function Mn(){const e=Wr.lFrame;return Wr.lFrame=e.parent,e.currentTNode=null,e.lView=null,e}const Hn=Mn;function Xn(){const e=Mn();e.isParent=!0,e.tView=null,e.selectedIndex=-1,e.contextLView=null,e.elementDepthCount=0,e.currentDirectiveIndex=-1,e.currentNamespace=null,e.bindingRootIndex=-1,e.bindingIndex=-1,e.currentQueryIndex=0}function $n(){return Wr.lFrame.selectedIndex}function Ir(e){Wr.lFrame.selectedIndex=e}function ir(){const e=Wr.lFrame;return G(e.tView,e.selectedIndex)}function Cr(){Wr.lFrame.currentNamespace=lh}function Br(){!function ro(){Wr.lFrame.currentNamespace=null}()}let Xi=!0;function bo(){return Xi}function To(e){Xi=e}function _r(e,t){for(let n=t.directiveStart,l=t.directiveEnd;n=l)break}else t[B]<0&&(e[Vs]+=65536),(k>14>16&&(3&e[Sr])===t&&(e[Sr]+=16384,gs(k,g)):gs(k,g)}const Ps=-1;class el{factory;injectImpl;resolving=!1;canSeeViewProviders;multi;componentProviders;index;providerFactory;constructor(t,n,l){this.factory=t,this.canSeeViewProviders=n,this.injectImpl=l}}function Js(e,t,n){let l=0;for(;lt){x=g-1;break}}}for(;g>16}(e),l=t;for(;n>0;)l=l[Uo],n--;return l}let _h=!0;function Ll(e){const t=_h;return _h=e,t}const bd=255,zu=5;let rm=0;const Pl={};function vh(e,t){const n=wd(e,t);if(-1!==n)return n;const l=t[Fn];l.firstCreatePass&&(e.injectorIndex=t.length,Cf(l.data,e),Cf(t,null),Cf(l.blueprint,null));const p=Nc(e,t),g=e.injectorIndex;if(gh(p)){const x=Hu(p),k=Wu(p,t),B=k[Fn].data;for(let ie=0;ie<8;ie++)t[g+ie]=k[x+ie]|B[x+ie]}return t[g+8]=p,g}function Cf(e,t){e.push(0,0,0,0,0,0,0,0,t)}function wd(e,t){return-1===e.injectorIndex||e.parent&&e.parent.injectorIndex===e.injectorIndex||null===t[e.injectorIndex+8]?-1:e.injectorIndex}function Nc(e,t){if(e.parent&&-1!==e.parent.injectorIndex)return e.parent.injectorIndex;let n=0,l=null,p=t;for(;null!==p;){if(l=Gu(p),null===l)return Ps;if(n++,p=p[Uo],-1!==l.injectorIndex)return l.injectorIndex|n<<16}return Ps}function Lc(e,t,n){!function im(e,t,n){let l;"string"==typeof n?l=n.charCodeAt(0)||0:n.hasOwnProperty(ni)&&(l=n[ni]),null==l&&(l=n[ni]=rm++);const p=l&bd;t.data[e+(p>>zu)]|=1<=0?t&bd:Sf:t}(n);if("function"==typeof g){if(!Qt(t,e,l))return l&bi.Host?Ku(p,0,l):Df(t,n,l,p);try{let x;if(x=g(l),null!=x||l&bi.Optional)return x;Li()}finally{Hn()}}else if("number"==typeof g){let x=null,k=wd(e,t),B=Ps,ie=l&bi.Host?t[vo][Qi]:null;for((-1===k||l&bi.SkipSelf)&&(B=-1===k?Nc(e,t):t[k+8],B!==Ps&&wh(l,!1)?(x=t[Fn],k=Hu(B),t=Wu(B,t)):k=-1);-1!==k;){const Se=t[Fn];if(xd(g,k,Se.data)){const He=bh(k,t,n,x,l,ie);if(He!==Pl)return He}B=t[k+8],B!==Ps&&wh(l,t[Fn].data[k+8]===ie)&&xd(g,k,t)?(x=Se,k=Hu(B),t=Wu(B,t)):k=-1}}return p}function bh(e,t,n,l,p,g){const x=t[Fn],k=x.data[e+8],Se=fu(k,x,n,null==l?Lo(k)&&_h:l!=x&&!!(3&k.type),p&bi.Host&&g===k);return null!==Se?Fl(t,x,Se,k):Pl}function fu(e,t,n,l,p){const g=e.providerIndexes,x=t.data,k=1048575&g,B=e.directiveStart,Se=g>>20,Nt=p?k+Se:e.directiveEnd;for(let Ut=l?k:k+Se;Ut=B&&qt.type===n)return Ut}if(p){const Ut=x[B];if(Ut&&Yo(Ut)&&Ut.type===n)return B}return null}function Fl(e,t,n,l){let p=e[n];const g=t.data;if(function Dl(e){return e instanceof el}(p)){const x=p;x.resolving&&function es(e,t){throw t&&t.join(" > "),new Rn(-200,e)}(function Qr(e){return"function"==typeof e?e.name||e.toString():"object"==typeof e&&null!=e&&"function"==typeof e.type?e.type.name||e.type.toString():Or(e)}(g[n]));const k=Ll(x.canSeeViewProviders);x.resolving=!0;const ie=x.injectImpl?Oo(x.injectImpl):null;Qt(e,l,bi.Default);try{p=e[n]=x.factory(void 0,g,e,l),t.firstCreatePass&&n>=l.directiveStart&&function ga(e,t,n){const{ngOnChanges:l,ngOnInit:p,ngDoCheck:g}=t.type.prototype;if(l){const x=Wa(t);(n.preOrderHooks??=[]).push(e,x),(n.preOrderCheckHooks??=[]).push(e,x)}p&&(n.preOrderHooks??=[]).push(0-e,p),g&&((n.preOrderHooks??=[]).push(e,g),(n.preOrderCheckHooks??=[]).push(e,g))}(n,g[n],t)}finally{null!==ie&&Oo(ie),Ll(k),x.resolving=!1,Hn()}}return p}function xd(e,t,n){return!!(n[t+(e>>zu)]&1<{const t=e.prototype.constructor,n=t[gi]||Cd(t),l=Object.prototype;let p=Object.getPrototypeOf(e.prototype).constructor;for(;p&&p!==l;){const g=p[gi]||Cd(p);if(g&&g!==n)return g;p=Object.getPrototypeOf(p)}return g=>new g})}function Cd(e){return Ve(e)?()=>{const t=Cd(Ge(e));return t&&t()}:So(e)}function Gu(e){const t=e[Fn],n=t.type;return 2===n?t.declTNode:1===n?e[Qi]:null}function Xu(e){return function Ed(e,t){if("class"===t)return e.classes;if("style"===t)return e.styles;const n=e.attrs;if(n){const l=n.length;let p=0;for(;p_o(qr)});static __NG_ELEMENT_ID__=-1}class lm{attributeName;constructor(t){this.attributeName=t}__NG_ELEMENT_ID__=()=>Xu(this.attributeName);toString(){return`HostAttributeToken ${this.attributeName}`}}new ht("").__NG_ELEMENT_ID__=e=>{const t=Si();if(null===t)throw new Rn(204,!1);if(2&t.type)return t.value;if(e&bi.Optional)return null;throw new Rn(204,!1)};const Sh=!1;let ws=(()=>class e{static __NG_ELEMENT_ID__=kd;static __NG_ENV_ID__=n=>n})();class Fc extends ws{_lView;constructor(t){super(),this._lView=t}onDestroy(t){return is(this._lView,t),()=>function Oa(e,t){if(null===e[Ie])return;const n=e[Ie].indexOf(t);-1!==n&&e[Ie].splice(n,1)}(this._lView,t)}}function kd(){return new Fc(En())}class rc{}const gu=new ht("",{providedIn:"root",factory:()=>!1}),Od=new ht(""),ic=new ht("");let Ec=(()=>{class e{taskId=0;pendingTasks=new Set;get _hasPendingTasks(){return this.hasPendingTasks.value}hasPendingTasks=new Kt.t(!1);add(){this._hasPendingTasks||this.hasPendingTasks.next(!0);const n=this.taskId++;return this.pendingTasks.add(n),n}has(n){return this.pendingTasks.has(n)}remove(n){this.pendingTasks.delete(n),0===this.pendingTasks.size&&this._hasPendingTasks&&this.hasPendingTasks.next(!1)}ngOnDestroy(){this.pendingTasks.clear(),this._hasPendingTasks&&this.hasPendingTasks.next(!1)}static \u0275prov=ai({token:e,providedIn:"root",factory:()=>new e})}return e})();const oc=class Mh extends rt.B{__isAsync;destroyRef=void 0;pendingTasks=void 0;constructor(t=!1){super(),this.__isAsync=t,Ol()&&(this.destroyRef=lr(ws,{optional:!0})??void 0,this.pendingTasks=lr(Ec,{optional:!0})??void 0)}emit(t){const n=T(null);try{super.next(t)}finally{T(n)}}subscribe(t,n,l){let p=t,g=n||(()=>null),x=l;if(t&&"object"==typeof t){const B=t;p=B.next?.bind(B),g=B.error?.bind(B),x=B.complete?.bind(B)}this.__isAsync&&(g=this.wrapInTimeout(g),p&&(p=this.wrapInTimeout(p)),x&&(x=this.wrapInTimeout(x)));const k=super.subscribe({next:p,error:g,complete:x});return t instanceof Vt.yU&&t.add(k),k}wrapInTimeout(t){return n=>{const l=this.pendingTasks?.add();setTimeout(()=>{t(n),void 0!==l&&this.pendingTasks?.remove(l)})}}};function _u(...e){}function Rd(e){let t,n;function l(){e=_u;try{void 0!==n&&"function"==typeof cancelAnimationFrame&&cancelAnimationFrame(n),void 0!==t&&clearTimeout(t)}catch{}}return t=setTimeout(()=>{e(),l()}),"function"==typeof requestAnimationFrame&&(n=requestAnimationFrame(()=>{e(),l()})),()=>l()}function cm(e){return queueMicrotask(()=>e()),()=>{e=_u}}const xc="isAngularZone",Zu=xc+"_ID";let kh=0;class os{hasPendingMacrotasks=!1;hasPendingMicrotasks=!1;isStable=!0;onUnstable=new oc(!1);onMicrotaskEmpty=new oc(!1);onStable=new oc(!1);onError=new oc(!1);constructor(t){const{enableLongStackTrace:n=!1,shouldCoalesceEventChangeDetection:l=!1,shouldCoalesceRunChangeDetection:p=!1,scheduleInRootZone:g=Sh}=t;if(typeof Zone>"u")throw new Rn(908,!1);Zone.assertZonePatched();const x=this;x._nesting=0,x._outer=x._inner=Zone.current,Zone.TaskTrackingZoneSpec&&(x._inner=x._inner.fork(new Zone.TaskTrackingZoneSpec)),n&&Zone.longStackTraceZoneSpec&&(x._inner=x._inner.fork(Zone.longStackTraceZoneSpec)),x.shouldCoalesceEventChangeDetection=!p&&l,x.shouldCoalesceRunChangeDetection=p,x.callbackScheduled=!1,x.scheduleInRootZone=g,function Rf(e){const t=()=>{!function um(e){function t(){Rd(()=>{e.callbackScheduled=!1,Oh(e),e.isCheckStableRunning=!0,Ih(e),e.isCheckStableRunning=!1})}e.isCheckStableRunning||e.callbackScheduled||(e.callbackScheduled=!0,e.scheduleInRootZone?Zone.root.run(()=>{t()}):e._outer.run(()=>{t()}),Oh(e))}(e)},n=kh++;e._inner=e._inner.fork({name:"angular",properties:{[xc]:!0,[Zu]:n,[Zu+n]:!0},onInvokeTask:(l,p,g,x,k,B)=>{if(function dm(e){return Lf(e,"__ignore_ng_zone__")}(B))return l.invokeTask(g,x,k,B);try{return Nf(e),l.invokeTask(g,x,k,B)}finally{(e.shouldCoalesceEventChangeDetection&&"eventTask"===x.type||e.shouldCoalesceRunChangeDetection)&&t(),vu(e)}},onInvoke:(l,p,g,x,k,B,ie)=>{try{return Nf(e),l.invoke(g,x,k,B,ie)}finally{e.shouldCoalesceRunChangeDetection&&!e.callbackScheduled&&!function Fg(e){return Lf(e,"__scheduler_tick__")}(B)&&t(),vu(e)}},onHasTask:(l,p,g,x)=>{l.hasTask(g,x),p===g&&("microTask"==x.change?(e._hasPendingMicrotasks=x.microTask,Oh(e),Ih(e)):"macroTask"==x.change&&(e.hasPendingMacrotasks=x.macroTask))},onHandleError:(l,p,g,x)=>(l.handleError(g,x),e.runOutsideAngular(()=>e.onError.emit(x)),!1)})}(x)}static isInAngularZone(){return typeof Zone<"u"&&!0===Zone.current.get(xc)}static assertInAngularZone(){if(!os.isInAngularZone())throw new Rn(909,!1)}static assertNotInAngularZone(){if(os.isInAngularZone())throw new Rn(909,!1)}run(t,n,l){return this._inner.run(t,n,l)}runTask(t,n,l,p){const g=this._inner,x=g.scheduleEventTask("NgZoneEvent: "+p,t,Of,_u,_u);try{return g.runTask(x,n,l)}finally{g.cancelTask(x)}}runGuarded(t,n,l){return this._inner.runGuarded(t,n,l)}runOutsideAngular(t){return this._outer.run(t)}}const Of={};function Ih(e){if(0==e._nesting&&!e.hasPendingMicrotasks&&!e.isStable)try{e._nesting++,e.onMicrotaskEmpty.emit(null)}finally{if(e._nesting--,!e.hasPendingMicrotasks)try{e.runOutsideAngular(()=>e.onStable.emit(null))}finally{e.isStable=!0}}}function Oh(e){e.hasPendingMicrotasks=!!(e._hasPendingMicrotasks||(e.shouldCoalesceEventChangeDetection||e.shouldCoalesceRunChangeDetection)&&!0===e.callbackScheduled)}function Nf(e){e._nesting++,e.isStable&&(e.isStable=!1,e.onUnstable.emit(null))}function vu(e){e._nesting--,Ih(e)}class Rh{hasPendingMicrotasks=!1;hasPendingMacrotasks=!1;isStable=!0;onUnstable=new oc;onMicrotaskEmpty=new oc;onStable=new oc;onError=new oc;run(t,n,l){return t.apply(n,l)}runGuarded(t,n,l){return t.apply(n,l)}runOutsideAngular(t){return t()}runTask(t,n,l,p){return t.apply(n,l)}}function Lf(e,t){return!(!Array.isArray(e)||1!==e.length)&&!0===e[0]?.data?.[t]}class Cc{_console=console;handleError(t){this._console.error("ERROR",t)}}const qu=new ht("",{providedIn:"root",factory:()=>{const e=lr(os),t=lr(Cc);return n=>e.runOutsideAngular(()=>t.handleError(n))}});function Pf(e,t){return z(e,t)}const $g=(Pf.required=function bu(e){return z(cn,e)},Pf);function wu(){return Dc(Si(),En())}function Dc(e,t){return new Os(rs(e,t))}let Os=(()=>class e{nativeElement;constructor(n){this.nativeElement=n}static __NG_ELEMENT_ID__=wu})();function Nh(e){return e instanceof Os?e.nativeElement:e}function Nd(){return this._results[Symbol.iterator]()}class Ff{_emitDistinctChangesOnly;dirty=!0;_onDirty=void 0;_results=[];_changesDetected=!1;_changes=void 0;length=0;first=void 0;last=void 0;get changes(){return this._changes??=new rt.B}constructor(t=!1){this._emitDistinctChangesOnly=t}get(t){return this._results[t]}map(t){return this._results.map(t)}filter(t){return this._results.filter(t)}find(t){return this._results.find(t)}reduce(t,n){return this._results.reduce(t,n)}forEach(t){this._results.forEach(t)}some(t){return this._results.some(t)}toArray(){return this._results.slice()}toString(){return this._results.toString()}reset(t,n){this.dirty=!1;const l=function lo(e){return e.flat(Number.POSITIVE_INFINITY)}(t);(this._changesDetected=!function Bo(e,t,n){if(e.length!==t.length)return!1;for(let l=0;lYh}),Yh="ng",sd=new ht(""),b=new ht("",{providedIn:"platform",factory:()=>"unknown"}),A=new ht(""),j=new ht("",{providedIn:"root",factory:()=>nl().body?.querySelector("[ngCspNonce]")?.getAttribute("ngCspNonce")||null}),to=new ht("",{providedIn:"root",factory:()=>!1}),yr=new Set;function oi(e){yr.has(e)||(yr.add(e),performance?.mark?.("mark_feature_usage",{detail:{feature:e}}))}var Wi=function(e){return e[e.EarlyRead=0]="EarlyRead",e[e.Write=1]="Write",e[e.MixedReadWrite=2]="MixedReadWrite",e[e.Read=3]="Read",e}(Wi||{});let Bs=(()=>{class e{impl=null;execute(){this.impl?.execute()}static \u0275prov=ai({token:e,providedIn:"root",factory:()=>new e})}return e})();const Na=[Wi.EarlyRead,Wi.Write,Wi.MixedReadWrite,Wi.Read];let rl=(()=>{class e{ngZone=lr(os);scheduler=lr(rc);errorHandler=lr(Cc,{optional:!0});sequences=new Set;deferredRegistrations=new Set;executing=!1;execute(){this.executing=!0;for(const n of Na)for(const l of this.sequences)if(!l.erroredOrDestroyed&&l.hooks[n])try{l.pipelinedValue=this.ngZone.runOutsideAngular(()=>l.hooks[n](l.pipelinedValue))}catch(p){l.erroredOrDestroyed=!0,this.errorHandler?.handleError(p)}this.executing=!1;for(const n of this.sequences)n.afterRun(),n.once&&(this.sequences.delete(n),n.destroy());for(const n of this.deferredRegistrations)this.sequences.add(n);this.deferredRegistrations.size>0&&this.scheduler.notify(8),this.deferredRegistrations.clear()}register(n){this.executing?this.deferredRegistrations.add(n):(this.sequences.add(n),this.scheduler.notify(7))}unregister(n){this.executing&&this.sequences.has(n)?(n.erroredOrDestroyed=!0,n.pipelinedValue=void 0,n.once=!0):(this.sequences.delete(n),this.deferredRegistrations.delete(n))}static \u0275prov=ai({token:e,providedIn:"root",factory:()=>new e})}return e})();class gl{impl;hooks;once;erroredOrDestroyed=!1;pipelinedValue=void 0;unregisterOnDestroy;constructor(t,n,l,p){this.impl=t,this.hooks=n,this.once=l,this.unregisterOnDestroy=p?.onDestroy(()=>this.destroy())}afterRun(){this.erroredOrDestroyed=!1,this.pipelinedValue=void 0}destroy(){this.impl.unregister(this),this.unregisterOnDestroy?.()}}function ba(e,t){!t?.injector&&Sa();const n=t?.injector??lr(Qo);return typeof ngServerMode<"u"&&ngServerMode?$d:(oi("NgAfterRender"),Vc(e,n,t,!1))}function Xa(e,t){!t?.injector&&Sa();const n=t?.injector??lr(Qo);return typeof ngServerMode<"u"&&ngServerMode?$d:(oi("NgAfterNextRender"),Vc(e,n,t,!0))}function Vc(e,t,n,l){const p=t.get(Bs);p.impl??=t.get(rl);const g=n?.phase??Wi.MixedReadWrite,x=!0!==n?.manualCleanup?t.get(ws):null,k=new gl(p.impl,function wa(e,t){if(e instanceof Function){const n=[void 0,void 0,void 0,void 0];return n[t]=e,n}return[e.earlyRead,e.write,e.mixedReadWrite,e.read]}(e,g),l,x);return p.impl.register(k),k}const $d={destroy(){}};let Jg=()=>null;function ip(e,t,n=!1){return Jg(e,t,n)}var Sc=function(e){return e[e.Emulated=0]="Emulated",e[e.None=2]="None",e[e.ShadowDom=3]="ShadowDom",e}(Sc||{});let ld,ap;function Kd(e){return function Tm(){if(void 0===ld&&(ld=null,dn.trustedTypes))try{ld=dn.trustedTypes.createPolicy("angular",{createHTML:e=>e,createScript:e=>e,createScriptURL:e=>e})}catch{}return ld}()?.createHTML(e)||e}function Mm(){if(void 0===ap&&(ap=null,dn.trustedTypes))try{ap=dn.trustedTypes.createPolicy("angular#unsafe-bypass",{createHTML:e=>e,createScript:e=>e,createScriptURL:e=>e})}catch{}return ap}function l_(e){return Mm()?.createHTML(e)||e}function u_(e){return Mm()?.createScriptURL(e)||e}class cd{changingThisBreaksApplicationSecurity;constructor(t){this.changingThisBreaksApplicationSecurity=t}toString(){return`SafeValue must use [property]=binding: ${this.changingThisBreaksApplicationSecurity} (see ${Nr})`}}class Ry extends cd{getTypeName(){return"HTML"}}class Ny extends cd{getTypeName(){return"Style"}}class lp extends cd{getTypeName(){return"Script"}}class Ly extends cd{getTypeName(){return"URL"}}class Py extends cd{getTypeName(){return"ResourceURL"}}function Gc(e){return e instanceof cd?e.changingThisBreaksApplicationSecurity:e}function Gd(e,t){const n=function Fy(e){return e instanceof cd&&e.getTypeName()||null}(e);if(null!=n&&n!==t){if("ResourceURL"===n&&"URL"===t)return!0;throw new Error(`Required a safe ${t}, got a ${n} (see ${Nr})`)}return n===t}function By(e){return new Ry(e)}function Uy(e){return new Ny(e)}function $y(e){return new lp(e)}function jy(e){return new Ly(e)}function Vy(e){return new Py(e)}class km{inertDocumentHelper;constructor(t){this.inertDocumentHelper=t}getInertBodyElement(t){t=""+t;try{const n=(new window.DOMParser).parseFromString(Kd(t),"text/html").body;return null===n?this.inertDocumentHelper.getInertBodyElement(t):(n.firstChild?.remove(),n)}catch{return null}}}class Hy{defaultDoc;inertDocument;constructor(t){this.defaultDoc=t,this.inertDocument=this.defaultDoc.implementation.createHTMLDocument("sanitization-inert")}getInertBodyElement(t){const n=this.inertDocument.createElement("template");return n.innerHTML=Kd(t),n}}const Im=/^(?!javascript:)(?:[a-z0-9+.-]+:|[^&:\/?#]*(?:[\/?#]|$))/i;function cp(e){return(e=String(e)).match(Im)?e:"unsafe:"+e}function Xc(e){const t={};for(const n of e.split(","))t[n]=!0;return t}function sf(...e){const t={};for(const n of e)for(const l in n)n.hasOwnProperty(l)&&(t[l]=!0);return t}const h_=Xc("area,br,col,hr,img,wbr"),f_=Xc("colgroup,dd,dt,li,p,tbody,td,tfoot,th,thead,tr"),p_=Xc("rp,rt"),Om=sf(h_,sf(f_,Xc("address,article,aside,blockquote,caption,center,del,details,dialog,dir,div,dl,figure,figcaption,footer,h1,h2,h3,h4,h5,h6,header,hgroup,hr,ins,main,map,menu,nav,ol,pre,section,summary,table,ul")),sf(p_,Xc("a,abbr,acronym,audio,b,bdi,bdo,big,br,cite,code,del,dfn,em,font,i,img,ins,kbd,label,map,mark,picture,q,ruby,rp,rt,s,samp,small,source,span,strike,strong,sub,sup,time,track,tt,u,var,video")),sf(p_,f_)),up=Xc("background,cite,href,itemtype,longdesc,poster,src,xlink:href"),g_=sf(up,Xc("abbr,accesskey,align,alt,autoplay,axis,bgcolor,border,cellpadding,cellspacing,class,clear,color,cols,colspan,compact,controls,coords,datetime,default,dir,download,face,headers,height,hidden,hreflang,hspace,ismap,itemscope,itemprop,kind,label,lang,language,loop,media,muted,nohref,nowrap,open,preload,rel,rev,role,rows,rowspan,rules,scope,scrolling,shape,size,sizes,span,srclang,srcset,start,summary,tabindex,target,title,translate,type,usemap,valign,value,vspace,width"),Xc("aria-activedescendant,aria-atomic,aria-autocomplete,aria-busy,aria-checked,aria-colcount,aria-colindex,aria-colspan,aria-controls,aria-current,aria-describedby,aria-details,aria-disabled,aria-dropeffect,aria-errormessage,aria-expanded,aria-flowto,aria-grabbed,aria-haspopup,aria-hidden,aria-invalid,aria-keyshortcuts,aria-label,aria-labelledby,aria-level,aria-live,aria-modal,aria-multiline,aria-multiselectable,aria-orientation,aria-owns,aria-placeholder,aria-posinset,aria-pressed,aria-readonly,aria-relevant,aria-required,aria-roledescription,aria-rowcount,aria-rowindex,aria-rowspan,aria-selected,aria-setsize,aria-sort,aria-valuemax,aria-valuemin,aria-valuenow,aria-valuetext")),Ky=Xc("script,style,template");class Gy{sanitizedSomething=!1;buf=[];sanitizeChildren(t){let n=t.firstChild,l=!0,p=[];for(;n;)if(n.nodeType===Node.ELEMENT_NODE?l=this.startElement(n):n.nodeType===Node.TEXT_NODE?this.chars(n.nodeValue):this.sanitizedSomething=!0,l&&n.firstChild)p.push(n),n=Yy(n);else for(;n;){n.nodeType===Node.ELEMENT_NODE&&this.endElement(n);let g=Xy(n);if(g){n=g;break}n=p.pop()}return this.buf.join("")}startElement(t){const n=v_(t).toLowerCase();if(!Om.hasOwnProperty(n))return this.sanitizedSomething=!0,!Ky.hasOwnProperty(n);this.buf.push("<"),this.buf.push(n);const l=t.attributes;for(let p=0;p"),!0}endElement(t){const n=v_(t).toLowerCase();Om.hasOwnProperty(n)&&!h_.hasOwnProperty(n)&&(this.buf.push(""))}chars(t){this.buf.push(Nm(t))}}function Xy(e){const t=e.nextSibling;if(t&&e!==t.previousSibling)throw Rm(t);return t}function Yy(e){const t=e.firstChild;if(t&&function __(e,t){return(e.compareDocumentPosition(t)&Node.DOCUMENT_POSITION_CONTAINED_BY)!==Node.DOCUMENT_POSITION_CONTAINED_BY}(e,t))throw Rm(t);return t}function v_(e){const t=e.nodeName;return"string"==typeof t?t:"FORM"}function Rm(e){return new Error(`Failed to sanitize html because the element is clobbered: ${e.outerHTML}`)}const Qy=/[\uD800-\uDBFF][\uDC00-\uDFFF]/g,Zy=/([^\#-~ |!])/g;function Nm(e){return e.replace(/&/g,"&").replace(Qy,function(t){return"&#"+(1024*(t.charCodeAt(0)-55296)+(t.charCodeAt(1)-56320)+65536)+";"}).replace(Zy,function(t){return"&#"+t.charCodeAt(0)+";"}).replace(//g,">")}let dp;function Lm(e,t){let n=null;try{dp=dp||function d_(e){const t=new Hy(e);return function Wy(){try{return!!(new window.DOMParser).parseFromString(Kd(""),"text/html")}catch{return!1}}()?new km(t):t}(e);let l=t?String(t):"";n=dp.getInertBodyElement(l);let p=5,g=l;do{if(0===p)throw new Error("Failed to sanitize html because the input is unstable");p--,l=g,g=n.innerHTML,n=dp.getInertBodyElement(l)}while(l!==g);return Kd((new Gy).sanitizeChildren(Pm(n)||n))}finally{if(n){const l=Pm(n)||n;for(;l.firstChild;)l.firstChild.remove()}}}function Pm(e){return"content"in e&&function qy(e){return e.nodeType===Node.ELEMENT_NODE&&"TEMPLATE"===e.nodeName}(e)?e.content:null}var ud=function(e){return e[e.NONE=0]="NONE",e[e.HTML=1]="HTML",e[e.STYLE=2]="STYLE",e[e.SCRIPT=3]="SCRIPT",e[e.URL=4]="URL",e[e.RESOURCE_URL=5]="RESOURCE_URL",e}(ud||{});function y_(e){const t=dd();return t?l_(t.sanitize(ud.HTML,e)||""):Gd(e,"HTML")?l_(Gc(e)):Lm(nl(),Or(e))}function Xd(e){const t=dd();return t?t.sanitize(ud.URL,e)||"":Gd(e,"URL")?Gc(e):cp(Or(e))}function Fm(e){const t=dd();if(t)return u_(t.sanitize(ud.RESOURCE_URL,e)||"");if(Gd(e,"ResourceURL"))return u_(Gc(e));throw new Rn(904,!1)}function b_(e,t,n){return function $m(e,t){return"src"===t&&("embed"===e||"frame"===e||"iframe"===e||"media"===e||"script"===e)||"href"===t&&("base"===e||"link"===e)?Fm:Xd}(t,n)(e)}function dd(){const e=En();return e&&e[co].sanitizer}const E_=/^>|^->||--!>|)/g,x_="\u200b$1\u200b";function Al(e){return e instanceof Function?e():e}var ku=function(e){return e[e.None=0]="None",e[e.SignalBased=1]="SignalBased",e[e.HasDecoratorInputTransform=2]="HasDecoratorInputTransform",e}(ku||{}),mp=function(e){return e[e.Important=1]="Important",e[e.DashCase=2]="DashCase",e}(mp||{});let Hm;function Wm(e,t){return Hm(e,t)}function Zd(e,t,n,l,p){if(null!=l){let g,x=!1;wi(l)?g=l:ii(l)&&(x=!0,l=l[oo]);const k=qi(l);0===e&&null!==n?null==p?z_(t,n,k):hd(t,n,k,p||null,!0):1===e&&null!==n?hd(t,n,k,p||null,!0):2===e?function cf(e,t,n){e.removeChild(null,t,n)}(t,k,x):3===e&&t.destroyNode(k),null!=g&&function J_(e,t,n,l,p){const g=n[ci];g!==qi(n)&&Zd(t,e,l,g,p);for(let k=Rr;kt.replace(Yd,x_))}(t))}function gp(e,t,n){return e.createElement(t,n)}function j_(e,t){t[co].changeDetectionScheduler?.notify(10),Ep(e,t,t[ri],2,null,null)}function V_(e,t){const n=e[Di],l=t[Oi];(ii(l)||t[vo]!==l[Oi][vo])&&(e[Sr]|=li.HasTransplantedViews),null===n?e[Di]=[t]:n.push(t)}function _p(e,t){const n=e[Di],l=n.indexOf(t);n.splice(l,1)}function af(e,t){if(e.length<=Rr)return;const n=Rr+t,l=e[n];if(l){const p=l[Ci];null!==p&&p!==e&&_p(p,l),t>0&&(e[n-1][ys]=l[ys]);const g=Ms(e,Rr+t);!function $_(e,t){j_(e,t),t[oo]=null,t[Qi]=null}(l[Fn],l);const x=g[uo];null!==x&&x.detachView(g[Fn]),l[Oi]=null,l[ys]=null,l[Sr]&=-129}return l}function lf(e,t){if(!(256&t[Sr])){const n=t[ri];n.destroyNode&&Ep(e,t,n,3,null,null),function ob(e){let t=e[Xs];if(!t)return Gm(e[Fn],e);for(;t;){let n=null;if(ii(t))n=t[Xs];else{const l=t[Rr];l&&(n=l)}if(!n){for(;t&&!t[ys]&&t!==e;)ii(t)&&Gm(t[Fn],t),t=t[Oi];null===t&&(t=e),ii(t)&&Gm(t[Fn],t),n=t&&t[ys]}t=n}}(t)}}function Gm(e,t){if(256&t[Sr])return;const n=T(null);try{t[Sr]&=-129,t[Sr]|=256,t[Et]&&De(t[Et]),function vp(e,t){let n;if(null!=e&&null!=(n=e.destroyHooks))for(let l=0;l=0?l[k]():l[-k].unsubscribe(),x+=2}else n[x].call(l[n[x+1]]);null!==l&&(t[Bi]=null);const p=t[Ie];if(null!==p){t[Ie]=null;for(let x=0;x-1){const{encapsulation:g}=e.data[l.directiveStart+p];if(g===Sc.None||g===Sc.Emulated)return null}return rs(l,n)}}(e,t.parent,n)}function hd(e,t,n,l,p){e.insertBefore(t,n,l,p)}function z_(e,t,n){e.appendChild(t,n)}function K_(e,t,n,l,p){null!==l?hd(e,t,n,l,p):z_(e,t,n)}function Xm(e,t){return e.parentNode(t)}function Ym(e,t,n){return X_(e,t,n)}let Qm,X_=function G_(e,t,n){return 40&e.type?rs(e,n):null};function bp(e,t,n,l){const p=yp(e,l,t),g=t[ri],k=Ym(l.parent||t[Qi],l,t);if(null!=p)if(Array.isArray(n))for(let B=0;B-1){let g;for(;++pg?"":p[Se+1].toLowerCase(),2&l&&ie!==He){if(uc(l))return!1;x=!0}}}}else{if(!x&&!uc(l)&&!uc(B))return!1;if(x&&uc(B))continue;x=!1,l=B|1&l}}return uc(l)||x}function uc(e){return!(1&e)}function mb(e,t,n,l){if(null===t)return-1;let p=0;if(l||!n){let g=!1;for(;p-1)for(n++;n0?'="'+k+'"':"")+"]"}else 8&l?p+="."+x:4&l&&(p+=" "+x);else""!==p&&!uc(x)&&(t+=uf(g,p),p=""),l=x,g=g||!uc(l);n++}return""!==p&&(t+=uf(g,p)),t}const $i={};function xp(e=1){Eb(pi(),En(),$n()+e,!1)}function Eb(e,t,n,l){if(!l)if(3&~t[Sr]){const g=e.preOrderHooks;null!==g&&Hi(t,g,0,n)}else{const g=e.preOrderCheckHooks;null!==g&&jr(t,g,n)}Ir(n)}function qd(e,t=bi.Default){const n=En();return null===n?_o(e,t):yh(Si(),n,Ge(e),t)}function iv(){throw new Error("invalid")}function Jm(e,t,n,l,p,g){const x=T(null);try{let k=null;p&ku.SignalBased&&(k=t[l][C]),null!==k&&void 0!==k.transformFn&&(g=k.transformFn(g)),p&ku.HasDecoratorInputTransform&&(g=e.inputTransforms[l].call(t,g)),null!==e.setInput?e.setInput(t,k,g,n,l):Hs(t,k,l,g)}finally{T(x)}}function df(e,t,n,l,p,g,x,k,B,ie,Se){const He=t.blueprint.slice();return He[oo]=p,He[Sr]=1228|l,(null!==ie||e&&2048&e[Sr])&&(He[Sr]|=2048),on(He),He[Oi]=He[Uo]=e,He[Ki]=n,He[co]=x||e&&e[co],He[ri]=k||e&&e[ri],He[no]=B||e&&e[no]||null,He[Qi]=g,He[Ui]=function Bf(){return xu++}(),He[so]=Se,He[U]=ie,He[vo]=2==t.type?e[vo]:He,He}function fd(e,t,n,l,p){let g=e.data[t];if(null===g)g=function eg(e,t,n,l,p){const g=Nl(),x=Oc(),B=e.data[t]=function er(e,t,n,l,p,g){let x=t?t.injectorIndex:-1,k=0;return _c()&&(k|=128),{type:n,index:l,insertBeforeIndex:null,injectorIndex:x,directiveStart:-1,directiveEnd:-1,directiveStylingLast:-1,componentOffset:-1,propertyBindings:null,flags:k,providerIndexes:0,value:p,attrs:g,mergedAttrs:null,localNames:null,initialInputs:void 0,inputs:null,outputs:null,tView:null,next:null,prev:null,projectionNext:null,child:null,parent:t,projection:null,styles:null,stylesWithoutHost:null,residualStyles:void 0,classes:null,classesWithoutHost:null,residualClasses:void 0,classBindings:0,styleBindings:0}}(0,x?g:g&&g.parent,n,t,l,p);return null===e.firstChild&&(e.firstChild=B),null!==g&&(x?null==g.child&&null!==B.parent&&(g.child=B):null===g.next&&(g.next=B,B.prev=g)),B}(e,t,n,l,p),function $(){return Wr.lFrame.inI18n}()&&(g.flags|=32);else if(64&g.type){g.type=n,g.value=l,g.attrs=p;const x=function Ra(){const e=Wr.lFrame,t=e.currentTNode;return e.isParent?t:t.parent}();g.injectorIndex=null===x?-1:x.injectorIndex}return Qs(g,!0),g}function hf(e,t,n,l){if(0===n)return-1;const p=t.length;for(let g=0;gGt&&Eb(e,t,Gt,!1),za(x?2:0,p),n(l,p)}finally{Ir(g),za(x?3:1,p)}}function m(e,t,n){if(bs(t)){const l=T(null);try{const g=t.directiveEnd;for(let x=t.directiveStart;xnull;function fr(e,t,n,l,p){for(let g in t){if(!t.hasOwnProperty(g))continue;const x=t[g];if(void 0===x)continue;l??={};let k,B=ku.None;Array.isArray(x)?(k=x[0],B=x[1]):k=x;let ie=g;if(null!==p){if(!p.hasOwnProperty(g))continue;ie=p[g]}0===e?ti(l,n,ie,k,B):ti(l,n,ie,k)}return l}function ti(e,t,n,l,p){let g;e.hasOwnProperty(n)?(g=e[n]).push(t,l):g=e[n]=[t,l],void 0!==p&&g.push(p)}function ho(e,t,n,l,p,g,x,k){const B=rs(t,n);let Se,ie=t.inputs;!k&&null!=ie&&(Se=ie[l])?(Cb(e,n,Se,l,p),Lo(t)&&function Ea(e,t){const n=K(t,e);16&n[Sr]||(n[Sr]|=64)}(n,t.index)):3&t.type&&(l=function ko(e){return"class"===e?"className":"for"===e?"htmlFor":"formaction"===e?"formAction":"innerHtml"===e?"innerHTML":"readonly"===e?"readOnly":"tabindex"===e?"tabIndex":e}(l),p=null!=x?x(p,t.value||"",l):p,g.setProperty(B,l,p))}function vl(e,t,n,l){if(hh()){const p=null===l?null:{"":-1},g=function tg(e,t){const n=e.directiveRegistry;let l=null,p=null;if(n)for(let g=0;g0;){const n=e[--t];if("number"==typeof n&&n<0)return n}return 0})(x)!=k&&x.push(k),x.push(n,l,g)}}(e,t,l,hf(e,n,p.hostVars,$i),p)}function xo(e){let t=16;return e.signals?t=4096:e.onPush&&(t=64),t}function na(e,t,n,l,p,g){const x=rs(e,t);!function sl(e,t,n,l,p,g,x){if(null==g)e.removeAttribute(t,p,n);else{const k=null==x?Or(g):x(g,l||"",p);e.setAttribute(t,p,k,n)}}(t[ri],x,g,e.value,n,l,p)}function Ru(e,t,n,l,p,g){const x=g[t];if(null!==x)for(let k=0;k0&&(n[p-1][ys]=t),l{Is(e.lView)},consumerOnSignalRead(){this.lView[Et]=this}},xD={...L,consumerIsAlwaysLive:!0,consumerMarkedDirty:e=>{let t=us(e.lView);for(;t&&!e1(t[Fn]);)t=us(t);t&&ur(t)},consumerOnSignalRead(){this.lView[Et]=this}};function e1(e){return 2!==e.type}function t1(e){if(null===e[ye])return;let t=!0;for(;t;){let n=!1;for(const l of e[ye])l.dirty&&(n=!0,null===l.zone||Zone.current===l.zone?l.run():l.zone.run(()=>l.run()));t=n&&!!(8192&e[Sr])}}const CD=100;function cv(e,t=!0,n=0){const p=e[co].rendererFactory;p.begin?.();try{!function DD(e,t){const n=ma();try{ql(!0),Sb(e,t);let l=0;for(;kr(e);){if(l===CD)throw new Rn(103,!1);l++,Sb(e,1)}}finally{ql(n)}}(e,n)}catch(x){throw t&&av(e,x),x}finally{p.end?.()}}function r1(e,t,n,l){const p=t[Sr];if(!(256&~p))return;Gn(t);let k=!0,B=null,ie=null;e1(e)?(ie=function vD(e){return e[Et]??function yD(e){const t=Jw.pop()??Object.create(wD);return t.lView=e,t}(e)}(t),B=be(ie)):null===function S(){return c}()?(k=!1,ie=function ED(e){const t=e[Et]??Object.create(xD);return t.lView=e,t}(t),B=be(ie)):t[Et]&&(De(t[Et]),t[Et]=null);try{on(t),function yd(e){return Wr.lFrame.bindingIndex=e}(e.bindingStartIndex),null!==n&&v(e,t,n,2,l);const Se=!(3&~p);if(Se){const Ut=e.preOrderCheckHooks;null!==Ut&&jr(t,Ut,null)}else{const Ut=e.preOrderHooks;null!==Ut&&Hi(t,Ut,0,null),Yi(t,0)}if(function AD(e){for(let t=lc(e);null!==t;t=Vh(t)){if(!(t[Sr]&li.HasTransplantedViews))continue;const n=t[Di];for(let l=0;l-1&&(af(t,l),Ms(n,l))}this._attachedToViewContainer=!1}lf(this._lView[Fn],this._lView)}onDestroy(t){is(this._lView,t)}markForCheck(){ig(this._cdRefInjectingView||this._lView,4)}markForRefresh(){ur(this._cdRefInjectingView||this._lView)}detach(){this._lView[Sr]&=-129}reattach(){Gi(this._lView),this._lView[Sr]|=128}detectChanges(){this._lView[Sr]|=1024,cv(this._lView,this.notifyErrorHandler)}checkNoChanges(){}attachToViewContainerRef(){if(this._appRef)throw new Rn(902,!1);this._attachedToViewContainer=!0}detachFromAppRef(){this._appRef=null;const t=Ha(this._lView),n=this._lView[Ci];null!==n&&!t&&_p(n,this._lView),j_(this._lView[Fn],this._lView)}attachToAppRef(t){if(this._attachedToViewContainer)throw new Rn(902,!1);this._appRef=t;const n=Ha(this._lView),l=this._lView[Ci];null!==l&&!n&&V_(l,this._lView),Gi(this._lView)}}let sg=(()=>class e{static __NG_ELEMENT_ID__=kD})();const TD=sg,MD=class extends TD{_declarationLView;_declarationTContainer;elementRef;constructor(t,n,l){super(),this._declarationLView=t,this._declarationTContainer=n,this.elementRef=l}get ssrId(){return this._declarationTContainer.tView?.ssrId||null}createEmbeddedView(t,n){return this.createEmbeddedViewImpl(t,n)}createEmbeddedViewImpl(t,n,l){const p=Ap(this._declarationLView,this._declarationTContainer,t,{embeddedViewInjector:n,dehydratedView:l});return new og(p)}};function kD(){return uv(Si(),En())}function uv(e,t){return 4&e.type?new MD(t,e,Dc(e,t)):null}class UD{resolveComponentFactory(t){throw Error(`No component factory found for ${Tr(t)}.`)}}class hv{static NULL=new UD}class gf{}class c1{}class $D{}class u1{}class Ib{}let jD=(()=>class e{destroyNode=null;static __NG_ELEMENT_ID__=()=>function VD(){const e=En(),n=K(Si().index,e);return(ii(n)?n:e)[ri]}()})(),HD=(()=>{class e{static \u0275prov=ai({token:e,providedIn:"root",factory:()=>null})}return e})();function Jd(e){return!!fi(e)}function pv(e,t,n){let l=n?e.styles:null,p=n?e.classes:null,g=0;if(null!==t)for(let x=0;x0&&ev(e,n,g.join(" "))}}(Nt,ia,qt,l),void 0!==n&&function JD(e,t,n){const l=e.projection=[];for(let p=0;pn()),this.destroyCbs=null}onDestroy(t){this.destroyCbs.push(t)}}class Lb extends c1{moduleType;constructor(t){super(),this.moduleType=t}create(t){return new Nb(this.moduleType,t,[])}}class m1 extends gf{injector;componentFactoryResolver=new f1(this);instance=null;constructor(t){super();const n=new vs([...t.providers,{provide:gf,useValue:this},{provide:hv,useValue:this.componentFactoryResolver}],t.parent||_i(),t.debugName,new Set(["environment"]));this.injector=n,t.runEnvironmentInitializers&&n.resolveInjectorInitializers()}destroy(){this.injector.destroy()}onDestroy(t){this.injector.onDestroy(t)}}function Pb(e,t,n=null){return new m1({providers:e,parent:t,debugName:n,runEnvironmentInitializers:!0}).injector}let rA=(()=>{class e{_injector;cachedInjectors=new Map;constructor(n){this._injector=n}getOrCreateStandaloneInjector(n){if(!n.standalone)return null;if(!this.cachedInjectors.has(n)){const l=$a(0,n.type),p=l.length>0?Pb([l],this._injector,`Standalone[${n.type.name}]`):null;this.cachedInjectors.set(n,p)}return this.cachedInjectors.get(n)}ngOnDestroy(){try{for(const n of this.cachedInjectors.values())null!==n&&n.destroy()}finally{this.cachedInjectors.clear()}}static \u0275prov=ai({token:e,providedIn:"environment",factory:()=>new e(_o(cs))})}return e})();function g1(e){return N(()=>{const t=b1(e),n={...t,decls:e.decls,vars:e.vars,template:e.template,consts:e.consts||null,ngContentSelectors:e.ngContentSelectors,onPush:e.changeDetection===sc.OnPush,directiveDefs:null,pipeDefs:null,dependencies:t.standalone&&e.dependencies||null,getStandaloneInjector:t.standalone?p=>p.get(rA).getOrCreateStandaloneInjector(n):null,getExternalStyles:null,signals:e.signals??!1,data:e.data||{},encapsulation:e.encapsulation||Sc.Emulated,styles:e.styles||Wn,_:null,schemas:e.schemas||null,tView:null,id:""};t.standalone&&oi("NgStandalone"),w1(n);const l=e.dependencies;return n.directiveDefs=mv(l,!1),n.pipeDefs=mv(l,!0),n.id=function aA(e){let t=0;const n=[e.selectors,e.ngContentSelectors,e.hostVars,e.hostAttrs,e.consts,e.vars,e.decls,e.encapsulation,e.standalone,e.signals,e.exportAs,JSON.stringify(e.inputs),JSON.stringify(e.outputs),Object.getOwnPropertyNames(e.type.prototype),!!e.contentQueries,!!e.viewQuery].join("|");for(const p of n)t=Math.imul(31,t)+p.charCodeAt(0)|0;return t+=2147483648,"c"+t}(n),n})}function iA(e){return zr(e)||di(e)}function oA(e){return null!==e}function Fb(e){return N(()=>({type:e.type,bootstrap:e.bootstrap||Wn,declarations:e.declarations||Wn,imports:e.imports||Wn,exports:e.exports||Wn,transitiveCompileScopes:null,schemas:e.schemas||null,id:e.id||null}))}function _1(e,t){if(null==e)return On;const n={};for(const l in e)if(e.hasOwnProperty(l)){const p=e[l];let g,x,k=ku.None;Array.isArray(p)?(k=p[0],g=p[1],x=p[2]??g):(g=p,x=p),t?(n[g]=k!==ku.None?[l,k]:l,t[g]=x):n[g]=l}return n}function v1(e){return N(()=>{const t=b1(e);return w1(t),t})}function y1(e){return{type:e.type,name:e.name,factory:null,pure:!1!==e.pure,standalone:e.standalone??!0,onDestroy:e.type.prototype.ngOnDestroy||null}}function b1(e){const t={};return{type:e.type,providersResolver:null,factory:null,hostBindings:e.hostBindings||null,hostVars:e.hostVars||0,hostAttrs:e.hostAttrs||null,contentQueries:e.contentQueries||null,declaredInputs:t,inputTransforms:null,inputConfig:e.inputs||On,exportAs:e.exportAs||null,standalone:e.standalone??!0,signals:!0===e.signals,selectors:e.selectors||Wn,viewQuery:e.viewQuery||null,features:e.features||null,setInput:null,findHostDirectiveDefs:null,hostDirectives:null,inputs:_1(e.inputs,t),outputs:_1(e.outputs),debugInfo:null}}function w1(e){e.features?.forEach(t=>t(e))}function mv(e,t){if(!e)return null;const n=t?Fi:iA;return()=>("function"==typeof e?e():e).map(l=>n(l)).filter(oA)}let x1=(()=>{class e{log(n){console.log(n)}warn(n){console.warn(n)}static \u0275fac=function(l){return new(l||e)};static \u0275prov=ai({token:e,factory:e.\u0275fac,providedIn:"platform"})}return e})();function Bb(e){return"function"==typeof e&&void 0!==e[C]}const A1="ng";function NA(e,t){!function T1(e,t){if(typeof COMPILED>"u"||!COMPILED){const n=dn;n[A1]??={},n[A1][e]=t}}(e,t)}const M1=new ht(""),k1=new ht("");let $b,LA=(()=>{class e{_ngZone;registry;_isZoneStable=!0;_callbacks=[];taskTrackingZone=null;constructor(n,l,p){this._ngZone=n,this.registry=l,$b||(function PA(e){$b=e}(p),p.addToWindow(l)),this._watchAngularEvents(),n.run(()=>{this.taskTrackingZone=typeof Zone>"u"?null:Zone.current.get("TaskTrackingZone")})}_watchAngularEvents(){this._ngZone.onUnstable.subscribe({next:()=>{this._isZoneStable=!1}}),this._ngZone.runOutsideAngular(()=>{this._ngZone.onStable.subscribe({next:()=>{os.assertNotInAngularZone(),queueMicrotask(()=>{this._isZoneStable=!0,this._runCallbacksIfReady()})}})})}isStable(){return this._isZoneStable&&!this._ngZone.hasPendingMacrotasks}_runCallbacksIfReady(){if(this.isStable())queueMicrotask(()=>{for(;0!==this._callbacks.length;){let n=this._callbacks.pop();clearTimeout(n.timeoutId),n.doneCb()}});else{let n=this.getPendingTasks();this._callbacks=this._callbacks.filter(l=>!l.updateCb||!l.updateCb(n)||(clearTimeout(l.timeoutId),!1))}}getPendingTasks(){return this.taskTrackingZone?this.taskTrackingZone.macroTasks.map(n=>({source:n.source,creationLocation:n.creationLocation,data:n.data})):[]}addCallback(n,l,p){let g=-1;l&&l>0&&(g=setTimeout(()=>{this._callbacks=this._callbacks.filter(x=>x.timeoutId!==g),n()},l)),this._callbacks.push({doneCb:n,timeoutId:g,updateCb:p})}whenStable(n,l,p){if(p&&!this.taskTrackingZone)throw new Error('Task tracking zone is required when passing an update callback to whenStable(). Is "zone.js/plugins/task-tracking" loaded?');this.addCallback(n,l,p),this._runCallbacksIfReady()}registerApplication(n){this.registry.registerApplication(n,this)}unregisterApplication(n){this.registry.unregisterApplication(n)}findProviders(n,l,p){return[]}static \u0275fac=function(l){return new(l||e)(_o(os),_o(I1),_o(k1))};static \u0275prov=ai({token:e,factory:e.\u0275fac})}return e})(),I1=(()=>{class e{_applications=new Map;registerApplication(n,l){this._applications.set(n,l)}unregisterApplication(n){this._applications.delete(n)}unregisterAllApplications(){this._applications.clear()}getTestability(n){return this._applications.get(n)||null}getAllTestabilities(){return Array.from(this._applications.values())}getAllRootElements(){return Array.from(this._applications.keys())}findTestabilityInTree(n,l=!0){return $b?.findTestabilityInTree(this,n,l)??null}static \u0275fac=function(l){return new(l||e)};static \u0275prov=ai({token:e,factory:e.\u0275fac,providedIn:"platform"})}return e})();function jb(e){return!!e&&"function"==typeof e.then}function O1(e){return!!e&&"function"==typeof e.subscribe}const Vb=new ht("");let R1=(()=>{class e{resolve;reject;initialized=!1;done=!1;donePromise=new Promise((n,l)=>{this.resolve=n,this.reject=l});appInits=lr(Vb,{optional:!0})??[];injector=lr(Qo);constructor(){}runInitializers(){if(this.initialized)return;const n=[];for(const p of this.appInits){const g=$s(this.injector,p);if(jb(g))n.push(g);else if(O1(g)){const x=new Promise((k,B)=>{g.subscribe({complete:k,error:B})});n.push(x)}}const l=()=>{this.done=!0,this.resolve()};Promise.all(n).then(()=>{l()}).catch(p=>{this.reject(p)}),0===n.length&&l(),this.initialized=!0}static \u0275fac=function(l){return new(l||e)};static \u0275prov=ai({token:e,factory:e.\u0275fac,providedIn:"root"})}return e})(),Hb=(()=>{class e{static \u0275prov=ai({token:e,providedIn:"root",factory:()=>new N1})}return e})();class N1{queuedEffectCount=0;queues=new Map;schedule(t){this.enqueue(t)}enqueue(t){const n=t.zone;this.queues.has(n)||this.queues.set(n,new Set);const l=this.queues.get(n);l.has(t)||(this.queuedEffectCount++,l.add(t))}flush(){for(;this.queuedEffectCount>0;)for(const[t,n]of this.queues)null===t?this.flushQueue(n):t.run(()=>this.flushQueue(n))}flushQueue(t){for(const n of t)t.delete(n),this.queuedEffectCount--,n.run()}}const pg=new ht("");let hc=(()=>{class e{_bootstrapListeners=[];_runningTick=!1;_destroyed=!1;_destroyListeners=[];_views=[];internalErrorHandler=lr(qu);afterRenderManager=lr(Bs);zonelessEnabled=lr(gu);rootEffectScheduler=lr(Hb);dirtyFlags=0;deferredDirtyFlags=0;externalTestViews=new Set;afterTick=new rt.B;get allViews(){return[...this.externalTestViews.keys(),...this._views]}get destroyed(){return this._destroyed}componentTypes=[];components=[];isStable=lr(Ec).hasPendingTasks.pipe((0,en.T)(n=>!n));whenStable(){let n;return new Promise(l=>{n=this.isStable.subscribe({next:p=>{p&&l()}})}).finally(()=>{n.unsubscribe()})}_injector=lr(cs);get injector(){return this._injector}bootstrap(n,l){const p=n instanceof u1;if(!this._injector.get(R1).done)throw!p&&Ro(n),new Rn(405,!1);let x;x=p?n:this._injector.get(hv).resolveComponentFactory(n),this.componentTypes.push(x.componentType);const k=function FA(e){return e.isBoundToModule}(x)?void 0:this._injector.get(gf),ie=x.create(Qo.NULL,[],l||x.selector,k),Se=ie.location.nativeElement,He=ie.injector.get(M1,null);return He?.registerApplication(Se),ie.onDestroy(()=>{this.detachView(ie.hostView),vv(this.components,ie),He?.unregisterApplication(Se)}),this._loadComponent(ie),ie}tick(){this.zonelessEnabled||(this.dirtyFlags|=1),this._tick()}_tick(){if(this._runningTick)throw new Rn(101,!1);const n=T(null);try{this._runningTick=!0,this.synchronize()}catch(l){this.internalErrorHandler(l)}finally{this._runningTick=!1,T(n),this.afterTick.next()}}synchronize(){let n=null;this._injector.destroyed||(n=this._injector.get(Ib,null,{optional:!0})),this.dirtyFlags|=this.deferredDirtyFlags,this.deferredDirtyFlags=0;let l=0;for(;0!==this.dirtyFlags&&l++<10;)this.synchronizeOnce(n)}synchronizeOnce(n){if(this.dirtyFlags|=this.deferredDirtyFlags,this.deferredDirtyFlags=0,16&this.dirtyFlags&&(this.dirtyFlags&=-17,this.rootEffectScheduler.flush()),7&this.dirtyFlags){const l=!!(1&this.dirtyFlags);this.dirtyFlags&=-8,this.dirtyFlags|=8;for(let{_lView:p,notifyErrorHandler:g}of this.allViews)$A(p,g,l,this.zonelessEnabled);if(this.dirtyFlags&=-5,this.syncDirtyFlagsWithViews(),23&this.dirtyFlags)return}else n?.begin?.(),n?.end?.();8&this.dirtyFlags&&(this.dirtyFlags&=-9,this.afterRenderManager.execute()),this.syncDirtyFlagsWithViews()}syncDirtyFlagsWithViews(){this.allViews.some(({_lView:n})=>kr(n))?this.dirtyFlags|=2:this.dirtyFlags&=-8}attachView(n){const l=n;this._views.push(l),l.attachToAppRef(this)}detachView(n){const l=n;vv(this._views,l),l.detachFromAppRef()}_loadComponent(n){this.attachView(n.hostView),this.tick(),this.components.push(n);const l=this._injector.get(pg,[]);[...this._bootstrapListeners,...l].forEach(p=>p(n))}ngOnDestroy(){if(!this._destroyed)try{this._destroyListeners.forEach(n=>n()),this._views.slice().forEach(n=>n.destroy())}finally{this._destroyed=!0,this._views=[],this._bootstrapListeners=[],this._destroyListeners=[]}}onDestroy(n){return this._destroyListeners.push(n),()=>vv(this._destroyListeners,n)}destroy(){if(this._destroyed)throw new Rn(406,!1);const n=this._injector;n.destroy&&!n.destroyed&&n.destroy()}get viewCount(){return this._views.length}warnIfDestroyed(){}static \u0275fac=function(l){return new(l||e)};static \u0275prov=ai({token:e,factory:e.\u0275fac,providedIn:"root"})}return e})();function vv(e,t){const n=e.indexOf(t);n>-1&&e.splice(n,1)}function $A(e,t,n,l){(n||kr(e))&&cv(e,t,n&&!l?0:1)}let tE=()=>null;function Mp(e,t){return tE(e,t)}let Cv=(()=>class e{static __NG_ELEMENT_ID__=AS})();function AS(){return iE(Si(),En())}const SS=Cv,nE=class extends SS{_lContainer;_hostTNode;_hostLView;constructor(t,n,l){super(),this._lContainer=t,this._hostTNode=n,this._hostLView=l}get element(){return Dc(this._hostTNode,this._hostLView)}get injector(){return new Fs(this._hostTNode,this._hostLView)}get parentInjector(){const t=Nc(this._hostTNode,this._hostLView);if(gh(t)){const n=Wu(t,this._hostLView),l=Hu(t);return new Fs(n[Fn].data[l+8],n)}return new Fs(null,this._hostLView)}clear(){for(;this.length>0;)this.remove(this.length-1)}get(t){const n=rE(this._lContainer);return null!==n&&n[t]||null}get length(){return this._lContainer.length-Rr}createEmbeddedView(t,n,l){let p,g;"number"==typeof l?p=l:null!=l&&(p=l.index,g=l.injector);const x=Mp(this._lContainer,t.ssrId),k=t.createEmbeddedViewImpl(n||{},g,x);return this.insertImpl(k,p,mf(this._hostTNode,x)),k}createComponent(t,n,l,p,g){const x=t&&!function El(e){return"function"==typeof e}(t);let k;if(x)k=n;else{const qt=n||{};k=qt.index,l=qt.injector,p=qt.projectableNodes,g=qt.environmentInjector||qt.ngModuleRef}const B=x?t:new hg(zr(t)),ie=l||this.parentInjector;if(!g&&null==B.ngModule){const Ln=(x?ie:this.parentInjector).get(cs,null);Ln&&(g=Ln)}const Se=zr(B.componentType??{}),He=Mp(this._lContainer,Se?.id??null),Ut=B.create(ie,p,He?.firstChild??null,g);return this.insertImpl(Ut.hostView,k,mf(this._hostTNode,He)),Ut}insert(t,n){return this.insertImpl(t,n,!0)}insertImpl(t,n,l){const p=t._lView;if(function At(e){return wi(e[Oi])}(p)){const k=this.indexOf(t);if(-1!==k)this.detach(k);else{const B=p[Oi],ie=new nE(B,B[Qi],B[Oi]);ie.detach(ie.indexOf(t))}}const g=this._adjustIndex(n),x=this._lContainer;return Sp(x,p,g,l),t.attachToViewContainerRef(),Da(e0(x),g,t),t}move(t,n){return this.insert(t,n)}indexOf(t){const n=rE(this._lContainer);return null!==n?n.indexOf(t):-1}remove(t){const n=this._adjustIndex(t,-1),l=af(this._lContainer,n);l&&(Ms(e0(this._lContainer),n),lf(l[Fn],l))}detach(t){const n=this._adjustIndex(t,-1),l=af(this._lContainer,n);return l&&null!=Ms(e0(this._lContainer),n)?new og(l):null}_adjustIndex(t,n=0){return t??this.length+n}};function rE(e){return e[8]}function e0(e){return e[8]||(e[8]=[])}function iE(e,t){let n;const l=t[e.index];return wi(l)?n=l:(n=ng(l,t,null,e),t[e.index]=n,ra(t,n)),oE(n,t,e,l),new nE(n,e,t)}let oE=function aE(e,t,n,l){if(e[ci])return;let p;p=8&n.type?qi(l):function TS(e,t){const n=e[ri],l=n.createComment(""),p=rs(t,e);return hd(n,Xm(n,p),l,function ab(e,t){return e.nextSibling(t)}(n,p),!1),l}(t,n),e[ci]=p},t0=()=>!1;class n0{queryList;matches=null;constructor(t){this.queryList=t}clone(){return new n0(this.queryList)}setDirty(){this.queryList.setDirty()}}class r0{queries;constructor(t=[]){this.queries=t}createEmbeddedView(t){const n=t.queries;if(null!==n){const l=null!==t.contentQueries?t.contentQueries[0]:n.length,p=[];for(let g=0;gt.trim())}(t):t}}class o0{queries;constructor(t=[]){this.queries=t}elementStart(t,n){for(let l=0;l0)l.push(x[k/2]);else{const ie=g[k+1],Se=t[-B];for(let He=Rr;He(Z(t),t.value);return n[C]=t,n}(e),l=n[C];return t?.equal&&(l.equal=t.equal),n.set=p=>Ze(l,p),n.update=p=>function it(e,t){se()||qe(),Ze(e,t(e.value))}(l,p),n.asReadonly=u0.bind(n),n}function u0(){const e=this[C];if(void 0===e.readonlyFn){const t=()=>this();t[C]=e,e.readonlyFn=t}return e.readonlyFn}function mE(e){return Bb(e)&&"function"==typeof e.set}function d0(e,t,n){let l;const p=bt(()=>{l._dirtyCounter();const g=function BS(e,t){const n=e._lView,l=e._queryIndex;if(void 0===n||void 0===l||4&n[Sr])return t?void 0:Wn;const p=l0(n,l),g=pE(n,l);return p.reset(g,Nh),t?p.first:p._changesDetected||void 0===e._flatValue?e._flatValue=p.toArray():e._flatValue}(l,e);if(t&&void 0===g)throw new Rn(-951,!1);return g});return l=p[C],l._dirtyCounter=kp(0),l._flatValue=void 0,p}function bE(e,t){return function gE(e){return d0(!0,!1)}()}const $S=(bE.required=function US(e,t){return function _E(e){return d0(!0,!0)}()},bE);function h0(e){let t=function SE(e){return Object.getPrototypeOf(e.prototype).constructor}(e.type),n=!0;const l=[e];for(;t;){let p;if(Yo(e))p=t.\u0275cmp||t.\u0275dir;else{if(t.\u0275cmp)throw new Rn(903,!1);p=t.\u0275dir}if(p){if(n){l.push(p);const x=e;x.inputs=Av(e.inputs),x.inputTransforms=Av(e.inputTransforms),x.declaredInputs=Av(e.declaredInputs),x.outputs=Av(e.outputs);const k=p.hostBindings;k&&JS(e,k);const B=p.viewQuery,ie=p.contentQueries;if(B&&ZS(e,B),ie&&qS(e,ie),YS(e,p),Hr(e.outputs,p.outputs),Yo(p)&&p.data.animation){const Se=e.data;Se.animation=(Se.animation||[]).concat(p.data.animation)}}const g=p.features;if(g)for(let x=0;x=0;l--){const p=e[l];p.hostVars=t+=p.hostVars,p.hostAttrs=nc(p.hostAttrs,n=nc(n,p.hostAttrs))}}(l)}function YS(e,t){for(const n in t.inputs){if(!t.inputs.hasOwnProperty(n)||e.inputs.hasOwnProperty(n))continue;const l=t.inputs[n];if(void 0!==l&&(e.inputs[n]=l,e.declaredInputs[n]=t.declaredInputs[n],null!==t.inputTransforms)){const p=Array.isArray(l)?l[0]:l;if(!t.inputTransforms.hasOwnProperty(p))continue;e.inputTransforms??={},e.inputTransforms[p]=t.inputTransforms[p]}}}function Av(e){return e===On?{}:e===Wn?[]:e}function ZS(e,t){const n=e.viewQuery;e.viewQuery=n?(l,p)=>{t(l,p),n(l,p)}:t}function qS(e,t){const n=e.contentQueries;e.contentQueries=n?(l,p,g)=>{t(l,p,g),n(l,p,g)}:t}function JS(e,t){const n=e.hostBindings;e.hostBindings=n?(l,p)=>{t(l,p),n(l,p)}:t}function TE(e){const t=n=>{const l=Array.isArray(e);null===n.hostDirectives?(n.findHostDirectiveDefs=ME,n.hostDirectives=l?e.map(f0):[e]):l?n.hostDirectives.unshift(...e.map(f0)):n.hostDirectives.unshift(e)};return t.ngInherit=!0,t}function ME(e,t,n){if(null!==e.hostDirectives)for(const l of e.hostDirectives)if("function"==typeof l){const p=l();for(const g of p)kE(f0(g),t,n)}else kE(l,t,n)}function kE(e,t,n){const l=di(e.directive);(function rT(e,t){for(const n in t)t.hasOwnProperty(n)&&(e[t[n]]=e[n])})(l.declaredInputs,e.inputs),ME(l,t,n),n.set(l,e),t.push(l)}function f0(e){return"function"==typeof e?{directive:Ge(e),inputs:On,outputs:On}:{directive:Ge(e.directive),inputs:IE(e.inputs),outputs:IE(e.outputs)}}function IE(e){if(void 0===e||0===e.length)return On;const t={};for(let n=0;n>17&32767}function S0(e){return 2|e}function yf(e){return(131068&e)>>2}function T0(e,t){return-131069&e|t<<2}function M0(e){return 1|e}function JE(e,t,n,l){const p=e[n+1],g=null===t;let x=l?oh(p):yf(p),k=!1;for(;0!==x&&(!1===k||g);){const ie=e[x+1];nM(e[x],t)&&(k=!0,e[x+1]=l?M0(ie):S0(ie)),x=l?oh(ie):yf(ie)}k&&(e[n+1]=l?S0(p):M0(p))}function nM(e,t){return null===e||null==t||(Array.isArray(e)?e[1]:e)===t||!(!Array.isArray(e)||"string"!=typeof t)&&ot(e,t)>=0}const Pa={textEnd:0,key:0,keyEnd:0,value:0,valueEnd:0};function ex(e){return e.substring(Pa.key,Pa.keyEnd)}function rM(e){return e.substring(Pa.value,Pa.valueEnd)}function tx(e,t){const n=Pa.textEnd;return n===t?-1:(t=Pa.keyEnd=function sM(e,t,n){for(;t32;)t++;return t}(e,Pa.key=t,n),Kp(e,t,n))}function nx(e,t){const n=Pa.textEnd;let l=Pa.key=Kp(e,t,n);return n===l?-1:(l=Pa.keyEnd=function aM(e,t,n){let l;for(;t=65&&(-33&l)<=90||l>=48&&l<=57);)t++;return t}(e,l,n),l=ix(e,l,n),l=Pa.value=Kp(e,l,n),l=Pa.valueEnd=function lM(e,t,n){let l=-1,p=-1,g=-1,x=t,k=x;for(;x32&&(k=x),g=p,p=l,l=-33&B}return k}(e,l,n),ix(e,l,n))}function rx(e){Pa.key=0,Pa.keyEnd=0,Pa.value=0,Pa.valueEnd=0,Pa.textEnd=e.length}function Kp(e,t,n){for(;t=0;n=nx(t,n))cx(e,ex(t),rM(t))}function sx(e){Jc(mM,Lu,e,!0)}function Lu(e,t){for(let n=function iM(e){return rx(e),tx(e,Kp(e,0,Pa.textEnd))}(t);n>=0;n=tx(t,n))et(e,ex(t),!0)}function qc(e,t,n,l){const p=En(),g=pi(),x=P(2);g.firstUpdatePass&&lx(g,e,x,l),t!==$i&&Ws(p,x,t)&&ux(g,g.data[$n()],p,p[ri],e,p[x+1]=function _M(e,t){return null==e||""===e||("string"==typeof t?e+=t:"object"==typeof e&&(e=Tr(Gc(e)))),e}(t,n),l,x)}function Jc(e,t,n,l){const p=pi(),g=P(2);p.firstUpdatePass&&lx(p,null,g,l);const x=En();if(n!==$i&&Ws(x,g,n)){const k=p.data[$n()];if(hx(k,l)&&!ax(p,g)){let B=l?k.classesWithoutHost:k.stylesWithoutHost;null!==B&&(n=Vr(B,n||"")),I0(p,k,x,n,l)}else!function gM(e,t,n,l,p,g,x,k){p===$i&&(p=Wn);let B=0,ie=0,Se=0=e.expandoStartIndex}function lx(e,t,n,l){const p=e.data;if(null===p[n+1]){const g=p[$n()],x=ax(e,n);hx(g,l)&&null===t&&!x&&(t=!1),t=function uM(e,t,n,l){const p=It(e);let g=l?t.residualClasses:t.residualStyles;if(null===p)0===(l?t.classBindings:t.styleBindings)&&(n=xg(n=N0(null,e,t,n,l),t.attrs,l),g=null);else{const x=t.directiveStylingLast;if(-1===x||e[x]!==p)if(n=N0(p,e,t,n,l),null===g){let B=function dM(e,t,n){const l=n?t.classBindings:t.styleBindings;if(0!==yf(l))return e[oh(l)]}(e,t,l);void 0!==B&&Array.isArray(B)&&(B=N0(null,e,t,B[1],l),B=xg(B,t.attrs,l),function hM(e,t,n,l){e[oh(n?t.classBindings:t.styleBindings)]=l}(e,t,l,B))}else g=function fM(e,t,n){let l;const p=t.directiveEnd;for(let g=1+t.directiveStylingLast;g0)&&(ie=!0)):Se=n,p)if(0!==B){const Nt=oh(e[k+1]);e[l+1]=Iv(Nt,k),0!==Nt&&(e[Nt+1]=T0(e[Nt+1],l)),e[k+1]=function qT(e,t){return 131071&e|t<<17}(e[k+1],l)}else e[l+1]=Iv(k,0),0!==k&&(e[k+1]=T0(e[k+1],l)),k=l;else e[l+1]=Iv(B,0),0===k?k=l:e[B+1]=T0(e[B+1],l),B=l;ie&&(e[l+1]=S0(e[l+1])),JE(e,Se,l,!0),JE(e,Se,l,!1),function tM(e,t,n,l,p){const g=p?e.residualClasses:e.residualStyles;null!=g&&"string"==typeof t&&ot(g,t)>=0&&(n[l+1]=M0(n[l+1]))}(t,Se,e,l,g),x=Iv(k,B),g?t.classBindings=x:t.styleBindings=x}(p,g,t,n,x,l)}}function N0(e,t,n,l,p){let g=null;const x=n.directiveEnd;let k=n.directiveStylingLast;for(-1===k?k=n.directiveStart:k++;k0;){const B=e[p],ie=Array.isArray(B),Se=ie?B[1]:B,He=null===Se;let Nt=n[p+1];Nt===$i&&(Nt=He?Wn:void 0);let Ut=He?te(Nt,l):Se===l?Nt:void 0;if(ie&&!Ov(Ut)&&(Ut=te(B,l)),Ov(Ut)&&(k=Ut,x))return k;const qt=e[p+1];p=x?oh(qt):yf(qt)}if(null!==t){let B=g?t.residualClasses:t.residualStyles;null!=B&&(k=te(B,l))}return k}function Ov(e){return void 0!==e}function hx(e,t){return!!(e.flags&(t?8:16))}function fx(e,t,n){Jc(et,Lu,Bp(En(),e,t,n),!0)}function px(){return En()[vo][Ki]}class AM{destroy(t){}updateValue(t,n){}swap(t,n){const l=Math.min(t,n),p=Math.max(t,n),g=this.detach(p);if(p-l>1){const x=this.detach(l);this.attach(l,g),this.attach(p,x)}else this.attach(l,g)}move(t,n){this.attach(n,this.detach(t))}}function L0(e,t,n,l,p){return e===n&&Object.is(t,l)?1:Object.is(p(e,t),p(n,l))?-1:0}function P0(e,t,n,l){return!(void 0===t||!t.has(l)||(e.attach(n,t.get(l)),t.delete(l),0))}function mx(e,t,n,l,p){if(P0(e,t,l,n(l,p)))e.updateValue(l,p);else{const g=e.create(l,p);e.attach(l,g)}}function gx(e,t,n,l){const p=new Set;for(let g=t;g<=n;g++)p.add(l(g,e.at(g)));return p}class _x{kvMap=new Map;_vMap=void 0;has(t){return this.kvMap.has(t)}delete(t){if(!this.has(t))return!1;const n=this.kvMap.get(t);return void 0!==this._vMap&&this._vMap.has(n)?(this.kvMap.set(t,this._vMap.get(n)),this._vMap.delete(n)):this.kvMap.delete(t),!0}get(t){return this.kvMap.get(t)}set(t,n){if(this.kvMap.has(t)){let l=this.kvMap.get(t);void 0===this._vMap&&(this._vMap=new Map);const p=this._vMap;for(;p.has(l);)l=p.get(l);p.set(l,n)}else this.kvMap.set(t,n)}forEach(t){for(let[n,l]of this.kvMap)if(t(l,n),void 0!==this._vMap){const p=this._vMap;for(;p.has(l);)l=p.get(l),t(l,n)}}}function vx(e,t){oi("NgControlFlow");const n=En(),l=I(),p=n[l]!==$i?n[l]:-1,g=-1!==p?Rv(n,Gt+p):void 0;if(Ws(n,l,e)){const k=T(null);try{if(void 0!==g&&Db(g,0),-1!==e){const B=Gt+e,ie=Rv(n,B),Se=F0(n[Fn],B),He=Mp(ie,Se.tView.ssrId);Sp(ie,Ap(n,Se,t,{dehydratedView:He}),0,mf(Se,He))}}finally{T(k)}}else if(void 0!==g){const k=qw(g,0);void 0!==k&&(k[Ki]=t)}}class TM{lContainer;$implicit;$index;constructor(t,n,l){this.lContainer=t,this.$implicit=n,this.$index=l}get $count(){return this.lContainer.length-Rr}}function yx(e){return e}class kM{hasEmptyBlock;trackByFn;liveCollection;constructor(t,n,l){this.hasEmptyBlock=t,this.trackByFn=n,this.liveCollection=l}}function bx(e,t,n,l,p,g,x,k,B,ie,Se,He,Nt){oi("NgControlFlow");const Ut=En(),qt=pi(),Ln=void 0!==B,Yn=En(),cr=k?x.bind(Yn[vo][Ki]):x,Pn=new kM(Ln,cr);Yn[Gt+e]=Pn,wg(Ut,qt,e+1,t,n,l,p,fn(qt.consts,g)),Ln&&wg(Ut,qt,e+2,B,ie,Se,He,fn(qt.consts,Nt))}class IM extends AM{lContainer;hostLView;templateTNode;operationsCounter=void 0;needsIndexUpdate=!1;constructor(t,n,l){super(),this.lContainer=t,this.hostLView=n,this.templateTNode=l}get length(){return this.lContainer.length-Rr}at(t){return this.getLView(t)[Ki].$implicit}attach(t,n){const l=n[so];this.needsIndexUpdate||=t!==this.length,Sp(this.lContainer,n,t,mf(this.templateTNode,l))}detach(t){return this.needsIndexUpdate||=t!==this.length-1,function OM(e,t){return af(e,t)}(this.lContainer,t)}create(t,n){const l=Mp(this.lContainer,this.templateTNode.tView.ssrId),p=Ap(this.hostLView,this.templateTNode,new TM(this.lContainer,n,t),{dehydratedView:l});return this.operationsCounter?.recordCreate(),p}destroy(t){lf(t[Fn],t),this.operationsCounter?.recordDestroy()}updateValue(t,n){this.getLView(t)[Ki].$implicit=n}reset(){this.needsIndexUpdate=!1,this.operationsCounter?.reset()}updateIndexes(){if(this.needsIndexUpdate)for(let t=0;t{e.destroy(B)})}(B,e,g.trackByFn),B.updateIndexes(),g.hasEmptyBlock){const ie=I(),Se=0===B.length;if(Ws(l,ie,Se)){const He=n+2,Nt=Rv(l,He);if(Se){const Ut=F0(p,He),qt=Mp(Nt,Ut.tView.ssrId);Sp(Nt,Ap(l,Ut,void 0,{dehydratedView:qt}),0,mf(Ut,qt))}else Db(Nt,0)}}}finally{T(t)}}function Rv(e,t){return e[t]}function F0(e,t){return G(e,t)}function Nv(e,t,n,l){const p=En(),g=pi(),x=Gt+e,k=p[ri],B=g.firstCreatePass?function NM(e,t,n,l,p,g){const x=t.consts,B=fd(t,e,2,l,fn(x,p));return vl(t,n,B,fn(x,g)),null!==B.attrs&&pv(B,B.attrs,!1),null!==B.mergedAttrs&&pv(B,B.mergedAttrs,!0),null!==t.queries&&t.queries.elementStart(t,B),B}(x,g,p,t,n,l):g.data[x],ie=Ex(g,p,B,k,t,e);p[x]=ie;const Se=fa(B);return Qs(B,!0),tv(k,ie,B),!function Op(e){return!(32&~e.flags)}(B)&&bo()&&bp(g,p,ie,B),0===function _d(){return Wr.lFrame.elementDepthCount}()&&ya(ie,p),function uh(){Wr.lFrame.elementDepthCount++}(),Se&&(d(g,p,B),m(g,B,p)),null!==l&&_(p,B),Nv}function Lv(){let e=Si();Oc()?pa():(e=e.parent,Qs(e,!1));const t=e;(function Ql(e){return Wr.skipHydrationRootTNode===e})(t)&&function Ja(){Wr.skipHydrationRootTNode=null}(),function dh(){Wr.lFrame.elementDepthCount--}();const n=pi();return n.firstCreatePass&&(_r(n,e),bs(e)&&n.queries.elementEnd(e)),null!=t.classesWithoutHost&&function yc(e){return!!(8&e.flags)}(t)&&I0(n,t,En(),t.classesWithoutHost,!0),null!=t.stylesWithoutHost&&function tc(e){return!!(16&e.flags)}(t)&&I0(n,t,En(),t.stylesWithoutHost,!1),Lv}function B0(e,t,n,l){return Nv(e,t,n,l),Lv(),B0}let Ex=(e,t,n,l,p,g)=>(To(!0),gp(l,p,function Ji(){return Wr.lFrame.currentNamespace}()));function Pv(e,t,n){const l=En(),p=pi(),g=e+Gt,x=p.firstCreatePass?function FM(e,t,n,l,p){const g=t.consts,x=fn(g,l),k=fd(t,e,8,"ng-container",x);return null!==x&&pv(k,x,!0),vl(t,n,k,fn(g,p)),null!==t.queries&&t.queries.elementStart(t,k),k}(g,p,l,t,n):p.data[g];Qs(x,!0);const k=xx(p,l,x,e);return l[g]=k,bo()&&bp(p,l,k,x),ya(k,l),fa(x)&&(d(p,l,x),m(p,x,l)),null!=n&&_(l,x),Pv}function Fv(){let e=Si();const t=pi();return Oc()?pa():(e=e.parent,Qs(e,!1)),t.firstCreatePass&&(_r(t,e),bs(e)&&t.queries.elementEnd(e)),Fv}function U0(e,t,n){return Pv(e,t,n),Fv(),U0}let xx=(e,t,n,l)=>(To(!0),Km(t[ri],""));function Cx(){return En()}function $0(e,t,n){const l=En();return Ws(l,I(),t)&&ho(pi(),ir(),l,e,t,l[ri],n,!0),$0}function j0(e,t,n){const l=En();if(Ws(l,I(),t)){const g=pi(),x=ir();ho(g,x,l,e,t,Zw(It(g.data),x,l),n,!0)}return j0}const bf=void 0;var jM=["en",[["a","p"],["AM","PM"],bf],[["AM","PM"],bf,bf],[["S","M","T","W","T","F","S"],["Sun","Mon","Tue","Wed","Thu","Fri","Sat"],["Sunday","Monday","Tuesday","Wednesday","Thursday","Friday","Saturday"],["Su","Mo","Tu","We","Th","Fr","Sa"]],bf,[["J","F","M","A","M","J","J","A","S","O","N","D"],["Jan","Feb","Mar","Apr","May","Jun","Jul","Aug","Sep","Oct","Nov","Dec"],["January","February","March","April","May","June","July","August","September","October","November","December"]],bf,[["B","A"],["BC","AD"],["Before Christ","Anno Domini"]],0,[6,0],["M/d/yy","MMM d, y","MMMM d, y","EEEE, MMMM d, y"],["h:mm a","h:mm:ss a","h:mm:ss a z","h:mm:ss a zzzz"],["{1}, {0}",bf,"{1} 'at' {0}",bf],[".",",",";","%","+","-","E","\xd7","\u2030","\u221e","NaN",":"],["#,##0.###","#,##0%","\xa4#,##0.00","#E0"],"USD","$","US Dollar",{},"ltr",function $M(e){const n=Math.floor(Math.abs(e)),l=e.toString().replace(/^[^.]*\.?/,"").length;return 1===n&&0===l?1:5}];let Gp={};function V0(e){const t=function VM(e){return e.toLowerCase().replace(/_/g,"-")}(e);let n=Ax(t);if(n)return n;const l=t.split("-")[0];if(n=Ax(l),n)return n;if("en"===l)return jM;throw new Rn(701,!1)}function Dx(e){return V0(e)[Xp.PluralCase]}function Ax(e){return e in Gp||(Gp[e]=dn.ng&&dn.ng.common&&dn.ng.common.locales&&dn.ng.common.locales[e]),Gp[e]}var Xp=function(e){return e[e.LocaleId=0]="LocaleId",e[e.DayPeriodsFormat=1]="DayPeriodsFormat",e[e.DayPeriodsStandalone=2]="DayPeriodsStandalone",e[e.DaysFormat=3]="DaysFormat",e[e.DaysStandalone=4]="DaysStandalone",e[e.MonthsFormat=5]="MonthsFormat",e[e.MonthsStandalone=6]="MonthsStandalone",e[e.Eras=7]="Eras",e[e.FirstDayOfWeek=8]="FirstDayOfWeek",e[e.WeekendRange=9]="WeekendRange",e[e.DateFormat=10]="DateFormat",e[e.TimeFormat=11]="TimeFormat",e[e.DateTimeFormat=12]="DateTimeFormat",e[e.NumberSymbols=13]="NumberSymbols",e[e.NumberFormats=14]="NumberFormats",e[e.CurrencyCode=15]="CurrencyCode",e[e.CurrencySymbol=16]="CurrencySymbol",e[e.CurrencyName=17]="CurrencyName",e[e.Currencies=18]="Currencies",e[e.Directionality=19]="Directionality",e[e.PluralCase=20]="PluralCase",e[e.ExtraData=21]="ExtraData",e}(Xp||{});const Bv="en-US";let Sx=Bv,zx=(e,t,n)=>{};function z0(e,t,n,l){const p=En(),g=pi(),x=Si();return G0(g,p,p[ri],x,e,t,l),z0}function K0(e,t){const n=Si(),l=En(),p=pi();return G0(p,l,Zw(It(p.data),n,l),n,e,t),K0}function G0(e,t,n,l,p,g,x){const k=fa(l),ie=e.firstCreatePass&&Dp(e),Se=t[Ki],He=pf(t);let Nt=!0;if(3&l.type||x){const Ln=rs(l,t),Yn=x?x(Ln):Ln,cr=He.length,Pn=x?ji=>x(qi(ji[l.index])):l.index;let xi=null;if(!x&&k&&(xi=function Ok(e,t,n,l){const p=e.cleanup;if(null!=p)for(let g=0;gB?k[B]:null}"string"==typeof x&&(g+=2)}return null}(e,t,p,l.index)),null!==xi)(xi.__ngLastListenerFn__||xi).__ngNextListenerFn__=g,xi.__ngLastListenerFn__=g,Nt=!1;else{g=Gx(l,t,Se,g),zx(Ln,p,g);const ji=n.listen(Yn,p,g);He.push(g,ji),ie&&ie.push(p,Pn,cr,cr+1)}}else g=Gx(l,t,Se,g);const Ut=l.outputs;let qt;if(Nt&&null!==Ut&&(qt=Ut[p])){const Ln=qt.length;if(Ln)for(let Yn=0;Yn-1?K(e.index,t):t,5);let k=Kx(t,n,l,g),B=p.__ngNextListenerFn__;for(;B;)k=Kx(t,n,B,g)&&k,B=B.__ngNextListenerFn__;return k}}function Xx(e=1){return function vr(e){return(Wr.lFrame.contextLView=function ui(e,t){for(;e>0;)t=t[Uo],e--;return t}(e,Wr.lFrame.contextLView))[Ki]}(e)}function Rk(e,t){let n=null;const l=function gb(e){const t=e.attrs;if(null!=t){const n=t.indexOf(5);if(!(1&n))return t[n+1]}return null}(e);for(let p=0;pn._dirtyCounter.update(l=>l+1))}(t,hE(e,n,l,p))}function uC(e=1){ln(zt()+e)}function dC(e){return F(function vd(){return Wr.lFrame.contextLView}(),Gt+e)}function wC(e,t=""){const n=En(),l=pi(),p=e+Gt,g=l.firstCreatePass?fd(l,p,1,t,null):l.data[p],x=EC(l,n,g,t,e);n[p]=x,bo()&&bp(l,n,x,g),Qs(g,!1)}let EC=(e,t,n,l,p)=>(To(!0),function zm(e,t){return e.createText(t)}(t[ri],l));function Q0(e){return Hv("",e,""),Q0}function Hv(e,t,n){const l=En(),p=Bp(l,e,t,n);return p!==$i&&function md(e,t,n){const l=gc(t,e);!function U_(e,t,n){e.setValue(t,n)}(e[ri],l,n)}(l,$n(),p),Hv}function Z0(e,t,n){mE(t)&&(t=t());const l=En();return Ws(l,I(),t)&&ho(pi(),ir(),l,e,t,l[ri],n,!1),Z0}function IC(e,t){const n=mE(e);return n&&e.set(t),n}function q0(e,t){const n=En(),l=pi(),p=Si();return G0(l,n,n[ri],p,e,t),q0}function J0(e,t,n,l,p){if(e=Ge(e),Array.isArray(e))for(let g=0;g>20;if(ts(e)||!e.multi){const Ut=new el(ie,p,qd),qt=tw(B,t,p?Se:Se+Nt,He);-1===qt?(Lc(vh(k,x),g,B),ew(g,e,t.length),t.push(B),k.directiveStart++,k.directiveEnd++,p&&(k.providerIndexes+=1048576),n.push(Ut),x.push(Ut)):(n[qt]=Ut,x[qt]=Ut)}else{const Ut=tw(B,t,Se+Nt,He),qt=tw(B,t,Se,Se+Nt),Yn=qt>=0&&n[qt];if(p&&!Yn||!p&&!(Ut>=0&&n[Ut])){Lc(vh(k,x),g,B);const cr=function qk(e,t,n,l,p){const g=new el(e,n,qd);return g.multi=[],g.index=t,g.componentProviders=0,NC(g,p,l&&!n),g}(p?Zk:Qk,n.length,p,l,ie);!p&&Yn&&(n[qt].providerFactory=cr),ew(g,e,t.length,0),t.push(B),k.directiveStart++,k.directiveEnd++,p&&(k.providerIndexes+=1048576),n.push(cr),x.push(cr)}else ew(g,e,Ut>-1?Ut:qt,NC(n[p?qt:Ut],ie,!p&&l));!p&&l&&Yn&&n[qt].componentProviders++}}}function ew(e,t,n,l){const p=ts(t),g=function kl(e){return!!e.useClass}(t);if(p||g){const B=(g?Ge(t.useClass):t).prototype.ngOnDestroy;if(B){const ie=e.destroyHooks||(e.destroyHooks=[]);if(!p&&t.multi){const Se=ie.indexOf(n);-1===Se?ie.push(n,[l,B]):ie[Se+1].push(l,B)}else ie.push(n,B)}}}function NC(e,t,n){return n&&e.componentProviders++,e.multi.push(t)-1}function tw(e,t,n,l){for(let p=n;p{n.providersResolver=(l,p)=>function Yk(e,t,n){const l=pi();if(l.firstCreatePass){const p=Yo(e);J0(n,l.data,l.blueprint,p,!0),J0(t,l.data,l.blueprint,p,!1)}}(l,p?p(e):e,t)}}function FC(e,t,n){const l=Zs()+e,p=En();return p[l]===$i?Nu(p,l,n?t.call(n):t()):bg(p,l)}function BC(e,t,n,l){return HC(En(),Zs(),e,t,n,l)}function UC(e,t,n,l,p){return WC(En(),Zs(),e,t,n,l,p)}function $C(e,t,n,l,p,g){return function zC(e,t,n,l,p,g,x,k){const B=t+n;return function Tv(e,t,n,l,p){const g=vf(e,t,n,l);return Ws(e,t+2,p)||g}(e,B,p,g,x)?Nu(e,B+3,k?l.call(k,p,g,x):l(p,g,x)):Mg(e,B+3)}(En(),Zs(),e,t,n,l,p,g)}function jC(e,t,n,l,p,g,x){return function KC(e,t,n,l,p,g,x,k,B){const ie=t+n;return Tc(e,ie,p,g,x,k)?Nu(e,ie+4,B?l.call(B,p,g,x,k):l(p,g,x,k)):Mg(e,ie+4)}(En(),Zs(),e,t,n,l,p,g,x)}function VC(e,t,n,l,p,g,x,k,B,ie,Se){const He=Zs()+e,Nt=En(),Ut=Tc(Nt,He,n,l,p,g);return Tc(Nt,He+4,x,k,B,ie)||Ut?Nu(Nt,He+8,Se?t.call(Se,n,l,p,g,x,k,B,ie):t(n,l,p,g,x,k,B,ie)):bg(Nt,He+8)}function Mg(e,t){const n=e[t];return n===$i?void 0:n}function HC(e,t,n,l,p,g){const x=t+n;return Ws(e,x,p)?Nu(e,x+1,g?l.call(g,p):l(p)):Mg(e,x+1)}function WC(e,t,n,l,p,g,x){const k=t+n;return vf(e,k,p,g)?Nu(e,k+2,x?l.call(x,p,g):l(p,g)):Mg(e,k+2)}function XC(e,t){const n=pi();let l;const p=e+Gt;n.firstCreatePass?(l=function sI(e,t){if(t)for(let n=t.length-1;n>=0;n--){const l=t[n];if(e===l.name)return l}}(t,n.pipeRegistry),n.data[p]=l,l.onDestroy&&(n.destroyHooks??=[]).push(p,l.onDestroy)):l=n.data[p];const g=l.factory||(l.factory=So(l.type)),k=Oo(qd);try{const B=Ll(!1),ie=g();return Ll(B),function Y0(e,t,n,l){n>=e.data.length&&(e.data[n]=null,e.blueprint[n]=null),t[n]=l}(n,En(),p,ie),ie}finally{Oo(k)}}function YC(e,t,n){const l=e+Gt,p=En(),g=F(p,l);return kg(p,l)?HC(p,Zs(),t,g.transform,n,g):g.transform(n)}function QC(e,t,n,l){const p=e+Gt,g=En(),x=F(g,p);return kg(g,p)?WC(g,Zs(),t,x.transform,n,l,x):x.transform(n,l)}function kg(e,t){return e[Fn].data[t].pure}function ZC(e,t){return uv(e,t)}class f2{full;major;minor;patch;constructor(t){this.full=t;const n=t.split(".");this.major=n[0],this.minor=n[1],this.patch=n.slice(2).join(".")}}class PI{ngModuleFactory;componentFactories;constructor(t,n){this.ngModuleFactory=t,this.componentFactories=n}}let FI=(()=>{class e{compileModuleSync(n){return new Lb(n)}compileModuleAsync(n){return Promise.resolve(this.compileModuleSync(n))}compileModuleAndAllComponentsSync(n){const l=this.compileModuleSync(n),g=Al(fi(n).declarations).reduce((x,k)=>{const B=zr(k);return B&&x.push(new hg(B)),x},[]);return new PI(l,g)}compileModuleAndAllComponentsAsync(n){return Promise.resolve(this.compileModuleAndAllComponentsSync(n))}clearCache(){}clearCacheFor(n){}getModuleId(n){}static \u0275fac=function(l){return new(l||e)};static \u0275prov=ai({token:e,factory:e.\u0275fac,providedIn:"root"})}return e})(),$I=(()=>{class e{zone=lr(os);changeDetectionScheduler=lr(rc);applicationRef=lr(hc);_onMicrotaskEmptySubscription;initialize(){this._onMicrotaskEmptySubscription||(this._onMicrotaskEmptySubscription=this.zone.onMicrotaskEmpty.subscribe({next:()=>{this.changeDetectionScheduler.runningTick||this.zone.run(()=>{this.applicationRef.tick()})}}))}ngOnDestroy(){this._onMicrotaskEmptySubscription?.unsubscribe()}static \u0275fac=function(l){return new(l||e)};static \u0275prov=ai({token:e,factory:e.\u0275fac,providedIn:"root"})}return e})();function lw({ngZoneFactory:e,ignoreChangesOutsideZone:t,scheduleInRootZone:n}){return e??=()=>new os({...cw(),scheduleInRootZone:n}),[{provide:os,useFactory:e},{provide:Qn,multi:!0,useFactory:()=>{const l=lr($I,{optional:!0});return()=>l.initialize()}},{provide:Qn,multi:!0,useFactory:()=>{const l=lr(VI);return()=>{l.initialize()}}},!0===t?{provide:Od,useValue:!0}:[],{provide:ic,useValue:n??Sh}]}function cw(e){return{enableLongStackTrace:!1,shouldCoalesceEventChangeDetection:e?.eventCoalescing??!1,shouldCoalesceRunChangeDetection:e?.runCoalescing??!1}}let VI=(()=>{class e{subscription=new Vt.yU;initialized=!1;zone=lr(os);pendingTasks=lr(Ec);initialize(){if(this.initialized)return;this.initialized=!0;let n=null;!this.zone.isStable&&!this.zone.hasPendingMacrotasks&&!this.zone.hasPendingMicrotasks&&(n=this.pendingTasks.add()),this.zone.runOutsideAngular(()=>{this.subscription.add(this.zone.onStable.subscribe(()=>{os.assertNotInAngularZone(),queueMicrotask(()=>{null!==n&&!this.zone.hasPendingMacrotasks&&!this.zone.hasPendingMicrotasks&&(this.pendingTasks.remove(n),n=null)})}))}),this.subscription.add(this.zone.onUnstable.subscribe(()=>{os.assertInAngularZone(),n??=this.pendingTasks.add()}))}ngOnDestroy(){this.subscription.unsubscribe()}static \u0275fac=function(l){return new(l||e)};static \u0275prov=ai({token:e,factory:e.\u0275fac,providedIn:"root"})}return e})(),Og=(()=>{class e{appRef=lr(hc);taskService=lr(Ec);ngZone=lr(os);zonelessEnabled=lr(gu);disableScheduling=lr(Od,{optional:!0})??!1;zoneIsDefined=typeof Zone<"u"&&!!Zone.root.run;schedulerTickApplyArgs=[{data:{__scheduler_tick__:!0}}];subscriptions=new Vt.yU;angularZoneId=this.zoneIsDefined?this.ngZone._inner?.get(Zu):null;scheduleInRootZone=!this.zonelessEnabled&&this.zoneIsDefined&&(lr(ic,{optional:!0})??!1);cancelScheduledCallback=null;useMicrotaskScheduler=!1;runningTick=!1;pendingRenderTaskId=null;constructor(){this.subscriptions.add(this.appRef.afterTick.subscribe(()=>{this.runningTick||this.cleanup()})),this.subscriptions.add(this.ngZone.onUnstable.subscribe(()=>{this.runningTick||this.cleanup()})),this.disableScheduling||=!this.zonelessEnabled&&(this.ngZone instanceof Rh||!this.zoneIsDefined)}notify(n){if(!this.zonelessEnabled&&5===n)return;let l=!1;switch(n){case 0:this.appRef.dirtyFlags|=2;break;case 3:case 2:case 4:case 5:case 1:this.appRef.dirtyFlags|=4;break;case 8:this.appRef.deferredDirtyFlags|=8;break;case 6:case 14:this.appRef.dirtyFlags|=2,l=!0;break;case 13:this.appRef.dirtyFlags|=16,l=!0;break;case 12:l=!0;break;default:this.appRef.dirtyFlags|=8}if(!this.shouldScheduleTick(l))return;const p=this.useMicrotaskScheduler?cm:Rd;this.pendingRenderTaskId=this.taskService.add(),this.cancelScheduledCallback=this.scheduleInRootZone?Zone.root.run(()=>p(()=>this.tick())):this.ngZone.runOutsideAngular(()=>p(()=>this.tick()))}shouldScheduleTick(n){return!(this.disableScheduling&&!n||this.appRef.destroyed||null!==this.pendingRenderTaskId||this.runningTick||this.appRef._runningTick||!this.zonelessEnabled&&this.zoneIsDefined&&Zone.current.get(Zu+this.angularZoneId))}tick(){if(this.runningTick||this.appRef.destroyed)return;if(0===this.appRef.dirtyFlags)return void this.cleanup();!this.zonelessEnabled&&7&this.appRef.dirtyFlags&&(this.appRef.dirtyFlags|=1);const n=this.taskService.add();try{this.ngZone.run(()=>{this.runningTick=!0,this.appRef._tick()},void 0,this.schedulerTickApplyArgs)}catch(l){throw this.taskService.remove(n),l}finally{this.cleanup()}this.useMicrotaskScheduler=!0,cm(()=>{this.useMicrotaskScheduler=!1,this.taskService.remove(n)})}ngOnDestroy(){this.subscriptions.unsubscribe(),this.cleanup()}cleanup(){if(this.runningTick=!1,this.cancelScheduledCallback?.(),this.cancelScheduledCallback=null,null!==this.pendingRenderTaskId){const n=this.pendingRenderTaskId;this.pendingRenderTaskId=null,this.taskService.remove(n)}}static \u0275fac=function(l){return new(l||e)};static \u0275prov=ai({token:e,factory:e.\u0275fac,providedIn:"root"})}return e})();const dw=new ht("",{providedIn:"root",factory:()=>lr(dw,bi.Optional|bi.SkipSelf)||function HI(){return typeof $localize<"u"&&$localize.locale||Bv}()}),WI=new ht("",{providedIn:"root",factory:()=>"USD"}),Kv=new ht("");function Gv(e){return!e.moduleRef}let sh=null;function JI(){return!1}let C2=(()=>class e{static __NG_ELEMENT_ID__=eO})();function eO(e){return function tO(e,t,n){if(Lo(e)&&!n){const l=K(e.index,t);return new og(l,l)}return 175&e.type?new og(t[vo],t):null}(Si(),En(),!(16&~e))}class T2{constructor(){}supports(t){return Sv(t)}create(t){return new sO(t)}}const oO=(e,t)=>t;class sO{length=0;collection;_linkedRecords=null;_unlinkedRecords=null;_previousItHead=null;_itHead=null;_itTail=null;_additionsHead=null;_additionsTail=null;_movesHead=null;_movesTail=null;_removalsHead=null;_removalsTail=null;_identityChangesHead=null;_identityChangesTail=null;_trackByFn;constructor(t){this._trackByFn=t||oO}forEachItem(t){let n;for(n=this._itHead;null!==n;n=n._next)t(n)}forEachOperation(t){let n=this._itHead,l=this._removalsHead,p=0,g=null;for(;n||l;){const x=!l||n&&n.currentIndex{x=this._trackByFn(p,k),null!==n&&Object.is(n.trackById,x)?(l&&(n=this._verifyReinsertion(n,k,x,p)),Object.is(n.item,k)||this._addIdentityChange(n,k)):(n=this._mismatch(n,k,x,p),l=!0),n=n._next,p++}),this.length=p;return this._truncate(n),this.collection=t,this.isDirty}get isDirty(){return null!==this._additionsHead||null!==this._movesHead||null!==this._removalsHead||null!==this._identityChangesHead}_reset(){if(this.isDirty){let t;for(t=this._previousItHead=this._itHead;null!==t;t=t._next)t._nextPrevious=t._next;for(t=this._additionsHead;null!==t;t=t._nextAdded)t.previousIndex=t.currentIndex;for(this._additionsHead=this._additionsTail=null,t=this._movesHead;null!==t;t=t._nextMoved)t.previousIndex=t.currentIndex;this._movesHead=this._movesTail=null,this._removalsHead=this._removalsTail=null,this._identityChangesHead=this._identityChangesTail=null}}_mismatch(t,n,l,p){let g;return null===t?g=this._itTail:(g=t._prev,this._remove(t)),null!==(t=null===this._unlinkedRecords?null:this._unlinkedRecords.get(l,null))?(Object.is(t.item,n)||this._addIdentityChange(t,n),this._reinsertAfter(t,g,p)):null!==(t=null===this._linkedRecords?null:this._linkedRecords.get(l,p))?(Object.is(t.item,n)||this._addIdentityChange(t,n),this._moveAfter(t,g,p)):t=this._addAfter(new aO(n,l),g,p),t}_verifyReinsertion(t,n,l,p){let g=null===this._unlinkedRecords?null:this._unlinkedRecords.get(l,null);return null!==g?t=this._reinsertAfter(g,t._prev,p):t.currentIndex!=p&&(t.currentIndex=p,this._addToMoves(t,p)),t}_truncate(t){for(;null!==t;){const n=t._next;this._addToRemovals(this._unlink(t)),t=n}null!==this._unlinkedRecords&&this._unlinkedRecords.clear(),null!==this._additionsTail&&(this._additionsTail._nextAdded=null),null!==this._movesTail&&(this._movesTail._nextMoved=null),null!==this._itTail&&(this._itTail._next=null),null!==this._removalsTail&&(this._removalsTail._nextRemoved=null),null!==this._identityChangesTail&&(this._identityChangesTail._nextIdentityChange=null)}_reinsertAfter(t,n,l){null!==this._unlinkedRecords&&this._unlinkedRecords.remove(t);const p=t._prevRemoved,g=t._nextRemoved;return null===p?this._removalsHead=g:p._nextRemoved=g,null===g?this._removalsTail=p:g._prevRemoved=p,this._insertAfter(t,n,l),this._addToMoves(t,l),t}_moveAfter(t,n,l){return this._unlink(t),this._insertAfter(t,n,l),this._addToMoves(t,l),t}_addAfter(t,n,l){return this._insertAfter(t,n,l),this._additionsTail=null===this._additionsTail?this._additionsHead=t:this._additionsTail._nextAdded=t,t}_insertAfter(t,n,l){const p=null===n?this._itHead:n._next;return t._next=p,t._prev=n,null===p?this._itTail=t:p._prev=t,null===n?this._itHead=t:n._next=t,null===this._linkedRecords&&(this._linkedRecords=new M2),this._linkedRecords.put(t),t.currentIndex=l,t}_remove(t){return this._addToRemovals(this._unlink(t))}_unlink(t){null!==this._linkedRecords&&this._linkedRecords.remove(t);const n=t._prev,l=t._next;return null===n?this._itHead=l:n._next=l,null===l?this._itTail=n:l._prev=n,t}_addToMoves(t,n){return t.previousIndex===n||(this._movesTail=null===this._movesTail?this._movesHead=t:this._movesTail._nextMoved=t),t}_addToRemovals(t){return null===this._unlinkedRecords&&(this._unlinkedRecords=new M2),this._unlinkedRecords.put(t),t.currentIndex=null,t._nextRemoved=null,null===this._removalsTail?(this._removalsTail=this._removalsHead=t,t._prevRemoved=null):(t._prevRemoved=this._removalsTail,this._removalsTail=this._removalsTail._nextRemoved=t),t}_addIdentityChange(t,n){return t.item=n,this._identityChangesTail=null===this._identityChangesTail?this._identityChangesHead=t:this._identityChangesTail._nextIdentityChange=t,t}}class aO{item;trackById;currentIndex=null;previousIndex=null;_nextPrevious=null;_prev=null;_next=null;_prevDup=null;_nextDup=null;_prevRemoved=null;_nextRemoved=null;_nextAdded=null;_nextMoved=null;_nextIdentityChange=null;constructor(t,n){this.item=t,this.trackById=n}}class lO{_head=null;_tail=null;add(t){null===this._head?(this._head=this._tail=t,t._nextDup=null,t._prevDup=null):(this._tail._nextDup=t,t._prevDup=this._tail,t._nextDup=null,this._tail=t)}get(t,n){let l;for(l=this._head;null!==l;l=l._nextDup)if((null===n||n<=l.currentIndex)&&Object.is(l.trackById,t))return l;return null}remove(t){const n=t._prevDup,l=t._nextDup;return null===n?this._head=l:n._nextDup=l,null===l?this._tail=n:l._prevDup=n,null===this._head}}class M2{map=new Map;put(t){const n=t.trackById;let l=this.map.get(n);l||(l=new lO,this.map.set(n,l)),l.add(t)}get(t,n){const p=this.map.get(t);return p?p.get(t,n):null}remove(t){const n=t.trackById;return this.map.get(n).remove(t)&&this.map.delete(n),t}get isEmpty(){return 0===this.map.size}clear(){this.map.clear()}}function k2(e,t,n){const l=e.previousIndex;if(null===l)return l;let p=0;return n&&l{if(n&&n.key===p)this._maybeAddToChanges(n,l),this._appendAfter=n,n=n._next;else{const g=this._getOrCreateRecordForKey(p,l);n=this._insertBeforeOrAppend(n,g)}}),n){n._prev&&(n._prev._next=null),this._removalsHead=n;for(let l=n;null!==l;l=l._nextRemoved)l===this._mapHead&&(this._mapHead=null),this._records.delete(l.key),l._nextRemoved=l._next,l.previousValue=l.currentValue,l.currentValue=null,l._prev=null,l._next=null}return this._changesTail&&(this._changesTail._nextChanged=null),this._additionsTail&&(this._additionsTail._nextAdded=null),this.isDirty}_insertBeforeOrAppend(t,n){if(t){const l=t._prev;return n._next=t,n._prev=l,t._prev=n,l&&(l._next=n),t===this._mapHead&&(this._mapHead=n),this._appendAfter=t,t}return this._appendAfter?(this._appendAfter._next=n,n._prev=this._appendAfter):this._mapHead=n,this._appendAfter=n,null}_getOrCreateRecordForKey(t,n){if(this._records.has(t)){const p=this._records.get(t);this._maybeAddToChanges(p,n);const g=p._prev,x=p._next;return g&&(g._next=x),x&&(x._prev=g),p._next=null,p._prev=null,p}const l=new uO(t);return this._records.set(t,l),l.currentValue=n,this._addToAdditions(l),l}_reset(){if(this.isDirty){let t;for(this._previousMapHead=this._mapHead,t=this._previousMapHead;null!==t;t=t._next)t._nextPrevious=t._next;for(t=this._changesHead;null!==t;t=t._nextChanged)t.previousValue=t.currentValue;for(t=this._additionsHead;null!=t;t=t._nextAdded)t.previousValue=t.currentValue;this._changesHead=this._changesTail=null,this._additionsHead=this._additionsTail=null,this._removalsHead=null}}_maybeAddToChanges(t,n){Object.is(n,t.currentValue)||(t.previousValue=t.currentValue,t.currentValue=n,this._addToChanges(t))}_addToAdditions(t){null===this._additionsHead?this._additionsHead=this._additionsTail=t:(this._additionsTail._nextAdded=t,this._additionsTail=t)}_addToChanges(t){null===this._changesHead?this._changesHead=this._changesTail=t:(this._changesTail._nextChanged=t,this._changesTail=t)}_forEach(t,n){t instanceof Map?t.forEach(n):Object.keys(t).forEach(l=>n(t[l],l))}}class uO{key;previousValue=null;currentValue=null;_nextPrevious=null;_next=null;_prev=null;_nextAdded=null;_nextRemoved=null;_nextChanged=null;constructor(t){this.key=t}}function O2(){return new _w([new T2])}let _w=(()=>{class e{factories;static \u0275prov=ai({token:e,providedIn:"root",factory:O2});constructor(n){this.factories=n}static create(n,l){if(null!=l){const p=l.factories.slice();n=n.concat(p)}return new e(n)}static extend(n){return{provide:e,useFactory:l=>e.create(n,l||O2()),deps:[[e,new Ts,new ca]]}}find(n){const l=this.factories.find(p=>p.supports(n));if(null!=l)return l;throw new Rn(901,!1)}}return e})();function R2(){return new vw([new I2])}let vw=(()=>{class e{static \u0275prov=ai({token:e,providedIn:"root",factory:R2});factories;constructor(n){this.factories=n}static create(n,l){if(l){const p=l.factories.slice();n=n.concat(p)}return new e(n)}static extend(n){return{provide:e,useFactory:l=>e.create(n,l||R2()),deps:[[e,new Ts,new ca]]}}find(n){const l=this.factories.find(p=>p.supports(n));if(l)return l;throw new Rn(901,!1)}}return e})();function CO(e){try{const{rootComponent:t,appProviders:n,platformProviders:l}=e,p=function qI(e=[]){if(sh)return sh;const t=function w2(e=[],t){return Qo.create({name:t,providers:[{provide:yl,useValue:"platform"},{provide:Kv,useValue:new Set([()=>sh=null])},...e]})}(e);return sh=t,function L1(){!function _t(e){yn=e}(()=>{throw new Rn(600,!1)})}(),function E2(e){const t=e.get(sd,null);$s(e,()=>{t?.forEach(n=>n())})}(t),t}(l),g=[lw({}),{provide:rc,useExisting:Og},...n||[]];return function v2(e){const t=Gv(e)?e.r3Injector:e.moduleRef.injector,n=t.get(os);return n.run(()=>{Gv(e)?e.r3Injector.resolveInjectorInitializers():e.moduleRef.resolveInjectorInitializers();const l=t.get(Cc,null);let p;if(n.runOutsideAngular(()=>{p=n.onError.subscribe({next:g=>{l.handleError(g)}})}),Gv(e)){const g=()=>t.destroy(),x=e.platformInjector.get(Kv);x.add(g),t.onDestroy(()=>{p.unsubscribe(),x.delete(g)})}else{const g=()=>e.moduleRef.destroy(),x=e.platformInjector.get(Kv);x.add(g),e.moduleRef.onDestroy(()=>{vv(e.allPlatformModules,e.moduleRef),p.unsubscribe(),x.delete(g)})}return function UA(e,t,n){try{const l=n();return jb(l)?l.catch(p=>{throw t.runOutsideAngular(()=>e.handleError(p)),p}):l}catch(l){throw t.runOutsideAngular(()=>e.handleError(l)),l}}(l,n,()=>{const g=t.get(R1);return g.runInitializers(),g.donePromise.then(()=>{if(function KM(e){"string"==typeof e&&(Sx=e.toLowerCase().replace(/_/g,"-"))}(t.get(dw,Bv)||Bv),Gv(e)){const k=t.get(hc);return void 0!==e.rootComponent&&k.bootstrap(e.rootComponent),k}return function YI(e,t){const n=e.injector.get(hc);if(e._bootstrapComponents.length>0)e._bootstrapComponents.forEach(l=>n.bootstrap(l));else{if(!e.instance.ngDoBootstrap)throw new Rn(-403,!1);e.instance.ngDoBootstrap(n)}t.push(e)}(e.moduleRef,e.allPlatformModules),e.moduleRef})})})}({r3Injector:new m1({providers:g,parent:p,debugName:"",runEnvironmentInitializers:!1}).injector,platformInjector:p,rootComponent:t})}catch(t){return Promise.reject(t)}}function GO(e){return"boolean"==typeof e?e:null!=e&&"false"!==e}function XO(e,t=NaN){return isNaN(parseFloat(e))||isNaN(Number(e))?t:Number(e)}function xw(e,t){oi("NgSignals");const n=bt(e);return t?.equal&&(n[C].equal=t.equal),n}function Zp(e){const t=T(null);try{return e()}finally{T(t)}}let aD=(()=>class e{view;node;constructor(n,l){this.view=n,this.node=l}static __NG_ELEMENT_ID__=eR})();function eR(){return new aD(En(),Si())}let nR=(()=>{class e extends N1{pendingTasks=lr(Ec);taskId=null;schedule(n){super.schedule(n),null===this.taskId&&(this.taskId=this.pendingTasks.add(),queueMicrotask(()=>this.flush()))}flush(){try{super.flush()}finally{null!==this.taskId&&(this.pendingTasks.remove(this.taskId),this.taskId=null)}}static \u0275prov=ai({token:e,providedIn:"root",factory:()=>new e})}return e})();class rR{scheduler;effectFn;zone;injector;unregisterOnDestroy;watcher;constructor(t,n,l,p,g,x){this.scheduler=t,this.effectFn=n,this.zone=l,this.injector=g,this.watcher=function Ee(e,t,n){const l=Object.create(Xt);n&&(l.consumerAllowSignalWrites=!0),l.fn=e,l.schedule=t;const p=B=>{l.cleanupFn=B};return l.ref={notify:()=>ae(l),run:()=>{if(null===l.fn)return;if(function M(){return y}())throw new Error("Schedulers cannot synchronously execute watches while scheduling.");if(l.dirty=!1,l.hasRun&&!xe(l))return;l.hasRun=!0;const B=be(l);try{l.cleanupFn(),l.cleanupFn=st,l.fn(p)}finally{Oe(l,B)}},cleanup:()=>l.cleanupFn(),destroy:()=>function x(B){(function g(B){return null===B.fn&&null===B.schedule})(B)||(De(B),B.cleanupFn(),B.fn=null,B.schedule=null,B.cleanupFn=st)}(l),[C]:l},l.ref}(k=>this.runEffect(k),()=>this.schedule(),x),this.unregisterOnDestroy=p?.onDestroy(()=>this.destroy())}runEffect(t){try{this.effectFn(t)}catch(n){this.injector.get(Cc,null,{optional:!0})?.handleError(n)}}run(){this.watcher.run()}schedule(){this.scheduler.schedule(this)}destroy(){this.watcher.destroy(),this.unregisterOnDestroy?.()}}let Cw=!1;class sR{[C];constructor(t){this[C]=t}destroy(){this[C].destroy()}}function Dw(e,t){if(Cw)return function oR(e,t){oi("NgSignals"),!t?.injector&&Sa();const n=t?.injector??lr(Qo),l=!0!==t?.manualCleanup?n.get(ws):null,p=new rR(n.get(nR),e,typeof Zone>"u"?null:Zone.current,l,n,t?.allowSignalWrites??!1),g=n.get(C2,null,{optional:!0});return g&&8&g._lView[Sr]?(g._lView[ne]??=[]).push(p.watcher.notify):p.watcher.notify(),p}(e,t);oi("NgSignals"),!t?.injector&&Sa();const n=t?.injector??lr(Qo);let p,l=!0!==t?.manualCleanup?n.get(ws):null;const g=n.get(aD,null,{optional:!0}),x=n.get(rc);return null===g||t?.forceRoot?p=function uR(e,t,n){const l=Object.create(aR);return l.fn=e,l.scheduler=t,l.notifier=n,l.zone=typeof Zone<"u"?Zone.current:null,l.scheduler.schedule(l),l.notifier.notify(13),l}(e,n.get(Hb),x):(p=function cR(e,t,n){const l=Object.create(lR);return l.view=e,l.zone=typeof Zone<"u"?Zone.current:null,l.notifier=t,l.fn=n,e[ye]??=new Set,e[ye].add(l),l.consumerMarkedDirty(l),l}(g.view,x,e),l instanceof Fc&&l._lView===g.view&&(l=null)),p.injector=n,null!==l&&(p.onDestroyFn=l.onDestroy(()=>p.destroy())),new sR(p)}const lD={...L,consumerIsAlwaysLive:!0,consumerAllowSignalWrites:!0,dirty:!0,hasRun:!1,cleanupFns:void 0,zone:null,onDestroyFn:_u,run(){if(this.dirty=!1,this.hasRun&&!xe(this))return;this.hasRun=!0;const e=l=>(this.cleanupFns??=[]).push(l),t=be(this),n=ql(!1);try{this.maybeCleanup(),this.fn(e)}finally{ql(n),Oe(this,t)}},maybeCleanup(){if(this.cleanupFns?.length)try{for(;this.cleanupFns.length;)this.cleanupFns.pop()()}finally{this.cleanupFns=[]}}},aR={...lD,consumerMarkedDirty(){this.scheduler.schedule(this),this.notifier.notify(13)},destroy(){De(this),this.onDestroyFn(),this.maybeCleanup()}},lR={...lD,consumerMarkedDirty(){this.view[Sr]|=8192,Is(this.view),this.notifier.notify(14)},destroy(){De(this),this.onDestroyFn(),this.maybeCleanup(),this.view[ye]?.delete(this)}};function vR(e,t){const n=zr(e),l=t.elementInjector||_i();return new hg(n).create(l,t.projectableNodes,t.hostElement,t.environmentInjector)}function yR(e){const t=zr(e);if(!t)return null;const n=new hg(t);return{get selector(){return n.selector},get type(){return n.componentType},get inputs(){return n.inputs},get outputs(){return n.outputs},get ngContentSelectors(){return n.ngContentSelectors},get isStandalone(){return t.standalone},get isSignal(){return t.signals}}}},936:(o,s,r)=>{"use strict";r.d(s,{BC:()=>en,JD:()=>Ao,Q0:()=>aa,X1:()=>da,YN:()=>$a,YS:()=>Ba,cV:()=>Nn,cb:()=>kn,cz:()=>me,hs:()=>wr,j4:()=>Ds,k0:()=>xe,kq:()=>M,l_:()=>Rs,me:()=>pe,ok:()=>Ro,qT:()=>Li,tU:()=>Bn,vO:()=>Mt,vS:()=>sa,xq:()=>Aa,ze:()=>Ho});var i=r(3107),a=r(4460),c=r(1787),y=r(2653),w=r(8447),C=r(7947);let T=(()=>{class de{_renderer;_elementRef;onChange=Y=>{};onTouched=()=>{};constructor(Y,Ue){this._renderer=Y,this._elementRef=Ue}setProperty(Y,Ue){this._renderer.setProperty(this._elementRef.nativeElement,Y,Ue)}registerOnTouched(Y){this.onTouched=Y}registerOnChange(Y){this.onChange=Y}setDisabledState(Y){this.setProperty("disabled",Y)}static \u0275fac=function(Ue){return new(Ue||de)(i.rXU(i.sFG),i.rXU(i.aKT))};static \u0275dir=i.FsC({type:de})}return de})(),S=(()=>{class de extends T{static \u0275fac=(()=>{let Y;return function(jt){return(Y||(Y=i.xGo(de)))(jt||de)}})();static \u0275dir=i.FsC({type:de,features:[i.Vt3]})}return de})();const M=new i.nKC(""),Z={provide:M,useExisting:(0,i.Rfq)(()=>pe),multi:!0},re=new i.nKC("");let pe=(()=>{class de extends T{_compositionMode;_composing=!1;constructor(Y,Ue,jt){super(Y,Ue),this._compositionMode=jt,null==this._compositionMode&&(this._compositionMode=!function q(){const de=(0,a.QT)()?(0,a.QT)().getUserAgent():"";return/android (\d+)/.test(de.toLowerCase())}())}writeValue(Y){this.setProperty("value",Y??"")}_handleInput(Y){(!this._compositionMode||this._compositionMode&&!this._composing)&&this.onChange(Y)}_compositionStart(){this._composing=!0}_compositionEnd(Y){this._composing=!1,this._compositionMode&&this.onChange(Y)}static \u0275fac=function(Ue){return new(Ue||de)(i.rXU(i.sFG),i.rXU(i.aKT),i.rXU(re,8))};static \u0275dir=i.FsC({type:de,selectors:[["input","formControlName","",3,"type","checkbox"],["textarea","formControlName",""],["input","formControl","",3,"type","checkbox"],["textarea","formControl",""],["input","ngModel","",3,"type","checkbox"],["textarea","ngModel",""],["","ngDefaultControl",""]],hostBindings:function(Ue,jt){1&Ue&&i.bIt("input",function(Jr){return jt._handleInput(Jr.target.value)})("blur",function(){return jt.onTouched()})("compositionstart",function(){return jt._compositionStart()})("compositionend",function(Jr){return jt._compositionEnd(Jr.target.value)})},standalone:!1,features:[i.Jv_([Z]),i.Vt3]})}return de})();function se(de){return null==de||("string"==typeof de||Array.isArray(de))&&0===de.length}function ae(de){return null!=de&&"number"==typeof de.length}const me=new i.nKC(""),be=new i.nKC(""),Oe=/^(?=.{1,254}$)(?=.{1,64}@)[a-zA-Z0-9!#$%&'*+/=?^_`{|}~-]+(?:\.[a-zA-Z0-9!#$%&'*+/=?^_`{|}~-]+)*@[a-zA-Z0-9](?:[a-zA-Z0-9-]{0,61}[a-zA-Z0-9])?(?:\.[a-zA-Z0-9](?:[a-zA-Z0-9-]{0,61}[a-zA-Z0-9])?)*$/;class xe{static min(he){return function De(de){return he=>{if(se(he.value)||se(de))return null;const Y=parseFloat(he.value);return!isNaN(Y)&&Y{if(se(he.value)||se(de))return null;const Y=parseFloat(he.value);return!isNaN(Y)&&Y>de?{max:{max:de,actual:he.value}}:null}}(he)}static required(he){return ue(he)}static requiredTrue(he){return Ce(he)}static email(he){return function Be(de){return se(de.value)||Oe.test(de.value)?null:{email:!0}}(he)}static minLength(he){return function at(de){return he=>se(he.value)||!ae(he.value)?null:he.value.length{if(se(Ue.value))return null;const jt=Ue.value;return he.test(jt)?null:{pattern:{requiredPattern:Y,actualValue:jt}}}}(he)}static nullValidator(he){return null}static compose(he){return _t(he)}static composeAsync(he){return $e(he)}}function ue(de){return se(de.value)?{required:!0}:null}function Ce(de){return!0===de.value?null:{required:!0}}function dt(de){return he=>ae(he.value)&&he.value.length>de?{maxlength:{requiredLength:de,actualLength:he.value.length}}:null}function lt(de){return null}function rn(de){return null!=de}function gn(de){return(0,i.jNT)(de)?(0,c.H)(de):de}function bn(de){let he={};return de.forEach(Y=>{he=null!=Y?{...he,...Y}:he}),0===Object.keys(he).length?null:he}function Vn(de,he){return he.map(Y=>Y(de))}function qe(de){return de.map(he=>function yn(de){return!de.validate}(he)?he:Y=>he.validate(Y))}function _t(de){if(!de)return null;const he=de.filter(rn);return 0==he.length?null:function(Y){return bn(Vn(Y,he))}}function ze(de){return null!=de?_t(qe(de)):null}function $e(de){if(!de)return null;const he=de.filter(rn);return 0==he.length?null:function(Y){const Ue=Vn(Y,he).map(gn);return(0,y.p)(Ue).pipe((0,C.T)(bn))}}function Ft(de){return null!=de?$e(qe(de)):null}function Ke(de,he){return null===de?[he]:Array.isArray(de)?[...de,he]:[de,he]}function Ze(de){return de._rawValidators}function it(de){return de._rawAsyncValidators}function Ot(de){return de?Array.isArray(de)?de:[de]:[]}function $t(de,he){return Array.isArray(de)?de.includes(he):de===he}function Te(de,he){const Y=Ot(he);return Ot(de).forEach(jt=>{$t(Y,jt)||Y.push(jt)}),Y}function Ee(de,he){return Ot(he).filter(Y=>!$t(de,Y))}class st{get value(){return this.control?this.control.value:null}get valid(){return this.control?this.control.valid:null}get invalid(){return this.control?this.control.invalid:null}get pending(){return this.control?this.control.pending:null}get disabled(){return this.control?this.control.disabled:null}get enabled(){return this.control?this.control.enabled:null}get errors(){return this.control?this.control.errors:null}get pristine(){return this.control?this.control.pristine:null}get dirty(){return this.control?this.control.dirty:null}get touched(){return this.control?this.control.touched:null}get status(){return this.control?this.control.status:null}get untouched(){return this.control?this.control.untouched:null}get statusChanges(){return this.control?this.control.statusChanges:null}get valueChanges(){return this.control?this.control.valueChanges:null}get path(){return null}_composedValidatorFn;_composedAsyncValidatorFn;_rawValidators=[];_rawAsyncValidators=[];_setValidators(he){this._rawValidators=he||[],this._composedValidatorFn=ze(this._rawValidators)}_setAsyncValidators(he){this._rawAsyncValidators=he||[],this._composedAsyncValidatorFn=Ft(this._rawAsyncValidators)}get validator(){return this._composedValidatorFn||null}get asyncValidator(){return this._composedAsyncValidatorFn||null}_onDestroyCallbacks=[];_registerOnDestroy(he){this._onDestroyCallbacks.push(he)}_invokeOnDestroyCallbacks(){this._onDestroyCallbacks.forEach(he=>he()),this._onDestroyCallbacks=[]}reset(he=void 0){this.control&&this.control.reset(he)}hasError(he,Y){return!!this.control&&this.control.hasError(he,Y)}getError(he,Y){return this.control?this.control.getError(he,Y):null}}class Xt extends st{name;get formDirective(){return null}get path(){return null}}class Mt extends st{_parent=null;name=null;valueAccessor=null}class Kt{_cd;constructor(he){this._cd=he}get isTouched(){return this._cd?.control?._touched?.(),!!this._cd?.control?.touched}get isUntouched(){return!!this._cd?.control?.untouched}get isPristine(){return this._cd?.control?._pristine?.(),!!this._cd?.control?.pristine}get isDirty(){return!!this._cd?.control?.dirty}get isValid(){return this._cd?.control?._status?.(),!!this._cd?.control?.valid}get isInvalid(){return!!this._cd?.control?.invalid}get isPending(){return!!this._cd?.control?.pending}get isSubmitted(){return this._cd?._submitted?.(),!!this._cd?.submitted}}let en=(()=>{class de extends Kt{constructor(Y){super(Y)}static \u0275fac=function(Ue){return new(Ue||de)(i.rXU(Mt,2))};static \u0275dir=i.FsC({type:de,selectors:[["","formControlName",""],["","ngModel",""],["","formControl",""]],hostVars:14,hostBindings:function(Ue,jt){2&Ue&&i.AVh("ng-untouched",jt.isUntouched)("ng-touched",jt.isTouched)("ng-pristine",jt.isPristine)("ng-dirty",jt.isDirty)("ng-valid",jt.isValid)("ng-invalid",jt.isInvalid)("ng-pending",jt.isPending)},standalone:!1,features:[i.Vt3]})}return de})(),kn=(()=>{class de extends Kt{constructor(Y){super(Y)}static \u0275fac=function(Ue){return new(Ue||de)(i.rXU(Xt,10))};static \u0275dir=i.FsC({type:de,selectors:[["","formGroupName",""],["","formArrayName",""],["","ngModelGroup",""],["","formGroup",""],["form",3,"ngNoForm",""],["","ngForm",""]],hostVars:16,hostBindings:function(Ue,jt){2&Ue&&i.AVh("ng-untouched",jt.isUntouched)("ng-touched",jt.isTouched)("ng-pristine",jt.isPristine)("ng-dirty",jt.isDirty)("ng-valid",jt.isValid)("ng-invalid",jt.isInvalid)("ng-pending",jt.isPending)("ng-submitted",jt.isSubmitted)},standalone:!1,features:[i.Vt3]})}return de})();const In="VALID",sr="INVALID",xn="PENDING",Hr="DISABLED";class Tr{}class Vr extends Tr{value;source;constructor(he,Y){super(),this.value=he,this.source=Y}}class vt extends Tr{pristine;source;constructor(he,Y){super(),this.pristine=he,this.source=Y}}class Wt extends Tr{touched;source;constructor(he,Y){super(),this.touched=he,this.source=Y}}class Re extends Tr{status;source;constructor(he,Y){super(),this.status=he,this.source=Y}}class Ge extends Tr{source;constructor(he){super(),this.source=he}}class Ve extends Tr{source;constructor(he){super(),this.source=he}}function Dt(de){return(qn(de)?de.validators:de)||null}function Bt(de,he){return(qn(he)?he.asyncValidators:de)||null}function qn(de){return null!=de&&!Array.isArray(de)&&"object"==typeof de}function Er(de,he,Y){const Ue=de.controls;if(!(he?Object.keys(Ue):Ue).length)throw new i.wOt(1e3,"");if(!Ue[Y])throw new i.wOt(1001,"")}function si(de,he,Y){de._forEachChild((Ue,jt)=>{if(void 0===Y[jt])throw new i.wOt(1002,"")})}class hi{_pendingDirty=!1;_hasOwnPendingAsyncValidator=null;_pendingTouched=!1;_onCollectionChange=()=>{};_updateOn;_parent=null;_asyncValidationSubscription;_composedValidatorFn;_composedAsyncValidatorFn;_rawValidators;_rawAsyncValidators;value;constructor(he,Y){this._assignValidators(he),this._assignAsyncValidators(Y)}get validator(){return this._composedValidatorFn}set validator(he){this._rawValidators=this._composedValidatorFn=he}get asyncValidator(){return this._composedAsyncValidatorFn}set asyncValidator(he){this._rawAsyncValidators=this._composedAsyncValidatorFn=he}get parent(){return this._parent}get status(){return(0,i.O8t)(this.statusReactive)}set status(he){(0,i.O8t)(()=>this.statusReactive.set(he))}_status=(0,i.EWP)(()=>this.statusReactive());statusReactive=(0,i.vPA)(void 0);get valid(){return this.status===In}get invalid(){return this.status===sr}get pending(){return this.status==xn}get disabled(){return this.status===Hr}get enabled(){return this.status!==Hr}errors;get pristine(){return(0,i.O8t)(this.pristineReactive)}set pristine(he){(0,i.O8t)(()=>this.pristineReactive.set(he))}_pristine=(0,i.EWP)(()=>this.pristineReactive());pristineReactive=(0,i.vPA)(!0);get dirty(){return!this.pristine}get touched(){return(0,i.O8t)(this.touchedReactive)}set touched(he){(0,i.O8t)(()=>this.touchedReactive.set(he))}_touched=(0,i.EWP)(()=>this.touchedReactive());touchedReactive=(0,i.vPA)(!1);get untouched(){return!this.touched}_events=new w.B;events=this._events.asObservable();valueChanges;statusChanges;get updateOn(){return this._updateOn?this._updateOn:this.parent?this.parent.updateOn:"change"}setValidators(he){this._assignValidators(he)}setAsyncValidators(he){this._assignAsyncValidators(he)}addValidators(he){this.setValidators(Te(he,this._rawValidators))}addAsyncValidators(he){this.setAsyncValidators(Te(he,this._rawAsyncValidators))}removeValidators(he){this.setValidators(Ee(he,this._rawValidators))}removeAsyncValidators(he){this.setAsyncValidators(Ee(he,this._rawAsyncValidators))}hasValidator(he){return $t(this._rawValidators,he)}hasAsyncValidator(he){return $t(this._rawAsyncValidators,he)}clearValidators(){this.validator=null}clearAsyncValidators(){this.asyncValidator=null}markAsTouched(he={}){const Y=!1===this.touched;this.touched=!0;const Ue=he.sourceControl??this;this._parent&&!he.onlySelf&&this._parent.markAsTouched({...he,sourceControl:Ue}),Y&&!1!==he.emitEvent&&this._events.next(new Wt(!0,Ue))}markAllAsTouched(he={}){this.markAsTouched({onlySelf:!0,emitEvent:he.emitEvent,sourceControl:this}),this._forEachChild(Y=>Y.markAllAsTouched(he))}markAsUntouched(he={}){const Y=!0===this.touched;this.touched=!1,this._pendingTouched=!1;const Ue=he.sourceControl??this;this._forEachChild(jt=>{jt.markAsUntouched({onlySelf:!0,emitEvent:he.emitEvent,sourceControl:Ue})}),this._parent&&!he.onlySelf&&this._parent._updateTouched(he,Ue),Y&&!1!==he.emitEvent&&this._events.next(new Wt(!1,Ue))}markAsDirty(he={}){const Y=!0===this.pristine;this.pristine=!1;const Ue=he.sourceControl??this;this._parent&&!he.onlySelf&&this._parent.markAsDirty({...he,sourceControl:Ue}),Y&&!1!==he.emitEvent&&this._events.next(new vt(!1,Ue))}markAsPristine(he={}){const Y=!1===this.pristine;this.pristine=!0,this._pendingDirty=!1;const Ue=he.sourceControl??this;this._forEachChild(jt=>{jt.markAsPristine({onlySelf:!0,emitEvent:he.emitEvent})}),this._parent&&!he.onlySelf&&this._parent._updatePristine(he,Ue),Y&&!1!==he.emitEvent&&this._events.next(new vt(!0,Ue))}markAsPending(he={}){this.status=xn;const Y=he.sourceControl??this;!1!==he.emitEvent&&(this._events.next(new Re(this.status,Y)),this.statusChanges.emit(this.status)),this._parent&&!he.onlySelf&&this._parent.markAsPending({...he,sourceControl:Y})}disable(he={}){const Y=this._parentMarkedDirty(he.onlySelf);this.status=Hr,this.errors=null,this._forEachChild(jt=>{jt.disable({...he,onlySelf:!0})}),this._updateValue();const Ue=he.sourceControl??this;!1!==he.emitEvent&&(this._events.next(new Vr(this.value,Ue)),this._events.next(new Re(this.status,Ue)),this.valueChanges.emit(this.value),this.statusChanges.emit(this.status)),this._updateAncestors({...he,skipPristineCheck:Y},this),this._onDisabledChange.forEach(jt=>jt(!0))}enable(he={}){const Y=this._parentMarkedDirty(he.onlySelf);this.status=In,this._forEachChild(Ue=>{Ue.enable({...he,onlySelf:!0})}),this.updateValueAndValidity({onlySelf:!0,emitEvent:he.emitEvent}),this._updateAncestors({...he,skipPristineCheck:Y},this),this._onDisabledChange.forEach(Ue=>Ue(!1))}_updateAncestors(he,Y){this._parent&&!he.onlySelf&&(this._parent.updateValueAndValidity(he),he.skipPristineCheck||this._parent._updatePristine({},Y),this._parent._updateTouched({},Y))}setParent(he){this._parent=he}getRawValue(){return this.value}updateValueAndValidity(he={}){if(this._setInitialStatus(),this._updateValue(),this.enabled){const Ue=this._cancelExistingSubscription();this.errors=this._runValidator(),this.status=this._calculateStatus(),(this.status===In||this.status===xn)&&this._runAsyncValidator(Ue,he.emitEvent)}const Y=he.sourceControl??this;!1!==he.emitEvent&&(this._events.next(new Vr(this.value,Y)),this._events.next(new Re(this.status,Y)),this.valueChanges.emit(this.value),this.statusChanges.emit(this.status)),this._parent&&!he.onlySelf&&this._parent.updateValueAndValidity({...he,sourceControl:Y})}_updateTreeValidity(he={emitEvent:!0}){this._forEachChild(Y=>Y._updateTreeValidity(he)),this.updateValueAndValidity({onlySelf:!0,emitEvent:he.emitEvent})}_setInitialStatus(){this.status=this._allControlsDisabled()?Hr:In}_runValidator(){return this.validator?this.validator(this):null}_runAsyncValidator(he,Y){if(this.asyncValidator){this.status=xn,this._hasOwnPendingAsyncValidator={emitEvent:!1!==Y};const Ue=gn(this.asyncValidator(this));this._asyncValidationSubscription=Ue.subscribe(jt=>{this._hasOwnPendingAsyncValidator=null,this.setErrors(jt,{emitEvent:Y,shouldHaveEmitted:he})})}}_cancelExistingSubscription(){if(this._asyncValidationSubscription){this._asyncValidationSubscription.unsubscribe();const he=this._hasOwnPendingAsyncValidator?.emitEvent??!1;return this._hasOwnPendingAsyncValidator=null,he}return!1}setErrors(he,Y={}){this.errors=he,this._updateControlsErrors(!1!==Y.emitEvent,this,Y.shouldHaveEmitted)}get(he){let Y=he;return null==Y||(Array.isArray(Y)||(Y=Y.split(".")),0===Y.length)?null:Y.reduce((Ue,jt)=>Ue&&Ue._find(jt),this)}getError(he,Y){const Ue=Y?this.get(Y):this;return Ue&&Ue.errors?Ue.errors[he]:null}hasError(he,Y){return!!this.getError(he,Y)}get root(){let he=this;for(;he._parent;)he=he._parent;return he}_updateControlsErrors(he,Y,Ue){this.status=this._calculateStatus(),he&&this.statusChanges.emit(this.status),(he||Ue)&&this._events.next(new Re(this.status,Y)),this._parent&&this._parent._updateControlsErrors(he,Y,Ue)}_initObservables(){this.valueChanges=new i.bkB,this.statusChanges=new i.bkB}_calculateStatus(){return this._allControlsDisabled()?Hr:this.errors?sr:this._hasOwnPendingAsyncValidator||this._anyControlsHaveStatus(xn)?xn:this._anyControlsHaveStatus(sr)?sr:In}_anyControlsHaveStatus(he){return this._anyControls(Y=>Y.status===he)}_anyControlsDirty(){return this._anyControls(he=>he.dirty)}_anyControlsTouched(){return this._anyControls(he=>he.touched)}_updatePristine(he,Y){const Ue=!this._anyControlsDirty(),jt=this.pristine!==Ue;this.pristine=Ue,this._parent&&!he.onlySelf&&this._parent._updatePristine(he,Y),jt&&this._events.next(new vt(this.pristine,Y))}_updateTouched(he={},Y){this.touched=this._anyControlsTouched(),this._events.next(new Wt(this.touched,Y)),this._parent&&!he.onlySelf&&this._parent._updateTouched(he,Y)}_onDisabledChange=[];_registerOnCollectionChange(he){this._onCollectionChange=he}_setUpdateStrategy(he){qn(he)&&null!=he.updateOn&&(this._updateOn=he.updateOn)}_parentMarkedDirty(he){return!he&&!(!this._parent||!this._parent.dirty)&&!this._parent._anyControlsDirty()}_find(he){return null}_assignValidators(he){this._rawValidators=Array.isArray(he)?he.slice():he,this._composedValidatorFn=function ct(de){return Array.isArray(de)?ze(de):de||null}(this._rawValidators)}_assignAsyncValidators(he){this._rawAsyncValidators=Array.isArray(he)?he.slice():he,this._composedAsyncValidatorFn=function wn(de){return Array.isArray(de)?Ft(de):de||null}(this._rawAsyncValidators)}}class Zi extends hi{constructor(he,Y,Ue){super(Dt(Y),Bt(Ue,Y)),this.controls=he,this._initObservables(),this._setUpdateStrategy(Y),this._setUpControls(),this.updateValueAndValidity({onlySelf:!0,emitEvent:!!this.asyncValidator})}controls;registerControl(he,Y){return this.controls[he]?this.controls[he]:(this.controls[he]=Y,Y.setParent(this),Y._registerOnCollectionChange(this._onCollectionChange),Y)}addControl(he,Y,Ue={}){this.registerControl(he,Y),this.updateValueAndValidity({emitEvent:Ue.emitEvent}),this._onCollectionChange()}removeControl(he,Y={}){this.controls[he]&&this.controls[he]._registerOnCollectionChange(()=>{}),delete this.controls[he],this.updateValueAndValidity({emitEvent:Y.emitEvent}),this._onCollectionChange()}setControl(he,Y,Ue={}){this.controls[he]&&this.controls[he]._registerOnCollectionChange(()=>{}),delete this.controls[he],Y&&this.registerControl(he,Y),this.updateValueAndValidity({emitEvent:Ue.emitEvent}),this._onCollectionChange()}contains(he){return this.controls.hasOwnProperty(he)&&this.controls[he].enabled}setValue(he,Y={}){si(this,0,he),Object.keys(he).forEach(Ue=>{Er(this,!0,Ue),this.controls[Ue].setValue(he[Ue],{onlySelf:!0,emitEvent:Y.emitEvent})}),this.updateValueAndValidity(Y)}patchValue(he,Y={}){null!=he&&(Object.keys(he).forEach(Ue=>{const jt=this.controls[Ue];jt&&jt.patchValue(he[Ue],{onlySelf:!0,emitEvent:Y.emitEvent})}),this.updateValueAndValidity(Y))}reset(he={},Y={}){this._forEachChild((Ue,jt)=>{Ue.reset(he?he[jt]:null,{onlySelf:!0,emitEvent:Y.emitEvent})}),this._updatePristine(Y,this),this._updateTouched(Y,this),this.updateValueAndValidity(Y)}getRawValue(){return this._reduceChildren({},(he,Y,Ue)=>(he[Ue]=Y.getRawValue(),he))}_syncPendingControls(){let he=this._reduceChildren(!1,(Y,Ue)=>!!Ue._syncPendingControls()||Y);return he&&this.updateValueAndValidity({onlySelf:!0}),he}_forEachChild(he){Object.keys(this.controls).forEach(Y=>{const Ue=this.controls[Y];Ue&&he(Ue,Y)})}_setUpControls(){this._forEachChild(he=>{he.setParent(this),he._registerOnCollectionChange(this._onCollectionChange)})}_updateValue(){this.value=this._reduceValue()}_anyControls(he){for(const[Y,Ue]of Object.entries(this.controls))if(this.contains(Y)&&he(Ue))return!0;return!1}_reduceValue(){return this._reduceChildren({},(Y,Ue,jt)=>((Ue.enabled||this.disabled)&&(Y[jt]=Ue.value),Y))}_reduceChildren(he,Y){let Ue=he;return this._forEachChild((jt,br)=>{Ue=Y(Ue,jt,br)}),Ue}_allControlsDisabled(){for(const he of Object.keys(this.controls))if(this.controls[he].enabled)return!1;return Object.keys(this.controls).length>0||this.disabled}_find(he){return this.controls.hasOwnProperty(he)?this.controls[he]:null}}class Rt extends Zi{}const mn=new i.nKC("CallSetDisabledState",{providedIn:"root",factory:()=>dr}),dr="always";function Co(de,he){return[...he.path,de]}function Ni(de,he,Y=dr){qo(de,he),he.valueAccessor.writeValue(de.value),(de.disabled||"always"===Y)&&he.valueAccessor.setDisabledState?.(de.disabled),function Jo(de,he){he.valueAccessor.registerOnChange(Y=>{de._pendingValue=Y,de._pendingChange=!0,de._pendingDirty=!0,"change"===de.updateOn&&oa(de,he)})}(de,he),function ao(de,he){const Y=(Ue,jt)=>{he.valueAccessor.writeValue(Ue),jt&&he.viewToModelUpdate(Ue)};de.registerOnChange(Y),he._registerOnDestroy(()=>{de._unregisterOnChange(Y)})}(de,he),function Fo(de,he){he.valueAccessor.registerOnTouched(()=>{de._pendingTouched=!0,"blur"===de.updateOn&&de._pendingChange&&oa(de,he),"submit"!==de.updateOn&&de.markAsTouched()})}(de,he),function ai(de,he){if(he.valueAccessor.setDisabledState){const Y=Ue=>{he.valueAccessor.setDisabledState(Ue)};de.registerOnDisabledChange(Y),he._registerOnDestroy(()=>{de._unregisterOnDisabledChange(Y)})}}(de,he)}function ds(de,he,Y=!0){const Ue=()=>{};he.valueAccessor&&(he.valueAccessor.registerOnChange(Ue),he.valueAccessor.registerOnTouched(Ue)),fo(de,he),de&&(he._invokeOnDestroyCallbacks(),de._registerOnCollectionChange(()=>{}))}function $o(de,he){de.forEach(Y=>{Y.registerOnValidatorChange&&Y.registerOnValidatorChange(he)})}function qo(de,he){const Y=Ze(de);null!==he.validator?de.setValidators(Ke(Y,he.validator)):"function"==typeof Y&&de.setValidators([Y]);const Ue=it(de);null!==he.asyncValidator?de.setAsyncValidators(Ke(Ue,he.asyncValidator)):"function"==typeof Ue&&de.setAsyncValidators([Ue]);const jt=()=>de.updateValueAndValidity();$o(he._rawValidators,jt),$o(he._rawAsyncValidators,jt)}function fo(de,he){let Y=!1;if(null!==de){if(null!==he.validator){const jt=Ze(de);if(Array.isArray(jt)&&jt.length>0){const br=jt.filter(Jr=>Jr!==he.validator);br.length!==jt.length&&(Y=!0,de.setValidators(br))}}if(null!==he.asyncValidator){const jt=it(de);if(Array.isArray(jt)&&jt.length>0){const br=jt.filter(Jr=>Jr!==he.asyncValidator);br.length!==jt.length&&(Y=!0,de.setAsyncValidators(br))}}}const Ue=()=>{};return $o(he._rawValidators,Ue),$o(he._rawAsyncValidators,Ue),Y}function oa(de,he){de._pendingDirty&&de.markAsDirty(),de.setValue(de._pendingValue,{emitModelToViewChange:!1}),he.viewToModelUpdate(de._pendingValue),de._pendingChange=!1}function po(de,he){qo(de,he)}function Ye(de,he){if(!de.hasOwnProperty("model"))return!1;const Y=de.model;return!!Y.isFirstChange()||!Object.is(he,Y.currentValue)}function gt(de,he){de._syncPendingControls(),he.forEach(Y=>{const Ue=Y.control;"submit"===Ue.updateOn&&Ue._pendingChange&&(Y.viewToModelUpdate(Ue._pendingValue),Ue._pendingChange=!1)})}function Ht(de,he){if(!he)return null;let Y,Ue,jt;return Array.isArray(he),he.forEach(br=>{br.constructor===pe?Y=br:function Ne(de){return Object.getPrototypeOf(de.constructor)===S}(br)?Ue=br:jt=br}),jt||Ue||Y||null}const Dn={provide:Xt,useExisting:(0,i.Rfq)(()=>Nn)},Cn=Promise.resolve();let Nn=(()=>{class de extends Xt{callSetDisabledState;get submitted(){return(0,i.O8t)(this.submittedReactive)}_submitted=(0,i.EWP)(()=>this.submittedReactive());submittedReactive=(0,i.vPA)(!1);_directives=new Set;form;ngSubmit=new i.bkB;options;constructor(Y,Ue,jt){super(),this.callSetDisabledState=jt,this.form=new Zi({},ze(Y),Ft(Ue))}ngAfterViewInit(){this._setUpdateStrategy()}get formDirective(){return this}get control(){return this.form}get path(){return[]}get controls(){return this.form.controls}addControl(Y){Cn.then(()=>{const Ue=this._findContainer(Y.path);Y.control=Ue.registerControl(Y.name,Y.control),Ni(Y.control,Y,this.callSetDisabledState),Y.control.updateValueAndValidity({emitEvent:!1}),this._directives.add(Y)})}getControl(Y){return this.form.get(Y.path)}removeControl(Y){Cn.then(()=>{const Ue=this._findContainer(Y.path);Ue&&Ue.removeControl(Y.name),this._directives.delete(Y)})}addFormGroup(Y){Cn.then(()=>{const Ue=this._findContainer(Y.path),jt=new Zi({});po(jt,Y),Ue.registerControl(Y.name,jt),jt.updateValueAndValidity({emitEvent:!1})})}removeFormGroup(Y){Cn.then(()=>{const Ue=this._findContainer(Y.path);Ue&&Ue.removeControl(Y.name)})}getFormGroup(Y){return this.form.get(Y.path)}updateModel(Y,Ue){Cn.then(()=>{this.form.get(Y.path).setValue(Ue)})}setValue(Y){this.control.setValue(Y)}onSubmit(Y){return this.submittedReactive.set(!0),gt(this.form,this._directives),this.ngSubmit.emit(Y),"dialog"===Y?.target?.method}onReset(){this.resetForm()}resetForm(Y=void 0){this.form.reset(Y),this.submittedReactive.set(!1)}_setUpdateStrategy(){this.options&&null!=this.options.updateOn&&(this.form._updateOn=this.options.updateOn)}_findContainer(Y){return Y.pop(),Y.length?this.form.get(Y):this.form}static \u0275fac=function(Ue){return new(Ue||de)(i.rXU(me,10),i.rXU(be,10),i.rXU(mn,8))};static \u0275dir=i.FsC({type:de,selectors:[["form",3,"ngNoForm","",3,"formGroup",""],["ng-form"],["","ngForm",""]],hostBindings:function(Ue,jt){1&Ue&&i.bIt("submit",function(Jr){return jt.onSubmit(Jr)})("reset",function(){return jt.onReset()})},inputs:{options:[0,"ngFormOptions","options"]},outputs:{ngSubmit:"ngSubmit"},exportAs:["ngForm"],standalone:!1,features:[i.Jv_([Dn]),i.Vt3]})}return de})();function jn(de,he){const Y=de.indexOf(he);Y>-1&&de.splice(Y,1)}function Jn(de){return"object"==typeof de&&null!==de&&2===Object.keys(de).length&&"value"in de&&"disabled"in de}const ar=class extends hi{defaultValue=null;_onChange=[];_pendingValue;_pendingChange=!1;constructor(he=null,Y,Ue){super(Dt(Y),Bt(Ue,Y)),this._applyFormState(he),this._setUpdateStrategy(Y),this._initObservables(),this.updateValueAndValidity({onlySelf:!0,emitEvent:!!this.asyncValidator}),qn(Y)&&(Y.nonNullable||Y.initialValueIsDefault)&&(this.defaultValue=Jn(he)?he.value:he)}setValue(he,Y={}){this.value=this._pendingValue=he,this._onChange.length&&!1!==Y.emitModelToViewChange&&this._onChange.forEach(Ue=>Ue(this.value,!1!==Y.emitViewToModelChange)),this.updateValueAndValidity(Y)}patchValue(he,Y={}){this.setValue(he,Y)}reset(he=this.defaultValue,Y={}){this._applyFormState(he),this.markAsPristine(Y),this.markAsUntouched(Y),this.setValue(this.value,Y),this._pendingChange=!1}_updateValue(){}_anyControls(he){return!1}_allControlsDisabled(){return this.disabled}registerOnChange(he){this._onChange.push(he)}_unregisterOnChange(he){jn(this._onChange,he)}registerOnDisabledChange(he){this._onDisabledChange.push(he)}_unregisterOnDisabledChange(he){jn(this._onDisabledChange,he)}_forEachChild(he){}_syncPendingControls(){return!("submit"!==this.updateOn||(this._pendingDirty&&this.markAsDirty(),this._pendingTouched&&this.markAsTouched(),!this._pendingChange)||(this.setValue(this._pendingValue,{onlySelf:!0,emitModelToViewChange:!1}),0))}_applyFormState(he){Jn(he)?(this.value=this._pendingValue=he.value,he.disabled?this.disable({onlySelf:!0,emitEvent:!1}):this.enable({onlySelf:!0,emitEvent:!1})):this.value=this._pendingValue=he}},wr=ar,es={provide:Mt,useExisting:(0,i.Rfq)(()=>sa)},zs=Promise.resolve();let sa=(()=>{class de extends Mt{_changeDetectorRef;callSetDisabledState;control=new ar;static ngAcceptInputType_isDisabled;_registered=!1;viewModel;name="";isDisabled;model;options;update=new i.bkB;constructor(Y,Ue,jt,br,Jr,ts){super(),this._changeDetectorRef=Jr,this.callSetDisabledState=ts,this._parent=Y,this._setValidators(Ue),this._setAsyncValidators(jt),this.valueAccessor=Ht(0,br)}ngOnChanges(Y){if(this._checkForErrors(),!this._registered||"name"in Y){if(this._registered&&(this._checkName(),this.formDirective)){const Ue=Y.name.previousValue;this.formDirective.removeControl({name:Ue,path:this._getPath(Ue)})}this._setUpControl()}"isDisabled"in Y&&this._updateDisabled(Y),Ye(Y,this.viewModel)&&(this._updateValue(this.model),this.viewModel=this.model)}ngOnDestroy(){this.formDirective&&this.formDirective.removeControl(this)}get path(){return this._getPath(this.name)}get formDirective(){return this._parent?this._parent.formDirective:null}viewToModelUpdate(Y){this.viewModel=Y,this.update.emit(Y)}_setUpControl(){this._setUpdateStrategy(),this._isStandalone()?this._setUpStandalone():this.formDirective.addControl(this),this._registered=!0}_setUpdateStrategy(){this.options&&null!=this.options.updateOn&&(this.control._updateOn=this.options.updateOn)}_isStandalone(){return!this._parent||!(!this.options||!this.options.standalone)}_setUpStandalone(){Ni(this.control,this,this.callSetDisabledState),this.control.updateValueAndValidity({emitEvent:!1})}_checkForErrors(){this._isStandalone()||this._checkParentType(),this._checkName()}_checkParentType(){}_checkName(){this.options&&this.options.name&&(this.name=this.options.name),this._isStandalone()}_updateValue(Y){zs.then(()=>{this.control.setValue(Y,{emitViewToModelChange:!1}),this._changeDetectorRef?.markForCheck()})}_updateDisabled(Y){const Ue=Y.isDisabled.currentValue,jt=0!==Ue&&(0,i.L39)(Ue);zs.then(()=>{jt&&!this.control.disabled?this.control.disable():!jt&&this.control.disabled&&this.control.enable(),this._changeDetectorRef?.markForCheck()})}_getPath(Y){return this._parent?Co(Y,this._parent):[Y]}static \u0275fac=function(Ue){return new(Ue||de)(i.rXU(Xt,9),i.rXU(me,10),i.rXU(be,10),i.rXU(M,10),i.rXU(i.gRc,8),i.rXU(mn,8))};static \u0275dir=i.FsC({type:de,selectors:[["","ngModel","",3,"formControlName","",3,"formControl",""]],inputs:{name:"name",isDisabled:[0,"disabled","isDisabled"],model:[0,"ngModel","model"],options:[0,"ngModelOptions","options"]},outputs:{update:"ngModelChange"},exportAs:["ngModel"],standalone:!1,features:[i.Jv_([es]),i.Vt3,i.OA$]})}return de})(),Li=(()=>{class de{static \u0275fac=function(Ue){return new(Ue||de)};static \u0275dir=i.FsC({type:de,selectors:[["form",3,"ngNoForm","",3,"ngNativeValidate",""]],hostAttrs:["novalidate",""],standalone:!1})}return de})();const bi={provide:M,useExisting:(0,i.Rfq)(()=>aa),multi:!0};let aa=(()=>{class de extends S{writeValue(Y){this.setProperty("value",Y??"")}registerOnChange(Y){this.onChange=Ue=>{Y(""==Ue?null:parseFloat(Ue))}}static \u0275fac=(()=>{let Y;return function(jt){return(Y||(Y=i.xGo(de)))(jt||de)}})();static \u0275dir=i.FsC({type:de,selectors:[["input","type","number","formControlName",""],["input","type","number","formControl",""],["input","type","number","ngModel",""]],hostBindings:function(Ue,jt){1&Ue&&i.bIt("input",function(Jr){return jt.onChange(Jr.target.value)})("blur",function(){return jt.onTouched()})},standalone:!1,features:[i.Jv_([bi]),i.Vt3]})}return de})();const mo=new i.nKC(""),Go={provide:Mt,useExisting:(0,i.Rfq)(()=>Rs)};let Rs=(()=>{class de extends Mt{_ngModelWarningConfig;callSetDisabledState;viewModel;form;set isDisabled(Y){}model;update=new i.bkB;static _ngModelWarningSentOnce=!1;_ngModelWarningSent=!1;constructor(Y,Ue,jt,br,Jr){super(),this._ngModelWarningConfig=br,this.callSetDisabledState=Jr,this._setValidators(Y),this._setAsyncValidators(Ue),this.valueAccessor=Ht(0,jt)}ngOnChanges(Y){if(this._isControlChanged(Y)){const Ue=Y.form.previousValue;Ue&&ds(Ue,this,!1),Ni(this.form,this,this.callSetDisabledState),this.form.updateValueAndValidity({emitEvent:!1})}Ye(Y,this.viewModel)&&(this.form.setValue(this.model),this.viewModel=this.model)}ngOnDestroy(){this.form&&ds(this.form,this,!1)}get path(){return[]}get control(){return this.form}viewToModelUpdate(Y){this.viewModel=Y,this.update.emit(Y)}_isControlChanged(Y){return Y.hasOwnProperty("form")}static \u0275fac=function(Ue){return new(Ue||de)(i.rXU(me,10),i.rXU(be,10),i.rXU(M,10),i.rXU(mo,8),i.rXU(mn,8))};static \u0275dir=i.FsC({type:de,selectors:[["","formControl",""]],inputs:{form:[0,"formControl","form"],isDisabled:[0,"disabled","isDisabled"],model:[0,"ngModel","model"]},outputs:{update:"ngModelChange"},exportAs:["ngForm"],standalone:!1,features:[i.Jv_([Go]),i.Vt3,i.OA$]})}return de})();const Xr={provide:Xt,useExisting:(0,i.Rfq)(()=>Ds)};let Ds=(()=>{class de extends Xt{callSetDisabledState;get submitted(){return(0,i.O8t)(this._submittedReactive)}set submitted(Y){this._submittedReactive.set(Y)}_submitted=(0,i.EWP)(()=>this._submittedReactive());_submittedReactive=(0,i.vPA)(!1);_oldForm;_onCollectionChange=()=>this._updateDomValue();directives=[];form=null;ngSubmit=new i.bkB;constructor(Y,Ue,jt){super(),this.callSetDisabledState=jt,this._setValidators(Y),this._setAsyncValidators(Ue)}ngOnChanges(Y){this._checkFormPresent(),Y.hasOwnProperty("form")&&(this._updateValidators(),this._updateDomValue(),this._updateRegistrations(),this._oldForm=this.form)}ngOnDestroy(){this.form&&(fo(this.form,this),this.form._onCollectionChange===this._onCollectionChange&&this.form._registerOnCollectionChange(()=>{}))}get formDirective(){return this}get control(){return this.form}get path(){return[]}addControl(Y){const Ue=this.form.get(Y.path);return Ni(Ue,Y,this.callSetDisabledState),Ue.updateValueAndValidity({emitEvent:!1}),this.directives.push(Y),Ue}getControl(Y){return this.form.get(Y.path)}removeControl(Y){ds(Y.control||null,Y,!1),function kt(de,he){const Y=de.indexOf(he);Y>-1&&de.splice(Y,1)}(this.directives,Y)}addFormGroup(Y){this._setUpFormContainer(Y)}removeFormGroup(Y){this._cleanUpFormContainer(Y)}getFormGroup(Y){return this.form.get(Y.path)}addFormArray(Y){this._setUpFormContainer(Y)}removeFormArray(Y){this._cleanUpFormContainer(Y)}getFormArray(Y){return this.form.get(Y.path)}updateModel(Y,Ue){this.form.get(Y.path).setValue(Ue)}onSubmit(Y){return this._submittedReactive.set(!0),gt(this.form,this.directives),this.ngSubmit.emit(Y),this.form._events.next(new Ge(this.control)),"dialog"===Y?.target?.method}onReset(){this.resetForm()}resetForm(Y=void 0){this.form.reset(Y),this._submittedReactive.set(!1),this.form._events.next(new Ve(this.form))}_updateDomValue(){this.directives.forEach(Y=>{const Ue=Y.control,jt=this.form.get(Y.path);Ue!==jt&&(ds(Ue||null,Y),(de=>de instanceof ar)(jt)&&(Ni(jt,Y,this.callSetDisabledState),Y.control=jt))}),this.form._updateTreeValidity({emitEvent:!1})}_setUpFormContainer(Y){const Ue=this.form.get(Y.path);po(Ue,Y),Ue.updateValueAndValidity({emitEvent:!1})}_cleanUpFormContainer(Y){if(this.form){const Ue=this.form.get(Y.path);Ue&&function Ii(de,he){return fo(de,he)}(Ue,Y)&&Ue.updateValueAndValidity({emitEvent:!1})}}_updateRegistrations(){this.form._registerOnCollectionChange(this._onCollectionChange),this._oldForm&&this._oldForm._registerOnCollectionChange(()=>{})}_updateValidators(){qo(this.form,this),this._oldForm&&fo(this._oldForm,this)}_checkFormPresent(){}static \u0275fac=function(Ue){return new(Ue||de)(i.rXU(me,10),i.rXU(be,10),i.rXU(mn,8))};static \u0275dir=i.FsC({type:de,selectors:[["","formGroup",""]],hostBindings:function(Ue,jt){1&Ue&&i.bIt("submit",function(Jr){return jt.onSubmit(Jr)})("reset",function(){return jt.onReset()})},inputs:{form:[0,"formGroup","form"]},outputs:{ngSubmit:"ngSubmit"},exportAs:["ngForm"],standalone:!1,features:[i.Jv_([Xr]),i.Vt3,i.OA$]})}return de})();const _o={provide:Mt,useExisting:(0,i.Rfq)(()=>Ao)};let Ao=(()=>{class de extends Mt{_ngModelWarningConfig;_added=!1;viewModel;control;name=null;set isDisabled(Y){}model;update=new i.bkB;static _ngModelWarningSentOnce=!1;_ngModelWarningSent=!1;constructor(Y,Ue,jt,br,Jr){super(),this._ngModelWarningConfig=Jr,this._parent=Y,this._setValidators(Ue),this._setAsyncValidators(jt),this.valueAccessor=Ht(0,br)}ngOnChanges(Y){this._added||this._setUpControl(),Ye(Y,this.viewModel)&&(this.viewModel=this.model,this.formDirective.updateModel(this,this.model))}ngOnDestroy(){this.formDirective&&this.formDirective.removeControl(this)}viewToModelUpdate(Y){this.viewModel=Y,this.update.emit(Y)}get path(){return Co(null==this.name?this.name:this.name.toString(),this._parent)}get formDirective(){return this._parent?this._parent.formDirective:null}_checkParentType(){}_setUpControl(){this._checkParentType(),this.control=this.formDirective.addControl(this),this._added=!0}static \u0275fac=function(Ue){return new(Ue||de)(i.rXU(Xt,13),i.rXU(me,10),i.rXU(be,10),i.rXU(M,10),i.rXU(mo,8))};static \u0275dir=i.FsC({type:de,selectors:[["","formControlName",""]],inputs:{name:[0,"formControlName","name"],isDisabled:[0,"disabled","isDisabled"],model:[0,"ngModel","model"]},outputs:{update:"ngModelChange"},standalone:!1,features:[i.Jv_([_o]),i.Vt3,i.OA$]})}return de})();let Bo=(()=>{class de{_validator=lt;_onChange;_enabled;ngOnChanges(Y){if(this.inputName in Y){const Ue=this.normalizeInput(Y[this.inputName].currentValue);this._enabled=this.enabled(Ue),this._validator=this._enabled?this.createValidator(Ue):lt,this._onChange&&this._onChange()}}validate(Y){return this._validator(Y)}registerOnValidatorChange(Y){this._onChange=Y}enabled(Y){return null!=Y}static \u0275fac=function(Ue){return new(Ue||de)};static \u0275dir=i.FsC({type:de,features:[i.OA$]})}return de})();const Us={provide:me,useExisting:(0,i.Rfq)(()=>Ba),multi:!0},ua={provide:me,useExisting:(0,i.Rfq)(()=>Aa),multi:!0};let Ba=(()=>{class de extends Bo{required;inputName="required";normalizeInput=i.L39;createValidator=Y=>ue;enabled(Y){return Y}static \u0275fac=(()=>{let Y;return function(jt){return(Y||(Y=i.xGo(de)))(jt||de)}})();static \u0275dir=i.FsC({type:de,selectors:[["","required","","formControlName","",3,"type","checkbox"],["","required","","formControl","",3,"type","checkbox"],["","required","","ngModel","",3,"type","checkbox"]],hostVars:1,hostBindings:function(Ue,jt){2&Ue&&i.BMQ("required",jt._enabled?"":null)},inputs:{required:"required"},standalone:!1,features:[i.Jv_([Us]),i.Vt3]})}return de})(),Aa=(()=>{class de extends Ba{createValidator=Y=>Ce;static \u0275fac=(()=>{let Y;return function(jt){return(Y||(Y=i.xGo(de)))(jt||de)}})();static \u0275dir=i.FsC({type:de,selectors:[["input","type","checkbox","required","","formControlName",""],["input","type","checkbox","required","","formControl",""],["input","type","checkbox","required","","ngModel",""]],hostVars:1,hostBindings:function(Ue,jt){2&Ue&&i.BMQ("required",jt._enabled?"":null)},standalone:!1,features:[i.Jv_([ua]),i.Vt3]})}return de})();const Ct={provide:me,useExisting:(0,i.Rfq)(()=>Bn),multi:!0};let Bn=(()=>{class de extends Bo{maxlength;inputName="maxlength";normalizeInput=Y=>function Ns(de){return"number"==typeof de?de:parseInt(de,10)}(Y);createValidator=Y=>dt(Y);static \u0275fac=(()=>{let Y;return function(jt){return(Y||(Y=i.xGo(de)))(jt||de)}})();static \u0275dir=i.FsC({type:de,selectors:[["","maxlength","","formControlName",""],["","maxlength","","formControl",""],["","maxlength","","ngModel",""]],hostVars:1,hostBindings:function(Ue,jt){2&Ue&&i.BMQ("maxlength",jt._enabled?jt.maxlength:null)},inputs:{maxlength:"maxlength"},standalone:!1,features:[i.Jv_([Ct]),i.Vt3]})}return de})(),Mr=(()=>{class de{static \u0275fac=function(Ue){return new(Ue||de)};static \u0275mod=i.$C({type:de});static \u0275inj=i.G2t({})}return de})();class fi extends hi{constructor(he,Y,Ue){super(Dt(Y),Bt(Ue,Y)),this.controls=he,this._initObservables(),this._setUpdateStrategy(Y),this._setUpControls(),this.updateValueAndValidity({onlySelf:!0,emitEvent:!!this.asyncValidator})}controls;at(he){return this.controls[this._adjustIndex(he)]}push(he,Y={}){this.controls.push(he),this._registerControl(he),this.updateValueAndValidity({emitEvent:Y.emitEvent}),this._onCollectionChange()}insert(he,Y,Ue={}){this.controls.splice(he,0,Y),this._registerControl(Y),this.updateValueAndValidity({emitEvent:Ue.emitEvent})}removeAt(he,Y={}){let Ue=this._adjustIndex(he);Ue<0&&(Ue=0),this.controls[Ue]&&this.controls[Ue]._registerOnCollectionChange(()=>{}),this.controls.splice(Ue,1),this.updateValueAndValidity({emitEvent:Y.emitEvent})}setControl(he,Y,Ue={}){let jt=this._adjustIndex(he);jt<0&&(jt=0),this.controls[jt]&&this.controls[jt]._registerOnCollectionChange(()=>{}),this.controls.splice(jt,1),Y&&(this.controls.splice(jt,0,Y),this._registerControl(Y)),this.updateValueAndValidity({emitEvent:Ue.emitEvent}),this._onCollectionChange()}get length(){return this.controls.length}setValue(he,Y={}){si(this,0,he),he.forEach((Ue,jt)=>{Er(this,!1,jt),this.at(jt).setValue(Ue,{onlySelf:!0,emitEvent:Y.emitEvent})}),this.updateValueAndValidity(Y)}patchValue(he,Y={}){null!=he&&(he.forEach((Ue,jt)=>{this.at(jt)&&this.at(jt).patchValue(Ue,{onlySelf:!0,emitEvent:Y.emitEvent})}),this.updateValueAndValidity(Y))}reset(he=[],Y={}){this._forEachChild((Ue,jt)=>{Ue.reset(he[jt],{onlySelf:!0,emitEvent:Y.emitEvent})}),this._updatePristine(Y,this),this._updateTouched(Y,this),this.updateValueAndValidity(Y)}getRawValue(){return this.controls.map(he=>he.getRawValue())}clear(he={}){this.controls.length<1||(this._forEachChild(Y=>Y._registerOnCollectionChange(()=>{})),this.controls.splice(0),this.updateValueAndValidity({emitEvent:he.emitEvent}))}_adjustIndex(he){return he<0?he+this.length:he}_syncPendingControls(){let he=this.controls.reduce((Y,Ue)=>!!Ue._syncPendingControls()||Y,!1);return he&&this.updateValueAndValidity({onlySelf:!0}),he}_forEachChild(he){this.controls.forEach((Y,Ue)=>{he(Y,Ue)})}_updateValue(){this.value=this.controls.filter(he=>he.enabled||this.disabled).map(he=>he.value)}_anyControls(he){return this.controls.some(Y=>Y.enabled&&he(Y))}_setUpControls(){this._forEachChild(he=>this._registerControl(he))}_allControlsDisabled(){for(const he of this.controls)if(he.enabled)return!1;return this.controls.length>0||this.disabled}_registerControl(he){he.setParent(this),he._registerOnCollectionChange(this._onCollectionChange)}_find(he){return this.at(he)??null}}function Fi(de){return!!de&&(void 0!==de.asyncValidators||void 0!==de.validators||void 0!==de.updateOn)}let Ro=(()=>{class de{useNonNullable=!1;get nonNullable(){const Y=new de;return Y.useNonNullable=!0,Y}group(Y,Ue=null){const jt=this._reduceControls(Y);let br={};return Fi(Ue)?br=Ue:null!==Ue&&(br.validators=Ue.validator,br.asyncValidators=Ue.asyncValidator),new Zi(jt,br)}record(Y,Ue=null){const jt=this._reduceControls(Y);return new Rt(jt,Ue)}control(Y,Ue,jt){let br={};return this.useNonNullable?(Fi(Ue)?br=Ue:(br.validators=Ue,br.asyncValidators=jt),new ar(Y,{...br,nonNullable:!0})):new ar(Y,Ue,jt)}array(Y,Ue,jt){const br=Y.map(Jr=>this._createControl(Jr));return new fi(br,Ue,jt)}_reduceControls(Y){const Ue={};return Object.keys(Y).forEach(jt=>{Ue[jt]=this._createControl(Y[jt])}),Ue}_createControl(Y){return Y instanceof ar||Y instanceof hi?Y:Array.isArray(Y)?this.control(Y[0],Y.length>1?Y[1]:null,Y.length>2?Y[2]:null):this.control(Y)}static \u0275fac=function(Ue){return new(Ue||de)};static \u0275prov=i.jDH({token:de,factory:de.\u0275fac,providedIn:"root"})}return de})(),Ho=(()=>{class de extends Ro{group(Y,Ue=null){return super.group(Y,Ue)}control(Y,Ue,jt){return super.control(Y,Ue,jt)}array(Y,Ue,jt){return super.array(Y,Ue,jt)}static \u0275fac=(()=>{let Y;return function(jt){return(Y||(Y=i.xGo(de)))(jt||de)}})();static \u0275prov=i.jDH({token:de,factory:de.\u0275fac,providedIn:"root"})}return de})(),$a=(()=>{class de{static withConfig(Y){return{ngModule:de,providers:[{provide:mn,useValue:Y.callSetDisabledState??dr}]}}static \u0275fac=function(Ue){return new(Ue||de)};static \u0275mod=i.$C({type:de});static \u0275inj=i.G2t({imports:[Mr]})}return de})(),da=(()=>{class de{static withConfig(Y){return{ngModule:de,providers:[{provide:mo,useValue:Y.warnOnNgModelWithFormControl??"always"},{provide:mn,useValue:Y.callSetDisabledState??dr}]}}static \u0275fac=function(Ue){return new(Ue||de)};static \u0275mod=i.$C({type:de});static \u0275inj=i.G2t({imports:[Mr]})}return de})()},9471:(o,s,r)=>{"use strict";r.d(s,{$z:()=>ce,Hl:()=>Vn,iY:()=>gn,pQ:()=>bn});var i=r(3107),a=r(8559),c=r(2147),y=r(2902),w=r(5467);const C=["mat-button",""],T=[[["",8,"material-icons",3,"iconPositionEnd",""],["mat-icon",3,"iconPositionEnd",""],["","matButtonIcon","",3,"iconPositionEnd",""]],"*",[["","iconPositionEnd","",8,"material-icons"],["mat-icon","iconPositionEnd",""],["","matButtonIcon","","iconPositionEnd",""]]],S=[".material-icons:not([iconPositionEnd]), mat-icon:not([iconPositionEnd]), [matButtonIcon]:not([iconPositionEnd])","*",".material-icons[iconPositionEnd], mat-icon[iconPositionEnd], [matButtonIcon][iconPositionEnd]"],O="@media(forced-colors: active){.mat-mdc-button:not(.mdc-button--outlined),.mat-mdc-unelevated-button:not(.mdc-button--outlined),.mat-mdc-raised-button:not(.mdc-button--outlined),.mat-mdc-outlined-button:not(.mdc-button--outlined),.mat-mdc-icon-button.mat-mdc-icon-button{outline:solid 1px}}",re=["mat-icon-button",""],pe=["*"],ae=new i.nKC("MAT_BUTTON_CONFIG"),be=[{attribute:"mat-button",mdcClasses:["mdc-button","mat-mdc-button"]},{attribute:"mat-flat-button",mdcClasses:["mdc-button","mdc-button--unelevated","mat-mdc-unelevated-button"]},{attribute:"mat-raised-button",mdcClasses:["mdc-button","mdc-button--raised","mat-mdc-raised-button"]},{attribute:"mat-stroked-button",mdcClasses:["mdc-button","mdc-button--outlined","mat-mdc-outlined-button"]},{attribute:"mat-fab",mdcClasses:["mdc-fab","mat-mdc-fab-base","mat-mdc-fab"]},{attribute:"mat-mini-fab",mdcClasses:["mdc-fab","mat-mdc-fab-base","mdc-fab--mini","mat-mdc-mini-fab"]},{attribute:"mat-icon-button",mdcClasses:["mdc-icon-button","mat-mdc-icon-button"]}];let Oe=(()=>{class yn{_elementRef=(0,i.WQX)(i.aKT);_platform=(0,i.WQX)(c.OD);_ngZone=(0,i.WQX)(i.SKi);_animationMode=(0,i.WQX)(i.bc$,{optional:!0});_focusMonitor=(0,i.WQX)(a.FN);_rippleLoader=(0,i.WQX)(y.Ej);_isFab=!1;color;get disableRipple(){return this._disableRipple}set disableRipple(_t){this._disableRipple=_t,this._updateRippleDisabled()}_disableRipple=!1;get disabled(){return this._disabled}set disabled(_t){this._disabled=_t,this._updateRippleDisabled()}_disabled=!1;ariaDisabled;disabledInteractive;constructor(){(0,i.WQX)(w.l).load(y.Ah);const _t=(0,i.WQX)(ae,{optional:!0}),ze=this._elementRef.nativeElement,$e=ze.classList;this.disabledInteractive=_t?.disabledInteractive??!1,this.color=_t?.color??null,this._rippleLoader?.configureRipple(ze,{className:"mat-mdc-button-ripple"});for(const{attribute:Ft,mdcClasses:Ke}of be)ze.hasAttribute(Ft)&&$e.add(...Ke)}ngAfterViewInit(){this._focusMonitor.monitor(this._elementRef,!0)}ngOnDestroy(){this._focusMonitor.stopMonitoring(this._elementRef),this._rippleLoader?.destroyRipple(this._elementRef.nativeElement)}focus(_t="program",ze){_t?this._focusMonitor.focusVia(this._elementRef.nativeElement,_t,ze):this._elementRef.nativeElement.focus(ze)}_getAriaDisabled(){return null!=this.ariaDisabled?this.ariaDisabled:!(!this.disabled||!this.disabledInteractive)||null}_getDisabledAttribute(){return!(this.disabledInteractive||!this.disabled)||null}_updateRippleDisabled(){this._rippleLoader?.setDisabled(this._elementRef.nativeElement,this.disableRipple||this.disabled)}static \u0275fac=function(ze){return new(ze||yn)};static \u0275dir=i.FsC({type:yn,inputs:{color:"color",disableRipple:[2,"disableRipple","disableRipple",i.L39],disabled:[2,"disabled","disabled",i.L39],ariaDisabled:[2,"aria-disabled","ariaDisabled",i.L39],disabledInteractive:[2,"disabledInteractive","disabledInteractive",i.L39]},features:[i.GFd]})}return yn})(),De=(()=>{class yn extends Oe{tabIndex;ngOnInit(){this._ngZone.runOutsideAngular(()=>{this._elementRef.nativeElement.addEventListener("click",this._haltDisabledEvents)})}ngOnDestroy(){super.ngOnDestroy(),this._elementRef.nativeElement.removeEventListener("click",this._haltDisabledEvents)}_haltDisabledEvents=_t=>{this.disabled&&(_t.preventDefault(),_t.stopImmediatePropagation())};_getAriaDisabled(){return null!=this.ariaDisabled?this.ariaDisabled:this.disabled||null}static \u0275fac=(()=>{let _t;return function($e){return(_t||(_t=i.xGo(yn)))($e||yn)}})();static \u0275dir=i.FsC({type:yn,inputs:{tabIndex:[2,"tabIndex","tabIndex",_t=>null==_t?void 0:(0,i.Udg)(_t)]},features:[i.GFd,i.Vt3]})}return yn})(),ce=(()=>{class yn extends Oe{static \u0275fac=(()=>{let _t;return function($e){return(_t||(_t=i.xGo(yn)))($e||yn)}})();static \u0275cmp=i.VBU({type:yn,selectors:[["button","mat-button",""],["button","mat-raised-button",""],["button","mat-flat-button",""],["button","mat-stroked-button",""]],hostVars:14,hostBindings:function(ze,$e){2&ze&&(i.BMQ("disabled",$e._getDisabledAttribute())("aria-disabled",$e._getAriaDisabled()),i.HbH($e.color?"mat-"+$e.color:""),i.AVh("mat-mdc-button-disabled",$e.disabled)("mat-mdc-button-disabled-interactive",$e.disabledInteractive)("_mat-animation-noopable","NoopAnimations"===$e._animationMode)("mat-unthemed",!$e.color)("mat-mdc-button-base",!0))},exportAs:["matButton"],features:[i.Vt3],attrs:C,ngContentSelectors:S,decls:7,vars:4,consts:[[1,"mat-mdc-button-persistent-ripple"],[1,"mdc-button__label"],[1,"mat-focus-indicator"],[1,"mat-mdc-button-touch-target"]],template:function(ze,$e){1&ze&&(i.NAR(T),i.nrm(0,"span",0),i.SdG(1),i.j41(2,"span",1),i.SdG(3,1),i.k0s(),i.SdG(4,2),i.nrm(5,"span",2)(6,"span",3)),2&ze&&i.AVh("mdc-button__ripple",!$e._isFab)("mdc-fab__ripple",$e._isFab)},styles:['.mat-mdc-button-base{text-decoration:none}.mdc-button{-webkit-user-select:none;user-select:none;position:relative;display:inline-flex;align-items:center;justify-content:center;box-sizing:border-box;min-width:64px;border:none;outline:none;line-height:inherit;-webkit-appearance:none;overflow:visible;vertical-align:middle;background:rgba(0,0,0,0);padding:0 8px}.mdc-button::-moz-focus-inner{padding:0;border:0}.mdc-button:active{outline:none}.mdc-button:hover{cursor:pointer}.mdc-button:disabled{cursor:default;pointer-events:none}.mdc-button[hidden]{display:none}.mdc-button .mdc-button__label{position:relative}.mat-mdc-button{padding:0 var(--mat-text-button-horizontal-padding, 12px);height:var(--mdc-text-button-container-height, 40px);font-family:var(--mdc-text-button-label-text-font, var(--mat-sys-label-large-font));font-size:var(--mdc-text-button-label-text-size, var(--mat-sys-label-large-size));letter-spacing:var(--mdc-text-button-label-text-tracking, var(--mat-sys-label-large-tracking));text-transform:var(--mdc-text-button-label-text-transform);font-weight:var(--mdc-text-button-label-text-weight, var(--mat-sys-label-large-weight))}.mat-mdc-button,.mat-mdc-button .mdc-button__ripple{border-radius:var(--mdc-text-button-container-shape, var(--mat-sys-corner-full))}.mat-mdc-button:not(:disabled){color:var(--mdc-text-button-label-text-color, var(--mat-sys-primary))}.mat-mdc-button[disabled],.mat-mdc-button.mat-mdc-button-disabled{cursor:default;pointer-events:none;color:var(--mdc-text-button-disabled-label-text-color, color-mix(in srgb, var(--mat-sys-on-surface) 38%, transparent))}.mat-mdc-button.mat-mdc-button-disabled-interactive{pointer-events:auto}.mat-mdc-button:has(.material-icons,mat-icon,[matButtonIcon]){padding:0 var(--mat-text-button-with-icon-horizontal-padding, 16px)}.mat-mdc-button>.mat-icon{margin-right:var(--mat-text-button-icon-spacing, 8px);margin-left:var(--mat-text-button-icon-offset, -4px)}[dir=rtl] .mat-mdc-button>.mat-icon{margin-right:var(--mat-text-button-icon-offset, -4px);margin-left:var(--mat-text-button-icon-spacing, 8px)}.mat-mdc-button .mdc-button__label+.mat-icon{margin-right:var(--mat-text-button-icon-offset, -4px);margin-left:var(--mat-text-button-icon-spacing, 8px)}[dir=rtl] .mat-mdc-button .mdc-button__label+.mat-icon{margin-right:var(--mat-text-button-icon-spacing, 8px);margin-left:var(--mat-text-button-icon-offset, -4px)}.mat-mdc-button .mat-ripple-element{background-color:var(--mat-text-button-ripple-color, color-mix(in srgb, var(--mat-sys-primary) calc(var(--mat-sys-pressed-state-layer-opacity) * 100%), transparent))}.mat-mdc-button .mat-mdc-button-persistent-ripple::before{background-color:var(--mat-text-button-state-layer-color, var(--mat-sys-primary))}.mat-mdc-button.mat-mdc-button-disabled .mat-mdc-button-persistent-ripple::before{background-color:var(--mat-text-button-disabled-state-layer-color, var(--mat-sys-on-surface-variant))}.mat-mdc-button:hover .mat-mdc-button-persistent-ripple::before{opacity:var(--mat-text-button-hover-state-layer-opacity, var(--mat-sys-hover-state-layer-opacity))}.mat-mdc-button.cdk-program-focused .mat-mdc-button-persistent-ripple::before,.mat-mdc-button.cdk-keyboard-focused .mat-mdc-button-persistent-ripple::before,.mat-mdc-button.mat-mdc-button-disabled-interactive:focus .mat-mdc-button-persistent-ripple::before{opacity:var(--mat-text-button-focus-state-layer-opacity, var(--mat-sys-focus-state-layer-opacity))}.mat-mdc-button:active .mat-mdc-button-persistent-ripple::before{opacity:var(--mat-text-button-pressed-state-layer-opacity, var(--mat-sys-pressed-state-layer-opacity))}.mat-mdc-button .mat-mdc-button-touch-target{position:absolute;top:50%;height:48px;left:0;right:0;transform:translateY(-50%);display:var(--mat-text-button-touch-target-display, block)}.mat-mdc-unelevated-button{transition:box-shadow 280ms cubic-bezier(0.4, 0, 0.2, 1);height:var(--mdc-filled-button-container-height, 40px);font-family:var(--mdc-filled-button-label-text-font, var(--mat-sys-label-large-font));font-size:var(--mdc-filled-button-label-text-size, var(--mat-sys-label-large-size));letter-spacing:var(--mdc-filled-button-label-text-tracking, var(--mat-sys-label-large-tracking));text-transform:var(--mdc-filled-button-label-text-transform);font-weight:var(--mdc-filled-button-label-text-weight, var(--mat-sys-label-large-weight));padding:0 var(--mat-filled-button-horizontal-padding, 24px)}.mat-mdc-unelevated-button>.mat-icon{margin-right:var(--mat-filled-button-icon-spacing, 8px);margin-left:var(--mat-filled-button-icon-offset, -8px)}[dir=rtl] .mat-mdc-unelevated-button>.mat-icon{margin-right:var(--mat-filled-button-icon-offset, -8px);margin-left:var(--mat-filled-button-icon-spacing, 8px)}.mat-mdc-unelevated-button .mdc-button__label+.mat-icon{margin-right:var(--mat-filled-button-icon-offset, -8px);margin-left:var(--mat-filled-button-icon-spacing, 8px)}[dir=rtl] .mat-mdc-unelevated-button .mdc-button__label+.mat-icon{margin-right:var(--mat-filled-button-icon-spacing, 8px);margin-left:var(--mat-filled-button-icon-offset, -8px)}.mat-mdc-unelevated-button .mat-ripple-element{background-color:var(--mat-filled-button-ripple-color, color-mix(in srgb, var(--mat-sys-on-primary) calc(var(--mat-sys-pressed-state-layer-opacity) * 100%), transparent))}.mat-mdc-unelevated-button .mat-mdc-button-persistent-ripple::before{background-color:var(--mat-filled-button-state-layer-color, var(--mat-sys-on-primary))}.mat-mdc-unelevated-button.mat-mdc-button-disabled .mat-mdc-button-persistent-ripple::before{background-color:var(--mat-filled-button-disabled-state-layer-color, var(--mat-sys-on-surface-variant))}.mat-mdc-unelevated-button:hover .mat-mdc-button-persistent-ripple::before{opacity:var(--mat-filled-button-hover-state-layer-opacity, var(--mat-sys-hover-state-layer-opacity))}.mat-mdc-unelevated-button.cdk-program-focused .mat-mdc-button-persistent-ripple::before,.mat-mdc-unelevated-button.cdk-keyboard-focused .mat-mdc-button-persistent-ripple::before,.mat-mdc-unelevated-button.mat-mdc-button-disabled-interactive:focus .mat-mdc-button-persistent-ripple::before{opacity:var(--mat-filled-button-focus-state-layer-opacity, var(--mat-sys-focus-state-layer-opacity))}.mat-mdc-unelevated-button:active .mat-mdc-button-persistent-ripple::before{opacity:var(--mat-filled-button-pressed-state-layer-opacity, var(--mat-sys-pressed-state-layer-opacity))}.mat-mdc-unelevated-button .mat-mdc-button-touch-target{position:absolute;top:50%;height:48px;left:0;right:0;transform:translateY(-50%);display:var(--mat-filled-button-touch-target-display, block)}.mat-mdc-unelevated-button:not(:disabled){color:var(--mdc-filled-button-label-text-color, var(--mat-sys-on-primary));background-color:var(--mdc-filled-button-container-color, var(--mat-sys-primary))}.mat-mdc-unelevated-button,.mat-mdc-unelevated-button .mdc-button__ripple{border-radius:var(--mdc-filled-button-container-shape, var(--mat-sys-corner-full))}.mat-mdc-unelevated-button[disabled],.mat-mdc-unelevated-button.mat-mdc-button-disabled{cursor:default;pointer-events:none;color:var(--mdc-filled-button-disabled-label-text-color, color-mix(in srgb, var(--mat-sys-on-surface) 38%, transparent));background-color:var(--mdc-filled-button-disabled-container-color, color-mix(in srgb, var(--mat-sys-on-surface) 12%, transparent))}.mat-mdc-unelevated-button.mat-mdc-button-disabled-interactive{pointer-events:auto}.mat-mdc-raised-button{transition:box-shadow 280ms cubic-bezier(0.4, 0, 0.2, 1);box-shadow:var(--mdc-protected-button-container-elevation-shadow, var(--mat-sys-level1));height:var(--mdc-protected-button-container-height, 40px);font-family:var(--mdc-protected-button-label-text-font, var(--mat-sys-label-large-font));font-size:var(--mdc-protected-button-label-text-size, var(--mat-sys-label-large-size));letter-spacing:var(--mdc-protected-button-label-text-tracking, var(--mat-sys-label-large-tracking));text-transform:var(--mdc-protected-button-label-text-transform);font-weight:var(--mdc-protected-button-label-text-weight, var(--mat-sys-label-large-weight));padding:0 var(--mat-protected-button-horizontal-padding, 24px)}.mat-mdc-raised-button>.mat-icon{margin-right:var(--mat-protected-button-icon-spacing, 8px);margin-left:var(--mat-protected-button-icon-offset, -8px)}[dir=rtl] .mat-mdc-raised-button>.mat-icon{margin-right:var(--mat-protected-button-icon-offset, -8px);margin-left:var(--mat-protected-button-icon-spacing, 8px)}.mat-mdc-raised-button .mdc-button__label+.mat-icon{margin-right:var(--mat-protected-button-icon-offset, -8px);margin-left:var(--mat-protected-button-icon-spacing, 8px)}[dir=rtl] .mat-mdc-raised-button .mdc-button__label+.mat-icon{margin-right:var(--mat-protected-button-icon-spacing, 8px);margin-left:var(--mat-protected-button-icon-offset, -8px)}.mat-mdc-raised-button .mat-ripple-element{background-color:var(--mat-protected-button-ripple-color, color-mix(in srgb, var(--mat-sys-primary) calc(var(--mat-sys-pressed-state-layer-opacity) * 100%), transparent))}.mat-mdc-raised-button .mat-mdc-button-persistent-ripple::before{background-color:var(--mat-protected-button-state-layer-color, var(--mat-sys-primary))}.mat-mdc-raised-button.mat-mdc-button-disabled .mat-mdc-button-persistent-ripple::before{background-color:var(--mat-protected-button-disabled-state-layer-color, var(--mat-sys-on-surface-variant))}.mat-mdc-raised-button:hover .mat-mdc-button-persistent-ripple::before{opacity:var(--mat-protected-button-hover-state-layer-opacity, var(--mat-sys-hover-state-layer-opacity))}.mat-mdc-raised-button.cdk-program-focused .mat-mdc-button-persistent-ripple::before,.mat-mdc-raised-button.cdk-keyboard-focused .mat-mdc-button-persistent-ripple::before,.mat-mdc-raised-button.mat-mdc-button-disabled-interactive:focus .mat-mdc-button-persistent-ripple::before{opacity:var(--mat-protected-button-focus-state-layer-opacity, var(--mat-sys-focus-state-layer-opacity))}.mat-mdc-raised-button:active .mat-mdc-button-persistent-ripple::before{opacity:var(--mat-protected-button-pressed-state-layer-opacity, var(--mat-sys-pressed-state-layer-opacity))}.mat-mdc-raised-button .mat-mdc-button-touch-target{position:absolute;top:50%;height:48px;left:0;right:0;transform:translateY(-50%);display:var(--mat-protected-button-touch-target-display, block)}.mat-mdc-raised-button:not(:disabled){color:var(--mdc-protected-button-label-text-color, var(--mat-sys-primary));background-color:var(--mdc-protected-button-container-color, var(--mat-sys-surface))}.mat-mdc-raised-button,.mat-mdc-raised-button .mdc-button__ripple{border-radius:var(--mdc-protected-button-container-shape, var(--mat-sys-corner-full))}.mat-mdc-raised-button:hover{box-shadow:var(--mdc-protected-button-hover-container-elevation-shadow, var(--mat-sys-level2))}.mat-mdc-raised-button:focus{box-shadow:var(--mdc-protected-button-focus-container-elevation-shadow, var(--mat-sys-level1))}.mat-mdc-raised-button:active,.mat-mdc-raised-button:focus:active{box-shadow:var(--mdc-protected-button-pressed-container-elevation-shadow, var(--mat-sys-level1))}.mat-mdc-raised-button[disabled],.mat-mdc-raised-button.mat-mdc-button-disabled{cursor:default;pointer-events:none;color:var(--mdc-protected-button-disabled-label-text-color, color-mix(in srgb, var(--mat-sys-on-surface) 38%, transparent));background-color:var(--mdc-protected-button-disabled-container-color, color-mix(in srgb, var(--mat-sys-on-surface) 12%, transparent))}.mat-mdc-raised-button[disabled].mat-mdc-button-disabled,.mat-mdc-raised-button.mat-mdc-button-disabled.mat-mdc-button-disabled{box-shadow:var(--mdc-protected-button-disabled-container-elevation-shadow, var(--mat-sys-level0))}.mat-mdc-raised-button.mat-mdc-button-disabled-interactive{pointer-events:auto}.mat-mdc-outlined-button{border-style:solid;transition:border 280ms cubic-bezier(0.4, 0, 0.2, 1);height:var(--mdc-outlined-button-container-height, 40px);font-family:var(--mdc-outlined-button-label-text-font, var(--mat-sys-label-large-font));font-size:var(--mdc-outlined-button-label-text-size, var(--mat-sys-label-large-size));letter-spacing:var(--mdc-outlined-button-label-text-tracking, var(--mat-sys-label-large-tracking));text-transform:var(--mdc-outlined-button-label-text-transform);font-weight:var(--mdc-outlined-button-label-text-weight, var(--mat-sys-label-large-weight));border-radius:var(--mdc-outlined-button-container-shape, var(--mat-sys-corner-full));border-width:var(--mdc-outlined-button-outline-width, 1px);padding:0 var(--mat-outlined-button-horizontal-padding, 24px)}.mat-mdc-outlined-button>.mat-icon{margin-right:var(--mat-outlined-button-icon-spacing, 8px);margin-left:var(--mat-outlined-button-icon-offset, -8px)}[dir=rtl] .mat-mdc-outlined-button>.mat-icon{margin-right:var(--mat-outlined-button-icon-offset, -8px);margin-left:var(--mat-outlined-button-icon-spacing, 8px)}.mat-mdc-outlined-button .mdc-button__label+.mat-icon{margin-right:var(--mat-outlined-button-icon-offset, -8px);margin-left:var(--mat-outlined-button-icon-spacing, 8px)}[dir=rtl] .mat-mdc-outlined-button .mdc-button__label+.mat-icon{margin-right:var(--mat-outlined-button-icon-spacing, 8px);margin-left:var(--mat-outlined-button-icon-offset, -8px)}.mat-mdc-outlined-button .mat-ripple-element{background-color:var(--mat-outlined-button-ripple-color, color-mix(in srgb, var(--mat-sys-primary) calc(var(--mat-sys-pressed-state-layer-opacity) * 100%), transparent))}.mat-mdc-outlined-button .mat-mdc-button-persistent-ripple::before{background-color:var(--mat-outlined-button-state-layer-color, var(--mat-sys-primary))}.mat-mdc-outlined-button.mat-mdc-button-disabled .mat-mdc-button-persistent-ripple::before{background-color:var(--mat-outlined-button-disabled-state-layer-color, var(--mat-sys-on-surface-variant))}.mat-mdc-outlined-button:hover .mat-mdc-button-persistent-ripple::before{opacity:var(--mat-outlined-button-hover-state-layer-opacity, var(--mat-sys-hover-state-layer-opacity))}.mat-mdc-outlined-button.cdk-program-focused .mat-mdc-button-persistent-ripple::before,.mat-mdc-outlined-button.cdk-keyboard-focused .mat-mdc-button-persistent-ripple::before,.mat-mdc-outlined-button.mat-mdc-button-disabled-interactive:focus .mat-mdc-button-persistent-ripple::before{opacity:var(--mat-outlined-button-focus-state-layer-opacity, var(--mat-sys-focus-state-layer-opacity))}.mat-mdc-outlined-button:active .mat-mdc-button-persistent-ripple::before{opacity:var(--mat-outlined-button-pressed-state-layer-opacity, var(--mat-sys-pressed-state-layer-opacity))}.mat-mdc-outlined-button .mat-mdc-button-touch-target{position:absolute;top:50%;height:48px;left:0;right:0;transform:translateY(-50%);display:var(--mat-outlined-button-touch-target-display, block)}.mat-mdc-outlined-button:not(:disabled){color:var(--mdc-outlined-button-label-text-color, var(--mat-sys-primary));border-color:var(--mdc-outlined-button-outline-color, var(--mat-sys-outline))}.mat-mdc-outlined-button[disabled],.mat-mdc-outlined-button.mat-mdc-button-disabled{cursor:default;pointer-events:none;color:var(--mdc-outlined-button-disabled-label-text-color, color-mix(in srgb, var(--mat-sys-on-surface) 38%, transparent));border-color:var(--mdc-outlined-button-disabled-outline-color, color-mix(in srgb, var(--mat-sys-on-surface) 12%, transparent))}.mat-mdc-outlined-button.mat-mdc-button-disabled-interactive{pointer-events:auto}.mat-mdc-outlined-button .mdc-button__ripple{border-width:var(--mdc-outlined-button-outline-width, 1px);border-style:solid;border-color:rgba(0,0,0,0)}.mat-mdc-button,.mat-mdc-unelevated-button,.mat-mdc-raised-button,.mat-mdc-outlined-button{-webkit-tap-highlight-color:rgba(0,0,0,0)}.mat-mdc-button .mat-mdc-button-ripple,.mat-mdc-button .mat-mdc-button-persistent-ripple,.mat-mdc-button .mat-mdc-button-persistent-ripple::before,.mat-mdc-unelevated-button .mat-mdc-button-ripple,.mat-mdc-unelevated-button .mat-mdc-button-persistent-ripple,.mat-mdc-unelevated-button .mat-mdc-button-persistent-ripple::before,.mat-mdc-raised-button .mat-mdc-button-ripple,.mat-mdc-raised-button .mat-mdc-button-persistent-ripple,.mat-mdc-raised-button .mat-mdc-button-persistent-ripple::before,.mat-mdc-outlined-button .mat-mdc-button-ripple,.mat-mdc-outlined-button .mat-mdc-button-persistent-ripple,.mat-mdc-outlined-button .mat-mdc-button-persistent-ripple::before{top:0;left:0;right:0;bottom:0;position:absolute;pointer-events:none;border-radius:inherit}.mat-mdc-button .mat-mdc-button-ripple,.mat-mdc-unelevated-button .mat-mdc-button-ripple,.mat-mdc-raised-button .mat-mdc-button-ripple,.mat-mdc-outlined-button .mat-mdc-button-ripple{overflow:hidden}.mat-mdc-button .mat-mdc-button-persistent-ripple::before,.mat-mdc-unelevated-button .mat-mdc-button-persistent-ripple::before,.mat-mdc-raised-button .mat-mdc-button-persistent-ripple::before,.mat-mdc-outlined-button .mat-mdc-button-persistent-ripple::before{content:"";opacity:0}.mat-mdc-button .mdc-button__label,.mat-mdc-button .mat-icon,.mat-mdc-unelevated-button .mdc-button__label,.mat-mdc-unelevated-button .mat-icon,.mat-mdc-raised-button .mdc-button__label,.mat-mdc-raised-button .mat-icon,.mat-mdc-outlined-button .mdc-button__label,.mat-mdc-outlined-button .mat-icon{z-index:1;position:relative}.mat-mdc-button .mat-focus-indicator,.mat-mdc-unelevated-button .mat-focus-indicator,.mat-mdc-raised-button .mat-focus-indicator,.mat-mdc-outlined-button .mat-focus-indicator{top:0;left:0;right:0;bottom:0;position:absolute}.mat-mdc-button:focus .mat-focus-indicator::before,.mat-mdc-unelevated-button:focus .mat-focus-indicator::before,.mat-mdc-raised-button:focus .mat-focus-indicator::before,.mat-mdc-outlined-button:focus .mat-focus-indicator::before{content:""}.mat-mdc-button._mat-animation-noopable,.mat-mdc-unelevated-button._mat-animation-noopable,.mat-mdc-raised-button._mat-animation-noopable,.mat-mdc-outlined-button._mat-animation-noopable{transition:none !important;animation:none !important}.mat-mdc-button>.mat-icon,.mat-mdc-unelevated-button>.mat-icon,.mat-mdc-raised-button>.mat-icon,.mat-mdc-outlined-button>.mat-icon{display:inline-block;position:relative;vertical-align:top;font-size:1.125rem;height:1.125rem;width:1.125rem}.mat-mdc-outlined-button .mat-mdc-button-ripple,.mat-mdc-outlined-button .mdc-button__ripple{top:-1px;left:-1px;bottom:-1px;right:-1px}.mat-mdc-unelevated-button .mat-focus-indicator::before,.mat-mdc-raised-button .mat-focus-indicator::before{margin:calc(calc(var(--mat-focus-indicator-border-width, 3px) + 2px)*-1)}.mat-mdc-outlined-button .mat-focus-indicator::before{margin:calc(calc(var(--mat-focus-indicator-border-width, 3px) + 3px)*-1)}',"@media(forced-colors: active){.mat-mdc-button:not(.mdc-button--outlined),.mat-mdc-unelevated-button:not(.mdc-button--outlined),.mat-mdc-raised-button:not(.mdc-button--outlined),.mat-mdc-outlined-button:not(.mdc-button--outlined),.mat-mdc-icon-button.mat-mdc-icon-button{outline:solid 1px}}"],encapsulation:2,changeDetection:0})}return yn})(),gn=(()=>{class yn extends Oe{constructor(){super(),this._rippleLoader.configureRipple(this._elementRef.nativeElement,{centered:!0})}static \u0275fac=function(ze){return new(ze||yn)};static \u0275cmp=i.VBU({type:yn,selectors:[["button","mat-icon-button",""]],hostVars:14,hostBindings:function(ze,$e){2&ze&&(i.BMQ("disabled",$e._getDisabledAttribute())("aria-disabled",$e._getAriaDisabled()),i.HbH($e.color?"mat-"+$e.color:""),i.AVh("mat-mdc-button-disabled",$e.disabled)("mat-mdc-button-disabled-interactive",$e.disabledInteractive)("_mat-animation-noopable","NoopAnimations"===$e._animationMode)("mat-unthemed",!$e.color)("mat-mdc-button-base",!0))},exportAs:["matButton"],features:[i.Vt3],attrs:re,ngContentSelectors:pe,decls:4,vars:0,consts:[[1,"mat-mdc-button-persistent-ripple","mdc-icon-button__ripple"],[1,"mat-focus-indicator"],[1,"mat-mdc-button-touch-target"]],template:function(ze,$e){1&ze&&(i.NAR(),i.nrm(0,"span",0),i.SdG(1),i.nrm(2,"span",1)(3,"span",2))},styles:['.mat-mdc-icon-button{-webkit-user-select:none;user-select:none;display:inline-block;position:relative;box-sizing:border-box;border:none;outline:none;background-color:rgba(0,0,0,0);fill:currentColor;color:inherit;text-decoration:none;cursor:pointer;z-index:0;overflow:visible;border-radius:50%;flex-shrink:0;text-align:center;width:var(--mdc-icon-button-state-layer-size, 40px);height:var(--mdc-icon-button-state-layer-size, 40px);padding:calc(calc(var(--mdc-icon-button-state-layer-size, 40px) - var(--mdc-icon-button-icon-size, 24px)) / 2);font-size:var(--mdc-icon-button-icon-size, 24px);color:var(--mdc-icon-button-icon-color, var(--mat-sys-on-surface-variant));-webkit-tap-highlight-color:rgba(0,0,0,0)}.mat-mdc-icon-button .mat-mdc-button-ripple,.mat-mdc-icon-button .mat-mdc-button-persistent-ripple,.mat-mdc-icon-button .mat-mdc-button-persistent-ripple::before{top:0;left:0;right:0;bottom:0;position:absolute;pointer-events:none;border-radius:inherit}.mat-mdc-icon-button .mat-mdc-button-ripple{overflow:hidden}.mat-mdc-icon-button .mat-mdc-button-persistent-ripple::before{content:"";opacity:0}.mat-mdc-icon-button .mdc-button__label,.mat-mdc-icon-button .mat-icon{z-index:1;position:relative}.mat-mdc-icon-button .mat-focus-indicator{top:0;left:0;right:0;bottom:0;position:absolute}.mat-mdc-icon-button:focus .mat-focus-indicator::before{content:""}.mat-mdc-icon-button .mat-ripple-element{background-color:var(--mat-icon-button-ripple-color, color-mix(in srgb, var(--mat-sys-on-surface-variant) calc(var(--mat-sys-pressed-state-layer-opacity) * 100%), transparent))}.mat-mdc-icon-button .mat-mdc-button-persistent-ripple::before{background-color:var(--mat-icon-button-state-layer-color, var(--mat-sys-on-surface-variant))}.mat-mdc-icon-button.mat-mdc-button-disabled .mat-mdc-button-persistent-ripple::before{background-color:var(--mat-icon-button-disabled-state-layer-color, var(--mat-sys-on-surface-variant))}.mat-mdc-icon-button:hover .mat-mdc-button-persistent-ripple::before{opacity:var(--mat-icon-button-hover-state-layer-opacity, var(--mat-sys-hover-state-layer-opacity))}.mat-mdc-icon-button.cdk-program-focused .mat-mdc-button-persistent-ripple::before,.mat-mdc-icon-button.cdk-keyboard-focused .mat-mdc-button-persistent-ripple::before,.mat-mdc-icon-button.mat-mdc-button-disabled-interactive:focus .mat-mdc-button-persistent-ripple::before{opacity:var(--mat-icon-button-focus-state-layer-opacity, var(--mat-sys-focus-state-layer-opacity))}.mat-mdc-icon-button:active .mat-mdc-button-persistent-ripple::before{opacity:var(--mat-icon-button-pressed-state-layer-opacity, var(--mat-sys-pressed-state-layer-opacity))}.mat-mdc-icon-button .mat-mdc-button-touch-target{position:absolute;top:50%;height:48px;left:50%;width:48px;transform:translate(-50%, -50%);display:var(--mat-icon-button-touch-target-display, block)}.mat-mdc-icon-button._mat-animation-noopable{transition:none !important;animation:none !important}.mat-mdc-icon-button[disabled],.mat-mdc-icon-button.mat-mdc-button-disabled{cursor:default;pointer-events:none;color:var(--mdc-icon-button-disabled-icon-color, color-mix(in srgb, var(--mat-sys-on-surface) 38%, transparent))}.mat-mdc-icon-button.mat-mdc-button-disabled-interactive{pointer-events:auto}.mat-mdc-icon-button img,.mat-mdc-icon-button svg{width:var(--mdc-icon-button-icon-size, 24px);height:var(--mdc-icon-button-icon-size, 24px);vertical-align:baseline}.mat-mdc-icon-button .mat-mdc-button-persistent-ripple{border-radius:50%}.mat-mdc-icon-button[hidden]{display:none}.mat-mdc-icon-button.mat-unthemed:not(.mdc-ripple-upgraded):focus::before,.mat-mdc-icon-button.mat-primary:not(.mdc-ripple-upgraded):focus::before,.mat-mdc-icon-button.mat-accent:not(.mdc-ripple-upgraded):focus::before,.mat-mdc-icon-button.mat-warn:not(.mdc-ripple-upgraded):focus::before{background:rgba(0,0,0,0);opacity:1}',O],encapsulation:2,changeDetection:0})}return yn})(),bn=(()=>{class yn extends De{static \u0275fac=(()=>{let _t;return function($e){return(_t||(_t=i.xGo(yn)))($e||yn)}})();static \u0275cmp=i.VBU({type:yn,selectors:[["a","mat-icon-button",""]],hostVars:15,hostBindings:function(ze,$e){2&ze&&(i.BMQ("disabled",$e._getDisabledAttribute())("tabindex",$e.disabled&&!$e.disabledInteractive?-1:$e.tabIndex)("aria-disabled",$e._getAriaDisabled()),i.HbH($e.color?"mat-"+$e.color:""),i.AVh("mat-mdc-button-disabled",$e.disabled)("mat-mdc-button-disabled-interactive",$e.disabledInteractive)("_mat-animation-noopable","NoopAnimations"===$e._animationMode)("mat-unthemed",!$e.color)("mat-mdc-button-base",!0))},exportAs:["matButton","matAnchor"],features:[i.Vt3],attrs:re,ngContentSelectors:pe,decls:4,vars:0,consts:[[1,"mat-mdc-button-persistent-ripple","mdc-icon-button__ripple"],[1,"mat-focus-indicator"],[1,"mat-mdc-button-touch-target"]],template:function(ze,$e){1&ze&&(i.NAR(),i.nrm(0,"span",0),i.SdG(1),i.nrm(2,"span",1)(3,"span",2))},styles:['.mat-mdc-icon-button{-webkit-user-select:none;user-select:none;display:inline-block;position:relative;box-sizing:border-box;border:none;outline:none;background-color:rgba(0,0,0,0);fill:currentColor;color:inherit;text-decoration:none;cursor:pointer;z-index:0;overflow:visible;border-radius:50%;flex-shrink:0;text-align:center;width:var(--mdc-icon-button-state-layer-size, 40px);height:var(--mdc-icon-button-state-layer-size, 40px);padding:calc(calc(var(--mdc-icon-button-state-layer-size, 40px) - var(--mdc-icon-button-icon-size, 24px)) / 2);font-size:var(--mdc-icon-button-icon-size, 24px);color:var(--mdc-icon-button-icon-color, var(--mat-sys-on-surface-variant));-webkit-tap-highlight-color:rgba(0,0,0,0)}.mat-mdc-icon-button .mat-mdc-button-ripple,.mat-mdc-icon-button .mat-mdc-button-persistent-ripple,.mat-mdc-icon-button .mat-mdc-button-persistent-ripple::before{top:0;left:0;right:0;bottom:0;position:absolute;pointer-events:none;border-radius:inherit}.mat-mdc-icon-button .mat-mdc-button-ripple{overflow:hidden}.mat-mdc-icon-button .mat-mdc-button-persistent-ripple::before{content:"";opacity:0}.mat-mdc-icon-button .mdc-button__label,.mat-mdc-icon-button .mat-icon{z-index:1;position:relative}.mat-mdc-icon-button .mat-focus-indicator{top:0;left:0;right:0;bottom:0;position:absolute}.mat-mdc-icon-button:focus .mat-focus-indicator::before{content:""}.mat-mdc-icon-button .mat-ripple-element{background-color:var(--mat-icon-button-ripple-color, color-mix(in srgb, var(--mat-sys-on-surface-variant) calc(var(--mat-sys-pressed-state-layer-opacity) * 100%), transparent))}.mat-mdc-icon-button .mat-mdc-button-persistent-ripple::before{background-color:var(--mat-icon-button-state-layer-color, var(--mat-sys-on-surface-variant))}.mat-mdc-icon-button.mat-mdc-button-disabled .mat-mdc-button-persistent-ripple::before{background-color:var(--mat-icon-button-disabled-state-layer-color, var(--mat-sys-on-surface-variant))}.mat-mdc-icon-button:hover .mat-mdc-button-persistent-ripple::before{opacity:var(--mat-icon-button-hover-state-layer-opacity, var(--mat-sys-hover-state-layer-opacity))}.mat-mdc-icon-button.cdk-program-focused .mat-mdc-button-persistent-ripple::before,.mat-mdc-icon-button.cdk-keyboard-focused .mat-mdc-button-persistent-ripple::before,.mat-mdc-icon-button.mat-mdc-button-disabled-interactive:focus .mat-mdc-button-persistent-ripple::before{opacity:var(--mat-icon-button-focus-state-layer-opacity, var(--mat-sys-focus-state-layer-opacity))}.mat-mdc-icon-button:active .mat-mdc-button-persistent-ripple::before{opacity:var(--mat-icon-button-pressed-state-layer-opacity, var(--mat-sys-pressed-state-layer-opacity))}.mat-mdc-icon-button .mat-mdc-button-touch-target{position:absolute;top:50%;height:48px;left:50%;width:48px;transform:translate(-50%, -50%);display:var(--mat-icon-button-touch-target-display, block)}.mat-mdc-icon-button._mat-animation-noopable{transition:none !important;animation:none !important}.mat-mdc-icon-button[disabled],.mat-mdc-icon-button.mat-mdc-button-disabled{cursor:default;pointer-events:none;color:var(--mdc-icon-button-disabled-icon-color, color-mix(in srgb, var(--mat-sys-on-surface) 38%, transparent))}.mat-mdc-icon-button.mat-mdc-button-disabled-interactive{pointer-events:auto}.mat-mdc-icon-button img,.mat-mdc-icon-button svg{width:var(--mdc-icon-button-icon-size, 24px);height:var(--mdc-icon-button-icon-size, 24px);vertical-align:baseline}.mat-mdc-icon-button .mat-mdc-button-persistent-ripple{border-radius:50%}.mat-mdc-icon-button[hidden]{display:none}.mat-mdc-icon-button.mat-unthemed:not(.mdc-ripple-upgraded):focus::before,.mat-mdc-icon-button.mat-primary:not(.mdc-ripple-upgraded):focus::before,.mat-mdc-icon-button.mat-accent:not(.mdc-ripple-upgraded):focus::before,.mat-mdc-icon-button.mat-warn:not(.mdc-ripple-upgraded):focus::before{background:rgba(0,0,0,0);opacity:1}',O],encapsulation:2,changeDetection:0})}return yn})(),Vn=(()=>{class yn{static \u0275fac=function(ze){return new(ze||yn)};static \u0275mod=i.$C({type:yn});static \u0275inj=i.G2t({imports:[y.yE,y.pZ,y.yE]})}return yn})()},2902:(o,s,r)=>{"use strict";r.d(s,{Ah:()=>Ze,Ej:()=>Tr,Ju:()=>Be,MI:()=>Le,MJ:()=>bt,N:()=>ce,QC:()=>N,Sy:()=>Tn,TL:()=>St,X0:()=>Ce,de:()=>lt,es:()=>Ke,is:()=>z,jb:()=>mt,pZ:()=>Fe,r6:()=>cn,tO:()=>Vr,wT:()=>ft,yE:()=>ue});var i=r(3107),a=r(8559),c=r(2944),y=r(8447),w=r(2147),C=r(3022),T=r(5467),S=r(5919),M=r(4460);const Z=["text"],q=[[["mat-icon"]],"*"],re=["mat-icon","*"];function pe(vt,Wt){if(1&vt&&i.nrm(0,"mat-pseudo-checkbox",1),2&vt){const Re=i.XpG();i.Y8G("disabled",Re.disabled)("state",Re.selected?"checked":"unchecked")}}function se(vt,Wt){if(1&vt&&i.nrm(0,"mat-pseudo-checkbox",3),2&vt){const Re=i.XpG();i.Y8G("disabled",Re.disabled)}}function ae(vt,Wt){if(1&vt&&(i.j41(0,"span",4),i.EFF(1),i.k0s()),2&vt){const Re=i.XpG();i.R7$(),i.SpI("(",Re.group.label,")")}}const me=["mat-internal-form-field",""],be=["*"],ce=new i.nKC("mat-sanity-checks",{providedIn:"root",factory:()=>!0});let ue=(()=>{class vt{constructor(){(0,i.WQX)(a.Q_)._applyBodyHighContrastModeCssClasses()}static \u0275fac=function(Ge){return new(Ge||vt)};static \u0275mod=i.$C({type:vt});static \u0275inj=i.G2t({imports:[c.jI,c.jI]})}return vt})();class Ce{_defaultMatcher;ngControl;_parentFormGroup;_parentForm;_stateChanges;errorState=!1;matcher;constructor(Wt,Re,Ge,Ve,Dt){this._defaultMatcher=Wt,this.ngControl=Re,this._parentFormGroup=Ge,this._parentForm=Ve,this._stateChanges=Dt}updateErrorState(){const Wt=this.errorState,Re=this._parentFormGroup||this._parentForm,Ge=this.matcher||this._defaultMatcher,Ve=this.ngControl?this.ngControl.control:null,Dt=Ge?.isErrorState(Ve,Re)??!1;Dt!==Wt&&(this.errorState=Dt,this._stateChanges.next())}}const Be=new i.nKC("MAT_DATE_LOCALE",{providedIn:"root",factory:function at(){return(0,i.WQX)(i.xe9)}}),dt="Method not implemented";class bt{locale;_localeChanges=new y.B;localeChanges=this._localeChanges;setTime(Wt,Re,Ge,Ve){throw new Error(dt)}getHours(Wt){throw new Error(dt)}getMinutes(Wt){throw new Error(dt)}getSeconds(Wt){throw new Error(dt)}parseTime(Wt,Re){throw new Error(dt)}addSeconds(Wt,Re){throw new Error(dt)}getValidDateOrNull(Wt){return this.isDateInstance(Wt)&&this.isValid(Wt)?Wt:null}deserialize(Wt){return null==Wt||this.isDateInstance(Wt)&&this.isValid(Wt)?Wt:this.invalid()}setLocale(Wt){this.locale=Wt,this._localeChanges.next()}compareDate(Wt,Re){return this.getYear(Wt)-this.getYear(Re)||this.getMonth(Wt)-this.getMonth(Re)||this.getDate(Wt)-this.getDate(Re)}compareTime(Wt,Re){return this.getHours(Wt)-this.getHours(Re)||this.getMinutes(Wt)-this.getMinutes(Re)||this.getSeconds(Wt)-this.getSeconds(Re)}sameDate(Wt,Re){if(Wt&&Re){let Ge=this.isValid(Wt),Ve=this.isValid(Re);return Ge&&Ve?!this.compareDate(Wt,Re):Ge==Ve}return Wt==Re}sameTime(Wt,Re){if(Wt&&Re){const Ge=this.isValid(Wt),Ve=this.isValid(Re);return Ge&&Ve?!this.compareTime(Wt,Re):Ge==Ve}return Wt==Re}clampDate(Wt,Re,Ge){return Re&&this.compareDate(Wt,Re)<0?Re:Ge&&this.compareDate(Wt,Ge)>0?Ge:Wt}}const lt=new i.nKC("mat-date-formats");let Ke=(()=>{class vt{isErrorState(Re,Ge){return!!(Re&&Re.invalid&&(Re.touched||Ge&&Ge.submitted))}static \u0275fac=function(Ge){return new(Ge||vt)};static \u0275prov=i.jDH({token:vt,factory:vt.\u0275fac,providedIn:"root"})}return vt})(),Ze=(()=>{class vt{static \u0275fac=function(Ge){return new(Ge||vt)};static \u0275cmp=i.VBU({type:vt,selectors:[["structural-styles"]],decls:0,vars:0,template:function(Ge,Ve){},styles:['.mat-focus-indicator{position:relative}.mat-focus-indicator::before{top:0;left:0;right:0;bottom:0;position:absolute;box-sizing:border-box;pointer-events:none;display:var(--mat-focus-indicator-display, none);border-width:var(--mat-focus-indicator-border-width, 3px);border-style:var(--mat-focus-indicator-border-style, solid);border-color:var(--mat-focus-indicator-border-color, transparent);border-radius:var(--mat-focus-indicator-border-radius, 4px)}.mat-focus-indicator:focus::before{content:""}@media(forced-colors: active){html{--mat-focus-indicator-display: block}}'],encapsulation:2,changeDetection:0})}return vt})();var Ee=function(vt){return vt[vt.FADING_IN=0]="FADING_IN",vt[vt.VISIBLE=1]="VISIBLE",vt[vt.FADING_OUT=2]="FADING_OUT",vt[vt.HIDDEN=3]="HIDDEN",vt}(Ee||{});class st{_renderer;element;config;_animationForciblyDisabledThroughCss;state=Ee.HIDDEN;constructor(Wt,Re,Ge,Ve=!1){this._renderer=Wt,this.element=Re,this.config=Ge,this._animationForciblyDisabledThroughCss=Ve}fadeOut(){this._renderer.fadeOutRipple(this)}}const Xt=(0,w.BQ)({passive:!0,capture:!0});class Mt{_events=new Map;addHandler(Wt,Re,Ge,Ve){const Dt=this._events.get(Re);if(Dt){const ct=Dt.get(Ge);ct?ct.add(Ve):Dt.set(Ge,new Set([Ve]))}else this._events.set(Re,new Map([[Ge,new Set([Ve])]])),Wt.runOutsideAngular(()=>{document.addEventListener(Re,this._delegateEventHandler,Xt)})}removeHandler(Wt,Re,Ge){const Ve=this._events.get(Wt);if(!Ve)return;const Dt=Ve.get(Re);Dt&&(Dt.delete(Ge),0===Dt.size&&Ve.delete(Re),0===Ve.size&&(this._events.delete(Wt),document.removeEventListener(Wt,this._delegateEventHandler,Xt)))}_delegateEventHandler=Wt=>{const Re=(0,w.Fb)(Wt);Re&&this._events.get(Wt.type)?.forEach((Ge,Ve)=>{(Ve===Re||Ve.contains(Re))&&Ge.forEach(Dt=>Dt.handleEvent(Wt))})}}const Kt={enterDuration:225,exitDuration:150},Vt=(0,w.BQ)({passive:!0,capture:!0}),en=["mousedown","touchstart"],kn=["mouseup","mouseleave","touchend","touchcancel"];let Kn=(()=>{class vt{static \u0275fac=function(Ge){return new(Ge||vt)};static \u0275cmp=i.VBU({type:vt,selectors:[["ng-component"]],hostAttrs:["mat-ripple-style-loader",""],decls:0,vars:0,template:function(Ge,Ve){},styles:[".mat-ripple{overflow:hidden;position:relative}.mat-ripple:not(:empty){transform:translateZ(0)}.mat-ripple.mat-ripple-unbounded{overflow:visible}.mat-ripple-element{position:absolute;border-radius:50%;pointer-events:none;transition:opacity,transform 0ms cubic-bezier(0, 0, 0.2, 1);transform:scale3d(0, 0, 0);background-color:var(--mat-ripple-color, color-mix(in srgb, var(--mat-sys-on-surface) 10%, transparent))}@media(forced-colors: active){.mat-ripple-element{display:none}}.cdk-drag-preview .mat-ripple-element,.cdk-drag-placeholder .mat-ripple-element{display:none}"],encapsulation:2,changeDetection:0})}return vt})();class Nr{_target;_ngZone;_platform;_containerElement;_triggerElement;_isPointerDown=!1;_activeRipples=new Map;_mostRecentTransientRipple;_lastTouchStartEvent;_pointerUpEventsRegistered=!1;_containerRect;static _eventManager=new Mt;constructor(Wt,Re,Ge,Ve,Dt){this._target=Wt,this._ngZone=Re,this._platform=Ve,Ve.isBrowser&&(this._containerElement=(0,C.i8)(Ge)),Dt&&Dt.get(T.l).load(Kn)}fadeInRipple(Wt,Re,Ge={}){const Ve=this._containerRect=this._containerRect||this._containerElement.getBoundingClientRect(),Dt={...Kt,...Ge.animation};Ge.centered&&(Wt=Ve.left+Ve.width/2,Re=Ve.top+Ve.height/2);const ct=Ge.radius||function Rn(vt,Wt,Re){const Ge=Math.max(Math.abs(vt-Re.left),Math.abs(vt-Re.right)),Ve=Math.max(Math.abs(Wt-Re.top),Math.abs(Wt-Re.bottom));return Math.sqrt(Ge*Ge+Ve*Ve)}(Wt,Re,Ve),Bt=Wt-Ve.left,wn=Re-Ve.top,qn=Dt.enterDuration,Er=document.createElement("div");Er.classList.add("mat-ripple-element"),Er.style.left=Bt-ct+"px",Er.style.top=wn-ct+"px",Er.style.height=2*ct+"px",Er.style.width=2*ct+"px",null!=Ge.color&&(Er.style.backgroundColor=Ge.color),Er.style.transitionDuration=`${qn}ms`,this._containerElement.appendChild(Er);const si=window.getComputedStyle(Er),Zi=si.transitionDuration,Jt="none"===si.transitionProperty||"0s"===Zi||"0s, 0s"===Zi||0===Ve.width&&0===Ve.height,Tt=new st(this,Er,Ge,Jt);Er.style.transform="scale3d(1, 1, 1)",Tt.state=Ee.FADING_IN,Ge.persistent||(this._mostRecentTransientRipple=Tt);let nt=null;return!Jt&&(qn||Dt.exitDuration)&&this._ngZone.runOutsideAngular(()=>{const Rt=()=>{nt&&(nt.fallbackTimer=null),clearTimeout(mn),this._finishRippleTransition(Tt)},sn=()=>this._destroyRipple(Tt),mn=setTimeout(sn,qn+100);Er.addEventListener("transitionend",Rt),Er.addEventListener("transitioncancel",sn),nt={onTransitionEnd:Rt,onTransitionCancel:sn,fallbackTimer:mn}}),this._activeRipples.set(Tt,nt),(Jt||!qn)&&this._finishRippleTransition(Tt),Tt}fadeOutRipple(Wt){if(Wt.state===Ee.FADING_OUT||Wt.state===Ee.HIDDEN)return;const Re=Wt.element,Ge={...Kt,...Wt.config.animation};Re.style.transitionDuration=`${Ge.exitDuration}ms`,Re.style.opacity="0",Wt.state=Ee.FADING_OUT,(Wt._animationForciblyDisabledThroughCss||!Ge.exitDuration)&&this._finishRippleTransition(Wt)}fadeOutAll(){this._getActiveRipples().forEach(Wt=>Wt.fadeOut())}fadeOutAllNonPersistent(){this._getActiveRipples().forEach(Wt=>{Wt.config.persistent||Wt.fadeOut()})}setupTriggerEvents(Wt){const Re=(0,C.i8)(Wt);!this._platform.isBrowser||!Re||Re===this._triggerElement||(this._removeTriggerEvents(),this._triggerElement=Re,en.forEach(Ge=>{Nr._eventManager.addHandler(this._ngZone,Ge,Re,this)}))}handleEvent(Wt){"mousedown"===Wt.type?this._onMousedown(Wt):"touchstart"===Wt.type?this._onTouchStart(Wt):this._onPointerUp(),this._pointerUpEventsRegistered||(this._ngZone.runOutsideAngular(()=>{kn.forEach(Re=>{this._triggerElement.addEventListener(Re,this,Vt)})}),this._pointerUpEventsRegistered=!0)}_finishRippleTransition(Wt){Wt.state===Ee.FADING_IN?this._startFadeOutTransition(Wt):Wt.state===Ee.FADING_OUT&&this._destroyRipple(Wt)}_startFadeOutTransition(Wt){const Re=Wt===this._mostRecentTransientRipple,{persistent:Ge}=Wt.config;Wt.state=Ee.VISIBLE,!Ge&&(!Re||!this._isPointerDown)&&Wt.fadeOut()}_destroyRipple(Wt){const Re=this._activeRipples.get(Wt)??null;this._activeRipples.delete(Wt),this._activeRipples.size||(this._containerRect=null),Wt===this._mostRecentTransientRipple&&(this._mostRecentTransientRipple=null),Wt.state=Ee.HIDDEN,null!==Re&&(Wt.element.removeEventListener("transitionend",Re.onTransitionEnd),Wt.element.removeEventListener("transitioncancel",Re.onTransitionCancel),null!==Re.fallbackTimer&&clearTimeout(Re.fallbackTimer)),Wt.element.remove()}_onMousedown(Wt){const Re=(0,a._G)(Wt),Ge=this._lastTouchStartEvent&&Date.now(){!Wt.config.persistent&&(Wt.state===Ee.VISIBLE||Wt.config.terminateOnPointerUp&&Wt.state===Ee.FADING_IN)&&Wt.fadeOut()}))}_getActiveRipples(){return Array.from(this._activeRipples.keys())}_removeTriggerEvents(){const Wt=this._triggerElement;Wt&&(en.forEach(Re=>Nr._eventManager.removeHandler(Re,Wt,this)),this._pointerUpEventsRegistered&&(kn.forEach(Re=>Wt.removeEventListener(Re,this,Vt)),this._pointerUpEventsRegistered=!1))}}const pr=new i.nKC("mat-ripple-global-options");let cn=(()=>{class vt{_elementRef=(0,i.WQX)(i.aKT);_animationMode=(0,i.WQX)(i.bc$,{optional:!0});color;unbounded;centered;radius=0;animation;get disabled(){return this._disabled}set disabled(Re){Re&&this.fadeOutAllNonPersistent(),this._disabled=Re,this._setupTriggerEventsIfEnabled()}_disabled=!1;get trigger(){return this._trigger||this._elementRef.nativeElement}set trigger(Re){this._trigger=Re,this._setupTriggerEventsIfEnabled()}_trigger;_rippleRenderer;_globalOptions;_isInitialized=!1;constructor(){const Re=(0,i.WQX)(i.SKi),Ge=(0,i.WQX)(w.OD),Ve=(0,i.WQX)(pr,{optional:!0}),Dt=(0,i.WQX)(i.zZn);this._globalOptions=Ve||{},this._rippleRenderer=new Nr(this,Re,this._elementRef,Ge,Dt)}ngOnInit(){this._isInitialized=!0,this._setupTriggerEventsIfEnabled()}ngOnDestroy(){this._rippleRenderer._removeTriggerEvents()}fadeOutAll(){this._rippleRenderer.fadeOutAll()}fadeOutAllNonPersistent(){this._rippleRenderer.fadeOutAllNonPersistent()}get rippleConfig(){return{centered:this.centered,radius:this.radius,color:this.color,animation:{...this._globalOptions.animation,..."NoopAnimations"===this._animationMode?{enterDuration:0,exitDuration:0}:{},...this.animation},terminateOnPointerUp:this._globalOptions.terminateOnPointerUp}}get rippleDisabled(){return this.disabled||!!this._globalOptions.disabled}_setupTriggerEventsIfEnabled(){!this.disabled&&this._isInitialized&&this._rippleRenderer.setupTriggerEvents(this.trigger)}launch(Re,Ge=0,Ve){return"number"==typeof Re?this._rippleRenderer.fadeInRipple(Re,Ge,{...this.rippleConfig,...Ve}):this._rippleRenderer.fadeInRipple(0,0,{...this.rippleConfig,...Re})}static \u0275fac=function(Ge){return new(Ge||vt)};static \u0275dir=i.FsC({type:vt,selectors:[["","mat-ripple",""],["","matRipple",""]],hostAttrs:[1,"mat-ripple"],hostVars:2,hostBindings:function(Ge,Ve){2&Ge&&i.AVh("mat-ripple-unbounded",Ve.unbounded)},inputs:{color:[0,"matRippleColor","color"],unbounded:[0,"matRippleUnbounded","unbounded"],centered:[0,"matRippleCentered","centered"],radius:[0,"matRippleRadius","radius"],animation:[0,"matRippleAnimation","animation"],disabled:[0,"matRippleDisabled","disabled"],trigger:[0,"matRippleTrigger","trigger"]},exportAs:["matRipple"]})}return vt})(),Fe=(()=>{class vt{static \u0275fac=function(Ge){return new(Ge||vt)};static \u0275mod=i.$C({type:vt});static \u0275inj=i.G2t({imports:[ue,ue]})}return vt})(),ke=(()=>{class vt{_animationMode=(0,i.WQX)(i.bc$,{optional:!0});state="unchecked";disabled=!1;appearance="full";constructor(){}static \u0275fac=function(Ge){return new(Ge||vt)};static \u0275cmp=i.VBU({type:vt,selectors:[["mat-pseudo-checkbox"]],hostAttrs:[1,"mat-pseudo-checkbox"],hostVars:12,hostBindings:function(Ge,Ve){2&Ge&&i.AVh("mat-pseudo-checkbox-indeterminate","indeterminate"===Ve.state)("mat-pseudo-checkbox-checked","checked"===Ve.state)("mat-pseudo-checkbox-disabled",Ve.disabled)("mat-pseudo-checkbox-minimal","minimal"===Ve.appearance)("mat-pseudo-checkbox-full","full"===Ve.appearance)("_mat-animation-noopable","NoopAnimations"===Ve._animationMode)},inputs:{state:"state",disabled:"disabled",appearance:"appearance"},decls:0,vars:0,template:function(Ge,Ve){},styles:['.mat-pseudo-checkbox{border-radius:2px;cursor:pointer;display:inline-block;vertical-align:middle;box-sizing:border-box;position:relative;flex-shrink:0;transition:border-color 90ms cubic-bezier(0, 0, 0.2, 0.1),background-color 90ms cubic-bezier(0, 0, 0.2, 0.1)}.mat-pseudo-checkbox::after{position:absolute;opacity:0;content:"";border-bottom:2px solid currentColor;transition:opacity 90ms cubic-bezier(0, 0, 0.2, 0.1)}.mat-pseudo-checkbox._mat-animation-noopable{transition:none !important;animation:none !important}.mat-pseudo-checkbox._mat-animation-noopable::after{transition:none}.mat-pseudo-checkbox-disabled{cursor:default}.mat-pseudo-checkbox-indeterminate::after{left:1px;opacity:1;border-radius:2px}.mat-pseudo-checkbox-checked::after{left:1px;border-left:2px solid currentColor;transform:rotate(-45deg);opacity:1;box-sizing:content-box}.mat-pseudo-checkbox-minimal.mat-pseudo-checkbox-checked::after,.mat-pseudo-checkbox-minimal.mat-pseudo-checkbox-indeterminate::after{color:var(--mat-minimal-pseudo-checkbox-selected-checkmark-color, var(--mat-sys-primary))}.mat-pseudo-checkbox-minimal.mat-pseudo-checkbox-checked.mat-pseudo-checkbox-disabled::after,.mat-pseudo-checkbox-minimal.mat-pseudo-checkbox-indeterminate.mat-pseudo-checkbox-disabled::after{color:var(--mat-minimal-pseudo-checkbox-disabled-selected-checkmark-color, color-mix(in srgb, var(--mat-sys-on-surface) 38%, transparent))}.mat-pseudo-checkbox-full{border-color:var(--mat-full-pseudo-checkbox-unselected-icon-color, var(--mat-sys-on-surface-variant));border-width:2px;border-style:solid}.mat-pseudo-checkbox-full.mat-pseudo-checkbox-disabled{border-color:var(--mat-full-pseudo-checkbox-disabled-unselected-icon-color, color-mix(in srgb, var(--mat-sys-on-surface) 38%, transparent))}.mat-pseudo-checkbox-full.mat-pseudo-checkbox-checked,.mat-pseudo-checkbox-full.mat-pseudo-checkbox-indeterminate{background-color:var(--mat-full-pseudo-checkbox-selected-icon-color, var(--mat-sys-primary));border-color:rgba(0,0,0,0)}.mat-pseudo-checkbox-full.mat-pseudo-checkbox-checked::after,.mat-pseudo-checkbox-full.mat-pseudo-checkbox-indeterminate::after{color:var(--mat-full-pseudo-checkbox-selected-checkmark-color, var(--mat-sys-on-primary))}.mat-pseudo-checkbox-full.mat-pseudo-checkbox-checked.mat-pseudo-checkbox-disabled,.mat-pseudo-checkbox-full.mat-pseudo-checkbox-indeterminate.mat-pseudo-checkbox-disabled{background-color:var(--mat-full-pseudo-checkbox-disabled-selected-icon-color, color-mix(in srgb, var(--mat-sys-on-surface) 38%, transparent))}.mat-pseudo-checkbox-full.mat-pseudo-checkbox-checked.mat-pseudo-checkbox-disabled::after,.mat-pseudo-checkbox-full.mat-pseudo-checkbox-indeterminate.mat-pseudo-checkbox-disabled::after{color:var(--mat-full-pseudo-checkbox-disabled-selected-checkmark-color, var(--mat-sys-surface))}.mat-pseudo-checkbox{width:18px;height:18px}.mat-pseudo-checkbox-minimal.mat-pseudo-checkbox-checked::after{width:14px;height:6px;transform-origin:center;top:-4.2426406871px;left:0;bottom:0;right:0;margin:auto}.mat-pseudo-checkbox-minimal.mat-pseudo-checkbox-indeterminate::after{top:8px;width:16px}.mat-pseudo-checkbox-full.mat-pseudo-checkbox-checked::after{width:10px;height:4px;transform-origin:center;top:-2.8284271247px;left:0;bottom:0;right:0;margin:auto}.mat-pseudo-checkbox-full.mat-pseudo-checkbox-indeterminate::after{top:6px;width:12px}'],encapsulation:2,changeDetection:0})}return vt})(),Je=(()=>{class vt{static \u0275fac=function(Ge){return new(Ge||vt)};static \u0275mod=i.$C({type:vt});static \u0275inj=i.G2t({imports:[ue]})}return vt})();const z=new i.nKC("MAT_OPTION_PARENT_COMPONENT"),N=new i.nKC("MatOptgroup");class Le{source;isUserInput;constructor(Wt,Re=!1){this.source=Wt,this.isUserInput=Re}}let ft=(()=>{class vt{_element=(0,i.WQX)(i.aKT);_changeDetectorRef=(0,i.WQX)(i.gRc);_parent=(0,i.WQX)(z,{optional:!0});group=(0,i.WQX)(N,{optional:!0});_signalDisableRipple=!1;_selected=!1;_active=!1;_disabled=!1;_mostRecentViewValue="";get multiple(){return this._parent&&this._parent.multiple}get selected(){return this._selected}value;id=(0,i.WQX)(a.g7).getId("mat-option-");get disabled(){return this.group&&this.group.disabled||this._disabled}set disabled(Re){this._disabled=Re}get disableRipple(){return this._signalDisableRipple?this._parent.disableRipple():!!this._parent?.disableRipple}get hideSingleSelectionIndicator(){return!(!this._parent||!this._parent.hideSingleSelectionIndicator)}onSelectionChange=new i.bkB;_text;_stateChanges=new y.B;constructor(){(0,i.WQX)(T.l).load(Ze),(0,i.WQX)(T.l).load(T.Y),this._signalDisableRipple=!!this._parent&&(0,i.Hps)(this._parent.disableRipple)}get active(){return this._active}get viewValue(){return(this._text?.nativeElement.textContent||"").trim()}select(Re=!0){this._selected||(this._selected=!0,this._changeDetectorRef.markForCheck(),Re&&this._emitSelectionChangeEvent())}deselect(Re=!0){this._selected&&(this._selected=!1,this._changeDetectorRef.markForCheck(),Re&&this._emitSelectionChangeEvent())}focus(Re,Ge){const Ve=this._getHostElement();"function"==typeof Ve.focus&&Ve.focus(Ge)}setActiveStyles(){this._active||(this._active=!0,this._changeDetectorRef.markForCheck())}setInactiveStyles(){this._active&&(this._active=!1,this._changeDetectorRef.markForCheck())}getLabel(){return this.viewValue}_handleKeydown(Re){(Re.keyCode===S.Fm||Re.keyCode===S.t6)&&!(0,S.rp)(Re)&&(this._selectViaInteraction(),Re.preventDefault())}_selectViaInteraction(){this.disabled||(this._selected=!this.multiple||!this._selected,this._changeDetectorRef.markForCheck(),this._emitSelectionChangeEvent(!0))}_getTabIndex(){return this.disabled?"-1":"0"}_getHostElement(){return this._element.nativeElement}ngAfterViewChecked(){if(this._selected){const Re=this.viewValue;Re!==this._mostRecentViewValue&&(this._mostRecentViewValue&&this._stateChanges.next(),this._mostRecentViewValue=Re)}}ngOnDestroy(){this._stateChanges.complete()}_emitSelectionChangeEvent(Re=!1){this.onSelectionChange.emit(new Le(this,Re))}static \u0275fac=function(Ge){return new(Ge||vt)};static \u0275cmp=i.VBU({type:vt,selectors:[["mat-option"]],viewQuery:function(Ge,Ve){if(1&Ge&&i.GBs(Z,7),2&Ge){let Dt;i.mGM(Dt=i.lsd())&&(Ve._text=Dt.first)}},hostAttrs:["role","option",1,"mat-mdc-option","mdc-list-item"],hostVars:11,hostBindings:function(Ge,Ve){1&Ge&&i.bIt("click",function(){return Ve._selectViaInteraction()})("keydown",function(ct){return Ve._handleKeydown(ct)}),2&Ge&&(i.Mr5("id",Ve.id),i.BMQ("aria-selected",Ve.selected)("aria-disabled",Ve.disabled.toString()),i.AVh("mdc-list-item--selected",Ve.selected)("mat-mdc-option-multiple",Ve.multiple)("mat-mdc-option-active",Ve.active)("mdc-list-item--disabled",Ve.disabled))},inputs:{value:"value",id:"id",disabled:[2,"disabled","disabled",i.L39]},outputs:{onSelectionChange:"onSelectionChange"},exportAs:["matOption"],features:[i.GFd],ngContentSelectors:re,decls:8,vars:5,consts:[["text",""],["aria-hidden","true",1,"mat-mdc-option-pseudo-checkbox",3,"disabled","state"],[1,"mdc-list-item__primary-text"],["state","checked","aria-hidden","true","appearance","minimal",1,"mat-mdc-option-pseudo-checkbox",3,"disabled"],[1,"cdk-visually-hidden"],["aria-hidden","true","mat-ripple","",1,"mat-mdc-option-ripple","mat-focus-indicator",3,"matRippleTrigger","matRippleDisabled"]],template:function(Ge,Ve){1&Ge&&(i.NAR(q),i.DNE(0,pe,1,2,"mat-pseudo-checkbox",1),i.SdG(1),i.j41(2,"span",2,0),i.SdG(4,1),i.k0s(),i.DNE(5,se,1,1,"mat-pseudo-checkbox",3)(6,ae,2,1,"span",4),i.nrm(7,"div",5)),2&Ge&&(i.vxM(Ve.multiple?0:-1),i.R7$(5),i.vxM(Ve.multiple||!Ve.selected||Ve.hideSingleSelectionIndicator?-1:5),i.R7$(),i.vxM(Ve.group&&Ve.group._inert?6:-1),i.R7$(),i.Y8G("matRippleTrigger",Ve._getHostElement())("matRippleDisabled",Ve.disabled||Ve.disableRipple))},dependencies:[ke,cn],styles:['.mat-mdc-option{-webkit-user-select:none;user-select:none;-moz-osx-font-smoothing:grayscale;-webkit-font-smoothing:antialiased;display:flex;position:relative;align-items:center;justify-content:flex-start;overflow:hidden;min-height:48px;padding:0 16px;cursor:pointer;-webkit-tap-highlight-color:rgba(0,0,0,0);color:var(--mat-option-label-text-color, var(--mat-sys-on-surface));font-family:var(--mat-option-label-text-font, var(--mat-sys-label-large-font));line-height:var(--mat-option-label-text-line-height, var(--mat-sys-label-large-line-height));font-size:var(--mat-option-label-text-size, var(--mat-sys-body-large-size));letter-spacing:var(--mat-option-label-text-tracking, var(--mat-sys-label-large-tracking));font-weight:var(--mat-option-label-text-weight, var(--mat-sys-body-large-weight))}.mat-mdc-option:hover:not(.mdc-list-item--disabled){background-color:var(--mat-option-hover-state-layer-color, color-mix(in srgb, var(--mat-sys-on-surface) calc(var(--mat-sys-hover-state-layer-opacity) * 100%), transparent))}.mat-mdc-option:focus.mdc-list-item,.mat-mdc-option.mat-mdc-option-active.mdc-list-item{background-color:var(--mat-option-focus-state-layer-color, color-mix(in srgb, var(--mat-sys-on-surface) calc(var(--mat-sys-focus-state-layer-opacity) * 100%), transparent));outline:0}.mat-mdc-option.mdc-list-item--selected:not(.mdc-list-item--disabled) .mdc-list-item__primary-text{color:var(--mat-option-selected-state-label-text-color, var(--mat-sys-on-secondary-container))}.mat-mdc-option.mdc-list-item--selected:not(.mdc-list-item--disabled):not(.mat-mdc-option-multiple){background-color:var(--mat-option-selected-state-layer-color, var(--mat-sys-secondary-container))}.mat-mdc-option .mat-pseudo-checkbox{--mat-minimal-pseudo-checkbox-selected-checkmark-color: var(--mat-option-selected-state-label-text-color, var(--mat-sys-on-secondary-container))}.mat-mdc-option.mdc-list-item{align-items:center;background:rgba(0,0,0,0)}.mat-mdc-option.mdc-list-item--disabled{cursor:default;pointer-events:none}.mat-mdc-option.mdc-list-item--disabled .mat-mdc-option-pseudo-checkbox,.mat-mdc-option.mdc-list-item--disabled .mdc-list-item__primary-text,.mat-mdc-option.mdc-list-item--disabled>mat-icon{opacity:.38}.mat-mdc-optgroup .mat-mdc-option:not(.mat-mdc-option-multiple){padding-left:32px}[dir=rtl] .mat-mdc-optgroup .mat-mdc-option:not(.mat-mdc-option-multiple){padding-left:16px;padding-right:32px}.mat-mdc-option .mat-icon,.mat-mdc-option .mat-pseudo-checkbox-full{margin-right:16px;flex-shrink:0}[dir=rtl] .mat-mdc-option .mat-icon,[dir=rtl] .mat-mdc-option .mat-pseudo-checkbox-full{margin-right:0;margin-left:16px}.mat-mdc-option .mat-pseudo-checkbox-minimal{margin-left:16px;flex-shrink:0}[dir=rtl] .mat-mdc-option .mat-pseudo-checkbox-minimal{margin-right:16px;margin-left:0}.mat-mdc-option .mat-mdc-option-ripple{top:0;left:0;right:0;bottom:0;position:absolute;pointer-events:none}.mat-mdc-option .mdc-list-item__primary-text{white-space:normal;font-size:inherit;font-weight:inherit;letter-spacing:inherit;line-height:inherit;font-family:inherit;text-decoration:inherit;text-transform:inherit;margin-right:auto}[dir=rtl] .mat-mdc-option .mdc-list-item__primary-text{margin-right:0;margin-left:auto}@media(forced-colors: active){.mat-mdc-option.mdc-list-item--selected:not(:has(.mat-mdc-option-pseudo-checkbox))::after{content:"";position:absolute;top:50%;right:16px;transform:translateY(-50%);width:10px;height:0;border-bottom:solid 10px;border-radius:10px}[dir=rtl] .mat-mdc-option.mdc-list-item--selected:not(:has(.mat-mdc-option-pseudo-checkbox))::after{right:auto;left:16px}}.mat-mdc-option-multiple{--mdc-list-list-item-selected-container-color:var(--mdc-list-list-item-container-color, transparent)}.mat-mdc-option-active .mat-focus-indicator::before{content:""}'],encapsulation:2,changeDetection:0})}return vt})();function mt(vt,Wt,Re){if(Re.length){let Ge=Wt.toArray(),Ve=Re.toArray(),Dt=0;for(let ct=0;ctRe+Ge?Math.max(0,vt-Ge+Wt):Re}let Tn=(()=>{class vt{static \u0275fac=function(Ge){return new(Ge||vt)};static \u0275mod=i.$C({type:vt});static \u0275inj=i.G2t({imports:[Fe,ue,Je]})}return vt})();const an={capture:!0},dn=["focus","mousedown","mouseenter","touchstart"],In="mat-ripple-loader-uninitialized",sr="mat-ripple-loader-class-name",xn="mat-ripple-loader-centered",Hr="mat-ripple-loader-disabled";let Tr=(()=>{class vt{_document=(0,i.WQX)(M.qQ,{optional:!0});_animationMode=(0,i.WQX)(i.bc$,{optional:!0});_globalRippleOptions=(0,i.WQX)(pr,{optional:!0});_platform=(0,i.WQX)(w.OD);_ngZone=(0,i.WQX)(i.SKi);_injector=(0,i.WQX)(i.zZn);_hosts=new Map;constructor(){this._ngZone.runOutsideAngular(()=>{for(const Re of dn)this._document?.addEventListener(Re,this._onInteraction,an)})}ngOnDestroy(){const Re=this._hosts.keys();for(const Ge of Re)this.destroyRipple(Ge);for(const Ge of dn)this._document?.removeEventListener(Ge,this._onInteraction,an)}configureRipple(Re,Ge){Re.setAttribute(In,this._globalRippleOptions?.namespace??""),(Ge.className||!Re.hasAttribute(sr))&&Re.setAttribute(sr,Ge.className||""),Ge.centered&&Re.setAttribute(xn,""),Ge.disabled&&Re.setAttribute(Hr,"")}setDisabled(Re,Ge){const Ve=this._hosts.get(Re);Ve?(Ve.target.rippleDisabled=Ge,!Ge&&!Ve.hasSetUpEvents&&(Ve.hasSetUpEvents=!0,Ve.renderer.setupTriggerEvents(Re))):Ge?Re.setAttribute(Hr,""):Re.removeAttribute(Hr)}_onInteraction=Re=>{const Ge=(0,w.Fb)(Re);if(Ge instanceof HTMLElement){const Ve=Ge.closest(`[${In}="${this._globalRippleOptions?.namespace??""}"]`);Ve&&this._createRipple(Ve)}};_createRipple(Re){if(!this._document||this._hosts.has(Re))return;Re.querySelector(".mat-ripple")?.remove();const Ge=this._document.createElement("span");Ge.classList.add("mat-ripple",Re.getAttribute(sr)),Re.append(Ge);const Ve="NoopAnimations"===this._animationMode,Dt=this._globalRippleOptions,ct=Ve?0:Dt?.animation?.enterDuration??Kt.enterDuration,Bt=Ve?0:Dt?.animation?.exitDuration??Kt.exitDuration,wn={rippleDisabled:Ve||Dt?.disabled||Re.hasAttribute(Hr),rippleConfig:{centered:Re.hasAttribute(xn),terminateOnPointerUp:Dt?.terminateOnPointerUp,animation:{enterDuration:ct,exitDuration:Bt}}},qn=new Nr(wn,this._ngZone,Ge,this._platform,this._injector),Er=!wn.rippleDisabled;Er&&qn.setupTriggerEvents(Re),this._hosts.set(Re,{target:wn,renderer:qn,hasSetUpEvents:Er}),Re.removeAttribute(In)}destroyRipple(Re){const Ge=this._hosts.get(Re);Ge&&(Ge.renderer._removeTriggerEvents(),this._hosts.delete(Re))}static \u0275fac=function(Ge){return new(Ge||vt)};static \u0275prov=i.jDH({token:vt,factory:vt.\u0275fac,providedIn:"root"})}return vt})(),Vr=(()=>{class vt{labelPosition;static \u0275fac=function(Ge){return new(Ge||vt)};static \u0275cmp=i.VBU({type:vt,selectors:[["div","mat-internal-form-field",""]],hostAttrs:[1,"mdc-form-field","mat-internal-form-field"],hostVars:2,hostBindings:function(Ge,Ve){2&Ge&&i.AVh("mdc-form-field--align-end","before"===Ve.labelPosition)},inputs:{labelPosition:"labelPosition"},attrs:me,ngContentSelectors:be,decls:1,vars:0,template:function(Ge,Ve){1&Ge&&(i.NAR(),i.SdG(0))},styles:[".mat-internal-form-field{-moz-osx-font-smoothing:grayscale;-webkit-font-smoothing:antialiased;display:inline-flex;align-items:center;vertical-align:middle}.mat-internal-form-field>label{margin-left:0;margin-right:auto;padding-left:4px;padding-right:0;order:0}[dir=rtl] .mat-internal-form-field>label{margin-left:auto;margin-right:0;padding-left:0;padding-right:4px}.mdc-form-field--align-end>label{margin-left:auto;margin-right:0;padding-left:0;padding-right:4px;order:-1}[dir=rtl] .mdc-form-field--align-end .mdc-form-field--align-end label{margin-left:0;margin-right:auto;padding-left:4px;padding-right:0}"],encapsulation:2,changeDetection:0})}return vt})()},7544:(o,s,r)=>{"use strict";r.d(s,{Vh:()=>Te,bZ:()=>Kt,E7:()=>Kn,tx:()=>rt,Yi:()=>kn,hM:()=>pr,CP:()=>Ot});var i=r(9666),a=r(3107),c=r(8559),y=r(2147),w=r(6192),C=r(4460),T=r(5919),S=r(8447),M=r(6381),O=r(3016),L=r(2944),Z=r(593);function q(ke,Je){}class re{viewContainerRef;injector;id;role="dialog";panelClass="";hasBackdrop=!0;backdropClass="";disableClose=!1;width="";height="";minWidth;minHeight;maxWidth;maxHeight;positionStrategy;data=null;direction;ariaDescribedBy=null;ariaLabelledBy=null;ariaLabel=null;ariaModal=!0;autoFocus="first-tabbable";restoreFocus=!0;scrollStrategy;closeOnNavigation=!0;closeOnDestroy=!0;closeOnOverlayDetachments=!0;componentFactoryResolver;providers;container;templateContext}let se=(()=>{class ke extends w.lb{_elementRef=(0,a.WQX)(a.aKT);_focusTrapFactory=(0,a.WQX)(c.GX);_config;_interactivityChecker=(0,a.WQX)(c.Z7);_ngZone=(0,a.WQX)(a.SKi);_overlayRef=(0,a.WQX)(i.yY);_focusMonitor=(0,a.WQX)(c.FN);_platform=(0,a.WQX)(y.OD);_document=(0,a.WQX)(C.qQ,{optional:!0});_portalOutlet;_focusTrap=null;_elementFocusedBeforeDialogWasOpened=null;_closeInteractionType=null;_ariaLabelledByQueue=[];_changeDetectorRef=(0,a.WQX)(a.gRc);_injector=(0,a.WQX)(a.zZn);_isDestroyed=!1;constructor(){super(),this._config=(0,a.WQX)(re,{optional:!0})||new re,this._config.ariaLabelledBy&&this._ariaLabelledByQueue.push(this._config.ariaLabelledBy)}_addAriaLabelledBy(z){this._ariaLabelledByQueue.push(z),this._changeDetectorRef.markForCheck()}_removeAriaLabelledBy(z){const N=this._ariaLabelledByQueue.indexOf(z);N>-1&&(this._ariaLabelledByQueue.splice(N,1),this._changeDetectorRef.markForCheck())}_contentAttached(){this._initializeFocusTrap(),this._handleBackdropClicks(),this._captureInitialFocus()}_captureInitialFocus(){this._trapFocus()}ngOnDestroy(){this._isDestroyed=!0,this._restoreFocus()}attachComponentPortal(z){this._portalOutlet.hasAttached();const N=this._portalOutlet.attachComponentPortal(z);return this._contentAttached(),N}attachTemplatePortal(z){this._portalOutlet.hasAttached();const N=this._portalOutlet.attachTemplatePortal(z);return this._contentAttached(),N}attachDomPortal=z=>{this._portalOutlet.hasAttached();const N=this._portalOutlet.attachDomPortal(z);return this._contentAttached(),N};_recaptureFocus(){this._containsFocus()||this._trapFocus()}_forceFocus(z,N){this._interactivityChecker.isFocusable(z)||(z.tabIndex=-1,this._ngZone.runOutsideAngular(()=>{const W=()=>{z.removeEventListener("blur",W),z.removeEventListener("mousedown",W),z.removeAttribute("tabindex")};z.addEventListener("blur",W),z.addEventListener("mousedown",W)})),z.focus(N)}_focusByCssSelector(z,N){let W=this._elementRef.nativeElement.querySelector(z);W&&this._forceFocus(W,N)}_trapFocus(){this._isDestroyed||(0,a.mal)(()=>{const z=this._elementRef.nativeElement;switch(this._config.autoFocus){case!1:case"dialog":this._containsFocus()||z.focus();break;case!0:case"first-tabbable":this._focusTrap?.focusInitialElement()||this._focusDialogContainer();break;case"first-heading":this._focusByCssSelector('h1, h2, h3, h4, h5, h6, [role="heading"]');break;default:this._focusByCssSelector(this._config.autoFocus)}},{injector:this._injector})}_restoreFocus(){const z=this._config.restoreFocus;let N=null;if("string"==typeof z?N=this._document.querySelector(z):"boolean"==typeof z?N=z?this._elementFocusedBeforeDialogWasOpened:null:z&&(N=z),this._config.restoreFocus&&N&&"function"==typeof N.focus){const W=(0,y.vc)(),Le=this._elementRef.nativeElement;(!W||W===this._document.body||W===Le||Le.contains(W))&&(this._focusMonitor?(this._focusMonitor.focusVia(N,this._closeInteractionType),this._closeInteractionType=null):N.focus())}this._focusTrap&&this._focusTrap.destroy()}_focusDialogContainer(){this._elementRef.nativeElement.focus&&this._elementRef.nativeElement.focus()}_containsFocus(){const z=this._elementRef.nativeElement,N=(0,y.vc)();return z===N||z.contains(N)}_initializeFocusTrap(){this._platform.isBrowser&&(this._focusTrap=this._focusTrapFactory.create(this._elementRef.nativeElement),this._document&&(this._elementFocusedBeforeDialogWasOpened=(0,y.vc)()))}_handleBackdropClicks(){this._overlayRef.backdropClick().subscribe(()=>{this._config.disableClose&&this._recaptureFocus()})}static \u0275fac=function(N){return new(N||ke)};static \u0275cmp=a.VBU({type:ke,selectors:[["cdk-dialog-container"]],viewQuery:function(N,W){if(1&N&&a.GBs(w.I3,7),2&N){let Le;a.mGM(Le=a.lsd())&&(W._portalOutlet=Le.first)}},hostAttrs:["tabindex","-1",1,"cdk-dialog-container"],hostVars:6,hostBindings:function(N,W){2&N&&a.BMQ("id",W._config.id||null)("role",W._config.role)("aria-modal",W._config.ariaModal)("aria-labelledby",W._config.ariaLabel?null:W._ariaLabelledByQueue[0])("aria-label",W._config.ariaLabel)("aria-describedby",W._config.ariaDescribedBy||null)},features:[a.Vt3],decls:1,vars:0,consts:[["cdkPortalOutlet",""]],template:function(N,W){1&N&&a.DNE(0,q,0,0,"ng-template",0)},dependencies:[w.I3],styles:[".cdk-dialog-container{display:block;width:100%;height:100%;min-height:inherit;max-height:inherit}"],encapsulation:2})}return ke})();class ae{overlayRef;config;componentInstance;componentRef;containerInstance;disableClose;closed=new S.B;backdropClick;keydownEvents;outsidePointerEvents;id;_detachSubscription;constructor(Je,z){this.overlayRef=Je,this.config=z,this.disableClose=z.disableClose,this.backdropClick=Je.backdropClick(),this.keydownEvents=Je.keydownEvents(),this.outsidePointerEvents=Je.outsidePointerEvents(),this.id=z.id,this.keydownEvents.subscribe(N=>{N.keyCode===T._f&&!this.disableClose&&!(0,T.rp)(N)&&(N.preventDefault(),this.close(void 0,{focusOrigin:"keyboard"}))}),this.backdropClick.subscribe(()=>{this.disableClose||this.close(void 0,{focusOrigin:"mouse"})}),this._detachSubscription=Je.detachments().subscribe(()=>{!1!==z.closeOnOverlayDetachments&&this.close()})}close(Je,z){if(this.containerInstance){const N=this.closed;this.containerInstance._closeInteractionType=z?.focusOrigin||"program",this._detachSubscription.unsubscribe(),this.overlayRef.dispose(),N.next(Je),N.complete(),this.componentInstance=this.containerInstance=null}}updatePosition(){return this.overlayRef.updatePosition(),this}updateSize(Je="",z=""){return this.overlayRef.updateSize({width:Je,height:z}),this}addPanelClass(Je){return this.overlayRef.addPanelClass(Je),this}removePanelClass(Je){return this.overlayRef.removePanelClass(Je),this}}const me=new a.nKC("DialogScrollStrategy",{providedIn:"root",factory:()=>{const ke=(0,a.WQX)(i.hJ);return()=>ke.scrollStrategies.block()}}),be=new a.nKC("DialogData"),Oe=new a.nKC("DefaultDialogConfig");let ce=(()=>{class ke{_overlay=(0,a.WQX)(i.hJ);_injector=(0,a.WQX)(a.zZn);_defaultOptions=(0,a.WQX)(Oe,{optional:!0});_parentDialog=(0,a.WQX)(ke,{optional:!0,skipSelf:!0});_overlayContainer=(0,a.WQX)(i.Sf);_idGenerator=(0,a.WQX)(c.g7);_openDialogsAtThisLevel=[];_afterAllClosedAtThisLevel=new S.B;_afterOpenedAtThisLevel=new S.B;_ariaHiddenElements=new Map;_scrollStrategy=(0,a.WQX)(me);get openDialogs(){return this._parentDialog?this._parentDialog.openDialogs:this._openDialogsAtThisLevel}get afterOpened(){return this._parentDialog?this._parentDialog.afterOpened:this._afterOpenedAtThisLevel}afterAllClosed=(0,M.v)(()=>this.openDialogs.length?this._getAfterAllClosed():this._getAfterAllClosed().pipe((0,Z.Z)(void 0)));constructor(){}open(z,N){(N={...this._defaultOptions||new re,...N}).id=N.id||this._idGenerator.getId("cdk-dialog-"),N.id&&this.getDialogById(N.id);const Le=this._getOverlayConfig(N),ft=this._overlay.create(Le),mt=new ae(ft,N),St=this._attachContainer(ft,mt,N);return mt.containerInstance=St,this._attachDialogContent(z,mt,St,N),this.openDialogs.length||this._hideNonDialogContentFromAssistiveTechnology(),this.openDialogs.push(mt),mt.closed.subscribe(()=>this._removeOpenDialog(mt,!0)),this.afterOpened.next(mt),mt}closeAll(){ue(this.openDialogs,z=>z.close())}getDialogById(z){return this.openDialogs.find(N=>N.id===z)}ngOnDestroy(){ue(this._openDialogsAtThisLevel,z=>{!1===z.config.closeOnDestroy&&this._removeOpenDialog(z,!1)}),ue(this._openDialogsAtThisLevel,z=>z.close()),this._afterAllClosedAtThisLevel.complete(),this._afterOpenedAtThisLevel.complete(),this._openDialogsAtThisLevel=[]}_getOverlayConfig(z){const N=new i.rR({positionStrategy:z.positionStrategy||this._overlay.position().global().centerHorizontally().centerVertically(),scrollStrategy:z.scrollStrategy||this._scrollStrategy(),panelClass:z.panelClass,hasBackdrop:z.hasBackdrop,direction:z.direction,minWidth:z.minWidth,minHeight:z.minHeight,maxWidth:z.maxWidth,maxHeight:z.maxHeight,width:z.width,height:z.height,disposeOnNavigation:z.closeOnNavigation});return z.backdropClass&&(N.backdropClass=z.backdropClass),N}_attachContainer(z,N,W){const Le=W.injector||W.viewContainerRef?.injector,ft=[{provide:re,useValue:W},{provide:ae,useValue:N},{provide:i.yY,useValue:z}];let mt;W.container?"function"==typeof W.container?mt=W.container:(mt=W.container.type,ft.push(...W.container.providers(W))):mt=se;const St=new w.A8(mt,W.viewContainerRef,a.zZn.create({parent:Le||this._injector,providers:ft}));return z.attach(St).instance}_attachDialogContent(z,N,W,Le){if(z instanceof a.C4Q){const ft=this._createInjector(Le,N,W,void 0);let mt={$implicit:Le.data,dialogRef:N};Le.templateContext&&(mt={...mt,..."function"==typeof Le.templateContext?Le.templateContext():Le.templateContext}),W.attachTemplatePortal(new w.VA(z,null,mt,ft))}else{const ft=this._createInjector(Le,N,W,this._injector),mt=W.attachComponentPortal(new w.A8(z,Le.viewContainerRef,ft));N.componentRef=mt,N.componentInstance=mt.instance}}_createInjector(z,N,W,Le){const ft=z.injector||z.viewContainerRef?.injector,mt=[{provide:be,useValue:z.data},{provide:ae,useValue:N}];return z.providers&&("function"==typeof z.providers?mt.push(...z.providers(N,z,W)):mt.push(...z.providers)),z.direction&&(!ft||!ft.get(L.dS,null,{optional:!0}))&&mt.push({provide:L.dS,useValue:{value:z.direction,change:(0,O.of)()}}),a.zZn.create({parent:ft||Le,providers:mt})}_removeOpenDialog(z,N){const W=this.openDialogs.indexOf(z);W>-1&&(this.openDialogs.splice(W,1),this.openDialogs.length||(this._ariaHiddenElements.forEach((Le,ft)=>{Le?ft.setAttribute("aria-hidden",Le):ft.removeAttribute("aria-hidden")}),this._ariaHiddenElements.clear(),N&&this._getAfterAllClosed().next()))}_hideNonDialogContentFromAssistiveTechnology(){const z=this._overlayContainer.getContainerElement();if(z.parentElement){const N=z.parentElement.children;for(let W=N.length-1;W>-1;W--){const Le=N[W];Le!==z&&"SCRIPT"!==Le.nodeName&&"STYLE"!==Le.nodeName&&!Le.hasAttribute("aria-live")&&(this._ariaHiddenElements.set(Le,Le.getAttribute("aria-hidden")),Le.setAttribute("aria-hidden","true"))}}}_getAfterAllClosed(){const z=this._parentDialog;return z?z._getAfterAllClosed():this._afterAllClosedAtThisLevel}static \u0275fac=function(N){return new(N||ke)};static \u0275prov=a.jDH({token:ke,factory:ke.\u0275fac,providedIn:"root"})}return ke})();function ue(ke,Je){let z=ke.length;for(;z--;)Je(ke[z])}let Ce=(()=>{class ke{static \u0275fac=function(N){return new(N||ke)};static \u0275mod=a.$C({type:ke});static \u0275inj=a.G2t({providers:[ce],imports:[i.z_,w.jc,c.Pd,w.jc]})}return ke})();var Be=r(3022),at=r(7509),dt=r(1483),bt=r(7610),lt=r(8108),rn=r(2902);function bn(ke,Je){}r(1204);class Vn{viewContainerRef;injector;id;role="dialog";panelClass="";hasBackdrop=!0;backdropClass="";disableClose=!1;width="";height="";minWidth;minHeight;maxWidth;maxHeight;position;data=null;direction;ariaDescribedBy=null;ariaLabelledBy=null;ariaLabel=null;ariaModal=!0;autoFocus="first-tabbable";restoreFocus=!0;delayFocusTrap=!0;scrollStrategy;closeOnNavigation=!0;componentFactoryResolver;enterAnimationDuration;exitAnimationDuration}const yn="mdc-dialog--open",qe="mdc-dialog--opening",_t="mdc-dialog--closing";let Ft=(()=>{class ke extends se{_animationMode=(0,a.WQX)(a.bc$,{optional:!0});_animationStateChanged=new a.bkB;_animationsEnabled="NoopAnimations"!==this._animationMode;_actionSectionCount=0;_hostElement=this._elementRef.nativeElement;_enterAnimationDuration=this._animationsEnabled?Ze(this._config.enterAnimationDuration)??150:0;_exitAnimationDuration=this._animationsEnabled?Ze(this._config.exitAnimationDuration)??75:0;_animationTimer=null;_contentAttached(){super._contentAttached(),this._startOpenAnimation()}_startOpenAnimation(){this._animationStateChanged.emit({state:"opening",totalTime:this._enterAnimationDuration}),this._animationsEnabled?(this._hostElement.style.setProperty(Ke,`${this._enterAnimationDuration}ms`),this._requestAnimationFrame(()=>this._hostElement.classList.add(qe,yn)),this._waitForAnimationToComplete(this._enterAnimationDuration,this._finishDialogOpen)):(this._hostElement.classList.add(yn),Promise.resolve().then(()=>this._finishDialogOpen()))}_startExitAnimation(){this._animationStateChanged.emit({state:"closing",totalTime:this._exitAnimationDuration}),this._hostElement.classList.remove(yn),this._animationsEnabled?(this._hostElement.style.setProperty(Ke,`${this._exitAnimationDuration}ms`),this._requestAnimationFrame(()=>this._hostElement.classList.add(_t)),this._waitForAnimationToComplete(this._exitAnimationDuration,this._finishDialogClose)):Promise.resolve().then(()=>this._finishDialogClose())}_updateActionSectionCount(z){this._actionSectionCount+=z,this._changeDetectorRef.markForCheck()}_finishDialogOpen=()=>{this._clearAnimationClasses(),this._openAnimationDone(this._enterAnimationDuration)};_finishDialogClose=()=>{this._clearAnimationClasses(),this._animationStateChanged.emit({state:"closed",totalTime:this._exitAnimationDuration})};_clearAnimationClasses(){this._hostElement.classList.remove(qe,_t)}_waitForAnimationToComplete(z,N){null!==this._animationTimer&&clearTimeout(this._animationTimer),this._animationTimer=setTimeout(N,z)}_requestAnimationFrame(z){this._ngZone.runOutsideAngular(()=>{"function"==typeof requestAnimationFrame?requestAnimationFrame(z):z()})}_captureInitialFocus(){this._config.delayFocusTrap||this._trapFocus()}_openAnimationDone(z){this._config.delayFocusTrap&&this._trapFocus(),this._animationStateChanged.next({state:"opened",totalTime:z})}ngOnDestroy(){super.ngOnDestroy(),null!==this._animationTimer&&clearTimeout(this._animationTimer)}attachComponentPortal(z){const N=super.attachComponentPortal(z);return N.location.nativeElement.classList.add("mat-mdc-dialog-component-host"),N}static \u0275fac=(()=>{let z;return function(W){return(z||(z=a.xGo(ke)))(W||ke)}})();static \u0275cmp=a.VBU({type:ke,selectors:[["mat-dialog-container"]],hostAttrs:["tabindex","-1",1,"mat-mdc-dialog-container","mdc-dialog"],hostVars:10,hostBindings:function(N,W){2&N&&(a.Mr5("id",W._config.id),a.BMQ("aria-modal",W._config.ariaModal)("role",W._config.role)("aria-labelledby",W._config.ariaLabel?null:W._ariaLabelledByQueue[0])("aria-label",W._config.ariaLabel)("aria-describedby",W._config.ariaDescribedBy||null),a.AVh("_mat-animation-noopable",!W._animationsEnabled)("mat-mdc-dialog-container-with-actions",W._actionSectionCount>0))},features:[a.Vt3],decls:3,vars:0,consts:[[1,"mat-mdc-dialog-inner-container","mdc-dialog__container"],[1,"mat-mdc-dialog-surface","mdc-dialog__surface"],["cdkPortalOutlet",""]],template:function(N,W){1&N&&(a.j41(0,"div",0)(1,"div",1),a.DNE(2,bn,0,0,"ng-template",2),a.k0s()())},dependencies:[w.I3],styles:['.mat-mdc-dialog-container{width:100%;height:100%;display:block;box-sizing:border-box;max-height:inherit;min-height:inherit;min-width:inherit;max-width:inherit;outline:0}.cdk-overlay-pane.mat-mdc-dialog-panel{max-width:var(--mat-dialog-container-max-width, 560px);min-width:var(--mat-dialog-container-min-width, 280px)}@media(max-width: 599px){.cdk-overlay-pane.mat-mdc-dialog-panel{max-width:var(--mat-dialog-container-small-max-width, calc(100vw - 32px))}}.mat-mdc-dialog-inner-container{display:flex;flex-direction:row;align-items:center;justify-content:space-around;box-sizing:border-box;height:100%;opacity:0;transition:opacity linear var(--mat-dialog-transition-duration, 0ms);max-height:inherit;min-height:inherit;min-width:inherit;max-width:inherit}.mdc-dialog--closing .mat-mdc-dialog-inner-container{transition:opacity 75ms linear;transform:none}.mdc-dialog--open .mat-mdc-dialog-inner-container{opacity:1}._mat-animation-noopable .mat-mdc-dialog-inner-container{transition:none}.mat-mdc-dialog-surface{display:flex;flex-direction:column;flex-grow:0;flex-shrink:0;box-sizing:border-box;width:100%;height:100%;position:relative;overflow-y:auto;outline:0;transform:scale(0.8);transition:transform var(--mat-dialog-transition-duration, 0ms) cubic-bezier(0, 0, 0.2, 1);max-height:inherit;min-height:inherit;min-width:inherit;max-width:inherit;box-shadow:var(--mat-dialog-container-elevation-shadow, none);border-radius:var(--mdc-dialog-container-shape, var(--mat-sys-corner-extra-large, 4px));background-color:var(--mdc-dialog-container-color, var(--mat-sys-surface, white))}[dir=rtl] .mat-mdc-dialog-surface{text-align:right}.mdc-dialog--open .mat-mdc-dialog-surface,.mdc-dialog--closing .mat-mdc-dialog-surface{transform:none}._mat-animation-noopable .mat-mdc-dialog-surface{transition:none}.mat-mdc-dialog-surface::before{position:absolute;box-sizing:border-box;width:100%;height:100%;top:0;left:0;border:2px solid rgba(0,0,0,0);border-radius:inherit;content:"";pointer-events:none}.mat-mdc-dialog-title{display:block;position:relative;flex-shrink:0;box-sizing:border-box;margin:0 0 1px;padding:var(--mat-dialog-headline-padding, 6px 24px 13px)}.mat-mdc-dialog-title::before{display:inline-block;width:0;height:40px;content:"";vertical-align:0}[dir=rtl] .mat-mdc-dialog-title{text-align:right}.mat-mdc-dialog-container .mat-mdc-dialog-title{color:var(--mdc-dialog-subhead-color, var(--mat-sys-on-surface, rgba(0, 0, 0, 0.87)));font-family:var(--mdc-dialog-subhead-font, var(--mat-sys-headline-small-font, inherit));line-height:var(--mdc-dialog-subhead-line-height, var(--mat-sys-headline-small-line-height, 1.5rem));font-size:var(--mdc-dialog-subhead-size, var(--mat-sys-headline-small-size, 1rem));font-weight:var(--mdc-dialog-subhead-weight, var(--mat-sys-headline-small-weight, 400));letter-spacing:var(--mdc-dialog-subhead-tracking, var(--mat-sys-headline-small-tracking, 0.03125em))}.mat-mdc-dialog-content{display:block;flex-grow:1;box-sizing:border-box;margin:0;overflow:auto;max-height:65vh}.mat-mdc-dialog-content>:first-child{margin-top:0}.mat-mdc-dialog-content>:last-child{margin-bottom:0}.mat-mdc-dialog-container .mat-mdc-dialog-content{color:var(--mdc-dialog-supporting-text-color, var(--mat-sys-on-surface-variant, rgba(0, 0, 0, 0.6)));font-family:var(--mdc-dialog-supporting-text-font, var(--mat-sys-body-medium-font, inherit));line-height:var(--mdc-dialog-supporting-text-line-height, var(--mat-sys-body-medium-line-height, 1.5rem));font-size:var(--mdc-dialog-supporting-text-size, var(--mat-sys-body-medium-size, 1rem));font-weight:var(--mdc-dialog-supporting-text-weight, var(--mat-sys-body-medium-weight, 400));letter-spacing:var(--mdc-dialog-supporting-text-tracking, var(--mat-sys-body-medium-tracking, 0.03125em))}.mat-mdc-dialog-container .mat-mdc-dialog-content{padding:var(--mat-dialog-content-padding, 20px 24px)}.mat-mdc-dialog-container-with-actions .mat-mdc-dialog-content{padding:var(--mat-dialog-with-actions-content-padding, 20px 24px 0)}.mat-mdc-dialog-container .mat-mdc-dialog-title+.mat-mdc-dialog-content{padding-top:0}.mat-mdc-dialog-actions{display:flex;position:relative;flex-shrink:0;flex-wrap:wrap;align-items:center;justify-content:flex-end;box-sizing:border-box;min-height:52px;margin:0;padding:8px;border-top:1px solid rgba(0,0,0,0);padding:var(--mat-dialog-actions-padding, 16px 24px);justify-content:var(--mat-dialog-actions-alignment, flex-end)}@media(forced-colors: active){.mat-mdc-dialog-actions{border-top-color:CanvasText}}.mat-mdc-dialog-actions.mat-mdc-dialog-actions-align-start,.mat-mdc-dialog-actions[align=start]{justify-content:start}.mat-mdc-dialog-actions.mat-mdc-dialog-actions-align-center,.mat-mdc-dialog-actions[align=center]{justify-content:center}.mat-mdc-dialog-actions.mat-mdc-dialog-actions-align-end,.mat-mdc-dialog-actions[align=end]{justify-content:flex-end}.mat-mdc-dialog-actions .mat-button-base+.mat-button-base,.mat-mdc-dialog-actions .mat-mdc-button-base+.mat-mdc-button-base{margin-left:8px}[dir=rtl] .mat-mdc-dialog-actions .mat-button-base+.mat-button-base,[dir=rtl] .mat-mdc-dialog-actions .mat-mdc-button-base+.mat-mdc-button-base{margin-left:0;margin-right:8px}.mat-mdc-dialog-component-host{display:contents}'],encapsulation:2})}return ke})();const Ke="--mat-dialog-transition-duration";function Ze(ke){return null==ke?null:"number"==typeof ke?ke:ke.endsWith("ms")?(0,Be.OE)(ke.substring(0,ke.length-2)):ke.endsWith("s")?1e3*(0,Be.OE)(ke.substring(0,ke.length-1)):"0"===ke?0:null}var it=function(ke){return ke[ke.OPEN=0]="OPEN",ke[ke.CLOSING=1]="CLOSING",ke[ke.CLOSED=2]="CLOSED",ke}(it||{});class Ot{_ref;_containerInstance;componentInstance;componentRef;disableClose;id;_afterOpened=new S.B;_beforeClosed=new S.B;_result;_closeFallbackTimeout;_state=it.OPEN;_closeInteractionType;constructor(Je,z,N){this._ref=Je,this._containerInstance=N,this.disableClose=z.disableClose,this.id=Je.id,Je.addPanelClass("mat-mdc-dialog-panel"),N._animationStateChanged.pipe((0,dt.p)(W=>"opened"===W.state),(0,bt.s)(1)).subscribe(()=>{this._afterOpened.next(),this._afterOpened.complete()}),N._animationStateChanged.pipe((0,dt.p)(W=>"closed"===W.state),(0,bt.s)(1)).subscribe(()=>{clearTimeout(this._closeFallbackTimeout),this._finishDialogClose()}),Je.overlayRef.detachments().subscribe(()=>{this._beforeClosed.next(this._result),this._beforeClosed.complete(),this._finishDialogClose()}),(0,at.h)(this.backdropClick(),this.keydownEvents().pipe((0,dt.p)(W=>W.keyCode===T._f&&!this.disableClose&&!(0,T.rp)(W)))).subscribe(W=>{this.disableClose||(W.preventDefault(),$t(this,"keydown"===W.type?"keyboard":"mouse"))})}close(Je){this._result=Je,this._containerInstance._animationStateChanged.pipe((0,dt.p)(z=>"closing"===z.state),(0,bt.s)(1)).subscribe(z=>{this._beforeClosed.next(Je),this._beforeClosed.complete(),this._ref.overlayRef.detachBackdrop(),this._closeFallbackTimeout=setTimeout(()=>this._finishDialogClose(),z.totalTime+100)}),this._state=it.CLOSING,this._containerInstance._startExitAnimation()}afterOpened(){return this._afterOpened}afterClosed(){return this._ref.closed}beforeClosed(){return this._beforeClosed}backdropClick(){return this._ref.backdropClick}keydownEvents(){return this._ref.keydownEvents}updatePosition(Je){let z=this._ref.config.positionStrategy;return Je&&(Je.left||Je.right)?Je.left?z.left(Je.left):z.right(Je.right):z.centerHorizontally(),Je&&(Je.top||Je.bottom)?Je.top?z.top(Je.top):z.bottom(Je.bottom):z.centerVertically(),this._ref.updatePosition(),this}updateSize(Je="",z=""){return this._ref.updateSize(Je,z),this}addPanelClass(Je){return this._ref.addPanelClass(Je),this}removePanelClass(Je){return this._ref.removePanelClass(Je),this}getState(){return this._state}_finishDialogClose(){this._state=it.CLOSED,this._ref.close(this._result,{focusOrigin:this._closeInteractionType}),this.componentInstance=null}}function $t(ke,Je,z){return ke._closeInteractionType=Je,ke.close(z)}const Te=new a.nKC("MatMdcDialogData"),Ee=new a.nKC("mat-mdc-dialog-default-options"),st=new a.nKC("mat-mdc-dialog-scroll-strategy",{providedIn:"root",factory:()=>{const ke=(0,a.WQX)(i.hJ);return()=>ke.scrollStrategies.block()}});let Kt=(()=>{class ke{_overlay=(0,a.WQX)(i.hJ);_defaultOptions=(0,a.WQX)(Ee,{optional:!0});_scrollStrategy=(0,a.WQX)(st);_parentDialog=(0,a.WQX)(ke,{optional:!0,skipSelf:!0});_idGenerator=(0,a.WQX)(c.g7);_dialog=(0,a.WQX)(ce);_openDialogsAtThisLevel=[];_afterAllClosedAtThisLevel=new S.B;_afterOpenedAtThisLevel=new S.B;dialogConfigClass=Vn;_dialogRefConstructor;_dialogContainerType;_dialogDataToken;get openDialogs(){return this._parentDialog?this._parentDialog.openDialogs:this._openDialogsAtThisLevel}get afterOpened(){return this._parentDialog?this._parentDialog.afterOpened:this._afterOpenedAtThisLevel}_getAfterAllClosed(){const z=this._parentDialog;return z?z._getAfterAllClosed():this._afterAllClosedAtThisLevel}afterAllClosed=(0,M.v)(()=>this.openDialogs.length?this._getAfterAllClosed():this._getAfterAllClosed().pipe((0,Z.Z)(void 0)));constructor(){this._dialogRefConstructor=Ot,this._dialogContainerType=Ft,this._dialogDataToken=Te}open(z,N){let W;(N={...this._defaultOptions||new Vn,...N}).id=N.id||this._idGenerator.getId("mat-mdc-dialog-"),N.scrollStrategy=N.scrollStrategy||this._scrollStrategy();const Le=this._dialog.open(z,{...N,positionStrategy:this._overlay.position().global().centerHorizontally().centerVertically(),disableClose:!0,closeOnDestroy:!1,closeOnOverlayDetachments:!1,container:{type:this._dialogContainerType,providers:()=>[{provide:this.dialogConfigClass,useValue:N},{provide:re,useValue:N}]},templateContext:()=>({dialogRef:W}),providers:(ft,mt,St)=>(W=new this._dialogRefConstructor(ft,N,St),W.updatePosition(N?.position),[{provide:this._dialogContainerType,useValue:St},{provide:this._dialogDataToken,useValue:mt.data},{provide:this._dialogRefConstructor,useValue:W}])});return W.componentRef=Le.componentRef,W.componentInstance=Le.componentInstance,this.openDialogs.push(W),this.afterOpened.next(W),W.afterClosed().subscribe(()=>{const ft=this.openDialogs.indexOf(W);ft>-1&&(this.openDialogs.splice(ft,1),this.openDialogs.length||this._getAfterAllClosed().next())}),W}closeAll(){this._closeDialogs(this.openDialogs)}getDialogById(z){return this.openDialogs.find(N=>N.id===z)}ngOnDestroy(){this._closeDialogs(this._openDialogsAtThisLevel),this._afterAllClosedAtThisLevel.complete(),this._afterOpenedAtThisLevel.complete()}_closeDialogs(z){let N=z.length;for(;N--;)z[N].close()}static \u0275fac=function(N){return new(N||ke)};static \u0275prov=a.jDH({token:ke,factory:ke.\u0275fac,providedIn:"root"})}return ke})(),rt=(()=>{class ke{dialogRef=(0,a.WQX)(Ot,{optional:!0});_elementRef=(0,a.WQX)(a.aKT);_dialog=(0,a.WQX)(Kt);ariaLabel;type="button";dialogResult;_matDialogClose;constructor(){}ngOnInit(){this.dialogRef||(this.dialogRef=Nr(this._elementRef,this._dialog.openDialogs))}ngOnChanges(z){const N=z._matDialogClose||z._matDialogCloseResult;N&&(this.dialogResult=N.currentValue)}_onButtonClick(z){$t(this.dialogRef,0===z.screenX&&0===z.screenY?"keyboard":"mouse",this.dialogResult)}static \u0275fac=function(N){return new(N||ke)};static \u0275dir=a.FsC({type:ke,selectors:[["","mat-dialog-close",""],["","matDialogClose",""]],hostVars:2,hostBindings:function(N,W){1&N&&a.bIt("click",function(ft){return W._onButtonClick(ft)}),2&N&&a.BMQ("aria-label",W.ariaLabel||null)("type",W.type)},inputs:{ariaLabel:[0,"aria-label","ariaLabel"],type:"type",dialogResult:[0,"mat-dialog-close","dialogResult"],_matDialogClose:[0,"matDialogClose","_matDialogClose"]},exportAs:["matDialogClose"],features:[a.OA$]})}return ke})(),Vt=(()=>{class ke{_dialogRef=(0,a.WQX)(Ot,{optional:!0});_elementRef=(0,a.WQX)(a.aKT);_dialog=(0,a.WQX)(Kt);constructor(){}ngOnInit(){this._dialogRef||(this._dialogRef=Nr(this._elementRef,this._dialog.openDialogs)),this._dialogRef&&Promise.resolve().then(()=>{this._onAdd()})}ngOnDestroy(){this._dialogRef?._containerInstance&&Promise.resolve().then(()=>{this._onRemove()})}static \u0275fac=function(N){return new(N||ke)};static \u0275dir=a.FsC({type:ke})}return ke})(),kn=(()=>{class ke{static \u0275fac=function(N){return new(N||ke)};static \u0275dir=a.FsC({type:ke,selectors:[["","mat-dialog-content",""],["mat-dialog-content"],["","matDialogContent",""]],hostAttrs:[1,"mat-mdc-dialog-content","mdc-dialog__content"],features:[a.nM4([lt.uv])]})}return ke})(),Kn=(()=>{class ke extends Vt{align;_onAdd(){this._dialogRef._containerInstance?._updateActionSectionCount?.(1)}_onRemove(){this._dialogRef._containerInstance?._updateActionSectionCount?.(-1)}static \u0275fac=(()=>{let z;return function(W){return(z||(z=a.xGo(ke)))(W||ke)}})();static \u0275dir=a.FsC({type:ke,selectors:[["","mat-dialog-actions",""],["mat-dialog-actions"],["","matDialogActions",""]],hostAttrs:[1,"mat-mdc-dialog-actions","mdc-dialog__actions"],hostVars:6,hostBindings:function(N,W){2&N&&a.AVh("mat-mdc-dialog-actions-align-start","start"===W.align)("mat-mdc-dialog-actions-align-center","center"===W.align)("mat-mdc-dialog-actions-align-end","end"===W.align)},inputs:{align:"align"},features:[a.Vt3]})}return ke})();function Nr(ke,Je){let z=ke.nativeElement.parentElement;for(;z&&!z.classList.contains("mat-mdc-dialog-container");)z=z.parentElement;return z?Je.find(N=>N.id===z.id):null}let pr=(()=>{class ke{static \u0275fac=function(N){return new(N||ke)};static \u0275mod=a.$C({type:ke});static \u0275inj=a.G2t({providers:[Kt],imports:[Ce,i.z_,w.jc,rn.yE,rn.yE]})}return ke})()},7702:(o,s,r)=>{"use strict";r.d(s,{q:()=>y,w:()=>w});var i=r(3107),a=r(3022),c=r(2902);let y=(()=>{class C{get vertical(){return this._vertical}set vertical(S){this._vertical=(0,a.he)(S)}_vertical=!1;get inset(){return this._inset}set inset(S){this._inset=(0,a.he)(S)}_inset=!1;static \u0275fac=function(M){return new(M||C)};static \u0275cmp=i.VBU({type:C,selectors:[["mat-divider"]],hostAttrs:["role","separator",1,"mat-divider"],hostVars:7,hostBindings:function(M,O){2&M&&(i.BMQ("aria-orientation",O.vertical?"vertical":"horizontal"),i.AVh("mat-divider-vertical",O.vertical)("mat-divider-horizontal",!O.vertical)("mat-divider-inset",O.inset))},inputs:{vertical:"vertical",inset:"inset"},decls:0,vars:0,template:function(M,O){},styles:[".mat-divider{display:block;margin:0;border-top-style:solid;border-top-color:var(--mat-divider-color, var(--mat-sys-outline));border-top-width:var(--mat-divider-width, 1px)}.mat-divider.mat-divider-vertical{border-top:0;border-right-style:solid;border-right-color:var(--mat-divider-color, var(--mat-sys-outline));border-right-width:var(--mat-divider-width, 1px)}.mat-divider.mat-divider-inset{margin-left:80px}[dir=rtl] .mat-divider.mat-divider-inset{margin-left:auto;margin-right:80px}"],encapsulation:2,changeDetection:0})}return C})(),w=(()=>{class C{static \u0275fac=function(M){return new(M||C)};static \u0275mod=i.$C({type:C});static \u0275inj=i.G2t({imports:[c.yE,c.yE]})}return C})()},6071:(o,s,r)=>{"use strict";r.d(s,{xb:()=>an,U$:()=>dn,TL:()=>en,rl:()=>Tr,qT:()=>ft,RG:()=>Vr,MV:()=>kn,nJ:()=>rt,JW:()=>Nr,yw:()=>pr});var i=r(3107),a=r(8559),c=r(2944),y=r(3022),w=r(2147),C=r(4460),T=r(5710),S=r(8447),M=r(7509),O=r(593),L=r(7947),Z=r(5351),q=r(2483),pe=r(1483),se=r(5424),ae=r(1698),me=r(8249);class Oe{_box;_destroyed=new S.B;_resizeSubject=new S.B;_resizeObserver;_elementObservables=new Map;constructor(Wt){this._box=Wt,typeof ResizeObserver<"u"&&(this._resizeObserver=new ResizeObserver(Re=>this._resizeSubject.next(Re)))}observe(Wt){return this._elementObservables.has(Wt)||this._elementObservables.set(Wt,new ae.c(Re=>{const Ge=this._resizeSubject.subscribe(Re);return this._resizeObserver?.observe(Wt,{box:this._box}),()=>{this._resizeObserver?.unobserve(Wt),Ge.unsubscribe(),this._elementObservables.delete(Wt)}}).pipe((0,pe.p)(Re=>Re.some(Ge=>Ge.target===Wt)),(0,me.t)({bufferSize:1,refCount:!0}),(0,se.Q)(this._destroyed))),this._elementObservables.get(Wt)}destroy(){this._destroyed.next(),this._destroyed.complete(),this._resizeSubject.complete(),this._elementObservables.clear()}}let xe=(()=>{class vt{_observers=new Map;_ngZone=(0,i.WQX)(i.SKi);constructor(){}ngOnDestroy(){for(const[,Re]of this._observers)Re.destroy();this._observers.clear()}observe(Re,Ge){const Ve=Ge?.box||"content-box";return this._observers.has(Ve)||this._observers.set(Ve,new Oe(Ve)),this._observers.get(Ve).observe(Re)}static \u0275fac=function(Ge){return new(Ge||vt)};static \u0275prov=i.jDH({token:vt,factory:vt.\u0275fac,providedIn:"root"})}return vt})();var De=r(1204),ce=r(7747),ue=r(2902);const Ce=["notch"],Be=["matFormFieldNotchedOutline",""],at=["*"],dt=["textField"],bt=["iconPrefixContainer"],lt=["textPrefixContainer"],rn=["iconSuffixContainer"],gn=["textSuffixContainer"],bn=["*",[["mat-label"]],[["","matPrefix",""],["","matIconPrefix",""]],[["","matTextPrefix",""]],[["","matTextSuffix",""]],[["","matSuffix",""],["","matIconSuffix",""]],[["mat-error"],["","matError",""]],[["mat-hint",3,"align","end"]],[["mat-hint","align","end"]]],Vn=["*","mat-label","[matPrefix], [matIconPrefix]","[matTextPrefix]","[matTextSuffix]","[matSuffix], [matIconSuffix]","mat-error, [matError]","mat-hint:not([align='end'])","mat-hint[align='end']"];function yn(vt,Wt){1&vt&&i.nrm(0,"span",21)}function qe(vt,Wt){if(1&vt&&(i.j41(0,"label",20),i.SdG(1,1),i.DNE(2,yn,1,0,"span",21),i.k0s()),2&vt){const Re=i.XpG(2);i.Y8G("floating",Re._shouldLabelFloat())("monitorResize",Re._hasOutline())("id",Re._labelId),i.BMQ("for",Re._control.disableAutomaticLabeling?null:Re._control.id),i.R7$(2),i.vxM(!Re.hideRequiredMarker&&Re._control.required?2:-1)}}function _t(vt,Wt){if(1&vt&&i.DNE(0,qe,3,5,"label",20),2&vt){const Re=i.XpG();i.vxM(Re._hasFloatingLabel()?0:-1)}}function ze(vt,Wt){1&vt&&i.nrm(0,"div",7)}function $e(vt,Wt){}function Ft(vt,Wt){if(1&vt&&i.DNE(0,$e,0,0,"ng-template",13),2&vt){i.XpG(2);const Re=i.sdS(1);i.Y8G("ngTemplateOutlet",Re)}}function Ke(vt,Wt){if(1&vt&&(i.j41(0,"div",9),i.DNE(1,Ft,1,1,null,13),i.k0s()),2&vt){const Re=i.XpG();i.Y8G("matFormFieldNotchedOutlineOpen",Re._shouldLabelFloat()),i.R7$(),i.vxM(Re._forceDisplayInfixLabel()?-1:1)}}function Ze(vt,Wt){1&vt&&(i.j41(0,"div",10,2),i.SdG(2,2),i.k0s())}function it(vt,Wt){1&vt&&(i.j41(0,"div",11,3),i.SdG(2,3),i.k0s())}function Ot(vt,Wt){}function $t(vt,Wt){if(1&vt&&i.DNE(0,Ot,0,0,"ng-template",13),2&vt){i.XpG();const Re=i.sdS(1);i.Y8G("ngTemplateOutlet",Re)}}function Te(vt,Wt){1&vt&&(i.j41(0,"div",14,4),i.SdG(2,4),i.k0s())}function Ee(vt,Wt){1&vt&&(i.j41(0,"div",15,5),i.SdG(2,5),i.k0s())}function st(vt,Wt){1&vt&&i.nrm(0,"div",16)}function Xt(vt,Wt){if(1&vt&&(i.j41(0,"div",18),i.SdG(1,6),i.k0s()),2&vt){const Re=i.XpG();i.Y8G("@transitionMessages",Re._subscriptAnimationState)}}function Mt(vt,Wt){if(1&vt&&(i.j41(0,"mat-hint",22),i.EFF(1),i.k0s()),2&vt){const Re=i.XpG(2);i.Y8G("id",Re._hintLabelId),i.R7$(),i.JRh(Re.hintLabel)}}function Kt(vt,Wt){if(1&vt&&(i.j41(0,"div",19),i.DNE(1,Mt,2,2,"mat-hint",22),i.SdG(2,7),i.nrm(3,"div",23),i.SdG(4,8),i.k0s()),2&vt){const Re=i.XpG();i.Y8G("@transitionMessages",Re._subscriptAnimationState),i.R7$(),i.vxM(Re.hintLabel?1:-1)}}let rt=(()=>{class vt{static \u0275fac=function(Ge){return new(Ge||vt)};static \u0275dir=i.FsC({type:vt,selectors:[["mat-label"]]})}return vt})();const Vt=new i.nKC("MatError");let en=(()=>{class vt{id=(0,i.WQX)(a.g7).getId("mat-mdc-error-");constructor(){(0,i.WQX)(new i.ES_("aria-live"),{optional:!0})||(0,i.WQX)(i.aKT).nativeElement.setAttribute("aria-live","polite")}static \u0275fac=function(Ge){return new(Ge||vt)};static \u0275dir=i.FsC({type:vt,selectors:[["mat-error"],["","matError",""]],hostAttrs:["aria-atomic","true",1,"mat-mdc-form-field-error","mat-mdc-form-field-bottom-align"],hostVars:1,hostBindings:function(Ge,Ve){2&Ge&&i.Mr5("id",Ve.id)},inputs:{id:"id"},features:[i.Jv_([{provide:Vt,useExisting:vt}])]})}return vt})(),kn=(()=>{class vt{align="start";id=(0,i.WQX)(a.g7).getId("mat-mdc-hint-");static \u0275fac=function(Ge){return new(Ge||vt)};static \u0275dir=i.FsC({type:vt,selectors:[["mat-hint"]],hostAttrs:[1,"mat-mdc-form-field-hint","mat-mdc-form-field-bottom-align"],hostVars:4,hostBindings:function(Ge,Ve){2&Ge&&(i.Mr5("id",Ve.id),i.BMQ("align",null),i.AVh("mat-mdc-form-field-hint-end","end"===Ve.align))},inputs:{align:"align",id:"id"}})}return vt})();const Kn=new i.nKC("MatPrefix");let Nr=(()=>{class vt{set _isTextSelector(Re){this._isText=!0}_isText=!1;static \u0275fac=function(Ge){return new(Ge||vt)};static \u0275dir=i.FsC({type:vt,selectors:[["","matPrefix",""],["","matIconPrefix",""],["","matTextPrefix",""]],inputs:{_isTextSelector:[0,"matTextPrefix","_isTextSelector"]},features:[i.Jv_([{provide:Kn,useExisting:vt}])]})}return vt})();const Rn=new i.nKC("MatSuffix");let pr=(()=>{class vt{set _isTextSelector(Re){this._isText=!0}_isText=!1;static \u0275fac=function(Ge){return new(Ge||vt)};static \u0275dir=i.FsC({type:vt,selectors:[["","matSuffix",""],["","matIconSuffix",""],["","matTextSuffix",""]],inputs:{_isTextSelector:[0,"matTextSuffix","_isTextSelector"]},features:[i.Jv_([{provide:Rn,useExisting:vt}])]})}return vt})();const cn=new i.nKC("FloatingLabelParent");let Fe=(()=>{class vt{_elementRef=(0,i.WQX)(i.aKT);get floating(){return this._floating}set floating(Re){this._floating=Re,this.monitorResize&&this._handleResize()}_floating=!1;get monitorResize(){return this._monitorResize}set monitorResize(Re){this._monitorResize=Re,this._monitorResize?this._subscribeToResize():this._resizeSubscription.unsubscribe()}_monitorResize=!1;_resizeObserver=(0,i.WQX)(xe);_ngZone=(0,i.WQX)(i.SKi);_parent=(0,i.WQX)(cn);_resizeSubscription=new T.yU;constructor(){}ngOnDestroy(){this._resizeSubscription.unsubscribe()}getWidth(){return function ke(vt){if(null!==vt.offsetParent)return vt.scrollWidth;const Re=vt.cloneNode(!0);Re.style.setProperty("position","absolute"),Re.style.setProperty("transform","translate(-9999px, -9999px)"),document.documentElement.appendChild(Re);const Ge=Re.scrollWidth;return Re.remove(),Ge}(this._elementRef.nativeElement)}get element(){return this._elementRef.nativeElement}_handleResize(){setTimeout(()=>this._parent._handleLabelResized())}_subscribeToResize(){this._resizeSubscription.unsubscribe(),this._ngZone.runOutsideAngular(()=>{this._resizeSubscription=this._resizeObserver.observe(this._elementRef.nativeElement,{box:"border-box"}).subscribe(()=>this._handleResize())})}static \u0275fac=function(Ge){return new(Ge||vt)};static \u0275dir=i.FsC({type:vt,selectors:[["label","matFormFieldFloatingLabel",""]],hostAttrs:[1,"mdc-floating-label","mat-mdc-floating-label"],hostVars:2,hostBindings:function(Ge,Ve){2&Ge&&i.AVh("mdc-floating-label--float-above",Ve.floating)},inputs:{floating:"floating",monitorResize:"monitorResize"}})}return vt})();const Je="mdc-line-ripple--active",z="mdc-line-ripple--deactivating";let N=(()=>{class vt{_elementRef=(0,i.WQX)(i.aKT);constructor(){(0,i.WQX)(i.SKi).runOutsideAngular(()=>{this._elementRef.nativeElement.addEventListener("transitionend",this._handleTransitionEnd)})}activate(){const Re=this._elementRef.nativeElement.classList;Re.remove(z),Re.add(Je)}deactivate(){this._elementRef.nativeElement.classList.add(z)}_handleTransitionEnd=Re=>{const Ge=this._elementRef.nativeElement.classList,Ve=Ge.contains(z);"opacity"===Re.propertyName&&Ve&&Ge.remove(Je,z)};ngOnDestroy(){this._elementRef.nativeElement.removeEventListener("transitionend",this._handleTransitionEnd)}static \u0275fac=function(Ge){return new(Ge||vt)};static \u0275dir=i.FsC({type:vt,selectors:[["div","matFormFieldLineRipple",""]],hostAttrs:[1,"mdc-line-ripple"]})}return vt})(),W=(()=>{class vt{_elementRef=(0,i.WQX)(i.aKT);_ngZone=(0,i.WQX)(i.SKi);open=!1;_notch;constructor(){}ngAfterViewInit(){const Re=this._elementRef.nativeElement.querySelector(".mdc-floating-label");Re?(this._elementRef.nativeElement.classList.add("mdc-notched-outline--upgraded"),"function"==typeof requestAnimationFrame&&(Re.style.transitionDuration="0s",this._ngZone.runOutsideAngular(()=>{requestAnimationFrame(()=>Re.style.transitionDuration="")}))):this._elementRef.nativeElement.classList.add("mdc-notched-outline--no-label")}_setNotchWidth(Re){this._notch.nativeElement.style.width=this.open&&Re?`calc(${Re}px * var(--mat-mdc-form-field-floating-label-scale, 0.75) + 9px)`:""}static \u0275fac=function(Ge){return new(Ge||vt)};static \u0275cmp=i.VBU({type:vt,selectors:[["div","matFormFieldNotchedOutline",""]],viewQuery:function(Ge,Ve){if(1&Ge&&i.GBs(Ce,5),2&Ge){let Dt;i.mGM(Dt=i.lsd())&&(Ve._notch=Dt.first)}},hostAttrs:[1,"mdc-notched-outline"],hostVars:2,hostBindings:function(Ge,Ve){2&Ge&&i.AVh("mdc-notched-outline--notched",Ve.open)},inputs:{open:[0,"matFormFieldNotchedOutlineOpen","open"]},attrs:Be,ngContentSelectors:at,decls:5,vars:0,consts:[["notch",""],[1,"mat-mdc-notch-piece","mdc-notched-outline__leading"],[1,"mat-mdc-notch-piece","mdc-notched-outline__notch"],[1,"mat-mdc-notch-piece","mdc-notched-outline__trailing"]],template:function(Ge,Ve){1&Ge&&(i.NAR(),i.nrm(0,"div",1),i.j41(1,"div",2,0),i.SdG(3),i.k0s(),i.nrm(4,"div",3))},encapsulation:2,changeDetection:0})}return vt})();const Le={transitionMessages:(0,De.hZ)("transitionMessages",[(0,De.wk)("enter",(0,De.iF)({opacity:1,transform:"translateY(0%)"})),(0,De.kY)("void => enter",[(0,De.iF)({opacity:0,transform:"translateY(-5px)"}),(0,De.i0)("300ms cubic-bezier(0.55, 0, 0.55, 0.2)")])])};let ft=(()=>{class vt{value;stateChanges;id;placeholder;ngControl;focused;empty;shouldLabelFloat;required;disabled;errorState;controlType;autofilled;userAriaDescribedBy;disableAutomaticLabeling;static \u0275fac=function(Ge){return new(Ge||vt)};static \u0275dir=i.FsC({type:vt})}return vt})();const an=new i.nKC("MatFormField"),dn=new i.nKC("MAT_FORM_FIELD_DEFAULT_OPTIONS");let Tr=(()=>{class vt{_elementRef=(0,i.WQX)(i.aKT);_changeDetectorRef=(0,i.WQX)(i.gRc);_dir=(0,i.WQX)(c.dS);_platform=(0,i.WQX)(w.OD);_idGenerator=(0,i.WQX)(a.g7);_defaults=(0,i.WQX)(dn,{optional:!0});_animationMode=(0,i.WQX)(i.bc$,{optional:!0});_textField;_iconPrefixContainer;_textPrefixContainer;_iconSuffixContainer;_textSuffixContainer;_floatingLabel;_notchedOutline;_lineRipple;_formFieldControl;_prefixChildren;_suffixChildren;_errorChildren;_hintChildren;_labelChild=(0,i.sbv)(rt);get hideRequiredMarker(){return this._hideRequiredMarker}set hideRequiredMarker(Re){this._hideRequiredMarker=(0,y.he)(Re)}_hideRequiredMarker=!1;color="primary";get floatLabel(){return this._floatLabel||this._defaults?.floatLabel||"auto"}set floatLabel(Re){Re!==this._floatLabel&&(this._floatLabel=Re,this._changeDetectorRef.markForCheck())}_floatLabel;get appearance(){return this._appearance}set appearance(Re){const Ge=this._appearance;this._appearance=Re||this._defaults?.appearance||"fill","outline"===this._appearance&&this._appearance!==Ge&&(this._needsOutlineLabelOffsetUpdate=!0)}_appearance="fill";get subscriptSizing(){return this._subscriptSizing||this._defaults?.subscriptSizing||"fixed"}set subscriptSizing(Re){this._subscriptSizing=Re||this._defaults?.subscriptSizing||"fixed"}_subscriptSizing=null;get hintLabel(){return this._hintLabel}set hintLabel(Re){this._hintLabel=Re,this._processHints()}_hintLabel="";_hasIconPrefix=!1;_hasTextPrefix=!1;_hasIconSuffix=!1;_hasTextSuffix=!1;_labelId=this._idGenerator.getId("mat-mdc-form-field-label-");_hintLabelId=this._idGenerator.getId("mat-mdc-hint-");_subscriptAnimationState="";get _control(){return this._explicitFormFieldControl||this._formFieldControl}set _control(Re){this._explicitFormFieldControl=Re}_destroyed=new S.B;_isFocused=null;_explicitFormFieldControl;_needsOutlineLabelOffsetUpdate=!1;_previousControl=null;_stateChanges;_valueChanges;_describedByChanges;_injector=(0,i.WQX)(i.zZn);constructor(){const Re=this._defaults;Re&&(Re.appearance&&(this.appearance=Re.appearance),this._hideRequiredMarker=!!Re?.hideRequiredMarker,Re.color&&(this.color=Re.color))}ngAfterViewInit(){this._updateFocusState(),this._subscriptAnimationState="enter",this._changeDetectorRef.detectChanges()}ngAfterContentInit(){this._assertFormFieldControl(),this._initializeSubscript(),this._initializePrefixAndSuffix(),this._initializeOutlineLabelOffsetSubscriptions()}ngAfterContentChecked(){this._assertFormFieldControl(),this._control!==this._previousControl&&(this._initializeControl(this._previousControl),this._previousControl=this._control)}ngOnDestroy(){this._stateChanges?.unsubscribe(),this._valueChanges?.unsubscribe(),this._describedByChanges?.unsubscribe(),this._destroyed.next(),this._destroyed.complete()}getLabelId=(0,i.EWP)(()=>this._hasFloatingLabel()?this._labelId:null);getConnectedOverlayOrigin(){return this._textField||this._elementRef}_animateAndLockLabel(){this._hasFloatingLabel()&&(this.floatLabel="always")}_initializeControl(Re){const Ge=this._control,Ve="mat-mdc-form-field-type-";Re&&this._elementRef.nativeElement.classList.remove(Ve+Re.controlType),Ge.controlType&&this._elementRef.nativeElement.classList.add(Ve+Ge.controlType),this._stateChanges?.unsubscribe(),this._stateChanges=Ge.stateChanges.subscribe(()=>{this._updateFocusState(),this._changeDetectorRef.markForCheck()}),this._describedByChanges?.unsubscribe(),this._describedByChanges=Ge.stateChanges.pipe((0,O.Z)([void 0,void 0]),(0,L.T)(()=>[Ge.errorState,Ge.userAriaDescribedBy]),function re(){return(0,Z.N)((vt,Wt)=>{let Re,Ge=!1;vt.subscribe((0,q._)(Wt,Ve=>{const Dt=Re;Re=Ve,Ge&&Wt.next([Dt,Ve]),Ge=!0}))})}(),(0,pe.p)(([[Dt,ct],[Bt,wn]])=>Dt!==Bt||ct!==wn)).subscribe(()=>this._syncDescribedByIds()),this._valueChanges?.unsubscribe(),Ge.ngControl&&Ge.ngControl.valueChanges&&(this._valueChanges=Ge.ngControl.valueChanges.pipe((0,se.Q)(this._destroyed)).subscribe(()=>this._changeDetectorRef.markForCheck()))}_checkPrefixAndSuffixTypes(){this._hasIconPrefix=!!this._prefixChildren.find(Re=>!Re._isText),this._hasTextPrefix=!!this._prefixChildren.find(Re=>Re._isText),this._hasIconSuffix=!!this._suffixChildren.find(Re=>!Re._isText),this._hasTextSuffix=!!this._suffixChildren.find(Re=>Re._isText)}_initializePrefixAndSuffix(){this._checkPrefixAndSuffixTypes(),(0,M.h)(this._prefixChildren.changes,this._suffixChildren.changes).subscribe(()=>{this._checkPrefixAndSuffixTypes(),this._changeDetectorRef.markForCheck()})}_initializeSubscript(){this._hintChildren.changes.subscribe(()=>{this._processHints(),this._changeDetectorRef.markForCheck()}),this._errorChildren.changes.subscribe(()=>{this._syncDescribedByIds(),this._changeDetectorRef.markForCheck()}),this._validateHints(),this._syncDescribedByIds()}_assertFormFieldControl(){}_updateFocusState(){this._control.focused&&!this._isFocused?(this._isFocused=!0,this._lineRipple?.activate()):!this._control.focused&&(this._isFocused||null===this._isFocused)&&(this._isFocused=!1,this._lineRipple?.deactivate()),this._textField?.nativeElement.classList.toggle("mdc-text-field--focused",this._control.focused)}_initializeOutlineLabelOffsetSubscriptions(){this._prefixChildren.changes.subscribe(()=>this._needsOutlineLabelOffsetUpdate=!0),(0,i.Tzd)(()=>{this._needsOutlineLabelOffsetUpdate&&(this._needsOutlineLabelOffsetUpdate=!1,this._updateOutlineLabelOffset())},{injector:this._injector}),this._dir.change.pipe((0,se.Q)(this._destroyed)).subscribe(()=>this._needsOutlineLabelOffsetUpdate=!0)}_shouldAlwaysFloat(){return"always"===this.floatLabel}_hasOutline(){return"outline"===this.appearance}_forceDisplayInfixLabel(){return!this._platform.isBrowser&&this._prefixChildren.length&&!this._shouldLabelFloat()}_hasFloatingLabel=(0,i.EWP)(()=>!!this._labelChild());_shouldLabelFloat(){return!!this._hasFloatingLabel()&&(this._control.shouldLabelFloat||this._shouldAlwaysFloat())}_shouldForward(Re){const Ge=this._control?this._control.ngControl:null;return Ge&&Ge[Re]}_getDisplayedMessages(){return this._errorChildren&&this._errorChildren.length>0&&this._control.errorState?"error":"hint"}_handleLabelResized(){this._refreshOutlineNotchWidth()}_refreshOutlineNotchWidth(){this._hasOutline()&&this._floatingLabel&&this._shouldLabelFloat()?this._notchedOutline?._setNotchWidth(this._floatingLabel.getWidth()):this._notchedOutline?._setNotchWidth(0)}_processHints(){this._validateHints(),this._syncDescribedByIds()}_validateHints(){}_syncDescribedByIds(){if(this._control){let Re=[];if(this._control.userAriaDescribedBy&&"string"==typeof this._control.userAriaDescribedBy&&Re.push(...this._control.userAriaDescribedBy.split(" ")),"hint"===this._getDisplayedMessages()){const Ge=this._hintChildren?this._hintChildren.find(Dt=>"start"===Dt.align):null,Ve=this._hintChildren?this._hintChildren.find(Dt=>"end"===Dt.align):null;Ge?Re.push(Ge.id):this._hintLabel&&Re.push(this._hintLabelId),Ve&&Re.push(Ve.id)}else this._errorChildren&&Re.push(...this._errorChildren.map(Ge=>Ge.id));this._control.setDescribedByIds(Re)}}_updateOutlineLabelOffset(){if(!this._hasOutline()||!this._floatingLabel)return;const Re=this._floatingLabel.element;if(!this._iconPrefixContainer&&!this._textPrefixContainer)return void(Re.style.transform="");if(!this._isAttachedToDom())return void(this._needsOutlineLabelOffsetUpdate=!0);const Ge=this._iconPrefixContainer?.nativeElement,Ve=this._textPrefixContainer?.nativeElement,Dt=this._iconSuffixContainer?.nativeElement,ct=this._textSuffixContainer?.nativeElement,Bt=Ge?.getBoundingClientRect().width??0,wn=Ve?.getBoundingClientRect().width??0,qn=Dt?.getBoundingClientRect().width??0,Er=ct?.getBoundingClientRect().width??0;Re.style.transform=`var(\n --mat-mdc-form-field-label-transform,\n translateY(-50%) translateX(calc(${"rtl"===this._dir.value?"-1":"1"} * (${Bt+wn}px + var(--mat-mdc-form-field-label-offset-x, 0px))))\n )`,this._elementRef.nativeElement.style.setProperty("--mat-form-field-notch-max-width",`calc(100% - ${Bt+wn+qn+Er}px)`)}_isAttachedToDom(){const Re=this._elementRef.nativeElement;if(Re.getRootNode){const Ge=Re.getRootNode();return Ge&&Ge!==Re}return document.documentElement.contains(Re)}static \u0275fac=function(Ge){return new(Ge||vt)};static \u0275cmp=i.VBU({type:vt,selectors:[["mat-form-field"]],contentQueries:function(Ge,Ve,Dt){if(1&Ge&&(i.C6U(Dt,Ve._labelChild,rt,5),i.wni(Dt,ft,5),i.wni(Dt,Kn,5),i.wni(Dt,Rn,5),i.wni(Dt,Vt,5),i.wni(Dt,kn,5)),2&Ge){let ct;i.NyB(),i.mGM(ct=i.lsd())&&(Ve._formFieldControl=ct.first),i.mGM(ct=i.lsd())&&(Ve._prefixChildren=ct),i.mGM(ct=i.lsd())&&(Ve._suffixChildren=ct),i.mGM(ct=i.lsd())&&(Ve._errorChildren=ct),i.mGM(ct=i.lsd())&&(Ve._hintChildren=ct)}},viewQuery:function(Ge,Ve){if(1&Ge&&(i.GBs(dt,5),i.GBs(bt,5),i.GBs(lt,5),i.GBs(rn,5),i.GBs(gn,5),i.GBs(Fe,5),i.GBs(W,5),i.GBs(N,5)),2&Ge){let Dt;i.mGM(Dt=i.lsd())&&(Ve._textField=Dt.first),i.mGM(Dt=i.lsd())&&(Ve._iconPrefixContainer=Dt.first),i.mGM(Dt=i.lsd())&&(Ve._textPrefixContainer=Dt.first),i.mGM(Dt=i.lsd())&&(Ve._iconSuffixContainer=Dt.first),i.mGM(Dt=i.lsd())&&(Ve._textSuffixContainer=Dt.first),i.mGM(Dt=i.lsd())&&(Ve._floatingLabel=Dt.first),i.mGM(Dt=i.lsd())&&(Ve._notchedOutline=Dt.first),i.mGM(Dt=i.lsd())&&(Ve._lineRipple=Dt.first)}},hostAttrs:[1,"mat-mdc-form-field"],hostVars:42,hostBindings:function(Ge,Ve){2&Ge&&i.AVh("mat-mdc-form-field-label-always-float",Ve._shouldAlwaysFloat())("mat-mdc-form-field-has-icon-prefix",Ve._hasIconPrefix)("mat-mdc-form-field-has-icon-suffix",Ve._hasIconSuffix)("mat-form-field-invalid",Ve._control.errorState)("mat-form-field-disabled",Ve._control.disabled)("mat-form-field-autofilled",Ve._control.autofilled)("mat-form-field-no-animations","NoopAnimations"===Ve._animationMode)("mat-form-field-appearance-fill","fill"==Ve.appearance)("mat-form-field-appearance-outline","outline"==Ve.appearance)("mat-form-field-hide-placeholder",Ve._hasFloatingLabel()&&!Ve._shouldLabelFloat())("mat-focused",Ve._control.focused)("mat-primary","accent"!==Ve.color&&"warn"!==Ve.color)("mat-accent","accent"===Ve.color)("mat-warn","warn"===Ve.color)("ng-untouched",Ve._shouldForward("untouched"))("ng-touched",Ve._shouldForward("touched"))("ng-pristine",Ve._shouldForward("pristine"))("ng-dirty",Ve._shouldForward("dirty"))("ng-valid",Ve._shouldForward("valid"))("ng-invalid",Ve._shouldForward("invalid"))("ng-pending",Ve._shouldForward("pending"))},inputs:{hideRequiredMarker:"hideRequiredMarker",color:"color",floatLabel:"floatLabel",appearance:"appearance",subscriptSizing:"subscriptSizing",hintLabel:"hintLabel"},exportAs:["matFormField"],features:[i.Jv_([{provide:an,useExisting:vt},{provide:cn,useExisting:vt}])],ngContentSelectors:Vn,decls:18,vars:21,consts:[["labelTemplate",""],["textField",""],["iconPrefixContainer",""],["textPrefixContainer",""],["textSuffixContainer",""],["iconSuffixContainer",""],[1,"mat-mdc-text-field-wrapper","mdc-text-field",3,"click"],[1,"mat-mdc-form-field-focus-overlay"],[1,"mat-mdc-form-field-flex"],["matFormFieldNotchedOutline","",3,"matFormFieldNotchedOutlineOpen"],[1,"mat-mdc-form-field-icon-prefix"],[1,"mat-mdc-form-field-text-prefix"],[1,"mat-mdc-form-field-infix"],[3,"ngTemplateOutlet"],[1,"mat-mdc-form-field-text-suffix"],[1,"mat-mdc-form-field-icon-suffix"],["matFormFieldLineRipple",""],[1,"mat-mdc-form-field-subscript-wrapper","mat-mdc-form-field-bottom-align"],[1,"mat-mdc-form-field-error-wrapper"],[1,"mat-mdc-form-field-hint-wrapper"],["matFormFieldFloatingLabel","",3,"floating","monitorResize","id"],["aria-hidden","true",1,"mat-mdc-form-field-required-marker","mdc-floating-label--required"],[3,"id"],[1,"mat-mdc-form-field-hint-spacer"]],template:function(Ge,Ve){if(1&Ge){const Dt=i.RV6();i.NAR(bn),i.DNE(0,_t,1,1,"ng-template",null,0,i.C5r),i.j41(2,"div",6,1),i.bIt("click",function(Bt){return i.eBV(Dt),i.Njj(Ve._control.onContainerClick(Bt))}),i.DNE(4,ze,1,0,"div",7),i.j41(5,"div",8),i.DNE(6,Ke,2,2,"div",9)(7,Ze,3,0,"div",10)(8,it,3,0,"div",11),i.j41(9,"div",12),i.DNE(10,$t,1,1,null,13),i.SdG(11),i.k0s(),i.DNE(12,Te,3,0,"div",14)(13,Ee,3,0,"div",15),i.k0s(),i.DNE(14,st,1,0,"div",16),i.k0s(),i.j41(15,"div",17),i.DNE(16,Xt,2,1,"div",18)(17,Kt,5,2,"div",19),i.k0s()}if(2&Ge){let Dt;i.R7$(2),i.AVh("mdc-text-field--filled",!Ve._hasOutline())("mdc-text-field--outlined",Ve._hasOutline())("mdc-text-field--no-label",!Ve._hasFloatingLabel())("mdc-text-field--disabled",Ve._control.disabled)("mdc-text-field--invalid",Ve._control.errorState),i.R7$(2),i.vxM(Ve._hasOutline()||Ve._control.disabled?-1:4),i.R7$(2),i.vxM(Ve._hasOutline()?6:-1),i.R7$(),i.vxM(Ve._hasIconPrefix?7:-1),i.R7$(),i.vxM(Ve._hasTextPrefix?8:-1),i.R7$(2),i.vxM(!Ve._hasOutline()||Ve._forceDisplayInfixLabel()?10:-1),i.R7$(2),i.vxM(Ve._hasTextSuffix?12:-1),i.R7$(),i.vxM(Ve._hasIconSuffix?13:-1),i.R7$(),i.vxM(Ve._hasOutline()?-1:14),i.R7$(),i.AVh("mat-mdc-form-field-subscript-dynamic-size","dynamic"===Ve.subscriptSizing),i.R7$(),i.vxM("error"===(Dt=Ve._getDisplayedMessages())?16:"hint"===Dt?17:-1)}},dependencies:[Fe,W,C.T3,N,kn],styles:['.mdc-text-field{display:inline-flex;align-items:baseline;padding:0 16px;position:relative;box-sizing:border-box;overflow:hidden;will-change:opacity,transform,color;border-top-left-radius:4px;border-top-right-radius:4px;border-bottom-right-radius:0;border-bottom-left-radius:0}.mdc-text-field__input{width:100%;min-width:0;border:none;border-radius:0;background:none;padding:0;-moz-appearance:none;-webkit-appearance:none;height:28px}.mdc-text-field__input::-webkit-calendar-picker-indicator{display:none}.mdc-text-field__input::-ms-clear{display:none}.mdc-text-field__input:focus{outline:none}.mdc-text-field__input:invalid{box-shadow:none}.mdc-text-field__input::placeholder{opacity:0}.mdc-text-field__input::-moz-placeholder{opacity:0}.mdc-text-field__input::-webkit-input-placeholder{opacity:0}.mdc-text-field__input:-ms-input-placeholder{opacity:0}.mdc-text-field--no-label .mdc-text-field__input::placeholder,.mdc-text-field--focused .mdc-text-field__input::placeholder{opacity:1}.mdc-text-field--no-label .mdc-text-field__input::-moz-placeholder,.mdc-text-field--focused .mdc-text-field__input::-moz-placeholder{opacity:1}.mdc-text-field--no-label .mdc-text-field__input::-webkit-input-placeholder,.mdc-text-field--focused .mdc-text-field__input::-webkit-input-placeholder{opacity:1}.mdc-text-field--no-label .mdc-text-field__input:-ms-input-placeholder,.mdc-text-field--focused .mdc-text-field__input:-ms-input-placeholder{opacity:1}.mdc-text-field--disabled:not(.mdc-text-field--no-label) .mdc-text-field__input.mat-mdc-input-disabled-interactive::placeholder{opacity:0}.mdc-text-field--disabled:not(.mdc-text-field--no-label) .mdc-text-field__input.mat-mdc-input-disabled-interactive::-moz-placeholder{opacity:0}.mdc-text-field--disabled:not(.mdc-text-field--no-label) .mdc-text-field__input.mat-mdc-input-disabled-interactive::-webkit-input-placeholder{opacity:0}.mdc-text-field--disabled:not(.mdc-text-field--no-label) .mdc-text-field__input.mat-mdc-input-disabled-interactive:-ms-input-placeholder{opacity:0}.mdc-text-field--outlined .mdc-text-field__input,.mdc-text-field--filled.mdc-text-field--no-label .mdc-text-field__input{height:100%}.mdc-text-field--outlined .mdc-text-field__input{display:flex;border:none !important;background-color:rgba(0,0,0,0)}.mdc-text-field--disabled .mdc-text-field__input{pointer-events:auto}.mdc-text-field--filled:not(.mdc-text-field--disabled) .mdc-text-field__input{color:var(--mdc-filled-text-field-input-text-color, var(--mat-sys-on-surface));caret-color:var(--mdc-filled-text-field-caret-color, var(--mat-sys-primary))}.mdc-text-field--filled:not(.mdc-text-field--disabled) .mdc-text-field__input::placeholder{color:var(--mdc-filled-text-field-input-text-placeholder-color, var(--mat-sys-on-surface-variant))}.mdc-text-field--filled:not(.mdc-text-field--disabled) .mdc-text-field__input::-moz-placeholder{color:var(--mdc-filled-text-field-input-text-placeholder-color, var(--mat-sys-on-surface-variant))}.mdc-text-field--filled:not(.mdc-text-field--disabled) .mdc-text-field__input::-webkit-input-placeholder{color:var(--mdc-filled-text-field-input-text-placeholder-color, var(--mat-sys-on-surface-variant))}.mdc-text-field--filled:not(.mdc-text-field--disabled) .mdc-text-field__input:-ms-input-placeholder{color:var(--mdc-filled-text-field-input-text-placeholder-color, var(--mat-sys-on-surface-variant))}.mdc-text-field--filled.mdc-text-field--invalid:not(.mdc-text-field--disabled) .mdc-text-field__input{caret-color:var(--mdc-filled-text-field-error-caret-color)}.mdc-text-field--filled.mdc-text-field--disabled .mdc-text-field__input{color:var(--mdc-filled-text-field-disabled-input-text-color, color-mix(in srgb, var(--mat-sys-on-surface) 38%, transparent))}.mdc-text-field--outlined:not(.mdc-text-field--disabled) .mdc-text-field__input{color:var(--mdc-outlined-text-field-input-text-color, var(--mat-sys-on-surface));caret-color:var(--mdc-outlined-text-field-caret-color, var(--mat-sys-primary))}.mdc-text-field--outlined:not(.mdc-text-field--disabled) .mdc-text-field__input::placeholder{color:var(--mdc-outlined-text-field-input-text-placeholder-color, var(--mat-sys-on-surface-variant))}.mdc-text-field--outlined:not(.mdc-text-field--disabled) .mdc-text-field__input::-moz-placeholder{color:var(--mdc-outlined-text-field-input-text-placeholder-color, var(--mat-sys-on-surface-variant))}.mdc-text-field--outlined:not(.mdc-text-field--disabled) .mdc-text-field__input::-webkit-input-placeholder{color:var(--mdc-outlined-text-field-input-text-placeholder-color, var(--mat-sys-on-surface-variant))}.mdc-text-field--outlined:not(.mdc-text-field--disabled) .mdc-text-field__input:-ms-input-placeholder{color:var(--mdc-outlined-text-field-input-text-placeholder-color, var(--mat-sys-on-surface-variant))}.mdc-text-field--outlined.mdc-text-field--invalid:not(.mdc-text-field--disabled) .mdc-text-field__input{caret-color:var(--mdc-outlined-text-field-error-caret-color)}.mdc-text-field--outlined.mdc-text-field--disabled .mdc-text-field__input{color:var(--mdc-outlined-text-field-disabled-input-text-color, color-mix(in srgb, var(--mat-sys-on-surface) 38%, transparent))}@media(forced-colors: active){.mdc-text-field--disabled .mdc-text-field__input{background-color:Window}}.mdc-text-field--filled{height:56px;border-bottom-right-radius:0;border-bottom-left-radius:0;border-top-left-radius:var(--mdc-filled-text-field-container-shape, var(--mat-sys-corner-extra-small));border-top-right-radius:var(--mdc-filled-text-field-container-shape, var(--mat-sys-corner-extra-small))}.mdc-text-field--filled:not(.mdc-text-field--disabled){background-color:var(--mdc-filled-text-field-container-color, var(--mat-sys-surface-variant))}.mdc-text-field--filled.mdc-text-field--disabled{background-color:var(--mdc-filled-text-field-disabled-container-color, color-mix(in srgb, var(--mat-sys-on-surface) 4%, transparent))}.mdc-text-field--outlined{height:56px;overflow:visible;padding-right:max(16px,var(--mdc-outlined-text-field-container-shape, var(--mat-sys-corner-extra-small)));padding-left:max(16px,var(--mdc-outlined-text-field-container-shape, var(--mat-sys-corner-extra-small)) + 4px)}[dir=rtl] .mdc-text-field--outlined{padding-right:max(16px,var(--mdc-outlined-text-field-container-shape, var(--mat-sys-corner-extra-small)) + 4px);padding-left:max(16px,var(--mdc-outlined-text-field-container-shape, var(--mat-sys-corner-extra-small)))}.mdc-floating-label{position:absolute;left:0;transform-origin:left top;line-height:1.15rem;text-align:left;text-overflow:ellipsis;white-space:nowrap;cursor:text;overflow:hidden;will-change:transform}[dir=rtl] .mdc-floating-label{right:0;left:auto;transform-origin:right top;text-align:right}.mdc-text-field .mdc-floating-label{top:50%;transform:translateY(-50%);pointer-events:none}.mdc-notched-outline .mdc-floating-label{display:inline-block;position:relative;max-width:100%}.mdc-text-field--outlined .mdc-floating-label{left:4px;right:auto}[dir=rtl] .mdc-text-field--outlined .mdc-floating-label{left:auto;right:4px}.mdc-text-field--filled .mdc-floating-label{left:16px;right:auto}[dir=rtl] .mdc-text-field--filled .mdc-floating-label{left:auto;right:16px}.mdc-text-field--disabled .mdc-floating-label{cursor:default}@media(forced-colors: active){.mdc-text-field--disabled .mdc-floating-label{z-index:1}}.mdc-text-field--filled.mdc-text-field--no-label .mdc-floating-label{display:none}.mdc-text-field--filled:not(.mdc-text-field--disabled) .mdc-floating-label{color:var(--mdc-filled-text-field-label-text-color, var(--mat-sys-on-surface-variant))}.mdc-text-field--filled:not(.mdc-text-field--disabled).mdc-text-field--focused .mdc-floating-label{color:var(--mdc-filled-text-field-focus-label-text-color, var(--mat-sys-primary))}.mdc-text-field--filled:not(.mdc-text-field--disabled):not(.mdc-text-field--focused):hover .mdc-floating-label{color:var(--mdc-filled-text-field-hover-label-text-color, var(--mat-sys-on-surface-variant))}.mdc-text-field--filled.mdc-text-field--disabled .mdc-floating-label{color:var(--mdc-filled-text-field-disabled-label-text-color, color-mix(in srgb, var(--mat-sys-on-surface) 38%, transparent))}.mdc-text-field--filled:not(.mdc-text-field--disabled).mdc-text-field--invalid .mdc-floating-label{color:var(--mdc-filled-text-field-error-label-text-color, var(--mat-sys-error))}.mdc-text-field--filled:not(.mdc-text-field--disabled).mdc-text-field--invalid.mdc-text-field--focused .mdc-floating-label{color:var(--mdc-filled-text-field-error-focus-label-text-color, var(--mat-sys-error))}.mdc-text-field--filled:not(.mdc-text-field--disabled).mdc-text-field--invalid:not(.mdc-text-field--disabled):hover .mdc-floating-label{color:var(--mdc-filled-text-field-error-hover-label-text-color, var(--mat-sys-on-error-container))}.mdc-text-field--filled .mdc-floating-label{font-family:var(--mdc-filled-text-field-label-text-font, var(--mat-sys-body-large-font));font-size:var(--mdc-filled-text-field-label-text-size, var(--mat-sys-body-large-size));font-weight:var(--mdc-filled-text-field-label-text-weight, var(--mat-sys-body-large-weight));letter-spacing:var(--mdc-filled-text-field-label-text-tracking, var(--mat-sys-body-large-tracking))}.mdc-text-field--outlined:not(.mdc-text-field--disabled) .mdc-floating-label{color:var(--mdc-outlined-text-field-label-text-color, var(--mat-sys-on-surface-variant))}.mdc-text-field--outlined:not(.mdc-text-field--disabled).mdc-text-field--focused .mdc-floating-label{color:var(--mdc-outlined-text-field-focus-label-text-color, var(--mat-sys-primary))}.mdc-text-field--outlined:not(.mdc-text-field--disabled):not(.mdc-text-field--focused):hover .mdc-floating-label{color:var(--mdc-outlined-text-field-hover-label-text-color, var(--mat-sys-on-surface))}.mdc-text-field--outlined.mdc-text-field--disabled .mdc-floating-label{color:var(--mdc-outlined-text-field-disabled-label-text-color, color-mix(in srgb, var(--mat-sys-on-surface) 38%, transparent))}.mdc-text-field--outlined:not(.mdc-text-field--disabled).mdc-text-field--invalid .mdc-floating-label{color:var(--mdc-outlined-text-field-error-label-text-color, var(--mat-sys-error))}.mdc-text-field--outlined:not(.mdc-text-field--disabled).mdc-text-field--invalid.mdc-text-field--focused .mdc-floating-label{color:var(--mdc-outlined-text-field-error-focus-label-text-color, var(--mat-sys-error))}.mdc-text-field--outlined:not(.mdc-text-field--disabled).mdc-text-field--invalid:not(.mdc-text-field--disabled):hover .mdc-floating-label{color:var(--mdc-outlined-text-field-error-hover-label-text-color, var(--mat-sys-on-error-container))}.mdc-text-field--outlined .mdc-floating-label{font-family:var(--mdc-outlined-text-field-label-text-font, var(--mat-sys-body-large-font));font-size:var(--mdc-outlined-text-field-label-text-size, var(--mat-sys-body-large-size));font-weight:var(--mdc-outlined-text-field-label-text-weight, var(--mat-sys-body-large-weight));letter-spacing:var(--mdc-outlined-text-field-label-text-tracking, var(--mat-sys-body-large-tracking))}.mdc-floating-label--float-above{cursor:auto;transform:translateY(-106%) scale(0.75)}.mdc-text-field--filled .mdc-floating-label--float-above{transform:translateY(-106%) scale(0.75)}.mdc-text-field--outlined .mdc-floating-label--float-above{transform:translateY(-37.25px) scale(1);font-size:.75rem}.mdc-notched-outline .mdc-floating-label--float-above{text-overflow:clip}.mdc-notched-outline--upgraded .mdc-floating-label--float-above{max-width:133.3333333333%}.mdc-text-field--outlined.mdc-notched-outline--upgraded .mdc-floating-label--float-above,.mdc-text-field--outlined .mdc-notched-outline--upgraded .mdc-floating-label--float-above{transform:translateY(-34.75px) scale(0.75)}.mdc-text-field--outlined.mdc-notched-outline--upgraded .mdc-floating-label--float-above,.mdc-text-field--outlined .mdc-notched-outline--upgraded .mdc-floating-label--float-above{font-size:1rem}.mdc-floating-label--required:not(.mdc-floating-label--hide-required-marker)::after{margin-left:1px;margin-right:0;content:"*"}[dir=rtl] .mdc-floating-label--required:not(.mdc-floating-label--hide-required-marker)::after{margin-left:0;margin-right:1px}.mdc-notched-outline{display:flex;position:absolute;top:0;right:0;left:0;box-sizing:border-box;width:100%;max-width:100%;height:100%;text-align:left;pointer-events:none}[dir=rtl] .mdc-notched-outline{text-align:right}.mdc-text-field--outlined .mdc-notched-outline{z-index:1}.mat-mdc-notch-piece{box-sizing:border-box;height:100%;pointer-events:none;border-top:1px solid;border-bottom:1px solid}.mdc-text-field--focused .mat-mdc-notch-piece{border-width:2px}.mdc-text-field--outlined:not(.mdc-text-field--disabled) .mat-mdc-notch-piece{border-color:var(--mdc-outlined-text-field-outline-color, var(--mat-sys-outline));border-width:var(--mdc-outlined-text-field-outline-width, 1px)}.mdc-text-field--outlined:not(.mdc-text-field--disabled):not(.mdc-text-field--focused):hover .mat-mdc-notch-piece{border-color:var(--mdc-outlined-text-field-hover-outline-color, var(--mat-sys-on-surface))}.mdc-text-field--outlined:not(.mdc-text-field--disabled).mdc-text-field--focused .mat-mdc-notch-piece{border-color:var(--mdc-outlined-text-field-focus-outline-color, var(--mat-sys-primary))}.mdc-text-field--outlined.mdc-text-field--disabled .mat-mdc-notch-piece{border-color:var(--mdc-outlined-text-field-disabled-outline-color, color-mix(in srgb, var(--mat-sys-on-surface) 12%, transparent))}.mdc-text-field--outlined:not(.mdc-text-field--disabled).mdc-text-field--invalid .mat-mdc-notch-piece{border-color:var(--mdc-outlined-text-field-error-outline-color, var(--mat-sys-error))}.mdc-text-field--outlined:not(.mdc-text-field--disabled).mdc-text-field--invalid:not(.mdc-text-field--focused):hover .mdc-notched-outline .mat-mdc-notch-piece{border-color:var(--mdc-outlined-text-field-error-hover-outline-color, var(--mat-sys-on-error-container))}.mdc-text-field--outlined:not(.mdc-text-field--disabled).mdc-text-field--invalid.mdc-text-field--focused .mat-mdc-notch-piece{border-color:var(--mdc-outlined-text-field-error-focus-outline-color, var(--mat-sys-error))}.mdc-text-field--outlined:not(.mdc-text-field--disabled).mdc-text-field--focused .mdc-notched-outline .mat-mdc-notch-piece{border-width:var(--mdc-outlined-text-field-focus-outline-width, 2px)}.mdc-notched-outline__leading{border-left:1px solid;border-right:none;border-top-right-radius:0;border-bottom-right-radius:0;border-top-left-radius:var(--mdc-outlined-text-field-container-shape, var(--mat-sys-corner-extra-small));border-bottom-left-radius:var(--mdc-outlined-text-field-container-shape, var(--mat-sys-corner-extra-small))}.mdc-text-field--outlined .mdc-notched-outline .mdc-notched-outline__leading{width:max(12px,var(--mdc-outlined-text-field-container-shape, var(--mat-sys-corner-extra-small)))}[dir=rtl] .mdc-notched-outline__leading{border-left:none;border-right:1px solid;border-bottom-left-radius:0;border-top-left-radius:0;border-top-right-radius:var(--mdc-outlined-text-field-container-shape, var(--mat-sys-corner-extra-small));border-bottom-right-radius:var(--mdc-outlined-text-field-container-shape, var(--mat-sys-corner-extra-small))}.mdc-notched-outline__trailing{flex-grow:1;border-left:none;border-right:1px solid;border-top-left-radius:0;border-bottom-left-radius:0;border-top-right-radius:var(--mdc-outlined-text-field-container-shape, var(--mat-sys-corner-extra-small));border-bottom-right-radius:var(--mdc-outlined-text-field-container-shape, var(--mat-sys-corner-extra-small))}[dir=rtl] .mdc-notched-outline__trailing{border-left:1px solid;border-right:none;border-top-right-radius:0;border-bottom-right-radius:0;border-top-left-radius:var(--mdc-outlined-text-field-container-shape, var(--mat-sys-corner-extra-small));border-bottom-left-radius:var(--mdc-outlined-text-field-container-shape, var(--mat-sys-corner-extra-small))}.mdc-notched-outline__notch{flex:0 0 auto;width:auto}.mdc-text-field--outlined .mdc-notched-outline .mdc-notched-outline__notch{max-width:min(var(--mat-form-field-notch-max-width, 100%),100% - max(12px,var(--mdc-outlined-text-field-container-shape, var(--mat-sys-corner-extra-small)))*2)}.mdc-text-field--outlined .mdc-notched-outline--notched .mdc-notched-outline__notch{padding-top:1px}.mdc-text-field--focused.mdc-text-field--outlined .mdc-notched-outline--notched .mdc-notched-outline__notch{padding-top:2px}.mdc-notched-outline--notched .mdc-notched-outline__notch{padding-left:0;padding-right:8px;border-top:none;--mat-form-field-notch-max-width: 100%}[dir=rtl] .mdc-notched-outline--notched .mdc-notched-outline__notch{padding-left:8px;padding-right:0}.mdc-notched-outline--no-label .mdc-notched-outline__notch{display:none}.mdc-line-ripple::before,.mdc-line-ripple::after{position:absolute;bottom:0;left:0;width:100%;border-bottom-style:solid;content:""}.mdc-line-ripple::before{z-index:1;border-bottom-width:var(--mdc-filled-text-field-active-indicator-height, 1px)}.mdc-text-field--filled:not(.mdc-text-field--disabled) .mdc-line-ripple::before{border-bottom-color:var(--mdc-filled-text-field-active-indicator-color, var(--mat-sys-on-surface-variant))}.mdc-text-field--filled:not(.mdc-text-field--disabled):not(.mdc-text-field--focused):hover .mdc-line-ripple::before{border-bottom-color:var(--mdc-filled-text-field-hover-active-indicator-color, var(--mat-sys-on-surface))}.mdc-text-field--filled.mdc-text-field--disabled .mdc-line-ripple::before{border-bottom-color:var(--mdc-filled-text-field-disabled-active-indicator-color, color-mix(in srgb, var(--mat-sys-on-surface) 38%, transparent))}.mdc-text-field--filled:not(.mdc-text-field--disabled).mdc-text-field--invalid .mdc-line-ripple::before{border-bottom-color:var(--mdc-filled-text-field-error-active-indicator-color, var(--mat-sys-error))}.mdc-text-field--filled:not(.mdc-text-field--disabled).mdc-text-field--invalid:not(.mdc-text-field--focused):hover .mdc-line-ripple::before{border-bottom-color:var(--mdc-filled-text-field-error-hover-active-indicator-color, var(--mat-sys-on-error-container))}.mdc-line-ripple::after{transform:scaleX(0);opacity:0;z-index:2}.mdc-text-field--filled .mdc-line-ripple::after{border-bottom-width:var(--mdc-filled-text-field-focus-active-indicator-height, 2px)}.mdc-text-field--filled:not(.mdc-text-field--disabled) .mdc-line-ripple::after{border-bottom-color:var(--mdc-filled-text-field-focus-active-indicator-color, var(--mat-sys-primary))}.mdc-text-field--filled.mdc-text-field--invalid:not(.mdc-text-field--disabled) .mdc-line-ripple::after{border-bottom-color:var(--mdc-filled-text-field-error-focus-active-indicator-color, var(--mat-sys-error))}.mdc-line-ripple--active::after{transform:scaleX(1);opacity:1}.mdc-line-ripple--deactivating::after{opacity:0}.mdc-text-field--disabled{pointer-events:none}.mat-mdc-form-field-textarea-control{vertical-align:middle;resize:vertical;box-sizing:border-box;height:auto;margin:0;padding:0;border:none;overflow:auto}.mat-mdc-form-field-input-control.mat-mdc-form-field-input-control{-moz-osx-font-smoothing:grayscale;-webkit-font-smoothing:antialiased;font:inherit;letter-spacing:inherit;text-decoration:inherit;text-transform:inherit;border:none}.mat-mdc-form-field .mat-mdc-floating-label.mdc-floating-label{-moz-osx-font-smoothing:grayscale;-webkit-font-smoothing:antialiased;line-height:normal;pointer-events:all;will-change:auto}.mat-mdc-form-field:not(.mat-form-field-disabled) .mat-mdc-floating-label.mdc-floating-label{cursor:inherit}.mdc-text-field--no-label:not(.mdc-text-field--textarea) .mat-mdc-form-field-input-control.mdc-text-field__input,.mat-mdc-text-field-wrapper .mat-mdc-form-field-input-control{height:auto}.mat-mdc-text-field-wrapper .mat-mdc-form-field-input-control.mdc-text-field__input[type=color]{height:23px}.mat-mdc-text-field-wrapper{height:auto;flex:auto;will-change:auto}.mat-mdc-form-field-has-icon-prefix .mat-mdc-text-field-wrapper{padding-left:0;--mat-mdc-form-field-label-offset-x: -16px}.mat-mdc-form-field-has-icon-suffix .mat-mdc-text-field-wrapper{padding-right:0}[dir=rtl] .mat-mdc-text-field-wrapper{padding-left:16px;padding-right:16px}[dir=rtl] .mat-mdc-form-field-has-icon-suffix .mat-mdc-text-field-wrapper{padding-left:0}[dir=rtl] .mat-mdc-form-field-has-icon-prefix .mat-mdc-text-field-wrapper{padding-right:0}.mat-form-field-disabled .mdc-text-field__input::placeholder{color:var(--mat-form-field-disabled-input-text-placeholder-color, color-mix(in srgb, var(--mat-sys-on-surface) 38%, transparent))}.mat-form-field-disabled .mdc-text-field__input::-moz-placeholder{color:var(--mat-form-field-disabled-input-text-placeholder-color, color-mix(in srgb, var(--mat-sys-on-surface) 38%, transparent))}.mat-form-field-disabled .mdc-text-field__input::-webkit-input-placeholder{color:var(--mat-form-field-disabled-input-text-placeholder-color, color-mix(in srgb, var(--mat-sys-on-surface) 38%, transparent))}.mat-form-field-disabled .mdc-text-field__input:-ms-input-placeholder{color:var(--mat-form-field-disabled-input-text-placeholder-color, color-mix(in srgb, var(--mat-sys-on-surface) 38%, transparent))}.mat-mdc-form-field-label-always-float .mdc-text-field__input::placeholder{transition-delay:40ms;transition-duration:110ms;opacity:1}.mat-mdc-text-field-wrapper .mat-mdc-form-field-infix .mat-mdc-floating-label{left:auto;right:auto}.mat-mdc-text-field-wrapper.mdc-text-field--outlined .mdc-text-field__input{display:inline-block}.mat-mdc-form-field .mat-mdc-text-field-wrapper.mdc-text-field .mdc-notched-outline__notch{padding-top:0}.mat-mdc-form-field.mat-mdc-form-field.mat-mdc-form-field.mat-mdc-form-field.mat-mdc-form-field.mat-mdc-form-field .mdc-notched-outline__notch{border-left:1px solid rgba(0,0,0,0)}[dir=rtl] .mat-mdc-form-field.mat-mdc-form-field.mat-mdc-form-field.mat-mdc-form-field.mat-mdc-form-field.mat-mdc-form-field .mdc-notched-outline__notch{border-left:none;border-right:1px solid rgba(0,0,0,0)}.mat-mdc-form-field-infix{min-height:var(--mat-form-field-container-height, 56px);padding-top:var(--mat-form-field-filled-with-label-container-padding-top, 24px);padding-bottom:var(--mat-form-field-filled-with-label-container-padding-bottom, 8px)}.mdc-text-field--outlined .mat-mdc-form-field-infix,.mdc-text-field--no-label .mat-mdc-form-field-infix{padding-top:var(--mat-form-field-container-vertical-padding, 16px);padding-bottom:var(--mat-form-field-container-vertical-padding, 16px)}.mat-mdc-text-field-wrapper .mat-mdc-form-field-flex .mat-mdc-floating-label{top:calc(var(--mat-form-field-container-height, 56px)/2)}.mdc-text-field--filled .mat-mdc-floating-label{display:var(--mat-form-field-filled-label-display, block)}.mat-mdc-text-field-wrapper.mdc-text-field--outlined .mdc-notched-outline--upgraded .mdc-floating-label--float-above{--mat-mdc-form-field-label-transform: translateY(calc(calc(6.75px + var(--mat-form-field-container-height, 56px) / 2) * -1)) scale(var(--mat-mdc-form-field-floating-label-scale, 0.75));transform:var(--mat-mdc-form-field-label-transform)}.mat-mdc-form-field-subscript-wrapper{box-sizing:border-box;width:100%;position:relative}.mat-mdc-form-field-hint-wrapper,.mat-mdc-form-field-error-wrapper{position:absolute;top:0;left:0;right:0;padding:0 16px}.mat-mdc-form-field-subscript-dynamic-size .mat-mdc-form-field-hint-wrapper,.mat-mdc-form-field-subscript-dynamic-size .mat-mdc-form-field-error-wrapper{position:static}.mat-mdc-form-field-bottom-align::before{content:"";display:inline-block;height:16px}.mat-mdc-form-field-bottom-align.mat-mdc-form-field-subscript-dynamic-size::before{content:unset}.mat-mdc-form-field-hint-end{order:1}.mat-mdc-form-field-hint-wrapper{display:flex}.mat-mdc-form-field-hint-spacer{flex:1 0 1em}.mat-mdc-form-field-error{display:block;color:var(--mat-form-field-error-text-color, var(--mat-sys-error))}.mat-mdc-form-field-subscript-wrapper,.mat-mdc-form-field-bottom-align::before{-moz-osx-font-smoothing:grayscale;-webkit-font-smoothing:antialiased;font-family:var(--mat-form-field-subscript-text-font, var(--mat-sys-body-small-font));line-height:var(--mat-form-field-subscript-text-line-height, var(--mat-sys-body-small-line-height));font-size:var(--mat-form-field-subscript-text-size, var(--mat-sys-body-small-size));letter-spacing:var(--mat-form-field-subscript-text-tracking, var(--mat-sys-body-small-tracking));font-weight:var(--mat-form-field-subscript-text-weight, var(--mat-sys-body-small-weight))}.mat-mdc-form-field-focus-overlay{top:0;left:0;right:0;bottom:0;position:absolute;opacity:0;pointer-events:none;background-color:var(--mat-form-field-state-layer-color, var(--mat-sys-on-surface))}.mat-mdc-text-field-wrapper:hover .mat-mdc-form-field-focus-overlay{opacity:var(--mat-form-field-hover-state-layer-opacity, var(--mat-sys-hover-state-layer-opacity))}.mat-mdc-form-field.mat-focused .mat-mdc-form-field-focus-overlay{opacity:var(--mat-form-field-focus-state-layer-opacity, 0)}select.mat-mdc-form-field-input-control{-moz-appearance:none;-webkit-appearance:none;background-color:rgba(0,0,0,0);display:inline-flex;box-sizing:border-box}select.mat-mdc-form-field-input-control:not(:disabled){cursor:pointer}select.mat-mdc-form-field-input-control:not(.mat-mdc-native-select-inline) option{color:var(--mat-form-field-select-option-text-color, var(--mat-sys-neutral10))}select.mat-mdc-form-field-input-control:not(.mat-mdc-native-select-inline) option:disabled{color:var(--mat-form-field-select-disabled-option-text-color, color-mix(in srgb, var(--mat-sys-neutral10) 38%, transparent))}.mat-mdc-form-field-type-mat-native-select .mat-mdc-form-field-infix::after{content:"";width:0;height:0;border-left:5px solid rgba(0,0,0,0);border-right:5px solid rgba(0,0,0,0);border-top:5px solid;position:absolute;right:0;top:50%;margin-top:-2.5px;pointer-events:none;color:var(--mat-form-field-enabled-select-arrow-color, var(--mat-sys-on-surface-variant))}[dir=rtl] .mat-mdc-form-field-type-mat-native-select .mat-mdc-form-field-infix::after{right:auto;left:0}.mat-mdc-form-field-type-mat-native-select.mat-focused .mat-mdc-form-field-infix::after{color:var(--mat-form-field-focus-select-arrow-color, var(--mat-sys-primary))}.mat-mdc-form-field-type-mat-native-select.mat-form-field-disabled .mat-mdc-form-field-infix::after{color:var(--mat-form-field-disabled-select-arrow-color, color-mix(in srgb, var(--mat-sys-on-surface) 38%, transparent))}.mat-mdc-form-field-type-mat-native-select .mat-mdc-form-field-input-control{padding-right:15px}[dir=rtl] .mat-mdc-form-field-type-mat-native-select .mat-mdc-form-field-input-control{padding-right:0;padding-left:15px}@media(forced-colors: active){.mat-form-field-appearance-fill .mat-mdc-text-field-wrapper{outline:solid 1px}}@media(forced-colors: active){.mat-form-field-appearance-fill.mat-form-field-disabled .mat-mdc-text-field-wrapper{outline-color:GrayText}}@media(forced-colors: active){.mat-form-field-appearance-fill.mat-focused .mat-mdc-text-field-wrapper{outline:dashed 3px}}@media(forced-colors: active){.mat-mdc-form-field.mat-focused .mdc-notched-outline{border:dashed 3px}}.mat-mdc-form-field-input-control[type=date],.mat-mdc-form-field-input-control[type=datetime],.mat-mdc-form-field-input-control[type=datetime-local],.mat-mdc-form-field-input-control[type=month],.mat-mdc-form-field-input-control[type=week],.mat-mdc-form-field-input-control[type=time]{line-height:1}.mat-mdc-form-field-input-control::-webkit-datetime-edit{line-height:1;padding:0;margin-bottom:-2px}.mat-mdc-form-field{--mat-mdc-form-field-floating-label-scale: 0.75;display:inline-flex;flex-direction:column;min-width:0;text-align:left;-moz-osx-font-smoothing:grayscale;-webkit-font-smoothing:antialiased;font-family:var(--mat-form-field-container-text-font, var(--mat-sys-body-large-font));line-height:var(--mat-form-field-container-text-line-height, var(--mat-sys-body-large-line-height));font-size:var(--mat-form-field-container-text-size, var(--mat-sys-body-large-size));letter-spacing:var(--mat-form-field-container-text-tracking, var(--mat-sys-body-large-tracking));font-weight:var(--mat-form-field-container-text-weight, var(--mat-sys-body-large-weight))}.mat-mdc-form-field .mdc-text-field--outlined .mdc-floating-label--float-above{font-size:calc(var(--mat-form-field-outlined-label-text-populated-size)*var(--mat-mdc-form-field-floating-label-scale))}.mat-mdc-form-field .mdc-text-field--outlined .mdc-notched-outline--upgraded .mdc-floating-label--float-above{font-size:var(--mat-form-field-outlined-label-text-populated-size)}[dir=rtl] .mat-mdc-form-field{text-align:right}.mat-mdc-form-field-flex{display:inline-flex;align-items:baseline;box-sizing:border-box;width:100%}.mat-mdc-text-field-wrapper{width:100%;z-index:0}.mat-mdc-form-field-icon-prefix,.mat-mdc-form-field-icon-suffix{align-self:center;line-height:0;pointer-events:auto;position:relative;z-index:1}.mat-mdc-form-field-icon-prefix>.mat-icon,.mat-mdc-form-field-icon-suffix>.mat-icon{padding:0 12px;box-sizing:content-box}.mat-mdc-form-field-icon-prefix{color:var(--mat-form-field-leading-icon-color, var(--mat-sys-on-surface-variant))}.mat-form-field-disabled .mat-mdc-form-field-icon-prefix{color:var(--mat-form-field-disabled-leading-icon-color, color-mix(in srgb, var(--mat-sys-on-surface) 38%, transparent))}.mat-mdc-form-field-icon-suffix{color:var(--mat-form-field-trailing-icon-color, var(--mat-sys-on-surface-variant))}.mat-form-field-disabled .mat-mdc-form-field-icon-suffix{color:var(--mat-form-field-disabled-trailing-icon-color, color-mix(in srgb, var(--mat-sys-on-surface) 38%, transparent))}.mat-form-field-invalid .mat-mdc-form-field-icon-suffix{color:var(--mat-form-field-error-trailing-icon-color, var(--mat-sys-error))}.mat-form-field-invalid:not(.mat-focused):not(.mat-form-field-disabled) .mat-mdc-text-field-wrapper:hover .mat-mdc-form-field-icon-suffix{color:var(--mat-form-field-error-hover-trailing-icon-color, var(--mat-sys-on-error-container))}.mat-form-field-invalid.mat-focused .mat-mdc-text-field-wrapper .mat-mdc-form-field-icon-suffix{color:var(--mat-form-field-error-focus-trailing-icon-color, var(--mat-sys-error))}.mat-mdc-form-field-icon-prefix,[dir=rtl] .mat-mdc-form-field-icon-suffix{padding:0 4px 0 0}.mat-mdc-form-field-icon-suffix,[dir=rtl] .mat-mdc-form-field-icon-prefix{padding:0 0 0 4px}.mat-mdc-form-field-subscript-wrapper .mat-icon,.mat-mdc-form-field label .mat-icon{width:1em;height:1em;font-size:inherit}.mat-mdc-form-field-infix{flex:auto;min-width:0;width:180px;position:relative;box-sizing:border-box}.mat-mdc-form-field-infix:has(textarea[cols]){width:auto}.mat-mdc-form-field .mdc-notched-outline__notch{margin-left:-1px;-webkit-clip-path:inset(-9em -999em -9em 1px);clip-path:inset(-9em -999em -9em 1px)}[dir=rtl] .mat-mdc-form-field .mdc-notched-outline__notch{margin-left:0;margin-right:-1px;-webkit-clip-path:inset(-9em 1px -9em -999em);clip-path:inset(-9em 1px -9em -999em)}.mat-mdc-form-field:not(.mat-form-field-no-animations) .mdc-floating-label{transition:transform 150ms cubic-bezier(0.4, 0, 0.2, 1),color 150ms cubic-bezier(0.4, 0, 0.2, 1)}.mat-mdc-form-field:not(.mat-form-field-no-animations) .mdc-text-field__input{transition:opacity 150ms cubic-bezier(0.4, 0, 0.2, 1)}.mat-mdc-form-field:not(.mat-form-field-no-animations) .mdc-text-field__input::placeholder{transition:opacity 67ms cubic-bezier(0.4, 0, 0.2, 1)}.mat-mdc-form-field:not(.mat-form-field-no-animations) .mdc-text-field__input::-moz-placeholder{transition:opacity 67ms cubic-bezier(0.4, 0, 0.2, 1)}.mat-mdc-form-field:not(.mat-form-field-no-animations) .mdc-text-field__input::-webkit-input-placeholder{transition:opacity 67ms cubic-bezier(0.4, 0, 0.2, 1)}.mat-mdc-form-field:not(.mat-form-field-no-animations) .mdc-text-field__input:-ms-input-placeholder{transition:opacity 67ms cubic-bezier(0.4, 0, 0.2, 1)}.mat-mdc-form-field:not(.mat-form-field-no-animations).mdc-text-field--no-label .mdc-text-field__input::placeholder,.mat-mdc-form-field:not(.mat-form-field-no-animations).mdc-text-field--focused .mdc-text-field__input::placeholder{transition-delay:40ms;transition-duration:110ms}.mat-mdc-form-field:not(.mat-form-field-no-animations).mdc-text-field--no-label .mdc-text-field__input::-moz-placeholder,.mat-mdc-form-field:not(.mat-form-field-no-animations).mdc-text-field--focused .mdc-text-field__input::-moz-placeholder{transition-delay:40ms;transition-duration:110ms}.mat-mdc-form-field:not(.mat-form-field-no-animations).mdc-text-field--no-label .mdc-text-field__input::-webkit-input-placeholder,.mat-mdc-form-field:not(.mat-form-field-no-animations).mdc-text-field--focused .mdc-text-field__input::-webkit-input-placeholder{transition-delay:40ms;transition-duration:110ms}.mat-mdc-form-field:not(.mat-form-field-no-animations).mdc-text-field--no-label .mdc-text-field__input:-ms-input-placeholder,.mat-mdc-form-field:not(.mat-form-field-no-animations).mdc-text-field--focused .mdc-text-field__input:-ms-input-placeholder{transition-delay:40ms;transition-duration:110ms}.mat-mdc-form-field:not(.mat-form-field-no-animations) .mdc-text-field--filled:not(.mdc-ripple-upgraded):focus .mdc-text-field__ripple::before{transition-duration:75ms}.mat-mdc-form-field:not(.mat-form-field-no-animations) .mdc-line-ripple::after{transition:transform 180ms cubic-bezier(0.4, 0, 0.2, 1),opacity 180ms cubic-bezier(0.4, 0, 0.2, 1)}.mdc-notched-outline .mdc-floating-label{max-width:calc(100% + 1px)}.mdc-notched-outline--upgraded .mdc-floating-label--float-above{max-width:calc(133.3333333333% + 1px)}'],encapsulation:2,data:{animation:[Le.transitionMessages]},changeDetection:0})}return vt})(),Vr=(()=>{class vt{static \u0275fac=function(Ge){return new(Ge||vt)};static \u0275mod=i.$C({type:vt});static \u0275inj=i.G2t({imports:[ue.yE,ce.w5,ue.yE]})}return vt})()},3904:(o,s,r)=>{"use strict";r.d(s,{An:()=>_t,m_:()=>ze,tp:()=>Ce});var i=r(3107),a=r(2902),c=r(4460),y=r(3016),w=r(8915),C=r(2653),T=r(5710),S=r(2040),M=r(7947),O=r(7178),L=r(4447),Z=r(6218),q=r(7610),re=r(7691),pe=r(6388);const se=["*"];let ae;function be($e){return function me(){if(void 0===ae&&(ae=null,typeof window<"u")){const $e=window;void 0!==$e.trustedTypes&&(ae=$e.trustedTypes.createPolicy("angular#components",{createHTML:Ft=>Ft}))}return ae}()?.createHTML($e)||$e}function Oe($e){return Error(`Unable to find icon with the name "${$e}"`)}function De($e){return Error(`The URL provided to MatIconRegistry was not trusted as a resource URL via Angular's DomSanitizer. Attempted URL was "${$e}".`)}function ce($e){return Error(`The literal provided to MatIconRegistry was not trusted as safe HTML by Angular's DomSanitizer. Attempted literal was "${$e}".`)}class ue{url;svgText;options;svgElement;constructor(Ft,Ke,Ze){this.url=Ft,this.svgText=Ke,this.options=Ze}}let Ce=(()=>{class $e{_httpClient;_sanitizer;_errorHandler;_document;_svgIconConfigs=new Map;_iconSetConfigs=new Map;_cachedIconsByUrl=new Map;_inProgressUrlFetches=new Map;_fontCssClassesByAlias=new Map;_resolvers=[];_defaultFontSetClass=["material-icons","mat-ligature-font"];constructor(Ke,Ze,it,Ot){this._httpClient=Ke,this._sanitizer=Ze,this._errorHandler=Ot,this._document=it}addSvgIcon(Ke,Ze,it){return this.addSvgIconInNamespace("",Ke,Ze,it)}addSvgIconLiteral(Ke,Ze,it){return this.addSvgIconLiteralInNamespace("",Ke,Ze,it)}addSvgIconInNamespace(Ke,Ze,it,Ot){return this._addSvgIconConfig(Ke,Ze,new ue(it,null,Ot))}addSvgIconResolver(Ke){return this._resolvers.push(Ke),this}addSvgIconLiteralInNamespace(Ke,Ze,it,Ot){const $t=this._sanitizer.sanitize(i.WPN.HTML,it);if(!$t)throw ce(it);const Te=be($t);return this._addSvgIconConfig(Ke,Ze,new ue("",Te,Ot))}addSvgIconSet(Ke,Ze){return this.addSvgIconSetInNamespace("",Ke,Ze)}addSvgIconSetLiteral(Ke,Ze){return this.addSvgIconSetLiteralInNamespace("",Ke,Ze)}addSvgIconSetInNamespace(Ke,Ze,it){return this._addSvgIconSetConfig(Ke,new ue(Ze,null,it))}addSvgIconSetLiteralInNamespace(Ke,Ze,it){const Ot=this._sanitizer.sanitize(i.WPN.HTML,Ze);if(!Ot)throw ce(Ze);const $t=be(Ot);return this._addSvgIconSetConfig(Ke,new ue("",$t,it))}registerFontClassAlias(Ke,Ze=Ke){return this._fontCssClassesByAlias.set(Ke,Ze),this}classNameForFontAlias(Ke){return this._fontCssClassesByAlias.get(Ke)||Ke}setDefaultFontSetClass(...Ke){return this._defaultFontSetClass=Ke,this}getDefaultFontSetClass(){return this._defaultFontSetClass}getSvgIconFromUrl(Ke){const Ze=this._sanitizer.sanitize(i.WPN.RESOURCE_URL,Ke);if(!Ze)throw De(Ke);const it=this._cachedIconsByUrl.get(Ze);return it?(0,y.of)(dt(it)):this._loadSvgIconFromConfig(new ue(Ke,null)).pipe((0,S.M)(Ot=>this._cachedIconsByUrl.set(Ze,Ot)),(0,M.T)(Ot=>dt(Ot)))}getNamedSvgIcon(Ke,Ze=""){const it=bt(Ze,Ke);let Ot=this._svgIconConfigs.get(it);if(Ot)return this._getSvgFromConfig(Ot);if(Ot=this._getIconConfigFromResolvers(Ze,Ke),Ot)return this._svgIconConfigs.set(it,Ot),this._getSvgFromConfig(Ot);const $t=this._iconSetConfigs.get(Ze);return $t?this._getSvgFromIconSetConfigs(Ke,$t):(0,w.$)(Oe(it))}ngOnDestroy(){this._resolvers=[],this._svgIconConfigs.clear(),this._iconSetConfigs.clear(),this._cachedIconsByUrl.clear()}_getSvgFromConfig(Ke){return Ke.svgText?(0,y.of)(dt(this._svgElementFromConfig(Ke))):this._loadSvgIconFromConfig(Ke).pipe((0,M.T)(Ze=>dt(Ze)))}_getSvgFromIconSetConfigs(Ke,Ze){const it=this._extractIconWithNameFromAnySet(Ke,Ze);if(it)return(0,y.of)(it);const Ot=Ze.filter($t=>!$t.svgText).map($t=>this._loadSvgIconSetFromConfig($t).pipe((0,O.W)(Te=>{const st=`Loading icon set URL: ${this._sanitizer.sanitize(i.WPN.RESOURCE_URL,$t.url)} failed: ${Te.message}`;return this._errorHandler.handleError(new Error(st)),(0,y.of)(null)})));return(0,C.p)(Ot).pipe((0,M.T)(()=>{const $t=this._extractIconWithNameFromAnySet(Ke,Ze);if(!$t)throw Oe(Ke);return $t}))}_extractIconWithNameFromAnySet(Ke,Ze){for(let it=Ze.length-1;it>=0;it--){const Ot=Ze[it];if(Ot.svgText&&Ot.svgText.toString().indexOf(Ke)>-1){const $t=this._svgElementFromConfig(Ot),Te=this._extractSvgIconFromSet($t,Ke,Ot.options);if(Te)return Te}}return null}_loadSvgIconFromConfig(Ke){return this._fetchIcon(Ke).pipe((0,S.M)(Ze=>Ke.svgText=Ze),(0,M.T)(()=>this._svgElementFromConfig(Ke)))}_loadSvgIconSetFromConfig(Ke){return Ke.svgText?(0,y.of)(null):this._fetchIcon(Ke).pipe((0,S.M)(Ze=>Ke.svgText=Ze))}_extractSvgIconFromSet(Ke,Ze,it){const Ot=Ke.querySelector(`[id="${Ze}"]`);if(!Ot)return null;const $t=Ot.cloneNode(!0);if($t.removeAttribute("id"),"svg"===$t.nodeName.toLowerCase())return this._setSvgAttributes($t,it);if("symbol"===$t.nodeName.toLowerCase())return this._setSvgAttributes(this._toSvgElement($t),it);const Te=this._svgElementFromString(be(""));return Te.appendChild($t),this._setSvgAttributes(Te,it)}_svgElementFromString(Ke){const Ze=this._document.createElement("DIV");Ze.innerHTML=Ke;const it=Ze.querySelector("svg");if(!it)throw Error(" tag not found");return it}_toSvgElement(Ke){const Ze=this._svgElementFromString(be("")),it=Ke.attributes;for(let Ot=0;Otbe(st)),(0,L.j)(()=>this._inProgressUrlFetches.delete($t)),(0,Z.u)());return this._inProgressUrlFetches.set($t,Ee),Ee}_addSvgIconConfig(Ke,Ze,it){return this._svgIconConfigs.set(bt(Ke,Ze),it),this}_addSvgIconSetConfig(Ke,Ze){const it=this._iconSetConfigs.get(Ke);return it?it.push(Ze):this._iconSetConfigs.set(Ke,[Ze]),this}_svgElementFromConfig(Ke){if(!Ke.svgElement){const Ze=this._svgElementFromString(Ke.svgText);this._setSvgAttributes(Ze,Ke.options),Ke.svgElement=Ze}return Ke.svgElement}_getIconConfigFromResolvers(Ke,Ze){for(let it=0;itFt?Ft.pathname+Ft.search:""}}}),Vn=["clip-path","color-profile","src","cursor","fill","filter","marker","marker-start","marker-mid","marker-end","mask","stroke"],yn=Vn.map($e=>`[${$e}]`).join(", "),qe=/^url\(['"]?#(.*?)['"]?\)$/;let _t=(()=>{class $e{_elementRef=(0,i.WQX)(i.aKT);_iconRegistry=(0,i.WQX)(Ce);_location=(0,i.WQX)(gn);_errorHandler=(0,i.WQX)(i.zcH);_defaultColor;get color(){return this._color||this._defaultColor}set color(Ke){this._color=Ke}_color;inline=!1;get svgIcon(){return this._svgIcon}set svgIcon(Ke){Ke!==this._svgIcon&&(Ke?this._updateSvgIcon(Ke):this._svgIcon&&this._clearSvgElement(),this._svgIcon=Ke)}_svgIcon;get fontSet(){return this._fontSet}set fontSet(Ke){const Ze=this._cleanupFontValue(Ke);Ze!==this._fontSet&&(this._fontSet=Ze,this._updateFontIconClasses())}_fontSet;get fontIcon(){return this._fontIcon}set fontIcon(Ke){const Ze=this._cleanupFontValue(Ke);Ze!==this._fontIcon&&(this._fontIcon=Ze,this._updateFontIconClasses())}_fontIcon;_previousFontSetClass=[];_previousFontIconClass;_svgName;_svgNamespace;_previousPath;_elementsWithExternalReferences;_currentIconFetch=T.yU.EMPTY;constructor(){const Ke=(0,i.WQX)(new i.ES_("aria-hidden"),{optional:!0}),Ze=(0,i.WQX)(rn,{optional:!0});Ze&&(Ze.color&&(this.color=this._defaultColor=Ze.color),Ze.fontSet&&(this.fontSet=Ze.fontSet)),Ke||this._elementRef.nativeElement.setAttribute("aria-hidden","true")}_splitIconName(Ke){if(!Ke)return["",""];const Ze=Ke.split(":");switch(Ze.length){case 1:return["",Ze[0]];case 2:return Ze;default:throw Error(`Invalid icon name: "${Ke}"`)}}ngOnInit(){this._updateFontIconClasses()}ngAfterViewChecked(){const Ke=this._elementsWithExternalReferences;if(Ke&&Ke.size){const Ze=this._location.getPathname();Ze!==this._previousPath&&(this._previousPath=Ze,this._prependPathToReferences(Ze))}}ngOnDestroy(){this._currentIconFetch.unsubscribe(),this._elementsWithExternalReferences&&this._elementsWithExternalReferences.clear()}_usingFontIcon(){return!this.svgIcon}_setSvgElement(Ke){this._clearSvgElement();const Ze=this._location.getPathname();this._previousPath=Ze,this._cacheChildrenWithExternalReferences(Ke),this._prependPathToReferences(Ze),this._elementRef.nativeElement.appendChild(Ke)}_clearSvgElement(){const Ke=this._elementRef.nativeElement;let Ze=Ke.childNodes.length;for(this._elementsWithExternalReferences&&this._elementsWithExternalReferences.clear();Ze--;){const it=Ke.childNodes[Ze];(1!==it.nodeType||"svg"===it.nodeName.toLowerCase())&&it.remove()}}_updateFontIconClasses(){if(!this._usingFontIcon())return;const Ke=this._elementRef.nativeElement,Ze=(this.fontSet?this._iconRegistry.classNameForFontAlias(this.fontSet).split(/ +/):this._iconRegistry.getDefaultFontSetClass()).filter(it=>it.length>0);this._previousFontSetClass.forEach(it=>Ke.classList.remove(it)),Ze.forEach(it=>Ke.classList.add(it)),this._previousFontSetClass=Ze,this.fontIcon!==this._previousFontIconClass&&!Ze.includes("mat-ligature-font")&&(this._previousFontIconClass&&Ke.classList.remove(this._previousFontIconClass),this.fontIcon&&Ke.classList.add(this.fontIcon),this._previousFontIconClass=this.fontIcon)}_cleanupFontValue(Ke){return"string"==typeof Ke?Ke.trim().split(" ")[0]:Ke}_prependPathToReferences(Ke){const Ze=this._elementsWithExternalReferences;Ze&&Ze.forEach((it,Ot)=>{it.forEach($t=>{Ot.setAttribute($t.name,`url('${Ke}#${$t.value}')`)})})}_cacheChildrenWithExternalReferences(Ke){const Ze=Ke.querySelectorAll(yn),it=this._elementsWithExternalReferences=this._elementsWithExternalReferences||new Map;for(let Ot=0;Ot{const Te=Ze[Ot],Ee=Te.getAttribute($t),st=Ee?Ee.match(qe):null;if(st){let Xt=it.get(Te);Xt||(Xt=[],it.set(Te,Xt)),Xt.push({name:$t,value:st[1]})}})}_updateSvgIcon(Ke){if(this._svgNamespace=null,this._svgName=null,this._currentIconFetch.unsubscribe(),Ke){const[Ze,it]=this._splitIconName(Ke);Ze&&(this._svgNamespace=Ze),it&&(this._svgName=it),this._currentIconFetch=this._iconRegistry.getNamedSvgIcon(it,Ze).pipe((0,q.s)(1)).subscribe(Ot=>this._setSvgElement(Ot),Ot=>{this._errorHandler.handleError(new Error(`Error retrieving icon ${Ze}:${it}! ${Ot.message}`))})}}static \u0275fac=function(Ze){return new(Ze||$e)};static \u0275cmp=i.VBU({type:$e,selectors:[["mat-icon"]],hostAttrs:["role","img",1,"mat-icon","notranslate"],hostVars:10,hostBindings:function(Ze,it){2&Ze&&(i.BMQ("data-mat-icon-type",it._usingFontIcon()?"font":"svg")("data-mat-icon-name",it._svgName||it.fontIcon)("data-mat-icon-namespace",it._svgNamespace||it.fontSet)("fontIcon",it._usingFontIcon()?it.fontIcon:null),i.HbH(it.color?"mat-"+it.color:""),i.AVh("mat-icon-inline",it.inline)("mat-icon-no-color","primary"!==it.color&&"accent"!==it.color&&"warn"!==it.color))},inputs:{color:"color",inline:[2,"inline","inline",i.L39],svgIcon:"svgIcon",fontSet:"fontSet",fontIcon:"fontIcon"},exportAs:["matIcon"],features:[i.GFd],ngContentSelectors:se,decls:1,vars:0,template:function(Ze,it){1&Ze&&(i.NAR(),i.SdG(0))},styles:["mat-icon,mat-icon.mat-primary,mat-icon.mat-accent,mat-icon.mat-warn{color:var(--mat-icon-color, inherit)}.mat-icon{-webkit-user-select:none;user-select:none;background-repeat:no-repeat;display:inline-block;fill:currentColor;height:24px;width:24px;overflow:hidden}.mat-icon.mat-icon-inline{font-size:inherit;height:inherit;line-height:inherit;width:inherit}.mat-icon.mat-ligature-font[fontIcon]::before{content:attr(fontIcon)}[dir=rtl] .mat-icon-rtl-mirror{transform:scale(-1, 1)}.mat-form-field:not(.mat-form-field-appearance-legacy) .mat-form-field-prefix .mat-icon,.mat-form-field:not(.mat-form-field-appearance-legacy) .mat-form-field-suffix .mat-icon{display:block}.mat-form-field:not(.mat-form-field-appearance-legacy) .mat-form-field-prefix .mat-icon-button .mat-icon,.mat-form-field:not(.mat-form-field-appearance-legacy) .mat-form-field-suffix .mat-icon-button .mat-icon{margin:auto}"],encapsulation:2,changeDetection:0})}return $e})(),ze=(()=>{class $e{static \u0275fac=function(Ze){return new(Ze||$e)};static \u0275mod=i.$C({type:$e});static \u0275inj=i.G2t({imports:[a.yE,a.yE]})}return $e})()},6389:(o,s,r)=>{"use strict";r.d(s,{fS:()=>pe,fg:()=>re});var i=r(3022),a=r(2147),c=r(708),y=r(3107),w=r(8559),C=r(936),T=r(2902),S=r(6071),M=r(8447);const L=new y.nKC("MAT_INPUT_VALUE_ACCESSOR"),Z=["button","checkbox","file","hidden","image","radio","range","reset","submit"],q=new y.nKC("MAT_INPUT_CONFIG");let re=(()=>{class se{_elementRef=(0,y.WQX)(y.aKT);_platform=(0,y.WQX)(a.OD);ngControl=(0,y.WQX)(C.vO,{optional:!0,self:!0});_autofillMonitor=(0,y.WQX)(c.P8);_ngZone=(0,y.WQX)(y.SKi);_formField=(0,y.WQX)(S.xb,{optional:!0});_uid=(0,y.WQX)(w.g7).getId("mat-input-");_previousNativeValue;_inputValueAccessor;_signalBasedValueAccessor;_previousPlaceholder;_errorStateTracker;_webkitBlinkWheelListenerAttached=!1;_config=(0,y.WQX)(q,{optional:!0});_formFieldDescribedBy;_isServer;_isNativeSelect;_isTextarea;_isInFormField;focused=!1;stateChanges=new M.B;controlType="mat-input";autofilled=!1;get disabled(){return this._disabled}set disabled(me){this._disabled=(0,i.he)(me),this.focused&&(this.focused=!1,this.stateChanges.next())}_disabled=!1;get id(){return this._id}set id(me){this._id=me||this._uid}_id;placeholder;name;get required(){return this._required??this.ngControl?.control?.hasValidator(C.k0.required)??!1}set required(me){this._required=(0,i.he)(me)}_required;get type(){return this._type}set type(me){this._type=me||"text",this._validateType(),!this._isTextarea&&(0,a.MU)().has(this._type)&&(this._elementRef.nativeElement.type=this._type),this._ensureWheelDefaultBehavior()}_type="text";get errorStateMatcher(){return this._errorStateTracker.matcher}set errorStateMatcher(me){this._errorStateTracker.matcher=me}userAriaDescribedBy;get value(){return this._signalBasedValueAccessor?this._signalBasedValueAccessor.value():this._inputValueAccessor.value}set value(me){me!==this.value&&(this._signalBasedValueAccessor?this._signalBasedValueAccessor.value.set(me):this._inputValueAccessor.value=me,this.stateChanges.next())}get readonly(){return this._readonly}set readonly(me){this._readonly=(0,i.he)(me)}_readonly=!1;disabledInteractive;get errorState(){return this._errorStateTracker.errorState}set errorState(me){this._errorStateTracker.errorState=me}_neverEmptyInputTypes=["date","datetime","datetime-local","month","time","week"].filter(me=>(0,a.MU)().has(me));constructor(){const me=(0,y.WQX)(C.cV,{optional:!0}),be=(0,y.WQX)(C.j4,{optional:!0}),Oe=(0,y.WQX)(T.es),xe=(0,y.WQX)(L,{optional:!0,self:!0}),De=this._elementRef.nativeElement,ce=De.nodeName.toLowerCase();xe?(0,y.Hps)(xe.value)?this._signalBasedValueAccessor=xe:this._inputValueAccessor=xe:this._inputValueAccessor=De,this._previousNativeValue=this.value,this.id=this.id,this._platform.IOS&&this._ngZone.runOutsideAngular(()=>{De.addEventListener("keyup",this._iOSKeyupListener)}),this._errorStateTracker=new T.X0(Oe,this.ngControl,be,me,this.stateChanges),this._isServer=!this._platform.isBrowser,this._isNativeSelect="select"===ce,this._isTextarea="textarea"===ce,this._isInFormField=!!this._formField,this.disabledInteractive=this._config?.disabledInteractive||!1,this._isNativeSelect&&(this.controlType=De.multiple?"mat-native-select-multiple":"mat-native-select"),this._signalBasedValueAccessor&&(0,y.QZP)(()=>{this._signalBasedValueAccessor.value(),this.stateChanges.next()})}ngAfterViewInit(){this._platform.isBrowser&&this._autofillMonitor.monitor(this._elementRef.nativeElement).subscribe(me=>{this.autofilled=me.isAutofilled,this.stateChanges.next()})}ngOnChanges(){this.stateChanges.next()}ngOnDestroy(){this.stateChanges.complete(),this._platform.isBrowser&&this._autofillMonitor.stopMonitoring(this._elementRef.nativeElement),this._platform.IOS&&this._elementRef.nativeElement.removeEventListener("keyup",this._iOSKeyupListener),this._webkitBlinkWheelListenerAttached&&this._elementRef.nativeElement.removeEventListener("wheel",this._webkitBlinkWheelListener)}ngDoCheck(){this.ngControl&&(this.updateErrorState(),null!==this.ngControl.disabled&&this.ngControl.disabled!==this.disabled&&(this.disabled=this.ngControl.disabled,this.stateChanges.next())),this._dirtyCheckNativeValue(),this._dirtyCheckPlaceholder()}focus(me){this._elementRef.nativeElement.focus(me)}updateErrorState(){this._errorStateTracker.updateErrorState()}_focusChanged(me){if(me!==this.focused){if(!this._isNativeSelect&&me&&this.disabled&&this.disabledInteractive){const be=this._elementRef.nativeElement;"number"===be.type?(be.type="text",be.setSelectionRange(0,0),be.type="number"):be.setSelectionRange(0,0)}this.focused=me,this.stateChanges.next()}}_onInput(){}_dirtyCheckNativeValue(){const me=this._elementRef.nativeElement.value;this._previousNativeValue!==me&&(this._previousNativeValue=me,this.stateChanges.next())}_dirtyCheckPlaceholder(){const me=this._getPlaceholder();if(me!==this._previousPlaceholder){const be=this._elementRef.nativeElement;this._previousPlaceholder=me,me?be.setAttribute("placeholder",me):be.removeAttribute("placeholder")}}_getPlaceholder(){return this.placeholder||null}_validateType(){Z.indexOf(this._type)}_isNeverEmpty(){return this._neverEmptyInputTypes.indexOf(this._type)>-1}_isBadInput(){let me=this._elementRef.nativeElement.validity;return me&&me.badInput}get empty(){return!(this._isNeverEmpty()||this._elementRef.nativeElement.value||this._isBadInput()||this.autofilled)}get shouldLabelFloat(){if(this._isNativeSelect){const me=this._elementRef.nativeElement,be=me.options[0];return this.focused||me.multiple||!this.empty||!!(me.selectedIndex>-1&&be&&be.label)}return this.focused&&!this.disabled||!this.empty}setDescribedByIds(me){const be=this._elementRef.nativeElement,Oe=be.getAttribute("aria-describedby");let xe;if(Oe){const De=this._formFieldDescribedBy||me;xe=me.concat(Oe.split(" ").filter(ce=>ce&&!De.includes(ce)))}else xe=me;this._formFieldDescribedBy=me,xe.length?be.setAttribute("aria-describedby",xe.join(" ")):be.removeAttribute("aria-describedby")}onContainerClick(){this.focused||this.focus()}_isInlineSelect(){const me=this._elementRef.nativeElement;return this._isNativeSelect&&(me.multiple||me.size>1)}_iOSKeyupListener=me=>{const be=me.target;!be.value&&0===be.selectionStart&&0===be.selectionEnd&&(be.setSelectionRange(1,1),be.setSelectionRange(0,0))};_webkitBlinkWheelListener=()=>{};_ensureWheelDefaultBehavior(){!this._webkitBlinkWheelListenerAttached&&"number"===this._type&&(this._platform.BLINK||this._platform.WEBKIT)&&(this._ngZone.runOutsideAngular(()=>{this._elementRef.nativeElement.addEventListener("wheel",this._webkitBlinkWheelListener)}),this._webkitBlinkWheelListenerAttached=!0),this._webkitBlinkWheelListenerAttached&&"number"!==this._type&&(this._elementRef.nativeElement.removeEventListener("wheel",this._webkitBlinkWheelListener),this._webkitBlinkWheelListenerAttached=!0)}_getReadonlyAttribute(){return this._isNativeSelect?null:this.readonly||this.disabled&&this.disabledInteractive?"true":null}static \u0275fac=function(be){return new(be||se)};static \u0275dir=y.FsC({type:se,selectors:[["input","matInput",""],["textarea","matInput",""],["select","matNativeControl",""],["input","matNativeControl",""],["textarea","matNativeControl",""]],hostAttrs:[1,"mat-mdc-input-element"],hostVars:21,hostBindings:function(be,Oe){1&be&&y.bIt("focus",function(){return Oe._focusChanged(!0)})("blur",function(){return Oe._focusChanged(!1)})("input",function(){return Oe._onInput()}),2&be&&(y.Mr5("id",Oe.id)("disabled",Oe.disabled&&!Oe.disabledInteractive)("required",Oe.required),y.BMQ("name",Oe.name||null)("readonly",Oe._getReadonlyAttribute())("aria-disabled",Oe.disabled&&Oe.disabledInteractive?"true":null)("aria-invalid",Oe.empty&&Oe.required?null:Oe.errorState)("aria-required",Oe.required)("id",Oe.id),y.AVh("mat-input-server",Oe._isServer)("mat-mdc-form-field-textarea-control",Oe._isInFormField&&Oe._isTextarea)("mat-mdc-form-field-input-control",Oe._isInFormField)("mat-mdc-input-disabled-interactive",Oe.disabledInteractive)("mdc-text-field__input",Oe._isInFormField)("mat-mdc-native-select-inline",Oe._isInlineSelect()))},inputs:{disabled:"disabled",id:"id",placeholder:"placeholder",name:"name",required:"required",type:"type",errorStateMatcher:"errorStateMatcher",userAriaDescribedBy:[0,"aria-describedby","userAriaDescribedBy"],value:"value",readonly:"readonly",disabledInteractive:[2,"disabledInteractive","disabledInteractive",y.L39]},exportAs:["matInput"],features:[y.Jv_([{provide:S.qT,useExisting:se}]),y.GFd,y.OA$]})}return se})(),pe=(()=>{class se{static \u0275fac=function(be){return new(be||se)};static \u0275mod=y.$C({type:se});static \u0275inj=y.G2t({imports:[T.yE,S.RG,S.RG,c.EE,T.yE]})}return se})()},7818:(o,s,r)=>{"use strict";r.d(s,{Cn:()=>Xt,Cp:()=>st,fb:()=>rn,kk:()=>Ze});var i=r(3107),a=r(8559),c=r(5919),y=r(8447),w=r(7509),C=r(5710),T=r(3016),S=r(4984),M=r(593),O=r(2867),L=r(5424),Z=r(1483),q=r(7610),re=r(8136),pe=r(4460),se=r(2902),ae=r(5467),me=r(6192),be=r(1204),Oe=r(2944),xe=r(9666),De=r(2147),ce=r(8108);const ue=["mat-menu-item",""],Ce=[[["mat-icon"],["","matMenuItemIcon",""]],"*"],Be=["mat-icon, [matMenuItemIcon]","*"];function at(Mt,Kt){1&Mt&&(i.qSk(),i.j41(0,"svg",2),i.nrm(1,"polygon",3),i.k0s())}const dt=["*"];function bt(Mt,Kt){if(1&Mt){const rt=i.RV6();i.j41(0,"div",0),i.bIt("click",function(){i.eBV(rt);const en=i.XpG();return i.Njj(en.closed.emit("click"))})("@transformMenu.start",function(en){i.eBV(rt);const kn=i.XpG();return i.Njj(kn._onAnimationStart(en))})("@transformMenu.done",function(en){i.eBV(rt);const kn=i.XpG();return i.Njj(kn._onAnimationDone(en))}),i.j41(1,"div",1),i.SdG(2),i.k0s()()}if(2&Mt){const rt=i.XpG();i.HbH(rt._classList),i.Y8G("id",rt.panelId)("@transformMenu",rt._panelAnimationState),i.BMQ("aria-label",rt.ariaLabel||null)("aria-labelledby",rt.ariaLabelledby||null)("aria-describedby",rt.ariaDescribedby||null)}}const lt=new i.nKC("MAT_MENU_PANEL");let rn=(()=>{class Mt{_elementRef=(0,i.WQX)(i.aKT);_document=(0,i.WQX)(pe.qQ);_focusMonitor=(0,i.WQX)(a.FN);_parentMenu=(0,i.WQX)(lt,{optional:!0});_changeDetectorRef=(0,i.WQX)(i.gRc);role="menuitem";disabled=!1;disableRipple=!1;_hovered=new y.B;_focused=new y.B;_highlighted=!1;_triggersSubmenu=!1;constructor(){(0,i.WQX)(ae.l).load(se.Ah),this._parentMenu?.addItem?.(this)}focus(rt,Vt){this._focusMonitor&&rt?this._focusMonitor.focusVia(this._getHostElement(),rt,Vt):this._getHostElement().focus(Vt),this._focused.next(this)}ngAfterViewInit(){this._focusMonitor&&this._focusMonitor.monitor(this._elementRef,!1)}ngOnDestroy(){this._focusMonitor&&this._focusMonitor.stopMonitoring(this._elementRef),this._parentMenu&&this._parentMenu.removeItem&&this._parentMenu.removeItem(this),this._hovered.complete(),this._focused.complete()}_getTabIndex(){return this.disabled?"-1":"0"}_getHostElement(){return this._elementRef.nativeElement}_checkDisabled(rt){this.disabled&&(rt.preventDefault(),rt.stopPropagation())}_handleMouseEnter(){this._hovered.next(this)}getLabel(){const rt=this._elementRef.nativeElement.cloneNode(!0),Vt=rt.querySelectorAll("mat-icon, .material-icons");for(let en=0;en enter",(0,be.i0)("120ms cubic-bezier(0, 0, 0.2, 1)",(0,be.iF)({opacity:1,transform:"scale(1)"}))),(0,be.kY)("* => void",(0,be.i0)("100ms 25ms linear",(0,be.iF)({opacity:0})))]),fadeInItems:(0,be.hZ)("fadeInItems",[(0,be.wk)("showing",(0,be.iF)({opacity:1})),(0,be.kY)("void => *",[(0,be.iF)({opacity:0}),(0,be.i0)("400ms 100ms cubic-bezier(0.55, 0, 0.55, 0.2)")])])},Ft=new i.nKC("mat-menu-default-options",{providedIn:"root",factory:function Ke(){return{overlapTrigger:!1,xPosition:"after",yPosition:"below",backdropClass:"cdk-overlay-transparent-backdrop"}}});let Ze=(()=>{class Mt{_elementRef=(0,i.WQX)(i.aKT);_changeDetectorRef=(0,i.WQX)(i.gRc);_keyManager;_xPosition;_yPosition;_firstItemFocusRef;_allItems;_directDescendantItems=new i.rOR;_classList={};_panelAnimationState="void";_animationDone=new y.B;_isAnimating;parentMenu;direction;overlayPanelClass;backdropClass;ariaLabel;ariaLabelledby;ariaDescribedby;get xPosition(){return this._xPosition}set xPosition(rt){this._xPosition=rt,this.setPositionClasses()}get yPosition(){return this._yPosition}set yPosition(rt){this._yPosition=rt,this.setPositionClasses()}templateRef;items;lazyContent;overlapTrigger;hasBackdrop;set panelClass(rt){const Vt=this._previousPanelClass,en={...this._classList};Vt&&Vt.length&&Vt.split(" ").forEach(kn=>{en[kn]=!1}),this._previousPanelClass=rt,rt&&rt.length&&(rt.split(" ").forEach(kn=>{en[kn]=!0}),this._elementRef.nativeElement.className=""),this._classList=en}_previousPanelClass;get classList(){return this.panelClass}set classList(rt){this.panelClass=rt}closed=new i.bkB;close=this.closed;panelId=(0,i.WQX)(a.g7).getId("mat-menu-panel-");_injector=(0,i.WQX)(i.zZn);constructor(){const rt=(0,i.WQX)(Ft);this.overlayPanelClass=rt.overlayPanelClass||"",this._xPosition=rt.xPosition,this._yPosition=rt.yPosition,this.backdropClass=rt.backdropClass,this.overlapTrigger=rt.overlapTrigger,this.hasBackdrop=rt.hasBackdrop}ngOnInit(){this.setPositionClasses()}ngAfterContentInit(){this._updateDirectDescendants(),this._keyManager=new a.Bu(this._directDescendantItems).withWrap().withTypeAhead().withHomeAndEnd(),this._keyManager.tabOut.subscribe(()=>this.closed.emit("tab")),this._directDescendantItems.changes.pipe((0,M.Z)(this._directDescendantItems),(0,O.n)(rt=>(0,w.h)(...rt.map(Vt=>Vt._focused)))).subscribe(rt=>this._keyManager.updateActiveItem(rt)),this._directDescendantItems.changes.subscribe(rt=>{const Vt=this._keyManager;if("enter"===this._panelAnimationState&&Vt.activeItem?._hasFocus()){const en=rt.toArray(),kn=Math.max(0,Math.min(en.length-1,Vt.activeItemIndex||0));en[kn]&&!en[kn].disabled?Vt.setActiveItem(kn):Vt.setNextItemActive()}})}ngOnDestroy(){this._keyManager?.destroy(),this._directDescendantItems.destroy(),this.closed.complete(),this._firstItemFocusRef?.destroy()}_hovered(){return this._directDescendantItems.changes.pipe((0,M.Z)(this._directDescendantItems),(0,O.n)(Vt=>(0,w.h)(...Vt.map(en=>en._hovered))))}addItem(rt){}removeItem(rt){}_handleKeydown(rt){const Vt=rt.keyCode,en=this._keyManager;switch(Vt){case c._f:(0,c.rp)(rt)||(rt.preventDefault(),this.closed.emit("keydown"));break;case c.UQ:this.parentMenu&&"ltr"===this.direction&&this.closed.emit("keydown");break;case c.LE:this.parentMenu&&"rtl"===this.direction&&this.closed.emit("keydown");break;default:return(Vt===c.i7||Vt===c.n6)&&en.setFocusOrigin("keyboard"),void en.onKeydown(rt)}}focusFirstItem(rt="program"){this._firstItemFocusRef?.destroy(),this._firstItemFocusRef=(0,i.mal)(()=>{let Vt=null;if(this._directDescendantItems.length&&(Vt=this._directDescendantItems.first._getHostElement().closest('[role="menu"]')),!Vt||!Vt.contains(document.activeElement)){const en=this._keyManager;en.setFocusOrigin(rt).setFirstItemActive(),!en.activeItem&&Vt&&Vt.focus()}},{injector:this._injector})}resetActiveItem(){this._keyManager.setActiveItem(-1)}setElevation(rt){}setPositionClasses(rt=this.xPosition,Vt=this.yPosition){this._classList={...this._classList,"mat-menu-before":"before"===rt,"mat-menu-after":"after"===rt,"mat-menu-above":"above"===Vt,"mat-menu-below":"below"===Vt},this._changeDetectorRef.markForCheck()}_startAnimation(){this._panelAnimationState="enter"}_resetAnimation(){this._panelAnimationState="void"}_onAnimationDone(rt){this._animationDone.next(rt),this._isAnimating=!1}_onAnimationStart(rt){this._isAnimating=!0,"enter"===rt.toState&&0===this._keyManager.activeItemIndex&&(rt.element.scrollTop=0)}_updateDirectDescendants(){this._allItems.changes.pipe((0,M.Z)(this._allItems)).subscribe(rt=>{this._directDescendantItems.reset(rt.filter(Vt=>Vt._parentMenu===this)),this._directDescendantItems.notifyOnChanges()})}static \u0275fac=function(Vt){return new(Vt||Mt)};static \u0275cmp=i.VBU({type:Mt,selectors:[["mat-menu"]],contentQueries:function(Vt,en,kn){if(1&Vt&&(i.wni(kn,yn,5),i.wni(kn,rn,5),i.wni(kn,rn,4)),2&Vt){let Kn;i.mGM(Kn=i.lsd())&&(en.lazyContent=Kn.first),i.mGM(Kn=i.lsd())&&(en._allItems=Kn),i.mGM(Kn=i.lsd())&&(en.items=Kn)}},viewQuery:function(Vt,en){if(1&Vt&&i.GBs(i.C4Q,5),2&Vt){let kn;i.mGM(kn=i.lsd())&&(en.templateRef=kn.first)}},hostVars:3,hostBindings:function(Vt,en){2&Vt&&i.BMQ("aria-label",null)("aria-labelledby",null)("aria-describedby",null)},inputs:{backdropClass:"backdropClass",ariaLabel:[0,"aria-label","ariaLabel"],ariaLabelledby:[0,"aria-labelledby","ariaLabelledby"],ariaDescribedby:[0,"aria-describedby","ariaDescribedby"],xPosition:"xPosition",yPosition:"yPosition",overlapTrigger:[2,"overlapTrigger","overlapTrigger",i.L39],hasBackdrop:[2,"hasBackdrop","hasBackdrop",rt=>null==rt?null:(0,i.L39)(rt)],panelClass:[0,"class","panelClass"],classList:"classList"},outputs:{closed:"closed",close:"close"},exportAs:["matMenu"],features:[i.Jv_([{provide:lt,useExisting:Mt}]),i.GFd],ngContentSelectors:dt,decls:1,vars:0,consts:[["tabindex","-1","role","menu",1,"mat-mdc-menu-panel",3,"click","id"],[1,"mat-mdc-menu-content"]],template:function(Vt,en){1&Vt&&(i.NAR(),i.DNE(0,bt,3,7,"ng-template"))},styles:['mat-menu{display:none}.mat-mdc-menu-content{margin:0;padding:8px 0;outline:0}.mat-mdc-menu-content,.mat-mdc-menu-content .mat-mdc-menu-item .mat-mdc-menu-item-text{-moz-osx-font-smoothing:grayscale;-webkit-font-smoothing:antialiased;flex:1;white-space:normal;font-family:var(--mat-menu-item-label-text-font, var(--mat-sys-label-large-font));line-height:var(--mat-menu-item-label-text-line-height, var(--mat-sys-label-large-line-height));font-size:var(--mat-menu-item-label-text-size, var(--mat-sys-label-large-size));letter-spacing:var(--mat-menu-item-label-text-tracking, var(--mat-sys-label-large-tracking));font-weight:var(--mat-menu-item-label-text-weight, var(--mat-sys-label-large-weight))}.mat-mdc-menu-panel{min-width:112px;max-width:280px;overflow:auto;-webkit-overflow-scrolling:touch;box-sizing:border-box;outline:0;border-radius:var(--mat-menu-container-shape, var(--mat-sys-corner-extra-small));background-color:var(--mat-menu-container-color, var(--mat-sys-surface-container));box-shadow:var(--mat-menu-container-elevation-shadow, 0px 3px 1px -2px rgba(0, 0, 0, 0.2), 0px 2px 2px 0px rgba(0, 0, 0, 0.14), 0px 1px 5px 0px rgba(0, 0, 0, 0.12));will-change:transform,opacity}.mat-mdc-menu-panel.ng-animating{pointer-events:none}.mat-mdc-menu-panel.ng-animating:has(.mat-mdc-menu-content:empty){display:none}@media(forced-colors: active){.mat-mdc-menu-panel{outline:solid 1px}}.mat-mdc-menu-panel .mat-divider{color:var(--mat-menu-divider-color, var(--mat-sys-surface-variant));margin-bottom:var(--mat-menu-divider-bottom-spacing, 8px);margin-top:var(--mat-menu-divider-top-spacing, 8px)}.mat-mdc-menu-item{display:flex;position:relative;align-items:center;justify-content:flex-start;overflow:hidden;padding:0;cursor:pointer;width:100%;text-align:left;box-sizing:border-box;color:inherit;font-size:inherit;background:none;text-decoration:none;margin:0;min-height:48px;padding-left:var(--mat-menu-item-leading-spacing, 12px);padding-right:var(--mat-menu-item-trailing-spacing, 12px);-webkit-user-select:none;user-select:none;cursor:pointer;outline:none;border:none;-webkit-tap-highlight-color:rgba(0,0,0,0)}.mat-mdc-menu-item::-moz-focus-inner{border:0}[dir=rtl] .mat-mdc-menu-item{padding-left:var(--mat-menu-item-trailing-spacing, 12px);padding-right:var(--mat-menu-item-leading-spacing, 12px)}.mat-mdc-menu-item:has(.material-icons,mat-icon,[matButtonIcon]){padding-left:var(--mat-menu-item-with-icon-leading-spacing, 12px);padding-right:var(--mat-menu-item-with-icon-trailing-spacing, 12px)}[dir=rtl] .mat-mdc-menu-item:has(.material-icons,mat-icon,[matButtonIcon]){padding-left:var(--mat-menu-item-with-icon-trailing-spacing, 12px);padding-right:var(--mat-menu-item-with-icon-leading-spacing, 12px)}.mat-mdc-menu-item,.mat-mdc-menu-item:visited,.mat-mdc-menu-item:link{color:var(--mat-menu-item-label-text-color, var(--mat-sys-on-surface))}.mat-mdc-menu-item .mat-icon-no-color,.mat-mdc-menu-item .mat-mdc-menu-submenu-icon{color:var(--mat-menu-item-icon-color, var(--mat-sys-on-surface-variant))}.mat-mdc-menu-item[disabled]{cursor:default;opacity:.38}.mat-mdc-menu-item[disabled]::after{display:block;position:absolute;content:"";top:0;left:0;bottom:0;right:0}.mat-mdc-menu-item:focus{outline:0}.mat-mdc-menu-item .mat-icon{flex-shrink:0;margin-right:var(--mat-menu-item-spacing, 12px);height:var(--mat-menu-item-icon-size, 24px);width:var(--mat-menu-item-icon-size, 24px)}[dir=rtl] .mat-mdc-menu-item{text-align:right}[dir=rtl] .mat-mdc-menu-item .mat-icon{margin-right:0;margin-left:var(--mat-menu-item-spacing, 12px)}.mat-mdc-menu-item:not([disabled]):hover{background-color:var(--mat-menu-item-hover-state-layer-color, color-mix(in srgb, var(--mat-sys-on-surface) calc(var(--mat-sys-hover-state-layer-opacity) * 100%), transparent))}.mat-mdc-menu-item:not([disabled]).cdk-program-focused,.mat-mdc-menu-item:not([disabled]).cdk-keyboard-focused,.mat-mdc-menu-item:not([disabled]).mat-mdc-menu-item-highlighted{background-color:var(--mat-menu-item-focus-state-layer-color, color-mix(in srgb, var(--mat-sys-on-surface) calc(var(--mat-sys-focus-state-layer-opacity) * 100%), transparent))}@media(forced-colors: active){.mat-mdc-menu-item{margin-top:1px}}.mat-mdc-menu-submenu-icon{width:var(--mat-menu-item-icon-size, 24px);height:10px;fill:currentColor;padding-left:var(--mat-menu-item-spacing, 12px)}[dir=rtl] .mat-mdc-menu-submenu-icon{padding-right:var(--mat-menu-item-spacing, 12px);padding-left:0}[dir=rtl] .mat-mdc-menu-submenu-icon polygon{transform:scaleX(-1);transform-origin:center}@media(forced-colors: active){.mat-mdc-menu-submenu-icon{fill:CanvasText}}.mat-mdc-menu-item .mat-mdc-menu-ripple{top:0;left:0;right:0;bottom:0;position:absolute;pointer-events:none}'],encapsulation:2,data:{animation:[_t.transformMenu,_t.fadeInItems]},changeDetection:0})}return Mt})();const it=new i.nKC("mat-menu-scroll-strategy",{providedIn:"root",factory:()=>{const Mt=(0,i.WQX)(xe.hJ);return()=>Mt.scrollStrategies.reposition()}}),$t={provide:it,deps:[xe.hJ],useFactory:function Ot(Mt){return()=>Mt.scrollStrategies.reposition()}},Te=(0,De.BQ)({passive:!0});let st=(()=>{class Mt{_overlay=(0,i.WQX)(xe.hJ);_element=(0,i.WQX)(i.aKT);_viewContainerRef=(0,i.WQX)(i.c1b);_menuItemInstance=(0,i.WQX)(rn,{optional:!0,self:!0});_dir=(0,i.WQX)(Oe.dS,{optional:!0});_focusMonitor=(0,i.WQX)(a.FN);_ngZone=(0,i.WQX)(i.SKi);_scrollStrategy=(0,i.WQX)(it);_changeDetectorRef=(0,i.WQX)(i.gRc);_portal;_overlayRef=null;_menuOpen=!1;_closingActionsSubscription=C.yU.EMPTY;_hoverSubscription=C.yU.EMPTY;_menuCloseSubscription=C.yU.EMPTY;_parentMaterialMenu;_parentInnerPadding;_handleTouchStart=rt=>{(0,a.w6)(rt)||(this._openedBy="touch")};_openedBy=void 0;get _deprecatedMatMenuTriggerFor(){return this.menu}set _deprecatedMatMenuTriggerFor(rt){this.menu=rt}get menu(){return this._menu}set menu(rt){rt!==this._menu&&(this._menu=rt,this._menuCloseSubscription.unsubscribe(),rt&&(this._menuCloseSubscription=rt.close.subscribe(Vt=>{this._destroyMenu(Vt),("click"===Vt||"tab"===Vt)&&this._parentMaterialMenu&&this._parentMaterialMenu.closed.emit(Vt)})),this._menuItemInstance?._setTriggersSubmenu(this.triggersSubmenu()))}_menu;menuData;restoreFocus=!0;menuOpened=new i.bkB;onMenuOpen=this.menuOpened;menuClosed=new i.bkB;onMenuClose=this.menuClosed;constructor(){const rt=(0,i.WQX)(lt,{optional:!0});this._parentMaterialMenu=rt instanceof Ze?rt:void 0,this._element.nativeElement.addEventListener("touchstart",this._handleTouchStart,Te)}ngAfterContentInit(){this._handleHover()}ngOnDestroy(){this._overlayRef&&(this._overlayRef.dispose(),this._overlayRef=null),this._element.nativeElement.removeEventListener("touchstart",this._handleTouchStart,Te),this._menuCloseSubscription.unsubscribe(),this._closingActionsSubscription.unsubscribe(),this._hoverSubscription.unsubscribe()}get menuOpen(){return this._menuOpen}get dir(){return this._dir&&"rtl"===this._dir.value?"rtl":"ltr"}triggersSubmenu(){return!!(this._menuItemInstance&&this._parentMaterialMenu&&this.menu)}toggleMenu(){return this._menuOpen?this.closeMenu():this.openMenu()}openMenu(){const rt=this.menu;if(this._menuOpen||!rt)return;const Vt=this._createOverlay(rt),en=Vt.getConfig(),kn=en.positionStrategy;this._setPosition(rt,kn),en.hasBackdrop=null==rt.hasBackdrop?!this.triggersSubmenu():rt.hasBackdrop,Vt.attach(this._getPortal(rt)),rt.lazyContent&&rt.lazyContent.attach(this.menuData),this._closingActionsSubscription=this._menuClosingActions().subscribe(()=>this.closeMenu()),this._initMenu(rt),rt instanceof Ze&&(rt._startAnimation(),rt._directDescendantItems.changes.pipe((0,L.Q)(rt.close)).subscribe(()=>{kn.withLockedPosition(!1).reapplyLastPosition(),kn.withLockedPosition(!0)}))}closeMenu(){this.menu?.close.emit()}focus(rt,Vt){this._focusMonitor&&rt?this._focusMonitor.focusVia(this._element,rt,Vt):this._element.nativeElement.focus(Vt)}updatePosition(){this._overlayRef?.updatePosition()}_destroyMenu(rt){if(!this._overlayRef||!this.menuOpen)return;const Vt=this.menu;this._closingActionsSubscription.unsubscribe(),this._overlayRef.detach(),this.restoreFocus&&("keydown"===rt||!this._openedBy||!this.triggersSubmenu())&&this.focus(this._openedBy),this._openedBy=void 0,Vt instanceof Ze?(Vt._resetAnimation(),Vt.lazyContent?Vt._animationDone.pipe((0,Z.p)(en=>"void"===en.toState),(0,q.s)(1),(0,L.Q)(Vt.lazyContent._attached)).subscribe({next:()=>Vt.lazyContent.detach(),complete:()=>this._setIsMenuOpen(!1)}):this._setIsMenuOpen(!1)):(this._setIsMenuOpen(!1),Vt?.lazyContent?.detach())}_initMenu(rt){rt.parentMenu=this.triggersSubmenu()?this._parentMaterialMenu:void 0,rt.direction=this.dir,rt.focusFirstItem(this._openedBy||"program"),this._setIsMenuOpen(!0)}_setIsMenuOpen(rt){rt!==this._menuOpen&&(this._menuOpen=rt,this._menuOpen?this.menuOpened.emit():this.menuClosed.emit(),this.triggersSubmenu()&&this._menuItemInstance._setHighlighted(rt),this._changeDetectorRef.markForCheck())}_createOverlay(rt){if(!this._overlayRef){const Vt=this._getOverlayConfig(rt);this._subscribeToPositions(rt,Vt.positionStrategy),this._overlayRef=this._overlay.create(Vt),this._overlayRef.keydownEvents().subscribe(en=>{this.menu instanceof Ze&&this.menu._handleKeydown(en)})}return this._overlayRef}_getOverlayConfig(rt){return new xe.rR({positionStrategy:this._overlay.position().flexibleConnectedTo(this._element).withLockedPosition().withGrowAfterOpen().withTransformOriginOn(".mat-menu-panel, .mat-mdc-menu-panel"),backdropClass:rt.backdropClass||"cdk-overlay-transparent-backdrop",panelClass:rt.overlayPanelClass,scrollStrategy:this._scrollStrategy(),direction:this._dir||"ltr"})}_subscribeToPositions(rt,Vt){rt.setPositionClasses&&Vt.positionChanges.subscribe(en=>{this._ngZone.run(()=>{rt.setPositionClasses("start"===en.connectionPair.overlayX?"after":"before","top"===en.connectionPair.overlayY?"below":"above")})})}_setPosition(rt,Vt){let[en,kn]="before"===rt.xPosition?["end","start"]:["start","end"],[Kn,Nr]="above"===rt.yPosition?["bottom","top"]:["top","bottom"],[Rn,pr]=[Kn,Nr],[cn,Fe]=[en,kn],ke=0;if(this.triggersSubmenu()){if(Fe=en="before"===rt.xPosition?"start":"end",kn=cn="end"===en?"start":"end",this._parentMaterialMenu){if(null==this._parentInnerPadding){const Je=this._parentMaterialMenu.items.first;this._parentInnerPadding=Je?Je._getHostElement().offsetTop:0}ke="bottom"===Kn?this._parentInnerPadding:-this._parentInnerPadding}}else rt.overlapTrigger||(Rn="top"===Kn?"bottom":"top",pr="top"===Nr?"bottom":"top");Vt.withPositions([{originX:en,originY:Rn,overlayX:cn,overlayY:Kn,offsetY:ke},{originX:kn,originY:Rn,overlayX:Fe,overlayY:Kn,offsetY:ke},{originX:en,originY:pr,overlayX:cn,overlayY:Nr,offsetY:-ke},{originX:kn,originY:pr,overlayX:Fe,overlayY:Nr,offsetY:-ke}])}_menuClosingActions(){const rt=this._overlayRef.backdropClick(),Vt=this._overlayRef.detachments(),en=this._parentMaterialMenu?this._parentMaterialMenu.closed:(0,T.of)(),kn=this._parentMaterialMenu?this._parentMaterialMenu._hovered().pipe((0,Z.p)(Kn=>Kn!==this._menuItemInstance),(0,Z.p)(()=>this._menuOpen)):(0,T.of)();return(0,w.h)(rt,en,kn,Vt)}_handleMousedown(rt){(0,a._G)(rt)||(this._openedBy=0===rt.button?"mouse":void 0,this.triggersSubmenu()&&rt.preventDefault())}_handleKeydown(rt){const Vt=rt.keyCode;(Vt===c.Fm||Vt===c.t6)&&(this._openedBy="keyboard"),this.triggersSubmenu()&&(Vt===c.LE&&"ltr"===this.dir||Vt===c.UQ&&"rtl"===this.dir)&&(this._openedBy="keyboard",this.openMenu())}_handleClick(rt){this.triggersSubmenu()?(rt.stopPropagation(),this.openMenu()):this.toggleMenu()}_handleHover(){!this.triggersSubmenu()||!this._parentMaterialMenu||(this._hoverSubscription=this._parentMaterialMenu._hovered().pipe((0,Z.p)(rt=>rt===this._menuItemInstance&&!rt.disabled),(0,re.c)(0,S.$)).subscribe(()=>{this._openedBy="mouse",this.menu instanceof Ze&&this.menu._isAnimating?this.menu._animationDone.pipe((0,q.s)(1),(0,re.c)(0,S.$),(0,L.Q)(this._parentMaterialMenu._hovered())).subscribe(()=>this.openMenu()):this.openMenu()}))}_getPortal(rt){return(!this._portal||this._portal.templateRef!==rt.templateRef)&&(this._portal=new me.VA(rt.templateRef,this._viewContainerRef)),this._portal}static \u0275fac=function(Vt){return new(Vt||Mt)};static \u0275dir=i.FsC({type:Mt,selectors:[["","mat-menu-trigger-for",""],["","matMenuTriggerFor",""]],hostAttrs:[1,"mat-mdc-menu-trigger"],hostVars:3,hostBindings:function(Vt,en){1&Vt&&i.bIt("click",function(Kn){return en._handleClick(Kn)})("mousedown",function(Kn){return en._handleMousedown(Kn)})("keydown",function(Kn){return en._handleKeydown(Kn)}),2&Vt&&i.BMQ("aria-haspopup",en.menu?"menu":null)("aria-expanded",en.menuOpen)("aria-controls",en.menuOpen?en.menu.panelId:null)},inputs:{_deprecatedMatMenuTriggerFor:[0,"mat-menu-trigger-for","_deprecatedMatMenuTriggerFor"],menu:[0,"matMenuTriggerFor","menu"],menuData:[0,"matMenuTriggerData","menuData"],restoreFocus:[0,"matMenuTriggerRestoreFocus","restoreFocus"]},outputs:{menuOpened:"menuOpened",onMenuOpen:"onMenuOpen",menuClosed:"menuClosed",onMenuClose:"onMenuClose"},exportAs:["matMenuTrigger"]})}return Mt})(),Xt=(()=>{class Mt{static \u0275fac=function(Vt){return new(Vt||Mt)};static \u0275mod=i.$C({type:Mt});static \u0275inj=i.G2t({providers:[$t],imports:[se.pZ,se.yE,xe.z_,ce.Gj,se.yE]})}return Mt})()},2322:(o,s,r)=>{"use strict";r.d(s,{HM:()=>S,PO:()=>O});var i=r(3107),c=(r(4460),r(2902));function y(L,Z){1&L&&i.nrm(0,"div",2)}const w=new i.nKC("MAT_PROGRESS_BAR_DEFAULT_OPTIONS");let S=(()=>{class L{_elementRef=(0,i.WQX)(i.aKT);_ngZone=(0,i.WQX)(i.SKi);_changeDetectorRef=(0,i.WQX)(i.gRc);_animationMode=(0,i.WQX)(i.bc$,{optional:!0});constructor(){const q=(0,i.WQX)(w,{optional:!0});this._isNoopAnimation="NoopAnimations"===this._animationMode,q&&(q.color&&(this.color=this._defaultColor=q.color),this.mode=q.mode||this.mode)}_isNoopAnimation=!1;get color(){return this._color||this._defaultColor}set color(q){this._color=q}_color;_defaultColor="primary";get value(){return this._value}set value(q){this._value=M(q||0),this._changeDetectorRef.markForCheck()}_value=0;get bufferValue(){return this._bufferValue||0}set bufferValue(q){this._bufferValue=M(q||0),this._changeDetectorRef.markForCheck()}_bufferValue=0;animationEnd=new i.bkB;get mode(){return this._mode}set mode(q){this._mode=q,this._changeDetectorRef.markForCheck()}_mode="determinate";ngAfterViewInit(){this._ngZone.runOutsideAngular(()=>{this._elementRef.nativeElement.addEventListener("transitionend",this._transitionendHandler)})}ngOnDestroy(){this._elementRef.nativeElement.removeEventListener("transitionend",this._transitionendHandler)}_getPrimaryBarTransform(){return`scaleX(${this._isIndeterminate()?1:this.value/100})`}_getBufferBarFlexBasis(){return`${"buffer"===this.mode?this.bufferValue:100}%`}_isIndeterminate(){return"indeterminate"===this.mode||"query"===this.mode}_transitionendHandler=q=>{0===this.animationEnd.observers.length||!q.target||!q.target.classList.contains("mdc-linear-progress__primary-bar")||("determinate"===this.mode||"buffer"===this.mode)&&this._ngZone.run(()=>this.animationEnd.next({value:this.value}))};static \u0275fac=function(re){return new(re||L)};static \u0275cmp=i.VBU({type:L,selectors:[["mat-progress-bar"]],hostAttrs:["role","progressbar","aria-valuemin","0","aria-valuemax","100","tabindex","-1",1,"mat-mdc-progress-bar","mdc-linear-progress"],hostVars:10,hostBindings:function(re,pe){2&re&&(i.BMQ("aria-valuenow",pe._isIndeterminate()?null:pe.value)("mode",pe.mode),i.HbH("mat-"+pe.color),i.AVh("_mat-animation-noopable",pe._isNoopAnimation)("mdc-linear-progress--animation-ready",!pe._isNoopAnimation)("mdc-linear-progress--indeterminate",pe._isIndeterminate()))},inputs:{color:"color",value:[2,"value","value",i.Udg],bufferValue:[2,"bufferValue","bufferValue",i.Udg],mode:"mode"},outputs:{animationEnd:"animationEnd"},exportAs:["matProgressBar"],features:[i.GFd],decls:7,vars:5,consts:[["aria-hidden","true",1,"mdc-linear-progress__buffer"],[1,"mdc-linear-progress__buffer-bar"],[1,"mdc-linear-progress__buffer-dots"],["aria-hidden","true",1,"mdc-linear-progress__bar","mdc-linear-progress__primary-bar"],[1,"mdc-linear-progress__bar-inner"],["aria-hidden","true",1,"mdc-linear-progress__bar","mdc-linear-progress__secondary-bar"]],template:function(re,pe){1&re&&(i.j41(0,"div",0),i.nrm(1,"div",1),i.DNE(2,y,1,0,"div",2),i.k0s(),i.j41(3,"div",3),i.nrm(4,"span",4),i.k0s(),i.j41(5,"div",5),i.nrm(6,"span",4),i.k0s()),2&re&&(i.R7$(),i.xc7("flex-basis",pe._getBufferBarFlexBasis()),i.R7$(),i.vxM("buffer"===pe.mode?2:-1),i.R7$(),i.xc7("transform",pe._getPrimaryBarTransform()))},styles:[".mat-mdc-progress-bar{display:block;text-align:start}.mat-mdc-progress-bar[mode=query]{transform:scaleX(-1)}.mat-mdc-progress-bar._mat-animation-noopable .mdc-linear-progress__buffer-dots,.mat-mdc-progress-bar._mat-animation-noopable .mdc-linear-progress__primary-bar,.mat-mdc-progress-bar._mat-animation-noopable .mdc-linear-progress__secondary-bar,.mat-mdc-progress-bar._mat-animation-noopable .mdc-linear-progress__bar-inner.mdc-linear-progress__bar-inner{animation:none}.mat-mdc-progress-bar._mat-animation-noopable .mdc-linear-progress__primary-bar,.mat-mdc-progress-bar._mat-animation-noopable .mdc-linear-progress__buffer-bar{transition:transform 1ms}.mdc-linear-progress{position:relative;width:100%;transform:translateZ(0);outline:1px solid rgba(0,0,0,0);overflow-x:hidden;transition:opacity 250ms 0ms cubic-bezier(0.4, 0, 0.6, 1);height:max(var(--mdc-linear-progress-track-height, 4px),var(--mdc-linear-progress-active-indicator-height, 4px))}@media(forced-colors: active){.mdc-linear-progress{outline-color:CanvasText}}.mdc-linear-progress__bar{position:absolute;top:0;bottom:0;margin:auto 0;width:100%;animation:none;transform-origin:top left;transition:transform 250ms 0ms cubic-bezier(0.4, 0, 0.6, 1);height:var(--mdc-linear-progress-active-indicator-height, 4px)}.mdc-linear-progress--indeterminate .mdc-linear-progress__bar{transition:none}[dir=rtl] .mdc-linear-progress__bar{right:0;transform-origin:center right}.mdc-linear-progress__bar-inner{display:inline-block;position:absolute;width:100%;animation:none;border-top-style:solid;border-color:var(--mdc-linear-progress-active-indicator-color, var(--mat-sys-primary));border-top-width:var(--mdc-linear-progress-active-indicator-height, 4px)}.mdc-linear-progress__buffer{display:flex;position:absolute;top:0;bottom:0;margin:auto 0;width:100%;overflow:hidden;height:var(--mdc-linear-progress-track-height, 4px);border-radius:var(--mdc-linear-progress-track-shape, var(--mat-sys-corner-none))}.mdc-linear-progress__buffer-dots{-webkit-mask-image:url(\"data:image/svg+xml,%3Csvg version='1.1' xmlns='http://www.w3.org/2000/svg' xmlns:xlink='http://www.w3.org/1999/xlink' x='0px' y='0px' enable-background='new 0 0 5 2' xml:space='preserve' viewBox='0 0 5 2' preserveAspectRatio='xMinYMin slice'%3E%3Ccircle cx='1' cy='1' r='1'/%3E%3C/svg%3E\");mask-image:url(\"data:image/svg+xml,%3Csvg version='1.1' xmlns='http://www.w3.org/2000/svg' xmlns:xlink='http://www.w3.org/1999/xlink' x='0px' y='0px' enable-background='new 0 0 5 2' xml:space='preserve' viewBox='0 0 5 2' preserveAspectRatio='xMinYMin slice'%3E%3Ccircle cx='1' cy='1' r='1'/%3E%3C/svg%3E\");background-repeat:repeat-x;flex:auto;transform:rotate(180deg);animation:mdc-linear-progress-buffering 250ms infinite linear;background-color:var(--mdc-linear-progress-track-color, var(--mat-sys-surface-variant))}@media(forced-colors: active){.mdc-linear-progress__buffer-dots{background-color:ButtonBorder}}[dir=rtl] .mdc-linear-progress__buffer-dots{animation:mdc-linear-progress-buffering-reverse 250ms infinite linear;transform:rotate(0)}.mdc-linear-progress__buffer-bar{flex:0 1 100%;transition:flex-basis 250ms 0ms cubic-bezier(0.4, 0, 0.6, 1);background-color:var(--mdc-linear-progress-track-color, var(--mat-sys-surface-variant))}.mdc-linear-progress__primary-bar{transform:scaleX(0)}.mdc-linear-progress--indeterminate .mdc-linear-progress__primary-bar{left:-145.166611%}.mdc-linear-progress--indeterminate.mdc-linear-progress--animation-ready .mdc-linear-progress__primary-bar{animation:mdc-linear-progress-primary-indeterminate-translate 2s infinite linear}.mdc-linear-progress--indeterminate.mdc-linear-progress--animation-ready .mdc-linear-progress__primary-bar>.mdc-linear-progress__bar-inner{animation:mdc-linear-progress-primary-indeterminate-scale 2s infinite linear}[dir=rtl] .mdc-linear-progress.mdc-linear-progress--animation-ready .mdc-linear-progress__primary-bar{animation-name:mdc-linear-progress-primary-indeterminate-translate-reverse}[dir=rtl] .mdc-linear-progress.mdc-linear-progress--indeterminate .mdc-linear-progress__primary-bar{right:-145.166611%;left:auto}.mdc-linear-progress__secondary-bar{display:none}.mdc-linear-progress--indeterminate .mdc-linear-progress__secondary-bar{left:-54.888891%;display:block}.mdc-linear-progress--indeterminate.mdc-linear-progress--animation-ready .mdc-linear-progress__secondary-bar{animation:mdc-linear-progress-secondary-indeterminate-translate 2s infinite linear}.mdc-linear-progress--indeterminate.mdc-linear-progress--animation-ready .mdc-linear-progress__secondary-bar>.mdc-linear-progress__bar-inner{animation:mdc-linear-progress-secondary-indeterminate-scale 2s infinite linear}[dir=rtl] .mdc-linear-progress.mdc-linear-progress--animation-ready .mdc-linear-progress__secondary-bar{animation-name:mdc-linear-progress-secondary-indeterminate-translate-reverse}[dir=rtl] .mdc-linear-progress.mdc-linear-progress--indeterminate .mdc-linear-progress__secondary-bar{right:-54.888891%;left:auto}@keyframes mdc-linear-progress-buffering{from{transform:rotate(180deg) translateX(calc(var(--mdc-linear-progress-track-height, 4px) * -2.5))}}@keyframes mdc-linear-progress-primary-indeterminate-translate{0%{transform:translateX(0)}20%{animation-timing-function:cubic-bezier(0.5, 0, 0.701732, 0.495819);transform:translateX(0)}59.15%{animation-timing-function:cubic-bezier(0.302435, 0.381352, 0.55, 0.956352);transform:translateX(83.67142%)}100%{transform:translateX(200.611057%)}}@keyframes mdc-linear-progress-primary-indeterminate-scale{0%{transform:scaleX(0.08)}36.65%{animation-timing-function:cubic-bezier(0.334731, 0.12482, 0.785844, 1);transform:scaleX(0.08)}69.15%{animation-timing-function:cubic-bezier(0.06, 0.11, 0.6, 1);transform:scaleX(0.661479)}100%{transform:scaleX(0.08)}}@keyframes mdc-linear-progress-secondary-indeterminate-translate{0%{animation-timing-function:cubic-bezier(0.15, 0, 0.515058, 0.409685);transform:translateX(0)}25%{animation-timing-function:cubic-bezier(0.31033, 0.284058, 0.8, 0.733712);transform:translateX(37.651913%)}48.35%{animation-timing-function:cubic-bezier(0.4, 0.627035, 0.6, 0.902026);transform:translateX(84.386165%)}100%{transform:translateX(160.277782%)}}@keyframes mdc-linear-progress-secondary-indeterminate-scale{0%{animation-timing-function:cubic-bezier(0.205028, 0.057051, 0.57661, 0.453971);transform:scaleX(0.08)}19.15%{animation-timing-function:cubic-bezier(0.152313, 0.196432, 0.648374, 1.004315);transform:scaleX(0.457104)}44.15%{animation-timing-function:cubic-bezier(0.257759, -0.003163, 0.211762, 1.38179);transform:scaleX(0.72796)}100%{transform:scaleX(0.08)}}@keyframes mdc-linear-progress-primary-indeterminate-translate-reverse{0%{transform:translateX(0)}20%{animation-timing-function:cubic-bezier(0.5, 0, 0.701732, 0.495819);transform:translateX(0)}59.15%{animation-timing-function:cubic-bezier(0.302435, 0.381352, 0.55, 0.956352);transform:translateX(-83.67142%)}100%{transform:translateX(-200.611057%)}}@keyframes mdc-linear-progress-secondary-indeterminate-translate-reverse{0%{animation-timing-function:cubic-bezier(0.15, 0, 0.515058, 0.409685);transform:translateX(0)}25%{animation-timing-function:cubic-bezier(0.31033, 0.284058, 0.8, 0.733712);transform:translateX(-37.651913%)}48.35%{animation-timing-function:cubic-bezier(0.4, 0.627035, 0.6, 0.902026);transform:translateX(-84.386165%)}100%{transform:translateX(-160.277782%)}}@keyframes mdc-linear-progress-buffering-reverse{from{transform:translateX(-10px)}}"],encapsulation:2,changeDetection:0})}return L})();function M(L,Z=0,q=100){return Math.max(Z,Math.min(q,L))}let O=(()=>{class L{static \u0275fac=function(re){return new(re||L)};static \u0275mod=i.$C({type:L});static \u0275inj=i.G2t({imports:[c.yE]})}return L})()},4375:(o,s,r)=>{"use strict";r.d(s,{$2:()=>it,VO:()=>Ze,Ve:()=>Ot});var i=r(9666),a=r(3107),c=r(2902),y=r(6071),w=r(8108),C=r(8559),T=r(2944),S=r(1349),M=r(5919),O=r(936),L=r(8447),Z=r(6381),q=r(7509),re=r(593),pe=r(2867),se=r(1483),ae=r(7947),me=r(6645),be=r(5424),Oe=r(7610),xe=r(1204),De=r(4460);const ce=["trigger"],ue=["panel"],Ce=[[["mat-select-trigger"]],"*"],Be=["mat-select-trigger","*"];function at($t,Te){if(1&$t&&(a.j41(0,"span",4),a.EFF(1),a.k0s()),2&$t){const Ee=a.XpG();a.R7$(),a.JRh(Ee.placeholder)}}function dt($t,Te){1&$t&&a.SdG(0)}function bt($t,Te){if(1&$t&&(a.j41(0,"span",11),a.EFF(1),a.k0s()),2&$t){const Ee=a.XpG(2);a.R7$(),a.JRh(Ee.triggerValue)}}function lt($t,Te){if(1&$t&&(a.j41(0,"span",5),a.DNE(1,dt,1,0)(2,bt,2,1,"span",11),a.k0s()),2&$t){const Ee=a.XpG();a.R7$(),a.vxM(Ee.customTrigger?1:2)}}function rn($t,Te){if(1&$t){const Ee=a.RV6();a.j41(0,"div",12,1),a.bIt("@transformPanel.done",function(Xt){a.eBV(Ee);const Mt=a.XpG();return a.Njj(Mt._panelDoneAnimatingStream.next(Xt.toState))})("keydown",function(Xt){a.eBV(Ee);const Mt=a.XpG();return a.Njj(Mt._handleKeydown(Xt))}),a.SdG(2,1),a.k0s()}if(2&$t){const Ee=a.XpG();a.ZvI("mat-mdc-select-panel mdc-menu-surface mdc-menu-surface--open ",Ee._getPanelTheme(),""),a.Y8G("ngClass",Ee.panelClass)("@transformPanel","showing"),a.BMQ("id",Ee.id+"-panel")("aria-multiselectable",Ee.multiple)("aria-label",Ee.ariaLabel||null)("aria-labelledby",Ee._getPanelAriaLabelledby())}}const gn={transformPanelWrap:(0,xe.hZ)("transformPanelWrap",[(0,xe.kY)("* => void",(0,xe.P)("@transformPanel",[(0,xe.MA)()],{optional:!0}))]),transformPanel:(0,xe.hZ)("transformPanel",[(0,xe.wk)("void",(0,xe.iF)({opacity:0,transform:"scale(1, 0.8)"})),(0,xe.kY)("void => showing",(0,xe.i0)("120ms cubic-bezier(0, 0, 0.2, 1)",(0,xe.iF)({opacity:1,transform:"scale(1, 1)"}))),(0,xe.kY)("* => void",(0,xe.i0)("100ms linear",(0,xe.iF)({opacity:0})))])},qe=new a.nKC("mat-select-scroll-strategy",{providedIn:"root",factory:()=>{const $t=(0,a.WQX)(i.hJ);return()=>$t.scrollStrategies.reposition()}}),ze=new a.nKC("MAT_SELECT_CONFIG"),$e={provide:qe,deps:[i.hJ],useFactory:function _t($t){return()=>$t.scrollStrategies.reposition()}},Ft=new a.nKC("MatSelectTrigger");class Ke{source;value;constructor(Te,Ee){this.source=Te,this.value=Ee}}let Ze=(()=>{class $t{_viewportRuler=(0,a.WQX)(w.Xj);_changeDetectorRef=(0,a.WQX)(a.gRc);_elementRef=(0,a.WQX)(a.aKT);_dir=(0,a.WQX)(T.dS,{optional:!0});_idGenerator=(0,a.WQX)(C.g7);_parentFormField=(0,a.WQX)(y.xb,{optional:!0});ngControl=(0,a.WQX)(O.vO,{self:!0,optional:!0});_liveAnnouncer=(0,a.WQX)(C.Ai);_defaultOptions=(0,a.WQX)(ze,{optional:!0});options;optionGroups;customTrigger;_positions=[{originX:"start",originY:"bottom",overlayX:"start",overlayY:"top"},{originX:"end",originY:"bottom",overlayX:"end",overlayY:"top"},{originX:"start",originY:"top",overlayX:"start",overlayY:"bottom",panelClass:"mat-mdc-select-panel-above"},{originX:"end",originY:"top",overlayX:"end",overlayY:"bottom",panelClass:"mat-mdc-select-panel-above"}];_scrollOptionIntoView(Ee){const st=this.options.toArray()[Ee];if(st){const Xt=this.panel.nativeElement,Mt=(0,c.jb)(Ee,this.options,this.optionGroups),Kt=st._getHostElement();Xt.scrollTop=0===Ee&&1===Mt?0:(0,c.TL)(Kt.offsetTop,Kt.offsetHeight,Xt.scrollTop,Xt.offsetHeight)}}_positioningSettled(){this._scrollOptionIntoView(this._keyManager.activeItemIndex||0)}_getChangeEvent(Ee){return new Ke(this,Ee)}_scrollStrategyFactory=(0,a.WQX)(qe);_panelOpen=!1;_compareWith=(Ee,st)=>Ee===st;_uid=this._idGenerator.getId("mat-select-");_triggerAriaLabelledBy=null;_previousControl;_destroy=new L.B;_errorStateTracker;stateChanges=new L.B;disableAutomaticLabeling=!0;userAriaDescribedBy;_selectionModel;_keyManager;_preferredOverlayOrigin;_overlayWidth;_onChange=()=>{};_onTouched=()=>{};_valueId=this._idGenerator.getId("mat-select-value-");_panelDoneAnimatingStream=new L.B;_scrollStrategy;_overlayPanelClass=this._defaultOptions?.overlayPanelClass||"";get focused(){return this._focused||this._panelOpen}_focused=!1;controlType="mat-select";trigger;panel;_overlayDir;panelClass;disabled=!1;disableRipple=!1;tabIndex=0;get hideSingleSelectionIndicator(){return this._hideSingleSelectionIndicator}set hideSingleSelectionIndicator(Ee){this._hideSingleSelectionIndicator=Ee,this._syncParentProperties()}_hideSingleSelectionIndicator=this._defaultOptions?.hideSingleSelectionIndicator??!1;get placeholder(){return this._placeholder}set placeholder(Ee){this._placeholder=Ee,this.stateChanges.next()}_placeholder;get required(){return this._required??this.ngControl?.control?.hasValidator(O.k0.required)??!1}set required(Ee){this._required=Ee,this.stateChanges.next()}_required;get multiple(){return this._multiple}set multiple(Ee){this._multiple=Ee}_multiple=!1;disableOptionCentering=this._defaultOptions?.disableOptionCentering??!1;get compareWith(){return this._compareWith}set compareWith(Ee){this._compareWith=Ee,this._selectionModel&&this._initializeSelection()}get value(){return this._value}set value(Ee){this._assignValue(Ee)&&this._onChange(Ee)}_value;ariaLabel="";ariaLabelledby;get errorStateMatcher(){return this._errorStateTracker.matcher}set errorStateMatcher(Ee){this._errorStateTracker.matcher=Ee}typeaheadDebounceInterval;sortComparator;get id(){return this._id}set id(Ee){this._id=Ee||this._uid,this.stateChanges.next()}_id;get errorState(){return this._errorStateTracker.errorState}set errorState(Ee){this._errorStateTracker.errorState=Ee}panelWidth=this._defaultOptions&&typeof this._defaultOptions.panelWidth<"u"?this._defaultOptions.panelWidth:"auto";_initialized=new L.B;optionSelectionChanges=(0,Z.v)(()=>{const Ee=this.options;return Ee?Ee.changes.pipe((0,re.Z)(Ee),(0,pe.n)(()=>(0,q.h)(...Ee.map(st=>st.onSelectionChange)))):this._initialized.pipe((0,pe.n)(()=>this.optionSelectionChanges))});openedChange=new a.bkB;_openedStream=this.openedChange.pipe((0,se.p)(Ee=>Ee),(0,ae.T)(()=>{}));_closedStream=this.openedChange.pipe((0,se.p)(Ee=>!Ee),(0,ae.T)(()=>{}));selectionChange=new a.bkB;valueChange=new a.bkB;constructor(){const Ee=(0,a.WQX)(c.es),st=(0,a.WQX)(O.cV,{optional:!0}),Xt=(0,a.WQX)(O.j4,{optional:!0}),Mt=(0,a.WQX)(new a.ES_("tabindex"),{optional:!0});this.ngControl&&(this.ngControl.valueAccessor=this),null!=this._defaultOptions?.typeaheadDebounceInterval&&(this.typeaheadDebounceInterval=this._defaultOptions.typeaheadDebounceInterval),this._errorStateTracker=new c.X0(Ee,this.ngControl,Xt,st,this.stateChanges),this._scrollStrategy=this._scrollStrategyFactory(),this.tabIndex=null==Mt?0:parseInt(Mt)||0,this.id=this.id}ngOnInit(){this._selectionModel=new S.CB(this.multiple),this.stateChanges.next(),this._panelDoneAnimatingStream.pipe((0,me.F)(),(0,be.Q)(this._destroy)).subscribe(()=>this._panelDoneAnimating(this.panelOpen)),this._viewportRuler.change().pipe((0,be.Q)(this._destroy)).subscribe(()=>{this.panelOpen&&(this._overlayWidth=this._getOverlayWidth(this._preferredOverlayOrigin),this._changeDetectorRef.detectChanges())})}ngAfterContentInit(){this._initialized.next(),this._initialized.complete(),this._initKeyManager(),this._selectionModel.changed.pipe((0,be.Q)(this._destroy)).subscribe(Ee=>{Ee.added.forEach(st=>st.select()),Ee.removed.forEach(st=>st.deselect())}),this.options.changes.pipe((0,re.Z)(null),(0,be.Q)(this._destroy)).subscribe(()=>{this._resetOptions(),this._initializeSelection()})}ngDoCheck(){const Ee=this._getTriggerAriaLabelledby(),st=this.ngControl;if(Ee!==this._triggerAriaLabelledBy){const Xt=this._elementRef.nativeElement;this._triggerAriaLabelledBy=Ee,Ee?Xt.setAttribute("aria-labelledby",Ee):Xt.removeAttribute("aria-labelledby")}st&&(this._previousControl!==st.control&&(void 0!==this._previousControl&&null!==st.disabled&&st.disabled!==this.disabled&&(this.disabled=st.disabled),this._previousControl=st.control),this.updateErrorState())}ngOnChanges(Ee){(Ee.disabled||Ee.userAriaDescribedBy)&&this.stateChanges.next(),Ee.typeaheadDebounceInterval&&this._keyManager&&this._keyManager.withTypeAhead(this.typeaheadDebounceInterval)}ngOnDestroy(){this._keyManager?.destroy(),this._destroy.next(),this._destroy.complete(),this.stateChanges.complete(),this._clearFromModal()}toggle(){this.panelOpen?this.close():this.open()}open(){this._canOpen()&&(this._parentFormField&&(this._preferredOverlayOrigin=this._parentFormField.getConnectedOverlayOrigin()),this._overlayWidth=this._getOverlayWidth(this._preferredOverlayOrigin),this._applyModalPanelOwnership(),this._panelOpen=!0,this._keyManager.withHorizontalOrientation(null),this._highlightCorrectOption(),this._changeDetectorRef.markForCheck(),this.stateChanges.next())}_trackedModal=null;_applyModalPanelOwnership(){const Ee=this._elementRef.nativeElement.closest('body > .cdk-overlay-container [aria-modal="true"]');if(!Ee)return;const st=`${this.id}-panel`;this._trackedModal&&(0,C.Ae)(this._trackedModal,"aria-owns",st),(0,C.px)(Ee,"aria-owns",st),this._trackedModal=Ee}_clearFromModal(){this._trackedModal&&((0,C.Ae)(this._trackedModal,"aria-owns",`${this.id}-panel`),this._trackedModal=null)}close(){this._panelOpen&&(this._panelOpen=!1,this._keyManager.withHorizontalOrientation(this._isRtl()?"rtl":"ltr"),this._changeDetectorRef.markForCheck(),this._onTouched(),this.stateChanges.next())}writeValue(Ee){this._assignValue(Ee)}registerOnChange(Ee){this._onChange=Ee}registerOnTouched(Ee){this._onTouched=Ee}setDisabledState(Ee){this.disabled=Ee,this._changeDetectorRef.markForCheck(),this.stateChanges.next()}get panelOpen(){return this._panelOpen}get selected(){return this.multiple?this._selectionModel?.selected||[]:this._selectionModel?.selected[0]}get triggerValue(){if(this.empty)return"";if(this._multiple){const Ee=this._selectionModel.selected.map(st=>st.viewValue);return this._isRtl()&&Ee.reverse(),Ee.join(", ")}return this._selectionModel.selected[0].viewValue}updateErrorState(){this._errorStateTracker.updateErrorState()}_isRtl(){return!!this._dir&&"rtl"===this._dir.value}_handleKeydown(Ee){this.disabled||(this.panelOpen?this._handleOpenKeydown(Ee):this._handleClosedKeydown(Ee))}_handleClosedKeydown(Ee){const st=Ee.keyCode,Xt=st===M.n6||st===M.i7||st===M.UQ||st===M.LE,Mt=st===M.Fm||st===M.t6,Kt=this._keyManager;if(!Kt.isTyping()&&Mt&&!(0,M.rp)(Ee)||(this.multiple||Ee.altKey)&&Xt)Ee.preventDefault(),this.open();else if(!this.multiple){const rt=this.selected;Kt.onKeydown(Ee);const Vt=this.selected;Vt&&rt!==Vt&&this._liveAnnouncer.announce(Vt.viewValue,1e4)}}_handleOpenKeydown(Ee){const st=this._keyManager,Xt=Ee.keyCode,Mt=Xt===M.n6||Xt===M.i7,Kt=st.isTyping();if(Mt&&Ee.altKey)Ee.preventDefault(),this.close();else if(Kt||Xt!==M.Fm&&Xt!==M.t6||!st.activeItem||(0,M.rp)(Ee))if(!Kt&&this._multiple&&Xt===M.A&&Ee.ctrlKey){Ee.preventDefault();const rt=this.options.some(Vt=>!Vt.disabled&&!Vt.selected);this.options.forEach(Vt=>{Vt.disabled||(rt?Vt.select():Vt.deselect())})}else{const rt=st.activeItemIndex;st.onKeydown(Ee),this._multiple&&Mt&&Ee.shiftKey&&st.activeItem&&st.activeItemIndex!==rt&&st.activeItem._selectViaInteraction()}else Ee.preventDefault(),st.activeItem._selectViaInteraction()}_onFocus(){this.disabled||(this._focused=!0,this.stateChanges.next())}_onBlur(){this._focused=!1,this._keyManager?.cancelTypeahead(),!this.disabled&&!this.panelOpen&&(this._onTouched(),this._changeDetectorRef.markForCheck(),this.stateChanges.next())}_onAttached(){this._overlayDir.positionChange.pipe((0,Oe.s)(1)).subscribe(()=>{this._changeDetectorRef.detectChanges(),this._positioningSettled()})}_getPanelTheme(){return this._parentFormField?`mat-${this._parentFormField.color}`:""}get empty(){return!this._selectionModel||this._selectionModel.isEmpty()}_initializeSelection(){Promise.resolve().then(()=>{this.ngControl&&(this._value=this.ngControl.value),this._setSelectionByValue(this._value),this.stateChanges.next()})}_setSelectionByValue(Ee){if(this.options.forEach(st=>st.setInactiveStyles()),this._selectionModel.clear(),this.multiple&&Ee)Array.isArray(Ee),Ee.forEach(st=>this._selectOptionByValue(st)),this._sortValues();else{const st=this._selectOptionByValue(Ee);st?this._keyManager.updateActiveItem(st):this.panelOpen||this._keyManager.updateActiveItem(-1)}this._changeDetectorRef.markForCheck()}_selectOptionByValue(Ee){const st=this.options.find(Xt=>{if(this._selectionModel.isSelected(Xt))return!1;try{return null!=Xt.value&&this._compareWith(Xt.value,Ee)}catch{return!1}});return st&&this._selectionModel.select(st),st}_assignValue(Ee){return!!(Ee!==this._value||this._multiple&&Array.isArray(Ee))&&(this.options&&this._setSelectionByValue(Ee),this._value=Ee,!0)}_skipPredicate=Ee=>!this.panelOpen&&Ee.disabled;_getOverlayWidth(Ee){return"auto"===this.panelWidth?(Ee instanceof i.$Q?Ee.elementRef:Ee||this._elementRef).nativeElement.getBoundingClientRect().width:null===this.panelWidth?"":this.panelWidth}_syncParentProperties(){if(this.options)for(const Ee of this.options)Ee._changeDetectorRef.markForCheck()}_initKeyManager(){this._keyManager=new C.Au(this.options).withTypeAhead(this.typeaheadDebounceInterval).withVerticalOrientation().withHorizontalOrientation(this._isRtl()?"rtl":"ltr").withHomeAndEnd().withPageUpDown().withAllowedModifierKeys(["shiftKey"]).skipPredicate(this._skipPredicate),this._keyManager.tabOut.subscribe(()=>{this.panelOpen&&(!this.multiple&&this._keyManager.activeItem&&this._keyManager.activeItem._selectViaInteraction(),this.focus(),this.close())}),this._keyManager.change.subscribe(()=>{this._panelOpen&&this.panel?this._scrollOptionIntoView(this._keyManager.activeItemIndex||0):!this._panelOpen&&!this.multiple&&this._keyManager.activeItem&&this._keyManager.activeItem._selectViaInteraction()})}_resetOptions(){const Ee=(0,q.h)(this.options.changes,this._destroy);this.optionSelectionChanges.pipe((0,be.Q)(Ee)).subscribe(st=>{this._onSelect(st.source,st.isUserInput),st.isUserInput&&!this.multiple&&this._panelOpen&&(this.close(),this.focus())}),(0,q.h)(...this.options.map(st=>st._stateChanges)).pipe((0,be.Q)(Ee)).subscribe(()=>{this._changeDetectorRef.detectChanges(),this.stateChanges.next()})}_onSelect(Ee,st){const Xt=this._selectionModel.isSelected(Ee);null!=Ee.value||this._multiple?(Xt!==Ee.selected&&(Ee.selected?this._selectionModel.select(Ee):this._selectionModel.deselect(Ee)),st&&this._keyManager.setActiveItem(Ee),this.multiple&&(this._sortValues(),st&&this.focus())):(Ee.deselect(),this._selectionModel.clear(),null!=this.value&&this._propagateChanges(Ee.value)),Xt!==this._selectionModel.isSelected(Ee)&&this._propagateChanges(),this.stateChanges.next()}_sortValues(){if(this.multiple){const Ee=this.options.toArray();this._selectionModel.sort((st,Xt)=>this.sortComparator?this.sortComparator(st,Xt,Ee):Ee.indexOf(st)-Ee.indexOf(Xt)),this.stateChanges.next()}}_propagateChanges(Ee){let st;st=this.multiple?this.selected.map(Xt=>Xt.value):this.selected?this.selected.value:Ee,this._value=st,this.valueChange.emit(st),this._onChange(st),this.selectionChange.emit(this._getChangeEvent(st)),this._changeDetectorRef.markForCheck()}_highlightCorrectOption(){if(this._keyManager)if(this.empty){let Ee=-1;for(let st=0;st0}focus(Ee){this._elementRef.nativeElement.focus(Ee)}_getPanelAriaLabelledby(){if(this.ariaLabel)return null;const Ee=this._parentFormField?.getLabelId()||null;return this.ariaLabelledby?(Ee?Ee+" ":"")+this.ariaLabelledby:Ee}_getAriaActiveDescendant(){return this.panelOpen&&this._keyManager&&this._keyManager.activeItem?this._keyManager.activeItem.id:null}_getTriggerAriaLabelledby(){if(this.ariaLabel)return null;const Ee=this._parentFormField?.getLabelId();let st=(Ee?Ee+" ":"")+this._valueId;return this.ariaLabelledby&&(st+=" "+this.ariaLabelledby),st}_panelDoneAnimating(Ee){this.openedChange.emit(Ee)}setDescribedByIds(Ee){Ee.length?this._elementRef.nativeElement.setAttribute("aria-describedby",Ee.join(" ")):this._elementRef.nativeElement.removeAttribute("aria-describedby")}onContainerClick(){this.focus(),this.open()}get shouldLabelFloat(){return this.panelOpen||!this.empty||this.focused&&!!this.placeholder}static \u0275fac=function(st){return new(st||$t)};static \u0275cmp=a.VBU({type:$t,selectors:[["mat-select"]],contentQueries:function(st,Xt,Mt){if(1&st&&(a.wni(Mt,Ft,5),a.wni(Mt,c.wT,5),a.wni(Mt,c.QC,5)),2&st){let Kt;a.mGM(Kt=a.lsd())&&(Xt.customTrigger=Kt.first),a.mGM(Kt=a.lsd())&&(Xt.options=Kt),a.mGM(Kt=a.lsd())&&(Xt.optionGroups=Kt)}},viewQuery:function(st,Xt){if(1&st&&(a.GBs(ce,5),a.GBs(ue,5),a.GBs(i.WB,5)),2&st){let Mt;a.mGM(Mt=a.lsd())&&(Xt.trigger=Mt.first),a.mGM(Mt=a.lsd())&&(Xt.panel=Mt.first),a.mGM(Mt=a.lsd())&&(Xt._overlayDir=Mt.first)}},hostAttrs:["role","combobox","aria-haspopup","listbox",1,"mat-mdc-select"],hostVars:19,hostBindings:function(st,Xt){1&st&&a.bIt("keydown",function(Kt){return Xt._handleKeydown(Kt)})("focus",function(){return Xt._onFocus()})("blur",function(){return Xt._onBlur()}),2&st&&(a.BMQ("id",Xt.id)("tabindex",Xt.disabled?-1:Xt.tabIndex)("aria-controls",Xt.panelOpen?Xt.id+"-panel":null)("aria-expanded",Xt.panelOpen)("aria-label",Xt.ariaLabel||null)("aria-required",Xt.required.toString())("aria-disabled",Xt.disabled.toString())("aria-invalid",Xt.errorState)("aria-activedescendant",Xt._getAriaActiveDescendant()),a.AVh("mat-mdc-select-disabled",Xt.disabled)("mat-mdc-select-invalid",Xt.errorState)("mat-mdc-select-required",Xt.required)("mat-mdc-select-empty",Xt.empty)("mat-mdc-select-multiple",Xt.multiple))},inputs:{userAriaDescribedBy:[0,"aria-describedby","userAriaDescribedBy"],panelClass:"panelClass",disabled:[2,"disabled","disabled",a.L39],disableRipple:[2,"disableRipple","disableRipple",a.L39],tabIndex:[2,"tabIndex","tabIndex",Ee=>null==Ee?0:(0,a.Udg)(Ee)],hideSingleSelectionIndicator:[2,"hideSingleSelectionIndicator","hideSingleSelectionIndicator",a.L39],placeholder:"placeholder",required:[2,"required","required",a.L39],multiple:[2,"multiple","multiple",a.L39],disableOptionCentering:[2,"disableOptionCentering","disableOptionCentering",a.L39],compareWith:"compareWith",value:"value",ariaLabel:[0,"aria-label","ariaLabel"],ariaLabelledby:[0,"aria-labelledby","ariaLabelledby"],errorStateMatcher:"errorStateMatcher",typeaheadDebounceInterval:[2,"typeaheadDebounceInterval","typeaheadDebounceInterval",a.Udg],sortComparator:"sortComparator",id:"id",panelWidth:"panelWidth"},outputs:{openedChange:"openedChange",_openedStream:"opened",_closedStream:"closed",selectionChange:"selectionChange",valueChange:"valueChange"},exportAs:["matSelect"],features:[a.Jv_([{provide:y.qT,useExisting:$t},{provide:c.is,useExisting:$t}]),a.GFd,a.OA$],ngContentSelectors:Be,decls:11,vars:8,consts:[["fallbackOverlayOrigin","cdkOverlayOrigin","trigger",""],["panel",""],["cdk-overlay-origin","",1,"mat-mdc-select-trigger",3,"click"],[1,"mat-mdc-select-value"],[1,"mat-mdc-select-placeholder","mat-mdc-select-min-line"],[1,"mat-mdc-select-value-text"],[1,"mat-mdc-select-arrow-wrapper"],[1,"mat-mdc-select-arrow"],["viewBox","0 0 24 24","width","24px","height","24px","focusable","false","aria-hidden","true"],["d","M7 10l5 5 5-5z"],["cdk-connected-overlay","","cdkConnectedOverlayLockPosition","","cdkConnectedOverlayHasBackdrop","","cdkConnectedOverlayBackdropClass","cdk-overlay-transparent-backdrop",3,"backdropClick","attach","detach","cdkConnectedOverlayPanelClass","cdkConnectedOverlayScrollStrategy","cdkConnectedOverlayOrigin","cdkConnectedOverlayOpen","cdkConnectedOverlayPositions","cdkConnectedOverlayWidth"],[1,"mat-mdc-select-min-line"],["role","listbox","tabindex","-1",3,"keydown","ngClass"]],template:function(st,Xt){if(1&st){const Mt=a.RV6();a.NAR(Ce),a.j41(0,"div",2,0),a.bIt("click",function(){return a.eBV(Mt),a.Njj(Xt.open())}),a.j41(3,"div",3),a.DNE(4,at,2,1,"span",4)(5,lt,3,1,"span",5),a.k0s(),a.j41(6,"div",6)(7,"div",7),a.qSk(),a.j41(8,"svg",8),a.nrm(9,"path",9),a.k0s()()()(),a.DNE(10,rn,3,9,"ng-template",10),a.bIt("backdropClick",function(){return a.eBV(Mt),a.Njj(Xt.close())})("attach",function(){return a.eBV(Mt),a.Njj(Xt._onAttached())})("detach",function(){return a.eBV(Mt),a.Njj(Xt.close())})}if(2&st){const Mt=a.sdS(1);a.R7$(3),a.BMQ("id",Xt._valueId),a.R7$(),a.vxM(Xt.empty?4:5),a.R7$(6),a.Y8G("cdkConnectedOverlayPanelClass",Xt._overlayPanelClass)("cdkConnectedOverlayScrollStrategy",Xt._scrollStrategy)("cdkConnectedOverlayOrigin",Xt._preferredOverlayOrigin||Mt)("cdkConnectedOverlayOpen",Xt.panelOpen)("cdkConnectedOverlayPositions",Xt._positions)("cdkConnectedOverlayWidth",Xt._overlayWidth)}},dependencies:[i.$Q,i.WB,De.YU],styles:['.mat-mdc-select{display:inline-block;width:100%;outline:none;-moz-osx-font-smoothing:grayscale;-webkit-font-smoothing:antialiased;color:var(--mat-select-enabled-trigger-text-color, var(--mat-sys-on-surface));font-family:var(--mat-select-trigger-text-font, var(--mat-sys-body-large-font));line-height:var(--mat-select-trigger-text-line-height, var(--mat-sys-body-large-line-height));font-size:var(--mat-select-trigger-text-size, var(--mat-sys-body-large-size));font-weight:var(--mat-select-trigger-text-weight, var(--mat-sys-body-large-weight));letter-spacing:var(--mat-select-trigger-text-tracking, var(--mat-sys-body-large-tracking))}div.mat-mdc-select-panel{box-shadow:var(--mat-select-container-elevation-shadow, 0px 3px 1px -2px rgba(0, 0, 0, 0.2), 0px 2px 2px 0px rgba(0, 0, 0, 0.14), 0px 1px 5px 0px rgba(0, 0, 0, 0.12))}.mat-mdc-select-disabled{color:var(--mat-select-disabled-trigger-text-color, color-mix(in srgb, var(--mat-sys-on-surface) 38%, transparent))}.mat-mdc-select-trigger{display:inline-flex;align-items:center;cursor:pointer;position:relative;box-sizing:border-box;width:100%}.mat-mdc-select-disabled .mat-mdc-select-trigger{-webkit-user-select:none;user-select:none;cursor:default}.mat-mdc-select-value{width:100%;overflow:hidden;text-overflow:ellipsis;white-space:nowrap}.mat-mdc-select-value-text{white-space:nowrap;overflow:hidden;text-overflow:ellipsis}.mat-mdc-select-arrow-wrapper{height:24px;flex-shrink:0;display:inline-flex;align-items:center}.mat-form-field-appearance-fill .mdc-text-field--no-label .mat-mdc-select-arrow-wrapper{transform:none}.mat-mdc-form-field .mat-mdc-select.mat-mdc-select-invalid .mat-mdc-select-arrow,.mat-form-field-invalid:not(.mat-form-field-disabled) .mat-mdc-form-field-infix::after{color:var(--mat-select-invalid-arrow-color, var(--mat-sys-error))}.mat-mdc-select-arrow{width:10px;height:5px;position:relative;color:var(--mat-select-enabled-arrow-color, var(--mat-sys-on-surface-variant))}.mat-mdc-form-field.mat-focused .mat-mdc-select-arrow{color:var(--mat-select-focused-arrow-color, var(--mat-sys-primary))}.mat-mdc-form-field .mat-mdc-select.mat-mdc-select-disabled .mat-mdc-select-arrow{color:var(--mat-select-disabled-arrow-color, color-mix(in srgb, var(--mat-sys-on-surface) 38%, transparent))}.mat-mdc-select-arrow svg{fill:currentColor;position:absolute;top:50%;left:50%;transform:translate(-50%, -50%)}@media(forced-colors: active){.mat-mdc-select-arrow svg{fill:CanvasText}.mat-mdc-select-disabled .mat-mdc-select-arrow svg{fill:GrayText}}div.mat-mdc-select-panel{width:100%;max-height:275px;outline:0;overflow:auto;padding:8px 0;border-radius:4px;box-sizing:border-box;position:static;background-color:var(--mat-select-panel-background-color, var(--mat-sys-surface-container))}@media(forced-colors: active){div.mat-mdc-select-panel{outline:solid 1px}}.cdk-overlay-pane:not(.mat-mdc-select-panel-above) div.mat-mdc-select-panel{border-top-left-radius:0;border-top-right-radius:0;transform-origin:top center}.mat-mdc-select-panel-above div.mat-mdc-select-panel{border-bottom-left-radius:0;border-bottom-right-radius:0;transform-origin:bottom center}div.mat-mdc-select-panel .mat-mdc-option{--mdc-list-list-item-container-color: var(--mat-select-panel-background-color)}.mat-mdc-select-placeholder{transition:color 400ms 133.3333333333ms cubic-bezier(0.25, 0.8, 0.25, 1);color:var(--mat-select-placeholder-text-color, var(--mat-sys-on-surface-variant))}._mat-animation-noopable .mat-mdc-select-placeholder{transition:none}.mat-form-field-hide-placeholder .mat-mdc-select-placeholder{color:rgba(0,0,0,0);-webkit-text-fill-color:rgba(0,0,0,0);transition:none;display:block}.mat-mdc-form-field-type-mat-select:not(.mat-form-field-disabled) .mat-mdc-text-field-wrapper{cursor:pointer}.mat-mdc-form-field-type-mat-select.mat-form-field-appearance-fill .mat-mdc-floating-label{max-width:calc(100% - 18px)}.mat-mdc-form-field-type-mat-select.mat-form-field-appearance-fill .mdc-floating-label--float-above{max-width:calc(100%/0.75 - 24px)}.mat-mdc-form-field-type-mat-select.mat-form-field-appearance-outline .mdc-notched-outline__notch{max-width:calc(100% - 60px)}.mat-mdc-form-field-type-mat-select.mat-form-field-appearance-outline .mdc-text-field--label-floating .mdc-notched-outline__notch{max-width:calc(100% - 24px)}.mat-mdc-select-min-line:empty::before{content:" ";white-space:pre;width:1px;display:inline-block;visibility:hidden}.mat-form-field-appearance-fill .mat-mdc-select-arrow-wrapper{transform:var(--mat-select-arrow-transform, translateY(-8px))}'],encapsulation:2,data:{animation:[gn.transformPanel]},changeDetection:0})}return $t})(),it=(()=>{class $t{static \u0275fac=function(st){return new(st||$t)};static \u0275dir=a.FsC({type:$t,selectors:[["mat-select-trigger"]],features:[a.Jv_([{provide:Ft,useExisting:$t}])]})}return $t})(),Ot=(()=>{class $t{static \u0275fac=function(st){return new(st||$t)};static \u0275mod=a.$C({type:$t});static \u0275inj=a.G2t({providers:[$e],imports:[i.z_,c.Sy,c.yE,w.Gj,y.RG,c.Sy,c.yE]})}return $t})()},5785:(o,s,r)=>{"use strict";r.d(s,{$C:()=>$e,$l:()=>_t,qe:()=>ze,vg:()=>it});var i=r(8108),a=r(3107),c=r(2902),y=r(8559),w=r(2944),C=r(3022),T=r(5919),S=r(2147),M=r(4460),O=r(8447),L=r(909),Z=r(7509),q=r(1483),re=r(7947),pe=r(6590),se=r(5424),ae=r(7610),me=r(593),be=r(8627),Oe=r(1204);const xe=["*"],De=["content"],ce=[[["mat-drawer"]],[["mat-drawer-content"]],"*"],ue=["mat-drawer","mat-drawer-content","*"];function Ce(Ot,$t){if(1&Ot){const Te=a.RV6();a.j41(0,"div",1),a.bIt("click",function(){a.eBV(Te);const st=a.XpG();return a.Njj(st._onBackdropClicked())}),a.k0s()}if(2&Ot){const Te=a.XpG();a.AVh("mat-drawer-shown",Te._isShowingBackdrop())}}function Be(Ot,$t){1&Ot&&(a.j41(0,"mat-drawer-content"),a.SdG(1,2),a.k0s())}const gn={transformDrawer:(0,Oe.hZ)("transform",[(0,Oe.wk)("open, open-instant",(0,Oe.iF)({transform:"none",visibility:"visible"})),(0,Oe.wk)("void",(0,Oe.iF)({"box-shadow":"none",visibility:"hidden"})),(0,Oe.kY)("void => open-instant",(0,Oe.i0)("0ms")),(0,Oe.kY)("void <=> open, open-instant => void",(0,Oe.i0)("400ms cubic-bezier(0.25, 0.8, 0.25, 1)"))])},Vn=new a.nKC("MAT_DRAWER_DEFAULT_AUTOSIZE",{providedIn:"root",factory:function qe(){return!1}}),yn=new a.nKC("MAT_DRAWER_CONTAINER");let _t=(()=>{class Ot extends i.uv{_platform=(0,a.WQX)(S.OD);_changeDetectorRef=(0,a.WQX)(a.gRc);_container=(0,a.WQX)($e);constructor(){super((0,a.WQX)(a.aKT),(0,a.WQX)(i.R),(0,a.WQX)(a.SKi))}ngAfterContentInit(){this._container._contentMarginChanges.subscribe(()=>{this._changeDetectorRef.markForCheck()})}_shouldBeHidden(){if(this._platform.isBrowser)return!1;const{start:Te,end:Ee}=this._container;return null!=Te&&"over"!==Te.mode&&Te.opened||null!=Ee&&"over"!==Ee.mode&&Ee.opened}static \u0275fac=function(Ee){return new(Ee||Ot)};static \u0275cmp=a.VBU({type:Ot,selectors:[["mat-drawer-content"]],hostAttrs:[1,"mat-drawer-content"],hostVars:6,hostBindings:function(Ee,st){2&Ee&&(a.xc7("margin-left",st._container._contentMargins.left,"px")("margin-right",st._container._contentMargins.right,"px"),a.AVh("mat-drawer-content-hidden",st._shouldBeHidden()))},features:[a.Jv_([{provide:i.uv,useExisting:Ot}]),a.Vt3],ngContentSelectors:xe,decls:1,vars:0,template:function(Ee,st){1&Ee&&(a.NAR(),a.SdG(0))},encapsulation:2,changeDetection:0})}return Ot})(),ze=(()=>{class Ot{_elementRef=(0,a.WQX)(a.aKT);_focusTrapFactory=(0,a.WQX)(y.GX);_focusMonitor=(0,a.WQX)(y.FN);_platform=(0,a.WQX)(S.OD);_ngZone=(0,a.WQX)(a.SKi);_interactivityChecker=(0,a.WQX)(y.Z7);_doc=(0,a.WQX)(M.qQ,{optional:!0});_container=(0,a.WQX)(yn,{optional:!0});_focusTrap=null;_elementFocusedBeforeDrawerWasOpened=null;_enableAnimations=!1;_isAttached;_anchor;get position(){return this._position}set position(Te){(Te="end"===Te?"end":"start")!==this._position&&(this._isAttached&&this._updatePositionInParent(Te),this._position=Te,this.onPositionChanged.emit())}_position="start";get mode(){return this._mode}set mode(Te){this._mode=Te,this._updateFocusTrapState(),this._modeChanged.next()}_mode="over";get disableClose(){return this._disableClose}set disableClose(Te){this._disableClose=(0,C.he)(Te)}_disableClose=!1;get autoFocus(){return this._autoFocus??("side"===this.mode?"dialog":"first-tabbable")}set autoFocus(Te){("true"===Te||"false"===Te||null==Te)&&(Te=(0,C.he)(Te)),this._autoFocus=Te}_autoFocus;get opened(){return this._opened}set opened(Te){this.toggle((0,C.he)(Te))}_opened=!1;_openedVia;_animationStarted=new O.B;_animationEnd=new O.B;_animationState="void";openedChange=new a.bkB(!0);_openedStream=this.openedChange.pipe((0,q.p)(Te=>Te),(0,re.T)(()=>{}));openedStart=this._animationStarted.pipe((0,q.p)(Te=>Te.fromState!==Te.toState&&0===Te.toState.indexOf("open")),(0,pe.u)(void 0));_closedStream=this.openedChange.pipe((0,q.p)(Te=>!Te),(0,re.T)(()=>{}));closedStart=this._animationStarted.pipe((0,q.p)(Te=>Te.fromState!==Te.toState&&"void"===Te.toState),(0,pe.u)(void 0));_destroyed=new O.B;onPositionChanged=new a.bkB;_content;_modeChanged=new O.B;_injector=(0,a.WQX)(a.zZn);_changeDetectorRef=(0,a.WQX)(a.gRc);constructor(){this.openedChange.pipe((0,se.Q)(this._destroyed)).subscribe(Te=>{Te?(this._doc&&(this._elementFocusedBeforeDrawerWasOpened=this._doc.activeElement),this._takeFocus()):this._isFocusWithinDrawer()&&this._restoreFocus(this._openedVia||"program")}),this._ngZone.runOutsideAngular(()=>{(0,L.R)(this._elementRef.nativeElement,"keydown").pipe((0,q.p)(Te=>Te.keyCode===T._f&&!this.disableClose&&!(0,T.rp)(Te)),(0,se.Q)(this._destroyed)).subscribe(Te=>this._ngZone.run(()=>{this.close(),Te.stopPropagation(),Te.preventDefault()}))}),this._animationEnd.subscribe(Te=>{const{fromState:Ee,toState:st}=Te;(0===st.indexOf("open")&&"void"===Ee||"void"===st&&0===Ee.indexOf("open"))&&this.openedChange.emit(this._opened)})}_forceFocus(Te,Ee){this._interactivityChecker.isFocusable(Te)||(Te.tabIndex=-1,this._ngZone.runOutsideAngular(()=>{const st=()=>{Te.removeEventListener("blur",st),Te.removeEventListener("mousedown",st),Te.removeAttribute("tabindex")};Te.addEventListener("blur",st),Te.addEventListener("mousedown",st)})),Te.focus(Ee)}_focusByCssSelector(Te,Ee){let st=this._elementRef.nativeElement.querySelector(Te);st&&this._forceFocus(st,Ee)}_takeFocus(){if(!this._focusTrap)return;const Te=this._elementRef.nativeElement;switch(this.autoFocus){case!1:case"dialog":return;case!0:case"first-tabbable":(0,a.mal)(()=>{!this._focusTrap.focusInitialElement()&&"function"==typeof Te.focus&&Te.focus()},{injector:this._injector});break;case"first-heading":this._focusByCssSelector('h1, h2, h3, h4, h5, h6, [role="heading"]');break;default:this._focusByCssSelector(this.autoFocus)}}_restoreFocus(Te){"dialog"!==this.autoFocus&&(this._elementFocusedBeforeDrawerWasOpened?this._focusMonitor.focusVia(this._elementFocusedBeforeDrawerWasOpened,Te):this._elementRef.nativeElement.blur(),this._elementFocusedBeforeDrawerWasOpened=null)}_isFocusWithinDrawer(){const Te=this._doc.activeElement;return!!Te&&this._elementRef.nativeElement.contains(Te)}ngAfterViewInit(){this._isAttached=!0,"end"===this._position&&this._updatePositionInParent("end"),this._platform.isBrowser&&(this._focusTrap=this._focusTrapFactory.create(this._elementRef.nativeElement),this._updateFocusTrapState())}ngAfterContentChecked(){this._platform.isBrowser&&(this._enableAnimations=!0)}ngOnDestroy(){this._focusTrap?.destroy(),this._anchor?.remove(),this._anchor=null,this._animationStarted.complete(),this._animationEnd.complete(),this._modeChanged.complete(),this._destroyed.next(),this._destroyed.complete()}open(Te){return this.toggle(!0,Te)}close(){return this.toggle(!1)}_closeViaBackdropClick(){return this._setOpen(!1,!0,"mouse")}toggle(Te=!this.opened,Ee){Te&&Ee&&(this._openedVia=Ee);const st=this._setOpen(Te,!Te&&this._isFocusWithinDrawer(),this._openedVia||"program");return Te||(this._openedVia=null),st}_setOpen(Te,Ee,st){return this._opened=Te,Te?this._animationState=this._enableAnimations?"open":"open-instant":(this._animationState="void",Ee&&this._restoreFocus(st)),this._changeDetectorRef.markForCheck(),this._updateFocusTrapState(),new Promise(Xt=>{this.openedChange.pipe((0,ae.s)(1)).subscribe(Mt=>Xt(Mt?"open":"close"))})}_getWidth(){return this._elementRef.nativeElement&&this._elementRef.nativeElement.offsetWidth||0}_updateFocusTrapState(){this._focusTrap&&(this._focusTrap.enabled=!!this._container?.hasBackdrop&&this.opened)}_updatePositionInParent(Te){if(!this._platform.isBrowser)return;const Ee=this._elementRef.nativeElement,st=Ee.parentNode;"end"===Te?(this._anchor||(this._anchor=this._doc.createComment("mat-drawer-anchor"),st.insertBefore(this._anchor,Ee)),st.appendChild(Ee)):this._anchor&&this._anchor.parentNode.insertBefore(Ee,this._anchor)}static \u0275fac=function(Ee){return new(Ee||Ot)};static \u0275cmp=a.VBU({type:Ot,selectors:[["mat-drawer"]],viewQuery:function(Ee,st){if(1&Ee&&a.GBs(De,5),2&Ee){let Xt;a.mGM(Xt=a.lsd())&&(st._content=Xt.first)}},hostAttrs:["tabIndex","-1",1,"mat-drawer"],hostVars:12,hostBindings:function(Ee,st){1&Ee&&a.Kam("@transform.start",function(Mt){return st._animationStarted.next(Mt)})("@transform.done",function(Mt){return st._animationEnd.next(Mt)}),2&Ee&&(a.zvX("@transform",st._animationState),a.BMQ("align",null),a.AVh("mat-drawer-end","end"===st.position)("mat-drawer-over","over"===st.mode)("mat-drawer-push","push"===st.mode)("mat-drawer-side","side"===st.mode)("mat-drawer-opened",st.opened))},inputs:{position:"position",mode:"mode",disableClose:"disableClose",autoFocus:"autoFocus",opened:"opened"},outputs:{openedChange:"openedChange",_openedStream:"opened",openedStart:"openedStart",_closedStream:"closed",closedStart:"closedStart",onPositionChanged:"positionChanged"},exportAs:["matDrawer"],ngContentSelectors:xe,decls:3,vars:0,consts:[["content",""],["cdkScrollable","",1,"mat-drawer-inner-container"]],template:function(Ee,st){1&Ee&&(a.NAR(),a.j41(0,"div",1,0),a.SdG(2),a.k0s())},dependencies:[i.uv],encapsulation:2,data:{animation:[gn.transformDrawer]},changeDetection:0})}return Ot})(),$e=(()=>{class Ot{_dir=(0,a.WQX)(w.dS,{optional:!0});_element=(0,a.WQX)(a.aKT);_ngZone=(0,a.WQX)(a.SKi);_changeDetectorRef=(0,a.WQX)(a.gRc);_animationMode=(0,a.WQX)(a.bc$,{optional:!0});_allDrawers;_drawers=new a.rOR;_content;_userContent;get start(){return this._start}get end(){return this._end}get autosize(){return this._autosize}set autosize(Te){this._autosize=(0,C.he)(Te)}_autosize=(0,a.WQX)(Vn);get hasBackdrop(){return this._drawerHasBackdrop(this._start)||this._drawerHasBackdrop(this._end)}set hasBackdrop(Te){this._backdropOverride=null==Te?null:(0,C.he)(Te)}_backdropOverride;backdropClick=new a.bkB;_start;_end;_left;_right;_destroyed=new O.B;_doCheckSubject=new O.B;_contentMargins={left:null,right:null};_contentMarginChanges=new O.B;get scrollable(){return this._userContent||this._content}_injector=(0,a.WQX)(a.zZn);constructor(){const Te=(0,a.WQX)(i.Xj);this._dir?.change.pipe((0,se.Q)(this._destroyed)).subscribe(()=>{this._validateDrawers(),this.updateContentMargins()}),Te.change().pipe((0,se.Q)(this._destroyed)).subscribe(()=>this.updateContentMargins())}ngAfterContentInit(){this._allDrawers.changes.pipe((0,me.Z)(this._allDrawers),(0,se.Q)(this._destroyed)).subscribe(Te=>{this._drawers.reset(Te.filter(Ee=>!Ee._container||Ee._container===this)),this._drawers.notifyOnChanges()}),this._drawers.changes.pipe((0,me.Z)(null)).subscribe(()=>{this._validateDrawers(),this._drawers.forEach(Te=>{this._watchDrawerToggle(Te),this._watchDrawerPosition(Te),this._watchDrawerMode(Te)}),(!this._drawers.length||this._isDrawerOpen(this._start)||this._isDrawerOpen(this._end))&&this.updateContentMargins(),this._changeDetectorRef.markForCheck()}),this._ngZone.runOutsideAngular(()=>{this._doCheckSubject.pipe((0,be.B)(10),(0,se.Q)(this._destroyed)).subscribe(()=>this.updateContentMargins())})}ngOnDestroy(){this._contentMarginChanges.complete(),this._doCheckSubject.complete(),this._drawers.destroy(),this._destroyed.next(),this._destroyed.complete()}open(){this._drawers.forEach(Te=>Te.open())}close(){this._drawers.forEach(Te=>Te.close())}updateContentMargins(){let Te=0,Ee=0;if(this._left&&this._left.opened)if("side"==this._left.mode)Te+=this._left._getWidth();else if("push"==this._left.mode){const st=this._left._getWidth();Te+=st,Ee-=st}if(this._right&&this._right.opened)if("side"==this._right.mode)Ee+=this._right._getWidth();else if("push"==this._right.mode){const st=this._right._getWidth();Ee+=st,Te-=st}Te=Te||null,Ee=Ee||null,(Te!==this._contentMargins.left||Ee!==this._contentMargins.right)&&(this._contentMargins={left:Te,right:Ee},this._ngZone.run(()=>this._contentMarginChanges.next(this._contentMargins)))}ngDoCheck(){this._autosize&&this._isPushed()&&this._ngZone.runOutsideAngular(()=>this._doCheckSubject.next())}_watchDrawerToggle(Te){Te._animationStarted.pipe((0,q.p)(Ee=>Ee.fromState!==Ee.toState),(0,se.Q)(this._drawers.changes)).subscribe(Ee=>{"open-instant"!==Ee.toState&&"NoopAnimations"!==this._animationMode&&this._element.nativeElement.classList.add("mat-drawer-transition"),this.updateContentMargins(),this._changeDetectorRef.markForCheck()}),"side"!==Te.mode&&Te.openedChange.pipe((0,se.Q)(this._drawers.changes)).subscribe(()=>this._setContainerClass(Te.opened))}_watchDrawerPosition(Te){Te&&Te.onPositionChanged.pipe((0,se.Q)(this._drawers.changes)).subscribe(()=>{(0,a.mal)(()=>{this._validateDrawers()},{injector:this._injector,phase:a.wjH.Read})})}_watchDrawerMode(Te){Te&&Te._modeChanged.pipe((0,se.Q)((0,Z.h)(this._drawers.changes,this._destroyed))).subscribe(()=>{this.updateContentMargins(),this._changeDetectorRef.markForCheck()})}_setContainerClass(Te){const Ee=this._element.nativeElement.classList,st="mat-drawer-container-has-open";Te?Ee.add(st):Ee.remove(st)}_validateDrawers(){this._start=this._end=null,this._drawers.forEach(Te=>{"end"==Te.position?this._end=Te:this._start=Te}),this._right=this._left=null,this._dir&&"rtl"===this._dir.value?(this._left=this._end,this._right=this._start):(this._left=this._start,this._right=this._end)}_isPushed(){return this._isDrawerOpen(this._start)&&"over"!=this._start.mode||this._isDrawerOpen(this._end)&&"over"!=this._end.mode}_onBackdropClicked(){this.backdropClick.emit(),this._closeModalDrawersViaBackdrop()}_closeModalDrawersViaBackdrop(){[this._start,this._end].filter(Te=>Te&&!Te.disableClose&&this._drawerHasBackdrop(Te)).forEach(Te=>Te._closeViaBackdropClick())}_isShowingBackdrop(){return this._isDrawerOpen(this._start)&&this._drawerHasBackdrop(this._start)||this._isDrawerOpen(this._end)&&this._drawerHasBackdrop(this._end)}_isDrawerOpen(Te){return null!=Te&&Te.opened}_drawerHasBackdrop(Te){return null==this._backdropOverride?!!Te&&"side"!==Te.mode:this._backdropOverride}static \u0275fac=function(Ee){return new(Ee||Ot)};static \u0275cmp=a.VBU({type:Ot,selectors:[["mat-drawer-container"]],contentQueries:function(Ee,st,Xt){if(1&Ee&&(a.wni(Xt,_t,5),a.wni(Xt,ze,5)),2&Ee){let Mt;a.mGM(Mt=a.lsd())&&(st._content=Mt.first),a.mGM(Mt=a.lsd())&&(st._allDrawers=Mt)}},viewQuery:function(Ee,st){if(1&Ee&&a.GBs(_t,5),2&Ee){let Xt;a.mGM(Xt=a.lsd())&&(st._userContent=Xt.first)}},hostAttrs:[1,"mat-drawer-container"],hostVars:2,hostBindings:function(Ee,st){2&Ee&&a.AVh("mat-drawer-container-explicit-backdrop",st._backdropOverride)},inputs:{autosize:"autosize",hasBackdrop:"hasBackdrop"},outputs:{backdropClick:"backdropClick"},exportAs:["matDrawerContainer"],features:[a.Jv_([{provide:yn,useExisting:Ot}])],ngContentSelectors:ue,decls:4,vars:2,consts:[[1,"mat-drawer-backdrop",3,"mat-drawer-shown"],[1,"mat-drawer-backdrop",3,"click"]],template:function(Ee,st){1&Ee&&(a.NAR(ce),a.DNE(0,Ce,1,2,"div",0),a.SdG(1),a.SdG(2,1),a.DNE(3,Be,2,0,"mat-drawer-content")),2&Ee&&(a.vxM(st.hasBackdrop?0:-1),a.R7$(3),a.vxM(st._content?-1:3))},dependencies:[_t],styles:['.mat-drawer-container{position:relative;z-index:1;color:var(--mat-sidenav-content-text-color, var(--mat-sys-on-background));background-color:var(--mat-sidenav-content-background-color, var(--mat-sys-background));box-sizing:border-box;-webkit-overflow-scrolling:touch;display:block;overflow:hidden}.mat-drawer-container[fullscreen]{top:0;left:0;right:0;bottom:0;position:absolute}.mat-drawer-container[fullscreen].mat-drawer-container-has-open{overflow:hidden}.mat-drawer-container.mat-drawer-container-explicit-backdrop .mat-drawer-side{z-index:3}.mat-drawer-container.ng-animate-disabled .mat-drawer-backdrop,.mat-drawer-container.ng-animate-disabled .mat-drawer-content,.ng-animate-disabled .mat-drawer-container .mat-drawer-backdrop,.ng-animate-disabled .mat-drawer-container .mat-drawer-content{transition:none}.mat-drawer-backdrop{top:0;left:0;right:0;bottom:0;position:absolute;display:block;z-index:3;visibility:hidden}.mat-drawer-backdrop.mat-drawer-shown{visibility:visible;background-color:var(--mat-sidenav-scrim-color, color-mix(in srgb, var(--mat-sys-neutral-variant20) 40%, transparent))}.mat-drawer-transition .mat-drawer-backdrop{transition-duration:400ms;transition-timing-function:cubic-bezier(0.25, 0.8, 0.25, 1);transition-property:background-color,visibility}@media(forced-colors: active){.mat-drawer-backdrop{opacity:.5}}.mat-drawer-content{position:relative;z-index:1;display:block;height:100%;overflow:auto}.mat-drawer-content.mat-drawer-content-hidden{opacity:0}.mat-drawer-transition .mat-drawer-content{transition-duration:400ms;transition-timing-function:cubic-bezier(0.25, 0.8, 0.25, 1);transition-property:transform,margin-left,margin-right}.mat-drawer{position:relative;z-index:4;color:var(--mat-sidenav-container-text-color, var(--mat-sys-on-surface-variant));box-shadow:var(--mat-sidenav-container-elevation-shadow, none);background-color:var(--mat-sidenav-container-background-color, var(--mat-sys-surface));border-top-right-radius:var(--mat-sidenav-container-shape, var(--mat-sys-corner-large));border-bottom-right-radius:var(--mat-sidenav-container-shape, var(--mat-sys-corner-large));width:var(--mat-sidenav-container-width, 360px);display:block;position:absolute;top:0;bottom:0;z-index:3;outline:0;box-sizing:border-box;overflow-y:auto;transform:translate3d(-100%, 0, 0)}@media(forced-colors: active){.mat-drawer,[dir=rtl] .mat-drawer.mat-drawer-end{border-right:solid 1px currentColor}}@media(forced-colors: active){[dir=rtl] .mat-drawer,.mat-drawer.mat-drawer-end{border-left:solid 1px currentColor;border-right:none}}.mat-drawer.mat-drawer-side{z-index:2}.mat-drawer.mat-drawer-end{right:0;transform:translate3d(100%, 0, 0);border-top-left-radius:var(--mat-sidenav-container-shape, var(--mat-sys-corner-large));border-bottom-left-radius:var(--mat-sidenav-container-shape, var(--mat-sys-corner-large));border-top-right-radius:0;border-bottom-right-radius:0}[dir=rtl] .mat-drawer{border-top-left-radius:var(--mat-sidenav-container-shape, var(--mat-sys-corner-large));border-bottom-left-radius:var(--mat-sidenav-container-shape, var(--mat-sys-corner-large));border-top-right-radius:0;border-bottom-right-radius:0;transform:translate3d(100%, 0, 0)}[dir=rtl] .mat-drawer.mat-drawer-end{border-top-right-radius:var(--mat-sidenav-container-shape, var(--mat-sys-corner-large));border-bottom-right-radius:var(--mat-sidenav-container-shape, var(--mat-sys-corner-large));border-top-left-radius:0;border-bottom-left-radius:0;left:0;right:auto;transform:translate3d(-100%, 0, 0)}.mat-drawer[style*="visibility: hidden"]{display:none}.mat-drawer-side{box-shadow:none;border-right-color:var(--mat-sidenav-container-divider-color, transparent);border-right-width:1px;border-right-style:solid}.mat-drawer-side.mat-drawer-end{border-left-color:var(--mat-sidenav-container-divider-color, transparent);border-left-width:1px;border-left-style:solid;border-right:none}[dir=rtl] .mat-drawer-side{border-left-color:var(--mat-sidenav-container-divider-color, transparent);border-left-width:1px;border-left-style:solid;border-right:none}[dir=rtl] .mat-drawer-side.mat-drawer-end{border-right-color:var(--mat-sidenav-container-divider-color, transparent);border-right-width:1px;border-right-style:solid;border-left:none}.mat-drawer-inner-container{width:100%;height:100%;overflow:auto;-webkit-overflow-scrolling:touch}.mat-sidenav-fixed{position:fixed}'],encapsulation:2,changeDetection:0})}return Ot})(),it=(()=>{class Ot{static \u0275fac=function(Ee){return new(Ee||Ot)};static \u0275mod=a.$C({type:Ot});static \u0275inj=a.G2t({imports:[c.yE,i.Gj,i.Gj,c.yE]})}return Ot})()},7712:(o,s,r)=>{"use strict";r.d(s,{oV:()=>lt,uc:()=>bn});var i=r(5424),a=r(3022),c=r(5919),y=r(3107),w=r(4460),C=r(2147),T=r(8559),S=r(2944),M=r(9666),O=r(8108),L=r(6192),Z=r(8447),re=(r(1204),r(2902));const pe=["tooltip"],me=new y.nKC("mat-tooltip-scroll-strategy",{providedIn:"root",factory:()=>{const Vn=(0,y.WQX)(M.hJ);return()=>Vn.scrollStrategies.reposition({scrollThrottle:20})}}),Oe={provide:me,deps:[M.hJ],useFactory:function be(Vn){return()=>Vn.scrollStrategies.reposition({scrollThrottle:20})}},De=new y.nKC("mat-tooltip-default-options",{providedIn:"root",factory:function xe(){return{showDelay:0,hideDelay:0,touchendHideDelay:1500}}}),ue="tooltip-panel",Ce=(0,C.BQ)({passive:!0});let lt=(()=>{class Vn{_overlay=(0,y.WQX)(M.hJ);_elementRef=(0,y.WQX)(y.aKT);_scrollDispatcher=(0,y.WQX)(O.R);_viewContainerRef=(0,y.WQX)(y.c1b);_ngZone=(0,y.WQX)(y.SKi);_platform=(0,y.WQX)(C.OD);_ariaDescriber=(0,y.WQX)(T.vr);_focusMonitor=(0,y.WQX)(T.FN);_dir=(0,y.WQX)(S.dS);_injector=(0,y.WQX)(y.zZn);_defaultOptions=(0,y.WQX)(De,{optional:!0});_overlayRef;_tooltipInstance;_portal;_position="below";_positionAtOrigin=!1;_disabled=!1;_tooltipClass;_scrollStrategy=(0,y.WQX)(me);_viewInitialized=!1;_pointerExitEventsInitialized=!1;_tooltipComponent=rn;_viewportMargin=8;_currentPosition;_cssClassPrefix="mat-mdc";_ariaDescriptionPending;get position(){return this._position}set position(qe){qe!==this._position&&(this._position=qe,this._overlayRef&&(this._updatePosition(this._overlayRef),this._tooltipInstance?.show(0),this._overlayRef.updatePosition()))}get positionAtOrigin(){return this._positionAtOrigin}set positionAtOrigin(qe){this._positionAtOrigin=(0,a.he)(qe),this._detach(),this._overlayRef=null}get disabled(){return this._disabled}set disabled(qe){const _t=(0,a.he)(qe);this._disabled!==_t&&(this._disabled=_t,_t?this.hide(0):this._setupPointerEnterEventsIfNeeded(),this._syncAriaDescription(this.message))}get showDelay(){return this._showDelay}set showDelay(qe){this._showDelay=(0,a.OE)(qe)}_showDelay;get hideDelay(){return this._hideDelay}set hideDelay(qe){this._hideDelay=(0,a.OE)(qe),this._tooltipInstance&&(this._tooltipInstance._mouseLeaveHideDelay=this._hideDelay)}_hideDelay;touchGestures="auto";get message(){return this._message}set message(qe){const _t=this._message;this._message=null!=qe?String(qe).trim():"",!this._message&&this._isTooltipVisible()?this.hide(0):(this._setupPointerEnterEventsIfNeeded(),this._updateTooltipMessage()),this._syncAriaDescription(_t)}_message="";get tooltipClass(){return this._tooltipClass}set tooltipClass(qe){this._tooltipClass=qe,this._tooltipInstance&&this._setTooltipClass(this._tooltipClass)}_passiveListeners=[];_document=(0,y.WQX)(w.qQ);_touchstartTimeout=null;_destroyed=new Z.B;constructor(){const qe=this._defaultOptions;qe&&(this._showDelay=qe.showDelay,this._hideDelay=qe.hideDelay,qe.position&&(this.position=qe.position),qe.positionAtOrigin&&(this.positionAtOrigin=qe.positionAtOrigin),qe.touchGestures&&(this.touchGestures=qe.touchGestures),qe.tooltipClass&&(this.tooltipClass=qe.tooltipClass)),this._dir.change.pipe((0,i.Q)(this._destroyed)).subscribe(()=>{this._overlayRef&&this._updatePosition(this._overlayRef)}),this._viewportMargin=8}ngAfterViewInit(){this._viewInitialized=!0,this._setupPointerEnterEventsIfNeeded(),this._focusMonitor.monitor(this._elementRef).pipe((0,i.Q)(this._destroyed)).subscribe(qe=>{qe?"keyboard"===qe&&this._ngZone.run(()=>this.show()):this._ngZone.run(()=>this.hide(0))})}ngOnDestroy(){const qe=this._elementRef.nativeElement;this._touchstartTimeout&&clearTimeout(this._touchstartTimeout),this._overlayRef&&(this._overlayRef.dispose(),this._tooltipInstance=null),this._passiveListeners.forEach(([_t,ze])=>{qe.removeEventListener(_t,ze,Ce)}),this._passiveListeners.length=0,this._destroyed.next(),this._destroyed.complete(),this._ariaDescriber.removeDescription(qe,this.message,"tooltip"),this._focusMonitor.stopMonitoring(qe)}show(qe=this.showDelay,_t){if(this.disabled||!this.message||this._isTooltipVisible())return void this._tooltipInstance?._cancelPendingAnimations();const ze=this._createOverlay(_t);this._detach(),this._portal=this._portal||new L.A8(this._tooltipComponent,this._viewContainerRef);const $e=this._tooltipInstance=ze.attach(this._portal).instance;$e._triggerElement=this._elementRef.nativeElement,$e._mouseLeaveHideDelay=this._hideDelay,$e.afterHidden().pipe((0,i.Q)(this._destroyed)).subscribe(()=>this._detach()),this._setTooltipClass(this._tooltipClass),this._updateTooltipMessage(),$e.show(qe)}hide(qe=this.hideDelay){const _t=this._tooltipInstance;_t&&(_t.isVisible()?_t.hide(qe):(_t._cancelPendingAnimations(),this._detach()))}toggle(qe){this._isTooltipVisible()?this.hide():this.show(void 0,qe)}_isTooltipVisible(){return!!this._tooltipInstance&&this._tooltipInstance.isVisible()}_createOverlay(qe){if(this._overlayRef){const $e=this._overlayRef.getConfig().positionStrategy;if((!this.positionAtOrigin||!qe)&&$e._origin instanceof y.aKT)return this._overlayRef;this._detach()}const _t=this._scrollDispatcher.getAncestorScrollContainers(this._elementRef),ze=this._overlay.position().flexibleConnectedTo(this.positionAtOrigin&&qe||this._elementRef).withTransformOriginOn(`.${this._cssClassPrefix}-tooltip`).withFlexibleDimensions(!1).withViewportMargin(this._viewportMargin).withScrollableContainers(_t);return ze.positionChanges.pipe((0,i.Q)(this._destroyed)).subscribe($e=>{this._updateCurrentPositionClass($e.connectionPair),this._tooltipInstance&&$e.scrollableViewProperties.isOverlayClipped&&this._tooltipInstance.isVisible()&&this._ngZone.run(()=>this.hide(0))}),this._overlayRef=this._overlay.create({direction:this._dir,positionStrategy:ze,panelClass:`${this._cssClassPrefix}-${ue}`,scrollStrategy:this._scrollStrategy()}),this._updatePosition(this._overlayRef),this._overlayRef.detachments().pipe((0,i.Q)(this._destroyed)).subscribe(()=>this._detach()),this._overlayRef.outsidePointerEvents().pipe((0,i.Q)(this._destroyed)).subscribe(()=>this._tooltipInstance?._handleBodyInteraction()),this._overlayRef.keydownEvents().pipe((0,i.Q)(this._destroyed)).subscribe($e=>{this._isTooltipVisible()&&$e.keyCode===c._f&&!(0,c.rp)($e)&&($e.preventDefault(),$e.stopPropagation(),this._ngZone.run(()=>this.hide(0)))}),this._defaultOptions?.disableTooltipInteractivity&&this._overlayRef.addPanelClass(`${this._cssClassPrefix}-tooltip-panel-non-interactive`),this._overlayRef}_detach(){this._overlayRef&&this._overlayRef.hasAttached()&&this._overlayRef.detach(),this._tooltipInstance=null}_updatePosition(qe){const _t=qe.getConfig().positionStrategy,ze=this._getOrigin(),$e=this._getOverlayPosition();_t.withPositions([this._addOffset({...ze.main,...$e.main}),this._addOffset({...ze.fallback,...$e.fallback})])}_addOffset(qe){const ze=!this._dir||"ltr"==this._dir.value;return"top"===qe.originY?qe.offsetY=-8:"bottom"===qe.originY?qe.offsetY=8:"start"===qe.originX?qe.offsetX=ze?-8:8:"end"===qe.originX&&(qe.offsetX=ze?8:-8),qe}_getOrigin(){const qe=!this._dir||"ltr"==this._dir.value,_t=this.position;let ze;"above"==_t||"below"==_t?ze={originX:"center",originY:"above"==_t?"top":"bottom"}:"before"==_t||"left"==_t&&qe||"right"==_t&&!qe?ze={originX:"start",originY:"center"}:("after"==_t||"right"==_t&&qe||"left"==_t&&!qe)&&(ze={originX:"end",originY:"center"});const{x:$e,y:Ft}=this._invertPosition(ze.originX,ze.originY);return{main:ze,fallback:{originX:$e,originY:Ft}}}_getOverlayPosition(){const qe=!this._dir||"ltr"==this._dir.value,_t=this.position;let ze;"above"==_t?ze={overlayX:"center",overlayY:"bottom"}:"below"==_t?ze={overlayX:"center",overlayY:"top"}:"before"==_t||"left"==_t&&qe||"right"==_t&&!qe?ze={overlayX:"end",overlayY:"center"}:("after"==_t||"right"==_t&&qe||"left"==_t&&!qe)&&(ze={overlayX:"start",overlayY:"center"});const{x:$e,y:Ft}=this._invertPosition(ze.overlayX,ze.overlayY);return{main:ze,fallback:{overlayX:$e,overlayY:Ft}}}_updateTooltipMessage(){this._tooltipInstance&&(this._tooltipInstance.message=this.message,this._tooltipInstance._markForCheck(),(0,y.mal)(()=>{this._tooltipInstance&&this._overlayRef.updatePosition()},{injector:this._injector}))}_setTooltipClass(qe){this._tooltipInstance&&(this._tooltipInstance.tooltipClass=qe,this._tooltipInstance._markForCheck())}_invertPosition(qe,_t){return"above"===this.position||"below"===this.position?"top"===_t?_t="bottom":"bottom"===_t&&(_t="top"):"end"===qe?qe="start":"start"===qe&&(qe="end"),{x:qe,y:_t}}_updateCurrentPositionClass(qe){const{overlayY:_t,originX:ze,originY:$e}=qe;let Ft;if(Ft="center"===_t?this._dir&&"rtl"===this._dir.value?"end"===ze?"left":"right":"start"===ze?"left":"right":"bottom"===_t&&"top"===$e?"above":"below",Ft!==this._currentPosition){const Ke=this._overlayRef;if(Ke){const Ze=`${this._cssClassPrefix}-${ue}-`;Ke.removePanelClass(Ze+this._currentPosition),Ke.addPanelClass(Ze+Ft)}this._currentPosition=Ft}}_setupPointerEnterEventsIfNeeded(){this._disabled||!this.message||!this._viewInitialized||this._passiveListeners.length||(this._platformSupportsMouseEvents()?this._passiveListeners.push(["mouseenter",qe=>{let _t;this._setupPointerExitEventsIfNeeded(),void 0!==qe.x&&void 0!==qe.y&&(_t=qe),this.show(void 0,_t)}]):"off"!==this.touchGestures&&(this._disableNativeGesturesIfNecessary(),this._passiveListeners.push(["touchstart",qe=>{const _t=qe.targetTouches?.[0],ze=_t?{x:_t.clientX,y:_t.clientY}:void 0;this._setupPointerExitEventsIfNeeded(),this._touchstartTimeout&&clearTimeout(this._touchstartTimeout),this._touchstartTimeout=setTimeout(()=>{this._touchstartTimeout=null,this.show(void 0,ze)},this._defaultOptions?.touchLongPressShowDelay??500)}])),this._addListeners(this._passiveListeners))}_setupPointerExitEventsIfNeeded(){if(this._pointerExitEventsInitialized)return;this._pointerExitEventsInitialized=!0;const qe=[];if(this._platformSupportsMouseEvents())qe.push(["mouseleave",_t=>{const ze=_t.relatedTarget;(!ze||!this._overlayRef?.overlayElement.contains(ze))&&this.hide()}],["wheel",_t=>this._wheelListener(_t)]);else if("off"!==this.touchGestures){this._disableNativeGesturesIfNecessary();const _t=()=>{this._touchstartTimeout&&clearTimeout(this._touchstartTimeout),this.hide(this._defaultOptions?.touchendHideDelay)};qe.push(["touchend",_t],["touchcancel",_t])}this._addListeners(qe),this._passiveListeners.push(...qe)}_addListeners(qe){qe.forEach(([_t,ze])=>{this._elementRef.nativeElement.addEventListener(_t,ze,Ce)})}_platformSupportsMouseEvents(){return!this._platform.IOS&&!this._platform.ANDROID}_wheelListener(qe){if(this._isTooltipVisible()){const _t=this._document.elementFromPoint(qe.clientX,qe.clientY),ze=this._elementRef.nativeElement;_t!==ze&&!ze.contains(_t)&&this.hide()}}_disableNativeGesturesIfNecessary(){const qe=this.touchGestures;if("off"!==qe){const _t=this._elementRef.nativeElement,ze=_t.style;("on"===qe||"INPUT"!==_t.nodeName&&"TEXTAREA"!==_t.nodeName)&&(ze.userSelect=ze.msUserSelect=ze.webkitUserSelect=ze.MozUserSelect="none"),("on"===qe||!_t.draggable)&&(ze.webkitUserDrag="none"),ze.touchAction="none",ze.webkitTapHighlightColor="transparent"}}_syncAriaDescription(qe){this._ariaDescriptionPending||(this._ariaDescriptionPending=!0,this._ariaDescriber.removeDescription(this._elementRef.nativeElement,qe,"tooltip"),this._ngZone.runOutsideAngular(()=>{Promise.resolve().then(()=>{this._ariaDescriptionPending=!1,this.message&&!this.disabled&&this._ariaDescriber.describe(this._elementRef.nativeElement,this.message,"tooltip")})}))}static \u0275fac=function(_t){return new(_t||Vn)};static \u0275dir=y.FsC({type:Vn,selectors:[["","matTooltip",""]],hostAttrs:[1,"mat-mdc-tooltip-trigger"],hostVars:2,hostBindings:function(_t,ze){2&_t&&y.AVh("mat-mdc-tooltip-disabled",ze.disabled)},inputs:{position:[0,"matTooltipPosition","position"],positionAtOrigin:[0,"matTooltipPositionAtOrigin","positionAtOrigin"],disabled:[0,"matTooltipDisabled","disabled"],showDelay:[0,"matTooltipShowDelay","showDelay"],hideDelay:[0,"matTooltipHideDelay","hideDelay"],touchGestures:[0,"matTooltipTouchGestures","touchGestures"],message:[0,"matTooltip","message"],tooltipClass:[0,"matTooltipClass","tooltipClass"]},exportAs:["matTooltip"]})}return Vn})(),rn=(()=>{class Vn{_changeDetectorRef=(0,y.WQX)(y.gRc);_elementRef=(0,y.WQX)(y.aKT);_isMultiline=!1;message;tooltipClass;_showTimeoutId;_hideTimeoutId;_triggerElement;_mouseLeaveHideDelay;_animationsDisabled;_tooltip;_closeOnInteraction=!1;_isVisible=!1;_onHide=new Z.B;_showAnimation="mat-mdc-tooltip-show";_hideAnimation="mat-mdc-tooltip-hide";constructor(){const qe=(0,y.WQX)(y.bc$,{optional:!0});this._animationsDisabled="NoopAnimations"===qe}show(qe){null!=this._hideTimeoutId&&clearTimeout(this._hideTimeoutId),this._showTimeoutId=setTimeout(()=>{this._toggleVisibility(!0),this._showTimeoutId=void 0},qe)}hide(qe){null!=this._showTimeoutId&&clearTimeout(this._showTimeoutId),this._hideTimeoutId=setTimeout(()=>{this._toggleVisibility(!1),this._hideTimeoutId=void 0},qe)}afterHidden(){return this._onHide}isVisible(){return this._isVisible}ngOnDestroy(){this._cancelPendingAnimations(),this._onHide.complete(),this._triggerElement=null}_handleBodyInteraction(){this._closeOnInteraction&&this.hide(0)}_markForCheck(){this._changeDetectorRef.markForCheck()}_handleMouseLeave({relatedTarget:qe}){(!qe||!this._triggerElement.contains(qe))&&(this.isVisible()?this.hide(this._mouseLeaveHideDelay):this._finalizeAnimation(!1))}_onShow(){this._isMultiline=this._isTooltipMultiline(),this._markForCheck()}_isTooltipMultiline(){const qe=this._elementRef.nativeElement.getBoundingClientRect();return qe.height>24&&qe.width>=200}_handleAnimationEnd({animationName:qe}){(qe===this._showAnimation||qe===this._hideAnimation)&&this._finalizeAnimation(qe===this._showAnimation)}_cancelPendingAnimations(){null!=this._showTimeoutId&&clearTimeout(this._showTimeoutId),null!=this._hideTimeoutId&&clearTimeout(this._hideTimeoutId),this._showTimeoutId=this._hideTimeoutId=void 0}_finalizeAnimation(qe){qe?this._closeOnInteraction=!0:this.isVisible()||this._onHide.next()}_toggleVisibility(qe){const _t=this._tooltip.nativeElement,ze=this._showAnimation,$e=this._hideAnimation;if(_t.classList.remove(qe?$e:ze),_t.classList.add(qe?ze:$e),this._isVisible!==qe&&(this._isVisible=qe,this._changeDetectorRef.markForCheck()),qe&&!this._animationsDisabled&&"function"==typeof getComputedStyle){const Ft=getComputedStyle(_t);("0s"===Ft.getPropertyValue("animation-duration")||"none"===Ft.getPropertyValue("animation-name"))&&(this._animationsDisabled=!0)}qe&&this._onShow(),this._animationsDisabled&&(_t.classList.add("_mat-animation-noopable"),this._finalizeAnimation(qe))}static \u0275fac=function(_t){return new(_t||Vn)};static \u0275cmp=y.VBU({type:Vn,selectors:[["mat-tooltip-component"]],viewQuery:function(_t,ze){if(1&_t&&y.GBs(pe,7),2&_t){let $e;y.mGM($e=y.lsd())&&(ze._tooltip=$e.first)}},hostAttrs:["aria-hidden","true"],hostBindings:function(_t,ze){1&_t&&y.bIt("mouseleave",function(Ft){return ze._handleMouseLeave(Ft)})},decls:4,vars:4,consts:[["tooltip",""],[1,"mdc-tooltip","mat-mdc-tooltip",3,"animationend","ngClass"],[1,"mat-mdc-tooltip-surface","mdc-tooltip__surface"]],template:function(_t,ze){if(1&_t){const $e=y.RV6();y.j41(0,"div",1,0),y.bIt("animationend",function(Ke){return y.eBV($e),y.Njj(ze._handleAnimationEnd(Ke))}),y.j41(2,"div",2),y.EFF(3),y.k0s()()}2&_t&&(y.AVh("mdc-tooltip--multiline",ze._isMultiline),y.Y8G("ngClass",ze.tooltipClass),y.R7$(3),y.JRh(ze.message))},dependencies:[w.YU],styles:['.mat-mdc-tooltip{position:relative;transform:scale(0);display:inline-flex}.mat-mdc-tooltip::before{content:"";top:0;right:0;bottom:0;left:0;z-index:-1;position:absolute}.mat-mdc-tooltip-panel-below .mat-mdc-tooltip::before{top:-8px}.mat-mdc-tooltip-panel-above .mat-mdc-tooltip::before{bottom:-8px}.mat-mdc-tooltip-panel-right .mat-mdc-tooltip::before{left:-8px}.mat-mdc-tooltip-panel-left .mat-mdc-tooltip::before{right:-8px}.mat-mdc-tooltip._mat-animation-noopable{animation:none;transform:scale(1)}.mat-mdc-tooltip-surface{word-break:normal;overflow-wrap:anywhere;padding:4px 8px;min-width:40px;max-width:200px;min-height:24px;max-height:40vh;box-sizing:border-box;overflow:hidden;text-align:center;will-change:transform,opacity;background-color:var(--mdc-plain-tooltip-container-color, var(--mat-sys-inverse-surface));color:var(--mdc-plain-tooltip-supporting-text-color, var(--mat-sys-inverse-on-surface));border-radius:var(--mdc-plain-tooltip-container-shape, var(--mat-sys-corner-extra-small));font-family:var(--mdc-plain-tooltip-supporting-text-font, var(--mat-sys-body-small-font));font-size:var(--mdc-plain-tooltip-supporting-text-size, var(--mat-sys-body-small-size));font-weight:var(--mdc-plain-tooltip-supporting-text-weight, var(--mat-sys-body-small-weight));line-height:var(--mdc-plain-tooltip-supporting-text-line-height, var(--mat-sys-body-small-line-height));letter-spacing:var(--mdc-plain-tooltip-supporting-text-tracking, var(--mat-sys-body-small-tracking))}.mat-mdc-tooltip-surface::before{position:absolute;box-sizing:border-box;width:100%;height:100%;top:0;left:0;border:1px solid rgba(0,0,0,0);border-radius:inherit;content:"";pointer-events:none}.mdc-tooltip--multiline .mat-mdc-tooltip-surface{text-align:left}[dir=rtl] .mdc-tooltip--multiline .mat-mdc-tooltip-surface{text-align:right}.mat-mdc-tooltip-panel.mat-mdc-tooltip-panel-non-interactive{pointer-events:none}@keyframes mat-mdc-tooltip-show{0%{opacity:0;transform:scale(0.8)}100%{opacity:1;transform:scale(1)}}@keyframes mat-mdc-tooltip-hide{0%{opacity:1;transform:scale(1)}100%{opacity:0;transform:scale(0.8)}}.mat-mdc-tooltip-show{animation:mat-mdc-tooltip-show 150ms cubic-bezier(0, 0, 0.2, 1) forwards}.mat-mdc-tooltip-hide{animation:mat-mdc-tooltip-hide 75ms cubic-bezier(0.4, 0, 1, 1) forwards}'],encapsulation:2,changeDetection:0})}return Vn})(),bn=(()=>{class Vn{static \u0275fac=function(_t){return new(_t||Vn)};static \u0275mod=y.$C({type:Vn});static \u0275inj=y.G2t({providers:[Oe],imports:[T.Pd,M.z_,re.yE,re.yE,O.Gj]})}return Vn})()},6388:(o,s,r)=>{"use strict";r.d(s,{B7:()=>bt,B8:()=>Ze,hE:()=>Nr,up:()=>an});var i=r(4460),a=r(3107);class c extends i.VF{supportsDOMEvents=!0}class y extends c{static makeCurrent(){(0,i.ZD)(new y)}onAndCancel(Dt,ct,Bt){return Dt.addEventListener(ct,Bt),()=>{Dt.removeEventListener(ct,Bt)}}dispatchEvent(Dt,ct){Dt.dispatchEvent(ct)}remove(Dt){Dt.remove()}createElement(Dt,ct){return(ct=ct||this.getDefaultDocument()).createElement(Dt)}createHtmlDocument(){return document.implementation.createHTMLDocument("fakeTitle")}getDefaultDocument(){return document}isElementNode(Dt){return Dt.nodeType===Node.ELEMENT_NODE}isShadowRoot(Dt){return Dt instanceof DocumentFragment}getGlobalEventTarget(Dt,ct){return"window"===ct?window:"document"===ct?Dt:"body"===ct?Dt.body:null}getBaseHref(Dt){const ct=function C(){return w=w||document.querySelector("base"),w?w.getAttribute("href"):null}();return null==ct?null:function T(Ve){return new URL(Ve,document.baseURI).pathname}(ct)}resetBaseElement(){w=null}getUserAgent(){return window.navigator.userAgent}getCookie(Dt){return(0,i._b)(document.cookie,Dt)}}let w=null,M=(()=>{class Ve{build(){return new XMLHttpRequest}static \u0275fac=function(Bt){return new(Bt||Ve)};static \u0275prov=a.jDH({token:Ve,factory:Ve.\u0275fac})}return Ve})();const O=new a.nKC("");let L=(()=>{class Ve{_zone;_plugins;_eventNameToPlugin=new Map;constructor(ct,Bt){this._zone=Bt,ct.forEach(wn=>{wn.manager=this}),this._plugins=ct.slice().reverse()}addEventListener(ct,Bt,wn){return this._findPluginFor(Bt).addEventListener(ct,Bt,wn)}getZone(){return this._zone}_findPluginFor(ct){let Bt=this._eventNameToPlugin.get(ct);if(Bt)return Bt;if(Bt=this._plugins.find(qn=>qn.supports(ct)),!Bt)throw new a.wOt(5101,!1);return this._eventNameToPlugin.set(ct,Bt),Bt}static \u0275fac=function(Bt){return new(Bt||Ve)(a.KVO(O),a.KVO(a.SKi))};static \u0275prov=a.jDH({token:Ve,factory:Ve.\u0275fac})}return Ve})();class Z{_doc;constructor(Dt){this._doc=Dt}manager}const q="ng-app-id";function re(Ve){for(const Dt of Ve)Dt.remove()}function pe(Ve,Dt){const ct=Dt.createElement("style");return ct.textContent=Ve,ct}function ae(Ve,Dt){const ct=Dt.createElement("link");return ct.setAttribute("rel","stylesheet"),ct.setAttribute("href",Ve),ct}let me=(()=>{class Ve{doc;appId;nonce;inline=new Map;external=new Map;hosts=new Set;isServer;constructor(ct,Bt,wn,qn={}){this.doc=ct,this.appId=Bt,this.nonce=wn,this.isServer=(0,i.Vy)(qn),function se(Ve,Dt,ct){const Bt=Ve.head?.querySelectorAll(`style[${q}="${Dt}"]`);if(Bt)for(const wn of Bt)wn.textContent&&(wn.removeAttribute(q),ct.set(wn.textContent,{usage:0,elements:[wn]}))}(ct,Bt,this.inline),this.hosts.add(ct.head)}addStyles(ct,Bt){for(const wn of ct)this.addUsage(wn,this.inline,pe);Bt?.forEach(wn=>this.addUsage(wn,this.external,ae))}removeStyles(ct,Bt){for(const wn of ct)this.removeUsage(wn,this.inline);Bt?.forEach(wn=>this.removeUsage(wn,this.external))}addUsage(ct,Bt,wn){const qn=Bt.get(ct);qn?qn.usage++:Bt.set(ct,{usage:1,elements:[...this.hosts].map(Er=>this.addElement(Er,wn(ct,this.doc)))})}removeUsage(ct,Bt){const wn=Bt.get(ct);wn&&(wn.usage--,wn.usage<=0&&(re(wn.elements),Bt.delete(ct)))}ngOnDestroy(){for(const[,{elements:ct}]of[...this.inline,...this.external])re(ct);this.hosts.clear()}addHost(ct){this.hosts.add(ct);for(const[Bt,{elements:wn}]of this.inline)wn.push(this.addElement(ct,pe(Bt,this.doc)));for(const[Bt,{elements:wn}]of this.external)wn.push(this.addElement(ct,ae(Bt,this.doc)))}removeHost(ct){this.hosts.delete(ct)}addElement(ct,Bt){return this.nonce&&Bt.setAttribute("nonce",this.nonce),this.isServer&&Bt.setAttribute(q,this.appId),ct.appendChild(Bt)}static \u0275fac=function(Bt){return new(Bt||Ve)(a.KVO(i.qQ),a.KVO(a.sZ2),a.KVO(a.BIS,8),a.KVO(a.Agw))};static \u0275prov=a.jDH({token:Ve,factory:Ve.\u0275fac})}return Ve})();const be={svg:"http://www.w3.org/2000/svg",xhtml:"http://www.w3.org/1999/xhtml",xlink:"http://www.w3.org/1999/xlink",xml:"http://www.w3.org/XML/1998/namespace",xmlns:"http://www.w3.org/2000/xmlns/",math:"http://www.w3.org/1998/Math/MathML"},Oe=/%COMP%/g,Ce=new a.nKC("",{providedIn:"root",factory:()=>!0});function dt(Ve,Dt){return Dt.map(ct=>ct.replace(Oe,Ve))}let bt=(()=>{class Ve{eventManager;sharedStylesHost;appId;removeStylesOnCompDestroy;doc;platformId;ngZone;nonce;rendererByCompId=new Map;defaultRenderer;platformIsServer;constructor(ct,Bt,wn,qn,Er,si,hi,Zi=null){this.eventManager=ct,this.sharedStylesHost=Bt,this.appId=wn,this.removeStylesOnCompDestroy=qn,this.doc=Er,this.platformId=si,this.ngZone=hi,this.nonce=Zi,this.platformIsServer=(0,i.Vy)(si),this.defaultRenderer=new lt(ct,Er,hi,this.platformIsServer)}createRenderer(ct,Bt){if(!ct||!Bt)return this.defaultRenderer;this.platformIsServer&&Bt.encapsulation===a.gXe.ShadowDom&&(Bt={...Bt,encapsulation:a.gXe.Emulated});const wn=this.getOrCreateRenderer(ct,Bt);return wn instanceof qe?wn.applyToHost(ct):wn instanceof yn&&wn.applyStyles(),wn}getOrCreateRenderer(ct,Bt){const wn=this.rendererByCompId;let qn=wn.get(Bt.id);if(!qn){const Er=this.doc,si=this.ngZone,hi=this.eventManager,Zi=this.sharedStylesHost,Jt=this.removeStylesOnCompDestroy,Tt=this.platformIsServer;switch(Bt.encapsulation){case a.gXe.Emulated:qn=new qe(hi,Zi,Bt,this.appId,Jt,Er,si,Tt);break;case a.gXe.ShadowDom:return new Vn(hi,Zi,ct,Bt,Er,si,this.nonce,Tt);default:qn=new yn(hi,Zi,Bt,Jt,Er,si,Tt)}wn.set(Bt.id,qn)}return qn}ngOnDestroy(){this.rendererByCompId.clear()}static \u0275fac=function(Bt){return new(Bt||Ve)(a.KVO(L),a.KVO(me),a.KVO(a.sZ2),a.KVO(Ce),a.KVO(i.qQ),a.KVO(a.Agw),a.KVO(a.SKi),a.KVO(a.BIS))};static \u0275prov=a.jDH({token:Ve,factory:Ve.\u0275fac})}return Ve})();class lt{eventManager;doc;ngZone;platformIsServer;data=Object.create(null);throwOnSyntheticProps=!0;constructor(Dt,ct,Bt,wn){this.eventManager=Dt,this.doc=ct,this.ngZone=Bt,this.platformIsServer=wn}destroy(){}destroyNode=null;createElement(Dt,ct){return ct?this.doc.createElementNS(be[ct]||ct,Dt):this.doc.createElement(Dt)}createComment(Dt){return this.doc.createComment(Dt)}createText(Dt){return this.doc.createTextNode(Dt)}appendChild(Dt,ct){(bn(Dt)?Dt.content:Dt).appendChild(ct)}insertBefore(Dt,ct,Bt){Dt&&(bn(Dt)?Dt.content:Dt).insertBefore(ct,Bt)}removeChild(Dt,ct){ct.remove()}selectRootElement(Dt,ct){let Bt="string"==typeof Dt?this.doc.querySelector(Dt):Dt;if(!Bt)throw new a.wOt(-5104,!1);return ct||(Bt.textContent=""),Bt}parentNode(Dt){return Dt.parentNode}nextSibling(Dt){return Dt.nextSibling}setAttribute(Dt,ct,Bt,wn){if(wn){ct=wn+":"+ct;const qn=be[wn];qn?Dt.setAttributeNS(qn,ct,Bt):Dt.setAttribute(ct,Bt)}else Dt.setAttribute(ct,Bt)}removeAttribute(Dt,ct,Bt){if(Bt){const wn=be[Bt];wn?Dt.removeAttributeNS(wn,ct):Dt.removeAttribute(`${Bt}:${ct}`)}else Dt.removeAttribute(ct)}addClass(Dt,ct){Dt.classList.add(ct)}removeClass(Dt,ct){Dt.classList.remove(ct)}setStyle(Dt,ct,Bt,wn){wn&(a.czy.DashCase|a.czy.Important)?Dt.style.setProperty(ct,Bt,wn&a.czy.Important?"important":""):Dt.style[ct]=Bt}removeStyle(Dt,ct,Bt){Bt&a.czy.DashCase?Dt.style.removeProperty(ct):Dt.style[ct]=""}setProperty(Dt,ct,Bt){null!=Dt&&(Dt[ct]=Bt)}setValue(Dt,ct){Dt.nodeValue=ct}listen(Dt,ct,Bt){if("string"==typeof Dt&&!(Dt=(0,i.QT)().getGlobalEventTarget(this.doc,Dt)))throw new Error(`Unsupported event target ${Dt} for event ${ct}`);return this.eventManager.addEventListener(Dt,ct,this.decoratePreventDefault(Bt))}decoratePreventDefault(Dt){return ct=>{if("__ngUnwrap__"===ct)return Dt;!1===(this.platformIsServer?this.ngZone.runGuarded(()=>Dt(ct)):Dt(ct))&&ct.preventDefault()}}}function bn(Ve){return"TEMPLATE"===Ve.tagName&&void 0!==Ve.content}class Vn extends lt{sharedStylesHost;hostEl;shadowRoot;constructor(Dt,ct,Bt,wn,qn,Er,si,hi){super(Dt,qn,Er,hi),this.sharedStylesHost=ct,this.hostEl=Bt,this.shadowRoot=Bt.attachShadow({mode:"open"}),this.sharedStylesHost.addHost(this.shadowRoot);const Zi=dt(wn.id,wn.styles);for(const Tt of Zi){const nt=document.createElement("style");si&&nt.setAttribute("nonce",si),nt.textContent=Tt,this.shadowRoot.appendChild(nt)}const Jt=wn.getExternalStyles?.();if(Jt)for(const Tt of Jt){const nt=ae(Tt,qn);si&&nt.setAttribute("nonce",si),this.shadowRoot.appendChild(nt)}}nodeOrShadowRoot(Dt){return Dt===this.hostEl?this.shadowRoot:Dt}appendChild(Dt,ct){return super.appendChild(this.nodeOrShadowRoot(Dt),ct)}insertBefore(Dt,ct,Bt){return super.insertBefore(this.nodeOrShadowRoot(Dt),ct,Bt)}removeChild(Dt,ct){return super.removeChild(null,ct)}parentNode(Dt){return this.nodeOrShadowRoot(super.parentNode(this.nodeOrShadowRoot(Dt)))}destroy(){this.sharedStylesHost.removeHost(this.shadowRoot)}}class yn extends lt{sharedStylesHost;removeStylesOnCompDestroy;styles;styleUrls;constructor(Dt,ct,Bt,wn,qn,Er,si,hi){super(Dt,qn,Er,si),this.sharedStylesHost=ct,this.removeStylesOnCompDestroy=wn,this.styles=hi?dt(hi,Bt.styles):Bt.styles,this.styleUrls=Bt.getExternalStyles?.(hi)}applyStyles(){this.sharedStylesHost.addStyles(this.styles,this.styleUrls)}destroy(){this.removeStylesOnCompDestroy&&this.sharedStylesHost.removeStyles(this.styles,this.styleUrls)}}class qe extends yn{contentAttr;hostAttr;constructor(Dt,ct,Bt,wn,qn,Er,si,hi){const Zi=wn+"-"+Bt.id;super(Dt,ct,Bt,qn,Er,si,hi,Zi),this.contentAttr=function Be(Ve){return"_ngcontent-%COMP%".replace(Oe,Ve)}(Zi),this.hostAttr=function at(Ve){return"_nghost-%COMP%".replace(Oe,Ve)}(Zi)}applyToHost(Dt){this.applyStyles(),this.setAttribute(Dt,this.hostAttr,"")}createElement(Dt,ct){const Bt=super.createElement(Dt,ct);return super.setAttribute(Bt,this.contentAttr,""),Bt}}let _t=(()=>{class Ve extends Z{constructor(ct){super(ct)}supports(ct){return!0}addEventListener(ct,Bt,wn){return ct.addEventListener(Bt,wn,!1),()=>this.removeEventListener(ct,Bt,wn)}removeEventListener(ct,Bt,wn){return ct.removeEventListener(Bt,wn)}static \u0275fac=function(Bt){return new(Bt||Ve)(a.KVO(i.qQ))};static \u0275prov=a.jDH({token:Ve,factory:Ve.\u0275fac})}return Ve})();const ze=["alt","control","meta","shift"],$e={"\b":"Backspace","\t":"Tab","\x7f":"Delete","\x1b":"Escape",Del:"Delete",Esc:"Escape",Left:"ArrowLeft",Right:"ArrowRight",Up:"ArrowUp",Down:"ArrowDown",Menu:"ContextMenu",Scroll:"ScrollLock",Win:"OS"},Ft={alt:Ve=>Ve.altKey,control:Ve=>Ve.ctrlKey,meta:Ve=>Ve.metaKey,shift:Ve=>Ve.shiftKey};let Ke=(()=>{class Ve extends Z{constructor(ct){super(ct)}supports(ct){return null!=Ve.parseEventName(ct)}addEventListener(ct,Bt,wn){const qn=Ve.parseEventName(Bt),Er=Ve.eventCallback(qn.fullKey,wn,this.manager.getZone());return this.manager.getZone().runOutsideAngular(()=>(0,i.QT)().onAndCancel(ct,qn.domEventName,Er))}static parseEventName(ct){const Bt=ct.toLowerCase().split("."),wn=Bt.shift();if(0===Bt.length||"keydown"!==wn&&"keyup"!==wn)return null;const qn=Ve._normalizeKey(Bt.pop());let Er="",si=Bt.indexOf("code");if(si>-1&&(Bt.splice(si,1),Er="code."),ze.forEach(Zi=>{const Jt=Bt.indexOf(Zi);Jt>-1&&(Bt.splice(Jt,1),Er+=Zi+".")}),Er+=qn,0!=Bt.length||0===qn.length)return null;const hi={};return hi.domEventName=wn,hi.fullKey=Er,hi}static matchEventFullKeyCode(ct,Bt){let wn=$e[ct.key]||ct.key,qn="";return Bt.indexOf("code.")>-1&&(wn=ct.code,qn="code."),!(null==wn||!wn)&&(wn=wn.toLowerCase()," "===wn?wn="space":"."===wn&&(wn="dot"),ze.forEach(Er=>{Er!==wn&&(0,Ft[Er])(ct)&&(qn+=Er+".")}),qn+=wn,qn===Bt)}static eventCallback(ct,Bt,wn){return qn=>{Ve.matchEventFullKeyCode(qn,ct)&&wn.runGuarded(()=>Bt(qn))}}static _normalizeKey(ct){return"esc"===ct?"escape":ct}static \u0275fac=function(Bt){return new(Bt||Ve)(a.KVO(i.qQ))};static \u0275prov=a.jDH({token:Ve,factory:Ve.\u0275fac})}return Ve})();function Ze(Ve,Dt){return(0,a.TL3)({rootComponent:Ve,...Ot(Dt)})}function Ot(Ve){return{appProviders:[...Vt,...Ve?.providers??[]],platformProviders:Xt}}const Xt=[{provide:a.Agw,useValue:i.AJ},{provide:a.PLl,useValue:function Te(){y.makeCurrent()},multi:!0},{provide:i.qQ,useFactory:function st(){return(0,a.TL$)(document),document},deps:[]}],Vt=[{provide:a.H8p,useValue:"root"},{provide:a.zcH,useFactory:function Ee(){return new a.zcH},deps:[]},{provide:O,useClass:_t,multi:!0,deps:[i.qQ,a.SKi,a.Agw]},{provide:O,useClass:Ke,multi:!0,deps:[i.qQ]},bt,me,L,{provide:a._9s,useExisting:bt},{provide:i.N0,useClass:M,deps:[]},[]];let Nr=(()=>{class Ve{_doc;constructor(ct){this._doc=ct}getTitle(){return this._doc.title}setTitle(ct){this._doc.title=ct||""}static \u0275fac=function(Bt){return new(Bt||Ve)(a.KVO(i.qQ))};static \u0275prov=a.jDH({token:Ve,factory:Ve.\u0275fac,providedIn:"root"})}return Ve})(),an=(()=>{class Ve{static \u0275fac=function(Bt){return new(Bt||Ve)};static \u0275prov=a.jDH({token:Ve,factory:function(Bt){let wn=null;return wn=Bt?new(Bt||Ve):a.KVO(dn),wn},providedIn:"root"})}return Ve})(),dn=(()=>{class Ve extends an{_doc;constructor(ct){super(),this._doc=ct}sanitize(ct,Bt){if(null==Bt)return null;switch(ct){case a.WPN.NONE:return Bt;case a.WPN.HTML:return(0,a.ZF7)(Bt,"HTML")?(0,a.rcV)(Bt):(0,a.h9k)(this._doc,String(Bt)).toString();case a.WPN.STYLE:return(0,a.ZF7)(Bt,"Style")?(0,a.rcV)(Bt):Bt;case a.WPN.SCRIPT:if((0,a.ZF7)(Bt,"Script"))return(0,a.rcV)(Bt);throw new a.wOt(5200,!1);case a.WPN.URL:return(0,a.ZF7)(Bt,"URL")?(0,a.rcV)(Bt):(0,a.$MX)(String(Bt));case a.WPN.RESOURCE_URL:if((0,a.ZF7)(Bt,"ResourceURL"))return(0,a.rcV)(Bt);throw new a.wOt(5201,!1);default:throw new a.wOt(5202,!1)}}bypassSecurityTrustHtml(ct){return(0,a.Kcf)(ct)}bypassSecurityTrustStyle(ct){return(0,a.cWb)(ct)}bypassSecurityTrustScript(ct){return(0,a.UyX)(ct)}bypassSecurityTrustUrl(ct){return(0,a.osQ)(ct)}bypassSecurityTrustResourceUrl(ct){return(0,a.e5t)(ct)}static \u0275fac=function(Bt){return new(Bt||Ve)(a.KVO(i.qQ))};static \u0275prov=a.jDH({token:Ve,factory:Ve.\u0275fac,providedIn:"root"})}return Ve})()},8716:(o,s,r)=>{"use strict";r.d(s,{nX:()=>_o,wF:()=>Ye,Ix:()=>li,Wk:()=>bs,wQ:()=>Lo,iI:()=>Wa,n3:()=>ca,lh:()=>ou,oH:()=>Wl});var i=r(3107),a=r(1531),c=r(1787),y=r(3016),w=r(1217),C=r(6627),T=r(8747),S=r(3569),M=r(6381),O=r(6742),L=r(8915),Z=r(6564),q=r(1642),re=r(8447),pe=r(5710),se=r(4460),ae=r(7947),me=r(2867),be=r(7610),Oe=r(593),xe=r(1483),De=r(5823),ce=r(1703),ue=r(1459),Ce=r(2040),Be=r(7178),at=r(5351),dt=r(36),lt=r(5670),rn=r(2483);function gn(R){return R<=0?()=>Z.w:(0,at.N)((G,F)=>{let K=[];G.subscribe((0,rn._)(F,_e=>{K.push(_e),R{for(const _e of K)F.next(_e);F.complete()},void 0,()=>{K=null}))})}var bn=r(5017),Vn=r(9220),qe=r(6590),_t=r(4447),ze=r(3589),$e=r(5424),Ft=r(1890),Ke=r(6388);const Ze="primary",it=Symbol("RouteTitle");class Ot{params;constructor(G){this.params=G||{}}has(G){return Object.prototype.hasOwnProperty.call(this.params,G)}get(G){if(this.has(G)){const F=this.params[G];return Array.isArray(F)?F[0]:F}return null}getAll(G){if(this.has(G)){const F=this.params[G];return Array.isArray(F)?F:[F]}return[]}get keys(){return Object.keys(this.params)}}function $t(R){return new Ot(R)}function Te(R,G,F){const K=F.path.split("/");if(K.length>R.length||"full"===F.pathMatch&&(G.hasChildren()||K.lengthK[We]===_e)}return R===G}function Kt(R){return R.length>0?R[R.length-1]:null}function rt(R){return(0,a.A)(R)?R:(0,i.jNT)(R)?(0,c.H)(Promise.resolve(R)):(0,y.of)(R)}const Vt={exact:function Nr(R,G,F){if(!W(R.segments,G.segments)||!Fe(R.segments,G.segments,F)||R.numberOfChildren!==G.numberOfChildren)return!1;for(const K in G.children)if(!R.children[K]||!Nr(R.children[K],G.children[K],F))return!1;return!0},subset:pr},en={exact:function Kn(R,G){return st(R,G)},subset:function Rn(R,G){return Object.keys(G).length<=Object.keys(R).length&&Object.keys(G).every(F=>Mt(R[F],G[F]))},ignored:()=>!0};function kn(R,G,F){return Vt[F.paths](R.root,G.root,F.matrixParams)&&en[F.queryParams](R.queryParams,G.queryParams)&&!("exact"===F.fragment&&R.fragment!==G.fragment)}function pr(R,G,F){return cn(R,G,G.segments,F)}function cn(R,G,F,K){if(R.segments.length>F.length){const _e=R.segments.slice(0,F.length);return!(!W(_e,F)||G.hasChildren()||!Fe(_e,F,K))}if(R.segments.length===F.length){if(!W(R.segments,F)||!Fe(R.segments,F,K))return!1;for(const _e in G.children)if(!R.children[_e]||!pr(R.children[_e],G.children[_e],K))return!1;return!0}{const _e=F.slice(0,R.segments.length),We=F.slice(R.segments.length);return!!(W(R.segments,_e)&&Fe(R.segments,_e,K)&&R.children[Ze])&&cn(R.children[Ze],G,We,K)}}function Fe(R,G,F){return G.every((K,_e)=>en[F](R[_e].parameters,K.parameters))}class ke{root;queryParams;fragment;_queryParamMap;constructor(G=new Je([],{}),F={},K=null){this.root=G,this.queryParams=F,this.fragment=K}get queryParamMap(){return this._queryParamMap??=$t(this.queryParams),this._queryParamMap}toString(){return St.serialize(this)}}class Je{segments;children;parent=null;constructor(G,F){this.segments=G,this.children=F,Object.values(F).forEach(K=>K.parent=this)}hasChildren(){return this.numberOfChildren>0}get numberOfChildren(){return Object.keys(this.children).length}toString(){return Tn(this)}}class z{path;parameters;_parameterMap;constructor(G,F){this.path=G,this.parameters=F}get parameterMap(){return this._parameterMap??=$t(this.parameters),this._parameterMap}toString(){return Vr(this)}}function W(R,G){return R.length===G.length&&R.every((F,K)=>F.path===G[K].path)}let ft=(()=>{class R{static \u0275fac=function(K){return new(K||R)};static \u0275prov=i.jDH({token:R,factory:()=>new mt,providedIn:"root"})}return R})();class mt{parse(G){const F=new Er(G);return new ke(F.parseRootSegment(),F.parseQueryParams(),F.parseFragment())}serialize(G){const F=`/${an(G.root,!0)}`,K=function Wt(R){const G=Object.entries(R).map(([F,K])=>Array.isArray(K)?K.map(_e=>`${In(F)}=${In(_e)}`).join("&"):`${In(F)}=${In(K)}`).filter(F=>F);return G.length?`?${G.join("&")}`:""}(G.queryParams);return`${F}${K}${"string"==typeof G.fragment?`#${function sr(R){return encodeURI(R)}(G.fragment)}`:""}`}}const St=new mt;function Tn(R){return R.segments.map(G=>Vr(G)).join("/")}function an(R,G){if(!R.hasChildren())return Tn(R);if(G){const F=R.children[Ze]?an(R.children[Ze],!1):"",K=[];return Object.entries(R.children).forEach(([_e,We])=>{_e!==Ze&&K.push(`${_e}:${an(We,!1)}`)}),K.length>0?`${F}(${K.join("//")})`:F}{const F=function Le(R,G){let F=[];return Object.entries(R.children).forEach(([K,_e])=>{K===Ze&&(F=F.concat(G(_e,K)))}),Object.entries(R.children).forEach(([K,_e])=>{K!==Ze&&(F=F.concat(G(_e,K)))}),F}(R,(K,_e)=>_e===Ze?[an(R.children[Ze],!1)]:[`${_e}:${an(K,!1)}`]);return 1===Object.keys(R.children).length&&null!=R.children[Ze]?`${Tn(R)}/${F[0]}`:`${Tn(R)}/(${F.join("//")})`}}function dn(R){return encodeURIComponent(R).replace(/%40/g,"@").replace(/%3A/gi,":").replace(/%24/g,"$").replace(/%2C/gi,",")}function In(R){return dn(R).replace(/%3B/gi,";")}function xn(R){return dn(R).replace(/\(/g,"%28").replace(/\)/g,"%29").replace(/%26/gi,"&")}function Hr(R){return decodeURIComponent(R)}function Tr(R){return Hr(R.replace(/\+/g,"%20"))}function Vr(R){return`${xn(R.path)}${function vt(R){return Object.entries(R).map(([G,F])=>`;${xn(G)}=${xn(F)}`).join("")}(R.parameters)}`}const Re=/^[^\/()?;#]+/;function Ge(R){const G=R.match(Re);return G?G[0]:""}const Ve=/^[^\/()?;=#]+/,ct=/^[^=?&#]+/,wn=/^[^&#]+/;class Er{url;remaining;constructor(G){this.url=G,this.remaining=G}parseRootSegment(){return this.consumeOptional("/"),""===this.remaining||this.peekStartsWith("?")||this.peekStartsWith("#")?new Je([],{}):new Je([],this.parseChildren())}parseQueryParams(){const G={};if(this.consumeOptional("?"))do{this.parseQueryParam(G)}while(this.consumeOptional("&"));return G}parseFragment(){return this.consumeOptional("#")?decodeURIComponent(this.remaining):null}parseChildren(){if(""===this.remaining)return{};this.consumeOptional("/");const G=[];for(this.peekStartsWith("(")||G.push(this.parseSegment());this.peekStartsWith("/")&&!this.peekStartsWith("//")&&!this.peekStartsWith("/(");)this.capture("/"),G.push(this.parseSegment());let F={};this.peekStartsWith("/(")&&(this.capture("/"),F=this.parseParens(!0));let K={};return this.peekStartsWith("(")&&(K=this.parseParens(!1)),(G.length>0||Object.keys(F).length>0)&&(K[Ze]=new Je(G,F)),K}parseSegment(){const G=Ge(this.remaining);if(""===G&&this.peekStartsWith(";"))throw new i.wOt(4009,!1);return this.capture(G),new z(Hr(G),this.parseMatrixParams())}parseMatrixParams(){const G={};for(;this.consumeOptional(";");)this.parseParam(G);return G}parseParam(G){const F=function Dt(R){const G=R.match(Ve);return G?G[0]:""}(this.remaining);if(!F)return;this.capture(F);let K="";if(this.consumeOptional("=")){const _e=Ge(this.remaining);_e&&(K=_e,this.capture(K))}G[Hr(F)]=Hr(K)}parseQueryParam(G){const F=function Bt(R){const G=R.match(ct);return G?G[0]:""}(this.remaining);if(!F)return;this.capture(F);let K="";if(this.consumeOptional("=")){const At=function qn(R){const G=R.match(wn);return G?G[0]:""}(this.remaining);At&&(K=At,this.capture(K))}const _e=Tr(F),We=Tr(K);if(G.hasOwnProperty(_e)){let At=G[_e];Array.isArray(At)||(At=[At],G[_e]=At),At.push(We)}else G[_e]=We}parseParens(G){const F={};for(this.capture("(");!this.consumeOptional(")")&&this.remaining.length>0;){const K=Ge(this.remaining),_e=this.remaining[K.length];if("/"!==_e&&")"!==_e&&";"!==_e)throw new i.wOt(4010,!1);let We;K.indexOf(":")>-1?(We=K.slice(0,K.indexOf(":")),this.capture(We),this.capture(":")):G&&(We=Ze);const At=this.parseChildren();F[We]=1===Object.keys(At).length?At[Ze]:new Je([],At),this.consumeOptional("//")}return F}peekStartsWith(G){return this.remaining.startsWith(G)}consumeOptional(G){return!!this.peekStartsWith(G)&&(this.remaining=this.remaining.substring(G.length),!0)}capture(G){if(!this.consumeOptional(G))throw new i.wOt(4011,!1)}}function si(R){return R.segments.length>0?new Je([],{[Ze]:R}):R}function hi(R){const G={};for(const[K,_e]of Object.entries(R.children)){const We=hi(_e);if(K===Ze&&0===We.segments.length&&We.hasChildren())for(const[At,fn]of Object.entries(We.children))G[At]=fn;else(We.segments.length>0||We.hasChildren())&&(G[K]=We)}return function Zi(R){if(1===R.numberOfChildren&&R.children[Ze]){const G=R.children[Ze];return new Je(R.segments.concat(G.segments),G.children)}return R}(new Je(R.segments,G))}function Jt(R){return R instanceof ke}function nt(R){let G;const _e=si(function F(We){const At={};for(const on of We.children){const ur=F(on);At[on.outlet]=ur}const fn=new Je(We.url,At);return We===R&&(G=fn),fn}(R.root));return G??_e}function Rt(R,G,F,K){let _e=R;for(;_e.parent;)_e=_e.parent;if(0===G.length)return dr(_e,_e,_e,F,K);const We=function ds(R){if("string"==typeof R[0]&&1===R.length&&"/"===R[0])return new Ni(!0,0,R);let G=0,F=!1;const K=R.reduce((_e,We,At)=>{if("object"==typeof We&&null!=We){if(We.outlets){const fn={};return Object.entries(We.outlets).forEach(([on,ur])=>{fn[on]="string"==typeof ur?ur.split("/"):ur}),[..._e,{outlets:fn}]}if(We.segmentPath)return[..._e,We.segmentPath]}return"string"!=typeof We?[..._e,We]:0===At?(We.split("/").forEach((fn,on)=>{0==on&&"."===fn||(0==on&&""===fn?F=!0:".."===fn?G++:""!=fn&&_e.push(fn))}),_e):[..._e,We]},[]);return new Ni(F,G,K)}(G);if(We.toRoot())return dr(_e,_e,new Je([],{}),F,K);const At=function ai(R,G,F){if(R.isAbsolute)return new $o(G,!0,0);if(!F)return new $o(G,!1,NaN);if(null===F.parent)return new $o(F,!0,0);const K=sn(R.commands[0])?0:1;return function qo(R,G,F){let K=R,_e=G,We=F;for(;We>_e;){if(We-=_e,K=K.parent,!K)throw new i.wOt(4005,!1);_e=K.segments.length}return new $o(K,!1,_e-We)}(F,F.segments.length-1+K,R.numberOfDoubleDots)}(We,_e,R),fn=At.processChildren?Fo(At.segmentGroup,At.index,We.commands):Jo(At.segmentGroup,At.index,We.commands);return dr(_e,At.segmentGroup,fn,F,K)}function sn(R){return"object"==typeof R&&null!=R&&!R.outlets&&!R.segmentPath}function mn(R){return"object"==typeof R&&null!=R&&R.outlets}function dr(R,G,F,K,_e){let At,We={};K&&Object.entries(K).forEach(([on,ur])=>{We[on]=Array.isArray(ur)?ur.map(ui=>`${ui}`):`${ur}`}),At=R===G?F:Co(R,G,F);const fn=si(hi(At));return new ke(fn,We,_e)}function Co(R,G,F){const K={};return Object.entries(R.children).forEach(([_e,We])=>{K[_e]=We===G?F:Co(We,G,F)}),new Je(R.segments,K)}class Ni{isAbsolute;numberOfDoubleDots;commands;constructor(G,F,K){if(this.isAbsolute=G,this.numberOfDoubleDots=F,this.commands=K,G&&K.length>0&&sn(K[0]))throw new i.wOt(4003,!1);const _e=K.find(mn);if(_e&&_e!==Kt(K))throw new i.wOt(4004,!1)}toRoot(){return this.isAbsolute&&1===this.commands.length&&"/"==this.commands[0]}}class $o{segmentGroup;processChildren;index;constructor(G,F,K){this.segmentGroup=G,this.processChildren=F,this.index=K}}function Jo(R,G,F){if(R??=new Je([],{}),0===R.segments.length&&R.hasChildren())return Fo(R,G,F);const K=function oa(R,G,F){let K=0,_e=G;const We={match:!1,pathIndex:0,commandIndex:0};for(;_e=F.length)return We;const At=R.segments[_e],fn=F[K];if(mn(fn))break;const on=`${fn}`,ur=K0&&void 0===on)break;if(on&&ur&&"object"==typeof ur&&void 0===ur.outlets){if(!Io(on,ur,At))return We;K+=2}else{if(!Io(on,{},At))return We;K++}_e++}return{match:!0,pathIndex:_e,commandIndex:K}}(R,G,F),_e=F.slice(K.commandIndex);if(K.match&&K.pathIndexWe!==Ze)&&R.children[Ze]&&1===R.numberOfChildren&&0===R.children[Ze].segments.length){const We=Fo(R.children[Ze],G,F);return new Je(R.segments,We.children)}return Object.entries(K).forEach(([We,At])=>{"string"==typeof At&&(At=[At]),null!==At&&(_e[We]=Jo(R.children[We],G,At))}),Object.entries(R.children).forEach(([We,At])=>{void 0===K[We]&&(_e[We]=At)}),new Je(R.segments,_e)}}function ao(R,G,F){const K=R.segments.slice(0,G);let _e=0;for(;_e{"string"==typeof K&&(K=[K]),null!==K&&(G[F]=ao(new Je([],{}),0,K))}),G}function Ii(R){const G={};return Object.entries(R).forEach(([F,K])=>G[F]=`${K}`),G}function Io(R,G,F){return R==F.path&&st(G,F.parameters)}const tt="imperative";var xt=function(R){return R[R.NavigationStart=0]="NavigationStart",R[R.NavigationEnd=1]="NavigationEnd",R[R.NavigationCancel=2]="NavigationCancel",R[R.NavigationError=3]="NavigationError",R[R.RoutesRecognized=4]="RoutesRecognized",R[R.ResolveStart=5]="ResolveStart",R[R.ResolveEnd=6]="ResolveEnd",R[R.GuardsCheckStart=7]="GuardsCheckStart",R[R.GuardsCheckEnd=8]="GuardsCheckEnd",R[R.RouteConfigLoadStart=9]="RouteConfigLoadStart",R[R.RouteConfigLoadEnd=10]="RouteConfigLoadEnd",R[R.ChildActivationStart=11]="ChildActivationStart",R[R.ChildActivationEnd=12]="ChildActivationEnd",R[R.ActivationStart=13]="ActivationStart",R[R.ActivationEnd=14]="ActivationEnd",R[R.Scroll=15]="Scroll",R[R.NavigationSkipped=16]="NavigationSkipped",R}(xt||{});class ht{id;url;constructor(G,F){this.id=G,this.url=F}}class ve extends ht{type=xt.NavigationStart;navigationTrigger;restoredState;constructor(G,F,K="imperative",_e=null){super(G,F),this.navigationTrigger=K,this.restoredState=_e}toString(){return`NavigationStart(id: ${this.id}, url: '${this.url}')`}}class Ye extends ht{urlAfterRedirects;type=xt.NavigationEnd;constructor(G,F,K){super(G,F),this.urlAfterRedirects=K}toString(){return`NavigationEnd(id: ${this.id}, url: '${this.url}', urlAfterRedirects: '${this.urlAfterRedirects}')`}}var Ne=function(R){return R[R.Redirect=0]="Redirect",R[R.SupersededByNewNavigation=1]="SupersededByNewNavigation",R[R.NoDataFromResolver=2]="NoDataFromResolver",R[R.GuardRejected=3]="GuardRejected",R}(Ne||{}),gt=function(R){return R[R.IgnoredSameUrlNavigation=0]="IgnoredSameUrlNavigation",R[R.IgnoredByUrlHandlingStrategy=1]="IgnoredByUrlHandlingStrategy",R}(gt||{});class Ht extends ht{reason;code;type=xt.NavigationCancel;constructor(G,F,K,_e){super(G,F),this.reason=K,this.code=_e}toString(){return`NavigationCancel(id: ${this.id}, url: '${this.url}')`}}class kt extends ht{reason;code;type=xt.NavigationSkipped;constructor(G,F,K,_e){super(G,F),this.reason=K,this.code=_e}}class hn extends ht{error;target;type=xt.NavigationError;constructor(G,F,K,_e){super(G,F),this.error=K,this.target=_e}toString(){return`NavigationError(id: ${this.id}, url: '${this.url}', error: ${this.error})`}}class Dn extends ht{urlAfterRedirects;state;type=xt.RoutesRecognized;constructor(G,F,K,_e){super(G,F),this.urlAfterRedirects=K,this.state=_e}toString(){return`RoutesRecognized(id: ${this.id}, url: '${this.url}', urlAfterRedirects: '${this.urlAfterRedirects}', state: ${this.state})`}}class Cn extends ht{urlAfterRedirects;state;type=xt.GuardsCheckStart;constructor(G,F,K,_e){super(G,F),this.urlAfterRedirects=K,this.state=_e}toString(){return`GuardsCheckStart(id: ${this.id}, url: '${this.url}', urlAfterRedirects: '${this.urlAfterRedirects}', state: ${this.state})`}}class Nn extends ht{urlAfterRedirects;state;shouldActivate;type=xt.GuardsCheckEnd;constructor(G,F,K,_e,We){super(G,F),this.urlAfterRedirects=K,this.state=_e,this.shouldActivate=We}toString(){return`GuardsCheckEnd(id: ${this.id}, url: '${this.url}', urlAfterRedirects: '${this.urlAfterRedirects}', state: ${this.state}, shouldActivate: ${this.shouldActivate})`}}class jn extends ht{urlAfterRedirects;state;type=xt.ResolveStart;constructor(G,F,K,_e){super(G,F),this.urlAfterRedirects=K,this.state=_e}toString(){return`ResolveStart(id: ${this.id}, url: '${this.url}', urlAfterRedirects: '${this.urlAfterRedirects}', state: ${this.state})`}}class Jn extends ht{urlAfterRedirects;state;type=xt.ResolveEnd;constructor(G,F,K,_e){super(G,F),this.urlAfterRedirects=K,this.state=_e}toString(){return`ResolveEnd(id: ${this.id}, url: '${this.url}', urlAfterRedirects: '${this.urlAfterRedirects}', state: ${this.state})`}}class ar{route;type=xt.RouteConfigLoadStart;constructor(G){this.route=G}toString(){return`RouteConfigLoadStart(path: ${this.route.path})`}}class wr{route;type=xt.RouteConfigLoadEnd;constructor(G){this.route=G}toString(){return`RouteConfigLoadEnd(path: ${this.route.path})`}}class xr{snapshot;type=xt.ChildActivationStart;constructor(G){this.snapshot=G}toString(){return`ChildActivationStart(path: '${this.snapshot.routeConfig&&this.snapshot.routeConfig.path||""}')`}}class gi{snapshot;type=xt.ChildActivationEnd;constructor(G){this.snapshot=G}toString(){return`ChildActivationEnd(path: '${this.snapshot.routeConfig&&this.snapshot.routeConfig.path||""}')`}}class ni{snapshot;type=xt.ActivationStart;constructor(G){this.snapshot=G}toString(){return`ActivationStart(path: '${this.snapshot.routeConfig&&this.snapshot.routeConfig.path||""}')`}}class Mi{snapshot;type=xt.ActivationEnd;constructor(G){this.snapshot=G}toString(){return`ActivationEnd(path: '${this.snapshot.routeConfig&&this.snapshot.routeConfig.path||""}')`}}class Or{routerEvent;position;anchor;type=xt.Scroll;constructor(G,F,K){this.routerEvent=G,this.position=F,this.anchor=K}toString(){return`Scroll(anchor: '${this.anchor}', position: '${this.position?`${this.position[0]}, ${this.position[1]}`:null}')`}}class Qr{}class Pr{url;navigationBehaviorOptions;constructor(G,F){this.url=G,this.navigationBehaviorOptions=F}}function No(R){return R.outlet||Ze}function Ko(R){if(!R)return null;if(R.routeConfig?._injector)return R.routeConfig._injector;for(let G=R.parent;G;G=G.parent){const F=G.routeConfig;if(F?._loadedInjector)return F._loadedInjector;if(F?._injector)return F._injector}return null}class mo{rootInjector;outlet=null;route=null;children;attachRef=null;get injector(){return Ko(this.route?.snapshot)??this.rootInjector}constructor(G){this.rootInjector=G,this.children=new Go(this.rootInjector)}}let Go=(()=>{class R{rootInjector;contexts=new Map;constructor(F){this.rootInjector=F}onChildOutletCreated(F,K){const _e=this.getOrCreateContext(F);_e.outlet=K,this.contexts.set(F,_e)}onChildOutletDestroyed(F){const K=this.getContext(F);K&&(K.outlet=null,K.attachRef=null)}onOutletDeactivated(){const F=this.contexts;return this.contexts=new Map,F}onOutletReAttached(F){this.contexts=F}getOrCreateContext(F){let K=this.getContext(F);return K||(K=new mo(this.rootInjector),this.contexts.set(F,K)),K}getContext(F){return this.contexts.get(F)||null}static \u0275fac=function(K){return new(K||R)(i.KVO(i.uvJ))};static \u0275prov=i.jDH({token:R,factory:R.\u0275fac,providedIn:"root"})}return R})();class Rs{_root;constructor(G){this._root=G}get root(){return this._root.value}parent(G){const F=this.pathFromRoot(G);return F.length>1?F[F.length-2]:null}children(G){const F=Xr(G,this._root);return F?F.children.map(K=>K.value):[]}firstChild(G){const F=Xr(G,this._root);return F&&F.children.length>0?F.children[0].value:null}siblings(G){const F=Ds(G,this._root);return F.length<2?[]:F[F.length-2].children.map(_e=>_e.value).filter(_e=>_e!==G)}pathFromRoot(G){return Ds(G,this._root).map(F=>F.value)}}function Xr(R,G){if(R===G.value)return G;for(const F of G.children){const K=Xr(R,F);if(K)return K}return null}function Ds(R,G){if(R===G.value)return[G];for(const F of G.children){const K=Ds(R,F);if(K.length)return K.unshift(G),K}return[]}class go{value;children;constructor(G,F){this.value=G,this.children=F}toString(){return`TreeNode(${this.value})`}}function io(R){const G={};return R&&R.children.forEach(F=>G[F.value.outlet]=F),G}class fs extends Rs{snapshot;constructor(G,F){super(G),this.snapshot=F,Gs(this,G)}toString(){return this.snapshot.toString()}}function Xo(R){const G=function Qa(R){const We=new lr([],{},{},"",{},Ze,R,null,{});return new As("",new go(We,[]))}(R),F=new w.t([new z("",{})]),K=new w.t({}),_e=new w.t({}),We=new w.t({}),At=new w.t(""),fn=new _o(F,K,We,At,_e,Ze,R,G.root);return fn.snapshot=G.root,new fs(new go(fn,[]),G)}class _o{urlSubject;paramsSubject;queryParamsSubject;fragmentSubject;dataSubject;outlet;component;snapshot;_futureSnapshot;_routerState;_paramMap;_queryParamMap;title;url;params;queryParams;fragment;data;constructor(G,F,K,_e,We,At,fn,on){this.urlSubject=G,this.paramsSubject=F,this.queryParamsSubject=K,this.fragmentSubject=_e,this.dataSubject=We,this.outlet=At,this.component=fn,this._futureSnapshot=on,this.title=this.dataSubject?.pipe((0,ae.T)(ur=>ur[it]))??(0,y.of)(void 0),this.url=G,this.params=F,this.queryParams=K,this.fragment=_e,this.data=We}get routeConfig(){return this._futureSnapshot.routeConfig}get root(){return this._routerState.root}get parent(){return this._routerState.parent(this)}get firstChild(){return this._routerState.firstChild(this)}get children(){return this._routerState.children(this)}get pathFromRoot(){return this._routerState.pathFromRoot(this)}get paramMap(){return this._paramMap??=this.params.pipe((0,ae.T)(G=>$t(G))),this._paramMap}get queryParamMap(){return this._queryParamMap??=this.queryParams.pipe((0,ae.T)(G=>$t(G))),this._queryParamMap}toString(){return this.snapshot?this.snapshot.toString():`Future(${this._futureSnapshot})`}}function Ao(R,G,F="emptyOnly"){let K;const{routeConfig:_e}=R;return K=null===G||"always"!==F&&""!==_e?.path&&(G.component||G.routeConfig?.loadComponent)?{params:{...R.params},data:{...R.data},resolve:{...R.data,...R._resolvedData??{}}}:{params:{...G.params,...R.params},data:{...G.data,...R.data},resolve:{...R.data,...G.data,..._e?.data,...R._resolvedData}},_e&&Vi(_e)&&(K.resolve[it]=_e.title),K}class lr{url;params;queryParams;fragment;data;outlet;component;routeConfig;_resolve;_resolvedData;_routerState;_paramMap;_queryParamMap;get title(){return this.data?.[it]}constructor(G,F,K,_e,We,At,fn,on,ur){this.url=G,this.params=F,this.queryParams=K,this.fragment=_e,this.data=We,this.outlet=At,this.component=fn,this.routeConfig=on,this._resolve=ur}get root(){return this._routerState.root}get parent(){return this._routerState.parent(this)}get firstChild(){return this._routerState.firstChild(this)}get children(){return this._routerState.children(this)}get pathFromRoot(){return this._routerState.pathFromRoot(this)}get paramMap(){return this._paramMap??=$t(this.params),this._paramMap}get queryParamMap(){return this._queryParamMap??=$t(this.queryParams),this._queryParamMap}toString(){return`Route(url:'${this.url.map(K=>K.toString()).join("/")}', path:'${this.routeConfig?this.routeConfig.path:""}')`}}class As extends Rs{url;constructor(G,F){super(F),this.url=G,Gs(this,F)}toString(){return _s(this._root)}}function Gs(R,G){G.value._routerState=R,G.children.forEach(F=>Gs(R,F))}function _s(R){const G=R.children.length>0?` { ${R.children.map(_s).join(", ")} } `:"";return`${R.value}${G}`}function la(R){if(R.snapshot){const G=R.snapshot,F=R._futureSnapshot;R.snapshot=F,st(G.queryParams,F.queryParams)||R.queryParamsSubject.next(F.queryParams),G.fragment!==F.fragment&&R.fragmentSubject.next(F.fragment),st(G.params,F.params)||R.paramsSubject.next(F.params),function Ee(R,G){if(R.length!==G.length)return!1;for(let F=0;Fst(F.parameters,G[K].parameters))}(R.url,G.url);return F&&!(!R.parent!=!G.parent)&&(!R.parent||ls(R.parent,G.parent))}function Vi(R){return"string"==typeof R.title||null===R.title}const ll=new i.nKC("");let ca=(()=>{class R{activated=null;get activatedComponentRef(){return this.activated}_activatedRoute=null;name=Ze;activateEvents=new i.bkB;deactivateEvents=new i.bkB;attachEvents=new i.bkB;detachEvents=new i.bkB;routerOutletData=(0,i.hFB)(void 0);parentContexts=(0,i.WQX)(Go);location=(0,i.WQX)(i.c1b);changeDetector=(0,i.WQX)(i.gRc);inputBinder=(0,i.WQX)(Ts,{optional:!0});supportsBindingToComponentInputs=!0;ngOnChanges(F){if(F.name){const{firstChange:K,previousValue:_e}=F.name;if(K)return;this.isTrackedInParentContexts(_e)&&(this.deactivate(),this.parentContexts.onChildOutletDestroyed(_e)),this.initializeOutletWithName()}}ngOnDestroy(){this.isTrackedInParentContexts(this.name)&&this.parentContexts.onChildOutletDestroyed(this.name),this.inputBinder?.unsubscribeFromRouteData(this)}isTrackedInParentContexts(F){return this.parentContexts.getContext(F)?.outlet===this}ngOnInit(){this.initializeOutletWithName()}initializeOutletWithName(){if(this.parentContexts.onChildOutletCreated(this.name,this),this.activated)return;const F=this.parentContexts.getContext(this.name);F?.route&&(F.attachRef?this.attach(F.attachRef,F.route):this.activateWith(F.route,F.injector))}get isActivated(){return!!this.activated}get component(){if(!this.activated)throw new i.wOt(4012,!1);return this.activated.instance}get activatedRoute(){if(!this.activated)throw new i.wOt(4012,!1);return this._activatedRoute}get activatedRouteData(){return this._activatedRoute?this._activatedRoute.snapshot.data:{}}detach(){if(!this.activated)throw new i.wOt(4012,!1);this.location.detach();const F=this.activated;return this.activated=null,this._activatedRoute=null,this.detachEvents.emit(F.instance),F}attach(F,K){this.activated=F,this._activatedRoute=K,this.location.insert(F.hostView),this.inputBinder?.bindActivatedRouteToOutletComponent(this),this.attachEvents.emit(F.instance)}deactivate(){if(this.activated){const F=this.component;this.activated.destroy(),this.activated=null,this._activatedRoute=null,this.deactivateEvents.emit(F)}}activateWith(F,K){if(this.isActivated)throw new i.wOt(4013,!1);this._activatedRoute=F;const _e=this.location,At=F.snapshot.component,fn=this.parentContexts.getOrCreateContext(this.name).children,on=new Ss(F,fn,_e.injector,this.routerOutletData);this.activated=_e.createComponent(At,{index:_e.length,injector:on,environmentInjector:K}),this.changeDetector.markForCheck(),this.inputBinder?.bindActivatedRouteToOutletComponent(this),this.activateEvents.emit(this.activated.instance)}static \u0275fac=function(K){return new(K||R)};static \u0275dir=i.FsC({type:R,selectors:[["router-outlet"]],inputs:{name:"name",routerOutletData:[1,"routerOutletData"]},outputs:{activateEvents:"activate",deactivateEvents:"deactivate",attachEvents:"attach",detachEvents:"detach"},exportAs:["outlet"],features:[i.OA$]})}return R})();class Ss{route;childContexts;parent;outletData;__ngOutletInjector(G){return new Ss(this.route,this.childContexts,G,this.outletData)}constructor(G,F,K,_e){this.route=G,this.childContexts=F,this.parent=K,this.outletData=_e}get(G,F){return G===_o?this.route:G===Go?this.childContexts:G===ll?this.outletData:this.parent.get(G,F)}}const Ts=new i.nKC("");let Ns=(()=>{class R{outletDataSubscriptions=new Map;bindActivatedRouteToOutletComponent(F){this.unsubscribeFromRouteData(F),this.subscribeToRouteData(F)}unsubscribeFromRouteData(F){this.outletDataSubscriptions.get(F)?.unsubscribe(),this.outletDataSubscriptions.delete(F)}subscribeToRouteData(F){const{activatedRoute:K}=F,_e=(0,C.z)([K.queryParams,K.params,K.data]).pipe((0,me.n)(([We,At,fn],on)=>(fn={...We,...At,...fn},0===on?(0,y.of)(fn):Promise.resolve(fn)))).subscribe(We=>{if(!F.isActivated||!F.activatedComponentRef||F.activatedRoute!==K||null===K.component)return void this.unsubscribeFromRouteData(F);const At=(0,i.HJs)(K.component);if(At)for(const{templateName:fn}of At.inputs)F.activatedComponentRef.setInput(fn,We[fn]);else this.unsubscribeFromRouteData(F)});this.outletDataSubscriptions.set(F,_e)}static \u0275fac=function(K){return new(K||R)};static \u0275prov=i.jDH({token:R,factory:R.\u0275fac})}return R})();function Bo(R,G,F){if(F&&R.shouldReuseRoute(G.value,F.value.snapshot)){const K=F.value;K._futureSnapshot=G.value;const _e=function lo(R,G,F){return G.children.map(K=>{for(const _e of F.children)if(R.shouldReuseRoute(K.value,_e.value.snapshot))return Bo(R,K,_e);return Bo(R,K)})}(R,G,F);return new go(K,_e)}{if(R.shouldAttach(G.value)){const We=R.retrieve(G.value);if(null!==We){const At=We.route;return At.value._futureSnapshot=G.value,At.children=G.children.map(fn=>Bo(R,fn)),At}}const K=function ps(R){return new _o(new w.t(R.url),new w.t(R.params),new w.t(R.queryParams),new w.t(R.fragment),new w.t(R.data),R.outlet,R.component,R)}(G.value),_e=G.children.map(We=>Bo(R,We));return new go(K,_e)}}class Da{redirectTo;navigationBehaviorOptions;constructor(G,F){this.redirectTo=G,this.navigationBehaviorOptions=F}}const Ms="ngNavigationCancelingError";function Us(R,G){const{redirectTo:F,navigationBehaviorOptions:K}=Jt(G)?{redirectTo:G,navigationBehaviorOptions:void 0}:G,_e=ua(!1,Ne.Redirect);return _e.url=F,_e.navigationBehaviorOptions=K,_e}function ua(R,G){const F=new Error(`NavigationCancelingError: ${R||""}`);return F[Ms]=!0,F.cancellationCode=G,F}function Aa(R){return!!R&&R[Ms]}class te{routeReuseStrategy;futureState;currState;forwardEvent;inputBindingEnabled;constructor(G,F,K,_e,We){this.routeReuseStrategy=G,this.futureState=F,this.currState=K,this.forwardEvent=_e,this.inputBindingEnabled=We}activate(G){const F=this.futureState._root,K=this.currState?this.currState._root:null;this.deactivateChildRoutes(F,K,G),la(this.futureState.root),this.activateChildRoutes(F,K,G)}deactivateChildRoutes(G,F,K){const _e=io(F);G.children.forEach(We=>{const At=We.value.outlet;this.deactivateRoutes(We,_e[At],K),delete _e[At]}),Object.values(_e).forEach(We=>{this.deactivateRouteAndItsChildren(We,K)})}deactivateRoutes(G,F,K){const _e=G.value,We=F?F.value:null;if(_e===We)if(_e.component){const At=K.getContext(_e.outlet);At&&this.deactivateChildRoutes(G,F,At.children)}else this.deactivateChildRoutes(G,F,K);else We&&this.deactivateRouteAndItsChildren(F,K)}deactivateRouteAndItsChildren(G,F){G.value.component&&this.routeReuseStrategy.shouldDetach(G.value.snapshot)?this.detachAndStoreRouteSubtree(G,F):this.deactivateRouteAndOutlet(G,F)}detachAndStoreRouteSubtree(G,F){const K=F.getContext(G.value.outlet),_e=K&&G.value.component?K.children:F,We=io(G);for(const At of Object.values(We))this.deactivateRouteAndItsChildren(At,_e);if(K&&K.outlet){const At=K.outlet.detach(),fn=K.children.onOutletDeactivated();this.routeReuseStrategy.store(G.value.snapshot,{componentRef:At,route:G,contexts:fn})}}deactivateRouteAndOutlet(G,F){const K=F.getContext(G.value.outlet),_e=K&&G.value.component?K.children:F,We=io(G);for(const At of Object.values(We))this.deactivateRouteAndItsChildren(At,_e);K&&(K.outlet&&(K.outlet.deactivate(),K.children.onOutletDeactivated()),K.attachRef=null,K.route=null)}activateChildRoutes(G,F,K){const _e=io(F);G.children.forEach(We=>{this.activateRoutes(We,_e[We.value.outlet],K),this.forwardEvent(new Mi(We.value.snapshot))}),G.children.length&&this.forwardEvent(new gi(G.value.snapshot))}activateRoutes(G,F,K){const _e=G.value,We=F?F.value:null;if(la(_e),_e===We)if(_e.component){const At=K.getOrCreateContext(_e.outlet);this.activateChildRoutes(G,F,At.children)}else this.activateChildRoutes(G,F,K);else if(_e.component){const At=K.getOrCreateContext(_e.outlet);if(this.routeReuseStrategy.shouldAttach(_e.snapshot)){const fn=this.routeReuseStrategy.retrieve(_e.snapshot);this.routeReuseStrategy.store(_e.snapshot,null),At.children.onOutletReAttached(fn.contexts),At.attachRef=fn.componentRef,At.route=fn.route.value,At.outlet&&At.outlet.attach(fn.componentRef,fn.route.value),la(fn.route.value),this.activateChildRoutes(G,null,At.children)}else At.attachRef=null,At.route=_e,At.outlet&&At.outlet.activateWith(_e,At.injector),this.activateChildRoutes(G,null,At.children)}else this.activateChildRoutes(G,null,K)}}class ot{path;route;constructor(G){this.path=G,this.route=this.path[this.path.length-1]}}class Ct{component;route;constructor(G,F){this.component=G,this.route=F}}function Bn(R,G,F){const K=R._root;return Qn(K,G?G._root:null,F,[K.value])}function Wn(R,G){const F=Symbol(),K=G.get(R,F);return K===F?"function"!=typeof R||(0,i.LfX)(R)?G.get(R):R:K}function Qn(R,G,F,K,_e={canDeactivateChecks:[],canActivateChecks:[]}){const We=io(G);return R.children.forEach(At=>{(function qr(R,G,F,K,_e={canDeactivateChecks:[],canActivateChecks:[]}){const We=R.value,At=G?G.value:null,fn=F?F.getContext(R.value.outlet):null;if(At&&We.routeConfig===At.routeConfig){const on=function zi(R,G,F){if("function"==typeof F)return F(R,G);switch(F){case"pathParamsChange":return!W(R.url,G.url);case"pathParamsOrQueryParamsChange":return!W(R.url,G.url)||!st(R.queryParams,G.queryParams);case"always":return!0;case"paramsOrQueryParamsChange":return!ls(R,G)||!st(R.queryParams,G.queryParams);default:return!ls(R,G)}}(At,We,We.routeConfig.runGuardsAndResolvers);on?_e.canActivateChecks.push(new ot(K)):(We.data=At.data,We._resolvedData=At._resolvedData),Qn(R,G,We.component?fn?fn.children:null:F,K,_e),on&&fn&&fn.outlet&&fn.outlet.isActivated&&_e.canDeactivateChecks.push(new Ct(fn.outlet.component,At))}else At&&Mr(G,fn,_e),_e.canActivateChecks.push(new ot(K)),Qn(R,null,We.component?fn?fn.children:null:F,K,_e)})(At,We[At.value.outlet],F,K.concat([At.value]),_e),delete We[At.value.outlet]}),Object.entries(We).forEach(([At,fn])=>Mr(fn,F.getContext(At),_e)),_e}function Mr(R,G,F){const K=io(R),_e=R.value;Object.entries(K).forEach(([We,At])=>{Mr(At,_e.component?G?G.children.getContext(We):null:G,F)}),F.canDeactivateChecks.push(new Ct(_e.component&&G&&G.outlet&&G.outlet.isActivated?G.outlet.component:null,_e))}function fi(R){return"function"==typeof R}function Ua(R){return R instanceof T.G||"EmptyError"===R?.name}const $a=Symbol("INITIAL_VALUE");function da(){return(0,me.n)(R=>(0,C.z)(R.map(G=>G.pipe((0,be.s)(1),(0,Oe.Z)($a)))).pipe((0,ae.T)(G=>{for(const F of G)if(!0!==F){if(F===$a)return $a;if(!1===F||de(F))return F}return!0}),(0,xe.p)(G=>G!==$a),(0,be.s)(1)))}function de(R){return Jt(R)||R instanceof Da}function ja(R){return(0,O.F)((0,Ce.M)(G=>{if("boolean"!=typeof G)throw Us(0,G)}),(0,ae.T)(G=>!0===G))}class cl{segmentGroup;constructor(G){this.segmentGroup=G||null}}class _i extends Error{urlTree;constructor(G){super(),this.urlTree=G}}function cs(R){return(0,L.$)(new cl(R))}class Pu{urlSerializer;urlTree;constructor(G,F){this.urlSerializer=G,this.urlTree=F}lineralizeSegments(G,F){let K=[],_e=F.root;for(;;){if(K=K.concat(_e.segments),0===_e.numberOfChildren)return(0,y.of)(K);if(_e.numberOfChildren>1||!_e.children[Ze])return(0,L.$)(new i.wOt(4e3,!1));_e=_e.children[Ze]}}applyRedirectCommands(G,F,K,_e,We){if("string"!=typeof F){const fn=F,{queryParams:on,fragment:ur,routeConfig:ui,url:kr,outlet:Gi,params:Is,data:is,title:Oa}=_e,us=(0,i.N4e)(We,()=>fn({params:Is,data:is,queryParams:on,fragment:ur,routeConfig:ui,url:kr,outlet:Gi,title:Oa}));if(us instanceof ke)throw new _i(us);F=us}const At=this.applyRedirectCreateUrlTree(F,this.urlSerializer.parse(F),G,K);if("/"===F[0])throw new _i(At);return At}applyRedirectCreateUrlTree(G,F,K,_e){const We=this.createSegmentGroup(G,F.root,K,_e);return new ke(We,this.createQueryParams(F.queryParams,this.urlTree.queryParams),F.fragment)}createQueryParams(G,F){const K={};return Object.entries(G).forEach(([_e,We])=>{if("string"==typeof We&&":"===We[0]){const fn=We.substring(1);K[_e]=F[fn]}else K[_e]=We}),K}createSegmentGroup(G,F,K,_e){const We=this.createSegments(G,F.segments,K,_e);let At={};return Object.entries(F.children).forEach(([fn,on])=>{At[fn]=this.createSegmentGroup(G,on,K,_e)}),new Je(We,At)}createSegments(G,F,K,_e){return F.map(We=>":"===We.path[0]?this.findPosParam(G,We,_e):this.findOrReturn(We,K))}findPosParam(G,F,K){const _e=K[F.path.substring(1)];if(!_e)throw new i.wOt(4001,!1);return _e}findOrReturn(G,F){let K=0;for(const _e of F){if(_e.path===G.path)return F.splice(K),_e;K++}return G}}const wl={matched:!1,consumedSegments:[],remainingSegments:[],parameters:{},positionalParamSegments:{}};function ul(R,G,F,K,_e){const We=yi(R,G,F);return We.matched?(K=function es(R,G){return R.providers&&!R._injector&&(R._injector=(0,i.Ol2)(R.providers,G,`Route: ${R.path}`)),R._injector??G}(G,K),function fc(R,G,F,K){const _e=G.canMatch;if(!_e||0===_e.length)return(0,y.of)(!0);const We=_e.map(At=>{const fn=Wn(At,R);return rt(function Ho(R){return R&&fi(R.canMatch)}(fn)?fn.canMatch(G,F):(0,i.N4e)(R,()=>fn(G,F)))});return(0,y.of)(We).pipe(da(),ja())}(K,G,F).pipe((0,ae.T)(At=>!0===At?We:{...wl}))):(0,y.of)(We)}function yi(R,G,F){if("**"===G.path)return function Il(R){return{matched:!0,parameters:R.length>0?Kt(R).parameters:{},consumedSegments:R,remainingSegments:[],positionalParamSegments:{}}}(F);if(""===G.path)return"full"===G.pathMatch&&(R.hasChildren()||F.length>0)?{...wl}:{matched:!0,consumedSegments:[],remainingSegments:F,parameters:{},positionalParamSegments:{}};const _e=(G.matcher||Te)(F,R,G);if(!_e)return{...wl};const We={};Object.entries(_e.posParams??{}).forEach(([fn,on])=>{We[fn]=on.path});const At=_e.consumed.length>0?{...We,..._e.consumed[_e.consumed.length-1].parameters}:We;return{matched:!0,consumedSegments:_e.consumed,remainingSegments:F.slice(_e.consumed.length),parameters:At,positionalParamSegments:_e.posParams??{}}}function eu(R,G,F,K){return F.length>0&&function $s(R,G,F){return F.some(K=>Sa(R,G,K)&&No(K)!==Ze)}(R,F,K)?{segmentGroup:new Je(G,dl(K,new Je(F,R.children))),slicedSegments:[]}:0===F.length&&function Ol(R,G,F){return F.some(K=>Sa(R,G,K))}(R,F,K)?{segmentGroup:new Je(R.segments,tu(R,F,K,R.children)),slicedSegments:F}:{segmentGroup:new Je(R.segments,R.children),slicedSegments:F}}function tu(R,G,F,K){const _e={};for(const We of F)if(Sa(R,G,We)&&!K[No(We)]){const At=new Je([],{});_e[No(We)]=At}return{...K,..._e}}function dl(R,G){const F={};F[Ze]=G;for(const K of R)if(""===K.path&&No(K)!==Ze){const _e=new Je([],{});F[No(K)]=_e}return F}function Sa(R,G,F){return(!(R.hasChildren()||G.length>0)||"full"!==F.pathMatch)&&""===F.path}class js{}class ru{injector;configLoader;rootComponentType;config;urlTree;paramsInheritanceStrategy;urlSerializer;applyRedirects;absoluteRedirectCount=0;allowRedirects=!0;constructor(G,F,K,_e,We,At,fn){this.injector=G,this.configLoader=F,this.rootComponentType=K,this.config=_e,this.urlTree=We,this.paramsInheritanceStrategy=At,this.urlSerializer=fn,this.applyRedirects=new Pu(this.urlSerializer,this.urlTree)}noMatchError(G){return new i.wOt(4002,`'${G.segmentGroup}'`)}recognize(){const G=eu(this.urlTree.root,[],[],this.config).segmentGroup;return this.match(G).pipe((0,ae.T)(({children:F,rootSnapshot:K})=>{const _e=new go(K,F),We=new As("",_e),At=function Tt(R,G,F=null,K=null){return Rt(nt(R),G,F,K)}(K,[],this.urlTree.queryParams,this.urlTree.fragment);return At.queryParams=this.urlTree.queryParams,We.url=this.urlSerializer.serialize(At),{state:We,tree:At}}))}match(G){const F=new lr([],Object.freeze({}),Object.freeze({...this.urlTree.queryParams}),this.urlTree.fragment,Object.freeze({}),Ze,this.rootComponentType,null,{});return this.processSegmentGroup(this.injector,this.config,G,Ze,F).pipe((0,ae.T)(K=>({children:K,rootSnapshot:F})),(0,Be.W)(K=>{if(K instanceof _i)return this.urlTree=K.urlTree,this.match(K.urlTree.root);throw K instanceof cl?this.noMatchError(K):K}))}processSegmentGroup(G,F,K,_e,We){return 0===K.segments.length&&K.hasChildren()?this.processChildren(G,F,K,We):this.processSegment(G,F,K,K.segments,_e,!0,We).pipe((0,ae.T)(At=>At instanceof go?[At]:[]))}processChildren(G,F,K,_e){const We=[];for(const At of Object.keys(K.children))"primary"===At?We.unshift(At):We.push(At);return(0,c.H)(We).pipe((0,ue.H)(At=>{const fn=K.children[At],on=function hs(R,G){const F=R.filter(K=>No(K)===G);return F.push(...R.filter(K=>No(K)!==G)),F}(F,At);return this.processSegmentGroup(G,on,fn,At,_e)}),function bt(R,G){return(0,at.N)((0,dt.S)(R,G,arguments.length>=2,!0))}((At,fn)=>(At.push(...fn),At)),(0,lt.U)(null),function yn(R,G){const F=arguments.length>=2;return K=>K.pipe(R?(0,xe.p)((_e,We)=>R(_e,We,K)):Vn.D,gn(1),F?(0,lt.U)(G):(0,bn.v)(()=>new T.G))}(),(0,De.Z)(At=>{if(null===At)return cs(K);const fn=jl(At);return function Mc(R){R.sort((G,F)=>G.value.outlet===Ze?-1:F.value.outlet===Ze?1:G.value.outlet.localeCompare(F.value.outlet))}(fn),(0,y.of)(fn)}))}processSegment(G,F,K,_e,We,At,fn){return(0,c.H)(F).pipe((0,ue.H)(on=>this.processSegmentAgainstRoute(on._injector??G,F,on,K,_e,We,At,fn).pipe((0,Be.W)(ur=>{if(ur instanceof cl)return(0,y.of)(null);throw ur}))),(0,ce.$)(on=>!!on),(0,Be.W)(on=>{if(Ua(on))return function ks(R,G,F){return 0===G.length&&!R.children[F]}(K,_e,We)?(0,y.of)(new js):cs(K);throw on}))}processSegmentAgainstRoute(G,F,K,_e,We,At,fn,on){return No(K)===At||At!==Ze&&Sa(_e,We,K)?void 0===K.redirectTo?this.matchSegmentAgainstRoute(G,_e,K,We,At,on):this.allowRedirects&&fn?this.expandSegmentAgainstRouteUsingRedirect(G,_e,F,K,We,At,on):cs(_e):cs(_e)}expandSegmentAgainstRouteUsingRedirect(G,F,K,_e,We,At,fn){const{matched:on,parameters:ur,consumedSegments:ui,positionalParamSegments:kr,remainingSegments:Gi}=yi(F,_e,We);if(!on)return cs(F);"string"==typeof _e.redirectTo&&"/"===_e.redirectTo[0]&&(this.absoluteRedirectCount++,this.absoluteRedirectCount>31&&(this.allowRedirects=!1));const Is=new lr(We,ur,Object.freeze({...this.urlTree.queryParams}),this.urlTree.fragment,Vl(_e),No(_e),_e.component??_e._loadedComponent??null,_e,Hl(_e)),is=Ao(Is,fn,this.paramsInheritanceStrategy);Is.params=Object.freeze(is.params),Is.data=Object.freeze(is.data);const Oa=this.applyRedirects.applyRedirectCommands(ui,_e.redirectTo,kr,Is,G);return this.applyRedirects.lineralizeSegments(_e,Oa).pipe((0,De.Z)(us=>this.processSegment(G,K,F,us.concat(Gi),At,!1,fn)))}matchSegmentAgainstRoute(G,F,K,_e,We,At){const fn=ul(F,K,_e,G);return"**"===K.path&&(F.children={}),fn.pipe((0,me.n)(on=>on.matched?this.getChildConfig(G=K._injector??G,K,_e).pipe((0,me.n)(({routes:ur})=>{const ui=K._loadedInjector??G,{parameters:kr,consumedSegments:Gi,remainingSegments:Is}=on,is=new lr(Gi,kr,Object.freeze({...this.urlTree.queryParams}),this.urlTree.fragment,Vl(K),No(K),K.component??K._loadedComponent??null,K,Hl(K)),Oa=Ao(is,At,this.paramsInheritanceStrategy);is.params=Object.freeze(Oa.params),is.data=Object.freeze(Oa.data);const{segmentGroup:us,slicedSegments:Wr}=eu(F,Gi,Is,ur);if(0===Wr.length&&us.hasChildren())return this.processChildren(ui,ur,us,is).pipe((0,ae.T)(Ka=>new go(is,Ka)));if(0===ur.length&&0===Wr.length)return(0,y.of)(new go(is,[]));const Ys=No(K)===We;return this.processSegment(ui,ur,us,Wr,Ys?Ze:We,!0,is).pipe((0,ae.T)(Ka=>new go(is,Ka instanceof go?[Ka]:[])))})):cs(F)))}getChildConfig(G,F,K){return F.children?(0,y.of)({routes:F.children,injector:G}):F.loadChildren?void 0!==F._loadedRoutes?(0,y.of)({routes:F._loadedRoutes,injector:F._loadedInjector}):function yl(R,G,F,K){const _e=G.canLoad;if(void 0===_e||0===_e.length)return(0,y.of)(!0);const We=_e.map(At=>{const fn=Wn(At,R);return rt(function di(R){return R&&fi(R.canLoad)}(fn)?fn.canLoad(G,F):(0,i.N4e)(R,()=>fn(G,F)))});return(0,y.of)(We).pipe(da(),ja())}(G,F,K).pipe((0,De.Z)(_e=>_e?this.configLoader.loadChildren(G,F).pipe((0,Ce.M)(We=>{F._loadedRoutes=We.routes,F._loadedInjector=We.injector})):function bl(){return(0,L.$)(ua(!1,Ne.GuardRejected))}())):(0,y.of)({routes:[],injector:G})}}function El(R){const G=R.value.routeConfig;return G&&""===G.path}function jl(R){const G=[],F=new Set;for(const K of R){if(!El(K)){G.push(K);continue}const _e=G.find(We=>K.value.routeConfig===We.value.routeConfig);void 0!==_e?(_e.children.push(...K.children),F.add(_e)):G.push(K)}for(const K of F){const _e=jl(K.children);G.push(new go(K.value,_e))}return G.filter(K=>!F.has(K))}function Vl(R){return R.data||{}}function Hl(R){return R.resolve||{}}function Vo(R){const G=R.children.map(F=>Vo(F)).flat();return[R,...G]}function Sr(R){return(0,me.n)(G=>{const F=R(G);return F?(0,c.H)(F).pipe((0,ae.T)(()=>G)):(0,y.of)(G)})}let Oi=(()=>{class R{buildTitle(F){let K,_e=F.root;for(;void 0!==_e;)K=this.getResolvedTitleForRoute(_e)??K,_e=_e.children.find(We=>We.outlet===Ze);return K}getResolvedTitleForRoute(F){return F.data[it]}static \u0275fac=function(K){return new(K||R)};static \u0275prov=i.jDH({token:R,factory:()=>(0,i.WQX)(ys),providedIn:"root"})}return R})(),ys=(()=>{class R extends Oi{title;constructor(F){super(),this.title=F}updateTitle(F){const K=this.buildTitle(F);void 0!==K&&this.title.setTitle(K)}static \u0275fac=function(K){return new(K||R)(i.KVO(Ke.hE))};static \u0275prov=i.jDH({token:R,factory:R.\u0275fac,providedIn:"root"})}return R})();const Qi=new i.nKC("",{providedIn:"root",factory:()=>({})});let so=(()=>{class R{static \u0275fac=function(K){return new(K||R)};static \u0275cmp=i.VBU({type:R,selectors:[["ng-component"]],decls:1,vars:0,template:function(K,_e){1&K&&i.nrm(0,"router-outlet")},dependencies:[ca],encapsulation:2})}return R})();function Bi(R){const G=R.children&&R.children.map(Bi),F=G?{...R,children:G}:{...R};return!F.component&&!F.loadComponent&&(G||F.loadChildren)&&F.outlet&&F.outlet!==Ze&&(F.component=so),F}const Ki=new i.nKC("");let no=(()=>{class R{componentLoaders=new WeakMap;childrenLoaders=new WeakMap;onLoadStartListener;onLoadEndListener;compiler=(0,i.WQX)(i.Ql9);loadComponent(F){if(this.componentLoaders.get(F))return this.componentLoaders.get(F);if(F._loadedComponent)return(0,y.of)(F._loadedComponent);this.onLoadStartListener&&this.onLoadStartListener(F);const K=rt(F.loadComponent()).pipe((0,ae.T)(Xs),(0,Ce.M)(We=>{this.onLoadEndListener&&this.onLoadEndListener(F),F._loadedComponent=We}),(0,_t.j)(()=>{this.componentLoaders.delete(F)})),_e=new q.G(K,()=>new re.B).pipe((0,ze.B)());return this.componentLoaders.set(F,_e),_e}loadChildren(F,K){if(this.childrenLoaders.get(K))return this.childrenLoaders.get(K);if(K._loadedRoutes)return(0,y.of)({routes:K._loadedRoutes,injector:K._loadedInjector});this.onLoadStartListener&&this.onLoadStartListener(K);const We=function co(R,G,F,K){return rt(R.loadChildren()).pipe((0,ae.T)(Xs),(0,De.Z)(_e=>_e instanceof i.Co$||Array.isArray(_e)?(0,y.of)(_e):(0,c.H)(G.compileModuleAsync(_e))),(0,ae.T)(_e=>{K&&K(R);let We,At,fn=!1;return Array.isArray(_e)?(At=_e,!0):(We=_e.create(F).injector,At=We.get(Ki,[],{optional:!0,self:!0}).flat()),{routes:At.map(Bi),injector:We}}))}(K,this.compiler,F,this.onLoadEndListener).pipe((0,_t.j)(()=>{this.childrenLoaders.delete(K)})),At=new q.G(We,()=>new re.B).pipe((0,ze.B)());return this.childrenLoaders.set(K,At),At}static \u0275fac=function(K){return new(K||R)};static \u0275prov=i.jDH({token:R,factory:R.\u0275fac,providedIn:"root"})}return R})();function Xs(R){return function ri(R){return R&&"object"==typeof R&&"default"in R}(R)?R.default:R}let Za=(()=>{class R{static \u0275fac=function(K){return new(K||R)};static \u0275prov=i.jDH({token:R,factory:()=>(0,i.WQX)(Uo),providedIn:"root"})}return R})(),Uo=(()=>{class R{shouldProcessUrl(F){return!0}extract(F){return F}merge(F,K){return F}static \u0275fac=function(K){return new(K||R)};static \u0275prov=i.jDH({token:R,factory:R.\u0275fac,providedIn:"root"})}return R})();const vo=new i.nKC(""),Ci=new i.nKC("");function Vs(R,G,F){const K=R.get(Ci),_e=R.get(se.qQ);return R.get(i.SKi).runOutsideAngular(()=>{if(!_e.startViewTransition||K.skipNextTransition)return K.skipNextTransition=!1,new Promise(ur=>setTimeout(ur));let We;const At=new Promise(ur=>{We=ur}),fn=_e.startViewTransition(()=>(We(),function uo(R){return new Promise(G=>{(0,i.mal)({read:()=>setTimeout(G)},{injector:R})})}(R))),{onViewTransitionCreated:on}=K;return on&&(0,i.N4e)(R,()=>on({transition:fn,from:G,to:F})),At})}const Ui=new i.nKC("");let U=(()=>{class R{currentNavigation=null;currentTransition=null;lastSuccessfulNavigation=null;events=new re.B;transitionAbortSubject=new re.B;configLoader=(0,i.WQX)(no);environmentInjector=(0,i.WQX)(i.uvJ);urlSerializer=(0,i.WQX)(ft);rootContexts=(0,i.WQX)(Go);location=(0,i.WQX)(se.aZ);inputBindingEnabled=null!==(0,i.WQX)(Ts,{optional:!0});titleStrategy=(0,i.WQX)(Oi);options=(0,i.WQX)(Qi,{optional:!0})||{};paramsInheritanceStrategy=this.options.paramsInheritanceStrategy||"emptyOnly";urlHandlingStrategy=(0,i.WQX)(Za);createViewTransition=(0,i.WQX)(vo,{optional:!0});navigationErrorHandler=(0,i.WQX)(Ui,{optional:!0});navigationId=0;get hasRequestedNavigation(){return 0!==this.navigationId}transitions;afterPreactivation=()=>(0,y.of)(void 0);rootComponentType=null;constructor(){this.configLoader.onLoadEndListener=_e=>this.events.next(new wr(_e)),this.configLoader.onLoadStartListener=_e=>this.events.next(new ar(_e))}complete(){this.transitions?.complete()}handleNavigationRequest(F){const K=++this.navigationId;this.transitions?.next({...this.transitions.value,...F,id:K})}setupNavigations(F,K,_e){return this.transitions=new w.t({id:0,currentUrlTree:K,currentRawUrl:K,extractedUrl:this.urlHandlingStrategy.extract(K),urlAfterRedirects:this.urlHandlingStrategy.extract(K),rawUrl:K,extras:{},resolve:()=>{},reject:()=>{},promise:Promise.resolve(!0),source:tt,restoredState:null,currentSnapshot:_e.snapshot,targetSnapshot:null,currentRouterState:_e,targetRouterState:null,guards:{canActivateChecks:[],canDeactivateChecks:[]},guardsResult:null}),this.transitions.pipe((0,xe.p)(We=>0!==We.id),(0,ae.T)(We=>({...We,extractedUrl:this.urlHandlingStrategy.extract(We.rawUrl)})),(0,me.n)(We=>{let At=!1,fn=!1;return(0,y.of)(We).pipe((0,me.n)(on=>{if(this.navigationId>We.id)return this.cancelNavigationTransition(We,"",Ne.SupersededByNewNavigation),Z.w;this.currentTransition=We,this.currentNavigation={id:on.id,initialUrl:on.rawUrl,extractedUrl:on.extractedUrl,targetBrowserUrl:"string"==typeof on.extras.browserUrl?this.urlSerializer.parse(on.extras.browserUrl):on.extras.browserUrl,trigger:on.source,extras:on.extras,previousNavigation:this.lastSuccessfulNavigation?{...this.lastSuccessfulNavigation,previousNavigation:null}:null};const ur=!F.navigated||this.isUpdatingInternalState()||this.isUpdatedBrowserUrl();if(!ur&&"reload"!==(on.extras.onSameUrlNavigation??F.onSameUrlNavigation)){const kr="";return this.events.next(new kt(on.id,this.urlSerializer.serialize(on.rawUrl),kr,gt.IgnoredSameUrlNavigation)),on.resolve(!1),Z.w}if(this.urlHandlingStrategy.shouldProcessUrl(on.rawUrl))return(0,y.of)(on).pipe((0,me.n)(kr=>{const Gi=this.transitions?.getValue();return this.events.next(new ve(kr.id,this.urlSerializer.serialize(kr.extractedUrl),kr.source,kr.restoredState)),Gi!==this.transitions?.getValue()?Z.w:Promise.resolve(kr)}),function ha(R,G,F,K,_e,We){return(0,De.Z)(At=>function nu(R,G,F,K,_e,We,At="emptyOnly"){return new ru(R,G,F,K,_e,At,We).recognize()}(R,G,F,K,At.extractedUrl,_e,We).pipe((0,ae.T)(({state:fn,tree:on})=>({...At,targetSnapshot:fn,urlAfterRedirects:on}))))}(this.environmentInjector,this.configLoader,this.rootComponentType,F.config,this.urlSerializer,this.paramsInheritanceStrategy),(0,Ce.M)(kr=>{We.targetSnapshot=kr.targetSnapshot,We.urlAfterRedirects=kr.urlAfterRedirects,this.currentNavigation={...this.currentNavigation,finalUrl:kr.urlAfterRedirects};const Gi=new Dn(kr.id,this.urlSerializer.serialize(kr.extractedUrl),this.urlSerializer.serialize(kr.urlAfterRedirects),kr.targetSnapshot);this.events.next(Gi)}));if(ur&&this.urlHandlingStrategy.shouldProcessUrl(on.currentRawUrl)){const{id:kr,extractedUrl:Gi,source:Is,restoredState:is,extras:Oa}=on,us=new ve(kr,this.urlSerializer.serialize(Gi),Is,is);this.events.next(us);const Wr=Xo(this.rootComponentType).snapshot;return this.currentTransition=We={...on,targetSnapshot:Wr,urlAfterRedirects:Gi,extras:{...Oa,skipLocationChange:!1,replaceUrl:!1}},this.currentNavigation.finalUrl=Gi,(0,y.of)(We)}{const kr="";return this.events.next(new kt(on.id,this.urlSerializer.serialize(on.extractedUrl),kr,gt.IgnoredByUrlHandlingStrategy)),on.resolve(!1),Z.w}}),(0,Ce.M)(on=>{const ur=new Cn(on.id,this.urlSerializer.serialize(on.extractedUrl),this.urlSerializer.serialize(on.urlAfterRedirects),on.targetSnapshot);this.events.next(ur)}),(0,ae.T)(on=>(this.currentTransition=We={...on,guards:Bn(on.targetSnapshot,on.currentSnapshot,this.rootContexts)},We)),function he(R,G){return(0,De.Z)(F=>{const{targetSnapshot:K,currentSnapshot:_e,guards:{canActivateChecks:We,canDeactivateChecks:At}}=F;return 0===At.length&&0===We.length?(0,y.of)({...F,guardsResult:!0}):function Y(R,G,F,K){return(0,c.H)(R).pipe((0,De.Z)(_e=>function kl(R,G,F,K,_e){const We=G&&G.routeConfig?G.routeConfig.canDeactivate:null;if(!We||0===We.length)return(0,y.of)(!0);const At=We.map(fn=>{const on=Ko(G)??_e,ur=Wn(fn,on);return rt(function jo(R){return R&&fi(R.canDeactivate)}(ur)?ur.canDeactivate(R,G,F,K):(0,i.N4e)(on,()=>ur(R,G,F,K))).pipe((0,ce.$)())});return(0,y.of)(At).pipe(da())}(_e.component,_e.route,F,G,K)),(0,ce.$)(_e=>!0!==_e,!0))}(At,K,_e,R).pipe((0,De.Z)(fn=>fn&&function zr(R){return"boolean"==typeof R}(fn)?function Ue(R,G,F,K){return(0,c.H)(G).pipe((0,ue.H)(_e=>(0,S.x)(function br(R,G){return null!==R&&G&&G(new xr(R)),(0,y.of)(!0)}(_e.route.parent,K),function jt(R,G){return null!==R&&G&&G(new ni(R)),(0,y.of)(!0)}(_e.route,K),function ts(R,G,F){const K=G[G.length-1],We=G.slice(0,G.length-1).reverse().map(At=>function On(R){const G=R.routeConfig?R.routeConfig.canActivateChild:null;return G&&0!==G.length?{node:R,guards:G}:null}(At)).filter(At=>null!==At).map(At=>(0,M.v)(()=>{const fn=At.guards.map(on=>{const ur=Ko(At.node)??F,ui=Wn(on,ur);return rt(function Ro(R){return R&&fi(R.canActivateChild)}(ui)?ui.canActivateChild(K,R):(0,i.N4e)(ur,()=>ui(K,R))).pipe((0,ce.$)())});return(0,y.of)(fn).pipe(da())}));return(0,y.of)(We).pipe(da())}(R,_e.path,F),function Jr(R,G,F){const K=G.routeConfig?G.routeConfig.canActivate:null;if(!K||0===K.length)return(0,y.of)(!0);const _e=K.map(We=>(0,M.v)(()=>{const At=Ko(G)??F,fn=Wn(We,At);return rt(function Fi(R){return R&&fi(R.canActivate)}(fn)?fn.canActivate(G,R):(0,i.N4e)(At,()=>fn(G,R))).pipe((0,ce.$)())}));return(0,y.of)(_e).pipe(da())}(R,_e.route,F))),(0,ce.$)(_e=>!0!==_e,!0))}(K,We,R,G):(0,y.of)(fn)),(0,ae.T)(fn=>({...F,guardsResult:fn})))})}(this.environmentInjector,on=>this.events.next(on)),(0,Ce.M)(on=>{if(We.guardsResult=on.guardsResult,on.guardsResult&&"boolean"!=typeof on.guardsResult)throw Us(0,on.guardsResult);const ur=new Nn(on.id,this.urlSerializer.serialize(on.extractedUrl),this.urlSerializer.serialize(on.urlAfterRedirects),on.targetSnapshot,!!on.guardsResult);this.events.next(ur)}),(0,xe.p)(on=>!!on.guardsResult||(this.cancelNavigationTransition(on,"",Ne.GuardRejected),!1)),Sr(on=>{if(on.guards.canActivateChecks.length)return(0,y.of)(on).pipe((0,Ce.M)(ur=>{const ui=new jn(ur.id,this.urlSerializer.serialize(ur.extractedUrl),this.urlSerializer.serialize(ur.urlAfterRedirects),ur.targetSnapshot);this.events.next(ui)}),(0,me.n)(ur=>{let ui=!1;return(0,y.of)(ur).pipe(function iu(R,G){return(0,De.Z)(F=>{const{targetSnapshot:K,guards:{canActivateChecks:_e}}=F;if(!_e.length)return(0,y.of)(F);const We=new Set(_e.map(on=>on.route)),At=new Set;for(const on of We)if(!At.has(on))for(const ur of Vo(on))At.add(ur);let fn=0;return(0,c.H)(At).pipe((0,ue.H)(on=>We.has(on)?function Wo(R,G,F,K){const _e=R.routeConfig,We=R._resolve;return void 0!==_e?.title&&!Vi(_e)&&(We[it]=_e.title),function oo(R,G,F,K){const _e=Xt(R);if(0===_e.length)return(0,y.of)({});const We={};return(0,c.H)(_e).pipe((0,De.Z)(At=>function Fn(R,G,F,K){const _e=Ko(G)??K,We=Wn(R,_e);return rt(We.resolve?We.resolve(G,F):(0,i.N4e)(_e,()=>We(G,F)))}(R[At],G,F,K).pipe((0,ce.$)(),(0,Ce.M)(fn=>{if(fn instanceof Da)throw Us(new mt,fn);We[At]=fn}))),gn(1),(0,qe.u)(We),(0,Be.W)(At=>Ua(At)?Z.w:(0,L.$)(At)))}(We,R,G,K).pipe((0,ae.T)(At=>(R._resolvedData=At,R.data=Ao(R,R.parent,F).resolve,null)))}(on,K,R,G):(on.data=Ao(on,on.parent,R).resolve,(0,y.of)(void 0))),(0,Ce.M)(()=>fn++),gn(1),(0,De.Z)(on=>fn===At.size?(0,y.of)(F):Z.w))})}(this.paramsInheritanceStrategy,this.environmentInjector),(0,Ce.M)({next:()=>ui=!0,complete:()=>{ui||this.cancelNavigationTransition(ur,"",Ne.NoDataFromResolver)}}))}),(0,Ce.M)(ur=>{const ui=new Jn(ur.id,this.urlSerializer.serialize(ur.extractedUrl),this.urlSerializer.serialize(ur.urlAfterRedirects),ur.targetSnapshot);this.events.next(ui)}))}),Sr(on=>{const ur=ui=>{const kr=[];ui.routeConfig?.loadComponent&&!ui.routeConfig._loadedComponent&&kr.push(this.configLoader.loadComponent(ui.routeConfig).pipe((0,Ce.M)(Gi=>{ui.component=Gi}),(0,ae.T)(()=>{})));for(const Gi of ui.children)kr.push(...ur(Gi));return kr};return(0,C.z)(ur(on.targetSnapshot.root)).pipe((0,lt.U)(null),(0,be.s)(1))}),Sr(()=>this.afterPreactivation()),(0,me.n)(()=>{const{currentSnapshot:on,targetSnapshot:ur}=We,ui=this.createViewTransition?.(this.environmentInjector,on.root,ur.root);return ui?(0,c.H)(ui).pipe((0,ae.T)(()=>We)):(0,y.of)(We)}),(0,ae.T)(on=>{const ur=function So(R,G,F){const K=Bo(R,G._root,F?F._root:void 0);return new fs(K,G)}(F.routeReuseStrategy,on.targetSnapshot,on.currentRouterState);return this.currentTransition=We={...on,targetRouterState:ur},this.currentNavigation.targetRouterState=ur,We}),(0,Ce.M)(()=>{this.events.next(new Qr)}),((R,G,F,K)=>(0,ae.T)(_e=>(new te(G,_e.targetRouterState,_e.currentRouterState,F,K).activate(R),_e)))(this.rootContexts,F.routeReuseStrategy,on=>this.events.next(on),this.inputBindingEnabled),(0,be.s)(1),(0,Ce.M)({next:on=>{At=!0,this.lastSuccessfulNavigation=this.currentNavigation,this.events.next(new Ye(on.id,this.urlSerializer.serialize(on.extractedUrl),this.urlSerializer.serialize(on.urlAfterRedirects))),this.titleStrategy?.updateTitle(on.targetRouterState.snapshot),on.resolve(!0)},complete:()=>{At=!0}}),(0,$e.Q)(this.transitionAbortSubject.pipe((0,Ce.M)(on=>{throw on}))),(0,_t.j)(()=>{!At&&!fn&&this.cancelNavigationTransition(We,"",Ne.SupersededByNewNavigation),this.currentTransition?.id===We.id&&(this.currentNavigation=null,this.currentTransition=null)}),(0,Be.W)(on=>{if(fn=!0,Aa(on))this.events.next(new Ht(We.id,this.urlSerializer.serialize(We.extractedUrl),on.message,on.cancellationCode)),function Ba(R){return Aa(R)&&Jt(R.url)}(on)?this.events.next(new Pr(on.url,on.navigationBehaviorOptions)):We.resolve(!1);else{const ur=new hn(We.id,this.urlSerializer.serialize(We.extractedUrl),on,We.targetSnapshot??void 0);try{const ui=(0,i.N4e)(this.environmentInjector,()=>this.navigationErrorHandler?.(ur));if(!(ui instanceof Da))throw this.events.next(ur),on;{const{message:kr,cancellationCode:Gi}=Us(0,ui);this.events.next(new Ht(We.id,this.urlSerializer.serialize(We.extractedUrl),kr,Gi)),this.events.next(new Pr(ui.redirectTo,ui.navigationBehaviorOptions))}}catch(ui){this.options.resolveNavigationPromiseOnError?We.resolve(!1):We.reject(ui)}}return Z.w}))}))}cancelNavigationTransition(F,K,_e){const We=new Ht(F.id,this.urlSerializer.serialize(F.extractedUrl),K,_e);this.events.next(We),F.resolve(!1)}isUpdatingInternalState(){return this.currentTransition?.extractedUrl.toString()!==this.currentTransition?.currentUrlTree.toString()}isUpdatedBrowserUrl(){const F=this.urlHandlingStrategy.extract(this.urlSerializer.parse(this.location.path(!0))),K=this.currentNavigation?.targetBrowserUrl??this.currentNavigation?.extractedUrl;return F.toString()!==K?.toString()&&!this.currentNavigation?.extras.skipLocationChange}static \u0275fac=function(K){return new(K||R)};static \u0275prov=i.jDH({token:R,factory:R.\u0275fac,providedIn:"root"})}return R})();function Ie(R){return R!==tt}let ne=(()=>{class R{static \u0275fac=function(K){return new(K||R)};static \u0275prov=i.jDH({token:R,factory:()=>(0,i.WQX)(Et),providedIn:"root"})}return R})();class ye{shouldDetach(G){return!1}store(G,F){}shouldAttach(G){return!1}retrieve(G){return null}shouldReuseRoute(G,F){return G.routeConfig===F.routeConfig}}let Et=(()=>{class R extends ye{static \u0275fac=(()=>{let F;return function(_e){return(F||(F=i.xGo(R)))(_e||R)}})();static \u0275prov=i.jDH({token:R,factory:R.\u0275fac,providedIn:"root"})}return R})(),Gt=(()=>{class R{static \u0275fac=function(K){return new(K||R)};static \u0275prov=i.jDH({token:R,factory:()=>(0,i.WQX)(Un),providedIn:"root"})}return R})(),Un=(()=>{class R extends Gt{location=(0,i.WQX)(se.aZ);urlSerializer=(0,i.WQX)(ft);options=(0,i.WQX)(Qi,{optional:!0})||{};canceledNavigationResolution=this.options.canceledNavigationResolution||"replace";urlHandlingStrategy=(0,i.WQX)(Za);urlUpdateStrategy=this.options.urlUpdateStrategy||"deferred";currentUrlTree=new ke;getCurrentUrlTree(){return this.currentUrlTree}rawUrlTree=this.currentUrlTree;getRawUrlTree(){return this.rawUrlTree}currentPageId=0;lastSuccessfulId=-1;restoredState(){return this.location.getState()}get browserPageId(){return"computed"!==this.canceledNavigationResolution?this.currentPageId:this.restoredState()?.\u0275routerPageId??this.currentPageId}routerState=Xo(null);getRouterState(){return this.routerState}stateMemento=this.createStateMemento();createStateMemento(){return{rawUrlTree:this.rawUrlTree,currentUrlTree:this.currentUrlTree,routerState:this.routerState}}registerNonRouterCurrentEntryChangeListener(F){return this.location.subscribe(K=>{"popstate"===K.type&&F(K.url,K.state)})}handleRouterEvent(F,K){if(F instanceof ve)this.stateMemento=this.createStateMemento();else if(F instanceof kt)this.rawUrlTree=K.initialUrl;else if(F instanceof Dn){if("eager"===this.urlUpdateStrategy&&!K.extras.skipLocationChange){const _e=this.urlHandlingStrategy.merge(K.finalUrl,K.initialUrl);this.setBrowserUrl(K.targetBrowserUrl??_e,K)}}else F instanceof Qr?(this.currentUrlTree=K.finalUrl,this.rawUrlTree=this.urlHandlingStrategy.merge(K.finalUrl,K.initialUrl),this.routerState=K.targetRouterState,"deferred"===this.urlUpdateStrategy&&!K.extras.skipLocationChange&&this.setBrowserUrl(K.targetBrowserUrl??this.rawUrlTree,K)):F instanceof Ht&&(F.code===Ne.GuardRejected||F.code===Ne.NoDataFromResolver)?this.restoreHistory(K):F instanceof hn?this.restoreHistory(K,!0):F instanceof Ye&&(this.lastSuccessfulId=F.id,this.currentPageId=this.browserPageId)}setBrowserUrl(F,K){const _e=F instanceof ke?this.urlSerializer.serialize(F):F;if(this.location.isCurrentPathEqualTo(_e)||K.extras.replaceUrl){const At={...K.extras.state,...this.generateNgRouterState(K.id,this.browserPageId)};this.location.replaceState(_e,"",At)}else{const We={...K.extras.state,...this.generateNgRouterState(K.id,this.browserPageId+1)};this.location.go(_e,"",We)}}restoreHistory(F,K=!1){if("computed"===this.canceledNavigationResolution){const We=this.currentPageId-this.browserPageId;0!==We?this.location.historyGo(We):this.currentUrlTree===F.finalUrl&&0===We&&(this.resetState(F),this.resetUrlToCurrentUrlTree())}else"replace"===this.canceledNavigationResolution&&(K&&this.resetState(F),this.resetUrlToCurrentUrlTree())}resetState(F){this.routerState=this.stateMemento.routerState,this.currentUrlTree=this.stateMemento.currentUrlTree,this.rawUrlTree=this.urlHandlingStrategy.merge(this.currentUrlTree,F.finalUrl??this.rawUrlTree)}resetUrlToCurrentUrlTree(){this.location.replaceState(this.urlSerializer.serialize(this.rawUrlTree),"",this.generateNgRouterState(this.lastSuccessfulId,this.currentPageId))}generateNgRouterState(F,K){return"computed"===this.canceledNavigationResolution?{navigationId:F,\u0275routerPageId:K}:{navigationId:F}}static \u0275fac=(()=>{let F;return function(_e){return(F||(F=i.xGo(R)))(_e||R)}})();static \u0275prov=i.jDH({token:R,factory:R.\u0275fac,providedIn:"root"})}return R})();var tr=function(R){return R[R.COMPLETE=0]="COMPLETE",R[R.FAILED=1]="FAILED",R[R.REDIRECTING=2]="REDIRECTING",R}(tr||{});function ci(R,G){R.events.pipe((0,xe.p)(F=>F instanceof Ye||F instanceof Ht||F instanceof hn||F instanceof kt),(0,ae.T)(F=>F instanceof Ye||F instanceof kt?tr.COMPLETE:F instanceof Ht&&(F.code===Ne.Redirect||F.code===Ne.SupersededByNewNavigation)?tr.REDIRECTING:tr.FAILED),(0,xe.p)(F=>F!==tr.REDIRECTING),(0,be.s)(1)).subscribe(()=>{G()})}const Di={paths:"exact",fragment:"ignored",matrixParams:"ignored",queryParams:"exact"},Rr={paths:"subset",fragment:"ignored",matrixParams:"ignored",queryParams:"subset"};let li=(()=>{class R{get currentUrlTree(){return this.stateManager.getCurrentUrlTree()}get rawUrlTree(){return this.stateManager.getRawUrlTree()}disposed=!1;nonRouterCurrentEntryChangeSubscription;console=(0,i.WQX)(i.H3F);stateManager=(0,i.WQX)(Gt);options=(0,i.WQX)(Qi,{optional:!0})||{};pendingTasks=(0,i.WQX)(i.TgB);urlUpdateStrategy=this.options.urlUpdateStrategy||"deferred";navigationTransitions=(0,i.WQX)(U);urlSerializer=(0,i.WQX)(ft);location=(0,i.WQX)(se.aZ);urlHandlingStrategy=(0,i.WQX)(Za);_events=new re.B;get events(){return this._events}get routerState(){return this.stateManager.getRouterState()}navigated=!1;routeReuseStrategy=(0,i.WQX)(ne);onSameUrlNavigation=this.options.onSameUrlNavigation||"ignore";config=(0,i.WQX)(Ki,{optional:!0})?.flat()??[];componentInputBindingEnabled=!!(0,i.WQX)(Ts,{optional:!0});constructor(){this.resetConfig(this.config),this.navigationTransitions.setupNavigations(this,this.currentUrlTree,this.routerState).subscribe({error:F=>{this.console.warn(F)}}),this.subscribeToNavigationEvents()}eventsSubscription=new pe.yU;subscribeToNavigationEvents(){const F=this.navigationTransitions.events.subscribe(K=>{try{const _e=this.navigationTransitions.currentTransition,We=this.navigationTransitions.currentNavigation;if(null!==_e&&null!==We)if(this.stateManager.handleRouterEvent(K,We),K instanceof Ht&&K.code!==Ne.Redirect&&K.code!==Ne.SupersededByNewNavigation)this.navigated=!0;else if(K instanceof Ye)this.navigated=!0;else if(K instanceof Pr){const At=K.navigationBehaviorOptions,fn=this.urlHandlingStrategy.merge(K.url,_e.currentRawUrl),on={browserUrl:_e.extras.browserUrl,info:_e.extras.info,skipLocationChange:_e.extras.skipLocationChange,replaceUrl:_e.extras.replaceUrl||"eager"===this.urlUpdateStrategy||Ie(_e.source),...At};this.scheduleNavigation(fn,tt,null,on,{resolve:_e.resolve,reject:_e.reject,promise:_e.promise})}(function wi(R){return!(R instanceof Qr||R instanceof Pr)})(K)&&this._events.next(K)}catch(_e){this.navigationTransitions.transitionAbortSubject.next(_e)}});this.eventsSubscription.add(F)}resetRootComponentType(F){this.routerState.root.component=F,this.navigationTransitions.rootComponentType=F}initialNavigation(){this.setUpLocationChangeListener(),this.navigationTransitions.hasRequestedNavigation||this.navigateToSyncWithBrowser(this.location.path(!0),tt,this.stateManager.restoredState())}setUpLocationChangeListener(){this.nonRouterCurrentEntryChangeSubscription??=this.stateManager.registerNonRouterCurrentEntryChangeListener((F,K)=>{setTimeout(()=>{this.navigateToSyncWithBrowser(F,"popstate",K)},0)})}navigateToSyncWithBrowser(F,K,_e){const We={replaceUrl:!0},At=_e?.navigationId?_e:null;if(_e){const on={..._e};delete on.navigationId,delete on.\u0275routerPageId,0!==Object.keys(on).length&&(We.state=on)}const fn=this.parseUrl(F);this.scheduleNavigation(fn,K,At,We)}get url(){return this.serializeUrl(this.currentUrlTree)}getCurrentNavigation(){return this.navigationTransitions.currentNavigation}get lastSuccessfulNavigation(){return this.navigationTransitions.lastSuccessfulNavigation}resetConfig(F){this.config=F.map(Bi),this.navigated=!1}ngOnDestroy(){this.dispose()}dispose(){this.navigationTransitions.complete(),this.nonRouterCurrentEntryChangeSubscription&&(this.nonRouterCurrentEntryChangeSubscription.unsubscribe(),this.nonRouterCurrentEntryChangeSubscription=void 0),this.disposed=!0,this.eventsSubscription.unsubscribe()}createUrlTree(F,K={}){const{relativeTo:_e,queryParams:We,fragment:At,queryParamsHandling:fn,preserveFragment:on}=K,ur=on?this.currentUrlTree.fragment:At;let kr,ui=null;switch(fn??this.options.defaultQueryParamsHandling){case"merge":ui={...this.currentUrlTree.queryParams,...We};break;case"preserve":ui=this.currentUrlTree.queryParams;break;default:ui=We||null}null!==ui&&(ui=this.removeEmptyProps(ui));try{kr=nt(_e?_e.snapshot:this.routerState.snapshot.root)}catch{("string"!=typeof F[0]||"/"!==F[0][0])&&(F=[]),kr=this.currentUrlTree.root}return Rt(kr,F,ui,ur??null)}navigateByUrl(F,K={skipLocationChange:!1}){const _e=Jt(F)?F:this.parseUrl(F),We=this.urlHandlingStrategy.merge(_e,this.rawUrlTree);return this.scheduleNavigation(We,tt,null,K)}navigate(F,K={skipLocationChange:!1}){return function ii(R){for(let G=0;G(null!=We&&(K[_e]=We),K),{})}scheduleNavigation(F,K,_e,We,At){if(this.disposed)return Promise.resolve(!1);let fn,on,ur;At?(fn=At.resolve,on=At.reject,ur=At.promise):ur=new Promise((kr,Gi)=>{fn=kr,on=Gi});const ui=this.pendingTasks.add();return ci(this,()=>{queueMicrotask(()=>this.pendingTasks.remove(ui))}),this.navigationTransitions.handleNavigationRequest({source:K,restoredState:_e,currentUrlTree:this.currentUrlTree,currentRawUrl:this.currentUrlTree,rawUrl:F,extras:We,resolve:fn,reject:on,promise:ur,currentSnapshot:this.routerState.snapshot,currentRouterState:this.routerState}),ur.catch(kr=>Promise.reject(kr))}static \u0275fac=function(K){return new(K||R)};static \u0275prov=i.jDH({token:R,factory:R.\u0275fac,providedIn:"root"})}return R})(),bs=(()=>{class R{router;route;tabIndexAttribute;renderer;el;locationStrategy;href=null;target;queryParams;fragment;queryParamsHandling;state;info;relativeTo;isAnchorElement;subscription;onChanges=new re.B;constructor(F,K,_e,We,At,fn){this.router=F,this.route=K,this.tabIndexAttribute=_e,this.renderer=We,this.el=At,this.locationStrategy=fn;const on=At.nativeElement.tagName?.toLowerCase();this.isAnchorElement="a"===on||"area"===on,this.isAnchorElement?this.subscription=F.events.subscribe(ur=>{ur instanceof Ye&&this.updateHref()}):this.setTabIndexIfNotOnNativeEl("0")}preserveFragment=!1;skipLocationChange=!1;replaceUrl=!1;setTabIndexIfNotOnNativeEl(F){null!=this.tabIndexAttribute||this.isAnchorElement||this.applyAttributeValue("tabindex",F)}ngOnChanges(F){this.isAnchorElement&&this.updateHref(),this.onChanges.next(this)}routerLinkInput=null;set routerLink(F){null==F?(this.routerLinkInput=null,this.setTabIndexIfNotOnNativeEl(null)):(this.routerLinkInput=Jt(F)||Array.isArray(F)?F:[F],this.setTabIndexIfNotOnNativeEl("0"))}onClick(F,K,_e,We,At){const fn=this.urlTree;return!!(null===fn||this.isAnchorElement&&(0!==F||K||_e||We||At||"string"==typeof this.target&&"_self"!=this.target))||(this.router.navigateByUrl(fn,{skipLocationChange:this.skipLocationChange,replaceUrl:this.replaceUrl,state:this.state,info:this.info}),!this.isAnchorElement)}ngOnDestroy(){this.subscription?.unsubscribe()}updateHref(){const F=this.urlTree;this.href=null!==F&&this.locationStrategy?this.locationStrategy?.prepareExternalUrl(this.router.serializeUrl(F)):null;const K=null===this.href?null:(0,i.n$t)(this.href,this.el.nativeElement.tagName.toLowerCase(),"href");this.applyAttributeValue("href",K)}applyAttributeValue(F,K){const _e=this.renderer,We=this.el.nativeElement;null!==K?_e.setAttribute(We,F,K):_e.removeAttribute(We,F)}get urlTree(){return null===this.routerLinkInput?null:Jt(this.routerLinkInput)?this.routerLinkInput:this.router.createUrlTree(this.routerLinkInput,{relativeTo:void 0!==this.relativeTo?this.relativeTo:this.route,queryParams:this.queryParams,fragment:this.fragment,queryParamsHandling:this.queryParamsHandling,preserveFragment:this.preserveFragment})}static \u0275fac=function(K){return new(K||R)(i.rXU(li),i.rXU(_o),i.kS0("tabindex"),i.rXU(i.sFG),i.rXU(i.aKT),i.rXU(se.hb))};static \u0275dir=i.FsC({type:R,selectors:[["","routerLink",""]],hostVars:1,hostBindings:function(K,_e){1&K&&i.bIt("click",function(At){return _e.onClick(At.button,At.ctrlKey,At.shiftKey,At.altKey,At.metaKey)}),2&K&&i.BMQ("target",_e.target)},inputs:{target:"target",queryParams:"queryParams",fragment:"fragment",queryParamsHandling:"queryParamsHandling",state:"state",info:"info",relativeTo:"relativeTo",preserveFragment:[2,"preserveFragment","preserveFragment",i.L39],skipLocationChange:[2,"skipLocationChange","skipLocationChange",i.L39],replaceUrl:[2,"replaceUrl","replaceUrl",i.L39],routerLink:"routerLink"},features:[i.GFd,i.OA$]})}return R})(),Lo=(()=>{class R{router;element;renderer;cdr;link;links;classes=[];routerEventsSubscription;linkInputChangesSubscription;_isActive=!1;get isActive(){return this._isActive}routerLinkActiveOptions={exact:!1};ariaCurrentWhenActive;isActiveChange=new i.bkB;constructor(F,K,_e,We,At){this.router=F,this.element=K,this.renderer=_e,this.cdr=We,this.link=At,this.routerEventsSubscription=F.events.subscribe(fn=>{fn instanceof Ye&&this.update()})}ngAfterContentInit(){(0,y.of)(this.links.changes,(0,y.of)(null)).pipe((0,Ft.U)()).subscribe(F=>{this.update(),this.subscribeToEachLinkOnChanges()})}subscribeToEachLinkOnChanges(){this.linkInputChangesSubscription?.unsubscribe();const F=[...this.links.toArray(),this.link].filter(K=>!!K).map(K=>K.onChanges);this.linkInputChangesSubscription=(0,c.H)(F).pipe((0,Ft.U)()).subscribe(K=>{this._isActive!==this.isLinkActive(this.router)(K)&&this.update()})}set routerLinkActive(F){const K=Array.isArray(F)?F:F.split(" ");this.classes=K.filter(_e=>!!_e)}ngOnChanges(F){this.update()}ngOnDestroy(){this.routerEventsSubscription.unsubscribe(),this.linkInputChangesSubscription?.unsubscribe()}update(){!this.links||!this.router.navigated||queueMicrotask(()=>{const F=this.hasActiveLinks();this.classes.forEach(K=>{F?this.renderer.addClass(this.element.nativeElement,K):this.renderer.removeClass(this.element.nativeElement,K)}),F&&void 0!==this.ariaCurrentWhenActive?this.renderer.setAttribute(this.element.nativeElement,"aria-current",this.ariaCurrentWhenActive.toString()):this.renderer.removeAttribute(this.element.nativeElement,"aria-current"),this._isActive!==F&&(this._isActive=F,this.cdr.markForCheck(),this.isActiveChange.emit(F))})}isLinkActive(F){const K=function fa(R){return!!R.paths}(this.routerLinkActiveOptions)?this.routerLinkActiveOptions:this.routerLinkActiveOptions.exact||!1;return _e=>{const We=_e.urlTree;return!!We&&F.isActive(We,K)}}hasActiveLinks(){const F=this.isLinkActive(this.router);return this.link&&F(this.link)||this.links.some(F)}static \u0275fac=function(K){return new(K||R)(i.rXU(li),i.rXU(i.aKT),i.rXU(i.sFG),i.rXU(i.gRc),i.rXU(bs,8))};static \u0275dir=i.FsC({type:R,selectors:[["","routerLinkActive",""]],contentQueries:function(K,_e,We){if(1&K&&i.wni(We,bs,5),2&K){let At;i.mGM(At=i.lsd())&&(_e.links=At)}},inputs:{routerLinkActiveOptions:"routerLinkActiveOptions",ariaCurrentWhenActive:"ariaCurrentWhenActive",routerLinkActive:"routerLinkActive"},outputs:{isActiveChange:"isActiveChange"},exportAs:["routerLinkActive"],features:[i.OA$]})}return R})();class Yo{}let Ta=(()=>{class R{router;injector;preloadingStrategy;loader;subscription;constructor(F,K,_e,We,At){this.router=F,this.injector=_e,this.preloadingStrategy=We,this.loader=At}setUpPreloading(){this.subscription=this.router.events.pipe((0,xe.p)(F=>F instanceof Ye),(0,ue.H)(()=>this.preload())).subscribe(()=>{})}preload(){return this.processRoutes(this.injector,this.router.config)}ngOnDestroy(){this.subscription&&this.subscription.unsubscribe()}processRoutes(F,K){const _e=[];for(const We of K){We.providers&&!We._injector&&(We._injector=(0,i.Ol2)(We.providers,F,`Route: ${We.path}`));const At=We._injector??F,fn=We._loadedInjector??At;(We.loadChildren&&!We._loadedRoutes&&void 0===We.canLoad||We.loadComponent&&!We._loadedComponent)&&_e.push(this.preloadConfig(At,We)),(We.children||We._loadedRoutes)&&_e.push(this.processRoutes(fn,We.children??We._loadedRoutes))}return(0,c.H)(_e).pipe((0,Ft.U)())}preloadConfig(F,K){return this.preloadingStrategy.preload(K,()=>{let _e;_e=K.loadChildren&&void 0===K.canLoad?this.loader.loadChildren(F,K):(0,y.of)(null);const We=_e.pipe((0,De.Z)(At=>null===At?(0,y.of)(void 0):(K._loadedRoutes=At.routes,K._loadedInjector=At.injector,this.processRoutes(At.injector??F,At.routes))));if(K.loadComponent&&!K._loadedComponent){const At=this.loader.loadComponent(K);return(0,c.H)([We,At]).pipe((0,Ft.U)())}return We})}static \u0275fac=function(K){return new(K||R)(i.KVO(li),i.KVO(i.Ql9),i.KVO(i.uvJ),i.KVO(Yo),i.KVO(no))};static \u0275prov=i.jDH({token:R,factory:R.\u0275fac,providedIn:"root"})}return R})();const Ma=new i.nKC("");let qa=(()=>{class R{urlSerializer;transitions;viewportScroller;zone;options;routerEventsSubscription;scrollEventsSubscription;lastId=0;lastSource="imperative";restoredId=0;store={};constructor(F,K,_e,We,At={}){this.urlSerializer=F,this.transitions=K,this.viewportScroller=_e,this.zone=We,this.options=At,At.scrollPositionRestoration||="disabled",At.anchorScrolling||="disabled"}init(){"disabled"!==this.options.scrollPositionRestoration&&this.viewportScroller.setHistoryScrollRestoration("manual"),this.routerEventsSubscription=this.createScrollEvents(),this.scrollEventsSubscription=this.consumeScrollEvents()}createScrollEvents(){return this.transitions.events.subscribe(F=>{F instanceof ve?(this.store[this.lastId]=this.viewportScroller.getScrollPosition(),this.lastSource=F.navigationTrigger,this.restoredId=F.restoredState?F.restoredState.navigationId:0):F instanceof Ye?(this.lastId=F.id,this.scheduleScrollEvent(F,this.urlSerializer.parse(F.urlAfterRedirects).fragment)):F instanceof kt&&F.code===gt.IgnoredSameUrlNavigation&&(this.lastSource=void 0,this.restoredId=0,this.scheduleScrollEvent(F,this.urlSerializer.parse(F.url).fragment))})}consumeScrollEvents(){return this.transitions.events.subscribe(F=>{F instanceof Or&&(F.position?"top"===this.options.scrollPositionRestoration?this.viewportScroller.scrollToPosition([0,0]):"enabled"===this.options.scrollPositionRestoration&&this.viewportScroller.scrollToPosition(F.position):F.anchor&&"enabled"===this.options.anchorScrolling?this.viewportScroller.scrollToAnchor(F.anchor):"disabled"!==this.options.scrollPositionRestoration&&this.viewportScroller.scrollToPosition([0,0]))})}scheduleScrollEvent(F,K){this.zone.runOutsideAngular(()=>{setTimeout(()=>{this.zone.run(()=>{this.transitions.events.next(new Or(F,"popstate"===this.lastSource?this.store[this.restoredId]:null,K))})},0)})}ngOnDestroy(){this.routerEventsSubscription?.unsubscribe(),this.scrollEventsSubscription?.unsubscribe()}static \u0275fac=function(K){i.QTQ()};static \u0275prov=i.jDH({token:R,factory:R.\u0275fac})}return R})();function ou(R,...G){return(0,i.EmA)([{provide:Ki,multi:!0,useValue:R},[],{provide:_o,useFactory:ka,deps:[li]},{provide:i.iLQ,multi:!0,useFactory:pc},G.map(F=>F.\u0275providers)])}function ka(R){return R.routerState.root}function Ia(R,G){return{\u0275kind:R,\u0275providers:G}}function Wl(R={}){return Ia(4,[{provide:Ma,useFactory:()=>{const F=(0,i.WQX)(se.Xr),K=(0,i.WQX)(i.SKi),_e=(0,i.WQX)(U),We=(0,i.WQX)(ft);return new qa(We,_e,F,K,R)}}])}function pc(){const R=(0,i.WQX)(i.zZn);return G=>{const F=R.get(i.o8S);if(G!==F.components[0])return;const K=R.get(li),_e=R.get(fl);1===R.get(yo)&&K.initialNavigation(),R.get(mc,null,i.$GK.Optional)?.setUpPreloading(),R.get(Ma,null,i.$GK.Optional)?.init(),K.resetRootComponentType(F.componentTypes[0]),_e.closed||(_e.next(),_e.complete(),_e.unsubscribe())}}const fl=new i.nKC("",{factory:()=>new re.B}),yo=new i.nKC("",{providedIn:"root",factory:()=>1}),mc=new i.nKC("");function lu(R){return Ia(0,[{provide:mc,useExisting:Ta},{provide:Yo,useExisting:R}])}function Ur(R){return Ia(9,[{provide:vo,useValue:Vs},{provide:Ci,useValue:{skipNextTransition:!!R?.skipInitialTransition,...R}}])}const Hs=new i.nKC("ROUTER_FORROOT_GUARD"),zl=[se.aZ,{provide:ft,useClass:mt},li,Go,{provide:_o,useFactory:ka,deps:[li]},no,[]];let Wa=(()=>{class R{constructor(F){}static forRoot(F,K){return{ngModule:R,providers:[zl,[],{provide:Ki,multi:!0,useValue:F},{provide:Hs,useFactory:pl,deps:[[li,new i.Xx1,new i.kdw]]},K?.errorHandler?{provide:Ui,useValue:K.errorHandler}:[],{provide:Qi,useValue:K||{}},K?.useHash?{provide:se.hb,useClass:se.fw}:{provide:se.hb,useClass:se.Sm},{provide:Ma,useFactory:()=>{const R=(0,i.WQX)(se.Xr),G=(0,i.WQX)(i.SKi),F=(0,i.WQX)(Qi),K=(0,i.WQX)(U),_e=(0,i.WQX)(ft);return F.scrollOffset&&R.setOffset(F.scrollOffset),new qa(_e,K,R,G,F)}},K?.preloadingStrategy?lu(K.preloadingStrategy).\u0275providers:[],K?.initialNavigation?gd(K):[],K?.bindToComponentInputs?Ia(8,[Ns,{provide:Ts,useExisting:Ns}]).\u0275providers:[],K?.enableViewTransitions?Ur().\u0275providers:[],[{provide:cu,useFactory:pc},{provide:i.iLQ,multi:!0,useExisting:cu}]]}}static forChild(F){return{ngModule:R,providers:[{provide:Ki,multi:!0,useValue:F}]}}static \u0275fac=function(K){return new(K||R)(i.KVO(Hs,8))};static \u0275mod=i.$C({type:R});static \u0275inj=i.G2t({})}return R})();function pl(R){return"guarded"}function gd(R){return["disabled"===R.initialNavigation?Ia(3,[{provide:i.hnV,multi:!0,useFactory:()=>{const G=(0,i.WQX)(li);return()=>{G.setUpLocationChangeListener()}}},{provide:yo,useValue:2}]).\u0275providers:[],"enabledBlocking"===R.initialNavigation?Ia(2,[{provide:yo,useValue:0},{provide:i.hnV,multi:!0,deps:[i.zZn],useFactory:G=>{const F=G.get(se.hj,Promise.resolve());return()=>F.then(()=>new Promise(K=>{const _e=G.get(li),We=G.get(fl);ci(_e,()=>{K(!0)}),G.get(U).afterPreactivation=()=>(K(!0),We.closed?(0,y.of)(void 0):We),_e.initialNavigation()}))}}]).\u0275providers:[]]}const cu=new i.nKC("")},8378:(o,s,r)=>{"use strict";r.d(s,{My:()=>Oe,aT:()=>ce});const be=Array.from({length:256},(qe,_t)=>_t.toString(16).padStart(2,"0"));function Oe(qe){!function c(qe,..._t){if(!function a(qe){return qe instanceof Uint8Array||ArrayBuffer.isView(qe)&&"Uint8Array"===qe.constructor.name}(qe))throw new Error("Uint8Array expected");if(_t.length>0&&!_t.includes(qe.length))throw new Error("Uint8Array expected of length "+_t+", got length="+qe.length)}(qe);let _t="";for(let ze=0;ze=xe._0&&qe<=xe._9?qe-xe._0:qe>=xe.A&&qe<=xe.F?qe-(xe.A-10):qe>=xe.a&&qe<=xe.f?qe-(xe.a-10):void 0}function ce(qe){if("string"!=typeof qe)throw new Error("hex string expected, got "+typeof qe);const _t=qe.length,ze=_t/2;if(_t%2)throw new Error("hex string expected, got unpadded hex of length "+_t);const $e=new Uint8Array(ze);for(let Ft=0,Ke=0;Ft{"use strict";function a(Mt){return Mt instanceof Uint8Array||null!=Mt&&"object"==typeof Mt&&"Uint8Array"===Mt.constructor.name}function c(...Mt){const Kt=kn=>kn,rt=(kn,Kn)=>Nr=>kn(Kn(Nr));return{encode:Mt.map(kn=>kn.encode).reduceRight(rt,Kt),decode:Mt.map(kn=>kn.decode).reduce(rt,Kt)}}function y(Mt){return{encode:Kt=>{if(!Array.isArray(Kt)||Kt.length&&"number"!=typeof Kt[0])throw new Error("alphabet.encode input should be an array of numbers");return Kt.map(rt=>{if(rt<0||rt>=Mt.length)throw new Error(`Digit index outside alphabet: ${rt} (alphabet: ${Mt.length})`);return Mt[rt]})},decode:Kt=>{if(!Array.isArray(Kt)||Kt.length&&"string"!=typeof Kt[0])throw new Error("alphabet.decode input should be array of strings");return Kt.map(rt=>{if("string"!=typeof rt)throw new Error(`alphabet.decode: not string element=${rt}`);const Vt=Mt.indexOf(rt);if(-1===Vt)throw new Error(`Unknown letter: "${rt}". Allowed: ${Mt}`);return Vt})}}}function w(Mt=""){if("string"!=typeof Mt)throw new Error("join separator should be string");return{encode:Kt=>{if(!Array.isArray(Kt)||Kt.length&&"string"!=typeof Kt[0])throw new Error("join.encode input should be array of strings");for(let rt of Kt)if("string"!=typeof rt)throw new Error(`join.encode: non-string input=${rt}`);return Kt.join(Mt)},decode:Kt=>{if("string"!=typeof Kt)throw new Error("join.decode input should be string");return Kt.split(Mt)}}}function C(Mt,Kt="="){if("string"!=typeof Kt)throw new Error("padding chr should be string");return{encode(rt){if(!Array.isArray(rt)||rt.length&&"string"!=typeof rt[0])throw new Error("padding.encode input should be array of strings");for(let Vt of rt)if("string"!=typeof Vt)throw new Error(`padding.encode: non-string input=${Vt}`);for(;rt.length*Mt%8;)rt.push(Kt);return rt},decode(rt){if(!Array.isArray(rt)||rt.length&&"string"!=typeof rt[0])throw new Error("padding.encode input should be array of strings");for(let en of rt)if("string"!=typeof en)throw new Error(`padding.decode: non-string input=${en}`);let Vt=rt.length;if(Vt*Mt%8)throw new Error("Invalid padding: string should have whole number of bytes");for(;Vt>0&&rt[Vt-1]===Kt;Vt--)if(!((Vt-1)*Mt%8))throw new Error("Invalid padding: string has too much padding");return rt.slice(0,Vt)}}}function S(Mt,Kt,rt){if(Kt<2)throw new Error(`convertRadix: wrong from=${Kt}, base cannot be less than 2`);if(rt<2)throw new Error(`convertRadix: wrong to=${rt}, base cannot be less than 2`);if(!Array.isArray(Mt))throw new Error("convertRadix: data should be array");if(!Mt.length)return[];let Vt=0;const en=[],kn=Array.from(Mt);for(kn.forEach(Kn=>{if(Kn<0||Kn>=Kt)throw new Error(`Wrong integer: ${Kn}`)});;){let Kn=0,Nr=!0;for(let Rn=Vt;RnFt,K3:()=>ce,Tq:()=>Vn});const M=(Mt,Kt)=>Kt?M(Kt,Mt%Kt):Mt,O=(Mt,Kt)=>Mt+(Kt-M(Mt,Kt));function L(Mt,Kt,rt,Vt){if(!Array.isArray(Mt))throw new Error("convertRadix2: data should be array");if(Kt<=0||Kt>32)throw new Error(`convertRadix2: wrong from=${Kt}`);if(rt<=0||rt>32)throw new Error(`convertRadix2: wrong to=${rt}`);if(O(Kt,rt)>32)throw new Error(`convertRadix2: carry overflow from=${Kt} to=${rt} carryBits=${O(Kt,rt)}`);let en=0,kn=0;const Kn=2**rt-1,Nr=[];for(const Rn of Mt){if(Rn>=2**Kt)throw new Error(`convertRadix2: invalid data word=${Rn} from=${Kt}`);if(en=en<32)throw new Error(`convertRadix2: carry overflow pos=${kn} from=${Kt}`);for(kn+=Kt;kn>=rt;kn-=rt)Nr.push((en>>kn-rt&Kn)>>>0);en&=2**kn-1}if(en=en<=Kt)throw new Error("Excess padding");if(!Vt&&en)throw new Error(`Non-zero padding: ${en}`);return Vt&&kn>0&&Nr.push(en>>>0),Nr}function Z(Mt){return{encode:Kt=>{if(!a(Kt))throw new Error("radix.encode input should be Uint8Array");return S(Array.from(Kt),256,Mt)},decode:Kt=>{if(!Array.isArray(Kt)||Kt.length&&"number"!=typeof Kt[0])throw new Error("radix.decode input should be array of numbers");return Uint8Array.from(S(Kt,Mt,256))}}}function q(Mt,Kt=!1){if(Mt<=0||Mt>32)throw new Error("radix2: bits should be in (0..32]");if(O(8,Mt)>32||O(Mt,8)>32)throw new Error("radix2: carry overflow");return{encode:rt=>{if(!a(rt))throw new Error("radix2.encode input should be Uint8Array");return L(Array.from(rt),8,Mt,!Kt)},decode:rt=>{if(!Array.isArray(rt)||rt.length&&"number"!=typeof rt[0])throw new Error("radix2.decode input should be array of numbers");return Uint8Array.from(L(rt,Mt,8,Kt))}}}function re(Mt){if("function"!=typeof Mt)throw new Error("unsafeWrapper fn should be function");return function(...Kt){try{return Mt.apply(null,Kt)}catch{}}}function pe(Mt,Kt){if("function"!=typeof Kt)throw new Error("checksum fn should be function");return{encode(rt){if(!a(rt))throw new Error("checksum.encode: input should be Uint8Array");const Vt=Kt(rt).slice(0,Mt),en=new Uint8Array(rt.length+Mt);return en.set(rt),en.set(Vt,rt.length),en},decode(rt){if(!a(rt))throw new Error("checksum.decode: input should be Uint8Array");const Vt=rt.slice(0,-Mt),en=Kt(Vt).slice(0,Mt),kn=rt.slice(-Mt);for(let Kn=0;Knc(Z(58),y("123456789ABCDEFGHJKLMNPQRSTUVWXYZabcdefghijkmnopqrstuvwxyz"),w("")))(),Vn=Mt=>c(pe(4,Kt=>Mt(Mt(Kt))),dt),yn=c(y("qpzry9x8gf2tvdw0s3jn54khce6mua7l"),w("")),qe=[996825010,642813549,513874426,1027748829,705979059];function _t(Mt){const Kt=Mt>>25;let rt=(33554431&Mt)<<5;for(let Vt=0;Vt>Vt&1)&&(rt^=qe[Vt]);return rt}function ze(Mt,Kt,rt=1){const Vt=Mt.length;let en=1;for(let kn=0;kn126)throw new Error(`Invalid prefix (${Mt})`);en=_t(en)^Kn>>5}en=_t(en);for(let kn=0;knJe)throw new TypeError(`Length ${z} exceeds limit ${Je}`);const N=Fe.toLowerCase(),W=ze(N,ke,Kt);return`${N}1${yn.encode(ke)}${W}`}function Nr(Fe,ke=90){if("string"!=typeof Fe)throw new Error("bech32.decode input should be string, not "+typeof Fe);if(Fe.length<8||!1!==ke&&Fe.length>ke)throw new TypeError(`Wrong string length: ${Fe.length} (${Fe}). Expected (8..${ke})`);const Je=Fe.toLowerCase();if(Fe!==Je&&Fe!==Fe.toUpperCase())throw new Error("String must be lowercase or uppercase");const z=Je.lastIndexOf("1");if(0===z||-1===z)throw new Error('Letter "1" must be present between prefix and data only');const N=Je.slice(0,z),W=Je.slice(z+1);if(W.length<6)throw new Error("Data must be at least 6 characters long");const Le=yn.decode(W).slice(0,-6),ft=ze(N,Le,Kt);if(!W.endsWith(ft))throw new Error(`Invalid checksum in ${Fe}: expected "${ft}"`);return{prefix:N,words:Le}}return{encode:Kn,decode:Nr,encodeFromBytes:function cn(Fe,ke){return Kn(Fe,en(ke))},decodeToBytes:function pr(Fe){const{prefix:ke,words:Je}=Nr(Fe,!1);return{prefix:ke,words:Je,bytes:Vt(Je)}},decodeUnsafe:re(Nr),fromWords:Vt,fromWordsUnsafe:kn,toWords:en}}const Ft=$e("bech32")},2769:(o,s,r)=>{"use strict";r.d(s,{A:()=>y});var i=r(3121),a=r(9311);const y=(0,i.A)(a.A,"Map")},1238:(o,s,r)=>{"use strict";r.d(s,{A:()=>ft});var c=r(2486);const w=function y(mt,St){for(var Tn=mt.length;Tn--;)if((0,c.A)(mt[Tn][0],St))return Tn;return-1};var T=Array.prototype.splice;function se(mt){var St=-1,Tn=null==mt?0:mt.length;for(this.clear();++St-1},se.prototype.set=function re(mt,St){var Tn=this.__data__,an=w(Tn,mt);return an<0?(++this.size,Tn.push([mt,St])):Tn[an][1]=St,this};const ae=se;var Be=r(2769);const bt=(0,r(3121).A)(Object,"create");var qe=Object.prototype.hasOwnProperty;var Ft=Object.prototype.hasOwnProperty;function Te(mt){var St=-1,Tn=null==mt?0:mt.length;for(this.clear();++St{"use strict";r.d(s,{A:()=>c});const c=r(9311).A.Symbol},6259:(o,s,r)=>{"use strict";r.d(s,{A:()=>L});var c=r(1656),y=r(9007),w=r(5303),C=r(3467),T=r(766),M=Object.prototype.hasOwnProperty;const L=function O(Z,q){var re=(0,y.A)(Z),pe=!re&&(0,c.A)(Z),se=!re&&!pe&&(0,w.A)(Z),ae=!re&&!pe&&!se&&(0,T.A)(Z),me=re||pe||se||ae,be=me?function i(Z,q){for(var re=-1,pe=Array(Z);++re{"use strict";r.d(s,{A:()=>C});var i=r(8758),a=r(2486),y=Object.prototype.hasOwnProperty;const C=function w(T,S,M){var O=T[S];(!y.call(T,S)||!(0,a.A)(O,M)||void 0===M&&!(S in T))&&(0,i.A)(T,S,M)}},8758:(o,s,r)=>{"use strict";r.d(s,{A:()=>c});var i=r(4133);const c=function a(y,w,C){"__proto__"==w&&i.A?(0,i.A)(y,w,{configurable:!0,enumerable:!0,value:C,writable:!0}):y[w]=C}},5688:(o,s,r)=>{"use strict";r.d(s,{A:()=>se});var i=r(4883),a=Object.prototype,c=a.hasOwnProperty,y=a.toString,w=i.A?i.A.toStringTag:void 0;var M=Object.prototype.toString;var re=i.A?i.A.toStringTag:void 0;const se=function pe(ae){return null==ae?void 0===ae?"[object Undefined]":"[object Null]":re&&re in Object(ae)?function C(ae){var me=c.call(ae,w),be=ae[w];try{ae[w]=void 0;var Oe=!0}catch{}var xe=y.call(ae);return Oe&&(me?ae[w]=be:delete ae[w]),xe}(ae):function O(ae){return M.call(ae)}(ae)}},4975:(o,s,r)=>{"use strict";r.d(s,{A:()=>a});const a=function i(c){return function(y){return c(y)}}},3031:(o,s,r)=>{"use strict";r.d(s,{A:()=>w});const c=r(9311).A.Uint8Array,w=function y(C){var T=new C.constructor(C.byteLength);return new c(T).set(new c(C)),T}},4224:(o,s,r)=>{"use strict";r.d(s,{A:()=>S});var i=r(9311),a="object"==typeof exports&&exports&&!exports.nodeType&&exports,c=a&&"object"==typeof module&&module&&!module.nodeType&&module,w=c&&c.exports===a?i.A.Buffer:void 0,C=w?w.allocUnsafe:void 0;const S=function T(M,O){if(O)return M.slice();var L=M.length,Z=C?C(L):new M.constructor(L);return M.copy(Z),Z}},7383:(o,s,r)=>{"use strict";r.d(s,{A:()=>c});var i=r(3031);const c=function a(y,w){var C=w?(0,i.A)(y.buffer):y.buffer;return new y.constructor(C,y.byteOffset,y.length)}},1369:(o,s,r)=>{"use strict";r.d(s,{A:()=>a});const a=function i(c,y){var w=-1,C=c.length;for(y||(y=Array(C));++w{"use strict";r.d(s,{A:()=>y});var i=r(2065),a=r(8758);const y=function c(w,C,T,S){var M=!T;T||(T={});for(var O=-1,L=C.length;++O{"use strict";r.d(s,{A:()=>c});var i=r(3121);const c=function(){try{var y=(0,i.A)(Object,"defineProperty");return y({},"",{}),y}catch{}}()},8618:(o,s,r)=>{"use strict";r.d(s,{A:()=>a});const a="object"==typeof global&&global&&global.Object===Object&&global},3121:(o,s,r)=>{"use strict";r.d(s,{A:()=>De});var ce,i=r(5656),c=r(9311).A["__core-js_shared__"],w=(ce=/[^.]+$/.exec(c&&c.keys&&c.keys.IE_PROTO||""))?"Symbol(src)_1."+ce:"";var S=r(7999),M=r(4435),L=/^\[object .+?Constructor\]$/,se=RegExp("^"+Function.prototype.toString.call(Object.prototype.hasOwnProperty).replace(/[\\^$.*+?()[\]{}|]/g,"\\$&").replace(/hasOwnProperty|(function).*?(?=\\\()| for .+?(?=\\\])/g,"$1.*?")+"$");const me=function ae(ce){return!(!(0,S.A)(ce)||function C(ce){return!!w&&w in ce}(ce))&&((0,i.A)(ce)?se:L).test((0,M.A)(ce))},De=function xe(ce,ue){var Ce=function be(ce,ue){return ce?.[ue]}(ce,ue);return me(Ce)?Ce:void 0}},5749:(o,s,r)=>{"use strict";r.d(s,{A:()=>c});const c=(0,r(5717).A)(Object.getPrototypeOf,Object)},223:(o,s,r)=>{"use strict";r.d(s,{A:()=>S});var i=r(7999),a=Object.create;const y=function(){function M(){}return function(O){if(!(0,i.A)(O))return{};if(a)return a(O);M.prototype=O;var L=new M;return M.prototype=void 0,L}}();var w=r(5749),C=r(1561);const S=function T(M){return"function"!=typeof M.constructor||(0,C.A)(M)?{}:y((0,w.A)(M))}},3467:(o,s,r)=>{"use strict";r.d(s,{A:()=>y});var a=/^(?:0|[1-9]\d*)$/;const y=function c(w,C){var T=typeof w;return!!(C=C??9007199254740991)&&("number"==T||"symbol"!=T&&a.test(w))&&w>-1&&w%1==0&&w{"use strict";r.d(s,{A:()=>c});var i=Object.prototype;const c=function a(y){var w=y&&y.constructor;return y===("function"==typeof w&&w.prototype||i)}},8583:(o,s,r)=>{"use strict";r.d(s,{A:()=>T});var i=r(8618),a="object"==typeof exports&&exports&&!exports.nodeType&&exports,c=a&&"object"==typeof module&&module&&!module.nodeType&&module,w=c&&c.exports===a&&i.A.process;const T=function(){try{return c&&c.require&&c.require("util").types||w&&w.binding&&w.binding("util")}catch{}}()},5717:(o,s,r)=>{"use strict";r.d(s,{A:()=>a});const a=function i(c,y){return function(w){return c(y(w))}}},9311:(o,s,r)=>{"use strict";r.d(s,{A:()=>y});var i=r(8618),a="object"==typeof self&&self&&self.Object===Object&&self;const y=i.A||a||Function("return this")()},4435:(o,s,r)=>{"use strict";r.d(s,{A:()=>y});var a=Function.prototype.toString;const y=function c(w){if(null!=w){try{return a.call(w)}catch{}try{return w+""}catch{}}return""}},2486:(o,s,r)=>{"use strict";r.d(s,{A:()=>a});const a=function i(c,y){return c===y||c!=c&&y!=y}},6143:(o,s,r)=>{"use strict";r.d(s,{A:()=>a});const a=function i(c){for(var y=-1,w=null==c?0:c.length,C={};++y{"use strict";r.d(s,{A:()=>O});var i=r(5688),a=r(2312);const w=function y(L){return(0,a.A)(L)&&"[object Arguments]"==(0,i.A)(L)};var C=Object.prototype,T=C.hasOwnProperty,S=C.propertyIsEnumerable;const O=w(function(){return arguments}())?w:function(L){return(0,a.A)(L)&&T.call(L,"callee")&&!S.call(L,"callee")}},9007:(o,s,r)=>{"use strict";r.d(s,{A:()=>a});const a=Array.isArray},2808:(o,s,r)=>{"use strict";r.d(s,{A:()=>y});var i=r(5656),a=r(4184);const y=function c(w){return null!=w&&(0,a.A)(w.length)&&!(0,i.A)(w)}},5303:(o,s,r)=>{"use strict";r.d(s,{A:()=>O});var i=r(9311),y="object"==typeof exports&&exports&&!exports.nodeType&&exports,w=y&&"object"==typeof module&&module&&!module.nodeType&&module,T=w&&w.exports===y?i.A.Buffer:void 0;const O=(T?T.isBuffer:void 0)||function a(){return!1}},5656:(o,s,r)=>{"use strict";r.d(s,{A:()=>S});var i=r(5688),a=r(7999);const S=function T(M){if(!(0,a.A)(M))return!1;var O=(0,i.A)(M);return"[object Function]"==O||"[object GeneratorFunction]"==O||"[object AsyncFunction]"==O||"[object Proxy]"==O}},4184:(o,s,r)=>{"use strict";r.d(s,{A:()=>c});const c=function a(y){return"number"==typeof y&&y>-1&&y%1==0&&y<=9007199254740991}},7999:(o,s,r)=>{"use strict";r.d(s,{A:()=>a});const a=function i(c){var y=typeof c;return null!=c&&("object"==y||"function"==y)}},2312:(o,s,r)=>{"use strict";r.d(s,{A:()=>a});const a=function i(c){return null!=c&&"object"==typeof c}},766:(o,s,r)=>{"use strict";r.d(s,{A:()=>yn});var i=r(5688),a=r(4184),c=r(2312),dt={};dt["[object Float32Array]"]=dt["[object Float64Array]"]=dt["[object Int8Array]"]=dt["[object Int16Array]"]=dt["[object Int32Array]"]=dt["[object Uint8Array]"]=dt["[object Uint8ClampedArray]"]=dt["[object Uint16Array]"]=dt["[object Uint32Array]"]=!0,dt["[object Arguments]"]=dt["[object Array]"]=dt["[object ArrayBuffer]"]=dt["[object Boolean]"]=dt["[object DataView]"]=dt["[object Date]"]=dt["[object Error]"]=dt["[object Function]"]=dt["[object Map]"]=dt["[object Number]"]=dt["[object Object]"]=dt["[object RegExp]"]=dt["[object Set]"]=dt["[object String]"]=dt["[object WeakMap]"]=!1;var rn=r(4975),gn=r(8583),bn=gn.A&&gn.A.isTypedArray;const yn=bn?(0,rn.A)(bn):function bt(qe){return(0,c.A)(qe)&&(0,a.A)(qe.length)&&!!dt[(0,i.A)(qe)]}},3959:(o,s,r)=>{"use strict";r.d(s,{A:()=>Z});var i=r(6259),a=r(7999),c=r(1561);var T=Object.prototype.hasOwnProperty;const M=function S(q){if(!(0,a.A)(q))return function y(q){var re=[];if(null!=q)for(var pe in Object(q))re.push(pe);return re}(q);var re=(0,c.A)(q),pe=[];for(var se in q)"constructor"==se&&(re||!T.call(q,se))||pe.push(se);return pe};var O=r(2808);const Z=function L(q){return(0,O.A)(q)?(0,i.A)(q,!0):M(q)}},4819:(o,s,r)=>{"use strict";r.d(s,{A:()=>Tn});var i=r(1238),a=r(8758),c=r(2486);const w=function y(an,dn,In){(void 0!==In&&!(0,c.A)(an[dn],In)||void 0===In&&!(dn in an))&&(0,a.A)(an,dn,In)},M=function C(an){return function(dn,In,sr){for(var xn=-1,Hr=Object(dn),Tr=sr(dn),Vr=Tr.length;Vr--;){var vt=Tr[an?Vr:++xn];if(!1===In(Hr[vt],vt,Hr))break}return dn}}();var O=r(4224),L=r(7383),Z=r(1369),q=r(223),re=r(1656),pe=r(9007),se=r(2808),ae=r(2312);var Oe=r(5303),xe=r(5656),De=r(7999),ce=r(5688),ue=r(5749),dt=Function.prototype.toString,bt=Object.prototype.hasOwnProperty,lt=dt.call(Object);var bn=r(766);const yn=function Vn(an,dn){if(("constructor"!==dn||"function"!=typeof an[dn])&&"__proto__"!=dn)return an[dn]};var qe=r(101),_t=r(3959);const Ke=function Ft(an,dn,In,sr,xn,Hr,Tr){var Vr=yn(an,In),vt=yn(dn,In),Wt=Tr.get(vt);if(Wt)w(an,In,Wt);else{var Re=Hr?Hr(Vr,vt,In+"",an,dn,Tr):void 0,Ge=void 0===Re;if(Ge){var Ve=(0,pe.A)(vt),Dt=!Ve&&(0,Oe.A)(vt),ct=!Ve&&!Dt&&(0,bn.A)(vt);Re=vt,Ve||Dt||ct?(0,pe.A)(Vr)?Re=Vr:function me(an){return(0,ae.A)(an)&&(0,se.A)(an)}(Vr)?Re=(0,Z.A)(Vr):Dt?(Ge=!1,Re=(0,O.A)(vt,!0)):ct?(Ge=!1,Re=(0,L.A)(vt,!0)):Re=[]:function rn(an){if(!(0,ae.A)(an)||"[object Object]"!=(0,ce.A)(an))return!1;var dn=(0,ue.A)(an);if(null===dn)return!0;var In=bt.call(dn,"constructor")&&dn.constructor;return"function"==typeof In&&In instanceof In&&dt.call(In)==lt}(vt)||(0,re.A)(vt)?(Re=Vr,(0,re.A)(Vr)?Re=function ze(an){return(0,qe.A)(an,(0,_t.A)(an))}(Vr):(!(0,De.A)(Vr)||(0,xe.A)(Vr))&&(Re=(0,q.A)(vt))):Ge=!1}Ge&&(Tr.set(vt,Re),xn(Re,vt,sr,Hr,Tr),Tr.delete(vt)),w(an,In,Re)}},it=function Ze(an,dn,In,sr,xn){an!==dn&&M(dn,function(Hr,Tr){if(xn||(xn=new i.A),(0,De.A)(Hr))Ke(an,dn,Tr,In,Ze,sr,xn);else{var Vr=sr?sr(yn(an,Tr),Hr,Tr+"",an,dn,xn):void 0;void 0===Vr&&(Vr=Hr),w(an,Tr,Vr)}},_t.A)},$t=function Ot(an){return an};var st=Math.max;const rt=function Kt(an){return function(){return an}};var Vt=r(4133),Rn=Date.now;const ke=function pr(an){var dn=0,In=0;return function(){var sr=Rn(),xn=16-(sr-In);if(In=sr,xn>0){if(++dn>=800)return arguments[0]}else dn=0;return an.apply(void 0,arguments)}}(Vt.A?function(an,dn){return(0,Vt.A)(an,"toString",{configurable:!0,enumerable:!1,value:rt(dn),writable:!0})}:$t),z=function Je(an,dn){return ke(function Xt(an,dn,In){return dn=st(void 0===dn?an.length-1:dn,0),function(){for(var sr=arguments,xn=-1,Hr=st(sr.length-dn,0),Tr=Array(Hr);++xn1?In[xn-1]:void 0,Tr=xn>2?In[2]:void 0;for(Hr=an.length>3&&"function"==typeof Hr?(xn--,Hr):void 0,Tr&&function W(an,dn,In){if(!(0,De.A)(In))return!1;var sr=typeof dn;return!!("number"==sr?(0,se.A)(In)&&(0,N.A)(dn,In.length):"string"==sr&&dn in In)&&(0,c.A)(In[dn],an)}(In[0],In[1],Tr)&&(Hr=xn<3?void 0:Hr,xn=1),dn=Object(dn);++sr{"use strict";__webpack_require__.d(__webpack_exports__,{Ts:()=>init,ql:()=>launch});var _home_runner_work_angor_hub_angor_hub_node_modules_angular_builders_custom_webpack_node_modules_babel_runtime_helpers_esm_asyncToGenerator_js__WEBPACK_IMPORTED_MODULE_1__=__webpack_require__(3014),_home_runner_work_angor_hub_angor_hub_node_modules_angular_builders_custom_webpack_node_modules_babel_runtime_helpers_esm_awaitAsyncGenerator_js__WEBPACK_IMPORTED_MODULE_2__=__webpack_require__(5137),_home_runner_work_angor_hub_angor_hub_node_modules_angular_builders_custom_webpack_node_modules_babel_runtime_helpers_esm_wrapAsyncGenerator_js__WEBPACK_IMPORTED_MODULE_0__=__webpack_require__(9129),BUILD={allRenderFn:!1,cmpDidLoad:!0,cmpDidUnload:!1,cmpDidUpdate:!0,cmpDidRender:!0,cmpWillLoad:!0,cmpWillUpdate:!0,cmpWillRender:!0,connectedCallback:!0,disconnectedCallback:!0,element:!0,event:!0,hasRenderFn:!0,lifecycle:!0,hostListener:!0,hostListenerTargetWindow:!0,hostListenerTargetDocument:!0,hostListenerTargetBody:!0,hostListenerTargetParent:!1,hostListenerTarget:!0,member:!0,method:!0,mode:!0,observeAttribute:!0,prop:!0,propMutable:!0,reflect:!0,scoped:!0,shadowDom:!0,slot:!0,cssAnnotations:!0,state:!0,style:!0,formAssociated:!1,svg:!0,updatable:!0,vdomAttribute:!0,vdomXlink:!0,vdomClass:!0,vdomFunctional:!0,vdomKey:!0,vdomListener:!0,vdomRef:!0,vdomPropOrAttr:!0,vdomRender:!0,vdomStyle:!0,vdomText:!0,watchCallback:!0,taskQueue:!0,hotModuleReplacement:!1,isDebug:!1,isDev:!1,isTesting:!1,hydrateServerSide:!1,hydrateClientSide:!1,lifecycleDOMEvents:!1,lazyLoad:!1,profile:!1,slotRelocation:!0,appendChildSlotFix:!1,cloneNodeFix:!1,hydratedAttribute:!1,hydratedClass:!0,scriptDataOpts:!1,scopedSlotTextContentFix:!1,shadowDomShim:!1,slotChildNodesFix:!1,invisiblePrehydration:!0,propBoolean:!0,propNumber:!0,propString:!0,constructableCSS:!0,cmpShouldUpdate:!0,devTools:!1,shadowDelegatesFocus:!0,initializeNextTick:!1,asyncLoading:!1,asyncQueue:!1,transformTagName:!1,attachStyles:!0,experimentalSlotFixes:!1},__defProp$1=Object.defineProperty,__export$1=(o,s)=>{for(var r in s)__defProp$1(o,r,{get:s[r],enumerable:!0})},hostRefs=new WeakMap,getHostRef=o=>hostRefs.get(o),registerHost=(o,s)=>hostRefs.set(o,{$flags$:0,$hostElement$:o,$cmpMeta$:s,$instanceValues$:new Map}),isMemberInElement=(o,s)=>s in o,consoleError=(o,s)=>(0,console.error)(o,s),styles=new Map,modeResolutionChain=[],SLOT_FB_CSS="slot-fb{display:contents}slot-fb[hidden]{display:none}",XLINK_NS="http://www.w3.org/1999/xlink",win=typeof window<"u"?window:{},doc=win.document||{head:{}},H=win.HTMLElement||class{},plt={$flags$:0,$resourcesUrl$:"",jmp:o=>o(),raf:o=>requestAnimationFrame(o),ael:(o,s,r,i)=>o.addEventListener(s,r,i),rel:(o,s,r,i)=>o.removeEventListener(s,r,i),ce:(o,s)=>new CustomEvent(o,s)},supportsListenerOptions=(()=>{let o=!1;try{doc.addEventListener("e",null,Object.defineProperty({},"passive",{get(){o=!0}}))}catch{}return o})(),promiseResolve=o=>Promise.resolve(o),supportsConstructableStylesheets=(()=>{try{return new CSSStyleSheet,"function"==typeof(new CSSStyleSheet).replaceSync}catch{}return!1})(),queuePending=!1,queueDomReads=[],queueDomWrites=[],queueTask=(o,s)=>r=>{o.push(r),queuePending||(queuePending=!0,s&&4&plt.$flags$?nextTick(flush):plt.raf(flush))},consume=o=>{for(let s=0;s{consume(queueDomReads),consume(queueDomWrites),(queuePending=queueDomReads.length>0)&&plt.raf(flush)},nextTick=o=>promiseResolve().then(o),writeTask=queueTask(queueDomWrites,!0),EMPTY_OBJ={},SVG_NS="http://www.w3.org/2000/svg",HTML_NS="http://www.w3.org/1999/xhtml",isDef=o=>null!=o,isComplexType=o=>"object"==(o=typeof o)||"function"===o;function queryNonceMetaTagContent(o){var s,r,i;return null!=(i=null==(r=null==(s=o.head)?void 0:s.querySelector('meta[name="csp-nonce"]'))?void 0:r.getAttribute("content"))?i:void 0}var result_exports={};__export$1(result_exports,{err:()=>err,map:()=>map,ok:()=>ok,unwrap:()=>unwrap$1,unwrapErr:()=>unwrapErr});var ok=o=>({isOk:!0,isErr:!1,value:o}),err=o=>({isOk:!1,isErr:!0,value:o});function map(o,s){if(o.isOk){const r=s(o.value);return r instanceof Promise?r.then(i=>ok(i)):ok(r)}if(o.isErr)return err(o.value);throw"should never get here"}var unwrap$1=o=>{if(o.isOk)return o.value;throw o.value},unwrapErr=o=>{if(o.isErr)return o.value;throw o.value},createTime=(o,s="")=>()=>{},h=(o,s,...r)=>{let i=null,a=null,c=null,y=!1,w=!1;const C=[],T=M=>{for(let O=0;OM[O]).join(" "))}}if("function"==typeof o)return o(null===s?{}:s,C,vdomFnUtils);const S=newVNode(o,null);return S.$attrs$=s,C.length>0&&(S.$children$=C),S.$key$=a,S.$name$=c,S},newVNode=(o,s)=>({$flags$:0,$tag$:o,$text$:s,$elm$:null,$children$:null,$attrs$:null,$key$:null,$name$:null}),Host={},isHost=o=>o&&o.$tag$===Host,vdomFnUtils={forEach:(o,s)=>o.map(convertToPublic).forEach(s),map:(o,s)=>o.map(convertToPublic).map(s).map(convertToPrivate)},convertToPublic=o=>({vattrs:o.$attrs$,vchildren:o.$children$,vkey:o.$key$,vname:o.$name$,vtag:o.$tag$,vtext:o.$text$}),convertToPrivate=o=>{if("function"==typeof o.vtag){const r={...o.vattrs};return o.vkey&&(r.key=o.vkey),o.vname&&(r.name=o.vname),h(o.vtag,r,...o.vchildren||[])}const s=newVNode(o.vtag,o.vtext);return s.$attrs$=o.vattrs,s.$children$=o.vchildren,s.$key$=o.vkey,s.$name$=o.vname,s},computeMode=o=>modeResolutionChain.map(s=>s(o)).find(s=>!!s),parsePropertyValue=(o,s)=>null==o||isComplexType(o)?o:4&s?"false"!==o&&(""===o||!!o):2&s?parseFloat(o):1&s?String(o):o,getElement=o=>o,createEvent=(o,s,r)=>{const i=getElement(o);return{emit:a=>emitEvent(i,s,{bubbles:!!(4&r),composed:!!(2&r),cancelable:!!(1&r),detail:a})}},emitEvent=(o,s,r)=>{const i=plt.ce(s,r);return o.dispatchEvent(i),i},rootAppliedStyles=new WeakMap,registerStyle=(o,s,r)=>{let i=styles.get(o);supportsConstructableStylesheets&&r?(i=i||new CSSStyleSheet,"string"==typeof i?i=s:i.replaceSync(s)):i=s,styles.set(o,i)},addStyle=(o,s,r)=>{var i;const a=getScopeId(s,r),c=styles.get(a);if(o=11===o.nodeType?o:doc,c)if("string"==typeof c){let y,w=rootAppliedStyles.get(o=o.head||o);if(w||rootAppliedStyles.set(o,w=new Set),!w.has(a)){{y=doc.createElement("style"),y.innerHTML=c;const C=null!=(i=plt.$nonce$)?i:queryNonceMetaTagContent(doc);null!=C&&y.setAttribute("nonce",C),(!(1&s.$flags$)||1&s.$flags$&&"HEAD"!==o.nodeName)&&o.insertBefore(y,o.querySelector("link"))}4&s.$flags$&&(y.innerHTML+=SLOT_FB_CSS),w&&w.add(a)}}else o.adoptedStyleSheets.includes(c)||(o.adoptedStyleSheets=[...o.adoptedStyleSheets,c]);return a},attachStyles=o=>{const s=o.$cmpMeta$,r=o.$hostElement$,i=s.$flags$,a=createTime("attachStyles",s.$tagName$),c=addStyle(r.shadowRoot?r.shadowRoot:r.getRootNode(),s,o.$modeName$);10&i&&2&i&&(r["s-sc"]=c,r.classList.add(c+"-h"),2&i&&r.classList.add(c+"-s")),a()},getScopeId=(o,s)=>"sc-"+(s&&32&o.$flags$?o.$tagName$+"-"+s:o.$tagName$),setAccessor=(o,s,r,i,a,c)=>{if(r!==i){let y=isMemberInElement(o,s),w=s.toLowerCase();if("class"===s){const C=o.classList,T=parseClassList(r),S=parseClassList(i);C.remove(...T.filter(M=>M&&!S.includes(M))),C.add(...S.filter(M=>M&&!T.includes(M)))}else if("style"===s){for(const C in r)i&&null!=i[C]||(C.includes("-")?o.style.removeProperty(C):o.style[C]="");for(const C in i)r&&i[C]===r[C]||(C.includes("-")?o.style.setProperty(C,i[C]):o.style[C]=i[C])}else if("key"!==s)if("ref"===s)i&&i(o);else if(o.__lookupSetter__(s)||"o"!==s[0]||"n"!==s[1]){const C=isComplexType(i);if((y||C&&null!==i)&&!a)try{if(o.tagName.includes("-"))o[s]=i;else{const S=i??"";"list"===s?y=!1:null!=r&&o[s]==S||(o[s]=S)}}catch{}let T=!1;w!==(w=w.replace(/^xlink\:?/,""))&&(s=w,T=!0),null==i||!1===i?!1===i&&""!==o.getAttribute(s)||(T?o.removeAttributeNS(XLINK_NS,s):o.removeAttribute(s)):(!y||4&c||a)&&!C&&(i=!0===i?"":i,T?o.setAttributeNS(XLINK_NS,s,i):o.setAttribute(s,i))}else if(s="-"===s[2]?s.slice(3):isMemberInElement(win,w)?w.slice(2):w[2]+s.slice(3),r||i){const C=s.endsWith(CAPTURE_EVENT_SUFFIX);s=s.replace(CAPTURE_EVENT_REGEX,""),r&&plt.rel(o,s,r,C),i&&plt.ael(o,s,i,C)}}},parseClassListRegex=/\s/,parseClassList=o=>o?o.split(parseClassListRegex):[],CAPTURE_EVENT_SUFFIX="Capture",CAPTURE_EVENT_REGEX=new RegExp(CAPTURE_EVENT_SUFFIX+"$"),updateElement=(o,s,r)=>{const i=11===s.$elm$.nodeType&&s.$elm$.host?s.$elm$.host:s.$elm$,a=o&&o.$attrs$||EMPTY_OBJ,c=s.$attrs$||EMPTY_OBJ;for(const y of sortedAttrNames(Object.keys(a)))y in c||setAccessor(i,y,a[y],void 0,r,s.$flags$);for(const y of sortedAttrNames(Object.keys(c)))setAccessor(i,y,a[y],c[y],r,s.$flags$)},scopeId,contentRef,hostTagName;function sortedAttrNames(o){return o.includes("ref")?[...o.filter(s=>"ref"!==s),"ref"]:o}var useNativeShadowDom=!1,checkSlotFallbackVisibility=!1,checkSlotRelocate=!1,isSvgMode=!1,createElm=(o,s,r,i)=>{var a;const c=s.$children$[r];let y,w,C,T=0;if(useNativeShadowDom||(checkSlotRelocate=!0,"slot"===c.$tag$&&(scopeId&&i.classList.add(scopeId+"-s"),c.$flags$|=c.$children$?2:1)),null!==c.$text$)y=c.$elm$=doc.createTextNode(c.$text$);else if(1&c.$flags$)y=c.$elm$=doc.createTextNode("");else{if(isSvgMode||(isSvgMode="svg"===c.$tag$),y=c.$elm$=doc.createElementNS(isSvgMode?SVG_NS:HTML_NS,!useNativeShadowDom&&BUILD.slotRelocation&&2&c.$flags$?"slot-fb":c.$tag$),isSvgMode&&"foreignObject"===c.$tag$&&(isSvgMode=!1),updateElement(null,c,isSvgMode),y.getRootNode().querySelector("body")&&BUILD.scoped&&isDef(scopeId)&&y["s-si"]!==scopeId&&y.classList.add(y["s-si"]=scopeId),updateElementScopeIds(y,i),c.$children$)for(T=0;T{plt.$flags$|=1;const r=Array.from(o.childNodes);if(o["s-sr"]&&BUILD.experimentalSlotFixes){let i=o;for(;i=i.nextSibling;)i&&i["s-sn"]===o["s-sn"]&&i["s-sh"]===hostTagName&&r.push(i)}for(let i=r.length-1;i>=0;i--){const a=r[i];a["s-hn"]!==hostTagName&&a["s-ol"]&&(insertBefore(parentReferenceNode(a),a,referenceNode(a)),a["s-ol"].remove(),a["s-ol"]=void 0,a["s-sh"]=void 0,checkSlotRelocate=!0),s&&putBackInOriginalLocation(a,s)}plt.$flags$&=-2},addVnodes=(o,s,r,i,a,c)=>{let y,w=o["s-cr"]&&o["s-cr"].parentNode||o;for(w.shadowRoot&&w.tagName===hostTagName&&(w=w.shadowRoot);a<=c;++a)i[a]&&(y=createElm(null,r,a,o),y&&(i[a].$elm$=y,insertBefore(w,y,referenceNode(s))))},removeVnodes=(o,s,r)=>{for(let i=s;i<=r;++i){const a=o[i];if(a){const c=a.$elm$;nullifyVNodeRefs(a),c&&(checkSlotFallbackVisibility=!0,c["s-ol"]?c["s-ol"].remove():putBackInOriginalLocation(c,!0),c.remove())}}},updateChildren=(o,s,r,i,a=!1)=>{let c,y,w=0,C=0,T=0,S=0,M=s.length-1,O=s[0],L=s[M],Z=i.length-1,q=i[0],re=i[Z];for(;w<=M&&C<=Z;)if(null==O)O=s[++w];else if(null==L)L=s[--M];else if(null==q)q=i[++C];else if(null==re)re=i[--Z];else if(isSameVnode(O,q,a))patch(O,q,a),O=s[++w],q=i[++C];else if(isSameVnode(L,re,a))patch(L,re,a),L=s[--M],re=i[--Z];else if(isSameVnode(O,re,a))"slot"!==O.$tag$&&"slot"!==re.$tag$||putBackInOriginalLocation(O.$elm$.parentNode,!1),patch(O,re,a),insertBefore(o,O.$elm$,L.$elm$.nextSibling),O=s[++w],re=i[--Z];else if(isSameVnode(L,q,a))"slot"!==O.$tag$&&"slot"!==re.$tag$||putBackInOriginalLocation(L.$elm$.parentNode,!1),patch(L,q,a),insertBefore(o,L.$elm$,O.$elm$),L=s[--M],q=i[++C];else{for(T=-1,S=w;S<=M;++S)if(s[S]&&null!==s[S].$key$&&s[S].$key$===q.$key$){T=S;break}T>=0?(y=s[T],y.$tag$!==q.$tag$?c=createElm(s&&s[C],r,T,o):(patch(y,q,a),s[T]=void 0,c=y.$elm$),q=i[++C]):(c=createElm(s&&s[C],r,C,o),q=i[++C]),c&&insertBefore(parentReferenceNode(O.$elm$),c,referenceNode(O.$elm$))}w>M?addVnodes(o,null==i[Z+1]?null:i[Z+1].$elm$,r,i,C,Z):C>Z&&removeVnodes(s,w,M)},isSameVnode=(o,s,r=!1)=>!(o.$tag$!==s.$tag$||("slot"===o.$tag$?"$nodeId$"in o&&r&&8!==o.$elm$.nodeType||o.$name$!==s.$name$:!r&&o.$key$!==s.$key$)),referenceNode=o=>o&&o["s-ol"]||o,parentReferenceNode=o=>(o["s-ol"]?o["s-ol"]:o).parentNode,patch=(o,s,r=!1)=>{const i=s.$elm$=o.$elm$,a=o.$children$,c=s.$children$,y=s.$tag$,w=s.$text$;let C;null===w?(isSvgMode="svg"===y||"foreignObject"!==y&&isSvgMode,("slot"!==y||useNativeShadowDom)&&updateElement(o,s,isSvgMode),null!==a&&null!==c?updateChildren(i,a,s,c,r):null!==c?(null!==o.$text$&&(i.textContent=""),addVnodes(i,null,s,c,0,c.length-1)):!r&&BUILD.updatable&&null!==a&&removeVnodes(a,0,a.length-1),isSvgMode&&"svg"===y&&(isSvgMode=!1)):(C=i["s-cr"])?C.parentNode.textContent=w:o.$text$!==w&&(i.data=w)},updateFallbackSlotVisibility=o=>{const s=o.childNodes;for(const r of s)if(1===r.nodeType){if(r["s-sr"]){const i=r["s-sn"];r.hidden=!1;for(const a of s)if(a!==r)if(a["s-hn"]!==r["s-hn"]||""!==i){if(1===a.nodeType&&(i===a.getAttribute("slot")||i===a["s-sn"])||3===a.nodeType&&i===a["s-sn"]){r.hidden=!0;break}}else if(1===a.nodeType||3===a.nodeType&&""!==a.textContent.trim()){r.hidden=!0;break}}updateFallbackSlotVisibility(r)}},relocateNodes=[],markSlotContentForRelocation=o=>{let s,r,i;for(const a of o.childNodes){if(a["s-sr"]&&(s=a["s-cr"])&&s.parentNode){r=s.parentNode.childNodes;const c=a["s-sn"];for(i=r.length-1;i>=0;i--)if(s=r[i],!s["s-cn"]&&!s["s-nr"]&&s["s-hn"]!==a["s-hn"]&&!BUILD.experimentalSlotFixes)if(isNodeLocatedInSlot(s,c)){let y=relocateNodes.find(w=>w.$nodeToRelocate$===s);checkSlotFallbackVisibility=!0,s["s-sn"]=s["s-sn"]||c,y?(y.$nodeToRelocate$["s-sh"]=a["s-hn"],y.$slotRefNode$=a):(s["s-sh"]=a["s-hn"],relocateNodes.push({$slotRefNode$:a,$nodeToRelocate$:s})),s["s-sr"]&&relocateNodes.map(w=>{isNodeLocatedInSlot(w.$nodeToRelocate$,s["s-sn"])&&(y=relocateNodes.find(C=>C.$nodeToRelocate$===s),y&&!w.$slotRefNode$&&(w.$slotRefNode$=y.$slotRefNode$))})}else relocateNodes.some(y=>y.$nodeToRelocate$===s)||relocateNodes.push({$nodeToRelocate$:s})}1===a.nodeType&&markSlotContentForRelocation(a)}},isNodeLocatedInSlot=(o,s)=>1===o.nodeType?null===o.getAttribute("slot")&&""===s||o.getAttribute("slot")===s:o["s-sn"]===s||""===s,nullifyVNodeRefs=o=>{o.$attrs$&&o.$attrs$.ref&&o.$attrs$.ref(null),o.$children$&&o.$children$.map(nullifyVNodeRefs)},insertBefore=(o,s,r)=>{const i=o?.insertBefore(s,r);return updateElementScopeIds(s,o),i},findScopeIds=o=>{const s=[];return o&&s.push(...o["s-scs"]||[],o["s-si"],o["s-sc"],...findScopeIds(o.parentElement)),s},updateElementScopeIds=(o,s,r=!1)=>{var i;if(o&&s&&1===o.nodeType){const a=new Set(findScopeIds(s).filter(Boolean));if(a.size&&(null==(i=o.classList)||i.add(...o["s-scs"]=[...a]),o["s-ol"]||r))for(const c of Array.from(o.childNodes))updateElementScopeIds(c,o,!0)}},renderVdom=(o,s,r=!1)=>{var i,a,c,y,w;const C=o.$hostElement$,T=o.$cmpMeta$,S=o.$vnode$||newVNode(null,null),M=isHost(s)?s:h(null,null,s);if(hostTagName=C.tagName,T.$attrsToReflect$&&(M.$attrs$=M.$attrs$||{},T.$attrsToReflect$.map(([O,L])=>M.$attrs$[L]=C[O])),r&&M.$attrs$)for(const O of Object.keys(M.$attrs$))C.hasAttribute(O)&&!["key","ref","style","class"].includes(O)&&(M.$attrs$[O]=C[O]);if(M.$tag$=null,M.$flags$|=4,o.$vnode$=M,M.$elm$=S.$elm$=C.shadowRoot||C,scopeId=C["s-sc"],useNativeShadowDom=!!(1&T.$flags$),contentRef=C["s-cr"],checkSlotFallbackVisibility=!1,patch(S,M,r),plt.$flags$|=1,checkSlotRelocate){markSlotContentForRelocation(M.$elm$);for(const O of relocateNodes){const L=O.$nodeToRelocate$;if(!L["s-ol"]){const Z=doc.createTextNode("");Z["s-nr"]=L,insertBefore(L.parentNode,L["s-ol"]=Z,L)}}for(const O of relocateNodes){const L=O.$nodeToRelocate$,Z=O.$slotRefNode$;if(Z){const q=Z.parentNode;let re=Z.nextSibling;{let pe=null==(i=L["s-ol"])?void 0:i.previousSibling;for(;pe;){let se=null!=(a=pe["s-nr"])?a:null;if(se&&se["s-sn"]===L["s-sn"]&&q===se.parentNode){for(se=se.nextSibling;se===L||se?.["s-sr"];)se=se?.nextSibling;if(!se||!se["s-nr"]){re=se;break}}pe=pe.previousSibling}}(!re&&q!==L.parentNode||L.nextSibling!==re)&&L!==re&&(!L["s-hn"]&&L["s-ol"]&&(L["s-hn"]=L["s-ol"].parentNode.nodeName),insertBefore(q,L,re),1===L.nodeType&&(L.hidden=null!=(c=L["s-ih"])&&c)),L&&"function"==typeof Z["s-rf"]&&Z["s-rf"](L)}else 1===L.nodeType&&(r&&(L["s-ih"]=null!=(y=L.hidden)&&y),L.hidden=!0)}}if(checkSlotFallbackVisibility&&updateFallbackSlotVisibility(M.$elm$),plt.$flags$&=-2,relocateNodes.length=0,BUILD.experimentalScopedSlotChanges&&2&T.$flags$)for(const O of M.$elm$.childNodes)O["s-hn"]===hostTagName||O["s-sh"]||(r&&null==O["s-ih"]&&(O["s-ih"]=null!=(w=O.hidden)&&w),O.hidden=!0);contentRef=void 0},attachToAncestor=(o,s)=>{},scheduleUpdate=(o,s)=>(o.$flags$|=16,attachToAncestor(o,o.$ancestorComponent$),writeTask(()=>dispatchHooks(o,s))),dispatchHooks=(o,s)=>{const r=o.$hostElement$,i=createTime("scheduleUpdate",o.$cmpMeta$.$tagName$),a=r;if(!a)throw new Error(`Can't render component <${r.tagName.toLowerCase()} /> with invalid Stencil runtime! Make sure this imported component is compiled with a \`externalRuntime: true\` flag. For more information, please refer to https://stenciljs.com/docs/custom-elements#externalruntime`);let c;return c=safeCall(a,s?"componentWillLoad":"componentWillUpdate"),c=enqueue(c,()=>safeCall(a,"componentWillRender")),i(),enqueue(c,()=>updateComponent(o,a,s))},enqueue=(o,s)=>isPromisey(o)?o.then(s).catch(r=>{console.error(r),s()}):s(),isPromisey=o=>o instanceof Promise||o&&o.then&&"function"==typeof o.then,updateComponent=function(){var o=(0,_home_runner_work_angor_hub_angor_hub_node_modules_angular_builders_custom_webpack_node_modules_babel_runtime_helpers_esm_asyncToGenerator_js__WEBPACK_IMPORTED_MODULE_1__.A)(function*(s,r,i){const a=s.$hostElement$,c=createTime("update",s.$cmpMeta$.$tagName$);i&&attachStyles(s);const y=createTime("render",s.$cmpMeta$.$tagName$);callRender(s,r,a,i),y(),c(),postUpdateComponent(s)});return function(r,i,a){return o.apply(this,arguments)}}(),renderingRef=null,callRender=(o,s,r,i)=>{try{renderingRef=s,s=s.render&&s.render(),o.$flags$&=-17,o.$flags$|=2,(BUILD.hasRenderFn||BUILD.reflect)&&(BUILD.vdomRender||BUILD.reflect)&&(BUILD.hydrateServerSide||renderVdom(o,s,i))}catch(a){consoleError(a,o.$hostElement$)}return renderingRef=null,null},getRenderingRef=()=>renderingRef,postUpdateComponent=o=>{const r=o.$hostElement$,i=createTime("postUpdate",o.$cmpMeta$.$tagName$),a=r;safeCall(a,"componentDidRender"),64&o.$flags$?(safeCall(a,"componentDidUpdate"),i()):(o.$flags$|=64,safeCall(a,"componentDidLoad"),i())},forceUpdate=o=>{{const s=getHostRef(o),r=s.$hostElement$.isConnected;return r&&2==(18&s.$flags$)&&scheduleUpdate(s,!1),r}},safeCall=(o,s,r)=>{if(o&&o[s])try{return o[s](r)}catch(i){consoleError(i)}},getValue=(o,s)=>getHostRef(o).$instanceValues$.get(s),setValue=(o,s,r,i)=>{const a=getHostRef(o),c=o,y=a.$instanceValues$.get(s),w=a.$flags$,C=c;r=parsePropertyValue(r,i.$members$[s][0]);const T=Number.isNaN(y)&&Number.isNaN(r);if(r!==y&&!T){if(a.$instanceValues$.set(s,r),i.$watchers$&&128&w){const S=i.$watchers$[s];S&&S.map(M=>{try{C[M](r,y,s)}catch(O){consoleError(O,c)}})}if(2==(18&w)){if(C.componentShouldUpdate&&!1===C.componentShouldUpdate(r,y,s))return;scheduleUpdate(a,!1)}}},proxyComponent=(o,s,r)=>{var i,a;const c=o.prototype;if(s.$members$||s.$watchers$||o.watchers){o.watchers&&!s.$watchers$&&(s.$watchers$=o.watchers);const y=Object.entries(null!=(i=s.$members$)?i:{});y.map(([w,[C]])=>{(31&C||32&C)&&Object.defineProperty(c,w,{get(){return getValue(this,w)},set(T){setValue(this,w,T,s)},configurable:!0,enumerable:!0})});{const w=new Map;c.attributeChangedCallback=function(C,T,S){plt.jmp(()=>{var M;const O=w.get(C);if(this.hasOwnProperty(O))S=this[O],delete this[O];else{if(c.hasOwnProperty(O)&&"number"==typeof this[O]&&this[O]==S)return;if(null==O){const L=getHostRef(this),Z=L?.$flags$;if(Z&&!(8&Z)&&128&Z&&S!==T){const q=this,re=null==(M=s.$watchers$)?void 0:M[C];re?.forEach(pe=>{null!=q[pe]&&q[pe].call(q,S,T,C)})}return}}this[O]=(null!==S||"boolean"!=typeof this[O])&&S})},o.observedAttributes=Array.from(new Set([...Object.keys(null!=(a=s.$watchers$)?a:{}),...y.filter(([C,T])=>15&T[0]).map(([C,T])=>{var S;const M=T[1]||C;return w.set(M,C),512&T[0]&&(null==(S=s.$attrsToReflect$)||S.push([C,M])),M})]))}}return o},initializeComponent=function(){var o=(0,_home_runner_work_angor_hub_angor_hub_node_modules_angular_builders_custom_webpack_node_modules_babel_runtime_helpers_esm_asyncToGenerator_js__WEBPACK_IMPORTED_MODULE_1__.A)(function*(s,r,i,a){let c;if(!(32&r.$flags$)&&(r.$flags$|=32,c=s.constructor,customElements.whenDefined(s.localName).then(()=>r.$flags$|=128),c&&c.style)){let y;"string"==typeof c.style?y=c.style:"string"!=typeof c.style&&(r.$modeName$=computeMode(s),r.$modeName$&&(y=c.style[r.$modeName$]));const w=getScopeId(i,r.$modeName$);if(!styles.has(w)){const C=createTime("registerStyles",i.$tagName$);registerStyle(w,y,!!(1&i.$flags$)),C()}}scheduleUpdate(r,!0)});return function(r,i,a,c){return o.apply(this,arguments)}}(),fireConnectedCallback=o=>{},connectedCallback=o=>{if(!(1&plt.$flags$)){const s=getHostRef(o),r=s.$cmpMeta$,i=createTime("connectedCallback",r.$tagName$);1&s.$flags$?(addHostEventListeners(o,s,r.$listeners$),s?.$lazyInstance$?fireConnectedCallback(s.$lazyInstance$):s?.$onReadyPromise$&&s.$onReadyPromise$.then(()=>fireConnectedCallback(s.$lazyInstance$))):(s.$flags$|=1,12&r.$flags$&&setContentReference(o),r.$members$&&Object.entries(r.$members$).map(([a,[c]])=>{if(31&c&&o.hasOwnProperty(a)){const y=o[a];delete o[a],o[a]=y}}),initializeComponent(o,s,r)),i()}},setContentReference=o=>{const s=o["s-cr"]=doc.createComment("");s["s-cn"]=!0,insertBefore(o,s,o.firstChild)},disconnectedCallback=function(){var o=(0,_home_runner_work_angor_hub_angor_hub_node_modules_angular_builders_custom_webpack_node_modules_babel_runtime_helpers_esm_asyncToGenerator_js__WEBPACK_IMPORTED_MODULE_1__.A)(function*(s){if(!(1&plt.$flags$)){const r=getHostRef(s);r.$rmListeners$&&(r.$rmListeners$.map(i=>i()),r.$rmListeners$=void 0)}});return function(r){return o.apply(this,arguments)}}(),proxyCustomElement=(o,s)=>{const r={$flags$:s[0],$tagName$:s[1]};r.$members$=s[2],r.$listeners$=s[3],r.$watchers$=o.$watchers$,r.$attrsToReflect$=[];const i=o.prototype.connectedCallback,a=o.prototype.disconnectedCallback;return Object.assign(o.prototype,{__registerHost(){registerHost(this,r)},connectedCallback(){const c=getHostRef(this);addHostEventListeners(this,c,r.$listeners$),connectedCallback(this),i&&i.call(this)},disconnectedCallback(){disconnectedCallback(this),a&&a.call(this)},__attachShadow(){if(this.shadowRoot){if("open"!==this.shadowRoot.mode)throw new Error(`Unable to re-use existing shadow root for ${r.$tagName$}! Mode is set to ${this.shadowRoot.mode} but Stencil only supports open shadow roots.`)}else this.attachShadow({mode:"open",delegatesFocus:!!(16&r.$flags$)})}}),o.is=r.$tagName$,proxyComponent(o,r)},Fragment=(o,s)=>s,addHostEventListeners=(o,s,r,i)=>{r&&r.map(([a,c,y])=>{const w=getHostListenerTarget(o,a),C=hostListenerProxy(s,y),T=hostListenerOpts(a);plt.ael(w,c,C,T),(s.$rmListeners$=s.$rmListeners$||[]).push(()=>plt.rel(w,c,C,T))})},hostListenerProxy=(o,s)=>r=>{try{BUILD.lazyLoad||o.$hostElement$[s](r)}catch(i){consoleError(i)}},getHostListenerTarget=(o,s)=>4&s?doc:8&s?win:16&s?doc.body:o,hostListenerOpts=o=>supportsListenerOptions?{passive:!!(1&o),capture:!!(2&o)}:!!(2&o),CURRENT_MODULE,METHOD_MODULE,o;o=CURRENT_MODULE||(CURRENT_MODULE={}),o.WELCOME="welcome",o.WELCOME_LOGIN="welcome-login",o.WELCOME_SIGNUP="welcome-signup",o.INFO="info",o.LOGIN_BUNKER_URL="login-bunker-url",o.LOGIN_READ_ONLY="login-read-only",o.CONFIRM_LOGOUT="confirm-logout",o.IMPORT_FLOW="import",o.IMPORT_OTP="import-otp",o.LOGIN="login",o.SIGNUP="signup",o.LOCAL_SIGNUP="local-signup",o.EXTENSION="extension",o.LOADING="loading",o.PREVIOUSLY_LOGGED="switch-account",o.LOGIN_OTP="otp",o.CONNECT="connect",o.CONNECTION_STRING="connection-string",o.IFRAME="iframe",function(o){o.LOGIN="login",o.SIGNUP="signup",o.LOGOUT="logout",o.CONFIRM="confirm"}(METHOD_MODULE||(METHOD_MODULE={}));const appendToMap=(o,s,r)=>{const i=o.get(s);i?i.includes(r)||i.push(r):o.set(s,[r])},debounce=(o,s)=>{let r;return(...i)=>{r&&clearTimeout(r),r=setTimeout(()=>{r=0,o(...i)},s)}},isConnected=o=>!("isConnected"in o)||o.isConnected,cleanupElements=debounce(o=>{for(let s of o.keys())o.set(s,o.get(s).filter(isConnected))},2e3),stencilSubscription=()=>{if("function"!=typeof getRenderingRef)return{};const o=new Map;return{dispose:()=>o.clear(),get:s=>{const r=getRenderingRef();r&&appendToMap(o,s,r)},set:s=>{const r=o.get(s);r&&o.set(s,r.filter(forceUpdate)),cleanupElements(o)},reset:()=>{o.forEach(s=>s.forEach(forceUpdate)),cleanupElements(o)}}},unwrap=o=>"function"==typeof o?o():o,createObservableMap=(o,s=(r,i)=>r!==i)=>{const r=unwrap(o);let i=new Map(Object.entries(r??{}));const a={dispose:[],get:[],set:[],reset:[]},c=()=>{var S;i=new Map(Object.entries(null!==(S=unwrap(o))&&void 0!==S?S:{})),a.reset.forEach(M=>M())},y=S=>(a.get.forEach(M=>M(S)),i.get(S)),w=(S,M)=>{const O=i.get(S);s(M,O,S)&&(i.set(S,M),a.set.forEach(L=>L(S,M,O)))},C=typeof Proxy>"u"?{}:new Proxy(r,{get:(S,M)=>y(M),ownKeys:S=>Array.from(i.keys()),getOwnPropertyDescriptor:()=>({enumerable:!0,configurable:!0}),has:(S,M)=>i.has(M),set:(S,M,O)=>(w(M,O),!0)}),T=(S,M)=>(a[S].push(M),()=>{removeFromArray(a[S],M)});return{state:C,get:y,set:w,on:T,onChange:(S,M)=>{const O=T("set",(Z,q)=>{Z===S&&M(q)}),L=T("reset",()=>M(unwrap(o)[S]));return()=>{O(),L()}},use:(...S)=>{const M=S.reduce((O,L)=>(L.set&&O.push(T("set",L.set)),L.get&&O.push(T("get",L.get)),L.reset&&O.push(T("reset",L.reset)),L.dispose&&O.push(T("dispose",L.dispose)),O),[]);return()=>M.forEach(O=>O())},dispose:()=>{a.dispose.forEach(S=>S()),c()},reset:c,forceUpdate:S=>{const M=i.get(S);a.set.forEach(O=>O(S,M,M))}}},removeFromArray=(o,s)=>{const r=o.indexOf(s);r>=0&&(o[r]=o[o.length-1],o.length--)},createStore=(o,s)=>{const r=createObservableMap(o,s);return r.use(stencilSubscription()),r},{state,onChange}=createStore({screen:CURRENT_MODULE.WELCOME,prevScreen:CURRENT_MODULE.WELCOME,path:[CURRENT_MODULE.WELCOME],error:"",isLoading:!1,isLoadingExtension:!1,isOTP:!1,authUrl:"",iframeUrl:"",localSignup:!1,nlSignin:{loginName:""},nlSignup:{signupName:"",domain:"",servers:[{name:"@nsec.app",value:"nsec.app"},{name:"@highlighter.com",value:"highlighter.com"}]},nlSigninBunkerUrl:{loginName:""},nlSigninReadOnly:{loginName:""},nlSigninOTP:{loginName:"",code:""},nlImport:null});onChange("screen",()=>{state.error="",state.nlSignin.loginName="",state.nlSignup.signupName="",state.nlSignup.domain=""});const baseCss="/*! tailwindcss v3.4.10 | MIT License | https://tailwindcss.com*/*,:after,:before{--tw-border-spacing-x:0;--tw-border-spacing-y:0;--tw-translate-x:0;--tw-translate-y:0;--tw-rotate:0;--tw-skew-x:0;--tw-skew-y:0;--tw-scale-x:1;--tw-scale-y:1;--tw-scroll-snap-strictness:proximity;--tw-ring-offset-width:0px;--tw-ring-offset-color:#fff;--tw-ring-color:rgba(59,130,246,.5);--tw-ring-offset-shadow:0 0 #0000;--tw-ring-shadow:0 0 #0000;--tw-shadow:0 0 #0000;--tw-shadow-colored:0 0 #0000;border:0 solid #e5e7eb;box-sizing:border-box}:after,:before{--tw-content:\"\"}:host,html{-webkit-text-size-adjust:100%;font-feature-settings:normal;-webkit-tap-highlight-color:transparent;font-family:ui-sans-serif,system-ui,sans-serif,Apple Color Emoji,Segoe UI Emoji,Segoe UI Symbol,Noto Color Emoji;font-variation-settings:normal;line-height:1.5;-moz-tab-size:4;tab-size:4}body{line-height:inherit;margin:0}hr{border-top-width:1px;color:inherit;height:0}abbr:where([title]){text-decoration:underline dotted}h1,h2,h3,h4,h5,h6{font-size:inherit;font-weight:inherit}a{color:inherit;text-decoration:inherit}b,strong{font-weight:bolder}code,kbd,pre,samp{font-feature-settings:normal;font-family:ui-monospace,SFMono-Regular,Menlo,Monaco,Consolas,Liberation Mono,Courier New,monospace;font-size:1em;font-variation-settings:normal}small{font-size:80%}sub,sup{font-size:75%;line-height:0;position:relative;vertical-align:baseline}sub{bottom:-.25em}sup{top:-.5em}table{border-collapse:collapse;border-color:inherit;text-indent:0}button,input,optgroup,select,textarea{font-feature-settings:inherit;color:inherit;font-family:inherit;font-size:100%;font-variation-settings:inherit;font-weight:inherit;letter-spacing:inherit;line-height:inherit;margin:0;padding:0}button,select{text-transform:none}button,input:where([type=button]),input:where([type=reset]),input:where([type=submit]){-webkit-appearance:button;background-color:transparent;background-image:none}:-moz-focusring{outline:auto}:-moz-ui-invalid{box-shadow:none}progress{vertical-align:baseline}::-webkit-inner-spin-button,::-webkit-outer-spin-button{height:auto}[type=search]{-webkit-appearance:textfield;outline-offset:-2px}::-webkit-search-decoration{-webkit-appearance:none}::-webkit-file-upload-button{-webkit-appearance:button;font:inherit}summary{display:list-item}blockquote,dd,dl,fieldset,figure,h1,h2,h3,h4,h5,h6,hr,p,pre{margin:0}fieldset,legend{padding:0}menu,ol,ul{list-style:none;margin:0;padding:0}dialog{padding:0}textarea{resize:vertical}input::placeholder,textarea::placeholder{color:#9ca3af;color:#6b7280;opacity:1}[role=button],button{cursor:pointer}:disabled{cursor:default}audio,canvas,embed,iframe,img,object,svg,video{display:block;vertical-align:middle}img,video{height:auto;max-width:100%}[hidden]{display:none}[multiple],[type=date],[type=datetime-local],[type=email],[type=month],[type=number],[type=password],[type=search],[type=tel],[type=text],[type=time],[type=url],[type=week],input:where(:not([type])),select,textarea{--tw-shadow:0 0 #0000;appearance:none;background-color:#fff;border-color:#6b7280;border-radius:0;border-width:1px;font-size:1rem;line-height:1.5rem;padding:.5rem .75rem}[multiple]:focus,[type=date]:focus,[type=datetime-local]:focus,[type=email]:focus,[type=month]:focus,[type=number]:focus,[type=password]:focus,[type=search]:focus,[type=tel]:focus,[type=text]:focus,[type=time]:focus,[type=url]:focus,[type=week]:focus,input:where(:not([type])):focus,select:focus,textarea:focus{--tw-ring-inset:var(--tw-empty, );--tw-ring-offset-width:0px;--tw-ring-offset-color:#fff;--tw-ring-color:#2563eb;--tw-ring-offset-shadow:var(--tw-ring-inset) 0 0 0 var(--tw-ring-offset-width) var(--tw-ring-offset-color);--tw-ring-shadow:var(--tw-ring-inset) 0 0 0 calc(1px + var(--tw-ring-offset-width)) var(--tw-ring-color);border-color:#2563eb;box-shadow:var(--tw-ring-offset-shadow),var(--tw-ring-shadow),var(--tw-shadow);outline:2px solid transparent;outline-offset:2px}::-webkit-datetime-edit-fields-wrapper{padding:0}::-webkit-date-and-time-value{min-height:1.5em;text-align:inherit}::-webkit-datetime-edit{display:inline-flex}::-webkit-datetime-edit,::-webkit-datetime-edit-day-field,::-webkit-datetime-edit-hour-field,::-webkit-datetime-edit-meridiem-field,::-webkit-datetime-edit-millisecond-field,::-webkit-datetime-edit-minute-field,::-webkit-datetime-edit-month-field,::-webkit-datetime-edit-second-field,::-webkit-datetime-edit-year-field{padding-bottom:0;padding-top:0}select{background-image:url(\"data:image/svg+xml;charset=utf-8,%3Csvg xmlns='http://www.w3.org/2000/svg' fill='none' viewBox='0 0 20 20'%3E%3Cpath stroke='%236b7280' stroke-linecap='round' stroke-linejoin='round' stroke-width='1.5' d='m6 8 4 4 4-4'/%3E%3C/svg%3E\");background-position:right .5rem center;background-repeat:no-repeat;background-size:1.5em 1.5em;padding-right:2.5rem;print-color-adjust:exact}[multiple],[size]:where(select:not([size=\"1\"])){background-image:none;background-position:0 0;background-repeat:unset;background-size:initial;padding-right:.75rem;print-color-adjust:unset}[type=checkbox],[type=radio]{--tw-shadow:0 0 #0000;appearance:none;background-color:#fff;background-origin:border-box;border-color:#6b7280;border-width:1px;color:#2563eb;display:inline-block;flex-shrink:0;height:1rem;padding:0;print-color-adjust:exact;user-select:none;vertical-align:middle;width:1rem}[type=checkbox]{border-radius:0}[type=radio]{border-radius:100%}[type=checkbox]:focus,[type=radio]:focus{--tw-ring-inset:var(--tw-empty, );--tw-ring-offset-width:2px;--tw-ring-offset-color:#fff;--tw-ring-color:#2563eb;--tw-ring-offset-shadow:var(--tw-ring-inset) 0 0 0 var(--tw-ring-offset-width) var(--tw-ring-offset-color);--tw-ring-shadow:var(--tw-ring-inset) 0 0 0 calc(2px + var(--tw-ring-offset-width)) var(--tw-ring-color);box-shadow:var(--tw-ring-offset-shadow),var(--tw-ring-shadow),var(--tw-shadow);outline:2px solid transparent;outline-offset:2px}[type=checkbox]:checked,[type=radio]:checked{background-color:currentColor;background-position:50%;background-repeat:no-repeat;background-size:100% 100%;border-color:transparent}[type=checkbox]:checked{background-image:url(\"data:image/svg+xml;charset=utf-8,%3Csvg viewBox='0 0 16 16' fill='%23fff' xmlns='http://www.w3.org/2000/svg'%3E%3Cpath d='M12.207 4.793a1 1 0 0 1 0 1.414l-5 5a1 1 0 0 1-1.414 0l-2-2a1 1 0 0 1 1.414-1.414L6.5 9.086l4.293-4.293a1 1 0 0 1 1.414 0z'/%3E%3C/svg%3E\")}@media (forced-colors:active){[type=checkbox]:checked{appearance:auto}}[type=radio]:checked{background-image:url(\"data:image/svg+xml;charset=utf-8,%3Csvg viewBox='0 0 16 16' fill='%23fff' xmlns='http://www.w3.org/2000/svg'%3E%3Ccircle cx='8' cy='8' r='3'/%3E%3C/svg%3E\")}@media (forced-colors:active){[type=radio]:checked{appearance:auto}}[type=checkbox]:checked:focus,[type=checkbox]:checked:hover,[type=radio]:checked:focus,[type=radio]:checked:hover{background-color:currentColor;border-color:transparent}[type=checkbox]:indeterminate{background-color:currentColor;background-image:url(\"data:image/svg+xml;charset=utf-8,%3Csvg xmlns='http://www.w3.org/2000/svg' fill='none' viewBox='0 0 16 16'%3E%3Cpath stroke='%23fff' stroke-linecap='round' stroke-linejoin='round' stroke-width='2' d='M4 8h8'/%3E%3C/svg%3E\");background-position:50%;background-repeat:no-repeat;background-size:100% 100%;border-color:transparent}@media (forced-colors:active){[type=checkbox]:indeterminate{appearance:auto}}[type=checkbox]:indeterminate:focus,[type=checkbox]:indeterminate:hover{background-color:currentColor;border-color:transparent}[type=file]{background:unset;border-color:inherit;border-radius:0;border-width:0;font-size:unset;line-height:inherit;padding:0}[type=file]:focus{outline:1px solid ButtonText;outline:1px auto -webkit-focus-ring-color}::backdrop{--tw-border-spacing-x:0;--tw-border-spacing-y:0;--tw-translate-x:0;--tw-translate-y:0;--tw-rotate:0;--tw-skew-x:0;--tw-skew-y:0;--tw-scale-x:1;--tw-scale-y:1;--tw-scroll-snap-strictness:proximity;--tw-ring-offset-width:0px;--tw-ring-offset-color:#fff;--tw-ring-color:rgba(59,130,246,.5);--tw-ring-offset-shadow:0 0 #0000;--tw-ring-shadow:0 0 #0000;--tw-shadow:0 0 #0000;--tw-shadow-colored:0 0 #0000;}.block{display:block}.transform{transform:translate(var(--tw-translate-x),var(--tw-translate-y)) rotate(var(--tw-rotate)) skewX(var(--tw-skew-x)) skewY(var(--tw-skew-y)) scaleX(var(--tw-scale-x)) scaleY(var(--tw-scale-y))}.theme-default .nl-bg{--tw-bg-opacity:1;--tw-shadow:0 1px 2px 0 rgba(0,0,0,.05);--tw-shadow-colored:0 1px 2px 0 var(--tw-shadow-color);background-color:rgb(255 255 255/var(--tw-bg-opacity));box-shadow:var(--tw-ring-offset-shadow,0 0 #0000),var(--tw-ring-shadow,0 0 #0000),var(--tw-shadow)}.theme-default .dark .nl-bg{--tw-bg-opacity:1;--tw-shadow-color:rgba(51,65,85,.7);--tw-shadow:var(--tw-shadow-colored);background-color:rgb(31 41 55/var(--tw-bg-opacity))}.theme-default .nl-description,.theme-default .nl-logo,.theme-default .nl-title{--tw-text-opacity:1;color:rgb(31 41 55/var(--tw-text-opacity))}.theme-default .dark .nl-description,.theme-default .dark .nl-logo,.theme-default .dark .nl-title{--tw-text-opacity:1;color:rgb(255 255 255/var(--tw-text-opacity))}.theme-default .nl-description a{--tw-text-opacity:1;color:rgb(30 64 175/var(--tw-text-opacity));text-decoration-line:underline}.theme-default .dark .nl-description a{--tw-text-opacity:1;color:rgb(191 219 254/var(--tw-text-opacity));text-decoration-line:underline}.theme-default .nl-action-button{--tw-text-opacity:1;color:rgb(31 41 55/var(--tw-text-opacity));outline:2px solid transparent;outline-offset:2px}.theme-default .nl-action-button:hover{--tw-bg-opacity:1;background-color:rgb(243 244 246/var(--tw-bg-opacity))}.theme-default .dark .nl-action-button{--tw-text-opacity:1;color:rgb(255 255 255/var(--tw-text-opacity));outline:2px solid transparent;outline-offset:2px}.theme-default .dark .nl-action-button:hover{--tw-bg-opacity:1;background-color:rgb(55 65 81/var(--tw-bg-opacity))}.theme-default .nl-title{--tw-text-opacity:1;color:rgb(31 41 55/var(--tw-text-opacity))}.theme-default .dark .nl-title{--tw-text-opacity:1;color:rgb(229 231 235/var(--tw-text-opacity))}.theme-default .nl-button{--tw-border-opacity:1;--tw-bg-opacity:1;--tw-text-opacity:1;--tw-shadow:0 1px 2px 0 rgba(0,0,0,.05);--tw-shadow-colored:0 1px 2px 0 var(--tw-shadow-color);background-color:rgb(255 255 255/var(--tw-bg-opacity));border-color:rgb(229 231 235/var(--tw-border-opacity));border-width:1px;box-shadow:var(--tw-ring-offset-shadow,0 0 #0000),var(--tw-ring-shadow,0 0 #0000),var(--tw-shadow);color:rgb(31 41 55/var(--tw-text-opacity))}.theme-default .nl-button:hover{--tw-bg-opacity:1;background-color:rgb(249 250 251/var(--tw-bg-opacity))}.theme-default .dark .nl-button{--tw-border-opacity:1;--tw-bg-opacity:1;--tw-text-opacity:1;background-color:rgb(15 23 42/var(--tw-bg-opacity));border-color:rgb(55 65 81/var(--tw-border-opacity));color:rgb(209 213 219/var(--tw-text-opacity))}.theme-default .dark .nl-button:hover{--tw-bg-opacity:1;background-color:rgb(31 41 55/var(--tw-bg-opacity))}.theme-default .nl-divider{--tw-text-opacity:1;color:rgb(156 163 175/var(--tw-text-opacity))}.theme-default .nl-divider:before{border-top-width:1px}.theme-default .nl-divider:after,.theme-default .nl-divider:before{--tw-border-opacity:1;border-color:rgb(229 231 235/var(--tw-border-opacity));content:var(--tw-content)}.theme-default .dark .nl-divider{--tw-text-opacity:1;color:rgb(107 114 128/var(--tw-text-opacity))}.theme-default .dark .nl-divider:after,.theme-default .dark .nl-divider:before{--tw-border-opacity:1;border-color:rgb(75 85 99/var(--tw-border-opacity));content:var(--tw-content)}.theme-default .nl-footer{--tw-text-opacity:1;color:rgb(31 41 55/var(--tw-text-opacity))}.theme-default .dark .nl-footer{--tw-text-opacity:1;color:rgb(229 231 235/var(--tw-text-opacity))}.theme-default .nl-error{--tw-text-opacity:1;color:rgb(153 27 27/var(--tw-text-opacity))}.theme-default .dark .nl-error{--tw-text-opacity:1;color:rgb(254 202 202/var(--tw-text-opacity))}.theme-default .nl-input{--tw-bg-opacity:1;background-color:rgb(243 244 246/var(--tw-bg-opacity))}.theme-default .nl-input:focus{--tw-border-opacity:1;--tw-ring-opacity:1;--tw-ring-color:rgb(168 85 247/var(--tw-ring-opacity));border-color:rgb(168 85 247/var(--tw-border-opacity))}.theme-default .dark .nl-input{--tw-bg-opacity:1;--tw-text-opacity:1;background-color:rgb(55 65 81/var(--tw-bg-opacity));color:rgb(156 163 175/var(--tw-text-opacity))}.theme-default .dark .nl-input:focus{--tw-ring-opacity:1;--tw-ring-color:rgb(75 85 99/var(--tw-ring-opacity))}.theme-default .nl-select{--tw-bg-opacity:1;background-color:rgb(243 244 246/var(--tw-bg-opacity))}.theme-default .nl-select:focus{--tw-border-opacity:1;--tw-ring-opacity:1;--tw-ring-color:rgb(168 85 247/var(--tw-ring-opacity));border-color:rgb(168 85 247/var(--tw-border-opacity))}.theme-default .dark .nl-select{--tw-bg-opacity:1;--tw-text-opacity:1;background-color:rgb(55 65 81/var(--tw-bg-opacity));color:rgb(156 163 175/var(--tw-text-opacity))}.theme-default .dark .nl-select:focus{--tw-ring-opacity:1;--tw-ring-color:rgb(75 85 99/var(--tw-ring-opacity))}.theme-default .nl-select-list{--tw-bg-opacity:1;background-color:rgb(243 244 246/var(--tw-bg-opacity))}.theme-default .dark .nl-select-list{--tw-bg-opacity:1;background-color:rgb(55 65 81/var(--tw-bg-opacity))}.theme-default .nl-select-option{--tw-text-opacity:1;color:rgb(31 41 55/var(--tw-text-opacity))}.theme-default .nl-select-option:hover{--tw-bg-opacity:1;background-color:rgb(229 231 235/var(--tw-bg-opacity))}.theme-default .nl-select-option.active-option{--tw-bg-opacity:1;--tw-text-opacity:1;background-color:rgb(209 213 219/var(--tw-bg-opacity));color:rgb(30 58 138/var(--tw-text-opacity))}.theme-default .dark .nl-select-option{--tw-text-opacity:1;color:rgb(156 163 175/var(--tw-text-opacity))}.theme-default .dark .nl-select-option:hover{--tw-bg-opacity:1;--tw-text-opacity:1;background-color:rgb(31 41 55/var(--tw-bg-opacity));color:rgb(209 213 219/var(--tw-text-opacity))}.theme-default .nl-text-error{--tw-text-opacity:1;color:rgb(248 113 113/var(--tw-text-opacity))}.theme-default .nl-text-success{--tw-text-opacity:1;color:rgb(45 212 191/var(--tw-text-opacity))}.theme-default .nl-banner{--tw-border-opacity:1;--tw-bg-opacity:1;--tw-text-opacity:1;--tw-shadow:0 1px 2px 0 rgba(0,0,0,.05);--tw-shadow-colored:0 1px 2px 0 var(--tw-shadow-color);background-color:rgb(255 255 255/var(--tw-bg-opacity));border-color:rgb(229 231 235/var(--tw-border-opacity));border-width:1px;box-shadow:var(--tw-ring-offset-shadow,0 0 #0000),var(--tw-ring-shadow,0 0 #0000),var(--tw-shadow);color:rgb(31 41 55/var(--tw-text-opacity))}.theme-default .dark .nl-banner{--tw-border-opacity:1;--tw-bg-opacity:1;--tw-text-opacity:1;background-color:rgb(15 23 42/var(--tw-bg-opacity));border-color:rgb(55 65 81/var(--tw-border-opacity));color:rgb(209 213 219/var(--tw-text-opacity))}.theme-ocean .nl-bg{--tw-bg-opacity:1;--tw-shadow:0 1px 2px 0 rgba(0,0,0,.05);--tw-shadow-colored:0 1px 2px 0 var(--tw-shadow-color);background-color:rgb(191 219 254/var(--tw-bg-opacity));box-shadow:var(--tw-ring-offset-shadow,0 0 #0000),var(--tw-ring-shadow,0 0 #0000),var(--tw-shadow)}.theme-ocean .dark .nl-bg{--tw-bg-opacity:1;--tw-shadow-color:rgba(51,65,85,.7);--tw-shadow:var(--tw-shadow-colored);background-color:rgb(8 47 73/var(--tw-bg-opacity))}.theme-ocean .nl-description,.theme-ocean .nl-logo,.theme-ocean .nl-title{--tw-text-opacity:1;color:rgb(8 47 73/var(--tw-text-opacity))}.theme-ocean .dark .nl-description,.theme-ocean .dark .nl-logo,.theme-ocean .dark .nl-title{--tw-text-opacity:1;color:rgb(186 230 253/var(--tw-text-opacity))}.theme-ocean .nl-action-button{--tw-text-opacity:1;color:rgb(8 47 73/var(--tw-text-opacity));outline:2px solid transparent;outline-offset:2px}.theme-ocean .nl-action-button:hover{--tw-bg-opacity:1;background-color:rgb(224 242 254/var(--tw-bg-opacity))}.theme-ocean .dark .nl-action-button{--tw-text-opacity:1;color:rgb(186 230 253/var(--tw-text-opacity));outline:2px solid transparent;outline-offset:2px}.theme-ocean .dark .nl-action-button:hover{--tw-bg-opacity:1;background-color:rgb(12 74 110/var(--tw-bg-opacity))}.theme-ocean .nl-button{--tw-border-opacity:1;--tw-bg-opacity:1;--tw-text-opacity:1;--tw-shadow:0 1px 2px 0 rgba(0,0,0,.05);--tw-shadow-colored:0 1px 2px 0 var(--tw-shadow-color);background-color:rgb(224 242 254/var(--tw-bg-opacity));border-color:rgb(186 230 253/var(--tw-border-opacity));border-width:1px;box-shadow:var(--tw-ring-offset-shadow,0 0 #0000),var(--tw-ring-shadow,0 0 #0000),var(--tw-shadow);color:rgb(8 47 73/var(--tw-text-opacity))}.theme-ocean .nl-button:hover{--tw-bg-opacity:1;background-color:rgb(240 249 255/var(--tw-bg-opacity))}.theme-ocean .dark .nl-button{--tw-border-opacity:1;--tw-bg-opacity:1;--tw-text-opacity:1;background-color:rgb(7 89 133/var(--tw-bg-opacity));border-color:rgb(8 47 73/var(--tw-border-opacity));color:rgb(186 230 253/var(--tw-text-opacity))}.theme-ocean .dark .nl-button:hover{--tw-bg-opacity:1;background-color:rgb(12 74 110/var(--tw-bg-opacity))}.theme-ocean .nl-divider{--tw-text-opacity:1;color:rgb(8 47 73/var(--tw-text-opacity))}.theme-ocean .nl-divider:after,.theme-ocean .nl-divider:before{--tw-border-opacity:1;border-color:rgb(8 47 73/var(--tw-border-opacity));content:var(--tw-content)}.theme-ocean .dark .nl-divider{--tw-text-opacity:1;color:rgb(186 230 253/var(--tw-text-opacity))}.theme-ocean .dark .nl-divider:after,.theme-ocean .dark .nl-divider:before{--tw-border-opacity:1;border-color:rgb(186 230 253/var(--tw-border-opacity));content:var(--tw-content)}.theme-ocean .nl-footer{--tw-text-opacity:1;color:rgb(8 47 73/var(--tw-text-opacity))}.theme-ocean .dark .nl-footer{--tw-text-opacity:1;color:rgb(186 230 253/var(--tw-text-opacity))}.theme-ocean .nl-error{--tw-text-opacity:1;color:rgb(153 27 27/var(--tw-text-opacity))}.theme-ocean .dark .nl-error{--tw-text-opacity:1;color:rgb(254 202 202/var(--tw-text-opacity))}.theme-ocean .nl-input{--tw-bg-opacity:1;background-color:rgb(224 242 254/var(--tw-bg-opacity))}.theme-ocean .nl-input:focus{--tw-border-opacity:1;--tw-ring-opacity:1;--tw-ring-color:rgb(14 165 233/var(--tw-ring-opacity));border-color:rgb(14 165 233/var(--tw-border-opacity))}.theme-ocean .dark .nl-input{--tw-bg-opacity:1;--tw-text-opacity:1;background-color:rgb(12 74 110/var(--tw-bg-opacity));color:rgb(56 189 248/var(--tw-text-opacity))}.theme-ocean .dark .nl-input:focus{--tw-ring-opacity:1;--tw-ring-color:rgb(2 132 199/var(--tw-ring-opacity))}.theme-ocean .nl-select{--tw-bg-opacity:1;background-color:rgb(224 242 254/var(--tw-bg-opacity))}.theme-ocean .nl-select:focus{--tw-border-opacity:1;--tw-ring-opacity:1;--tw-ring-color:rgb(14 165 233/var(--tw-ring-opacity));border-color:rgb(14 165 233/var(--tw-border-opacity))}.theme-ocean .dark .nl-select{--tw-bg-opacity:1;--tw-text-opacity:1;background-color:rgb(12 74 110/var(--tw-bg-opacity));color:rgb(56 189 248/var(--tw-text-opacity))}.theme-ocean .dark .nl-select:focus{--tw-ring-opacity:1;--tw-ring-color:rgb(2 132 199/var(--tw-ring-opacity))}.theme-ocean .nl-select-list{--tw-bg-opacity:1;background-color:rgb(224 242 254/var(--tw-bg-opacity))}.theme-ocean .dark .nl-select-list{--tw-bg-opacity:1;background-color:rgb(3 105 161/var(--tw-bg-opacity))}.theme-ocean .nl-select-option{--tw-text-opacity:1;color:rgb(7 89 133/var(--tw-text-opacity))}.theme-ocean .nl-select-option:hover{--tw-bg-opacity:1;background-color:rgb(186 230 253/var(--tw-bg-opacity))}.theme-ocean .dark .nl-select-option{--tw-text-opacity:1;color:rgb(56 189 248/var(--tw-text-opacity))}.theme-ocean .dark .nl-select-option:hover{--tw-bg-opacity:1;--tw-text-opacity:1;background-color:rgb(7 89 133/var(--tw-bg-opacity));color:rgb(125 211 252/var(--tw-text-opacity))}.theme-ocean .nl-text-error{--tw-text-opacity:1;color:rgb(220 38 38/var(--tw-text-opacity))}.theme-ocean .dark .nl-text-error{--tw-text-opacity:1;color:rgb(248 113 113/var(--tw-text-opacity))}.theme-ocean .nl-text-success{--tw-text-opacity:1;color:rgb(13 148 136/var(--tw-text-opacity))}.theme-ocean .dark .nl-text-success{--tw-text-opacity:1;color:rgb(45 212 191/var(--tw-text-opacity))}.theme-lemonade .nl-bg{--tw-bg-opacity:1;--tw-shadow:0 1px 2px 0 rgba(0,0,0,.05);--tw-shadow-colored:0 1px 2px 0 var(--tw-shadow-color);background-color:rgb(187 247 208/var(--tw-bg-opacity));box-shadow:var(--tw-ring-offset-shadow,0 0 #0000),var(--tw-ring-shadow,0 0 #0000),var(--tw-shadow)}.theme-lemonade .dark .nl-bg{--tw-bg-opacity:1;--tw-shadow-color:rgba(51,65,85,.7);--tw-shadow:var(--tw-shadow-colored);background-color:rgb(5 46 22/var(--tw-bg-opacity))}.theme-lemonade .nl-description,.theme-lemonade .nl-logo,.theme-lemonade .nl-title{--tw-text-opacity:1;color:rgb(5 46 22/var(--tw-text-opacity))}.theme-lemonade .dark .nl-description,.theme-lemonade .dark .nl-logo,.theme-lemonade .dark .nl-title{--tw-text-opacity:1;color:rgb(187 247 208/var(--tw-text-opacity))}.theme-lemonade .nl-action-button{--tw-text-opacity:1;color:rgb(5 46 22/var(--tw-text-opacity));outline:2px solid transparent;outline-offset:2px}.theme-lemonade .nl-action-button:hover{--tw-bg-opacity:1;background-color:rgb(220 252 231/var(--tw-bg-opacity))}.theme-lemonade .dark .nl-action-button{--tw-text-opacity:1;color:rgb(187 247 208/var(--tw-text-opacity));outline:2px solid transparent;outline-offset:2px}.theme-lemonade .dark .nl-action-button:hover{--tw-bg-opacity:1;background-color:rgb(20 83 45/var(--tw-bg-opacity))}.theme-lemonade .nl-button{--tw-border-opacity:1;--tw-bg-opacity:1;--tw-text-opacity:1;--tw-shadow:0 1px 2px 0 rgba(0,0,0,.05);--tw-shadow-colored:0 1px 2px 0 var(--tw-shadow-color);background-color:rgb(220 252 231/var(--tw-bg-opacity));border-color:rgb(187 247 208/var(--tw-border-opacity));border-width:1px;box-shadow:var(--tw-ring-offset-shadow,0 0 #0000),var(--tw-ring-shadow,0 0 #0000),var(--tw-shadow);color:rgb(5 46 22/var(--tw-text-opacity))}.theme-lemonade .nl-button:hover{--tw-bg-opacity:1;background-color:rgb(240 253 244/var(--tw-bg-opacity))}.theme-lemonade .dark .nl-button{--tw-border-opacity:1;--tw-bg-opacity:1;--tw-text-opacity:1;background-color:rgb(22 101 52/var(--tw-bg-opacity));border-color:rgb(5 46 22/var(--tw-border-opacity));color:rgb(187 247 208/var(--tw-text-opacity))}.theme-lemonade .dark .nl-button:hover{--tw-bg-opacity:1;background-color:rgb(20 83 45/var(--tw-bg-opacity))}.theme-lemonade .nl-divider{--tw-text-opacity:1;color:rgb(5 46 22/var(--tw-text-opacity))}.theme-lemonade .nl-divider:after,.theme-lemonade .nl-divider:before{--tw-border-opacity:1;border-color:rgb(5 46 22/var(--tw-border-opacity));content:var(--tw-content)}.theme-lemonade .dark .nl-divider{--tw-text-opacity:1;color:rgb(187 247 208/var(--tw-text-opacity))}.theme-lemonade .dark .nl-divider:after,.theme-lemonade .dark .nl-divider:before{--tw-border-opacity:1;border-color:rgb(187 247 208/var(--tw-border-opacity));content:var(--tw-content)}.theme-lemonade .nl-footer{--tw-text-opacity:1;color:rgb(5 46 22/var(--tw-text-opacity))}.theme-lemonade .dark .nl-footer{--tw-text-opacity:1;color:rgb(187 247 208/var(--tw-text-opacity))}.theme-lemonade .nl-error{--tw-text-opacity:1;color:rgb(153 27 27/var(--tw-text-opacity))}.theme-lemonade .dark .nl-error{--tw-text-opacity:1;color:rgb(254 202 202/var(--tw-text-opacity))}.theme-lemonade .nl-input{--tw-bg-opacity:1;background-color:rgb(220 252 231/var(--tw-bg-opacity))}.theme-lemonade .nl-input:focus{--tw-border-opacity:1;--tw-ring-opacity:1;--tw-ring-color:rgb(34 197 94/var(--tw-ring-opacity));border-color:rgb(34 197 94/var(--tw-border-opacity))}.theme-lemonade .dark .nl-input{--tw-bg-opacity:1;--tw-text-opacity:1;background-color:rgb(20 83 45/var(--tw-bg-opacity));color:rgb(74 222 128/var(--tw-text-opacity))}.theme-lemonade .dark .nl-input:focus{--tw-ring-opacity:1;--tw-ring-color:rgb(22 163 74/var(--tw-ring-opacity))}.theme-lemonade .nl-select{--tw-bg-opacity:1;background-color:rgb(220 252 231/var(--tw-bg-opacity))}.theme-lemonade .nl-select:focus{--tw-border-opacity:1;--tw-ring-opacity:1;--tw-ring-color:rgb(34 197 94/var(--tw-ring-opacity));border-color:rgb(34 197 94/var(--tw-border-opacity))}.theme-lemonade .dark .nl-select{--tw-bg-opacity:1;--tw-text-opacity:1;background-color:rgb(20 83 45/var(--tw-bg-opacity));color:rgb(74 222 128/var(--tw-text-opacity))}.theme-lemonade .dark .nl-select:focus{--tw-ring-opacity:1;--tw-ring-color:rgb(22 163 74/var(--tw-ring-opacity))}.theme-lemonade .nl-select-list{--tw-bg-opacity:1;background-color:rgb(220 252 231/var(--tw-bg-opacity))}.theme-lemonade .dark .nl-select-list{--tw-bg-opacity:1;background-color:rgb(21 128 61/var(--tw-bg-opacity))}.theme-lemonade .nl-select-option{--tw-text-opacity:1;color:rgb(22 101 52/var(--tw-text-opacity))}.theme-lemonade .nl-select-option:hover{--tw-bg-opacity:1;background-color:rgb(187 247 208/var(--tw-bg-opacity))}.theme-lemonade .dark .nl-select-option{--tw-text-opacity:1;color:rgb(74 222 128/var(--tw-text-opacity))}.theme-lemonade .dark .nl-select-option:hover{--tw-bg-opacity:1;--tw-text-opacity:1;background-color:rgb(22 101 52/var(--tw-bg-opacity));color:rgb(134 239 172/var(--tw-text-opacity))}.theme-lemonade .nl-text-error{--tw-text-opacity:1;color:rgb(220 38 38/var(--tw-text-opacity))}.theme-lemonade .dark .nl-text-error{--tw-text-opacity:1;color:rgb(248 113 113/var(--tw-text-opacity))}.theme-lemonade .nl-text-success{--tw-text-opacity:1;color:rgb(13 148 136/var(--tw-text-opacity))}.theme-lemonade .dark .nl-text-success{--tw-text-opacity:1;color:rgb(45 212 191/var(--tw-text-opacity))}.theme-purple .nl-bg{--tw-bg-opacity:1;--tw-shadow:0 1px 2px 0 rgba(0,0,0,.05);--tw-shadow-colored:0 1px 2px 0 var(--tw-shadow-color);background-color:rgb(233 213 255/var(--tw-bg-opacity));box-shadow:var(--tw-ring-offset-shadow,0 0 #0000),var(--tw-ring-shadow,0 0 #0000),var(--tw-shadow)}.theme-purple .dark .nl-bg{--tw-bg-opacity:1;--tw-shadow-color:rgba(51,65,85,.7);--tw-shadow:var(--tw-shadow-colored);background-color:rgb(59 7 100/var(--tw-bg-opacity))}.theme-purple .nl-description,.theme-purple .nl-logo,.theme-purple .nl-title{--tw-text-opacity:1;color:rgb(59 7 100/var(--tw-text-opacity))}.theme-purple .dark .nl-description,.theme-purple .dark .nl-logo,.theme-purple .dark .nl-title{--tw-text-opacity:1;color:rgb(233 213 255/var(--tw-text-opacity))}.theme-purple .nl-action-button{--tw-text-opacity:1;color:rgb(59 7 100/var(--tw-text-opacity));outline:2px solid transparent;outline-offset:2px}.theme-purple .nl-action-button:hover{--tw-bg-opacity:1;background-color:rgb(243 232 255/var(--tw-bg-opacity))}.theme-purple .dark .nl-action-button{--tw-text-opacity:1;color:rgb(233 213 255/var(--tw-text-opacity));outline:2px solid transparent;outline-offset:2px}.theme-purple .dark .nl-action-button:hover{--tw-bg-opacity:1;background-color:rgb(88 28 135/var(--tw-bg-opacity))}.theme-purple .nl-button{--tw-border-opacity:1;--tw-bg-opacity:1;--tw-text-opacity:1;--tw-shadow:0 1px 2px 0 rgba(0,0,0,.05);--tw-shadow-colored:0 1px 2px 0 var(--tw-shadow-color);background-color:rgb(243 232 255/var(--tw-bg-opacity));border-color:rgb(233 213 255/var(--tw-border-opacity));border-width:1px;box-shadow:var(--tw-ring-offset-shadow,0 0 #0000),var(--tw-ring-shadow,0 0 #0000),var(--tw-shadow);color:rgb(59 7 100/var(--tw-text-opacity))}.theme-purple .nl-button:hover{--tw-bg-opacity:1;background-color:rgb(250 245 255/var(--tw-bg-opacity))}.theme-purple .dark .nl-button{--tw-border-opacity:1;--tw-bg-opacity:1;--tw-text-opacity:1;background-color:rgb(107 33 168/var(--tw-bg-opacity));border-color:rgb(59 7 100/var(--tw-border-opacity));color:rgb(233 213 255/var(--tw-text-opacity))}.theme-purple .dark .nl-button:hover{--tw-bg-opacity:1;background-color:rgb(88 28 135/var(--tw-bg-opacity))}.theme-purple .nl-divider{--tw-text-opacity:1;color:rgb(59 7 100/var(--tw-text-opacity))}.theme-purple .nl-divider:after,.theme-purple .nl-divider:before{--tw-border-opacity:1;border-color:rgb(59 7 100/var(--tw-border-opacity));content:var(--tw-content)}.theme-purple .dark .nl-divider{--tw-text-opacity:1;color:rgb(233 213 255/var(--tw-text-opacity))}.theme-purple .dark .nl-divider:after,.theme-purple .dark .nl-divider:before{--tw-border-opacity:1;border-color:rgb(233 213 255/var(--tw-border-opacity));content:var(--tw-content)}.theme-purple .nl-footer{--tw-text-opacity:1;color:rgb(59 7 100/var(--tw-text-opacity))}.theme-purple .dark .nl-footer{--tw-text-opacity:1;color:rgb(233 213 255/var(--tw-text-opacity))}.theme-purple .nl-error{--tw-text-opacity:1;color:rgb(153 27 27/var(--tw-text-opacity))}.theme-purple .dark .nl-error{--tw-text-opacity:1;color:rgb(254 202 202/var(--tw-text-opacity))}.theme-purple .nl-input{--tw-bg-opacity:1;background-color:rgb(243 232 255/var(--tw-bg-opacity))}.theme-purple .nl-input:focus{--tw-border-opacity:1;--tw-ring-opacity:1;--tw-ring-color:rgb(168 85 247/var(--tw-ring-opacity));border-color:rgb(168 85 247/var(--tw-border-opacity))}.theme-purple .dark .nl-input{--tw-bg-opacity:1;--tw-text-opacity:1;background-color:rgb(88 28 135/var(--tw-bg-opacity));color:rgb(192 132 252/var(--tw-text-opacity))}.theme-purple .dark .nl-input:focus{--tw-ring-opacity:1;--tw-ring-color:rgb(147 51 234/var(--tw-ring-opacity))}.theme-purple .nl-select{--tw-bg-opacity:1;background-color:rgb(243 232 255/var(--tw-bg-opacity))}.theme-purple .nl-select:focus{--tw-border-opacity:1;--tw-ring-opacity:1;--tw-ring-color:rgb(168 85 247/var(--tw-ring-opacity));border-color:rgb(168 85 247/var(--tw-border-opacity))}.theme-purple .dark .nl-select{--tw-bg-opacity:1;--tw-text-opacity:1;background-color:rgb(88 28 135/var(--tw-bg-opacity));color:rgb(192 132 252/var(--tw-text-opacity))}.theme-purple .dark .nl-select:focus{--tw-ring-opacity:1;--tw-ring-color:rgb(147 51 234/var(--tw-ring-opacity))}.theme-purple .nl-select-list{--tw-bg-opacity:1;background-color:rgb(243 232 255/var(--tw-bg-opacity))}.theme-purple .dark .nl-select-list{--tw-bg-opacity:1;background-color:rgb(126 34 206/var(--tw-bg-opacity))}.theme-purple .nl-select-option{--tw-text-opacity:1;color:rgb(107 33 168/var(--tw-text-opacity))}.theme-purple .nl-select-option:hover{--tw-bg-opacity:1;background-color:rgb(233 213 255/var(--tw-bg-opacity))}.theme-purple .dark .nl-select-option{--tw-text-opacity:1;color:rgb(192 132 252/var(--tw-text-opacity))}.theme-purple .dark .nl-select-option:hover{--tw-bg-opacity:1;--tw-text-opacity:1;background-color:rgb(107 33 168/var(--tw-bg-opacity));color:rgb(216 180 254/var(--tw-text-opacity))}.theme-purple .nl-text-error{--tw-text-opacity:1;color:rgb(220 38 38/var(--tw-text-opacity))}.theme-purple .dark .nl-text-error{--tw-text-opacity:1;color:rgb(248 113 113/var(--tw-text-opacity))}.theme-purple .nl-text-success{--tw-text-opacity:1;color:rgb(13 148 136/var(--tw-text-opacity))}.theme-purple .dark .nl-text-success{--tw-text-opacity:1;color:rgb(45 212 191/var(--tw-text-opacity))}.theme-crab .nl-button{--tw-border-opacity:1;--tw-bg-opacity:1;--tw-text-opacity:1;--tw-shadow:0 1px 2px 0 rgba(0,0,0,.05);--tw-shadow-colored:0 1px 2px 0 var(--tw-shadow-color);background-color:rgb(254 226 226/var(--tw-bg-opacity));border-color:rgb(254 202 202/var(--tw-border-opacity));border-width:1px;box-shadow:var(--tw-ring-offset-shadow,0 0 #0000),var(--tw-ring-shadow,0 0 #0000),var(--tw-shadow);color:rgb(69 10 10/var(--tw-text-opacity))}.theme-crab .nl-button:hover{--tw-bg-opacity:1;background-color:rgb(254 242 242/var(--tw-bg-opacity))}.theme-crab .dark .nl-button{--tw-border-opacity:1;--tw-bg-opacity:1;--tw-text-opacity:1;background-color:rgb(153 27 27/var(--tw-bg-opacity));border-color:rgb(69 10 10/var(--tw-border-opacity));color:rgb(254 202 202/var(--tw-text-opacity))}.theme-crab .dark .nl-button:hover{--tw-bg-opacity:1;background-color:rgb(127 29 29/var(--tw-bg-opacity))}.show-slow{display:none;opacity:0;transition:.1s}.isOpen .show-slow{display:block;opacity:1;transition:.2s;transition-delay:.2s}:host{display:block}.animate-spin-loading{animation:spin2 1s linear infinite;background:var(--qa-dark-color)}@keyframes spin2{to{transform:rotate(1turn)}}.active{animation:blink .7s infinite alternate}@keyframes blink{0%{opacity:1}to{opacity:0}}.sr-only{clip:rect(0,0,0,0);border-width:0;height:1px;margin:-1px;overflow:hidden;padding:0;position:absolute;white-space:nowrap;width:1px}.static{position:static}.fixed{position:fixed}.absolute{position:absolute}.relative{position:relative}.left-0{left:0}.start-0{inset-inline-start:0}.top-0{top:0}.z-\\[80\\]{z-index:80}.z-\\[81\\]{z-index:81}.mx-auto{margin-left:auto;margin-right:auto}.flex{display:flex}.h-5{height:20px}.h-7{height:28px}.h-full{height:100%}.w-5{width:20px}.w-7{width:28px}.w-full{width:100%}.max-w-96{max-width:384px}.flex-shrink-0{flex-shrink:0}.cursor-pointer{cursor:pointer}.flex-col{flex-direction:column}.items-center{align-items:center}.justify-center{justify-content:center}.justify-between{justify-content:space-between}.gap-1{gap:4px}.gap-2{gap:8px}.overflow-y-auto{overflow-y:auto}.overflow-x-hidden{overflow-x:hidden}.rounded-full{border-radius:9999px}.rounded-xl{border-radius:.75rem}.border{border-width:1px}.border-transparent{border-color:transparent}.bg-gray-500{--tw-bg-opacity:1;background-color:rgb(107 114 128/var(--tw-bg-opacity))}.bg-opacity-75{--tw-bg-opacity:0.75}.p-4{padding:16px}.px-4{padding-left:16px;padding-right:16px}.py-3{padding-bottom:12px}.pt-3,.py-3{padding-top:12px}.text-center{text-align:center}.text-base{font-size:16px;line-height:24px}.text-sm{font-size:14px;line-height:20px}.font-bold{font-weight:700}.font-light{font-weight:300}.font-semibold{font-weight:600}.text-blue-400{--tw-text-opacity:1;color:rgb(96 165 250/var(--tw-text-opacity))}.shadow{--tw-shadow:0 1px 3px 0 rgba(0,0,0,.1),0 1px 2px -1px rgba(0,0,0,.1);--tw-shadow-colored:0 1px 3px 0 var(--tw-shadow-color),0 1px 2px -1px var(--tw-shadow-color);box-shadow:var(--tw-ring-offset-shadow,0 0 #0000),var(--tw-ring-shadow,0 0 #0000),var(--tw-shadow)}.dark\\:focus\\:outline-none:focus:is(.dark *){outline:2px solid transparent;outline-offset:2px}.dark\\:focus\\:ring-1:focus:is(.dark *){--tw-ring-offset-shadow:var(--tw-ring-inset) 0 0 0 var(--tw-ring-offset-width) var(--tw-ring-offset-color);--tw-ring-shadow:var(--tw-ring-inset) 0 0 0 calc(1px + var(--tw-ring-offset-width)) var(--tw-ring-color);box-shadow:var(--tw-ring-offset-shadow),var(--tw-ring-shadow),var(--tw-shadow,0 0 #0000)}.dark\\:focus\\:ring-gray-600:focus:is(.dark *){--tw-ring-opacity:1;--tw-ring-color:rgb(75 85 99/var(--tw-ring-opacity))}@media (min-width:640px){.sm\\:mx-auto{margin-left:auto;margin-right:auto}.sm\\:w-full{width:100%}.sm\\:max-w-lg{max-width:512px}}.inline-flex{display:inline-flex}.h-4{height:16px}.w-4{width:16px}.gap-x-2{column-gap:8px}.rounded-lg{border-radius:.5rem}.px-3{padding-left:12px;padding-right:12px}.py-2\\.5{padding-bottom:10px;padding-top:10px}.font-medium{font-weight:500}.disabled\\:pointer-events-none:disabled{pointer-events:none}.disabled\\:opacity-50:disabled{opacity:.5}.mt-0{margin-top:0}.mt-3{margin-top:12px}.max-h-0{max-height:0}.max-h-\\[500px\\]{max-height:500px}.max-w-52{max-width:208px}.max-w-7{max-width:28px}.rotate-0{--tw-rotate:0deg}.rotate-0,.rotate-180{transform:translate(var(--tw-translate-x),var(--tw-translate-y)) rotate(var(--tw-rotate)) skewX(var(--tw-skew-x)) skewY(var(--tw-skew-y)) scaleX(var(--tw-scale-x)) scaleY(var(--tw-scale-y))}.rotate-180{--tw-rotate:180deg}.gap-0\\.5{gap:2px}.gap-3{gap:12px}.gap-x-3\\.5{column-gap:14px}.overflow-hidden,.truncate{overflow:hidden}.truncate{text-overflow:ellipsis;white-space:nowrap}.border-b-\\[1px\\]{border-bottom-width:1px}.border-dashed{border-style:dashed}.border-blue-500{--tw-border-opacity:1;border-color:rgb(59 130 246/var(--tw-border-opacity))}.border-gray-200{--tw-border-opacity:1;border-color:rgb(229 231 235/var(--tw-border-opacity))}.border-gray-400{--tw-border-opacity:1;border-color:rgb(156 163 175/var(--tw-border-opacity))}.p-2{padding:8px}.py-2{padding-bottom:8px;padding-top:8px}.pb-1{padding-bottom:4px}.pb-1\\.5{padding-bottom:6px}.pb-5{padding-bottom:20px}.pe-4{padding-inline-end:16px}.ps-4{padding-inline-start:16px}.pt-5{padding-top:20px}.text-3xl{font-size:30px;line-height:36px}.uppercase{text-transform:uppercase}.text-blue-500{--tw-text-opacity:1;color:rgb(59 130 246/var(--tw-text-opacity))}.decoration-dashed{text-decoration-style:dashed}.duration-300{transition-duration:.3s}.duration-\\[0\\.25s\\]{transition-duration:.25s}.ease-in{transition-timing-function:cubic-bezier(.4,0,1,1)}.hover\\:bg-gray-300:hover{--tw-bg-opacity:1;background-color:rgb(209 213 219/var(--tw-bg-opacity))}.ml-auto,.mx-auto{margin-left:auto}.mr-auto{margin-right:auto}.w-60{width:240px}.pt-2{padding-top:8px}.text-4xl{font-size:36px;line-height:40px}.text-lg{font-size:18px;line-height:28px}.mb-0\\.5{margin-bottom:2px}.mb-2{margin-bottom:8px}.mb-5{margin-bottom:20px}.ml-auto{margin-left:auto}.inline-block{display:inline-block}.w-72{width:288px}.max-w-72{max-width:288px}.border-\\[3px\\]{border-width:3px}.border-current{border-color:currentColor}.border-t-transparent{border-top-color:transparent}.pb-2{padding-bottom:8px}.text-2xl{font-size:24px;line-height:32px}.text-slate-900{--tw-text-opacity:1;color:rgb(15 23 42/var(--tw-text-opacity))}.filter{filter:var(--tw-blur) var(--tw-brightness) var(--tw-contrast) var(--tw-grayscale) var(--tw-hue-rotate) var(--tw-invert) var(--tw-saturate) var(--tw-sepia) var(--tw-drop-shadow)}.dark\\:text-gray-300:is(.dark *){--tw-text-opacity:1;color:rgb(209 213 219/var(--tw-text-opacity))}.h-12{height:48px}.w-12{width:48px}.text-green-800{--tw-text-opacity:1;color:rgb(22 101 52/var(--tw-text-opacity))}.dark\\:text-green-200:is(.dark *){--tw-text-opacity:1;color:rgb(187 247 208/var(--tw-text-opacity))}.mb-10{margin-bottom:40px}.mt-10{margin-top:40px}.h-20{height:80px}.w-20{width:80px}.border-\\[4px\\]{border-width:4px}.w-auto{width:auto}.border-gray-300{--tw-border-opacity:1;border-color:rgb(209 213 219/var(--tw-border-opacity))}.border-orange-300{--tw-border-opacity:1;border-color:rgb(253 186 116/var(--tw-border-opacity))}.border-red-300{--tw-border-opacity:1;border-color:rgb(252 165 165/var(--tw-border-opacity))}.border-teal-300{--tw-border-opacity:1;border-color:rgb(94 234 212/var(--tw-border-opacity))}.border-yellow-300{--tw-border-opacity:1;border-color:rgb(253 224 71/var(--tw-border-opacity))}.bg-gray-100{--tw-bg-opacity:1;background-color:rgb(243 244 246/var(--tw-bg-opacity))}.bg-orange-100{--tw-bg-opacity:1;background-color:rgb(255 237 213/var(--tw-bg-opacity))}.bg-red-100{--tw-bg-opacity:1;background-color:rgb(254 226 226/var(--tw-bg-opacity))}.bg-teal-100{--tw-bg-opacity:1;background-color:rgb(204 251 241/var(--tw-bg-opacity))}.bg-yellow-100{--tw-bg-opacity:1;background-color:rgb(254 249 195/var(--tw-bg-opacity))}.px-1{padding-left:4px;padding-right:4px}.text-\\[10px\\]{font-size:10px}.text-gray-400{--tw-text-opacity:1;color:rgb(156 163 175/var(--tw-text-opacity))}.text-orange-600{--tw-text-opacity:1;color:rgb(234 88 12/var(--tw-text-opacity))}.text-red-600{--tw-text-opacity:1;color:rgb(220 38 38/var(--tw-text-opacity))}.text-teal-600{--tw-text-opacity:1;color:rgb(13 148 136/var(--tw-text-opacity))}.text-yellow-500{--tw-text-opacity:1;color:rgb(234 179 8/var(--tw-text-opacity))}.pointer-events-none{pointer-events:none}.inset-y-0{bottom:0;top:0}.ps-11{padding-inline-start:44px}.text-gray-500{--tw-text-opacity:1;color:rgb(107 114 128/var(--tw-text-opacity))}.peer:disabled~.peer-disabled\\:pointer-events-none{pointer-events:none}.peer:disabled~.peer-disabled\\:opacity-50{opacity:.5}.dark\\:border-transparent:is(.dark *){border-color:transparent}.right-\\[-2px\\]{right:-2px}.right-\\[-3px\\]{right:-3px}.top-\\[-2px\\]{top:-2px}.top-\\[-3px\\]{top:-3px}.h-1\\.5{height:6px}.h-3{height:12px}.h-6{height:24px}.w-1\\.5{width:6px}.w-3{width:12px}.max-w-6{max-width:24px}.border-2{border-width:2px}.border-blue-200{--tw-border-opacity:1;border-color:rgb(191 219 254/var(--tw-border-opacity))}.border-white{--tw-border-opacity:1;border-color:rgb(255 255 255/var(--tw-border-opacity))}.bg-green-500{--tw-bg-opacity:1;background-color:rgb(34 197 94/var(--tw-bg-opacity))}.bg-white{--tw-bg-opacity:1;background-color:rgb(255 255 255/var(--tw-bg-opacity))}.pb-3{padding-bottom:12px}.pt-0{padding-top:0}.text-red-500{--tw-text-opacity:1;color:rgb(239 68 68/var(--tw-text-opacity))}.hover\\:bg-gray-400:hover{--tw-bg-opacity:1;background-color:rgb(156 163 175/var(--tw-bg-opacity))}.hover\\:text-red-600:hover{--tw-text-opacity:1;color:rgb(220 38 38/var(--tw-text-opacity))}.group:hover .group-hover\\:border-blue-400{--tw-border-opacity:1;border-color:rgb(96 165 250/var(--tw-border-opacity))}.mt-1{margin-top:4px}.hidden{display:none}.min-w-\\[15rem\\]{min-width:15rem}.overflow-hidden,.truncate{overflow:hidden}.shadow-md{--tw-shadow:0 4px 6px -1px rgba(0,0,0,.1),0 2px 4px -2px rgba(0,0,0,.1);--tw-shadow-colored:0 4px 6px -1px var(--tw-shadow-color),0 2px 4px -2px var(--tw-shadow-color);box-shadow:var(--tw-ring-offset-shadow,0 0 #0000),var(--tw-ring-shadow,0 0 #0000),var(--tw-shadow)}.before\\:absolute:before{content:var(--tw-content);position:absolute}.before\\:-top-4:before{content:var(--tw-content);top:-16px}.before\\:start-0:before{content:var(--tw-content);inset-inline-start:0}.before\\:h-4:before{content:var(--tw-content);height:16px}.before\\:w-full:before{content:var(--tw-content);width:100%}.after\\:absolute:after{content:var(--tw-content);position:absolute}.after\\:-bottom-4:after{bottom:-16px;content:var(--tw-content)}.after\\:start-0:after{content:var(--tw-content);inset-inline-start:0}.after\\:h-4:after{content:var(--tw-content);height:16px}.after\\:w-full:after{content:var(--tw-content);width:100%}.end-0{inset-inline-end:0}.h-\\[20px\\]{height:20px}.w-\\[20px\\]{width:20px}.border-\\[2px\\]{border-width:2px}.pe-11{padding-inline-end:44px}.right-0{right:0}.right-2{right:8px}.top-2{top:8px}.top-52{top:208px}.z-0{z-index:0}.z-10{z-index:10}.z-20{z-index:20}.z-50{z-index:50}.m-auto{margin:auto}.ml-0{margin-left:0}.ml-\\[2px\\]{margin-left:2px}.mr-0{margin-right:0}.mr-2{margin-right:8px}.mr-3\\.5{margin-right:14px}.mt-2{margin-top:8px}.grid{display:grid}.h-0{height:0}.h-8{height:32px}.h-\\[46px\\]{height:46px}.h-auto{height:auto}.w-0{width:0}.w-16{width:64px}.w-52{width:208px}.w-6{width:24px}.w-8{width:32px}.w-\\[48px\\]{width:48px}.min-w-40{min-width:160px}.max-w-40{max-width:160px}@keyframes spin{to{transform:rotate(1turn)}}.animate-spin{animation:spin 1s linear infinite}.place-items-center{place-items:center}.text-nowrap{text-wrap:nowrap}.rounded-r-lg{border-bottom-right-radius:.5rem;border-top-right-radius:.5rem}.rounded-r-none{border-bottom-right-radius:0;border-top-right-radius:0}.border-\\[0px\\]{border-width:0}.p-3{padding:12px}.px-2{padding-left:8px;padding-right:8px}.pl-\\[11px\\]{padding-left:11px}.text-xs{font-size:12px;line-height:16px}.text-red-400{--tw-text-opacity:1;color:rgb(248 113 113/var(--tw-text-opacity))}.opacity-0{opacity:0}.transition-all{transition-duration:.15s;transition-property:all}.ease-in-out,.transition-all{transition-timing-function:cubic-bezier(.4,0,.2,1)}.hover\\:right-2:hover{right:8px}.hover\\:rounded-r-lg:hover{border-bottom-right-radius:.5rem;border-top-right-radius:.5rem}",buttonBaseCss=baseCss,ButtonBaseStyle0=buttonBaseCss,ButtonBase=proxyCustomElement(class extends H{constructor(){super(),this.__registerHost(),this.theme="default",this.darkMode=!1,this.titleBtn="Open modal",this.disabled=!1}componentDidRender(){const o=this.element.querySelector("svg");o&&(o.classList.add("flex-shrink-0","w-4","h-4","block"),o.removeAttribute("style"))}render(){return h("div",{key:"1048576f0a9839c56cac030b1de7899b25b5f39e",class:`theme-${this.theme}`},h("div",{key:"ea29f74a1f7e4268802c6e4aaca5867dfd2e4c9b",class:"animate-spin-loading active"}),h("button",{key:"71f84d47b11aa3971818b686f8dddb74e0d36eb0",disabled:this.disabled,type:"button",class:"nl-button py-2.5 px-3 w-full inline-flex justify-center items-center gap-x-2 text-sm font-medium rounded-lg disabled:opacity-50 disabled:pointer-events-none dark:focus:outline-none dark:focus:ring-1 dark:focus:ring-gray-600"},h("slot",{key:"91a91994e20dc10e3bbb2576e4214fa98533be8e",name:"icon-start"}),this.titleBtn))}get element(){return this}static get style(){return ButtonBaseStyle0}},[4,"button-base",{theme:[1025],darkMode:[1028,"dark-mode"],titleBtn:[1,"title-btn"],disabled:[4]}]);function defineCustomElement$q(){typeof customElements>"u"||["button-base"].forEach(o=>{"button-base"===o&&(customElements.get(o)||customElements.define(o,ButtonBase))})}defineCustomElement$q();const nlConfirmLogoutCss=baseCss,NlConfirmLogoutStyle0=nlConfirmLogoutCss,NlConfirmLogout$1=proxyCustomElement(class extends H{constructor(){super(),this.__registerHost(),this.handleLogoutBanner=createEvent(this,"handleLogoutBanner",7),this.handleBackUpModal=createEvent(this,"handleBackUpModal",7),this.nlCloseModal=createEvent(this,"nlCloseModal",7),this.titleModal="Delete keys?",this.description="Your profile keys are stored in this browser tab and will be deleted if you log out, and your profile will be inaccessible."}handleLogout(){this.handleLogoutBanner.emit(METHOD_MODULE.LOGOUT),this.nlCloseModal.emit()}handleCancel(){this.nlCloseModal.emit()}handleBackUp(){state.path=[CURRENT_MODULE.IMPORT_FLOW]}render(){return h("div",{key:"fe605f38f9d0a440fe53e21f19288c41e4762c22",class:"p-4 overflow-y-auto"},h("h1",{key:"84d14a59035515b2fd612d262400a038887a10d7",class:"nl-title font-bold text-center text-4xl"},this.titleModal),h("p",{key:"83ef73271c76309561be95e0207f8130d75a161c",class:"nl-description font-light text-center text-lg pt-2 max-w-96 mx-auto"},this.description),h("div",{key:"fce0f132846beb95dd9e41357f5ab87be7229a56",class:"mt-3 ml-auto mr-auto w-60 flex flex-col gap-2"},h("button-base",{key:"c4fc722a7c98d84e797963ed7fe928164411b701",onClick:()=>this.handleBackUp(),titleBtn:"Backup keys",theme:"lemonade"}),h("button-base",{key:"39df385a9a8dc3fcd74f4196d4191bc4a308a16d",onClick:()=>this.handleLogout(),theme:"crab",titleBtn:"Logout and delete keys"})))}static get style(){return NlConfirmLogoutStyle0}},[0,"nl-confirm-logout",{titleModal:[1,"title-modal"],description:[1]}]);function defineCustomElement$p(){typeof customElements>"u"||["nl-confirm-logout","button-base"].forEach(o=>{switch(o){case"nl-confirm-logout":customElements.get(o)||customElements.define(o,NlConfirmLogout$1);break;case"button-base":customElements.get(o)||defineCustomElement$q()}})}defineCustomElement$p();const nlConnectCss=baseCss,NlConnectStyle0=nlConnectCss,NlConnect=proxyCustomElement(class extends H{constructor(){super(),this.__registerHost(),this.nlNostrConnect=createEvent(this,"nlNostrConnect",7),this.nlNostrConnectDefault=createEvent(this,"nlNostrConnectDefault",7),this.titleWelcome="Connect to key store",this.authMethods=[],this.hasOTP=!1,this.connectionStringServices=[],this.isOpenAdvancedLogin=!1}handleChangeScreen(o){state.path=[...state.path,o]}handleOpenAdvanced(){this.isOpenAdvancedLogin=!this.isOpenAdvancedLogin}allowAuthMethod(o){return!this.authMethods.length||this.authMethods.includes(o)}componentWillLoad(){}handleOpenLink(o,s){o.preventDefault(),this.nlNostrConnect.emit(s)}handleConnectionString(){this.nlNostrConnectDefault.emit(),this.handleChangeScreen(CURRENT_MODULE.CONNECTION_STRING)}render(){const o=(this.isOpenAdvancedLogin?"rotate-180":"rotate-0")+" duration-300 flex-shrink-0 w-4 h-4 text-blue-500";return h(Fragment,{key:"a85f0a26b61b7e321025b7dd96e459a6c43958a9"},h("div",{key:"7af7ae501bed1bf028465e65f3caa3824a3948ca",class:"p-4 overflow-y-auto"},h("h1",{key:"7795a15c6d525d1b7ad0e6da63ad1889a64d6459",class:"nl-title font-bold text-center text-3xl"},this.titleWelcome)),h("div",{key:"cf5b947b22757334cbf92059dfc7ffaef0c95951",class:"p-4"},!!this.connectionStringServices.length&&h("div",{key:"c5de66ab74b14d69993dc20cf123777a3b8a016e",class:"max-w-96 mx-auto pt-5"},h("p",{key:"f7ac9e48789870264707bf39e3f1b2d73218aad5",class:"nl-description font-medium text-sm pb-1.5"},"Select key store:"),h("ul",{key:"07c1bd1bf9ffaa80f0868481ce22a8d5c73a345b",class:"p-2 rounded-lg border border-gray-200 flex flex-col w-full gap-0.5"},this.connectionStringServices.map(s=>h("li",null,h("a",{href:s.link,target:"_blank",onClick:r=>this.handleOpenLink(r,s),class:"flex items-center gap-x-3.5 w-full hover:bg-gray-300 flex cursor-pointer items-center gap-x-3.5 py-2 px-3 rounded-lg text-sm justify-between"},h("div",{class:"w-full max-w-7 h-7 flex relative"},h("div",{class:"uppercase font-bold w-full h-full rounded-full border border-gray-400 flex justify-center items-center"},s.img?h("img",{class:"w-full rounded-full",src:s.img,alt:s.name}):h("svg",{xmlns:"http://www.w3.org/2000/svg",fill:"none",viewBox:"0 0 24 24","stroke-width":"1.5",stroke:"#9ca3af",class:"w-4 h-4 block"},h("path",{"stroke-linecap":"round","stroke-linejoin":"round",d:"M15.75 5.25a3 3 0 0 1 3 3m3 0a6 6 0 0 1-7.029 5.912c-.563-.097-1.159.026-1.563.43L10.5 17.25H8.25v2.25H6v2.25H2.25v-2.818c0-.597.237-1.17.659-1.591l6.499-6.499c.404-.404.527-1 .43-1.563A6 6 0 1 1 21.75 8.25Z"})))),h("div",{class:"overflow-hidden flex flex-col w-full"},h("div",{class:"nl-title truncate overflow-hidden"},s.name)))))))),h("div",{key:"2a9094524ef58b138d04411484264a40ce42db7c",class:"ps-4 pe-4 overflow-y-auto"},h("p",{key:"d833546cba5fd4a904a0123e6e760b602fda0ff7",class:"nl-error font-light text-center text-sm max-w-96 mx-auto"},state.error)),h("div",{key:"700aa690c440f2685c9330feeb58986669b46f85",class:"max-w-52 mx-auto pb-5"},(this.allowAuthMethod("connect")||this.allowAuthMethod("readOnly"))&&h("div",{key:"058706b54702ac9ca3cd74a8096f521c211e5a16",class:"flex justify-center"},h("div",{key:"073f2567734817ba3cc8f34b32fa1a284d2b8ab1",onClick:()=>this.handleOpenAdvanced(),class:"text-blue-500 mt-3 decoration-dashed cursor-pointer inline-flex gap-2 items-center pb-1 border-dashed border-b-[1px] border-blue-500 text-sm font-light"},"Advanced",h("svg",{key:"d433319920bc751f771086bf726a3d5f1e31320e",class:o,xmlns:"http://www.w3.org/2000/svg",width:"24",height:"24",viewBox:"0 0 24 24",fill:"none",stroke:"currentColor","stroke-width":"2","stroke-linecap":"round","stroke-linejoin":"round"},h("path",{key:"4cc3a36807664b0402a26420c4979a68ba77df9c",d:"m6 9 6 6 6-6"})))),h("div",{key:"76dc95f39af78bd124e5f61309d96ee443d53f2f",class:(this.isOpenAdvancedLogin?"max-h-[500px] mt-3 duration-300":"max-h-0 mt-0 duration-[0.25s]")+" transition-max-height ease-in flex gap-3 flex-col overflow-hidden"},this.allowAuthMethod("connect")&&h("button-base",{key:"616d8de815233bc6264b51fa849fbf26d98758ed",titleBtn:"User name",onClick:()=>this.handleChangeScreen(CURRENT_MODULE.LOGIN)},h("svg",{key:"fa2f51ca2a111920d15a87106258c55a7b1961ff",style:{display:"none"},slot:"icon-start",xmlns:"http://www.w3.org/2000/svg",fill:"none",viewBox:"0 0 24 24","stroke-width":"2",stroke:"currentColor"},h("path",{key:"288dee2f9c21bde4471a7eebbf94c231c1acad12","stroke-linecap":"round","stroke-linejoin":"round",d:"M15.75 6a3.75 3.75 0 1 1-7.5 0 3.75 3.75 0 0 1 7.5 0ZM4.501 20.118a7.5 7.5 0 0 1 14.998 0A17.933 17.933 0 0 1 12 21.75c-2.676 0-5.216-.584-7.499-1.632Z"}))),this.allowAuthMethod("connect")&&h("button-base",{key:"8298c3ad602e2bc279ab084a5e5ea311fdc193e9",titleBtn:"Connection string",onClick:()=>this.handleConnectionString()},h("svg",{key:"b7f83a4b7fae0ff0965c2493aa70b09e1b1ab3d8",style:{display:"none"},slot:"icon-start",xmlns:"http://www.w3.org/2000/svg",fill:"none",viewBox:"0 0 24 24","stroke-width":"1.5",stroke:"currentColor"},h("path",{key:"d580fdbb1eee16439ffa4a46fa4f30cafbf0fd36","stroke-linecap":"round","stroke-linejoin":"round",d:"M3.75 4.875c0-.621.504-1.125 1.125-1.125h4.5c.621 0 1.125.504 1.125 1.125v4.5c0 .621-.504 1.125-1.125 1.125h-4.5A1.125 1.125 0 0 1 3.75 9.375v-4.5ZM3.75 14.625c0-.621.504-1.125 1.125-1.125h4.5c.621 0 1.125.504 1.125 1.125v4.5c0 .621-.504 1.125-1.125 1.125h-4.5a1.125 1.125 0 0 1-1.125-1.125v-4.5ZM13.5 4.875c0-.621.504-1.125 1.125-1.125h4.5c.621 0 1.125.504 1.125 1.125v4.5c0 .621-.504 1.125-1.125 1.125h-4.5A1.125 1.125 0 0 1 13.5 9.375v-4.5Z"}),h("path",{key:"ab90c206914cb2d6cae80b7e36ce45653c65b9b3","stroke-linecap":"round","stroke-linejoin":"round",d:"M6.75 6.75h.75v.75h-.75v-.75ZM6.75 16.5h.75v.75h-.75v-.75ZM16.5 6.75h.75v.75h-.75v-.75ZM13.5 13.5h.75v.75h-.75v-.75ZM13.5 19.5h.75v.75h-.75v-.75ZM19.5 13.5h.75v.75h-.75v-.75ZM19.5 19.5h.75v.75h-.75v-.75ZM16.5 16.5h.75v.75h-.75v-.75Z"}))),this.allowAuthMethod("connect")&&h("button-base",{key:"c923265e7da4bb6815cf91c54a4b393c19f3d16d",onClick:()=>this.handleChangeScreen(CURRENT_MODULE.LOGIN_BUNKER_URL),titleBtn:"Bunker URL"},h("svg",{key:"8c5bd04e91407a83d0021e4413ee58973b57aa54",style:{display:"none"},slot:"icon-start",xmlns:"http://www.w3.org/2000/svg",fill:"none",viewBox:"0 0 24 24","stroke-width":"1.5",stroke:"currentColor"},h("path",{key:"d115abfce6eee55572316a4cc2a808a176d17f46","stroke-linecap":"round","stroke-linejoin":"round",d:"M13.19 8.688a4.5 4.5 0 0 1 1.242 7.244l-4.5 4.5a4.5 4.5 0 0 1-6.364-6.364l1.757-1.757m13.35-.622 1.757-1.757a4.5 4.5 0 0 0-6.364-6.364l-4.5 4.5a4.5 4.5 0 0 0 1.242 7.244"}))))))}static get style(){return NlConnectStyle0}},[0,"nl-connect",{titleWelcome:[1,"title-welcome"],authMethods:[16],hasOTP:[4,"has-o-t-p"],connectionStringServices:[16],isOpenAdvancedLogin:[32]}]);function defineCustomElement$o(){typeof customElements>"u"||["nl-connect","button-base"].forEach(o=>{switch(o){case"nl-connect":customElements.get(o)||customElements.define(o,NlConnect);break;case"button-base":customElements.get(o)||defineCustomElement$q()}})}defineCustomElement$o();const nlIframeCss=baseCss,NlIframeStyle0=nlIframeCss,NlConfirmLogout=proxyCustomElement(class extends H{constructor(){super(),this.__registerHost(),this.nlCloseModal=createEvent(this,"nlCloseModal",7),this.titleModal="Confirm",this.description="Your profile keys are stored in this browser tab and will be deleted if you log out, and your profile will be inaccessible.",this.iframeUrl=""}handleCancel(){this.nlCloseModal.emit()}render(){return h("div",{key:"36ee9fd43bbb16768b7634783781ecffb1c9432a",class:"p-4 overflow-y-auto"},h("div",{key:"1634e1fd37bc44030f22bfdab9f7deec2806731b",class:"mt-3 flex flex-col gap-2"},this.iframeUrl&&h("iframe",{key:"2b1ab3032b152fb109f3531bb7600bb76aa1a562",src:this.iframeUrl,style:{width:"100%",height:"600px",border:"1px solid #ccc",borderRadius:"8px"}})))}static get style(){return NlIframeStyle0}},[0,"nl-iframe",{titleModal:[1,"title-modal"],description:[1],iframeUrl:[1,"iframe-url"]}]);function defineCustomElement$n(){typeof customElements>"u"||["nl-iframe"].forEach(o=>{"nl-iframe"===o&&(customElements.get(o)||customElements.define(o,NlConfirmLogout))})}defineCustomElement$n();const nlSelectCss=baseCss,NlSelectStyle0=nlSelectCss,NlSelect=proxyCustomElement(class extends H{constructor(){super(),this.__registerHost(),this.selectDomain=createEvent(this,"selectDomain",7),this.isOpen=!1,this.value=null,this.options=void 0,this.selected=void 0,this.mode=!1,this.darkMode=!1,this.themeState="default",this.theme="default"}handleWindowClick(){this.wrapperRef.querySelector(".listClass")&&(this.isOpen=!1)}toggleDropdown(){this.isOpen=!this.isOpen,this.calculateDropdownPosition()}watchPropHandler(o){this.themeState=o}watchModeHandler(o){this.mode=o}connectedCallback(){this.themeState=this.theme,this.mode=this.darkMode,this.value=this.options[this.selected],this.selectDomain.emit(this.value.value)}calculateDropdownPosition(){if(this.isOpen&&this.buttonRef){const o=this.buttonRef.getBoundingClientRect();this.ulRef.style.top=`${o.height}px`}}handleChange(o){this.value=o,this.isOpen=!1,this.selectDomain.emit(this.value.value)}render(){const o=(this.isOpen?"listClass":"hidden")+" min-w-[15rem] nl-select-list absolute left-0 shadow-md rounded-lg p-2 mt-1 after:h-4 after:absolute after:-bottom-4 after:start-0 after:w-full before:h-4 before:absolute before:-top-4 before:start-0 before:w-full",s=(this.isOpen?"rotate-180":"rotate-0")+" duration-300 flex-shrink-0 w-4 h-4 text-gray-500";return h("div",{key:"c86084c50712455e04682a4392e490bc0e20eb1d",class:`theme-${this.themeState}`},h("div",{key:"a90d9b4af52845a9971c39cec69c13493d511381",class:"relative",ref:r=>this.wrapperRef=r},h("button",{key:"1391137997bf8fcd0a5466cd9fa20c79b4ce27ba",ref:r=>this.buttonRef=r,onClick:()=>this.toggleDropdown(),type:"button",class:"nl-select peer py-3 px-4 flex items-center w-full justify-between border-transparent rounded-lg text-sm disabled:opacity-50 disabled:pointer-events-none dark:border-transparent"},h("span",{key:"224425ab92ba3599595924972e98a0fc9cb1a189",class:"truncate overflow-hidden"},this.value.name),h("svg",{key:"8eb2a2b552cb9ea36fb1abc61d804efb423afda6",class:s,xmlns:"http://www.w3.org/2000/svg",width:"24",height:"24",viewBox:"0 0 24 24",fill:"none",stroke:"currentColor","stroke-width":"2","stroke-linecap":"round","stroke-linejoin":"round"},h("path",{key:"feea1a7f54f4a111b7bf01e3945445311b97ab82",d:"m6 9 6 6 6-6"}))),h("ul",{key:"fca4982f04f4133d5c2a2f613a7e7d977dd5c241",ref:r=>this.ulRef=r,class:o},this.options.map(r=>h("li",{onClick:()=>this.handleChange(r),class:"nl-select-option flex cursor-pointer items-center gap-x-3.5 py-2 px-3 rounded-lg text-sm"},r.name)))))}get element(){return this}static get watchers(){return{theme:["watchPropHandler"],darkMode:["watchModeHandler"]}}static get style(){return NlSelectStyle0}},[0,"nl-select",{options:[16],selected:[2],darkMode:[4,"dark-mode"],theme:[1],isOpen:[32],value:[32],mode:[32],themeState:[32]},[[8,"click","handleWindowClick"]],{theme:["watchPropHandler"],darkMode:["watchModeHandler"]}]);function defineCustomElement$m(){typeof customElements>"u"||["nl-select"].forEach(o=>{"nl-select"===o&&(customElements.get(o)||customElements.define(o,NlSelect))})}defineCustomElement$m();const nlImportFlowCss=baseCss,NlImportFlowStyle0=nlImportFlowCss,NlImportFlow$1=proxyCustomElement(class extends H{constructor(){super(),this.__registerHost(),this.nlImportAccount=createEvent(this,"nlImportAccount",7),this.nlExportKeys=createEvent(this,"nlExportKeys",7),this.titleInfo="Back up your keys",this.titleImport="Choose a service",this.services=[],this.isContinued=!1,this.isKeyBackup=!1,this.isCopy=!1}handleDomainSelect(o){const s=this.services.find(r=>r.domain===o.detail);state.nlImport=s}handleCreateAccount(o){o.preventDefault(),this.nlImportAccount.emit(state.nlImport)}handleContinue(){this.isContinued=!0}handleContinueKeyBackup(){this.isKeyBackup=!0}copyToClipboard(){var o=this;return(0,_home_runner_work_angor_hub_angor_hub_node_modules_angular_builders_custom_webpack_node_modules_babel_runtime_helpers_esm_asyncToGenerator_js__WEBPACK_IMPORTED_MODULE_1__.A)(function*(){o.nlExportKeys.emit(),o.isCopy=!0,setTimeout(()=>{o.isCopy=!1},1500)})()}render(){if(!this.isContinued&&!this.isKeyBackup)return h("div",{class:"p-4 overflow-y-auto"},h("h1",{class:"nl-title font-bold text-center text-2xl"},this.titleInfo),h("p",{class:"nl-description font-light text-sm pt-2 pb-2 max-w-96 mx-auto"},"Nostr profiles are controlled by cryptographic keys.",h("br",null),h("br",null),"Your keys are currently only stored in this browser tab, and may be lost if you close it.",h("br",null),h("br",null),"You should backup your keys.",h("br",null),h("br",null),"We recommend to import your keys into a key store service, to protect them and to use with other apps."),h("div",{class:"ml-auto mr-auto mb-2 w-72"},h("button-base",{onClick:()=>this.handleContinue(),titleBtn:"Import to key store"})),h("div",{class:"ml-auto mr-auto w-72"},h("button-base",{onClick:()=>this.handleContinueKeyBackup(),titleBtn:"Export keys"})));if(this.isKeyBackup)return h("div",{class:"p-4 overflow-y-auto"},h("h1",{class:"nl-title font-bold text-center text-2xl"},"Key export"),h("p",{class:"nl-description font-light text-sm pt-2 pb-2 max-w-96 mx-auto"},"Copy your keys and store them in a safe place, like a password manager.",h("br",null),h("br",null),"You can sign into other Nostr apps by pasting your keys into them.",h("br",null),h("br",null),"Your keys must be kept secret, never share them with anyone."),h("div",{class:"max-w-72 mx-auto"},h("div",{class:"ml-auto mr-auto mb-2 w-72"},h("button-base",{onClick:()=>this.copyToClipboard(),titleBtn:this.isCopy?"Copied!":"Copy to clipboard"}))));const o=this.services.filter(s=>s.canImport).map(s=>({name:s.domain,value:s.domain}));return h(Fragment,null,h("div",{class:"p-4 overflow-y-auto"},h("h1",{class:"nl-title font-bold text-center text-2xl"},this.titleImport),h("p",{class:"nl-description font-light text-center text-sm pt-2 max-w-96 mx-auto"},"Your Nostr keys will be imported into the service you choose. You will manage your keys on their website.")),h("div",{class:"max-w-72 mx-auto mb-5"},h("div",{class:"mb-0.5"},h("nl-select",{onSelectDomain:s=>this.handleDomainSelect(s),selected:0,options:o})),h("p",{class:"nl-title font-light text-sm mb-2"},"Default provider is a fine choice to start with."),h("div",{class:"ps-4 pe-4 overflow-y-auto"},h("p",{class:"nl-error font-light text-center text-sm max-w-96 mx-auto"},state.error)),h("button-base",{disabled:state.isLoading,onClick:s=>this.handleCreateAccount(s),titleBtn:"Start importing"},state.isLoading?h("span",{slot:"icon-start",class:"animate-spin-loading inline-block w-4 h-4 border-[3px] border-current border-t-transparent text-slate-900 dark:text-gray-300 rounded-full",role:"status","aria-label":"loading"}):h("svg",{slot:"icon-start",style:{display:"none"},xmlns:"http://www.w3.org/2000/svg",fill:"none",viewBox:"0 0 24 24","stroke-width":"1.5",stroke:"currentColor"},h("path",{"stroke-linecap":"round","stroke-linejoin":"round",d:"M18 7.5v3m0 0v3m0-3h3m-3 0h-3m-2.25-4.125a3.375 3.375 0 1 1-6.75 0 3.375 3.375 0 0 1 6.75 0ZM3 19.235v-.11a6.375 6.375 0 0 1 12.75 0v.109A12.318 12.318 0 0 1 9.374 21c-2.331 0-4.512-.645-6.374-1.766Z"})))))}static get style(){return NlImportFlowStyle0}},[0,"nl-import-flow",{titleInfo:[1025,"title-info"],titleImport:[1,"title-import"],services:[16],isContinued:[32],isKeyBackup:[32],isCopy:[32]}]);function defineCustomElement$l(){typeof customElements>"u"||["nl-import-flow","button-base","nl-select"].forEach(o=>{switch(o){case"nl-import-flow":customElements.get(o)||customElements.define(o,NlImportFlow$1);break;case"button-base":customElements.get(o)||defineCustomElement$q();break;case"nl-select":customElements.get(o)||defineCustomElement$m()}})}defineCustomElement$l();const nlInfoCss=baseCss,NlInfoStyle0=nlInfoCss,NlInfo=proxyCustomElement(class extends H{constructor(){super(),this.__registerHost()}render(){return h("div",{key:"7463f42c27643903a9d6fb0160fbabe833679fcb",class:"p-4 overflow-y-auto"},h("svg",{key:"86c5f04f87b21553f3512d289425996b46eb6c57",class:"w-12 h-12 mx-auto mb-2",width:"225",height:"224",viewBox:"0 0 225 224",fill:"none",xmlns:"http://www.w3.org/2000/svg"},h("rect",{key:"6be61e0b2ff3d3f13e617e9b1df073fbe3b5678b",width:"224.047",height:"224",rx:"64",fill:"#6951FA"}),h("path",{key:"0c0aff7d5143022fe857de141cdae31397c3c2f4",d:"M162.441 135.941V88.0593C170.359 85.1674 176 77.5348 176 68.6696C176 57.2919 166.708 48 155.33 48C143.953 48 134.661 57.2444 134.661 68.6696C134.661 77.5822 140.302 85.1674 148.219 88.0593V135.941C147.698 136.13 147.176 136.367 146.655 136.604L87.3956 77.3452C88.6282 74.6904 89.2919 71.7511 89.2919 68.6696C89.2919 57.2444 80.0474 48 68.6696 48C57.2919 48 48 57.2444 48 68.6696C48 77.5822 53.6415 85.1674 61.5585 88.0593V135.941C53.6415 138.833 48 146.465 48 155.33C48 166.708 57.2444 176 68.6696 176C80.0948 176 89.3393 166.708 89.3393 155.33C89.3393 146.418 83.6978 138.833 75.7807 135.941V88.0593C76.3022 87.8696 76.8237 87.6326 77.3452 87.3956L136.604 146.655C135.372 149.31 134.708 152.249 134.708 155.33C134.708 166.708 143.953 176 155.378 176C166.803 176 176.047 166.708 176.047 155.33C176.047 146.418 170.406 138.833 162.489 135.941H162.441Z",fill:"white"})),h("h1",{key:"3a89ee5051e2d74945347dec6055749cec126f27",class:"nl-title font-bold text-center text-4xl"},"Nostr ",h("span",{key:"96a49c22dffa4a30639f387a949d7695604c6a1f",class:"font-light"},"Login")),h("p",{key:"a6dded720da9db673173a1ff02bc5544e6a66d38",class:"text-green-800 dark:text-green-200 font-light text-center text-lg pt-2 max-w-96 mx-auto"},"Version: 1.6.12"),h("p",{key:"9d9dbd36ade753d30db448139dc057921f29697d",class:"nl-description font-light text-center text-lg pt-2 max-w-96 mx-auto"},"Learn more about Nostr"," ",h("a",{key:"1811ad4f1acda7f5235566ea6f2ce8e70c62c91c",target:"_blank",href:"https://nostr.how"},"here"),".",h("br",{key:"127a6127e71f43caa1c262c6ec8108a5a6f40774"}),"This is an"," ",h("a",{key:"0e18839f8577229533eb2d2ef00f8657e6396aa1",target:"_blank",href:"https://github.com/nostrband/nostr-login"},"open-source")," ","tool by"," ",h("a",{key:"9affd14ad9dedae3e5d269a1477343eae63cd46b",target:"_blank",href:"https://nostr.band"},"Nostr.Band"),"."))}static get style(){return NlInfoStyle0}},[0,"nl-info"]);function defineCustomElement$k(){typeof customElements>"u"||["nl-info"].forEach(o=>{"nl-info"===o&&(customElements.get(o)||customElements.define(o,NlInfo))})}defineCustomElement$k();const nlInfoExtensionCss=baseCss,NlInfoExtensionStyle0=nlInfoExtensionCss,NlInfoExtension=proxyCustomElement(class extends H{constructor(){super(),this.__registerHost()}render(){return h("div",{key:"9335feb745c6d09a213a2e771c40262036341b54",class:"p-4 overflow-y-auto"},state.isLoadingExtension?h("div",null,h("h1",{class:"nl-title font-bold text-center text-4xl"},"Signing in..."),h("div",{class:"mt-10 mb-10 ml-auto mr-auto w-20"},h("span",{slot:"icon-start",class:"animate-spin-loading ml-auto mr-auto inline-block w-20 h-20 border-[4px] border-current border-t-transparent text-slate-900 dark:text-gray-300 rounded-full",role:"status","aria-label":"loading"})),h("div",{class:"ps-4 pe-4 overflow-y-auto"},h("p",{class:"nl-error font-light text-center text-sm max-w-96 mx-auto"},state.error))):h("div",null,h("h1",{class:"nl-title font-bold text-center text-4xl"},"Install browser extension!"),h("p",{class:"nl-description font-light text-center text-lg pt-2 max-w-96 mx-auto"},"Try"," ",h("a",{href:"https://getalby.com",target:"_blank"},"Alby"),","," ",h("a",{href:"https://chromewebstore.google.com/detail/nos2x/kpgefcfmnafjgpblomihpgmejjdanjjp",target:"_blank"},"nos2x")," ","or"," ",h("a",{href:"https://apps.apple.com/us/app/nostore/id1666553677",target:"_blank"},"Nostore"))))}static get style(){return NlInfoExtensionStyle0}},[0,"nl-info-extension"]);function defineCustomElement$j(){typeof customElements>"u"||["nl-info-extension"].forEach(o=>{"nl-info-extension"===o&&(customElements.get(o)||customElements.define(o,NlInfoExtension))})}defineCustomElement$j();const nlLoadingCss=baseCss,NlLoadingStyle0=nlLoadingCss,NlLoading=proxyCustomElement(class extends H{constructor(){super(),this.__registerHost(),this.stopFetchHandler=createEvent(this,"stopFetchHandler",7),this.handleContinue=createEvent(this,"handleContinue",7),this.path=void 0}handleStop(o){o.preventDefault(),this.stopFetchHandler.emit()}handleContinueClick(o){o.preventDefault(),this.handleContinue.emit()}render(){let o="Connecting...",s="Establishing connection to your key storage.";this.path===CURRENT_MODULE.LOCAL_SIGNUP?(o="Creating...",s="Publishing your profile on Nostr."):state.authUrl&&(state.isLoading?(o="Confirming...",s="Please confirm the connection in your key storage app."):(o="Almost ready!",s="Continue to confirm the connection to your key storage."));const r=this.path!==CURRENT_MODULE.LOCAL_SIGNUP,i=!state.isLoading&&state.iframeUrl&&state.authUrl,a=`${state.iframeUrl}?connect=${encodeURIComponent(state.authUrl)}`;return h("div",{key:"516866bac0ab965ad91fa153040e38cc94ecfe43",class:"p-4 overflow-y-auto"},h("h1",{key:"51fffb5a84be838536699741d19eb072d4318517",class:"nl-title font-bold text-center text-4xl"},o),h("p",{key:"8c0825a89ca531b74d1fb11fa06632b9bddf11b4",class:"nl-description font-light text-center text-lg pt-2 max-w-96 mx-auto"},s),!state.authUrl&&state.isLoading&&h("div",{key:"5b39a21b600a0524d7eff2885fa9b048b76daf8b",class:"mt-10 mb-10 ml-auto mr-auto w-20"},h("span",{key:"6ac53666049efdd495197b4c57536a3e09969cdb",slot:"icon-start",class:"animate-spin-loading ml-auto mr-auto inline-block w-20 h-20 border-[4px] border-current border-t-transparent text-slate-900 dark:text-gray-300 rounded-full",role:"status","aria-label":"loading"})),h("div",{key:"1a7211d6d3d9f6e14ff02a3605c6c7b1d2dbff09",class:"ps-4 pe-4 overflow-y-auto"},h("p",{key:"678cc1522ff896809fbc0309966497aafb308a36",class:"nl-error font-light text-center text-sm max-w-96 mx-auto"},state.error)),a&&h("div",{key:"6b68b0afd47bb420e142d6cefbe5fb286a6871be",class:"mt-3 ml-auto mr-auto w-72 flex justify-center"},h("iframe",{key:"69526e3b7af7d255b00f2ba1aeb9f688261958eb",src:a,width:"180px",height:"80px",style:{display:i?"block":"none"}})),!i&&r&&h("div",{key:"ea17236efcb5ae4aebec89508337a12f682e35cd",class:"mt-3 ml-auto mr-auto w-72"},h("button-base",{key:"7c6a62128ece1a50a5e01df43f8948f95f42fab2",onClick:c=>{state.authUrl&&!state.isLoading?this.handleContinueClick(c):this.handleStop(c)},titleBtn:state.isLoading?"Cancel":"Continue"})))}static get style(){return NlLoadingStyle0}},[0,"nl-loading",{path:[1]}]);function defineCustomElement$i(){typeof customElements>"u"||["nl-loading","button-base"].forEach(o=>{switch(o){case"nl-loading":customElements.get(o)||customElements.define(o,NlLoading);break;case"button-base":customElements.get(o)||defineCustomElement$q()}})}defineCustomElement$i();const nlLocalSignupCss=baseCss,NlLocalSignupStyle0=nlLocalSignupCss,NlLocalSignup=proxyCustomElement(class extends H{constructor(){super(),this.__registerHost(),this.nlLocalSignup=createEvent(this,"nlLocalSignup",7),this.fetchHandler=createEvent(this,"fetchHandler",7),this.titleSignup="Create Nostr profile",this.description="Choose any username, you can always change it later.",this.isAvailable=!1}handleInputChange(o){state.nlSignup.signupName=o.target.value}handleCreateAccount(o){o.preventDefault(),this.nlLocalSignup.emit(`${state.nlSignup.signupName}`)}render(){return h(Fragment,{key:"1ef0db8a3af10d6bd50c0ee084968abcef035b31"},h("div",{key:"966dbcd09fc2da235a817cbcf01b75e64ba2a3df",class:"p-4 overflow-y-auto"},h("h1",{key:"121ad8a12bb0d30785e26261993c73af716da22a",class:"nl-title font-bold text-center text-2xl"},this.titleSignup),h("p",{key:"6758bc49ee96973718cb301a96ce26949c446512",class:"nl-description font-light text-center text-sm pt-2 max-w-96 mx-auto"},this.description)),h("div",{key:"e8354901c534454753d055542226b56ae7a3ec67",class:"max-w-72 mx-auto"},h("div",{key:"2a84cdb7a830431318ddb3a32c10476ab7aa98c8",class:"relative mb-2"},h("input",{key:"50c84d948104ac51b647b941f1e086f4eecf03d9",onInput:o=>this.handleInputChange(o),type:"text",class:"nl-input peer py-3 px-4 ps-11 block w-full border-transparent rounded-lg text-sm disabled:opacity-50 disabled:pointer-events-none dark:border-transparent",placeholder:"Enter username",value:state.nlSignup.signupName}),h("div",{key:"8c52f3d644a8a0cd278af7646e9dbb0998b56afe",class:"absolute inset-y-0 start-0 flex items-center pointer-events-none ps-4 peer-disabled:opacity-50 peer-disabled:pointer-events-none"},h("svg",{key:"8923dc1949a04c7a10398db3c1211d00ce7fe925",xmlns:"http://www.w3.org/2000/svg",fill:"none",viewBox:"0 0 24 24","stroke-width":"2",stroke:this.isAvailable?"#00cc00":"currentColor",class:"flex-shrink-0 w-4 h-4 text-gray-500"},h("path",{key:"e3303cbea9146cb1a66e47d5ecf51da5a4a2e8b7","stroke-linecap":"round","stroke-linejoin":"round",d:"M15.75 6a3.75 3.75 0 1 1-7.5 0 3.75 3.75 0 0 1 7.5 0ZM4.501 20.118a7.5 7.5 0 0 1 14.998 0A17.933 17.933 0 0 1 12 21.75c-2.676 0-5.216-.584-7.499-1.632Z"})))),h("div",{key:"916d7e92cea31d802b74ce71dd202b7ae5f84ed8",class:"ps-4 pe-4 overflow-y-auto"},h("p",{key:"9bb8ffd3c9a7c2d62f700af314305d6403e9b54d",class:"nl-error font-light text-center text-sm max-w-96 mx-auto"},state.error)),h("button-base",{key:"dcd3530cb7878ec853ea1985cecfda1e03ab8011",disabled:state.isLoading,onClick:o=>this.handleCreateAccount(o),titleBtn:"Create profile"},state.isLoading?h("span",{slot:"icon-start",class:"animate-spin-loading inline-block w-4 h-4 border-[3px] border-current border-t-transparent text-slate-900 dark:text-gray-300 rounded-full",role:"status","aria-label":"loading"}):h("svg",{slot:"icon-start",style:{display:"none"},xmlns:"http://www.w3.org/2000/svg",fill:"none",viewBox:"0 0 24 24","stroke-width":"1.5",stroke:"currentColor"},h("path",{"stroke-linecap":"round","stroke-linejoin":"round",d:"M18 7.5v3m0 0v3m0-3h3m-3 0h-3m-2.25-4.125a3.375 3.375 0 1 1-6.75 0 3.375 3.375 0 0 1 6.75 0ZM3 19.235v-.11a6.375 6.375 0 0 1 12.75 0v.109A12.318 12.318 0 0 1 9.374 21c-2.331 0-4.512-.645-6.374-1.766Z"})))))}static get style(){return NlLocalSignupStyle0}},[0,"nl-local-signup",{titleSignup:[1,"title-signup"],description:[1],isAvailable:[32]}]);function defineCustomElement$h(){typeof customElements>"u"||["nl-local-signup","button-base"].forEach(o=>{switch(o){case"nl-local-signup":customElements.get(o)||customElements.define(o,NlLocalSignup);break;case"button-base":customElements.get(o)||defineCustomElement$q()}})}defineCustomElement$h();const NlLoginStatus=proxyCustomElement(class extends H{constructor(){super(),this.__registerHost(),this.info=void 0}render(){let o="",s="";if("extension"===this.info.authMethod)o="Extension",s="border-yellow-300 text-yellow-500 bg-yellow-100";else if("readOnly"===this.info.authMethod)o="Read only",s="border-gray-300 text-gray-400 bg-gray-100";else if("connect"===this.info.authMethod)o="Connect",s="border-teal-300 text-teal-600 bg-teal-100";else if("local"===this.info.authMethod)o="Temporary",s="border-red-300 text-red-600 bg-red-100";else{if("otp"!==this.info.authMethod)throw console.log("unknown auth method",this.info),new Error("Unknown auth method");o="Delegated",s="border-orange-300 text-orange-600 bg-orange-100"}return h("div",{key:"f7d43062e3d372b26fd7e9c462eabad823b762e1"},h("span",{key:"c79aafe47bf945f5c6bf26aa230debc4d950be71",class:`${s} rounded-xl border w-auto text-[10px] px-1 `},o))}},[0,"nl-login-status",{info:[16]}]);function defineCustomElement$g(){typeof customElements>"u"||["nl-login-status"].forEach(o=>{"nl-login-status"===o&&(customElements.get(o)||customElements.define(o,NlLoginStatus))})}defineCustomElement$g();const nlOtpMigrateCss=baseCss,NlOtpMigrateStyle0=nlOtpMigrateCss,NlImportFlow=proxyCustomElement(class extends H{constructor(){super(),this.__registerHost(),this.nlImportAccount=createEvent(this,"nlImportAccount",7),this.titleInfo="Import keys to storage service",this.titleImport="Choose a service",this.textImport="You will be prompted to import keys to the chosen service, and this website will connect to your keys.",this.services=[]}handleDomainSelect(o){const s=this.services.find(r=>r.domain===o.detail);state.nlImport=s}handleCreateAccount(o){o.preventDefault(),this.nlImportAccount.emit(state.nlImport)}render(){const o=this.services.filter(s=>s.canImport).map(s=>({name:s.domain,value:s.domain}));return h(Fragment,{key:"d27cbfa870975b4f9f0c6350ff6424e34b19dfad"},h("div",{key:"22618ac8a4e7cc53e111cfa47a7db3163ccc43ef",class:"p-4 overflow-y-auto"},h("h1",{key:"ebc3dc11334fa49479a1d071cf9a89bf204ca8ff",class:"nl-title font-bold text-center text-2xl"},this.titleImport),h("p",{key:"70795495de8e8f69488b2cebb2f8c5f1c2ace243",class:"nl-description font-light text-center text-sm pt-2 max-w-96 mx-auto"},this.textImport)),h("div",{key:"a9f4df9d99623c686d22ed200bddb7657984a4f8",class:"max-w-72 mx-auto mb-5"},h("div",{key:"c9a0fedecd1e036f9a84a12aaf44ac6fd8bde10b",class:"mb-0.5"},h("nl-select",{key:"3db03a9a4fd78f544f670c6b1917af67ca818696",onSelectDomain:s=>this.handleDomainSelect(s),selected:0,options:o})),h("p",{key:"fc392301b3553c3fea01ab17341d8e0c829af408",class:"nl-title font-light text-sm mb-2"},"Default provider is a fine choice to start with."),h("div",{key:"e0dd51b7f1f9fe7ca367f309ea945cf5feffedf2",class:"ps-4 pe-4 overflow-y-auto"},h("p",{key:"4316dfbf51fb06b68f55d34bffe4450c29fc273c",class:"nl-error font-light text-center text-sm max-w-96 mx-auto"},state.error)),h("button-base",{key:"dfbd68892ba44c72d4c319725dc82cf3a1af7d96",disabled:state.isLoading,onClick:s=>this.handleCreateAccount(s),titleBtn:"Start importing"},state.isLoading?h("span",{slot:"icon-start",class:"animate-spin-loading inline-block w-4 h-4 border-[3px] border-current border-t-transparent text-slate-900 dark:text-gray-300 rounded-full",role:"status","aria-label":"loading"}):h("svg",{slot:"icon-start",style:{display:"none"},xmlns:"http://www.w3.org/2000/svg",fill:"none",viewBox:"0 0 24 24","stroke-width":"1.5",stroke:"currentColor"},h("path",{"stroke-linecap":"round","stroke-linejoin":"round",d:"M18 7.5v3m0 0v3m0-3h3m-3 0h-3m-2.25-4.125a3.375 3.375 0 1 1-6.75 0 3.375 3.375 0 0 1 6.75 0ZM3 19.235v-.11a6.375 6.375 0 0 1 12.75 0v.109A12.318 12.318 0 0 1 9.374 21c-2.331 0-4.512-.645-6.374-1.766Z"})))))}static get style(){return NlOtpMigrateStyle0}},[0,"nl-otp-migrate",{titleInfo:[1025,"title-info"],titleImport:[1,"title-import"],textImport:[1,"text-import"],services:[16]}]);function defineCustomElement$f(){typeof customElements>"u"||["nl-otp-migrate","button-base","nl-select"].forEach(o=>{switch(o){case"nl-otp-migrate":customElements.get(o)||customElements.define(o,NlImportFlow);break;case"button-base":customElements.get(o)||defineCustomElement$q();break;case"nl-select":customElements.get(o)||defineCustomElement$m()}})}defineCustomElement$f();const nlPreviouslyLoggedCss=baseCss,NlPreviouslyLoggedStyle0=nlPreviouslyLoggedCss,NlPreviouslyLogged=proxyCustomElement(class extends H{constructor(){super(),this.__registerHost(),this.nlSwitchAccount=createEvent(this,"nlSwitchAccount",7),this.nlLoginRecentAccount=createEvent(this,"nlLoginRecentAccount",7),this.nlRemoveRecent=createEvent(this,"nlRemoveRecent",7),this.titlePage="Your profiles",this.description="Switch between active profiles or choose a recent one for fast login.",this.accounts=[],this.recents=[]}handleGoToWelcome(){state.path=[CURRENT_MODULE.WELCOME]}switchToWelcomeIfEmpty(){this.recents.length||this.accounts.length||(state.path=[CURRENT_MODULE.WELCOME])}watchAccounts(){this.switchToWelcomeIfEmpty()}watchRecents(){this.switchToWelcomeIfEmpty()}handleRemoveRecent(o){this.nlRemoveRecent.emit(o)}handleSwitch(o){this.nlSwitchAccount.emit(o)}handleLoginRecentAccount(o){this.nlLoginRecentAccount.emit(o)}render(){return h(Fragment,{key:"0b747732fe31ffb2d687859a8d5f5452de06cd82"},h("div",{key:"b696865acec55c2dc0f6f3ecf6360028f3911136",class:"p-4 pt-0 overflow-y-auto"},h("h1",{key:"156d95e32b1f14cdccfeabb2cb518bbba51b5da6",class:"nl-title font-bold text-center text-4xl"},this.titlePage),h("p",{key:"1d07d29dda5338c71c7831d4550c99af8717012d",class:"nl-description font-light text-center text-lg pt-2 max-w-96 mx-auto"},this.description)),h("div",{key:"3776d52ca658395479d7aaba1d96b707b144da5d",class:"p-4"},!!this.accounts.length&&h("div",{key:"77d80f7e11fd0ad09c5fa13c8b39939a9c011641",class:"max-w-96 mx-auto"},h("p",{key:"f32b9358755c561781e840383a2bc6b2bfe5c392",class:"nl-description font-medium text-sm pb-1.5"},"Active profiles"),h("ul",{key:"789082d6f3ad3d75ebe461cde35846d0ff37e912",class:"p-2 rounded-lg border border-blue-200 flex flex-col w-full gap-0.5"},this.accounts.map(o=>{const s=!!o?.picture,r=o.name||o.nip05||o.pubkey,i=!!r;return h("li",{onClick:()=>this.handleSwitch(o),class:"group hover:bg-gray-400 flex cursor-pointer gap-x-3.5 py-2 px-3 rounded-lg text-sm items-center justify-between"},h("div",{class:"flex items-center gap-x-3.5 w-full"},h("div",{class:"w-full max-w-7 h-7 flex relative"},h("div",{class:"absolute top-[-2px] right-[-2px] bg-white border-2 border-white rounded-xl"},h("div",{class:"active h-1.5 w-1.5 bg-green-500 rounded-xl"})),h("div",{class:"group-hover:border-blue-400 uppercase font-bold w-full h-full rounded-full border border-gray-400 flex justify-center items-center"},s?h("img",{class:"w-full rounded-full",src:o.picture,alt:"Logo"}):i?r[0]:h("svg",{xmlns:"http://www.w3.org/2000/svg",fill:"none",viewBox:"0 0 24 24","stroke-width":"1.5",stroke:"currentColor",class:"w-full"},h("path",{"stroke-linecap":"round","stroke-linejoin":"round",d:"M17.982 18.725A7.488 7.488 0 0 0 12 15.75a7.488 7.488 0 0 0-5.982 2.975m11.963 0a9 9 0 1 0-11.963 0m11.963 0A8.966 8.966 0 0 1 12 21a8.966 8.966 0 0 1-5.982-2.275M15 9.75a3 3 0 1 1-6 0 3 3 0 0 1 6 0Z"})))),h("div",{class:"overflow-hidden flex flex-col w-full"},h("div",{class:"nl-title truncate overflow-hidden"},r),h("nl-login-status",{info:o}))))}))),!!this.recents.length&&h("div",{key:"e89d6cda8386575a0a87a2188a89e5d929b55e8d",class:"max-w-96 mx-auto pt-5"},h("p",{key:"811958459f3694f5e31c2f22c75611c49973b17b",class:"nl-description font-medium text-sm pb-1.5"},"Recent profiles"),h("ul",{key:"0c042b8bec46a9871551bf2965eb9f561b012f22",class:"p-2 rounded-lg border border-gray-200 flex flex-col w-full gap-0.5"},this.recents.map(o=>{const s=!!o?.picture,r=o.name||o.nip05||o.pubkey,i=!!r;return h("li",{onClick:()=>this.handleLoginRecentAccount(o),class:"flex items-center gap-x-3.5 w-full hover:bg-gray-400 flex cursor-pointer items-center gap-x-3.5 py-2 px-3 rounded-lg text-sm justify-between"},h("div",{class:"w-full max-w-7 h-7 flex relative"},h("div",{class:"absolute top-[-3px] right-[-3px] bg-white border border-white rounded-xl"},h("svg",{xmlns:"http://www.w3.org/2000/svg",fill:"none",viewBox:"0 0 24 24","stroke-width":"1.5",stroke:"currentColor",class:"w-3 h-3"},h("path",{"stroke-linecap":"round","stroke-linejoin":"round",d:"M12 6v6h4.5m4.5 0a9 9 0 1 1-18 0 9 9 0 0 1 18 0Z"}))),h("div",{class:"uppercase font-bold w-full h-full rounded-full border border-gray-400 flex justify-center items-center"},s?h("img",{class:"w-full rounded-full",src:o.picture,alt:"Logo"}):i?r[0]:h("svg",{xmlns:"http://www.w3.org/2000/svg",fill:"none",viewBox:"0 0 24 24","stroke-width":"1.5",stroke:"currentColor",class:"w-full"},h("path",{"stroke-linecap":"round","stroke-linejoin":"round",d:"M17.982 18.725A7.488 7.488 0 0 0 12 15.75a7.488 7.488 0 0 0-5.982 2.975m11.963 0a9 9 0 1 0-11.963 0m11.963 0A8.966 8.966 0 0 1 12 21a8.966 8.966 0 0 1-5.982-2.275M15 9.75a3 3 0 1 1-6 0 3 3 0 0 1 6 0Z"})))),h("div",{class:"overflow-hidden flex flex-col w-full"},h("div",{class:"nl-title truncate overflow-hidden"},r),h("nl-login-status",{info:o})),h("svg",{onClick:a=>{a.stopPropagation(),this.handleRemoveRecent(o)},xmlns:"http://www.w3.org/2000/svg",fill:"none",viewBox:"0 0 24 24","stroke-width":"1.5",stroke:"currentColor",class:"w-full max-w-6 h-6 text-red-500 hover:text-red-600 ml-auto"},h("path",{"stroke-linecap":"round","stroke-linejoin":"round",d:"m14.74 9-.346 9m-4.788 0L9.26 9m9.968-3.21c.342.052.682.107 1.022.166m-1.022-.165L18.16 19.673a2.25 2.25 0 0 1-2.244 2.077H8.084a2.25 2.25 0 0 1-2.244-2.077L4.772 5.79m14.456 0a48.108 48.108 0 0 0-3.478-.397m-12 .562c.34-.059.68-.114 1.022-.165m0 0a48.11 48.11 0 0 1 3.478-.397m7.5 0v-.916c0-1.18-.91-2.164-2.09-2.201a51.964 51.964 0 0 0-3.32 0c-1.18.037-2.09 1.022-2.09 2.201v.916m7.5 0a48.667 48.667 0 0 0-7.5 0"})))})))),h("div",{key:"f70f67171d6727d25b9a38bdf48730146c46f4f2",class:"p-4 overflow-y-auto"},h("p",{key:"7289d6c89d90db640ecc63603657280dec8d3a82",class:"nl-footer font-light text-center text-sm max-w-96 mx-auto"},"You can also"," ",h("span",{key:"5c0d9e2954a37fc013d459a78b8a056b916cdd62",onClick:()=>this.handleGoToWelcome(),class:"cursor-pointer pb-3 text-blue-500"},"add another profile"))))}static get watchers(){return{accounts:["watchAccounts"],recents:["watchRecents"]}}static get style(){return NlPreviouslyLoggedStyle0}},[0,"nl-previously-logged",{titlePage:[1,"title-page"],description:[1],accounts:[16],recents:[16]},void 0,{accounts:["watchAccounts"],recents:["watchRecents"]}]);function defineCustomElement$e(){typeof customElements>"u"||["nl-previously-logged","nl-login-status"].forEach(o=>{switch(o){case"nl-previously-logged":customElements.get(o)||customElements.define(o,NlPreviouslyLogged);break;case"nl-login-status":customElements.get(o)||defineCustomElement$g()}})}defineCustomElement$e();const nlSigninCss=baseCss,NlSigninStyle0=nlSigninCss,NlSignin=proxyCustomElement(class extends H{constructor(){super(),this.__registerHost(),this.nlLogin=createEvent(this,"nlLogin",7),this.nlCheckLogin=createEvent(this,"nlCheckLogin",7),this.titleLogin="Connect to key store",this.description="Please enter your user name.",this.isGood=!1}handleInputChange(o){state.nlSignin.loginName=o.target.value,this.nlCheckLogin.emit(o.target.value)}handleLogin(o){o.preventDefault(),this.nlLogin.emit(state.nlSignin.loginName)}render(){return h(Fragment,{key:"70d5c41620a53b3b84157044f33fdce851d9054d"},h("div",{key:"f8880d45479ef512694fe1300a3c99df8dc756f2",class:"p-4 overflow-y-auto"},h("h1",{key:"fb0379faf61fa39d283fd2d159932b0dba56ed60",class:"nl-title font-bold text-center text-2xl"},this.titleLogin),h("p",{key:"389dcc582e456ba3241a202aa77026b5fe1f2f1c",class:"nl-description font-light text-center text-sm pt-2 max-w-96 mx-auto"},this.description)),h("div",{key:"0cbc1dd3dd3e8437d5f1be8c5612a48ebf589a73",class:"max-w-72 mx-auto"},h("div",{key:"6d8d1a649d6f9b4ec39e91cb50880ec55ae34469",class:"relative mb-2"},h("input",{key:"546c3c63fc1849275b86efdfb8fa5b016ae4282b",onInput:o=>this.handleInputChange(o),type:"text",class:"nl-input peer py-3 px-4 ps-11 block w-full border-transparent rounded-lg text-sm disabled:opacity-50 disabled:pointer-events-none dark:border-transparent",placeholder:"name@domain.com",value:state.nlSignin.loginName}),h("div",{key:"c91b2fb461ca2ee751a0811381a771ed227d1c7b",class:"absolute inset-y-0 start-0 flex items-center pointer-events-none ps-4 peer-disabled:opacity-50 peer-disabled:pointer-events-none"},h("svg",{key:"cd11d6e2e75a3e3e60696d825f494e49d587abc3",xmlns:"http://www.w3.org/2000/svg",fill:"none",viewBox:"0 0 24 24","stroke-width":"2",stroke:this.isGood?"#00cc00":"currentColor",class:"flex-shrink-0 w-4 h-4 text-gray-500"},h("path",{key:"dd3d6d8e13a01fdb449dadbb5daa79141ae74217","stroke-linecap":"round","stroke-linejoin":"round",d:"M15.75 6a3.75 3.75 0 1 1-7.5 0 3.75 3.75 0 0 1 7.5 0ZM4.501 20.118a7.5 7.5 0 0 1 14.998 0A17.933 17.933 0 0 1 12 21.75c-2.676 0-5.216-.584-7.499-1.632Z"})))),h("div",{key:"e2aff3f44b41a2365f9c561410c2d8733e93943d",class:"ps-4 pe-4 overflow-y-auto"},h("p",{key:"4f3b61256e93001cbf6cf8e0eea61e73265abd65",class:"nl-error font-light text-center text-sm max-w-96 mx-auto"},state.error)),h("button-base",{key:"64e9997f3163465cc99eae8600e7b13251ffe484",titleBtn:"Connect",disabled:state.isLoading,onClick:o=>this.handleLogin(o)},state.isLoading?h("span",{slot:"icon-start",class:"animate-spin-loading inline-block w-4 h-4 border-[3px] border-current border-t-transparent text-slate-900 dark:text-gray-300 rounded-full",role:"status","aria-label":"loading"}):h("svg",{style:{display:"none"},slot:"icon-start",xmlns:"http://www.w3.org/2000/svg",fill:"none",viewBox:"0 0 24 24","stroke-width":"1.5",stroke:"currentColor"},h("path",{"stroke-linecap":"round","stroke-linejoin":"round",d:"M8.25 9V5.25A2.25 2.25 0 0 1 10.5 3h6a2.25 2.25 0 0 1 2.25 2.25v13.5A2.25 2.25 0 0 1 16.5 21h-6a2.25 2.25 0 0 1-2.25-2.25V15M12 9l3 3m0 0-3 3m3-3H2.25"})))))}static get style(){return NlSigninStyle0}},[0,"nl-signin",{titleLogin:[1,"title-login"],description:[1],isGood:[32]}]);function defineCustomElement$d(){typeof customElements>"u"||["nl-signin","button-base"].forEach(o=>{switch(o){case"nl-signin":customElements.get(o)||customElements.define(o,NlSignin);break;case"button-base":customElements.get(o)||defineCustomElement$q()}})}defineCustomElement$d();const nlSigninBunkerUrlCss=baseCss,NlSigninBunkerUrlStyle0=nlSigninBunkerUrlCss,NlSigninBunkerUrl=proxyCustomElement(class extends H{constructor(){super(),this.__registerHost(),this.nlLogin=createEvent(this,"nlLogin",7),this.nlCheckLogin=createEvent(this,"nlCheckLogin",7),this.titleLogin="Connect with bunker url",this.description="Please enter a bunker url provided by key store.",this.isGood=!1}handleInputChange(o){state.nlSigninBunkerUrl.loginName=o.target.value,this.nlCheckLogin.emit(o.target.value)}handleLogin(o){o.preventDefault(),this.nlLogin.emit(state.nlSigninBunkerUrl.loginName)}render(){return h(Fragment,{key:"0ac12fea476faa724c8fa9ba34bebbd58c0b324d"},h("div",{key:"94fc0ef392c7d6abedc1bba2c833ff3e734fde23",class:"p-4 overflow-y-auto"},h("h1",{key:"c8426115b8d12e24e349813302360dc37ae935ca",class:"nl-title font-bold text-center text-2xl"},this.titleLogin),h("p",{key:"804a1e0b2329e78f80470da090cb06fd3165116f",class:"nl-description font-light text-center text-sm pt-2 max-w-96 mx-auto"},this.description)),h("div",{key:"3dad7e0005f66ad81c616983921455bf77b95c31",class:"max-w-72 mx-auto"},h("div",{key:"3e2f1825061c8f65c300676624d244240abb9590",class:"relative mb-2"},h("input",{key:"048e82df548ed4018684b92a93cd20c6ea60af95",onInput:o=>this.handleInputChange(o),type:"text",class:"nl-input peer py-3 px-4 ps-11 block w-full border-transparent rounded-lg text-sm disabled:opacity-50 disabled:pointer-events-none dark:border-transparent",placeholder:"bunker://...",value:state.nlSigninBunkerUrl.loginName}),h("div",{key:"29afff805cfc2d5e135ece3d5d791e6a1506294b",class:"absolute inset-y-0 start-0 flex items-center pointer-events-none ps-4 peer-disabled:opacity-50 peer-disabled:pointer-events-none"},h("svg",{key:"3ca9eb00e319357c690fa7d0027dba1e61d7fb83",xmlns:"http://www.w3.org/2000/svg",fill:"none",viewBox:"0 0 24 24","stroke-width":"2",stroke:this.isGood?"#00cc00":"currentColor",class:"flex-shrink-0 w-4 h-4 text-gray-500"},h("path",{key:"2914d12af813da649534f1aca80f3b80d1e53193","stroke-linecap":"round","stroke-linejoin":"round",d:"M13.19 8.688a4.5 4.5 0 0 1 1.242 7.244l-4.5 4.5a4.5 4.5 0 0 1-6.364-6.364l1.757-1.757m13.35-.622 1.757-1.757a4.5 4.5 0 0 0-6.364-6.364l-4.5 4.5a4.5 4.5 0 0 0 1.242 7.244"})))),h("div",{key:"83617653feed00b5d45b4d8318369a16185ca690",class:"ps-4 pe-4 overflow-y-auto"},h("p",{key:"3548cd177582a91b8c4b383311f04fd4b8b2002e",class:"nl-error font-light text-center text-sm max-w-96 mx-auto"},state.error)),h("button-base",{key:"8ae258e580cae2a08955ff02b4d21601a3be3aee",titleBtn:"Connect",disabled:state.isLoading,onClick:o=>this.handleLogin(o)},state.isLoading?h("span",{slot:"icon-start",class:"animate-spin-loading inline-block w-4 h-4 border-[3px] border-current border-t-transparent text-slate-900 dark:text-gray-300 rounded-full",role:"status","aria-label":"loading"}):h("svg",{style:{display:"none"},slot:"icon-start",xmlns:"http://www.w3.org/2000/svg",fill:"none",viewBox:"0 0 24 24","stroke-width":"1.5",stroke:"currentColor"},h("path",{"stroke-linecap":"round","stroke-linejoin":"round",d:"M8.25 9V5.25A2.25 2.25 0 0 1 10.5 3h6a2.25 2.25 0 0 1 2.25 2.25v13.5A2.25 2.25 0 0 1 16.5 21h-6a2.25 2.25 0 0 1-2.25-2.25V15M12 9l3 3m0 0-3 3m3-3H2.25"})))))}static get style(){return NlSigninBunkerUrlStyle0}},[0,"nl-signin-bunker-url",{titleLogin:[1,"title-login"],description:[1],isGood:[32]}]);function defineCustomElement$c(){typeof customElements>"u"||["nl-signin-bunker-url","button-base"].forEach(o=>{switch(o){case"nl-signin-bunker-url":customElements.get(o)||customElements.define(o,NlSigninBunkerUrl);break;case"button-base":customElements.get(o)||defineCustomElement$q()}})}defineCustomElement$c();var browser$1={},canPromise$1=function(){return"function"==typeof Promise&&Promise.prototype&&Promise.prototype.then},qrcode={},utils$1$1={};let toSJISFunction;const CODEWORDS_COUNT=[0,26,44,70,100,134,172,196,242,292,346,404,466,532,581,655,733,815,901,991,1085,1156,1258,1364,1474,1588,1706,1828,1921,2051,2185,2323,2465,2611,2761,2876,3034,3196,3362,3532,3706];utils$1$1.getSymbolSize=function(o){if(!o)throw new Error('"version" cannot be null or undefined');if(o<1||o>40)throw new Error('"version" should be in range from 1 to 40');return 4*o+17},utils$1$1.getSymbolTotalCodewords=function(o){return CODEWORDS_COUNT[o]},utils$1$1.getBCHDigit=function(o){let s=0;for(;0!==o;)s++,o>>>=1;return s},utils$1$1.setToSJISFunction=function(o){if("function"!=typeof o)throw new Error('"toSJISFunc" is not a valid function.');toSJISFunction=o},utils$1$1.isKanjiModeEnabled=function(){return void 0!==toSJISFunction},utils$1$1.toSJIS=function(o){return toSJISFunction(o)};var errorCorrectionLevel={},exports;function BitBuffer$1(){this.buffer=[],this.length=0}exports=errorCorrectionLevel,exports.L={bit:1},exports.M={bit:0},exports.Q={bit:3},exports.H={bit:2},exports.isValid=function(o){return o&&void 0!==o.bit&&o.bit>=0&&o.bit<4},exports.from=function(o,s){if(exports.isValid(o))return o;try{return function(r){if("string"!=typeof r)throw new Error("Param is not a string");switch(r.toLowerCase()){case"l":case"low":return exports.L;case"m":case"medium":return exports.M;case"q":case"quartile":return exports.Q;case"h":case"high":return exports.H;default:throw new Error("Unknown EC Level: "+r)}}(o)}catch{return s}},BitBuffer$1.prototype={get:function(o){const s=Math.floor(o/8);return 1==(this.buffer[s]>>>7-o%8&1)},put:function(o,s){for(let r=0;r>>s-r-1&1))},getLengthInBits:function(){return this.length},putBit:function(o){const s=Math.floor(this.length/8);this.buffer.length<=s&&this.buffer.push(0),o&&(this.buffer[s]|=128>>>this.length%8),this.length++}};var bitBuffer=BitBuffer$1;function BitMatrix$1(o){if(!o||o<1)throw new Error("BitMatrix size must be defined and greater than 0");this.size=o,this.data=new Uint8Array(o*o),this.reservedBit=new Uint8Array(o*o)}BitMatrix$1.prototype.set=function(o,s,r,i){const a=o*this.size+s;this.data[a]=r,i&&(this.reservedBit[a]=!0)},BitMatrix$1.prototype.get=function(o,s){return this.data[o*this.size+s]},BitMatrix$1.prototype.xor=function(o,s,r){this.data[o*this.size+s]^=r},BitMatrix$1.prototype.isReserved=function(o,s){return this.reservedBit[o*this.size+s]};var bitMatrix=BitMatrix$1,alignmentPattern={};!function(o){const s=utils$1$1.getSymbolSize;o.getRowColCoords=function(r){if(1===r)return[];const i=Math.floor(r/7)+2,a=s(r),c=145===a?26:2*Math.ceil((a-13)/(2*i-2)),y=[a-7];for(let w=1;w=0&&y<=7},o.from=function(y){return o.isValid(y)?parseInt(y,10):void 0},o.getPenaltyN1=function(y){const w=y.size;let C=0,T=0,S=0,M=null,O=null;for(let L=0;L=5&&(C+=T-5+3),M=q,T=1),q=y.get(Z,L),q===O?S++:(S>=5&&(C+=S-5+3),O=q,S=1)}T>=5&&(C+=T-5+3),S>=5&&(C+=S-5+3)}return C},o.getPenaltyN2=function(y){const w=y.size;let C=0;for(let T=0;T=10&&(1488===T||93===T)&&C++,S=S<<1&2047|y.get(O,M),O>=10&&(1488===S||93===S)&&C++}return 40*C},o.getPenaltyN4=function(y){let w=0;const C=y.data.length;for(let T=0;T=0;){const c=a[0];for(let w=0;w0){const a=new Uint8Array(this.degree);return a.set(r,i),a}return r};var reedSolomonEncoder=ReedSolomonEncoder$1,version={},mode={},versionCheck={isValid:function(o){return!isNaN(o)&&o>=1&&o<=40}},regex$1={};const numeric="[0-9]+",alphanumeric="[A-Z $%*+\\-./:]+";let kanji="(?:[u3000-u303F]|[u3040-u309F]|[u30A0-u30FF]|[uFF00-uFFEF]|[u4E00-u9FAF]|[u2605-u2606]|[u2190-u2195]|u203B|[u2010u2015u2018u2019u2025u2026u201Cu201Du2225u2260]|[u0391-u0451]|[u00A7u00A8u00B1u00B4u00D7u00F7])+";kanji=kanji.replace(/u/g,"\\u");const byte="(?:(?![A-Z0-9 $%*+\\-./:]|"+kanji+")(?:.|[\r\n]))+";regex$1.KANJI=new RegExp(kanji,"g"),regex$1.BYTE_KANJI=new RegExp("[^A-Z0-9 $%*+\\-./:]+","g"),regex$1.BYTE=new RegExp(byte,"g"),regex$1.NUMERIC=new RegExp(numeric,"g"),regex$1.ALPHANUMERIC=new RegExp(alphanumeric,"g");const TEST_KANJI=new RegExp("^"+kanji+"$"),TEST_NUMERIC=new RegExp("^"+numeric+"$"),TEST_ALPHANUMERIC=new RegExp("^[A-Z0-9 $%*+\\-./:]+$");regex$1.testKanji=function(o){return TEST_KANJI.test(o)},regex$1.testNumeric=function(o){return TEST_NUMERIC.test(o)},regex$1.testAlphanumeric=function(o){return TEST_ALPHANUMERIC.test(o)},function(o){const s=versionCheck,r=regex$1;o.NUMERIC={id:"Numeric",bit:1,ccBits:[10,12,14]},o.ALPHANUMERIC={id:"Alphanumeric",bit:2,ccBits:[9,11,13]},o.BYTE={id:"Byte",bit:4,ccBits:[8,16,16]},o.KANJI={id:"Kanji",bit:8,ccBits:[8,10,12]},o.MIXED={bit:-1},o.getCharCountIndicator=function(i,a){if(!i.ccBits)throw new Error("Invalid mode: "+i);if(!s.isValid(a))throw new Error("Invalid version: "+a);return a>=1&&a<10?i.ccBits[0]:a<27?i.ccBits[1]:i.ccBits[2]},o.getBestModeForData=function(i){return r.testNumeric(i)?o.NUMERIC:r.testAlphanumeric(i)?o.ALPHANUMERIC:r.testKanji(i)?o.KANJI:o.BYTE},o.toString=function(i){if(i&&i.id)return i.id;throw new Error("Invalid mode")},o.isValid=function(i){return i&&i.bit&&i.ccBits},o.from=function(i,a){if(o.isValid(i))return i;try{return function(c){if("string"!=typeof c)throw new Error("Param is not a string");switch(c.toLowerCase()){case"numeric":return o.NUMERIC;case"alphanumeric":return o.ALPHANUMERIC;case"kanji":return o.KANJI;case"byte":return o.BYTE;default:throw new Error("Unknown mode: "+c)}}(i)}catch{return a}}}(mode),function(o){const s=utils$1$1,r=errorCorrectionCode,i=errorCorrectionLevel,a=mode,c=versionCheck,y=s.getBCHDigit(7973);function w(T,S){return a.getCharCountIndicator(T,S)+4}function C(T,S){let M=0;return T.forEach(function(O){const L=w(O.mode,S);M+=L+O.getBitsLength()}),M}o.from=function(T,S){return c.isValid(T)?parseInt(T,10):S},o.getCapacity=function(T,S,M){if(!c.isValid(T))throw new Error("Invalid QR Code version");void 0===M&&(M=a.BYTE);const O=8*(s.getSymbolTotalCodewords(T)-r.getTotalCodewordsCount(T,S));if(M===a.MIXED)return O;const L=O-w(M,T);switch(M){case a.NUMERIC:return Math.floor(L/10*3);case a.ALPHANUMERIC:return Math.floor(L/11*2);case a.KANJI:return Math.floor(L/13);default:return Math.floor(L/8)}},o.getBestVersionForData=function(T,S){let M;const O=i.from(S,i.M);if(Array.isArray(T)){if(T.length>1)return function(L,Z){for(let q=1;q<=40;q++)if(C(L,q)<=o.getCapacity(q,Z,a.MIXED))return q}(T,O);if(0===T.length)return 1;M=T[0]}else M=T;return function(L,Z,q){for(let re=1;re<=40;re++)if(Z<=o.getCapacity(re,q,L))return re}(M.mode,M.getLength(),O)},o.getEncodedBits=function(T){if(!c.isValid(T)||T<7)throw new Error("Invalid QR Code version");let S=T<<12;for(;s.getBCHDigit(S)-y>=0;)S^=7973<=0;)i^=G15<0&&(r=this.data.substr(s),i=parseInt(r,10),o.put(i,3*a+1))};var numericData=NumericData;const Mode$3=mode,ALPHA_NUM_CHARS=["0","1","2","3","4","5","6","7","8","9","A","B","C","D","E","F","G","H","I","J","K","L","M","N","O","P","Q","R","S","T","U","V","W","X","Y","Z"," ","$","%","*","+","-",".","/",":"];function AlphanumericData(o){this.mode=Mode$3.ALPHANUMERIC,this.data=o}AlphanumericData.getBitsLength=function(o){return 11*Math.floor(o/2)+o%2*6},AlphanumericData.prototype.getLength=function(){return this.data.length},AlphanumericData.prototype.getBitsLength=function(){return AlphanumericData.getBitsLength(this.data.length)},AlphanumericData.prototype.write=function(o){let s;for(s=0;s+2<=this.data.length;s+=2){let r=45*ALPHA_NUM_CHARS.indexOf(this.data[s]);r+=ALPHA_NUM_CHARS.indexOf(this.data[s+1]),o.put(r,11)}this.data.length%2&&o.put(ALPHA_NUM_CHARS.indexOf(this.data[s]),6)};var alphanumericData=AlphanumericData;const Mode$2=mode;function ByteData(o){this.mode=Mode$2.BYTE,this.data="string"==typeof o?(new TextEncoder).encode(o):new Uint8Array(o)}ByteData.getBitsLength=function(o){return 8*o},ByteData.prototype.getLength=function(){return this.data.length},ByteData.prototype.getBitsLength=function(){return ByteData.getBitsLength(this.data.length)},ByteData.prototype.write=function(o){for(let s=0,r=this.data.length;s=33088&&r<=40956)r-=33088;else{if(!(r>=57408&&r<=60351))throw new Error("Invalid SJIS character: "+this.data[s]+"\nMake sure your charset is UTF-8");r-=49472}r=192*(r>>>8&255)+(255&r),o.put(r,13)}};var kanjiData=KanjiData,dijkstra={exports:{}};(function(o){var s={single_source_shortest_paths:function(r,i,a){var c={},y={};y[i]=0;var w,C,T,S,M,O,Z=s.PriorityQueue.make();for(Z.push(i,0);!Z.empty();)for(T in C=(w=Z.pop()).value,S=w.cost,M=r[C]||{})M.hasOwnProperty(T)&&(O=S+M[T],(void 0===y[T]||y[T]>O)&&(y[T]=O,Z.push(T,O),c[T]=C));if(void 0!==a&&void 0===y[a]){var q=["Could not find a path from ",i," to ",a,"."].join("");throw new Error(q)}return c},extract_shortest_path_from_predecessor_list:function(r,i){for(var a=[],c=i;c;)a.push(c),c=r[c];return a.reverse(),a},find_path:function(r,i,a){var c=s.single_source_shortest_paths(r,i,a);return s.extract_shortest_path_from_predecessor_list(c,a)},PriorityQueue:{make:function(r){var i,a=s.PriorityQueue,c={};for(i in r=r||{},a)a.hasOwnProperty(i)&&(c[i]=a[i]);return c.queue=[],c.sorter=r.sorter||a.default_sorter,c},default_sorter:function(r,i){return r.cost-i.cost},push:function(r,i){this.queue.push({value:r,cost:i}),this.queue.sort(this.sorter)},pop:function(){return this.queue.shift()},empty:function(){return 0===this.queue.length}}};o.exports=s})(dijkstra),function(o){const s=mode,r=numericData,i=alphanumericData,a=byteData,c=kanjiData,y=regex$1,w=utils$1$1,C=dijkstra.exports;function T(Z){return unescape(encodeURIComponent(Z)).length}function S(Z,q,re){const pe=[];let se;for(;null!==(se=Z.exec(re));)pe.push({data:se[0],index:se.index,mode:q,length:se[0].length});return pe}function M(Z){const q=S(y.NUMERIC,s.NUMERIC,Z),re=S(y.ALPHANUMERIC,s.ALPHANUMERIC,Z);let pe,se;return w.isKanjiModeEnabled()?(pe=S(y.BYTE,s.BYTE,Z),se=S(y.KANJI,s.KANJI,Z)):(pe=S(y.BYTE_KANJI,s.BYTE,Z),se=[]),q.concat(re,pe,se).sort(function(ae,me){return ae.index-me.index}).map(function(ae){return{data:ae.data,mode:ae.mode,length:ae.length}})}function O(Z,q){switch(q){case s.NUMERIC:return r.getBitsLength(Z);case s.ALPHANUMERIC:return i.getBitsLength(Z);case s.KANJI:return c.getBitsLength(Z);case s.BYTE:return a.getBitsLength(Z)}}function L(Z,q){let re;const pe=s.getBestModeForData(Z);if(re=s.from(q,pe),re!==s.BYTE&&re.bit=0?be[be.length-1]:null;return xe&&xe.mode===Oe.mode?(be[be.length-1].data+=Oe.data,be):(be.push(Oe),be)},[]))},o.rawSplit=function(Z){return o.fromArray(M(Z,w.isKanjiModeEnabled()))}}(segments);const Utils$1=utils$1$1,ECLevel=errorCorrectionLevel,BitBuffer=bitBuffer,BitMatrix=bitMatrix,AlignmentPattern=alignmentPattern,FinderPattern=finderPattern,MaskPattern=maskPattern,ECCode=errorCorrectionCode,ReedSolomonEncoder=reedSolomonEncoder,Version=version,FormatInfo=formatInfo,Mode=mode,Segments=segments;function setupFinderPattern(o,s){const r=o.size,i=FinderPattern.getPositions(s);for(let a=0;a=0&&w<=6&&(0===C||6===C)||C>=0&&C<=6&&(0===w||6===w)||w>=2&&w<=4&&C>=2&&C<=4,!0)}}function setupTimingPattern(o){const s=o.size;for(let r=8;r>w&1),o.set(a,c,y,!0),o.set(c,a,y,!0)}function setupFormatInfo(o,s,r){const i=o.size,a=FormatInfo.getEncodedBits(s,r);let c,y;for(c=0;c<15;c++)y=1==(a>>c&1),o.set(c<6?c:c<8?c+1:i-15+c,8,y,!0),o.set(8,c<8?i-c-1:c<9?15-c-1+1:15-c-1,y,!0);o.set(i-8,8,1,!0)}function setupData(o,s){const r=o.size;let i=-1,a=r-1,c=7,y=0;for(let w=r-1;w>0;w-=2)for(6===w&&w--;;){for(let C=0;C<2;C++)if(!o.isReserved(a,w-C)){let T=!1;y>>c&1)),o.set(a,w-C,T),c--,-1===c&&(y++,c=7)}if(a+=i,a<0||r<=a){a-=i,i=-i;break}}}function createData(o,s,r){const i=new BitBuffer;r.forEach(function(y){i.put(y.mode.bit,4),i.put(y.getLength(),Mode.getCharCountIndicator(y.mode,o)),y.write(i)});const a=8*(Utils$1.getSymbolTotalCodewords(o)-ECCode.getTotalCodewordsCount(o,s));for(i.getLengthInBits()+4<=a&&i.put(0,4);i.getLengthInBits()%8!=0;)i.putBit(0);const c=(a-i.getLengthInBits())/8;for(let y=0;y=7&&setupVersionInfo(C,s),setupData(C,y),isNaN(i)&&(i=MaskPattern.getBestMask(C,setupFormatInfo.bind(null,C,r))),MaskPattern.applyMask(i,C),setupFormatInfo(C,r,i),{modules:C,version:s,errorCorrectionLevel:r,maskPattern:i,segments:a}}qrcode.create=function(o,s){if(void 0===o||""===o)throw new Error("No input text");let r,i,a=ECLevel.M;return void 0!==s&&(a=ECLevel.from(s.errorCorrectionLevel,ECLevel.M),r=Version.from(s.version),i=MaskPattern.from(s.maskPattern),s.toSJISFunc&&Utils$1.setToSJISFunction(s.toSJISFunc)),createSymbol(o,r,a,i)};var canvas={},utils$3={};(function(o){function s(r){if("number"==typeof r&&(r=r.toString()),"string"!=typeof r)throw new Error("Color should be defined as hex string");let i=r.slice().replace("#","").split("");if(i.length<3||5===i.length||i.length>8)throw new Error("Invalid hex color: "+r);3!==i.length&&4!==i.length||(i=Array.prototype.concat.apply([],i.map(function(c){return[c,c]}))),6===i.length&&i.push("F","F");const a=parseInt(i.join(""),16);return{r:a>>24&255,g:a>>16&255,b:a>>8&255,a:255&a,hex:"#"+i.slice(0,6).join("")}}o.getOptions=function(r){r||(r={}),r.color||(r.color={});const a=r.width&&r.width>=21?r.width:void 0;return{width:a,scale:a?4:r.scale||4,margin:null==r.margin||r.margin<0?4:r.margin,color:{dark:s(r.color.dark||"#000000ff"),light:s(r.color.light||"#ffffffff")},type:r.type,rendererOpts:r.rendererOpts||{}}},o.getScale=function(r,i){return i.width&&i.width>=r+2*i.margin?i.width/(r+2*i.margin):i.scale},o.getImageWidth=function(r,i){const a=o.getScale(r,i);return Math.floor((r+2*i.margin)*a)},o.qrToImageData=function(r,i,a){const c=i.modules.size,y=i.modules.data,w=o.getScale(c,a),C=Math.floor((c+2*a.margin)*w),T=a.margin*w,S=[a.color.light,a.color.dark];for(let M=0;M=T&&O>=T&&M0&&C>0&&o[w-1]||(i+=c?svgCmd("M",C+r,.5+T+r):svgCmd("m",a,0),a=0,c=!1),C+1':"",C="',S=''+w+C+"\n";return"function"==typeof r&&r(null,S),S};const canPromise=canPromise$1,QRCode=qrcode,CanvasRenderer=canvas,SvgRenderer=svgTag;function renderCanvas(o,s,r,i,a){const c=[].slice.call(arguments,1),y=c.length,w="function"==typeof c[y-1];if(!w&&!canPromise())throw new Error("Callback required as last argument");if(!w){if(y<1)throw new Error("Too few arguments provided");return 1===y?(r=s,s=i=void 0):2!==y||s.getContext||(i=r,r=s,s=void 0),new Promise(function(C,T){try{const S=QRCode.create(r,i);C(o(S,s,i))}catch(S){T(S)}})}if(y<2)throw new Error("Too few arguments provided");2===y?(a=r,r=s,s=i=void 0):3===y&&(s.getContext&&void 0===a?(a=i,i=void 0):(a=i,i=r,r=s,s=void 0));try{const C=QRCode.create(r,i);a(null,o(C,s,i))}catch(C){a(C)}}browser$1.create=QRCode.create,browser$1.toCanvas=renderCanvas.bind(null,CanvasRenderer.render),browser$1.toDataURL=renderCanvas.bind(null,CanvasRenderer.renderToDataURL),browser$1.toString=renderCanvas.bind(null,function(o,s,r){return SvgRenderer.render(o,r)});const nlSigninConnectionStringCss=baseCss,NlSigninConnectionStringStyle0=nlSigninConnectionStringCss,NlSigninConnectionString=proxyCustomElement(class extends H{constructor(){super(),this.__registerHost(),this.titleLogin="Connection string",this.description="Scan or copy the connection string with key store app",this.connectionString="",this.isCopy=!1}componentDidLoad(){this.generateQRCode()}generateQRCode(){var o=this;return(0,_home_runner_work_angor_hub_angor_hub_node_modules_angular_builders_custom_webpack_node_modules_babel_runtime_helpers_esm_asyncToGenerator_js__WEBPACK_IMPORTED_MODULE_1__.A)(function*(){if(o.connectionString&&o.canvasElement)try{yield browser$1.toCanvas(o.canvasElement,o.connectionString)}catch(s){console.error("Error generating QR Code:",s)}})()}copyToClipboard(){var o=this;return(0,_home_runner_work_angor_hub_angor_hub_node_modules_angular_builders_custom_webpack_node_modules_babel_runtime_helpers_esm_asyncToGenerator_js__WEBPACK_IMPORTED_MODULE_1__.A)(function*(){try{yield navigator.clipboard.writeText(o.connectionString),o.isCopy=!0,setTimeout(()=>{o.isCopy=!1},1500)}catch(s){console.error("Failed to copy connectionString: ",s)}})()}render(){return h(Fragment,{key:"4dfdad6e2e948203e0dfe7aa8608d95cd3495c41"},h("div",{key:"852159a0231473f13c6452e307b90f02e7efd445",class:"p-4 overflow-y-auto"},h("h1",{key:"07859d4b83c5fb6ac12732f1708db3ba3b700380",class:"nl-title font-bold text-center text-2xl"},this.titleLogin),h("p",{key:"200d00f3785f4a684c798225f0061d9ef4ed2fa1",class:"nl-description font-light text-center text-sm pt-2 max-w-96 mx-auto"},this.description)),h("canvas",{key:"e27335a378a7853fd73cdf0b701a9922f9e87a98",class:"mx-auto mb-2",ref:o=>this.canvasElement=o}),h("div",{key:"5e93edcf3b13f1d02b6feca2a192ef275891032a",class:"px-4"},h("div",{key:"96643d192fc3e3c652027fc7b9da2c8186205b1f",class:"max-w-72 mx-auto"},h("div",{key:"24faf8ea390198fc185f94d77d0ac3faa3c03e9f",class:"relative mb-2"},h("input",{key:"45f531795476a136897925509955fa9fdaf66503",type:"text",class:"nl-input peer py-3 px-4 pe-11 ps-11 block w-full border-transparent rounded-lg text-sm disabled:opacity-50 disabled:pointer-events-none dark:border-transparent",placeholder:"npub or name@domain",value:this.connectionString,disabled:!0}),h("div",{key:"3f3bb777777890fb68152c94d16cd83abde57cac",class:"absolute inset-y-0 start-0 flex items-center pointer-events-none ps-4 peer-disabled:opacity-50 peer-disabled:pointer-events-none"},h("svg",{key:"c99e6d36b5f3e85a03b2922a3984803601ce4747",xmlns:"http://www.w3.org/2000/svg",fill:"none",viewBox:"0 0 24 24","stroke-width":"1.5",stroke:"currentColor",class:"flex-shrink-0 w-4 h-4 text-gray-500"},h("path",{key:"1d72c6d727215e897c88b923f1eb65a83bc9eda9","stroke-linecap":"round","stroke-linejoin":"round",d:"M2.036 12.322a1.012 1.012 0 0 1 0-.639C3.423 7.51 7.36 4.5 12 4.5c4.638 0 8.573 3.007 9.963 7.178.07.207.07.431 0 .639C20.577 16.49 16.64 19.5 12 19.5c-4.638 0-8.573-3.007-9.963-7.178Z"}),h("path",{key:"5c40e5fd22377e528bdc3fe77db8975dfe015286","stroke-linecap":"round","stroke-linejoin":"round",d:"M15 12a3 3 0 1 1-6 0 3 3 0 0 1 6 0Z"}))),this.isCopy?h("div",{class:"absolute inset-y-0 end-0 flex items-center p-2 rounded-lg"},h("svg",{xmlns:"http://www.w3.org/2000/svg",fill:"none",viewBox:"0 0 24 24","stroke-width":"1.5",stroke:"#00cc00",class:"flex-shrink-0 w-4 h-4 text-gray-500"},h("path",{"stroke-linecap":"round","stroke-linejoin":"round",d:"M9 12.75 11.25 15 15 9.75M21 12a9 9 0 1 1-18 0 9 9 0 0 1 18 0Z"}))):h("div",{class:"absolute inset-y-0 end-0 flex items-center cursor-pointer p-2 rounded-lg",onClick:()=>this.copyToClipboard()},h("svg",{xmlns:"http://www.w3.org/2000/svg",fill:"none",viewBox:"0 0 24 24","stroke-width":"1.5",stroke:"currentColor",class:"flex-shrink-0 w-4 h-4 text-gray-500"},h("path",{"stroke-linecap":"round","stroke-linejoin":"round",d:"M16.5 8.25V6a2.25 2.25 0 0 0-2.25-2.25H6A2.25 2.25 0 0 0 3.75 6v8.25A2.25 2.25 0 0 0 6 16.5h2.25m8.25-8.25H18a2.25 2.25 0 0 1 2.25 2.25V18A2.25 2.25 0 0 1 18 20.25h-7.5A2.25 2.25 0 0 1 8.25 18v-1.5m8.25-8.25h-6a2.25 2.25 0 0 0-2.25 2.25v6"})))),h("div",{key:"26403008de1debe9660fbacda25b6c5eb1ce81c8",class:"mt-10 justify-center items-center flex gap-2"},h("span",{key:"2cc09432eb515db009f4ca5909b8ba943c90bbd6",slot:"icon-start",class:"animate-spin-loading inline-block w-[20px] h-[20px] border-[2px] border-current border-t-transparent text-slate-900 dark:text-gray-300 rounded-full",role:"status","aria-label":"loading"}),h("span",{key:"b2d8a70b65950ec00d9544c4ba50a51bffc48335",class:"nl-footer"},"Waiting for connection")))))}static get style(){return NlSigninConnectionStringStyle0}},[0,"nl-signin-connection-string",{titleLogin:[1,"title-login"],description:[1],connectionString:[1,"connection-string"],isCopy:[32]}]);function defineCustomElement$b(){typeof customElements>"u"||["nl-signin-connection-string"].forEach(o=>{"nl-signin-connection-string"===o&&(customElements.get(o)||customElements.define(o,NlSigninConnectionString))})}defineCustomElement$b();const nlSigninOtpCss=baseCss,NlSigninOtpStyle0=nlSigninOtpCss,NlSigninOtp=proxyCustomElement(class extends H{constructor(){super(),this.__registerHost(),this.nlLoginOTPUser=createEvent(this,"nlLoginOTPUser",7),this.nlLoginOTPCode=createEvent(this,"nlLoginOTPCode",7),this.nlCheckLogin=createEvent(this,"nlCheckLogin",7),this.titleLogin="Log in with DM",this.description="Please enter your user name or npub, and we will send you a direct message with a one-time code.",this.titleLoginOTP="Enter the code",this.descriptionOTP="Please enter the one-time code we sent to you as a direct message on Nostr.",this.isGood=!1}handleInputChange(o){state.isOTP?state.nlSigninOTP.code=o.target.value:(state.nlSigninOTP.loginName=o.target.value,this.nlCheckLogin.emit(state.nlSigninOTP.loginName))}handleLogin(o){o.preventDefault(),state.isOTP?this.nlLoginOTPCode.emit(state.nlSigninOTP.code):this.nlLoginOTPUser.emit(state.nlSigninOTP.loginName)}render(){return h(Fragment,{key:"a93b9af1f6a2a881d75e9aa1e547a63678ad4dc5"},h("div",{key:"ae6c700a09e753e0148b5ddfd27f20c2a0850d3d",class:"p-4 overflow-y-auto"},h("h1",{key:"e0998107834bf9e90b6372580ccb31bb0d726904",class:"nl-title font-bold text-center text-2xl"},state.isOTP?this.titleLoginOTP:this.titleLogin),h("p",{key:"29e894bbfcdfb326ae807055c57fbb32b1b4bfa9",class:"nl-description font-light text-center text-sm pt-2 max-w-96 mx-auto"},state.isOTP?this.descriptionOTP:this.description)),h("div",{key:"911cee576416be96c64d38fc362cdb656293e198",class:"max-w-72 mx-auto"},h("div",{key:"f72d607dd7beb554c248c7c4128de6d33a8f246f",class:"relative mb-2"},h("input",{key:"24e6a78d257e84d4f5c71b4aee31c453a504cd93",onInput:o=>this.handleInputChange(o),type:"text",class:"nl-input peer py-3 px-4 ps-11 block w-full border-transparent rounded-lg text-sm disabled:opacity-50 disabled:pointer-events-none dark:border-transparent",placeholder:state.isOTP?"code from direct message":"npub or name@domain",value:state.isOTP?state.nlSigninOTP.code:state.nlSigninOTP.loginName}),h("div",{key:"438171f72c2c64d1754a2d5fda95a7b5d3816894",class:"absolute inset-y-0 start-0 flex items-center pointer-events-none ps-4 peer-disabled:opacity-50 peer-disabled:pointer-events-none"},h("svg",{key:"b31663307181bb1d58884a3ecce192728b164b70",xmlns:"http://www.w3.org/2000/svg",fill:"none",viewBox:"0 0 24 24","stroke-width":"1.5",stroke:this.isGood?"#00cc00":"currentColor",class:"flex-shrink-0 w-4 h-4 text-gray-500"},h("path",{key:"8b80421658eea7b0b49708c994a9d94b965895f1","stroke-linecap":"round","stroke-linejoin":"round",d:"M2.036 12.322a1.012 1.012 0 0 1 0-.639C3.423 7.51 7.36 4.5 12 4.5c4.638 0 8.573 3.007 9.963 7.178.07.207.07.431 0 .639C20.577 16.49 16.64 19.5 12 19.5c-4.638 0-8.573-3.007-9.963-7.178Z"}),h("path",{key:"6d184bdf20d124a312e1817e27111de1fd0b8eb1","stroke-linecap":"round","stroke-linejoin":"round",d:"M15 12a3 3 0 1 1-6 0 3 3 0 0 1 6 0Z"})))),h("div",{key:"ab8948cbd67e068fc2f113fcc5e61137d799e636",class:"ps-4 pe-4 overflow-y-auto"},h("p",{key:"719399b9f40ae23ba11ae22e4223314c815c821f",class:"nl-error font-light text-center text-sm max-w-96 mx-auto"},state.error)),h("button-base",{key:"b2ce8bbaceeddc82ea079dba280dc04600d7f725",titleBtn:"Log in",disabled:state.isLoading,onClick:o=>this.handleLogin(o)},state.isLoading&&h("span",{key:"7764fb6ecf8452c06047dc7832e274ebccdd6379",slot:"icon-start",class:"animate-spin-loading inline-block w-4 h-4 border-[3px] border-current border-t-transparent text-slate-900 dark:text-gray-300 rounded-full",role:"status","aria-label":"loading"}))))}static get style(){return NlSigninOtpStyle0}},[0,"nl-signin-otp",{titleLogin:[1,"title-login"],description:[1],titleLoginOTP:[1,"title-login-o-t-p"],descriptionOTP:[1,"description-o-t-p"],isGood:[32]}]);function defineCustomElement$a(){typeof customElements>"u"||["nl-signin-otp","button-base"].forEach(o=>{switch(o){case"nl-signin-otp":customElements.get(o)||customElements.define(o,NlSigninOtp);break;case"button-base":customElements.get(o)||defineCustomElement$q()}})}defineCustomElement$a();const nlSigninReadOnlyCss=baseCss,NlSigninReadOnlyStyle0=nlSigninReadOnlyCss,NlSigninReadOnly=proxyCustomElement(class extends H{constructor(){super(),this.__registerHost(),this.nlLoginReadOnly=createEvent(this,"nlLoginReadOnly",7),this.nlCheckLogin=createEvent(this,"nlCheckLogin",7),this.titleLogin="Log in to read only",this.description="Please enter the user name or npub of any Nostr user.",this.isGood=!1}handleInputChange(o){state.nlSigninReadOnly.loginName=o.target.value,this.nlCheckLogin.emit(o.target.value)}handleLogin(o){o.preventDefault(),this.nlLoginReadOnly.emit(state.nlSigninReadOnly.loginName)}render(){return h(Fragment,{key:"5ff970ee20c505cab00b3c9263dd9a6ebd6b62a8"},h("div",{key:"036a6b49de93c20ed4af3c47c7ecc10c81818f86",class:"p-4 overflow-y-auto"},h("h1",{key:"97951254c835d38f95832882225fdc2b50bf578a",class:"nl-title font-bold text-center text-2xl"},this.titleLogin),h("p",{key:"e811a52ee24540b018f95ebffd1406330005a5f2",class:"nl-description font-light text-center text-sm pt-2 max-w-96 mx-auto"},this.description)),h("div",{key:"ae07b4fbe663e17733b6bd1efaa1c974276c8fd6",class:"max-w-72 mx-auto"},h("div",{key:"0a935603a2742e049bd5b2ca3c1b13f07d63ac2b",class:"relative mb-2"},h("input",{key:"1221b6501de2c739fc1470f82142b623afe4749b",onInput:o=>this.handleInputChange(o),type:"text",class:"nl-input peer py-3 px-4 ps-11 block w-full border-transparent rounded-lg text-sm disabled:opacity-50 disabled:pointer-events-none dark:border-transparent",placeholder:"npub or name@domain",value:state.nlSigninReadOnly.loginName}),h("div",{key:"820f77d6c814aea1794463b6216df338c6f0863d",class:"absolute inset-y-0 start-0 flex items-center pointer-events-none ps-4 peer-disabled:opacity-50 peer-disabled:pointer-events-none"},h("svg",{key:"9922ba1b7b536ddc8d560d76087fd735e1aa000c",xmlns:"http://www.w3.org/2000/svg",fill:"none",viewBox:"0 0 24 24","stroke-width":"1.5",stroke:this.isGood?"#00cc00":"currentColor",class:"flex-shrink-0 w-4 h-4 text-gray-500"},h("path",{key:"250dae1273e5346920bb6d5cad3644c678a9eae8","stroke-linecap":"round","stroke-linejoin":"round",d:"M2.036 12.322a1.012 1.012 0 0 1 0-.639C3.423 7.51 7.36 4.5 12 4.5c4.638 0 8.573 3.007 9.963 7.178.07.207.07.431 0 .639C20.577 16.49 16.64 19.5 12 19.5c-4.638 0-8.573-3.007-9.963-7.178Z"}),h("path",{key:"e94192cf4f271cf3477ebe2f186597a5c5a7b474","stroke-linecap":"round","stroke-linejoin":"round",d:"M15 12a3 3 0 1 1-6 0 3 3 0 0 1 6 0Z"})))),h("div",{key:"8d548af75b9c39dfe0bf2eeae805e58d2cb324c1",class:"ps-4 pe-4 overflow-y-auto"},h("p",{key:"7cc88f5116a24e1b309e320c63c34f5cc8c5b656",class:"nl-error font-light text-center text-sm max-w-96 mx-auto"},state.error)),h("button-base",{key:"156e8a30228a8d34009c5cb020588c82f039eac5",titleBtn:"Log in",disabled:state.isLoading,onClick:o=>this.handleLogin(o)},state.isLoading&&h("span",{key:"14082758440bf5ec897629c92faf949f80895be8",slot:"icon-start",class:"animate-spin-loading inline-block w-4 h-4 border-[3px] border-current border-t-transparent text-slate-900 dark:text-gray-300 rounded-full",role:"status","aria-label":"loading"}))))}static get style(){return NlSigninReadOnlyStyle0}},[0,"nl-signin-read-only",{titleLogin:[1,"title-login"],description:[1],isGood:[32]}]);function defineCustomElement$9(){typeof customElements>"u"||["nl-signin-read-only","button-base"].forEach(o=>{switch(o){case"nl-signin-read-only":customElements.get(o)||customElements.define(o,NlSigninReadOnly);break;case"button-base":customElements.get(o)||defineCustomElement$q()}})}defineCustomElement$9();const nlSignupCss=baseCss,NlSignupStyle0=nlSignupCss,NlSignup=proxyCustomElement(class extends H{constructor(){super(),this.__registerHost(),this.nlSignup=createEvent(this,"nlSignup",7),this.nlCheckSignup=createEvent(this,"nlCheckSignup",7),this.fetchHandler=createEvent(this,"fetchHandler",7),this.titleSignup="Create keys with key store",this.description="Choose some username and a key store service.",this.bunkers="nsec.app,highlighter.com",this.isAvailable=!1}formatServers(o){return o.split(",").map(s=>({name:"@"+s,value:s}))}handleInputChange(o){state.nlSignup.signupName=o.target.value,this.nlCheckSignup.emit(`${o.target.value}@${state.nlSignup.domain}`)}handleDomainSelect(o){state.nlSignup.domain=o.detail,this.nlCheckSignup.emit(`${state.nlSignup.signupName}@${o.detail}`)}handleCreateAccount(o){o.preventDefault(),this.nlSignup.emit(`${state.nlSignup.signupName}@${state.nlSignup.domain}`)}watchBunkersHandler(o){state.nlSignup.servers=this.formatServers(o)}componentWillLoad(){state.nlSignup.servers=this.formatServers(this.bunkers)}render(){return h(Fragment,{key:"f7b56fee1ec9c6dd3632bed5d46c661b090a32cd"},h("div",{key:"a7fd1b6249688b0974a0c56a0573f36eb1f1d7a4",class:"p-4 overflow-y-auto"},h("h1",{key:"01d5a745026ea0a293fd248880f00d335355f5bf",class:"nl-title font-bold text-center text-2xl"},this.titleSignup),h("p",{key:"1fe9362df4c08bee7966a3d7f06aca0c8c9f9e38",class:"nl-description font-light text-center text-sm pt-2 max-w-96 mx-auto"},this.description)),h("div",{key:"15eadc1d7189a9a99efad1c42a430fb316d3ae1a",class:"max-w-72 mx-auto"},h("div",{key:"011c9eb5d2d16cd6b784f0d879fd4f504c522905",class:"relative mb-2"},h("input",{key:"123e130805b229fe68c64765c434a36840cc137e",onInput:o=>this.handleInputChange(o),type:"text",class:"nl-input peer py-3 px-4 ps-11 block w-full border-transparent rounded-lg text-sm disabled:opacity-50 disabled:pointer-events-none dark:border-transparent",placeholder:"Name",value:state.nlSignup.signupName}),h("div",{key:"ee00cfd158acb362567e909a6f90d2651a4acd05",class:"absolute inset-y-0 start-0 flex items-center pointer-events-none ps-4 peer-disabled:opacity-50 peer-disabled:pointer-events-none"},h("svg",{key:"bc8a81c9a62cb215efb0cdff30980ee447371ec5",xmlns:"http://www.w3.org/2000/svg",fill:"none",viewBox:"0 0 24 24","stroke-width":"2",stroke:this.isAvailable?"#00cc00":"currentColor",class:"flex-shrink-0 w-4 h-4 text-gray-500"},h("path",{key:"fb78fc743ec535bb92d30e2b43927d499f6299ca","stroke-linecap":"round","stroke-linejoin":"round",d:"M15.75 6a3.75 3.75 0 1 1-7.5 0 3.75 3.75 0 0 1 7.5 0ZM4.501 20.118a7.5 7.5 0 0 1 14.998 0A17.933 17.933 0 0 1 12 21.75c-2.676 0-5.216-.584-7.499-1.632Z"})))),h("div",{key:"f541cd6ed4d04a52afb093053c6fea85d0926ce1",class:"mb-2"},h("nl-select",{key:"dbce850d0c1d2e1cfdf4ce250978ce508abc173a",onSelectDomain:o=>this.handleDomainSelect(o),selected:0,options:state.nlSignup.servers})),h("div",{key:"a68612eabd83e3f7e61b533fd247f1768554b0c1",class:"ps-4 pe-4 overflow-y-auto"},h("p",{key:"25c8a89289071d5fca16b5e8918026c41afb3a77",class:"nl-error font-light text-center text-sm max-w-96 mx-auto"},state.error)),h("button-base",{key:"6cbf8ff97e9ebf1bd830e86337219ee386f978ea",disabled:state.isLoading,onClick:o=>this.handleCreateAccount(o),titleBtn:"Create profile"},state.isLoading?h("span",{slot:"icon-start",class:"animate-spin-loading inline-block w-4 h-4 border-[3px] border-current border-t-transparent text-slate-900 dark:text-gray-300 rounded-full",role:"status","aria-label":"loading"}):h("svg",{slot:"icon-start",style:{display:"none"},xmlns:"http://www.w3.org/2000/svg",fill:"none",viewBox:"0 0 24 24","stroke-width":"1.5",stroke:"currentColor"},h("path",{"stroke-linecap":"round","stroke-linejoin":"round",d:"M18 7.5v3m0 0v3m0-3h3m-3 0h-3m-2.25-4.125a3.375 3.375 0 1 1-6.75 0 3.375 3.375 0 0 1 6.75 0ZM3 19.235v-.11a6.375 6.375 0 0 1 12.75 0v.109A12.318 12.318 0 0 1 9.374 21c-2.331 0-4.512-.645-6.374-1.766Z"})))))}static get watchers(){return{bunkers:["watchBunkersHandler"]}}static get style(){return NlSignupStyle0}},[0,"nl-signup",{titleSignup:[1,"title-signup"],description:[1],bunkers:[1],isAvailable:[32]},void 0,{bunkers:["watchBunkersHandler"]}]);function defineCustomElement$8(){typeof customElements>"u"||["nl-signup","button-base","nl-select"].forEach(o=>{switch(o){case"nl-signup":customElements.get(o)||customElements.define(o,NlSignup);break;case"button-base":customElements.get(o)||defineCustomElement$q();break;case"nl-select":customElements.get(o)||defineCustomElement$m()}})}defineCustomElement$8();const nlWelcomeCss=baseCss,NlWelcomeStyle0=nlWelcomeCss,NlWelcome=proxyCustomElement(class extends H{constructor(){super(),this.__registerHost(),this.titleWelcome="Welcome to Nostr!",this.description="This website is part of the Nostr network. Log in with your Nostr profile or sign up to join."}handleChangeScreen(o){state.path=[...state.path,o]}render(){return h(Fragment,{key:"d3fb00029cb12cc8b00f26eaed6bd76e90402363"},h("div",{key:"e41a79654adb620ee433848c965fd872cdfcc58c",class:"p-4 overflow-y-auto"},h("h1",{key:"28e5c6ec6a4e4982a386daff93446db4efcd0737",class:"nl-title font-bold text-center text-4xl"},this.titleWelcome),h("p",{key:"d0afbc9587aafe4d93c547b34f5f55c268b42e48",class:"nl-description font-light text-center text-lg pt-2 max-w-96 mx-auto"},this.description)),h("div",{key:"d5570f014a56f326348b8077429c198b55b66683",class:"max-w-52 mx-auto pb-5"},h("div",{key:"3f4095a715c960544264eae1dc809c3bc68de2a8",class:"flex gap-3 flex-col mb-2"},h("button-base",{key:"a154d028e883fb9d9ea1823a5df0d2500bfdb726",titleBtn:"Log in",onClick:()=>this.handleChangeScreen(CURRENT_MODULE.WELCOME_LOGIN)},h("svg",{key:"2b256c1a23f88a3232e59fa3d56c344eae398690",style:{display:"none"},slot:"icon-start",xmlns:"http://www.w3.org/2000/svg",fill:"none",viewBox:"0 0 24 24","stroke-width":"1.5",stroke:"currentColor"},h("path",{key:"bf629d871a100f59c2b465d50f58081290b4300a","stroke-linecap":"round","stroke-linejoin":"round",d:"M15.75 5.25a3 3 0 0 1 3 3m3 0a6 6 0 0 1-7.029 5.912c-.563-.097-1.159.026-1.563.43L10.5 17.25H8.25v2.25H6v2.25H2.25v-2.818c0-.597.237-1.17.659-1.591l6.499-6.499c.404-.404.527-1 .43-1.563A6 6 0 1 1 21.75 8.25Z"})))),h("button-base",{key:"6fdf8ff44483ec67cff96015ebc7d1832a676fa3",onClick:()=>this.handleChangeScreen(CURRENT_MODULE.WELCOME_SIGNUP),titleBtn:"Sign up"},h("svg",{key:"6714790ee5ccb91a6bda3424e515ea273f2163f9",style:{display:"none"},slot:"icon-start",xmlns:"http://www.w3.org/2000/svg",fill:"none",viewBox:"0 0 24 24","stroke-width":"1.5",stroke:"currentColor"},h("path",{key:"e31e8d7667a33a8713387f8eb73252a4016b5de4","stroke-linecap":"round","stroke-linejoin":"round",d:"M18 7.5v3m0 0v3m0-3h3m-3 0h-3m-2.25-4.125a3.375 3.375 0 1 1-6.75 0 3.375 3.375 0 0 1 6.75 0ZM3 19.235v-.11a6.375 6.375 0 0 1 12.75 0v.109A12.318 12.318 0 0 1 9.374 21c-2.331 0-4.512-.645-6.374-1.766Z"})))))}static get style(){return NlWelcomeStyle0}},[0,"nl-welcome",{titleWelcome:[1,"title-welcome"],description:[1]}]);function defineCustomElement$7(){typeof customElements>"u"||["nl-welcome","button-base"].forEach(o=>{switch(o){case"nl-welcome":customElements.get(o)||customElements.define(o,NlWelcome);break;case"button-base":customElements.get(o)||defineCustomElement$q()}})}defineCustomElement$7();const nlWelcomeSigninCss=baseCss,NlWelcomeSigninStyle0=nlWelcomeSigninCss,NlWelcomeSignIn=proxyCustomElement(class extends H{constructor(){super(),this.__registerHost(),this.nlLoginExtension=createEvent(this,"nlLoginExtension",7),this.titleWelcome="Log in",this.hasExtension=!1,this.authMethods=[],this.hasOTP=!1}handleChangeScreen(o){state.path=[...state.path,o],o===CURRENT_MODULE.EXTENSION&&this.nlLoginExtension.emit()}allowAuthMethod(o){return!this.authMethods.length||this.authMethods.includes(o)}renderSignInWithExtension(){return h("button-base",{onClick:()=>this.handleChangeScreen(CURRENT_MODULE.EXTENSION),titleBtn:"With extension"},h("svg",{style:{display:"none"},slot:"icon-start",xmlns:"http://www.w3.org/2000/svg",fill:"none",viewBox:"0 0 24 24","stroke-width":"1.5",stroke:"currentColor"},h("path",{"stroke-linecap":"round","stroke-linejoin":"round",d:"M3 8.25V18a2.25 2.25 0 0 0 2.25 2.25h13.5A2.25 2.25 0 0 0 21 18V8.25m-18 0V6a2.25 2.25 0 0 1 2.25-2.25h13.5A2.25 2.25 0 0 1 21 6v2.25m-18 0h18M5.25 6h.008v.008H5.25V6ZM7.5 6h.008v.008H7.5V6Zm2.25 0h.008v.008H9.75V6Z"})))}render(){return h(Fragment,{key:"49598c3d31f3a4c2fc9d3579283163c43f19b6c7"},h("div",{key:"6b3c16634c1dc4be65c425edb65f5070990fee91",class:"p-4 overflow-y-auto"},h("h1",{key:"1f60d1f489afaa42c47e28563fadc0fa7b46a3df",class:"nl-title font-bold text-center text-3xl"},this.titleWelcome)),h("div",{key:"01507d2b6d0bba54527e12d664ddefd7244a9697",class:"max-w-52 mx-auto pb-5"},h("div",{key:"82deccfff688e1cbb67191c90a3ca6f22f285744",class:"flex gap-3 flex-col"},this.allowAuthMethod("connect")&&h("button-base",{key:"177bbcf244409242ab1c7c03cfb60300e848fed2",titleBtn:"Connect",onClick:()=>this.handleChangeScreen(CURRENT_MODULE.CONNECT)},h("svg",{key:"1fa2c695562eb093430389253dd7f94733d63976",style:{display:"none"},slot:"icon-start",xmlns:"http://www.w3.org/2000/svg",fill:"none",viewBox:"0 0 24 24","stroke-width":"1.5",stroke:"currentColor"},h("path",{key:"16323646bde098c55c787cc90b66b4952c803542","stroke-linecap":"round","stroke-linejoin":"round",d:"M8.25 9V5.25A2.25 2.25 0 0 1 10.5 3h6a2.25 2.25 0 0 1 2.25 2.25v13.5A2.25 2.25 0 0 1 16.5 21h-6a2.25 2.25 0 0 1-2.25-2.25V15M12 9l3 3m0 0-3 3m3-3H2.25"}))),this.allowAuthMethod("readOnly")&&h("button-base",{key:"9b6d546d7f34ca197baa13ec0f280890ff0d8c7f",onClick:()=>this.handleChangeScreen(CURRENT_MODULE.LOGIN_READ_ONLY),titleBtn:"Read only"},h("svg",{key:"2ab8c1763d88e7c5678cafc3c15817d60a7bb6c0",style:{display:"none"},slot:"icon-start",xmlns:"http://www.w3.org/2000/svg",fill:"none",viewBox:"0 0 24 24","stroke-width":"1.5",stroke:"currentColor"},h("path",{key:"faa5a61e8d35daf7fbb64fc5783c23b8881d8100","stroke-linecap":"round","stroke-linejoin":"round",d:"M2.036 12.322a1.012 1.012 0 0 1 0-.639C3.423 7.51 7.36 4.5 12 4.5c4.638 0 8.573 3.007 9.963 7.178.07.207.07.431 0 .639C20.577 16.49 16.64 19.5 12 19.5c-4.638 0-8.573-3.007-9.963-7.178Z"}),h("path",{key:"6083db853e798c9764b11ed4701dab048d4f30f2","stroke-linecap":"round","stroke-linejoin":"round",d:"M15 12a3 3 0 1 1-6 0 3 3 0 0 1 6 0Z"}))),this.hasOTP&&this.allowAuthMethod("otp")&&h("button-base",{key:"f45b1afed2d9b10a2d77eaa59b1aa168eabb191d",titleBtn:"One-time code",onClick:()=>this.handleChangeScreen(CURRENT_MODULE.LOGIN_OTP)},h("svg",{key:"84fbe5952fecd429f8074c65675d2111eb2d7fe8",style:{display:"none"},slot:"icon-start",xmlns:"http://www.w3.org/2000/svg",fill:"none",viewBox:"0 0 24 24","stroke-width":"1.5",stroke:"currentColor"},h("path",{key:"83dc6eaa4e128065dfd7e97f0950cd00f0be6d54","stroke-linecap":"round","stroke-linejoin":"round",d:"M12 6v6h4.5m4.5 0a9 9 0 1 1-18 0 9 9 0 0 1 18 0Z"}))),this.hasExtension&&this.allowAuthMethod("extension")&&this.renderSignInWithExtension(),!this.allowAuthMethod("connect")&&!this.hasExtension&&h("p",{key:"f94e3302a807855f45855302482542e6f79f8ec8",class:"nl-description font-light text-center text-lg pt-2 max-w-96 mx-auto"},"No Nostr extension!"),!this.allowAuthMethod("connect")&&this.hasExtension&&!this.allowAuthMethod("extension")&&h("p",{key:"552762dfd2b9d24c7279c1f500ccd94500e35be1",class:"nl-description font-light text-center text-lg pt-2 max-w-96 mx-auto"},"Use advanced options."))))}static get style(){return NlWelcomeSigninStyle0}},[0,"nl-welcome-signin",{titleWelcome:[1,"title-welcome"],hasExtension:[4,"has-extension"],authMethods:[16],hasOTP:[4,"has-o-t-p"]}]);function defineCustomElement$6(){typeof customElements>"u"||["nl-welcome-signin","button-base"].forEach(o=>{switch(o){case"nl-welcome-signin":customElements.get(o)||customElements.define(o,NlWelcomeSignIn);break;case"button-base":customElements.get(o)||defineCustomElement$q()}})}defineCustomElement$6();const nlWelcomeSignupCss=baseCss,NlWelcomeSignupStyle0=nlWelcomeSignupCss,NlWelcomeSignUp=proxyCustomElement(class extends H{constructor(){super(),this.__registerHost(),this.titleWelcome="Sign up",this.description="Nostr profiles are based on cryptographic keys. You can create keys right here, or with a key storage app."}handleChangeScreen(o){state.path=[...state.path,o]}render(){return h(Fragment,{key:"95a13ee24b5203b1f1fe9f355524abba9dc55dcb"},h("div",{key:"23209055b5ab42ed4e147f0d7e38ec320437f783",class:"p-4 overflow-y-auto"},h("h1",{key:"8f06a983aa9ca0caa01dd35d4907552696ffc996",class:"nl-title font-bold text-center text-3xl"},this.titleWelcome),h("p",{key:"14d88998c67951b047b79dd0d9358ae2b7a19895",class:"nl-description font-light text-center text-lg pt-2 max-w-96 mx-auto"},this.description)),h("div",{key:"62344241204e1c08e2d497b0bbc28b9aff3d7640",class:"max-w-52 mx-auto pb-5"},h("div",{key:"641c269ff23d94330acf465e62d294ce42b05212",class:"flex gap-3 flex-col"},h("button-base",{key:"aaa7f28f647f05506e93756df2895cef952b2912",onClick:()=>this.handleChangeScreen(CURRENT_MODULE.LOCAL_SIGNUP),titleBtn:"Create keys"},h("svg",{key:"2e8c77cdd122a51638f9a2e606d9ff33581b84c7",style:{display:"none"},slot:"icon-start",xmlns:"http://www.w3.org/2000/svg",fill:"none",viewBox:"0 0 24 24","stroke-width":"1.5",stroke:"currentColor"},h("path",{key:"b6d0e6199dcc11a7ac9f4ba47c86219e325fa987","stroke-linecap":"round","stroke-linejoin":"round",d:"M15.75 5.25a3 3 0 0 1 3 3m3 0a6 6 0 0 1-7.029 5.912c-.563-.097-1.159.026-1.563.43L10.5 17.25H8.25v2.25H6v2.25H2.25v-2.818c0-.597.237-1.17.659-1.591l6.499-6.499c.404-.404.527-1 .43-1.563A6 6 0 1 1 21.75 8.25Z"}))),h("button-base",{key:"3c239d1df872ac71424478fd3f6857c5a9148ef6",onClick:()=>this.handleChangeScreen(CURRENT_MODULE.SIGNUP),titleBtn:"With key store"},h("svg",{key:"4600c4e8bb4e62d9a0303ae1abc464c6d6fc7899",style:{display:"none"},slot:"icon-start",xmlns:"http://www.w3.org/2000/svg",fill:"none",viewBox:"0 0 24 24","stroke-width":"1.5",stroke:"currentColor"},h("path",{key:"c36bef296a15f3bb43c984ed083a8defeb530ab4","stroke-linecap":"round","stroke-linejoin":"round",d:"M20.25 6.375c0 2.278-3.694 4.125-8.25 4.125S3.75 8.653 3.75 6.375m16.5 0c0-2.278-3.694-4.125-8.25-4.125S3.75 4.097 3.75 6.375m16.5 0v11.25c0 2.278-3.694 4.125-8.25 4.125s-8.25-1.847-8.25-4.125V6.375m16.5 0v3.75m-16.5-3.75v3.75m16.5 0v3.75C20.25 16.153 16.556 18 12 18s-8.25-1.847-8.25-4.125v-3.75m16.5 0c0 2.278-3.694 4.125-8.25 4.125s-8.25-1.847-8.25-4.125"}))))))}static get style(){return NlWelcomeSignupStyle0}},[0,"nl-welcome-signup",{titleWelcome:[1,"title-welcome"],description:[1]}]);function defineCustomElement$5(){typeof customElements>"u"||["nl-welcome-signup","button-base"].forEach(o=>{switch(o){case"nl-welcome-signup":customElements.get(o)||customElements.define(o,NlWelcomeSignUp);break;case"button-base":customElements.get(o)||defineCustomElement$q()}})}defineCustomElement$5();const nlAuthCss=baseCss,NlAuthStyle0=nlAuthCss,NlAuth=proxyCustomElement(class extends H{constructor(){super(),this.__registerHost(),this.__attachShadow(),this.nlCloseModal=createEvent(this,"nlCloseModal",7),this.nlChangeDarkMode=createEvent(this,"nlChangeDarkMode",7),this.theme="default",this.bunkers="",this.startScreen=CURRENT_MODULE.WELCOME,this.authMethods=[],this.hasExtension=!1,this.hasOTP=!1,this.isLoading=!1,this.isLoadingExtension=!1,this.isOTP=!1,this.authUrl="",this.iframeUrl="",this.error="",this.localSignup=!1,this.accounts=[],this.recents=[],this.darkMode=!1,this.welcomeTitle="",this.welcomeDescription="",this.connectionString="",this.connectionStringServices=[]}watchLocalSignupHandler(o){state.localSignup=o}watchLoadingHandler(o){state.isLoading=o}watchLoadingExtensionHandler(o){state.isLoadingExtension=o}watchOTPHandler(o){state.isOTP=o}watchAuthUrlHandler(o){state.authUrl=o}watchIframeUrlHandler(o){state.iframeUrl=o}watchErrorHandler(o){state.error=o}handleClose(){this.nlCloseModal.emit()}handleChangeDarkMode(){this.nlChangeDarkMode.emit(!this.darkMode)}componentWillLoad(){state.path=[this.startScreen],state.localSignup=this.localSignup,state.error="",state.iframeUrl="",state.authUrl="",state.isLoading=!1,state.isLoadingExtension=!1,state.isOTP=!1,console.log("path",state.path)}handleClickToBack(){state.path.pop(),state.path=[...state.path],state.isLoading=!1,state.isLoadingExtension=!1,state.authUrl="",state.isOTP=!1}switchSignSignUpStrategy(o){state.path=CURRENT_MODULE.LOCAL_SIGNUP!==o?[CURRENT_MODULE.WELCOME,o]:[CURRENT_MODULE.WELCOME,CURRENT_MODULE.WELCOME_SIGNUP,o]}render(){const o="w-full h-full fixed top-0 start-0 z-[80] overflow-x-hidden overflow-y-auto flex items-center "+(this.darkMode?"dark":""),s=state.path.at(-1),r=state.isOTP||s!==CURRENT_MODULE.INFO&&s!==CURRENT_MODULE.CONFIRM_LOGOUT&&s!==CURRENT_MODULE.IMPORT_FLOW&&s!==CURRENT_MODULE.WELCOME&&s!==CURRENT_MODULE.EXTENSION&&s!==CURRENT_MODULE.IFRAME&&s!==CURRENT_MODULE.PREVIOUSLY_LOGGED,i=s!==CURRENT_MODULE.IFRAME&&(!this.authMethods.length||!this.localSignup&&this.authMethods.includes("connect")||this.localSignup&&this.authMethods.includes("local"));return h("div",{class:`theme-${this.theme}`},h("div",{class:o},h("div",{onClick:()=>this.handleClose(),class:"absolute top-0 left-0 w-full h-full bg-gray-500 bg-opacity-75 z-[80]"}),h("div",{class:"nl-bg relative z-[81] w-full flex flex-col rounded-xl sm:max-w-lg sm:w-full sm:mx-auto"},h("div",{class:"flex justify-between items-center py-3 px-4"},h("div",{class:"flex gap-2 items-center"},h("svg",{class:"w-7 h-7",width:"225",height:"224",viewBox:"0 0 225 224",fill:"none",xmlns:"http://www.w3.org/2000/svg"},h("rect",{width:"224.047",height:"224",rx:"64",fill:"#6951FA"}),h("path",{d:"M162.441 135.941V88.0593C170.359 85.1674 176 77.5348 176 68.6696C176 57.2919 166.708 48 155.33 48C143.953 48 134.661 57.2444 134.661 68.6696C134.661 77.5822 140.302 85.1674 148.219 88.0593V135.941C147.698 136.13 147.176 136.367 146.655 136.604L87.3956 77.3452C88.6282 74.6904 89.2919 71.7511 89.2919 68.6696C89.2919 57.2444 80.0474 48 68.6696 48C57.2919 48 48 57.2444 48 68.6696C48 77.5822 53.6415 85.1674 61.5585 88.0593V135.941C53.6415 138.833 48 146.465 48 155.33C48 166.708 57.2444 176 68.6696 176C80.0948 176 89.3393 166.708 89.3393 155.33C89.3393 146.418 83.6978 138.833 75.7807 135.941V88.0593C76.3022 87.8696 76.8237 87.6326 77.3452 87.3956L136.604 146.655C135.372 149.31 134.708 152.249 134.708 155.33C134.708 166.708 143.953 176 155.378 176C166.803 176 176.047 166.708 176.047 155.33C176.047 146.418 170.406 138.833 162.489 135.941H162.441Z",fill:"white"})),h("p",{class:"font-bold nl-logo text-base"},"Nostr ",h("span",{class:"font-light"},"Login"))),h("div",{class:"flex gap-1"},h("button",{onClick:()=>this.handleChangeDarkMode(),type:"button",class:"nl-action-button flex justify-center items-center w-7 h-7 text-sm font-semibold rounded-full border border-transparent"},h("span",{class:"sr-only"},"Change theme"),h("svg",{xmlns:"http://www.w3.org/2000/svg",fill:"none",viewBox:"0 0 24 24","stroke-width":"1.5",stroke:"currentColor",class:"flex-shrink-0 w-5 h-5"},h("path",this.darkMode?{"stroke-linecap":"round","stroke-linejoin":"round",d:"M12 3v2.25m6.364.386-1.591 1.591M21 12h-2.25m-.386 6.364-1.591-1.591M12 18.75V21m-4.773-4.227-1.591 1.591M5.25 12H3m4.227-4.773L5.636 5.636M15.75 12a3.75 3.75 0 1 1-7.5 0 3.75 3.75 0 0 1 7.5 0Z"}:{"stroke-linecap":"round","stroke-linejoin":"round",d:"M21.752 15.002A9.72 9.72 0 0 1 18 15.75c-5.385 0-9.75-4.365-9.75-9.75 0-1.33.266-2.597.748-3.752A9.753 9.753 0 0 0 3 11.25C3 16.635 7.365 21 12.75 21a9.753 9.753 0 0 0 9.002-5.998Z"}))),!state.isLoading&&h("button",{onClick:()=>state.path=[...state.path,CURRENT_MODULE.INFO],type:"button",class:"nl-action-button flex justify-center items-center w-7 h-7 text-sm font-semibold rounded-full border border-transparent"},h("span",{class:"sr-only"},"Info"),h("svg",{xmlns:"http://www.w3.org/2000/svg",fill:"none",viewBox:"0 0 24 24","stroke-width":"1.5",stroke:"currentColor",class:"flex-shrink-0 w-5 h-5"},h("path",{"stroke-linecap":"round","stroke-linejoin":"round",d:"m11.25 11.25.041-.02a.75.75 0 0 1 1.063.852l-.708 2.836a.75.75 0 0 0 1.063.853l.041-.021M21 12a9 9 0 1 1-18 0 9 9 0 0 1 18 0Zm-9-3.75h.008v.008H12V8.25Z"}))),h("button",{onClick:()=>this.handleClose(),type:"button",class:"nl-action-button flex justify-center items-center w-7 h-7 text-sm font-semibold rounded-full border border-transparent"},h("span",{class:"sr-only"},"Close"),h("svg",{class:"flex-shrink-0 w-5 h-5",xmlns:"http://www.w3.org/2000/svg",width:"24",height:"24",viewBox:"0 0 24 24",fill:"none",stroke:"currentColor","stroke-width":"2","stroke-linecap":"round","stroke-linejoin":"round"},h("path",{d:"M18 6 6 18"}),h("path",{d:"m6 6 12 12"}))))),state.path.length>1&&!state.isLoading&&h("div",{class:"p-4"},h("button",{onClick:()=>this.handleClickToBack(),type:"button",class:"nl-action-button flex justify-center items-center w-7 h-7 text-sm font-semibold rounded-full border border-transparent dark:focus:outline-none dark:focus:ring-1 dark:focus:ring-gray-600","data-hs-overlay":"#hs-vertically-centered-modal"},h("span",{class:"sr-only"},"Back"),h("svg",{xmlns:"http://www.w3.org/2000/svg",fill:"none",viewBox:"0 0 24 24","stroke-width":"1.5",stroke:"currentColor",class:"flex-shrink-0 w-5 h-5"},h("path",{"stroke-linecap":"round","stroke-linejoin":"round",d:"M10.5 19.5 3 12m0 0 7.5-7.5M3 12h18"})))),state.isLoading||state.authUrl?h("nl-loading",{path:s}):h(Fragment,null,(()=>{if(state.isOTP)return h("nl-signin-otp",null);switch(s){case CURRENT_MODULE.WELCOME:return h("nl-welcome",{titleWelcome:this.welcomeTitle||void 0,description:this.welcomeDescription||void 0});case CURRENT_MODULE.LOGIN:return h("nl-signin",null);case CURRENT_MODULE.SIGNUP:return h("nl-signup",{bunkers:this.bunkers});case CURRENT_MODULE.LOCAL_SIGNUP:return h("nl-local-signup",null);case CURRENT_MODULE.CONFIRM_LOGOUT:return h("nl-confirm-logout",null);case CURRENT_MODULE.IMPORT_FLOW:return h("nl-import-flow",{services:this.connectionStringServices});case CURRENT_MODULE.IMPORT_OTP:return h("nl-otp-migrate",{services:this.connectionStringServices});case CURRENT_MODULE.INFO:return h("nl-info",null);case CURRENT_MODULE.EXTENSION:return h("nl-info-extension",null);case CURRENT_MODULE.LOGIN_READ_ONLY:return h("nl-signin-read-only",null);case CURRENT_MODULE.LOGIN_BUNKER_URL:return h("nl-signin-bunker-url",null);case CURRENT_MODULE.LOGIN_OTP:return h("nl-signin-otp",null);case CURRENT_MODULE.WELCOME_LOGIN:return h("nl-welcome-signin",{hasOTP:this.hasOTP,authMethods:this.authMethods,hasExtension:this.hasExtension});case CURRENT_MODULE.WELCOME_SIGNUP:return h("nl-welcome-signup",null);case CURRENT_MODULE.CONNECTION_STRING:return h("nl-signin-connection-string",{connectionString:this.connectionString});case CURRENT_MODULE.CONNECT:return h("nl-connect",{connectionStringServices:this.connectionStringServices,authMethods:this.authMethods});case CURRENT_MODULE.PREVIOUSLY_LOGGED:return h("nl-previously-logged",{accounts:this.accounts,recents:this.recents});case CURRENT_MODULE.IFRAME:return h("nl-iframe",{iframeUrl:this.authUrl});default:return h("nl-welcome",null)}})(),r&&h(Fragment,null,s===CURRENT_MODULE.WELCOME_SIGNUP||s===CURRENT_MODULE.SIGNUP||s===CURRENT_MODULE.LOCAL_SIGNUP?h("div",{class:"p-4 overflow-y-auto"},h("p",{class:"nl-footer font-light text-center text-sm pt-3 max-w-96 mx-auto"},"If you already have a profile please"," ",h("span",{onClick:()=>this.switchSignSignUpStrategy(CURRENT_MODULE.WELCOME_LOGIN),class:"cursor-pointer text-blue-400"},"log in"),".")):i&&h("div",{class:"p-4 overflow-y-auto"},h("p",{class:"nl-footer font-light text-center text-sm pt-3 max-w-96 mx-auto"},"If you don't have a profile please"," ",h("span",{onClick:()=>this.switchSignSignUpStrategy(this.localSignup?CURRENT_MODULE.LOCAL_SIGNUP:CURRENT_MODULE.WELCOME_SIGNUP),class:"cursor-pointer text-blue-400"},"sign up"),".")))))))}static get watchers(){return{localSignup:["watchLocalSignupHandler"],isLoading:["watchLoadingHandler"],isLoadingExtension:["watchLoadingExtensionHandler"],isOTP:["watchOTPHandler"],authUrl:["watchAuthUrlHandler"],iframeUrl:["watchIframeUrlHandler"],error:["watchErrorHandler"]}}static get style(){return NlAuthStyle0}},[1,"nl-auth",{theme:[1025],bunkers:[1],startScreen:[1,"start-screen"],authMethods:[16],hasExtension:[4,"has-extension"],hasOTP:[4,"has-o-t-p"],isLoading:[4,"is-loading"],isLoadingExtension:[4,"is-loading-extension"],isOTP:[4,"is-o-t-p"],authUrl:[1,"auth-url"],iframeUrl:[1,"iframe-url"],error:[1],localSignup:[4,"local-signup"],accounts:[1040],recents:[1040],darkMode:[1028,"dark-mode"],welcomeTitle:[1,"welcome-title"],welcomeDescription:[1,"welcome-description"],connectionString:[1,"connection-string"],connectionStringServices:[16]},void 0,{localSignup:["watchLocalSignupHandler"],isLoading:["watchLoadingHandler"],isLoadingExtension:["watchLoadingExtensionHandler"],isOTP:["watchOTPHandler"],authUrl:["watchAuthUrlHandler"],iframeUrl:["watchIframeUrlHandler"],error:["watchErrorHandler"]}]);function defineCustomElement$4(){typeof customElements>"u"||["nl-auth","button-base","nl-confirm-logout","nl-connect","nl-iframe","nl-import-flow","nl-info","nl-info-extension","nl-loading","nl-local-signup","nl-login-status","nl-otp-migrate","nl-previously-logged","nl-select","nl-signin","nl-signin-bunker-url","nl-signin-connection-string","nl-signin-otp","nl-signin-read-only","nl-signup","nl-welcome","nl-welcome-signin","nl-welcome-signup"].forEach(o=>{switch(o){case"nl-auth":customElements.get(o)||customElements.define(o,NlAuth);break;case"button-base":customElements.get(o)||defineCustomElement$q();break;case"nl-confirm-logout":customElements.get(o)||defineCustomElement$p();break;case"nl-connect":customElements.get(o)||defineCustomElement$o();break;case"nl-iframe":customElements.get(o)||defineCustomElement$n();break;case"nl-import-flow":customElements.get(o)||defineCustomElement$l();break;case"nl-info":customElements.get(o)||defineCustomElement$k();break;case"nl-info-extension":customElements.get(o)||defineCustomElement$j();break;case"nl-loading":customElements.get(o)||defineCustomElement$i();break;case"nl-local-signup":customElements.get(o)||defineCustomElement$h();break;case"nl-login-status":customElements.get(o)||defineCustomElement$g();break;case"nl-otp-migrate":customElements.get(o)||defineCustomElement$f();break;case"nl-previously-logged":customElements.get(o)||defineCustomElement$e();break;case"nl-select":customElements.get(o)||defineCustomElement$m();break;case"nl-signin":customElements.get(o)||defineCustomElement$d();break;case"nl-signin-bunker-url":customElements.get(o)||defineCustomElement$c();break;case"nl-signin-connection-string":customElements.get(o)||defineCustomElement$b();break;case"nl-signin-otp":customElements.get(o)||defineCustomElement$a();break;case"nl-signin-read-only":customElements.get(o)||defineCustomElement$9();break;case"nl-signup":customElements.get(o)||defineCustomElement$8();break;case"nl-welcome":customElements.get(o)||defineCustomElement$7();break;case"nl-welcome-signin":customElements.get(o)||defineCustomElement$6();break;case"nl-welcome-signup":customElements.get(o)||defineCustomElement$5()}})}defineCustomElement$4();const NlButton=proxyCustomElement(class extends H{constructor(){super(),this.__registerHost(),this.__attachShadow(),this.theme="default",this.darkMode=!1,this.titleBtn="Open modal",this.disabled=!1}render(){return h("button-base",{key:"9f7936090efc7263cce71d1ad89490d7f5445991",theme:this.theme,darkMode:this.darkMode,titleBtn:this.titleBtn,disabled:this.disabled})}},[1,"nl-button",{theme:[1],darkMode:[4,"dark-mode"],titleBtn:[1,"title-btn"],disabled:[4]}]);function defineCustomElement$3(){typeof customElements>"u"||["nl-button","button-base"].forEach(o=>{switch(o){case"nl-button":customElements.get(o)||customElements.define(o,NlButton);break;case"button-base":customElements.get(o)||defineCustomElement$q()}})}defineCustomElement$3();const nlChangeAccountCss=baseCss,NlChangeAccountStyle0=nlChangeAccountCss,NLChangeAccount=proxyCustomElement(class extends H{constructor(){super(),this.__registerHost(),this.handleOpenWelcomeModal=createEvent(this,"handleOpenWelcomeModal",7),this.handleSwitchAccount=createEvent(this,"handleSwitchAccount",7),this.isOpen=!1,this.options=[],this.accounts=[],this.currentAccount=null,this.mode=!1,this.darkMode=!1,this.themeState="default",this.theme="default"}handleWindowClick(){this.wrapperRef.querySelector(".listClass")&&(this.isOpen=!1)}toggleDropdown(){this.isOpen=!this.isOpen,this.calculateDropdownPosition()}watchPropHandler(o){this.themeState=o}watchModeHandler(o){this.mode=o}watchAccountsHandler(o){this.options=o}connectedCallback(){this.themeState=this.theme,this.mode=this.darkMode}calculateDropdownPosition(){if(this.isOpen&&this.buttonRef){const o=this.buttonRef.getBoundingClientRect();this.ulRef.style.top=`${o.height}px`}}handleChange(o){this.handleSwitchAccount.emit(o)}handleOpenModal(){this.handleOpenWelcomeModal.emit()}render(){const o=(this.isOpen?"listClass flex flex-col gap-2":"hidden")+" w-full nl-select-list absolute z-10 left-0 shadow-md rounded-lg p-2 mt-1 after:h-4 after:absolute after:-bottom-4 after:start-0 after:w-full before:h-4 before:absolute before:-top-4 before:start-0 before:w-full",s=(this.isOpen?"rotate-180":"rotate-0")+" duration-300 flex-shrink-0 w-4 h-4 text-gray-500",r=this.options&&this.currentAccount?this.options.filter(i=>i.pubkey!==this.currentAccount.pubkey||i.authMethod!==this.currentAccount.authMethod):[];return h("div",{key:"4e15e39f7ac6a552bfc772396e3e9ef8eeca95cc",class:`theme-${this.themeState}`},h("div",{key:"eae10769ce35dc4cc072d2361c1ee1390c79c822",class:"relative",ref:i=>this.wrapperRef=i},h("button",{key:"e585a44168809f27b99201f7e13bd5db5e4f6569",ref:i=>this.buttonRef=i,onClick:()=>this.toggleDropdown(),type:"button",class:"nl-select peer py-3 px-4 flex items-center w-full justify-between border-transparent rounded-lg text-sm disabled:opacity-50 disabled:pointer-events-none dark:border-transparent"},h("span",{key:"006ed9a67b57227d4dab51f0b6bcb8290cd9d3ac",class:"text-gray-500"},"Switch profile"),h("svg",{key:"5f824a479165929698fab31b8837b89418587652",class:s,xmlns:"http://www.w3.org/2000/svg",width:"24",height:"24",viewBox:"0 0 24 24",fill:"none",stroke:"currentColor","stroke-width":"2","stroke-linecap":"round","stroke-linejoin":"round"},h("path",{key:"600914907723c9f8d01a15da357ccb825c1d1e6a",d:"m6 9 6 6 6-6"}))),h("ul",{key:"9b5b68724a3bce995e6b8b0a9d0eb653baedf79a",ref:i=>this.ulRef=i,class:o},this.options&&r.map(i=>{const c=i.name||i.nip05||i.pubkey;return h("li",{onClick:()=>this.handleChange(i),class:"nl-select-option flex cursor-pointer items-center gap-x-3.5 py-2 px-3 rounded-lg text-sm"},h("div",{class:"uppercase font-bold w-full max-w-6 h-6 rounded-full border border-gray-400 flex justify-center items-center"},i?.picture?h("img",{class:"w-full rounded-full",src:i.picture,alt:"Logo"}):c?c[0]:h("svg",{xmlns:"http://www.w3.org/2000/svg",fill:"none",viewBox:"0 0 24 24","stroke-width":"1.5",stroke:"currentColor",class:"w-full"},h("path",{"stroke-linecap":"round","stroke-linejoin":"round",d:"M17.982 18.725A7.488 7.488 0 0 0 12 15.75a7.488 7.488 0 0 0-5.982 2.975m11.963 0a9 9 0 1 0-11.963 0m11.963 0A8.966 8.966 0 0 1 12 21a8.966 8.966 0 0 1-5.982-2.275M15 9.75a3 3 0 1 1-6 0 3 3 0 0 1 6 0Z"}))),h("div",{class:"overflow-hidden flex flex-col w-full"},h("div",{class:"truncate overflow-hidden"},c),h("nl-login-status",{info:i})))}),h("li",{key:"936f2b75ca2dfca3483650d5d62fc50182cfc8f2",class:"first:pt-0 pt-2 border-t-[1px] first:border-none border-gray-300"},h("div",{key:"be0b4f29e70d8e2bc9fd1cc04c0fb43ad3dd5cac",onClick:()=>this.handleOpenModal(),class:"nl-select-option flex cursor-pointer items-center gap-x-3.5 py-2 px-3 rounded-lg text-sm"},h("div",{key:"bdd2a67e5763726666fcea91b0e7de67fe855994",class:"uppercase font-bold w-6 h-6 rounded-full border border-gray-400 flex justify-center items-center"},h("svg",{key:"f3a258f3e510ccb83b95bf3abecf65c248c8b0f1",xmlns:"http://www.w3.org/2000/svg",fill:"none",viewBox:"0 0 24 24","stroke-width":"1.5",stroke:"currentColor",class:"w-4 h-4"},h("path",{key:"dafaa898f3e042531a923a9a77b94511895c6102","stroke-linecap":"round","stroke-linejoin":"round",d:"M12 4.5v15m7.5-7.5h-15"}))),"Add profile")))))}get element(){return this}static get watchers(){return{theme:["watchPropHandler"],darkMode:["watchModeHandler"],accounts:["watchAccountsHandler"]}}static get style(){return NlChangeAccountStyle0}},[0,"nl-change-account",{accounts:[16],currentAccount:[16],darkMode:[4,"dark-mode"],theme:[1],isOpen:[32],options:[32],mode:[32],themeState:[32]},[[8,"click","handleWindowClick"]],{theme:["watchPropHandler"],darkMode:["watchModeHandler"],accounts:["watchAccountsHandler"]}]);function defineCustomElement$2(){typeof customElements>"u"||["nl-change-account","nl-login-status"].forEach(o=>{switch(o){case"nl-change-account":customElements.get(o)||customElements.define(o,NLChangeAccount);break;case"nl-login-status":customElements.get(o)||defineCustomElement$g()}})}defineCustomElement$2();const nlDialogCss=baseCss,NlDialogStyle0=nlDialogCss,NlDialog=proxyCustomElement(class extends H{constructor(){super(),this.__registerHost(),this.__attachShadow()}componentDidLoad(){var o;null===(o=this.dialogElement)||void 0===o||o.showModal()}disconnectedCallback(){var o;null===(o=this.dialogElement)||void 0===o||o.close()}render(){return h("dialog",{key:"9c20328d937c160bcb9b9bf731d744721e84f189",ref:o=>this.dialogElement=o,class:"m-auto nl-banner-dialog"},h("slot",{key:"2e047d7c9e8904d590c588b73a5480cb1605ff86"}))}static get style(){return NlDialogStyle0}},[1,"nl-dialog"]);function defineCustomElement$1(){typeof customElements>"u"||["nl-dialog"].forEach(o=>{"nl-dialog"===o&&(customElements.get(o)||customElements.define(o,NlDialog))})}defineCustomElement$1();const nlBannerCss=baseCss,NlBannerStyle0=nlBannerCss,NlBanner=proxyCustomElement(class extends H{constructor(){super(),this.__registerHost(),this.__attachShadow(),this.handleNotifyConfirmBanner=createEvent(this,"handleNotifyConfirmBanner",7),this.handleNotifyConfirmBannerIframe=createEvent(this,"handleNotifyConfirmBannerIframe",7),this.handleLoginBanner=createEvent(this,"handleLoginBanner",7),this.handleLogoutBanner=createEvent(this,"handleLogoutBanner",7),this.handleOpenWelcomeModal=createEvent(this,"handleOpenWelcomeModal",7),this.handleConfirmLogout=createEvent(this,"handleConfirmLogout",7),this.handleImportModal=createEvent(this,"handleImportModal",7),this.theme="default",this.darkMode=!1,this.hiddenMode=!1,this.titleBanner="",this.isOpen=!1,this.isLoading=!1,this.notify=null,this.userInfo=null,this.accounts=[],this.isUserImgError=!1,this.domain="",this.mode="",this.url="",this.isOpenConfirm=!1}watchNotifyHandler(o){var s,r,i,a;this.isOpen=!0,this.isOpenConfirm=!0,this.domain=(null===(s=this.userInfo)||void 0===s?void 0:s.domain)||(null===(a=null===(i=null===(r=this.userInfo)||void 0===r?void 0:r.nip05)||void 0===i?void 0:i.split("@"))||void 0===a?void 0:a[1])||"",this.mode=o.mode,this.url=o.url,this.mode||(this.isOpenConfirm=!1,this.isOpen=!1)}handleOpen(){this.userInfo?this.isOpen=!0:this.handleOpenWelcomeModal.emit()}handleClose(){this.isOpen=!1}handleLogin(){this.handleLoginBanner.emit(METHOD_MODULE.LOGIN),this.handleClose()}handleSignup(){this.handleLoginBanner.emit(METHOD_MODULE.SIGNUP),this.handleClose()}handleImport(){this.handleImportModal.emit(),this.handleClose()}handleLogout(){if(localStorage.getItem("backupKey"))return this.handleLogoutBanner.emit(METHOD_MODULE.LOGOUT),this.handleClose(),void localStorage.removeItem("backupKey");"local"===this.userInfo.authMethod?this.handleConfirmLogout.emit():this.handleLogoutBanner.emit(METHOD_MODULE.LOGOUT),this.handleClose()}handleConfirm(){switch(this.mode){case"authUrl":this.handleNotifyConfirmBanner.emit(this.url);break;case"iframeAuthUrl":this.handleNotifyConfirmBannerIframe.emit(this.url)}this.handleClose()}render(){var o,s,r,i,a,c;const y=!(null===(o=this.userInfo)||void 0===o||!o.picture),w=(null===(s=this.userInfo)||void 0===s?void 0:s.name)||(null===(a=null===(i=null===(r=this.userInfo)||void 0===r?void 0:r.nip05)||void 0===i?void 0:i.split("@"))||void 0===a?void 0:a[0])||(null===(c=this.userInfo)||void 0===c?void 0:c.pubkey)||"",C=!!w,T=this.userInfo&&"local"===this.userInfo.authMethod,S=localStorage.getItem("backupKey"),M=h("svg",{xmlns:"http://www.w3.org/2000/svg",fill:"none",viewBox:"0 0 24 24","stroke-width":"1.5",stroke:"currentColor",class:"w-full"},h("path",{"stroke-linecap":"round","stroke-linejoin":"round",d:"M17.982 18.725A7.488 7.488 0 0 0 12 15.75a7.488 7.488 0 0 0-5.982 2.975m11.963 0a9 9 0 1 0-11.963 0m11.963 0A8.966 8.966 0 0 1 12 21a8.966 8.966 0 0 1-5.982-2.275M15 9.75a3 3 0 1 1-6 0 3 3 0 0 1 6 0Z"})),O=h(Fragment,null,h("div",{class:"block w-[48px] h-[46px] relative z-10"},h("div",{onClick:()=>this.handleOpen(),class:"flex w-52 h-[46px] items-center pl-[11px]"},h("span",{class:(this.isLoading?"w-5 h-5 border-[2px] mr-3.5 ml-[2px] opacity-1":"w-0 h-0 border-[0px] mr-0 opacity-0 ml-0")+" animate-spin transition-all duration-300 ease-in-out inline-block border-current border-t-transparent text-slate-900 dark:text-gray-300 rounded-full",role:"status","aria-label":"loading"}),this.userInfo?h("div",{class:"uppercase font-bold w-6 h-6 mr-2 rounded-full border border-gray-200 flex justify-center items-center"},y?this.isUserImgError?M:h("img",{class:"w-full rounded-full",src:this.userInfo.picture,alt:"Logo",onError:()=>this.isUserImgError=!0}):C?w[0]:M):h("div",{class:"flex justify-center items-center"},h("svg",{class:"w-6 h-6",width:"225",height:"224",viewBox:"0 0 225 224",fill:"none",xmlns:"http://www.w3.org/2000/svg"},h("rect",{width:"224.047",height:"224",rx:"64",fill:"#6951FA"}),h("path",{d:"M162.441 135.941V88.0593C170.359 85.1674 176 77.5348 176 68.6696C176 57.2919 166.708 48 155.33 48C143.953 48 134.661 57.2444 134.661 68.6696C134.661 77.5822 140.302 85.1674 148.219 88.0593V135.941C147.698 136.13 147.176 136.367 146.655 136.604L87.3956 77.3452C88.6282 74.6904 89.2919 71.7511 89.2919 68.6696C89.2919 57.2444 80.0474 48 68.6696 48C57.2919 48 48 57.2444 48 68.6696C48 77.5822 53.6415 85.1674 61.5585 88.0593V135.941C53.6415 138.833 48 146.465 48 155.33C48 166.708 57.2444 176 68.6696 176C80.0948 176 89.3393 166.708 89.3393 155.33C89.3393 146.418 83.6978 138.833 75.7807 135.941V88.0593C76.3022 87.8696 76.8237 87.6326 77.3452 87.3956L136.604 146.655C135.372 149.31 134.708 152.249 134.708 155.33C134.708 166.708 143.953 176 155.378 176C166.803 176 176.047 166.708 176.047 155.33C176.047 146.418 170.406 138.833 162.489 135.941H162.441Z",fill:"white"})),this.isOpen&&h("span",{class:"px-2"},h("b",null,"Nostr")," Login")),this.isOpen&&C&&h("div",{class:"show-slow truncate w-16 text-xs"},w),this.isOpen&&C&&h("nl-login-status",{info:this.userInfo}))),h("button",{onClick:()=>this.handleClose(),type:"button",class:(this.isOpen?"z-20":"z-0")+" nl-action-button absolute right-2 top-2 z-0 show-slow grid place-items-center w-7 h-7 text-sm font-semibold rounded-full border border-transparent"},h("span",{class:"sr-only"},"Close"),h("svg",{class:"flex-shrink-0 w-5 h-5",xmlns:"http://www.w3.org/2000/svg",width:"24",height:"24",viewBox:"0 0 24 24",fill:"none",stroke:"currentColor","stroke-width":"2","stroke-linecap":"round","stroke-linejoin":"round"},h("path",{d:"M18 6 6 18"}),h("path",{d:"m6 6 12 12"}))),h("div",{class:"p-3 show-slow"},this.isOpenConfirm?h("div",null,h("div",{class:"w-8 h-8 p-1/2 rounded-full border border-gray-200 bg-white mb-2 mt-2 show-slow m-auto"},h("svg",{xmlns:"http://www.w3.org/2000/svg",fill:"none",viewBox:"0 0 24 24","stroke-width":"1.5",stroke:"#5a68ff",class:"w-full"},h("path",{"stroke-linecap":"round","stroke-linejoin":"round",d:"m11.25 11.25.041-.02a.75.75 0 0 1 1.063.852l-.708 2.836a.75.75 0 0 0 1.063.853l.041-.021M21 12a9 9 0 1 1-18 0 9 9 0 0 1 18 0Zm-9-3.75h.008v.008H12V8.25Z"}))),h("p",{class:"mb-2 text-center max-w-40 min-w-40 mx-auto"},"timeout"===this.mode?"Keys not responding, check your key storage app":`Confirmation required at ${this.domain}`),"timeout"===this.mode?h("a",{onClick:()=>this.handleClose(),href:`https://${this.domain}`,target:"_blank",class:"nl-button text-nowrap py-2.5 px-3 w-full inline-flex justify-center items-center gap-x-2 text-sm font-medium rounded-lg disabled:opacity-50 disabled:pointer-events-none dark:focus:outline-none dark:focus:ring-1 dark:focus:ring-gray-600"},"Go to ",this.domain):"rebind"===this.mode?h("iframe",{src:this.url,width:"180",height:"80"}):h("button-base",{onClick:()=>this.handleConfirm(),titleBtn:"Confirm"})):h("div",null,h("div",null,this.titleBanner&&h("p",{class:"mb-2 text-center show-slow max-w-40 min-w-40 mx-auto"},this.titleBanner),T&&h(Fragment,null,!S&&h("p",{class:"mb-2 text-center show-slow text-red-400 max-w-40 min-w-40 mx-auto"},"Your profile may be lost if you close this tab"),h("div",{class:"mb-2"},h("button-base",{onClick:()=>this.handleImport(),theme:"lemonade",titleBtn:"Back up profile"}))),h("div",{class:"mb-2"},h("nl-change-account",{currentAccount:this.userInfo,accounts:this.accounts})),this.userInfo?h("button-base",{onClick:()=>this.handleLogout(),titleBtn:"Log out"}):h("div",null,h("button-base",{onClick:()=>this.handleLogin(),titleBtn:"Log in"},h("svg",{style:{display:"none"},slot:"icon-start",xmlns:"http://www.w3.org/2000/svg",fill:"none",viewBox:"0 0 24 24","stroke-width":"1.5",stroke:"currentColor",class:"flex-shrink-0 w-4 h-4"},h("path",{"stroke-linecap":"round","stroke-linejoin":"round",d:"M15.75 5.25a3 3 0 0 1 3 3m3 0a6 6 0 0 1-7.029 5.912c-.563-.097-1.159.026-1.563.43L10.5 17.25H8.25v2.25H6v2.25H2.25v-2.818c0-.597.237-1.17.659-1.591l6.499-6.499c.404-.404.527-1 .43-1.563A6 6 0 1 1 21.75 8.25Z"}))),h("button-base",{onClick:()=>this.handleSignup(),titleBtn:"Sign up"},h("svg",{style:{display:"none"},slot:"icon-start",xmlns:"http://www.w3.org/2000/svg",fill:"none",viewBox:"0 0 24 24","stroke-width":"1.5",stroke:"currentColor",class:"flex-shrink-0 w-4 h-4"},h("path",{"stroke-linecap":"round","stroke-linejoin":"round",d:"M18 7.5v3m0 0v3m0-3h3m-3 0h-3m-2.25-4.125a3.375 3.375 0 1 1-6.75 0 3.375 3.375 0 0 1 6.75 0ZM3 19.235v-.11a6.375 6.375 0 0 1 12.75 0v.109A12.318 12.318 0 0 1 9.374 21c-2.331 0-4.512-.645-6.374-1.766Z"})))))))),Z=!!function q(re,pe){pe=pe||document.body;const se=Array.from(pe.querySelectorAll(re)),ae=function(me){q(re,me).forEach(be=>{se.includes(be)||se.push(be)})};pe.shadowRoot&&ae(pe.shadowRoot);for(const me of Array.from(pe.querySelectorAll("*")))me.shadowRoot&&ae(me.shadowRoot);return se}("dialog").find(q=>q.open&&!q.classList.contains("nl-banner-dialog"));return console.log("nostr-login need dialog",Z),h("div",{class:`theme-${this.theme} ${!this.isOpen&&this.hiddenMode?"hidden":""}`},h("div",{class:this.darkMode&&"dark"},this.isOpenConfirm&&Z?h("nl-dialog",null,h("div",{class:`nl-banner ${this.isOpen?"w-52 h-auto right-2 rounded-r-lg isOpen":"rounded-r-none hover:rounded-r-lg cursor-pointer"} z-50 w-12 h-12 fixed top-52 right-0 inline-block gap-x-2 text-sm font-medium rounded-lg hover:right-2 transition-all duration-300 ease-in-out`},O)):h("div",{class:`nl-banner ${this.isOpen?"w-52 h-auto right-2 rounded-r-lg isOpen":"rounded-r-none hover:rounded-r-lg cursor-pointer"} z-50 w-12 h-12 fixed top-52 right-0 inline-block gap-x-2 text-sm font-medium rounded-lg hover:right-2 transition-all duration-300 ease-in-out`},O)))}static get watchers(){return{notify:["watchNotifyHandler"]}}static get style(){return NlBannerStyle0}},[1,"nl-banner",{theme:[1025],darkMode:[1028,"dark-mode"],hiddenMode:[1028,"hidden-mode"],titleBanner:[1,"title-banner"],isOpen:[1028,"is-open"],isLoading:[4,"is-loading"],notify:[16],userInfo:[16],accounts:[1040],isUserImgError:[32],domain:[32],mode:[32],url:[32],isOpenConfirm:[32]},void 0,{notify:["watchNotifyHandler"]}]);function defineCustomElement(){typeof customElements>"u"||["nl-banner","button-base","nl-change-account","nl-dialog","nl-login-status"].forEach(o=>{switch(o){case"nl-banner":customElements.get(o)||customElements.define(o,NlBanner);break;case"button-base":customElements.get(o)||defineCustomElement$q();break;case"nl-change-account":customElements.get(o)||defineCustomElement$2();break;case"nl-dialog":customElements.get(o)||defineCustomElement$1();break;case"nl-login-status":customElements.get(o)||defineCustomElement$g()}})}defineCustomElement();var commonjsGlobal=typeof globalThis<"u"?globalThis:typeof window<"u"?window:typeof global<"u"?global:typeof self<"u"?self:{};function getDefaultExportFromCjs(o){return o&&o.__esModule&&Object.prototype.hasOwnProperty.call(o,"default")?o.default:o}var lib$1={},types={};Object.defineProperty(types,"__esModule",{value:!0});var ee={},taskCollection$1={},taskCollection={},bakeCollection={};(function(exports){Object.defineProperty(exports,"__esModule",{value:!0}),exports.bakeCollectionVariadic=exports.bakeCollectionAwait=exports.bakeCollection=exports.BAKED_EMPTY_FUNC=void 0,exports.BAKED_EMPTY_FUNC=function(){};var FORLOOP_FALLBACK=1500;function generateArgsDefCode(o){var s="";if(0===o)return s;for(var r=0;r1)s?((r=this._tasks).push.apply(r,arguments),this.length+=arguments.length):(this._tasks.push(o),this.length++);else if(s){var a;1===i?((a=Array(1+arguments.length)).push(a),a.push.apply(a,arguments),this._tasks=a):((a=Array(arguments.length)).push.apply(a,arguments),this._tasks=a),this.length+=arguments.length}else this._tasks=1===i?[this._tasks,o]:o,this.length++}function push_rebuild(o,s){var r,i=this.length;if(i>1)s?((r=this._tasks).push.apply(r,arguments),this.length+=arguments.length):(this._tasks.push(o),this.length++);else if(s){var a;1===i?((a=Array(1+arguments.length)).push(a),a.push.apply(a,arguments),this._tasks=a):((a=Array(arguments.length)).push.apply(a,arguments),this._tasks=a),this.length+=arguments.length}else this._tasks=1===i?[this._tasks,o]:o,this.length++;this.firstEmitBuildStrategy?this.call=rebuild_on_first_call:this.rebuild()}function _fast_remove_single(o,s){-1!==s&&(0===s?o.shift():s===o.length-1?o.length=o.length-1:o.splice(s,1))}function removeLast_norebuild(o){0!==this.length&&(1===this.length?this._tasks===o&&(this.length=0):(_fast_remove_single(this._tasks,this._tasks.lastIndexOf(o)),1===this._tasks.length?(this._tasks=this._tasks[0],this.length=1):this.length=this._tasks.length))}function removeLast_rebuild(o){if(0!==this.length){if(1===this.length)return this._tasks===o&&(this.length=0),this.firstEmitBuildStrategy?void(this.call=bake_collection_1.BAKED_EMPTY_FUNC):void this.rebuild();_fast_remove_single(this._tasks,this._tasks.lastIndexOf(o)),1===this._tasks.length?(this._tasks=this._tasks[0],this.length=1):this.length=this._tasks.length,this.firstEmitBuildStrategy?this.call=rebuild_on_first_call:this.rebuild()}}function insert_norebuild(o){for(var s,r=[],i=1;i0&&!s.includes(o.length))throw new Error(`Expected Uint8Array of length ${s}, not of length=${o.length}`)}function hash$3(o){if("function"!=typeof o||"function"!=typeof o.create)throw new Error("Hash should be wrapped by utils.wrapConstructor");number$3(o.outputLen),number$3(o.blockLen)}function exists$3(o,s=!0){if(o.destroyed)throw new Error("Hash instance has been destroyed");if(s&&o.finished)throw new Error("Hash#digest() has already been called")}function output$3(o,s){bytes$3(o);const r=s.outputLen;if(o.lengtho instanceof Uint8Array,createView$2=o=>new DataView(o.buffer,o.byteOffset,o.byteLength),rotr$2=(o,s)=>o<<32-s|o>>>s,isLE$3=68===new Uint8Array(new Uint32Array([287454020]).buffer)[0];if(!isLE$3)throw new Error("Non little-endian hardware is not supported");function utf8ToBytes$4(o){if("string"!=typeof o)throw new Error("utf8ToBytes expected string, got "+typeof o);return new Uint8Array((new TextEncoder).encode(o))}function toBytes$3(o){if("string"==typeof o&&(o=utf8ToBytes$4(o)),!u8a$3(o))throw new Error("expected Uint8Array, got "+typeof o);return o}function concatBytes$3(...o){const s=new Uint8Array(o.reduce((i,a)=>i+a.length,0));let r=0;return o.forEach(i=>{if(!u8a$3(i))throw new Error("Uint8Array expected");s.set(i,r),r+=i.length}),s}Array.from({length:256},(o,s)=>s.toString(16).padStart(2,"0"));let Hash$2=class{clone(){return this._cloneInto()}};function wrapConstructor$2(o){const s=i=>o().update(toBytes$3(i)).digest(),r=o();return s.outputLen=r.outputLen,s.blockLen=r.blockLen,s.create=()=>o(),s}function randomBytes$2(o=32){if(crypto$3&&"function"==typeof crypto$3.getRandomValues)return crypto$3.getRandomValues(new Uint8Array(o));throw new Error("crypto.getRandomValues must be defined")}function setBigUint64$2(o,s,r,i){if("function"==typeof o.setBigUint64)return o.setBigUint64(s,r,i);const a=BigInt(32),c=BigInt(4294967295),y=Number(r>>a&c),w=Number(r&c),T=i?0:4;o.setUint32(s+(i?4:0),y,i),o.setUint32(s+T,w,i)}let SHA2$2=class extends Hash$2{constructor(o,s,r,i){super(),this.blockLen=o,this.outputLen=s,this.padOffset=r,this.isLE=i,this.finished=!1,this.length=0,this.pos=0,this.destroyed=!1,this.buffer=new Uint8Array(o),this.view=createView$2(this.buffer)}update(o){assert$3.exists(this);const{view:s,buffer:r,blockLen:i}=this,a=(o=toBytes$3(o)).length;for(let c=0;ci-c&&(this.process(r,0),c=0);for(let S=c;ST.length)throw new Error("_sha2: outputLen bigger than state");for(let S=0;So&s^~o&r,Maj$2=(o,s,r)=>o&s^o&r^s&r,SHA256_K$2=new Uint32Array([1116352408,1899447441,3049323471,3921009573,961987163,1508970993,2453635748,2870763221,3624381080,310598401,607225278,1426881987,1925078388,2162078206,2614888103,3248222580,3835390401,4022224774,264347078,604807628,770255983,1249150122,1555081692,1996064986,2554220882,2821834349,2952996808,3210313671,3336571891,3584528711,113926993,338241895,666307205,773529912,1294757372,1396182291,1695183700,1986661051,2177026350,2456956037,2730485921,2820302411,3259730800,3345764771,3516065817,3600352804,4094571909,275423344,430227734,506948616,659060556,883997877,958139571,1322822218,1537002063,1747873779,1955562222,2024104815,2227730452,2361852424,2428436474,2756734187,3204031479,3329325298]),IV$2=new Uint32Array([1779033703,3144134277,1013904242,2773480762,1359893119,2600822924,528734635,1541459225]),SHA256_W$2=new Uint32Array(64);let SHA256$2=class extends SHA2$2{constructor(){super(64,32,8,!1),this.A=0|IV$2[0],this.B=0|IV$2[1],this.C=0|IV$2[2],this.D=0|IV$2[3],this.E=0|IV$2[4],this.F=0|IV$2[5],this.G=0|IV$2[6],this.H=0|IV$2[7]}get(){const{A:o,B:s,C:r,D:i,E:a,F:c,G:y,H:w}=this;return[o,s,r,i,a,c,y,w]}set(o,s,r,i,a,c,y,w){this.A=0|o,this.B=0|s,this.C=0|r,this.D=0|i,this.E=0|a,this.F=0|c,this.G=0|y,this.H=0|w}process(o,s){for(let S=0;S<16;S++,s+=4)SHA256_W$2[S]=o.getUint32(s,!1);for(let S=16;S<64;S++){const M=SHA256_W$2[S-15],O=SHA256_W$2[S-2],L=rotr$2(M,7)^rotr$2(M,18)^M>>>3,Z=rotr$2(O,17)^rotr$2(O,19)^O>>>10;SHA256_W$2[S]=Z+SHA256_W$2[S-7]+L+SHA256_W$2[S-16]|0}let{A:r,B:i,C:a,D:c,E:y,F:w,G:C,H:T}=this;for(let S=0;S<64;S++){const M=T+(rotr$2(y,6)^rotr$2(y,11)^rotr$2(y,25))+Chi$2(y,w,C)+SHA256_K$2[S]+SHA256_W$2[S]|0,O=(rotr$2(r,2)^rotr$2(r,13)^rotr$2(r,22))+Maj$2(r,i,a)|0;T=C,C=w,w=y,y=c+M|0,c=a,a=i,i=r,r=M+O|0}r=r+this.A|0,i=i+this.B|0,a=a+this.C|0,c=c+this.D|0,y=y+this.E|0,w=w+this.F|0,C=C+this.G|0,T=T+this.H|0,this.set(r,i,a,c,y,w,C,T)}roundClean(){SHA256_W$2.fill(0)}destroy(){this.set(0,0,0,0,0,0,0,0),this.buffer.fill(0)}},SHA224$1=class extends SHA256$2{constructor(){super(),this.A=-1056596264,this.B=914150663,this.C=812702999,this.D=-150054599,this.E=-4191439,this.F=1750603025,this.G=1694076839,this.H=-1090891868,this.outputLen=28}};const sha256$2=wrapConstructor$2(()=>new SHA256$2);wrapConstructor$2(()=>new SHA224$1);const _0n$4=BigInt(0),_1n$4=BigInt(1),_2n$2=BigInt(2),u8a$2=o=>o instanceof Uint8Array,hexes$2=Array.from({length:256},(o,s)=>s.toString(16).padStart(2,"0"));function bytesToHex$2(o){if(!u8a$2(o))throw new Error("Uint8Array expected");let s="";for(let r=0;ri+a.length,0));let r=0;return o.forEach(i=>{if(!u8a$2(i))throw new Error("Uint8Array expected");s.set(i,r),r+=i.length}),s}function equalBytes$1(o,s){if(o.length!==s.length)return!1;for(let r=0;r_0n$4;o>>=_1n$4,s+=1);return s}function bitGet(o,s){return o>>BigInt(s)&_1n$4}const bitSet=(o,s,r)=>o|(r?_1n$4:_0n$4)<(_2n$2<new Uint8Array(o),u8fr=o=>Uint8Array.from(o);function createHmacDrbg(o,s,r){if("number"!=typeof o||o<2)throw new Error("hashLen must be a number");if("number"!=typeof s||s<2)throw new Error("qByteLen must be a number");if("function"!=typeof r)throw new Error("hmacFn must be a function");let i=u8n(o),a=u8n(o),c=0;const y=()=>{i.fill(1),a.fill(0),c=0},w=(...S)=>r(a,i,...S),C=(S=u8n())=>{a=w(u8fr([0]),S),i=w(),0!==S.length&&(a=w(u8fr([1]),S),i=w())},T=()=>{if(c++>=1e3)throw new Error("drbg: tried 1000 values");let S=0;const M=[];for(;S{let O;for(y(),C(S);!(O=M(T()));)C();return y(),O}}const validatorFns={bigint:o=>"bigint"==typeof o,function:o=>"function"==typeof o,boolean:o=>"boolean"==typeof o,string:o=>"string"==typeof o,isSafeInteger:o=>Number.isSafeInteger(o),array:o=>Array.isArray(o),field:(o,s)=>s.Fp.isValid(o),hash:o=>"function"==typeof o&&Number.isSafeInteger(o.outputLen)};function validateObject(o,s,r={}){const i=(a,c,y)=>{const w=validatorFns[c];if("function"!=typeof w)throw new Error(`Invalid validator "${c}", expected function`);const C=o[a];if(!(y&&void 0===C||w(C,o)))throw new Error(`Invalid param ${String(a)}=${C} (${typeof C}), expected ${c}`)};for(const[a,c]of Object.entries(s))i(a,c,!1);for(const[a,c]of Object.entries(r))i(a,c,!0);return o}var ut=Object.freeze({__proto__:null,bitGet,bitLen,bitMask,bitSet,bytesToHex:bytesToHex$2,bytesToNumberBE,bytesToNumberLE,concatBytes:concatBytes$2,createHmacDrbg,ensureBytes:ensureBytes$1,equalBytes:equalBytes$1,hexToBytes:hexToBytes$2,hexToNumber,numberToBytesBE,numberToBytesLE,numberToHexUnpadded,numberToVarBytesBE,utf8ToBytes:utf8ToBytes$3,validateObject});const _0n$3=BigInt(0),_1n$3=BigInt(1),_2n$1=BigInt(2),_3n$1=BigInt(3),_4n=BigInt(4),_5n=BigInt(5),_8n=BigInt(8);function mod(o,s){const r=o%s;return r>=_0n$3?r:s+r}function pow(o,s,r){if(r<=_0n$3||s<_0n$3)throw new Error("Expected power/modulo > 0");if(r===_1n$3)return _0n$3;let i=_1n$3;for(;s>_0n$3;)s&_1n$3&&(i=i*o%r),o=o*o%r,s>>=_1n$3;return i}function pow2(o,s,r){let i=o;for(;s-- >_0n$3;)i*=i,i%=r;return i}function invert(o,s){if(o===_0n$3||s<=_0n$3)throw new Error(`invert: expected positive integers, got n=${o} mod=${s}`);let r=mod(o,s),i=s,a=_0n$3,c=_1n$3;for(;r!==_0n$3;){const y=i%r,w=a-c*(i/r);i=r,r=y,a=c,c=w}if(i!==_1n$3)throw new Error("invert: does not exist");return mod(a,s)}function tonelliShanks(o){const s=(o-_1n$3)/_2n$1;let r,i,a;for(r=o-_1n$3,i=0;r%_2n$1===_0n$3;r/=_2n$1,i++);for(a=_2n$1;a(r[i]="function",r),{ORDER:"bigint",MASK:"bigint",BYTES:"isSafeInteger",BITS:"isSafeInteger"}))}function FpPow(o,s,r){if(r<_0n$3)throw new Error("Expected power > 0");if(r===_0n$3)return o.ONE;if(r===_1n$3)return s;let i=o.ONE,a=s;for(;r>_0n$3;)r&_1n$3&&(i=o.mul(i,a)),a=o.sqr(a),r>>=_1n$3;return i}function FpInvertBatch(o,s){const r=new Array(s.length),i=s.reduce((c,y,w)=>o.is0(y)?c:(r[w]=c,o.mul(c,y)),o.ONE),a=o.inv(i);return s.reduceRight((c,y,w)=>o.is0(y)?c:(r[w]=o.mul(c,r[w]),o.mul(c,y)),a),r}function nLength(o,s){const r=void 0!==s?s:o.toString(2).length;return{nBitLength:r,nByteLength:Math.ceil(r/8)}}function Field(o,s,r=!1,i={}){if(o<=_0n$3)throw new Error(`Expected Fp ORDER > 0, got ${o}`);const{nBitLength:a,nByteLength:c}=nLength(o,s);if(c>2048)throw new Error("Field lengths over 2048 bytes are not supported");const y=FpSqrt(o),w=Object.freeze({ORDER:o,BITS:a,BYTES:c,MASK:bitMask(a),ZERO:_0n$3,ONE:_1n$3,create:C=>mod(C,o),isValid:C=>{if("bigint"!=typeof C)throw new Error("Invalid field element: expected bigint, got "+typeof C);return _0n$3<=C&&CC===_0n$3,isOdd:C=>(C&_1n$3)===_1n$3,neg:C=>mod(-C,o),eql:(C,T)=>C===T,sqr:C=>mod(C*C,o),add:(C,T)=>mod(C+T,o),sub:(C,T)=>mod(C-T,o),mul:(C,T)=>mod(C*T,o),pow:(C,T)=>FpPow(w,C,T),div:(C,T)=>mod(C*invert(T,o),o),sqrN:C=>C*C,addN:(C,T)=>C+T,subN:(C,T)=>C-T,mulN:(C,T)=>C*T,inv:C=>invert(C,o),sqrt:i.sqrt||(C=>y(w,C)),invertBatch:C=>FpInvertBatch(w,C),cmov:(C,T,S)=>S?T:C,toBytes:C=>r?numberToBytesLE(C,c):numberToBytesBE(C,c),fromBytes:C=>{if(C.length!==c)throw new Error(`Fp.fromBytes: expected ${c}, got ${C.length}`);return r?bytesToNumberLE(C):bytesToNumberBE(C)}});return Object.freeze(w)}function hashToPrivateScalar(o,s,r=!1){const i=(o=ensureBytes$1("privateHash",o)).length,a=nLength(s).nByteLength+8;if(a<24||i1024)throw new Error(`hashToPrivateScalar: expected ${a}-1024 bytes of input, got ${i}`);return mod(r?bytesToNumberLE(o):bytesToNumberBE(o),s-_1n$3)+_1n$3}const _0n$2=BigInt(0),_1n$2=BigInt(1);function wNAF(o,s){const r=(a,c)=>{const y=c.negate();return a?y:c},i=a=>({windows:Math.ceil(s/a)+1,windowSize:2**(a-1)});return{constTimeNegate:r,unsafeLadder(a,c){let y=o.ZERO,w=a;for(;c>_0n$2;)c&_1n$2&&(y=y.add(w)),w=w.double(),c>>=_1n$2;return y},precomputeWindow(a,c){const{windows:y,windowSize:w}=i(c),C=[];let T=a,S=T;for(let M=0;M>=L,re>C&&(re-=O,y+=_1n$2);const pe=q,se=q+Math.abs(re)-1,me=re<0;0===re?S=S.add(r(Z%2!=0,c[pe])):T=T.add(r(me,c[se]))}return{p:T,f:S}},wNAFCached(a,c,y,w){const C=a._WINDOW_SIZE||1;let T=c.get(a);return T||(T=this.precomputeWindow(a,C),1!==C&&c.set(a,w(T))),this.wNAF(C,T,y)}}}function validateBasic(o){return validateField(o.Fp),validateObject(o,{n:"bigint",h:"bigint",Gx:"field",Gy:"field"},{nBitLength:"isSafeInteger",nByteLength:"isSafeInteger"}),Object.freeze({...nLength(o.n,o.nBitLength),...o,p:o.Fp.ORDER})}function validatePointOpts(o){const s=validateBasic(o);validateObject(s,{a:"field",b:"field"},{allowedPrivateKeyLengths:"array",wrapPrivateKey:"boolean",isTorsionFree:"function",clearCofactor:"function",allowInfinityPoint:"boolean",fromBytes:"function",toBytes:"function"});const{endo:r,Fp:i,a}=s;if(r){if(!i.eql(a,i.ZERO))throw new Error("Endomorphism can only be defined for Koblitz curves that have a=0");if("object"!=typeof r||"bigint"!=typeof r.beta||"function"!=typeof r.splitScalar)throw new Error("Expected endomorphism with beta: bigint and splitScalar: function")}return Object.freeze({...s})}const{bytesToNumberBE:b2n,hexToBytes:h2b}=ut,DER={Err:class extends Error{constructor(o=""){super(o)}},_parseInt(o){const{Err:s}=DER;if(o.length<2||2!==o[0])throw new s("Invalid signature integer tag");const r=o[1],i=o.subarray(2,r+2);if(!r||i.length!==r)throw new s("Invalid signature integer: wrong length");if(128&i[0])throw new s("Invalid signature integer: negative");if(0===i[0]&&!(128&i[1]))throw new s("Invalid signature integer: unnecessary leading zero");return{d:b2n(i),l:o.subarray(r+2)}},toSig(o){const{Err:s}=DER,r="string"==typeof o?h2b(o):o;if(!(r instanceof Uint8Array))throw new Error("ui8a expected");let i=r.length;if(i<2||48!=r[0])throw new s("Invalid signature tag");if(r[1]!==i-2)throw new s("Invalid signature: incorrect length");const{d:a,l:c}=DER._parseInt(r.subarray(2)),{d:y,l:w}=DER._parseInt(c);if(w.length)throw new s("Invalid signature: left bytes after parsing");return{r:a,s:y}},hexFromSig(o){const s=T=>8&Number.parseInt(T[0],16)?"00"+T:T,r=T=>{const S=T.toString(16);return 1&S.length?`0${S}`:S},i=s(r(o.s)),a=s(r(o.r)),c=i.length/2,y=a.length/2,w=r(c),C=r(y);return`30${r(y+c+4)}02${C}${a}02${w}${i}`}},_0n$1=BigInt(0),_1n$1=BigInt(1);BigInt(2);const _3n=BigInt(3);function weierstrassPoints(o){const s=validatePointOpts(o),{Fp:r}=s,i=s.toBytes||((Z,q,re)=>{const pe=q.toAffine();return concatBytes$2(Uint8Array.from([4]),r.toBytes(pe.x),r.toBytes(pe.y))}),a=s.fromBytes||(Z=>{const q=Z.subarray(1);return{x:r.fromBytes(q.subarray(0,r.BYTES)),y:r.fromBytes(q.subarray(r.BYTES,2*r.BYTES))}});function c(Z){const{a:q,b:re}=s,pe=r.sqr(Z),se=r.mul(pe,Z);return r.add(r.add(se,r.mul(Z,q)),re)}if(!r.eql(r.sqr(s.Gy),c(s.Gx)))throw new Error("bad generator point: equation left != right");function y(Z){return"bigint"==typeof Z&&_0n$1r.eql(ae,r.ZERO);return se(re)&&se(pe)?M.ZERO:new M(re,pe,r.ONE)}get x(){return this.toAffine().x}get y(){return this.toAffine().y}static normalizeZ(q){const re=r.invertBatch(q.map(pe=>pe.pz));return q.map((pe,se)=>pe.toAffine(re[se])).map(M.fromAffine)}static fromHex(q){const re=M.fromAffine(a(ensureBytes$1("pointHex",q)));return re.assertValidity(),re}static fromPrivateKey(q){return M.BASE.multiply(C(q))}_setWindowSize(q){this._WINDOW_SIZE=q,T.delete(this)}assertValidity(){if(this.is0()){if(s.allowInfinityPoint)return;throw new Error("bad point: ZERO")}const{x:q,y:re}=this.toAffine();if(!r.isValid(q)||!r.isValid(re))throw new Error("bad point: x or y not FE");const pe=r.sqr(re),se=c(q);if(!r.eql(pe,se))throw new Error("bad point: equation left != right");if(!this.isTorsionFree())throw new Error("bad point: not in prime-order subgroup")}hasEvenY(){const{y:q}=this.toAffine();if(r.isOdd)return!r.isOdd(q);throw new Error("Field doesn't support isOdd")}equals(q){S(q);const{px:re,py:pe,pz:se}=this,{px:ae,py:me,pz:be}=q,Oe=r.eql(r.mul(re,be),r.mul(ae,se)),xe=r.eql(r.mul(pe,be),r.mul(me,se));return Oe&&xe}negate(){return new M(this.px,r.neg(this.py),this.pz)}double(){const{a:q,b:re}=s,pe=r.mul(re,_3n),{px:se,py:ae,pz:me}=this;let be=r.ZERO,Oe=r.ZERO,xe=r.ZERO,De=r.mul(se,se),ce=r.mul(ae,ae),ue=r.mul(me,me),Ce=r.mul(se,ae);return Ce=r.add(Ce,Ce),xe=r.mul(se,me),xe=r.add(xe,xe),be=r.mul(q,xe),Oe=r.mul(pe,ue),Oe=r.add(be,Oe),be=r.sub(ce,Oe),Oe=r.add(ce,Oe),Oe=r.mul(be,Oe),be=r.mul(Ce,be),xe=r.mul(pe,xe),ue=r.mul(q,ue),Ce=r.sub(De,ue),Ce=r.mul(q,Ce),Ce=r.add(Ce,xe),xe=r.add(De,De),De=r.add(xe,De),De=r.add(De,ue),De=r.mul(De,Ce),Oe=r.add(Oe,De),ue=r.mul(ae,me),ue=r.add(ue,ue),De=r.mul(ue,Ce),be=r.sub(be,De),xe=r.mul(ue,ce),xe=r.add(xe,xe),xe=r.add(xe,xe),new M(be,Oe,xe)}add(q){S(q);const{px:re,py:pe,pz:se}=this,{px:ae,py:me,pz:be}=q;let Oe=r.ZERO,xe=r.ZERO,De=r.ZERO;const ce=s.a,ue=r.mul(s.b,_3n);let Ce=r.mul(re,ae),Be=r.mul(pe,me),at=r.mul(se,be),dt=r.add(re,pe),bt=r.add(ae,me);dt=r.mul(dt,bt),bt=r.add(Ce,Be),dt=r.sub(dt,bt),bt=r.add(re,se);let lt=r.add(ae,be);return bt=r.mul(bt,lt),lt=r.add(Ce,at),bt=r.sub(bt,lt),lt=r.add(pe,se),Oe=r.add(me,be),lt=r.mul(lt,Oe),Oe=r.add(Be,at),lt=r.sub(lt,Oe),De=r.mul(ce,bt),Oe=r.mul(ue,at),De=r.add(Oe,De),Oe=r.sub(Be,De),De=r.add(Be,De),xe=r.mul(Oe,De),Be=r.add(Ce,Ce),Be=r.add(Be,Ce),at=r.mul(ce,at),bt=r.mul(ue,bt),Be=r.add(Be,at),at=r.sub(Ce,at),at=r.mul(ce,at),bt=r.add(bt,at),Ce=r.mul(Be,bt),xe=r.add(xe,Ce),Ce=r.mul(lt,bt),Oe=r.mul(dt,Oe),Oe=r.sub(Oe,Ce),Ce=r.mul(dt,Be),De=r.mul(lt,De),De=r.add(De,Ce),new M(Oe,xe,De)}subtract(q){return this.add(q.negate())}is0(){return this.equals(M.ZERO)}wNAF(q){return L.wNAFCached(this,T,q,re=>{const pe=r.invertBatch(re.map(se=>se.pz));return re.map((se,ae)=>se.toAffine(pe[ae])).map(M.fromAffine)})}multiplyUnsafe(q){const re=M.ZERO;if(q===_0n$1)return re;if(w(q),q===_1n$1)return this;const{endo:pe}=s;if(!pe)return L.unsafeLadder(this,q);let{k1neg:se,k1:ae,k2neg:me,k2:be}=pe.splitScalar(q),Oe=re,xe=re,De=this;for(;ae>_0n$1||be>_0n$1;)ae&_1n$1&&(Oe=Oe.add(De)),be&_1n$1&&(xe=xe.add(De)),De=De.double(),ae>>=_1n$1,be>>=_1n$1;return se&&(Oe=Oe.negate()),me&&(xe=xe.negate()),xe=new M(r.mul(xe.px,pe.beta),xe.py,xe.pz),Oe.add(xe)}multiply(q){w(q);let re,pe,se=q;const{endo:ae}=s;if(ae){const{k1neg:me,k1:be,k2neg:Oe,k2:xe}=ae.splitScalar(se);let{p:De,f:ce}=this.wNAF(be),{p:ue,f:Ce}=this.wNAF(xe);De=L.constTimeNegate(me,De),ue=L.constTimeNegate(Oe,ue),ue=new M(r.mul(ue.px,ae.beta),ue.py,ue.pz),re=De.add(ue),pe=ce.add(Ce)}else{const{p:me,f:be}=this.wNAF(se);re=me,pe=be}return M.normalizeZ([re,pe])[0]}multiplyAndAddUnsafe(q,re,pe){const se=M.BASE,ae=(be,Oe)=>Oe!==_0n$1&&Oe!==_1n$1&&be.equals(se)?be.multiply(Oe):be.multiplyUnsafe(Oe),me=ae(this,re).add(ae(q,pe));return me.is0()?void 0:me}toAffine(q){const{px:re,py:pe,pz:se}=this,ae=this.is0();null==q&&(q=ae?r.ONE:r.inv(se));const me=r.mul(re,q),be=r.mul(pe,q),Oe=r.mul(se,q);if(ae)return{x:r.ZERO,y:r.ZERO};if(!r.eql(Oe,r.ONE))throw new Error("invZ was invalid");return{x:me,y:be}}isTorsionFree(){const{h:q,isTorsionFree:re}=s;if(q===_1n$1)return!0;if(re)return re(M,this);throw new Error("isTorsionFree() has not been declared for the elliptic curve")}clearCofactor(){const{h:q,clearCofactor:re}=s;return q===_1n$1?this:re?re(M,this):this.multiplyUnsafe(s.h)}toRawBytes(q=!0){return this.assertValidity(),i(M,this,q)}toHex(q=!0){return bytesToHex$2(this.toRawBytes(q))}}M.BASE=new M(s.Gx,s.Gy,r.ONE),M.ZERO=new M(r.ZERO,r.ONE,r.ZERO);const O=s.nBitLength,L=wNAF(M,s.endo?Math.ceil(O/2):O);return{CURVE:s,ProjectivePoint:M,normPrivateKeyToScalar:C,weierstrassEquation:c,isWithinCurveOrder:y}}function validateOpts(o){const s=validateBasic(o);return validateObject(s,{hash:"hash",hmac:"function",randomBytes:"function"},{bits2int:"function",bits2int_modN:"function",lowS:"boolean"}),Object.freeze({lowS:!0,...s})}function weierstrass(o){const s=validateOpts(o),{Fp:r,n:i}=s,a=r.BYTES+1,c=2*r.BYTES+1;function y(ce){return mod(ce,i)}function w(ce){return invert(ce,i)}const{ProjectivePoint:C,normPrivateKeyToScalar:T,weierstrassEquation:S,isWithinCurveOrder:M}=weierstrassPoints({...s,toBytes(ce,ue,Ce){const Be=ue.toAffine(),at=r.toBytes(Be.x),dt=concatBytes$2;return Ce?dt(Uint8Array.from([ue.hasEvenY()?2:3]),at):dt(Uint8Array.from([4]),at,r.toBytes(Be.y))},fromBytes(ce){const ue=ce.length,Ce=ce[0],Be=ce.subarray(1);if(ue!==a||2!==Ce&&3!==Ce){if(ue===c&&4===Ce)return{x:r.fromBytes(Be.subarray(0,r.BYTES)),y:r.fromBytes(Be.subarray(r.BYTES,2*r.BYTES))};throw new Error(`Point of length ${ue} was invalid. Expected ${a} compressed bytes or ${c} uncompressed bytes`)}{const dt=bytesToNumberBE(Be);if(!(_0n$1<(at=dt)&&atbytesToHex$2(numberToBytesBE(ce,s.nByteLength));function L(ce){return ce>i>>_1n$1}const Z=(ce,ue,Ce)=>bytesToNumberBE(ce.slice(ue,Ce));class q{constructor(ue,Ce,Be){this.r=ue,this.s=Ce,this.recovery=Be,this.assertValidity()}static fromCompact(ue){const Ce=s.nByteLength;return ue=ensureBytes$1("compactSignature",ue,2*Ce),new q(Z(ue,0,Ce),Z(ue,Ce,2*Ce))}static fromDER(ue){const{r:Ce,s:Be}=DER.toSig(ensureBytes$1("DER",ue));return new q(Ce,Be)}assertValidity(){if(!M(this.r))throw new Error("r must be 0 < r < CURVE.n");if(!M(this.s))throw new Error("s must be 0 < s < CURVE.n")}addRecoveryBit(ue){return new q(this.r,this.s,ue)}recoverPublicKey(ue){const{r:Ce,s:Be,recovery:at}=this,dt=ae(ensureBytes$1("msgHash",ue));if(null==at||![0,1,2,3].includes(at))throw new Error("recovery id invalid");const bt=2===at||3===at?Ce+s.n:Ce;if(bt>=r.ORDER)throw new Error("recovery id 2 or 3 invalid");const rn=C.fromHex((1&at?"03":"02")+O(bt)),gn=w(bt),bn=y(-dt*gn),Vn=y(Be*gn),yn=C.BASE.multiplyAndAddUnsafe(rn,bn,Vn);if(!yn)throw new Error("point at infinify");return yn.assertValidity(),yn}hasHighS(){return L(this.s)}normalizeS(){return this.hasHighS()?new q(this.r,y(-this.s),this.recovery):this}toDERRawBytes(){return hexToBytes$2(this.toDERHex())}toDERHex(){return DER.hexFromSig({r:this.r,s:this.s})}toCompactRawBytes(){return hexToBytes$2(this.toCompactHex())}toCompactHex(){return O(this.r)+O(this.s)}}const re={isValidPrivateKey(ce){try{return T(ce),!0}catch{return!1}},normPrivateKeyToScalar:T,randomPrivateKey:()=>numberToBytesBE(hashToPrivateScalar(s.randomBytes(r.BYTES+8),i),s.nByteLength),precompute:(ce=8,ue=C.BASE)=>(ue._setWindowSize(ce),ue.multiply(BigInt(3)),ue)};function pe(ce){const ue=ce instanceof Uint8Array,Ce="string"==typeof ce,Be=(ue||Ce)&&ce.length;return ue?Be===a||Be===c:Ce?Be===2*a||Be===2*c:ce instanceof C}const se=s.bits2int||function(ce){const ue=bytesToNumberBE(ce),Ce=8*ce.length-s.nBitLength;return Ce>0?ue>>BigInt(Ce):ue},ae=s.bits2int_modN||function(ce){return y(se(ce))},me=bitMask(s.nBitLength);function be(ce){if("bigint"!=typeof ce)throw new Error("bigint expected");if(!(_0n$1<=ce&&ceqe in Ce))throw new Error("sign() legacy options not supported");const{hash:Be,randomBytes:at}=s;let{lowS:dt,prehash:bt,extraEntropy:lt}=Ce;null==dt&&(dt=!0),ce=ensureBytes$1("msgHash",ce),bt&&(ce=ensureBytes$1("prehashed msgHash",Be(ce)));const rn=ae(ce),gn=T(ue),bn=[be(gn),be(rn)];if(null!=lt){const qe=!0===lt?at(r.BYTES):lt;bn.push(ensureBytes$1("extraEntropy",qe,r.BYTES))}const Vn=concatBytes$2(...bn),yn=rn;return{seed:Vn,k2sig:function(qe){const _t=se(qe);if(!M(_t))return;const ze=w(_t),$e=C.BASE.multiply(_t).toAffine(),Ft=y($e.x);if(Ft===_0n$1)return;const Ke=y(ze*y(yn+Ft*gn));if(Ke===_0n$1)return;let Ze=($e.x===Ft?0:2)|Number($e.y&_1n$1),it=Ke;return dt&&L(Ke)&&(it=L(Ot=Ke)?y(-Ot):Ot,Ze^=1),new q(Ft,it,Ze);var Ot}}}(ce,ue,Ce);return createHmacDrbg(s.hash.outputLen,s.nByteLength,s.hmac)(Be,at)},verify:function(ce,ue,Ce,Be=De){const at=ce;if(ue=ensureBytes$1("msgHash",ue),Ce=ensureBytes$1("publicKey",Ce),"strict"in Be)throw new Error("options.strict was renamed to lowS");const{lowS:dt,prehash:bt}=Be;let lt,rn;try{if("string"==typeof at||at instanceof Uint8Array)try{lt=q.fromDER(at)}catch($e){if(!($e instanceof DER.Err))throw $e;lt=q.fromCompact(at)}else{if("object"!=typeof at||"bigint"!=typeof at.r||"bigint"!=typeof at.s)throw new Error("PARSE");{const{r:$e,s:Ft}=at;lt=new q($e,Ft)}}rn=C.fromHex(Ce)}catch($e){if("PARSE"===$e.message)throw new Error("signature must be Signature instance, Uint8Array or hex string");return!1}if(dt&<.hasHighS())return!1;bt&&(ue=s.hash(ue));const{r:gn,s:bn}=lt,Vn=ae(ue),yn=w(bn),qe=y(Vn*yn),_t=y(gn*yn),ze=C.BASE.multiplyAndAddUnsafe(rn,qe,_t)?.toAffine();return!!ze&&y(ze.x)===gn},ProjectivePoint:C,Signature:q,utils:re}}BigInt(4);let HMAC$2=class extends Hash$2{constructor(o,s){super(),this.finished=!1,this.destroyed=!1,assert$3.hash(o);const r=toBytes$3(s);if(this.iHash=o.create(),"function"!=typeof this.iHash.update)throw new Error("Expected instance of class which extends utils.Hash");this.blockLen=this.iHash.blockLen,this.outputLen=this.iHash.outputLen;const i=this.blockLen,a=new Uint8Array(i);a.set(r.length>i?o.create().update(r).digest():r);for(let c=0;cnew HMAC$2(o,s).update(r).digest();function getHash(o){return{hash:o,hmac:(s,...r)=>hmac$2(o,s,concatBytes$3(...r)),randomBytes:randomBytes$2}}function createCurve(o,s){const r=i=>weierstrass({...o,...getHash(i)});return Object.freeze({...r(s),create:r})}hmac$2.create=(o,s)=>new HMAC$2(o,s);const secp256k1P=BigInt("0xfffffffffffffffffffffffffffffffffffffffffffffffffffffffefffffc2f"),secp256k1N=BigInt("0xfffffffffffffffffffffffffffffffebaaedce6af48a03bbfd25e8cd0364141"),_1n=BigInt(1),_2n=BigInt(2),divNearest=(o,s)=>(o+s/_2n)/s;function sqrtMod(o){const s=secp256k1P,r=BigInt(3),i=BigInt(6),a=BigInt(11),c=BigInt(22),y=BigInt(23),w=BigInt(44),C=BigInt(88),T=o*o*o%s,S=T*T*o%s,M=pow2(S,r,s)*S%s,O=pow2(M,r,s)*S%s,L=pow2(O,_2n,s)*T%s,Z=pow2(L,a,s)*L%s,q=pow2(Z,c,s)*Z%s,re=pow2(q,w,s)*q%s,pe=pow2(re,C,s)*re%s,se=pow2(pe,w,s)*q%s,ae=pow2(se,r,s)*S%s,me=pow2(ae,y,s)*Z%s,be=pow2(me,i,s)*T%s,Oe=pow2(be,_2n,s);if(!Fp.eql(Fp.sqr(Oe),o))throw new Error("Cannot find square root");return Oe}const Fp=Field(secp256k1P,void 0,void 0,{sqrt:sqrtMod}),secp256k1=createCurve({a:BigInt(0),b:BigInt(7),Fp,n:secp256k1N,Gx:BigInt("55066263022277343669578718895168534326250603453777594175500187360389116729240"),Gy:BigInt("32670510020758816978083085130507043184471273380659243275938904335757337482424"),h:BigInt(1),lowS:!0,endo:{beta:BigInt("0x7ae96a2b657c07106e64479eac3434e99cf0497512f58995c1396c28719501ee"),splitScalar:o=>{const s=secp256k1N,r=BigInt("0x3086d221a7d46bcde86c90e49284eb15"),i=-_1n*BigInt("0xe4437ed6010e88286f547fa90abfe4c3"),a=BigInt("0x114ca50f7a8e2f3f657c1108d9d44cfd8"),c=r,y=BigInt("0x100000000000000000000000000000000"),w=divNearest(c*o,s),C=divNearest(-i*o,s);let T=mod(o-w*r-C*a,s),S=mod(-w*i-C*c,s);const M=T>y,O=S>y;if(M&&(T=s-T),O&&(S=s-S),T>y||S>y)throw new Error("splitScalar: Endomorphism failed, k="+o);return{k1neg:M,k1:T,k2neg:O,k2:S}}}},sha256$2),_0n=BigInt(0),fe=o=>"bigint"==typeof o&&_0n"bigint"==typeof o&&_0na.charCodeAt(0)));r=concatBytes$2(i,i),TAGGED_HASH_PREFIXES[o]=r}return sha256$2(concatBytes$2(r,...s))}const pointToBytes=o=>o.toRawBytes(!0).slice(1),numTo32b=o=>numberToBytesBE(o,32),modP=o=>mod(o,secp256k1P),modN=o=>mod(o,secp256k1N),Point$1=secp256k1.ProjectivePoint,GmulAdd=(o,s,r)=>Point$1.BASE.multiplyAndAddUnsafe(o,s,r);function schnorrGetExtPubKey(o){let s=secp256k1.utils.normPrivateKeyToScalar(o),r=Point$1.fromPrivateKey(s);return{scalar:r.hasEvenY()?s:modN(-s),bytes:pointToBytes(r)}}function lift_x(o){if(!fe(o))throw new Error("bad x: need 0 < x < p");const s=modP(o*o);let r=sqrtMod(modP(s*o+BigInt(7)));r%_2n!==_0n&&(r=modP(-r));const i=new Point$1(o,r,_1n);return i.assertValidity(),i}function challenge(...o){return modN(bytesToNumberBE(taggedHash("BIP0340/challenge",...o)))}function schnorrGetPublicKey(o){return schnorrGetExtPubKey(o).bytes}function schnorrSign(o,s,r=randomBytes$2(32)){const i=ensureBytes$1("message",o),{bytes:a,scalar:c}=schnorrGetExtPubKey(s),y=ensureBytes$1("auxRand",r,32),w=numTo32b(c^bytesToNumberBE(taggedHash("BIP0340/aux",y))),C=taggedHash("BIP0340/nonce",w,a,i),T=modN(bytesToNumberBE(C));if(T===_0n)throw new Error("sign failed: k is zero");const{bytes:S,scalar:M}=schnorrGetExtPubKey(T),O=challenge(S,a,i),L=new Uint8Array(64);if(L.set(S,0),L.set(numTo32b(modN(M+O*c)),32),!schnorrVerify(L,i,a))throw new Error("sign: Invalid signature produced");return L}function schnorrVerify(o,s,r){const i=ensureBytes$1("signature",o,64),a=ensureBytes$1("message",s),c=ensureBytes$1("publicKey",r,32);try{const y=lift_x(bytesToNumberBE(c)),w=bytesToNumberBE(i.subarray(0,32));if(!fe(w))return!1;const C=bytesToNumberBE(i.subarray(32,64));if(!ge(C))return!1;const T=challenge(numTo32b(w),pointToBytes(y),a),S=GmulAdd(y,C,modN(-T));return!(!S||!S.hasEvenY()||S.toAffine().x!==w)}catch{return!1}}const schnorr={getPublicKey:schnorrGetPublicKey,sign:schnorrSign,verify:schnorrVerify,utils:{randomPrivateKey:secp256k1.utils.randomPrivateKey,lift_x,pointToBytes,numberToBytesBE,bytesToNumberBE,taggedHash,mod}},crypto$2="object"==typeof globalThis&&"crypto"in globalThis?globalThis.crypto:void 0,u8a$1=o=>o instanceof Uint8Array,createView$1=o=>new DataView(o.buffer,o.byteOffset,o.byteLength),rotr$1=(o,s)=>o<<32-s|o>>>s,isLE$2=68===new Uint8Array(new Uint32Array([287454020]).buffer)[0];if(!isLE$2)throw new Error("Non little-endian hardware is not supported");const hexes$1=Array.from({length:256},(o,s)=>s.toString(16).padStart(2,"0"));function bytesToHex$1(o){if(!u8a$1(o))throw new Error("Uint8Array expected");let s="";for(let r=0;ri+a.length,0));let r=0;return o.forEach(i=>{if(!u8a$1(i))throw new Error("Uint8Array expected");s.set(i,r),r+=i.length}),s}let Hash$1=class{clone(){return this._cloneInto()}};function wrapConstructor$1(o){const s=i=>o().update(toBytes$2(i)).digest(),r=o();return s.outputLen=r.outputLen,s.blockLen=r.blockLen,s.create=()=>o(),s}function randomBytes$1(o=32){if(crypto$2&&"function"==typeof crypto$2.getRandomValues)return crypto$2.getRandomValues(new Uint8Array(o));throw new Error("crypto.getRandomValues must be defined")}function number$2(o){if(!Number.isSafeInteger(o)||o<0)throw new Error(`Wrong positive integer: ${o}`)}function bool$2(o){if("boolean"!=typeof o)throw new Error(`Expected boolean, not ${o}`)}function bytes$2(o,...s){if(!(o instanceof Uint8Array))throw new Error("Expected Uint8Array");if(s.length>0&&!s.includes(o.length))throw new Error(`Expected Uint8Array of length ${s}, not of length=${o.length}`)}function hash$2(o){if("function"!=typeof o||"function"!=typeof o.create)throw new Error("Hash should be wrapped by utils.wrapConstructor");number$2(o.outputLen),number$2(o.blockLen)}function exists$2(o,s=!0){if(o.destroyed)throw new Error("Hash instance has been destroyed");if(s&&o.finished)throw new Error("Hash#digest() has already been called")}function output$2(o,s){bytes$2(o);const r=s.outputLen;if(o.length>a&c),w=Number(r&c),T=i?0:4;o.setUint32(s+(i?4:0),y,i),o.setUint32(s+T,w,i)}let SHA2$1=class extends Hash$1{constructor(o,s,r,i){super(),this.blockLen=o,this.outputLen=s,this.padOffset=r,this.isLE=i,this.finished=!1,this.length=0,this.pos=0,this.destroyed=!1,this.buffer=new Uint8Array(o),this.view=createView$1(this.buffer)}update(o){assert$2.exists(this);const{view:s,buffer:r,blockLen:i}=this,a=(o=toBytes$2(o)).length;for(let c=0;ci-c&&(this.process(r,0),c=0);for(let S=c;ST.length)throw new Error("_sha2: outputLen bigger than state");for(let S=0;So&s^~o&r,Maj$1=(o,s,r)=>o&s^o&r^s&r,SHA256_K$1=new Uint32Array([1116352408,1899447441,3049323471,3921009573,961987163,1508970993,2453635748,2870763221,3624381080,310598401,607225278,1426881987,1925078388,2162078206,2614888103,3248222580,3835390401,4022224774,264347078,604807628,770255983,1249150122,1555081692,1996064986,2554220882,2821834349,2952996808,3210313671,3336571891,3584528711,113926993,338241895,666307205,773529912,1294757372,1396182291,1695183700,1986661051,2177026350,2456956037,2730485921,2820302411,3259730800,3345764771,3516065817,3600352804,4094571909,275423344,430227734,506948616,659060556,883997877,958139571,1322822218,1537002063,1747873779,1955562222,2024104815,2227730452,2361852424,2428436474,2756734187,3204031479,3329325298]),IV$1=new Uint32Array([1779033703,3144134277,1013904242,2773480762,1359893119,2600822924,528734635,1541459225]),SHA256_W$1=new Uint32Array(64);let SHA256$1=class extends SHA2$1{constructor(){super(64,32,8,!1),this.A=0|IV$1[0],this.B=0|IV$1[1],this.C=0|IV$1[2],this.D=0|IV$1[3],this.E=0|IV$1[4],this.F=0|IV$1[5],this.G=0|IV$1[6],this.H=0|IV$1[7]}get(){const{A:o,B:s,C:r,D:i,E:a,F:c,G:y,H:w}=this;return[o,s,r,i,a,c,y,w]}set(o,s,r,i,a,c,y,w){this.A=0|o,this.B=0|s,this.C=0|r,this.D=0|i,this.E=0|a,this.F=0|c,this.G=0|y,this.H=0|w}process(o,s){for(let S=0;S<16;S++,s+=4)SHA256_W$1[S]=o.getUint32(s,!1);for(let S=16;S<64;S++){const M=SHA256_W$1[S-15],O=SHA256_W$1[S-2],L=rotr$1(M,7)^rotr$1(M,18)^M>>>3,Z=rotr$1(O,17)^rotr$1(O,19)^O>>>10;SHA256_W$1[S]=Z+SHA256_W$1[S-7]+L+SHA256_W$1[S-16]|0}let{A:r,B:i,C:a,D:c,E:y,F:w,G:C,H:T}=this;for(let S=0;S<64;S++){const M=T+(rotr$1(y,6)^rotr$1(y,11)^rotr$1(y,25))+Chi$1(y,w,C)+SHA256_K$1[S]+SHA256_W$1[S]|0,O=(rotr$1(r,2)^rotr$1(r,13)^rotr$1(r,22))+Maj$1(r,i,a)|0;T=C,C=w,w=y,y=c+M|0,c=a,a=i,i=r,r=M+O|0}r=r+this.A|0,i=i+this.B|0,a=a+this.C|0,c=c+this.D|0,y=y+this.E|0,w=w+this.F|0,C=C+this.G|0,T=T+this.H|0,this.set(r,i,a,c,y,w,C,T)}roundClean(){SHA256_W$1.fill(0)}destroy(){this.set(0,0,0,0,0,0,0,0),this.buffer.fill(0)}};class SHA224 extends SHA256$1{constructor(){super(),this.A=-1056596264,this.B=914150663,this.C=812702999,this.D=-150054599,this.E=-4191439,this.F=1750603025,this.G=1694076839,this.H=-1090891868,this.outputLen=28}}const sha256$1=wrapConstructor$1(()=>new SHA256$1);function assertNumber(o){if(!Number.isSafeInteger(o))throw new Error(`Wrong integer: ${o}`)}function chain$1(...o){const s=(r,i)=>a=>r(i(a));return{encode:Array.from(o).reverse().reduce((r,i)=>r?s(r,i.encode):i.encode,void 0),decode:o.reduce((r,i)=>r?s(r,i.decode):i.decode,void 0)}}function alphabet$1(o){return{encode:s=>{if(!Array.isArray(s)||s.length&&"number"!=typeof s[0])throw new Error("alphabet.encode input should be an array of numbers");return s.map(r=>{if(assertNumber(r),r<0||r>=o.length)throw new Error(`Digit index outside alphabet: ${r} (alphabet: ${o.length})`);return o[r]})},decode:s=>{if(!Array.isArray(s)||s.length&&"string"!=typeof s[0])throw new Error("alphabet.decode input should be array of strings");return s.map(r=>{if("string"!=typeof r)throw new Error(`alphabet.decode: not string element=${r}`);const i=o.indexOf(r);if(-1===i)throw new Error(`Unknown letter: "${r}". Allowed: ${o}`);return i})}}}function join$1(o=""){if("string"!=typeof o)throw new Error("join separator should be string");return{encode:s=>{if(!Array.isArray(s)||s.length&&"string"!=typeof s[0])throw new Error("join.encode input should be array of strings");for(let r of s)if("string"!=typeof r)throw new Error(`join.encode: non-string input=${r}`);return s.join(o)},decode:s=>{if("string"!=typeof s)throw new Error("join.decode input should be string");return s.split(o)}}}function padding$1(o,s="="){if(assertNumber(o),"string"!=typeof s)throw new Error("padding chr should be string");return{encode(r){if(!Array.isArray(r)||r.length&&"string"!=typeof r[0])throw new Error("padding.encode input should be array of strings");for(let i of r)if("string"!=typeof i)throw new Error(`padding.encode: non-string input=${i}`);for(;r.length*o%8;)r.push(s);return r},decode(r){if(!Array.isArray(r)||r.length&&"string"!=typeof r[0])throw new Error("padding.encode input should be array of strings");for(let a of r)if("string"!=typeof a)throw new Error(`padding.decode: non-string input=${a}`);let i=r.length;if(i*o%8)throw new Error("Invalid padding: string should have whole number of bytes");for(;i>0&&r[i-1]===s;i--)if(!((i-1)*o%8))throw new Error("Invalid padding: string has too much padding");return r.slice(0,i)}}}function normalize$1(o){if("function"!=typeof o)throw new Error("normalize fn should be function");return{encode:s=>s,decode:s=>o(s)}}function convertRadix$1(o,s,r){if(s<2)throw new Error(`convertRadix: wrong from=${s}, base cannot be less than 2`);if(r<2)throw new Error(`convertRadix: wrong to=${r}, base cannot be less than 2`);if(!Array.isArray(o))throw new Error("convertRadix: data should be array");if(!o.length)return[];let i=0;const a=[],c=Array.from(o);for(c.forEach(y=>{if(assertNumber(y),y<0||y>=s)throw new Error(`Wrong integer: ${y}`)});;){let y=0,w=!0;for(let C=i;Cnew SHA224);const gcd$1=(o,s)=>s?gcd$1(s,o%s):o,radix2carry$1=(o,s)=>o+(s-gcd$1(o,s));function convertRadix2$1(o,s,r,i){if(!Array.isArray(o))throw new Error("convertRadix2: data should be array");if(s<=0||s>32)throw new Error(`convertRadix2: wrong from=${s}`);if(r<=0||r>32)throw new Error(`convertRadix2: wrong to=${r}`);if(radix2carry$1(s,r)>32)throw new Error(`convertRadix2: carry overflow from=${s} to=${r} carryBits=${radix2carry$1(s,r)}`);let a=0,c=0;const y=2**r-1,w=[];for(const C of o){if(assertNumber(C),C>=2**s)throw new Error(`convertRadix2: invalid data word=${C} from=${s}`);if(a=a<32)throw new Error(`convertRadix2: carry overflow pos=${c} from=${s}`);for(c+=s;c>=r;c-=r)w.push((a>>c-r&y)>>>0);a&=2**c-1}if(a=a<=s)throw new Error("Excess padding");if(!i&&a)throw new Error(`Non-zero padding: ${a}`);return i&&c>0&&w.push(a>>>0),w}function radix$1(o){return assertNumber(o),{encode:s=>{if(!(s instanceof Uint8Array))throw new Error("radix.encode input should be Uint8Array");return convertRadix$1(Array.from(s),256,o)},decode:s=>{if(!Array.isArray(s)||s.length&&"number"!=typeof s[0])throw new Error("radix.decode input should be array of strings");return Uint8Array.from(convertRadix$1(s,o,256))}}}function radix2$1(o,s=!1){if(assertNumber(o),o<=0||o>32)throw new Error("radix2: bits should be in (0..32]");if(radix2carry$1(8,o)>32||radix2carry$1(o,8)>32)throw new Error("radix2: carry overflow");return{encode:r=>{if(!(r instanceof Uint8Array))throw new Error("radix2.encode input should be Uint8Array");return convertRadix2$1(Array.from(r),8,o,!s)},decode:r=>{if(!Array.isArray(r)||r.length&&"number"!=typeof r[0])throw new Error("radix2.decode input should be array of strings");return Uint8Array.from(convertRadix2$1(r,o,8,s))}}}function unsafeWrapper$1(o){if("function"!=typeof o)throw new Error("unsafeWrapper fn should be function");return function(...s){try{return o.apply(null,s)}catch{}}}const base16=chain$1(radix2$1(4),alphabet$1("0123456789ABCDEF"),join$1("")),base32=chain$1(radix2$1(5),alphabet$1("ABCDEFGHIJKLMNOPQRSTUVWXYZ234567"),padding$1(5),join$1(""));chain$1(radix2$1(5),alphabet$1("0123456789ABCDEFGHIJKLMNOPQRSTUV"),padding$1(5),join$1("")),chain$1(radix2$1(5),alphabet$1("0123456789ABCDEFGHJKMNPQRSTVWXYZ"),join$1(""),normalize$1(o=>o.toUpperCase().replace(/O/g,"0").replace(/[IL]/g,"1")));const base64$1=chain$1(radix2$1(6),alphabet$1("ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/"),padding$1(6),join$1("")),base64url=chain$1(radix2$1(6),alphabet$1("ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789-_"),padding$1(6),join$1("")),genBase58$1=o=>chain$1(radix$1(58),alphabet$1(o),join$1("")),base58$1=genBase58$1("123456789ABCDEFGHJKLMNPQRSTUVWXYZabcdefghijkmnopqrstuvwxyz");genBase58$1("123456789abcdefghijkmnopqrstuvwxyzABCDEFGHJKLMNPQRSTUVWXYZ"),genBase58$1("rpshnaf39wBUDNEGHJKLM4PQRST7VWXYZ2bcdeCg65jkm8oFqi1tuvAxyz");const XMR_BLOCK_LEN=[0,2,3,5,6,7,9,10,11],base58xmr={encode(o){let s="";for(let r=0;r>25;let r=(33554431&o)<<5;for(let i=0;i>i&1)&&(r^=POLYMOD_GENERATORS$1[i]);return r}function bechChecksum$1(o,s,r=1){const i=o.length;let a=1;for(let c=0;c126)throw new Error(`Invalid prefix (${o})`);a=bech32Polymod$1(a)^y>>5}a=bech32Polymod$1(a);for(let c=0;cC)throw new TypeError(`Wrong string length: ${w.length} (${w}). Expected (8..${C})`);const T=w.toLowerCase();if(w!==T&&w!==w.toUpperCase())throw new Error("String must be lowercase or uppercase");const S=(w=T).lastIndexOf("1");if(0===S||-1===S)throw new Error('Letter "1" must be present between prefix and data only');const M=w.slice(0,S),O=w.slice(S+1);if(O.length<6)throw new Error("Data must be at least 6 characters long");const L=BECH_ALPHABET$1.decode(O).slice(0,-6),Z=bechChecksum$1(M,L,s);if(!O.endsWith(Z))throw new Error(`Invalid checksum in ${w}: expected "${Z}"`);return{prefix:M,words:L}}return{encode:function(w,C,T=90){if("string"!=typeof w)throw new Error("bech32.encode prefix should be string, not "+typeof w);if(!Array.isArray(C)||C.length&&"number"!=typeof C[0])throw new Error("bech32.encode words should be array of numbers, not "+typeof C);const S=w.length+7+C.length;if(!1!==T&&S>T)throw new TypeError(`Length ${S} exceeds limit ${T}`);return`${w=w.toLowerCase()}1${BECH_ALPHABET$1.encode(C)}${bechChecksum$1(w,C,s)}`},decode:y,decodeToBytes:function(w){const{prefix:C,words:T}=y(w,!1);return{prefix:C,words:T,bytes:i(T)}},decodeUnsafe:unsafeWrapper$1(y),fromWords:i,fromWordsUnsafe:c,toWords:a}}const bech32$1=genBech32$1("bech32");genBech32$1("bech32m");const utf8={encode:o=>(new TextDecoder).decode(o),decode:o=>(new TextEncoder).encode(o)},hex=chain$1(radix2$1(4),alphabet$1("0123456789abcdef"),join$1(""),normalize$1(o=>{if("string"!=typeof o||o.length%2)throw new TypeError(`hex.decode: expected string, got ${typeof o} with length ${o.length}`);return o.toLowerCase()})),CODERS={utf8,hex,base16,base32,base64:base64$1,base64url,base58:base58$1,base58xmr};Object.keys(CODERS).join(", ");const wordlist="abandon\nability\nable\nabout\nabove\nabsent\nabsorb\nabstract\nabsurd\nabuse\naccess\naccident\naccount\naccuse\nachieve\nacid\nacoustic\nacquire\nacross\nact\naction\nactor\nactress\nactual\nadapt\nadd\naddict\naddress\nadjust\nadmit\nadult\nadvance\nadvice\naerobic\naffair\nafford\nafraid\nagain\nage\nagent\nagree\nahead\naim\nair\nairport\naisle\nalarm\nalbum\nalcohol\nalert\nalien\nall\nalley\nallow\nalmost\nalone\nalpha\nalready\nalso\nalter\nalways\namateur\namazing\namong\namount\namused\nanalyst\nanchor\nancient\nanger\nangle\nangry\nanimal\nankle\nannounce\nannual\nanother\nanswer\nantenna\nantique\nanxiety\nany\napart\napology\nappear\napple\napprove\napril\narch\narctic\narea\narena\nargue\narm\narmed\narmor\narmy\naround\narrange\narrest\narrive\narrow\nart\nartefact\nartist\nartwork\nask\naspect\nassault\nasset\nassist\nassume\nasthma\nathlete\natom\nattack\nattend\nattitude\nattract\nauction\naudit\naugust\naunt\nauthor\nauto\nautumn\naverage\navocado\navoid\nawake\naware\naway\nawesome\nawful\nawkward\naxis\nbaby\nbachelor\nbacon\nbadge\nbag\nbalance\nbalcony\nball\nbamboo\nbanana\nbanner\nbar\nbarely\nbargain\nbarrel\nbase\nbasic\nbasket\nbattle\nbeach\nbean\nbeauty\nbecause\nbecome\nbeef\nbefore\nbegin\nbehave\nbehind\nbelieve\nbelow\nbelt\nbench\nbenefit\nbest\nbetray\nbetter\nbetween\nbeyond\nbicycle\nbid\nbike\nbind\nbiology\nbird\nbirth\nbitter\nblack\nblade\nblame\nblanket\nblast\nbleak\nbless\nblind\nblood\nblossom\nblouse\nblue\nblur\nblush\nboard\nboat\nbody\nboil\nbomb\nbone\nbonus\nbook\nboost\nborder\nboring\nborrow\nboss\nbottom\nbounce\nbox\nboy\nbracket\nbrain\nbrand\nbrass\nbrave\nbread\nbreeze\nbrick\nbridge\nbrief\nbright\nbring\nbrisk\nbroccoli\nbroken\nbronze\nbroom\nbrother\nbrown\nbrush\nbubble\nbuddy\nbudget\nbuffalo\nbuild\nbulb\nbulk\nbullet\nbundle\nbunker\nburden\nburger\nburst\nbus\nbusiness\nbusy\nbutter\nbuyer\nbuzz\ncabbage\ncabin\ncable\ncactus\ncage\ncake\ncall\ncalm\ncamera\ncamp\ncan\ncanal\ncancel\ncandy\ncannon\ncanoe\ncanvas\ncanyon\ncapable\ncapital\ncaptain\ncar\ncarbon\ncard\ncargo\ncarpet\ncarry\ncart\ncase\ncash\ncasino\ncastle\ncasual\ncat\ncatalog\ncatch\ncategory\ncattle\ncaught\ncause\ncaution\ncave\nceiling\ncelery\ncement\ncensus\ncentury\ncereal\ncertain\nchair\nchalk\nchampion\nchange\nchaos\nchapter\ncharge\nchase\nchat\ncheap\ncheck\ncheese\nchef\ncherry\nchest\nchicken\nchief\nchild\nchimney\nchoice\nchoose\nchronic\nchuckle\nchunk\nchurn\ncigar\ncinnamon\ncircle\ncitizen\ncity\ncivil\nclaim\nclap\nclarify\nclaw\nclay\nclean\nclerk\nclever\nclick\nclient\ncliff\nclimb\nclinic\nclip\nclock\nclog\nclose\ncloth\ncloud\nclown\nclub\nclump\ncluster\nclutch\ncoach\ncoast\ncoconut\ncode\ncoffee\ncoil\ncoin\ncollect\ncolor\ncolumn\ncombine\ncome\ncomfort\ncomic\ncommon\ncompany\nconcert\nconduct\nconfirm\ncongress\nconnect\nconsider\ncontrol\nconvince\ncook\ncool\ncopper\ncopy\ncoral\ncore\ncorn\ncorrect\ncost\ncotton\ncouch\ncountry\ncouple\ncourse\ncousin\ncover\ncoyote\ncrack\ncradle\ncraft\ncram\ncrane\ncrash\ncrater\ncrawl\ncrazy\ncream\ncredit\ncreek\ncrew\ncricket\ncrime\ncrisp\ncritic\ncrop\ncross\ncrouch\ncrowd\ncrucial\ncruel\ncruise\ncrumble\ncrunch\ncrush\ncry\ncrystal\ncube\nculture\ncup\ncupboard\ncurious\ncurrent\ncurtain\ncurve\ncushion\ncustom\ncute\ncycle\ndad\ndamage\ndamp\ndance\ndanger\ndaring\ndash\ndaughter\ndawn\nday\ndeal\ndebate\ndebris\ndecade\ndecember\ndecide\ndecline\ndecorate\ndecrease\ndeer\ndefense\ndefine\ndefy\ndegree\ndelay\ndeliver\ndemand\ndemise\ndenial\ndentist\ndeny\ndepart\ndepend\ndeposit\ndepth\ndeputy\nderive\ndescribe\ndesert\ndesign\ndesk\ndespair\ndestroy\ndetail\ndetect\ndevelop\ndevice\ndevote\ndiagram\ndial\ndiamond\ndiary\ndice\ndiesel\ndiet\ndiffer\ndigital\ndignity\ndilemma\ndinner\ndinosaur\ndirect\ndirt\ndisagree\ndiscover\ndisease\ndish\ndismiss\ndisorder\ndisplay\ndistance\ndivert\ndivide\ndivorce\ndizzy\ndoctor\ndocument\ndog\ndoll\ndolphin\ndomain\ndonate\ndonkey\ndonor\ndoor\ndose\ndouble\ndove\ndraft\ndragon\ndrama\ndrastic\ndraw\ndream\ndress\ndrift\ndrill\ndrink\ndrip\ndrive\ndrop\ndrum\ndry\nduck\ndumb\ndune\nduring\ndust\ndutch\nduty\ndwarf\ndynamic\neager\neagle\nearly\nearn\nearth\neasily\neast\neasy\necho\necology\neconomy\nedge\nedit\neducate\neffort\negg\neight\neither\nelbow\nelder\nelectric\nelegant\nelement\nelephant\nelevator\nelite\nelse\nembark\nembody\nembrace\nemerge\nemotion\nemploy\nempower\nempty\nenable\nenact\nend\nendless\nendorse\nenemy\nenergy\nenforce\nengage\nengine\nenhance\nenjoy\nenlist\nenough\nenrich\nenroll\nensure\nenter\nentire\nentry\nenvelope\nepisode\nequal\nequip\nera\nerase\nerode\nerosion\nerror\nerupt\nescape\nessay\nessence\nestate\neternal\nethics\nevidence\nevil\nevoke\nevolve\nexact\nexample\nexcess\nexchange\nexcite\nexclude\nexcuse\nexecute\nexercise\nexhaust\nexhibit\nexile\nexist\nexit\nexotic\nexpand\nexpect\nexpire\nexplain\nexpose\nexpress\nextend\nextra\neye\neyebrow\nfabric\nface\nfaculty\nfade\nfaint\nfaith\nfall\nfalse\nfame\nfamily\nfamous\nfan\nfancy\nfantasy\nfarm\nfashion\nfat\nfatal\nfather\nfatigue\nfault\nfavorite\nfeature\nfebruary\nfederal\nfee\nfeed\nfeel\nfemale\nfence\nfestival\nfetch\nfever\nfew\nfiber\nfiction\nfield\nfigure\nfile\nfilm\nfilter\nfinal\nfind\nfine\nfinger\nfinish\nfire\nfirm\nfirst\nfiscal\nfish\nfit\nfitness\nfix\nflag\nflame\nflash\nflat\nflavor\nflee\nflight\nflip\nfloat\nflock\nfloor\nflower\nfluid\nflush\nfly\nfoam\nfocus\nfog\nfoil\nfold\nfollow\nfood\nfoot\nforce\nforest\nforget\nfork\nfortune\nforum\nforward\nfossil\nfoster\nfound\nfox\nfragile\nframe\nfrequent\nfresh\nfriend\nfringe\nfrog\nfront\nfrost\nfrown\nfrozen\nfruit\nfuel\nfun\nfunny\nfurnace\nfury\nfuture\ngadget\ngain\ngalaxy\ngallery\ngame\ngap\ngarage\ngarbage\ngarden\ngarlic\ngarment\ngas\ngasp\ngate\ngather\ngauge\ngaze\ngeneral\ngenius\ngenre\ngentle\ngenuine\ngesture\nghost\ngiant\ngift\ngiggle\nginger\ngiraffe\ngirl\ngive\nglad\nglance\nglare\nglass\nglide\nglimpse\nglobe\ngloom\nglory\nglove\nglow\nglue\ngoat\ngoddess\ngold\ngood\ngoose\ngorilla\ngospel\ngossip\ngovern\ngown\ngrab\ngrace\ngrain\ngrant\ngrape\ngrass\ngravity\ngreat\ngreen\ngrid\ngrief\ngrit\ngrocery\ngroup\ngrow\ngrunt\nguard\nguess\nguide\nguilt\nguitar\ngun\ngym\nhabit\nhair\nhalf\nhammer\nhamster\nhand\nhappy\nharbor\nhard\nharsh\nharvest\nhat\nhave\nhawk\nhazard\nhead\nhealth\nheart\nheavy\nhedgehog\nheight\nhello\nhelmet\nhelp\nhen\nhero\nhidden\nhigh\nhill\nhint\nhip\nhire\nhistory\nhobby\nhockey\nhold\nhole\nholiday\nhollow\nhome\nhoney\nhood\nhope\nhorn\nhorror\nhorse\nhospital\nhost\nhotel\nhour\nhover\nhub\nhuge\nhuman\nhumble\nhumor\nhundred\nhungry\nhunt\nhurdle\nhurry\nhurt\nhusband\nhybrid\nice\nicon\nidea\nidentify\nidle\nignore\nill\nillegal\nillness\nimage\nimitate\nimmense\nimmune\nimpact\nimpose\nimprove\nimpulse\ninch\ninclude\nincome\nincrease\nindex\nindicate\nindoor\nindustry\ninfant\ninflict\ninform\ninhale\ninherit\ninitial\ninject\ninjury\ninmate\ninner\ninnocent\ninput\ninquiry\ninsane\ninsect\ninside\ninspire\ninstall\nintact\ninterest\ninto\ninvest\ninvite\ninvolve\niron\nisland\nisolate\nissue\nitem\nivory\njacket\njaguar\njar\njazz\njealous\njeans\njelly\njewel\njob\njoin\njoke\njourney\njoy\njudge\njuice\njump\njungle\njunior\njunk\njust\nkangaroo\nkeen\nkeep\nketchup\nkey\nkick\nkid\nkidney\nkind\nkingdom\nkiss\nkit\nkitchen\nkite\nkitten\nkiwi\nknee\nknife\nknock\nknow\nlab\nlabel\nlabor\nladder\nlady\nlake\nlamp\nlanguage\nlaptop\nlarge\nlater\nlatin\nlaugh\nlaundry\nlava\nlaw\nlawn\nlawsuit\nlayer\nlazy\nleader\nleaf\nlearn\nleave\nlecture\nleft\nleg\nlegal\nlegend\nleisure\nlemon\nlend\nlength\nlens\nleopard\nlesson\nletter\nlevel\nliar\nliberty\nlibrary\nlicense\nlife\nlift\nlight\nlike\nlimb\nlimit\nlink\nlion\nliquid\nlist\nlittle\nlive\nlizard\nload\nloan\nlobster\nlocal\nlock\nlogic\nlonely\nlong\nloop\nlottery\nloud\nlounge\nlove\nloyal\nlucky\nluggage\nlumber\nlunar\nlunch\nluxury\nlyrics\nmachine\nmad\nmagic\nmagnet\nmaid\nmail\nmain\nmajor\nmake\nmammal\nman\nmanage\nmandate\nmango\nmansion\nmanual\nmaple\nmarble\nmarch\nmargin\nmarine\nmarket\nmarriage\nmask\nmass\nmaster\nmatch\nmaterial\nmath\nmatrix\nmatter\nmaximum\nmaze\nmeadow\nmean\nmeasure\nmeat\nmechanic\nmedal\nmedia\nmelody\nmelt\nmember\nmemory\nmention\nmenu\nmercy\nmerge\nmerit\nmerry\nmesh\nmessage\nmetal\nmethod\nmiddle\nmidnight\nmilk\nmillion\nmimic\nmind\nminimum\nminor\nminute\nmiracle\nmirror\nmisery\nmiss\nmistake\nmix\nmixed\nmixture\nmobile\nmodel\nmodify\nmom\nmoment\nmonitor\nmonkey\nmonster\nmonth\nmoon\nmoral\nmore\nmorning\nmosquito\nmother\nmotion\nmotor\nmountain\nmouse\nmove\nmovie\nmuch\nmuffin\nmule\nmultiply\nmuscle\nmuseum\nmushroom\nmusic\nmust\nmutual\nmyself\nmystery\nmyth\nnaive\nname\nnapkin\nnarrow\nnasty\nnation\nnature\nnear\nneck\nneed\nnegative\nneglect\nneither\nnephew\nnerve\nnest\nnet\nnetwork\nneutral\nnever\nnews\nnext\nnice\nnight\nnoble\nnoise\nnominee\nnoodle\nnormal\nnorth\nnose\nnotable\nnote\nnothing\nnotice\nnovel\nnow\nnuclear\nnumber\nnurse\nnut\noak\nobey\nobject\noblige\nobscure\nobserve\nobtain\nobvious\noccur\nocean\noctober\nodor\noff\noffer\noffice\noften\noil\nokay\nold\nolive\nolympic\nomit\nonce\none\nonion\nonline\nonly\nopen\nopera\nopinion\noppose\noption\norange\norbit\norchard\norder\nordinary\norgan\norient\noriginal\norphan\nostrich\nother\noutdoor\nouter\noutput\noutside\noval\noven\nover\nown\nowner\noxygen\noyster\nozone\npact\npaddle\npage\npair\npalace\npalm\npanda\npanel\npanic\npanther\npaper\nparade\nparent\npark\nparrot\nparty\npass\npatch\npath\npatient\npatrol\npattern\npause\npave\npayment\npeace\npeanut\npear\npeasant\npelican\npen\npenalty\npencil\npeople\npepper\nperfect\npermit\nperson\npet\nphone\nphoto\nphrase\nphysical\npiano\npicnic\npicture\npiece\npig\npigeon\npill\npilot\npink\npioneer\npipe\npistol\npitch\npizza\nplace\nplanet\nplastic\nplate\nplay\nplease\npledge\npluck\nplug\nplunge\npoem\npoet\npoint\npolar\npole\npolice\npond\npony\npool\npopular\nportion\nposition\npossible\npost\npotato\npottery\npoverty\npowder\npower\npractice\npraise\npredict\nprefer\nprepare\npresent\npretty\nprevent\nprice\npride\nprimary\nprint\npriority\nprison\nprivate\nprize\nproblem\nprocess\nproduce\nprofit\nprogram\nproject\npromote\nproof\nproperty\nprosper\nprotect\nproud\nprovide\npublic\npudding\npull\npulp\npulse\npumpkin\npunch\npupil\npuppy\npurchase\npurity\npurpose\npurse\npush\nput\npuzzle\npyramid\nquality\nquantum\nquarter\nquestion\nquick\nquit\nquiz\nquote\nrabbit\nraccoon\nrace\nrack\nradar\nradio\nrail\nrain\nraise\nrally\nramp\nranch\nrandom\nrange\nrapid\nrare\nrate\nrather\nraven\nraw\nrazor\nready\nreal\nreason\nrebel\nrebuild\nrecall\nreceive\nrecipe\nrecord\nrecycle\nreduce\nreflect\nreform\nrefuse\nregion\nregret\nregular\nreject\nrelax\nrelease\nrelief\nrely\nremain\nremember\nremind\nremove\nrender\nrenew\nrent\nreopen\nrepair\nrepeat\nreplace\nreport\nrequire\nrescue\nresemble\nresist\nresource\nresponse\nresult\nretire\nretreat\nreturn\nreunion\nreveal\nreview\nreward\nrhythm\nrib\nribbon\nrice\nrich\nride\nridge\nrifle\nright\nrigid\nring\nriot\nripple\nrisk\nritual\nrival\nriver\nroad\nroast\nrobot\nrobust\nrocket\nromance\nroof\nrookie\nroom\nrose\nrotate\nrough\nround\nroute\nroyal\nrubber\nrude\nrug\nrule\nrun\nrunway\nrural\nsad\nsaddle\nsadness\nsafe\nsail\nsalad\nsalmon\nsalon\nsalt\nsalute\nsame\nsample\nsand\nsatisfy\nsatoshi\nsauce\nsausage\nsave\nsay\nscale\nscan\nscare\nscatter\nscene\nscheme\nschool\nscience\nscissors\nscorpion\nscout\nscrap\nscreen\nscript\nscrub\nsea\nsearch\nseason\nseat\nsecond\nsecret\nsection\nsecurity\nseed\nseek\nsegment\nselect\nsell\nseminar\nsenior\nsense\nsentence\nseries\nservice\nsession\nsettle\nsetup\nseven\nshadow\nshaft\nshallow\nshare\nshed\nshell\nsheriff\nshield\nshift\nshine\nship\nshiver\nshock\nshoe\nshoot\nshop\nshort\nshoulder\nshove\nshrimp\nshrug\nshuffle\nshy\nsibling\nsick\nside\nsiege\nsight\nsign\nsilent\nsilk\nsilly\nsilver\nsimilar\nsimple\nsince\nsing\nsiren\nsister\nsituate\nsix\nsize\nskate\nsketch\nski\nskill\nskin\nskirt\nskull\nslab\nslam\nsleep\nslender\nslice\nslide\nslight\nslim\nslogan\nslot\nslow\nslush\nsmall\nsmart\nsmile\nsmoke\nsmooth\nsnack\nsnake\nsnap\nsniff\nsnow\nsoap\nsoccer\nsocial\nsock\nsoda\nsoft\nsolar\nsoldier\nsolid\nsolution\nsolve\nsomeone\nsong\nsoon\nsorry\nsort\nsoul\nsound\nsoup\nsource\nsouth\nspace\nspare\nspatial\nspawn\nspeak\nspecial\nspeed\nspell\nspend\nsphere\nspice\nspider\nspike\nspin\nspirit\nsplit\nspoil\nsponsor\nspoon\nsport\nspot\nspray\nspread\nspring\nspy\nsquare\nsqueeze\nsquirrel\nstable\nstadium\nstaff\nstage\nstairs\nstamp\nstand\nstart\nstate\nstay\nsteak\nsteel\nstem\nstep\nstereo\nstick\nstill\nsting\nstock\nstomach\nstone\nstool\nstory\nstove\nstrategy\nstreet\nstrike\nstrong\nstruggle\nstudent\nstuff\nstumble\nstyle\nsubject\nsubmit\nsubway\nsuccess\nsuch\nsudden\nsuffer\nsugar\nsuggest\nsuit\nsummer\nsun\nsunny\nsunset\nsuper\nsupply\nsupreme\nsure\nsurface\nsurge\nsurprise\nsurround\nsurvey\nsuspect\nsustain\nswallow\nswamp\nswap\nswarm\nswear\nsweet\nswift\nswim\nswing\nswitch\nsword\nsymbol\nsymptom\nsyrup\nsystem\ntable\ntackle\ntag\ntail\ntalent\ntalk\ntank\ntape\ntarget\ntask\ntaste\ntattoo\ntaxi\nteach\nteam\ntell\nten\ntenant\ntennis\ntent\nterm\ntest\ntext\nthank\nthat\ntheme\nthen\ntheory\nthere\nthey\nthing\nthis\nthought\nthree\nthrive\nthrow\nthumb\nthunder\nticket\ntide\ntiger\ntilt\ntimber\ntime\ntiny\ntip\ntired\ntissue\ntitle\ntoast\ntobacco\ntoday\ntoddler\ntoe\ntogether\ntoilet\ntoken\ntomato\ntomorrow\ntone\ntongue\ntonight\ntool\ntooth\ntop\ntopic\ntopple\ntorch\ntornado\ntortoise\ntoss\ntotal\ntourist\ntoward\ntower\ntown\ntoy\ntrack\ntrade\ntraffic\ntragic\ntrain\ntransfer\ntrap\ntrash\ntravel\ntray\ntreat\ntree\ntrend\ntrial\ntribe\ntrick\ntrigger\ntrim\ntrip\ntrophy\ntrouble\ntruck\ntrue\ntruly\ntrumpet\ntrust\ntruth\ntry\ntube\ntuition\ntumble\ntuna\ntunnel\nturkey\nturn\nturtle\ntwelve\ntwenty\ntwice\ntwin\ntwist\ntwo\ntype\ntypical\nugly\numbrella\nunable\nunaware\nuncle\nuncover\nunder\nundo\nunfair\nunfold\nunhappy\nuniform\nunique\nunit\nuniverse\nunknown\nunlock\nuntil\nunusual\nunveil\nupdate\nupgrade\nuphold\nupon\nupper\nupset\nurban\nurge\nusage\nuse\nused\nuseful\nuseless\nusual\nutility\nvacant\nvacuum\nvague\nvalid\nvalley\nvalve\nvan\nvanish\nvapor\nvarious\nvast\nvault\nvehicle\nvelvet\nvendor\nventure\nvenue\nverb\nverify\nversion\nvery\nvessel\nveteran\nviable\nvibrant\nvicious\nvictory\nvideo\nview\nvillage\nvintage\nviolin\nvirtual\nvirus\nvisa\nvisit\nvisual\nvital\nvivid\nvocal\nvoice\nvoid\nvolcano\nvolume\nvote\nvoyage\nwage\nwagon\nwait\nwalk\nwall\nwalnut\nwant\nwarfare\nwarm\nwarrior\nwash\nwasp\nwaste\nwater\nwave\nway\nwealth\nweapon\nwear\nweasel\nweather\nweb\nwedding\nweekend\nweird\nwelcome\nwest\nwet\nwhale\nwhat\nwheat\nwheel\nwhen\nwhere\nwhip\nwhisper\nwide\nwidth\nwife\nwild\nwill\nwin\nwindow\nwine\nwing\nwink\nwinner\nwinter\nwire\nwisdom\nwise\nwish\nwitness\nwolf\nwoman\nwonder\nwood\nwool\nword\nwork\nworld\nworry\nworth\nwrap\nwreck\nwrestle\nwrist\nwrite\nwrong\nyard\nyear\nyellow\nyou\nyoung\nyouth\nzebra\nzero\nzone\nzoo".split("\n");function number$1(o){if(!Number.isSafeInteger(o)||o<0)throw new Error(`Wrong positive integer: ${o}`)}function bool$1(o){if("boolean"!=typeof o)throw new Error(`Expected boolean, not ${o}`)}function isBytes$2(o){return o instanceof Uint8Array||null!=o&&"object"==typeof o&&"Uint8Array"===o.constructor.name}function bytes$1(o,...s){if(!isBytes$2(o))throw new Error("Expected Uint8Array");if(s.length>0&&!s.includes(o.length))throw new Error(`Expected Uint8Array of length ${s}, not of length=${o.length}`)}function hash$1(o){if("function"!=typeof o||"function"!=typeof o.create)throw new Error("Hash should be wrapped by utils.wrapConstructor");number$1(o.outputLen),number$1(o.blockLen)}function exists$1(o,s=!0){if(o.destroyed)throw new Error("Hash instance has been destroyed");if(s&&o.finished)throw new Error("Hash#digest() has already been called")}function output$1(o,s){bytes$1(o);const r=s.outputLen;if(o.lengthnew DataView(o.buffer,o.byteOffset,o.byteLength),rotr=(o,s)=>o<<32-s|o>>>s,isLE$1=68===new Uint8Array(new Uint32Array([287454020]).buffer)[0];if(!isLE$1)throw new Error("Non little-endian hardware is not supported");const hexes=Array.from({length:256},(o,s)=>s.toString(16).padStart(2,"0"));function bytesToHex(o){if(!isBytes$1(o))throw new Error("Uint8Array expected");let s="";for(let r=0;r=asciis._0&&o<=asciis._9?o-asciis._0:o>=asciis._A&&o<=asciis._F?o-(asciis._A-10):o>=asciis._a&&o<=asciis._f?o-(asciis._a-10):void 0}function hexToBytes(o){if("string"!=typeof o)throw new Error("hex string expected, got "+typeof o);const s=o.length,r=s/2;if(s%2)throw new Error("padded hex string expected, got unpadded hex of length "+s);const i=new Uint8Array(r);for(let a=0,c=0;ao().update(toBytes$1(i)).digest(),r=o();return s.outputLen=r.outputLen,s.blockLen=r.blockLen,s.create=()=>o(),s}function randomBytes(o=32){if(crypto$1&&"function"==typeof crypto$1.getRandomValues)return crypto$1.getRandomValues(new Uint8Array(o));throw new Error("crypto.getRandomValues must be defined")}let HMAC$1=class extends Hash{constructor(o,s){super(),this.finished=!1,this.destroyed=!1,hash$1(o);const r=toBytes$1(s);if(this.iHash=o.create(),"function"!=typeof this.iHash.update)throw new Error("Expected instance of class which extends utils.Hash");this.blockLen=this.iHash.blockLen,this.outputLen=this.iHash.outputLen;const i=this.blockLen,a=new Uint8Array(i);a.set(r.length>i?o.create().update(r).digest():r);for(let c=0;cnew HMAC$1(o,s).update(r).digest();function pbkdf2Init(o,s,r,i){hash$1(o);const a=checkOpts$1({dkLen:32,asyncTick:10},i),{c,dkLen:y,asyncTick:w}=a;if(number$1(c),number$1(y),number$1(w),c<1)throw new Error("PBKDF2: iterations (c) should be >= 1");const C=toBytes$1(s),T=toBytes$1(r),S=new Uint8Array(y),M=hmac$1.create(o,C),O=M._cloneInto().update(T);return{c,dkLen:y,asyncTick:w,DK:S,PRF:M,PRFSalt:O}}function pbkdf2Output(o,s,r,i,a){return o.destroy(),s.destroy(),i&&i.destroy(),a.fill(0),r}function pbkdf2(o,s,r,i){const{c:a,dkLen:c,DK:y,PRF:w,PRFSalt:C}=pbkdf2Init(o,s,r,i);let T;const S=new Uint8Array(4),M=createView(S),O=new Uint8Array(w.outputLen);for(let L=1,Z=0;Z>a&c),w=Number(r&c),T=i?0:4;o.setUint32(s+(i?4:0),y,i),o.setUint32(s+T,w,i)}hmac$1.create=(o,s)=>new HMAC$1(o,s);class SHA2 extends Hash{constructor(s,r,i,a){super(),this.blockLen=s,this.outputLen=r,this.padOffset=i,this.isLE=a,this.finished=!1,this.length=0,this.pos=0,this.destroyed=!1,this.buffer=new Uint8Array(s),this.view=createView(this.buffer)}update(s){exists$1(this);const{view:r,buffer:i,blockLen:a}=this,c=(s=toBytes$1(s)).length;for(let y=0;ya-y&&(this.process(i,0),y=0);for(let M=y;MS.length)throw new Error("_sha2: outputLen bigger than state");for(let M=0;Mo&s^~o&r,Maj=(o,s,r)=>o&s^o&r^s&r,SHA256_K=new Uint32Array([1116352408,1899447441,3049323471,3921009573,961987163,1508970993,2453635748,2870763221,3624381080,310598401,607225278,1426881987,1925078388,2162078206,2614888103,3248222580,3835390401,4022224774,264347078,604807628,770255983,1249150122,1555081692,1996064986,2554220882,2821834349,2952996808,3210313671,3336571891,3584528711,113926993,338241895,666307205,773529912,1294757372,1396182291,1695183700,1986661051,2177026350,2456956037,2730485921,2820302411,3259730800,3345764771,3516065817,3600352804,4094571909,275423344,430227734,506948616,659060556,883997877,958139571,1322822218,1537002063,1747873779,1955562222,2024104815,2227730452,2361852424,2428436474,2756734187,3204031479,3329325298]),IV=new Uint32Array([1779033703,3144134277,1013904242,2773480762,1359893119,2600822924,528734635,1541459225]),SHA256_W=new Uint32Array(64);class SHA256 extends SHA2{constructor(){super(64,32,8,!1),this.A=0|IV[0],this.B=0|IV[1],this.C=0|IV[2],this.D=0|IV[3],this.E=0|IV[4],this.F=0|IV[5],this.G=0|IV[6],this.H=0|IV[7]}get(){const{A:s,B:r,C:i,D:a,E:c,F:y,G:w,H:C}=this;return[s,r,i,a,c,y,w,C]}set(s,r,i,a,c,y,w,C){this.A=0|s,this.B=0|r,this.C=0|i,this.D=0|a,this.E=0|c,this.F=0|y,this.G=0|w,this.H=0|C}process(s,r){for(let M=0;M<16;M++,r+=4)SHA256_W[M]=s.getUint32(r,!1);for(let M=16;M<64;M++){const O=SHA256_W[M-15],L=SHA256_W[M-2],Z=rotr(O,7)^rotr(O,18)^O>>>3,q=rotr(L,17)^rotr(L,19)^L>>>10;SHA256_W[M]=q+SHA256_W[M-7]+Z+SHA256_W[M-16]|0}let{A:i,B:a,C:c,D:y,E:w,F:C,G:T,H:S}=this;for(let M=0;M<64;M++){const O=S+(rotr(w,6)^rotr(w,11)^rotr(w,25))+Chi(w,C,T)+SHA256_K[M]+SHA256_W[M]|0,L=(rotr(i,2)^rotr(i,13)^rotr(i,22))+Maj(i,a,c)|0;S=T,T=C,C=w,w=y+O|0,y=c,c=a,a=i,i=O+L|0}i=i+this.A|0,a=a+this.B|0,c=c+this.C|0,y=y+this.D|0,w=w+this.E|0,C=C+this.F|0,T=T+this.G|0,S=S+this.H|0,this.set(i,a,c,y,w,C,T,S)}roundClean(){SHA256_W.fill(0)}destroy(){this.set(0,0,0,0,0,0,0,0),this.buffer.fill(0)}}const sha256=wrapConstructor(()=>new SHA256),U32_MASK64=BigInt(2**32-1),_32n=BigInt(32);function fromBig(o,s=!1){return s?{h:Number(o&U32_MASK64),l:Number(o>>_32n&U32_MASK64)}:{h:0|Number(o>>_32n&U32_MASK64),l:0|Number(o&U32_MASK64)}}function split(o,s=!1){let r=new Uint32Array(o.length),i=new Uint32Array(o.length);for(let a=0;aBigInt(o>>>0)<<_32n|BigInt(s>>>0),shrSH=(o,s,r)=>o>>>r,shrSL=(o,s,r)=>o<<32-r|s>>>r,rotrSH=(o,s,r)=>o>>>r|s<<32-r,rotrSL=(o,s,r)=>o<<32-r|s>>>r,rotrBH=(o,s,r)=>o<<64-r|s>>>r-32,rotrBL=(o,s,r)=>o>>>r-32|s<<64-r,rotr32H=(o,s)=>s,rotr32L=(o,s)=>o,rotlSH=(o,s,r)=>o<>>32-r,rotlSL=(o,s,r)=>s<>>32-r,rotlBH=(o,s,r)=>s<>>64-r,rotlBL=(o,s,r)=>o<>>64-r;function add(o,s,r,i){const a=(s>>>0)+(i>>>0);return{h:o+r+(a/2**32|0)|0,l:0|a}}const add3L=(o,s,r)=>(o>>>0)+(s>>>0)+(r>>>0),add3H=(o,s,r,i)=>s+r+i+(o/2**32|0)|0,add4L=(o,s,r,i)=>(o>>>0)+(s>>>0)+(r>>>0)+(i>>>0),add4H=(o,s,r,i,a)=>s+r+i+a+(o/2**32|0)|0,add5L=(o,s,r,i,a)=>(o>>>0)+(s>>>0)+(r>>>0)+(i>>>0)+(a>>>0),add5H=(o,s,r,i,a,c)=>s+r+i+a+c+(o/2**32|0)|0,u64={fromBig,split,toBig,shrSH,shrSL,rotrSH,rotrSL,rotrBH,rotrBL,rotr32H,rotr32L,rotlSH,rotlSL,rotlBH,rotlBL,add,add3L,add3H,add4L,add4H,add5H,add5L},[SHA512_Kh,SHA512_Kl]=u64.split(["0x428a2f98d728ae22","0x7137449123ef65cd","0xb5c0fbcfec4d3b2f","0xe9b5dba58189dbbc","0x3956c25bf348b538","0x59f111f1b605d019","0x923f82a4af194f9b","0xab1c5ed5da6d8118","0xd807aa98a3030242","0x12835b0145706fbe","0x243185be4ee4b28c","0x550c7dc3d5ffb4e2","0x72be5d74f27b896f","0x80deb1fe3b1696b1","0x9bdc06a725c71235","0xc19bf174cf692694","0xe49b69c19ef14ad2","0xefbe4786384f25e3","0x0fc19dc68b8cd5b5","0x240ca1cc77ac9c65","0x2de92c6f592b0275","0x4a7484aa6ea6e483","0x5cb0a9dcbd41fbd4","0x76f988da831153b5","0x983e5152ee66dfab","0xa831c66d2db43210","0xb00327c898fb213f","0xbf597fc7beef0ee4","0xc6e00bf33da88fc2","0xd5a79147930aa725","0x06ca6351e003826f","0x142929670a0e6e70","0x27b70a8546d22ffc","0x2e1b21385c26c926","0x4d2c6dfc5ac42aed","0x53380d139d95b3df","0x650a73548baf63de","0x766a0abb3c77b2a8","0x81c2c92e47edaee6","0x92722c851482353b","0xa2bfe8a14cf10364","0xa81a664bbc423001","0xc24b8b70d0f89791","0xc76c51a30654be30","0xd192e819d6ef5218","0xd69906245565a910","0xf40e35855771202a","0x106aa07032bbd1b8","0x19a4c116b8d2d0c8","0x1e376c085141ab53","0x2748774cdf8eeb99","0x34b0bcb5e19b48a8","0x391c0cb3c5c95a63","0x4ed8aa4ae3418acb","0x5b9cca4f7763e373","0x682e6ff3d6b2b8a3","0x748f82ee5defb2fc","0x78a5636f43172f60","0x84c87814a1f0ab72","0x8cc702081a6439ec","0x90befffa23631e28","0xa4506cebde82bde9","0xbef9a3f7b2c67915","0xc67178f2e372532b","0xca273eceea26619c","0xd186b8c721c0c207","0xeada7dd6cde0eb1e","0xf57d4f7fee6ed178","0x06f067aa72176fba","0x0a637dc5a2c898a6","0x113f9804bef90dae","0x1b710b35131c471b","0x28db77f523047d84","0x32caab7b40c72493","0x3c9ebe0a15c9bebc","0x431d67c49c100d4c","0x4cc5d4becb3e42b6","0x597f299cfc657e2a","0x5fcb6fab3ad6faec","0x6c44198c4a475817"].map(o=>BigInt(o))),SHA512_W_H=new Uint32Array(80),SHA512_W_L=new Uint32Array(80);class SHA512 extends SHA2{constructor(){super(128,64,16,!1),this.Ah=1779033703,this.Al=-205731576,this.Bh=-1150833019,this.Bl=-2067093701,this.Ch=1013904242,this.Cl=-23791573,this.Dh=-1521486534,this.Dl=1595750129,this.Eh=1359893119,this.El=-1377402159,this.Fh=-1694144372,this.Fl=725511199,this.Gh=528734635,this.Gl=-79577749,this.Hh=1541459225,this.Hl=327033209}get(){const{Ah:s,Al:r,Bh:i,Bl:a,Ch:c,Cl:y,Dh:w,Dl:C,Eh:T,El:S,Fh:M,Fl:O,Gh:L,Gl:Z,Hh:q,Hl:re}=this;return[s,r,i,a,c,y,w,C,T,S,M,O,L,Z,q,re]}set(s,r,i,a,c,y,w,C,T,S,M,O,L,Z,q,re){this.Ah=0|s,this.Al=0|r,this.Bh=0|i,this.Bl=0|a,this.Ch=0|c,this.Cl=0|y,this.Dh=0|w,this.Dl=0|C,this.Eh=0|T,this.El=0|S,this.Fh=0|M,this.Fl=0|O,this.Gh=0|L,this.Gl=0|Z,this.Hh=0|q,this.Hl=0|re}process(s,r){for(let ae=0;ae<16;ae++,r+=4)SHA512_W_H[ae]=s.getUint32(r),SHA512_W_L[ae]=s.getUint32(r+=4);for(let ae=16;ae<80;ae++){const me=0|SHA512_W_H[ae-15],be=0|SHA512_W_L[ae-15],Oe=u64.rotrSH(me,be,1)^u64.rotrSH(me,be,8)^u64.shrSH(me,be,7),xe=u64.rotrSL(me,be,1)^u64.rotrSL(me,be,8)^u64.shrSL(me,be,7),De=0|SHA512_W_H[ae-2],ce=0|SHA512_W_L[ae-2],ue=u64.rotrSH(De,ce,19)^u64.rotrBH(De,ce,61)^u64.shrSH(De,ce,6),Ce=u64.rotrSL(De,ce,19)^u64.rotrBL(De,ce,61)^u64.shrSL(De,ce,6),Be=u64.add4L(xe,Ce,SHA512_W_L[ae-7],SHA512_W_L[ae-16]),at=u64.add4H(Be,Oe,ue,SHA512_W_H[ae-7],SHA512_W_H[ae-16]);SHA512_W_H[ae]=0|at,SHA512_W_L[ae]=0|Be}let{Ah:i,Al:a,Bh:c,Bl:y,Ch:w,Cl:C,Dh:T,Dl:S,Eh:M,El:O,Fh:L,Fl:Z,Gh:q,Gl:re,Hh:pe,Hl:se}=this;for(let ae=0;ae<80;ae++){const me=u64.rotrSH(M,O,14)^u64.rotrSH(M,O,18)^u64.rotrBH(M,O,41),be=u64.rotrSL(M,O,14)^u64.rotrSL(M,O,18)^u64.rotrBL(M,O,41),Oe=M&L^~M&q,De=u64.add5L(se,be,O&Z^~O&re,SHA512_Kl[ae],SHA512_W_L[ae]),ce=u64.add5H(De,pe,me,Oe,SHA512_Kh[ae],SHA512_W_H[ae]),ue=0|De,Ce=u64.rotrSH(i,a,28)^u64.rotrBH(i,a,34)^u64.rotrBH(i,a,39),Be=u64.rotrSL(i,a,28)^u64.rotrBL(i,a,34)^u64.rotrBL(i,a,39),at=i&c^i&w^c&w,dt=a&y^a&C^y&C;pe=0|q,se=0|re,q=0|L,re=0|Z,L=0|M,Z=0|O,({h:M,l:O}=u64.add(0|T,0|S,0|ce,0|ue)),T=0|w,S=0|C,w=0|c,C=0|y,c=0|i,y=0|a;const bt=u64.add3L(ue,Be,dt);i=u64.add3H(bt,ce,Ce,at),a=0|bt}({h:i,l:a}=u64.add(0|this.Ah,0|this.Al,0|i,0|a)),({h:c,l:y}=u64.add(0|this.Bh,0|this.Bl,0|c,0|y)),({h:w,l:C}=u64.add(0|this.Ch,0|this.Cl,0|w,0|C)),({h:T,l:S}=u64.add(0|this.Dh,0|this.Dl,0|T,0|S)),({h:M,l:O}=u64.add(0|this.Eh,0|this.El,0|M,0|O)),({h:L,l:Z}=u64.add(0|this.Fh,0|this.Fl,0|L,0|Z)),({h:q,l:re}=u64.add(0|this.Gh,0|this.Gl,0|q,0|re)),({h:pe,l:se}=u64.add(0|this.Hh,0|this.Hl,0|pe,0|se)),this.set(i,a,c,y,w,C,T,S,M,O,L,Z,q,re,pe,se)}roundClean(){SHA512_W_H.fill(0),SHA512_W_L.fill(0)}destroy(){this.buffer.fill(0),this.set(0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0)}}const sha512=wrapConstructor(()=>new SHA512);function isBytes(o){return o instanceof Uint8Array||null!=o&&"object"==typeof o&&"Uint8Array"===o.constructor.name}function chain(...o){const s=i=>i,r=(i,a)=>c=>i(a(c));return{encode:o.map(i=>i.encode).reduceRight(r,s),decode:o.map(i=>i.decode).reduce(r,s)}}function alphabet(o){return{encode:s=>{if(!Array.isArray(s)||s.length&&"number"!=typeof s[0])throw new Error("alphabet.encode input should be an array of numbers");return s.map(r=>{if(r<0||r>=o.length)throw new Error(`Digit index outside alphabet: ${r} (alphabet: ${o.length})`);return o[r]})},decode:s=>{if(!Array.isArray(s)||s.length&&"string"!=typeof s[0])throw new Error("alphabet.decode input should be array of strings");return s.map(r=>{if("string"!=typeof r)throw new Error(`alphabet.decode: not string element=${r}`);const i=o.indexOf(r);if(-1===i)throw new Error(`Unknown letter: "${r}". Allowed: ${o}`);return i})}}}function join(o=""){if("string"!=typeof o)throw new Error("join separator should be string");return{encode:s=>{if(!Array.isArray(s)||s.length&&"string"!=typeof s[0])throw new Error("join.encode input should be array of strings");for(let r of s)if("string"!=typeof r)throw new Error(`join.encode: non-string input=${r}`);return s.join(o)},decode:s=>{if("string"!=typeof s)throw new Error("join.decode input should be string");return s.split(o)}}}function padding(o,s="="){if("string"!=typeof s)throw new Error("padding chr should be string");return{encode(r){if(!Array.isArray(r)||r.length&&"string"!=typeof r[0])throw new Error("padding.encode input should be array of strings");for(let i of r)if("string"!=typeof i)throw new Error(`padding.encode: non-string input=${i}`);for(;r.length*o%8;)r.push(s);return r},decode(r){if(!Array.isArray(r)||r.length&&"string"!=typeof r[0])throw new Error("padding.encode input should be array of strings");for(let a of r)if("string"!=typeof a)throw new Error(`padding.decode: non-string input=${a}`);let i=r.length;if(i*o%8)throw new Error("Invalid padding: string should have whole number of bytes");for(;i>0&&r[i-1]===s;i--)if(!((i-1)*o%8))throw new Error("Invalid padding: string has too much padding");return r.slice(0,i)}}}function convertRadix(o,s,r){if(s<2)throw new Error(`convertRadix: wrong from=${s}, base cannot be less than 2`);if(r<2)throw new Error(`convertRadix: wrong to=${r}, base cannot be less than 2`);if(!Array.isArray(o))throw new Error("convertRadix: data should be array");if(!o.length)return[];let i=0;const a=[],c=Array.from(o);for(c.forEach(y=>{if(y<0||y>=s)throw new Error(`Wrong integer: ${y}`)});;){let y=0,w=!0;for(let C=i;Cs?gcd(s,o%s):o,radix2carry=(o,s)=>o+(s-gcd(o,s));function convertRadix2(o,s,r,i){if(!Array.isArray(o))throw new Error("convertRadix2: data should be array");if(s<=0||s>32)throw new Error(`convertRadix2: wrong from=${s}`);if(r<=0||r>32)throw new Error(`convertRadix2: wrong to=${r}`);if(radix2carry(s,r)>32)throw new Error(`convertRadix2: carry overflow from=${s} to=${r} carryBits=${radix2carry(s,r)}`);let a=0,c=0;const y=2**r-1,w=[];for(const C of o){if(C>=2**s)throw new Error(`convertRadix2: invalid data word=${C} from=${s}`);if(a=a<32)throw new Error(`convertRadix2: carry overflow pos=${c} from=${s}`);for(c+=s;c>=r;c-=r)w.push((a>>c-r&y)>>>0);a&=2**c-1}if(a=a<=s)throw new Error("Excess padding");if(!i&&a)throw new Error(`Non-zero padding: ${a}`);return i&&c>0&&w.push(a>>>0),w}function radix(o){return{encode:s=>{if(!isBytes(s))throw new Error("radix.encode input should be Uint8Array");return convertRadix(Array.from(s),256,o)},decode:s=>{if(!Array.isArray(s)||s.length&&"number"!=typeof s[0])throw new Error("radix.decode input should be array of numbers");return Uint8Array.from(convertRadix(s,o,256))}}}function radix2(o,s=!1){if(o<=0||o>32)throw new Error("radix2: bits should be in (0..32]");if(radix2carry(8,o)>32||radix2carry(o,8)>32)throw new Error("radix2: carry overflow");return{encode:r=>{if(!isBytes(r))throw new Error("radix2.encode input should be Uint8Array");return convertRadix2(Array.from(r),8,o,!s)},decode:r=>{if(!Array.isArray(r)||r.length&&"number"!=typeof r[0])throw new Error("radix2.decode input should be array of numbers");return Uint8Array.from(convertRadix2(r,o,8,s))}}}function unsafeWrapper(o){if("function"!=typeof o)throw new Error("unsafeWrapper fn should be function");return function(...s){try{return o.apply(null,s)}catch{}}}function checksum(o,s){if("function"!=typeof s)throw new Error("checksum fn should be function");return{encode(r){if(!isBytes(r))throw new Error("checksum.encode: input should be Uint8Array");const i=s(r).slice(0,o),a=new Uint8Array(r.length+o);return a.set(r),a.set(i,r.length),a},decode(r){if(!isBytes(r))throw new Error("checksum.decode: input should be Uint8Array");const i=r.slice(0,-o),a=s(i).slice(0,o),c=r.slice(-o);for(let y=0;ychain(radix(58),alphabet(o),join("")),base58=genBase58("123456789ABCDEFGHJKLMNPQRSTUVWXYZabcdefghijkmnopqrstuvwxyz"),createBase58check=o=>chain(checksum(4,s=>o(o(s))),base58),base58check$1=createBase58check,BECH_ALPHABET=chain(alphabet("qpzry9x8gf2tvdw0s3jn54khce6mua7l"),join("")),POLYMOD_GENERATORS=[996825010,642813549,513874426,1027748829,705979059];function bech32Polymod(o){const s=o>>25;let r=(33554431&o)<<5;for(let i=0;i>i&1)&&(r^=POLYMOD_GENERATORS[i]);return r}function bechChecksum(o,s,r=1){const i=o.length;let a=1;for(let c=0;c126)throw new Error(`Invalid prefix (${o})`);a=bech32Polymod(a)^y>>5}a=bech32Polymod(a);for(let c=0;cC)throw new TypeError(`Wrong string length: ${w.length} (${w}). Expected (8..${C})`);const T=w.toLowerCase();if(w!==T&&w!==w.toUpperCase())throw new Error("String must be lowercase or uppercase");const S=(w=T).lastIndexOf("1");if(0===S||-1===S)throw new Error('Letter "1" must be present between prefix and data only');const M=w.slice(0,S),O=w.slice(S+1);if(O.length<6)throw new Error("Data must be at least 6 characters long");const L=BECH_ALPHABET.decode(O).slice(0,-6),Z=bechChecksum(M,L,s);if(!O.endsWith(Z))throw new Error(`Invalid checksum in ${w}: expected "${Z}"`);return{prefix:M,words:L}}return{encode:function(w,C,T=90){if("string"!=typeof w)throw new Error("bech32.encode prefix should be string, not "+typeof w);if(!Array.isArray(C)||C.length&&"number"!=typeof C[0])throw new Error("bech32.encode words should be array of numbers, not "+typeof C);const S=w.length+7+C.length;if(!1!==T&&S>T)throw new TypeError(`Length ${S} exceeds limit ${T}`);const M=w.toLowerCase(),O=bechChecksum(M,C,s);return`${M}1${BECH_ALPHABET.encode(C)}${O}`},decode:y,decodeToBytes:function(w){const{prefix:C,words:T}=y(w,!1);return{prefix:C,words:T,bytes:i(T)}},decodeUnsafe:unsafeWrapper(y),fromWords:i,fromWordsUnsafe:c,toWords:a}}const bech32=genBech32("bech32"),isJapanese=o=>"\u3042\u3044\u3053\u304f\u3057\u3093"===o[0];function nfkd(o){if("string"!=typeof o)throw new TypeError("Invalid mnemonic type: "+typeof o);return o.normalize("NFKD")}function normalize(o){const s=nfkd(o),r=s.split(" ");if(![12,15,18,21,24].includes(r.length))throw new Error("Invalid mnemonic");return{nfkd:s,words:r}}function assertEntropy(o){assert$1.bytes(o,16,20,24,28,32)}function generateMnemonic(o,s=128){if(assert$1.number(s),s%32!=0||s>256)throw new TypeError("Invalid entropy");return entropyToMnemonic(randomBytes(s/8),o)}const calcChecksum=o=>{const s=8-o.length/4;return new Uint8Array([sha256(o)[0]>>s<{if("string"!=typeof s)throw new Error(`Wordlist: non-string element: ${s}`)}),utils$1.chain(utils$1.checksum(1,calcChecksum),utils$1.radix2(11,!0),utils$1.alphabet(o))}function mnemonicToEntropy(o,s){const{words:r}=normalize(o),i=getCoder(s).decode(r);return assertEntropy(i),i}function entropyToMnemonic(o,s){return assertEntropy(o),getCoder(s).encode(o).join(isJapanese(s)?"\u3000":" ")}function validateMnemonic(o,s){try{mnemonicToEntropy(o,s)}catch{return!1}return!0}const salt=o=>nfkd(`mnemonic${o}`);function mnemonicToSeedSync(o,s=""){return pbkdf2(sha512,normalize(o).nfkd,salt(s),{c:2048,dkLen:64})}const Rho=new Uint8Array([7,4,13,1,10,6,15,3,12,0,9,5,2,14,11,8]),Id=Uint8Array.from({length:16},(o,s)=>s),Pi=Id.map(o=>(9*o+5)%16);let idxL=[Id],idxR=[Pi];for(let o=0;o<4;o++)for(let s of[idxL,idxR])s.push(s[o].map(r=>Rho[r]));const shifts=[[11,14,15,12,5,8,7,9,11,13,14,15,6,7,9,8],[12,13,11,15,6,9,9,7,12,15,11,13,7,8,7,7],[13,15,14,11,7,7,6,8,13,14,13,12,5,5,6,9],[14,11,12,14,8,6,5,5,15,12,15,14,9,9,8,6],[15,12,13,13,9,5,8,6,14,11,12,11,8,6,5,5]].map(o=>new Uint8Array(o)),shiftsL=idxL.map((o,s)=>o.map(r=>shifts[s][r])),shiftsR=idxR.map((o,s)=>o.map(r=>shifts[s][r])),Kl=new Uint32Array([0,1518500249,1859775393,2400959708,2840853838]),Kr=new Uint32Array([1352829926,1548603684,1836072691,2053994217,0]),rotl$1=(o,s)=>o<>>32-s;function f(o,s,r,i){return 0===o?s^r^i:1===o?s&r|~s&i:2===o?(s|~r)^i:3===o?s&i|r&~i:s^(r|~i)}const BUF=new Uint32Array(16);class RIPEMD160 extends SHA2{constructor(){super(64,20,8,!0),this.h0=1732584193,this.h1=-271733879,this.h2=-1732584194,this.h3=271733878,this.h4=-1009589776}get(){const{h0:s,h1:r,h2:i,h3:a,h4:c}=this;return[s,r,i,a,c]}set(s,r,i,a,c){this.h0=0|s,this.h1=0|r,this.h2=0|i,this.h3=0|a,this.h4=0|c}process(s,r){for(let L=0;L<16;L++,r+=4)BUF[L]=s.getUint32(r,!0);let i=0|this.h0,a=i,c=0|this.h1,y=c,w=0|this.h2,C=w,T=0|this.h3,S=T,M=0|this.h4,O=M;for(let L=0;L<5;L++){const Z=4-L,q=Kl[L],re=Kr[L],pe=idxL[L],se=idxR[L],ae=shiftsL[L],me=shiftsR[L];for(let be=0;be<16;be++){const Oe=rotl$1(i+f(L,c,w,T)+BUF[pe[be]]+q,ae[be])+M|0;i=M,M=T,T=0|rotl$1(w,10),w=c,c=Oe}for(let be=0;be<16;be++){const Oe=rotl$1(a+f(Z,y,C,S)+BUF[se[be]]+re,me[be])+O|0;a=O,O=S,S=0|rotl$1(C,10),C=y,y=Oe}}this.set(this.h1+w+S|0,this.h2+T+O|0,this.h3+M+a|0,this.h4+i+y|0,this.h0+c+C|0)}roundClean(){BUF.fill(0)}destroy(){this.destroyed=!0,this.buffer.fill(0),this.set(0,0,0,0,0)}}const ripemd160=wrapConstructor(()=>new RIPEMD160),Point=secp256k1.ProjectivePoint,base58check=base58check$1(sha256);function bytesToNumber(o){return BigInt(`0x${bytesToHex(o)}`)}function numberToBytes(o){return hexToBytes(o.toString(16).padStart(64,"0"))}const MASTER_SECRET=utf8ToBytes$1("Bitcoin seed"),BITCOIN_VERSIONS={private:76066276,public:76067358},HARDENED_OFFSET=2147483648,hash160=o=>ripemd160(sha256(o)),fromU32=o=>createView(o).getUint32(0,!1),toU32=o=>{if(!Number.isSafeInteger(o)||o<0||o>2**32-1)throw new Error(`Invalid number=${o}. Should be from 0 to 2 ** 32 - 1`);const s=new Uint8Array(4);return createView(s).setUint32(0,o,!1),s};class HDKey{get fingerprint(){if(!this.pubHash)throw new Error("No publicKey set!");return fromU32(this.pubHash)}get identifier(){return this.pubHash}get pubKeyHash(){return this.pubHash}get privateKey(){return this.privKeyBytes||null}get publicKey(){return this.pubKey||null}get privateExtendedKey(){const s=this.privateKey;if(!s)throw new Error("No private key");return base58check.encode(this.serialize(this.versions.private,concatBytes(new Uint8Array([0]),s)))}get publicExtendedKey(){if(!this.pubKey)throw new Error("No public key");return base58check.encode(this.serialize(this.versions.public,this.pubKey))}static fromMasterSeed(s,r=BITCOIN_VERSIONS){if(bytes$1(s),8*s.length<128||8*s.length>512)throw new Error(`HDKey: wrong seed length=${s.length}. Should be between 128 and 512 bits; 256 bits is advised)`);const i=hmac$1(sha512,MASTER_SECRET,s);return new HDKey({versions:r,chainCode:i.slice(32),privateKey:i.slice(0,32)})}static fromExtendedKey(s,r=BITCOIN_VERSIONS){const i=base58check.decode(s),a=createView(i),c=a.getUint32(0,!1),y={versions:r,depth:i[4],parentFingerprint:a.getUint32(5,!1),index:a.getUint32(9,!1),chainCode:i.slice(13,45)},w=i.slice(45),C=0===w[0];if(c!==r[C?"private":"public"])throw new Error("Version mismatch");return new HDKey(C?{...y,privateKey:w.slice(1)}:{...y,publicKey:w})}static fromJSON(s){return HDKey.fromExtendedKey(s.xpriv)}constructor(s){if(this.depth=0,this.index=0,this.chainCode=null,this.parentFingerprint=0,!s||"object"!=typeof s)throw new Error("HDKey.constructor must not be called directly");if(this.versions=s.versions||BITCOIN_VERSIONS,this.depth=s.depth||0,this.chainCode=s.chainCode,this.index=s.index||0,this.parentFingerprint=s.parentFingerprint||0,!this.depth&&(this.parentFingerprint||this.index))throw new Error("HDKey: zero depth with non-zero index/parent fingerprint");if(s.publicKey&&s.privateKey)throw new Error("HDKey: publicKey and privateKey at same time.");if(s.privateKey){if(!secp256k1.utils.isValidPrivateKey(s.privateKey))throw new Error("Invalid private key");this.privKey="bigint"==typeof s.privateKey?s.privateKey:bytesToNumber(s.privateKey),this.privKeyBytes=numberToBytes(this.privKey),this.pubKey=secp256k1.getPublicKey(s.privateKey,!0)}else{if(!s.publicKey)throw new Error("HDKey: no public or private key provided");this.pubKey=Point.fromHex(s.publicKey).toRawBytes(!0)}this.pubHash=hash160(this.pubKey)}derive(s){if(!/^[mM]'?/.test(s))throw new Error('Path must start with "m" or "M"');if(/^[mM]'?$/.test(s))return this;const r=s.replace(/^[mM]'?\//,"").split("/");let i=this;for(const a of r){const c=/^(\d+)('?)$/.exec(a);if(!c||3!==c.length)throw new Error(`Invalid child index: ${a}`);let y=+c[1];if(!Number.isSafeInteger(y)||y>=HARDENED_OFFSET)throw new Error("Invalid index");"'"===c[2]&&(y+=HARDENED_OFFSET),i=i.deriveChild(y)}return i}deriveChild(s){if(!this.pubKey||!this.chainCode)throw new Error("No publicKey or chainCode set");let r=toU32(s);if(s>=HARDENED_OFFSET){const w=this.privateKey;if(!w)throw new Error("Could not derive hardened child key");r=concatBytes(new Uint8Array([0]),w,r)}else r=concatBytes(this.pubKey,r);const i=hmac$1(sha512,this.chainCode,r),a=bytesToNumber(i.slice(0,32)),c=i.slice(32);if(!secp256k1.utils.isValidPrivateKey(a))throw new Error("Tweak bigger than curve order");const y={versions:this.versions,chainCode:c,depth:this.depth+1,parentFingerprint:this.fingerprint,index:s};try{if(this.privateKey){const w=mod(this.privKey+a,secp256k1.CURVE.n);if(!secp256k1.utils.isValidPrivateKey(w))throw new Error("The tweak was out of range or the resulted private key is invalid");y.privateKey=w}else{const w=Point.fromHex(this.pubKey).add(Point.fromPrivateKey(a));if(w.equals(Point.ZERO))throw new Error("The tweak was equal to negative P, which made the result key invalid");y.publicKey=w.toRawBytes(!0)}return new HDKey(y)}catch{return this.deriveChild(s+1)}}sign(s){if(!this.privateKey)throw new Error("No privateKey set!");return bytes$1(s,32),secp256k1.sign(s,this.privKey).toCompactRawBytes()}verify(s,r){if(bytes$1(s,32),bytes$1(r,64),!this.publicKey)throw new Error("No publicKey set!");let i;try{i=secp256k1.Signature.fromCompact(r)}catch{return!1}return secp256k1.verify(i,s,this.publicKey)}wipePrivateData(){return this.privKey=void 0,this.privKeyBytes&&(this.privKeyBytes.fill(0),this.privKeyBytes=void 0),this}toJSON(){return{xpriv:this.privateExtendedKey,xpub:this.publicExtendedKey}}serialize(s,r){if(!this.chainCode)throw new Error("No chainCode set");return bytes$1(r,33),concatBytes(toU32(s),new Uint8Array([this.depth]),toU32(this.parentFingerprint),toU32(this.index),this.chainCode,r)}}const u8a=o=>o instanceof Uint8Array,u32=o=>new Uint32Array(o.buffer,o.byteOffset,Math.floor(o.byteLength/4)),isLE=68===new Uint8Array(new Uint32Array([287454020]).buffer)[0];if(!isLE)throw new Error("Non little-endian hardware is not supported");function utf8ToBytes(o){if("string"!=typeof o)throw new Error("utf8ToBytes expected string, got "+typeof o);return new Uint8Array((new TextEncoder).encode(o))}function toBytes(o){if("string"==typeof o&&(o=utf8ToBytes(o)),!u8a(o))throw new Error("expected Uint8Array, got "+typeof o);return o}const isPlainObject=o=>"[object Object]"===Object.prototype.toString.call(o)&&o.constructor===Object;function checkOpts(o,s){if(void 0!==s&&("object"!=typeof s||!isPlainObject(s)))throw new Error("options must be object or undefined");return Object.assign(o,s)}function ensureBytes(o,s){if(!(o instanceof Uint8Array))throw new Error("Uint8Array expected");if("number"==typeof s&&o.length!==s)throw new Error(`Uint8Array length ${s} expected`)}function equalBytes(o,s){if(o.length!==s.length)throw new Error("equalBytes: Different size of Uint8Arrays");let r=!0;for(let i=0;i0&&!s.includes(o.length))throw new Error(`Expected Uint8Array of length ${s}, not of length=${o.length}`)}function hash(o){if("function"!=typeof o||"function"!=typeof o.create)throw new Error("hash must be wrapped by utils.wrapConstructor");number(o.outputLen),number(o.blockLen)}function exists(o,s=!0){if(o.destroyed)throw new Error("Hash instance has been destroyed");if(s&&o.finished)throw new Error("Hash#digest() has already been called")}function output(o,s){bytes(o);const r=s.outputLen;if(o.length255&o[s++]|(255&o[s++])<<8;class Poly1305{constructor(s){this.blockLen=16,this.outputLen=16,this.buffer=new Uint8Array(16),this.r=new Uint16Array(10),this.h=new Uint16Array(10),this.pad=new Uint16Array(8),this.pos=0,this.finished=!1,ensureBytes(s=toBytes(s),32);const r=u8to16(s,0),i=u8to16(s,2),a=u8to16(s,4),c=u8to16(s,6),y=u8to16(s,8),w=u8to16(s,10),C=u8to16(s,12),T=u8to16(s,14);this.r[0]=8191&r,this.r[1]=8191&(r>>>13|i<<3),this.r[2]=7939&(i>>>10|a<<6),this.r[3]=8191&(a>>>7|c<<9),this.r[4]=255&(c>>>4|y<<12),this.r[5]=y>>>1&8190,this.r[6]=8191&(y>>>14|w<<2),this.r[7]=8065&(w>>>11|C<<5),this.r[8]=8191&(C>>>8|T<<8),this.r[9]=T>>>5&127;for(let S=0;S<8;S++)this.pad[S]=u8to16(s,16+2*S)}process(s,r,i=!1){const a=i?0:2048,{h:c,r:y}=this,w=y[0],C=y[1],T=y[2],S=y[3],M=y[4],O=y[5],L=y[6],Z=y[7],q=y[8],re=y[9],pe=u8to16(s,r+0),se=u8to16(s,r+2),ae=u8to16(s,r+4),me=u8to16(s,r+6),be=u8to16(s,r+8),Oe=u8to16(s,r+10),xe=u8to16(s,r+12),De=u8to16(s,r+14);let ce=c[0]+(8191&pe),ue=c[1]+(8191&(pe>>>13|se<<3)),Ce=c[2]+(8191&(se>>>10|ae<<6)),Be=c[3]+(8191&(ae>>>7|me<<9)),at=c[4]+(8191&(me>>>4|be<<12)),dt=c[5]+(be>>>1&8191),bt=c[6]+(8191&(be>>>14|Oe<<2)),lt=c[7]+(8191&(Oe>>>11|xe<<5)),rn=c[8]+(8191&(xe>>>8|De<<8)),gn=c[9]+(De>>>5|a),bn=0,Vn=bn+ce*w+ue*(5*re)+Ce*(5*q)+Be*(5*Z)+at*(5*L);bn=Vn>>>13,Vn&=8191,Vn+=dt*(5*O)+bt*(5*M)+lt*(5*S)+rn*(5*T)+gn*(5*C),bn+=Vn>>>13,Vn&=8191;let yn=bn+ce*C+ue*w+Ce*(5*re)+Be*(5*q)+at*(5*Z);bn=yn>>>13,yn&=8191,yn+=dt*(5*L)+bt*(5*O)+lt*(5*M)+rn*(5*S)+gn*(5*T),bn+=yn>>>13,yn&=8191;let qe=bn+ce*T+ue*C+Ce*w+Be*(5*re)+at*(5*q);bn=qe>>>13,qe&=8191,qe+=dt*(5*Z)+bt*(5*L)+lt*(5*O)+rn*(5*M)+gn*(5*S),bn+=qe>>>13,qe&=8191;let _t=bn+ce*S+ue*T+Ce*C+Be*w+at*(5*re);bn=_t>>>13,_t&=8191,_t+=dt*(5*q)+bt*(5*Z)+lt*(5*L)+rn*(5*O)+gn*(5*M),bn+=_t>>>13,_t&=8191;let ze=bn+ce*M+ue*S+Ce*T+Be*C+at*w;bn=ze>>>13,ze&=8191,ze+=dt*(5*re)+bt*(5*q)+lt*(5*Z)+rn*(5*L)+gn*(5*O),bn+=ze>>>13,ze&=8191;let $e=bn+ce*O+ue*M+Ce*S+Be*T+at*C;bn=$e>>>13,$e&=8191,$e+=dt*w+bt*(5*re)+lt*(5*q)+rn*(5*Z)+gn*(5*L),bn+=$e>>>13,$e&=8191;let Ft=bn+ce*L+ue*O+Ce*M+Be*S+at*T;bn=Ft>>>13,Ft&=8191,Ft+=dt*C+bt*w+lt*(5*re)+rn*(5*q)+gn*(5*Z),bn+=Ft>>>13,Ft&=8191;let Ke=bn+ce*Z+ue*L+Ce*O+Be*M+at*S;bn=Ke>>>13,Ke&=8191,Ke+=dt*T+bt*C+lt*w+rn*(5*re)+gn*(5*q),bn+=Ke>>>13,Ke&=8191;let Ze=bn+ce*q+ue*Z+Ce*L+Be*O+at*M;bn=Ze>>>13,Ze&=8191,Ze+=dt*S+bt*T+lt*C+rn*w+gn*(5*re),bn+=Ze>>>13,Ze&=8191;let it=bn+ce*re+ue*q+Ce*Z+Be*L+at*O;bn=it>>>13,it&=8191,it+=dt*M+bt*S+lt*T+rn*C+gn*w,bn+=it>>>13,it&=8191,bn=(bn<<2)+bn|0,bn=bn+Vn|0,Vn=8191&bn,bn>>>=13,yn+=bn,c[0]=Vn,c[1]=yn,c[2]=qe,c[3]=_t,c[4]=ze,c[5]=$e,c[6]=Ft,c[7]=Ke,c[8]=Ze,c[9]=it}finalize(){const{h:s,pad:r}=this,i=new Uint16Array(10);let a=s[1]>>>13;s[1]&=8191;for(let w=2;w<10;w++)s[w]+=a,a=s[w]>>>13,s[w]&=8191;s[0]+=5*a,a=s[0]>>>13,s[0]&=8191,s[1]+=a,a=s[1]>>>13,s[1]&=8191,s[2]+=a,i[0]=s[0]+5,a=i[0]>>>13,i[0]&=8191;for(let w=1;w<10;w++)i[w]=s[w]+a,a=i[w]>>>13,i[w]&=8191;i[9]-=8192;let c=(1^a)-1;for(let w=0;w<10;w++)i[w]&=c;c=~c;for(let w=0;w<10;w++)s[w]=s[w]&c|i[w];s[0]=65535&(s[0]|s[1]<<13),s[1]=65535&(s[1]>>>3|s[2]<<10),s[2]=65535&(s[2]>>>6|s[3]<<7),s[3]=65535&(s[3]>>>9|s[4]<<4),s[4]=65535&(s[4]>>>12|s[5]<<1|s[6]<<14),s[5]=65535&(s[6]>>>2|s[7]<<11),s[6]=65535&(s[7]>>>5|s[8]<<8),s[7]=65535&(s[8]>>>8|s[9]<<5);let y=s[0]+r[0];s[0]=65535&y;for(let w=1;w<8;w++)y=(s[w]+r[w]|0)+(y>>>16)|0,s[w]=65535&y}update(s){assert.exists(this);const{buffer:r,blockLen:i}=this,a=(s=toBytes(s)).length;for(let c=0;c>>0,s[c++]=i[y]>>>8;return s}digest(){const{buffer:s,outputLen:r}=this;this.digestInto(s);const i=s.slice(0,r);return this.destroy(),i}}function wrapConstructorWithKey(o){const s=(i,a)=>o(a).update(toBytes(i)).digest(),r=o(new Uint8Array(32));return s.outputLen=r.outputLen,s.blockLen=r.blockLen,s.create=i=>o(i),s}wrapConstructorWithKey(o=>new Poly1305(o));const sigma16=utf8ToBytes("expand 16-byte k"),sigma32=utf8ToBytes("expand 32-byte k"),sigma16_32=u32(sigma16),sigma32_32=u32(sigma32),isAligned32=o=>!(o.byteOffset%4),salsaBasic=o=>{const{core:s,rounds:r,counterRight:i,counterLen:a,allow128bitKeys:c,extendNonceFn:y,blockLen:w}=checkOpts({rounds:20,counterRight:!1,counterLen:8,allow128bitKeys:!0,blockLen:64},o);assert.number(a),assert.number(r),assert.number(w),assert.bool(i),assert.bool(c);const C=w/4;if(w%4!=0)throw new Error("Salsa/ChaCha: blockLen must be aligned to 4 bytes");return(T,S,M,O,L=0)=>{if(assert.bytes(T),assert.bytes(S),assert.bytes(M),O||(O=new Uint8Array(M.length)),assert.bytes(O),assert.number(L),L<0||L>=2**32-1)throw new Error("Salsa/ChaCha: counter overflow");if(O.length=2**32-1)throw new Error("Salsa/ChaCha: counter overflow");const Ce=Math.min(w,De-ce);if(Ce===w&&xe&&Oe){const Be=ce/4;if(ce%4!=0)throw new Error("Salsa/ChaCha: invalid block position");for(let at=0;ato<>>32-s;function chachaCore(o,s,r,i,a,c=20){let y=o[0],w=o[1],C=o[2],T=o[3],S=s[0],M=s[1],O=s[2],L=s[3],Z=s[4],q=s[5],re=s[6],pe=s[7],se=a,ae=r[0],me=r[1],be=r[2],Oe=y,xe=w,De=C,ce=T,ue=S,Ce=M,Be=O,at=L,dt=Z,bt=q,lt=re,rn=pe,gn=se,bn=ae,Vn=me,yn=be;for(let _t=0;_ta?s.create().update(i).digest():i);for(let y=0;ynew HMAC(o,s).update(r).digest();function extract$1(o,s,r){return assert$2.hash(o),void 0===r&&(r=new Uint8Array(o.outputLen)),hmac(o,toBytes$2(r),toBytes$2(s))}hmac.create=(o,s)=>new HMAC(o,s);const HKDF_COUNTER$1=new Uint8Array([0]),EMPTY_BUFFER$1=new Uint8Array;function expand$1(o,s,r,i=32){if(assert$2.hash(o),assert$2.number(i),i>255*o.outputLen)throw new Error("Length should be <= 255*HashLen");const a=Math.ceil(i/o.outputLen);void 0===r&&(r=EMPTY_BUFFER$1);const c=new Uint8Array(a*o.outputLen),y=hmac.create(o,s),w=y._cloneInto(),C=new Uint8Array(y.outputLen);for(let T=0;Texpand$1(o,extract$1(o,s,r),i,a);var __defProp=Object.defineProperty,__export=(o,s)=>{for(var r in s)__defProp(o,r,{get:s[r],enumerable:!0})};function generatePrivateKey(){return bytesToHex$1(schnorr.utils.randomPrivateKey())}function getPublicKey(o){return bytesToHex$1(schnorr.getPublicKey(o))}var utils_exports={};__export(utils_exports,{MessageNode:()=>MessageNode,MessageQueue:()=>MessageQueue,insertEventIntoAscendingList:()=>insertEventIntoAscendingList,insertEventIntoDescendingList:()=>insertEventIntoDescendingList,normalizeURL:()=>normalizeURL,utf8Decoder:()=>utf8Decoder,utf8Encoder:()=>utf8Encoder});var utf8Decoder=new TextDecoder("utf-8"),utf8Encoder=new TextEncoder;function normalizeURL(o){let s=new URL(o);return s.pathname=s.pathname.replace(/\/+/g,"/"),s.pathname.endsWith("/")&&(s.pathname=s.pathname.slice(0,-1)),("80"===s.port&&"ws:"===s.protocol||"443"===s.port&&"wss:"===s.protocol)&&(s.port=""),s.searchParams.sort(),s.hash="",s.toString()}function insertEventIntoDescendingList(o,s){let r,i=0,a=o.length-1,c=i;if(a<0)c=0;else if(s.created_at=o[i].created_at)c=i;else for(;;){if(a<=i+1){c=a;break}if(r=Math.floor(i+(a-i)/2),o[r].created_at>s.created_at)i=r;else{if(!(o[r].created_ato[a].created_at)c=a+1;else if(s.created_at<=o[i].created_at)c=i;else for(;;){if(a<=i+1){c=a;break}if(r=Math.floor(i+(a-i)/2),o[r].created_ats.created_at)){c=r;break}a=r}}return o[c]?.id!==s.id?[...o.slice(0,c),s,...o.slice(c)]:o}var MessageNode=class{_value;_next;get value(){return this._value}set value(o){this._value=o}get next(){return this._next}set next(o){this._next=o}constructor(o){this._value=o,this._next=null}},MessageQueue=class{_first;_last;get first(){return this._first}set first(o){this._first=o}get last(){return this._last}set last(o){this._last=o}_size;get size(){return this._size}set size(o){this._size=o}constructor(){this._first=null,this._last=null,this._size=0}enqueue(o){const s=new MessageNode(o);return 0!==this._size&&this._last?(this._last.next=s,this._last=s):(this._first=s,this._last=s),this._size++,!0}dequeue(){if(0===this._size||!this._first)return null;let o=this._first;return this._first=o.next,o.next=null,this._size--,o.value}},verifiedSymbol=Symbol("verified");function getBlankEvent(o=255){return{kind:o,content:"",tags:[],created_at:0}}function finishEvent(o,s){const r=o;return r.pubkey=getPublicKey(s),r.id=getEventHash(r),r.sig=getSignature(r,s),r[verifiedSymbol]=!0,r}function serializeEvent(o){if(!validateEvent(o))throw new Error("can't serialize event with wrong or missing properties");return JSON.stringify([0,o.pubkey,o.created_at,o.kind,o.tags,o.content])}function getEventHash(o){return bytesToHex$1(sha256$1(utf8Encoder.encode(serializeEvent(o))))}var isRecord=o=>o instanceof Object;function validateEvent(o){if(!isRecord(o)||"number"!=typeof o.kind||"string"!=typeof o.content||"number"!=typeof o.created_at||"string"!=typeof o.pubkey||!o.pubkey.match(/^[a-f0-9]{64}$/)||!Array.isArray(o.tags))return!1;for(let s=0;ss.id.startsWith(r))||o.kinds&&-1===o.kinds.indexOf(s.kind)||o.authors&&-1===o.authors.indexOf(s.pubkey)&&!o.authors.some(r=>s.pubkey.startsWith(r)))return!1;for(let r in o)if("#"===r[0]){let i=o[`#${r.slice(1)}`];if(i&&!s.tags.find(([a,c])=>a===r.slice(1)&&-1!==i.indexOf(c)))return!1}return!(o.since&&s.created_ato.until)}function matchFilters(o,s){for(let r=0;rgetHex64,getInt:()=>getInt,getSubscriptionId:()=>getSubscriptionId,matchEventId:()=>matchEventId,matchEventKind:()=>matchEventKind,matchEventPubkey:()=>matchEventPubkey});var newListeners=()=>({connect:[],disconnect:[],error:[],notice:[],auth:[]});function relayInit(o,s={}){let{listTimeout:r=3e3,getTimeout:i=3e3,countTimeout:a=3e3}=s;var c,y,w={},C=newListeners(),T={},S={};function M(){return 1===c?.readyState}function O(re){return L.apply(this,arguments)}function L(){return(L=(0,_home_runner_work_angor_hub_angor_hub_node_modules_angular_builders_custom_webpack_node_modules_babel_runtime_helpers_esm_asyncToGenerator_js__WEBPACK_IMPORTED_MODULE_1__.A)(function*(re){let pe=JSON.stringify(re);if(M()||(yield new Promise(se=>setTimeout(se,1e3)),M()))try{c.send(pe)}catch(se){console.log(se)}})).apply(this,arguments)}const Z=(re,{verb:pe="REQ",skipVerification:se=!1,alreadyHaveEvent:ae=null,id:me=Math.random().toString().slice(2)}={})=>{let be=me;w[be]={id:be,filters:re,skipVerification:se,alreadyHaveEvent:ae},O([pe,be,...re]);let Oe={sub:(xe,De={})=>Z(xe||re,{skipVerification:De.skipVerification||se,alreadyHaveEvent:De.alreadyHaveEvent||ae,id:be}),unsub:()=>{delete w[be],delete T[be],O(["CLOSE",be])},on:(xe,De)=>{T[be]=T[be]||{event:[],count:[],eose:[]},T[be][xe].push(De)},off:(xe,De)=>{let ce=T[be],ue=ce[xe].indexOf(De);ue>=0&&ce[xe].splice(ue,1)},get events(){return eventsGenerator(Oe)}};return Oe};function q(re,pe){return new Promise((se,ae)=>{if(!re.id)return void ae(new Error(`event ${re} has no id`));let me=re.id;O([pe,re]),S[me]={resolve:se,reject:ae}})}return{url:o,sub:Z,on:(re,pe)=>{C[re].push(pe),"connect"===re&&1===c?.readyState&&pe()},off:(re,pe)=>{let se=C[re].indexOf(pe);-1!==se&&C[re].splice(se,1)},list:(re,pe)=>new Promise(se=>{let ae=Z(re,pe),me=[],be=setTimeout(()=>{ae.unsub(),se(me)},r);ae.on("eose",()=>{ae.unsub(),clearTimeout(be),se(me)}),ae.on("event",Oe=>{me.push(Oe)})}),get:(re,pe)=>new Promise(se=>{let ae=Z([re],pe),me=setTimeout(()=>{ae.unsub(),se(null)},i);ae.on("event",be=>{ae.unsub(),clearTimeout(me),se(be)})}),count:re=>new Promise(pe=>{let se=Z(re,{...Z,verb:"COUNT"}),ae=setTimeout(()=>{se.unsub(),pe(null)},a);se.on("count",me=>{se.unsub(),clearTimeout(ae),pe(me)})}),publish:re=>(0,_home_runner_work_angor_hub_angor_hub_node_modules_angular_builders_custom_webpack_node_modules_babel_runtime_helpers_esm_asyncToGenerator_js__WEBPACK_IMPORTED_MODULE_1__.A)(function*(){yield q(re,"EVENT")})(),auth:re=>(0,_home_runner_work_angor_hub_angor_hub_node_modules_angular_builders_custom_webpack_node_modules_babel_runtime_helpers_esm_asyncToGenerator_js__WEBPACK_IMPORTED_MODULE_1__.A)(function*(){yield q(re,"AUTH")})(),connect:(re=(0,_home_runner_work_angor_hub_angor_hub_node_modules_angular_builders_custom_webpack_node_modules_babel_runtime_helpers_esm_asyncToGenerator_js__WEBPACK_IMPORTED_MODULE_1__.A)(function*(){M()||(yield(0,_home_runner_work_angor_hub_angor_hub_node_modules_angular_builders_custom_webpack_node_modules_babel_runtime_helpers_esm_asyncToGenerator_js__WEBPACK_IMPORTED_MODULE_1__.A)(function*(){return y||(y=new Promise((pe,se)=>{try{c=new WebSocket(o)}catch(Oe){se(Oe)}c.onopen=()=>{C.connect.forEach(Oe=>Oe()),pe()},c.onerror=()=>{y=void 0,C.error.forEach(Oe=>Oe()),se()},c.onclose=(0,_home_runner_work_angor_hub_angor_hub_node_modules_angular_builders_custom_webpack_node_modules_babel_runtime_helpers_esm_asyncToGenerator_js__WEBPACK_IMPORTED_MODULE_1__.A)(function*(){y=void 0,C.disconnect.forEach(Oe=>Oe())});let ae,me=new MessageQueue;function be(){if(0===me.size)return clearInterval(ae),void(ae=null);var Oe=me.dequeue();if(!Oe)return;let xe=getSubscriptionId(Oe);if(xe){let De=w[xe];if(De&&De.alreadyHaveEvent&&De.alreadyHaveEvent(getHex64(Oe,"id"),o))return}try{let De=JSON.parse(Oe);switch(De[0]){case"EVENT":{let Be=De[1],at=De[2];return void(validateEvent(at)&&w[Be]&&(w[Be].skipVerification||verifySignature(at))&&matchFilters(w[Be].filters,at)&&(T[Be]?.event||[]).forEach(dt=>dt(at)))}case"COUNT":let ce=De[1],ue=De[2];return void(w[ce]&&(T[ce]?.count||[]).forEach(Be=>Be(ue)));case"EOSE":{let Be=De[1];return void(Be in T&&(T[Be].eose.forEach(at=>at()),T[Be].eose=[]))}case"OK":{let Be=De[1],at=De[2],dt=De[3]||"";if(Be in S){let{resolve:bt,reject:lt}=S[Be];at?bt(null):lt(new Error(dt))}return}case"NOTICE":let Ce=De[1];return void C.notice.forEach(Be=>Be(Ce));case"AUTH":{let Be=De[1];return void C.auth?.forEach(at=>at(Be))}}}catch{return}}c.onmessage=Oe=>{me.enqueue(Oe.data),ae||(ae=setInterval(be,0))}}))})())}),function(){return re.apply(this,arguments)}),close(){C=newListeners(),T={},S={},c?.readyState===WebSocket.OPEN&&c.close()},get status(){return c?.readyState??3}};var re}function eventsGenerator(o){return _eventsGenerator.apply(this,arguments)}function _eventsGenerator(){return _eventsGenerator=(0,_home_runner_work_angor_hub_angor_hub_node_modules_angular_builders_custom_webpack_node_modules_babel_runtime_helpers_esm_wrapAsyncGenerator_js__WEBPACK_IMPORTED_MODULE_0__.A)(function*(o){let s;const r=[],i=a=>{s?(s(a),s=void 0):r.push(a)};o.on("event",i);try{for(;;)r.length>0?yield r.shift():yield yield(0,_home_runner_work_angor_hub_angor_hub_node_modules_angular_builders_custom_webpack_node_modules_babel_runtime_helpers_esm_awaitAsyncGenerator_js__WEBPACK_IMPORTED_MODULE_2__.A)(new Promise(c=>{s=c}))}finally{o.off("event",i)}}),_eventsGenerator.apply(this,arguments)}var nip19_exports={};__export(nip19_exports,{BECH32_REGEX:()=>BECH32_REGEX,decode:()=>decode,naddrEncode:()=>naddrEncode,neventEncode:()=>neventEncode,noteEncode:()=>noteEncode,nprofileEncode:()=>nprofileEncode,npubEncode:()=>npubEncode,nrelayEncode:()=>nrelayEncode,nsecEncode:()=>nsecEncode});var Bech32MaxSize=5e3,BECH32_REGEX=/[\x21-\x7E]{1,83}1[023456789acdefghjklmnpqrstuvwxyz]{6,}/;function integerToUint8Array(o){const s=new Uint8Array(4);return s[0]=o>>24&255,s[1]=o>>16&255,s[2]=o>>8&255,s[3]=255&o,s}function decode(o){let{prefix:s,words:r}=bech32$1.decode(o,Bech32MaxSize),i=new Uint8Array(bech32$1.fromWords(r));switch(s){case"nprofile":{let a=parseTLV(i);if(!a[0]?.[0])throw new Error("missing TLV 0 for nprofile");if(32!==a[0][0].length)throw new Error("TLV 0 should be 32 bytes");return{type:"nprofile",data:{pubkey:bytesToHex$1(a[0][0]),relays:a[1]?a[1].map(c=>utf8Decoder.decode(c)):[]}}}case"nevent":{let a=parseTLV(i);if(!a[0]?.[0])throw new Error("missing TLV 0 for nevent");if(32!==a[0][0].length)throw new Error("TLV 0 should be 32 bytes");if(a[2]&&32!==a[2][0].length)throw new Error("TLV 2 should be 32 bytes");if(a[3]&&4!==a[3][0].length)throw new Error("TLV 3 should be 4 bytes");return{type:"nevent",data:{id:bytesToHex$1(a[0][0]),relays:a[1]?a[1].map(c=>utf8Decoder.decode(c)):[],author:a[2]?.[0]?bytesToHex$1(a[2][0]):void 0,kind:a[3]?.[0]?parseInt(bytesToHex$1(a[3][0]),16):void 0}}}case"naddr":{let a=parseTLV(i);if(!a[0]?.[0])throw new Error("missing TLV 0 for naddr");if(!a[2]?.[0])throw new Error("missing TLV 2 for naddr");if(32!==a[2][0].length)throw new Error("TLV 2 should be 32 bytes");if(!a[3]?.[0])throw new Error("missing TLV 3 for naddr");if(4!==a[3][0].length)throw new Error("TLV 3 should be 4 bytes");return{type:"naddr",data:{identifier:utf8Decoder.decode(a[0][0]),pubkey:bytesToHex$1(a[2][0]),kind:parseInt(bytesToHex$1(a[3][0]),16),relays:a[1]?a[1].map(c=>utf8Decoder.decode(c)):[]}}}case"nrelay":{let a=parseTLV(i);if(!a[0]?.[0])throw new Error("missing TLV 0 for nrelay");return{type:"nrelay",data:utf8Decoder.decode(a[0][0])}}case"nsec":case"npub":case"note":return{type:s,data:bytesToHex$1(i)};default:throw new Error(`unknown prefix ${s}`)}}function parseTLV(o){let s={},r=o;for(;r.length>0;){let i=r[0],a=r[1];if(!a)throw new Error(`malformed TLV ${i}`);let c=r.slice(2,2+a);if(r=r.slice(2+a),c.lengthutf8Encoder.encode(s))}))}function neventEncode(o){let s;return null!=o.kind&&(s=integerToUint8Array(o.kind)),encodeBech32("nevent",encodeTLV({0:[hexToBytes$1(o.id)],1:(o.relays||[]).map(r=>utf8Encoder.encode(r)),2:o.author?[hexToBytes$1(o.author)]:[],3:s?[new Uint8Array(s)]:[]}))}function naddrEncode(o){let s=new ArrayBuffer(4);return new DataView(s).setUint32(0,o.kind,!1),encodeBech32("naddr",encodeTLV({0:[utf8Encoder.encode(o.identifier)],1:(o.relays||[]).map(r=>utf8Encoder.encode(r)),2:[hexToBytes$1(o.pubkey)],3:[new Uint8Array(s)]}))}function nrelayEncode(o){return encodeBech32("nrelay",encodeTLV({0:[utf8Encoder.encode(o)]}))}function encodeTLV(o){let s=[];return Object.entries(o).forEach(([r,i])=>{i.forEach(a=>{let c=new Uint8Array(a.length+2);c.set([parseInt(r)],0),c.set([a.length],1),c.set(a,2),s.push(c)})}),concatBytes$1(...s)}var nip04_exports={};function encrypt$1(o,s,r){return _encrypt$.apply(this,arguments)}function _encrypt$(){return _encrypt$=(0,_home_runner_work_angor_hub_angor_hub_node_modules_angular_builders_custom_webpack_node_modules_babel_runtime_helpers_esm_asyncToGenerator_js__WEBPACK_IMPORTED_MODULE_1__.A)(function*(o,s,r){const i=getNormalizedX(secp256k1.getSharedSecret(o,"02"+s));let a=Uint8Array.from(randomBytes$1(16)),c=utf8Encoder.encode(r),y=yield crypto.subtle.importKey("raw",i,{name:"AES-CBC"},!1,["encrypt"]),w=yield crypto.subtle.encrypt({name:"AES-CBC",iv:a},y,c);return`${base64$1.encode(new Uint8Array(w))}?iv=${base64$1.encode(new Uint8Array(a.buffer))}`}),_encrypt$.apply(this,arguments)}function decrypt$1(o,s,r){return _decrypt$.apply(this,arguments)}function _decrypt$(){return _decrypt$=(0,_home_runner_work_angor_hub_angor_hub_node_modules_angular_builders_custom_webpack_node_modules_babel_runtime_helpers_esm_asyncToGenerator_js__WEBPACK_IMPORTED_MODULE_1__.A)(function*(o,s,r){let[i,a]=r.split("?iv="),c=getNormalizedX(secp256k1.getSharedSecret(o,"02"+s)),y=yield crypto.subtle.importKey("raw",c,{name:"AES-CBC"},!1,["decrypt"]),w=base64$1.decode(i),C=base64$1.decode(a),T=yield crypto.subtle.decrypt({name:"AES-CBC",iv:C},y,w);return utf8Decoder.decode(T)}),_decrypt$.apply(this,arguments)}function getNormalizedX(o){return o.slice(1,33)}__export(nip04_exports,{decrypt:()=>decrypt$1,encrypt:()=>encrypt$1}),typeof crypto<"u"&&!crypto.subtle&&crypto.webcrypto&&(crypto.subtle=crypto.webcrypto.subtle);var nip05_exports={};__export(nip05_exports,{NIP05_REGEX:()=>NIP05_REGEX$1,queryProfile:()=>queryProfile,searchDomain:()=>searchDomain,useFetchImplementation:()=>useFetchImplementation});var NIP05_REGEX$1=/^(?:([\w.+-]+)@)?([\w.-]+)$/,_fetch;try{_fetch=fetch}catch{}function useFetchImplementation(o){_fetch=o}function searchDomain(o){return _searchDomain.apply(this,arguments)}function _searchDomain(){return _searchDomain=(0,_home_runner_work_angor_hub_angor_hub_node_modules_angular_builders_custom_webpack_node_modules_babel_runtime_helpers_esm_asyncToGenerator_js__WEBPACK_IMPORTED_MODULE_1__.A)(function*(o,s=""){try{return(yield(yield _fetch(`https://${o}/.well-known/nostr.json?name=${s}`)).json()).names}catch{return{}}}),_searchDomain.apply(this,arguments)}function queryProfile(o){return _queryProfile.apply(this,arguments)}function _queryProfile(){return _queryProfile=(0,_home_runner_work_angor_hub_angor_hub_node_modules_angular_builders_custom_webpack_node_modules_babel_runtime_helpers_esm_asyncToGenerator_js__WEBPACK_IMPORTED_MODULE_1__.A)(function*(o){const s=o.match(NIP05_REGEX$1);if(!s)return null;const[r,i="_",a]=s;try{const c=yield _fetch(`https://${a}/.well-known/nostr.json?name=${i}`),{names:y,relays:w}=parseNIP05Result$1(yield c.json()),C=y[i];return C?{pubkey:C,relays:w?.[C]}:null}catch{return null}}),_queryProfile.apply(this,arguments)}function parseNIP05Result$1(o){const s={names:{}};for(const[r,i]of Object.entries(o.names))"string"==typeof r&&"string"==typeof i&&(s.names[r]=i);if(o.relays){s.relays={};for(const[r,i]of Object.entries(o.relays))"string"==typeof r&&Array.isArray(i)&&(s.relays[r]=i.filter(a=>"string"==typeof a))}return s}var nip06_exports={};function privateKeyFromSeedWords(o,s){let r=HDKey.fromMasterSeed(mnemonicToSeedSync(o,s)).derive("m/44'/1237'/0'/0/0").privateKey;if(!r)throw new Error("could not derive private key");return bytesToHex$1(r)}function generateSeedWords(){return generateMnemonic(wordlist)}function validateWords(o){return validateMnemonic(o,wordlist)}__export(nip06_exports,{generateSeedWords:()=>generateSeedWords,privateKeyFromSeedWords:()=>privateKeyFromSeedWords,validateWords:()=>validateWords});var nip10_exports={};function parse(o){const s={reply:void 0,root:void 0,mentions:[],profiles:[]},r=[];for(const i of o.tags)"e"===i[0]&&i[1]&&r.push(i),"p"===i[0]&&i[1]&&s.profiles.push({pubkey:i[1],relays:i[2]?[i[2]]:[]});for(let i=0;iparse});var nip13_exports={};function getPow(o){let s=0;for(let r=0;r=s)break}return i}__export(nip13_exports,{getPow:()=>getPow,minePow:()=>minePow});var nip18_exports={};function finishRepostEvent(o,s,r,i){return finishEvent({kind:6,tags:[...o.tags??[],["e",s.id,r],["p",s.pubkey]],content:""===o.content?"":JSON.stringify(s),created_at:o.created_at},i)}function getRepostedEventPointer(o){if(6!==o.kind)return;let s,r;for(let i=o.tags.length-1;i>=0&&(void 0===s||void 0===r);i--){const a=o.tags[i];a.length>=2&&("e"===a[0]&&void 0===s?s=a:"p"===a[0]&&void 0===r&&(r=a))}return void 0!==s?{id:s[1],relays:[s[2],r?.[2]].filter(i=>"string"==typeof i),author:r?.[1]}:void 0}function getRepostedEvent(o,{skipVerification:s}={}){const r=getRepostedEventPointer(o);if(void 0===r||""===o.content)return;let i;try{i=JSON.parse(o.content)}catch{return}return i.id===r.id&&(s||verifySignature(i))?i:void 0}__export(nip18_exports,{finishRepostEvent:()=>finishRepostEvent,getRepostedEvent:()=>getRepostedEvent,getRepostedEventPointer:()=>getRepostedEventPointer});var nip21_exports={};__export(nip21_exports,{NOSTR_URI_REGEX:()=>NOSTR_URI_REGEX,parse:()=>parse2,test:()=>test});var NOSTR_URI_REGEX=new RegExp(`nostr:(${BECH32_REGEX.source})`);function test(o){return"string"==typeof o&&new RegExp(`^${NOSTR_URI_REGEX.source}$`).test(o)}function parse2(o){const s=o.match(new RegExp(`^${NOSTR_URI_REGEX.source}$`));if(!s)throw new Error(`Invalid Nostr URI: ${o}`);return{uri:s[0],value:s[1],decoded:decode(s[1])}}var nip25_exports={};function finishReactionEvent(o,s,r){const i=s.tags.filter(a=>a.length>=2&&("e"===a[0]||"p"===a[0]));return finishEvent({...o,kind:7,tags:[...o.tags??[],...i,["e",s.id],["p",s.pubkey]],content:o.content??"+"},r)}function getReactedEventPointer(o){if(7!==o.kind)return;let s,r;for(let i=o.tags.length-1;i>=0&&(void 0===s||void 0===r);i--){const a=o.tags[i];a.length>=2&&("e"===a[0]&&void 0===s?s=a:"p"===a[0]&&void 0===r&&(r=a))}return void 0!==s&&void 0!==r?{id:s[1],relays:[s[2],r[2]].filter(i=>void 0!==i),author:r[1]}:void 0}__export(nip25_exports,{finishReactionEvent:()=>finishReactionEvent,getReactedEventPointer:()=>getReactedEventPointer});var nip26_exports={};function createDelegation(o,s){let r=[];(s.kind||-1)>=0&&r.push(`kind=${s.kind}`),s.until&&r.push(`created_at<${s.until}`),s.since&&r.push(`created_at>${s.since}`);let i=r.join("&");if(""===i)throw new Error("refusing to create a delegation without any conditions");let a=sha256$1(utf8Encoder.encode(`nostr:delegation:${s.pubkey}:${i}`)),c=bytesToHex$1(schnorr.sign(a,o));return{from:getPublicKey(o),to:s.pubkey,cond:i,sig:c}}function getDelegator(o){let s=o.tags.find(w=>"delegation"===w[0]&&w.length>=4);if(!s)return null;let r=s[1],i=s[2],a=s[3],c=i.split("&");for(let w=0;w"===T&&o.created_at>parseInt(S)))return null}let y=sha256$1(utf8Encoder.encode(`nostr:delegation:${o.pubkey}:${i}`));return schnorr.verify(a,y,r)?r:null}__export(nip26_exports,{createDelegation:()=>createDelegation,getDelegator:()=>getDelegator});var nip27_exports={};__export(nip27_exports,{matchAll:()=>matchAll,regex:()=>regex,replaceAll:()=>replaceAll});var regex=()=>new RegExp(`\\b${NOSTR_URI_REGEX.source}\\b`,"g");function*matchAll(o){const s=o.matchAll(regex());for(const r of s)try{const[i,a]=r;yield{uri:i,value:a,decoded:decode(a),start:r.index,end:r.index+i.length}}catch{}}function replaceAll(o,s){return o.replaceAll(regex(),(r,i)=>s({uri:r,value:i,decoded:decode(i)}))}var nip28_exports={};__export(nip28_exports,{channelCreateEvent:()=>channelCreateEvent,channelHideMessageEvent:()=>channelHideMessageEvent,channelMessageEvent:()=>channelMessageEvent,channelMetadataEvent:()=>channelMetadataEvent,channelMuteUserEvent:()=>channelMuteUserEvent});var channelCreateEvent=(o,s)=>{let r;if("object"==typeof o.content)r=JSON.stringify(o.content);else{if("string"!=typeof o.content)return;r=o.content}return finishEvent({kind:40,tags:[...o.tags??[]],content:r,created_at:o.created_at},s)},channelMetadataEvent=(o,s)=>{let r;if("object"==typeof o.content)r=JSON.stringify(o.content);else{if("string"!=typeof o.content)return;r=o.content}return finishEvent({kind:41,tags:[["e",o.channel_create_event_id],...o.tags??[]],content:r,created_at:o.created_at},s)},channelMessageEvent=(o,s)=>{const r=[["e",o.channel_create_event_id,o.relay_url,"root"]];return o.reply_to_channel_message_event_id&&r.push(["e",o.reply_to_channel_message_event_id,o.relay_url,"reply"]),finishEvent({kind:42,tags:[...r,...o.tags??[]],content:o.content,created_at:o.created_at},s)},channelHideMessageEvent=(o,s)=>{let r;if("object"==typeof o.content)r=JSON.stringify(o.content);else{if("string"!=typeof o.content)return;r=o.content}return finishEvent({kind:43,tags:[["e",o.channel_message_event_id],...o.tags??[]],content:r,created_at:o.created_at},s)},channelMuteUserEvent=(o,s)=>{let r;if("object"==typeof o.content)r=JSON.stringify(o.content);else{if("string"!=typeof o.content)return;r=o.content}return finishEvent({kind:44,tags:[["p",o.pubkey_to_mute],...o.tags??[]],content:r,created_at:o.created_at},s)},nip39_exports={},_fetch2;__export(nip39_exports,{useFetchImplementation:()=>useFetchImplementation2,validateGithub:()=>validateGithub});try{_fetch2=fetch}catch{}function useFetchImplementation2(o){_fetch2=o}function validateGithub(o,s,r){return _validateGithub.apply(this,arguments)}function _validateGithub(){return _validateGithub=(0,_home_runner_work_angor_hub_angor_hub_node_modules_angular_builders_custom_webpack_node_modules_babel_runtime_helpers_esm_asyncToGenerator_js__WEBPACK_IMPORTED_MODULE_1__.A)(function*(o,s,r){try{return(yield(yield _fetch2(`https://gist.github.com/${s}/${r}/raw`)).text())===`Verifying that I control the following Nostr public key: ${o}`}catch{return!1}}),_validateGithub.apply(this,arguments)}var nip42_exports={};__export(nip42_exports,{authenticate:()=>authenticate});var authenticate=function(){var o=(0,_home_runner_work_angor_hub_angor_hub_node_modules_angular_builders_custom_webpack_node_modules_babel_runtime_helpers_esm_asyncToGenerator_js__WEBPACK_IMPORTED_MODULE_1__.A)(function*({challenge:s,relay:r,sign:i}){const a={kind:22242,created_at:Math.floor(Date.now()/1e3),tags:[["relay",r.url],["challenge",s]],content:""};return r.auth(yield i(a))});return function(r){return o.apply(this,arguments)}}(),nip44_exports={};__export(nip44_exports,{decrypt:()=>decrypt2,encrypt:()=>encrypt2,utils:()=>utils});var utils={v2:{maxPlaintextSize:65408,minCiphertextSize:100,maxCiphertextSize:102400,getConversationKey:(o,s)=>secp256k1.getSharedSecret(o,"02"+s).subarray(1,33),getMessageKeys(o,s){const r=hkdf(sha256$1,o,s,"nip44-v2",76);return{encryption:r.subarray(0,32),nonce:r.subarray(32,44),auth:r.subarray(44,76)}},calcPadding(o){if(!Number.isSafeInteger(o)||o<0)throw new Error("expected positive integer");if(o<=32)return 32;const s=1<=utils.v2.maxPlaintextSize)throw new Error("invalid plaintext length: must be between 1b and 64KB");const i=utils.v2.calcPadding(r),a=new Uint8Array(i-r),c=new Uint8Array(2);return new DataView(c.buffer).setUint16(0,r),concatBytes$1(c,s,a)},unpad(o){const s=new DataView(o.buffer).getUint16(0),r=o.subarray(2,2+s);if(0===s||r.length!==s||o.length!==2+utils.v2.calcPadding(s))throw new Error("invalid padding");return utf8Decoder.decode(r)}}};function encrypt2(o,s,r={}){const i=r.version??2;if(2!==i)throw new Error("unknown encryption version "+i);const a=r.salt??randomBytes$1(32);ensureBytes(a,32);const c=utils.v2.getMessageKeys(o,a),y=utils.v2.pad(s),w=chacha20(c.encryption,c.nonce,y),C=hmac(sha256$1,c.auth,w);return base64$1.encode(concatBytes$1(new Uint8Array([i]),a,w,C))}function decrypt2(o,s){const r=utils.v2;ensureBytes(o,32);const i=s.length;if(i=r.maxCiphertextSize)throw new Error("invalid ciphertext length: "+i);if("#"===s[0])throw new Error("unknown encryption version");let a;try{a=base64$1.decode(s)}catch(M){throw new Error("invalid base64: "+M.message)}const c=a.subarray(0,1)[0];if(2!==c)throw new Error("unknown encryption version "+c);const y=a.subarray(1,33),w=a.subarray(33,-32),C=a.subarray(-32),T=r.getMessageKeys(o,y);if(!equalBytes(hmac(sha256$1,T.auth,w),C))throw new Error("invalid MAC");const S=chacha20(T.encryption,T.nonce,w);return r.unpad(S)}var nip47_exports={};function parseConnectionString(o){const{pathname:s,searchParams:r}=new URL(o),i=s,a=r.get("relay"),c=r.get("secret");if(!i||!a||!c)throw new Error("invalid connection string");return{pubkey:i,relay:a,secret:c}}function makeNwcRequestEvent(o){return _makeNwcRequestEvent.apply(this,arguments)}function _makeNwcRequestEvent(){return _makeNwcRequestEvent=(0,_home_runner_work_angor_hub_angor_hub_node_modules_angular_builders_custom_webpack_node_modules_babel_runtime_helpers_esm_asyncToGenerator_js__WEBPACK_IMPORTED_MODULE_1__.A)(function*({pubkey:o,secret:s,invoice:r}){const i={method:"pay_invoice",params:{invoice:r}},a=yield encrypt$1(s,o,JSON.stringify(i));return finishEvent({kind:23194,created_at:Math.round(Date.now()/1e3),content:a,tags:[["p",o]]},s)}),_makeNwcRequestEvent.apply(this,arguments)}__export(nip47_exports,{makeNwcRequestEvent:()=>makeNwcRequestEvent,parseConnectionString:()=>parseConnectionString});var nip57_exports={},_fetch3;__export(nip57_exports,{getZapEndpoint:()=>getZapEndpoint,makeZapReceipt:()=>makeZapReceipt,makeZapRequest:()=>makeZapRequest,useFetchImplementation:()=>useFetchImplementation3,validateZapRequest:()=>validateZapRequest});try{_fetch3=fetch}catch{}function useFetchImplementation3(o){_fetch3=o}function getZapEndpoint(o){return _getZapEndpoint.apply(this,arguments)}function _getZapEndpoint(){return _getZapEndpoint=(0,_home_runner_work_angor_hub_angor_hub_node_modules_angular_builders_custom_webpack_node_modules_babel_runtime_helpers_esm_asyncToGenerator_js__WEBPACK_IMPORTED_MODULE_1__.A)(function*(o){try{let s="",{lud06:r,lud16:i}=JSON.parse(o.content);if(r){let{words:y}=bech32$1.decode(r,1e3),w=bech32$1.fromWords(y);s=utf8Decoder.decode(w)}else{if(!i)return null;{let[y,w]=i.split("@");s=`https://${w}/.well-known/lnurlp/${y}`}}let a=yield _fetch3(s),c=yield a.json();if(c.allowsNostr&&c.nostrPubkey)return c.callback}catch{}return null}),_getZapEndpoint.apply(this,arguments)}function makeZapRequest({profile:o,event:s,amount:r,relays:i,comment:a=""}){if(!r)throw new Error("amount not given");if(!o)throw new Error("profile not given");let c={kind:9734,created_at:Math.round(Date.now()/1e3),content:a,tags:[["p",o],["amount",r.toString()],["relays",...i]]};return s&&c.tags.push(["e",s]),c}function validateZapRequest(o){let s;try{s=JSON.parse(o)}catch{return"Invalid zap request JSON."}if(!validateEvent(s))return"Zap request is not a valid Nostr event.";if(!verifySignature(s))return"Invalid signature on zap request.";let r=s.tags.find(([a,c])=>"p"===a&&c);if(!r)return"Zap request doesn't have a 'p' tag.";if(!r[1].match(/^[a-f0-9]{64}$/))return"Zap request 'p' tag is not valid hex.";let i=s.tags.find(([a,c])=>"e"===a&&c);return i&&!i[1].match(/^[a-f0-9]{64}$/)?"Zap request 'e' tag is not valid hex.":s.tags.find(([a,c])=>"relays"===a&&c)?null:"Zap request doesn't have a 'relays' tag."}function makeZapReceipt({zapRequest:o,preimage:s,bolt11:r,paidAt:i}){let a=JSON.parse(o).tags.filter(([y])=>"e"===y||"p"===y||"a"===y),c={kind:9735,created_at:Math.round(i.getTime()/1e3),content:"",tags:[...a,["bolt11",r],["description",o]]};return s&&c.tags.push(["preimage",s]),c}var nip98_exports={};__export(nip98_exports,{getToken:()=>getToken,unpackEventFromToken:()=>unpackEventFromToken,validateEvent:()=>validateEvent2,validateToken:()=>validateToken});var _authorizationScheme="Nostr ";function getToken(o,s,r){return _getToken.apply(this,arguments)}function _getToken(){return _getToken=(0,_home_runner_work_angor_hub_angor_hub_node_modules_angular_builders_custom_webpack_node_modules_babel_runtime_helpers_esm_asyncToGenerator_js__WEBPACK_IMPORTED_MODULE_1__.A)(function*(o,s,r,i=!1){if(!o||!s)throw new Error("Missing loginUrl or httpMethod");const a=getBlankEvent(27235);a.tags=[["u",o],["method",s]],a.created_at=Math.round((new Date).getTime()/1e3);const c=yield r(a);return(i?_authorizationScheme:"")+base64$1.encode(utf8Encoder.encode(JSON.stringify(c)))}),_getToken.apply(this,arguments)}function validateToken(o,s,r){return _validateToken.apply(this,arguments)}function _validateToken(){return _validateToken=(0,_home_runner_work_angor_hub_angor_hub_node_modules_angular_builders_custom_webpack_node_modules_babel_runtime_helpers_esm_asyncToGenerator_js__WEBPACK_IMPORTED_MODULE_1__.A)(function*(o,s,r){const i=yield unpackEventFromToken(o).catch(a=>{throw a});return yield validateEvent2(i,s,r).catch(a=>{throw a})}),_validateToken.apply(this,arguments)}function unpackEventFromToken(o){return _unpackEventFromToken.apply(this,arguments)}function _unpackEventFromToken(){return _unpackEventFromToken=(0,_home_runner_work_angor_hub_angor_hub_node_modules_angular_builders_custom_webpack_node_modules_babel_runtime_helpers_esm_asyncToGenerator_js__WEBPACK_IMPORTED_MODULE_1__.A)(function*(o){if(!o)throw new Error("Missing token");o=o.replace(_authorizationScheme,"");const s=utf8Decoder.decode(base64$1.decode(o));if(!s||0===s.length||!s.startsWith("{"))throw new Error("Invalid token");return JSON.parse(s)}),_unpackEventFromToken.apply(this,arguments)}function validateEvent2(o,s,r){return _validateEvent.apply(this,arguments)}function _validateEvent(){return _validateEvent=(0,_home_runner_work_angor_hub_angor_hub_node_modules_angular_builders_custom_webpack_node_modules_babel_runtime_helpers_esm_asyncToGenerator_js__WEBPACK_IMPORTED_MODULE_1__.A)(function*(o,s,r){if(!o)throw new Error("Invalid nostr event");if(!verifySignature(o))throw new Error("Invalid nostr event, signature invalid");if(27235!==o.kind)throw new Error("Invalid nostr event, kind invalid");if(!o.created_at)throw new Error("Invalid nostr event, created_at invalid");if(Math.round((new Date).getTime()/1e3)-o.created_at>60)throw new Error("Invalid nostr event, expired");const i=o.tags.find(c=>"u"===c[0]);if(1!==i?.length&&i?.[1]!==s)throw new Error("Invalid nostr event, url tag invalid");const a=o.tags.find(c=>"method"===c[0]);if(1!==a?.length&&a?.[1].toLowerCase()!==r.toLowerCase())throw new Error("Invalid nostr event, method tag invalid");return!0}),_validateEvent.apply(this,arguments)}var browser={exports:{}},ms,hasRequiredMs;function requireMs(){if(hasRequiredMs)return ms;hasRequiredMs=1;var o=1e3,s=60*o,r=60*s,i=24*r,a=7*i;function y(w,C,T,S){var M=C>=1.5*T;return Math.round(w/T)+" "+S+(M?"s":"")}return ms=function(w,C){C=C||{};var S,M,T=typeof w;if("string"===T&&w.length>0)return function(S){if(!((S=String(S)).length>100)){var M=/^(-?(?:\d+)?\.?\d+) *(milliseconds?|msecs?|ms|seconds?|secs?|s|minutes?|mins?|m|hours?|hrs?|h|days?|d|weeks?|w|years?|yrs?|y)?$/i.exec(S);if(M){var O=parseFloat(M[1]);switch((M[2]||"ms").toLowerCase()){case"years":case"year":case"yrs":case"yr":case"y":return 315576e5*O;case"weeks":case"week":case"w":return O*a;case"days":case"day":case"d":return O*i;case"hours":case"hour":case"hrs":case"hr":case"h":return O*r;case"minutes":case"minute":case"mins":case"min":case"m":return O*s;case"seconds":case"second":case"secs":case"sec":case"s":return O*o;case"milliseconds":case"millisecond":case"msecs":case"msec":case"ms":return O;default:return}}}}(w);if("number"===T&&isFinite(w))return C.long?(S=w,(M=Math.abs(S))>=i?y(S,M,i,"day"):M>=r?y(S,M,r,"hour"):M>=s?y(S,M,s,"minute"):M>=o?y(S,M,o,"second"):S+" ms"):function(S){var M=Math.abs(S);return M>=i?Math.round(S/i)+"d":M>=r?Math.round(S/r)+"h":M>=s?Math.round(S/s)+"m":M>=o?Math.round(S/o)+"s":S+"ms"}(w);throw new Error("val is not a non-empty string or a valid number. val="+JSON.stringify(w))}}function setup(o){function s(a){let c,y,w,C=null;function T(...S){if(!T.enabled)return;const M=T,O=Number(new Date);M.diff=O-(c||O),M.prev=c,M.curr=O,c=O,S[0]=s.coerce(S[0]),"string"!=typeof S[0]&&S.unshift("%O");let Z=0;S[0]=S[0].replace(/%([a-zA-Z%])/g,(q,re)=>{if("%%"===q)return"%";Z++;const pe=s.formatters[re];return"function"==typeof pe&&(q=pe.call(M,S[Z]),S.splice(Z,1),Z--),q}),s.formatArgs.call(M,S),(M.log||s.log).apply(M,S)}return T.namespace=a,T.useColors=s.useColors(),T.color=s.selectColor(a),T.extend=r,T.destroy=s.destroy,Object.defineProperty(T,"enabled",{enumerable:!0,configurable:!1,get:()=>null!==C?C:(y!==s.namespaces&&(y=s.namespaces,w=s.enabled(a)),w),set:S=>{C=S}}),"function"==typeof s.init&&s.init(T),T}function r(a,c){const y=s(this.namespace+(void 0===c?":":c)+a);return y.log=this.log,y}function i(a){return a.toString().substring(2,a.toString().length-2).replace(/\.\*\?$/,"*")}return s.debug=s,s.default=s,s.coerce=function(a){return a instanceof Error?a.stack||a.message:a},s.disable=function(){const a=[...s.names.map(i),...s.skips.map(i).map(c=>"-"+c)].join(",");return s.enable(""),a},s.enable=function(a){let c;s.save(a),s.namespaces=a,s.names=[],s.skips=[];const y=("string"==typeof a?a:"").split(/[\s,]+/),w=y.length;for(c=0;c{s[a]=o[a]}),s.names=[],s.skips=[],s.formatters={},s.selectColor=function(a){let c=0;for(let y=0;y{"%%"!==w&&(c++,"%c"===w&&(y=c))}),i.splice(y,0,a)},s.save=function(i){try{i?s.storage.setItem("debug",i):s.storage.removeItem("debug")}catch{}},s.load=function(){let i;try{i=s.storage.getItem("debug")}catch{}return!i&&typeof process<"u"&&"env"in process&&(i=process.env.DEBUG),i},s.useColors=function(){return!(!(typeof window<"u"&&window.process)||"renderer"!==window.process.type&&!window.process.__nwjs)||!(typeof navigator<"u"&&navigator.userAgent&&navigator.userAgent.toLowerCase().match(/(edge|trident)\/(\d+)/))&&(typeof document<"u"&&document.documentElement&&document.documentElement.style&&document.documentElement.style.WebkitAppearance||typeof window<"u"&&window.console&&(window.console.firebug||window.console.exception&&window.console.table)||typeof navigator<"u"&&navigator.userAgent&&navigator.userAgent.toLowerCase().match(/firefox\/(\d+)/)&&parseInt(RegExp.$1,10)>=31||typeof navigator<"u"&&navigator.userAgent&&navigator.userAgent.toLowerCase().match(/applewebkit\/(\d+)/))},s.storage=function(){try{return localStorage}catch{}}(),s.destroy=(()=>{let i=!1;return()=>{i||(i=!0,console.warn("Instance method `debug.destroy()` is deprecated and no longer does anything. It will be removed in the next major version of `debug`."))}})(),s.colors=["#0000CC","#0000FF","#0033CC","#0033FF","#0066CC","#0066FF","#0099CC","#0099FF","#00CC00","#00CC33","#00CC66","#00CC99","#00CCCC","#00CCFF","#3300CC","#3300FF","#3333CC","#3333FF","#3366CC","#3366FF","#3399CC","#3399FF","#33CC00","#33CC33","#33CC66","#33CC99","#33CCCC","#33CCFF","#6600CC","#6600FF","#6633CC","#6633FF","#66CC00","#66CC33","#9900CC","#9900FF","#9933CC","#9933FF","#99CC00","#99CC33","#CC0000","#CC0033","#CC0066","#CC0099","#CC00CC","#CC00FF","#CC3300","#CC3333","#CC3366","#CC3399","#CC33CC","#CC33FF","#CC6600","#CC6633","#CC9900","#CC9933","#CCCC00","#CCCC33","#FF0000","#FF0033","#FF0066","#FF0099","#FF00CC","#FF00FF","#FF3300","#FF3333","#FF3366","#FF3399","#FF33CC","#FF33FF","#FF6600","#FF6633","#FF9900","#FF9933","#FFCC00","#FFCC33"],s.log=console.debug||console.log||(()=>{}),o.exports=common(s);const{formatters:r}=o.exports;r.j=function(i){try{return JSON.stringify(i)}catch(a){return"[UnexpectedJSONParseError]: "+a.message}}}(browser,browser.exports);var browserExports=browser.exports,debug3=getDefaultExportFromCjs(browserExports),dist={},LRUCache$1={},LRUCacheNode$1={};Object.defineProperty(LRUCacheNode$1,"__esModule",{value:!0}),LRUCacheNode$1.LRUCacheNode=void 0;class LRUCacheNode{constructor(s,r,i){const{entryExpirationTimeInMS:a=null,next:c=null,prev:y=null,onEntryEvicted:w,onEntryMarkedAsMostRecentlyUsed:C,clone:T,cloneFn:S}=i??{};if("number"==typeof a&&(a<=0||Number.isNaN(a)))throw new Error("entryExpirationTimeInMS must either be null (no expiry) or greater than 0");this.clone=null!=T&&T,this.cloneFn=S??this.defaultClone,this.key=s,this.internalValue=this.clone?this.cloneFn(r):r,this.created=Date.now(),this.entryExpirationTimeInMS=a,this.next=c,this.prev=y,this.onEntryEvicted=w,this.onEntryMarkedAsMostRecentlyUsed=C}get value(){return this.clone?this.cloneFn(this.internalValue):this.internalValue}get isExpired(){return"number"==typeof this.entryExpirationTimeInMS&&Date.now()-this.created>this.entryExpirationTimeInMS}invokeOnEvicted(){if(this.onEntryEvicted){const{key:s,value:r,isExpired:i}=this;this.onEntryEvicted({key:s,value:r,isExpired:i})}}invokeOnEntryMarkedAsMostRecentlyUsed(){if(this.onEntryMarkedAsMostRecentlyUsed){const{key:s,value:r}=this;this.onEntryMarkedAsMostRecentlyUsed({key:s,value:r})}}defaultClone(s){return"boolean"==typeof s||"string"==typeof s||"number"==typeof s?s:JSON.parse(JSON.stringify(s))}}LRUCacheNode$1.LRUCacheNode=LRUCacheNode,Object.defineProperty(LRUCache$1,"__esModule",{value:!0}),LRUCache$1.LRUCache=void 0;const LRUCacheNode_1=LRUCacheNode$1;class LRUCache{constructor(s){this.lookupTable=new Map,this.head=null,this.tail=null;const{maxSize:r=25,entryExpirationTimeInMS:i=null,onEntryEvicted:a,onEntryMarkedAsMostRecentlyUsed:c,cloneFn:y,clone:w}=s??{};if(Number.isNaN(r)||r<=0)throw new Error("maxSize must be greater than 0.");if("number"==typeof i&&(i<=0||Number.isNaN(i)))throw new Error("entryExpirationTimeInMS must either be null (no expiry) or greater than 0");this.maxSizeInternal=r,this.entryExpirationTimeInMS=i,this.onEntryEvicted=a,this.onEntryMarkedAsMostRecentlyUsed=c,this.clone=w,this.cloneFn=y}get size(){return this.cleanCache(),this.lookupTable.size}get remainingSize(){return this.maxSizeInternal-this.size}get newest(){return this.head?this.head.isExpired?(this.removeNodeFromListAndLookupTable(this.head),this.newest):this.mapNodeToEntry(this.head):null}get oldest(){return this.tail?this.tail.isExpired?(this.removeNodeFromListAndLookupTable(this.tail),this.oldest):this.mapNodeToEntry(this.tail):null}get maxSize(){return this.maxSizeInternal}set maxSize(s){if(Number.isNaN(s)||s<=0)throw new Error("maxSize must be greater than 0.");this.maxSizeInternal=s,this.enforceSizeLimit()}set(s,r,i){const a=this.lookupTable.get(s);a&&this.removeNodeFromListAndLookupTable(a);const c=new LRUCacheNode_1.LRUCacheNode(s,r,{entryExpirationTimeInMS:this.entryExpirationTimeInMS,onEntryEvicted:this.onEntryEvicted,onEntryMarkedAsMostRecentlyUsed:this.onEntryMarkedAsMostRecentlyUsed,clone:this.clone,cloneFn:this.cloneFn,...i});return this.setNodeAsHead(c),this.lookupTable.set(s,c),this.enforceSizeLimit(),this}get(s){const r=this.lookupTable.get(s);return r?r.isExpired?(this.removeNodeFromListAndLookupTable(r),null):(this.setNodeAsHead(r),r.value):null}peek(s){const r=this.lookupTable.get(s);return r?r.isExpired?(this.removeNodeFromListAndLookupTable(r),null):r.value:null}delete(s){const r=this.lookupTable.get(s);return!!r&&this.removeNodeFromListAndLookupTable(r)}has(s){const r=this.lookupTable.get(s);return!(!r||r.isExpired&&(this.removeNodeFromListAndLookupTable(r),1))}clear(){this.head=null,this.tail=null,this.lookupTable.clear()}find(s){let r=this.head;for(;r;){if(r.isExpired){const a=r.next;this.removeNodeFromListAndLookupTable(r),r=a;continue}const i=this.mapNodeToEntry(r);if(s(i))return this.setNodeAsHead(r),i;r=r.next}return null}forEach(s){let r=this.head,i=0;for(;r;)if(r.isExpired){const a=r.next;this.removeNodeFromListAndLookupTable(r),r=a}else s(r.value,r.key,i),r=r.next,i++}*values(){let s=this.head;for(;s;)if(s.isExpired){const r=s.next;this.removeNodeFromListAndLookupTable(s),s=r}else yield s.value,s=s.next}*keys(){let s=this.head;for(;s;)if(s.isExpired){const r=s.next;this.removeNodeFromListAndLookupTable(s),s=r}else yield s.key,s=s.next}*entries(){let s=this.head;for(;s;)if(s.isExpired){const r=s.next;this.removeNodeFromListAndLookupTable(s),s=r}else yield this.mapNodeToEntry(s),s=s.next}*[Symbol.iterator](){let s=this.head;for(;s;)if(s.isExpired){const r=s.next;this.removeNodeFromListAndLookupTable(s),s=r}else yield this.mapNodeToEntry(s),s=s.next}enforceSizeLimit(){let s=this.tail;for(;null!==s&&this.size>this.maxSizeInternal;){const r=s.prev;this.removeNodeFromListAndLookupTable(s),s=r}}mapNodeToEntry({key:s,value:r}){return{key:s,value:r}}setNodeAsHead(s){this.removeNodeFromList(s),this.head?(s.next=this.head,this.head.prev=s,this.head=s):(this.head=s,this.tail=s),s.invokeOnEntryMarkedAsMostRecentlyUsed()}removeNodeFromList(s){null!==s.prev&&(s.prev.next=s.next),null!==s.next&&(s.next.prev=s.prev),this.head===s&&(this.head=s.next),this.tail===s&&(this.tail=s.prev),s.next=null,s.prev=null}removeNodeFromListAndLookupTable(s){return s.invokeOnEvicted(),this.removeNodeFromList(s),this.lookupTable.delete(s.key)}cleanCache(){if(!this.entryExpirationTimeInMS)return;const s=[];for(const r of this.lookupTable.values())r.isExpired&&s.push(r);s.forEach(r=>this.removeNodeFromListAndLookupTable(r))}}LRUCache$1.LRUCache=LRUCache,function(o){var s=commonjsGlobal&&commonjsGlobal.__createBinding||(Object.create?function(i,a,c,y){void 0===y&&(y=c);var w=Object.getOwnPropertyDescriptor(a,c);w&&!("get"in w?!a.__esModule:w.writable||w.configurable)||(w={enumerable:!0,get:function(){return a[c]}}),Object.defineProperty(i,y,w)}:function(i,a,c,y){void 0===y&&(y=c),i[y]=a[c]}),r=commonjsGlobal&&commonjsGlobal.__exportStar||function(i,a){for(var c in i)"default"===c||Object.prototype.hasOwnProperty.call(a,c)||s(a,i,c)};Object.defineProperty(o,"__esModule",{value:!0}),r(LRUCache$1,o)}(dist);var lib={};(function(o){function s(De){if(!Number.isSafeInteger(De))throw new Error(`Wrong integer: ${De}`)}function r(...De){const ce=(ue,Ce)=>Be=>ue(Ce(Be));return{encode:Array.from(De).reverse().reduce((ue,Ce)=>ue?ce(ue,Ce.encode):Ce.encode,void 0),decode:De.reduce((ue,Ce)=>ue?ce(ue,Ce.decode):Ce.decode,void 0)}}function i(De){return{encode:ce=>{if(!Array.isArray(ce)||ce.length&&"number"!=typeof ce[0])throw new Error("alphabet.encode input should be an array of numbers");return ce.map(ue=>{if(s(ue),ue<0||ue>=De.length)throw new Error(`Digit index outside alphabet: ${ue} (alphabet: ${De.length})`);return De[ue]})},decode:ce=>{if(!Array.isArray(ce)||ce.length&&"string"!=typeof ce[0])throw new Error("alphabet.decode input should be array of strings");return ce.map(ue=>{if("string"!=typeof ue)throw new Error(`alphabet.decode: not string element=${ue}`);const Ce=De.indexOf(ue);if(-1===Ce)throw new Error(`Unknown letter: "${ue}". Allowed: ${De}`);return Ce})}}}function a(De=""){if("string"!=typeof De)throw new Error("join separator should be string");return{encode:ce=>{if(!Array.isArray(ce)||ce.length&&"string"!=typeof ce[0])throw new Error("join.encode input should be array of strings");for(let ue of ce)if("string"!=typeof ue)throw new Error(`join.encode: non-string input=${ue}`);return ce.join(De)},decode:ce=>{if("string"!=typeof ce)throw new Error("join.decode input should be string");return ce.split(De)}}}function c(De,ce="="){if(s(De),"string"!=typeof ce)throw new Error("padding chr should be string");return{encode(ue){if(!Array.isArray(ue)||ue.length&&"string"!=typeof ue[0])throw new Error("padding.encode input should be array of strings");for(let Ce of ue)if("string"!=typeof Ce)throw new Error(`padding.encode: non-string input=${Ce}`);for(;ue.length*De%8;)ue.push(ce);return ue},decode(ue){if(!Array.isArray(ue)||ue.length&&"string"!=typeof ue[0])throw new Error("padding.encode input should be array of strings");for(let Be of ue)if("string"!=typeof Be)throw new Error(`padding.decode: non-string input=${Be}`);let Ce=ue.length;if(Ce*De%8)throw new Error("Invalid padding: string should have whole number of bytes");for(;Ce>0&&ue[Ce-1]===ce;Ce--)if(!((Ce-1)*De%8))throw new Error("Invalid padding: string has too much padding");return ue.slice(0,Ce)}}}function y(De){if("function"!=typeof De)throw new Error("normalize fn should be function");return{encode:ce=>ce,decode:ce=>De(ce)}}function w(De,ce,ue){if(ce<2)throw new Error(`convertRadix: wrong from=${ce}, base cannot be less than 2`);if(ue<2)throw new Error(`convertRadix: wrong to=${ue}, base cannot be less than 2`);if(!Array.isArray(De))throw new Error("convertRadix: data should be array");if(!De.length)return[];let Ce=0;const Be=[],at=Array.from(De);for(at.forEach(dt=>{if(s(dt),dt<0||dt>=ce)throw new Error(`Wrong integer: ${dt}`)});;){let dt=0,bt=!0;for(let lt=Ce;ltce?C(ce,De%ce):De,T=(De,ce)=>De+(ce-C(De,ce));function S(De,ce,ue,Ce){if(!Array.isArray(De))throw new Error("convertRadix2: data should be array");if(ce<=0||ce>32)throw new Error(`convertRadix2: wrong from=${ce}`);if(ue<=0||ue>32)throw new Error(`convertRadix2: wrong to=${ue}`);if(T(ce,ue)>32)throw new Error(`convertRadix2: carry overflow from=${ce} to=${ue} carryBits=${T(ce,ue)}`);let Be=0,at=0;const dt=2**ue-1,bt=[];for(const lt of De){if(s(lt),lt>=2**ce)throw new Error(`convertRadix2: invalid data word=${lt} from=${ce}`);if(Be=Be<32)throw new Error(`convertRadix2: carry overflow pos=${at} from=${ce}`);for(at+=ce;at>=ue;at-=ue)bt.push((Be>>at-ue&dt)>>>0);Be&=2**at-1}if(Be=Be<=ce)throw new Error("Excess padding");if(!Ce&&Be)throw new Error(`Non-zero padding: ${Be}`);return Ce&&at>0&&bt.push(Be>>>0),bt}function M(De){return s(De),{encode:ce=>{if(!(ce instanceof Uint8Array))throw new Error("radix.encode input should be Uint8Array");return w(Array.from(ce),256,De)},decode:ce=>{if(!Array.isArray(ce)||ce.length&&"number"!=typeof ce[0])throw new Error("radix.decode input should be array of strings");return Uint8Array.from(w(ce,De,256))}}}function O(De,ce=!1){if(s(De),De<=0||De>32)throw new Error("radix2: bits should be in (0..32]");if(T(8,De)>32||T(De,8)>32)throw new Error("radix2: carry overflow");return{encode:ue=>{if(!(ue instanceof Uint8Array))throw new Error("radix2.encode input should be Uint8Array");return S(Array.from(ue),8,De,!ce)},decode:ue=>{if(!Array.isArray(ue)||ue.length&&"number"!=typeof ue[0])throw new Error("radix2.decode input should be array of strings");return Uint8Array.from(S(ue,De,8,ce))}}}function L(De){if("function"!=typeof De)throw new Error("unsafeWrapper fn should be function");return function(...ce){try{return De.apply(null,ce)}catch{}}}function Z(De,ce){if(s(De),"function"!=typeof ce)throw new Error("checksum fn should be function");return{encode(ue){if(!(ue instanceof Uint8Array))throw new Error("checksum.encode: input should be Uint8Array");const Ce=ce(ue).slice(0,De),Be=new Uint8Array(ue.length+De);return Be.set(ue),Be.set(Ce,ue.length),Be},decode(ue){if(!(ue instanceof Uint8Array))throw new Error("checksum.decode: input should be Uint8Array");const Ce=ue.slice(0,-De),Be=ce(Ce).slice(0,De),at=ue.slice(-De);for(let dt=0;dtDe.toUpperCase().replace(/O/g,"0").replace(/[IL]/g,"1"))),o.base64=r(O(6),i("ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/"),c(6),a("")),o.base64url=r(O(6),i("ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789-_"),c(6),a(""));const q=De=>r(M(58),i(De),a(""));o.base58=q("123456789ABCDEFGHJKLMNPQRSTUVWXYZabcdefghijkmnopqrstuvwxyz"),o.base58flickr=q("123456789abcdefghijkmnopqrstuvwxyzABCDEFGHJKLMNPQRSTUVWXYZ"),o.base58xrp=q("rpshnaf39wBUDNEGHJKLM4PQRST7VWXYZ2bcdeCg65jkm8oFqi1tuvAxyz");const re=[0,2,3,5,6,7,9,10,11];o.base58xmr={encode(De){let ce="";for(let ue=0;uer(Z(4,ce=>De(De(ce))),o.base58);const pe=r(i("qpzry9x8gf2tvdw0s3jn54khce6mua7l"),a("")),se=[996825010,642813549,513874426,1027748829,705979059];function ae(De){const ce=De>>25;let ue=(33554431&De)<<5;for(let Ce=0;Ce>Ce&1)&&(ue^=se[Ce]);return ue}function me(De,ce,ue=1){const Ce=De.length;let Be=1;for(let at=0;at126)throw new Error(`Invalid prefix (${De})`);Be=ae(Be)^dt>>5}Be=ae(Be);for(let at=0;atlt)throw new TypeError(`Wrong string length: ${bt.length} (${bt}). Expected (8..${lt})`);const rn=bt.toLowerCase();if(bt!==rn&&bt!==bt.toUpperCase())throw new Error("String must be lowercase or uppercase");const gn=(bt=rn).lastIndexOf("1");if(0===gn||-1===gn)throw new Error('Letter "1" must be present between prefix and data only');const bn=bt.slice(0,gn),Vn=bt.slice(gn+1);if(Vn.length<6)throw new Error("Data must be at least 6 characters long");const yn=pe.decode(Vn).slice(0,-6),qe=me(bn,yn,ce);if(!Vn.endsWith(qe))throw new Error(`Invalid checksum in ${bt}: expected "${qe}"`);return{prefix:bn,words:yn}}return{encode:function(bt,lt,rn=90){if("string"!=typeof bt)throw new Error("bech32.encode prefix should be string, not "+typeof bt);if(!Array.isArray(lt)||lt.length&&"number"!=typeof lt[0])throw new Error("bech32.encode words should be array of numbers, not "+typeof lt);const gn=bt.length+7+lt.length;if(!1!==rn&&gn>rn)throw new TypeError(`Length ${gn} exceeds limit ${rn}`);return`${bt=bt.toLowerCase()}1${pe.encode(lt)}${me(bt,lt,ce)}`},decode:dt,decodeToBytes:function(bt){const{prefix:lt,words:rn}=dt(bt,!1);return{prefix:lt,words:rn,bytes:Ce(rn)}},decodeUnsafe:L(dt),fromWords:Ce,fromWordsUnsafe:at,toWords:Be}}o.bech32=be("bech32"),o.bech32m=be("bech32m"),o.utf8={encode:De=>(new TextDecoder).decode(De),decode:De=>(new TextEncoder).encode(De)},o.hex=r(O(4),i("0123456789abcdef"),a(""),y(De=>{if("string"!=typeof De||De.length%2)throw new TypeError(`hex.decode: expected string, got ${typeof De} with length ${De.length}`);return De.toLowerCase()}));const Oe={utf8:o.utf8,hex:o.hex,base16:o.base16,base32:o.base32,base64:o.base64,base64url:o.base64url,base58:o.base58,base58xmr:o.base58xmr},xe=`Invalid encoding type. Available types: ${Object.keys(Oe).join(", ")}`;o.bytesToString=(De,ce)=>{if("string"!=typeof De||!Oe.hasOwnProperty(De))throw new TypeError(xe);if(!(ce instanceof Uint8Array))throw new TypeError("bytesToString() expects Uint8Array");return Oe[De].encode(ce)},o.str=o.bytesToString,o.stringToBytes=(De,ce)=>{if(!Oe.hasOwnProperty(De))throw new TypeError(xe);if("string"!=typeof ce)throw new TypeError("stringToBytes() expects string");return Oe[De].decode(ce)},o.bytes=o.stringToBytes})(lib),BigInt(1e3),BigInt(1e6),BigInt(1e9),BigInt(1e12),BigInt("2100000000000000000"),BigInt(1e11);const TAGCODES={payment_hash:1,payment_secret:16,description:13,payee:19,description_hash:23,expiry:6,min_final_cltv_expiry:24,fallback_address:9,route_hint:3,feature_bits:5,metadata:27};for(let o=0,s=Object.keys(TAGCODES);othis.handleNotice(s))}initiateAuth(o={limit:1}){var s=this;return(0,_home_runner_work_angor_hub_angor_hub_node_modules_angular_builders_custom_webpack_node_modules_babel_runtime_helpers_esm_asyncToGenerator_js__WEBPACK_IMPORTED_MODULE_1__.A)(function*(){s.debug("Initiating authentication");const r=s.relay.sub([o],{id:"auth-test"});r.on("eose",()=>{r.unsub(),s._status=1,s.ndkRelay.emit("ready"),s.debug("Authentication not required"),r.unsub()}),s.debug("Authentication request started")})()}connect(){var o=this;return(0,_home_runner_work_angor_hub_angor_hub_node_modules_angular_builders_custom_webpack_node_modules_babel_runtime_helpers_esm_asyncToGenerator_js__WEBPACK_IMPORTED_MODULE_1__.A)(function*(){const s=()=>{o.updateConnectionStats.connected(),o.ndkRelay.authRequired?(o._status=6,o.ndkRelay.emit("connect"),o.initiateAuth()):(o._status=1,o.ndkRelay.emit("connect"),o.ndkRelay.emit("ready"))},r=()=>{o.updateConnectionStats.disconnected(),1===o._status&&(o._status=3,o.handleReconnection()),o.ndkRelay.emit("disconnect")},i=function(){var a=(0,_home_runner_work_angor_hub_angor_hub_node_modules_angular_builders_custom_webpack_node_modules_babel_runtime_helpers_esm_asyncToGenerator_js__WEBPACK_IMPORTED_MODULE_1__.A)(function*(c){o.debug("Relay requested authentication",{havePolicy:!!o.ndkRelay.authPolicy}),o.ndkRelay.authPolicy?7!==o._status&&(o._status=7,yield o.ndkRelay.authPolicy(o.ndkRelay,c),7===o._status&&(o.debug("Authentication policy finished"),o._status=1,o.ndkRelay.emit("ready"))):yield o.ndkRelay.emit("auth",c)});return function(y){return a.apply(this,arguments)}}();try{o.updateConnectionStats.attempt(),o._status=0,o.relay.off("connect",s),o.relay.off("disconnect",r),o.relay.on("connect",s),o.relay.on("disconnect",r),o.relay.on("auth",i),yield o.relay.connect()}catch(a){throw o.debug("Failed to connect",a),o._status=3,a}})()}disconnect(){this._status=2,this.relay.close()}get status(){return this._status}isAvailable(){return 1===this._status}isFlapping(){const o=this._connectionStats.durations;if(o.length%3!=0)return!1;const s=o.reduce((i,a)=>i+a,0)/o.length,r=o.map(i=>Math.pow(i-s,2)).reduce((i,a)=>i+a,0)/o.length;return Math.sqrt(r)<1e3}handleNotice(o){var s=this;return(0,_home_runner_work_angor_hub_angor_hub_node_modules_angular_builders_custom_webpack_node_modules_babel_runtime_helpers_esm_asyncToGenerator_js__WEBPACK_IMPORTED_MODULE_1__.A)(function*(){(o.includes("oo many")||o.includes("aximum"))&&(s.disconnect(),setTimeout(()=>s.connect(),2e3),s.debug(s.relay.url,"Relay complaining?",o)),s.ndkRelay.emit("notice",s,o)})()}handleReconnection(o=0){if(this.isFlapping())return this.ndkRelay.emit("flapping",this,this._connectionStats),void(this._status=5);const s=this.connectedAt?Math.max(0,6e4-(Date.now()-this.connectedAt)):0;setTimeout(()=>{this._status=4,this.connect().then(()=>{this.debug("Reconnected")}).catch(r=>{this.debug("Reconnect failed",r),o<5?setTimeout(()=>{this.handleReconnection(o+1)},6e4):this.debug("Reconnect failed after 5 attempts")})},s)}updateConnectionStats={connected:()=>{this._connectionStats.success++,this._connectionStats.connectedAt=Date.now()},disconnected:()=>{this._connectionStats.connectedAt&&(this._connectionStats.durations.push(Date.now()-this._connectionStats.connectedAt),this._connectionStats.durations.length>100&&this._connectionStats.durations.shift()),this._connectionStats.connectedAt=void 0},attempt:()=>{this._connectionStats.attempts++}};get connectionStats(){return this._connectionStats}},NDKRelayPublisher=class{ndkRelay;constructor(o){this.ndkRelay=o}publish(o,s=2500){var r=this;return(0,_home_runner_work_angor_hub_angor_hub_node_modules_angular_builders_custom_webpack_node_modules_babel_runtime_helpers_esm_asyncToGenerator_js__WEBPACK_IMPORTED_MODULE_1__.A)(function*(){const i=()=>new Promise((C,T)=>{try{r.publishEvent(o,s).then(S=>C(S)).catch(S=>T(S))}catch(S){T(S)}}),a=new Promise((C,T)=>{setTimeout(()=>T(new Error("Timeout")),s)}),c=()=>{i().then(C=>y(C)).catch(C=>w(C))};let y,w;return 1===r.ndkRelay.status?Promise.race([i(),a]):Promise.race([new Promise((C,T)=>{y=C,w=T,r.ndkRelay.once("connect",c)}),a]).finally(()=>{r.ndkRelay.removeListener("connect",c)})})()}publishEvent(o,s){var r=this;return(0,_home_runner_work_angor_hub_angor_hub_node_modules_angular_builders_custom_webpack_node_modules_babel_runtime_helpers_esm_asyncToGenerator_js__WEBPACK_IMPORTED_MODULE_1__.A)(function*(){const i=yield o.toNostrEvent(),a=r.ndkRelay.connectivity.relay.publish(i);let c;const y=new Promise((C,T)=>{a.then(()=>{clearTimeout(c),r.ndkRelay.emit("published",o),C(!0)}).catch(S=>{clearTimeout(c),r.ndkRelay.debug("Publish failed",S,o.id),r.ndkRelay.emit("publish:failed",o,S),T(S)})});if(!s||o.isEphemeral())return y;const w=new Promise((C,T)=>{c=setTimeout(()=>{r.ndkRelay.debug("Publish timed out",o.rawEvent()),r.ndkRelay.emit("publish:failed",o,"Timeout"),T(new Error("Publish operation timed out"))},s)});return Promise.race([y,w])})()}auth(o){var s=this;return(0,_home_runner_work_angor_hub_angor_hub_node_modules_angular_builders_custom_webpack_node_modules_babel_runtime_helpers_esm_asyncToGenerator_js__WEBPACK_IMPORTED_MODULE_1__.A)(function*(){return s.ndkRelay.connectivity.relay.auth(o.rawEvent())})()}};function calculateGroupableId(o){const s=[];for(const r of o){if(r.since||r.until)return null;const i=Object.keys(r||{}).sort().join("-");s.push(i)}return s.join("|")}function mergeFilters(o){const s={};return o.forEach(r=>{Object.entries(r).forEach(([i,a])=>{s[i]=Array.isArray(a)?void 0===s[i]?[...a]:Array.from(new Set([...s[i],...a])):a})}),s}var MAX_SUBID_LENGTH=20;function queryFullyFilled(o){return!(!filterIncludesIds(o.filter)||!resultHasAllRequestedIds(o))}function compareFilter(o,s){if(Object.keys(o).length!==Object.keys(s).length)return!1;for(const[r,i]of Object.entries(o)){const a=s[r];if(!a)return!1;if(Array.isArray(i)&&Array.isArray(a)){const c=i;for(const y of a)if(!c.includes(y))return!1}else if(a!==i)return!1}return!0}function filterIncludesIds(o){return!!o.ids}function resultHasAllRequestedIds(o){const s=o.filter.ids;return!!s&&s.length===o.eventFirstSeen.size}function generateSubId(o,s){const r=o.map(w=>w.subId).filter(Boolean),i=[],a=new Set,c=new Set;if(r.length>0)i.push(Array.from(new Set(r)).join(","));else{for(const w of s)for(const C of Object.keys(w))"kinds"===C?w.kinds?.forEach(T=>c.add(T)):a.add(C);c.size>0&&i.push("kinds:"+Array.from(c).join(",")),a.size>0&&i.push(Array.from(a).join(","))}let y=i.join("-");return y.length>MAX_SUBID_LENGTH&&(y=y.substring(0,MAX_SUBID_LENGTH)),1!==r.length&&(y+="-"+Math.floor(999*Math.random()).toString()),y}function filterFromId(o){let s;if(o.match(NIP33_A_REGEX)){const[r,i,a]=o.split(":"),c={authors:[i],kinds:[parseInt(r)]};return a&&(c["#d"]=[a]),c}try{switch(s=nip19_exports.decode(o),s.type){case"nevent":return{ids:[s.data.id]};case"note":return{ids:[s.data]};case"naddr":return{authors:[s.data.pubkey],"#d":[s.data.identifier],kinds:[s.data.kind]}}}catch{}return{ids:[o]}}function isNip33AValue(o){return null!==o.match(NIP33_A_REGEX)}var NIP33_A_REGEX=/^(\d+):([0-9A-Fa-f]+)(?::(.*))?$/;function relaysFromBech32(o){try{const s=nip19_exports.decode(o);if(["naddr","nevent"].includes(s?.type)){const r=s.data;if(r?.relays)return r.relays.map(i=>new NDKRelay(i))}}catch{}return[]}var NDKGroupedSubscriptions=class extends lib$1.EventEmitter{subscriptions;req;debug;constructor(o,s){super(),this.subscriptions=o,this.debug=s||this.subscriptions[0].subscription.debug.extend("grouped");for(const r of o)this.handleSubscriptionClosure(r)}addSubscription(o){this.subscriptions.push(o),this.handleSubscriptionClosure(o)}eventReceived(o){for(const s of this.subscriptions)s.eventReceived(o)}eoseReceived(o){Array.from(this.subscriptions).forEach(function(){var s=(0,_home_runner_work_angor_hub_angor_hub_node_modules_angular_builders_custom_webpack_node_modules_babel_runtime_helpers_esm_asyncToGenerator_js__WEBPACK_IMPORTED_MODULE_1__.A)(function*(r){r.subscription.eoseReceived(o)});return function(r){return s.apply(this,arguments)}}())}handleSubscriptionClosure(o){o.subscription.on("close",()=>{const s=this.subscriptions.findIndex(r=>r.subscription===o.subscription);this.subscriptions.splice(s,1),this.subscriptions.length<=0&&this.emit("close")})}map(o){return this.subscriptions.map(o)}[Symbol.iterator](){let o=0;const s=this.subscriptions;return{next:()=>omatchFilter(r,s))}};function findMatchingActiveSubscriptions(o,s){if(o.length!==s.length)return!1;for(let r=0;r{this.delayedItems.get(r)&&this.delayedItems.delete(r)}));let y=this.executionTimeoutsByGroupId.get(r);y&&"at-most"!==o.opts.groupableDelayType||(y=setTimeout(()=>{this.executeGroup(r,o)},o.opts.groupableDelay),this.executionTimeoutsByGroupId.set(r,y)),this.delayedTimers.has(r)?this.delayedTimers.get(r).push(y):this.delayedTimers.set(r,[y])}executeGroup(o,s){const r=this.delayedItems.get(o);this.delayedItems.delete(o);const i=this.delayedTimers.get(o);if(this.delayedTimers.delete(o),i)for(const a of i)clearTimeout(a);if(r){const a=r.subscriptions[0].filters.length,c=[];for(let y=0;yC.filters[y]);c.push(mergeFilters(w))}this.executeSubscriptions(o,r,c)}}executeSubscriptionsWhenConnected(o,s,r){const i=()=>{this.debug("new relay coming online for active subscription",{relay:this.ndkRelay.url,mergeFilters}),this.executeSubscriptionsConnected(o,s,r)};this.ndkRelay.once("ready",i),s.once("close",()=>{this.ndkRelay.removeListener("ready",i)})}executeSubscriptions(o,s,r){this.conn.isAvailable()?this.executeSubscriptionsConnected(o,s,r):this.executeSubscriptionsWhenConnected(o,s,r)}executeSubscriptionsConnected(o,s,r){const i=[];for(const{subscription:w}of s)i.push(w);const a=generateSubId(i,r);s.req=r;const c={id:a};(this.ndkRelay.trusted||i.every(w=>w.opts.skipVerification))&&(c.skipVerification=!0);const y=this.conn.relay.sub(r,c);return this.activeSubscriptions.set(y,s),o&&this.activeSubscriptionsByGroupId.set(o,{filters:r,sub:y}),y.on("event",w=>{const C=new NDKEvent(void 0,w);C.relay=this.ndkRelay,this.activeSubscriptions.get(y)?.eventReceived(C)}),y.on("eose",()=>{this.activeSubscriptions.get(y)?.eoseReceived(this.ndkRelay)}),s.once("close",()=>{y.unsub(),this.activeSubscriptions.delete(y),o&&this.activeSubscriptionsByGroupId.delete(o)}),this.executeSubscriptionsWhenConnected(o,s,r),y}executedFilters(){const o=new Map;for(const[,s]of this.activeSubscriptions)o.set(s.req,s.map(r=>r.subscription));return o}},NDKRelay=class extends lib$1.EventEmitter{url;scores;connectivity;subs;publisher;authPolicy;authRequired=!1;trusted=!1;complaining=!1;debug;constructor(o,s){super(),this.url=o,this.scores=new Map,this.debug=debug3(`ndk:relay:${o}`),this.connectivity=new NDKRelayConnectivity(this),this.subs=new NDKRelaySubscriptions(this),this.publisher=new NDKRelayPublisher(this),this.authPolicy=s}get status(){return this.connectivity.status}get connectionStats(){return this.connectivity.connectionStats}connect(){var o=this;return(0,_home_runner_work_angor_hub_angor_hub_node_modules_angular_builders_custom_webpack_node_modules_babel_runtime_helpers_esm_asyncToGenerator_js__WEBPACK_IMPORTED_MODULE_1__.A)(function*(){return o.connectivity.connect()})()}disconnect(){3!==this.status&&this.connectivity.disconnect()}subscribe(o,s){this.subs.subscribe(o,s)}publish(o,s=2500){var r=this;return(0,_home_runner_work_angor_hub_angor_hub_node_modules_angular_builders_custom_webpack_node_modules_babel_runtime_helpers_esm_asyncToGenerator_js__WEBPACK_IMPORTED_MODULE_1__.A)(function*(){return r.publisher.publish(o,s)})()}auth(o){var s=this;return(0,_home_runner_work_angor_hub_angor_hub_node_modules_angular_builders_custom_webpack_node_modules_babel_runtime_helpers_esm_asyncToGenerator_js__WEBPACK_IMPORTED_MODULE_1__.A)(function*(){return s.publisher.auth(o)})()}scoreSlowerEvent(o){}tagReference(o){const s=["r",this.url];return o&&s.push(o),s}referenceTags(){return[["r",this.url]]}activeSubscriptions(){return this.subs.executedFilters()}},PublishError=class extends Error{errors;constructor(o,s){super(o),this.errors=s}},NDKRelaySet=class dD{relays;debug;ndk;constructor(s,r){this.relays=s,this.ndk=r,this.debug=r.debug.extend("relayset")}addRelay(s){this.relays.add(s)}static fromRelayUrls(s,r){const i=new Set;for(const a of s){const c=r.pool.relays.get(a);if(c)i.add(c);else{const y=new NDKRelay(a);r.pool.useTemporaryRelay(y),i.add(y)}}return new dD(new Set(i),r)}publish(s,r){var i=this;return(0,_home_runner_work_angor_hub_angor_hub_node_modules_angular_builders_custom_webpack_node_modules_babel_runtime_helpers_esm_asyncToGenerator_js__WEBPACK_IMPORTED_MODULE_1__.A)(function*(){const a=new Set,c=new Map,y=s.isEphemeral(),w=Array.from(i.relays).map(C=>new Promise(T=>{C.publish(s,r).then(()=>{a.add(C),T()}).catch(S=>{y||(c.set(C,S),i.debug("error publishing to relay",{relay:C.url,err:S})),T()})}));if(yield Promise.all(w),0===a.size&&!y)throw new PublishError("No relay was able to receive the event",c);return a})()}size(){return this.relays.size}};function calculateRelaySetFromEvent(o,s){const r=new Set;return o.pool?.relays.forEach(i=>r.add(i)),new NDKRelaySet(r,o)}function getWriteRelaysFor(o,s){if(o.outboxTracker)return o.outboxTracker.data.get(s)?.writeRelays}function calculateRelaySetsFromFilter(o,s){const r=new Map,i=new Set;if(s.forEach(a=>{a.authors&&a.authors.forEach(c=>i.add(c))}),i.size>0){const a=new Map;for(const c of i){const y=getWriteRelaysFor(o,c);y&&y.size>0?(o.debug(`Adding ${y.size} relays for ${c}`),y.forEach(w=>{const C=a.get(w)||[];C.push(c),a.set(w,C)})):o.explicitRelayUrls?.forEach(w=>{const C=a.get(w)||[];C.push(c),a.set(w,C)})}for(const c of a.keys())r.set(c,[]);for(const c of s)if(c.authors)for(const[y,w]of a.entries()){const C=c.authors.filter(T=>w.includes(T));r.set(y,[...r.get(y),{...c,authors:C}])}else for(const y of a.keys())r.set(y,[...r.get(y),c])}else o.explicitRelayUrls?.forEach(a=>{r.set(a,s)});return r}function calculateRelaySetsFromFilters(o,s){return calculateRelaySetsFromFilter(o,s)}var DEFAULT_RELAYS=["wss://nos.lol","wss://relay.nostr.band","wss://relay.f7z.io","wss://relay.damus.io","wss://nostr.mom","wss://no.str.cr"],Zap=class extends lib$1.EventEmitter{ndk;zappedEvent;zappedUser;constructor(o){super(),this.ndk=o.ndk,this.zappedEvent=o.zappedEvent,this.zappedUser=o.zappedUser||this.ndk.getUser({hexpubkey:this.zappedEvent?.pubkey})}getZapEndpoint(){var o=this;return(0,_home_runner_work_angor_hub_angor_hub_node_modules_angular_builders_custom_webpack_node_modules_babel_runtime_helpers_esm_asyncToGenerator_js__WEBPACK_IMPORTED_MODULE_1__.A)(function*(){let s,r,i,a;if(o.zappedUser&&(o.zappedUser.profile||(yield o.zappedUser.fetchProfile({groupable:!1})),s=(o.zappedUser.profile||{}).lud06,r=(o.zappedUser.profile||{}).lud16),r&&!r.startsWith("LNURL")){const[c,y]=r.split("@");i=`https://${y}/.well-known/lnurlp/${c}`}else if(s){const{words:c}=bech32.decode(s,1e3),y=bech32.fromWords(c);i=new TextDecoder("utf-8").decode(y)}if(!i)throw new Error("No zap endpoint found");try{const c=o.ndk.httpFetch||fetch,y=yield c(i);if(200!==y.status){const C=yield y.text();throw new Error(`Unable to fetch zap endpoint ${i}: ${C}`)}const w=yield y.json();return w?.allowsNostr&&(w?.nostrPubkey||w?.nostrPubKey)&&(a=w.callback),a}catch(c){throw new Error(`Unable to fetch zap endpoint ${i}: ${c}`)}})()}createZapRequest(o,s,r,i,a){var c=this;return(0,_home_runner_work_angor_hub_angor_hub_node_modules_angular_builders_custom_webpack_node_modules_babel_runtime_helpers_esm_asyncToGenerator_js__WEBPACK_IMPORTED_MODULE_1__.A)(function*(){const y=yield c.generateZapRequest(o,s,r,i);if(!y)return null;const{event:w,zapEndpoint:C}=y;if(!w)throw new Error("No zap request event found");let T;yield w.sign(a);try{T=yield c.getInvoice(w,o,C)}catch(S){throw new Error("Failed to get invoice: "+S)}return T})()}getInvoice(o,s,r){return(0,_home_runner_work_angor_hub_angor_hub_node_modules_angular_builders_custom_webpack_node_modules_babel_runtime_helpers_esm_asyncToGenerator_js__WEBPACK_IMPORTED_MODULE_1__.A)(function*(){return(yield(yield fetch(`${r}?`+new URLSearchParams({amount:s.toString(),nostr:JSON.stringify(o.rawEvent())}))).json()).pr})()}generateZapRequest(o,s,r,i,a){var c=this;return(0,_home_runner_work_angor_hub_angor_hub_node_modules_angular_builders_custom_webpack_node_modules_babel_runtime_helpers_esm_asyncToGenerator_js__WEBPACK_IMPORTED_MODULE_1__.A)(function*(){const y=yield c.getZapEndpoint();if(!y)throw new Error("No zap endpoint found");if(!c.zappedEvent&&!c.zappedUser)throw new Error("No zapped event or user found");const w=nip57_exports.makeZapRequest({profile:c.zappedUser.pubkey,event:null,amount:o,comment:s||"",relays:i??c.relays()});if(c.zappedEvent){const T=c.zappedEvent.referenceTags();w.tags.push(...T)}w.tags.push(["lnurl",y]);const C=new NDKEvent(c.ndk,w);return r&&(C.tags=C.tags.concat(r)),{event:C,zapEndpoint:y}})()}relays(){let o=[];return this.ndk?.pool?.relays&&(o=this.ndk.pool.urls()),o.length||(o=DEFAULT_RELAYS),o}};function mergeTags(o,s){const r=new Map,i=(a,c)=>a.every((y,w)=>y===c[w]);return o.concat(s).forEach(a=>{for(let[c,y]of r)if(i(y,a)||i(a,y))return void(a.length>=y.length&&r.set(c,a));r.set(a.join(","),a)}),Array.from(r.values())}function generateContentTags(o){return _generateContentTags.apply(this,arguments)}function _generateContentTags(){return _generateContentTags=(0,_home_runner_work_angor_hub_angor_hub_node_modules_angular_builders_custom_webpack_node_modules_babel_runtime_helpers_esm_asyncToGenerator_js__WEBPACK_IMPORTED_MODULE_1__.A)(function*(o,s=[]){let r=[];const i=a=>{s.find(c=>c[0]===a[0]&&c[1]===a[1])||s.push(a)};return o=o.replace(/(@|nostr:)(npub|nprofile|note|nevent|naddr)[a-zA-Z0-9]+/g,a=>{try{const c=a.split(/(@|nostr:)/)[2],{type:y,data:w}=nip19_exports.decode(c);let C;switch(y){case"npub":C=["p",w];break;case"nprofile":C=["p",w.pubkey];break;case"note":r.push(new Promise(function(){var T=(0,_home_runner_work_angor_hub_angor_hub_node_modules_angular_builders_custom_webpack_node_modules_babel_runtime_helpers_esm_asyncToGenerator_js__WEBPACK_IMPORTED_MODULE_1__.A)(function*(S){i(["e",w,yield maybeGetEventRelayUrl(c),"mention"]),S()});return function(S){return T.apply(this,arguments)}}()));break;case"nevent":r.push(new Promise(function(){var T=(0,_home_runner_work_angor_hub_angor_hub_node_modules_angular_builders_custom_webpack_node_modules_babel_runtime_helpers_esm_asyncToGenerator_js__WEBPACK_IMPORTED_MODULE_1__.A)(function*(S){let{id:M,relays:O,author:L}=w;O&&0!==O.length||(O=[yield maybeGetEventRelayUrl(c)]),i(["e",M,O[0],"mention"]),L&&i(["p",L]),S()});return function(S){return T.apply(this,arguments)}}()));break;case"naddr":r.push(new Promise(function(){var T=(0,_home_runner_work_angor_hub_angor_hub_node_modules_angular_builders_custom_webpack_node_modules_babel_runtime_helpers_esm_asyncToGenerator_js__WEBPACK_IMPORTED_MODULE_1__.A)(function*(S){const M=[w.kind,w.pubkey,w.identifier].join(":");let O=w.relays??[];0===O.length&&(O=[yield maybeGetEventRelayUrl(c)]),i(["a",M,O[0],"mention"]),i(["p",w.pubkey]),S()});return function(S){return T.apply(this,arguments)}}()));break;default:return a}return C&&i(C),`nostr:${c}`}catch{return a}}),yield Promise.all(r),{content:o=o.replace(/#(\w+)/g,(a,c)=>{const y=["t",c];return s.find(w=>w[0]===y[0]&&w[1]===y[1])||s.push(y),a}),tags:s}}),_generateContentTags.apply(this,arguments)}function maybeGetEventRelayUrl(o){return _maybeGetEventRelayUrl.apply(this,arguments)}function _maybeGetEventRelayUrl(){return(_maybeGetEventRelayUrl=(0,_home_runner_work_angor_hub_angor_hub_node_modules_angular_builders_custom_webpack_node_modules_babel_runtime_helpers_esm_asyncToGenerator_js__WEBPACK_IMPORTED_MODULE_1__.A)(function*(o){return""})).apply(this,arguments)}function isReplaceable(){if(void 0===this.kind)throw new Error("Kind not set");return this.kind>=1e4&&this.kind<2e4}function isEphemeral(){if(void 0===this.kind)throw new Error("Kind not set");return this.kind>=2e4&&this.kind<3e4}function isParamReplaceable(){if(void 0===this.kind)throw new Error("Kind not set");return this.kind>=3e4&&this.kind<4e4}function encrypt(o,s){return _encrypt.apply(this,arguments)}function _encrypt(){return _encrypt=(0,_home_runner_work_angor_hub_angor_hub_node_modules_angular_builders_custom_webpack_node_modules_babel_runtime_helpers_esm_asyncToGenerator_js__WEBPACK_IMPORTED_MODULE_1__.A)(function*(o,s){if(!this.ndk)throw new Error("No NDK instance found!");if(s||(yield this.ndk.assertSigner(),s=this.ndk.signer),!o){const r=this.getMatchingTags("p");if(1!==r.length)throw new Error("No recipient could be determined and no explicit recipient was provided");o=this.ndk.getUser({hexpubkey:r[0][1]})}this.content=yield s?.encrypt(o,this.content)}),_encrypt.apply(this,arguments)}function decrypt(o,s){return _decrypt.apply(this,arguments)}function _decrypt(){return _decrypt=(0,_home_runner_work_angor_hub_angor_hub_node_modules_angular_builders_custom_webpack_node_modules_babel_runtime_helpers_esm_asyncToGenerator_js__WEBPACK_IMPORTED_MODULE_1__.A)(function*(o,s){if(!this.ndk)throw new Error("No NDK instance found!");s||(yield this.ndk.assertSigner(),s=this.ndk.signer),o||(o=this.author),this.content=yield s?.decrypt(o,this.content)}),_decrypt.apply(this,arguments)}function encode(){return this.isParamReplaceable()?nip19_exports.naddrEncode({kind:this.kind,pubkey:this.pubkey,identifier:this.replaceableDTag(),relays:this.relay?[this.relay.url]:[]}):this.relay?nip19_exports.neventEncode({id:this.tagId(),relays:[this.relay.url],author:this.pubkey}):nip19_exports.noteEncode(this.tagId())}function repost(){return _repost.apply(this,arguments)}function _repost(){return _repost=(0,_home_runner_work_angor_hub_angor_hub_node_modules_angular_builders_custom_webpack_node_modules_babel_runtime_helpers_esm_asyncToGenerator_js__WEBPACK_IMPORTED_MODULE_1__.A)(function*(o=!0,s){if(!s&&o){if(!this.ndk)throw new Error("No NDK instance found");this.ndk.assertSigner(),s=this.ndk.signer}const r=new NDKEvent(this.ndk,{kind:getKind(this),content:""});return r.tag(this),16===r.kind&&r.tags.push(["k",`${this.kind}`]),s&&(yield r.sign(s)),o&&(yield r.publish()),r}),_repost.apply(this,arguments)}function getKind(o){return 1===o.kind?6:16}var NDKEvent=class iy extends lib$1.EventEmitter{ndk;created_at;content="";tags=[];kind;id="";sig;pubkey="";_author=void 0;relay;constructor(s,r){super(),this.ndk=s,this.created_at=r?.created_at,this.content=r?.content||"",this.tags=r?.tags||[],this.id=r?.id||"",this.sig=r?.sig,this.pubkey=r?.pubkey||"",this.kind=r?.kind}rawEvent(){return{created_at:this.created_at,content:this.content,tags:this.tags,kind:this.kind,pubkey:this.pubkey,id:this.id,sig:this.sig}}set author(s){this.pubkey=s.hexpubkey,this._author=void 0}get author(){if(this._author)return this._author;if(!this.ndk)throw new Error("No NDK instance found");const s=this.ndk.getUser({hexpubkey:this.pubkey});return this._author=s,s}tag(s,r){let i=[];if(s instanceof NDKUser){const a=["p",s.pubkey];r&&a.push(r),i.push(a)}else if(s instanceof iy){const a=s;i=a.referenceTags(r,a?.pubkey===this.pubkey);for(const y of a.getMatchingTags("p"))y[1]!==this.pubkey&&(this.tags.find(w=>"p"===w[0]&&w[1]===y[1])||this.tags.push(["p",y[1]]))}else i=[s];this.tags=mergeTags(this.tags,i)}toNostrEvent(s){var r=this;return(0,_home_runner_work_angor_hub_angor_hub_node_modules_angular_builders_custom_webpack_node_modules_babel_runtime_helpers_esm_asyncToGenerator_js__WEBPACK_IMPORTED_MODULE_1__.A)(function*(){if(!s&&""===r.pubkey){const y=yield r.ndk?.signer?.user();r.pubkey=y?.hexpubkey||""}r.created_at||(r.created_at=Math.floor(Date.now()/1e3));const i=r.rawEvent(),{content:a,tags:c}=yield r.generateTags();i.content=a||"",i.tags=c;try{r.id=getEventHash(i)}catch{}return r.id&&(i.id=r.id),r.sig&&(i.sig=r.sig),i})()}isReplaceable=isReplaceable.bind(this);isEphemeral=isEphemeral.bind(this);isParamReplaceable=isParamReplaceable.bind(this);encode=encode.bind(this);encrypt=encrypt.bind(this);decrypt=decrypt.bind(this);getMatchingTags(s){return this.tags.filter(r=>r[0]===s)}tagValue(s){const r=this.getMatchingTags(s);if(0!==r.length)return r[0][1]}get alt(){return this.tagValue("alt")}set alt(s){this.removeTag("alt"),s&&this.tags.push(["alt",s])}removeTag(s){this.tags=this.tags.filter(r=>r[0]!==s)}sign(s){var r=this;return(0,_home_runner_work_angor_hub_angor_hub_node_modules_angular_builders_custom_webpack_node_modules_babel_runtime_helpers_esm_asyncToGenerator_js__WEBPACK_IMPORTED_MODULE_1__.A)(function*(){s?r.author=yield s.user():(r.ndk?.assertSigner(),s=r.ndk.signer),yield r.generateTags(),r.isReplaceable()&&(r.created_at=Math.floor(Date.now()/1e3));const i=yield r.toNostrEvent();return r.sig=yield s.sign(i),r.sig})()}publish(s,r){var i=this;return(0,_home_runner_work_angor_hub_angor_hub_node_modules_angular_builders_custom_webpack_node_modules_babel_runtime_helpers_esm_asyncToGenerator_js__WEBPACK_IMPORTED_MODULE_1__.A)(function*(){if(i.sig||(yield i.sign()),!i.ndk)throw new Error("NDKEvent must be associated with an NDK instance to publish");return s||(s=i.ndk.devWriteRelaySet||calculateRelaySetFromEvent(i.ndk)),s.publish(i,r)})()}generateTags(){var s=this;return(0,_home_runner_work_angor_hub_angor_hub_node_modules_angular_builders_custom_webpack_node_modules_babel_runtime_helpers_esm_asyncToGenerator_js__WEBPACK_IMPORTED_MODULE_1__.A)(function*(){let r=[];const i=yield generateContentTags(s.content,s.tags),a=i.content;if(r=i.tags,s.kind&&s.isParamReplaceable()&&!s.getMatchingTags("d")[0]){const c=s.tagValue("title");let y=[...Array(c?6:16)].map(()=>Math.random().toString(36)[2]).join("");c&&c.length>0&&(y=c.replace(/[^a-z0-9]+/gi,"-").replace(/^-|-$/g,"")+"-"+y),r.push(["d",y])}if((s.ndk?.clientName||s.ndk?.clientNip89)&&!s.tagValue("client")){const c=["client",s.ndk.clientName??""];s.ndk.clientNip89&&c.push(s.ndk.clientNip89),r.push(c)}return{content:a||"",tags:r}})()}muted(){const s=this.ndk?.mutedIds.get(this.pubkey);if(s&&"p"===s)return"author";const r=this.tagReference(),i=this.ndk?.mutedIds.get(r[1]);return i&&i===r[0]?"event":null}replaceableDTag(){if(this.kind&&this.kind>=3e4&&this.kind<=4e4){const s=this.getMatchingTags("d")[0];return s?s[1]:""}throw new Error("Event is not a parameterized replaceable event")}deduplicationKey(){return 0===this.kind||3===this.kind||this.kind&&this.kind>=1e4&&this.kind<2e4?`${this.kind}:${this.pubkey}`:this.tagId()}tagId(){return this.isParamReplaceable()?this.tagAddress():this.id}tagAddress(){if(!this.isParamReplaceable())throw new Error("This must only be called on replaceable events");const s=this.replaceableDTag();return`${this.kind}:${this.pubkey}:${s}`}tagReference(s){let r;return r=this.isParamReplaceable()?["a",this.tagAddress()]:["e",this.tagId()],r.push(this.relay?this.relay.url:""),s&&r.push(s),r}referenceTags(s,r){let i=[];return i=this.isParamReplaceable()?[["a",this.tagAddress()],["e",this.id]]:[["e",this.id]],this.relay?.url?i=i.map(a=>(a.push(this.relay?.url),a)):s&&(i=i.map(a=>(a.push(""),a))),s&&i.forEach(a=>a.push(s)),r||i.push(...this.author.referenceTags()),i}filter(){return this.isParamReplaceable()?{"#a":[this.tagId()]}:{"#e":[this.tagId()]}}zap(s,r,i,a,c){var y=this;return(0,_home_runner_work_angor_hub_angor_hub_node_modules_angular_builders_custom_webpack_node_modules_babel_runtime_helpers_esm_asyncToGenerator_js__WEBPACK_IMPORTED_MODULE_1__.A)(function*(){if(!y.ndk)throw new Error("No NDK instance found");c||y.ndk.assertSigner();const w=new Zap({ndk:y.ndk,zappedEvent:y,zappedUser:a}),C=Array.from(y.ndk.pool.relays.keys());return yield w.createZapRequest(s,r,i,C,c)})()}delete(s){var r=this;return(0,_home_runner_work_angor_hub_angor_hub_node_modules_angular_builders_custom_webpack_node_modules_babel_runtime_helpers_esm_asyncToGenerator_js__WEBPACK_IMPORTED_MODULE_1__.A)(function*(){if(!r.ndk)throw new Error("No NDK instance found");r.ndk.assertSigner();const i=new iy(r.ndk,{kind:5,content:s||""});return i.tag(r),yield i.publish(),i})()}repost=repost.bind(this);react(s,r=!0){var i=this;return(0,_home_runner_work_angor_hub_angor_hub_node_modules_angular_builders_custom_webpack_node_modules_babel_runtime_helpers_esm_asyncToGenerator_js__WEBPACK_IMPORTED_MODULE_1__.A)(function*(){if(!i.ndk)throw new Error("No NDK instance found");i.ndk.assertSigner();const a=new iy(i.ndk,{kind:7,content:s});return a.tag(i),r?yield a.publish():yield a.sign(),a})()}get isValid(){return!0}},READ_MARKER="read",WRITE_MARKER="write",NDKRelayList=class hD extends NDKEvent{constructor(s,r){super(s,r),this.kind??=10002}static from(s){return new hD(s.ndk,s.rawEvent())}get readRelayUrls(){return this.getMatchingTags("r").filter(s=>!s[2]||s[2]&&s[2]===READ_MARKER).map(s=>s[1])}set readRelayUrls(s){for(const r of s)this.tags.push(["r",r,READ_MARKER])}get writeRelayUrls(){return this.getMatchingTags("r").filter(s=>!s[2]||s[2]&&s[2]===WRITE_MARKER).map(s=>s[1])}set writeRelayUrls(s){for(const r of s)this.tags.push(["r",r,WRITE_MARKER])}get bothRelayUrls(){return this.getMatchingTags("r").filter(s=>!s[2]).map(s=>s[1])}set bothRelayUrls(s){for(const r of s)this.tags.push(["r",r])}get relays(){return this.getMatchingTags("r").map(s=>s[1])}},NDKSubscriptionCacheUsage=(o=>(o.ONLY_CACHE="ONLY_CACHE",o.CACHE_FIRST="CACHE_FIRST",o.PARALLEL="PARALLEL",o.ONLY_RELAY="ONLY_RELAY",o))(NDKSubscriptionCacheUsage||{}),defaultOpts={closeOnEose:!1,cacheUsage:"CACHE_FIRST",groupable:!0,groupableDelay:100,groupableDelayType:"at-most"},NDKSubscription=class extends lib$1.EventEmitter{subId;filters;opts;pool;skipVerification=!1;skipValidation=!1;relayFilters;relaySet;ndk;debug;eoseDebug;eventFirstSeen=new Map;eosesSeen=new Set;eventsPerRelay=new Map;lastEventReceivedAt;internalId;constructor(o,s,r,i,a){if(super(),this.ndk=o,this.pool=r?.pool||o.pool,this.opts={...defaultOpts,...r||{}},this.filters=s instanceof Array?s:[s],this.subId=a||r?.subId,this.internalId=Math.random().toString(36).substring(7),this.relaySet=i,this.debug=o.debug.extend(`subscription[${r?.subId??this.internalId}]`),this.eoseDebug=this.debug.extend("eose"),this.skipVerification=r?.skipVerification||!1,this.skipValidation=r?.skipValidation||!1,this.opts.closeOnEose||this.debug("Creating a permanent subscription",this.opts,JSON.stringify(this.filters)),"ONLY_CACHE"===this.opts.cacheUsage&&!this.opts.closeOnEose)throw new Error("Cannot use cache-only options with a persistent subscription")}get filter(){return this.filters[0]}isGroupable(){return this.opts?.groupable||!1}shouldQueryCache(){return"ONLY_RELAY"!==this.opts?.cacheUsage}shouldQueryRelays(){return"ONLY_CACHE"!==this.opts?.cacheUsage}shouldWaitForCache(){return this.opts.closeOnEose&&!!this.ndk.cacheAdapter?.locking&&"PARALLEL"!==this.opts.cacheUsage}start(){var o=this;return(0,_home_runner_work_angor_hub_angor_hub_node_modules_angular_builders_custom_webpack_node_modules_babel_runtime_helpers_esm_asyncToGenerator_js__WEBPACK_IMPORTED_MODULE_1__.A)(function*(){let s;o.shouldQueryCache()&&(s=o.startWithCache(),o.shouldWaitForCache()&&(yield s,queryFullyFilled(o)))?o.emit("eose",o):o.shouldQueryRelays()?o.startWithRelays():o.emit("eose",o)})()}stop(){this.emit("close",this),this.removeAllListeners()}hasAuthorsFilter(){return this.filters.some(o=>o.authors?.length)}startWithCache(){var o=this;return(0,_home_runner_work_angor_hub_angor_hub_node_modules_angular_builders_custom_webpack_node_modules_babel_runtime_helpers_esm_asyncToGenerator_js__WEBPACK_IMPORTED_MODULE_1__.A)(function*(){if(o.ndk.cacheAdapter?.query){const s=o.ndk.cacheAdapter.query(o);o.ndk.cacheAdapter.locking&&(yield s)}})()}startWithRelays(){if(this.relaySet){this.relayFilters=new Map;for(const o of this.relaySet.relays)this.relayFilters.set(o.url,this.filters)}else this.relayFilters=calculateRelaySetsFromFilters(this.ndk,this.filters);if(this.relayFilters&&0!==this.relayFilters.size)for(const[o,s]of this.relayFilters)this.pool.getRelay(o).subscribe(this,s);else this.debug("No relays to subscribe to",this.ndk.explicitRelayUrls)}eventReceived(o,s,r=!1){if(s&&(o.relay=s),s||(s=o.relay),this.skipValidation||o.isValid){if(!r&&s){let i=this.eventsPerRelay.get(s);if(i||(i=new Set,this.eventsPerRelay.set(s,i)),i.add(o.id),this.eventFirstSeen.has(o.id)){const a=Date.now()-(this.eventFirstSeen.get(o.id)||0);return s.scoreSlowerEvent(a),void this.emit("event:dup",o,s,a,this)}this.ndk.cacheAdapter&&this.ndk.cacheAdapter.setEvent(o,this.filters,s),this.eventFirstSeen.set(o.id,Date.now())}else this.eventFirstSeen.set(o.id,0);o.ndk||(o.ndk=this.ndk),this.emit("event",o,s,this),this.lastEventReceivedAt=Date.now()}else this.debug("Event failed validation",o)}eoseTimeout;eoseReceived(o){this.eosesSeen.add(o),this.eoseDebug(`received from ${o.url}`);let s=this.lastEventReceivedAt?Date.now()-this.lastEventReceivedAt:void 0;const r=this.eosesSeen.size===this.relayFilters?.size;if(queryFullyFilled(this))this.emit("eose"),this.eoseDebug("Query fully filled"),this.opts?.closeOnEose&&this.stop();else if(r)this.emit("eose"),this.eoseDebug("All EOSEs seen"),this.opts?.closeOnEose&&this.stop();else{let i=1e3;const a=this.eosesSeen.size/this.relayFilters.size;if(this.eosesSeen.size>=2&&a>=.5){i*=1-a,this.eoseTimeout&&clearTimeout(this.eoseTimeout);const c=()=>{s=this.lastEventReceivedAt?Date.now()-this.lastEventReceivedAt:void 0,void 0!==s&&s<20?this.eoseTimeout=setTimeout(c,i):(this.emit("eose"),this.opts?.closeOnEose&&this.stop())};this.eoseTimeout=setTimeout(c,i)}}}};function follows(o,s){return _follows.apply(this,arguments)}function _follows(){return _follows=(0,_home_runner_work_angor_hub_angor_hub_node_modules_angular_builders_custom_webpack_node_modules_babel_runtime_helpers_esm_asyncToGenerator_js__WEBPACK_IMPORTED_MODULE_1__.A)(function*(o,s,r=3){if(!this.ndk)throw new Error("NDK not set");const i=Array.from(yield this.ndk.fetchEvents({kinds:[r],authors:[this.pubkey]},o||{groupable:!1}))[0];if(i){const a=new Set;return i.tags.forEach(c=>{if("p"===c[0])try{a.add(c[1]),s&&this.ndk?.outboxTracker?.trackUsers([c[1]])}catch{}}),[...a].reduce((c,y)=>{const w=new NDKUser({pubkey:y});return w.ndk=this.ndk,c.add(w),c},new Set)}return new Set}),_follows.apply(this,arguments)}function profileFromEvent(o){const s={};let r;try{r=JSON.parse(o.content)}catch(i){throw new Error(`Failed to parse profile event: ${i}`)}return Object.keys(r).forEach(i=>{switch(i){case"name":s.name=r.name;break;case"display_name":s.displayName=r.display_name;break;case"image":case"picture":s.image=r.image||r.picture;break;case"banner":s.banner=r.banner;break;case"bio":s.bio=r.bio;break;case"nip05":s.nip05=r.nip05;break;case"lud06":s.lud06=r.lud06;break;case"lud16":s.lud16=r.lud16;break;case"about":s.about=r.about;break;case"zapService":s.zapService=r.zapService;break;case"website":s.website=r.website;break;default:s[i]=r[i]}}),s}function serializeProfile(o){const s={};for(const[r,i]of Object.entries(o))switch(r){case"username":case"name":s.name=i;break;case"displayName":s.display_name=i;break;case"image":case"picture":s.picture=i;break;case"bio":case"about":s.about=i;break;default:s[r]=i}return JSON.stringify(s)}var NDKList=class fD extends NDKEvent{_encryptedTags;encryptedTagsLength;constructor(s,r){super(s,r),this.kind??=30001}static from(s){return new fD(s.ndk,s.rawEvent())}get title(){const s=this.tagValue("title")||this.tagValue("name");return 3!==this.kind||s?1e4!==this.kind||s?10001!==this.kind||s?10002!==this.kind||s?10003!==this.kind||s?10004!==this.kind||s?10005!==this.kind||s?10006!==this.kind||s?10007!==this.kind||s?10015!==this.kind||s?10030!==this.kind||s?s??this.tagValue("d"):"Emojis":"Interests":"Search Relays":"Blocked Relays":"Public Chats":"Communities":"Bookmarks":"Relay Metadata":"Pinned Notes":"Mute":"Contacts"}set title(s){if(this.removeTag("title"),this.removeTag("name"),!s)throw new Error("Title cannot be empty");this.tags.push(["title",s])}get name(){const s=this.tagValue("name");return 3!==this.kind||s?1e4!==this.kind||s?10001!==this.kind||s?10002!==this.kind||s?10003!==this.kind||s?10004!==this.kind||s?10005!==this.kind||s?10006!==this.kind||s?10007!==this.kind||s?10015!==this.kind||s?10030!==this.kind||s?s??this.tagValue("d"):"Emojis":"Interests":"Search Relays":"Blocked Relays":"Public Chats":"Communities":"Bookmarks":"Relay Metadata":"Pinned Notes":"Mute":"Contacts"}set name(s){if(this.removeTag("name"),!s)throw new Error("Name cannot be empty");this.tags.push(["title",s])}get description(){return this.tagValue("description")}set description(s){s?this.tags.push(["description",s]):this.removeTag("description")}isEncryptedTagsCacheValid(){return!(!this._encryptedTags||this.encryptedTagsLength!==this.content.length)}encryptedTags(s=!0){var r=this;return(0,_home_runner_work_angor_hub_angor_hub_node_modules_angular_builders_custom_webpack_node_modules_babel_runtime_helpers_esm_asyncToGenerator_js__WEBPACK_IMPORTED_MODULE_1__.A)(function*(){if(s&&r.isEncryptedTagsCacheValid())return r._encryptedTags;if(!r.ndk)throw new Error("NDK instance not set");if(!r.ndk.signer)throw new Error("NDK signer not set");const i=yield r.ndk.signer.user();try{if(r.content.length>0)try{const a=yield r.ndk.signer.decrypt(i,r.content),c=JSON.parse(a);return c&&c[0]?(r.encryptedTagsLength=r.content.length,r._encryptedTags=c):(r.encryptedTagsLength=r.content.length,r._encryptedTags=[])}catch{console.log(`error decrypting ${r.content}`)}}catch{}return[]})()}validateTag(s){return!0}get items(){return this.tags.filter(s=>!["d","L","l","title","name","description","summary","image","thumb","alt","expiration","subject"].includes(s[0]))}addItem(s,r=void 0,i=!1){var a=this;return(0,_home_runner_work_angor_hub_angor_hub_node_modules_angular_builders_custom_webpack_node_modules_babel_runtime_helpers_esm_asyncToGenerator_js__WEBPACK_IMPORTED_MODULE_1__.A)(function*(){if(!a.ndk)throw new Error("NDK instance not set");if(!a.ndk.signer)throw new Error("NDK signer not set");let c;if(s instanceof NDKEvent)c=s.referenceTags();else if(s instanceof NDKUser)c=s.referenceTags();else if(s instanceof NDKRelay)c=s.referenceTags();else{if(!Array.isArray(s))throw new Error("Invalid object type");c=[s]}if(r&&c[0].push(r),i){const y=yield a.ndk.signer.user(),w=yield a.encryptedTags();w.push(...c),a._encryptedTags=w,a.encryptedTagsLength=a.content.length,a.content=JSON.stringify(w),yield a.encrypt(y)}else a.tags.push(...c);a.created_at=Math.floor(Date.now()/1e3),a.emit("change")})()}removeItem(s,r){var i=this;return(0,_home_runner_work_angor_hub_angor_hub_node_modules_angular_builders_custom_webpack_node_modules_babel_runtime_helpers_esm_asyncToGenerator_js__WEBPACK_IMPORTED_MODULE_1__.A)(function*(){if(!i.ndk)throw new Error("NDK instance not set");if(!i.ndk.signer)throw new Error("NDK signer not set");if(r){const a=yield i.ndk.signer.user(),c=yield i.encryptedTags();c.splice(s,1),i._encryptedTags=c,i.encryptedTagsLength=i.content.length,i.content=JSON.stringify(c),yield i.encrypt(a)}else i.tags.splice(s,1);return i.created_at=Math.floor(Date.now()/1e3),i.emit("change"),i})()}},lists_default=NDKList;function pin(o,s,r){return _pin.apply(this,arguments)}function _pin(){return _pin=(0,_home_runner_work_angor_hub_angor_hub_node_modules_angular_builders_custom_webpack_node_modules_babel_runtime_helpers_esm_asyncToGenerator_js__WEBPACK_IMPORTED_MODULE_1__.A)(function*(o,s,r){if(!this.ndk)throw new Error("No NDK instance found");if(this.ndk.assertSigner(),!s){const i=yield this.ndk.fetchEvents({kinds:[10001],authors:[this.pubkey]},{cacheUsage:"ONLY_RELAY"});s=i.size>0?lists_default.from(Array.from(i)[0]):new NDKEvent(this.ndk,{kind:10001})}return s.tag(o),r&&(yield s.publish()),s}),_pin.apply(this,arguments)}var NIP05_REGEX=/^(?:([\w.+-]+)@)?([\w.-]+)$/;function getNip05For(o){return _getNip05For.apply(this,arguments)}function _getNip05For(){return _getNip05For=(0,_home_runner_work_angor_hub_angor_hub_node_modules_angular_builders_custom_webpack_node_modules_babel_runtime_helpers_esm_asyncToGenerator_js__WEBPACK_IMPORTED_MODULE_1__.A)(function*(o,s=fetch,r={}){const i=o.match(NIP05_REGEX);if(!i)return null;const[a,c="_",y]=i;try{const w=yield s(`https://${y}/.well-known/nostr.json?name=${c}`,r),{names:C,relays:T,nip46:S}=parseNIP05Result(yield w.json()),M=C[c];return M?{pubkey:M,relays:T?.[M],nip46:S?.[M]}:null}catch{return null}}),_getNip05For.apply(this,arguments)}function parseNIP05Result(o){const s={names:{}};for(const[r,i]of Object.entries(o.names))"string"==typeof r&&"string"==typeof i&&(s.names[r]=i);if(o.relays){s.relays={};for(const[r,i]of Object.entries(o.relays))"string"==typeof r&&Array.isArray(i)&&(s.relays[r]=i.filter(a=>"string"==typeof a))}if(o.nip46){s.nip46={};for(const[r,i]of Object.entries(o.relays))"string"==typeof r&&Array.isArray(i)&&(s.nip46[r]=i.filter(a=>"string"==typeof a))}return s}var NDKUser=class Sw{ndk;profile;_npub;_pubkey;relayUrls=[];nip46Urls=[];constructor(s){s.npub&&(this._npub=s.npub),s.hexpubkey&&(this._pubkey=s.hexpubkey),s.pubkey&&(this._pubkey=s.pubkey),s.relayUrls&&(this.relayUrls=s.relayUrls),s.nip46Urls&&(this.nip46Urls=s.nip46Urls)}get npub(){if(!this._npub){if(!this._pubkey)throw new Error("hexpubkey not set");this._npub=nip19_exports.npubEncode(this.pubkey)}return this._npub}set npub(s){this._npub=s}get hexpubkey(){return this.pubkey}set hexpubkey(s){this._pubkey=s}get pubkey(){if(!this._pubkey){if(!this._npub)throw new Error("npub not set");this._pubkey=nip19_exports.decode(this.npub).data}return this._pubkey}set pubkey(s){this._pubkey=s}static fromNip05(s,r,i=!1){return(0,_home_runner_work_angor_hub_angor_hub_node_modules_angular_builders_custom_webpack_node_modules_babel_runtime_helpers_esm_asyncToGenerator_js__WEBPACK_IMPORTED_MODULE_1__.A)(function*(){if(r?.cacheAdapter&&r.cacheAdapter.loadNip05){const y=yield r.cacheAdapter.loadNip05(s);if(y){const w=new Sw({pubkey:y.pubkey,relayUrls:y.relays,nip46Urls:y.nip46});return w.ndk=r,w}}let a={};i&&(a.cache="no-cache");const c=yield getNip05For(s,r?.httpFetch,a);if(c&&r?.cacheAdapter&&r.cacheAdapter.saveNip05&&r?.cacheAdapter.saveNip05(s,c),c){const y=new Sw({pubkey:c.pubkey,relayUrls:c.relays,nip46Urls:c.nip46});return y.ndk=r,y}})()}fetchProfile(s){var r=this;return(0,_home_runner_work_angor_hub_angor_hub_node_modules_angular_builders_custom_webpack_node_modules_babel_runtime_helpers_esm_asyncToGenerator_js__WEBPACK_IMPORTED_MODULE_1__.A)(function*(){if(!r.ndk)throw new Error("NDK not set");r.profile||(r.profile={});let i=null;if(r.ndk.cacheAdapter&&r.ndk.cacheAdapter.fetchProfile&&"ONLY_RELAY"!==s?.cacheUsage){const c=yield r.ndk.cacheAdapter.fetchProfile(r.pubkey);if(c)return r.profile=c,c}!s&&r.ndk.cacheAdapter&&r.ndk.cacheAdapter.locking&&(i=yield r.ndk.fetchEvents({kinds:[0],authors:[r.pubkey]},{cacheUsage:"ONLY_CACHE",closeOnEose:!0,groupable:!1}),s={cacheUsage:"ONLY_RELAY",closeOnEose:!0,groupable:!0,groupableDelay:250}),i&&0!==i.size||(i=yield r.ndk.fetchEvents({kinds:[0],authors:[r.pubkey]},s));const a=Array.from(i).sort((c,y)=>c.created_at-y.created_at);return 0===a.length?null:(r.profile=profileFromEvent(a[0]),r.profile&&r.ndk.cacheAdapter&&r.ndk.cacheAdapter.saveProfile&&r.ndk.cacheAdapter.saveProfile(r.pubkey,r.profile),r.profile)})()}follows=follows.bind(this);pin=pin.bind(this);relayList(){var s=this;return(0,_home_runner_work_angor_hub_angor_hub_node_modules_angular_builders_custom_webpack_node_modules_babel_runtime_helpers_esm_asyncToGenerator_js__WEBPACK_IMPORTED_MODULE_1__.A)(function*(){if(!s.ndk)throw new Error("NDK not set");const r=s.ndk.outboxPool||s.ndk.pool,i=new Set;for(const y of r.relays.values())i.add(y);const a=new NDKRelaySet(i,s.ndk),c=yield s.ndk.fetchEvent({kinds:[10002],authors:[s.pubkey]},{closeOnEose:!0,pool:r,groupable:!0,subId:`relay-list-${s.pubkey.slice(0,6)}`},a);return c?NDKRelayList.from(c):yield s.relayListFromKind3()})()}relayListFromKind3(){var s=this;return(0,_home_runner_work_angor_hub_angor_hub_node_modules_angular_builders_custom_webpack_node_modules_babel_runtime_helpers_esm_asyncToGenerator_js__WEBPACK_IMPORTED_MODULE_1__.A)(function*(){if(!s.ndk)throw new Error("NDK not set");const r=yield s.ndk.fetchEvent({kinds:[3],authors:[s.pubkey]});if(r)try{const i=JSON.parse(r.content),a=new NDKRelayList(s.ndk),c=new Set,y=new Set;for(const[w,C]of Object.entries(i))if(C){const T=C;T.write&&y.add(w),T.read&&c.add(w)}else c.add(w),y.add(w);return a.readRelayUrls=Array.from(c),a.writeRelayUrls=Array.from(y),a}catch{}})()}tagReference(){return["p",this.pubkey]}referenceTags(s){const r=[["p",this.pubkey]];return s&&r[0].push("",s),r}publish(){var s=this;return(0,_home_runner_work_angor_hub_angor_hub_node_modules_angular_builders_custom_webpack_node_modules_babel_runtime_helpers_esm_asyncToGenerator_js__WEBPACK_IMPORTED_MODULE_1__.A)(function*(){if(!s.ndk)throw new Error("No NDK instance found");if(!s.profile)throw new Error("No profile available");s.ndk.assertSigner(),yield new NDKEvent(s.ndk,{kind:0,content:serializeProfile(s.profile)}).publish()})()}follow(s,r,i=3){var a=this;return(0,_home_runner_work_angor_hub_angor_hub_node_modules_angular_builders_custom_webpack_node_modules_babel_runtime_helpers_esm_asyncToGenerator_js__WEBPACK_IMPORTED_MODULE_1__.A)(function*(){if(!a.ndk)throw new Error("No NDK instance found");if(a.ndk.assertSigner(),r||(r=yield a.follows(void 0,void 0,i)),r.has(s))return!1;r.add(s);const c=new NDKEvent(a.ndk,{kind:i});for(const y of r)c.tag(y);return yield c.publish(),!0})()}validateNip05(s){var r=this;return(0,_home_runner_work_angor_hub_angor_hub_node_modules_angular_builders_custom_webpack_node_modules_babel_runtime_helpers_esm_asyncToGenerator_js__WEBPACK_IMPORTED_MODULE_1__.A)(function*(){if(!r.ndk)throw new Error("No NDK instance found");const i=yield getNip05For(s);return null===i?null:i.pubkey===r.pubkey})()}zap(s,r,i,a){var c=this;return(0,_home_runner_work_angor_hub_angor_hub_node_modules_angular_builders_custom_webpack_node_modules_babel_runtime_helpers_esm_asyncToGenerator_js__WEBPACK_IMPORTED_MODULE_1__.A)(function*(){if(!c.ndk)throw new Error("No NDK instance found");a||c.ndk.assertSigner();const y=new Zap({ndk:c.ndk,zappedUser:c}),w=Array.from(c.ndk.pool.relays.keys());return yield y.createZapRequest(s,r,i,w,a)})()}},NDKPrivateKeySigner=class pD{_user;privateKey;constructor(s){s&&(this.privateKey=s,this._user=new NDKUser({hexpubkey:getPublicKey(this.privateKey)}))}static generate(){const s=generatePrivateKey();return new pD(s)}blockUntilReady(){var s=this;return(0,_home_runner_work_angor_hub_angor_hub_node_modules_angular_builders_custom_webpack_node_modules_babel_runtime_helpers_esm_asyncToGenerator_js__WEBPACK_IMPORTED_MODULE_1__.A)(function*(){if(!s._user)throw new Error("NDKUser not initialized");return s._user})()}user(){var s=this;return(0,_home_runner_work_angor_hub_angor_hub_node_modules_angular_builders_custom_webpack_node_modules_babel_runtime_helpers_esm_asyncToGenerator_js__WEBPACK_IMPORTED_MODULE_1__.A)(function*(){return yield s.blockUntilReady(),s._user})()}sign(s){var r=this;return(0,_home_runner_work_angor_hub_angor_hub_node_modules_angular_builders_custom_webpack_node_modules_babel_runtime_helpers_esm_asyncToGenerator_js__WEBPACK_IMPORTED_MODULE_1__.A)(function*(){if(!r.privateKey)throw Error("Attempted to sign without a private key");return getSignature(s,r.privateKey)})()}encrypt(s,r){var i=this;return(0,_home_runner_work_angor_hub_angor_hub_node_modules_angular_builders_custom_webpack_node_modules_babel_runtime_helpers_esm_asyncToGenerator_js__WEBPACK_IMPORTED_MODULE_1__.A)(function*(){if(!i.privateKey)throw Error("Attempted to encrypt without a private key");const a=s.hexpubkey;return yield nip04_exports.encrypt(i.privateKey,a,r)})()}decrypt(s,r){var i=this;return(0,_home_runner_work_angor_hub_angor_hub_node_modules_angular_builders_custom_webpack_node_modules_babel_runtime_helpers_esm_asyncToGenerator_js__WEBPACK_IMPORTED_MODULE_1__.A)(function*(){if(!i.privateKey)throw Error("Attempted to decrypt without a private key");const a=s.hexpubkey;return yield nip04_exports.decrypt(i.privateKey,a,r)})()}},NDKNostrRpc=class extends lib$1.EventEmitter{ndk;signer;debug;constructor(o,s,r){super(),this.ndk=o,this.signer=s,this.debug=r.extend("rpc")}subscribe(o){var s=this;const r=this.ndk.subscribe(o,{closeOnEose:!1,groupable:!1});return r.on("event",function(){var i=(0,_home_runner_work_angor_hub_angor_hub_node_modules_angular_builders_custom_webpack_node_modules_babel_runtime_helpers_esm_asyncToGenerator_js__WEBPACK_IMPORTED_MODULE_1__.A)(function*(a){try{const c=yield s.parseEvent(a);s.emit(c.method?"request":`response-${c.id}`,c)}catch(c){s.debug("error parsing event",c,a.rawEvent())}});return function(a){return i.apply(this,arguments)}}()),new Promise((i,a)=>{r.on("eose",()=>i(r))})}parseEvent(o){var s=this;return(0,_home_runner_work_angor_hub_angor_hub_node_modules_angular_builders_custom_webpack_node_modules_babel_runtime_helpers_esm_asyncToGenerator_js__WEBPACK_IMPORTED_MODULE_1__.A)(function*(){const r=s.ndk.getUser({hexpubkey:o.pubkey});r.ndk=s.ndk;const i=yield s.signer.decrypt(r,o.content),a=JSON.parse(i),{id:c,method:y,params:w,result:C,error:T}=a;return y?{id:c,pubkey:o.pubkey,method:y,params:w,event:o}:{id:c,result:C,error:T,event:o}})()}sendResponse(o,s,r,i=24133,a){var c=this;return(0,_home_runner_work_angor_hub_angor_hub_node_modules_angular_builders_custom_webpack_node_modules_babel_runtime_helpers_esm_asyncToGenerator_js__WEBPACK_IMPORTED_MODULE_1__.A)(function*(){const y={id:o,result:r};a&&(y.error=a);const w=yield c.signer.user(),C=c.ndk.getUser({hexpubkey:s}),T=new NDKEvent(c.ndk,{kind:i,content:JSON.stringify(y),tags:[["p",s]],pubkey:w.hexpubkey});T.content=yield c.signer.encrypt(C,T.content),yield T.sign(c.signer),yield T.publish()})()}sendRequest(o,s,r=[],i=24133,a){var c=this;return(0,_home_runner_work_angor_hub_angor_hub_node_modules_angular_builders_custom_webpack_node_modules_babel_runtime_helpers_esm_asyncToGenerator_js__WEBPACK_IMPORTED_MODULE_1__.A)(function*(){const y=Math.random().toString(36).substring(7),w=yield c.signer.user(),C=c.ndk.getUser({hexpubkey:o}),T={id:y,method:s,params:r},S=new Promise(O=>{const L=Z=>{"auth_url"===Z.result?(c.once(`response-${y}`,L),c.emit("authUrl",Z.error)):a&&a(Z)};c.once(`response-${y}`,L)}),M=new NDKEvent(c.ndk,{kind:i,content:JSON.stringify(T),tags:[["p",o]],pubkey:w.pubkey});return M.content=yield c.signer.encrypt(C,M.content),yield M.sign(c.signer),c.debug(`sending ${s} request to`,o),yield M.publish(),S})()}},NDKNip46Signer=class extends lib$1.EventEmitter{ndk;remoteUser;remotePubkey;token;localSigner;nip05;rpc;debug;relayUrls=[];constructor(o,s,r){let i,a;if(super(),s.includes("#")){const c=s.split("#");i=new NDKUser({npub:c[0]}).pubkey,a=c[1]}else s.startsWith("npub")?i=new NDKUser({npub:s}).pubkey:s.match(/\./)?this.nip05=s:i=s;this.ndk=o,i&&(this.remotePubkey=i),this.token=a,this.debug=o.debug.extend("nip46:signer"),this.remoteUser=new NDKUser({pubkey:i}),this.localSigner=r||NDKPrivateKeySigner.generate(),this.rpc=new NDKNostrRpc(o,this.localSigner,this.debug),this.rpc.on("authUrl",(...c)=>{this.emit("authUrl",...c)}),this.localSigner.user().then(c=>{this.rpc.subscribe({kinds:[24133,24134],"#p":[c.pubkey]})})}user(){var o=this;return(0,_home_runner_work_angor_hub_angor_hub_node_modules_angular_builders_custom_webpack_node_modules_babel_runtime_helpers_esm_asyncToGenerator_js__WEBPACK_IMPORTED_MODULE_1__.A)(function*(){return o.remoteUser})()}blockUntilReady(){var o=this;return(0,_home_runner_work_angor_hub_angor_hub_node_modules_angular_builders_custom_webpack_node_modules_babel_runtime_helpers_esm_asyncToGenerator_js__WEBPACK_IMPORTED_MODULE_1__.A)(function*(){const s=yield o.localSigner.user(),r=o.ndk.getUser({pubkey:o.remotePubkey});if(o.nip05&&!o.remotePubkey&&NDKUser.fromNip05(o.nip05).then(i=>{i&&(o.remoteUser=i,o.remotePubkey=i.pubkey,o.relayUrls=i.nip46Urls)}),!o.remotePubkey)throw new Error("Remote pubkey not set");return new Promise((i,a)=>{setTimeout(()=>{const c=[s.pubkey];o.token&&c.push(o.token),o.rpc.sendRequest(o.remotePubkey,"connect",c,24133,y=>{"ack"===y.result?i(r):a(y.error)})},100)})})()}encrypt(o,s){var r=this;return(0,_home_runner_work_angor_hub_angor_hub_node_modules_angular_builders_custom_webpack_node_modules_babel_runtime_helpers_esm_asyncToGenerator_js__WEBPACK_IMPORTED_MODULE_1__.A)(function*(){return r.debug("asking for encryption"),new Promise((i,a)=>{r.rpc.sendRequest(r.remotePubkey,"nip04_encrypt",[o.pubkey,s],24133,c=>{c.error?a(c.error):i(c.result)})})})()}decrypt(o,s){var r=this;return(0,_home_runner_work_angor_hub_angor_hub_node_modules_angular_builders_custom_webpack_node_modules_babel_runtime_helpers_esm_asyncToGenerator_js__WEBPACK_IMPORTED_MODULE_1__.A)(function*(){return r.debug("asking for decryption"),new Promise((i,a)=>{r.rpc.sendRequest(r.remotePubkey,"nip04_decrypt",[o.pubkey,s],24133,c=>{if(c.error)a(c.error);else{const y=JSON.parse(c.result);i(y[0])}})})})()}sign(o){var s=this;return(0,_home_runner_work_angor_hub_angor_hub_node_modules_angular_builders_custom_webpack_node_modules_babel_runtime_helpers_esm_asyncToGenerator_js__WEBPACK_IMPORTED_MODULE_1__.A)(function*(){return s.debug("asking for a signature"),new Promise((r,i)=>{s.rpc.sendRequest(s.remotePubkey,"sign_event",[JSON.stringify(o)],24133,a=>{if(s.debug("got a response",a),a.error)i(a.error);else{const c=JSON.parse(a.result);r(c.sig)}})})})()}createAccount(o,s,r){var i=this;return(0,_home_runner_work_angor_hub_angor_hub_node_modules_angular_builders_custom_webpack_node_modules_babel_runtime_helpers_esm_asyncToGenerator_js__WEBPACK_IMPORTED_MODULE_1__.A)(function*(){i.debug("asking to create an account");const a=[];return o&&a.push(o),s&&a.push(s),r&&a.push(r),new Promise((c,y)=>{i.rpc.sendRequest(i.remotePubkey,"create_account",a,24134,w=>{i.debug("got a response",w),w.error?y(w.error):c(w.result)})})})()}};function dedup(o,s){return o.created_at>s.created_at?o:s}var OutboxItem=class{type;relayUrlScores;readRelays;writeRelays;constructor(o){this.type=o,this.relayUrlScores=new Map,this.readRelays=new Set,this.writeRelays=new Set}},OutboxTracker=class extends lib$1.EventEmitter{data;ndk;debug;constructor(o){super(),this.ndk=o,this.debug=o.debug.extend("outbox-tracker"),this.data=new dist.LRUCache({maxSize:1e5,entryExpirationTimeInMS:5e3})}trackUsers(o){for(const s of o){const r=getKeyFromItem(s);if(this.data.has(r))continue;const i=this.track(s,"user"),a=s instanceof NDKUser?s:new NDKUser({hexpubkey:s});a.ndk=this.ndk,a.relayList().then(c=>{if(c){i.readRelays=new Set(c.readRelayUrls),i.writeRelays=new Set(c.writeRelayUrls);for(const y of i.readRelays)this.ndk.pool.blacklistRelayUrls.has(y)&&(this.debug(`removing blacklisted relay ${y} from read relays`),i.readRelays.delete(y));for(const y of i.writeRelays)this.ndk.pool.blacklistRelayUrls.has(y)&&(this.debug(`removing blacklisted relay ${y} from write relays`),i.writeRelays.delete(y));this.data.set(r,i),this.debug(`Adding ${i.readRelays.size} read relays and ${i.writeRelays.size} write relays for ${a.hexpubkey}`)}})}}track(o,s){const r=getKeyFromItem(o);s??=getTypeFromItem(o);let i=this.data.get(r);return i||(i=new OutboxItem(s)),this.data.set(r,i),i}};function getKeyFromItem(o){return o instanceof NDKUser?o.hexpubkey:o}function getTypeFromItem(o){return o instanceof NDKUser?"user":"kind"}var NDKPool=class extends lib$1.EventEmitter{relays=new Map;blacklistRelayUrls;debug;temporaryRelayTimers=new Map;flappingRelays=new Set;backoffTimes=new Map;constructor(o=[],s=[],r,i){super(),this.debug=i??r.debug.extend("pool");for(const a of o){const c=new NDKRelay(a);this.addRelay(c,!1)}this.blacklistRelayUrls=new Set(s)}useTemporaryRelay(o,s=6e5){const r=this.relays.has(o.url);r||this.addRelay(o);const i=this.temporaryRelayTimers.get(o.url);if(i&&clearTimeout(i),!r||i){const a=setTimeout(()=>{this.removeRelay(o.url)},s);this.temporaryRelayTimers.set(o.url,a)}}addRelay(o,s=!0){var r=this;const i=o.url;this.blacklistRelayUrls?.has(i)?this.debug(`Relay ${i} is blacklisted`):(o.on("notice",function(){var a=(0,_home_runner_work_angor_hub_angor_hub_node_modules_angular_builders_custom_webpack_node_modules_babel_runtime_helpers_esm_asyncToGenerator_js__WEBPACK_IMPORTED_MODULE_1__.A)(function*(c,y){return r.emit("notice",c,y)});return function(c,y){return a.apply(this,arguments)}}()),o.on("connect",()=>this.handleRelayConnect(i)),o.on("ready",()=>this.handleRelayReady(o)),o.on("disconnect",(0,_home_runner_work_angor_hub_angor_hub_node_modules_angular_builders_custom_webpack_node_modules_babel_runtime_helpers_esm_asyncToGenerator_js__WEBPACK_IMPORTED_MODULE_1__.A)(function*(){return r.emit("relay:disconnect",o)})),o.on("flapping",()=>this.handleFlapping(o)),o.on("auth",function(){var a=(0,_home_runner_work_angor_hub_angor_hub_node_modules_angular_builders_custom_webpack_node_modules_babel_runtime_helpers_esm_asyncToGenerator_js__WEBPACK_IMPORTED_MODULE_1__.A)(function*(c){return r.emit("relay:auth",o,c)});return function(c){return a.apply(this,arguments)}}()),this.relays.set(i,o),s&&o.connect().catch(a=>{this.debug(`Failed to connect to relay ${i}`,a)}))}removeRelay(o){const s=this.relays.get(o);if(s)return s.disconnect(),this.relays.delete(o),this.emit("relay:disconnect",s),!0;const r=this.temporaryRelayTimers.get(o);return r&&(clearTimeout(r),this.temporaryRelayTimers.delete(o)),!1}getRelay(o,s=!0){let r=this.relays.get(o);return r||(r=new NDKRelay(o),this.addRelay(r,s)),r}handleRelayConnect(o){this.debug(`Relay ${o} connected`),this.emit("relay:connect",this.relays.get(o)),this.stats().connected===this.relays.size&&this.emit("connect")}handleRelayReady(o){this.debug(`Relay ${o.url} ready`),this.emit("relay:ready",o)}connect(o){var s=this;return(0,_home_runner_work_angor_hub_angor_hub_node_modules_angular_builders_custom_webpack_node_modules_babel_runtime_helpers_esm_asyncToGenerator_js__WEBPACK_IMPORTED_MODULE_1__.A)(function*(){const r=[];s.debug(`Connecting to ${s.relays.size} relays${o?`, timeout ${o}...`:""}`);for(const i of s.relays.values())if(o){const a=new Promise((c,y)=>{setTimeout(()=>y(`Timed out after ${o}ms`),o)});r.push(Promise.race([i.connect(),a]).catch(c=>{s.debug(`Failed to connect to relay ${i.url}: ${c??"No reason specified"}`)}))}else r.push(i.connect());o&&setTimeout(()=>{const i=s.stats().connected===s.relays.size,a=s.stats().connected>0;!i&&a&&s.emit("connect")},o),yield Promise.all(r)})()}checkOnFlappingRelays(){if(this.flappingRelays.size/this.relays.size>=.8)for(const o of this.flappingRelays)this.backoffTimes.set(o,0)}handleFlapping(o){this.debug(`Relay ${o.url} is flapping`);let s=this.backoffTimes.get(o.url)||5e3;s*=2,this.backoffTimes.set(o.url,s),this.debug(`Backoff time for ${o.url} is ${s}ms`),setTimeout(()=>{this.debug(`Attempting to reconnect to ${o.url}`),o.connect(),this.checkOnFlappingRelays()},s),o.disconnect(),this.emit("flapping",o)}size(){return this.relays.size}stats(){const o={total:0,connected:0,disconnected:0,connecting:0};for(const s of this.relays.values())o.total++,1===s.status?o.connected++:3===s.status?o.disconnected++:0===s.status&&o.connecting++;return o}connectedRelays(){return Array.from(this.relays.values()).filter(o=>1===o.status)}urls(){return Array.from(this.relays.keys())}};function correctRelaySet(o,s){const r=s.connectedRelays();if(!Array.from(o.relays).some(i=>r.map(a=>a.url).includes(i.url)))for(const i of r)o.addRelay(i);if(0===r.length)for(const i of s.relays.values())o.addRelay(i);return o}var SPEC_PATH="/.well-known/nostr/nip96.json",Nip96=class{ndk;spec;url;nip98Required=!1;constructor(o,s){this.url=`https://${o}${SPEC_PATH}`,this.ndk=s}prepareUpload(o,s="POST"){var r=this;return(0,_home_runner_work_angor_hub_angor_hub_node_modules_angular_builders_custom_webpack_node_modules_babel_runtime_helpers_esm_asyncToGenerator_js__WEBPACK_IMPORTED_MODULE_1__.A)(function*(){if(r.validateHttpFetch(),r.spec||(yield r.fetchSpec()),!r.spec)throw new Error("Failed to fetch NIP96 spec");let i={};return r.nip98Required&&(i={Authorization:yield r.generateNip98Header(r.spec.api_url,s,o)}),{url:r.spec.api_url,headers:i}})()}xhrUpload(o,s){var r=this;return(0,_home_runner_work_angor_hub_angor_hub_node_modules_angular_builders_custom_webpack_node_modules_babel_runtime_helpers_esm_asyncToGenerator_js__WEBPACK_IMPORTED_MODULE_1__.A)(function*(){const i="POST",{url:a,headers:c}=yield r.prepareUpload(s,i);o.open(i,a,!0),c.Authorization&&o.setRequestHeader("Authorization",c.Authorization);const y=new FormData;return y.append("file",s),new Promise((w,C)=>{o.onload=function(){o.status>=200&&o.status<300?w(JSON.parse(o.responseText)):C(new Error(o.statusText))},o.onerror=function(){C(new Error("Network Error"))},o.send(y)})})()}upload(o){var s=this;return(0,_home_runner_work_angor_hub_angor_hub_node_modules_angular_builders_custom_webpack_node_modules_babel_runtime_helpers_esm_asyncToGenerator_js__WEBPACK_IMPORTED_MODULE_1__.A)(function*(){const r="POST",{url:i,headers:a}=yield s.prepareUpload(o,r),c=new FormData;c.append("file",o);const y=yield s.ndk.httpFetch(s.spec.api_url,{method:r,headers:a,body:c});if(200!==y.status)throw new Error(`Failed to upload file to ${i}`);const w=yield y.json();if("success"!==w.status)throw new Error(w.message);return w})()}validateHttpFetch(){if(!this.ndk)throw new Error("NDK is required to fetch NIP96 spec");if(!this.ndk.httpFetch)throw new Error("NDK must have an httpFetch method to fetch NIP96 spec")}fetchSpec(){var o=this;return(0,_home_runner_work_angor_hub_angor_hub_node_modules_angular_builders_custom_webpack_node_modules_babel_runtime_helpers_esm_asyncToGenerator_js__WEBPACK_IMPORTED_MODULE_1__.A)(function*(){o.validateHttpFetch();const s=yield o.ndk.httpFetch(o.url);if(200!==s.status)throw new Error(`Failed to fetch NIP96 spec from ${o.url}`);const r=yield s.json();if(!r)throw new Error(`Failed to parse NIP96 spec from ${o.url}`);o.spec=r,o.nip98Required=o.spec.plans.free.is_nip98_required})()}generateNip98Header(o,s,r){var i=this;return(0,_home_runner_work_angor_hub_angor_hub_node_modules_angular_builders_custom_webpack_node_modules_babel_runtime_helpers_esm_asyncToGenerator_js__WEBPACK_IMPORTED_MODULE_1__.A)(function*(){const a=new NDKEvent(i.ndk,{kind:27235,tags:[["u",o],["method",s]]});if(["POST","PUT","PATCH"].includes(s)){const c=yield i.calculateSha256(r);a.tags.push(["payload",c])}return yield a.sign(),`Nostr ${btoa(JSON.stringify(a.rawEvent()))}`})()}calculateSha256(o){return(0,_home_runner_work_angor_hub_angor_hub_node_modules_angular_builders_custom_webpack_node_modules_babel_runtime_helpers_esm_asyncToGenerator_js__WEBPACK_IMPORTED_MODULE_1__.A)(function*(){const s=yield o.arrayBuffer(),r=yield crypto.subtle.digest("SHA-256",s);return Array.from(new Uint8Array(r)).map(i=>i.toString(16).padStart(2,"0")).join("")})()}},DEFAULT_OUTBOX_RELAYS=["wss://purplepag.es","wss://relay.snort.social"],DEFAULT_BLACKLISTED_RELAYS=["wss://brb.io"],NDK=class extends lib$1.EventEmitter{explicitRelayUrls;pool;outboxPool;_signer;_activeUser;cacheAdapter;debug;devWriteRelaySet;outboxTracker;mutedIds;clientName;clientNip89;relayAuthDefaultPolicy;httpFetch;autoConnectUserRelays=!0;autoFetchUserMutelist=!0;constructor(o={}){var s;super(),s=this,this.debug=o.debug||debug3("ndk"),this.explicitRelayUrls=o.explicitRelayUrls||[],this.pool=new NDKPool(o.explicitRelayUrls||[],o.blacklistRelayUrls,this),this.debug(`Starting with explicit relays: ${JSON.stringify(this.explicitRelayUrls)}`),this.pool.on("relay:auth",function(){var r=(0,_home_runner_work_angor_hub_angor_hub_node_modules_angular_builders_custom_webpack_node_modules_babel_runtime_helpers_esm_asyncToGenerator_js__WEBPACK_IMPORTED_MODULE_1__.A)(function*(i,a){s.relayAuthDefaultPolicy&&(yield s.relayAuthDefaultPolicy(i,a))});return function(i,a){return r.apply(this,arguments)}}()),this.autoConnectUserRelays=o.autoConnectUserRelays??!0,this.autoFetchUserMutelist=o.autoFetchUserMutelist??!0,this.clientName=o.clientName,this.clientNip89=o.clientNip89,this.relayAuthDefaultPolicy=o.relayAuthDefaultPolicy,o.enableOutboxModel&&(this.outboxPool=new NDKPool(o.outboxRelayUrls||DEFAULT_OUTBOX_RELAYS,o.blacklistRelayUrls||DEFAULT_BLACKLISTED_RELAYS,this,this.debug.extend("outbox-pool")),this.outboxTracker=new OutboxTracker(this)),this.signer=o.signer,this.cacheAdapter=o.cacheAdapter,this.mutedIds=o.mutedIds||new Map,o.devWriteRelayUrls&&(this.devWriteRelaySet=NDKRelaySet.fromRelayUrls(o.devWriteRelayUrls,this));try{this.httpFetch=fetch}catch{}}addExplicitRelay(o,s,r=!0){let i;return i="string"==typeof o?new NDKRelay(o,s):o,this.pool.addRelay(i,r),this.explicitRelayUrls.push(i.url),i}toJSON(){return{relayCount:this.pool.relays.size}.toString()}get activeUser(){return this._activeUser}set activeUser(o){var s=this;const r=this._activeUser?.pubkey!==o?.pubkey;if(this._activeUser=o,o&&r){const i=function(){var C=(0,_home_runner_work_angor_hub_angor_hub_node_modules_angular_builders_custom_webpack_node_modules_babel_runtime_helpers_esm_asyncToGenerator_js__WEBPACK_IMPORTED_MODULE_1__.A)(function*(T){const S=yield T.relayList();if(S){s.debug("Connecting to user relays",{npub:T.npub,relays:S.relays});for(const M of S.relays){let O=s.pool.relays.get(M);O||(O=new NDKRelay(M),s.pool.addRelay(O))}}else s.debug("No relay list found for user",{npub:T.npub})});return function(S){return C.apply(this,arguments)}}(),a=function(){var C=(0,_home_runner_work_angor_hub_angor_hub_node_modules_angular_builders_custom_webpack_node_modules_babel_runtime_helpers_esm_asyncToGenerator_js__WEBPACK_IMPORTED_MODULE_1__.A)(function*(T){const S=yield s.fetchEvents([{kinds:[1e4],authors:[T.pubkey]},{kinds:[3e4],authors:[T.pubkey],"#d":["mute"],limit:1}]);if(S)for(const M of S){const O=lists_default.from(M);for(const L of O.items)s.mutedIds.set(L[1],L[0])}else s.debug("No mute list found for user",{npub:T.npub})});return function(S){return C.apply(this,arguments)}}(),c=[];this.autoConnectUserRelays&&c.push(i),this.autoFetchUserMutelist&&c.push(a);const y=function(){var C=(0,_home_runner_work_angor_hub_angor_hub_node_modules_angular_builders_custom_webpack_node_modules_babel_runtime_helpers_esm_asyncToGenerator_js__WEBPACK_IMPORTED_MODULE_1__.A)(function*(T){for(const S of c)yield S(T)});return function(S){return C.apply(this,arguments)}}(),w=this.outboxPool||this.pool;w.connectedRelays.length>0?y(o):(this.debug("Waiting for connection to main relays"),w.once("relay:ready",C=>{this.debug("New relay ready",C?.url),y(o)}))}else o||(this.mutedIds=new Map)}get signer(){return this._signer}set signer(o){this._signer=o,this.emit("signer:ready",o),o?.user().then(s=>{s.ndk=this,this.activeUser=s})}connect(o){var s=this;return(0,_home_runner_work_angor_hub_angor_hub_node_modules_angular_builders_custom_webpack_node_modules_babel_runtime_helpers_esm_asyncToGenerator_js__WEBPACK_IMPORTED_MODULE_1__.A)(function*(){s._signer&&s.autoConnectUserRelays&&(s.debug("Attempting to connect to user relays specified by signer"),s._signer.relays)&&(yield s._signer.relays()).forEach(i=>s.pool.addRelay(i));const r=[s.pool.connect(o)];return s.outboxPool&&r.push(s.outboxPool.connect(o)),s.debug("Connecting to relays",{timeoutMs:o}),Promise.allSettled(r).then(()=>{})})()}getUser(o){const s=new NDKUser(o);return s.ndk=this,s}getUserFromNip05(o,s=!1){var r=this;return(0,_home_runner_work_angor_hub_angor_hub_node_modules_angular_builders_custom_webpack_node_modules_babel_runtime_helpers_esm_asyncToGenerator_js__WEBPACK_IMPORTED_MODULE_1__.A)(function*(){return NDKUser.fromNip05(o,r,s)})()}subscribe(o,s,r,i=!0){const a=new NDKSubscription(this,o,s,r);if(r)for(const c of r.relays)this.pool.useTemporaryRelay(c);if(this.outboxPool&&a.hasAuthorsFilter()){const c=a.filters.filter(y=>y.authors&&y.authors?.length>0).map(y=>y.authors).flat();this.outboxTracker?.trackUsers(c)}return i&&a.start(),a}publish(o,s,r){var i=this;return(0,_home_runner_work_angor_hub_angor_hub_node_modules_angular_builders_custom_webpack_node_modules_babel_runtime_helpers_esm_asyncToGenerator_js__WEBPACK_IMPORTED_MODULE_1__.A)(function*(){return i.debug("Deprecated: Use `event.publish()` instead"),o.publish(s,r)})()}fetchEvent(o,s,r){var i=this;return(0,_home_runner_work_angor_hub_angor_hub_node_modules_angular_builders_custom_webpack_node_modules_babel_runtime_helpers_esm_asyncToGenerator_js__WEBPACK_IMPORTED_MODULE_1__.A)(function*(){let a,c;if(r instanceof NDKRelay?c=new NDKRelaySet(new Set([r]),i):r instanceof NDKRelaySet&&(c=r),!r&&"string"==typeof o&&!isNip33AValue(o)){const y=relaysFromBech32(o);y.length>0&&(c=new NDKRelaySet(new Set(y),i),c=correctRelaySet(c,i.pool))}if(a="string"==typeof o?filterFromId(o):o,!a)throw new Error(`Invalid filter: ${JSON.stringify(o)}`);return new Promise(y=>{const w=i.subscribe(a,{...s||{},closeOnEose:!0},c,!1);w.on("event",C=>{C.ndk=i,y(C)}),w.on("eose",()=>{y(null)}),w.start()})})()}fetchEvents(o,s,r){var i=this;return(0,_home_runner_work_angor_hub_angor_hub_node_modules_angular_builders_custom_webpack_node_modules_babel_runtime_helpers_esm_asyncToGenerator_js__WEBPACK_IMPORTED_MODULE_1__.A)(function*(){return new Promise(a=>{const c=new Map,y=i.subscribe(o,{...s||{},closeOnEose:!0},r,!1),w=C=>{const T=C.deduplicationKey(),S=c.get(T);S&&(C=dedup(S,C)),C.ndk=i,c.set(T,C)};y.on("event",w),y.on("event:dup",w),y.on("eose",()=>{a(new Set(c.values()))}),y.start()})})()}assertSigner(){if(!this.signer)throw this.emit("signerRequired"),new Error("Signer required")}getNip96(o){return new Nip96(o,this)}};const LOCAL_STORE_KEY="__nostrlogin_nip46",LOGGED_IN_ACCOUNTS="__nostrlogin_accounts",RECENT_ACCOUNTS="__nostrlogin_recent",OUTBOX_RELAYS$1=["wss://purplepag.es","wss://relay.nos.social","wss://user.kindpag.es","wss://relay.damus.io","wss://nos.lol"],DEFAULT_SIGNUP_RELAYS=["wss://relay.damus.io/","wss://nos.lol/","wss://relay.primal.net/"],localStorageSetItem=(o,s)=>{localStorage.setItem(o,s)},localStorageGetItem=o=>{const s=window.localStorage.getItem(o);if(s)try{return JSON.parse(s)}catch{}return null},localStorageRemoveItem=o=>{localStorage.removeItem(o)},fetchProfile=function(){var o=(0,_home_runner_work_angor_hub_angor_hub_node_modules_angular_builders_custom_webpack_node_modules_babel_runtime_helpers_esm_asyncToGenerator_js__WEBPACK_IMPORTED_MODULE_1__.A)(function*(s,r){const i=new NDKUser({pubkey:s.pubkey});return i.ndk=r,yield i.fetchProfile()});return function(r,i){return o.apply(this,arguments)}}(),createProfile=function(){var o=(0,_home_runner_work_angor_hub_angor_hub_node_modules_angular_builders_custom_webpack_node_modules_babel_runtime_helpers_esm_asyncToGenerator_js__WEBPACK_IMPORTED_MODULE_1__.A)(function*(s,r,i,a){const c={name:s.name},y=new NDKEvent(r,{kind:0,created_at:Math.floor(Date.now()/1e3),pubkey:s.pubkey,content:JSON.stringify(c),tags:[]});window.location.hostname&&y.tags.push(["client",window.location.hostname]);const w=new NDKEvent(r,{kind:10002,created_at:Math.floor(Date.now()/1e3),pubkey:s.pubkey,content:"",tags:[]}),C=(a||"").split(",").map(T=>T.trim()).filter(T=>T.startsWith("ws"));C.length||C.push(...DEFAULT_SIGNUP_RELAYS);for(const T of C)w.tags.push(["r",T]);yield y.sign(i),console.log("signed profile",y),yield w.sign(i),console.log("signed relays",w),yield y.publish(NDKRelaySet.fromRelayUrls(OUTBOX_RELAYS$1,r)),console.log("published profile",y),yield w.publish(NDKRelaySet.fromRelayUrls(OUTBOX_RELAYS$1,r)),console.log("published relays",w)});return function(r,i,a,c){return o.apply(this,arguments)}}(),bunkerUrlToInfo=(o,s="")=>{const r=new URL(o);return{pubkey:r.hostname||r.pathname.split("//")[1],sk:s||generatePrivateKey(),relays:r.searchParams.getAll("relay"),token:r.searchParams.get("secret")||"",authMethod:"connect"}},isBunkerUrl=o=>o.startsWith("bunker://"),getBunkerUrl=function(){var o=(0,_home_runner_work_angor_hub_angor_hub_node_modules_angular_builders_custom_webpack_node_modules_babel_runtime_helpers_esm_asyncToGenerator_js__WEBPACK_IMPORTED_MODULE_1__.A)(function*(s,r){if(!s)return"";if(isBunkerUrl(s))return s;if(s.includes("@")){const[i,a]=s.toLocaleLowerCase().split("@"),c=r.devOverrideBunkerOrigin||`https://${a}`,y=`${c}/.well-known/nostr.json?name=_`,w=`${c}/.well-known/nostr.json?name=${i}`,C=yield fetch(y),T=yield C.json(),M=T.nip46[T.names._],O=yield fetch(w),L=(yield O.json()).names[i];if(!M.length)throw new Error("Bunker relay not provided");return`bunker://${L}?relay=${M[0]}`}throw new Error("Invalid user name or bunker url")});return function(r,i){return o.apply(this,arguments)}}(),checkNip05=function(){var o=(0,_home_runner_work_angor_hub_angor_hub_node_modules_angular_builders_custom_webpack_node_modules_babel_runtime_helpers_esm_asyncToGenerator_js__WEBPACK_IMPORTED_MODULE_1__.A)(function*(s){let r=!1,i="",a="";return yield(0,_home_runner_work_angor_hub_angor_hub_node_modules_angular_builders_custom_webpack_node_modules_babel_runtime_helpers_esm_asyncToGenerator_js__WEBPACK_IMPORTED_MODULE_1__.A)(function*(){if(!s||!s.includes("@"))return;const[c,y]=s.toLocaleLowerCase().split("@");if(!c)return;if(!new RegExp(/^[\w-.]+@([\w-]+\.)+[\w-]{2,8}$/g).test(s))return void(i="Invalid name");if(!y)return void(i="Select service");const w=`https://${y}/.well-known/nostr.json?name=${c.toLowerCase()}`;try{const C=yield fetch(w),T=yield C.json();if(T.names[c])return void(a=T.names[c])}catch{}r=!0})(),{available:r,taken:""!=a,error:i,pubkey:a}});return function(r){return o.apply(this,arguments)}}(),upgradeInfo=o=>{"typeAuthMethod"in o&&delete o.typeAuthMethod,o.authMethod||(o.authMethod="extension"in o&&o.extension?"extension":"readOnly"in o&&o.readOnly?"readOnly":"connect"),o.nip05&&isBunkerUrl(o.nip05)&&(o.bunkerUrl=o.nip05,o.nip05="")},localStorageAddAccount=o=>{localStorageSetItem(LOCAL_STORE_KEY,JSON.stringify(o));const s=localStorageGetItem(LOGGED_IN_ACCOUNTS)||[],r=localStorageGetItem(RECENT_ACCOUNTS)||[];s.forEach(y=>upgradeInfo(y)),r.forEach(y=>upgradeInfo(y));const i=s,a=s.findIndex(y=>y.pubkey===o.pubkey&&y.authMethod===o.authMethod);-1!==a?i[a]=o:i.push(o);const c=r.filter(y=>y.pubkey!==o.pubkey||y.authMethod!==o.authMethod);localStorageSetItem(RECENT_ACCOUNTS,JSON.stringify(c)),localStorageSetItem(LOGGED_IN_ACCOUNTS,JSON.stringify(i))},localStorageRemoveCurrentAccount=()=>{const o=localStorageGetItem(LOCAL_STORE_KEY);if(!o)return;upgradeInfo(o);const s={...o};delete s.sk,delete s.otpData;const r=localStorageGetItem(LOGGED_IN_ACCOUNTS)||[],i=localStorageGetItem(RECENT_ACCOUNTS)||[];r.forEach(y=>upgradeInfo(y)),i.forEach(y=>upgradeInfo(y));const a=i;if("connect"===s.authMethod&&s.bunkerUrl&&s.bunkerUrl.includes("secret="))console.log("nostr login bunker conn with a secret not saved to recent");else if("local"===s.authMethod)console.log("nostr login temporary local keys not save to recent");else{const y=i.findIndex(w=>w.pubkey===s.pubkey&&w.authMethod===s.authMethod);-1!==y?a[y]=s:a.push(s)}const c=r.filter(y=>y.pubkey!==o.pubkey||y.authMethod!==o.authMethod);localStorageSetItem(RECENT_ACCOUNTS,JSON.stringify(a)),localStorageSetItem(LOGGED_IN_ACCOUNTS,JSON.stringify(c)),localStorageRemoveItem(LOCAL_STORE_KEY)},localStorageRemoveRecent=o=>{const s=localStorageGetItem(RECENT_ACCOUNTS)||[];s.forEach(i=>upgradeInfo(i));const r=s.filter(i=>i.pubkey!==o.pubkey||i.authMethod!==o.authMethod);localStorageSetItem(RECENT_ACCOUNTS,JSON.stringify(r))},localStorageGetRecents=()=>{const o=localStorageGetItem(RECENT_ACCOUNTS)||[];return o.forEach(s=>upgradeInfo(s)),o},localStorageGetAccounts=()=>{const o=localStorageGetItem(LOGGED_IN_ACCOUNTS)||[];return o.forEach(s=>upgradeInfo(s)),o},localStorageGetCurrent=()=>{const o=localStorageGetItem(LOCAL_STORE_KEY);return o&&upgradeInfo(o),o},getDarkMode=o=>{const s=localStorage.getItem("nl-dark-mode");return s?!!JSON.parse(s):void 0!==o.darkMode?o.darkMode:!(!window.matchMedia||!window.matchMedia("(prefers-color-scheme: dark)").matches)},getIcon=function(){var o=(0,_home_runner_work_angor_hub_angor_hub_node_modules_angular_builders_custom_webpack_node_modules_babel_runtime_helpers_esm_asyncToGenerator_js__WEBPACK_IMPORTED_MODULE_1__.A)(function*(){return document.location.origin+"/favicon.ico"});return function(){return o.apply(this,arguments)}}();class NostrRpc extends NDKNostrRpc{pubkey;_ndk;_signer;requests=new Set;sub;_useNip44=!1;constructor(s,r,i){super(s,i,s.debug.extend("nip46:signer:rpc")),this._ndk=s,this._signer=i,this.pubkey=r}subscribe(s){var r=()=>super.subscribe,i=this;return(0,_home_runner_work_angor_hub_angor_hub_node_modules_angular_builders_custom_webpack_node_modules_babel_runtime_helpers_esm_asyncToGenerator_js__WEBPACK_IMPORTED_MODULE_1__.A)(function*(){return i.sub=yield r().call(i,s),i.sub})()}stop(){this.sub&&(this.sub.stop(),this.sub=void 0)}setUseNip44(s){this._useNip44=s}isNip04(s){const r=s.length;return!(r<28)&&"?"===s[r-28]&&"i"===s[r-27]&&"v"===s[r-26]&&"="===s[r-25]}parseEvent(s){var r=this;return(0,_home_runner_work_angor_hub_angor_hub_node_modules_angular_builders_custom_webpack_node_modules_babel_runtime_helpers_esm_asyncToGenerator_js__WEBPACK_IMPORTED_MODULE_1__.A)(function*(){const i=r._ndk.getUser({pubkey:s.pubkey});i.ndk=r._ndk;const a=r.isNip04(s.content)?r._signer.decrypt:r._signer.decryptNip44;console.log("client event nip04",r.isNip04(s.content));const c=yield a.call(r._signer,i,s.content),y=JSON.parse(c),{id:w,method:C,params:T,result:S,error:M}=y;return C?{id:w,pubkey:s.pubkey,method:C,params:T,event:s}:{id:w,result:S,error:M,event:s}})()}parseNostrConnectReply(s,r){var i=this;return(0,_home_runner_work_angor_hub_angor_hub_node_modules_angular_builders_custom_webpack_node_modules_babel_runtime_helpers_esm_asyncToGenerator_js__WEBPACK_IMPORTED_MODULE_1__.A)(function*(){const a=new NDKEvent(i._ndk,s),c=yield i.parseEvent(a);if(console.log("nostr connect parsedEvent",c),c.method)throw new Error("Bad nostr connect reply");if(c.result===r)return a.pubkey;throw new Error(c.error)})()}listen(s){var r=this;return(0,_home_runner_work_angor_hub_angor_hub_node_modules_angular_builders_custom_webpack_node_modules_babel_runtime_helpers_esm_asyncToGenerator_js__WEBPACK_IMPORTED_MODULE_1__.A)(function*(){const i=r.pubkey;console.log("nostr-login listening for conn to",i);const a=yield r.subscribe({kinds:[24133],"#p":[i]});return new Promise((c,y)=>{a.on("event",function(){var w=(0,_home_runner_work_angor_hub_angor_hub_node_modules_angular_builders_custom_webpack_node_modules_babel_runtime_helpers_esm_asyncToGenerator_js__WEBPACK_IMPORTED_MODULE_1__.A)(function*(C){try{const T=yield r.parseEvent(C);if(!T.method){const S=T;if("auth_url"===S.result)return;"ack"===S.result||S.result===s?c(C.pubkey):y(S.error)}}catch(T){console.log("error parsing event",T,C.rawEvent())}r.stop()});return function(C){return w.apply(this,arguments)}}())})})()}connect(s,r){var i=this;return(0,_home_runner_work_angor_hub_angor_hub_node_modules_angular_builders_custom_webpack_node_modules_babel_runtime_helpers_esm_asyncToGenerator_js__WEBPACK_IMPORTED_MODULE_1__.A)(function*(){return new Promise((a,c)=>{i.sendRequest(s.pubkey,"connect",[s.pubkey,s.token||"",r||""],24133,w=>{"ack"===w.result?a():c(w.error)})})})()}getId(){return Math.random().toString(36).substring(7)}sendRequest(s,r,i=[],a=24133,c){var y=this;return(0,_home_runner_work_angor_hub_angor_hub_node_modules_angular_builders_custom_webpack_node_modules_babel_runtime_helpers_esm_asyncToGenerator_js__WEBPACK_IMPORTED_MODULE_1__.A)(function*(){const w=y.getId();y.setResponseHandler(w,c),yield(yield y.createRequestEvent(w,s,r,i,a)).publish()})()}setResponseHandler(s,r){let i=!1;const a=Date.now();return new Promise(()=>{const c=y=>{"auth_url"===y.result?(this.once(`response-${s}`,c),i||(i=!0,this.emit("authUrl",y.error))):r&&this.requests.has(s)&&(this.requests.delete(s),console.log("nostr-login iframe processed request in",Date.now()-a,"ms"),r(y))};this.once(`response-${s}`,c)})}createRequestEvent(s,r,i,a=[],c=24133){var y=this;return(0,_home_runner_work_angor_hub_angor_hub_node_modules_angular_builders_custom_webpack_node_modules_babel_runtime_helpers_esm_asyncToGenerator_js__WEBPACK_IMPORTED_MODULE_1__.A)(function*(){y.requests.add(s);const w=yield y._signer.user(),C=y._ndk.getUser({pubkey:r}),S=new NDKEvent(y._ndk,{kind:c,content:JSON.stringify({id:s,method:i,params:a}),tags:[["p",r]],pubkey:w.pubkey}),M=y._useNip44&&"create_account"!==i?y._signer.encryptNip44:y._signer.encrypt;return S.content=yield M.call(y._signer,C,S.content),yield S.sign(y._signer),S})()}}class IframeNostrRpc extends NostrRpc{peerOrigin;iframePort;iframeRequests=new Map;constructor(s,r,i,a){super(s,r,i),this._ndk=s,this.peerOrigin=a}subscribe(s){var r=()=>super.subscribe,i=this;return(0,_home_runner_work_angor_hub_angor_hub_node_modules_angular_builders_custom_webpack_node_modules_babel_runtime_helpers_esm_asyncToGenerator_js__WEBPACK_IMPORTED_MODULE_1__.A)(function*(){return i.peerOrigin?new NDKSubscription(i._ndk,s,{closeOnEose:!0,cacheUsage:NDKSubscriptionCacheUsage.ONLY_CACHE}):r().call(i,s)})()}setWorkerIframePort(s){var r=this;if(!this.peerOrigin)throw new Error("Unexpected iframe port");this.iframePort=s,s.onmessage=function(){var i=(0,_home_runner_work_angor_hub_angor_hub_node_modules_angular_builders_custom_webpack_node_modules_babel_runtime_helpers_esm_asyncToGenerator_js__WEBPACK_IMPORTED_MODULE_1__.A)(function*(a){if(console.log("iframe-nip46 got response",a.data),"string"==typeof a.data&&a.data.startsWith("errorNoKey")){const c=a.data.split(":")[1],{id:y="",pubkey:w=""}=r.iframeRequests.get(c)||{};y&&w&&r.requests.has(y)&&r.emit(`iframeRestart-${w}`)}else try{const c=a.data;if(!validateEvent(c))throw new Error("Invalid event from iframe");if(!verifySignature(c))throw new Error("Invalid event signature from iframe");const y=new NDKEvent(r._ndk,c),w=yield r.parseEvent(y);w.method||(console.log("parsed response",w),r.emit(`response-${w.id}`,w))}catch(c){console.log("error parsing event",c,a.data)}});return function(a){return i.apply(this,arguments)}}()}sendRequest(s,r,i=[],a=24133,c){var y=this;return(0,_home_runner_work_angor_hub_angor_hub_node_modules_angular_builders_custom_webpack_node_modules_babel_runtime_helpers_esm_asyncToGenerator_js__WEBPACK_IMPORTED_MODULE_1__.A)(function*(){const w=y.getId(),C=yield y.createRequestEvent(w,s,r,i,a);y.setResponseHandler(w,c),y.iframePort?(y.iframeRequests.set(C.id,{id:w,pubkey:s}),console.log("iframe-nip46 sending request to",y.peerOrigin,C.rawEvent()),y.iframePort.postMessage(C.rawEvent())):yield C.publish()})()}}class ReadyListener{origin;messages;promise;constructor(s,r){var i=this;this.origin=r,this.messages=s,this.promise=new Promise(a=>{console.log(new Date,"started listener for",this.messages);const c=function(){var y=(0,_home_runner_work_angor_hub_angor_hub_node_modules_angular_builders_custom_webpack_node_modules_babel_runtime_helpers_esm_asyncToGenerator_js__WEBPACK_IMPORTED_MODULE_1__.A)(function*(w){const C=new URL(r).hostname,T=new URL(w.origin).hostname;(T===C||T.endsWith("."+C))&&Array.isArray(w.data)&&w.data.length&&i.messages.includes(w.data[0])&&(console.log(new Date,"got ready message from",w.origin,w.data),window.removeEventListener("message",c),a(w.data))});return function(C){return y.apply(this,arguments)}}();window.addEventListener("message",c)})}wait(){var s=this;return(0,_home_runner_work_angor_hub_angor_hub_node_modules_angular_builders_custom_webpack_node_modules_babel_runtime_helpers_esm_asyncToGenerator_js__WEBPACK_IMPORTED_MODULE_1__.A)(function*(){console.log(new Date,"waiting for",s.messages);const r=yield s.promise;return console.log(new Date,"finished waiting for",s.messages,r),r})()}}class BannerManager extends lib$1.EventEmitter{banner=null;iframeReady;params;constructor(s){super(),this.params=s}onAuthUrl(s,r){this.banner&&(this.banner.notify=s?{mode:r?"iframeAuthUrl":"authUrl",url:s}:{mode:""})}onIframeRestart(s){this.banner&&(this.iframeReady=new ReadyListener(["rebinderDone","rebinderError"],new URL(s).origin),this.banner.notify={mode:"rebind",url:s})}onUserInfo(s){this.banner&&(this.banner.userInfo=s)}onCallTimeout(){this.banner&&(this.banner.notify={mode:"timeout"})}onCallStart(){this.banner&&(this.banner.isLoading=!0)}onCallEnd(){var s=this;return(0,_home_runner_work_angor_hub_angor_hub_node_modules_angular_builders_custom_webpack_node_modules_babel_runtime_helpers_esm_asyncToGenerator_js__WEBPACK_IMPORTED_MODULE_1__.A)(function*(){s.banner&&(s.iframeReady&&(yield s.iframeReady.wait(),s.iframeReady=void 0),s.banner.isLoading=!1,s.banner.notify={mode:""})})()}onUpdateAccounts(s){this.banner&&(this.banner.accounts=s)}onDarkMode(s){this.banner&&(this.banner.darkMode=s)}launchAuthBanner(s){var r=this;this.banner=document.createElement("nl-banner"),this.banner.setAttribute("dark-mode",String(getDarkMode(s))),s.theme&&this.banner.setAttribute("theme",s.theme),s.noBanner&&this.banner.setAttribute("hidden-mode","true"),this.banner.addEventListener("handleLoginBanner",i=>{this.emit("launch",i.detail)}),this.banner.addEventListener("handleConfirmLogout",()=>{this.emit("onConfirmLogout")}),this.banner.addEventListener("handleLogoutBanner",(0,_home_runner_work_angor_hub_angor_hub_node_modules_angular_builders_custom_webpack_node_modules_babel_runtime_helpers_esm_asyncToGenerator_js__WEBPACK_IMPORTED_MODULE_1__.A)(function*(){r.emit("logout")})),this.banner.addEventListener("handleImportModal",i=>{this.emit("import")}),this.banner.addEventListener("handleNotifyConfirmBanner",i=>{this.emit("onAuthUrlClick",i.detail)}),this.banner.addEventListener("handleNotifyConfirmBannerIframe",i=>{this.emit("onIframeAuthUrlClick",i.detail)}),this.banner.addEventListener("handleSwitchAccount",i=>{this.emit("onSwitchAccount",i.detail)}),this.banner.addEventListener("handleOpenWelcomeModal",()=>{this.emit("launch",this.params.optionsModal.startScreen),this.banner&&(this.banner.isOpen=!1)}),document.body.appendChild(this.banner)}}function extract(o,s,r){return hash$1(o),void 0===r&&(r=new Uint8Array(o.outputLen)),hmac$1(o,toBytes$1(r),toBytes$1(s))}const HKDF_COUNTER=new Uint8Array([0]),EMPTY_BUFFER=new Uint8Array;function expand(o,s,r,i=32){if(hash$1(o),number$1(i),i>255*o.outputLen)throw new Error("Length should be <= 255*HashLen");const a=Math.ceil(i/o.outputLen);void 0===r&&(r=EMPTY_BUFFER);const c=new Uint8Array(a*o.outputLen),y=hmac$1.create(o,s),w=y._cloneInto(),C=new Uint8Array(y.outputLen);for(let T=0;Tdecoder.decode(o),getConversationKey(o,s){const r=secp256k1.getSharedSecret(o,"02"+s).subarray(1,33);return extract(sha256,r,"nip44-v2")},getMessageKeys(o,s){const r=expand(sha256,o,s,76);return{chacha_key:r.subarray(0,32),chacha_nonce:r.subarray(32,44),hmac_key:r.subarray(44,76)}},calcPaddedLen(o){if(!Number.isSafeInteger(o)||o<1)throw new Error("expected positive integer");if(o<=32)return 32;const s=1<u.maxPlaintextSize)throw new Error("invalid plaintext size: must be between 1 and 65535 bytes");const s=new Uint8Array(2);return new DataView(s.buffer).setUint16(0,o,!1),s},pad(o){const s=u.utf8Encode(o),r=s.length;return concatBytes(u.writeU16BE(r),s,new Uint8Array(u.calcPaddedLen(r)-r))},unpad(o){const s=new DataView(o.buffer).getUint16(0),r=o.subarray(2,2+s);if(su.maxPlaintextSize||r.length!==s||o.length!==2+u.calcPaddedLen(s))throw new Error("invalid padding");return u.utf8Decode(r)},hmacAad(o,s,r){if(32!==r.length)throw new Error("AAD associated data must be 32 bytes");const i=concatBytes(r,s);return hmac$1(sha256,o,i)},decodePayload(o){if("string"!=typeof o)throw new Error("payload must be a valid string");const s=o.length;if(s<132||s>87472)throw new Error("invalid payload length: "+s);if("#"===o[0])throw new Error("unknown encryption version");let r;try{r=base64.decode(o)}catch(c){throw new Error("invalid base64: "+c.message)}const i=r.length;if(i<99||i>65603)throw new Error("invalid data length: "+i);const a=r[0];if(2!==a)throw new Error("unknown encryption version "+a);return{nonce:r.subarray(1,33),ciphertext:r.subarray(33,-32),mac:r.subarray(-32)}}};function encryptNip44(o,s,r=randomBytes(32)){const{chacha_key:i,chacha_nonce:a,hmac_key:c}=u.getMessageKeys(s,r),y=u.pad(o),w=chacha20(i,a,y),C=u.hmacAad(c,w,r);return base64.encode(concatBytes(new Uint8Array([2]),r,w,C))}function decryptNip44(o,s){const{nonce:r,ciphertext:i,mac:a}=u.decodePayload(o),{chacha_key:c,chacha_nonce:y,hmac_key:w}=u.getMessageKeys(s,r);if(!equalBytes(u.hmacAad(w,i,r),a))throw new Error("invalid MAC");const C=chacha20(c,y,i);return u.unpad(C)}class Nip44{cache=new Map;createKey(s,r){return u.getConversationKey(s,r)}getKey(s,r,i){const a=getPublicKey(s)+r;let c=this.cache.get(a);if(c)return c;const y=this.createKey(s,r);return this.cache.set(a,y),y}encrypt(s,r,i){return encryptNip44(i,this.getKey(s,r))}decrypt(s,r,i){return decryptNip44(i,this.getKey(s,r))}}class PrivateKeySigner extends NDKPrivateKeySigner{nip44=new Nip44;constructor(s){super(s)}encryptNip44(s,r){return Promise.resolve(this.nip44.encrypt(this.privateKey,s.pubkey,r))}decryptNip44(s,r){return Promise.resolve(this.nip44.decrypt(this.privateKey,s.pubkey,r))}}const OUTBOX_RELAYS=["wss://user.kindpag.es","wss://purplepag.es","wss://relay.nos.social"],DEFAULT_NOSTRCONNECT_RELAY="wss://relay.nsec.app/",NOSTRCONNECT_APPS=[{name:"Nsec.app",domain:"nsec.app",canImport:!0,img:"https://nsec.app/assets/favicon.ico",link:"https://use.nsec.app/",relay:"wss://relay.nsec.app/"},{name:"Amber",img:"https://raw.githubusercontent.com/greenart7c3/Amber/master/app/src/main/res/mipmap-hdpi/ic_launcher.webp",link:"",relay:"wss://relay.nsec.app/"},{name:"Other key stores",img:"",link:"",relay:"wss://relay.nsec.app/"}];class AuthNostrService extends lib$1.EventEmitter{ndk;profileNdk;signer=null;localSigner=null;params;signerPromise;readyPromise;readyCallback;nip44Codec=new Nip44;nostrConnectKey="";nostrConnectSecret="";iframe;starterReady;nip04;nip44;constructor(s){super(),this.params=s,this.ndk=new NDK({enableOutboxModel:!1}),this.profileNdk=new NDK({enableOutboxModel:!0,explicitRelayUrls:OUTBOX_RELAYS}),this.profileNdk.connect(),this.nip04={encrypt:this.encrypt04.bind(this),decrypt:this.decrypt04.bind(this)},this.nip44={encrypt:this.encrypt44.bind(this),decrypt:this.decrypt44.bind(this)}}isIframe(){return!!this.iframe}waitReady(){var s=this;return(0,_home_runner_work_angor_hub_angor_hub_node_modules_angular_builders_custom_webpack_node_modules_babel_runtime_helpers_esm_asyncToGenerator_js__WEBPACK_IMPORTED_MODULE_1__.A)(function*(){if(s.signerPromise)try{yield s.signerPromise}catch{}if(s.readyPromise)try{yield s.readyPromise}catch{}})()}nostrConnect(s,{domain:r="",link:i="",iframeUrl:a="",importConnect:c=!1}={}){var y=this;return(0,_home_runner_work_angor_hub_angor_hub_node_modules_angular_builders_custom_webpack_node_modules_babel_runtime_helpers_esm_asyncToGenerator_js__WEBPACK_IMPORTED_MODULE_1__.A)(function*(){const w={authMethod:"connect",pubkey:"",sk:y.nostrConnectKey,domain:r,relays:[s=s||DEFAULT_NOSTRCONNECT_RELAY],iframeUrl:a};console.log("nostrconnect info",w,i),i&&!a&&window.open(i,"_blank","width=400,height=700");const C=yield y.initSigner(w,{listen:!0});if(!C)throw new Error("Bad remote pubkey");return w.pubkey=C,w.bunkerUrl=`bunker://${C}?relay=${s}`,c||y.onAuth("login",w),w})()}createNostrConnect(s){var r=this;return(0,_home_runner_work_angor_hub_angor_hub_node_modules_angular_builders_custom_webpack_node_modules_babel_runtime_helpers_esm_asyncToGenerator_js__WEBPACK_IMPORTED_MODULE_1__.A)(function*(){r.nostrConnectKey=generatePrivateKey(),r.nostrConnectSecret=Math.random().toString(36).substring(7);const i=getPublicKey(r.nostrConnectKey),a={name:document.location.host,url:document.location.href,icon:yield getIcon(),perms:r.params.optionsModal.perms};return`nostrconnect://${i}?metadata=${encodeURIComponent(JSON.stringify(a))}&secret=${r.nostrConnectSecret}${s?`&relay=${s}`:""}`})()}getNostrConnectServices(){var s=this;return(0,_home_runner_work_angor_hub_angor_hub_node_modules_angular_builders_custom_webpack_node_modules_babel_runtime_helpers_esm_asyncToGenerator_js__WEBPACK_IMPORTED_MODULE_1__.A)(function*(){const r=yield s.createNostrConnect(),i=NOSTRCONNECT_APPS.map(a=>({...a}));for(const a of i){let c=DEFAULT_NOSTRCONNECT_RELAY;if(a.link.startsWith("https://")){let w=a.domain||new URL(a.link).hostname;try{const C=yield(yield fetch(`https://${w}/.well-known/nostr.json`)).json(),S=C.nip46[C.names._];S&&S.length&&(c=S[0]),a.iframeUrl=C.nip46.iframe_url||""}catch(C){console.log("Bad app info",C,a)}}const y=r+"&relay="+c;a.link=a.iframeUrl?y:a.link.replace("",y)}return[r,i]})()}localSignup(s){var r=this;return(0,_home_runner_work_angor_hub_angor_hub_node_modules_angular_builders_custom_webpack_node_modules_babel_runtime_helpers_esm_asyncToGenerator_js__WEBPACK_IMPORTED_MODULE_1__.A)(function*(){const i=generatePrivateKey(),a={pubkey:getPublicKey(i),sk:i,name:s,authMethod:"local"};console.log(`localSignup name: ${s}`),yield r.setLocal(a,!0)})()}setLocal(s,r){var i=this;return(0,_home_runner_work_angor_hub_angor_hub_node_modules_angular_builders_custom_webpack_node_modules_babel_runtime_helpers_esm_asyncToGenerator_js__WEBPACK_IMPORTED_MODULE_1__.A)(function*(){i.releaseSigner(),i.localSigner=new PrivateKeySigner(s.sk),r&&(yield createProfile(s,i.profileNdk,i.localSigner,i.params.optionsModal.signupRelays)),i.onAuth("login",s)})()}prepareImportUrl(s){if("otp"===this.params.userInfo?.authMethod)return s+"&import=true";if(!this.localSigner||"local"!==this.params.userInfo?.authMethod)throw new Error("Most be local keys");return s+"#import="+nip19_exports.nsecEncode(this.localSigner.privateKey)}importAndConnect(s){var r=this;return(0,_home_runner_work_angor_hub_angor_hub_node_modules_angular_builders_custom_webpack_node_modules_babel_runtime_helpers_esm_asyncToGenerator_js__WEBPACK_IMPORTED_MODULE_1__.A)(function*(){const{relay:i,domain:a,link:c,iframeUrl:y}=s;if(!a)throw new Error("Domain required");const w=yield r.nostrConnect(i,{domain:a,link:c,importConnect:!0,iframeUrl:y});yield r.logout(!0),r.localSigner=null,r.onAuth("login",w)})()}setReadOnly(s){this.onAuth("login",{pubkey:s,authMethod:"readOnly"})}setExtension(s){this.onAuth("login",{pubkey:s,authMethod:"extension"})}setOTP(s,r){this.onAuth("login",{pubkey:s,authMethod:"otp",otpData:r})}setConnect(s){var r=this;return(0,_home_runner_work_angor_hub_angor_hub_node_modules_angular_builders_custom_webpack_node_modules_babel_runtime_helpers_esm_asyncToGenerator_js__WEBPACK_IMPORTED_MODULE_1__.A)(function*(){r.releaseSigner(),yield r.startAuth(),yield r.initSigner(s),r.onAuth("login",s),yield r.endAuth()})()}createAccount(s){var r=this;return(0,_home_runner_work_angor_hub_angor_hub_node_modules_angular_builders_custom_webpack_node_modules_babel_runtime_helpers_esm_asyncToGenerator_js__WEBPACK_IMPORTED_MODULE_1__.A)(function*(){const[i,a]=s.split("@"),c=yield getBunkerUrl(`_@${a}`,r.params.optionsModal);console.log("create account bunker's url",c);const y=bunkerUrlToInfo(c),w=!!r.params.userInfo;yield r.initSigner(y,{eventToAddAccount:w});const C=[i,a,"",r.params.optionsModal.perms||""];console.log("signer",r.signer);const T=yield new Promise(S=>{r.signer.rpc.sendRequest(y.pubkey,"create_account",C,void 0,S)});if(console.log("create_account pubkey",T),"error"===T.result)throw new Error(T.error);return{bunkerUrl:`bunker://${T.result}?relay=${y.relays?.[0]}`,sk:y.sk}})()}releaseSigner(){this.signer=null,this.localSigner=null;for(const s of this.ndk.pool.relays.keys())this.ndk.pool.removeRelay(s)}logout(s=!1){var r=this;return(0,_home_runner_work_angor_hub_angor_hub_node_modules_angular_builders_custom_webpack_node_modules_babel_runtime_helpers_esm_asyncToGenerator_js__WEBPACK_IMPORTED_MODULE_1__.A)(function*(){s||r.releaseSigner(),localStorageRemoveCurrentAccount(),r.onAuth("logout"),r.emit("updateAccounts")})()}setUserInfo(s){this.params.userInfo=s,this.emit("onUserInfo",s),s&&(localStorageAddAccount(s),this.emit("updateAccounts"))}exportKeys(){return this.params.userInfo?"local"!==this.params.userInfo.authMethod?"":nip19_exports.nsecEncode(this.params.userInfo.sk):""}onAuth(s,r=null){if("logout"!==s&&!r)throw new Error("No user info in onAuth");if(r&&this.params.userInfo&&(r.pubkey!==this.params.userInfo.pubkey||r.authMethod!==this.params.userInfo.authMethod)){const i=new CustomEvent("nlAuth",{detail:{type:"logout"}});console.log("nostr-login auth",i.detail),document.dispatchEvent(i)}this.setUserInfo(r),r&&fetchProfile(r,this.profileNdk).then(i=>{if(this.params.userInfo!==r)return;const a={...this.params.userInfo,picture:i?.image||i?.picture,name:i?.name||i?.displayName||i?.nip05||nip19_exports.npubEncode(r.pubkey)};this.setUserInfo(a)});try{const i=r?nip19_exports.npubEncode(r.pubkey):"",a={type:s};"logout"===s?(this.iframe&&this.iframe.remove(),this.iframe=void 0):(a.pubkey=r.pubkey,r.sk&&(a.localNsec=nip19_exports.nsecEncode(r.sk)),r.relays&&(a.relays=r.relays),r.otpData&&(a.otpData=r.otpData),a.method=r.authMethod||"connect");const c=new CustomEvent("nlAuth",{detail:a});console.log("nostr-login auth",a),document.dispatchEvent(c),this.params.optionsModal.onAuth&&this.params.optionsModal.onAuth(i,a)}catch(i){console.log("onAuth error",i)}}createIframe(s){return(0,_home_runner_work_angor_hub_angor_hub_node_modules_angular_builders_custom_webpack_node_modules_babel_runtime_helpers_esm_asyncToGenerator_js__WEBPACK_IMPORTED_MODULE_1__.A)(function*(){if(!s)return;const r=new URL(s);let i;const a="__nostr-login-worker-iframe-"+r.hostname.replaceAll(".","-");i=document.querySelector(`#${a}`),console.log("iframe",a,i),i||(i=document.createElement("iframe"),i.setAttribute("width","0"),i.setAttribute("height","0"),i.setAttribute("border","0"),i.style.display="none",i.id=a,document.body.append(i)),i.setAttribute("src",s);const c=new ReadyListener(["workerReady","workerError"],r.origin);yield new Promise(w=>{i.addEventListener("load",w)});const y=yield c.wait();return console.log("nostr-login iframe ready",s,y),{iframe:i,port:y[1]}})()}startAuth(){var s=this;return(0,_home_runner_work_angor_hub_angor_hub_node_modules_angular_builders_custom_webpack_node_modules_babel_runtime_helpers_esm_asyncToGenerator_js__WEBPACK_IMPORTED_MODULE_1__.A)(function*(){if(s.readyCallback)throw new Error("Already started");s.readyPromise=new Promise(r=>s.readyCallback=r)})()}endAuth(){var s=this;return(0,_home_runner_work_angor_hub_angor_hub_node_modules_angular_builders_custom_webpack_node_modules_babel_runtime_helpers_esm_asyncToGenerator_js__WEBPACK_IMPORTED_MODULE_1__.A)(function*(){if(console.log("endAuth",s.params.userInfo),s.params.userInfo&&s.params.userInfo.iframeUrl){const{iframe:r,port:i}=(yield s.createIframe(s.params.userInfo.iframeUrl))||{};if(s.iframe=r,!s.iframe||!i)return;s.signer.rpc.setWorkerIframePort(i)}s.readyCallback(),s.readyCallback=void 0})()}resetAuth(){this.readyCallback&&this.readyCallback(),this.readyCallback=void 0}listen(s,r){var i=this;return(0,_home_runner_work_angor_hub_angor_hub_node_modules_angular_builders_custom_webpack_node_modules_babel_runtime_helpers_esm_asyncToGenerator_js__WEBPACK_IMPORTED_MODULE_1__.A)(function*(){if(console.log("listen",s,r),!s.iframeUrl)return r.listen(i.nostrConnectSecret);const a=yield i.starterReady.wait();if("starterError"===a[0])throw new Error(a[1]);return i.signer.rpc.parseNostrConnectReply(a[1],i.nostrConnectSecret)})()}initSigner(s,{listen:r=!1,connect:i=!1,eventToAddAccount:a=!1}={}){var c=this;return(0,_home_runner_work_angor_hub_angor_hub_node_modules_angular_builders_custom_webpack_node_modules_babel_runtime_helpers_esm_asyncToGenerator_js__WEBPACK_IMPORTED_MODULE_1__.A)(function*(){if(c.signerPromise)try{yield c.signerPromise}catch{}console.log("initSigner info",s);const y=s.iframeUrl?new URL(s.iframeUrl).origin:void 0;return y&&(c.starterReady=new ReadyListener(["starterDone","starterError"],y)),c.emit("onIframeUrl",s.iframeUrl),c.signerPromise=new Promise(function(){var w=(0,_home_runner_work_angor_hub_angor_hub_node_modules_angular_builders_custom_webpack_node_modules_babel_runtime_helpers_esm_asyncToGenerator_js__WEBPACK_IMPORTED_MODULE_1__.A)(function*(C,T){try{if(s.relays&&!s.iframeUrl)for(const L of s.relays)c.ndk.addExplicitRelay(L,void 0);yield c.ndk.connect();const S=getPublicKey(s.sk),M=new PrivateKeySigner(s.sk);c.signer=new NDKNip46Signer(c.ndk,s.pubkey,M);const O=new IframeNostrRpc(c.ndk,S,M,y);if(O.setUseNip44(!0),c.signer.rpc=O,O.on(`iframeRestart-${s.pubkey}`,(0,_home_runner_work_angor_hub_angor_hub_node_modules_angular_builders_custom_webpack_node_modules_babel_runtime_helpers_esm_asyncToGenerator_js__WEBPACK_IMPORTED_MODULE_1__.A)(function*(){const L=s.iframeUrl+(s.iframeUrl.includes("?")?"&":"?")+"pubkey="+s.pubkey+"&rebind="+S;c.emit("iframeRestart",{pubkey:s.pubkey,iframeUrl:L})})),r||O.on("authUrl",L=>{console.log("nostr login auth url",L),c.emit("onAuthUrl",{url:L,iframeUrl:s.iframeUrl,eventToAddAccount:a})}),r){const L=yield c.listen(s,O);c.signer.remotePubkey=L,c.signer.remoteUser=new NDKUser({pubkey:L}),s.pubkey=L,C(L)}else i&&(yield O.connect(s,c.params.optionsModal.perms)),C(void 0)}catch(S){console.log("initSigner failure",S),c.signer=null,T(S)}});return function(C,T){return w.apply(this,arguments)}}()),c.signerPromise})()}authNip46(s,{name:r,bunkerUrl:i,sk:a="",domain:c="",iframeUrl:y=""}){var w=this;return(0,_home_runner_work_angor_hub_angor_hub_node_modules_angular_builders_custom_webpack_node_modules_babel_runtime_helpers_esm_asyncToGenerator_js__WEBPACK_IMPORTED_MODULE_1__.A)(function*(){try{const C=bunkerUrlToInfo(i,a);if(isBunkerUrl(r)?C.bunkerUrl=r:(C.nip05=r,C.domain=r.split("@")[1]),c&&(C.domain=c),y&&(C.iframeUrl=y),!C.pubkey||!C.sk||!C.relays?.[0])throw new Error(`Bad bunker url ${i}`);const T=!!w.params.userInfo;console.log("authNip46",s,C),yield w.initSigner(C,{connect:!0,eventToAddAccount:T}),w.onAuth(s,C)}catch(C){throw console.log("nostr login auth failed",C),C}})()}signEvent(s){var r=this;return(0,_home_runner_work_angor_hub_angor_hub_node_modules_angular_builders_custom_webpack_node_modules_babel_runtime_helpers_esm_asyncToGenerator_js__WEBPACK_IMPORTED_MODULE_1__.A)(function*(){return r.localSigner?(s.pubkey=getPublicKey(r.localSigner.privateKey),s.id=getEventHash(s),s.sig=yield r.localSigner.sign(s)):(s.pubkey=r.signer?.remotePubkey,s.id=getEventHash(s),s.sig=yield r.signer?.sign(s)),console.log("signed",{event:s}),s})()}codec_call(s,r,i){var a=this;return(0,_home_runner_work_angor_hub_angor_hub_node_modules_angular_builders_custom_webpack_node_modules_babel_runtime_helpers_esm_asyncToGenerator_js__WEBPACK_IMPORTED_MODULE_1__.A)(function*(){return new Promise((c,y)=>{a.signer.rpc.sendRequest(a.signer.remotePubkey,s,[r,i],24133,w=>{w.error?y(w.error):c(w.result)})})})()}encrypt04(s,r){var i=this;return(0,_home_runner_work_angor_hub_angor_hub_node_modules_angular_builders_custom_webpack_node_modules_babel_runtime_helpers_esm_asyncToGenerator_js__WEBPACK_IMPORTED_MODULE_1__.A)(function*(){return i.localSigner?i.localSigner.encrypt(new NDKUser({pubkey:s}),r):i.signer.encrypt(new NDKUser({pubkey:s}),r)})()}decrypt04(s,r){var i=this;return(0,_home_runner_work_angor_hub_angor_hub_node_modules_angular_builders_custom_webpack_node_modules_babel_runtime_helpers_esm_asyncToGenerator_js__WEBPACK_IMPORTED_MODULE_1__.A)(function*(){return i.localSigner?i.localSigner.decrypt(new NDKUser({pubkey:s}),r):i.codec_call("nip04_decrypt",s,r)})()}encrypt44(s,r){var i=this;return(0,_home_runner_work_angor_hub_angor_hub_node_modules_angular_builders_custom_webpack_node_modules_babel_runtime_helpers_esm_asyncToGenerator_js__WEBPACK_IMPORTED_MODULE_1__.A)(function*(){return i.localSigner?i.nip44Codec.encrypt(i.localSigner.privateKey,s,r):i.codec_call("nip44_encrypt",s,r)})()}decrypt44(s,r){var i=this;return(0,_home_runner_work_angor_hub_angor_hub_node_modules_angular_builders_custom_webpack_node_modules_babel_runtime_helpers_esm_asyncToGenerator_js__WEBPACK_IMPORTED_MODULE_1__.A)(function*(){return i.localSigner?i.nip44Codec.decrypt(i.localSigner.privateKey,s,r):i.codec_call("nip44_decrypt",s,r)})()}}class ModalManager extends lib$1.EventEmitter{modal=null;params;extensionService;authNostrService;launcherPromise;accounts=[];recents=[];opt;constructor(s,r,i){super(),this.params=s,this.extensionService=i,this.authNostrService=r}waitReady(){var s=this;return(0,_home_runner_work_angor_hub_angor_hub_node_modules_angular_builders_custom_webpack_node_modules_babel_runtime_helpers_esm_asyncToGenerator_js__WEBPACK_IMPORTED_MODULE_1__.A)(function*(){if(s.launcherPromise){try{yield s.launcherPromise}catch{}s.launcherPromise=void 0}})()}launch(s){var r=this;return(0,_home_runner_work_angor_hub_angor_hub_node_modules_angular_builders_custom_webpack_node_modules_babel_runtime_helpers_esm_asyncToGenerator_js__WEBPACK_IMPORTED_MODULE_1__.A)(function*(){r.launcherPromise&&(yield r.waitReady()),r.opt=s;const i=document.createElement("dialog");r.modal=document.createElement("nl-auth"),r.modal.accounts=r.accounts,r.modal.recents=r.recents,r.modal.setAttribute("dark-mode",String(getDarkMode(s))),s.theme&&r.modal.setAttribute("theme",s.theme),s.startScreen&&r.modal.setAttribute("start-screen",s.startScreen),r.modal.setAttribute("bunkers",s.bunkers?s.bunkers:"nsec.app,highlighter.com"),void 0!==s.methods&&(r.modal.authMethods=s.methods),void 0!==s.localSignup&&(r.modal.localSignup=s.localSignup),s.title&&(r.modal.welcomeTitle=s.title),s.description&&(r.modal.welcomeDescription=s.description),r.modal.hasExtension=r.extensionService.hasExtension(),r.modal.hasOTP=!!s.otpRequestUrl&&!!s.otpReplyUrl,r.modal.isLoadingExtension=!1,r.modal.isLoading=!1,[r.modal.connectionString,r.modal.connectionStringServices]=yield r.authNostrService.getNostrConnectServices(),i.appendChild(r.modal),document.body.appendChild(i);let a="";return r.launcherPromise=new Promise((c,y)=>{i.addEventListener("close",()=>{y(new Error("Closed")),r.authNostrService.resetAuth(),r.modal&&(document.body.removeChild(r.modal.parentNode),r.modal=null)});const w=function(){var pe=(0,_home_runner_work_angor_hub_angor_hub_node_modules_angular_builders_custom_webpack_node_modules_babel_runtime_helpers_esm_asyncToGenerator_js__WEBPACK_IMPORTED_MODULE_1__.A)(function*(se){r.modal&&(r.modal.isLoading=!1),yield r.authNostrService.endAuth(),i.close(),r.modal=null,se()});return function(ae){return pe.apply(this,arguments)}}(),C=function(){var pe=(0,_home_runner_work_angor_hub_angor_hub_node_modules_angular_builders_custom_webpack_node_modules_babel_runtime_helpers_esm_asyncToGenerator_js__WEBPACK_IMPORTED_MODULE_1__.A)(function*(se,ae){r.modal&&(r.modal.isLoading=!0);try{ae&&!ae.start||(yield r.authNostrService.startAuth()),yield se(),ae&&!ae.end||(yield w(c))}catch(me){console.log("error",me),r.modal&&(r.modal.isLoading=!1,r.modal.authUrl="",r.modal.iframeUrl="",r.modal.error=me.toString())}});return function(ae,me){return pe.apply(this,arguments)}}(),T=function(){var pe=(0,_home_runner_work_angor_hub_angor_hub_node_modules_angular_builders_custom_webpack_node_modules_babel_runtime_helpers_esm_asyncToGenerator_js__WEBPACK_IMPORTED_MODULE_1__.A)(function*(se,ae){yield C((0,_home_runner_work_angor_hub_angor_hub_node_modules_angular_builders_custom_webpack_node_modules_babel_runtime_helpers_esm_asyncToGenerator_js__WEBPACK_IMPORTED_MODULE_1__.A)(function*(){const me=yield getBunkerUrl(se,r.params.optionsModal);yield r.authNostrService.authNip46("login",{name:se,bunkerUrl:me,domain:ae})}))});return function(ae,me){return pe.apply(this,arguments)}}(),S=function(){var pe=(0,_home_runner_work_angor_hub_angor_hub_node_modules_angular_builders_custom_webpack_node_modules_babel_runtime_helpers_esm_asyncToGenerator_js__WEBPACK_IMPORTED_MODULE_1__.A)(function*(se){yield C((0,_home_runner_work_angor_hub_angor_hub_node_modules_angular_builders_custom_webpack_node_modules_babel_runtime_helpers_esm_asyncToGenerator_js__WEBPACK_IMPORTED_MODULE_1__.A)(function*(){const{bunkerUrl:ae,sk:me}=yield r.authNostrService.createAccount(se);yield r.authNostrService.authNip46("signup",{name:se,bunkerUrl:ae,sk:me})}))});return function(ae){return pe.apply(this,arguments)}}(),M=function(){var pe=(0,_home_runner_work_angor_hub_angor_hub_node_modules_angular_builders_custom_webpack_node_modules_babel_runtime_helpers_esm_asyncToGenerator_js__WEBPACK_IMPORTED_MODULE_1__.A)(function*(){try{yield navigator.clipboard.writeText(r.authNostrService.exportKeys()),localStorageSetItem("backupKey","true")}catch(se){console.error("Failed to copy to clipboard: ",se)}});return function(){return pe.apply(this,arguments)}}(),O=function(){var pe=(0,_home_runner_work_angor_hub_angor_hub_node_modules_angular_builders_custom_webpack_node_modules_babel_runtime_helpers_esm_asyncToGenerator_js__WEBPACK_IMPORTED_MODULE_1__.A)(function*(se){yield C((0,_home_runner_work_angor_hub_angor_hub_node_modules_angular_builders_custom_webpack_node_modules_babel_runtime_helpers_esm_asyncToGenerator_js__WEBPACK_IMPORTED_MODULE_1__.A)(function*(){const{iframeUrl:ae}=se,me=r.authNostrService.prepareImportUrl(se.link);r.modal&&ae&&(r.modal.authUrl=me,r.modal.iframeUrl=ae,r.modal.isLoading=!1,console.log("nostrconnect authUrl",r.modal.authUrl,r.modal.iframeUrl)),yield r.authNostrService.importAndConnect(se)}))});return function(ae){return pe.apply(this,arguments)}}(),L=function(){var pe=(0,_home_runner_work_angor_hub_angor_hub_node_modules_angular_builders_custom_webpack_node_modules_babel_runtime_helpers_esm_asyncToGenerator_js__WEBPACK_IMPORTED_MODULE_1__.A)(function*(se){yield C((0,_home_runner_work_angor_hub_angor_hub_node_modules_angular_builders_custom_webpack_node_modules_babel_runtime_helpers_esm_asyncToGenerator_js__WEBPACK_IMPORTED_MODULE_1__.A)(function*(){const{relay:ae,domain:me,link:be,iframeUrl:Oe}=se||{};console.log("nostrConnect",se,ae,me,be,Oe),r.modal&&(Oe&&(r.modal.authUrl=be,r.modal.iframeUrl=Oe,r.modal.isLoading=!1,console.log("nostrconnect authUrl",r.modal.authUrl,r.modal.iframeUrl)),se||(r.modal.isLoading=!1)),yield r.authNostrService.nostrConnect(ae,{domain:me,link:be,iframeUrl:Oe})}))});return function(ae){return pe.apply(this,arguments)}}(),Z=function(){var pe=(0,_home_runner_work_angor_hub_angor_hub_node_modules_angular_builders_custom_webpack_node_modules_babel_runtime_helpers_esm_asyncToGenerator_js__WEBPACK_IMPORTED_MODULE_1__.A)(function*(se){yield C((0,_home_runner_work_angor_hub_angor_hub_node_modules_angular_builders_custom_webpack_node_modules_babel_runtime_helpers_esm_asyncToGenerator_js__WEBPACK_IMPORTED_MODULE_1__.A)(function*(){if(!se)throw new Error("Please enter some nickname");yield r.authNostrService.localSignup(se)}))});return function(ae){return pe.apply(this,arguments)}}();if(!r.modal)throw new Error("WTH?");r.modal.addEventListener("handleContinue",()=>{r.modal&&(r.modal.isLoading=!0,r.emit("onAuthUrlClick",r.modal.authUrl))}),r.modal.addEventListener("nlLogin",pe=>{T(pe.detail)}),r.modal.addEventListener("nlSignup",pe=>{S(pe.detail)}),r.modal.addEventListener("nlLocalSignup",pe=>{Z(pe.detail)}),r.modal.addEventListener("nlImportAccount",pe=>{O(pe.detail)}),r.modal.addEventListener("nlExportKeys",pe=>{M()}),r.modal.addEventListener("handleLogoutBanner",()=>{r.emit("onLogoutBanner")}),r.modal.addEventListener("nlNostrConnect",pe=>{L(pe.detail)}),r.modal.addEventListener("nlNostrConnectDefault",()=>{L()}),r.modal.addEventListener("nlSwitchAccount",pe=>{r.emit("onSwitchAccount",pe.detail),setTimeout(()=>i.close(),300)}),r.modal.addEventListener("nlLoginRecentAccount",function(){var pe=(0,_home_runner_work_angor_hub_angor_hub_node_modules_angular_builders_custom_webpack_node_modules_babel_runtime_helpers_esm_asyncToGenerator_js__WEBPACK_IMPORTED_MODULE_1__.A)(function*(se){const ae=se.detail;if("readOnly"===ae.authMethod)r.authNostrService.setReadOnly(ae.pubkey),i.close();else if("otp"===ae.authMethod)try{r.modal.dispatchEvent(new CustomEvent("nlLoginOTPUser",{detail:ae.nip05||ae.pubkey}))}catch(me){console.error(me)}else if("extension"===ae.authMethod)yield r.extensionService.trySetExtensionForPubkey(ae.pubkey),i.close();else{const me=ae.bunkerUrl||ae.nip05;if(!me)throw new Error("Bad connect info");T(me,ae.domain)}});return function(se){return pe.apply(this,arguments)}}()),r.modal.addEventListener("nlRemoveRecent",pe=>{localStorageRemoveRecent(pe.detail),r.emit("updateAccounts")});const q=function(){var pe=(0,_home_runner_work_angor_hub_angor_hub_node_modules_angular_builders_custom_webpack_node_modules_babel_runtime_helpers_esm_asyncToGenerator_js__WEBPACK_IMPORTED_MODULE_1__.A)(function*(se){let ae="";if(se.includes("@")){const{error:me,pubkey:be}=yield checkNip05(se);if(!be)throw new Error(me);ae=be}else if(se.startsWith("npub")){const{type:me,data:be}=nip19_exports.decode(se);if("npub"!==me)throw new Error("Bad npub");ae=be}else 64===se.trim().length&&(ae=se.trim(),nip19_exports.npubEncode(ae));return ae});return function(ae){return pe.apply(this,arguments)}}();r.modal.addEventListener("nlLoginReadOnly",function(){var pe=(0,_home_runner_work_angor_hub_angor_hub_node_modules_angular_builders_custom_webpack_node_modules_babel_runtime_helpers_esm_asyncToGenerator_js__WEBPACK_IMPORTED_MODULE_1__.A)(function*(se){yield C((0,_home_runner_work_angor_hub_angor_hub_node_modules_angular_builders_custom_webpack_node_modules_babel_runtime_helpers_esm_asyncToGenerator_js__WEBPACK_IMPORTED_MODULE_1__.A)(function*(){const ae=se.detail,me=yield q(ae);r.authNostrService.setReadOnly(me)}))});return function(se){return pe.apply(this,arguments)}}()),r.modal.addEventListener("nlLoginExtension",(0,_home_runner_work_angor_hub_angor_hub_node_modules_angular_builders_custom_webpack_node_modules_babel_runtime_helpers_esm_asyncToGenerator_js__WEBPACK_IMPORTED_MODULE_1__.A)(function*(){if(!r.extensionService.hasExtension())throw new Error("No extension");yield C((0,_home_runner_work_angor_hub_angor_hub_node_modules_angular_builders_custom_webpack_node_modules_babel_runtime_helpers_esm_asyncToGenerator_js__WEBPACK_IMPORTED_MODULE_1__.A)(function*(){r.modal&&(r.modal.isLoadingExtension=!0,yield r.extensionService.setExtension(),r.modal.isLoadingExtension=!1)}))})),r.modal.addEventListener("nlLoginOTPUser",function(){var pe=(0,_home_runner_work_angor_hub_angor_hub_node_modules_angular_builders_custom_webpack_node_modules_babel_runtime_helpers_esm_asyncToGenerator_js__WEBPACK_IMPORTED_MODULE_1__.A)(function*(se){yield C((0,_home_runner_work_angor_hub_angor_hub_node_modules_angular_builders_custom_webpack_node_modules_babel_runtime_helpers_esm_asyncToGenerator_js__WEBPACK_IMPORTED_MODULE_1__.A)(function*(){if(!r.modal)return;const ae=se.detail,me=yield q(ae),be=r.opt.otpRequestUrl+(r.opt.otpRequestUrl.includes("?")?"&":"?")+"pubkey="+me,Oe=yield fetch(be);if(200!==Oe.status)throw console.warn("nostr-login: bad otp reply",Oe),new Error("Failed to send DM");r.modal.isOTP=!0,a=me,r.modal.isLoading=!1}),{start:!0})});return function(se){return pe.apply(this,arguments)}}()),r.modal.addEventListener("nlLoginOTPCode",function(){var pe=(0,_home_runner_work_angor_hub_angor_hub_node_modules_angular_builders_custom_webpack_node_modules_babel_runtime_helpers_esm_asyncToGenerator_js__WEBPACK_IMPORTED_MODULE_1__.A)(function*(se){yield C((0,_home_runner_work_angor_hub_angor_hub_node_modules_angular_builders_custom_webpack_node_modules_babel_runtime_helpers_esm_asyncToGenerator_js__WEBPACK_IMPORTED_MODULE_1__.A)(function*(){if(!r.modal)return;const ae=se.detail,me=r.opt.otpReplyUrl+(r.opt.otpRequestUrl.includes("?")?"&":"?")+"pubkey="+a+"&code="+ae,be=yield fetch(me);if(200!==be.status)throw console.warn("nostr-login: bad otp reply",be),new Error("Invalid code");const Oe=yield be.text();r.authNostrService.setOTP(a,Oe),r.modal.isOTP=!1}),{end:!0})});return function(se){return pe.apply(this,arguments)}}()),r.modal.addEventListener("nlCheckSignup",function(){var pe=(0,_home_runner_work_angor_hub_angor_hub_node_modules_angular_builders_custom_webpack_node_modules_babel_runtime_helpers_esm_asyncToGenerator_js__WEBPACK_IMPORTED_MODULE_1__.A)(function*(se){const{available:ae,taken:me,error:be}=yield checkNip05(se.detail);r.modal&&(r.modal.error=String(be),!be&&me&&(r.modal.error="Already taken"),r.modal.signupNameIsAvailable=ae)});return function(se){return pe.apply(this,arguments)}}()),r.modal.addEventListener("nlCheckLogin",function(){var pe=(0,_home_runner_work_angor_hub_angor_hub_node_modules_angular_builders_custom_webpack_node_modules_babel_runtime_helpers_esm_asyncToGenerator_js__WEBPACK_IMPORTED_MODULE_1__.A)(function*(se){const{available:ae,taken:me,error:be}=yield checkNip05(se.detail);r.modal&&(r.modal.error=String(be),ae&&(r.modal.error="Name not found"),r.modal.loginIsGood=me)});return function(se){return pe.apply(this,arguments)}}());const re=()=>{r.modal&&(r.modal.isLoading=!1),i.close(),y(new Error("Cancelled"))};r.modal.addEventListener("stopFetchHandler",re),r.modal.addEventListener("nlCloseModal",re),r.modal.addEventListener("nlChangeDarkMode",pe=>{setDarkMode(pe.detail),document.dispatchEvent(new CustomEvent("nlDarkMode",{detail:pe.detail}))}),r.on("onIframeAuthUrlCallEnd",()=>{i.close(),r.modal=null,c()}),i.showModal()}),r.launcherPromise})()}showIframeUrl(s){var r=this;return(0,_home_runner_work_angor_hub_angor_hub_node_modules_angular_builders_custom_webpack_node_modules_babel_runtime_helpers_esm_asyncToGenerator_js__WEBPACK_IMPORTED_MODULE_1__.A)(function*(){yield r.waitReady(),r.launch({startScreen:"iframe"}).catch(()=>console.log("closed auth iframe")),r.modal.authUrl=s})()}connectModals(s){var r=this;const i=function(){var c=(0,_home_runner_work_angor_hub_angor_hub_node_modules_angular_builders_custom_webpack_node_modules_babel_runtime_helpers_esm_asyncToGenerator_js__WEBPACK_IMPORTED_MODULE_1__.A)(function*(y){yield r.launch(y)});return function(w){return c.apply(this,arguments)}}(),a=document.getElementsByTagName("nl-button");for(let c=0;c{this.checkExtension(s)&&clearTimeout(r)},100)}checkExtension(s){return!(this.nostrExtension||!window.nostr||window.nostr===s||(this.initExtension(s),0))}initExtension(s,r){var i=this;return(0,_home_runner_work_angor_hub_angor_hub_node_modules_angular_builders_custom_webpack_node_modules_babel_runtime_helpers_esm_asyncToGenerator_js__WEBPACK_IMPORTED_MODULE_1__.A)(function*(){i.nostrExtension=window.nostr,window.nostr=s,"extension"===i.params.userInfo?.authMethod&&(yield i.trySetExtensionForPubkey(i.params.userInfo.pubkey)),r||setTimeout(()=>{window.nostr!==s&&i.nostrExtension!==window.nostr&&i.initExtension(s,!0)},300)})()}setExtensionReadPubkey(s){var r=this;return(0,_home_runner_work_angor_hub_angor_hub_node_modules_angular_builders_custom_webpack_node_modules_babel_runtime_helpers_esm_asyncToGenerator_js__WEBPACK_IMPORTED_MODULE_1__.A)(function*(){window.nostr=r.nostrExtension;const i=yield window.nostr.getPublicKey();s&&s!==i?r.emit("extensionLogout"):r.emit("extensionLogin",i)})()}trySetExtensionForPubkey(s){var r=this;return(0,_home_runner_work_angor_hub_angor_hub_node_modules_angular_builders_custom_webpack_node_modules_babel_runtime_helpers_esm_asyncToGenerator_js__WEBPACK_IMPORTED_MODULE_1__.A)(function*(){if(r.nostrExtension)return r.setExtensionReadPubkey(s)})()}setExtension(){var s=this;return(0,_home_runner_work_angor_hub_angor_hub_node_modules_angular_builders_custom_webpack_node_modules_babel_runtime_helpers_esm_asyncToGenerator_js__WEBPACK_IMPORTED_MODULE_1__.A)(function*(){return s.setExtensionReadPubkey()})()}unsetExtension(s){window.nostr===this.nostrExtension&&(window.nostr=s)}getExtension(){return this.nostrExtension}hasExtension(){return!!this.nostrExtension}}class NostrParams{userInfo;optionsModal;constructor(){this.userInfo=null,this.optionsModal={theme:"default",startScreen:"welcome",devOverrideBunkerOrigin:""}}}class Popup{popup=null;constructor(){}openPopup(s){if((!this.popup||this.popup.closed)&&(this.popup=window.open(s,"_blank","width=400,height=700"),console.log("popup",this.popup),!this.popup))throw new Error("Popup blocked. Try again, please!")}closePopup(){try{this.popup?.close(),this.popup=null}catch{}}}const CALL_TIMEOUT=5e3;class ProcessManager extends lib$1.EventEmitter{callCount=0;callTimer;constructor(){super()}onAuthUrl(){this.callTimer&&clearTimeout(this.callTimer)}onIframeUrl(){this.callTimer&&clearTimeout(this.callTimer)}wait(s){var r=this;return(0,_home_runner_work_angor_hub_angor_hub_node_modules_angular_builders_custom_webpack_node_modules_babel_runtime_helpers_esm_asyncToGenerator_js__WEBPACK_IMPORTED_MODULE_1__.A)(function*(){let i,a;r.callTimer||(r.callTimer=setTimeout(()=>r.emit("onCallTimeout"),CALL_TIMEOUT)),r.callCount||r.emit("onCallStart"),r.callCount++;try{a=yield s()}catch(c){i=c}if(r.callCount--,r.emit("onCallEnd"),r.callTimer&&clearTimeout(r.callTimer),r.callTimer=void 0,i)throw i;return a})()}}class NostrLoginInitializer{extensionService;params;authNostrService;nostr;processManager;popupManager;bannerManager;modalManager;constructor(){var s=this;this.params=new NostrParams,this.processManager=new ProcessManager,this.popupManager=new Popup,this.bannerManager=new BannerManager(this.params),this.authNostrService=new AuthNostrService(this.params),this.extensionService=new NostrExtensionService(this.params),this.modalManager=new ModalManager(this.params,this.authNostrService,this.extensionService);const r={waitReady:(i=(0,_home_runner_work_angor_hub_angor_hub_node_modules_angular_builders_custom_webpack_node_modules_babel_runtime_helpers_esm_asyncToGenerator_js__WEBPACK_IMPORTED_MODULE_1__.A)(function*(){yield s.authNostrService.waitReady(),yield s.modalManager.waitReady()}),function(){return i.apply(this,arguments)}),getUserInfo:()=>this.params.userInfo,getSigner:()=>{if("readOnly"===this.params.userInfo.authMethod)throw new Error("Read only");return"extension"===this.params.userInfo.authMethod?this.extensionService.getExtension():this.authNostrService},launch:()=>this.launch(),wait:i=>this.processManager.wait(i)};var i;this.nostr=new Nostr(r),this.processManager.on("onCallTimeout",()=>{this.bannerManager.onCallTimeout()}),this.processManager.on("onCallEnd",()=>{this.bannerManager.onCallEnd(),this.modalManager.onCallEnd()}),this.processManager.on("onCallStart",()=>{this.bannerManager.onCallStart()}),this.authNostrService.on("onIframeUrl",i=>{this.modalManager.onIframeUrl(i)}),this.authNostrService.on("iframeRestart",({iframeUrl:i})=>{this.processManager.onIframeUrl(),this.bannerManager.onIframeRestart(i)}),this.authNostrService.on("onAuthUrl",({url:i,iframeUrl:a,eventToAddAccount:c})=>{this.processManager.onAuthUrl(),c?this.modalManager.onAuthUrl(i):this.params.userInfo?this.bannerManager.onAuthUrl(i,a):this.modalManager.onAuthUrl(i)}),this.authNostrService.on("updateAccounts",()=>{this.updateAccounts()}),this.authNostrService.on("onUserInfo",i=>{this.bannerManager.onUserInfo(i)}),this.modalManager.on("onAuthUrlClick",i=>{this.openPopup(i)}),this.bannerManager.on("onIframeAuthUrlClick",i=>{this.modalManager.showIframeUrl(i)}),this.modalManager.on("onSwitchAccount",function(){var i=(0,_home_runner_work_angor_hub_angor_hub_node_modules_angular_builders_custom_webpack_node_modules_babel_runtime_helpers_esm_asyncToGenerator_js__WEBPACK_IMPORTED_MODULE_1__.A)(function*(a){s.switchAccount(a)});return function(a){return i.apply(this,arguments)}}()),this.modalManager.on("onLogoutBanner",function(){var i=(0,_home_runner_work_angor_hub_angor_hub_node_modules_angular_builders_custom_webpack_node_modules_babel_runtime_helpers_esm_asyncToGenerator_js__WEBPACK_IMPORTED_MODULE_1__.A)(function*(a){logout()});return function(a){return i.apply(this,arguments)}}()),this.bannerManager.on("onConfirmLogout",(0,_home_runner_work_angor_hub_angor_hub_node_modules_angular_builders_custom_webpack_node_modules_babel_runtime_helpers_esm_asyncToGenerator_js__WEBPACK_IMPORTED_MODULE_1__.A)(function*(){console.log(4),s.launch("confirm-logout")})),this.modalManager.on("updateAccounts",()=>{this.updateAccounts()}),this.bannerManager.on("logout",()=>{logout()}),this.bannerManager.on("onAuthUrlClick",i=>{this.openPopup(i)}),this.bannerManager.on("onSwitchAccount",function(){var i=(0,_home_runner_work_angor_hub_angor_hub_node_modules_angular_builders_custom_webpack_node_modules_babel_runtime_helpers_esm_asyncToGenerator_js__WEBPACK_IMPORTED_MODULE_1__.A)(function*(a){s.switchAccount(a)});return function(a){return i.apply(this,arguments)}}()),this.bannerManager.on("import",()=>{this.launch("import")}),this.extensionService.on("extensionLogin",i=>{this.authNostrService.setExtension(i)}),this.extensionService.on("extensionLogout",()=>{logout()}),this.bannerManager.on("launch",i=>{this.launch(i)})}openPopup(s){this.popupManager.openPopup(s)}switchAccount(s){var r=this;return(0,_home_runner_work_angor_hub_angor_hub_node_modules_angular_builders_custom_webpack_node_modules_babel_runtime_helpers_esm_asyncToGenerator_js__WEBPACK_IMPORTED_MODULE_1__.A)(function*(){if(console.log("nostr login switch to info",s),r.extensionService.unsetExtension(r.nostr),"readOnly"===s.authMethod)r.authNostrService.setReadOnly(s.pubkey);else if("otp"===s.authMethod)r.authNostrService.setOTP(s.pubkey,s.otpData||"");else if("local"===s.authMethod&&s.sk)r.authNostrService.setLocal(s);else if("extension"===s.authMethod)yield r.extensionService.trySetExtensionForPubkey(s.pubkey);else{if(!("connect"===s.authMethod&&s.sk&&s.relays&&s.relays[0]))throw new Error("Bad auth info");r.authNostrService.setConnect(s)}})()}updateAccounts(){const s=localStorageGetAccounts(),r=localStorageGetRecents();this.bannerManager.onUpdateAccounts(s),this.modalManager.onUpdateAccounts(s,r)}launch=s=>{const r=localStorageGetRecents(),i=localStorageGetAccounts(),a=s?{startScreen:s}:this.params.optionsModal;return s||!r?.length&&!i?.length||(a.startScreen="switch-account"),this.modalManager.launch(a).catch(()=>{})};init=(()=>{var r,s=this;return r=(0,_home_runner_work_angor_hub_angor_hub_node_modules_angular_builders_custom_webpack_node_modules_babel_runtime_helpers_esm_asyncToGenerator_js__WEBPACK_IMPORTED_MODULE_1__.A)(function*(i){s.extensionService.startCheckingExtension(s.nostr),window.nostr=s.nostr,s.modalManager.connectModals(i),s.bannerManager.launchAuthBanner(i),i&&(s.params.optionsModal={...i});try{const a=localStorageGetCurrent();if(a){if(!a.pubkey)throw new Error("Bad stored info");yield s.switchAccount(a)}}catch(a){console.log("nostr login init error",a),yield logout()}s.updateAccounts()}),function(i){return r.apply(this,arguments)}})();logout=(()=>{var s=this;return(0,_home_runner_work_angor_hub_angor_hub_node_modules_angular_builders_custom_webpack_node_modules_babel_runtime_helpers_esm_asyncToGenerator_js__WEBPACK_IMPORTED_MODULE_1__.A)(function*(){s.extensionService.unsetExtension(s.nostr),yield s.authNostrService.logout()})})();setDarkMode=s=>{localStorageSetItem("nl-dark-mode",`${s}`),this.bannerManager.onDarkMode(s),this.modalManager.onDarkMode(s)}}const initializer=new NostrLoginInitializer,{init,launch,logout,setDarkMode}=initializer;document.addEventListener("nlLogout",logout),document.addEventListener("nlLaunch",o=>{launch(o.detail||"")}),document.addEventListener("nlDarkMode",o=>{setDarkMode(!!o.detail)})},5492:(o,s,r)=>{"use strict";r.d(s,{lo:()=>Eh,pC:()=>Ja,Bq:()=>uu,dq:()=>Ql,lG:()=>du,sh:()=>Dh,Qe:()=>Cd});var i={};r.r(i),r.d(i,{OG:()=>W,My:()=>Mt,Ph:()=>en,lX:()=>kn,Id:()=>cn,fg:()=>mt,qj:()=>pr,aT:()=>Vt,lq:()=>Kn,z:()=>Nr,Q5:()=>Tn});var a=r(3014);function c(b){if(!Number.isSafeInteger(b)||b<0)throw new Error(`Wrong positive integer: ${b}`)}function w(b,...E){if(!(b instanceof Uint8Array))throw new Error("Expected Uint8Array");if(E.length>0&&!E.includes(b.length))throw new Error(`Expected Uint8Array of length ${E}, not of length=${b.length}`)}function T(b,E=!0){if(b.destroyed)throw new Error("Hash instance has been destroyed");if(E&&b.finished)throw new Error("Hash#digest() has already been called")}const L="object"==typeof globalThis&&"crypto"in globalThis?globalThis.crypto:void 0,Z=b=>b instanceof Uint8Array,pe=b=>new DataView(b.buffer,b.byteOffset,b.byteLength),se=(b,E)=>b<<32-E|b>>>E;if(68!==new Uint8Array(new Uint32Array([287454020]).buffer)[0])throw new Error("Non little-endian hardware is not supported");function Ce(b){if("string"==typeof b&&(b=function ue(b){if("string"!=typeof b)throw new Error("utf8ToBytes expected string, got "+typeof b);return new Uint8Array((new TextEncoder).encode(b))}(b)),!Z(b))throw new Error("expected Uint8Array, got "+typeof b);return b}class at{clone(){return this._cloneInto()}}function lt(b){const E=j=>b().update(Ce(j)).digest(),A=b();return E.outputLen=A.outputLen,E.blockLen=A.blockLen,E.create=()=>b(),E}function bn(b=32){if(L&&"function"==typeof L.getRandomValues)return L.getRandomValues(new Uint8Array(b));throw new Error("crypto.getRandomValues must be defined")}class yn extends at{constructor(E,A,j,X){super(),this.blockLen=E,this.outputLen=A,this.padOffset=j,this.isLE=X,this.finished=!1,this.length=0,this.pos=0,this.destroyed=!1,this.buffer=new Uint8Array(E),this.view=pe(this.buffer)}update(E){T(this);const{view:A,buffer:j,blockLen:X}=this,le=(E=Ce(E)).length;for(let Me=0;MeX-Me&&(this.process(j,0),Me=0);for(let Lt=Me;Lt>X&le),Pe=Number(A&le),wt=j?0:4;b.setUint32(E+(j?4:0),Me,j),b.setUint32(E+wt,Pe,j)})(j,X-8,BigInt(8*this.length),le),this.process(j,0);const Pe=pe(E),Qe=this.outputLen;if(Qe%4)throw new Error("_sha2: outputLen should be aligned to 32bit");const wt=Qe/4,Pt=this.get();if(wt>Pt.length)throw new Error("_sha2: outputLen bigger than state");for(let Lt=0;Ltb&E^~b&A,_t=(b,E,A)=>b&E^b&A^E&A,ze=new Uint32Array([1116352408,1899447441,3049323471,3921009573,961987163,1508970993,2453635748,2870763221,3624381080,310598401,607225278,1426881987,1925078388,2162078206,2614888103,3248222580,3835390401,4022224774,264347078,604807628,770255983,1249150122,1555081692,1996064986,2554220882,2821834349,2952996808,3210313671,3336571891,3584528711,113926993,338241895,666307205,773529912,1294757372,1396182291,1695183700,1986661051,2177026350,2456956037,2730485921,2820302411,3259730800,3345764771,3516065817,3600352804,4094571909,275423344,430227734,506948616,659060556,883997877,958139571,1322822218,1537002063,1747873779,1955562222,2024104815,2227730452,2361852424,2428436474,2756734187,3204031479,3329325298]),$e=new Uint32Array([1779033703,3144134277,1013904242,2773480762,1359893119,2600822924,528734635,1541459225]),Ft=new Uint32Array(64);class Ke extends yn{constructor(){super(64,32,8,!1),this.A=0|$e[0],this.B=0|$e[1],this.C=0|$e[2],this.D=0|$e[3],this.E=0|$e[4],this.F=0|$e[5],this.G=0|$e[6],this.H=0|$e[7]}get(){const{A:E,B:A,C:j,D:X,E:le,F:Me,G:Pe,H:Qe}=this;return[E,A,j,X,le,Me,Pe,Qe]}set(E,A,j,X,le,Me,Pe,Qe){this.A=0|E,this.B=0|A,this.C=0|j,this.D=0|X,this.E=0|le,this.F=0|Me,this.G=0|Pe,this.H=0|Qe}process(E,A){for(let Lt=0;Lt<16;Lt++,A+=4)Ft[Lt]=E.getUint32(A,!1);for(let Lt=16;Lt<64;Lt++){const nn=Ft[Lt-15],pn=Ft[Lt-2],tn=se(nn,7)^se(nn,18)^nn>>>3,Yt=se(pn,17)^se(pn,19)^pn>>>10;Ft[Lt]=Yt+Ft[Lt-7]+tn+Ft[Lt-16]|0}let{A:j,B:X,C:le,D:Me,E:Pe,F:Qe,G:wt,H:Pt}=this;for(let Lt=0;Lt<64;Lt++){const pn=Pt+(se(Pe,6)^se(Pe,11)^se(Pe,25))+qe(Pe,Qe,wt)+ze[Lt]+Ft[Lt]|0,Yt=(se(j,2)^se(j,13)^se(j,22))+_t(j,X,le)|0;Pt=wt,wt=Qe,Qe=Pe,Pe=Me+pn|0,Me=le,le=X,X=j,j=pn+Yt|0}j=j+this.A|0,X=X+this.B|0,le=le+this.C|0,Me=Me+this.D|0,Pe=Pe+this.E|0,Qe=Qe+this.F|0,wt=wt+this.G|0,Pt=Pt+this.H|0,this.set(j,X,le,Me,Pe,Qe,wt,Pt)}roundClean(){Ft.fill(0)}destroy(){this.set(0,0,0,0,0,0,0,0),this.buffer.fill(0)}}const it=lt(()=>new Ke),Te=(BigInt(0),BigInt(1)),Ee=BigInt(2),st=b=>b instanceof Uint8Array,Xt=Array.from({length:256},(b,E)=>E.toString(16).padStart(2,"0"));function Mt(b){if(!st(b))throw new Error("Uint8Array expected");let E="";for(let A=0;Aj+X.length,0));let A=0;return b.forEach(j=>{if(!st(j))throw new Error("Uint8Array expected");E.set(j,A),A+=j.length}),E}const W=b=>(Ee<new Uint8Array(b),ft=b=>Uint8Array.from(b);function mt(b,E,A){if("number"!=typeof b||b<2)throw new Error("hashLen must be a number");if("number"!=typeof E||E<2)throw new Error("qByteLen must be a number");if("function"!=typeof A)throw new Error("hmacFn must be a function");let j=Le(b),X=Le(b),le=0;const Me=()=>{j.fill(1),X.fill(0),le=0},Pe=(...Lt)=>A(X,j,...Lt),Qe=(Lt=Le())=>{X=Pe(ft([0]),Lt),j=Pe(),0!==Lt.length&&(X=Pe(ft([1]),Lt),j=Pe())},wt=()=>{if(le++>=1e3)throw new Error("drbg: tried 1000 values");let Lt=0;const nn=[];for(;Lt{let pn;for(Me(),Qe(Lt);!(pn=nn(wt()));)Qe();return Me(),pn}}const St={bigint:b=>"bigint"==typeof b,function:b=>"function"==typeof b,boolean:b=>"boolean"==typeof b,string:b=>"string"==typeof b,stringOrUint8Array:b=>"string"==typeof b||b instanceof Uint8Array,isSafeInteger:b=>Number.isSafeInteger(b),array:b=>Array.isArray(b),field:(b,E)=>E.Fp.isValid(b),hash:b=>"function"==typeof b&&Number.isSafeInteger(b.outputLen)};function Tn(b,E,A={}){const j=(X,le,Me)=>{const Pe=St[le];if("function"!=typeof Pe)throw new Error(`Invalid validator "${le}", expected function`);const Qe=b[X];if(!(Me&&void 0===Qe||Pe(Qe,b)))throw new Error(`Invalid param ${String(X)}=${Qe} (${typeof Qe}), expected ${le}`)};for(const[X,le]of Object.entries(E))j(X,le,!1);for(const[X,le]of Object.entries(A))j(X,le,!0);return b}const an=BigInt(0),dn=BigInt(1),In=BigInt(2),sr=BigInt(3),xn=BigInt(4),Hr=BigInt(5),Tr=BigInt(8);function Wt(b,E){const A=b%E;return A>=an?A:E+A}function Re(b,E,A){if(A<=an||E 0");if(A===dn)return an;let j=dn;for(;E>an;)E&dn&&(j=j*b%A),b=b*b%A,E>>=dn;return j}function Ge(b,E,A){let j=b;for(;E-- >an;)j*=j,j%=A;return j}function Ve(b,E){if(b===an||E<=an)throw new Error(`invert: expected positive integers, got n=${b} mod=${E}`);let A=Wt(b,E),j=E,X=an,le=dn,Me=dn,Pe=an;for(;A!==an;){const wt=j/A,Pt=j%A,Lt=X-Me*wt,nn=le-Pe*wt;j=A,A=Pt,X=Me,le=Pe,Me=Lt,Pe=nn}if(j!==dn)throw new Error("invert: does not exist");return Wt(X,E)}BigInt(9),BigInt(16);const wn=["create","isValid","is0","neg","inv","sqrt","sqr","eql","add","sub","mul","pow","div","addN","subN","mulN","sqrN"];function Jt(b,E){const A=void 0!==E?E:b.toString(2).length;return{nBitLength:A,nByteLength:Math.ceil(A/8)}}function mn(b){if("bigint"!=typeof b)throw new Error("field order must be bigint");const E=b.toString(2).length;return Math.ceil(E/8)}function dr(b){const E=mn(b);return E+Math.ceil(E/2)}class Ni extends at{constructor(E,A){super(),this.finished=!1,this.destroyed=!1,function C(b){if("function"!=typeof b||"function"!=typeof b.create)throw new Error("Hash should be wrapped by utils.wrapConstructor");c(b.outputLen),c(b.blockLen)}(E);const j=Ce(A);if(this.iHash=E.create(),"function"!=typeof this.iHash.update)throw new Error("Expected instance of class which extends utils.Hash");this.blockLen=this.iHash.blockLen,this.outputLen=this.iHash.outputLen;const X=this.blockLen,le=new Uint8Array(X);le.set(j.length>X?E.create().update(j).digest():j);for(let Me=0;Menew Ni(b,E).update(A).digest();ds.create=(b,E)=>new Ni(b,E);const $o=BigInt(0),ai=BigInt(1);function fo(b){return function qn(b){Tn(b,wn.reduce((j,X)=>(j[X]="function",j),{ORDER:"bigint",MASK:"bigint",BYTES:"isSafeInteger",BITS:"isSafeInteger"}))}(b.Fp),Tn(b,{n:"bigint",h:"bigint",Gx:"field",Gy:"field"},{nBitLength:"isSafeInteger",nByteLength:"isSafeInteger"}),Object.freeze({...Jt(b.n,b.nBitLength),...b,p:b.Fp.ORDER})}const{Ph:Fo,aT:oa}=i,ao={Err:class extends Error{constructor(E=""){super(E)}},_parseInt(b){const{Err:E}=ao;if(b.length<2||2!==b[0])throw new E("Invalid signature integer tag");const A=b[1],j=b.subarray(2,A+2);if(!A||j.length!==A)throw new E("Invalid signature integer: wrong length");if(128&j[0])throw new E("Invalid signature integer: negative");if(0===j[0]&&!(128&j[1]))throw new E("Invalid signature integer: unnecessary leading zero");return{d:Fo(j),l:b.subarray(A+2)}},toSig(b){const{Err:E}=ao,A="string"==typeof b?oa(b):b;if(!(A instanceof Uint8Array))throw new Error("ui8a expected");let j=A.length;if(j<2||48!=A[0])throw new E("Invalid signature tag");if(A[1]!==j-2)throw new E("Invalid signature: incorrect length");const{d:X,l:le}=ao._parseInt(A.subarray(2)),{d:Me,l:Pe}=ao._parseInt(le);if(Pe.length)throw new E("Invalid signature: left bytes after parsing");return{r:X,s:Me}},hexFromSig(b){const E=wt=>8&Number.parseInt(wt[0],16)?"00"+wt:wt,A=wt=>{const Pt=wt.toString(16);return 1&Pt.length?`0${Pt}`:Pt},j=E(A(b.s)),X=E(A(b.r)),le=j.length/2,Me=X.length/2,Pe=A(le),Qe=A(Me);return`30${A(Me+le+4)}02${Qe}${X}02${Pe}${j}`}},po=BigInt(0),Ii=BigInt(1),tt=(BigInt(2),BigInt(3));function Ye(b){const E=function ve(b){const E=fo(b);return Tn(E,{hash:"hash",hmac:"function",randomBytes:"function"},{bits2int:"function",bits2int_modN:"function",lowS:"boolean"}),Object.freeze({lowS:!0,...E})}(b),{Fp:A,n:j}=E,X=A.BYTES+1,le=2*A.BYTES+1;function Pe(rr){return Wt(rr,j)}function Qe(rr){return Ve(rr,j)}const{ProjectivePoint:wt,normPrivateKeyToScalar:Pt,weierstrassEquation:Lt,isWithinCurveOrder:nn}=function ht(b){const E=function Jo(b){const E=fo(b);Tn(E,{a:"field",b:"field"},{allowedPrivateKeyLengths:"array",wrapPrivateKey:"boolean",isTorsionFree:"function",clearCofactor:"function",allowInfinityPoint:"boolean",fromBytes:"function",toBytes:"function"});const{endo:A,Fp:j,a:X}=E;if(A){if(!j.eql(X,j.ZERO))throw new Error("Endomorphism can only be defined for Koblitz curves that have a=0");if("object"!=typeof A||"bigint"!=typeof A.beta||"function"!=typeof A.splitScalar)throw new Error("Expected endomorphism with beta: bigint and splitScalar: function")}return Object.freeze({...E})}(b),{Fp:A}=E,j=E.toBytes||((tn,Yt,Zt)=>{const vn=Yt.toAffine();return cn(Uint8Array.from([4]),A.toBytes(vn.x),A.toBytes(vn.y))}),X=E.fromBytes||(tn=>{const Yt=tn.subarray(1);return{x:A.fromBytes(Yt.subarray(0,A.BYTES)),y:A.fromBytes(Yt.subarray(A.BYTES,2*A.BYTES))}});function le(tn){const{a:Yt,b:Zt}=E,vn=A.sqr(tn),Sn=A.mul(vn,tn);return A.add(A.add(Sn,A.mul(tn,Yt)),Zt)}if(!A.eql(A.sqr(E.Gy),le(E.Gx)))throw new Error("bad generator point: equation left != right");function Me(tn){return"bigint"==typeof tn&&poA.eql(Zn,A.ZERO);return Sn(Zt)&&Sn(vn)?Lt.ZERO:new Lt(Zt,vn,A.ONE)}get x(){return this.toAffine().x}get y(){return this.toAffine().y}static normalizeZ(Yt){const Zt=A.invertBatch(Yt.map(vn=>vn.pz));return Yt.map((vn,Sn)=>vn.toAffine(Zt[Sn])).map(Lt.fromAffine)}static fromHex(Yt){const Zt=Lt.fromAffine(X(pr("pointHex",Yt)));return Zt.assertValidity(),Zt}static fromPrivateKey(Yt){return Lt.BASE.multiply(Qe(Yt))}_setWindowSize(Yt){this._WINDOW_SIZE=Yt,wt.delete(this)}assertValidity(){if(this.is0()){if(E.allowInfinityPoint&&!A.is0(this.py))return;throw new Error("bad point: ZERO")}const{x:Yt,y:Zt}=this.toAffine();if(!A.isValid(Yt)||!A.isValid(Zt))throw new Error("bad point: x or y not FE");const vn=A.sqr(Zt),Sn=le(Yt);if(!A.eql(vn,Sn))throw new Error("bad point: equation left != right");if(!this.isTorsionFree())throw new Error("bad point: not in prime-order subgroup")}hasEvenY(){const{y:Yt}=this.toAffine();if(A.isOdd)return!A.isOdd(Yt);throw new Error("Field doesn't support isOdd")}equals(Yt){Pt(Yt);const{px:Zt,py:vn,pz:Sn}=this,{px:Zn,py:or,pz:Lr}=Yt,mr=A.eql(A.mul(Zt,Lr),A.mul(Zn,Sn)),Ar=A.eql(A.mul(vn,Lr),A.mul(or,Sn));return mr&&Ar}negate(){return new Lt(this.px,A.neg(this.py),this.pz)}double(){const{a:Yt,b:Zt}=E,vn=A.mul(Zt,tt),{px:Sn,py:Zn,pz:or}=this;let Lr=A.ZERO,mr=A.ZERO,Ar=A.ZERO,$r=A.mul(Sn,Sn),Ri=A.mul(Zn,Zn),Ei=A.mul(or,or),ei=A.mul(Sn,Zn);return ei=A.add(ei,ei),Ar=A.mul(Sn,or),Ar=A.add(Ar,Ar),Lr=A.mul(Yt,Ar),mr=A.mul(vn,Ei),mr=A.add(Lr,mr),Lr=A.sub(Ri,mr),mr=A.add(Ri,mr),mr=A.mul(Lr,mr),Lr=A.mul(ei,Lr),Ar=A.mul(vn,Ar),Ei=A.mul(Yt,Ei),ei=A.sub($r,Ei),ei=A.mul(Yt,ei),ei=A.add(ei,Ar),Ar=A.add($r,$r),$r=A.add(Ar,$r),$r=A.add($r,Ei),$r=A.mul($r,ei),mr=A.add(mr,$r),Ei=A.mul(Zn,or),Ei=A.add(Ei,Ei),$r=A.mul(Ei,ei),Lr=A.sub(Lr,$r),Ar=A.mul(Ei,Ri),Ar=A.add(Ar,Ar),Ar=A.add(Ar,Ar),new Lt(Lr,mr,Ar)}add(Yt){Pt(Yt);const{px:Zt,py:vn,pz:Sn}=this,{px:Zn,py:or,pz:Lr}=Yt;let mr=A.ZERO,Ar=A.ZERO,$r=A.ZERO;const Ri=E.a,Ei=A.mul(E.b,tt);let ei=A.mul(Zt,Zn),eo=A.mul(vn,or),to=A.mul(Sn,Lr),wo=A.add(Zt,vn),rr=A.add(Zn,or);wo=A.mul(wo,rr),rr=A.add(ei,eo),wo=A.sub(wo,rr),rr=A.add(Zt,Sn);let hr=A.add(Zn,Lr);return rr=A.mul(rr,hr),hr=A.add(ei,to),rr=A.sub(rr,hr),hr=A.add(vn,Sn),mr=A.add(or,Lr),hr=A.mul(hr,mr),mr=A.add(eo,to),hr=A.sub(hr,mr),$r=A.mul(Ri,rr),mr=A.mul(Ei,to),$r=A.add(mr,$r),mr=A.sub(eo,$r),$r=A.add(eo,$r),Ar=A.mul(mr,$r),eo=A.add(ei,ei),eo=A.add(eo,ei),to=A.mul(Ri,to),rr=A.mul(Ei,rr),eo=A.add(eo,to),to=A.sub(ei,to),to=A.mul(Ri,to),rr=A.add(rr,to),ei=A.mul(eo,rr),Ar=A.add(Ar,ei),ei=A.mul(hr,rr),mr=A.mul(wo,mr),mr=A.sub(mr,ei),ei=A.mul(wo,eo),$r=A.mul(hr,$r),$r=A.add($r,ei),new Lt(mr,Ar,$r)}subtract(Yt){return this.add(Yt.negate())}is0(){return this.equals(Lt.ZERO)}wNAF(Yt){return pn.wNAFCached(this,wt,Yt,Zt=>{const vn=A.invertBatch(Zt.map(Sn=>Sn.pz));return Zt.map((Sn,Zn)=>Sn.toAffine(vn[Zn])).map(Lt.fromAffine)})}multiplyUnsafe(Yt){const Zt=Lt.ZERO;if(Yt===po)return Zt;if(Pe(Yt),Yt===Ii)return this;const{endo:vn}=E;if(!vn)return pn.unsafeLadder(this,Yt);let{k1neg:Sn,k1:Zn,k2neg:or,k2:Lr}=vn.splitScalar(Yt),mr=Zt,Ar=Zt,$r=this;for(;Zn>po||Lr>po;)Zn&Ii&&(mr=mr.add($r)),Lr&Ii&&(Ar=Ar.add($r)),$r=$r.double(),Zn>>=Ii,Lr>>=Ii;return Sn&&(mr=mr.negate()),or&&(Ar=Ar.negate()),Ar=new Lt(A.mul(Ar.px,vn.beta),Ar.py,Ar.pz),mr.add(Ar)}multiply(Yt){Pe(Yt);let vn,Sn,Zt=Yt;const{endo:Zn}=E;if(Zn){const{k1neg:or,k1:Lr,k2neg:mr,k2:Ar}=Zn.splitScalar(Zt);let{p:$r,f:Ri}=this.wNAF(Lr),{p:Ei,f:ei}=this.wNAF(Ar);$r=pn.constTimeNegate(or,$r),Ei=pn.constTimeNegate(mr,Ei),Ei=new Lt(A.mul(Ei.px,Zn.beta),Ei.py,Ei.pz),vn=$r.add(Ei),Sn=Ri.add(ei)}else{const{p:or,f:Lr}=this.wNAF(Zt);vn=or,Sn=Lr}return Lt.normalizeZ([vn,Sn])[0]}multiplyAndAddUnsafe(Yt,Zt,vn){const Sn=Lt.BASE,Zn=(Lr,mr)=>mr!==po&&mr!==Ii&&Lr.equals(Sn)?Lr.multiply(mr):Lr.multiplyUnsafe(mr),or=Zn(this,Zt).add(Zn(Yt,vn));return or.is0()?void 0:or}toAffine(Yt){const{px:Zt,py:vn,pz:Sn}=this,Zn=this.is0();null==Yt&&(Yt=Zn?A.ONE:A.inv(Sn));const or=A.mul(Zt,Yt),Lr=A.mul(vn,Yt),mr=A.mul(Sn,Yt);if(Zn)return{x:A.ZERO,y:A.ZERO};if(!A.eql(mr,A.ONE))throw new Error("invZ was invalid");return{x:or,y:Lr}}isTorsionFree(){const{h:Yt,isTorsionFree:Zt}=E;if(Yt===Ii)return!0;if(Zt)return Zt(Lt,this);throw new Error("isTorsionFree() has not been declared for the elliptic curve")}clearCofactor(){const{h:Yt,clearCofactor:Zt}=E;return Yt===Ii?this:Zt?Zt(Lt,this):this.multiplyUnsafe(E.h)}toRawBytes(Yt=!0){return this.assertValidity(),j(Lt,this,Yt)}toHex(Yt=!0){return Mt(this.toRawBytes(Yt))}}Lt.BASE=new Lt(E.Gx,E.Gy,A.ONE),Lt.ZERO=new Lt(A.ZERO,A.ONE,A.ZERO);const nn=E.nBitLength,pn=function qo(b,E){const A=(X,le)=>{const Me=le.negate();return X?Me:le},j=X=>({windows:Math.ceil(E/X)+1,windowSize:2**(X-1)});return{constTimeNegate:A,unsafeLadder(X,le){let Me=b.ZERO,Pe=X;for(;le>$o;)le&ai&&(Me=Me.add(Pe)),Pe=Pe.double(),le>>=ai;return Me},precomputeWindow(X,le){const{windows:Me,windowSize:Pe}=j(le),Qe=[];let wt=X,Pt=wt;for(let Lt=0;Lt>=pn,Zt>Qe&&(Zt-=nn,Me+=ai);const vn=Yt,Sn=Yt+Math.abs(Zt)-1,or=Zt<0;0===Zt?Pt=Pt.add(A(tn%2!=0,le[vn])):wt=wt.add(A(or,le[Sn]))}return{p:wt,f:Pt}},wNAFCached(X,le,Me,Pe){const Qe=X._WINDOW_SIZE||1;let wt=le.get(X);return wt||(wt=this.precomputeWindow(X,Qe),1!==Qe&&le.set(X,Pe(wt))),this.wNAF(Qe,wt,Me)}}}(Lt,E.endo?Math.ceil(nn/2):nn);return{CURVE:E,ProjectivePoint:Lt,normPrivateKeyToScalar:Qe,weierstrassEquation:le,isWithinCurveOrder:Me}}({...E,toBytes(rr,hr,Yr){const mi=hr.toAffine(),yr=A.toBytes(mi.x),oi=cn;return Yr?oi(Uint8Array.from([hr.hasEvenY()?2:3]),yr):oi(Uint8Array.from([4]),yr,A.toBytes(mi.y))},fromBytes(rr){const hr=rr.length,Yr=rr[0],mi=rr.subarray(1);if(hr!==X||2!==Yr&&3!==Yr){if(hr===le&&4===Yr)return{x:A.fromBytes(mi.subarray(0,A.BYTES)),y:A.fromBytes(mi.subarray(A.BYTES,2*A.BYTES))};throw new Error(`Point of length ${hr} was invalid. Expected ${X} compressed bytes or ${le} uncompressed bytes`)}{const yr=en(mi);if(!function Me(rr){return poMt(Kn(rr,E.nByteLength));function tn(rr){return rr>j>>Ii}const Zt=(rr,hr,Yr)=>en(rr.slice(hr,Yr));class vn{constructor(hr,Yr,mi){this.r=hr,this.s=Yr,this.recovery=mi,this.assertValidity()}static fromCompact(hr){const Yr=E.nByteLength;return hr=pr("compactSignature",hr,2*Yr),new vn(Zt(hr,0,Yr),Zt(hr,Yr,2*Yr))}static fromDER(hr){const{r:Yr,s:mi}=ao.toSig(pr("DER",hr));return new vn(Yr,mi)}assertValidity(){if(!nn(this.r))throw new Error("r must be 0 < r < CURVE.n");if(!nn(this.s))throw new Error("s must be 0 < s < CURVE.n")}addRecoveryBit(hr){return new vn(this.r,this.s,hr)}recoverPublicKey(hr){const{r:Yr,s:mi,recovery:yr}=this,oi=Ar(pr("msgHash",hr));if(null==yr||![0,1,2,3].includes(yr))throw new Error("recovery id invalid");const Eo=2===yr||3===yr?Yr+E.n:Yr;if(Eo>=A.ORDER)throw new Error("recovery id 2 or 3 invalid");const Bs=wt.fromHex((1&yr?"03":"02")+pn(Eo)),Na=Qe(Eo),rl=Pe(-oi*Na),gl=Pe(mi*Na),ba=wt.BASE.multiplyAndAddUnsafe(Bs,rl,gl);if(!ba)throw new Error("point at infinify");return ba.assertValidity(),ba}hasHighS(){return tn(this.s)}normalizeS(){return this.hasHighS()?new vn(this.r,Pe(-this.s),this.recovery):this}toDERRawBytes(){return Vt(this.toDERHex())}toDERHex(){return ao.hexFromSig({r:this.r,s:this.s})}toCompactRawBytes(){return Vt(this.toCompactHex())}toCompactHex(){return pn(this.r)+pn(this.s)}}const Sn={isValidPrivateKey(rr){try{return Pt(rr),!0}catch{return!1}},normPrivateKeyToScalar:Pt,randomPrivateKey:()=>{const rr=dr(E.n);return function Co(b,E,A=!1){const j=b.length,X=mn(E),le=dr(E);if(j<16||j1024)throw new Error(`expected ${le}-1024 bytes of input, got ${j}`);const Pe=Wt(A?en(b):kn(b),E-dn)+dn;return A?Nr(Pe,X):Kn(Pe,X)}(E.randomBytes(rr),E.n)},precompute:(rr=8,hr=wt.BASE)=>(hr._setWindowSize(rr),hr.multiply(BigInt(3)),hr)};function or(rr){const hr=rr instanceof Uint8Array,Yr="string"==typeof rr,mi=(hr||Yr)&&rr.length;return hr?mi===X||mi===le:Yr?mi===2*X||mi===2*le:rr instanceof wt}const mr=E.bits2int||function(rr){const hr=en(rr),Yr=8*rr.length-E.nBitLength;return Yr>0?hr>>BigInt(Yr):hr},Ar=E.bits2int_modN||function(rr){return Pe(mr(rr))},$r=W(E.nBitLength);function Ri(rr){if("bigint"!=typeof rr)throw new Error("bigint expected");if(!(po<=rr&&rr<$r))throw new Error(`bigint expected < 2^${E.nBitLength}`);return Kn(rr,E.nByteLength)}const ei={lowS:E.lowS,prehash:!1},eo={lowS:E.lowS,prehash:!1};return wt.BASE._setWindowSize(8),{CURVE:E,getPublicKey:function Zn(rr,hr=!0){return wt.fromPrivateKey(rr).toRawBytes(hr)},getSharedSecret:function Lr(rr,hr,Yr=!0){if(or(rr))throw new Error("first arg must be private key");if(!or(hr))throw new Error("second arg must be public key");return wt.fromHex(hr).multiply(Pt(rr)).toRawBytes(Yr)},sign:function to(rr,hr,Yr=ei){const{seed:mi,k2sig:yr}=function Ei(rr,hr,Yr=ei){if(["recovered","canonical"].some(wa=>wa in Yr))throw new Error("sign() legacy options not supported");const{hash:mi,randomBytes:yr}=E;let{lowS:oi,prehash:Eo,extraEntropy:Wi}=Yr;null==oi&&(oi=!0),rr=pr("msgHash",rr),Eo&&(rr=pr("prehashed msgHash",mi(rr)));const Bs=Ar(rr),Na=Pt(hr),rl=[Ri(Na),Ri(Bs)];if(null!=Wi){const wa=!0===Wi?yr(A.BYTES):Wi;rl.push(pr("extraEntropy",wa))}const gl=cn(...rl),ba=Bs;return{seed:gl,k2sig:function Xa(wa){const Vc=mr(wa);if(!nn(Vc))return;const $d=Qe(Vc),Po=wt.BASE.multiply(Vc).toAffine(),cc=Pe(Po.x);if(cc===po)return;const ea=Pe($d*Pe(ba+cc*Na));if(ea===po)return;let Zo=(Po.x===cc?0:2)|Number(Po.y&Ii),Hc=ea;return oi&&tn(ea)&&(Hc=function Yt(rr){return tn(rr)?Pe(-rr):rr}(ea),Zo^=1),new vn(cc,Hc,Zo)}}}(rr,hr,Yr);return mt(E.hash.outputLen,E.nByteLength,E.hmac)(mi,yr)},verify:function wo(rr,hr,Yr,mi=eo){const yr=rr;if(hr=pr("msgHash",hr),Yr=pr("publicKey",Yr),"strict"in mi)throw new Error("options.strict was renamed to lowS");const{lowS:oi,prehash:Eo}=mi;let Wi,Bs;try{if("string"==typeof yr||yr instanceof Uint8Array)try{Wi=vn.fromDER(yr)}catch(Po){if(!(Po instanceof ao.Err))throw Po;Wi=vn.fromCompact(yr)}else{if("object"!=typeof yr||"bigint"!=typeof yr.r||"bigint"!=typeof yr.s)throw new Error("PARSE");{const{r:Po,s:cc}=yr;Wi=new vn(Po,cc)}}Bs=wt.fromHex(Yr)}catch(Po){if("PARSE"===Po.message)throw new Error("signature must be Signature instance, Uint8Array or hex string");return!1}if(oi&&Wi.hasHighS())return!1;Eo&&(hr=E.hash(hr));const{r:Na,s:rl}=Wi,gl=Ar(hr),ba=Qe(rl),Xa=Pe(gl*ba),wa=Pe(Na*ba),Vc=wt.BASE.multiplyAndAddUnsafe(Bs,Xa,wa)?.toAffine();return!!Vc&&Pe(Vc.x)===Na},ProjectivePoint:wt,Signature:vn,utils:Sn}}function Ht(b){return{hash:b,hmac:(E,...A)=>ds(b,E,function Be(...b){const E=new Uint8Array(b.reduce((j,X)=>j+X.length,0));let A=0;return b.forEach(j=>{if(!Z(j))throw new Error("Uint8Array expected");E.set(j,A),A+=j.length}),E}(...A)),randomBytes:bn}}BigInt(4);const hn=BigInt("0xfffffffffffffffffffffffffffffffffffffffffffffffffffffffefffffc2f"),Dn=BigInt("0xfffffffffffffffffffffffffffffffebaaedce6af48a03bbfd25e8cd0364141"),Cn=BigInt(1),Nn=BigInt(2),jn=(b,E)=>(b+E/Nn)/E;function Jn(b){const E=hn,A=BigInt(3),j=BigInt(6),X=BigInt(11),le=BigInt(22),Me=BigInt(23),Pe=BigInt(44),Qe=BigInt(88),wt=b*b*b%E,Pt=wt*wt*b%E,Lt=Ge(Pt,A,E)*Pt%E,nn=Ge(Lt,A,E)*Pt%E,pn=Ge(nn,Nn,E)*wt%E,tn=Ge(pn,X,E)*pn%E,Yt=Ge(tn,le,E)*tn%E,Zt=Ge(Yt,Pe,E)*Yt%E,vn=Ge(Zt,Qe,E)*Zt%E,Sn=Ge(vn,Pe,E)*Yt%E,Zn=Ge(Sn,A,E)*Pt%E,or=Ge(Zn,Me,E)*tn%E,Lr=Ge(or,j,E)*wt%E,mr=Ge(Lr,Nn,E);if(!ar.eql(ar.sqr(mr),b))throw new Error("Cannot find square root");return mr}const ar=function Tt(b,E,A=!1,j={}){if(b<=an)throw new Error(`Expected Field ORDER > 0, got ${b}`);const{nBitLength:X,nByteLength:le}=Jt(b,E);if(le>2048)throw new Error("Field lengths over 2048 bytes are not supported");const Me=function ct(b){if(b%xn===sr){const E=(b+dn)/xn;return function(j,X){const le=j.pow(X,E);if(!j.eql(j.sqr(le),X))throw new Error("Cannot find square root");return le}}if(b%Tr===Hr){const E=(b-Hr)/Tr;return function(j,X){const le=j.mul(X,In),Me=j.pow(le,E),Pe=j.mul(X,Me),Qe=j.mul(j.mul(Pe,In),Me),wt=j.mul(Pe,j.sub(Qe,j.ONE));if(!j.eql(j.sqr(wt),X))throw new Error("Cannot find square root");return wt}}return function Dt(b){const E=(b-dn)/In;let A,j,X;for(A=b-dn,j=0;A%In===an;A/=In,j++);for(X=In;XWt(Qe,b),isValid:Qe=>{if("bigint"!=typeof Qe)throw new Error("Invalid field element: expected bigint, got "+typeof Qe);return an<=Qe&&QeQe===an,isOdd:Qe=>(Qe&dn)===dn,neg:Qe=>Wt(-Qe,b),eql:(Qe,wt)=>Qe===wt,sqr:Qe=>Wt(Qe*Qe,b),add:(Qe,wt)=>Wt(Qe+wt,b),sub:(Qe,wt)=>Wt(Qe-wt,b),mul:(Qe,wt)=>Wt(Qe*wt,b),pow:(Qe,wt)=>function Er(b,E,A){if(A 0");if(A===an)return b.ONE;if(A===dn)return E;let j=b.ONE,X=E;for(;A>an;)A&dn&&(j=b.mul(j,X)),X=b.sqr(X),A>>=dn;return j}(Pe,Qe,wt),div:(Qe,wt)=>Wt(Qe*Ve(wt,b),b),sqrN:Qe=>Qe*Qe,addN:(Qe,wt)=>Qe+wt,subN:(Qe,wt)=>Qe-wt,mulN:(Qe,wt)=>Qe*wt,inv:Qe=>Ve(Qe,b),sqrt:j.sqrt||(Qe=>Me(Pe,Qe)),invertBatch:Qe=>function si(b,E){const A=new Array(E.length),j=E.reduce((le,Me,Pe)=>b.is0(Me)?le:(A[Pe]=le,b.mul(le,Me)),b.ONE),X=b.inv(j);return E.reduceRight((le,Me,Pe)=>b.is0(Me)?le:(A[Pe]=b.mul(le,A[Pe]),b.mul(le,Me)),X),A}(Pe,Qe),cmov:(Qe,wt,Pt)=>Pt?wt:Qe,toBytes:Qe=>A?Nr(Qe,le):Kn(Qe,le),fromBytes:Qe=>{if(Qe.length!==le)throw new Error(`Fp.fromBytes: expected ${le}, got ${Qe.length}`);return A?kn(Qe):en(Qe)}});return Object.freeze(Pe)}(hn,void 0,void 0,{sqrt:Jn}),wr=function kt(b,E){const A=j=>Ye({...b,...Ht(j)});return Object.freeze({...A(E),create:A})}({a:BigInt(0),b:BigInt(7),Fp:ar,n:Dn,Gx:BigInt("55066263022277343669578718895168534326250603453777594175500187360389116729240"),Gy:BigInt("32670510020758816978083085130507043184471273380659243275938904335757337482424"),h:BigInt(1),lowS:!0,endo:{beta:BigInt("0x7ae96a2b657c07106e64479eac3434e99cf0497512f58995c1396c28719501ee"),splitScalar:b=>{const E=Dn,A=BigInt("0x3086d221a7d46bcde86c90e49284eb15"),j=-Cn*BigInt("0xe4437ed6010e88286f547fa90abfe4c3"),X=BigInt("0x114ca50f7a8e2f3f657c1108d9d44cfd8"),le=A,Me=BigInt("0x100000000000000000000000000000000"),Pe=jn(le*b,E),Qe=jn(-j*b,E);let wt=Wt(b-Pe*A-Qe*X,E),Pt=Wt(-Pe*j-Qe*le,E);const Lt=wt>Me,nn=Pt>Me;if(Lt&&(wt=E-wt),nn&&(Pt=E-Pt),wt>Me||Pt>Me)throw new Error("splitScalar: Endomorphism failed, k="+b);return{k1neg:Lt,k1:wt,k2neg:nn,k2:Pt}}}},it),xr=BigInt(0),gi=b=>"bigint"==typeof b&&xrX.charCodeAt(0)));A=cn(j,j),Mi[b]=A}return it(cn(A,...E))}const Qr=b=>b.toRawBytes(!0).slice(1),Pr=b=>Kn(b,32),Do=b=>Wt(b,hn),es=b=>Wt(b,Dn),zs=wr.ProjectivePoint;function Li(b){let E=wr.utils.normPrivateKeyToScalar(b),A=zs.fromPrivateKey(E);return{scalar:A.hasEvenY()?E:es(-E),bytes:Qr(A)}}function bi(b){if(!gi(b))throw new Error("bad x: need 0 < x < p");const E=Do(b*b);let j=Jn(Do(E*b+BigInt(7)));j%Nn!==xr&&(j=Do(-j));const X=new zs(b,j,Cn);return X.assertValidity(),X}function aa(...b){return es(en(Or("BIP0340/challenge",...b)))}function Cs(b,E,A){const j=pr("signature",b,64),X=pr("message",E),le=pr("publicKey",A,32);try{const Me=bi(en(le)),Pe=en(j.subarray(0,32));if(!gi(Pe))return!1;const Qe=en(j.subarray(32,64));if(!(b=>"bigint"==typeof b&&xrzs.BASE.multiplyAndAddUnsafe(b,E,A))(Me,Qe,es(-wt));return!(!Pt||!Pt.hasEvenY()||Pt.toAffine().x!==Pe)}catch{return!1}}const No={getPublicKey:function Ks(b){return Li(b).bytes},sign:function Oo(b,E,A=bn(32)){const j=pr("message",b),{bytes:X,scalar:le}=Li(E),Me=pr("auxRand",A,32),Pe=Pr(le^en(Or("BIP0340/aux",Me))),Qe=Or("BIP0340/nonce",Pe,X,j),wt=es(en(Qe));if(wt===xr)throw new Error("sign failed: k is zero");const{bytes:Pt,scalar:Lt}=Li(wt),nn=aa(Pt,X,j),pn=new Uint8Array(64);if(pn.set(Pt,0),pn.set(Pr(es(Lt+nn*le)),32),!Cs(pn,j,X))throw new Error("sign: Invalid signature produced");return pn},verify:Cs,utils:{randomPrivateKey:wr.utils.randomPrivateKey,lift_x:bi,pointToBytes:Qr,numberToBytesBE:Kn,bytesToNumberBE:en,taggedHash:Or,mod:Wt}};var Xr=r(4704);function Ds(b){if(!Number.isSafeInteger(b)||b<0)throw new Error(`Wrong positive integer: ${b}`)}function io(b,...E){if(!(b instanceof Uint8Array))throw new Error("Expected Uint8Array");if(E.length>0&&!E.includes(b.length))throw new Error(`Expected Uint8Array of length ${E}, not of length=${b.length}`)}const Ao={number:Ds,bool:function go(b){if("boolean"!=typeof b)throw new Error(`Expected boolean, not ${b}`)},bytes:io,hash:function fs(b){if("function"!=typeof b||"function"!=typeof b.create)throw new Error("Hash should be wrapped by utils.wrapConstructor");Ds(b.outputLen),Ds(b.blockLen)},exists:function Xo(b,E=!0){if(b.destroyed)throw new Error("Hash instance has been destroyed");if(E&&b.finished)throw new Error("Hash#digest() has already been called")},output:function Qa(b,E){io(b);const A=E.outputLen;if(b.lengthX-Me&&(this.process(j,0),Me=0);for(let Lt=Me;Lt>X&le),Pe=Number(A&le),wt=j?0:4;b.setUint32(E+(j?4:0),Me,j),b.setUint32(E+wt,Pe,j)})(j,X-8,BigInt(8*this.length),le),this.process(j,0);const Pe=(0,Xr.O8)(E),Qe=this.outputLen;if(Qe%4)throw new Error("_sha2: outputLen should be aligned to 32bit");const wt=Qe/4,Pt=this.get();if(wt>Pt.length)throw new Error("_sha2: outputLen bigger than state");for(let Lt=0;Ltb&E^~b&A,_s=(b,E,A)=>b&E^b&A^E&A,la=new Uint32Array([1116352408,1899447441,3049323471,3921009573,961987163,1508970993,2453635748,2870763221,3624381080,310598401,607225278,1426881987,1925078388,2162078206,2614888103,3248222580,3835390401,4022224774,264347078,604807628,770255983,1249150122,1555081692,1996064986,2554220882,2821834349,2952996808,3210313671,3336571891,3584528711,113926993,338241895,666307205,773529912,1294757372,1396182291,1695183700,1986661051,2177026350,2456956037,2730485921,2820302411,3259730800,3345764771,3516065817,3600352804,4094571909,275423344,430227734,506948616,659060556,883997877,958139571,1322822218,1537002063,1747873779,1955562222,2024104815,2227730452,2361852424,2428436474,2756734187,3204031479,3329325298]),ls=new Uint32Array([1779033703,3144134277,1013904242,2773480762,1359893119,2600822924,528734635,1541459225]),Vi=new Uint32Array(64);class ll extends As{constructor(){super(64,32,8,!1),this.A=0|ls[0],this.B=0|ls[1],this.C=0|ls[2],this.D=0|ls[3],this.E=0|ls[4],this.F=0|ls[5],this.G=0|ls[6],this.H=0|ls[7]}get(){const{A:E,B:A,C:j,D:X,E:le,F:Me,G:Pe,H:Qe}=this;return[E,A,j,X,le,Me,Pe,Qe]}set(E,A,j,X,le,Me,Pe,Qe){this.A=0|E,this.B=0|A,this.C=0|j,this.D=0|X,this.E=0|le,this.F=0|Me,this.G=0|Pe,this.H=0|Qe}process(E,A){for(let Lt=0;Lt<16;Lt++,A+=4)Vi[Lt]=E.getUint32(A,!1);for(let Lt=16;Lt<64;Lt++){const nn=Vi[Lt-15],pn=Vi[Lt-2],tn=(0,Xr.Ow)(nn,7)^(0,Xr.Ow)(nn,18)^nn>>>3,Yt=(0,Xr.Ow)(pn,17)^(0,Xr.Ow)(pn,19)^pn>>>10;Vi[Lt]=Yt+Vi[Lt-7]+tn+Vi[Lt-16]|0}let{A:j,B:X,C:le,D:Me,E:Pe,F:Qe,G:wt,H:Pt}=this;for(let Lt=0;Lt<64;Lt++){const pn=Pt+((0,Xr.Ow)(Pe,6)^(0,Xr.Ow)(Pe,11)^(0,Xr.Ow)(Pe,25))+Gs(Pe,Qe,wt)+la[Lt]+Vi[Lt]|0,Yt=((0,Xr.Ow)(j,2)^(0,Xr.Ow)(j,13)^(0,Xr.Ow)(j,22))+_s(j,X,le)|0;Pt=wt,wt=Qe,Qe=Pe,Pe=Me+pn|0,Me=le,le=X,X=j,j=pn+Yt|0}j=j+this.A|0,X=X+this.B|0,le=le+this.C|0,Me=Me+this.D|0,Pe=Pe+this.E|0,Qe=Qe+this.F|0,wt=wt+this.G|0,Pt=Pt+this.H|0,this.set(j,X,le,Me,Pe,Qe,wt,Pt)}roundClean(){Vi.fill(0)}destroy(){this.set(0,0,0,0,0,0,0,0),this.buffer.fill(0)}}class ca extends ll{constructor(){super(),this.A=-1056596264,this.B=914150663,this.C=812702999,this.D=-150054599,this.E=-4191439,this.F=1750603025,this.G=1694076839,this.H=-1090891868,this.outputLen=28}}const Ss=(0,Xr.ld)(()=>new ll);function Ns(b){if(!Number.isSafeInteger(b))throw new Error(`Wrong integer: ${b}`)}function So(...b){const E=(X,le)=>Me=>X(le(Me));return{encode:Array.from(b).reverse().reduce((X,le)=>X?E(X,le.encode):le.encode,void 0),decode:b.reduce((X,le)=>X?E(X,le.decode):le.decode,void 0)}}function Bo(b){return{encode:E=>{if(!Array.isArray(E)||E.length&&"number"!=typeof E[0])throw new Error("alphabet.encode input should be an array of numbers");return E.map(A=>{if(Ns(A),A<0||A>=b.length)throw new Error(`Digit index outside alphabet: ${A} (alphabet: ${b.length})`);return b[A]})},decode:E=>{if(!Array.isArray(E)||E.length&&"string"!=typeof E[0])throw new Error("alphabet.decode input should be array of strings");return E.map(A=>{if("string"!=typeof A)throw new Error(`alphabet.decode: not string element=${A}`);const j=b.indexOf(A);if(-1===j)throw new Error(`Unknown letter: "${A}". Allowed: ${b}`);return j})}}}function lo(b=""){if("string"!=typeof b)throw new Error("join separator should be string");return{encode:E=>{if(!Array.isArray(E)||E.length&&"string"!=typeof E[0])throw new Error("join.encode input should be array of strings");for(let A of E)if("string"!=typeof A)throw new Error(`join.encode: non-string input=${A}`);return E.join(b)},decode:E=>{if("string"!=typeof E)throw new Error("join.decode input should be string");return E.split(b)}}}function ps(b,E="="){if(Ns(b),"string"!=typeof E)throw new Error("padding chr should be string");return{encode(A){if(!Array.isArray(A)||A.length&&"string"!=typeof A[0])throw new Error("padding.encode input should be array of strings");for(let j of A)if("string"!=typeof j)throw new Error(`padding.encode: non-string input=${j}`);for(;A.length*b%8;)A.push(E);return A},decode(A){if(!Array.isArray(A)||A.length&&"string"!=typeof A[0])throw new Error("padding.encode input should be array of strings");for(let X of A)if("string"!=typeof X)throw new Error(`padding.decode: non-string input=${X}`);let j=A.length;if(j*b%8)throw new Error("Invalid padding: string should have whole number of bytes");for(;j>0&&A[j-1]===E;j--)if(!((j-1)*b%8))throw new Error("Invalid padding: string has too much padding");return A.slice(0,j)}}}function Da(b){if("function"!=typeof b)throw new Error("normalize fn should be function");return{encode:E=>E,decode:E=>b(E)}}function Ms(b,E,A){if(E<2)throw new Error(`convertRadix: wrong from=${E}, base cannot be less than 2`);if(A<2)throw new Error(`convertRadix: wrong to=${A}, base cannot be less than 2`);if(!Array.isArray(b))throw new Error("convertRadix: data should be array");if(!b.length)return[];let j=0;const X=[],le=Array.from(b);for(le.forEach(Me=>{if(Ns(Me),Me<0||Me>=E)throw new Error(`Wrong integer: ${Me}`)});;){let Me=0,Pe=!0;for(let Qe=j;Qenew ca);const Us=(b,E)=>E?Us(E,b%E):b,ua=(b,E)=>b+(E-Us(b,E));function Ba(b,E,A,j){if(!Array.isArray(b))throw new Error("convertRadix2: data should be array");if(E<=0||E>32)throw new Error(`convertRadix2: wrong from=${E}`);if(A<=0||A>32)throw new Error(`convertRadix2: wrong to=${A}`);if(ua(E,A)>32)throw new Error(`convertRadix2: carry overflow from=${E} to=${A} carryBits=${ua(E,A)}`);let X=0,le=0;const Me=2**A-1,Pe=[];for(const Qe of b){if(Ns(Qe),Qe>=2**E)throw new Error(`convertRadix2: invalid data word=${Qe} from=${E}`);if(X=X<32)throw new Error(`convertRadix2: carry overflow pos=${le} from=${E}`);for(le+=E;le>=A;le-=A)Pe.push((X>>le-A&Me)>>>0);X&=2**le-1}if(X=X<=E)throw new Error("Excess padding");if(!j&&X)throw new Error(`Non-zero padding: ${X}`);return j&&le>0&&Pe.push(X>>>0),Pe}function Q(b,E=!1){if(Ns(b),b<=0||b>32)throw new Error("radix2: bits should be in (0..32]");if(ua(8,b)>32||ua(b,8)>32)throw new Error("radix2: carry overflow");return{encode:A=>{if(!(A instanceof Uint8Array))throw new Error("radix2.encode input should be Uint8Array");return Ba(Array.from(A),8,b,!E)},decode:A=>{if(!Array.isArray(A)||A.length&&"number"!=typeof A[0])throw new Error("radix2.decode input should be array of strings");return Uint8Array.from(Ba(A,b,8,E))}}}function et(b){if("function"!=typeof b)throw new Error("unsafeWrapper fn should be function");return function(...E){try{return b.apply(null,E)}catch{}}}So(Q(4),Bo("0123456789ABCDEF"),lo("")),So(Q(5),Bo("ABCDEFGHIJKLMNOPQRSTUVWXYZ234567"),ps(5),lo(""));const Qn=(So(Q(5),Bo("0123456789ABCDEFGHIJKLMNOPQRSTUV"),ps(5),lo("")),So(Q(5),Bo("0123456789ABCDEFGHJKMNPQRSTVWXYZ"),lo(""),Da(b=>b.toUpperCase().replace(/O/g,"0").replace(/[IL]/g,"1"))),So(Q(6),Bo("ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/"),ps(6),lo(""))),zi=(So(Q(6),Bo("ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789-_"),ps(6),lo("")),b=>So(function Aa(b){return Ns(b),{encode:E=>{if(!(E instanceof Uint8Array))throw new Error("radix.encode input should be Uint8Array");return Ms(Array.from(E),256,b)},decode:E=>{if(!Array.isArray(E)||E.length&&"number"!=typeof E[0])throw new Error("radix.decode input should be array of strings");return Uint8Array.from(Ms(E,b,256))}}}(58),Bo(b),lo(""))),jo=(zi("123456789ABCDEFGHJKLMNPQRSTUVWXYZabcdefghijkmnopqrstuvwxyz"),zi("123456789abcdefghijkmnopqrstuvwxyzABCDEFGHJKLMNPQRSTUVWXYZ"),zi("rpshnaf39wBUDNEGHJKLM4PQRST7VWXYZ2bcdeCg65jkm8oFqi1tuvAxyz"),So(Bo("qpzry9x8gf2tvdw0s3jn54khce6mua7l"),lo(""))),Ho=[996825010,642813549,513874426,1027748829,705979059];function Ua(b){const E=b>>25;let A=(33554431&b)<<5;for(let j=0;j>j&1)&&(A^=Ho[j]);return A}function $a(b,E,A=1){const j=b.length;let X=1;for(let le=0;le126)throw new Error(`Invalid prefix (${b})`);X=Ua(X)^Me>>5}X=Ua(X);for(let le=0;leLt)throw new TypeError(`Wrong string length: ${Pt.length} (${Pt}). Expected (8..${Lt})`);const nn=Pt.toLowerCase();if(Pt!==nn&&Pt!==Pt.toUpperCase())throw new Error("String must be lowercase or uppercase");const pn=(Pt=nn).lastIndexOf("1");if(0===pn||-1===pn)throw new Error('Letter "1" must be present between prefix and data only');const tn=Pt.slice(0,pn),Yt=Pt.slice(pn+1);if(Yt.length<6)throw new Error("Data must be at least 6 characters long");const Zt=jo.decode(Yt).slice(0,-6),vn=$a(tn,Zt,E);if(!Yt.endsWith(vn))throw new Error(`Invalid checksum in ${Pt}: expected "${vn}"`);return{prefix:tn,words:Zt}}return{encode:function Me(Pt,Lt,nn=90){if("string"!=typeof Pt)throw new Error("bech32.encode prefix should be string, not "+typeof Pt);if(!Array.isArray(Lt)||Lt.length&&"number"!=typeof Lt[0])throw new Error("bech32.encode words should be array of numbers, not "+typeof Lt);const pn=Pt.length+7+Lt.length;if(!1!==nn&&pn>nn)throw new TypeError(`Length ${pn} exceeds limit ${nn}`);return`${Pt=Pt.toLowerCase()}1${jo.encode(Lt)}${$a(Pt,Lt,E)}`},decode:Pe,decodeToBytes:function wt(Pt){const{prefix:Lt,words:nn}=Pe(Pt,!1);return{prefix:Lt,words:nn,bytes:j(nn)}},decodeUnsafe:et(Pe),fromWords:j,fromWordsUnsafe:le,toWords:X}}const de=da("bech32");function ja(b){if(!Number.isSafeInteger(b)||b<0)throw new Error(`positive integer expected, not ${b}`)}function fc(b){if("boolean"!=typeof b)throw new Error(`boolean expected, not ${b}`)}function cl(b){return b instanceof Uint8Array||null!=b&&"object"==typeof b&&"Uint8Array"===b.constructor.name}function _i(b,...E){if(!cl(b))throw new Error("Uint8Array expected");if(E.length>0&&!E.includes(b.length))throw new Error(`Uint8Array expected of length ${E}, not of length=${b.length}`)}function vs(b,E=!0){if(b.destroyed)throw new Error("Hash instance has been destroyed");if(E&&b.finished)throw new Error("Hash#digest() has already been called")}function Va(b,E){_i(b);const A=E.outputLen;if(b.length{if("string"!=typeof b||b.length%2)throw new TypeError(`hex.decode: expected string, got ${typeof b} with length ${b.length}`);return b.toLowerCase()}));const yi=b=>new Uint32Array(b.buffer,b.byteOffset,Math.floor(b.byteLength/4)),Il=b=>new DataView(b.buffer,b.byteOffset,b.byteLength);if(68!==new Uint8Array(new Uint32Array([287454020]).buffer)[0])throw new Error("Non little-endian hardware is not supported");function hl(b){if("string"==typeof b)b=function El(b){if("string"!=typeof b)throw new Error("string expected, got "+typeof b);return new Uint8Array((new TextEncoder).encode(b))}(b);else{if(!cl(b))throw new Error("Uint8Array expected, got "+typeof b);b=b.slice()}return b}function ha(b,E){if(b.length!==E.length)return!1;let A=0;for(let j=0;j(Object.assign(E,b),E);function Wo(b,E,A,j){if("function"==typeof b.setBigUint64)return b.setBigUint64(E,A,j);const X=BigInt(32),le=BigInt(4294967295),Me=Number(A>>X&le),Pe=Number(A&le),wt=j?0:4;b.setUint32(E+(j?4:0),Me,j),b.setUint32(E+wt,Pe,j)}const Sr=new Uint8Array(16),Oi=yi(Sr),Qi=(b,E,A,j)=>({s3:A<<31|j>>>1,s2:E<<31|A>>>1,s1:b<<31|E>>>1,s0:b>>>1^225<<24&-(1&j)}),so=b=>(b>>>0&255)<<24|(b>>>8&255)<<16|(b>>>16&255)<<8|b>>>24&255;class no{constructor(E,A){this.blockLen=16,this.outputLen=16,this.s0=0,this.s1=0,this.s2=0,this.s3=0,this.finished=!1,_i(E=hl(E),16);const j=Il(E);let X=j.getUint32(0,!1),le=j.getUint32(4,!1),Me=j.getUint32(8,!1),Pe=j.getUint32(12,!1);const Qe=[];for(let tn=0;tn<128;tn++)Qe.push({s0:so(X),s1:so(le),s2:so(Me),s3:so(Pe)}),({s0:X,s1:le,s2:Me,s3:Pe}=Qi(X,le,Me,Pe));const wt=(b=A||1024)>65536?8:b>1024?4:2;var b;if(![1,2,4,8].includes(wt))throw new Error(`ghash: wrong window size=${wt}, should be 2, 4 or 8`);this.W=wt;const Lt=128/wt,nn=this.windowSize=2**wt,pn=[];for(let tn=0;tn>>wt-or-1&1))continue;const{s0:mr,s1:Ar,s2:$r,s3:Ri}=Qe[wt*tn+or];Zt^=mr,vn^=Ar,Sn^=$r,Zn^=Ri}pn.push({s0:Zt,s1:vn,s2:Sn,s3:Zn})}this.t=pn}_updateBlock(E,A,j,X){E^=this.s0,A^=this.s1,j^=this.s2,X^=this.s3;const{W:le,t:Me,windowSize:Pe}=this;let Qe=0,wt=0,Pt=0,Lt=0;const nn=(1<>>8*Yt&255;for(let vn=8/le-1;vn>=0;vn--){const Sn=Zt>>>le*vn&nn,{s0:Zn,s1:or,s2:Lr,s3:mr}=Me[pn*Pe+Sn];Qe^=Zn,wt^=or,Pt^=Lr,Lt^=mr,pn+=1}}this.s0=Qe,this.s1=wt,this.s2=Pt,this.s3=Lt}update(E){E=hl(E),vs(this);const A=yi(E),j=Math.floor(E.length/16),X=E.length%16;for(let le=0;le>>1|A,A=(1&X)<<7}return b[0]^=225&-E,b}((E=hl(E)).slice());super(j,A),j.fill(0)}update(E){E=hl(E),vs(this);const A=yi(E),j=E.length%16,X=Math.floor(E.length/16);for(let le=0;leb(X,j.length).update(hl(j)).digest(),A=b(new Uint8Array(16),0);return E.outputLen=A.outputLen,E.blockLen=A.blockLen,E.create=(j,X)=>b(j,X),E}ri((b,E)=>new no(b,E)),ri((b,E)=>new co(b,E)),new Uint8Array(16);const Vs=283;function uo(b){return b<<1^Vs&-(b>>7)}function Ui(b,E){let A=0;for(;E>0;E>>=1)A^=b&-(1&E),b=uo(b);return A}const U=(()=>{let b=new Uint8Array(256);for(let A=0,j=1;A<256;A++,j^=uo(j))b[A]=j;const E=new Uint8Array(256);E[0]=99;for(let A=0;A<255;A++){let j=b[255-A];j|=j<<8,E[b[A]]=255&(j^j>>4^j>>5^j>>6^j>>7^99)}return E})(),Ie=U.map((b,E)=>U.indexOf(E)),ne=b=>b<<24|b>>>8,ye=b=>b<<8|b>>>24;function Et(b,E){if(256!==b.length)throw new Error("Wrong sbox length");const A=new Uint32Array(256).map((wt,Pt)=>E(b[Pt])),j=A.map(ye),X=j.map(ye),le=X.map(ye),Me=new Uint32Array(65536),Pe=new Uint32Array(65536),Qe=new Uint16Array(65536);for(let wt=0;wt<256;wt++)for(let Pt=0;Pt<256;Pt++){const Lt=256*wt+Pt;Me[Lt]=A[wt]^j[Pt],Pe[Lt]=X[wt]^le[Pt],Qe[Lt]=b[wt]<<8|b[Pt]}return{sbox:b,sbox2:Qe,T0:A,T1:j,T2:X,T3:le,T01:Me,T23:Pe}}const Gt=Et(U,b=>Ui(b,3)<<24|b<<16|b<<8|Ui(b,2)),Un=Et(Ie,b=>Ui(b,11)<<24|Ui(b,13)<<16|Ui(b,9)<<8|Ui(b,14)),tr=(()=>{const b=new Uint8Array(16);for(let E=0,A=1;E<16;E++,A=uo(A))b[E]=A;return b})();function ci(b){_i(b);const E=b.length;if(![16,24,32].includes(E))throw new Error(`aes: wrong key size: should be 16, 24 or 32, got: ${E}`);const{sbox2:A}=Gt,j=yi(b),X=j.length,le=Pe=>Rr(A,Pe,Pe,Pe,Pe),Me=new Uint32Array(E+28);Me.set(j);for(let Pe=X;Pe6&&Pe%X==4&&(Qe=le(Qe)),Me[Pe]=Me[Pe-X]^Qe}return Me}function Di(b,E,A,j,X,le){return b[A<<8&65280|j>>>8&255]^E[X>>>8&65280|le>>>24&255]}function Rr(b,E,A,j,X){return b[255&E|65280&A]|b[j>>>16&255|X>>>16&65280]<<16}function li(b,E,A,j,X){const{sbox2:le,T01:Me,T23:Pe}=Gt;let Qe=0;E^=b[Qe++],A^=b[Qe++],j^=b[Qe++],X^=b[Qe++];const wt=b.length/4-2;for(let tn=0;tn{const Pe=ci(E),{b:Qe,o:wt,out:Pt}=function Ha(b,E,A){let j=b.length;const X=j%16;if(!E&&0!==X)throw new Error("aec/(cbc-ecb): unpadded plaintext with disabled padding");const le=yi(b);if(E){let Qe=16-X;Qe||(Qe=16),j+=Qe}const Me=wi(j,A);return{b:le,o:yi(Me),out:Me}}(le,X,Me),Lt=yi(A);let nn=Lt[0],pn=Lt[1],tn=Lt[2],Yt=Lt[3],Zt=0;for(;Zt+4<=Qe.length;)nn^=Qe[Zt+0],pn^=Qe[Zt+1],tn^=Qe[Zt+2],Yt^=Qe[Zt+3],({s0:nn,s1:pn,s2:tn,s3:Yt}=li(Pe,nn,pn,tn,Yt)),wt[Zt++]=nn,wt[Zt++]=pn,wt[Zt++]=tn,wt[Zt++]=Yt;if(X){const vn=function Ta(b){const E=new Uint8Array(16),A=yi(E);E.set(b);const j=16-b.length;for(let X=16-j;X<16;X++)E[X]=j;return A}(le.subarray(4*Zt));nn^=vn[0],pn^=vn[1],tn^=vn[2],Yt^=vn[3],({s0:nn,s1:pn,s2:tn,s3:Yt}=li(Pe,nn,pn,tn,Yt)),wt[Zt++]=nn,wt[Zt++]=pn,wt[Zt++]=tn,wt[Zt++]=Yt}return Pe.fill(0),Pt},decrypt:(le,Me)=>{!function Yo(b){if(_i(b),b.length%16!=0)throw new Error("aes/(cbc-ecb).decrypt ciphertext should consist of blocks with size 16")}(le);const Pe=function ki(b){const E=ci(b),A=E.slice(),j=E.length,{sbox2:X}=Gt,{T0:le,T1:Me,T2:Pe,T3:Qe}=Un;for(let wt=0;wt>>8&255]^Pe[Lt>>>16&255]^Qe[Lt>>>24]}return A}(E),Qe=yi(A),wt=wi(le.length,Me),Pt=yi(le),Lt=yi(wt);let nn=Qe[0],pn=Qe[1],tn=Qe[2],Yt=Qe[3];for(let Zt=0;Zt+4<=Pt.length;){const vn=nn,Sn=pn,Zn=tn,or=Yt;nn=Pt[Zt+0],pn=Pt[Zt+1],tn=Pt[Zt+2],Yt=Pt[Zt+3];const{s0:Lr,s1:mr,s2:Ar,s3:$r}=ii(Pe,nn,pn,tn,Yt);Lt[Zt++]=Lr^vn,Lt[Zt++]=mr^Sn,Lt[Zt++]=Ar^Zn,Lt[Zt++]=$r^or}return Pe.fill(0),function Ls(b,E){if(!E)return b;const A=b.length;if(!A)throw new Error("aes/pcks5: empty ciphertext not allowed");const j=b[A-1];if(j<=0||j>16)throw new Error(`aes/pcks5: wrong padding byte: ${j}`);const X=b.subarray(0,-j);for(let le=0;le255&b[E++]|(255&b[E++])<<8;class zo{constructor(E){this.blockLen=16,this.outputLen=16,this.buffer=new Uint8Array(16),this.r=new Uint16Array(10),this.h=new Uint16Array(10),this.pad=new Uint16Array(8),this.pos=0,this.finished=!1,_i(E=hl(E),32);const A=yo(E,0),j=yo(E,2),X=yo(E,4),le=yo(E,6),Me=yo(E,8),Pe=yo(E,10),Qe=yo(E,12),wt=yo(E,14);this.r[0]=8191&A,this.r[1]=8191&(A>>>13|j<<3),this.r[2]=7939&(j>>>10|X<<6),this.r[3]=8191&(X>>>7|le<<9),this.r[4]=255&(le>>>4|Me<<12),this.r[5]=Me>>>1&8190,this.r[6]=8191&(Me>>>14|Pe<<2),this.r[7]=8065&(Pe>>>11|Qe<<5),this.r[8]=8191&(Qe>>>8|wt<<8),this.r[9]=wt>>>5&127;for(let Pt=0;Pt<8;Pt++)this.pad[Pt]=yo(E,16+2*Pt)}process(E,A,j=!1){const X=j?0:2048,{h:le,r:Me}=this,Pe=Me[0],Qe=Me[1],wt=Me[2],Pt=Me[3],Lt=Me[4],nn=Me[5],pn=Me[6],tn=Me[7],Yt=Me[8],Zt=Me[9],vn=yo(E,A+0),Sn=yo(E,A+2),Zn=yo(E,A+4),or=yo(E,A+6),Lr=yo(E,A+8),mr=yo(E,A+10),Ar=yo(E,A+12),$r=yo(E,A+14);let Ri=le[0]+(8191&vn),Ei=le[1]+(8191&(vn>>>13|Sn<<3)),ei=le[2]+(8191&(Sn>>>10|Zn<<6)),eo=le[3]+(8191&(Zn>>>7|or<<9)),to=le[4]+(8191&(or>>>4|Lr<<12)),wo=le[5]+(Lr>>>1&8191),rr=le[6]+(8191&(Lr>>>14|mr<<2)),hr=le[7]+(8191&(mr>>>11|Ar<<5)),Yr=le[8]+(8191&(Ar>>>8|$r<<8)),mi=le[9]+($r>>>5|X),yr=0,oi=yr+Ri*Pe+Ei*(5*Zt)+ei*(5*Yt)+eo*(5*tn)+to*(5*pn);yr=oi>>>13,oi&=8191,oi+=wo*(5*nn)+rr*(5*Lt)+hr*(5*Pt)+Yr*(5*wt)+mi*(5*Qe),yr+=oi>>>13,oi&=8191;let Eo=yr+Ri*Qe+Ei*Pe+ei*(5*Zt)+eo*(5*Yt)+to*(5*tn);yr=Eo>>>13,Eo&=8191,Eo+=wo*(5*pn)+rr*(5*nn)+hr*(5*Lt)+Yr*(5*Pt)+mi*(5*wt),yr+=Eo>>>13,Eo&=8191;let Wi=yr+Ri*wt+Ei*Qe+ei*Pe+eo*(5*Zt)+to*(5*Yt);yr=Wi>>>13,Wi&=8191,Wi+=wo*(5*tn)+rr*(5*pn)+hr*(5*nn)+Yr*(5*Lt)+mi*(5*Pt),yr+=Wi>>>13,Wi&=8191;let Bs=yr+Ri*Pt+Ei*wt+ei*Qe+eo*Pe+to*(5*Zt);yr=Bs>>>13,Bs&=8191,Bs+=wo*(5*Yt)+rr*(5*tn)+hr*(5*pn)+Yr*(5*nn)+mi*(5*Lt),yr+=Bs>>>13,Bs&=8191;let Na=yr+Ri*Lt+Ei*Pt+ei*wt+eo*Qe+to*Pe;yr=Na>>>13,Na&=8191,Na+=wo*(5*Zt)+rr*(5*Yt)+hr*(5*tn)+Yr*(5*pn)+mi*(5*nn),yr+=Na>>>13,Na&=8191;let rl=yr+Ri*nn+Ei*Lt+ei*Pt+eo*wt+to*Qe;yr=rl>>>13,rl&=8191,rl+=wo*Pe+rr*(5*Zt)+hr*(5*Yt)+Yr*(5*tn)+mi*(5*pn),yr+=rl>>>13,rl&=8191;let gl=yr+Ri*pn+Ei*nn+ei*Lt+eo*Pt+to*wt;yr=gl>>>13,gl&=8191,gl+=wo*Qe+rr*Pe+hr*(5*Zt)+Yr*(5*Yt)+mi*(5*tn),yr+=gl>>>13,gl&=8191;let ba=yr+Ri*tn+Ei*pn+ei*nn+eo*Lt+to*Pt;yr=ba>>>13,ba&=8191,ba+=wo*wt+rr*Qe+hr*Pe+Yr*(5*Zt)+mi*(5*Yt),yr+=ba>>>13,ba&=8191;let Xa=yr+Ri*Yt+Ei*tn+ei*pn+eo*nn+to*Lt;yr=Xa>>>13,Xa&=8191,Xa+=wo*Pt+rr*wt+hr*Qe+Yr*Pe+mi*(5*Zt),yr+=Xa>>>13,Xa&=8191;let wa=yr+Ri*Zt+Ei*Yt+ei*tn+eo*pn+to*nn;yr=wa>>>13,wa&=8191,wa+=wo*Lt+rr*Pt+hr*wt+Yr*Qe+mi*Pe,yr+=wa>>>13,wa&=8191,yr=(yr<<2)+yr|0,yr=yr+oi|0,oi=8191&yr,yr>>>=13,Eo+=yr,le[0]=oi,le[1]=Eo,le[2]=Wi,le[3]=Bs,le[4]=Na,le[5]=rl,le[6]=gl,le[7]=ba,le[8]=Xa,le[9]=wa}finalize(){const{h:E,pad:A}=this,j=new Uint16Array(10);let X=E[1]>>>13;E[1]&=8191;for(let Pe=2;Pe<10;Pe++)E[Pe]+=X,X=E[Pe]>>>13,E[Pe]&=8191;E[0]+=5*X,X=E[0]>>>13,E[0]&=8191,E[1]+=X,X=E[1]>>>13,E[1]&=8191,E[2]+=X,j[0]=E[0]+5,X=j[0]>>>13,j[0]&=8191;for(let Pe=1;Pe<10;Pe++)j[Pe]=E[Pe]+X,X=j[Pe]>>>13,j[Pe]&=8191;j[9]-=8192;let le=(1^X)-1;for(let Pe=0;Pe<10;Pe++)j[Pe]&=le;le=~le;for(let Pe=0;Pe<10;Pe++)E[Pe]=E[Pe]&le|j[Pe];E[0]=65535&(E[0]|E[1]<<13),E[1]=65535&(E[1]>>>3|E[2]<<10),E[2]=65535&(E[2]>>>6|E[3]<<7),E[3]=65535&(E[3]>>>9|E[4]<<4),E[4]=65535&(E[4]>>>12|E[5]<<1|E[6]<<14),E[5]=65535&(E[6]>>>2|E[7]<<11),E[6]=65535&(E[7]>>>5|E[8]<<8),E[7]=65535&(E[8]>>>8|E[9]<<5);let Me=E[0]+A[0];E[0]=65535&Me;for(let Pe=1;Pe<8;Pe++)Me=(E[Pe]+A[Pe]|0)+(Me>>>16)|0,E[Pe]=65535&Me}update(E){vs(this);const{buffer:A,blockLen:j}=this,X=(E=hl(E)).length;for(let le=0;le>>0,E[le++]=j[Me]>>>8;return E}digest(){const{buffer:E,outputLen:A}=this;this.digestInto(E);const j=E.slice(0,A);return this.destroy(),j}}const au=function xl(b){const E=(j,X)=>b(X).update(hl(j)).digest(),A=b(new Uint8Array(32));return E.outputLen=A.outputLen,E.blockLen=A.blockLen,E.create=j=>b(j),E}(b=>new zo(b)),mc=b=>Uint8Array.from(b.split("").map(E=>E.charCodeAt(0))),lu=mc("expand 16-byte k"),Bu=mc("expand 32-byte k"),ah=yi(lu),Uu=yi(Bu);function Ur(b,E){return b<>>32-E}function kc(b){return b.byteOffset%4==0}Uu.slice();const Wa=2**32-1,Fr=new Uint32Array;function Xl(b,E){const{allowShortKeys:A,extendNonceFn:j,counterLength:X,counterRight:le,rounds:Me}=function Hl(b,E){if(null==E||"object"!=typeof E)throw new Error("options must be defined");return Object.assign(b,E)}({allowShortKeys:!1,counterLength:8,counterRight:!1,rounds:20},E);if("function"!=typeof b)throw new Error("core must be a function");return ja(X),ja(Me),fc(le),fc(A),(Pe,Qe,wt,Pt,Lt=0)=>{_i(Pe),_i(Qe),_i(wt);const nn=wt.length;if(Pt||(Pt=new Uint8Array(nn)),_i(Pt),ja(Lt),Lt<0||Lt>=Wa)throw new Error("arx: counter overflow");if(Pt.length=Wa)throw new Error("arx: counter overflow");const Yt=Math.min(64,Qe-tn);if(Lt&&64===Yt){const Zt=tn/4;if(tn%4!=0)throw new Error("arx: invalid block position");for(let Sn,vn=0;vn<16;vn++)Sn=Zt+vn,pn[Sn]=nn[Sn]^Pt[vn];tn+=64}else{for(let vn,Zt=0;Zt0;)pn.pop().fill(0);return Pt}}function pl(b,E,A,j,X,le=20){let Me=b[0],Pe=b[1],Qe=b[2],wt=b[3],Pt=E[0],Lt=E[1],nn=E[2],pn=E[3],tn=E[4],Yt=E[5],Zt=E[6],vn=E[7],Sn=X,Zn=A[0],or=A[1],Lr=A[2],mr=Me,Ar=Pe,$r=Qe,Ri=wt,Ei=Pt,ei=Lt,eo=nn,to=pn,wo=tn,rr=Yt,hr=Zt,Yr=vn,mi=Sn,yr=Zn,oi=or,Eo=Lr;for(let Bs=0;Bs{b.update(E);const A=E.length%16;A&&b.update(qi.subarray(A))},gc=new Uint8Array(32);function rs(b,E,A,j,X){const le=b(E,A,gc),Me=au.create(le);X&&Dr(Me,X),Dr(Me,j);const Pe=new Uint8Array(16),Qe=Il(Pe);Wo(Qe,0,BigInt(X?X.length:0),!0),Wo(Qe,8,BigInt(j.length),!0),Me.update(Pe);const wt=Me.digest();return le.fill(0),wt}const R=b=>(E,A,j)=>(_i(E,32),_i(A),{encrypt:(le,Me)=>{const Pe=le.length,Qe=Pe+16;Me?_i(Me,Qe):Me=new Uint8Array(Qe),b(E,A,le,Me,1);const wt=rs(b,E,A,Me.subarray(0,-16),j);return Me.set(wt,Pe),Me},decrypt:(le,Me)=>{const Pe=le.length,Qe=Pe-16;if(Pe<16)throw new Error("encrypted data must be at least 16 bytes");Me?_i(Me,Qe):Me=new Uint8Array(Qe);const wt=le.subarray(0,-16);if(!ha(le.subarray(-16),rs(b,E,A,wt,j)))throw new Error("invalid tag");return b(E,A,wt,Me,1),Me}});R(Yl),R(za);class K extends Xr.Vw{constructor(E,A){super(),this.finished=!1,this.destroyed=!1,Ao.hash(E);const j=(0,Xr.ZJ)(A);if(this.iHash=E.create(),"function"!=typeof this.iHash.update)throw new Error("Expected instance of class which extends utils.Hash");this.blockLen=this.iHash.blockLen,this.outputLen=this.iHash.outputLen;const X=this.blockLen,le=new Uint8Array(X);le.set(j.length>X?E.create().update(j).digest():j);for(let Me=0;Menew K(b,E).update(A).digest();_e.create=(b,E)=>new K(b,E);const At=new Uint8Array([0]),fn=new Uint8Array;var ui=Object.defineProperty,kr=(b,E)=>{for(var A in E)ui(b,A,{get:E[A],enumerable:!0})},Gi=Symbol("verified"),Is=b=>b instanceof Object;function is(b){if(!Is(b)||"number"!=typeof b.kind||"string"!=typeof b.content||"number"!=typeof b.created_at||"string"!=typeof b.pubkey||!b.pubkey.match(/^[a-f0-9]{64}$/)||!Array.isArray(b.tags))return!1;for(let E=0;Edh,QueueNode:()=>uh,binarySearch:()=>_d,insertEventIntoAscendingList:()=>Jp,insertEventIntoDescendingList:()=>$u,normalizeURL:()=>Ka,utf8Decoder:()=>Wr,utf8Encoder:()=>Ys});var Wr=new TextDecoder("utf-8"),Ys=new TextEncoder;function Ka(b){-1===b.indexOf("://")&&(b="wss://"+b);let E=new URL(b);return E.pathname=E.pathname.replace(/\/+/g,"/"),E.pathname.endsWith("/")&&(E.pathname=E.pathname.slice(0,-1)),("80"===E.port&&"ws:"===E.protocol||"443"===E.port&&"wss:"===E.protocol)&&(E.port=""),E.searchParams.sort(),E.hash="",E.toString()}function $u(b,E){const[A,j]=_d(b,X=>E.id===X.id?0:E.created_at===X.created_at?-1:X.created_at-E.created_at);return j||b.splice(A,0,E),b}function Jp(b,E){const[A,j]=_d(b,X=>E.id===X.id?0:E.created_at===X.created_at?-1:E.created_at-X.created_at);return j||b.splice(A,0,E),b}function _d(b,E){let A=0,j=b.length-1;for(;A<=j;){const X=Math.floor((A+j)/2),le=E(b[X]);if(0===le)return[X,!0];le<0?j=X-1:A=X+1}return[A,!1]}var uh=class{value;next=null;prev=null;constructor(b){this.value=b}},dh=class{first;last;constructor(){this.first=null,this.last=null}enqueue(b){const E=new uh(b);return this.last?this.last===this.first?(this.last=E,this.last.prev=this.first,this.first.next=E):(E.prev=this.last,this.last.next=E,this.last=E):(this.first=E,this.last=E),!0}dequeue(){if(!this.first)return null;if(this.first===this.last){const E=this.first;return this.first=null,this.last=null,E.value}const b=this.first;return this.first=b.next,b.value}};function Ql(b){let E=Ss(Ys.encode(function _c(b){if(!is(b))throw new Error("can't serialize event with wrong or missing properties");return JSON.stringify([0,b.pubkey,b.created_at,b.kind,b.tags,b.content])}(b)));return(0,Xr.My)(E)}var Zl=new class{generateSecretKey(){return No.utils.randomPrivateKey()}getPublicKey(b){return(0,Xr.My)(No.getPublicKey(b))}finalizeEvent(b,E){const A=b;return A.pubkey=(0,Xr.My)(No.getPublicKey(E)),A.id=Ql(A),A.sig=(0,Xr.My)(No.sign(Ql(A),E)),A[Gi]=!0,A}verifyEvent(b){if("boolean"==typeof b[Gi])return b[Gi];const E=Ql(b);if(E!==b.id)return b[Gi]=!1,!1;try{const A=No.verify(b.sig,E,b.pubkey);return b[Gi]=A,A}catch{return b[Gi]=!1,!1}}},uu=Zl.generateSecretKey,du=Zl.getPublicKey,Ja=Zl.finalizeEvent,En=Zl.verifyEvent;function Ic(b){return 1e3<=b&&b<1e4||[1,2,4,5,6,7,8,16,40,41,42,43,44].includes(b)}function hu(b){return[0,3].includes(b)||1e4<=b&&b<2e4}function Si(b){return 2e4<=b&&b<3e4}function Nl(b){return 3e4<=b&&b<4e4}function Ra(b){return Ic(b)?"regular":hu(b)?"replaceable":Si(b)?"ephemeral":Nl(b)?"parameterized":"unknown"}function Qs(b,E){const A=E instanceof Array?E:[E];return is(b)&&A.includes(b.kind)||!1}kr({},{Application:()=>wc,BadgeAward:()=>Zs,BadgeDefinition:()=>mh,BlockedRelaysList:()=>bo,BookmarkList:()=>ro,Bookmarksets:()=>yc,Calendar:()=>Ll,CalendarEventRSVP:()=>xf,ChannelCreation:()=>P,ChannelHideMessage:()=>Ae,ChannelMessage:()=>oe,ChannelMetadata:()=>$,ChannelMuteUser:()=>je,ClassifiedListing:()=>tm,ClientAuth:()=>gs,CommunitiesList:()=>Ji,CommunityDefinition:()=>rm,CommunityPostApproval:()=>nr,Contacts:()=>em,CreateOrUpdateProduct:()=>bc,CreateOrUpdateStall:()=>ml,Curationsets:()=>tc,Date:()=>nm,DirectMessageRelaysList:()=>jr,DraftClassifiedListing:()=>Wu,DraftLong:()=>ju,Emojisets:()=>Vu,EncryptedDirectMessage:()=>fh,EventDeletion:()=>ph,FileMetadata:()=>zt,FileServerPreference:()=>Hi,Followsets:()=>Jl,GenericRepost:()=>I,Genericlists:()=>vc,GiftWrap:()=>It,HTTPAuth:()=>Dl,Handlerinformation:()=>zu,Handlerrecommendation:()=>bd,Highlights:()=>ir,InterestsList:()=>ga,Interestsets:()=>Js,JobFeedback:()=>Xn,JobRequest:()=>Mn,JobResult:()=>Hn,Label:()=>zn,LightningPubRPC:()=>Mo,LiveChatMessage:()=>ln,LiveEvent:()=>gh,LongFormArticle:()=>nc,Metadata:()=>Oc,Mutelist:()=>Cr,NWCWalletInfo:()=>Yi,NWCWalletRequest:()=>qs,NWCWalletResponse:()=>Ps,NostrConnect:()=>el,OpenTimestamps:()=>pt,Pinlist:()=>Gr,PrivateDirectMessage:()=>yd,ProblemTracker:()=>An,ProfileBadges:()=>Rc,PublicChatsList:()=>Xi,Reaction:()=>ql,RecommendRelay:()=>vd,RelayList:()=>Br,Relaysets:()=>ec,Report:()=>Qt,Reporting:()=>Gn,Repost:()=>ma,Seal:()=>Cl,SearchRelaysList:()=>To,ShortTextNote:()=>pa,Time:()=>_h,UserEmojiList:()=>_r,UserStatuses:()=>Hu,Zap:()=>Ir,ZapGoal:()=>vr,ZapRequest:()=>$n,classifyKind:()=>Ra,isEphemeralKind:()=>Si,isKind:()=>Qs,isParameterizedReplaceableKind:()=>Nl,isRegularKind:()=>Ic,isReplaceableKind:()=>hu});var Oc=0,pa=1,vd=2,em=3,fh=4,ph=5,ma=6,ql=7,Zs=8,Cl=13,yd=14,I=16,P=40,$=41,oe=42,Ae=43,je=44,pt=1040,It=1059,zt=1063,ln=1311,An=1971,Qt=1984,Gn=1984,zn=1985,nr=4550,Mn=5999,Hn=6999,Xn=7e3,vr=9041,$n=9734,Ir=9735,ir=9802,Cr=1e4,Gr=10001,Br=10002,ro=10003,Ji=10004,Xi=10005,bo=10006,To=10007,ga=10015,_r=10030,jr=10050,Hi=10096,Yi=13194,Mo=21e3,gs=22242,qs=23194,Ps=23195,el=24133,Dl=27235,Jl=3e4,vc=30001,ec=30002,yc=30003,tc=30004,Rc=30008,mh=30009,Js=30015,ml=30017,bc=30018,nc=30023,ju=30024,Vu=30030,wc=30078,gh=30311,Hu=30315,tm=30402,Wu=30403,nm=31922,_h=31923,Ll=31924,xf=31925,bd=31989,zu=31990,rm=34550;function Pl(b,E){if(b.ids&&-1===b.ids.indexOf(E.id)||b.kinds&&-1===b.kinds.indexOf(E.kind)||b.authors&&-1===b.authors.indexOf(E.pubkey))return!1;for(let A in b)if("#"===A[0]){let X=b[`#${A.slice(1)}`];if(X&&!E.tags.find(([le,Me])=>le===A.slice(1)&&-1!==X.indexOf(Me)))return!1}return!(b.since&&E.created_atb.until)}function Nc(b,E){let A=E.length+3,j=b.indexOf(`"${E}":`)+A,X=b.slice(j).indexOf('"')+j+1;return b.slice(X,X+64)}function Lc(b,E){let A=E.length,j=b.indexOf(`"${E}":`)+A+3,X=b.slice(j),le=Math.min(X.indexOf(","),X.indexOf("}"));return parseInt(X.slice(0,le),10)}function Ed(b){let E=b.slice(0,22).indexOf('"EVENT"');if(-1===E)return null;let A=b.slice(E+7+1).indexOf('"');if(-1===A)return null;let j=E+7+1+A,X=b.slice(j+1,80).indexOf('"');return-1===X?null:b.slice(j+1,j+1+X)}function Ku(b,E){return E===Nc(b,"id")}function Df(b,E){return E===Nc(b,"pubkey")}function yh(b,E){return E===Lc(b,"kind")}function bh(b,E){return{kind:gs,created_at:Math.floor(Date.now()/1e3),tags:[["relay",b],["challenge",E]],content:""}}function fu(){return Fl.apply(this,arguments)}function Fl(){return(Fl=(0,a.A)(function*(){return new Promise(b=>{const E=new MessageChannel,A=()=>{E.port1.removeEventListener("message",A),b()};E.port1.addEventListener("message",A),E.port2.postMessage(0),E.port1.start()})})).apply(this,arguments)}kr({},{getHex64:()=>Nc,getInt:()=>Lc,getSubscriptionId:()=>Ed,matchEventId:()=>Ku,matchEventKind:()=>yh,matchEventPubkey:()=>Df}),kr({},{makeAuthEvent:()=>bh});var Pg=b=>(b[Gi]=!0,!0),xd=class{url;_connected=!1;onclose=null;onnotice=b=>console.debug(`NOTICE from ${this.url}: ${b}`);_onauth=null;baseEoseTimeout=4400;connectionTimeout=4400;publishTimeout=4400;openSubs=new Map;connectionTimeoutHandle;connectionPromise;openCountRequests=new Map;openEventPublishes=new Map;ws;incomingMessageQueue=new dh;queueRunning=!1;challenge;serial=0;verifyEvent;_WebSocket;constructor(b,E){this.url=Ka(b),this.verifyEvent=E.verifyEvent,this._WebSocket=E.websocketImplementation||WebSocket}static connect(b,E){return(0,a.A)(function*(){const A=new xd(b,E);return yield A.connect(),A})()}closeAllSubscriptions(b){for(let[E,A]of this.openSubs)A.close(b);this.openSubs.clear();for(let[E,A]of this.openEventPublishes)A.reject(new Error(b));this.openEventPublishes.clear();for(let[E,A]of this.openCountRequests)A.reject(new Error(b));this.openCountRequests.clear()}get connected(){return this._connected}connect(){var b=this;return(0,a.A)(function*(){return b.connectionPromise||(b.challenge=void 0,b.connectionPromise=new Promise((E,A)=>{b.connectionTimeoutHandle=setTimeout(()=>{A("connection timed out"),b.connectionPromise=void 0,b.onclose?.(),b.closeAllSubscriptions("relay connection timed out")},b.connectionTimeout);try{b.ws=new b._WebSocket(b.url)}catch(j){return void A(j)}b.ws.onopen=()=>{clearTimeout(b.connectionTimeoutHandle),b._connected=!0,E()},b.ws.onerror=j=>{A(j.message||"websocket error"),b._connected&&(b._connected=!1,b.connectionPromise=void 0,b.onclose?.(),b.closeAllSubscriptions("relay connection errored"))},b.ws.onclose=(0,a.A)(function*(){b._connected&&(b._connected=!1,b.connectionPromise=void 0,b.onclose?.(),b.closeAllSubscriptions("relay connection closed"))}),b.ws.onmessage=b._onmessage.bind(b)})),b.connectionPromise})()}runQueue(){var b=this;return(0,a.A)(function*(){for(b.queueRunning=!0;!1!==b.handleNext();)yield fu();b.queueRunning=!1})()}handleNext(){const b=this.incomingMessageQueue.dequeue();if(!b)return!1;const E=Ed(b);if(E){const A=this.openSubs.get(E);if(!A)return;const j=Nc(b,"id"),X=A.alreadyHaveEvent?.(j);if(A.receivedEvent?.(this,j),X)return}try{let A=JSON.parse(b);switch(A[0]){case"EVENT":{const j=this.openSubs.get(A[1]),X=A[2];return void(this.verifyEvent(X)&&function im(b,E){for(let A=0;A{E.ws?.send(b)})})()}auth(b){var E=this;return(0,a.A)(function*(){if(!E.challenge)throw new Error("can't perform auth, no challenge was received");const A=yield b(bh(E.url,E.challenge)),j=new Promise((X,le)=>{E.openEventPublishes.set(A.id,{resolve:X,reject:le})});return E.send('["AUTH",'+JSON.stringify(A)+"]"),j})()}publish(b){var E=this;return(0,a.A)(function*(){const A=new Promise((j,X)=>{E.openEventPublishes.set(b.id,{resolve:j,reject:X})});return E.send('["EVENT",'+JSON.stringify(b)+"]"),setTimeout(()=>{const j=E.openEventPublishes.get(b.id);j&&(j.reject(new Error("publish timed out")),E.openEventPublishes.delete(b.id))},E.publishTimeout),A})()}count(b,E){var A=this;return(0,a.A)(function*(){A.serial++;const j=E?.id||"count:"+A.serial,X=new Promise((le,Me)=>{A.openCountRequests.set(j,{resolve:le,reject:Me})});return A.send('["COUNT","'+j+'",'+JSON.stringify(b).substring(1)),X})()}subscribe(b,E){const A=this.prepareSubscription(b,E);return A.fire(),A}prepareSubscription(b,E){this.serial++;const A=E.id||"sub:"+this.serial,j=new wh(this,A,b,E);return this.openSubs.set(A,j),j}close(){this.closeAllSubscriptions("relay connection closed by us"),this._connected=!1,this.ws?.close()}_onmessage(b){this.incomingMessageQueue.enqueue(b.data),this.queueRunning||this.runQueue()}},wh=class{relay;id;closed=!1;eosed=!1;filters;alreadyHaveEvent;receivedEvent;onevent;oneose;onclose;eoseTimeout;eoseTimeoutHandle;constructor(b,E,A,j){this.relay=b,this.filters=A,this.id=E,this.alreadyHaveEvent=j.alreadyHaveEvent,this.receivedEvent=j.receivedEvent,this.eoseTimeout=j.eoseTimeout||b.baseEoseTimeout,this.oneose=j.oneose,this.onclose=j.onclose,this.onevent=j.onevent||(X=>{console.warn(`onevent() callback not defined for subscription '${this.id}' in relay ${this.relay.url}. event received:`,X)})}fire(){this.relay.send('["REQ","'+this.id+'",'+JSON.stringify(this.filters).substring(1)),this.eoseTimeoutHandle=setTimeout(this.receivedEose.bind(this),this.eoseTimeout)}receivedEose(){this.eosed||(clearTimeout(this.eoseTimeoutHandle),this.eosed=!0,this.oneose?.())}close(b="closed by caller"){!this.closed&&this.relay.connected&&(this.relay.send('["CLOSE",'+JSON.stringify(this.id)+"]"),this.closed=!0),this.relay.openSubs.delete(this.id),this.onclose?.(b)}};try{WebSocket}catch{}var Sf,Fs=class{relays=new Map;seenOn=new Map;trackRelays=!1;verifyEvent;trustedRelayURLs=new Set;_WebSocket;constructor(b){this.verifyEvent=b.verifyEvent,this._WebSocket=b.websocketImplementation}ensureRelay(b,E){var A=this;return(0,a.A)(function*(){b=Ka(b);let j=A.relays.get(b);return j||(j=new xd(b,{verifyEvent:A.trustedRelayURLs.has(b)?Pg:A.verifyEvent,websocketImplementation:A._WebSocket}),E?.connectionTimeout&&(j.connectionTimeout=E.connectionTimeout),A.relays.set(b,j)),yield j.connect(),j})()}close(b){b.map(Ka).forEach(E=>{this.relays.get(E)?.close()})}subscribeMany(b,E,A){return this.subscribeManyMap(Object.fromEntries(b.map(j=>[j,E])),A)}subscribeManyMap(b,E){var A=this;this.trackRelays&&(E.receivedEvent=(nn,pn)=>{let tn=this.seenOn.get(pn);tn||(tn=new Set,this.seenOn.set(pn,tn)),tn.add(nn)});const j=new Set,X=[],le=Object.keys(b).length,Me=[];let Pe=nn=>{Me[nn]=!0,Me.filter(pn=>pn).length===le&&(E.oneose?.(),Pe=()=>{})};const Qe=[];let wt=(nn,pn)=>{Pe(nn),Qe[nn]=pn,Qe.filter(tn=>tn).length===le&&(E.onclose?.(Qe),wt=()=>{})};const Pt=nn=>{if(E.alreadyHaveEvent?.(nn))return!0;const pn=j.has(nn);return j.add(nn),pn},Lt=Promise.all(Object.entries(b).map(function(){var nn=(0,a.A)(function*(pn,tn,Yt){if(Yt.indexOf(pn)!==tn)return void wt(tn,"duplicate url");let Sn,[Zt,vn]=pn;Zt=Ka(Zt);try{Sn=yield A.ensureRelay(Zt,{connectionTimeout:E.maxWait?Math.max(.8*E.maxWait,E.maxWait-1e3):void 0})}catch(or){return void wt(tn,or?.message||String(or))}let Zn=Sn.subscribe(vn,{...E,oneose:()=>Pe(tn),onclose:or=>wt(tn,or),alreadyHaveEvent:Pt,eoseTimeout:E.maxWait});X.push(Zn)});return function(pn,tn,Yt){return nn.apply(this,arguments)}}()));return{close:()=>(0,a.A)(function*(){yield Lt,X.forEach(nn=>{nn.close()})})()}}subscribeManyEose(b,E,A){const j=this.subscribeMany(b,E,{...A,oneose(){j.close()}});return j}querySync(b,E,A){var j=this;return(0,a.A)(function*(){return new Promise(function(){var X=(0,a.A)(function*(le){const Me=[];j.subscribeManyEose(b,[E],{...A,onevent(Pe){Me.push(Pe)},onclose(Pe){le(Me)}})});return function(le){return X.apply(this,arguments)}}())})()}get(b,E,A){var j=this;return(0,a.A)(function*(){E.limit=1;const X=yield j.querySync(b,E,A);return X.sort((le,Me)=>Me.created_at-le.created_at),X[0]||null})()}publish(b,E){var A=this;return b.map(Ka).map(function(){var j=(0,a.A)(function*(X,le,Me){if(Me.indexOf(X)!==le)return Promise.reject("duplicate url");let Pe=yield A.ensureRelay(X);return Pe.publish(E).then(Qe=>{if(A.trackRelays){let wt=A.seenOn.get(E.id);wt||(wt=new Set,A.seenOn.set(E.id,wt)),wt.add(Pe)}return Qe})});return function(X,le,Me){return j.apply(this,arguments)}}())}listConnectionStatus(){const b=new Map;return this.relays.forEach((E,A)=>b.set(A,E.connected)),b}destroy(){this.relays.forEach(b=>b.close()),this.relays=new Map}};try{Sf=WebSocket}catch{}var Eh=class extends Fs{constructor(){super({verifyEvent:En,websocketImplementation:Sf})}},Cd={};kr(Cd,{BECH32_REGEX:()=>Xu,Bech32MaxSize:()=>Gu,NostrTypeGuard:()=>om,decode:()=>mu,encodeBytes:()=>Ga,naddrEncode:()=>Td,neventEncode:()=>Qu,noteEncode:()=>Mf,nprofileEncode:()=>Sd,npubEncode:()=>Tf,nsecEncode:()=>Dd});var om={isNProfile:b=>/^nprofile1[a-z\d]+$/.test(b||""),isNEvent:b=>/^nevent1[a-z\d]+$/.test(b||""),isNAddr:b=>/^naddr1[a-z\d]+$/.test(b||""),isNSec:b=>/^nsec1[a-z\d]{58}$/.test(b||""),isNPub:b=>/^npub1[a-z\d]{58}$/.test(b||""),isNote:b=>/^note1[a-z\d]+$/.test(b||""),isNcryptsec:b=>/^ncryptsec1[a-z\d]+$/.test(b||"")},Gu=5e3,Xu=/[\x21-\x7E]{1,83}1[023456789acdefghjklmnpqrstuvwxyz]{6,}/;function mu(b){let{prefix:E,words:A}=de.decode(b,Gu),j=new Uint8Array(de.fromWords(A));switch(E){case"nprofile":{let X=Yu(j);if(!X[0]?.[0])throw new Error("missing TLV 0 for nprofile");if(32!==X[0][0].length)throw new Error("TLV 0 should be 32 bytes");return{type:"nprofile",data:{pubkey:(0,Xr.My)(X[0][0]),relays:X[1]?X[1].map(le=>Wr.decode(le)):[]}}}case"nevent":{let X=Yu(j);if(!X[0]?.[0])throw new Error("missing TLV 0 for nevent");if(32!==X[0][0].length)throw new Error("TLV 0 should be 32 bytes");if(X[2]&&32!==X[2][0].length)throw new Error("TLV 2 should be 32 bytes");if(X[3]&&4!==X[3][0].length)throw new Error("TLV 3 should be 4 bytes");return{type:"nevent",data:{id:(0,Xr.My)(X[0][0]),relays:X[1]?X[1].map(le=>Wr.decode(le)):[],author:X[2]?.[0]?(0,Xr.My)(X[2][0]):void 0,kind:X[3]?.[0]?parseInt((0,Xr.My)(X[3][0]),16):void 0}}}case"naddr":{let X=Yu(j);if(!X[0]?.[0])throw new Error("missing TLV 0 for naddr");if(!X[2]?.[0])throw new Error("missing TLV 2 for naddr");if(32!==X[2][0].length)throw new Error("TLV 2 should be 32 bytes");if(!X[3]?.[0])throw new Error("missing TLV 3 for naddr");if(4!==X[3][0].length)throw new Error("TLV 3 should be 4 bytes");return{type:"naddr",data:{identifier:Wr.decode(X[0][0]),pubkey:(0,Xr.My)(X[2][0]),kind:parseInt((0,Xr.My)(X[3][0]),16),relays:X[1]?X[1].map(le=>Wr.decode(le)):[]}}}case"nsec":return{type:E,data:j};case"npub":case"note":return{type:E,data:(0,Xr.My)(j)};default:throw new Error(`unknown prefix ${E}`)}}function Yu(b){let E={},A=b;for(;A.length>0;){let j=A[0],X=A[1],le=A.slice(2,2+X);if(A=A.slice(2+X),le.lengthYs.encode(A))}))}function Qu(b){let E;return void 0!==b.kind&&(E=function xh(b){const E=new Uint8Array(4);return E[0]=b>>24&255,E[1]=b>>16&255,E[2]=b>>8&255,E[3]=255&b,E}(b.kind)),Ad("nevent",Ch({0:[(0,Xr.aT)(b.id)],1:(b.relays||[]).map(j=>Ys.encode(j)),2:b.author?[(0,Xr.aT)(b.author)]:[],3:E?[new Uint8Array(E)]:[]}))}function Td(b){let E=new ArrayBuffer(4);return new DataView(E).setUint32(0,b.kind,!1),Ad("naddr",Ch({0:[Ys.encode(b.identifier)],1:(b.relays||[]).map(j=>Ys.encode(j)),2:[(0,Xr.aT)(b.pubkey)],3:[new Uint8Array(E)]}))}function Ch(b){let E=[];return Object.entries(b).reverse().forEach(([A,j])=>{j.forEach(X=>{let le=new Uint8Array(X.length+2);le.set([parseInt(A)],0),le.set([X.length],1),le.set(X,2),E.push(le)})}),(0,Xr.Id)(...E)}var Dh={};function Ah(b,E,A){return Qo.apply(this,arguments)}function Qo(){return(Qo=(0,a.A)(function*(b,E,A){const j=b instanceof Uint8Array?(0,Xr.My)(b):b,le=kf(wr.getSharedSecret(j,"02"+E));let Me=Uint8Array.from((0,Xr.po)(16)),Pe=Ys.encode(A),Qe=qa(le,Me).encrypt(Pe);return`${Qn.encode(new Uint8Array(Qe))}?iv=${Qn.encode(new Uint8Array(Me.buffer))}`})).apply(this,arguments)}function lm(b,E,A){return Md.apply(this,arguments)}function Md(){return(Md=(0,a.A)(function*(b,E,A){const j=b instanceof Uint8Array?(0,Xr.My)(b):b;let[X,le]=A.split("?iv="),Pe=kf(wr.getSharedSecret(j,"02"+E)),Qe=Qn.decode(le),wt=Qn.decode(X),Pt=qa(Pe,Qe).decrypt(wt);return Wr.decode(Pt)})).apply(this,arguments)}function kf(b){return b.slice(1,33)}kr(Dh,{decrypt:()=>lm,encrypt:()=>Ah}),kr({},{NIP05_REGEX:()=>ws,isNip05:()=>Fc,isValid:()=>Ec,queryProfile:()=>Od,searchDomain:()=>gu,useFetchImplementation:()=>rc});var kd,ws=/^(?:([\w.+-]+)@)?([\w_-]+(\.[\w_-]+)+)$/,Fc=b=>ws.test(b||"");try{kd=fetch}catch{}function rc(b){kd=b}function gu(b){return If.apply(this,arguments)}function If(){return(If=(0,a.A)(function*(b,E=""){try{const A=`https://${b}/.well-known/nostr.json?name=${E}`,j=yield kd(A,{redirect:"manual"});if(200!==j.status)throw Error("Wrong response code");return(yield j.json()).names}catch{return{}}})).apply(this,arguments)}function Od(b){return ic.apply(this,arguments)}function ic(){return(ic=(0,a.A)(function*(b){const E=b.match(ws);if(!E)return null;const[,A="_",j]=E;try{const X=`https://${j}/.well-known/nostr.json?name=${A}`,le=yield kd(X,{redirect:"manual"});if(200!==le.status)throw Error("Wrong response code");const Me=yield le.json(),Pe=Me.names[A];return Pe?{pubkey:Pe,relays:Me.relays?.[Pe]}:null}catch{return null}})).apply(this,arguments)}function Ec(b,E){return Th.apply(this,arguments)}function Th(){return(Th=(0,a.A)(function*(b,E){const A=yield Od(E);return!!A&&A.pubkey===b})).apply(this,arguments)}function oc(b){const E={reply:void 0,root:void 0,mentions:[],profiles:[],quotes:[]};let A,j;for(let X=b.tags.length-1;X>=0;X--){const le=b.tags[X];if("e"===le[0]&&le[1]){const[Me,Pe,Qe,wt,Pt]=le,Lt={id:Pe,relays:Qe?[Qe]:[],author:Pt};if("root"===wt){E.root=Lt;continue}if("reply"===wt){E.reply=Lt;continue}if("mention"===wt){E.mentions.push(Lt);continue}A?j=Lt:A=Lt,E.mentions.push(Lt)}else{if("q"===le[0]&&le[1]){const[Me,Pe,Qe]=le;E.quotes.push({id:Pe,relays:Qe?[Qe]:[]})}"p"===le[0]&&le[1]&&E.profiles.push({pubkey:le[1],relays:le[2]?[le[2]]:[]})}}return E.root||(E.root=j||A||E.reply),E.reply||(E.reply=A||E.root),[E.reply,E.root].forEach(X=>{if(!X)return;let le=E.mentions.indexOf(X);if(-1!==le&&E.mentions.splice(le,1),X.author){let Me=E.profiles.find(Pe=>Pe.pubkey===X.author);Me&&Me.relays&&(X.relays||(X.relays=[]),Me.relays.forEach(Pe=>{-1===X.relays?.indexOf(Pe)&&X.relays.push(Pe)}),Me.relays=X.relays)}}),E.mentions.forEach(X=>{if(X.author){let le=E.profiles.find(Me=>Me.pubkey===X.author);le&&le.relays&&(X.relays||(X.relays=[]),le.relays.forEach(Me=>{-1===X.relays.indexOf(Me)&&X.relays.push(Me)}),le.relays=X.relays)}}),E}kr({},{parse:()=>oc}),kr({},{fetchRelayInformation:()=>oy,useFetchImplementation:()=>cm});try{fetch}catch{}function cm(b){}function oy(b){return xc.apply(this,arguments)}function xc(){return(xc=(0,a.A)(function*(b){return yield(yield fetch(b.replace("ws://","http://").replace("wss://","https://"),{headers:{Accept:"application/nostr+json"}})).json()})).apply(this,arguments)}function kh(b){let E=0;for(let A=0;A<64;A+=8){const j=parseInt(b.substring(A,A+8),16);if(0!==j){E+=Math.clz32(j);break}E+=32}return E}function os(b,E){let A=0;const j=b,X=["nonce",A.toString(),E.toString()];for(j.tags.push(X);;){const le=Math.floor((new Date).getTime()/1e3);if(le!==j.created_at&&(A=0,j.created_at=le),X[1]=(++A).toString(),j.id=Of(j),kh(j.id)>=E)break}return j}function Of(b){return(0,Xr.My)(Ss(Ys.encode(JSON.stringify([0,b.pubkey,b.created_at,b.kind,b.tags,b.content]))))}function um(b,E,A,j){return Ja({kind:ma,tags:[...b.tags??[],["e",E.id,A],["p",E.pubkey]],content:""===b.content?"":JSON.stringify(E),created_at:b.created_at},j)}function Rf(b){if(b.kind!==ma)return;let E,A;for(let j=b.tags.length-1;j>=0&&(void 0===E||void 0===A);j--){const X=b.tags[j];X.length>=2&&("e"===X[0]&&void 0===E?E=X:"p"===X[0]&&void 0===A&&(A=X))}return void 0!==E?{id:E[1],relays:[E[2],A?.[2]].filter(j=>"string"==typeof j),author:A?.[1]}:void 0}function Oh(b,{skipVerification:E}={}){const A=Rf(b);if(void 0===A||""===b.content)return;let j;try{j=JSON.parse(b.content)}catch{return}return j.id===A.id&&(E||En(j))?j:void 0}kr({},{fastEventHash:()=>Of,getPow:()=>kh,minePow:()=>os}),kr({},{finishRepostEvent:()=>um,getRepostedEvent:()=>Oh,getRepostedEventPointer:()=>Rf}),kr({},{NOSTR_URI_REGEX:()=>vu,parse:()=>dm,test:()=>Rh});var vu=new RegExp(`nostr:(${Xu.source})`);function Rh(b){return"string"==typeof b&&new RegExp(`^${vu.source}$`).test(b)}function dm(b){const E=b.match(new RegExp(`^${vu.source}$`));if(!E)throw new Error(`Invalid Nostr URI: ${b}`);return{uri:E[0],value:E[1],decoded:mu(E[1])}}function Lf(b,E,A){const j=E.tags.filter(X=>X.length>=2&&("e"===X[0]||"p"===X[0]));return Ja({...b,kind:ql,tags:[...b.tags??[],...j,["e",E.id],["p",E.pubkey]],content:b.content??"+"},A)}function Bg(b){if(b.kind!==ql)return;let E,A;for(let j=b.tags.length-1;j>=0&&(void 0===E||void 0===A);j--){const X=b.tags[j];X.length>=2&&("e"===X[0]&&void 0===E?E=X:"p"===X[0]&&void 0===A&&(A=X))}return void 0!==E&&void 0!==A?{id:E[1],relays:[E[2],A[2]].filter(j=>void 0!==j),author:A[1]}:void 0}kr({},{finishReactionEvent:()=>Lf,getReactedEventPointer:()=>Bg}),kr({},{matchAll:()=>yu,regex:()=>qu,replaceAll:()=>Ug});var qu=()=>new RegExp(`\\b${vu.source}\\b`,"g");function*yu(b){const E=b.matchAll(qu());for(const A of E)try{const[j,X]=A;yield{uri:j,value:X,decoded:mu(X),start:A.index,end:A.index+j.length}}catch{}}function Ug(b,E){return b.replaceAll(qu(),(A,j)=>E({uri:A,value:j,decoded:mu(j)}))}kr({},{channelCreateEvent:()=>Pf,channelHideMessageEvent:()=>wu,channelMessageEvent:()=>$g,channelMetadataEvent:()=>bu,channelMuteUserEvent:()=>Dc});var Pf=(b,E)=>{let A;if("object"==typeof b.content)A=JSON.stringify(b.content);else{if("string"!=typeof b.content)return;A=b.content}return Ja({kind:P,tags:[...b.tags??[]],content:A,created_at:b.created_at},E)},bu=(b,E)=>{let A;if("object"==typeof b.content)A=JSON.stringify(b.content);else{if("string"!=typeof b.content)return;A=b.content}return Ja({kind:$,tags:[["e",b.channel_create_event_id],...b.tags??[]],content:A,created_at:b.created_at},E)},$g=(b,E)=>{const A=[["e",b.channel_create_event_id,b.relay_url,"root"]];return b.reply_to_channel_message_event_id&&A.push(["e",b.reply_to_channel_message_event_id,b.relay_url,"reply"]),Ja({kind:oe,tags:[...A,...b.tags??[]],content:b.content,created_at:b.created_at},E)},wu=(b,E)=>{let A;if("object"==typeof b.content)A=JSON.stringify(b.content);else{if("string"!=typeof b.content)return;A=b.content}return Ja({kind:Ae,tags:[["e",b.channel_message_event_id],...b.tags??[]],content:A,created_at:b.created_at},E)},Dc=(b,E)=>{let A;if("object"==typeof b.content)A=JSON.stringify(b.content);else{if("string"!=typeof b.content)return;A=b.content}return Ja({kind:je,tags:[["p",b.pubkey_to_mute],...b.tags??[]],content:A,created_at:b.created_at},E)};kr({},{EMOJI_SHORTCODE_REGEX:()=>Nh,matchAll:()=>Ff,regex:()=>Nd,replaceAll:()=>Ju});var ed,Nh=/:(\w+):/,Nd=()=>new RegExp(`\\B${Nh.source}\\B`,"g");function*Ff(b){const E=b.matchAll(Nd());for(const A of E)try{const[j,X]=A;yield{shortcode:j,name:X,start:A.index,end:A.index+j.length}}catch{}}function Ju(b,E){return b.replaceAll(Nd(),(A,j)=>E({shortcode:A,name:j}))}kr({},{useFetchImplementation:()=>Lh,validateGithub:()=>td});try{ed=fetch}catch{}function Lh(b){ed=b}function td(b,E,A){return Bc.apply(this,arguments)}function Bc(){return(Bc=(0,a.A)(function*(b,E,A){try{return(yield(yield ed(`https://gist.github.com/${E}/${A}/raw`)).text())===`Verifying that I control the following Nostr public key: ${b}`}catch{return!1}})).apply(this,arguments)}kr({},{decrypt:()=>Bh,encrypt:()=>rd,getConversationKey:()=>xu,v2:()=>Uc});var sc=1,nd=65535;function xu(b,E){const A=wr.getSharedSecret(b,"02"+E).subarray(1,33);return function We(b,E,A){return Ao.hash(b),void 0===A&&(A=new Uint8Array(b.outputLen)),_e(b,(0,Xr.ZJ)(A),(0,Xr.ZJ)(E))}(Ss,A,"nip44-v2")}function Bf(b,E){const A=function on(b,E,A,j=32){if(Ao.hash(b),Ao.number(j),j>255*b.outputLen)throw new Error("Length should be <= 255*HashLen");const X=Math.ceil(j/b.outputLen);void 0===A&&(A=fn);const le=new Uint8Array(X*b.outputLen),Me=_e.create(b,E),Pe=Me._cloneInto(),Qe=new Uint8Array(Me.outputLen);for(let wt=0;wtnd)throw new Error("invalid plaintext size: must be between 1 and 65535 bytes");const E=new Uint8Array(2);return new DataView(E.buffer).setUint16(0,b,!1),E}(A),X=new Uint8Array(Ld(A)-A);return(0,Xr.Id)(j,E,X)}(b),Pe=Yl(j,X,Me),Qe=$f(le,Pe,A);return Qn.encode((0,Xr.Id)(new Uint8Array([2]),A,Pe,Qe))}function Bh(b,E){const{nonce:A,ciphertext:j,mac:X}=function va(b){if("string"!=typeof b)throw new Error("payload must be a valid string");const E=b.length;if(E<132||E>87472)throw new Error("invalid payload length: "+E);if("#"===b[0])throw new Error("unknown encryption version");let A;try{A=Qn.decode(b)}catch(le){throw new Error("invalid base64: "+le.message)}const j=A.length;if(j<99||j>65603)throw new Error("invalid data length: "+j);const X=A[0];if(2!==X)throw new Error("unknown encryption version "+X);return{nonce:A.subarray(1,33),ciphertext:A.subarray(33,-32),mac:A.subarray(-32)}}(b),{chacha_key:le,chacha_nonce:Me,hmac_key:Pe}=Bf(E,A);if(!ha($f(Pe,j,A),X))throw new Error("invalid MAC");return function Uf(b){const E=new DataView(b.buffer).getUint16(0),A=b.subarray(2,2+E);if(End||A.length!==E||b.length!==2+Ld(E))throw new Error("invalid padding");return Wr.decode(A)}(Yl(le,Me,j))}var id,Uc={utils:{getConversationKey:xu,calcPaddedLen:Ld},encrypt:rd,decrypt:Bh};function fm(b){const{pathname:E,searchParams:A}=new URL(b),j=E,X=A.get("relay"),le=A.get("secret");if(!j||!X||!le)throw new Error("invalid connection string");return{pubkey:j,relay:X,secret:le}}function ya(b,E,A){return ac.apply(this,arguments)}function ac(){return(ac=(0,a.A)(function*(b,E,A){const X=yield Ah(E,b,JSON.stringify({method:"pay_invoice",params:{invoice:A}})),le={kind:qs,created_at:Math.round(Date.now()/1e3),content:X,tags:[["p",b]]};return Ja(le,E)})).apply(this,arguments)}kr({},{makeNwcRequestEvent:()=>ya,parseConnectionString:()=>fm}),kr({},{getZapEndpoint:()=>$h,makeZapReceipt:()=>jh,makeZapRequest:()=>Vf,useFetchImplementation:()=>jf,validateZapRequest:()=>Hf});try{id=fetch}catch{}function jf(b){id=b}function $h(b){return Pd.apply(this,arguments)}function Pd(){return(Pd=(0,a.A)(function*(b){try{let E="",{lud06:A,lud16:j}=JSON.parse(b.content);if(A){let{words:Me}=de.decode(A,1e3),Pe=de.fromWords(Me);E=Wr.decode(Pe)}else{if(!j)return null;{let[Me,Pe]=j.split("@");E=new URL(`/.well-known/lnurlp/${Me}`,`https://${Pe}`).toString()}}let le=yield(yield id(E)).json();if(le.allowsNostr&&le.nostrPubkey)return le.callback}catch{}return null})).apply(this,arguments)}function Vf({profile:b,event:E,amount:A,relays:j,comment:X=""}){if(!A)throw new Error("amount not given");if(!b)throw new Error("profile not given");let le={kind:9734,created_at:Math.round(Date.now()/1e3),content:X,tags:[["p",b],["amount",A.toString()],["relays",...j]]};return E&&le.tags.push(["e",E]),le}function Hf(b){let E;try{E=JSON.parse(b)}catch{return"Invalid zap request JSON."}if(!is(E))return"Zap request is not a valid Nostr event.";if(!En(E))return"Invalid signature on zap request.";let A=E.tags.find(([le,Me])=>"p"===le&&Me);if(!A)return"Zap request doesn't have a 'p' tag.";if(!A[1].match(/^[a-f0-9]{64}$/))return"Zap request 'p' tag is not valid hex.";let j=E.tags.find(([le,Me])=>"e"===le&&Me);return j&&!j[1].match(/^[a-f0-9]{64}$/)?"Zap request 'e' tag is not valid hex.":E.tags.find(([le,Me])=>"relays"===le&&Me)?null:"Zap request doesn't have a 'relays' tag."}function jh({zapRequest:b,preimage:E,bolt11:A,paidAt:j}){let X=JSON.parse(b),le=X.tags.filter(([Pe])=>"e"===Pe||"p"===Pe||"a"===Pe),Me={kind:9735,created_at:Math.round(j.getTime()/1e3),content:"",tags:[...le,["P",X.pubkey],["bolt11",A],["description",b]]};return E&&Me.tags.push(["preimage",E]),Me}kr({},{createRumor:()=>Fd,createSeal:()=>Bd,createWrap:()=>Ud,unwrapEvent:()=>mm,unwrapManyEvents:()=>Wh,wrapEvent:()=>Cu,wrapManyEvents:()=>Hh});var zf=()=>Math.round(Date.now()/1e3),Kf=()=>Math.round(zf()-172800*Math.random()),lc=(b,E)=>xu(b,E),Vh=(b,E,A)=>rd(JSON.stringify(b),lc(E,A)),od=(b,E)=>JSON.parse(Bh(b.content,lc(E,b.pubkey)));function Fd(b,E){const A={created_at:zf(),content:"",tags:[],...b,pubkey:du(E)};return A.id=Ql(A),A}function Bd(b,E,A){return Ja({kind:Cl,content:Vh(b,E,A),created_at:Kf(),tags:[]},E)}function Ud(b,E){const A=uu();return Ja({kind:It,content:Vh(b,A,E),created_at:Kf(),tags:[["p",E]]},A)}function Cu(b,E,A){return Ud(Bd(Fd(b,E),E,A),A)}function Hh(b,E,A){if(!A||0===A.length)throw new Error("At least one recipient is required.");const j=du(E),X=[Cu(b,E,j)];return A.forEach(le=>{X.push(Cu(b,E,le))}),X}function mm(b,E){const A=od(b,E);return od(A,E)}function Wh(b,E){let A=[];return b.forEach(j=>{A.push(mm(j,E))}),A.sort((j,X)=>j.created_at-X.created_at),A}kr({},{getToken:()=>Xf,hashPayload:()=>nl,unpackEventFromToken:()=>Yf,validateEvent:()=>Yh,validateEventKind:()=>Gh,validateEventMethodTag:()=>_m,validateEventPayloadTag:()=>Du,validateEventTimestamp:()=>Qf,validateEventUrlTag:()=>Xh,validateToken:()=>$c});var Gf="Nostr ";function Xf(b,E,A){return zh.apply(this,arguments)}function zh(){return(zh=(0,a.A)(function*(b,E,A,j=!1,X){const le={kind:Dl,tags:[["u",b],["method",E]],created_at:Math.round((new Date).getTime()/1e3),content:""};X&&le.tags.push(["payload",nl(X)]);const Me=yield A(le);return(j?Gf:"")+Qn.encode(Ys.encode(JSON.stringify(Me)))})).apply(this,arguments)}function $c(b,E,A){return jc.apply(this,arguments)}function jc(){return(jc=(0,a.A)(function*(b,E,A){const j=yield Yf(b).catch(le=>{throw le});return yield Yh(j,E,A).catch(le=>{throw le})})).apply(this,arguments)}function Yf(b){return Kh.apply(this,arguments)}function Kh(){return(Kh=(0,a.A)(function*(b){if(!b)throw new Error("Missing token");b=b.replace(Gf,"");const E=Wr.decode(Qn.decode(b));if(!E||0===E.length||!E.startsWith("{"))throw new Error("Invalid token");return JSON.parse(E)})).apply(this,arguments)}function Qf(b){return!!b.created_at&&Math.round((new Date).getTime()/1e3)-b.created_at<60}function Gh(b){return b.kind===Dl}function Xh(b,E){const A=b.tags.find(j=>"u"===j[0]);return!!A&&A.length>0&&A[1]===E}function _m(b,E){const A=b.tags.find(j=>"method"===j[0]);return!!A&&A.length>0&&A[1].toLowerCase()===E.toLowerCase()}function nl(b){const E=Ss(Ys.encode(JSON.stringify(b)));return(0,Xr.My)(E)}function Du(b,E){const A=b.tags.find(X=>"payload"===X[0]);if(!A)return!1;const j=nl(E);return A.length>0&&A[1]===j}function Yh(b,E,A,j){return sd.apply(this,arguments)}function sd(){return(sd=(0,a.A)(function*(b,E,A,j){if(!En(b))throw new Error("Invalid nostr event, signature invalid");if(!Gh(b))throw new Error("Invalid nostr event, kind invalid");if(!Qf(b))throw new Error("Invalid nostr event, created_at timestamp invalid");if(!Xh(b,E))throw new Error("Invalid nostr event, url tag invalid");if(!_m(b,A))throw new Error("Invalid nostr event, method tag invalid");if(j&&"object"==typeof j&&Object.keys(j).length>0&&!Du(b,j))throw new Error("Invalid nostr event, payload tag does not match request body hash");return!0})).apply(this,arguments)}},3797:(o,s,r)=>{"use strict";r.d(s,{OS:()=>O,av:()=>L,qT:()=>ae,rV:()=>re}),Symbol("verified");var O=0,L=1,re=4,ae=7},4704:(o,s,r)=>{"use strict";r.d(s,{Vw:()=>ae,My:()=>M,Id:()=>se,O8:()=>w,aT:()=>O,po:()=>ce,Ow:()=>C,ZJ:()=>pe,ld:()=>Oe});const i="object"==typeof globalThis&&"crypto"in globalThis?globalThis.crypto:void 0,a=ue=>ue instanceof Uint8Array,w=ue=>new DataView(ue.buffer,ue.byteOffset,ue.byteLength),C=(ue,Ce)=>ue<<32-Ce|ue>>>Ce;if(68!==new Uint8Array(new Uint32Array([287454020]).buffer)[0])throw new Error("Non little-endian hardware is not supported");const S=Array.from({length:256},(ue,Ce)=>Ce.toString(16).padStart(2,"0"));function M(ue){if(!a(ue))throw new Error("Uint8Array expected");let Ce="";for(let Be=0;Beat+dt.length,0));let Be=0;return ue.forEach(at=>{if(!a(at))throw new Error("Uint8Array expected");Ce.set(at,Be),Be+=at.length}),Ce}class ae{clone(){return this._cloneInto()}}function Oe(ue){const Ce=at=>ue().update(pe(at)).digest(),Be=ue();return Ce.outputLen=Be.outputLen,Ce.blockLen=Be.blockLen,Ce.create=()=>ue(),Ce}function ce(ue=32){if(i&&"function"==typeof i.getRandomValues)return i.getRandomValues(new Uint8Array(ue));throw new Error("crypto.getRandomValues must be defined")}},2661:(o,s,r)=>{"use strict";function i(a,c){this.v=a,this.k=c}r.d(s,{A:()=>i})},3014:(o,s,r)=>{"use strict";function i(c,y,w,C,T,S,M){try{var O=c[S](M),L=O.value}catch(Z){return void w(Z)}O.done?y(L):Promise.resolve(L).then(C,T)}function a(c){return function(){var y=this,w=arguments;return new Promise(function(C,T){var S=c.apply(y,w);function M(L){i(S,C,T,M,O,"next",L)}function O(L){i(S,C,T,M,O,"throw",L)}M(void 0)})}}r.d(s,{A:()=>a})},5137:(o,s,r)=>{"use strict";r.d(s,{A:()=>a});var i=r(2661);function a(c){return new i.A(c,0)}},9129:(o,s,r)=>{"use strict";r.d(s,{A:()=>a});var i=r(2661);function a(y){return function(){return new c(y.apply(this,arguments))}}function c(y){var w,C;function T(M,O){try{var L=y[M](O),Z=L.value,q=Z instanceof i.A;Promise.resolve(q?Z.v:Z).then(function(re){if(q){var pe="return"===M?"return":"next";if(!Z.k||re.done)return T(pe,re);re=y[pe](re).value}S(L.done?"return":"normal",re)},function(re){T("throw",re)})}catch(re){S("throw",re)}}function S(M,O){switch(M){case"return":w.resolve({value:O,done:!0});break;case"throw":w.reject(O);break;default:w.resolve({value:O,done:!1})}(w=w.next)?T(w.key,w.arg):C=null}this._invoke=function(M,O){return new Promise(function(L,Z){var q={key:M,arg:O,resolve:L,reject:Z,next:null};C?C=C.next=q:(w=C=q,T(M,O))})},"function"!=typeof y.return&&(this.return=void 0)}c.prototype["function"==typeof Symbol&&Symbol.asyncIterator||"@@asyncIterator"]=function(){return this},c.prototype.next=function(y){return this._invoke("next",y)},c.prototype.throw=function(y){return this._invoke("throw",y)},c.prototype.return=function(y){return this._invoke("return",y)}},1635:(o,s,r)=>{"use strict";function Z(ze,$e,Ft,Ke){return new(Ft||(Ft=Promise))(function(it,Ot){function $t(st){try{Ee(Ke.next(st))}catch(Xt){Ot(Xt)}}function Te(st){try{Ee(Ke.throw(st))}catch(Xt){Ot(Xt)}}function Ee(st){st.done?it(st.value):function Ze(it){return it instanceof Ft?it:new Ft(function(Ot){Ot(it)})}(st.value).then($t,Te)}Ee((Ke=Ke.apply(ze,$e||[])).next())})}function xe(ze){return this instanceof xe?(this.v=ze,this):new xe(ze)}function De(ze,$e,Ft){if(!Symbol.asyncIterator)throw new TypeError("Symbol.asyncIterator is not defined.");var Ze,Ke=Ft.apply(ze,$e||[]),it=[];return Ze=Object.create(("function"==typeof AsyncIterator?AsyncIterator:Object).prototype),$t("next"),$t("throw"),$t("return",function Ot(Kt){return function(rt){return Promise.resolve(rt).then(Kt,Xt)}}),Ze[Symbol.asyncIterator]=function(){return this},Ze;function $t(Kt,rt){Ke[Kt]&&(Ze[Kt]=function(Vt){return new Promise(function(en,kn){it.push([Kt,Vt,en,kn])>1||Te(Kt,Vt)})},rt&&(Ze[Kt]=rt(Ze[Kt])))}function Te(Kt,rt){try{!function Ee(Kt){Kt.value instanceof xe?Promise.resolve(Kt.value.v).then(st,Xt):Mt(it[0][2],Kt)}(Ke[Kt](rt))}catch(Vt){Mt(it[0][3],Vt)}}function st(Kt){Te("next",Kt)}function Xt(Kt){Te("throw",Kt)}function Mt(Kt,rt){Kt(rt),it.shift(),it.length&&Te(it[0][0],it[0][1])}}function ue(ze){if(!Symbol.asyncIterator)throw new TypeError("Symbol.asyncIterator is not defined.");var Ft,$e=ze[Symbol.asyncIterator];return $e?$e.call(ze):(ze=function se(ze){var $e="function"==typeof Symbol&&Symbol.iterator,Ft=$e&&ze[$e],Ke=0;if(Ft)return Ft.call(ze);if(ze&&"number"==typeof ze.length)return{next:function(){return ze&&Ke>=ze.length&&(ze=void 0),{value:ze&&ze[Ke++],done:!ze}}};throw new TypeError($e?"Object is not iterable.":"Symbol.iterator is not defined.")}(ze),Ft={},Ke("next"),Ke("throw"),Ke("return"),Ft[Symbol.asyncIterator]=function(){return this},Ft);function Ke(it){Ft[it]=ze[it]&&function(Ot){return new Promise(function($t,Te){!function Ze(it,Ot,$t,Te){Promise.resolve(Te).then(function(Ee){it({value:Ee,done:$t})},Ot)}($t,Te,(Ot=ze[it](Ot)).done,Ot.value)})}}}r.d(s,{AQ:()=>De,N3:()=>xe,sH:()=>Z,xN:()=>ue}),"function"==typeof SuppressedError&&SuppressedError}},o=>{o(o.s=770)}]); \ No newline at end of file diff --git a/main.bb8bd8bc84452c78.js b/main.bb8bd8bc84452c78.js deleted file mode 100644 index a32577e..0000000 --- a/main.bb8bd8bc84452c78.js +++ /dev/null @@ -1 +0,0 @@ -(self.webpackChunkangor=self.webpackChunkangor||[]).push([[792],{6146:(o,s,r)=>{"use strict";r.d(s,{F:()=>i.F});var i=r(799)},799:(o,s,r)=>{"use strict";r.d(s,{F:()=>at});let i=(()=>{class dt{static{this.standard="cubic-bezier(0.4, 0.0, 0.2, 1)"}static{this.deceleration="cubic-bezier(0.0, 0.0, 0.2, 1)"}static{this.acceleration="cubic-bezier(0.4, 0.0, 1, 1)"}static{this.sharp="cubic-bezier(0.4, 0.0, 0.6, 1)"}}return dt})(),a=(()=>{class dt{static{this.complex="375ms"}static{this.entering="225ms"}static{this.exiting="195ms"}}return dt})();var c=r(1204);const ue=(dt,bt,lt,rn,gn=`${a.entering} ${i.deceleration}`,bn=`${a.exiting} ${i.acceleration}`)=>(0,c.hZ)(dt,[(0,c.wk)("void",(0,c.iF)(bt)),(0,c.wk)("*",(0,c.iF)(lt)),(0,c.kY)("void => false, * => false",[]),(0,c.kY)("void => *",(0,c.i0)(rn||gn),{params:{timings:gn}}),(0,c.kY)("* => void",(0,c.i0)(rn||bn),{params:{timings:bn}})]),at=[(0,c.hZ)("expandCollapse",[(0,c.wk)("void, collapsed",(0,c.iF)({height:"0"})),(0,c.wk)("*, expanded",(0,c.iF)("*")),(0,c.kY)("void <=> false, collapsed <=> false, expanded <=> false",[]),(0,c.kY)("void <=> *, collapsed <=> expanded",(0,c.i0)("{{timings}}"),{params:{timings:`${a.entering} ${i.deceleration}`}})]),(0,c.hZ)("fadeIn",[(0,c.wk)("void",(0,c.iF)({opacity:0})),(0,c.wk)("*",(0,c.iF)({opacity:1})),(0,c.kY)("void => false",[]),(0,c.kY)("void => *",(0,c.i0)("{{timings}}"),{params:{timings:`${a.entering} ${i.deceleration}`}})]),(0,c.hZ)("fadeInTop",[(0,c.wk)("void",(0,c.iF)({opacity:0,transform:"translate3d(0, -100%, 0)"})),(0,c.wk)("*",(0,c.iF)({opacity:1,transform:"translate3d(0, 0, 0)"})),(0,c.kY)("void => false",[]),(0,c.kY)("void => *",(0,c.i0)("{{timings}}"),{params:{timings:`${a.entering} ${i.deceleration}`}})]),(0,c.hZ)("fadeInBottom",[(0,c.wk)("void",(0,c.iF)({opacity:0,transform:"translate3d(0, 100%, 0)"})),(0,c.wk)("*",(0,c.iF)({opacity:1,transform:"translate3d(0, 0, 0)"})),(0,c.kY)("void => false",[]),(0,c.kY)("void => *",(0,c.i0)("{{timings}}"),{params:{timings:`${a.entering} ${i.deceleration}`}})]),(0,c.hZ)("fadeInLeft",[(0,c.wk)("void",(0,c.iF)({opacity:0,transform:"translate3d(-100%, 0, 0)"})),(0,c.wk)("*",(0,c.iF)({opacity:1,transform:"translate3d(0, 0, 0)"})),(0,c.kY)("void => false",[]),(0,c.kY)("void => *",(0,c.i0)("{{timings}}"),{params:{timings:`${a.entering} ${i.deceleration}`}})]),(0,c.hZ)("fadeInRight",[(0,c.wk)("void",(0,c.iF)({opacity:0,transform:"translate3d(100%, 0, 0)"})),(0,c.wk)("*",(0,c.iF)({opacity:1,transform:"translate3d(0, 0, 0)"})),(0,c.kY)("void => false",[]),(0,c.kY)("void => *",(0,c.i0)("{{timings}}"),{params:{timings:`${a.entering} ${i.deceleration}`}})]),(0,c.hZ)("fadeOut",[(0,c.wk)("*",(0,c.iF)({opacity:1})),(0,c.wk)("void",(0,c.iF)({opacity:0})),(0,c.kY)("false => void",[]),(0,c.kY)("* => void",(0,c.i0)("{{timings}}"),{params:{timings:`${a.exiting} ${i.acceleration}`}})]),(0,c.hZ)("fadeOutTop",[(0,c.wk)("*",(0,c.iF)({opacity:1,transform:"translate3d(0, 0, 0)"})),(0,c.wk)("void",(0,c.iF)({opacity:0,transform:"translate3d(0, -100%, 0)"})),(0,c.kY)("false => void",[]),(0,c.kY)("* => void",(0,c.i0)("{{timings}}"),{params:{timings:`${a.exiting} ${i.acceleration}`}})]),(0,c.hZ)("fadeOutBottom",[(0,c.wk)("*",(0,c.iF)({opacity:1,transform:"translate3d(0, 0, 0)"})),(0,c.wk)("void",(0,c.iF)({opacity:0,transform:"translate3d(0, 100%, 0)"})),(0,c.kY)("false => void",[]),(0,c.kY)("* => void",(0,c.i0)("{{timings}}"),{params:{timings:`${a.exiting} ${i.acceleration}`}})]),(0,c.hZ)("fadeOutLeft",[(0,c.wk)("*",(0,c.iF)({opacity:1,transform:"translate3d(0, 0, 0)"})),(0,c.wk)("void",(0,c.iF)({opacity:0,transform:"translate3d(-100%, 0, 0)"})),(0,c.kY)("false => void",[]),(0,c.kY)("* => void",(0,c.i0)("{{timings}}"),{params:{timings:`${a.exiting} ${i.acceleration}`}})]),(0,c.hZ)("fadeOutRight",[(0,c.wk)("*",(0,c.iF)({opacity:1,transform:"translate3d(0, 0, 0)"})),(0,c.wk)("void",(0,c.iF)({opacity:0,transform:"translate3d(100%, 0, 0)"})),(0,c.kY)("false => void",[]),(0,c.kY)("* => void",(0,c.i0)("{{timings}}"),{params:{timings:`${a.exiting} ${i.acceleration}`}})]),(0,c.hZ)("shake",[(0,c.kY)("void => false",[]),(0,c.kY)("void => *, * => true",[(0,c.i0)("{{timings}}",(0,c.i7)([(0,c.iF)({transform:"translate3d(0, 0, 0)",offset:0}),(0,c.iF)({transform:"translate3d(-10px, 0, 0)",offset:.1}),(0,c.iF)({transform:"translate3d(10px, 0, 0)",offset:.2}),(0,c.iF)({transform:"translate3d(-10px, 0, 0)",offset:.3}),(0,c.iF)({transform:"translate3d(10px, 0, 0)",offset:.4}),(0,c.iF)({transform:"translate3d(-10px, 0, 0)",offset:.5}),(0,c.iF)({transform:"translate3d(10px, 0, 0)",offset:.6}),(0,c.iF)({transform:"translate3d(-10px, 0, 0)",offset:.7}),(0,c.iF)({transform:"translate3d(10px, 0, 0)",offset:.8}),(0,c.iF)({transform:"translate3d(-10px, 0, 0)",offset:.9}),(0,c.iF)({transform:"translate3d(0, 0, 0)",offset:1})]))],{params:{timings:"0.8s cubic-bezier(0.455, 0.03, 0.515, 0.955)"}})]),(0,c.hZ)("slideInTop",[(0,c.wk)("void",(0,c.iF)({transform:"translate3d(0, -100%, 0)"})),(0,c.wk)("*",(0,c.iF)({transform:"translate3d(0, 0, 0)"})),(0,c.kY)("void => false",[]),(0,c.kY)("void => *",(0,c.i0)("{{timings}}"),{params:{timings:`${a.entering} ${i.deceleration}`}})]),(0,c.hZ)("slideInBottom",[(0,c.wk)("void",(0,c.iF)({transform:"translate3d(0, 100%, 0)"})),(0,c.wk)("*",(0,c.iF)({transform:"translate3d(0, 0, 0)"})),(0,c.kY)("void => false",[]),(0,c.kY)("void => *",(0,c.i0)("{{timings}}"),{params:{timings:`${a.entering} ${i.deceleration}`}})]),(0,c.hZ)("slideInLeft",[(0,c.wk)("void",(0,c.iF)({transform:"translate3d(-100%, 0, 0)"})),(0,c.wk)("*",(0,c.iF)({transform:"translate3d(0, 0, 0)"})),(0,c.kY)("void => false",[]),(0,c.kY)("void => *",(0,c.i0)("{{timings}}"),{params:{timings:`${a.entering} ${i.deceleration}`}})]),(0,c.hZ)("slideInRight",[(0,c.wk)("void",(0,c.iF)({transform:"translate3d(100%, 0, 0)"})),(0,c.wk)("*",(0,c.iF)({transform:"translate3d(0, 0, 0)"})),(0,c.kY)("void => false",[]),(0,c.kY)("void => *",(0,c.i0)("{{timings}}"),{params:{timings:`${a.entering} ${i.deceleration}`}})]),(0,c.hZ)("slideOutTop",[(0,c.wk)("*",(0,c.iF)({transform:"translate3d(0, 0, 0)"})),(0,c.wk)("void",(0,c.iF)({transform:"translate3d(0, -100%, 0)"})),(0,c.kY)("false => void",[]),(0,c.kY)("* => void",(0,c.i0)("{{timings}}"),{params:{timings:`${a.exiting} ${i.acceleration}`}})]),(0,c.hZ)("slideOutBottom",[(0,c.wk)("*",(0,c.iF)({transform:"translate3d(0, 0, 0)"})),(0,c.wk)("void",(0,c.iF)({transform:"translate3d(0, 100%, 0)"})),(0,c.kY)("false => void",[]),(0,c.kY)("* => void",(0,c.i0)("{{timings}}"),{params:{timings:`${a.exiting} ${i.acceleration}`}})]),(0,c.hZ)("slideOutLeft",[(0,c.wk)("*",(0,c.iF)({transform:"translate3d(0, 0, 0)"})),(0,c.wk)("void",(0,c.iF)({transform:"translate3d(-100%, 0, 0)"})),(0,c.kY)("false => void",[]),(0,c.kY)("* => void",(0,c.i0)("{{timings}}"),{params:{timings:`${a.exiting} ${i.acceleration}`}})]),(0,c.hZ)("slideOutRight",[(0,c.wk)("*",(0,c.iF)({transform:"translate3d(0, 0, 0)"})),(0,c.wk)("void",(0,c.iF)({transform:"translate3d(100%, 0, 0)"})),(0,c.kY)("false => void",[]),(0,c.kY)("* => void",(0,c.i0)("{{timings}}"),{params:{timings:`${a.exiting} ${i.acceleration}`}})]),ue("zoomIn",{opacity:0,transform:"scale(0.5)"},{opacity:1,transform:"scale(1)"},""),ue("zoomOut",{opacity:1,transform:"scale(1)"},{opacity:0,transform:"scale(0.5)"},"")]},3871:(o,s,r)=>{"use strict";r.d(s,{$w:()=>Rn,lX:()=>c,Tv:()=>Aa});var i=r(6146),a=r(3107);let c=(()=>{class Q{constructor(){this._componentRegistry=new Map,this._navigationStore=new Map}registerComponent(te,ot){this._componentRegistry.set(te,ot)}deregisterComponent(te){this._componentRegistry.delete(te)}getComponent(te){return this._componentRegistry.get(te)}storeNavigation(te,ot){this._navigationStore.set(te,ot)}getNavigation(te){return this._navigationStore.get(te)??[]}deleteNavigation(te){this._navigationStore.has(te)||console.warn(`Navigation with the key '${te}' does not exist.`),this._navigationStore.delete(te)}getFlatNavigation(te,ot=[]){for(const Ct of te)"basic"===Ct.type?ot.push(Ct):Ct.children&&this.getFlatNavigation(Ct.children,ot);return ot}getItem(te,ot){for(const Ct of ot){if(Ct.id===te)return Ct;if(Ct.children){const Bn=this.getItem(te,Ct.children);if(Bn)return Bn}}return null}getItemParent(te,ot,Ct){for(const Bn of ot){if(Bn.id===te)return Ct;if(Bn.children){const On=this.getItemParent(te,Bn.children,Bn);if(On)return On}}return null}static{this.\u0275fac=function(ot){return new(ot||Q)}}static{this.\u0275prov=a.jDH({token:Q,factory:Q.\u0275fac,providedIn:"root"})}}return Q})();var y=r(3939),w=r(7838),C=r(8447),T=r(4460),S=r(3904),M=r(7818),O=r(7712),L=r(8716),Z=r(5424);const q=Q=>({"angor-horizontal-navigation-item-active-forced":Q}),re=Q=>[Q];function pe(Q,et){1&Q&&a.eu8(0)}function se(Q,et){if(1&Q&&(a.j41(0,"div",2),a.DNE(1,pe,1,0,"ng-container",7),a.k0s()),2&Q){let te,ot,Ct,Bn;const On=a.XpG(),Wn=a.sdS(9);a.Y8G("ngClass",a.eq3(10,q,On.item.active))("routerLink",a.eq3(12,re,On.item.link))("fragment",null!==(te=On.item.fragment)&&void 0!==te?te:null)("preserveFragment",null!==(ot=On.item.preserveFragment)&&void 0!==ot&&ot)("queryParams",null!==(Ct=On.item.queryParams)&&void 0!==Ct?Ct:null)("queryParamsHandling",null!==(Bn=On.item.queryParamsHandling)&&void 0!==Bn?Bn:null)("routerLinkActive","angor-horizontal-navigation-item-active")("routerLinkActiveOptions",On.isActiveMatchOptions)("matTooltip",On.item.tooltip||""),a.R7$(),a.Y8G("ngTemplateOutlet",Wn)}}function ae(Q,et){1&Q&&a.eu8(0)}function me(Q,et){if(1&Q&&(a.j41(0,"a",3),a.DNE(1,ae,1,0,"ng-container",7),a.k0s()),2&Q){const te=a.XpG(),ot=a.sdS(9);a.Y8G("href",te.item.link,a.B4B)("target",te.item.target||"_self")("matTooltip",te.item.tooltip||""),a.R7$(),a.Y8G("ngTemplateOutlet",ot)}}function be(Q,et){1&Q&&a.eu8(0)}function Oe(Q,et){if(1&Q){const te=a.RV6();a.j41(0,"div",8),a.bIt("click",function(){a.eBV(te);const Ct=a.XpG();return a.Njj(Ct.item.function(Ct.item))}),a.DNE(1,be,1,0,"ng-container",7),a.k0s()}if(2&Q){const te=a.XpG(),ot=a.sdS(9);a.Y8G("ngClass",a.eq3(3,q,te.item.active))("matTooltip",te.item.tooltip||""),a.R7$(),a.Y8G("ngTemplateOutlet",ot)}}function xe(Q,et){1&Q&&a.eu8(0)}function De(Q,et){if(1&Q){const te=a.RV6();a.j41(0,"div",9),a.bIt("click",function(){a.eBV(te);const Ct=a.XpG();return a.Njj(Ct.item.function(Ct.item))}),a.DNE(1,xe,1,0,"ng-container",7),a.k0s()}if(2&Q){let te,ot,Ct,Bn;const On=a.XpG(),Wn=a.sdS(9);a.Y8G("ngClass",a.eq3(10,q,On.item.active))("routerLink",a.eq3(12,re,On.item.link))("fragment",null!==(te=On.item.fragment)&&void 0!==te?te:null)("preserveFragment",null!==(ot=On.item.preserveFragment)&&void 0!==ot&&ot)("queryParams",null!==(Ct=On.item.queryParams)&&void 0!==Ct?Ct:null)("queryParamsHandling",null!==(Bn=On.item.queryParamsHandling)&&void 0!==Bn?Bn:null)("routerLinkActive","angor-horizontal-navigation-item-active")("routerLinkActiveOptions",On.isActiveMatchOptions)("matTooltip",On.item.tooltip||""),a.R7$(),a.Y8G("ngTemplateOutlet",Wn)}}function ce(Q,et){1&Q&&a.eu8(0)}function ue(Q,et){if(1&Q){const te=a.RV6();a.j41(0,"a",10),a.bIt("click",function(){a.eBV(te);const Ct=a.XpG();return a.Njj(Ct.item.function(Ct.item))}),a.DNE(1,ce,1,0,"ng-container",7),a.k0s()}if(2&Q){const te=a.XpG(),ot=a.sdS(9);a.Y8G("href",te.item.link,a.B4B)("target",te.item.target||"_self")("matTooltip",te.item.tooltip||""),a.R7$(),a.Y8G("ngTemplateOutlet",ot)}}function Ce(Q,et){1&Q&&a.eu8(0)}function Be(Q,et){if(1&Q&&(a.j41(0,"div",4),a.DNE(1,Ce,1,0,"ng-container",7),a.k0s()),2&Q){const te=a.XpG(),ot=a.sdS(9);a.Y8G("ngClass",a.eq3(3,q,te.item.active))("matTooltip",te.item.tooltip||""),a.R7$(),a.Y8G("ngTemplateOutlet",ot)}}function at(Q,et){1&Q&&a.eu8(0)}function dt(Q,et){if(1&Q&&(a.j41(0,"div",6),a.DNE(1,at,1,0,"ng-container",7),a.k0s()),2&Q){a.XpG();const te=a.sdS(9);a.R7$(),a.Y8G("ngTemplateOutlet",te)}}function bt(Q,et){if(1&Q&&a.nrm(0,"mat-icon",11),2&Q){const te=a.XpG(2);a.Y8G("ngClass",null==te.item.classes?null:te.item.classes.icon)("svgIcon",te.item.icon)}}function lt(Q,et){if(1&Q&&(a.j41(0,"div",15)(1,"span",14),a.EFF(2),a.k0s()()),2&Q){const te=a.XpG(2);a.R7$(),a.Y8G("ngClass",null==te.item.classes?null:te.item.classes.subtitle),a.R7$(),a.SpI(" ",te.item.subtitle," ")}}function rn(Q,et){if(1&Q&&(a.j41(0,"div",16)(1,"div",17),a.EFF(2),a.k0s()()),2&Q){const te=a.XpG(2);a.R7$(),a.Y8G("ngClass",te.item.badge.classes),a.R7$(),a.SpI(" ",te.item.badge.title," ")}}function gn(Q,et){if(1&Q&&(a.DNE(0,bt,1,2,"mat-icon",11),a.j41(1,"div",12)(2,"div",13)(3,"span",14),a.EFF(4),a.k0s()(),a.DNE(5,lt,3,2,"div",15),a.k0s(),a.DNE(6,rn,3,2,"div",16)),2&Q){const te=a.XpG();a.vxM(te.item.icon?0:-1),a.R7$(3),a.Y8G("ngClass",null==te.item.classes?null:te.item.classes.title),a.R7$(),a.SpI(" ",te.item.title," "),a.R7$(),a.vxM(te.item.subtitle?5:-1),a.R7$(),a.vxM(te.item.badge?6:-1)}}let bn=(()=>{class Q{constructor(){this._changeDetectorRef=(0,a.WQX)(a.gRc),this._angorNavigationService=(0,a.WQX)(c),this._angorUtilsService=(0,a.WQX)(y.Q),this.isActiveMatchOptions=this._angorUtilsService.subsetMatchOptions,this._unsubscribeAll=new C.B}ngOnInit(){this.isActiveMatchOptions=this.item.isActiveMatchOptions??this.item.exactMatch?this._angorUtilsService.exactMatchOptions:this._angorUtilsService.subsetMatchOptions,this._angorHorizontalNavigationComponent=this._angorNavigationService.getComponent(this.name),this._changeDetectorRef.markForCheck(),this._angorHorizontalNavigationComponent.onRefreshed.pipe((0,Z.Q)(this._unsubscribeAll)).subscribe(()=>{this._changeDetectorRef.markForCheck()})}ngOnDestroy(){this._unsubscribeAll.next(null),this._unsubscribeAll.complete()}static{this.\u0275fac=function(ot){return new(ot||Q)}}static{this.\u0275cmp=a.VBU({type:Q,selectors:[["angor-horizontal-navigation-basic-item"]],inputs:{item:"item",name:"name"},decls:10,vars:10,consts:[["itemTemplate",""],[1,"angor-horizontal-navigation-item-wrapper",3,"ngClass"],[1,"angor-horizontal-navigation-item",3,"ngClass","routerLink","fragment","preserveFragment","queryParams","queryParamsHandling","routerLinkActive","routerLinkActiveOptions","matTooltip"],[1,"angor-horizontal-navigation-item",3,"href","target","matTooltip"],[1,"angor-horizontal-navigation-item",3,"ngClass","matTooltip"],["mat-menu-item","",1,"angor-horizontal-navigation-item",3,"href","target","matTooltip"],[1,"angor-horizontal-navigation-item","angor-horizontal-navigation-item-disabled"],[4,"ngTemplateOutlet"],[1,"angor-horizontal-navigation-item",3,"click","ngClass","matTooltip"],[1,"angor-horizontal-navigation-item",3,"click","ngClass","routerLink","fragment","preserveFragment","queryParams","queryParamsHandling","routerLinkActive","routerLinkActiveOptions","matTooltip"],["mat-menu-item","",1,"angor-horizontal-navigation-item",3,"click","href","target","matTooltip"],[1,"angor-horizontal-navigation-item-icon",3,"ngClass","svgIcon"],[1,"angor-horizontal-navigation-item-title-wrapper"],[1,"angor-horizontal-navigation-item-title"],[3,"ngClass"],[1,"angor-horizontal-navigation-item-subtitle","text-hint"],[1,"angor-horizontal-navigation-item-badge"],[1,"angor-horizontal-navigation-item-badge-content",3,"ngClass"]],template:function(ot,Ct){1&ot&&(a.j41(0,"div",1),a.DNE(1,se,2,14,"div",2)(2,me,2,4,"a",3)(3,Oe,2,5,"div",4)(4,De,2,14,"div",2)(5,ue,2,4,"a",5)(6,Be,2,5,"div",4)(7,dt,2,1,"div",6),a.k0s(),a.DNE(8,gn,7,5,"ng-template",null,0,a.C5r)),2&ot&&(a.AVh("angor-horizontal-navigation-item-has-subtitle",!!Ct.item.subtitle),a.Y8G("ngClass",null==Ct.item.classes?null:Ct.item.classes.wrapper),a.R7$(),a.vxM(!Ct.item.link||Ct.item.externalLink||Ct.item.function||Ct.item.disabled?-1:1),a.R7$(),a.vxM(Ct.item.link&&Ct.item.externalLink&&!Ct.item.function&&!Ct.item.disabled?2:-1),a.R7$(),a.vxM(Ct.item.link||!Ct.item.function||Ct.item.disabled?-1:3),a.R7$(),a.vxM(Ct.item.link&&!Ct.item.externalLink&&Ct.item.function&&!Ct.item.disabled?4:-1),a.R7$(),a.vxM(Ct.item.link&&Ct.item.externalLink&&Ct.item.function&&!Ct.item.disabled?5:-1),a.R7$(),a.vxM(Ct.item.link||Ct.item.function||Ct.item.disabled?-1:6),a.R7$(),a.vxM(Ct.item.disabled?7:-1))},dependencies:[T.YU,L.Wk,L.wQ,O.uc,O.oV,T.T3,M.Cn,M.fb,S.m_,S.An],encapsulation:2,changeDetection:0})}}return Q})(),Vn=(()=>{class Q{constructor(){this._changeDetectorRef=(0,a.WQX)(a.gRc),this._angorNavigationService=(0,a.WQX)(c),this._unsubscribeAll=new C.B}ngOnInit(){this._angorHorizontalNavigationComponent=this._angorNavigationService.getComponent(this.name),this._angorHorizontalNavigationComponent.onRefreshed.pipe((0,Z.Q)(this._unsubscribeAll)).subscribe(()=>{this._changeDetectorRef.markForCheck()})}ngOnDestroy(){this._unsubscribeAll.next(null),this._unsubscribeAll.complete()}static{this.\u0275fac=function(ot){return new(ot||Q)}}static{this.\u0275cmp=a.VBU({type:Q,selectors:[["angor-horizontal-navigation-divider-item"]],inputs:{item:"item",name:"name"},decls:1,vars:1,consts:[[1,"angor-horizontal-navigation-item-wrapper","divider",3,"ngClass"]],template:function(ot,Ct){1&ot&&a.nrm(0,"div",0),2&ot&&a.Y8G("ngClass",null==Ct.item.classes?null:Ct.item.classes.wrapper)},dependencies:[T.YU],encapsulation:2,changeDetection:0})}}return Q})();const yn=["matMenu"],qe=(Q,et)=>({"angor-horizontal-navigation-menu-active":Q,"angor-horizontal-navigation-menu-active-forced":et}),_t=Q=>({$implicit:Q}),ze=(Q,et)=>({"angor-horizontal-navigation-item-disabled":Q,"angor-horizontal-navigation-item-active-forced":et});function $e(Q,et){1&Q&&a.eu8(0)}function Ft(Q,et){if(1&Q){const te=a.RV6();a.j41(0,"div",6,2),a.bIt("onMenuOpen",function(){a.eBV(te);const Ct=a.XpG();return a.Njj(Ct.triggerChangeDetection())})("onMenuClose",function(){a.eBV(te);const Ct=a.XpG();return a.Njj(Ct.triggerChangeDetection())}),a.DNE(2,$e,1,0,"ng-container",7),a.k0s()}if(2&Q){const te=a.sdS(1),ot=a.XpG(),Ct=a.sdS(2),Bn=a.sdS(6);a.Y8G("ngClass",a.l_i(4,qe,te.menuOpen,ot.item.active))("matMenuTriggerFor",Ct),a.R7$(2),a.Y8G("ngTemplateOutlet",Bn)("ngTemplateOutletContext",a.eq3(7,_t,ot.item))}}function Ke(Q,et){if(1&Q&&(a.j41(0,"div",8),a.nrm(1,"angor-horizontal-navigation-basic-item",11),a.k0s()),2&Q){const te=a.XpG(2).$implicit,ot=a.XpG();a.Y8G("disabled",te.disabled),a.R7$(),a.Y8G("item",te)("name",ot.name)}}function Ze(Q,et){1&Q&&a.eu8(0)}function it(Q,et){if(1&Q&&(a.j41(0,"div",9),a.DNE(1,Ze,1,0,"ng-container",7),a.nrm(2,"angor-horizontal-navigation-branch-item",12,3),a.k0s()),2&Q){const te=a.sdS(3),ot=a.XpG(2).$implicit,Ct=a.XpG(),Bn=a.sdS(6);a.Y8G("disabled",ot.disabled)("matMenuTriggerFor",te.matMenu),a.R7$(),a.Y8G("ngTemplateOutlet",Bn)("ngTemplateOutletContext",a.eq3(7,_t,ot)),a.R7$(),a.Y8G("child",!0)("item",ot)("name",Ct.name)}}function Ot(Q,et){if(1&Q&&(a.j41(0,"div",10),a.nrm(1,"angor-horizontal-navigation-divider-item",11),a.k0s()),2&Q){const te=a.XpG(2).$implicit,ot=a.XpG();a.R7$(),a.Y8G("item",te)("name",ot.name)}}function $t(Q,et){if(1&Q&&a.DNE(0,Ke,2,3,"div",8)(1,it,4,9,"div",9)(2,Ot,2,2,"div",10),2&Q){const te=a.XpG().$implicit;a.vxM("basic"===te.type?0:-1),a.R7$(),a.vxM("aside"===te.type||"collapsable"===te.type||"group"===te.type?1:-1),a.R7$(),a.vxM("divider"===te.type?2:-1)}}function Te(Q,et){if(1&Q&&a.DNE(0,$t,3,3),2&Q){const te=et.$implicit;a.vxM(te.hidden&&!te.hidden(te)||!te.hidden?0:-1)}}function Ee(Q,et){if(1&Q&&a.nrm(0,"mat-icon",15),2&Q){const te=a.XpG().$implicit;a.Y8G("ngClass",null==te.classes?null:te.classes.icon)("svgIcon",te.icon)}}function st(Q,et){if(1&Q&&(a.j41(0,"div",19)(1,"span",18),a.EFF(2),a.k0s()()),2&Q){const te=a.XpG().$implicit;a.R7$(),a.Y8G("ngClass",null==te.classes?null:te.classes.subtitle),a.R7$(),a.SpI(" ",te.subtitle," ")}}function Xt(Q,et){if(1&Q&&(a.j41(0,"div",20)(1,"div",21),a.EFF(2),a.k0s()()),2&Q){const te=a.XpG().$implicit;a.R7$(),a.Y8G("ngClass",te.badge.classes),a.R7$(),a.SpI(" ",te.badge.title," ")}}function Mt(Q,et){if(1&Q&&(a.j41(0,"div",13)(1,"div",14),a.DNE(2,Ee,1,2,"mat-icon",15),a.j41(3,"div",16)(4,"div",17)(5,"span",18),a.EFF(6),a.k0s()(),a.DNE(7,st,3,2,"div",19),a.k0s(),a.DNE(8,Xt,3,2,"div",20),a.k0s()()),2&Q){const te=et.$implicit;a.AVh("angor-horizontal-navigation-item-has-subtitle",!!te.subtitle),a.Y8G("ngClass",null==te.classes?null:te.classes.wrapper),a.R7$(),a.Y8G("ngClass",a.l_i(10,ze,te.disabled,te.active))("matTooltip",te.tooltip||""),a.R7$(),a.vxM(te.icon?2:-1),a.R7$(3),a.Y8G("ngClass",null==te.classes?null:te.classes.title),a.R7$(),a.SpI(" ",te.title," "),a.R7$(),a.vxM(te.subtitle?7:-1),a.R7$(),a.vxM(te.badge?8:-1)}}let Kt=(()=>{class Q{constructor(){this._changeDetectorRef=(0,a.WQX)(a.gRc),this._angorNavigationService=(0,a.WQX)(c),this.child=!1,this._unsubscribeAll=new C.B}ngOnInit(){this._angorHorizontalNavigationComponent=this._angorNavigationService.getComponent(this.name),this._angorHorizontalNavigationComponent.onRefreshed.pipe((0,Z.Q)(this._unsubscribeAll)).subscribe(()=>{this._changeDetectorRef.markForCheck()})}ngOnDestroy(){this._unsubscribeAll.next(null),this._unsubscribeAll.complete()}triggerChangeDetection(){this._changeDetectorRef.markForCheck()}trackByFn(te,ot){return ot.id||te}static{this.\u0275fac=function(ot){return new(ot||Q)}}static{this.\u0275cmp=a.VBU({type:Q,selectors:[["angor-horizontal-navigation-branch-item"]],viewQuery:function(ot,Ct){if(1&ot&&a.GBs(yn,7),2&ot){let Bn;a.mGM(Bn=a.lsd())&&(Ct.matMenu=Bn.first)}},inputs:{child:"child",item:"item",name:"name"},decls:7,vars:2,consts:[["matMenu","matMenu"],["itemTemplate",""],["trigger","matMenuTrigger"],["branch",""],[3,"ngClass","matMenuTriggerFor"],[1,"angor-horizontal-navigation-menu-panel",3,"overlapTrigger"],[3,"onMenuOpen","onMenuClose","ngClass","matMenuTriggerFor"],[4,"ngTemplateOutlet","ngTemplateOutletContext"],["mat-menu-item","",1,"angor-horizontal-navigation-menu-item",3,"disabled"],["mat-menu-item","",1,"angor-horizontal-navigation-menu-item",3,"disabled","matMenuTriggerFor"],["mat-menu-item","",1,"angor-horizontal-navigation-menu-item"],[3,"item","name"],[3,"child","item","name"],[1,"angor-horizontal-navigation-item-wrapper",3,"ngClass"],[1,"angor-horizontal-navigation-item",3,"ngClass","matTooltip"],[1,"angor-horizontal-navigation-item-icon",3,"ngClass","svgIcon"],[1,"angor-horizontal-navigation-item-title-wrapper"],[1,"angor-horizontal-navigation-item-title"],[3,"ngClass"],[1,"angor-horizontal-navigation-item-subtitle","text-hint"],[1,"angor-horizontal-navigation-item-badge"],[1,"angor-horizontal-navigation-item-badge-content",3,"ngClass"]],template:function(ot,Ct){1&ot&&(a.DNE(0,Ft,3,9,"div",4),a.j41(1,"mat-menu",5,0),a.Z7z(3,Te,1,1,null,null,Ct.trackByFn,!0),a.k0s(),a.DNE(5,Mt,9,13,"ng-template",null,1,a.C5r)),2&ot&&(a.vxM(Ct.child?-1:0),a.R7$(),a.Y8G("overlapTrigger",!1),a.R7$(2),a.Dyx(Ct.item.children))},dependencies:()=>[Q,T.YU,M.Cn,M.kk,M.fb,M.Cp,T.T3,bn,Vn,O.uc,O.oV,S.m_,S.An],encapsulation:2,changeDetection:0})}}return Q})(),rt=(()=>{class Q{constructor(){this._changeDetectorRef=(0,a.WQX)(a.gRc),this._angorNavigationService=(0,a.WQX)(c),this._unsubscribeAll=new C.B}ngOnInit(){this._angorHorizontalNavigationComponent=this._angorNavigationService.getComponent(this.name),this._angorHorizontalNavigationComponent.onRefreshed.pipe((0,Z.Q)(this._unsubscribeAll)).subscribe(()=>{this._changeDetectorRef.markForCheck()})}ngOnDestroy(){this._unsubscribeAll.next(null),this._unsubscribeAll.complete()}static{this.\u0275fac=function(ot){return new(ot||Q)}}static{this.\u0275cmp=a.VBU({type:Q,selectors:[["angor-horizontal-navigation-spacer-item"]],inputs:{item:"item",name:"name"},decls:1,vars:1,consts:[[1,"angor-horizontal-navigation-item-wrapper",3,"ngClass"]],template:function(ot,Ct){1&ot&&a.nrm(0,"div",0),2&ot&&a.Y8G("ngClass",null==Ct.item.classes?null:Ct.item.classes.wrapper)},dependencies:[T.YU],encapsulation:2,changeDetection:0})}}return Q})();function Vt(Q,et){if(1&Q&&a.nrm(0,"angor-horizontal-navigation-basic-item",1),2&Q){const te=a.XpG(2).$implicit,ot=a.XpG();a.Y8G("item",te)("name",ot.name)}}function en(Q,et){if(1&Q&&a.nrm(0,"angor-horizontal-navigation-branch-item",1),2&Q){const te=a.XpG(2).$implicit,ot=a.XpG();a.Y8G("item",te)("name",ot.name)}}function kn(Q,et){if(1&Q&&a.nrm(0,"angor-horizontal-navigation-spacer-item",1),2&Q){const te=a.XpG(2).$implicit,ot=a.XpG();a.Y8G("item",te)("name",ot.name)}}function Kn(Q,et){if(1&Q&&a.DNE(0,Vt,1,2,"angor-horizontal-navigation-basic-item",1)(1,en,1,2,"angor-horizontal-navigation-branch-item",1)(2,kn,1,2,"angor-horizontal-navigation-spacer-item",1),2&Q){const te=a.XpG().$implicit;a.vxM("basic"===te.type?0:-1),a.R7$(),a.vxM("aside"===te.type||"collapsable"===te.type||"group"===te.type?1:-1),a.R7$(),a.vxM("spacer"===te.type?2:-1)}}function Nr(Q,et){if(1&Q&&a.DNE(0,Kn,3,3),2&Q){const te=et.$implicit;a.vxM(te.hidden&&!te.hidden(te)||!te.hidden?0:-1)}}let Rn=(()=>{class Q{constructor(){this._changeDetectorRef=(0,a.WQX)(a.gRc),this._angorNavigationService=(0,a.WQX)(c),this._angorUtilsService=(0,a.WQX)(y.Q),this.name=this._angorUtilsService.randomId(),this.onRefreshed=new w.m(1),this._unsubscribeAll=new C.B}ngOnChanges(te){"navigation"in te&&this._changeDetectorRef.markForCheck()}ngOnInit(){""===this.name&&(this.name=this._angorUtilsService.randomId()),this._angorNavigationService.registerComponent(this.name,this)}ngOnDestroy(){this._angorNavigationService.deregisterComponent(this.name),this._unsubscribeAll.next(null),this._unsubscribeAll.complete()}refresh(){this._changeDetectorRef.markForCheck(),this.onRefreshed.next(!0)}trackByFn(te,ot){return ot.id||te}static{this.\u0275fac=function(ot){return new(ot||Q)}}static{this.\u0275cmp=a.VBU({type:Q,selectors:[["angor-horizontal-navigation"]],inputs:{name:"name",navigation:"navigation"},exportAs:["angorHorizontalNavigation"],features:[a.OA$],decls:3,vars:0,consts:[[1,"angor-horizontal-navigation-wrapper"],[1,"angor-horizontal-navigation-menu-item",3,"item","name"]],template:function(ot,Ct){1&ot&&(a.j41(0,"div",0),a.Z7z(1,Nr,1,1,null,null,Ct.trackByFn,!0),a.k0s()),2&ot&&(a.R7$(),a.Dyx(Ct.navigation))},dependencies:[bn,Kt,rt],styles:["angor-horizontal-navigation .angor-horizontal-navigation-wrapper{display:flex;align-items:center}@media (min-width: 600px){angor-horizontal-navigation .angor-horizontal-navigation-wrapper angor-horizontal-navigation-basic-item:hover .angor-horizontal-navigation-item-wrapper,angor-horizontal-navigation .angor-horizontal-navigation-wrapper angor-horizontal-navigation-branch-item:hover .angor-horizontal-navigation-item-wrapper{background-color:var(--angor-bg-hover)}}angor-horizontal-navigation .angor-horizontal-navigation-wrapper angor-horizontal-navigation-basic-item .angor-horizontal-navigation-item-wrapper,angor-horizontal-navigation .angor-horizontal-navigation-wrapper angor-horizontal-navigation-branch-item .angor-horizontal-navigation-item-wrapper{border-radius:4px;overflow:hidden}angor-horizontal-navigation .angor-horizontal-navigation-wrapper angor-horizontal-navigation-basic-item .angor-horizontal-navigation-item-wrapper .angor-horizontal-navigation-item,angor-horizontal-navigation .angor-horizontal-navigation-wrapper angor-horizontal-navigation-branch-item .angor-horizontal-navigation-item-wrapper .angor-horizontal-navigation-item{padding:0 16px;cursor:pointer;-webkit-user-select:none;user-select:none}angor-horizontal-navigation .angor-horizontal-navigation-wrapper angor-horizontal-navigation-basic-item .angor-horizontal-navigation-item-wrapper .angor-horizontal-navigation-item .angor-horizontal-navigation-item-icon,angor-horizontal-navigation .angor-horizontal-navigation-wrapper angor-horizontal-navigation-branch-item .angor-horizontal-navigation-item-wrapper .angor-horizontal-navigation-item .angor-horizontal-navigation-item-icon{margin-right:12px}angor-horizontal-navigation .angor-horizontal-navigation-wrapper angor-horizontal-navigation-basic-item .angor-horizontal-navigation-item-active .angor-horizontal-navigation-item-title,angor-horizontal-navigation .angor-horizontal-navigation-wrapper angor-horizontal-navigation-basic-item .angor-horizontal-navigation-item-active-forced .angor-horizontal-navigation-item-title{--tw-text-opacity: 1 !important;color:rgba(var(--angor-primary-rgb),var(--tw-text-opacity, 1))!important}angor-horizontal-navigation .angor-horizontal-navigation-wrapper angor-horizontal-navigation-basic-item .angor-horizontal-navigation-item-active .angor-horizontal-navigation-item-subtitle,angor-horizontal-navigation .angor-horizontal-navigation-wrapper angor-horizontal-navigation-basic-item .angor-horizontal-navigation-item-active-forced .angor-horizontal-navigation-item-subtitle{--tw-text-opacity: 1 !important;color:rgba(var(--angor-primary-400-rgb),var(--tw-text-opacity, 1))!important}.dark angor-horizontal-navigation .angor-horizontal-navigation-wrapper angor-horizontal-navigation-basic-item .angor-horizontal-navigation-item-active .angor-horizontal-navigation-item-subtitle,.dark angor-horizontal-navigation .angor-horizontal-navigation-wrapper angor-horizontal-navigation-basic-item .angor-horizontal-navigation-item-active-forced .angor-horizontal-navigation-item-subtitle{--tw-text-opacity: 1 !important;color:rgba(var(--angor-primary-600-rgb),var(--tw-text-opacity, 1))!important}angor-horizontal-navigation .angor-horizontal-navigation-wrapper angor-horizontal-navigation-basic-item .angor-horizontal-navigation-item-active .angor-horizontal-navigation-item-icon,angor-horizontal-navigation .angor-horizontal-navigation-wrapper angor-horizontal-navigation-basic-item .angor-horizontal-navigation-item-active-forced .angor-horizontal-navigation-item-icon{--tw-text-opacity: 1 !important;color:rgba(var(--angor-primary-rgb),var(--tw-text-opacity, 1))!important}angor-horizontal-navigation .angor-horizontal-navigation-wrapper angor-horizontal-navigation-branch-item .angor-horizontal-navigation-menu-active .angor-horizontal-navigation-item-wrapper,angor-horizontal-navigation .angor-horizontal-navigation-wrapper angor-horizontal-navigation-branch-item .angor-horizontal-navigation-menu-active-forced .angor-horizontal-navigation-item-wrapper{background-color:var(--angor-bg-hover)}angor-horizontal-navigation .angor-horizontal-navigation-wrapper angor-horizontal-navigation-spacer-item{margin:12px 0}.angor-horizontal-navigation-menu-panel .angor-horizontal-navigation-menu-item{height:auto;min-height:0;line-height:normal;white-space:normal}.angor-horizontal-navigation-menu-panel .angor-horizontal-navigation-menu-item angor-horizontal-navigation-basic-item,.angor-horizontal-navigation-menu-panel .angor-horizontal-navigation-menu-item angor-horizontal-navigation-branch-item,.angor-horizontal-navigation-menu-panel .angor-horizontal-navigation-menu-item angor-horizontal-navigation-divider-item{display:flex;flex:1 1 auto}.angor-horizontal-navigation-menu-panel .angor-horizontal-navigation-menu-item angor-horizontal-navigation-divider-item{margin:8px -16px}.angor-horizontal-navigation-menu-panel .angor-horizontal-navigation-menu-item angor-horizontal-navigation-divider-item .angor-horizontal-navigation-item-wrapper{height:1px;box-shadow:0 1px}.angor-horizontal-navigation-menu-item angor-horizontal-navigation-basic-item .angor-horizontal-navigation-item-active .angor-horizontal-navigation-item-title,.angor-horizontal-navigation-menu-item angor-horizontal-navigation-basic-item .angor-horizontal-navigation-item-active-forced .angor-horizontal-navigation-item-title{--tw-text-opacity: 1 !important;color:rgba(var(--angor-primary-rgb),var(--tw-text-opacity, 1))!important}.angor-horizontal-navigation-menu-item angor-horizontal-navigation-basic-item .angor-horizontal-navigation-item-active .angor-horizontal-navigation-item-subtitle,.angor-horizontal-navigation-menu-item angor-horizontal-navigation-basic-item .angor-horizontal-navigation-item-active-forced .angor-horizontal-navigation-item-subtitle{--tw-text-opacity: 1 !important;color:rgba(var(--angor-primary-400-rgb),var(--tw-text-opacity, 1))!important}.dark .angor-horizontal-navigation-menu-item angor-horizontal-navigation-basic-item .angor-horizontal-navigation-item-active .angor-horizontal-navigation-item-subtitle,.dark .angor-horizontal-navigation-menu-item angor-horizontal-navigation-basic-item .angor-horizontal-navigation-item-active-forced .angor-horizontal-navigation-item-subtitle{--tw-text-opacity: 1 !important;color:rgba(var(--angor-primary-600-rgb),var(--tw-text-opacity, 1))!important}.angor-horizontal-navigation-menu-item angor-horizontal-navigation-basic-item .angor-horizontal-navigation-item-active .angor-horizontal-navigation-item-icon,.angor-horizontal-navigation-menu-item angor-horizontal-navigation-basic-item .angor-horizontal-navigation-item-active-forced .angor-horizontal-navigation-item-icon{--tw-text-opacity: 1 !important;color:rgba(var(--angor-primary-rgb),var(--tw-text-opacity, 1))!important}.angor-horizontal-navigation-menu-item .angor-horizontal-navigation-item-wrapper{width:100%}.angor-horizontal-navigation-menu-item .angor-horizontal-navigation-item-wrapper.angor-horizontal-navigation-item-has-subtitle .angor-horizontal-navigation-item{min-height:56px}.angor-horizontal-navigation-menu-item .angor-horizontal-navigation-item-wrapper .angor-horizontal-navigation-item{position:relative;display:flex;align-items:center;justify-content:flex-start;min-height:48px;width:100%;font-size:13px;font-weight:500;text-decoration:none}.angor-horizontal-navigation-menu-item .angor-horizontal-navigation-item-wrapper .angor-horizontal-navigation-item .angor-horizontal-navigation-item-title-wrapper .angor-horizontal-navigation-item-subtitle{font-size:12px}.angor-horizontal-navigation-menu-item .angor-horizontal-navigation-item-wrapper .angor-horizontal-navigation-item .angor-horizontal-navigation-item-badge{margin-left:auto}.angor-horizontal-navigation-menu-item .angor-horizontal-navigation-item-wrapper .angor-horizontal-navigation-item .angor-horizontal-navigation-item-badge .angor-horizontal-navigation-item-badge-content{display:flex;align-items:center;justify-content:center;font-size:10px;font-weight:600;white-space:nowrap;height:20px}\n"],encapsulation:2,data:{animation:i.F},changeDetection:0})}}return Q})();const pr=Q=>({"angor-vertical-navigation-item-active-forced":Q}),cn=Q=>[Q];function Fe(Q,et){1&Q&&a.eu8(0)}function ke(Q,et){if(1&Q&&(a.j41(0,"a",2),a.DNE(1,Fe,1,0,"ng-container",6),a.k0s()),2&Q){let te,ot,Ct,Bn;const On=a.XpG(),Wn=a.sdS(9);a.Y8G("ngClass",a.eq3(10,pr,On.item.active))("routerLink",a.eq3(12,cn,On.item.link))("fragment",null!==(te=On.item.fragment)&&void 0!==te?te:null)("preserveFragment",null!==(ot=On.item.preserveFragment)&&void 0!==ot&&ot)("queryParams",null!==(Ct=On.item.queryParams)&&void 0!==Ct?Ct:null)("queryParamsHandling",null!==(Bn=On.item.queryParamsHandling)&&void 0!==Bn?Bn:null)("routerLinkActive","angor-vertical-navigation-item-active")("routerLinkActiveOptions",On.isActiveMatchOptions)("matTooltip",On.item.tooltip||""),a.R7$(),a.Y8G("ngTemplateOutlet",Wn)}}function Je(Q,et){1&Q&&a.eu8(0)}function z(Q,et){if(1&Q&&(a.j41(0,"a",3),a.DNE(1,Je,1,0,"ng-container",6),a.k0s()),2&Q){const te=a.XpG(),ot=a.sdS(9);a.Y8G("href",te.item.link,a.B4B)("target",te.item.target||"_self")("matTooltip",te.item.tooltip||""),a.R7$(),a.Y8G("ngTemplateOutlet",ot)}}function N(Q,et){1&Q&&a.eu8(0)}function W(Q,et){if(1&Q){const te=a.RV6();a.j41(0,"div",7),a.bIt("click",function(){a.eBV(te);const Ct=a.XpG();return a.Njj(Ct.item.function(Ct.item))}),a.DNE(1,N,1,0,"ng-container",6),a.k0s()}if(2&Q){const te=a.XpG(),ot=a.sdS(9);a.Y8G("ngClass",a.eq3(3,pr,te.item.active))("matTooltip",te.item.tooltip||""),a.R7$(),a.Y8G("ngTemplateOutlet",ot)}}function Le(Q,et){1&Q&&a.eu8(0)}function ft(Q,et){if(1&Q){const te=a.RV6();a.j41(0,"a",8),a.bIt("click",function(){a.eBV(te);const Ct=a.XpG();return a.Njj(Ct.item.function(Ct.item))}),a.DNE(1,Le,1,0,"ng-container",6),a.k0s()}if(2&Q){let te,ot,Ct,Bn;const On=a.XpG(),Wn=a.sdS(9);a.Y8G("ngClass",a.eq3(10,pr,On.item.active))("routerLink",a.eq3(12,cn,On.item.link))("fragment",null!==(te=On.item.fragment)&&void 0!==te?te:null)("preserveFragment",null!==(ot=On.item.preserveFragment)&&void 0!==ot&&ot)("queryParams",null!==(Ct=On.item.queryParams)&&void 0!==Ct?Ct:null)("queryParamsHandling",null!==(Bn=On.item.queryParamsHandling)&&void 0!==Bn?Bn:null)("routerLinkActive","angor-vertical-navigation-item-active")("routerLinkActiveOptions",On.isActiveMatchOptions)("matTooltip",On.item.tooltip||""),a.R7$(),a.Y8G("ngTemplateOutlet",Wn)}}function mt(Q,et){1&Q&&a.eu8(0)}function St(Q,et){if(1&Q){const te=a.RV6();a.j41(0,"a",9),a.bIt("click",function(){a.eBV(te);const Ct=a.XpG();return a.Njj(Ct.item.function(Ct.item))}),a.DNE(1,mt,1,0,"ng-container",6),a.k0s()}if(2&Q){const te=a.XpG(),ot=a.sdS(9);a.Y8G("href",te.item.link,a.B4B)("target",te.item.target||"_self")("matTooltip",te.item.tooltip||""),a.R7$(),a.Y8G("ngTemplateOutlet",ot)}}function Tn(Q,et){1&Q&&a.eu8(0)}function an(Q,et){if(1&Q&&(a.j41(0,"div",4),a.DNE(1,Tn,1,0,"ng-container",6),a.k0s()),2&Q){const te=a.XpG(),ot=a.sdS(9);a.Y8G("ngClass",a.eq3(3,pr,te.item.active))("matTooltip",te.item.tooltip||""),a.R7$(),a.Y8G("ngTemplateOutlet",ot)}}function dn(Q,et){1&Q&&a.eu8(0)}function In(Q,et){if(1&Q&&(a.j41(0,"div",5),a.DNE(1,dn,1,0,"ng-container",6),a.k0s()),2&Q){const te=a.XpG(),ot=a.sdS(9);a.Y8G("matTooltip",te.item.tooltip||""),a.R7$(),a.Y8G("ngTemplateOutlet",ot)}}function sr(Q,et){if(1&Q&&a.nrm(0,"mat-icon",10),2&Q){const te=a.XpG(2);a.Y8G("ngClass",null==te.item.classes?null:te.item.classes.icon)("svgIcon",te.item.icon)}}function xn(Q,et){if(1&Q&&(a.j41(0,"div",14)(1,"span",13),a.EFF(2),a.k0s()()),2&Q){const te=a.XpG(2);a.R7$(),a.Y8G("ngClass",null==te.item.classes?null:te.item.classes.subtitle),a.R7$(),a.SpI(" ",te.item.subtitle," ")}}function Hr(Q,et){if(1&Q&&(a.j41(0,"div",15)(1,"div",16),a.EFF(2),a.k0s()()),2&Q){const te=a.XpG(2);a.R7$(),a.Y8G("ngClass",te.item.badge.classes),a.R7$(),a.SpI(" ",te.item.badge.title," ")}}function Tr(Q,et){if(1&Q&&(a.DNE(0,sr,1,2,"mat-icon",10),a.j41(1,"div",11)(2,"div",12)(3,"span",13),a.EFF(4),a.k0s()(),a.DNE(5,xn,3,2,"div",14),a.k0s(),a.DNE(6,Hr,3,2,"div",15)),2&Q){const te=a.XpG();a.vxM(te.item.icon?0:-1),a.R7$(3),a.Y8G("ngClass",null==te.item.classes?null:te.item.classes.title),a.R7$(),a.SpI(" ",te.item.title," "),a.R7$(),a.vxM(te.item.subtitle?5:-1),a.R7$(),a.vxM(te.item.badge?6:-1)}}let Vr=(()=>{class Q{constructor(){this._changeDetectorRef=(0,a.WQX)(a.gRc),this._angorNavigationService=(0,a.WQX)(c),this._angorUtilsService=(0,a.WQX)(y.Q),this.isActiveMatchOptions=this._angorUtilsService.subsetMatchOptions,this._unsubscribeAll=new C.B}ngOnInit(){this.isActiveMatchOptions=this.item.isActiveMatchOptions??this.item.exactMatch?this._angorUtilsService.exactMatchOptions:this._angorUtilsService.subsetMatchOptions,this._angorVerticalNavigationComponent=this._angorNavigationService.getComponent(this.name),this._changeDetectorRef.markForCheck(),this._angorVerticalNavigationComponent.onRefreshed.pipe((0,Z.Q)(this._unsubscribeAll)).subscribe(()=>{this._changeDetectorRef.markForCheck()})}ngOnDestroy(){this._unsubscribeAll.next(null),this._unsubscribeAll.complete()}static{this.\u0275fac=function(ot){return new(ot||Q)}}static{this.\u0275cmp=a.VBU({type:Q,selectors:[["angor-vertical-navigation-basic-item"]],inputs:{item:"item",name:"name"},decls:10,vars:10,consts:[["itemTemplate",""],[1,"angor-vertical-navigation-item-wrapper",3,"ngClass"],[1,"angor-vertical-navigation-item",3,"ngClass","routerLink","fragment","preserveFragment","queryParams","queryParamsHandling","routerLinkActive","routerLinkActiveOptions","matTooltip"],[1,"angor-vertical-navigation-item",3,"href","target","matTooltip"],[1,"angor-vertical-navigation-item",3,"ngClass","matTooltip"],[1,"angor-vertical-navigation-item","angor-vertical-navigation-item-disabled",3,"matTooltip"],[4,"ngTemplateOutlet"],[1,"angor-vertical-navigation-item",3,"click","ngClass","matTooltip"],[1,"angor-vertical-navigation-item",3,"click","ngClass","routerLink","fragment","preserveFragment","queryParams","queryParamsHandling","routerLinkActive","routerLinkActiveOptions","matTooltip"],[1,"angor-vertical-navigation-item",3,"click","href","target","matTooltip"],[1,"angor-vertical-navigation-item-icon",3,"ngClass","svgIcon"],[1,"angor-vertical-navigation-item-title-wrapper"],[1,"angor-vertical-navigation-item-title"],[3,"ngClass"],[1,"angor-vertical-navigation-item-subtitle"],[1,"angor-vertical-navigation-item-badge"],[1,"angor-vertical-navigation-item-badge-content",3,"ngClass"]],template:function(ot,Ct){1&ot&&(a.j41(0,"div",1),a.DNE(1,ke,2,14,"a",2)(2,z,2,4,"a",3)(3,W,2,5,"div",4)(4,ft,2,14,"a",2)(5,St,2,4,"a",3)(6,an,2,5,"div",4)(7,In,2,2,"div",5),a.k0s(),a.DNE(8,Tr,7,5,"ng-template",null,0,a.C5r)),2&ot&&(a.AVh("angor-vertical-navigation-item-has-subtitle",!!Ct.item.subtitle),a.Y8G("ngClass",null==Ct.item.classes?null:Ct.item.classes.wrapper),a.R7$(),a.vxM(!Ct.item.link||Ct.item.externalLink||Ct.item.function||Ct.item.disabled?-1:1),a.R7$(),a.vxM(Ct.item.link&&Ct.item.externalLink&&!Ct.item.function&&!Ct.item.disabled?2:-1),a.R7$(),a.vxM(Ct.item.link||!Ct.item.function||Ct.item.disabled?-1:3),a.R7$(),a.vxM(Ct.item.link&&!Ct.item.externalLink&&Ct.item.function&&!Ct.item.disabled?4:-1),a.R7$(),a.vxM(Ct.item.link&&Ct.item.externalLink&&Ct.item.function&&!Ct.item.disabled?5:-1),a.R7$(),a.vxM(Ct.item.link||Ct.item.function||Ct.item.disabled?-1:6),a.R7$(),a.vxM(Ct.item.disabled?7:-1))},dependencies:[T.YU,L.Wk,L.wQ,O.uc,O.oV,T.T3,S.m_,S.An],encapsulation:2,changeDetection:0})}}return Q})(),vt=(()=>{class Q{constructor(){this._changeDetectorRef=(0,a.WQX)(a.gRc),this._angorNavigationService=(0,a.WQX)(c),this._unsubscribeAll=new C.B}ngOnInit(){this._angorVerticalNavigationComponent=this._angorNavigationService.getComponent(this.name),this._angorVerticalNavigationComponent.onRefreshed.pipe((0,Z.Q)(this._unsubscribeAll)).subscribe(()=>{this._changeDetectorRef.markForCheck()})}ngOnDestroy(){this._unsubscribeAll.next(null),this._unsubscribeAll.complete()}static{this.\u0275fac=function(ot){return new(ot||Q)}}static{this.\u0275cmp=a.VBU({type:Q,selectors:[["angor-vertical-navigation-divider-item"]],inputs:{item:"item",name:"name"},decls:1,vars:1,consts:[[1,"angor-vertical-navigation-item-wrapper","divider",3,"ngClass"]],template:function(ot,Ct){1&ot&&a.nrm(0,"div",0),2&ot&&a.Y8G("ngClass",null==Ct.item.classes?null:Ct.item.classes.wrapper)},dependencies:[T.YU],encapsulation:2,changeDetection:0})}}return Q})(),Wt=(()=>{class Q{constructor(){this._changeDetectorRef=(0,a.WQX)(a.gRc),this._angorNavigationService=(0,a.WQX)(c),this._unsubscribeAll=new C.B}ngOnInit(){this._angorVerticalNavigationComponent=this._angorNavigationService.getComponent(this.name),this._angorVerticalNavigationComponent.onRefreshed.pipe((0,Z.Q)(this._unsubscribeAll)).subscribe(()=>{this._changeDetectorRef.markForCheck()})}ngOnDestroy(){this._unsubscribeAll.next(null),this._unsubscribeAll.complete()}static{this.\u0275fac=function(ot){return new(ot||Q)}}static{this.\u0275cmp=a.VBU({type:Q,selectors:[["angor-vertical-navigation-spacer-item"]],inputs:{item:"item",name:"name"},decls:1,vars:1,consts:[[1,"angor-vertical-navigation-item-wrapper",3,"ngClass"]],template:function(ot,Ct){1&ot&&a.nrm(0,"div",0),2&ot&&a.Y8G("ngClass",null==Ct.item.classes?null:Ct.item.classes.wrapper)},dependencies:[T.YU],encapsulation:2,changeDetection:0})}}return Q})();function Re(Q,et){if(1&Q&&a.nrm(0,"mat-icon",2),2&Q){const te=a.XpG();a.Y8G("ngClass",null==te.item.classes?null:te.item.classes.icon)("svgIcon",te.item.icon)}}function Ge(Q,et){if(1&Q&&(a.j41(0,"div",6)(1,"span",5),a.EFF(2),a.k0s()()),2&Q){const te=a.XpG();a.R7$(),a.Y8G("ngClass",null==te.item.classes?null:te.item.classes.subtitle),a.R7$(),a.SpI(" ",te.item.subtitle," ")}}function Ve(Q,et){if(1&Q&&(a.j41(0,"div",7)(1,"div",8),a.EFF(2),a.k0s()()),2&Q){const te=a.XpG();a.R7$(),a.Y8G("ngClass",te.item.badge.classes),a.R7$(),a.SpI(" ",te.item.badge.title," ")}}function Dt(Q,et){if(1&Q&&a.nrm(0,"angor-vertical-navigation-basic-item",9),2&Q){const te=a.XpG(2).$implicit,ot=a.XpG();a.Y8G("item",te)("name",ot.name)}}function ct(Q,et){if(1&Q&&a.nrm(0,"angor-vertical-navigation-collapsable-item",10),2&Q){const te=a.XpG(2).$implicit,ot=a.XpG();a.Y8G("item",te)("name",ot.name)("autoCollapse",ot.autoCollapse)}}function Bt(Q,et){if(1&Q&&a.nrm(0,"angor-vertical-navigation-divider-item",9),2&Q){const te=a.XpG(2).$implicit,ot=a.XpG();a.Y8G("item",te)("name",ot.name)}}function wn(Q,et){if(1&Q&&a.nrm(0,"angor-vertical-navigation-group-item",9),2&Q){const te=a.XpG(2).$implicit,ot=a.XpG();a.Y8G("item",te)("name",ot.name)}}function qn(Q,et){if(1&Q&&a.nrm(0,"angor-vertical-navigation-spacer-item",9),2&Q){const te=a.XpG(2).$implicit,ot=a.XpG();a.Y8G("item",te)("name",ot.name)}}function Er(Q,et){if(1&Q&&a.DNE(0,Dt,1,2,"angor-vertical-navigation-basic-item",9)(1,ct,1,3,"angor-vertical-navigation-collapsable-item",10)(2,Bt,1,2,"angor-vertical-navigation-divider-item",9)(3,wn,1,2,"angor-vertical-navigation-group-item",9)(4,qn,1,2,"angor-vertical-navigation-spacer-item",9),2&Q){const te=a.XpG().$implicit;a.vxM("basic"===te.type?0:-1),a.R7$(),a.vxM("collapsable"===te.type?1:-1),a.R7$(),a.vxM("divider"===te.type?2:-1),a.R7$(),a.vxM("group"===te.type?3:-1),a.R7$(),a.vxM("spacer"===te.type?4:-1)}}function si(Q,et){if(1&Q&&a.DNE(0,Er,5,5),2&Q){const te=et.$implicit;a.vxM(te.hidden&&!te.hidden(te)||!te.hidden?0:-1)}}let hi=(()=>{class Q{constructor(){this._changeDetectorRef=(0,a.WQX)(a.gRc),this._angorNavigationService=(0,a.WQX)(c),this._unsubscribeAll=new C.B}ngOnInit(){this._angorVerticalNavigationComponent=this._angorNavigationService.getComponent(this.name),this._angorVerticalNavigationComponent.onRefreshed.pipe((0,Z.Q)(this._unsubscribeAll)).subscribe(()=>{this._changeDetectorRef.markForCheck()})}ngOnDestroy(){this._unsubscribeAll.next(null),this._unsubscribeAll.complete()}trackByFn(te,ot){return ot.id||te}static{this.\u0275fac=function(ot){return new(ot||Q)}}static{this.\u0275cmp=a.VBU({type:Q,selectors:[["angor-vertical-navigation-group-item"]],inputs:{autoCollapse:"autoCollapse",item:"item",name:"name"},decls:11,vars:8,consts:[[1,"angor-vertical-navigation-item-wrapper",3,"ngClass"],[1,"angor-vertical-navigation-item"],[1,"angor-vertical-navigation-item-icon",3,"ngClass","svgIcon"],[1,"angor-vertical-navigation-item-title-wrapper"],[1,"angor-vertical-navigation-item-title"],[3,"ngClass"],[1,"angor-vertical-navigation-item-subtitle"],[1,"angor-vertical-navigation-item-badge"],[1,"angor-vertical-navigation-item-badge-content",3,"ngClass"],[3,"item","name"],[3,"item","name","autoCollapse"]],template:function(ot,Ct){1&ot&&(a.j41(0,"div",0)(1,"div",1),a.DNE(2,Re,1,2,"mat-icon",2),a.j41(3,"div",3)(4,"div",4)(5,"span",5),a.EFF(6),a.k0s()(),a.DNE(7,Ge,3,2,"div",6),a.k0s(),a.DNE(8,Ve,3,2,"div",7),a.k0s()(),a.Z7z(9,si,1,1,null,null,Ct.trackByFn,!0)),2&ot&&(a.AVh("angor-vertical-navigation-item-has-subtitle",!!Ct.item.subtitle),a.Y8G("ngClass",null==Ct.item.classes?null:Ct.item.classes.wrapper),a.R7$(2),a.vxM(Ct.item.icon?2:-1),a.R7$(3),a.Y8G("ngClass",null==Ct.item.classes?null:Ct.item.classes.title),a.R7$(),a.SpI(" ",Ct.item.title," "),a.R7$(),a.vxM(Ct.item.subtitle?7:-1),a.R7$(),a.vxM(Ct.item.badge?8:-1),a.R7$(),a.Dyx(Ct.item.children))},dependencies:()=>[Q,T.YU,S.m_,S.An,Vr,qo,vt,Wt],encapsulation:2,changeDetection:0})}}return Q})();var Zi=r(1483);const Jt=Q=>({"angor-vertical-navigation-item-disabled":Q});function Tt(Q,et){if(1&Q&&a.nrm(0,"mat-icon",2),2&Q){const te=a.XpG();a.Y8G("ngClass",null==te.item.classes?null:te.item.classes.icon)("svgIcon",te.item.icon)}}function nt(Q,et){if(1&Q&&(a.j41(0,"div",6)(1,"span",5),a.EFF(2),a.k0s()()),2&Q){const te=a.XpG();a.R7$(),a.Y8G("ngClass",null==te.item.classes?null:te.item.classes.subtitle),a.R7$(),a.SpI(" ",te.item.subtitle," ")}}function Rt(Q,et){if(1&Q&&(a.j41(0,"div",7)(1,"div",10),a.EFF(2),a.k0s()()),2&Q){const te=a.XpG();a.R7$(),a.Y8G("ngClass",te.item.badge.classes),a.R7$(),a.SpI(" ",te.item.badge.title," ")}}function sn(Q,et){if(1&Q&&a.nrm(0,"angor-vertical-navigation-basic-item",11),2&Q){const te=a.XpG(2).$implicit,ot=a.XpG(2);a.Y8G("item",te)("name",ot.name)}}function mn(Q,et){if(1&Q&&a.nrm(0,"angor-vertical-navigation-collapsable-item",12),2&Q){const te=a.XpG(2).$implicit,ot=a.XpG(2);a.Y8G("item",te)("name",ot.name)("autoCollapse",ot.autoCollapse)}}function dr(Q,et){if(1&Q&&a.nrm(0,"angor-vertical-navigation-divider-item",11),2&Q){const te=a.XpG(2).$implicit,ot=a.XpG(2);a.Y8G("item",te)("name",ot.name)}}function Co(Q,et){if(1&Q&&a.nrm(0,"angor-vertical-navigation-group-item",11),2&Q){const te=a.XpG(2).$implicit,ot=a.XpG(2);a.Y8G("item",te)("name",ot.name)}}function Ni(Q,et){if(1&Q&&a.nrm(0,"angor-vertical-navigation-spacer-item",11),2&Q){const te=a.XpG(2).$implicit,ot=a.XpG(2);a.Y8G("item",te)("name",ot.name)}}function ds(Q,et){if(1&Q&&a.DNE(0,sn,1,2,"angor-vertical-navigation-basic-item",11)(1,mn,1,3,"angor-vertical-navigation-collapsable-item",12)(2,dr,1,2,"angor-vertical-navigation-divider-item",11)(3,Co,1,2,"angor-vertical-navigation-group-item",11)(4,Ni,1,2,"angor-vertical-navigation-spacer-item",11),2&Q){const te=a.XpG().$implicit;a.vxM("basic"===te.type?0:-1),a.R7$(),a.vxM("collapsable"===te.type?1:-1),a.R7$(),a.vxM("divider"===te.type?2:-1),a.R7$(),a.vxM("group"===te.type?3:-1),a.R7$(),a.vxM("spacer"===te.type?4:-1)}}function $o(Q,et){if(1&Q&&a.DNE(0,ds,5,5),2&Q){const te=et.$implicit;a.vxM(te.hidden&&!te.hidden(te)||!te.hidden?0:-1)}}function ai(Q,et){if(1&Q&&(a.j41(0,"div",9),a.Z7z(1,$o,1,1,null,null,a.BUC().trackByFn,!0),a.k0s()),2&Q){const te=a.XpG();a.Y8G("@expandCollapse",void 0),a.R7$(),a.Dyx(te.item.children)}}let qo=(()=>{class Q{constructor(){this._changeDetectorRef=(0,a.WQX)(a.gRc),this._router=(0,a.WQX)(L.Ix),this._angorNavigationService=(0,a.WQX)(c),this.isCollapsed=!0,this.isExpanded=!1,this._unsubscribeAll=new C.B}get classList(){return{"angor-vertical-navigation-item-collapsed":this.isCollapsed,"angor-vertical-navigation-item-expanded":this.isExpanded}}ngOnInit(){this._angorVerticalNavigationComponent=this._angorNavigationService.getComponent(this.name),this._hasActiveChild(this.item,this._router.url)?this.expand():this.autoCollapse&&this.collapse(),this._angorVerticalNavigationComponent.onCollapsableItemCollapsed.pipe((0,Z.Q)(this._unsubscribeAll)).subscribe(te=>{null!==te&&this._isChildrenOf(te,this.item)&&this.collapse()}),this.autoCollapse&&this._angorVerticalNavigationComponent.onCollapsableItemExpanded.pipe((0,Z.Q)(this._unsubscribeAll)).subscribe(te=>{null!==te&&(this._isChildrenOf(this.item,te)||this._hasActiveChild(this.item,this._router.url)||this.item!==te&&this.collapse())}),this._router.events.pipe((0,Zi.p)(te=>te instanceof L.wF),(0,Z.Q)(this._unsubscribeAll)).subscribe(te=>{this._hasActiveChild(this.item,te.urlAfterRedirects)?this.expand():this.autoCollapse&&this.collapse()}),this._angorVerticalNavigationComponent.onRefreshed.pipe((0,Z.Q)(this._unsubscribeAll)).subscribe(()=>{this._changeDetectorRef.markForCheck()})}ngOnDestroy(){this._unsubscribeAll.next(null),this._unsubscribeAll.complete()}collapse(){this.item.disabled||this.isCollapsed||(this.isCollapsed=!0,this.isExpanded=!this.isCollapsed,this._changeDetectorRef.markForCheck(),this._angorVerticalNavigationComponent.onCollapsableItemCollapsed.next(this.item))}expand(){this.item.disabled||this.isCollapsed&&(this.isCollapsed=!1,this.isExpanded=!this.isCollapsed,this._changeDetectorRef.markForCheck(),this._angorVerticalNavigationComponent.onCollapsableItemExpanded.next(this.item))}toggleCollapsable(){this.isCollapsed?this.expand():this.collapse()}trackByFn(te,ot){return ot.id||te}_hasActiveChild(te,ot){const Ct=te.children;if(!Ct)return!1;for(const Bn of Ct)if(Bn.children&&this._hasActiveChild(Bn,ot)||Bn.link&&this._router.isActive(Bn.link,Bn.exactMatch||!1))return!0;return!1}_isChildrenOf(te,ot){const Ct=te.children;if(!Ct)return!1;if(Ct.indexOf(ot)>-1)return!0;for(const Bn of Ct)if(Bn.children&&this._isChildrenOf(Bn,ot))return!0;return!1}static{this.\u0275fac=function(ot){return new(ot||Q)}}static{this.\u0275cmp=a.VBU({type:Q,selectors:[["angor-vertical-navigation-collapsable-item"]],hostVars:2,hostBindings:function(ot,Ct){2&ot&&a.HbH(Ct.classList)},inputs:{autoCollapse:"autoCollapse",item:"item",name:"name"},decls:11,vars:14,consts:[[1,"angor-vertical-navigation-item-wrapper",3,"ngClass"],[1,"angor-vertical-navigation-item",3,"click","ngClass","matTooltip"],[1,"angor-vertical-navigation-item-icon",3,"ngClass","svgIcon"],[1,"angor-vertical-navigation-item-title-wrapper"],[1,"angor-vertical-navigation-item-title"],[3,"ngClass"],[1,"angor-vertical-navigation-item-subtitle"],[1,"angor-vertical-navigation-item-badge"],[1,"angor-vertical-navigation-item-arrow","icon-size-4",3,"svgIcon"],[1,"angor-vertical-navigation-item-children"],[1,"angor-vertical-navigation-item-badge-content",3,"ngClass"],[3,"item","name"],[3,"item","name","autoCollapse"]],template:function(ot,Ct){1&ot&&(a.j41(0,"div",0)(1,"div",1),a.bIt("click",function(){return Ct.toggleCollapsable()}),a.DNE(2,Tt,1,2,"mat-icon",2),a.j41(3,"div",3)(4,"div",4)(5,"span",5),a.EFF(6),a.k0s()(),a.DNE(7,nt,3,2,"div",6),a.k0s(),a.DNE(8,Rt,3,2,"div",7),a.nrm(9,"mat-icon",8),a.k0s()(),a.DNE(10,ai,3,1,"div",9)),2&ot&&(a.AVh("angor-vertical-navigation-item-has-subtitle",!!Ct.item.subtitle),a.Y8G("ngClass",null==Ct.item.classes?null:Ct.item.classes.wrapper),a.R7$(),a.Y8G("ngClass",a.eq3(12,Jt,Ct.item.disabled))("matTooltip",Ct.item.tooltip||""),a.R7$(),a.vxM(Ct.item.icon?2:-1),a.R7$(3),a.Y8G("ngClass",null==Ct.item.classes?null:Ct.item.classes.title),a.R7$(),a.SpI(" ",Ct.item.title," "),a.R7$(),a.vxM(Ct.item.subtitle?7:-1),a.R7$(),a.vxM(Ct.item.badge?8:-1),a.R7$(),a.Y8G("svgIcon","heroicons_solid:chevron-right"),a.R7$(),a.vxM(Ct.isCollapsed?-1:10))},dependencies:()=>[Q,T.YU,O.uc,O.oV,S.m_,S.An,Vr,vt,hi,Wt],encapsulation:2,data:{animation:i.F},changeDetection:0})}}return Q})();const fo=(Q,et,te)=>({"angor-vertical-navigation-item-active":Q,"angor-vertical-navigation-item-disabled":et,"angor-vertical-navigation-item-active-forced":te});function Jo(Q,et){if(1&Q&&a.nrm(0,"mat-icon",2),2&Q){const te=a.XpG();a.Y8G("ngClass",null==te.item.classes?null:te.item.classes.icon)("svgIcon",te.item.icon)}}function Fo(Q,et){if(1&Q&&(a.j41(0,"div",6)(1,"span",5),a.EFF(2),a.k0s()()),2&Q){const te=a.XpG();a.R7$(),a.Y8G("ngClass",null==te.item.classes?null:te.item.classes.subtitle),a.R7$(),a.SpI(" ",te.item.subtitle," ")}}function oa(Q,et){if(1&Q&&(a.j41(0,"div",7)(1,"div",9),a.EFF(2),a.k0s()()),2&Q){const te=a.XpG();a.R7$(),a.Y8G("ngClass",te.item.badge.classes),a.R7$(),a.SpI(" ",te.item.badge.title," ")}}function ao(Q,et){if(1&Q&&a.nrm(0,"angor-vertical-navigation-basic-item",10),2&Q){const te=a.XpG(2).$implicit,ot=a.XpG(2);a.Y8G("item",te)("name",ot.name)}}function po(Q,et){if(1&Q&&a.nrm(0,"angor-vertical-navigation-collapsable-item",11),2&Q){const te=a.XpG(2).$implicit,ot=a.XpG(2);a.Y8G("item",te)("name",ot.name)("autoCollapse",ot.autoCollapse)}}function Ii(Q,et){if(1&Q&&a.nrm(0,"angor-vertical-navigation-divider-item",10),2&Q){const te=a.XpG(2).$implicit,ot=a.XpG(2);a.Y8G("item",te)("name",ot.name)}}function Io(Q,et){if(1&Q&&a.nrm(0,"angor-vertical-navigation-group-item",10),2&Q){const te=a.XpG(2).$implicit,ot=a.XpG(2);a.Y8G("item",te)("name",ot.name)}}function tt(Q,et){if(1&Q&&a.nrm(0,"angor-vertical-navigation-spacer-item",10),2&Q){const te=a.XpG(2).$implicit,ot=a.XpG(2);a.Y8G("item",te)("name",ot.name)}}function xt(Q,et){if(1&Q&&a.DNE(0,ao,1,2,"angor-vertical-navigation-basic-item",10)(1,po,1,3,"angor-vertical-navigation-collapsable-item",11)(2,Ii,1,2,"angor-vertical-navigation-divider-item",10)(3,Io,1,2,"angor-vertical-navigation-group-item",10)(4,tt,1,2,"angor-vertical-navigation-spacer-item",10),2&Q){const te=a.XpG().$implicit;a.vxM("basic"===te.type?0:-1),a.R7$(),a.vxM("collapsable"===te.type?1:-1),a.R7$(),a.vxM("divider"===te.type?2:-1),a.R7$(),a.vxM("group"===te.type?3:-1),a.R7$(),a.vxM("spacer"===te.type?4:-1)}}function ht(Q,et){if(1&Q&&a.DNE(0,xt,5,5),2&Q){const te=et.$implicit;a.vxM(te.hidden&&!te.hidden(te)||!te.hidden?0:-1)}}function ve(Q,et){if(1&Q&&(a.j41(0,"div",8),a.Z7z(1,ht,1,1,null,null,a.BUC().trackByFn,!0),a.k0s()),2&Q){const te=a.XpG();a.R7$(),a.Dyx(te.item.children)}}let Ye=(()=>{class Q{constructor(){this._changeDetectorRef=(0,a.WQX)(a.gRc),this._router=(0,a.WQX)(L.Ix),this._angorNavigationService=(0,a.WQX)(c),this.active=!1,this._unsubscribeAll=new C.B}ngOnChanges(te){"activeItemId"in te&&this._markIfActive(this._router.url)}ngOnInit(){this._markIfActive(this._router.url),this._router.events.pipe((0,Zi.p)(te=>te instanceof L.wF),(0,Z.Q)(this._unsubscribeAll)).subscribe(te=>{this._markIfActive(te.urlAfterRedirects)}),this._angorVerticalNavigationComponent=this._angorNavigationService.getComponent(this.name),this._angorVerticalNavigationComponent.onRefreshed.pipe((0,Z.Q)(this._unsubscribeAll)).subscribe(()=>{this._changeDetectorRef.markForCheck()})}ngOnDestroy(){this._unsubscribeAll.next(null),this._unsubscribeAll.complete()}trackByFn(te,ot){return ot.id||te}_hasActiveChild(te,ot){const Ct=te.children;if(!Ct)return!1;for(const Bn of Ct){if(Bn.children&&this._hasActiveChild(Bn,ot))return!0;if("basic"===Bn.type&&Bn.link&&this._router.isActive(Bn.link,Bn.exactMatch||!1))return!0}return!1}_markIfActive(te){this.active=this.activeItemId===this.item.id,this._hasActiveChild(this.item,te)&&(this.active=!0),this._changeDetectorRef.markForCheck()}static{this.\u0275fac=function(ot){return new(ot||Q)}}static{this.\u0275cmp=a.VBU({type:Q,selectors:[["angor-vertical-navigation-aside-item"]],inputs:{activeItemId:"activeItemId",autoCollapse:"autoCollapse",item:"item",name:"name",skipChildren:"skipChildren"},features:[a.OA$],decls:10,vars:15,consts:[[1,"angor-vertical-navigation-item-wrapper",3,"ngClass"],[1,"angor-vertical-navigation-item",3,"ngClass","matTooltip"],[1,"angor-vertical-navigation-item-icon",3,"ngClass","svgIcon"],[1,"angor-vertical-navigation-item-title-wrapper"],[1,"angor-vertical-navigation-item-title"],[3,"ngClass"],[1,"angor-vertical-navigation-item-subtitle"],[1,"angor-vertical-navigation-item-badge"],[1,"angor-vertical-navigation-item-children"],[1,"angor-vertical-navigation-item-badge-content",3,"ngClass"],[3,"item","name"],[3,"item","name","autoCollapse"]],template:function(ot,Ct){1&ot&&(a.j41(0,"div",0)(1,"div",1),a.DNE(2,Jo,1,2,"mat-icon",2),a.j41(3,"div",3)(4,"div",4)(5,"span",5),a.EFF(6),a.k0s()(),a.DNE(7,Fo,3,2,"div",6),a.k0s(),a.DNE(8,oa,3,2,"div",7),a.k0s()(),a.DNE(9,ve,3,0,"div",8)),2&ot&&(a.AVh("angor-vertical-navigation-item-has-subtitle",!!Ct.item.subtitle),a.Y8G("ngClass",null==Ct.item.classes?null:Ct.item.classes.wrapper),a.R7$(),a.Y8G("ngClass",a.sMw(11,fo,Ct.active,Ct.item.disabled,Ct.item.active))("matTooltip",Ct.item.tooltip||""),a.R7$(),a.vxM(Ct.item.icon?2:-1),a.R7$(3),a.Y8G("ngClass",null==Ct.item.classes?null:Ct.item.classes.title),a.R7$(),a.SpI(" ",Ct.item.title," "),a.R7$(),a.vxM(Ct.item.subtitle?7:-1),a.R7$(),a.vxM(Ct.item.badge?8:-1),a.R7$(),a.vxM(Ct.skipChildren?-1:9))},dependencies:[T.YU,O.uc,O.oV,S.m_,S.An,Vr,qo,vt,hi,Wt],encapsulation:2,changeDetection:0})}}return Q})();class Ne{constructor(et,te,ot,Ct){this.x=et,this.y=te,this.w=ot,this.h=Ct}}class gt{constructor(et,te){this.x=et,this.y=te}}var Ht=r(3022),kt=r(2147),hn=r(4819);function Dn(Q){return getComputedStyle(Q)}function Cn(Q,et){for(var te in et){var ot=et[te];"number"==typeof ot&&(ot+="px"),Q.style[te]=ot}return Q}function Nn(Q){var et=document.createElement("div");return et.className=Q,et}var jn=typeof Element<"u"&&(Element.prototype.matches||Element.prototype.webkitMatchesSelector||Element.prototype.mozMatchesSelector||Element.prototype.msMatchesSelector);function Jn(Q,et){if(!jn)throw new Error("No element matching method supported");return jn.call(Q,et)}function ar(Q){Q.remove?Q.remove():Q.parentNode&&Q.parentNode.removeChild(Q)}function wr(Q,et){return Array.prototype.filter.call(Q.children,function(te){return Jn(te,et)})}var xr={main:"ps",rtl:"ps__rtl",element:{thumb:function(Q){return"ps__thumb-"+Q},rail:function(Q){return"ps__rail-"+Q},consuming:"ps__child--consume"},state:{focus:"ps--focus",clicking:"ps--clicking",active:function(Q){return"ps--active-"+Q},scrolling:function(Q){return"ps--scrolling-"+Q}}},gi={x:null,y:null};function ni(Q,et){var te=Q.element.classList,ot=xr.state.scrolling(et);te.contains(ot)?clearTimeout(gi[et]):te.add(ot)}function Mi(Q,et){gi[et]=setTimeout(function(){return Q.isAlive&&Q.element.classList.remove(xr.state.scrolling(et))},Q.settings.scrollingThreshold)}var Qr=function(et){this.element=et,this.handlers={}},Pr={isEmpty:{configurable:!0}};Qr.prototype.bind=function(et,te){typeof this.handlers[et]>"u"&&(this.handlers[et]=[]),this.handlers[et].push(te),this.element.addEventListener(et,te,!1)},Qr.prototype.unbind=function(et,te){var ot=this;this.handlers[et]=this.handlers[et].filter(function(Ct){return!(!te||Ct===te)||(ot.element.removeEventListener(et,Ct,!1),!1)})},Qr.prototype.unbindAll=function(){for(var et in this.handlers)this.unbind(et)},Pr.isEmpty.get=function(){var Q=this;return Object.keys(this.handlers).every(function(et){return 0===Q.handlers[et].length})},Object.defineProperties(Qr.prototype,Pr);var Do=function(){this.eventElements=[]};function es(Q){if("function"==typeof window.CustomEvent)return new CustomEvent(Q);var et=document.createEvent("CustomEvent");return et.initCustomEvent(Q,!1,!1,void 0),et}function zs(Q,et,te,ot,Ct){var Bn;if(void 0===ot&&(ot=!0),void 0===Ct&&(Ct=!1),"top"===et)Bn=["contentHeight","containerHeight","scrollTop","y","up","down"];else{if("left"!==et)throw new Error("A proper axis should be provided");Bn=["contentWidth","containerWidth","scrollLeft","x","left","right"]}!function sa(Q,et,te,ot,Ct){var Bn=te[0],On=te[1],Wn=te[2],Qn=te[3],qr=te[4],zi=te[5];void 0===ot&&(ot=!0),void 0===Ct&&(Ct=!1);var Mr=Q.element;Q.reach[Qn]=null,Mr[Wn]<1&&(Q.reach[Qn]="start"),Mr[Wn]>Q[Bn]-Q[On]-1&&(Q.reach[Qn]="end"),et&&(Mr.dispatchEvent(es("ps-scroll-"+Qn)),et<0?Mr.dispatchEvent(es("ps-scroll-"+qr)):et>0&&Mr.dispatchEvent(es("ps-scroll-"+zi)),ot&&function Or(Q,et){ni(Q,et),Mi(Q,et)}(Q,Qn)),Q.reach[Qn]&&(et||Ct)&&Mr.dispatchEvent(es("ps-"+Qn+"-reach-"+Q.reach[Qn]))}(Q,te,Bn,ot,Ct)}function Li(Q){return parseInt(Q,10)||0}Do.prototype.eventElement=function(et){var te=this.eventElements.filter(function(ot){return ot.element===et})[0];return te||(te=new Qr(et),this.eventElements.push(te)),te},Do.prototype.bind=function(et,te,ot){this.eventElement(et).bind(te,ot)},Do.prototype.unbind=function(et,te,ot){var Ct=this.eventElement(et);Ct.unbind(te,ot),Ct.isEmpty&&this.eventElements.splice(this.eventElements.indexOf(Ct),1)},Do.prototype.unbindAll=function(){this.eventElements.forEach(function(et){return et.unbindAll()}),this.eventElements=[]},Do.prototype.once=function(et,te,ot){var Ct=this.eventElement(et),Bn=function(On){Ct.unbind(te,Bn),ot(On)};Ct.bind(te,Bn)};var Ks={isWebKit:typeof document<"u"&&"WebkitAppearance"in document.documentElement.style,supportsTouch:typeof window<"u"&&("ontouchstart"in window||"maxTouchPoints"in window.navigator&&window.navigator.maxTouchPoints>0||window.DocumentTouch&&document instanceof window.DocumentTouch),supportsIePointer:typeof navigator<"u"&&navigator.msMaxTouchPoints,isChrome:typeof navigator<"u"&&/Chrome/i.test(navigator&&navigator.userAgent)};function Oo(Q){var et=Q.element,te=Math.floor(et.scrollTop),ot=et.getBoundingClientRect();Q.containerWidth=Math.floor(ot.width),Q.containerHeight=Math.floor(ot.height),Q.contentWidth=et.scrollWidth,Q.contentHeight=et.scrollHeight,et.contains(Q.scrollbarXRail)||(wr(et,xr.element.rail("x")).forEach(function(Ct){return ar(Ct)}),et.appendChild(Q.scrollbarXRail)),et.contains(Q.scrollbarYRail)||(wr(et,xr.element.rail("y")).forEach(function(Ct){return ar(Ct)}),et.appendChild(Q.scrollbarYRail)),!Q.settings.suppressScrollX&&Q.containerWidth+Q.settings.scrollXMarginOffset=Q.railXWidth-Q.scrollbarXWidth&&(Q.scrollbarXLeft=Q.railXWidth-Q.scrollbarXWidth),Q.scrollbarYTop>=Q.railYHeight-Q.scrollbarYHeight&&(Q.scrollbarYTop=Q.railYHeight-Q.scrollbarYHeight),function No(Q,et){var te={width:et.railXWidth},ot=Math.floor(Q.scrollTop);te.left=et.isRtl?et.negativeScrollAdjustment+Q.scrollLeft+et.containerWidth-et.contentWidth:Q.scrollLeft,et.isScrollbarXUsingBottom?te.bottom=et.scrollbarXBottom-ot:te.top=et.scrollbarXTop+ot,Cn(et.scrollbarXRail,te);var Ct={top:ot,height:et.railYHeight};et.isScrollbarYUsingRight?Ct.right=et.isRtl?et.contentWidth-(et.negativeScrollAdjustment+Q.scrollLeft)-et.scrollbarYRight-et.scrollbarYOuterWidth-9:et.scrollbarYRight-Q.scrollLeft:Ct.left=et.isRtl?et.negativeScrollAdjustment+Q.scrollLeft+2*et.containerWidth-et.contentWidth-et.scrollbarYLeft-et.scrollbarYOuterWidth:et.scrollbarYLeft+Q.scrollLeft,Cn(et.scrollbarYRail,Ct),Cn(et.scrollbarX,{left:et.scrollbarXLeft,width:et.scrollbarXWidth-et.railBorderXWidth}),Cn(et.scrollbarY,{top:et.scrollbarYTop,height:et.scrollbarYHeight-et.railBorderYWidth})}(et,Q),Q.scrollbarXActive?et.classList.add(xr.state.active("x")):(et.classList.remove(xr.state.active("x")),Q.scrollbarXWidth=0,Q.scrollbarXLeft=0,et.scrollLeft=!0===Q.isRtl?Q.contentWidth:0),Q.scrollbarYActive?et.classList.add(xr.state.active("y")):(et.classList.remove(xr.state.active("y")),Q.scrollbarYHeight=0,Q.scrollbarYTop=0,et.scrollTop=0)}function Cs(Q,et){return Q.settings.minScrollbarLength&&(et=Math.max(et,Q.settings.minScrollbarLength)),Q.settings.maxScrollbarLength&&(et=Math.min(et,Q.settings.maxScrollbarLength)),et}var Ko=null;function Go(Q,et){var te=et[0],ot=et[1],Ct=et[2],Bn=et[3],On=et[4],Wn=et[5],Qn=et[6],qr=et[7],zi=et[8],Mr=Q.element,fi=null,zr=null,di=null;function Fi(Ho){Ho.touches&&Ho.touches[0]&&(Ho[Ct]=Ho.touches[0]["page"+qr.toUpperCase()]),Ko===On&&(Mr[Qn]=fi+di*(Ho[Ct]-zr),ni(Q,qr),Oo(Q),Ho.stopPropagation(),Ho.preventDefault())}function Ro(){Mi(Q,qr),Q[zi].classList.remove(xr.state.clicking),document.removeEventListener("mousemove",Fi),document.removeEventListener("mouseup",Ro),document.removeEventListener("touchmove",Fi),document.removeEventListener("touchend",Ro),Ko=null}function jo(Ho){null===Ko&&(Ko=On,fi=Mr[Qn],Ho.touches&&(Ho[Ct]=Ho.touches[0]["page"+qr.toUpperCase()]),zr=Ho[Ct],di=(Q[ot]-Q[te])/(Q[Bn]-Q[Wn]),Ho.touches?(document.addEventListener("touchmove",Fi,{passive:!1}),document.addEventListener("touchend",Ro)):(document.addEventListener("mousemove",Fi),document.addEventListener("mouseup",Ro)),Q[zi].classList.add(xr.state.clicking)),Ho.stopPropagation(),Ho.cancelable&&Ho.preventDefault()}Q[On].addEventListener("mousedown",jo),Q[On].addEventListener("touchstart",jo)}var io={"click-rail":function hs(Q){Q.event.bind(Q.scrollbarY,"mousedown",function(et){return et.stopPropagation()}),Q.event.bind(Q.scrollbarYRail,"mousedown",function(et){var te=et.pageY-window.pageYOffset-Q.scrollbarYRail.getBoundingClientRect().top;Q.element.scrollTop+=(te>Q.scrollbarYTop?1:-1)*Q.containerHeight,Oo(Q),et.stopPropagation()}),Q.event.bind(Q.scrollbarX,"mousedown",function(et){return et.stopPropagation()}),Q.event.bind(Q.scrollbarXRail,"mousedown",function(et){var te=et.pageX-window.pageXOffset-Q.scrollbarXRail.getBoundingClientRect().left;Q.element.scrollLeft+=(te>Q.scrollbarXLeft?1:-1)*Q.containerWidth,Oo(Q),et.stopPropagation()})},"drag-thumb":function mo(Q){Go(Q,["containerHeight","contentHeight","pageY","railYHeight","scrollbarY","scrollbarYHeight","scrollTop","y","scrollbarYRail"]),Go(Q,["containerWidth","contentWidth","pageX","railXWidth","scrollbarX","scrollbarXWidth","scrollLeft","x","scrollbarXRail"])},keyboard:function Rs(Q){var et=Q.element;Q.event.bind(Q.ownerDocument,"keydown",function(Bn){if(!(Bn.isDefaultPrevented&&Bn.isDefaultPrevented()||Bn.defaultPrevented)&&(Jn(et,":hover")||Jn(Q.scrollbarX,":focus")||Jn(Q.scrollbarY,":focus"))){var On=document.activeElement?document.activeElement:Q.ownerDocument.activeElement;if(On){if("IFRAME"===On.tagName)On=On.contentDocument.activeElement;else for(;On.shadowRoot;)On=On.shadowRoot.activeElement;if(function bi(Q){return Jn(Q,"input,[contenteditable]")||Jn(Q,"select,[contenteditable]")||Jn(Q,"textarea,[contenteditable]")||Jn(Q,"button,[contenteditable]")}(On))return}var Wn=0,Qn=0;switch(Bn.which){case 37:Wn=Bn.metaKey?-Q.contentWidth:Bn.altKey?-Q.containerWidth:-30;break;case 38:Qn=Bn.metaKey?Q.contentHeight:Bn.altKey?Q.containerHeight:30;break;case 39:Wn=Bn.metaKey?Q.contentWidth:Bn.altKey?Q.containerWidth:30;break;case 40:Qn=Bn.metaKey?-Q.contentHeight:Bn.altKey?-Q.containerHeight:-30;break;case 32:Qn=Bn.shiftKey?Q.containerHeight:-Q.containerHeight;break;case 33:Qn=Q.containerHeight;break;case 34:Qn=-Q.containerHeight;break;case 36:Qn=Q.contentHeight;break;case 35:Qn=-Q.contentHeight;break;default:return}Q.settings.suppressScrollX&&0!==Wn||Q.settings.suppressScrollY&&0!==Qn||(et.scrollTop-=Qn,et.scrollLeft+=Wn,Oo(Q),function Ct(Bn,On){var Wn=Math.floor(et.scrollTop);if(0===Bn){if(!Q.scrollbarYActive)return!1;if(0===Wn&&On>0||Wn>=Q.contentHeight-Q.containerHeight&&On<0)return!Q.settings.wheelPropagation}var Qn=et.scrollLeft;if(0===On){if(!Q.scrollbarXActive)return!1;if(0===Qn&&Bn<0||Qn>=Q.contentWidth-Q.containerWidth&&Bn>0)return!Q.settings.wheelPropagation}return!0}(Wn,Qn)&&Bn.preventDefault())}})},wheel:function Xr(Q){var et=Q.element;function Bn(On){var Wn=function ot(On){var Wn=On.deltaX,Qn=-1*On.deltaY;return(typeof Wn>"u"||typeof Qn>"u")&&(Wn=-1*On.wheelDeltaX/6,Qn=On.wheelDeltaY/6),On.deltaMode&&1===On.deltaMode&&(Wn*=10,Qn*=10),Wn!=Wn&&Qn!=Qn&&(Wn=0,Qn=On.wheelDelta),On.shiftKey?[-Qn,-Wn]:[Wn,Qn]}(On),Qn=Wn[0],qr=Wn[1];if(!function Ct(On,Wn,Qn){if(!Ks.isWebKit&&et.querySelector("select:focus"))return!0;if(!et.contains(On))return!1;for(var qr=On;qr&&qr!==et;){if(qr.classList.contains(xr.element.consuming))return!0;var zi=Dn(qr);if(Qn&&zi.overflowY.match(/(scroll|auto)/)){var Mr=qr.scrollHeight-qr.clientHeight;if(Mr>0&&(qr.scrollTop>0&&Qn<0||qr.scrollTop0))return!0}if(Wn&&zi.overflowX.match(/(scroll|auto)/)){var fi=qr.scrollWidth-qr.clientWidth;if(fi>0&&(qr.scrollLeft>0&&Wn<0||qr.scrollLeft0))return!0}qr=qr.parentNode}return!1}(On.target,Qn,qr)){var zi=!1;Q.settings.useBothWheelAxes?Q.scrollbarYActive&&!Q.scrollbarXActive?(qr?et.scrollTop-=qr*Q.settings.wheelSpeed:et.scrollTop+=Qn*Q.settings.wheelSpeed,zi=!0):Q.scrollbarXActive&&!Q.scrollbarYActive&&(Qn?et.scrollLeft+=Qn*Q.settings.wheelSpeed:et.scrollLeft-=qr*Q.settings.wheelSpeed,zi=!0):(et.scrollTop-=qr*Q.settings.wheelSpeed,et.scrollLeft+=Qn*Q.settings.wheelSpeed),Oo(Q),zi=zi||function te(On,Wn){var Qn=Math.floor(et.scrollTop),qr=0===et.scrollTop,zi=Qn+et.offsetHeight===et.scrollHeight,Mr=0===et.scrollLeft,fi=et.scrollLeft+et.offsetWidth===et.scrollWidth;return!(Math.abs(Wn)>Math.abs(On)?qr||zi:Mr||fi)||!Q.settings.wheelPropagation}(Qn,qr),zi&&!On.ctrlKey&&(On.stopPropagation(),On.preventDefault())}}typeof window.onwheel<"u"?Q.event.bind(et,"wheel",Bn):typeof window.onmousewheel<"u"&&Q.event.bind(et,"mousewheel",Bn)},touch:function Ds(Q){if(Ks.supportsTouch||Ks.supportsIePointer){var et=Q.element,te={startOffset:{},startTime:0,speed:{},easingLoop:null};Ks.supportsTouch?(Q.event.bind(et,"touchstart",Wn),Q.event.bind(et,"touchmove",qr),Q.event.bind(et,"touchend",zi)):Ks.supportsIePointer&&(window.PointerEvent?(Q.event.bind(et,"pointerdown",Wn),Q.event.bind(et,"pointermove",qr),Q.event.bind(et,"pointerup",zi)):window.MSPointerEvent&&(Q.event.bind(et,"MSPointerDown",Wn),Q.event.bind(et,"MSPointerMove",qr),Q.event.bind(et,"MSPointerUp",zi)))}function Ct(Mr,fi){et.scrollTop-=fi,et.scrollLeft-=Mr,Oo(Q)}function Bn(Mr){return Mr.targetTouches?Mr.targetTouches[0]:Mr}function On(Mr){return!(Mr.target===Q.scrollbarX||Mr.target===Q.scrollbarY||Mr.pointerType&&"pen"===Mr.pointerType&&0===Mr.buttons||!(Mr.targetTouches&&1===Mr.targetTouches.length||Mr.pointerType&&"mouse"!==Mr.pointerType&&Mr.pointerType!==Mr.MSPOINTER_TYPE_MOUSE))}function Wn(Mr){if(On(Mr)){var fi=Bn(Mr);te.startOffset.pageX=fi.pageX,te.startOffset.pageY=fi.pageY,te.startTime=(new Date).getTime(),null!==te.easingLoop&&clearInterval(te.easingLoop)}}function qr(Mr){if(On(Mr)){var fi=Bn(Mr),zr={pageX:fi.pageX,pageY:fi.pageY},di=zr.pageX-te.startOffset.pageX,Fi=zr.pageY-te.startOffset.pageY;if(function Qn(Mr,fi,zr){if(!et.contains(Mr))return!1;for(var di=Mr;di&&di!==et;){if(di.classList.contains(xr.element.consuming))return!0;var Fi=Dn(di);if(zr&&Fi.overflowY.match(/(scroll|auto)/)){var Ro=di.scrollHeight-di.clientHeight;if(Ro>0&&(di.scrollTop>0&&zr<0||di.scrollTop0))return!0}if(fi&&Fi.overflowX.match(/(scroll|auto)/)){var jo=di.scrollWidth-di.clientWidth;if(jo>0&&(di.scrollLeft>0&&fi<0||di.scrollLeft0))return!0}di=di.parentNode}return!1}(Mr.target,di,Fi))return;Ct(di,Fi),te.startOffset=zr;var Ro=(new Date).getTime(),jo=Ro-te.startTime;jo>0&&(te.speed.x=di/jo,te.speed.y=Fi/jo,te.startTime=Ro),function ot(Mr,fi){var zr=Math.floor(et.scrollTop),di=et.scrollLeft,Fi=Math.abs(Mr),Ro=Math.abs(fi);if(Ro>Fi){if(fi<0&&zr===Q.contentHeight-Q.containerHeight||fi>0&&0===zr)return 0===window.scrollY&&fi>0&&Ks.isChrome}else if(Fi>Ro&&(Mr<0&&di===Q.contentWidth-Q.containerWidth||Mr>0&&0===di))return!0;return!0}(di,Fi)&&Mr.cancelable&&Mr.preventDefault()}}function zi(){Q.settings.swipeEasing&&(clearInterval(te.easingLoop),te.easingLoop=setInterval(function(){Q.isInitialized?clearInterval(te.easingLoop):te.speed.x||te.speed.y?Math.abs(te.speed.x)<.01&&Math.abs(te.speed.y)<.01?clearInterval(te.easingLoop):(Ct(30*te.speed.x,30*te.speed.y),te.speed.x*=.8,te.speed.y*=.8):clearInterval(te.easingLoop)},10))}}},fs=function(et,te){var ot=this;if(void 0===te&&(te={}),"string"==typeof et&&(et=document.querySelector(et)),!et||!et.nodeName)throw new Error("no element is specified to initialize PerfectScrollbar");for(var Ct in this.element=et,et.classList.add(xr.main),this.settings={handlers:["click-rail","drag-thumb","keyboard","wheel","touch"],maxScrollbarLength:null,minScrollbarLength:null,scrollingThreshold:1e3,scrollXMarginOffset:0,scrollYMarginOffset:0,suppressScrollX:!1,suppressScrollY:!1,swipeEasing:!0,useBothWheelAxes:!1,wheelPropagation:!0,wheelSpeed:1},te)this.settings[Ct]=te[Ct];this.containerWidth=null,this.containerHeight=null,this.contentWidth=null,this.contentHeight=null;var zi,qr,Bn=function(){return et.classList.add(xr.state.focus)},On=function(){return et.classList.remove(xr.state.focus)};this.isRtl="rtl"===Dn(et).direction,!0===this.isRtl&&et.classList.add(xr.rtl),this.isNegativeScroll=(qr=et.scrollLeft,et.scrollLeft=-1,zi=et.scrollLeft<0,et.scrollLeft=qr,zi),this.negativeScrollAdjustment=this.isNegativeScroll?et.scrollWidth-et.clientWidth:0,this.event=new Do,this.ownerDocument=et.ownerDocument||document,this.scrollbarXRail=Nn(xr.element.rail("x")),et.appendChild(this.scrollbarXRail),this.scrollbarX=Nn(xr.element.thumb("x")),this.scrollbarXRail.appendChild(this.scrollbarX),this.scrollbarX.setAttribute("tabindex",0),this.event.bind(this.scrollbarX,"focus",Bn),this.event.bind(this.scrollbarX,"blur",On),this.scrollbarXActive=null,this.scrollbarXWidth=null,this.scrollbarXLeft=null;var Wn=Dn(this.scrollbarXRail);this.scrollbarXBottom=parseInt(Wn.bottom,10),isNaN(this.scrollbarXBottom)?(this.isScrollbarXUsingBottom=!1,this.scrollbarXTop=Li(Wn.top)):this.isScrollbarXUsingBottom=!0,this.railBorderXWidth=Li(Wn.borderLeftWidth)+Li(Wn.borderRightWidth),Cn(this.scrollbarXRail,{display:"block"}),this.railXMarginWidth=Li(Wn.marginLeft)+Li(Wn.marginRight),Cn(this.scrollbarXRail,{display:""}),this.railXWidth=null,this.railXRatio=null,this.scrollbarYRail=Nn(xr.element.rail("y")),et.appendChild(this.scrollbarYRail),this.scrollbarY=Nn(xr.element.thumb("y")),this.scrollbarYRail.appendChild(this.scrollbarY),this.scrollbarY.setAttribute("tabindex",0),this.event.bind(this.scrollbarY,"focus",Bn),this.event.bind(this.scrollbarY,"blur",On),this.scrollbarYActive=null,this.scrollbarYHeight=null,this.scrollbarYTop=null;var Qn=Dn(this.scrollbarYRail);this.scrollbarYRight=parseInt(Qn.right,10),isNaN(this.scrollbarYRight)?(this.isScrollbarYUsingRight=!1,this.scrollbarYLeft=Li(Qn.left)):this.isScrollbarYUsingRight=!0,this.scrollbarYOuterWidth=this.isRtl?function aa(Q){var et=Dn(Q);return Li(et.width)+Li(et.paddingLeft)+Li(et.paddingRight)+Li(et.borderLeftWidth)+Li(et.borderRightWidth)}(this.scrollbarY):null,this.railBorderYWidth=Li(Qn.borderTopWidth)+Li(Qn.borderBottomWidth),Cn(this.scrollbarYRail,{display:"block"}),this.railYMarginHeight=Li(Qn.marginTop)+Li(Qn.marginBottom),Cn(this.scrollbarYRail,{display:""}),this.railYHeight=null,this.railYRatio=null,this.reach={x:et.scrollLeft<=0?"start":et.scrollLeft>=this.contentWidth-this.containerWidth?"end":null,y:et.scrollTop<=0?"start":et.scrollTop>=this.contentHeight-this.containerHeight?"end":null},this.isAlive=!0,this.settings.handlers.forEach(function(qr){return io[qr](ot)}),this.lastScrollTop=Math.floor(et.scrollTop),this.lastScrollLeft=et.scrollLeft,this.event.bind(this.element,"scroll",function(qr){return ot.onScroll(qr)}),Oo(this)};fs.prototype.update=function(){this.isAlive&&(this.negativeScrollAdjustment=this.isNegativeScroll?this.element.scrollWidth-this.element.clientWidth:0,Cn(this.scrollbarXRail,{display:"block"}),Cn(this.scrollbarYRail,{display:"block"}),this.railXMarginWidth=Li(Dn(this.scrollbarXRail).marginLeft)+Li(Dn(this.scrollbarXRail).marginRight),this.railYMarginHeight=Li(Dn(this.scrollbarYRail).marginTop)+Li(Dn(this.scrollbarYRail).marginBottom),Cn(this.scrollbarXRail,{display:"none"}),Cn(this.scrollbarYRail,{display:"none"}),Oo(this),zs(this,"top",0,!1,!0),zs(this,"left",0,!1,!0),Cn(this.scrollbarXRail,{display:""}),Cn(this.scrollbarYRail,{display:""}))},fs.prototype.onScroll=function(et){this.isAlive&&(Oo(this),zs(this,"top",this.element.scrollTop-this.lastScrollTop),zs(this,"left",this.element.scrollLeft-this.lastScrollLeft),this.lastScrollTop=Math.floor(this.element.scrollTop),this.lastScrollLeft=this.element.scrollLeft)},fs.prototype.destroy=function(){this.isAlive&&(this.event.unbindAll(),ar(this.scrollbarX),ar(this.scrollbarY),ar(this.scrollbarXRail),ar(this.scrollbarYRail),this.removePsClasses(),this.element=null,this.scrollbarX=null,this.scrollbarY=null,this.scrollbarXRail=null,this.scrollbarYRail=null,this.isAlive=!1)},fs.prototype.removePsClasses=function(){this.element.className=this.element.className.split(" ").filter(function(et){return!et.match(/^ps([-_].+|)$/)}).join(" ")};const Xo=fs;var Qa=r(909),_o=r(8627);let Ao=(()=>{class Q{constructor(){this._elementRef=(0,a.WQX)(a.aKT),this._platform=(0,a.WQX)(kt.OD),this.angorScrollbar=!0,this._ps=null,this._unsubscribeAll=new C.B}get elementRef(){return this._elementRef}get ps(){return this._ps}ngOnChanges(te){"angorScrollbar"in te&&(this.angorScrollbar=(0,Ht.he)(te.angorScrollbar.currentValue),this.angorScrollbar?this._initScrollbar():this._destroyScrollbar()),"angorScrollbarOptions"in te&&(this._options=(0,hn.A)({},this._options,te.angorScrollbarOptions.currentValue),this._reinitializeScrollbar())}ngOnInit(){(0,Qa.R)(window,"resize").pipe((0,Z.Q)(this._unsubscribeAll),(0,_o.B)(150)).subscribe(()=>this.update())}ngOnDestroy(){this._destroyScrollbar(),this._unsubscribeAll.next(),this._unsubscribeAll.complete()}isEnabled(){return this.angorScrollbar}update(){this._ps?.update()}destroy(){this.ngOnDestroy()}geometry(te="scroll"){return new Ne(this._elementRef.nativeElement[`${te}Left`],this._elementRef.nativeElement[`${te}Top`],this._elementRef.nativeElement[`${te}Width`],this._elementRef.nativeElement[`${te}Height`])}position(te=!1){return!te&&this._ps?new gt(this._ps.reach.x||0,this._ps.reach.y||0):new gt(this._elementRef.nativeElement.scrollLeft,this._elementRef.nativeElement.scrollTop)}scrollTo(te,ot,Ct){null==ot&&null==Ct?this.animateScrolling("scrollTop",te,Ct):(null!=te&&this.scrollToX(te,Ct),null!=ot&&this.scrollToY(ot,Ct))}scrollToX(te,ot){this.animateScrolling("scrollLeft",te,ot)}scrollToY(te,ot){this.animateScrolling("scrollTop",te,ot)}scrollToTop(te=0,ot){this.animateScrolling("scrollTop",te,ot)}scrollToBottom(te=0,ot){this.animateScrolling("scrollTop",this._elementRef.nativeElement.scrollHeight-this._elementRef.nativeElement.clientHeight-te,ot)}scrollToLeft(te=0,ot){this.animateScrolling("scrollLeft",te,ot)}scrollToRight(te=0,ot){this.animateScrolling("scrollLeft",this._elementRef.nativeElement.scrollWidth-this._elementRef.nativeElement.clientWidth-te,ot)}scrollToElement(te,ot=0,Ct=!1,Bn){const On=this._elementRef.nativeElement.querySelector(te);if(!On)return;const Wn=On.getBoundingClientRect(),Qn=this._elementRef.nativeElement.getBoundingClientRect();this._elementRef.nativeElement.classList.contains("ps--active-x")&&this._scrollToInAxis(Wn.left,Qn.left,"scrollLeft",ot,Ct,Bn),this._elementRef.nativeElement.classList.contains("ps--active-y")&&this._scrollToInAxis(Wn.top,Qn.top,"scrollTop",ot,Ct,Bn)}animateScrolling(te,ot,Ct){this._animation&&window.cancelAnimationFrame(this._animation),!Ct||typeof window>"u"?this._elementRef.nativeElement[te]=ot:ot!==this._elementRef.nativeElement[te]&&this._smoothScroll(te,ot,Ct)}_initScrollbar(){this._ps||this._platform.ANDROID||this._platform.IOS||!this._platform.isBrowser||(this._ps=new Xo(this._elementRef.nativeElement,{...this._options}))}_destroyScrollbar(){this._ps?.destroy(),this._ps=null}_reinitializeScrollbar(){setTimeout(()=>this._destroyScrollbar()),setTimeout(()=>this._initScrollbar())}_scrollToInAxis(te,ot,Ct,Bn,On,Wn){On&&te<=ot-Math.abs(Bn)||this.animateScrolling(Ct,te-ot+this._elementRef.nativeElement[Ct]+Bn,Wn)}_smoothScroll(te,ot,Ct){let Bn=0,On=this._elementRef.nativeElement[te];const Wn=(On-ot)/2;let Qn=performance.now();const qr=zi=>{Bn+=Math.PI/(Ct/(zi-Qn));const Mr=Math.round(ot+Wn+Wn*Math.cos(Bn));this._elementRef.nativeElement[te]===On&&(Bn>=Math.PI?this.animateScrolling(te,ot,0):(this._elementRef.nativeElement[te]=Mr,On=this._elementRef.nativeElement[te],Qn=zi,this._animation=window.requestAnimationFrame(qr)))};window.requestAnimationFrame(qr)}static{this.\u0275fac=function(ot){return new(ot||Q)}}static{this.\u0275dir=a.FsC({type:Q,selectors:[["","angorScrollbar",""]],inputs:{angorScrollbar:"angorScrollbar",angorScrollbarOptions:"angorScrollbarOptions"},exportAs:["angorScrollbar"],features:[a.OA$]})}}return Q})();var lr=r(1204),As=r(9666),Gs=r(7509),_s=r(8136);const la=["navigationContent"],ls=[[["","angorVerticalNavigationHeader",""]],[["","angorVerticalNavigationContentHeader",""]],[["","angorVerticalNavigationFooter",""]]],Vi=["[angorVerticalNavigationHeader]","[angorVerticalNavigationContentHeader]","[angorVerticalNavigationFooter]"],ll=Q=>({wheelPropagation:Q,suppressScrollX:!0}),ca=()=>({wheelPropagation:!1,suppressScrollX:!0});function Ss(Q,et){if(1&Q){const te=a.RV6();a.j41(0,"angor-vertical-navigation-aside-item",10),a.bIt("click",function(){a.eBV(te);const Ct=a.XpG(2).$implicit,Bn=a.XpG();return a.Njj(Bn.toggleAside(Ct))}),a.k0s()}if(2&Q){const te=a.XpG(2).$implicit,ot=a.XpG();a.Y8G("item",te)("name",ot.name)("activeItemId",ot.activeAsideItemId)("autoCollapse",ot.autoCollapse)("skipChildren",!0)}}function Ts(Q,et){if(1&Q&&a.nrm(0,"angor-vertical-navigation-basic-item",8),2&Q){const te=a.XpG(2).$implicit,ot=a.XpG();a.Y8G("item",te)("name",ot.name)}}function Ns(Q,et){if(1&Q&&a.nrm(0,"angor-vertical-navigation-collapsable-item",9),2&Q){const te=a.XpG(2).$implicit,ot=a.XpG();a.Y8G("item",te)("name",ot.name)("autoCollapse",ot.autoCollapse)}}function So(Q,et){if(1&Q&&a.nrm(0,"angor-vertical-navigation-divider-item",8),2&Q){const te=a.XpG(2).$implicit,ot=a.XpG();a.Y8G("item",te)("name",ot.name)}}function Bo(Q,et){if(1&Q&&a.nrm(0,"angor-vertical-navigation-group-item",9),2&Q){const te=a.XpG(2).$implicit,ot=a.XpG();a.Y8G("item",te)("name",ot.name)("autoCollapse",ot.autoCollapse)}}function lo(Q,et){if(1&Q&&a.nrm(0,"angor-vertical-navigation-spacer-item",8),2&Q){const te=a.XpG(2).$implicit,ot=a.XpG();a.Y8G("item",te)("name",ot.name)}}function ps(Q,et){if(1&Q&&a.DNE(0,Ss,1,5,"angor-vertical-navigation-aside-item",7)(1,Ts,1,2,"angor-vertical-navigation-basic-item",8)(2,Ns,1,3,"angor-vertical-navigation-collapsable-item",9)(3,So,1,2,"angor-vertical-navigation-divider-item",8)(4,Bo,1,3,"angor-vertical-navigation-group-item",9)(5,lo,1,2,"angor-vertical-navigation-spacer-item",8),2&Q){const te=a.XpG().$implicit;a.vxM("aside"===te.type?0:-1),a.R7$(),a.vxM("basic"===te.type?1:-1),a.R7$(),a.vxM("collapsable"===te.type?2:-1),a.R7$(),a.vxM("divider"===te.type?3:-1),a.R7$(),a.vxM("group"===te.type?4:-1),a.R7$(),a.vxM("spacer"===te.type?5:-1)}}function Da(Q,et){if(1&Q&&a.DNE(0,ps,6,6),2&Q){const te=et.$implicit;a.vxM(te.hidden&&!te.hidden(te)||!te.hidden?0:-1)}}function Ms(Q,et){if(1&Q&&a.nrm(0,"angor-vertical-navigation-aside-item",9),2&Q){const te=a.XpG(2).$implicit,ot=a.XpG(2);a.Y8G("item",te)("name",ot.name)("autoCollapse",ot.autoCollapse)}}function Us(Q,et){if(1&Q&&a.DNE(0,Ms,1,3,"angor-vertical-navigation-aside-item",9),2&Q){const te=a.XpG().$implicit,ot=a.XpG(2);a.vxM("aside"===te.type&&te.id===ot.activeAsideItemId?0:-1)}}function ua(Q,et){if(1&Q&&a.DNE(0,Us,1,1),2&Q){const te=et.$implicit;a.vxM(te.hidden&&!te.hidden(te)||!te.hidden?0:-1)}}function Ba(Q,et){if(1&Q&&(a.j41(0,"div",6),a.Z7z(1,ua,1,1,null,null,a.BUC().trackByFn,!0),a.k0s()),2&Q){const te=a.XpG();a.Y8G("angorScrollbarOptions",a.lJ4(5,ca))("@fadeInLeft","left"===te.position)("@fadeInRight","right"===te.position)("@fadeOutLeft","left"===te.position)("@fadeOutRight","right"===te.position),a.R7$(),a.Dyx(te.navigation)}}let Aa=(()=>{class Q{constructor(){this._animationBuilder=(0,a.WQX)(lr.S6),this._changeDetectorRef=(0,a.WQX)(a.gRc),this._document=(0,a.WQX)(T.qQ),this._elementRef=(0,a.WQX)(a.aKT),this._renderer2=(0,a.WQX)(a.sFG),this._router=(0,a.WQX)(L.Ix),this._scrollStrategyOptions=(0,a.WQX)(As.Tv),this._angorNavigationService=(0,a.WQX)(c),this._angorUtilsService=(0,a.WQX)(y.Q),this.appearance="default",this.autoCollapse=!0,this.inner=!1,this.mode="side",this.name=this._angorUtilsService.randomId(),this.opened=!0,this.position="left",this.transparentOverlay=!1,this.appearanceChanged=new a.bkB,this.modeChanged=new a.bkB,this.openedChanged=new a.bkB,this.positionChanged=new a.bkB,this.activeAsideItemId=null,this.onCollapsableItemCollapsed=new w.m(1),this.onCollapsableItemExpanded=new w.m(1),this.onRefreshed=new w.m(1),this._animationsEnabled=!1,this._hovered=!1,this._scrollStrategy=this._scrollStrategyOptions.block(),this._unsubscribeAll=new C.B,this._handleAsideOverlayClick=()=>{this.closeAside()},this._handleOverlayClick=()=>{this.close()}}get classList(){return{"angor-vertical-navigation-animations-enabled":this._animationsEnabled,[`angor-vertical-navigation-appearance-${this.appearance}`]:!0,"angor-vertical-navigation-hover":this._hovered,"angor-vertical-navigation-inner":this.inner,"angor-vertical-navigation-mode-over":"over"===this.mode,"angor-vertical-navigation-mode-side":"side"===this.mode,"angor-vertical-navigation-opened":this.opened,"angor-vertical-navigation-position-left":"left"===this.position,"angor-vertical-navigation-position-right":"right"===this.position}}get styleList(){return{visibility:this.opened?"visible":"hidden"}}set angorScrollbarDirectives(te){this._angorScrollbarDirectives=te,0!==te.length&&(this._angorScrollbarDirectivesSubscription&&this._angorScrollbarDirectivesSubscription.unsubscribe(),this._angorScrollbarDirectivesSubscription=(0,Gs.h)(this.onCollapsableItemCollapsed,this.onCollapsableItemExpanded).pipe((0,Z.Q)(this._unsubscribeAll),(0,_s.c)(250)).subscribe(()=>{te.forEach(ot=>{ot.update()})}))}_onMouseenter(){this._enableAnimations(),this._hovered=!0}_onMouseleave(){this._enableAnimations(),this._hovered=!1}ngOnChanges(te){if("appearance"in te&&this.appearanceChanged.next(te.appearance.currentValue),"inner"in te&&(this.inner=(0,Ht.he)(te.inner.currentValue)),"mode"in te){const ot=te.mode.currentValue,Ct=te.mode.previousValue;this._disableAnimations(),"over"===Ct&&"side"===ot&&this._hideOverlay(),"side"===Ct&&"over"===ot&&(this.closeAside(),this.opened&&this._showOverlay()),this.modeChanged.next(ot),setTimeout(()=>{this._enableAnimations()},500)}"navigation"in te&&this._changeDetectorRef.markForCheck(),"opened"in te&&(this.opened=(0,Ht.he)(te.opened.currentValue),this._toggleOpened(this.opened)),"position"in te&&this.positionChanged.next(te.position.currentValue),"transparentOverlay"in te&&(this.transparentOverlay=(0,Ht.he)(te.transparentOverlay.currentValue))}ngOnInit(){""===this.name&&(this.name=this._angorUtilsService.randomId()),this._angorNavigationService.registerComponent(this.name,this),this._router.events.pipe((0,Zi.p)(te=>te instanceof L.wF),(0,Z.Q)(this._unsubscribeAll)).subscribe(()=>{"over"===this.mode&&this.opened&&this.close(),"side"===this.mode&&this.activeAsideItemId&&this.closeAside()})}ngAfterViewInit(){this._mutationObserver=new MutationObserver(te=>{te.forEach(ot=>{const Ct=ot.target;if("class"===ot.attributeName)if(Ct.classList.contains("cdk-global-scrollblock")){const Bn=parseInt(Ct.style.top,10);this._renderer2.setStyle(this._elementRef.nativeElement,"margin-top",`${Math.abs(Bn)}px`)}else this._renderer2.setStyle(this._elementRef.nativeElement,"margin-top",null)})}),this._mutationObserver.observe(this._document.documentElement,{attributes:!0,attributeFilter:["class"]}),setTimeout(()=>{if(this._navigationContentEl)if(this._navigationContentEl.nativeElement.classList.contains("ps"))this._angorScrollbarDirectives.forEach(te=>{te.isEnabled()&&te.scrollToElement(".angor-vertical-navigation-item-active",-120,!0)});else{const te=this._navigationContentEl.nativeElement.querySelector(".angor-vertical-navigation-item-active");te&&te.scrollIntoView()}})}ngOnDestroy(){this._mutationObserver.disconnect(),this.close(),this.closeAside(),this._angorNavigationService.deregisterComponent(this.name),this._unsubscribeAll.next(null),this._unsubscribeAll.complete()}refresh(){this._changeDetectorRef.markForCheck(),this.onRefreshed.next(!0)}open(){this.opened||this._toggleOpened(!0)}close(){this.opened&&(this.closeAside(),this._toggleOpened(!1))}toggle(){this.opened?this.close():this.open()}openAside(te){te.disabled||!te.id||(this.activeAsideItemId=te.id,this._showAsideOverlay(),this._changeDetectorRef.markForCheck())}closeAside(){this.activeAsideItemId=null,this._hideAsideOverlay(),this._changeDetectorRef.markForCheck()}toggleAside(te){this.activeAsideItemId===te.id?this.closeAside():this.openAside(te)}trackByFn(te,ot){return ot.id||te}_enableAnimations(){this._animationsEnabled||(this._animationsEnabled=!0)}_disableAnimations(){this._animationsEnabled&&(this._animationsEnabled=!1)}_showOverlay(){this._asideOverlay||(this._overlay=this._renderer2.createElement("div"),this._overlay.classList.add("angor-vertical-navigation-overlay"),this.transparentOverlay&&this._overlay.classList.add("angor-vertical-navigation-overlay-transparent"),this._renderer2.appendChild(this._elementRef.nativeElement.parentElement,this._overlay),this._scrollStrategy.enable(),this._player=this._animationBuilder.build([(0,lr.i0)("300ms cubic-bezier(0.25, 0.8, 0.25, 1)",(0,lr.iF)({opacity:1}))]).create(this._overlay),this._player.play(),this._overlay.addEventListener("click",this._handleOverlayClick))}_hideOverlay(){this._overlay&&(this._player=this._animationBuilder.build([(0,lr.i0)("300ms cubic-bezier(0.25, 0.8, 0.25, 1)",(0,lr.iF)({opacity:0}))]).create(this._overlay),this._player.play(),this._player.onDone(()=>{this._overlay&&(this._overlay.removeEventListener("click",this._handleOverlayClick),this._overlay.parentNode.removeChild(this._overlay),this._overlay=null),this._scrollStrategy.disable()}))}_showAsideOverlay(){this._asideOverlay||(this._asideOverlay=this._renderer2.createElement("div"),this._asideOverlay.classList.add("angor-vertical-navigation-aside-overlay"),this._renderer2.appendChild(this._elementRef.nativeElement.parentElement,this._asideOverlay),this._player=this._animationBuilder.build([(0,lr.i0)("300ms cubic-bezier(0.25, 0.8, 0.25, 1)",(0,lr.iF)({opacity:1}))]).create(this._asideOverlay),this._player.play(),this._asideOverlay.addEventListener("click",this._handleAsideOverlayClick))}_hideAsideOverlay(){this._asideOverlay&&(this._player=this._animationBuilder.build([(0,lr.i0)("300ms cubic-bezier(0.25, 0.8, 0.25, 1)",(0,lr.iF)({opacity:0}))]).create(this._asideOverlay),this._player.play(),this._player.onDone(()=>{this._asideOverlay&&(this._asideOverlay.removeEventListener("click",this._handleAsideOverlayClick),this._asideOverlay.parentNode.removeChild(this._asideOverlay),this._asideOverlay=null)}))}_toggleOpened(te){this.opened=te,this._enableAnimations(),"over"===this.mode&&(this.opened?this._showOverlay():this._hideOverlay()),this.openedChanged.next(te)}static{this.\u0275fac=function(ot){return new(ot||Q)}}static{this.\u0275cmp=a.VBU({type:Q,selectors:[["angor-vertical-navigation"]],viewQuery:function(ot,Ct){if(1&ot&&(a.GBs(la,5),a.GBs(Ao,5)),2&ot){let Bn;a.mGM(Bn=a.lsd())&&(Ct._navigationContentEl=Bn.first),a.mGM(Bn=a.lsd())&&(Ct.angorScrollbarDirectives=Bn)}},hostVars:4,hostBindings:function(ot,Ct){1&ot&&a.bIt("mouseenter",function(){return Ct._onMouseenter()})("mouseleave",function(){return Ct._onMouseleave()}),2&ot&&(a.Aen(Ct.styleList),a.HbH(Ct.classList))},inputs:{appearance:"appearance",autoCollapse:"autoCollapse",inner:"inner",mode:"mode",name:"name",navigation:"navigation",opened:"opened",position:"position",transparentOverlay:"transparentOverlay"},outputs:{appearanceChanged:"appearanceChanged",modeChanged:"modeChanged",openedChanged:"openedChanged",positionChanged:"positionChanged"},exportAs:["angorVerticalNavigation"],features:[a.OA$],ngContentSelectors:Vi,decls:12,vars:4,consts:[["navigationContent",""],[1,"angor-vertical-navigation-wrapper"],[1,"angor-vertical-navigation-header"],["angorScrollbar","",1,"angor-vertical-navigation-content",3,"angorScrollbarOptions"],[1,"angor-vertical-navigation-content-header"],[1,"angor-vertical-navigation-footer"],["angorScrollbar","",1,"angor-vertical-navigation-aside-wrapper",3,"angorScrollbarOptions"],[3,"item","name","activeItemId","autoCollapse","skipChildren"],[3,"item","name"],[3,"item","name","autoCollapse"],[3,"click","item","name","activeItemId","autoCollapse","skipChildren"]],template:function(ot,Ct){1&ot&&(a.NAR(ls),a.j41(0,"div",1)(1,"div",2),a.SdG(2),a.k0s(),a.j41(3,"div",3,0)(5,"div",4),a.SdG(6,1),a.k0s(),a.Z7z(7,Da,1,1,null,null,Ct.trackByFn,!0),a.k0s(),a.j41(9,"div",5),a.SdG(10,2),a.k0s()(),a.DNE(11,Ba,3,6,"div",6)),2&ot&&(a.R7$(3),a.Y8G("angorScrollbarOptions",a.eq3(2,ll,Ct.inner)),a.R7$(4),a.Dyx(Ct.navigation),a.R7$(4),a.vxM(Ct.activeAsideItemId?11:-1))},dependencies:[Ao,Ye,Vr,qo,vt,hi,Wt],styles:[':root{--angor-vertical-navigation-width: 280px}angor-vertical-navigation{position:sticky;display:flex;flex-direction:column;flex:1 0 auto;top:0;width:var(--angor-vertical-navigation-width);min-width:var(--angor-vertical-navigation-width);max-width:var(--angor-vertical-navigation-width);height:100vh;min-height:100vh;max-height:100vh;z-index:200}angor-vertical-navigation.angor-vertical-navigation-animations-enabled{transition-duration:.4s;transition-timing-function:cubic-bezier(.25,.8,.25,1);transition-property:visibility,margin-left,margin-right,transform,width,max-width,min-width}angor-vertical-navigation.angor-vertical-navigation-animations-enabled .angor-vertical-navigation-wrapper{transition-duration:.4s;transition-timing-function:cubic-bezier(.25,.8,.25,1);transition-property:width,max-width,min-width}angor-vertical-navigation.angor-vertical-navigation-mode-over{position:fixed;top:0;bottom:0}angor-vertical-navigation.angor-vertical-navigation-position-left.angor-vertical-navigation-mode-side{margin-left:calc(var(--angor-vertical-navigation-width) * -1)}angor-vertical-navigation.angor-vertical-navigation-position-left.angor-vertical-navigation-mode-side.angor-vertical-navigation-opened{margin-left:0}angor-vertical-navigation.angor-vertical-navigation-position-left.angor-vertical-navigation-mode-over{left:0;transform:translate3d(-100%,0,0)}angor-vertical-navigation.angor-vertical-navigation-position-left.angor-vertical-navigation-mode-over.angor-vertical-navigation-opened{transform:translateZ(0)}angor-vertical-navigation.angor-vertical-navigation-position-left .angor-vertical-navigation-wrapper{left:0}angor-vertical-navigation.angor-vertical-navigation-position-right.angor-vertical-navigation-mode-side{margin-right:calc(var(--angor-vertical-navigation-width) * -1)}angor-vertical-navigation.angor-vertical-navigation-position-right.angor-vertical-navigation-mode-side.angor-vertical-navigation-opened{margin-right:0}angor-vertical-navigation.angor-vertical-navigation-position-right.angor-vertical-navigation-mode-over{right:0;transform:translate3d(100%,0,0)}angor-vertical-navigation.angor-vertical-navigation-position-right.angor-vertical-navigation-mode-over.angor-vertical-navigation-opened{transform:translateZ(0)}angor-vertical-navigation.angor-vertical-navigation-position-right .angor-vertical-navigation-wrapper{right:0}angor-vertical-navigation.angor-vertical-navigation-inner{position:relative;width:auto;min-width:0;max-width:none;height:auto;min-height:0;max-height:none;box-shadow:none}angor-vertical-navigation.angor-vertical-navigation-inner .angor-vertical-navigation-wrapper{position:relative;overflow:visible;height:auto}angor-vertical-navigation.angor-vertical-navigation-inner .angor-vertical-navigation-wrapper .angor-vertical-navigation-content{overflow:visible!important}angor-vertical-navigation .angor-vertical-navigation-wrapper{position:absolute;display:flex;flex:1 1 auto;flex-direction:column;top:0;bottom:0;width:100%;height:100%;overflow:hidden;z-index:10;background:inherit;box-shadow:inset -1px 0 0 var(--angor-border)}angor-vertical-navigation .angor-vertical-navigation-wrapper .angor-vertical-navigation-content{flex:1 1 auto;overflow-x:hidden;overflow-y:auto;overscroll-behavior:contain}angor-vertical-navigation .angor-vertical-navigation-wrapper .angor-vertical-navigation-content>angor-vertical-navigation-divider-item{margin:24px 0}angor-vertical-navigation .angor-vertical-navigation-wrapper .angor-vertical-navigation-content>angor-vertical-navigation-group-item{margin-top:24px}angor-vertical-navigation .angor-vertical-navigation-aside-wrapper{position:absolute;display:flex;flex:1 1 auto;flex-direction:column;top:0;bottom:0;left:var(--angor-vertical-navigation-width);width:var(--angor-vertical-navigation-width);height:100%;z-index:5;overflow-x:hidden;overflow-y:auto;-webkit-overflow-scrolling:touch;transition-duration:.4s;transition-property:left,right;transition-timing-function:cubic-bezier(.25,.8,.25,1);background:inherit}angor-vertical-navigation .angor-vertical-navigation-aside-wrapper>angor-vertical-navigation-aside-item{padding:24px 0}angor-vertical-navigation .angor-vertical-navigation-aside-wrapper>angor-vertical-navigation-aside-item>.angor-vertical-navigation-item-wrapper{display:none!important}angor-vertical-navigation.angor-vertical-navigation-position-right .angor-vertical-navigation-aside-wrapper{left:auto;right:var(--angor-vertical-navigation-width)}angor-vertical-navigation angor-vertical-navigation-aside-item,angor-vertical-navigation angor-vertical-navigation-basic-item,angor-vertical-navigation angor-vertical-navigation-collapsable-item,angor-vertical-navigation angor-vertical-navigation-divider-item,angor-vertical-navigation angor-vertical-navigation-group-item,angor-vertical-navigation angor-vertical-navigation-spacer-item{display:flex;flex-direction:column;flex:1 0 auto;-webkit-user-select:none;user-select:none}angor-vertical-navigation angor-vertical-navigation-aside-item .angor-vertical-navigation-item-wrapper .angor-vertical-navigation-item,angor-vertical-navigation angor-vertical-navigation-basic-item .angor-vertical-navigation-item-wrapper .angor-vertical-navigation-item,angor-vertical-navigation angor-vertical-navigation-collapsable-item .angor-vertical-navigation-item-wrapper .angor-vertical-navigation-item,angor-vertical-navigation angor-vertical-navigation-divider-item .angor-vertical-navigation-item-wrapper .angor-vertical-navigation-item,angor-vertical-navigation angor-vertical-navigation-group-item .angor-vertical-navigation-item-wrapper .angor-vertical-navigation-item,angor-vertical-navigation angor-vertical-navigation-spacer-item .angor-vertical-navigation-item-wrapper .angor-vertical-navigation-item{position:relative;display:flex;align-items:center;justify-content:flex-start;padding:10px 16px;font-size:13px;font-weight:500;line-height:20px;text-decoration:none;border-radius:6px}angor-vertical-navigation angor-vertical-navigation-aside-item .angor-vertical-navigation-item-wrapper .angor-vertical-navigation-item.angor-vertical-navigation-item-disabled,angor-vertical-navigation angor-vertical-navigation-basic-item .angor-vertical-navigation-item-wrapper .angor-vertical-navigation-item.angor-vertical-navigation-item-disabled,angor-vertical-navigation angor-vertical-navigation-collapsable-item .angor-vertical-navigation-item-wrapper .angor-vertical-navigation-item.angor-vertical-navigation-item-disabled,angor-vertical-navigation angor-vertical-navigation-divider-item .angor-vertical-navigation-item-wrapper .angor-vertical-navigation-item.angor-vertical-navigation-item-disabled,angor-vertical-navigation angor-vertical-navigation-group-item .angor-vertical-navigation-item-wrapper .angor-vertical-navigation-item.angor-vertical-navigation-item-disabled,angor-vertical-navigation angor-vertical-navigation-spacer-item .angor-vertical-navigation-item-wrapper .angor-vertical-navigation-item.angor-vertical-navigation-item-disabled{cursor:default;opacity:.4}angor-vertical-navigation angor-vertical-navigation-aside-item .angor-vertical-navigation-item-wrapper .angor-vertical-navigation-item .angor-vertical-navigation-item-icon,angor-vertical-navigation angor-vertical-navigation-basic-item .angor-vertical-navigation-item-wrapper .angor-vertical-navigation-item .angor-vertical-navigation-item-icon,angor-vertical-navigation angor-vertical-navigation-collapsable-item .angor-vertical-navigation-item-wrapper .angor-vertical-navigation-item .angor-vertical-navigation-item-icon,angor-vertical-navigation angor-vertical-navigation-divider-item .angor-vertical-navigation-item-wrapper .angor-vertical-navigation-item .angor-vertical-navigation-item-icon,angor-vertical-navigation angor-vertical-navigation-group-item .angor-vertical-navigation-item-wrapper .angor-vertical-navigation-item .angor-vertical-navigation-item-icon,angor-vertical-navigation angor-vertical-navigation-spacer-item .angor-vertical-navigation-item-wrapper .angor-vertical-navigation-item .angor-vertical-navigation-item-icon{margin-right:16px}angor-vertical-navigation angor-vertical-navigation-aside-item .angor-vertical-navigation-item-wrapper .angor-vertical-navigation-item .angor-vertical-navigation-item-title-wrapper .angor-vertical-navigation-item-subtitle,angor-vertical-navigation angor-vertical-navigation-basic-item .angor-vertical-navigation-item-wrapper .angor-vertical-navigation-item .angor-vertical-navigation-item-title-wrapper .angor-vertical-navigation-item-subtitle,angor-vertical-navigation angor-vertical-navigation-collapsable-item .angor-vertical-navigation-item-wrapper .angor-vertical-navigation-item .angor-vertical-navigation-item-title-wrapper .angor-vertical-navigation-item-subtitle,angor-vertical-navigation angor-vertical-navigation-divider-item .angor-vertical-navigation-item-wrapper .angor-vertical-navigation-item .angor-vertical-navigation-item-title-wrapper .angor-vertical-navigation-item-subtitle,angor-vertical-navigation angor-vertical-navigation-group-item .angor-vertical-navigation-item-wrapper .angor-vertical-navigation-item .angor-vertical-navigation-item-title-wrapper .angor-vertical-navigation-item-subtitle,angor-vertical-navigation angor-vertical-navigation-spacer-item .angor-vertical-navigation-item-wrapper .angor-vertical-navigation-item .angor-vertical-navigation-item-title-wrapper .angor-vertical-navigation-item-subtitle{font-size:11px;line-height:1.5}angor-vertical-navigation angor-vertical-navigation-aside-item .angor-vertical-navigation-item-wrapper .angor-vertical-navigation-item .angor-vertical-navigation-item-badge,angor-vertical-navigation angor-vertical-navigation-basic-item .angor-vertical-navigation-item-wrapper .angor-vertical-navigation-item .angor-vertical-navigation-item-badge,angor-vertical-navigation angor-vertical-navigation-collapsable-item .angor-vertical-navigation-item-wrapper .angor-vertical-navigation-item .angor-vertical-navigation-item-badge,angor-vertical-navigation angor-vertical-navigation-divider-item .angor-vertical-navigation-item-wrapper .angor-vertical-navigation-item .angor-vertical-navigation-item-badge,angor-vertical-navigation angor-vertical-navigation-group-item .angor-vertical-navigation-item-wrapper .angor-vertical-navigation-item .angor-vertical-navigation-item-badge,angor-vertical-navigation angor-vertical-navigation-spacer-item .angor-vertical-navigation-item-wrapper .angor-vertical-navigation-item .angor-vertical-navigation-item-badge{margin-left:auto}angor-vertical-navigation angor-vertical-navigation-aside-item .angor-vertical-navigation-item-wrapper .angor-vertical-navigation-item .angor-vertical-navigation-item-badge .angor-vertical-navigation-item-badge-content,angor-vertical-navigation angor-vertical-navigation-basic-item .angor-vertical-navigation-item-wrapper .angor-vertical-navigation-item .angor-vertical-navigation-item-badge .angor-vertical-navigation-item-badge-content,angor-vertical-navigation angor-vertical-navigation-collapsable-item .angor-vertical-navigation-item-wrapper .angor-vertical-navigation-item .angor-vertical-navigation-item-badge .angor-vertical-navigation-item-badge-content,angor-vertical-navigation angor-vertical-navigation-divider-item .angor-vertical-navigation-item-wrapper .angor-vertical-navigation-item .angor-vertical-navigation-item-badge .angor-vertical-navigation-item-badge-content,angor-vertical-navigation angor-vertical-navigation-group-item .angor-vertical-navigation-item-wrapper .angor-vertical-navigation-item .angor-vertical-navigation-item-badge .angor-vertical-navigation-item-badge-content,angor-vertical-navigation angor-vertical-navigation-spacer-item .angor-vertical-navigation-item-wrapper .angor-vertical-navigation-item .angor-vertical-navigation-item-badge .angor-vertical-navigation-item-badge-content{display:flex;align-items:center;justify-content:center;font-size:10px;font-weight:600;white-space:nowrap;height:20px}angor-vertical-navigation angor-vertical-navigation-aside-item>.angor-vertical-navigation-item-wrapper,angor-vertical-navigation angor-vertical-navigation-basic-item>.angor-vertical-navigation-item-wrapper,angor-vertical-navigation angor-vertical-navigation-collapsable-item>.angor-vertical-navigation-item-wrapper,angor-vertical-navigation angor-vertical-navigation-group-item>.angor-vertical-navigation-item-wrapper{margin:0 12px}angor-vertical-navigation angor-vertical-navigation-aside-item,angor-vertical-navigation angor-vertical-navigation-basic-item,angor-vertical-navigation angor-vertical-navigation-collapsable-item{margin-bottom:4px}angor-vertical-navigation angor-vertical-navigation-aside-item .angor-vertical-navigation-item,angor-vertical-navigation angor-vertical-navigation-basic-item .angor-vertical-navigation-item,angor-vertical-navigation angor-vertical-navigation-collapsable-item .angor-vertical-navigation-item{cursor:pointer}angor-vertical-navigation angor-vertical-navigation-collapsable-item>.angor-vertical-navigation-item-wrapper .angor-vertical-navigation-item .angor-vertical-navigation-item-badge+.angor-vertical-navigation-item-arrow{margin-left:8px}angor-vertical-navigation angor-vertical-navigation-collapsable-item>.angor-vertical-navigation-item-wrapper .angor-vertical-navigation-item .angor-vertical-navigation-item-arrow{height:20px;line-height:20px;margin-left:auto;transition:transform .3s cubic-bezier(.25,.8,.25,1),color 375ms cubic-bezier(.25,.8,.25,1)}angor-vertical-navigation angor-vertical-navigation-collapsable-item.angor-vertical-navigation-item-expanded>.angor-vertical-navigation-item-wrapper .angor-vertical-navigation-item .angor-vertical-navigation-item-arrow{transform:rotate(90deg)}angor-vertical-navigation angor-vertical-navigation-collapsable-item>.angor-vertical-navigation-item-children>*:first-child{margin-top:6px}angor-vertical-navigation angor-vertical-navigation-collapsable-item>.angor-vertical-navigation-item-children>*:last-child{padding-bottom:6px}angor-vertical-navigation angor-vertical-navigation-collapsable-item>.angor-vertical-navigation-item-children>*:last-child>.angor-vertical-navigation-item-children>*:last-child{padding-bottom:0}angor-vertical-navigation angor-vertical-navigation-collapsable-item>.angor-vertical-navigation-item-children .angor-vertical-navigation-item{padding:10px 16px}angor-vertical-navigation angor-vertical-navigation-collapsable-item .angor-vertical-navigation-item-children{overflow:hidden}angor-vertical-navigation angor-vertical-navigation-collapsable-item .angor-vertical-navigation-item-children .angor-vertical-navigation-item{padding-left:56px}angor-vertical-navigation angor-vertical-navigation-collapsable-item .angor-vertical-navigation-item-children .angor-vertical-navigation-item-children .angor-vertical-navigation-item{padding-left:72px}angor-vertical-navigation angor-vertical-navigation-collapsable-item .angor-vertical-navigation-item-children .angor-vertical-navigation-item-children .angor-vertical-navigation-item-children .angor-vertical-navigation-item{padding-left:88px}angor-vertical-navigation angor-vertical-navigation-collapsable-item .angor-vertical-navigation-item-children .angor-vertical-navigation-item-children .angor-vertical-navigation-item-children .angor-vertical-navigation-item-children .angor-vertical-navigation-item{padding-left:104px}angor-vertical-navigation angor-vertical-navigation-divider-item{margin:12px 0}angor-vertical-navigation angor-vertical-navigation-divider-item .angor-vertical-navigation-item-wrapper{height:1px;box-shadow:0 1px}angor-vertical-navigation angor-vertical-navigation-group-item>.angor-vertical-navigation-item-wrapper .angor-vertical-navigation-item .angor-vertical-navigation-item-badge,angor-vertical-navigation angor-vertical-navigation-group-item>.angor-vertical-navigation-item-wrapper .angor-vertical-navigation-item .angor-vertical-navigation-item-icon{display:none!important}angor-vertical-navigation angor-vertical-navigation-group-item>.angor-vertical-navigation-item-wrapper .angor-vertical-navigation-item .angor-vertical-navigation-item-title-wrapper .angor-vertical-navigation-item-title{font-size:12px;font-weight:600;letter-spacing:.05em;text-transform:uppercase}angor-vertical-navigation angor-vertical-navigation-spacer-item{margin:6px 0}.angor-vertical-navigation-overlay{position:absolute;inset:0;z-index:170;opacity:0;background-color:#0009}.angor-vertical-navigation-overlay+.angor-vertical-navigation-aside-overlay{background-color:transparent}.angor-vertical-navigation-aside-overlay{position:absolute;inset:0;z-index:169;opacity:0;background-color:#0000004d}angor-vertical-navigation-aside-item .angor-vertical-navigation-item-wrapper .angor-vertical-navigation-item,angor-vertical-navigation-basic-item .angor-vertical-navigation-item-wrapper .angor-vertical-navigation-item,angor-vertical-navigation-collapsable-item .angor-vertical-navigation-item-wrapper .angor-vertical-navigation-item,angor-vertical-navigation-group-item .angor-vertical-navigation-item-wrapper .angor-vertical-navigation-item{color:currentColor}angor-vertical-navigation-aside-item .angor-vertical-navigation-item-wrapper .angor-vertical-navigation-item .angor-vertical-navigation-item-icon,angor-vertical-navigation-basic-item .angor-vertical-navigation-item-wrapper .angor-vertical-navigation-item .angor-vertical-navigation-item-icon,angor-vertical-navigation-collapsable-item .angor-vertical-navigation-item-wrapper .angor-vertical-navigation-item .angor-vertical-navigation-item-icon,angor-vertical-navigation-group-item .angor-vertical-navigation-item-wrapper .angor-vertical-navigation-item .angor-vertical-navigation-item-icon{color:currentColor;opacity:.6}angor-vertical-navigation-aside-item .angor-vertical-navigation-item-wrapper .angor-vertical-navigation-item .angor-vertical-navigation-item-title-wrapper .angor-vertical-navigation-item-title,angor-vertical-navigation-basic-item .angor-vertical-navigation-item-wrapper .angor-vertical-navigation-item .angor-vertical-navigation-item-title-wrapper .angor-vertical-navigation-item-title,angor-vertical-navigation-collapsable-item .angor-vertical-navigation-item-wrapper .angor-vertical-navigation-item .angor-vertical-navigation-item-title-wrapper .angor-vertical-navigation-item-title,angor-vertical-navigation-group-item .angor-vertical-navigation-item-wrapper .angor-vertical-navigation-item .angor-vertical-navigation-item-title-wrapper .angor-vertical-navigation-item-title{color:currentColor;opacity:.8}angor-vertical-navigation-aside-item .angor-vertical-navigation-item-wrapper .angor-vertical-navigation-item .angor-vertical-navigation-item-title-wrapper .angor-vertical-navigation-item-subtitle,angor-vertical-navigation-basic-item .angor-vertical-navigation-item-wrapper .angor-vertical-navigation-item .angor-vertical-navigation-item-title-wrapper .angor-vertical-navigation-item-subtitle,angor-vertical-navigation-collapsable-item .angor-vertical-navigation-item-wrapper .angor-vertical-navigation-item .angor-vertical-navigation-item-title-wrapper .angor-vertical-navigation-item-subtitle,angor-vertical-navigation-group-item .angor-vertical-navigation-item-wrapper .angor-vertical-navigation-item .angor-vertical-navigation-item-title-wrapper .angor-vertical-navigation-item-subtitle{color:currentColor;opacity:.5}angor-vertical-navigation-aside-item>.angor-vertical-navigation-item-wrapper .angor-vertical-navigation-item:not(.angor-vertical-navigation-item-disabled).angor-vertical-navigation-item-active,angor-vertical-navigation-aside-item>.angor-vertical-navigation-item-wrapper .angor-vertical-navigation-item:not(.angor-vertical-navigation-item-disabled).angor-vertical-navigation-item-active-forced,angor-vertical-navigation-basic-item>.angor-vertical-navigation-item-wrapper .angor-vertical-navigation-item:not(.angor-vertical-navigation-item-disabled).angor-vertical-navigation-item-active,angor-vertical-navigation-basic-item>.angor-vertical-navigation-item-wrapper .angor-vertical-navigation-item:not(.angor-vertical-navigation-item-disabled).angor-vertical-navigation-item-active-forced,angor-vertical-navigation-collapsable-item>.angor-vertical-navigation-item-wrapper .angor-vertical-navigation-item:not(.angor-vertical-navigation-item-disabled).angor-vertical-navigation-item-active,angor-vertical-navigation-collapsable-item>.angor-vertical-navigation-item-wrapper .angor-vertical-navigation-item:not(.angor-vertical-navigation-item-disabled).angor-vertical-navigation-item-active-forced{background-color:rgb(3 33 40 / var(--tw-bg-opacity, 1));--tw-bg-opacity: .05}angor-vertical-navigation-aside-item>.angor-vertical-navigation-item-wrapper .angor-vertical-navigation-item:not(.angor-vertical-navigation-item-disabled).angor-vertical-navigation-item-active:is(.dark *),angor-vertical-navigation-aside-item>.angor-vertical-navigation-item-wrapper .angor-vertical-navigation-item:not(.angor-vertical-navigation-item-disabled).angor-vertical-navigation-item-active-forced:is(.dark *),angor-vertical-navigation-basic-item>.angor-vertical-navigation-item-wrapper .angor-vertical-navigation-item:not(.angor-vertical-navigation-item-disabled).angor-vertical-navigation-item-active:is(.dark *),angor-vertical-navigation-basic-item>.angor-vertical-navigation-item-wrapper .angor-vertical-navigation-item:not(.angor-vertical-navigation-item-disabled).angor-vertical-navigation-item-active-forced:is(.dark *),angor-vertical-navigation-collapsable-item>.angor-vertical-navigation-item-wrapper .angor-vertical-navigation-item:not(.angor-vertical-navigation-item-disabled).angor-vertical-navigation-item-active:is(.dark *),angor-vertical-navigation-collapsable-item>.angor-vertical-navigation-item-wrapper .angor-vertical-navigation-item:not(.angor-vertical-navigation-item-disabled).angor-vertical-navigation-item-active-forced:is(.dark *){background-color:rgb(255 255 255 / var(--tw-bg-opacity, 1));--tw-bg-opacity: .12}angor-vertical-navigation-aside-item>.angor-vertical-navigation-item-wrapper .angor-vertical-navigation-item:not(.angor-vertical-navigation-item-disabled).angor-vertical-navigation-item-active .angor-vertical-navigation-item-icon,angor-vertical-navigation-aside-item>.angor-vertical-navigation-item-wrapper .angor-vertical-navigation-item:not(.angor-vertical-navigation-item-disabled).angor-vertical-navigation-item-active-forced .angor-vertical-navigation-item-icon,angor-vertical-navigation-basic-item>.angor-vertical-navigation-item-wrapper .angor-vertical-navigation-item:not(.angor-vertical-navigation-item-disabled).angor-vertical-navigation-item-active .angor-vertical-navigation-item-icon,angor-vertical-navigation-basic-item>.angor-vertical-navigation-item-wrapper .angor-vertical-navigation-item:not(.angor-vertical-navigation-item-disabled).angor-vertical-navigation-item-active-forced .angor-vertical-navigation-item-icon,angor-vertical-navigation-collapsable-item>.angor-vertical-navigation-item-wrapper .angor-vertical-navigation-item:not(.angor-vertical-navigation-item-disabled).angor-vertical-navigation-item-active .angor-vertical-navigation-item-icon,angor-vertical-navigation-collapsable-item>.angor-vertical-navigation-item-wrapper .angor-vertical-navigation-item:not(.angor-vertical-navigation-item-disabled).angor-vertical-navigation-item-active-forced .angor-vertical-navigation-item-icon{opacity:1}angor-vertical-navigation-aside-item>.angor-vertical-navigation-item-wrapper .angor-vertical-navigation-item:not(.angor-vertical-navigation-item-disabled).angor-vertical-navigation-item-active .angor-vertical-navigation-item-title,angor-vertical-navigation-aside-item>.angor-vertical-navigation-item-wrapper .angor-vertical-navigation-item:not(.angor-vertical-navigation-item-disabled).angor-vertical-navigation-item-active-forced .angor-vertical-navigation-item-title,angor-vertical-navigation-basic-item>.angor-vertical-navigation-item-wrapper .angor-vertical-navigation-item:not(.angor-vertical-navigation-item-disabled).angor-vertical-navigation-item-active .angor-vertical-navigation-item-title,angor-vertical-navigation-basic-item>.angor-vertical-navigation-item-wrapper .angor-vertical-navigation-item:not(.angor-vertical-navigation-item-disabled).angor-vertical-navigation-item-active-forced .angor-vertical-navigation-item-title,angor-vertical-navigation-collapsable-item>.angor-vertical-navigation-item-wrapper .angor-vertical-navigation-item:not(.angor-vertical-navigation-item-disabled).angor-vertical-navigation-item-active .angor-vertical-navigation-item-title,angor-vertical-navigation-collapsable-item>.angor-vertical-navigation-item-wrapper .angor-vertical-navigation-item:not(.angor-vertical-navigation-item-disabled).angor-vertical-navigation-item-active-forced .angor-vertical-navigation-item-title{opacity:1}angor-vertical-navigation-aside-item>.angor-vertical-navigation-item-wrapper .angor-vertical-navigation-item:not(.angor-vertical-navigation-item-disabled).angor-vertical-navigation-item-active .angor-vertical-navigation-item-subtitle,angor-vertical-navigation-aside-item>.angor-vertical-navigation-item-wrapper .angor-vertical-navigation-item:not(.angor-vertical-navigation-item-disabled).angor-vertical-navigation-item-active-forced .angor-vertical-navigation-item-subtitle,angor-vertical-navigation-basic-item>.angor-vertical-navigation-item-wrapper .angor-vertical-navigation-item:not(.angor-vertical-navigation-item-disabled).angor-vertical-navigation-item-active .angor-vertical-navigation-item-subtitle,angor-vertical-navigation-basic-item>.angor-vertical-navigation-item-wrapper .angor-vertical-navigation-item:not(.angor-vertical-navigation-item-disabled).angor-vertical-navigation-item-active-forced .angor-vertical-navigation-item-subtitle,angor-vertical-navigation-collapsable-item>.angor-vertical-navigation-item-wrapper .angor-vertical-navigation-item:not(.angor-vertical-navigation-item-disabled).angor-vertical-navigation-item-active .angor-vertical-navigation-item-subtitle,angor-vertical-navigation-collapsable-item>.angor-vertical-navigation-item-wrapper .angor-vertical-navigation-item:not(.angor-vertical-navigation-item-disabled).angor-vertical-navigation-item-active-forced .angor-vertical-navigation-item-subtitle{opacity:1}angor-vertical-navigation-aside-item>.angor-vertical-navigation-item-wrapper .angor-vertical-navigation-item:not(.angor-vertical-navigation-item-active-forced):not(.angor-vertical-navigation-item-active):not(.angor-vertical-navigation-item-disabled):hover,angor-vertical-navigation-basic-item>.angor-vertical-navigation-item-wrapper .angor-vertical-navigation-item:not(.angor-vertical-navigation-item-active-forced):not(.angor-vertical-navigation-item-active):not(.angor-vertical-navigation-item-disabled):hover,angor-vertical-navigation-collapsable-item>.angor-vertical-navigation-item-wrapper .angor-vertical-navigation-item:not(.angor-vertical-navigation-item-active-forced):not(.angor-vertical-navigation-item-active):not(.angor-vertical-navigation-item-disabled):hover{background-color:rgb(3 33 40 / var(--tw-bg-opacity, 1));--tw-bg-opacity: .05}angor-vertical-navigation-aside-item>.angor-vertical-navigation-item-wrapper .angor-vertical-navigation-item:not(.angor-vertical-navigation-item-active-forced):not(.angor-vertical-navigation-item-active):not(.angor-vertical-navigation-item-disabled):hover:is(.dark *),angor-vertical-navigation-basic-item>.angor-vertical-navigation-item-wrapper .angor-vertical-navigation-item:not(.angor-vertical-navigation-item-active-forced):not(.angor-vertical-navigation-item-active):not(.angor-vertical-navigation-item-disabled):hover:is(.dark *),angor-vertical-navigation-collapsable-item>.angor-vertical-navigation-item-wrapper .angor-vertical-navigation-item:not(.angor-vertical-navigation-item-active-forced):not(.angor-vertical-navigation-item-active):not(.angor-vertical-navigation-item-disabled):hover:is(.dark *){background-color:rgb(255 255 255 / var(--tw-bg-opacity, 1));--tw-bg-opacity: .12}angor-vertical-navigation-aside-item>.angor-vertical-navigation-item-wrapper .angor-vertical-navigation-item:not(.angor-vertical-navigation-item-active-forced):not(.angor-vertical-navigation-item-active):not(.angor-vertical-navigation-item-disabled):hover .angor-vertical-navigation-item-icon,angor-vertical-navigation-basic-item>.angor-vertical-navigation-item-wrapper .angor-vertical-navigation-item:not(.angor-vertical-navigation-item-active-forced):not(.angor-vertical-navigation-item-active):not(.angor-vertical-navigation-item-disabled):hover .angor-vertical-navigation-item-icon,angor-vertical-navigation-collapsable-item>.angor-vertical-navigation-item-wrapper .angor-vertical-navigation-item:not(.angor-vertical-navigation-item-active-forced):not(.angor-vertical-navigation-item-active):not(.angor-vertical-navigation-item-disabled):hover .angor-vertical-navigation-item-icon{opacity:1}angor-vertical-navigation-aside-item>.angor-vertical-navigation-item-wrapper .angor-vertical-navigation-item:not(.angor-vertical-navigation-item-active-forced):not(.angor-vertical-navigation-item-active):not(.angor-vertical-navigation-item-disabled):hover .angor-vertical-navigation-item-title,angor-vertical-navigation-aside-item>.angor-vertical-navigation-item-wrapper .angor-vertical-navigation-item:not(.angor-vertical-navigation-item-active-forced):not(.angor-vertical-navigation-item-active):not(.angor-vertical-navigation-item-disabled):hover .angor-vertical-navigation-item-arrow,angor-vertical-navigation-basic-item>.angor-vertical-navigation-item-wrapper .angor-vertical-navigation-item:not(.angor-vertical-navigation-item-active-forced):not(.angor-vertical-navigation-item-active):not(.angor-vertical-navigation-item-disabled):hover .angor-vertical-navigation-item-title,angor-vertical-navigation-basic-item>.angor-vertical-navigation-item-wrapper .angor-vertical-navigation-item:not(.angor-vertical-navigation-item-active-forced):not(.angor-vertical-navigation-item-active):not(.angor-vertical-navigation-item-disabled):hover .angor-vertical-navigation-item-arrow,angor-vertical-navigation-collapsable-item>.angor-vertical-navigation-item-wrapper .angor-vertical-navigation-item:not(.angor-vertical-navigation-item-active-forced):not(.angor-vertical-navigation-item-active):not(.angor-vertical-navigation-item-disabled):hover .angor-vertical-navigation-item-title,angor-vertical-navigation-collapsable-item>.angor-vertical-navigation-item-wrapper .angor-vertical-navigation-item:not(.angor-vertical-navigation-item-active-forced):not(.angor-vertical-navigation-item-active):not(.angor-vertical-navigation-item-disabled):hover .angor-vertical-navigation-item-arrow{opacity:1}angor-vertical-navigation-aside-item>.angor-vertical-navigation-item-wrapper .angor-vertical-navigation-item:not(.angor-vertical-navigation-item-active-forced):not(.angor-vertical-navigation-item-active):not(.angor-vertical-navigation-item-disabled):hover .angor-vertical-navigation-item-subtitle,angor-vertical-navigation-basic-item>.angor-vertical-navigation-item-wrapper .angor-vertical-navigation-item:not(.angor-vertical-navigation-item-active-forced):not(.angor-vertical-navigation-item-active):not(.angor-vertical-navigation-item-disabled):hover .angor-vertical-navigation-item-subtitle,angor-vertical-navigation-collapsable-item>.angor-vertical-navigation-item-wrapper .angor-vertical-navigation-item:not(.angor-vertical-navigation-item-active-forced):not(.angor-vertical-navigation-item-active):not(.angor-vertical-navigation-item-disabled):hover .angor-vertical-navigation-item-subtitle{opacity:1}angor-vertical-navigation-collapsable-item.angor-vertical-navigation-item-expanded>.angor-vertical-navigation-item-wrapper .angor-vertical-navigation-item .angor-vertical-navigation-item-icon{opacity:1}angor-vertical-navigation-collapsable-item.angor-vertical-navigation-item-expanded>.angor-vertical-navigation-item-wrapper .angor-vertical-navigation-item .angor-vertical-navigation-item-title,angor-vertical-navigation-collapsable-item.angor-vertical-navigation-item-expanded>.angor-vertical-navigation-item-wrapper .angor-vertical-navigation-item .angor-vertical-navigation-item-arrow{opacity:1}angor-vertical-navigation-collapsable-item.angor-vertical-navigation-item-expanded>.angor-vertical-navigation-item-wrapper .angor-vertical-navigation-item .angor-vertical-navigation-item-subtitle{opacity:1}angor-vertical-navigation-group-item>.angor-vertical-navigation-item-wrapper .angor-vertical-navigation-item .angor-vertical-navigation-item-title-wrapper .angor-vertical-navigation-item-title{--tw-text-opacity: 1;color:rgba(var(--angor-primary-600-rgb),var(--tw-text-opacity, 1));opacity:1}angor-vertical-navigation-group-item>.angor-vertical-navigation-item-wrapper .angor-vertical-navigation-item .angor-vertical-navigation-item-title-wrapper .angor-vertical-navigation-item-title:is(.dark *){--tw-text-opacity: 1;color:rgba(var(--angor-primary-400-rgb),var(--tw-text-opacity, 1))}:root{--angor-vertical-navigation-compact-width: 112px}angor-vertical-navigation.angor-vertical-navigation-appearance-compact{width:var(--angor-vertical-navigation-compact-width);min-width:var(--angor-vertical-navigation-compact-width);max-width:var(--angor-vertical-navigation-compact-width)}angor-vertical-navigation.angor-vertical-navigation-appearance-compact.angor-vertical-navigation-position-left.angor-vertical-navigation-mode-side{margin-left:calc(var(--angor-vertical-navigation-compact-width) * -1)}angor-vertical-navigation.angor-vertical-navigation-appearance-compact.angor-vertical-navigation-position-left.angor-vertical-navigation-opened{margin-left:0}angor-vertical-navigation.angor-vertical-navigation-appearance-compact.angor-vertical-navigation-position-right.angor-vertical-navigation-mode-side{margin-right:calc(var(--angor-vertical-navigation-compact-width) * -1)}angor-vertical-navigation.angor-vertical-navigation-appearance-compact.angor-vertical-navigation-position-right.angor-vertical-navigation-opened{margin-right:0}angor-vertical-navigation.angor-vertical-navigation-appearance-compact.angor-vertical-navigation-position-right .angor-vertical-navigation-aside-wrapper{left:auto;right:var(--angor-vertical-navigation-compact-width)}angor-vertical-navigation.angor-vertical-navigation-appearance-compact .angor-vertical-navigation-wrapper .angor-vertical-navigation-content>angor-vertical-navigation-aside-item .angor-vertical-navigation-item-wrapper,angor-vertical-navigation.angor-vertical-navigation-appearance-compact .angor-vertical-navigation-wrapper .angor-vertical-navigation-content>angor-vertical-navigation-basic-item .angor-vertical-navigation-item-wrapper{margin:4px 8px 0}angor-vertical-navigation.angor-vertical-navigation-appearance-compact .angor-vertical-navigation-wrapper .angor-vertical-navigation-content>angor-vertical-navigation-aside-item .angor-vertical-navigation-item-wrapper .angor-vertical-navigation-item,angor-vertical-navigation.angor-vertical-navigation-appearance-compact .angor-vertical-navigation-wrapper .angor-vertical-navigation-content>angor-vertical-navigation-basic-item .angor-vertical-navigation-item-wrapper .angor-vertical-navigation-item{flex-direction:column;justify-content:center;padding:12px;border-radius:6px}angor-vertical-navigation.angor-vertical-navigation-appearance-compact .angor-vertical-navigation-wrapper .angor-vertical-navigation-content>angor-vertical-navigation-aside-item .angor-vertical-navigation-item-wrapper .angor-vertical-navigation-item .angor-vertical-navigation-item-icon,angor-vertical-navigation.angor-vertical-navigation-appearance-compact .angor-vertical-navigation-wrapper .angor-vertical-navigation-content>angor-vertical-navigation-basic-item .angor-vertical-navigation-item-wrapper .angor-vertical-navigation-item .angor-vertical-navigation-item-icon{margin-right:0}angor-vertical-navigation.angor-vertical-navigation-appearance-compact .angor-vertical-navigation-wrapper .angor-vertical-navigation-content>angor-vertical-navigation-aside-item .angor-vertical-navigation-item-wrapper .angor-vertical-navigation-item .angor-vertical-navigation-item-title-wrapper,angor-vertical-navigation.angor-vertical-navigation-appearance-compact .angor-vertical-navigation-wrapper .angor-vertical-navigation-content>angor-vertical-navigation-basic-item .angor-vertical-navigation-item-wrapper .angor-vertical-navigation-item .angor-vertical-navigation-item-title-wrapper{margin-top:8px}angor-vertical-navigation.angor-vertical-navigation-appearance-compact .angor-vertical-navigation-wrapper .angor-vertical-navigation-content>angor-vertical-navigation-aside-item .angor-vertical-navigation-item-wrapper .angor-vertical-navigation-item .angor-vertical-navigation-item-title-wrapper .angor-vertical-navigation-item-title,angor-vertical-navigation.angor-vertical-navigation-appearance-compact .angor-vertical-navigation-wrapper .angor-vertical-navigation-content>angor-vertical-navigation-basic-item .angor-vertical-navigation-item-wrapper .angor-vertical-navigation-item .angor-vertical-navigation-item-title-wrapper .angor-vertical-navigation-item-title{font-size:12px;font-weight:500;text-align:center;line-height:16px}angor-vertical-navigation.angor-vertical-navigation-appearance-compact .angor-vertical-navigation-wrapper .angor-vertical-navigation-content>angor-vertical-navigation-aside-item .angor-vertical-navigation-item-wrapper .angor-vertical-navigation-item .angor-vertical-navigation-item-title-wrapper .angor-vertical-navigation-item-subtitle,angor-vertical-navigation.angor-vertical-navigation-appearance-compact .angor-vertical-navigation-wrapper .angor-vertical-navigation-content>angor-vertical-navigation-basic-item .angor-vertical-navigation-item-wrapper .angor-vertical-navigation-item .angor-vertical-navigation-item-title-wrapper .angor-vertical-navigation-item-subtitle{display:none!important}angor-vertical-navigation.angor-vertical-navigation-appearance-compact .angor-vertical-navigation-wrapper .angor-vertical-navigation-content>angor-vertical-navigation-aside-item .angor-vertical-navigation-item-wrapper .angor-vertical-navigation-item .angor-vertical-navigation-item-badge,angor-vertical-navigation.angor-vertical-navigation-appearance-compact .angor-vertical-navigation-wrapper .angor-vertical-navigation-content>angor-vertical-navigation-basic-item .angor-vertical-navigation-item-wrapper .angor-vertical-navigation-item .angor-vertical-navigation-item-badge{position:absolute;top:12px;left:64px}angor-vertical-navigation.angor-vertical-navigation-appearance-compact .angor-vertical-navigation-wrapper .angor-vertical-navigation-content>angor-vertical-navigation-aside-item>angor-vertical-navigation-collapsable-item,angor-vertical-navigation.angor-vertical-navigation-appearance-compact .angor-vertical-navigation-wrapper .angor-vertical-navigation-content>angor-vertical-navigation-basic-item>angor-vertical-navigation-collapsable-item{display:none}angor-vertical-navigation.angor-vertical-navigation-appearance-compact .angor-vertical-navigation-wrapper .angor-vertical-navigation-content>angor-vertical-navigation-aside-item>angor-vertical-navigation-group-item>.angor-vertical-navigation-item-wrapper,angor-vertical-navigation.angor-vertical-navigation-appearance-compact .angor-vertical-navigation-wrapper .angor-vertical-navigation-content>angor-vertical-navigation-basic-item>angor-vertical-navigation-group-item>.angor-vertical-navigation-item-wrapper{display:none}angor-vertical-navigation.angor-vertical-navigation-appearance-compact .angor-vertical-navigation-aside-wrapper{left:var(--angor-vertical-navigation-compact-width)}:root{--angor-vertical-navigation-width: 280px;--angor-vertical-navigation-dense-width: 80px}angor-vertical-navigation.angor-vertical-navigation-appearance-dense:not(.angor-vertical-navigation-mode-over){width:var(--angor-vertical-navigation-dense-width);min-width:var(--angor-vertical-navigation-dense-width);max-width:var(--angor-vertical-navigation-dense-width)}angor-vertical-navigation.angor-vertical-navigation-appearance-dense:not(.angor-vertical-navigation-mode-over).angor-vertical-navigation-position-left.angor-vertical-navigation-mode-side{margin-left:calc(var(--angor-vertical-navigation-dense-width) * -1)}angor-vertical-navigation.angor-vertical-navigation-appearance-dense:not(.angor-vertical-navigation-mode-over).angor-vertical-navigation-position-left.angor-vertical-navigation-opened{margin-left:0}angor-vertical-navigation.angor-vertical-navigation-appearance-dense:not(.angor-vertical-navigation-mode-over).angor-vertical-navigation-position-right.angor-vertical-navigation-mode-side{margin-right:calc(var(--angor-vertical-navigation-dense-width) * -1)}angor-vertical-navigation.angor-vertical-navigation-appearance-dense:not(.angor-vertical-navigation-mode-over).angor-vertical-navigation-position-right.angor-vertical-navigation-opened{margin-right:0}angor-vertical-navigation.angor-vertical-navigation-appearance-dense:not(.angor-vertical-navigation-mode-over).angor-vertical-navigation-position-right .angor-vertical-navigation-aside-wrapper{left:auto;right:var(--angor-vertical-navigation-dense-width)}angor-vertical-navigation.angor-vertical-navigation-appearance-dense:not(.angor-vertical-navigation-mode-over).angor-vertical-navigation-position-right.angor-vertical-navigation-hover .angor-vertical-navigation-aside-wrapper{left:auto;right:var(--angor-vertical-navigation-width)}angor-vertical-navigation.angor-vertical-navigation-appearance-dense .angor-vertical-navigation-wrapper .angor-vertical-navigation-content angor-vertical-navigation-aside-item .angor-vertical-navigation-item-wrapper .angor-vertical-navigation-item,angor-vertical-navigation.angor-vertical-navigation-appearance-dense .angor-vertical-navigation-wrapper .angor-vertical-navigation-content angor-vertical-navigation-basic-item .angor-vertical-navigation-item-wrapper .angor-vertical-navigation-item,angor-vertical-navigation.angor-vertical-navigation-appearance-dense .angor-vertical-navigation-wrapper .angor-vertical-navigation-content angor-vertical-navigation-collapsable-item .angor-vertical-navigation-item-wrapper .angor-vertical-navigation-item,angor-vertical-navigation.angor-vertical-navigation-appearance-dense .angor-vertical-navigation-wrapper .angor-vertical-navigation-content angor-vertical-navigation-group-item .angor-vertical-navigation-item-wrapper .angor-vertical-navigation-item{width:calc(var(--angor-vertical-navigation-dense-width) - 24px);min-width:calc(var(--angor-vertical-navigation-dense-width) - 24px);max-width:calc(var(--angor-vertical-navigation-dense-width) - 24px)}angor-vertical-navigation.angor-vertical-navigation-appearance-dense .angor-vertical-navigation-wrapper .angor-vertical-navigation-content angor-vertical-navigation-aside-item .angor-vertical-navigation-item-wrapper .angor-vertical-navigation-item .angor-vertical-navigation-item-arrow,angor-vertical-navigation.angor-vertical-navigation-appearance-dense .angor-vertical-navigation-wrapper .angor-vertical-navigation-content angor-vertical-navigation-aside-item .angor-vertical-navigation-item-wrapper .angor-vertical-navigation-item .angor-vertical-navigation-item-badge,angor-vertical-navigation.angor-vertical-navigation-appearance-dense .angor-vertical-navigation-wrapper .angor-vertical-navigation-content angor-vertical-navigation-aside-item .angor-vertical-navigation-item-wrapper .angor-vertical-navigation-item .angor-vertical-navigation-item-title-wrapper,angor-vertical-navigation.angor-vertical-navigation-appearance-dense .angor-vertical-navigation-wrapper .angor-vertical-navigation-content angor-vertical-navigation-basic-item .angor-vertical-navigation-item-wrapper .angor-vertical-navigation-item .angor-vertical-navigation-item-arrow,angor-vertical-navigation.angor-vertical-navigation-appearance-dense .angor-vertical-navigation-wrapper .angor-vertical-navigation-content angor-vertical-navigation-basic-item .angor-vertical-navigation-item-wrapper .angor-vertical-navigation-item .angor-vertical-navigation-item-badge,angor-vertical-navigation.angor-vertical-navigation-appearance-dense .angor-vertical-navigation-wrapper .angor-vertical-navigation-content angor-vertical-navigation-basic-item .angor-vertical-navigation-item-wrapper .angor-vertical-navigation-item .angor-vertical-navigation-item-title-wrapper,angor-vertical-navigation.angor-vertical-navigation-appearance-dense .angor-vertical-navigation-wrapper .angor-vertical-navigation-content angor-vertical-navigation-collapsable-item .angor-vertical-navigation-item-wrapper .angor-vertical-navigation-item .angor-vertical-navigation-item-arrow,angor-vertical-navigation.angor-vertical-navigation-appearance-dense .angor-vertical-navigation-wrapper .angor-vertical-navigation-content angor-vertical-navigation-collapsable-item .angor-vertical-navigation-item-wrapper .angor-vertical-navigation-item .angor-vertical-navigation-item-badge,angor-vertical-navigation.angor-vertical-navigation-appearance-dense .angor-vertical-navigation-wrapper .angor-vertical-navigation-content angor-vertical-navigation-collapsable-item .angor-vertical-navigation-item-wrapper .angor-vertical-navigation-item .angor-vertical-navigation-item-title-wrapper,angor-vertical-navigation.angor-vertical-navigation-appearance-dense .angor-vertical-navigation-wrapper .angor-vertical-navigation-content angor-vertical-navigation-group-item .angor-vertical-navigation-item-wrapper .angor-vertical-navigation-item .angor-vertical-navigation-item-arrow,angor-vertical-navigation.angor-vertical-navigation-appearance-dense .angor-vertical-navigation-wrapper .angor-vertical-navigation-content angor-vertical-navigation-group-item .angor-vertical-navigation-item-wrapper .angor-vertical-navigation-item .angor-vertical-navigation-item-badge,angor-vertical-navigation.angor-vertical-navigation-appearance-dense .angor-vertical-navigation-wrapper .angor-vertical-navigation-content angor-vertical-navigation-group-item .angor-vertical-navigation-item-wrapper .angor-vertical-navigation-item .angor-vertical-navigation-item-title-wrapper{transition:opacity .4s cubic-bezier(.25,.8,.25,1)}angor-vertical-navigation.angor-vertical-navigation-appearance-dense .angor-vertical-navigation-wrapper .angor-vertical-navigation-content angor-vertical-navigation-group-item:first-of-type{margin-top:0}angor-vertical-navigation.angor-vertical-navigation-appearance-dense:not(.angor-vertical-navigation-hover):not(.angor-vertical-navigation-mode-over) .angor-vertical-navigation-wrapper .angor-vertical-navigation-content .angor-vertical-navigation-item-wrapper .angor-vertical-navigation-item{padding:10px 16px}angor-vertical-navigation.angor-vertical-navigation-appearance-dense:not(.angor-vertical-navigation-hover):not(.angor-vertical-navigation-mode-over) .angor-vertical-navigation-wrapper .angor-vertical-navigation-content .angor-vertical-navigation-item-wrapper .angor-vertical-navigation-item .angor-vertical-navigation-item-arrow,angor-vertical-navigation.angor-vertical-navigation-appearance-dense:not(.angor-vertical-navigation-hover):not(.angor-vertical-navigation-mode-over) .angor-vertical-navigation-wrapper .angor-vertical-navigation-content .angor-vertical-navigation-item-wrapper .angor-vertical-navigation-item .angor-vertical-navigation-item-badge,angor-vertical-navigation.angor-vertical-navigation-appearance-dense:not(.angor-vertical-navigation-hover):not(.angor-vertical-navigation-mode-over) .angor-vertical-navigation-wrapper .angor-vertical-navigation-content .angor-vertical-navigation-item-wrapper .angor-vertical-navigation-item .angor-vertical-navigation-item-title-wrapper{white-space:nowrap;opacity:0}angor-vertical-navigation.angor-vertical-navigation-appearance-dense:not(.angor-vertical-navigation-hover):not(.angor-vertical-navigation-mode-over) .angor-vertical-navigation-wrapper .angor-vertical-navigation-content angor-vertical-navigation-collapsable-item .angor-vertical-navigation-item-children{display:none}angor-vertical-navigation.angor-vertical-navigation-appearance-dense:not(.angor-vertical-navigation-hover):not(.angor-vertical-navigation-mode-over) .angor-vertical-navigation-wrapper .angor-vertical-navigation-content angor-vertical-navigation-group-item>.angor-vertical-navigation-item-wrapper .angor-vertical-navigation-item:before{content:"";position:absolute;top:20px;width:23px;border-top-width:2px}angor-vertical-navigation.angor-vertical-navigation-appearance-dense .angor-vertical-navigation-aside-wrapper{left:var(--angor-vertical-navigation-dense-width)}angor-vertical-navigation.angor-vertical-navigation-appearance-dense.angor-vertical-navigation-hover .angor-vertical-navigation-wrapper{width:var(--angor-vertical-navigation-width)}angor-vertical-navigation.angor-vertical-navigation-appearance-dense.angor-vertical-navigation-hover .angor-vertical-navigation-wrapper .angor-vertical-navigation-content .angor-vertical-navigation-item-wrapper .angor-vertical-navigation-item{width:calc(var(--angor-vertical-navigation-width) - 24px);min-width:calc(var(--angor-vertical-navigation-width) - 24px);max-width:calc(var(--angor-vertical-navigation-width) - 24px)}angor-vertical-navigation.angor-vertical-navigation-appearance-dense.angor-vertical-navigation-hover .angor-vertical-navigation-wrapper .angor-vertical-navigation-content .angor-vertical-navigation-item-wrapper .angor-vertical-navigation-item .angor-vertical-navigation-item-arrow,angor-vertical-navigation.angor-vertical-navigation-appearance-dense.angor-vertical-navigation-hover .angor-vertical-navigation-wrapper .angor-vertical-navigation-content .angor-vertical-navigation-item-wrapper .angor-vertical-navigation-item .angor-vertical-navigation-item-badge,angor-vertical-navigation.angor-vertical-navigation-appearance-dense.angor-vertical-navigation-hover .angor-vertical-navigation-wrapper .angor-vertical-navigation-content .angor-vertical-navigation-item-wrapper .angor-vertical-navigation-item .angor-vertical-navigation-item-title-wrapper{white-space:nowrap;animation:removeWhiteSpaceNoWrap 1ms linear .35s;animation-fill-mode:forwards}angor-vertical-navigation.angor-vertical-navigation-appearance-dense.angor-vertical-navigation-hover .angor-vertical-navigation-aside-wrapper{left:var(--angor-vertical-navigation-width)}@keyframes removeWhiteSpaceNoWrap{0%{white-space:nowrap}99%{white-space:nowrap}to{white-space:normal}}:root{--angor-vertical-navigation-thin-width: 80px}angor-vertical-navigation.angor-vertical-navigation-appearance-thin{width:var(--angor-vertical-navigation-thin-width);min-width:var(--angor-vertical-navigation-thin-width);max-width:var(--angor-vertical-navigation-thin-width)}angor-vertical-navigation.angor-vertical-navigation-appearance-thin.angor-vertical-navigation-position-left.angor-vertical-navigation-mode-side{margin-left:calc(var(--angor-vertical-navigation-thin-width) * -1)}angor-vertical-navigation.angor-vertical-navigation-appearance-thin.angor-vertical-navigation-position-left.angor-vertical-navigation-opened{margin-left:0}angor-vertical-navigation.angor-vertical-navigation-appearance-thin.angor-vertical-navigation-position-right.angor-vertical-navigation-mode-side{margin-right:calc(var(--angor-vertical-navigation-thin-width) * -1)}angor-vertical-navigation.angor-vertical-navigation-appearance-thin.angor-vertical-navigation-position-right.angor-vertical-navigation-opened{margin-right:0}angor-vertical-navigation.angor-vertical-navigation-appearance-thin.angor-vertical-navigation-position-right .angor-vertical-navigation-aside-wrapper{left:auto;right:var(--angor-vertical-navigation-thin-width)}angor-vertical-navigation.angor-vertical-navigation-appearance-thin .angor-vertical-navigation-wrapper .angor-vertical-navigation-content>angor-vertical-navigation-aside-item,angor-vertical-navigation.angor-vertical-navigation-appearance-thin .angor-vertical-navigation-wrapper .angor-vertical-navigation-content>angor-vertical-navigation-basic-item{flex-direction:column;justify-content:center;height:64px;min-height:64px;max-height:64px;padding:0 16px}angor-vertical-navigation.angor-vertical-navigation-appearance-thin .angor-vertical-navigation-wrapper .angor-vertical-navigation-content>angor-vertical-navigation-aside-item .angor-vertical-navigation-item-wrapper,angor-vertical-navigation.angor-vertical-navigation-appearance-thin .angor-vertical-navigation-wrapper .angor-vertical-navigation-content>angor-vertical-navigation-basic-item .angor-vertical-navigation-item-wrapper{display:flex;align-items:center;justify-content:center}angor-vertical-navigation.angor-vertical-navigation-appearance-thin .angor-vertical-navigation-wrapper .angor-vertical-navigation-content>angor-vertical-navigation-aside-item .angor-vertical-navigation-item-wrapper .angor-vertical-navigation-item,angor-vertical-navigation.angor-vertical-navigation-appearance-thin .angor-vertical-navigation-wrapper .angor-vertical-navigation-content>angor-vertical-navigation-basic-item .angor-vertical-navigation-item-wrapper .angor-vertical-navigation-item{justify-content:center;padding:12px;border-radius:4px}angor-vertical-navigation.angor-vertical-navigation-appearance-thin .angor-vertical-navigation-wrapper .angor-vertical-navigation-content>angor-vertical-navigation-aside-item .angor-vertical-navigation-item-wrapper .angor-vertical-navigation-item .angor-vertical-navigation-item-icon,angor-vertical-navigation.angor-vertical-navigation-appearance-thin .angor-vertical-navigation-wrapper .angor-vertical-navigation-content>angor-vertical-navigation-basic-item .angor-vertical-navigation-item-wrapper .angor-vertical-navigation-item .angor-vertical-navigation-item-icon{margin:0}angor-vertical-navigation.angor-vertical-navigation-appearance-thin .angor-vertical-navigation-wrapper .angor-vertical-navigation-content>angor-vertical-navigation-aside-item .angor-vertical-navigation-item-wrapper .angor-vertical-navigation-item .angor-vertical-navigation-item-arrow,angor-vertical-navigation.angor-vertical-navigation-appearance-thin .angor-vertical-navigation-wrapper .angor-vertical-navigation-content>angor-vertical-navigation-aside-item .angor-vertical-navigation-item-wrapper .angor-vertical-navigation-item .angor-vertical-navigation-item-badge-content,angor-vertical-navigation.angor-vertical-navigation-appearance-thin .angor-vertical-navigation-wrapper .angor-vertical-navigation-content>angor-vertical-navigation-aside-item .angor-vertical-navigation-item-wrapper .angor-vertical-navigation-item .angor-vertical-navigation-item-title-wrapper,angor-vertical-navigation.angor-vertical-navigation-appearance-thin .angor-vertical-navigation-wrapper .angor-vertical-navigation-content>angor-vertical-navigation-basic-item .angor-vertical-navigation-item-wrapper .angor-vertical-navigation-item .angor-vertical-navigation-item-arrow,angor-vertical-navigation.angor-vertical-navigation-appearance-thin .angor-vertical-navigation-wrapper .angor-vertical-navigation-content>angor-vertical-navigation-basic-item .angor-vertical-navigation-item-wrapper .angor-vertical-navigation-item .angor-vertical-navigation-item-badge-content,angor-vertical-navigation.angor-vertical-navigation-appearance-thin .angor-vertical-navigation-wrapper .angor-vertical-navigation-content>angor-vertical-navigation-basic-item .angor-vertical-navigation-item-wrapper .angor-vertical-navigation-item .angor-vertical-navigation-item-title-wrapper{display:none}angor-vertical-navigation.angor-vertical-navigation-appearance-thin .angor-vertical-navigation-wrapper .angor-vertical-navigation-content>angor-vertical-navigation-collapsable-item{display:none}angor-vertical-navigation.angor-vertical-navigation-appearance-thin .angor-vertical-navigation-wrapper .angor-vertical-navigation-content>angor-vertical-navigation-group-item>.angor-vertical-navigation-item-wrapper{display:none}angor-vertical-navigation.angor-vertical-navigation-appearance-thin .angor-vertical-navigation-aside-wrapper{left:var(--angor-vertical-navigation-thin-width)}\n'],encapsulation:2,data:{animation:i.F},changeDetection:0})}}return Q})()},7891:(o,s,r)=>{"use strict";r.d(s,{t:()=>a});const a=new(r(3107).nKC)("ANGOR_APP_CONFIG")},1109:(o,s,r)=>{"use strict";r.d(s,{P:()=>w});var i=r(7891),a=r(3107),c=r(4819),y=r(1217);let w=(()=>{class C{constructor(){this._defaultConfig=(0,a.WQX)(i.t),this._configSubject=new y.t(this._defaultConfig)}get config$(){return this._configSubject.asObservable()}set config(S){const M=(0,c.A)({},this._configSubject.getValue(),S);this._configSubject.next(M)}reset(){this._configSubject.next(this._defaultConfig)}static{this.\u0275fac=function(M){return new(M||C)}}static{this.\u0275prov=a.jDH({token:C,factory:C.\u0275fac,providedIn:"root"})}}return C})()},7153:(o,s,r)=>{"use strict";r.d(s,{m:()=>ae});var i=r(4460),a=r(3107),c=r(9471),y=r(7544),w=r(3904);const C=(me,be,Oe,xe,De,ce,ue,Ce)=>({"bg-primary-100 text-primary-600 dark:bg-primary-600 dark:text-primary-50":me,"bg-accent-100 text-accent-600 dark:bg-accent-600 dark:text-accent-50":be,"bg-warn-100 text-warn-600 dark:bg-warn-600 dark:text-warn-50":Oe,"bg-gray-100 text-gray-600 dark:bg-gray-600 dark:text-gray-50":xe,"bg-blue-100 text-blue-600 dark:bg-blue-600 dark:text-blue-50":De,"bg-green-100 text-green-500 dark:bg-green-500 dark:text-green-50":ce,"bg-amber-100 text-amber-500 dark:bg-amber-500 dark:text-amber-50":ue,"bg-red-100 text-red-600 dark:bg-red-600 dark:text-red-50":Ce});function T(me,be){1&me&&(a.j41(0,"div",1)(1,"button",6),a.nrm(2,"mat-icon",7),a.k0s()()),2&me&&(a.R7$(),a.Y8G("matDialogClose",void 0),a.R7$(),a.Y8G("svgIcon","heroicons_outline:x-mark"))}function S(me,be){if(1&me&&(a.j41(0,"div",3),a.nrm(1,"mat-icon",8),a.k0s()),2&me){const Oe=a.XpG();a.Y8G("ngClass",a.lV(2,C,"primary"===Oe.data.icon.color,"accent"===Oe.data.icon.color,"warn"===Oe.data.icon.color,"basic"===Oe.data.icon.color,"info"===Oe.data.icon.color,"success"===Oe.data.icon.color,"warning"===Oe.data.icon.color,"error"===Oe.data.icon.color)),a.R7$(),a.Y8G("svgIcon",Oe.data.icon.name)}}function M(me,be){if(1&me&&a.nrm(0,"div",9),2&me){const Oe=a.XpG(2);a.Y8G("innerHTML",Oe.data.title,a.npT)}}function O(me,be){if(1&me&&a.nrm(0,"div",10),2&me){const Oe=a.XpG(2);a.Y8G("innerHTML",Oe.data.message,a.npT)}}function L(me,be){if(1&me&&(a.j41(0,"div",4),a.DNE(1,M,1,1,"div",9)(2,O,1,1,"div",10),a.k0s()),2&me){const Oe=a.XpG();a.R7$(),a.vxM(Oe.data.title?1:-1),a.R7$(),a.vxM(Oe.data.message?2:-1)}}function Z(me,be){if(1&me&&(a.j41(0,"button",11),a.EFF(1),a.k0s()),2&me){const Oe=a.XpG(2);a.Y8G("matDialogClose","cancelled"),a.R7$(),a.SpI(" ",Oe.data.actions.cancel.label," ")}}function q(me,be){if(1&me&&(a.j41(0,"button",12),a.EFF(1),a.k0s()),2&me){const Oe=a.XpG(2);a.Y8G("color",Oe.data.actions.confirm.color)("matDialogClose","confirmed"),a.R7$(),a.SpI(" ",Oe.data.actions.confirm.label," ")}}function re(me,be){if(1&me&&(a.j41(0,"div",5),a.DNE(1,Z,2,2,"button",11)(2,q,2,3,"button",12),a.k0s()),2&me){const Oe=a.XpG();a.R7$(),a.vxM(Oe.data.actions.cancel.show?1:-1),a.R7$(),a.vxM(Oe.data.actions.confirm.show?2:-1)}}let pe=(()=>{class me{constructor(){this.data=(0,a.WQX)(y.Vh)}static{this.\u0275fac=function(xe){return new(xe||me)}}static{this.\u0275cmp=a.VBU({type:me,selectors:[["angor-confirmation-dialog"]],decls:6,vars:4,consts:[[1,"relative","flex","h-full","w-full","flex-col"],[1,"absolute","right-0","top-0","pr-4","pt-4"],[1,"flex","flex-auto","flex-col","items-center","p-8","pb-6","sm:flex-row","sm:items-start","sm:pb-8"],[1,"flex","h-10","w-10","flex-0","items-center","justify-center","rounded-full","sm:mr-4",3,"ngClass"],[1,"mt-4","flex","flex-col","items-center","space-y-1","text-center","sm:mt-0","sm:items-start","sm:pr-8","sm:text-left"],[1,"flex","items-center","justify-center","space-x-3","bg-gray-50","px-6","py-4","dark:bg-black","dark:bg-opacity-10","sm:justify-end"],["mat-icon-button","",3,"matDialogClose"],[1,"text-secondary",3,"svgIcon"],[1,"text-current",3,"svgIcon"],[1,"text-xl","font-medium","leading-6",3,"innerHTML"],[1,"text-secondary",3,"innerHTML"],["mat-stroked-button","",3,"matDialogClose"],["mat-flat-button","",3,"color","matDialogClose"]],template:function(xe,De){1&xe&&(a.j41(0,"div",0),a.DNE(1,T,3,2,"div",1),a.j41(2,"div",2),a.DNE(3,S,2,11,"div",3)(4,L,3,2,"div",4),a.k0s(),a.DNE(5,re,3,2,"div",5),a.k0s()),2&xe&&(a.R7$(),a.vxM(De.data.dismissible?1:-1),a.R7$(2),a.vxM(De.data.icon.show?3:-1),a.R7$(),a.vxM(De.data.title||De.data.message?4:-1),a.R7$(),a.vxM(De.data.actions.confirm.show||De.data.actions.cancel.show?5:-1))},dependencies:[c.Hl,c.$z,c.iY,y.hM,y.tx,w.m_,w.An,i.YU],styles:["@media (min-width: 960px){.angor-confirmation-dialog-panel{width:32rem}}.angor-confirmation-dialog-panel .mat-mdc-dialog-container .mat-mdc-dialog-surface{padding:0!important}\n"],encapsulation:2})}}return me})();var se=r(4819);let ae=(()=>{class me{constructor(){this._matDialog=(0,a.WQX)(y.bZ),this._defaultConfig={title:"Confirm action",message:"Are you sure you want to confirm this action?",icon:{show:!0,name:"heroicons_outline:exclamation-triangle",color:"warn"},actions:{confirm:{show:!0,label:"Confirm",color:"warn"},cancel:{show:!0,label:"Cancel"}},dismissible:!1}}open(Oe={}){const xe=(0,se.A)({},this._defaultConfig,Oe);return this._matDialog.open(pe,{autoFocus:!1,disableClose:!xe.dismissible,data:xe,panelClass:"angor-confirmation-dialog-panel"})}static{this.\u0275fac=function(xe){return new(xe||me)}}static{this.\u0275prov=a.jDH({token:me,factory:me.\u0275fac,providedIn:"root"})}}return me})()},2012:(o,s,r)=>{"use strict";r.d(s,{l:()=>S});var i=r(1109),a=r(6520),c=r(3107),y=r(6143),w=r(7838),C=r(7947),T=r(2867);let S=(()=>{class M{constructor(){this._breakpointObserver=(0,c.WQX)(a.QP),this._angorConfigService=(0,c.WQX)(i.P),this._onMediaChange=new w.m(1),this._angorConfigService.config$.pipe((0,C.T)(L=>(0,y.A)(Object.entries(L.screens).map(([Z,q])=>[Z,`(min-width: ${q})`]))),(0,T.n)(L=>this._breakpointObserver.observe(Object.values(L)).pipe((0,C.T)(Z=>{const q=[],re={},pe=Object.entries(Z.breakpoints).filter(([se,ae])=>ae)??[];for(const[se]of pe){const ae=Object.entries(L).find(([me,be])=>be===se)[0];ae&&(q.push(ae),re[ae]=se)}this._onMediaChange.next({matchingAliases:q,matchingQueries:re})})))).subscribe()}get onMediaChange$(){return this._onMediaChange.asObservable()}onMediaQueryChange$(L){return this._breakpointObserver.observe(L)}static{this.\u0275fac=function(Z){return new(Z||M)}}static{this.\u0275prov=c.jDH({token:M,factory:M.\u0275fac,providedIn:"root"})}}return M})()},3939:(o,s,r)=>{"use strict";r.d(s,{Q:()=>a});var i=r(3107);let a=(()=>{class c{get exactMatchOptions(){return{paths:"exact",fragment:"ignored",matrixParams:"ignored",queryParams:"exact"}}get subsetMatchOptions(){return{paths:"subset",fragment:"ignored",matrixParams:"ignored",queryParams:"subset"}}randomId(w=10){let T="";for(let S=0;S<10;S++)T+="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789".charAt(Math.floor(62*Math.random()));return T}static{this.\u0275fac=function(C){return new(C||c)}}static{this.\u0275prov=i.jDH({token:c,factory:c.\u0275fac,providedIn:"root"})}}return c})()},4482:(o,s,r)=>{"use strict";r.d(s,{v:()=>y});var i=r(3024),a=r(8447),c=r(3107);let y=(()=>{class w{constructor(){this.publicKeySubject=new a.B,this.previousPublicKey=null,this.initializeNostrLogin(),this.setupEventListeners()}initializeNostrLogin(){(0,i.Ts)({theme:"ocean",noBanner:!0,title:"Angor Hub",onAuth:(T,S)=>{this.handleAuthSuccess(T,S)}})}setupEventListeners(){document.addEventListener("nlAuth",this.handleNlAuthEvent.bind(this)),document.addEventListener("nlLogout",this.handleNlLogoutEvent.bind(this)),document.addEventListener("nlDarkMode",this.handleNlDarkModeEvent.bind(this)),document.addEventListener("nlLaunch",this.handleNlLaunchEvent.bind(this))}handleNlLogoutEvent(){console.log("Logout event detected"),this.handleLogout()}handleNlAuthEvent(T){const{type:S,pubkey:M,options:O}=T.detail;switch(S){case"login":console.log("User logged in:",M),this.handleAuthSuccess(M,O);break;case"signup":console.log("User signed up:",M),this.handleSignupSuccess(M,O);break;case"logout":console.log("User logged out"),this.handleLogout();break;case"switch-account":console.log("User switched account:",M),this.handleAccountSwitch(M,O);break;default:console.warn("Unknown nlAuth event type:",S)}this.previousPublicKey&&this.previousPublicKey!==M&&(console.log("Account switched to:",M),this.handleAccountSwitch(M,O)),this.previousPublicKey=M}handleAuthSuccess(T,S){console.log("Authenticated successfully with public key:",T),this.publicKeySubject.next(T)}handleSignupSuccess(T,S){console.log("Signup successful with public key:",T),this.publicKeySubject.next(T)}handleAccountSwitch(T,S){console.log("Account switched to:",T),this.publicKeySubject.next(T),window.location.reload()}handleLogout(){console.log("Logged out"),this.publicKeySubject.next("")}handleNlDarkModeEvent(T){const S=T.detail;console.log("Dark mode changed to:",S?"enabled":"disabled"),this.updateDarkMode(S)}handleNlLaunchEvent(T){const S=T.detail||"welcome";console.log(`Launching Nostr login screen: ${S}`),this.launchScreen(S)}launchScreen(T){(0,i.ql)(T)}updateDarkMode(T){document.body.classList.toggle("dark-mode",T),console.log("Dark mode is now "+(T?"enabled":"disabled"))}getPublicKeyObservable(){return this.publicKeySubject.asObservable()}launchWelcomeScreen(){(0,i.ql)("welcome")}launchSignupScreen(){(0,i.ql)("welcome-signup")}launchLoginScreen(){(0,i.ql)("welcome-login")}switchAccount(){document.dispatchEvent(new CustomEvent("nlLaunch",{detail:"switch-account"}))}logout(){document.dispatchEvent(new Event("nlLogout"))}toggleDarkMode(T){document.dispatchEvent(new CustomEvent("nlDarkMode",{detail:T}))}static{this.\u0275fac=function(S){return new(S||w)}}static{this.\u0275prov=c.jDH({token:w,factory:w.\u0275fac,providedIn:"root"})}}return w})()},3125:(o,s,r)=>{"use strict";r.d(s,{b:()=>T});var i=r(3014),a=r(3107),c=r(5492),y=r(1217),w=r(8447),C=r(4460);let T=(()=>{class S{constructor(O,L){this.document=O,this.platformId=L,this.pool=new c.lo,this.relays=[],this.maxRetries=10,this.retryDelay=15e3,this.eventSubject=new y.t(null),this.relaysSubject=new y.t([]),this.destroy$=new w.B,this.initializeRelays(),this.setupVisibilityHandling()}initializeRelays(){this.relays=this.loadRelaysFromLocalStorage(),this.connectToRelays(),this.relaysSubject.next(this.relays)}loadRelaysFromLocalStorage(){const O=JSON.parse(localStorage.getItem("nostrRelays")||"[]");return O.length>0?O.map(Z=>({...Z,connected:!1,retries:0,retryTimeout:null,ws:void 0})):[{url:"wss://relay.primal.net",connected:!1,retries:0,retryTimeout:null,accessType:"read-write"},{url:"wss://nos.lol",connected:!1,retries:0,retryTimeout:null,accessType:"read-write"},{url:"wss://relay.angor.io",connected:!1,retries:0,retryTimeout:null,accessType:"read-write"},{url:"wss://relay2.angor.io",connected:!1,retries:0,retryTimeout:null,accessType:"read-write"}]}saveRelaysToLocalStorage(){const O=this.relays.map(L=>({url:L.url,accessType:L.accessType,connected:L.connected,retries:L.retries,retryTimeout:L.retryTimeout}));localStorage.setItem("nostrRelays",JSON.stringify(O)),this.relaysSubject.next(this.relays)}connectToRelay(O){O.connected||(O.ws=new WebSocket(O.url),O.ws.onopen=()=>{O.connected=!0,O.retries=0,clearTimeout(O.retryTimeout),this.saveRelaysToLocalStorage()},O.ws.onerror=()=>this.handleRelayError(O),O.ws.onclose=()=>{O.connected=!1,this.handleRelayError(O)},O.ws.onmessage=({data:L})=>{try{const Z=JSON.parse("string"==typeof L?L:L.toString("utf-8"));this.eventSubject.next(Z)}catch(Z){console.warn("Error parsing WebSocket message:",Z)}})}handleRelayError(O){O.retries>=this.maxRetries?console.warn(`Max retries reached for relay: ${O.url}. No further attempts will be made.`):(O.retries++,O.retryTimeout=setTimeout(()=>this.connectToRelay(O),this.retryDelay*O.retries))}connectToRelays(){this.relays.forEach(O=>!O.connected&&this.connectToRelay(O))}ensureConnectedRelays(){var O=this;return(0,i.A)(function*(){return O.connectToRelays(),new Promise(L=>{const Z=setInterval(()=>{O.getConnectedRelays().length>0&&(clearInterval(Z),L())},1e3)})})()}setupVisibilityHandling(){(0,C.UE)(this.platformId)&&(this.document.addEventListener("visibilitychange",()=>{"visible"===this.document.visibilityState&&this.connectToRelays()}),window.addEventListener("beforeunload",()=>{this.relays.forEach(O=>O.ws?.close())}))}getConnectedRelays(){return this.relays.filter(O=>O.connected).map(O=>O.url)}getRelays(){return this.relaysSubject.asObservable()}publishEventToWriteRelays(O){var L=this;return(0,i.A)(function*(){const Z=L.relays.filter(q=>["write","read-write"].includes(q.accessType)&&q.connected);if(!Z.length)throw new Error("No connected write relays available");try{return yield Promise.any(Z.map(q=>L.pool.publish([q.url],O))),L.eventSubject.next(O),O}catch(q){throw console.error("Failed to publish event to relays:",q),q}})()}addRelay(O,L="read-write"){if(!this.relays.some(Z=>Z.url===O)){const Z={url:O,connected:!1,retries:0,retryTimeout:null,accessType:L};this.relays.push(Z),this.connectToRelay(Z),this.saveRelaysToLocalStorage()}}removeRelay(O){const L=this.relays.find(Z=>Z.url===O);L&&(L.ws?.close(),clearTimeout(L.retryTimeout)),this.relays=this.relays.filter(Z=>Z.url!==O),this.saveRelaysToLocalStorage()}removeAllCustomRelays(){const O=["wss://relay.angor.io","wss://relay2.angor.io"];this.relays.forEach(L=>{O.includes(L.url)||(L.ws?.close(),clearTimeout(L.retryTimeout))}),this.relays=this.relays.filter(L=>O.includes(L.url)),this.saveRelaysToLocalStorage()}updateRelayAccessType(O,L){const Z=this.relays.find(q=>q.url===O);Z&&(Z.accessType=L,this.saveRelaysToLocalStorage())}getPool(){return this.pool}getEventStream(){return this.eventSubject.asObservable()}ngOnDestroy(){this.destroy$.next(),this.destroy$.complete(),this.relays.forEach(O=>O.ws?.close())}static{this.\u0275fac=function(L){return new(L||S)(a.KVO(C.qQ,8),a.KVO(a.Agw))}}static{this.\u0275prov=a.jDH({token:S,factory:S.\u0275fac,providedIn:"root"})}}return S})()},8078:(o,s,r)=>{"use strict";r.d(s,{A:()=>yd});var i={};r.r(i),r.d(i,{OG:()=>Xs,My:()=>ha,Ph:()=>oo,lX:()=>Fn,Id:()=>so,fg:()=>vo,qj:()=>Qi,aT:()=>Wo,lq:()=>Sr,z:()=>Oi,Q5:()=>Vs});var a=r(3014),c=r(8378),y=r(2226),w=r(871),C=r(5492);function M(I){if(!Number.isSafeInteger(I)||I<0)throw new Error(`Wrong positive integer: ${I}`)}function Z(I,...P){if(!function L(I){return I instanceof Uint8Array||null!=I&&"object"==typeof I&&"Uint8Array"===I.constructor.name}(I))throw new Error("Expected Uint8Array");if(P.length>0&&!P.includes(I.length))throw new Error(`Expected Uint8Array of length ${P}, not of length=${I.length}`)}function q(I){if("function"!=typeof I||"function"!=typeof I.create)throw new Error("Hash should be wrapped by utils.wrapConstructor");M(I.outputLen),M(I.blockLen)}function re(I,P=!0){if(I.destroyed)throw new Error("Hash instance has been destroyed");if(P&&I.finished)throw new Error("Hash#digest() has already been called")}r(4704),"abandon\nability\nable\nabout\nabove\nabsent\nabsorb\nabstract\nabsurd\nabuse\naccess\naccident\naccount\naccuse\nachieve\nacid\nacoustic\nacquire\nacross\nact\naction\nactor\nactress\nactual\nadapt\nadd\naddict\naddress\nadjust\nadmit\nadult\nadvance\nadvice\naerobic\naffair\nafford\nafraid\nagain\nage\nagent\nagree\nahead\naim\nair\nairport\naisle\nalarm\nalbum\nalcohol\nalert\nalien\nall\nalley\nallow\nalmost\nalone\nalpha\nalready\nalso\nalter\nalways\namateur\namazing\namong\namount\namused\nanalyst\nanchor\nancient\nanger\nangle\nangry\nanimal\nankle\nannounce\nannual\nanother\nanswer\nantenna\nantique\nanxiety\nany\napart\napology\nappear\napple\napprove\napril\narch\narctic\narea\narena\nargue\narm\narmed\narmor\narmy\naround\narrange\narrest\narrive\narrow\nart\nartefact\nartist\nartwork\nask\naspect\nassault\nasset\nassist\nassume\nasthma\nathlete\natom\nattack\nattend\nattitude\nattract\nauction\naudit\naugust\naunt\nauthor\nauto\nautumn\naverage\navocado\navoid\nawake\naware\naway\nawesome\nawful\nawkward\naxis\nbaby\nbachelor\nbacon\nbadge\nbag\nbalance\nbalcony\nball\nbamboo\nbanana\nbanner\nbar\nbarely\nbargain\nbarrel\nbase\nbasic\nbasket\nbattle\nbeach\nbean\nbeauty\nbecause\nbecome\nbeef\nbefore\nbegin\nbehave\nbehind\nbelieve\nbelow\nbelt\nbench\nbenefit\nbest\nbetray\nbetter\nbetween\nbeyond\nbicycle\nbid\nbike\nbind\nbiology\nbird\nbirth\nbitter\nblack\nblade\nblame\nblanket\nblast\nbleak\nbless\nblind\nblood\nblossom\nblouse\nblue\nblur\nblush\nboard\nboat\nbody\nboil\nbomb\nbone\nbonus\nbook\nboost\nborder\nboring\nborrow\nboss\nbottom\nbounce\nbox\nboy\nbracket\nbrain\nbrand\nbrass\nbrave\nbread\nbreeze\nbrick\nbridge\nbrief\nbright\nbring\nbrisk\nbroccoli\nbroken\nbronze\nbroom\nbrother\nbrown\nbrush\nbubble\nbuddy\nbudget\nbuffalo\nbuild\nbulb\nbulk\nbullet\nbundle\nbunker\nburden\nburger\nburst\nbus\nbusiness\nbusy\nbutter\nbuyer\nbuzz\ncabbage\ncabin\ncable\ncactus\ncage\ncake\ncall\ncalm\ncamera\ncamp\ncan\ncanal\ncancel\ncandy\ncannon\ncanoe\ncanvas\ncanyon\ncapable\ncapital\ncaptain\ncar\ncarbon\ncard\ncargo\ncarpet\ncarry\ncart\ncase\ncash\ncasino\ncastle\ncasual\ncat\ncatalog\ncatch\ncategory\ncattle\ncaught\ncause\ncaution\ncave\nceiling\ncelery\ncement\ncensus\ncentury\ncereal\ncertain\nchair\nchalk\nchampion\nchange\nchaos\nchapter\ncharge\nchase\nchat\ncheap\ncheck\ncheese\nchef\ncherry\nchest\nchicken\nchief\nchild\nchimney\nchoice\nchoose\nchronic\nchuckle\nchunk\nchurn\ncigar\ncinnamon\ncircle\ncitizen\ncity\ncivil\nclaim\nclap\nclarify\nclaw\nclay\nclean\nclerk\nclever\nclick\nclient\ncliff\nclimb\nclinic\nclip\nclock\nclog\nclose\ncloth\ncloud\nclown\nclub\nclump\ncluster\nclutch\ncoach\ncoast\ncoconut\ncode\ncoffee\ncoil\ncoin\ncollect\ncolor\ncolumn\ncombine\ncome\ncomfort\ncomic\ncommon\ncompany\nconcert\nconduct\nconfirm\ncongress\nconnect\nconsider\ncontrol\nconvince\ncook\ncool\ncopper\ncopy\ncoral\ncore\ncorn\ncorrect\ncost\ncotton\ncouch\ncountry\ncouple\ncourse\ncousin\ncover\ncoyote\ncrack\ncradle\ncraft\ncram\ncrane\ncrash\ncrater\ncrawl\ncrazy\ncream\ncredit\ncreek\ncrew\ncricket\ncrime\ncrisp\ncritic\ncrop\ncross\ncrouch\ncrowd\ncrucial\ncruel\ncruise\ncrumble\ncrunch\ncrush\ncry\ncrystal\ncube\nculture\ncup\ncupboard\ncurious\ncurrent\ncurtain\ncurve\ncushion\ncustom\ncute\ncycle\ndad\ndamage\ndamp\ndance\ndanger\ndaring\ndash\ndaughter\ndawn\nday\ndeal\ndebate\ndebris\ndecade\ndecember\ndecide\ndecline\ndecorate\ndecrease\ndeer\ndefense\ndefine\ndefy\ndegree\ndelay\ndeliver\ndemand\ndemise\ndenial\ndentist\ndeny\ndepart\ndepend\ndeposit\ndepth\ndeputy\nderive\ndescribe\ndesert\ndesign\ndesk\ndespair\ndestroy\ndetail\ndetect\ndevelop\ndevice\ndevote\ndiagram\ndial\ndiamond\ndiary\ndice\ndiesel\ndiet\ndiffer\ndigital\ndignity\ndilemma\ndinner\ndinosaur\ndirect\ndirt\ndisagree\ndiscover\ndisease\ndish\ndismiss\ndisorder\ndisplay\ndistance\ndivert\ndivide\ndivorce\ndizzy\ndoctor\ndocument\ndog\ndoll\ndolphin\ndomain\ndonate\ndonkey\ndonor\ndoor\ndose\ndouble\ndove\ndraft\ndragon\ndrama\ndrastic\ndraw\ndream\ndress\ndrift\ndrill\ndrink\ndrip\ndrive\ndrop\ndrum\ndry\nduck\ndumb\ndune\nduring\ndust\ndutch\nduty\ndwarf\ndynamic\neager\neagle\nearly\nearn\nearth\neasily\neast\neasy\necho\necology\neconomy\nedge\nedit\neducate\neffort\negg\neight\neither\nelbow\nelder\nelectric\nelegant\nelement\nelephant\nelevator\nelite\nelse\nembark\nembody\nembrace\nemerge\nemotion\nemploy\nempower\nempty\nenable\nenact\nend\nendless\nendorse\nenemy\nenergy\nenforce\nengage\nengine\nenhance\nenjoy\nenlist\nenough\nenrich\nenroll\nensure\nenter\nentire\nentry\nenvelope\nepisode\nequal\nequip\nera\nerase\nerode\nerosion\nerror\nerupt\nescape\nessay\nessence\nestate\neternal\nethics\nevidence\nevil\nevoke\nevolve\nexact\nexample\nexcess\nexchange\nexcite\nexclude\nexcuse\nexecute\nexercise\nexhaust\nexhibit\nexile\nexist\nexit\nexotic\nexpand\nexpect\nexpire\nexplain\nexpose\nexpress\nextend\nextra\neye\neyebrow\nfabric\nface\nfaculty\nfade\nfaint\nfaith\nfall\nfalse\nfame\nfamily\nfamous\nfan\nfancy\nfantasy\nfarm\nfashion\nfat\nfatal\nfather\nfatigue\nfault\nfavorite\nfeature\nfebruary\nfederal\nfee\nfeed\nfeel\nfemale\nfence\nfestival\nfetch\nfever\nfew\nfiber\nfiction\nfield\nfigure\nfile\nfilm\nfilter\nfinal\nfind\nfine\nfinger\nfinish\nfire\nfirm\nfirst\nfiscal\nfish\nfit\nfitness\nfix\nflag\nflame\nflash\nflat\nflavor\nflee\nflight\nflip\nfloat\nflock\nfloor\nflower\nfluid\nflush\nfly\nfoam\nfocus\nfog\nfoil\nfold\nfollow\nfood\nfoot\nforce\nforest\nforget\nfork\nfortune\nforum\nforward\nfossil\nfoster\nfound\nfox\nfragile\nframe\nfrequent\nfresh\nfriend\nfringe\nfrog\nfront\nfrost\nfrown\nfrozen\nfruit\nfuel\nfun\nfunny\nfurnace\nfury\nfuture\ngadget\ngain\ngalaxy\ngallery\ngame\ngap\ngarage\ngarbage\ngarden\ngarlic\ngarment\ngas\ngasp\ngate\ngather\ngauge\ngaze\ngeneral\ngenius\ngenre\ngentle\ngenuine\ngesture\nghost\ngiant\ngift\ngiggle\nginger\ngiraffe\ngirl\ngive\nglad\nglance\nglare\nglass\nglide\nglimpse\nglobe\ngloom\nglory\nglove\nglow\nglue\ngoat\ngoddess\ngold\ngood\ngoose\ngorilla\ngospel\ngossip\ngovern\ngown\ngrab\ngrace\ngrain\ngrant\ngrape\ngrass\ngravity\ngreat\ngreen\ngrid\ngrief\ngrit\ngrocery\ngroup\ngrow\ngrunt\nguard\nguess\nguide\nguilt\nguitar\ngun\ngym\nhabit\nhair\nhalf\nhammer\nhamster\nhand\nhappy\nharbor\nhard\nharsh\nharvest\nhat\nhave\nhawk\nhazard\nhead\nhealth\nheart\nheavy\nhedgehog\nheight\nhello\nhelmet\nhelp\nhen\nhero\nhidden\nhigh\nhill\nhint\nhip\nhire\nhistory\nhobby\nhockey\nhold\nhole\nholiday\nhollow\nhome\nhoney\nhood\nhope\nhorn\nhorror\nhorse\nhospital\nhost\nhotel\nhour\nhover\nhub\nhuge\nhuman\nhumble\nhumor\nhundred\nhungry\nhunt\nhurdle\nhurry\nhurt\nhusband\nhybrid\nice\nicon\nidea\nidentify\nidle\nignore\nill\nillegal\nillness\nimage\nimitate\nimmense\nimmune\nimpact\nimpose\nimprove\nimpulse\ninch\ninclude\nincome\nincrease\nindex\nindicate\nindoor\nindustry\ninfant\ninflict\ninform\ninhale\ninherit\ninitial\ninject\ninjury\ninmate\ninner\ninnocent\ninput\ninquiry\ninsane\ninsect\ninside\ninspire\ninstall\nintact\ninterest\ninto\ninvest\ninvite\ninvolve\niron\nisland\nisolate\nissue\nitem\nivory\njacket\njaguar\njar\njazz\njealous\njeans\njelly\njewel\njob\njoin\njoke\njourney\njoy\njudge\njuice\njump\njungle\njunior\njunk\njust\nkangaroo\nkeen\nkeep\nketchup\nkey\nkick\nkid\nkidney\nkind\nkingdom\nkiss\nkit\nkitchen\nkite\nkitten\nkiwi\nknee\nknife\nknock\nknow\nlab\nlabel\nlabor\nladder\nlady\nlake\nlamp\nlanguage\nlaptop\nlarge\nlater\nlatin\nlaugh\nlaundry\nlava\nlaw\nlawn\nlawsuit\nlayer\nlazy\nleader\nleaf\nlearn\nleave\nlecture\nleft\nleg\nlegal\nlegend\nleisure\nlemon\nlend\nlength\nlens\nleopard\nlesson\nletter\nlevel\nliar\nliberty\nlibrary\nlicense\nlife\nlift\nlight\nlike\nlimb\nlimit\nlink\nlion\nliquid\nlist\nlittle\nlive\nlizard\nload\nloan\nlobster\nlocal\nlock\nlogic\nlonely\nlong\nloop\nlottery\nloud\nlounge\nlove\nloyal\nlucky\nluggage\nlumber\nlunar\nlunch\nluxury\nlyrics\nmachine\nmad\nmagic\nmagnet\nmaid\nmail\nmain\nmajor\nmake\nmammal\nman\nmanage\nmandate\nmango\nmansion\nmanual\nmaple\nmarble\nmarch\nmargin\nmarine\nmarket\nmarriage\nmask\nmass\nmaster\nmatch\nmaterial\nmath\nmatrix\nmatter\nmaximum\nmaze\nmeadow\nmean\nmeasure\nmeat\nmechanic\nmedal\nmedia\nmelody\nmelt\nmember\nmemory\nmention\nmenu\nmercy\nmerge\nmerit\nmerry\nmesh\nmessage\nmetal\nmethod\nmiddle\nmidnight\nmilk\nmillion\nmimic\nmind\nminimum\nminor\nminute\nmiracle\nmirror\nmisery\nmiss\nmistake\nmix\nmixed\nmixture\nmobile\nmodel\nmodify\nmom\nmoment\nmonitor\nmonkey\nmonster\nmonth\nmoon\nmoral\nmore\nmorning\nmosquito\nmother\nmotion\nmotor\nmountain\nmouse\nmove\nmovie\nmuch\nmuffin\nmule\nmultiply\nmuscle\nmuseum\nmushroom\nmusic\nmust\nmutual\nmyself\nmystery\nmyth\nnaive\nname\nnapkin\nnarrow\nnasty\nnation\nnature\nnear\nneck\nneed\nnegative\nneglect\nneither\nnephew\nnerve\nnest\nnet\nnetwork\nneutral\nnever\nnews\nnext\nnice\nnight\nnoble\nnoise\nnominee\nnoodle\nnormal\nnorth\nnose\nnotable\nnote\nnothing\nnotice\nnovel\nnow\nnuclear\nnumber\nnurse\nnut\noak\nobey\nobject\noblige\nobscure\nobserve\nobtain\nobvious\noccur\nocean\noctober\nodor\noff\noffer\noffice\noften\noil\nokay\nold\nolive\nolympic\nomit\nonce\none\nonion\nonline\nonly\nopen\nopera\nopinion\noppose\noption\norange\norbit\norchard\norder\nordinary\norgan\norient\noriginal\norphan\nostrich\nother\noutdoor\nouter\noutput\noutside\noval\noven\nover\nown\nowner\noxygen\noyster\nozone\npact\npaddle\npage\npair\npalace\npalm\npanda\npanel\npanic\npanther\npaper\nparade\nparent\npark\nparrot\nparty\npass\npatch\npath\npatient\npatrol\npattern\npause\npave\npayment\npeace\npeanut\npear\npeasant\npelican\npen\npenalty\npencil\npeople\npepper\nperfect\npermit\nperson\npet\nphone\nphoto\nphrase\nphysical\npiano\npicnic\npicture\npiece\npig\npigeon\npill\npilot\npink\npioneer\npipe\npistol\npitch\npizza\nplace\nplanet\nplastic\nplate\nplay\nplease\npledge\npluck\nplug\nplunge\npoem\npoet\npoint\npolar\npole\npolice\npond\npony\npool\npopular\nportion\nposition\npossible\npost\npotato\npottery\npoverty\npowder\npower\npractice\npraise\npredict\nprefer\nprepare\npresent\npretty\nprevent\nprice\npride\nprimary\nprint\npriority\nprison\nprivate\nprize\nproblem\nprocess\nproduce\nprofit\nprogram\nproject\npromote\nproof\nproperty\nprosper\nprotect\nproud\nprovide\npublic\npudding\npull\npulp\npulse\npumpkin\npunch\npupil\npuppy\npurchase\npurity\npurpose\npurse\npush\nput\npuzzle\npyramid\nquality\nquantum\nquarter\nquestion\nquick\nquit\nquiz\nquote\nrabbit\nraccoon\nrace\nrack\nradar\nradio\nrail\nrain\nraise\nrally\nramp\nranch\nrandom\nrange\nrapid\nrare\nrate\nrather\nraven\nraw\nrazor\nready\nreal\nreason\nrebel\nrebuild\nrecall\nreceive\nrecipe\nrecord\nrecycle\nreduce\nreflect\nreform\nrefuse\nregion\nregret\nregular\nreject\nrelax\nrelease\nrelief\nrely\nremain\nremember\nremind\nremove\nrender\nrenew\nrent\nreopen\nrepair\nrepeat\nreplace\nreport\nrequire\nrescue\nresemble\nresist\nresource\nresponse\nresult\nretire\nretreat\nreturn\nreunion\nreveal\nreview\nreward\nrhythm\nrib\nribbon\nrice\nrich\nride\nridge\nrifle\nright\nrigid\nring\nriot\nripple\nrisk\nritual\nrival\nriver\nroad\nroast\nrobot\nrobust\nrocket\nromance\nroof\nrookie\nroom\nrose\nrotate\nrough\nround\nroute\nroyal\nrubber\nrude\nrug\nrule\nrun\nrunway\nrural\nsad\nsaddle\nsadness\nsafe\nsail\nsalad\nsalmon\nsalon\nsalt\nsalute\nsame\nsample\nsand\nsatisfy\nsatoshi\nsauce\nsausage\nsave\nsay\nscale\nscan\nscare\nscatter\nscene\nscheme\nschool\nscience\nscissors\nscorpion\nscout\nscrap\nscreen\nscript\nscrub\nsea\nsearch\nseason\nseat\nsecond\nsecret\nsection\nsecurity\nseed\nseek\nsegment\nselect\nsell\nseminar\nsenior\nsense\nsentence\nseries\nservice\nsession\nsettle\nsetup\nseven\nshadow\nshaft\nshallow\nshare\nshed\nshell\nsheriff\nshield\nshift\nshine\nship\nshiver\nshock\nshoe\nshoot\nshop\nshort\nshoulder\nshove\nshrimp\nshrug\nshuffle\nshy\nsibling\nsick\nside\nsiege\nsight\nsign\nsilent\nsilk\nsilly\nsilver\nsimilar\nsimple\nsince\nsing\nsiren\nsister\nsituate\nsix\nsize\nskate\nsketch\nski\nskill\nskin\nskirt\nskull\nslab\nslam\nsleep\nslender\nslice\nslide\nslight\nslim\nslogan\nslot\nslow\nslush\nsmall\nsmart\nsmile\nsmoke\nsmooth\nsnack\nsnake\nsnap\nsniff\nsnow\nsoap\nsoccer\nsocial\nsock\nsoda\nsoft\nsolar\nsoldier\nsolid\nsolution\nsolve\nsomeone\nsong\nsoon\nsorry\nsort\nsoul\nsound\nsoup\nsource\nsouth\nspace\nspare\nspatial\nspawn\nspeak\nspecial\nspeed\nspell\nspend\nsphere\nspice\nspider\nspike\nspin\nspirit\nsplit\nspoil\nsponsor\nspoon\nsport\nspot\nspray\nspread\nspring\nspy\nsquare\nsqueeze\nsquirrel\nstable\nstadium\nstaff\nstage\nstairs\nstamp\nstand\nstart\nstate\nstay\nsteak\nsteel\nstem\nstep\nstereo\nstick\nstill\nsting\nstock\nstomach\nstone\nstool\nstory\nstove\nstrategy\nstreet\nstrike\nstrong\nstruggle\nstudent\nstuff\nstumble\nstyle\nsubject\nsubmit\nsubway\nsuccess\nsuch\nsudden\nsuffer\nsugar\nsuggest\nsuit\nsummer\nsun\nsunny\nsunset\nsuper\nsupply\nsupreme\nsure\nsurface\nsurge\nsurprise\nsurround\nsurvey\nsuspect\nsustain\nswallow\nswamp\nswap\nswarm\nswear\nsweet\nswift\nswim\nswing\nswitch\nsword\nsymbol\nsymptom\nsyrup\nsystem\ntable\ntackle\ntag\ntail\ntalent\ntalk\ntank\ntape\ntarget\ntask\ntaste\ntattoo\ntaxi\nteach\nteam\ntell\nten\ntenant\ntennis\ntent\nterm\ntest\ntext\nthank\nthat\ntheme\nthen\ntheory\nthere\nthey\nthing\nthis\nthought\nthree\nthrive\nthrow\nthumb\nthunder\nticket\ntide\ntiger\ntilt\ntimber\ntime\ntiny\ntip\ntired\ntissue\ntitle\ntoast\ntobacco\ntoday\ntoddler\ntoe\ntogether\ntoilet\ntoken\ntomato\ntomorrow\ntone\ntongue\ntonight\ntool\ntooth\ntop\ntopic\ntopple\ntorch\ntornado\ntortoise\ntoss\ntotal\ntourist\ntoward\ntower\ntown\ntoy\ntrack\ntrade\ntraffic\ntragic\ntrain\ntransfer\ntrap\ntrash\ntravel\ntray\ntreat\ntree\ntrend\ntrial\ntribe\ntrick\ntrigger\ntrim\ntrip\ntrophy\ntrouble\ntruck\ntrue\ntruly\ntrumpet\ntrust\ntruth\ntry\ntube\ntuition\ntumble\ntuna\ntunnel\nturkey\nturn\nturtle\ntwelve\ntwenty\ntwice\ntwin\ntwist\ntwo\ntype\ntypical\nugly\numbrella\nunable\nunaware\nuncle\nuncover\nunder\nundo\nunfair\nunfold\nunhappy\nuniform\nunique\nunit\nuniverse\nunknown\nunlock\nuntil\nunusual\nunveil\nupdate\nupgrade\nuphold\nupon\nupper\nupset\nurban\nurge\nusage\nuse\nused\nuseful\nuseless\nusual\nutility\nvacant\nvacuum\nvague\nvalid\nvalley\nvalve\nvan\nvanish\nvapor\nvarious\nvast\nvault\nvehicle\nvelvet\nvendor\nventure\nvenue\nverb\nverify\nversion\nvery\nvessel\nveteran\nviable\nvibrant\nvicious\nvictory\nvideo\nview\nvillage\nvintage\nviolin\nvirtual\nvirus\nvisa\nvisit\nvisual\nvital\nvivid\nvocal\nvoice\nvoid\nvolcano\nvolume\nvote\nvoyage\nwage\nwagon\nwait\nwalk\nwall\nwalnut\nwant\nwarfare\nwarm\nwarrior\nwash\nwasp\nwaste\nwater\nwave\nway\nwealth\nweapon\nwear\nweasel\nweather\nweb\nwedding\nweekend\nweird\nwelcome\nwest\nwet\nwhale\nwhat\nwheat\nwheel\nwhen\nwhere\nwhip\nwhisper\nwide\nwidth\nwife\nwild\nwill\nwin\nwindow\nwine\nwing\nwink\nwinner\nwinter\nwire\nwisdom\nwise\nwish\nwitness\nwolf\nwoman\nwonder\nwood\nwool\nword\nwork\nworld\nworry\nworth\nwrap\nwreck\nwrestle\nwrist\nwrite\nwrong\nyard\nyear\nyellow\nyou\nyoung\nyouth\nzebra\nzero\nzone\nzoo".split("\n");const xe=I=>new DataView(I.buffer,I.byteOffset,I.byteLength);if(68!==new Uint8Array(new Uint32Array([287454020]).buffer)[0])throw new Error("Non little-endian hardware is not supported");function bn(I){if("string"==typeof I&&(I=function gn(I){if("string"!=typeof I)throw new Error("utf8ToBytes expected string, got "+typeof I);return new Uint8Array((new TextEncoder).encode(I))}(I)),!function Oe(I){return I instanceof Uint8Array||null!=I&&"object"==typeof I&&"Uint8Array"===I.constructor.name}(I))throw new Error("expected Uint8Array, got "+typeof I);return I}class yn{clone(){return this._cloneInto()}}const qe={}.toString;function ze(I){const P=oe=>I().update(bn(oe)).digest(),$=I();return P.outputLen=$.outputLen,P.blockLen=$.blockLen,P.create=()=>I(),P}class Ze extends yn{constructor(P,$){super(),this.finished=!1,this.destroyed=!1,q(P);const oe=bn($);if(this.iHash=P.create(),"function"!=typeof this.iHash.update)throw new Error("Expected instance of class which extends utils.Hash");this.blockLen=this.iHash.blockLen,this.outputLen=this.iHash.outputLen;const Ae=this.blockLen,je=new Uint8Array(Ae);je.set(oe.length>Ae?P.create().update(oe).digest():oe);for(let pt=0;ptnew Ze(I,P).update($).digest();it.create=(I,P)=>new Ze(I,P);class Mt extends yn{constructor(P,$,oe,Ae){super(),this.blockLen=P,this.outputLen=$,this.padOffset=oe,this.isLE=Ae,this.finished=!1,this.length=0,this.pos=0,this.destroyed=!1,this.buffer=new Uint8Array(P),this.view=xe(this.buffer)}update(P){re(this);const{view:$,buffer:oe,blockLen:Ae}=this,je=(P=bn(P)).length;for(let pt=0;ptAe-pt&&(this.process(oe,0),pt=0);for(let Qt=pt;Qt>Ae&je),It=Number($&je),ln=oe?0:4;I.setUint32(P+(oe?4:0),pt,oe),I.setUint32(P+ln,It,oe)})(oe,Ae-8,BigInt(8*this.length),je),this.process(oe,0);const It=xe(P),zt=this.outputLen;if(zt%4)throw new Error("_sha2: outputLen should be aligned to 32bit");const ln=zt/4,An=this.get();if(ln>An.length)throw new Error("_sha2: outputLen bigger than state");for(let Qt=0;Qt>rt&Kt)}:{h:0|Number(I>>rt&Kt),l:0|Number(I&Kt)}}const xn_split=function en(I,P=!1){let $=new Uint32Array(I.length),oe=new Uint32Array(I.length);for(let Ae=0;AeI>>>$,xn_shrSL=(I,P,$)=>I<<32-$|P>>>$,xn_rotrSH=(I,P,$)=>I>>>$|P<<32-$,xn_rotrSL=(I,P,$)=>I<<32-$|P>>>$,xn_rotrBH=(I,P,$)=>I<<64-$|P>>>$-32,xn_rotrBL=(I,P,$)=>I>>>$-32|P<<64-$,xn_add=function ft(I,P,$,oe){const Ae=(P>>>0)+(oe>>>0);return{h:I+$+(Ae/2**32|0)|0,l:0|Ae}},xn_add3L=(I,P,$)=>(I>>>0)+(P>>>0)+($>>>0),xn_add3H=(I,P,$,oe)=>P+$+oe+(I/2**32|0)|0,xn_add4L=(I,P,$,oe)=>(I>>>0)+(P>>>0)+($>>>0)+(oe>>>0),xn_add4H=(I,P,$,oe,Ae)=>P+$+oe+Ae+(I/2**32|0)|0,xn_add5H=(I,P,$,oe,Ae,je)=>P+$+oe+Ae+je+(I/2**32|0)|0,xn_add5L=(I,P,$,oe,Ae)=>(I>>>0)+(P>>>0)+($>>>0)+(oe>>>0)+(Ae>>>0),[Hr,Tr]=xn_split(["0x428a2f98d728ae22","0x7137449123ef65cd","0xb5c0fbcfec4d3b2f","0xe9b5dba58189dbbc","0x3956c25bf348b538","0x59f111f1b605d019","0x923f82a4af194f9b","0xab1c5ed5da6d8118","0xd807aa98a3030242","0x12835b0145706fbe","0x243185be4ee4b28c","0x550c7dc3d5ffb4e2","0x72be5d74f27b896f","0x80deb1fe3b1696b1","0x9bdc06a725c71235","0xc19bf174cf692694","0xe49b69c19ef14ad2","0xefbe4786384f25e3","0x0fc19dc68b8cd5b5","0x240ca1cc77ac9c65","0x2de92c6f592b0275","0x4a7484aa6ea6e483","0x5cb0a9dcbd41fbd4","0x76f988da831153b5","0x983e5152ee66dfab","0xa831c66d2db43210","0xb00327c898fb213f","0xbf597fc7beef0ee4","0xc6e00bf33da88fc2","0xd5a79147930aa725","0x06ca6351e003826f","0x142929670a0e6e70","0x27b70a8546d22ffc","0x2e1b21385c26c926","0x4d2c6dfc5ac42aed","0x53380d139d95b3df","0x650a73548baf63de","0x766a0abb3c77b2a8","0x81c2c92e47edaee6","0x92722c851482353b","0xa2bfe8a14cf10364","0xa81a664bbc423001","0xc24b8b70d0f89791","0xc76c51a30654be30","0xd192e819d6ef5218","0xd69906245565a910","0xf40e35855771202a","0x106aa07032bbd1b8","0x19a4c116b8d2d0c8","0x1e376c085141ab53","0x2748774cdf8eeb99","0x34b0bcb5e19b48a8","0x391c0cb3c5c95a63","0x4ed8aa4ae3418acb","0x5b9cca4f7763e373","0x682e6ff3d6b2b8a3","0x748f82ee5defb2fc","0x78a5636f43172f60","0x84c87814a1f0ab72","0x8cc702081a6439ec","0x90befffa23631e28","0xa4506cebde82bde9","0xbef9a3f7b2c67915","0xc67178f2e372532b","0xca273eceea26619c","0xd186b8c721c0c207","0xeada7dd6cde0eb1e","0xf57d4f7fee6ed178","0x06f067aa72176fba","0x0a637dc5a2c898a6","0x113f9804bef90dae","0x1b710b35131c471b","0x28db77f523047d84","0x32caab7b40c72493","0x3c9ebe0a15c9bebc","0x431d67c49c100d4c","0x4cc5d4becb3e42b6","0x597f299cfc657e2a","0x5fcb6fab3ad6faec","0x6c44198c4a475817"].map(I=>BigInt(I))),Vr=new Uint32Array(80),vt=new Uint32Array(80);class Wt extends Mt{constructor(){super(128,64,16,!1),this.Ah=1779033703,this.Al=-205731576,this.Bh=-1150833019,this.Bl=-2067093701,this.Ch=1013904242,this.Cl=-23791573,this.Dh=-1521486534,this.Dl=1595750129,this.Eh=1359893119,this.El=-1377402159,this.Fh=-1694144372,this.Fl=725511199,this.Gh=528734635,this.Gl=-79577749,this.Hh=1541459225,this.Hl=327033209}get(){const{Ah:P,Al:$,Bh:oe,Bl:Ae,Ch:je,Cl:pt,Dh:It,Dl:zt,Eh:ln,El:An,Fh:Qt,Fl:Gn,Gh:zn,Gl:nr,Hh:Mn,Hl:Hn}=this;return[P,$,oe,Ae,je,pt,It,zt,ln,An,Qt,Gn,zn,nr,Mn,Hn]}set(P,$,oe,Ae,je,pt,It,zt,ln,An,Qt,Gn,zn,nr,Mn,Hn){this.Ah=0|P,this.Al=0|$,this.Bh=0|oe,this.Bl=0|Ae,this.Ch=0|je,this.Cl=0|pt,this.Dh=0|It,this.Dl=0|zt,this.Eh=0|ln,this.El=0|An,this.Fh=0|Qt,this.Fl=0|Gn,this.Gh=0|zn,this.Gl=0|nr,this.Hh=0|Mn,this.Hl=0|Hn}process(P,$){for(let $n=0;$n<16;$n++,$+=4)Vr[$n]=P.getUint32($),vt[$n]=P.getUint32($+=4);for(let $n=16;$n<80;$n++){const Ir=0|Vr[$n-15],ir=0|vt[$n-15],Cr=xn_rotrSH(Ir,ir,1)^xn_rotrSH(Ir,ir,8)^xn_shrSH(Ir,ir,7),Gr=xn_rotrSL(Ir,ir,1)^xn_rotrSL(Ir,ir,8)^xn_shrSL(Ir,ir,7),Br=0|Vr[$n-2],ro=0|vt[$n-2],Ji=xn_rotrSH(Br,ro,19)^xn_rotrBH(Br,ro,61)^xn_shrSH(Br,ro,6),Xi=xn_rotrSL(Br,ro,19)^xn_rotrBL(Br,ro,61)^xn_shrSL(Br,ro,6),bo=xn_add4L(Gr,Xi,vt[$n-7],vt[$n-16]),To=xn_add4H(bo,Cr,Ji,Vr[$n-7],Vr[$n-16]);Vr[$n]=0|To,vt[$n]=0|bo}let{Ah:oe,Al:Ae,Bh:je,Bl:pt,Ch:It,Cl:zt,Dh:ln,Dl:An,Eh:Qt,El:Gn,Fh:zn,Fl:nr,Gh:Mn,Gl:Hn,Hh:Xn,Hl:vr}=this;for(let $n=0;$n<80;$n++){const Ir=xn_rotrSH(Qt,Gn,14)^xn_rotrSH(Qt,Gn,18)^xn_rotrBH(Qt,Gn,41),ir=xn_rotrSL(Qt,Gn,14)^xn_rotrSL(Qt,Gn,18)^xn_rotrBL(Qt,Gn,41),Cr=Qt&zn^~Qt&Mn,Br=xn_add5L(vr,ir,Gn&nr^~Gn&Hn,Tr[$n],vt[$n]),ro=xn_add5H(Br,Xn,Ir,Cr,Hr[$n],Vr[$n]),Ji=0|Br,Xi=xn_rotrSH(oe,Ae,28)^xn_rotrBH(oe,Ae,34)^xn_rotrBH(oe,Ae,39),bo=xn_rotrSL(oe,Ae,28)^xn_rotrBL(oe,Ae,34)^xn_rotrBL(oe,Ae,39),To=oe&je^oe&It^je&It,ga=Ae&pt^Ae&zt^pt&zt;Xn=0|Mn,vr=0|Hn,Mn=0|zn,Hn=0|nr,zn=0|Qt,nr=0|Gn,({h:Qt,l:Gn}=xn_add(0|ln,0|An,0|ro,0|Ji)),ln=0|It,An=0|zt,It=0|je,zt=0|pt,je=0|oe,pt=0|Ae;const _r=xn_add3L(Ji,bo,ga);oe=xn_add3H(_r,ro,Xi,To),Ae=0|_r}({h:oe,l:Ae}=xn_add(0|this.Ah,0|this.Al,0|oe,0|Ae)),({h:je,l:pt}=xn_add(0|this.Bh,0|this.Bl,0|je,0|pt)),({h:It,l:zt}=xn_add(0|this.Ch,0|this.Cl,0|It,0|zt)),({h:ln,l:An}=xn_add(0|this.Dh,0|this.Dl,0|ln,0|An)),({h:Qt,l:Gn}=xn_add(0|this.Eh,0|this.El,0|Qt,0|Gn)),({h:zn,l:nr}=xn_add(0|this.Fh,0|this.Fl,0|zn,0|nr)),({h:Mn,l:Hn}=xn_add(0|this.Gh,0|this.Gl,0|Mn,0|Hn)),({h:Xn,l:vr}=xn_add(0|this.Hh,0|this.Hl,0|Xn,0|vr)),this.set(oe,Ae,je,pt,It,zt,ln,An,Qt,Gn,zn,nr,Mn,Hn,Xn,vr)}roundClean(){Vr.fill(0),vt.fill(0)}destroy(){this.buffer.fill(0),this.set(0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0)}}const Dt=ze(()=>new Wt);function Er(I){if("string"!=typeof I)throw new TypeError("Invalid mnemonic type: "+typeof I);return I.normalize("NFKD")}function Co(I,P=""){return function Te(I,P,$,oe){const{c:Ae,dkLen:je,DK:pt,PRF:It,PRFSalt:zt}=function Ot(I,P,$,oe){q(I);const Ae=function _t(I,P){if(void 0!==P&&"[object Object]"!==qe.call(P))throw new Error("Options should be object or undefined");return Object.assign(I,P)}({dkLen:32,asyncTick:10},oe),{c:je,dkLen:pt,asyncTick:It}=Ae;if(M(je),M(pt),M(It),je<1)throw new Error("PBKDF2: iterations (c) should be >= 1");const zt=bn(P),ln=bn($),An=new Uint8Array(pt),Qt=it.create(I,zt),Gn=Qt._cloneInto().update(ln);return{c:je,dkLen:pt,asyncTick:It,DK:An,PRF:Qt,PRFSalt:Gn}}(I,P,$,oe);let ln;const An=new Uint8Array(4),Qt=xe(An),Gn=new Uint8Array(It.outputLen);for(let zn=1,nr=0;nrEr(`mnemonic${I}`))(P),{c:2048,dkLen:64})}function Ni(I){if(!Number.isSafeInteger(I)||I<0)throw new Error(`Wrong positive integer: ${I}`)}function ai(I,...P){if(!function $o(I){return I instanceof Uint8Array||null!=I&&"object"==typeof I&&"Uint8Array"===I.constructor.name}(I))throw new Error("Expected Uint8Array");if(P.length>0&&!P.includes(I.length))throw new Error(`Expected Uint8Array of length ${P}, not of length=${I.length}`)}function fo(I,P=!0){if(I.destroyed)throw new Error("Hash instance has been destroyed");if(P&&I.finished)throw new Error("Hash#digest() has already been called")}function Ii(I){return I instanceof Uint8Array||null!=I&&"object"==typeof I&&"Uint8Array"===I.constructor.name}const Io=I=>new DataView(I.buffer,I.byteOffset,I.byteLength),tt=(I,P)=>I<<32-P|I>>>P;if(68!==new Uint8Array(new Uint32Array([287454020]).buffer)[0])throw new Error("Non little-endian hardware is not supported");const ht=Array.from({length:256},(I,P)=>P.toString(16).padStart(2,"0")),Ye={_0:48,_9:57,_A:65,_F:70,_a:97,_f:102};function Ne(I){return I>=Ye._0&&I<=Ye._9?I-Ye._0:I>=Ye._A&&I<=Ye._F?I-(Ye._A-10):I>=Ye._a&&I<=Ye._f?I-(Ye._a-10):void 0}function Dn(I){if("string"!=typeof I)throw new Error("utf8ToBytes expected string, got "+typeof I);return new Uint8Array((new TextEncoder).encode(I))}function Cn(I){if("string"==typeof I&&(I=Dn(I)),!Ii(I))throw new Error("expected Uint8Array, got "+typeof I);return I}function Nn(...I){let P=0;for(let oe=0;oeI().update(Cn(oe)).digest(),$=I();return P.outputLen=$.outputLen,P.blockLen=$.blockLen,P.create=()=>I(),P}class Mi extends jn{constructor(P,$){super(),this.finished=!1,this.destroyed=!1,function qo(I){if("function"!=typeof I||"function"!=typeof I.create)throw new Error("Hash should be wrapped by utils.wrapConstructor");Ni(I.outputLen),Ni(I.blockLen)}(P);const oe=Cn($);if(this.iHash=P.create(),"function"!=typeof this.iHash.update)throw new Error("Expected instance of class which extends utils.Hash");this.blockLen=this.iHash.blockLen,this.outputLen=this.iHash.outputLen;const Ae=this.blockLen,je=new Uint8Array(Ae);je.set(oe.length>Ae?P.create().update(oe).digest():oe);for(let pt=0;ptnew Mi(I,P).update($).digest();Or.create=(I,P)=>new Mi(I,P);class Pr extends jn{constructor(P,$,oe,Ae){super(),this.blockLen=P,this.outputLen=$,this.padOffset=oe,this.isLE=Ae,this.finished=!1,this.length=0,this.pos=0,this.destroyed=!1,this.buffer=new Uint8Array(P),this.view=Io(this.buffer)}update(P){fo(this);const{view:$,buffer:oe,blockLen:Ae}=this,je=(P=Cn(P)).length;for(let pt=0;ptAe-pt&&(this.process(oe,0),pt=0);for(let Qt=pt;Qt>Ae&je),It=Number($&je),ln=oe?0:4;I.setUint32(P+(oe?4:0),pt,oe),I.setUint32(P+ln,It,oe)})(oe,Ae-8,BigInt(8*this.length),je),this.process(oe,0);const It=Io(P),zt=this.outputLen;if(zt%4)throw new Error("_sha2: outputLen should be aligned to 32bit");const ln=zt/4,An=this.get();if(ln>An.length)throw new Error("_sha2: outputLen bigger than state");for(let Qt=0;QtP);let sa=[es],Li=[es.map(I=>(9*I+5)%16)];for(let I=0;I<4;I++)for(let P of[sa,Li])P.push(P[I].map($=>Do[$]));const bi=[[11,14,15,12,5,8,7,9,11,13,14,15,6,7,9,8],[12,13,11,15,6,9,9,7,12,15,11,13,7,8,7,7],[13,15,14,11,7,7,6,8,13,14,13,12,5,5,6,9],[14,11,12,14,8,6,5,5,15,12,15,14,9,9,8,6],[15,12,13,13,9,5,8,6,14,11,12,11,8,6,5,5]].map(I=>new Uint8Array(I)),aa=sa.map((I,P)=>I.map($=>bi[P][$])),Ks=Li.map((I,P)=>I.map($=>bi[P][$])),Oo=new Uint32Array([0,1518500249,1859775393,2400959708,2840853838]),Cs=new Uint32Array([1352829926,1548603684,1836072691,2053994217,0]),No=(I,P)=>I<>>32-P;function hs(I,P,$,oe){return 0===I?P^$^oe:1===I?P&$|~P&oe:2===I?(P|~$)^oe:3===I?P&oe|$&~oe:P^($|~oe)}const Ko=new Uint32Array(16);class mo extends Pr{constructor(){super(64,20,8,!0),this.h0=1732584193,this.h1=-271733879,this.h2=-1732584194,this.h3=271733878,this.h4=-1009589776}get(){const{h0:P,h1:$,h2:oe,h3:Ae,h4:je}=this;return[P,$,oe,Ae,je]}set(P,$,oe,Ae,je){this.h0=0|P,this.h1=0|$,this.h2=0|oe,this.h3=0|Ae,this.h4=0|je}process(P,$){for(let zn=0;zn<16;zn++,$+=4)Ko[zn]=P.getUint32($,!0);let oe=0|this.h0,Ae=oe,je=0|this.h1,pt=je,It=0|this.h2,zt=It,ln=0|this.h3,An=ln,Qt=0|this.h4,Gn=Qt;for(let zn=0;zn<5;zn++){const nr=4-zn,Mn=Oo[zn],Hn=Cs[zn],Xn=sa[zn],vr=Li[zn],$n=aa[zn],Ir=Ks[zn];for(let ir=0;ir<16;ir++){const Cr=No(oe+hs(zn,je,It,ln)+Ko[Xn[ir]]+Mn,$n[ir])+Qt|0;oe=Qt,Qt=ln,ln=0|No(It,10),It=je,je=Cr}for(let ir=0;ir<16;ir++){const Cr=No(Ae+hs(nr,pt,zt,An)+Ko[vr[ir]]+Hn,Ir[ir])+Gn|0;Ae=Gn,Gn=An,An=0|No(zt,10),zt=pt,pt=Cr}}this.set(this.h1+It+An|0,this.h2+ln+Gn|0,this.h3+Qt+Ae|0,this.h4+oe+pt|0,this.h0+je+zt|0)}roundClean(){Ko.fill(0)}destroy(){this.destroyed=!0,this.buffer.fill(0),this.set(0,0,0,0,0)}}const Go=wr(()=>new mo),Rs=(I,P,$)=>I&P^~I&$,Xr=(I,P,$)=>I&P^I&$^P&$,Ds=new Uint32Array([1116352408,1899447441,3049323471,3921009573,961987163,1508970993,2453635748,2870763221,3624381080,310598401,607225278,1426881987,1925078388,2162078206,2614888103,3248222580,3835390401,4022224774,264347078,604807628,770255983,1249150122,1555081692,1996064986,2554220882,2821834349,2952996808,3210313671,3336571891,3584528711,113926993,338241895,666307205,773529912,1294757372,1396182291,1695183700,1986661051,2177026350,2456956037,2730485921,2820302411,3259730800,3345764771,3516065817,3600352804,4094571909,275423344,430227734,506948616,659060556,883997877,958139571,1322822218,1537002063,1747873779,1955562222,2024104815,2227730452,2361852424,2428436474,2756734187,3204031479,3329325298]),go=new Uint32Array([1779033703,3144134277,1013904242,2773480762,1359893119,2600822924,528734635,1541459225]),io=new Uint32Array(64);class fs extends Pr{constructor(){super(64,32,8,!1),this.A=0|go[0],this.B=0|go[1],this.C=0|go[2],this.D=0|go[3],this.E=0|go[4],this.F=0|go[5],this.G=0|go[6],this.H=0|go[7]}get(){const{A:P,B:$,C:oe,D:Ae,E:je,F:pt,G:It,H:zt}=this;return[P,$,oe,Ae,je,pt,It,zt]}set(P,$,oe,Ae,je,pt,It,zt){this.A=0|P,this.B=0|$,this.C=0|oe,this.D=0|Ae,this.E=0|je,this.F=0|pt,this.G=0|It,this.H=0|zt}process(P,$){for(let Qt=0;Qt<16;Qt++,$+=4)io[Qt]=P.getUint32($,!1);for(let Qt=16;Qt<64;Qt++){const Gn=io[Qt-15],zn=io[Qt-2],nr=tt(Gn,7)^tt(Gn,18)^Gn>>>3,Mn=tt(zn,17)^tt(zn,19)^zn>>>10;io[Qt]=Mn+io[Qt-7]+nr+io[Qt-16]|0}let{A:oe,B:Ae,C:je,D:pt,E:It,F:zt,G:ln,H:An}=this;for(let Qt=0;Qt<64;Qt++){const zn=An+(tt(It,6)^tt(It,11)^tt(It,25))+Rs(It,zt,ln)+Ds[Qt]+io[Qt]|0,Mn=(tt(oe,2)^tt(oe,13)^tt(oe,22))+Xr(oe,Ae,je)|0;An=ln,ln=zt,zt=It,It=pt+zn|0,pt=je,je=Ae,Ae=oe,oe=zn+Mn|0}oe=oe+this.A|0,Ae=Ae+this.B|0,je=je+this.C|0,pt=pt+this.D|0,It=It+this.E|0,zt=zt+this.F|0,ln=ln+this.G|0,An=An+this.H|0,this.set(oe,Ae,je,pt,It,zt,ln,An)}roundClean(){io.fill(0)}destroy(){this.set(0,0,0,0,0,0,0,0),this.buffer.fill(0)}}const Qa=wr(()=>new fs),Ao=BigInt(2**32-1),lr=BigInt(32);function As(I,P=!1){return P?{h:Number(I&Ao),l:Number(I>>lr&Ao)}:{h:0|Number(I>>lr&Ao),l:0|Number(I&Ao)}}const te_split=function Gs(I,P=!1){let $=new Uint32Array(I.length),oe=new Uint32Array(I.length);for(let Ae=0;AeI>>>$,te_shrSL=(I,P,$)=>I<<32-$|P>>>$,te_rotrSH=(I,P,$)=>I>>>$|P<<32-$,te_rotrSL=(I,P,$)=>I<<32-$|P>>>$,te_rotrBH=(I,P,$)=>I<<64-$|P>>>$-32,te_rotrBL=(I,P,$)=>I>>>$-32|P<<64-$,te_add=function Da(I,P,$,oe){const Ae=(P>>>0)+(oe>>>0);return{h:I+$+(Ae/2**32|0)|0,l:0|Ae}},te_add3L=(I,P,$)=>(I>>>0)+(P>>>0)+($>>>0),te_add3H=(I,P,$,oe)=>P+$+oe+(I/2**32|0)|0,te_add4L=(I,P,$,oe)=>(I>>>0)+(P>>>0)+($>>>0)+(oe>>>0),te_add4H=(I,P,$,oe,Ae)=>P+$+oe+Ae+(I/2**32|0)|0,te_add5H=(I,P,$,oe,Ae,je)=>P+$+oe+Ae+je+(I/2**32|0)|0,te_add5L=(I,P,$,oe,Ae)=>(I>>>0)+(P>>>0)+($>>>0)+(oe>>>0)+(Ae>>>0),[ot,Ct]=te_split(["0x428a2f98d728ae22","0x7137449123ef65cd","0xb5c0fbcfec4d3b2f","0xe9b5dba58189dbbc","0x3956c25bf348b538","0x59f111f1b605d019","0x923f82a4af194f9b","0xab1c5ed5da6d8118","0xd807aa98a3030242","0x12835b0145706fbe","0x243185be4ee4b28c","0x550c7dc3d5ffb4e2","0x72be5d74f27b896f","0x80deb1fe3b1696b1","0x9bdc06a725c71235","0xc19bf174cf692694","0xe49b69c19ef14ad2","0xefbe4786384f25e3","0x0fc19dc68b8cd5b5","0x240ca1cc77ac9c65","0x2de92c6f592b0275","0x4a7484aa6ea6e483","0x5cb0a9dcbd41fbd4","0x76f988da831153b5","0x983e5152ee66dfab","0xa831c66d2db43210","0xb00327c898fb213f","0xbf597fc7beef0ee4","0xc6e00bf33da88fc2","0xd5a79147930aa725","0x06ca6351e003826f","0x142929670a0e6e70","0x27b70a8546d22ffc","0x2e1b21385c26c926","0x4d2c6dfc5ac42aed","0x53380d139d95b3df","0x650a73548baf63de","0x766a0abb3c77b2a8","0x81c2c92e47edaee6","0x92722c851482353b","0xa2bfe8a14cf10364","0xa81a664bbc423001","0xc24b8b70d0f89791","0xc76c51a30654be30","0xd192e819d6ef5218","0xd69906245565a910","0xf40e35855771202a","0x106aa07032bbd1b8","0x19a4c116b8d2d0c8","0x1e376c085141ab53","0x2748774cdf8eeb99","0x34b0bcb5e19b48a8","0x391c0cb3c5c95a63","0x4ed8aa4ae3418acb","0x5b9cca4f7763e373","0x682e6ff3d6b2b8a3","0x748f82ee5defb2fc","0x78a5636f43172f60","0x84c87814a1f0ab72","0x8cc702081a6439ec","0x90befffa23631e28","0xa4506cebde82bde9","0xbef9a3f7b2c67915","0xc67178f2e372532b","0xca273eceea26619c","0xd186b8c721c0c207","0xeada7dd6cde0eb1e","0xf57d4f7fee6ed178","0x06f067aa72176fba","0x0a637dc5a2c898a6","0x113f9804bef90dae","0x1b710b35131c471b","0x28db77f523047d84","0x32caab7b40c72493","0x3c9ebe0a15c9bebc","0x431d67c49c100d4c","0x4cc5d4becb3e42b6","0x597f299cfc657e2a","0x5fcb6fab3ad6faec","0x6c44198c4a475817"].map(I=>BigInt(I))),Bn=new Uint32Array(80),On=new Uint32Array(80);class Wn extends Pr{constructor(){super(128,64,16,!1),this.Ah=1779033703,this.Al=-205731576,this.Bh=-1150833019,this.Bl=-2067093701,this.Ch=1013904242,this.Cl=-23791573,this.Dh=-1521486534,this.Dl=1595750129,this.Eh=1359893119,this.El=-1377402159,this.Fh=-1694144372,this.Fl=725511199,this.Gh=528734635,this.Gl=-79577749,this.Hh=1541459225,this.Hl=327033209}get(){const{Ah:P,Al:$,Bh:oe,Bl:Ae,Ch:je,Cl:pt,Dh:It,Dl:zt,Eh:ln,El:An,Fh:Qt,Fl:Gn,Gh:zn,Gl:nr,Hh:Mn,Hl:Hn}=this;return[P,$,oe,Ae,je,pt,It,zt,ln,An,Qt,Gn,zn,nr,Mn,Hn]}set(P,$,oe,Ae,je,pt,It,zt,ln,An,Qt,Gn,zn,nr,Mn,Hn){this.Ah=0|P,this.Al=0|$,this.Bh=0|oe,this.Bl=0|Ae,this.Ch=0|je,this.Cl=0|pt,this.Dh=0|It,this.Dl=0|zt,this.Eh=0|ln,this.El=0|An,this.Fh=0|Qt,this.Fl=0|Gn,this.Gh=0|zn,this.Gl=0|nr,this.Hh=0|Mn,this.Hl=0|Hn}process(P,$){for(let $n=0;$n<16;$n++,$+=4)Bn[$n]=P.getUint32($),On[$n]=P.getUint32($+=4);for(let $n=16;$n<80;$n++){const Ir=0|Bn[$n-15],ir=0|On[$n-15],Cr=te_rotrSH(Ir,ir,1)^te_rotrSH(Ir,ir,8)^te_shrSH(Ir,ir,7),Gr=te_rotrSL(Ir,ir,1)^te_rotrSL(Ir,ir,8)^te_shrSL(Ir,ir,7),Br=0|Bn[$n-2],ro=0|On[$n-2],Ji=te_rotrSH(Br,ro,19)^te_rotrBH(Br,ro,61)^te_shrSH(Br,ro,6),Xi=te_rotrSL(Br,ro,19)^te_rotrBL(Br,ro,61)^te_shrSL(Br,ro,6),bo=te_add4L(Gr,Xi,On[$n-7],On[$n-16]),To=te_add4H(bo,Cr,Ji,Bn[$n-7],Bn[$n-16]);Bn[$n]=0|To,On[$n]=0|bo}let{Ah:oe,Al:Ae,Bh:je,Bl:pt,Ch:It,Cl:zt,Dh:ln,Dl:An,Eh:Qt,El:Gn,Fh:zn,Fl:nr,Gh:Mn,Gl:Hn,Hh:Xn,Hl:vr}=this;for(let $n=0;$n<80;$n++){const Ir=te_rotrSH(Qt,Gn,14)^te_rotrSH(Qt,Gn,18)^te_rotrBH(Qt,Gn,41),ir=te_rotrSL(Qt,Gn,14)^te_rotrSL(Qt,Gn,18)^te_rotrBL(Qt,Gn,41),Cr=Qt&zn^~Qt&Mn,Br=te_add5L(vr,ir,Gn&nr^~Gn&Hn,Ct[$n],On[$n]),ro=te_add5H(Br,Xn,Ir,Cr,ot[$n],Bn[$n]),Ji=0|Br,Xi=te_rotrSH(oe,Ae,28)^te_rotrBH(oe,Ae,34)^te_rotrBH(oe,Ae,39),bo=te_rotrSL(oe,Ae,28)^te_rotrBL(oe,Ae,34)^te_rotrBL(oe,Ae,39),To=oe&je^oe&It^je&It,ga=Ae&pt^Ae&zt^pt&zt;Xn=0|Mn,vr=0|Hn,Mn=0|zn,Hn=0|nr,zn=0|Qt,nr=0|Gn,({h:Qt,l:Gn}=te_add(0|ln,0|An,0|ro,0|Ji)),ln=0|It,An=0|zt,It=0|je,zt=0|pt,je=0|oe,pt=0|Ae;const _r=te_add3L(Ji,bo,ga);oe=te_add3H(_r,ro,Xi,To),Ae=0|_r}({h:oe,l:Ae}=te_add(0|this.Ah,0|this.Al,0|oe,0|Ae)),({h:je,l:pt}=te_add(0|this.Bh,0|this.Bl,0|je,0|pt)),({h:It,l:zt}=te_add(0|this.Ch,0|this.Cl,0|It,0|zt)),({h:ln,l:An}=te_add(0|this.Dh,0|this.Dl,0|ln,0|An)),({h:Qt,l:Gn}=te_add(0|this.Eh,0|this.El,0|Qt,0|Gn)),({h:zn,l:nr}=te_add(0|this.Fh,0|this.Fl,0|zn,0|nr)),({h:Mn,l:Hn}=te_add(0|this.Gh,0|this.Gl,0|Mn,0|Hn)),({h:Xn,l:vr}=te_add(0|this.Hh,0|this.Hl,0|Xn,0|vr)),this.set(oe,Ae,je,pt,It,zt,ln,An,Qt,Gn,zn,nr,Mn,Hn,Xn,vr)}roundClean(){Bn.fill(0),On.fill(0)}destroy(){this.buffer.fill(0),this.set(0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0)}}const Mr=wr(()=>new Wn);function Fi(I){if(!Number.isSafeInteger(I)||I<0)throw new Error(`Wrong positive integer: ${I}`)}function jo(I,...P){if(!(I instanceof Uint8Array))throw new Error("Expected Uint8Array");if(P.length>0&&!P.includes(I.length))throw new Error(`Expected Uint8Array of length ${P}, not of length=${I.length}`)}const de={number:Fi,bool:function Ro(I){if("boolean"!=typeof I)throw new Error(`Expected boolean, not ${I}`)},bytes:jo,hash:function Ho(I){if("function"!=typeof I||"function"!=typeof I.create)throw new Error("Hash should be wrapped by utils.wrapConstructor");Fi(I.outputLen),Fi(I.blockLen)},exists:function Ua(I,P=!0){if(I.destroyed)throw new Error("Hash instance has been destroyed");if(P&&I.finished)throw new Error("Hash#digest() has already been called")},output:function $a(I,P){jo(I);const $=P.outputLen;if(I.length<$)throw new Error(`digestInto() expects output buffer of length at least ${$}`)}},he="object"==typeof globalThis&&"crypto"in globalThis?globalThis.crypto:void 0,Y=I=>I instanceof Uint8Array,br=I=>new DataView(I.buffer,I.byteOffset,I.byteLength),Jr=(I,P)=>I<<32-P|I>>>P;if(68!==new Uint8Array(new Uint32Array([287454020]).buffer)[0])throw new Error("Non little-endian hardware is not supported");function vs(I){if("string"==typeof I&&(I=function cs(I){if("string"!=typeof I)throw new Error("utf8ToBytes expected string, got "+typeof I);return new Uint8Array((new TextEncoder).encode(I))}(I)),!Y(I))throw new Error("expected Uint8Array, got "+typeof I);return I}Array.from({length:256},(I,P)=>P.toString(16).padStart(2,"0"));class bl{clone(){return this._cloneInto()}}function ul(I){const P=oe=>I().update(vs(oe)).digest(),$=I();return P.outputLen=$.outputLen,P.blockLen=$.blockLen,P.create=()=>I(),P}function eu(I=32){if(he&&"function"==typeof he.getRandomValues)return he.getRandomValues(new Uint8Array(I));throw new Error("crypto.getRandomValues must be defined")}class dl extends bl{constructor(P,$,oe,Ae){super(),this.blockLen=P,this.outputLen=$,this.padOffset=oe,this.isLE=Ae,this.finished=!1,this.length=0,this.pos=0,this.destroyed=!1,this.buffer=new Uint8Array(P),this.view=br(this.buffer)}update(P){de.exists(this);const{view:$,buffer:oe,blockLen:Ae}=this,je=(P=vs(P)).length;for(let pt=0;ptAe-pt&&(this.process(oe,0),pt=0);for(let Qt=pt;Qt>Ae&je),It=Number($&je),ln=oe?0:4;I.setUint32(P+(oe?4:0),pt,oe),I.setUint32(P+ln,It,oe)})(oe,Ae-8,BigInt(8*this.length),je),this.process(oe,0);const It=br(P),zt=this.outputLen;if(zt%4)throw new Error("_sha2: outputLen should be aligned to 32bit");const ln=zt/4,An=this.get();if(ln>An.length)throw new Error("_sha2: outputLen bigger than state");for(let Qt=0;QtI&P^~I&$,Ol=(I,P,$)=>I&P^I&$^P&$,Sa=new Uint32Array([1116352408,1899447441,3049323471,3921009573,961987163,1508970993,2453635748,2870763221,3624381080,310598401,607225278,1426881987,1925078388,2162078206,2614888103,3248222580,3835390401,4022224774,264347078,604807628,770255983,1249150122,1555081692,1996064986,2554220882,2821834349,2952996808,3210313671,3336571891,3584528711,113926993,338241895,666307205,773529912,1294757372,1396182291,1695183700,1986661051,2177026350,2456956037,2730485921,2820302411,3259730800,3345764771,3516065817,3600352804,4094571909,275423344,430227734,506948616,659060556,883997877,958139571,1322822218,1537002063,1747873779,1955562222,2024104815,2227730452,2361852424,2428436474,2756734187,3204031479,3329325298]),ks=new Uint32Array([1779033703,3144134277,1013904242,2773480762,1359893119,2600822924,528734635,1541459225]),js=new Uint32Array(64);class nu extends dl{constructor(){super(64,32,8,!1),this.A=0|ks[0],this.B=0|ks[1],this.C=0|ks[2],this.D=0|ks[3],this.E=0|ks[4],this.F=0|ks[5],this.G=0|ks[6],this.H=0|ks[7]}get(){const{A:P,B:$,C:oe,D:Ae,E:je,F:pt,G:It,H:zt}=this;return[P,$,oe,Ae,je,pt,It,zt]}set(P,$,oe,Ae,je,pt,It,zt){this.A=0|P,this.B=0|$,this.C=0|oe,this.D=0|Ae,this.E=0|je,this.F=0|pt,this.G=0|It,this.H=0|zt}process(P,$){for(let Qt=0;Qt<16;Qt++,$+=4)js[Qt]=P.getUint32($,!1);for(let Qt=16;Qt<64;Qt++){const Gn=js[Qt-15],zn=js[Qt-2],nr=Jr(Gn,7)^Jr(Gn,18)^Gn>>>3,Mn=Jr(zn,17)^Jr(zn,19)^zn>>>10;js[Qt]=Mn+js[Qt-7]+nr+js[Qt-16]|0}let{A:oe,B:Ae,C:je,D:pt,E:It,F:zt,G:ln,H:An}=this;for(let Qt=0;Qt<64;Qt++){const zn=An+(Jr(It,6)^Jr(It,11)^Jr(It,25))+$s(It,zt,ln)+Sa[Qt]+js[Qt]|0,Mn=(Jr(oe,2)^Jr(oe,13)^Jr(oe,22))+Ol(oe,Ae,je)|0;An=ln,ln=zt,zt=It,It=pt+zn|0,pt=je,je=Ae,Ae=oe,oe=zn+Mn|0}oe=oe+this.A|0,Ae=Ae+this.B|0,je=je+this.C|0,pt=pt+this.D|0,It=It+this.E|0,zt=zt+this.F|0,ln=ln+this.G|0,An=An+this.H|0,this.set(oe,Ae,je,pt,It,zt,ln,An)}roundClean(){js.fill(0)}destroy(){this.set(0,0,0,0,0,0,0,0),this.buffer.fill(0)}}class ns extends nu{constructor(){super(),this.A=-1056596264,this.B=914150663,this.C=812702999,this.D=-150054599,this.E=-4191439,this.F=1750603025,this.G=1694076839,this.H=-1090891868,this.outputLen=28}}const ru=ul(()=>new nu),jl=(ul(()=>new ns),BigInt(0),BigInt(1)),hl=BigInt(2),Vl=I=>I instanceof Uint8Array,Hl=Array.from({length:256},(I,P)=>P.toString(16).padStart(2,"0"));function ha(I){if(!Vl(I))throw new Error("Uint8Array expected");let P="";for(let $=0;$oe+Ae.length,0));let $=0;return I.forEach(oe=>{if(!Vl(oe))throw new Error("Uint8Array expected");P.set(oe,$),$+=oe.length}),P}const Xs=I=>(hl<new Uint8Array(I),Uo=I=>Uint8Array.from(I);function vo(I,P,$){if("number"!=typeof I||I<2)throw new Error("hashLen must be a number");if("number"!=typeof P||P<2)throw new Error("qByteLen must be a number");if("function"!=typeof $)throw new Error("hmacFn must be a function");let oe=Za(I),Ae=Za(I),je=0;const pt=()=>{oe.fill(1),Ae.fill(0),je=0},It=(...Qt)=>$(Ae,oe,...Qt),zt=(Qt=Za())=>{Ae=It(Uo([0]),Qt),oe=It(),0!==Qt.length&&(Ae=It(Uo([1]),Qt),oe=It())},ln=()=>{if(je++>=1e3)throw new Error("drbg: tried 1000 values");let Qt=0;const Gn=[];for(;Qt{let zn;for(pt(),zt(Qt);!(zn=Gn(ln()));)zt();return pt(),zn}}const Ci={bigint:I=>"bigint"==typeof I,function:I=>"function"==typeof I,boolean:I=>"boolean"==typeof I,string:I=>"string"==typeof I,isSafeInteger:I=>Number.isSafeInteger(I),array:I=>Array.isArray(I),field:(I,P)=>P.Fp.isValid(I),hash:I=>"function"==typeof I&&Number.isSafeInteger(I.outputLen)};function Vs(I,P,$={}){const oe=(Ae,je,pt)=>{const It=Ci[je];if("function"!=typeof It)throw new Error(`Invalid validator "${je}", expected function`);const zt=I[Ae];if(!(pt&&void 0===zt||It(zt,I)))throw new Error(`Invalid param ${String(Ae)}=${zt} (${typeof zt}), expected ${je}`)};for(const[Ae,je]of Object.entries(P))oe(Ae,je,!1);for(const[Ae,je]of Object.entries($))oe(Ae,je,!0);return I}const uo=BigInt(0),Ui=BigInt(1),U=BigInt(2),Ie=BigInt(3),ne=BigInt(4),ye=BigInt(5),Et=BigInt(8);function tr(I,P){const $=I%P;return $>=uo?$:P+$}function ci(I,P,$){if($<=uo||P 0");if($===Ui)return uo;let oe=Ui;for(;P>uo;)P&Ui&&(oe=oe*I%$),I=I*I%$,P>>=Ui;return oe}function ki(I,P,$){let oe=I;for(;P-- >uo;)oe*=oe,oe%=$;return oe}function Di(I,P){if(I===uo||P<=uo)throw new Error(`invert: expected positive integers, got n=${I} mod=${P}`);let $=tr(I,P),oe=P,Ae=uo,je=Ui,pt=Ui,It=uo;for(;$!==uo;){const ln=oe/$,An=oe%$,Qt=Ae-pt*ln,Gn=je-It*ln;oe=$,$=An,Ae=pt,je=It,pt=Qt,It=Gn}if(oe!==Ui)throw new Error("invert: does not exist");return tr(Ae,P)}BigInt(9),BigInt(16);const wi=["create","isValid","is0","neg","inv","sqrt","sqr","eql","add","sub","mul","pow","div","addN","subN","mulN","sqrN"];function Ls(I,P){const $=void 0!==P?P:I.toString(2).length;return{nBitLength:$,nByteLength:Math.ceil($/8)}}const ka=BigInt(0),Ia=BigInt(1);function su(I){return function bs(I){Vs(I,wi.reduce((oe,Ae)=>(oe[Ae]="function",oe),{ORDER:"bigint",MASK:"bigint",BYTES:"isSafeInteger",BITS:"isSafeInteger"}))}(I.Fp),Vs(I,{n:"bigint",h:"bigint",Gx:"field",Gy:"field"},{nBitLength:"isSafeInteger",nByteLength:"isSafeInteger"}),Object.freeze({...Ls(I.n,I.nBitLength),...I,p:I.Fp.ORDER})}const{Ph:Wl,aT:pc}=i,fl={Err:class extends Error{constructor(P=""){super(P)}},_parseInt(I){const{Err:P}=fl;if(I.length<2||2!==I[0])throw new P("Invalid signature integer tag");const $=I[1],oe=I.subarray(2,$+2);if(!$||oe.length!==$)throw new P("Invalid signature integer: wrong length");if(128&oe[0])throw new P("Invalid signature integer: negative");if(0===oe[0]&&!(128&oe[1]))throw new P("Invalid signature integer: unnecessary leading zero");return{d:Wl(oe),l:I.subarray($+2)}},toSig(I){const{Err:P}=fl,$="string"==typeof I?pc(I):I;if(!($ instanceof Uint8Array))throw new Error("ui8a expected");let oe=$.length;if(oe<2||48!=$[0])throw new P("Invalid signature tag");if($[1]!==oe-2)throw new P("Invalid signature: incorrect length");const{d:Ae,l:je}=fl._parseInt($.subarray(2)),{d:pt,l:It}=fl._parseInt(je);if(It.length)throw new P("Invalid signature: left bytes after parsing");return{r:Ae,s:pt}},hexFromSig(I){const P=ln=>8&Number.parseInt(ln[0],16)?"00"+ln:ln,$=ln=>{const An=ln.toString(16);return 1&An.length?`0${An}`:An},oe=P($(I.s)),Ae=P($(I.r)),je=oe.length/2,pt=Ae.length/2,It=$(je),zt=$(pt);return`30${$(pt+je+4)}02${zt}${Ae}02${It}${oe}`}},yo=BigInt(0),zo=BigInt(1),au=(BigInt(2),BigInt(3));function ah(I){const P=function Bu(I){const P=su(I);return Vs(P,{hash:"hash",hmac:"function",randomBytes:"function"},{bits2int:"function",bits2int_modN:"function",lowS:"boolean"}),Object.freeze({lowS:!0,...P})}(I),{Fp:$,n:oe}=P,Ae=$.BYTES+1,je=2*$.BYTES+1;function It(_r){return tr(_r,oe)}function zt(_r){return Di(_r,oe)}const{ProjectivePoint:ln,normPrivateKeyToScalar:An,weierstrassEquation:Qt,isWithinCurveOrder:Gn}=function lu(I){const P=function Fu(I){const P=su(I);Vs(P,{a:"field",b:"field"},{allowedPrivateKeyLengths:"array",wrapPrivateKey:"boolean",isTorsionFree:"function",clearCofactor:"function",allowInfinityPoint:"boolean",fromBytes:"function",toBytes:"function"});const{endo:$,Fp:oe,a:Ae}=P;if($){if(!oe.eql(Ae,oe.ZERO))throw new Error("Endomorphism can only be defined for Koblitz curves that have a=0");if("object"!=typeof $||"bigint"!=typeof $.beta||"function"!=typeof $.splitScalar)throw new Error("Expected endomorphism with beta: bigint and splitScalar: function")}return Object.freeze({...P})}(I),{Fp:$}=P,oe=P.toBytes||((nr,Mn,Hn)=>{const Xn=Mn.toAffine();return so(Uint8Array.from([4]),$.toBytes(Xn.x),$.toBytes(Xn.y))}),Ae=P.fromBytes||(nr=>{const Mn=nr.subarray(1);return{x:$.fromBytes(Mn.subarray(0,$.BYTES)),y:$.fromBytes(Mn.subarray($.BYTES,2*$.BYTES))}});function je(nr){const{a:Mn,b:Hn}=P,Xn=$.sqr(nr),vr=$.mul(Xn,nr);return $.add($.add(vr,$.mul(nr,Mn)),Hn)}if(!$.eql($.sqr(P.Gy),je(P.Gx)))throw new Error("bad generator point: equation left != right");function pt(nr){return"bigint"==typeof nr&&yo$.eql($n,$.ZERO);return vr(Hn)&&vr(Xn)?Qt.ZERO:new Qt(Hn,Xn,$.ONE)}get x(){return this.toAffine().x}get y(){return this.toAffine().y}static normalizeZ(Mn){const Hn=$.invertBatch(Mn.map(Xn=>Xn.pz));return Mn.map((Xn,vr)=>Xn.toAffine(Hn[vr])).map(Qt.fromAffine)}static fromHex(Mn){const Hn=Qt.fromAffine(Ae(Qi("pointHex",Mn)));return Hn.assertValidity(),Hn}static fromPrivateKey(Mn){return Qt.BASE.multiply(zt(Mn))}_setWindowSize(Mn){this._WINDOW_SIZE=Mn,ln.delete(this)}assertValidity(){if(this.is0()){if(P.allowInfinityPoint)return;throw new Error("bad point: ZERO")}const{x:Mn,y:Hn}=this.toAffine();if(!$.isValid(Mn)||!$.isValid(Hn))throw new Error("bad point: x or y not FE");const Xn=$.sqr(Hn),vr=je(Mn);if(!$.eql(Xn,vr))throw new Error("bad point: equation left != right");if(!this.isTorsionFree())throw new Error("bad point: not in prime-order subgroup")}hasEvenY(){const{y:Mn}=this.toAffine();if($.isOdd)return!$.isOdd(Mn);throw new Error("Field doesn't support isOdd")}equals(Mn){An(Mn);const{px:Hn,py:Xn,pz:vr}=this,{px:$n,py:Ir,pz:ir}=Mn,Cr=$.eql($.mul(Hn,ir),$.mul($n,vr)),Gr=$.eql($.mul(Xn,ir),$.mul(Ir,vr));return Cr&&Gr}negate(){return new Qt(this.px,$.neg(this.py),this.pz)}double(){const{a:Mn,b:Hn}=P,Xn=$.mul(Hn,au),{px:vr,py:$n,pz:Ir}=this;let ir=$.ZERO,Cr=$.ZERO,Gr=$.ZERO,Br=$.mul(vr,vr),ro=$.mul($n,$n),Ji=$.mul(Ir,Ir),Xi=$.mul(vr,$n);return Xi=$.add(Xi,Xi),Gr=$.mul(vr,Ir),Gr=$.add(Gr,Gr),ir=$.mul(Mn,Gr),Cr=$.mul(Xn,Ji),Cr=$.add(ir,Cr),ir=$.sub(ro,Cr),Cr=$.add(ro,Cr),Cr=$.mul(ir,Cr),ir=$.mul(Xi,ir),Gr=$.mul(Xn,Gr),Ji=$.mul(Mn,Ji),Xi=$.sub(Br,Ji),Xi=$.mul(Mn,Xi),Xi=$.add(Xi,Gr),Gr=$.add(Br,Br),Br=$.add(Gr,Br),Br=$.add(Br,Ji),Br=$.mul(Br,Xi),Cr=$.add(Cr,Br),Ji=$.mul($n,Ir),Ji=$.add(Ji,Ji),Br=$.mul(Ji,Xi),ir=$.sub(ir,Br),Gr=$.mul(Ji,ro),Gr=$.add(Gr,Gr),Gr=$.add(Gr,Gr),new Qt(ir,Cr,Gr)}add(Mn){An(Mn);const{px:Hn,py:Xn,pz:vr}=this,{px:$n,py:Ir,pz:ir}=Mn;let Cr=$.ZERO,Gr=$.ZERO,Br=$.ZERO;const ro=P.a,Ji=$.mul(P.b,au);let Xi=$.mul(Hn,$n),bo=$.mul(Xn,Ir),To=$.mul(vr,ir),ga=$.add(Hn,Xn),_r=$.add($n,Ir);ga=$.mul(ga,_r),_r=$.add(Xi,bo),ga=$.sub(ga,_r),_r=$.add(Hn,vr);let jr=$.add($n,ir);return _r=$.mul(_r,jr),jr=$.add(Xi,To),_r=$.sub(_r,jr),jr=$.add(Xn,vr),Cr=$.add(Ir,ir),jr=$.mul(jr,Cr),Cr=$.add(bo,To),jr=$.sub(jr,Cr),Br=$.mul(ro,_r),Cr=$.mul(Ji,To),Br=$.add(Cr,Br),Cr=$.sub(bo,Br),Br=$.add(bo,Br),Gr=$.mul(Cr,Br),bo=$.add(Xi,Xi),bo=$.add(bo,Xi),To=$.mul(ro,To),_r=$.mul(Ji,_r),bo=$.add(bo,To),To=$.sub(Xi,To),To=$.mul(ro,To),_r=$.add(_r,To),Xi=$.mul(bo,_r),Gr=$.add(Gr,Xi),Xi=$.mul(jr,_r),Cr=$.mul(ga,Cr),Cr=$.sub(Cr,Xi),Xi=$.mul(ga,bo),Br=$.mul(jr,Br),Br=$.add(Br,Xi),new Qt(Cr,Gr,Br)}subtract(Mn){return this.add(Mn.negate())}is0(){return this.equals(Qt.ZERO)}wNAF(Mn){return zn.wNAFCached(this,ln,Mn,Hn=>{const Xn=$.invertBatch(Hn.map(vr=>vr.pz));return Hn.map((vr,$n)=>vr.toAffine(Xn[$n])).map(Qt.fromAffine)})}multiplyUnsafe(Mn){const Hn=Qt.ZERO;if(Mn===yo)return Hn;if(It(Mn),Mn===zo)return this;const{endo:Xn}=P;if(!Xn)return zn.unsafeLadder(this,Mn);let{k1neg:vr,k1:$n,k2neg:Ir,k2:ir}=Xn.splitScalar(Mn),Cr=Hn,Gr=Hn,Br=this;for(;$n>yo||ir>yo;)$n&zo&&(Cr=Cr.add(Br)),ir&zo&&(Gr=Gr.add(Br)),Br=Br.double(),$n>>=zo,ir>>=zo;return vr&&(Cr=Cr.negate()),Ir&&(Gr=Gr.negate()),Gr=new Qt($.mul(Gr.px,Xn.beta),Gr.py,Gr.pz),Cr.add(Gr)}multiply(Mn){It(Mn);let Xn,vr,Hn=Mn;const{endo:$n}=P;if($n){const{k1neg:Ir,k1:ir,k2neg:Cr,k2:Gr}=$n.splitScalar(Hn);let{p:Br,f:ro}=this.wNAF(ir),{p:Ji,f:Xi}=this.wNAF(Gr);Br=zn.constTimeNegate(Ir,Br),Ji=zn.constTimeNegate(Cr,Ji),Ji=new Qt($.mul(Ji.px,$n.beta),Ji.py,Ji.pz),Xn=Br.add(Ji),vr=ro.add(Xi)}else{const{p:Ir,f:ir}=this.wNAF(Hn);Xn=Ir,vr=ir}return Qt.normalizeZ([Xn,vr])[0]}multiplyAndAddUnsafe(Mn,Hn,Xn){const vr=Qt.BASE,$n=(ir,Cr)=>Cr!==yo&&Cr!==zo&&ir.equals(vr)?ir.multiply(Cr):ir.multiplyUnsafe(Cr),Ir=$n(this,Hn).add($n(Mn,Xn));return Ir.is0()?void 0:Ir}toAffine(Mn){const{px:Hn,py:Xn,pz:vr}=this,$n=this.is0();null==Mn&&(Mn=$n?$.ONE:$.inv(vr));const Ir=$.mul(Hn,Mn),ir=$.mul(Xn,Mn),Cr=$.mul(vr,Mn);if($n)return{x:$.ZERO,y:$.ZERO};if(!$.eql(Cr,$.ONE))throw new Error("invZ was invalid");return{x:Ir,y:ir}}isTorsionFree(){const{h:Mn,isTorsionFree:Hn}=P;if(Mn===zo)return!0;if(Hn)return Hn(Qt,this);throw new Error("isTorsionFree() has not been declared for the elliptic curve")}clearCofactor(){const{h:Mn,clearCofactor:Hn}=P;return Mn===zo?this:Hn?Hn(Qt,this):this.multiplyUnsafe(P.h)}toRawBytes(Mn=!0){return this.assertValidity(),oe(Qt,this,Mn)}toHex(Mn=!0){return ha(this.toRawBytes(Mn))}}Qt.BASE=new Qt(P.Gx,P.Gy,$.ONE),Qt.ZERO=new Qt($.ZERO,$.ONE,$.ZERO);const Gn=P.nBitLength,zn=function Rl(I,P){const $=(Ae,je)=>{const pt=je.negate();return Ae?pt:je},oe=Ae=>({windows:Math.ceil(P/Ae)+1,windowSize:2**(Ae-1)});return{constTimeNegate:$,unsafeLadder(Ae,je){let pt=I.ZERO,It=Ae;for(;je>ka;)je&Ia&&(pt=pt.add(It)),It=It.double(),je>>=Ia;return pt},precomputeWindow(Ae,je){const{windows:pt,windowSize:It}=oe(je),zt=[];let ln=Ae,An=ln;for(let Qt=0;Qt>=zn,Hn>zt&&(Hn-=Gn,pt+=Ia);const Xn=Mn,vr=Mn+Math.abs(Hn)-1,Ir=Hn<0;0===Hn?An=An.add($(nr%2!=0,je[Xn])):ln=ln.add($(Ir,je[vr]))}return{p:ln,f:An}},wNAFCached(Ae,je,pt,It){const zt=Ae._WINDOW_SIZE||1;let ln=je.get(Ae);return ln||(ln=this.precomputeWindow(Ae,zt),1!==zt&&je.set(Ae,It(ln))),this.wNAF(zt,ln,pt)}}}(Qt,P.endo?Math.ceil(Gn/2):Gn);return{CURVE:P,ProjectivePoint:Qt,normPrivateKeyToScalar:zt,weierstrassEquation:je,isWithinCurveOrder:pt}}({...P,toBytes(_r,jr,Hi){const Yi=jr.toAffine(),Mo=$.toBytes(Yi.x),gs=so;return Hi?gs(Uint8Array.from([jr.hasEvenY()?2:3]),Mo):gs(Uint8Array.from([4]),Mo,$.toBytes(Yi.y))},fromBytes(_r){const jr=_r.length,Hi=_r[0],Yi=_r.subarray(1);if(jr!==Ae||2!==Hi&&3!==Hi){if(jr===je&&4===Hi)return{x:$.fromBytes(Yi.subarray(0,$.BYTES)),y:$.fromBytes(Yi.subarray($.BYTES,2*$.BYTES))};throw new Error(`Point of length ${jr} was invalid. Expected ${Ae} compressed bytes or ${je} uncompressed bytes`)}{const Mo=oo(Yi);if(!function pt(_r){return yo<_r&&_r<$.ORDER}(Mo))throw new Error("Point is not on curve");const gs=Qt(Mo);let qs=$.sqrt(gs);return!(1&~Hi)!=((qs&zo)===zo)&&(qs=$.neg(qs)),{x:Mo,y:qs}}}}),zn=_r=>ha(Sr(_r,P.nByteLength));function nr(_r){return _r>oe>>zo}const Hn=(_r,jr,Hi)=>oo(_r.slice(jr,Hi));class Xn{constructor(jr,Hi,Yi){this.r=jr,this.s=Hi,this.recovery=Yi,this.assertValidity()}static fromCompact(jr){const Hi=P.nByteLength;return jr=Qi("compactSignature",jr,2*Hi),new Xn(Hn(jr,0,Hi),Hn(jr,Hi,2*Hi))}static fromDER(jr){const{r:Hi,s:Yi}=fl.toSig(Qi("DER",jr));return new Xn(Hi,Yi)}assertValidity(){if(!Gn(this.r))throw new Error("r must be 0 < r < CURVE.n");if(!Gn(this.s))throw new Error("s must be 0 < s < CURVE.n")}addRecoveryBit(jr){return new Xn(this.r,this.s,jr)}recoverPublicKey(jr){const{r:Hi,s:Yi,recovery:Mo}=this,gs=Gr(Qi("msgHash",jr));if(null==Mo||![0,1,2,3].includes(Mo))throw new Error("recovery id invalid");const qs=2===Mo||3===Mo?Hi+P.n:Hi;if(qs>=$.ORDER)throw new Error("recovery id 2 or 3 invalid");const el=ln.fromHex((1&Mo?"03":"02")+zn(qs)),Dl=zt(qs),Jl=It(-gs*Dl),vc=It(Yi*Dl),ec=ln.BASE.multiplyAndAddUnsafe(el,Jl,vc);if(!ec)throw new Error("point at infinify");return ec.assertValidity(),ec}hasHighS(){return nr(this.s)}normalizeS(){return this.hasHighS()?new Xn(this.r,It(-this.s),this.recovery):this}toDERRawBytes(){return Wo(this.toDERHex())}toDERHex(){return fl.hexFromSig({r:this.r,s:this.s})}toCompactRawBytes(){return Wo(this.toCompactHex())}toCompactHex(){return zn(this.r)+zn(this.s)}}const vr={isValidPrivateKey(_r){try{return An(_r),!0}catch{return!1}},normPrivateKeyToScalar:An,randomPrivateKey:()=>{const jr=function ou(I,P,$=!1){const oe=(I=Qi("privateHash",I)).length,Ae=Ls(P).nByteLength+8;if(Ae<24||oe1024)throw new Error(`hashToPrivateScalar: expected ${Ae}-1024 bytes of input, got ${oe}`);return tr($?Fn(I):oo(I),P-Ui)+Ui}(P.randomBytes($.BYTES+8),oe);return Sr(jr,P.nByteLength)},precompute:(_r=8,jr=ln.BASE)=>(jr._setWindowSize(_r),jr.multiply(BigInt(3)),jr)};function Ir(_r){const jr=_r instanceof Uint8Array,Hi="string"==typeof _r,Yi=(jr||Hi)&&_r.length;return jr?Yi===Ae||Yi===je:Hi?Yi===2*Ae||Yi===2*je:_r instanceof ln}const Cr=P.bits2int||function(_r){const jr=oo(_r),Hi=8*_r.length-P.nBitLength;return Hi>0?jr>>BigInt(Hi):jr},Gr=P.bits2int_modN||function(_r){return It(Cr(_r))},Br=Xs(P.nBitLength);function ro(_r){if("bigint"!=typeof _r)throw new Error("bigint expected");if(!(yo<=_r&&_rtc in Hi))throw new Error("sign() legacy options not supported");const{hash:Yi,randomBytes:Mo}=P;let{lowS:gs,prehash:qs,extraEntropy:Ps}=Hi;null==gs&&(gs=!0),_r=Qi("msgHash",_r),qs&&(_r=Qi("prehashed msgHash",Yi(_r)));const el=Gr(_r),Dl=An(jr),Jl=[ro(Dl),ro(el)];if(null!=Ps){const tc=!0===Ps?Mo($.BYTES):Ps;Jl.push(Qi("extraEntropy",tc,$.BYTES))}const vc=so(...Jl),ec=el;return{seed:vc,k2sig:function yc(tc){const Rc=Cr(tc);if(!Gn(Rc))return;const mh=zt(Rc),Js=ln.BASE.multiply(Rc).toAffine(),ml=It(Js.x);if(ml===yo)return;const bc=It(mh*It(ec+ml*Dl));if(bc===yo)return;let nc=(Js.x===ml?0:2)|Number(Js.y&zo),ju=bc;return gs&&nr(bc)&&(ju=function Mn(_r){return nr(_r)?It(-_r):_r}(bc),nc^=1),new Xn(ml,ju,nc)}}}(_r,jr,Hi);return vo(P.hash.outputLen,P.nByteLength,P.hmac)(Yi,Mo)},verify:function ga(_r,jr,Hi,Yi=bo){const Mo=_r;if(jr=Qi("msgHash",jr),Hi=Qi("publicKey",Hi),"strict"in Yi)throw new Error("options.strict was renamed to lowS");const{lowS:gs,prehash:qs}=Yi;let Ps,el;try{if("string"==typeof Mo||Mo instanceof Uint8Array)try{Ps=Xn.fromDER(Mo)}catch(Js){if(!(Js instanceof fl.Err))throw Js;Ps=Xn.fromCompact(Mo)}else{if("object"!=typeof Mo||"bigint"!=typeof Mo.r||"bigint"!=typeof Mo.s)throw new Error("PARSE");{const{r:Js,s:ml}=Mo;Ps=new Xn(Js,ml)}}el=ln.fromHex(Hi)}catch(Js){if("PARSE"===Js.message)throw new Error("signature must be Signature instance, Uint8Array or hex string");return!1}if(gs&&Ps.hasHighS())return!1;qs&&(jr=P.hash(jr));const{r:Dl,s:Jl}=Ps,vc=Gr(jr),ec=zt(Jl),yc=It(vc*ec),tc=It(Dl*ec),Rc=ln.BASE.multiplyAndAddUnsafe(el,yc,tc)?.toAffine();return!!Rc&&It(Rc.x)===Dl},ProjectivePoint:ln,Signature:Xn,utils:vr}}BigInt(4);class Yl extends bl{constructor(P,$){super(),this.finished=!1,this.destroyed=!1,de.hash(P);const oe=vs($);if(this.iHash=P.create(),"function"!=typeof this.iHash.update)throw new Error("Expected instance of class which extends utils.Hash");this.blockLen=this.iHash.blockLen,this.outputLen=this.iHash.outputLen;const Ae=this.blockLen,je=new Uint8Array(Ae);je.set(oe.length>Ae?P.create().update(oe).digest():oe);for(let pt=0;ptnew Yl(I,P).update($).digest();function lh(I){return{hash:I,hmac:(P,...$)=>za(I,P,function Va(...I){const P=new Uint8Array(I.reduce((oe,Ae)=>oe+Ae.length,0));let $=0;return I.forEach(oe=>{if(!Y(oe))throw new Error("Uint8Array expected");P.set(oe,$),$+=oe.length}),P}(...$)),randomBytes:eu}}za.create=(I,P)=>new Yl(I,P);const qi=BigInt("0xfffffffffffffffffffffffffffffffffffffffffffffffffffffffefffffc2f"),Dr=BigInt("0xfffffffffffffffffffffffffffffffebaaedce6af48a03bbfd25e8cd0364141"),gc=BigInt(1),rs=BigInt(2),R=(I,P)=>(I+P/rs)/P;const F=function Ta(I,P,$=!1,oe={}){if(I<=uo)throw new Error(`Expected Fp ORDER > 0, got ${I}`);const{nBitLength:Ae,nByteLength:je}=Ls(I,P);if(je>2048)throw new Error("Field lengths over 2048 bytes are not supported");const pt=function li(I){if(I%ne===Ie){const P=(I+Ui)/ne;return function(oe,Ae){const je=oe.pow(Ae,P);if(!oe.eql(oe.sqr(je),Ae))throw new Error("Cannot find square root");return je}}if(I%Et===ye){const P=(I-ye)/Et;return function(oe,Ae){const je=oe.mul(Ae,U),pt=oe.pow(je,P),It=oe.mul(Ae,pt),zt=oe.mul(oe.mul(It,U),pt),ln=oe.mul(It,oe.sub(zt,oe.ONE));if(!oe.eql(oe.sqr(ln),Ae))throw new Error("Cannot find square root");return ln}}return function Rr(I){const P=(I-Ui)/U;let $,oe,Ae;for($=I-Ui,oe=0;$%U===uo;$/=U,oe++);for(Ae=U;Aetr(zt,I),isValid:zt=>{if("bigint"!=typeof zt)throw new Error("Invalid field element: expected bigint, got "+typeof zt);return uo<=zt&&ztzt===uo,isOdd:zt=>(zt&Ui)===Ui,neg:zt=>tr(-zt,I),eql:(zt,ln)=>zt===ln,sqr:zt=>tr(zt*zt,I),add:(zt,ln)=>tr(zt+ln,I),sub:(zt,ln)=>tr(zt-ln,I),mul:(zt,ln)=>tr(zt*ln,I),pow:(zt,ln)=>function Lo(I,P,$){if($ 0");if($===uo)return I.ONE;if($===Ui)return P;let oe=I.ONE,Ae=P;for(;$>uo;)$&Ui&&(oe=I.mul(oe,Ae)),Ae=I.sqr(Ae),$>>=Ui;return oe}(It,zt,ln),div:(zt,ln)=>tr(zt*Di(ln,I),I),sqrN:zt=>zt*zt,addN:(zt,ln)=>zt+ln,subN:(zt,ln)=>zt-ln,mulN:(zt,ln)=>zt*ln,inv:zt=>Di(zt,I),sqrt:oe.sqrt||(zt=>pt(It,zt)),invertBatch:zt=>function fa(I,P){const $=new Array(P.length),oe=P.reduce((je,pt,It)=>I.is0(pt)?je:($[It]=je,I.mul(je,pt)),I.ONE),Ae=I.inv(oe);return P.reduceRight((je,pt,It)=>I.is0(pt)?je:($[It]=I.mul(je,$[It]),I.mul(je,pt)),Ae),$}(It,zt),cmov:(zt,ln,An)=>An?ln:zt,toBytes:zt=>$?Oi(zt,je):Sr(zt,je),fromBytes:zt=>{if(zt.length!==je)throw new Error(`Fp.fromBytes: expected ${je}, got ${zt.length}`);return $?Fn(zt):oo(zt)}});return Object.freeze(It)}(qi,void 0,void 0,{sqrt:function G(I){const P=qi,$=BigInt(3),oe=BigInt(6),Ae=BigInt(11),je=BigInt(22),pt=BigInt(23),It=BigInt(44),zt=BigInt(88),ln=I*I*I%P,An=ln*ln*I%P,Qt=ki(An,$,P)*An%P,Gn=ki(Qt,$,P)*An%P,zn=ki(Gn,rs,P)*ln%P,nr=ki(zn,Ae,P)*zn%P,Mn=ki(nr,je,P)*nr%P,Hn=ki(Mn,It,P)*Mn%P,Xn=ki(Hn,zt,P)*Hn%P,vr=ki(Xn,It,P)*Mn%P,$n=ki(vr,$,P)*An%P,Ir=ki($n,pt,P)*nr%P,ir=ki(Ir,oe,P)*ln%P,Cr=ki(ir,rs,P);if(!F.eql(F.sqr(Cr),I))throw new Error("Cannot find square root");return Cr}}),K=function ch(I,P){const $=oe=>ah({...I,...lh(oe)});return Object.freeze({...$(P),create:$})}({a:BigInt(0),b:BigInt(7),Fp:F,n:Dr,Gx:BigInt("55066263022277343669578718895168534326250603453777594175500187360389116729240"),Gy:BigInt("32670510020758816978083085130507043184471273380659243275938904335757337482424"),h:BigInt(1),lowS:!0,endo:{beta:BigInt("0x7ae96a2b657c07106e64479eac3434e99cf0497512f58995c1396c28719501ee"),splitScalar:I=>{const P=Dr,$=BigInt("0x3086d221a7d46bcde86c90e49284eb15"),oe=-gc*BigInt("0xe4437ed6010e88286f547fa90abfe4c3"),Ae=BigInt("0x114ca50f7a8e2f3f657c1108d9d44cfd8"),je=$,pt=BigInt("0x100000000000000000000000000000000"),It=R(je*I,P),zt=R(-oe*I,P);let ln=tr(I-It*$-zt*Ae,P),An=tr(-It*oe-zt*je,P);const Qt=ln>pt,Gn=An>pt;if(Qt&&(ln=P-ln),Gn&&(An=P-An),ln>pt||An>pt)throw new Error("splitScalar: Endomorphism failed, k="+I);return{k1neg:Qt,k1:ln,k2neg:Gn,k2:An}}}},ru);BigInt(0);var Ql=r(1998);const Zl=K.ProjectivePoint,uu=(0,Ql.Tq)(Qa);function du(I){return BigInt(`0x${function ve(I){if(!Ii(I))throw new Error("Uint8Array expected");let P="";for(let $=0;${if(!Number.isSafeInteger(I)||I<0||I>2**32-1)throw new Error(`Invalid number=${I}. Should be from 0 to 2 ** 32 - 1`);const P=new Uint8Array(4);return Io(P).setUint32(0,I,!1),P};class Ra{get fingerprint(){if(!this.pubHash)throw new Error("No publicKey set!");return Io(this.pubHash).getUint32(0,!1)}get identifier(){return this.pubHash}get pubKeyHash(){return this.pubHash}get privateKey(){return this.privKeyBytes||null}get publicKey(){return this.pubKey||null}get privateExtendedKey(){const P=this.privateKey;if(!P)throw new Error("No private key");return uu.encode(this.serialize(this.versions.private,Nn(new Uint8Array([0]),P)))}get publicExtendedKey(){if(!this.pubKey)throw new Error("No public key");return uu.encode(this.serialize(this.versions.public,this.pubKey))}static fromMasterSeed(P,$=pi){if(ai(P),8*P.length<128||8*P.length>512)throw new Error(`HDKey: wrong seed length=${P.length}. Should be between 128 and 512 bits; 256 bits is advised)`);const oe=Or(Mr,En,P);return new Ra({versions:$,chainCode:oe.slice(32),privateKey:oe.slice(0,32)})}static fromExtendedKey(P,$=pi){const oe=uu.decode(P),Ae=Io(oe),je=Ae.getUint32(0,!1),pt={versions:$,depth:oe[4],parentFingerprint:Ae.getUint32(5,!1),index:Ae.getUint32(9,!1),chainCode:oe.slice(13,45)},It=oe.slice(45),zt=0===It[0];if(je!==$[zt?"private":"public"])throw new Error("Version mismatch");return new Ra(zt?{...pt,privateKey:It.slice(1)}:{...pt,publicKey:It})}static fromJSON(P){return Ra.fromExtendedKey(P.xpriv)}constructor(P){if(this.depth=0,this.index=0,this.chainCode=null,this.parentFingerprint=0,!P||"object"!=typeof P)throw new Error("HDKey.constructor must not be called directly");if(this.versions=P.versions||pi,this.depth=P.depth||0,this.chainCode=P.chainCode,this.index=P.index||0,this.parentFingerprint=P.parentFingerprint||0,!this.depth&&(this.parentFingerprint||this.index))throw new Error("HDKey: zero depth with non-zero index/parent fingerprint");if(P.publicKey&&P.privateKey)throw new Error("HDKey: publicKey and privateKey at same time.");if(P.privateKey){if(!K.utils.isValidPrivateKey(P.privateKey))throw new Error("Invalid private key");this.privKey="bigint"==typeof P.privateKey?P.privateKey:du(P.privateKey),this.privKeyBytes=function Ja(I){return function gt(I){if("string"!=typeof I)throw new Error("hex string expected, got "+typeof I);const P=I.length,$=P/2;if(P%2)throw new Error("padded hex string expected, got unpadded hex of length "+P);const oe=new Uint8Array($);for(let Ae=0,je=0;Ae<$;Ae++,je+=2){const pt=Ne(I.charCodeAt(je)),It=Ne(I.charCodeAt(je+1));if(void 0===pt||void 0===It)throw new Error('hex string expected, got non-hex character "'+(I[je]+I[je+1])+'" at index '+je);oe[Ae]=16*pt+It}return oe}(I.toString(16).padStart(64,"0"))}(this.privKey),this.pubKey=K.getPublicKey(P.privateKey,!0)}else{if(!P.publicKey)throw new Error("HDKey: no public or private key provided");this.pubKey=Zl.fromHex(P.publicKey).toRawBytes(!0)}this.pubHash=Go(Qa(this.pubKey))}derive(P){if(!/^[mM]'?/.test(P))throw new Error('Path must start with "m" or "M"');if(/^[mM]'?$/.test(P))return this;const $=P.replace(/^[mM]'?\//,"").split("/");let oe=this;for(const Ae of $){const je=/^(\d+)('?)$/.exec(Ae);if(!je||3!==je.length)throw new Error(`Invalid child index: ${Ae}`);let pt=+je[1];if(!Number.isSafeInteger(pt)||pt>=Ic)throw new Error("Invalid index");"'"===je[2]&&(pt+=Ic),oe=oe.deriveChild(pt)}return oe}deriveChild(P){if(!this.pubKey||!this.chainCode)throw new Error("No publicKey or chainCode set");let $=Nl(P);if(P>=Ic){const It=this.privateKey;if(!It)throw new Error("Could not derive hardened child key");$=Nn(new Uint8Array([0]),It,$)}else $=Nn(this.pubKey,$);const oe=Or(Mr,this.chainCode,$),Ae=du(oe.slice(0,32)),je=oe.slice(32);if(!K.utils.isValidPrivateKey(Ae))throw new Error("Tweak bigger than curve order");const pt={versions:this.versions,chainCode:je,depth:this.depth+1,parentFingerprint:this.fingerprint,index:P};try{if(this.privateKey){const It=tr(this.privKey+Ae,K.CURVE.n);if(!K.utils.isValidPrivateKey(It))throw new Error("The tweak was out of range or the resulted private key is invalid");pt.privateKey=It}else{const It=Zl.fromHex(this.pubKey).add(Zl.fromPrivateKey(Ae));if(It.equals(Zl.ZERO))throw new Error("The tweak was equal to negative P, which made the result key invalid");pt.publicKey=It.toRawBytes(!0)}return new Ra(pt)}catch{return this.deriveChild(P+1)}}sign(P){if(!this.privateKey)throw new Error("No privateKey set!");return ai(P,32),K.sign(P,this.privKey).toCompactRawBytes()}verify(P,$){if(ai(P,32),ai($,64),!this.publicKey)throw new Error("No publicKey set!");let oe;try{oe=K.Signature.fromCompact($)}catch{return!1}return K.verify(oe,P,this.publicKey)}wipePrivateData(){return this.privKey=void 0,this.privKeyBytes&&(this.privKeyBytes.fill(0),this.privKeyBytes=void 0),this}toJSON(){return{xpriv:this.privateExtendedKey,xpub:this.publicExtendedKey}}serialize(P,$){if(!this.chainCode)throw new Error("No chainCode set");return ai($,33),Nn(Nl(P),new Uint8Array([this.depth]),Nl(this.parentFingerprint),Nl(this.index),this.chainCode,$)}}var ma=r(3107);let ql=(()=>{class I{constructor(){this.encoder=new TextEncoder,this.decoder=new TextDecoder}getPasswordKey($){var oe=this;return(0,a.A)(function*(){return window.crypto.subtle.importKey("raw",oe.encoder.encode($),"PBKDF2",!1,["deriveKey"])})()}deriveKey($,oe,Ae){return(0,a.A)(function*(){return window.crypto.subtle.deriveKey({name:"PBKDF2",salt:oe,iterations:25e4,hash:"SHA-256"},$,{name:"AES-GCM",length:256},!1,Ae)})()}encryptData($,oe){var Ae=this;return(0,a.A)(function*(){try{const je=window.crypto.getRandomValues(new Uint8Array(16)),pt=window.crypto.getRandomValues(new Uint8Array(12)),It=yield Ae.getPasswordKey(oe),zt=yield Ae.deriveKey(It,je,["encrypt"]),ln=new Uint8Array(yield window.crypto.subtle.encrypt({name:"AES-GCM",iv:pt},zt,Ae.encoder.encode($))),An=new Uint8Array(je.length+pt.length+ln.length);return An.set(je,0),An.set(pt,je.length),An.set(ln,je.length+pt.length),Ql.K3.encode(An)}catch(je){throw console.error("Encryption failed:",je),new Error("Failed to encrypt data.")}})()}decryptData($,oe){var Ae=this;return(0,a.A)(function*(){try{const je=Ql.K3.decode($),pt=je.slice(0,16),It=je.slice(16,28),zt=je.slice(28),ln=yield Ae.getPasswordKey(oe),An=yield Ae.deriveKey(ln,pt,["decrypt"]),Qt=yield window.crypto.subtle.decrypt({name:"AES-GCM",iv:It},An,zt);return Ae.decoder.decode(Qt)}catch(je){throw console.error("Decryption failed:",je),new Error("Failed to decrypt data.")}})()}static{this.\u0275fac=function(oe){return new(oe||I)}}static{this.\u0275prov=ma.jDH({token:I,factory:I.\u0275fac,providedIn:"root"})}}return I})();var Zs=r(7544),Cl=r(4482);let yd=(()=>{class I{constructor($,oe,Ae){this.securityService=$,this.dialog=oe,this._nostrLoginService=Ae,this.localStorageSecretKeyName="secretKey",this.localStoragePublicKeyName="publicKey",this.localStorageNpubName="npub",this.localStorageNsecName="nsec",this.storageKey="userPassword"}savePassword($,oe){const Ae=Date.now()+60*oe*1e3;sessionStorage.setItem(this.storageKey,JSON.stringify({password:$,expirationTime:Ae}))}getPassword(){const $=sessionStorage.getItem(this.storageKey);if(!$)return null;const{password:oe,expirationTime:Ae}=JSON.parse($);return Date.now()>Ae?(this.clearPassword(),null):oe}clearPassword(){sessionStorage.removeItem(this.storageKey)}changePassword($,oe,Ae){var je=this;return(0,a.A)(function*(){try{const pt=yield je.getSecretKey($);if(!pt)throw new Error("Incorrect current password.");yield je.setSecretKey(pt,oe);const It=yield je.getNsec($);return It&&(yield je.setNsec(It,oe)),je.clearPassword(),Ae&&je.savePassword(oe,60),!0}catch(pt){return console.error("Failed to change password: ",pt),!1}})()}getUsername($){return $.startsWith("npub")&&($=C.Qe.decode($).data.toString()),`@${localStorage.getItem(`${$}`)||C.Qe.npubEncode($)}`}npub(){let $=this.getPublicKey();return C.Qe.npubEncode($)}requestPassword(){var $=this;return(0,a.A)(function*(){return $.dialog.open(y.b,{width:"300px",disableClose:!0}).afterClosed().toPromise()})()}nsec($){var oe=this;return(0,a.A)(function*(){if(oe.usingSecretKey()){let Ae=yield oe.getSecretKey($);const je=Uint8Array.from(w.hp.from(Ae,"hex"));return C.Qe.nsecEncode(je)}return""})()}pubkey($){return C.Qe.decode($).data.toString()}setPublicKey($){const oe=C.Qe.npubEncode($);window.localStorage.setItem(this.localStoragePublicKeyName,$),window.localStorage.setItem(this.localStorageNpubName,oe)}getPublicKey(){const $=localStorage.getItem("__nostrlogin_nip46");if($)try{return JSON.parse($).pubkey||""}catch(oe){console.error("Error parsing nostr login data:",oe)}return localStorage.getItem(this.localStoragePublicKeyName)||""}setNpub($){localStorage.setItem(this.localStorageNpubName,$)}getNpub(){return window.localStorage.getItem(this.localStorageNpubName)||""}setSecretKey($,oe=""){var Ae=this;return(0,a.A)(function*(){if(""===oe)localStorage.setItem(Ae.localStorageSecretKeyName,$),localStorage.setItem("usePassword","false");else{const je=yield Ae.securityService.encryptData($,oe);localStorage.setItem(Ae.localStorageSecretKeyName,je),localStorage.setItem("usePassword","true")}})()}getSecretKey($=""){var oe=this;return(0,a.A)(function*(){const Ae=localStorage.getItem(oe.localStorageSecretKeyName),je="true"===localStorage.getItem("usePassword");return Ae?je?yield oe.securityService.decryptData(Ae,$):Ae:null})()}getDecryptedSecretKey(){var $=this;return(0,a.A)(function*(){try{if("true"!==localStorage.getItem("usePassword"))return $.getSecretKey();const Ae=$.getPassword();if(Ae)return yield $.getSecretKey(Ae);const je=yield $.requestPassword();if(je?.password){const pt=yield $.getSecretKey(je.password);return 0!==je.duration&&$.savePassword(je.password,je.duration),pt}return console.error("Password not provided"),null}catch(oe){return console.error("Error decrypting private key:",oe),null}})()}setNsec($,oe=""){var Ae=this;return(0,a.A)(function*(){if(""===oe)localStorage.setItem(Ae.localStorageNsecName,$),localStorage.setItem("usePassword","false");else{const je=yield Ae.securityService.encryptData($,oe);localStorage.setItem(Ae.localStorageNsecName,je),localStorage.setItem("usePassword","true")}})()}getNsec($=""){var oe=this;return(0,a.A)(function*(){const Ae=localStorage.getItem(oe.localStorageNsecName),je="true"===localStorage.getItem("usePassword");return Ae?je?yield oe.securityService.decryptData(Ae,$):Ae:null})()}setPublicKeyFromExtension($){this.setPublicKey($)}handleLoginWithKey($,oe=""){let Ae,je,pt,It;try{if($.startsWith(this.localStorageNsecName)){const ln=C.Qe.decode($);if(ln.type!==this.localStorageNsecName)throw new Error("Invalid nsec key.");Ae=w.hp.from(ln.data).toString("hex")}else{if(!/^[0-9a-fA-F]{64}$/.test($))throw new Error("Invalid key format. Must be either nsec or hex.");Ae=$}const zt=new Uint8Array(w.hp.from(Ae,"hex"));return je=(0,C.lG)(zt),It=C.Qe.npubEncode(je),pt=C.Qe.nsecEncode(zt),this.setSecretKey(Ae,oe),this.setNsec(It,oe),this.setPublicKey(je),this.setNpub(It),!0}catch(zt){return console.error("Error during key handling: ",zt),!1}}handleLoginWithMnemonic($,oe="",Ae=""){try{const pt=function Oc(I,P,$=0){let Ae=Ra.fromMasterSeed(Co(I,P)).derive(`m/44'/1237'/${$}'/0/0`).privateKey;if(!Ae)throw new Error("could not derive private key");return Ae}($,oe,0),It=(0,c.My)(pt),zt=(0,C.lG)(pt),ln=C.Qe.npubEncode(zt),An=C.Qe.nsecEncode(pt);return this.setSecretKey(It,Ae),this.setNsec(An,Ae),this.setPublicKey(zt),this.setNpub(ln),window.localStorage.setItem(this.localStorageNsecName,An),!0}catch(je){return console.error("Error during login with mnemonic:",je),!1}}logout(){window.localStorage.removeItem(this.localStorageSecretKeyName),window.localStorage.removeItem(this.localStoragePublicKeyName),window.localStorage.removeItem(this.localStorageNpubName),window.localStorage.removeItem(this.localStorageNsecName),this._nostrLoginService.logout()}usingNostrBrowserExtension(){return!this.usingSecretKey()&&!!globalThis.nostr}usingSecretKey(){return!!localStorage.getItem(this.localStorageSecretKeyName)}generateAndStoreKeys($=""){try{const oe=(0,C.Bq)(),Ae=w.hp.from(oe).toString("hex"),je=(0,C.lG)(oe),pt=C.Qe.npubEncode(je),It=C.Qe.nsecEncode(oe);return this.setSecretKey(Ae,$),this.setNsec(It,$),this.setPublicKey(je),this.setNpub(pt),{secretKey:Ae,pubkey:je,npub:pt,nsec:It}}catch(oe){return console.error("Error during key generation:",oe),null}}handleLoginWithExtension(){var $=this;return(0,a.A)(function*(){const oe=globalThis;if(!oe.nostr)return!1;try{const Ae=yield oe.nostr.getPublicKey();if(!Ae)throw new Error("Public key not available from Nostr extension.");return $.setPublicKeyFromExtension(Ae),!0}catch(Ae){return console.error("Failed to connect to Nostr extension:",Ae),!1}})()}encryptMessage($,oe,Ae){return(0,a.A)(function*(){console.log(Ae);try{return yield C.sh.encrypt($,oe,Ae)}catch(je){throw console.error("Error encrypting message:",je),je}})()}encryptMessageWithExtension($,oe){return(0,a.A)(function*(){return yield globalThis.nostr.nip04.encrypt(oe,$)})()}decryptMessageWithExtension($,oe){return(0,a.A)(function*(){const Ae=globalThis;if(Ae.nostr&&"function"==typeof Ae.nostr.nip04?.decrypt)try{return yield Ae.nostr.nip04.decrypt($,oe)}catch(je){return console.error("Decryption failed:",je),"*Failed to decrypt content: "+je.message+"*"}return console.warn("Nostr extension or decrypt method is unavailable"),"Attempted Nostr Window decryption and failed."})()}decryptMessage($,oe,Ae){return(0,a.A)(function*(){try{if(!$||!oe||!Ae)throw new Error("Private key, public key, or encrypted message is missing or undefined.");const je=yield C.sh.decrypt($,oe,Ae);if(!je)throw new Error("Decryption returned an empty message.");return je}catch(je){throw je}})()}getUnsignedEvent($,oe,Ae){return{kind:$,pubkey:this.getPublicKey(),tags:oe,content:Ae,created_at:Math.floor(Date.now()/1e3)}}getSignedEvent($,oe){const Ae=(0,c.aT)(oe);return(0,C.pC)($,Ae)}getMuteList(){return(localStorage.getItem("muteList")||"").split(",")}setMuteListFromTags($){let oe=[];$.forEach(Ae=>{oe.push(Ae[1])}),this.setMuteList(oe)}setMuteList($){if(0===$.length)localStorage.setItem("muteList","");else{let oe=Array.from(new Set($));localStorage.setItem("muteList",oe.filter(Ae=>Ae).join(","))}}signEventWithExtension($){return(0,a.A)(function*(){const oe=globalThis;if(oe.nostr)return yield oe.nostr.signEvent($);throw new Error("Tried to sign event with extension but failed")})()}signDMWithExtension($,oe){return(0,a.A)(function*(){const Ae=globalThis;if(Ae.nostr&&Ae.nostr.nip04?.encrypt)return yield Ae.nostr.nip04.encrypt($,oe);throw new Error("Failed to Sign with extension")})()}isUsingExtension(){var $=this;return(0,a.A)(function*(){const oe=globalThis;if(oe.nostr&&oe.nostr.getPublicKey)try{return!localStorage.getItem($.localStorageSecretKeyName)}catch(Ae){return console.error("Failed to check Nostr extension:",Ae),!1}return!1})()}isUsingSecretKey(){return!!localStorage.getItem(this.localStorageSecretKeyName)}getNpubFromPubkey($){try{return C.Qe.npubEncode($)}catch(oe){return console.error("Error converting hex to npub:",oe),""}}getNsecFromSeckey($){try{const oe=Uint8Array.from(w.hp.from($,"hex"));return C.Qe.nsecEncode(oe)}catch(oe){return console.error("Error converting hex to nsec:",oe),""}}getHexFromNpub($){try{const oe=C.Qe.decode($);if("npub"!==oe.type)throw new Error("Invalid npub format.");return oe.data.toString()}catch(oe){return console.error("Error converting npub to hex:",oe),""}}processKey($){try{if($.startsWith("npub")){const oe=this.getHexFromNpub($);if(!oe)throw new Error("Failed to convert npub to hex.");return oe}if(/^[0-9a-fA-F]{64}$/.test($))return $;throw new Error("Invalid key format. Must be either hex or npub.")}catch(oe){return console.error("Error processing key:",oe),""}}static{this.\u0275fac=function(oe){return new(oe||I)(ma.KVO(ql),ma.KVO(Zs.bZ),ma.KVO(Cl.v))}}static{this.\u0275prov=ma.jDH({token:I,factory:I.\u0275fac,providedIn:"root"})}}return I})()},6433:(o,s,r)=>{"use strict";r.d(s,{d:()=>C});var i=r(3014),a=r(3797),c=r(3107),y=r(5506),w=r(3149);let C=(()=>{class T{constructor(M,O){this.subscriptionService=M,this.storageService=O,this.isProfileLoaded=!1}loadUserProfile(M){var O=this;return(0,i.A)(function*(){O.isProfileLoaded||(yield O.subscribeToUserProfile(M),yield O.subscribeToUserChats(M),yield O.subscribeToUserPosts(M),yield O.subscribeToMyLikes(M),O.isProfileLoaded=!0)})()}subscribeToUserProfile(M){var O=this;return(0,i.A)(function*(){const L=yield O.storageService.getLastUpdateDate("users"),Z={kinds:[0],authors:[M],limit:1};L&&(Z.since=parseInt(L,10)),O.subscriptionService.addSubscriptions([Z],q=>{const re=O.parseMetadataEvent(q);O.storageService.saveProfile(M,re)})})()}subscribeToUserChats(M){var O=this;return(0,i.A)(function*(){const L=yield O.storageService.getLastUpdateDate("chats"),Z=[{kinds:[a.rV],authors:[M],limit:300},{kinds:[a.rV],"#p":[M],limit:300}];if(L){const q=parseInt(L,10);Z.forEach(re=>re.since=q)}else O.storageService.removeAllChats();O.subscriptionService.addSubscriptions(Z,q=>{const re=O.parseChatEvent(q);O.storageService.saveChatEvent(re)})})()}subscribeToUserPosts(M){var O=this;return(0,i.A)(function*(){const L=yield O.storageService.getLastUpdateDate("posts"),Z={kinds:[a.av],authors:[M]};L&&(Z.since=parseInt(L,10)),O.subscriptionService.addSubscriptions([Z],q=>{O.isReply(q)||O.storageService.savePost(q)})})()}isReply(M){return M.tags.filter(L=>"e"===L[0]||"p"===L[0]).length>0}subscribeToMyLikes(M){var O=this;return(0,i.A)(function*(){const L=yield O.storageService.getLastUpdateDate("myLikes"),Z={kinds:[a.qT],authors:[M]};L&&(Z.since=parseInt(L,10)),O.subscriptionService.addSubscriptions([Z],q=>{O.storageService.saveLike(q)})})()}parseMetadataEvent(M){try{return JSON.parse(M.content)}catch(O){return console.error("Error parsing metadata event:",O),null}}parseChatEvent(M){try{const O=M.content.split("?iv=");return{id:M.id,kind:M.kind,pubkey:M.pubkey,created_at:M.created_at,tags:M.tags,content:O[0],iv:O[1],IsRead:!1}}catch(O){return console.error("Error parsing chat event:",O),null}}static{this.\u0275fac=function(O){return new(O||T)(c.KVO(y.n),c.KVO(w.n))}}static{this.\u0275prov=c.jDH({token:T,factory:T.\u0275fac,providedIn:"root"})}}return T})()},3149:(o,s,r)=>{"use strict";r.d(s,{n:()=>C});var i=r(3014),a=r(230),c=r.n(a),y=r(1217),w=r(3107);let C=(()=>{class T{constructor(){this.profileSubject=new y.t(null),this.projectsSubject=new y.t([]),this.projectStatsSubject=new y.t({}),this.chatEventsSubject=new y.t([]),this.unreadChatCountSubject=new y.t(0),this.contactsSubject=new y.t({pubKey:"",contacts:[]}),this.postsSubject=new y.t(null),this.myLikesSubject=new y.t([]),this.notificationsSubject=new y.t([]),this.contactStatsSubject=new y.t({totalContacts:0,followersCount:0,followingCount:0}),this.profileStore=this.createStore("profiles"),this.updateHistoryStore=this.createStore("updateHistory"),this.contactsStore=this.createStore("contacts"),this.chatsStore=this.createStore("chats"),this.postsStore=this.createStore("posts"),this.myLikesStore=this.createStore("myLikes"),this.notificationsStore=this.createStore("notifications"),this.projectsStore=this.createStore("projects"),this.projectStatsStore=this.createStore("projectStats"),this.loadAllProjectsFromDB(),this.loadAllProjectStatsFromDB(),this.loadAllChatEventsFromDB(),this.loadAllMyLikesFromDB(),this.loadAllNotificationsFromDB(),this.loadContactStatsFromDB()}createStore(M){return c().createInstance({driver:c().INDEXEDDB,name:"angor-hub",version:1,storeName:M})}get profile$(){return this.profileSubject.asObservable()}get projects$(){return this.projectsSubject.asObservable()}get projectStats$(){return this.projectStatsSubject.asObservable()}get chatEvents$(){return this.chatEventsSubject.asObservable()}get unreadChatCount$(){return this.unreadChatCountSubject.asObservable()}get contacts$(){return this.contactsSubject.asObservable()}get posts$(){return this.postsSubject.asObservable()}get contactStats$(){return this.contactStatsSubject.asObservable()}get myLikes$(){return this.myLikesSubject.asObservable()}get notifications$(){return this.notificationsSubject.asObservable()}saveProfile(M,O){var L=this;return(0,i.A)(function*(){try{if(!M||!O)return void console.error("Invalid pubKey or metadata:",M,O);O.pubKey=M,yield L.profileStore.setItem(M,O),L.profileSubject.next({pubKey:M,metadata:O}),yield L.setUpdateHistory("profiles")}catch(Z){console.error("Error saving profile",Z)}})()}getProfile(M){var O=this;return(0,i.A)(function*(){try{return(yield O.profileStore.getItem(M))||null}catch(L){return console.error("Error retrieving profile metadata:",L),null}})()}getAllProfiles(){var M=this;return(0,i.A)(function*(){try{const O=[];return yield M.profileStore.iterate(L=>{O.push(L)}),O}catch(O){return console.error("Error retrieving all Profile:",O),[]}})()}searchProfile(M){var O=this;return(0,i.A)(function*(){try{const L=[],Z=M.toLowerCase();return yield O.profileStore.iterate((q,re)=>{JSON.stringify(q).toLowerCase().includes(Z)&&L.push({pubKey:re,profile:q})}),L}catch(L){return console.error("Error searching profiles by metadata:",L),[]}})()}getLastUpdateDate(M){var O=this;return(0,i.A)(function*(){try{return(yield O.updateHistoryStore.getItem(M))||null}catch(L){return console.error("Error retrieving last update date:",L),null}})()}saveProject(M){var O=this;return(0,i.A)(function*(){try{yield O.projectsStore.setItem(M.projectIdentifier,M);const L=yield O.getAllProjects();O.projectsSubject.next(L),yield O.setUpdateHistory("projects")}catch(L){console.error("Error saving project:",L)}})()}getProjectsByNostrPubKeys(M){var O=this;return(0,i.A)(function*(){if(!M||0===M.length)return[];const L=[],Z=yield O.projectsStore.keys();for(const q of Z){const re=yield O.projectsStore.getItem(q);re&&M.includes(re.nostrPubKey)&&L.push(re)}return L})()}getAllProjects(){var M=this;return(0,i.A)(function*(){try{const O=[];return yield M.projectsStore.iterate(L=>{O.push(L)}),O}catch(O){return console.error("Error retrieving all projects:",O),[]}})()}getProjectStats(M){var O=this;return(0,i.A)(function*(){try{return(yield O.projectStatsStore.getItem(M))||null}catch(L){return console.error("Error retrieving project stats:",L),null}})()}saveProjectStats(M,O){var L=this;return(0,i.A)(function*(){try{yield L.projectStatsStore.setItem(M,O);const Z=yield L.getAllProjectStats();L.projectStatsSubject.next(Z),yield L.setUpdateHistory("projectStats")}catch(Z){console.error("Error saving project stats:",Z)}})()}getAllProjectStats(){var M=this;return(0,i.A)(function*(){try{const O={};return yield M.projectStatsStore.iterate((L,Z)=>{O[Z]=L}),O}catch(O){return console.error("Error retrieving all project stats:",O),{}}})()}savePost(M){var O=this;return(0,i.A)(function*(){try{yield O.postsStore.setItem(M.id,M),yield O.setUpdateHistory("posts"),O.postsSubject.next(M)}catch(L){console.error("Error saving event type 1 and sending it to clients:",L)}})()}getPostsByPubKey(M){var O=this;return(0,i.A)(function*(){try{const L=[];return yield O.postsStore.iterate(Z=>{Z.pubkey===M&&1===Z.kind&&L.push(Z)}),L.sort((Z,q)=>q.createdAt-Z.createdAt)}catch(L){return console.error("Error retrieving events for pubKey:",L),[]}})()}getPostById(M){var O=this;return(0,i.A)(function*(){try{let L=null;return yield O.postsStore.iterate(Z=>{if(Z.id===M&&1===Z.kind)return L=Z,L}),L}catch(L){return console.error("Error retrieving post by ID:",L),null}})()}getAllPostsWithPagination(M,O=10){var L=this;return(0,i.A)(function*(){try{const Z=[],q=(M-1)*O;return yield L.postsStore.iterate(re=>{1===re.kind&&Z.push(re)}),Z.sort((re,pe)=>pe.created_at-re.created_at).slice(q,q+O)}catch(Z){return console.error("Error retrieving all posts with pagination:",Z),[]}})()}getPostsByPubKeysWithPagination(M,O,L=10){var Z=this;return(0,i.A)(function*(){try{const q=[],re=(O-1)*L;return yield Z.postsStore.iterate(pe=>{M.includes(pe.pubkey)&&1===pe.kind&&q.push(pe)}),q.sort((pe,se)=>se.created_at-pe.created_at).slice(re,re+L)}catch(q){return console.error("Error retrieving events for pubKeys with pagination:",q),[]}})()}saveLike(M){var O=this;return(0,i.A)(function*(){try{yield O.myLikesStore.setItem(M.id,M);const L=yield O.getAllMyLikes();O.myLikesSubject.next(L),yield O.setUpdateHistory("myLikes")}catch(L){console.error("Error saving like:",L)}})()}getAllMyLikes(){var M=this;return(0,i.A)(function*(){try{const O=[];return yield M.myLikesStore.iterate(L=>{try{const Z=L.tags.find(q=>"e"===q[0]);Z&&O.push(Z[1])}catch(Z){console.warn("Error parsing like:",L,Z)}}),O}catch(O){return console.error("Error retrieving all likes:",O),[]}})()}saveNotification(M){var O=this;return(0,i.A)(function*(){try{yield O.notificationsStore.setItem(M.id,M);const L=yield O.getAllNotifications();O.notificationsSubject.next(L),yield O.setUpdateHistory("notifications")}catch(L){console.error("Error saving notification:",L)}})()}getAllNotifications(){var M=this;return(0,i.A)(function*(){try{const O=[];return yield M.notificationsStore.iterate(L=>{O.push(L)}),O}catch(O){return console.error("Error retrieving all notifications:",O),[]}})()}saveChatEvent(M){var O=this;return(0,i.A)(function*(){try{yield O.chatsStore.setItem(M.id,M),yield O.setUpdateHistory("chats");const L=yield O.getAllChatEvents();O.chatEventsSubject.next(L),O.updateUnreadChatCount(L)}catch(L){console.error("Error saving chat event:",L)}})()}getAllChatEvents(){var M=this;return(0,i.A)(function*(){try{const O=[];return yield M.chatsStore.iterate(L=>{O.push(L)}),O}catch(O){return console.error("Error retrieving all chat events:",O),[]}})()}getChatEventsByPubKey(M){var O=this;return(0,i.A)(function*(){try{const L=[];return yield O.chatsStore.iterate(Z=>{const q=O.getReceiverPubKeyFromTags(Z.tags);(Z.pubkey===M||q===M)&&L.push(Z)}),L}catch(L){return console.error("Error retrieving chat events by pubkey:",L),[]}})()}updateChatEventReadStatus(M,O){var L=this;return(0,i.A)(function*(){try{const Z=yield L.chatsStore.getItem(M);if(Z){Z.IsRead=O,yield L.chatsStore.setItem(M,Z);const q=yield L.getAllChatEvents();L.chatEventsSubject.next(q),L.updateUnreadChatCount(q)}}catch(Z){console.error("Error updating chat event read status:",Z)}})()}markAllChatEventsAsRead(M){var O=this;return(0,i.A)(function*(){try{yield O.chatsStore.iterate(function(){var Z=(0,i.A)(function*(q,re){const pe=O.getReceiverPubKeyFromTags(q.tags);(q.pubkey===M||pe===M)&&!q.IsRead&&(q.IsRead=!0,yield O.chatsStore.setItem(re,q))});return function(q,re){return Z.apply(this,arguments)}}());const L=yield O.getAllChatEvents();O.chatEventsSubject.next(L),O.updateUnreadChatCount(L)}catch(L){console.error("Error marking all chat events as read:",L)}})()}getReceiverPubKeyFromTags(M){for(const O of M)if("p"===O[0]&&O[1])return O[1];return null}updateUnreadChatCount(M){const O=M.filter(L=>!L.IsRead).length;this.unreadChatCountSubject.next(O)}removeAllChats(){var M=this;return(0,i.A)(function*(){try{yield M.chatsStore.clear(),M.chatEventsSubject.next([]),M.unreadChatCountSubject.next(0),console.log("All chat events have been removed successfully.")}catch(O){console.error("Error removing all chat events:",O)}})()}setUpdateHistory(M){var O=this;return(0,i.A)(function*(){try{const L=Math.floor(Date.now()/1e3);yield O.updateHistoryStore.setItem(M,L)}catch(L){console.error("Error updating history:",L)}})()}loadAllProjectsFromDB(){var M=this;return(0,i.A)(function*(){try{const O=yield M.getAllProjects();M.projectsSubject.next(O)}catch(O){console.error("Error loading projects from DB:",O)}})()}loadAllProjectStatsFromDB(){var M=this;return(0,i.A)(function*(){try{const O=yield M.getAllProjectStats();M.projectStatsSubject.next(O)}catch(O){console.error("Error loading project stats from DB:",O)}})()}loadAllChatEventsFromDB(){var M=this;return(0,i.A)(function*(){try{const O=yield M.getAllChatEvents();M.chatEventsSubject.next(O)}catch(O){console.error("Error loading chat events from DB:",O)}})()}loadPostsFromDB(M,O=10,L=0){var Z=this;return(0,i.A)(function*(){try{const q=[];return yield Z.postsStore.iterate(re=>{M.includes(re.pubkey)&&q.push(re)}),q.sort((re,pe)=>pe.created_at-re.created_at).slice(L,L+O)}catch(q){return console.error("Error retrieving events from DB:",q),[]}})()}loadPosts(M,O){var L=this;return(0,i.A)(function*(){const q=10*(O-1),re=yield L.loadPostsFromDB(M,10,q);re.length>0&&re.forEach(pe=>{L.postsSubject.next(pe)})})()}loadAllMyLikesFromDB(){var M=this;return(0,i.A)(function*(){try{const O=yield M.getAllMyLikes();M.myLikesSubject.next(O)}catch(O){console.error("Error loading likes from DB:",O)}})()}loadAllNotificationsFromDB(){var M=this;return(0,i.A)(function*(){try{const O=yield M.getAllNotifications();M.notificationsSubject.next(O)}catch(O){console.error("Error loading notifications from DB:",O)}})()}loadContactStatsFromDB(){var M=this;return(0,i.A)(function*(){try{let O=0,L=0,Z=0;yield M.contactsStore.iterate((q,re)=>{const[pe]=re.split(":");O++,q.isFollower?L++:Z++}),M.contactStatsSubject.next({totalContacts:O,followersCount:L,followingCount:Z})}catch(O){console.error("Error loading contact stats from DB:",O)}})()}static{this.\u0275fac=function(O){return new(O||T)}}static{this.\u0275prov=w.jDH({token:T,factory:T.\u0275fac,providedIn:"root"})}}return T})()},5506:(o,s,r)=>{"use strict";r.d(s,{n:()=>se});var a,i=r(1217),c=new Uint8Array(16);function y(){if(!a&&!(a=typeof crypto<"u"&&crypto.getRandomValues&&crypto.getRandomValues.bind(crypto)||typeof msCrypto<"u"&&"function"==typeof msCrypto.getRandomValues&&msCrypto.getRandomValues.bind(msCrypto)))throw new Error("crypto.getRandomValues() not supported. See https://github.com/uuidjs/uuid#getrandomvalues-not-supported");return a(c)}const w=/^(?:[0-9a-f]{8}-[0-9a-f]{4}-[1-5][0-9a-f]{3}-[89ab][0-9a-f]{3}-[0-9a-f]{12}|00000000-0000-0000-0000-000000000000)$/i;for(var S=[],M=0;M<256;++M)S.push((M+256).toString(16).substr(1));const L=function O(ae){var me=arguments.length>1&&void 0!==arguments[1]?arguments[1]:0,be=(S[ae[me+0]]+S[ae[me+1]]+S[ae[me+2]]+S[ae[me+3]]+"-"+S[ae[me+4]]+S[ae[me+5]]+"-"+S[ae[me+6]]+S[ae[me+7]]+"-"+S[ae[me+8]]+S[ae[me+9]]+"-"+S[ae[me+10]]+S[ae[me+11]]+S[ae[me+12]]+S[ae[me+13]]+S[ae[me+14]]+S[ae[me+15]]).toLowerCase();if(!function C(ae){return"string"==typeof ae&&w.test(ae)}(be))throw TypeError("Stringified UUID is invalid");return be},q=function Z(ae,me,be){var Oe=(ae=ae||{}).random||(ae.rng||y)();if(Oe[6]=15&Oe[6]|64,Oe[8]=63&Oe[8]|128,me){be=be||0;for(var xe=0;xe<16;++xe)me[be+xe]=Oe[xe];return me}return L(Oe)};var re=r(3107),pe=r(3125);let se=(()=>{class ae{constructor(be){this.relayService=be,this.subscriptions=new Map,this.activeRelays=[],this.pendingSubscriptions=new Map,this.subscriptionsSubject=new i.t(new Map),this.subscriptions$=this.subscriptionsSubject.asObservable(),this.subscriptionQueue=[],this.isProcessingQueue=!1,this.queueInterval=1e3,this.maxSubscriptionsPerBatch=5,this.debounceInterval=1e3,this.lastActionTimestamp=new Map,this.connectToAllRelays(),this.processSubscriptionQueue()}addSubscriptions(be,Oe,xe){const De=this.findExistingSubscription(be);if(De)return De.callbacks.push(Oe),De.id;const ce=q();this.lastActionTimestamp.set(ce,Date.now());const ue={filter:be,callbacks:[Oe],id:ce};return this.subscriptions.set(ue.id,ue),this.subscriptionsSubject.next(this.subscriptions),this.addToQueue(ue),ue.id}findExistingSubscription(be){return Array.from(this.subscriptions.values()).find(Oe=>JSON.stringify(Oe.filter)===JSON.stringify(be))}removeSubscriptionById(be){const Oe=Date.now(),xe=this.lastActionTimestamp.get(be);xe&&Oe-xe{this.subscriptionQueue.length>0&&this.subscriptionQueue.splice(0,this.maxSubscriptionsPerBatch).forEach(xe=>this.subscribeToRelays(xe.filter,xe))},this.queueInterval))}subscribeToRelays(be,Oe){0!==this.activeRelays.length?this.relayService.ensureConnectedRelays().then(()=>{const xe=this.relayService.getConnectedRelays();this.relayService.getPool().subscribeMany(xe,be,{onevent:De=>{Oe.callbacks.forEach(ce=>ce(De))},onclose:()=>console.log("Subscription closed")})}).catch(xe=>{console.error("Error subscribing to relays:",xe)}):this.pendingSubscriptions.set(Oe.id,Oe)}subscribeToAllRelays(){this.pendingSubscriptions.forEach(be=>{this.subscribeToRelays(be.filter,be)}),this.pendingSubscriptions.clear()}connectToAllRelays(){this.relayService.ensureConnectedRelays().then(()=>{this.activeRelays=this.relayService.getConnectedRelays(),this.subscribeToAllRelays()}).catch(be=>{console.error("Error connecting to relays:",be)})}clearAllSubscriptions(){this.subscriptions.clear(),this.pendingSubscriptions.clear(),this.subscriptionsSubject.next(new Map)}getSubscriptions(){return Array.from(this.subscriptions.values())}static{this.\u0275fac=function(Oe){return new(Oe||ae)(re.KVO(pe.b))}}static{this.\u0275prov=re.jDH({token:ae,factory:ae.\u0275fac,providedIn:"root"})}}return ae})()},2226:(o,s,r)=>{"use strict";r.d(s,{b:()=>q});var i=r(4460),a=r(936),c=r(9471),y=r(2902),w=r(7544),C=r(6071),T=r(3904),S=r(6389),M=r(4375),O=r(5785),L=r(3107);function Z(re,pe){1&re&&(L.j41(0,"mat-error"),L.EFF(1," Password is required "),L.k0s())}let q=(()=>{class re{constructor(se,ae,me){this.fb=se,this.dialogRef=ae,this.data=me,this.passwordForm=this.fb.group({password:["",a.k0.required],duration:["0",a.k0.required]})}onCancel(){this.dialogRef.close()}onSubmit(){this.dialogRef.close(this.passwordForm.value)}static{this.\u0275fac=function(ae){return new(ae||re)(L.rXU(a.ok),L.rXU(w.CP),L.rXU(w.Vh))}}static{this.\u0275cmp=L.VBU({type:re,selectors:[["password-dialog"]],decls:30,vars:5,consts:[["mat-dialog-title",""],["mat-dialog-content",""],[3,"formGroup"],[1,"w-full",3,"subscriptSizing"],["matPrefix",""],["matInput","","type","password",3,"formControlName"],[4,"ngIf"],[1,"mt-5","w-full"],["formControlName","duration"],["value","0"],["value","1"],["value","5"],["value","10"],["value","60"],["mat-dialog-actions",""],["mat-button","",3,"click"],["mat-raised-button","","color","primary",3,"click","disabled"]],template:function(ae,me){1&ae&&(L.j41(0,"h1",0),L.EFF(1,"Enter Password"),L.k0s(),L.j41(2,"div",1)(3,"form",2)(4,"mat-form-field",3)(5,"mat-label"),L.EFF(6,"Password"),L.k0s(),L.j41(7,"mat-icon",4),L.EFF(8,"lock"),L.k0s(),L.nrm(9,"input",5),L.DNE(10,Z,2,0,"mat-error",6),L.k0s(),L.j41(11,"mat-form-field",7)(12,"mat-label"),L.EFF(13,"Duration"),L.k0s(),L.j41(14,"mat-select",8)(15,"mat-option",9),L.EFF(16,"0 Minute"),L.k0s(),L.j41(17,"mat-option",10),L.EFF(18,"1 Minute"),L.k0s(),L.j41(19,"mat-option",11),L.EFF(20,"5 Minutes"),L.k0s(),L.j41(21,"mat-option",12),L.EFF(22,"10 Minutes"),L.k0s(),L.j41(23,"mat-option",13),L.EFF(24,"1 Hour"),L.k0s()()()()(),L.j41(25,"div",14)(26,"button",15),L.bIt("click",function(){return me.onCancel()}),L.EFF(27,"Cancel"),L.k0s(),L.j41(28,"button",16),L.bIt("click",function(){return me.onSubmit()}),L.EFF(29," Submit "),L.k0s()()),2&ae&&(L.R7$(3),L.Y8G("formGroup",me.passwordForm),L.R7$(),L.Y8G("subscriptSizing","dynamic"),L.R7$(5),L.Y8G("formControlName","password"),L.R7$(),L.Y8G("ngIf",me.passwordForm.get("password").hasError("required")),L.R7$(18),L.Y8G("disabled",me.passwordForm.invalid))},dependencies:[O.vg,c.Hl,c.$z,T.m_,T.An,a.YN,a.qT,a.me,a.BC,a.cb,y.wT,C.nJ,C.rl,a.X1,a.j4,a.JD,i.MD,i.bT,M.Ve,C.TL,C.JW,M.VO,C.RG,S.fS,S.fg],styles:[".full-width[_ngcontent-%COMP%]{width:100%}"],changeDetection:0})}}return re})()},770:(o,s,r)=>{"use strict";var i=r(6388),a=r(8716),c=r(3107);let y=(()=>{class v{constructor(){}static{this.\u0275fac=function(_){return new(_||v)}}static{this.\u0275cmp=c.VBU({type:v,selectors:[["app-root"]],decls:1,vars:0,template:function(_,D){1&_&&c.nrm(0,"router-outlet")},dependencies:[a.n3],styles:["[_nghost-%COMP%]{display:flex;flex:1 1 auto;width:100%;height:100%}"]})}}return v})();var w=r(3014);const C=new c.nKC("ANGOR_MOCK_API_DEFAULT_DELAY");var T=r(8915),S=r(1698),M=r(7610),O=r(3016);class L{constructor(m,d){this.url=m,this.delay=d,this._replyCount=0,this._replied=0}get response(){if(this._replyCount>0&&this._replyCount<=this._replied)return(0,T.$)(()=>new Error("Execution limit has been reached!"));if(!this._reply)return(0,T.$)(()=>new Error("Response callback function does not exist!"));if(!this.request)return(0,T.$)(()=>new Error("Request does not exist!"));this._replied++;const m=this._reply({request:this.request,urlParams:this.urlParams});return m instanceof S.c?m.pipe((0,M.s)(1)):(0,O.of)(m).pipe((0,M.s)(1))}reply(m){this._reply=m}replyCount(m){this._replyCount=m}}var Z=r(6143);let q=(()=>{class v{constructor(){this._handlers={get:new Map,post:new Map,patch:new Map,delete:new Map,put:new Map,head:new Map,jsonp:new Map,options:new Map}}findHandler(d,_){const D={handler:void 0,urlParams:{}},V=_.split("/"),J=this._handlers[d.toLowerCase()];for(const[we,Xe]of J){const yt=we.split("/");if(V.length===yt.length&&yt.every((_n,gr)=>_n.startsWith(":")||_n===V[gr])){D.handler=Xe,D.urlParams=(0,Z.A)(yt.map((_n,gr)=>_n.startsWith(":")?[_n.substring(1),V[gr]]:void 0).filter(Boolean));break}}return D}onGet(d,_){return this._registerHandler("get",d,_)}onPost(d,_){return this._registerHandler("post",d,_)}onPatch(d,_){return this._registerHandler("patch",d,_)}onDelete(d,_){return this._registerHandler("delete",d,_)}onPut(d,_){return this._registerHandler("put",d,_)}onHead(d,_){return this._registerHandler("head",d,_)}onJsonp(d,_){return this._registerHandler("jsonp",d,_)}onOptions(d,_){return this._registerHandler("options",d,_)}_registerHandler(d,_,D){const V=new L(_,D);return this._handlers[d].set(_,V),V}static{this.\u0275fac=function(_){return new(_||v)}}static{this.\u0275prov=c.jDH({token:v,factory:v.\u0275fac,providedIn:"root"})}}return v})();var re=r(7691),pe=r(8136),se=r(2867);const ae=(v,m)=>{const d=(0,c.WQX)(C),_=(0,c.WQX)(q),{handler:D,urlParams:V}=_.findHandler(v.method.toUpperCase(),v.url);return D?(D.request=v,D.urlParams=V,D.response.pipe((0,pe.c)(D.delay??d??0),(0,se.n)(J=>{if(!J)return(0,T.$)(()=>new re.yz({error:"NOT FOUND",status:404,statusText:"NOT FOUND"}));const we={status:J[0],body:J[1]};return we.status>=200&&we.status<300?(0,O.of)(new re.cS({body:we.body,status:we.status,statusText:"OK"})):(0,T.$)(()=>new re.yz({error:we.body?.error,status:we.status,statusText:"ERROR"}))}))):m(v)};var me=r(7891),be=r(7153),Oe=r(1217);let xe=(()=>{class v{constructor(){this._auto$=new Oe.t(!0),this._mode$=new Oe.t("indeterminate"),this._progress$=new Oe.t(0),this._show$=new Oe.t(!1),this._urlMap=new Map}get auto$(){return this._auto$.asObservable()}get mode$(){return this._mode$.asObservable()}get progress$(){return this._progress$.asObservable()}get show$(){return this._show$.asObservable()}show(){this._show$.next(!0)}hide(){this._show$.next(!1)}setAutoMode(d){this._auto$.next(d)}setMode(d){this._mode$.next(d)}setProgress(d){d<0||d>100?console.error("Progress value must be between 0 and 100!"):this._progress$.next(d)}_setLoadingStatus(d,_){_?(!0===d?(this._urlMap.set(_,d),this._show$.next(!0)):!1===d&&this._urlMap.has(_)&&this._urlMap.delete(_),0===this._urlMap.size&&this._show$.next(!1)):console.error("The request URL must be provided!")}static{this.\u0275fac=function(_){return new(_||v)}}static{this.\u0275prov=c.jDH({token:v,factory:v.\u0275fac,providedIn:"root"})}}return v})();var De=r(4447);const ce=(v,m)=>{const d=(0,c.WQX)(xe);let _=!1;return d.auto$.pipe((0,M.s)(1)).subscribe(D=>{_=D}),_?(d._setLoadingStatus(!0,v.url),m(v).pipe((0,De.j)(()=>{d._setLoadingStatus(!1,v.url)}))):m(v)};var ue=r(2012),Ce=r(2147);let Be=(()=>{class v{constructor(){this._platform=(0,c.WQX)(Ce.OD),this.osName="os-unknown",this._platform.isBrowser&&(navigator.userAgent.includes("Win")&&(this.osName="os-windows"),navigator.userAgent.includes("Mac")&&(this.osName="os-mac"),navigator.userAgent.includes("X11")&&(this.osName="os-unix"),navigator.userAgent.includes("Linux")&&(this.osName="os-linux"),this._platform.IOS&&(this.osName="os-ios"),this._platform.ANDROID&&(this.osName="os-android"))}static{this.\u0275fac=function(_){return new(_||v)}}static{this.\u0275prov=c.jDH({token:v,factory:v.\u0275fac,providedIn:"root"})}}return v})();var at=r(4460),dt=r(1483);let bt=(()=>{class v{constructor(){this._document=(0,c.WQX)(at.qQ),this._router=(0,c.WQX)(a.Ix),this._router.events.pipe((0,dt.p)(d=>d instanceof a.wF),(0,M.s)(1)).subscribe(()=>{this.hide()})}show(){this._document.body.classList.remove("angor-splash-screen-hidden")}hide(){this._document.body.classList.add("angor-splash-screen-hidden")}static{this.\u0275fac=function(_){return new(_||v)}}static{this.\u0275prov=c.jDH({token:v,factory:v.\u0275fac,providedIn:"root"})}}return v})();var lt=r(3939),rn=r(2902),gn=r(7544),bn=r(6071);class yn extends Error{}class qe extends yn{constructor(m){super(`Invalid DateTime: ${m.toMessage()}`)}}class _t extends yn{constructor(m){super(`Invalid Interval: ${m.toMessage()}`)}}class ze extends yn{constructor(m){super(`Invalid Duration: ${m.toMessage()}`)}}class $e extends yn{}class Ft extends yn{constructor(m){super(`Invalid unit ${m}`)}}class Ke extends yn{}class Ze extends yn{constructor(){super("Zone is an abstract class")}}const it="numeric",Ot="short",$t="long",Te={year:it,month:it,day:it},Ee={year:it,month:Ot,day:it},st={year:it,month:Ot,day:it,weekday:Ot},Xt={year:it,month:$t,day:it},Mt={year:it,month:$t,day:it,weekday:$t},Kt={hour:it,minute:it},rt={hour:it,minute:it,second:it},Vt={hour:it,minute:it,second:it,timeZoneName:Ot},en={hour:it,minute:it,second:it,timeZoneName:$t},kn={hour:it,minute:it,hourCycle:"h23"},Kn={hour:it,minute:it,second:it,hourCycle:"h23"},Nr={hour:it,minute:it,second:it,hourCycle:"h23",timeZoneName:Ot},Rn={hour:it,minute:it,second:it,hourCycle:"h23",timeZoneName:$t},pr={year:it,month:it,day:it,hour:it,minute:it},cn={year:it,month:it,day:it,hour:it,minute:it,second:it},Fe={year:it,month:Ot,day:it,hour:it,minute:it},ke={year:it,month:Ot,day:it,hour:it,minute:it,second:it},Je={year:it,month:Ot,day:it,weekday:Ot,hour:it,minute:it},z={year:it,month:$t,day:it,hour:it,minute:it,timeZoneName:Ot},N={year:it,month:$t,day:it,hour:it,minute:it,second:it,timeZoneName:Ot},W={year:it,month:$t,day:it,weekday:$t,hour:it,minute:it,timeZoneName:$t},Le={year:it,month:$t,day:it,weekday:$t,hour:it,minute:it,second:it,timeZoneName:$t};class ft{get type(){throw new Ze}get name(){throw new Ze}get ianaName(){return this.name}get isUniversal(){throw new Ze}offsetName(m,d){throw new Ze}formatOffset(m,d){throw new Ze}offset(m){throw new Ze}equals(m){throw new Ze}get isValid(){throw new Ze}}let mt=null;class St extends ft{static get instance(){return null===mt&&(mt=new St),mt}get type(){return"system"}get name(){return(new Intl.DateTimeFormat).resolvedOptions().timeZone}get isUniversal(){return!1}offsetName(m,{format:d,locale:_}){return lr(m,d,_)}formatOffset(m,d){return la(this.offset(m),d)}offset(m){return-new Date(m).getTimezoneOffset()}equals(m){return"system"===m.type}get isValid(){return!0}}let Tn={};const dn={year:0,month:1,day:2,era:3,hour:4,minute:5,second:6};let xn={};class Hr extends ft{static create(m){return xn[m]||(xn[m]=new Hr(m)),xn[m]}static resetCache(){xn={},Tn={}}static isValidSpecifier(m){return this.isValidZone(m)}static isValidZone(m){if(!m)return!1;try{return new Intl.DateTimeFormat("en-US",{timeZone:m}).format(),!0}catch{return!1}}constructor(m){super(),this.zoneName=m,this.valid=Hr.isValidZone(m)}get type(){return"iana"}get name(){return this.zoneName}get isUniversal(){return!1}offsetName(m,{format:d,locale:_}){return lr(m,d,_,this.name)}formatOffset(m,d){return la(this.offset(m),d)}offset(m){const d=new Date(m);if(isNaN(d))return NaN;const _=function an(v){return Tn[v]||(Tn[v]=new Intl.DateTimeFormat("en-US",{hour12:!1,timeZone:v,year:"numeric",month:"2-digit",day:"2-digit",hour:"2-digit",minute:"2-digit",second:"2-digit",era:"short"})),Tn[v]}(this.name);let[D,V,J,we,Xe,yt,un]=_.formatToParts?function sr(v,m){const d=v.formatToParts(m),_=[];for(let D=0;D=0?fr:1e3+fr,(Xo({year:D,month:V,day:J,hour:24===Xe?0:Xe,minute:yt,second:un,millisecond:0})-er)/6e4}equals(m){return"iana"===m.type&&m.name===this.name}get isValid(){return this.valid}}let Tr={},vt={};function Wt(v,m={}){const d=JSON.stringify([v,m]);let _=vt[d];return _||(_=new Intl.DateTimeFormat(v,m),vt[d]=_),_}let Re={},Ve={},ct=null,wn={};function Jt(v,m,d,_){const D=v.listingMode();return"error"===D?null:"en"===D?d(m):_(m)}class nt{constructor(m,d,_){this.padTo=_.padTo||0,this.floor=_.floor||!1;const{padTo:D,floor:V,...J}=_;if(!d||Object.keys(J).length>0){const we={useGrouping:!1,..._};_.padTo>0&&(we.minimumIntegerDigits=_.padTo),this.inf=function Ge(v,m={}){const d=JSON.stringify([v,m]);let _=Re[d];return _||(_=new Intl.NumberFormat(v,m),Re[d]=_),_}(m,we)}}format(m){if(this.inf){const d=this.floor?Math.floor(m):m;return this.inf.format(d)}return mo(this.floor?Math.floor(m):Ds(m,3),this.padTo)}}class Rt{constructor(m,d,_){let D;if(this.opts=_,this.originalZone=void 0,this.opts.timeZone)this.dt=m;else if("fixed"===m.zone.type){const J=m.offset/60*-1,we=J>=0?`Etc/GMT+${J}`:`Etc/GMT${J}`;0!==m.offset&&Hr.create(we).valid?(D=we,this.dt=m):(D="UTC",this.dt=0===m.offset?m:m.setZone("UTC").plus({minutes:m.offset}),this.originalZone=m.zone)}else"system"===m.zone.type?this.dt=m:"iana"===m.zone.type?(this.dt=m,D=m.zone.name):(D="UTC",this.dt=m.setZone("UTC").plus({minutes:m.offset}),this.originalZone=m.zone);const V={...this.opts};V.timeZone=V.timeZone||D,this.dtf=Wt(d,V)}format(){return this.originalZone?this.formatToParts().map(({value:m})=>m).join(""):this.dtf.format(this.dt.toJSDate())}formatToParts(){const m=this.dtf.formatToParts(this.dt.toJSDate());return this.originalZone?m.map(d=>{if("timeZoneName"===d.type){const _=this.originalZone.offsetName(this.dt.ts,{locale:this.dt.locale,format:this.opts.timeZoneName});return{...d,value:_}}return d}):m}resolvedOptions(){return this.dtf.resolvedOptions()}}class sn{constructor(m,d,_){this.opts={style:"long",..._},!d&&Li()&&(this.rtf=function Dt(v,m={}){const{base:d,..._}=m,D=JSON.stringify([v,_]);let V=Ve[D];return V||(V=new Intl.RelativeTimeFormat(v,m),Ve[D]=V),V}(m,_))}format(m,d){return this.rtf?this.rtf.format(m,d):function te(v,m,d="always",_=!1){const D={years:["year","yr."],quarters:["quarter","qtr."],months:["month","mo."],weeks:["week","wk."],days:["day","day","days"],hours:["hour","hr."],minutes:["minute","min."],seconds:["second","sec."]},V=-1===["hours","minutes","seconds"].indexOf(v);if("auto"===d&&V){const _n="days"===v;switch(m){case 1:return _n?"tomorrow":`next ${D[v][0]}`;case-1:return _n?"yesterday":`last ${D[v][0]}`;case 0:return _n?"today":`this ${D[v][0]}`}}const J=Object.is(m,-0)||m<0,we=Math.abs(m),Xe=1===we,yt=D[v],un=_?Xe?yt[1]:yt[2]||yt[1]:Xe?D[v][0]:v;return J?`${we} ${un} ago`:`in ${we} ${un}`}(d,m,this.opts.numeric,"long"!==this.opts.style)}formatToParts(m,d){return this.rtf?this.rtf.formatToParts(m,d):[]}}const mn={firstDay:1,minimalDays:4,weekend:[6,7]};class dr{static fromOpts(m){return dr.create(m.locale,m.numberingSystem,m.outputCalendar,m.weekSettings,m.defaultToEN)}static create(m,d,_,D,V=!1){const J=m||Ne.defaultLocale,we=J||(V?"en-US":function Bt(){return ct||(ct=(new Intl.DateTimeFormat).resolvedOptions().locale,ct)}()),Xe=d||Ne.defaultNumberingSystem,yt=_||Ne.defaultOutputCalendar,un=No(D)||Ne.defaultWeekSettings;return new dr(we,Xe,yt,un,J)}static resetCache(){ct=null,vt={},Re={},Ve={}}static fromObject({locale:m,numberingSystem:d,outputCalendar:_,weekSettings:D}={}){return dr.create(m,d,_,D)}constructor(m,d,_,D,V){const[J,we,Xe]=function Er(v){const m=v.indexOf("-x-");-1!==m&&(v=v.substring(0,m));const d=v.indexOf("-u-");if(-1===d)return[v];{let _,D;try{_=Wt(v).resolvedOptions(),D=v}catch{const Xe=v.substring(0,d);_=Wt(Xe).resolvedOptions(),D=Xe}const{numberingSystem:V,calendar:J}=_;return[D,V,J]}}(m);this.locale=J,this.numberingSystem=d||we||null,this.outputCalendar=_||Xe||null,this.weekSettings=D,this.intl=function si(v,m,d){return(d||m)&&(v.includes("-u-")||(v+="-u"),d&&(v+=`-ca-${d}`),m&&(v+=`-nu-${m}`)),v}(this.locale,this.numberingSystem,this.outputCalendar),this.weekdaysCache={format:{},standalone:{}},this.monthsCache={format:{},standalone:{}},this.meridiemCache=null,this.eraCache={},this.specifiedLocale=V,this.fastNumbersCached=null}get fastNumbers(){return null==this.fastNumbersCached&&(this.fastNumbersCached=function Tt(v){return(!v.numberingSystem||"latn"===v.numberingSystem)&&("latn"===v.numberingSystem||!v.locale||v.locale.startsWith("en")||"latn"===new Intl.DateTimeFormat(v.intl).resolvedOptions().numberingSystem)}(this)),this.fastNumbersCached}listingMode(){return this.isEnglish()&&!(null!==this.numberingSystem&&"latn"!==this.numberingSystem||null!==this.outputCalendar&&"gregory"!==this.outputCalendar)?"en":"intl"}clone(m){return m&&0!==Object.getOwnPropertyNames(m).length?dr.create(m.locale||this.specifiedLocale,m.numberingSystem||this.numberingSystem,m.outputCalendar||this.outputCalendar,No(m.weekSettings)||this.weekSettings,m.defaultToEN||!1):this}redefaultToEN(m={}){return this.clone({...m,defaultToEN:!0})}redefaultToSystem(m={}){return this.clone({...m,defaultToEN:!1})}months(m,d=!1){return Jt(this,m,Ts,()=>{const _=d?{month:m,day:"numeric"}:{month:m},D=d?"format":"standalone";return this.monthsCache[D][m]||(this.monthsCache[D][m]=function hi(v){const m=[];for(let d=1;d<=12;d++){const _=Fr.utc(2009,d,1);m.push(v(_))}return m}(V=>this.extract(V,_,"month"))),this.monthsCache[D][m]})}weekdays(m,d=!1){return Jt(this,m,lo,()=>{const _=d?{weekday:m,year:"numeric",month:"long",day:"numeric"}:{weekday:m},D=d?"format":"standalone";return this.weekdaysCache[D][m]||(this.weekdaysCache[D][m]=function Zi(v){const m=[];for(let d=1;d<=7;d++){const _=Fr.utc(2016,11,13+d);m.push(v(_))}return m}(V=>this.extract(V,_,"weekday"))),this.weekdaysCache[D][m]})}meridiems(){return Jt(this,void 0,()=>ps,()=>{if(!this.meridiemCache){const m={hour:"numeric",hourCycle:"h12"};this.meridiemCache=[Fr.utc(2016,11,13,9),Fr.utc(2016,11,13,19)].map(d=>this.extract(d,m,"dayperiod"))}return this.meridiemCache})}eras(m){return Jt(this,m,ua,()=>{const d={era:m};return this.eraCache[m]||(this.eraCache[m]=[Fr.utc(-40,1,1),Fr.utc(2017,1,1)].map(_=>this.extract(_,d,"era"))),this.eraCache[m]})}extract(m,d,_){const J=this.dtFormatter(m,d).formatToParts().find(we=>we.type.toLowerCase()===_);return J?J.value:null}numberFormatter(m={}){return new nt(this.intl,m.forceSimple||this.fastNumbers,m)}dtFormatter(m,d={}){return new Rt(m,this.intl,d)}relFormatter(m={}){return new sn(this.intl,this.isEnglish(),m)}listFormatter(m={}){return function Vr(v,m={}){const d=JSON.stringify([v,m]);let _=Tr[d];return _||(_=new Intl.ListFormat(v,m),Tr[d]=_),_}(this.intl,m)}isEnglish(){return"en"===this.locale||"en-us"===this.locale.toLowerCase()||new Intl.DateTimeFormat(this.intl).resolvedOptions().locale.startsWith("en-us")}getWeekSettings(){return this.weekSettings?this.weekSettings:bi()?function qn(v){let m=wn[v];if(!m){const d=new Intl.Locale(v);m="getWeekInfo"in d?d.getWeekInfo():d.weekInfo,wn[v]=m}return m}(this.locale):mn}getStartOfWeek(){return this.getWeekSettings().firstDay}getMinDaysInFirstWeek(){return this.getWeekSettings().minimalDays}getWeekendDays(){return this.getWeekSettings().weekend}equals(m){return this.locale===m.locale&&this.numberingSystem===m.numberingSystem&&this.outputCalendar===m.outputCalendar}toString(){return`Locale(${this.locale}, ${this.numberingSystem}, ${this.outputCalendar})`}}let Co=null;class Ni extends ft{static get utcInstance(){return null===Co&&(Co=new Ni(0)),Co}static instance(m){return 0===m?Ni.utcInstance:new Ni(m)}static parseSpecifier(m){if(m){const d=m.match(/^utc(?:([+-]\d{1,2})(?::(\d{2}))?)?$/i);if(d)return new Ni(As(d[1],d[2]))}return null}constructor(m){super(),this.fixed=m}get type(){return"fixed"}get name(){return 0===this.fixed?"UTC":`UTC${la(this.fixed,"narrow")}`}get ianaName(){return 0===this.fixed?"Etc/UTC":`Etc/GMT${la(-this.fixed,"narrow")}`}offsetName(){return this.name}formatOffset(m,d){return la(this.fixed,d)}get isUniversal(){return!0}offset(){return this.fixed}equals(m){return"fixed"===m.type&&m.fixed===this.fixed}get isValid(){return!0}}class ds extends ft{constructor(m){super(),this.zoneName=m}get type(){return"invalid"}get name(){return this.zoneName}get isUniversal(){return!1}offsetName(){return null}formatOffset(){return""}offset(){return NaN}equals(){return!1}get isValid(){return!1}}function $o(v,m){if(Pr(v)||null===v)return m;if(v instanceof ft)return v;if(function zs(v){return"string"==typeof v}(v)){const _=v.toLowerCase();return"default"===_?m:"local"===_||"system"===_?St.instance:"utc"===_||"gmt"===_?Ni.utcInstance:Ni.parseSpecifier(_)||Hr.create(v)}return Do(v)?Ni.instance(v):"object"==typeof v&&"offset"in v&&"function"==typeof v.offset?v:new ds(v)}const ai={arab:"[\u0660-\u0669]",arabext:"[\u06f0-\u06f9]",bali:"[\u1b50-\u1b59]",beng:"[\u09e6-\u09ef]",deva:"[\u0966-\u096f]",fullwide:"[\uff10-\uff19]",gujr:"[\u0ae6-\u0aef]",hanidec:"[\u3007|\u4e00|\u4e8c|\u4e09|\u56db|\u4e94|\u516d|\u4e03|\u516b|\u4e5d]",khmr:"[\u17e0-\u17e9]",knda:"[\u0ce6-\u0cef]",laoo:"[\u0ed0-\u0ed9]",limb:"[\u1946-\u194f]",mlym:"[\u0d66-\u0d6f]",mong:"[\u1810-\u1819]",mymr:"[\u1040-\u1049]",orya:"[\u0b66-\u0b6f]",tamldec:"[\u0be6-\u0bef]",telu:"[\u0c66-\u0c6f]",thai:"[\u0e50-\u0e59]",tibt:"[\u0f20-\u0f29]",latn:"\\d"},qo={arab:[1632,1641],arabext:[1776,1785],bali:[6992,7001],beng:[2534,2543],deva:[2406,2415],fullwide:[65296,65303],gujr:[2790,2799],khmr:[6112,6121],knda:[3302,3311],laoo:[3792,3801],limb:[6470,6479],mlym:[3430,3439],mong:[6160,6169],mymr:[4160,4169],orya:[2918,2927],tamldec:[3046,3055],telu:[3174,3183],thai:[3664,3673],tibt:[3872,3881]},fo=ai.hanidec.replace(/[\[|\]]/g,"").split("");let Fo={};function ao({numberingSystem:v},m=""){const d=v||"latn";return Fo[d]||(Fo[d]={}),Fo[d][m]||(Fo[d][m]=new RegExp(`${ai[d]}${m}`)),Fo[d][m]}let ve,po=()=>Date.now(),Ii="system",Io=null,tt=null,xt=null,ht=60,Ye=null;class Ne{static get now(){return po}static set now(m){po=m}static set defaultZone(m){Ii=m}static get defaultZone(){return $o(Ii,St.instance)}static get defaultLocale(){return Io}static set defaultLocale(m){Io=m}static get defaultNumberingSystem(){return tt}static set defaultNumberingSystem(m){tt=m}static get defaultOutputCalendar(){return xt}static set defaultOutputCalendar(m){xt=m}static get defaultWeekSettings(){return Ye}static set defaultWeekSettings(m){Ye=No(m)}static get twoDigitCutoffYear(){return ht}static set twoDigitCutoffYear(m){ht=m%100}static get throwOnInvalid(){return ve}static set throwOnInvalid(m){ve=m}static resetCaches(){dr.resetCache(),Hr.resetCache(),Fr.resetCache(),function oa(){Fo={}}()}}class gt{constructor(m,d){this.reason=m,this.explanation=d}toMessage(){return this.explanation?`${this.reason}: ${this.explanation}`:this.reason}}const Ht=[0,31,59,90,120,151,181,212,243,273,304,334],kt=[0,31,60,91,121,152,182,213,244,274,305,335];function hn(v,m){return new gt("unit out of range",`you specified ${m} (of type ${typeof m}) as a ${v}, which is invalid`)}function Dn(v,m,d){const _=new Date(Date.UTC(v,m-1,d));v<100&&v>=0&&_.setUTCFullYear(_.getUTCFullYear()-1900);const D=_.getUTCDay();return 0===D?7:D}function Cn(v,m,d){return d+(go(v)?kt:Ht)[m-1]}function Nn(v,m){const d=go(v)?kt:Ht,_=d.findIndex(V=>V_o(_,m,d)?(yt=_+1,Xe=1):yt=_,{weekYear:yt,weekNumber:Xe,weekday:we,...ls(v)}}function ar(v,m=4,d=1){const{weekYear:_,weekNumber:D,weekday:V}=v,J=jn(Dn(_,1,m),d),we=io(_);let yt,Xe=7*D+V-J-7+m;Xe<1?(yt=_-1,Xe+=io(yt)):Xe>we?(yt=_+1,Xe-=io(_)):yt=_;const{month:un,day:_n}=Nn(yt,Xe);return{year:yt,month:un,day:_n,...ls(v)}}function wr(v){const{year:m,month:d,day:_}=v;return{year:m,ordinal:Cn(m,d,_),...ls(v)}}function xr(v){const{year:m,ordinal:d}=v,{month:_,day:D}=Nn(m,d);return{year:m,month:_,day:D,...ls(v)}}function gi(v,m){if(Pr(v.localWeekday)&&Pr(v.localWeekNumber)&&Pr(v.localWeekYear))return{minDaysInFirstWeek:4,startOfWeek:1};if(!Pr(v.weekday)||!Pr(v.weekNumber)||!Pr(v.weekYear))throw new $e("Cannot mix locale-based week fields with ISO-based week fields");return Pr(v.localWeekday)||(v.weekday=v.localWeekday),Pr(v.localWeekNumber)||(v.weekNumber=v.localWeekNumber),Pr(v.localWeekYear)||(v.weekYear=v.localWeekYear),delete v.localWeekday,delete v.localWeekNumber,delete v.localWeekYear,{minDaysInFirstWeek:m.getMinDaysInFirstWeek(),startOfWeek:m.getStartOfWeek()}}function Or(v){const m=es(v.year),d=hs(v.month,1,12),_=hs(v.day,1,fs(v.year,v.month));return m?d?!_&&hn("day",v.day):hn("month",v.month):hn("year",v.year)}function Qr(v){const{hour:m,minute:d,second:_,millisecond:D}=v,V=hs(m,0,23)||24===m&&0===d&&0===_&&0===D,J=hs(d,0,59),we=hs(_,0,59),Xe=hs(D,0,999);return V?J?we?!Xe&&hn("millisecond",D):hn("second",_):hn("minute",d):hn("hour",m)}function Pr(v){return typeof v>"u"}function Do(v){return"number"==typeof v}function es(v){return"number"==typeof v&&v%1==0}function Li(){try{return typeof Intl<"u"&&!!Intl.RelativeTimeFormat}catch{return!1}}function bi(){try{return typeof Intl<"u"&&!!Intl.Locale&&("weekInfo"in Intl.Locale.prototype||"getWeekInfo"in Intl.Locale.prototype)}catch{return!1}}function Ks(v,m,d){if(0!==v.length)return v.reduce((_,D)=>{const V=[m(D),D];return _&&d(_[0],V[0])===_[0]?_:V},null)[1]}function Cs(v,m){return Object.prototype.hasOwnProperty.call(v,m)}function No(v){if(null==v)return null;if("object"!=typeof v)throw new Ke("Week settings must be an object");if(!hs(v.firstDay,1,7)||!hs(v.minimalDays,1,7)||!Array.isArray(v.weekend)||v.weekend.some(m=>!hs(m,1,7)))throw new Ke("Invalid week settings");return{firstDay:v.firstDay,minimalDays:v.minimalDays,weekend:Array.from(v.weekend)}}function hs(v,m,d){return es(v)&&v>=m&&v<=d}function mo(v,m=2){let _;return _=v<0?"-"+(""+-v).padStart(m,"0"):(""+v).padStart(m,"0"),_}function Go(v){if(!Pr(v)&&null!==v&&""!==v)return parseInt(v,10)}function Rs(v){if(!Pr(v)&&null!==v&&""!==v)return parseFloat(v)}function Xr(v){if(!Pr(v)&&null!==v&&""!==v){const m=1e3*parseFloat("0."+v);return Math.floor(m)}}function Ds(v,m,d=!1){const _=10**m;return(d?Math.trunc:Math.round)(v*_)/_}function go(v){return v%4==0&&(v%100!=0||v%400==0)}function io(v){return go(v)?366:365}function fs(v,m){const d=function Ko(v,m){return v-m*Math.floor(v/m)}(m-1,12)+1;return 2===d?go(v+(m-d)/12)?29:28:[31,null,31,30,31,30,31,31,30,31,30,31][d-1]}function Xo(v){let m=Date.UTC(v.year,v.month-1,v.day,v.hour,v.minute,v.second,v.millisecond);return v.year<100&&v.year>=0&&(m=new Date(m),m.setUTCFullYear(v.year,v.month-1,v.day)),+m}function Qa(v,m,d){return-jn(Dn(v,1,m),d)+m-1}function _o(v,m=4,d=1){const _=Qa(v,m,d),D=Qa(v+1,m,d);return(io(v)-_+D)/7}function Ao(v){return v>99?v:v>Ne.twoDigitCutoffYear?1900+v:2e3+v}function lr(v,m,d,_=null){const D=new Date(v),V={hourCycle:"h23",year:"numeric",month:"2-digit",day:"2-digit",hour:"2-digit",minute:"2-digit"};_&&(V.timeZone=_);const J={timeZoneName:m,...V},we=new Intl.DateTimeFormat(d,J).formatToParts(D).find(Xe=>"timezonename"===Xe.type.toLowerCase());return we?we.value:null}function As(v,m){let d=parseInt(v,10);Number.isNaN(d)&&(d=0);const _=parseInt(m,10)||0;return 60*d+(d<0||Object.is(d,-0)?-_:_)}function Gs(v){const m=Number(v);if("boolean"==typeof v||""===v||Number.isNaN(m))throw new Ke(`Invalid unit value ${v}`);return m}function _s(v,m){const d={};for(const _ in v)if(Cs(v,_)){const D=v[_];if(null==D)continue;d[m(_)]=Gs(D)}return d}function la(v,m){const d=Math.trunc(Math.abs(v/60)),_=Math.trunc(Math.abs(v%60)),D=v>=0?"+":"-";switch(m){case"short":return`${D}${mo(d,2)}:${mo(_,2)}`;case"narrow":return`${D}${d}${_>0?`:${_}`:""}`;case"techie":return`${D}${mo(d,2)}${mo(_,2)}`;default:throw new RangeError(`Value format ${m} is out of range for property format`)}}function ls(v){return function Oo(v,m){return m.reduce((d,_)=>(d[_]=v[_],d),{})}(v,["hour","minute","second","millisecond"])}const ll=["January","February","March","April","May","June","July","August","September","October","November","December"],ca=["Jan","Feb","Mar","Apr","May","Jun","Jul","Aug","Sep","Oct","Nov","Dec"],Ss=["J","F","M","A","M","J","J","A","S","O","N","D"];function Ts(v){switch(v){case"narrow":return[...Ss];case"short":return[...ca];case"long":return[...ll];case"numeric":return["1","2","3","4","5","6","7","8","9","10","11","12"];case"2-digit":return["01","02","03","04","05","06","07","08","09","10","11","12"];default:return null}}const Ns=["Monday","Tuesday","Wednesday","Thursday","Friday","Saturday","Sunday"],So=["Mon","Tue","Wed","Thu","Fri","Sat","Sun"],Bo=["M","T","W","T","F","S","S"];function lo(v){switch(v){case"narrow":return[...Bo];case"short":return[...So];case"long":return[...Ns];case"numeric":return["1","2","3","4","5","6","7"];default:return null}}const ps=["AM","PM"],Da=["Before Christ","Anno Domini"],Ms=["BC","AD"],Us=["B","A"];function ua(v){switch(v){case"narrow":return[...Us];case"short":return[...Ms];case"long":return[...Da];default:return null}}function Ct(v,m){let d="";for(const _ of v)d+=_.literal?_.val:m(_.val);return d}const Bn={D:Te,DD:Ee,DDD:Xt,DDDD:Mt,t:Kt,tt:rt,ttt:Vt,tttt:en,T:kn,TT:Kn,TTT:Nr,TTTT:Rn,f:pr,ff:Fe,fff:z,ffff:W,F:cn,FF:ke,FFF:N,FFFF:Le};class On{static create(m,d={}){return new On(m,d)}static parseFormat(m){let d=null,_="",D=!1;const V=[];for(let J=0;J0&&V.push({literal:D||/^\s+$/.test(_),val:_}),d=null,_="",D=!D):D||we===d?_+=we:(_.length>0&&V.push({literal:/^\s+$/.test(_),val:_}),_=we,d=we)}return _.length>0&&V.push({literal:D||/^\s+$/.test(_),val:_}),V}static macroTokenToFormatOpts(m){return Bn[m]}constructor(m,d){this.opts=d,this.loc=m,this.systemLoc=null}formatWithSystemDefault(m,d){return null===this.systemLoc&&(this.systemLoc=this.loc.redefaultToSystem()),this.systemLoc.dtFormatter(m,{...this.opts,...d}).format()}dtFormatter(m,d={}){return this.loc.dtFormatter(m,{...this.opts,...d})}formatDateTime(m,d){return this.dtFormatter(m,d).format()}formatDateTimeParts(m,d){return this.dtFormatter(m,d).formatToParts()}formatInterval(m,d){return this.dtFormatter(m.start,d).dtf.formatRange(m.start.toJSDate(),m.end.toJSDate())}resolvedOptions(m,d){return this.dtFormatter(m,d).resolvedOptions()}num(m,d=0){if(this.opts.forceSimple)return mo(m,d);const _={...this.opts};return d>0&&(_.padTo=d),this.loc.numberFormatter(_).format(m)}formatDateTimeFromString(m,d){const _="en"===this.loc.listingMode(),D=this.loc.outputCalendar&&"gregory"!==this.loc.outputCalendar,V=(er,fr)=>this.loc.extract(m,er,fr),J=er=>m.isOffsetFixed&&0===m.offset&&er.allowZ?"Z":m.isValid?m.zone.formatOffset(m.ts,er.format):"",Xe=(er,fr)=>_?function Q(v,m){return Ts(m)[v.month-1]}(m,er):V(fr?{month:er}:{month:er,day:"numeric"},"month"),yt=(er,fr)=>_?function Aa(v,m){return lo(m)[v.weekday-1]}(m,er):V(fr?{weekday:er}:{weekday:er,month:"long",day:"numeric"},"weekday"),un=er=>{const fr=On.macroTokenToFormatOpts(er);return fr?this.formatWithSystemDefault(m,fr):er},_n=er=>_?function et(v,m){return ua(m)[v.year<0?0:1]}(m,er):V({era:er},"era");return Ct(On.parseFormat(d),er=>{switch(er){case"S":return this.num(m.millisecond);case"u":case"SSS":return this.num(m.millisecond,3);case"s":return this.num(m.second);case"ss":return this.num(m.second,2);case"uu":return this.num(Math.floor(m.millisecond/10),2);case"uuu":return this.num(Math.floor(m.millisecond/100));case"m":return this.num(m.minute);case"mm":return this.num(m.minute,2);case"h":return this.num(m.hour%12==0?12:m.hour%12);case"hh":return this.num(m.hour%12==0?12:m.hour%12,2);case"H":return this.num(m.hour);case"HH":return this.num(m.hour,2);case"Z":return J({format:"narrow",allowZ:this.opts.allowZ});case"ZZ":return J({format:"short",allowZ:this.opts.allowZ});case"ZZZ":return J({format:"techie",allowZ:this.opts.allowZ});case"ZZZZ":return m.zone.offsetName(m.ts,{format:"short",locale:this.loc.locale});case"ZZZZZ":return m.zone.offsetName(m.ts,{format:"long",locale:this.loc.locale});case"z":return m.zoneName;case"a":return _?function Ba(v){return ps[v.hour<12?0:1]}(m):V({hour:"numeric",hourCycle:"h12"},"dayperiod");case"d":return D?V({day:"numeric"},"day"):this.num(m.day);case"dd":return D?V({day:"2-digit"},"day"):this.num(m.day,2);case"c":case"E":return this.num(m.weekday);case"ccc":return yt("short",!0);case"cccc":return yt("long",!0);case"ccccc":return yt("narrow",!0);case"EEE":return yt("short",!1);case"EEEE":return yt("long",!1);case"EEEEE":return yt("narrow",!1);case"L":return D?V({month:"numeric",day:"numeric"},"month"):this.num(m.month);case"LL":return D?V({month:"2-digit",day:"numeric"},"month"):this.num(m.month,2);case"LLL":return Xe("short",!0);case"LLLL":return Xe("long",!0);case"LLLLL":return Xe("narrow",!0);case"M":return D?V({month:"numeric"},"month"):this.num(m.month);case"MM":return D?V({month:"2-digit"},"month"):this.num(m.month,2);case"MMM":return Xe("short",!1);case"MMMM":return Xe("long",!1);case"MMMMM":return Xe("narrow",!1);case"y":return D?V({year:"numeric"},"year"):this.num(m.year);case"yy":return D?V({year:"2-digit"},"year"):this.num(m.year.toString().slice(-2),2);case"yyyy":return D?V({year:"numeric"},"year"):this.num(m.year,4);case"yyyyyy":return D?V({year:"numeric"},"year"):this.num(m.year,6);case"G":return _n("short");case"GG":return _n("long");case"GGGGG":return _n("narrow");case"kk":return this.num(m.weekYear.toString().slice(-2),2);case"kkkk":return this.num(m.weekYear,4);case"W":return this.num(m.weekNumber);case"WW":return this.num(m.weekNumber,2);case"n":return this.num(m.localWeekNumber);case"nn":return this.num(m.localWeekNumber,2);case"ii":return this.num(m.localWeekYear.toString().slice(-2),2);case"iiii":return this.num(m.localWeekYear,4);case"o":return this.num(m.ordinal);case"ooo":return this.num(m.ordinal,3);case"q":return this.num(m.quarter);case"qq":return this.num(m.quarter,2);case"X":return this.num(Math.floor(m.ts/1e3));case"x":return this.num(m.ts);default:return un(er)}})}formatDurationFromString(m,d){const _=Xe=>{switch(Xe[0]){case"S":return"millisecond";case"s":return"second";case"m":return"minute";case"h":return"hour";case"d":return"day";case"w":return"week";case"M":return"month";case"y":return"year";default:return null}},V=On.parseFormat(d),J=V.reduce((Xe,{literal:yt,val:un})=>yt?Xe:Xe.concat(un),[]);return Ct(V,(Xe=>yt=>{const un=_(yt);return un?this.num(Xe.get(un),yt.length):yt})(m.shiftTo(...J.map(_).filter(Xe=>Xe))))}}const Wn=/[A-Za-z_+-]{1,256}(?::?\/[A-Za-z0-9_+-]{1,256}(?:\/[A-Za-z0-9_+-]{1,256})?)?/;function Qn(...v){const m=v.reduce((d,_)=>d+_.source,"");return RegExp(`^${m}$`)}function qr(...v){return m=>v.reduce(([d,_,D],V)=>{const[J,we,Xe]=V(m,D);return[{...d,...J},we||_,Xe]},[{},null,1]).slice(0,2)}function zi(v,...m){if(null==v)return[null,null];for(const[d,_]of m){const D=d.exec(v);if(D)return _(D)}return[null,null]}function Mr(...v){return(m,d)=>{const _={};let D;for(D=0;Dvoid 0!==er&&(fr||er&&un)?-er:er;return[{years:gr(Rs(d)),months:gr(Rs(_)),weeks:gr(Rs(D)),days:gr(Rs(V)),hours:gr(Rs(J)),minutes:gr(Rs(we)),seconds:gr(Rs(Xe),"-0"===Xe),milliseconds:gr(Xr(yt),_n)}]}const fc={GMT:0,EDT:-240,EST:-300,CDT:-300,CST:-360,MDT:-360,MST:-420,PDT:-420,PST:-480};function cl(v,m,d,_,D,V,J){const we={year:2===m.length?Ao(Go(m)):Go(m),month:ca.indexOf(d)+1,day:Go(_),hour:Go(D),minute:Go(V)};return J&&(we.second=Go(J)),v&&(we.weekday=v.length>3?Ns.indexOf(v)+1:So.indexOf(v)+1),we}const _i=/^(?:(Mon|Tue|Wed|Thu|Fri|Sat|Sun),\s)?(\d{1,2})\s(Jan|Feb|Mar|Apr|May|Jun|Jul|Aug|Sep|Oct|Nov|Dec)\s(\d{2,4})\s(\d\d):(\d\d)(?::(\d\d))?\s(?:(UT|GMT|[ECMP][SD]T)|([Zz])|(?:([+-]\d\d)(\d\d)))$/;function cs(v){const[,m,d,_,D,V,J,we,Xe,yt,un,_n]=v,gr=cl(m,D,_,d,V,J,we);let er;return er=Xe?fc[Xe]:yt?0:As(un,_n),[gr,new Ni(er)]}const Va=/^(Mon|Tue|Wed|Thu|Fri|Sat|Sun), (\d\d) (Jan|Feb|Mar|Apr|May|Jun|Jul|Aug|Sep|Oct|Nov|Dec) (\d{4}) (\d\d):(\d\d):(\d\d) GMT$/,bl=/^(Monday|Tuesday|Wednesday|Thursday|Friday|Saturday|Sunday), (\d\d)-(Jan|Feb|Mar|Apr|May|Jun|Jul|Aug|Sep|Oct|Nov|Dec)-(\d\d) (\d\d):(\d\d):(\d\d) GMT$/,Pu=/^(Mon|Tue|Wed|Thu|Fri|Sat|Sun) (Jan|Feb|Mar|Apr|May|Jun|Jul|Aug|Sep|Oct|Nov|Dec) ( \d|\d\d) (\d\d):(\d\d):(\d\d) (\d{4})$/;function wl(v){const[,m,d,_,D,V,J,we]=v;return[cl(m,D,_,d,V,J,we),Ni.utcInstance]}function ul(v){const[,m,d,_,D,V,J,we]=v;return[cl(m,we,d,_,D,V,J),Ni.utcInstance]}const yi=Qn(/([+-]\d{6}|\d{4})(?:-?(\d\d)(?:-?(\d\d))?)?/,Ro),Il=Qn(/(\d{4})-?W(\d\d)(?:-?(\d))?/,Ro),eu=Qn(/(\d{4})-?(\d{3})/,Ro),tu=Qn(Fi),dl=qr(function jt(v,m){return[{year:Ue(v,m),month:Ue(v,m+1,1),day:Ue(v,m+2,1)},null,m+3]},br,Jr,ts),$s=qr($a,br,Jr,ts),Ol=qr(da,br,Jr,ts),Sa=qr(br,Jr,ts),ru=qr(br),El=Qn(/(\d{4})-(\d\d)-(\d\d)/,Y),jl=Qn(he),hl=qr(br,Jr,ts),Hl="Invalid Duration",ha={weeks:{days:7,hours:168,minutes:10080,seconds:604800,milliseconds:6048e5},days:{hours:24,minutes:1440,seconds:86400,milliseconds:864e5},hours:{minutes:60,seconds:3600,milliseconds:36e5},minutes:{seconds:60,milliseconds:6e4},seconds:{milliseconds:1e3}},iu={years:{quarters:4,months:12,weeks:52,days:365,hours:8760,minutes:525600,seconds:31536e3,milliseconds:31536e6},quarters:{months:3,weeks:13,days:91,hours:2184,minutes:131040,seconds:7862400,milliseconds:78624e5},months:{weeks:4,days:30,hours:720,minutes:43200,seconds:2592e3,milliseconds:2592e6},...ha},Vo=365.2425,Wo=30.436875,oo={years:{quarters:4,months:12,weeks:Vo/7,days:Vo,hours:24*Vo,minutes:525949.2,seconds:525949.2*60,milliseconds:525949.2*60*1e3},quarters:{months:3,weeks:Vo/28,days:Vo/4,hours:24*Vo/4,minutes:131487.3,seconds:525949.2*60/4,milliseconds:7889237999.999999},months:{weeks:Wo/7,days:Wo,hours:24*Wo,minutes:43829.1,seconds:2629746,milliseconds:2629746e3},...ha},Fn=["years","quarters","months","weeks","days","hours","minutes","seconds","milliseconds"],Sr=Fn.slice(0).reverse();function Oi(v,m,d=!1){const _={values:d?m.values:{...v.values,...m.values||{}},loc:v.loc.clone(m.loc),conversionAccuracy:m.conversionAccuracy||v.conversionAccuracy,matrix:m.matrix||v.matrix};return new Bi(_)}function ys(v,m){let d=m.milliseconds??0;for(const _ of Sr.slice(1))m[_]&&(d+=m[_]*v[_].milliseconds);return d}function Qi(v,m){const d=ys(v,m)<0?-1:1;Fn.reduceRight((_,D)=>{if(Pr(m[D]))return _;if(_){const J=v[D][_],we=Math.floor(m[_]*d/J);m[D]+=we*d,m[_]-=we*J*d}return D},null),Fn.reduce((_,D)=>{if(Pr(m[D]))return _;if(_){const V=m[_]%1;m[_]-=V,m[D]+=V*v[_][D]}return D},null)}class Bi{constructor(m){const d="longterm"===m.conversionAccuracy||!1;let _=d?oo:iu;m.matrix&&(_=m.matrix),this.values=m.values,this.loc=m.loc||dr.create(),this.conversionAccuracy=d?"longterm":"casual",this.invalid=m.invalid||null,this.matrix=_,this.isLuxonDuration=!0}static fromMillis(m,d){return Bi.fromObject({milliseconds:m},d)}static fromObject(m,d={}){if(null==m||"object"!=typeof m)throw new Ke("Duration.fromObject: argument expected to be an object, got "+(null===m?"null":typeof m));return new Bi({values:_s(m,Bi.normalizeUnit),loc:dr.fromObject(d),conversionAccuracy:d.conversionAccuracy,matrix:d.matrix})}static fromDurationLike(m){if(Do(m))return Bi.fromMillis(m);if(Bi.isDuration(m))return m;if("object"==typeof m)return Bi.fromObject(m);throw new Ke(`Unknown duration argument ${m} of type ${typeof m}`)}static fromISO(m,d){const[_]=function ns(v){return zi(v,[yl,ja])}(m);return _?Bi.fromObject(_,d):Bi.invalid("unparsable",`the input "${m}" can't be parsed as ISO 8601`)}static fromISOTime(m,d){const[_]=function Mc(v){return zi(v,[kl,ru])}(m);return _?Bi.fromObject(_,d):Bi.invalid("unparsable",`the input "${m}" can't be parsed as ISO 8601`)}static invalid(m,d=null){if(!m)throw new Ke("need to specify a reason the Duration is invalid");const _=m instanceof gt?m:new gt(m,d);if(Ne.throwOnInvalid)throw new ze(_);return new Bi({invalid:_})}static normalizeUnit(m){const d={year:"years",years:"years",quarter:"quarters",quarters:"quarters",month:"months",months:"months",week:"weeks",weeks:"weeks",day:"days",days:"days",hour:"hours",hours:"hours",minute:"minutes",minutes:"minutes",second:"seconds",seconds:"seconds",millisecond:"milliseconds",milliseconds:"milliseconds"}[m&&m.toLowerCase()];if(!d)throw new Ft(m);return d}static isDuration(m){return m&&m.isLuxonDuration||!1}get locale(){return this.isValid?this.loc.locale:null}get numberingSystem(){return this.isValid?this.loc.numberingSystem:null}toFormat(m,d={}){const _={...d,floor:!1!==d.round&&!1!==d.floor};return this.isValid?On.create(this.loc,_).formatDurationFromString(this,m):Hl}toHuman(m={}){if(!this.isValid)return Hl;const d=Fn.map(_=>{const D=this.values[_];return Pr(D)?null:this.loc.numberFormatter({style:"unit",unitDisplay:"long",...m,unit:_.slice(0,-1)}).format(D)}).filter(_=>_);return this.loc.listFormatter({type:"conjunction",style:m.listStyle||"narrow",...m}).format(d)}toObject(){return this.isValid?{...this.values}:{}}toISO(){if(!this.isValid)return null;let m="P";return 0!==this.years&&(m+=this.years+"Y"),(0!==this.months||0!==this.quarters)&&(m+=this.months+3*this.quarters+"M"),0!==this.weeks&&(m+=this.weeks+"W"),0!==this.days&&(m+=this.days+"D"),(0!==this.hours||0!==this.minutes||0!==this.seconds||0!==this.milliseconds)&&(m+="T"),0!==this.hours&&(m+=this.hours+"H"),0!==this.minutes&&(m+=this.minutes+"M"),(0!==this.seconds||0!==this.milliseconds)&&(m+=Ds(this.seconds+this.milliseconds/1e3,3)+"S"),"P"===m&&(m+="T0S"),m}toISOTime(m={}){if(!this.isValid)return null;const d=this.toMillis();return d<0||d>=864e5?null:(m={suppressMilliseconds:!1,suppressSeconds:!1,includePrefix:!1,format:"extended",...m,includeOffset:!1},Fr.fromMillis(d,{zone:"UTC"}).toISOTime(m))}toJSON(){return this.toISO()}toString(){return this.toISO()}[Symbol.for("nodejs.util.inspect.custom")](){return this.isValid?`Duration { values: ${JSON.stringify(this.values)} }`:`Duration { Invalid, reason: ${this.invalidReason} }`}toMillis(){return this.isValid?ys(this.matrix,this.values):NaN}valueOf(){return this.toMillis()}plus(m){if(!this.isValid)return this;const d=Bi.fromDurationLike(m),_={};for(const D of Fn)(Cs(d.values,D)||Cs(this.values,D))&&(_[D]=d.get(D)+this.get(D));return Oi(this,{values:_},!0)}minus(m){if(!this.isValid)return this;const d=Bi.fromDurationLike(m);return this.plus(d.negate())}mapUnits(m){if(!this.isValid)return this;const d={};for(const _ of Object.keys(this.values))d[_]=Gs(m(this.values[_],_));return Oi(this,{values:d},!0)}get(m){return this[Bi.normalizeUnit(m)]}set(m){return this.isValid?Oi(this,{values:{...this.values,..._s(m,Bi.normalizeUnit)}}):this}reconfigure({locale:m,numberingSystem:d,conversionAccuracy:_,matrix:D}={}){return Oi(this,{loc:this.loc.clone({locale:m,numberingSystem:d}),matrix:D,conversionAccuracy:_})}as(m){return this.isValid?this.shiftTo(m).get(m):NaN}normalize(){if(!this.isValid)return this;const m=this.toObject();return Qi(this.matrix,m),Oi(this,{values:m},!0)}rescale(){return this.isValid?Oi(this,{values:function so(v){const m={};for(const[d,_]of Object.entries(v))0!==_&&(m[d]=_);return m}(this.normalize().shiftToAll().toObject())},!0):this}shiftTo(...m){if(!this.isValid)return this;if(0===m.length)return this;m=m.map(J=>Bi.normalizeUnit(J));const d={},_={},D=this.toObject();let V;for(const J of Fn)if(m.indexOf(J)>=0){V=J;let we=0;for(const yt in _)we+=this.matrix[yt][J]*_[yt],_[yt]=0;Do(D[J])&&(we+=D[J]);const Xe=Math.trunc(we);d[J]=Xe,_[J]=(1e3*we-1e3*Xe)/1e3}else Do(D[J])&&(_[J]=D[J]);for(const J in _)0!==_[J]&&(d[V]+=J===V?_[J]:_[J]/this.matrix[V][J]);return Qi(this.matrix,d),Oi(this,{values:d},!0)}shiftToAll(){return this.isValid?this.shiftTo("years","months","weeks","days","hours","minutes","seconds","milliseconds"):this}negate(){if(!this.isValid)return this;const m={};for(const d of Object.keys(this.values))m[d]=0===this.values[d]?0:-this.values[d];return Oi(this,{values:m},!0)}get years(){return this.isValid?this.values.years||0:NaN}get quarters(){return this.isValid?this.values.quarters||0:NaN}get months(){return this.isValid?this.values.months||0:NaN}get weeks(){return this.isValid?this.values.weeks||0:NaN}get days(){return this.isValid?this.values.days||0:NaN}get hours(){return this.isValid?this.values.hours||0:NaN}get minutes(){return this.isValid?this.values.minutes||0:NaN}get seconds(){return this.isValid?this.values.seconds||0:NaN}get milliseconds(){return this.isValid?this.values.milliseconds||0:NaN}get isValid(){return null===this.invalid}get invalidReason(){return this.invalid?this.invalid.reason:null}get invalidExplanation(){return this.invalid?this.invalid.explanation:null}equals(m){if(!this.isValid||!m.isValid||!this.loc.equals(m.loc))return!1;function d(_,D){return void 0===_||0===_?void 0===D||0===D:_===D}for(const _ of Fn)if(!d(this.values[_],m.values[_]))return!1;return!0}}const Ki="Invalid Interval";class co{constructor(m){this.s=m.start,this.e=m.end,this.invalid=m.invalid||null,this.isLuxonInterval=!0}static invalid(m,d=null){if(!m)throw new Ke("need to specify a reason the Interval is invalid");const _=m instanceof gt?m:new gt(m,d);if(Ne.throwOnInvalid)throw new _t(_);return new co({invalid:_})}static fromDateTimes(m,d){const _=Gl(m),D=Gl(d),V=function no(v,m){return v&&v.isValid?m&&m.isValid?mm}isBefore(m){return!!this.isValid&&this.e<=m}contains(m){return!!this.isValid&&this.s<=m&&this.e>m}set({start:m,end:d}={}){return this.isValid?co.fromDateTimes(m||this.s,d||this.e):this}splitAt(...m){if(!this.isValid)return[];const d=m.map(Gl).filter(J=>this.contains(J)).sort((J,we)=>J.toMillis()-we.toMillis()),_=[];let{s:D}=this,V=0;for(;D+this.e?this.e:J;_.push(co.fromDateTimes(D,we)),D=we,V+=1}return _}splitBy(m){const d=Bi.fromDurationLike(m);if(!this.isValid||!d.isValid||0===d.as("milliseconds"))return[];let V,{s:_}=this,D=1;const J=[];for(;_Xe*D));V=+we>+this.e?this.e:we,J.push(co.fromDateTimes(_,V)),_=V,D+=1}return J}divideEqually(m){return this.isValid?this.splitBy(this.length()/m).slice(0,m):[]}overlaps(m){return this.e>m.s&&this.s=m.e}equals(m){return!(!this.isValid||!m.isValid)&&this.s.equals(m.s)&&this.e.equals(m.e)}intersection(m){if(!this.isValid)return this;const d=this.s>m.s?this.s:m.s,_=this.e=_?null:co.fromDateTimes(d,_)}union(m){return this.isValid?co.fromDateTimes(this.sm.e?this.e:m.e):this}static merge(m){const[d,_]=m.sort((D,V)=>D.s-V.s).reduce(([D,V],J)=>V?V.overlaps(J)||V.abutsStart(J)?[D,V.union(J)]:[D.concat([V]),J]:[D,J],[[],null]);return _&&d.push(_),d}static xor(m){let d=null,_=0;const D=[],V=m.map(Xe=>[{time:Xe.s,type:"s"},{time:Xe.e,type:"e"}]),we=Array.prototype.concat(...V).sort((Xe,yt)=>Xe.time-yt.time);for(const Xe of we)_+="s"===Xe.type?1:-1,1===_?d=Xe.time:(d&&+d!=+Xe.time&&D.push(co.fromDateTimes(d,Xe.time)),d=null);return co.merge(D)}difference(...m){return co.xor([this].concat(m)).map(d=>this.intersection(d)).filter(d=>d&&!d.isEmpty())}toString(){return this.isValid?`[${this.s.toISO()} \u2013 ${this.e.toISO()})`:Ki}[Symbol.for("nodejs.util.inspect.custom")](){return this.isValid?`Interval { start: ${this.s.toISO()}, end: ${this.e.toISO()} }`:`Interval { Invalid, reason: ${this.invalidReason} }`}toLocaleString(m=Te,d={}){return this.isValid?On.create(this.s.loc.clone(d),m).formatInterval(this):Ki}toISO(m){return this.isValid?`${this.s.toISO(m)}/${this.e.toISO(m)}`:Ki}toISODate(){return this.isValid?`${this.s.toISODate()}/${this.e.toISODate()}`:Ki}toISOTime(m){return this.isValid?`${this.s.toISOTime(m)}/${this.e.toISOTime(m)}`:Ki}toFormat(m,{separator:d=" \u2013 "}={}){return this.isValid?`${this.s.toFormat(m)}${d}${this.e.toFormat(m)}`:Ki}toDuration(m,d){return this.isValid?this.e.diff(this.s,m,d):Bi.invalid(this.invalidReason)}mapEndpoints(m){return co.fromDateTimes(m(this.s),m(this.e))}}class ri{static hasDST(m=Ne.defaultZone){const d=Fr.now().setZone(m).set({month:12});return!m.isUniversal&&d.offset!==d.set({month:6}).offset}static isValidIANAZone(m){return Hr.isValidZone(m)}static normalizeZone(m){return $o(m,Ne.defaultZone)}static getStartOfWeek({locale:m=null,locObj:d=null}={}){return(d||dr.create(m)).getStartOfWeek()}static getMinimumDaysInFirstWeek({locale:m=null,locObj:d=null}={}){return(d||dr.create(m)).getMinDaysInFirstWeek()}static getWeekendWeekdays({locale:m=null,locObj:d=null}={}){return(d||dr.create(m)).getWeekendDays().slice()}static months(m="long",{locale:d=null,numberingSystem:_=null,locObj:D=null,outputCalendar:V="gregory"}={}){return(D||dr.create(d,_,V)).months(m)}static monthsFormat(m="long",{locale:d=null,numberingSystem:_=null,locObj:D=null,outputCalendar:V="gregory"}={}){return(D||dr.create(d,_,V)).months(m,!0)}static weekdays(m="long",{locale:d=null,numberingSystem:_=null,locObj:D=null}={}){return(D||dr.create(d,_,null)).weekdays(m)}static weekdaysFormat(m="long",{locale:d=null,numberingSystem:_=null,locObj:D=null}={}){return(D||dr.create(d,_,null)).weekdays(m,!0)}static meridiems({locale:m=null}={}){return dr.create(m).meridiems()}static eras(m="short",{locale:d=null}={}){return dr.create(d,null,"gregory").eras(m)}static features(){return{relative:Li(),localeWeek:bi()}}}function Xs(v,m){const d=D=>D.toUTC(0,{keepLocalTime:!0}).startOf("day").valueOf(),_=d(m)-d(v);return Math.floor(Bi.fromMillis(_).as("days"))}function Ci(v,m=d=>d){return{regex:v,deser:([d])=>m(function Jo(v){let m=parseInt(v,10);if(isNaN(m)){m="";for(let d=0;d=V&&_<=J&&(m+=_-V)}}return parseInt(m,10)}return m}(d))}}const uo="[ \xa0]",Ui=new RegExp(uo,"g");function U(v){return v.replace(/\./g,"\\.?").replace(Ui,uo)}function Ie(v){return v.replace(/\./g,"").replace(Ui," ").toLowerCase()}function ne(v,m){return null===v?null:{regex:RegExp(v.map(U).join("|")),deser:([d])=>v.findIndex(_=>Ie(d)===Ie(_))+m}}function ye(v,m){return{regex:v,deser:([,d,_])=>As(d,_),groups:m}}function Et(v){return{regex:v,deser:([m])=>m}}function Gt(v){return v.replace(/[\-\[\]{}()*+?.,\\\^$|#\s]/g,"\\$&")}const tr={year:{"2-digit":"yy",numeric:"yyyyy"},month:{numeric:"M","2-digit":"MM",short:"MMM",long:"MMMM"},day:{numeric:"d","2-digit":"dd"},weekday:{short:"EEE",long:"EEEE"},dayperiod:"a",dayPeriod:"a",hour12:{numeric:"h","2-digit":"hh"},hour24:{numeric:"H","2-digit":"HH"},minute:{numeric:"m","2-digit":"mm"},second:{numeric:"s","2-digit":"ss"},timeZoneName:{long:"ZZZZZ",short:"ZZZ"}};let li=null;function bs(v,m){return Array.prototype.concat(...v.map(d=>function wi(v,m){if(v.literal)return v;const _=Ha(On.macroTokenToFormatOpts(v.val),m);return null==_||_.includes(void 0)?v:_}(d,m)))}class Lo{constructor(m,d){if(this.locale=m,this.format=d,this.tokens=bs(On.parseFormat(d),m),this.units=this.tokens.map(_=>function Un(v,m){const d=ao(m),_=ao(m,"{2}"),D=ao(m,"{3}"),V=ao(m,"{4}"),J=ao(m,"{6}"),we=ao(m,"{1,2}"),Xe=ao(m,"{1,3}"),yt=ao(m,"{1,6}"),un=ao(m,"{1,9}"),_n=ao(m,"{2,4}"),gr=ao(m,"{4,6}"),er=Ai=>({regex:RegExp(Gt(Ai.val)),deser:([ko])=>ko,literal:!0}),ti=(Ai=>{if(v.literal)return er(Ai);switch(Ai.val){case"G":return ne(m.eras("short"),0);case"GG":return ne(m.eras("long"),0);case"y":return Ci(yt);case"yy":case"kk":return Ci(_n,Ao);case"yyyy":case"kkkk":return Ci(V);case"yyyyy":return Ci(gr);case"yyyyyy":return Ci(J);case"M":case"L":case"d":case"H":case"h":case"m":case"q":case"s":case"W":return Ci(we);case"MM":case"LL":case"dd":case"HH":case"hh":case"mm":case"qq":case"ss":case"WW":return Ci(_);case"MMM":return ne(m.months("short",!0),1);case"MMMM":return ne(m.months("long",!0),1);case"LLL":return ne(m.months("short",!1),1);case"LLLL":return ne(m.months("long",!1),1);case"o":case"S":return Ci(Xe);case"ooo":case"SSS":return Ci(D);case"u":return Et(un);case"uu":return Et(we);case"uuu":case"E":case"c":return Ci(d);case"a":return ne(m.meridiems(),0);case"EEE":return ne(m.weekdays("short",!1),1);case"EEEE":return ne(m.weekdays("long",!1),1);case"ccc":return ne(m.weekdays("short",!0),1);case"cccc":return ne(m.weekdays("long",!0),1);case"Z":case"ZZ":return ye(new RegExp(`([+-]${we.source})(?::(${_.source}))?`),2);case"ZZZ":return ye(new RegExp(`([+-]${we.source})(${_.source})?`),2);case"z":return Et(/[a-z_+-/]{1,256}?/i);case" ":return Et(/[^\S\n\r]/);default:return er(Ai)}})(v)||{invalidReason:"missing Intl.DateTimeFormat.formatToParts support"};return ti.token=v,ti}(_,m)),this.disqualifyingUnit=this.units.find(_=>_.invalidReason),!this.disqualifyingUnit){const[_,D]=function ki(v){return[`^${v.map(d=>d.regex).reduce((d,_)=>`${d}(${_.source})`,"")}$`,v]}(this.units);this.regex=RegExp(_,"i"),this.handlers=D}}explainFromTokens(m){if(this.isValid){const[d,_]=function Di(v,m,d){const _=v.match(m);if(_){const D={};let V=1;for(const J in d)if(Cs(d,J)){const we=d[J],Xe=we.groups?we.groups+1:1;!we.literal&&we.token&&(D[we.token.val[0]]=we.deser(_.slice(V,V+Xe))),V+=Xe}return[_,D]}return[_,{}]}(m,this.regex,this.handlers),[D,V,J]=_?function Rr(v){let _,d=null;return Pr(v.z)||(d=Hr.create(v.z)),Pr(v.Z)||(d||(d=new Ni(v.Z)),_=v.Z),Pr(v.q)||(v.M=3*(v.q-1)+1),Pr(v.h)||(v.h<12&&1===v.a?v.h+=12:12===v.h&&0===v.a&&(v.h=0)),0===v.G&&v.y&&(v.y=-v.y),Pr(v.u)||(v.S=Xr(v.u)),[Object.keys(v).reduce((V,J)=>{const we=(V=>{switch(V){case"S":return"millisecond";case"s":return"second";case"m":return"minute";case"h":case"H":return"hour";case"d":return"day";case"o":return"ordinal";case"L":case"M":return"month";case"y":return"year";case"E":case"c":return"weekday";case"W":return"weekNumber";case"k":return"weekYear";case"q":return"quarter";default:return null}})(J);return we&&(V[we]=v[J]),V},{}),d,_]}(_):[null,null,void 0];if(Cs(_,"a")&&Cs(_,"H"))throw new $e("Can't include meridiem when specifying 24-hour format");return{input:m,tokens:this.tokens,regex:this.regex,rawMatches:d,matches:_,result:D,zone:V,specificOffset:J}}return{input:m,tokens:this.tokens,invalidReason:this.invalidReason}}get isValid(){return!this.disqualifyingUnit}get invalidReason(){return this.disqualifyingUnit?this.disqualifyingUnit.invalidReason:null}}function fa(v,m,d){return new Lo(v,d).explainFromTokens(m)}function Ha(v,m){if(!v)return null;const _=On.create(m,v).dtFormatter(function ii(){return li||(li=Fr.fromMillis(1555555555555)),li}()),D=_.formatToParts(),V=_.resolvedOptions();return D.map(J=>function ci(v,m,d){const{type:_,value:D}=v;if("literal"===_){const Xe=/^\s+$/.test(D);return{literal:!Xe,val:Xe?" ":D}}let J=_;"hour"===_&&(J=null!=m.hour12?m.hour12?"hour12":"hour24":null!=m.hourCycle?"h11"===m.hourCycle||"h12"===m.hourCycle?"hour12":"hour24":d.hour12?"hour12":"hour24");let we=tr[J];if("object"==typeof we&&(we=we[m[_]]),we)return{literal:!1,val:we}}(J,v,V))}const Ls="Invalid DateTime",Ta=864e13;function Ma(v){return new gt("unsupported zone",`the zone "${v.name}" is not supported`)}function qa(v){return null===v.weekData&&(v.weekData=Jn(v.c)),v.weekData}function ou(v){return null===v.localWeekData&&(v.localWeekData=Jn(v.c,v.loc.getMinDaysInFirstWeek(),v.loc.getStartOfWeek())),v.localWeekData}function ka(v,m){const d={ts:v.ts,zone:v.zone,c:v.c,o:v.o,loc:v.loc,invalid:v.invalid};return new Fr({...d,...m,old:d})}function Ia(v,m,d){let _=v-60*m*1e3;const D=d.offset(_);if(m===D)return[_,m];_-=60*(D-m)*1e3;const V=d.offset(_);return D===V?[_,D]:[v-60*Math.min(D,V)*1e3,Math.max(D,V)]}function Rl(v,m){const d=new Date(v+=60*m*1e3);return{year:d.getUTCFullYear(),month:d.getUTCMonth()+1,day:d.getUTCDate(),hour:d.getUTCHours(),minute:d.getUTCMinutes(),second:d.getUTCSeconds(),millisecond:d.getUTCMilliseconds()}}function su(v,m,d){return Ia(Xo(v),m,d)}function Fu(v,m){const d=v.o,_=v.c.year+Math.trunc(m.years),D=v.c.month+Math.trunc(m.months)+3*Math.trunc(m.quarters),V={...v.c,year:_,month:D,day:Math.min(v.c.day,fs(_,D))+Math.trunc(m.days)+7*Math.trunc(m.weeks)},J=Bi.fromObject({years:m.years-Math.trunc(m.years),quarters:m.quarters-Math.trunc(m.quarters),months:m.months-Math.trunc(m.months),weeks:m.weeks-Math.trunc(m.weeks),days:m.days-Math.trunc(m.days),hours:m.hours,minutes:m.minutes,seconds:m.seconds,milliseconds:m.milliseconds}).as("milliseconds"),we=Xo(V);let[Xe,yt]=Ia(we,d,v.zone);return 0!==J&&(Xe+=J,yt=v.zone.offset(Xe)),{ts:Xe,o:yt}}function Wl(v,m,d,_,D,V){const{setZone:J,zone:we}=d;if(v&&0!==Object.keys(v).length||m){const Xe=m||we,yt=Fr.fromObject(v,{...d,zone:Xe,specificOffset:V});return J?yt:yt.setZone(we)}return Fr.invalid(new gt("unparsable",`the input "${D}" can't be parsed as ${_}`))}function pc(v,m,d=!0){return v.isValid?On.create(dr.create("en-US"),{allowZ:d,forceSimple:!0}).formatDateTimeFromString(v,m):null}function fl(v,m){const d=v.c.year>9999||v.c.year<0;let _="";return d&&v.c.year>=0&&(_+="+"),_+=mo(v.c.year,d?6:4),m?(_+="-",_+=mo(v.c.month),_+="-",_+=mo(v.c.day)):(_+=mo(v.c.month),_+=mo(v.c.day)),_}function yo(v,m,d,_,D,V){let J=mo(v.c.hour);return m?(J+=":",J+=mo(v.c.minute),(0!==v.c.millisecond||0!==v.c.second||!d)&&(J+=":")):J+=mo(v.c.minute),(0!==v.c.millisecond||0!==v.c.second||!d)&&(J+=mo(v.c.second),(0!==v.c.millisecond||!_)&&(J+=".",J+=mo(v.c.millisecond,3))),D&&(v.isOffsetFixed&&0===v.offset&&!V?J+="Z":v.o<0?(J+="-",J+=mo(Math.trunc(-v.o/60)),J+=":",J+=mo(Math.trunc(-v.o%60))):(J+="+",J+=mo(Math.trunc(v.o/60)),J+=":",J+=mo(Math.trunc(v.o%60)))),V&&(J+="["+v.zone.ianaName+"]"),J}const zo={month:1,day:1,hour:0,minute:0,second:0,millisecond:0},xl={weekNumber:1,weekday:1,hour:0,minute:0,second:0,millisecond:0},au={ordinal:1,hour:0,minute:0,second:0,millisecond:0},mc=["year","month","day","hour","minute","second","millisecond"],lu=["weekYear","weekNumber","weekday","hour","minute","second","millisecond"],Bu=["year","ordinal","hour","minute","second","millisecond"];function Uu(v){switch(v.toLowerCase()){case"localweekday":case"localweekdays":return"localWeekday";case"localweeknumber":case"localweeknumbers":return"localWeekNumber";case"localweekyear":case"localweekyears":return"localWeekYear";default:return function ah(v){const m={year:"year",years:"year",month:"month",months:"month",day:"day",days:"day",hour:"hour",hours:"hour",minute:"minute",minutes:"minute",quarter:"quarter",quarters:"quarter",second:"second",seconds:"second",millisecond:"millisecond",milliseconds:"millisecond",weekday:"weekday",weekdays:"weekday",weeknumber:"weekNumber",weeksnumber:"weekNumber",weeknumbers:"weekNumber",weekyear:"weekYear",weekyears:"weekYear",ordinal:"ordinal"}[v.toLowerCase()];if(!m)throw new Ft(v);return m}(v)}}function Ur(v,m){const d=$o(m.zone,Ne.defaultZone);if(!d.isValid)return Fr.invalid(Ma(d));const _=dr.fromObject(m);let D,V;if(Pr(v.year))D=Ne.now();else{for(const Xe of mc)Pr(v[Xe])&&(v[Xe]=zo[Xe]);const J=Or(v)||Qr(v);if(J)return Fr.invalid(J);const we=function Ef(v){return Wa[v]||(void 0===zl&&(zl=Ne.now()),Wa[v]=v.offset(zl)),Wa[v]}(d);[D,V]=su(v,we,d)}return new Fr({ts:D,zone:d,loc:_,o:V})}function kc(v,m,d){const _=!!Pr(d.round)||d.round,D=(J,we)=>(J=Ds(J,_||d.calendary?0:2,!0),m.loc.clone(d).relFormatter(d).format(J,we)),V=J=>d.calendary?m.hasSame(v,J)?0:m.startOf(J).diff(v.startOf(J),J).get(J):m.diff(v,J).get(J);if(d.unit)return D(V(d.unit),d.unit);for(const J of d.units){const we=V(J);if(Math.abs(we)>=1)return D(we,J)}return D(v>m?-0:0,d.units[d.units.length-1])}function Hs(v){let d,m={};return v.length>0&&"object"==typeof v[v.length-1]?(m=v[v.length-1],d=Array.from(v).slice(0,v.length-1)):d=Array.from(v),[m,d]}let zl,Wa={};class Fr{constructor(m){const d=m.zone||Ne.defaultZone;let _=m.invalid||(Number.isNaN(m.ts)?new gt("invalid input"):null)||(d.isValid?null:Ma(d));this.ts=Pr(m.ts)?Ne.now():m.ts;let D=null,V=null;if(!_)if(m.old&&m.old.ts===this.ts&&m.old.zone.equals(d))[D,V]=[m.old.c,m.old.o];else{const we=Do(m.o)&&!m.old?m.o:d.offset(this.ts);D=Rl(this.ts,we),_=Number.isNaN(D.year)?new gt("invalid input"):null,D=_?null:D,V=_?null:we}this._zone=d,this.loc=m.loc||dr.create(),this.invalid=_,this.weekData=null,this.localWeekData=null,this.c=D,this.o=V,this.isLuxonDateTime=!0}static now(){return new Fr({})}static local(){const[m,d]=Hs(arguments),[_,D,V,J,we,Xe,yt]=d;return Ur({year:_,month:D,day:V,hour:J,minute:we,second:Xe,millisecond:yt},m)}static utc(){const[m,d]=Hs(arguments),[_,D,V,J,we,Xe,yt]=d;return m.zone=Ni.utcInstance,Ur({year:_,month:D,day:V,hour:J,minute:we,second:Xe,millisecond:yt},m)}static fromJSDate(m,d={}){const _=function sa(v){return"[object Date]"===Object.prototype.toString.call(v)}(m)?m.valueOf():NaN;if(Number.isNaN(_))return Fr.invalid("invalid input");const D=$o(d.zone,Ne.defaultZone);return D.isValid?new Fr({ts:_,zone:D,loc:dr.fromObject(d)}):Fr.invalid(Ma(D))}static fromMillis(m,d={}){if(Do(m))return m<-Ta||m>Ta?Fr.invalid("Timestamp out of range"):new Fr({ts:m,zone:$o(d.zone,Ne.defaultZone),loc:dr.fromObject(d)});throw new Ke(`fromMillis requires a numerical input, but received a ${typeof m} with value ${m}`)}static fromSeconds(m,d={}){if(Do(m))return new Fr({ts:1e3*m,zone:$o(d.zone,Ne.defaultZone),loc:dr.fromObject(d)});throw new Ke("fromSeconds requires a numerical input")}static fromObject(m,d={}){m=m||{};const _=$o(d.zone,Ne.defaultZone);if(!_.isValid)return Fr.invalid(Ma(_));const D=dr.fromObject(d),V=_s(m,Uu),{minDaysInFirstWeek:J,startOfWeek:we}=gi(V,D),Xe=Ne.now(),yt=Pr(d.specificOffset)?_.offset(Xe):d.specificOffset,un=!Pr(V.ordinal),_n=!Pr(V.year),gr=!Pr(V.month)||!Pr(V.day),er=_n||gr,fr=V.weekYear||V.weekNumber;if((er||un)&&fr)throw new $e("Can't mix weekYear/weekNumber units with year/month/day or ordinals");if(gr&&un)throw new $e("Can't mix ordinal dates with month/day");const ti=fr||V.weekday&&!er;let Ai,ko,ho=Rl(Xe,yt);ti?(Ai=lu,ko=xl,ho=Jn(ho,J,we)):un?(Ai=Bu,ko=au,ho=wr(ho)):(Ai=mc,ko=zo);let Ea=!1;for(const Bl of Ai)Pr(V[Bl])?V[Bl]=Ea?ko[Bl]:ho[Bl]:Ea=!0;const ta=ti?function ni(v,m=4,d=1){const _=es(v.weekYear),D=hs(v.weekNumber,1,_o(v.weekYear,m,d)),V=hs(v.weekday,1,7);return _?D?!V&&hn("weekday",v.weekday):hn("week",v.weekNumber):hn("weekYear",v.weekYear)}(V,J,we):un?function Mi(v){const m=es(v.year),d=hs(v.ordinal,1,io(v.year));return m?!d&&hn("ordinal",v.ordinal):hn("year",v.year)}(V):Or(V),Ou=ta||Qr(V);if(Ou)return Fr.invalid(Ou);const vl=ti?ar(V,J,we):un?xr(V):V,[xa,Ya]=su(vl,yt,_),Sl=new Fr({ts:xa,zone:_,o:Ya,loc:D});return V.weekday&&er&&m.weekday!==Sl.weekday?Fr.invalid("mismatched weekday",`you can't specify both a weekday of ${V.weekday} and a date of ${Sl.toISO()}`):Sl.isValid?Sl:Fr.invalid(Sl.invalid)}static fromISO(m,d={}){const[_,D]=function ks(v){return zi(v,[yi,dl],[Il,$s],[eu,Ol],[tu,Sa])}(m);return Wl(_,D,d,"ISO 8601",m)}static fromRFC2822(m,d={}){const[_,D]=function js(v){return zi(function vs(v){return v.replace(/\([^()]*\)|[\n\t]/g," ").replace(/(\s\s+)/g," ").trim()}(v),[_i,cs])}(m);return Wl(_,D,d,"RFC 2822",m)}static fromHTTP(m,d={}){const[_,D]=function nu(v){return zi(v,[Va,wl],[bl,wl],[Pu,ul])}(m);return Wl(_,D,d,"HTTP",d)}static fromFormat(m,d,_={}){if(Pr(m)||Pr(d))throw new Ke("fromFormat requires an input string and a format");const{locale:D=null,numberingSystem:V=null}=_,J=dr.fromOpts({locale:D,numberingSystem:V,defaultToEN:!0}),[we,Xe,yt,un]=function Yo(v,m,d){const{result:_,zone:D,specificOffset:V,invalidReason:J}=fa(v,m,d);return[_,D,V,J]}(J,m,d);return un?Fr.invalid(un):Wl(we,Xe,_,`format ${d}`,m,yt)}static fromString(m,d,_={}){return Fr.fromFormat(m,d,_)}static fromSQL(m,d={}){const[_,D]=function Vl(v){return zi(v,[El,dl],[jl,hl])}(m);return Wl(_,D,d,"SQL",m)}static invalid(m,d=null){if(!m)throw new Ke("need to specify a reason the DateTime is invalid");const _=m instanceof gt?m:new gt(m,d);if(Ne.throwOnInvalid)throw new qe(_);return new Fr({invalid:_})}static isDateTime(m){return m&&m.isLuxonDateTime||!1}static parseFormatForOpts(m,d={}){const _=Ha(m,dr.fromObject(d));return _?_.map(D=>D?D.val:null).join(""):null}static expandFormat(m,d={}){return bs(On.parseFormat(m),dr.fromObject(d)).map(D=>D.val).join("")}static resetCache(){zl=void 0,Wa={}}get(m){return this[m]}get isValid(){return null===this.invalid}get invalidReason(){return this.invalid?this.invalid.reason:null}get invalidExplanation(){return this.invalid?this.invalid.explanation:null}get locale(){return this.isValid?this.loc.locale:null}get numberingSystem(){return this.isValid?this.loc.numberingSystem:null}get outputCalendar(){return this.isValid?this.loc.outputCalendar:null}get zone(){return this._zone}get zoneName(){return this.isValid?this.zone.name:null}get year(){return this.isValid?this.c.year:NaN}get quarter(){return this.isValid?Math.ceil(this.c.month/3):NaN}get month(){return this.isValid?this.c.month:NaN}get day(){return this.isValid?this.c.day:NaN}get hour(){return this.isValid?this.c.hour:NaN}get minute(){return this.isValid?this.c.minute:NaN}get second(){return this.isValid?this.c.second:NaN}get millisecond(){return this.isValid?this.c.millisecond:NaN}get weekYear(){return this.isValid?qa(this).weekYear:NaN}get weekNumber(){return this.isValid?qa(this).weekNumber:NaN}get weekday(){return this.isValid?qa(this).weekday:NaN}get isWeekend(){return this.isValid&&this.loc.getWeekendDays().includes(this.weekday)}get localWeekday(){return this.isValid?ou(this).weekday:NaN}get localWeekNumber(){return this.isValid?ou(this).weekNumber:NaN}get localWeekYear(){return this.isValid?ou(this).weekYear:NaN}get ordinal(){return this.isValid?wr(this.c).ordinal:NaN}get monthShort(){return this.isValid?ri.months("short",{locObj:this.loc})[this.month-1]:null}get monthLong(){return this.isValid?ri.months("long",{locObj:this.loc})[this.month-1]:null}get weekdayShort(){return this.isValid?ri.weekdays("short",{locObj:this.loc})[this.weekday-1]:null}get weekdayLong(){return this.isValid?ri.weekdays("long",{locObj:this.loc})[this.weekday-1]:null}get offset(){return this.isValid?+this.o:NaN}get offsetNameShort(){return this.isValid?this.zone.offsetName(this.ts,{format:"short",locale:this.locale}):null}get offsetNameLong(){return this.isValid?this.zone.offsetName(this.ts,{format:"long",locale:this.locale}):null}get isOffsetFixed(){return this.isValid?this.zone.isUniversal:null}get isInDST(){return!this.isOffsetFixed&&(this.offset>this.set({month:1,day:1}).offset||this.offset>this.set({month:5}).offset)}getPossibleOffsets(){if(!this.isValid||this.isOffsetFixed)return[this];const m=864e5,d=6e4,_=Xo(this.c),D=this.zone.offset(_-m),V=this.zone.offset(_+m),J=this.zone.offset(_-D*d),we=this.zone.offset(_-V*d);if(J===we)return[this];const Xe=_-J*d,yt=_-we*d,un=Rl(Xe,J),_n=Rl(yt,we);return un.hour===_n.hour&&un.minute===_n.minute&&un.second===_n.second&&un.millisecond===_n.millisecond?[ka(this,{ts:Xe}),ka(this,{ts:yt})]:[this]}get isInLeapYear(){return go(this.year)}get daysInMonth(){return fs(this.year,this.month)}get daysInYear(){return this.isValid?io(this.year):NaN}get weeksInWeekYear(){return this.isValid?_o(this.weekYear):NaN}get weeksInLocalWeekYear(){return this.isValid?_o(this.localWeekYear,this.loc.getMinDaysInFirstWeek(),this.loc.getStartOfWeek()):NaN}resolvedLocaleOptions(m={}){const{locale:d,numberingSystem:_,calendar:D}=On.create(this.loc.clone(m),m).resolvedOptions(this);return{locale:d,numberingSystem:_,outputCalendar:D}}toUTC(m=0,d={}){return this.setZone(Ni.instance(m),d)}toLocal(){return this.setZone(Ne.defaultZone)}setZone(m,{keepLocalTime:d=!1,keepCalendarTime:_=!1}={}){if((m=$o(m,Ne.defaultZone)).equals(this.zone))return this;if(m.isValid){let D=this.ts;if(d||_){const V=m.offset(this.ts),J=this.toObject();[D]=su(J,V,m)}return ka(this,{ts:D,zone:m})}return Fr.invalid(Ma(m))}reconfigure({locale:m,numberingSystem:d,outputCalendar:_}={}){return ka(this,{loc:this.loc.clone({locale:m,numberingSystem:d,outputCalendar:_})})}setLocale(m){return this.reconfigure({locale:m})}set(m){if(!this.isValid)return this;const d=_s(m,Uu),{minDaysInFirstWeek:_,startOfWeek:D}=gi(d,this.loc),V=!Pr(d.weekYear)||!Pr(d.weekNumber)||!Pr(d.weekday),J=!Pr(d.ordinal),we=!Pr(d.year),Xe=!Pr(d.month)||!Pr(d.day);if((we||Xe||J)&&(d.weekYear||d.weekNumber))throw new $e("Can't mix weekYear/weekNumber units with year/month/day or ordinals");if(Xe&&J)throw new $e("Can't mix ordinal dates with month/day");let _n;V?_n=ar({...Jn(this.c,_,D),...d},_,D):Pr(d.ordinal)?(_n={...this.toObject(),...d},Pr(d.day)&&(_n.day=Math.min(fs(_n.year,_n.month),_n.day))):_n=xr({...wr(this.c),...d});const[gr,er]=su(_n,this.o,this.zone);return ka(this,{ts:gr,o:er})}plus(m){return this.isValid?ka(this,Fu(this,Bi.fromDurationLike(m))):this}minus(m){return this.isValid?ka(this,Fu(this,Bi.fromDurationLike(m).negate())):this}startOf(m,{useLocaleWeeks:d=!1}={}){if(!this.isValid)return this;const _={},D=Bi.normalizeUnit(m);switch(D){case"years":_.month=1;case"quarters":case"months":_.day=1;case"weeks":case"days":_.hour=0;case"hours":_.minute=0;case"minutes":_.second=0;case"seconds":_.millisecond=0}if("weeks"===D)if(d){const V=this.loc.getStartOfWeek(),{weekday:J}=this;Jthis.valueOf(),yt=function Uo(v,m,d,_){let[D,V,J,we]=function Za(v,m,d){const _=[["years",(Xe,yt)=>yt.year-Xe.year],["quarters",(Xe,yt)=>yt.quarter-Xe.quarter+4*(yt.year-Xe.year)],["months",(Xe,yt)=>yt.month-Xe.month+12*(yt.year-Xe.year)],["weeks",(Xe,yt)=>{const un=Xs(Xe,yt);return(un-un%7)/7}],["days",Xs]],D={},V=v;let J,we;for(const[Xe,yt]of _)d.indexOf(Xe)>=0&&(J=Xe,D[Xe]=yt(v,m),we=V.plus(D),we>m?(D[Xe]--,(v=V.plus(D))>m&&(we=v,D[Xe]--,v=V.plus(D))):v=we);return[v,D,we,J]}(v,m,d);const Xe=m-D,yt=d.filter(_n=>["hours","minutes","seconds","milliseconds"].indexOf(_n)>=0);0===yt.length&&(J0?Bi.fromMillis(Xe,_).shiftTo(...yt).plus(un):un}(J?this:m,J?m:this,V,D);return J?yt.negate():yt}diffNow(m="milliseconds",d={}){return this.diff(Fr.now(),m,d)}until(m){return this.isValid?co.fromDateTimes(this,m):this}hasSame(m,d,_){if(!this.isValid)return!1;const D=m.valueOf(),V=this.setZone(m.zone,{keepLocalTime:!0});return V.startOf(d,_)<=D&&D<=V.endOf(d,_)}equals(m){return this.isValid&&m.isValid&&this.valueOf()===m.valueOf()&&this.zone.equals(m.zone)&&this.loc.equals(m.loc)}toRelative(m={}){if(!this.isValid)return null;const d=m.base||Fr.fromObject({},{zone:this.zone}),_=m.padding?thisd.valueOf(),Math.min)}static max(...m){if(!m.every(Fr.isDateTime))throw new Ke("max requires all arguments be DateTimes");return Ks(m,d=>d.valueOf(),Math.max)}static fromFormatExplain(m,d,_={}){const{locale:D=null,numberingSystem:V=null}=_;return fa(dr.fromOpts({locale:D,numberingSystem:V,defaultToEN:!0}),m,d)}static fromStringExplain(m,d,_={}){return Fr.fromFormatExplain(m,d,_)}static buildFormatParser(m,d={}){const{locale:_=null,numberingSystem:D=null}=d,V=dr.fromOpts({locale:_,numberingSystem:D,defaultToEN:!0});return new Lo(V,m)}static fromFormatParser(m,d,_={}){if(Pr(m)||Pr(d))throw new Ke("fromFormatParser requires an input string and a format parser");const{locale:D=null,numberingSystem:V=null}=_,J=dr.fromOpts({locale:D,numberingSystem:V,defaultToEN:!0});if(!J.equals(d.locale))throw new Ke(`fromFormatParser called with a locale of ${J}, but the format parser was created for ${d.locale}`);const{result:we,zone:Xe,specificOffset:yt,invalidReason:un}=d.explainFromTokens(m);return un?Fr.invalid(un):Wl(we,Xe,_,`format ${d.format}`,m,yt)}static get DATE_SHORT(){return Te}static get DATE_MED(){return Ee}static get DATE_MED_WITH_WEEKDAY(){return st}static get DATE_FULL(){return Xt}static get DATE_HUGE(){return Mt}static get TIME_SIMPLE(){return Kt}static get TIME_WITH_SECONDS(){return rt}static get TIME_WITH_SHORT_OFFSET(){return Vt}static get TIME_WITH_LONG_OFFSET(){return en}static get TIME_24_SIMPLE(){return kn}static get TIME_24_WITH_SECONDS(){return Kn}static get TIME_24_WITH_SHORT_OFFSET(){return Nr}static get TIME_24_WITH_LONG_OFFSET(){return Rn}static get DATETIME_SHORT(){return pr}static get DATETIME_SHORT_WITH_SECONDS(){return cn}static get DATETIME_MED(){return Fe}static get DATETIME_MED_WITH_SECONDS(){return ke}static get DATETIME_MED_WITH_WEEKDAY(){return Je}static get DATETIME_FULL(){return z}static get DATETIME_FULL_WITH_SECONDS(){return N}static get DATETIME_HUGE(){return W}static get DATETIME_HUGE_WITH_SECONDS(){return Le}}function Gl(v){if(Fr.isDateTime(v))return v;if(v&&v.valueOf&&Do(v.valueOf()))return Fr.fromJSDate(v);if(v&&"object"==typeof v)return Fr.fromObject(v);throw new Ke(`Unknown datetime argument: ${v}, of type ${typeof v}`)}const pl=new c.nKC("MAT_LUXON_DATE_ADAPTER_OPTIONS",{providedIn:"root",factory:function gd(){return{useUtc:!1,firstDayOfWeek:0,defaultOutputCalendar:"gregory"}}});let Yl=(()=>{class v extends rn.MJ{_useUTC;_firstDayOfWeek;_defaultOutputCalendar;constructor(){super();const d=(0,c.WQX)(rn.Ju,{optional:!0}),_=(0,c.WQX)(pl,{optional:!0});this._useUTC=!!_?.useUtc,this._firstDayOfWeek=_?.firstDayOfWeek||0,this._defaultOutputCalendar=_?.defaultOutputCalendar||"gregory",this.setLocale(d||Fr.local().locale)}getYear(d){return d.year}getMonth(d){return d.month-1}getDate(d){return d.day}getDayOfWeek(d){return d.weekday}getMonthNames(d){return ri.months(d,{locale:this.locale,outputCalendar:this._defaultOutputCalendar})}getDateNames(){const d=new Intl.DateTimeFormat(this.locale,{day:"numeric",timeZone:"utc"});return function cu(v,m){const d=Array(v);for(let _=0;_d.format(Fr.utc(2017,1,_+1).toJSDate()))}getDayOfWeekNames(d){const _=ri.weekdays(d,{locale:this.locale});return _.unshift(_.pop()),_}getYearName(d){return d.toFormat("yyyy",this._getOptions())}getFirstDayOfWeek(){return this._firstDayOfWeek}getNumDaysInMonth(d){return d.daysInMonth}clone(d){return Fr.fromObject(d.toObject(),this._getOptions())}createDate(d,_,D){const V=this._getOptions();if(_<0||_>11)throw Error(`Invalid month index "${_}". Month index has to be between 0 and 11.`);if(D<1)throw Error(`Invalid date "${D}". Date has to be greater than 0.`);const J=this._useUTC?Fr.utc(d,_+1,D,V):Fr.local(d,_+1,D,V);if(!this.isValid(J))throw Error(`Invalid date "${D}". Reason: "${J.invalidReason}".`);return J}today(){const d=this._getOptions();return this._useUTC?Fr.utc(d):Fr.local(d)}parse(d,_){const D=this._getOptions();if("string"==typeof d&&d.length>0){const V=Fr.fromISO(d,D);if(this.isValid(V))return V;const J=Array.isArray(_)?_:[_];if(!_.length)throw Error("Formats array must not be empty.");for(const we of J){const Xe=Fr.fromFormat(d,we,D);if(this.isValid(Xe))return Xe}return this.invalid()}return"number"==typeof d?Fr.fromMillis(d,D):d instanceof Date?Fr.fromJSDate(d,D):d instanceof Fr?Fr.fromMillis(d.toMillis(),D):null}format(d,_){if(!this.isValid(d))throw Error("LuxonDateAdapter: Cannot format invalid date.");return this._useUTC?d.setLocale(this.locale).setZone("utc").toFormat(_):d.setLocale(this.locale).toFormat(_)}addCalendarYears(d,_){return d.reconfigure(this._getOptions()).plus({years:_})}addCalendarMonths(d,_){return d.reconfigure(this._getOptions()).plus({months:_})}addCalendarDays(d,_){return d.reconfigure(this._getOptions()).plus({days:_})}toIso8601(d){return d.toISO()}deserialize(d){const _=this._getOptions();let D;if(d instanceof Date&&(D=Fr.fromJSDate(d,_)),"string"==typeof d){if(!d)return null;D=Fr.fromISO(d,_)}return D&&this.isValid(D)?D:super.deserialize(d)}isDateInstance(d){return d instanceof Fr}isValid(d){return d.isValid}invalid(){return Fr.invalid("Invalid Luxon DateTime object.")}setTime(d,_,D,V){return this.clone(d).set({hour:_,minute:D,second:V,millisecond:0})}getHours(d){return d.hour}getMinutes(d){return d.minute}getSeconds(d){return d.second}parseTime(d,_){const D=this.parse(d,_);return(!D||!this.isValid(D))&&"string"==typeof d&&this.parse(d.replace(/[^0-9:(AM|PM)]/gi,""),_)||D}addSeconds(d,_){return d.reconfigure(this._getOptions()).plus({seconds:_})}_getOptions(){return{zone:this._useUTC?"utc":void 0,locale:this.locale,outputCalendar:this._defaultOutputCalendar}}static \u0275fac=function(_){return new(_||v)};static \u0275prov=c.jDH({token:v,factory:v.\u0275fac})}return v})();var Dr=r(1204);function rs(v){return new c.wOt(3e3,!1)}function Si(v){switch(v.length){case 0:return new Dr.sf;case 1:return v[0];default:return new Dr.ui(v)}}function Nl(v,m,d=new Map,_=new Map){const D=[],V=[];let J=-1,we=null;if(m.forEach(Xe=>{const yt=Xe.get("offset"),un=yt==J,_n=un&&we||new Map;Xe.forEach((gr,er)=>{let fr=er,ti=gr;if("offset"!==er)switch(fr=v.normalizePropertyName(fr,D),ti){case Dr.FX:ti=d.get(er);break;case Dr.kp:ti=_.get(er);break;default:ti=v.normalizeStyleValue(er,fr,ti,D)}_n.set(fr,ti)}),un||V.push(_n),we=_n,J=yt}),D.length)throw function uh(){return new c.wOt(3502,!1)}();return V}function Ra(v,m,d,_){switch(m){case"start":v.onStart(()=>_(d&&Qs(d,"start",v)));break;case"done":v.onDone(()=>_(d&&Qs(d,"done",v)));break;case"destroy":v.onDestroy(()=>_(d&&Qs(d,"destroy",v)))}}function Qs(v,m,d){const V=Oc(v.element,v.triggerName,v.fromState,v.toState,m||v.phaseName,d.totalTime??v.totalTime,!!d.disabled),J=v._data;return null!=J&&(V._data=J),V}function Oc(v,m,d,_,D="",V=0,J){return{element:v,triggerName:m,fromState:d,toState:_,phaseName:D,totalTime:V,disabled:!!J}}function pa(v,m,d){let _=v.get(m);return _||v.set(m,_=d),_}function vd(v){const m=v.indexOf(":");return[v.substring(1,m),v.slice(m+1)]}const em=typeof document>"u"?null:document.documentElement;function fh(v){const m=v.parentNode||v.host||null;return m===em?null:m}let ma=null,ql=!1;function I(v,m){for(;m;){if(m===v)return!0;m=fh(m)}return!1}function P(v,m,d){if(d)return Array.from(v.querySelectorAll(m));const _=v.querySelector(m);return _?[_]:[]}let oe=(()=>{class v{validateStyleProperty(d){return function Zs(v){ma||(ma=function yd(){return typeof document<"u"?document.body:null}()||{},ql=!!ma.style&&"WebkitAppearance"in ma.style);let m=!0;return ma.style&&!function ph(v){return"ebkit"==v.substring(1,6)}(v)&&(m=v in ma.style,!m&&ql&&(m="Webkit"+v.charAt(0).toUpperCase()+v.slice(1)in ma.style)),m}(d)}containsElement(d,_){return I(d,_)}getParentElement(d){return fh(d)}query(d,_,D){return P(d,_,D)}computeStyle(d,_,D){return D||""}animate(d,_,D,V,J,we=[],Xe){return new Dr.sf(D,V)}static \u0275fac=function(_){return new(_||v)};static \u0275prov=c.jDH({token:v,factory:v.\u0275fac})}return v})();class Ae{static NOOP=new oe}class je{}const It=1e3,An="ng-enter",Qt="ng-leave",Gn="ng-trigger",zn=".ng-trigger",nr="ng-animating",Mn=".ng-animating";function Hn(v){if("number"==typeof v)return v;const m=v.match(/^(-?[\.\d]+)(m?s)/);return!m||m.length<2?0:Xn(parseFloat(m[1]),m[2])}function Xn(v,m){return"s"===m?v*It:v}function vr(v,m,d){return v.hasOwnProperty("duration")?v:function $n(v,m,d){let D,V=0,J="";if("string"==typeof v){const we=v.match(/^(-?[\.\d]+)(m?s)(?:\s+(-?[\.\d]+)(m?s))?(?:\s+([-a-z]+(?:\(.+?\))?))?$/i);if(null===we)return m.push(rs()),{duration:0,delay:0,easing:""};D=Xn(parseFloat(we[1]),we[2]);const Xe=we[3];null!=Xe&&(V=Xn(parseFloat(Xe),we[4]));const yt=we[5];yt&&(J=yt)}else D=v;if(!d){let we=!1,Xe=m.length;D<0&&(m.push(function R(){return new c.wOt(3100,!1)}()),we=!0),V<0&&(m.push(function G(){return new c.wOt(3101,!1)}()),we=!0),we&&m.splice(Xe,0,rs())}return{duration:D,delay:V,easing:J}}(v,m,d)}function Cr(v,m,d){m.forEach((_,D)=>{const V=ga(D);d&&!d.has(D)&&d.set(D,v.style[V]),v.style[V]=_})}function Gr(v,m){m.forEach((d,_)=>{const D=ga(_);v.style[D]=""})}function Br(v){return Array.isArray(v)?1==v.length?v[0]:(0,Dr.K2)(v):v}const Ji=new RegExp("{{\\s*(.+?)\\s*}}","g");function Xi(v){let m=[];if("string"==typeof v){let d;for(;d=Ji.exec(v);)m.push(d[1]);Ji.lastIndex=0}return m}function bo(v,m,d){const _=`${v}`,D=_.replace(Ji,(V,J)=>{let we=m[J];return null==we&&(d.push(function K(){return new c.wOt(3003,!1)}()),we=""),we.toString()});return D==_?v:D}const To=/-+([a-z0-9])/g;function ga(v){return v.replace(To,(...m)=>m[1].toUpperCase())}function Yi(v,m,d){switch(m.type){case Dr.If.Trigger:return v.visitTrigger(m,d);case Dr.If.State:return v.visitState(m,d);case Dr.If.Transition:return v.visitTransition(m,d);case Dr.If.Sequence:return v.visitSequence(m,d);case Dr.If.Group:return v.visitGroup(m,d);case Dr.If.Animate:return v.visitAnimate(m,d);case Dr.If.Keyframes:return v.visitKeyframes(m,d);case Dr.If.Style:return v.visitStyle(m,d);case Dr.If.Reference:return v.visitReference(m,d);case Dr.If.AnimateChild:return v.visitAnimateChild(m,d);case Dr.If.AnimateRef:return v.visitAnimateRef(m,d);case Dr.If.Query:return v.visitQuery(m,d);case Dr.If.Stagger:return v.visitStagger(m,d);default:throw function _e(){return new c.wOt(3004,!1)}()}}function Mo(v,m){return window.getComputedStyle(v)[m]}const gs=new Set(["width","height","minWidth","minHeight","maxWidth","maxHeight","left","top","bottom","right","fontSize","outlineWidth","outlineOffset","paddingTop","paddingLeft","paddingBottom","paddingRight","marginTop","marginLeft","marginBottom","marginRight","borderRadius","borderWidth","borderTopWidth","borderLeftWidth","borderRightWidth","borderBottomWidth","textIndent","perspective"]);class qs extends je{normalizePropertyName(m,d){return ga(m)}normalizeStyleValue(m,d,_,D){let V="";const J=_.toString().trim();if(gs.has(d)&&0!==_&&"0"!==_)if("number"==typeof _)V="px";else{const we=_.match(/^[+-]?[\d\.]+([a-z]*)$/);we&&0==we[1].length&&D.push(function We(){return new c.wOt(3005,!1)}())}return J+V}}const yc="*";const Js=new Set(["true","1"]),ml=new Set(["false","0"]);function bc(v,m){const d=Js.has(v)||ml.has(v),_=Js.has(m)||ml.has(m);return(D,V)=>{let J=v==yc||v==D,we=m==yc||m==V;return!J&&d&&"boolean"==typeof D&&(J=D?Js.has(v):ml.has(v)),!we&&_&&"boolean"==typeof V&&(we=V?Js.has(m):ml.has(m)),J&&we}}const ju=new RegExp("s*:selfs*,?","g");function Vu(v,m,d,_){return new gh(v).build(m,d,_)}class gh{_driver;constructor(m){this._driver=m}build(m,d,_){const D=new Wu(d);return this._resetContextStyleTimingState(D),Yi(this,Br(m),D)}_resetContextStyleTimingState(m){m.currentQuerySelector="",m.collectedStyles=new Map,m.collectedStyles.set("",new Map),m.currentTime=0}visitTrigger(m,d){let _=d.queryCount=0,D=d.depCount=0;const V=[],J=[];return"@"==m.name.charAt(0)&&d.errors.push(function At(){return new c.wOt(3006,!1)}()),m.definitions.forEach(we=>{if(this._resetContextStyleTimingState(d),we.type==Dr.If.State){const Xe=we,yt=Xe.name;yt.toString().split(/\s*,\s*/).forEach(un=>{Xe.name=un,V.push(this.visitState(Xe,d))}),Xe.name=yt}else if(we.type==Dr.If.Transition){const Xe=this.visitTransition(we,d);_+=Xe.queryCount,D+=Xe.depCount,J.push(Xe)}else d.errors.push(function fn(){return new c.wOt(3007,!1)}())}),{type:Dr.If.Trigger,name:m.name,states:V,transitions:J,queryCount:_,depCount:D,options:null}}visitState(m,d){const _=this.visitStyle(m.styles,d),D=m.options&&m.options.params||null;if(_.containsDynamicStyles){const V=new Set,J=D||{};_.styles.forEach(we=>{we instanceof Map&&we.forEach(Xe=>{Xi(Xe).forEach(yt=>{J.hasOwnProperty(yt)||V.add(yt)})})}),V.size&&d.errors.push(function on(){return new c.wOt(3008,!1)}(0,V.values()))}return{type:Dr.If.State,name:m.name,style:_,options:D?{params:D}:null}}visitTransition(m,d){d.queryCount=0,d.depCount=0;const _=Yi(this,Br(m.animation),d),D=function tc(v,m){const d=[];return"string"==typeof v?v.split(/\s*,\s*/).forEach(_=>function Rc(v,m,d){if(":"==v[0]){const Xe=function mh(v,m){switch(v){case":enter":return"void => *";case":leave":return"* => void";case":increment":return(d,_)=>parseFloat(_)>parseFloat(d);case":decrement":return(d,_)=>parseFloat(_) *"}}(v,d);if("function"==typeof Xe)return void m.push(Xe);v=Xe}const _=v.match(/^(\*|[-\w]+)\s*()\s*(\*|[-\w]+)$/);if(null==_||_.length<4)return d.push(function Ys(){return new c.wOt(3015,!1)}()),m;const D=_[1],V=_[2],J=_[3];m.push(bc(D,J)),"<"==V[0]&&(D!=yc||J!=yc)&&m.push(bc(J,D))}(_,d,m)):d.push(v),d}(m.expr,d.errors);return{type:Dr.If.Transition,matchers:D,animation:_,queryCount:d.queryCount,depCount:d.depCount,options:Ll(m.options)}}visitSequence(m,d){return{type:Dr.If.Sequence,steps:m.steps.map(_=>Yi(this,_,d)),options:Ll(m.options)}}visitGroup(m,d){const _=d.currentTime;let D=0;const V=m.steps.map(J=>{d.currentTime=_;const we=Yi(this,J,d);return D=Math.max(D,d.currentTime),we});return d.currentTime=D,{type:Dr.If.Group,steps:V,options:Ll(m.options)}}visitAnimate(m,d){const _=function _h(v,m){if(v.hasOwnProperty("duration"))return v;if("number"==typeof v)return xf(vr(v,m).duration,0,"");const d=v;if(d.split(/\s+/).some(V=>"{"==V.charAt(0)&&"{"==V.charAt(1))){const V=xf(0,0,"");return V.dynamic=!0,V.strValue=d,V}const D=vr(d,m);return xf(D.duration,D.delay,D.easing)}(m.timings,d.errors);d.currentAnimateTimings=_;let D,V=m.styles?m.styles:(0,Dr.iF)({});if(V.type==Dr.If.Keyframes)D=this.visitKeyframes(V,d);else{let J=m.styles,we=!1;if(!J){we=!0;const yt={};_.easing&&(yt.easing=_.easing),J=(0,Dr.iF)(yt)}d.currentTime+=_.duration+_.delay;const Xe=this.visitStyle(J,d);Xe.isEmptyStep=we,D=Xe}return d.currentAnimateTimings=null,{type:Dr.If.Animate,timings:_,style:D,options:null}}visitStyle(m,d){const _=this._makeStyleAst(m,d);return this._validateStyleAst(_,d),_}_makeStyleAst(m,d){const _=[],D=Array.isArray(m.styles)?m.styles:[m.styles];for(let we of D)"string"==typeof we?we===Dr.kp?_.push(we):d.errors.push(new c.wOt(3002,!1)):_.push(new Map(Object.entries(we)));let V=!1,J=null;return _.forEach(we=>{if(we instanceof Map&&(we.has("easing")&&(J=we.get("easing"),we.delete("easing")),!V))for(let Xe of we.values())if(Xe.toString().indexOf("{{")>=0){V=!0;break}}),{type:Dr.If.Style,styles:_,easing:J,offset:m.offset,containsDynamicStyles:V,options:null}}_validateStyleAst(m,d){const _=d.currentAnimateTimings;let D=d.currentTime,V=d.currentTime;_&&V>0&&(V-=_.duration+_.delay),m.styles.forEach(J=>{"string"!=typeof J&&J.forEach((we,Xe)=>{const yt=d.collectedStyles.get(d.currentQuerySelector),un=yt.get(Xe);let _n=!0;un&&(V!=D&&V>=un.startTime&&D<=un.endTime&&(d.errors.push(function kr(){return new c.wOt(3010,!1)}()),_n=!1),V=un.startTime),_n&&yt.set(Xe,{startTime:V,endTime:D}),d.options&&function ro(v,m,d){const _=m.params||{},D=Xi(v);D.length&&D.forEach(V=>{_.hasOwnProperty(V)||d.push(function F(){return new c.wOt(3001,!1)}())})}(we,d.options,d.errors)})})}visitKeyframes(m,d){const _={type:Dr.If.Keyframes,styles:[],options:null};if(!d.currentAnimateTimings)return d.errors.push(function Gi(){return new c.wOt(3011,!1)}()),_;let V=0;const J=[];let we=!1,Xe=!1,yt=0;const un=m.steps.map(ko=>{const ho=this._makeStyleAst(ko,d);let Ea=null!=ho.offset?ho.offset:function nm(v){if("string"==typeof v)return null;let m=null;if(Array.isArray(v))v.forEach(d=>{if(d instanceof Map&&d.has("offset")){const _=d;m=parseFloat(_.get("offset")),_.delete("offset")}});else if(v instanceof Map&&v.has("offset")){const d=v;m=parseFloat(d.get("offset")),d.delete("offset")}return m}(ho.styles),ta=0;return null!=Ea&&(V++,ta=ho.offset=Ea),Xe=Xe||ta<0||ta>1,we=we||ta0&&V<_n?d.errors.push(function Oa(){return new c.wOt(3202,!1)}()):0==V&&(gr=1/(_n-1));const er=_n-1,fr=d.currentTime,ti=d.currentAnimateTimings,Ai=ti.duration;return un.forEach((ko,ho)=>{const Ea=gr>0?ho==er?1:gr*ho:J[ho],ta=Ea*Ai;d.currentTime=fr+ti.delay+ta,ti.duration=ta,this._validateStyleAst(ko,d),ko.offset=Ea,_.styles.push(ko)}),_}visitReference(m,d){return{type:Dr.If.Reference,animation:Yi(this,Br(m.animation),d),options:Ll(m.options)}}visitAnimateChild(m,d){return d.depCount++,{type:Dr.If.AnimateChild,options:Ll(m.options)}}visitAnimateRef(m,d){return{type:Dr.If.AnimateRef,animation:this.visitReference(m.animation,d),options:Ll(m.options)}}visitQuery(m,d){const _=d.currentQuerySelector,D=m.options||{};d.queryCount++,d.currentQuery=m;const[V,J]=function Hu(v){const m=!!v.split(/\s*,\s*/).find(d=>":self"==d);return m&&(v=v.replace(ju,"")),v=v.replace(/@\*/g,zn).replace(/@\w+/g,d=>zn+"-"+d.slice(1)).replace(/:animating/g,Mn),[v,m]}(m.selector);d.currentQuerySelector=_.length?_+" "+V:V,pa(d.collectedStyles,d.currentQuerySelector,new Map);const we=Yi(this,Br(m.animation),d);return d.currentQuery=null,d.currentQuerySelector=_,{type:Dr.If.Query,selector:V,limit:D.limit||0,optional:!!D.optional,includeSelf:J,animation:we,originalSelector:m.selector,options:Ll(m.options)}}visitStagger(m,d){d.currentQuery||d.errors.push(function us(){return new c.wOt(3013,!1)}());const _="full"===m.timings?{duration:0,delay:0,easing:"full"}:vr(m.timings,d.errors,!0);return{type:Dr.If.Stagger,animation:Yi(this,Br(m.animation),d),timings:_,options:null}}}class Wu{errors;queryCount=0;depCount=0;currentTransition=null;currentQuery=null;currentQuerySelector=null;currentAnimateTimings=null;currentTime=0;collectedStyles=new Map;options=null;unsupportedCSSPropertiesFound=new Set;constructor(m){this.errors=m}}function Ll(v){return v?(v={...v}).params&&(v.params=function tm(v){return v?{...v}:null}(v.params)):v={},v}function xf(v,m,d){return{duration:v,delay:m,easing:d}}function bd(v,m,d,_,D,V,J=null,we=!1){return{type:1,element:v,keyframes:m,preStyleProps:d,postStyleProps:_,duration:D,delay:V,totalTime:D+V,easing:J,subTimeline:we}}class zu{_map=new Map;get(m){return this._map.get(m)||[]}append(m,d){let _=this._map.get(m);_||this._map.set(m,_=[]),_.push(...d)}has(m){return this._map.has(m)}clear(){this._map.clear()}}const im=new RegExp(":enter","g"),Cf=new RegExp(":leave","g");function wd(v,m,d,_,D,V=new Map,J=new Map,we,Xe,yt=[]){return(new Nc).buildKeyframes(v,m,d,_,D,V,J,we,Xe,yt)}class Nc{buildKeyframes(m,d,_,D,V,J,we,Xe,yt,un=[]){yt=yt||new zu;const _n=new Ed(m,d,yt,D,V,un,[]);_n.options=Xe;const gr=Xe.delay?Hn(Xe.delay):0;_n.currentTimeline.delayNextStep(gr),_n.currentTimeline.setStyles([J],null,_n.errors,Xe),Yi(this,_,_n);const er=_n.timelines.filter(fr=>fr.containsAnimation());if(er.length&&we.size){let fr;for(let ti=er.length-1;ti>=0;ti--){const Ai=er[ti];if(Ai.element===d){fr=Ai;break}}fr&&!fr.allowOnlyTimelineStyles()&&fr.setStyles([we],null,_n.errors,Xe)}return er.length?er.map(fr=>fr.buildKeyframes()):[bd(d,[],[],[],0,gr,"",!1)]}visitTrigger(m,d){}visitState(m,d){}visitTransition(m,d){}visitAnimateChild(m,d){const _=d.subInstructions.get(d.element);if(_){const D=d.createSubContext(m.options),V=d.currentTimeline.currentTime,J=this._visitSubInstructions(_,D,D.options);V!=J&&d.transformIntoNewTimeline(J)}d.previousNode=m}visitAnimateRef(m,d){const _=d.createSubContext(m.options);_.transformIntoNewTimeline(),this._applyAnimationRefDelays([m.options,m.animation.options],d,_),this.visitReference(m.animation,_),d.transformIntoNewTimeline(_.currentTimeline.currentTime),d.previousNode=m}_applyAnimationRefDelays(m,d,_){for(const D of m){const V=D?.delay;if(V){const J="number"==typeof V?V:Hn(bo(V,D?.params??{},d.errors));_.delayNextStep(J)}}}_visitSubInstructions(m,d,_){let V=d.currentTimeline.currentTime;const J=null!=_.duration?Hn(_.duration):null,we=null!=_.delay?Hn(_.delay):null;return 0!==J&&m.forEach(Xe=>{const yt=d.appendInstructionToTimeline(Xe,J,we);V=Math.max(V,yt.duration+yt.delay)}),V}visitReference(m,d){d.updateOptions(m.options,!0),Yi(this,m.animation,d),d.previousNode=m}visitSequence(m,d){const _=d.subContextCount;let D=d;const V=m.options;if(V&&(V.params||V.delay)&&(D=d.createSubContext(V),D.transformIntoNewTimeline(),null!=V.delay)){D.previousNode.type==Dr.If.Style&&(D.currentTimeline.snapshotCurrentStyles(),D.previousNode=Lc);const J=Hn(V.delay);D.delayNextStep(J)}m.steps.length&&(m.steps.forEach(J=>Yi(this,J,D)),D.currentTimeline.applyStylesToKeyframe(),D.subContextCount>_&&D.transformIntoNewTimeline()),d.previousNode=m}visitGroup(m,d){const _=[];let D=d.currentTimeline.currentTime;const V=m.options&&m.options.delay?Hn(m.options.delay):0;m.steps.forEach(J=>{const we=d.createSubContext(m.options);V&&we.delayNextStep(V),Yi(this,J,we),D=Math.max(D,we.currentTimeline.currentTime),_.push(we.currentTimeline)}),_.forEach(J=>d.currentTimeline.mergeTimelineCollectedStyles(J)),d.transformIntoNewTimeline(D),d.previousNode=m}_visitTiming(m,d){if(m.dynamic){const _=m.strValue;return vr(d.params?bo(_,d.params,d.errors):_,d.errors)}return{duration:m.duration,delay:m.delay,easing:m.easing}}visitAnimate(m,d){const _=d.currentAnimateTimings=this._visitTiming(m.timings,d),D=d.currentTimeline;_.delay&&(d.incrementTime(_.delay),D.snapshotCurrentStyles());const V=m.style;V.type==Dr.If.Keyframes?this.visitKeyframes(V,d):(d.incrementTime(_.duration),this.visitStyle(V,d),D.applyStylesToKeyframe()),d.currentAnimateTimings=null,d.previousNode=m}visitStyle(m,d){const _=d.currentTimeline,D=d.currentAnimateTimings;!D&&_.hasCurrentStyleProperties()&&_.forwardFrame();const V=D&&D.easing||m.easing;m.isEmptyStep?_.applyEmptyStep(V):_.setStyles(m.styles,V,d.errors,d.options),d.previousNode=m}visitKeyframes(m,d){const _=d.currentAnimateTimings,D=d.currentTimeline.duration,V=_.duration,we=d.createSubContext().currentTimeline;we.easing=_.easing,m.styles.forEach(Xe=>{we.forwardTime((Xe.offset||0)*V),we.setStyles(Xe.styles,Xe.easing,d.errors,d.options),we.applyStylesToKeyframe()}),d.currentTimeline.mergeTimelineCollectedStyles(we),d.transformIntoNewTimeline(D+V),d.previousNode=m}visitQuery(m,d){const _=d.currentTimeline.currentTime,D=m.options||{},V=D.delay?Hn(D.delay):0;V&&(d.previousNode.type===Dr.If.Style||0==_&&d.currentTimeline.hasCurrentStyleProperties())&&(d.currentTimeline.snapshotCurrentStyles(),d.previousNode=Lc);let J=_;const we=d.invokeQuery(m.selector,m.originalSelector,m.limit,m.includeSelf,!!D.optional,d.errors);d.currentQueryTotal=we.length;let Xe=null;we.forEach((yt,un)=>{d.currentQueryIndex=un;const _n=d.createSubContext(m.options,yt);V&&_n.delayNextStep(V),yt===d.element&&(Xe=_n.currentTimeline),Yi(this,m.animation,_n),_n.currentTimeline.applyStylesToKeyframe(),J=Math.max(J,_n.currentTimeline.currentTime)}),d.currentQueryIndex=0,d.currentQueryTotal=0,d.transformIntoNewTimeline(J),Xe&&(d.currentTimeline.mergeTimelineCollectedStyles(Xe),d.currentTimeline.snapshotCurrentStyles()),d.previousNode=m}visitStagger(m,d){const _=d.parentContext,D=d.currentTimeline,V=m.timings,J=Math.abs(V.duration),we=J*(d.currentQueryTotal-1);let Xe=J*d.currentQueryIndex;switch(V.duration<0?"reverse":V.easing){case"reverse":Xe=we-Xe;break;case"full":Xe=_.currentStaggerTime}const un=d.currentTimeline;Xe&&un.delayNextStep(Xe);const _n=un.currentTime;Yi(this,m.animation,d),d.previousNode=m,_.currentStaggerTime=D.currentTime-_n+(D.startTime-_.currentTimeline.startTime)}}const Lc={};class Ed{_driver;element;subInstructions;_enterClassName;_leaveClassName;errors;timelines;parentContext=null;currentTimeline;currentAnimateTimings=null;previousNode=Lc;subContextCount=0;options={};currentQueryIndex=0;currentQueryTotal=0;currentStaggerTime=0;constructor(m,d,_,D,V,J,we,Xe){this._driver=m,this.element=d,this.subInstructions=_,this._enterClassName=D,this._leaveClassName=V,this.errors=J,this.timelines=we,this.currentTimeline=Xe||new Ku(this._driver,d,0),we.push(this.currentTimeline)}get params(){return this.options.params}updateOptions(m,d){if(!m)return;const _=m;let D=this.options;null!=_.duration&&(D.duration=Hn(_.duration)),null!=_.delay&&(D.delay=Hn(_.delay));const V=_.params;if(V){let J=D.params;J||(J=this.options.params={}),Object.keys(V).forEach(we=>{(!d||!J.hasOwnProperty(we))&&(J[we]=bo(V[we],J,this.errors))})}}_copyOptions(){const m={};if(this.options){const d=this.options.params;if(d){const _=m.params={};Object.keys(d).forEach(D=>{_[D]=d[D]})}}return m}createSubContext(m=null,d,_){const D=d||this.element,V=new Ed(this._driver,D,this.subInstructions,this._enterClassName,this._leaveClassName,this.errors,this.timelines,this.currentTimeline.fork(D,_||0));return V.previousNode=this.previousNode,V.currentAnimateTimings=this.currentAnimateTimings,V.options=this._copyOptions(),V.updateOptions(m),V.currentQueryIndex=this.currentQueryIndex,V.currentQueryTotal=this.currentQueryTotal,V.parentContext=this,this.subContextCount++,V}transformIntoNewTimeline(m){return this.previousNode=Lc,this.currentTimeline=this.currentTimeline.fork(this.element,m),this.timelines.push(this.currentTimeline),this.currentTimeline}appendInstructionToTimeline(m,d,_){const D={duration:d??m.duration,delay:this.currentTimeline.currentTime+(_??0)+m.delay,easing:""},V=new Df(this._driver,m.element,m.keyframes,m.preStyleProps,m.postStyleProps,D,m.stretchStartingKeyframe);return this.timelines.push(V),D}incrementTime(m){this.currentTimeline.forwardTime(this.currentTimeline.duration+m)}delayNextStep(m){m>0&&this.currentTimeline.delayNextStep(m)}invokeQuery(m,d,_,D,V,J){let we=[];if(D&&we.push(this.element),m.length>0){m=(m=m.replace(im,"."+this._enterClassName)).replace(Cf,"."+this._leaveClassName);let yt=this._driver.query(this.element,m,1!=_);0!==_&&(yt=_<0?yt.slice(yt.length+_,yt.length):yt.slice(0,_)),we.push(...yt)}return!V&&0==we.length&&J.push(function Wr(){return new c.wOt(3014,!1)}()),we}}class Ku{_driver;element;startTime;_elementTimelineStylesLookup;duration=0;easing=null;_previousKeyframe=new Map;_currentKeyframe=new Map;_keyframes=new Map;_styleSummary=new Map;_localTimelineStyles=new Map;_globalTimelineStyles;_pendingStyles=new Map;_backFill=new Map;_currentEmptyStepKeyframe=null;constructor(m,d,_,D){this._driver=m,this.element=d,this.startTime=_,this._elementTimelineStylesLookup=D,this._elementTimelineStylesLookup||(this._elementTimelineStylesLookup=new Map),this._globalTimelineStyles=this._elementTimelineStylesLookup.get(d),this._globalTimelineStyles||(this._globalTimelineStyles=this._localTimelineStyles,this._elementTimelineStylesLookup.set(d,this._localTimelineStyles)),this._loadKeyframe()}containsAnimation(){switch(this._keyframes.size){case 0:return!1;case 1:return this.hasCurrentStyleProperties();default:return!0}}hasCurrentStyleProperties(){return this._currentKeyframe.size>0}get currentTime(){return this.startTime+this.duration}delayNextStep(m){const d=1===this._keyframes.size&&this._pendingStyles.size;this.duration||d?(this.forwardTime(this.currentTime+m),d&&this.snapshotCurrentStyles()):this.startTime+=m}fork(m,d){return this.applyStylesToKeyframe(),new Ku(this._driver,m,d||this.currentTime,this._elementTimelineStylesLookup)}_loadKeyframe(){this._currentKeyframe&&(this._previousKeyframe=this._currentKeyframe),this._currentKeyframe=this._keyframes.get(this.duration),this._currentKeyframe||(this._currentKeyframe=new Map,this._keyframes.set(this.duration,this._currentKeyframe))}forwardFrame(){this.duration+=1,this._loadKeyframe()}forwardTime(m){this.applyStylesToKeyframe(),this.duration=m,this._loadKeyframe()}_updateStyle(m,d){this._localTimelineStyles.set(m,d),this._globalTimelineStyles.set(m,d),this._styleSummary.set(m,{time:this.currentTime,value:d})}allowOnlyTimelineStyles(){return this._currentEmptyStepKeyframe!==this._currentKeyframe}applyEmptyStep(m){m&&this._previousKeyframe.set("easing",m);for(let[d,_]of this._globalTimelineStyles)this._backFill.set(d,_||Dr.kp),this._currentKeyframe.set(d,Dr.kp);this._currentEmptyStepKeyframe=this._currentKeyframe}setStyles(m,d,_,D){d&&this._previousKeyframe.set("easing",d);const V=D&&D.params||{},J=function Af(v,m){const d=new Map;let _;return v.forEach(D=>{if("*"===D){_??=m.keys();for(let V of _)d.set(V,Dr.kp)}else for(let[V,J]of D)d.set(V,J)}),d}(m,this._globalTimelineStyles);for(let[we,Xe]of J){const yt=bo(Xe,V,_);this._pendingStyles.set(we,yt),this._localTimelineStyles.has(we)||this._backFill.set(we,this._globalTimelineStyles.get(we)??Dr.kp),this._updateStyle(we,yt)}}applyStylesToKeyframe(){0!=this._pendingStyles.size&&(this._pendingStyles.forEach((m,d)=>{this._currentKeyframe.set(d,m)}),this._pendingStyles.clear(),this._localTimelineStyles.forEach((m,d)=>{this._currentKeyframe.has(d)||this._currentKeyframe.set(d,m)}))}snapshotCurrentStyles(){for(let[m,d]of this._localTimelineStyles)this._pendingStyles.set(m,d),this._updateStyle(m,d)}getFinalKeyframe(){return this._keyframes.get(this.duration)}get properties(){const m=[];for(let d in this._currentKeyframe)m.push(d);return m}mergeTimelineCollectedStyles(m){m._styleSummary.forEach((d,_)=>{const D=this._styleSummary.get(_);(!D||d.time>D.time)&&this._updateStyle(_,d.value)})}buildKeyframes(){this.applyStylesToKeyframe();const m=new Set,d=new Set,_=1===this._keyframes.size&&0===this.duration;let D=[];this._keyframes.forEach((we,Xe)=>{const yt=new Map([...this._backFill,...we]);yt.forEach((un,_n)=>{un===Dr.FX?m.add(_n):un===Dr.kp&&d.add(_n)}),_||yt.set("offset",Xe/this.duration),D.push(yt)});const V=[...m.values()],J=[...d.values()];if(_){const we=D[0],Xe=new Map(we);we.set("offset",0),Xe.set("offset",1),D=[we,Xe]}return bd(this.element,D,V,J,this.duration,this.startTime,this.easing,!1)}}class Df extends Ku{keyframes;preStyleProps;postStyleProps;_stretchStartingKeyframe;timings;constructor(m,d,_,D,V,J,we=!1){super(m,d,J.delay),this.keyframes=_,this.preStyleProps=D,this.postStyleProps=V,this._stretchStartingKeyframe=we,this.timings={duration:J.duration,delay:J.delay,easing:J.easing}}containsAnimation(){return this.keyframes.length>1}buildKeyframes(){let m=this.keyframes,{delay:d,duration:_,easing:D}=this.timings;if(this._stretchStartingKeyframe&&d){const V=[],J=_+d,we=d/J,Xe=new Map(m[0]);Xe.set("offset",0),V.push(Xe);const yt=new Map(m[0]);yt.set("offset",yh(we)),V.push(yt);const un=m.length-1;for(let _n=1;_n<=un;_n++){let gr=new Map(m[_n]);const er=gr.get("offset");gr.set("offset",yh((d+er*_)/J)),V.push(gr)}_=J,d=0,D="",m=V}return bd(this.element,m,this.preStyleProps,this.postStyleProps,_,d,D,!0)}}function yh(v,m=3){const d=Math.pow(10,m-1);return Math.round(v*d)/d}function bh(v,m,d,_,D,V,J,we,Xe,yt,un,_n,gr){return{type:0,element:v,triggerName:m,isRemovalTransition:D,fromState:d,fromStyles:V,toState:_,toStyles:J,timelines:we,queriedElements:Xe,preStyleProps:yt,postStyleProps:un,totalTime:_n,errors:gr}}const fu={};class Fl{_triggerName;ast;_stateStyles;constructor(m,d,_){this._triggerName=m,this.ast=d,this._stateStyles=_}match(m,d,_,D){return function xd(v,m,d,_,D){return v.some(V=>V(m,d,_,D))}(this.ast.matchers,m,d,_,D)}buildStyles(m,d,_){let D=this._stateStyles.get("*");return void 0!==m&&(D=this._stateStyles.get(m?.toString())||D),D?D.buildStyles(d,_):new Map}build(m,d,_,D,V,J,we,Xe,yt,un){const _n=[],gr=this.ast.options&&this.ast.options.params||fu,fr=this.buildStyles(_,we&&we.params||fu,_n),ti=Xe&&Xe.params||fu,Ai=this.buildStyles(D,ti,_n),ko=new Set,ho=new Map,Ea=new Map,ta="void"===D,Ou={params:wh(ti,gr),delay:this.ast.options?.delay},vl=un?[]:wd(m,d,this.ast.animation,V,J,fr,Ai,Ou,yt,_n);let xa=0;return vl.forEach(Ya=>{xa=Math.max(Ya.duration+Ya.delay,xa)}),_n.length?bh(d,this._triggerName,_,D,ta,fr,Ai,[],[],ho,Ea,xa,_n):(vl.forEach(Ya=>{const Sl=Ya.element,Bl=pa(ho,Sl,new Set);Ya.preStyleProps.forEach(pd=>Bl.add(pd));const ff=pa(Ea,Sl,new Set);Ya.postStyleProps.forEach(pd=>ff.add(pd)),Sl!==d&&ko.add(Sl)}),bh(d,this._triggerName,_,D,ta,fr,Ai,vl,[...ko.values()],ho,Ea,xa))}}function wh(v,m){const d={...m};return Object.entries(v).forEach(([_,D])=>{null!=D&&(d[_]=D)}),d}class Pc{styles;defaultParams;normalizer;constructor(m,d,_){this.styles=m,this.defaultParams=d,this.normalizer=_}buildStyles(m,d){const _=new Map,D=wh(m,this.defaultParams);return this.styles.styles.forEach(V=>{"string"!=typeof V&&V.forEach((J,we)=>{J&&(J=bo(J,D,d));const Xe=this.normalizer.normalizePropertyName(we,d);J=this.normalizer.normalizeStyleValue(we,Xe,J,d),_.set(we,J)})}),_}}class Fs{name;ast;_normalizer;transitionFactories=[];fallbackTransition;states=new Map;constructor(m,d,_){this.name=m,this.ast=d,this._normalizer=_,d.states.forEach(D=>{this.states.set(D.name,new Pc(D.style,D.options&&D.options.params||{},_))}),Eh(this.states,"true","1"),Eh(this.states,"false","0"),d.transitions.forEach(D=>{this.transitionFactories.push(new Fl(m,D,this.states))}),this.fallbackTransition=function Sf(v,m){return new Fl(v,{type:Dr.If.Transition,animation:{type:Dr.If.Sequence,steps:[],options:null},matchers:[(J,we)=>!0],options:null,queryCount:0,depCount:0},m)}(m,this.states)}get containsQueries(){return this.ast.queryCount>0}matchTransition(m,d,_,D){return this.transitionFactories.find(J=>J.match(m,d,_,D))||null}matchStyles(m,d,_){return this.fallbackTransition.buildStyles(m,d,_)}}function Eh(v,m,d){v.has(m)?v.has(d)||v.set(d,v.get(m)):v.has(d)&&v.set(m,v.get(d))}const Cd=new zu;class om{bodyNode;_driver;_normalizer;_animations=new Map;_playersById=new Map;players=[];constructor(m,d,_){this.bodyNode=m,this._driver=d,this._normalizer=_}register(m,d){const _=[],V=Vu(this._driver,d,_,[]);if(_.length)throw function dh(){return new c.wOt(3503,!1)}();this._animations.set(m,V)}_buildPlayer(m,d,_){const D=m.element,V=Nl(this._normalizer,m.keyframes,d,_);return this._driver.animate(D,V,m.duration,m.delay,m.easing,[],!0)}create(m,d,_={}){const D=[],V=this._animations.get(m);let J;const we=new Map;if(V?(J=wd(this._driver,d,V,An,Qt,new Map,new Map,_,Cd,D),J.forEach(un=>{const _n=pa(we,un.element,new Map);un.postStyleProps.forEach(gr=>_n.set(gr,null))})):(D.push(function hh(){return new c.wOt(3300,!1)}()),J=[]),D.length)throw function _c(){return new c.wOt(3504,!1)}();we.forEach((un,_n)=>{un.forEach((gr,er)=>{un.set(er,this._driver.computeStyle(_n,er,Dr.kp))})});const yt=Si(J.map(un=>{const _n=we.get(un.element);return this._buildPlayer(un,new Map,_n)}));return this._playersById.set(m,yt),yt.onDestroy(()=>this.destroy(m)),this.players.push(yt),yt}destroy(m){const d=this._getPlayer(m);d.destroy(),this._playersById.delete(m);const _=this.players.indexOf(d);_>=0&&this.players.splice(_,1)}_getPlayer(m){const d=this._playersById.get(m);if(!d)throw function Ql(){return new c.wOt(3301,!1)}();return d}listen(m,d,_,D){const V=Oc(d,"","","");return Ra(this._getPlayer(m),_,V,D),()=>{}}command(m,d,_,D){if("register"==_)return void this.register(m,D[0]);if("create"==_)return void this.create(m,d,D[0]||{});const V=this._getPlayer(m);switch(_){case"play":V.play();break;case"pause":V.pause();break;case"reset":V.reset();break;case"restart":V.restart();break;case"finish":V.finish();break;case"init":V.init();break;case"setPosition":V.setPosition(parseFloat(D[0]));break;case"destroy":this.destroy(m)}}}const Gu="ng-animate-queued",xh="ng-animate-disabled",Tf=[],Mf={namespaceId:"",setForRemoval:!1,setForMove:!1,hasAnimation:!1,removedBeforeQueried:!1},Ad={namespaceId:"",setForMove:!1,setForRemoval:!1,hasAnimation:!1,removedBeforeQueried:!0},Ga="__ng_removed";class Sd{namespaceId;value;options;get params(){return this.options.params}constructor(m,d=""){this.namespaceId=d;const _=m&&m.hasOwnProperty("value");if(this.value=function Ah(v){return v??null}(_?m.value:m),_){const{value:V,...J}=m;this.options=J}else this.options={};this.options.params||(this.options.params={})}absorbOptions(m){const d=m.params;if(d){const _=this.options.params;Object.keys(d).forEach(D=>{null==_[D]&&(_[D]=d[D])})}}}const Qu="void",Td=new Sd(Qu);class Ch{id;hostElement;_engine;players=[];_triggers=new Map;_queue=[];_elementListeners=new Map;_hostClassName;constructor(m,d,_){this.id=m,this.hostElement=d,this._engine=_,this._hostClassName="ng-tns-"+m,ws(d,this._hostClassName)}listen(m,d,_,D){if(!this._triggers.has(d))throw function Zl(){return new c.wOt(3302,!1)}();if(null==_||0==_.length)throw function uu(){return new c.wOt(3303,!1)}();if(!function lm(v){return"start"==v||"done"==v}(_))throw function du(){return new c.wOt(3400,!1)}();const V=pa(this._elementListeners,m,[]),J={name:d,phase:_,callback:D};V.push(J);const we=pa(this._engine.statesByElement,m,new Map);return we.has(d)||(ws(m,Gn),ws(m,Gn+"-"+d),we.set(d,Td)),()=>{this._engine.afterFlush(()=>{const Xe=V.indexOf(J);Xe>=0&&V.splice(Xe,1),this._triggers.has(d)||we.delete(d)})}}register(m,d){return!this._triggers.has(m)&&(this._triggers.set(m,d),!0)}_getTrigger(m){const d=this._triggers.get(m);if(!d)throw function Ja(){return new c.wOt(3401,!1)}();return d}trigger(m,d,_,D=!0){const V=this._getTrigger(d),J=new am(this.id,d,m);let we=this._engine.statesByElement.get(m);we||(ws(m,Gn),ws(m,Gn+"-"+d),this._engine.statesByElement.set(m,we=new Map));let Xe=we.get(d);const yt=new Sd(_,this.id);if(!(_&&_.hasOwnProperty("value"))&&Xe&&yt.absorbOptions(Xe.options),we.set(d,yt),Xe||(Xe=Td),yt.value!==Qu&&Xe.value===yt.value){if(!function If(v,m){const d=Object.keys(v),_=Object.keys(m);if(d.length!=_.length)return!1;for(let D=0;D{Gr(m,Ai),Cr(m,ko)})}return}const gr=pa(this._engine.playersByElement,m,[]);gr.forEach(ti=>{ti.namespaceId==this.id&&ti.triggerName==d&&ti.queued&&ti.destroy()});let er=V.matchTransition(Xe.value,yt.value,m,yt.params),fr=!1;if(!er){if(!D)return;er=V.fallbackTransition,fr=!0}return this._engine.totalQueuedPlayers++,this._queue.push({element:m,triggerName:d,transition:er,fromState:Xe,toState:yt,player:J,isFallbackTransition:fr}),fr||(ws(m,Gu),J.onStart(()=>{Fc(m,Gu)})),J.onDone(()=>{let ti=this.players.indexOf(J);ti>=0&&this.players.splice(ti,1);const Ai=this._engine.playersByElement.get(m);if(Ai){let ko=Ai.indexOf(J);ko>=0&&Ai.splice(ko,1)}}),this.players.push(J),gr.push(J),J}deregister(m){this._triggers.delete(m),this._engine.statesByElement.forEach(d=>d.delete(m)),this._elementListeners.forEach((d,_)=>{this._elementListeners.set(_,d.filter(D=>D.name!=m))})}clearElementCache(m){this._engine.statesByElement.delete(m),this._elementListeners.delete(m);const d=this._engine.playersByElement.get(m);d&&(d.forEach(_=>_.destroy()),this._engine.playersByElement.delete(m))}_signalRemovalForInnerTriggers(m,d){const _=this._engine.driver.query(m,zn,!0);_.forEach(D=>{if(D[Ga])return;const V=this._engine.fetchNamespacesByElement(D);V.size?V.forEach(J=>J.triggerLeaveAnimation(D,d,!1,!0)):this.clearElementCache(D)}),this._engine.afterFlushAnimationsDone(()=>_.forEach(D=>this.clearElementCache(D)))}triggerLeaveAnimation(m,d,_,D){const V=this._engine.statesByElement.get(m),J=new Map;if(V){const we=[];if(V.forEach((Xe,yt)=>{if(J.set(yt,Xe.value),this._triggers.has(yt)){const un=this.trigger(m,yt,Qu,D);un&&we.push(un)}}),we.length)return this._engine.markElementAsRemoved(this.id,m,!0,d,J),_&&Si(we).onDone(()=>this._engine.processLeaveNode(m)),!0}return!1}prepareLeaveAnimationListeners(m){const d=this._elementListeners.get(m),_=this._engine.statesByElement.get(m);if(d&&_){const D=new Set;d.forEach(V=>{const J=V.name;if(D.has(J))return;D.add(J);const Xe=this._triggers.get(J).fallbackTransition,yt=_.get(J)||Td,un=new Sd(Qu),_n=new am(this.id,J,m);this._engine.totalQueuedPlayers++,this._queue.push({element:m,triggerName:J,transition:Xe,fromState:yt,toState:un,player:_n,isFallbackTransition:!0})})}}removeNode(m,d){const _=this._engine;if(m.childElementCount&&this._signalRemovalForInnerTriggers(m,d),this.triggerLeaveAnimation(m,d,!0))return;let D=!1;if(_.totalAnimations){const V=_.players.length?_.playersByQueriedElement.get(m):[];if(V&&V.length)D=!0;else{let J=m;for(;J=J.parentNode;)if(_.statesByElement.get(J)){D=!0;break}}}if(this.prepareLeaveAnimationListeners(m),D)_.markElementAsRemoved(this.id,m,!1,d);else{const V=m[Ga];(!V||V===Mf)&&(_.afterFlush(()=>this.clearElementCache(m)),_.destroyInnerAnimations(m),_._onRemovalComplete(m,d))}}insertNode(m,d){ws(m,this._hostClassName)}drainQueuedTransitions(m){const d=[];return this._queue.forEach(_=>{const D=_.player;if(D.destroyed)return;const V=_.element,J=this._elementListeners.get(V);J&&J.forEach(we=>{if(we.name==_.triggerName){const Xe=Oc(V,_.triggerName,_.fromState.value,_.toState.value);Xe._data=m,Ra(_.player,we.phase,Xe,we.callback)}}),D.markedForDestroy?this._engine.afterFlush(()=>{D.destroy()}):d.push(_)}),this._queue=[],d.sort((_,D)=>{const V=_.transition.ast.depCount,J=D.transition.ast.depCount;return 0==V||0==J?V-J:this._engine.driver.containsElement(_.element,D.element)?1:-1})}destroy(m){this.players.forEach(d=>d.destroy()),this._signalRemovalForInnerTriggers(this.hostElement,m)}}class sm{bodyNode;driver;_normalizer;players=[];newHostElements=new Map;playersByElement=new Map;playersByQueriedElement=new Map;statesByElement=new Map;disabledNodes=new Set;totalAnimations=0;totalQueuedPlayers=0;_namespaceLookup={};_namespaceList=[];_flushFns=[];_whenQuietFns=[];namespacesByHostElement=new Map;collectedEnterElements=[];collectedLeaveElements=[];onRemovalComplete=(m,d)=>{};_onRemovalComplete(m,d){this.onRemovalComplete(m,d)}constructor(m,d,_){this.bodyNode=m,this.driver=d,this._normalizer=_}get queuedPlayers(){const m=[];return this._namespaceList.forEach(d=>{d.players.forEach(_=>{_.queued&&m.push(_)})}),m}createNamespace(m,d){const _=new Ch(m,d,this);return this.bodyNode&&this.driver.containsElement(this.bodyNode,d)?this._balanceNamespaceList(_,d):(this.newHostElements.set(d,_),this.collectEnterElement(d)),this._namespaceLookup[m]=_}_balanceNamespaceList(m,d){const _=this._namespaceList,D=this.namespacesByHostElement;if(_.length-1>=0){let J=!1,we=this.driver.getParentElement(d);for(;we;){const Xe=D.get(we);if(Xe){const yt=_.indexOf(Xe);_.splice(yt+1,0,m),J=!0;break}we=this.driver.getParentElement(we)}J||_.unshift(m)}else _.push(m);return D.set(d,m),m}register(m,d){let _=this._namespaceLookup[m];return _||(_=this.createNamespace(m,d)),_}registerTrigger(m,d,_){let D=this._namespaceLookup[m];D&&D.register(d,_)&&this.totalAnimations++}destroy(m,d){m&&(this.afterFlush(()=>{}),this.afterFlushAnimationsDone(()=>{const _=this._fetchNamespace(m);this.namespacesByHostElement.delete(_.hostElement);const D=this._namespaceList.indexOf(_);D>=0&&this._namespaceList.splice(D,1),_.destroy(d),delete this._namespaceLookup[m]}))}_fetchNamespace(m){return this._namespaceLookup[m]}fetchNamespacesByElement(m){const d=new Set,_=this.statesByElement.get(m);if(_)for(let D of _.values())if(D.namespaceId){const V=this._fetchNamespace(D.namespaceId);V&&d.add(V)}return d}trigger(m,d,_,D){if(Qo(d)){const V=this._fetchNamespace(m);if(V)return V.trigger(d,_,D),!0}return!1}insertNode(m,d,_,D){if(!Qo(d))return;const V=d[Ga];if(V&&V.setForRemoval){V.setForRemoval=!1,V.setForMove=!0;const J=this.collectedLeaveElements.indexOf(d);J>=0&&this.collectedLeaveElements.splice(J,1)}if(m){const J=this._fetchNamespace(m);J&&J.insertNode(d,_)}D&&this.collectEnterElement(d)}collectEnterElement(m){this.collectedEnterElements.push(m)}markElementAsDisabled(m,d){d?this.disabledNodes.has(m)||(this.disabledNodes.add(m),ws(m,xh)):this.disabledNodes.has(m)&&(this.disabledNodes.delete(m),Fc(m,xh))}removeNode(m,d,_){if(Qo(d)){const D=m?this._fetchNamespace(m):null;D?D.removeNode(d,_):this.markElementAsRemoved(m,d,!1,_);const V=this.namespacesByHostElement.get(d);V&&V.id!==m&&V.removeNode(d,_)}else this._onRemovalComplete(d,_)}markElementAsRemoved(m,d,_,D,V){this.collectedLeaveElements.push(d),d[Ga]={namespaceId:m,setForRemoval:D,hasAnimation:_,removedBeforeQueried:!1,previousTriggersValues:V}}listen(m,d,_,D,V){return Qo(d)?this._fetchNamespace(m).listen(d,_,D,V):()=>{}}_buildInstruction(m,d,_,D,V){return m.transition.build(this.driver,m.element,m.fromState.value,m.toState.value,_,D,m.fromState.options,m.toState.options,d,V)}destroyInnerAnimations(m){let d=this.driver.query(m,zn,!0);d.forEach(_=>this.destroyActiveAnimationsForElement(_)),0!=this.playersByQueriedElement.size&&(d=this.driver.query(m,Mn,!0),d.forEach(_=>this.finishActiveQueriedAnimationOnElement(_)))}destroyActiveAnimationsForElement(m){const d=this.playersByElement.get(m);d&&d.forEach(_=>{_.queued?_.markedForDestroy=!0:_.destroy()})}finishActiveQueriedAnimationOnElement(m){const d=this.playersByQueriedElement.get(m);d&&d.forEach(_=>_.finish())}whenRenderingDone(){return new Promise(m=>{if(this.players.length)return Si(this.players).onDone(()=>m());m()})}processLeaveNode(m){const d=m[Ga];if(d&&d.setForRemoval){if(m[Ga]=Mf,d.namespaceId){this.destroyInnerAnimations(m);const _=this._fetchNamespace(d.namespaceId);_&&_.clearElementCache(m)}this._onRemovalComplete(m,d.setForRemoval)}m.classList?.contains(xh)&&this.markElementAsDisabled(m,!1),this.driver.query(m,".ng-animate-disabled",!0).forEach(_=>{this.markElementAsDisabled(_,!1)})}flush(m=-1){let d=[];if(this.newHostElements.size&&(this.newHostElements.forEach((_,D)=>this._balanceNamespaceList(_,D)),this.newHostElements.clear()),this.totalAnimations&&this.collectedEnterElements.length)for(let _=0;__()),this._flushFns=[],this._whenQuietFns.length){const _=this._whenQuietFns;this._whenQuietFns=[],d.length?Si(d).onDone(()=>{_.forEach(D=>D())}):_.forEach(D=>D())}}reportError(m){throw function En(){return new c.wOt(3402,!1)}()}_flushAnimations(m,d){const _=new zu,D=[],V=new Map,J=[],we=new Map,Xe=new Map,yt=new Map,un=new Set;this.disabledNodes.forEach(Zr=>{un.add(Zr);const vi=this.driver.query(Zr,".ng-animate-queued",!0);for(let Ti=0;Ti{const Ti=An+ti++;fr.set(vi,Ti),Zr.forEach(xo=>ws(xo,Ti))});const Ai=[],ko=new Set,ho=new Set;for(let Zr=0;Zrko.add(xo)):ho.add(vi))}const Ea=new Map,ta=Sh(gr,Array.from(ko));ta.forEach((Zr,vi)=>{const Ti=Qt+ti++;Ea.set(vi,Ti),Zr.forEach(xo=>ws(xo,Ti))}),m.push(()=>{er.forEach((Zr,vi)=>{const Ti=fr.get(vi);Zr.forEach(xo=>Fc(xo,Ti))}),ta.forEach((Zr,vi)=>{const Ti=Ea.get(vi);Zr.forEach(xo=>Fc(xo,Ti))}),Ai.forEach(Zr=>{this.processLeaveNode(Zr)})});const Ou=[],vl=[];for(let Zr=this._namespaceList.length-1;Zr>=0;Zr--)this._namespaceList[Zr].drainQueuedTransitions(d).forEach(Ti=>{const xo=Ti.player,Ca=Ti.element;if(Ou.push(xo),this.collectedEnterElements.length){const ra=Ca[Ga];if(ra&&ra.setForMove){if(ra.previousTriggersValues&&ra.previousTriggersValues.has(Ti.triggerName)){const Qc=ra.previousTriggersValues.get(Ti.triggerName),dc=this.statesByElement.get(Ti.element);if(dc&&dc.has(Ti.triggerName)){const pf=dc.get(Ti.triggerName);pf.value=Qc,dc.set(Ti.triggerName,pf)}}return void xo.destroy()}}const na=!_n||!this.driver.containsElement(_n,Ca),sl=Ea.get(Ca),Ru=fr.get(Ca),xs=this._buildInstruction(Ti,_,Ru,sl,na);if(xs.errors&&xs.errors.length)return void vl.push(xs);if(na)return xo.onStart(()=>Gr(Ca,xs.fromStyles)),xo.onDestroy(()=>Cr(Ca,xs.toStyles)),void D.push(xo);if(Ti.isFallbackTransition)return xo.onStart(()=>Gr(Ca,xs.fromStyles)),xo.onDestroy(()=>Cr(Ca,xs.toStyles)),void D.push(xo);const ng=[];xs.timelines.forEach(ra=>{ra.stretchStartingKeyframe=!0,this.disabledNodes.has(ra.element)||ng.push(ra)}),xs.timelines=ng,_.append(Ca,xs.timelines),J.push({instruction:xs,player:xo,element:Ca}),xs.queriedElements.forEach(ra=>pa(we,ra,[]).push(xo)),xs.preStyleProps.forEach((ra,Qc)=>{if(ra.size){let dc=Xe.get(Qc);dc||Xe.set(Qc,dc=new Set),ra.forEach((pf,Dp)=>dc.add(Dp))}}),xs.postStyleProps.forEach((ra,Qc)=>{let dc=yt.get(Qc);dc||yt.set(Qc,dc=new Set),ra.forEach((pf,Dp)=>dc.add(Dp))})});if(vl.length){const Zr=[];vl.forEach(vi=>{Zr.push(function Ic(){return new c.wOt(3505,!1)}())}),Ou.forEach(vi=>vi.destroy()),this.reportError(Zr)}const xa=new Map,Ya=new Map;J.forEach(Zr=>{const vi=Zr.element;_.has(vi)&&(Ya.set(vi,vi),this._beforeAnimationBuild(Zr.player.namespaceId,Zr.instruction,xa))}),D.forEach(Zr=>{const vi=Zr.element;this._getPreviousPlayers(vi,!1,Zr.namespaceId,Zr.triggerName,null).forEach(xo=>{pa(xa,vi,[]).push(xo),xo.destroy()})});const Sl=Ai.filter(Zr=>Od(Zr,Xe,yt)),Bl=new Map;kf(Bl,this.driver,ho,yt,Dr.kp).forEach(Zr=>{Od(Zr,Xe,yt)&&Sl.push(Zr)});const pd=new Map;er.forEach((Zr,vi)=>{kf(pd,this.driver,new Set(Zr),Xe,Dr.FX)}),Sl.forEach(Zr=>{const vi=Bl.get(Zr),Ti=pd.get(Zr);Bl.set(Zr,new Map([...vi?.entries()??[],...Ti?.entries()??[]]))});const tg=[],Cp=[],ov={};J.forEach(Zr=>{const{element:vi,player:Ti,instruction:xo}=Zr;if(_.has(vi)){if(un.has(vi))return Ti.onDestroy(()=>Cr(vi,xo.toStyles)),Ti.disabled=!0,Ti.overrideTotalTime(xo.totalTime),void D.push(Ti);let Ca=ov;if(Ya.size>1){let sl=vi;const Ru=[];for(;sl=sl.parentNode;){const xs=Ya.get(sl);if(xs){Ca=xs;break}Ru.push(sl)}Ru.forEach(xs=>Ya.set(xs,Ca))}const na=this._buildAnimation(Ti.namespaceId,xo,xa,V,pd,Bl);if(Ti.setRealPlayer(na),Ca===ov)tg.push(Ti);else{const sl=this.playersByElement.get(Ca);sl&&sl.length&&(Ti.parentPlayer=Si(sl)),D.push(Ti)}}else Gr(vi,xo.fromStyles),Ti.onDestroy(()=>Cr(vi,xo.toStyles)),Cp.push(Ti),un.has(vi)&&D.push(Ti)}),Cp.forEach(Zr=>{const vi=V.get(Zr.element);if(vi&&vi.length){const Ti=Si(vi);Zr.setRealPlayer(Ti)}}),D.forEach(Zr=>{Zr.parentPlayer?Zr.syncPlayerEvents(Zr.parentPlayer):Zr.destroy()});for(let Zr=0;Zr!na.destroyed);Ca.length?kd(this,vi,Ca):this.processLeaveNode(vi)}return Ai.length=0,tg.forEach(Zr=>{this.players.push(Zr),Zr.onDone(()=>{Zr.destroy();const vi=this.players.indexOf(Zr);this.players.splice(vi,1)}),Zr.play()}),tg}afterFlush(m){this._flushFns.push(m)}afterFlushAnimationsDone(m){this._whenQuietFns.push(m)}_getPreviousPlayers(m,d,_,D,V){let J=[];if(d){const we=this.playersByQueriedElement.get(m);we&&(J=we)}else{const we=this.playersByElement.get(m);if(we){const Xe=!V||V==Qu;we.forEach(yt=>{yt.queued||!Xe&&yt.triggerName!=D||J.push(yt)})}}return(_||D)&&(J=J.filter(we=>!(_&&_!=we.namespaceId||D&&D!=we.triggerName))),J}_beforeAnimationBuild(m,d,_){const V=d.element,J=d.isRemovalTransition?void 0:m,we=d.isRemovalTransition?void 0:d.triggerName;for(const Xe of d.timelines){const yt=Xe.element,un=yt!==V,_n=pa(_,yt,[]);this._getPreviousPlayers(yt,un,J,we,d.toState).forEach(er=>{const fr=er.getRealPlayer();fr.beforeDestroy&&fr.beforeDestroy(),er.destroy(),_n.push(er)})}Gr(V,d.fromStyles)}_buildAnimation(m,d,_,D,V,J){const we=d.triggerName,Xe=d.element,yt=[],un=new Set,_n=new Set,gr=d.timelines.map(fr=>{const ti=fr.element;un.add(ti);const Ai=ti[Ga];if(Ai&&Ai.removedBeforeQueried)return new Dr.sf(fr.duration,fr.delay);const ko=ti!==Xe,ho=function rc(v){const m=[];return gu(v,m),m}((_.get(ti)||Tf).map(xa=>xa.getRealPlayer())).filter(xa=>!!xa.element&&xa.element===ti),Ea=V.get(ti),ta=J.get(ti),Ou=Nl(this._normalizer,fr.keyframes,Ea,ta),vl=this._buildPlayer(fr,Ou,ho);if(fr.subTimeline&&D&&_n.add(ti),ko){const xa=new am(m,we,ti);xa.setRealPlayer(vl),yt.push(xa)}return vl});yt.forEach(fr=>{pa(this.playersByQueriedElement,fr.element,[]).push(fr),fr.onDone(()=>function Dh(v,m,d){let _=v.get(m);if(_){if(_.length){const D=_.indexOf(d);_.splice(D,1)}0==_.length&&v.delete(m)}return _}(this.playersByQueriedElement,fr.element,fr))}),un.forEach(fr=>ws(fr,nr));const er=Si(gr);return er.onDestroy(()=>{un.forEach(fr=>Fc(fr,nr)),Cr(Xe,d.toStyles)}),_n.forEach(fr=>{pa(D,fr,[]).push(er)}),er}_buildPlayer(m,d,_){return d.length>0?this.driver.animate(m.element,d,m.duration,m.delay,m.easing,_):new Dr.sf(m.duration,m.delay)}}class am{namespaceId;triggerName;element;_player=new Dr.sf;_containsRealPlayer=!1;_queuedCallbacks=new Map;destroyed=!1;parentPlayer=null;markedForDestroy=!1;disabled=!1;queued=!0;totalTime=0;constructor(m,d,_){this.namespaceId=m,this.triggerName=d,this.element=_}setRealPlayer(m){this._containsRealPlayer||(this._player=m,this._queuedCallbacks.forEach((d,_)=>{d.forEach(D=>Ra(m,_,void 0,D))}),this._queuedCallbacks.clear(),this._containsRealPlayer=!0,this.overrideTotalTime(m.totalTime),this.queued=!1)}getRealPlayer(){return this._player}overrideTotalTime(m){this.totalTime=m}syncPlayerEvents(m){const d=this._player;d.triggerCallback&&m.onStart(()=>d.triggerCallback("start")),m.onDone(()=>this.finish()),m.onDestroy(()=>this.destroy())}_queueEvent(m,d){pa(this._queuedCallbacks,m,[]).push(d)}onDone(m){this.queued&&this._queueEvent("done",m),this._player.onDone(m)}onStart(m){this.queued&&this._queueEvent("start",m),this._player.onStart(m)}onDestroy(m){this.queued&&this._queueEvent("destroy",m),this._player.onDestroy(m)}init(){this._player.init()}hasStarted(){return!this.queued&&this._player.hasStarted()}play(){!this.queued&&this._player.play()}pause(){!this.queued&&this._player.pause()}restart(){!this.queued&&this._player.restart()}finish(){this._player.finish()}destroy(){this.destroyed=!0,this._player.destroy()}reset(){!this.queued&&this._player.reset()}setPosition(m){this.queued||this._player.setPosition(m)}getPosition(){return this.queued?0:this._player.getPosition()}triggerCallback(m){const d=this._player;d.triggerCallback&&d.triggerCallback(m)}}function Qo(v){return v&&1===v.nodeType}function Md(v,m){const d=v.style.display;return v.style.display=m??"none",d}function kf(v,m,d,_,D){const V=[];d.forEach(Xe=>V.push(Md(Xe)));const J=[];_.forEach((Xe,yt)=>{const un=new Map;Xe.forEach(_n=>{const gr=m.computeStyle(yt,_n,D);un.set(_n,gr),(!gr||0==gr.length)&&(yt[Ga]=Ad,J.push(yt))}),v.set(yt,un)});let we=0;return d.forEach(Xe=>Md(Xe,V[we++])),J}function Sh(v,m){const d=new Map;if(v.forEach(we=>d.set(we,[])),0==m.length)return d;const D=new Set(m),V=new Map;function J(we){if(!we)return 1;let Xe=V.get(we);if(Xe)return Xe;const yt=we.parentNode;return Xe=d.has(yt)?yt:D.has(yt)?1:J(yt),V.set(we,Xe),Xe}return m.forEach(we=>{const Xe=J(we);1!==Xe&&d.get(Xe).push(we)}),d}function ws(v,m){v.classList?.add(m)}function Fc(v,m){v.classList?.remove(m)}function kd(v,m,d){Si(d).onDone(()=>v.processLeaveNode(m))}function gu(v,m){for(let d=0;dD.add(V)):m.set(v,_),d.delete(v),!0}class ic{_driver;_normalizer;_transitionEngine;_timelineEngine;_triggerCache={};onRemovalComplete=(m,d)=>{};constructor(m,d,_){this._driver=d,this._normalizer=_,this._transitionEngine=new sm(m.body,d,_),this._timelineEngine=new om(m.body,d,_),this._transitionEngine.onRemovalComplete=(D,V)=>this.onRemovalComplete(D,V)}registerTrigger(m,d,_,D,V){const J=m+"-"+D;let we=this._triggerCache[J];if(!we){const Xe=[],un=Vu(this._driver,V,Xe,[]);if(Xe.length)throw function _d(){return new c.wOt(3404,!1)}();we=function pu(v,m,d){return new Fs(v,m,d)}(D,un,this._normalizer),this._triggerCache[J]=we}this._transitionEngine.registerTrigger(d,D,we)}register(m,d){this._transitionEngine.register(m,d)}destroy(m,d){this._transitionEngine.destroy(m,d)}onInsert(m,d,_,D){this._transitionEngine.insertNode(m,d,_,D)}onRemove(m,d,_){this._transitionEngine.removeNode(m,d,_)}disableAnimations(m,d){this._transitionEngine.markElementAsDisabled(m,d)}process(m,d,_,D){if("@"==_.charAt(0)){const[V,J]=vd(_);this._timelineEngine.command(V,d,J,D)}else this._transitionEngine.trigger(m,d,_,D)}listen(m,d,_,D,V){if("@"==_.charAt(0)){const[J,we]=vd(_);return this._timelineEngine.listen(J,d,we,V)}return this._transitionEngine.listen(m,d,_,D,V)}flush(m=-1){this._transitionEngine.flush(m)}get players(){return[...this._transitionEngine.players,...this._timelineEngine.players]}whenRenderingDone(){return this._transitionEngine.whenRenderingDone()}afterFlushAnimationsDone(m){this._transitionEngine.afterFlushAnimationsDone(m)}}let Th=(()=>{class v{_element;_startStyles;_endStyles;static initialStylesByElement=new WeakMap;_state=0;_initialStyles;constructor(d,_,D){this._element=d,this._startStyles=_,this._endStyles=D;let V=v.initialStylesByElement.get(d);V||v.initialStylesByElement.set(d,V=new Map),this._initialStyles=V}start(){this._state<1&&(this._startStyles&&Cr(this._element,this._startStyles,this._initialStyles),this._state=1)}finish(){this.start(),this._state<2&&(Cr(this._element,this._initialStyles),this._endStyles&&(Cr(this._element,this._endStyles),this._endStyles=null),this._state=1)}destroy(){this.finish(),this._state<3&&(v.initialStylesByElement.delete(this._element),this._startStyles&&(Gr(this._element,this._startStyles),this._endStyles=null),this._endStyles&&(Gr(this._element,this._endStyles),this._endStyles=null),Cr(this._element,this._initialStyles),this._state=3)}}return v})();function Mh(v){let m=null;return v.forEach((d,_)=>{(function oc(v){return"display"===v||"position"===v})(_)&&(m=m||new Map,m.set(_,d))}),m}class _u{element;keyframes;options;_specialStyles;_onDoneFns=[];_onStartFns=[];_onDestroyFns=[];_duration;_delay;_initialized=!1;_finished=!1;_started=!1;_destroyed=!1;_finalKeyframe;_originalOnDoneFns=[];_originalOnStartFns=[];domPlayer;time=0;parentPlayer=null;currentSnapshot=new Map;constructor(m,d,_,D){this.element=m,this.keyframes=d,this.options=_,this._specialStyles=D,this._duration=_.duration,this._delay=_.delay||0,this.time=this._duration+this._delay}_onFinish(){this._finished||(this._finished=!0,this._onDoneFns.forEach(m=>m()),this._onDoneFns=[])}init(){this._buildPlayer(),this._preparePlayerBeforeStart()}_buildPlayer(){if(this._initialized)return;this._initialized=!0;const m=this.keyframes;this.domPlayer=this._triggerWebAnimation(this.element,m,this.options),this._finalKeyframe=m.length?m[m.length-1]:new Map;const d=()=>this._onFinish();this.domPlayer.addEventListener("finish",d),this.onDestroy(()=>{this.domPlayer.removeEventListener("finish",d)})}_preparePlayerBeforeStart(){this._delay?this._resetDomPlayerState():this.domPlayer.pause()}_convertKeyframesToObject(m){const d=[];return m.forEach(_=>{d.push(Object.fromEntries(_))}),d}_triggerWebAnimation(m,d,_){return m.animate(this._convertKeyframesToObject(d),_)}onStart(m){this._originalOnStartFns.push(m),this._onStartFns.push(m)}onDone(m){this._originalOnDoneFns.push(m),this._onDoneFns.push(m)}onDestroy(m){this._onDestroyFns.push(m)}play(){this._buildPlayer(),this.hasStarted()||(this._onStartFns.forEach(m=>m()),this._onStartFns=[],this._started=!0,this._specialStyles&&this._specialStyles.start()),this.domPlayer.play()}pause(){this.init(),this.domPlayer.pause()}finish(){this.init(),this._specialStyles&&this._specialStyles.finish(),this._onFinish(),this.domPlayer.finish()}reset(){this._resetDomPlayerState(),this._destroyed=!1,this._finished=!1,this._started=!1,this._onStartFns=this._originalOnStartFns,this._onDoneFns=this._originalOnDoneFns}_resetDomPlayerState(){this.domPlayer&&this.domPlayer.cancel()}restart(){this.reset(),this.play()}hasStarted(){return this._started}destroy(){this._destroyed||(this._destroyed=!0,this._resetDomPlayerState(),this._onFinish(),this._specialStyles&&this._specialStyles.destroy(),this._onDestroyFns.forEach(m=>m()),this._onDestroyFns=[])}setPosition(m){void 0===this.domPlayer&&this.init(),this.domPlayer.currentTime=m*this.time}getPosition(){return+(this.domPlayer.currentTime??0)/this.time}get totalTime(){return this._delay+this._duration}beforeDestroy(){const m=new Map;this.hasStarted()&&this._finalKeyframe.forEach((_,D)=>{"offset"!==D&&m.set(D,this._finished?_:Mo(this.element,D))}),this.currentSnapshot=m}triggerCallback(m){const d="start"===m?this._onStartFns:this._onDoneFns;d.forEach(_=>_()),d.length=0}}class Rd{validateStyleProperty(m){return!0}validateAnimatableStyleProperty(m){return!0}containsElement(m,d){return I(m,d)}getParentElement(m){return fh(m)}query(m,d,_){return P(m,d,_)}computeStyle(m,d,_){return Mo(m,d)}animate(m,d,_,D,V,J=[]){const Xe={duration:_,delay:D,fill:0==D?"both":"forwards"};V&&(Xe.easing=V);const yt=new Map,un=J.filter(er=>er instanceof _u);(function jr(v,m){return 0===v||0===m})(_,D)&&un.forEach(er=>{er.currentSnapshot.forEach((fr,ti)=>yt.set(ti,fr))});let _n=function Ir(v){return v.length?v[0]instanceof Map?v:v.map(m=>new Map(Object.entries(m))):[]}(d).map(er=>new Map(er));_n=function Hi(v,m,d){if(d.size&&m.length){let _=m[0],D=[];if(d.forEach((V,J)=>{_.has(J)||D.push(J),_.set(J,V)}),D.length)for(let V=1;VJ.set(we,Mo(v,we)))}}return m}(m,_n,yt);const gr=function Ec(v,m){let d=null,_=null;return Array.isArray(m)&&m.length?(d=Mh(m[0]),m.length>1&&(_=Mh(m[m.length-1]))):m instanceof Map&&(d=Mh(m)),d||_?new Th(v,d,_):null}(m,_n);return new _u(m,_n,Xe,gr)}}const Zu="@.disabled";class kh{namespaceId;delegate;engine;_onDestroy;\u0275type=0;constructor(m,d,_,D){this.namespaceId=m,this.delegate=d,this.engine=_,this._onDestroy=D}get data(){return this.delegate.data}destroyNode(m){this.delegate.destroyNode?.(m)}destroy(){this.engine.destroy(this.namespaceId,this.delegate),this.engine.afterFlushAnimationsDone(()=>{queueMicrotask(()=>{this.delegate.destroy()})}),this._onDestroy?.()}createElement(m,d){return this.delegate.createElement(m,d)}createComment(m){return this.delegate.createComment(m)}createText(m){return this.delegate.createText(m)}appendChild(m,d){this.delegate.appendChild(m,d),this.engine.onInsert(this.namespaceId,d,m,!1)}insertBefore(m,d,_,D=!0){this.delegate.insertBefore(m,d,_),this.engine.onInsert(this.namespaceId,d,m,D)}removeChild(m,d,_){this.parentNode(d)&&this.engine.onRemove(this.namespaceId,d,this.delegate)}selectRootElement(m,d){return this.delegate.selectRootElement(m,d)}parentNode(m){return this.delegate.parentNode(m)}nextSibling(m){return this.delegate.nextSibling(m)}setAttribute(m,d,_,D){this.delegate.setAttribute(m,d,_,D)}removeAttribute(m,d,_){this.delegate.removeAttribute(m,d,_)}addClass(m,d){this.delegate.addClass(m,d)}removeClass(m,d){this.delegate.removeClass(m,d)}setStyle(m,d,_,D){this.delegate.setStyle(m,d,_,D)}removeStyle(m,d,_){this.delegate.removeStyle(m,d,_)}setProperty(m,d,_){"@"==d.charAt(0)&&d==Zu?this.disableAnimations(m,!!_):this.delegate.setProperty(m,d,_)}setValue(m,d){this.delegate.setValue(m,d)}listen(m,d,_){return this.delegate.listen(m,d,_)}disableAnimations(m,d){this.engine.disableAnimations(m,d)}}class os extends kh{factory;constructor(m,d,_,D,V){super(d,_,D,V),this.factory=m,this.namespaceId=d}setProperty(m,d,_){"@"==d.charAt(0)?"."==d.charAt(1)&&d==Zu?this.disableAnimations(m,_=void 0===_||!!_):this.engine.process(this.namespaceId,m,d.slice(1),_):this.delegate.setProperty(m,d,_)}listen(m,d,_){if("@"==d.charAt(0)){const D=function Of(v){switch(v){case"body":return document.body;case"document":return document;case"window":return window;default:return v}}(m);let V=d.slice(1),J="";return"@"!=V.charAt(0)&&([V,J]=function Ih(v){const m=v.indexOf(".");return[v.substring(0,m),v.slice(m+1)]}(V)),this.engine.listen(this.namespaceId,D,V,J,we=>{this.factory.scheduleListenerCallback(we._data||-1,_,we)})}return this.delegate.listen(m,d,_)}}class um{delegate;engine;_zone;_currentId=0;_microtaskId=1;_animationCallbacksBuffer=[];_rendererCache=new Map;_cdRecurDepth=0;constructor(m,d,_){this.delegate=m,this.engine=d,this._zone=_,d.onRemovalComplete=(D,V)=>{V?.removeChild(null,D)}}createRenderer(m,d){const D=this.delegate.createRenderer(m,d);if(!m||!d?.data?.animation){const yt=this._rendererCache;let un=yt.get(D);return un||(un=new kh("",D,this.engine,()=>yt.delete(D)),yt.set(D,un)),un}const V=d.id,J=d.id+"-"+this._currentId;this._currentId++,this.engine.register(J,m);const we=yt=>{Array.isArray(yt)?yt.forEach(we):this.engine.registerTrigger(V,J,m,yt.name,yt)};return d.data.animation.forEach(we),new os(this,J,D,this.engine)}begin(){this._cdRecurDepth++,this.delegate.begin&&this.delegate.begin()}_scheduleCountTask(){queueMicrotask(()=>{this._microtaskId++})}scheduleListenerCallback(m,d,_){if(m>=0&&md(_));const D=this._animationCallbacksBuffer;0==D.length&&queueMicrotask(()=>{this._zone.run(()=>{D.forEach(V=>{const[J,we]=V;J(we)}),this._animationCallbacksBuffer=[]})}),D.push([d,_])}end(){this._cdRecurDepth--,0==this._cdRecurDepth&&this._zone.runOutsideAngular(()=>{this._scheduleCountTask(),this.engine.flush(this._microtaskId)}),this.delegate.end&&this.delegate.end()}whenRenderingDone(){return this.engine.whenRenderingDone()}}const vu=[{provide:je,useFactory:function Oh(){return new qs}},{provide:ic,useClass:(()=>{class v extends ic{constructor(d,_,D){super(d,_,D)}ngOnDestroy(){this.flush()}static \u0275fac=function(_){return new(_||v)(c.KVO(at.qQ),c.KVO(Ae),c.KVO(je))};static \u0275prov=c.jDH({token:v,factory:v.\u0275fac})}return v})()},{provide:c._9s,useFactory:function Nf(v,m,d){return new um(v,m,d)},deps:[i.B7,ic,c.SKi]}],Rh=[{provide:Ae,useFactory:()=>new Rd},{provide:c.bc$,useValue:"BrowserAnimations"},...vu];var qu=r(6381),yu=r(909),Ug=r(3569),tl=r(8447),Pf=r(850);const bu=new S.c(Pf.l);var wu=r(7509),Dc=r(1787),Os=r(7947),Nh=r(1642),Nd=r(1126),Ff=r(7225),Ju=r(5351);const ed={connector:()=>new tl.B};function Lh(v,m=ed){const{connector:d}=m;return(0,Ju.N)((_,D)=>{const V=d();(0,Ff.Tg)(v(function hm(v){return new S.c(m=>v.subscribe(m))}(V))).subscribe(D),D.add(_.subscribe(V))})}var Eu=r(2040);const sc="Service workers are disabled or not supported by this browser";class xu{serviceWorker;worker;registration;events;constructor(m){if(this.serviceWorker=m,m){const _=(0,yu.R)(m,"controllerchange").pipe((0,Os.T)(()=>m.controller)),D=(0,qu.v)(()=>(0,O.of)(m.controller)),V=(0,Ug.x)(D,_);this.worker=V.pipe((0,dt.p)(un=>!!un)),this.registration=this.worker.pipe((0,se.n)(()=>m.getRegistration()));const yt=(0,yu.R)(m,"message").pipe((0,Os.T)(un=>un.data)).pipe((0,dt.p)(un=>un&&un.type)).pipe(function Bc(v){return v?m=>Lh(v)(m):m=>function td(v,m){const d=(0,Nd.T)(v)?v:()=>v;return(0,Nd.T)(m)?Lh(m,{connector:d}):_=>new Nh.G(_,d)}(new tl.B)(m)}());yt.connect(),this.events=yt}else this.worker=this.events=this.registration=function nd(v){return(0,qu.v)(()=>(0,T.$)(new Error(v)))}(sc)}postMessage(m,d){return this.worker.pipe((0,M.s)(1),(0,Eu.M)(_=>{_.postMessage({action:m,...d})})).toPromise().then(()=>{})}postMessageWithOperation(m,d,_){const D=this.waitForOperationCompleted(_),V=this.postMessage(m,d);return Promise.all([V,D]).then(([,J])=>J)}generateNonce(){return Math.round(1e7*Math.random())}eventsOfType(m){let d;return d="string"==typeof m?_=>_.type===m:_=>m.includes(_.type),this.events.pipe((0,dt.p)(d))}nextEventOfType(m){return this.eventsOfType(m).pipe((0,M.s)(1))}waitForOperationCompleted(m){return this.eventsOfType("OPERATION_COMPLETED").pipe((0,dt.p)(d=>d.nonce===m),(0,M.s)(1),(0,Os.T)(d=>{if(void 0!==d.result)return d.result;throw new Error(d.error)})).toPromise()}get isEnabled(){return!!this.serviceWorker}}let Bf=(()=>{class v{sw;messages;notificationClicks;subscription;get isEnabled(){return this.sw.isEnabled}pushManager=null;subscriptionChanges=new tl.B;constructor(d){if(this.sw=d,!d.isEnabled)return this.messages=bu,this.notificationClicks=bu,void(this.subscription=bu);this.messages=this.sw.eventsOfType("PUSH").pipe((0,Os.T)(D=>D.data)),this.notificationClicks=this.sw.eventsOfType("NOTIFICATION_CLICK").pipe((0,Os.T)(D=>D.data)),this.pushManager=this.sw.registration.pipe((0,Os.T)(D=>D.pushManager));const _=this.pushManager.pipe((0,se.n)(D=>D.getSubscription()));this.subscription=(0,wu.h)(_,this.subscriptionChanges)}requestSubscription(d){if(!this.sw.isEnabled||null===this.pushManager)return Promise.reject(new Error(sc));const _={userVisibleOnly:!0};let D=this.decodeBase64(d.serverPublicKey.replace(/_/g,"/").replace(/-/g,"+")),V=new Uint8Array(new ArrayBuffer(D.length));for(let J=0;JJ.subscribe(_)),(0,M.s)(1)).toPromise().then(J=>(this.subscriptionChanges.next(J),J))}unsubscribe(){return this.sw.isEnabled?this.subscription.pipe((0,M.s)(1),(0,se.n)(_=>{if(null===_)throw new Error("Not subscribed to push notifications.");return _.unsubscribe().then(D=>{if(!D)throw new Error("Unsubscribe failed!");this.subscriptionChanges.next(null)})})).toPromise():Promise.reject(new Error(sc))}decodeBase64(d){return atob(d)}static \u0275fac=function(_){return new(_||v)(c.KVO(xu))};static \u0275prov=c.jDH({token:v,factory:v.\u0275fac})}return v})(),Ld=(()=>{class v{sw;versionUpdates;unrecoverable;get isEnabled(){return this.sw.isEnabled}constructor(d){if(this.sw=d,!d.isEnabled)return this.versionUpdates=bu,void(this.unrecoverable=bu);this.versionUpdates=this.sw.eventsOfType(["VERSION_DETECTED","VERSION_INSTALLATION_FAILED","VERSION_READY","NO_NEW_VERSION_DETECTED"]),this.unrecoverable=this.sw.eventsOfType("UNRECOVERABLE_STATE")}checkForUpdate(){if(!this.sw.isEnabled)return Promise.reject(new Error(sc));const d=this.sw.generateNonce();return this.sw.postMessageWithOperation("CHECK_FOR_UPDATES",{nonce:d},d)}activateUpdate(){if(!this.sw.isEnabled)return Promise.reject(new Error(sc));const d=this.sw.generateNonce();return this.sw.postMessageWithOperation("ACTIVATE_UPDATE",{nonce:d},d)}static \u0275fac=function(_){return new(_||v)(c.KVO(xu))};static \u0275prov=c.jDH({token:v,factory:v.\u0275fac})}return v})();const Ph=new c.nKC("");function Fh(v,m,d,_){return()=>{if(!(0,at.UE)(_)||!("serviceWorker"in navigator)||!1===d.enabled)return;const D=v.get(c.SKi),V=v.get(c.o8S);let J;if(D.runOutsideAngular(()=>{const we=navigator.serviceWorker,Xe=()=>we.controller?.postMessage({action:"INITIALIZE"});we.addEventListener("controllerchange",Xe),V.onDestroy(()=>{we.removeEventListener("controllerchange",Xe)})}),"function"==typeof d.registrationStrategy)J=d.registrationStrategy();else{const[we,...Xe]=(d.registrationStrategy||"registerWhenStable:30000").split(":");switch(we){case"registerImmediately":J=(0,O.of)(null);break;case"registerWithDelay":J=Uf(+Xe[0]||0);break;case"registerWhenStable":const yt=(0,Dc.H)(v.get(c.o8S).whenStable());J=Xe[0]?(0,wu.h)(yt,Uf(+Xe[0])):yt;break;default:throw new Error(`Unknown ServiceWorker registration strategy: ${d.registrationStrategy}`)}}D.runOutsideAngular(()=>J.pipe((0,M.s)(1)).subscribe(()=>navigator.serviceWorker.register(m,{scope:d.scope}).catch(we=>console.error("Service worker registration failed with:",we))))}}function Uf(v){return(0,O.of)(null).pipe((0,pe.c)(v))}function $f(v,m){return new xu((0,at.UE)(m)&&!1!==v.enabled?navigator.serviceWorker:void 0)}class va{enabled;scope;registrationStrategy}var Uc=r(2653),jg=r(5903),fm=r(7178),ya=r(8249),ac=r(6627),Uh=r(6564);function id(v){return v&&v.constructor&&"function"==typeof v.constructor.isBuffer&&v.constructor.isBuffer(v)}function jf(v){return v}function $h(v,m){const d=(m=m||{}).delimiter||".",_=m.maxDepth,D=m.transformKey||jf,V={};return function J(we,Xe,yt){yt=yt||1,Object.keys(we).forEach(function(un){const _n=we[un],gr=m.safe&&Array.isArray(_n),er=Object.prototype.toString.call(_n),fr=id(_n),ti="[object Object]"===er||"[object Array]"===er,Ai=Xe?Xe+d+D(un):D(un);if(!gr&&!fr&&ti&&Object.keys(_n).length&&(!m.maxDepth||yt<_))return J(_n,Ai,yt+1);V[Ai]=_n})}(v),V}function Pd(v,m){const d=(m=m||{}).delimiter||".",_=m.overwrite||!1,D=m.transformKey||jf,V={};if(id(v)||"[object Object]"!==Object.prototype.toString.call(v))return v;function we(un){const _n=Number(un);return isNaN(_n)||-1!==un.indexOf(".")||m.object?un:_n}return v=Object.keys(v).reduce(function(un,_n){const gr=Object.prototype.toString.call(v[_n]);return"[object Object]"!==gr&&"[object Array]"!==gr||function yt(un){const _n=Object.prototype.toString.call(un);return!un||("[object Array]"===_n?!un.length:"[object Object]"===_n?!Object.keys(un).length:void 0)}(v[_n])?(un[_n]=v[_n],un):function Xe(un,_n,gr){return Object.keys(gr).reduce(function(er,fr){return er[un+d+fr]=gr[fr],er},_n)}(_n,un,$h(v[_n],m))},{}),Object.keys(v).forEach(function(un){const _n=un.split(d).map(D);let gr=we(_n.shift()),er=we(_n[0]),fr=V;for(;void 0!==er;){if("__proto__"===gr)return;const ti=Object.prototype.toString.call(fr[gr]),Ai="[object Object]"===ti||"[object Array]"===ti;if(!_&&!Ai&&typeof fr[gr]<"u")return;(_&&!Ai||!_&&null==fr[gr])&&(fr[gr]="number"!=typeof er||m.object?{}:[]),fr=fr[gr],_n.length>0&&(gr=we(_n.shift()),er=we(_n[0]))}fr[gr]=Pd(v[un],m)}),V}class Vf{translations;constructor(m){this.translations=m}getTranslation(m){return(0,O.of)(this.translations.get(m)||{})}}const Hf=new c.nKC("TRANSLOCO_LOADER");function jh(v,m){return v&&(Object.prototype.hasOwnProperty.call(v,m)?v[m]:m.split(".").reduce((d,_)=>d?.[_],v))}function Wf(v){return v?Array.isArray(v)?v.length:od(v)?Object.keys(v).length:v?v.length:0:0}function lc(v){return"string"==typeof v}function od(v){return!!v&&"object"==typeof v&&!Array.isArray(v)}function Cu(v){return null==v}function Hh(v){return!1===Cu(v)}function Wh(v){return v&&"string"==typeof v.scope}function zh(v){return $h(v,{safe:!0})}const $c=new c.nKC("TRANSLOCO_CONFIG",{providedIn:"root",factory:()=>jc}),jc={defaultLang:"en",reRenderOnLangChange:!1,prodMode:!1,failedRetries:2,fallbackLang:[],availableLangs:[],missingHandler:{logMissingKey:!0,useFallbackTranslation:!1,allowEmpty:!1},flatten:{aot:!1},interpolation:["{{","}}"]};function Yf(v={}){return{...jc,...v,missingHandler:{...jc.missingHandler,...v.missingHandler},flatten:{...jc.flatten,...v.flatten}}}const Kh=new c.nKC("TRANSLOCO_TRANSPILER");let Qf=(()=>{class v{interpolationMatcher;constructor(d){this.interpolationMatcher=function Gh(v){const[m,d]=v.interpolation;return new RegExp(`${m}(.*?)${d}`,"g")}(d??jc)}transpile(d,_={},D,V){return lc(d)?d.replace(this.interpolationMatcher,(J,we)=>(we=we.trim(),Hh(_[we])?_[we]:Hh(D[we])?this.transpile(D[we],_,D,V):"")):(_&&(od(d)?d=this.handleObject(d,_,D,V):Array.isArray(d)&&(d=this.handleArray(d,_,D,V))),d)}handleObject(d,_={},D,V){let J=d;return Object.keys(_).forEach(we=>{const Xe=jh(J,we),yt=jh(_,we),un=this.transpile(Xe,yt,D,V);J=function pm(v,m,d){v={...v};const _=m.split("."),D=_.length-1;return _.reduce((V,J,we)=>(V[J]=we===D?d:Array.isArray(V[J])?V[J].slice():{...V[J]},V&&V[J]),v),v}(J,we,un)}),J}handleArray(d,_={},D,V){return d.map(J=>this.transpile(J,_,D,V))}static \u0275fac=function(_){return new(_||v)(c.KVO($c,8))};static \u0275prov=c.jDH({token:v,factory:v.\u0275fac})}return v})();const nl=new c.nKC("TRANSLOCO_MISSING_HANDLER");let Du=(()=>{class v{handle(d,_){return _.missingHandler.logMissingKey&&!_.prodMode&&console.warn(`%c Missing translation for '${d}'`,"font-size: 12px; color: red"),d}static \u0275fac=function(_){return new(_||v)};static \u0275prov=c.jDH({token:v,factory:v.\u0275fac})}return v})();const Yh=new c.nKC("TRANSLOCO_INTERCEPTOR");let sd=(()=>{class v{preSaveTranslation(d){return d}preSaveTranslationKey(d,_){return _}static \u0275fac=function(_){return new(_||v)};static \u0275prov=c.jDH({token:v,factory:v.\u0275fac})}return v})();const b=new c.nKC("TRANSLOCO_FALLBACK_STRATEGY");let nn,E=(()=>{class v{userConfig;constructor(d){this.userConfig=d}getNextLangs(){const d=this.userConfig.fallbackLang;if(!d)throw new Error("When using the default fallback, a fallback language must be provided in the config!");return Array.isArray(d)?d:[d]}static \u0275fac=function(_){return new(_||v)(c.KVO($c))};static \u0275prov=c.jDH({token:v,factory:v.\u0275fac})}return v})();function A(v){if(!v)return"";const m=v.split("/");return m.pop(),m.join("/")}function j(v){return v?v.split("/").pop():""}function wt(v){return{scope:A(v)||null,langName:j(v)}}function Pt(v){const{path:m,inlineLoader:d,mainLoader:_,data:D}=v;if(d){if(!1===function Kf(v){return"function"==typeof v}(d[m]))throw`You're using an inline loader but didn't provide a loader for ${m}`;return d[m]().then(J=>J.default?J.default:J)}return _.getTranslation(m,D)}let Yt=(()=>{class v{loader;parser;missingHandler;interceptor;fallbackStrategy;langChanges$;subscription=null;translations=new Map;cache=new Map;firstFallbackLang;defaultLang="";availableLangs=[];isResolvedMissingOnce=!1;lang;failedLangs=new Set;events=new tl.B;events$=this.events.asObservable();config;constructor(d,_,D,V,J,we){this.loader=d,this.parser=_,this.missingHandler=D,this.interceptor=V,this.fallbackStrategy=we,this.loader||(this.loader=new Vf(this.translations)),nn=this,this.config=JSON.parse(JSON.stringify(J)),this.setAvailableLangs(this.config.availableLangs||[]),this.setFallbackLangForMissingTranslation(this.config),this.setDefaultLang(this.config.defaultLang),this.lang=new Oe.t(this.getDefaultLang()),this.langChanges$=this.lang.asObservable(),this.subscription=this.events$.subscribe(Xe=>{"translationLoadSuccess"===Xe.type&&Xe.wasFailure&&this.setActiveLang(Xe.payload.langName)})}getDefaultLang(){return this.defaultLang}setDefaultLang(d){this.defaultLang=d}getActiveLang(){return this.lang.getValue()}setActiveLang(d){return this.parser.onLangChanged?.(d),this.lang.next(d),this.events.next({type:"langChanged",payload:wt(d)}),this}setAvailableLangs(d){this.availableLangs=d}getAvailableLangs(){return this.availableLangs}load(d,_={}){const D=this.cache.get(d);if(D)return D;let V;const J=this._isLangScoped(d);let we;J&&(we=A(d));const Xe={path:d,mainLoader:this.loader,inlineLoader:_.inlineLoader,data:J?{scope:we}:void 0};if(this.useFallbackTranslation(d)){const un=J?`${we}/${this.firstFallbackLang}`:this.firstFallbackLang,_n=function Lt({mainLoader:v,path:m,data:d,fallbackPath:_,inlineLoader:D}){return(_?[m,_]:[m]).map(J=>{const we=Pt({path:J,mainLoader:v,inlineLoader:D,data:d});return(0,Dc.H)(we).pipe((0,Os.T)(Xe=>({translation:Xe,lang:J})))})}({...Xe,fallbackPath:un});V=(0,Uc.p)(_n)}else{const un=Pt(Xe);V=(0,Dc.H)(un)}const yt=V.pipe((0,jg.L)(this.config.failedRetries),(0,Eu.M)(un=>{Array.isArray(un)?un.forEach(_n=>{this.handleSuccess(_n.lang,_n.translation),_n.lang!==d&&this.cache.set(_n.lang,(0,O.of)({}))}):this.handleSuccess(d,un)}),(0,fm.W)(un=>(this.config.prodMode||console.error(`Error while trying to load "${d}"`,un),this.handleFailure(d,_))),(0,ya.t)(1));return this.cache.set(d,yt),yt}translate(d,_={},D=this.getActiveLang()){if(!d)return d;const{scope:V,resolveLang:J}=this.resolveLangAndScope(D);if(Array.isArray(d))return d.map(yt=>this.translate(V?`${V}.${yt}`:yt,_,J));d=V?`${V}.${d}`:d;const we=this.getTranslation(J),Xe=we[d];return Xe?this.parser.transpile(Xe,_,we,d):this._handleMissingKey(d,Xe,_)}selectTranslate(d,_,D,V=!1){let J;const we=(yt,un)=>this.load(yt,un).pipe((0,Os.T)(()=>V?this.translateObject(d,_,yt):this.translate(d,_,yt)));if(Cu(D))return this.langChanges$.pipe((0,se.n)(yt=>we(yt)));if(function gm(v){return Array.isArray(v)&&v.every(Wh)}(D)||Wh(D)){const yt=Array.isArray(D)?D[0]:D;D=yt.scope,J=function Qe(v,m){return function Gf(v){return v&&od(v.loader)}(v)?function Pe(v,m){return Object.keys(v).reduce((d,_)=>(d[`${m}/${_}`]=v[_],d),{})}(v.loader,m):void 0}(yt,yt.scope)}if(this.isLang(D)||this.isScopeWithLang(D))return we(D);const Xe=D;return this.langChanges$.pipe((0,se.n)(yt=>we(`${Xe}/${yt}`,{inlineLoader:J})))}isScopeWithLang(d){return this.isLang(j(d))}translateObject(d,_={},D=this.getActiveLang()){if(lc(d)||Array.isArray(d)){const{resolveLang:J,scope:we}=this.resolveLangAndScope(D);if(Array.isArray(d))return d.map(un=>this.translateObject(we?`${we}.${un}`:un,_,J));const Xe=this.getTranslation(J),yt=function Xf(v){return Pd(v)}(this.getObjectByKey(Xe,d=we?`${we}.${d}`:d));return function zf(v){return 0===Wf(v)}(yt)?this.translate(d,_,D):this.parser.transpile(yt,_,Xe,d)}const V=[];for(const[J,we]of this.getEntries(d))V.push(this.translateObject(J,we,D));return V}selectTranslateObject(d,_,D){if(lc(d)||Array.isArray(d))return this.selectTranslate(d,_,D,!0);const[[V,J],...we]=this.getEntries(d);return this.selectTranslateObject(V,J,D).pipe((0,Os.T)(Xe=>{const yt=[Xe];for(const[un,_n]of we)yt.push(this.translateObject(un,_n,D));return yt}))}getTranslation(d){if(d){if(this.isLang(d))return this.translations.get(d)||{};{const{scope:_,resolveLang:D}=this.resolveLangAndScope(d),V=this.translations.get(D)||{};return this.getObjectByKey(V,_)}}return this.translations}selectTranslation(d){let _=this.langChanges$;if(d){const D=j(d)!==d;_=this.isLang(d)||D?(0,O.of)(d):this.langChanges$.pipe((0,Os.T)(V=>`${d}/${V}`))}return _.pipe((0,se.n)(D=>this.load(D).pipe((0,Os.T)(()=>this.getTranslation(D)))))}setTranslation(d,_=this.getActiveLang(),D={}){const J={merge:!0,emitChange:!0,...D},we=A(_);let Xe=d;if(we){const er=this.getMappedScope(we);Xe=zh({[er]:d})}const yt=we?j(_):_,un={...J.merge&&this.getTranslation(yt),...Xe},_n=this.config.flatten.aot?un:zh(un),gr=this.interceptor.preSaveTranslation(_n,yt);this.translations.set(yt,gr),J.emitChange&&this.setActiveLang(this.getActiveLang())}setTranslationKey(d,_,D=this.getActiveLang(),V={}){const J=this.interceptor.preSaveTranslationKey(d,_,D);this.setTranslation({[d]:J},D,{...V,merge:!0})}setFallbackLangForMissingTranslation({fallbackLang:d}){const _=Array.isArray(d)?d[0]:d;d&&this.useFallbackTranslation(_)&&(this.firstFallbackLang=_)}_handleMissingKey(d,_,D){if(this.config.missingHandler.allowEmpty&&""===_)return"";if(!this.isResolvedMissingOnce&&this.useFallbackTranslation()){this.isResolvedMissingOnce=!0;const V=this.translate(d,D,this.firstFallbackLang);return this.isResolvedMissingOnce=!1,V}return this.missingHandler.handle(d,this.getMissingHandlerData(),D)}_isLangScoped(d){return-1===this.getAvailableLangsIds().indexOf(d)}isLang(d){return-1!==this.getAvailableLangsIds().indexOf(d)}_loadDependencies(d,_){const D=j(d);return this._isLangScoped(d)&&!this.isLoadedTranslation(D)?(0,ac.z)([this.load(D),this.load(d,{inlineLoader:_})]):this.load(d,{inlineLoader:_})}_completeScopeWithLang(d){return this._isLangScoped(d)&&!this.isLang(j(d))?`${d}/${this.getActiveLang()}`:d}_setScopeAlias(d,_){this.config.scopeMapping||(this.config.scopeMapping={}),this.config.scopeMapping[d]=_}ngOnDestroy(){this.subscription&&(this.subscription.unsubscribe(),this.subscription=null),this.cache.clear()}isLoadedTranslation(d){return Wf(this.getTranslation(d))}getAvailableLangsIds(){return lc(this.getAvailableLangs()[0])?this.getAvailableLangs():this.getAvailableLangs().map(_=>_.id)}getMissingHandlerData(){return{...this.config,activeLang:this.getActiveLang(),availableLangs:this.availableLangs,defaultLang:this.defaultLang}}useFallbackTranslation(d){return this.config.missingHandler.useFallbackTranslation&&d!==this.firstFallbackLang}handleSuccess(d,_){this.setTranslation(_,d,{emitChange:!1}),this.events.next({wasFailure:!!this.failedLangs.size,type:"translationLoadSuccess",payload:wt(d)}),this.failedLangs.forEach(D=>this.cache.delete(D)),this.failedLangs.clear()}handleFailure(d,_){Cu(_.failedCounter)&&(_.failedCounter=0,_.fallbackLangs||(_.fallbackLangs=this.fallbackStrategy.getNextLangs(d)));const D=d.split("/"),J=_.fallbackLangs[_.failedCounter];if(this.failedLangs.add(d),this.cache.has(J))return this.handleSuccess(J,this.getTranslation(J)),Uh.w;if(!J||J===D[D.length-1]){let yt="Unable to load translation and all the fallback languages";throw D.length>1&&(yt+=", did you misspelled the scope name?"),new Error(yt)}let Xe=J;return D.length>1&&(D[D.length-1]=J,Xe=D.join("/")),_.failedCounter++,this.events.next({type:"translationLoadFailure",payload:wt(d)}),this.load(Xe,_)}getMappedScope(d){const{scopeMapping:_={}}=this.config;return _[d]||function Bd(v){return v.replace(/(?:^\w|[A-Z]|\b\w)/g,(m,d)=>0==d?m.toLowerCase():m.toUpperCase()).replace(/\s+|_|-|\//g,"")}(d)}resolveLangAndScope(d){let D,_=d;if(this._isLangScoped(d)){const V=j(d),J=this.isLang(V);_=J?V:this.getActiveLang(),D=this.getMappedScope(J?A(d):d)}return{scope:D,resolveLang:_}}getObjectByKey(d,_){const D={},V=`${_}.`;for(const J in d)J.startsWith(V)&&(D[J.replace(V,"")]=d[J]);return D}getEntries(d){return d instanceof Map?d.entries():Object.entries(d)}static \u0275fac=function(_){return new(_||v)(c.KVO(Hf,8),c.KVO(Kh),c.KVO(nl),c.KVO(Yh),c.KVO($c),c.KVO(b))};static \u0275prov=c.jDH({token:v,factory:v.\u0275fac,providedIn:"root"})}return v})();function hr(v){return(0,c.EmA)([{provide:Kh,useClass:v,deps:[$c]}])}function Yr(v){return(0,c.EmA)([{provide:b,useClass:v,deps:[$c]}])}function mi(v){return(0,c.EmA)([{provide:nl,useClass:v}])}function yr(v){return(0,c.EmA)([{provide:Yh,useClass:v}])}new c.nKC("TRANSLOCO_LANG"),new c.nKC("TRANSLOCO_LOADING_TEMPLATE"),new c.nKC("TRANSLOCO_SCOPE"),new c.nKC("TRANSLOCO_TEST_LANGS - Available testing languages"),new c.nKC("TRANSLOCO_TEST_OPTIONS - Testing options");var Xa=r(7838);let wa=(()=>{class v{constructor(){this._httpClient=(0,c.WQX)(re.Qq),this._navigation=new Xa.m(1)}get navigation$(){return this._navigation.asObservable()}get(){return this._httpClient.get("api/navigation").pipe((0,Eu.M)(d=>{this._navigation.next(d)}))}static{this.\u0275fac=function(_){return new(_||v)}}static{this.\u0275prov=c.jDH({token:v,factory:v.\u0275fac,providedIn:"root"})}}return v})(),Vc=(()=>{class v{constructor(d){this._httpClient=d,this._chat=new Oe.t(null),this._chats=new Oe.t(null)}get chat$(){return this._chat.asObservable()}get chats$(){return this._chats.asObservable()}getChats(){return this._httpClient.get("api/apps/chat/chats").pipe((0,Eu.M)(d=>{this._chats.next(d)}))}getChatById(d){return this._httpClient.get("api/apps/chat/chat",{params:{id:d}}).pipe((0,Os.T)(_=>(this._chat.next(_),_)),(0,se.n)(_=>_?(0,O.of)(_):(0,T.$)("Could not found chat with id of "+d+"!")))}static{this.\u0275fac=function(_){return new(_||v)(c.KVO(re.Qq))}}static{this.\u0275prov=c.jDH({token:v,factory:v.\u0275fac,providedIn:"root"})}}return v})();const cc=new class Po{constructor(m){this.version=m,this.full=m,this.major=m.split(".")[0],this.minor=m.split(".")[1],this.patch=m.split(".").slice(2).join(".")}}("0.0.12").full;var ea=r(5424),Zo=r(3022),Hc=r(2322);function jd(v,m){if(1&v&&c.nrm(0,"mat-progress-bar",0),2&v){const d=c.XpG();c.Y8G("mode",d.mode)("value",d.progress)}}let Wc=(()=>{class v{constructor(){this._angorLoadingService=(0,c.WQX)(xe),this.autoMode=!0,this.progress=0,this.show=!1,this._unsubscribeAll=new tl.B}ngOnChanges(d){"autoMode"in d&&this._angorLoadingService.setAutoMode((0,Zo.he)(d.autoMode.currentValue))}ngOnInit(){this._angorLoadingService.mode$.pipe((0,ea.Q)(this._unsubscribeAll)).subscribe(d=>{this.mode=d}),this._angorLoadingService.progress$.pipe((0,ea.Q)(this._unsubscribeAll)).subscribe(d=>{this.progress=d}),this._angorLoadingService.show$.pipe((0,ea.Q)(this._unsubscribeAll)).subscribe(d=>{this.show=d})}ngOnDestroy(){this._unsubscribeAll.next(null),this._unsubscribeAll.complete()}static{this.\u0275fac=function(_){return new(_||v)}}static{this.\u0275cmp=c.VBU({type:v,selectors:[["angor-loading-bar"]],inputs:{autoMode:"autoMode"},exportAs:["angorLoadingBar"],features:[c.OA$],decls:1,vars:1,consts:[[3,"mode","value"]],template:function(_,D){1&_&&c.DNE(0,jd,1,2,"mat-progress-bar",0),2&_&&c.vxM(D.show?0:-1)},dependencies:[Hc.PO,Hc.HM],styles:["angor-loading-bar{position:fixed;top:0;z-index:999;width:100%;height:6px}\n"],encapsulation:2})}}return v})();function Qh(v,m){1&v&&c.nrm(0,"router-outlet")}let Zf=(()=>{class v{constructor(){this._unsubscribeAll=new tl.B}ngOnDestroy(){this._unsubscribeAll.next(null),this._unsubscribeAll.complete()}static{this.\u0275fac=function(_){return new(_||v)}}static{this.\u0275cmp=c.VBU({type:v,selectors:[["empty-layout"]],decls:4,vars:1,consts:[[1,"flex","w-full","flex-auto","flex-col"],[1,"flex","flex-auto","flex-col"]],template:function(_,D){1&_&&(c.nrm(0,"angor-loading-bar"),c.j41(1,"div",0)(2,"div",1),c.DNE(3,Qh,1,0,"router-outlet"),c.k0s()()),2&_&&(c.R7$(3),c.vxM(3))},dependencies:[Wc,a.n3],encapsulation:2})}}return v})();var _l=r(9471),il=r(3904),zc=r(7712);function vm(v,m){1&v&&c.nrm(0,"mat-icon",3)}let Ac=(()=>{class v{constructor(){this._document=(0,c.WQX)(at.qQ)}toggleFullscreen(){this._document.fullscreenEnabled?this._document.fullscreenElement?this._document.exitFullscreen():this._document.documentElement.requestFullscreen().catch(()=>{console.error("Entering fullscreen mode failed.")}):console.log("Fullscreen is not available in this browser.")}static{this.\u0275fac=function(_){return new(_||v)}}static{this.\u0275cmp=c.VBU({type:v,selectors:[["angor-fullscreen"]],inputs:{iconTpl:"iconTpl",tooltip:"tooltip"},exportAs:["angorFullscreen"],decls:4,vars:2,consts:[["defaultIconTpl",""],["mat-icon-button","",3,"click","matTooltip"],[3,"ngTemplateOutlet"],["svgIcon","heroicons_outline:arrows-pointing-out"]],template:function(_,D){if(1&_){const V=c.RV6();c.j41(0,"button",1),c.bIt("click",function(){return c.eBV(V),c.Njj(D.toggleFullscreen())}),c.eu8(1,2),c.k0s(),c.DNE(2,vm,1,0,"ng-template",null,0,c.C5r)}if(2&_){const V=c.sdS(3);c.Y8G("matTooltip",D.tooltip||"Toggle Fullscreen"),c.R7$(),c.Y8G("ngTemplateOutlet",D.iconTpl||V)}},dependencies:[_l.Hl,_l.iY,zc.uc,zc.oV,at.T3,il.m_,il.An],encapsulation:2,changeDetection:0})}}return v})();var Zh=r(3871),ym=r(6192),qh=r(3125);let qf=(()=>{class v{constructor(d){this.relayService=d,this.notificationSubject=new Oe.t([]),this.notificationCount=new Oe.t(0),this.lastNotificationTimestamp=null,this.initializeNotificationData()}initializeNotificationData(){this.notificationCount.next(this.loadCountFromLocalStorage()),this.lastNotificationTimestamp=this.loadTimestampFromLocalStorage()}loadCountFromLocalStorage(){const d=localStorage.getItem("notificationCount");return d?parseInt(d,10):0}loadTimestampFromLocalStorage(){const d=localStorage.getItem("lastNotificationTimestamp");return d?parseInt(d,10):null}saveNotificationData(d,_){localStorage.setItem("notificationCount",d.toString()),localStorage.setItem("lastNotificationTimestamp",_.toString())}getNotificationObservable(){return this.notificationSubject.asObservable()}getNotificationCount(){return this.notificationCount.asObservable()}loadFilterPreferences(){const d=localStorage.getItem("notificationSettings");return d?JSON.parse(d):[1,3,4,7,9735]}subscribeToNotifications(d){var _=this;return(0,w.A)(function*(){yield _.relayService.ensureConnectedRelays();const D=_.relayService.getPool(),V=_.relayService.getConnectedRelays();if(0===V.length)throw new Error("No connected relays");const J=_.loadTimestampFromLocalStorage(),we=_.loadFilterPreferences();0===we.length&&we.push(1,3,4,7,9735);const Xe={kinds:we,"#p":[d],limit:50,since:J||void 0};return new Promise(yt=>{D.subscribeMany(V,[Xe],{onevent:_n=>_.handleNotificationEvent(_n,d),oneose(){yt()}})})})()}handleNotificationEvent(d,_){if(this.isNotificationEvent(d,_)){const V=new Date(1e3*d.created_at);let J="",we="",Xe="";switch(d.kind){case 1:J="Mention",we="Mentioned you in an event.",Xe="heroicons_outline:at-symbol";break;case 4:J="Private Message",we="Sent a private message.",Xe="heroicons_outline:envelope-open";break;case 9735:J="Zap",we="Received a zap event.",Xe="feather:zap";break;case 3:J="New Follower",we="You have a new follower.",Xe="heroicons_outline:user-plus";break;case 7:J="New Like",we="You have a new Like.",Xe="heroicons_outline:hand-thumb-up";break;default:J="Notification",Xe="heroicons_outline:bell"}const _n=[{id:d.id,icon:Xe,title:J,description:we,time:V,kind:d.kind,read:!1},...this.notificationSubject.value].slice(0,50);this.notificationSubject.next(_n),this.incrementNotificationCount(d.created_at)}}incrementNotificationCount(d){const _=this.notificationCount.value+1;this.notificationCount.next(_),this.saveNotificationData(_,d)}markAllAsRead(){const d=this.notificationSubject.value.map(D=>({...D,read:!0}));this.notificationSubject.next(d),this.notificationCount.next(0);const _=Math.floor(Date.now()/1e3);this.saveNotificationData(0,_)}isNotificationEvent(d,_){return d.tags.some(D=>"p"===D[0]&&D[1]===_)}static{this.\u0275fac=function(_){return new(_||v)(c.KVO(qh.b))}}static{this.\u0275prov=c.jDH({token:v,factory:v.\u0275fac,providedIn:"root"})}}return v})();var Au=r(9666),Vd=r(8078);const Jh=["notificationsOrigin"],La=["notificationsPanel"],sy=v=>({unread:v}),Es=(v,m)=>({"bg-gray-400 dark:bg-gray-500 sm:opacity-0 sm:group-hover:opacity-100":v,"bg-primary":m});function ay(v,m){if(1&v&&(c.j41(0,"span",4)(1,"span",6),c.EFF(2),c.k0s()()),2&v){const d=c.XpG();c.R7$(2),c.SpI(" ",d.unreadCount," ")}}function ly(v,m){1&v&&c.eu8(0)}function bm(v,m){if(1&v&&(c.j41(0,"a",23),c.DNE(1,ly,1,0,"ng-container",25),c.k0s()),2&v){const d=c.XpG(2).$implicit,_=c.sdS(9);c.Y8G("href",d.link,c.B4B),c.R7$(),c.Y8G("ngTemplateOutlet",_)}}function Vg(v,m){1&v&&c.eu8(0)}function Hg(v,m){if(1&v&&(c.j41(0,"a",24),c.DNE(1,Vg,1,0,"ng-container",25),c.k0s()),2&v){const d=c.XpG(2).$implicit,_=c.sdS(9);c.Y8G("routerLink",d.link),c.R7$(),c.Y8G("ngTemplateOutlet",_)}}function cy(v,m){if(1&v&&c.DNE(0,bm,2,2,"a",23)(1,Hg,2,2,"a",24),2&v){const d=c.XpG().$implicit;c.vxM(d.useRouter?-1:0),c.R7$(),c.vxM(d.useRouter?1:-1)}}function Tw(v,m){1&v&&c.eu8(0)}function Wg(v,m){if(1&v&&(c.j41(0,"div",17),c.DNE(1,Tw,1,0,"ng-container",25),c.k0s()),2&v){c.XpG();const d=c.sdS(9);c.R7$(),c.Y8G("ngTemplateOutlet",d)}}function uy(v,m){if(1&v&&(c.j41(0,"div",26),c.nrm(1,"mat-icon",32),c.k0s()),2&v){const d=c.XpG(2).$implicit;c.R7$(),c.Y8G("svgIcon",d.icon)}}function Jf(v,m){if(1&v&&c.nrm(0,"img",27),2&v){const d=c.XpG(2).$implicit;c.Y8G("src",d.image,c.B4B)("alt","Notification image")}}function wm(v,m){if(1&v&&c.nrm(0,"div",29),2&v){const d=c.XpG(2).$implicit;c.Y8G("innerHTML",d.title,c.npT)}}function Em(v,m){if(1&v&&c.nrm(0,"div",30),2&v){const d=c.XpG(2).$implicit;c.Y8G("innerHTML",d.description,c.npT)}}function Hd(v,m){if(1&v&&(c.DNE(0,uy,2,1,"div",26)(1,Jf,1,2,"img",27),c.j41(2,"div",28),c.DNE(3,wm,1,1,"div",29)(4,Em,1,1,"div",30),c.j41(5,"div",31),c.EFF(6),c.nI1(7,"date"),c.k0s()()),2&v){const d=c.XpG().$implicit;c.vxM(d.icon&&!d.image?0:-1),c.R7$(),c.vxM(d.image?1:-1),c.R7$(2),c.vxM(d.title?3:-1),c.R7$(),c.vxM(d.description?4:-1),c.R7$(2),c.SpI(" ",c.i5U(7,5,d.time,"MMM dd, h:mm a")," ")}}function ep(v,m){if(1&v){const d=c.RV6();c.j41(0,"div",16),c.DNE(1,cy,2,2)(2,Wg,2,1,"div",17),c.j41(3,"div",18)(4,"button",19),c.bIt("click",function(){const D=c.eBV(d).$implicit,V=c.XpG(2);return c.Njj(V.toggleRead(D))}),c.nrm(5,"span",20),c.k0s(),c.j41(6,"button",21),c.bIt("click",function(){const D=c.eBV(d).$implicit,V=c.XpG(2);return c.Njj(V.delete(D))}),c.nrm(7,"mat-icon",22),c.k0s()()(),c.DNE(8,Hd,8,8,"ng-template",null,2,c.C5r)}if(2&v){const d=m.$implicit;c.Y8G("ngClass",c.eq3(7,sy,!d.read)),c.R7$(),c.vxM(d.link?1:-1),c.R7$(),c.vxM(d.link?-1:2),c.R7$(2),c.Y8G("matTooltip",d.read?"Mark as unread":"Mark as read"),c.R7$(),c.Y8G("ngClass",c.l_i(9,Es,d.read,!d.read)),c.R7$(),c.Y8G("matTooltip","Remove"),c.R7$(),c.Y8G("svgIcon","heroicons_solid:x-mark")}}function tp(v,m){1&v&&(c.j41(0,"div",15)(1,"div",33),c.nrm(2,"mat-icon",34),c.k0s(),c.j41(3,"div",35),c.EFF(4," No notifications "),c.k0s(),c.j41(5,"div",36),c.EFF(6," When you have notifications, they will appear here. "),c.k0s()()),2&v&&(c.R7$(2),c.Y8G("svgIcon","heroicons_outline:bell"))}function Wd(v,m){if(1&v){const d=c.RV6();c.j41(0,"div",7)(1,"div",8)(2,"div",9)(3,"button",3),c.bIt("click",function(){c.eBV(d);const D=c.XpG();return c.Njj(D.closePanel())}),c.nrm(4,"mat-icon",10),c.k0s()(),c.j41(5,"div",11),c.EFF(6,"Notifications"),c.k0s(),c.j41(7,"div",12)(8,"button",13),c.bIt("click",function(){c.eBV(d);const D=c.XpG();return c.Njj(D.markAllAsRead())}),c.nrm(9,"mat-icon",10),c.k0s()()(),c.j41(10,"div",14),c.Z7z(11,ep,10,12,null,null,c.BUC().trackByFn,!0),c.DNE(13,tp,7,1,"div",15),c.k0s()()}if(2&v){const d=c.XpG();c.R7$(4),c.Y8G("svgIcon","heroicons_solid:x-mark"),c.R7$(4),c.Y8G("matTooltip","Mark all as read")("disabled",0===d.unreadCount),c.R7$(),c.Y8G("svgIcon","heroicons_solid:envelope-open"),c.R7$(2),c.Dyx(d.notifications),c.R7$(2),c.vxM(d.notifications&&d.notifications.length?-1:13)}}let np=(()=>{class v{constructor(d,_,D,V,J){this._notificationService=d,this._changeDetectorRef=_,this._overlay=D,this._viewContainerRef=V,this._signerService=J,this.notifications=[],this.unreadCount=0,this._unsubscribeAll=new tl.B}ngOnInit(){const d=this._signerService.getPublicKey();this._notificationService.subscribeToNotifications(d).then(()=>{this._notificationService.getNotificationObservable().pipe((0,ea.Q)(this._unsubscribeAll)).subscribe(_=>{this.notifications=_,this._changeDetectorRef.markForCheck()}),this._notificationService.getNotificationCount().pipe((0,ea.Q)(this._unsubscribeAll)).subscribe(_=>{this.unreadCount=_,this._changeDetectorRef.markForCheck()})})}ngOnDestroy(){this._unsubscribeAll.next(null),this._unsubscribeAll.complete()}openPanel(){!this._notificationsPanel||!this._notificationsOrigin||(this._overlayRef||this._createOverlay(),this._overlayRef.attach(new ym.VA(this._notificationsPanel,this._viewContainerRef)))}closePanel(){this._overlayRef&&this._overlayRef.detach()}markAllAsRead(){this._notificationService.markAllAsRead()}toggleRead(d){d.read=!d.read}trackByFn(d,_){return _.id}_createOverlay(){this._overlayRef=this._overlay.create({hasBackdrop:!0,backdropClass:"angor-backdrop-on-mobile",scrollStrategy:this._overlay.scrollStrategies.block(),positionStrategy:this._overlay.position().flexibleConnectedTo(this._notificationsOrigin._elementRef.nativeElement).withLockedPosition(!0).withPush(!0).withPositions([{originX:"start",originY:"bottom",overlayX:"start",overlayY:"top"},{originX:"start",originY:"top",overlayX:"start",overlayY:"bottom"}])}),this._overlayRef.backdropClick().subscribe(()=>{this._overlayRef.detach()})}static{this.\u0275fac=function(_){return new(_||v)(c.rXU(qf),c.rXU(c.gRc),c.rXU(Au.hJ),c.rXU(c.c1b),c.rXU(Vd.A))}}static{this.\u0275cmp=c.VBU({type:v,selectors:[["notifications"]],viewQuery:function(_,D){if(1&_&&(c.GBs(Jh,5),c.GBs(La,5)),2&_){let V;c.mGM(V=c.lsd())&&(D._notificationsOrigin=V.first),c.mGM(V=c.lsd())&&(D._notificationsPanel=V.first)}},exportAs:["notifications"],decls:6,vars:2,consts:[["notificationsOrigin",""],["notificationsPanel",""],["notificationContent",""],["mat-icon-button","",3,"click"],[1,"absolute","left-0","right-0","top-0","flex","h-3","items-center","justify-center"],[3,"svgIcon"],[1,"ml-4","mt-2.5","flex","h-4","min-w-4","shrink-0","items-center","justify-center","rounded-full","bg-teal-600","px-1","text-xs","font-medium","text-indigo-50"],[1,"fixed","inset-0","flex","flex-col","overflow-hidden","shadow-lg","sm:static","sm:inset-auto","sm:w-90","sm:min-w-90","sm:rounded-2xl"],[1,"flex","shrink-0","items-center","bg-primary","py-4","pl-6","pr-4","text-on-primary"],[1,"-ml-1","mr-3","sm:hidden"],[1,"text-current","icon-size-5",3,"svgIcon"],[1,"text-lg","font-medium","leading-10"],[1,"ml-auto"],["mat-icon-button","",1,"dark:text-white",3,"click","matTooltip","disabled"],[1,"bg-card","relative","flex","flex-auto","flex-col","divide-y","overflow-y-auto","sm:max-h-120"],[1,"flex","flex-auto","flex-col","items-center","justify-center","px-8","py-12","sm:justify-start"],[1,"group","flex","hover:bg-gray-50","dark:hover:bg-black","dark:hover:bg-opacity-5",3,"ngClass"],[1,"flex","flex-auto","py-5","pl-6"],[1,"relative","my-5","ml-2","mr-6","flex","flex-col"],["mat-icon-button","",1,"h-6","min-h-6","w-6",3,"click","matTooltip"],[1,"h-2","w-2","rounded-full",3,"ngClass"],["mat-icon-button","",1,"h-6","min-h-6","w-6","sm:opacity-0","sm:group-hover:opacity-100",3,"click","matTooltip"],[1,"icon-size-4",3,"svgIcon"],[1,"flex","flex-auto","cursor-pointer","py-5","pl-6",3,"href"],[1,"flex","flex-auto","cursor-pointer","py-5","pl-6",3,"routerLink"],[4,"ngTemplateOutlet"],[1,"mr-4","flex","h-8","w-8","shrink-0","items-center","justify-center","rounded-full","bg-gray-100","dark:bg-gray-700"],[1,"mr-4","h-8","w-8","shrink-0","overflow-hidden","rounded-full","object-cover","object-center",3,"src","alt"],[1,"flex","flex-auto","flex-col"],[1,"line-clamp-1","font-semibold",3,"innerHTML"],[1,"line-clamp-2",3,"innerHTML"],[1,"text-secondary","mt-2","text-sm","leading-none"],[1,"icon-size-5",3,"svgIcon"],[1,"flex","h-14","w-14","flex-0","items-center","justify-center","rounded-full","bg-primary-100","dark:bg-primary-600"],[1,"text-primary-700","dark:text-primary-50",3,"svgIcon"],[1,"mt-5","text-2xl","font-semibold","tracking-tight"],[1,"text-secondary","mt-1","w-full","max-w-60","text-center","text-md"]],template:function(_,D){if(1&_){const V=c.RV6();c.j41(0,"button",3,0),c.bIt("click",function(){return c.eBV(V),c.Njj(D.openPanel())}),c.DNE(2,ay,3,1,"span",4),c.nrm(3,"mat-icon",5),c.k0s(),c.DNE(4,Wd,14,5,"ng-template",null,1,c.C5r)}2&_&&(c.R7$(2),c.vxM(D.unreadCount>0?2:-1),c.R7$(),c.Y8G("svgIcon","heroicons_outline:bell"))},dependencies:[_l.Hl,_l.iY,il.m_,il.An,zc.uc,zc.oV,at.YU,at.T3,a.Wk,at.vh],encapsulation:2,changeDetection:0})}}return v})();var xm=r(799),Su=r(936),Cm=r(8108),Kc=r(8559),Dm=r(5710),dy=r(2944),ol=r(5919),zd=r(6520),Mw=r(593);const zg=["panel"],hy=["*"];function Kg(v,m){if(1&v){const d=c.RV6();c.j41(0,"div",1,0),c.bIt("@panelAnimation.done",function(D){c.eBV(d);const V=c.XpG();return c.Njj(V._animationDone.next(D))}),c.SdG(2),c.k0s()}if(2&v){const d=m.id,_=c.XpG();c.HbH(_._classList),c.AVh("mat-mdc-autocomplete-visible",_.showPanel)("mat-mdc-autocomplete-hidden",!_.showPanel)("mat-primary","primary"===_._color)("mat-accent","accent"===_._color)("mat-warn","warn"===_._color),c.Y8G("id",_.id)("@panelAnimation",_.isOpen?"visible":"hidden"),c.BMQ("aria-label",_.ariaLabel||null)("aria-labelledby",_._getPanelAriaLabelledby(d))}}const kw=(0,Dr.hZ)("panelAnimation",[(0,Dr.wk)("void, hidden",(0,Dr.iF)({opacity:0,transform:"scaleY(0.8)"})),(0,Dr.kY)(":enter, hidden => visible",[(0,Dr.Os)([(0,Dr.i0)("0.03s linear",(0,Dr.iF)({opacity:1})),(0,Dr.i0)("0.12s cubic-bezier(0, 0, 0.2, 1)",(0,Dr.iF)({transform:"scaleY(1)"}))])]),(0,Dr.kY)(":leave, visible => hidden",[(0,Dr.i0)("0.075s linear",(0,Dr.iF)({opacity:0}))])]);class Gg{source;option;constructor(m,d){this.source=m,this.option=d}}const Xg=new c.nKC("mat-autocomplete-default-options",{providedIn:"root",factory:function Yg(){return{autoActiveFirstOption:!1,autoSelectActiveOption:!1,hideSingleSelectionIndicator:!1,requireSelection:!1}}});let Tu=(()=>{class v{_changeDetectorRef=(0,c.WQX)(c.gRc);_elementRef=(0,c.WQX)(c.aKT);_defaults=(0,c.WQX)(Xg);_activeOptionChanges=Dm.yU.EMPTY;_animationDone=new c.bkB;_keyManager;showPanel=!1;get isOpen(){return this._isOpen&&this.showPanel}_isOpen=!1;_latestOpeningTrigger;_setColor(d){this._color=d,this._changeDetectorRef.markForCheck()}_color;template;panel;options;optionGroups;ariaLabel;ariaLabelledby;displayWith=null;autoActiveFirstOption;autoSelectActiveOption;requireSelection;panelWidth;disableRipple;optionSelected=new c.bkB;opened=new c.bkB;closed=new c.bkB;optionActivated=new c.bkB;set classList(d){this._classList=d,this._elementRef.nativeElement.className=""}_classList;get hideSingleSelectionIndicator(){return this._hideSingleSelectionIndicator}set hideSingleSelectionIndicator(d){this._hideSingleSelectionIndicator=d,this._syncParentProperties()}_hideSingleSelectionIndicator;_syncParentProperties(){if(this.options)for(const d of this.options)d._changeDetectorRef.markForCheck()}id=(0,c.WQX)(Kc.g7).getId("mat-autocomplete-");inertGroups;constructor(){const d=(0,c.WQX)(Ce.OD);this.inertGroups=d?.SAFARI||!1,this.autoActiveFirstOption=!!this._defaults.autoActiveFirstOption,this.autoSelectActiveOption=!!this._defaults.autoSelectActiveOption,this.requireSelection=!!this._defaults.requireSelection,this._hideSingleSelectionIndicator=this._defaults.hideSingleSelectionIndicator??!1}ngAfterContentInit(){this._keyManager=new Kc.Au(this.options).withWrap().skipPredicate(this._skipPredicate),this._activeOptionChanges=this._keyManager.change.subscribe(d=>{this.isOpen&&this.optionActivated.emit({source:this,option:this.options.toArray()[d]||null})}),this._setVisibility()}ngOnDestroy(){this._keyManager?.destroy(),this._activeOptionChanges.unsubscribe(),this._animationDone.complete()}_setScrollTop(d){this.panel&&(this.panel.nativeElement.scrollTop=d)}_getScrollTop(){return this.panel?this.panel.nativeElement.scrollTop:0}_setVisibility(){this.showPanel=!!this.options.length,this._changeDetectorRef.markForCheck()}_emitSelectEvent(d){const _=new Gg(this,d);this.optionSelected.emit(_)}_getPanelAriaLabelledby(d){return this.ariaLabel?null:this.ariaLabelledby?(d?d+" ":"")+this.ariaLabelledby:d}_skipPredicate(){return!1}static \u0275fac=function(_){return new(_||v)};static \u0275cmp=c.VBU({type:v,selectors:[["mat-autocomplete"]],contentQueries:function(_,D,V){if(1&_&&(c.wni(V,rn.wT,5),c.wni(V,rn.QC,5)),2&_){let J;c.mGM(J=c.lsd())&&(D.options=J),c.mGM(J=c.lsd())&&(D.optionGroups=J)}},viewQuery:function(_,D){if(1&_&&(c.GBs(c.C4Q,7),c.GBs(zg,5)),2&_){let V;c.mGM(V=c.lsd())&&(D.template=V.first),c.mGM(V=c.lsd())&&(D.panel=V.first)}},hostAttrs:[1,"mat-mdc-autocomplete"],inputs:{ariaLabel:[0,"aria-label","ariaLabel"],ariaLabelledby:[0,"aria-labelledby","ariaLabelledby"],displayWith:"displayWith",autoActiveFirstOption:[2,"autoActiveFirstOption","autoActiveFirstOption",c.L39],autoSelectActiveOption:[2,"autoSelectActiveOption","autoSelectActiveOption",c.L39],requireSelection:[2,"requireSelection","requireSelection",c.L39],panelWidth:"panelWidth",disableRipple:[2,"disableRipple","disableRipple",c.L39],classList:[0,"class","classList"],hideSingleSelectionIndicator:[2,"hideSingleSelectionIndicator","hideSingleSelectionIndicator",c.L39]},outputs:{optionSelected:"optionSelected",opened:"opened",closed:"closed",optionActivated:"optionActivated"},exportAs:["matAutocomplete"],features:[c.Jv_([{provide:rn.is,useExisting:v}]),c.GFd],ngContentSelectors:hy,decls:1,vars:0,consts:[["panel",""],["role","listbox",1,"mat-mdc-autocomplete-panel","mdc-menu-surface","mdc-menu-surface--open",3,"id"]],template:function(_,D){1&_&&(c.NAR(),c.DNE(0,Kg,3,16,"ng-template"))},styles:["div.mat-mdc-autocomplete-panel{width:100%;max-height:256px;visibility:hidden;transform-origin:center top;overflow:auto;padding:8px 0;box-sizing:border-box;position:static;border-radius:var(--mat-autocomplete-container-shape, var(--mat-sys-corner-extra-small));box-shadow:var(--mat-autocomplete-container-elevation-shadow, 0px 3px 1px -2px rgba(0, 0, 0, 0.2), 0px 2px 2px 0px rgba(0, 0, 0, 0.14), 0px 1px 5px 0px rgba(0, 0, 0, 0.12));background-color:var(--mat-autocomplete-background-color, var(--mat-sys-surface-container))}@media(forced-colors: active){div.mat-mdc-autocomplete-panel{outline:solid 1px}}.cdk-overlay-pane:not(.mat-mdc-autocomplete-panel-above) div.mat-mdc-autocomplete-panel{border-top-left-radius:0;border-top-right-radius:0}.mat-mdc-autocomplete-panel-above div.mat-mdc-autocomplete-panel{border-bottom-left-radius:0;border-bottom-right-radius:0;transform-origin:center bottom}div.mat-mdc-autocomplete-panel.mat-mdc-autocomplete-visible{visibility:visible}div.mat-mdc-autocomplete-panel.mat-mdc-autocomplete-hidden{visibility:hidden;pointer-events:none}mat-autocomplete{display:none}"],encapsulation:2,data:{animation:[kw]},changeDetection:0})}return v})();const Ow={provide:Su.kq,useExisting:(0,c.Rfq)(()=>qg),multi:!0},Zg=new c.nKC("mat-autocomplete-scroll-strategy",{providedIn:"root",factory:()=>{const v=(0,c.WQX)(Au.hJ);return()=>v.scrollStrategies.reposition()}}),ef={provide:Zg,deps:[Au.hJ],useFactory:function rp(v){return()=>v.scrollStrategies.reposition()}};let qg=(()=>{class v{_element=(0,c.WQX)(c.aKT);_overlay=(0,c.WQX)(Au.hJ);_viewContainerRef=(0,c.WQX)(c.c1b);_zone=(0,c.WQX)(c.SKi);_changeDetectorRef=(0,c.WQX)(c.gRc);_dir=(0,c.WQX)(dy.dS,{optional:!0});_formField=(0,c.WQX)(bn.xb,{optional:!0,host:!0});_document=(0,c.WQX)(at.qQ);_viewportRuler=(0,c.WQX)(Cm.Xj);_defaults=(0,c.WQX)(Xg,{optional:!0});_overlayRef;_portal;_componentDestroyed=!1;_scrollStrategy=(0,c.WQX)(Zg);_keydownSubscription;_outsideClickSubscription;_previousValue;_valueOnAttach;_valueOnLastKeydown;_positionStrategy;_manuallyFloatingLabel=!1;_closingActionsSubscription;_viewportSubscription=Dm.yU.EMPTY;_breakpointObserver=(0,c.WQX)(zd.QP);_handsetLandscapeSubscription=Dm.yU.EMPTY;_canOpenOnNextFocus=!0;_valueBeforeAutoSelection;_pendingAutoselectedOption;_closeKeyEventStream=new tl.B;_windowBlurHandler=()=>{this._canOpenOnNextFocus=this._document.activeElement!==this._element.nativeElement||this.panelOpen};_onChange=()=>{};_onTouched=()=>{};autocomplete;position="auto";connectedTo;autocompleteAttribute="off";autocompleteDisabled;_initialized=new tl.B;_injector=(0,c.WQX)(c.zZn);constructor(){}_aboveClass="mat-mdc-autocomplete-panel-above";ngAfterViewInit(){this._initialized.next(),this._initialized.complete();const d=this._getWindow();typeof d<"u"&&this._zone.runOutsideAngular(()=>d.addEventListener("blur",this._windowBlurHandler))}ngOnChanges(d){d.position&&this._positionStrategy&&(this._setStrategyPositions(this._positionStrategy),this.panelOpen&&this._overlayRef.updatePosition())}ngOnDestroy(){const d=this._getWindow();typeof d<"u"&&d.removeEventListener("blur",this._windowBlurHandler),this._handsetLandscapeSubscription.unsubscribe(),this._viewportSubscription.unsubscribe(),this._componentDestroyed=!0,this._destroyPanel(),this._closeKeyEventStream.complete(),this._clearFromModal()}get panelOpen(){return this._overlayAttached&&this.autocomplete.showPanel}_overlayAttached=!1;openPanel(){this._openPanelInternal()}closePanel(){this._resetLabel(),this._overlayAttached&&(this.panelOpen&&this._zone.run(()=>{this.autocomplete.closed.emit()}),this.autocomplete._latestOpeningTrigger===this&&(this.autocomplete._isOpen=!1,this.autocomplete._latestOpeningTrigger=null),this._overlayAttached=!1,this._pendingAutoselectedOption=null,this._overlayRef&&this._overlayRef.hasAttached()&&(this._overlayRef.detach(),this._closingActionsSubscription.unsubscribe()),this._updatePanelState(),this._componentDestroyed||this._changeDetectorRef.detectChanges(),this._trackedModal&&(0,Kc.Ae)(this._trackedModal,"aria-owns",this.autocomplete.id))}updatePosition(){this._overlayAttached&&this._overlayRef.updatePosition()}get panelClosingActions(){return(0,wu.h)(this.optionSelections,this.autocomplete._keyManager.tabOut.pipe((0,dt.p)(()=>this._overlayAttached)),this._closeKeyEventStream,this._getOutsideClickStream(),this._overlayRef?this._overlayRef.detachments().pipe((0,dt.p)(()=>this._overlayAttached)):(0,O.of)()).pipe((0,Os.T)(d=>d instanceof rn.MI?d:null))}optionSelections=(0,qu.v)(()=>{const d=this.autocomplete?this.autocomplete.options:null;return d?d.changes.pipe((0,Mw.Z)(d),(0,se.n)(()=>(0,wu.h)(...d.map(_=>_.onSelectionChange)))):this._initialized.pipe((0,se.n)(()=>this.optionSelections))});get activeOption(){return this.autocomplete&&this.autocomplete._keyManager?this.autocomplete._keyManager.activeItem:null}_getOutsideClickStream(){return(0,wu.h)((0,yu.R)(this._document,"click"),(0,yu.R)(this._document,"auxclick"),(0,yu.R)(this._document,"touchend")).pipe((0,dt.p)(d=>{const _=(0,Ce.Fb)(d),D=this._formField?this._formField.getConnectedOverlayOrigin().nativeElement:null,V=this.connectedTo?this.connectedTo.elementRef.nativeElement:null;return this._overlayAttached&&_!==this._element.nativeElement&&this._document.activeElement!==this._element.nativeElement&&(!D||!D.contains(_))&&(!V||!V.contains(_))&&!!this._overlayRef&&!this._overlayRef.overlayElement.contains(_)}))}writeValue(d){Promise.resolve(null).then(()=>this._assignOptionValue(d))}registerOnChange(d){this._onChange=d}registerOnTouched(d){this._onTouched=d}setDisabledState(d){this._element.nativeElement.disabled=d}_handleKeydown(d){const _=d.keyCode,D=(0,ol.rp)(d);if(_===ol._f&&!D&&d.preventDefault(),this._valueOnLastKeydown=this._element.nativeElement.value,this.activeOption&&_===ol.Fm&&this.panelOpen&&!D)this.activeOption._selectViaInteraction(),this._resetActiveItem(),d.preventDefault();else if(this.autocomplete){const V=this.autocomplete._keyManager.activeItem,J=_===ol.i7||_===ol.n6;_===ol.wn||J&&!D&&this.panelOpen?this.autocomplete._keyManager.onKeydown(d):J&&this._canOpen()&&this._openPanelInternal(this._valueOnLastKeydown),(J||this.autocomplete._keyManager.activeItem!==V)&&(this._scrollToOption(this.autocomplete._keyManager.activeItemIndex||0),this.autocomplete.autoSelectActiveOption&&this.activeOption&&(this._pendingAutoselectedOption||(this._valueBeforeAutoSelection=this._valueOnLastKeydown),this._pendingAutoselectedOption=this.activeOption,this._assignOptionValue(this.activeOption.value)))}}_handleInput(d){let _=d.target,D=_.value;if("number"===_.type&&(D=""==D?null:parseFloat(D)),this._previousValue!==D){if(this._previousValue=D,this._pendingAutoselectedOption=null,(!this.autocomplete||!this.autocomplete.requireSelection)&&this._onChange(D),D){if(this.panelOpen&&!this.autocomplete.requireSelection){const V=this.autocomplete.options?.find(J=>J.selected);V&&D!==this._getDisplayValue(V.value)&&V.deselect(!1)}}else this._clearPreviousSelectedOption(null,!1);if(this._canOpen()&&this._document.activeElement===d.target){const V=this._valueOnLastKeydown??this._element.nativeElement.value;this._valueOnLastKeydown=null,this._openPanelInternal(V)}}}_handleFocus(){this._canOpenOnNextFocus?this._canOpen()&&(this._previousValue=this._element.nativeElement.value,this._attachOverlay(this._previousValue),this._floatLabel(!0)):this._canOpenOnNextFocus=!0}_handleClick(){this._canOpen()&&!this.panelOpen&&this._openPanelInternal()}_floatLabel(d=!1){this._formField&&"auto"===this._formField.floatLabel&&(d?this._formField._animateAndLockLabel():this._formField.floatLabel="always",this._manuallyFloatingLabel=!0)}_resetLabel(){this._manuallyFloatingLabel&&(this._formField&&(this._formField.floatLabel="auto"),this._manuallyFloatingLabel=!1)}_subscribeToClosingActions(){const d=new S.c(D=>{(0,c.mal)(()=>{D.next()},{injector:this._injector})}),_=this.autocomplete.options.changes.pipe((0,Eu.M)(()=>this._positionStrategy.reapplyLastPosition()),(0,pe.c)(0));return(0,wu.h)(d,_).pipe((0,se.n)(()=>this._zone.run(()=>{const D=this.panelOpen;return this._resetActiveItem(),this._updatePanelState(),this._changeDetectorRef.detectChanges(),this.panelOpen&&this._overlayRef.updatePosition(),D!==this.panelOpen&&(this.panelOpen?this._emitOpened():this.autocomplete.closed.emit()),this.panelClosingActions})),(0,M.s)(1)).subscribe(D=>this._setValueAndClose(D))}_emitOpened(){this.autocomplete.opened.emit()}_destroyPanel(){this._overlayRef&&(this.closePanel(),this._overlayRef.dispose(),this._overlayRef=null)}_getDisplayValue(d){const _=this.autocomplete;return _&&_.displayWith?_.displayWith(d):d}_assignOptionValue(d){const _=this._getDisplayValue(d);null==d&&this._clearPreviousSelectedOption(null,!1),this._updateNativeInputValue(_??"")}_updateNativeInputValue(d){this._formField?this._formField._control.value=d:this._element.nativeElement.value=d,this._previousValue=d}_setValueAndClose(d){const _=this.autocomplete,D=d?d.source:this._pendingAutoselectedOption;D?(this._clearPreviousSelectedOption(D),this._assignOptionValue(D.value),this._onChange(D.value),_._emitSelectEvent(D),this._element.nativeElement.focus()):_.requireSelection&&this._element.nativeElement.value!==this._valueOnAttach&&(this._clearPreviousSelectedOption(null),this._assignOptionValue(null),_._animationDone?_._animationDone.pipe((0,M.s)(1)).subscribe(()=>this._onChange(null)):this._onChange(null)),this.closePanel()}_clearPreviousSelectedOption(d,_){this.autocomplete?.options?.forEach(D=>{D!==d&&D.selected&&D.deselect(_)})}_openPanelInternal(d=this._element.nativeElement.value){this._attachOverlay(d),this._floatLabel(),this._trackedModal&&(0,Kc.px)(this._trackedModal,"aria-owns",this.autocomplete.id)}_attachOverlay(d){let _=this._overlayRef;_?(this._positionStrategy.setOrigin(this._getConnectedElement()),_.updateSize({width:this._getPanelWidth()})):(this._portal=new ym.VA(this.autocomplete.template,this._viewContainerRef,{id:this._formField?.getLabelId()}),_=this._overlay.create(this._getOverlayConfig()),this._overlayRef=_,this._viewportSubscription=this._viewportRuler.change().subscribe(()=>{this.panelOpen&&_&&_.updateSize({width:this._getPanelWidth()})}),this._handsetLandscapeSubscription=this._breakpointObserver.observe(zd.Rp.HandsetLandscape).subscribe(V=>{V.matches?this._positionStrategy.withFlexibleDimensions(!0).withGrowAfterOpen(!0).withViewportMargin(8):this._positionStrategy.withFlexibleDimensions(!1).withGrowAfterOpen(!1).withViewportMargin(0)})),_&&!_.hasAttached()&&(_.attach(this._portal),this._valueOnAttach=d,this._valueOnLastKeydown=null,this._closingActionsSubscription=this._subscribeToClosingActions());const D=this.panelOpen;this.autocomplete._isOpen=this._overlayAttached=!0,this.autocomplete._latestOpeningTrigger=this,this.autocomplete._setColor(this._formField?.color),this._updatePanelState(),this._applyModalPanelOwnership(),this.panelOpen&&D!==this.panelOpen&&this._emitOpened()}_handlePanelKeydown=d=>{(d.keyCode===ol._f&&!(0,ol.rp)(d)||d.keyCode===ol.i7&&(0,ol.rp)(d,"altKey"))&&(this._pendingAutoselectedOption&&(this._updateNativeInputValue(this._valueBeforeAutoSelection??""),this._pendingAutoselectedOption=null),this._closeKeyEventStream.next(),this._resetActiveItem(),d.stopPropagation(),d.preventDefault())};_updatePanelState(){if(this.autocomplete._setVisibility(),this.panelOpen){const d=this._overlayRef;this._keydownSubscription||(this._keydownSubscription=d.keydownEvents().subscribe(this._handlePanelKeydown)),this._outsideClickSubscription||(this._outsideClickSubscription=d.outsidePointerEvents().subscribe())}else this._keydownSubscription?.unsubscribe(),this._outsideClickSubscription?.unsubscribe(),this._keydownSubscription=this._outsideClickSubscription=null}_getOverlayConfig(){return new Au.rR({positionStrategy:this._getOverlayPosition(),scrollStrategy:this._scrollStrategy(),width:this._getPanelWidth(),direction:this._dir??void 0,panelClass:this._defaults?.overlayPanelClass})}_getOverlayPosition(){const d=this._overlay.position().flexibleConnectedTo(this._getConnectedElement()).withFlexibleDimensions(!1).withPush(!1);return this._setStrategyPositions(d),this._positionStrategy=d,d}_setStrategyPositions(d){const _=[{originX:"start",originY:"bottom",overlayX:"start",overlayY:"top"},{originX:"end",originY:"bottom",overlayX:"end",overlayY:"top"}],D=this._aboveClass,V=[{originX:"start",originY:"top",overlayX:"start",overlayY:"bottom",panelClass:D},{originX:"end",originY:"top",overlayX:"end",overlayY:"bottom",panelClass:D}];let J;J="above"===this.position?V:"below"===this.position?_:[..._,...V],d.withPositions(J)}_getConnectedElement(){return this.connectedTo?this.connectedTo.elementRef:this._formField?this._formField.getConnectedOverlayOrigin():this._element}_getPanelWidth(){return this.autocomplete.panelWidth||this._getHostWidth()}_getHostWidth(){return this._getConnectedElement().nativeElement.getBoundingClientRect().width}_resetActiveItem(){const d=this.autocomplete;if(d.autoActiveFirstOption){let _=-1;for(let D=0;D .cdk-overlay-container [aria-modal="true"]');if(!d)return;const _=this.autocomplete.id;this._trackedModal&&(0,Kc.Ae)(this._trackedModal,"aria-owns",_),(0,Kc.px)(d,"aria-owns",_),this._trackedModal=d}_clearFromModal(){this._trackedModal&&((0,Kc.Ae)(this._trackedModal,"aria-owns",this.autocomplete.id),this._trackedModal=null)}static \u0275fac=function(_){return new(_||v)};static \u0275dir=c.FsC({type:v,selectors:[["input","matAutocomplete",""],["textarea","matAutocomplete",""]],hostAttrs:[1,"mat-mdc-autocomplete-trigger"],hostVars:7,hostBindings:function(_,D){1&_&&c.bIt("focusin",function(){return D._handleFocus()})("blur",function(){return D._onTouched()})("input",function(J){return D._handleInput(J)})("keydown",function(J){return D._handleKeydown(J)})("click",function(){return D._handleClick()}),2&_&&c.BMQ("autocomplete",D.autocompleteAttribute)("role",D.autocompleteDisabled?null:"combobox")("aria-autocomplete",D.autocompleteDisabled?null:"list")("aria-activedescendant",D.panelOpen&&D.activeOption?D.activeOption.id:null)("aria-expanded",D.autocompleteDisabled?null:D.panelOpen.toString())("aria-controls",D.autocompleteDisabled||!D.panelOpen||null==D.autocomplete?null:D.autocomplete.id)("aria-haspopup",D.autocompleteDisabled?null:"listbox")},inputs:{autocomplete:[0,"matAutocomplete","autocomplete"],position:[0,"matAutocompletePosition","position"],connectedTo:[0,"matAutocompleteConnectedTo","connectedTo"],autocompleteAttribute:[0,"autocomplete","autocompleteAttribute"],autocompleteDisabled:[2,"matAutocompleteDisabled","autocompleteDisabled",c.L39]},exportAs:["matAutocompleteTrigger"],features:[c.Jv_([Ow]),c.GFd,c.OA$]})}return v})(),Jg=(()=>{class v{static \u0275fac=function(_){return new(_||v)};static \u0275mod=c.$C({type:v});static \u0275inj=c.G2t({providers:[ef],imports:[Au.z_,rn.Sy,rn.yE,Cm.Gj,rn.Sy,rn.yE]})}return v})();var fy=r(6389),py=r(8627),ip=r(3149);const e_=["barSearchInput"],my=["matAutocomplete"];function gy(v,m){if(1&v){const d=c.RV6();c.j41(0,"button",5),c.bIt("click",function(){c.eBV(d);const D=c.XpG(2);return c.Njj(D.open())}),c.nrm(1,"mat-icon",6),c.k0s()}2&v&&(c.R7$(),c.Y8G("svgIcon","heroicons_outline:magnifying-glass"))}function tf(v,m){1&v&&(c.j41(0,"mat-option",14),c.EFF(1," No results found! "),c.k0s())}function t_(v,m){if(1&v){const d=c.RV6();c.j41(0,"img",22),c.bIt("error",function(D){c.eBV(d);const V=c.XpG(5);return c.Njj(V.handleImageError(D))}),c.k0s()}if(2&v){const d=c.XpG().$implicit;c.Mz_("alt","",d.name,"'s avatar"),c.Y8G("src",d.avatar,c.B4B)}}function Am(v,m){1&v&&(c.qex(0),c.nrm(1,"mat-icon",23),c.bVm()),2&v&&(c.R7$(),c.Y8G("svgIcon","heroicons_outline:user-circle"))}function _y(v,m){if(1&v&&(c.j41(0,"div",24),c.EFF(1),c.k0s()),2&v){const d=c.XpG().$implicit;c.R7$(),c.SpI(" ",d.about," ")}}function Rw(v,m){if(1&v&&(c.qex(0),c.j41(1,"mat-option",15)(2,"div",16)(3,"div",17),c.DNE(4,t_,1,3,"img",18)(5,Am,2,1,"ng-container",2),c.k0s(),c.j41(6,"div",19)(7,"span",20),c.EFF(8),c.k0s(),c.DNE(9,_y,2,1,"div",21),c.k0s()()(),c.bVm()),2&v){const d=m.$implicit;c.R7$(),c.Y8G("routerLink",d.link)("value",d.name),c.R7$(3),c.Y8G("ngIf",d.avatar),c.R7$(),c.Y8G("ngIf",!d.avatar),c.R7$(3),c.JRh(d.name),c.R7$(),c.Y8G("ngIf",d.about)}}function Nw(v,m){if(1&v&&(c.qex(0),c.DNE(1,Rw,10,6,"ng-container",12),c.bVm()),2&v){const d=m.$implicit,_=c.XpG(3);c.R7$(),c.Y8G("ngForOf",d.results)("ngForTrackBy",_.trackByFn)}}function nf(v,m){if(1&v){const d=c.RV6();c.j41(0,"div",7),c.nrm(1,"mat-icon",8),c.j41(2,"input",9,0),c.bIt("keydown",function(D){c.eBV(d);const V=c.XpG(2);return c.Njj(V.onKeydown(D))}),c.k0s(),c.j41(4,"mat-autocomplete",10,1),c.DNE(6,tf,2,0,"mat-option",11)(7,Nw,2,2,"ng-container",12),c.k0s(),c.j41(8,"button",13),c.bIt("click",function(){c.eBV(d);const D=c.XpG(2);return c.Njj(D.close())}),c.nrm(9,"mat-icon",6),c.k0s()()}if(2&v){const d=c.sdS(5),_=c.XpG(2);c.Y8G("@slideInTop",void 0)("@slideOutTop",void 0),c.R7$(),c.Y8G("svgIcon","heroicons_outline:magnifying-glass"),c.R7$(),c.Y8G("formControl",_.searchControl)("matAutocomplete",d)("placeholder","Search..."),c.R7$(2),c.Y8G("autoSelectActiveOption",!0)("disableRipple",!0),c.R7$(2),c.Y8G("ngIf",_.resultSets&&!_.resultSets.length),c.R7$(),c.Y8G("ngForOf",_.resultSets)("ngForTrackBy",_.trackByFn),c.R7$(2),c.Y8G("svgIcon","heroicons_outline:x-mark")}}function vy(v,m){if(1&v&&(c.j41(0,"div"),c.DNE(1,gy,2,1,"button",3)(2,nf,10,12,"div",4),c.k0s()),2&v){const d=c.XpG();c.R7$(),c.Y8G("ngIf",!d.opened),c.R7$(),c.Y8G("ngIf",d.opened)}}let rf=(()=>{class v{constructor(d,_){this._storageService=d,this._sanitizer=_,this.appearance="basic",this.debounce=300,this.minLength=2,this.search=new c.bkB,this.opened=!1,this.searchControl=new Su.hs,this._unsubscribeAll=new tl.B}set barSearchInput(d){d&&setTimeout(()=>{d.nativeElement.focus()})}set matAutocomplete(d){this._matAutocomplete=d}ngOnChanges(d){"appearance"in d&&this.close()}ngOnInit(){var d=this;this.searchControl.valueChanges.pipe((0,py.B)(this.debounce),(0,ea.Q)(this._unsubscribeAll),(0,Os.T)(_=>((!_||_.length_&&_.length>=this.minLength)).subscribe(function(){var _=(0,w.A)(function*(D){const V=yield d._storageService.searchProfile(D);d.resultSets=V.map(J=>({label:"Project",results:[{name:J.profile.name||J.profile.displayName||J.pubKey,pubkey:J.pubKey,username:J.profile.username||"",website:J.profile.website||"",about:J.profile.about?J.profile.about.replace(/<\/?[^>]+(>|$)/g,""):"",avatar:J.profile.picture||null,banner:J.profile.banner||null,link:`/profile/${J.pubKey}`}]})),d.search.next(d.resultSets)});return function(D){return _.apply(this,arguments)}}())}ngOnDestroy(){this._unsubscribeAll.next(null),this._unsubscribeAll.complete()}onKeydown(d){"Escape"===d.code&&"bar"===this.appearance&&!this._matAutocomplete.isOpen&&this.close()}open(){this.opened||(this.opened=!0)}close(){this.opened&&(this.searchControl.setValue(""),this.opened=!1)}trackByFn(d,_){return _.id||d}handleImageError(d){const _=d.target;_.onerror=null,_.src="images/avatars/avatar-placeholder.png"}static{this.\u0275fac=function(_){return new(_||v)(c.rXU(ip.n),c.rXU(i.up))}}static{this.\u0275cmp=c.VBU({type:v,selectors:[["search"]],viewQuery:function(_,D){if(1&_&&(c.GBs(e_,5),c.GBs(my,5)),2&_){let V;c.mGM(V=c.lsd())&&(D.barSearchInput=V.first),c.mGM(V=c.lsd())&&(D.matAutocomplete=V.first)}},inputs:{appearance:"appearance",debounce:"debounce",minLength:"minLength"},outputs:{search:"search"},exportAs:["angorSearch"],features:[c.Jv_([{provide:Zg,useFactory:()=>{const d=(0,c.WQX)(Au.hJ);return()=>d.scrollStrategies.block()}}]),c.OA$],decls:1,vars:1,consts:[["barSearchInput",""],["matAutocomplete","matAutocomplete"],[4,"ngIf"],["mat-icon-button","",3,"click",4,"ngIf"],["class","bg-card absolute inset-0 z-99 flex shrink-0 items-center",4,"ngIf"],["mat-icon-button","",3,"click"],[3,"svgIcon"],[1,"bg-card","absolute","inset-0","z-99","flex","shrink-0","items-center"],[1,"absolute","ml-6","sm:ml-8",3,"svgIcon"],[1,"h-full","w-full","px-16","sm:px-18",3,"keydown","formControl","matAutocomplete","placeholder"],[1,"max-h-128","rounded-b","border-t","shadow-md","sm:px-2",3,"autoSelectActiveOption","disableRipple"],["class","text-secondary pointer-events-none bg-transparent px-6 py-0 text-md",4,"ngIf"],[4,"ngFor","ngForOf","ngForTrackBy"],["mat-icon-button","",1,"absolute","right-5","top-1/2","-mt-5","h-10","w-10","shrink-0","sm:right-7",3,"click"],[1,"text-secondary","pointer-events-none","bg-transparent","px-6","py-0","text-md"],[1,"group","relative","mb-1","rounded-md","px-6","py-0","text-md","dark:hover:bg-hover","hover:bg-gray-100",3,"routerLink","value"],[1,"flex","items-center"],[1,"flex","h-8","w-8","shrink-0","items-center","justify-center","overflow-hidden","rounded-full","bg-primary-100","dark:bg-primary-800"],["class","h-full w-full object-cover",3,"src","alt","error",4,"ngIf"],[1,"ml-3","truncate"],[1,"font-semibold"],["class","text-sm text-gray-500",4,"ngIf"],[1,"h-full","w-full","object-cover",3,"error","src","alt"],[1,"m-0","text-primary","icon-size-5","dark:text-primary-400",3,"svgIcon"],[1,"text-sm","text-gray-500"]],template:function(_,D){1&_&&c.DNE(0,vy,3,2,"div",2),2&_&&c.Y8G("ngIf","bar"===D.appearance)},dependencies:[_l.Hl,_l.iY,il.m_,il.An,Su.YN,Su.me,Su.BC,Jg,Tu,rn.wT,qg,Su.X1,Su.l_,rn.Sy,a.Wk,bn.RG,fy.fS,at.MD,at.Sq,at.bT],encapsulation:2,data:{animation:xm.F}})}}return v})();var op=r(7702),Mu=r(7818),yy=r(1109),Lw=r(4482);const n_=()=>["/settings"];function by(v,m){if(1&v&&(c.qex(0),c.nrm(1,"img",15),c.bVm()),2&v){const d=c.XpG();c.R7$(),c.Y8G("src",d.getSafeUrl(null==d.user?null:d.user.picture),c.B4B)}}function r_(v,m){1&v&&c.nrm(0,"mat-icon",12),2&v&&c.Y8G("svgIcon","heroicons_outline:user-circle")}let sp=(()=>{class v{constructor(d,_,D,V,J,we,Xe){this._changeDetectorRef=d,this._router=_,this._angorConfigService=D,this._signerService=V,this._storageService=J,this.sanitizer=we,this._nostrLoginService=Xe,this.isLoading=!0,this.errorMessage=null,this._unsubscribeAll=new tl.B}ngOnInit(){this.userPubKey=this._signerService.getPublicKey(),this._angorConfigService.config$.pipe((0,ea.Q)(this._unsubscribeAll)).subscribe(d=>{localStorage.setItem("angorConfig",JSON.stringify(d)),this.config=d,this._changeDetectorRef.detectChanges()}),this.loadUserProfile(),this._storageService.profile$.subscribe(d=>{d&&d.pubKey===this.userPubKey&&(this.user=d.metadata,this._changeDetectorRef.detectChanges())})}ngOnDestroy(){this._unsubscribeAll.next(null),this._unsubscribeAll.complete()}loadUserProfile(){var d=this;return(0,w.A)(function*(){d._storageService.getProfile(d.userPubKey).then(_=>{d.user=_,d._changeDetectorRef.detectChanges()})})()}logout(){this._router.navigate(["/logout"])}profile(){this._router.navigate(["/profile"])}setLayout(d){this._angorConfigService.config={layout:d},this._changeDetectorRef.detectChanges()}setScheme(d){this._angorConfigService.config={scheme:d},this._changeDetectorRef.detectChanges()}setTheme(d){this._angorConfigService.config={theme:d},this._changeDetectorRef.detectChanges()}getSafeUrl(d){return this.sanitizer.bypassSecurityTrustUrl(d)}Switch(){this._nostrLoginService.switchAccount()}static{this.\u0275fac=function(_){return new(_||v)(c.rXU(c.gRc),c.rXU(a.Ix),c.rXU(yy.P),c.rXU(Vd.A),c.rXU(ip.n),c.rXU(i.up),c.rXU(Lw.v))}}static{this.\u0275cmp=c.VBU({type:v,selectors:[["user"]],decls:50,vars:16,consts:[["defaultAvatar",""],["userActions","matMenu"],["settingsMenu","matMenu"],["mat-icon-button","",3,"matMenuTriggerFor"],[1,"relative"],[4,"ngIf","ngIfElse"],[3,"xPosition"],["mat-menu-item",""],[1,"flex","flex-col","leading-none"],[1,"mt-1.5","text-md","font-medium"],[1,"my-2"],["mat-menu-item","",3,"click"],[3,"svgIcon"],["mat-menu-item","",3,"matMenuTriggerFor"],["mat-menu-item","",3,"routerLink"],["alt","","onerror","this.onerror=null; this.src='/images/avatars/avatar-placeholder.png';",1,"h-7","w-7","rounded-full","object-cover",3,"src"]],template:function(_,D){if(1&_){const V=c.RV6();c.j41(0,"button",3)(1,"span",4),c.DNE(2,by,2,1,"ng-container",5)(3,r_,1,1,"ng-template",null,0,c.C5r),c.k0s()(),c.j41(5,"mat-menu",6,1)(7,"button",7)(8,"span",8)(9,"span"),c.EFF(10,"Logged in as"),c.k0s(),c.j41(11,"span",9),c.EFF(12),c.k0s()()(),c.nrm(13,"mat-divider",10),c.j41(14,"button",11),c.bIt("click",function(){return c.eBV(V),c.Njj(D.Switch())}),c.nrm(15,"mat-icon",12),c.j41(16,"span"),c.EFF(17,"Switch account"),c.k0s()(),c.j41(18,"button",11),c.bIt("click",function(){return c.eBV(V),c.Njj(D.profile())}),c.nrm(19,"mat-icon",12),c.j41(20,"span"),c.EFF(21,"Profile"),c.k0s()(),c.j41(22,"button",13),c.nrm(23,"mat-icon",12),c.j41(24,"span"),c.EFF(25,"Options"),c.k0s()(),c.nrm(26,"mat-divider",10),c.j41(27,"button",11),c.bIt("click",function(){return c.eBV(V),c.Njj(D.logout())}),c.nrm(28,"mat-icon",12),c.j41(29,"span"),c.EFF(30,"logout"),c.k0s()()(),c.j41(31,"mat-menu",null,2)(33,"button",11),c.bIt("click",function(){return c.eBV(V),c.Njj(D.setScheme("auto"))}),c.nrm(34,"mat-icon",12),c.j41(35,"span"),c.EFF(36,"Auto Theme"),c.k0s()(),c.j41(37,"button",11),c.bIt("click",function(){return c.eBV(V),c.Njj(D.setScheme("light"))}),c.nrm(38,"mat-icon",12),c.j41(39,"span"),c.EFF(40,"Light Theme"),c.k0s()(),c.j41(41,"button",11),c.bIt("click",function(){return c.eBV(V),c.Njj(D.setScheme("dark"))}),c.nrm(42,"mat-icon",12),c.j41(43,"span"),c.EFF(44,"Dark Theme"),c.k0s()(),c.nrm(45,"mat-divider"),c.j41(46,"button",14),c.nrm(47,"mat-icon",12),c.j41(48,"span"),c.EFF(49,"Settings"),c.k0s()()()}if(2&_){const V=c.sdS(4),J=c.sdS(6),we=c.sdS(32);c.Y8G("matMenuTriggerFor",J),c.R7$(2),c.Y8G("ngIf",null==D.user?null:D.user.picture)("ngIfElse",V),c.R7$(3),c.Y8G("xPosition","before"),c.R7$(7),c.JRh((null==D.user?null:D.user.display_name)||(null==D.user?null:D.user.name)||"Unknown User"),c.R7$(3),c.Y8G("svgIcon","heroicons_outline:user-circle"),c.R7$(4),c.Y8G("svgIcon","heroicons_outline:user-circle"),c.R7$(3),c.Y8G("matMenuTriggerFor",we),c.R7$(),c.Y8G("svgIcon","heroicons_outline:cog-8-tooth"),c.R7$(5),c.Y8G("svgIcon","heroicons_outline:arrow-right-on-rectangle"),c.R7$(6),c.Y8G("svgIcon","heroicons_solid:bolt"),c.R7$(4),c.Y8G("svgIcon","heroicons_solid:sun"),c.R7$(4),c.Y8G("svgIcon","heroicons_solid:moon"),c.R7$(4),c.Y8G("routerLink",c.lJ4(15,n_)),c.R7$(),c.Y8G("svgIcon","heroicons_outline:cog-8-tooth")}},dependencies:[_l.Hl,_l.iY,Mu.Cn,Mu.kk,Mu.fb,Mu.Cp,il.m_,il.An,op.w,op.q,at.MD,at.bT,a.iI,a.Wk],encapsulation:2,changeDetection:0})}}return v})();var i_=r(6061),ad=r(9587);let wy=(()=>{class v{constructor(d,_){this.swUpdate=d,this.zone=_,this.newVersionAvailableSubject=new Oe.t(!1),this.isNewVersionAvailable$=this.newVersionAvailableSubject.asObservable(),this.intervalSource=function o_(v=0,m=i_.E){return v<0&&(v=0),(0,ad.O)(v,v,m)}(9e5),this.checkForUpdateOnLoad(),this.checkForUpdateOnInterval()}applyUpdate(){this.swUpdate.activateUpdate().then(()=>document.location.reload()).catch(d=>console.error("Failed to apply updates:",d))}checkForUpdateOnInterval(){var d=this;this.unsubscribeInterval(),this.swUpdate.isEnabled&&this.zone.runOutsideAngular(()=>{this.intervalSubscription=this.intervalSource.subscribe((0,w.A)(function*(){try{(yield d.swUpdate.checkForUpdate())&&d.newVersionAvailableSubject.next(!0)}catch(_){console.error("Failed to check for updates:",_)}}))})}checkForUpdateOnLoad(){this.unsubscribeNewVersion(),this.swUpdate.isEnabled&&(this.newVersionSubscription=this.swUpdate.versionUpdates.subscribe(d=>{switch(d.type){case"VERSION_DETECTED":break;case"VERSION_READY":this.newVersionAvailableSubject.next(!0);break;case"VERSION_INSTALLATION_FAILED":console.error(`Failed to install app version '${d.version.hash}': ${d.error}`)}}))}unsubscribeInterval(){this.intervalSubscription&&this.intervalSubscription.unsubscribe()}unsubscribeNewVersion(){this.newVersionSubscription&&this.newVersionSubscription.unsubscribe()}static{this.\u0275fac=function(_){return new(_||v)(c.KVO(Ld),c.KVO(c.SKi))}}static{this.\u0275prov=c.jDH({token:v,factory:v.\u0275fac,providedIn:"root"})}}return v})();function Ey(v,m){if(1&v){const d=c.RV6();c.j41(0,"button",1),c.bIt("click",function(){c.eBV(d);const D=c.XpG();return c.Njj(D.applyUpdate())}),c.nrm(1,"mat-icon",2),c.k0s()}if(2&v){const d=c.XpG();c.Y8G("matTooltip",d.tooltip||"Update App"),c.R7$(),c.Y8G("svgIcon","heroicons_outline:cloud-arrow-down")}}let s_=(()=>{class v{constructor(d,_){this.updateService=d,this._changeDetectorRef=_,this.updateService.isNewVersionAvailable$.subscribe(D=>{D&&this._changeDetectorRef.detectChanges()})}applyUpdate(){this.updateService.applyUpdate()}static{this.\u0275fac=function(_){return new(_||v)(c.rXU(wy),c.rXU(c.gRc))}}static{this.\u0275cmp=c.VBU({type:v,selectors:[["update"]],inputs:{tooltip:"tooltip"},exportAs:["update"],decls:2,vars:3,consts:[["mat-icon-button","",3,"matTooltip","click",4,"ngIf"],["mat-icon-button","",3,"click","matTooltip"],[3,"svgIcon"]],template:function(_,D){1&_&&(c.DNE(0,Ey,2,2,"button",0),c.nI1(1,"async")),2&_&&c.Y8G("ngIf",c.bMT(1,1,D.updateService.isNewVersionAvailable$))},dependencies:[_l.Hl,_l.iY,il.m_,il.An,zc.uc,zc.oV,at.MD,at.bT,at.Jj],encapsulation:2,changeDetection:0})}}return v})();function xy(v,m){if(1&v&&(c.j41(0,"angor-vertical-navigation",0),c.qex(1,10),c.j41(2,"div",11),c.nrm(3,"img",12),c.k0s(),c.bVm(),c.k0s()),2&v){const d=c.XpG();c.Y8G("mode","over")("name","mainNavigation")("navigation",d.navigation.default)("opened",!1)}}function a_(v,m){if(1&v&&(c.j41(0,"div",13)(1,"div",14),c.nrm(2,"img",15)(3,"img",16),c.k0s(),c.nrm(4,"img",17),c.k0s(),c.nrm(5,"angor-horizontal-navigation",18)),2&v){const d=c.XpG();c.R7$(5),c.Y8G("name","mainNavigation")("navigation",d.navigation.horizontal)}}function Cy(v,m){if(1&v){const d=c.RV6();c.j41(0,"button",19),c.bIt("click",function(){c.eBV(d);const D=c.XpG();return c.Njj(D.toggleNavigation("mainNavigation"))}),c.nrm(1,"mat-icon",20),c.k0s()}2&v&&(c.R7$(),c.Y8G("svgIcon","heroicons_outline:bars-3"))}function Dy(v,m){1&v&&c.nrm(0,"router-outlet")}let Ay=(()=>{class v{constructor(d,_,D,V,J){this._activatedRoute=d,this._router=_,this._navigationService=D,this._angorMediaWatcherService=V,this._angorNavigationService=J,this._unsubscribeAll=new tl.B,this.version=cc}ngOnInit(){this._navigationService.navigation$.pipe((0,ea.Q)(this._unsubscribeAll)).subscribe(d=>{this.navigation=d}),this._angorMediaWatcherService.onMediaChange$.pipe((0,ea.Q)(this._unsubscribeAll)).subscribe(({matchingAliases:d})=>{this.isScreenSmall=!d.includes("md")})}ngOnDestroy(){this._unsubscribeAll.next(null),this._unsubscribeAll.complete()}toggleNavigation(d){const _=this._angorNavigationService.getComponent(d);_&&_.toggle()}static{this.\u0275fac=function(_){return new(_||v)(c.rXU(a.nX),c.rXU(a.Ix),c.rXU(wa),c.rXU(ue.l),c.rXU(Zh.lX))}}static{this.\u0275cmp=c.VBU({type:v,selectors:[["modern-layout"]],decls:17,vars:6,consts:[[1,"dark","bg-gray-900","print:hidden",3,"mode","name","navigation","opened"],[1,"flex","w-full","min-w-0","flex-auto","flex-col"],[1,"bg-card","relative","z-49","flex","h-16","w-full","flex-0","items-center","px-4","shadow","dark:border-b","dark:bg-transparent","dark:shadow-none","sm:h-20","md:px-6","print:hidden"],["mat-icon-button",""],[1,"ml-auto","flex","items-center","space-x-0.5","pl-2","sm:space-x-2"],[1,"hidden","md:block"],[3,"appearance"],[1,"flex","w-full","flex-auto","flex-col"],[1,"bg-card","relative","z-49","flex","h-14","w-full","flex-0","items-center","border-t","px-4","dark:bg-transparent","sm:h-20","md:px-6","print:hidden"],[1,"text-secondary","font-medium"],["angorVerticalNavigationContentHeader",""],[1,"flex","h-20","items-center","px-8","pt-6"],["src","images/logo/logo-text-on-dark.svg","alt","Angor Hub",1,"h-10","w-24"],[1,"mx-2","flex","items-center","lg:mr-8"],[1,"hidden","lg:flex"],["src","images/logo/logo-text.svg",1,"h-10","w-24","dark:hidden"],["src","images/logo/logo-text-on-dark.svg",1,"hidden","h-10","w-24","dark:flex"],["src","images/logo/logo.svg",1,"flex","w-8","lg:hidden"],[1,"mr-2",3,"name","navigation"],["mat-icon-button","",3,"click"],[3,"svgIcon"]],template:function(_,D){1&_&&(c.nrm(0,"angor-loading-bar"),c.DNE(1,xy,4,4,"angor-vertical-navigation",0),c.j41(2,"div",1)(3,"div",2),c.DNE(4,a_,6,2)(5,Cy,2,1,"button",3),c.j41(6,"div",4),c.nrm(7,"update")(8,"angor-fullscreen",5)(9,"search",6)(10,"notifications")(11,"user"),c.k0s()(),c.j41(12,"div",7),c.DNE(13,Dy,1,0,"router-outlet"),c.k0s(),c.j41(14,"div",8)(15,"span",9),c.EFF(16),c.k0s()()()),2&_&&(c.R7$(),c.vxM(D.isScreenSmall?1:-1),c.R7$(3),c.vxM(D.isScreenSmall?-1:4),c.R7$(),c.vxM(D.isScreenSmall?5:-1),c.R7$(4),c.Y8G("appearance","bar"),c.R7$(4),c.vxM(13),c.R7$(3),c.SpI("Angor Hub - version ",D.version,""))},dependencies:[Wc,Zh.Tv,Zh.$w,_l.Hl,_l.iY,il.m_,il.An,Ac,rf,np,sp,a.n3,s_],encapsulation:2})}}return v})();function Sy(v,m){1&v&&c.nrm(0,"router-outlet")}let Ty=(()=>{class v{constructor(d,_,D,V,J){this._activatedRoute=d,this._router=_,this._navigationService=D,this._angorMediaWatcherService=V,this._angorNavigationService=J,this._unsubscribeAll=new tl.B,this.version=cc}ngOnInit(){this._navigationService.navigation$.pipe((0,ea.Q)(this._unsubscribeAll)).subscribe(d=>{this.navigation=d}),this._angorMediaWatcherService.onMediaChange$.pipe((0,ea.Q)(this._unsubscribeAll)).subscribe(({matchingAliases:d})=>{this.isScreenSmall=!d.includes("md")})}ngOnDestroy(){this._unsubscribeAll.next(null),this._unsubscribeAll.complete()}toggleNavigation(d){const _=this._angorNavigationService.getComponent(d);_&&_.toggle()}static{this.\u0275fac=function(_){return new(_||v)(c.rXU(a.nX),c.rXU(a.Ix),c.rXU(wa),c.rXU(ue.l),c.rXU(Zh.lX))}}static{this.\u0275cmp=c.VBU({type:v,selectors:[["classic-layout"]],decls:21,vars:8,consts:[[1,"dark","bg-gray-900","print:hidden",3,"mode","name","navigation","opened"],["angorVerticalNavigationContentHeader",""],[1,"flex","h-20","items-center","p-6"],["src","images/logo/logo-text.svg","alt","Angor Hub",1,"w-30","dark:hidden"],["src","images/logo/logo-text-on-dark.svg","alt","Angor Hub",1,"hidden","w-30","dark:flex"],[1,"flex","w-full","min-w-0","flex-auto","flex-col"],[1,"bg-card","relative","z-49","flex","h-16","w-full","flex-0","items-center","px-4","shadow","dark:border-b","dark:bg-transparent","dark:shadow-none","md:px-6","print:hidden"],["mat-icon-button","",3,"click"],[3,"svgIcon"],[1,"ml-auto","flex","items-center","space-x-0.5","pl-2","sm:space-x-2"],[1,"hidden","md:block"],[3,"appearance"],[1,"flex","flex-auto","flex-col"],[1,"bg-card","relative","z-49","flex","h-14","w-full","flex-0","items-center","justify-start","border-t","px-4","dark:bg-transparent","md:px-6","print:hidden"],[1,"text-secondary","font-medium"]],template:function(_,D){1&_&&(c.nrm(0,"angor-loading-bar"),c.j41(1,"angor-vertical-navigation",0),c.qex(2,1),c.j41(3,"div",2),c.nrm(4,"img",3)(5,"img",4),c.k0s(),c.bVm(),c.k0s(),c.j41(6,"div",5)(7,"div",6)(8,"button",7),c.bIt("click",function(){return D.toggleNavigation("mainNavigation")}),c.nrm(9,"mat-icon",8),c.k0s(),c.j41(10,"div",9),c.nrm(11,"update")(12,"angor-fullscreen",10)(13,"search",11)(14,"notifications")(15,"user"),c.k0s()(),c.j41(16,"div",12),c.DNE(17,Sy,1,0,"router-outlet"),c.k0s(),c.j41(18,"div",13)(19,"span",14),c.EFF(20),c.k0s()()()),2&_&&(c.R7$(),c.Y8G("mode",D.isScreenSmall?"over":"side")("name","mainNavigation")("navigation",D.navigation.default)("opened",!D.isScreenSmall),c.R7$(8),c.Y8G("svgIcon","heroicons_outline:bars-3"),c.R7$(4),c.Y8G("appearance","bar"),c.R7$(4),c.vxM(17),c.R7$(3),c.SpI("Angor Hub - version ",D.version,""))},dependencies:[Wc,Zh.Tv,_l.Hl,_l.iY,il.m_,il.An,Ac,rf,np,sp,a.n3,s_],encapsulation:2})}}return v})();function Sm(v,m){1&v&&c.nrm(0,"empty-layout")}function My(v,m){1&v&&c.nrm(0,"modern-layout")}function ky(v,m){1&v&&c.nrm(0,"classic-layout")}let Sc=(()=>{class v{constructor(d,_,D,V,J,we,Xe){this._activatedRoute=d,this._document=_,this._renderer2=D,this._router=V,this._angorConfigService=J,this._angorMediaWatcherService=we,this._angorPlatformService=Xe,this._unsubscribeAll=new tl.B}ngOnInit(){(0,ac.z)([this._angorConfigService.config$,this._angorMediaWatcherService.onMediaQueryChange$(["(prefers-color-scheme: dark)","(prefers-color-scheme: light)"])]).pipe((0,ea.Q)(this._unsubscribeAll),(0,Os.T)(([d,_])=>{const D={scheme:d.scheme,theme:d.theme};return"auto"===d.scheme&&(D.scheme=_.breakpoints["(prefers-color-scheme: dark)"]?"dark":"light"),D})).subscribe(d=>{this.scheme=d.scheme,this.theme=d.theme,this._updateScheme(),this._updateTheme()}),this._angorConfigService.config$.pipe((0,ea.Q)(this._unsubscribeAll)).subscribe(d=>{this.config=d,this._updateLayout()}),this._router.events.pipe((0,dt.p)(d=>d instanceof a.wF),(0,ea.Q)(this._unsubscribeAll)).subscribe(()=>{this._updateLayout()}),this._renderer2.setAttribute(this._document.querySelector("[ng-version]"),"angor-version",cc),this._renderer2.addClass(this._document.body,this._angorPlatformService.osName)}ngOnDestroy(){this._unsubscribeAll.next(null),this._unsubscribeAll.complete()}_updateLayout(){let d=this._activatedRoute;for(;d.firstChild;)d=d.firstChild;this.layout=this.config.layout;const _=d.snapshot.queryParamMap.get("layout");_&&(this.layout=_,this.config&&(this.config.layout=_)),d.pathFromRoot.forEach(V=>{V.routeConfig&&V.routeConfig.data&&V.routeConfig.data.layout&&(this.layout=V.routeConfig.data.layout)})}_updateScheme(){this._document.body.classList.remove("light","dark"),this._document.body.classList.add(this.scheme)}_updateTheme(){this._document.body.classList.forEach(d=>{d.startsWith("theme-")&&this._document.body.classList.remove(d,d.split("-")[1])}),this._document.body.classList.add(this.theme)}static{this.\u0275fac=function(_){return new(_||v)(c.rXU(a.nX),c.rXU(at.qQ),c.rXU(c.sFG),c.rXU(a.Ix),c.rXU(yy.P),c.rXU(ue.l),c.rXU(Be))}}static{this.\u0275cmp=c.VBU({type:v,selectors:[["layout"]],decls:3,vars:3,template:function(_,D){1&_&&c.DNE(0,Sm,1,0,"empty-layout")(1,My,1,0,"modern-layout")(2,ky,1,0,"classic-layout"),2&_&&(c.vxM("empty"===D.layout?0:-1),c.R7$(),c.vxM("modern"===D.layout?1:-1),c.R7$(),c.vxM("classic"===D.layout?2:-1))},dependencies:[Zf,Ay,Ty],styles:["layout{display:flex;flex:1 1 auto;width:100%;max-width:100%;min-width:0}layout>*{position:relative;display:flex;flex:1 1 auto;width:100%}layout router-outlet+*{position:relative;display:flex;flex:1 1 auto;width:100%}\n"],encapsulation:2})}}return v})();const ld=()=>{const v=(0,c.WQX)(Vd.A),m=(0,c.WQX)(a.Ix);return""!==v.getPublicKey()||m.parseUrl("/login")},Tm=[{path:"",pathMatch:"full",redirectTo:"home"},{path:"project/:pubkey",pathMatch:"full",redirectTo:"explore"},{path:"login-redirect",pathMatch:"full",redirectTo:"explore"},{path:"",component:Sc,data:{layout:"empty"},children:[{path:"login",loadChildren:()=>Promise.all([r.e(87),r.e(232)]).then(r.bind(r,6232))},{path:"create",loadChildren:()=>Promise.all([r.e(87),r.e(664)]).then(r.bind(r,9664))}]},{path:"",canActivate:[ld],canActivateChild:[ld],component:Sc,data:{layout:"empty"},children:[{path:"logout",loadChildren:()=>r.e(957).then(r.bind(r,7957))}]},{path:"",canActivate:[ld],canActivateChild:[ld],component:Sc,resolve:{initialData:()=>{const v=(0,c.WQX)(wa);return(0,c.WQX)(Vc),(0,Uc.p)([v.get()])}},children:[{path:"home",loadChildren:()=>Promise.all([r.e(859),r.e(523),r.e(900),r.e(836)]).then(r.bind(r,836))},{path:"explore",loadChildren:()=>Promise.all([r.e(371),r.e(76),r.e(907)]).then(r.bind(r,8288))},{path:"zap",loadChildren:()=>Promise.all([r.e(859),r.e(785)]).then(r.bind(r,8166))},{path:"bookmark",loadChildren:()=>Promise.all([r.e(371),r.e(76),r.e(767)]).then(r.bind(r,6767))},{path:"profile",loadChildren:()=>Promise.all([r.e(859),r.e(523),r.e(371),r.e(556),r.e(900),r.e(76),r.e(394)]).then(r.bind(r,5394))},{path:"profile/:pubkey",loadChildren:()=>Promise.all([r.e(859),r.e(523),r.e(371),r.e(556),r.e(900),r.e(76),r.e(394)]).then(r.bind(r,5394))},{path:"post",loadChildren:()=>Promise.all([r.e(859),r.e(523),r.e(556),r.e(900),r.e(544)]).then(r.bind(r,6544))},{path:"post/:id",loadChildren:()=>Promise.all([r.e(859),r.e(523),r.e(556),r.e(900),r.e(544)]).then(r.bind(r,6544))},{path:"settings",loadChildren:()=>Promise.all([r.e(859),r.e(371),r.e(76),r.e(126)]).then(r.bind(r,6126))},{path:"settings/:id",loadChildren:()=>Promise.all([r.e(859),r.e(371),r.e(76),r.e(126)]).then(r.bind(r,6126))},{path:"chat",loadChildren:()=>Promise.all([r.e(859),r.e(523),r.e(556),r.e(512)]).then(r.bind(r,1512))},{path:"404-not-found",pathMatch:"full",loadChildren:()=>r.e(256).then(r.bind(r,9256))},{path:"**",redirectTo:"404-not-found"}]}];let Kd=(()=>{class v{constructor(){const d=(0,c.WQX)(i.up),_=(0,c.WQX)(il.tp);_.addSvgIconSet(d.bypassSecurityTrustResourceUrl("icons/material-twotone.svg")),_.addSvgIconSetInNamespace("mat_outline",d.bypassSecurityTrustResourceUrl("icons/material-outline.svg")),_.addSvgIconSetInNamespace("mat_solid",d.bypassSecurityTrustResourceUrl("icons/material-solid.svg")),_.addSvgIconSetInNamespace("feather",d.bypassSecurityTrustResourceUrl("icons/feather.svg")),_.addSvgIconSetInNamespace("heroicons_outline",d.bypassSecurityTrustResourceUrl("icons/heroicons-outline.svg")),_.addSvgIconSetInNamespace("heroicons_solid",d.bypassSecurityTrustResourceUrl("icons/heroicons-solid.svg")),_.addSvgIconSetInNamespace("heroicons_mini",d.bypassSecurityTrustResourceUrl("icons/heroicons-mini.svg"))}static{this.\u0275fac=function(_){return new(_||v)}}static{this.\u0275prov=c.jDH({token:v,factory:v.\u0275fac,providedIn:"root"})}}return v})();var Oy=r(8747),Pw=r(1540);let Mm=(()=>{class v{constructor(d){this.httpClient=d}getTranslation(d){return this.httpClient.get(`./i18n/${d}.json`)}static{this.\u0275fac=function(_){return new(_||v)(c.KVO(re.Qq))}}static{this.\u0275prov=c.jDH({token:v,factory:v.\u0275fac,providedIn:"root"})}}return v})();const l_=[{id:"home",title:"Home",type:"basic",icon:"heroicons_outline:home",link:"/home"},{id:"explore",title:"Explore",type:"basic",icon:"heroicons_outline:magnifying-glass",link:"/explore"},{id:"bookmark",title:"Bookmark",type:"basic",icon:"heroicons_outline:bookmark",link:"/bookmark"},{id:"chat",title:"Chat",type:"basic",icon:"heroicons_outline:chat-bubble-left-right",link:"/chat",badge:{title:"0",classes:"px-2 bg-[#086c81] text-white rounded-full"}},{id:"profile",title:"Profile",type:"basic",icon:"heroicons_outline:user",link:"/profile"},{id:"settings",title:"Settings",type:"basic",icon:"heroicons_outline:cog-6-tooth",link:"/settings"}],c_=[{id:"home",title:"Home",type:"basic",icon:"heroicons_outline:home",link:"/home"},{id:"explore",title:"Explore",type:"basic",icon:"heroicons_outline:magnifying-glass",link:"/explore"},{id:"bookmark",title:"Bookmark",type:"basic",icon:"heroicons_outline:bookmark",link:"/bookmark"},{id:"chat",title:"Chat",type:"basic",icon:"heroicons_outline:chat-bubble-left-right",link:"/chat",badge:{title:"27",classes:"px-2 bg-[#086c81] text-white rounded-full"}},{id:"profile",title:"Profile",type:"basic",icon:"heroicons_outline:user",link:"/profile"},{id:"settings",title:"Settings",type:"basic",icon:"heroicons_outline:cog-6-tooth",link:"/settings"}];var u_=r(1238);var Ny=r(2065),lp=r(101),Ly=r(6259),Py=r(1561);const Fy=(0,r(5717).A)(Object.keys,Object);var Uy=Object.prototype.hasOwnProperty;var Vy=r(2808);const km=function d_(v){return(0,Vy.A)(v)?(0,Ly.A)(v):function $y(v){if(!(0,Py.A)(v))return Fy(v);var m=[];for(var d in Object(v))Uy.call(v,d)&&"constructor"!=d&&m.push(d);return m}(v)};var Im=r(3959);var sf=r(4224),h_=r(1369);const zy=function Fw(){return[]};var Om=Object.prototype.propertyIsEnumerable,up=Object.getOwnPropertySymbols;const m_=up?function(v){return null==v?[]:(v=Object(v),function f_(v,m){for(var d=-1,_=null==v?0:v.length,D=0,V=[];++d<_;){var J=v[d];m(J,d,v)&&(V[D++]=J)}return V}(up(v),function(m){return Om.call(v,m)}))}:zy,__=function Gy(v,m){for(var d=-1,_=m.length,D=v.length;++d<_;)v[D+d]=m[d];return v};var Xy=r(5749);const Rm=Object.getOwnPropertySymbols?function(v){for(var m=[];v;)__(m,m_(v)),v=(0,Xy.A)(v);return m}:zy;var Nm=r(9007);const Lm=function dp(v,m,d){var _=m(v);return(0,Nm.A)(v)?_:__(_,d(v))},qy=function Pm(v){return Lm(v,km,m_)},y_=function ud(v){return Lm(v,Im.A,Rm)};var hp=r(3121),Xd=r(9311);const Bm=(0,hp.A)(Xd.A,"DataView");var Um=r(2769);const $m=(0,hp.A)(Xd.A,"Promise"),w_=(0,hp.A)(Xd.A,"Set"),dd=(0,hp.A)(Xd.A,"WeakMap");var E_=r(5688),Yd=r(4435),x_="[object Map]",D_="[object Promise]",A_="[object Set]",S_="[object WeakMap]",T_="[object DataView]",eb=(0,Yd.A)(Bm),tb=(0,Yd.A)(Um.A),jm=(0,Yd.A)($m),jw=(0,Yd.A)(w_),Vw=(0,Yd.A)(dd),Yc=E_.A;(Bm&&Yc(new Bm(new ArrayBuffer(1)))!=T_||Um.A&&Yc(new Um.A)!=x_||$m&&Yc($m.resolve())!=D_||w_&&Yc(new w_)!=A_||dd&&Yc(new dd)!=S_)&&(Yc=function(v){var m=(0,E_.A)(v),d="[object Object]"==m?v.constructor:void 0,_=d?(0,Yd.A)(d):"";if(_)switch(_){case eb:return T_;case tb:return x_;case jm:return D_;case jw:return A_;case Vw:return S_}return m});const M_=Yc;var Ww=Object.prototype.hasOwnProperty;var k_=r(3031);var I_=/\w*$/;var N_=r(4883),L_=N_.A?N_.A.prototype:void 0,Vm=L_?L_.valueOf:void 0;var P_=r(7383);const ob=function j_(v,m,d){var _=v.constructor;switch(m){case"[object ArrayBuffer]":return(0,k_.A)(v);case"[object Boolean]":case"[object Date]":return new _(+v);case"[object DataView]":return function fp(v,m){var d=m?(0,k_.A)(v.buffer):v.buffer;return new v.constructor(d,v.byteOffset,v.byteLength)}(v,d);case"[object Float32Array]":case"[object Float64Array]":case"[object Int8Array]":case"[object Int16Array]":case"[object Int32Array]":case"[object Uint8Array]":case"[object Uint8ClampedArray]":case"[object Uint16Array]":case"[object Uint32Array]":return(0,P_.A)(v,d);case"[object Map]":case"[object Set]":return new _;case"[object Number]":case"[object String]":return new _(v);case"[object RegExp]":return function O_(v){var m=new v.constructor(v.source,I_.exec(v));return m.lastIndex=v.lastIndex,m}(v);case"[object Symbol]":return function Qd(v){return Vm?Object(Vm.call(v)):{}}(v)}};var sb=r(223),V_=r(5303),_p=r(2312);var H_=r(4975),vp=r(8583),yp=vp.A&&vp.A.isMap;const hd=yp?(0,H_.A)(yp):function lf(v){return(0,_p.A)(v)&&"[object Map]"==M_(v)};var z_=r(7999);var Ym=vp.A&&vp.A.isSet;const X_=Ym?(0,H_.A)(Ym):function Xm(v){return(0,_p.A)(v)&&"[object Set]"==M_(v)};var Iu="[object Arguments]",wp="[object Function]",J_="[object Object]",ss={};ss[Iu]=ss["[object Array]"]=ss["[object ArrayBuffer]"]=ss["[object DataView]"]=ss["[object Boolean]"]=ss["[object Date]"]=ss["[object Float32Array]"]=ss["[object Float64Array]"]=ss["[object Int8Array]"]=ss["[object Int16Array]"]=ss["[object Int32Array]"]=ss["[object Map]"]=ss["[object Number]"]=ss[J_]=ss["[object RegExp]"]=ss["[object Set]"]=ss["[object String]"]=ss["[object Symbol]"]=ss["[object Uint8Array]"]=ss["[object Uint8ClampedArray]"]=ss["[object Uint16Array]"]=ss["[object Uint32Array]"]=!0,ss["[object Error]"]=ss[wp]=ss["[object WeakMap]"]=!1;const yb=function uf(v,m,d,_,D,V){var J,we=1&m,Xe=2&m,yt=4&m;if(d&&(J=D?d(v,_,D,V):d(v)),void 0!==J)return J;if(!(0,z_.A)(v))return v;var un=(0,Nm.A)(v);if(un){if(J=function zw(v){var m=v.length,d=new v.constructor(m);return m&&"string"==typeof v[0]&&Ww.call(v,"index")&&(d.index=v.index,d.input=v.input),d}(v),!we)return(0,h_.A)(v,J)}else{var _n=M_(v),gr=_n==wp||"[object GeneratorFunction]"==_n;if((0,V_.A)(v))return(0,sf.A)(v,we);if(_n==J_||_n==Iu||gr&&!D){if(J=Xe||gr?{}:(0,sb.A)(v),!we)return Xe?function Qy(v,m){return(0,lp.A)(v,Rm(v),m)}(v,function cp(v,m){return v&&(0,lp.A)(m,(0,Im.A)(m),v)}(J,v)):function g_(v,m){return(0,lp.A)(v,m_(v),m)}(v,function Hy(v,m){return v&&(0,lp.A)(m,km(m),v)}(J,v))}else{if(!ss[_n])return D?v:{};J=ob(v,_n,we)}}V||(V=new u_.A);var er=V.get(v);if(er)return er;V.set(v,J),X_(v)?v.forEach(function(Ai){J.add(uf(Ai,m,d,Ai,v,V))}):hd(v)&&v.forEach(function(Ai,ko){J.set(ko,uf(Ai,m,d,ko,v,V))});var ti=un?void 0:(yt?Xe?y_:qy:Xe?Im.A:km)(v);return function cd(v,m){for(var d=-1,_=null==v?0:v.length;++d<_&&!1!==m(v[d],d,v););}(ti||v,function(Ai,ko){ti&&(Ai=v[ko=Ai]),(0,Ny.A)(J,ko,uf(Ai,m,d,ko,v,V))}),J},xp=function $i(v){return yb(v,5)},qd=[(()=>{class v{constructor(d){this._angorMockApiService=d,this._defaultNavigation=l_,this._horizontalNavigation=c_,this.registerHandlers()}registerHandlers(){this._angorMockApiService.onGet("api/navigation").reply(()=>(this._horizontalNavigation.forEach(d=>{this._defaultNavigation.forEach(_=>{_.id===d.id&&(d.children=xp(_.children))})}),[200,{default:xp(this._defaultNavigation),horizontal:xp(this._horizontalNavigation)}]))}static{this.\u0275fac=function(_){return new(_||v)(c.KVO(q))}}static{this.\u0275prov=c.jDH({token:v,factory:v.\u0275fac,providedIn:"root"})}}return v})()];let iv=(()=>{class v{constructor(d){this.http=d,this.timestamp=null,this.ngswFilePath="/ngsw.json"}load(){var d=this;return(0,w.A)(function*(){try{const _=yield d.http.get(d.ngswFilePath).toPromise();_&&_.timestamp?(d.timestamp=_.timestamp,console.log("Timestamp successfully loaded:",d.timestamp)):console.error("Invalid data format in ngsw.json")}catch(_){console.error("Error loading ngsw.json:",_)}})()}getTimestamp(){return this.timestamp}loadHash(){return this.http.get(this.ngswFilePath).pipe((0,Os.T)(d=>d.timestamp||null),(0,fm.W)(d=>(console.error("Error fetching ngsw.json hash:",d),(0,T.$)(()=>new Error("Failed to load hash.")))))}static{this.\u0275fac=function(_){return new(_||v)(c.KVO(re.Qq))}}static{this.\u0275prov=c.jDH({token:v,factory:v.\u0275fac,providedIn:"root"})}}return v})();var Jm=r(6433),xb=r(3024);const hf={providers:[function Lf(){return(0,c.ngT)("NgEagerAnimations"),[...Rh]}(),(0,re.$R)(),function rd(v,m={}){return(0,c.EmA)([Bf,Ld,{provide:Ph,useValue:v},{provide:va,useValue:m},{provide:xu,useFactory:$f,deps:[va,c.Agw]},{provide:c.hnV,useFactory:Fh,deps:[c.zZn,Ph,va,c.Agw],multi:!0}])}("ngsw-worker.js",{enabled:!(0,c.naY)(),registrationStrategy:"registerWhenStable:30000"}),{provide:c.hnV,useFactory:function eg(v){return()=>v.load()},deps:[iv,Vd.A,Jm.d],multi:!0},{provide:c.hnV,useFactory:function df(v,m){return(0,w.A)(function*(){const d=v.getPublicKey();d&&(yield m.loadUserProfile(d))})},deps:[Vd.A,Jm.d],multi:!0},{provide:c.hnV,useFactory:function fd(){return()=>{(0,xb.Ts)({theme:"ocean",noBanner:!0,title:"Angor Hub",onAuth:(v,m)=>{}})}},multi:!0},(0,a.lh)(Tm,(0,a.oH)({scrollPositionRestoration:"enabled"})),{provide:rn.MJ,useClass:Yl},{provide:rn.de,useValue:{parse:{dateInput:"D"},display:{dateInput:"DDD",monthYearLabel:"LLL yyyy",dateA11yLabel:"DD",monthYearA11yLabel:"LLLL yyyy"}}},function ei(v){const m=[hr(Qf),mi(Du),yr(sd),Yr(E)];return v.config&&m.push(function eo(v){return(0,c.EmA)([{provide:$c,useValue:Yf(v)}])}(v.config)),v.loader&&m.push(function to(v){return(0,c.EmA)([{provide:Hf,useClass:v}])}(v.loader)),m}({config:{availableLangs:[{id:"en",label:"English"}],defaultLang:"en",fallbackLang:"en",reRenderOnLangChange:!0,prodMode:!0},loader:Mm}),{provide:c.hnV,useFactory:()=>{const v=(0,c.WQX)(Yt),m=v.getDefaultLang();return v.setActiveLang(m),()=>function ap(v,m){const d="object"==typeof m;return new Promise((_,D)=>{const V=new Pw.Ms({next:J=>{_(J),V.unsubscribe()},error:D,complete:()=>{d?_(m.defaultValue):D(new Oy.G)}});v.subscribe(V)})}(v.load(m))},multi:!0},[{provide:c.Z63,useValue:()=>(0,c.WQX)(Kd),multi:!0}],(v=>{const m=[{provide:rn.N,useValue:{doctype:!0,theme:!1,version:!0}},{provide:bn.U$,useValue:{appearance:"fill"}},{provide:C,useValue:v?.mockApi?.delay??0},{provide:me.t,useValue:v?.angor??{}},(0,c.oKB)(gn.hM),{provide:c.Z63,useValue:()=>(0,c.WQX)(be.m),multi:!0},(0,re.$R)((0,re.b$)([ce])),{provide:c.Z63,useValue:()=>(0,c.WQX)(xe),multi:!0},{provide:c.Z63,useValue:()=>(0,c.WQX)(ue.l),multi:!0},{provide:c.Z63,useValue:()=>(0,c.WQX)(Be),multi:!0},{provide:c.Z63,useValue:()=>(0,c.WQX)(bt),multi:!0},{provide:c.Z63,useValue:()=>(0,c.WQX)(lt.Q),multi:!0}];return v?.mockApi?.services&&m.push((0,re.$R)((0,re.b$)([ae])),{provide:c.hnV,deps:[...v.mockApi.services],useFactory:()=>()=>null,multi:!0}),m})({mockApi:{delay:0,services:qd},angor:JSON.parse(localStorage.getItem("angorConfig"))??{layout:"classic",scheme:"light",screens:{sm:"600px",md:"960px",lg:"1280px",xl:"1440px"},theme:"theme-brand",themes:[{id:"theme-brand",name:"Brand"},{id:"theme-default",name:"Default"},{id:"theme-teal",name:"Teal"},{id:"theme-rose",name:"Rose"},{id:"theme-purple",name:"Purple"},{id:"theme-amber",name:"Amber"}]}})]};(0,i.B8)(y,hf).catch(v=>console.error(v))},9566:(o,s)=>{"use strict";s.byteLength=function T(q){var re=C(q),se=re[1];return 3*(re[0]+se)/4-se},s.toByteArray=function M(q){var re,xe,pe=C(q),se=pe[0],ae=pe[1],me=new a(function S(q,re,pe){return 3*(re+pe)/4-pe}(0,se,ae)),be=0,Oe=ae>0?se-4:se;for(xe=0;xe>16&255,me[be++]=re>>8&255,me[be++]=255&re;return 2===ae&&(re=i[q.charCodeAt(xe)]<<2|i[q.charCodeAt(xe+1)]>>4,me[be++]=255&re),1===ae&&(re=i[q.charCodeAt(xe)]<<10|i[q.charCodeAt(xe+1)]<<4|i[q.charCodeAt(xe+2)]>>2,me[be++]=re>>8&255,me[be++]=255&re),me},s.fromByteArray=function Z(q){for(var re,pe=q.length,se=pe%3,ae=[],be=0,Oe=pe-se;beOe?Oe:be+16383));return 1===se?ae.push(r[(re=q[pe-1])>>2]+r[re<<4&63]+"=="):2===se&&ae.push(r[(re=(q[pe-2]<<8)+q[pe-1])>>10]+r[re>>4&63]+r[re<<2&63]+"="),ae.join("")};for(var r=[],i=[],a=typeof Uint8Array<"u"?Uint8Array:Array,c="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/",y=0;y<64;++y)r[y]=c[y],i[c.charCodeAt(y)]=y;function C(q){var re=q.length;if(re%4>0)throw new Error("Invalid string. Length must be a multiple of 4");var pe=q.indexOf("=");return-1===pe&&(pe=re),[pe,pe===re?0:4-pe%4]}function O(q){return r[q>>18&63]+r[q>>12&63]+r[q>>6&63]+r[63&q]}function L(q,re,pe){for(var ae=[],me=re;me{"use strict";const a=r(9566),c=r(9859),y="function"==typeof Symbol&&"function"==typeof Symbol.for?Symbol.for("nodejs.util.inspect.custom"):null;s.hp=S,s.IS=50;const w=2147483647;function T(z){if(z>w)throw new RangeError('The value "'+z+'" is invalid for option "size"');const N=new Uint8Array(z);return Object.setPrototypeOf(N,S.prototype),N}function S(z,N,W){if("number"==typeof z){if("string"==typeof N)throw new TypeError('The "string" argument must be of type string. Received type number');return Z(z)}return M(z,N,W)}function M(z,N,W){if("string"==typeof z)return function q(z,N){if(("string"!=typeof N||""===N)&&(N="utf8"),!S.isEncoding(N))throw new TypeError("Unknown encoding: "+N);const W=0|Oe(z,N);let Le=T(W);const ft=Le.write(z,N);return ft!==W&&(Le=Le.slice(0,ft)),Le}(z,N);if(ArrayBuffer.isView(z))return function pe(z){if(pr(z,Uint8Array)){const N=new Uint8Array(z);return se(N.buffer,N.byteOffset,N.byteLength)}return re(z)}(z);if(null==z)throw new TypeError("The first argument must be one of type string, Buffer, ArrayBuffer, Array, or Array-like Object. Received type "+typeof z);if(pr(z,ArrayBuffer)||z&&pr(z.buffer,ArrayBuffer)||typeof SharedArrayBuffer<"u"&&(pr(z,SharedArrayBuffer)||z&&pr(z.buffer,SharedArrayBuffer)))return se(z,N,W);if("number"==typeof z)throw new TypeError('The "value" argument must not be of type number. Received type number');const Le=z.valueOf&&z.valueOf();if(null!=Le&&Le!==z)return S.from(Le,N,W);const ft=function ae(z){if(S.isBuffer(z)){const N=0|me(z.length),W=T(N);return 0===W.length||z.copy(W,0,0,N),W}return void 0!==z.length?"number"!=typeof z.length||cn(z.length)?T(0):re(z):"Buffer"===z.type&&Array.isArray(z.data)?re(z.data):void 0}(z);if(ft)return ft;if(typeof Symbol<"u"&&null!=Symbol.toPrimitive&&"function"==typeof z[Symbol.toPrimitive])return S.from(z[Symbol.toPrimitive]("string"),N,W);throw new TypeError("The first argument must be one of type string, Buffer, ArrayBuffer, Array, or Array-like Object. Received type "+typeof z)}function O(z){if("number"!=typeof z)throw new TypeError('"size" argument must be of type number');if(z<0)throw new RangeError('The value "'+z+'" is invalid for option "size"')}function Z(z){return O(z),T(z<0?0:0|me(z))}function re(z){const N=z.length<0?0:0|me(z.length),W=T(N);for(let Le=0;Le=w)throw new RangeError("Attempt to allocate Buffer larger than maximum size: 0x"+w.toString(16)+" bytes");return 0|z}function Oe(z,N){if(S.isBuffer(z))return z.length;if(ArrayBuffer.isView(z)||pr(z,ArrayBuffer))return z.byteLength;if("string"!=typeof z)throw new TypeError('The "string" argument must be one of type string, Buffer, or ArrayBuffer. Received type '+typeof z);const W=z.length,Le=arguments.length>2&&!0===arguments[2];if(!Le&&0===W)return 0;let ft=!1;for(;;)switch(N){case"ascii":case"latin1":case"binary":return W;case"utf8":case"utf-8":return en(z).length;case"ucs2":case"ucs-2":case"utf16le":case"utf-16le":return 2*W;case"hex":return W>>>1;case"base64":return Nr(z).length;default:if(ft)return Le?-1:en(z).length;N=(""+N).toLowerCase(),ft=!0}}function xe(z,N,W){let Le=!1;if((void 0===N||N<0)&&(N=0),N>this.length||((void 0===W||W>this.length)&&(W=this.length),W<=0)||(W>>>=0)<=(N>>>=0))return"";for(z||(z="utf8");;)switch(z){case"hex":return qe(this,N,W);case"utf8":case"utf-8":return rn(this,N,W);case"ascii":return Vn(this,N,W);case"latin1":case"binary":return yn(this,N,W);case"base64":return lt(this,N,W);case"ucs2":case"ucs-2":case"utf16le":case"utf-16le":return _t(this,N,W);default:if(Le)throw new TypeError("Unknown encoding: "+z);z=(z+"").toLowerCase(),Le=!0}}function De(z,N,W){const Le=z[N];z[N]=z[W],z[W]=Le}function ce(z,N,W,Le,ft){if(0===z.length)return-1;if("string"==typeof W?(Le=W,W=0):W>2147483647?W=2147483647:W<-2147483648&&(W=-2147483648),cn(W=+W)&&(W=ft?0:z.length-1),W<0&&(W=z.length+W),W>=z.length){if(ft)return-1;W=z.length-1}else if(W<0){if(!ft)return-1;W=0}if("string"==typeof N&&(N=S.from(N,Le)),S.isBuffer(N))return 0===N.length?-1:ue(z,N,W,Le,ft);if("number"==typeof N)return N&=255,"function"==typeof Uint8Array.prototype.indexOf?ft?Uint8Array.prototype.indexOf.call(z,N,W):Uint8Array.prototype.lastIndexOf.call(z,N,W):ue(z,[N],W,Le,ft);throw new TypeError("val must be string, number or Buffer")}function ue(z,N,W,Le,ft){let dn,mt=1,St=z.length,Tn=N.length;if(void 0!==Le&&("ucs2"===(Le=String(Le).toLowerCase())||"ucs-2"===Le||"utf16le"===Le||"utf-16le"===Le)){if(z.length<2||N.length<2)return-1;mt=2,St/=2,Tn/=2,W/=2}function an(In,sr){return 1===mt?In[sr]:In.readUInt16BE(sr*mt)}if(ft){let In=-1;for(dn=W;dnSt&&(W=St-Tn),dn=W;dn>=0;dn--){let In=!0;for(let sr=0;srft&&(Le=ft):Le=ft;const mt=N.length;let St;for(Le>mt/2&&(Le=mt/2),St=0;St>8,ft=W%256,mt.push(ft),mt.push(Le);return mt}(N,z.length-W),z,W,Le)}function lt(z,N,W){return a.fromByteArray(0===N&&W===z.length?z:z.slice(N,W))}function rn(z,N,W){W=Math.min(z.length,W);const Le=[];let ft=N;for(;ft239?4:mt>223?3:mt>191?2:1;if(ft+Tn<=W){let an,dn,In,sr;switch(Tn){case 1:mt<128&&(St=mt);break;case 2:an=z[ft+1],128==(192&an)&&(sr=(31&mt)<<6|63&an,sr>127&&(St=sr));break;case 3:an=z[ft+1],dn=z[ft+2],128==(192&an)&&128==(192&dn)&&(sr=(15&mt)<<12|(63&an)<<6|63&dn,sr>2047&&(sr<55296||sr>57343)&&(St=sr));break;case 4:an=z[ft+1],dn=z[ft+2],In=z[ft+3],128==(192&an)&&128==(192&dn)&&128==(192&In)&&(sr=(15&mt)<<18|(63&an)<<12|(63&dn)<<6|63&In,sr>65535&&sr<1114112&&(St=sr))}}null===St?(St=65533,Tn=1):St>65535&&(St-=65536,Le.push(St>>>10&1023|55296),St=56320|1023&St),Le.push(St),ft+=Tn}return function bn(z){const N=z.length;if(N<=gn)return String.fromCharCode.apply(String,z);let W="",Le=0;for(;Left.length?(S.isBuffer(St)||(St=S.from(St)),St.copy(ft,mt)):Uint8Array.prototype.set.call(ft,St,mt);else{if(!S.isBuffer(St))throw new TypeError('"list" argument must be an Array of Buffers');St.copy(ft,mt)}mt+=St.length}return ft},S.byteLength=Oe,S.prototype._isBuffer=!0,S.prototype.swap16=function(){const N=this.length;if(N%2!=0)throw new RangeError("Buffer size must be a multiple of 16-bits");for(let W=0;WW&&(N+=" ... "),""},y&&(S.prototype[y]=S.prototype.inspect),S.prototype.compare=function(N,W,Le,ft,mt){if(pr(N,Uint8Array)&&(N=S.from(N,N.offset,N.byteLength)),!S.isBuffer(N))throw new TypeError('The "target" argument must be one of type Buffer or Uint8Array. Received type '+typeof N);if(void 0===W&&(W=0),void 0===Le&&(Le=N?N.length:0),void 0===ft&&(ft=0),void 0===mt&&(mt=this.length),W<0||Le>N.length||ft<0||mt>this.length)throw new RangeError("out of range index");if(ft>=mt&&W>=Le)return 0;if(ft>=mt)return-1;if(W>=Le)return 1;if(this===N)return 0;let St=(mt>>>=0)-(ft>>>=0),Tn=(Le>>>=0)-(W>>>=0);const an=Math.min(St,Tn),dn=this.slice(ft,mt),In=N.slice(W,Le);for(let sr=0;sr>>=0,isFinite(Le)?(Le>>>=0,void 0===ft&&(ft="utf8")):(ft=Le,Le=void 0)}const mt=this.length-W;if((void 0===Le||Le>mt)&&(Le=mt),N.length>0&&(Le<0||W<0)||W>this.length)throw new RangeError("Attempt to write outside buffer bounds");ft||(ft="utf8");let St=!1;for(;;)switch(ft){case"hex":return Ce(this,N,W,Le);case"utf8":case"utf-8":return Be(this,N,W,Le);case"ascii":case"latin1":case"binary":return at(this,N,W,Le);case"base64":return dt(this,N,W,Le);case"ucs2":case"ucs-2":case"utf16le":case"utf-16le":return bt(this,N,W,Le);default:if(St)throw new TypeError("Unknown encoding: "+ft);ft=(""+ft).toLowerCase(),St=!0}},S.prototype.toJSON=function(){return{type:"Buffer",data:Array.prototype.slice.call(this._arr||this,0)}};const gn=4096;function Vn(z,N,W){let Le="";W=Math.min(z.length,W);for(let ft=N;ftLe)&&(W=Le);let ft="";for(let mt=N;mtW)throw new RangeError("Trying to access beyond buffer length")}function $e(z,N,W,Le,ft,mt){if(!S.isBuffer(z))throw new TypeError('"buffer" argument must be a Buffer instance');if(N>ft||Nz.length)throw new RangeError("Index out of range")}function Ft(z,N,W,Le,ft){Xt(N,Le,ft,z,W,7);let mt=Number(N&BigInt(4294967295));z[W++]=mt,mt>>=8,z[W++]=mt,mt>>=8,z[W++]=mt,mt>>=8,z[W++]=mt;let St=Number(N>>BigInt(32)&BigInt(4294967295));return z[W++]=St,St>>=8,z[W++]=St,St>>=8,z[W++]=St,St>>=8,z[W++]=St,W}function Ke(z,N,W,Le,ft){Xt(N,Le,ft,z,W,7);let mt=Number(N&BigInt(4294967295));z[W+7]=mt,mt>>=8,z[W+6]=mt,mt>>=8,z[W+5]=mt,mt>>=8,z[W+4]=mt;let St=Number(N>>BigInt(32)&BigInt(4294967295));return z[W+3]=St,St>>=8,z[W+2]=St,St>>=8,z[W+1]=St,St>>=8,z[W]=St,W+8}function Ze(z,N,W,Le,ft,mt){if(W+Le>z.length)throw new RangeError("Index out of range");if(W<0)throw new RangeError("Index out of range")}function it(z,N,W,Le,ft){return N=+N,W>>>=0,ft||Ze(z,0,W,4),c.write(z,N,W,Le,23,4),W+4}function Ot(z,N,W,Le,ft){return N=+N,W>>>=0,ft||Ze(z,0,W,8),c.write(z,N,W,Le,52,8),W+8}S.prototype.slice=function(N,W){const Le=this.length;(N=~~N)<0?(N+=Le)<0&&(N=0):N>Le&&(N=Le),(W=void 0===W?Le:~~W)<0?(W+=Le)<0&&(W=0):W>Le&&(W=Le),W>>=0,W>>>=0,Le||ze(N,W,this.length);let ft=this[N],mt=1,St=0;for(;++St>>=0,W>>>=0,Le||ze(N,W,this.length);let ft=this[N+--W],mt=1;for(;W>0&&(mt*=256);)ft+=this[N+--W]*mt;return ft},S.prototype.readUint8=S.prototype.readUInt8=function(N,W){return N>>>=0,W||ze(N,1,this.length),this[N]},S.prototype.readUint16LE=S.prototype.readUInt16LE=function(N,W){return N>>>=0,W||ze(N,2,this.length),this[N]|this[N+1]<<8},S.prototype.readUint16BE=S.prototype.readUInt16BE=function(N,W){return N>>>=0,W||ze(N,2,this.length),this[N]<<8|this[N+1]},S.prototype.readUint32LE=S.prototype.readUInt32LE=function(N,W){return N>>>=0,W||ze(N,4,this.length),(this[N]|this[N+1]<<8|this[N+2]<<16)+16777216*this[N+3]},S.prototype.readUint32BE=S.prototype.readUInt32BE=function(N,W){return N>>>=0,W||ze(N,4,this.length),16777216*this[N]+(this[N+1]<<16|this[N+2]<<8|this[N+3])},S.prototype.readBigUInt64LE=ke(function(N){Mt(N>>>=0,"offset");const W=this[N],Le=this[N+7];(void 0===W||void 0===Le)&&Kt(N,this.length-8);const ft=W+256*this[++N]+65536*this[++N]+this[++N]*2**24,mt=this[++N]+256*this[++N]+65536*this[++N]+Le*2**24;return BigInt(ft)+(BigInt(mt)<>>=0,"offset");const W=this[N],Le=this[N+7];(void 0===W||void 0===Le)&&Kt(N,this.length-8);const ft=W*2**24+65536*this[++N]+256*this[++N]+this[++N],mt=this[++N]*2**24+65536*this[++N]+256*this[++N]+Le;return(BigInt(ft)<>>=0,W>>>=0,Le||ze(N,W,this.length);let ft=this[N],mt=1,St=0;for(;++St=mt&&(ft-=Math.pow(2,8*W)),ft},S.prototype.readIntBE=function(N,W,Le){N>>>=0,W>>>=0,Le||ze(N,W,this.length);let ft=W,mt=1,St=this[N+--ft];for(;ft>0&&(mt*=256);)St+=this[N+--ft]*mt;return mt*=128,St>=mt&&(St-=Math.pow(2,8*W)),St},S.prototype.readInt8=function(N,W){return N>>>=0,W||ze(N,1,this.length),128&this[N]?-1*(255-this[N]+1):this[N]},S.prototype.readInt16LE=function(N,W){N>>>=0,W||ze(N,2,this.length);const Le=this[N]|this[N+1]<<8;return 32768&Le?4294901760|Le:Le},S.prototype.readInt16BE=function(N,W){N>>>=0,W||ze(N,2,this.length);const Le=this[N+1]|this[N]<<8;return 32768&Le?4294901760|Le:Le},S.prototype.readInt32LE=function(N,W){return N>>>=0,W||ze(N,4,this.length),this[N]|this[N+1]<<8|this[N+2]<<16|this[N+3]<<24},S.prototype.readInt32BE=function(N,W){return N>>>=0,W||ze(N,4,this.length),this[N]<<24|this[N+1]<<16|this[N+2]<<8|this[N+3]},S.prototype.readBigInt64LE=ke(function(N){Mt(N>>>=0,"offset");const W=this[N],Le=this[N+7];return(void 0===W||void 0===Le)&&Kt(N,this.length-8),(BigInt(this[N+4]+256*this[N+5]+65536*this[N+6]+(Le<<24))<>>=0,"offset");const W=this[N],Le=this[N+7];(void 0===W||void 0===Le)&&Kt(N,this.length-8);const ft=(W<<24)+65536*this[++N]+256*this[++N]+this[++N];return(BigInt(ft)<>>=0,W||ze(N,4,this.length),c.read(this,N,!0,23,4)},S.prototype.readFloatBE=function(N,W){return N>>>=0,W||ze(N,4,this.length),c.read(this,N,!1,23,4)},S.prototype.readDoubleLE=function(N,W){return N>>>=0,W||ze(N,8,this.length),c.read(this,N,!0,52,8)},S.prototype.readDoubleBE=function(N,W){return N>>>=0,W||ze(N,8,this.length),c.read(this,N,!1,52,8)},S.prototype.writeUintLE=S.prototype.writeUIntLE=function(N,W,Le,ft){N=+N,W>>>=0,Le>>>=0,ft||$e(this,N,W,Le,Math.pow(2,8*Le)-1,0);let mt=1,St=0;for(this[W]=255&N;++St>>=0,Le>>>=0,ft||$e(this,N,W,Le,Math.pow(2,8*Le)-1,0);let mt=Le-1,St=1;for(this[W+mt]=255&N;--mt>=0&&(St*=256);)this[W+mt]=N/St&255;return W+Le},S.prototype.writeUint8=S.prototype.writeUInt8=function(N,W,Le){return N=+N,W>>>=0,Le||$e(this,N,W,1,255,0),this[W]=255&N,W+1},S.prototype.writeUint16LE=S.prototype.writeUInt16LE=function(N,W,Le){return N=+N,W>>>=0,Le||$e(this,N,W,2,65535,0),this[W]=255&N,this[W+1]=N>>>8,W+2},S.prototype.writeUint16BE=S.prototype.writeUInt16BE=function(N,W,Le){return N=+N,W>>>=0,Le||$e(this,N,W,2,65535,0),this[W]=N>>>8,this[W+1]=255&N,W+2},S.prototype.writeUint32LE=S.prototype.writeUInt32LE=function(N,W,Le){return N=+N,W>>>=0,Le||$e(this,N,W,4,4294967295,0),this[W+3]=N>>>24,this[W+2]=N>>>16,this[W+1]=N>>>8,this[W]=255&N,W+4},S.prototype.writeUint32BE=S.prototype.writeUInt32BE=function(N,W,Le){return N=+N,W>>>=0,Le||$e(this,N,W,4,4294967295,0),this[W]=N>>>24,this[W+1]=N>>>16,this[W+2]=N>>>8,this[W+3]=255&N,W+4},S.prototype.writeBigUInt64LE=ke(function(N,W=0){return Ft(this,N,W,BigInt(0),BigInt("0xffffffffffffffff"))}),S.prototype.writeBigUInt64BE=ke(function(N,W=0){return Ke(this,N,W,BigInt(0),BigInt("0xffffffffffffffff"))}),S.prototype.writeIntLE=function(N,W,Le,ft){if(N=+N,W>>>=0,!ft){const an=Math.pow(2,8*Le-1);$e(this,N,W,Le,an-1,-an)}let mt=0,St=1,Tn=0;for(this[W]=255&N;++mt>>=0,!ft){const an=Math.pow(2,8*Le-1);$e(this,N,W,Le,an-1,-an)}let mt=Le-1,St=1,Tn=0;for(this[W+mt]=255&N;--mt>=0&&(St*=256);)N<0&&0===Tn&&0!==this[W+mt+1]&&(Tn=1),this[W+mt]=(N/St|0)-Tn&255;return W+Le},S.prototype.writeInt8=function(N,W,Le){return N=+N,W>>>=0,Le||$e(this,N,W,1,127,-128),N<0&&(N=255+N+1),this[W]=255&N,W+1},S.prototype.writeInt16LE=function(N,W,Le){return N=+N,W>>>=0,Le||$e(this,N,W,2,32767,-32768),this[W]=255&N,this[W+1]=N>>>8,W+2},S.prototype.writeInt16BE=function(N,W,Le){return N=+N,W>>>=0,Le||$e(this,N,W,2,32767,-32768),this[W]=N>>>8,this[W+1]=255&N,W+2},S.prototype.writeInt32LE=function(N,W,Le){return N=+N,W>>>=0,Le||$e(this,N,W,4,2147483647,-2147483648),this[W]=255&N,this[W+1]=N>>>8,this[W+2]=N>>>16,this[W+3]=N>>>24,W+4},S.prototype.writeInt32BE=function(N,W,Le){return N=+N,W>>>=0,Le||$e(this,N,W,4,2147483647,-2147483648),N<0&&(N=4294967295+N+1),this[W]=N>>>24,this[W+1]=N>>>16,this[W+2]=N>>>8,this[W+3]=255&N,W+4},S.prototype.writeBigInt64LE=ke(function(N,W=0){return Ft(this,N,W,-BigInt("0x8000000000000000"),BigInt("0x7fffffffffffffff"))}),S.prototype.writeBigInt64BE=ke(function(N,W=0){return Ke(this,N,W,-BigInt("0x8000000000000000"),BigInt("0x7fffffffffffffff"))}),S.prototype.writeFloatLE=function(N,W,Le){return it(this,N,W,!0,Le)},S.prototype.writeFloatBE=function(N,W,Le){return it(this,N,W,!1,Le)},S.prototype.writeDoubleLE=function(N,W,Le){return Ot(this,N,W,!0,Le)},S.prototype.writeDoubleBE=function(N,W,Le){return Ot(this,N,W,!1,Le)},S.prototype.copy=function(N,W,Le,ft){if(!S.isBuffer(N))throw new TypeError("argument should be a Buffer");if(Le||(Le=0),!ft&&0!==ft&&(ft=this.length),W>=N.length&&(W=N.length),W||(W=0),ft>0&&ft=this.length)throw new RangeError("Index out of range");if(ft<0)throw new RangeError("sourceEnd out of bounds");ft>this.length&&(ft=this.length),N.length-W>>=0,Le=void 0===Le?this.length:Le>>>0,N||(N=0),"number"==typeof N)for(mt=W;mt=Le+4;W-=3)N=`_${z.slice(W-3,W)}${N}`;return`${z.slice(0,W)}${N}`}function Xt(z,N,W,Le,ft,mt){if(z>W||z3?0===N||N===BigInt(0)?`>= 0${St} and < 2${St} ** ${8*(mt+1)}${St}`:`>= -(2${St} ** ${8*(mt+1)-1}${St}) and < 2 ** ${8*(mt+1)-1}${St}`:`>= ${N}${St} and <= ${W}${St}`,new $t.ERR_OUT_OF_RANGE("value",Tn,z)}!function st(z,N,W){Mt(N,"offset"),(void 0===z[N]||void 0===z[N+W])&&Kt(N,z.length-(W+1))}(Le,ft,mt)}function Mt(z,N){if("number"!=typeof z)throw new $t.ERR_INVALID_ARG_TYPE(N,"number",z)}function Kt(z,N,W){throw Math.floor(z)!==z?(Mt(z,W),new $t.ERR_OUT_OF_RANGE(W||"offset","an integer",z)):N<0?new $t.ERR_BUFFER_OUT_OF_BOUNDS:new $t.ERR_OUT_OF_RANGE(W||"offset",`>= ${W?1:0} and <= ${N}`,z)}Te("ERR_BUFFER_OUT_OF_BOUNDS",function(z){return z?`${z} is outside of buffer bounds`:"Attempt to access memory outside buffer bounds"},RangeError),Te("ERR_INVALID_ARG_TYPE",function(z,N){return`The "${z}" argument must be of type number. Received type ${typeof N}`},TypeError),Te("ERR_OUT_OF_RANGE",function(z,N,W){let Le=`The value of "${z}" is out of range.`,ft=W;return Number.isInteger(W)&&Math.abs(W)>2**32?ft=Ee(String(W)):"bigint"==typeof W&&(ft=String(W),(W>BigInt(2)**BigInt(32)||W<-(BigInt(2)**BigInt(32)))&&(ft=Ee(ft)),ft+="n"),Le+=` It must be ${N}. Received ${ft}`,Le},RangeError);const rt=/[^+/0-9A-Za-z-_]/g;function en(z,N){let W;N=N||1/0;const Le=z.length;let ft=null;const mt=[];for(let St=0;St55295&&W<57344){if(!ft){if(W>56319){(N-=3)>-1&&mt.push(239,191,189);continue}if(St+1===Le){(N-=3)>-1&&mt.push(239,191,189);continue}ft=W;continue}if(W<56320){(N-=3)>-1&&mt.push(239,191,189),ft=W;continue}W=65536+(ft-55296<<10|W-56320)}else ft&&(N-=3)>-1&&mt.push(239,191,189);if(ft=null,W<128){if((N-=1)<0)break;mt.push(W)}else if(W<2048){if((N-=2)<0)break;mt.push(W>>6|192,63&W|128)}else if(W<65536){if((N-=3)<0)break;mt.push(W>>12|224,W>>6&63|128,63&W|128)}else{if(!(W<1114112))throw new Error("Invalid code point");if((N-=4)<0)break;mt.push(W>>18|240,W>>12&63|128,W>>6&63|128,63&W|128)}}return mt}function Nr(z){return a.toByteArray(function Vt(z){if((z=(z=z.split("=")[0]).trim().replace(rt,"")).length<2)return"";for(;z.length%4!=0;)z+="=";return z}(z))}function Rn(z,N,W,Le){let ft;for(ft=0;ft=N.length||ft>=z.length);++ft)N[ft+W]=z[ft];return ft}function pr(z,N){return z instanceof N||null!=z&&null!=z.constructor&&null!=z.constructor.name&&z.constructor.name===N.name}function cn(z){return z!=z}const Fe=function(){const z="0123456789abcdef",N=new Array(256);for(let W=0;W<16;++W){const Le=16*W;for(let ft=0;ft<16;++ft)N[Le+ft]=z[W]+z[ft]}return N}();function ke(z){return typeof BigInt>"u"?Je:z}function Je(){throw new Error("BigInt not supported")}},9859:(o,s)=>{s.read=function(r,i,a,c,y){var w,C,T=8*y-c-1,S=(1<>1,O=-7,L=a?y-1:0,Z=a?-1:1,q=r[i+L];for(L+=Z,w=q&(1<<-O)-1,q>>=-O,O+=T;O>0;w=256*w+r[i+L],L+=Z,O-=8);for(C=w&(1<<-O)-1,w>>=-O,O+=c;O>0;C=256*C+r[i+L],L+=Z,O-=8);if(0===w)w=1-M;else{if(w===S)return C?NaN:1/0*(q?-1:1);C+=Math.pow(2,c),w-=M}return(q?-1:1)*C*Math.pow(2,w-c)},s.write=function(r,i,a,c,y,w){var C,T,S,M=8*w-y-1,O=(1<>1,Z=23===y?Math.pow(2,-24)-Math.pow(2,-77):0,q=c?0:w-1,re=c?1:-1,pe=i<0||0===i&&1/i<0?1:0;for(i=Math.abs(i),isNaN(i)||i===1/0?(T=isNaN(i)?1:0,C=O):(C=Math.floor(Math.log(i)/Math.LN2),i*(S=Math.pow(2,-C))<1&&(C--,S*=2),(i+=C+L>=1?Z/S:Z*Math.pow(2,1-L))*S>=2&&(C++,S/=2),C+L>=O?(T=0,C=O):C+L>=1?(T=(i*S-1)*Math.pow(2,y),C+=L):(T=i*Math.pow(2,L-1)*Math.pow(2,y),C=0));y>=8;r[a+q]=255&T,q+=re,T/=256,y-=8);for(C=C<0;r[a+q]=255&C,q+=re,C/=256,M-=8);r[a+q-re]|=128*pe}},230:o=>{o.exports=function a(c,y,w){function C(M,O){if(!y[M]){if(!c[M]){if(T)return T(M,!0);var Z=new Error("Cannot find module '"+M+"'");throw Z.code="MODULE_NOT_FOUND",Z}var q=y[M]={exports:{}};c[M][0].call(q.exports,function(re){return C(c[M][1][re]||re)},q,q.exports,a,c,y,w)}return y[M].exports}for(var T=void 0,S=0;S"u"&&a(3);var L=Promise;function Z(ve,Ye){Ye&&ve.then(function(Ne){Ye(null,Ne)},function(Ne){Ye(Ne)})}function q(ve,Ye,Ne){"function"==typeof Ye&&ve.then(Ye),"function"==typeof Ne&&ve.catch(Ne)}function re(ve){return"string"!=typeof ve&&(console.warn(ve+" used as a key, but it is not a string."),ve=String(ve)),ve}function pe(){if(arguments.length&&"function"==typeof arguments[arguments.length-1])return arguments[arguments.length-1]}var se="local-forage-detect-blob-support",ae=void 0,me={},be=Object.prototype.toString,Oe="readonly",xe="readwrite";function De(ve){for(var Ye=ve.length,Ne=new ArrayBuffer(Ye),gt=new Uint8Array(Ne),Ht=0;Ht=43)}}).catch(function(){return!1})}(ve).then(function(Ye){return ae=Ye})}function Ce(ve){var Ye=me[ve.name],Ne={};Ne.promise=new L(function(gt,Ht){Ne.resolve=gt,Ne.reject=Ht}),Ye.deferredOperations.push(Ne),Ye.dbReady=Ye.dbReady?Ye.dbReady.then(function(){return Ne.promise}):Ne.promise}function Be(ve){var Ne=me[ve.name].deferredOperations.pop();if(Ne)return Ne.resolve(),Ne.promise}function at(ve,Ye){var gt=me[ve.name].deferredOperations.pop();if(gt)return gt.reject(Ye),gt.promise}function dt(ve,Ye){return new L(function(Ne,gt){if(me[ve.name]=me[ve.name]||{forages:[],db:null,dbReady:null,deferredOperations:[]},ve.db){if(!Ye)return Ne(ve.db);Ce(ve),ve.db.close()}var Ht=[ve.name];Ye&&Ht.push(ve.version);var kt=S.open.apply(S,Ht);Ye&&(kt.onupgradeneeded=function(hn){var Dn=kt.result;try{Dn.createObjectStore(ve.storeName),hn.oldVersion<=1&&Dn.createObjectStore(se)}catch(Cn){if("ConstraintError"!==Cn.name)throw Cn;console.warn('The database "'+ve.name+'" has been upgraded from version '+hn.oldVersion+" to version "+hn.newVersion+', but the storage "'+ve.storeName+'" already exists.')}}),kt.onerror=function(hn){hn.preventDefault(),gt(kt.error)},kt.onsuccess=function(){var hn=kt.result;hn.onversionchange=function(Dn){Dn.target.close()},Ne(hn),Be(ve)}})}function bt(ve){return dt(ve,!1)}function lt(ve){return dt(ve,!0)}function rn(ve,Ye){if(!ve.db)return!0;var Ne=!ve.db.objectStoreNames.contains(ve.storeName),Ht=ve.version>ve.db.version;if(ve.versionve.version&&(ve.version=kt)}return!0}return!1}function bn(ve){return O([De(atob(ve.data))],{type:ve.type})}function Vn(ve){return ve&&ve.__local_forage_encoded_blob}function yn(ve){var Ye=this,Ne=Ye._initReady().then(function(){var gt=me[Ye._dbInfo.name];if(gt&>.dbReady)return gt.dbReady});return q(Ne,ve,ve),Ne}function _t(ve,Ye,Ne,gt){void 0===gt&&(gt=1);try{var Ht=ve.db.transaction(ve.storeName,Ye);Ne(null,Ht)}catch(kt){if(gt>0&&(!ve.db||"InvalidStateError"===kt.name||"NotFoundError"===kt.name))return L.resolve().then(function(){if(!ve.db||"NotFoundError"===kt.name&&!ve.db.objectStoreNames.contains(ve.storeName)&&ve.version<=ve.db.version)return ve.db&&(ve.version=ve.db.version+1),lt(ve)}).then(function(){return function qe(ve){Ce(ve);for(var Ye=me[ve.name],Ne=Ye.forages,gt=0;gt>4,jn[Ht++]=(15&hn)<<4|Dn>>2,jn[Ht++]=(3&Dn)<<6|63&Cn;return Nn}function St(ve){var gt,Ye=new Uint8Array(ve),Ne="";for(gt=0;gt>2],Ne+=Kt[(3&Ye[gt])<<4|Ye[gt+1]>>4],Ne+=Kt[(15&Ye[gt+1])<<2|Ye[gt+2]>>6],Ne+=Kt[63&Ye[gt+2]];return Ye.length%3==2?Ne=Ne.substring(0,Ne.length-1)+"=":Ye.length%3==1&&(Ne=Ne.substring(0,Ne.length-2)+"=="),Ne}var dn={serialize:function Tn(ve,Ye){var Ne="";if(ve&&(Ne=ft.call(ve)),ve&&("[object ArrayBuffer]"===Ne||ve.buffer&&"[object ArrayBuffer]"===ft.call(ve.buffer))){var gt,Ht=en;ve instanceof ArrayBuffer?(gt=ve,Ht+=Kn):(gt=ve.buffer,"[object Int8Array]"===Ne?Ht+="si08":"[object Uint8Array]"===Ne?Ht+="ui08":"[object Uint8ClampedArray]"===Ne?Ht+="uic8":"[object Int16Array]"===Ne?Ht+="si16":"[object Uint16Array]"===Ne?Ht+="ur16":"[object Int32Array]"===Ne?Ht+="si32":"[object Uint32Array]"===Ne?Ht+=z:"[object Float32Array]"===Ne?Ht+=N:"[object Float64Array]"===Ne?Ht+=W:Ye(new Error("Failed to get type for BinaryArray"))),Ye(Ht+St(gt))}else if("[object Blob]"===Ne){var kt=new FileReader;kt.onload=function(){var hn="~~local_forage_type~"+ve.type+"~"+St(this.result);Ye(en+Nr+hn)},kt.readAsArrayBuffer(ve)}else try{Ye(JSON.stringify(ve))}catch(hn){console.error("Couldn't convert value into a JSON string: ",ve),Ye(null,hn)}},deserialize:function an(ve){if(ve.substring(0,9)!==en)return JSON.parse(ve);var gt,Ye=ve.substring(13),Ne=ve.substring(9,13);if(Ne===Nr&&Vt.test(Ye)){var Ht=Ye.match(Vt);gt=Ht[1],Ye=Ye.substring(Ht[0].length)}var kt=mt(Ye);switch(Ne){case Kn:return kt;case Nr:return O([kt],{type:gt});case"si08":return new Int8Array(kt);case"ui08":return new Uint8Array(kt);case"uic8":return new Uint8ClampedArray(kt);case"si16":return new Int16Array(kt);case"ur16":return new Uint16Array(kt);case"si32":return new Int32Array(kt);case z:return new Uint32Array(kt);case N:return new Float32Array(kt);case W:return new Float64Array(kt);default:throw new Error("Unkown type: "+Ne)}},stringToBuffer:mt,bufferToString:St};function In(ve,Ye,Ne,gt){ve.executeSql("CREATE TABLE IF NOT EXISTS "+Ye.storeName+" (id INTEGER PRIMARY KEY, key unique, value)",[],Ne,gt)}function xn(ve,Ye,Ne,gt,Ht,kt){ve.executeSql(Ne,gt,Ht,function(hn,Dn){Dn.code===Dn.SYNTAX_ERR?hn.executeSql("SELECT name FROM sqlite_master WHERE type='table' AND name = ?",[Ye.storeName],function(Cn,Nn){Nn.rows.length?kt(Cn,Dn):In(Cn,Ye,function(){Cn.executeSql(Ne,gt,Ht,kt)},kt)},kt):kt(hn,Dn)},kt)}function Vr(ve,Ye,Ne,gt){var Ht=this;ve=re(ve);var kt=new L(function(hn,Dn){Ht.ready().then(function(){void 0===Ye&&(Ye=null);var Cn=Ye,Nn=Ht._dbInfo;Nn.serializer.serialize(Ye,function(jn,Jn){Jn?Dn(Jn):Nn.db.transaction(function(ar){xn(ar,Nn,"INSERT OR REPLACE INTO "+Nn.storeName+" (key, value) VALUES (?, ?)",[ve,jn],function(){hn(Cn)},function(wr,xr){Dn(xr)})},function(ar){if(ar.code===ar.QUOTA_ERR){if(gt>0)return void hn(Vr.apply(Ht,[ve,Cn,Ne,gt-1]));Dn(ar)}})})}).catch(Dn)});return Z(kt,Ne),kt}var wn={_driver:"webSQLStorage",_initStorage:function sr(ve){var Ye=this,Ne={db:null};if(ve)for(var gt in ve)Ne[gt]="string"!=typeof ve[gt]?ve[gt].toString():ve[gt];var Ht=new L(function(kt,hn){try{Ne.db=openDatabase(Ne.name,String(Ne.version),Ne.description,Ne.size)}catch(Dn){return hn(Dn)}Ne.db.transaction(function(Dn){In(Dn,Ne,function(){Ye._dbInfo=Ne,kt()},function(Cn,Nn){hn(Nn)})},hn)});return Ne.serializer=dn,Ht},_support:function Mt(){return"function"==typeof openDatabase}(),iterate:function Tr(ve,Ye){var Ne=this,gt=new L(function(Ht,kt){Ne.ready().then(function(){var hn=Ne._dbInfo;hn.db.transaction(function(Dn){xn(Dn,hn,"SELECT * FROM "+hn.storeName,[],function(Cn,Nn){for(var jn=Nn.rows,Jn=jn.length,ar=0;ar '__WebKitDatabaseInfoTable__'",[],function(Ht,kt){for(var hn=[],Dn=0;Dn0}var ds={_driver:"localStorageWrapper",_initStorage:function Zi(ve){var Ne={};if(ve)for(var gt in ve)Ne[gt]=ve[gt];return Ne.keyPrefix=Er(ve,this._defaultConfig),hi()?(this._dbInfo=Ne,Ne.serializer=dn,L.resolve()):L.reject()},_support:function qn(){try{return typeof localStorage<"u"&&"setItem"in localStorage&&!!localStorage.setItem}catch{return!1}}(),iterate:function nt(ve,Ye){var Ne=this,gt=Ne.ready().then(function(){for(var Ht=Ne._dbInfo,kt=Ht.keyPrefix,hn=kt.length,Dn=localStorage.length,Cn=1,Nn=0;Nn=0;Ht--){var kt=localStorage.key(Ht);0===kt.indexOf(gt)&&localStorage.removeItem(kt)}});return Z(Ne,ve),Ne},length:function mn(ve){var Ne=this.keys().then(function(gt){return gt.length});return Z(Ne,ve),Ne},key:function Rt(ve,Ye){var Ne=this,gt=Ne.ready().then(function(){var kt,Ht=Ne._dbInfo;try{kt=localStorage.key(ve)}catch{kt=null}return kt&&(kt=kt.substring(Ht.keyPrefix.length)),kt});return Z(gt,Ye),gt},keys:function sn(ve){var Ye=this,Ne=Ye.ready().then(function(){for(var gt=Ye._dbInfo,Ht=localStorage.length,kt=[],hn=0;hn=0;hn--){var Dn=localStorage.key(hn);0===Dn.indexOf(kt)&&localStorage.removeItem(Dn)}}):L.reject("Invalid arguments"),Ye),Ht}},$o=function(Ye,Ne){return Ye===Ne||"number"==typeof Ye&&"number"==typeof Ne&&isNaN(Ye)&&isNaN(Ne)},ai=function(Ye,Ne){for(var gt=Ye.length,Ht=0;Ht"u"?"undefined":w(Ne))){if(this._ready)return new Error("Can't call config() after localforage has been used.");for(var gt in Ne){if("storeName"===gt&&(Ne[gt]=Ne[gt].replace(/\W/g,"_")),"version"===gt&&"number"!=typeof Ne[gt])return new Error("Database version must be a number.");this._config[gt]=Ne[gt]}return!("driver"in Ne)||!Ne.driver||this.setDriver(this._config.driver)}return"string"==typeof Ne?this._config[Ne]:this._config},ve.prototype.defineDriver=function(Ne,gt,Ht){var kt=new L(function(hn,Dn){try{var Cn=Ne._driver,Nn=new Error("Custom driver not compliant; see https://mozilla.github.io/localForage/#definedriver");if(!Ne._driver)return void Dn(Nn);for(var jn=po.concat("_initStorage"),Jn=0,ar=jn.length;Jn{"use strict";r.d(s,{t:()=>a});var i=r(8447);class a extends i.B{constructor(y){super(),this._value=y}get value(){return this.getValue()}_subscribe(y){const w=super._subscribe(y);return!w.closed&&y.next(this._value),w}getValue(){const{hasError:y,thrownError:w,_value:C}=this;if(y)throw w;return this._throwIfClosed(),C}next(y){super.next(this._value=y)}}},1698:(o,s,r)=>{"use strict";r.d(s,{c:()=>S});var i=r(1540),a=r(5710),c=r(2563),y=r(6742),w=r(3305),C=r(1126),T=r(4171);let S=(()=>{class Z{constructor(re){re&&(this._subscribe=re)}lift(re){const pe=new Z;return pe.source=this,pe.operator=re,pe}subscribe(re,pe,se){const ae=function L(Z){return Z&&Z instanceof i.vU||function O(Z){return Z&&(0,C.T)(Z.next)&&(0,C.T)(Z.error)&&(0,C.T)(Z.complete)}(Z)&&(0,a.Uv)(Z)}(re)?re:new i.Ms(re,pe,se);return(0,T.Y)(()=>{const{operator:me,source:be}=this;ae.add(me?me.call(ae,be):be?this._subscribe(ae):this._trySubscribe(ae))}),ae}_trySubscribe(re){try{return this._subscribe(re)}catch(pe){re.error(pe)}}forEach(re,pe){return new(pe=M(pe))((se,ae)=>{const me=new i.Ms({next:be=>{try{re(be)}catch(Oe){ae(Oe),me.unsubscribe()}},error:ae,complete:se});this.subscribe(me)})}_subscribe(re){var pe;return null===(pe=this.source)||void 0===pe?void 0:pe.subscribe(re)}[c.s](){return this}pipe(...re){return(0,y.m)(re)(this)}toPromise(re){return new(re=M(re))((pe,se)=>{let ae;this.subscribe(me=>ae=me,me=>se(me),()=>pe(ae))})}}return Z.create=q=>new Z(q),Z})();function M(Z){var q;return null!==(q=Z??w.$.Promise)&&void 0!==q?q:Promise}},7838:(o,s,r)=>{"use strict";r.d(s,{m:()=>c});var i=r(8447),a=r(6188);class c extends i.B{constructor(w=1/0,C=1/0,T=a.U){super(),this._bufferSize=w,this._windowTime=C,this._timestampProvider=T,this._buffer=[],this._infiniteTimeWindow=!0,this._infiniteTimeWindow=C===1/0,this._bufferSize=Math.max(1,w),this._windowTime=Math.max(1,C)}next(w){const{isStopped:C,_buffer:T,_infiniteTimeWindow:S,_timestampProvider:M,_windowTime:O}=this;C||(T.push(w),!S&&T.push(M.now()+O)),this._trimBuffer(),super.next(w)}_subscribe(w){this._throwIfClosed(),this._trimBuffer();const C=this._innerSubscribe(w),{_infiniteTimeWindow:T,_buffer:S}=this,M=S.slice();for(let O=0;O{"use strict";r.d(s,{B:()=>T});var i=r(1698),a=r(5710);const y=(0,r(5644).L)(M=>function(){M(this),this.name="ObjectUnsubscribedError",this.message="object unsubscribed"});var w=r(5891),C=r(4171);let T=(()=>{class M extends i.c{constructor(){super(),this.closed=!1,this.currentObservers=null,this.observers=[],this.isStopped=!1,this.hasError=!1,this.thrownError=null}lift(L){const Z=new S(this,this);return Z.operator=L,Z}_throwIfClosed(){if(this.closed)throw new y}next(L){(0,C.Y)(()=>{if(this._throwIfClosed(),!this.isStopped){this.currentObservers||(this.currentObservers=Array.from(this.observers));for(const Z of this.currentObservers)Z.next(L)}})}error(L){(0,C.Y)(()=>{if(this._throwIfClosed(),!this.isStopped){this.hasError=this.isStopped=!0,this.thrownError=L;const{observers:Z}=this;for(;Z.length;)Z.shift().error(L)}})}complete(){(0,C.Y)(()=>{if(this._throwIfClosed(),!this.isStopped){this.isStopped=!0;const{observers:L}=this;for(;L.length;)L.shift().complete()}})}unsubscribe(){this.isStopped=this.closed=!0,this.observers=this.currentObservers=null}get observed(){var L;return(null===(L=this.observers)||void 0===L?void 0:L.length)>0}_trySubscribe(L){return this._throwIfClosed(),super._trySubscribe(L)}_subscribe(L){return this._throwIfClosed(),this._checkFinalizedStatuses(L),this._innerSubscribe(L)}_innerSubscribe(L){const{hasError:Z,isStopped:q,observers:re}=this;return Z||q?a.Kn:(this.currentObservers=null,re.push(L),new a.yU(()=>{this.currentObservers=null,(0,w.o)(re,L)}))}_checkFinalizedStatuses(L){const{hasError:Z,thrownError:q,isStopped:re}=this;Z?L.error(q):re&&L.complete()}asObservable(){const L=new i.c;return L.source=this,L}}return M.create=(O,L)=>new S(O,L),M})();class S extends T{constructor(O,L){super(),this.destination=O,this.source=L}next(O){var L,Z;null===(Z=null===(L=this.destination)||void 0===L?void 0:L.next)||void 0===Z||Z.call(L,O)}error(O){var L,Z;null===(Z=null===(L=this.destination)||void 0===L?void 0:L.error)||void 0===Z||Z.call(L,O)}complete(){var O,L;null===(L=null===(O=this.destination)||void 0===O?void 0:O.complete)||void 0===L||L.call(O)}_subscribe(O){var L,Z;return null!==(Z=null===(L=this.source)||void 0===L?void 0:L.subscribe(O))&&void 0!==Z?Z:a.Kn}}},1540:(o,s,r)=>{"use strict";r.d(s,{Ms:()=>se,vU:()=>Z});var i=r(1126),a=r(5710),c=r(3305),y=r(191),w=r(850);const C=M("C",void 0,void 0);function M(xe,De,ce){return{kind:xe,value:De,error:ce}}var O=r(3695),L=r(4171);class Z extends a.yU{constructor(De){super(),this.isStopped=!1,De?(this.destination=De,(0,a.Uv)(De)&&De.add(this)):this.destination=Oe}static create(De,ce,ue){return new se(De,ce,ue)}next(De){this.isStopped?be(function S(xe){return M("N",xe,void 0)}(De),this):this._next(De)}error(De){this.isStopped?be(function T(xe){return M("E",void 0,xe)}(De),this):(this.isStopped=!0,this._error(De))}complete(){this.isStopped?be(C,this):(this.isStopped=!0,this._complete())}unsubscribe(){this.closed||(this.isStopped=!0,super.unsubscribe(),this.destination=null)}_next(De){this.destination.next(De)}_error(De){try{this.destination.error(De)}finally{this.unsubscribe()}}_complete(){try{this.destination.complete()}finally{this.unsubscribe()}}}const q=Function.prototype.bind;function re(xe,De){return q.call(xe,De)}class pe{constructor(De){this.partialObserver=De}next(De){const{partialObserver:ce}=this;if(ce.next)try{ce.next(De)}catch(ue){ae(ue)}}error(De){const{partialObserver:ce}=this;if(ce.error)try{ce.error(De)}catch(ue){ae(ue)}else ae(De)}complete(){const{partialObserver:De}=this;if(De.complete)try{De.complete()}catch(ce){ae(ce)}}}class se extends Z{constructor(De,ce,ue){let Ce;if(super(),(0,i.T)(De)||!De)Ce={next:De??void 0,error:ce??void 0,complete:ue??void 0};else{let Be;this&&c.$.useDeprecatedNextContext?(Be=Object.create(De),Be.unsubscribe=()=>this.unsubscribe(),Ce={next:De.next&&re(De.next,Be),error:De.error&&re(De.error,Be),complete:De.complete&&re(De.complete,Be)}):Ce=De}this.destination=new pe(Ce)}}function ae(xe){c.$.useDeprecatedSynchronousErrorHandling?(0,L.l)(xe):(0,y.m)(xe)}function be(xe,De){const{onStoppedNotification:ce}=c.$;ce&&O.f.setTimeout(()=>ce(xe,De))}const Oe={closed:!0,next:w.l,error:function me(xe){throw xe},complete:w.l}},5710:(o,s,r)=>{"use strict";r.d(s,{Kn:()=>C,yU:()=>w,Uv:()=>T});var i=r(1126);const c=(0,r(5644).L)(M=>function(L){M(this),this.message=L?`${L.length} errors occurred during unsubscription:\n${L.map((Z,q)=>`${q+1}) ${Z.toString()}`).join("\n ")}`:"",this.name="UnsubscriptionError",this.errors=L});var y=r(5891);class w{constructor(O){this.initialTeardown=O,this.closed=!1,this._parentage=null,this._finalizers=null}unsubscribe(){let O;if(!this.closed){this.closed=!0;const{_parentage:L}=this;if(L)if(this._parentage=null,Array.isArray(L))for(const re of L)re.remove(this);else L.remove(this);const{initialTeardown:Z}=this;if((0,i.T)(Z))try{Z()}catch(re){O=re instanceof c?re.errors:[re]}const{_finalizers:q}=this;if(q){this._finalizers=null;for(const re of q)try{S(re)}catch(pe){O=O??[],pe instanceof c?O=[...O,...pe.errors]:O.push(pe)}}if(O)throw new c(O)}}add(O){var L;if(O&&O!==this)if(this.closed)S(O);else{if(O instanceof w){if(O.closed||O._hasParent(this))return;O._addParent(this)}(this._finalizers=null!==(L=this._finalizers)&&void 0!==L?L:[]).push(O)}}_hasParent(O){const{_parentage:L}=this;return L===O||Array.isArray(L)&&L.includes(O)}_addParent(O){const{_parentage:L}=this;this._parentage=Array.isArray(L)?(L.push(O),L):L?[L,O]:O}_removeParent(O){const{_parentage:L}=this;L===O?this._parentage=null:Array.isArray(L)&&(0,y.o)(L,O)}remove(O){const{_finalizers:L}=this;L&&(0,y.o)(L,O),O instanceof w&&O._removeParent(this)}}w.EMPTY=(()=>{const M=new w;return M.closed=!0,M})();const C=w.EMPTY;function T(M){return M instanceof w||M&&"closed"in M&&(0,i.T)(M.remove)&&(0,i.T)(M.add)&&(0,i.T)(M.unsubscribe)}function S(M){(0,i.T)(M)?M():M.unsubscribe()}},3305:(o,s,r)=>{"use strict";r.d(s,{$:()=>i});const i={onUnhandledError:null,onStoppedNotification:null,Promise:void 0,useDeprecatedSynchronousErrorHandling:!1,useDeprecatedNextContext:!1}},1642:(o,s,r)=>{"use strict";r.d(s,{G:()=>C});var i=r(1698),a=r(5710),c=r(3589),y=r(2483),w=r(5351);class C extends i.c{constructor(S,M){super(),this.source=S,this.subjectFactory=M,this._subject=null,this._refCount=0,this._connection=null,(0,w.S)(S)&&(this.lift=S.lift)}_subscribe(S){return this.getSubject().subscribe(S)}getSubject(){const S=this._subject;return(!S||S.isStopped)&&(this._subject=this.subjectFactory()),this._subject}_teardown(){this._refCount=0;const{_connection:S}=this;this._subject=this._connection=null,S?.unsubscribe()}connect(){let S=this._connection;if(!S){S=this._connection=new a.yU;const M=this.getSubject();S.add(this.source.subscribe((0,y._)(M,void 0,()=>{this._teardown(),M.complete()},O=>{this._teardown(),M.error(O)},()=>this._teardown()))),S.closed&&(this._connection=null,S=a.yU.EMPTY)}return S}refCount(){return(0,c.B)()(this)}}},6627:(o,s,r)=>{"use strict";r.d(s,{z:()=>O});var i=r(1698),a=r(3740),c=r(1787),y=r(9220),w=r(3759),C=r(4327),T=r(9321),S=r(2483),M=r(8266);function O(...q){const re=(0,C.lI)(q),pe=(0,C.ms)(q),{args:se,keys:ae}=(0,a.D)(q);if(0===se.length)return(0,c.H)([],re);const me=new i.c(function L(q,re,pe=y.D){return se=>{Z(re,()=>{const{length:ae}=q,me=new Array(ae);let be=ae,Oe=ae;for(let xe=0;xe{const De=(0,c.H)(q[xe],re);let ce=!1;De.subscribe((0,S._)(se,ue=>{me[xe]=ue,ce||(ce=!0,Oe--),Oe||se.next(pe(me.slice()))},()=>{--be||se.complete()}))},se)},se)}}(se,re,ae?be=>(0,T.e)(ae,be):y.D));return pe?me.pipe((0,w.I)(pe)):me}function Z(q,re,pe){q?(0,M.N)(pe,q,re):re()}},3569:(o,s,r)=>{"use strict";r.d(s,{x:()=>w});var i=r(1890),c=r(4327),y=r(1787);function w(...C){return function a(){return(0,i.U)(1)}()((0,y.H)(C,(0,c.lI)(C)))}},6381:(o,s,r)=>{"use strict";r.d(s,{v:()=>c});var i=r(1698),a=r(7225);function c(y){return new i.c(w=>{(0,a.Tg)(y()).subscribe(w)})}},6564:(o,s,r)=>{"use strict";r.d(s,{w:()=>a});const a=new(r(1698).c)(w=>w.complete())},2653:(o,s,r)=>{"use strict";r.d(s,{p:()=>S});var i=r(1698),a=r(3740),c=r(7225),y=r(4327),w=r(2483),C=r(3759),T=r(9321);function S(...M){const O=(0,y.ms)(M),{args:L,keys:Z}=(0,a.D)(M),q=new i.c(re=>{const{length:pe}=L;if(!pe)return void re.complete();const se=new Array(pe);let ae=pe,me=pe;for(let be=0;be{Oe||(Oe=!0,me--),se[be]=xe},()=>ae--,void 0,()=>{(!ae||!Oe)&&(me||re.next(Z?(0,T.e)(Z,se):se),re.complete())}))}});return O?q.pipe((0,C.I)(O)):q}},1787:(o,s,r)=>{"use strict";r.d(s,{H:()=>ue});var i=r(7225),a=r(8266),c=r(5351),y=r(2483);function w(Ce,Be=0){return(0,c.N)((at,dt)=>{at.subscribe((0,y._)(dt,bt=>(0,a.N)(dt,Ce,()=>dt.next(bt),Be),()=>(0,a.N)(dt,Ce,()=>dt.complete(),Be),bt=>(0,a.N)(dt,Ce,()=>dt.error(bt),Be)))})}function C(Ce,Be=0){return(0,c.N)((at,dt)=>{dt.add(Ce.schedule(()=>at.subscribe(dt),Be))})}var M=r(1698),L=r(6952),Z=r(1126);function re(Ce,Be){if(!Ce)throw new Error("Iterable cannot be null");return new M.c(at=>{(0,a.N)(at,Be,()=>{const dt=Ce[Symbol.asyncIterator]();(0,a.N)(at,Be,()=>{dt.next().then(bt=>{bt.done?at.complete():at.next(bt.value)})},0,!0)})})}var pe=r(6600),se=r(6505),ae=r(6786),me=r(4876),be=r(8394),Oe=r(8810),xe=r(3173);function ue(Ce,Be){return Be?function ce(Ce,Be){if(null!=Ce){if((0,pe.l)(Ce))return function T(Ce,Be){return(0,i.Tg)(Ce).pipe(C(Be),w(Be))}(Ce,Be);if((0,ae.X)(Ce))return function O(Ce,Be){return new M.c(at=>{let dt=0;return Be.schedule(function(){dt===Ce.length?at.complete():(at.next(Ce[dt++]),at.closed||this.schedule())})})}(Ce,Be);if((0,se.y)(Ce))return function S(Ce,Be){return(0,i.Tg)(Ce).pipe(C(Be),w(Be))}(Ce,Be);if((0,be.T)(Ce))return re(Ce,Be);if((0,me.x)(Ce))return function q(Ce,Be){return new M.c(at=>{let dt;return(0,a.N)(at,Be,()=>{dt=Ce[L.l](),(0,a.N)(at,Be,()=>{let bt,lt;try{({value:bt,done:lt}=dt.next())}catch(rn){return void at.error(rn)}lt?at.complete():at.next(bt)},0,!0)}),()=>(0,Z.T)(dt?.return)&&dt.return()})}(Ce,Be);if((0,xe.U)(Ce))return function De(Ce,Be){return re((0,xe.C)(Ce),Be)}(Ce,Be)}throw(0,Oe.L)(Ce)}(Ce,Be):(0,i.Tg)(Ce)}},909:(o,s,r)=>{"use strict";r.d(s,{R:()=>O});var i=r(7225),a=r(1698),c=r(5823),y=r(6786),w=r(1126),C=r(3759);const T=["addListener","removeListener"],S=["addEventListener","removeEventListener"],M=["on","off"];function O(pe,se,ae,me){if((0,w.T)(ae)&&(me=ae,ae=void 0),me)return O(pe,se,ae).pipe((0,C.I)(me));const[be,Oe]=function re(pe){return(0,w.T)(pe.addEventListener)&&(0,w.T)(pe.removeEventListener)}(pe)?S.map(xe=>De=>pe[xe](se,De,ae)):function Z(pe){return(0,w.T)(pe.addListener)&&(0,w.T)(pe.removeListener)}(pe)?T.map(L(pe,se)):function q(pe){return(0,w.T)(pe.on)&&(0,w.T)(pe.off)}(pe)?M.map(L(pe,se)):[];if(!be&&(0,y.X)(pe))return(0,c.Z)(xe=>O(xe,se,ae))((0,i.Tg)(pe));if(!be)throw new TypeError("Invalid event target");return new a.c(xe=>{const De=(...ce)=>xe.next(1Oe(De)})}function L(pe,se){return ae=>me=>pe[ae](se,me)}},7225:(o,s,r)=>{"use strict";r.d(s,{Tg:()=>q});var i=r(1635),a=r(6786),c=r(6505),y=r(1698),w=r(6600),C=r(8394),T=r(8810),S=r(4876),M=r(3173),O=r(1126),L=r(191),Z=r(2563);function q(xe){if(xe instanceof y.c)return xe;if(null!=xe){if((0,w.l)(xe))return function re(xe){return new y.c(De=>{const ce=xe[Z.s]();if((0,O.T)(ce.subscribe))return ce.subscribe(De);throw new TypeError("Provided object does not correctly implement Symbol.observable")})}(xe);if((0,a.X)(xe))return function pe(xe){return new y.c(De=>{for(let ce=0;ce{xe.then(ce=>{De.closed||(De.next(ce),De.complete())},ce=>De.error(ce)).then(null,L.m)})}(xe);if((0,C.T)(xe))return me(xe);if((0,S.x)(xe))return function ae(xe){return new y.c(De=>{for(const ce of xe)if(De.next(ce),De.closed)return;De.complete()})}(xe);if((0,M.U)(xe))return function be(xe){return me((0,M.C)(xe))}(xe)}throw(0,T.L)(xe)}function me(xe){return new y.c(De=>{(function Oe(xe,De){var ce,ue,Ce,Be;return(0,i.sH)(this,void 0,void 0,function*(){try{for(ce=(0,i.xN)(xe);!(ue=yield ce.next()).done;)if(De.next(ue.value),De.closed)return}catch(at){Ce={error:at}}finally{try{ue&&!ue.done&&(Be=ce.return)&&(yield Be.call(ce))}finally{if(Ce)throw Ce.error}}De.complete()})})(xe,De).catch(ce=>De.error(ce))})}},7509:(o,s,r)=>{"use strict";r.d(s,{h:()=>C});var i=r(1890),a=r(7225),c=r(6564),y=r(4327),w=r(1787);function C(...T){const S=(0,y.lI)(T),M=(0,y.R0)(T,1/0),O=T;return O.length?1===O.length?(0,a.Tg)(O[0]):(0,i.U)(M)((0,w.H)(O,S)):c.w}},3016:(o,s,r)=>{"use strict";r.d(s,{of:()=>c});var i=r(4327),a=r(1787);function c(...y){const w=(0,i.lI)(y);return(0,a.H)(y,w)}},8915:(o,s,r)=>{"use strict";r.d(s,{$:()=>c});var i=r(1698),a=r(1126);function c(y,w){const C=(0,a.T)(y)?y:()=>y,T=S=>S.error(C());return new i.c(w?S=>w.schedule(T,0,S):T)}},9587:(o,s,r)=>{"use strict";r.d(s,{O:()=>w});var i=r(1698),a=r(6061),c=r(9921);function w(C=0,T,S=a.b){let M=-1;return null!=T&&((0,c.m)(T)?S=T:M=T),new i.c(O=>{let L=function y(C){return C instanceof Date&&!isNaN(C)}(C)?+C-S.now():C;L<0&&(L=0);let Z=0;return S.schedule(function(){O.closed||(O.next(Z++),0<=M?this.schedule(void 0,M):O.complete())},L)})}},2483:(o,s,r)=>{"use strict";r.d(s,{_:()=>a});var i=r(1540);function a(y,w,C,T,S){return new c(y,w,C,T,S)}class c extends i.vU{constructor(w,C,T,S,M,O){super(w),this.onFinalize=M,this.shouldUnsubscribe=O,this._next=C?function(L){try{C(L)}catch(Z){w.error(Z)}}:super._next,this._error=S?function(L){try{S(L)}catch(Z){w.error(Z)}finally{this.unsubscribe()}}:super._error,this._complete=T?function(){try{T()}catch(L){w.error(L)}finally{this.unsubscribe()}}:super._complete}unsubscribe(){var w;if(!this.shouldUnsubscribe||this.shouldUnsubscribe()){const{closed:C}=this;super.unsubscribe(),!C&&(null===(w=this.onFinalize)||void 0===w||w.call(this))}}}},5684:(o,s,r)=>{"use strict";r.d(s,{Z:()=>T});var i=r(6061),a=r(5351),c=r(7225),y=r(2483),C=r(9587);function T(S,M=i.E){return function w(S){return(0,a.N)((M,O)=>{let L=!1,Z=null,q=null,re=!1;const pe=()=>{if(q?.unsubscribe(),q=null,L){L=!1;const ae=Z;Z=null,O.next(ae)}re&&O.complete()},se=()=>{q=null,re&&O.complete()};M.subscribe((0,y._)(O,ae=>{L=!0,Z=ae,q||(0,c.Tg)(S(ae)).subscribe(q=(0,y._)(O,pe,se))},()=>{re=!0,(!L||!q||q.closed)&&O.complete()}))})}(()=>(0,C.O)(S,M))}},7178:(o,s,r)=>{"use strict";r.d(s,{W:()=>y});var i=r(7225),a=r(2483),c=r(5351);function y(w){return(0,c.N)((C,T)=>{let O,S=null,M=!1;S=C.subscribe((0,a._)(T,void 0,void 0,L=>{O=(0,i.Tg)(w(L,y(w)(C))),S?(S.unsubscribe(),S=null,O.subscribe(T)):M=!0})),M&&(S.unsubscribe(),S=null,O.subscribe(T))})}},1459:(o,s,r)=>{"use strict";r.d(s,{H:()=>c});var i=r(5823),a=r(1126);function c(y,w){return(0,a.T)(w)?(0,i.Z)(y,w,1):(0,i.Z)(y,1)}},8627:(o,s,r)=>{"use strict";r.d(s,{B:()=>y});var i=r(6061),a=r(5351),c=r(2483);function y(w,C=i.E){return(0,a.N)((T,S)=>{let M=null,O=null,L=null;const Z=()=>{if(M){M.unsubscribe(),M=null;const re=O;O=null,S.next(re)}};function q(){const re=L+w,pe=C.now();if(pe{O=re,L=C.now(),M||(M=C.schedule(q,w),S.add(M))},()=>{Z(),S.complete()},void 0,()=>{O=M=null}))})}},5670:(o,s,r)=>{"use strict";r.d(s,{U:()=>c});var i=r(5351),a=r(2483);function c(y){return(0,i.N)((w,C)=>{let T=!1;w.subscribe((0,a._)(C,S=>{T=!0,C.next(S)},()=>{T||C.next(y),C.complete()}))})}},8136:(o,s,r)=>{"use strict";r.d(s,{c:()=>q});var i=r(6061),a=r(3569),c=r(7610),y=r(5351),w=r(2483),C=r(850),S=r(6590),M=r(5823),O=r(7225);function L(re,pe){return pe?se=>(0,a.x)(pe.pipe((0,c.s)(1),function T(){return(0,y.N)((re,pe)=>{re.subscribe((0,w._)(pe,C.l))})}()),se.pipe(L(re))):(0,M.Z)((se,ae)=>(0,O.Tg)(re(se,ae)).pipe((0,c.s)(1),(0,S.u)(se)))}var Z=r(9587);function q(re,pe=i.E){const se=(0,Z.O)(re,pe);return L(()=>se)}},6645:(o,s,r)=>{"use strict";r.d(s,{F:()=>y});var i=r(9220),a=r(5351),c=r(2483);function y(C,T=i.D){return C=C??w,(0,a.N)((S,M)=>{let O,L=!0;S.subscribe((0,c._)(M,Z=>{const q=T(Z);(L||!C(O,q))&&(L=!1,O=q,M.next(Z))}))})}function w(C,T){return C===T}},1483:(o,s,r)=>{"use strict";r.d(s,{p:()=>c});var i=r(5351),a=r(2483);function c(y,w){return(0,i.N)((C,T)=>{let S=0;C.subscribe((0,a._)(T,M=>y.call(w,M,S++)&&T.next(M)))})}},4447:(o,s,r)=>{"use strict";r.d(s,{j:()=>a});var i=r(5351);function a(c){return(0,i.N)((y,w)=>{try{y.subscribe(w)}finally{w.add(c)}})}},1703:(o,s,r)=>{"use strict";r.d(s,{$:()=>T});var i=r(8747),a=r(1483),c=r(7610),y=r(5670),w=r(5017),C=r(9220);function T(S,M){const O=arguments.length>=2;return L=>L.pipe(S?(0,a.p)((Z,q)=>S(Z,q,L)):C.D,(0,c.s)(1),O?(0,y.U)(M):(0,w.v)(()=>new i.G))}},7947:(o,s,r)=>{"use strict";r.d(s,{T:()=>c});var i=r(5351),a=r(2483);function c(y,w){return(0,i.N)((C,T)=>{let S=0;C.subscribe((0,a._)(T,M=>{T.next(y.call(w,M,S++))}))})}},6590:(o,s,r)=>{"use strict";r.d(s,{u:()=>a});var i=r(7947);function a(c){return(0,i.T)(()=>c)}},1890:(o,s,r)=>{"use strict";r.d(s,{U:()=>c});var i=r(5823),a=r(9220);function c(y=1/0){return(0,i.Z)(a.D,y)}},5823:(o,s,r)=>{"use strict";r.d(s,{Z:()=>S});var i=r(7947),a=r(7225),c=r(5351),y=r(8266),w=r(2483),T=r(1126);function S(M,O,L=1/0){return(0,T.T)(O)?S((Z,q)=>(0,i.T)((re,pe)=>O(Z,re,q,pe))((0,a.Tg)(M(Z,q))),L):("number"==typeof O&&(L=O),(0,c.N)((Z,q)=>function C(M,O,L,Z,q,re,pe,se){const ae=[];let me=0,be=0,Oe=!1;const xe=()=>{Oe&&!ae.length&&!me&&O.complete()},De=ue=>me{re&&O.next(ue),me++;let Ce=!1;(0,a.Tg)(L(ue,be++)).subscribe((0,w._)(O,Be=>{q?.(Be),re?De(Be):O.next(Be)},()=>{Ce=!0},void 0,()=>{if(Ce)try{for(me--;ae.length&&mece(Be)):ce(Be)}xe()}catch(Be){O.error(Be)}}))};return M.subscribe((0,w._)(O,De,()=>{Oe=!0,xe()})),()=>{se?.()}}(Z,q,M,L)))}},3589:(o,s,r)=>{"use strict";r.d(s,{B:()=>c});var i=r(5351),a=r(2483);function c(){return(0,i.N)((y,w)=>{let C=null;y._refCount++;const T=(0,a._)(w,void 0,void 0,void 0,()=>{if(!y||y._refCount<=0||0<--y._refCount)return void(C=null);const S=y._connection,M=C;C=null,S&&(!M||S===M)&&S.unsubscribe(),w.unsubscribe()});y.subscribe(T),T.closed||(C=y.connect())})}},5903:(o,s,r)=>{"use strict";r.d(s,{L:()=>C});var i=r(5351),a=r(2483),c=r(9220),y=r(9587),w=r(7225);function C(T=1/0){let S;S=T&&"object"==typeof T?T:{count:T};const{count:M=1/0,delay:O,resetOnSuccess:L=!1}=S;return M<=0?c.D:(0,i.N)((Z,q)=>{let pe,re=0;const se=()=>{let ae=!1;pe=Z.subscribe((0,a._)(q,me=>{L&&(re=0),q.next(me)},void 0,me=>{if(re++{pe?(pe.unsubscribe(),pe=null,se()):ae=!0};if(null!=O){const Oe="number"==typeof O?(0,y.O)(O):(0,w.Tg)(O(me,re)),xe=(0,a._)(q,()=>{xe.unsubscribe(),be()},()=>{q.complete()});Oe.subscribe(xe)}else be()}else q.error(me)})),ae&&(pe.unsubscribe(),pe=null,se())};se()})}},36:(o,s,r)=>{"use strict";r.d(s,{S:()=>a});var i=r(2483);function a(c,y,w,C,T){return(S,M)=>{let O=w,L=y,Z=0;S.subscribe((0,i._)(M,q=>{const re=Z++;L=O?c(L,q,re):(O=!0,q),C&&M.next(L)},T&&(()=>{O&&M.next(L),M.complete()})))}}},6218:(o,s,r)=>{"use strict";r.d(s,{u:()=>w});var i=r(7225),a=r(8447),c=r(1540),y=r(5351);function w(T={}){const{connector:S=()=>new a.B,resetOnError:M=!0,resetOnComplete:O=!0,resetOnRefCountZero:L=!0}=T;return Z=>{let q,re,pe,se=0,ae=!1,me=!1;const be=()=>{re?.unsubscribe(),re=void 0},Oe=()=>{be(),q=pe=void 0,ae=me=!1},xe=()=>{const De=q;Oe(),De?.unsubscribe()};return(0,y.N)((De,ce)=>{se++,!me&&!ae&&be();const ue=pe=pe??S();ce.add(()=>{se--,0===se&&!me&&!ae&&(re=C(xe,L))}),ue.subscribe(ce),!q&&se>0&&(q=new c.Ms({next:Ce=>ue.next(Ce),error:Ce=>{me=!0,be(),re=C(Oe,M,Ce),ue.error(Ce)},complete:()=>{ae=!0,be(),re=C(Oe,O),ue.complete()}}),(0,i.Tg)(De).subscribe(q))})(Z)}}function C(T,S,...M){if(!0===S)return void T();if(!1===S)return;const O=new c.Ms({next:()=>{O.unsubscribe(),T()}});return(0,i.Tg)(S(...M)).subscribe(O)}},8249:(o,s,r)=>{"use strict";r.d(s,{t:()=>c});var i=r(7838),a=r(6218);function c(y,w,C){let T,S=!1;return y&&"object"==typeof y?({bufferSize:T=1/0,windowTime:w=1/0,refCount:S=!1,scheduler:C}=y):T=y??1/0,(0,a.u)({connector:()=>new i.m(T,w,C),resetOnError:!0,resetOnComplete:!1,resetOnRefCountZero:S})}},1866:(o,s,r)=>{"use strict";r.d(s,{i:()=>a});var i=r(1483);function a(c){return(0,i.p)((y,w)=>c<=w)}},593:(o,s,r)=>{"use strict";r.d(s,{Z:()=>y});var i=r(3569),a=r(4327),c=r(5351);function y(...w){const C=(0,a.lI)(w);return(0,c.N)((T,S)=>{(C?(0,i.x)(w,T,C):(0,i.x)(w,T)).subscribe(S)})}},2867:(o,s,r)=>{"use strict";r.d(s,{n:()=>y});var i=r(7225),a=r(5351),c=r(2483);function y(w,C){return(0,a.N)((T,S)=>{let M=null,O=0,L=!1;const Z=()=>L&&!M&&S.complete();T.subscribe((0,c._)(S,q=>{M?.unsubscribe();let re=0;const pe=O++;(0,i.Tg)(w(q,pe)).subscribe(M=(0,c._)(S,se=>S.next(C?C(q,se,pe,re++):se),()=>{M=null,Z()}))},()=>{L=!0,Z()}))})}},7610:(o,s,r)=>{"use strict";r.d(s,{s:()=>y});var i=r(6564),a=r(5351),c=r(2483);function y(w){return w<=0?()=>i.w:(0,a.N)((C,T)=>{let S=0;C.subscribe((0,c._)(T,M=>{++S<=w&&(T.next(M),w<=S&&T.complete())}))})}},5424:(o,s,r)=>{"use strict";r.d(s,{Q:()=>w});var i=r(5351),a=r(2483),c=r(7225),y=r(850);function w(C){return(0,i.N)((T,S)=>{(0,c.Tg)(C).subscribe((0,a._)(S,()=>S.complete(),y.l)),!S.closed&&T.subscribe(S)})}},8445:(o,s,r)=>{"use strict";r.d(s,{v:()=>c});var i=r(5351),a=r(2483);function c(y,w=!1){return(0,i.N)((C,T)=>{let S=0;C.subscribe((0,a._)(T,M=>{const O=y(M,S++);(O||w)&&T.next(M),!O&&T.complete()}))})}},2040:(o,s,r)=>{"use strict";r.d(s,{M:()=>w});var i=r(1126),a=r(5351),c=r(2483),y=r(9220);function w(C,T,S){const M=(0,i.T)(C)||T||S?{next:C,error:T,complete:S}:C;return M?(0,a.N)((O,L)=>{var Z;null===(Z=M.subscribe)||void 0===Z||Z.call(M);let q=!0;O.subscribe((0,c._)(L,re=>{var pe;null===(pe=M.next)||void 0===pe||pe.call(M,re),L.next(re)},()=>{var re;q=!1,null===(re=M.complete)||void 0===re||re.call(M),L.complete()},re=>{var pe;q=!1,null===(pe=M.error)||void 0===pe||pe.call(M,re),L.error(re)},()=>{var re,pe;q&&(null===(re=M.unsubscribe)||void 0===re||re.call(M)),null===(pe=M.finalize)||void 0===pe||pe.call(M)}))}):y.D}},5017:(o,s,r)=>{"use strict";r.d(s,{v:()=>y});var i=r(8747),a=r(5351),c=r(2483);function y(C=w){return(0,a.N)((T,S)=>{let M=!1;T.subscribe((0,c._)(S,O=>{M=!0,S.next(O)},()=>M?S.complete():S.error(C())))})}function w(){return new i.G}},9899:(o,s,r)=>{"use strict";r.d(s,{R:()=>w});var i=r(5710);class a extends i.yU{constructor(T,S){super()}schedule(T,S=0){return this}}const c={setInterval(C,T,...S){const{delegate:M}=c;return M?.setInterval?M.setInterval(C,T,...S):setInterval(C,T,...S)},clearInterval(C){const{delegate:T}=c;return(T?.clearInterval||clearInterval)(C)},delegate:void 0};var y=r(5891);class w extends a{constructor(T,S){super(T,S),this.scheduler=T,this.work=S,this.pending=!1}schedule(T,S=0){var M;if(this.closed)return this;this.state=T;const O=this.id,L=this.scheduler;return null!=O&&(this.id=this.recycleAsyncId(L,O,S)),this.pending=!0,this.delay=S,this.id=null!==(M=this.id)&&void 0!==M?M:this.requestAsyncId(L,this.id,S),this}requestAsyncId(T,S,M=0){return c.setInterval(T.flush.bind(T,this),M)}recycleAsyncId(T,S,M=0){if(null!=M&&this.delay===M&&!1===this.pending)return S;null!=S&&c.clearInterval(S)}execute(T,S){if(this.closed)return new Error("executing a cancelled action");this.pending=!1;const M=this._execute(T,S);if(M)return M;!1===this.pending&&null!=this.id&&(this.id=this.recycleAsyncId(this.scheduler,this.id,null))}_execute(T,S){let O,M=!1;try{this.work(T)}catch(L){M=!0,O=L||new Error("Scheduled action threw falsy error")}if(M)return this.unsubscribe(),O}unsubscribe(){if(!this.closed){const{id:T,scheduler:S}=this,{actions:M}=S;this.work=this.state=this.scheduler=null,this.pending=!1,(0,y.o)(M,this),null!=T&&(this.id=this.recycleAsyncId(S,T,null)),this.delay=null,super.unsubscribe()}}}},8050:(o,s,r)=>{"use strict";r.d(s,{q:()=>c});var i=r(6188);class a{constructor(w,C=a.now){this.schedulerActionCtor=w,this.now=C}schedule(w,C=0,T){return new this.schedulerActionCtor(this,w).schedule(T,C)}}a.now=i.U.now;class c extends a{constructor(w,C=a.now){super(w,C),this.actions=[],this._active=!1}flush(w){const{actions:C}=this;if(this._active)return void C.push(w);let T;this._active=!0;do{if(T=w.execute(w.state,w.delay))break}while(w=C.shift());if(this._active=!1,T){for(;w=C.shift();)w.unsubscribe();throw T}}}},4984:(o,s,r)=>{"use strict";r.d(s,{$:()=>re});var i=r(9899);let c,a=1;const y={};function w(se){return se in y&&(delete y[se],!0)}const C={setImmediate(se){const ae=a++;return y[ae]=!0,c||(c=Promise.resolve()),c.then(()=>w(ae)&&se()),ae},clearImmediate(se){w(se)}},{setImmediate:S,clearImmediate:M}=C,O={setImmediate(...se){const{delegate:ae}=O;return(ae?.setImmediate||S)(...se)},clearImmediate(se){const{delegate:ae}=O;return(ae?.clearImmediate||M)(se)},delegate:void 0};var Z=r(8050);const re=new class q extends Z.q{flush(ae){this._active=!0;const me=this._scheduled;this._scheduled=void 0;const{actions:be}=this;let Oe;ae=ae||be.shift();do{if(Oe=ae.execute(ae.state,ae.delay))break}while((ae=be[0])&&ae.id===me&&be.shift());if(this._active=!1,Oe){for(;(ae=be[0])&&ae.id===me&&be.shift();)ae.unsubscribe();throw Oe}}}(class L extends i.R{constructor(ae,me){super(ae,me),this.scheduler=ae,this.work=me}requestAsyncId(ae,me,be=0){return null!==be&&be>0?super.requestAsyncId(ae,me,be):(ae.actions.push(this),ae._scheduled||(ae._scheduled=O.setImmediate(ae.flush.bind(ae,void 0))))}recycleAsyncId(ae,me,be=0){var Oe;if(null!=be?be>0:this.delay>0)return super.recycleAsyncId(ae,me,be);const{actions:xe}=ae;null!=me&&(null===(Oe=xe[xe.length-1])||void 0===Oe?void 0:Oe.id)!==me&&(O.clearImmediate(me),ae._scheduled===me&&(ae._scheduled=void 0))}})},6061:(o,s,r)=>{"use strict";r.d(s,{E:()=>c,b:()=>y});var i=r(9899);const c=new(r(8050).q)(i.R),y=c},6188:(o,s,r)=>{"use strict";r.d(s,{U:()=>i});const i={now:()=>(i.delegate||Date).now(),delegate:void 0}},3695:(o,s,r)=>{"use strict";r.d(s,{f:()=>i});const i={setTimeout(a,c,...y){const{delegate:w}=i;return w?.setTimeout?w.setTimeout(a,c,...y):setTimeout(a,c,...y)},clearTimeout(a){const{delegate:c}=i;return(c?.clearTimeout||clearTimeout)(a)},delegate:void 0}},6952:(o,s,r)=>{"use strict";r.d(s,{l:()=>a});const a=function i(){return"function"==typeof Symbol&&Symbol.iterator?Symbol.iterator:"@@iterator"}()},2563:(o,s,r)=>{"use strict";r.d(s,{s:()=>i});const i="function"==typeof Symbol&&Symbol.observable||"@@observable"},8747:(o,s,r)=>{"use strict";r.d(s,{G:()=>a});const a=(0,r(5644).L)(c=>function(){c(this),this.name="EmptyError",this.message="no elements in sequence"})},4327:(o,s,r)=>{"use strict";r.d(s,{R0:()=>C,lI:()=>w,ms:()=>y});var i=r(1126),a=r(9921);function c(T){return T[T.length-1]}function y(T){return(0,i.T)(c(T))?T.pop():void 0}function w(T){return(0,a.m)(c(T))?T.pop():void 0}function C(T,S){return"number"==typeof c(T)?T.pop():S}},3740:(o,s,r)=>{"use strict";r.d(s,{D:()=>w});const{isArray:i}=Array,{getPrototypeOf:a,prototype:c,keys:y}=Object;function w(T){if(1===T.length){const S=T[0];if(i(S))return{args:S,keys:null};if(function C(T){return T&&"object"==typeof T&&a(T)===c}(S)){const M=y(S);return{args:M.map(O=>S[O]),keys:M}}}return{args:T,keys:null}}},5891:(o,s,r)=>{"use strict";function i(a,c){if(a){const y=a.indexOf(c);0<=y&&a.splice(y,1)}}r.d(s,{o:()=>i})},5644:(o,s,r)=>{"use strict";function i(a){const y=a(w=>{Error.call(w),w.stack=(new Error).stack});return y.prototype=Object.create(Error.prototype),y.prototype.constructor=y,y}r.d(s,{L:()=>i})},9321:(o,s,r)=>{"use strict";function i(a,c){return a.reduce((y,w,C)=>(y[w]=c[C],y),{})}r.d(s,{e:()=>i})},4171:(o,s,r)=>{"use strict";r.d(s,{Y:()=>c,l:()=>y});var i=r(3305);let a=null;function c(w){if(i.$.useDeprecatedSynchronousErrorHandling){const C=!a;if(C&&(a={errorThrown:!1,error:null}),w(),C){const{errorThrown:T,error:S}=a;if(a=null,T)throw S}}else w()}function y(w){i.$.useDeprecatedSynchronousErrorHandling&&a&&(a.errorThrown=!0,a.error=w)}},8266:(o,s,r)=>{"use strict";function i(a,c,y,w=0,C=!1){const T=c.schedule(function(){y(),C?a.add(this.schedule(null,w)):this.unsubscribe()},w);if(a.add(T),!C)return T}r.d(s,{N:()=>i})},9220:(o,s,r)=>{"use strict";function i(a){return a}r.d(s,{D:()=>i})},6786:(o,s,r)=>{"use strict";r.d(s,{X:()=>i});const i=a=>a&&"number"==typeof a.length&&"function"!=typeof a},8394:(o,s,r)=>{"use strict";r.d(s,{T:()=>a});var i=r(1126);function a(c){return Symbol.asyncIterator&&(0,i.T)(c?.[Symbol.asyncIterator])}},1126:(o,s,r)=>{"use strict";function i(a){return"function"==typeof a}r.d(s,{T:()=>i})},6600:(o,s,r)=>{"use strict";r.d(s,{l:()=>c});var i=r(2563),a=r(1126);function c(y){return(0,a.T)(y[i.s])}},4876:(o,s,r)=>{"use strict";r.d(s,{x:()=>c});var i=r(6952),a=r(1126);function c(y){return(0,a.T)(y?.[i.l])}},1531:(o,s,r)=>{"use strict";r.d(s,{A:()=>c});var i=r(1698),a=r(1126);function c(y){return!!y&&(y instanceof i.c||(0,a.T)(y.lift)&&(0,a.T)(y.subscribe))}},6505:(o,s,r)=>{"use strict";r.d(s,{y:()=>a});var i=r(1126);function a(c){return(0,i.T)(c?.then)}},3173:(o,s,r)=>{"use strict";r.d(s,{C:()=>c,U:()=>y});var i=r(1635),a=r(1126);function c(w){return(0,i.AQ)(this,arguments,function*(){const T=w.getReader();try{for(;;){const{value:S,done:M}=yield(0,i.N3)(T.read());if(M)return yield(0,i.N3)(void 0);yield yield(0,i.N3)(S)}}finally{T.releaseLock()}})}function y(w){return(0,a.T)(w?.getReader)}},9921:(o,s,r)=>{"use strict";r.d(s,{m:()=>a});var i=r(1126);function a(c){return c&&(0,i.T)(c.schedule)}},5351:(o,s,r)=>{"use strict";r.d(s,{N:()=>c,S:()=>a});var i=r(1126);function a(y){return(0,i.T)(y?.lift)}function c(y){return w=>{if(a(w))return w.lift(function(C){try{return y(C,this)}catch(T){this.error(T)}});throw new TypeError("Unable to lift unknown Observable type")}}},3759:(o,s,r)=>{"use strict";r.d(s,{I:()=>y});var i=r(7947);const{isArray:a}=Array;function y(w){return(0,i.T)(C=>function c(w,C){return a(C)?w(...C):w(C)}(w,C))}},850:(o,s,r)=>{"use strict";function i(){}r.d(s,{l:()=>i})},6742:(o,s,r)=>{"use strict";r.d(s,{F:()=>a,m:()=>c});var i=r(9220);function a(...y){return c(y)}function c(y){return 0===y.length?i.D:1===y.length?y[0]:function(C){return y.reduce((T,S)=>S(T),C)}}},191:(o,s,r)=>{"use strict";r.d(s,{m:()=>c});var i=r(3305),a=r(3695);function c(y){a.f.setTimeout(()=>{const{onUnhandledError:w}=i.$;if(!w)throw y;w(y)})}},8810:(o,s,r)=>{"use strict";function i(a){return new TypeError(`You provided ${null!==a&&"object"==typeof a?"an invalid object":`'${a}'`} where a stream was expected. You can provide an Observable, Promise, ReadableStream, Array, AsyncIterable, or Iterable.`)}r.d(s,{L:()=>i})},1204:(o,s,r)=>{"use strict";r.d(s,{FX:()=>dt,If:()=>c,K2:()=>S,MA:()=>re,Os:()=>T,P:()=>se,S6:()=>me,hZ:()=>w,i0:()=>C,i7:()=>L,iF:()=>M,kY:()=>Z,kp:()=>y,sf:()=>Be,ui:()=>at,wk:()=>O});var i=r(4460),a=r(3107),c=function(bt){return bt[bt.State=0]="State",bt[bt.Transition=1]="Transition",bt[bt.Sequence=2]="Sequence",bt[bt.Group=3]="Group",bt[bt.Animate=4]="Animate",bt[bt.Keyframes=5]="Keyframes",bt[bt.Style=6]="Style",bt[bt.Trigger=7]="Trigger",bt[bt.Reference=8]="Reference",bt[bt.AnimateChild=9]="AnimateChild",bt[bt.AnimateRef=10]="AnimateRef",bt[bt.Query=11]="Query",bt[bt.Stagger=12]="Stagger",bt}(c||{});const y="*";function w(bt,lt){return{type:c.Trigger,name:bt,definitions:lt,options:{}}}function C(bt,lt=null){return{type:c.Animate,styles:lt,timings:bt}}function T(bt,lt=null){return{type:c.Group,steps:bt,options:lt}}function S(bt,lt=null){return{type:c.Sequence,steps:bt,options:lt}}function M(bt){return{type:c.Style,styles:bt,offset:null}}function O(bt,lt,rn){return{type:c.State,name:bt,styles:lt,options:rn}}function L(bt){return{type:c.Keyframes,steps:bt}}function Z(bt,lt,rn=null){return{type:c.Transition,expr:bt,animation:lt,options:rn}}function re(bt=null){return{type:c.AnimateChild,options:bt}}function se(bt,lt,rn=null){return{type:c.Query,selector:bt,animation:lt,options:rn}}let me=(()=>{class bt{static \u0275fac=function(gn){return new(gn||bt)};static \u0275prov=a.jDH({token:bt,factory:()=>(0,a.WQX)(Oe),providedIn:"root"})}return bt})();class be{}let Oe=(()=>{class bt extends me{animationModuleType=(0,a.WQX)(a.bc$,{optional:!0});_nextAnimationId=0;_renderer;constructor(rn,gn){if(super(),this._renderer=rn.createRenderer(gn.body,{id:"0",encapsulation:a.gXe.None,styles:[],data:{animation:[]}}),null===this.animationModuleType&&!function Ce(bt){const lt=bt.\u0275type;return 0===lt||1===lt}(this._renderer))throw new a.wOt(3600,!1)}build(rn){const gn=this._nextAnimationId;this._nextAnimationId++;const bn=Array.isArray(rn)?S(rn):rn;return ce(this._renderer,null,gn,"register",[bn]),new xe(gn,this._renderer)}static \u0275fac=function(gn){return new(gn||bt)(a.KVO(a._9s),a.KVO(i.qQ))};static \u0275prov=a.jDH({token:bt,factory:bt.\u0275fac,providedIn:"root"})}return bt})();class xe extends be{_id;_renderer;constructor(lt,rn){super(),this._id=lt,this._renderer=rn}create(lt,rn){return new De(this._id,lt,rn||{},this._renderer)}}class De{id;element;_renderer;parentPlayer=null;_started=!1;constructor(lt,rn,gn,bn){this.id=lt,this.element=rn,this._renderer=bn,this._command("create",gn)}_listen(lt,rn){return this._renderer.listen(this.element,`@@${this.id}:${lt}`,rn)}_command(lt,...rn){ce(this._renderer,this.element,this.id,lt,rn)}onDone(lt){this._listen("done",lt)}onStart(lt){this._listen("start",lt)}onDestroy(lt){this._listen("destroy",lt)}init(){this._command("init")}hasStarted(){return this._started}play(){this._command("play"),this._started=!0}pause(){this._command("pause")}restart(){this._command("restart")}finish(){this._command("finish")}destroy(){this._command("destroy")}reset(){this._command("reset"),this._started=!1}setPosition(lt){this._command("setPosition",lt)}getPosition(){return function ue(bt){const lt=bt.\u0275type;return 0===lt?bt:1===lt?bt.animationRenderer:null}(this._renderer)?.engine?.players[this.id]?.getPosition()??0}totalTime=0}function ce(bt,lt,rn,gn,bn){bt.setProperty(lt,`@@${rn}:${gn}`,bn)}class Be{_onDoneFns=[];_onStartFns=[];_onDestroyFns=[];_originalOnDoneFns=[];_originalOnStartFns=[];_started=!1;_destroyed=!1;_finished=!1;_position=0;parentPlayer=null;totalTime;constructor(lt=0,rn=0){this.totalTime=lt+rn}_onFinish(){this._finished||(this._finished=!0,this._onDoneFns.forEach(lt=>lt()),this._onDoneFns=[])}onStart(lt){this._originalOnStartFns.push(lt),this._onStartFns.push(lt)}onDone(lt){this._originalOnDoneFns.push(lt),this._onDoneFns.push(lt)}onDestroy(lt){this._onDestroyFns.push(lt)}hasStarted(){return this._started}init(){}play(){this.hasStarted()||(this._onStart(),this.triggerMicrotask()),this._started=!0}triggerMicrotask(){queueMicrotask(()=>this._onFinish())}_onStart(){this._onStartFns.forEach(lt=>lt()),this._onStartFns=[]}pause(){}restart(){}finish(){this._onFinish()}destroy(){this._destroyed||(this._destroyed=!0,this.hasStarted()||this._onStart(),this.finish(),this._onDestroyFns.forEach(lt=>lt()),this._onDestroyFns=[])}reset(){this._started=!1,this._finished=!1,this._onStartFns=this._originalOnStartFns,this._onDoneFns=this._originalOnDoneFns}setPosition(lt){this._position=this.totalTime?lt*this.totalTime:1}getPosition(){return this.totalTime?this._position/this.totalTime:1}triggerCallback(lt){const rn="start"==lt?this._onStartFns:this._onDoneFns;rn.forEach(gn=>gn()),rn.length=0}}class at{_onDoneFns=[];_onStartFns=[];_finished=!1;_started=!1;_destroyed=!1;_onDestroyFns=[];parentPlayer=null;totalTime=0;players;constructor(lt){this.players=lt;let rn=0,gn=0,bn=0;const Vn=this.players.length;0==Vn?queueMicrotask(()=>this._onFinish()):this.players.forEach(yn=>{yn.onDone(()=>{++rn==Vn&&this._onFinish()}),yn.onDestroy(()=>{++gn==Vn&&this._onDestroy()}),yn.onStart(()=>{++bn==Vn&&this._onStart()})}),this.totalTime=this.players.reduce((yn,qe)=>Math.max(yn,qe.totalTime),0)}_onFinish(){this._finished||(this._finished=!0,this._onDoneFns.forEach(lt=>lt()),this._onDoneFns=[])}init(){this.players.forEach(lt=>lt.init())}onStart(lt){this._onStartFns.push(lt)}_onStart(){this.hasStarted()||(this._started=!0,this._onStartFns.forEach(lt=>lt()),this._onStartFns=[])}onDone(lt){this._onDoneFns.push(lt)}onDestroy(lt){this._onDestroyFns.push(lt)}hasStarted(){return this._started}play(){this.parentPlayer||this.init(),this._onStart(),this.players.forEach(lt=>lt.play())}pause(){this.players.forEach(lt=>lt.pause())}restart(){this.players.forEach(lt=>lt.restart())}finish(){this._onFinish(),this.players.forEach(lt=>lt.finish())}destroy(){this._onDestroy()}_onDestroy(){this._destroyed||(this._destroyed=!0,this._onFinish(),this.players.forEach(lt=>lt.destroy()),this._onDestroyFns.forEach(lt=>lt()),this._onDestroyFns=[])}reset(){this.players.forEach(lt=>lt.reset()),this._destroyed=!1,this._finished=!1,this._started=!1}setPosition(lt){const rn=lt*this.totalTime;this.players.forEach(gn=>{const bn=gn.totalTime?Math.min(1,rn/gn.totalTime):1;gn.setPosition(bn)})}getPosition(){const lt=this.players.reduce((rn,gn)=>null===rn||gn.totalTime>rn.totalTime?gn:rn,null);return null!=lt?lt.getPosition():0}beforeDestroy(){this.players.forEach(lt=>{lt.beforeDestroy&<.beforeDestroy()})}triggerCallback(lt){const rn="start"==lt?this._onStartFns:this._onDoneFns;rn.forEach(gn=>gn()),rn.length=0}}const dt="!"},8559:(o,s,r)=>{"use strict";r.d(s,{Pd:()=>si,Au:()=>_t,vr:()=>rn,Bu:()=>ze,FN:()=>Ve,GX:()=>Fe,Q_:()=>Er,Z7:()=>Ee,Ai:()=>Vr,g7:()=>Zi,px:()=>ue,_G:()=>ft,w6:()=>mt,Ae:()=>Ce});var i=r(4460),a=r(3107),c=r(2147),y=r(5467),w=r(5919),C=r(8447),T=r(5710),M=(r(1531),r(3016)),O=r(1217),L=r(2040),Z=r(8627),q=r(1483),re=r(7947),se=(r(7610),r(1866)),ae=r(6645),me=r(5424),Oe=r(7747),xe=r(3022),De=r(6520);const ce=" ";function ue(Jt,Tt,nt){const Rt=Be(Jt,Tt);nt=nt.trim(),!Rt.some(sn=>sn.trim()===nt)&&(Rt.push(nt),Jt.setAttribute(Tt,Rt.join(ce)))}function Ce(Jt,Tt,nt){const Rt=Be(Jt,Tt);nt=nt.trim();const sn=Rt.filter(mn=>mn!==nt);sn.length?Jt.setAttribute(Tt,sn.join(ce)):Jt.removeAttribute(Tt)}function Be(Jt,Tt){return Jt.getAttribute(Tt)?.match(/\S+/g)??[]}const dt="cdk-describedby-message",bt="cdk-describedby-host";let lt=0,rn=(()=>{class Jt{_platform=(0,a.WQX)(c.OD);_document=(0,a.WQX)(i.qQ);_messageRegistry=new Map;_messagesContainer=null;_id=""+lt++;constructor(){(0,a.WQX)(y.l).load(y.Y),this._id=(0,a.WQX)(a.sZ2)+"-"+lt++}describe(nt,Rt,sn){if(!this._canBeDescribed(nt,Rt))return;const mn=gn(Rt,sn);"string"!=typeof Rt?(bn(Rt,this._id),this._messageRegistry.set(mn,{messageElement:Rt,referenceCount:0})):this._messageRegistry.has(mn)||this._createMessageElement(Rt,sn),this._isElementDescribedByMessage(nt,mn)||this._addMessageReference(nt,mn)}removeDescription(nt,Rt,sn){if(!Rt||!this._isElementNode(nt))return;const mn=gn(Rt,sn);if(this._isElementDescribedByMessage(nt,mn)&&this._removeMessageReference(nt,mn),"string"==typeof Rt){const dr=this._messageRegistry.get(mn);dr&&0===dr.referenceCount&&this._deleteMessageElement(mn)}0===this._messagesContainer?.childNodes.length&&(this._messagesContainer.remove(),this._messagesContainer=null)}ngOnDestroy(){const nt=this._document.querySelectorAll(`[${bt}="${this._id}"]`);for(let Rt=0;Rt0!=sn.indexOf(dt));nt.setAttribute("aria-describedby",Rt.join(" "))}_addMessageReference(nt,Rt){const sn=this._messageRegistry.get(Rt);ue(nt,"aria-describedby",sn.messageElement.id),nt.setAttribute(bt,this._id),sn.referenceCount++}_removeMessageReference(nt,Rt){const sn=this._messageRegistry.get(Rt);sn.referenceCount--,Ce(nt,"aria-describedby",sn.messageElement.id),nt.removeAttribute(bt)}_isElementDescribedByMessage(nt,Rt){const sn=Be(nt,"aria-describedby"),mn=this._messageRegistry.get(Rt),dr=mn&&mn.messageElement.id;return!!dr&&-1!=sn.indexOf(dr)}_canBeDescribed(nt,Rt){if(!this._isElementNode(nt))return!1;if(Rt&&"object"==typeof Rt)return!0;const sn=null==Rt?"":`${Rt}`.trim(),mn=nt.getAttribute("aria-label");return!(!sn||mn&&mn.trim()===sn)}_isElementNode(nt){return nt.nodeType===this._document.ELEMENT_NODE}static \u0275fac=function(Rt){return new(Rt||Jt)};static \u0275prov=a.jDH({token:Jt,factory:Jt.\u0275fac,providedIn:"root"})}return Jt})();function gn(Jt,Tt){return"string"==typeof Jt?`${Tt||""}/${Jt}`:Jt}function bn(Jt,Tt){Jt.id||(Jt.id=`${dt}-${Tt}-${lt++}`)}class yn{_letterKeyStream=new C.B;_items=[];_selectedItemIndex=-1;_pressedLetters=[];_skipPredicateFn;_selectedItem=new C.B;selectedItem=this._selectedItem;constructor(Tt,nt){const Rt="number"==typeof nt?.debounceInterval?nt.debounceInterval:200;nt?.skipPredicate&&(this._skipPredicateFn=nt.skipPredicate),this.setItems(Tt),this._setupKeyHandler(Rt)}destroy(){this._pressedLetters=[],this._letterKeyStream.complete(),this._selectedItem.complete()}setCurrentSelectedItemIndex(Tt){this._selectedItemIndex=Tt}setItems(Tt){this._items=Tt}handleKey(Tt){const nt=Tt.keyCode;Tt.key&&1===Tt.key.length?this._letterKeyStream.next(Tt.key.toLocaleUpperCase()):(nt>=w.A&&nt<=w.Z||nt>=w.f2&&nt<=w.bn)&&this._letterKeyStream.next(String.fromCharCode(nt))}isTyping(){return this._pressedLetters.length>0}reset(){this._pressedLetters=[]}_setupKeyHandler(Tt){this._letterKeyStream.pipe((0,L.M)(nt=>this._pressedLetters.push(nt)),(0,Z.B)(Tt),(0,q.p)(()=>this._pressedLetters.length>0),(0,re.T)(()=>this._pressedLetters.join("").toLocaleUpperCase())).subscribe(nt=>{for(let Rt=1;RtTt.disabled;constructor(Tt,nt){this._items=Tt,Tt instanceof a.rOR?this._itemChangesSubscription=Tt.changes.subscribe(Rt=>this._itemsChanged(Rt.toArray())):(0,a.Hps)(Tt)&&(this._effectRef=(0,a.QZP)(()=>this._itemsChanged(Tt()),{injector:nt}))}tabOut=new C.B;change=new C.B;skipPredicate(Tt){return this._skipPredicateFn=Tt,this}withWrap(Tt=!0){return this._wrap=Tt,this}withVerticalOrientation(Tt=!0){return this._vertical=Tt,this}withHorizontalOrientation(Tt){return this._horizontal=Tt,this}withAllowedModifierKeys(Tt){return this._allowedModifierKeys=Tt,this}withTypeAhead(Tt=200){this._typeaheadSubscription.unsubscribe();const nt=this._getItemsArray();return this._typeahead=new yn(nt,{debounceInterval:"number"==typeof Tt?Tt:void 0,skipPredicate:Rt=>this._skipPredicateFn(Rt)}),this._typeaheadSubscription=this._typeahead.selectedItem.subscribe(Rt=>{this.setActiveItem(Rt)}),this}cancelTypeahead(){return this._typeahead?.reset(),this}withHomeAndEnd(Tt=!0){return this._homeAndEnd=Tt,this}withPageUpDown(Tt=!0,nt=10){return this._pageUpAndDown={enabled:Tt,delta:nt},this}setActiveItem(Tt){const nt=this._activeItem();this.updateActiveItem(Tt),this._activeItem()!==nt&&this.change.next(this._activeItemIndex)}onKeydown(Tt){const nt=Tt.keyCode,sn=["altKey","ctrlKey","metaKey","shiftKey"].every(mn=>!Tt[mn]||this._allowedModifierKeys.indexOf(mn)>-1);switch(nt){case w.wn:return void this.tabOut.next();case w.n6:if(this._vertical&&sn){this.setNextItemActive();break}return;case w.i7:if(this._vertical&&sn){this.setPreviousItemActive();break}return;case w.LE:if(this._horizontal&&sn){"rtl"===this._horizontal?this.setPreviousItemActive():this.setNextItemActive();break}return;case w.UQ:if(this._horizontal&&sn){"rtl"===this._horizontal?this.setNextItemActive():this.setPreviousItemActive();break}return;case w.yZ:if(this._homeAndEnd&&sn){this.setFirstItemActive();break}return;case w.Kp:if(this._homeAndEnd&&sn){this.setLastItemActive();break}return;case w.w_:if(this._pageUpAndDown.enabled&&sn){const mn=this._activeItemIndex-this._pageUpAndDown.delta;this._setActiveItemByIndex(mn>0?mn:0,1);break}return;case w.dB:if(this._pageUpAndDown.enabled&&sn){const mn=this._activeItemIndex+this._pageUpAndDown.delta,dr=this._getItemsArray().length;this._setActiveItemByIndex(mn-1&&Rt!==this._activeItemIndex&&(this._activeItemIndex=Rt,this._typeahead?.setCurrentSelectedItemIndex(Rt))}}}class _t extends qe{setActiveItem(Tt){this.activeItem&&this.activeItem.setInactiveStyles(),super.setActiveItem(Tt),this.activeItem&&this.activeItem.setActiveStyles()}}class ze extends qe{_origin="program";setFocusOrigin(Tt){return this._origin=Tt,this}setActiveItem(Tt){super.setActiveItem(Tt),this.activeItem&&this.activeItem.focus(this._origin)}}let Ee=(()=>{class Jt{_platform=(0,a.WQX)(c.OD);constructor(){}isDisabled(nt){return nt.hasAttribute("disabled")}isVisible(nt){return function Xt(Jt){return!!(Jt.offsetWidth||Jt.offsetHeight||"function"==typeof Jt.getClientRects&&Jt.getClientRects().length)}(nt)&&"visible"===getComputedStyle(nt).visibility}isTabbable(nt){if(!this._platform.isBrowser)return!1;const Rt=function st(Jt){try{return Jt.frameElement}catch{return null}}(function pr(Jt){return Jt.ownerDocument&&Jt.ownerDocument.defaultView||window}(nt));if(Rt&&(-1===Kn(Rt)||!this.isVisible(Rt)))return!1;let sn=nt.nodeName.toLowerCase(),mn=Kn(nt);return nt.hasAttribute("contenteditable")?-1!==mn:!("iframe"===sn||"object"===sn||this._platform.WEBKIT&&this._platform.IOS&&!function Nr(Jt){let Tt=Jt.nodeName.toLowerCase(),nt="input"===Tt&&Jt.type;return"text"===nt||"password"===nt||"select"===Tt||"textarea"===Tt}(nt))&&("audio"===sn?!!nt.hasAttribute("controls")&&-1!==mn:"video"===sn?-1!==mn&&(null!==mn||this._platform.FIREFOX||nt.hasAttribute("controls")):nt.tabIndex>=0)}isFocusable(nt,Rt){return function Rn(Jt){return!function Kt(Jt){return function Vt(Jt){return"input"==Jt.nodeName.toLowerCase()}(Jt)&&"hidden"==Jt.type}(Jt)&&(function Mt(Jt){let Tt=Jt.nodeName.toLowerCase();return"input"===Tt||"select"===Tt||"button"===Tt||"textarea"===Tt}(Jt)||function rt(Jt){return function en(Jt){return"a"==Jt.nodeName.toLowerCase()}(Jt)&&Jt.hasAttribute("href")}(Jt)||Jt.hasAttribute("contenteditable")||kn(Jt))}(nt)&&!this.isDisabled(nt)&&(Rt?.ignoreVisibility||this.isVisible(nt))}static \u0275fac=function(Rt){return new(Rt||Jt)};static \u0275prov=a.jDH({token:Jt,factory:Jt.\u0275fac,providedIn:"root"})}return Jt})();function kn(Jt){if(!Jt.hasAttribute("tabindex")||void 0===Jt.tabIndex)return!1;let Tt=Jt.getAttribute("tabindex");return!(!Tt||isNaN(parseInt(Tt,10)))}function Kn(Jt){if(!kn(Jt))return null;const Tt=parseInt(Jt.getAttribute("tabindex")||"",10);return isNaN(Tt)?-1:Tt}class cn{_element;_checker;_ngZone;_document;_injector;_startAnchor;_endAnchor;_hasAttached=!1;startAnchorListener=()=>this.focusLastTabbableElement();endAnchorListener=()=>this.focusFirstTabbableElement();get enabled(){return this._enabled}set enabled(Tt){this._enabled=Tt,this._startAnchor&&this._endAnchor&&(this._toggleAnchorTabIndex(Tt,this._startAnchor),this._toggleAnchorTabIndex(Tt,this._endAnchor))}_enabled=!0;constructor(Tt,nt,Rt,sn,mn=!1,dr){this._element=Tt,this._checker=nt,this._ngZone=Rt,this._document=sn,this._injector=dr,mn||this.attachAnchors()}destroy(){const Tt=this._startAnchor,nt=this._endAnchor;Tt&&(Tt.removeEventListener("focus",this.startAnchorListener),Tt.remove()),nt&&(nt.removeEventListener("focus",this.endAnchorListener),nt.remove()),this._startAnchor=this._endAnchor=null,this._hasAttached=!1}attachAnchors(){return!!this._hasAttached||(this._ngZone.runOutsideAngular(()=>{this._startAnchor||(this._startAnchor=this._createAnchor(),this._startAnchor.addEventListener("focus",this.startAnchorListener)),this._endAnchor||(this._endAnchor=this._createAnchor(),this._endAnchor.addEventListener("focus",this.endAnchorListener))}),this._element.parentNode&&(this._element.parentNode.insertBefore(this._startAnchor,this._element),this._element.parentNode.insertBefore(this._endAnchor,this._element.nextSibling),this._hasAttached=!0),this._hasAttached)}focusInitialElementWhenReady(Tt){return new Promise(nt=>{this._executeOnStable(()=>nt(this.focusInitialElement(Tt)))})}focusFirstTabbableElementWhenReady(Tt){return new Promise(nt=>{this._executeOnStable(()=>nt(this.focusFirstTabbableElement(Tt)))})}focusLastTabbableElementWhenReady(Tt){return new Promise(nt=>{this._executeOnStable(()=>nt(this.focusLastTabbableElement(Tt)))})}_getRegionBoundary(Tt){const nt=this._element.querySelectorAll(`[cdk-focus-region-${Tt}], [cdkFocusRegion${Tt}], [cdk-focus-${Tt}]`);return"start"==Tt?nt.length?nt[0]:this._getFirstTabbableElement(this._element):nt.length?nt[nt.length-1]:this._getLastTabbableElement(this._element)}focusInitialElement(Tt){const nt=this._element.querySelector("[cdk-focus-initial], [cdkFocusInitial]");if(nt){if(!this._checker.isFocusable(nt)){const Rt=this._getFirstTabbableElement(nt);return Rt?.focus(Tt),!!Rt}return nt.focus(Tt),!0}return this.focusFirstTabbableElement(Tt)}focusFirstTabbableElement(Tt){const nt=this._getRegionBoundary("start");return nt&&nt.focus(Tt),!!nt}focusLastTabbableElement(Tt){const nt=this._getRegionBoundary("end");return nt&&nt.focus(Tt),!!nt}hasAttached(){return this._hasAttached}_getFirstTabbableElement(Tt){if(this._checker.isFocusable(Tt)&&this._checker.isTabbable(Tt))return Tt;const nt=Tt.children;for(let Rt=0;Rt=0;Rt--){const sn=nt[Rt].nodeType===this._document.ELEMENT_NODE?this._getLastTabbableElement(nt[Rt]):null;if(sn)return sn}return null}_createAnchor(){const Tt=this._document.createElement("div");return this._toggleAnchorTabIndex(this._enabled,Tt),Tt.classList.add("cdk-visually-hidden"),Tt.classList.add("cdk-focus-trap-anchor"),Tt.setAttribute("aria-hidden","true"),Tt}_toggleAnchorTabIndex(Tt,nt){Tt?nt.setAttribute("tabindex","0"):nt.removeAttribute("tabindex")}toggleAnchors(Tt){this._startAnchor&&this._endAnchor&&(this._toggleAnchorTabIndex(Tt,this._startAnchor),this._toggleAnchorTabIndex(Tt,this._endAnchor))}_executeOnStable(Tt){this._injector?(0,a.mal)(Tt,{injector:this._injector}):setTimeout(Tt)}}let Fe=(()=>{class Jt{_checker=(0,a.WQX)(Ee);_ngZone=(0,a.WQX)(a.SKi);_document=(0,a.WQX)(i.qQ);_injector=(0,a.WQX)(a.zZn);constructor(){(0,a.WQX)(y.l).load(y.Y)}create(nt,Rt=!1){return new cn(nt,this._checker,this._ngZone,this._document,Rt,this._injector)}static \u0275fac=function(Rt){return new(Rt||Jt)};static \u0275prov=a.jDH({token:Jt,factory:Jt.\u0275fac,providedIn:"root"})}return Jt})();function ft(Jt){return 0===Jt.buttons||0===Jt.detail}function mt(Jt){const Tt=Jt.touches&&Jt.touches[0]||Jt.changedTouches&&Jt.changedTouches[0];return!(!Tt||-1!==Tt.identifier||null!=Tt.radiusX&&1!==Tt.radiusX||null!=Tt.radiusY&&1!==Tt.radiusY)}const St=new a.nKC("cdk-input-modality-detector-options"),Tn={ignoreKeys:[w.A$,w.W3,w.eg,w.Ge,w.FX]},dn=(0,c.BQ)({passive:!0,capture:!0});let In=(()=>{class Jt{_platform=(0,a.WQX)(c.OD);modalityDetected;modalityChanged;get mostRecentModality(){return this._modality.value}_mostRecentTarget=null;_modality=new O.t(null);_options;_lastTouchMs=0;_onKeydown=nt=>{this._options?.ignoreKeys?.some(Rt=>Rt===nt.keyCode)||(this._modality.next("keyboard"),this._mostRecentTarget=(0,c.Fb)(nt))};_onMousedown=nt=>{Date.now()-this._lastTouchMs<650||(this._modality.next(ft(nt)?"keyboard":"mouse"),this._mostRecentTarget=(0,c.Fb)(nt))};_onTouchstart=nt=>{mt(nt)?this._modality.next("keyboard"):(this._lastTouchMs=Date.now(),this._modality.next("touch"),this._mostRecentTarget=(0,c.Fb)(nt))};constructor(){const nt=(0,a.WQX)(a.SKi),Rt=(0,a.WQX)(i.qQ),sn=(0,a.WQX)(St,{optional:!0});this._options={...Tn,...sn},this.modalityDetected=this._modality.pipe((0,se.i)(1)),this.modalityChanged=this.modalityDetected.pipe((0,ae.F)()),this._platform.isBrowser&&nt.runOutsideAngular(()=>{Rt.addEventListener("keydown",this._onKeydown,dn),Rt.addEventListener("mousedown",this._onMousedown,dn),Rt.addEventListener("touchstart",this._onTouchstart,dn)})}ngOnDestroy(){this._modality.complete(),this._platform.isBrowser&&(document.removeEventListener("keydown",this._onKeydown,dn),document.removeEventListener("mousedown",this._onMousedown,dn),document.removeEventListener("touchstart",this._onTouchstart,dn))}static \u0275fac=function(Rt){return new(Rt||Jt)};static \u0275prov=a.jDH({token:Jt,factory:Jt.\u0275fac,providedIn:"root"})}return Jt})();const sr=new a.nKC("liveAnnouncerElement",{providedIn:"root",factory:function xn(){return null}}),Hr=new a.nKC("LIVE_ANNOUNCER_DEFAULT_OPTIONS");let Tr=0,Vr=(()=>{class Jt{_ngZone=(0,a.WQX)(a.SKi);_defaultOptions=(0,a.WQX)(Hr,{optional:!0});_liveElement;_document=(0,a.WQX)(i.qQ);_previousTimeout;_currentPromise;_currentResolve;constructor(){const nt=(0,a.WQX)(sr,{optional:!0});this._liveElement=nt||this._createLiveElement()}announce(nt,...Rt){const sn=this._defaultOptions;let mn,dr;return 1===Rt.length&&"number"==typeof Rt[0]?dr=Rt[0]:[mn,dr]=Rt,this.clear(),clearTimeout(this._previousTimeout),mn||(mn=sn&&sn.politeness?sn.politeness:"polite"),null==dr&&sn&&(dr=sn.duration),this._liveElement.setAttribute("aria-live",mn),this._liveElement.id&&this._exposeAnnouncerToModals(this._liveElement.id),this._ngZone.runOutsideAngular(()=>(this._currentPromise||(this._currentPromise=new Promise(Co=>this._currentResolve=Co)),clearTimeout(this._previousTimeout),this._previousTimeout=setTimeout(()=>{this._liveElement.textContent=nt,"number"==typeof dr&&(this._previousTimeout=setTimeout(()=>this.clear(),dr)),this._currentResolve?.(),this._currentPromise=this._currentResolve=void 0},100),this._currentPromise))}clear(){this._liveElement&&(this._liveElement.textContent="")}ngOnDestroy(){clearTimeout(this._previousTimeout),this._liveElement?.remove(),this._liveElement=null,this._currentResolve?.(),this._currentPromise=this._currentResolve=void 0}_createLiveElement(){const nt="cdk-live-announcer-element",Rt=this._document.getElementsByClassName(nt),sn=this._document.createElement("div");for(let mn=0;mn .cdk-overlay-container [aria-modal="true"]');for(let sn=0;sn{class Jt{_ngZone=(0,a.WQX)(a.SKi);_platform=(0,a.WQX)(c.OD);_inputModalityDetector=(0,a.WQX)(In);_origin=null;_lastFocusOrigin;_windowFocused=!1;_windowFocusTimeoutId;_originTimeoutId;_originFromTouchInteraction=!1;_elementInfo=new Map;_monitoredElementCount=0;_rootNodeFocusListenerCount=new Map;_detectionMode;_windowFocusListener=()=>{this._windowFocused=!0,this._windowFocusTimeoutId=window.setTimeout(()=>this._windowFocused=!1)};_document=(0,a.WQX)(i.qQ,{optional:!0});_stopInputModalityDetector=new C.B;constructor(){const nt=(0,a.WQX)(Re,{optional:!0});this._detectionMode=nt?.detectionMode||Wt.IMMEDIATE}_rootNodeFocusAndBlurListener=nt=>{for(let sn=(0,c.Fb)(nt);sn;sn=sn.parentElement)"focus"===nt.type?this._onFocus(nt,sn):this._onBlur(nt,sn)};monitor(nt,Rt=!1){const sn=(0,xe.i8)(nt);if(!this._platform.isBrowser||1!==sn.nodeType)return(0,M.of)();const mn=(0,c.KT)(sn)||this._getDocument(),dr=this._elementInfo.get(sn);if(dr)return Rt&&(dr.checkChildren=!0),dr.subject;const Co={checkChildren:Rt,subject:new C.B,rootNode:mn};return this._elementInfo.set(sn,Co),this._registerGlobalListeners(Co),Co.subject}stopMonitoring(nt){const Rt=(0,xe.i8)(nt),sn=this._elementInfo.get(Rt);sn&&(sn.subject.complete(),this._setClasses(Rt),this._elementInfo.delete(Rt),this._removeGlobalListeners(sn))}focusVia(nt,Rt,sn){const mn=(0,xe.i8)(nt);mn===this._getDocument().activeElement?this._getClosestElementsInfo(mn).forEach(([Co,Ni])=>this._originChanged(Co,Rt,Ni)):(this._setOrigin(Rt),"function"==typeof mn.focus&&mn.focus(sn))}ngOnDestroy(){this._elementInfo.forEach((nt,Rt)=>this.stopMonitoring(Rt))}_getDocument(){return this._document||document}_getWindow(){return this._getDocument().defaultView||window}_getFocusOrigin(nt){return this._origin?this._originFromTouchInteraction?this._shouldBeAttributedToTouch(nt)?"touch":"program":this._origin:this._windowFocused&&this._lastFocusOrigin?this._lastFocusOrigin:nt&&this._isLastInteractionFromInputLabel(nt)?"mouse":"program"}_shouldBeAttributedToTouch(nt){return this._detectionMode===Wt.EVENTUAL||!!nt?.contains(this._inputModalityDetector._mostRecentTarget)}_setClasses(nt,Rt){nt.classList.toggle("cdk-focused",!!Rt),nt.classList.toggle("cdk-touch-focused","touch"===Rt),nt.classList.toggle("cdk-keyboard-focused","keyboard"===Rt),nt.classList.toggle("cdk-mouse-focused","mouse"===Rt),nt.classList.toggle("cdk-program-focused","program"===Rt)}_setOrigin(nt,Rt=!1){this._ngZone.runOutsideAngular(()=>{this._origin=nt,this._originFromTouchInteraction="touch"===nt&&Rt,this._detectionMode===Wt.IMMEDIATE&&(clearTimeout(this._originTimeoutId),this._originTimeoutId=setTimeout(()=>this._origin=null,this._originFromTouchInteraction?650:1))})}_onFocus(nt,Rt){const sn=this._elementInfo.get(Rt),mn=(0,c.Fb)(nt);!sn||!sn.checkChildren&&Rt!==mn||this._originChanged(Rt,this._getFocusOrigin(mn),sn)}_onBlur(nt,Rt){const sn=this._elementInfo.get(Rt);!sn||sn.checkChildren&&nt.relatedTarget instanceof Node&&Rt.contains(nt.relatedTarget)||(this._setClasses(Rt),this._emitOrigin(sn,null))}_emitOrigin(nt,Rt){nt.subject.observers.length&&this._ngZone.run(()=>nt.subject.next(Rt))}_registerGlobalListeners(nt){if(!this._platform.isBrowser)return;const Rt=nt.rootNode,sn=this._rootNodeFocusListenerCount.get(Rt)||0;sn||this._ngZone.runOutsideAngular(()=>{Rt.addEventListener("focus",this._rootNodeFocusAndBlurListener,Ge),Rt.addEventListener("blur",this._rootNodeFocusAndBlurListener,Ge)}),this._rootNodeFocusListenerCount.set(Rt,sn+1),1==++this._monitoredElementCount&&(this._ngZone.runOutsideAngular(()=>{this._getWindow().addEventListener("focus",this._windowFocusListener)}),this._inputModalityDetector.modalityDetected.pipe((0,me.Q)(this._stopInputModalityDetector)).subscribe(mn=>{this._setOrigin(mn,!0)}))}_removeGlobalListeners(nt){const Rt=nt.rootNode;if(this._rootNodeFocusListenerCount.has(Rt)){const sn=this._rootNodeFocusListenerCount.get(Rt);sn>1?this._rootNodeFocusListenerCount.set(Rt,sn-1):(Rt.removeEventListener("focus",this._rootNodeFocusAndBlurListener,Ge),Rt.removeEventListener("blur",this._rootNodeFocusAndBlurListener,Ge),this._rootNodeFocusListenerCount.delete(Rt))}--this._monitoredElementCount||(this._getWindow().removeEventListener("focus",this._windowFocusListener),this._stopInputModalityDetector.next(),clearTimeout(this._windowFocusTimeoutId),clearTimeout(this._originTimeoutId))}_originChanged(nt,Rt,sn){this._setClasses(nt,Rt),this._emitOrigin(sn,Rt),this._lastFocusOrigin=Rt}_getClosestElementsInfo(nt){const Rt=[];return this._elementInfo.forEach((sn,mn)=>{(mn===nt||sn.checkChildren&&mn.contains(nt))&&Rt.push([mn,sn])}),Rt}_isLastInteractionFromInputLabel(nt){const{_mostRecentTarget:Rt,mostRecentModality:sn}=this._inputModalityDetector;if("mouse"!==sn||!Rt||Rt===nt||"INPUT"!==nt.nodeName&&"TEXTAREA"!==nt.nodeName||nt.disabled)return!1;const mn=nt.labels;if(mn)for(let dr=0;dr{class Jt{_platform=(0,a.WQX)(c.OD);_hasCheckedHighContrastMode;_document=(0,a.WQX)(i.qQ);_breakpointSubscription;constructor(){this._breakpointSubscription=(0,a.WQX)(De.QP).observe("(forced-colors: active)").subscribe(()=>{this._hasCheckedHighContrastMode&&(this._hasCheckedHighContrastMode=!1,this._applyBodyHighContrastModeCssClasses())})}getHighContrastMode(){if(!this._platform.isBrowser)return ct.NONE;const nt=this._document.createElement("div");nt.style.backgroundColor="rgb(1,2,3)",nt.style.position="absolute",this._document.body.appendChild(nt);const Rt=this._document.defaultView||window,sn=Rt&&Rt.getComputedStyle?Rt.getComputedStyle(nt):null,mn=(sn&&sn.backgroundColor||"").replace(/ /g,"");switch(nt.remove(),mn){case"rgb(0,0,0)":case"rgb(45,50,54)":case"rgb(32,32,32)":return ct.WHITE_ON_BLACK;case"rgb(255,255,255)":case"rgb(255,250,239)":return ct.BLACK_ON_WHITE}return ct.NONE}ngOnDestroy(){this._breakpointSubscription.unsubscribe()}_applyBodyHighContrastModeCssClasses(){if(!this._hasCheckedHighContrastMode&&this._platform.isBrowser&&this._document.body){const nt=this._document.body.classList;nt.remove(qn,Bt,wn),this._hasCheckedHighContrastMode=!0;const Rt=this.getHighContrastMode();Rt===ct.BLACK_ON_WHITE?nt.add(qn,Bt):Rt===ct.WHITE_ON_BLACK&&nt.add(qn,wn)}}static \u0275fac=function(Rt){return new(Rt||Jt)};static \u0275prov=a.jDH({token:Jt,factory:Jt.\u0275fac,providedIn:"root"})}return Jt})(),si=(()=>{class Jt{constructor(){(0,a.WQX)(Er)._applyBodyHighContrastModeCssClasses()}static \u0275fac=function(Rt){return new(Rt||Jt)};static \u0275mod=a.$C({type:Jt});static \u0275inj=a.G2t({imports:[Oe.w5]})}return Jt})();const hi={};let Zi=(()=>{class Jt{_appId=(0,a.WQX)(a.sZ2);getId(nt){return"ng"!==this._appId&&(nt+=this._appId),hi.hasOwnProperty(nt)||(hi[nt]=0),`${nt}${hi[nt]++}`}static \u0275fac=function(Rt){return new(Rt||Jt)};static \u0275prov=a.jDH({token:Jt,factory:Jt.\u0275fac,providedIn:"root"})}return Jt})()},2944:(o,s,r)=>{"use strict";r.d(s,{dS:()=>T,jI:()=>M});var i=r(3107),a=r(4460);const c=new i.nKC("cdk-dir-doc",{providedIn:"root",factory:function y(){return(0,i.WQX)(a.qQ)}}),w=/^(ar|ckb|dv|he|iw|fa|nqo|ps|sd|ug|ur|yi|.*[-_](Adlm|Arab|Hebr|Nkoo|Rohg|Thaa))(?!.*[-_](Latn|Cyrl)($|-|_))($|-|_)/i;let T=(()=>{class O{value="ltr";change=new i.bkB;constructor(){const Z=(0,i.WQX)(c,{optional:!0});Z&&(this.value=function C(O){const L=O?.toLowerCase()||"";return"auto"===L&&typeof navigator<"u"&&navigator?.language?w.test(navigator.language)?"rtl":"ltr":"rtl"===L?"rtl":"ltr"}((Z.body?Z.body.dir:null)||(Z.documentElement?Z.documentElement.dir:null)||"ltr"))}ngOnDestroy(){this.change.complete()}static \u0275fac=function(q){return new(q||O)};static \u0275prov=i.jDH({token:O,factory:O.\u0275fac,providedIn:"root"})}return O})(),M=(()=>{class O{static \u0275fac=function(q){return new(q||O)};static \u0275mod=i.$C({type:O});static \u0275inj=i.G2t({})}return O})()},3022:(o,s,r)=>{"use strict";r.d(s,{FG:()=>w,OE:()=>c,a1:()=>C,he:()=>a,i8:()=>T});var i=r(3107);function a(M){return null!=M&&"false"!=`${M}`}function c(M,O=0){return function y(M){return!isNaN(parseFloat(M))&&!isNaN(Number(M))}(M)?Number(M):2===arguments.length?O:0}function w(M){return Array.isArray(M)?M:[M]}function C(M){return null==M?"":"string"==typeof M?M:`${M}px`}function T(M){return M instanceof i.aKT?M.nativeElement:M}},1349:(o,s,r)=>{"use strict";r.d(s,{CB:()=>Z,zP:()=>re}),r(1531),r(3016);var c=r(8447),y=r(3107);class Z{_multiple;_emitChanges;compareWith;_selection=new Set;_deselectedToEmit=[];_selectedToEmit=[];_selected;get selected(){return this._selected||(this._selected=Array.from(this._selection.values())),this._selected}changed=new c.B;constructor(se=!1,ae,me=!0,be){this._multiple=se,this._emitChanges=me,this.compareWith=be,ae&&ae.length&&(se?ae.forEach(Oe=>this._markSelected(Oe)):this._markSelected(ae[0]),this._selectedToEmit.length=0)}select(...se){this._verifyValueAssignment(se),se.forEach(me=>this._markSelected(me));const ae=this._hasQueuedChanges();return this._emitChangeEvent(),ae}deselect(...se){this._verifyValueAssignment(se),se.forEach(me=>this._unmarkSelected(me));const ae=this._hasQueuedChanges();return this._emitChangeEvent(),ae}setSelection(...se){this._verifyValueAssignment(se);const ae=this.selected,me=new Set(se);se.forEach(Oe=>this._markSelected(Oe)),ae.filter(Oe=>!me.has(this._getConcreteValue(Oe,me))).forEach(Oe=>this._unmarkSelected(Oe));const be=this._hasQueuedChanges();return this._emitChangeEvent(),be}toggle(se){return this.isSelected(se)?this.deselect(se):this.select(se)}clear(se=!0){this._unmarkAll();const ae=this._hasQueuedChanges();return se&&this._emitChangeEvent(),ae}isSelected(se){return this._selection.has(this._getConcreteValue(se))}isEmpty(){return 0===this._selection.size}hasValue(){return!this.isEmpty()}sort(se){this._multiple&&this.selected&&this._selected.sort(se)}isMultipleSelection(){return this._multiple}_emitChangeEvent(){this._selected=null,(this._selectedToEmit.length||this._deselectedToEmit.length)&&(this.changed.next({source:this,added:this._selectedToEmit,removed:this._deselectedToEmit}),this._deselectedToEmit=[],this._selectedToEmit=[])}_markSelected(se){se=this._getConcreteValue(se),this.isSelected(se)||(this._multiple||this._unmarkAll(),this.isSelected(se)||this._selection.add(se),this._emitChanges&&this._selectedToEmit.push(se))}_unmarkSelected(se){se=this._getConcreteValue(se),this.isSelected(se)&&(this._selection.delete(se),this._emitChanges&&this._deselectedToEmit.push(se))}_unmarkAll(){this.isEmpty()||this._selection.forEach(se=>this._unmarkSelected(se))}_verifyValueAssignment(se){}_hasQueuedChanges(){return!(!this._deselectedToEmit.length&&!this._selectedToEmit.length)}_getConcreteValue(se,ae){if(this.compareWith){ae=ae??this._selection;for(let me of ae)if(this.compareWith(se,me))return me;return se}return se}}let re=(()=>{class pe{_listeners=[];notify(ae,me){for(let be of this._listeners)be(ae,me)}listen(ae){return this._listeners.push(ae),()=>{this._listeners=this._listeners.filter(me=>ae!==me)}}ngOnDestroy(){this._listeners=[]}static \u0275fac=function(me){return new(me||pe)};static \u0275prov=y.jDH({token:pe,factory:pe.\u0275fac,providedIn:"root"})}return pe})()},5919:(o,s,r)=>{"use strict";r.d(s,{A:()=>$e,A$:()=>S,FX:()=>C,Fm:()=>w,Ge:()=>N,Kp:()=>pe,LE:()=>be,UQ:()=>ae,W3:()=>T,Z:()=>z,_f:()=>L,bn:()=>Vn,dB:()=>re,eg:()=>Ye,f2:()=>Ce,i7:()=>me,n6:()=>Oe,rp:()=>Ne,t6:()=>Z,w_:()=>q,wn:()=>c,yZ:()=>se});const c=9,w=13,C=16,T=17,S=18,L=27,Z=32,q=33,re=34,pe=35,se=36,ae=37,me=38,be=39,Oe=40,Ce=48,Vn=57,$e=65,z=90,N=91,Ye=224;function Ne(gt,...Ht){return Ht.length?Ht.some(kt=>gt[kt]):gt.altKey||gt.shiftKey||gt.ctrlKey||gt.metaKey}},6520:(o,s,r)=>{"use strict";r.d(s,{QP:()=>Oe,Rp:()=>De});var i=r(3107),a=r(3022),c=r(8447),y=r(6627),w=r(3569),C=r(1698),T=r(7610),S=r(1866),M=r(8627),O=r(7947),L=r(593),Z=r(5424),q=r(2147);const pe=new Set;let se,ae=(()=>{class ce{_platform=(0,i.WQX)(q.OD);_nonce=(0,i.WQX)(i.BIS,{optional:!0});_matchMedia;constructor(){this._matchMedia=this._platform.isBrowser&&window.matchMedia?window.matchMedia.bind(window):be}matchMedia(Ce){return(this._platform.WEBKIT||this._platform.BLINK)&&function me(ce,ue){if(!pe.has(ce))try{se||(se=document.createElement("style"),ue&&se.setAttribute("nonce",ue),se.setAttribute("type","text/css"),document.head.appendChild(se)),se.sheet&&(se.sheet.insertRule(`@media ${ce} {body{ }}`,0),pe.add(ce))}catch(Ce){console.error(Ce)}}(Ce,this._nonce),this._matchMedia(Ce)}static \u0275fac=function(Be){return new(Be||ce)};static \u0275prov=i.jDH({token:ce,factory:ce.\u0275fac,providedIn:"root"})}return ce})();function be(ce){return{matches:"all"===ce||""===ce,media:ce,addListener:()=>{},removeListener:()=>{}}}let Oe=(()=>{class ce{_mediaMatcher=(0,i.WQX)(ae);_zone=(0,i.WQX)(i.SKi);_queries=new Map;_destroySubject=new c.B;constructor(){}ngOnDestroy(){this._destroySubject.next(),this._destroySubject.complete()}isMatched(Ce){return xe((0,a.FG)(Ce)).some(at=>this._registerQuery(at).mql.matches)}observe(Ce){const at=xe((0,a.FG)(Ce)).map(bt=>this._registerQuery(bt).observable);let dt=(0,y.z)(at);return dt=(0,w.x)(dt.pipe((0,T.s)(1)),dt.pipe((0,S.i)(1),(0,M.B)(0))),dt.pipe((0,O.T)(bt=>{const lt={matches:!1,breakpoints:{}};return bt.forEach(({matches:rn,query:gn})=>{lt.matches=lt.matches||rn,lt.breakpoints[gn]=rn}),lt}))}_registerQuery(Ce){if(this._queries.has(Ce))return this._queries.get(Ce);const Be=this._mediaMatcher.matchMedia(Ce),dt={observable:new C.c(bt=>{const lt=rn=>this._zone.run(()=>bt.next(rn));return Be.addListener(lt),()=>{Be.removeListener(lt)}}).pipe((0,L.Z)(Be),(0,O.T)(({matches:bt})=>({query:Ce,matches:bt})),(0,Z.Q)(this._destroySubject)),mql:Be};return this._queries.set(Ce,dt),dt}static \u0275fac=function(Be){return new(Be||ce)};static \u0275prov=i.jDH({token:ce,factory:ce.\u0275fac,providedIn:"root"})}return ce})();function xe(ce){return ce.map(ue=>ue.split(",")).reduce((ue,Ce)=>ue.concat(Ce)).map(ue=>ue.trim())}const De={XSmall:"(max-width: 599.98px)",Small:"(min-width: 600px) and (max-width: 959.98px)",Medium:"(min-width: 960px) and (max-width: 1279.98px)",Large:"(min-width: 1280px) and (max-width: 1919.98px)",XLarge:"(min-width: 1920px)",Handset:"(max-width: 599.98px) and (orientation: portrait), (max-width: 959.98px) and (orientation: landscape)",Tablet:"(min-width: 600px) and (max-width: 839.98px) and (orientation: portrait), (min-width: 960px) and (max-width: 1279.98px) and (orientation: landscape)",Web:"(min-width: 840px) and (orientation: portrait), (min-width: 1280px) and (orientation: landscape)",HandsetPortrait:"(max-width: 599.98px) and (orientation: portrait)",TabletPortrait:"(min-width: 600px) and (max-width: 839.98px) and (orientation: portrait)",WebPortrait:"(min-width: 840px) and (orientation: portrait)",HandsetLandscape:"(max-width: 959.98px) and (orientation: landscape)",TabletLandscape:"(min-width: 960px) and (max-width: 1279.98px) and (orientation: landscape)",WebLandscape:"(min-width: 1280px) and (orientation: landscape)"}},7747:(o,s,r)=>{"use strict";r.d(s,{w5:()=>C});var i=r(3107);let c=(()=>{class T{create(M){return typeof MutationObserver>"u"?null:new MutationObserver(M)}static \u0275fac=function(O){return new(O||T)};static \u0275prov=i.jDH({token:T,factory:T.\u0275fac,providedIn:"root"})}return T})(),C=(()=>{class T{static \u0275fac=function(O){return new(O||T)};static \u0275mod=i.$C({type:T});static \u0275inj=i.G2t({providers:[c]})}return T})()},9666:(o,s,r)=>{"use strict";r.d(s,{$Q:()=>en,Sf:()=>_t,Tv:()=>Ce,WB:()=>kn,hJ:()=>Kt,rR:()=>Be,yY:()=>ze,z_:()=>Rn});var i=r(8108),a=r(4460),c=r(3107),y=r(3022),w=r(2147),C=r(1483),T=r(5424),S=r(8445),M=r(2944),O=r(6192),L=r(8559),Z=r(5467),q=r(8447),re=r(5710),pe=r(7509),se=r(5919);const ae=(0,w.CZ)();class me{_viewportRuler;_previousHTMLStyles={top:"",left:""};_previousScrollPosition;_isEnabled=!1;_document;constructor(Fe,ke){this._viewportRuler=Fe,this._document=ke}attach(){}enable(){if(this._canBeEnabled()){const Fe=this._document.documentElement;this._previousScrollPosition=this._viewportRuler.getViewportScrollPosition(),this._previousHTMLStyles.left=Fe.style.left||"",this._previousHTMLStyles.top=Fe.style.top||"",Fe.style.left=(0,y.a1)(-this._previousScrollPosition.left),Fe.style.top=(0,y.a1)(-this._previousScrollPosition.top),Fe.classList.add("cdk-global-scrollblock"),this._isEnabled=!0}}disable(){if(this._isEnabled){const Fe=this._document.documentElement,Je=Fe.style,z=this._document.body.style,N=Je.scrollBehavior||"",W=z.scrollBehavior||"";this._isEnabled=!1,Je.left=this._previousHTMLStyles.left,Je.top=this._previousHTMLStyles.top,Fe.classList.remove("cdk-global-scrollblock"),ae&&(Je.scrollBehavior=z.scrollBehavior="auto"),window.scroll(this._previousScrollPosition.left,this._previousScrollPosition.top),ae&&(Je.scrollBehavior=N,z.scrollBehavior=W)}}_canBeEnabled(){if(this._document.documentElement.classList.contains("cdk-global-scrollblock")||this._isEnabled)return!1;const ke=this._document.body,Je=this._viewportRuler.getViewportSize();return ke.scrollHeight>Je.height||ke.scrollWidth>Je.width}}class Oe{_scrollDispatcher;_ngZone;_viewportRuler;_config;_scrollSubscription=null;_overlayRef;_initialScrollPosition;constructor(Fe,ke,Je,z){this._scrollDispatcher=Fe,this._ngZone=ke,this._viewportRuler=Je,this._config=z}attach(Fe){this._overlayRef=Fe}enable(){if(this._scrollSubscription)return;const Fe=this._scrollDispatcher.scrolled(0).pipe((0,C.p)(ke=>!ke||!this._overlayRef.overlayElement.contains(ke.getElementRef().nativeElement)));this._config&&this._config.threshold&&this._config.threshold>1?(this._initialScrollPosition=this._viewportRuler.getViewportScrollPosition().top,this._scrollSubscription=Fe.subscribe(()=>{const ke=this._viewportRuler.getViewportScrollPosition().top;Math.abs(ke-this._initialScrollPosition)>this._config.threshold?this._detach():this._overlayRef.updatePosition()})):this._scrollSubscription=Fe.subscribe(this._detach)}disable(){this._scrollSubscription&&(this._scrollSubscription.unsubscribe(),this._scrollSubscription=null)}detach(){this.disable(),this._overlayRef=null}_detach=()=>{this.disable(),this._overlayRef.hasAttached()&&this._ngZone.run(()=>this._overlayRef.detach())}}class xe{enable(){}disable(){}attach(){}}function De(cn,Fe){return Fe.some(ke=>cn.bottomke.bottom||cn.rightke.right)}function ce(cn,Fe){return Fe.some(ke=>cn.topke.bottom||cn.leftke.right)}class ue{_scrollDispatcher;_viewportRuler;_ngZone;_config;_scrollSubscription=null;_overlayRef;constructor(Fe,ke,Je,z){this._scrollDispatcher=Fe,this._viewportRuler=ke,this._ngZone=Je,this._config=z}attach(Fe){this._overlayRef=Fe}enable(){this._scrollSubscription||(this._scrollSubscription=this._scrollDispatcher.scrolled(this._config?this._config.scrollThrottle:0).subscribe(()=>{if(this._overlayRef.updatePosition(),this._config&&this._config.autoClose){const ke=this._overlayRef.overlayElement.getBoundingClientRect(),{width:Je,height:z}=this._viewportRuler.getViewportSize();De(ke,[{width:Je,height:z,bottom:z,right:Je,top:0,left:0}])&&(this.disable(),this._ngZone.run(()=>this._overlayRef.detach()))}}))}disable(){this._scrollSubscription&&(this._scrollSubscription.unsubscribe(),this._scrollSubscription=null)}detach(){this.disable(),this._overlayRef=null}}let Ce=(()=>{class cn{_scrollDispatcher=(0,c.WQX)(i.R);_viewportRuler=(0,c.WQX)(i.Xj);_ngZone=(0,c.WQX)(c.SKi);_document=(0,c.WQX)(a.qQ);constructor(){}noop=()=>new xe;close=ke=>new Oe(this._scrollDispatcher,this._ngZone,this._viewportRuler,ke);block=()=>new me(this._viewportRuler,this._document);reposition=ke=>new ue(this._scrollDispatcher,this._viewportRuler,this._ngZone,ke);static \u0275fac=function(Je){return new(Je||cn)};static \u0275prov=c.jDH({token:cn,factory:cn.\u0275fac,providedIn:"root"})}return cn})();class Be{positionStrategy;scrollStrategy=new xe;panelClass="";hasBackdrop=!1;backdropClass="cdk-overlay-dark-backdrop";width;height;minWidth;minHeight;maxWidth;maxHeight;direction;disposeOnNavigation=!1;constructor(Fe){if(Fe){const ke=Object.keys(Fe);for(const Je of ke)void 0!==Fe[Je]&&(this[Je]=Fe[Je])}}}class bt{connectionPair;scrollableViewProperties;constructor(Fe,ke){this.connectionPair=Fe,this.scrollableViewProperties=ke}}let gn=(()=>{class cn{_attachedOverlays=[];_document=(0,c.WQX)(a.qQ);_isAttached;constructor(){}ngOnDestroy(){this.detach()}add(ke){this.remove(ke),this._attachedOverlays.push(ke)}remove(ke){const Je=this._attachedOverlays.indexOf(ke);Je>-1&&this._attachedOverlays.splice(Je,1),0===this._attachedOverlays.length&&this.detach()}static \u0275fac=function(Je){return new(Je||cn)};static \u0275prov=c.jDH({token:cn,factory:cn.\u0275fac,providedIn:"root"})}return cn})(),bn=(()=>{class cn extends gn{_ngZone=(0,c.WQX)(c.SKi,{optional:!0});add(ke){super.add(ke),this._isAttached||(this._ngZone?this._ngZone.runOutsideAngular(()=>this._document.body.addEventListener("keydown",this._keydownListener)):this._document.body.addEventListener("keydown",this._keydownListener),this._isAttached=!0)}detach(){this._isAttached&&(this._document.body.removeEventListener("keydown",this._keydownListener),this._isAttached=!1)}_keydownListener=ke=>{const Je=this._attachedOverlays;for(let z=Je.length-1;z>-1;z--)if(Je[z]._keydownEvents.observers.length>0){const N=Je[z]._keydownEvents;this._ngZone?this._ngZone.run(()=>N.next(ke)):N.next(ke);break}};static \u0275fac=(()=>{let ke;return function(z){return(ke||(ke=c.xGo(cn)))(z||cn)}})();static \u0275prov=c.jDH({token:cn,factory:cn.\u0275fac,providedIn:"root"})}return cn})(),Vn=(()=>{class cn extends gn{_platform=(0,c.WQX)(w.OD);_ngZone=(0,c.WQX)(c.SKi,{optional:!0});_cursorOriginalValue;_cursorStyleIsSet=!1;_pointerDownEventTarget;add(ke){if(super.add(ke),!this._isAttached){const Je=this._document.body;this._ngZone?this._ngZone.runOutsideAngular(()=>this._addEventListeners(Je)):this._addEventListeners(Je),this._platform.IOS&&!this._cursorStyleIsSet&&(this._cursorOriginalValue=Je.style.cursor,Je.style.cursor="pointer",this._cursorStyleIsSet=!0),this._isAttached=!0}}detach(){if(this._isAttached){const ke=this._document.body;ke.removeEventListener("pointerdown",this._pointerDownListener,!0),ke.removeEventListener("click",this._clickListener,!0),ke.removeEventListener("auxclick",this._clickListener,!0),ke.removeEventListener("contextmenu",this._clickListener,!0),this._platform.IOS&&this._cursorStyleIsSet&&(ke.style.cursor=this._cursorOriginalValue,this._cursorStyleIsSet=!1),this._isAttached=!1}}_addEventListeners(ke){ke.addEventListener("pointerdown",this._pointerDownListener,!0),ke.addEventListener("click",this._clickListener,!0),ke.addEventListener("auxclick",this._clickListener,!0),ke.addEventListener("contextmenu",this._clickListener,!0)}_pointerDownListener=ke=>{this._pointerDownEventTarget=(0,w.Fb)(ke)};_clickListener=ke=>{const Je=(0,w.Fb)(ke),z="click"===ke.type&&this._pointerDownEventTarget?this._pointerDownEventTarget:Je;this._pointerDownEventTarget=null;const N=this._attachedOverlays.slice();for(let W=N.length-1;W>-1;W--){const Le=N[W];if(Le._outsidePointerEvents.observers.length<1||!Le.hasAttached())continue;if(yn(Le.overlayElement,Je)||yn(Le.overlayElement,z))break;const ft=Le._outsidePointerEvents;this._ngZone?this._ngZone.run(()=>ft.next(ke)):ft.next(ke)}};static \u0275fac=(()=>{let ke;return function(z){return(ke||(ke=c.xGo(cn)))(z||cn)}})();static \u0275prov=c.jDH({token:cn,factory:cn.\u0275fac,providedIn:"root"})}return cn})();function yn(cn,Fe){const ke=typeof ShadowRoot<"u"&&ShadowRoot;let Je=Fe;for(;Je;){if(Je===cn)return!0;Je=ke&&Je instanceof ShadowRoot?Je.host:Je.parentNode}return!1}let qe=(()=>{class cn{static \u0275fac=function(Je){return new(Je||cn)};static \u0275cmp=c.VBU({type:cn,selectors:[["ng-component"]],hostAttrs:["cdk-overlay-style-loader",""],decls:0,vars:0,template:function(Je,z){},styles:[".cdk-overlay-container,.cdk-global-overlay-wrapper{pointer-events:none;top:0;left:0;height:100%;width:100%}.cdk-overlay-container{position:fixed}@layer cdk-overlay{.cdk-overlay-container{z-index:1000}}.cdk-overlay-container:empty{display:none}.cdk-global-overlay-wrapper{display:flex;position:absolute}@layer cdk-overlay{.cdk-global-overlay-wrapper{z-index:1000}}.cdk-overlay-pane{position:absolute;pointer-events:auto;box-sizing:border-box;display:flex;max-width:100%;max-height:100%}@layer cdk-overlay{.cdk-overlay-pane{z-index:1000}}.cdk-overlay-backdrop{position:absolute;top:0;bottom:0;left:0;right:0;pointer-events:auto;-webkit-tap-highlight-color:rgba(0,0,0,0);opacity:0}@layer cdk-overlay{.cdk-overlay-backdrop{z-index:1000;transition:opacity 400ms cubic-bezier(0.25, 0.8, 0.25, 1)}}.cdk-overlay-backdrop-showing{opacity:1}@media(forced-colors: active){.cdk-overlay-backdrop-showing{opacity:.6}}@layer cdk-overlay{.cdk-overlay-dark-backdrop{background:rgba(0,0,0,.32)}}.cdk-overlay-transparent-backdrop{transition:visibility 1ms linear,opacity 1ms linear;visibility:hidden;opacity:1}.cdk-overlay-transparent-backdrop.cdk-overlay-backdrop-showing,.cdk-high-contrast-active .cdk-overlay-transparent-backdrop{opacity:0;visibility:visible}.cdk-overlay-backdrop-noop-animation{transition:none}.cdk-overlay-connected-position-bounding-box{position:absolute;display:flex;flex-direction:column;min-width:1px;min-height:1px}@layer cdk-overlay{.cdk-overlay-connected-position-bounding-box{z-index:1000}}.cdk-global-scrollblock{position:fixed;width:100%;overflow-y:scroll}"],encapsulation:2,changeDetection:0})}return cn})(),_t=(()=>{class cn{_platform=(0,c.WQX)(w.OD);_containerElement;_document=(0,c.WQX)(a.qQ);_styleLoader=(0,c.WQX)(Z.l);constructor(){}ngOnDestroy(){this._containerElement?.remove()}getContainerElement(){return this._loadStyles(),this._containerElement||this._createContainer(),this._containerElement}_createContainer(){const ke="cdk-overlay-container";if(this._platform.isBrowser||(0,w.v8)()){const z=this._document.querySelectorAll(`.${ke}[platform="server"], .${ke}[platform="test"]`);for(let N=0;Nthis._backdropClick.next(Fe);_backdropTransitionendHandler=Fe=>{this._disposeBackdrop(Fe.target)};_previousHostParent;_keydownEvents=new q.B;_outsidePointerEvents=new q.B;_renders=new q.B;_afterRenderRef;_afterNextRenderRef;constructor(Fe,ke,Je,z,N,W,Le,ft,mt,St=!1,Tn){this._portalOutlet=Fe,this._host=ke,this._pane=Je,this._config=z,this._ngZone=N,this._keyboardDispatcher=W,this._document=Le,this._location=ft,this._outsideClickDispatcher=mt,this._animationsDisabled=St,this._injector=Tn,z.scrollStrategy&&(this._scrollStrategy=z.scrollStrategy,this._scrollStrategy.attach(this)),this._positionStrategy=z.positionStrategy,this._afterRenderRef=(0,c.O8t)(()=>(0,c.Tzd)(()=>{this._renders.next()},{injector:this._injector}))}get overlayElement(){return this._pane}get backdropElement(){return this._backdropElement}get hostElement(){return this._host}attach(Fe){!this._host.parentElement&&this._previousHostParent&&this._previousHostParent.appendChild(this._host);const ke=this._portalOutlet.attach(Fe);return this._positionStrategy&&this._positionStrategy.attach(this),this._updateStackingOrder(),this._updateElementSize(),this._updateElementDirection(),this._scrollStrategy&&this._scrollStrategy.enable(),this._afterNextRenderRef?.destroy(),this._afterNextRenderRef=(0,c.mal)(()=>{this.hasAttached()&&this.updatePosition()},{injector:this._injector}),this._togglePointerEvents(!0),this._config.hasBackdrop&&this._attachBackdrop(),this._config.panelClass&&this._toggleClasses(this._pane,this._config.panelClass,!0),this._attachments.next(),this._keyboardDispatcher.add(this),this._config.disposeOnNavigation&&(this._locationChanges=this._location.subscribe(()=>this.dispose())),this._outsideClickDispatcher.add(this),"function"==typeof ke?.onDestroy&&ke.onDestroy(()=>{this.hasAttached()&&this._ngZone.runOutsideAngular(()=>Promise.resolve().then(()=>this.detach()))}),ke}detach(){if(!this.hasAttached())return;this.detachBackdrop(),this._togglePointerEvents(!1),this._positionStrategy&&this._positionStrategy.detach&&this._positionStrategy.detach(),this._scrollStrategy&&this._scrollStrategy.disable();const Fe=this._portalOutlet.detach();return this._detachments.next(),this._keyboardDispatcher.remove(this),this._detachContentWhenEmpty(),this._locationChanges.unsubscribe(),this._outsideClickDispatcher.remove(this),Fe}dispose(){const Fe=this.hasAttached();this._positionStrategy&&this._positionStrategy.dispose(),this._disposeScrollStrategy(),this._disposeBackdrop(this._backdropElement),this._locationChanges.unsubscribe(),this._keyboardDispatcher.remove(this),this._portalOutlet.dispose(),this._attachments.complete(),this._backdropClick.complete(),this._keydownEvents.complete(),this._outsidePointerEvents.complete(),this._outsideClickDispatcher.remove(this),this._host?.remove(),this._afterNextRenderRef?.destroy(),this._previousHostParent=this._pane=this._host=null,Fe&&this._detachments.next(),this._detachments.complete(),this._afterRenderRef.destroy(),this._renders.complete()}hasAttached(){return this._portalOutlet.hasAttached()}backdropClick(){return this._backdropClick}attachments(){return this._attachments}detachments(){return this._detachments}keydownEvents(){return this._keydownEvents}outsidePointerEvents(){return this._outsidePointerEvents}getConfig(){return this._config}updatePosition(){this._positionStrategy&&this._positionStrategy.apply()}updatePositionStrategy(Fe){Fe!==this._positionStrategy&&(this._positionStrategy&&this._positionStrategy.dispose(),this._positionStrategy=Fe,this.hasAttached()&&(Fe.attach(this),this.updatePosition()))}updateSize(Fe){this._config={...this._config,...Fe},this._updateElementSize()}setDirection(Fe){this._config={...this._config,direction:Fe},this._updateElementDirection()}addPanelClass(Fe){this._pane&&this._toggleClasses(this._pane,Fe,!0)}removePanelClass(Fe){this._pane&&this._toggleClasses(this._pane,Fe,!1)}getDirection(){const Fe=this._config.direction;return Fe?"string"==typeof Fe?Fe:Fe.value:"ltr"}updateScrollStrategy(Fe){Fe!==this._scrollStrategy&&(this._disposeScrollStrategy(),this._scrollStrategy=Fe,this.hasAttached()&&(Fe.attach(this),Fe.enable()))}_updateElementDirection(){this._host.setAttribute("dir",this.getDirection())}_updateElementSize(){if(!this._pane)return;const Fe=this._pane.style;Fe.width=(0,y.a1)(this._config.width),Fe.height=(0,y.a1)(this._config.height),Fe.minWidth=(0,y.a1)(this._config.minWidth),Fe.minHeight=(0,y.a1)(this._config.minHeight),Fe.maxWidth=(0,y.a1)(this._config.maxWidth),Fe.maxHeight=(0,y.a1)(this._config.maxHeight)}_togglePointerEvents(Fe){this._pane.style.pointerEvents=Fe?"":"none"}_attachBackdrop(){const Fe="cdk-overlay-backdrop-showing";this._backdropElement=this._document.createElement("div"),this._backdropElement.classList.add("cdk-overlay-backdrop"),this._animationsDisabled&&this._backdropElement.classList.add("cdk-overlay-backdrop-noop-animation"),this._config.backdropClass&&this._toggleClasses(this._backdropElement,this._config.backdropClass,!0),this._host.parentElement.insertBefore(this._backdropElement,this._host),this._backdropElement.addEventListener("click",this._backdropClickHandler),!this._animationsDisabled&&typeof requestAnimationFrame<"u"?this._ngZone.runOutsideAngular(()=>{requestAnimationFrame(()=>{this._backdropElement&&this._backdropElement.classList.add(Fe)})}):this._backdropElement.classList.add(Fe)}_updateStackingOrder(){this._host.nextSibling&&this._host.parentNode.appendChild(this._host)}detachBackdrop(){const Fe=this._backdropElement;if(Fe){if(this._animationsDisabled)return void this._disposeBackdrop(Fe);Fe.classList.remove("cdk-overlay-backdrop-showing"),this._ngZone.runOutsideAngular(()=>{Fe.addEventListener("transitionend",this._backdropTransitionendHandler)}),Fe.style.pointerEvents="none",this._backdropTimeout=this._ngZone.runOutsideAngular(()=>setTimeout(()=>{this._disposeBackdrop(Fe)},500))}}_toggleClasses(Fe,ke,Je){const z=(0,y.FG)(ke||[]).filter(N=>!!N);z.length&&(Je?Fe.classList.add(...z):Fe.classList.remove(...z))}_detachContentWhenEmpty(){this._ngZone.runOutsideAngular(()=>{const Fe=this._renders.pipe((0,T.Q)((0,pe.h)(this._attachments,this._detachments))).subscribe(()=>{(!this._pane||!this._host||0===this._pane.children.length)&&(this._pane&&this._config.panelClass&&this._toggleClasses(this._pane,this._config.panelClass,!1),this._host&&this._host.parentElement&&(this._previousHostParent=this._host.parentElement,this._host.remove()),Fe.unsubscribe())})})}_disposeScrollStrategy(){const Fe=this._scrollStrategy;Fe&&(Fe.disable(),Fe.detach&&Fe.detach())}_disposeBackdrop(Fe){Fe&&(Fe.removeEventListener("click",this._backdropClickHandler),Fe.removeEventListener("transitionend",this._backdropTransitionendHandler),Fe.remove(),this._backdropElement===Fe&&(this._backdropElement=null)),this._backdropTimeout&&(clearTimeout(this._backdropTimeout),this._backdropTimeout=void 0)}}const $e="cdk-overlay-connected-position-bounding-box",Ft=/([A-Za-z%]+)$/;class Ke{_viewportRuler;_document;_platform;_overlayContainer;_overlayRef;_isInitialRender;_lastBoundingBoxSize={width:0,height:0};_isPushed=!1;_canPush=!0;_growAfterOpen=!1;_hasFlexibleDimensions=!0;_positionLocked=!1;_originRect;_overlayRect;_viewportRect;_containerRect;_viewportMargin=0;_scrollables=[];_preferredPositions=[];_origin;_pane;_isDisposed;_boundingBox;_lastPosition;_lastScrollVisibility;_positionChanges=new q.B;_resizeSubscription=re.yU.EMPTY;_offsetX=0;_offsetY=0;_transformOriginSelector;_appliedPanelClasses=[];_previousPushAmount;positionChanges=this._positionChanges;get positions(){return this._preferredPositions}constructor(Fe,ke,Je,z,N){this._viewportRuler=ke,this._document=Je,this._platform=z,this._overlayContainer=N,this.setOrigin(Fe)}attach(Fe){this._validatePositions(),Fe.hostElement.classList.add($e),this._overlayRef=Fe,this._boundingBox=Fe.hostElement,this._pane=Fe.overlayElement,this._isDisposed=!1,this._isInitialRender=!0,this._lastPosition=null,this._resizeSubscription.unsubscribe(),this._resizeSubscription=this._viewportRuler.change().subscribe(()=>{this._isInitialRender=!0,this.apply()})}apply(){if(this._isDisposed||!this._platform.isBrowser)return;if(!this._isInitialRender&&this._positionLocked&&this._lastPosition)return void this.reapplyLastPosition();this._clearPanelClasses(),this._resetOverlayElementStyles(),this._resetBoundingBoxStyles(),this._viewportRect=this._getNarrowedViewportRect(),this._originRect=this._getOriginRect(),this._overlayRect=this._pane.getBoundingClientRect(),this._containerRect=this._overlayContainer.getContainerElement().getBoundingClientRect();const Fe=this._originRect,ke=this._overlayRect,Je=this._viewportRect,z=this._containerRect,N=[];let W;for(let Le of this._preferredPositions){let ft=this._getOriginPoint(Fe,z,Le),mt=this._getOverlayPoint(ft,ke,Le),St=this._getOverlayFit(mt,ke,Je,Le);if(St.isCompletelyWithinViewport)return this._isPushed=!1,void this._applyPosition(Le,ft);this._canFitWithFlexibleDimensions(St,mt,Je)?N.push({position:Le,origin:ft,overlayRect:ke,boundingBoxRect:this._calculateBoundingBoxRect(ft,Le)}):(!W||W.overlayFit.visibleAreaft&&(ft=St,Le=mt)}return this._isPushed=!1,void this._applyPosition(Le.position,Le.origin)}if(this._canPush)return this._isPushed=!0,void this._applyPosition(W.position,W.originPoint);this._applyPosition(W.position,W.originPoint)}detach(){this._clearPanelClasses(),this._lastPosition=null,this._previousPushAmount=null,this._resizeSubscription.unsubscribe()}dispose(){this._isDisposed||(this._boundingBox&&Ze(this._boundingBox.style,{top:"",left:"",right:"",bottom:"",height:"",width:"",alignItems:"",justifyContent:""}),this._pane&&this._resetOverlayElementStyles(),this._overlayRef&&this._overlayRef.hostElement.classList.remove($e),this.detach(),this._positionChanges.complete(),this._overlayRef=this._boundingBox=null,this._isDisposed=!0)}reapplyLastPosition(){if(this._isDisposed||!this._platform.isBrowser)return;const Fe=this._lastPosition;if(Fe){this._originRect=this._getOriginRect(),this._overlayRect=this._pane.getBoundingClientRect(),this._viewportRect=this._getNarrowedViewportRect(),this._containerRect=this._overlayContainer.getContainerElement().getBoundingClientRect();const ke=this._getOriginPoint(this._originRect,this._containerRect,Fe);this._applyPosition(Fe,ke)}else this.apply()}withScrollableContainers(Fe){return this._scrollables=Fe,this}withPositions(Fe){return this._preferredPositions=Fe,-1===Fe.indexOf(this._lastPosition)&&(this._lastPosition=null),this._validatePositions(),this}withViewportMargin(Fe){return this._viewportMargin=Fe,this}withFlexibleDimensions(Fe=!0){return this._hasFlexibleDimensions=Fe,this}withGrowAfterOpen(Fe=!0){return this._growAfterOpen=Fe,this}withPush(Fe=!0){return this._canPush=Fe,this}withLockedPosition(Fe=!0){return this._positionLocked=Fe,this}setOrigin(Fe){return this._origin=Fe,this}withDefaultOffsetX(Fe){return this._offsetX=Fe,this}withDefaultOffsetY(Fe){return this._offsetY=Fe,this}withTransformOriginOn(Fe){return this._transformOriginSelector=Fe,this}_getOriginPoint(Fe,ke,Je){let z,N;if("center"==Je.originX)z=Fe.left+Fe.width/2;else{const W=this._isRtl()?Fe.right:Fe.left,Le=this._isRtl()?Fe.left:Fe.right;z="start"==Je.originX?W:Le}return ke.left<0&&(z-=ke.left),N="center"==Je.originY?Fe.top+Fe.height/2:"top"==Je.originY?Fe.top:Fe.bottom,ke.top<0&&(N-=ke.top),{x:z,y:N}}_getOverlayPoint(Fe,ke,Je){let z,N;return z="center"==Je.overlayX?-ke.width/2:"start"===Je.overlayX?this._isRtl()?-ke.width:0:this._isRtl()?0:-ke.width,N="center"==Je.overlayY?-ke.height/2:"top"==Je.overlayY?0:-ke.height,{x:Fe.x+z,y:Fe.y+N}}_getOverlayFit(Fe,ke,Je,z){const N=Ot(ke);let{x:W,y:Le}=Fe,ft=this._getOffset(z,"x"),mt=this._getOffset(z,"y");ft&&(W+=ft),mt&&(Le+=mt);let an=0-Le,dn=Le+N.height-Je.height,In=this._subtractOverflows(N.width,0-W,W+N.width-Je.width),sr=this._subtractOverflows(N.height,an,dn),xn=In*sr;return{visibleArea:xn,isCompletelyWithinViewport:N.width*N.height===xn,fitsInViewportVertically:sr===N.height,fitsInViewportHorizontally:In==N.width}}_canFitWithFlexibleDimensions(Fe,ke,Je){if(this._hasFlexibleDimensions){const z=Je.bottom-ke.y,N=Je.right-ke.x,W=it(this._overlayRef.getConfig().minHeight),Le=it(this._overlayRef.getConfig().minWidth);return(Fe.fitsInViewportVertically||null!=W&&W<=z)&&(Fe.fitsInViewportHorizontally||null!=Le&&Le<=N)}return!1}_pushOverlayOnScreen(Fe,ke,Je){if(this._previousPushAmount&&this._positionLocked)return{x:Fe.x+this._previousPushAmount.x,y:Fe.y+this._previousPushAmount.y};const z=Ot(ke),N=this._viewportRect,W=Math.max(Fe.x+z.width-N.width,0),Le=Math.max(Fe.y+z.height-N.height,0),ft=Math.max(N.top-Je.top-Fe.y,0),mt=Math.max(N.left-Je.left-Fe.x,0);let St=0,Tn=0;return St=z.width<=N.width?mt||-W:Fe.xIn&&!this._isInitialRender&&!this._growAfterOpen&&(W=Fe.y-In/2)}if("end"===ke.overlayX&&!z||"start"===ke.overlayX&&z)an=Je.width-Fe.x+2*this._viewportMargin,St=Fe.x-this._viewportMargin;else if("start"===ke.overlayX&&!z||"end"===ke.overlayX&&z)Tn=Fe.x,St=Je.right-Fe.x;else{const dn=Math.min(Je.right-Fe.x+Je.left,Fe.x),In=this._lastBoundingBoxSize.width;St=2*dn,Tn=Fe.x-dn,St>In&&!this._isInitialRender&&!this._growAfterOpen&&(Tn=Fe.x-In/2)}return{top:W,left:Tn,bottom:Le,right:an,width:St,height:N}}_setBoundingBoxStyles(Fe,ke){const Je=this._calculateBoundingBoxRect(Fe,ke);!this._isInitialRender&&!this._growAfterOpen&&(Je.height=Math.min(Je.height,this._lastBoundingBoxSize.height),Je.width=Math.min(Je.width,this._lastBoundingBoxSize.width));const z={};if(this._hasExactPosition())z.top=z.left="0",z.bottom=z.right=z.maxHeight=z.maxWidth="",z.width=z.height="100%";else{const N=this._overlayRef.getConfig().maxHeight,W=this._overlayRef.getConfig().maxWidth;z.height=(0,y.a1)(Je.height),z.top=(0,y.a1)(Je.top),z.bottom=(0,y.a1)(Je.bottom),z.width=(0,y.a1)(Je.width),z.left=(0,y.a1)(Je.left),z.right=(0,y.a1)(Je.right),z.alignItems="center"===ke.overlayX?"center":"end"===ke.overlayX?"flex-end":"flex-start",z.justifyContent="center"===ke.overlayY?"center":"bottom"===ke.overlayY?"flex-end":"flex-start",N&&(z.maxHeight=(0,y.a1)(N)),W&&(z.maxWidth=(0,y.a1)(W))}this._lastBoundingBoxSize=Je,Ze(this._boundingBox.style,z)}_resetBoundingBoxStyles(){Ze(this._boundingBox.style,{top:"0",left:"0",right:"0",bottom:"0",height:"",width:"",alignItems:"",justifyContent:""})}_resetOverlayElementStyles(){Ze(this._pane.style,{top:"",left:"",bottom:"",right:"",position:"",transform:""})}_setOverlayElementStyles(Fe,ke){const Je={},z=this._hasExactPosition(),N=this._hasFlexibleDimensions,W=this._overlayRef.getConfig();if(z){const St=this._viewportRuler.getViewportScrollPosition();Ze(Je,this._getExactOverlayY(ke,Fe,St)),Ze(Je,this._getExactOverlayX(ke,Fe,St))}else Je.position="static";let Le="",ft=this._getOffset(ke,"x"),mt=this._getOffset(ke,"y");ft&&(Le+=`translateX(${ft}px) `),mt&&(Le+=`translateY(${mt}px)`),Je.transform=Le.trim(),W.maxHeight&&(z?Je.maxHeight=(0,y.a1)(W.maxHeight):N&&(Je.maxHeight="")),W.maxWidth&&(z?Je.maxWidth=(0,y.a1)(W.maxWidth):N&&(Je.maxWidth="")),Ze(this._pane.style,Je)}_getExactOverlayY(Fe,ke,Je){let z={top:"",bottom:""},N=this._getOverlayPoint(ke,this._overlayRect,Fe);return this._isPushed&&(N=this._pushOverlayOnScreen(N,this._overlayRect,Je)),"bottom"===Fe.overlayY?z.bottom=this._document.documentElement.clientHeight-(N.y+this._overlayRect.height)+"px":z.top=(0,y.a1)(N.y),z}_getExactOverlayX(Fe,ke,Je){let W,z={left:"",right:""},N=this._getOverlayPoint(ke,this._overlayRect,Fe);return this._isPushed&&(N=this._pushOverlayOnScreen(N,this._overlayRect,Je)),W=this._isRtl()?"end"===Fe.overlayX?"left":"right":"end"===Fe.overlayX?"right":"left","right"===W?z.right=this._document.documentElement.clientWidth-(N.x+this._overlayRect.width)+"px":z.left=(0,y.a1)(N.x),z}_getScrollVisibility(){const Fe=this._getOriginRect(),ke=this._pane.getBoundingClientRect(),Je=this._scrollables.map(z=>z.getElementRef().nativeElement.getBoundingClientRect());return{isOriginClipped:ce(Fe,Je),isOriginOutsideView:De(Fe,Je),isOverlayClipped:ce(ke,Je),isOverlayOutsideView:De(ke,Je)}}_subtractOverflows(Fe,...ke){return ke.reduce((Je,z)=>Je-Math.max(z,0),Fe)}_getNarrowedViewportRect(){const Fe=this._document.documentElement.clientWidth,ke=this._document.documentElement.clientHeight,Je=this._viewportRuler.getViewportScrollPosition();return{top:Je.top+this._viewportMargin,left:Je.left+this._viewportMargin,right:Je.left+Fe-this._viewportMargin,bottom:Je.top+ke-this._viewportMargin,width:Fe-2*this._viewportMargin,height:ke-2*this._viewportMargin}}_isRtl(){return"rtl"===this._overlayRef.getDirection()}_hasExactPosition(){return!this._hasFlexibleDimensions||this._isPushed}_getOffset(Fe,ke){return"x"===ke?null==Fe.offsetX?this._offsetX:Fe.offsetX:null==Fe.offsetY?this._offsetY:Fe.offsetY}_validatePositions(){}_addPanelClasses(Fe){this._pane&&(0,y.FG)(Fe).forEach(ke=>{""!==ke&&-1===this._appliedPanelClasses.indexOf(ke)&&(this._appliedPanelClasses.push(ke),this._pane.classList.add(ke))})}_clearPanelClasses(){this._pane&&(this._appliedPanelClasses.forEach(Fe=>{this._pane.classList.remove(Fe)}),this._appliedPanelClasses=[])}_getOriginRect(){const Fe=this._origin;if(Fe instanceof c.aKT)return Fe.nativeElement.getBoundingClientRect();if(Fe instanceof Element)return Fe.getBoundingClientRect();const ke=Fe.width||0,Je=Fe.height||0;return{top:Fe.y,bottom:Fe.y+Je,left:Fe.x,right:Fe.x+ke,height:Je,width:ke}}}function Ze(cn,Fe){for(let ke in Fe)Fe.hasOwnProperty(ke)&&(cn[ke]=Fe[ke]);return cn}function it(cn){if("number"!=typeof cn&&null!=cn){const[Fe,ke]=cn.split(Ft);return ke&&"px"!==ke?null:parseFloat(Fe)}return cn||null}function Ot(cn){return{top:Math.floor(cn.top),right:Math.floor(cn.right),bottom:Math.floor(cn.bottom),left:Math.floor(cn.left),width:Math.floor(cn.width),height:Math.floor(cn.height)}}const st="cdk-global-overlay-wrapper";class Xt{_overlayRef;_cssPosition="static";_topOffset="";_bottomOffset="";_alignItems="";_xPosition="";_xOffset="";_width="";_height="";_isDisposed=!1;attach(Fe){const ke=Fe.getConfig();this._overlayRef=Fe,this._width&&!ke.width&&Fe.updateSize({width:this._width}),this._height&&!ke.height&&Fe.updateSize({height:this._height}),Fe.hostElement.classList.add(st),this._isDisposed=!1}top(Fe=""){return this._bottomOffset="",this._topOffset=Fe,this._alignItems="flex-start",this}left(Fe=""){return this._xOffset=Fe,this._xPosition="left",this}bottom(Fe=""){return this._topOffset="",this._bottomOffset=Fe,this._alignItems="flex-end",this}right(Fe=""){return this._xOffset=Fe,this._xPosition="right",this}start(Fe=""){return this._xOffset=Fe,this._xPosition="start",this}end(Fe=""){return this._xOffset=Fe,this._xPosition="end",this}width(Fe=""){return this._overlayRef?this._overlayRef.updateSize({width:Fe}):this._width=Fe,this}height(Fe=""){return this._overlayRef?this._overlayRef.updateSize({height:Fe}):this._height=Fe,this}centerHorizontally(Fe=""){return this.left(Fe),this._xPosition="center",this}centerVertically(Fe=""){return this.top(Fe),this._alignItems="center",this}apply(){if(!this._overlayRef||!this._overlayRef.hasAttached())return;const Fe=this._overlayRef.overlayElement.style,ke=this._overlayRef.hostElement.style,Je=this._overlayRef.getConfig(),{width:z,height:N,maxWidth:W,maxHeight:Le}=Je,ft=!("100%"!==z&&"100vw"!==z||W&&"100%"!==W&&"100vw"!==W),mt=!("100%"!==N&&"100vh"!==N||Le&&"100%"!==Le&&"100vh"!==Le),St=this._xPosition,Tn=this._xOffset,an="rtl"===this._overlayRef.getConfig().direction;let dn="",In="",sr="";ft?sr="flex-start":"center"===St?(sr="center",an?In=Tn:dn=Tn):an?"left"===St||"end"===St?(sr="flex-end",dn=Tn):("right"===St||"start"===St)&&(sr="flex-start",In=Tn):"left"===St||"start"===St?(sr="flex-start",dn=Tn):("right"===St||"end"===St)&&(sr="flex-end",In=Tn),Fe.position=this._cssPosition,Fe.marginLeft=ft?"0":dn,Fe.marginTop=mt?"0":this._topOffset,Fe.marginBottom=this._bottomOffset,Fe.marginRight=ft?"0":In,ke.justifyContent=sr,ke.alignItems=mt?"flex-start":this._alignItems}dispose(){if(this._isDisposed||!this._overlayRef)return;const Fe=this._overlayRef.overlayElement.style,ke=this._overlayRef.hostElement,Je=ke.style;ke.classList.remove(st),Je.justifyContent=Je.alignItems=Fe.marginTop=Fe.marginBottom=Fe.marginLeft=Fe.marginRight=Fe.position="",this._overlayRef=null,this._isDisposed=!0}}let Mt=(()=>{class cn{_viewportRuler=(0,c.WQX)(i.Xj);_document=(0,c.WQX)(a.qQ);_platform=(0,c.WQX)(w.OD);_overlayContainer=(0,c.WQX)(_t);constructor(){}global(){return new Xt}flexibleConnectedTo(ke){return new Ke(ke,this._viewportRuler,this._document,this._platform,this._overlayContainer)}static \u0275fac=function(Je){return new(Je||cn)};static \u0275prov=c.jDH({token:cn,factory:cn.\u0275fac,providedIn:"root"})}return cn})(),Kt=(()=>{class cn{scrollStrategies=(0,c.WQX)(Ce);_overlayContainer=(0,c.WQX)(_t);_positionBuilder=(0,c.WQX)(Mt);_keyboardDispatcher=(0,c.WQX)(bn);_injector=(0,c.WQX)(c.zZn);_ngZone=(0,c.WQX)(c.SKi);_document=(0,c.WQX)(a.qQ);_directionality=(0,c.WQX)(M.dS);_location=(0,c.WQX)(a.aZ);_outsideClickDispatcher=(0,c.WQX)(Vn);_animationsModuleType=(0,c.WQX)(c.bc$,{optional:!0});_idGenerator=(0,c.WQX)(L.g7);_appRef;_styleLoader=(0,c.WQX)(Z.l);constructor(){}create(ke){this._styleLoader.load(qe);const Je=this._createHostElement(),z=this._createPaneElement(Je),N=this._createPortalOutlet(z),W=new Be(ke);return W.direction=W.direction||this._directionality.value,new ze(N,Je,z,W,this._ngZone,this._keyboardDispatcher,this._document,this._location,this._outsideClickDispatcher,"NoopAnimations"===this._animationsModuleType,this._injector.get(c.uvJ))}position(){return this._positionBuilder}_createPaneElement(ke){const Je=this._document.createElement("div");return Je.id=this._idGenerator.getId("cdk-overlay-"),Je.classList.add("cdk-overlay-pane"),ke.appendChild(Je),Je}_createHostElement(){const ke=this._document.createElement("div");return this._overlayContainer.getContainerElement().appendChild(ke),ke}_createPortalOutlet(ke){return this._appRef||(this._appRef=this._injector.get(c.o8S)),new O.aI(ke,null,this._appRef,this._injector,this._document)}static \u0275fac=function(Je){return new(Je||cn)};static \u0275prov=c.jDH({token:cn,factory:cn.\u0275fac,providedIn:"root"})}return cn})();const rt=[{originX:"start",originY:"bottom",overlayX:"start",overlayY:"top"},{originX:"start",originY:"top",overlayX:"start",overlayY:"bottom"},{originX:"end",originY:"top",overlayX:"end",overlayY:"bottom"},{originX:"end",originY:"bottom",overlayX:"end",overlayY:"top"}],Vt=new c.nKC("cdk-connected-overlay-scroll-strategy",{providedIn:"root",factory:()=>{const cn=(0,c.WQX)(Kt);return()=>cn.scrollStrategies.reposition()}});let en=(()=>{class cn{elementRef=(0,c.WQX)(c.aKT);constructor(){}static \u0275fac=function(Je){return new(Je||cn)};static \u0275dir=c.FsC({type:cn,selectors:[["","cdk-overlay-origin",""],["","overlay-origin",""],["","cdkOverlayOrigin",""]],exportAs:["cdkOverlayOrigin"]})}return cn})(),kn=(()=>{class cn{_overlay=(0,c.WQX)(Kt);_dir=(0,c.WQX)(M.dS,{optional:!0});_overlayRef;_templatePortal;_backdropSubscription=re.yU.EMPTY;_attachSubscription=re.yU.EMPTY;_detachSubscription=re.yU.EMPTY;_positionSubscription=re.yU.EMPTY;_offsetX;_offsetY;_position;_scrollStrategyFactory=(0,c.WQX)(Vt);_disposeOnNavigation=!1;_ngZone=(0,c.WQX)(c.SKi);origin;positions;positionStrategy;get offsetX(){return this._offsetX}set offsetX(ke){this._offsetX=ke,this._position&&this._updatePositionStrategy(this._position)}get offsetY(){return this._offsetY}set offsetY(ke){this._offsetY=ke,this._position&&this._updatePositionStrategy(this._position)}width;height;minWidth;minHeight;backdropClass;panelClass;viewportMargin=0;scrollStrategy;open=!1;disableClose=!1;transformOriginSelector;hasBackdrop=!1;lockPosition=!1;flexibleDimensions=!1;growAfterOpen=!1;push=!1;get disposeOnNavigation(){return this._disposeOnNavigation}set disposeOnNavigation(ke){this._disposeOnNavigation=ke}backdropClick=new c.bkB;positionChange=new c.bkB;attach=new c.bkB;detach=new c.bkB;overlayKeydown=new c.bkB;overlayOutsideClick=new c.bkB;constructor(){const ke=(0,c.WQX)(c.C4Q),Je=(0,c.WQX)(c.c1b);this._templatePortal=new O.VA(ke,Je),this.scrollStrategy=this._scrollStrategyFactory()}get overlayRef(){return this._overlayRef}get dir(){return this._dir?this._dir.value:"ltr"}ngOnDestroy(){this._attachSubscription.unsubscribe(),this._detachSubscription.unsubscribe(),this._backdropSubscription.unsubscribe(),this._positionSubscription.unsubscribe(),this._overlayRef&&this._overlayRef.dispose()}ngOnChanges(ke){this._position&&(this._updatePositionStrategy(this._position),this._overlayRef.updateSize({width:this.width,minWidth:this.minWidth,height:this.height,minHeight:this.minHeight}),ke.origin&&this.open&&this._position.apply()),ke.open&&(this.open?this._attachOverlay():this._detachOverlay())}_createOverlay(){(!this.positions||!this.positions.length)&&(this.positions=rt);const ke=this._overlayRef=this._overlay.create(this._buildConfig());this._attachSubscription=ke.attachments().subscribe(()=>this.attach.emit()),this._detachSubscription=ke.detachments().subscribe(()=>this.detach.emit()),ke.keydownEvents().subscribe(Je=>{this.overlayKeydown.next(Je),Je.keyCode===se._f&&!this.disableClose&&!(0,se.rp)(Je)&&(Je.preventDefault(),this._detachOverlay())}),this._overlayRef.outsidePointerEvents().subscribe(Je=>{const z=this._getOriginElement(),N=(0,w.Fb)(Je);(!z||z!==N&&!z.contains(N))&&this.overlayOutsideClick.next(Je)})}_buildConfig(){const ke=this._position=this.positionStrategy||this._createPositionStrategy(),Je=new Be({direction:this._dir||"ltr",positionStrategy:ke,scrollStrategy:this.scrollStrategy,hasBackdrop:this.hasBackdrop,disposeOnNavigation:this.disposeOnNavigation});return(this.width||0===this.width)&&(Je.width=this.width),(this.height||0===this.height)&&(Je.height=this.height),(this.minWidth||0===this.minWidth)&&(Je.minWidth=this.minWidth),(this.minHeight||0===this.minHeight)&&(Je.minHeight=this.minHeight),this.backdropClass&&(Je.backdropClass=this.backdropClass),this.panelClass&&(Je.panelClass=this.panelClass),Je}_updatePositionStrategy(ke){const Je=this.positions.map(z=>({originX:z.originX,originY:z.originY,overlayX:z.overlayX,overlayY:z.overlayY,offsetX:z.offsetX||this.offsetX,offsetY:z.offsetY||this.offsetY,panelClass:z.panelClass||void 0}));return ke.setOrigin(this._getOrigin()).withPositions(Je).withFlexibleDimensions(this.flexibleDimensions).withPush(this.push).withGrowAfterOpen(this.growAfterOpen).withViewportMargin(this.viewportMargin).withLockedPosition(this.lockPosition).withTransformOriginOn(this.transformOriginSelector)}_createPositionStrategy(){const ke=this._overlay.position().flexibleConnectedTo(this._getOrigin());return this._updatePositionStrategy(ke),ke}_getOrigin(){return this.origin instanceof en?this.origin.elementRef:this.origin}_getOriginElement(){return this.origin instanceof en?this.origin.elementRef.nativeElement:this.origin instanceof c.aKT?this.origin.nativeElement:typeof Element<"u"&&this.origin instanceof Element?this.origin:null}_attachOverlay(){this._overlayRef?this._overlayRef.getConfig().hasBackdrop=this.hasBackdrop:this._createOverlay(),this._overlayRef.hasAttached()||this._overlayRef.attach(this._templatePortal),this.hasBackdrop?this._backdropSubscription=this._overlayRef.backdropClick().subscribe(ke=>{this.backdropClick.emit(ke)}):this._backdropSubscription.unsubscribe(),this._positionSubscription.unsubscribe(),this.positionChange.observers.length>0&&(this._positionSubscription=this._position.positionChanges.pipe((0,S.v)(()=>this.positionChange.observers.length>0)).subscribe(ke=>{this._ngZone.run(()=>this.positionChange.emit(ke)),0===this.positionChange.observers.length&&this._positionSubscription.unsubscribe()}))}_detachOverlay(){this._overlayRef&&this._overlayRef.detach(),this._backdropSubscription.unsubscribe(),this._positionSubscription.unsubscribe()}static \u0275fac=function(Je){return new(Je||cn)};static \u0275dir=c.FsC({type:cn,selectors:[["","cdk-connected-overlay",""],["","connected-overlay",""],["","cdkConnectedOverlay",""]],inputs:{origin:[0,"cdkConnectedOverlayOrigin","origin"],positions:[0,"cdkConnectedOverlayPositions","positions"],positionStrategy:[0,"cdkConnectedOverlayPositionStrategy","positionStrategy"],offsetX:[0,"cdkConnectedOverlayOffsetX","offsetX"],offsetY:[0,"cdkConnectedOverlayOffsetY","offsetY"],width:[0,"cdkConnectedOverlayWidth","width"],height:[0,"cdkConnectedOverlayHeight","height"],minWidth:[0,"cdkConnectedOverlayMinWidth","minWidth"],minHeight:[0,"cdkConnectedOverlayMinHeight","minHeight"],backdropClass:[0,"cdkConnectedOverlayBackdropClass","backdropClass"],panelClass:[0,"cdkConnectedOverlayPanelClass","panelClass"],viewportMargin:[0,"cdkConnectedOverlayViewportMargin","viewportMargin"],scrollStrategy:[0,"cdkConnectedOverlayScrollStrategy","scrollStrategy"],open:[0,"cdkConnectedOverlayOpen","open"],disableClose:[0,"cdkConnectedOverlayDisableClose","disableClose"],transformOriginSelector:[0,"cdkConnectedOverlayTransformOriginOn","transformOriginSelector"],hasBackdrop:[2,"cdkConnectedOverlayHasBackdrop","hasBackdrop",c.L39],lockPosition:[2,"cdkConnectedOverlayLockPosition","lockPosition",c.L39],flexibleDimensions:[2,"cdkConnectedOverlayFlexibleDimensions","flexibleDimensions",c.L39],growAfterOpen:[2,"cdkConnectedOverlayGrowAfterOpen","growAfterOpen",c.L39],push:[2,"cdkConnectedOverlayPush","push",c.L39],disposeOnNavigation:[2,"cdkConnectedOverlayDisposeOnNavigation","disposeOnNavigation",c.L39]},outputs:{backdropClick:"backdropClick",positionChange:"positionChange",attach:"attach",detach:"detach",overlayKeydown:"overlayKeydown",overlayOutsideClick:"overlayOutsideClick"},exportAs:["cdkConnectedOverlay"],features:[c.GFd,c.OA$]})}return cn})();const Nr={provide:Vt,deps:[Kt],useFactory:function Kn(cn){return()=>cn.scrollStrategies.reposition()}};let Rn=(()=>{class cn{static \u0275fac=function(Je){return new(Je||cn)};static \u0275mod=c.$C({type:cn});static \u0275inj=c.G2t({providers:[Kt,Nr],imports:[M.jI,O.jc,i.E9,i.E9]})}return cn})()},2147:(o,s,r)=>{"use strict";r.d(s,{BD:()=>se,BQ:()=>L,CZ:()=>pe,Fb:()=>xe,KT:()=>be,MU:()=>S,OD:()=>y,r5:()=>Z,v8:()=>De,vc:()=>Oe});var i=r(3107),a=r(4460);let c;try{c=typeof Intl<"u"&&Intl.v8BreakIterator}catch{c=!1}let C,y=(()=>{class ce{_platformId=(0,i.WQX)(i.Agw);isBrowser=this._platformId?(0,a.UE)(this._platformId):"object"==typeof document&&!!document;EDGE=this.isBrowser&&/(edge)/i.test(navigator.userAgent);TRIDENT=this.isBrowser&&/(msie|trident)/i.test(navigator.userAgent);BLINK=this.isBrowser&&!(!window.chrome&&!c)&&typeof CSS<"u"&&!this.EDGE&&!this.TRIDENT;WEBKIT=this.isBrowser&&/AppleWebKit/i.test(navigator.userAgent)&&!this.BLINK&&!this.EDGE&&!this.TRIDENT;IOS=this.isBrowser&&/iPad|iPhone|iPod/.test(navigator.userAgent)&&!("MSStream"in window);FIREFOX=this.isBrowser&&/(firefox|minefield)/i.test(navigator.userAgent);ANDROID=this.isBrowser&&/android/i.test(navigator.userAgent)&&!this.TRIDENT;SAFARI=this.isBrowser&&/safari/i.test(navigator.userAgent)&&this.WEBKIT;constructor(){}static \u0275fac=function(Be){return new(Be||ce)};static \u0275prov=i.jDH({token:ce,factory:ce.\u0275fac,providedIn:"root"})}return ce})();const T=["color","button","checkbox","date","datetime-local","email","file","hidden","image","month","number","password","radio","range","reset","search","submit","tel","text","time","url","week"];function S(){if(C)return C;if("object"!=typeof document||!document)return C=new Set(T),C;let ce=document.createElement("input");return C=new Set(T.filter(ue=>(ce.setAttribute("type",ue),ce.type===ue))),C}let M;function L(ce){return function O(){if(null==M&&typeof window<"u")try{window.addEventListener("test",null,Object.defineProperty({},"passive",{get:()=>M=!0}))}finally{M=M||!1}return M}()?ce:!!ce.capture}var Z=function(ce){return ce[ce.NORMAL=0]="NORMAL",ce[ce.NEGATED=1]="NEGATED",ce[ce.INVERTED=2]="INVERTED",ce}(Z||{});let q,re,ae;function pe(){if(null==re){if("object"!=typeof document||!document||"function"!=typeof Element||!Element)return re=!1,re;if("scrollBehavior"in document.documentElement.style)re=!0;else{const ce=Element.prototype.scrollTo;re=!!ce&&!/\{\s*\[native code\]\s*\}/.test(ce.toString())}}return re}function se(){if("object"!=typeof document||!document)return Z.NORMAL;if(null==q){const ce=document.createElement("div"),ue=ce.style;ce.dir="rtl",ue.width="1px",ue.overflow="auto",ue.visibility="hidden",ue.pointerEvents="none",ue.position="absolute";const Ce=document.createElement("div"),Be=Ce.style;Be.width="2px",Be.height="1px",ce.appendChild(Ce),document.body.appendChild(ce),q=Z.NORMAL,0===ce.scrollLeft&&(ce.scrollLeft=1,q=0===ce.scrollLeft?Z.NEGATED:Z.INVERTED),ce.remove()}return q}function be(ce){if(function me(){if(null==ae){const ce=typeof document<"u"?document.head:null;ae=!(!ce||!ce.createShadowRoot&&!ce.attachShadow)}return ae}()){const ue=ce.getRootNode?ce.getRootNode():null;if(typeof ShadowRoot<"u"&&ShadowRoot&&ue instanceof ShadowRoot)return ue}return null}function Oe(){let ce=typeof document<"u"&&document?document.activeElement:null;for(;ce&&ce.shadowRoot;){const ue=ce.shadowRoot.activeElement;if(ue===ce)break;ce=ue}return ce}function xe(ce){return ce.composedPath?ce.composedPath()[0]:ce.target}function De(){return typeof __karma__<"u"&&!!__karma__||typeof jasmine<"u"&&!!jasmine||typeof jest<"u"&&!!jest||typeof Mocha<"u"&&!!Mocha}},6192:(o,s,r)=>{"use strict";r.d(s,{A8:()=>O,I3:()=>be,VA:()=>L,aI:()=>pe,jc:()=>xe,lb:()=>q});var i=r(3107),a=r(4460);class M{_attachedHost;attach(ue){return this._attachedHost=ue,ue.attach(this)}detach(){let ue=this._attachedHost;null!=ue&&(this._attachedHost=null,ue.detach())}get isAttached(){return null!=this._attachedHost}setAttachedHost(ue){this._attachedHost=ue}}class O extends M{component;viewContainerRef;injector;componentFactoryResolver;projectableNodes;constructor(ue,Ce,Be,at,dt){super(),this.component=ue,this.viewContainerRef=Ce,this.injector=Be,this.projectableNodes=dt}}class L extends M{templateRef;viewContainerRef;context;injector;constructor(ue,Ce,Be,at){super(),this.templateRef=ue,this.viewContainerRef=Ce,this.context=Be,this.injector=at}get origin(){return this.templateRef.elementRef}attach(ue,Ce=this.context){return this.context=Ce,super.attach(ue)}detach(){return this.context=void 0,super.detach()}}class Z extends M{element;constructor(ue){super(),this.element=ue instanceof i.aKT?ue.nativeElement:ue}}class q{_attachedPortal;_disposeFn;_isDisposed=!1;hasAttached(){return!!this._attachedPortal}attach(ue){return ue instanceof O?(this._attachedPortal=ue,this.attachComponentPortal(ue)):ue instanceof L?(this._attachedPortal=ue,this.attachTemplatePortal(ue)):this.attachDomPortal&&ue instanceof Z?(this._attachedPortal=ue,this.attachDomPortal(ue)):void 0}attachDomPortal=null;detach(){this._attachedPortal&&(this._attachedPortal.setAttachedHost(null),this._attachedPortal=null),this._invokeDisposeFn()}dispose(){this.hasAttached()&&this.detach(),this._invokeDisposeFn(),this._isDisposed=!0}setDisposeFn(ue){this._disposeFn=ue}_invokeDisposeFn(){this._disposeFn&&(this._disposeFn(),this._disposeFn=null)}}class pe extends q{outletElement;_appRef;_defaultInjector;_document;constructor(ue,Ce,Be,at,dt){super(),this.outletElement=ue,this._appRef=Be,this._defaultInjector=at,this._document=dt}attachComponentPortal(ue){let Ce;if(ue.viewContainerRef){const Be=ue.injector||ue.viewContainerRef.injector,at=Be.get(i.Vns,null,{optional:!0})||void 0;Ce=ue.viewContainerRef.createComponent(ue.component,{index:ue.viewContainerRef.length,injector:Be,ngModuleRef:at,projectableNodes:ue.projectableNodes||void 0}),this.setDisposeFn(()=>Ce.destroy())}else Ce=(0,i.a0P)(ue.component,{elementInjector:ue.injector||this._defaultInjector||i.zZn.NULL,environmentInjector:this._appRef.injector,projectableNodes:ue.projectableNodes||void 0}),this._appRef.attachView(Ce.hostView),this.setDisposeFn(()=>{this._appRef.viewCount>0&&this._appRef.detachView(Ce.hostView),Ce.destroy()});return this.outletElement.appendChild(this._getComponentRootNode(Ce)),this._attachedPortal=ue,Ce}attachTemplatePortal(ue){let Ce=ue.viewContainerRef,Be=Ce.createEmbeddedView(ue.templateRef,ue.context,{injector:ue.injector});return Be.rootNodes.forEach(at=>this.outletElement.appendChild(at)),Be.detectChanges(),this.setDisposeFn(()=>{let at=Ce.indexOf(Be);-1!==at&&Ce.remove(at)}),this._attachedPortal=ue,Be}attachDomPortal=ue=>{const Ce=ue.element,Be=this._document.createComment("dom-portal");Ce.parentNode.insertBefore(Be,Ce),this.outletElement.appendChild(Ce),this._attachedPortal=ue,super.setDisposeFn(()=>{Be.parentNode&&Be.parentNode.replaceChild(Ce,Be)})};dispose(){super.dispose(),this.outletElement.remove()}_getComponentRootNode(ue){return ue.hostView.rootNodes[0]}}let be=(()=>{class ce extends q{_moduleRef=(0,i.WQX)(i.Vns,{optional:!0});_document=(0,i.WQX)(a.qQ);_viewContainerRef=(0,i.WQX)(i.c1b);_isInitialized=!1;_attachedRef;constructor(){super()}get portal(){return this._attachedPortal}set portal(Ce){this.hasAttached()&&!Ce&&!this._isInitialized||(this.hasAttached()&&super.detach(),Ce&&super.attach(Ce),this._attachedPortal=Ce||null)}attached=new i.bkB;get attachedRef(){return this._attachedRef}ngOnInit(){this._isInitialized=!0}ngOnDestroy(){super.dispose(),this._attachedRef=this._attachedPortal=null}attachComponentPortal(Ce){Ce.setAttachedHost(this);const Be=null!=Ce.viewContainerRef?Ce.viewContainerRef:this._viewContainerRef,at=Be.createComponent(Ce.component,{index:Be.length,injector:Ce.injector||Be.injector,projectableNodes:Ce.projectableNodes||void 0,ngModuleRef:this._moduleRef||void 0});return Be!==this._viewContainerRef&&this._getRootNode().appendChild(at.hostView.rootNodes[0]),super.setDisposeFn(()=>at.destroy()),this._attachedPortal=Ce,this._attachedRef=at,this.attached.emit(at),at}attachTemplatePortal(Ce){Ce.setAttachedHost(this);const Be=this._viewContainerRef.createEmbeddedView(Ce.templateRef,Ce.context,{injector:Ce.injector});return super.setDisposeFn(()=>this._viewContainerRef.clear()),this._attachedPortal=Ce,this._attachedRef=Be,this.attached.emit(Be),Be}attachDomPortal=Ce=>{const Be=Ce.element,at=this._document.createComment("dom-portal");Ce.setAttachedHost(this),Be.parentNode.insertBefore(at,Be),this._getRootNode().appendChild(Be),this._attachedPortal=Ce,super.setDisposeFn(()=>{at.parentNode&&at.parentNode.replaceChild(Be,at)})};_getRootNode(){const Ce=this._viewContainerRef.element.nativeElement;return Ce.nodeType===Ce.ELEMENT_NODE?Ce:Ce.parentNode}static \u0275fac=function(Be){return new(Be||ce)};static \u0275dir=i.FsC({type:ce,selectors:[["","cdkPortalOutlet",""]],inputs:{portal:[0,"cdkPortalOutlet","portal"]},outputs:{attached:"attached"},exportAs:["cdkPortalOutlet"],features:[i.Vt3]})}return ce})(),xe=(()=>{class ce{static \u0275fac=function(Be){return new(Be||ce)};static \u0275mod=i.$C({type:ce});static \u0275inj=i.G2t({})}return ce})()},5467:(o,s,r)=>{"use strict";r.d(s,{Y:()=>y,l:()=>c});var i=r(3107);const a=new WeakMap;let c=(()=>{class w{_appRef;_injector=(0,i.WQX)(i.zZn);_environmentInjector=(0,i.WQX)(i.uvJ);load(T){const S=this._appRef=this._appRef||this._injector.get(i.o8S);let M=a.get(S);M||(M={loaders:new Set,refs:[]},a.set(S,M),S.onDestroy(()=>{a.get(S)?.refs.forEach(O=>O.destroy()),a.delete(S)})),M.loaders.has(T)||(M.loaders.add(T),M.refs.push((0,i.a0P)(T,{environmentInjector:this._environmentInjector})))}static \u0275fac=function(S){return new(S||w)};static \u0275prov=i.jDH({token:w,factory:w.\u0275fac,providedIn:"root"})}return w})(),y=(()=>{class w{static \u0275fac=function(S){return new(S||w)};static \u0275cmp=i.VBU({type:w,selectors:[["ng-component"]],exportAs:["cdkVisuallyHidden"],decls:0,vars:0,template:function(S,M){},styles:[".cdk-visually-hidden{border:0;clip:rect(0 0 0 0);height:1px;margin:-1px;overflow:hidden;padding:0;position:absolute;width:1px;white-space:nowrap;outline:0;-webkit-appearance:none;-moz-appearance:none;left:0}[dir=rtl] .cdk-visually-hidden{left:auto;right:0}"],encapsulation:2,changeDetection:0})}return w})()},8108:(o,s,r)=>{"use strict";r.d(s,{uv:()=>lt,Gj:()=>Ze,R:()=>bt,E9:()=>it,Xj:()=>gn});var i=r(3022),a=r(3107),c=r(8447),y=r(3016),w=r(1698),C=r(909),T=r(9899),S=r(5710);const M={schedule(Ot){let $t=requestAnimationFrame,Te=cancelAnimationFrame;const{delegate:Ee}=M;Ee&&($t=Ee.requestAnimationFrame,Te=Ee.cancelAnimationFrame);const st=$t(Xt=>{Te=void 0,Ot(Xt)});return new S.yU(()=>Te?.(st))},requestAnimationFrame(...Ot){const{delegate:$t}=M;return($t?.requestAnimationFrame||requestAnimationFrame)(...Ot)},cancelAnimationFrame(...Ot){const{delegate:$t}=M;return($t?.cancelAnimationFrame||cancelAnimationFrame)(...Ot)},delegate:void 0};var L=r(8050);new class Z extends L.q{flush($t){this._active=!0;const Te=this._scheduled;this._scheduled=void 0;const{actions:Ee}=this;let st;$t=$t||Ee.shift();do{if(st=$t.execute($t.state,$t.delay))break}while(($t=Ee[0])&&$t.id===Te&&Ee.shift());if(this._active=!1,st){for(;($t=Ee[0])&&$t.id===Te&&Ee.shift();)$t.unsubscribe();throw st}}}(class O extends T.R{constructor($t,Te){super($t,Te),this.scheduler=$t,this.work=Te}requestAsyncId($t,Te,Ee=0){return null!==Ee&&Ee>0?super.requestAsyncId($t,Te,Ee):($t.actions.push(this),$t._scheduled||($t._scheduled=M.requestAnimationFrame(()=>$t.flush(void 0))))}recycleAsyncId($t,Te,Ee=0){var st;if(null!=Ee?Ee>0:this.delay>0)return super.recycleAsyncId($t,Te,Ee);const{actions:Xt}=$t;null!=Te&&(null===(st=Xt[Xt.length-1])||void 0===st?void 0:st.id)!==Te&&(M.cancelAnimationFrame(Te),$t._scheduled=void 0)}});r(4984);var se=r(5684),ae=r(1483),me=r(5424),be=r(2147),Oe=r(4460),xe=r(2944);let bt=(()=>{class Ot{_ngZone=(0,a.WQX)(a.SKi);_platform=(0,a.WQX)(be.OD);_document=(0,a.WQX)(Oe.qQ,{optional:!0});constructor(){}_scrolled=new c.B;_globalSubscription=null;_scrolledCount=0;scrollContainers=new Map;register(Te){this.scrollContainers.has(Te)||this.scrollContainers.set(Te,Te.elementScrolled().subscribe(()=>this._scrolled.next(Te)))}deregister(Te){const Ee=this.scrollContainers.get(Te);Ee&&(Ee.unsubscribe(),this.scrollContainers.delete(Te))}scrolled(Te=20){return this._platform.isBrowser?new w.c(Ee=>{this._globalSubscription||this._addGlobalListener();const st=Te>0?this._scrolled.pipe((0,se.Z)(Te)).subscribe(Ee):this._scrolled.subscribe(Ee);return this._scrolledCount++,()=>{st.unsubscribe(),this._scrolledCount--,this._scrolledCount||this._removeGlobalListener()}}):(0,y.of)()}ngOnDestroy(){this._removeGlobalListener(),this.scrollContainers.forEach((Te,Ee)=>this.deregister(Ee)),this._scrolled.complete()}ancestorScrolled(Te,Ee){const st=this.getAncestorScrollContainers(Te);return this.scrolled(Ee).pipe((0,ae.p)(Xt=>!Xt||st.indexOf(Xt)>-1))}getAncestorScrollContainers(Te){const Ee=[];return this.scrollContainers.forEach((st,Xt)=>{this._scrollableContainsElement(Xt,Te)&&Ee.push(Xt)}),Ee}_getWindow(){return this._document.defaultView||window}_scrollableContainsElement(Te,Ee){let st=(0,i.i8)(Ee),Xt=Te.getElementRef().nativeElement;do{if(st==Xt)return!0}while(st=st.parentElement);return!1}_addGlobalListener(){this._globalSubscription=this._ngZone.runOutsideAngular(()=>{const Te=this._getWindow();return(0,C.R)(Te.document,"scroll").subscribe(()=>this._scrolled.next())})}_removeGlobalListener(){this._globalSubscription&&(this._globalSubscription.unsubscribe(),this._globalSubscription=null)}static \u0275fac=function(Ee){return new(Ee||Ot)};static \u0275prov=a.jDH({token:Ot,factory:Ot.\u0275fac,providedIn:"root"})}return Ot})(),lt=(()=>{class Ot{elementRef=(0,a.WQX)(a.aKT);scrollDispatcher=(0,a.WQX)(bt);ngZone=(0,a.WQX)(a.SKi);dir=(0,a.WQX)(xe.dS,{optional:!0});_destroyed=new c.B;_elementScrolled=new w.c(Te=>this.ngZone.runOutsideAngular(()=>(0,C.R)(this.elementRef.nativeElement,"scroll").pipe((0,me.Q)(this._destroyed)).subscribe(Te)));constructor(){}ngOnInit(){this.scrollDispatcher.register(this)}ngOnDestroy(){this.scrollDispatcher.deregister(this),this._destroyed.next(),this._destroyed.complete()}elementScrolled(){return this._elementScrolled}getElementRef(){return this.elementRef}scrollTo(Te){const Ee=this.elementRef.nativeElement,st=this.dir&&"rtl"==this.dir.value;null==Te.left&&(Te.left=st?Te.end:Te.start),null==Te.right&&(Te.right=st?Te.start:Te.end),null!=Te.bottom&&(Te.top=Ee.scrollHeight-Ee.clientHeight-Te.bottom),st&&(0,be.BD)()!=be.r5.NORMAL?(null!=Te.left&&(Te.right=Ee.scrollWidth-Ee.clientWidth-Te.left),(0,be.BD)()==be.r5.INVERTED?Te.left=Te.right:(0,be.BD)()==be.r5.NEGATED&&(Te.left=Te.right?-Te.right:Te.right)):null!=Te.right&&(Te.left=Ee.scrollWidth-Ee.clientWidth-Te.right),this._applyScrollToOptions(Te)}_applyScrollToOptions(Te){const Ee=this.elementRef.nativeElement;(0,be.CZ)()?Ee.scrollTo(Te):(null!=Te.top&&(Ee.scrollTop=Te.top),null!=Te.left&&(Ee.scrollLeft=Te.left))}measureScrollOffset(Te){const Ee="left",Xt=this.elementRef.nativeElement;if("top"==Te)return Xt.scrollTop;if("bottom"==Te)return Xt.scrollHeight-Xt.clientHeight-Xt.scrollTop;const Mt=this.dir&&"rtl"==this.dir.value;return"start"==Te?Te=Mt?"right":Ee:"end"==Te&&(Te=Mt?Ee:"right"),Mt&&(0,be.BD)()==be.r5.INVERTED?Te==Ee?Xt.scrollWidth-Xt.clientWidth-Xt.scrollLeft:Xt.scrollLeft:Mt&&(0,be.BD)()==be.r5.NEGATED?Te==Ee?Xt.scrollLeft+Xt.scrollWidth-Xt.clientWidth:-Xt.scrollLeft:Te==Ee?Xt.scrollLeft:Xt.scrollWidth-Xt.clientWidth-Xt.scrollLeft}static \u0275fac=function(Ee){return new(Ee||Ot)};static \u0275dir=a.FsC({type:Ot,selectors:[["","cdk-scrollable",""],["","cdkScrollable",""]]})}return Ot})(),gn=(()=>{class Ot{_platform=(0,a.WQX)(be.OD);_viewportSize;_change=new c.B;_changeListener=Te=>{this._change.next(Te)};_document=(0,a.WQX)(Oe.qQ,{optional:!0});constructor(){(0,a.WQX)(a.SKi).runOutsideAngular(()=>{if(this._platform.isBrowser){const Ee=this._getWindow();Ee.addEventListener("resize",this._changeListener),Ee.addEventListener("orientationchange",this._changeListener)}this.change().subscribe(()=>this._viewportSize=null)})}ngOnDestroy(){if(this._platform.isBrowser){const Te=this._getWindow();Te.removeEventListener("resize",this._changeListener),Te.removeEventListener("orientationchange",this._changeListener)}this._change.complete()}getViewportSize(){this._viewportSize||this._updateViewportSize();const Te={width:this._viewportSize.width,height:this._viewportSize.height};return this._platform.isBrowser||(this._viewportSize=null),Te}getViewportRect(){const Te=this.getViewportScrollPosition(),{width:Ee,height:st}=this.getViewportSize();return{top:Te.top,left:Te.left,bottom:Te.top+st,right:Te.left+Ee,height:st,width:Ee}}getViewportScrollPosition(){if(!this._platform.isBrowser)return{top:0,left:0};const Te=this._document,Ee=this._getWindow(),st=Te.documentElement,Xt=st.getBoundingClientRect();return{top:-Xt.top||Te.body.scrollTop||Ee.scrollY||st.scrollTop||0,left:-Xt.left||Te.body.scrollLeft||Ee.scrollX||st.scrollLeft||0}}change(Te=20){return Te>0?this._change.pipe((0,se.Z)(Te)):this._change}_getWindow(){return this._document.defaultView||window}_updateViewportSize(){const Te=this._getWindow();this._viewportSize=this._platform.isBrowser?{width:Te.innerWidth,height:Te.innerHeight}:{width:0,height:0}}static \u0275fac=function(Ee){return new(Ee||Ot)};static \u0275prov=a.jDH({token:Ot,factory:Ot.\u0275fac,providedIn:"root"})}return Ot})(),Ze=(()=>{class Ot{static \u0275fac=function(Ee){return new(Ee||Ot)};static \u0275mod=a.$C({type:Ot});static \u0275inj=a.G2t({})}return Ot})(),it=(()=>{class Ot{static \u0275fac=function(Ee){return new(Ee||Ot)};static \u0275mod=a.$C({type:Ot});static \u0275inj=a.G2t({imports:[xe.jI,Ze,xe.jI,Ze]})}return Ot})()},708:(o,s,r)=>{"use strict";r.d(s,{EE:()=>se,P8:()=>q,xb:()=>pe});var i=r(2147),a=r(3107),c=r(5467),y=r(3022),w=r(6564),C=r(8447),T=r(909),S=r(4460),M=r(5684),O=r(5424);let L=(()=>{class ae{static \u0275fac=function(Oe){return new(Oe||ae)};static \u0275cmp=a.VBU({type:ae,selectors:[["ng-component"]],hostAttrs:["cdk-text-field-style-loader",""],decls:0,vars:0,template:function(Oe,xe){},styles:["textarea.cdk-textarea-autosize{resize:none}textarea.cdk-textarea-autosize-measuring{padding:2px 0 !important;box-sizing:content-box !important;height:auto !important;overflow:hidden !important}textarea.cdk-textarea-autosize-measuring-firefox{padding:2px 0 !important;box-sizing:content-box !important;height:0 !important}@keyframes cdk-text-field-autofill-start{/*!*/}@keyframes cdk-text-field-autofill-end{/*!*/}.cdk-text-field-autofill-monitored:-webkit-autofill{animation:cdk-text-field-autofill-start 0s 1ms}.cdk-text-field-autofill-monitored:not(:-webkit-autofill){animation:cdk-text-field-autofill-end 0s 1ms}"],encapsulation:2,changeDetection:0})}return ae})();const Z=(0,i.BQ)({passive:!0});let q=(()=>{class ae{_platform=(0,a.WQX)(i.OD);_ngZone=(0,a.WQX)(a.SKi);_styleLoader=(0,a.WQX)(c.l);_monitoredElements=new Map;constructor(){}monitor(be){if(!this._platform.isBrowser)return w.w;this._styleLoader.load(L);const Oe=(0,y.i8)(be),xe=this._monitoredElements.get(Oe);if(xe)return xe.subject;const De=new C.B,ce="cdk-text-field-autofilled",ue=Ce=>{"cdk-text-field-autofill-start"!==Ce.animationName||Oe.classList.contains(ce)?"cdk-text-field-autofill-end"===Ce.animationName&&Oe.classList.contains(ce)&&(Oe.classList.remove(ce),this._ngZone.run(()=>De.next({target:Ce.target,isAutofilled:!1}))):(Oe.classList.add(ce),this._ngZone.run(()=>De.next({target:Ce.target,isAutofilled:!0})))};return this._ngZone.runOutsideAngular(()=>{Oe.addEventListener("animationstart",ue,Z),Oe.classList.add("cdk-text-field-autofill-monitored")}),this._monitoredElements.set(Oe,{subject:De,unlisten:()=>{Oe.removeEventListener("animationstart",ue,Z)}}),De}stopMonitoring(be){const Oe=(0,y.i8)(be),xe=this._monitoredElements.get(Oe);xe&&(xe.unlisten(),xe.subject.complete(),Oe.classList.remove("cdk-text-field-autofill-monitored"),Oe.classList.remove("cdk-text-field-autofilled"),this._monitoredElements.delete(Oe))}ngOnDestroy(){this._monitoredElements.forEach((be,Oe)=>this.stopMonitoring(Oe))}static \u0275fac=function(Oe){return new(Oe||ae)};static \u0275prov=a.jDH({token:ae,factory:ae.\u0275fac,providedIn:"root"})}return ae})(),pe=(()=>{class ae{_elementRef=(0,a.WQX)(a.aKT);_platform=(0,a.WQX)(i.OD);_ngZone=(0,a.WQX)(a.SKi);_previousValue;_initialHeight;_destroyed=new C.B;_minRows;_maxRows;_enabled=!0;_previousMinRows=-1;_textareaElement;get minRows(){return this._minRows}set minRows(be){this._minRows=(0,y.OE)(be),this._setMinHeight()}get maxRows(){return this._maxRows}set maxRows(be){this._maxRows=(0,y.OE)(be),this._setMaxHeight()}get enabled(){return this._enabled}set enabled(be){this._enabled!==be&&((this._enabled=be)?this.resizeToFitContent(!0):this.reset())}get placeholder(){return this._textareaElement.placeholder}set placeholder(be){this._cachedPlaceholderHeight=void 0,be?this._textareaElement.setAttribute("placeholder",be):this._textareaElement.removeAttribute("placeholder"),this._cacheTextareaPlaceholderHeight()}_cachedLineHeight;_cachedPlaceholderHeight;_document=(0,a.WQX)(S.qQ,{optional:!0});_hasFocus;_isViewInited=!1;constructor(){(0,a.WQX)(c.l).load(L),this._textareaElement=this._elementRef.nativeElement}_setMinHeight(){const be=this.minRows&&this._cachedLineHeight?this.minRows*this._cachedLineHeight+"px":null;be&&(this._textareaElement.style.minHeight=be)}_setMaxHeight(){const be=this.maxRows&&this._cachedLineHeight?this.maxRows*this._cachedLineHeight+"px":null;be&&(this._textareaElement.style.maxHeight=be)}ngAfterViewInit(){this._platform.isBrowser&&(this._initialHeight=this._textareaElement.style.height,this.resizeToFitContent(),this._ngZone.runOutsideAngular(()=>{const be=this._getWindow();(0,T.R)(be,"resize").pipe((0,M.Z)(16),(0,O.Q)(this._destroyed)).subscribe(()=>this.resizeToFitContent(!0)),this._textareaElement.addEventListener("focus",this._handleFocusEvent),this._textareaElement.addEventListener("blur",this._handleFocusEvent)}),this._isViewInited=!0,this.resizeToFitContent(!0))}ngOnDestroy(){this._textareaElement.removeEventListener("focus",this._handleFocusEvent),this._textareaElement.removeEventListener("blur",this._handleFocusEvent),this._destroyed.next(),this._destroyed.complete()}_cacheTextareaLineHeight(){if(this._cachedLineHeight)return;let be=this._textareaElement.cloneNode(!1);be.rows=1,be.style.position="absolute",be.style.visibility="hidden",be.style.border="none",be.style.padding="0",be.style.height="",be.style.minHeight="",be.style.maxHeight="",be.style.overflow="hidden",this._textareaElement.parentNode.appendChild(be),this._cachedLineHeight=be.clientHeight,be.remove(),this._setMinHeight(),this._setMaxHeight()}_measureScrollHeight(){const be=this._textareaElement,Oe=be.style.marginBottom||"",xe=this._platform.FIREFOX,De=xe&&this._hasFocus,ce=xe?"cdk-textarea-autosize-measuring-firefox":"cdk-textarea-autosize-measuring";De&&(be.style.marginBottom=`${be.clientHeight}px`),be.classList.add(ce);const ue=be.scrollHeight-4;return be.classList.remove(ce),De&&(be.style.marginBottom=Oe),ue}_cacheTextareaPlaceholderHeight(){if(!this._isViewInited||null!=this._cachedPlaceholderHeight)return;if(!this.placeholder)return void(this._cachedPlaceholderHeight=0);const be=this._textareaElement.value;this._textareaElement.value=this._textareaElement.placeholder,this._cachedPlaceholderHeight=this._measureScrollHeight(),this._textareaElement.value=be}_handleFocusEvent=be=>{this._hasFocus="focus"===be.type};ngDoCheck(){this._platform.isBrowser&&this.resizeToFitContent()}resizeToFitContent(be=!1){if(!this._enabled||(this._cacheTextareaLineHeight(),this._cacheTextareaPlaceholderHeight(),!this._cachedLineHeight))return;const Oe=this._elementRef.nativeElement,xe=Oe.value;if(!be&&this._minRows===this._previousMinRows&&xe===this._previousValue)return;const De=this._measureScrollHeight(),ce=Math.max(De,this._cachedPlaceholderHeight||0);Oe.style.height=`${ce}px`,this._ngZone.runOutsideAngular(()=>{typeof requestAnimationFrame<"u"?requestAnimationFrame(()=>this._scrollToCaretPosition(Oe)):setTimeout(()=>this._scrollToCaretPosition(Oe))}),this._previousValue=xe,this._previousMinRows=this._minRows}reset(){void 0!==this._initialHeight&&(this._textareaElement.style.height=this._initialHeight)}_noopInputHandler(){}_getDocument(){return this._document||document}_getWindow(){return this._getDocument().defaultView||window}_scrollToCaretPosition(be){const{selectionStart:Oe,selectionEnd:xe}=be;!this._destroyed.isStopped&&this._hasFocus&&be.setSelectionRange(Oe,xe)}static \u0275fac=function(Oe){return new(Oe||ae)};static \u0275dir=a.FsC({type:ae,selectors:[["textarea","cdkTextareaAutosize",""]],hostAttrs:["rows","1",1,"cdk-textarea-autosize"],hostBindings:function(Oe,xe){1&Oe&&a.bIt("input",function(){return xe._noopInputHandler()})},inputs:{minRows:[0,"cdkAutosizeMinRows","minRows"],maxRows:[0,"cdkAutosizeMaxRows","maxRows"],enabled:[2,"cdkTextareaAutosize","enabled",a.L39],placeholder:"placeholder"},exportAs:["cdkTextareaAutosize"],features:[a.GFd]})}return ae})(),se=(()=>{class ae{static \u0275fac=function(Oe){return new(Oe||ae)};static \u0275mod=a.$C({type:ae});static \u0275inj=a.G2t({})}return ae})()},4460:(o,s,r)=>{"use strict";r.d(s,{AJ:()=>lr,B3:()=>xr,Jj:()=>es,MD:()=>Ao,N0:()=>Ss,PV:()=>Li,QT:()=>y,Sm:()=>ae,Sq:()=>ve,T3:()=>gi,UE:()=>Gs,VF:()=>C,Vy:()=>_s,Xr:()=>ls,YU:()=>Io,ZD:()=>w,_b:()=>ao,aZ:()=>be,bT:()=>gt,fw:()=>me,hb:()=>pe,hj:()=>O,jo:()=>hs,qQ:()=>S,vh:()=>Cs});var i=r(3107),a=r(8447);let c=null;function y(){return c}function w(U){c??=U}class C{}const S=new i.nKC("");let M=(()=>{class U{historyGo(ne){throw new Error("")}static \u0275fac=function(ye){return new(ye||U)};static \u0275prov=i.jDH({token:U,factory:()=>(0,i.WQX)(L),providedIn:"platform"})}return U})();const O=new i.nKC("");let L=(()=>{class U extends M{_location;_history;_doc=(0,i.WQX)(S);constructor(){super(),this._location=window.location,this._history=window.history}getBaseHrefFromDOM(){return y().getBaseHref(this._doc)}onPopState(ne){const ye=y().getGlobalEventTarget(this._doc,"window");return ye.addEventListener("popstate",ne,!1),()=>ye.removeEventListener("popstate",ne)}onHashChange(ne){const ye=y().getGlobalEventTarget(this._doc,"window");return ye.addEventListener("hashchange",ne,!1),()=>ye.removeEventListener("hashchange",ne)}get href(){return this._location.href}get protocol(){return this._location.protocol}get hostname(){return this._location.hostname}get port(){return this._location.port}get pathname(){return this._location.pathname}get search(){return this._location.search}get hash(){return this._location.hash}set pathname(ne){this._location.pathname=ne}pushState(ne,ye,Et){this._history.pushState(ne,ye,Et)}replaceState(ne,ye,Et){this._history.replaceState(ne,ye,Et)}forward(){this._history.forward()}back(){this._history.back()}historyGo(ne=0){this._history.go(ne)}getState(){return this._history.state}static \u0275fac=function(ye){return new(ye||U)};static \u0275prov=i.jDH({token:U,factory:()=>new U,providedIn:"platform"})}return U})();function Z(U,Ie){if(0==U.length)return Ie;if(0==Ie.length)return U;let ne=0;return U.endsWith("/")&&ne++,Ie.startsWith("/")&&ne++,2==ne?U+Ie.substring(1):1==ne?U+Ie:U+"/"+Ie}function q(U){const Ie=U.match(/#|\?|$/),ne=Ie&&Ie.index||U.length;return U.slice(0,ne-("/"===U[ne-1]?1:0))+U.slice(ne)}function re(U){return U&&"?"!==U[0]?"?"+U:U}let pe=(()=>{class U{historyGo(ne){throw new Error("")}static \u0275fac=function(ye){return new(ye||U)};static \u0275prov=i.jDH({token:U,factory:()=>(0,i.WQX)(ae),providedIn:"root"})}return U})();const se=new i.nKC("");let ae=(()=>{class U extends pe{_platformLocation;_baseHref;_removeListenerFns=[];constructor(ne,ye){super(),this._platformLocation=ne,this._baseHref=ye??this._platformLocation.getBaseHrefFromDOM()??(0,i.WQX)(S).location?.origin??""}ngOnDestroy(){for(;this._removeListenerFns.length;)this._removeListenerFns.pop()()}onPopState(ne){this._removeListenerFns.push(this._platformLocation.onPopState(ne),this._platformLocation.onHashChange(ne))}getBaseHref(){return this._baseHref}prepareExternalUrl(ne){return Z(this._baseHref,ne)}path(ne=!1){const ye=this._platformLocation.pathname+re(this._platformLocation.search),Et=this._platformLocation.hash;return Et&&ne?`${ye}${Et}`:ye}pushState(ne,ye,Et,Gt){const Un=this.prepareExternalUrl(Et+re(Gt));this._platformLocation.pushState(ne,ye,Un)}replaceState(ne,ye,Et,Gt){const Un=this.prepareExternalUrl(Et+re(Gt));this._platformLocation.replaceState(ne,ye,Un)}forward(){this._platformLocation.forward()}back(){this._platformLocation.back()}getState(){return this._platformLocation.getState()}historyGo(ne=0){this._platformLocation.historyGo?.(ne)}static \u0275fac=function(ye){return new(ye||U)(i.KVO(M),i.KVO(se,8))};static \u0275prov=i.jDH({token:U,factory:U.\u0275fac,providedIn:"root"})}return U})(),me=(()=>{class U extends pe{_platformLocation;_baseHref="";_removeListenerFns=[];constructor(ne,ye){super(),this._platformLocation=ne,null!=ye&&(this._baseHref=ye)}ngOnDestroy(){for(;this._removeListenerFns.length;)this._removeListenerFns.pop()()}onPopState(ne){this._removeListenerFns.push(this._platformLocation.onPopState(ne),this._platformLocation.onHashChange(ne))}getBaseHref(){return this._baseHref}path(ne=!1){const ye=this._platformLocation.hash??"#";return ye.length>0?ye.substring(1):ye}prepareExternalUrl(ne){const ye=Z(this._baseHref,ne);return ye.length>0?"#"+ye:ye}pushState(ne,ye,Et,Gt){let Un=this.prepareExternalUrl(Et+re(Gt));0==Un.length&&(Un=this._platformLocation.pathname),this._platformLocation.pushState(ne,ye,Un)}replaceState(ne,ye,Et,Gt){let Un=this.prepareExternalUrl(Et+re(Gt));0==Un.length&&(Un=this._platformLocation.pathname),this._platformLocation.replaceState(ne,ye,Un)}forward(){this._platformLocation.forward()}back(){this._platformLocation.back()}getState(){return this._platformLocation.getState()}historyGo(ne=0){this._platformLocation.historyGo?.(ne)}static \u0275fac=function(ye){return new(ye||U)(i.KVO(M),i.KVO(se,8))};static \u0275prov=i.jDH({token:U,factory:U.\u0275fac})}return U})(),be=(()=>{class U{_subject=new a.B;_basePath;_locationStrategy;_urlChangeListeners=[];_urlChangeSubscription=null;constructor(ne){this._locationStrategy=ne;const ye=this._locationStrategy.getBaseHref();this._basePath=function ce(U){if(new RegExp("^(https?:)?//").test(U)){const[,ne]=U.split(/\/\/[^\/]+/);return ne}return U}(q(De(ye))),this._locationStrategy.onPopState(Et=>{this._subject.next({url:this.path(!0),pop:!0,state:Et.state,type:Et.type})})}ngOnDestroy(){this._urlChangeSubscription?.unsubscribe(),this._urlChangeListeners=[]}path(ne=!1){return this.normalize(this._locationStrategy.path(ne))}getState(){return this._locationStrategy.getState()}isCurrentPathEqualTo(ne,ye=""){return this.path()==this.normalize(ne+re(ye))}normalize(ne){return U.stripTrailingSlash(function xe(U,Ie){if(!U||!Ie.startsWith(U))return Ie;const ne=Ie.substring(U.length);return""===ne||["/",";","?","#"].includes(ne[0])?ne:Ie}(this._basePath,De(ne)))}prepareExternalUrl(ne){return ne&&"/"!==ne[0]&&(ne="/"+ne),this._locationStrategy.prepareExternalUrl(ne)}go(ne,ye="",Et=null){this._locationStrategy.pushState(Et,"",ne,ye),this._notifyUrlChangeListeners(this.prepareExternalUrl(ne+re(ye)),Et)}replaceState(ne,ye="",Et=null){this._locationStrategy.replaceState(Et,"",ne,ye),this._notifyUrlChangeListeners(this.prepareExternalUrl(ne+re(ye)),Et)}forward(){this._locationStrategy.forward()}back(){this._locationStrategy.back()}historyGo(ne=0){this._locationStrategy.historyGo?.(ne)}onUrlChange(ne){return this._urlChangeListeners.push(ne),this._urlChangeSubscription??=this.subscribe(ye=>{this._notifyUrlChangeListeners(ye.url,ye.state)}),()=>{const ye=this._urlChangeListeners.indexOf(ne);this._urlChangeListeners.splice(ye,1),0===this._urlChangeListeners.length&&(this._urlChangeSubscription?.unsubscribe(),this._urlChangeSubscription=null)}}_notifyUrlChangeListeners(ne="",ye){this._urlChangeListeners.forEach(Et=>Et(ne,ye))}subscribe(ne,ye,Et){return this._subject.subscribe({next:ne,error:ye??void 0,complete:Et??void 0})}static normalizeQueryParams=re;static joinWithSlash=Z;static stripTrailingSlash=q;static \u0275fac=function(ye){return new(ye||U)(i.KVO(pe))};static \u0275prov=i.jDH({token:U,factory:()=>function Oe(){return new be((0,i.KVO)(pe))}(),providedIn:"root"})}return U})();function De(U){return U.replace(/\/index.html$/,"")}var Be=function(U){return U[U.Zero=0]="Zero",U[U.One=1]="One",U[U.Two=2]="Two",U[U.Few=3]="Few",U[U.Many=4]="Many",U[U.Other=5]="Other",U}(Be||{}),at=function(U){return U[U.Format=0]="Format",U[U.Standalone=1]="Standalone",U}(at||{}),dt=function(U){return U[U.Narrow=0]="Narrow",U[U.Abbreviated=1]="Abbreviated",U[U.Wide=2]="Wide",U[U.Short=3]="Short",U}(dt||{}),bt=function(U){return U[U.Short=0]="Short",U[U.Medium=1]="Medium",U[U.Long=2]="Long",U[U.Full=3]="Full",U}(bt||{});const lt={Decimal:0,Group:1,List:2,PercentSign:3,PlusSign:4,MinusSign:5,Exponential:6,SuperscriptingExponent:7,PerMille:8,Infinity:9,NaN:10,TimeSeparator:11,CurrencyDecimal:12,CurrencyGroup:13};function $e(U,Ie){return Vt((0,i.H5H)(U)[i.KH2.DateFormat],Ie)}function Ft(U,Ie){return Vt((0,i.H5H)(U)[i.KH2.TimeFormat],Ie)}function Ke(U,Ie){return Vt((0,i.H5H)(U)[i.KH2.DateTimeFormat],Ie)}function Ze(U,Ie){const ne=(0,i.H5H)(U),ye=ne[i.KH2.NumberSymbols][Ie];if(typeof ye>"u"){if(Ie===lt.CurrencyDecimal)return ne[i.KH2.NumberSymbols][lt.Decimal];if(Ie===lt.CurrencyGroup)return ne[i.KH2.NumberSymbols][lt.Group]}return ye}const st=i.mq5;function Xt(U){if(!U[i.KH2.ExtraData])throw new Error(`Missing extra locale data for the locale "${U[i.KH2.LocaleId]}". Use "registerLocaleData" to load new data. See the "I18n guide" on angular.io to know more.`)}function Vt(U,Ie){for(let ne=Ie;ne>-1;ne--)if(typeof U[ne]<"u")return U[ne];throw new Error("Locale data API: locale data undefined")}function en(U){const[Ie,ne]=U.split(":");return{hours:+Ie,minutes:+ne}}const Rn=/^(\d{4,})-?(\d\d)-?(\d\d)(?:T(\d\d)(?::?(\d\d)(?::?(\d\d)(?:\.(\d+))?)?)?(Z|([+-])(\d\d):?(\d\d))?)?$/,pr={},cn=/((?:[^BEGHLMOSWYZabcdhmswyz']+)|(?:'(?:[^']|'')*')|(?:G{1,5}|y{1,4}|Y{1,4}|M{1,5}|L{1,5}|w{1,2}|W{1}|d{1,2}|E{1,6}|c{1,6}|a{1,5}|b{1,5}|B{1,5}|h{1,2}|H{1,2}|m{1,2}|s{1,2}|S{1,3}|z{1,4}|Z{1,5}|O{1,4}))([\s\S]*)/;var Fe=function(U){return U[U.Short=0]="Short",U[U.ShortGMT=1]="ShortGMT",U[U.Long=2]="Long",U[U.Extended=3]="Extended",U}(Fe||{}),ke=function(U){return U[U.FullYear=0]="FullYear",U[U.Month=1]="Month",U[U.Date=2]="Date",U[U.Hours=3]="Hours",U[U.Minutes=4]="Minutes",U[U.Seconds=5]="Seconds",U[U.FractionalSeconds=6]="FractionalSeconds",U[U.Day=7]="Day",U}(ke||{}),Je=function(U){return U[U.DayPeriods=0]="DayPeriods",U[U.Days=1]="Days",U[U.Months=2]="Months",U[U.Eras=3]="Eras",U}(Je||{});function z(U,Ie,ne,ye){let Et=function ct(U){if(wn(U))return U;if("number"==typeof U&&!isNaN(U))return new Date(U);if("string"==typeof U){if(U=U.trim(),/^(\d{4}(-\d{1,2}(-\d{1,2})?)?)$/.test(U)){const[Et,Gt=1,Un=1]=U.split("-").map(tr=>+tr);return N(Et,Gt-1,Un)}const ne=parseFloat(U);if(!isNaN(U-ne))return new Date(ne);let ye;if(ye=U.match(Rn))return function Bt(U){const Ie=new Date(0);let ne=0,ye=0;const Et=U[8]?Ie.setUTCFullYear:Ie.setFullYear,Gt=U[8]?Ie.setUTCHours:Ie.setHours;U[9]&&(ne=Number(U[9]+U[10]),ye=Number(U[9]+U[11])),Et.call(Ie,Number(U[1]),Number(U[2])-1,Number(U[3]));const Un=Number(U[4]||0)-ne,tr=Number(U[5]||0)-ye,ci=Number(U[6]||0),ki=Math.floor(1e3*parseFloat("0."+(U[7]||0)));return Gt.call(Ie,Un,tr,ci,ki),Ie}(ye)}const Ie=new Date(U);if(!wn(Ie))throw new Error(`Unable to convert "${U}" into a date`);return Ie}(U);Ie=W(ne,Ie)||Ie;let tr,Un=[];for(;Ie;){if(tr=cn.exec(Ie),!tr){Un.push(Ie);break}{Un=Un.concat(tr.slice(1));const Di=Un.pop();if(!Di)break;Ie=Di}}let ci=Et.getTimezoneOffset();ye&&(ci=Ge(ye,ci),Et=function Dt(U,Ie,ne){const ye=ne?-1:1,Et=U.getTimezoneOffset();return function Ve(U,Ie){return(U=new Date(U.getTime())).setMinutes(U.getMinutes()+Ie),U}(U,ye*(Ge(Ie,Et)-Et))}(Et,ye,!0));let ki="";return Un.forEach(Di=>{const Rr=function Re(U){if(Wt[U])return Wt[U];let Ie;switch(U){case"G":case"GG":case"GGG":Ie=an(Je.Eras,dt.Abbreviated);break;case"GGGG":Ie=an(Je.Eras,dt.Wide);break;case"GGGGG":Ie=an(Je.Eras,dt.Narrow);break;case"y":Ie=St(ke.FullYear,1,0,!1,!0);break;case"yy":Ie=St(ke.FullYear,2,0,!0,!0);break;case"yyy":Ie=St(ke.FullYear,3,0,!1,!0);break;case"yyyy":Ie=St(ke.FullYear,4,0,!1,!0);break;case"Y":Ie=vt(1);break;case"YY":Ie=vt(2,!0);break;case"YYY":Ie=vt(3);break;case"YYYY":Ie=vt(4);break;case"M":case"L":Ie=St(ke.Month,1,1);break;case"MM":case"LL":Ie=St(ke.Month,2,1);break;case"MMM":Ie=an(Je.Months,dt.Abbreviated);break;case"MMMM":Ie=an(Je.Months,dt.Wide);break;case"MMMMM":Ie=an(Je.Months,dt.Narrow);break;case"LLL":Ie=an(Je.Months,dt.Abbreviated,at.Standalone);break;case"LLLL":Ie=an(Je.Months,dt.Wide,at.Standalone);break;case"LLLLL":Ie=an(Je.Months,dt.Narrow,at.Standalone);break;case"w":Ie=Vr(1);break;case"ww":Ie=Vr(2);break;case"W":Ie=Vr(1,!0);break;case"d":Ie=St(ke.Date,1);break;case"dd":Ie=St(ke.Date,2);break;case"c":case"cc":Ie=St(ke.Day,1);break;case"ccc":Ie=an(Je.Days,dt.Abbreviated,at.Standalone);break;case"cccc":Ie=an(Je.Days,dt.Wide,at.Standalone);break;case"ccccc":Ie=an(Je.Days,dt.Narrow,at.Standalone);break;case"cccccc":Ie=an(Je.Days,dt.Short,at.Standalone);break;case"E":case"EE":case"EEE":Ie=an(Je.Days,dt.Abbreviated);break;case"EEEE":Ie=an(Je.Days,dt.Wide);break;case"EEEEE":Ie=an(Je.Days,dt.Narrow);break;case"EEEEEE":Ie=an(Je.Days,dt.Short);break;case"a":case"aa":case"aaa":Ie=an(Je.DayPeriods,dt.Abbreviated);break;case"aaaa":Ie=an(Je.DayPeriods,dt.Wide);break;case"aaaaa":Ie=an(Je.DayPeriods,dt.Narrow);break;case"b":case"bb":case"bbb":Ie=an(Je.DayPeriods,dt.Abbreviated,at.Standalone,!0);break;case"bbbb":Ie=an(Je.DayPeriods,dt.Wide,at.Standalone,!0);break;case"bbbbb":Ie=an(Je.DayPeriods,dt.Narrow,at.Standalone,!0);break;case"B":case"BB":case"BBB":Ie=an(Je.DayPeriods,dt.Abbreviated,at.Format,!0);break;case"BBBB":Ie=an(Je.DayPeriods,dt.Wide,at.Format,!0);break;case"BBBBB":Ie=an(Je.DayPeriods,dt.Narrow,at.Format,!0);break;case"h":Ie=St(ke.Hours,1,-12);break;case"hh":Ie=St(ke.Hours,2,-12);break;case"H":Ie=St(ke.Hours,1);break;case"HH":Ie=St(ke.Hours,2);break;case"m":Ie=St(ke.Minutes,1);break;case"mm":Ie=St(ke.Minutes,2);break;case"s":Ie=St(ke.Seconds,1);break;case"ss":Ie=St(ke.Seconds,2);break;case"S":Ie=St(ke.FractionalSeconds,1);break;case"SS":Ie=St(ke.FractionalSeconds,2);break;case"SSS":Ie=St(ke.FractionalSeconds,3);break;case"Z":case"ZZ":case"ZZZ":Ie=In(Fe.Short);break;case"ZZZZZ":Ie=In(Fe.Extended);break;case"O":case"OO":case"OOO":case"z":case"zz":case"zzz":Ie=In(Fe.ShortGMT);break;case"OOOO":case"ZZZZ":case"zzzz":Ie=In(Fe.Long);break;default:return null}return Wt[U]=Ie,Ie}(Di);ki+=Rr?Rr(Et,ne,ci):"''"===Di?"'":Di.replace(/(^'|'$)/g,"").replace(/''/g,"'")}),ki}function N(U,Ie,ne){const ye=new Date(0);return ye.setFullYear(U,Ie,ne),ye.setHours(0,0,0),ye}function W(U,Ie){const ne=function gn(U){return(0,i.H5H)(U)[i.KH2.LocaleId]}(U);if(pr[ne]??={},pr[ne][Ie])return pr[ne][Ie];let ye="";switch(Ie){case"shortDate":ye=$e(U,bt.Short);break;case"mediumDate":ye=$e(U,bt.Medium);break;case"longDate":ye=$e(U,bt.Long);break;case"fullDate":ye=$e(U,bt.Full);break;case"shortTime":ye=Ft(U,bt.Short);break;case"mediumTime":ye=Ft(U,bt.Medium);break;case"longTime":ye=Ft(U,bt.Long);break;case"fullTime":ye=Ft(U,bt.Full);break;case"short":const Et=W(U,"shortTime"),Gt=W(U,"shortDate");ye=Le(Ke(U,bt.Short),[Et,Gt]);break;case"medium":const Un=W(U,"mediumTime"),tr=W(U,"mediumDate");ye=Le(Ke(U,bt.Medium),[Un,tr]);break;case"long":const ci=W(U,"longTime"),ki=W(U,"longDate");ye=Le(Ke(U,bt.Long),[ci,ki]);break;case"full":const Di=W(U,"fullTime"),Rr=W(U,"fullDate");ye=Le(Ke(U,bt.Full),[Di,Rr])}return ye&&(pr[ne][Ie]=ye),ye}function Le(U,Ie){return Ie&&(U=U.replace(/\{([^}]+)}/g,function(ne,ye){return null!=Ie&&ye in Ie?Ie[ye]:ne})),U}function ft(U,Ie,ne="-",ye,Et){let Gt="";(U<0||Et&&U<=0)&&(Et?U=1-U:(U=-U,Gt=ne));let Un=String(U);for(;Un.length0||tr>-ne)&&(tr+=ne),U===ke.Hours)0===tr&&-12===ne&&(tr=12);else if(U===ke.FractionalSeconds)return function mt(U,Ie){return ft(U,3).substring(0,Ie)}(tr,Ie);const ci=Ze(Un,lt.MinusSign);return ft(tr,Ie,ci,ye,Et)}}function an(U,Ie,ne=at.Format,ye=!1){return function(Et,Gt){return function dn(U,Ie,ne,ye,Et,Gt){switch(ne){case Je.Months:return function yn(U,Ie,ne){const ye=(0,i.H5H)(U),Gt=Vt([ye[i.KH2.MonthsFormat],ye[i.KH2.MonthsStandalone]],Ie);return Vt(Gt,ne)}(Ie,Et,ye)[U.getMonth()];case Je.Days:return function Vn(U,Ie,ne){const ye=(0,i.H5H)(U),Gt=Vt([ye[i.KH2.DaysFormat],ye[i.KH2.DaysStandalone]],Ie);return Vt(Gt,ne)}(Ie,Et,ye)[U.getDay()];case Je.DayPeriods:const Un=U.getHours(),tr=U.getMinutes();if(Gt){const ki=function Mt(U){const Ie=(0,i.H5H)(U);return Xt(Ie),(Ie[i.KH2.ExtraData][2]||[]).map(ye=>"string"==typeof ye?en(ye):[en(ye[0]),en(ye[1])])}(Ie),Di=function Kt(U,Ie,ne){const ye=(0,i.H5H)(U);Xt(ye);const Gt=Vt([ye[i.KH2.ExtraData][0],ye[i.KH2.ExtraData][1]],Ie)||[];return Vt(Gt,ne)||[]}(Ie,Et,ye),Rr=ki.findIndex(li=>{if(Array.isArray(li)){const[ii,wi]=li,bs=Un>=ii.hours&&tr>=ii.minutes,Lo=Un0?Math.floor(Et/60):Math.ceil(Et/60);switch(U){case Fe.Short:return(Et>=0?"+":"")+ft(Un,2,Gt)+ft(Math.abs(Et%60),2,Gt);case Fe.ShortGMT:return"GMT"+(Et>=0?"+":"")+ft(Un,1,Gt);case Fe.Long:return"GMT"+(Et>=0?"+":"")+ft(Un,2,Gt)+":"+ft(Math.abs(Et%60),2,Gt);case Fe.Extended:return 0===ye?"Z":(Et>=0?"+":"")+ft(Un,2,Gt)+":"+ft(Math.abs(Et%60),2,Gt);default:throw new Error(`Unknown zone width "${U}"`)}}}const sr=0,xn=4;function Tr(U){const Ie=U.getDay(),ne=0===Ie?-3:xn-Ie;return N(U.getFullYear(),U.getMonth(),U.getDate()+ne)}function Vr(U,Ie=!1){return function(ne,ye){let Et;if(Ie){const Gt=new Date(ne.getFullYear(),ne.getMonth(),1).getDay()-1,Un=ne.getDate();Et=1+Math.floor((Un+Gt)/7)}else{const Gt=Tr(ne),Un=function Hr(U){const Ie=N(U,sr,1).getDay();return N(U,0,1+(Ie<=xn?xn:xn+7)-Ie)}(Gt.getFullYear()),tr=Gt.getTime()-Un.getTime();Et=1+Math.round(tr/6048e5)}return ft(Et,U,Ze(ye,lt.MinusSign))}}function vt(U,Ie=!1){return function(ne,ye){return ft(Tr(ne).getFullYear(),U,Ze(ye,lt.MinusSign),Ie)}}const Wt={};function Ge(U,Ie){U=U.replace(/:/g,"");const ne=Date.parse("Jan 01, 1970 00:00:00 "+U)/6e4;return isNaN(ne)?Ie:ne}function wn(U){return U instanceof Date&&!isNaN(U.valueOf())}let fo=(()=>{class U{static \u0275fac=function(ye){return new(ye||U)};static \u0275prov=i.jDH({token:U,factory:function(ye){let Et=null;return ye?Et=new ye:(Gt=i.KVO(i.xe9),Et=new Fo(Gt)),Et;var Gt},providedIn:"root"})}return U})();let Fo=(()=>{class U extends fo{locale;constructor(ne){super(),this.locale=ne}getPluralCategory(ne,ye){switch(st(ye||this.locale)(ne)){case Be.Zero:return"zero";case Be.One:return"one";case Be.Two:return"two";case Be.Few:return"few";case Be.Many:return"many";default:return"other"}}static \u0275fac=function(ye){return new(ye||U)(i.KVO(i.xe9))};static \u0275prov=i.jDH({token:U,factory:U.\u0275fac})}return U})();function ao(U,Ie){Ie=encodeURIComponent(Ie);for(const ne of U.split(";")){const ye=ne.indexOf("="),[Et,Gt]=-1==ye?[ne,""]:[ne.slice(0,ye),ne.slice(ye+1)];if(Et.trim()===Ie)return decodeURIComponent(Gt)}return null}const po=/\s+/,Ii=[];let Io=(()=>{class U{_ngEl;_renderer;initialClasses=Ii;rawClass;stateMap=new Map;constructor(ne,ye){this._ngEl=ne,this._renderer=ye}set klass(ne){this.initialClasses=null!=ne?ne.trim().split(po):Ii}set ngClass(ne){this.rawClass="string"==typeof ne?ne.trim().split(po):ne}ngDoCheck(){for(const ye of this.initialClasses)this._updateState(ye,!0);const ne=this.rawClass;if(Array.isArray(ne)||ne instanceof Set)for(const ye of ne)this._updateState(ye,!0);else if(null!=ne)for(const ye of Object.keys(ne))this._updateState(ye,!!ne[ye]);this._applyStateDiff()}_updateState(ne,ye){const Et=this.stateMap.get(ne);void 0!==Et?(Et.enabled!==ye&&(Et.changed=!0,Et.enabled=ye),Et.touched=!0):this.stateMap.set(ne,{enabled:ye,changed:!0,touched:!0})}_applyStateDiff(){for(const ne of this.stateMap){const ye=ne[0],Et=ne[1];Et.changed?(this._toggleClass(ye,Et.enabled),Et.changed=!1):Et.touched||(Et.enabled&&this._toggleClass(ye,!1),this.stateMap.delete(ye)),Et.touched=!1}}_toggleClass(ne,ye){(ne=ne.trim()).length>0&&ne.split(po).forEach(Et=>{ye?this._renderer.addClass(this._ngEl.nativeElement,Et):this._renderer.removeClass(this._ngEl.nativeElement,Et)})}static \u0275fac=function(ye){return new(ye||U)(i.rXU(i.aKT),i.rXU(i.sFG))};static \u0275dir=i.FsC({type:U,selectors:[["","ngClass",""]],inputs:{klass:[0,"class","klass"],ngClass:"ngClass"}})}return U})();class ht{$implicit;ngForOf;index;count;constructor(Ie,ne,ye,Et){this.$implicit=Ie,this.ngForOf=ne,this.index=ye,this.count=Et}get first(){return 0===this.index}get last(){return this.index===this.count-1}get even(){return this.index%2==0}get odd(){return!this.even}}let ve=(()=>{class U{_viewContainer;_template;_differs;set ngForOf(ne){this._ngForOf=ne,this._ngForOfDirty=!0}set ngForTrackBy(ne){this._trackByFn=ne}get ngForTrackBy(){return this._trackByFn}_ngForOf=null;_ngForOfDirty=!0;_differ=null;_trackByFn;constructor(ne,ye,Et){this._viewContainer=ne,this._template=ye,this._differs=Et}set ngForTemplate(ne){ne&&(this._template=ne)}ngDoCheck(){if(this._ngForOfDirty){this._ngForOfDirty=!1;const ne=this._ngForOf;!this._differ&&ne&&(this._differ=this._differs.find(ne).create(this.ngForTrackBy))}if(this._differ){const ne=this._differ.diff(this._ngForOf);ne&&this._applyChanges(ne)}}_applyChanges(ne){const ye=this._viewContainer;ne.forEachOperation((Et,Gt,Un)=>{if(null==Et.previousIndex)ye.createEmbeddedView(this._template,new ht(Et.item,this._ngForOf,-1,-1),null===Un?void 0:Un);else if(null==Un)ye.remove(null===Gt?void 0:Gt);else if(null!==Gt){const tr=ye.get(Gt);ye.move(tr,Un),Ye(tr,Et)}});for(let Et=0,Gt=ye.length;Et{Ye(ye.get(Et.currentIndex),Et)})}static ngTemplateContextGuard(ne,ye){return!0}static \u0275fac=function(ye){return new(ye||U)(i.rXU(i.c1b),i.rXU(i.C4Q),i.rXU(i._q3))};static \u0275dir=i.FsC({type:U,selectors:[["","ngFor","","ngForOf",""]],inputs:{ngForOf:"ngForOf",ngForTrackBy:"ngForTrackBy",ngForTemplate:"ngForTemplate"}})}return U})();function Ye(U,Ie){U.context.$implicit=Ie.item}let gt=(()=>{class U{_viewContainer;_context=new Ht;_thenTemplateRef=null;_elseTemplateRef=null;_thenViewRef=null;_elseViewRef=null;constructor(ne,ye){this._viewContainer=ne,this._thenTemplateRef=ye}set ngIf(ne){this._context.$implicit=this._context.ngIf=ne,this._updateView()}set ngIfThen(ne){kt("ngIfThen",ne),this._thenTemplateRef=ne,this._thenViewRef=null,this._updateView()}set ngIfElse(ne){kt("ngIfElse",ne),this._elseTemplateRef=ne,this._elseViewRef=null,this._updateView()}_updateView(){this._context.$implicit?this._thenViewRef||(this._viewContainer.clear(),this._elseViewRef=null,this._thenTemplateRef&&(this._thenViewRef=this._viewContainer.createEmbeddedView(this._thenTemplateRef,this._context))):this._elseViewRef||(this._viewContainer.clear(),this._thenViewRef=null,this._elseTemplateRef&&(this._elseViewRef=this._viewContainer.createEmbeddedView(this._elseTemplateRef,this._context)))}static ngIfUseIfTypeGuard;static ngTemplateGuard_ngIf;static ngTemplateContextGuard(ne,ye){return!0}static \u0275fac=function(ye){return new(ye||U)(i.rXU(i.c1b),i.rXU(i.C4Q))};static \u0275dir=i.FsC({type:U,selectors:[["","ngIf",""]],inputs:{ngIf:"ngIf",ngIfThen:"ngIfThen",ngIfElse:"ngIfElse"}})}return U})();class Ht{$implicit=null;ngIf=null}function kt(U,Ie){if(Ie&&!Ie.createEmbeddedView)throw new Error(`${U} must be a TemplateRef, but received '${(0,i.Tbb)(Ie)}'.`)}let xr=(()=>{class U{_ngEl;_differs;_renderer;_ngStyle=null;_differ=null;constructor(ne,ye,Et){this._ngEl=ne,this._differs=ye,this._renderer=Et}set ngStyle(ne){this._ngStyle=ne,!this._differ&&ne&&(this._differ=this._differs.find(ne).create())}ngDoCheck(){if(this._differ){const ne=this._differ.diff(this._ngStyle);ne&&this._applyChanges(ne)}}_setStyle(ne,ye){const[Et,Gt]=ne.split("."),Un=-1===Et.indexOf("-")?void 0:i.czy.DashCase;null!=ye?this._renderer.setStyle(this._ngEl.nativeElement,Et,Gt?`${ye}${Gt}`:ye,Un):this._renderer.removeStyle(this._ngEl.nativeElement,Et,Un)}_applyChanges(ne){ne.forEachRemovedItem(ye=>this._setStyle(ye.key,null)),ne.forEachAddedItem(ye=>this._setStyle(ye.key,ye.currentValue)),ne.forEachChangedItem(ye=>this._setStyle(ye.key,ye.currentValue))}static \u0275fac=function(ye){return new(ye||U)(i.rXU(i.aKT),i.rXU(i.MKu),i.rXU(i.sFG))};static \u0275dir=i.FsC({type:U,selectors:[["","ngStyle",""]],inputs:{ngStyle:"ngStyle"}})}return U})(),gi=(()=>{class U{_viewContainerRef;_viewRef=null;ngTemplateOutletContext=null;ngTemplateOutlet=null;ngTemplateOutletInjector=null;constructor(ne){this._viewContainerRef=ne}ngOnChanges(ne){if(this._shouldRecreateView(ne)){const ye=this._viewContainerRef;if(this._viewRef&&ye.remove(ye.indexOf(this._viewRef)),!this.ngTemplateOutlet)return void(this._viewRef=null);const Et=this._createContextForwardProxy();this._viewRef=ye.createEmbeddedView(this.ngTemplateOutlet,Et,{injector:this.ngTemplateOutletInjector??void 0})}}_shouldRecreateView(ne){return!!ne.ngTemplateOutlet||!!ne.ngTemplateOutletInjector}_createContextForwardProxy(){return new Proxy({},{set:(ne,ye,Et)=>!!this.ngTemplateOutletContext&&Reflect.set(this.ngTemplateOutletContext,ye,Et),get:(ne,ye,Et)=>{if(this.ngTemplateOutletContext)return Reflect.get(this.ngTemplateOutletContext,ye,Et)}})}static \u0275fac=function(ye){return new(ye||U)(i.rXU(i.c1b))};static \u0275dir=i.FsC({type:U,selectors:[["","ngTemplateOutlet",""]],inputs:{ngTemplateOutletContext:"ngTemplateOutletContext",ngTemplateOutlet:"ngTemplateOutlet",ngTemplateOutletInjector:"ngTemplateOutletInjector"},features:[i.OA$]})}return U})();function Mi(U,Ie){return new i.wOt(2100,!1)}class Or{createSubscription(Ie,ne){return(0,i.O8t)(()=>Ie.subscribe({next:ne,error:ye=>{throw ye}}))}dispose(Ie){(0,i.O8t)(()=>Ie.unsubscribe())}}class Qr{createSubscription(Ie,ne){return Ie.then(ne,ye=>{throw ye})}dispose(Ie){}}const Pr=new Qr,Do=new Or;let es=(()=>{class U{_ref;_latestValue=null;markForCheckOnValueUpdate=!0;_subscription=null;_obj=null;_strategy=null;constructor(ne){this._ref=ne}ngOnDestroy(){this._subscription&&this._dispose(),this._ref=null}transform(ne){if(!this._obj){if(ne)try{this.markForCheckOnValueUpdate=!1,this._subscribe(ne)}finally{this.markForCheckOnValueUpdate=!0}return this._latestValue}return ne!==this._obj?(this._dispose(),this.transform(ne)):this._latestValue}_subscribe(ne){this._obj=ne,this._strategy=this._selectStrategy(ne),this._subscription=this._strategy.createSubscription(ne,ye=>this._updateLatestValue(ne,ye))}_selectStrategy(ne){if((0,i.jNT)(ne))return Pr;if((0,i.zjR)(ne))return Do;throw Mi()}_dispose(){this._strategy.dispose(this._subscription),this._latestValue=null,this._subscription=null,this._obj=null}_updateLatestValue(ne,ye){ne===this._obj&&(this._latestValue=ye,this.markForCheckOnValueUpdate&&this._ref?.markForCheck())}static \u0275fac=function(ye){return new(ye||U)(i.rXU(i.gRc,16))};static \u0275pipe=i.EJ8({name:"async",type:U,pure:!1})}return U})();const sa=/(?:[0-9A-Za-z\xAA\xB5\xBA\xC0-\xD6\xD8-\xF6\xF8-\u02C1\u02C6-\u02D1\u02E0-\u02E4\u02EC\u02EE\u0370-\u0374\u0376\u0377\u037A-\u037D\u037F\u0386\u0388-\u038A\u038C\u038E-\u03A1\u03A3-\u03F5\u03F7-\u0481\u048A-\u052F\u0531-\u0556\u0559\u0560-\u0588\u05D0-\u05EA\u05EF-\u05F2\u0620-\u064A\u066E\u066F\u0671-\u06D3\u06D5\u06E5\u06E6\u06EE\u06EF\u06FA-\u06FC\u06FF\u0710\u0712-\u072F\u074D-\u07A5\u07B1\u07CA-\u07EA\u07F4\u07F5\u07FA\u0800-\u0815\u081A\u0824\u0828\u0840-\u0858\u0860-\u086A\u0870-\u0887\u0889-\u088E\u08A0-\u08C9\u0904-\u0939\u093D\u0950\u0958-\u0961\u0971-\u0980\u0985-\u098C\u098F\u0990\u0993-\u09A8\u09AA-\u09B0\u09B2\u09B6-\u09B9\u09BD\u09CE\u09DC\u09DD\u09DF-\u09E1\u09F0\u09F1\u09FC\u0A05-\u0A0A\u0A0F\u0A10\u0A13-\u0A28\u0A2A-\u0A30\u0A32\u0A33\u0A35\u0A36\u0A38\u0A39\u0A59-\u0A5C\u0A5E\u0A72-\u0A74\u0A85-\u0A8D\u0A8F-\u0A91\u0A93-\u0AA8\u0AAA-\u0AB0\u0AB2\u0AB3\u0AB5-\u0AB9\u0ABD\u0AD0\u0AE0\u0AE1\u0AF9\u0B05-\u0B0C\u0B0F\u0B10\u0B13-\u0B28\u0B2A-\u0B30\u0B32\u0B33\u0B35-\u0B39\u0B3D\u0B5C\u0B5D\u0B5F-\u0B61\u0B71\u0B83\u0B85-\u0B8A\u0B8E-\u0B90\u0B92-\u0B95\u0B99\u0B9A\u0B9C\u0B9E\u0B9F\u0BA3\u0BA4\u0BA8-\u0BAA\u0BAE-\u0BB9\u0BD0\u0C05-\u0C0C\u0C0E-\u0C10\u0C12-\u0C28\u0C2A-\u0C39\u0C3D\u0C58-\u0C5A\u0C5D\u0C60\u0C61\u0C80\u0C85-\u0C8C\u0C8E-\u0C90\u0C92-\u0CA8\u0CAA-\u0CB3\u0CB5-\u0CB9\u0CBD\u0CDD\u0CDE\u0CE0\u0CE1\u0CF1\u0CF2\u0D04-\u0D0C\u0D0E-\u0D10\u0D12-\u0D3A\u0D3D\u0D4E\u0D54-\u0D56\u0D5F-\u0D61\u0D7A-\u0D7F\u0D85-\u0D96\u0D9A-\u0DB1\u0DB3-\u0DBB\u0DBD\u0DC0-\u0DC6\u0E01-\u0E30\u0E32\u0E33\u0E40-\u0E46\u0E81\u0E82\u0E84\u0E86-\u0E8A\u0E8C-\u0EA3\u0EA5\u0EA7-\u0EB0\u0EB2\u0EB3\u0EBD\u0EC0-\u0EC4\u0EC6\u0EDC-\u0EDF\u0F00\u0F40-\u0F47\u0F49-\u0F6C\u0F88-\u0F8C\u1000-\u102A\u103F\u1050-\u1055\u105A-\u105D\u1061\u1065\u1066\u106E-\u1070\u1075-\u1081\u108E\u10A0-\u10C5\u10C7\u10CD\u10D0-\u10FA\u10FC-\u1248\u124A-\u124D\u1250-\u1256\u1258\u125A-\u125D\u1260-\u1288\u128A-\u128D\u1290-\u12B0\u12B2-\u12B5\u12B8-\u12BE\u12C0\u12C2-\u12C5\u12C8-\u12D6\u12D8-\u1310\u1312-\u1315\u1318-\u135A\u1380-\u138F\u13A0-\u13F5\u13F8-\u13FD\u1401-\u166C\u166F-\u167F\u1681-\u169A\u16A0-\u16EA\u16F1-\u16F8\u1700-\u1711\u171F-\u1731\u1740-\u1751\u1760-\u176C\u176E-\u1770\u1780-\u17B3\u17D7\u17DC\u1820-\u1878\u1880-\u1884\u1887-\u18A8\u18AA\u18B0-\u18F5\u1900-\u191E\u1950-\u196D\u1970-\u1974\u1980-\u19AB\u19B0-\u19C9\u1A00-\u1A16\u1A20-\u1A54\u1AA7\u1B05-\u1B33\u1B45-\u1B4C\u1B83-\u1BA0\u1BAE\u1BAF\u1BBA-\u1BE5\u1C00-\u1C23\u1C4D-\u1C4F\u1C5A-\u1C7D\u1C80-\u1C88\u1C90-\u1CBA\u1CBD-\u1CBF\u1CE9-\u1CEC\u1CEE-\u1CF3\u1CF5\u1CF6\u1CFA\u1D00-\u1DBF\u1E00-\u1F15\u1F18-\u1F1D\u1F20-\u1F45\u1F48-\u1F4D\u1F50-\u1F57\u1F59\u1F5B\u1F5D\u1F5F-\u1F7D\u1F80-\u1FB4\u1FB6-\u1FBC\u1FBE\u1FC2-\u1FC4\u1FC6-\u1FCC\u1FD0-\u1FD3\u1FD6-\u1FDB\u1FE0-\u1FEC\u1FF2-\u1FF4\u1FF6-\u1FFC\u2071\u207F\u2090-\u209C\u2102\u2107\u210A-\u2113\u2115\u2119-\u211D\u2124\u2126\u2128\u212A-\u212D\u212F-\u2139\u213C-\u213F\u2145-\u2149\u214E\u2183\u2184\u2C00-\u2CE4\u2CEB-\u2CEE\u2CF2\u2CF3\u2D00-\u2D25\u2D27\u2D2D\u2D30-\u2D67\u2D6F\u2D80-\u2D96\u2DA0-\u2DA6\u2DA8-\u2DAE\u2DB0-\u2DB6\u2DB8-\u2DBE\u2DC0-\u2DC6\u2DC8-\u2DCE\u2DD0-\u2DD6\u2DD8-\u2DDE\u2E2F\u3005\u3006\u3031-\u3035\u303B\u303C\u3041-\u3096\u309D-\u309F\u30A1-\u30FA\u30FC-\u30FF\u3105-\u312F\u3131-\u318E\u31A0-\u31BF\u31F0-\u31FF\u3400-\u4DBF\u4E00-\uA48C\uA4D0-\uA4FD\uA500-\uA60C\uA610-\uA61F\uA62A\uA62B\uA640-\uA66E\uA67F-\uA69D\uA6A0-\uA6E5\uA717-\uA71F\uA722-\uA788\uA78B-\uA7CA\uA7D0\uA7D1\uA7D3\uA7D5-\uA7D9\uA7F2-\uA801\uA803-\uA805\uA807-\uA80A\uA80C-\uA822\uA840-\uA873\uA882-\uA8B3\uA8F2-\uA8F7\uA8FB\uA8FD\uA8FE\uA90A-\uA925\uA930-\uA946\uA960-\uA97C\uA984-\uA9B2\uA9CF\uA9E0-\uA9E4\uA9E6-\uA9EF\uA9FA-\uA9FE\uAA00-\uAA28\uAA40-\uAA42\uAA44-\uAA4B\uAA60-\uAA76\uAA7A\uAA7E-\uAAAF\uAAB1\uAAB5\uAAB6\uAAB9-\uAABD\uAAC0\uAAC2\uAADB-\uAADD\uAAE0-\uAAEA\uAAF2-\uAAF4\uAB01-\uAB06\uAB09-\uAB0E\uAB11-\uAB16\uAB20-\uAB26\uAB28-\uAB2E\uAB30-\uAB5A\uAB5C-\uAB69\uAB70-\uABE2\uAC00-\uD7A3\uD7B0-\uD7C6\uD7CB-\uD7FB\uF900-\uFA6D\uFA70-\uFAD9\uFB00-\uFB06\uFB13-\uFB17\uFB1D\uFB1F-\uFB28\uFB2A-\uFB36\uFB38-\uFB3C\uFB3E\uFB40\uFB41\uFB43\uFB44\uFB46-\uFBB1\uFBD3-\uFD3D\uFD50-\uFD8F\uFD92-\uFDC7\uFDF0-\uFDFB\uFE70-\uFE74\uFE76-\uFEFC\uFF21-\uFF3A\uFF41-\uFF5A\uFF66-\uFFBE\uFFC2-\uFFC7\uFFCA-\uFFCF\uFFD2-\uFFD7\uFFDA-\uFFDC]|\uD800[\uDC00-\uDC0B\uDC0D-\uDC26\uDC28-\uDC3A\uDC3C\uDC3D\uDC3F-\uDC4D\uDC50-\uDC5D\uDC80-\uDCFA\uDE80-\uDE9C\uDEA0-\uDED0\uDF00-\uDF1F\uDF2D-\uDF40\uDF42-\uDF49\uDF50-\uDF75\uDF80-\uDF9D\uDFA0-\uDFC3\uDFC8-\uDFCF]|\uD801[\uDC00-\uDC9D\uDCB0-\uDCD3\uDCD8-\uDCFB\uDD00-\uDD27\uDD30-\uDD63\uDD70-\uDD7A\uDD7C-\uDD8A\uDD8C-\uDD92\uDD94\uDD95\uDD97-\uDDA1\uDDA3-\uDDB1\uDDB3-\uDDB9\uDDBB\uDDBC\uDE00-\uDF36\uDF40-\uDF55\uDF60-\uDF67\uDF80-\uDF85\uDF87-\uDFB0\uDFB2-\uDFBA]|\uD802[\uDC00-\uDC05\uDC08\uDC0A-\uDC35\uDC37\uDC38\uDC3C\uDC3F-\uDC55\uDC60-\uDC76\uDC80-\uDC9E\uDCE0-\uDCF2\uDCF4\uDCF5\uDD00-\uDD15\uDD20-\uDD39\uDD80-\uDDB7\uDDBE\uDDBF\uDE00\uDE10-\uDE13\uDE15-\uDE17\uDE19-\uDE35\uDE60-\uDE7C\uDE80-\uDE9C\uDEC0-\uDEC7\uDEC9-\uDEE4\uDF00-\uDF35\uDF40-\uDF55\uDF60-\uDF72\uDF80-\uDF91]|\uD803[\uDC00-\uDC48\uDC80-\uDCB2\uDCC0-\uDCF2\uDD00-\uDD23\uDE80-\uDEA9\uDEB0\uDEB1\uDF00-\uDF1C\uDF27\uDF30-\uDF45\uDF70-\uDF81\uDFB0-\uDFC4\uDFE0-\uDFF6]|\uD804[\uDC03-\uDC37\uDC71\uDC72\uDC75\uDC83-\uDCAF\uDCD0-\uDCE8\uDD03-\uDD26\uDD44\uDD47\uDD50-\uDD72\uDD76\uDD83-\uDDB2\uDDC1-\uDDC4\uDDDA\uDDDC\uDE00-\uDE11\uDE13-\uDE2B\uDE80-\uDE86\uDE88\uDE8A-\uDE8D\uDE8F-\uDE9D\uDE9F-\uDEA8\uDEB0-\uDEDE\uDF05-\uDF0C\uDF0F\uDF10\uDF13-\uDF28\uDF2A-\uDF30\uDF32\uDF33\uDF35-\uDF39\uDF3D\uDF50\uDF5D-\uDF61]|\uD805[\uDC00-\uDC34\uDC47-\uDC4A\uDC5F-\uDC61\uDC80-\uDCAF\uDCC4\uDCC5\uDCC7\uDD80-\uDDAE\uDDD8-\uDDDB\uDE00-\uDE2F\uDE44\uDE80-\uDEAA\uDEB8\uDF00-\uDF1A\uDF40-\uDF46]|\uD806[\uDC00-\uDC2B\uDCA0-\uDCDF\uDCFF-\uDD06\uDD09\uDD0C-\uDD13\uDD15\uDD16\uDD18-\uDD2F\uDD3F\uDD41\uDDA0-\uDDA7\uDDAA-\uDDD0\uDDE1\uDDE3\uDE00\uDE0B-\uDE32\uDE3A\uDE50\uDE5C-\uDE89\uDE9D\uDEB0-\uDEF8]|\uD807[\uDC00-\uDC08\uDC0A-\uDC2E\uDC40\uDC72-\uDC8F\uDD00-\uDD06\uDD08\uDD09\uDD0B-\uDD30\uDD46\uDD60-\uDD65\uDD67\uDD68\uDD6A-\uDD89\uDD98\uDEE0-\uDEF2\uDFB0]|\uD808[\uDC00-\uDF99]|\uD809[\uDC80-\uDD43]|\uD80B[\uDF90-\uDFF0]|[\uD80C\uD81C-\uD820\uD822\uD840-\uD868\uD86A-\uD86C\uD86F-\uD872\uD874-\uD879\uD880-\uD883][\uDC00-\uDFFF]|\uD80D[\uDC00-\uDC2E]|\uD811[\uDC00-\uDE46]|\uD81A[\uDC00-\uDE38\uDE40-\uDE5E\uDE70-\uDEBE\uDED0-\uDEED\uDF00-\uDF2F\uDF40-\uDF43\uDF63-\uDF77\uDF7D-\uDF8F]|\uD81B[\uDE40-\uDE7F\uDF00-\uDF4A\uDF50\uDF93-\uDF9F\uDFE0\uDFE1\uDFE3]|\uD821[\uDC00-\uDFF7]|\uD823[\uDC00-\uDCD5\uDD00-\uDD08]|\uD82B[\uDFF0-\uDFF3\uDFF5-\uDFFB\uDFFD\uDFFE]|\uD82C[\uDC00-\uDD22\uDD50-\uDD52\uDD64-\uDD67\uDD70-\uDEFB]|\uD82F[\uDC00-\uDC6A\uDC70-\uDC7C\uDC80-\uDC88\uDC90-\uDC99]|\uD835[\uDC00-\uDC54\uDC56-\uDC9C\uDC9E\uDC9F\uDCA2\uDCA5\uDCA6\uDCA9-\uDCAC\uDCAE-\uDCB9\uDCBB\uDCBD-\uDCC3\uDCC5-\uDD05\uDD07-\uDD0A\uDD0D-\uDD14\uDD16-\uDD1C\uDD1E-\uDD39\uDD3B-\uDD3E\uDD40-\uDD44\uDD46\uDD4A-\uDD50\uDD52-\uDEA5\uDEA8-\uDEC0\uDEC2-\uDEDA\uDEDC-\uDEFA\uDEFC-\uDF14\uDF16-\uDF34\uDF36-\uDF4E\uDF50-\uDF6E\uDF70-\uDF88\uDF8A-\uDFA8\uDFAA-\uDFC2\uDFC4-\uDFCB]|\uD837[\uDF00-\uDF1E]|\uD838[\uDD00-\uDD2C\uDD37-\uDD3D\uDD4E\uDE90-\uDEAD\uDEC0-\uDEEB]|\uD839[\uDFE0-\uDFE6\uDFE8-\uDFEB\uDFED\uDFEE\uDFF0-\uDFFE]|\uD83A[\uDC00-\uDCC4\uDD00-\uDD43\uDD4B]|\uD83B[\uDE00-\uDE03\uDE05-\uDE1F\uDE21\uDE22\uDE24\uDE27\uDE29-\uDE32\uDE34-\uDE37\uDE39\uDE3B\uDE42\uDE47\uDE49\uDE4B\uDE4D-\uDE4F\uDE51\uDE52\uDE54\uDE57\uDE59\uDE5B\uDE5D\uDE5F\uDE61\uDE62\uDE64\uDE67-\uDE6A\uDE6C-\uDE72\uDE74-\uDE77\uDE79-\uDE7C\uDE7E\uDE80-\uDE89\uDE8B-\uDE9B\uDEA1-\uDEA3\uDEA5-\uDEA9\uDEAB-\uDEBB]|\uD869[\uDC00-\uDEDF\uDF00-\uDFFF]|\uD86D[\uDC00-\uDF38\uDF40-\uDFFF]|\uD86E[\uDC00-\uDC1D\uDC20-\uDFFF]|\uD873[\uDC00-\uDEA1\uDEB0-\uDFFF]|\uD87A[\uDC00-\uDFE0]|\uD87E[\uDC00-\uDE1D]|\uD884[\uDC00-\uDF4A])\S*/g;let Li=(()=>{class U{transform(ne){if(null==ne)return null;if("string"!=typeof ne)throw Mi();return ne.replace(sa,ye=>ye[0].toUpperCase()+ye.slice(1).toLowerCase())}static \u0275fac=function(ye){return new(ye||U)};static \u0275pipe=i.EJ8({name:"titlecase",type:U,pure:!0})}return U})();const Ks=new i.nKC(""),Oo=new i.nKC("");let Cs=(()=>{class U{locale;defaultTimezone;defaultOptions;constructor(ne,ye,Et){this.locale=ne,this.defaultTimezone=ye,this.defaultOptions=Et}transform(ne,ye,Et,Gt){if(null==ne||""===ne||ne!=ne)return null;try{return z(ne,ye??this.defaultOptions?.dateFormat??"mediumDate",Gt||this.locale,Et??this.defaultOptions?.timezone??this.defaultTimezone??void 0)}catch(Un){throw Mi()}}static \u0275fac=function(ye){return new(ye||U)(i.rXU(i.xe9,16),i.rXU(Ks,24),i.rXU(Oo,24))};static \u0275pipe=i.EJ8({name:"date",type:U,pure:!0})}return U})();const No=/#/g;let hs=(()=>{class U{_localization;constructor(ne){this._localization=ne}transform(ne,ye,Et){if(null==ne)return"";if("object"!=typeof ye||null===ye)throw Mi();return ye[function Jo(U,Ie,ne,ye){let Et=`=${U}`;if(Ie.indexOf(Et)>-1||(Et=ne.getPluralCategory(U,ye),Ie.indexOf(Et)>-1))return Et;if(Ie.indexOf("other")>-1)return"other";throw new Error(`No plural message found for value "${U}"`)}(ne,Object.keys(ye),this._localization,Et)].replace(No,ne.toString())}static \u0275fac=function(ye){return new(ye||U)(i.rXU(fo,16))};static \u0275pipe=i.EJ8({name:"i18nPlural",type:U,pure:!0})}return U})(),Ao=(()=>{class U{static \u0275fac=function(ye){return new(ye||U)};static \u0275mod=i.$C({type:U});static \u0275inj=i.G2t({})}return U})();const lr="browser",As="server";function Gs(U){return U===lr}function _s(U){return U===As}let ls=(()=>{class U{static \u0275prov=(0,i.jDH)({token:U,providedIn:"root",factory:()=>Gs((0,i.WQX)(i.Agw))?new Vi((0,i.WQX)(S),window):new ca})}return U})();class Vi{document;window;offset=()=>[0,0];constructor(Ie,ne){this.document=Ie,this.window=ne}setOffset(Ie){this.offset=Array.isArray(Ie)?()=>Ie:Ie}getScrollPosition(){return[this.window.scrollX,this.window.scrollY]}scrollToPosition(Ie){this.window.scrollTo(Ie[0],Ie[1])}scrollToAnchor(Ie){const ne=function ll(U,Ie){const ne=U.getElementById(Ie)||U.getElementsByName(Ie)[0];if(ne)return ne;if("function"==typeof U.createTreeWalker&&U.body&&"function"==typeof U.body.attachShadow){const ye=U.createTreeWalker(U.body,NodeFilter.SHOW_ELEMENT);let Et=ye.currentNode;for(;Et;){const Gt=Et.shadowRoot;if(Gt){const Un=Gt.getElementById(Ie)||Gt.querySelector(`[name="${Ie}"]`);if(Un)return Un}Et=ye.nextNode()}}return null}(this.document,Ie);ne&&(this.scrollToElement(ne),ne.focus())}setHistoryScrollRestoration(Ie){this.window.history.scrollRestoration=Ie}scrollToElement(Ie){const ne=Ie.getBoundingClientRect(),ye=ne.left+this.window.pageXOffset,Et=ne.top+this.window.pageYOffset,Gt=this.offset();this.window.scrollTo(ye-Gt[0],Et-Gt[1])}}class ca{setOffset(Ie){}getScrollPosition(){return[0,0]}scrollToPosition(Ie){}scrollToAnchor(Ie){}setHistoryScrollRestoration(Ie){}}class Ss{}},7691:(o,s,r)=>{"use strict";r.d(s,{$R:()=>Ve,Nl:()=>De,Qq:()=>Ft,b$:()=>Dt,cS:()=>Vn,yz:()=>yn});var i=r(3014),a=r(3107),c=r(3016),y=r(1698),w=r(1787),C=r(1459),T=r(1483),S=r(7947),M=r(4447),O=r(2867),L=r(4460);class Z{}class q{}class re{headers;normalizedNames=new Map;lazyInit;lazyUpdate=null;constructor(xt){xt?"string"==typeof xt?this.lazyInit=()=>{this.headers=new Map,xt.split("\n").forEach(ht=>{const ve=ht.indexOf(":");if(ve>0){const Ye=ht.slice(0,ve),Ne=ht.slice(ve+1).trim();this.addHeaderEntry(Ye,Ne)}})}:typeof Headers<"u"&&xt instanceof Headers?(this.headers=new Map,xt.forEach((ht,ve)=>{this.addHeaderEntry(ve,ht)})):this.lazyInit=()=>{this.headers=new Map,Object.entries(xt).forEach(([ht,ve])=>{this.setHeaderEntries(ht,ve)})}:this.headers=new Map}has(xt){return this.init(),this.headers.has(xt.toLowerCase())}get(xt){this.init();const ht=this.headers.get(xt.toLowerCase());return ht&&ht.length>0?ht[0]:null}keys(){return this.init(),Array.from(this.normalizedNames.values())}getAll(xt){return this.init(),this.headers.get(xt.toLowerCase())||null}append(xt,ht){return this.clone({name:xt,value:ht,op:"a"})}set(xt,ht){return this.clone({name:xt,value:ht,op:"s"})}delete(xt,ht){return this.clone({name:xt,value:ht,op:"d"})}maybeSetNormalizedName(xt,ht){this.normalizedNames.has(ht)||this.normalizedNames.set(ht,xt)}init(){this.lazyInit&&(this.lazyInit instanceof re?this.copyFrom(this.lazyInit):this.lazyInit(),this.lazyInit=null,this.lazyUpdate&&(this.lazyUpdate.forEach(xt=>this.applyUpdate(xt)),this.lazyUpdate=null))}copyFrom(xt){xt.init(),Array.from(xt.headers.keys()).forEach(ht=>{this.headers.set(ht,xt.headers.get(ht)),this.normalizedNames.set(ht,xt.normalizedNames.get(ht))})}clone(xt){const ht=new re;return ht.lazyInit=this.lazyInit&&this.lazyInit instanceof re?this.lazyInit:this,ht.lazyUpdate=(this.lazyUpdate||[]).concat([xt]),ht}applyUpdate(xt){const ht=xt.name.toLowerCase();switch(xt.op){case"a":case"s":let ve=xt.value;if("string"==typeof ve&&(ve=[ve]),0===ve.length)return;this.maybeSetNormalizedName(xt.name,ht);const Ye=("a"===xt.op?this.headers.get(ht):void 0)||[];Ye.push(...ve),this.headers.set(ht,Ye);break;case"d":const Ne=xt.value;if(Ne){let gt=this.headers.get(ht);if(!gt)return;gt=gt.filter(Ht=>-1===Ne.indexOf(Ht)),0===gt.length?(this.headers.delete(ht),this.normalizedNames.delete(ht)):this.headers.set(ht,gt)}else this.headers.delete(ht),this.normalizedNames.delete(ht)}}addHeaderEntry(xt,ht){const ve=xt.toLowerCase();this.maybeSetNormalizedName(xt,ve),this.headers.has(ve)?this.headers.get(ve).push(ht):this.headers.set(ve,[ht])}setHeaderEntries(xt,ht){const ve=(Array.isArray(ht)?ht:[ht]).map(Ne=>Ne.toString()),Ye=xt.toLowerCase();this.headers.set(Ye,ve),this.maybeSetNormalizedName(xt,Ye)}forEach(xt){this.init(),Array.from(this.normalizedNames.keys()).forEach(ht=>xt(this.normalizedNames.get(ht),this.headers.get(ht)))}}class se{encodeKey(xt){return Oe(xt)}encodeValue(xt){return Oe(xt)}decodeKey(xt){return decodeURIComponent(xt)}decodeValue(xt){return decodeURIComponent(xt)}}const me=/%(\d[a-f0-9])/gi,be={40:"@","3A":":",24:"$","2C":",","3B":";","3D":"=","3F":"?","2F":"/"};function Oe(tt){return encodeURIComponent(tt).replace(me,(xt,ht)=>be[ht]??xt)}function xe(tt){return`${tt}`}class De{map;encoder;updates=null;cloneFrom=null;constructor(xt={}){if(this.encoder=xt.encoder||new se,xt.fromString){if(xt.fromObject)throw new Error("Cannot specify both fromString and fromObject.");this.map=function ae(tt,xt){const ht=new Map;return tt.length>0&&tt.replace(/^\?/,"").split("&").forEach(Ye=>{const Ne=Ye.indexOf("="),[gt,Ht]=-1==Ne?[xt.decodeKey(Ye),""]:[xt.decodeKey(Ye.slice(0,Ne)),xt.decodeValue(Ye.slice(Ne+1))],kt=ht.get(gt)||[];kt.push(Ht),ht.set(gt,kt)}),ht}(xt.fromString,this.encoder)}else xt.fromObject?(this.map=new Map,Object.keys(xt.fromObject).forEach(ht=>{const ve=xt.fromObject[ht],Ye=Array.isArray(ve)?ve.map(xe):[xe(ve)];this.map.set(ht,Ye)})):this.map=null}has(xt){return this.init(),this.map.has(xt)}get(xt){this.init();const ht=this.map.get(xt);return ht?ht[0]:null}getAll(xt){return this.init(),this.map.get(xt)||null}keys(){return this.init(),Array.from(this.map.keys())}append(xt,ht){return this.clone({param:xt,value:ht,op:"a"})}appendAll(xt){const ht=[];return Object.keys(xt).forEach(ve=>{const Ye=xt[ve];Array.isArray(Ye)?Ye.forEach(Ne=>{ht.push({param:ve,value:Ne,op:"a"})}):ht.push({param:ve,value:Ye,op:"a"})}),this.clone(ht)}set(xt,ht){return this.clone({param:xt,value:ht,op:"s"})}delete(xt,ht){return this.clone({param:xt,value:ht,op:"d"})}toString(){return this.init(),this.keys().map(xt=>{const ht=this.encoder.encodeKey(xt);return this.map.get(xt).map(ve=>ht+"="+this.encoder.encodeValue(ve)).join("&")}).filter(xt=>""!==xt).join("&")}clone(xt){const ht=new De({encoder:this.encoder});return ht.cloneFrom=this.cloneFrom||this,ht.updates=(this.updates||[]).concat(xt),ht}init(){null===this.map&&(this.map=new Map),null!==this.cloneFrom&&(this.cloneFrom.init(),this.cloneFrom.keys().forEach(xt=>this.map.set(xt,this.cloneFrom.map.get(xt))),this.updates.forEach(xt=>{switch(xt.op){case"a":case"s":const ht=("a"===xt.op?this.map.get(xt.param):void 0)||[];ht.push(xe(xt.value)),this.map.set(xt.param,ht);break;case"d":if(void 0===xt.value){this.map.delete(xt.param);break}{let ve=this.map.get(xt.param)||[];const Ye=ve.indexOf(xe(xt.value));-1!==Ye&&ve.splice(Ye,1),ve.length>0?this.map.set(xt.param,ve):this.map.delete(xt.param)}}}),this.cloneFrom=this.updates=null)}}class ue{map=new Map;set(xt,ht){return this.map.set(xt,ht),this}get(xt){return this.map.has(xt)||this.map.set(xt,xt.defaultValue()),this.map.get(xt)}delete(xt){return this.map.delete(xt),this}has(xt){return this.map.has(xt)}keys(){return this.map.keys()}}function Be(tt){return typeof ArrayBuffer<"u"&&tt instanceof ArrayBuffer}function at(tt){return typeof Blob<"u"&&tt instanceof Blob}function dt(tt){return typeof FormData<"u"&&tt instanceof FormData}class lt{url;body=null;headers;context;reportProgress=!1;withCredentials=!1;responseType="json";method;params;urlWithParams;transferCache;constructor(xt,ht,ve,Ye){let Ne;if(this.url=ht,this.method=xt.toUpperCase(),function Ce(tt){switch(tt){case"DELETE":case"GET":case"HEAD":case"OPTIONS":case"JSONP":return!1;default:return!0}}(this.method)||Ye?(this.body=void 0!==ve?ve:null,Ne=Ye):Ne=ve,Ne&&(this.reportProgress=!!Ne.reportProgress,this.withCredentials=!!Ne.withCredentials,Ne.responseType&&(this.responseType=Ne.responseType),Ne.headers&&(this.headers=Ne.headers),Ne.context&&(this.context=Ne.context),Ne.params&&(this.params=Ne.params),this.transferCache=Ne.transferCache),this.headers??=new re,this.context??=new ue,this.params){const gt=this.params.toString();if(0===gt.length)this.urlWithParams=ht;else{const Ht=ht.indexOf("?");this.urlWithParams=ht+(-1===Ht?"?":HtNn.set(jn,xt.setHeaders[jn]),hn)),xt.setParams&&(Dn=Object.keys(xt.setParams).reduce((Nn,jn)=>Nn.set(jn,xt.setParams[jn]),Dn)),new lt(ht,ve,gt,{params:Dn,headers:hn,context:Cn,reportProgress:kt,responseType:Ye,withCredentials:Ht,transferCache:Ne})}}var rn=function(tt){return tt[tt.Sent=0]="Sent",tt[tt.UploadProgress=1]="UploadProgress",tt[tt.ResponseHeader=2]="ResponseHeader",tt[tt.DownloadProgress=3]="DownloadProgress",tt[tt.Response=4]="Response",tt[tt.User=5]="User",tt}(rn||{});class gn{headers;status;statusText;url;ok;type;constructor(xt,ht=200,ve="OK"){this.headers=xt.headers||new re,this.status=void 0!==xt.status?xt.status:ht,this.statusText=xt.statusText||ve,this.url=xt.url||null,this.ok=this.status>=200&&this.status<300}}class bn extends gn{constructor(xt={}){super(xt)}type=rn.ResponseHeader;clone(xt={}){return new bn({headers:xt.headers||this.headers,status:void 0!==xt.status?xt.status:this.status,statusText:xt.statusText||this.statusText,url:xt.url||this.url||void 0})}}class Vn extends gn{body;constructor(xt={}){super(xt),this.body=void 0!==xt.body?xt.body:null}type=rn.Response;clone(xt={}){return new Vn({body:void 0!==xt.body?xt.body:this.body,headers:xt.headers||this.headers,status:void 0!==xt.status?xt.status:this.status,statusText:xt.statusText||this.statusText,url:xt.url||this.url||void 0})}}class yn extends gn{name="HttpErrorResponse";message;error;ok=!1;constructor(xt){super(xt,0,"Unknown Error"),this.message=this.status>=200&&this.status<300?`Http failure during parsing for ${xt.url||"(unknown url)"}`:`Http failure response for ${xt.url||"(unknown url)"}: ${xt.status} ${xt.statusText}`,this.error=xt.error||null}}function $e(tt,xt){return{body:xt,headers:tt.headers,context:tt.context,observe:tt.observe,params:tt.params,reportProgress:tt.reportProgress,responseType:tt.responseType,withCredentials:tt.withCredentials,transferCache:tt.transferCache}}let Ft=(()=>{class tt{handler;constructor(ht){this.handler=ht}request(ht,ve,Ye={}){let Ne;if(ht instanceof lt)Ne=ht;else{let kt,hn;kt=Ye.headers instanceof re?Ye.headers:new re(Ye.headers),Ye.params&&(hn=Ye.params instanceof De?Ye.params:new De({fromObject:Ye.params})),Ne=new lt(ht,ve,void 0!==Ye.body?Ye.body:null,{headers:kt,context:Ye.context,params:hn,reportProgress:Ye.reportProgress,responseType:Ye.responseType||"json",withCredentials:Ye.withCredentials,transferCache:Ye.transferCache})}const gt=(0,c.of)(Ne).pipe((0,C.H)(kt=>this.handler.handle(kt)));if(ht instanceof lt||"events"===Ye.observe)return gt;const Ht=gt.pipe((0,T.p)(kt=>kt instanceof Vn));switch(Ye.observe||"body"){case"body":switch(Ne.responseType){case"arraybuffer":return Ht.pipe((0,S.T)(kt=>{if(null!==kt.body&&!(kt.body instanceof ArrayBuffer))throw new Error("Response is not an ArrayBuffer.");return kt.body}));case"blob":return Ht.pipe((0,S.T)(kt=>{if(null!==kt.body&&!(kt.body instanceof Blob))throw new Error("Response is not a Blob.");return kt.body}));case"text":return Ht.pipe((0,S.T)(kt=>{if(null!==kt.body&&"string"!=typeof kt.body)throw new Error("Response is not a string.");return kt.body}));default:return Ht.pipe((0,S.T)(kt=>kt.body))}case"response":return Ht;default:throw new Error(`Unreachable: unhandled observe type ${Ye.observe}}`)}}delete(ht,ve={}){return this.request("DELETE",ht,ve)}get(ht,ve={}){return this.request("GET",ht,ve)}head(ht,ve={}){return this.request("HEAD",ht,ve)}jsonp(ht,ve){return this.request("JSONP",ht,{params:(new De).append(ve,"JSONP_CALLBACK"),observe:"body",responseType:"json"})}options(ht,ve={}){return this.request("OPTIONS",ht,ve)}patch(ht,ve,Ye={}){return this.request("PATCH",ht,$e(Ye,ve))}post(ht,ve,Ye={}){return this.request("POST",ht,$e(Ye,ve))}put(ht,ve,Ye={}){return this.request("PUT",ht,$e(Ye,ve))}static \u0275fac=function(ve){return new(ve||tt)(a.KVO(Z))};static \u0275prov=a.jDH({token:tt,factory:tt.\u0275fac})}return tt})();const Ke=/^\)\]\}',?\n/;function it(tt){if(tt.url)return tt.url;const xt="X-Request-URL".toLocaleLowerCase();return tt.headers.get(xt)}let Ot=(()=>{class tt{fetchImpl=(0,a.WQX)($t,{optional:!0})?.fetch??((...ht)=>globalThis.fetch(...ht));ngZone=(0,a.WQX)(a.SKi);handle(ht){return new y.c(ve=>{const Ye=new AbortController;return this.doRequest(ht,Ye.signal,ve).then(Te,Ne=>ve.error(new yn({error:Ne}))),()=>Ye.abort()})}doRequest(ht,ve,Ye){var Ne=this;return(0,i.A)(function*(){const gt=Ne.createRequestInit(ht);let Ht;try{const Jn=Ne.ngZone.runOutsideAngular(()=>Ne.fetchImpl(ht.urlWithParams,{signal:ve,...gt}));(function Ee(tt){tt.then(Te,Te)})(Jn),Ye.next({type:rn.Sent}),Ht=yield Jn}catch(Jn){return void Ye.error(new yn({error:Jn,status:Jn.status??0,statusText:Jn.statusText,url:ht.urlWithParams,headers:Jn.headers}))}const kt=new re(Ht.headers),hn=Ht.statusText,Dn=it(Ht)??ht.urlWithParams;let Cn=Ht.status,Nn=null;if(ht.reportProgress&&Ye.next(new bn({headers:kt,status:Cn,statusText:hn,url:Dn})),Ht.body){const Jn=Ht.headers.get("content-length"),ar=[],wr=Ht.body.getReader();let gi,ni,xr=0;const Mi=typeof Zone<"u"&&Zone.current;yield Ne.ngZone.runOutsideAngular((0,i.A)(function*(){for(;;){const{done:Qr,value:Pr}=yield wr.read();if(Qr)break;if(ar.push(Pr),xr+=Pr.length,ht.reportProgress){ni="text"===ht.responseType?(ni??"")+(gi??=new TextDecoder).decode(Pr,{stream:!0}):void 0;const Do=()=>Ye.next({type:rn.DownloadProgress,total:Jn?+Jn:void 0,loaded:xr,partialText:ni});Mi?Mi.run(Do):Do()}}}));const Or=Ne.concatChunks(ar,xr);try{const Qr=Ht.headers.get("Content-Type")??"";Nn=Ne.parseBody(ht,Or,Qr)}catch(Qr){return void Ye.error(new yn({error:Qr,headers:new re(Ht.headers),status:Ht.status,statusText:Ht.statusText,url:it(Ht)??ht.urlWithParams}))}}0===Cn&&(Cn=Nn?200:0),Cn>=200&&Cn<300?(Ye.next(new Vn({body:Nn,headers:kt,status:Cn,statusText:hn,url:Dn})),Ye.complete()):Ye.error(new yn({error:Nn,headers:kt,status:Cn,statusText:hn,url:Dn}))})()}parseBody(ht,ve,Ye){switch(ht.responseType){case"json":const Ne=(new TextDecoder).decode(ve).replace(Ke,"");return""===Ne?null:JSON.parse(Ne);case"text":return(new TextDecoder).decode(ve);case"blob":return new Blob([ve],{type:Ye});case"arraybuffer":return ve.buffer}}createRequestInit(ht){const ve={},Ye=ht.withCredentials?"include":void 0;if(ht.headers.forEach((Ne,gt)=>ve[Ne]=gt.join(",")),ht.headers.has("Accept")||(ve.Accept="application/json, text/plain, */*"),!ht.headers.has("Content-Type")){const Ne=ht.detectContentTypeHeader();null!==Ne&&(ve["Content-Type"]=Ne)}return{body:ht.serializeBody(),method:ht.method,headers:ve,credentials:Ye}}concatChunks(ht,ve){const Ye=new Uint8Array(ve);let Ne=0;for(const gt of ht)Ye.set(gt,Ne),Ne+=gt.length;return Ye}static \u0275fac=function(ve){return new(ve||tt)};static \u0275prov=a.jDH({token:tt,factory:tt.\u0275fac})}return tt})();class $t{}function Te(){}function st(tt,xt){return xt(tt)}const rt=new a.nKC(""),Vt=new a.nKC(""),en=new a.nKC("",{providedIn:"root",factory:()=>!0});let Rn=(()=>{class tt extends Z{backend;injector;chain=null;pendingTasks=(0,a.WQX)(a.TgB);contributeToStability=(0,a.WQX)(en);constructor(ht,ve){super(),this.backend=ht,this.injector=ve}handle(ht){if(null===this.chain){const ve=Array.from(new Set([...this.injector.get(rt),...this.injector.get(Vt,[])]));this.chain=ve.reduceRight((Ye,Ne)=>function Mt(tt,xt,ht){return(ve,Ye)=>(0,a.N4e)(ht,()=>xt(ve,Ne=>tt(Ne,Ye)))}(Ye,Ne,this.injector),st)}if(this.contributeToStability){const ve=this.pendingTasks.add();return this.chain(ht,Ye=>this.backend.handle(Ye)).pipe((0,M.j)(()=>this.pendingTasks.remove(ve)))}return this.chain(ht,ve=>this.backend.handle(ve))}static \u0275fac=function(ve){return new(ve||tt)(a.KVO(q),a.KVO(a.uvJ))};static \u0275prov=a.jDH({token:tt,factory:tt.\u0275fac})}return tt})();const St=/^\)\]\}',?\n/;let an=(()=>{class tt{xhrFactory;constructor(ht){this.xhrFactory=ht}handle(ht){if("JSONP"===ht.method)throw new a.wOt(-2800,!1);const ve=this.xhrFactory;return(ve.\u0275loadImpl?(0,w.H)(ve.\u0275loadImpl()):(0,c.of)(null)).pipe((0,O.n)(()=>new y.c(Ne=>{const gt=ve.build();if(gt.open(ht.method,ht.urlWithParams),ht.withCredentials&&(gt.withCredentials=!0),ht.headers.forEach((ar,wr)=>gt.setRequestHeader(ar,wr.join(","))),ht.headers.has("Accept")||gt.setRequestHeader("Accept","application/json, text/plain, */*"),!ht.headers.has("Content-Type")){const ar=ht.detectContentTypeHeader();null!==ar&>.setRequestHeader("Content-Type",ar)}if(ht.responseType){const ar=ht.responseType.toLowerCase();gt.responseType="json"!==ar?ar:"text"}const Ht=ht.serializeBody();let kt=null;const hn=()=>{if(null!==kt)return kt;const ar=gt.statusText||"OK",wr=new re(gt.getAllResponseHeaders()),xr=function Tn(tt){return"responseURL"in tt&&tt.responseURL?tt.responseURL:/^X-Request-URL:/m.test(tt.getAllResponseHeaders())?tt.getResponseHeader("X-Request-URL"):null}(gt)||ht.url;return kt=new bn({headers:wr,status:gt.status,statusText:ar,url:xr}),kt},Dn=()=>{let{headers:ar,status:wr,statusText:xr,url:gi}=hn(),ni=null;204!==wr&&(ni=typeof gt.response>"u"?gt.responseText:gt.response),0===wr&&(wr=ni?200:0);let Mi=wr>=200&&wr<300;if("json"===ht.responseType&&"string"==typeof ni){const Or=ni;ni=ni.replace(St,"");try{ni=""!==ni?JSON.parse(ni):null}catch(Qr){ni=Or,Mi&&(Mi=!1,ni={error:Qr,text:ni})}}Mi?(Ne.next(new Vn({body:ni,headers:ar,status:wr,statusText:xr,url:gi||void 0})),Ne.complete()):Ne.error(new yn({error:ni,headers:ar,status:wr,statusText:xr,url:gi||void 0}))},Cn=ar=>{const{url:wr}=hn(),xr=new yn({error:ar,status:gt.status||0,statusText:gt.statusText||"Unknown Error",url:wr||void 0});Ne.error(xr)};let Nn=!1;const jn=ar=>{Nn||(Ne.next(hn()),Nn=!0);let wr={type:rn.DownloadProgress,loaded:ar.loaded};ar.lengthComputable&&(wr.total=ar.total),"text"===ht.responseType&>.responseText&&(wr.partialText=gt.responseText),Ne.next(wr)},Jn=ar=>{let wr={type:rn.UploadProgress,loaded:ar.loaded};ar.lengthComputable&&(wr.total=ar.total),Ne.next(wr)};return gt.addEventListener("load",Dn),gt.addEventListener("error",Cn),gt.addEventListener("timeout",Cn),gt.addEventListener("abort",Cn),ht.reportProgress&&(gt.addEventListener("progress",jn),null!==Ht&>.upload&>.upload.addEventListener("progress",Jn)),gt.send(Ht),Ne.next({type:rn.Sent}),()=>{gt.removeEventListener("error",Cn),gt.removeEventListener("abort",Cn),gt.removeEventListener("load",Dn),gt.removeEventListener("timeout",Cn),ht.reportProgress&&(gt.removeEventListener("progress",jn),null!==Ht&>.upload&>.upload.removeEventListener("progress",Jn)),gt.readyState!==gt.DONE&>.abort()}})))}static \u0275fac=function(ve){return new(ve||tt)(a.KVO(L.N0))};static \u0275prov=a.jDH({token:tt,factory:tt.\u0275fac})}return tt})();const dn=new a.nKC(""),sr=new a.nKC("",{providedIn:"root",factory:()=>"XSRF-TOKEN"}),Hr=new a.nKC("",{providedIn:"root",factory:()=>"X-XSRF-TOKEN"});class Tr{}let Vr=(()=>{class tt{doc;platform;cookieName;lastCookieString="";lastToken=null;parseCount=0;constructor(ht,ve,Ye){this.doc=ht,this.platform=ve,this.cookieName=Ye}getToken(){if("server"===this.platform)return null;const ht=this.doc.cookie||"";return ht!==this.lastCookieString&&(this.parseCount++,this.lastToken=(0,L._b)(ht,this.cookieName),this.lastCookieString=ht),this.lastToken}static \u0275fac=function(ve){return new(ve||tt)(a.KVO(L.qQ),a.KVO(a.Agw),a.KVO(sr))};static \u0275prov=a.jDH({token:tt,factory:tt.\u0275fac})}return tt})();function vt(tt,xt){const ht=tt.url.toLowerCase();if(!(0,a.WQX)(dn)||"GET"===tt.method||"HEAD"===tt.method||ht.startsWith("http://")||ht.startsWith("https://"))return xt(tt);const ve=(0,a.WQX)(Tr).getToken(),Ye=(0,a.WQX)(Hr);return null!=ve&&!tt.headers.has(Ye)&&(tt=tt.clone({headers:tt.headers.set(Ye,ve)})),xt(tt)}var Re=function(tt){return tt[tt.Interceptors=0]="Interceptors",tt[tt.LegacyInterceptors=1]="LegacyInterceptors",tt[tt.CustomXsrfConfiguration=2]="CustomXsrfConfiguration",tt[tt.NoXsrfProtection=3]="NoXsrfProtection",tt[tt.JsonpSupport=4]="JsonpSupport",tt[tt.RequestsMadeViaParent=5]="RequestsMadeViaParent",tt[tt.Fetch=6]="Fetch",tt}(Re||{});function Ve(...tt){const xt=[Ft,an,Rn,{provide:Z,useExisting:Rn},{provide:q,useFactory:()=>(0,a.WQX)(Ot,{optional:!0})??(0,a.WQX)(an)},{provide:rt,useValue:vt,multi:!0},{provide:dn,useValue:!0},{provide:Tr,useClass:Vr}];for(const ht of tt)xt.push(...ht.\u0275providers);return(0,a.EmA)(xt)}function Dt(tt){return function Ge(tt,xt){return{\u0275kind:tt,\u0275providers:xt}}(Re.Interceptors,tt.map(xt=>({provide:rt,useValue:xt,multi:!0})))}},3107:(o,s,r)=>{"use strict";function a(e,t){return Object.is(e,t)}r.d(s,{bc$:()=>A,iLQ:()=>pg,sZ2:()=>Du,hnV:()=>Vb,wjH:()=>Wi,o8S:()=>hc,BIS:()=>j,gRc:()=>C2,Ql9:()=>FI,Ocv:()=>WI,Z63:()=>Qn,aKT:()=>Os,uvJ:()=>cs,zcH:()=>Cc,bkB:()=>oc,ES_:()=>lm,$GK:()=>bi,nKC:()=>ht,zZn:()=>Qo,_q3:()=>_w,MKu:()=>vw,xe9:()=>dw,Co$:()=>c1,Vns:()=>gf,SKi:()=>os,Xx1:()=>ca,Agw:()=>b,PLl:()=>sd,rOR:()=>Ff,sFG:()=>jD,_9s:()=>Ib,czy:()=>mp,WPN:()=>ud,kdw:()=>Ts,C4Q:()=>sg,NYb:()=>LA,giA:()=>I1,RxE:()=>f2,c1b:()=>Cv,gXe:()=>Sc,mal:()=>Xa,Tzd:()=>ba,L39:()=>GO,EWP:()=>xw,sbv:()=>$S,a0P:()=>vR,Ol2:()=>Pb,w6W:()=>tA,QZP:()=>Dw,Rfq:()=>Re,oKB:()=>Ua,WQX:()=>lr,hFB:()=>$g,naY:()=>JI,Hps:()=>Bb,QuC:()=>Ro,EmA:()=>jo,Udg:()=>XO,HJs:()=>yR,N4e:()=>$s,vPA:()=>kp,O8t:()=>Zp,H3F:()=>x1,H8p:()=>yl,KH2:()=>Xp,TgB:()=>Ec,wOt:()=>Rn,WHO:()=>M1,e01:()=>k1,lNU:()=>Nr,h9k:()=>Lm,$MX:()=>cp,ZF7:()=>Gd,Kcf:()=>By,e5t:()=>Vy,UyX:()=>$y,cWb:()=>Uy,osQ:()=>jy,H5H:()=>V0,Zy3:()=>pr,mq5:()=>Dx,JZv:()=>dn,TL3:()=>CO,LfX:()=>Fo,plB:()=>Jd,jNT:()=>jb,zjR:()=>O1,ngT:()=>oi,hVU:()=>NA,TL$:()=>_m,Tbb:()=>Tr,rcV:()=>Gc,nM4:()=>TE,Vt3:()=>h0,GFd:()=>RE,OA$:()=>zl,Jv_:()=>LC,R7$:()=>xp,BMQ:()=>A0,HbH:()=>sx,ZvI:()=>fx,AVh:()=>R0,BUC:()=>px,vxM:()=>vx,wni:()=>oC,C6U:()=>cC,VBU:()=>g1,FsC:()=>v1,jDH:()=>ai,G2t:()=>fo,$C:()=>Fb,EJ8:()=>y1,rXU:()=>qd,nrm:()=>B0,eu8:()=>U0,bVm:()=>Fv,qex:()=>Pv,k0s:()=>Lv,j41:()=>Nv,RV6:()=>Cx,xGo:()=>Eh,Mr5:()=>$0,KVO:()=>_o,kS0:()=>Xu,QTQ:()=>iv,bIt:()=>z0,lsd:()=>lC,joV:()=>Br,qSk:()=>Cr,XpG:()=>Xx,nI1:()=>XC,bMT:()=>YC,i5U:()=>QC,SdG:()=>Qx,NAR:()=>Yx,Y8G:()=>k0,FS9:()=>X0,Mz_:()=>Vv,lJ4:()=>FC,eq3:()=>BC,l_i:()=>UC,sMw:()=>$C,ziG:()=>jC,lV:()=>VC,NyB:()=>uC,mGM:()=>aC,sdS:()=>dC,Dyx:()=>wx,Z7z:()=>bx,Vm6:()=>yx,Njj:()=>hu,eBV:()=>Ic,npT:()=>y_,f$h:()=>Fm,B4B:()=>Xd,n$t:()=>b_,Aen:()=>Zc,xc7:()=>O0,Kam:()=>K0,zvX:()=>j0,DNE:()=>m0,C5r:()=>ZC,EFF:()=>wC,JRh:()=>Q0,SpI:()=>Hv,DH7:()=>IC,mxI:()=>q0,R50:()=>Z0,GBs:()=>sC}),r(3014);let c=null,y=!1,w=1;const C=Symbol("SIGNAL");function T(e){const t=c;return c=e,t}const L={version:0,lastCleanEpoch:0,dirty:!1,producerNode:void 0,producerLastReadVersion:void 0,producerIndexOfThis:void 0,nextProducerIndex:0,liveConsumerNode:void 0,liveConsumerIndexOfThis:void 0,consumerAllowSignalWrites:!1,consumerIsAlwaysLive:!1,producerMustRecompute:()=>!1,producerRecomputeValue:()=>{},consumerMarkedDirty:()=>{},consumerOnSignalRead:()=>{}};function Z(e){if(y)throw new Error("");if(null===c)return;c.consumerOnSignalRead(e);const t=c.nextProducerIndex++;Be(c),te.nextProducerIndex;)e.producerNode.pop(),e.producerLastReadVersion.pop(),e.producerIndexOfThis.pop()}}function xe(e){Be(e);for(let t=0;t0}function Be(e){e.producerNode??=[],e.producerIndexOfThis??=[],e.producerLastReadVersion??=[]}function at(e){e.liveConsumerNode??=[],e.liveConsumerIndexOfThis??=[]}function dt(e){return void 0!==e.producerNode}function bt(e){const t=Object.create(bn);t.computation=e;const n=()=>{if(re(t),Z(t),t.value===gn)throw t.error;return t.value};return n[C]=t,n}const lt=Symbol("UNSET"),rn=Symbol("COMPUTING"),gn=Symbol("ERRORED"),bn={...L,value:lt,dirty:!0,error:null,equal:a,producerMustRecompute:e=>e.value===lt||e.value===rn,producerRecomputeValue(e){if(e.value===rn)throw new Error("Detected cycle in computations.");const t=e.value;e.value=rn;const n=be(e);let l;try{l=e.computation()}catch(p){l=gn,e.error=p}finally{Oe(e,n)}t!==lt&&t!==gn&&l!==gn&&e.equal(t,l)?e.value=t:(e.value=l,e.version++)}};let yn=function Vn(){throw new Error};function qe(){yn()}let ze=null;function Ze(e,t){se()||qe(),e.equal(e.value,t)||(e.value=t,function Te(e){e.version++,function q(){w++}(),pe(e),ze?.()}(e))}const $t={...L,equal:a,value:void 0};const st=()=>{},Xt={...L,consumerIsAlwaysLive:!0,consumerAllowSignalWrites:!1,consumerMarkedDirty:e=>{null!==e.schedule&&e.schedule(e.ref)},hasRun:!1,cleanupFn:st};var Kt=r(1217),rt=r(8447),Vt=r(5710),en=r(7947);r(1703);const Nr="https://g.co/ng/security#xss";class Rn extends Error{code;constructor(t,n){super(pr(t,n)),this.code=t}}function pr(e,t){return`NG0${Math.abs(e)}${t?": "+t:""}`}const cn=Symbol("InputSignalNode#UNSET"),Fe={...$t,transformFn:void 0,applyValueToInputSignal(e,t){Ze(e,t)}};function z(e,t){const n=Object.create(Fe);function l(){if(Z(n),n.value===cn)throw new Rn(-950,!1);return n.value}return n.value=e,n.transformFn=t?.transform,l[C]=n,l}function N(e){return{toString:e}.toString()}const Le="__parameters__";function Tn(e,t,n){return N(()=>{const l=function St(e){return function(...n){if(e){const l=e(...n);for(const p in l)this[p]=l[p]}}}(t);function p(...g){if(this instanceof p)return l.apply(this,g),this;const x=new p(...g);return k.annotation=x,k;function k(B,ie,Se){const He=B.hasOwnProperty(Le)?B[Le]:Object.defineProperty(B,Le,{value:[]})[Le];for(;He.length<=Se;)He.push(null);return(He[Se]=He[Se]||[]).push(x),B}}return n&&(p.prototype=Object.create(n.prototype)),p.prototype.ngMetadataName=e,p.annotationCls=p,p})}const dn=globalThis;function xn(e){for(let t in e)if(e[t]===xn)return t;throw Error("Could not find renamed property on target object.")}function Hr(e,t){for(const n in t)t.hasOwnProperty(n)&&!e.hasOwnProperty(n)&&(e[n]=t[n])}function Tr(e){if("string"==typeof e)return e;if(Array.isArray(e))return"["+e.map(Tr).join(", ")+"]";if(null==e)return""+e;if(e.overriddenName)return`${e.overriddenName}`;if(e.name)return`${e.name}`;const t=e.toString();if(null==t)return""+t;const n=t.indexOf("\n");return-1===n?t:t.substring(0,n)}function Vr(e,t){return null==e||""===e?null===t?"":t:null==t||""===t?e:e+" "+t}const Wt=xn({__forward_ref__:xn});function Re(e){return e.__forward_ref__=Re,e.toString=function(){return Tr(this())},e}function Ge(e){return Ve(e)?e():e}function Ve(e){return"function"==typeof e&&e.hasOwnProperty(Wt)&&e.__forward_ref__===Re}function ai(e){return{token:e.token,providedIn:e.providedIn||null,factory:e.factory,value:void 0}}function fo(e){return{providers:e.providers||[],imports:e.imports||[]}}function Jo(e){return oa(e,Ii)||oa(e,tt)}function Fo(e){return null!==Jo(e)}function oa(e,t){return e.hasOwnProperty(t)?e[t]:null}function po(e){return e&&(e.hasOwnProperty(Io)||e.hasOwnProperty(xt))?e[Io]:null}const Ii=xn({\u0275prov:xn}),Io=xn({\u0275inj:xn}),tt=xn({ngInjectableDef:xn}),xt=xn({ngInjectorDef:xn});class ht{_desc;ngMetadataName="InjectionToken";\u0275prov;constructor(t,n){this._desc=t,this.\u0275prov=void 0,"number"==typeof n?this.__NG_ELEMENT_ID__=n:void 0!==n&&(this.\u0275prov=ai({token:this,providedIn:n.providedIn||"root",factory:n.factory}))}get multi(){return this}toString(){return`InjectionToken ${this._desc}`}}function jn(e){return e&&!!e.\u0275providers}const Jn=xn({\u0275cmp:xn}),ar=xn({\u0275dir:xn}),wr=xn({\u0275pipe:xn}),xr=xn({\u0275mod:xn}),gi=xn({\u0275fac:xn}),ni=xn({__NG_ELEMENT_ID__:xn}),Mi=xn({__NG_ENV_ID__:xn});function Or(e){return"string"==typeof e?e:null==e?"":String(e)}function Li(e,t){throw new Rn(-201,!1)}var bi=function(e){return e[e.Default=0]="Default",e[e.Host=1]="Host",e[e.Self=2]="Self",e[e.SkipSelf=4]="SkipSelf",e[e.Optional=8]="Optional",e}(bi||{});let aa;function Ks(){return aa}function Oo(e){const t=aa;return aa=e,t}function Cs(e,t,n){const l=Jo(e);return l&&"root"==l.providedIn?void 0===l.value?l.value=l.factory():l.value:n&bi.Optional?null:void 0!==t?t:void Li()}const Ko={},mo="__NG_DI_FLAG__",Go="ngTempTokenPath",Xr=/\n/gm,go="__source";let io;function Xo(e){const t=io;return io=e,t}function Qa(e,t=bi.Default){if(void 0===io)throw new Rn(-203,!1);return null===io?Cs(e,void 0,t):io.get(e,t&bi.Optional?null:void 0,t)}function _o(e,t=bi.Default){return(Ks()||Qa)(Ge(e),t)}function lr(e,t=bi.Default){return _o(e,As(t))}function As(e){return typeof e>"u"||"number"==typeof e?e:(e.optional&&8)|(e.host&&1)|(e.self&&2)|(e.skipSelf&&4)}function Gs(e){const t=[];for(let n=0;nArray.isArray(n)?ps(n,t):t(n))}function Da(e,t,n){t>=e.length?e.push(n):e.splice(t,0,n)}function Ms(e,t){return t>=e.length-1?e.pop():e.splice(t,1)[0]}function et(e,t,n){let l=ot(e,t);return l>=0?e[1|l]=n:(l=~l,function Aa(e,t,n,l){let p=e.length;if(p==t)e.push(n,l);else if(1===p)e.push(l,e[0]),e[0]=n;else{for(p--,e.push(e[p-1],e[p]);p>t;)e[p]=e[p-2],p--;e[t]=n,e[t+1]=l}}(e,l,t,n)),l}function te(e,t){const n=ot(e,t);if(n>=0)return e[1|n]}function ot(e,t){return function Bn(e,t,n){let l=0,p=e.length>>n;for(;p!==l;){const g=l+(p-l>>1),x=e[g<t?p=g:l=g+1}return~(p<{n.push(x)};return ps(t,x=>{const k=x;de(k,g,[],l)&&(p||=[],p.push(k))}),void 0!==p&&da(p,g),n}function da(e,t){for(let n=0;n{t(g,l)})}}function de(e,t,n,l){if(!(e=Ge(e)))return!1;let p=null,g=po(e);const x=!g&&zr(e);if(g||x){if(x&&!x.standalone)return!1;p=e}else{const B=e.ngModule;if(g=po(B),!g)return!1;p=B}const k=l.has(p);if(x){if(k)return!1;if(l.add(p),x.dependencies){const B="function"==typeof x.dependencies?x.dependencies():x.dependencies;for(const ie of B)de(ie,t,n,l)}}else{if(!g)return!1;{if(null!=g.imports&&!k){let ie;l.add(p);try{ps(g.imports,Se=>{de(Se,t,n,l)&&(ie||=[],ie.push(Se))})}finally{}void 0!==ie&&da(ie,t)}if(!k){const ie=So(p)||(()=>new p);t({provide:p,useFactory:ie,deps:Wn},p),t({provide:zi,useValue:p,multi:!0},p),t({provide:Qn,useValue:()=>_o(p),multi:!0},p)}const B=g.providers;if(null!=B&&!k){const ie=e;Y(B,Se=>{t(Se,ie)})}}}return p!==e&&void 0!==e.providers}function Y(e,t){for(let n of e)jn(n)&&(n=n.\u0275providers),Array.isArray(n)?Y(n,t):t(n)}const Ue=xn({provide:String,useValue:xn});function jt(e){return null!==e&&"object"==typeof e&&Ue in e}function ts(e){return"function"==typeof e}const yl=new ht(""),ja={},fc={};let cl;function _i(){return void 0===cl&&(cl=new Mr),cl}class cs{}class vs extends cs{parent;source;scopes;records=new Map;_ngOnDestroyHooks=new Set;_onDestroyHooks=[];get destroyed(){return this._destroyed}_destroyed=!1;injectorDefTypes;constructor(t,n,l,p){super(),this.parent=n,this.source=l,this.scopes=p,dl(t,x=>this.processProvider(x)),this.records.set(qr,yi(void 0,this)),p.has("environment")&&this.records.set(cs,yi(void 0,this));const g=this.records.get(yl);null!=g&&"string"==typeof g.value&&this.scopes.add(g.value),this.injectorDefTypes=new Set(this.get(zi,Wn,bi.Self))}destroy(){ul(this),this._destroyed=!0;const t=T(null);try{for(const l of this._ngOnDestroyHooks)l.ngOnDestroy();const n=this._onDestroyHooks;this._onDestroyHooks=[];for(const l of n)l()}finally{this.records.clear(),this._ngOnDestroyHooks.clear(),this.injectorDefTypes.clear(),T(t)}}onDestroy(t){return ul(this),this._onDestroyHooks.push(t),()=>this.removeOnDestroy(t)}runInContext(t){ul(this);const n=Xo(this),l=Oo(void 0);try{return t()}finally{Xo(n),Oo(l)}}get(t,n=Ko,l=bi.Default){if(ul(this),t.hasOwnProperty(Mi))return t[Mi](this);l=As(l);const g=Xo(this),x=Oo(void 0);try{if(!(l&bi.SkipSelf)){let B=this.records.get(t);if(void 0===B){const ie=function tu(e){return"function"==typeof e||"object"==typeof e&&e instanceof ht}(t)&&Jo(t);B=ie&&this.injectableDefInScope(ie)?yi(Va(t),ja):null,this.records.set(t,B)}if(null!=B)return this.hydrate(t,B)}return(l&bi.Self?_i():this.parent).get(t,n=l&bi.Optional&&n===Ko?null:n)}catch(k){if("NullInjectorError"===k.name){if((k[Go]=k[Go]||[]).unshift(Tr(t)),g)throw k;return function ls(e,t,n,l){const p=e[Go];throw t[go]&&p.unshift(t[go]),e.message=function Vi(e,t,n,l=null){e=e&&"\n"===e.charAt(0)&&"\u0275"==e.charAt(1)?e.slice(2):e;let p=Tr(t);if(Array.isArray(t))p=t.map(Tr).join(" -> ");else if("object"==typeof t){let g=[];for(let x in t)if(t.hasOwnProperty(x)){let k=t[x];g.push(x+":"+("string"==typeof k?JSON.stringify(k):Tr(k)))}p=`{${g.join(", ")}}`}return`${n}${l?"("+l+")":""}[${p}]: ${e.replace(Xr,"\n ")}`}("\n"+e.message,p,n,l),e.ngTokenPath=p,e[Go]=null,e}(k,t,"R3InjectorError",this.source)}throw k}finally{Oo(x),Xo(g)}}resolveInjectorInitializers(){const t=T(null),n=Xo(this),l=Oo(void 0);try{const g=this.get(Qn,Wn,bi.Self);for(const x of g)x()}finally{Xo(n),Oo(l),T(t)}}toString(){const t=[],n=this.records;for(const l of n.keys())t.push(Tr(l));return`R3Injector[${t.join(", ")}]`}processProvider(t){let n=ts(t=Ge(t))?t:Ge(t&&t.provide);const l=function Pu(e){return jt(e)?yi(void 0,e.useValue):yi(wl(e),ja)}(t);if(!ts(t)&&!0===t.multi){let p=this.records.get(n);p||(p=yi(void 0,ja,!0),p.factory=()=>Gs(p.multi),this.records.set(n,p)),n=t,p.multi.push(t)}this.records.set(n,l)}hydrate(t,n){const l=T(null);try{return n.value===ja&&(n.value=fc,n.value=n.factory()),"object"==typeof n.value&&n.value&&function eu(e){return null!==e&&"object"==typeof e&&"function"==typeof e.ngOnDestroy}(n.value)&&this._ngOnDestroyHooks.add(n.value),n.value}finally{T(l)}}injectableDefInScope(t){if(!t.providedIn)return!1;const n=Ge(t.providedIn);return"string"==typeof n?"any"===n||this.scopes.has(n):this.injectorDefTypes.has(n)}removeOnDestroy(t){const n=this._onDestroyHooks.indexOf(t);-1!==n&&this._onDestroyHooks.splice(n,1)}}function Va(e){const t=Jo(e),n=null!==t?t.factory:So(e);if(null!==n)return n;if(e instanceof ht)throw new Rn(204,!1);if(e instanceof Function)return function bl(e){if(e.length>0)throw new Rn(204,!1);const n=function ao(e){return e&&(e[Ii]||e[tt])||null}(e);return null!==n?()=>n.factory(e):()=>new e}(e);throw new Rn(204,!1)}function wl(e,t,n){let l;if(ts(e)){const p=Ge(e);return So(p)||Va(p)}if(jt(e))l=()=>Ge(e.useValue);else if(function Jr(e){return!(!e||!e.useFactory)}(e))l=()=>e.useFactory(...Gs(e.deps||[]));else if(function br(e){return!(!e||!e.useExisting)}(e))l=()=>_o(Ge(e.useExisting));else{const p=Ge(e&&(e.useClass||e.provide));if(!function Il(e){return!!e.deps}(e))return So(p)||Va(p);l=()=>new p(...Gs(e.deps))}return l}function ul(e){if(e.destroyed)throw new Rn(205,!1)}function yi(e,t,n=!1){return{factory:e,value:t,multi:n?[]:void 0}}function dl(e,t){for(const n of e)Array.isArray(n)?dl(n,t):n&&jn(n)?dl(n.\u0275providers,t):t(n)}function $s(e,t){e instanceof vs&&ul(e);const l=Xo(e),p=Oo(void 0);try{return t()}finally{Xo(l),Oo(p)}}function Ol(){return void 0!==Ks()||null!=function fs(){return io}()}function Sa(e){if(!Ol())throw new Rn(-203,!1)}const oo=0,Fn=1,Sr=2,Oi=3,ys=4,Qi=5,so=6,Bi=7,Ki=8,no=9,co=10,ri=11,Xs=12,Za=13,Uo=14,vo=15,Ci=16,Vs=17,uo=18,Ui=19,U=20,Ie=21,ne=22,ye=23,Et=24,Gt=25,Un=1,ci=7,Di=9,Rr=10;var li=function(e){return e[e.None=0]="None",e[e.HasTransplantedViews=2]="HasTransplantedViews",e}(li||{});function ii(e){return Array.isArray(e)&&"object"==typeof e[Un]}function wi(e){return Array.isArray(e)&&!0===e[Un]}function bs(e){return!!(4&e.flags)}function Lo(e){return e.componentOffset>-1}function fa(e){return!(1&~e.flags)}function Yo(e){return!!e.template}function Ha(e){return!!(512&e[Sr])}class kc{previousValue;currentValue;firstChange;constructor(t,n,l){this.previousValue=t,this.currentValue=n,this.firstChange=l}isFirstChange(){return this.firstChange}}function Hs(e,t,n,l){null!==t?t.applyValueToInputSignal(t,l):e[n]=l}const zl=(()=>{const e=()=>Wa;return e.ngInherit=!0,e})();function Wa(e){return e.type.prototype.ngOnChanges&&(e.setInput=Gl),Fr}function Fr(){const e=pl(this),t=e?.current;if(t){const n=e.previous;if(n===On)e.previous=t;else for(let l in t)n[l]=t[l];e.current=null,this.ngOnChanges(t)}}function Gl(e,t,n,l,p){const g=this.declaredInputs[l],x=pl(e)||function gd(e,t){return e[Xl]=t}(e,{previous:On,current:null}),k=x.current||(x.current={}),B=x.previous,ie=B[g];k[g]=new kc(ie&&ie.currentValue,n,B===On),Hs(e,t,p,n)}const Xl="__ngSimpleChanges__";function pl(e){return e[Xl]||null}const za=function(e,t,n){},lh="svg";function qi(e){for(;Array.isArray(e);)e=e[oo];return e}function gc(e,t){return qi(t[e])}function rs(e,t){return qi(t[e.index])}function G(e,t){return e.data[t]}function F(e,t){return e[t]}function K(e,t){const n=t[e];return ii(n)?n:n[oo]}function We(e){return!(128&~e[Sr])}function fn(e,t){return null==t?null:e[t]}function on(e){e[Vs]=0}function ur(e){1024&e[Sr]||(e[Sr]|=1024,We(e)&&Is(e))}function kr(e){return!!(9216&e[Sr]||e[Et]?.dirty)}function Gi(e){e[co].changeDetectionScheduler?.notify(9),64&e[Sr]&&(e[Sr]|=1024),kr(e)&&Is(e)}function Is(e){e[co].changeDetectionScheduler?.notify(0);let t=us(e);for(;null!==t&&!(8192&t[Sr])&&(t[Sr]|=8192,We(t));)t=us(t)}function is(e,t){if(!(256&~e[Sr]))throw new Rn(911,!1);null===e[Ie]&&(e[Ie]=[]),e[Ie].push(t)}function us(e){const t=e[Oi];return wi(t)?t[Oi]:t}const Wr={lFrame:nr(null),bindingsEnabled:!0,skipHydrationRootTNode:null};let $u=!1;function hh(){return Wr.bindingsEnabled}function _c(){return null!==Wr.skipHydrationRootTNode}function En(){return Wr.lFrame.lView}function pi(){return Wr.lFrame.tView}function Ic(e){return Wr.lFrame.contextLView=e,e[Ki]}function hu(e){return Wr.lFrame.contextLView=null,e}function Si(){let e=Nl();for(;null!==e&&64===e.type;)e=e.parent;return e}function Nl(){return Wr.lFrame.currentTNode}function Qs(e,t){const n=Wr.lFrame;n.currentTNode=e,n.isParent=t}function Oc(){return Wr.lFrame.isParent}function pa(){Wr.lFrame.isParent=!1}function ma(){return $u}function ql(e){const t=$u;return $u=e,t}function Zs(){const e=Wr.lFrame;let t=e.bindingRootIndex;return-1===t&&(t=e.bindingRootIndex=e.tView.bindingStartIndex),t}function I(){return Wr.lFrame.bindingIndex++}function P(e){const t=Wr.lFrame,n=t.bindingIndex;return t.bindingIndex=t.bindingIndex+e,n}function Ae(e,t){const n=Wr.lFrame;n.bindingIndex=n.bindingRootIndex=e,pt(t)}function pt(e){Wr.lFrame.currentDirectiveIndex=e}function It(e){const t=Wr.lFrame.currentDirectiveIndex;return-1===t?null:e[t]}function zt(){return Wr.lFrame.currentQueryIndex}function ln(e){Wr.lFrame.currentQueryIndex=e}function An(e){const t=e[Fn];return 2===t.type?t.declTNode:1===t.type?e[Qi]:null}function Qt(e,t,n){if(n&bi.SkipSelf){let p=t,g=e;for(;!(p=p.parent,null!==p||n&bi.Host||(p=An(g),null===p||(g=g[Uo],10&p.type))););if(null===p)return!1;t=p,e=g}const l=Wr.lFrame=zn();return l.currentTNode=t,l.lView=e,!0}function Gn(e){const t=zn(),n=e[Fn];Wr.lFrame=t,t.currentTNode=n.firstChild,t.lView=e,t.tView=n,t.contextLView=e,t.bindingIndex=n.bindingStartIndex,t.inI18n=!1}function zn(){const e=Wr.lFrame,t=null===e?null:e.child;return null===t?nr(e):t}function nr(e){const t={currentTNode:null,isParent:!0,lView:null,tView:null,selectedIndex:-1,contextLView:null,elementDepthCount:0,currentNamespace:null,currentDirectiveIndex:-1,bindingRootIndex:-1,bindingIndex:-1,currentQueryIndex:0,parent:e,child:null,inI18n:!1};return null!==e&&(e.child=t),t}function Mn(){const e=Wr.lFrame;return Wr.lFrame=e.parent,e.currentTNode=null,e.lView=null,e}const Hn=Mn;function Xn(){const e=Mn();e.isParent=!0,e.tView=null,e.selectedIndex=-1,e.contextLView=null,e.elementDepthCount=0,e.currentDirectiveIndex=-1,e.currentNamespace=null,e.bindingRootIndex=-1,e.bindingIndex=-1,e.currentQueryIndex=0}function $n(){return Wr.lFrame.selectedIndex}function Ir(e){Wr.lFrame.selectedIndex=e}function ir(){const e=Wr.lFrame;return G(e.tView,e.selectedIndex)}function Cr(){Wr.lFrame.currentNamespace=lh}function Br(){!function ro(){Wr.lFrame.currentNamespace=null}()}let Xi=!0;function bo(){return Xi}function To(e){Xi=e}function _r(e,t){for(let n=t.directiveStart,l=t.directiveEnd;n=l)break}else t[B]<0&&(e[Vs]+=65536),(k>14>16&&(3&e[Sr])===t&&(e[Sr]+=16384,gs(k,g)):gs(k,g)}const Ps=-1;class el{factory;injectImpl;resolving=!1;canSeeViewProviders;multi;componentProviders;index;providerFactory;constructor(t,n,l){this.factory=t,this.canSeeViewProviders=n,this.injectImpl=l}}function Js(e,t,n){let l=0;for(;lt){x=g-1;break}}}for(;g>16}(e),l=t;for(;n>0;)l=l[Uo],n--;return l}let _h=!0;function Ll(e){const t=_h;return _h=e,t}const bd=255,zu=5;let rm=0;const Pl={};function vh(e,t){const n=wd(e,t);if(-1!==n)return n;const l=t[Fn];l.firstCreatePass&&(e.injectorIndex=t.length,Cf(l.data,e),Cf(t,null),Cf(l.blueprint,null));const p=Nc(e,t),g=e.injectorIndex;if(gh(p)){const x=Hu(p),k=Wu(p,t),B=k[Fn].data;for(let ie=0;ie<8;ie++)t[g+ie]=k[x+ie]|B[x+ie]}return t[g+8]=p,g}function Cf(e,t){e.push(0,0,0,0,0,0,0,0,t)}function wd(e,t){return-1===e.injectorIndex||e.parent&&e.parent.injectorIndex===e.injectorIndex||null===t[e.injectorIndex+8]?-1:e.injectorIndex}function Nc(e,t){if(e.parent&&-1!==e.parent.injectorIndex)return e.parent.injectorIndex;let n=0,l=null,p=t;for(;null!==p;){if(l=Gu(p),null===l)return Ps;if(n++,p=p[Uo],-1!==l.injectorIndex)return l.injectorIndex|n<<16}return Ps}function Lc(e,t,n){!function im(e,t,n){let l;"string"==typeof n?l=n.charCodeAt(0)||0:n.hasOwnProperty(ni)&&(l=n[ni]),null==l&&(l=n[ni]=rm++);const p=l&bd;t.data[e+(p>>zu)]|=1<=0?t&bd:Sf:t}(n);if("function"==typeof g){if(!Qt(t,e,l))return l&bi.Host?Ku(p,0,l):Df(t,n,l,p);try{let x;if(x=g(l),null!=x||l&bi.Optional)return x;Li()}finally{Hn()}}else if("number"==typeof g){let x=null,k=wd(e,t),B=Ps,ie=l&bi.Host?t[vo][Qi]:null;for((-1===k||l&bi.SkipSelf)&&(B=-1===k?Nc(e,t):t[k+8],B!==Ps&&wh(l,!1)?(x=t[Fn],k=Hu(B),t=Wu(B,t)):k=-1);-1!==k;){const Se=t[Fn];if(xd(g,k,Se.data)){const He=bh(k,t,n,x,l,ie);if(He!==Pl)return He}B=t[k+8],B!==Ps&&wh(l,t[Fn].data[k+8]===ie)&&xd(g,k,t)?(x=Se,k=Hu(B),t=Wu(B,t)):k=-1}}return p}function bh(e,t,n,l,p,g){const x=t[Fn],k=x.data[e+8],Se=fu(k,x,n,null==l?Lo(k)&&_h:l!=x&&!!(3&k.type),p&bi.Host&&g===k);return null!==Se?Fl(t,x,Se,k):Pl}function fu(e,t,n,l,p){const g=e.providerIndexes,x=t.data,k=1048575&g,B=e.directiveStart,Se=g>>20,Nt=p?k+Se:e.directiveEnd;for(let Ut=l?k:k+Se;Ut=B&&qt.type===n)return Ut}if(p){const Ut=x[B];if(Ut&&Yo(Ut)&&Ut.type===n)return B}return null}function Fl(e,t,n,l){let p=e[n];const g=t.data;if(function Dl(e){return e instanceof el}(p)){const x=p;x.resolving&&function es(e,t){throw t&&t.join(" > "),new Rn(-200,e)}(function Qr(e){return"function"==typeof e?e.name||e.toString():"object"==typeof e&&null!=e&&"function"==typeof e.type?e.type.name||e.type.toString():Or(e)}(g[n]));const k=Ll(x.canSeeViewProviders);x.resolving=!0;const ie=x.injectImpl?Oo(x.injectImpl):null;Qt(e,l,bi.Default);try{p=e[n]=x.factory(void 0,g,e,l),t.firstCreatePass&&n>=l.directiveStart&&function ga(e,t,n){const{ngOnChanges:l,ngOnInit:p,ngDoCheck:g}=t.type.prototype;if(l){const x=Wa(t);(n.preOrderHooks??=[]).push(e,x),(n.preOrderCheckHooks??=[]).push(e,x)}p&&(n.preOrderHooks??=[]).push(0-e,p),g&&((n.preOrderHooks??=[]).push(e,g),(n.preOrderCheckHooks??=[]).push(e,g))}(n,g[n],t)}finally{null!==ie&&Oo(ie),Ll(k),x.resolving=!1,Hn()}}return p}function xd(e,t,n){return!!(n[t+(e>>zu)]&1<{const t=e.prototype.constructor,n=t[gi]||Cd(t),l=Object.prototype;let p=Object.getPrototypeOf(e.prototype).constructor;for(;p&&p!==l;){const g=p[gi]||Cd(p);if(g&&g!==n)return g;p=Object.getPrototypeOf(p)}return g=>new g})}function Cd(e){return Ve(e)?()=>{const t=Cd(Ge(e));return t&&t()}:So(e)}function Gu(e){const t=e[Fn],n=t.type;return 2===n?t.declTNode:1===n?e[Qi]:null}function Xu(e){return function Ed(e,t){if("class"===t)return e.classes;if("style"===t)return e.styles;const n=e.attrs;if(n){const l=n.length;let p=0;for(;p_o(qr)});static __NG_ELEMENT_ID__=-1}class lm{attributeName;constructor(t){this.attributeName=t}__NG_ELEMENT_ID__=()=>Xu(this.attributeName);toString(){return`HostAttributeToken ${this.attributeName}`}}new ht("").__NG_ELEMENT_ID__=e=>{const t=Si();if(null===t)throw new Rn(204,!1);if(2&t.type)return t.value;if(e&bi.Optional)return null;throw new Rn(204,!1)};const Sh=!1;let ws=(()=>class e{static __NG_ELEMENT_ID__=kd;static __NG_ENV_ID__=n=>n})();class Fc extends ws{_lView;constructor(t){super(),this._lView=t}onDestroy(t){return is(this._lView,t),()=>function Oa(e,t){if(null===e[Ie])return;const n=e[Ie].indexOf(t);-1!==n&&e[Ie].splice(n,1)}(this._lView,t)}}function kd(){return new Fc(En())}class rc{}const gu=new ht("",{providedIn:"root",factory:()=>!1}),Od=new ht(""),ic=new ht("");let Ec=(()=>{class e{taskId=0;pendingTasks=new Set;get _hasPendingTasks(){return this.hasPendingTasks.value}hasPendingTasks=new Kt.t(!1);add(){this._hasPendingTasks||this.hasPendingTasks.next(!0);const n=this.taskId++;return this.pendingTasks.add(n),n}has(n){return this.pendingTasks.has(n)}remove(n){this.pendingTasks.delete(n),0===this.pendingTasks.size&&this._hasPendingTasks&&this.hasPendingTasks.next(!1)}ngOnDestroy(){this.pendingTasks.clear(),this._hasPendingTasks&&this.hasPendingTasks.next(!1)}static \u0275prov=ai({token:e,providedIn:"root",factory:()=>new e})}return e})();const oc=class Mh extends rt.B{__isAsync;destroyRef=void 0;pendingTasks=void 0;constructor(t=!1){super(),this.__isAsync=t,Ol()&&(this.destroyRef=lr(ws,{optional:!0})??void 0,this.pendingTasks=lr(Ec,{optional:!0})??void 0)}emit(t){const n=T(null);try{super.next(t)}finally{T(n)}}subscribe(t,n,l){let p=t,g=n||(()=>null),x=l;if(t&&"object"==typeof t){const B=t;p=B.next?.bind(B),g=B.error?.bind(B),x=B.complete?.bind(B)}this.__isAsync&&(g=this.wrapInTimeout(g),p&&(p=this.wrapInTimeout(p)),x&&(x=this.wrapInTimeout(x)));const k=super.subscribe({next:p,error:g,complete:x});return t instanceof Vt.yU&&t.add(k),k}wrapInTimeout(t){return n=>{const l=this.pendingTasks?.add();setTimeout(()=>{t(n),void 0!==l&&this.pendingTasks?.remove(l)})}}};function _u(...e){}function Rd(e){let t,n;function l(){e=_u;try{void 0!==n&&"function"==typeof cancelAnimationFrame&&cancelAnimationFrame(n),void 0!==t&&clearTimeout(t)}catch{}}return t=setTimeout(()=>{e(),l()}),"function"==typeof requestAnimationFrame&&(n=requestAnimationFrame(()=>{e(),l()})),()=>l()}function cm(e){return queueMicrotask(()=>e()),()=>{e=_u}}const xc="isAngularZone",Zu=xc+"_ID";let kh=0;class os{hasPendingMacrotasks=!1;hasPendingMicrotasks=!1;isStable=!0;onUnstable=new oc(!1);onMicrotaskEmpty=new oc(!1);onStable=new oc(!1);onError=new oc(!1);constructor(t){const{enableLongStackTrace:n=!1,shouldCoalesceEventChangeDetection:l=!1,shouldCoalesceRunChangeDetection:p=!1,scheduleInRootZone:g=Sh}=t;if(typeof Zone>"u")throw new Rn(908,!1);Zone.assertZonePatched();const x=this;x._nesting=0,x._outer=x._inner=Zone.current,Zone.TaskTrackingZoneSpec&&(x._inner=x._inner.fork(new Zone.TaskTrackingZoneSpec)),n&&Zone.longStackTraceZoneSpec&&(x._inner=x._inner.fork(Zone.longStackTraceZoneSpec)),x.shouldCoalesceEventChangeDetection=!p&&l,x.shouldCoalesceRunChangeDetection=p,x.callbackScheduled=!1,x.scheduleInRootZone=g,function Rf(e){const t=()=>{!function um(e){function t(){Rd(()=>{e.callbackScheduled=!1,Oh(e),e.isCheckStableRunning=!0,Ih(e),e.isCheckStableRunning=!1})}e.isCheckStableRunning||e.callbackScheduled||(e.callbackScheduled=!0,e.scheduleInRootZone?Zone.root.run(()=>{t()}):e._outer.run(()=>{t()}),Oh(e))}(e)},n=kh++;e._inner=e._inner.fork({name:"angular",properties:{[xc]:!0,[Zu]:n,[Zu+n]:!0},onInvokeTask:(l,p,g,x,k,B)=>{if(function dm(e){return Lf(e,"__ignore_ng_zone__")}(B))return l.invokeTask(g,x,k,B);try{return Nf(e),l.invokeTask(g,x,k,B)}finally{(e.shouldCoalesceEventChangeDetection&&"eventTask"===x.type||e.shouldCoalesceRunChangeDetection)&&t(),vu(e)}},onInvoke:(l,p,g,x,k,B,ie)=>{try{return Nf(e),l.invoke(g,x,k,B,ie)}finally{e.shouldCoalesceRunChangeDetection&&!e.callbackScheduled&&!function Fg(e){return Lf(e,"__scheduler_tick__")}(B)&&t(),vu(e)}},onHasTask:(l,p,g,x)=>{l.hasTask(g,x),p===g&&("microTask"==x.change?(e._hasPendingMicrotasks=x.microTask,Oh(e),Ih(e)):"macroTask"==x.change&&(e.hasPendingMacrotasks=x.macroTask))},onHandleError:(l,p,g,x)=>(l.handleError(g,x),e.runOutsideAngular(()=>e.onError.emit(x)),!1)})}(x)}static isInAngularZone(){return typeof Zone<"u"&&!0===Zone.current.get(xc)}static assertInAngularZone(){if(!os.isInAngularZone())throw new Rn(909,!1)}static assertNotInAngularZone(){if(os.isInAngularZone())throw new Rn(909,!1)}run(t,n,l){return this._inner.run(t,n,l)}runTask(t,n,l,p){const g=this._inner,x=g.scheduleEventTask("NgZoneEvent: "+p,t,Of,_u,_u);try{return g.runTask(x,n,l)}finally{g.cancelTask(x)}}runGuarded(t,n,l){return this._inner.runGuarded(t,n,l)}runOutsideAngular(t){return this._outer.run(t)}}const Of={};function Ih(e){if(0==e._nesting&&!e.hasPendingMicrotasks&&!e.isStable)try{e._nesting++,e.onMicrotaskEmpty.emit(null)}finally{if(e._nesting--,!e.hasPendingMicrotasks)try{e.runOutsideAngular(()=>e.onStable.emit(null))}finally{e.isStable=!0}}}function Oh(e){e.hasPendingMicrotasks=!!(e._hasPendingMicrotasks||(e.shouldCoalesceEventChangeDetection||e.shouldCoalesceRunChangeDetection)&&!0===e.callbackScheduled)}function Nf(e){e._nesting++,e.isStable&&(e.isStable=!1,e.onUnstable.emit(null))}function vu(e){e._nesting--,Ih(e)}class Rh{hasPendingMicrotasks=!1;hasPendingMacrotasks=!1;isStable=!0;onUnstable=new oc;onMicrotaskEmpty=new oc;onStable=new oc;onError=new oc;run(t,n,l){return t.apply(n,l)}runGuarded(t,n,l){return t.apply(n,l)}runOutsideAngular(t){return t()}runTask(t,n,l,p){return t.apply(n,l)}}function Lf(e,t){return!(!Array.isArray(e)||1!==e.length)&&!0===e[0]?.data?.[t]}class Cc{_console=console;handleError(t){this._console.error("ERROR",t)}}const qu=new ht("",{providedIn:"root",factory:()=>{const e=lr(os),t=lr(Cc);return n=>e.runOutsideAngular(()=>t.handleError(n))}});function Pf(e,t){return z(e,t)}const $g=(Pf.required=function bu(e){return z(cn,e)},Pf);function wu(){return Dc(Si(),En())}function Dc(e,t){return new Os(rs(e,t))}let Os=(()=>class e{nativeElement;constructor(n){this.nativeElement=n}static __NG_ELEMENT_ID__=wu})();function Nh(e){return e instanceof Os?e.nativeElement:e}function Nd(){return this._results[Symbol.iterator]()}class Ff{_emitDistinctChangesOnly;dirty=!0;_onDirty=void 0;_results=[];_changesDetected=!1;_changes=void 0;length=0;first=void 0;last=void 0;get changes(){return this._changes??=new rt.B}constructor(t=!1){this._emitDistinctChangesOnly=t}get(t){return this._results[t]}map(t){return this._results.map(t)}filter(t){return this._results.filter(t)}find(t){return this._results.find(t)}reduce(t,n){return this._results.reduce(t,n)}forEach(t){this._results.forEach(t)}some(t){return this._results.some(t)}toArray(){return this._results.slice()}toString(){return this._results.toString()}reset(t,n){this.dirty=!1;const l=function lo(e){return e.flat(Number.POSITIVE_INFINITY)}(t);(this._changesDetected=!function Bo(e,t,n){if(e.length!==t.length)return!1;for(let l=0;lYh}),Yh="ng",sd=new ht(""),b=new ht("",{providedIn:"platform",factory:()=>"unknown"}),A=new ht(""),j=new ht("",{providedIn:"root",factory:()=>nl().body?.querySelector("[ngCspNonce]")?.getAttribute("ngCspNonce")||null}),to=new ht("",{providedIn:"root",factory:()=>!1}),yr=new Set;function oi(e){yr.has(e)||(yr.add(e),performance?.mark?.("mark_feature_usage",{detail:{feature:e}}))}var Wi=function(e){return e[e.EarlyRead=0]="EarlyRead",e[e.Write=1]="Write",e[e.MixedReadWrite=2]="MixedReadWrite",e[e.Read=3]="Read",e}(Wi||{});let Bs=(()=>{class e{impl=null;execute(){this.impl?.execute()}static \u0275prov=ai({token:e,providedIn:"root",factory:()=>new e})}return e})();const Na=[Wi.EarlyRead,Wi.Write,Wi.MixedReadWrite,Wi.Read];let rl=(()=>{class e{ngZone=lr(os);scheduler=lr(rc);errorHandler=lr(Cc,{optional:!0});sequences=new Set;deferredRegistrations=new Set;executing=!1;execute(){this.executing=!0;for(const n of Na)for(const l of this.sequences)if(!l.erroredOrDestroyed&&l.hooks[n])try{l.pipelinedValue=this.ngZone.runOutsideAngular(()=>l.hooks[n](l.pipelinedValue))}catch(p){l.erroredOrDestroyed=!0,this.errorHandler?.handleError(p)}this.executing=!1;for(const n of this.sequences)n.afterRun(),n.once&&(this.sequences.delete(n),n.destroy());for(const n of this.deferredRegistrations)this.sequences.add(n);this.deferredRegistrations.size>0&&this.scheduler.notify(8),this.deferredRegistrations.clear()}register(n){this.executing?this.deferredRegistrations.add(n):(this.sequences.add(n),this.scheduler.notify(7))}unregister(n){this.executing&&this.sequences.has(n)?(n.erroredOrDestroyed=!0,n.pipelinedValue=void 0,n.once=!0):(this.sequences.delete(n),this.deferredRegistrations.delete(n))}static \u0275prov=ai({token:e,providedIn:"root",factory:()=>new e})}return e})();class gl{impl;hooks;once;erroredOrDestroyed=!1;pipelinedValue=void 0;unregisterOnDestroy;constructor(t,n,l,p){this.impl=t,this.hooks=n,this.once=l,this.unregisterOnDestroy=p?.onDestroy(()=>this.destroy())}afterRun(){this.erroredOrDestroyed=!1,this.pipelinedValue=void 0}destroy(){this.impl.unregister(this),this.unregisterOnDestroy?.()}}function ba(e,t){!t?.injector&&Sa();const n=t?.injector??lr(Qo);return typeof ngServerMode<"u"&&ngServerMode?$d:(oi("NgAfterRender"),Vc(e,n,t,!1))}function Xa(e,t){!t?.injector&&Sa();const n=t?.injector??lr(Qo);return typeof ngServerMode<"u"&&ngServerMode?$d:(oi("NgAfterNextRender"),Vc(e,n,t,!0))}function Vc(e,t,n,l){const p=t.get(Bs);p.impl??=t.get(rl);const g=n?.phase??Wi.MixedReadWrite,x=!0!==n?.manualCleanup?t.get(ws):null,k=new gl(p.impl,function wa(e,t){if(e instanceof Function){const n=[void 0,void 0,void 0,void 0];return n[t]=e,n}return[e.earlyRead,e.write,e.mixedReadWrite,e.read]}(e,g),l,x);return p.impl.register(k),k}const $d={destroy(){}};let Jg=()=>null;function ip(e,t,n=!1){return Jg(e,t,n)}var Sc=function(e){return e[e.Emulated=0]="Emulated",e[e.None=2]="None",e[e.ShadowDom=3]="ShadowDom",e}(Sc||{});let ld,ap;function Kd(e){return function Tm(){if(void 0===ld&&(ld=null,dn.trustedTypes))try{ld=dn.trustedTypes.createPolicy("angular",{createHTML:e=>e,createScript:e=>e,createScriptURL:e=>e})}catch{}return ld}()?.createHTML(e)||e}function Mm(){if(void 0===ap&&(ap=null,dn.trustedTypes))try{ap=dn.trustedTypes.createPolicy("angular#unsafe-bypass",{createHTML:e=>e,createScript:e=>e,createScriptURL:e=>e})}catch{}return ap}function l_(e){return Mm()?.createHTML(e)||e}function u_(e){return Mm()?.createScriptURL(e)||e}class cd{changingThisBreaksApplicationSecurity;constructor(t){this.changingThisBreaksApplicationSecurity=t}toString(){return`SafeValue must use [property]=binding: ${this.changingThisBreaksApplicationSecurity} (see ${Nr})`}}class Ry extends cd{getTypeName(){return"HTML"}}class Ny extends cd{getTypeName(){return"Style"}}class lp extends cd{getTypeName(){return"Script"}}class Ly extends cd{getTypeName(){return"URL"}}class Py extends cd{getTypeName(){return"ResourceURL"}}function Gc(e){return e instanceof cd?e.changingThisBreaksApplicationSecurity:e}function Gd(e,t){const n=function Fy(e){return e instanceof cd&&e.getTypeName()||null}(e);if(null!=n&&n!==t){if("ResourceURL"===n&&"URL"===t)return!0;throw new Error(`Required a safe ${t}, got a ${n} (see ${Nr})`)}return n===t}function By(e){return new Ry(e)}function Uy(e){return new Ny(e)}function $y(e){return new lp(e)}function jy(e){return new Ly(e)}function Vy(e){return new Py(e)}class km{inertDocumentHelper;constructor(t){this.inertDocumentHelper=t}getInertBodyElement(t){t=""+t;try{const n=(new window.DOMParser).parseFromString(Kd(t),"text/html").body;return null===n?this.inertDocumentHelper.getInertBodyElement(t):(n.firstChild?.remove(),n)}catch{return null}}}class Hy{defaultDoc;inertDocument;constructor(t){this.defaultDoc=t,this.inertDocument=this.defaultDoc.implementation.createHTMLDocument("sanitization-inert")}getInertBodyElement(t){const n=this.inertDocument.createElement("template");return n.innerHTML=Kd(t),n}}const Im=/^(?!javascript:)(?:[a-z0-9+.-]+:|[^&:\/?#]*(?:[\/?#]|$))/i;function cp(e){return(e=String(e)).match(Im)?e:"unsafe:"+e}function Xc(e){const t={};for(const n of e.split(","))t[n]=!0;return t}function sf(...e){const t={};for(const n of e)for(const l in n)n.hasOwnProperty(l)&&(t[l]=!0);return t}const h_=Xc("area,br,col,hr,img,wbr"),f_=Xc("colgroup,dd,dt,li,p,tbody,td,tfoot,th,thead,tr"),p_=Xc("rp,rt"),Om=sf(h_,sf(f_,Xc("address,article,aside,blockquote,caption,center,del,details,dialog,dir,div,dl,figure,figcaption,footer,h1,h2,h3,h4,h5,h6,header,hgroup,hr,ins,main,map,menu,nav,ol,pre,section,summary,table,ul")),sf(p_,Xc("a,abbr,acronym,audio,b,bdi,bdo,big,br,cite,code,del,dfn,em,font,i,img,ins,kbd,label,map,mark,picture,q,ruby,rp,rt,s,samp,small,source,span,strike,strong,sub,sup,time,track,tt,u,var,video")),sf(p_,f_)),up=Xc("background,cite,href,itemtype,longdesc,poster,src,xlink:href"),g_=sf(up,Xc("abbr,accesskey,align,alt,autoplay,axis,bgcolor,border,cellpadding,cellspacing,class,clear,color,cols,colspan,compact,controls,coords,datetime,default,dir,download,face,headers,height,hidden,hreflang,hspace,ismap,itemscope,itemprop,kind,label,lang,language,loop,media,muted,nohref,nowrap,open,preload,rel,rev,role,rows,rowspan,rules,scope,scrolling,shape,size,sizes,span,srclang,srcset,start,summary,tabindex,target,title,translate,type,usemap,valign,value,vspace,width"),Xc("aria-activedescendant,aria-atomic,aria-autocomplete,aria-busy,aria-checked,aria-colcount,aria-colindex,aria-colspan,aria-controls,aria-current,aria-describedby,aria-details,aria-disabled,aria-dropeffect,aria-errormessage,aria-expanded,aria-flowto,aria-grabbed,aria-haspopup,aria-hidden,aria-invalid,aria-keyshortcuts,aria-label,aria-labelledby,aria-level,aria-live,aria-modal,aria-multiline,aria-multiselectable,aria-orientation,aria-owns,aria-placeholder,aria-posinset,aria-pressed,aria-readonly,aria-relevant,aria-required,aria-roledescription,aria-rowcount,aria-rowindex,aria-rowspan,aria-selected,aria-setsize,aria-sort,aria-valuemax,aria-valuemin,aria-valuenow,aria-valuetext")),Ky=Xc("script,style,template");class Gy{sanitizedSomething=!1;buf=[];sanitizeChildren(t){let n=t.firstChild,l=!0,p=[];for(;n;)if(n.nodeType===Node.ELEMENT_NODE?l=this.startElement(n):n.nodeType===Node.TEXT_NODE?this.chars(n.nodeValue):this.sanitizedSomething=!0,l&&n.firstChild)p.push(n),n=Yy(n);else for(;n;){n.nodeType===Node.ELEMENT_NODE&&this.endElement(n);let g=Xy(n);if(g){n=g;break}n=p.pop()}return this.buf.join("")}startElement(t){const n=v_(t).toLowerCase();if(!Om.hasOwnProperty(n))return this.sanitizedSomething=!0,!Ky.hasOwnProperty(n);this.buf.push("<"),this.buf.push(n);const l=t.attributes;for(let p=0;p"),!0}endElement(t){const n=v_(t).toLowerCase();Om.hasOwnProperty(n)&&!h_.hasOwnProperty(n)&&(this.buf.push(""))}chars(t){this.buf.push(Nm(t))}}function Xy(e){const t=e.nextSibling;if(t&&e!==t.previousSibling)throw Rm(t);return t}function Yy(e){const t=e.firstChild;if(t&&function __(e,t){return(e.compareDocumentPosition(t)&Node.DOCUMENT_POSITION_CONTAINED_BY)!==Node.DOCUMENT_POSITION_CONTAINED_BY}(e,t))throw Rm(t);return t}function v_(e){const t=e.nodeName;return"string"==typeof t?t:"FORM"}function Rm(e){return new Error(`Failed to sanitize html because the element is clobbered: ${e.outerHTML}`)}const Qy=/[\uD800-\uDBFF][\uDC00-\uDFFF]/g,Zy=/([^\#-~ |!])/g;function Nm(e){return e.replace(/&/g,"&").replace(Qy,function(t){return"&#"+(1024*(t.charCodeAt(0)-55296)+(t.charCodeAt(1)-56320)+65536)+";"}).replace(Zy,function(t){return"&#"+t.charCodeAt(0)+";"}).replace(//g,">")}let dp;function Lm(e,t){let n=null;try{dp=dp||function d_(e){const t=new Hy(e);return function Wy(){try{return!!(new window.DOMParser).parseFromString(Kd(""),"text/html")}catch{return!1}}()?new km(t):t}(e);let l=t?String(t):"";n=dp.getInertBodyElement(l);let p=5,g=l;do{if(0===p)throw new Error("Failed to sanitize html because the input is unstable");p--,l=g,g=n.innerHTML,n=dp.getInertBodyElement(l)}while(l!==g);return Kd((new Gy).sanitizeChildren(Pm(n)||n))}finally{if(n){const l=Pm(n)||n;for(;l.firstChild;)l.firstChild.remove()}}}function Pm(e){return"content"in e&&function qy(e){return e.nodeType===Node.ELEMENT_NODE&&"TEMPLATE"===e.nodeName}(e)?e.content:null}var ud=function(e){return e[e.NONE=0]="NONE",e[e.HTML=1]="HTML",e[e.STYLE=2]="STYLE",e[e.SCRIPT=3]="SCRIPT",e[e.URL=4]="URL",e[e.RESOURCE_URL=5]="RESOURCE_URL",e}(ud||{});function y_(e){const t=dd();return t?l_(t.sanitize(ud.HTML,e)||""):Gd(e,"HTML")?l_(Gc(e)):Lm(nl(),Or(e))}function Xd(e){const t=dd();return t?t.sanitize(ud.URL,e)||"":Gd(e,"URL")?Gc(e):cp(Or(e))}function Fm(e){const t=dd();if(t)return u_(t.sanitize(ud.RESOURCE_URL,e)||"");if(Gd(e,"ResourceURL"))return u_(Gc(e));throw new Rn(904,!1)}function b_(e,t,n){return function $m(e,t){return"src"===t&&("embed"===e||"frame"===e||"iframe"===e||"media"===e||"script"===e)||"href"===t&&("base"===e||"link"===e)?Fm:Xd}(t,n)(e)}function dd(){const e=En();return e&&e[co].sanitizer}const E_=/^>|^->||--!>|)/g,x_="\u200b$1\u200b";function Al(e){return e instanceof Function?e():e}var ku=function(e){return e[e.None=0]="None",e[e.SignalBased=1]="SignalBased",e[e.HasDecoratorInputTransform=2]="HasDecoratorInputTransform",e}(ku||{}),mp=function(e){return e[e.Important=1]="Important",e[e.DashCase=2]="DashCase",e}(mp||{});let Hm;function Wm(e,t){return Hm(e,t)}function Zd(e,t,n,l,p){if(null!=l){let g,x=!1;wi(l)?g=l:ii(l)&&(x=!0,l=l[oo]);const k=qi(l);0===e&&null!==n?null==p?z_(t,n,k):hd(t,n,k,p||null,!0):1===e&&null!==n?hd(t,n,k,p||null,!0):2===e?function cf(e,t,n){e.removeChild(null,t,n)}(t,k,x):3===e&&t.destroyNode(k),null!=g&&function J_(e,t,n,l,p){const g=n[ci];g!==qi(n)&&Zd(t,e,l,g,p);for(let k=Rr;kt.replace(Yd,x_))}(t))}function gp(e,t,n){return e.createElement(t,n)}function j_(e,t){t[co].changeDetectionScheduler?.notify(10),Ep(e,t,t[ri],2,null,null)}function V_(e,t){const n=e[Di],l=t[Oi];(ii(l)||t[vo]!==l[Oi][vo])&&(e[Sr]|=li.HasTransplantedViews),null===n?e[Di]=[t]:n.push(t)}function _p(e,t){const n=e[Di],l=n.indexOf(t);n.splice(l,1)}function af(e,t){if(e.length<=Rr)return;const n=Rr+t,l=e[n];if(l){const p=l[Ci];null!==p&&p!==e&&_p(p,l),t>0&&(e[n-1][ys]=l[ys]);const g=Ms(e,Rr+t);!function $_(e,t){j_(e,t),t[oo]=null,t[Qi]=null}(l[Fn],l);const x=g[uo];null!==x&&x.detachView(g[Fn]),l[Oi]=null,l[ys]=null,l[Sr]&=-129}return l}function lf(e,t){if(!(256&t[Sr])){const n=t[ri];n.destroyNode&&Ep(e,t,n,3,null,null),function ob(e){let t=e[Xs];if(!t)return Gm(e[Fn],e);for(;t;){let n=null;if(ii(t))n=t[Xs];else{const l=t[Rr];l&&(n=l)}if(!n){for(;t&&!t[ys]&&t!==e;)ii(t)&&Gm(t[Fn],t),t=t[Oi];null===t&&(t=e),ii(t)&&Gm(t[Fn],t),n=t&&t[ys]}t=n}}(t)}}function Gm(e,t){if(256&t[Sr])return;const n=T(null);try{t[Sr]&=-129,t[Sr]|=256,t[Et]&&De(t[Et]),function vp(e,t){let n;if(null!=e&&null!=(n=e.destroyHooks))for(let l=0;l=0?l[k]():l[-k].unsubscribe(),x+=2}else n[x].call(l[n[x+1]]);null!==l&&(t[Bi]=null);const p=t[Ie];if(null!==p){t[Ie]=null;for(let x=0;x-1){const{encapsulation:g}=e.data[l.directiveStart+p];if(g===Sc.None||g===Sc.Emulated)return null}return rs(l,n)}}(e,t.parent,n)}function hd(e,t,n,l,p){e.insertBefore(t,n,l,p)}function z_(e,t,n){e.appendChild(t,n)}function K_(e,t,n,l,p){null!==l?hd(e,t,n,l,p):z_(e,t,n)}function Xm(e,t){return e.parentNode(t)}function Ym(e,t,n){return X_(e,t,n)}let Qm,X_=function G_(e,t,n){return 40&e.type?rs(e,n):null};function bp(e,t,n,l){const p=yp(e,l,t),g=t[ri],k=Ym(l.parent||t[Qi],l,t);if(null!=p)if(Array.isArray(n))for(let B=0;B-1){let g;for(;++pg?"":p[Se+1].toLowerCase(),2&l&&ie!==He){if(uc(l))return!1;x=!0}}}}else{if(!x&&!uc(l)&&!uc(B))return!1;if(x&&uc(B))continue;x=!1,l=B|1&l}}return uc(l)||x}function uc(e){return!(1&e)}function mb(e,t,n,l){if(null===t)return-1;let p=0;if(l||!n){let g=!1;for(;p-1)for(n++;n0?'="'+k+'"':"")+"]"}else 8&l?p+="."+x:4&l&&(p+=" "+x);else""!==p&&!uc(x)&&(t+=uf(g,p),p=""),l=x,g=g||!uc(l);n++}return""!==p&&(t+=uf(g,p)),t}const $i={};function xp(e=1){Eb(pi(),En(),$n()+e,!1)}function Eb(e,t,n,l){if(!l)if(3&~t[Sr]){const g=e.preOrderHooks;null!==g&&Hi(t,g,0,n)}else{const g=e.preOrderCheckHooks;null!==g&&jr(t,g,n)}Ir(n)}function qd(e,t=bi.Default){const n=En();return null===n?_o(e,t):yh(Si(),n,Ge(e),t)}function iv(){throw new Error("invalid")}function Jm(e,t,n,l,p,g){const x=T(null);try{let k=null;p&ku.SignalBased&&(k=t[l][C]),null!==k&&void 0!==k.transformFn&&(g=k.transformFn(g)),p&ku.HasDecoratorInputTransform&&(g=e.inputTransforms[l].call(t,g)),null!==e.setInput?e.setInput(t,k,g,n,l):Hs(t,k,l,g)}finally{T(x)}}function df(e,t,n,l,p,g,x,k,B,ie,Se){const He=t.blueprint.slice();return He[oo]=p,He[Sr]=1228|l,(null!==ie||e&&2048&e[Sr])&&(He[Sr]|=2048),on(He),He[Oi]=He[Uo]=e,He[Ki]=n,He[co]=x||e&&e[co],He[ri]=k||e&&e[ri],He[no]=B||e&&e[no]||null,He[Qi]=g,He[Ui]=function Bf(){return xu++}(),He[so]=Se,He[U]=ie,He[vo]=2==t.type?e[vo]:He,He}function fd(e,t,n,l,p){let g=e.data[t];if(null===g)g=function eg(e,t,n,l,p){const g=Nl(),x=Oc(),B=e.data[t]=function er(e,t,n,l,p,g){let x=t?t.injectorIndex:-1,k=0;return _c()&&(k|=128),{type:n,index:l,insertBeforeIndex:null,injectorIndex:x,directiveStart:-1,directiveEnd:-1,directiveStylingLast:-1,componentOffset:-1,propertyBindings:null,flags:k,providerIndexes:0,value:p,attrs:g,mergedAttrs:null,localNames:null,initialInputs:void 0,inputs:null,outputs:null,tView:null,next:null,prev:null,projectionNext:null,child:null,parent:t,projection:null,styles:null,stylesWithoutHost:null,residualStyles:void 0,classes:null,classesWithoutHost:null,residualClasses:void 0,classBindings:0,styleBindings:0}}(0,x?g:g&&g.parent,n,t,l,p);return null===e.firstChild&&(e.firstChild=B),null!==g&&(x?null==g.child&&null!==B.parent&&(g.child=B):null===g.next&&(g.next=B,B.prev=g)),B}(e,t,n,l,p),function $(){return Wr.lFrame.inI18n}()&&(g.flags|=32);else if(64&g.type){g.type=n,g.value=l,g.attrs=p;const x=function Ra(){const e=Wr.lFrame,t=e.currentTNode;return e.isParent?t:t.parent}();g.injectorIndex=null===x?-1:x.injectorIndex}return Qs(g,!0),g}function hf(e,t,n,l){if(0===n)return-1;const p=t.length;for(let g=0;gGt&&Eb(e,t,Gt,!1),za(x?2:0,p),n(l,p)}finally{Ir(g),za(x?3:1,p)}}function m(e,t,n){if(bs(t)){const l=T(null);try{const g=t.directiveEnd;for(let x=t.directiveStart;xnull;function fr(e,t,n,l,p){for(let g in t){if(!t.hasOwnProperty(g))continue;const x=t[g];if(void 0===x)continue;l??={};let k,B=ku.None;Array.isArray(x)?(k=x[0],B=x[1]):k=x;let ie=g;if(null!==p){if(!p.hasOwnProperty(g))continue;ie=p[g]}0===e?ti(l,n,ie,k,B):ti(l,n,ie,k)}return l}function ti(e,t,n,l,p){let g;e.hasOwnProperty(n)?(g=e[n]).push(t,l):g=e[n]=[t,l],void 0!==p&&g.push(p)}function ho(e,t,n,l,p,g,x,k){const B=rs(t,n);let Se,ie=t.inputs;!k&&null!=ie&&(Se=ie[l])?(Cb(e,n,Se,l,p),Lo(t)&&function Ea(e,t){const n=K(t,e);16&n[Sr]||(n[Sr]|=64)}(n,t.index)):3&t.type&&(l=function ko(e){return"class"===e?"className":"for"===e?"htmlFor":"formaction"===e?"formAction":"innerHtml"===e?"innerHTML":"readonly"===e?"readOnly":"tabindex"===e?"tabIndex":e}(l),p=null!=x?x(p,t.value||"",l):p,g.setProperty(B,l,p))}function vl(e,t,n,l){if(hh()){const p=null===l?null:{"":-1},g=function tg(e,t){const n=e.directiveRegistry;let l=null,p=null;if(n)for(let g=0;g0;){const n=e[--t];if("number"==typeof n&&n<0)return n}return 0})(x)!=k&&x.push(k),x.push(n,l,g)}}(e,t,l,hf(e,n,p.hostVars,$i),p)}function xo(e){let t=16;return e.signals?t=4096:e.onPush&&(t=64),t}function na(e,t,n,l,p,g){const x=rs(e,t);!function sl(e,t,n,l,p,g,x){if(null==g)e.removeAttribute(t,p,n);else{const k=null==x?Or(g):x(g,l||"",p);e.setAttribute(t,p,k,n)}}(t[ri],x,g,e.value,n,l,p)}function Ru(e,t,n,l,p,g){const x=g[t];if(null!==x)for(let k=0;k0&&(n[p-1][ys]=t),l{Is(e.lView)},consumerOnSignalRead(){this.lView[Et]=this}},xD={...L,consumerIsAlwaysLive:!0,consumerMarkedDirty:e=>{let t=us(e.lView);for(;t&&!e1(t[Fn]);)t=us(t);t&&ur(t)},consumerOnSignalRead(){this.lView[Et]=this}};function e1(e){return 2!==e.type}function t1(e){if(null===e[ye])return;let t=!0;for(;t;){let n=!1;for(const l of e[ye])l.dirty&&(n=!0,null===l.zone||Zone.current===l.zone?l.run():l.zone.run(()=>l.run()));t=n&&!!(8192&e[Sr])}}const CD=100;function cv(e,t=!0,n=0){const p=e[co].rendererFactory;p.begin?.();try{!function DD(e,t){const n=ma();try{ql(!0),Sb(e,t);let l=0;for(;kr(e);){if(l===CD)throw new Rn(103,!1);l++,Sb(e,1)}}finally{ql(n)}}(e,n)}catch(x){throw t&&av(e,x),x}finally{p.end?.()}}function r1(e,t,n,l){const p=t[Sr];if(!(256&~p))return;Gn(t);let k=!0,B=null,ie=null;e1(e)?(ie=function vD(e){return e[Et]??function yD(e){const t=Jw.pop()??Object.create(wD);return t.lView=e,t}(e)}(t),B=be(ie)):null===function S(){return c}()?(k=!1,ie=function ED(e){const t=e[Et]??Object.create(xD);return t.lView=e,t}(t),B=be(ie)):t[Et]&&(De(t[Et]),t[Et]=null);try{on(t),function yd(e){return Wr.lFrame.bindingIndex=e}(e.bindingStartIndex),null!==n&&v(e,t,n,2,l);const Se=!(3&~p);if(Se){const Ut=e.preOrderCheckHooks;null!==Ut&&jr(t,Ut,null)}else{const Ut=e.preOrderHooks;null!==Ut&&Hi(t,Ut,0,null),Yi(t,0)}if(function AD(e){for(let t=lc(e);null!==t;t=Vh(t)){if(!(t[Sr]&li.HasTransplantedViews))continue;const n=t[Di];for(let l=0;l-1&&(af(t,l),Ms(n,l))}this._attachedToViewContainer=!1}lf(this._lView[Fn],this._lView)}onDestroy(t){is(this._lView,t)}markForCheck(){ig(this._cdRefInjectingView||this._lView,4)}markForRefresh(){ur(this._cdRefInjectingView||this._lView)}detach(){this._lView[Sr]&=-129}reattach(){Gi(this._lView),this._lView[Sr]|=128}detectChanges(){this._lView[Sr]|=1024,cv(this._lView,this.notifyErrorHandler)}checkNoChanges(){}attachToViewContainerRef(){if(this._appRef)throw new Rn(902,!1);this._attachedToViewContainer=!0}detachFromAppRef(){this._appRef=null;const t=Ha(this._lView),n=this._lView[Ci];null!==n&&!t&&_p(n,this._lView),j_(this._lView[Fn],this._lView)}attachToAppRef(t){if(this._attachedToViewContainer)throw new Rn(902,!1);this._appRef=t;const n=Ha(this._lView),l=this._lView[Ci];null!==l&&!n&&V_(l,this._lView),Gi(this._lView)}}let sg=(()=>class e{static __NG_ELEMENT_ID__=kD})();const TD=sg,MD=class extends TD{_declarationLView;_declarationTContainer;elementRef;constructor(t,n,l){super(),this._declarationLView=t,this._declarationTContainer=n,this.elementRef=l}get ssrId(){return this._declarationTContainer.tView?.ssrId||null}createEmbeddedView(t,n){return this.createEmbeddedViewImpl(t,n)}createEmbeddedViewImpl(t,n,l){const p=Ap(this._declarationLView,this._declarationTContainer,t,{embeddedViewInjector:n,dehydratedView:l});return new og(p)}};function kD(){return uv(Si(),En())}function uv(e,t){return 4&e.type?new MD(t,e,Dc(e,t)):null}class UD{resolveComponentFactory(t){throw Error(`No component factory found for ${Tr(t)}.`)}}class hv{static NULL=new UD}class gf{}class c1{}class $D{}class u1{}class Ib{}let jD=(()=>class e{destroyNode=null;static __NG_ELEMENT_ID__=()=>function VD(){const e=En(),n=K(Si().index,e);return(ii(n)?n:e)[ri]}()})(),HD=(()=>{class e{static \u0275prov=ai({token:e,providedIn:"root",factory:()=>null})}return e})();function Jd(e){return!!fi(e)}function pv(e,t,n){let l=n?e.styles:null,p=n?e.classes:null,g=0;if(null!==t)for(let x=0;x0&&ev(e,n,g.join(" "))}}(Nt,ia,qt,l),void 0!==n&&function JD(e,t,n){const l=e.projection=[];for(let p=0;pn()),this.destroyCbs=null}onDestroy(t){this.destroyCbs.push(t)}}class Lb extends c1{moduleType;constructor(t){super(),this.moduleType=t}create(t){return new Nb(this.moduleType,t,[])}}class m1 extends gf{injector;componentFactoryResolver=new f1(this);instance=null;constructor(t){super();const n=new vs([...t.providers,{provide:gf,useValue:this},{provide:hv,useValue:this.componentFactoryResolver}],t.parent||_i(),t.debugName,new Set(["environment"]));this.injector=n,t.runEnvironmentInitializers&&n.resolveInjectorInitializers()}destroy(){this.injector.destroy()}onDestroy(t){this.injector.onDestroy(t)}}function Pb(e,t,n=null){return new m1({providers:e,parent:t,debugName:n,runEnvironmentInitializers:!0}).injector}let rA=(()=>{class e{_injector;cachedInjectors=new Map;constructor(n){this._injector=n}getOrCreateStandaloneInjector(n){if(!n.standalone)return null;if(!this.cachedInjectors.has(n)){const l=$a(0,n.type),p=l.length>0?Pb([l],this._injector,`Standalone[${n.type.name}]`):null;this.cachedInjectors.set(n,p)}return this.cachedInjectors.get(n)}ngOnDestroy(){try{for(const n of this.cachedInjectors.values())null!==n&&n.destroy()}finally{this.cachedInjectors.clear()}}static \u0275prov=ai({token:e,providedIn:"environment",factory:()=>new e(_o(cs))})}return e})();function g1(e){return N(()=>{const t=b1(e),n={...t,decls:e.decls,vars:e.vars,template:e.template,consts:e.consts||null,ngContentSelectors:e.ngContentSelectors,onPush:e.changeDetection===sc.OnPush,directiveDefs:null,pipeDefs:null,dependencies:t.standalone&&e.dependencies||null,getStandaloneInjector:t.standalone?p=>p.get(rA).getOrCreateStandaloneInjector(n):null,getExternalStyles:null,signals:e.signals??!1,data:e.data||{},encapsulation:e.encapsulation||Sc.Emulated,styles:e.styles||Wn,_:null,schemas:e.schemas||null,tView:null,id:""};t.standalone&&oi("NgStandalone"),w1(n);const l=e.dependencies;return n.directiveDefs=mv(l,!1),n.pipeDefs=mv(l,!0),n.id=function aA(e){let t=0;const n=[e.selectors,e.ngContentSelectors,e.hostVars,e.hostAttrs,e.consts,e.vars,e.decls,e.encapsulation,e.standalone,e.signals,e.exportAs,JSON.stringify(e.inputs),JSON.stringify(e.outputs),Object.getOwnPropertyNames(e.type.prototype),!!e.contentQueries,!!e.viewQuery].join("|");for(const p of n)t=Math.imul(31,t)+p.charCodeAt(0)|0;return t+=2147483648,"c"+t}(n),n})}function iA(e){return zr(e)||di(e)}function oA(e){return null!==e}function Fb(e){return N(()=>({type:e.type,bootstrap:e.bootstrap||Wn,declarations:e.declarations||Wn,imports:e.imports||Wn,exports:e.exports||Wn,transitiveCompileScopes:null,schemas:e.schemas||null,id:e.id||null}))}function _1(e,t){if(null==e)return On;const n={};for(const l in e)if(e.hasOwnProperty(l)){const p=e[l];let g,x,k=ku.None;Array.isArray(p)?(k=p[0],g=p[1],x=p[2]??g):(g=p,x=p),t?(n[g]=k!==ku.None?[l,k]:l,t[g]=x):n[g]=l}return n}function v1(e){return N(()=>{const t=b1(e);return w1(t),t})}function y1(e){return{type:e.type,name:e.name,factory:null,pure:!1!==e.pure,standalone:e.standalone??!0,onDestroy:e.type.prototype.ngOnDestroy||null}}function b1(e){const t={};return{type:e.type,providersResolver:null,factory:null,hostBindings:e.hostBindings||null,hostVars:e.hostVars||0,hostAttrs:e.hostAttrs||null,contentQueries:e.contentQueries||null,declaredInputs:t,inputTransforms:null,inputConfig:e.inputs||On,exportAs:e.exportAs||null,standalone:e.standalone??!0,signals:!0===e.signals,selectors:e.selectors||Wn,viewQuery:e.viewQuery||null,features:e.features||null,setInput:null,findHostDirectiveDefs:null,hostDirectives:null,inputs:_1(e.inputs,t),outputs:_1(e.outputs),debugInfo:null}}function w1(e){e.features?.forEach(t=>t(e))}function mv(e,t){if(!e)return null;const n=t?Fi:iA;return()=>("function"==typeof e?e():e).map(l=>n(l)).filter(oA)}let x1=(()=>{class e{log(n){console.log(n)}warn(n){console.warn(n)}static \u0275fac=function(l){return new(l||e)};static \u0275prov=ai({token:e,factory:e.\u0275fac,providedIn:"platform"})}return e})();function Bb(e){return"function"==typeof e&&void 0!==e[C]}const A1="ng";function NA(e,t){!function T1(e,t){if(typeof COMPILED>"u"||!COMPILED){const n=dn;n[A1]??={},n[A1][e]=t}}(e,t)}const M1=new ht(""),k1=new ht("");let $b,LA=(()=>{class e{_ngZone;registry;_isZoneStable=!0;_callbacks=[];taskTrackingZone=null;constructor(n,l,p){this._ngZone=n,this.registry=l,$b||(function PA(e){$b=e}(p),p.addToWindow(l)),this._watchAngularEvents(),n.run(()=>{this.taskTrackingZone=typeof Zone>"u"?null:Zone.current.get("TaskTrackingZone")})}_watchAngularEvents(){this._ngZone.onUnstable.subscribe({next:()=>{this._isZoneStable=!1}}),this._ngZone.runOutsideAngular(()=>{this._ngZone.onStable.subscribe({next:()=>{os.assertNotInAngularZone(),queueMicrotask(()=>{this._isZoneStable=!0,this._runCallbacksIfReady()})}})})}isStable(){return this._isZoneStable&&!this._ngZone.hasPendingMacrotasks}_runCallbacksIfReady(){if(this.isStable())queueMicrotask(()=>{for(;0!==this._callbacks.length;){let n=this._callbacks.pop();clearTimeout(n.timeoutId),n.doneCb()}});else{let n=this.getPendingTasks();this._callbacks=this._callbacks.filter(l=>!l.updateCb||!l.updateCb(n)||(clearTimeout(l.timeoutId),!1))}}getPendingTasks(){return this.taskTrackingZone?this.taskTrackingZone.macroTasks.map(n=>({source:n.source,creationLocation:n.creationLocation,data:n.data})):[]}addCallback(n,l,p){let g=-1;l&&l>0&&(g=setTimeout(()=>{this._callbacks=this._callbacks.filter(x=>x.timeoutId!==g),n()},l)),this._callbacks.push({doneCb:n,timeoutId:g,updateCb:p})}whenStable(n,l,p){if(p&&!this.taskTrackingZone)throw new Error('Task tracking zone is required when passing an update callback to whenStable(). Is "zone.js/plugins/task-tracking" loaded?');this.addCallback(n,l,p),this._runCallbacksIfReady()}registerApplication(n){this.registry.registerApplication(n,this)}unregisterApplication(n){this.registry.unregisterApplication(n)}findProviders(n,l,p){return[]}static \u0275fac=function(l){return new(l||e)(_o(os),_o(I1),_o(k1))};static \u0275prov=ai({token:e,factory:e.\u0275fac})}return e})(),I1=(()=>{class e{_applications=new Map;registerApplication(n,l){this._applications.set(n,l)}unregisterApplication(n){this._applications.delete(n)}unregisterAllApplications(){this._applications.clear()}getTestability(n){return this._applications.get(n)||null}getAllTestabilities(){return Array.from(this._applications.values())}getAllRootElements(){return Array.from(this._applications.keys())}findTestabilityInTree(n,l=!0){return $b?.findTestabilityInTree(this,n,l)??null}static \u0275fac=function(l){return new(l||e)};static \u0275prov=ai({token:e,factory:e.\u0275fac,providedIn:"platform"})}return e})();function jb(e){return!!e&&"function"==typeof e.then}function O1(e){return!!e&&"function"==typeof e.subscribe}const Vb=new ht("");let R1=(()=>{class e{resolve;reject;initialized=!1;done=!1;donePromise=new Promise((n,l)=>{this.resolve=n,this.reject=l});appInits=lr(Vb,{optional:!0})??[];injector=lr(Qo);constructor(){}runInitializers(){if(this.initialized)return;const n=[];for(const p of this.appInits){const g=$s(this.injector,p);if(jb(g))n.push(g);else if(O1(g)){const x=new Promise((k,B)=>{g.subscribe({complete:k,error:B})});n.push(x)}}const l=()=>{this.done=!0,this.resolve()};Promise.all(n).then(()=>{l()}).catch(p=>{this.reject(p)}),0===n.length&&l(),this.initialized=!0}static \u0275fac=function(l){return new(l||e)};static \u0275prov=ai({token:e,factory:e.\u0275fac,providedIn:"root"})}return e})(),Hb=(()=>{class e{static \u0275prov=ai({token:e,providedIn:"root",factory:()=>new N1})}return e})();class N1{queuedEffectCount=0;queues=new Map;schedule(t){this.enqueue(t)}enqueue(t){const n=t.zone;this.queues.has(n)||this.queues.set(n,new Set);const l=this.queues.get(n);l.has(t)||(this.queuedEffectCount++,l.add(t))}flush(){for(;this.queuedEffectCount>0;)for(const[t,n]of this.queues)null===t?this.flushQueue(n):t.run(()=>this.flushQueue(n))}flushQueue(t){for(const n of t)t.delete(n),this.queuedEffectCount--,n.run()}}const pg=new ht("");let hc=(()=>{class e{_bootstrapListeners=[];_runningTick=!1;_destroyed=!1;_destroyListeners=[];_views=[];internalErrorHandler=lr(qu);afterRenderManager=lr(Bs);zonelessEnabled=lr(gu);rootEffectScheduler=lr(Hb);dirtyFlags=0;deferredDirtyFlags=0;externalTestViews=new Set;afterTick=new rt.B;get allViews(){return[...this.externalTestViews.keys(),...this._views]}get destroyed(){return this._destroyed}componentTypes=[];components=[];isStable=lr(Ec).hasPendingTasks.pipe((0,en.T)(n=>!n));whenStable(){let n;return new Promise(l=>{n=this.isStable.subscribe({next:p=>{p&&l()}})}).finally(()=>{n.unsubscribe()})}_injector=lr(cs);get injector(){return this._injector}bootstrap(n,l){const p=n instanceof u1;if(!this._injector.get(R1).done)throw!p&&Ro(n),new Rn(405,!1);let x;x=p?n:this._injector.get(hv).resolveComponentFactory(n),this.componentTypes.push(x.componentType);const k=function FA(e){return e.isBoundToModule}(x)?void 0:this._injector.get(gf),ie=x.create(Qo.NULL,[],l||x.selector,k),Se=ie.location.nativeElement,He=ie.injector.get(M1,null);return He?.registerApplication(Se),ie.onDestroy(()=>{this.detachView(ie.hostView),vv(this.components,ie),He?.unregisterApplication(Se)}),this._loadComponent(ie),ie}tick(){this.zonelessEnabled||(this.dirtyFlags|=1),this._tick()}_tick(){if(this._runningTick)throw new Rn(101,!1);const n=T(null);try{this._runningTick=!0,this.synchronize()}catch(l){this.internalErrorHandler(l)}finally{this._runningTick=!1,T(n),this.afterTick.next()}}synchronize(){let n=null;this._injector.destroyed||(n=this._injector.get(Ib,null,{optional:!0})),this.dirtyFlags|=this.deferredDirtyFlags,this.deferredDirtyFlags=0;let l=0;for(;0!==this.dirtyFlags&&l++<10;)this.synchronizeOnce(n)}synchronizeOnce(n){if(this.dirtyFlags|=this.deferredDirtyFlags,this.deferredDirtyFlags=0,16&this.dirtyFlags&&(this.dirtyFlags&=-17,this.rootEffectScheduler.flush()),7&this.dirtyFlags){const l=!!(1&this.dirtyFlags);this.dirtyFlags&=-8,this.dirtyFlags|=8;for(let{_lView:p,notifyErrorHandler:g}of this.allViews)$A(p,g,l,this.zonelessEnabled);if(this.dirtyFlags&=-5,this.syncDirtyFlagsWithViews(),23&this.dirtyFlags)return}else n?.begin?.(),n?.end?.();8&this.dirtyFlags&&(this.dirtyFlags&=-9,this.afterRenderManager.execute()),this.syncDirtyFlagsWithViews()}syncDirtyFlagsWithViews(){this.allViews.some(({_lView:n})=>kr(n))?this.dirtyFlags|=2:this.dirtyFlags&=-8}attachView(n){const l=n;this._views.push(l),l.attachToAppRef(this)}detachView(n){const l=n;vv(this._views,l),l.detachFromAppRef()}_loadComponent(n){this.attachView(n.hostView),this.tick(),this.components.push(n);const l=this._injector.get(pg,[]);[...this._bootstrapListeners,...l].forEach(p=>p(n))}ngOnDestroy(){if(!this._destroyed)try{this._destroyListeners.forEach(n=>n()),this._views.slice().forEach(n=>n.destroy())}finally{this._destroyed=!0,this._views=[],this._bootstrapListeners=[],this._destroyListeners=[]}}onDestroy(n){return this._destroyListeners.push(n),()=>vv(this._destroyListeners,n)}destroy(){if(this._destroyed)throw new Rn(406,!1);const n=this._injector;n.destroy&&!n.destroyed&&n.destroy()}get viewCount(){return this._views.length}warnIfDestroyed(){}static \u0275fac=function(l){return new(l||e)};static \u0275prov=ai({token:e,factory:e.\u0275fac,providedIn:"root"})}return e})();function vv(e,t){const n=e.indexOf(t);n>-1&&e.splice(n,1)}function $A(e,t,n,l){(n||kr(e))&&cv(e,t,n&&!l?0:1)}let tE=()=>null;function Mp(e,t){return tE(e,t)}let Cv=(()=>class e{static __NG_ELEMENT_ID__=AS})();function AS(){return iE(Si(),En())}const SS=Cv,nE=class extends SS{_lContainer;_hostTNode;_hostLView;constructor(t,n,l){super(),this._lContainer=t,this._hostTNode=n,this._hostLView=l}get element(){return Dc(this._hostTNode,this._hostLView)}get injector(){return new Fs(this._hostTNode,this._hostLView)}get parentInjector(){const t=Nc(this._hostTNode,this._hostLView);if(gh(t)){const n=Wu(t,this._hostLView),l=Hu(t);return new Fs(n[Fn].data[l+8],n)}return new Fs(null,this._hostLView)}clear(){for(;this.length>0;)this.remove(this.length-1)}get(t){const n=rE(this._lContainer);return null!==n&&n[t]||null}get length(){return this._lContainer.length-Rr}createEmbeddedView(t,n,l){let p,g;"number"==typeof l?p=l:null!=l&&(p=l.index,g=l.injector);const x=Mp(this._lContainer,t.ssrId),k=t.createEmbeddedViewImpl(n||{},g,x);return this.insertImpl(k,p,mf(this._hostTNode,x)),k}createComponent(t,n,l,p,g){const x=t&&!function El(e){return"function"==typeof e}(t);let k;if(x)k=n;else{const qt=n||{};k=qt.index,l=qt.injector,p=qt.projectableNodes,g=qt.environmentInjector||qt.ngModuleRef}const B=x?t:new hg(zr(t)),ie=l||this.parentInjector;if(!g&&null==B.ngModule){const Ln=(x?ie:this.parentInjector).get(cs,null);Ln&&(g=Ln)}const Se=zr(B.componentType??{}),He=Mp(this._lContainer,Se?.id??null),Ut=B.create(ie,p,He?.firstChild??null,g);return this.insertImpl(Ut.hostView,k,mf(this._hostTNode,He)),Ut}insert(t,n){return this.insertImpl(t,n,!0)}insertImpl(t,n,l){const p=t._lView;if(function At(e){return wi(e[Oi])}(p)){const k=this.indexOf(t);if(-1!==k)this.detach(k);else{const B=p[Oi],ie=new nE(B,B[Qi],B[Oi]);ie.detach(ie.indexOf(t))}}const g=this._adjustIndex(n),x=this._lContainer;return Sp(x,p,g,l),t.attachToViewContainerRef(),Da(e0(x),g,t),t}move(t,n){return this.insert(t,n)}indexOf(t){const n=rE(this._lContainer);return null!==n?n.indexOf(t):-1}remove(t){const n=this._adjustIndex(t,-1),l=af(this._lContainer,n);l&&(Ms(e0(this._lContainer),n),lf(l[Fn],l))}detach(t){const n=this._adjustIndex(t,-1),l=af(this._lContainer,n);return l&&null!=Ms(e0(this._lContainer),n)?new og(l):null}_adjustIndex(t,n=0){return t??this.length+n}};function rE(e){return e[8]}function e0(e){return e[8]||(e[8]=[])}function iE(e,t){let n;const l=t[e.index];return wi(l)?n=l:(n=ng(l,t,null,e),t[e.index]=n,ra(t,n)),oE(n,t,e,l),new nE(n,e,t)}let oE=function aE(e,t,n,l){if(e[ci])return;let p;p=8&n.type?qi(l):function TS(e,t){const n=e[ri],l=n.createComment(""),p=rs(t,e);return hd(n,Xm(n,p),l,function ab(e,t){return e.nextSibling(t)}(n,p),!1),l}(t,n),e[ci]=p},t0=()=>!1;class n0{queryList;matches=null;constructor(t){this.queryList=t}clone(){return new n0(this.queryList)}setDirty(){this.queryList.setDirty()}}class r0{queries;constructor(t=[]){this.queries=t}createEmbeddedView(t){const n=t.queries;if(null!==n){const l=null!==t.contentQueries?t.contentQueries[0]:n.length,p=[];for(let g=0;gt.trim())}(t):t}}class o0{queries;constructor(t=[]){this.queries=t}elementStart(t,n){for(let l=0;l0)l.push(x[k/2]);else{const ie=g[k+1],Se=t[-B];for(let He=Rr;He(Z(t),t.value);return n[C]=t,n}(e),l=n[C];return t?.equal&&(l.equal=t.equal),n.set=p=>Ze(l,p),n.update=p=>function it(e,t){se()||qe(),Ze(e,t(e.value))}(l,p),n.asReadonly=u0.bind(n),n}function u0(){const e=this[C];if(void 0===e.readonlyFn){const t=()=>this();t[C]=e,e.readonlyFn=t}return e.readonlyFn}function mE(e){return Bb(e)&&"function"==typeof e.set}function d0(e,t,n){let l;const p=bt(()=>{l._dirtyCounter();const g=function BS(e,t){const n=e._lView,l=e._queryIndex;if(void 0===n||void 0===l||4&n[Sr])return t?void 0:Wn;const p=l0(n,l),g=pE(n,l);return p.reset(g,Nh),t?p.first:p._changesDetected||void 0===e._flatValue?e._flatValue=p.toArray():e._flatValue}(l,e);if(t&&void 0===g)throw new Rn(-951,!1);return g});return l=p[C],l._dirtyCounter=kp(0),l._flatValue=void 0,p}function bE(e,t){return function gE(e){return d0(!0,!1)}()}const $S=(bE.required=function US(e,t){return function _E(e){return d0(!0,!0)}()},bE);function h0(e){let t=function SE(e){return Object.getPrototypeOf(e.prototype).constructor}(e.type),n=!0;const l=[e];for(;t;){let p;if(Yo(e))p=t.\u0275cmp||t.\u0275dir;else{if(t.\u0275cmp)throw new Rn(903,!1);p=t.\u0275dir}if(p){if(n){l.push(p);const x=e;x.inputs=Av(e.inputs),x.inputTransforms=Av(e.inputTransforms),x.declaredInputs=Av(e.declaredInputs),x.outputs=Av(e.outputs);const k=p.hostBindings;k&&JS(e,k);const B=p.viewQuery,ie=p.contentQueries;if(B&&ZS(e,B),ie&&qS(e,ie),YS(e,p),Hr(e.outputs,p.outputs),Yo(p)&&p.data.animation){const Se=e.data;Se.animation=(Se.animation||[]).concat(p.data.animation)}}const g=p.features;if(g)for(let x=0;x=0;l--){const p=e[l];p.hostVars=t+=p.hostVars,p.hostAttrs=nc(p.hostAttrs,n=nc(n,p.hostAttrs))}}(l)}function YS(e,t){for(const n in t.inputs){if(!t.inputs.hasOwnProperty(n)||e.inputs.hasOwnProperty(n))continue;const l=t.inputs[n];if(void 0!==l&&(e.inputs[n]=l,e.declaredInputs[n]=t.declaredInputs[n],null!==t.inputTransforms)){const p=Array.isArray(l)?l[0]:l;if(!t.inputTransforms.hasOwnProperty(p))continue;e.inputTransforms??={},e.inputTransforms[p]=t.inputTransforms[p]}}}function Av(e){return e===On?{}:e===Wn?[]:e}function ZS(e,t){const n=e.viewQuery;e.viewQuery=n?(l,p)=>{t(l,p),n(l,p)}:t}function qS(e,t){const n=e.contentQueries;e.contentQueries=n?(l,p,g)=>{t(l,p,g),n(l,p,g)}:t}function JS(e,t){const n=e.hostBindings;e.hostBindings=n?(l,p)=>{t(l,p),n(l,p)}:t}function TE(e){const t=n=>{const l=Array.isArray(e);null===n.hostDirectives?(n.findHostDirectiveDefs=ME,n.hostDirectives=l?e.map(f0):[e]):l?n.hostDirectives.unshift(...e.map(f0)):n.hostDirectives.unshift(e)};return t.ngInherit=!0,t}function ME(e,t,n){if(null!==e.hostDirectives)for(const l of e.hostDirectives)if("function"==typeof l){const p=l();for(const g of p)kE(f0(g),t,n)}else kE(l,t,n)}function kE(e,t,n){const l=di(e.directive);(function rT(e,t){for(const n in t)t.hasOwnProperty(n)&&(e[t[n]]=e[n])})(l.declaredInputs,e.inputs),ME(l,t,n),n.set(l,e),t.push(l)}function f0(e){return"function"==typeof e?{directive:Ge(e),inputs:On,outputs:On}:{directive:Ge(e.directive),inputs:IE(e.inputs),outputs:IE(e.outputs)}}function IE(e){if(void 0===e||0===e.length)return On;const t={};for(let n=0;n>17&32767}function S0(e){return 2|e}function yf(e){return(131068&e)>>2}function T0(e,t){return-131069&e|t<<2}function M0(e){return 1|e}function JE(e,t,n,l){const p=e[n+1],g=null===t;let x=l?oh(p):yf(p),k=!1;for(;0!==x&&(!1===k||g);){const ie=e[x+1];nM(e[x],t)&&(k=!0,e[x+1]=l?M0(ie):S0(ie)),x=l?oh(ie):yf(ie)}k&&(e[n+1]=l?S0(p):M0(p))}function nM(e,t){return null===e||null==t||(Array.isArray(e)?e[1]:e)===t||!(!Array.isArray(e)||"string"!=typeof t)&&ot(e,t)>=0}const Pa={textEnd:0,key:0,keyEnd:0,value:0,valueEnd:0};function ex(e){return e.substring(Pa.key,Pa.keyEnd)}function rM(e){return e.substring(Pa.value,Pa.valueEnd)}function tx(e,t){const n=Pa.textEnd;return n===t?-1:(t=Pa.keyEnd=function sM(e,t,n){for(;t32;)t++;return t}(e,Pa.key=t,n),Kp(e,t,n))}function nx(e,t){const n=Pa.textEnd;let l=Pa.key=Kp(e,t,n);return n===l?-1:(l=Pa.keyEnd=function aM(e,t,n){let l;for(;t=65&&(-33&l)<=90||l>=48&&l<=57);)t++;return t}(e,l,n),l=ix(e,l,n),l=Pa.value=Kp(e,l,n),l=Pa.valueEnd=function lM(e,t,n){let l=-1,p=-1,g=-1,x=t,k=x;for(;x32&&(k=x),g=p,p=l,l=-33&B}return k}(e,l,n),ix(e,l,n))}function rx(e){Pa.key=0,Pa.keyEnd=0,Pa.value=0,Pa.valueEnd=0,Pa.textEnd=e.length}function Kp(e,t,n){for(;t=0;n=nx(t,n))cx(e,ex(t),rM(t))}function sx(e){Jc(mM,Lu,e,!0)}function Lu(e,t){for(let n=function iM(e){return rx(e),tx(e,Kp(e,0,Pa.textEnd))}(t);n>=0;n=tx(t,n))et(e,ex(t),!0)}function qc(e,t,n,l){const p=En(),g=pi(),x=P(2);g.firstUpdatePass&&lx(g,e,x,l),t!==$i&&Ws(p,x,t)&&ux(g,g.data[$n()],p,p[ri],e,p[x+1]=function _M(e,t){return null==e||""===e||("string"==typeof t?e+=t:"object"==typeof e&&(e=Tr(Gc(e)))),e}(t,n),l,x)}function Jc(e,t,n,l){const p=pi(),g=P(2);p.firstUpdatePass&&lx(p,null,g,l);const x=En();if(n!==$i&&Ws(x,g,n)){const k=p.data[$n()];if(hx(k,l)&&!ax(p,g)){let B=l?k.classesWithoutHost:k.stylesWithoutHost;null!==B&&(n=Vr(B,n||"")),I0(p,k,x,n,l)}else!function gM(e,t,n,l,p,g,x,k){p===$i&&(p=Wn);let B=0,ie=0,Se=0=e.expandoStartIndex}function lx(e,t,n,l){const p=e.data;if(null===p[n+1]){const g=p[$n()],x=ax(e,n);hx(g,l)&&null===t&&!x&&(t=!1),t=function uM(e,t,n,l){const p=It(e);let g=l?t.residualClasses:t.residualStyles;if(null===p)0===(l?t.classBindings:t.styleBindings)&&(n=xg(n=N0(null,e,t,n,l),t.attrs,l),g=null);else{const x=t.directiveStylingLast;if(-1===x||e[x]!==p)if(n=N0(p,e,t,n,l),null===g){let B=function dM(e,t,n){const l=n?t.classBindings:t.styleBindings;if(0!==yf(l))return e[oh(l)]}(e,t,l);void 0!==B&&Array.isArray(B)&&(B=N0(null,e,t,B[1],l),B=xg(B,t.attrs,l),function hM(e,t,n,l){e[oh(n?t.classBindings:t.styleBindings)]=l}(e,t,l,B))}else g=function fM(e,t,n){let l;const p=t.directiveEnd;for(let g=1+t.directiveStylingLast;g0)&&(ie=!0)):Se=n,p)if(0!==B){const Nt=oh(e[k+1]);e[l+1]=Iv(Nt,k),0!==Nt&&(e[Nt+1]=T0(e[Nt+1],l)),e[k+1]=function qT(e,t){return 131071&e|t<<17}(e[k+1],l)}else e[l+1]=Iv(k,0),0!==k&&(e[k+1]=T0(e[k+1],l)),k=l;else e[l+1]=Iv(B,0),0===k?k=l:e[B+1]=T0(e[B+1],l),B=l;ie&&(e[l+1]=S0(e[l+1])),JE(e,Se,l,!0),JE(e,Se,l,!1),function tM(e,t,n,l,p){const g=p?e.residualClasses:e.residualStyles;null!=g&&"string"==typeof t&&ot(g,t)>=0&&(n[l+1]=M0(n[l+1]))}(t,Se,e,l,g),x=Iv(k,B),g?t.classBindings=x:t.styleBindings=x}(p,g,t,n,x,l)}}function N0(e,t,n,l,p){let g=null;const x=n.directiveEnd;let k=n.directiveStylingLast;for(-1===k?k=n.directiveStart:k++;k0;){const B=e[p],ie=Array.isArray(B),Se=ie?B[1]:B,He=null===Se;let Nt=n[p+1];Nt===$i&&(Nt=He?Wn:void 0);let Ut=He?te(Nt,l):Se===l?Nt:void 0;if(ie&&!Ov(Ut)&&(Ut=te(B,l)),Ov(Ut)&&(k=Ut,x))return k;const qt=e[p+1];p=x?oh(qt):yf(qt)}if(null!==t){let B=g?t.residualClasses:t.residualStyles;null!=B&&(k=te(B,l))}return k}function Ov(e){return void 0!==e}function hx(e,t){return!!(e.flags&(t?8:16))}function fx(e,t,n){Jc(et,Lu,Bp(En(),e,t,n),!0)}function px(){return En()[vo][Ki]}class AM{destroy(t){}updateValue(t,n){}swap(t,n){const l=Math.min(t,n),p=Math.max(t,n),g=this.detach(p);if(p-l>1){const x=this.detach(l);this.attach(l,g),this.attach(p,x)}else this.attach(l,g)}move(t,n){this.attach(n,this.detach(t))}}function L0(e,t,n,l,p){return e===n&&Object.is(t,l)?1:Object.is(p(e,t),p(n,l))?-1:0}function P0(e,t,n,l){return!(void 0===t||!t.has(l)||(e.attach(n,t.get(l)),t.delete(l),0))}function mx(e,t,n,l,p){if(P0(e,t,l,n(l,p)))e.updateValue(l,p);else{const g=e.create(l,p);e.attach(l,g)}}function gx(e,t,n,l){const p=new Set;for(let g=t;g<=n;g++)p.add(l(g,e.at(g)));return p}class _x{kvMap=new Map;_vMap=void 0;has(t){return this.kvMap.has(t)}delete(t){if(!this.has(t))return!1;const n=this.kvMap.get(t);return void 0!==this._vMap&&this._vMap.has(n)?(this.kvMap.set(t,this._vMap.get(n)),this._vMap.delete(n)):this.kvMap.delete(t),!0}get(t){return this.kvMap.get(t)}set(t,n){if(this.kvMap.has(t)){let l=this.kvMap.get(t);void 0===this._vMap&&(this._vMap=new Map);const p=this._vMap;for(;p.has(l);)l=p.get(l);p.set(l,n)}else this.kvMap.set(t,n)}forEach(t){for(let[n,l]of this.kvMap)if(t(l,n),void 0!==this._vMap){const p=this._vMap;for(;p.has(l);)l=p.get(l),t(l,n)}}}function vx(e,t){oi("NgControlFlow");const n=En(),l=I(),p=n[l]!==$i?n[l]:-1,g=-1!==p?Rv(n,Gt+p):void 0;if(Ws(n,l,e)){const k=T(null);try{if(void 0!==g&&Db(g,0),-1!==e){const B=Gt+e,ie=Rv(n,B),Se=F0(n[Fn],B),He=Mp(ie,Se.tView.ssrId);Sp(ie,Ap(n,Se,t,{dehydratedView:He}),0,mf(Se,He))}}finally{T(k)}}else if(void 0!==g){const k=qw(g,0);void 0!==k&&(k[Ki]=t)}}class TM{lContainer;$implicit;$index;constructor(t,n,l){this.lContainer=t,this.$implicit=n,this.$index=l}get $count(){return this.lContainer.length-Rr}}function yx(e){return e}class kM{hasEmptyBlock;trackByFn;liveCollection;constructor(t,n,l){this.hasEmptyBlock=t,this.trackByFn=n,this.liveCollection=l}}function bx(e,t,n,l,p,g,x,k,B,ie,Se,He,Nt){oi("NgControlFlow");const Ut=En(),qt=pi(),Ln=void 0!==B,Yn=En(),cr=k?x.bind(Yn[vo][Ki]):x,Pn=new kM(Ln,cr);Yn[Gt+e]=Pn,wg(Ut,qt,e+1,t,n,l,p,fn(qt.consts,g)),Ln&&wg(Ut,qt,e+2,B,ie,Se,He,fn(qt.consts,Nt))}class IM extends AM{lContainer;hostLView;templateTNode;operationsCounter=void 0;needsIndexUpdate=!1;constructor(t,n,l){super(),this.lContainer=t,this.hostLView=n,this.templateTNode=l}get length(){return this.lContainer.length-Rr}at(t){return this.getLView(t)[Ki].$implicit}attach(t,n){const l=n[so];this.needsIndexUpdate||=t!==this.length,Sp(this.lContainer,n,t,mf(this.templateTNode,l))}detach(t){return this.needsIndexUpdate||=t!==this.length-1,function OM(e,t){return af(e,t)}(this.lContainer,t)}create(t,n){const l=Mp(this.lContainer,this.templateTNode.tView.ssrId),p=Ap(this.hostLView,this.templateTNode,new TM(this.lContainer,n,t),{dehydratedView:l});return this.operationsCounter?.recordCreate(),p}destroy(t){lf(t[Fn],t),this.operationsCounter?.recordDestroy()}updateValue(t,n){this.getLView(t)[Ki].$implicit=n}reset(){this.needsIndexUpdate=!1,this.operationsCounter?.reset()}updateIndexes(){if(this.needsIndexUpdate)for(let t=0;t{e.destroy(B)})}(B,e,g.trackByFn),B.updateIndexes(),g.hasEmptyBlock){const ie=I(),Se=0===B.length;if(Ws(l,ie,Se)){const He=n+2,Nt=Rv(l,He);if(Se){const Ut=F0(p,He),qt=Mp(Nt,Ut.tView.ssrId);Sp(Nt,Ap(l,Ut,void 0,{dehydratedView:qt}),0,mf(Ut,qt))}else Db(Nt,0)}}}finally{T(t)}}function Rv(e,t){return e[t]}function F0(e,t){return G(e,t)}function Nv(e,t,n,l){const p=En(),g=pi(),x=Gt+e,k=p[ri],B=g.firstCreatePass?function NM(e,t,n,l,p,g){const x=t.consts,B=fd(t,e,2,l,fn(x,p));return vl(t,n,B,fn(x,g)),null!==B.attrs&&pv(B,B.attrs,!1),null!==B.mergedAttrs&&pv(B,B.mergedAttrs,!0),null!==t.queries&&t.queries.elementStart(t,B),B}(x,g,p,t,n,l):g.data[x],ie=Ex(g,p,B,k,t,e);p[x]=ie;const Se=fa(B);return Qs(B,!0),tv(k,ie,B),!function Op(e){return!(32&~e.flags)}(B)&&bo()&&bp(g,p,ie,B),0===function _d(){return Wr.lFrame.elementDepthCount}()&&ya(ie,p),function uh(){Wr.lFrame.elementDepthCount++}(),Se&&(d(g,p,B),m(g,B,p)),null!==l&&_(p,B),Nv}function Lv(){let e=Si();Oc()?pa():(e=e.parent,Qs(e,!1));const t=e;(function Ql(e){return Wr.skipHydrationRootTNode===e})(t)&&function Ja(){Wr.skipHydrationRootTNode=null}(),function dh(){Wr.lFrame.elementDepthCount--}();const n=pi();return n.firstCreatePass&&(_r(n,e),bs(e)&&n.queries.elementEnd(e)),null!=t.classesWithoutHost&&function yc(e){return!!(8&e.flags)}(t)&&I0(n,t,En(),t.classesWithoutHost,!0),null!=t.stylesWithoutHost&&function tc(e){return!!(16&e.flags)}(t)&&I0(n,t,En(),t.stylesWithoutHost,!1),Lv}function B0(e,t,n,l){return Nv(e,t,n,l),Lv(),B0}let Ex=(e,t,n,l,p,g)=>(To(!0),gp(l,p,function Ji(){return Wr.lFrame.currentNamespace}()));function Pv(e,t,n){const l=En(),p=pi(),g=e+Gt,x=p.firstCreatePass?function FM(e,t,n,l,p){const g=t.consts,x=fn(g,l),k=fd(t,e,8,"ng-container",x);return null!==x&&pv(k,x,!0),vl(t,n,k,fn(g,p)),null!==t.queries&&t.queries.elementStart(t,k),k}(g,p,l,t,n):p.data[g];Qs(x,!0);const k=xx(p,l,x,e);return l[g]=k,bo()&&bp(p,l,k,x),ya(k,l),fa(x)&&(d(p,l,x),m(p,x,l)),null!=n&&_(l,x),Pv}function Fv(){let e=Si();const t=pi();return Oc()?pa():(e=e.parent,Qs(e,!1)),t.firstCreatePass&&(_r(t,e),bs(e)&&t.queries.elementEnd(e)),Fv}function U0(e,t,n){return Pv(e,t,n),Fv(),U0}let xx=(e,t,n,l)=>(To(!0),Km(t[ri],""));function Cx(){return En()}function $0(e,t,n){const l=En();return Ws(l,I(),t)&&ho(pi(),ir(),l,e,t,l[ri],n,!0),$0}function j0(e,t,n){const l=En();if(Ws(l,I(),t)){const g=pi(),x=ir();ho(g,x,l,e,t,Zw(It(g.data),x,l),n,!0)}return j0}const bf=void 0;var jM=["en",[["a","p"],["AM","PM"],bf],[["AM","PM"],bf,bf],[["S","M","T","W","T","F","S"],["Sun","Mon","Tue","Wed","Thu","Fri","Sat"],["Sunday","Monday","Tuesday","Wednesday","Thursday","Friday","Saturday"],["Su","Mo","Tu","We","Th","Fr","Sa"]],bf,[["J","F","M","A","M","J","J","A","S","O","N","D"],["Jan","Feb","Mar","Apr","May","Jun","Jul","Aug","Sep","Oct","Nov","Dec"],["January","February","March","April","May","June","July","August","September","October","November","December"]],bf,[["B","A"],["BC","AD"],["Before Christ","Anno Domini"]],0,[6,0],["M/d/yy","MMM d, y","MMMM d, y","EEEE, MMMM d, y"],["h:mm a","h:mm:ss a","h:mm:ss a z","h:mm:ss a zzzz"],["{1}, {0}",bf,"{1} 'at' {0}",bf],[".",",",";","%","+","-","E","\xd7","\u2030","\u221e","NaN",":"],["#,##0.###","#,##0%","\xa4#,##0.00","#E0"],"USD","$","US Dollar",{},"ltr",function $M(e){const n=Math.floor(Math.abs(e)),l=e.toString().replace(/^[^.]*\.?/,"").length;return 1===n&&0===l?1:5}];let Gp={};function V0(e){const t=function VM(e){return e.toLowerCase().replace(/_/g,"-")}(e);let n=Ax(t);if(n)return n;const l=t.split("-")[0];if(n=Ax(l),n)return n;if("en"===l)return jM;throw new Rn(701,!1)}function Dx(e){return V0(e)[Xp.PluralCase]}function Ax(e){return e in Gp||(Gp[e]=dn.ng&&dn.ng.common&&dn.ng.common.locales&&dn.ng.common.locales[e]),Gp[e]}var Xp=function(e){return e[e.LocaleId=0]="LocaleId",e[e.DayPeriodsFormat=1]="DayPeriodsFormat",e[e.DayPeriodsStandalone=2]="DayPeriodsStandalone",e[e.DaysFormat=3]="DaysFormat",e[e.DaysStandalone=4]="DaysStandalone",e[e.MonthsFormat=5]="MonthsFormat",e[e.MonthsStandalone=6]="MonthsStandalone",e[e.Eras=7]="Eras",e[e.FirstDayOfWeek=8]="FirstDayOfWeek",e[e.WeekendRange=9]="WeekendRange",e[e.DateFormat=10]="DateFormat",e[e.TimeFormat=11]="TimeFormat",e[e.DateTimeFormat=12]="DateTimeFormat",e[e.NumberSymbols=13]="NumberSymbols",e[e.NumberFormats=14]="NumberFormats",e[e.CurrencyCode=15]="CurrencyCode",e[e.CurrencySymbol=16]="CurrencySymbol",e[e.CurrencyName=17]="CurrencyName",e[e.Currencies=18]="Currencies",e[e.Directionality=19]="Directionality",e[e.PluralCase=20]="PluralCase",e[e.ExtraData=21]="ExtraData",e}(Xp||{});const Bv="en-US";let Sx=Bv,zx=(e,t,n)=>{};function z0(e,t,n,l){const p=En(),g=pi(),x=Si();return G0(g,p,p[ri],x,e,t,l),z0}function K0(e,t){const n=Si(),l=En(),p=pi();return G0(p,l,Zw(It(p.data),n,l),n,e,t),K0}function G0(e,t,n,l,p,g,x){const k=fa(l),ie=e.firstCreatePass&&Dp(e),Se=t[Ki],He=pf(t);let Nt=!0;if(3&l.type||x){const Ln=rs(l,t),Yn=x?x(Ln):Ln,cr=He.length,Pn=x?ji=>x(qi(ji[l.index])):l.index;let xi=null;if(!x&&k&&(xi=function Ok(e,t,n,l){const p=e.cleanup;if(null!=p)for(let g=0;gB?k[B]:null}"string"==typeof x&&(g+=2)}return null}(e,t,p,l.index)),null!==xi)(xi.__ngLastListenerFn__||xi).__ngNextListenerFn__=g,xi.__ngLastListenerFn__=g,Nt=!1;else{g=Gx(l,t,Se,g),zx(Ln,p,g);const ji=n.listen(Yn,p,g);He.push(g,ji),ie&&ie.push(p,Pn,cr,cr+1)}}else g=Gx(l,t,Se,g);const Ut=l.outputs;let qt;if(Nt&&null!==Ut&&(qt=Ut[p])){const Ln=qt.length;if(Ln)for(let Yn=0;Yn-1?K(e.index,t):t,5);let k=Kx(t,n,l,g),B=p.__ngNextListenerFn__;for(;B;)k=Kx(t,n,B,g)&&k,B=B.__ngNextListenerFn__;return k}}function Xx(e=1){return function vr(e){return(Wr.lFrame.contextLView=function ui(e,t){for(;e>0;)t=t[Uo],e--;return t}(e,Wr.lFrame.contextLView))[Ki]}(e)}function Rk(e,t){let n=null;const l=function gb(e){const t=e.attrs;if(null!=t){const n=t.indexOf(5);if(!(1&n))return t[n+1]}return null}(e);for(let p=0;pn._dirtyCounter.update(l=>l+1))}(t,hE(e,n,l,p))}function uC(e=1){ln(zt()+e)}function dC(e){return F(function vd(){return Wr.lFrame.contextLView}(),Gt+e)}function wC(e,t=""){const n=En(),l=pi(),p=e+Gt,g=l.firstCreatePass?fd(l,p,1,t,null):l.data[p],x=EC(l,n,g,t,e);n[p]=x,bo()&&bp(l,n,x,g),Qs(g,!1)}let EC=(e,t,n,l,p)=>(To(!0),function zm(e,t){return e.createText(t)}(t[ri],l));function Q0(e){return Hv("",e,""),Q0}function Hv(e,t,n){const l=En(),p=Bp(l,e,t,n);return p!==$i&&function md(e,t,n){const l=gc(t,e);!function U_(e,t,n){e.setValue(t,n)}(e[ri],l,n)}(l,$n(),p),Hv}function Z0(e,t,n){mE(t)&&(t=t());const l=En();return Ws(l,I(),t)&&ho(pi(),ir(),l,e,t,l[ri],n,!1),Z0}function IC(e,t){const n=mE(e);return n&&e.set(t),n}function q0(e,t){const n=En(),l=pi(),p=Si();return G0(l,n,n[ri],p,e,t),q0}function J0(e,t,n,l,p){if(e=Ge(e),Array.isArray(e))for(let g=0;g>20;if(ts(e)||!e.multi){const Ut=new el(ie,p,qd),qt=tw(B,t,p?Se:Se+Nt,He);-1===qt?(Lc(vh(k,x),g,B),ew(g,e,t.length),t.push(B),k.directiveStart++,k.directiveEnd++,p&&(k.providerIndexes+=1048576),n.push(Ut),x.push(Ut)):(n[qt]=Ut,x[qt]=Ut)}else{const Ut=tw(B,t,Se+Nt,He),qt=tw(B,t,Se,Se+Nt),Yn=qt>=0&&n[qt];if(p&&!Yn||!p&&!(Ut>=0&&n[Ut])){Lc(vh(k,x),g,B);const cr=function qk(e,t,n,l,p){const g=new el(e,n,qd);return g.multi=[],g.index=t,g.componentProviders=0,NC(g,p,l&&!n),g}(p?Zk:Qk,n.length,p,l,ie);!p&&Yn&&(n[qt].providerFactory=cr),ew(g,e,t.length,0),t.push(B),k.directiveStart++,k.directiveEnd++,p&&(k.providerIndexes+=1048576),n.push(cr),x.push(cr)}else ew(g,e,Ut>-1?Ut:qt,NC(n[p?qt:Ut],ie,!p&&l));!p&&l&&Yn&&n[qt].componentProviders++}}}function ew(e,t,n,l){const p=ts(t),g=function kl(e){return!!e.useClass}(t);if(p||g){const B=(g?Ge(t.useClass):t).prototype.ngOnDestroy;if(B){const ie=e.destroyHooks||(e.destroyHooks=[]);if(!p&&t.multi){const Se=ie.indexOf(n);-1===Se?ie.push(n,[l,B]):ie[Se+1].push(l,B)}else ie.push(n,B)}}}function NC(e,t,n){return n&&e.componentProviders++,e.multi.push(t)-1}function tw(e,t,n,l){for(let p=n;p{n.providersResolver=(l,p)=>function Yk(e,t,n){const l=pi();if(l.firstCreatePass){const p=Yo(e);J0(n,l.data,l.blueprint,p,!0),J0(t,l.data,l.blueprint,p,!1)}}(l,p?p(e):e,t)}}function FC(e,t,n){const l=Zs()+e,p=En();return p[l]===$i?Nu(p,l,n?t.call(n):t()):bg(p,l)}function BC(e,t,n,l){return HC(En(),Zs(),e,t,n,l)}function UC(e,t,n,l,p){return WC(En(),Zs(),e,t,n,l,p)}function $C(e,t,n,l,p,g){return function zC(e,t,n,l,p,g,x,k){const B=t+n;return function Tv(e,t,n,l,p){const g=vf(e,t,n,l);return Ws(e,t+2,p)||g}(e,B,p,g,x)?Nu(e,B+3,k?l.call(k,p,g,x):l(p,g,x)):Mg(e,B+3)}(En(),Zs(),e,t,n,l,p,g)}function jC(e,t,n,l,p,g,x){return function KC(e,t,n,l,p,g,x,k,B){const ie=t+n;return Tc(e,ie,p,g,x,k)?Nu(e,ie+4,B?l.call(B,p,g,x,k):l(p,g,x,k)):Mg(e,ie+4)}(En(),Zs(),e,t,n,l,p,g,x)}function VC(e,t,n,l,p,g,x,k,B,ie,Se){const He=Zs()+e,Nt=En(),Ut=Tc(Nt,He,n,l,p,g);return Tc(Nt,He+4,x,k,B,ie)||Ut?Nu(Nt,He+8,Se?t.call(Se,n,l,p,g,x,k,B,ie):t(n,l,p,g,x,k,B,ie)):bg(Nt,He+8)}function Mg(e,t){const n=e[t];return n===$i?void 0:n}function HC(e,t,n,l,p,g){const x=t+n;return Ws(e,x,p)?Nu(e,x+1,g?l.call(g,p):l(p)):Mg(e,x+1)}function WC(e,t,n,l,p,g,x){const k=t+n;return vf(e,k,p,g)?Nu(e,k+2,x?l.call(x,p,g):l(p,g)):Mg(e,k+2)}function XC(e,t){const n=pi();let l;const p=e+Gt;n.firstCreatePass?(l=function sI(e,t){if(t)for(let n=t.length-1;n>=0;n--){const l=t[n];if(e===l.name)return l}}(t,n.pipeRegistry),n.data[p]=l,l.onDestroy&&(n.destroyHooks??=[]).push(p,l.onDestroy)):l=n.data[p];const g=l.factory||(l.factory=So(l.type)),k=Oo(qd);try{const B=Ll(!1),ie=g();return Ll(B),function Y0(e,t,n,l){n>=e.data.length&&(e.data[n]=null,e.blueprint[n]=null),t[n]=l}(n,En(),p,ie),ie}finally{Oo(k)}}function YC(e,t,n){const l=e+Gt,p=En(),g=F(p,l);return kg(p,l)?HC(p,Zs(),t,g.transform,n,g):g.transform(n)}function QC(e,t,n,l){const p=e+Gt,g=En(),x=F(g,p);return kg(g,p)?WC(g,Zs(),t,x.transform,n,l,x):x.transform(n,l)}function kg(e,t){return e[Fn].data[t].pure}function ZC(e,t){return uv(e,t)}class f2{full;major;minor;patch;constructor(t){this.full=t;const n=t.split(".");this.major=n[0],this.minor=n[1],this.patch=n.slice(2).join(".")}}class PI{ngModuleFactory;componentFactories;constructor(t,n){this.ngModuleFactory=t,this.componentFactories=n}}let FI=(()=>{class e{compileModuleSync(n){return new Lb(n)}compileModuleAsync(n){return Promise.resolve(this.compileModuleSync(n))}compileModuleAndAllComponentsSync(n){const l=this.compileModuleSync(n),g=Al(fi(n).declarations).reduce((x,k)=>{const B=zr(k);return B&&x.push(new hg(B)),x},[]);return new PI(l,g)}compileModuleAndAllComponentsAsync(n){return Promise.resolve(this.compileModuleAndAllComponentsSync(n))}clearCache(){}clearCacheFor(n){}getModuleId(n){}static \u0275fac=function(l){return new(l||e)};static \u0275prov=ai({token:e,factory:e.\u0275fac,providedIn:"root"})}return e})(),$I=(()=>{class e{zone=lr(os);changeDetectionScheduler=lr(rc);applicationRef=lr(hc);_onMicrotaskEmptySubscription;initialize(){this._onMicrotaskEmptySubscription||(this._onMicrotaskEmptySubscription=this.zone.onMicrotaskEmpty.subscribe({next:()=>{this.changeDetectionScheduler.runningTick||this.zone.run(()=>{this.applicationRef.tick()})}}))}ngOnDestroy(){this._onMicrotaskEmptySubscription?.unsubscribe()}static \u0275fac=function(l){return new(l||e)};static \u0275prov=ai({token:e,factory:e.\u0275fac,providedIn:"root"})}return e})();function lw({ngZoneFactory:e,ignoreChangesOutsideZone:t,scheduleInRootZone:n}){return e??=()=>new os({...cw(),scheduleInRootZone:n}),[{provide:os,useFactory:e},{provide:Qn,multi:!0,useFactory:()=>{const l=lr($I,{optional:!0});return()=>l.initialize()}},{provide:Qn,multi:!0,useFactory:()=>{const l=lr(VI);return()=>{l.initialize()}}},!0===t?{provide:Od,useValue:!0}:[],{provide:ic,useValue:n??Sh}]}function cw(e){return{enableLongStackTrace:!1,shouldCoalesceEventChangeDetection:e?.eventCoalescing??!1,shouldCoalesceRunChangeDetection:e?.runCoalescing??!1}}let VI=(()=>{class e{subscription=new Vt.yU;initialized=!1;zone=lr(os);pendingTasks=lr(Ec);initialize(){if(this.initialized)return;this.initialized=!0;let n=null;!this.zone.isStable&&!this.zone.hasPendingMacrotasks&&!this.zone.hasPendingMicrotasks&&(n=this.pendingTasks.add()),this.zone.runOutsideAngular(()=>{this.subscription.add(this.zone.onStable.subscribe(()=>{os.assertNotInAngularZone(),queueMicrotask(()=>{null!==n&&!this.zone.hasPendingMacrotasks&&!this.zone.hasPendingMicrotasks&&(this.pendingTasks.remove(n),n=null)})}))}),this.subscription.add(this.zone.onUnstable.subscribe(()=>{os.assertInAngularZone(),n??=this.pendingTasks.add()}))}ngOnDestroy(){this.subscription.unsubscribe()}static \u0275fac=function(l){return new(l||e)};static \u0275prov=ai({token:e,factory:e.\u0275fac,providedIn:"root"})}return e})(),Og=(()=>{class e{appRef=lr(hc);taskService=lr(Ec);ngZone=lr(os);zonelessEnabled=lr(gu);disableScheduling=lr(Od,{optional:!0})??!1;zoneIsDefined=typeof Zone<"u"&&!!Zone.root.run;schedulerTickApplyArgs=[{data:{__scheduler_tick__:!0}}];subscriptions=new Vt.yU;angularZoneId=this.zoneIsDefined?this.ngZone._inner?.get(Zu):null;scheduleInRootZone=!this.zonelessEnabled&&this.zoneIsDefined&&(lr(ic,{optional:!0})??!1);cancelScheduledCallback=null;useMicrotaskScheduler=!1;runningTick=!1;pendingRenderTaskId=null;constructor(){this.subscriptions.add(this.appRef.afterTick.subscribe(()=>{this.runningTick||this.cleanup()})),this.subscriptions.add(this.ngZone.onUnstable.subscribe(()=>{this.runningTick||this.cleanup()})),this.disableScheduling||=!this.zonelessEnabled&&(this.ngZone instanceof Rh||!this.zoneIsDefined)}notify(n){if(!this.zonelessEnabled&&5===n)return;let l=!1;switch(n){case 0:this.appRef.dirtyFlags|=2;break;case 3:case 2:case 4:case 5:case 1:this.appRef.dirtyFlags|=4;break;case 8:this.appRef.deferredDirtyFlags|=8;break;case 6:case 14:this.appRef.dirtyFlags|=2,l=!0;break;case 13:this.appRef.dirtyFlags|=16,l=!0;break;case 12:l=!0;break;default:this.appRef.dirtyFlags|=8}if(!this.shouldScheduleTick(l))return;const p=this.useMicrotaskScheduler?cm:Rd;this.pendingRenderTaskId=this.taskService.add(),this.cancelScheduledCallback=this.scheduleInRootZone?Zone.root.run(()=>p(()=>this.tick())):this.ngZone.runOutsideAngular(()=>p(()=>this.tick()))}shouldScheduleTick(n){return!(this.disableScheduling&&!n||this.appRef.destroyed||null!==this.pendingRenderTaskId||this.runningTick||this.appRef._runningTick||!this.zonelessEnabled&&this.zoneIsDefined&&Zone.current.get(Zu+this.angularZoneId))}tick(){if(this.runningTick||this.appRef.destroyed)return;if(0===this.appRef.dirtyFlags)return void this.cleanup();!this.zonelessEnabled&&7&this.appRef.dirtyFlags&&(this.appRef.dirtyFlags|=1);const n=this.taskService.add();try{this.ngZone.run(()=>{this.runningTick=!0,this.appRef._tick()},void 0,this.schedulerTickApplyArgs)}catch(l){throw this.taskService.remove(n),l}finally{this.cleanup()}this.useMicrotaskScheduler=!0,cm(()=>{this.useMicrotaskScheduler=!1,this.taskService.remove(n)})}ngOnDestroy(){this.subscriptions.unsubscribe(),this.cleanup()}cleanup(){if(this.runningTick=!1,this.cancelScheduledCallback?.(),this.cancelScheduledCallback=null,null!==this.pendingRenderTaskId){const n=this.pendingRenderTaskId;this.pendingRenderTaskId=null,this.taskService.remove(n)}}static \u0275fac=function(l){return new(l||e)};static \u0275prov=ai({token:e,factory:e.\u0275fac,providedIn:"root"})}return e})();const dw=new ht("",{providedIn:"root",factory:()=>lr(dw,bi.Optional|bi.SkipSelf)||function HI(){return typeof $localize<"u"&&$localize.locale||Bv}()}),WI=new ht("",{providedIn:"root",factory:()=>"USD"}),Kv=new ht("");function Gv(e){return!e.moduleRef}let sh=null;function JI(){return!1}let C2=(()=>class e{static __NG_ELEMENT_ID__=eO})();function eO(e){return function tO(e,t,n){if(Lo(e)&&!n){const l=K(e.index,t);return new og(l,l)}return 175&e.type?new og(t[vo],t):null}(Si(),En(),!(16&~e))}class T2{constructor(){}supports(t){return Sv(t)}create(t){return new sO(t)}}const oO=(e,t)=>t;class sO{length=0;collection;_linkedRecords=null;_unlinkedRecords=null;_previousItHead=null;_itHead=null;_itTail=null;_additionsHead=null;_additionsTail=null;_movesHead=null;_movesTail=null;_removalsHead=null;_removalsTail=null;_identityChangesHead=null;_identityChangesTail=null;_trackByFn;constructor(t){this._trackByFn=t||oO}forEachItem(t){let n;for(n=this._itHead;null!==n;n=n._next)t(n)}forEachOperation(t){let n=this._itHead,l=this._removalsHead,p=0,g=null;for(;n||l;){const x=!l||n&&n.currentIndex{x=this._trackByFn(p,k),null!==n&&Object.is(n.trackById,x)?(l&&(n=this._verifyReinsertion(n,k,x,p)),Object.is(n.item,k)||this._addIdentityChange(n,k)):(n=this._mismatch(n,k,x,p),l=!0),n=n._next,p++}),this.length=p;return this._truncate(n),this.collection=t,this.isDirty}get isDirty(){return null!==this._additionsHead||null!==this._movesHead||null!==this._removalsHead||null!==this._identityChangesHead}_reset(){if(this.isDirty){let t;for(t=this._previousItHead=this._itHead;null!==t;t=t._next)t._nextPrevious=t._next;for(t=this._additionsHead;null!==t;t=t._nextAdded)t.previousIndex=t.currentIndex;for(this._additionsHead=this._additionsTail=null,t=this._movesHead;null!==t;t=t._nextMoved)t.previousIndex=t.currentIndex;this._movesHead=this._movesTail=null,this._removalsHead=this._removalsTail=null,this._identityChangesHead=this._identityChangesTail=null}}_mismatch(t,n,l,p){let g;return null===t?g=this._itTail:(g=t._prev,this._remove(t)),null!==(t=null===this._unlinkedRecords?null:this._unlinkedRecords.get(l,null))?(Object.is(t.item,n)||this._addIdentityChange(t,n),this._reinsertAfter(t,g,p)):null!==(t=null===this._linkedRecords?null:this._linkedRecords.get(l,p))?(Object.is(t.item,n)||this._addIdentityChange(t,n),this._moveAfter(t,g,p)):t=this._addAfter(new aO(n,l),g,p),t}_verifyReinsertion(t,n,l,p){let g=null===this._unlinkedRecords?null:this._unlinkedRecords.get(l,null);return null!==g?t=this._reinsertAfter(g,t._prev,p):t.currentIndex!=p&&(t.currentIndex=p,this._addToMoves(t,p)),t}_truncate(t){for(;null!==t;){const n=t._next;this._addToRemovals(this._unlink(t)),t=n}null!==this._unlinkedRecords&&this._unlinkedRecords.clear(),null!==this._additionsTail&&(this._additionsTail._nextAdded=null),null!==this._movesTail&&(this._movesTail._nextMoved=null),null!==this._itTail&&(this._itTail._next=null),null!==this._removalsTail&&(this._removalsTail._nextRemoved=null),null!==this._identityChangesTail&&(this._identityChangesTail._nextIdentityChange=null)}_reinsertAfter(t,n,l){null!==this._unlinkedRecords&&this._unlinkedRecords.remove(t);const p=t._prevRemoved,g=t._nextRemoved;return null===p?this._removalsHead=g:p._nextRemoved=g,null===g?this._removalsTail=p:g._prevRemoved=p,this._insertAfter(t,n,l),this._addToMoves(t,l),t}_moveAfter(t,n,l){return this._unlink(t),this._insertAfter(t,n,l),this._addToMoves(t,l),t}_addAfter(t,n,l){return this._insertAfter(t,n,l),this._additionsTail=null===this._additionsTail?this._additionsHead=t:this._additionsTail._nextAdded=t,t}_insertAfter(t,n,l){const p=null===n?this._itHead:n._next;return t._next=p,t._prev=n,null===p?this._itTail=t:p._prev=t,null===n?this._itHead=t:n._next=t,null===this._linkedRecords&&(this._linkedRecords=new M2),this._linkedRecords.put(t),t.currentIndex=l,t}_remove(t){return this._addToRemovals(this._unlink(t))}_unlink(t){null!==this._linkedRecords&&this._linkedRecords.remove(t);const n=t._prev,l=t._next;return null===n?this._itHead=l:n._next=l,null===l?this._itTail=n:l._prev=n,t}_addToMoves(t,n){return t.previousIndex===n||(this._movesTail=null===this._movesTail?this._movesHead=t:this._movesTail._nextMoved=t),t}_addToRemovals(t){return null===this._unlinkedRecords&&(this._unlinkedRecords=new M2),this._unlinkedRecords.put(t),t.currentIndex=null,t._nextRemoved=null,null===this._removalsTail?(this._removalsTail=this._removalsHead=t,t._prevRemoved=null):(t._prevRemoved=this._removalsTail,this._removalsTail=this._removalsTail._nextRemoved=t),t}_addIdentityChange(t,n){return t.item=n,this._identityChangesTail=null===this._identityChangesTail?this._identityChangesHead=t:this._identityChangesTail._nextIdentityChange=t,t}}class aO{item;trackById;currentIndex=null;previousIndex=null;_nextPrevious=null;_prev=null;_next=null;_prevDup=null;_nextDup=null;_prevRemoved=null;_nextRemoved=null;_nextAdded=null;_nextMoved=null;_nextIdentityChange=null;constructor(t,n){this.item=t,this.trackById=n}}class lO{_head=null;_tail=null;add(t){null===this._head?(this._head=this._tail=t,t._nextDup=null,t._prevDup=null):(this._tail._nextDup=t,t._prevDup=this._tail,t._nextDup=null,this._tail=t)}get(t,n){let l;for(l=this._head;null!==l;l=l._nextDup)if((null===n||n<=l.currentIndex)&&Object.is(l.trackById,t))return l;return null}remove(t){const n=t._prevDup,l=t._nextDup;return null===n?this._head=l:n._nextDup=l,null===l?this._tail=n:l._prevDup=n,null===this._head}}class M2{map=new Map;put(t){const n=t.trackById;let l=this.map.get(n);l||(l=new lO,this.map.set(n,l)),l.add(t)}get(t,n){const p=this.map.get(t);return p?p.get(t,n):null}remove(t){const n=t.trackById;return this.map.get(n).remove(t)&&this.map.delete(n),t}get isEmpty(){return 0===this.map.size}clear(){this.map.clear()}}function k2(e,t,n){const l=e.previousIndex;if(null===l)return l;let p=0;return n&&l{if(n&&n.key===p)this._maybeAddToChanges(n,l),this._appendAfter=n,n=n._next;else{const g=this._getOrCreateRecordForKey(p,l);n=this._insertBeforeOrAppend(n,g)}}),n){n._prev&&(n._prev._next=null),this._removalsHead=n;for(let l=n;null!==l;l=l._nextRemoved)l===this._mapHead&&(this._mapHead=null),this._records.delete(l.key),l._nextRemoved=l._next,l.previousValue=l.currentValue,l.currentValue=null,l._prev=null,l._next=null}return this._changesTail&&(this._changesTail._nextChanged=null),this._additionsTail&&(this._additionsTail._nextAdded=null),this.isDirty}_insertBeforeOrAppend(t,n){if(t){const l=t._prev;return n._next=t,n._prev=l,t._prev=n,l&&(l._next=n),t===this._mapHead&&(this._mapHead=n),this._appendAfter=t,t}return this._appendAfter?(this._appendAfter._next=n,n._prev=this._appendAfter):this._mapHead=n,this._appendAfter=n,null}_getOrCreateRecordForKey(t,n){if(this._records.has(t)){const p=this._records.get(t);this._maybeAddToChanges(p,n);const g=p._prev,x=p._next;return g&&(g._next=x),x&&(x._prev=g),p._next=null,p._prev=null,p}const l=new uO(t);return this._records.set(t,l),l.currentValue=n,this._addToAdditions(l),l}_reset(){if(this.isDirty){let t;for(this._previousMapHead=this._mapHead,t=this._previousMapHead;null!==t;t=t._next)t._nextPrevious=t._next;for(t=this._changesHead;null!==t;t=t._nextChanged)t.previousValue=t.currentValue;for(t=this._additionsHead;null!=t;t=t._nextAdded)t.previousValue=t.currentValue;this._changesHead=this._changesTail=null,this._additionsHead=this._additionsTail=null,this._removalsHead=null}}_maybeAddToChanges(t,n){Object.is(n,t.currentValue)||(t.previousValue=t.currentValue,t.currentValue=n,this._addToChanges(t))}_addToAdditions(t){null===this._additionsHead?this._additionsHead=this._additionsTail=t:(this._additionsTail._nextAdded=t,this._additionsTail=t)}_addToChanges(t){null===this._changesHead?this._changesHead=this._changesTail=t:(this._changesTail._nextChanged=t,this._changesTail=t)}_forEach(t,n){t instanceof Map?t.forEach(n):Object.keys(t).forEach(l=>n(t[l],l))}}class uO{key;previousValue=null;currentValue=null;_nextPrevious=null;_next=null;_prev=null;_nextAdded=null;_nextRemoved=null;_nextChanged=null;constructor(t){this.key=t}}function O2(){return new _w([new T2])}let _w=(()=>{class e{factories;static \u0275prov=ai({token:e,providedIn:"root",factory:O2});constructor(n){this.factories=n}static create(n,l){if(null!=l){const p=l.factories.slice();n=n.concat(p)}return new e(n)}static extend(n){return{provide:e,useFactory:l=>e.create(n,l||O2()),deps:[[e,new Ts,new ca]]}}find(n){const l=this.factories.find(p=>p.supports(n));if(null!=l)return l;throw new Rn(901,!1)}}return e})();function R2(){return new vw([new I2])}let vw=(()=>{class e{static \u0275prov=ai({token:e,providedIn:"root",factory:R2});factories;constructor(n){this.factories=n}static create(n,l){if(l){const p=l.factories.slice();n=n.concat(p)}return new e(n)}static extend(n){return{provide:e,useFactory:l=>e.create(n,l||R2()),deps:[[e,new Ts,new ca]]}}find(n){const l=this.factories.find(p=>p.supports(n));if(l)return l;throw new Rn(901,!1)}}return e})();function CO(e){try{const{rootComponent:t,appProviders:n,platformProviders:l}=e,p=function qI(e=[]){if(sh)return sh;const t=function w2(e=[],t){return Qo.create({name:t,providers:[{provide:yl,useValue:"platform"},{provide:Kv,useValue:new Set([()=>sh=null])},...e]})}(e);return sh=t,function L1(){!function _t(e){yn=e}(()=>{throw new Rn(600,!1)})}(),function E2(e){const t=e.get(sd,null);$s(e,()=>{t?.forEach(n=>n())})}(t),t}(l),g=[lw({}),{provide:rc,useExisting:Og},...n||[]];return function v2(e){const t=Gv(e)?e.r3Injector:e.moduleRef.injector,n=t.get(os);return n.run(()=>{Gv(e)?e.r3Injector.resolveInjectorInitializers():e.moduleRef.resolveInjectorInitializers();const l=t.get(Cc,null);let p;if(n.runOutsideAngular(()=>{p=n.onError.subscribe({next:g=>{l.handleError(g)}})}),Gv(e)){const g=()=>t.destroy(),x=e.platformInjector.get(Kv);x.add(g),t.onDestroy(()=>{p.unsubscribe(),x.delete(g)})}else{const g=()=>e.moduleRef.destroy(),x=e.platformInjector.get(Kv);x.add(g),e.moduleRef.onDestroy(()=>{vv(e.allPlatformModules,e.moduleRef),p.unsubscribe(),x.delete(g)})}return function UA(e,t,n){try{const l=n();return jb(l)?l.catch(p=>{throw t.runOutsideAngular(()=>e.handleError(p)),p}):l}catch(l){throw t.runOutsideAngular(()=>e.handleError(l)),l}}(l,n,()=>{const g=t.get(R1);return g.runInitializers(),g.donePromise.then(()=>{if(function KM(e){"string"==typeof e&&(Sx=e.toLowerCase().replace(/_/g,"-"))}(t.get(dw,Bv)||Bv),Gv(e)){const k=t.get(hc);return void 0!==e.rootComponent&&k.bootstrap(e.rootComponent),k}return function YI(e,t){const n=e.injector.get(hc);if(e._bootstrapComponents.length>0)e._bootstrapComponents.forEach(l=>n.bootstrap(l));else{if(!e.instance.ngDoBootstrap)throw new Rn(-403,!1);e.instance.ngDoBootstrap(n)}t.push(e)}(e.moduleRef,e.allPlatformModules),e.moduleRef})})})}({r3Injector:new m1({providers:g,parent:p,debugName:"",runEnvironmentInitializers:!1}).injector,platformInjector:p,rootComponent:t})}catch(t){return Promise.reject(t)}}function GO(e){return"boolean"==typeof e?e:null!=e&&"false"!==e}function XO(e,t=NaN){return isNaN(parseFloat(e))||isNaN(Number(e))?t:Number(e)}function xw(e,t){oi("NgSignals");const n=bt(e);return t?.equal&&(n[C].equal=t.equal),n}function Zp(e){const t=T(null);try{return e()}finally{T(t)}}let aD=(()=>class e{view;node;constructor(n,l){this.view=n,this.node=l}static __NG_ELEMENT_ID__=eR})();function eR(){return new aD(En(),Si())}let nR=(()=>{class e extends N1{pendingTasks=lr(Ec);taskId=null;schedule(n){super.schedule(n),null===this.taskId&&(this.taskId=this.pendingTasks.add(),queueMicrotask(()=>this.flush()))}flush(){try{super.flush()}finally{null!==this.taskId&&(this.pendingTasks.remove(this.taskId),this.taskId=null)}}static \u0275prov=ai({token:e,providedIn:"root",factory:()=>new e})}return e})();class rR{scheduler;effectFn;zone;injector;unregisterOnDestroy;watcher;constructor(t,n,l,p,g,x){this.scheduler=t,this.effectFn=n,this.zone=l,this.injector=g,this.watcher=function Ee(e,t,n){const l=Object.create(Xt);n&&(l.consumerAllowSignalWrites=!0),l.fn=e,l.schedule=t;const p=B=>{l.cleanupFn=B};return l.ref={notify:()=>ae(l),run:()=>{if(null===l.fn)return;if(function M(){return y}())throw new Error("Schedulers cannot synchronously execute watches while scheduling.");if(l.dirty=!1,l.hasRun&&!xe(l))return;l.hasRun=!0;const B=be(l);try{l.cleanupFn(),l.cleanupFn=st,l.fn(p)}finally{Oe(l,B)}},cleanup:()=>l.cleanupFn(),destroy:()=>function x(B){(function g(B){return null===B.fn&&null===B.schedule})(B)||(De(B),B.cleanupFn(),B.fn=null,B.schedule=null,B.cleanupFn=st)}(l),[C]:l},l.ref}(k=>this.runEffect(k),()=>this.schedule(),x),this.unregisterOnDestroy=p?.onDestroy(()=>this.destroy())}runEffect(t){try{this.effectFn(t)}catch(n){this.injector.get(Cc,null,{optional:!0})?.handleError(n)}}run(){this.watcher.run()}schedule(){this.scheduler.schedule(this)}destroy(){this.watcher.destroy(),this.unregisterOnDestroy?.()}}let Cw=!1;class sR{[C];constructor(t){this[C]=t}destroy(){this[C].destroy()}}function Dw(e,t){if(Cw)return function oR(e,t){oi("NgSignals"),!t?.injector&&Sa();const n=t?.injector??lr(Qo),l=!0!==t?.manualCleanup?n.get(ws):null,p=new rR(n.get(nR),e,typeof Zone>"u"?null:Zone.current,l,n,t?.allowSignalWrites??!1),g=n.get(C2,null,{optional:!0});return g&&8&g._lView[Sr]?(g._lView[ne]??=[]).push(p.watcher.notify):p.watcher.notify(),p}(e,t);oi("NgSignals"),!t?.injector&&Sa();const n=t?.injector??lr(Qo);let p,l=!0!==t?.manualCleanup?n.get(ws):null;const g=n.get(aD,null,{optional:!0}),x=n.get(rc);return null===g||t?.forceRoot?p=function uR(e,t,n){const l=Object.create(aR);return l.fn=e,l.scheduler=t,l.notifier=n,l.zone=typeof Zone<"u"?Zone.current:null,l.scheduler.schedule(l),l.notifier.notify(13),l}(e,n.get(Hb),x):(p=function cR(e,t,n){const l=Object.create(lR);return l.view=e,l.zone=typeof Zone<"u"?Zone.current:null,l.notifier=t,l.fn=n,e[ye]??=new Set,e[ye].add(l),l.consumerMarkedDirty(l),l}(g.view,x,e),l instanceof Fc&&l._lView===g.view&&(l=null)),p.injector=n,null!==l&&(p.onDestroyFn=l.onDestroy(()=>p.destroy())),new sR(p)}const lD={...L,consumerIsAlwaysLive:!0,consumerAllowSignalWrites:!0,dirty:!0,hasRun:!1,cleanupFns:void 0,zone:null,onDestroyFn:_u,run(){if(this.dirty=!1,this.hasRun&&!xe(this))return;this.hasRun=!0;const e=l=>(this.cleanupFns??=[]).push(l),t=be(this),n=ql(!1);try{this.maybeCleanup(),this.fn(e)}finally{ql(n),Oe(this,t)}},maybeCleanup(){if(this.cleanupFns?.length)try{for(;this.cleanupFns.length;)this.cleanupFns.pop()()}finally{this.cleanupFns=[]}}},aR={...lD,consumerMarkedDirty(){this.scheduler.schedule(this),this.notifier.notify(13)},destroy(){De(this),this.onDestroyFn(),this.maybeCleanup()}},lR={...lD,consumerMarkedDirty(){this.view[Sr]|=8192,Is(this.view),this.notifier.notify(14)},destroy(){De(this),this.onDestroyFn(),this.maybeCleanup(),this.view[ye]?.delete(this)}};function vR(e,t){const n=zr(e),l=t.elementInjector||_i();return new hg(n).create(l,t.projectableNodes,t.hostElement,t.environmentInjector)}function yR(e){const t=zr(e);if(!t)return null;const n=new hg(t);return{get selector(){return n.selector},get type(){return n.componentType},get inputs(){return n.inputs},get outputs(){return n.outputs},get ngContentSelectors(){return n.ngContentSelectors},get isStandalone(){return t.standalone},get isSignal(){return t.signals}}}},936:(o,s,r)=>{"use strict";r.d(s,{BC:()=>en,JD:()=>Ao,Q0:()=>aa,X1:()=>da,YN:()=>$a,YS:()=>Ba,cV:()=>Nn,cb:()=>kn,cz:()=>me,hs:()=>wr,j4:()=>Ds,k0:()=>xe,kq:()=>M,l_:()=>Rs,me:()=>pe,ok:()=>Ro,qT:()=>Li,tU:()=>Bn,vO:()=>Mt,vS:()=>sa,xq:()=>Aa,ze:()=>Ho});var i=r(3107),a=r(4460),c=r(1787),y=r(2653),w=r(8447),C=r(7947);let T=(()=>{class de{_renderer;_elementRef;onChange=Y=>{};onTouched=()=>{};constructor(Y,Ue){this._renderer=Y,this._elementRef=Ue}setProperty(Y,Ue){this._renderer.setProperty(this._elementRef.nativeElement,Y,Ue)}registerOnTouched(Y){this.onTouched=Y}registerOnChange(Y){this.onChange=Y}setDisabledState(Y){this.setProperty("disabled",Y)}static \u0275fac=function(Ue){return new(Ue||de)(i.rXU(i.sFG),i.rXU(i.aKT))};static \u0275dir=i.FsC({type:de})}return de})(),S=(()=>{class de extends T{static \u0275fac=(()=>{let Y;return function(jt){return(Y||(Y=i.xGo(de)))(jt||de)}})();static \u0275dir=i.FsC({type:de,features:[i.Vt3]})}return de})();const M=new i.nKC(""),Z={provide:M,useExisting:(0,i.Rfq)(()=>pe),multi:!0},re=new i.nKC("");let pe=(()=>{class de extends T{_compositionMode;_composing=!1;constructor(Y,Ue,jt){super(Y,Ue),this._compositionMode=jt,null==this._compositionMode&&(this._compositionMode=!function q(){const de=(0,a.QT)()?(0,a.QT)().getUserAgent():"";return/android (\d+)/.test(de.toLowerCase())}())}writeValue(Y){this.setProperty("value",Y??"")}_handleInput(Y){(!this._compositionMode||this._compositionMode&&!this._composing)&&this.onChange(Y)}_compositionStart(){this._composing=!0}_compositionEnd(Y){this._composing=!1,this._compositionMode&&this.onChange(Y)}static \u0275fac=function(Ue){return new(Ue||de)(i.rXU(i.sFG),i.rXU(i.aKT),i.rXU(re,8))};static \u0275dir=i.FsC({type:de,selectors:[["input","formControlName","",3,"type","checkbox"],["textarea","formControlName",""],["input","formControl","",3,"type","checkbox"],["textarea","formControl",""],["input","ngModel","",3,"type","checkbox"],["textarea","ngModel",""],["","ngDefaultControl",""]],hostBindings:function(Ue,jt){1&Ue&&i.bIt("input",function(Jr){return jt._handleInput(Jr.target.value)})("blur",function(){return jt.onTouched()})("compositionstart",function(){return jt._compositionStart()})("compositionend",function(Jr){return jt._compositionEnd(Jr.target.value)})},standalone:!1,features:[i.Jv_([Z]),i.Vt3]})}return de})();function se(de){return null==de||("string"==typeof de||Array.isArray(de))&&0===de.length}function ae(de){return null!=de&&"number"==typeof de.length}const me=new i.nKC(""),be=new i.nKC(""),Oe=/^(?=.{1,254}$)(?=.{1,64}@)[a-zA-Z0-9!#$%&'*+/=?^_`{|}~-]+(?:\.[a-zA-Z0-9!#$%&'*+/=?^_`{|}~-]+)*@[a-zA-Z0-9](?:[a-zA-Z0-9-]{0,61}[a-zA-Z0-9])?(?:\.[a-zA-Z0-9](?:[a-zA-Z0-9-]{0,61}[a-zA-Z0-9])?)*$/;class xe{static min(he){return function De(de){return he=>{if(se(he.value)||se(de))return null;const Y=parseFloat(he.value);return!isNaN(Y)&&Y{if(se(he.value)||se(de))return null;const Y=parseFloat(he.value);return!isNaN(Y)&&Y>de?{max:{max:de,actual:he.value}}:null}}(he)}static required(he){return ue(he)}static requiredTrue(he){return Ce(he)}static email(he){return function Be(de){return se(de.value)||Oe.test(de.value)?null:{email:!0}}(he)}static minLength(he){return function at(de){return he=>se(he.value)||!ae(he.value)?null:he.value.length{if(se(Ue.value))return null;const jt=Ue.value;return he.test(jt)?null:{pattern:{requiredPattern:Y,actualValue:jt}}}}(he)}static nullValidator(he){return null}static compose(he){return _t(he)}static composeAsync(he){return $e(he)}}function ue(de){return se(de.value)?{required:!0}:null}function Ce(de){return!0===de.value?null:{required:!0}}function dt(de){return he=>ae(he.value)&&he.value.length>de?{maxlength:{requiredLength:de,actualLength:he.value.length}}:null}function lt(de){return null}function rn(de){return null!=de}function gn(de){return(0,i.jNT)(de)?(0,c.H)(de):de}function bn(de){let he={};return de.forEach(Y=>{he=null!=Y?{...he,...Y}:he}),0===Object.keys(he).length?null:he}function Vn(de,he){return he.map(Y=>Y(de))}function qe(de){return de.map(he=>function yn(de){return!de.validate}(he)?he:Y=>he.validate(Y))}function _t(de){if(!de)return null;const he=de.filter(rn);return 0==he.length?null:function(Y){return bn(Vn(Y,he))}}function ze(de){return null!=de?_t(qe(de)):null}function $e(de){if(!de)return null;const he=de.filter(rn);return 0==he.length?null:function(Y){const Ue=Vn(Y,he).map(gn);return(0,y.p)(Ue).pipe((0,C.T)(bn))}}function Ft(de){return null!=de?$e(qe(de)):null}function Ke(de,he){return null===de?[he]:Array.isArray(de)?[...de,he]:[de,he]}function Ze(de){return de._rawValidators}function it(de){return de._rawAsyncValidators}function Ot(de){return de?Array.isArray(de)?de:[de]:[]}function $t(de,he){return Array.isArray(de)?de.includes(he):de===he}function Te(de,he){const Y=Ot(he);return Ot(de).forEach(jt=>{$t(Y,jt)||Y.push(jt)}),Y}function Ee(de,he){return Ot(he).filter(Y=>!$t(de,Y))}class st{get value(){return this.control?this.control.value:null}get valid(){return this.control?this.control.valid:null}get invalid(){return this.control?this.control.invalid:null}get pending(){return this.control?this.control.pending:null}get disabled(){return this.control?this.control.disabled:null}get enabled(){return this.control?this.control.enabled:null}get errors(){return this.control?this.control.errors:null}get pristine(){return this.control?this.control.pristine:null}get dirty(){return this.control?this.control.dirty:null}get touched(){return this.control?this.control.touched:null}get status(){return this.control?this.control.status:null}get untouched(){return this.control?this.control.untouched:null}get statusChanges(){return this.control?this.control.statusChanges:null}get valueChanges(){return this.control?this.control.valueChanges:null}get path(){return null}_composedValidatorFn;_composedAsyncValidatorFn;_rawValidators=[];_rawAsyncValidators=[];_setValidators(he){this._rawValidators=he||[],this._composedValidatorFn=ze(this._rawValidators)}_setAsyncValidators(he){this._rawAsyncValidators=he||[],this._composedAsyncValidatorFn=Ft(this._rawAsyncValidators)}get validator(){return this._composedValidatorFn||null}get asyncValidator(){return this._composedAsyncValidatorFn||null}_onDestroyCallbacks=[];_registerOnDestroy(he){this._onDestroyCallbacks.push(he)}_invokeOnDestroyCallbacks(){this._onDestroyCallbacks.forEach(he=>he()),this._onDestroyCallbacks=[]}reset(he=void 0){this.control&&this.control.reset(he)}hasError(he,Y){return!!this.control&&this.control.hasError(he,Y)}getError(he,Y){return this.control?this.control.getError(he,Y):null}}class Xt extends st{name;get formDirective(){return null}get path(){return null}}class Mt extends st{_parent=null;name=null;valueAccessor=null}class Kt{_cd;constructor(he){this._cd=he}get isTouched(){return this._cd?.control?._touched?.(),!!this._cd?.control?.touched}get isUntouched(){return!!this._cd?.control?.untouched}get isPristine(){return this._cd?.control?._pristine?.(),!!this._cd?.control?.pristine}get isDirty(){return!!this._cd?.control?.dirty}get isValid(){return this._cd?.control?._status?.(),!!this._cd?.control?.valid}get isInvalid(){return!!this._cd?.control?.invalid}get isPending(){return!!this._cd?.control?.pending}get isSubmitted(){return this._cd?._submitted?.(),!!this._cd?.submitted}}let en=(()=>{class de extends Kt{constructor(Y){super(Y)}static \u0275fac=function(Ue){return new(Ue||de)(i.rXU(Mt,2))};static \u0275dir=i.FsC({type:de,selectors:[["","formControlName",""],["","ngModel",""],["","formControl",""]],hostVars:14,hostBindings:function(Ue,jt){2&Ue&&i.AVh("ng-untouched",jt.isUntouched)("ng-touched",jt.isTouched)("ng-pristine",jt.isPristine)("ng-dirty",jt.isDirty)("ng-valid",jt.isValid)("ng-invalid",jt.isInvalid)("ng-pending",jt.isPending)},standalone:!1,features:[i.Vt3]})}return de})(),kn=(()=>{class de extends Kt{constructor(Y){super(Y)}static \u0275fac=function(Ue){return new(Ue||de)(i.rXU(Xt,10))};static \u0275dir=i.FsC({type:de,selectors:[["","formGroupName",""],["","formArrayName",""],["","ngModelGroup",""],["","formGroup",""],["form",3,"ngNoForm",""],["","ngForm",""]],hostVars:16,hostBindings:function(Ue,jt){2&Ue&&i.AVh("ng-untouched",jt.isUntouched)("ng-touched",jt.isTouched)("ng-pristine",jt.isPristine)("ng-dirty",jt.isDirty)("ng-valid",jt.isValid)("ng-invalid",jt.isInvalid)("ng-pending",jt.isPending)("ng-submitted",jt.isSubmitted)},standalone:!1,features:[i.Vt3]})}return de})();const In="VALID",sr="INVALID",xn="PENDING",Hr="DISABLED";class Tr{}class Vr extends Tr{value;source;constructor(he,Y){super(),this.value=he,this.source=Y}}class vt extends Tr{pristine;source;constructor(he,Y){super(),this.pristine=he,this.source=Y}}class Wt extends Tr{touched;source;constructor(he,Y){super(),this.touched=he,this.source=Y}}class Re extends Tr{status;source;constructor(he,Y){super(),this.status=he,this.source=Y}}class Ge extends Tr{source;constructor(he){super(),this.source=he}}class Ve extends Tr{source;constructor(he){super(),this.source=he}}function Dt(de){return(qn(de)?de.validators:de)||null}function Bt(de,he){return(qn(he)?he.asyncValidators:de)||null}function qn(de){return null!=de&&!Array.isArray(de)&&"object"==typeof de}function Er(de,he,Y){const Ue=de.controls;if(!(he?Object.keys(Ue):Ue).length)throw new i.wOt(1e3,"");if(!Ue[Y])throw new i.wOt(1001,"")}function si(de,he,Y){de._forEachChild((Ue,jt)=>{if(void 0===Y[jt])throw new i.wOt(1002,"")})}class hi{_pendingDirty=!1;_hasOwnPendingAsyncValidator=null;_pendingTouched=!1;_onCollectionChange=()=>{};_updateOn;_parent=null;_asyncValidationSubscription;_composedValidatorFn;_composedAsyncValidatorFn;_rawValidators;_rawAsyncValidators;value;constructor(he,Y){this._assignValidators(he),this._assignAsyncValidators(Y)}get validator(){return this._composedValidatorFn}set validator(he){this._rawValidators=this._composedValidatorFn=he}get asyncValidator(){return this._composedAsyncValidatorFn}set asyncValidator(he){this._rawAsyncValidators=this._composedAsyncValidatorFn=he}get parent(){return this._parent}get status(){return(0,i.O8t)(this.statusReactive)}set status(he){(0,i.O8t)(()=>this.statusReactive.set(he))}_status=(0,i.EWP)(()=>this.statusReactive());statusReactive=(0,i.vPA)(void 0);get valid(){return this.status===In}get invalid(){return this.status===sr}get pending(){return this.status==xn}get disabled(){return this.status===Hr}get enabled(){return this.status!==Hr}errors;get pristine(){return(0,i.O8t)(this.pristineReactive)}set pristine(he){(0,i.O8t)(()=>this.pristineReactive.set(he))}_pristine=(0,i.EWP)(()=>this.pristineReactive());pristineReactive=(0,i.vPA)(!0);get dirty(){return!this.pristine}get touched(){return(0,i.O8t)(this.touchedReactive)}set touched(he){(0,i.O8t)(()=>this.touchedReactive.set(he))}_touched=(0,i.EWP)(()=>this.touchedReactive());touchedReactive=(0,i.vPA)(!1);get untouched(){return!this.touched}_events=new w.B;events=this._events.asObservable();valueChanges;statusChanges;get updateOn(){return this._updateOn?this._updateOn:this.parent?this.parent.updateOn:"change"}setValidators(he){this._assignValidators(he)}setAsyncValidators(he){this._assignAsyncValidators(he)}addValidators(he){this.setValidators(Te(he,this._rawValidators))}addAsyncValidators(he){this.setAsyncValidators(Te(he,this._rawAsyncValidators))}removeValidators(he){this.setValidators(Ee(he,this._rawValidators))}removeAsyncValidators(he){this.setAsyncValidators(Ee(he,this._rawAsyncValidators))}hasValidator(he){return $t(this._rawValidators,he)}hasAsyncValidator(he){return $t(this._rawAsyncValidators,he)}clearValidators(){this.validator=null}clearAsyncValidators(){this.asyncValidator=null}markAsTouched(he={}){const Y=!1===this.touched;this.touched=!0;const Ue=he.sourceControl??this;this._parent&&!he.onlySelf&&this._parent.markAsTouched({...he,sourceControl:Ue}),Y&&!1!==he.emitEvent&&this._events.next(new Wt(!0,Ue))}markAllAsTouched(he={}){this.markAsTouched({onlySelf:!0,emitEvent:he.emitEvent,sourceControl:this}),this._forEachChild(Y=>Y.markAllAsTouched(he))}markAsUntouched(he={}){const Y=!0===this.touched;this.touched=!1,this._pendingTouched=!1;const Ue=he.sourceControl??this;this._forEachChild(jt=>{jt.markAsUntouched({onlySelf:!0,emitEvent:he.emitEvent,sourceControl:Ue})}),this._parent&&!he.onlySelf&&this._parent._updateTouched(he,Ue),Y&&!1!==he.emitEvent&&this._events.next(new Wt(!1,Ue))}markAsDirty(he={}){const Y=!0===this.pristine;this.pristine=!1;const Ue=he.sourceControl??this;this._parent&&!he.onlySelf&&this._parent.markAsDirty({...he,sourceControl:Ue}),Y&&!1!==he.emitEvent&&this._events.next(new vt(!1,Ue))}markAsPristine(he={}){const Y=!1===this.pristine;this.pristine=!0,this._pendingDirty=!1;const Ue=he.sourceControl??this;this._forEachChild(jt=>{jt.markAsPristine({onlySelf:!0,emitEvent:he.emitEvent})}),this._parent&&!he.onlySelf&&this._parent._updatePristine(he,Ue),Y&&!1!==he.emitEvent&&this._events.next(new vt(!0,Ue))}markAsPending(he={}){this.status=xn;const Y=he.sourceControl??this;!1!==he.emitEvent&&(this._events.next(new Re(this.status,Y)),this.statusChanges.emit(this.status)),this._parent&&!he.onlySelf&&this._parent.markAsPending({...he,sourceControl:Y})}disable(he={}){const Y=this._parentMarkedDirty(he.onlySelf);this.status=Hr,this.errors=null,this._forEachChild(jt=>{jt.disable({...he,onlySelf:!0})}),this._updateValue();const Ue=he.sourceControl??this;!1!==he.emitEvent&&(this._events.next(new Vr(this.value,Ue)),this._events.next(new Re(this.status,Ue)),this.valueChanges.emit(this.value),this.statusChanges.emit(this.status)),this._updateAncestors({...he,skipPristineCheck:Y},this),this._onDisabledChange.forEach(jt=>jt(!0))}enable(he={}){const Y=this._parentMarkedDirty(he.onlySelf);this.status=In,this._forEachChild(Ue=>{Ue.enable({...he,onlySelf:!0})}),this.updateValueAndValidity({onlySelf:!0,emitEvent:he.emitEvent}),this._updateAncestors({...he,skipPristineCheck:Y},this),this._onDisabledChange.forEach(Ue=>Ue(!1))}_updateAncestors(he,Y){this._parent&&!he.onlySelf&&(this._parent.updateValueAndValidity(he),he.skipPristineCheck||this._parent._updatePristine({},Y),this._parent._updateTouched({},Y))}setParent(he){this._parent=he}getRawValue(){return this.value}updateValueAndValidity(he={}){if(this._setInitialStatus(),this._updateValue(),this.enabled){const Ue=this._cancelExistingSubscription();this.errors=this._runValidator(),this.status=this._calculateStatus(),(this.status===In||this.status===xn)&&this._runAsyncValidator(Ue,he.emitEvent)}const Y=he.sourceControl??this;!1!==he.emitEvent&&(this._events.next(new Vr(this.value,Y)),this._events.next(new Re(this.status,Y)),this.valueChanges.emit(this.value),this.statusChanges.emit(this.status)),this._parent&&!he.onlySelf&&this._parent.updateValueAndValidity({...he,sourceControl:Y})}_updateTreeValidity(he={emitEvent:!0}){this._forEachChild(Y=>Y._updateTreeValidity(he)),this.updateValueAndValidity({onlySelf:!0,emitEvent:he.emitEvent})}_setInitialStatus(){this.status=this._allControlsDisabled()?Hr:In}_runValidator(){return this.validator?this.validator(this):null}_runAsyncValidator(he,Y){if(this.asyncValidator){this.status=xn,this._hasOwnPendingAsyncValidator={emitEvent:!1!==Y};const Ue=gn(this.asyncValidator(this));this._asyncValidationSubscription=Ue.subscribe(jt=>{this._hasOwnPendingAsyncValidator=null,this.setErrors(jt,{emitEvent:Y,shouldHaveEmitted:he})})}}_cancelExistingSubscription(){if(this._asyncValidationSubscription){this._asyncValidationSubscription.unsubscribe();const he=this._hasOwnPendingAsyncValidator?.emitEvent??!1;return this._hasOwnPendingAsyncValidator=null,he}return!1}setErrors(he,Y={}){this.errors=he,this._updateControlsErrors(!1!==Y.emitEvent,this,Y.shouldHaveEmitted)}get(he){let Y=he;return null==Y||(Array.isArray(Y)||(Y=Y.split(".")),0===Y.length)?null:Y.reduce((Ue,jt)=>Ue&&Ue._find(jt),this)}getError(he,Y){const Ue=Y?this.get(Y):this;return Ue&&Ue.errors?Ue.errors[he]:null}hasError(he,Y){return!!this.getError(he,Y)}get root(){let he=this;for(;he._parent;)he=he._parent;return he}_updateControlsErrors(he,Y,Ue){this.status=this._calculateStatus(),he&&this.statusChanges.emit(this.status),(he||Ue)&&this._events.next(new Re(this.status,Y)),this._parent&&this._parent._updateControlsErrors(he,Y,Ue)}_initObservables(){this.valueChanges=new i.bkB,this.statusChanges=new i.bkB}_calculateStatus(){return this._allControlsDisabled()?Hr:this.errors?sr:this._hasOwnPendingAsyncValidator||this._anyControlsHaveStatus(xn)?xn:this._anyControlsHaveStatus(sr)?sr:In}_anyControlsHaveStatus(he){return this._anyControls(Y=>Y.status===he)}_anyControlsDirty(){return this._anyControls(he=>he.dirty)}_anyControlsTouched(){return this._anyControls(he=>he.touched)}_updatePristine(he,Y){const Ue=!this._anyControlsDirty(),jt=this.pristine!==Ue;this.pristine=Ue,this._parent&&!he.onlySelf&&this._parent._updatePristine(he,Y),jt&&this._events.next(new vt(this.pristine,Y))}_updateTouched(he={},Y){this.touched=this._anyControlsTouched(),this._events.next(new Wt(this.touched,Y)),this._parent&&!he.onlySelf&&this._parent._updateTouched(he,Y)}_onDisabledChange=[];_registerOnCollectionChange(he){this._onCollectionChange=he}_setUpdateStrategy(he){qn(he)&&null!=he.updateOn&&(this._updateOn=he.updateOn)}_parentMarkedDirty(he){return!he&&!(!this._parent||!this._parent.dirty)&&!this._parent._anyControlsDirty()}_find(he){return null}_assignValidators(he){this._rawValidators=Array.isArray(he)?he.slice():he,this._composedValidatorFn=function ct(de){return Array.isArray(de)?ze(de):de||null}(this._rawValidators)}_assignAsyncValidators(he){this._rawAsyncValidators=Array.isArray(he)?he.slice():he,this._composedAsyncValidatorFn=function wn(de){return Array.isArray(de)?Ft(de):de||null}(this._rawAsyncValidators)}}class Zi extends hi{constructor(he,Y,Ue){super(Dt(Y),Bt(Ue,Y)),this.controls=he,this._initObservables(),this._setUpdateStrategy(Y),this._setUpControls(),this.updateValueAndValidity({onlySelf:!0,emitEvent:!!this.asyncValidator})}controls;registerControl(he,Y){return this.controls[he]?this.controls[he]:(this.controls[he]=Y,Y.setParent(this),Y._registerOnCollectionChange(this._onCollectionChange),Y)}addControl(he,Y,Ue={}){this.registerControl(he,Y),this.updateValueAndValidity({emitEvent:Ue.emitEvent}),this._onCollectionChange()}removeControl(he,Y={}){this.controls[he]&&this.controls[he]._registerOnCollectionChange(()=>{}),delete this.controls[he],this.updateValueAndValidity({emitEvent:Y.emitEvent}),this._onCollectionChange()}setControl(he,Y,Ue={}){this.controls[he]&&this.controls[he]._registerOnCollectionChange(()=>{}),delete this.controls[he],Y&&this.registerControl(he,Y),this.updateValueAndValidity({emitEvent:Ue.emitEvent}),this._onCollectionChange()}contains(he){return this.controls.hasOwnProperty(he)&&this.controls[he].enabled}setValue(he,Y={}){si(this,0,he),Object.keys(he).forEach(Ue=>{Er(this,!0,Ue),this.controls[Ue].setValue(he[Ue],{onlySelf:!0,emitEvent:Y.emitEvent})}),this.updateValueAndValidity(Y)}patchValue(he,Y={}){null!=he&&(Object.keys(he).forEach(Ue=>{const jt=this.controls[Ue];jt&&jt.patchValue(he[Ue],{onlySelf:!0,emitEvent:Y.emitEvent})}),this.updateValueAndValidity(Y))}reset(he={},Y={}){this._forEachChild((Ue,jt)=>{Ue.reset(he?he[jt]:null,{onlySelf:!0,emitEvent:Y.emitEvent})}),this._updatePristine(Y,this),this._updateTouched(Y,this),this.updateValueAndValidity(Y)}getRawValue(){return this._reduceChildren({},(he,Y,Ue)=>(he[Ue]=Y.getRawValue(),he))}_syncPendingControls(){let he=this._reduceChildren(!1,(Y,Ue)=>!!Ue._syncPendingControls()||Y);return he&&this.updateValueAndValidity({onlySelf:!0}),he}_forEachChild(he){Object.keys(this.controls).forEach(Y=>{const Ue=this.controls[Y];Ue&&he(Ue,Y)})}_setUpControls(){this._forEachChild(he=>{he.setParent(this),he._registerOnCollectionChange(this._onCollectionChange)})}_updateValue(){this.value=this._reduceValue()}_anyControls(he){for(const[Y,Ue]of Object.entries(this.controls))if(this.contains(Y)&&he(Ue))return!0;return!1}_reduceValue(){return this._reduceChildren({},(Y,Ue,jt)=>((Ue.enabled||this.disabled)&&(Y[jt]=Ue.value),Y))}_reduceChildren(he,Y){let Ue=he;return this._forEachChild((jt,br)=>{Ue=Y(Ue,jt,br)}),Ue}_allControlsDisabled(){for(const he of Object.keys(this.controls))if(this.controls[he].enabled)return!1;return Object.keys(this.controls).length>0||this.disabled}_find(he){return this.controls.hasOwnProperty(he)?this.controls[he]:null}}class Rt extends Zi{}const mn=new i.nKC("CallSetDisabledState",{providedIn:"root",factory:()=>dr}),dr="always";function Co(de,he){return[...he.path,de]}function Ni(de,he,Y=dr){qo(de,he),he.valueAccessor.writeValue(de.value),(de.disabled||"always"===Y)&&he.valueAccessor.setDisabledState?.(de.disabled),function Jo(de,he){he.valueAccessor.registerOnChange(Y=>{de._pendingValue=Y,de._pendingChange=!0,de._pendingDirty=!0,"change"===de.updateOn&&oa(de,he)})}(de,he),function ao(de,he){const Y=(Ue,jt)=>{he.valueAccessor.writeValue(Ue),jt&&he.viewToModelUpdate(Ue)};de.registerOnChange(Y),he._registerOnDestroy(()=>{de._unregisterOnChange(Y)})}(de,he),function Fo(de,he){he.valueAccessor.registerOnTouched(()=>{de._pendingTouched=!0,"blur"===de.updateOn&&de._pendingChange&&oa(de,he),"submit"!==de.updateOn&&de.markAsTouched()})}(de,he),function ai(de,he){if(he.valueAccessor.setDisabledState){const Y=Ue=>{he.valueAccessor.setDisabledState(Ue)};de.registerOnDisabledChange(Y),he._registerOnDestroy(()=>{de._unregisterOnDisabledChange(Y)})}}(de,he)}function ds(de,he,Y=!0){const Ue=()=>{};he.valueAccessor&&(he.valueAccessor.registerOnChange(Ue),he.valueAccessor.registerOnTouched(Ue)),fo(de,he),de&&(he._invokeOnDestroyCallbacks(),de._registerOnCollectionChange(()=>{}))}function $o(de,he){de.forEach(Y=>{Y.registerOnValidatorChange&&Y.registerOnValidatorChange(he)})}function qo(de,he){const Y=Ze(de);null!==he.validator?de.setValidators(Ke(Y,he.validator)):"function"==typeof Y&&de.setValidators([Y]);const Ue=it(de);null!==he.asyncValidator?de.setAsyncValidators(Ke(Ue,he.asyncValidator)):"function"==typeof Ue&&de.setAsyncValidators([Ue]);const jt=()=>de.updateValueAndValidity();$o(he._rawValidators,jt),$o(he._rawAsyncValidators,jt)}function fo(de,he){let Y=!1;if(null!==de){if(null!==he.validator){const jt=Ze(de);if(Array.isArray(jt)&&jt.length>0){const br=jt.filter(Jr=>Jr!==he.validator);br.length!==jt.length&&(Y=!0,de.setValidators(br))}}if(null!==he.asyncValidator){const jt=it(de);if(Array.isArray(jt)&&jt.length>0){const br=jt.filter(Jr=>Jr!==he.asyncValidator);br.length!==jt.length&&(Y=!0,de.setAsyncValidators(br))}}}const Ue=()=>{};return $o(he._rawValidators,Ue),$o(he._rawAsyncValidators,Ue),Y}function oa(de,he){de._pendingDirty&&de.markAsDirty(),de.setValue(de._pendingValue,{emitModelToViewChange:!1}),he.viewToModelUpdate(de._pendingValue),de._pendingChange=!1}function po(de,he){qo(de,he)}function Ye(de,he){if(!de.hasOwnProperty("model"))return!1;const Y=de.model;return!!Y.isFirstChange()||!Object.is(he,Y.currentValue)}function gt(de,he){de._syncPendingControls(),he.forEach(Y=>{const Ue=Y.control;"submit"===Ue.updateOn&&Ue._pendingChange&&(Y.viewToModelUpdate(Ue._pendingValue),Ue._pendingChange=!1)})}function Ht(de,he){if(!he)return null;let Y,Ue,jt;return Array.isArray(he),he.forEach(br=>{br.constructor===pe?Y=br:function Ne(de){return Object.getPrototypeOf(de.constructor)===S}(br)?Ue=br:jt=br}),jt||Ue||Y||null}const Dn={provide:Xt,useExisting:(0,i.Rfq)(()=>Nn)},Cn=Promise.resolve();let Nn=(()=>{class de extends Xt{callSetDisabledState;get submitted(){return(0,i.O8t)(this.submittedReactive)}_submitted=(0,i.EWP)(()=>this.submittedReactive());submittedReactive=(0,i.vPA)(!1);_directives=new Set;form;ngSubmit=new i.bkB;options;constructor(Y,Ue,jt){super(),this.callSetDisabledState=jt,this.form=new Zi({},ze(Y),Ft(Ue))}ngAfterViewInit(){this._setUpdateStrategy()}get formDirective(){return this}get control(){return this.form}get path(){return[]}get controls(){return this.form.controls}addControl(Y){Cn.then(()=>{const Ue=this._findContainer(Y.path);Y.control=Ue.registerControl(Y.name,Y.control),Ni(Y.control,Y,this.callSetDisabledState),Y.control.updateValueAndValidity({emitEvent:!1}),this._directives.add(Y)})}getControl(Y){return this.form.get(Y.path)}removeControl(Y){Cn.then(()=>{const Ue=this._findContainer(Y.path);Ue&&Ue.removeControl(Y.name),this._directives.delete(Y)})}addFormGroup(Y){Cn.then(()=>{const Ue=this._findContainer(Y.path),jt=new Zi({});po(jt,Y),Ue.registerControl(Y.name,jt),jt.updateValueAndValidity({emitEvent:!1})})}removeFormGroup(Y){Cn.then(()=>{const Ue=this._findContainer(Y.path);Ue&&Ue.removeControl(Y.name)})}getFormGroup(Y){return this.form.get(Y.path)}updateModel(Y,Ue){Cn.then(()=>{this.form.get(Y.path).setValue(Ue)})}setValue(Y){this.control.setValue(Y)}onSubmit(Y){return this.submittedReactive.set(!0),gt(this.form,this._directives),this.ngSubmit.emit(Y),"dialog"===Y?.target?.method}onReset(){this.resetForm()}resetForm(Y=void 0){this.form.reset(Y),this.submittedReactive.set(!1)}_setUpdateStrategy(){this.options&&null!=this.options.updateOn&&(this.form._updateOn=this.options.updateOn)}_findContainer(Y){return Y.pop(),Y.length?this.form.get(Y):this.form}static \u0275fac=function(Ue){return new(Ue||de)(i.rXU(me,10),i.rXU(be,10),i.rXU(mn,8))};static \u0275dir=i.FsC({type:de,selectors:[["form",3,"ngNoForm","",3,"formGroup",""],["ng-form"],["","ngForm",""]],hostBindings:function(Ue,jt){1&Ue&&i.bIt("submit",function(Jr){return jt.onSubmit(Jr)})("reset",function(){return jt.onReset()})},inputs:{options:[0,"ngFormOptions","options"]},outputs:{ngSubmit:"ngSubmit"},exportAs:["ngForm"],standalone:!1,features:[i.Jv_([Dn]),i.Vt3]})}return de})();function jn(de,he){const Y=de.indexOf(he);Y>-1&&de.splice(Y,1)}function Jn(de){return"object"==typeof de&&null!==de&&2===Object.keys(de).length&&"value"in de&&"disabled"in de}const ar=class extends hi{defaultValue=null;_onChange=[];_pendingValue;_pendingChange=!1;constructor(he=null,Y,Ue){super(Dt(Y),Bt(Ue,Y)),this._applyFormState(he),this._setUpdateStrategy(Y),this._initObservables(),this.updateValueAndValidity({onlySelf:!0,emitEvent:!!this.asyncValidator}),qn(Y)&&(Y.nonNullable||Y.initialValueIsDefault)&&(this.defaultValue=Jn(he)?he.value:he)}setValue(he,Y={}){this.value=this._pendingValue=he,this._onChange.length&&!1!==Y.emitModelToViewChange&&this._onChange.forEach(Ue=>Ue(this.value,!1!==Y.emitViewToModelChange)),this.updateValueAndValidity(Y)}patchValue(he,Y={}){this.setValue(he,Y)}reset(he=this.defaultValue,Y={}){this._applyFormState(he),this.markAsPristine(Y),this.markAsUntouched(Y),this.setValue(this.value,Y),this._pendingChange=!1}_updateValue(){}_anyControls(he){return!1}_allControlsDisabled(){return this.disabled}registerOnChange(he){this._onChange.push(he)}_unregisterOnChange(he){jn(this._onChange,he)}registerOnDisabledChange(he){this._onDisabledChange.push(he)}_unregisterOnDisabledChange(he){jn(this._onDisabledChange,he)}_forEachChild(he){}_syncPendingControls(){return!("submit"!==this.updateOn||(this._pendingDirty&&this.markAsDirty(),this._pendingTouched&&this.markAsTouched(),!this._pendingChange)||(this.setValue(this._pendingValue,{onlySelf:!0,emitModelToViewChange:!1}),0))}_applyFormState(he){Jn(he)?(this.value=this._pendingValue=he.value,he.disabled?this.disable({onlySelf:!0,emitEvent:!1}):this.enable({onlySelf:!0,emitEvent:!1})):this.value=this._pendingValue=he}},wr=ar,es={provide:Mt,useExisting:(0,i.Rfq)(()=>sa)},zs=Promise.resolve();let sa=(()=>{class de extends Mt{_changeDetectorRef;callSetDisabledState;control=new ar;static ngAcceptInputType_isDisabled;_registered=!1;viewModel;name="";isDisabled;model;options;update=new i.bkB;constructor(Y,Ue,jt,br,Jr,ts){super(),this._changeDetectorRef=Jr,this.callSetDisabledState=ts,this._parent=Y,this._setValidators(Ue),this._setAsyncValidators(jt),this.valueAccessor=Ht(0,br)}ngOnChanges(Y){if(this._checkForErrors(),!this._registered||"name"in Y){if(this._registered&&(this._checkName(),this.formDirective)){const Ue=Y.name.previousValue;this.formDirective.removeControl({name:Ue,path:this._getPath(Ue)})}this._setUpControl()}"isDisabled"in Y&&this._updateDisabled(Y),Ye(Y,this.viewModel)&&(this._updateValue(this.model),this.viewModel=this.model)}ngOnDestroy(){this.formDirective&&this.formDirective.removeControl(this)}get path(){return this._getPath(this.name)}get formDirective(){return this._parent?this._parent.formDirective:null}viewToModelUpdate(Y){this.viewModel=Y,this.update.emit(Y)}_setUpControl(){this._setUpdateStrategy(),this._isStandalone()?this._setUpStandalone():this.formDirective.addControl(this),this._registered=!0}_setUpdateStrategy(){this.options&&null!=this.options.updateOn&&(this.control._updateOn=this.options.updateOn)}_isStandalone(){return!this._parent||!(!this.options||!this.options.standalone)}_setUpStandalone(){Ni(this.control,this,this.callSetDisabledState),this.control.updateValueAndValidity({emitEvent:!1})}_checkForErrors(){this._isStandalone()||this._checkParentType(),this._checkName()}_checkParentType(){}_checkName(){this.options&&this.options.name&&(this.name=this.options.name),this._isStandalone()}_updateValue(Y){zs.then(()=>{this.control.setValue(Y,{emitViewToModelChange:!1}),this._changeDetectorRef?.markForCheck()})}_updateDisabled(Y){const Ue=Y.isDisabled.currentValue,jt=0!==Ue&&(0,i.L39)(Ue);zs.then(()=>{jt&&!this.control.disabled?this.control.disable():!jt&&this.control.disabled&&this.control.enable(),this._changeDetectorRef?.markForCheck()})}_getPath(Y){return this._parent?Co(Y,this._parent):[Y]}static \u0275fac=function(Ue){return new(Ue||de)(i.rXU(Xt,9),i.rXU(me,10),i.rXU(be,10),i.rXU(M,10),i.rXU(i.gRc,8),i.rXU(mn,8))};static \u0275dir=i.FsC({type:de,selectors:[["","ngModel","",3,"formControlName","",3,"formControl",""]],inputs:{name:"name",isDisabled:[0,"disabled","isDisabled"],model:[0,"ngModel","model"],options:[0,"ngModelOptions","options"]},outputs:{update:"ngModelChange"},exportAs:["ngModel"],standalone:!1,features:[i.Jv_([es]),i.Vt3,i.OA$]})}return de})(),Li=(()=>{class de{static \u0275fac=function(Ue){return new(Ue||de)};static \u0275dir=i.FsC({type:de,selectors:[["form",3,"ngNoForm","",3,"ngNativeValidate",""]],hostAttrs:["novalidate",""],standalone:!1})}return de})();const bi={provide:M,useExisting:(0,i.Rfq)(()=>aa),multi:!0};let aa=(()=>{class de extends S{writeValue(Y){this.setProperty("value",Y??"")}registerOnChange(Y){this.onChange=Ue=>{Y(""==Ue?null:parseFloat(Ue))}}static \u0275fac=(()=>{let Y;return function(jt){return(Y||(Y=i.xGo(de)))(jt||de)}})();static \u0275dir=i.FsC({type:de,selectors:[["input","type","number","formControlName",""],["input","type","number","formControl",""],["input","type","number","ngModel",""]],hostBindings:function(Ue,jt){1&Ue&&i.bIt("input",function(Jr){return jt.onChange(Jr.target.value)})("blur",function(){return jt.onTouched()})},standalone:!1,features:[i.Jv_([bi]),i.Vt3]})}return de})();const mo=new i.nKC(""),Go={provide:Mt,useExisting:(0,i.Rfq)(()=>Rs)};let Rs=(()=>{class de extends Mt{_ngModelWarningConfig;callSetDisabledState;viewModel;form;set isDisabled(Y){}model;update=new i.bkB;static _ngModelWarningSentOnce=!1;_ngModelWarningSent=!1;constructor(Y,Ue,jt,br,Jr){super(),this._ngModelWarningConfig=br,this.callSetDisabledState=Jr,this._setValidators(Y),this._setAsyncValidators(Ue),this.valueAccessor=Ht(0,jt)}ngOnChanges(Y){if(this._isControlChanged(Y)){const Ue=Y.form.previousValue;Ue&&ds(Ue,this,!1),Ni(this.form,this,this.callSetDisabledState),this.form.updateValueAndValidity({emitEvent:!1})}Ye(Y,this.viewModel)&&(this.form.setValue(this.model),this.viewModel=this.model)}ngOnDestroy(){this.form&&ds(this.form,this,!1)}get path(){return[]}get control(){return this.form}viewToModelUpdate(Y){this.viewModel=Y,this.update.emit(Y)}_isControlChanged(Y){return Y.hasOwnProperty("form")}static \u0275fac=function(Ue){return new(Ue||de)(i.rXU(me,10),i.rXU(be,10),i.rXU(M,10),i.rXU(mo,8),i.rXU(mn,8))};static \u0275dir=i.FsC({type:de,selectors:[["","formControl",""]],inputs:{form:[0,"formControl","form"],isDisabled:[0,"disabled","isDisabled"],model:[0,"ngModel","model"]},outputs:{update:"ngModelChange"},exportAs:["ngForm"],standalone:!1,features:[i.Jv_([Go]),i.Vt3,i.OA$]})}return de})();const Xr={provide:Xt,useExisting:(0,i.Rfq)(()=>Ds)};let Ds=(()=>{class de extends Xt{callSetDisabledState;get submitted(){return(0,i.O8t)(this._submittedReactive)}set submitted(Y){this._submittedReactive.set(Y)}_submitted=(0,i.EWP)(()=>this._submittedReactive());_submittedReactive=(0,i.vPA)(!1);_oldForm;_onCollectionChange=()=>this._updateDomValue();directives=[];form=null;ngSubmit=new i.bkB;constructor(Y,Ue,jt){super(),this.callSetDisabledState=jt,this._setValidators(Y),this._setAsyncValidators(Ue)}ngOnChanges(Y){this._checkFormPresent(),Y.hasOwnProperty("form")&&(this._updateValidators(),this._updateDomValue(),this._updateRegistrations(),this._oldForm=this.form)}ngOnDestroy(){this.form&&(fo(this.form,this),this.form._onCollectionChange===this._onCollectionChange&&this.form._registerOnCollectionChange(()=>{}))}get formDirective(){return this}get control(){return this.form}get path(){return[]}addControl(Y){const Ue=this.form.get(Y.path);return Ni(Ue,Y,this.callSetDisabledState),Ue.updateValueAndValidity({emitEvent:!1}),this.directives.push(Y),Ue}getControl(Y){return this.form.get(Y.path)}removeControl(Y){ds(Y.control||null,Y,!1),function kt(de,he){const Y=de.indexOf(he);Y>-1&&de.splice(Y,1)}(this.directives,Y)}addFormGroup(Y){this._setUpFormContainer(Y)}removeFormGroup(Y){this._cleanUpFormContainer(Y)}getFormGroup(Y){return this.form.get(Y.path)}addFormArray(Y){this._setUpFormContainer(Y)}removeFormArray(Y){this._cleanUpFormContainer(Y)}getFormArray(Y){return this.form.get(Y.path)}updateModel(Y,Ue){this.form.get(Y.path).setValue(Ue)}onSubmit(Y){return this._submittedReactive.set(!0),gt(this.form,this.directives),this.ngSubmit.emit(Y),this.form._events.next(new Ge(this.control)),"dialog"===Y?.target?.method}onReset(){this.resetForm()}resetForm(Y=void 0){this.form.reset(Y),this._submittedReactive.set(!1),this.form._events.next(new Ve(this.form))}_updateDomValue(){this.directives.forEach(Y=>{const Ue=Y.control,jt=this.form.get(Y.path);Ue!==jt&&(ds(Ue||null,Y),(de=>de instanceof ar)(jt)&&(Ni(jt,Y,this.callSetDisabledState),Y.control=jt))}),this.form._updateTreeValidity({emitEvent:!1})}_setUpFormContainer(Y){const Ue=this.form.get(Y.path);po(Ue,Y),Ue.updateValueAndValidity({emitEvent:!1})}_cleanUpFormContainer(Y){if(this.form){const Ue=this.form.get(Y.path);Ue&&function Ii(de,he){return fo(de,he)}(Ue,Y)&&Ue.updateValueAndValidity({emitEvent:!1})}}_updateRegistrations(){this.form._registerOnCollectionChange(this._onCollectionChange),this._oldForm&&this._oldForm._registerOnCollectionChange(()=>{})}_updateValidators(){qo(this.form,this),this._oldForm&&fo(this._oldForm,this)}_checkFormPresent(){}static \u0275fac=function(Ue){return new(Ue||de)(i.rXU(me,10),i.rXU(be,10),i.rXU(mn,8))};static \u0275dir=i.FsC({type:de,selectors:[["","formGroup",""]],hostBindings:function(Ue,jt){1&Ue&&i.bIt("submit",function(Jr){return jt.onSubmit(Jr)})("reset",function(){return jt.onReset()})},inputs:{form:[0,"formGroup","form"]},outputs:{ngSubmit:"ngSubmit"},exportAs:["ngForm"],standalone:!1,features:[i.Jv_([Xr]),i.Vt3,i.OA$]})}return de})();const _o={provide:Mt,useExisting:(0,i.Rfq)(()=>Ao)};let Ao=(()=>{class de extends Mt{_ngModelWarningConfig;_added=!1;viewModel;control;name=null;set isDisabled(Y){}model;update=new i.bkB;static _ngModelWarningSentOnce=!1;_ngModelWarningSent=!1;constructor(Y,Ue,jt,br,Jr){super(),this._ngModelWarningConfig=Jr,this._parent=Y,this._setValidators(Ue),this._setAsyncValidators(jt),this.valueAccessor=Ht(0,br)}ngOnChanges(Y){this._added||this._setUpControl(),Ye(Y,this.viewModel)&&(this.viewModel=this.model,this.formDirective.updateModel(this,this.model))}ngOnDestroy(){this.formDirective&&this.formDirective.removeControl(this)}viewToModelUpdate(Y){this.viewModel=Y,this.update.emit(Y)}get path(){return Co(null==this.name?this.name:this.name.toString(),this._parent)}get formDirective(){return this._parent?this._parent.formDirective:null}_checkParentType(){}_setUpControl(){this._checkParentType(),this.control=this.formDirective.addControl(this),this._added=!0}static \u0275fac=function(Ue){return new(Ue||de)(i.rXU(Xt,13),i.rXU(me,10),i.rXU(be,10),i.rXU(M,10),i.rXU(mo,8))};static \u0275dir=i.FsC({type:de,selectors:[["","formControlName",""]],inputs:{name:[0,"formControlName","name"],isDisabled:[0,"disabled","isDisabled"],model:[0,"ngModel","model"]},outputs:{update:"ngModelChange"},standalone:!1,features:[i.Jv_([_o]),i.Vt3,i.OA$]})}return de})();let Bo=(()=>{class de{_validator=lt;_onChange;_enabled;ngOnChanges(Y){if(this.inputName in Y){const Ue=this.normalizeInput(Y[this.inputName].currentValue);this._enabled=this.enabled(Ue),this._validator=this._enabled?this.createValidator(Ue):lt,this._onChange&&this._onChange()}}validate(Y){return this._validator(Y)}registerOnValidatorChange(Y){this._onChange=Y}enabled(Y){return null!=Y}static \u0275fac=function(Ue){return new(Ue||de)};static \u0275dir=i.FsC({type:de,features:[i.OA$]})}return de})();const Us={provide:me,useExisting:(0,i.Rfq)(()=>Ba),multi:!0},ua={provide:me,useExisting:(0,i.Rfq)(()=>Aa),multi:!0};let Ba=(()=>{class de extends Bo{required;inputName="required";normalizeInput=i.L39;createValidator=Y=>ue;enabled(Y){return Y}static \u0275fac=(()=>{let Y;return function(jt){return(Y||(Y=i.xGo(de)))(jt||de)}})();static \u0275dir=i.FsC({type:de,selectors:[["","required","","formControlName","",3,"type","checkbox"],["","required","","formControl","",3,"type","checkbox"],["","required","","ngModel","",3,"type","checkbox"]],hostVars:1,hostBindings:function(Ue,jt){2&Ue&&i.BMQ("required",jt._enabled?"":null)},inputs:{required:"required"},standalone:!1,features:[i.Jv_([Us]),i.Vt3]})}return de})(),Aa=(()=>{class de extends Ba{createValidator=Y=>Ce;static \u0275fac=(()=>{let Y;return function(jt){return(Y||(Y=i.xGo(de)))(jt||de)}})();static \u0275dir=i.FsC({type:de,selectors:[["input","type","checkbox","required","","formControlName",""],["input","type","checkbox","required","","formControl",""],["input","type","checkbox","required","","ngModel",""]],hostVars:1,hostBindings:function(Ue,jt){2&Ue&&i.BMQ("required",jt._enabled?"":null)},standalone:!1,features:[i.Jv_([ua]),i.Vt3]})}return de})();const Ct={provide:me,useExisting:(0,i.Rfq)(()=>Bn),multi:!0};let Bn=(()=>{class de extends Bo{maxlength;inputName="maxlength";normalizeInput=Y=>function Ns(de){return"number"==typeof de?de:parseInt(de,10)}(Y);createValidator=Y=>dt(Y);static \u0275fac=(()=>{let Y;return function(jt){return(Y||(Y=i.xGo(de)))(jt||de)}})();static \u0275dir=i.FsC({type:de,selectors:[["","maxlength","","formControlName",""],["","maxlength","","formControl",""],["","maxlength","","ngModel",""]],hostVars:1,hostBindings:function(Ue,jt){2&Ue&&i.BMQ("maxlength",jt._enabled?jt.maxlength:null)},inputs:{maxlength:"maxlength"},standalone:!1,features:[i.Jv_([Ct]),i.Vt3]})}return de})(),Mr=(()=>{class de{static \u0275fac=function(Ue){return new(Ue||de)};static \u0275mod=i.$C({type:de});static \u0275inj=i.G2t({})}return de})();class fi extends hi{constructor(he,Y,Ue){super(Dt(Y),Bt(Ue,Y)),this.controls=he,this._initObservables(),this._setUpdateStrategy(Y),this._setUpControls(),this.updateValueAndValidity({onlySelf:!0,emitEvent:!!this.asyncValidator})}controls;at(he){return this.controls[this._adjustIndex(he)]}push(he,Y={}){this.controls.push(he),this._registerControl(he),this.updateValueAndValidity({emitEvent:Y.emitEvent}),this._onCollectionChange()}insert(he,Y,Ue={}){this.controls.splice(he,0,Y),this._registerControl(Y),this.updateValueAndValidity({emitEvent:Ue.emitEvent})}removeAt(he,Y={}){let Ue=this._adjustIndex(he);Ue<0&&(Ue=0),this.controls[Ue]&&this.controls[Ue]._registerOnCollectionChange(()=>{}),this.controls.splice(Ue,1),this.updateValueAndValidity({emitEvent:Y.emitEvent})}setControl(he,Y,Ue={}){let jt=this._adjustIndex(he);jt<0&&(jt=0),this.controls[jt]&&this.controls[jt]._registerOnCollectionChange(()=>{}),this.controls.splice(jt,1),Y&&(this.controls.splice(jt,0,Y),this._registerControl(Y)),this.updateValueAndValidity({emitEvent:Ue.emitEvent}),this._onCollectionChange()}get length(){return this.controls.length}setValue(he,Y={}){si(this,0,he),he.forEach((Ue,jt)=>{Er(this,!1,jt),this.at(jt).setValue(Ue,{onlySelf:!0,emitEvent:Y.emitEvent})}),this.updateValueAndValidity(Y)}patchValue(he,Y={}){null!=he&&(he.forEach((Ue,jt)=>{this.at(jt)&&this.at(jt).patchValue(Ue,{onlySelf:!0,emitEvent:Y.emitEvent})}),this.updateValueAndValidity(Y))}reset(he=[],Y={}){this._forEachChild((Ue,jt)=>{Ue.reset(he[jt],{onlySelf:!0,emitEvent:Y.emitEvent})}),this._updatePristine(Y,this),this._updateTouched(Y,this),this.updateValueAndValidity(Y)}getRawValue(){return this.controls.map(he=>he.getRawValue())}clear(he={}){this.controls.length<1||(this._forEachChild(Y=>Y._registerOnCollectionChange(()=>{})),this.controls.splice(0),this.updateValueAndValidity({emitEvent:he.emitEvent}))}_adjustIndex(he){return he<0?he+this.length:he}_syncPendingControls(){let he=this.controls.reduce((Y,Ue)=>!!Ue._syncPendingControls()||Y,!1);return he&&this.updateValueAndValidity({onlySelf:!0}),he}_forEachChild(he){this.controls.forEach((Y,Ue)=>{he(Y,Ue)})}_updateValue(){this.value=this.controls.filter(he=>he.enabled||this.disabled).map(he=>he.value)}_anyControls(he){return this.controls.some(Y=>Y.enabled&&he(Y))}_setUpControls(){this._forEachChild(he=>this._registerControl(he))}_allControlsDisabled(){for(const he of this.controls)if(he.enabled)return!1;return this.controls.length>0||this.disabled}_registerControl(he){he.setParent(this),he._registerOnCollectionChange(this._onCollectionChange)}_find(he){return this.at(he)??null}}function Fi(de){return!!de&&(void 0!==de.asyncValidators||void 0!==de.validators||void 0!==de.updateOn)}let Ro=(()=>{class de{useNonNullable=!1;get nonNullable(){const Y=new de;return Y.useNonNullable=!0,Y}group(Y,Ue=null){const jt=this._reduceControls(Y);let br={};return Fi(Ue)?br=Ue:null!==Ue&&(br.validators=Ue.validator,br.asyncValidators=Ue.asyncValidator),new Zi(jt,br)}record(Y,Ue=null){const jt=this._reduceControls(Y);return new Rt(jt,Ue)}control(Y,Ue,jt){let br={};return this.useNonNullable?(Fi(Ue)?br=Ue:(br.validators=Ue,br.asyncValidators=jt),new ar(Y,{...br,nonNullable:!0})):new ar(Y,Ue,jt)}array(Y,Ue,jt){const br=Y.map(Jr=>this._createControl(Jr));return new fi(br,Ue,jt)}_reduceControls(Y){const Ue={};return Object.keys(Y).forEach(jt=>{Ue[jt]=this._createControl(Y[jt])}),Ue}_createControl(Y){return Y instanceof ar||Y instanceof hi?Y:Array.isArray(Y)?this.control(Y[0],Y.length>1?Y[1]:null,Y.length>2?Y[2]:null):this.control(Y)}static \u0275fac=function(Ue){return new(Ue||de)};static \u0275prov=i.jDH({token:de,factory:de.\u0275fac,providedIn:"root"})}return de})(),Ho=(()=>{class de extends Ro{group(Y,Ue=null){return super.group(Y,Ue)}control(Y,Ue,jt){return super.control(Y,Ue,jt)}array(Y,Ue,jt){return super.array(Y,Ue,jt)}static \u0275fac=(()=>{let Y;return function(jt){return(Y||(Y=i.xGo(de)))(jt||de)}})();static \u0275prov=i.jDH({token:de,factory:de.\u0275fac,providedIn:"root"})}return de})(),$a=(()=>{class de{static withConfig(Y){return{ngModule:de,providers:[{provide:mn,useValue:Y.callSetDisabledState??dr}]}}static \u0275fac=function(Ue){return new(Ue||de)};static \u0275mod=i.$C({type:de});static \u0275inj=i.G2t({imports:[Mr]})}return de})(),da=(()=>{class de{static withConfig(Y){return{ngModule:de,providers:[{provide:mo,useValue:Y.warnOnNgModelWithFormControl??"always"},{provide:mn,useValue:Y.callSetDisabledState??dr}]}}static \u0275fac=function(Ue){return new(Ue||de)};static \u0275mod=i.$C({type:de});static \u0275inj=i.G2t({imports:[Mr]})}return de})()},9471:(o,s,r)=>{"use strict";r.d(s,{$z:()=>ce,Hl:()=>Vn,iY:()=>gn,pQ:()=>bn});var i=r(3107),a=r(8559),c=r(2147),y=r(2902),w=r(5467);const C=["mat-button",""],T=[[["",8,"material-icons",3,"iconPositionEnd",""],["mat-icon",3,"iconPositionEnd",""],["","matButtonIcon","",3,"iconPositionEnd",""]],"*",[["","iconPositionEnd","",8,"material-icons"],["mat-icon","iconPositionEnd",""],["","matButtonIcon","","iconPositionEnd",""]]],S=[".material-icons:not([iconPositionEnd]), mat-icon:not([iconPositionEnd]), [matButtonIcon]:not([iconPositionEnd])","*",".material-icons[iconPositionEnd], mat-icon[iconPositionEnd], [matButtonIcon][iconPositionEnd]"],O="@media(forced-colors: active){.mat-mdc-button:not(.mdc-button--outlined),.mat-mdc-unelevated-button:not(.mdc-button--outlined),.mat-mdc-raised-button:not(.mdc-button--outlined),.mat-mdc-outlined-button:not(.mdc-button--outlined),.mat-mdc-icon-button.mat-mdc-icon-button{outline:solid 1px}}",re=["mat-icon-button",""],pe=["*"],ae=new i.nKC("MAT_BUTTON_CONFIG"),be=[{attribute:"mat-button",mdcClasses:["mdc-button","mat-mdc-button"]},{attribute:"mat-flat-button",mdcClasses:["mdc-button","mdc-button--unelevated","mat-mdc-unelevated-button"]},{attribute:"mat-raised-button",mdcClasses:["mdc-button","mdc-button--raised","mat-mdc-raised-button"]},{attribute:"mat-stroked-button",mdcClasses:["mdc-button","mdc-button--outlined","mat-mdc-outlined-button"]},{attribute:"mat-fab",mdcClasses:["mdc-fab","mat-mdc-fab-base","mat-mdc-fab"]},{attribute:"mat-mini-fab",mdcClasses:["mdc-fab","mat-mdc-fab-base","mdc-fab--mini","mat-mdc-mini-fab"]},{attribute:"mat-icon-button",mdcClasses:["mdc-icon-button","mat-mdc-icon-button"]}];let Oe=(()=>{class yn{_elementRef=(0,i.WQX)(i.aKT);_platform=(0,i.WQX)(c.OD);_ngZone=(0,i.WQX)(i.SKi);_animationMode=(0,i.WQX)(i.bc$,{optional:!0});_focusMonitor=(0,i.WQX)(a.FN);_rippleLoader=(0,i.WQX)(y.Ej);_isFab=!1;color;get disableRipple(){return this._disableRipple}set disableRipple(_t){this._disableRipple=_t,this._updateRippleDisabled()}_disableRipple=!1;get disabled(){return this._disabled}set disabled(_t){this._disabled=_t,this._updateRippleDisabled()}_disabled=!1;ariaDisabled;disabledInteractive;constructor(){(0,i.WQX)(w.l).load(y.Ah);const _t=(0,i.WQX)(ae,{optional:!0}),ze=this._elementRef.nativeElement,$e=ze.classList;this.disabledInteractive=_t?.disabledInteractive??!1,this.color=_t?.color??null,this._rippleLoader?.configureRipple(ze,{className:"mat-mdc-button-ripple"});for(const{attribute:Ft,mdcClasses:Ke}of be)ze.hasAttribute(Ft)&&$e.add(...Ke)}ngAfterViewInit(){this._focusMonitor.monitor(this._elementRef,!0)}ngOnDestroy(){this._focusMonitor.stopMonitoring(this._elementRef),this._rippleLoader?.destroyRipple(this._elementRef.nativeElement)}focus(_t="program",ze){_t?this._focusMonitor.focusVia(this._elementRef.nativeElement,_t,ze):this._elementRef.nativeElement.focus(ze)}_getAriaDisabled(){return null!=this.ariaDisabled?this.ariaDisabled:!(!this.disabled||!this.disabledInteractive)||null}_getDisabledAttribute(){return!(this.disabledInteractive||!this.disabled)||null}_updateRippleDisabled(){this._rippleLoader?.setDisabled(this._elementRef.nativeElement,this.disableRipple||this.disabled)}static \u0275fac=function(ze){return new(ze||yn)};static \u0275dir=i.FsC({type:yn,inputs:{color:"color",disableRipple:[2,"disableRipple","disableRipple",i.L39],disabled:[2,"disabled","disabled",i.L39],ariaDisabled:[2,"aria-disabled","ariaDisabled",i.L39],disabledInteractive:[2,"disabledInteractive","disabledInteractive",i.L39]},features:[i.GFd]})}return yn})(),De=(()=>{class yn extends Oe{tabIndex;ngOnInit(){this._ngZone.runOutsideAngular(()=>{this._elementRef.nativeElement.addEventListener("click",this._haltDisabledEvents)})}ngOnDestroy(){super.ngOnDestroy(),this._elementRef.nativeElement.removeEventListener("click",this._haltDisabledEvents)}_haltDisabledEvents=_t=>{this.disabled&&(_t.preventDefault(),_t.stopImmediatePropagation())};_getAriaDisabled(){return null!=this.ariaDisabled?this.ariaDisabled:this.disabled||null}static \u0275fac=(()=>{let _t;return function($e){return(_t||(_t=i.xGo(yn)))($e||yn)}})();static \u0275dir=i.FsC({type:yn,inputs:{tabIndex:[2,"tabIndex","tabIndex",_t=>null==_t?void 0:(0,i.Udg)(_t)]},features:[i.GFd,i.Vt3]})}return yn})(),ce=(()=>{class yn extends Oe{static \u0275fac=(()=>{let _t;return function($e){return(_t||(_t=i.xGo(yn)))($e||yn)}})();static \u0275cmp=i.VBU({type:yn,selectors:[["button","mat-button",""],["button","mat-raised-button",""],["button","mat-flat-button",""],["button","mat-stroked-button",""]],hostVars:14,hostBindings:function(ze,$e){2&ze&&(i.BMQ("disabled",$e._getDisabledAttribute())("aria-disabled",$e._getAriaDisabled()),i.HbH($e.color?"mat-"+$e.color:""),i.AVh("mat-mdc-button-disabled",$e.disabled)("mat-mdc-button-disabled-interactive",$e.disabledInteractive)("_mat-animation-noopable","NoopAnimations"===$e._animationMode)("mat-unthemed",!$e.color)("mat-mdc-button-base",!0))},exportAs:["matButton"],features:[i.Vt3],attrs:C,ngContentSelectors:S,decls:7,vars:4,consts:[[1,"mat-mdc-button-persistent-ripple"],[1,"mdc-button__label"],[1,"mat-focus-indicator"],[1,"mat-mdc-button-touch-target"]],template:function(ze,$e){1&ze&&(i.NAR(T),i.nrm(0,"span",0),i.SdG(1),i.j41(2,"span",1),i.SdG(3,1),i.k0s(),i.SdG(4,2),i.nrm(5,"span",2)(6,"span",3)),2&ze&&i.AVh("mdc-button__ripple",!$e._isFab)("mdc-fab__ripple",$e._isFab)},styles:['.mat-mdc-button-base{text-decoration:none}.mdc-button{-webkit-user-select:none;user-select:none;position:relative;display:inline-flex;align-items:center;justify-content:center;box-sizing:border-box;min-width:64px;border:none;outline:none;line-height:inherit;-webkit-appearance:none;overflow:visible;vertical-align:middle;background:rgba(0,0,0,0);padding:0 8px}.mdc-button::-moz-focus-inner{padding:0;border:0}.mdc-button:active{outline:none}.mdc-button:hover{cursor:pointer}.mdc-button:disabled{cursor:default;pointer-events:none}.mdc-button[hidden]{display:none}.mdc-button .mdc-button__label{position:relative}.mat-mdc-button{padding:0 var(--mat-text-button-horizontal-padding, 12px);height:var(--mdc-text-button-container-height, 40px);font-family:var(--mdc-text-button-label-text-font, var(--mat-sys-label-large-font));font-size:var(--mdc-text-button-label-text-size, var(--mat-sys-label-large-size));letter-spacing:var(--mdc-text-button-label-text-tracking, var(--mat-sys-label-large-tracking));text-transform:var(--mdc-text-button-label-text-transform);font-weight:var(--mdc-text-button-label-text-weight, var(--mat-sys-label-large-weight))}.mat-mdc-button,.mat-mdc-button .mdc-button__ripple{border-radius:var(--mdc-text-button-container-shape, var(--mat-sys-corner-full))}.mat-mdc-button:not(:disabled){color:var(--mdc-text-button-label-text-color, var(--mat-sys-primary))}.mat-mdc-button[disabled],.mat-mdc-button.mat-mdc-button-disabled{cursor:default;pointer-events:none;color:var(--mdc-text-button-disabled-label-text-color, color-mix(in srgb, var(--mat-sys-on-surface) 38%, transparent))}.mat-mdc-button.mat-mdc-button-disabled-interactive{pointer-events:auto}.mat-mdc-button:has(.material-icons,mat-icon,[matButtonIcon]){padding:0 var(--mat-text-button-with-icon-horizontal-padding, 16px)}.mat-mdc-button>.mat-icon{margin-right:var(--mat-text-button-icon-spacing, 8px);margin-left:var(--mat-text-button-icon-offset, -4px)}[dir=rtl] .mat-mdc-button>.mat-icon{margin-right:var(--mat-text-button-icon-offset, -4px);margin-left:var(--mat-text-button-icon-spacing, 8px)}.mat-mdc-button .mdc-button__label+.mat-icon{margin-right:var(--mat-text-button-icon-offset, -4px);margin-left:var(--mat-text-button-icon-spacing, 8px)}[dir=rtl] .mat-mdc-button .mdc-button__label+.mat-icon{margin-right:var(--mat-text-button-icon-spacing, 8px);margin-left:var(--mat-text-button-icon-offset, -4px)}.mat-mdc-button .mat-ripple-element{background-color:var(--mat-text-button-ripple-color, color-mix(in srgb, var(--mat-sys-primary) calc(var(--mat-sys-pressed-state-layer-opacity) * 100%), transparent))}.mat-mdc-button .mat-mdc-button-persistent-ripple::before{background-color:var(--mat-text-button-state-layer-color, var(--mat-sys-primary))}.mat-mdc-button.mat-mdc-button-disabled .mat-mdc-button-persistent-ripple::before{background-color:var(--mat-text-button-disabled-state-layer-color, var(--mat-sys-on-surface-variant))}.mat-mdc-button:hover .mat-mdc-button-persistent-ripple::before{opacity:var(--mat-text-button-hover-state-layer-opacity, var(--mat-sys-hover-state-layer-opacity))}.mat-mdc-button.cdk-program-focused .mat-mdc-button-persistent-ripple::before,.mat-mdc-button.cdk-keyboard-focused .mat-mdc-button-persistent-ripple::before,.mat-mdc-button.mat-mdc-button-disabled-interactive:focus .mat-mdc-button-persistent-ripple::before{opacity:var(--mat-text-button-focus-state-layer-opacity, var(--mat-sys-focus-state-layer-opacity))}.mat-mdc-button:active .mat-mdc-button-persistent-ripple::before{opacity:var(--mat-text-button-pressed-state-layer-opacity, var(--mat-sys-pressed-state-layer-opacity))}.mat-mdc-button .mat-mdc-button-touch-target{position:absolute;top:50%;height:48px;left:0;right:0;transform:translateY(-50%);display:var(--mat-text-button-touch-target-display, block)}.mat-mdc-unelevated-button{transition:box-shadow 280ms cubic-bezier(0.4, 0, 0.2, 1);height:var(--mdc-filled-button-container-height, 40px);font-family:var(--mdc-filled-button-label-text-font, var(--mat-sys-label-large-font));font-size:var(--mdc-filled-button-label-text-size, var(--mat-sys-label-large-size));letter-spacing:var(--mdc-filled-button-label-text-tracking, var(--mat-sys-label-large-tracking));text-transform:var(--mdc-filled-button-label-text-transform);font-weight:var(--mdc-filled-button-label-text-weight, var(--mat-sys-label-large-weight));padding:0 var(--mat-filled-button-horizontal-padding, 24px)}.mat-mdc-unelevated-button>.mat-icon{margin-right:var(--mat-filled-button-icon-spacing, 8px);margin-left:var(--mat-filled-button-icon-offset, -8px)}[dir=rtl] .mat-mdc-unelevated-button>.mat-icon{margin-right:var(--mat-filled-button-icon-offset, -8px);margin-left:var(--mat-filled-button-icon-spacing, 8px)}.mat-mdc-unelevated-button .mdc-button__label+.mat-icon{margin-right:var(--mat-filled-button-icon-offset, -8px);margin-left:var(--mat-filled-button-icon-spacing, 8px)}[dir=rtl] .mat-mdc-unelevated-button .mdc-button__label+.mat-icon{margin-right:var(--mat-filled-button-icon-spacing, 8px);margin-left:var(--mat-filled-button-icon-offset, -8px)}.mat-mdc-unelevated-button .mat-ripple-element{background-color:var(--mat-filled-button-ripple-color, color-mix(in srgb, var(--mat-sys-on-primary) calc(var(--mat-sys-pressed-state-layer-opacity) * 100%), transparent))}.mat-mdc-unelevated-button .mat-mdc-button-persistent-ripple::before{background-color:var(--mat-filled-button-state-layer-color, var(--mat-sys-on-primary))}.mat-mdc-unelevated-button.mat-mdc-button-disabled .mat-mdc-button-persistent-ripple::before{background-color:var(--mat-filled-button-disabled-state-layer-color, var(--mat-sys-on-surface-variant))}.mat-mdc-unelevated-button:hover .mat-mdc-button-persistent-ripple::before{opacity:var(--mat-filled-button-hover-state-layer-opacity, var(--mat-sys-hover-state-layer-opacity))}.mat-mdc-unelevated-button.cdk-program-focused .mat-mdc-button-persistent-ripple::before,.mat-mdc-unelevated-button.cdk-keyboard-focused .mat-mdc-button-persistent-ripple::before,.mat-mdc-unelevated-button.mat-mdc-button-disabled-interactive:focus .mat-mdc-button-persistent-ripple::before{opacity:var(--mat-filled-button-focus-state-layer-opacity, var(--mat-sys-focus-state-layer-opacity))}.mat-mdc-unelevated-button:active .mat-mdc-button-persistent-ripple::before{opacity:var(--mat-filled-button-pressed-state-layer-opacity, var(--mat-sys-pressed-state-layer-opacity))}.mat-mdc-unelevated-button .mat-mdc-button-touch-target{position:absolute;top:50%;height:48px;left:0;right:0;transform:translateY(-50%);display:var(--mat-filled-button-touch-target-display, block)}.mat-mdc-unelevated-button:not(:disabled){color:var(--mdc-filled-button-label-text-color, var(--mat-sys-on-primary));background-color:var(--mdc-filled-button-container-color, var(--mat-sys-primary))}.mat-mdc-unelevated-button,.mat-mdc-unelevated-button .mdc-button__ripple{border-radius:var(--mdc-filled-button-container-shape, var(--mat-sys-corner-full))}.mat-mdc-unelevated-button[disabled],.mat-mdc-unelevated-button.mat-mdc-button-disabled{cursor:default;pointer-events:none;color:var(--mdc-filled-button-disabled-label-text-color, color-mix(in srgb, var(--mat-sys-on-surface) 38%, transparent));background-color:var(--mdc-filled-button-disabled-container-color, color-mix(in srgb, var(--mat-sys-on-surface) 12%, transparent))}.mat-mdc-unelevated-button.mat-mdc-button-disabled-interactive{pointer-events:auto}.mat-mdc-raised-button{transition:box-shadow 280ms cubic-bezier(0.4, 0, 0.2, 1);box-shadow:var(--mdc-protected-button-container-elevation-shadow, var(--mat-sys-level1));height:var(--mdc-protected-button-container-height, 40px);font-family:var(--mdc-protected-button-label-text-font, var(--mat-sys-label-large-font));font-size:var(--mdc-protected-button-label-text-size, var(--mat-sys-label-large-size));letter-spacing:var(--mdc-protected-button-label-text-tracking, var(--mat-sys-label-large-tracking));text-transform:var(--mdc-protected-button-label-text-transform);font-weight:var(--mdc-protected-button-label-text-weight, var(--mat-sys-label-large-weight));padding:0 var(--mat-protected-button-horizontal-padding, 24px)}.mat-mdc-raised-button>.mat-icon{margin-right:var(--mat-protected-button-icon-spacing, 8px);margin-left:var(--mat-protected-button-icon-offset, -8px)}[dir=rtl] .mat-mdc-raised-button>.mat-icon{margin-right:var(--mat-protected-button-icon-offset, -8px);margin-left:var(--mat-protected-button-icon-spacing, 8px)}.mat-mdc-raised-button .mdc-button__label+.mat-icon{margin-right:var(--mat-protected-button-icon-offset, -8px);margin-left:var(--mat-protected-button-icon-spacing, 8px)}[dir=rtl] .mat-mdc-raised-button .mdc-button__label+.mat-icon{margin-right:var(--mat-protected-button-icon-spacing, 8px);margin-left:var(--mat-protected-button-icon-offset, -8px)}.mat-mdc-raised-button .mat-ripple-element{background-color:var(--mat-protected-button-ripple-color, color-mix(in srgb, var(--mat-sys-primary) calc(var(--mat-sys-pressed-state-layer-opacity) * 100%), transparent))}.mat-mdc-raised-button .mat-mdc-button-persistent-ripple::before{background-color:var(--mat-protected-button-state-layer-color, var(--mat-sys-primary))}.mat-mdc-raised-button.mat-mdc-button-disabled .mat-mdc-button-persistent-ripple::before{background-color:var(--mat-protected-button-disabled-state-layer-color, var(--mat-sys-on-surface-variant))}.mat-mdc-raised-button:hover .mat-mdc-button-persistent-ripple::before{opacity:var(--mat-protected-button-hover-state-layer-opacity, var(--mat-sys-hover-state-layer-opacity))}.mat-mdc-raised-button.cdk-program-focused .mat-mdc-button-persistent-ripple::before,.mat-mdc-raised-button.cdk-keyboard-focused .mat-mdc-button-persistent-ripple::before,.mat-mdc-raised-button.mat-mdc-button-disabled-interactive:focus .mat-mdc-button-persistent-ripple::before{opacity:var(--mat-protected-button-focus-state-layer-opacity, var(--mat-sys-focus-state-layer-opacity))}.mat-mdc-raised-button:active .mat-mdc-button-persistent-ripple::before{opacity:var(--mat-protected-button-pressed-state-layer-opacity, var(--mat-sys-pressed-state-layer-opacity))}.mat-mdc-raised-button .mat-mdc-button-touch-target{position:absolute;top:50%;height:48px;left:0;right:0;transform:translateY(-50%);display:var(--mat-protected-button-touch-target-display, block)}.mat-mdc-raised-button:not(:disabled){color:var(--mdc-protected-button-label-text-color, var(--mat-sys-primary));background-color:var(--mdc-protected-button-container-color, var(--mat-sys-surface))}.mat-mdc-raised-button,.mat-mdc-raised-button .mdc-button__ripple{border-radius:var(--mdc-protected-button-container-shape, var(--mat-sys-corner-full))}.mat-mdc-raised-button:hover{box-shadow:var(--mdc-protected-button-hover-container-elevation-shadow, var(--mat-sys-level2))}.mat-mdc-raised-button:focus{box-shadow:var(--mdc-protected-button-focus-container-elevation-shadow, var(--mat-sys-level1))}.mat-mdc-raised-button:active,.mat-mdc-raised-button:focus:active{box-shadow:var(--mdc-protected-button-pressed-container-elevation-shadow, var(--mat-sys-level1))}.mat-mdc-raised-button[disabled],.mat-mdc-raised-button.mat-mdc-button-disabled{cursor:default;pointer-events:none;color:var(--mdc-protected-button-disabled-label-text-color, color-mix(in srgb, var(--mat-sys-on-surface) 38%, transparent));background-color:var(--mdc-protected-button-disabled-container-color, color-mix(in srgb, var(--mat-sys-on-surface) 12%, transparent))}.mat-mdc-raised-button[disabled].mat-mdc-button-disabled,.mat-mdc-raised-button.mat-mdc-button-disabled.mat-mdc-button-disabled{box-shadow:var(--mdc-protected-button-disabled-container-elevation-shadow, var(--mat-sys-level0))}.mat-mdc-raised-button.mat-mdc-button-disabled-interactive{pointer-events:auto}.mat-mdc-outlined-button{border-style:solid;transition:border 280ms cubic-bezier(0.4, 0, 0.2, 1);height:var(--mdc-outlined-button-container-height, 40px);font-family:var(--mdc-outlined-button-label-text-font, var(--mat-sys-label-large-font));font-size:var(--mdc-outlined-button-label-text-size, var(--mat-sys-label-large-size));letter-spacing:var(--mdc-outlined-button-label-text-tracking, var(--mat-sys-label-large-tracking));text-transform:var(--mdc-outlined-button-label-text-transform);font-weight:var(--mdc-outlined-button-label-text-weight, var(--mat-sys-label-large-weight));border-radius:var(--mdc-outlined-button-container-shape, var(--mat-sys-corner-full));border-width:var(--mdc-outlined-button-outline-width, 1px);padding:0 var(--mat-outlined-button-horizontal-padding, 24px)}.mat-mdc-outlined-button>.mat-icon{margin-right:var(--mat-outlined-button-icon-spacing, 8px);margin-left:var(--mat-outlined-button-icon-offset, -8px)}[dir=rtl] .mat-mdc-outlined-button>.mat-icon{margin-right:var(--mat-outlined-button-icon-offset, -8px);margin-left:var(--mat-outlined-button-icon-spacing, 8px)}.mat-mdc-outlined-button .mdc-button__label+.mat-icon{margin-right:var(--mat-outlined-button-icon-offset, -8px);margin-left:var(--mat-outlined-button-icon-spacing, 8px)}[dir=rtl] .mat-mdc-outlined-button .mdc-button__label+.mat-icon{margin-right:var(--mat-outlined-button-icon-spacing, 8px);margin-left:var(--mat-outlined-button-icon-offset, -8px)}.mat-mdc-outlined-button .mat-ripple-element{background-color:var(--mat-outlined-button-ripple-color, color-mix(in srgb, var(--mat-sys-primary) calc(var(--mat-sys-pressed-state-layer-opacity) * 100%), transparent))}.mat-mdc-outlined-button .mat-mdc-button-persistent-ripple::before{background-color:var(--mat-outlined-button-state-layer-color, var(--mat-sys-primary))}.mat-mdc-outlined-button.mat-mdc-button-disabled .mat-mdc-button-persistent-ripple::before{background-color:var(--mat-outlined-button-disabled-state-layer-color, var(--mat-sys-on-surface-variant))}.mat-mdc-outlined-button:hover .mat-mdc-button-persistent-ripple::before{opacity:var(--mat-outlined-button-hover-state-layer-opacity, var(--mat-sys-hover-state-layer-opacity))}.mat-mdc-outlined-button.cdk-program-focused .mat-mdc-button-persistent-ripple::before,.mat-mdc-outlined-button.cdk-keyboard-focused .mat-mdc-button-persistent-ripple::before,.mat-mdc-outlined-button.mat-mdc-button-disabled-interactive:focus .mat-mdc-button-persistent-ripple::before{opacity:var(--mat-outlined-button-focus-state-layer-opacity, var(--mat-sys-focus-state-layer-opacity))}.mat-mdc-outlined-button:active .mat-mdc-button-persistent-ripple::before{opacity:var(--mat-outlined-button-pressed-state-layer-opacity, var(--mat-sys-pressed-state-layer-opacity))}.mat-mdc-outlined-button .mat-mdc-button-touch-target{position:absolute;top:50%;height:48px;left:0;right:0;transform:translateY(-50%);display:var(--mat-outlined-button-touch-target-display, block)}.mat-mdc-outlined-button:not(:disabled){color:var(--mdc-outlined-button-label-text-color, var(--mat-sys-primary));border-color:var(--mdc-outlined-button-outline-color, var(--mat-sys-outline))}.mat-mdc-outlined-button[disabled],.mat-mdc-outlined-button.mat-mdc-button-disabled{cursor:default;pointer-events:none;color:var(--mdc-outlined-button-disabled-label-text-color, color-mix(in srgb, var(--mat-sys-on-surface) 38%, transparent));border-color:var(--mdc-outlined-button-disabled-outline-color, color-mix(in srgb, var(--mat-sys-on-surface) 12%, transparent))}.mat-mdc-outlined-button.mat-mdc-button-disabled-interactive{pointer-events:auto}.mat-mdc-outlined-button .mdc-button__ripple{border-width:var(--mdc-outlined-button-outline-width, 1px);border-style:solid;border-color:rgba(0,0,0,0)}.mat-mdc-button,.mat-mdc-unelevated-button,.mat-mdc-raised-button,.mat-mdc-outlined-button{-webkit-tap-highlight-color:rgba(0,0,0,0)}.mat-mdc-button .mat-mdc-button-ripple,.mat-mdc-button .mat-mdc-button-persistent-ripple,.mat-mdc-button .mat-mdc-button-persistent-ripple::before,.mat-mdc-unelevated-button .mat-mdc-button-ripple,.mat-mdc-unelevated-button .mat-mdc-button-persistent-ripple,.mat-mdc-unelevated-button .mat-mdc-button-persistent-ripple::before,.mat-mdc-raised-button .mat-mdc-button-ripple,.mat-mdc-raised-button .mat-mdc-button-persistent-ripple,.mat-mdc-raised-button .mat-mdc-button-persistent-ripple::before,.mat-mdc-outlined-button .mat-mdc-button-ripple,.mat-mdc-outlined-button .mat-mdc-button-persistent-ripple,.mat-mdc-outlined-button .mat-mdc-button-persistent-ripple::before{top:0;left:0;right:0;bottom:0;position:absolute;pointer-events:none;border-radius:inherit}.mat-mdc-button .mat-mdc-button-ripple,.mat-mdc-unelevated-button .mat-mdc-button-ripple,.mat-mdc-raised-button .mat-mdc-button-ripple,.mat-mdc-outlined-button .mat-mdc-button-ripple{overflow:hidden}.mat-mdc-button .mat-mdc-button-persistent-ripple::before,.mat-mdc-unelevated-button .mat-mdc-button-persistent-ripple::before,.mat-mdc-raised-button .mat-mdc-button-persistent-ripple::before,.mat-mdc-outlined-button .mat-mdc-button-persistent-ripple::before{content:"";opacity:0}.mat-mdc-button .mdc-button__label,.mat-mdc-button .mat-icon,.mat-mdc-unelevated-button .mdc-button__label,.mat-mdc-unelevated-button .mat-icon,.mat-mdc-raised-button .mdc-button__label,.mat-mdc-raised-button .mat-icon,.mat-mdc-outlined-button .mdc-button__label,.mat-mdc-outlined-button .mat-icon{z-index:1;position:relative}.mat-mdc-button .mat-focus-indicator,.mat-mdc-unelevated-button .mat-focus-indicator,.mat-mdc-raised-button .mat-focus-indicator,.mat-mdc-outlined-button .mat-focus-indicator{top:0;left:0;right:0;bottom:0;position:absolute}.mat-mdc-button:focus .mat-focus-indicator::before,.mat-mdc-unelevated-button:focus .mat-focus-indicator::before,.mat-mdc-raised-button:focus .mat-focus-indicator::before,.mat-mdc-outlined-button:focus .mat-focus-indicator::before{content:""}.mat-mdc-button._mat-animation-noopable,.mat-mdc-unelevated-button._mat-animation-noopable,.mat-mdc-raised-button._mat-animation-noopable,.mat-mdc-outlined-button._mat-animation-noopable{transition:none !important;animation:none !important}.mat-mdc-button>.mat-icon,.mat-mdc-unelevated-button>.mat-icon,.mat-mdc-raised-button>.mat-icon,.mat-mdc-outlined-button>.mat-icon{display:inline-block;position:relative;vertical-align:top;font-size:1.125rem;height:1.125rem;width:1.125rem}.mat-mdc-outlined-button .mat-mdc-button-ripple,.mat-mdc-outlined-button .mdc-button__ripple{top:-1px;left:-1px;bottom:-1px;right:-1px}.mat-mdc-unelevated-button .mat-focus-indicator::before,.mat-mdc-raised-button .mat-focus-indicator::before{margin:calc(calc(var(--mat-focus-indicator-border-width, 3px) + 2px)*-1)}.mat-mdc-outlined-button .mat-focus-indicator::before{margin:calc(calc(var(--mat-focus-indicator-border-width, 3px) + 3px)*-1)}',"@media(forced-colors: active){.mat-mdc-button:not(.mdc-button--outlined),.mat-mdc-unelevated-button:not(.mdc-button--outlined),.mat-mdc-raised-button:not(.mdc-button--outlined),.mat-mdc-outlined-button:not(.mdc-button--outlined),.mat-mdc-icon-button.mat-mdc-icon-button{outline:solid 1px}}"],encapsulation:2,changeDetection:0})}return yn})(),gn=(()=>{class yn extends Oe{constructor(){super(),this._rippleLoader.configureRipple(this._elementRef.nativeElement,{centered:!0})}static \u0275fac=function(ze){return new(ze||yn)};static \u0275cmp=i.VBU({type:yn,selectors:[["button","mat-icon-button",""]],hostVars:14,hostBindings:function(ze,$e){2&ze&&(i.BMQ("disabled",$e._getDisabledAttribute())("aria-disabled",$e._getAriaDisabled()),i.HbH($e.color?"mat-"+$e.color:""),i.AVh("mat-mdc-button-disabled",$e.disabled)("mat-mdc-button-disabled-interactive",$e.disabledInteractive)("_mat-animation-noopable","NoopAnimations"===$e._animationMode)("mat-unthemed",!$e.color)("mat-mdc-button-base",!0))},exportAs:["matButton"],features:[i.Vt3],attrs:re,ngContentSelectors:pe,decls:4,vars:0,consts:[[1,"mat-mdc-button-persistent-ripple","mdc-icon-button__ripple"],[1,"mat-focus-indicator"],[1,"mat-mdc-button-touch-target"]],template:function(ze,$e){1&ze&&(i.NAR(),i.nrm(0,"span",0),i.SdG(1),i.nrm(2,"span",1)(3,"span",2))},styles:['.mat-mdc-icon-button{-webkit-user-select:none;user-select:none;display:inline-block;position:relative;box-sizing:border-box;border:none;outline:none;background-color:rgba(0,0,0,0);fill:currentColor;color:inherit;text-decoration:none;cursor:pointer;z-index:0;overflow:visible;border-radius:50%;flex-shrink:0;text-align:center;width:var(--mdc-icon-button-state-layer-size, 40px);height:var(--mdc-icon-button-state-layer-size, 40px);padding:calc(calc(var(--mdc-icon-button-state-layer-size, 40px) - var(--mdc-icon-button-icon-size, 24px)) / 2);font-size:var(--mdc-icon-button-icon-size, 24px);color:var(--mdc-icon-button-icon-color, var(--mat-sys-on-surface-variant));-webkit-tap-highlight-color:rgba(0,0,0,0)}.mat-mdc-icon-button .mat-mdc-button-ripple,.mat-mdc-icon-button .mat-mdc-button-persistent-ripple,.mat-mdc-icon-button .mat-mdc-button-persistent-ripple::before{top:0;left:0;right:0;bottom:0;position:absolute;pointer-events:none;border-radius:inherit}.mat-mdc-icon-button .mat-mdc-button-ripple{overflow:hidden}.mat-mdc-icon-button .mat-mdc-button-persistent-ripple::before{content:"";opacity:0}.mat-mdc-icon-button .mdc-button__label,.mat-mdc-icon-button .mat-icon{z-index:1;position:relative}.mat-mdc-icon-button .mat-focus-indicator{top:0;left:0;right:0;bottom:0;position:absolute}.mat-mdc-icon-button:focus .mat-focus-indicator::before{content:""}.mat-mdc-icon-button .mat-ripple-element{background-color:var(--mat-icon-button-ripple-color, color-mix(in srgb, var(--mat-sys-on-surface-variant) calc(var(--mat-sys-pressed-state-layer-opacity) * 100%), transparent))}.mat-mdc-icon-button .mat-mdc-button-persistent-ripple::before{background-color:var(--mat-icon-button-state-layer-color, var(--mat-sys-on-surface-variant))}.mat-mdc-icon-button.mat-mdc-button-disabled .mat-mdc-button-persistent-ripple::before{background-color:var(--mat-icon-button-disabled-state-layer-color, var(--mat-sys-on-surface-variant))}.mat-mdc-icon-button:hover .mat-mdc-button-persistent-ripple::before{opacity:var(--mat-icon-button-hover-state-layer-opacity, var(--mat-sys-hover-state-layer-opacity))}.mat-mdc-icon-button.cdk-program-focused .mat-mdc-button-persistent-ripple::before,.mat-mdc-icon-button.cdk-keyboard-focused .mat-mdc-button-persistent-ripple::before,.mat-mdc-icon-button.mat-mdc-button-disabled-interactive:focus .mat-mdc-button-persistent-ripple::before{opacity:var(--mat-icon-button-focus-state-layer-opacity, var(--mat-sys-focus-state-layer-opacity))}.mat-mdc-icon-button:active .mat-mdc-button-persistent-ripple::before{opacity:var(--mat-icon-button-pressed-state-layer-opacity, var(--mat-sys-pressed-state-layer-opacity))}.mat-mdc-icon-button .mat-mdc-button-touch-target{position:absolute;top:50%;height:48px;left:50%;width:48px;transform:translate(-50%, -50%);display:var(--mat-icon-button-touch-target-display, block)}.mat-mdc-icon-button._mat-animation-noopable{transition:none !important;animation:none !important}.mat-mdc-icon-button[disabled],.mat-mdc-icon-button.mat-mdc-button-disabled{cursor:default;pointer-events:none;color:var(--mdc-icon-button-disabled-icon-color, color-mix(in srgb, var(--mat-sys-on-surface) 38%, transparent))}.mat-mdc-icon-button.mat-mdc-button-disabled-interactive{pointer-events:auto}.mat-mdc-icon-button img,.mat-mdc-icon-button svg{width:var(--mdc-icon-button-icon-size, 24px);height:var(--mdc-icon-button-icon-size, 24px);vertical-align:baseline}.mat-mdc-icon-button .mat-mdc-button-persistent-ripple{border-radius:50%}.mat-mdc-icon-button[hidden]{display:none}.mat-mdc-icon-button.mat-unthemed:not(.mdc-ripple-upgraded):focus::before,.mat-mdc-icon-button.mat-primary:not(.mdc-ripple-upgraded):focus::before,.mat-mdc-icon-button.mat-accent:not(.mdc-ripple-upgraded):focus::before,.mat-mdc-icon-button.mat-warn:not(.mdc-ripple-upgraded):focus::before{background:rgba(0,0,0,0);opacity:1}',O],encapsulation:2,changeDetection:0})}return yn})(),bn=(()=>{class yn extends De{static \u0275fac=(()=>{let _t;return function($e){return(_t||(_t=i.xGo(yn)))($e||yn)}})();static \u0275cmp=i.VBU({type:yn,selectors:[["a","mat-icon-button",""]],hostVars:15,hostBindings:function(ze,$e){2&ze&&(i.BMQ("disabled",$e._getDisabledAttribute())("tabindex",$e.disabled&&!$e.disabledInteractive?-1:$e.tabIndex)("aria-disabled",$e._getAriaDisabled()),i.HbH($e.color?"mat-"+$e.color:""),i.AVh("mat-mdc-button-disabled",$e.disabled)("mat-mdc-button-disabled-interactive",$e.disabledInteractive)("_mat-animation-noopable","NoopAnimations"===$e._animationMode)("mat-unthemed",!$e.color)("mat-mdc-button-base",!0))},exportAs:["matButton","matAnchor"],features:[i.Vt3],attrs:re,ngContentSelectors:pe,decls:4,vars:0,consts:[[1,"mat-mdc-button-persistent-ripple","mdc-icon-button__ripple"],[1,"mat-focus-indicator"],[1,"mat-mdc-button-touch-target"]],template:function(ze,$e){1&ze&&(i.NAR(),i.nrm(0,"span",0),i.SdG(1),i.nrm(2,"span",1)(3,"span",2))},styles:['.mat-mdc-icon-button{-webkit-user-select:none;user-select:none;display:inline-block;position:relative;box-sizing:border-box;border:none;outline:none;background-color:rgba(0,0,0,0);fill:currentColor;color:inherit;text-decoration:none;cursor:pointer;z-index:0;overflow:visible;border-radius:50%;flex-shrink:0;text-align:center;width:var(--mdc-icon-button-state-layer-size, 40px);height:var(--mdc-icon-button-state-layer-size, 40px);padding:calc(calc(var(--mdc-icon-button-state-layer-size, 40px) - var(--mdc-icon-button-icon-size, 24px)) / 2);font-size:var(--mdc-icon-button-icon-size, 24px);color:var(--mdc-icon-button-icon-color, var(--mat-sys-on-surface-variant));-webkit-tap-highlight-color:rgba(0,0,0,0)}.mat-mdc-icon-button .mat-mdc-button-ripple,.mat-mdc-icon-button .mat-mdc-button-persistent-ripple,.mat-mdc-icon-button .mat-mdc-button-persistent-ripple::before{top:0;left:0;right:0;bottom:0;position:absolute;pointer-events:none;border-radius:inherit}.mat-mdc-icon-button .mat-mdc-button-ripple{overflow:hidden}.mat-mdc-icon-button .mat-mdc-button-persistent-ripple::before{content:"";opacity:0}.mat-mdc-icon-button .mdc-button__label,.mat-mdc-icon-button .mat-icon{z-index:1;position:relative}.mat-mdc-icon-button .mat-focus-indicator{top:0;left:0;right:0;bottom:0;position:absolute}.mat-mdc-icon-button:focus .mat-focus-indicator::before{content:""}.mat-mdc-icon-button .mat-ripple-element{background-color:var(--mat-icon-button-ripple-color, color-mix(in srgb, var(--mat-sys-on-surface-variant) calc(var(--mat-sys-pressed-state-layer-opacity) * 100%), transparent))}.mat-mdc-icon-button .mat-mdc-button-persistent-ripple::before{background-color:var(--mat-icon-button-state-layer-color, var(--mat-sys-on-surface-variant))}.mat-mdc-icon-button.mat-mdc-button-disabled .mat-mdc-button-persistent-ripple::before{background-color:var(--mat-icon-button-disabled-state-layer-color, var(--mat-sys-on-surface-variant))}.mat-mdc-icon-button:hover .mat-mdc-button-persistent-ripple::before{opacity:var(--mat-icon-button-hover-state-layer-opacity, var(--mat-sys-hover-state-layer-opacity))}.mat-mdc-icon-button.cdk-program-focused .mat-mdc-button-persistent-ripple::before,.mat-mdc-icon-button.cdk-keyboard-focused .mat-mdc-button-persistent-ripple::before,.mat-mdc-icon-button.mat-mdc-button-disabled-interactive:focus .mat-mdc-button-persistent-ripple::before{opacity:var(--mat-icon-button-focus-state-layer-opacity, var(--mat-sys-focus-state-layer-opacity))}.mat-mdc-icon-button:active .mat-mdc-button-persistent-ripple::before{opacity:var(--mat-icon-button-pressed-state-layer-opacity, var(--mat-sys-pressed-state-layer-opacity))}.mat-mdc-icon-button .mat-mdc-button-touch-target{position:absolute;top:50%;height:48px;left:50%;width:48px;transform:translate(-50%, -50%);display:var(--mat-icon-button-touch-target-display, block)}.mat-mdc-icon-button._mat-animation-noopable{transition:none !important;animation:none !important}.mat-mdc-icon-button[disabled],.mat-mdc-icon-button.mat-mdc-button-disabled{cursor:default;pointer-events:none;color:var(--mdc-icon-button-disabled-icon-color, color-mix(in srgb, var(--mat-sys-on-surface) 38%, transparent))}.mat-mdc-icon-button.mat-mdc-button-disabled-interactive{pointer-events:auto}.mat-mdc-icon-button img,.mat-mdc-icon-button svg{width:var(--mdc-icon-button-icon-size, 24px);height:var(--mdc-icon-button-icon-size, 24px);vertical-align:baseline}.mat-mdc-icon-button .mat-mdc-button-persistent-ripple{border-radius:50%}.mat-mdc-icon-button[hidden]{display:none}.mat-mdc-icon-button.mat-unthemed:not(.mdc-ripple-upgraded):focus::before,.mat-mdc-icon-button.mat-primary:not(.mdc-ripple-upgraded):focus::before,.mat-mdc-icon-button.mat-accent:not(.mdc-ripple-upgraded):focus::before,.mat-mdc-icon-button.mat-warn:not(.mdc-ripple-upgraded):focus::before{background:rgba(0,0,0,0);opacity:1}',O],encapsulation:2,changeDetection:0})}return yn})(),Vn=(()=>{class yn{static \u0275fac=function(ze){return new(ze||yn)};static \u0275mod=i.$C({type:yn});static \u0275inj=i.G2t({imports:[y.yE,y.pZ,y.yE]})}return yn})()},2902:(o,s,r)=>{"use strict";r.d(s,{Ah:()=>Ze,Ej:()=>Tr,Ju:()=>Be,MI:()=>Le,MJ:()=>bt,N:()=>ce,QC:()=>N,Sy:()=>Tn,TL:()=>St,X0:()=>Ce,de:()=>lt,es:()=>Ke,is:()=>z,jb:()=>mt,pZ:()=>Fe,r6:()=>cn,tO:()=>Vr,wT:()=>ft,yE:()=>ue});var i=r(3107),a=r(8559),c=r(2944),y=r(8447),w=r(2147),C=r(3022),T=r(5467),S=r(5919),M=r(4460);const Z=["text"],q=[[["mat-icon"]],"*"],re=["mat-icon","*"];function pe(vt,Wt){if(1&vt&&i.nrm(0,"mat-pseudo-checkbox",1),2&vt){const Re=i.XpG();i.Y8G("disabled",Re.disabled)("state",Re.selected?"checked":"unchecked")}}function se(vt,Wt){if(1&vt&&i.nrm(0,"mat-pseudo-checkbox",3),2&vt){const Re=i.XpG();i.Y8G("disabled",Re.disabled)}}function ae(vt,Wt){if(1&vt&&(i.j41(0,"span",4),i.EFF(1),i.k0s()),2&vt){const Re=i.XpG();i.R7$(),i.SpI("(",Re.group.label,")")}}const me=["mat-internal-form-field",""],be=["*"],ce=new i.nKC("mat-sanity-checks",{providedIn:"root",factory:()=>!0});let ue=(()=>{class vt{constructor(){(0,i.WQX)(a.Q_)._applyBodyHighContrastModeCssClasses()}static \u0275fac=function(Ge){return new(Ge||vt)};static \u0275mod=i.$C({type:vt});static \u0275inj=i.G2t({imports:[c.jI,c.jI]})}return vt})();class Ce{_defaultMatcher;ngControl;_parentFormGroup;_parentForm;_stateChanges;errorState=!1;matcher;constructor(Wt,Re,Ge,Ve,Dt){this._defaultMatcher=Wt,this.ngControl=Re,this._parentFormGroup=Ge,this._parentForm=Ve,this._stateChanges=Dt}updateErrorState(){const Wt=this.errorState,Re=this._parentFormGroup||this._parentForm,Ge=this.matcher||this._defaultMatcher,Ve=this.ngControl?this.ngControl.control:null,Dt=Ge?.isErrorState(Ve,Re)??!1;Dt!==Wt&&(this.errorState=Dt,this._stateChanges.next())}}const Be=new i.nKC("MAT_DATE_LOCALE",{providedIn:"root",factory:function at(){return(0,i.WQX)(i.xe9)}}),dt="Method not implemented";class bt{locale;_localeChanges=new y.B;localeChanges=this._localeChanges;setTime(Wt,Re,Ge,Ve){throw new Error(dt)}getHours(Wt){throw new Error(dt)}getMinutes(Wt){throw new Error(dt)}getSeconds(Wt){throw new Error(dt)}parseTime(Wt,Re){throw new Error(dt)}addSeconds(Wt,Re){throw new Error(dt)}getValidDateOrNull(Wt){return this.isDateInstance(Wt)&&this.isValid(Wt)?Wt:null}deserialize(Wt){return null==Wt||this.isDateInstance(Wt)&&this.isValid(Wt)?Wt:this.invalid()}setLocale(Wt){this.locale=Wt,this._localeChanges.next()}compareDate(Wt,Re){return this.getYear(Wt)-this.getYear(Re)||this.getMonth(Wt)-this.getMonth(Re)||this.getDate(Wt)-this.getDate(Re)}compareTime(Wt,Re){return this.getHours(Wt)-this.getHours(Re)||this.getMinutes(Wt)-this.getMinutes(Re)||this.getSeconds(Wt)-this.getSeconds(Re)}sameDate(Wt,Re){if(Wt&&Re){let Ge=this.isValid(Wt),Ve=this.isValid(Re);return Ge&&Ve?!this.compareDate(Wt,Re):Ge==Ve}return Wt==Re}sameTime(Wt,Re){if(Wt&&Re){const Ge=this.isValid(Wt),Ve=this.isValid(Re);return Ge&&Ve?!this.compareTime(Wt,Re):Ge==Ve}return Wt==Re}clampDate(Wt,Re,Ge){return Re&&this.compareDate(Wt,Re)<0?Re:Ge&&this.compareDate(Wt,Ge)>0?Ge:Wt}}const lt=new i.nKC("mat-date-formats");let Ke=(()=>{class vt{isErrorState(Re,Ge){return!!(Re&&Re.invalid&&(Re.touched||Ge&&Ge.submitted))}static \u0275fac=function(Ge){return new(Ge||vt)};static \u0275prov=i.jDH({token:vt,factory:vt.\u0275fac,providedIn:"root"})}return vt})(),Ze=(()=>{class vt{static \u0275fac=function(Ge){return new(Ge||vt)};static \u0275cmp=i.VBU({type:vt,selectors:[["structural-styles"]],decls:0,vars:0,template:function(Ge,Ve){},styles:['.mat-focus-indicator{position:relative}.mat-focus-indicator::before{top:0;left:0;right:0;bottom:0;position:absolute;box-sizing:border-box;pointer-events:none;display:var(--mat-focus-indicator-display, none);border-width:var(--mat-focus-indicator-border-width, 3px);border-style:var(--mat-focus-indicator-border-style, solid);border-color:var(--mat-focus-indicator-border-color, transparent);border-radius:var(--mat-focus-indicator-border-radius, 4px)}.mat-focus-indicator:focus::before{content:""}@media(forced-colors: active){html{--mat-focus-indicator-display: block}}'],encapsulation:2,changeDetection:0})}return vt})();var Ee=function(vt){return vt[vt.FADING_IN=0]="FADING_IN",vt[vt.VISIBLE=1]="VISIBLE",vt[vt.FADING_OUT=2]="FADING_OUT",vt[vt.HIDDEN=3]="HIDDEN",vt}(Ee||{});class st{_renderer;element;config;_animationForciblyDisabledThroughCss;state=Ee.HIDDEN;constructor(Wt,Re,Ge,Ve=!1){this._renderer=Wt,this.element=Re,this.config=Ge,this._animationForciblyDisabledThroughCss=Ve}fadeOut(){this._renderer.fadeOutRipple(this)}}const Xt=(0,w.BQ)({passive:!0,capture:!0});class Mt{_events=new Map;addHandler(Wt,Re,Ge,Ve){const Dt=this._events.get(Re);if(Dt){const ct=Dt.get(Ge);ct?ct.add(Ve):Dt.set(Ge,new Set([Ve]))}else this._events.set(Re,new Map([[Ge,new Set([Ve])]])),Wt.runOutsideAngular(()=>{document.addEventListener(Re,this._delegateEventHandler,Xt)})}removeHandler(Wt,Re,Ge){const Ve=this._events.get(Wt);if(!Ve)return;const Dt=Ve.get(Re);Dt&&(Dt.delete(Ge),0===Dt.size&&Ve.delete(Re),0===Ve.size&&(this._events.delete(Wt),document.removeEventListener(Wt,this._delegateEventHandler,Xt)))}_delegateEventHandler=Wt=>{const Re=(0,w.Fb)(Wt);Re&&this._events.get(Wt.type)?.forEach((Ge,Ve)=>{(Ve===Re||Ve.contains(Re))&&Ge.forEach(Dt=>Dt.handleEvent(Wt))})}}const Kt={enterDuration:225,exitDuration:150},Vt=(0,w.BQ)({passive:!0,capture:!0}),en=["mousedown","touchstart"],kn=["mouseup","mouseleave","touchend","touchcancel"];let Kn=(()=>{class vt{static \u0275fac=function(Ge){return new(Ge||vt)};static \u0275cmp=i.VBU({type:vt,selectors:[["ng-component"]],hostAttrs:["mat-ripple-style-loader",""],decls:0,vars:0,template:function(Ge,Ve){},styles:[".mat-ripple{overflow:hidden;position:relative}.mat-ripple:not(:empty){transform:translateZ(0)}.mat-ripple.mat-ripple-unbounded{overflow:visible}.mat-ripple-element{position:absolute;border-radius:50%;pointer-events:none;transition:opacity,transform 0ms cubic-bezier(0, 0, 0.2, 1);transform:scale3d(0, 0, 0);background-color:var(--mat-ripple-color, color-mix(in srgb, var(--mat-sys-on-surface) 10%, transparent))}@media(forced-colors: active){.mat-ripple-element{display:none}}.cdk-drag-preview .mat-ripple-element,.cdk-drag-placeholder .mat-ripple-element{display:none}"],encapsulation:2,changeDetection:0})}return vt})();class Nr{_target;_ngZone;_platform;_containerElement;_triggerElement;_isPointerDown=!1;_activeRipples=new Map;_mostRecentTransientRipple;_lastTouchStartEvent;_pointerUpEventsRegistered=!1;_containerRect;static _eventManager=new Mt;constructor(Wt,Re,Ge,Ve,Dt){this._target=Wt,this._ngZone=Re,this._platform=Ve,Ve.isBrowser&&(this._containerElement=(0,C.i8)(Ge)),Dt&&Dt.get(T.l).load(Kn)}fadeInRipple(Wt,Re,Ge={}){const Ve=this._containerRect=this._containerRect||this._containerElement.getBoundingClientRect(),Dt={...Kt,...Ge.animation};Ge.centered&&(Wt=Ve.left+Ve.width/2,Re=Ve.top+Ve.height/2);const ct=Ge.radius||function Rn(vt,Wt,Re){const Ge=Math.max(Math.abs(vt-Re.left),Math.abs(vt-Re.right)),Ve=Math.max(Math.abs(Wt-Re.top),Math.abs(Wt-Re.bottom));return Math.sqrt(Ge*Ge+Ve*Ve)}(Wt,Re,Ve),Bt=Wt-Ve.left,wn=Re-Ve.top,qn=Dt.enterDuration,Er=document.createElement("div");Er.classList.add("mat-ripple-element"),Er.style.left=Bt-ct+"px",Er.style.top=wn-ct+"px",Er.style.height=2*ct+"px",Er.style.width=2*ct+"px",null!=Ge.color&&(Er.style.backgroundColor=Ge.color),Er.style.transitionDuration=`${qn}ms`,this._containerElement.appendChild(Er);const si=window.getComputedStyle(Er),Zi=si.transitionDuration,Jt="none"===si.transitionProperty||"0s"===Zi||"0s, 0s"===Zi||0===Ve.width&&0===Ve.height,Tt=new st(this,Er,Ge,Jt);Er.style.transform="scale3d(1, 1, 1)",Tt.state=Ee.FADING_IN,Ge.persistent||(this._mostRecentTransientRipple=Tt);let nt=null;return!Jt&&(qn||Dt.exitDuration)&&this._ngZone.runOutsideAngular(()=>{const Rt=()=>{nt&&(nt.fallbackTimer=null),clearTimeout(mn),this._finishRippleTransition(Tt)},sn=()=>this._destroyRipple(Tt),mn=setTimeout(sn,qn+100);Er.addEventListener("transitionend",Rt),Er.addEventListener("transitioncancel",sn),nt={onTransitionEnd:Rt,onTransitionCancel:sn,fallbackTimer:mn}}),this._activeRipples.set(Tt,nt),(Jt||!qn)&&this._finishRippleTransition(Tt),Tt}fadeOutRipple(Wt){if(Wt.state===Ee.FADING_OUT||Wt.state===Ee.HIDDEN)return;const Re=Wt.element,Ge={...Kt,...Wt.config.animation};Re.style.transitionDuration=`${Ge.exitDuration}ms`,Re.style.opacity="0",Wt.state=Ee.FADING_OUT,(Wt._animationForciblyDisabledThroughCss||!Ge.exitDuration)&&this._finishRippleTransition(Wt)}fadeOutAll(){this._getActiveRipples().forEach(Wt=>Wt.fadeOut())}fadeOutAllNonPersistent(){this._getActiveRipples().forEach(Wt=>{Wt.config.persistent||Wt.fadeOut()})}setupTriggerEvents(Wt){const Re=(0,C.i8)(Wt);!this._platform.isBrowser||!Re||Re===this._triggerElement||(this._removeTriggerEvents(),this._triggerElement=Re,en.forEach(Ge=>{Nr._eventManager.addHandler(this._ngZone,Ge,Re,this)}))}handleEvent(Wt){"mousedown"===Wt.type?this._onMousedown(Wt):"touchstart"===Wt.type?this._onTouchStart(Wt):this._onPointerUp(),this._pointerUpEventsRegistered||(this._ngZone.runOutsideAngular(()=>{kn.forEach(Re=>{this._triggerElement.addEventListener(Re,this,Vt)})}),this._pointerUpEventsRegistered=!0)}_finishRippleTransition(Wt){Wt.state===Ee.FADING_IN?this._startFadeOutTransition(Wt):Wt.state===Ee.FADING_OUT&&this._destroyRipple(Wt)}_startFadeOutTransition(Wt){const Re=Wt===this._mostRecentTransientRipple,{persistent:Ge}=Wt.config;Wt.state=Ee.VISIBLE,!Ge&&(!Re||!this._isPointerDown)&&Wt.fadeOut()}_destroyRipple(Wt){const Re=this._activeRipples.get(Wt)??null;this._activeRipples.delete(Wt),this._activeRipples.size||(this._containerRect=null),Wt===this._mostRecentTransientRipple&&(this._mostRecentTransientRipple=null),Wt.state=Ee.HIDDEN,null!==Re&&(Wt.element.removeEventListener("transitionend",Re.onTransitionEnd),Wt.element.removeEventListener("transitioncancel",Re.onTransitionCancel),null!==Re.fallbackTimer&&clearTimeout(Re.fallbackTimer)),Wt.element.remove()}_onMousedown(Wt){const Re=(0,a._G)(Wt),Ge=this._lastTouchStartEvent&&Date.now(){!Wt.config.persistent&&(Wt.state===Ee.VISIBLE||Wt.config.terminateOnPointerUp&&Wt.state===Ee.FADING_IN)&&Wt.fadeOut()}))}_getActiveRipples(){return Array.from(this._activeRipples.keys())}_removeTriggerEvents(){const Wt=this._triggerElement;Wt&&(en.forEach(Re=>Nr._eventManager.removeHandler(Re,Wt,this)),this._pointerUpEventsRegistered&&(kn.forEach(Re=>Wt.removeEventListener(Re,this,Vt)),this._pointerUpEventsRegistered=!1))}}const pr=new i.nKC("mat-ripple-global-options");let cn=(()=>{class vt{_elementRef=(0,i.WQX)(i.aKT);_animationMode=(0,i.WQX)(i.bc$,{optional:!0});color;unbounded;centered;radius=0;animation;get disabled(){return this._disabled}set disabled(Re){Re&&this.fadeOutAllNonPersistent(),this._disabled=Re,this._setupTriggerEventsIfEnabled()}_disabled=!1;get trigger(){return this._trigger||this._elementRef.nativeElement}set trigger(Re){this._trigger=Re,this._setupTriggerEventsIfEnabled()}_trigger;_rippleRenderer;_globalOptions;_isInitialized=!1;constructor(){const Re=(0,i.WQX)(i.SKi),Ge=(0,i.WQX)(w.OD),Ve=(0,i.WQX)(pr,{optional:!0}),Dt=(0,i.WQX)(i.zZn);this._globalOptions=Ve||{},this._rippleRenderer=new Nr(this,Re,this._elementRef,Ge,Dt)}ngOnInit(){this._isInitialized=!0,this._setupTriggerEventsIfEnabled()}ngOnDestroy(){this._rippleRenderer._removeTriggerEvents()}fadeOutAll(){this._rippleRenderer.fadeOutAll()}fadeOutAllNonPersistent(){this._rippleRenderer.fadeOutAllNonPersistent()}get rippleConfig(){return{centered:this.centered,radius:this.radius,color:this.color,animation:{...this._globalOptions.animation,..."NoopAnimations"===this._animationMode?{enterDuration:0,exitDuration:0}:{},...this.animation},terminateOnPointerUp:this._globalOptions.terminateOnPointerUp}}get rippleDisabled(){return this.disabled||!!this._globalOptions.disabled}_setupTriggerEventsIfEnabled(){!this.disabled&&this._isInitialized&&this._rippleRenderer.setupTriggerEvents(this.trigger)}launch(Re,Ge=0,Ve){return"number"==typeof Re?this._rippleRenderer.fadeInRipple(Re,Ge,{...this.rippleConfig,...Ve}):this._rippleRenderer.fadeInRipple(0,0,{...this.rippleConfig,...Re})}static \u0275fac=function(Ge){return new(Ge||vt)};static \u0275dir=i.FsC({type:vt,selectors:[["","mat-ripple",""],["","matRipple",""]],hostAttrs:[1,"mat-ripple"],hostVars:2,hostBindings:function(Ge,Ve){2&Ge&&i.AVh("mat-ripple-unbounded",Ve.unbounded)},inputs:{color:[0,"matRippleColor","color"],unbounded:[0,"matRippleUnbounded","unbounded"],centered:[0,"matRippleCentered","centered"],radius:[0,"matRippleRadius","radius"],animation:[0,"matRippleAnimation","animation"],disabled:[0,"matRippleDisabled","disabled"],trigger:[0,"matRippleTrigger","trigger"]},exportAs:["matRipple"]})}return vt})(),Fe=(()=>{class vt{static \u0275fac=function(Ge){return new(Ge||vt)};static \u0275mod=i.$C({type:vt});static \u0275inj=i.G2t({imports:[ue,ue]})}return vt})(),ke=(()=>{class vt{_animationMode=(0,i.WQX)(i.bc$,{optional:!0});state="unchecked";disabled=!1;appearance="full";constructor(){}static \u0275fac=function(Ge){return new(Ge||vt)};static \u0275cmp=i.VBU({type:vt,selectors:[["mat-pseudo-checkbox"]],hostAttrs:[1,"mat-pseudo-checkbox"],hostVars:12,hostBindings:function(Ge,Ve){2&Ge&&i.AVh("mat-pseudo-checkbox-indeterminate","indeterminate"===Ve.state)("mat-pseudo-checkbox-checked","checked"===Ve.state)("mat-pseudo-checkbox-disabled",Ve.disabled)("mat-pseudo-checkbox-minimal","minimal"===Ve.appearance)("mat-pseudo-checkbox-full","full"===Ve.appearance)("_mat-animation-noopable","NoopAnimations"===Ve._animationMode)},inputs:{state:"state",disabled:"disabled",appearance:"appearance"},decls:0,vars:0,template:function(Ge,Ve){},styles:['.mat-pseudo-checkbox{border-radius:2px;cursor:pointer;display:inline-block;vertical-align:middle;box-sizing:border-box;position:relative;flex-shrink:0;transition:border-color 90ms cubic-bezier(0, 0, 0.2, 0.1),background-color 90ms cubic-bezier(0, 0, 0.2, 0.1)}.mat-pseudo-checkbox::after{position:absolute;opacity:0;content:"";border-bottom:2px solid currentColor;transition:opacity 90ms cubic-bezier(0, 0, 0.2, 0.1)}.mat-pseudo-checkbox._mat-animation-noopable{transition:none !important;animation:none !important}.mat-pseudo-checkbox._mat-animation-noopable::after{transition:none}.mat-pseudo-checkbox-disabled{cursor:default}.mat-pseudo-checkbox-indeterminate::after{left:1px;opacity:1;border-radius:2px}.mat-pseudo-checkbox-checked::after{left:1px;border-left:2px solid currentColor;transform:rotate(-45deg);opacity:1;box-sizing:content-box}.mat-pseudo-checkbox-minimal.mat-pseudo-checkbox-checked::after,.mat-pseudo-checkbox-minimal.mat-pseudo-checkbox-indeterminate::after{color:var(--mat-minimal-pseudo-checkbox-selected-checkmark-color, var(--mat-sys-primary))}.mat-pseudo-checkbox-minimal.mat-pseudo-checkbox-checked.mat-pseudo-checkbox-disabled::after,.mat-pseudo-checkbox-minimal.mat-pseudo-checkbox-indeterminate.mat-pseudo-checkbox-disabled::after{color:var(--mat-minimal-pseudo-checkbox-disabled-selected-checkmark-color, color-mix(in srgb, var(--mat-sys-on-surface) 38%, transparent))}.mat-pseudo-checkbox-full{border-color:var(--mat-full-pseudo-checkbox-unselected-icon-color, var(--mat-sys-on-surface-variant));border-width:2px;border-style:solid}.mat-pseudo-checkbox-full.mat-pseudo-checkbox-disabled{border-color:var(--mat-full-pseudo-checkbox-disabled-unselected-icon-color, color-mix(in srgb, var(--mat-sys-on-surface) 38%, transparent))}.mat-pseudo-checkbox-full.mat-pseudo-checkbox-checked,.mat-pseudo-checkbox-full.mat-pseudo-checkbox-indeterminate{background-color:var(--mat-full-pseudo-checkbox-selected-icon-color, var(--mat-sys-primary));border-color:rgba(0,0,0,0)}.mat-pseudo-checkbox-full.mat-pseudo-checkbox-checked::after,.mat-pseudo-checkbox-full.mat-pseudo-checkbox-indeterminate::after{color:var(--mat-full-pseudo-checkbox-selected-checkmark-color, var(--mat-sys-on-primary))}.mat-pseudo-checkbox-full.mat-pseudo-checkbox-checked.mat-pseudo-checkbox-disabled,.mat-pseudo-checkbox-full.mat-pseudo-checkbox-indeterminate.mat-pseudo-checkbox-disabled{background-color:var(--mat-full-pseudo-checkbox-disabled-selected-icon-color, color-mix(in srgb, var(--mat-sys-on-surface) 38%, transparent))}.mat-pseudo-checkbox-full.mat-pseudo-checkbox-checked.mat-pseudo-checkbox-disabled::after,.mat-pseudo-checkbox-full.mat-pseudo-checkbox-indeterminate.mat-pseudo-checkbox-disabled::after{color:var(--mat-full-pseudo-checkbox-disabled-selected-checkmark-color, var(--mat-sys-surface))}.mat-pseudo-checkbox{width:18px;height:18px}.mat-pseudo-checkbox-minimal.mat-pseudo-checkbox-checked::after{width:14px;height:6px;transform-origin:center;top:-4.2426406871px;left:0;bottom:0;right:0;margin:auto}.mat-pseudo-checkbox-minimal.mat-pseudo-checkbox-indeterminate::after{top:8px;width:16px}.mat-pseudo-checkbox-full.mat-pseudo-checkbox-checked::after{width:10px;height:4px;transform-origin:center;top:-2.8284271247px;left:0;bottom:0;right:0;margin:auto}.mat-pseudo-checkbox-full.mat-pseudo-checkbox-indeterminate::after{top:6px;width:12px}'],encapsulation:2,changeDetection:0})}return vt})(),Je=(()=>{class vt{static \u0275fac=function(Ge){return new(Ge||vt)};static \u0275mod=i.$C({type:vt});static \u0275inj=i.G2t({imports:[ue]})}return vt})();const z=new i.nKC("MAT_OPTION_PARENT_COMPONENT"),N=new i.nKC("MatOptgroup");class Le{source;isUserInput;constructor(Wt,Re=!1){this.source=Wt,this.isUserInput=Re}}let ft=(()=>{class vt{_element=(0,i.WQX)(i.aKT);_changeDetectorRef=(0,i.WQX)(i.gRc);_parent=(0,i.WQX)(z,{optional:!0});group=(0,i.WQX)(N,{optional:!0});_signalDisableRipple=!1;_selected=!1;_active=!1;_disabled=!1;_mostRecentViewValue="";get multiple(){return this._parent&&this._parent.multiple}get selected(){return this._selected}value;id=(0,i.WQX)(a.g7).getId("mat-option-");get disabled(){return this.group&&this.group.disabled||this._disabled}set disabled(Re){this._disabled=Re}get disableRipple(){return this._signalDisableRipple?this._parent.disableRipple():!!this._parent?.disableRipple}get hideSingleSelectionIndicator(){return!(!this._parent||!this._parent.hideSingleSelectionIndicator)}onSelectionChange=new i.bkB;_text;_stateChanges=new y.B;constructor(){(0,i.WQX)(T.l).load(Ze),(0,i.WQX)(T.l).load(T.Y),this._signalDisableRipple=!!this._parent&&(0,i.Hps)(this._parent.disableRipple)}get active(){return this._active}get viewValue(){return(this._text?.nativeElement.textContent||"").trim()}select(Re=!0){this._selected||(this._selected=!0,this._changeDetectorRef.markForCheck(),Re&&this._emitSelectionChangeEvent())}deselect(Re=!0){this._selected&&(this._selected=!1,this._changeDetectorRef.markForCheck(),Re&&this._emitSelectionChangeEvent())}focus(Re,Ge){const Ve=this._getHostElement();"function"==typeof Ve.focus&&Ve.focus(Ge)}setActiveStyles(){this._active||(this._active=!0,this._changeDetectorRef.markForCheck())}setInactiveStyles(){this._active&&(this._active=!1,this._changeDetectorRef.markForCheck())}getLabel(){return this.viewValue}_handleKeydown(Re){(Re.keyCode===S.Fm||Re.keyCode===S.t6)&&!(0,S.rp)(Re)&&(this._selectViaInteraction(),Re.preventDefault())}_selectViaInteraction(){this.disabled||(this._selected=!this.multiple||!this._selected,this._changeDetectorRef.markForCheck(),this._emitSelectionChangeEvent(!0))}_getTabIndex(){return this.disabled?"-1":"0"}_getHostElement(){return this._element.nativeElement}ngAfterViewChecked(){if(this._selected){const Re=this.viewValue;Re!==this._mostRecentViewValue&&(this._mostRecentViewValue&&this._stateChanges.next(),this._mostRecentViewValue=Re)}}ngOnDestroy(){this._stateChanges.complete()}_emitSelectionChangeEvent(Re=!1){this.onSelectionChange.emit(new Le(this,Re))}static \u0275fac=function(Ge){return new(Ge||vt)};static \u0275cmp=i.VBU({type:vt,selectors:[["mat-option"]],viewQuery:function(Ge,Ve){if(1&Ge&&i.GBs(Z,7),2&Ge){let Dt;i.mGM(Dt=i.lsd())&&(Ve._text=Dt.first)}},hostAttrs:["role","option",1,"mat-mdc-option","mdc-list-item"],hostVars:11,hostBindings:function(Ge,Ve){1&Ge&&i.bIt("click",function(){return Ve._selectViaInteraction()})("keydown",function(ct){return Ve._handleKeydown(ct)}),2&Ge&&(i.Mr5("id",Ve.id),i.BMQ("aria-selected",Ve.selected)("aria-disabled",Ve.disabled.toString()),i.AVh("mdc-list-item--selected",Ve.selected)("mat-mdc-option-multiple",Ve.multiple)("mat-mdc-option-active",Ve.active)("mdc-list-item--disabled",Ve.disabled))},inputs:{value:"value",id:"id",disabled:[2,"disabled","disabled",i.L39]},outputs:{onSelectionChange:"onSelectionChange"},exportAs:["matOption"],features:[i.GFd],ngContentSelectors:re,decls:8,vars:5,consts:[["text",""],["aria-hidden","true",1,"mat-mdc-option-pseudo-checkbox",3,"disabled","state"],[1,"mdc-list-item__primary-text"],["state","checked","aria-hidden","true","appearance","minimal",1,"mat-mdc-option-pseudo-checkbox",3,"disabled"],[1,"cdk-visually-hidden"],["aria-hidden","true","mat-ripple","",1,"mat-mdc-option-ripple","mat-focus-indicator",3,"matRippleTrigger","matRippleDisabled"]],template:function(Ge,Ve){1&Ge&&(i.NAR(q),i.DNE(0,pe,1,2,"mat-pseudo-checkbox",1),i.SdG(1),i.j41(2,"span",2,0),i.SdG(4,1),i.k0s(),i.DNE(5,se,1,1,"mat-pseudo-checkbox",3)(6,ae,2,1,"span",4),i.nrm(7,"div",5)),2&Ge&&(i.vxM(Ve.multiple?0:-1),i.R7$(5),i.vxM(Ve.multiple||!Ve.selected||Ve.hideSingleSelectionIndicator?-1:5),i.R7$(),i.vxM(Ve.group&&Ve.group._inert?6:-1),i.R7$(),i.Y8G("matRippleTrigger",Ve._getHostElement())("matRippleDisabled",Ve.disabled||Ve.disableRipple))},dependencies:[ke,cn],styles:['.mat-mdc-option{-webkit-user-select:none;user-select:none;-moz-osx-font-smoothing:grayscale;-webkit-font-smoothing:antialiased;display:flex;position:relative;align-items:center;justify-content:flex-start;overflow:hidden;min-height:48px;padding:0 16px;cursor:pointer;-webkit-tap-highlight-color:rgba(0,0,0,0);color:var(--mat-option-label-text-color, var(--mat-sys-on-surface));font-family:var(--mat-option-label-text-font, var(--mat-sys-label-large-font));line-height:var(--mat-option-label-text-line-height, var(--mat-sys-label-large-line-height));font-size:var(--mat-option-label-text-size, var(--mat-sys-body-large-size));letter-spacing:var(--mat-option-label-text-tracking, var(--mat-sys-label-large-tracking));font-weight:var(--mat-option-label-text-weight, var(--mat-sys-body-large-weight))}.mat-mdc-option:hover:not(.mdc-list-item--disabled){background-color:var(--mat-option-hover-state-layer-color, color-mix(in srgb, var(--mat-sys-on-surface) calc(var(--mat-sys-hover-state-layer-opacity) * 100%), transparent))}.mat-mdc-option:focus.mdc-list-item,.mat-mdc-option.mat-mdc-option-active.mdc-list-item{background-color:var(--mat-option-focus-state-layer-color, color-mix(in srgb, var(--mat-sys-on-surface) calc(var(--mat-sys-focus-state-layer-opacity) * 100%), transparent));outline:0}.mat-mdc-option.mdc-list-item--selected:not(.mdc-list-item--disabled) .mdc-list-item__primary-text{color:var(--mat-option-selected-state-label-text-color, var(--mat-sys-on-secondary-container))}.mat-mdc-option.mdc-list-item--selected:not(.mdc-list-item--disabled):not(.mat-mdc-option-multiple){background-color:var(--mat-option-selected-state-layer-color, var(--mat-sys-secondary-container))}.mat-mdc-option .mat-pseudo-checkbox{--mat-minimal-pseudo-checkbox-selected-checkmark-color: var(--mat-option-selected-state-label-text-color, var(--mat-sys-on-secondary-container))}.mat-mdc-option.mdc-list-item{align-items:center;background:rgba(0,0,0,0)}.mat-mdc-option.mdc-list-item--disabled{cursor:default;pointer-events:none}.mat-mdc-option.mdc-list-item--disabled .mat-mdc-option-pseudo-checkbox,.mat-mdc-option.mdc-list-item--disabled .mdc-list-item__primary-text,.mat-mdc-option.mdc-list-item--disabled>mat-icon{opacity:.38}.mat-mdc-optgroup .mat-mdc-option:not(.mat-mdc-option-multiple){padding-left:32px}[dir=rtl] .mat-mdc-optgroup .mat-mdc-option:not(.mat-mdc-option-multiple){padding-left:16px;padding-right:32px}.mat-mdc-option .mat-icon,.mat-mdc-option .mat-pseudo-checkbox-full{margin-right:16px;flex-shrink:0}[dir=rtl] .mat-mdc-option .mat-icon,[dir=rtl] .mat-mdc-option .mat-pseudo-checkbox-full{margin-right:0;margin-left:16px}.mat-mdc-option .mat-pseudo-checkbox-minimal{margin-left:16px;flex-shrink:0}[dir=rtl] .mat-mdc-option .mat-pseudo-checkbox-minimal{margin-right:16px;margin-left:0}.mat-mdc-option .mat-mdc-option-ripple{top:0;left:0;right:0;bottom:0;position:absolute;pointer-events:none}.mat-mdc-option .mdc-list-item__primary-text{white-space:normal;font-size:inherit;font-weight:inherit;letter-spacing:inherit;line-height:inherit;font-family:inherit;text-decoration:inherit;text-transform:inherit;margin-right:auto}[dir=rtl] .mat-mdc-option .mdc-list-item__primary-text{margin-right:0;margin-left:auto}@media(forced-colors: active){.mat-mdc-option.mdc-list-item--selected:not(:has(.mat-mdc-option-pseudo-checkbox))::after{content:"";position:absolute;top:50%;right:16px;transform:translateY(-50%);width:10px;height:0;border-bottom:solid 10px;border-radius:10px}[dir=rtl] .mat-mdc-option.mdc-list-item--selected:not(:has(.mat-mdc-option-pseudo-checkbox))::after{right:auto;left:16px}}.mat-mdc-option-multiple{--mdc-list-list-item-selected-container-color:var(--mdc-list-list-item-container-color, transparent)}.mat-mdc-option-active .mat-focus-indicator::before{content:""}'],encapsulation:2,changeDetection:0})}return vt})();function mt(vt,Wt,Re){if(Re.length){let Ge=Wt.toArray(),Ve=Re.toArray(),Dt=0;for(let ct=0;ctRe+Ge?Math.max(0,vt-Ge+Wt):Re}let Tn=(()=>{class vt{static \u0275fac=function(Ge){return new(Ge||vt)};static \u0275mod=i.$C({type:vt});static \u0275inj=i.G2t({imports:[Fe,ue,Je]})}return vt})();const an={capture:!0},dn=["focus","mousedown","mouseenter","touchstart"],In="mat-ripple-loader-uninitialized",sr="mat-ripple-loader-class-name",xn="mat-ripple-loader-centered",Hr="mat-ripple-loader-disabled";let Tr=(()=>{class vt{_document=(0,i.WQX)(M.qQ,{optional:!0});_animationMode=(0,i.WQX)(i.bc$,{optional:!0});_globalRippleOptions=(0,i.WQX)(pr,{optional:!0});_platform=(0,i.WQX)(w.OD);_ngZone=(0,i.WQX)(i.SKi);_injector=(0,i.WQX)(i.zZn);_hosts=new Map;constructor(){this._ngZone.runOutsideAngular(()=>{for(const Re of dn)this._document?.addEventListener(Re,this._onInteraction,an)})}ngOnDestroy(){const Re=this._hosts.keys();for(const Ge of Re)this.destroyRipple(Ge);for(const Ge of dn)this._document?.removeEventListener(Ge,this._onInteraction,an)}configureRipple(Re,Ge){Re.setAttribute(In,this._globalRippleOptions?.namespace??""),(Ge.className||!Re.hasAttribute(sr))&&Re.setAttribute(sr,Ge.className||""),Ge.centered&&Re.setAttribute(xn,""),Ge.disabled&&Re.setAttribute(Hr,"")}setDisabled(Re,Ge){const Ve=this._hosts.get(Re);Ve?(Ve.target.rippleDisabled=Ge,!Ge&&!Ve.hasSetUpEvents&&(Ve.hasSetUpEvents=!0,Ve.renderer.setupTriggerEvents(Re))):Ge?Re.setAttribute(Hr,""):Re.removeAttribute(Hr)}_onInteraction=Re=>{const Ge=(0,w.Fb)(Re);if(Ge instanceof HTMLElement){const Ve=Ge.closest(`[${In}="${this._globalRippleOptions?.namespace??""}"]`);Ve&&this._createRipple(Ve)}};_createRipple(Re){if(!this._document||this._hosts.has(Re))return;Re.querySelector(".mat-ripple")?.remove();const Ge=this._document.createElement("span");Ge.classList.add("mat-ripple",Re.getAttribute(sr)),Re.append(Ge);const Ve="NoopAnimations"===this._animationMode,Dt=this._globalRippleOptions,ct=Ve?0:Dt?.animation?.enterDuration??Kt.enterDuration,Bt=Ve?0:Dt?.animation?.exitDuration??Kt.exitDuration,wn={rippleDisabled:Ve||Dt?.disabled||Re.hasAttribute(Hr),rippleConfig:{centered:Re.hasAttribute(xn),terminateOnPointerUp:Dt?.terminateOnPointerUp,animation:{enterDuration:ct,exitDuration:Bt}}},qn=new Nr(wn,this._ngZone,Ge,this._platform,this._injector),Er=!wn.rippleDisabled;Er&&qn.setupTriggerEvents(Re),this._hosts.set(Re,{target:wn,renderer:qn,hasSetUpEvents:Er}),Re.removeAttribute(In)}destroyRipple(Re){const Ge=this._hosts.get(Re);Ge&&(Ge.renderer._removeTriggerEvents(),this._hosts.delete(Re))}static \u0275fac=function(Ge){return new(Ge||vt)};static \u0275prov=i.jDH({token:vt,factory:vt.\u0275fac,providedIn:"root"})}return vt})(),Vr=(()=>{class vt{labelPosition;static \u0275fac=function(Ge){return new(Ge||vt)};static \u0275cmp=i.VBU({type:vt,selectors:[["div","mat-internal-form-field",""]],hostAttrs:[1,"mdc-form-field","mat-internal-form-field"],hostVars:2,hostBindings:function(Ge,Ve){2&Ge&&i.AVh("mdc-form-field--align-end","before"===Ve.labelPosition)},inputs:{labelPosition:"labelPosition"},attrs:me,ngContentSelectors:be,decls:1,vars:0,template:function(Ge,Ve){1&Ge&&(i.NAR(),i.SdG(0))},styles:[".mat-internal-form-field{-moz-osx-font-smoothing:grayscale;-webkit-font-smoothing:antialiased;display:inline-flex;align-items:center;vertical-align:middle}.mat-internal-form-field>label{margin-left:0;margin-right:auto;padding-left:4px;padding-right:0;order:0}[dir=rtl] .mat-internal-form-field>label{margin-left:auto;margin-right:0;padding-left:0;padding-right:4px}.mdc-form-field--align-end>label{margin-left:auto;margin-right:0;padding-left:0;padding-right:4px;order:-1}[dir=rtl] .mdc-form-field--align-end .mdc-form-field--align-end label{margin-left:0;margin-right:auto;padding-left:4px;padding-right:0}"],encapsulation:2,changeDetection:0})}return vt})()},7544:(o,s,r)=>{"use strict";r.d(s,{Vh:()=>Te,bZ:()=>Kt,E7:()=>Kn,tx:()=>rt,Yi:()=>kn,hM:()=>pr,CP:()=>Ot});var i=r(9666),a=r(3107),c=r(8559),y=r(2147),w=r(6192),C=r(4460),T=r(5919),S=r(8447),M=r(6381),O=r(3016),L=r(2944),Z=r(593);function q(ke,Je){}class re{viewContainerRef;injector;id;role="dialog";panelClass="";hasBackdrop=!0;backdropClass="";disableClose=!1;width="";height="";minWidth;minHeight;maxWidth;maxHeight;positionStrategy;data=null;direction;ariaDescribedBy=null;ariaLabelledBy=null;ariaLabel=null;ariaModal=!0;autoFocus="first-tabbable";restoreFocus=!0;scrollStrategy;closeOnNavigation=!0;closeOnDestroy=!0;closeOnOverlayDetachments=!0;componentFactoryResolver;providers;container;templateContext}let se=(()=>{class ke extends w.lb{_elementRef=(0,a.WQX)(a.aKT);_focusTrapFactory=(0,a.WQX)(c.GX);_config;_interactivityChecker=(0,a.WQX)(c.Z7);_ngZone=(0,a.WQX)(a.SKi);_overlayRef=(0,a.WQX)(i.yY);_focusMonitor=(0,a.WQX)(c.FN);_platform=(0,a.WQX)(y.OD);_document=(0,a.WQX)(C.qQ,{optional:!0});_portalOutlet;_focusTrap=null;_elementFocusedBeforeDialogWasOpened=null;_closeInteractionType=null;_ariaLabelledByQueue=[];_changeDetectorRef=(0,a.WQX)(a.gRc);_injector=(0,a.WQX)(a.zZn);_isDestroyed=!1;constructor(){super(),this._config=(0,a.WQX)(re,{optional:!0})||new re,this._config.ariaLabelledBy&&this._ariaLabelledByQueue.push(this._config.ariaLabelledBy)}_addAriaLabelledBy(z){this._ariaLabelledByQueue.push(z),this._changeDetectorRef.markForCheck()}_removeAriaLabelledBy(z){const N=this._ariaLabelledByQueue.indexOf(z);N>-1&&(this._ariaLabelledByQueue.splice(N,1),this._changeDetectorRef.markForCheck())}_contentAttached(){this._initializeFocusTrap(),this._handleBackdropClicks(),this._captureInitialFocus()}_captureInitialFocus(){this._trapFocus()}ngOnDestroy(){this._isDestroyed=!0,this._restoreFocus()}attachComponentPortal(z){this._portalOutlet.hasAttached();const N=this._portalOutlet.attachComponentPortal(z);return this._contentAttached(),N}attachTemplatePortal(z){this._portalOutlet.hasAttached();const N=this._portalOutlet.attachTemplatePortal(z);return this._contentAttached(),N}attachDomPortal=z=>{this._portalOutlet.hasAttached();const N=this._portalOutlet.attachDomPortal(z);return this._contentAttached(),N};_recaptureFocus(){this._containsFocus()||this._trapFocus()}_forceFocus(z,N){this._interactivityChecker.isFocusable(z)||(z.tabIndex=-1,this._ngZone.runOutsideAngular(()=>{const W=()=>{z.removeEventListener("blur",W),z.removeEventListener("mousedown",W),z.removeAttribute("tabindex")};z.addEventListener("blur",W),z.addEventListener("mousedown",W)})),z.focus(N)}_focusByCssSelector(z,N){let W=this._elementRef.nativeElement.querySelector(z);W&&this._forceFocus(W,N)}_trapFocus(){this._isDestroyed||(0,a.mal)(()=>{const z=this._elementRef.nativeElement;switch(this._config.autoFocus){case!1:case"dialog":this._containsFocus()||z.focus();break;case!0:case"first-tabbable":this._focusTrap?.focusInitialElement()||this._focusDialogContainer();break;case"first-heading":this._focusByCssSelector('h1, h2, h3, h4, h5, h6, [role="heading"]');break;default:this._focusByCssSelector(this._config.autoFocus)}},{injector:this._injector})}_restoreFocus(){const z=this._config.restoreFocus;let N=null;if("string"==typeof z?N=this._document.querySelector(z):"boolean"==typeof z?N=z?this._elementFocusedBeforeDialogWasOpened:null:z&&(N=z),this._config.restoreFocus&&N&&"function"==typeof N.focus){const W=(0,y.vc)(),Le=this._elementRef.nativeElement;(!W||W===this._document.body||W===Le||Le.contains(W))&&(this._focusMonitor?(this._focusMonitor.focusVia(N,this._closeInteractionType),this._closeInteractionType=null):N.focus())}this._focusTrap&&this._focusTrap.destroy()}_focusDialogContainer(){this._elementRef.nativeElement.focus&&this._elementRef.nativeElement.focus()}_containsFocus(){const z=this._elementRef.nativeElement,N=(0,y.vc)();return z===N||z.contains(N)}_initializeFocusTrap(){this._platform.isBrowser&&(this._focusTrap=this._focusTrapFactory.create(this._elementRef.nativeElement),this._document&&(this._elementFocusedBeforeDialogWasOpened=(0,y.vc)()))}_handleBackdropClicks(){this._overlayRef.backdropClick().subscribe(()=>{this._config.disableClose&&this._recaptureFocus()})}static \u0275fac=function(N){return new(N||ke)};static \u0275cmp=a.VBU({type:ke,selectors:[["cdk-dialog-container"]],viewQuery:function(N,W){if(1&N&&a.GBs(w.I3,7),2&N){let Le;a.mGM(Le=a.lsd())&&(W._portalOutlet=Le.first)}},hostAttrs:["tabindex","-1",1,"cdk-dialog-container"],hostVars:6,hostBindings:function(N,W){2&N&&a.BMQ("id",W._config.id||null)("role",W._config.role)("aria-modal",W._config.ariaModal)("aria-labelledby",W._config.ariaLabel?null:W._ariaLabelledByQueue[0])("aria-label",W._config.ariaLabel)("aria-describedby",W._config.ariaDescribedBy||null)},features:[a.Vt3],decls:1,vars:0,consts:[["cdkPortalOutlet",""]],template:function(N,W){1&N&&a.DNE(0,q,0,0,"ng-template",0)},dependencies:[w.I3],styles:[".cdk-dialog-container{display:block;width:100%;height:100%;min-height:inherit;max-height:inherit}"],encapsulation:2})}return ke})();class ae{overlayRef;config;componentInstance;componentRef;containerInstance;disableClose;closed=new S.B;backdropClick;keydownEvents;outsidePointerEvents;id;_detachSubscription;constructor(Je,z){this.overlayRef=Je,this.config=z,this.disableClose=z.disableClose,this.backdropClick=Je.backdropClick(),this.keydownEvents=Je.keydownEvents(),this.outsidePointerEvents=Je.outsidePointerEvents(),this.id=z.id,this.keydownEvents.subscribe(N=>{N.keyCode===T._f&&!this.disableClose&&!(0,T.rp)(N)&&(N.preventDefault(),this.close(void 0,{focusOrigin:"keyboard"}))}),this.backdropClick.subscribe(()=>{this.disableClose||this.close(void 0,{focusOrigin:"mouse"})}),this._detachSubscription=Je.detachments().subscribe(()=>{!1!==z.closeOnOverlayDetachments&&this.close()})}close(Je,z){if(this.containerInstance){const N=this.closed;this.containerInstance._closeInteractionType=z?.focusOrigin||"program",this._detachSubscription.unsubscribe(),this.overlayRef.dispose(),N.next(Je),N.complete(),this.componentInstance=this.containerInstance=null}}updatePosition(){return this.overlayRef.updatePosition(),this}updateSize(Je="",z=""){return this.overlayRef.updateSize({width:Je,height:z}),this}addPanelClass(Je){return this.overlayRef.addPanelClass(Je),this}removePanelClass(Je){return this.overlayRef.removePanelClass(Je),this}}const me=new a.nKC("DialogScrollStrategy",{providedIn:"root",factory:()=>{const ke=(0,a.WQX)(i.hJ);return()=>ke.scrollStrategies.block()}}),be=new a.nKC("DialogData"),Oe=new a.nKC("DefaultDialogConfig");let ce=(()=>{class ke{_overlay=(0,a.WQX)(i.hJ);_injector=(0,a.WQX)(a.zZn);_defaultOptions=(0,a.WQX)(Oe,{optional:!0});_parentDialog=(0,a.WQX)(ke,{optional:!0,skipSelf:!0});_overlayContainer=(0,a.WQX)(i.Sf);_idGenerator=(0,a.WQX)(c.g7);_openDialogsAtThisLevel=[];_afterAllClosedAtThisLevel=new S.B;_afterOpenedAtThisLevel=new S.B;_ariaHiddenElements=new Map;_scrollStrategy=(0,a.WQX)(me);get openDialogs(){return this._parentDialog?this._parentDialog.openDialogs:this._openDialogsAtThisLevel}get afterOpened(){return this._parentDialog?this._parentDialog.afterOpened:this._afterOpenedAtThisLevel}afterAllClosed=(0,M.v)(()=>this.openDialogs.length?this._getAfterAllClosed():this._getAfterAllClosed().pipe((0,Z.Z)(void 0)));constructor(){}open(z,N){(N={...this._defaultOptions||new re,...N}).id=N.id||this._idGenerator.getId("cdk-dialog-"),N.id&&this.getDialogById(N.id);const Le=this._getOverlayConfig(N),ft=this._overlay.create(Le),mt=new ae(ft,N),St=this._attachContainer(ft,mt,N);return mt.containerInstance=St,this._attachDialogContent(z,mt,St,N),this.openDialogs.length||this._hideNonDialogContentFromAssistiveTechnology(),this.openDialogs.push(mt),mt.closed.subscribe(()=>this._removeOpenDialog(mt,!0)),this.afterOpened.next(mt),mt}closeAll(){ue(this.openDialogs,z=>z.close())}getDialogById(z){return this.openDialogs.find(N=>N.id===z)}ngOnDestroy(){ue(this._openDialogsAtThisLevel,z=>{!1===z.config.closeOnDestroy&&this._removeOpenDialog(z,!1)}),ue(this._openDialogsAtThisLevel,z=>z.close()),this._afterAllClosedAtThisLevel.complete(),this._afterOpenedAtThisLevel.complete(),this._openDialogsAtThisLevel=[]}_getOverlayConfig(z){const N=new i.rR({positionStrategy:z.positionStrategy||this._overlay.position().global().centerHorizontally().centerVertically(),scrollStrategy:z.scrollStrategy||this._scrollStrategy(),panelClass:z.panelClass,hasBackdrop:z.hasBackdrop,direction:z.direction,minWidth:z.minWidth,minHeight:z.minHeight,maxWidth:z.maxWidth,maxHeight:z.maxHeight,width:z.width,height:z.height,disposeOnNavigation:z.closeOnNavigation});return z.backdropClass&&(N.backdropClass=z.backdropClass),N}_attachContainer(z,N,W){const Le=W.injector||W.viewContainerRef?.injector,ft=[{provide:re,useValue:W},{provide:ae,useValue:N},{provide:i.yY,useValue:z}];let mt;W.container?"function"==typeof W.container?mt=W.container:(mt=W.container.type,ft.push(...W.container.providers(W))):mt=se;const St=new w.A8(mt,W.viewContainerRef,a.zZn.create({parent:Le||this._injector,providers:ft}));return z.attach(St).instance}_attachDialogContent(z,N,W,Le){if(z instanceof a.C4Q){const ft=this._createInjector(Le,N,W,void 0);let mt={$implicit:Le.data,dialogRef:N};Le.templateContext&&(mt={...mt,..."function"==typeof Le.templateContext?Le.templateContext():Le.templateContext}),W.attachTemplatePortal(new w.VA(z,null,mt,ft))}else{const ft=this._createInjector(Le,N,W,this._injector),mt=W.attachComponentPortal(new w.A8(z,Le.viewContainerRef,ft));N.componentRef=mt,N.componentInstance=mt.instance}}_createInjector(z,N,W,Le){const ft=z.injector||z.viewContainerRef?.injector,mt=[{provide:be,useValue:z.data},{provide:ae,useValue:N}];return z.providers&&("function"==typeof z.providers?mt.push(...z.providers(N,z,W)):mt.push(...z.providers)),z.direction&&(!ft||!ft.get(L.dS,null,{optional:!0}))&&mt.push({provide:L.dS,useValue:{value:z.direction,change:(0,O.of)()}}),a.zZn.create({parent:ft||Le,providers:mt})}_removeOpenDialog(z,N){const W=this.openDialogs.indexOf(z);W>-1&&(this.openDialogs.splice(W,1),this.openDialogs.length||(this._ariaHiddenElements.forEach((Le,ft)=>{Le?ft.setAttribute("aria-hidden",Le):ft.removeAttribute("aria-hidden")}),this._ariaHiddenElements.clear(),N&&this._getAfterAllClosed().next()))}_hideNonDialogContentFromAssistiveTechnology(){const z=this._overlayContainer.getContainerElement();if(z.parentElement){const N=z.parentElement.children;for(let W=N.length-1;W>-1;W--){const Le=N[W];Le!==z&&"SCRIPT"!==Le.nodeName&&"STYLE"!==Le.nodeName&&!Le.hasAttribute("aria-live")&&(this._ariaHiddenElements.set(Le,Le.getAttribute("aria-hidden")),Le.setAttribute("aria-hidden","true"))}}}_getAfterAllClosed(){const z=this._parentDialog;return z?z._getAfterAllClosed():this._afterAllClosedAtThisLevel}static \u0275fac=function(N){return new(N||ke)};static \u0275prov=a.jDH({token:ke,factory:ke.\u0275fac,providedIn:"root"})}return ke})();function ue(ke,Je){let z=ke.length;for(;z--;)Je(ke[z])}let Ce=(()=>{class ke{static \u0275fac=function(N){return new(N||ke)};static \u0275mod=a.$C({type:ke});static \u0275inj=a.G2t({providers:[ce],imports:[i.z_,w.jc,c.Pd,w.jc]})}return ke})();var Be=r(3022),at=r(7509),dt=r(1483),bt=r(7610),lt=r(8108),rn=r(2902);function bn(ke,Je){}r(1204);class Vn{viewContainerRef;injector;id;role="dialog";panelClass="";hasBackdrop=!0;backdropClass="";disableClose=!1;width="";height="";minWidth;minHeight;maxWidth;maxHeight;position;data=null;direction;ariaDescribedBy=null;ariaLabelledBy=null;ariaLabel=null;ariaModal=!0;autoFocus="first-tabbable";restoreFocus=!0;delayFocusTrap=!0;scrollStrategy;closeOnNavigation=!0;componentFactoryResolver;enterAnimationDuration;exitAnimationDuration}const yn="mdc-dialog--open",qe="mdc-dialog--opening",_t="mdc-dialog--closing";let Ft=(()=>{class ke extends se{_animationMode=(0,a.WQX)(a.bc$,{optional:!0});_animationStateChanged=new a.bkB;_animationsEnabled="NoopAnimations"!==this._animationMode;_actionSectionCount=0;_hostElement=this._elementRef.nativeElement;_enterAnimationDuration=this._animationsEnabled?Ze(this._config.enterAnimationDuration)??150:0;_exitAnimationDuration=this._animationsEnabled?Ze(this._config.exitAnimationDuration)??75:0;_animationTimer=null;_contentAttached(){super._contentAttached(),this._startOpenAnimation()}_startOpenAnimation(){this._animationStateChanged.emit({state:"opening",totalTime:this._enterAnimationDuration}),this._animationsEnabled?(this._hostElement.style.setProperty(Ke,`${this._enterAnimationDuration}ms`),this._requestAnimationFrame(()=>this._hostElement.classList.add(qe,yn)),this._waitForAnimationToComplete(this._enterAnimationDuration,this._finishDialogOpen)):(this._hostElement.classList.add(yn),Promise.resolve().then(()=>this._finishDialogOpen()))}_startExitAnimation(){this._animationStateChanged.emit({state:"closing",totalTime:this._exitAnimationDuration}),this._hostElement.classList.remove(yn),this._animationsEnabled?(this._hostElement.style.setProperty(Ke,`${this._exitAnimationDuration}ms`),this._requestAnimationFrame(()=>this._hostElement.classList.add(_t)),this._waitForAnimationToComplete(this._exitAnimationDuration,this._finishDialogClose)):Promise.resolve().then(()=>this._finishDialogClose())}_updateActionSectionCount(z){this._actionSectionCount+=z,this._changeDetectorRef.markForCheck()}_finishDialogOpen=()=>{this._clearAnimationClasses(),this._openAnimationDone(this._enterAnimationDuration)};_finishDialogClose=()=>{this._clearAnimationClasses(),this._animationStateChanged.emit({state:"closed",totalTime:this._exitAnimationDuration})};_clearAnimationClasses(){this._hostElement.classList.remove(qe,_t)}_waitForAnimationToComplete(z,N){null!==this._animationTimer&&clearTimeout(this._animationTimer),this._animationTimer=setTimeout(N,z)}_requestAnimationFrame(z){this._ngZone.runOutsideAngular(()=>{"function"==typeof requestAnimationFrame?requestAnimationFrame(z):z()})}_captureInitialFocus(){this._config.delayFocusTrap||this._trapFocus()}_openAnimationDone(z){this._config.delayFocusTrap&&this._trapFocus(),this._animationStateChanged.next({state:"opened",totalTime:z})}ngOnDestroy(){super.ngOnDestroy(),null!==this._animationTimer&&clearTimeout(this._animationTimer)}attachComponentPortal(z){const N=super.attachComponentPortal(z);return N.location.nativeElement.classList.add("mat-mdc-dialog-component-host"),N}static \u0275fac=(()=>{let z;return function(W){return(z||(z=a.xGo(ke)))(W||ke)}})();static \u0275cmp=a.VBU({type:ke,selectors:[["mat-dialog-container"]],hostAttrs:["tabindex","-1",1,"mat-mdc-dialog-container","mdc-dialog"],hostVars:10,hostBindings:function(N,W){2&N&&(a.Mr5("id",W._config.id),a.BMQ("aria-modal",W._config.ariaModal)("role",W._config.role)("aria-labelledby",W._config.ariaLabel?null:W._ariaLabelledByQueue[0])("aria-label",W._config.ariaLabel)("aria-describedby",W._config.ariaDescribedBy||null),a.AVh("_mat-animation-noopable",!W._animationsEnabled)("mat-mdc-dialog-container-with-actions",W._actionSectionCount>0))},features:[a.Vt3],decls:3,vars:0,consts:[[1,"mat-mdc-dialog-inner-container","mdc-dialog__container"],[1,"mat-mdc-dialog-surface","mdc-dialog__surface"],["cdkPortalOutlet",""]],template:function(N,W){1&N&&(a.j41(0,"div",0)(1,"div",1),a.DNE(2,bn,0,0,"ng-template",2),a.k0s()())},dependencies:[w.I3],styles:['.mat-mdc-dialog-container{width:100%;height:100%;display:block;box-sizing:border-box;max-height:inherit;min-height:inherit;min-width:inherit;max-width:inherit;outline:0}.cdk-overlay-pane.mat-mdc-dialog-panel{max-width:var(--mat-dialog-container-max-width, 560px);min-width:var(--mat-dialog-container-min-width, 280px)}@media(max-width: 599px){.cdk-overlay-pane.mat-mdc-dialog-panel{max-width:var(--mat-dialog-container-small-max-width, calc(100vw - 32px))}}.mat-mdc-dialog-inner-container{display:flex;flex-direction:row;align-items:center;justify-content:space-around;box-sizing:border-box;height:100%;opacity:0;transition:opacity linear var(--mat-dialog-transition-duration, 0ms);max-height:inherit;min-height:inherit;min-width:inherit;max-width:inherit}.mdc-dialog--closing .mat-mdc-dialog-inner-container{transition:opacity 75ms linear;transform:none}.mdc-dialog--open .mat-mdc-dialog-inner-container{opacity:1}._mat-animation-noopable .mat-mdc-dialog-inner-container{transition:none}.mat-mdc-dialog-surface{display:flex;flex-direction:column;flex-grow:0;flex-shrink:0;box-sizing:border-box;width:100%;height:100%;position:relative;overflow-y:auto;outline:0;transform:scale(0.8);transition:transform var(--mat-dialog-transition-duration, 0ms) cubic-bezier(0, 0, 0.2, 1);max-height:inherit;min-height:inherit;min-width:inherit;max-width:inherit;box-shadow:var(--mat-dialog-container-elevation-shadow, none);border-radius:var(--mdc-dialog-container-shape, var(--mat-sys-corner-extra-large, 4px));background-color:var(--mdc-dialog-container-color, var(--mat-sys-surface, white))}[dir=rtl] .mat-mdc-dialog-surface{text-align:right}.mdc-dialog--open .mat-mdc-dialog-surface,.mdc-dialog--closing .mat-mdc-dialog-surface{transform:none}._mat-animation-noopable .mat-mdc-dialog-surface{transition:none}.mat-mdc-dialog-surface::before{position:absolute;box-sizing:border-box;width:100%;height:100%;top:0;left:0;border:2px solid rgba(0,0,0,0);border-radius:inherit;content:"";pointer-events:none}.mat-mdc-dialog-title{display:block;position:relative;flex-shrink:0;box-sizing:border-box;margin:0 0 1px;padding:var(--mat-dialog-headline-padding, 6px 24px 13px)}.mat-mdc-dialog-title::before{display:inline-block;width:0;height:40px;content:"";vertical-align:0}[dir=rtl] .mat-mdc-dialog-title{text-align:right}.mat-mdc-dialog-container .mat-mdc-dialog-title{color:var(--mdc-dialog-subhead-color, var(--mat-sys-on-surface, rgba(0, 0, 0, 0.87)));font-family:var(--mdc-dialog-subhead-font, var(--mat-sys-headline-small-font, inherit));line-height:var(--mdc-dialog-subhead-line-height, var(--mat-sys-headline-small-line-height, 1.5rem));font-size:var(--mdc-dialog-subhead-size, var(--mat-sys-headline-small-size, 1rem));font-weight:var(--mdc-dialog-subhead-weight, var(--mat-sys-headline-small-weight, 400));letter-spacing:var(--mdc-dialog-subhead-tracking, var(--mat-sys-headline-small-tracking, 0.03125em))}.mat-mdc-dialog-content{display:block;flex-grow:1;box-sizing:border-box;margin:0;overflow:auto;max-height:65vh}.mat-mdc-dialog-content>:first-child{margin-top:0}.mat-mdc-dialog-content>:last-child{margin-bottom:0}.mat-mdc-dialog-container .mat-mdc-dialog-content{color:var(--mdc-dialog-supporting-text-color, var(--mat-sys-on-surface-variant, rgba(0, 0, 0, 0.6)));font-family:var(--mdc-dialog-supporting-text-font, var(--mat-sys-body-medium-font, inherit));line-height:var(--mdc-dialog-supporting-text-line-height, var(--mat-sys-body-medium-line-height, 1.5rem));font-size:var(--mdc-dialog-supporting-text-size, var(--mat-sys-body-medium-size, 1rem));font-weight:var(--mdc-dialog-supporting-text-weight, var(--mat-sys-body-medium-weight, 400));letter-spacing:var(--mdc-dialog-supporting-text-tracking, var(--mat-sys-body-medium-tracking, 0.03125em))}.mat-mdc-dialog-container .mat-mdc-dialog-content{padding:var(--mat-dialog-content-padding, 20px 24px)}.mat-mdc-dialog-container-with-actions .mat-mdc-dialog-content{padding:var(--mat-dialog-with-actions-content-padding, 20px 24px 0)}.mat-mdc-dialog-container .mat-mdc-dialog-title+.mat-mdc-dialog-content{padding-top:0}.mat-mdc-dialog-actions{display:flex;position:relative;flex-shrink:0;flex-wrap:wrap;align-items:center;justify-content:flex-end;box-sizing:border-box;min-height:52px;margin:0;padding:8px;border-top:1px solid rgba(0,0,0,0);padding:var(--mat-dialog-actions-padding, 16px 24px);justify-content:var(--mat-dialog-actions-alignment, flex-end)}@media(forced-colors: active){.mat-mdc-dialog-actions{border-top-color:CanvasText}}.mat-mdc-dialog-actions.mat-mdc-dialog-actions-align-start,.mat-mdc-dialog-actions[align=start]{justify-content:start}.mat-mdc-dialog-actions.mat-mdc-dialog-actions-align-center,.mat-mdc-dialog-actions[align=center]{justify-content:center}.mat-mdc-dialog-actions.mat-mdc-dialog-actions-align-end,.mat-mdc-dialog-actions[align=end]{justify-content:flex-end}.mat-mdc-dialog-actions .mat-button-base+.mat-button-base,.mat-mdc-dialog-actions .mat-mdc-button-base+.mat-mdc-button-base{margin-left:8px}[dir=rtl] .mat-mdc-dialog-actions .mat-button-base+.mat-button-base,[dir=rtl] .mat-mdc-dialog-actions .mat-mdc-button-base+.mat-mdc-button-base{margin-left:0;margin-right:8px}.mat-mdc-dialog-component-host{display:contents}'],encapsulation:2})}return ke})();const Ke="--mat-dialog-transition-duration";function Ze(ke){return null==ke?null:"number"==typeof ke?ke:ke.endsWith("ms")?(0,Be.OE)(ke.substring(0,ke.length-2)):ke.endsWith("s")?1e3*(0,Be.OE)(ke.substring(0,ke.length-1)):"0"===ke?0:null}var it=function(ke){return ke[ke.OPEN=0]="OPEN",ke[ke.CLOSING=1]="CLOSING",ke[ke.CLOSED=2]="CLOSED",ke}(it||{});class Ot{_ref;_containerInstance;componentInstance;componentRef;disableClose;id;_afterOpened=new S.B;_beforeClosed=new S.B;_result;_closeFallbackTimeout;_state=it.OPEN;_closeInteractionType;constructor(Je,z,N){this._ref=Je,this._containerInstance=N,this.disableClose=z.disableClose,this.id=Je.id,Je.addPanelClass("mat-mdc-dialog-panel"),N._animationStateChanged.pipe((0,dt.p)(W=>"opened"===W.state),(0,bt.s)(1)).subscribe(()=>{this._afterOpened.next(),this._afterOpened.complete()}),N._animationStateChanged.pipe((0,dt.p)(W=>"closed"===W.state),(0,bt.s)(1)).subscribe(()=>{clearTimeout(this._closeFallbackTimeout),this._finishDialogClose()}),Je.overlayRef.detachments().subscribe(()=>{this._beforeClosed.next(this._result),this._beforeClosed.complete(),this._finishDialogClose()}),(0,at.h)(this.backdropClick(),this.keydownEvents().pipe((0,dt.p)(W=>W.keyCode===T._f&&!this.disableClose&&!(0,T.rp)(W)))).subscribe(W=>{this.disableClose||(W.preventDefault(),$t(this,"keydown"===W.type?"keyboard":"mouse"))})}close(Je){this._result=Je,this._containerInstance._animationStateChanged.pipe((0,dt.p)(z=>"closing"===z.state),(0,bt.s)(1)).subscribe(z=>{this._beforeClosed.next(Je),this._beforeClosed.complete(),this._ref.overlayRef.detachBackdrop(),this._closeFallbackTimeout=setTimeout(()=>this._finishDialogClose(),z.totalTime+100)}),this._state=it.CLOSING,this._containerInstance._startExitAnimation()}afterOpened(){return this._afterOpened}afterClosed(){return this._ref.closed}beforeClosed(){return this._beforeClosed}backdropClick(){return this._ref.backdropClick}keydownEvents(){return this._ref.keydownEvents}updatePosition(Je){let z=this._ref.config.positionStrategy;return Je&&(Je.left||Je.right)?Je.left?z.left(Je.left):z.right(Je.right):z.centerHorizontally(),Je&&(Je.top||Je.bottom)?Je.top?z.top(Je.top):z.bottom(Je.bottom):z.centerVertically(),this._ref.updatePosition(),this}updateSize(Je="",z=""){return this._ref.updateSize(Je,z),this}addPanelClass(Je){return this._ref.addPanelClass(Je),this}removePanelClass(Je){return this._ref.removePanelClass(Je),this}getState(){return this._state}_finishDialogClose(){this._state=it.CLOSED,this._ref.close(this._result,{focusOrigin:this._closeInteractionType}),this.componentInstance=null}}function $t(ke,Je,z){return ke._closeInteractionType=Je,ke.close(z)}const Te=new a.nKC("MatMdcDialogData"),Ee=new a.nKC("mat-mdc-dialog-default-options"),st=new a.nKC("mat-mdc-dialog-scroll-strategy",{providedIn:"root",factory:()=>{const ke=(0,a.WQX)(i.hJ);return()=>ke.scrollStrategies.block()}});let Kt=(()=>{class ke{_overlay=(0,a.WQX)(i.hJ);_defaultOptions=(0,a.WQX)(Ee,{optional:!0});_scrollStrategy=(0,a.WQX)(st);_parentDialog=(0,a.WQX)(ke,{optional:!0,skipSelf:!0});_idGenerator=(0,a.WQX)(c.g7);_dialog=(0,a.WQX)(ce);_openDialogsAtThisLevel=[];_afterAllClosedAtThisLevel=new S.B;_afterOpenedAtThisLevel=new S.B;dialogConfigClass=Vn;_dialogRefConstructor;_dialogContainerType;_dialogDataToken;get openDialogs(){return this._parentDialog?this._parentDialog.openDialogs:this._openDialogsAtThisLevel}get afterOpened(){return this._parentDialog?this._parentDialog.afterOpened:this._afterOpenedAtThisLevel}_getAfterAllClosed(){const z=this._parentDialog;return z?z._getAfterAllClosed():this._afterAllClosedAtThisLevel}afterAllClosed=(0,M.v)(()=>this.openDialogs.length?this._getAfterAllClosed():this._getAfterAllClosed().pipe((0,Z.Z)(void 0)));constructor(){this._dialogRefConstructor=Ot,this._dialogContainerType=Ft,this._dialogDataToken=Te}open(z,N){let W;(N={...this._defaultOptions||new Vn,...N}).id=N.id||this._idGenerator.getId("mat-mdc-dialog-"),N.scrollStrategy=N.scrollStrategy||this._scrollStrategy();const Le=this._dialog.open(z,{...N,positionStrategy:this._overlay.position().global().centerHorizontally().centerVertically(),disableClose:!0,closeOnDestroy:!1,closeOnOverlayDetachments:!1,container:{type:this._dialogContainerType,providers:()=>[{provide:this.dialogConfigClass,useValue:N},{provide:re,useValue:N}]},templateContext:()=>({dialogRef:W}),providers:(ft,mt,St)=>(W=new this._dialogRefConstructor(ft,N,St),W.updatePosition(N?.position),[{provide:this._dialogContainerType,useValue:St},{provide:this._dialogDataToken,useValue:mt.data},{provide:this._dialogRefConstructor,useValue:W}])});return W.componentRef=Le.componentRef,W.componentInstance=Le.componentInstance,this.openDialogs.push(W),this.afterOpened.next(W),W.afterClosed().subscribe(()=>{const ft=this.openDialogs.indexOf(W);ft>-1&&(this.openDialogs.splice(ft,1),this.openDialogs.length||this._getAfterAllClosed().next())}),W}closeAll(){this._closeDialogs(this.openDialogs)}getDialogById(z){return this.openDialogs.find(N=>N.id===z)}ngOnDestroy(){this._closeDialogs(this._openDialogsAtThisLevel),this._afterAllClosedAtThisLevel.complete(),this._afterOpenedAtThisLevel.complete()}_closeDialogs(z){let N=z.length;for(;N--;)z[N].close()}static \u0275fac=function(N){return new(N||ke)};static \u0275prov=a.jDH({token:ke,factory:ke.\u0275fac,providedIn:"root"})}return ke})(),rt=(()=>{class ke{dialogRef=(0,a.WQX)(Ot,{optional:!0});_elementRef=(0,a.WQX)(a.aKT);_dialog=(0,a.WQX)(Kt);ariaLabel;type="button";dialogResult;_matDialogClose;constructor(){}ngOnInit(){this.dialogRef||(this.dialogRef=Nr(this._elementRef,this._dialog.openDialogs))}ngOnChanges(z){const N=z._matDialogClose||z._matDialogCloseResult;N&&(this.dialogResult=N.currentValue)}_onButtonClick(z){$t(this.dialogRef,0===z.screenX&&0===z.screenY?"keyboard":"mouse",this.dialogResult)}static \u0275fac=function(N){return new(N||ke)};static \u0275dir=a.FsC({type:ke,selectors:[["","mat-dialog-close",""],["","matDialogClose",""]],hostVars:2,hostBindings:function(N,W){1&N&&a.bIt("click",function(ft){return W._onButtonClick(ft)}),2&N&&a.BMQ("aria-label",W.ariaLabel||null)("type",W.type)},inputs:{ariaLabel:[0,"aria-label","ariaLabel"],type:"type",dialogResult:[0,"mat-dialog-close","dialogResult"],_matDialogClose:[0,"matDialogClose","_matDialogClose"]},exportAs:["matDialogClose"],features:[a.OA$]})}return ke})(),Vt=(()=>{class ke{_dialogRef=(0,a.WQX)(Ot,{optional:!0});_elementRef=(0,a.WQX)(a.aKT);_dialog=(0,a.WQX)(Kt);constructor(){}ngOnInit(){this._dialogRef||(this._dialogRef=Nr(this._elementRef,this._dialog.openDialogs)),this._dialogRef&&Promise.resolve().then(()=>{this._onAdd()})}ngOnDestroy(){this._dialogRef?._containerInstance&&Promise.resolve().then(()=>{this._onRemove()})}static \u0275fac=function(N){return new(N||ke)};static \u0275dir=a.FsC({type:ke})}return ke})(),kn=(()=>{class ke{static \u0275fac=function(N){return new(N||ke)};static \u0275dir=a.FsC({type:ke,selectors:[["","mat-dialog-content",""],["mat-dialog-content"],["","matDialogContent",""]],hostAttrs:[1,"mat-mdc-dialog-content","mdc-dialog__content"],features:[a.nM4([lt.uv])]})}return ke})(),Kn=(()=>{class ke extends Vt{align;_onAdd(){this._dialogRef._containerInstance?._updateActionSectionCount?.(1)}_onRemove(){this._dialogRef._containerInstance?._updateActionSectionCount?.(-1)}static \u0275fac=(()=>{let z;return function(W){return(z||(z=a.xGo(ke)))(W||ke)}})();static \u0275dir=a.FsC({type:ke,selectors:[["","mat-dialog-actions",""],["mat-dialog-actions"],["","matDialogActions",""]],hostAttrs:[1,"mat-mdc-dialog-actions","mdc-dialog__actions"],hostVars:6,hostBindings:function(N,W){2&N&&a.AVh("mat-mdc-dialog-actions-align-start","start"===W.align)("mat-mdc-dialog-actions-align-center","center"===W.align)("mat-mdc-dialog-actions-align-end","end"===W.align)},inputs:{align:"align"},features:[a.Vt3]})}return ke})();function Nr(ke,Je){let z=ke.nativeElement.parentElement;for(;z&&!z.classList.contains("mat-mdc-dialog-container");)z=z.parentElement;return z?Je.find(N=>N.id===z.id):null}let pr=(()=>{class ke{static \u0275fac=function(N){return new(N||ke)};static \u0275mod=a.$C({type:ke});static \u0275inj=a.G2t({providers:[Kt],imports:[Ce,i.z_,w.jc,rn.yE,rn.yE]})}return ke})()},7702:(o,s,r)=>{"use strict";r.d(s,{q:()=>y,w:()=>w});var i=r(3107),a=r(3022),c=r(2902);let y=(()=>{class C{get vertical(){return this._vertical}set vertical(S){this._vertical=(0,a.he)(S)}_vertical=!1;get inset(){return this._inset}set inset(S){this._inset=(0,a.he)(S)}_inset=!1;static \u0275fac=function(M){return new(M||C)};static \u0275cmp=i.VBU({type:C,selectors:[["mat-divider"]],hostAttrs:["role","separator",1,"mat-divider"],hostVars:7,hostBindings:function(M,O){2&M&&(i.BMQ("aria-orientation",O.vertical?"vertical":"horizontal"),i.AVh("mat-divider-vertical",O.vertical)("mat-divider-horizontal",!O.vertical)("mat-divider-inset",O.inset))},inputs:{vertical:"vertical",inset:"inset"},decls:0,vars:0,template:function(M,O){},styles:[".mat-divider{display:block;margin:0;border-top-style:solid;border-top-color:var(--mat-divider-color, var(--mat-sys-outline));border-top-width:var(--mat-divider-width, 1px)}.mat-divider.mat-divider-vertical{border-top:0;border-right-style:solid;border-right-color:var(--mat-divider-color, var(--mat-sys-outline));border-right-width:var(--mat-divider-width, 1px)}.mat-divider.mat-divider-inset{margin-left:80px}[dir=rtl] .mat-divider.mat-divider-inset{margin-left:auto;margin-right:80px}"],encapsulation:2,changeDetection:0})}return C})(),w=(()=>{class C{static \u0275fac=function(M){return new(M||C)};static \u0275mod=i.$C({type:C});static \u0275inj=i.G2t({imports:[c.yE,c.yE]})}return C})()},6071:(o,s,r)=>{"use strict";r.d(s,{xb:()=>an,U$:()=>dn,TL:()=>en,rl:()=>Tr,qT:()=>ft,RG:()=>Vr,MV:()=>kn,nJ:()=>rt,JW:()=>Nr,yw:()=>pr});var i=r(3107),a=r(8559),c=r(2944),y=r(3022),w=r(2147),C=r(4460),T=r(5710),S=r(8447),M=r(7509),O=r(593),L=r(7947),Z=r(5351),q=r(2483),pe=r(1483),se=r(5424),ae=r(1698),me=r(8249);class Oe{_box;_destroyed=new S.B;_resizeSubject=new S.B;_resizeObserver;_elementObservables=new Map;constructor(Wt){this._box=Wt,typeof ResizeObserver<"u"&&(this._resizeObserver=new ResizeObserver(Re=>this._resizeSubject.next(Re)))}observe(Wt){return this._elementObservables.has(Wt)||this._elementObservables.set(Wt,new ae.c(Re=>{const Ge=this._resizeSubject.subscribe(Re);return this._resizeObserver?.observe(Wt,{box:this._box}),()=>{this._resizeObserver?.unobserve(Wt),Ge.unsubscribe(),this._elementObservables.delete(Wt)}}).pipe((0,pe.p)(Re=>Re.some(Ge=>Ge.target===Wt)),(0,me.t)({bufferSize:1,refCount:!0}),(0,se.Q)(this._destroyed))),this._elementObservables.get(Wt)}destroy(){this._destroyed.next(),this._destroyed.complete(),this._resizeSubject.complete(),this._elementObservables.clear()}}let xe=(()=>{class vt{_observers=new Map;_ngZone=(0,i.WQX)(i.SKi);constructor(){}ngOnDestroy(){for(const[,Re]of this._observers)Re.destroy();this._observers.clear()}observe(Re,Ge){const Ve=Ge?.box||"content-box";return this._observers.has(Ve)||this._observers.set(Ve,new Oe(Ve)),this._observers.get(Ve).observe(Re)}static \u0275fac=function(Ge){return new(Ge||vt)};static \u0275prov=i.jDH({token:vt,factory:vt.\u0275fac,providedIn:"root"})}return vt})();var De=r(1204),ce=r(7747),ue=r(2902);const Ce=["notch"],Be=["matFormFieldNotchedOutline",""],at=["*"],dt=["textField"],bt=["iconPrefixContainer"],lt=["textPrefixContainer"],rn=["iconSuffixContainer"],gn=["textSuffixContainer"],bn=["*",[["mat-label"]],[["","matPrefix",""],["","matIconPrefix",""]],[["","matTextPrefix",""]],[["","matTextSuffix",""]],[["","matSuffix",""],["","matIconSuffix",""]],[["mat-error"],["","matError",""]],[["mat-hint",3,"align","end"]],[["mat-hint","align","end"]]],Vn=["*","mat-label","[matPrefix], [matIconPrefix]","[matTextPrefix]","[matTextSuffix]","[matSuffix], [matIconSuffix]","mat-error, [matError]","mat-hint:not([align='end'])","mat-hint[align='end']"];function yn(vt,Wt){1&vt&&i.nrm(0,"span",21)}function qe(vt,Wt){if(1&vt&&(i.j41(0,"label",20),i.SdG(1,1),i.DNE(2,yn,1,0,"span",21),i.k0s()),2&vt){const Re=i.XpG(2);i.Y8G("floating",Re._shouldLabelFloat())("monitorResize",Re._hasOutline())("id",Re._labelId),i.BMQ("for",Re._control.disableAutomaticLabeling?null:Re._control.id),i.R7$(2),i.vxM(!Re.hideRequiredMarker&&Re._control.required?2:-1)}}function _t(vt,Wt){if(1&vt&&i.DNE(0,qe,3,5,"label",20),2&vt){const Re=i.XpG();i.vxM(Re._hasFloatingLabel()?0:-1)}}function ze(vt,Wt){1&vt&&i.nrm(0,"div",7)}function $e(vt,Wt){}function Ft(vt,Wt){if(1&vt&&i.DNE(0,$e,0,0,"ng-template",13),2&vt){i.XpG(2);const Re=i.sdS(1);i.Y8G("ngTemplateOutlet",Re)}}function Ke(vt,Wt){if(1&vt&&(i.j41(0,"div",9),i.DNE(1,Ft,1,1,null,13),i.k0s()),2&vt){const Re=i.XpG();i.Y8G("matFormFieldNotchedOutlineOpen",Re._shouldLabelFloat()),i.R7$(),i.vxM(Re._forceDisplayInfixLabel()?-1:1)}}function Ze(vt,Wt){1&vt&&(i.j41(0,"div",10,2),i.SdG(2,2),i.k0s())}function it(vt,Wt){1&vt&&(i.j41(0,"div",11,3),i.SdG(2,3),i.k0s())}function Ot(vt,Wt){}function $t(vt,Wt){if(1&vt&&i.DNE(0,Ot,0,0,"ng-template",13),2&vt){i.XpG();const Re=i.sdS(1);i.Y8G("ngTemplateOutlet",Re)}}function Te(vt,Wt){1&vt&&(i.j41(0,"div",14,4),i.SdG(2,4),i.k0s())}function Ee(vt,Wt){1&vt&&(i.j41(0,"div",15,5),i.SdG(2,5),i.k0s())}function st(vt,Wt){1&vt&&i.nrm(0,"div",16)}function Xt(vt,Wt){if(1&vt&&(i.j41(0,"div",18),i.SdG(1,6),i.k0s()),2&vt){const Re=i.XpG();i.Y8G("@transitionMessages",Re._subscriptAnimationState)}}function Mt(vt,Wt){if(1&vt&&(i.j41(0,"mat-hint",22),i.EFF(1),i.k0s()),2&vt){const Re=i.XpG(2);i.Y8G("id",Re._hintLabelId),i.R7$(),i.JRh(Re.hintLabel)}}function Kt(vt,Wt){if(1&vt&&(i.j41(0,"div",19),i.DNE(1,Mt,2,2,"mat-hint",22),i.SdG(2,7),i.nrm(3,"div",23),i.SdG(4,8),i.k0s()),2&vt){const Re=i.XpG();i.Y8G("@transitionMessages",Re._subscriptAnimationState),i.R7$(),i.vxM(Re.hintLabel?1:-1)}}let rt=(()=>{class vt{static \u0275fac=function(Ge){return new(Ge||vt)};static \u0275dir=i.FsC({type:vt,selectors:[["mat-label"]]})}return vt})();const Vt=new i.nKC("MatError");let en=(()=>{class vt{id=(0,i.WQX)(a.g7).getId("mat-mdc-error-");constructor(){(0,i.WQX)(new i.ES_("aria-live"),{optional:!0})||(0,i.WQX)(i.aKT).nativeElement.setAttribute("aria-live","polite")}static \u0275fac=function(Ge){return new(Ge||vt)};static \u0275dir=i.FsC({type:vt,selectors:[["mat-error"],["","matError",""]],hostAttrs:["aria-atomic","true",1,"mat-mdc-form-field-error","mat-mdc-form-field-bottom-align"],hostVars:1,hostBindings:function(Ge,Ve){2&Ge&&i.Mr5("id",Ve.id)},inputs:{id:"id"},features:[i.Jv_([{provide:Vt,useExisting:vt}])]})}return vt})(),kn=(()=>{class vt{align="start";id=(0,i.WQX)(a.g7).getId("mat-mdc-hint-");static \u0275fac=function(Ge){return new(Ge||vt)};static \u0275dir=i.FsC({type:vt,selectors:[["mat-hint"]],hostAttrs:[1,"mat-mdc-form-field-hint","mat-mdc-form-field-bottom-align"],hostVars:4,hostBindings:function(Ge,Ve){2&Ge&&(i.Mr5("id",Ve.id),i.BMQ("align",null),i.AVh("mat-mdc-form-field-hint-end","end"===Ve.align))},inputs:{align:"align",id:"id"}})}return vt})();const Kn=new i.nKC("MatPrefix");let Nr=(()=>{class vt{set _isTextSelector(Re){this._isText=!0}_isText=!1;static \u0275fac=function(Ge){return new(Ge||vt)};static \u0275dir=i.FsC({type:vt,selectors:[["","matPrefix",""],["","matIconPrefix",""],["","matTextPrefix",""]],inputs:{_isTextSelector:[0,"matTextPrefix","_isTextSelector"]},features:[i.Jv_([{provide:Kn,useExisting:vt}])]})}return vt})();const Rn=new i.nKC("MatSuffix");let pr=(()=>{class vt{set _isTextSelector(Re){this._isText=!0}_isText=!1;static \u0275fac=function(Ge){return new(Ge||vt)};static \u0275dir=i.FsC({type:vt,selectors:[["","matSuffix",""],["","matIconSuffix",""],["","matTextSuffix",""]],inputs:{_isTextSelector:[0,"matTextSuffix","_isTextSelector"]},features:[i.Jv_([{provide:Rn,useExisting:vt}])]})}return vt})();const cn=new i.nKC("FloatingLabelParent");let Fe=(()=>{class vt{_elementRef=(0,i.WQX)(i.aKT);get floating(){return this._floating}set floating(Re){this._floating=Re,this.monitorResize&&this._handleResize()}_floating=!1;get monitorResize(){return this._monitorResize}set monitorResize(Re){this._monitorResize=Re,this._monitorResize?this._subscribeToResize():this._resizeSubscription.unsubscribe()}_monitorResize=!1;_resizeObserver=(0,i.WQX)(xe);_ngZone=(0,i.WQX)(i.SKi);_parent=(0,i.WQX)(cn);_resizeSubscription=new T.yU;constructor(){}ngOnDestroy(){this._resizeSubscription.unsubscribe()}getWidth(){return function ke(vt){if(null!==vt.offsetParent)return vt.scrollWidth;const Re=vt.cloneNode(!0);Re.style.setProperty("position","absolute"),Re.style.setProperty("transform","translate(-9999px, -9999px)"),document.documentElement.appendChild(Re);const Ge=Re.scrollWidth;return Re.remove(),Ge}(this._elementRef.nativeElement)}get element(){return this._elementRef.nativeElement}_handleResize(){setTimeout(()=>this._parent._handleLabelResized())}_subscribeToResize(){this._resizeSubscription.unsubscribe(),this._ngZone.runOutsideAngular(()=>{this._resizeSubscription=this._resizeObserver.observe(this._elementRef.nativeElement,{box:"border-box"}).subscribe(()=>this._handleResize())})}static \u0275fac=function(Ge){return new(Ge||vt)};static \u0275dir=i.FsC({type:vt,selectors:[["label","matFormFieldFloatingLabel",""]],hostAttrs:[1,"mdc-floating-label","mat-mdc-floating-label"],hostVars:2,hostBindings:function(Ge,Ve){2&Ge&&i.AVh("mdc-floating-label--float-above",Ve.floating)},inputs:{floating:"floating",monitorResize:"monitorResize"}})}return vt})();const Je="mdc-line-ripple--active",z="mdc-line-ripple--deactivating";let N=(()=>{class vt{_elementRef=(0,i.WQX)(i.aKT);constructor(){(0,i.WQX)(i.SKi).runOutsideAngular(()=>{this._elementRef.nativeElement.addEventListener("transitionend",this._handleTransitionEnd)})}activate(){const Re=this._elementRef.nativeElement.classList;Re.remove(z),Re.add(Je)}deactivate(){this._elementRef.nativeElement.classList.add(z)}_handleTransitionEnd=Re=>{const Ge=this._elementRef.nativeElement.classList,Ve=Ge.contains(z);"opacity"===Re.propertyName&&Ve&&Ge.remove(Je,z)};ngOnDestroy(){this._elementRef.nativeElement.removeEventListener("transitionend",this._handleTransitionEnd)}static \u0275fac=function(Ge){return new(Ge||vt)};static \u0275dir=i.FsC({type:vt,selectors:[["div","matFormFieldLineRipple",""]],hostAttrs:[1,"mdc-line-ripple"]})}return vt})(),W=(()=>{class vt{_elementRef=(0,i.WQX)(i.aKT);_ngZone=(0,i.WQX)(i.SKi);open=!1;_notch;constructor(){}ngAfterViewInit(){const Re=this._elementRef.nativeElement.querySelector(".mdc-floating-label");Re?(this._elementRef.nativeElement.classList.add("mdc-notched-outline--upgraded"),"function"==typeof requestAnimationFrame&&(Re.style.transitionDuration="0s",this._ngZone.runOutsideAngular(()=>{requestAnimationFrame(()=>Re.style.transitionDuration="")}))):this._elementRef.nativeElement.classList.add("mdc-notched-outline--no-label")}_setNotchWidth(Re){this._notch.nativeElement.style.width=this.open&&Re?`calc(${Re}px * var(--mat-mdc-form-field-floating-label-scale, 0.75) + 9px)`:""}static \u0275fac=function(Ge){return new(Ge||vt)};static \u0275cmp=i.VBU({type:vt,selectors:[["div","matFormFieldNotchedOutline",""]],viewQuery:function(Ge,Ve){if(1&Ge&&i.GBs(Ce,5),2&Ge){let Dt;i.mGM(Dt=i.lsd())&&(Ve._notch=Dt.first)}},hostAttrs:[1,"mdc-notched-outline"],hostVars:2,hostBindings:function(Ge,Ve){2&Ge&&i.AVh("mdc-notched-outline--notched",Ve.open)},inputs:{open:[0,"matFormFieldNotchedOutlineOpen","open"]},attrs:Be,ngContentSelectors:at,decls:5,vars:0,consts:[["notch",""],[1,"mat-mdc-notch-piece","mdc-notched-outline__leading"],[1,"mat-mdc-notch-piece","mdc-notched-outline__notch"],[1,"mat-mdc-notch-piece","mdc-notched-outline__trailing"]],template:function(Ge,Ve){1&Ge&&(i.NAR(),i.nrm(0,"div",1),i.j41(1,"div",2,0),i.SdG(3),i.k0s(),i.nrm(4,"div",3))},encapsulation:2,changeDetection:0})}return vt})();const Le={transitionMessages:(0,De.hZ)("transitionMessages",[(0,De.wk)("enter",(0,De.iF)({opacity:1,transform:"translateY(0%)"})),(0,De.kY)("void => enter",[(0,De.iF)({opacity:0,transform:"translateY(-5px)"}),(0,De.i0)("300ms cubic-bezier(0.55, 0, 0.55, 0.2)")])])};let ft=(()=>{class vt{value;stateChanges;id;placeholder;ngControl;focused;empty;shouldLabelFloat;required;disabled;errorState;controlType;autofilled;userAriaDescribedBy;disableAutomaticLabeling;static \u0275fac=function(Ge){return new(Ge||vt)};static \u0275dir=i.FsC({type:vt})}return vt})();const an=new i.nKC("MatFormField"),dn=new i.nKC("MAT_FORM_FIELD_DEFAULT_OPTIONS");let Tr=(()=>{class vt{_elementRef=(0,i.WQX)(i.aKT);_changeDetectorRef=(0,i.WQX)(i.gRc);_dir=(0,i.WQX)(c.dS);_platform=(0,i.WQX)(w.OD);_idGenerator=(0,i.WQX)(a.g7);_defaults=(0,i.WQX)(dn,{optional:!0});_animationMode=(0,i.WQX)(i.bc$,{optional:!0});_textField;_iconPrefixContainer;_textPrefixContainer;_iconSuffixContainer;_textSuffixContainer;_floatingLabel;_notchedOutline;_lineRipple;_formFieldControl;_prefixChildren;_suffixChildren;_errorChildren;_hintChildren;_labelChild=(0,i.sbv)(rt);get hideRequiredMarker(){return this._hideRequiredMarker}set hideRequiredMarker(Re){this._hideRequiredMarker=(0,y.he)(Re)}_hideRequiredMarker=!1;color="primary";get floatLabel(){return this._floatLabel||this._defaults?.floatLabel||"auto"}set floatLabel(Re){Re!==this._floatLabel&&(this._floatLabel=Re,this._changeDetectorRef.markForCheck())}_floatLabel;get appearance(){return this._appearance}set appearance(Re){const Ge=this._appearance;this._appearance=Re||this._defaults?.appearance||"fill","outline"===this._appearance&&this._appearance!==Ge&&(this._needsOutlineLabelOffsetUpdate=!0)}_appearance="fill";get subscriptSizing(){return this._subscriptSizing||this._defaults?.subscriptSizing||"fixed"}set subscriptSizing(Re){this._subscriptSizing=Re||this._defaults?.subscriptSizing||"fixed"}_subscriptSizing=null;get hintLabel(){return this._hintLabel}set hintLabel(Re){this._hintLabel=Re,this._processHints()}_hintLabel="";_hasIconPrefix=!1;_hasTextPrefix=!1;_hasIconSuffix=!1;_hasTextSuffix=!1;_labelId=this._idGenerator.getId("mat-mdc-form-field-label-");_hintLabelId=this._idGenerator.getId("mat-mdc-hint-");_subscriptAnimationState="";get _control(){return this._explicitFormFieldControl||this._formFieldControl}set _control(Re){this._explicitFormFieldControl=Re}_destroyed=new S.B;_isFocused=null;_explicitFormFieldControl;_needsOutlineLabelOffsetUpdate=!1;_previousControl=null;_stateChanges;_valueChanges;_describedByChanges;_injector=(0,i.WQX)(i.zZn);constructor(){const Re=this._defaults;Re&&(Re.appearance&&(this.appearance=Re.appearance),this._hideRequiredMarker=!!Re?.hideRequiredMarker,Re.color&&(this.color=Re.color))}ngAfterViewInit(){this._updateFocusState(),this._subscriptAnimationState="enter",this._changeDetectorRef.detectChanges()}ngAfterContentInit(){this._assertFormFieldControl(),this._initializeSubscript(),this._initializePrefixAndSuffix(),this._initializeOutlineLabelOffsetSubscriptions()}ngAfterContentChecked(){this._assertFormFieldControl(),this._control!==this._previousControl&&(this._initializeControl(this._previousControl),this._previousControl=this._control)}ngOnDestroy(){this._stateChanges?.unsubscribe(),this._valueChanges?.unsubscribe(),this._describedByChanges?.unsubscribe(),this._destroyed.next(),this._destroyed.complete()}getLabelId=(0,i.EWP)(()=>this._hasFloatingLabel()?this._labelId:null);getConnectedOverlayOrigin(){return this._textField||this._elementRef}_animateAndLockLabel(){this._hasFloatingLabel()&&(this.floatLabel="always")}_initializeControl(Re){const Ge=this._control,Ve="mat-mdc-form-field-type-";Re&&this._elementRef.nativeElement.classList.remove(Ve+Re.controlType),Ge.controlType&&this._elementRef.nativeElement.classList.add(Ve+Ge.controlType),this._stateChanges?.unsubscribe(),this._stateChanges=Ge.stateChanges.subscribe(()=>{this._updateFocusState(),this._changeDetectorRef.markForCheck()}),this._describedByChanges?.unsubscribe(),this._describedByChanges=Ge.stateChanges.pipe((0,O.Z)([void 0,void 0]),(0,L.T)(()=>[Ge.errorState,Ge.userAriaDescribedBy]),function re(){return(0,Z.N)((vt,Wt)=>{let Re,Ge=!1;vt.subscribe((0,q._)(Wt,Ve=>{const Dt=Re;Re=Ve,Ge&&Wt.next([Dt,Ve]),Ge=!0}))})}(),(0,pe.p)(([[Dt,ct],[Bt,wn]])=>Dt!==Bt||ct!==wn)).subscribe(()=>this._syncDescribedByIds()),this._valueChanges?.unsubscribe(),Ge.ngControl&&Ge.ngControl.valueChanges&&(this._valueChanges=Ge.ngControl.valueChanges.pipe((0,se.Q)(this._destroyed)).subscribe(()=>this._changeDetectorRef.markForCheck()))}_checkPrefixAndSuffixTypes(){this._hasIconPrefix=!!this._prefixChildren.find(Re=>!Re._isText),this._hasTextPrefix=!!this._prefixChildren.find(Re=>Re._isText),this._hasIconSuffix=!!this._suffixChildren.find(Re=>!Re._isText),this._hasTextSuffix=!!this._suffixChildren.find(Re=>Re._isText)}_initializePrefixAndSuffix(){this._checkPrefixAndSuffixTypes(),(0,M.h)(this._prefixChildren.changes,this._suffixChildren.changes).subscribe(()=>{this._checkPrefixAndSuffixTypes(),this._changeDetectorRef.markForCheck()})}_initializeSubscript(){this._hintChildren.changes.subscribe(()=>{this._processHints(),this._changeDetectorRef.markForCheck()}),this._errorChildren.changes.subscribe(()=>{this._syncDescribedByIds(),this._changeDetectorRef.markForCheck()}),this._validateHints(),this._syncDescribedByIds()}_assertFormFieldControl(){}_updateFocusState(){this._control.focused&&!this._isFocused?(this._isFocused=!0,this._lineRipple?.activate()):!this._control.focused&&(this._isFocused||null===this._isFocused)&&(this._isFocused=!1,this._lineRipple?.deactivate()),this._textField?.nativeElement.classList.toggle("mdc-text-field--focused",this._control.focused)}_initializeOutlineLabelOffsetSubscriptions(){this._prefixChildren.changes.subscribe(()=>this._needsOutlineLabelOffsetUpdate=!0),(0,i.Tzd)(()=>{this._needsOutlineLabelOffsetUpdate&&(this._needsOutlineLabelOffsetUpdate=!1,this._updateOutlineLabelOffset())},{injector:this._injector}),this._dir.change.pipe((0,se.Q)(this._destroyed)).subscribe(()=>this._needsOutlineLabelOffsetUpdate=!0)}_shouldAlwaysFloat(){return"always"===this.floatLabel}_hasOutline(){return"outline"===this.appearance}_forceDisplayInfixLabel(){return!this._platform.isBrowser&&this._prefixChildren.length&&!this._shouldLabelFloat()}_hasFloatingLabel=(0,i.EWP)(()=>!!this._labelChild());_shouldLabelFloat(){return!!this._hasFloatingLabel()&&(this._control.shouldLabelFloat||this._shouldAlwaysFloat())}_shouldForward(Re){const Ge=this._control?this._control.ngControl:null;return Ge&&Ge[Re]}_getDisplayedMessages(){return this._errorChildren&&this._errorChildren.length>0&&this._control.errorState?"error":"hint"}_handleLabelResized(){this._refreshOutlineNotchWidth()}_refreshOutlineNotchWidth(){this._hasOutline()&&this._floatingLabel&&this._shouldLabelFloat()?this._notchedOutline?._setNotchWidth(this._floatingLabel.getWidth()):this._notchedOutline?._setNotchWidth(0)}_processHints(){this._validateHints(),this._syncDescribedByIds()}_validateHints(){}_syncDescribedByIds(){if(this._control){let Re=[];if(this._control.userAriaDescribedBy&&"string"==typeof this._control.userAriaDescribedBy&&Re.push(...this._control.userAriaDescribedBy.split(" ")),"hint"===this._getDisplayedMessages()){const Ge=this._hintChildren?this._hintChildren.find(Dt=>"start"===Dt.align):null,Ve=this._hintChildren?this._hintChildren.find(Dt=>"end"===Dt.align):null;Ge?Re.push(Ge.id):this._hintLabel&&Re.push(this._hintLabelId),Ve&&Re.push(Ve.id)}else this._errorChildren&&Re.push(...this._errorChildren.map(Ge=>Ge.id));this._control.setDescribedByIds(Re)}}_updateOutlineLabelOffset(){if(!this._hasOutline()||!this._floatingLabel)return;const Re=this._floatingLabel.element;if(!this._iconPrefixContainer&&!this._textPrefixContainer)return void(Re.style.transform="");if(!this._isAttachedToDom())return void(this._needsOutlineLabelOffsetUpdate=!0);const Ge=this._iconPrefixContainer?.nativeElement,Ve=this._textPrefixContainer?.nativeElement,Dt=this._iconSuffixContainer?.nativeElement,ct=this._textSuffixContainer?.nativeElement,Bt=Ge?.getBoundingClientRect().width??0,wn=Ve?.getBoundingClientRect().width??0,qn=Dt?.getBoundingClientRect().width??0,Er=ct?.getBoundingClientRect().width??0;Re.style.transform=`var(\n --mat-mdc-form-field-label-transform,\n translateY(-50%) translateX(calc(${"rtl"===this._dir.value?"-1":"1"} * (${Bt+wn}px + var(--mat-mdc-form-field-label-offset-x, 0px))))\n )`,this._elementRef.nativeElement.style.setProperty("--mat-form-field-notch-max-width",`calc(100% - ${Bt+wn+qn+Er}px)`)}_isAttachedToDom(){const Re=this._elementRef.nativeElement;if(Re.getRootNode){const Ge=Re.getRootNode();return Ge&&Ge!==Re}return document.documentElement.contains(Re)}static \u0275fac=function(Ge){return new(Ge||vt)};static \u0275cmp=i.VBU({type:vt,selectors:[["mat-form-field"]],contentQueries:function(Ge,Ve,Dt){if(1&Ge&&(i.C6U(Dt,Ve._labelChild,rt,5),i.wni(Dt,ft,5),i.wni(Dt,Kn,5),i.wni(Dt,Rn,5),i.wni(Dt,Vt,5),i.wni(Dt,kn,5)),2&Ge){let ct;i.NyB(),i.mGM(ct=i.lsd())&&(Ve._formFieldControl=ct.first),i.mGM(ct=i.lsd())&&(Ve._prefixChildren=ct),i.mGM(ct=i.lsd())&&(Ve._suffixChildren=ct),i.mGM(ct=i.lsd())&&(Ve._errorChildren=ct),i.mGM(ct=i.lsd())&&(Ve._hintChildren=ct)}},viewQuery:function(Ge,Ve){if(1&Ge&&(i.GBs(dt,5),i.GBs(bt,5),i.GBs(lt,5),i.GBs(rn,5),i.GBs(gn,5),i.GBs(Fe,5),i.GBs(W,5),i.GBs(N,5)),2&Ge){let Dt;i.mGM(Dt=i.lsd())&&(Ve._textField=Dt.first),i.mGM(Dt=i.lsd())&&(Ve._iconPrefixContainer=Dt.first),i.mGM(Dt=i.lsd())&&(Ve._textPrefixContainer=Dt.first),i.mGM(Dt=i.lsd())&&(Ve._iconSuffixContainer=Dt.first),i.mGM(Dt=i.lsd())&&(Ve._textSuffixContainer=Dt.first),i.mGM(Dt=i.lsd())&&(Ve._floatingLabel=Dt.first),i.mGM(Dt=i.lsd())&&(Ve._notchedOutline=Dt.first),i.mGM(Dt=i.lsd())&&(Ve._lineRipple=Dt.first)}},hostAttrs:[1,"mat-mdc-form-field"],hostVars:42,hostBindings:function(Ge,Ve){2&Ge&&i.AVh("mat-mdc-form-field-label-always-float",Ve._shouldAlwaysFloat())("mat-mdc-form-field-has-icon-prefix",Ve._hasIconPrefix)("mat-mdc-form-field-has-icon-suffix",Ve._hasIconSuffix)("mat-form-field-invalid",Ve._control.errorState)("mat-form-field-disabled",Ve._control.disabled)("mat-form-field-autofilled",Ve._control.autofilled)("mat-form-field-no-animations","NoopAnimations"===Ve._animationMode)("mat-form-field-appearance-fill","fill"==Ve.appearance)("mat-form-field-appearance-outline","outline"==Ve.appearance)("mat-form-field-hide-placeholder",Ve._hasFloatingLabel()&&!Ve._shouldLabelFloat())("mat-focused",Ve._control.focused)("mat-primary","accent"!==Ve.color&&"warn"!==Ve.color)("mat-accent","accent"===Ve.color)("mat-warn","warn"===Ve.color)("ng-untouched",Ve._shouldForward("untouched"))("ng-touched",Ve._shouldForward("touched"))("ng-pristine",Ve._shouldForward("pristine"))("ng-dirty",Ve._shouldForward("dirty"))("ng-valid",Ve._shouldForward("valid"))("ng-invalid",Ve._shouldForward("invalid"))("ng-pending",Ve._shouldForward("pending"))},inputs:{hideRequiredMarker:"hideRequiredMarker",color:"color",floatLabel:"floatLabel",appearance:"appearance",subscriptSizing:"subscriptSizing",hintLabel:"hintLabel"},exportAs:["matFormField"],features:[i.Jv_([{provide:an,useExisting:vt},{provide:cn,useExisting:vt}])],ngContentSelectors:Vn,decls:18,vars:21,consts:[["labelTemplate",""],["textField",""],["iconPrefixContainer",""],["textPrefixContainer",""],["textSuffixContainer",""],["iconSuffixContainer",""],[1,"mat-mdc-text-field-wrapper","mdc-text-field",3,"click"],[1,"mat-mdc-form-field-focus-overlay"],[1,"mat-mdc-form-field-flex"],["matFormFieldNotchedOutline","",3,"matFormFieldNotchedOutlineOpen"],[1,"mat-mdc-form-field-icon-prefix"],[1,"mat-mdc-form-field-text-prefix"],[1,"mat-mdc-form-field-infix"],[3,"ngTemplateOutlet"],[1,"mat-mdc-form-field-text-suffix"],[1,"mat-mdc-form-field-icon-suffix"],["matFormFieldLineRipple",""],[1,"mat-mdc-form-field-subscript-wrapper","mat-mdc-form-field-bottom-align"],[1,"mat-mdc-form-field-error-wrapper"],[1,"mat-mdc-form-field-hint-wrapper"],["matFormFieldFloatingLabel","",3,"floating","monitorResize","id"],["aria-hidden","true",1,"mat-mdc-form-field-required-marker","mdc-floating-label--required"],[3,"id"],[1,"mat-mdc-form-field-hint-spacer"]],template:function(Ge,Ve){if(1&Ge){const Dt=i.RV6();i.NAR(bn),i.DNE(0,_t,1,1,"ng-template",null,0,i.C5r),i.j41(2,"div",6,1),i.bIt("click",function(Bt){return i.eBV(Dt),i.Njj(Ve._control.onContainerClick(Bt))}),i.DNE(4,ze,1,0,"div",7),i.j41(5,"div",8),i.DNE(6,Ke,2,2,"div",9)(7,Ze,3,0,"div",10)(8,it,3,0,"div",11),i.j41(9,"div",12),i.DNE(10,$t,1,1,null,13),i.SdG(11),i.k0s(),i.DNE(12,Te,3,0,"div",14)(13,Ee,3,0,"div",15),i.k0s(),i.DNE(14,st,1,0,"div",16),i.k0s(),i.j41(15,"div",17),i.DNE(16,Xt,2,1,"div",18)(17,Kt,5,2,"div",19),i.k0s()}if(2&Ge){let Dt;i.R7$(2),i.AVh("mdc-text-field--filled",!Ve._hasOutline())("mdc-text-field--outlined",Ve._hasOutline())("mdc-text-field--no-label",!Ve._hasFloatingLabel())("mdc-text-field--disabled",Ve._control.disabled)("mdc-text-field--invalid",Ve._control.errorState),i.R7$(2),i.vxM(Ve._hasOutline()||Ve._control.disabled?-1:4),i.R7$(2),i.vxM(Ve._hasOutline()?6:-1),i.R7$(),i.vxM(Ve._hasIconPrefix?7:-1),i.R7$(),i.vxM(Ve._hasTextPrefix?8:-1),i.R7$(2),i.vxM(!Ve._hasOutline()||Ve._forceDisplayInfixLabel()?10:-1),i.R7$(2),i.vxM(Ve._hasTextSuffix?12:-1),i.R7$(),i.vxM(Ve._hasIconSuffix?13:-1),i.R7$(),i.vxM(Ve._hasOutline()?-1:14),i.R7$(),i.AVh("mat-mdc-form-field-subscript-dynamic-size","dynamic"===Ve.subscriptSizing),i.R7$(),i.vxM("error"===(Dt=Ve._getDisplayedMessages())?16:"hint"===Dt?17:-1)}},dependencies:[Fe,W,C.T3,N,kn],styles:['.mdc-text-field{display:inline-flex;align-items:baseline;padding:0 16px;position:relative;box-sizing:border-box;overflow:hidden;will-change:opacity,transform,color;border-top-left-radius:4px;border-top-right-radius:4px;border-bottom-right-radius:0;border-bottom-left-radius:0}.mdc-text-field__input{width:100%;min-width:0;border:none;border-radius:0;background:none;padding:0;-moz-appearance:none;-webkit-appearance:none;height:28px}.mdc-text-field__input::-webkit-calendar-picker-indicator{display:none}.mdc-text-field__input::-ms-clear{display:none}.mdc-text-field__input:focus{outline:none}.mdc-text-field__input:invalid{box-shadow:none}.mdc-text-field__input::placeholder{opacity:0}.mdc-text-field__input::-moz-placeholder{opacity:0}.mdc-text-field__input::-webkit-input-placeholder{opacity:0}.mdc-text-field__input:-ms-input-placeholder{opacity:0}.mdc-text-field--no-label .mdc-text-field__input::placeholder,.mdc-text-field--focused .mdc-text-field__input::placeholder{opacity:1}.mdc-text-field--no-label .mdc-text-field__input::-moz-placeholder,.mdc-text-field--focused .mdc-text-field__input::-moz-placeholder{opacity:1}.mdc-text-field--no-label .mdc-text-field__input::-webkit-input-placeholder,.mdc-text-field--focused .mdc-text-field__input::-webkit-input-placeholder{opacity:1}.mdc-text-field--no-label .mdc-text-field__input:-ms-input-placeholder,.mdc-text-field--focused .mdc-text-field__input:-ms-input-placeholder{opacity:1}.mdc-text-field--disabled:not(.mdc-text-field--no-label) .mdc-text-field__input.mat-mdc-input-disabled-interactive::placeholder{opacity:0}.mdc-text-field--disabled:not(.mdc-text-field--no-label) .mdc-text-field__input.mat-mdc-input-disabled-interactive::-moz-placeholder{opacity:0}.mdc-text-field--disabled:not(.mdc-text-field--no-label) .mdc-text-field__input.mat-mdc-input-disabled-interactive::-webkit-input-placeholder{opacity:0}.mdc-text-field--disabled:not(.mdc-text-field--no-label) .mdc-text-field__input.mat-mdc-input-disabled-interactive:-ms-input-placeholder{opacity:0}.mdc-text-field--outlined .mdc-text-field__input,.mdc-text-field--filled.mdc-text-field--no-label .mdc-text-field__input{height:100%}.mdc-text-field--outlined .mdc-text-field__input{display:flex;border:none !important;background-color:rgba(0,0,0,0)}.mdc-text-field--disabled .mdc-text-field__input{pointer-events:auto}.mdc-text-field--filled:not(.mdc-text-field--disabled) .mdc-text-field__input{color:var(--mdc-filled-text-field-input-text-color, var(--mat-sys-on-surface));caret-color:var(--mdc-filled-text-field-caret-color, var(--mat-sys-primary))}.mdc-text-field--filled:not(.mdc-text-field--disabled) .mdc-text-field__input::placeholder{color:var(--mdc-filled-text-field-input-text-placeholder-color, var(--mat-sys-on-surface-variant))}.mdc-text-field--filled:not(.mdc-text-field--disabled) .mdc-text-field__input::-moz-placeholder{color:var(--mdc-filled-text-field-input-text-placeholder-color, var(--mat-sys-on-surface-variant))}.mdc-text-field--filled:not(.mdc-text-field--disabled) .mdc-text-field__input::-webkit-input-placeholder{color:var(--mdc-filled-text-field-input-text-placeholder-color, var(--mat-sys-on-surface-variant))}.mdc-text-field--filled:not(.mdc-text-field--disabled) .mdc-text-field__input:-ms-input-placeholder{color:var(--mdc-filled-text-field-input-text-placeholder-color, var(--mat-sys-on-surface-variant))}.mdc-text-field--filled.mdc-text-field--invalid:not(.mdc-text-field--disabled) .mdc-text-field__input{caret-color:var(--mdc-filled-text-field-error-caret-color)}.mdc-text-field--filled.mdc-text-field--disabled .mdc-text-field__input{color:var(--mdc-filled-text-field-disabled-input-text-color, color-mix(in srgb, var(--mat-sys-on-surface) 38%, transparent))}.mdc-text-field--outlined:not(.mdc-text-field--disabled) .mdc-text-field__input{color:var(--mdc-outlined-text-field-input-text-color, var(--mat-sys-on-surface));caret-color:var(--mdc-outlined-text-field-caret-color, var(--mat-sys-primary))}.mdc-text-field--outlined:not(.mdc-text-field--disabled) .mdc-text-field__input::placeholder{color:var(--mdc-outlined-text-field-input-text-placeholder-color, var(--mat-sys-on-surface-variant))}.mdc-text-field--outlined:not(.mdc-text-field--disabled) .mdc-text-field__input::-moz-placeholder{color:var(--mdc-outlined-text-field-input-text-placeholder-color, var(--mat-sys-on-surface-variant))}.mdc-text-field--outlined:not(.mdc-text-field--disabled) .mdc-text-field__input::-webkit-input-placeholder{color:var(--mdc-outlined-text-field-input-text-placeholder-color, var(--mat-sys-on-surface-variant))}.mdc-text-field--outlined:not(.mdc-text-field--disabled) .mdc-text-field__input:-ms-input-placeholder{color:var(--mdc-outlined-text-field-input-text-placeholder-color, var(--mat-sys-on-surface-variant))}.mdc-text-field--outlined.mdc-text-field--invalid:not(.mdc-text-field--disabled) .mdc-text-field__input{caret-color:var(--mdc-outlined-text-field-error-caret-color)}.mdc-text-field--outlined.mdc-text-field--disabled .mdc-text-field__input{color:var(--mdc-outlined-text-field-disabled-input-text-color, color-mix(in srgb, var(--mat-sys-on-surface) 38%, transparent))}@media(forced-colors: active){.mdc-text-field--disabled .mdc-text-field__input{background-color:Window}}.mdc-text-field--filled{height:56px;border-bottom-right-radius:0;border-bottom-left-radius:0;border-top-left-radius:var(--mdc-filled-text-field-container-shape, var(--mat-sys-corner-extra-small));border-top-right-radius:var(--mdc-filled-text-field-container-shape, var(--mat-sys-corner-extra-small))}.mdc-text-field--filled:not(.mdc-text-field--disabled){background-color:var(--mdc-filled-text-field-container-color, var(--mat-sys-surface-variant))}.mdc-text-field--filled.mdc-text-field--disabled{background-color:var(--mdc-filled-text-field-disabled-container-color, color-mix(in srgb, var(--mat-sys-on-surface) 4%, transparent))}.mdc-text-field--outlined{height:56px;overflow:visible;padding-right:max(16px,var(--mdc-outlined-text-field-container-shape, var(--mat-sys-corner-extra-small)));padding-left:max(16px,var(--mdc-outlined-text-field-container-shape, var(--mat-sys-corner-extra-small)) + 4px)}[dir=rtl] .mdc-text-field--outlined{padding-right:max(16px,var(--mdc-outlined-text-field-container-shape, var(--mat-sys-corner-extra-small)) + 4px);padding-left:max(16px,var(--mdc-outlined-text-field-container-shape, var(--mat-sys-corner-extra-small)))}.mdc-floating-label{position:absolute;left:0;transform-origin:left top;line-height:1.15rem;text-align:left;text-overflow:ellipsis;white-space:nowrap;cursor:text;overflow:hidden;will-change:transform}[dir=rtl] .mdc-floating-label{right:0;left:auto;transform-origin:right top;text-align:right}.mdc-text-field .mdc-floating-label{top:50%;transform:translateY(-50%);pointer-events:none}.mdc-notched-outline .mdc-floating-label{display:inline-block;position:relative;max-width:100%}.mdc-text-field--outlined .mdc-floating-label{left:4px;right:auto}[dir=rtl] .mdc-text-field--outlined .mdc-floating-label{left:auto;right:4px}.mdc-text-field--filled .mdc-floating-label{left:16px;right:auto}[dir=rtl] .mdc-text-field--filled .mdc-floating-label{left:auto;right:16px}.mdc-text-field--disabled .mdc-floating-label{cursor:default}@media(forced-colors: active){.mdc-text-field--disabled .mdc-floating-label{z-index:1}}.mdc-text-field--filled.mdc-text-field--no-label .mdc-floating-label{display:none}.mdc-text-field--filled:not(.mdc-text-field--disabled) .mdc-floating-label{color:var(--mdc-filled-text-field-label-text-color, var(--mat-sys-on-surface-variant))}.mdc-text-field--filled:not(.mdc-text-field--disabled).mdc-text-field--focused .mdc-floating-label{color:var(--mdc-filled-text-field-focus-label-text-color, var(--mat-sys-primary))}.mdc-text-field--filled:not(.mdc-text-field--disabled):not(.mdc-text-field--focused):hover .mdc-floating-label{color:var(--mdc-filled-text-field-hover-label-text-color, var(--mat-sys-on-surface-variant))}.mdc-text-field--filled.mdc-text-field--disabled .mdc-floating-label{color:var(--mdc-filled-text-field-disabled-label-text-color, color-mix(in srgb, var(--mat-sys-on-surface) 38%, transparent))}.mdc-text-field--filled:not(.mdc-text-field--disabled).mdc-text-field--invalid .mdc-floating-label{color:var(--mdc-filled-text-field-error-label-text-color, var(--mat-sys-error))}.mdc-text-field--filled:not(.mdc-text-field--disabled).mdc-text-field--invalid.mdc-text-field--focused .mdc-floating-label{color:var(--mdc-filled-text-field-error-focus-label-text-color, var(--mat-sys-error))}.mdc-text-field--filled:not(.mdc-text-field--disabled).mdc-text-field--invalid:not(.mdc-text-field--disabled):hover .mdc-floating-label{color:var(--mdc-filled-text-field-error-hover-label-text-color, var(--mat-sys-on-error-container))}.mdc-text-field--filled .mdc-floating-label{font-family:var(--mdc-filled-text-field-label-text-font, var(--mat-sys-body-large-font));font-size:var(--mdc-filled-text-field-label-text-size, var(--mat-sys-body-large-size));font-weight:var(--mdc-filled-text-field-label-text-weight, var(--mat-sys-body-large-weight));letter-spacing:var(--mdc-filled-text-field-label-text-tracking, var(--mat-sys-body-large-tracking))}.mdc-text-field--outlined:not(.mdc-text-field--disabled) .mdc-floating-label{color:var(--mdc-outlined-text-field-label-text-color, var(--mat-sys-on-surface-variant))}.mdc-text-field--outlined:not(.mdc-text-field--disabled).mdc-text-field--focused .mdc-floating-label{color:var(--mdc-outlined-text-field-focus-label-text-color, var(--mat-sys-primary))}.mdc-text-field--outlined:not(.mdc-text-field--disabled):not(.mdc-text-field--focused):hover .mdc-floating-label{color:var(--mdc-outlined-text-field-hover-label-text-color, var(--mat-sys-on-surface))}.mdc-text-field--outlined.mdc-text-field--disabled .mdc-floating-label{color:var(--mdc-outlined-text-field-disabled-label-text-color, color-mix(in srgb, var(--mat-sys-on-surface) 38%, transparent))}.mdc-text-field--outlined:not(.mdc-text-field--disabled).mdc-text-field--invalid .mdc-floating-label{color:var(--mdc-outlined-text-field-error-label-text-color, var(--mat-sys-error))}.mdc-text-field--outlined:not(.mdc-text-field--disabled).mdc-text-field--invalid.mdc-text-field--focused .mdc-floating-label{color:var(--mdc-outlined-text-field-error-focus-label-text-color, var(--mat-sys-error))}.mdc-text-field--outlined:not(.mdc-text-field--disabled).mdc-text-field--invalid:not(.mdc-text-field--disabled):hover .mdc-floating-label{color:var(--mdc-outlined-text-field-error-hover-label-text-color, var(--mat-sys-on-error-container))}.mdc-text-field--outlined .mdc-floating-label{font-family:var(--mdc-outlined-text-field-label-text-font, var(--mat-sys-body-large-font));font-size:var(--mdc-outlined-text-field-label-text-size, var(--mat-sys-body-large-size));font-weight:var(--mdc-outlined-text-field-label-text-weight, var(--mat-sys-body-large-weight));letter-spacing:var(--mdc-outlined-text-field-label-text-tracking, var(--mat-sys-body-large-tracking))}.mdc-floating-label--float-above{cursor:auto;transform:translateY(-106%) scale(0.75)}.mdc-text-field--filled .mdc-floating-label--float-above{transform:translateY(-106%) scale(0.75)}.mdc-text-field--outlined .mdc-floating-label--float-above{transform:translateY(-37.25px) scale(1);font-size:.75rem}.mdc-notched-outline .mdc-floating-label--float-above{text-overflow:clip}.mdc-notched-outline--upgraded .mdc-floating-label--float-above{max-width:133.3333333333%}.mdc-text-field--outlined.mdc-notched-outline--upgraded .mdc-floating-label--float-above,.mdc-text-field--outlined .mdc-notched-outline--upgraded .mdc-floating-label--float-above{transform:translateY(-34.75px) scale(0.75)}.mdc-text-field--outlined.mdc-notched-outline--upgraded .mdc-floating-label--float-above,.mdc-text-field--outlined .mdc-notched-outline--upgraded .mdc-floating-label--float-above{font-size:1rem}.mdc-floating-label--required:not(.mdc-floating-label--hide-required-marker)::after{margin-left:1px;margin-right:0;content:"*"}[dir=rtl] .mdc-floating-label--required:not(.mdc-floating-label--hide-required-marker)::after{margin-left:0;margin-right:1px}.mdc-notched-outline{display:flex;position:absolute;top:0;right:0;left:0;box-sizing:border-box;width:100%;max-width:100%;height:100%;text-align:left;pointer-events:none}[dir=rtl] .mdc-notched-outline{text-align:right}.mdc-text-field--outlined .mdc-notched-outline{z-index:1}.mat-mdc-notch-piece{box-sizing:border-box;height:100%;pointer-events:none;border-top:1px solid;border-bottom:1px solid}.mdc-text-field--focused .mat-mdc-notch-piece{border-width:2px}.mdc-text-field--outlined:not(.mdc-text-field--disabled) .mat-mdc-notch-piece{border-color:var(--mdc-outlined-text-field-outline-color, var(--mat-sys-outline));border-width:var(--mdc-outlined-text-field-outline-width, 1px)}.mdc-text-field--outlined:not(.mdc-text-field--disabled):not(.mdc-text-field--focused):hover .mat-mdc-notch-piece{border-color:var(--mdc-outlined-text-field-hover-outline-color, var(--mat-sys-on-surface))}.mdc-text-field--outlined:not(.mdc-text-field--disabled).mdc-text-field--focused .mat-mdc-notch-piece{border-color:var(--mdc-outlined-text-field-focus-outline-color, var(--mat-sys-primary))}.mdc-text-field--outlined.mdc-text-field--disabled .mat-mdc-notch-piece{border-color:var(--mdc-outlined-text-field-disabled-outline-color, color-mix(in srgb, var(--mat-sys-on-surface) 12%, transparent))}.mdc-text-field--outlined:not(.mdc-text-field--disabled).mdc-text-field--invalid .mat-mdc-notch-piece{border-color:var(--mdc-outlined-text-field-error-outline-color, var(--mat-sys-error))}.mdc-text-field--outlined:not(.mdc-text-field--disabled).mdc-text-field--invalid:not(.mdc-text-field--focused):hover .mdc-notched-outline .mat-mdc-notch-piece{border-color:var(--mdc-outlined-text-field-error-hover-outline-color, var(--mat-sys-on-error-container))}.mdc-text-field--outlined:not(.mdc-text-field--disabled).mdc-text-field--invalid.mdc-text-field--focused .mat-mdc-notch-piece{border-color:var(--mdc-outlined-text-field-error-focus-outline-color, var(--mat-sys-error))}.mdc-text-field--outlined:not(.mdc-text-field--disabled).mdc-text-field--focused .mdc-notched-outline .mat-mdc-notch-piece{border-width:var(--mdc-outlined-text-field-focus-outline-width, 2px)}.mdc-notched-outline__leading{border-left:1px solid;border-right:none;border-top-right-radius:0;border-bottom-right-radius:0;border-top-left-radius:var(--mdc-outlined-text-field-container-shape, var(--mat-sys-corner-extra-small));border-bottom-left-radius:var(--mdc-outlined-text-field-container-shape, var(--mat-sys-corner-extra-small))}.mdc-text-field--outlined .mdc-notched-outline .mdc-notched-outline__leading{width:max(12px,var(--mdc-outlined-text-field-container-shape, var(--mat-sys-corner-extra-small)))}[dir=rtl] .mdc-notched-outline__leading{border-left:none;border-right:1px solid;border-bottom-left-radius:0;border-top-left-radius:0;border-top-right-radius:var(--mdc-outlined-text-field-container-shape, var(--mat-sys-corner-extra-small));border-bottom-right-radius:var(--mdc-outlined-text-field-container-shape, var(--mat-sys-corner-extra-small))}.mdc-notched-outline__trailing{flex-grow:1;border-left:none;border-right:1px solid;border-top-left-radius:0;border-bottom-left-radius:0;border-top-right-radius:var(--mdc-outlined-text-field-container-shape, var(--mat-sys-corner-extra-small));border-bottom-right-radius:var(--mdc-outlined-text-field-container-shape, var(--mat-sys-corner-extra-small))}[dir=rtl] .mdc-notched-outline__trailing{border-left:1px solid;border-right:none;border-top-right-radius:0;border-bottom-right-radius:0;border-top-left-radius:var(--mdc-outlined-text-field-container-shape, var(--mat-sys-corner-extra-small));border-bottom-left-radius:var(--mdc-outlined-text-field-container-shape, var(--mat-sys-corner-extra-small))}.mdc-notched-outline__notch{flex:0 0 auto;width:auto}.mdc-text-field--outlined .mdc-notched-outline .mdc-notched-outline__notch{max-width:min(var(--mat-form-field-notch-max-width, 100%),100% - max(12px,var(--mdc-outlined-text-field-container-shape, var(--mat-sys-corner-extra-small)))*2)}.mdc-text-field--outlined .mdc-notched-outline--notched .mdc-notched-outline__notch{padding-top:1px}.mdc-text-field--focused.mdc-text-field--outlined .mdc-notched-outline--notched .mdc-notched-outline__notch{padding-top:2px}.mdc-notched-outline--notched .mdc-notched-outline__notch{padding-left:0;padding-right:8px;border-top:none;--mat-form-field-notch-max-width: 100%}[dir=rtl] .mdc-notched-outline--notched .mdc-notched-outline__notch{padding-left:8px;padding-right:0}.mdc-notched-outline--no-label .mdc-notched-outline__notch{display:none}.mdc-line-ripple::before,.mdc-line-ripple::after{position:absolute;bottom:0;left:0;width:100%;border-bottom-style:solid;content:""}.mdc-line-ripple::before{z-index:1;border-bottom-width:var(--mdc-filled-text-field-active-indicator-height, 1px)}.mdc-text-field--filled:not(.mdc-text-field--disabled) .mdc-line-ripple::before{border-bottom-color:var(--mdc-filled-text-field-active-indicator-color, var(--mat-sys-on-surface-variant))}.mdc-text-field--filled:not(.mdc-text-field--disabled):not(.mdc-text-field--focused):hover .mdc-line-ripple::before{border-bottom-color:var(--mdc-filled-text-field-hover-active-indicator-color, var(--mat-sys-on-surface))}.mdc-text-field--filled.mdc-text-field--disabled .mdc-line-ripple::before{border-bottom-color:var(--mdc-filled-text-field-disabled-active-indicator-color, color-mix(in srgb, var(--mat-sys-on-surface) 38%, transparent))}.mdc-text-field--filled:not(.mdc-text-field--disabled).mdc-text-field--invalid .mdc-line-ripple::before{border-bottom-color:var(--mdc-filled-text-field-error-active-indicator-color, var(--mat-sys-error))}.mdc-text-field--filled:not(.mdc-text-field--disabled).mdc-text-field--invalid:not(.mdc-text-field--focused):hover .mdc-line-ripple::before{border-bottom-color:var(--mdc-filled-text-field-error-hover-active-indicator-color, var(--mat-sys-on-error-container))}.mdc-line-ripple::after{transform:scaleX(0);opacity:0;z-index:2}.mdc-text-field--filled .mdc-line-ripple::after{border-bottom-width:var(--mdc-filled-text-field-focus-active-indicator-height, 2px)}.mdc-text-field--filled:not(.mdc-text-field--disabled) .mdc-line-ripple::after{border-bottom-color:var(--mdc-filled-text-field-focus-active-indicator-color, var(--mat-sys-primary))}.mdc-text-field--filled.mdc-text-field--invalid:not(.mdc-text-field--disabled) .mdc-line-ripple::after{border-bottom-color:var(--mdc-filled-text-field-error-focus-active-indicator-color, var(--mat-sys-error))}.mdc-line-ripple--active::after{transform:scaleX(1);opacity:1}.mdc-line-ripple--deactivating::after{opacity:0}.mdc-text-field--disabled{pointer-events:none}.mat-mdc-form-field-textarea-control{vertical-align:middle;resize:vertical;box-sizing:border-box;height:auto;margin:0;padding:0;border:none;overflow:auto}.mat-mdc-form-field-input-control.mat-mdc-form-field-input-control{-moz-osx-font-smoothing:grayscale;-webkit-font-smoothing:antialiased;font:inherit;letter-spacing:inherit;text-decoration:inherit;text-transform:inherit;border:none}.mat-mdc-form-field .mat-mdc-floating-label.mdc-floating-label{-moz-osx-font-smoothing:grayscale;-webkit-font-smoothing:antialiased;line-height:normal;pointer-events:all;will-change:auto}.mat-mdc-form-field:not(.mat-form-field-disabled) .mat-mdc-floating-label.mdc-floating-label{cursor:inherit}.mdc-text-field--no-label:not(.mdc-text-field--textarea) .mat-mdc-form-field-input-control.mdc-text-field__input,.mat-mdc-text-field-wrapper .mat-mdc-form-field-input-control{height:auto}.mat-mdc-text-field-wrapper .mat-mdc-form-field-input-control.mdc-text-field__input[type=color]{height:23px}.mat-mdc-text-field-wrapper{height:auto;flex:auto;will-change:auto}.mat-mdc-form-field-has-icon-prefix .mat-mdc-text-field-wrapper{padding-left:0;--mat-mdc-form-field-label-offset-x: -16px}.mat-mdc-form-field-has-icon-suffix .mat-mdc-text-field-wrapper{padding-right:0}[dir=rtl] .mat-mdc-text-field-wrapper{padding-left:16px;padding-right:16px}[dir=rtl] .mat-mdc-form-field-has-icon-suffix .mat-mdc-text-field-wrapper{padding-left:0}[dir=rtl] .mat-mdc-form-field-has-icon-prefix .mat-mdc-text-field-wrapper{padding-right:0}.mat-form-field-disabled .mdc-text-field__input::placeholder{color:var(--mat-form-field-disabled-input-text-placeholder-color, color-mix(in srgb, var(--mat-sys-on-surface) 38%, transparent))}.mat-form-field-disabled .mdc-text-field__input::-moz-placeholder{color:var(--mat-form-field-disabled-input-text-placeholder-color, color-mix(in srgb, var(--mat-sys-on-surface) 38%, transparent))}.mat-form-field-disabled .mdc-text-field__input::-webkit-input-placeholder{color:var(--mat-form-field-disabled-input-text-placeholder-color, color-mix(in srgb, var(--mat-sys-on-surface) 38%, transparent))}.mat-form-field-disabled .mdc-text-field__input:-ms-input-placeholder{color:var(--mat-form-field-disabled-input-text-placeholder-color, color-mix(in srgb, var(--mat-sys-on-surface) 38%, transparent))}.mat-mdc-form-field-label-always-float .mdc-text-field__input::placeholder{transition-delay:40ms;transition-duration:110ms;opacity:1}.mat-mdc-text-field-wrapper .mat-mdc-form-field-infix .mat-mdc-floating-label{left:auto;right:auto}.mat-mdc-text-field-wrapper.mdc-text-field--outlined .mdc-text-field__input{display:inline-block}.mat-mdc-form-field .mat-mdc-text-field-wrapper.mdc-text-field .mdc-notched-outline__notch{padding-top:0}.mat-mdc-form-field.mat-mdc-form-field.mat-mdc-form-field.mat-mdc-form-field.mat-mdc-form-field.mat-mdc-form-field .mdc-notched-outline__notch{border-left:1px solid rgba(0,0,0,0)}[dir=rtl] .mat-mdc-form-field.mat-mdc-form-field.mat-mdc-form-field.mat-mdc-form-field.mat-mdc-form-field.mat-mdc-form-field .mdc-notched-outline__notch{border-left:none;border-right:1px solid rgba(0,0,0,0)}.mat-mdc-form-field-infix{min-height:var(--mat-form-field-container-height, 56px);padding-top:var(--mat-form-field-filled-with-label-container-padding-top, 24px);padding-bottom:var(--mat-form-field-filled-with-label-container-padding-bottom, 8px)}.mdc-text-field--outlined .mat-mdc-form-field-infix,.mdc-text-field--no-label .mat-mdc-form-field-infix{padding-top:var(--mat-form-field-container-vertical-padding, 16px);padding-bottom:var(--mat-form-field-container-vertical-padding, 16px)}.mat-mdc-text-field-wrapper .mat-mdc-form-field-flex .mat-mdc-floating-label{top:calc(var(--mat-form-field-container-height, 56px)/2)}.mdc-text-field--filled .mat-mdc-floating-label{display:var(--mat-form-field-filled-label-display, block)}.mat-mdc-text-field-wrapper.mdc-text-field--outlined .mdc-notched-outline--upgraded .mdc-floating-label--float-above{--mat-mdc-form-field-label-transform: translateY(calc(calc(6.75px + var(--mat-form-field-container-height, 56px) / 2) * -1)) scale(var(--mat-mdc-form-field-floating-label-scale, 0.75));transform:var(--mat-mdc-form-field-label-transform)}.mat-mdc-form-field-subscript-wrapper{box-sizing:border-box;width:100%;position:relative}.mat-mdc-form-field-hint-wrapper,.mat-mdc-form-field-error-wrapper{position:absolute;top:0;left:0;right:0;padding:0 16px}.mat-mdc-form-field-subscript-dynamic-size .mat-mdc-form-field-hint-wrapper,.mat-mdc-form-field-subscript-dynamic-size .mat-mdc-form-field-error-wrapper{position:static}.mat-mdc-form-field-bottom-align::before{content:"";display:inline-block;height:16px}.mat-mdc-form-field-bottom-align.mat-mdc-form-field-subscript-dynamic-size::before{content:unset}.mat-mdc-form-field-hint-end{order:1}.mat-mdc-form-field-hint-wrapper{display:flex}.mat-mdc-form-field-hint-spacer{flex:1 0 1em}.mat-mdc-form-field-error{display:block;color:var(--mat-form-field-error-text-color, var(--mat-sys-error))}.mat-mdc-form-field-subscript-wrapper,.mat-mdc-form-field-bottom-align::before{-moz-osx-font-smoothing:grayscale;-webkit-font-smoothing:antialiased;font-family:var(--mat-form-field-subscript-text-font, var(--mat-sys-body-small-font));line-height:var(--mat-form-field-subscript-text-line-height, var(--mat-sys-body-small-line-height));font-size:var(--mat-form-field-subscript-text-size, var(--mat-sys-body-small-size));letter-spacing:var(--mat-form-field-subscript-text-tracking, var(--mat-sys-body-small-tracking));font-weight:var(--mat-form-field-subscript-text-weight, var(--mat-sys-body-small-weight))}.mat-mdc-form-field-focus-overlay{top:0;left:0;right:0;bottom:0;position:absolute;opacity:0;pointer-events:none;background-color:var(--mat-form-field-state-layer-color, var(--mat-sys-on-surface))}.mat-mdc-text-field-wrapper:hover .mat-mdc-form-field-focus-overlay{opacity:var(--mat-form-field-hover-state-layer-opacity, var(--mat-sys-hover-state-layer-opacity))}.mat-mdc-form-field.mat-focused .mat-mdc-form-field-focus-overlay{opacity:var(--mat-form-field-focus-state-layer-opacity, 0)}select.mat-mdc-form-field-input-control{-moz-appearance:none;-webkit-appearance:none;background-color:rgba(0,0,0,0);display:inline-flex;box-sizing:border-box}select.mat-mdc-form-field-input-control:not(:disabled){cursor:pointer}select.mat-mdc-form-field-input-control:not(.mat-mdc-native-select-inline) option{color:var(--mat-form-field-select-option-text-color, var(--mat-sys-neutral10))}select.mat-mdc-form-field-input-control:not(.mat-mdc-native-select-inline) option:disabled{color:var(--mat-form-field-select-disabled-option-text-color, color-mix(in srgb, var(--mat-sys-neutral10) 38%, transparent))}.mat-mdc-form-field-type-mat-native-select .mat-mdc-form-field-infix::after{content:"";width:0;height:0;border-left:5px solid rgba(0,0,0,0);border-right:5px solid rgba(0,0,0,0);border-top:5px solid;position:absolute;right:0;top:50%;margin-top:-2.5px;pointer-events:none;color:var(--mat-form-field-enabled-select-arrow-color, var(--mat-sys-on-surface-variant))}[dir=rtl] .mat-mdc-form-field-type-mat-native-select .mat-mdc-form-field-infix::after{right:auto;left:0}.mat-mdc-form-field-type-mat-native-select.mat-focused .mat-mdc-form-field-infix::after{color:var(--mat-form-field-focus-select-arrow-color, var(--mat-sys-primary))}.mat-mdc-form-field-type-mat-native-select.mat-form-field-disabled .mat-mdc-form-field-infix::after{color:var(--mat-form-field-disabled-select-arrow-color, color-mix(in srgb, var(--mat-sys-on-surface) 38%, transparent))}.mat-mdc-form-field-type-mat-native-select .mat-mdc-form-field-input-control{padding-right:15px}[dir=rtl] .mat-mdc-form-field-type-mat-native-select .mat-mdc-form-field-input-control{padding-right:0;padding-left:15px}@media(forced-colors: active){.mat-form-field-appearance-fill .mat-mdc-text-field-wrapper{outline:solid 1px}}@media(forced-colors: active){.mat-form-field-appearance-fill.mat-form-field-disabled .mat-mdc-text-field-wrapper{outline-color:GrayText}}@media(forced-colors: active){.mat-form-field-appearance-fill.mat-focused .mat-mdc-text-field-wrapper{outline:dashed 3px}}@media(forced-colors: active){.mat-mdc-form-field.mat-focused .mdc-notched-outline{border:dashed 3px}}.mat-mdc-form-field-input-control[type=date],.mat-mdc-form-field-input-control[type=datetime],.mat-mdc-form-field-input-control[type=datetime-local],.mat-mdc-form-field-input-control[type=month],.mat-mdc-form-field-input-control[type=week],.mat-mdc-form-field-input-control[type=time]{line-height:1}.mat-mdc-form-field-input-control::-webkit-datetime-edit{line-height:1;padding:0;margin-bottom:-2px}.mat-mdc-form-field{--mat-mdc-form-field-floating-label-scale: 0.75;display:inline-flex;flex-direction:column;min-width:0;text-align:left;-moz-osx-font-smoothing:grayscale;-webkit-font-smoothing:antialiased;font-family:var(--mat-form-field-container-text-font, var(--mat-sys-body-large-font));line-height:var(--mat-form-field-container-text-line-height, var(--mat-sys-body-large-line-height));font-size:var(--mat-form-field-container-text-size, var(--mat-sys-body-large-size));letter-spacing:var(--mat-form-field-container-text-tracking, var(--mat-sys-body-large-tracking));font-weight:var(--mat-form-field-container-text-weight, var(--mat-sys-body-large-weight))}.mat-mdc-form-field .mdc-text-field--outlined .mdc-floating-label--float-above{font-size:calc(var(--mat-form-field-outlined-label-text-populated-size)*var(--mat-mdc-form-field-floating-label-scale))}.mat-mdc-form-field .mdc-text-field--outlined .mdc-notched-outline--upgraded .mdc-floating-label--float-above{font-size:var(--mat-form-field-outlined-label-text-populated-size)}[dir=rtl] .mat-mdc-form-field{text-align:right}.mat-mdc-form-field-flex{display:inline-flex;align-items:baseline;box-sizing:border-box;width:100%}.mat-mdc-text-field-wrapper{width:100%;z-index:0}.mat-mdc-form-field-icon-prefix,.mat-mdc-form-field-icon-suffix{align-self:center;line-height:0;pointer-events:auto;position:relative;z-index:1}.mat-mdc-form-field-icon-prefix>.mat-icon,.mat-mdc-form-field-icon-suffix>.mat-icon{padding:0 12px;box-sizing:content-box}.mat-mdc-form-field-icon-prefix{color:var(--mat-form-field-leading-icon-color, var(--mat-sys-on-surface-variant))}.mat-form-field-disabled .mat-mdc-form-field-icon-prefix{color:var(--mat-form-field-disabled-leading-icon-color, color-mix(in srgb, var(--mat-sys-on-surface) 38%, transparent))}.mat-mdc-form-field-icon-suffix{color:var(--mat-form-field-trailing-icon-color, var(--mat-sys-on-surface-variant))}.mat-form-field-disabled .mat-mdc-form-field-icon-suffix{color:var(--mat-form-field-disabled-trailing-icon-color, color-mix(in srgb, var(--mat-sys-on-surface) 38%, transparent))}.mat-form-field-invalid .mat-mdc-form-field-icon-suffix{color:var(--mat-form-field-error-trailing-icon-color, var(--mat-sys-error))}.mat-form-field-invalid:not(.mat-focused):not(.mat-form-field-disabled) .mat-mdc-text-field-wrapper:hover .mat-mdc-form-field-icon-suffix{color:var(--mat-form-field-error-hover-trailing-icon-color, var(--mat-sys-on-error-container))}.mat-form-field-invalid.mat-focused .mat-mdc-text-field-wrapper .mat-mdc-form-field-icon-suffix{color:var(--mat-form-field-error-focus-trailing-icon-color, var(--mat-sys-error))}.mat-mdc-form-field-icon-prefix,[dir=rtl] .mat-mdc-form-field-icon-suffix{padding:0 4px 0 0}.mat-mdc-form-field-icon-suffix,[dir=rtl] .mat-mdc-form-field-icon-prefix{padding:0 0 0 4px}.mat-mdc-form-field-subscript-wrapper .mat-icon,.mat-mdc-form-field label .mat-icon{width:1em;height:1em;font-size:inherit}.mat-mdc-form-field-infix{flex:auto;min-width:0;width:180px;position:relative;box-sizing:border-box}.mat-mdc-form-field-infix:has(textarea[cols]){width:auto}.mat-mdc-form-field .mdc-notched-outline__notch{margin-left:-1px;-webkit-clip-path:inset(-9em -999em -9em 1px);clip-path:inset(-9em -999em -9em 1px)}[dir=rtl] .mat-mdc-form-field .mdc-notched-outline__notch{margin-left:0;margin-right:-1px;-webkit-clip-path:inset(-9em 1px -9em -999em);clip-path:inset(-9em 1px -9em -999em)}.mat-mdc-form-field:not(.mat-form-field-no-animations) .mdc-floating-label{transition:transform 150ms cubic-bezier(0.4, 0, 0.2, 1),color 150ms cubic-bezier(0.4, 0, 0.2, 1)}.mat-mdc-form-field:not(.mat-form-field-no-animations) .mdc-text-field__input{transition:opacity 150ms cubic-bezier(0.4, 0, 0.2, 1)}.mat-mdc-form-field:not(.mat-form-field-no-animations) .mdc-text-field__input::placeholder{transition:opacity 67ms cubic-bezier(0.4, 0, 0.2, 1)}.mat-mdc-form-field:not(.mat-form-field-no-animations) .mdc-text-field__input::-moz-placeholder{transition:opacity 67ms cubic-bezier(0.4, 0, 0.2, 1)}.mat-mdc-form-field:not(.mat-form-field-no-animations) .mdc-text-field__input::-webkit-input-placeholder{transition:opacity 67ms cubic-bezier(0.4, 0, 0.2, 1)}.mat-mdc-form-field:not(.mat-form-field-no-animations) .mdc-text-field__input:-ms-input-placeholder{transition:opacity 67ms cubic-bezier(0.4, 0, 0.2, 1)}.mat-mdc-form-field:not(.mat-form-field-no-animations).mdc-text-field--no-label .mdc-text-field__input::placeholder,.mat-mdc-form-field:not(.mat-form-field-no-animations).mdc-text-field--focused .mdc-text-field__input::placeholder{transition-delay:40ms;transition-duration:110ms}.mat-mdc-form-field:not(.mat-form-field-no-animations).mdc-text-field--no-label .mdc-text-field__input::-moz-placeholder,.mat-mdc-form-field:not(.mat-form-field-no-animations).mdc-text-field--focused .mdc-text-field__input::-moz-placeholder{transition-delay:40ms;transition-duration:110ms}.mat-mdc-form-field:not(.mat-form-field-no-animations).mdc-text-field--no-label .mdc-text-field__input::-webkit-input-placeholder,.mat-mdc-form-field:not(.mat-form-field-no-animations).mdc-text-field--focused .mdc-text-field__input::-webkit-input-placeholder{transition-delay:40ms;transition-duration:110ms}.mat-mdc-form-field:not(.mat-form-field-no-animations).mdc-text-field--no-label .mdc-text-field__input:-ms-input-placeholder,.mat-mdc-form-field:not(.mat-form-field-no-animations).mdc-text-field--focused .mdc-text-field__input:-ms-input-placeholder{transition-delay:40ms;transition-duration:110ms}.mat-mdc-form-field:not(.mat-form-field-no-animations) .mdc-text-field--filled:not(.mdc-ripple-upgraded):focus .mdc-text-field__ripple::before{transition-duration:75ms}.mat-mdc-form-field:not(.mat-form-field-no-animations) .mdc-line-ripple::after{transition:transform 180ms cubic-bezier(0.4, 0, 0.2, 1),opacity 180ms cubic-bezier(0.4, 0, 0.2, 1)}.mdc-notched-outline .mdc-floating-label{max-width:calc(100% + 1px)}.mdc-notched-outline--upgraded .mdc-floating-label--float-above{max-width:calc(133.3333333333% + 1px)}'],encapsulation:2,data:{animation:[Le.transitionMessages]},changeDetection:0})}return vt})(),Vr=(()=>{class vt{static \u0275fac=function(Ge){return new(Ge||vt)};static \u0275mod=i.$C({type:vt});static \u0275inj=i.G2t({imports:[ue.yE,ce.w5,ue.yE]})}return vt})()},3904:(o,s,r)=>{"use strict";r.d(s,{An:()=>_t,m_:()=>ze,tp:()=>Ce});var i=r(3107),a=r(2902),c=r(4460),y=r(3016),w=r(8915),C=r(2653),T=r(5710),S=r(2040),M=r(7947),O=r(7178),L=r(4447),Z=r(6218),q=r(7610),re=r(7691),pe=r(6388);const se=["*"];let ae;function be($e){return function me(){if(void 0===ae&&(ae=null,typeof window<"u")){const $e=window;void 0!==$e.trustedTypes&&(ae=$e.trustedTypes.createPolicy("angular#components",{createHTML:Ft=>Ft}))}return ae}()?.createHTML($e)||$e}function Oe($e){return Error(`Unable to find icon with the name "${$e}"`)}function De($e){return Error(`The URL provided to MatIconRegistry was not trusted as a resource URL via Angular's DomSanitizer. Attempted URL was "${$e}".`)}function ce($e){return Error(`The literal provided to MatIconRegistry was not trusted as safe HTML by Angular's DomSanitizer. Attempted literal was "${$e}".`)}class ue{url;svgText;options;svgElement;constructor(Ft,Ke,Ze){this.url=Ft,this.svgText=Ke,this.options=Ze}}let Ce=(()=>{class $e{_httpClient;_sanitizer;_errorHandler;_document;_svgIconConfigs=new Map;_iconSetConfigs=new Map;_cachedIconsByUrl=new Map;_inProgressUrlFetches=new Map;_fontCssClassesByAlias=new Map;_resolvers=[];_defaultFontSetClass=["material-icons","mat-ligature-font"];constructor(Ke,Ze,it,Ot){this._httpClient=Ke,this._sanitizer=Ze,this._errorHandler=Ot,this._document=it}addSvgIcon(Ke,Ze,it){return this.addSvgIconInNamespace("",Ke,Ze,it)}addSvgIconLiteral(Ke,Ze,it){return this.addSvgIconLiteralInNamespace("",Ke,Ze,it)}addSvgIconInNamespace(Ke,Ze,it,Ot){return this._addSvgIconConfig(Ke,Ze,new ue(it,null,Ot))}addSvgIconResolver(Ke){return this._resolvers.push(Ke),this}addSvgIconLiteralInNamespace(Ke,Ze,it,Ot){const $t=this._sanitizer.sanitize(i.WPN.HTML,it);if(!$t)throw ce(it);const Te=be($t);return this._addSvgIconConfig(Ke,Ze,new ue("",Te,Ot))}addSvgIconSet(Ke,Ze){return this.addSvgIconSetInNamespace("",Ke,Ze)}addSvgIconSetLiteral(Ke,Ze){return this.addSvgIconSetLiteralInNamespace("",Ke,Ze)}addSvgIconSetInNamespace(Ke,Ze,it){return this._addSvgIconSetConfig(Ke,new ue(Ze,null,it))}addSvgIconSetLiteralInNamespace(Ke,Ze,it){const Ot=this._sanitizer.sanitize(i.WPN.HTML,Ze);if(!Ot)throw ce(Ze);const $t=be(Ot);return this._addSvgIconSetConfig(Ke,new ue("",$t,it))}registerFontClassAlias(Ke,Ze=Ke){return this._fontCssClassesByAlias.set(Ke,Ze),this}classNameForFontAlias(Ke){return this._fontCssClassesByAlias.get(Ke)||Ke}setDefaultFontSetClass(...Ke){return this._defaultFontSetClass=Ke,this}getDefaultFontSetClass(){return this._defaultFontSetClass}getSvgIconFromUrl(Ke){const Ze=this._sanitizer.sanitize(i.WPN.RESOURCE_URL,Ke);if(!Ze)throw De(Ke);const it=this._cachedIconsByUrl.get(Ze);return it?(0,y.of)(dt(it)):this._loadSvgIconFromConfig(new ue(Ke,null)).pipe((0,S.M)(Ot=>this._cachedIconsByUrl.set(Ze,Ot)),(0,M.T)(Ot=>dt(Ot)))}getNamedSvgIcon(Ke,Ze=""){const it=bt(Ze,Ke);let Ot=this._svgIconConfigs.get(it);if(Ot)return this._getSvgFromConfig(Ot);if(Ot=this._getIconConfigFromResolvers(Ze,Ke),Ot)return this._svgIconConfigs.set(it,Ot),this._getSvgFromConfig(Ot);const $t=this._iconSetConfigs.get(Ze);return $t?this._getSvgFromIconSetConfigs(Ke,$t):(0,w.$)(Oe(it))}ngOnDestroy(){this._resolvers=[],this._svgIconConfigs.clear(),this._iconSetConfigs.clear(),this._cachedIconsByUrl.clear()}_getSvgFromConfig(Ke){return Ke.svgText?(0,y.of)(dt(this._svgElementFromConfig(Ke))):this._loadSvgIconFromConfig(Ke).pipe((0,M.T)(Ze=>dt(Ze)))}_getSvgFromIconSetConfigs(Ke,Ze){const it=this._extractIconWithNameFromAnySet(Ke,Ze);if(it)return(0,y.of)(it);const Ot=Ze.filter($t=>!$t.svgText).map($t=>this._loadSvgIconSetFromConfig($t).pipe((0,O.W)(Te=>{const st=`Loading icon set URL: ${this._sanitizer.sanitize(i.WPN.RESOURCE_URL,$t.url)} failed: ${Te.message}`;return this._errorHandler.handleError(new Error(st)),(0,y.of)(null)})));return(0,C.p)(Ot).pipe((0,M.T)(()=>{const $t=this._extractIconWithNameFromAnySet(Ke,Ze);if(!$t)throw Oe(Ke);return $t}))}_extractIconWithNameFromAnySet(Ke,Ze){for(let it=Ze.length-1;it>=0;it--){const Ot=Ze[it];if(Ot.svgText&&Ot.svgText.toString().indexOf(Ke)>-1){const $t=this._svgElementFromConfig(Ot),Te=this._extractSvgIconFromSet($t,Ke,Ot.options);if(Te)return Te}}return null}_loadSvgIconFromConfig(Ke){return this._fetchIcon(Ke).pipe((0,S.M)(Ze=>Ke.svgText=Ze),(0,M.T)(()=>this._svgElementFromConfig(Ke)))}_loadSvgIconSetFromConfig(Ke){return Ke.svgText?(0,y.of)(null):this._fetchIcon(Ke).pipe((0,S.M)(Ze=>Ke.svgText=Ze))}_extractSvgIconFromSet(Ke,Ze,it){const Ot=Ke.querySelector(`[id="${Ze}"]`);if(!Ot)return null;const $t=Ot.cloneNode(!0);if($t.removeAttribute("id"),"svg"===$t.nodeName.toLowerCase())return this._setSvgAttributes($t,it);if("symbol"===$t.nodeName.toLowerCase())return this._setSvgAttributes(this._toSvgElement($t),it);const Te=this._svgElementFromString(be(""));return Te.appendChild($t),this._setSvgAttributes(Te,it)}_svgElementFromString(Ke){const Ze=this._document.createElement("DIV");Ze.innerHTML=Ke;const it=Ze.querySelector("svg");if(!it)throw Error(" tag not found");return it}_toSvgElement(Ke){const Ze=this._svgElementFromString(be("")),it=Ke.attributes;for(let Ot=0;Otbe(st)),(0,L.j)(()=>this._inProgressUrlFetches.delete($t)),(0,Z.u)());return this._inProgressUrlFetches.set($t,Ee),Ee}_addSvgIconConfig(Ke,Ze,it){return this._svgIconConfigs.set(bt(Ke,Ze),it),this}_addSvgIconSetConfig(Ke,Ze){const it=this._iconSetConfigs.get(Ke);return it?it.push(Ze):this._iconSetConfigs.set(Ke,[Ze]),this}_svgElementFromConfig(Ke){if(!Ke.svgElement){const Ze=this._svgElementFromString(Ke.svgText);this._setSvgAttributes(Ze,Ke.options),Ke.svgElement=Ze}return Ke.svgElement}_getIconConfigFromResolvers(Ke,Ze){for(let it=0;itFt?Ft.pathname+Ft.search:""}}}),Vn=["clip-path","color-profile","src","cursor","fill","filter","marker","marker-start","marker-mid","marker-end","mask","stroke"],yn=Vn.map($e=>`[${$e}]`).join(", "),qe=/^url\(['"]?#(.*?)['"]?\)$/;let _t=(()=>{class $e{_elementRef=(0,i.WQX)(i.aKT);_iconRegistry=(0,i.WQX)(Ce);_location=(0,i.WQX)(gn);_errorHandler=(0,i.WQX)(i.zcH);_defaultColor;get color(){return this._color||this._defaultColor}set color(Ke){this._color=Ke}_color;inline=!1;get svgIcon(){return this._svgIcon}set svgIcon(Ke){Ke!==this._svgIcon&&(Ke?this._updateSvgIcon(Ke):this._svgIcon&&this._clearSvgElement(),this._svgIcon=Ke)}_svgIcon;get fontSet(){return this._fontSet}set fontSet(Ke){const Ze=this._cleanupFontValue(Ke);Ze!==this._fontSet&&(this._fontSet=Ze,this._updateFontIconClasses())}_fontSet;get fontIcon(){return this._fontIcon}set fontIcon(Ke){const Ze=this._cleanupFontValue(Ke);Ze!==this._fontIcon&&(this._fontIcon=Ze,this._updateFontIconClasses())}_fontIcon;_previousFontSetClass=[];_previousFontIconClass;_svgName;_svgNamespace;_previousPath;_elementsWithExternalReferences;_currentIconFetch=T.yU.EMPTY;constructor(){const Ke=(0,i.WQX)(new i.ES_("aria-hidden"),{optional:!0}),Ze=(0,i.WQX)(rn,{optional:!0});Ze&&(Ze.color&&(this.color=this._defaultColor=Ze.color),Ze.fontSet&&(this.fontSet=Ze.fontSet)),Ke||this._elementRef.nativeElement.setAttribute("aria-hidden","true")}_splitIconName(Ke){if(!Ke)return["",""];const Ze=Ke.split(":");switch(Ze.length){case 1:return["",Ze[0]];case 2:return Ze;default:throw Error(`Invalid icon name: "${Ke}"`)}}ngOnInit(){this._updateFontIconClasses()}ngAfterViewChecked(){const Ke=this._elementsWithExternalReferences;if(Ke&&Ke.size){const Ze=this._location.getPathname();Ze!==this._previousPath&&(this._previousPath=Ze,this._prependPathToReferences(Ze))}}ngOnDestroy(){this._currentIconFetch.unsubscribe(),this._elementsWithExternalReferences&&this._elementsWithExternalReferences.clear()}_usingFontIcon(){return!this.svgIcon}_setSvgElement(Ke){this._clearSvgElement();const Ze=this._location.getPathname();this._previousPath=Ze,this._cacheChildrenWithExternalReferences(Ke),this._prependPathToReferences(Ze),this._elementRef.nativeElement.appendChild(Ke)}_clearSvgElement(){const Ke=this._elementRef.nativeElement;let Ze=Ke.childNodes.length;for(this._elementsWithExternalReferences&&this._elementsWithExternalReferences.clear();Ze--;){const it=Ke.childNodes[Ze];(1!==it.nodeType||"svg"===it.nodeName.toLowerCase())&&it.remove()}}_updateFontIconClasses(){if(!this._usingFontIcon())return;const Ke=this._elementRef.nativeElement,Ze=(this.fontSet?this._iconRegistry.classNameForFontAlias(this.fontSet).split(/ +/):this._iconRegistry.getDefaultFontSetClass()).filter(it=>it.length>0);this._previousFontSetClass.forEach(it=>Ke.classList.remove(it)),Ze.forEach(it=>Ke.classList.add(it)),this._previousFontSetClass=Ze,this.fontIcon!==this._previousFontIconClass&&!Ze.includes("mat-ligature-font")&&(this._previousFontIconClass&&Ke.classList.remove(this._previousFontIconClass),this.fontIcon&&Ke.classList.add(this.fontIcon),this._previousFontIconClass=this.fontIcon)}_cleanupFontValue(Ke){return"string"==typeof Ke?Ke.trim().split(" ")[0]:Ke}_prependPathToReferences(Ke){const Ze=this._elementsWithExternalReferences;Ze&&Ze.forEach((it,Ot)=>{it.forEach($t=>{Ot.setAttribute($t.name,`url('${Ke}#${$t.value}')`)})})}_cacheChildrenWithExternalReferences(Ke){const Ze=Ke.querySelectorAll(yn),it=this._elementsWithExternalReferences=this._elementsWithExternalReferences||new Map;for(let Ot=0;Ot{const Te=Ze[Ot],Ee=Te.getAttribute($t),st=Ee?Ee.match(qe):null;if(st){let Xt=it.get(Te);Xt||(Xt=[],it.set(Te,Xt)),Xt.push({name:$t,value:st[1]})}})}_updateSvgIcon(Ke){if(this._svgNamespace=null,this._svgName=null,this._currentIconFetch.unsubscribe(),Ke){const[Ze,it]=this._splitIconName(Ke);Ze&&(this._svgNamespace=Ze),it&&(this._svgName=it),this._currentIconFetch=this._iconRegistry.getNamedSvgIcon(it,Ze).pipe((0,q.s)(1)).subscribe(Ot=>this._setSvgElement(Ot),Ot=>{this._errorHandler.handleError(new Error(`Error retrieving icon ${Ze}:${it}! ${Ot.message}`))})}}static \u0275fac=function(Ze){return new(Ze||$e)};static \u0275cmp=i.VBU({type:$e,selectors:[["mat-icon"]],hostAttrs:["role","img",1,"mat-icon","notranslate"],hostVars:10,hostBindings:function(Ze,it){2&Ze&&(i.BMQ("data-mat-icon-type",it._usingFontIcon()?"font":"svg")("data-mat-icon-name",it._svgName||it.fontIcon)("data-mat-icon-namespace",it._svgNamespace||it.fontSet)("fontIcon",it._usingFontIcon()?it.fontIcon:null),i.HbH(it.color?"mat-"+it.color:""),i.AVh("mat-icon-inline",it.inline)("mat-icon-no-color","primary"!==it.color&&"accent"!==it.color&&"warn"!==it.color))},inputs:{color:"color",inline:[2,"inline","inline",i.L39],svgIcon:"svgIcon",fontSet:"fontSet",fontIcon:"fontIcon"},exportAs:["matIcon"],features:[i.GFd],ngContentSelectors:se,decls:1,vars:0,template:function(Ze,it){1&Ze&&(i.NAR(),i.SdG(0))},styles:["mat-icon,mat-icon.mat-primary,mat-icon.mat-accent,mat-icon.mat-warn{color:var(--mat-icon-color, inherit)}.mat-icon{-webkit-user-select:none;user-select:none;background-repeat:no-repeat;display:inline-block;fill:currentColor;height:24px;width:24px;overflow:hidden}.mat-icon.mat-icon-inline{font-size:inherit;height:inherit;line-height:inherit;width:inherit}.mat-icon.mat-ligature-font[fontIcon]::before{content:attr(fontIcon)}[dir=rtl] .mat-icon-rtl-mirror{transform:scale(-1, 1)}.mat-form-field:not(.mat-form-field-appearance-legacy) .mat-form-field-prefix .mat-icon,.mat-form-field:not(.mat-form-field-appearance-legacy) .mat-form-field-suffix .mat-icon{display:block}.mat-form-field:not(.mat-form-field-appearance-legacy) .mat-form-field-prefix .mat-icon-button .mat-icon,.mat-form-field:not(.mat-form-field-appearance-legacy) .mat-form-field-suffix .mat-icon-button .mat-icon{margin:auto}"],encapsulation:2,changeDetection:0})}return $e})(),ze=(()=>{class $e{static \u0275fac=function(Ze){return new(Ze||$e)};static \u0275mod=i.$C({type:$e});static \u0275inj=i.G2t({imports:[a.yE,a.yE]})}return $e})()},6389:(o,s,r)=>{"use strict";r.d(s,{fS:()=>pe,fg:()=>re});var i=r(3022),a=r(2147),c=r(708),y=r(3107),w=r(8559),C=r(936),T=r(2902),S=r(6071),M=r(8447);const L=new y.nKC("MAT_INPUT_VALUE_ACCESSOR"),Z=["button","checkbox","file","hidden","image","radio","range","reset","submit"],q=new y.nKC("MAT_INPUT_CONFIG");let re=(()=>{class se{_elementRef=(0,y.WQX)(y.aKT);_platform=(0,y.WQX)(a.OD);ngControl=(0,y.WQX)(C.vO,{optional:!0,self:!0});_autofillMonitor=(0,y.WQX)(c.P8);_ngZone=(0,y.WQX)(y.SKi);_formField=(0,y.WQX)(S.xb,{optional:!0});_uid=(0,y.WQX)(w.g7).getId("mat-input-");_previousNativeValue;_inputValueAccessor;_signalBasedValueAccessor;_previousPlaceholder;_errorStateTracker;_webkitBlinkWheelListenerAttached=!1;_config=(0,y.WQX)(q,{optional:!0});_formFieldDescribedBy;_isServer;_isNativeSelect;_isTextarea;_isInFormField;focused=!1;stateChanges=new M.B;controlType="mat-input";autofilled=!1;get disabled(){return this._disabled}set disabled(me){this._disabled=(0,i.he)(me),this.focused&&(this.focused=!1,this.stateChanges.next())}_disabled=!1;get id(){return this._id}set id(me){this._id=me||this._uid}_id;placeholder;name;get required(){return this._required??this.ngControl?.control?.hasValidator(C.k0.required)??!1}set required(me){this._required=(0,i.he)(me)}_required;get type(){return this._type}set type(me){this._type=me||"text",this._validateType(),!this._isTextarea&&(0,a.MU)().has(this._type)&&(this._elementRef.nativeElement.type=this._type),this._ensureWheelDefaultBehavior()}_type="text";get errorStateMatcher(){return this._errorStateTracker.matcher}set errorStateMatcher(me){this._errorStateTracker.matcher=me}userAriaDescribedBy;get value(){return this._signalBasedValueAccessor?this._signalBasedValueAccessor.value():this._inputValueAccessor.value}set value(me){me!==this.value&&(this._signalBasedValueAccessor?this._signalBasedValueAccessor.value.set(me):this._inputValueAccessor.value=me,this.stateChanges.next())}get readonly(){return this._readonly}set readonly(me){this._readonly=(0,i.he)(me)}_readonly=!1;disabledInteractive;get errorState(){return this._errorStateTracker.errorState}set errorState(me){this._errorStateTracker.errorState=me}_neverEmptyInputTypes=["date","datetime","datetime-local","month","time","week"].filter(me=>(0,a.MU)().has(me));constructor(){const me=(0,y.WQX)(C.cV,{optional:!0}),be=(0,y.WQX)(C.j4,{optional:!0}),Oe=(0,y.WQX)(T.es),xe=(0,y.WQX)(L,{optional:!0,self:!0}),De=this._elementRef.nativeElement,ce=De.nodeName.toLowerCase();xe?(0,y.Hps)(xe.value)?this._signalBasedValueAccessor=xe:this._inputValueAccessor=xe:this._inputValueAccessor=De,this._previousNativeValue=this.value,this.id=this.id,this._platform.IOS&&this._ngZone.runOutsideAngular(()=>{De.addEventListener("keyup",this._iOSKeyupListener)}),this._errorStateTracker=new T.X0(Oe,this.ngControl,be,me,this.stateChanges),this._isServer=!this._platform.isBrowser,this._isNativeSelect="select"===ce,this._isTextarea="textarea"===ce,this._isInFormField=!!this._formField,this.disabledInteractive=this._config?.disabledInteractive||!1,this._isNativeSelect&&(this.controlType=De.multiple?"mat-native-select-multiple":"mat-native-select"),this._signalBasedValueAccessor&&(0,y.QZP)(()=>{this._signalBasedValueAccessor.value(),this.stateChanges.next()})}ngAfterViewInit(){this._platform.isBrowser&&this._autofillMonitor.monitor(this._elementRef.nativeElement).subscribe(me=>{this.autofilled=me.isAutofilled,this.stateChanges.next()})}ngOnChanges(){this.stateChanges.next()}ngOnDestroy(){this.stateChanges.complete(),this._platform.isBrowser&&this._autofillMonitor.stopMonitoring(this._elementRef.nativeElement),this._platform.IOS&&this._elementRef.nativeElement.removeEventListener("keyup",this._iOSKeyupListener),this._webkitBlinkWheelListenerAttached&&this._elementRef.nativeElement.removeEventListener("wheel",this._webkitBlinkWheelListener)}ngDoCheck(){this.ngControl&&(this.updateErrorState(),null!==this.ngControl.disabled&&this.ngControl.disabled!==this.disabled&&(this.disabled=this.ngControl.disabled,this.stateChanges.next())),this._dirtyCheckNativeValue(),this._dirtyCheckPlaceholder()}focus(me){this._elementRef.nativeElement.focus(me)}updateErrorState(){this._errorStateTracker.updateErrorState()}_focusChanged(me){if(me!==this.focused){if(!this._isNativeSelect&&me&&this.disabled&&this.disabledInteractive){const be=this._elementRef.nativeElement;"number"===be.type?(be.type="text",be.setSelectionRange(0,0),be.type="number"):be.setSelectionRange(0,0)}this.focused=me,this.stateChanges.next()}}_onInput(){}_dirtyCheckNativeValue(){const me=this._elementRef.nativeElement.value;this._previousNativeValue!==me&&(this._previousNativeValue=me,this.stateChanges.next())}_dirtyCheckPlaceholder(){const me=this._getPlaceholder();if(me!==this._previousPlaceholder){const be=this._elementRef.nativeElement;this._previousPlaceholder=me,me?be.setAttribute("placeholder",me):be.removeAttribute("placeholder")}}_getPlaceholder(){return this.placeholder||null}_validateType(){Z.indexOf(this._type)}_isNeverEmpty(){return this._neverEmptyInputTypes.indexOf(this._type)>-1}_isBadInput(){let me=this._elementRef.nativeElement.validity;return me&&me.badInput}get empty(){return!(this._isNeverEmpty()||this._elementRef.nativeElement.value||this._isBadInput()||this.autofilled)}get shouldLabelFloat(){if(this._isNativeSelect){const me=this._elementRef.nativeElement,be=me.options[0];return this.focused||me.multiple||!this.empty||!!(me.selectedIndex>-1&&be&&be.label)}return this.focused&&!this.disabled||!this.empty}setDescribedByIds(me){const be=this._elementRef.nativeElement,Oe=be.getAttribute("aria-describedby");let xe;if(Oe){const De=this._formFieldDescribedBy||me;xe=me.concat(Oe.split(" ").filter(ce=>ce&&!De.includes(ce)))}else xe=me;this._formFieldDescribedBy=me,xe.length?be.setAttribute("aria-describedby",xe.join(" ")):be.removeAttribute("aria-describedby")}onContainerClick(){this.focused||this.focus()}_isInlineSelect(){const me=this._elementRef.nativeElement;return this._isNativeSelect&&(me.multiple||me.size>1)}_iOSKeyupListener=me=>{const be=me.target;!be.value&&0===be.selectionStart&&0===be.selectionEnd&&(be.setSelectionRange(1,1),be.setSelectionRange(0,0))};_webkitBlinkWheelListener=()=>{};_ensureWheelDefaultBehavior(){!this._webkitBlinkWheelListenerAttached&&"number"===this._type&&(this._platform.BLINK||this._platform.WEBKIT)&&(this._ngZone.runOutsideAngular(()=>{this._elementRef.nativeElement.addEventListener("wheel",this._webkitBlinkWheelListener)}),this._webkitBlinkWheelListenerAttached=!0),this._webkitBlinkWheelListenerAttached&&"number"!==this._type&&(this._elementRef.nativeElement.removeEventListener("wheel",this._webkitBlinkWheelListener),this._webkitBlinkWheelListenerAttached=!0)}_getReadonlyAttribute(){return this._isNativeSelect?null:this.readonly||this.disabled&&this.disabledInteractive?"true":null}static \u0275fac=function(be){return new(be||se)};static \u0275dir=y.FsC({type:se,selectors:[["input","matInput",""],["textarea","matInput",""],["select","matNativeControl",""],["input","matNativeControl",""],["textarea","matNativeControl",""]],hostAttrs:[1,"mat-mdc-input-element"],hostVars:21,hostBindings:function(be,Oe){1&be&&y.bIt("focus",function(){return Oe._focusChanged(!0)})("blur",function(){return Oe._focusChanged(!1)})("input",function(){return Oe._onInput()}),2&be&&(y.Mr5("id",Oe.id)("disabled",Oe.disabled&&!Oe.disabledInteractive)("required",Oe.required),y.BMQ("name",Oe.name||null)("readonly",Oe._getReadonlyAttribute())("aria-disabled",Oe.disabled&&Oe.disabledInteractive?"true":null)("aria-invalid",Oe.empty&&Oe.required?null:Oe.errorState)("aria-required",Oe.required)("id",Oe.id),y.AVh("mat-input-server",Oe._isServer)("mat-mdc-form-field-textarea-control",Oe._isInFormField&&Oe._isTextarea)("mat-mdc-form-field-input-control",Oe._isInFormField)("mat-mdc-input-disabled-interactive",Oe.disabledInteractive)("mdc-text-field__input",Oe._isInFormField)("mat-mdc-native-select-inline",Oe._isInlineSelect()))},inputs:{disabled:"disabled",id:"id",placeholder:"placeholder",name:"name",required:"required",type:"type",errorStateMatcher:"errorStateMatcher",userAriaDescribedBy:[0,"aria-describedby","userAriaDescribedBy"],value:"value",readonly:"readonly",disabledInteractive:[2,"disabledInteractive","disabledInteractive",y.L39]},exportAs:["matInput"],features:[y.Jv_([{provide:S.qT,useExisting:se}]),y.GFd,y.OA$]})}return se})(),pe=(()=>{class se{static \u0275fac=function(be){return new(be||se)};static \u0275mod=y.$C({type:se});static \u0275inj=y.G2t({imports:[T.yE,S.RG,S.RG,c.EE,T.yE]})}return se})()},7818:(o,s,r)=>{"use strict";r.d(s,{Cn:()=>Xt,Cp:()=>st,fb:()=>rn,kk:()=>Ze});var i=r(3107),a=r(8559),c=r(5919),y=r(8447),w=r(7509),C=r(5710),T=r(3016),S=r(4984),M=r(593),O=r(2867),L=r(5424),Z=r(1483),q=r(7610),re=r(8136),pe=r(4460),se=r(2902),ae=r(5467),me=r(6192),be=r(1204),Oe=r(2944),xe=r(9666),De=r(2147),ce=r(8108);const ue=["mat-menu-item",""],Ce=[[["mat-icon"],["","matMenuItemIcon",""]],"*"],Be=["mat-icon, [matMenuItemIcon]","*"];function at(Mt,Kt){1&Mt&&(i.qSk(),i.j41(0,"svg",2),i.nrm(1,"polygon",3),i.k0s())}const dt=["*"];function bt(Mt,Kt){if(1&Mt){const rt=i.RV6();i.j41(0,"div",0),i.bIt("click",function(){i.eBV(rt);const en=i.XpG();return i.Njj(en.closed.emit("click"))})("@transformMenu.start",function(en){i.eBV(rt);const kn=i.XpG();return i.Njj(kn._onAnimationStart(en))})("@transformMenu.done",function(en){i.eBV(rt);const kn=i.XpG();return i.Njj(kn._onAnimationDone(en))}),i.j41(1,"div",1),i.SdG(2),i.k0s()()}if(2&Mt){const rt=i.XpG();i.HbH(rt._classList),i.Y8G("id",rt.panelId)("@transformMenu",rt._panelAnimationState),i.BMQ("aria-label",rt.ariaLabel||null)("aria-labelledby",rt.ariaLabelledby||null)("aria-describedby",rt.ariaDescribedby||null)}}const lt=new i.nKC("MAT_MENU_PANEL");let rn=(()=>{class Mt{_elementRef=(0,i.WQX)(i.aKT);_document=(0,i.WQX)(pe.qQ);_focusMonitor=(0,i.WQX)(a.FN);_parentMenu=(0,i.WQX)(lt,{optional:!0});_changeDetectorRef=(0,i.WQX)(i.gRc);role="menuitem";disabled=!1;disableRipple=!1;_hovered=new y.B;_focused=new y.B;_highlighted=!1;_triggersSubmenu=!1;constructor(){(0,i.WQX)(ae.l).load(se.Ah),this._parentMenu?.addItem?.(this)}focus(rt,Vt){this._focusMonitor&&rt?this._focusMonitor.focusVia(this._getHostElement(),rt,Vt):this._getHostElement().focus(Vt),this._focused.next(this)}ngAfterViewInit(){this._focusMonitor&&this._focusMonitor.monitor(this._elementRef,!1)}ngOnDestroy(){this._focusMonitor&&this._focusMonitor.stopMonitoring(this._elementRef),this._parentMenu&&this._parentMenu.removeItem&&this._parentMenu.removeItem(this),this._hovered.complete(),this._focused.complete()}_getTabIndex(){return this.disabled?"-1":"0"}_getHostElement(){return this._elementRef.nativeElement}_checkDisabled(rt){this.disabled&&(rt.preventDefault(),rt.stopPropagation())}_handleMouseEnter(){this._hovered.next(this)}getLabel(){const rt=this._elementRef.nativeElement.cloneNode(!0),Vt=rt.querySelectorAll("mat-icon, .material-icons");for(let en=0;en enter",(0,be.i0)("120ms cubic-bezier(0, 0, 0.2, 1)",(0,be.iF)({opacity:1,transform:"scale(1)"}))),(0,be.kY)("* => void",(0,be.i0)("100ms 25ms linear",(0,be.iF)({opacity:0})))]),fadeInItems:(0,be.hZ)("fadeInItems",[(0,be.wk)("showing",(0,be.iF)({opacity:1})),(0,be.kY)("void => *",[(0,be.iF)({opacity:0}),(0,be.i0)("400ms 100ms cubic-bezier(0.55, 0, 0.55, 0.2)")])])},Ft=new i.nKC("mat-menu-default-options",{providedIn:"root",factory:function Ke(){return{overlapTrigger:!1,xPosition:"after",yPosition:"below",backdropClass:"cdk-overlay-transparent-backdrop"}}});let Ze=(()=>{class Mt{_elementRef=(0,i.WQX)(i.aKT);_changeDetectorRef=(0,i.WQX)(i.gRc);_keyManager;_xPosition;_yPosition;_firstItemFocusRef;_allItems;_directDescendantItems=new i.rOR;_classList={};_panelAnimationState="void";_animationDone=new y.B;_isAnimating;parentMenu;direction;overlayPanelClass;backdropClass;ariaLabel;ariaLabelledby;ariaDescribedby;get xPosition(){return this._xPosition}set xPosition(rt){this._xPosition=rt,this.setPositionClasses()}get yPosition(){return this._yPosition}set yPosition(rt){this._yPosition=rt,this.setPositionClasses()}templateRef;items;lazyContent;overlapTrigger;hasBackdrop;set panelClass(rt){const Vt=this._previousPanelClass,en={...this._classList};Vt&&Vt.length&&Vt.split(" ").forEach(kn=>{en[kn]=!1}),this._previousPanelClass=rt,rt&&rt.length&&(rt.split(" ").forEach(kn=>{en[kn]=!0}),this._elementRef.nativeElement.className=""),this._classList=en}_previousPanelClass;get classList(){return this.panelClass}set classList(rt){this.panelClass=rt}closed=new i.bkB;close=this.closed;panelId=(0,i.WQX)(a.g7).getId("mat-menu-panel-");_injector=(0,i.WQX)(i.zZn);constructor(){const rt=(0,i.WQX)(Ft);this.overlayPanelClass=rt.overlayPanelClass||"",this._xPosition=rt.xPosition,this._yPosition=rt.yPosition,this.backdropClass=rt.backdropClass,this.overlapTrigger=rt.overlapTrigger,this.hasBackdrop=rt.hasBackdrop}ngOnInit(){this.setPositionClasses()}ngAfterContentInit(){this._updateDirectDescendants(),this._keyManager=new a.Bu(this._directDescendantItems).withWrap().withTypeAhead().withHomeAndEnd(),this._keyManager.tabOut.subscribe(()=>this.closed.emit("tab")),this._directDescendantItems.changes.pipe((0,M.Z)(this._directDescendantItems),(0,O.n)(rt=>(0,w.h)(...rt.map(Vt=>Vt._focused)))).subscribe(rt=>this._keyManager.updateActiveItem(rt)),this._directDescendantItems.changes.subscribe(rt=>{const Vt=this._keyManager;if("enter"===this._panelAnimationState&&Vt.activeItem?._hasFocus()){const en=rt.toArray(),kn=Math.max(0,Math.min(en.length-1,Vt.activeItemIndex||0));en[kn]&&!en[kn].disabled?Vt.setActiveItem(kn):Vt.setNextItemActive()}})}ngOnDestroy(){this._keyManager?.destroy(),this._directDescendantItems.destroy(),this.closed.complete(),this._firstItemFocusRef?.destroy()}_hovered(){return this._directDescendantItems.changes.pipe((0,M.Z)(this._directDescendantItems),(0,O.n)(Vt=>(0,w.h)(...Vt.map(en=>en._hovered))))}addItem(rt){}removeItem(rt){}_handleKeydown(rt){const Vt=rt.keyCode,en=this._keyManager;switch(Vt){case c._f:(0,c.rp)(rt)||(rt.preventDefault(),this.closed.emit("keydown"));break;case c.UQ:this.parentMenu&&"ltr"===this.direction&&this.closed.emit("keydown");break;case c.LE:this.parentMenu&&"rtl"===this.direction&&this.closed.emit("keydown");break;default:return(Vt===c.i7||Vt===c.n6)&&en.setFocusOrigin("keyboard"),void en.onKeydown(rt)}}focusFirstItem(rt="program"){this._firstItemFocusRef?.destroy(),this._firstItemFocusRef=(0,i.mal)(()=>{let Vt=null;if(this._directDescendantItems.length&&(Vt=this._directDescendantItems.first._getHostElement().closest('[role="menu"]')),!Vt||!Vt.contains(document.activeElement)){const en=this._keyManager;en.setFocusOrigin(rt).setFirstItemActive(),!en.activeItem&&Vt&&Vt.focus()}},{injector:this._injector})}resetActiveItem(){this._keyManager.setActiveItem(-1)}setElevation(rt){}setPositionClasses(rt=this.xPosition,Vt=this.yPosition){this._classList={...this._classList,"mat-menu-before":"before"===rt,"mat-menu-after":"after"===rt,"mat-menu-above":"above"===Vt,"mat-menu-below":"below"===Vt},this._changeDetectorRef.markForCheck()}_startAnimation(){this._panelAnimationState="enter"}_resetAnimation(){this._panelAnimationState="void"}_onAnimationDone(rt){this._animationDone.next(rt),this._isAnimating=!1}_onAnimationStart(rt){this._isAnimating=!0,"enter"===rt.toState&&0===this._keyManager.activeItemIndex&&(rt.element.scrollTop=0)}_updateDirectDescendants(){this._allItems.changes.pipe((0,M.Z)(this._allItems)).subscribe(rt=>{this._directDescendantItems.reset(rt.filter(Vt=>Vt._parentMenu===this)),this._directDescendantItems.notifyOnChanges()})}static \u0275fac=function(Vt){return new(Vt||Mt)};static \u0275cmp=i.VBU({type:Mt,selectors:[["mat-menu"]],contentQueries:function(Vt,en,kn){if(1&Vt&&(i.wni(kn,yn,5),i.wni(kn,rn,5),i.wni(kn,rn,4)),2&Vt){let Kn;i.mGM(Kn=i.lsd())&&(en.lazyContent=Kn.first),i.mGM(Kn=i.lsd())&&(en._allItems=Kn),i.mGM(Kn=i.lsd())&&(en.items=Kn)}},viewQuery:function(Vt,en){if(1&Vt&&i.GBs(i.C4Q,5),2&Vt){let kn;i.mGM(kn=i.lsd())&&(en.templateRef=kn.first)}},hostVars:3,hostBindings:function(Vt,en){2&Vt&&i.BMQ("aria-label",null)("aria-labelledby",null)("aria-describedby",null)},inputs:{backdropClass:"backdropClass",ariaLabel:[0,"aria-label","ariaLabel"],ariaLabelledby:[0,"aria-labelledby","ariaLabelledby"],ariaDescribedby:[0,"aria-describedby","ariaDescribedby"],xPosition:"xPosition",yPosition:"yPosition",overlapTrigger:[2,"overlapTrigger","overlapTrigger",i.L39],hasBackdrop:[2,"hasBackdrop","hasBackdrop",rt=>null==rt?null:(0,i.L39)(rt)],panelClass:[0,"class","panelClass"],classList:"classList"},outputs:{closed:"closed",close:"close"},exportAs:["matMenu"],features:[i.Jv_([{provide:lt,useExisting:Mt}]),i.GFd],ngContentSelectors:dt,decls:1,vars:0,consts:[["tabindex","-1","role","menu",1,"mat-mdc-menu-panel",3,"click","id"],[1,"mat-mdc-menu-content"]],template:function(Vt,en){1&Vt&&(i.NAR(),i.DNE(0,bt,3,7,"ng-template"))},styles:['mat-menu{display:none}.mat-mdc-menu-content{margin:0;padding:8px 0;outline:0}.mat-mdc-menu-content,.mat-mdc-menu-content .mat-mdc-menu-item .mat-mdc-menu-item-text{-moz-osx-font-smoothing:grayscale;-webkit-font-smoothing:antialiased;flex:1;white-space:normal;font-family:var(--mat-menu-item-label-text-font, var(--mat-sys-label-large-font));line-height:var(--mat-menu-item-label-text-line-height, var(--mat-sys-label-large-line-height));font-size:var(--mat-menu-item-label-text-size, var(--mat-sys-label-large-size));letter-spacing:var(--mat-menu-item-label-text-tracking, var(--mat-sys-label-large-tracking));font-weight:var(--mat-menu-item-label-text-weight, var(--mat-sys-label-large-weight))}.mat-mdc-menu-panel{min-width:112px;max-width:280px;overflow:auto;-webkit-overflow-scrolling:touch;box-sizing:border-box;outline:0;border-radius:var(--mat-menu-container-shape, var(--mat-sys-corner-extra-small));background-color:var(--mat-menu-container-color, var(--mat-sys-surface-container));box-shadow:var(--mat-menu-container-elevation-shadow, 0px 3px 1px -2px rgba(0, 0, 0, 0.2), 0px 2px 2px 0px rgba(0, 0, 0, 0.14), 0px 1px 5px 0px rgba(0, 0, 0, 0.12));will-change:transform,opacity}.mat-mdc-menu-panel.ng-animating{pointer-events:none}.mat-mdc-menu-panel.ng-animating:has(.mat-mdc-menu-content:empty){display:none}@media(forced-colors: active){.mat-mdc-menu-panel{outline:solid 1px}}.mat-mdc-menu-panel .mat-divider{color:var(--mat-menu-divider-color, var(--mat-sys-surface-variant));margin-bottom:var(--mat-menu-divider-bottom-spacing, 8px);margin-top:var(--mat-menu-divider-top-spacing, 8px)}.mat-mdc-menu-item{display:flex;position:relative;align-items:center;justify-content:flex-start;overflow:hidden;padding:0;cursor:pointer;width:100%;text-align:left;box-sizing:border-box;color:inherit;font-size:inherit;background:none;text-decoration:none;margin:0;min-height:48px;padding-left:var(--mat-menu-item-leading-spacing, 12px);padding-right:var(--mat-menu-item-trailing-spacing, 12px);-webkit-user-select:none;user-select:none;cursor:pointer;outline:none;border:none;-webkit-tap-highlight-color:rgba(0,0,0,0)}.mat-mdc-menu-item::-moz-focus-inner{border:0}[dir=rtl] .mat-mdc-menu-item{padding-left:var(--mat-menu-item-trailing-spacing, 12px);padding-right:var(--mat-menu-item-leading-spacing, 12px)}.mat-mdc-menu-item:has(.material-icons,mat-icon,[matButtonIcon]){padding-left:var(--mat-menu-item-with-icon-leading-spacing, 12px);padding-right:var(--mat-menu-item-with-icon-trailing-spacing, 12px)}[dir=rtl] .mat-mdc-menu-item:has(.material-icons,mat-icon,[matButtonIcon]){padding-left:var(--mat-menu-item-with-icon-trailing-spacing, 12px);padding-right:var(--mat-menu-item-with-icon-leading-spacing, 12px)}.mat-mdc-menu-item,.mat-mdc-menu-item:visited,.mat-mdc-menu-item:link{color:var(--mat-menu-item-label-text-color, var(--mat-sys-on-surface))}.mat-mdc-menu-item .mat-icon-no-color,.mat-mdc-menu-item .mat-mdc-menu-submenu-icon{color:var(--mat-menu-item-icon-color, var(--mat-sys-on-surface-variant))}.mat-mdc-menu-item[disabled]{cursor:default;opacity:.38}.mat-mdc-menu-item[disabled]::after{display:block;position:absolute;content:"";top:0;left:0;bottom:0;right:0}.mat-mdc-menu-item:focus{outline:0}.mat-mdc-menu-item .mat-icon{flex-shrink:0;margin-right:var(--mat-menu-item-spacing, 12px);height:var(--mat-menu-item-icon-size, 24px);width:var(--mat-menu-item-icon-size, 24px)}[dir=rtl] .mat-mdc-menu-item{text-align:right}[dir=rtl] .mat-mdc-menu-item .mat-icon{margin-right:0;margin-left:var(--mat-menu-item-spacing, 12px)}.mat-mdc-menu-item:not([disabled]):hover{background-color:var(--mat-menu-item-hover-state-layer-color, color-mix(in srgb, var(--mat-sys-on-surface) calc(var(--mat-sys-hover-state-layer-opacity) * 100%), transparent))}.mat-mdc-menu-item:not([disabled]).cdk-program-focused,.mat-mdc-menu-item:not([disabled]).cdk-keyboard-focused,.mat-mdc-menu-item:not([disabled]).mat-mdc-menu-item-highlighted{background-color:var(--mat-menu-item-focus-state-layer-color, color-mix(in srgb, var(--mat-sys-on-surface) calc(var(--mat-sys-focus-state-layer-opacity) * 100%), transparent))}@media(forced-colors: active){.mat-mdc-menu-item{margin-top:1px}}.mat-mdc-menu-submenu-icon{width:var(--mat-menu-item-icon-size, 24px);height:10px;fill:currentColor;padding-left:var(--mat-menu-item-spacing, 12px)}[dir=rtl] .mat-mdc-menu-submenu-icon{padding-right:var(--mat-menu-item-spacing, 12px);padding-left:0}[dir=rtl] .mat-mdc-menu-submenu-icon polygon{transform:scaleX(-1);transform-origin:center}@media(forced-colors: active){.mat-mdc-menu-submenu-icon{fill:CanvasText}}.mat-mdc-menu-item .mat-mdc-menu-ripple{top:0;left:0;right:0;bottom:0;position:absolute;pointer-events:none}'],encapsulation:2,data:{animation:[_t.transformMenu,_t.fadeInItems]},changeDetection:0})}return Mt})();const it=new i.nKC("mat-menu-scroll-strategy",{providedIn:"root",factory:()=>{const Mt=(0,i.WQX)(xe.hJ);return()=>Mt.scrollStrategies.reposition()}}),$t={provide:it,deps:[xe.hJ],useFactory:function Ot(Mt){return()=>Mt.scrollStrategies.reposition()}},Te=(0,De.BQ)({passive:!0});let st=(()=>{class Mt{_overlay=(0,i.WQX)(xe.hJ);_element=(0,i.WQX)(i.aKT);_viewContainerRef=(0,i.WQX)(i.c1b);_menuItemInstance=(0,i.WQX)(rn,{optional:!0,self:!0});_dir=(0,i.WQX)(Oe.dS,{optional:!0});_focusMonitor=(0,i.WQX)(a.FN);_ngZone=(0,i.WQX)(i.SKi);_scrollStrategy=(0,i.WQX)(it);_changeDetectorRef=(0,i.WQX)(i.gRc);_portal;_overlayRef=null;_menuOpen=!1;_closingActionsSubscription=C.yU.EMPTY;_hoverSubscription=C.yU.EMPTY;_menuCloseSubscription=C.yU.EMPTY;_parentMaterialMenu;_parentInnerPadding;_handleTouchStart=rt=>{(0,a.w6)(rt)||(this._openedBy="touch")};_openedBy=void 0;get _deprecatedMatMenuTriggerFor(){return this.menu}set _deprecatedMatMenuTriggerFor(rt){this.menu=rt}get menu(){return this._menu}set menu(rt){rt!==this._menu&&(this._menu=rt,this._menuCloseSubscription.unsubscribe(),rt&&(this._menuCloseSubscription=rt.close.subscribe(Vt=>{this._destroyMenu(Vt),("click"===Vt||"tab"===Vt)&&this._parentMaterialMenu&&this._parentMaterialMenu.closed.emit(Vt)})),this._menuItemInstance?._setTriggersSubmenu(this.triggersSubmenu()))}_menu;menuData;restoreFocus=!0;menuOpened=new i.bkB;onMenuOpen=this.menuOpened;menuClosed=new i.bkB;onMenuClose=this.menuClosed;constructor(){const rt=(0,i.WQX)(lt,{optional:!0});this._parentMaterialMenu=rt instanceof Ze?rt:void 0,this._element.nativeElement.addEventListener("touchstart",this._handleTouchStart,Te)}ngAfterContentInit(){this._handleHover()}ngOnDestroy(){this._overlayRef&&(this._overlayRef.dispose(),this._overlayRef=null),this._element.nativeElement.removeEventListener("touchstart",this._handleTouchStart,Te),this._menuCloseSubscription.unsubscribe(),this._closingActionsSubscription.unsubscribe(),this._hoverSubscription.unsubscribe()}get menuOpen(){return this._menuOpen}get dir(){return this._dir&&"rtl"===this._dir.value?"rtl":"ltr"}triggersSubmenu(){return!!(this._menuItemInstance&&this._parentMaterialMenu&&this.menu)}toggleMenu(){return this._menuOpen?this.closeMenu():this.openMenu()}openMenu(){const rt=this.menu;if(this._menuOpen||!rt)return;const Vt=this._createOverlay(rt),en=Vt.getConfig(),kn=en.positionStrategy;this._setPosition(rt,kn),en.hasBackdrop=null==rt.hasBackdrop?!this.triggersSubmenu():rt.hasBackdrop,Vt.attach(this._getPortal(rt)),rt.lazyContent&&rt.lazyContent.attach(this.menuData),this._closingActionsSubscription=this._menuClosingActions().subscribe(()=>this.closeMenu()),this._initMenu(rt),rt instanceof Ze&&(rt._startAnimation(),rt._directDescendantItems.changes.pipe((0,L.Q)(rt.close)).subscribe(()=>{kn.withLockedPosition(!1).reapplyLastPosition(),kn.withLockedPosition(!0)}))}closeMenu(){this.menu?.close.emit()}focus(rt,Vt){this._focusMonitor&&rt?this._focusMonitor.focusVia(this._element,rt,Vt):this._element.nativeElement.focus(Vt)}updatePosition(){this._overlayRef?.updatePosition()}_destroyMenu(rt){if(!this._overlayRef||!this.menuOpen)return;const Vt=this.menu;this._closingActionsSubscription.unsubscribe(),this._overlayRef.detach(),this.restoreFocus&&("keydown"===rt||!this._openedBy||!this.triggersSubmenu())&&this.focus(this._openedBy),this._openedBy=void 0,Vt instanceof Ze?(Vt._resetAnimation(),Vt.lazyContent?Vt._animationDone.pipe((0,Z.p)(en=>"void"===en.toState),(0,q.s)(1),(0,L.Q)(Vt.lazyContent._attached)).subscribe({next:()=>Vt.lazyContent.detach(),complete:()=>this._setIsMenuOpen(!1)}):this._setIsMenuOpen(!1)):(this._setIsMenuOpen(!1),Vt?.lazyContent?.detach())}_initMenu(rt){rt.parentMenu=this.triggersSubmenu()?this._parentMaterialMenu:void 0,rt.direction=this.dir,rt.focusFirstItem(this._openedBy||"program"),this._setIsMenuOpen(!0)}_setIsMenuOpen(rt){rt!==this._menuOpen&&(this._menuOpen=rt,this._menuOpen?this.menuOpened.emit():this.menuClosed.emit(),this.triggersSubmenu()&&this._menuItemInstance._setHighlighted(rt),this._changeDetectorRef.markForCheck())}_createOverlay(rt){if(!this._overlayRef){const Vt=this._getOverlayConfig(rt);this._subscribeToPositions(rt,Vt.positionStrategy),this._overlayRef=this._overlay.create(Vt),this._overlayRef.keydownEvents().subscribe(en=>{this.menu instanceof Ze&&this.menu._handleKeydown(en)})}return this._overlayRef}_getOverlayConfig(rt){return new xe.rR({positionStrategy:this._overlay.position().flexibleConnectedTo(this._element).withLockedPosition().withGrowAfterOpen().withTransformOriginOn(".mat-menu-panel, .mat-mdc-menu-panel"),backdropClass:rt.backdropClass||"cdk-overlay-transparent-backdrop",panelClass:rt.overlayPanelClass,scrollStrategy:this._scrollStrategy(),direction:this._dir||"ltr"})}_subscribeToPositions(rt,Vt){rt.setPositionClasses&&Vt.positionChanges.subscribe(en=>{this._ngZone.run(()=>{rt.setPositionClasses("start"===en.connectionPair.overlayX?"after":"before","top"===en.connectionPair.overlayY?"below":"above")})})}_setPosition(rt,Vt){let[en,kn]="before"===rt.xPosition?["end","start"]:["start","end"],[Kn,Nr]="above"===rt.yPosition?["bottom","top"]:["top","bottom"],[Rn,pr]=[Kn,Nr],[cn,Fe]=[en,kn],ke=0;if(this.triggersSubmenu()){if(Fe=en="before"===rt.xPosition?"start":"end",kn=cn="end"===en?"start":"end",this._parentMaterialMenu){if(null==this._parentInnerPadding){const Je=this._parentMaterialMenu.items.first;this._parentInnerPadding=Je?Je._getHostElement().offsetTop:0}ke="bottom"===Kn?this._parentInnerPadding:-this._parentInnerPadding}}else rt.overlapTrigger||(Rn="top"===Kn?"bottom":"top",pr="top"===Nr?"bottom":"top");Vt.withPositions([{originX:en,originY:Rn,overlayX:cn,overlayY:Kn,offsetY:ke},{originX:kn,originY:Rn,overlayX:Fe,overlayY:Kn,offsetY:ke},{originX:en,originY:pr,overlayX:cn,overlayY:Nr,offsetY:-ke},{originX:kn,originY:pr,overlayX:Fe,overlayY:Nr,offsetY:-ke}])}_menuClosingActions(){const rt=this._overlayRef.backdropClick(),Vt=this._overlayRef.detachments(),en=this._parentMaterialMenu?this._parentMaterialMenu.closed:(0,T.of)(),kn=this._parentMaterialMenu?this._parentMaterialMenu._hovered().pipe((0,Z.p)(Kn=>Kn!==this._menuItemInstance),(0,Z.p)(()=>this._menuOpen)):(0,T.of)();return(0,w.h)(rt,en,kn,Vt)}_handleMousedown(rt){(0,a._G)(rt)||(this._openedBy=0===rt.button?"mouse":void 0,this.triggersSubmenu()&&rt.preventDefault())}_handleKeydown(rt){const Vt=rt.keyCode;(Vt===c.Fm||Vt===c.t6)&&(this._openedBy="keyboard"),this.triggersSubmenu()&&(Vt===c.LE&&"ltr"===this.dir||Vt===c.UQ&&"rtl"===this.dir)&&(this._openedBy="keyboard",this.openMenu())}_handleClick(rt){this.triggersSubmenu()?(rt.stopPropagation(),this.openMenu()):this.toggleMenu()}_handleHover(){!this.triggersSubmenu()||!this._parentMaterialMenu||(this._hoverSubscription=this._parentMaterialMenu._hovered().pipe((0,Z.p)(rt=>rt===this._menuItemInstance&&!rt.disabled),(0,re.c)(0,S.$)).subscribe(()=>{this._openedBy="mouse",this.menu instanceof Ze&&this.menu._isAnimating?this.menu._animationDone.pipe((0,q.s)(1),(0,re.c)(0,S.$),(0,L.Q)(this._parentMaterialMenu._hovered())).subscribe(()=>this.openMenu()):this.openMenu()}))}_getPortal(rt){return(!this._portal||this._portal.templateRef!==rt.templateRef)&&(this._portal=new me.VA(rt.templateRef,this._viewContainerRef)),this._portal}static \u0275fac=function(Vt){return new(Vt||Mt)};static \u0275dir=i.FsC({type:Mt,selectors:[["","mat-menu-trigger-for",""],["","matMenuTriggerFor",""]],hostAttrs:[1,"mat-mdc-menu-trigger"],hostVars:3,hostBindings:function(Vt,en){1&Vt&&i.bIt("click",function(Kn){return en._handleClick(Kn)})("mousedown",function(Kn){return en._handleMousedown(Kn)})("keydown",function(Kn){return en._handleKeydown(Kn)}),2&Vt&&i.BMQ("aria-haspopup",en.menu?"menu":null)("aria-expanded",en.menuOpen)("aria-controls",en.menuOpen?en.menu.panelId:null)},inputs:{_deprecatedMatMenuTriggerFor:[0,"mat-menu-trigger-for","_deprecatedMatMenuTriggerFor"],menu:[0,"matMenuTriggerFor","menu"],menuData:[0,"matMenuTriggerData","menuData"],restoreFocus:[0,"matMenuTriggerRestoreFocus","restoreFocus"]},outputs:{menuOpened:"menuOpened",onMenuOpen:"onMenuOpen",menuClosed:"menuClosed",onMenuClose:"onMenuClose"},exportAs:["matMenuTrigger"]})}return Mt})(),Xt=(()=>{class Mt{static \u0275fac=function(Vt){return new(Vt||Mt)};static \u0275mod=i.$C({type:Mt});static \u0275inj=i.G2t({providers:[$t],imports:[se.pZ,se.yE,xe.z_,ce.Gj,se.yE]})}return Mt})()},2322:(o,s,r)=>{"use strict";r.d(s,{HM:()=>S,PO:()=>O});var i=r(3107),c=(r(4460),r(2902));function y(L,Z){1&L&&i.nrm(0,"div",2)}const w=new i.nKC("MAT_PROGRESS_BAR_DEFAULT_OPTIONS");let S=(()=>{class L{_elementRef=(0,i.WQX)(i.aKT);_ngZone=(0,i.WQX)(i.SKi);_changeDetectorRef=(0,i.WQX)(i.gRc);_animationMode=(0,i.WQX)(i.bc$,{optional:!0});constructor(){const q=(0,i.WQX)(w,{optional:!0});this._isNoopAnimation="NoopAnimations"===this._animationMode,q&&(q.color&&(this.color=this._defaultColor=q.color),this.mode=q.mode||this.mode)}_isNoopAnimation=!1;get color(){return this._color||this._defaultColor}set color(q){this._color=q}_color;_defaultColor="primary";get value(){return this._value}set value(q){this._value=M(q||0),this._changeDetectorRef.markForCheck()}_value=0;get bufferValue(){return this._bufferValue||0}set bufferValue(q){this._bufferValue=M(q||0),this._changeDetectorRef.markForCheck()}_bufferValue=0;animationEnd=new i.bkB;get mode(){return this._mode}set mode(q){this._mode=q,this._changeDetectorRef.markForCheck()}_mode="determinate";ngAfterViewInit(){this._ngZone.runOutsideAngular(()=>{this._elementRef.nativeElement.addEventListener("transitionend",this._transitionendHandler)})}ngOnDestroy(){this._elementRef.nativeElement.removeEventListener("transitionend",this._transitionendHandler)}_getPrimaryBarTransform(){return`scaleX(${this._isIndeterminate()?1:this.value/100})`}_getBufferBarFlexBasis(){return`${"buffer"===this.mode?this.bufferValue:100}%`}_isIndeterminate(){return"indeterminate"===this.mode||"query"===this.mode}_transitionendHandler=q=>{0===this.animationEnd.observers.length||!q.target||!q.target.classList.contains("mdc-linear-progress__primary-bar")||("determinate"===this.mode||"buffer"===this.mode)&&this._ngZone.run(()=>this.animationEnd.next({value:this.value}))};static \u0275fac=function(re){return new(re||L)};static \u0275cmp=i.VBU({type:L,selectors:[["mat-progress-bar"]],hostAttrs:["role","progressbar","aria-valuemin","0","aria-valuemax","100","tabindex","-1",1,"mat-mdc-progress-bar","mdc-linear-progress"],hostVars:10,hostBindings:function(re,pe){2&re&&(i.BMQ("aria-valuenow",pe._isIndeterminate()?null:pe.value)("mode",pe.mode),i.HbH("mat-"+pe.color),i.AVh("_mat-animation-noopable",pe._isNoopAnimation)("mdc-linear-progress--animation-ready",!pe._isNoopAnimation)("mdc-linear-progress--indeterminate",pe._isIndeterminate()))},inputs:{color:"color",value:[2,"value","value",i.Udg],bufferValue:[2,"bufferValue","bufferValue",i.Udg],mode:"mode"},outputs:{animationEnd:"animationEnd"},exportAs:["matProgressBar"],features:[i.GFd],decls:7,vars:5,consts:[["aria-hidden","true",1,"mdc-linear-progress__buffer"],[1,"mdc-linear-progress__buffer-bar"],[1,"mdc-linear-progress__buffer-dots"],["aria-hidden","true",1,"mdc-linear-progress__bar","mdc-linear-progress__primary-bar"],[1,"mdc-linear-progress__bar-inner"],["aria-hidden","true",1,"mdc-linear-progress__bar","mdc-linear-progress__secondary-bar"]],template:function(re,pe){1&re&&(i.j41(0,"div",0),i.nrm(1,"div",1),i.DNE(2,y,1,0,"div",2),i.k0s(),i.j41(3,"div",3),i.nrm(4,"span",4),i.k0s(),i.j41(5,"div",5),i.nrm(6,"span",4),i.k0s()),2&re&&(i.R7$(),i.xc7("flex-basis",pe._getBufferBarFlexBasis()),i.R7$(),i.vxM("buffer"===pe.mode?2:-1),i.R7$(),i.xc7("transform",pe._getPrimaryBarTransform()))},styles:[".mat-mdc-progress-bar{display:block;text-align:start}.mat-mdc-progress-bar[mode=query]{transform:scaleX(-1)}.mat-mdc-progress-bar._mat-animation-noopable .mdc-linear-progress__buffer-dots,.mat-mdc-progress-bar._mat-animation-noopable .mdc-linear-progress__primary-bar,.mat-mdc-progress-bar._mat-animation-noopable .mdc-linear-progress__secondary-bar,.mat-mdc-progress-bar._mat-animation-noopable .mdc-linear-progress__bar-inner.mdc-linear-progress__bar-inner{animation:none}.mat-mdc-progress-bar._mat-animation-noopable .mdc-linear-progress__primary-bar,.mat-mdc-progress-bar._mat-animation-noopable .mdc-linear-progress__buffer-bar{transition:transform 1ms}.mdc-linear-progress{position:relative;width:100%;transform:translateZ(0);outline:1px solid rgba(0,0,0,0);overflow-x:hidden;transition:opacity 250ms 0ms cubic-bezier(0.4, 0, 0.6, 1);height:max(var(--mdc-linear-progress-track-height, 4px),var(--mdc-linear-progress-active-indicator-height, 4px))}@media(forced-colors: active){.mdc-linear-progress{outline-color:CanvasText}}.mdc-linear-progress__bar{position:absolute;top:0;bottom:0;margin:auto 0;width:100%;animation:none;transform-origin:top left;transition:transform 250ms 0ms cubic-bezier(0.4, 0, 0.6, 1);height:var(--mdc-linear-progress-active-indicator-height, 4px)}.mdc-linear-progress--indeterminate .mdc-linear-progress__bar{transition:none}[dir=rtl] .mdc-linear-progress__bar{right:0;transform-origin:center right}.mdc-linear-progress__bar-inner{display:inline-block;position:absolute;width:100%;animation:none;border-top-style:solid;border-color:var(--mdc-linear-progress-active-indicator-color, var(--mat-sys-primary));border-top-width:var(--mdc-linear-progress-active-indicator-height, 4px)}.mdc-linear-progress__buffer{display:flex;position:absolute;top:0;bottom:0;margin:auto 0;width:100%;overflow:hidden;height:var(--mdc-linear-progress-track-height, 4px);border-radius:var(--mdc-linear-progress-track-shape, var(--mat-sys-corner-none))}.mdc-linear-progress__buffer-dots{-webkit-mask-image:url(\"data:image/svg+xml,%3Csvg version='1.1' xmlns='http://www.w3.org/2000/svg' xmlns:xlink='http://www.w3.org/1999/xlink' x='0px' y='0px' enable-background='new 0 0 5 2' xml:space='preserve' viewBox='0 0 5 2' preserveAspectRatio='xMinYMin slice'%3E%3Ccircle cx='1' cy='1' r='1'/%3E%3C/svg%3E\");mask-image:url(\"data:image/svg+xml,%3Csvg version='1.1' xmlns='http://www.w3.org/2000/svg' xmlns:xlink='http://www.w3.org/1999/xlink' x='0px' y='0px' enable-background='new 0 0 5 2' xml:space='preserve' viewBox='0 0 5 2' preserveAspectRatio='xMinYMin slice'%3E%3Ccircle cx='1' cy='1' r='1'/%3E%3C/svg%3E\");background-repeat:repeat-x;flex:auto;transform:rotate(180deg);animation:mdc-linear-progress-buffering 250ms infinite linear;background-color:var(--mdc-linear-progress-track-color, var(--mat-sys-surface-variant))}@media(forced-colors: active){.mdc-linear-progress__buffer-dots{background-color:ButtonBorder}}[dir=rtl] .mdc-linear-progress__buffer-dots{animation:mdc-linear-progress-buffering-reverse 250ms infinite linear;transform:rotate(0)}.mdc-linear-progress__buffer-bar{flex:0 1 100%;transition:flex-basis 250ms 0ms cubic-bezier(0.4, 0, 0.6, 1);background-color:var(--mdc-linear-progress-track-color, var(--mat-sys-surface-variant))}.mdc-linear-progress__primary-bar{transform:scaleX(0)}.mdc-linear-progress--indeterminate .mdc-linear-progress__primary-bar{left:-145.166611%}.mdc-linear-progress--indeterminate.mdc-linear-progress--animation-ready .mdc-linear-progress__primary-bar{animation:mdc-linear-progress-primary-indeterminate-translate 2s infinite linear}.mdc-linear-progress--indeterminate.mdc-linear-progress--animation-ready .mdc-linear-progress__primary-bar>.mdc-linear-progress__bar-inner{animation:mdc-linear-progress-primary-indeterminate-scale 2s infinite linear}[dir=rtl] .mdc-linear-progress.mdc-linear-progress--animation-ready .mdc-linear-progress__primary-bar{animation-name:mdc-linear-progress-primary-indeterminate-translate-reverse}[dir=rtl] .mdc-linear-progress.mdc-linear-progress--indeterminate .mdc-linear-progress__primary-bar{right:-145.166611%;left:auto}.mdc-linear-progress__secondary-bar{display:none}.mdc-linear-progress--indeterminate .mdc-linear-progress__secondary-bar{left:-54.888891%;display:block}.mdc-linear-progress--indeterminate.mdc-linear-progress--animation-ready .mdc-linear-progress__secondary-bar{animation:mdc-linear-progress-secondary-indeterminate-translate 2s infinite linear}.mdc-linear-progress--indeterminate.mdc-linear-progress--animation-ready .mdc-linear-progress__secondary-bar>.mdc-linear-progress__bar-inner{animation:mdc-linear-progress-secondary-indeterminate-scale 2s infinite linear}[dir=rtl] .mdc-linear-progress.mdc-linear-progress--animation-ready .mdc-linear-progress__secondary-bar{animation-name:mdc-linear-progress-secondary-indeterminate-translate-reverse}[dir=rtl] .mdc-linear-progress.mdc-linear-progress--indeterminate .mdc-linear-progress__secondary-bar{right:-54.888891%;left:auto}@keyframes mdc-linear-progress-buffering{from{transform:rotate(180deg) translateX(calc(var(--mdc-linear-progress-track-height, 4px) * -2.5))}}@keyframes mdc-linear-progress-primary-indeterminate-translate{0%{transform:translateX(0)}20%{animation-timing-function:cubic-bezier(0.5, 0, 0.701732, 0.495819);transform:translateX(0)}59.15%{animation-timing-function:cubic-bezier(0.302435, 0.381352, 0.55, 0.956352);transform:translateX(83.67142%)}100%{transform:translateX(200.611057%)}}@keyframes mdc-linear-progress-primary-indeterminate-scale{0%{transform:scaleX(0.08)}36.65%{animation-timing-function:cubic-bezier(0.334731, 0.12482, 0.785844, 1);transform:scaleX(0.08)}69.15%{animation-timing-function:cubic-bezier(0.06, 0.11, 0.6, 1);transform:scaleX(0.661479)}100%{transform:scaleX(0.08)}}@keyframes mdc-linear-progress-secondary-indeterminate-translate{0%{animation-timing-function:cubic-bezier(0.15, 0, 0.515058, 0.409685);transform:translateX(0)}25%{animation-timing-function:cubic-bezier(0.31033, 0.284058, 0.8, 0.733712);transform:translateX(37.651913%)}48.35%{animation-timing-function:cubic-bezier(0.4, 0.627035, 0.6, 0.902026);transform:translateX(84.386165%)}100%{transform:translateX(160.277782%)}}@keyframes mdc-linear-progress-secondary-indeterminate-scale{0%{animation-timing-function:cubic-bezier(0.205028, 0.057051, 0.57661, 0.453971);transform:scaleX(0.08)}19.15%{animation-timing-function:cubic-bezier(0.152313, 0.196432, 0.648374, 1.004315);transform:scaleX(0.457104)}44.15%{animation-timing-function:cubic-bezier(0.257759, -0.003163, 0.211762, 1.38179);transform:scaleX(0.72796)}100%{transform:scaleX(0.08)}}@keyframes mdc-linear-progress-primary-indeterminate-translate-reverse{0%{transform:translateX(0)}20%{animation-timing-function:cubic-bezier(0.5, 0, 0.701732, 0.495819);transform:translateX(0)}59.15%{animation-timing-function:cubic-bezier(0.302435, 0.381352, 0.55, 0.956352);transform:translateX(-83.67142%)}100%{transform:translateX(-200.611057%)}}@keyframes mdc-linear-progress-secondary-indeterminate-translate-reverse{0%{animation-timing-function:cubic-bezier(0.15, 0, 0.515058, 0.409685);transform:translateX(0)}25%{animation-timing-function:cubic-bezier(0.31033, 0.284058, 0.8, 0.733712);transform:translateX(-37.651913%)}48.35%{animation-timing-function:cubic-bezier(0.4, 0.627035, 0.6, 0.902026);transform:translateX(-84.386165%)}100%{transform:translateX(-160.277782%)}}@keyframes mdc-linear-progress-buffering-reverse{from{transform:translateX(-10px)}}"],encapsulation:2,changeDetection:0})}return L})();function M(L,Z=0,q=100){return Math.max(Z,Math.min(q,L))}let O=(()=>{class L{static \u0275fac=function(re){return new(re||L)};static \u0275mod=i.$C({type:L});static \u0275inj=i.G2t({imports:[c.yE]})}return L})()},4375:(o,s,r)=>{"use strict";r.d(s,{$2:()=>it,VO:()=>Ze,Ve:()=>Ot});var i=r(9666),a=r(3107),c=r(2902),y=r(6071),w=r(8108),C=r(8559),T=r(2944),S=r(1349),M=r(5919),O=r(936),L=r(8447),Z=r(6381),q=r(7509),re=r(593),pe=r(2867),se=r(1483),ae=r(7947),me=r(6645),be=r(5424),Oe=r(7610),xe=r(1204),De=r(4460);const ce=["trigger"],ue=["panel"],Ce=[[["mat-select-trigger"]],"*"],Be=["mat-select-trigger","*"];function at($t,Te){if(1&$t&&(a.j41(0,"span",4),a.EFF(1),a.k0s()),2&$t){const Ee=a.XpG();a.R7$(),a.JRh(Ee.placeholder)}}function dt($t,Te){1&$t&&a.SdG(0)}function bt($t,Te){if(1&$t&&(a.j41(0,"span",11),a.EFF(1),a.k0s()),2&$t){const Ee=a.XpG(2);a.R7$(),a.JRh(Ee.triggerValue)}}function lt($t,Te){if(1&$t&&(a.j41(0,"span",5),a.DNE(1,dt,1,0)(2,bt,2,1,"span",11),a.k0s()),2&$t){const Ee=a.XpG();a.R7$(),a.vxM(Ee.customTrigger?1:2)}}function rn($t,Te){if(1&$t){const Ee=a.RV6();a.j41(0,"div",12,1),a.bIt("@transformPanel.done",function(Xt){a.eBV(Ee);const Mt=a.XpG();return a.Njj(Mt._panelDoneAnimatingStream.next(Xt.toState))})("keydown",function(Xt){a.eBV(Ee);const Mt=a.XpG();return a.Njj(Mt._handleKeydown(Xt))}),a.SdG(2,1),a.k0s()}if(2&$t){const Ee=a.XpG();a.ZvI("mat-mdc-select-panel mdc-menu-surface mdc-menu-surface--open ",Ee._getPanelTheme(),""),a.Y8G("ngClass",Ee.panelClass)("@transformPanel","showing"),a.BMQ("id",Ee.id+"-panel")("aria-multiselectable",Ee.multiple)("aria-label",Ee.ariaLabel||null)("aria-labelledby",Ee._getPanelAriaLabelledby())}}const gn={transformPanelWrap:(0,xe.hZ)("transformPanelWrap",[(0,xe.kY)("* => void",(0,xe.P)("@transformPanel",[(0,xe.MA)()],{optional:!0}))]),transformPanel:(0,xe.hZ)("transformPanel",[(0,xe.wk)("void",(0,xe.iF)({opacity:0,transform:"scale(1, 0.8)"})),(0,xe.kY)("void => showing",(0,xe.i0)("120ms cubic-bezier(0, 0, 0.2, 1)",(0,xe.iF)({opacity:1,transform:"scale(1, 1)"}))),(0,xe.kY)("* => void",(0,xe.i0)("100ms linear",(0,xe.iF)({opacity:0})))])},qe=new a.nKC("mat-select-scroll-strategy",{providedIn:"root",factory:()=>{const $t=(0,a.WQX)(i.hJ);return()=>$t.scrollStrategies.reposition()}}),ze=new a.nKC("MAT_SELECT_CONFIG"),$e={provide:qe,deps:[i.hJ],useFactory:function _t($t){return()=>$t.scrollStrategies.reposition()}},Ft=new a.nKC("MatSelectTrigger");class Ke{source;value;constructor(Te,Ee){this.source=Te,this.value=Ee}}let Ze=(()=>{class $t{_viewportRuler=(0,a.WQX)(w.Xj);_changeDetectorRef=(0,a.WQX)(a.gRc);_elementRef=(0,a.WQX)(a.aKT);_dir=(0,a.WQX)(T.dS,{optional:!0});_idGenerator=(0,a.WQX)(C.g7);_parentFormField=(0,a.WQX)(y.xb,{optional:!0});ngControl=(0,a.WQX)(O.vO,{self:!0,optional:!0});_liveAnnouncer=(0,a.WQX)(C.Ai);_defaultOptions=(0,a.WQX)(ze,{optional:!0});options;optionGroups;customTrigger;_positions=[{originX:"start",originY:"bottom",overlayX:"start",overlayY:"top"},{originX:"end",originY:"bottom",overlayX:"end",overlayY:"top"},{originX:"start",originY:"top",overlayX:"start",overlayY:"bottom",panelClass:"mat-mdc-select-panel-above"},{originX:"end",originY:"top",overlayX:"end",overlayY:"bottom",panelClass:"mat-mdc-select-panel-above"}];_scrollOptionIntoView(Ee){const st=this.options.toArray()[Ee];if(st){const Xt=this.panel.nativeElement,Mt=(0,c.jb)(Ee,this.options,this.optionGroups),Kt=st._getHostElement();Xt.scrollTop=0===Ee&&1===Mt?0:(0,c.TL)(Kt.offsetTop,Kt.offsetHeight,Xt.scrollTop,Xt.offsetHeight)}}_positioningSettled(){this._scrollOptionIntoView(this._keyManager.activeItemIndex||0)}_getChangeEvent(Ee){return new Ke(this,Ee)}_scrollStrategyFactory=(0,a.WQX)(qe);_panelOpen=!1;_compareWith=(Ee,st)=>Ee===st;_uid=this._idGenerator.getId("mat-select-");_triggerAriaLabelledBy=null;_previousControl;_destroy=new L.B;_errorStateTracker;stateChanges=new L.B;disableAutomaticLabeling=!0;userAriaDescribedBy;_selectionModel;_keyManager;_preferredOverlayOrigin;_overlayWidth;_onChange=()=>{};_onTouched=()=>{};_valueId=this._idGenerator.getId("mat-select-value-");_panelDoneAnimatingStream=new L.B;_scrollStrategy;_overlayPanelClass=this._defaultOptions?.overlayPanelClass||"";get focused(){return this._focused||this._panelOpen}_focused=!1;controlType="mat-select";trigger;panel;_overlayDir;panelClass;disabled=!1;disableRipple=!1;tabIndex=0;get hideSingleSelectionIndicator(){return this._hideSingleSelectionIndicator}set hideSingleSelectionIndicator(Ee){this._hideSingleSelectionIndicator=Ee,this._syncParentProperties()}_hideSingleSelectionIndicator=this._defaultOptions?.hideSingleSelectionIndicator??!1;get placeholder(){return this._placeholder}set placeholder(Ee){this._placeholder=Ee,this.stateChanges.next()}_placeholder;get required(){return this._required??this.ngControl?.control?.hasValidator(O.k0.required)??!1}set required(Ee){this._required=Ee,this.stateChanges.next()}_required;get multiple(){return this._multiple}set multiple(Ee){this._multiple=Ee}_multiple=!1;disableOptionCentering=this._defaultOptions?.disableOptionCentering??!1;get compareWith(){return this._compareWith}set compareWith(Ee){this._compareWith=Ee,this._selectionModel&&this._initializeSelection()}get value(){return this._value}set value(Ee){this._assignValue(Ee)&&this._onChange(Ee)}_value;ariaLabel="";ariaLabelledby;get errorStateMatcher(){return this._errorStateTracker.matcher}set errorStateMatcher(Ee){this._errorStateTracker.matcher=Ee}typeaheadDebounceInterval;sortComparator;get id(){return this._id}set id(Ee){this._id=Ee||this._uid,this.stateChanges.next()}_id;get errorState(){return this._errorStateTracker.errorState}set errorState(Ee){this._errorStateTracker.errorState=Ee}panelWidth=this._defaultOptions&&typeof this._defaultOptions.panelWidth<"u"?this._defaultOptions.panelWidth:"auto";_initialized=new L.B;optionSelectionChanges=(0,Z.v)(()=>{const Ee=this.options;return Ee?Ee.changes.pipe((0,re.Z)(Ee),(0,pe.n)(()=>(0,q.h)(...Ee.map(st=>st.onSelectionChange)))):this._initialized.pipe((0,pe.n)(()=>this.optionSelectionChanges))});openedChange=new a.bkB;_openedStream=this.openedChange.pipe((0,se.p)(Ee=>Ee),(0,ae.T)(()=>{}));_closedStream=this.openedChange.pipe((0,se.p)(Ee=>!Ee),(0,ae.T)(()=>{}));selectionChange=new a.bkB;valueChange=new a.bkB;constructor(){const Ee=(0,a.WQX)(c.es),st=(0,a.WQX)(O.cV,{optional:!0}),Xt=(0,a.WQX)(O.j4,{optional:!0}),Mt=(0,a.WQX)(new a.ES_("tabindex"),{optional:!0});this.ngControl&&(this.ngControl.valueAccessor=this),null!=this._defaultOptions?.typeaheadDebounceInterval&&(this.typeaheadDebounceInterval=this._defaultOptions.typeaheadDebounceInterval),this._errorStateTracker=new c.X0(Ee,this.ngControl,Xt,st,this.stateChanges),this._scrollStrategy=this._scrollStrategyFactory(),this.tabIndex=null==Mt?0:parseInt(Mt)||0,this.id=this.id}ngOnInit(){this._selectionModel=new S.CB(this.multiple),this.stateChanges.next(),this._panelDoneAnimatingStream.pipe((0,me.F)(),(0,be.Q)(this._destroy)).subscribe(()=>this._panelDoneAnimating(this.panelOpen)),this._viewportRuler.change().pipe((0,be.Q)(this._destroy)).subscribe(()=>{this.panelOpen&&(this._overlayWidth=this._getOverlayWidth(this._preferredOverlayOrigin),this._changeDetectorRef.detectChanges())})}ngAfterContentInit(){this._initialized.next(),this._initialized.complete(),this._initKeyManager(),this._selectionModel.changed.pipe((0,be.Q)(this._destroy)).subscribe(Ee=>{Ee.added.forEach(st=>st.select()),Ee.removed.forEach(st=>st.deselect())}),this.options.changes.pipe((0,re.Z)(null),(0,be.Q)(this._destroy)).subscribe(()=>{this._resetOptions(),this._initializeSelection()})}ngDoCheck(){const Ee=this._getTriggerAriaLabelledby(),st=this.ngControl;if(Ee!==this._triggerAriaLabelledBy){const Xt=this._elementRef.nativeElement;this._triggerAriaLabelledBy=Ee,Ee?Xt.setAttribute("aria-labelledby",Ee):Xt.removeAttribute("aria-labelledby")}st&&(this._previousControl!==st.control&&(void 0!==this._previousControl&&null!==st.disabled&&st.disabled!==this.disabled&&(this.disabled=st.disabled),this._previousControl=st.control),this.updateErrorState())}ngOnChanges(Ee){(Ee.disabled||Ee.userAriaDescribedBy)&&this.stateChanges.next(),Ee.typeaheadDebounceInterval&&this._keyManager&&this._keyManager.withTypeAhead(this.typeaheadDebounceInterval)}ngOnDestroy(){this._keyManager?.destroy(),this._destroy.next(),this._destroy.complete(),this.stateChanges.complete(),this._clearFromModal()}toggle(){this.panelOpen?this.close():this.open()}open(){this._canOpen()&&(this._parentFormField&&(this._preferredOverlayOrigin=this._parentFormField.getConnectedOverlayOrigin()),this._overlayWidth=this._getOverlayWidth(this._preferredOverlayOrigin),this._applyModalPanelOwnership(),this._panelOpen=!0,this._keyManager.withHorizontalOrientation(null),this._highlightCorrectOption(),this._changeDetectorRef.markForCheck(),this.stateChanges.next())}_trackedModal=null;_applyModalPanelOwnership(){const Ee=this._elementRef.nativeElement.closest('body > .cdk-overlay-container [aria-modal="true"]');if(!Ee)return;const st=`${this.id}-panel`;this._trackedModal&&(0,C.Ae)(this._trackedModal,"aria-owns",st),(0,C.px)(Ee,"aria-owns",st),this._trackedModal=Ee}_clearFromModal(){this._trackedModal&&((0,C.Ae)(this._trackedModal,"aria-owns",`${this.id}-panel`),this._trackedModal=null)}close(){this._panelOpen&&(this._panelOpen=!1,this._keyManager.withHorizontalOrientation(this._isRtl()?"rtl":"ltr"),this._changeDetectorRef.markForCheck(),this._onTouched(),this.stateChanges.next())}writeValue(Ee){this._assignValue(Ee)}registerOnChange(Ee){this._onChange=Ee}registerOnTouched(Ee){this._onTouched=Ee}setDisabledState(Ee){this.disabled=Ee,this._changeDetectorRef.markForCheck(),this.stateChanges.next()}get panelOpen(){return this._panelOpen}get selected(){return this.multiple?this._selectionModel?.selected||[]:this._selectionModel?.selected[0]}get triggerValue(){if(this.empty)return"";if(this._multiple){const Ee=this._selectionModel.selected.map(st=>st.viewValue);return this._isRtl()&&Ee.reverse(),Ee.join(", ")}return this._selectionModel.selected[0].viewValue}updateErrorState(){this._errorStateTracker.updateErrorState()}_isRtl(){return!!this._dir&&"rtl"===this._dir.value}_handleKeydown(Ee){this.disabled||(this.panelOpen?this._handleOpenKeydown(Ee):this._handleClosedKeydown(Ee))}_handleClosedKeydown(Ee){const st=Ee.keyCode,Xt=st===M.n6||st===M.i7||st===M.UQ||st===M.LE,Mt=st===M.Fm||st===M.t6,Kt=this._keyManager;if(!Kt.isTyping()&&Mt&&!(0,M.rp)(Ee)||(this.multiple||Ee.altKey)&&Xt)Ee.preventDefault(),this.open();else if(!this.multiple){const rt=this.selected;Kt.onKeydown(Ee);const Vt=this.selected;Vt&&rt!==Vt&&this._liveAnnouncer.announce(Vt.viewValue,1e4)}}_handleOpenKeydown(Ee){const st=this._keyManager,Xt=Ee.keyCode,Mt=Xt===M.n6||Xt===M.i7,Kt=st.isTyping();if(Mt&&Ee.altKey)Ee.preventDefault(),this.close();else if(Kt||Xt!==M.Fm&&Xt!==M.t6||!st.activeItem||(0,M.rp)(Ee))if(!Kt&&this._multiple&&Xt===M.A&&Ee.ctrlKey){Ee.preventDefault();const rt=this.options.some(Vt=>!Vt.disabled&&!Vt.selected);this.options.forEach(Vt=>{Vt.disabled||(rt?Vt.select():Vt.deselect())})}else{const rt=st.activeItemIndex;st.onKeydown(Ee),this._multiple&&Mt&&Ee.shiftKey&&st.activeItem&&st.activeItemIndex!==rt&&st.activeItem._selectViaInteraction()}else Ee.preventDefault(),st.activeItem._selectViaInteraction()}_onFocus(){this.disabled||(this._focused=!0,this.stateChanges.next())}_onBlur(){this._focused=!1,this._keyManager?.cancelTypeahead(),!this.disabled&&!this.panelOpen&&(this._onTouched(),this._changeDetectorRef.markForCheck(),this.stateChanges.next())}_onAttached(){this._overlayDir.positionChange.pipe((0,Oe.s)(1)).subscribe(()=>{this._changeDetectorRef.detectChanges(),this._positioningSettled()})}_getPanelTheme(){return this._parentFormField?`mat-${this._parentFormField.color}`:""}get empty(){return!this._selectionModel||this._selectionModel.isEmpty()}_initializeSelection(){Promise.resolve().then(()=>{this.ngControl&&(this._value=this.ngControl.value),this._setSelectionByValue(this._value),this.stateChanges.next()})}_setSelectionByValue(Ee){if(this.options.forEach(st=>st.setInactiveStyles()),this._selectionModel.clear(),this.multiple&&Ee)Array.isArray(Ee),Ee.forEach(st=>this._selectOptionByValue(st)),this._sortValues();else{const st=this._selectOptionByValue(Ee);st?this._keyManager.updateActiveItem(st):this.panelOpen||this._keyManager.updateActiveItem(-1)}this._changeDetectorRef.markForCheck()}_selectOptionByValue(Ee){const st=this.options.find(Xt=>{if(this._selectionModel.isSelected(Xt))return!1;try{return null!=Xt.value&&this._compareWith(Xt.value,Ee)}catch{return!1}});return st&&this._selectionModel.select(st),st}_assignValue(Ee){return!!(Ee!==this._value||this._multiple&&Array.isArray(Ee))&&(this.options&&this._setSelectionByValue(Ee),this._value=Ee,!0)}_skipPredicate=Ee=>!this.panelOpen&&Ee.disabled;_getOverlayWidth(Ee){return"auto"===this.panelWidth?(Ee instanceof i.$Q?Ee.elementRef:Ee||this._elementRef).nativeElement.getBoundingClientRect().width:null===this.panelWidth?"":this.panelWidth}_syncParentProperties(){if(this.options)for(const Ee of this.options)Ee._changeDetectorRef.markForCheck()}_initKeyManager(){this._keyManager=new C.Au(this.options).withTypeAhead(this.typeaheadDebounceInterval).withVerticalOrientation().withHorizontalOrientation(this._isRtl()?"rtl":"ltr").withHomeAndEnd().withPageUpDown().withAllowedModifierKeys(["shiftKey"]).skipPredicate(this._skipPredicate),this._keyManager.tabOut.subscribe(()=>{this.panelOpen&&(!this.multiple&&this._keyManager.activeItem&&this._keyManager.activeItem._selectViaInteraction(),this.focus(),this.close())}),this._keyManager.change.subscribe(()=>{this._panelOpen&&this.panel?this._scrollOptionIntoView(this._keyManager.activeItemIndex||0):!this._panelOpen&&!this.multiple&&this._keyManager.activeItem&&this._keyManager.activeItem._selectViaInteraction()})}_resetOptions(){const Ee=(0,q.h)(this.options.changes,this._destroy);this.optionSelectionChanges.pipe((0,be.Q)(Ee)).subscribe(st=>{this._onSelect(st.source,st.isUserInput),st.isUserInput&&!this.multiple&&this._panelOpen&&(this.close(),this.focus())}),(0,q.h)(...this.options.map(st=>st._stateChanges)).pipe((0,be.Q)(Ee)).subscribe(()=>{this._changeDetectorRef.detectChanges(),this.stateChanges.next()})}_onSelect(Ee,st){const Xt=this._selectionModel.isSelected(Ee);null!=Ee.value||this._multiple?(Xt!==Ee.selected&&(Ee.selected?this._selectionModel.select(Ee):this._selectionModel.deselect(Ee)),st&&this._keyManager.setActiveItem(Ee),this.multiple&&(this._sortValues(),st&&this.focus())):(Ee.deselect(),this._selectionModel.clear(),null!=this.value&&this._propagateChanges(Ee.value)),Xt!==this._selectionModel.isSelected(Ee)&&this._propagateChanges(),this.stateChanges.next()}_sortValues(){if(this.multiple){const Ee=this.options.toArray();this._selectionModel.sort((st,Xt)=>this.sortComparator?this.sortComparator(st,Xt,Ee):Ee.indexOf(st)-Ee.indexOf(Xt)),this.stateChanges.next()}}_propagateChanges(Ee){let st;st=this.multiple?this.selected.map(Xt=>Xt.value):this.selected?this.selected.value:Ee,this._value=st,this.valueChange.emit(st),this._onChange(st),this.selectionChange.emit(this._getChangeEvent(st)),this._changeDetectorRef.markForCheck()}_highlightCorrectOption(){if(this._keyManager)if(this.empty){let Ee=-1;for(let st=0;st0}focus(Ee){this._elementRef.nativeElement.focus(Ee)}_getPanelAriaLabelledby(){if(this.ariaLabel)return null;const Ee=this._parentFormField?.getLabelId()||null;return this.ariaLabelledby?(Ee?Ee+" ":"")+this.ariaLabelledby:Ee}_getAriaActiveDescendant(){return this.panelOpen&&this._keyManager&&this._keyManager.activeItem?this._keyManager.activeItem.id:null}_getTriggerAriaLabelledby(){if(this.ariaLabel)return null;const Ee=this._parentFormField?.getLabelId();let st=(Ee?Ee+" ":"")+this._valueId;return this.ariaLabelledby&&(st+=" "+this.ariaLabelledby),st}_panelDoneAnimating(Ee){this.openedChange.emit(Ee)}setDescribedByIds(Ee){Ee.length?this._elementRef.nativeElement.setAttribute("aria-describedby",Ee.join(" ")):this._elementRef.nativeElement.removeAttribute("aria-describedby")}onContainerClick(){this.focus(),this.open()}get shouldLabelFloat(){return this.panelOpen||!this.empty||this.focused&&!!this.placeholder}static \u0275fac=function(st){return new(st||$t)};static \u0275cmp=a.VBU({type:$t,selectors:[["mat-select"]],contentQueries:function(st,Xt,Mt){if(1&st&&(a.wni(Mt,Ft,5),a.wni(Mt,c.wT,5),a.wni(Mt,c.QC,5)),2&st){let Kt;a.mGM(Kt=a.lsd())&&(Xt.customTrigger=Kt.first),a.mGM(Kt=a.lsd())&&(Xt.options=Kt),a.mGM(Kt=a.lsd())&&(Xt.optionGroups=Kt)}},viewQuery:function(st,Xt){if(1&st&&(a.GBs(ce,5),a.GBs(ue,5),a.GBs(i.WB,5)),2&st){let Mt;a.mGM(Mt=a.lsd())&&(Xt.trigger=Mt.first),a.mGM(Mt=a.lsd())&&(Xt.panel=Mt.first),a.mGM(Mt=a.lsd())&&(Xt._overlayDir=Mt.first)}},hostAttrs:["role","combobox","aria-haspopup","listbox",1,"mat-mdc-select"],hostVars:19,hostBindings:function(st,Xt){1&st&&a.bIt("keydown",function(Kt){return Xt._handleKeydown(Kt)})("focus",function(){return Xt._onFocus()})("blur",function(){return Xt._onBlur()}),2&st&&(a.BMQ("id",Xt.id)("tabindex",Xt.disabled?-1:Xt.tabIndex)("aria-controls",Xt.panelOpen?Xt.id+"-panel":null)("aria-expanded",Xt.panelOpen)("aria-label",Xt.ariaLabel||null)("aria-required",Xt.required.toString())("aria-disabled",Xt.disabled.toString())("aria-invalid",Xt.errorState)("aria-activedescendant",Xt._getAriaActiveDescendant()),a.AVh("mat-mdc-select-disabled",Xt.disabled)("mat-mdc-select-invalid",Xt.errorState)("mat-mdc-select-required",Xt.required)("mat-mdc-select-empty",Xt.empty)("mat-mdc-select-multiple",Xt.multiple))},inputs:{userAriaDescribedBy:[0,"aria-describedby","userAriaDescribedBy"],panelClass:"panelClass",disabled:[2,"disabled","disabled",a.L39],disableRipple:[2,"disableRipple","disableRipple",a.L39],tabIndex:[2,"tabIndex","tabIndex",Ee=>null==Ee?0:(0,a.Udg)(Ee)],hideSingleSelectionIndicator:[2,"hideSingleSelectionIndicator","hideSingleSelectionIndicator",a.L39],placeholder:"placeholder",required:[2,"required","required",a.L39],multiple:[2,"multiple","multiple",a.L39],disableOptionCentering:[2,"disableOptionCentering","disableOptionCentering",a.L39],compareWith:"compareWith",value:"value",ariaLabel:[0,"aria-label","ariaLabel"],ariaLabelledby:[0,"aria-labelledby","ariaLabelledby"],errorStateMatcher:"errorStateMatcher",typeaheadDebounceInterval:[2,"typeaheadDebounceInterval","typeaheadDebounceInterval",a.Udg],sortComparator:"sortComparator",id:"id",panelWidth:"panelWidth"},outputs:{openedChange:"openedChange",_openedStream:"opened",_closedStream:"closed",selectionChange:"selectionChange",valueChange:"valueChange"},exportAs:["matSelect"],features:[a.Jv_([{provide:y.qT,useExisting:$t},{provide:c.is,useExisting:$t}]),a.GFd,a.OA$],ngContentSelectors:Be,decls:11,vars:8,consts:[["fallbackOverlayOrigin","cdkOverlayOrigin","trigger",""],["panel",""],["cdk-overlay-origin","",1,"mat-mdc-select-trigger",3,"click"],[1,"mat-mdc-select-value"],[1,"mat-mdc-select-placeholder","mat-mdc-select-min-line"],[1,"mat-mdc-select-value-text"],[1,"mat-mdc-select-arrow-wrapper"],[1,"mat-mdc-select-arrow"],["viewBox","0 0 24 24","width","24px","height","24px","focusable","false","aria-hidden","true"],["d","M7 10l5 5 5-5z"],["cdk-connected-overlay","","cdkConnectedOverlayLockPosition","","cdkConnectedOverlayHasBackdrop","","cdkConnectedOverlayBackdropClass","cdk-overlay-transparent-backdrop",3,"backdropClick","attach","detach","cdkConnectedOverlayPanelClass","cdkConnectedOverlayScrollStrategy","cdkConnectedOverlayOrigin","cdkConnectedOverlayOpen","cdkConnectedOverlayPositions","cdkConnectedOverlayWidth"],[1,"mat-mdc-select-min-line"],["role","listbox","tabindex","-1",3,"keydown","ngClass"]],template:function(st,Xt){if(1&st){const Mt=a.RV6();a.NAR(Ce),a.j41(0,"div",2,0),a.bIt("click",function(){return a.eBV(Mt),a.Njj(Xt.open())}),a.j41(3,"div",3),a.DNE(4,at,2,1,"span",4)(5,lt,3,1,"span",5),a.k0s(),a.j41(6,"div",6)(7,"div",7),a.qSk(),a.j41(8,"svg",8),a.nrm(9,"path",9),a.k0s()()()(),a.DNE(10,rn,3,9,"ng-template",10),a.bIt("backdropClick",function(){return a.eBV(Mt),a.Njj(Xt.close())})("attach",function(){return a.eBV(Mt),a.Njj(Xt._onAttached())})("detach",function(){return a.eBV(Mt),a.Njj(Xt.close())})}if(2&st){const Mt=a.sdS(1);a.R7$(3),a.BMQ("id",Xt._valueId),a.R7$(),a.vxM(Xt.empty?4:5),a.R7$(6),a.Y8G("cdkConnectedOverlayPanelClass",Xt._overlayPanelClass)("cdkConnectedOverlayScrollStrategy",Xt._scrollStrategy)("cdkConnectedOverlayOrigin",Xt._preferredOverlayOrigin||Mt)("cdkConnectedOverlayOpen",Xt.panelOpen)("cdkConnectedOverlayPositions",Xt._positions)("cdkConnectedOverlayWidth",Xt._overlayWidth)}},dependencies:[i.$Q,i.WB,De.YU],styles:['.mat-mdc-select{display:inline-block;width:100%;outline:none;-moz-osx-font-smoothing:grayscale;-webkit-font-smoothing:antialiased;color:var(--mat-select-enabled-trigger-text-color, var(--mat-sys-on-surface));font-family:var(--mat-select-trigger-text-font, var(--mat-sys-body-large-font));line-height:var(--mat-select-trigger-text-line-height, var(--mat-sys-body-large-line-height));font-size:var(--mat-select-trigger-text-size, var(--mat-sys-body-large-size));font-weight:var(--mat-select-trigger-text-weight, var(--mat-sys-body-large-weight));letter-spacing:var(--mat-select-trigger-text-tracking, var(--mat-sys-body-large-tracking))}div.mat-mdc-select-panel{box-shadow:var(--mat-select-container-elevation-shadow, 0px 3px 1px -2px rgba(0, 0, 0, 0.2), 0px 2px 2px 0px rgba(0, 0, 0, 0.14), 0px 1px 5px 0px rgba(0, 0, 0, 0.12))}.mat-mdc-select-disabled{color:var(--mat-select-disabled-trigger-text-color, color-mix(in srgb, var(--mat-sys-on-surface) 38%, transparent))}.mat-mdc-select-trigger{display:inline-flex;align-items:center;cursor:pointer;position:relative;box-sizing:border-box;width:100%}.mat-mdc-select-disabled .mat-mdc-select-trigger{-webkit-user-select:none;user-select:none;cursor:default}.mat-mdc-select-value{width:100%;overflow:hidden;text-overflow:ellipsis;white-space:nowrap}.mat-mdc-select-value-text{white-space:nowrap;overflow:hidden;text-overflow:ellipsis}.mat-mdc-select-arrow-wrapper{height:24px;flex-shrink:0;display:inline-flex;align-items:center}.mat-form-field-appearance-fill .mdc-text-field--no-label .mat-mdc-select-arrow-wrapper{transform:none}.mat-mdc-form-field .mat-mdc-select.mat-mdc-select-invalid .mat-mdc-select-arrow,.mat-form-field-invalid:not(.mat-form-field-disabled) .mat-mdc-form-field-infix::after{color:var(--mat-select-invalid-arrow-color, var(--mat-sys-error))}.mat-mdc-select-arrow{width:10px;height:5px;position:relative;color:var(--mat-select-enabled-arrow-color, var(--mat-sys-on-surface-variant))}.mat-mdc-form-field.mat-focused .mat-mdc-select-arrow{color:var(--mat-select-focused-arrow-color, var(--mat-sys-primary))}.mat-mdc-form-field .mat-mdc-select.mat-mdc-select-disabled .mat-mdc-select-arrow{color:var(--mat-select-disabled-arrow-color, color-mix(in srgb, var(--mat-sys-on-surface) 38%, transparent))}.mat-mdc-select-arrow svg{fill:currentColor;position:absolute;top:50%;left:50%;transform:translate(-50%, -50%)}@media(forced-colors: active){.mat-mdc-select-arrow svg{fill:CanvasText}.mat-mdc-select-disabled .mat-mdc-select-arrow svg{fill:GrayText}}div.mat-mdc-select-panel{width:100%;max-height:275px;outline:0;overflow:auto;padding:8px 0;border-radius:4px;box-sizing:border-box;position:static;background-color:var(--mat-select-panel-background-color, var(--mat-sys-surface-container))}@media(forced-colors: active){div.mat-mdc-select-panel{outline:solid 1px}}.cdk-overlay-pane:not(.mat-mdc-select-panel-above) div.mat-mdc-select-panel{border-top-left-radius:0;border-top-right-radius:0;transform-origin:top center}.mat-mdc-select-panel-above div.mat-mdc-select-panel{border-bottom-left-radius:0;border-bottom-right-radius:0;transform-origin:bottom center}div.mat-mdc-select-panel .mat-mdc-option{--mdc-list-list-item-container-color: var(--mat-select-panel-background-color)}.mat-mdc-select-placeholder{transition:color 400ms 133.3333333333ms cubic-bezier(0.25, 0.8, 0.25, 1);color:var(--mat-select-placeholder-text-color, var(--mat-sys-on-surface-variant))}._mat-animation-noopable .mat-mdc-select-placeholder{transition:none}.mat-form-field-hide-placeholder .mat-mdc-select-placeholder{color:rgba(0,0,0,0);-webkit-text-fill-color:rgba(0,0,0,0);transition:none;display:block}.mat-mdc-form-field-type-mat-select:not(.mat-form-field-disabled) .mat-mdc-text-field-wrapper{cursor:pointer}.mat-mdc-form-field-type-mat-select.mat-form-field-appearance-fill .mat-mdc-floating-label{max-width:calc(100% - 18px)}.mat-mdc-form-field-type-mat-select.mat-form-field-appearance-fill .mdc-floating-label--float-above{max-width:calc(100%/0.75 - 24px)}.mat-mdc-form-field-type-mat-select.mat-form-field-appearance-outline .mdc-notched-outline__notch{max-width:calc(100% - 60px)}.mat-mdc-form-field-type-mat-select.mat-form-field-appearance-outline .mdc-text-field--label-floating .mdc-notched-outline__notch{max-width:calc(100% - 24px)}.mat-mdc-select-min-line:empty::before{content:" ";white-space:pre;width:1px;display:inline-block;visibility:hidden}.mat-form-field-appearance-fill .mat-mdc-select-arrow-wrapper{transform:var(--mat-select-arrow-transform, translateY(-8px))}'],encapsulation:2,data:{animation:[gn.transformPanel]},changeDetection:0})}return $t})(),it=(()=>{class $t{static \u0275fac=function(st){return new(st||$t)};static \u0275dir=a.FsC({type:$t,selectors:[["mat-select-trigger"]],features:[a.Jv_([{provide:Ft,useExisting:$t}])]})}return $t})(),Ot=(()=>{class $t{static \u0275fac=function(st){return new(st||$t)};static \u0275mod=a.$C({type:$t});static \u0275inj=a.G2t({providers:[$e],imports:[i.z_,c.Sy,c.yE,w.Gj,y.RG,c.Sy,c.yE]})}return $t})()},5785:(o,s,r)=>{"use strict";r.d(s,{$C:()=>$e,$l:()=>_t,qe:()=>ze,vg:()=>it});var i=r(8108),a=r(3107),c=r(2902),y=r(8559),w=r(2944),C=r(3022),T=r(5919),S=r(2147),M=r(4460),O=r(8447),L=r(909),Z=r(7509),q=r(1483),re=r(7947),pe=r(6590),se=r(5424),ae=r(7610),me=r(593),be=r(8627),Oe=r(1204);const xe=["*"],De=["content"],ce=[[["mat-drawer"]],[["mat-drawer-content"]],"*"],ue=["mat-drawer","mat-drawer-content","*"];function Ce(Ot,$t){if(1&Ot){const Te=a.RV6();a.j41(0,"div",1),a.bIt("click",function(){a.eBV(Te);const st=a.XpG();return a.Njj(st._onBackdropClicked())}),a.k0s()}if(2&Ot){const Te=a.XpG();a.AVh("mat-drawer-shown",Te._isShowingBackdrop())}}function Be(Ot,$t){1&Ot&&(a.j41(0,"mat-drawer-content"),a.SdG(1,2),a.k0s())}const gn={transformDrawer:(0,Oe.hZ)("transform",[(0,Oe.wk)("open, open-instant",(0,Oe.iF)({transform:"none",visibility:"visible"})),(0,Oe.wk)("void",(0,Oe.iF)({"box-shadow":"none",visibility:"hidden"})),(0,Oe.kY)("void => open-instant",(0,Oe.i0)("0ms")),(0,Oe.kY)("void <=> open, open-instant => void",(0,Oe.i0)("400ms cubic-bezier(0.25, 0.8, 0.25, 1)"))])},Vn=new a.nKC("MAT_DRAWER_DEFAULT_AUTOSIZE",{providedIn:"root",factory:function qe(){return!1}}),yn=new a.nKC("MAT_DRAWER_CONTAINER");let _t=(()=>{class Ot extends i.uv{_platform=(0,a.WQX)(S.OD);_changeDetectorRef=(0,a.WQX)(a.gRc);_container=(0,a.WQX)($e);constructor(){super((0,a.WQX)(a.aKT),(0,a.WQX)(i.R),(0,a.WQX)(a.SKi))}ngAfterContentInit(){this._container._contentMarginChanges.subscribe(()=>{this._changeDetectorRef.markForCheck()})}_shouldBeHidden(){if(this._platform.isBrowser)return!1;const{start:Te,end:Ee}=this._container;return null!=Te&&"over"!==Te.mode&&Te.opened||null!=Ee&&"over"!==Ee.mode&&Ee.opened}static \u0275fac=function(Ee){return new(Ee||Ot)};static \u0275cmp=a.VBU({type:Ot,selectors:[["mat-drawer-content"]],hostAttrs:[1,"mat-drawer-content"],hostVars:6,hostBindings:function(Ee,st){2&Ee&&(a.xc7("margin-left",st._container._contentMargins.left,"px")("margin-right",st._container._contentMargins.right,"px"),a.AVh("mat-drawer-content-hidden",st._shouldBeHidden()))},features:[a.Jv_([{provide:i.uv,useExisting:Ot}]),a.Vt3],ngContentSelectors:xe,decls:1,vars:0,template:function(Ee,st){1&Ee&&(a.NAR(),a.SdG(0))},encapsulation:2,changeDetection:0})}return Ot})(),ze=(()=>{class Ot{_elementRef=(0,a.WQX)(a.aKT);_focusTrapFactory=(0,a.WQX)(y.GX);_focusMonitor=(0,a.WQX)(y.FN);_platform=(0,a.WQX)(S.OD);_ngZone=(0,a.WQX)(a.SKi);_interactivityChecker=(0,a.WQX)(y.Z7);_doc=(0,a.WQX)(M.qQ,{optional:!0});_container=(0,a.WQX)(yn,{optional:!0});_focusTrap=null;_elementFocusedBeforeDrawerWasOpened=null;_enableAnimations=!1;_isAttached;_anchor;get position(){return this._position}set position(Te){(Te="end"===Te?"end":"start")!==this._position&&(this._isAttached&&this._updatePositionInParent(Te),this._position=Te,this.onPositionChanged.emit())}_position="start";get mode(){return this._mode}set mode(Te){this._mode=Te,this._updateFocusTrapState(),this._modeChanged.next()}_mode="over";get disableClose(){return this._disableClose}set disableClose(Te){this._disableClose=(0,C.he)(Te)}_disableClose=!1;get autoFocus(){return this._autoFocus??("side"===this.mode?"dialog":"first-tabbable")}set autoFocus(Te){("true"===Te||"false"===Te||null==Te)&&(Te=(0,C.he)(Te)),this._autoFocus=Te}_autoFocus;get opened(){return this._opened}set opened(Te){this.toggle((0,C.he)(Te))}_opened=!1;_openedVia;_animationStarted=new O.B;_animationEnd=new O.B;_animationState="void";openedChange=new a.bkB(!0);_openedStream=this.openedChange.pipe((0,q.p)(Te=>Te),(0,re.T)(()=>{}));openedStart=this._animationStarted.pipe((0,q.p)(Te=>Te.fromState!==Te.toState&&0===Te.toState.indexOf("open")),(0,pe.u)(void 0));_closedStream=this.openedChange.pipe((0,q.p)(Te=>!Te),(0,re.T)(()=>{}));closedStart=this._animationStarted.pipe((0,q.p)(Te=>Te.fromState!==Te.toState&&"void"===Te.toState),(0,pe.u)(void 0));_destroyed=new O.B;onPositionChanged=new a.bkB;_content;_modeChanged=new O.B;_injector=(0,a.WQX)(a.zZn);_changeDetectorRef=(0,a.WQX)(a.gRc);constructor(){this.openedChange.pipe((0,se.Q)(this._destroyed)).subscribe(Te=>{Te?(this._doc&&(this._elementFocusedBeforeDrawerWasOpened=this._doc.activeElement),this._takeFocus()):this._isFocusWithinDrawer()&&this._restoreFocus(this._openedVia||"program")}),this._ngZone.runOutsideAngular(()=>{(0,L.R)(this._elementRef.nativeElement,"keydown").pipe((0,q.p)(Te=>Te.keyCode===T._f&&!this.disableClose&&!(0,T.rp)(Te)),(0,se.Q)(this._destroyed)).subscribe(Te=>this._ngZone.run(()=>{this.close(),Te.stopPropagation(),Te.preventDefault()}))}),this._animationEnd.subscribe(Te=>{const{fromState:Ee,toState:st}=Te;(0===st.indexOf("open")&&"void"===Ee||"void"===st&&0===Ee.indexOf("open"))&&this.openedChange.emit(this._opened)})}_forceFocus(Te,Ee){this._interactivityChecker.isFocusable(Te)||(Te.tabIndex=-1,this._ngZone.runOutsideAngular(()=>{const st=()=>{Te.removeEventListener("blur",st),Te.removeEventListener("mousedown",st),Te.removeAttribute("tabindex")};Te.addEventListener("blur",st),Te.addEventListener("mousedown",st)})),Te.focus(Ee)}_focusByCssSelector(Te,Ee){let st=this._elementRef.nativeElement.querySelector(Te);st&&this._forceFocus(st,Ee)}_takeFocus(){if(!this._focusTrap)return;const Te=this._elementRef.nativeElement;switch(this.autoFocus){case!1:case"dialog":return;case!0:case"first-tabbable":(0,a.mal)(()=>{!this._focusTrap.focusInitialElement()&&"function"==typeof Te.focus&&Te.focus()},{injector:this._injector});break;case"first-heading":this._focusByCssSelector('h1, h2, h3, h4, h5, h6, [role="heading"]');break;default:this._focusByCssSelector(this.autoFocus)}}_restoreFocus(Te){"dialog"!==this.autoFocus&&(this._elementFocusedBeforeDrawerWasOpened?this._focusMonitor.focusVia(this._elementFocusedBeforeDrawerWasOpened,Te):this._elementRef.nativeElement.blur(),this._elementFocusedBeforeDrawerWasOpened=null)}_isFocusWithinDrawer(){const Te=this._doc.activeElement;return!!Te&&this._elementRef.nativeElement.contains(Te)}ngAfterViewInit(){this._isAttached=!0,"end"===this._position&&this._updatePositionInParent("end"),this._platform.isBrowser&&(this._focusTrap=this._focusTrapFactory.create(this._elementRef.nativeElement),this._updateFocusTrapState())}ngAfterContentChecked(){this._platform.isBrowser&&(this._enableAnimations=!0)}ngOnDestroy(){this._focusTrap?.destroy(),this._anchor?.remove(),this._anchor=null,this._animationStarted.complete(),this._animationEnd.complete(),this._modeChanged.complete(),this._destroyed.next(),this._destroyed.complete()}open(Te){return this.toggle(!0,Te)}close(){return this.toggle(!1)}_closeViaBackdropClick(){return this._setOpen(!1,!0,"mouse")}toggle(Te=!this.opened,Ee){Te&&Ee&&(this._openedVia=Ee);const st=this._setOpen(Te,!Te&&this._isFocusWithinDrawer(),this._openedVia||"program");return Te||(this._openedVia=null),st}_setOpen(Te,Ee,st){return this._opened=Te,Te?this._animationState=this._enableAnimations?"open":"open-instant":(this._animationState="void",Ee&&this._restoreFocus(st)),this._changeDetectorRef.markForCheck(),this._updateFocusTrapState(),new Promise(Xt=>{this.openedChange.pipe((0,ae.s)(1)).subscribe(Mt=>Xt(Mt?"open":"close"))})}_getWidth(){return this._elementRef.nativeElement&&this._elementRef.nativeElement.offsetWidth||0}_updateFocusTrapState(){this._focusTrap&&(this._focusTrap.enabled=!!this._container?.hasBackdrop&&this.opened)}_updatePositionInParent(Te){if(!this._platform.isBrowser)return;const Ee=this._elementRef.nativeElement,st=Ee.parentNode;"end"===Te?(this._anchor||(this._anchor=this._doc.createComment("mat-drawer-anchor"),st.insertBefore(this._anchor,Ee)),st.appendChild(Ee)):this._anchor&&this._anchor.parentNode.insertBefore(Ee,this._anchor)}static \u0275fac=function(Ee){return new(Ee||Ot)};static \u0275cmp=a.VBU({type:Ot,selectors:[["mat-drawer"]],viewQuery:function(Ee,st){if(1&Ee&&a.GBs(De,5),2&Ee){let Xt;a.mGM(Xt=a.lsd())&&(st._content=Xt.first)}},hostAttrs:["tabIndex","-1",1,"mat-drawer"],hostVars:12,hostBindings:function(Ee,st){1&Ee&&a.Kam("@transform.start",function(Mt){return st._animationStarted.next(Mt)})("@transform.done",function(Mt){return st._animationEnd.next(Mt)}),2&Ee&&(a.zvX("@transform",st._animationState),a.BMQ("align",null),a.AVh("mat-drawer-end","end"===st.position)("mat-drawer-over","over"===st.mode)("mat-drawer-push","push"===st.mode)("mat-drawer-side","side"===st.mode)("mat-drawer-opened",st.opened))},inputs:{position:"position",mode:"mode",disableClose:"disableClose",autoFocus:"autoFocus",opened:"opened"},outputs:{openedChange:"openedChange",_openedStream:"opened",openedStart:"openedStart",_closedStream:"closed",closedStart:"closedStart",onPositionChanged:"positionChanged"},exportAs:["matDrawer"],ngContentSelectors:xe,decls:3,vars:0,consts:[["content",""],["cdkScrollable","",1,"mat-drawer-inner-container"]],template:function(Ee,st){1&Ee&&(a.NAR(),a.j41(0,"div",1,0),a.SdG(2),a.k0s())},dependencies:[i.uv],encapsulation:2,data:{animation:[gn.transformDrawer]},changeDetection:0})}return Ot})(),$e=(()=>{class Ot{_dir=(0,a.WQX)(w.dS,{optional:!0});_element=(0,a.WQX)(a.aKT);_ngZone=(0,a.WQX)(a.SKi);_changeDetectorRef=(0,a.WQX)(a.gRc);_animationMode=(0,a.WQX)(a.bc$,{optional:!0});_allDrawers;_drawers=new a.rOR;_content;_userContent;get start(){return this._start}get end(){return this._end}get autosize(){return this._autosize}set autosize(Te){this._autosize=(0,C.he)(Te)}_autosize=(0,a.WQX)(Vn);get hasBackdrop(){return this._drawerHasBackdrop(this._start)||this._drawerHasBackdrop(this._end)}set hasBackdrop(Te){this._backdropOverride=null==Te?null:(0,C.he)(Te)}_backdropOverride;backdropClick=new a.bkB;_start;_end;_left;_right;_destroyed=new O.B;_doCheckSubject=new O.B;_contentMargins={left:null,right:null};_contentMarginChanges=new O.B;get scrollable(){return this._userContent||this._content}_injector=(0,a.WQX)(a.zZn);constructor(){const Te=(0,a.WQX)(i.Xj);this._dir?.change.pipe((0,se.Q)(this._destroyed)).subscribe(()=>{this._validateDrawers(),this.updateContentMargins()}),Te.change().pipe((0,se.Q)(this._destroyed)).subscribe(()=>this.updateContentMargins())}ngAfterContentInit(){this._allDrawers.changes.pipe((0,me.Z)(this._allDrawers),(0,se.Q)(this._destroyed)).subscribe(Te=>{this._drawers.reset(Te.filter(Ee=>!Ee._container||Ee._container===this)),this._drawers.notifyOnChanges()}),this._drawers.changes.pipe((0,me.Z)(null)).subscribe(()=>{this._validateDrawers(),this._drawers.forEach(Te=>{this._watchDrawerToggle(Te),this._watchDrawerPosition(Te),this._watchDrawerMode(Te)}),(!this._drawers.length||this._isDrawerOpen(this._start)||this._isDrawerOpen(this._end))&&this.updateContentMargins(),this._changeDetectorRef.markForCheck()}),this._ngZone.runOutsideAngular(()=>{this._doCheckSubject.pipe((0,be.B)(10),(0,se.Q)(this._destroyed)).subscribe(()=>this.updateContentMargins())})}ngOnDestroy(){this._contentMarginChanges.complete(),this._doCheckSubject.complete(),this._drawers.destroy(),this._destroyed.next(),this._destroyed.complete()}open(){this._drawers.forEach(Te=>Te.open())}close(){this._drawers.forEach(Te=>Te.close())}updateContentMargins(){let Te=0,Ee=0;if(this._left&&this._left.opened)if("side"==this._left.mode)Te+=this._left._getWidth();else if("push"==this._left.mode){const st=this._left._getWidth();Te+=st,Ee-=st}if(this._right&&this._right.opened)if("side"==this._right.mode)Ee+=this._right._getWidth();else if("push"==this._right.mode){const st=this._right._getWidth();Ee+=st,Te-=st}Te=Te||null,Ee=Ee||null,(Te!==this._contentMargins.left||Ee!==this._contentMargins.right)&&(this._contentMargins={left:Te,right:Ee},this._ngZone.run(()=>this._contentMarginChanges.next(this._contentMargins)))}ngDoCheck(){this._autosize&&this._isPushed()&&this._ngZone.runOutsideAngular(()=>this._doCheckSubject.next())}_watchDrawerToggle(Te){Te._animationStarted.pipe((0,q.p)(Ee=>Ee.fromState!==Ee.toState),(0,se.Q)(this._drawers.changes)).subscribe(Ee=>{"open-instant"!==Ee.toState&&"NoopAnimations"!==this._animationMode&&this._element.nativeElement.classList.add("mat-drawer-transition"),this.updateContentMargins(),this._changeDetectorRef.markForCheck()}),"side"!==Te.mode&&Te.openedChange.pipe((0,se.Q)(this._drawers.changes)).subscribe(()=>this._setContainerClass(Te.opened))}_watchDrawerPosition(Te){Te&&Te.onPositionChanged.pipe((0,se.Q)(this._drawers.changes)).subscribe(()=>{(0,a.mal)(()=>{this._validateDrawers()},{injector:this._injector,phase:a.wjH.Read})})}_watchDrawerMode(Te){Te&&Te._modeChanged.pipe((0,se.Q)((0,Z.h)(this._drawers.changes,this._destroyed))).subscribe(()=>{this.updateContentMargins(),this._changeDetectorRef.markForCheck()})}_setContainerClass(Te){const Ee=this._element.nativeElement.classList,st="mat-drawer-container-has-open";Te?Ee.add(st):Ee.remove(st)}_validateDrawers(){this._start=this._end=null,this._drawers.forEach(Te=>{"end"==Te.position?this._end=Te:this._start=Te}),this._right=this._left=null,this._dir&&"rtl"===this._dir.value?(this._left=this._end,this._right=this._start):(this._left=this._start,this._right=this._end)}_isPushed(){return this._isDrawerOpen(this._start)&&"over"!=this._start.mode||this._isDrawerOpen(this._end)&&"over"!=this._end.mode}_onBackdropClicked(){this.backdropClick.emit(),this._closeModalDrawersViaBackdrop()}_closeModalDrawersViaBackdrop(){[this._start,this._end].filter(Te=>Te&&!Te.disableClose&&this._drawerHasBackdrop(Te)).forEach(Te=>Te._closeViaBackdropClick())}_isShowingBackdrop(){return this._isDrawerOpen(this._start)&&this._drawerHasBackdrop(this._start)||this._isDrawerOpen(this._end)&&this._drawerHasBackdrop(this._end)}_isDrawerOpen(Te){return null!=Te&&Te.opened}_drawerHasBackdrop(Te){return null==this._backdropOverride?!!Te&&"side"!==Te.mode:this._backdropOverride}static \u0275fac=function(Ee){return new(Ee||Ot)};static \u0275cmp=a.VBU({type:Ot,selectors:[["mat-drawer-container"]],contentQueries:function(Ee,st,Xt){if(1&Ee&&(a.wni(Xt,_t,5),a.wni(Xt,ze,5)),2&Ee){let Mt;a.mGM(Mt=a.lsd())&&(st._content=Mt.first),a.mGM(Mt=a.lsd())&&(st._allDrawers=Mt)}},viewQuery:function(Ee,st){if(1&Ee&&a.GBs(_t,5),2&Ee){let Xt;a.mGM(Xt=a.lsd())&&(st._userContent=Xt.first)}},hostAttrs:[1,"mat-drawer-container"],hostVars:2,hostBindings:function(Ee,st){2&Ee&&a.AVh("mat-drawer-container-explicit-backdrop",st._backdropOverride)},inputs:{autosize:"autosize",hasBackdrop:"hasBackdrop"},outputs:{backdropClick:"backdropClick"},exportAs:["matDrawerContainer"],features:[a.Jv_([{provide:yn,useExisting:Ot}])],ngContentSelectors:ue,decls:4,vars:2,consts:[[1,"mat-drawer-backdrop",3,"mat-drawer-shown"],[1,"mat-drawer-backdrop",3,"click"]],template:function(Ee,st){1&Ee&&(a.NAR(ce),a.DNE(0,Ce,1,2,"div",0),a.SdG(1),a.SdG(2,1),a.DNE(3,Be,2,0,"mat-drawer-content")),2&Ee&&(a.vxM(st.hasBackdrop?0:-1),a.R7$(3),a.vxM(st._content?-1:3))},dependencies:[_t],styles:['.mat-drawer-container{position:relative;z-index:1;color:var(--mat-sidenav-content-text-color, var(--mat-sys-on-background));background-color:var(--mat-sidenav-content-background-color, var(--mat-sys-background));box-sizing:border-box;-webkit-overflow-scrolling:touch;display:block;overflow:hidden}.mat-drawer-container[fullscreen]{top:0;left:0;right:0;bottom:0;position:absolute}.mat-drawer-container[fullscreen].mat-drawer-container-has-open{overflow:hidden}.mat-drawer-container.mat-drawer-container-explicit-backdrop .mat-drawer-side{z-index:3}.mat-drawer-container.ng-animate-disabled .mat-drawer-backdrop,.mat-drawer-container.ng-animate-disabled .mat-drawer-content,.ng-animate-disabled .mat-drawer-container .mat-drawer-backdrop,.ng-animate-disabled .mat-drawer-container .mat-drawer-content{transition:none}.mat-drawer-backdrop{top:0;left:0;right:0;bottom:0;position:absolute;display:block;z-index:3;visibility:hidden}.mat-drawer-backdrop.mat-drawer-shown{visibility:visible;background-color:var(--mat-sidenav-scrim-color, color-mix(in srgb, var(--mat-sys-neutral-variant20) 40%, transparent))}.mat-drawer-transition .mat-drawer-backdrop{transition-duration:400ms;transition-timing-function:cubic-bezier(0.25, 0.8, 0.25, 1);transition-property:background-color,visibility}@media(forced-colors: active){.mat-drawer-backdrop{opacity:.5}}.mat-drawer-content{position:relative;z-index:1;display:block;height:100%;overflow:auto}.mat-drawer-content.mat-drawer-content-hidden{opacity:0}.mat-drawer-transition .mat-drawer-content{transition-duration:400ms;transition-timing-function:cubic-bezier(0.25, 0.8, 0.25, 1);transition-property:transform,margin-left,margin-right}.mat-drawer{position:relative;z-index:4;color:var(--mat-sidenav-container-text-color, var(--mat-sys-on-surface-variant));box-shadow:var(--mat-sidenav-container-elevation-shadow, none);background-color:var(--mat-sidenav-container-background-color, var(--mat-sys-surface));border-top-right-radius:var(--mat-sidenav-container-shape, var(--mat-sys-corner-large));border-bottom-right-radius:var(--mat-sidenav-container-shape, var(--mat-sys-corner-large));width:var(--mat-sidenav-container-width, 360px);display:block;position:absolute;top:0;bottom:0;z-index:3;outline:0;box-sizing:border-box;overflow-y:auto;transform:translate3d(-100%, 0, 0)}@media(forced-colors: active){.mat-drawer,[dir=rtl] .mat-drawer.mat-drawer-end{border-right:solid 1px currentColor}}@media(forced-colors: active){[dir=rtl] .mat-drawer,.mat-drawer.mat-drawer-end{border-left:solid 1px currentColor;border-right:none}}.mat-drawer.mat-drawer-side{z-index:2}.mat-drawer.mat-drawer-end{right:0;transform:translate3d(100%, 0, 0);border-top-left-radius:var(--mat-sidenav-container-shape, var(--mat-sys-corner-large));border-bottom-left-radius:var(--mat-sidenav-container-shape, var(--mat-sys-corner-large));border-top-right-radius:0;border-bottom-right-radius:0}[dir=rtl] .mat-drawer{border-top-left-radius:var(--mat-sidenav-container-shape, var(--mat-sys-corner-large));border-bottom-left-radius:var(--mat-sidenav-container-shape, var(--mat-sys-corner-large));border-top-right-radius:0;border-bottom-right-radius:0;transform:translate3d(100%, 0, 0)}[dir=rtl] .mat-drawer.mat-drawer-end{border-top-right-radius:var(--mat-sidenav-container-shape, var(--mat-sys-corner-large));border-bottom-right-radius:var(--mat-sidenav-container-shape, var(--mat-sys-corner-large));border-top-left-radius:0;border-bottom-left-radius:0;left:0;right:auto;transform:translate3d(-100%, 0, 0)}.mat-drawer[style*="visibility: hidden"]{display:none}.mat-drawer-side{box-shadow:none;border-right-color:var(--mat-sidenav-container-divider-color, transparent);border-right-width:1px;border-right-style:solid}.mat-drawer-side.mat-drawer-end{border-left-color:var(--mat-sidenav-container-divider-color, transparent);border-left-width:1px;border-left-style:solid;border-right:none}[dir=rtl] .mat-drawer-side{border-left-color:var(--mat-sidenav-container-divider-color, transparent);border-left-width:1px;border-left-style:solid;border-right:none}[dir=rtl] .mat-drawer-side.mat-drawer-end{border-right-color:var(--mat-sidenav-container-divider-color, transparent);border-right-width:1px;border-right-style:solid;border-left:none}.mat-drawer-inner-container{width:100%;height:100%;overflow:auto;-webkit-overflow-scrolling:touch}.mat-sidenav-fixed{position:fixed}'],encapsulation:2,changeDetection:0})}return Ot})(),it=(()=>{class Ot{static \u0275fac=function(Ee){return new(Ee||Ot)};static \u0275mod=a.$C({type:Ot});static \u0275inj=a.G2t({imports:[c.yE,i.Gj,i.Gj,c.yE]})}return Ot})()},7712:(o,s,r)=>{"use strict";r.d(s,{oV:()=>lt,uc:()=>bn});var i=r(5424),a=r(3022),c=r(5919),y=r(3107),w=r(4460),C=r(2147),T=r(8559),S=r(2944),M=r(9666),O=r(8108),L=r(6192),Z=r(8447),re=(r(1204),r(2902));const pe=["tooltip"],me=new y.nKC("mat-tooltip-scroll-strategy",{providedIn:"root",factory:()=>{const Vn=(0,y.WQX)(M.hJ);return()=>Vn.scrollStrategies.reposition({scrollThrottle:20})}}),Oe={provide:me,deps:[M.hJ],useFactory:function be(Vn){return()=>Vn.scrollStrategies.reposition({scrollThrottle:20})}},De=new y.nKC("mat-tooltip-default-options",{providedIn:"root",factory:function xe(){return{showDelay:0,hideDelay:0,touchendHideDelay:1500}}}),ue="tooltip-panel",Ce=(0,C.BQ)({passive:!0});let lt=(()=>{class Vn{_overlay=(0,y.WQX)(M.hJ);_elementRef=(0,y.WQX)(y.aKT);_scrollDispatcher=(0,y.WQX)(O.R);_viewContainerRef=(0,y.WQX)(y.c1b);_ngZone=(0,y.WQX)(y.SKi);_platform=(0,y.WQX)(C.OD);_ariaDescriber=(0,y.WQX)(T.vr);_focusMonitor=(0,y.WQX)(T.FN);_dir=(0,y.WQX)(S.dS);_injector=(0,y.WQX)(y.zZn);_defaultOptions=(0,y.WQX)(De,{optional:!0});_overlayRef;_tooltipInstance;_portal;_position="below";_positionAtOrigin=!1;_disabled=!1;_tooltipClass;_scrollStrategy=(0,y.WQX)(me);_viewInitialized=!1;_pointerExitEventsInitialized=!1;_tooltipComponent=rn;_viewportMargin=8;_currentPosition;_cssClassPrefix="mat-mdc";_ariaDescriptionPending;get position(){return this._position}set position(qe){qe!==this._position&&(this._position=qe,this._overlayRef&&(this._updatePosition(this._overlayRef),this._tooltipInstance?.show(0),this._overlayRef.updatePosition()))}get positionAtOrigin(){return this._positionAtOrigin}set positionAtOrigin(qe){this._positionAtOrigin=(0,a.he)(qe),this._detach(),this._overlayRef=null}get disabled(){return this._disabled}set disabled(qe){const _t=(0,a.he)(qe);this._disabled!==_t&&(this._disabled=_t,_t?this.hide(0):this._setupPointerEnterEventsIfNeeded(),this._syncAriaDescription(this.message))}get showDelay(){return this._showDelay}set showDelay(qe){this._showDelay=(0,a.OE)(qe)}_showDelay;get hideDelay(){return this._hideDelay}set hideDelay(qe){this._hideDelay=(0,a.OE)(qe),this._tooltipInstance&&(this._tooltipInstance._mouseLeaveHideDelay=this._hideDelay)}_hideDelay;touchGestures="auto";get message(){return this._message}set message(qe){const _t=this._message;this._message=null!=qe?String(qe).trim():"",!this._message&&this._isTooltipVisible()?this.hide(0):(this._setupPointerEnterEventsIfNeeded(),this._updateTooltipMessage()),this._syncAriaDescription(_t)}_message="";get tooltipClass(){return this._tooltipClass}set tooltipClass(qe){this._tooltipClass=qe,this._tooltipInstance&&this._setTooltipClass(this._tooltipClass)}_passiveListeners=[];_document=(0,y.WQX)(w.qQ);_touchstartTimeout=null;_destroyed=new Z.B;constructor(){const qe=this._defaultOptions;qe&&(this._showDelay=qe.showDelay,this._hideDelay=qe.hideDelay,qe.position&&(this.position=qe.position),qe.positionAtOrigin&&(this.positionAtOrigin=qe.positionAtOrigin),qe.touchGestures&&(this.touchGestures=qe.touchGestures),qe.tooltipClass&&(this.tooltipClass=qe.tooltipClass)),this._dir.change.pipe((0,i.Q)(this._destroyed)).subscribe(()=>{this._overlayRef&&this._updatePosition(this._overlayRef)}),this._viewportMargin=8}ngAfterViewInit(){this._viewInitialized=!0,this._setupPointerEnterEventsIfNeeded(),this._focusMonitor.monitor(this._elementRef).pipe((0,i.Q)(this._destroyed)).subscribe(qe=>{qe?"keyboard"===qe&&this._ngZone.run(()=>this.show()):this._ngZone.run(()=>this.hide(0))})}ngOnDestroy(){const qe=this._elementRef.nativeElement;this._touchstartTimeout&&clearTimeout(this._touchstartTimeout),this._overlayRef&&(this._overlayRef.dispose(),this._tooltipInstance=null),this._passiveListeners.forEach(([_t,ze])=>{qe.removeEventListener(_t,ze,Ce)}),this._passiveListeners.length=0,this._destroyed.next(),this._destroyed.complete(),this._ariaDescriber.removeDescription(qe,this.message,"tooltip"),this._focusMonitor.stopMonitoring(qe)}show(qe=this.showDelay,_t){if(this.disabled||!this.message||this._isTooltipVisible())return void this._tooltipInstance?._cancelPendingAnimations();const ze=this._createOverlay(_t);this._detach(),this._portal=this._portal||new L.A8(this._tooltipComponent,this._viewContainerRef);const $e=this._tooltipInstance=ze.attach(this._portal).instance;$e._triggerElement=this._elementRef.nativeElement,$e._mouseLeaveHideDelay=this._hideDelay,$e.afterHidden().pipe((0,i.Q)(this._destroyed)).subscribe(()=>this._detach()),this._setTooltipClass(this._tooltipClass),this._updateTooltipMessage(),$e.show(qe)}hide(qe=this.hideDelay){const _t=this._tooltipInstance;_t&&(_t.isVisible()?_t.hide(qe):(_t._cancelPendingAnimations(),this._detach()))}toggle(qe){this._isTooltipVisible()?this.hide():this.show(void 0,qe)}_isTooltipVisible(){return!!this._tooltipInstance&&this._tooltipInstance.isVisible()}_createOverlay(qe){if(this._overlayRef){const $e=this._overlayRef.getConfig().positionStrategy;if((!this.positionAtOrigin||!qe)&&$e._origin instanceof y.aKT)return this._overlayRef;this._detach()}const _t=this._scrollDispatcher.getAncestorScrollContainers(this._elementRef),ze=this._overlay.position().flexibleConnectedTo(this.positionAtOrigin&&qe||this._elementRef).withTransformOriginOn(`.${this._cssClassPrefix}-tooltip`).withFlexibleDimensions(!1).withViewportMargin(this._viewportMargin).withScrollableContainers(_t);return ze.positionChanges.pipe((0,i.Q)(this._destroyed)).subscribe($e=>{this._updateCurrentPositionClass($e.connectionPair),this._tooltipInstance&&$e.scrollableViewProperties.isOverlayClipped&&this._tooltipInstance.isVisible()&&this._ngZone.run(()=>this.hide(0))}),this._overlayRef=this._overlay.create({direction:this._dir,positionStrategy:ze,panelClass:`${this._cssClassPrefix}-${ue}`,scrollStrategy:this._scrollStrategy()}),this._updatePosition(this._overlayRef),this._overlayRef.detachments().pipe((0,i.Q)(this._destroyed)).subscribe(()=>this._detach()),this._overlayRef.outsidePointerEvents().pipe((0,i.Q)(this._destroyed)).subscribe(()=>this._tooltipInstance?._handleBodyInteraction()),this._overlayRef.keydownEvents().pipe((0,i.Q)(this._destroyed)).subscribe($e=>{this._isTooltipVisible()&&$e.keyCode===c._f&&!(0,c.rp)($e)&&($e.preventDefault(),$e.stopPropagation(),this._ngZone.run(()=>this.hide(0)))}),this._defaultOptions?.disableTooltipInteractivity&&this._overlayRef.addPanelClass(`${this._cssClassPrefix}-tooltip-panel-non-interactive`),this._overlayRef}_detach(){this._overlayRef&&this._overlayRef.hasAttached()&&this._overlayRef.detach(),this._tooltipInstance=null}_updatePosition(qe){const _t=qe.getConfig().positionStrategy,ze=this._getOrigin(),$e=this._getOverlayPosition();_t.withPositions([this._addOffset({...ze.main,...$e.main}),this._addOffset({...ze.fallback,...$e.fallback})])}_addOffset(qe){const ze=!this._dir||"ltr"==this._dir.value;return"top"===qe.originY?qe.offsetY=-8:"bottom"===qe.originY?qe.offsetY=8:"start"===qe.originX?qe.offsetX=ze?-8:8:"end"===qe.originX&&(qe.offsetX=ze?8:-8),qe}_getOrigin(){const qe=!this._dir||"ltr"==this._dir.value,_t=this.position;let ze;"above"==_t||"below"==_t?ze={originX:"center",originY:"above"==_t?"top":"bottom"}:"before"==_t||"left"==_t&&qe||"right"==_t&&!qe?ze={originX:"start",originY:"center"}:("after"==_t||"right"==_t&&qe||"left"==_t&&!qe)&&(ze={originX:"end",originY:"center"});const{x:$e,y:Ft}=this._invertPosition(ze.originX,ze.originY);return{main:ze,fallback:{originX:$e,originY:Ft}}}_getOverlayPosition(){const qe=!this._dir||"ltr"==this._dir.value,_t=this.position;let ze;"above"==_t?ze={overlayX:"center",overlayY:"bottom"}:"below"==_t?ze={overlayX:"center",overlayY:"top"}:"before"==_t||"left"==_t&&qe||"right"==_t&&!qe?ze={overlayX:"end",overlayY:"center"}:("after"==_t||"right"==_t&&qe||"left"==_t&&!qe)&&(ze={overlayX:"start",overlayY:"center"});const{x:$e,y:Ft}=this._invertPosition(ze.overlayX,ze.overlayY);return{main:ze,fallback:{overlayX:$e,overlayY:Ft}}}_updateTooltipMessage(){this._tooltipInstance&&(this._tooltipInstance.message=this.message,this._tooltipInstance._markForCheck(),(0,y.mal)(()=>{this._tooltipInstance&&this._overlayRef.updatePosition()},{injector:this._injector}))}_setTooltipClass(qe){this._tooltipInstance&&(this._tooltipInstance.tooltipClass=qe,this._tooltipInstance._markForCheck())}_invertPosition(qe,_t){return"above"===this.position||"below"===this.position?"top"===_t?_t="bottom":"bottom"===_t&&(_t="top"):"end"===qe?qe="start":"start"===qe&&(qe="end"),{x:qe,y:_t}}_updateCurrentPositionClass(qe){const{overlayY:_t,originX:ze,originY:$e}=qe;let Ft;if(Ft="center"===_t?this._dir&&"rtl"===this._dir.value?"end"===ze?"left":"right":"start"===ze?"left":"right":"bottom"===_t&&"top"===$e?"above":"below",Ft!==this._currentPosition){const Ke=this._overlayRef;if(Ke){const Ze=`${this._cssClassPrefix}-${ue}-`;Ke.removePanelClass(Ze+this._currentPosition),Ke.addPanelClass(Ze+Ft)}this._currentPosition=Ft}}_setupPointerEnterEventsIfNeeded(){this._disabled||!this.message||!this._viewInitialized||this._passiveListeners.length||(this._platformSupportsMouseEvents()?this._passiveListeners.push(["mouseenter",qe=>{let _t;this._setupPointerExitEventsIfNeeded(),void 0!==qe.x&&void 0!==qe.y&&(_t=qe),this.show(void 0,_t)}]):"off"!==this.touchGestures&&(this._disableNativeGesturesIfNecessary(),this._passiveListeners.push(["touchstart",qe=>{const _t=qe.targetTouches?.[0],ze=_t?{x:_t.clientX,y:_t.clientY}:void 0;this._setupPointerExitEventsIfNeeded(),this._touchstartTimeout&&clearTimeout(this._touchstartTimeout),this._touchstartTimeout=setTimeout(()=>{this._touchstartTimeout=null,this.show(void 0,ze)},this._defaultOptions?.touchLongPressShowDelay??500)}])),this._addListeners(this._passiveListeners))}_setupPointerExitEventsIfNeeded(){if(this._pointerExitEventsInitialized)return;this._pointerExitEventsInitialized=!0;const qe=[];if(this._platformSupportsMouseEvents())qe.push(["mouseleave",_t=>{const ze=_t.relatedTarget;(!ze||!this._overlayRef?.overlayElement.contains(ze))&&this.hide()}],["wheel",_t=>this._wheelListener(_t)]);else if("off"!==this.touchGestures){this._disableNativeGesturesIfNecessary();const _t=()=>{this._touchstartTimeout&&clearTimeout(this._touchstartTimeout),this.hide(this._defaultOptions?.touchendHideDelay)};qe.push(["touchend",_t],["touchcancel",_t])}this._addListeners(qe),this._passiveListeners.push(...qe)}_addListeners(qe){qe.forEach(([_t,ze])=>{this._elementRef.nativeElement.addEventListener(_t,ze,Ce)})}_platformSupportsMouseEvents(){return!this._platform.IOS&&!this._platform.ANDROID}_wheelListener(qe){if(this._isTooltipVisible()){const _t=this._document.elementFromPoint(qe.clientX,qe.clientY),ze=this._elementRef.nativeElement;_t!==ze&&!ze.contains(_t)&&this.hide()}}_disableNativeGesturesIfNecessary(){const qe=this.touchGestures;if("off"!==qe){const _t=this._elementRef.nativeElement,ze=_t.style;("on"===qe||"INPUT"!==_t.nodeName&&"TEXTAREA"!==_t.nodeName)&&(ze.userSelect=ze.msUserSelect=ze.webkitUserSelect=ze.MozUserSelect="none"),("on"===qe||!_t.draggable)&&(ze.webkitUserDrag="none"),ze.touchAction="none",ze.webkitTapHighlightColor="transparent"}}_syncAriaDescription(qe){this._ariaDescriptionPending||(this._ariaDescriptionPending=!0,this._ariaDescriber.removeDescription(this._elementRef.nativeElement,qe,"tooltip"),this._ngZone.runOutsideAngular(()=>{Promise.resolve().then(()=>{this._ariaDescriptionPending=!1,this.message&&!this.disabled&&this._ariaDescriber.describe(this._elementRef.nativeElement,this.message,"tooltip")})}))}static \u0275fac=function(_t){return new(_t||Vn)};static \u0275dir=y.FsC({type:Vn,selectors:[["","matTooltip",""]],hostAttrs:[1,"mat-mdc-tooltip-trigger"],hostVars:2,hostBindings:function(_t,ze){2&_t&&y.AVh("mat-mdc-tooltip-disabled",ze.disabled)},inputs:{position:[0,"matTooltipPosition","position"],positionAtOrigin:[0,"matTooltipPositionAtOrigin","positionAtOrigin"],disabled:[0,"matTooltipDisabled","disabled"],showDelay:[0,"matTooltipShowDelay","showDelay"],hideDelay:[0,"matTooltipHideDelay","hideDelay"],touchGestures:[0,"matTooltipTouchGestures","touchGestures"],message:[0,"matTooltip","message"],tooltipClass:[0,"matTooltipClass","tooltipClass"]},exportAs:["matTooltip"]})}return Vn})(),rn=(()=>{class Vn{_changeDetectorRef=(0,y.WQX)(y.gRc);_elementRef=(0,y.WQX)(y.aKT);_isMultiline=!1;message;tooltipClass;_showTimeoutId;_hideTimeoutId;_triggerElement;_mouseLeaveHideDelay;_animationsDisabled;_tooltip;_closeOnInteraction=!1;_isVisible=!1;_onHide=new Z.B;_showAnimation="mat-mdc-tooltip-show";_hideAnimation="mat-mdc-tooltip-hide";constructor(){const qe=(0,y.WQX)(y.bc$,{optional:!0});this._animationsDisabled="NoopAnimations"===qe}show(qe){null!=this._hideTimeoutId&&clearTimeout(this._hideTimeoutId),this._showTimeoutId=setTimeout(()=>{this._toggleVisibility(!0),this._showTimeoutId=void 0},qe)}hide(qe){null!=this._showTimeoutId&&clearTimeout(this._showTimeoutId),this._hideTimeoutId=setTimeout(()=>{this._toggleVisibility(!1),this._hideTimeoutId=void 0},qe)}afterHidden(){return this._onHide}isVisible(){return this._isVisible}ngOnDestroy(){this._cancelPendingAnimations(),this._onHide.complete(),this._triggerElement=null}_handleBodyInteraction(){this._closeOnInteraction&&this.hide(0)}_markForCheck(){this._changeDetectorRef.markForCheck()}_handleMouseLeave({relatedTarget:qe}){(!qe||!this._triggerElement.contains(qe))&&(this.isVisible()?this.hide(this._mouseLeaveHideDelay):this._finalizeAnimation(!1))}_onShow(){this._isMultiline=this._isTooltipMultiline(),this._markForCheck()}_isTooltipMultiline(){const qe=this._elementRef.nativeElement.getBoundingClientRect();return qe.height>24&&qe.width>=200}_handleAnimationEnd({animationName:qe}){(qe===this._showAnimation||qe===this._hideAnimation)&&this._finalizeAnimation(qe===this._showAnimation)}_cancelPendingAnimations(){null!=this._showTimeoutId&&clearTimeout(this._showTimeoutId),null!=this._hideTimeoutId&&clearTimeout(this._hideTimeoutId),this._showTimeoutId=this._hideTimeoutId=void 0}_finalizeAnimation(qe){qe?this._closeOnInteraction=!0:this.isVisible()||this._onHide.next()}_toggleVisibility(qe){const _t=this._tooltip.nativeElement,ze=this._showAnimation,$e=this._hideAnimation;if(_t.classList.remove(qe?$e:ze),_t.classList.add(qe?ze:$e),this._isVisible!==qe&&(this._isVisible=qe,this._changeDetectorRef.markForCheck()),qe&&!this._animationsDisabled&&"function"==typeof getComputedStyle){const Ft=getComputedStyle(_t);("0s"===Ft.getPropertyValue("animation-duration")||"none"===Ft.getPropertyValue("animation-name"))&&(this._animationsDisabled=!0)}qe&&this._onShow(),this._animationsDisabled&&(_t.classList.add("_mat-animation-noopable"),this._finalizeAnimation(qe))}static \u0275fac=function(_t){return new(_t||Vn)};static \u0275cmp=y.VBU({type:Vn,selectors:[["mat-tooltip-component"]],viewQuery:function(_t,ze){if(1&_t&&y.GBs(pe,7),2&_t){let $e;y.mGM($e=y.lsd())&&(ze._tooltip=$e.first)}},hostAttrs:["aria-hidden","true"],hostBindings:function(_t,ze){1&_t&&y.bIt("mouseleave",function(Ft){return ze._handleMouseLeave(Ft)})},decls:4,vars:4,consts:[["tooltip",""],[1,"mdc-tooltip","mat-mdc-tooltip",3,"animationend","ngClass"],[1,"mat-mdc-tooltip-surface","mdc-tooltip__surface"]],template:function(_t,ze){if(1&_t){const $e=y.RV6();y.j41(0,"div",1,0),y.bIt("animationend",function(Ke){return y.eBV($e),y.Njj(ze._handleAnimationEnd(Ke))}),y.j41(2,"div",2),y.EFF(3),y.k0s()()}2&_t&&(y.AVh("mdc-tooltip--multiline",ze._isMultiline),y.Y8G("ngClass",ze.tooltipClass),y.R7$(3),y.JRh(ze.message))},dependencies:[w.YU],styles:['.mat-mdc-tooltip{position:relative;transform:scale(0);display:inline-flex}.mat-mdc-tooltip::before{content:"";top:0;right:0;bottom:0;left:0;z-index:-1;position:absolute}.mat-mdc-tooltip-panel-below .mat-mdc-tooltip::before{top:-8px}.mat-mdc-tooltip-panel-above .mat-mdc-tooltip::before{bottom:-8px}.mat-mdc-tooltip-panel-right .mat-mdc-tooltip::before{left:-8px}.mat-mdc-tooltip-panel-left .mat-mdc-tooltip::before{right:-8px}.mat-mdc-tooltip._mat-animation-noopable{animation:none;transform:scale(1)}.mat-mdc-tooltip-surface{word-break:normal;overflow-wrap:anywhere;padding:4px 8px;min-width:40px;max-width:200px;min-height:24px;max-height:40vh;box-sizing:border-box;overflow:hidden;text-align:center;will-change:transform,opacity;background-color:var(--mdc-plain-tooltip-container-color, var(--mat-sys-inverse-surface));color:var(--mdc-plain-tooltip-supporting-text-color, var(--mat-sys-inverse-on-surface));border-radius:var(--mdc-plain-tooltip-container-shape, var(--mat-sys-corner-extra-small));font-family:var(--mdc-plain-tooltip-supporting-text-font, var(--mat-sys-body-small-font));font-size:var(--mdc-plain-tooltip-supporting-text-size, var(--mat-sys-body-small-size));font-weight:var(--mdc-plain-tooltip-supporting-text-weight, var(--mat-sys-body-small-weight));line-height:var(--mdc-plain-tooltip-supporting-text-line-height, var(--mat-sys-body-small-line-height));letter-spacing:var(--mdc-plain-tooltip-supporting-text-tracking, var(--mat-sys-body-small-tracking))}.mat-mdc-tooltip-surface::before{position:absolute;box-sizing:border-box;width:100%;height:100%;top:0;left:0;border:1px solid rgba(0,0,0,0);border-radius:inherit;content:"";pointer-events:none}.mdc-tooltip--multiline .mat-mdc-tooltip-surface{text-align:left}[dir=rtl] .mdc-tooltip--multiline .mat-mdc-tooltip-surface{text-align:right}.mat-mdc-tooltip-panel.mat-mdc-tooltip-panel-non-interactive{pointer-events:none}@keyframes mat-mdc-tooltip-show{0%{opacity:0;transform:scale(0.8)}100%{opacity:1;transform:scale(1)}}@keyframes mat-mdc-tooltip-hide{0%{opacity:1;transform:scale(1)}100%{opacity:0;transform:scale(0.8)}}.mat-mdc-tooltip-show{animation:mat-mdc-tooltip-show 150ms cubic-bezier(0, 0, 0.2, 1) forwards}.mat-mdc-tooltip-hide{animation:mat-mdc-tooltip-hide 75ms cubic-bezier(0.4, 0, 1, 1) forwards}'],encapsulation:2,changeDetection:0})}return Vn})(),bn=(()=>{class Vn{static \u0275fac=function(_t){return new(_t||Vn)};static \u0275mod=y.$C({type:Vn});static \u0275inj=y.G2t({providers:[Oe],imports:[T.Pd,M.z_,re.yE,re.yE,O.Gj]})}return Vn})()},6388:(o,s,r)=>{"use strict";r.d(s,{B7:()=>bt,B8:()=>Ze,hE:()=>Nr,up:()=>an});var i=r(4460),a=r(3107);class c extends i.VF{supportsDOMEvents=!0}class y extends c{static makeCurrent(){(0,i.ZD)(new y)}onAndCancel(Dt,ct,Bt){return Dt.addEventListener(ct,Bt),()=>{Dt.removeEventListener(ct,Bt)}}dispatchEvent(Dt,ct){Dt.dispatchEvent(ct)}remove(Dt){Dt.remove()}createElement(Dt,ct){return(ct=ct||this.getDefaultDocument()).createElement(Dt)}createHtmlDocument(){return document.implementation.createHTMLDocument("fakeTitle")}getDefaultDocument(){return document}isElementNode(Dt){return Dt.nodeType===Node.ELEMENT_NODE}isShadowRoot(Dt){return Dt instanceof DocumentFragment}getGlobalEventTarget(Dt,ct){return"window"===ct?window:"document"===ct?Dt:"body"===ct?Dt.body:null}getBaseHref(Dt){const ct=function C(){return w=w||document.querySelector("base"),w?w.getAttribute("href"):null}();return null==ct?null:function T(Ve){return new URL(Ve,document.baseURI).pathname}(ct)}resetBaseElement(){w=null}getUserAgent(){return window.navigator.userAgent}getCookie(Dt){return(0,i._b)(document.cookie,Dt)}}let w=null,M=(()=>{class Ve{build(){return new XMLHttpRequest}static \u0275fac=function(Bt){return new(Bt||Ve)};static \u0275prov=a.jDH({token:Ve,factory:Ve.\u0275fac})}return Ve})();const O=new a.nKC("");let L=(()=>{class Ve{_zone;_plugins;_eventNameToPlugin=new Map;constructor(ct,Bt){this._zone=Bt,ct.forEach(wn=>{wn.manager=this}),this._plugins=ct.slice().reverse()}addEventListener(ct,Bt,wn){return this._findPluginFor(Bt).addEventListener(ct,Bt,wn)}getZone(){return this._zone}_findPluginFor(ct){let Bt=this._eventNameToPlugin.get(ct);if(Bt)return Bt;if(Bt=this._plugins.find(qn=>qn.supports(ct)),!Bt)throw new a.wOt(5101,!1);return this._eventNameToPlugin.set(ct,Bt),Bt}static \u0275fac=function(Bt){return new(Bt||Ve)(a.KVO(O),a.KVO(a.SKi))};static \u0275prov=a.jDH({token:Ve,factory:Ve.\u0275fac})}return Ve})();class Z{_doc;constructor(Dt){this._doc=Dt}manager}const q="ng-app-id";function re(Ve){for(const Dt of Ve)Dt.remove()}function pe(Ve,Dt){const ct=Dt.createElement("style");return ct.textContent=Ve,ct}function ae(Ve,Dt){const ct=Dt.createElement("link");return ct.setAttribute("rel","stylesheet"),ct.setAttribute("href",Ve),ct}let me=(()=>{class Ve{doc;appId;nonce;inline=new Map;external=new Map;hosts=new Set;isServer;constructor(ct,Bt,wn,qn={}){this.doc=ct,this.appId=Bt,this.nonce=wn,this.isServer=(0,i.Vy)(qn),function se(Ve,Dt,ct){const Bt=Ve.head?.querySelectorAll(`style[${q}="${Dt}"]`);if(Bt)for(const wn of Bt)wn.textContent&&(wn.removeAttribute(q),ct.set(wn.textContent,{usage:0,elements:[wn]}))}(ct,Bt,this.inline),this.hosts.add(ct.head)}addStyles(ct,Bt){for(const wn of ct)this.addUsage(wn,this.inline,pe);Bt?.forEach(wn=>this.addUsage(wn,this.external,ae))}removeStyles(ct,Bt){for(const wn of ct)this.removeUsage(wn,this.inline);Bt?.forEach(wn=>this.removeUsage(wn,this.external))}addUsage(ct,Bt,wn){const qn=Bt.get(ct);qn?qn.usage++:Bt.set(ct,{usage:1,elements:[...this.hosts].map(Er=>this.addElement(Er,wn(ct,this.doc)))})}removeUsage(ct,Bt){const wn=Bt.get(ct);wn&&(wn.usage--,wn.usage<=0&&(re(wn.elements),Bt.delete(ct)))}ngOnDestroy(){for(const[,{elements:ct}]of[...this.inline,...this.external])re(ct);this.hosts.clear()}addHost(ct){this.hosts.add(ct);for(const[Bt,{elements:wn}]of this.inline)wn.push(this.addElement(ct,pe(Bt,this.doc)));for(const[Bt,{elements:wn}]of this.external)wn.push(this.addElement(ct,ae(Bt,this.doc)))}removeHost(ct){this.hosts.delete(ct)}addElement(ct,Bt){return this.nonce&&Bt.setAttribute("nonce",this.nonce),this.isServer&&Bt.setAttribute(q,this.appId),ct.appendChild(Bt)}static \u0275fac=function(Bt){return new(Bt||Ve)(a.KVO(i.qQ),a.KVO(a.sZ2),a.KVO(a.BIS,8),a.KVO(a.Agw))};static \u0275prov=a.jDH({token:Ve,factory:Ve.\u0275fac})}return Ve})();const be={svg:"http://www.w3.org/2000/svg",xhtml:"http://www.w3.org/1999/xhtml",xlink:"http://www.w3.org/1999/xlink",xml:"http://www.w3.org/XML/1998/namespace",xmlns:"http://www.w3.org/2000/xmlns/",math:"http://www.w3.org/1998/Math/MathML"},Oe=/%COMP%/g,Ce=new a.nKC("",{providedIn:"root",factory:()=>!0});function dt(Ve,Dt){return Dt.map(ct=>ct.replace(Oe,Ve))}let bt=(()=>{class Ve{eventManager;sharedStylesHost;appId;removeStylesOnCompDestroy;doc;platformId;ngZone;nonce;rendererByCompId=new Map;defaultRenderer;platformIsServer;constructor(ct,Bt,wn,qn,Er,si,hi,Zi=null){this.eventManager=ct,this.sharedStylesHost=Bt,this.appId=wn,this.removeStylesOnCompDestroy=qn,this.doc=Er,this.platformId=si,this.ngZone=hi,this.nonce=Zi,this.platformIsServer=(0,i.Vy)(si),this.defaultRenderer=new lt(ct,Er,hi,this.platformIsServer)}createRenderer(ct,Bt){if(!ct||!Bt)return this.defaultRenderer;this.platformIsServer&&Bt.encapsulation===a.gXe.ShadowDom&&(Bt={...Bt,encapsulation:a.gXe.Emulated});const wn=this.getOrCreateRenderer(ct,Bt);return wn instanceof qe?wn.applyToHost(ct):wn instanceof yn&&wn.applyStyles(),wn}getOrCreateRenderer(ct,Bt){const wn=this.rendererByCompId;let qn=wn.get(Bt.id);if(!qn){const Er=this.doc,si=this.ngZone,hi=this.eventManager,Zi=this.sharedStylesHost,Jt=this.removeStylesOnCompDestroy,Tt=this.platformIsServer;switch(Bt.encapsulation){case a.gXe.Emulated:qn=new qe(hi,Zi,Bt,this.appId,Jt,Er,si,Tt);break;case a.gXe.ShadowDom:return new Vn(hi,Zi,ct,Bt,Er,si,this.nonce,Tt);default:qn=new yn(hi,Zi,Bt,Jt,Er,si,Tt)}wn.set(Bt.id,qn)}return qn}ngOnDestroy(){this.rendererByCompId.clear()}static \u0275fac=function(Bt){return new(Bt||Ve)(a.KVO(L),a.KVO(me),a.KVO(a.sZ2),a.KVO(Ce),a.KVO(i.qQ),a.KVO(a.Agw),a.KVO(a.SKi),a.KVO(a.BIS))};static \u0275prov=a.jDH({token:Ve,factory:Ve.\u0275fac})}return Ve})();class lt{eventManager;doc;ngZone;platformIsServer;data=Object.create(null);throwOnSyntheticProps=!0;constructor(Dt,ct,Bt,wn){this.eventManager=Dt,this.doc=ct,this.ngZone=Bt,this.platformIsServer=wn}destroy(){}destroyNode=null;createElement(Dt,ct){return ct?this.doc.createElementNS(be[ct]||ct,Dt):this.doc.createElement(Dt)}createComment(Dt){return this.doc.createComment(Dt)}createText(Dt){return this.doc.createTextNode(Dt)}appendChild(Dt,ct){(bn(Dt)?Dt.content:Dt).appendChild(ct)}insertBefore(Dt,ct,Bt){Dt&&(bn(Dt)?Dt.content:Dt).insertBefore(ct,Bt)}removeChild(Dt,ct){ct.remove()}selectRootElement(Dt,ct){let Bt="string"==typeof Dt?this.doc.querySelector(Dt):Dt;if(!Bt)throw new a.wOt(-5104,!1);return ct||(Bt.textContent=""),Bt}parentNode(Dt){return Dt.parentNode}nextSibling(Dt){return Dt.nextSibling}setAttribute(Dt,ct,Bt,wn){if(wn){ct=wn+":"+ct;const qn=be[wn];qn?Dt.setAttributeNS(qn,ct,Bt):Dt.setAttribute(ct,Bt)}else Dt.setAttribute(ct,Bt)}removeAttribute(Dt,ct,Bt){if(Bt){const wn=be[Bt];wn?Dt.removeAttributeNS(wn,ct):Dt.removeAttribute(`${Bt}:${ct}`)}else Dt.removeAttribute(ct)}addClass(Dt,ct){Dt.classList.add(ct)}removeClass(Dt,ct){Dt.classList.remove(ct)}setStyle(Dt,ct,Bt,wn){wn&(a.czy.DashCase|a.czy.Important)?Dt.style.setProperty(ct,Bt,wn&a.czy.Important?"important":""):Dt.style[ct]=Bt}removeStyle(Dt,ct,Bt){Bt&a.czy.DashCase?Dt.style.removeProperty(ct):Dt.style[ct]=""}setProperty(Dt,ct,Bt){null!=Dt&&(Dt[ct]=Bt)}setValue(Dt,ct){Dt.nodeValue=ct}listen(Dt,ct,Bt){if("string"==typeof Dt&&!(Dt=(0,i.QT)().getGlobalEventTarget(this.doc,Dt)))throw new Error(`Unsupported event target ${Dt} for event ${ct}`);return this.eventManager.addEventListener(Dt,ct,this.decoratePreventDefault(Bt))}decoratePreventDefault(Dt){return ct=>{if("__ngUnwrap__"===ct)return Dt;!1===(this.platformIsServer?this.ngZone.runGuarded(()=>Dt(ct)):Dt(ct))&&ct.preventDefault()}}}function bn(Ve){return"TEMPLATE"===Ve.tagName&&void 0!==Ve.content}class Vn extends lt{sharedStylesHost;hostEl;shadowRoot;constructor(Dt,ct,Bt,wn,qn,Er,si,hi){super(Dt,qn,Er,hi),this.sharedStylesHost=ct,this.hostEl=Bt,this.shadowRoot=Bt.attachShadow({mode:"open"}),this.sharedStylesHost.addHost(this.shadowRoot);const Zi=dt(wn.id,wn.styles);for(const Tt of Zi){const nt=document.createElement("style");si&&nt.setAttribute("nonce",si),nt.textContent=Tt,this.shadowRoot.appendChild(nt)}const Jt=wn.getExternalStyles?.();if(Jt)for(const Tt of Jt){const nt=ae(Tt,qn);si&&nt.setAttribute("nonce",si),this.shadowRoot.appendChild(nt)}}nodeOrShadowRoot(Dt){return Dt===this.hostEl?this.shadowRoot:Dt}appendChild(Dt,ct){return super.appendChild(this.nodeOrShadowRoot(Dt),ct)}insertBefore(Dt,ct,Bt){return super.insertBefore(this.nodeOrShadowRoot(Dt),ct,Bt)}removeChild(Dt,ct){return super.removeChild(null,ct)}parentNode(Dt){return this.nodeOrShadowRoot(super.parentNode(this.nodeOrShadowRoot(Dt)))}destroy(){this.sharedStylesHost.removeHost(this.shadowRoot)}}class yn extends lt{sharedStylesHost;removeStylesOnCompDestroy;styles;styleUrls;constructor(Dt,ct,Bt,wn,qn,Er,si,hi){super(Dt,qn,Er,si),this.sharedStylesHost=ct,this.removeStylesOnCompDestroy=wn,this.styles=hi?dt(hi,Bt.styles):Bt.styles,this.styleUrls=Bt.getExternalStyles?.(hi)}applyStyles(){this.sharedStylesHost.addStyles(this.styles,this.styleUrls)}destroy(){this.removeStylesOnCompDestroy&&this.sharedStylesHost.removeStyles(this.styles,this.styleUrls)}}class qe extends yn{contentAttr;hostAttr;constructor(Dt,ct,Bt,wn,qn,Er,si,hi){const Zi=wn+"-"+Bt.id;super(Dt,ct,Bt,qn,Er,si,hi,Zi),this.contentAttr=function Be(Ve){return"_ngcontent-%COMP%".replace(Oe,Ve)}(Zi),this.hostAttr=function at(Ve){return"_nghost-%COMP%".replace(Oe,Ve)}(Zi)}applyToHost(Dt){this.applyStyles(),this.setAttribute(Dt,this.hostAttr,"")}createElement(Dt,ct){const Bt=super.createElement(Dt,ct);return super.setAttribute(Bt,this.contentAttr,""),Bt}}let _t=(()=>{class Ve extends Z{constructor(ct){super(ct)}supports(ct){return!0}addEventListener(ct,Bt,wn){return ct.addEventListener(Bt,wn,!1),()=>this.removeEventListener(ct,Bt,wn)}removeEventListener(ct,Bt,wn){return ct.removeEventListener(Bt,wn)}static \u0275fac=function(Bt){return new(Bt||Ve)(a.KVO(i.qQ))};static \u0275prov=a.jDH({token:Ve,factory:Ve.\u0275fac})}return Ve})();const ze=["alt","control","meta","shift"],$e={"\b":"Backspace","\t":"Tab","\x7f":"Delete","\x1b":"Escape",Del:"Delete",Esc:"Escape",Left:"ArrowLeft",Right:"ArrowRight",Up:"ArrowUp",Down:"ArrowDown",Menu:"ContextMenu",Scroll:"ScrollLock",Win:"OS"},Ft={alt:Ve=>Ve.altKey,control:Ve=>Ve.ctrlKey,meta:Ve=>Ve.metaKey,shift:Ve=>Ve.shiftKey};let Ke=(()=>{class Ve extends Z{constructor(ct){super(ct)}supports(ct){return null!=Ve.parseEventName(ct)}addEventListener(ct,Bt,wn){const qn=Ve.parseEventName(Bt),Er=Ve.eventCallback(qn.fullKey,wn,this.manager.getZone());return this.manager.getZone().runOutsideAngular(()=>(0,i.QT)().onAndCancel(ct,qn.domEventName,Er))}static parseEventName(ct){const Bt=ct.toLowerCase().split("."),wn=Bt.shift();if(0===Bt.length||"keydown"!==wn&&"keyup"!==wn)return null;const qn=Ve._normalizeKey(Bt.pop());let Er="",si=Bt.indexOf("code");if(si>-1&&(Bt.splice(si,1),Er="code."),ze.forEach(Zi=>{const Jt=Bt.indexOf(Zi);Jt>-1&&(Bt.splice(Jt,1),Er+=Zi+".")}),Er+=qn,0!=Bt.length||0===qn.length)return null;const hi={};return hi.domEventName=wn,hi.fullKey=Er,hi}static matchEventFullKeyCode(ct,Bt){let wn=$e[ct.key]||ct.key,qn="";return Bt.indexOf("code.")>-1&&(wn=ct.code,qn="code."),!(null==wn||!wn)&&(wn=wn.toLowerCase()," "===wn?wn="space":"."===wn&&(wn="dot"),ze.forEach(Er=>{Er!==wn&&(0,Ft[Er])(ct)&&(qn+=Er+".")}),qn+=wn,qn===Bt)}static eventCallback(ct,Bt,wn){return qn=>{Ve.matchEventFullKeyCode(qn,ct)&&wn.runGuarded(()=>Bt(qn))}}static _normalizeKey(ct){return"esc"===ct?"escape":ct}static \u0275fac=function(Bt){return new(Bt||Ve)(a.KVO(i.qQ))};static \u0275prov=a.jDH({token:Ve,factory:Ve.\u0275fac})}return Ve})();function Ze(Ve,Dt){return(0,a.TL3)({rootComponent:Ve,...Ot(Dt)})}function Ot(Ve){return{appProviders:[...Vt,...Ve?.providers??[]],platformProviders:Xt}}const Xt=[{provide:a.Agw,useValue:i.AJ},{provide:a.PLl,useValue:function Te(){y.makeCurrent()},multi:!0},{provide:i.qQ,useFactory:function st(){return(0,a.TL$)(document),document},deps:[]}],Vt=[{provide:a.H8p,useValue:"root"},{provide:a.zcH,useFactory:function Ee(){return new a.zcH},deps:[]},{provide:O,useClass:_t,multi:!0,deps:[i.qQ,a.SKi,a.Agw]},{provide:O,useClass:Ke,multi:!0,deps:[i.qQ]},bt,me,L,{provide:a._9s,useExisting:bt},{provide:i.N0,useClass:M,deps:[]},[]];let Nr=(()=>{class Ve{_doc;constructor(ct){this._doc=ct}getTitle(){return this._doc.title}setTitle(ct){this._doc.title=ct||""}static \u0275fac=function(Bt){return new(Bt||Ve)(a.KVO(i.qQ))};static \u0275prov=a.jDH({token:Ve,factory:Ve.\u0275fac,providedIn:"root"})}return Ve})(),an=(()=>{class Ve{static \u0275fac=function(Bt){return new(Bt||Ve)};static \u0275prov=a.jDH({token:Ve,factory:function(Bt){let wn=null;return wn=Bt?new(Bt||Ve):a.KVO(dn),wn},providedIn:"root"})}return Ve})(),dn=(()=>{class Ve extends an{_doc;constructor(ct){super(),this._doc=ct}sanitize(ct,Bt){if(null==Bt)return null;switch(ct){case a.WPN.NONE:return Bt;case a.WPN.HTML:return(0,a.ZF7)(Bt,"HTML")?(0,a.rcV)(Bt):(0,a.h9k)(this._doc,String(Bt)).toString();case a.WPN.STYLE:return(0,a.ZF7)(Bt,"Style")?(0,a.rcV)(Bt):Bt;case a.WPN.SCRIPT:if((0,a.ZF7)(Bt,"Script"))return(0,a.rcV)(Bt);throw new a.wOt(5200,!1);case a.WPN.URL:return(0,a.ZF7)(Bt,"URL")?(0,a.rcV)(Bt):(0,a.$MX)(String(Bt));case a.WPN.RESOURCE_URL:if((0,a.ZF7)(Bt,"ResourceURL"))return(0,a.rcV)(Bt);throw new a.wOt(5201,!1);default:throw new a.wOt(5202,!1)}}bypassSecurityTrustHtml(ct){return(0,a.Kcf)(ct)}bypassSecurityTrustStyle(ct){return(0,a.cWb)(ct)}bypassSecurityTrustScript(ct){return(0,a.UyX)(ct)}bypassSecurityTrustUrl(ct){return(0,a.osQ)(ct)}bypassSecurityTrustResourceUrl(ct){return(0,a.e5t)(ct)}static \u0275fac=function(Bt){return new(Bt||Ve)(a.KVO(i.qQ))};static \u0275prov=a.jDH({token:Ve,factory:Ve.\u0275fac,providedIn:"root"})}return Ve})()},8716:(o,s,r)=>{"use strict";r.d(s,{nX:()=>_o,wF:()=>Ye,Ix:()=>li,Wk:()=>bs,wQ:()=>Lo,iI:()=>Wa,n3:()=>ca,lh:()=>ou,oH:()=>Wl});var i=r(3107),a=r(1531),c=r(1787),y=r(3016),w=r(1217),C=r(6627),T=r(8747),S=r(3569),M=r(6381),O=r(6742),L=r(8915),Z=r(6564),q=r(1642),re=r(8447),pe=r(5710),se=r(4460),ae=r(7947),me=r(2867),be=r(7610),Oe=r(593),xe=r(1483),De=r(5823),ce=r(1703),ue=r(1459),Ce=r(2040),Be=r(7178),at=r(5351),dt=r(36),lt=r(5670),rn=r(2483);function gn(R){return R<=0?()=>Z.w:(0,at.N)((G,F)=>{let K=[];G.subscribe((0,rn._)(F,_e=>{K.push(_e),R{for(const _e of K)F.next(_e);F.complete()},void 0,()=>{K=null}))})}var bn=r(5017),Vn=r(9220),qe=r(6590),_t=r(4447),ze=r(3589),$e=r(5424),Ft=r(1890),Ke=r(6388);const Ze="primary",it=Symbol("RouteTitle");class Ot{params;constructor(G){this.params=G||{}}has(G){return Object.prototype.hasOwnProperty.call(this.params,G)}get(G){if(this.has(G)){const F=this.params[G];return Array.isArray(F)?F[0]:F}return null}getAll(G){if(this.has(G)){const F=this.params[G];return Array.isArray(F)?F:[F]}return[]}get keys(){return Object.keys(this.params)}}function $t(R){return new Ot(R)}function Te(R,G,F){const K=F.path.split("/");if(K.length>R.length||"full"===F.pathMatch&&(G.hasChildren()||K.lengthK[We]===_e)}return R===G}function Kt(R){return R.length>0?R[R.length-1]:null}function rt(R){return(0,a.A)(R)?R:(0,i.jNT)(R)?(0,c.H)(Promise.resolve(R)):(0,y.of)(R)}const Vt={exact:function Nr(R,G,F){if(!W(R.segments,G.segments)||!Fe(R.segments,G.segments,F)||R.numberOfChildren!==G.numberOfChildren)return!1;for(const K in G.children)if(!R.children[K]||!Nr(R.children[K],G.children[K],F))return!1;return!0},subset:pr},en={exact:function Kn(R,G){return st(R,G)},subset:function Rn(R,G){return Object.keys(G).length<=Object.keys(R).length&&Object.keys(G).every(F=>Mt(R[F],G[F]))},ignored:()=>!0};function kn(R,G,F){return Vt[F.paths](R.root,G.root,F.matrixParams)&&en[F.queryParams](R.queryParams,G.queryParams)&&!("exact"===F.fragment&&R.fragment!==G.fragment)}function pr(R,G,F){return cn(R,G,G.segments,F)}function cn(R,G,F,K){if(R.segments.length>F.length){const _e=R.segments.slice(0,F.length);return!(!W(_e,F)||G.hasChildren()||!Fe(_e,F,K))}if(R.segments.length===F.length){if(!W(R.segments,F)||!Fe(R.segments,F,K))return!1;for(const _e in G.children)if(!R.children[_e]||!pr(R.children[_e],G.children[_e],K))return!1;return!0}{const _e=F.slice(0,R.segments.length),We=F.slice(R.segments.length);return!!(W(R.segments,_e)&&Fe(R.segments,_e,K)&&R.children[Ze])&&cn(R.children[Ze],G,We,K)}}function Fe(R,G,F){return G.every((K,_e)=>en[F](R[_e].parameters,K.parameters))}class ke{root;queryParams;fragment;_queryParamMap;constructor(G=new Je([],{}),F={},K=null){this.root=G,this.queryParams=F,this.fragment=K}get queryParamMap(){return this._queryParamMap??=$t(this.queryParams),this._queryParamMap}toString(){return St.serialize(this)}}class Je{segments;children;parent=null;constructor(G,F){this.segments=G,this.children=F,Object.values(F).forEach(K=>K.parent=this)}hasChildren(){return this.numberOfChildren>0}get numberOfChildren(){return Object.keys(this.children).length}toString(){return Tn(this)}}class z{path;parameters;_parameterMap;constructor(G,F){this.path=G,this.parameters=F}get parameterMap(){return this._parameterMap??=$t(this.parameters),this._parameterMap}toString(){return Vr(this)}}function W(R,G){return R.length===G.length&&R.every((F,K)=>F.path===G[K].path)}let ft=(()=>{class R{static \u0275fac=function(K){return new(K||R)};static \u0275prov=i.jDH({token:R,factory:()=>new mt,providedIn:"root"})}return R})();class mt{parse(G){const F=new Er(G);return new ke(F.parseRootSegment(),F.parseQueryParams(),F.parseFragment())}serialize(G){const F=`/${an(G.root,!0)}`,K=function Wt(R){const G=Object.entries(R).map(([F,K])=>Array.isArray(K)?K.map(_e=>`${In(F)}=${In(_e)}`).join("&"):`${In(F)}=${In(K)}`).filter(F=>F);return G.length?`?${G.join("&")}`:""}(G.queryParams);return`${F}${K}${"string"==typeof G.fragment?`#${function sr(R){return encodeURI(R)}(G.fragment)}`:""}`}}const St=new mt;function Tn(R){return R.segments.map(G=>Vr(G)).join("/")}function an(R,G){if(!R.hasChildren())return Tn(R);if(G){const F=R.children[Ze]?an(R.children[Ze],!1):"",K=[];return Object.entries(R.children).forEach(([_e,We])=>{_e!==Ze&&K.push(`${_e}:${an(We,!1)}`)}),K.length>0?`${F}(${K.join("//")})`:F}{const F=function Le(R,G){let F=[];return Object.entries(R.children).forEach(([K,_e])=>{K===Ze&&(F=F.concat(G(_e,K)))}),Object.entries(R.children).forEach(([K,_e])=>{K!==Ze&&(F=F.concat(G(_e,K)))}),F}(R,(K,_e)=>_e===Ze?[an(R.children[Ze],!1)]:[`${_e}:${an(K,!1)}`]);return 1===Object.keys(R.children).length&&null!=R.children[Ze]?`${Tn(R)}/${F[0]}`:`${Tn(R)}/(${F.join("//")})`}}function dn(R){return encodeURIComponent(R).replace(/%40/g,"@").replace(/%3A/gi,":").replace(/%24/g,"$").replace(/%2C/gi,",")}function In(R){return dn(R).replace(/%3B/gi,";")}function xn(R){return dn(R).replace(/\(/g,"%28").replace(/\)/g,"%29").replace(/%26/gi,"&")}function Hr(R){return decodeURIComponent(R)}function Tr(R){return Hr(R.replace(/\+/g,"%20"))}function Vr(R){return`${xn(R.path)}${function vt(R){return Object.entries(R).map(([G,F])=>`;${xn(G)}=${xn(F)}`).join("")}(R.parameters)}`}const Re=/^[^\/()?;#]+/;function Ge(R){const G=R.match(Re);return G?G[0]:""}const Ve=/^[^\/()?;=#]+/,ct=/^[^=?&#]+/,wn=/^[^&#]+/;class Er{url;remaining;constructor(G){this.url=G,this.remaining=G}parseRootSegment(){return this.consumeOptional("/"),""===this.remaining||this.peekStartsWith("?")||this.peekStartsWith("#")?new Je([],{}):new Je([],this.parseChildren())}parseQueryParams(){const G={};if(this.consumeOptional("?"))do{this.parseQueryParam(G)}while(this.consumeOptional("&"));return G}parseFragment(){return this.consumeOptional("#")?decodeURIComponent(this.remaining):null}parseChildren(){if(""===this.remaining)return{};this.consumeOptional("/");const G=[];for(this.peekStartsWith("(")||G.push(this.parseSegment());this.peekStartsWith("/")&&!this.peekStartsWith("//")&&!this.peekStartsWith("/(");)this.capture("/"),G.push(this.parseSegment());let F={};this.peekStartsWith("/(")&&(this.capture("/"),F=this.parseParens(!0));let K={};return this.peekStartsWith("(")&&(K=this.parseParens(!1)),(G.length>0||Object.keys(F).length>0)&&(K[Ze]=new Je(G,F)),K}parseSegment(){const G=Ge(this.remaining);if(""===G&&this.peekStartsWith(";"))throw new i.wOt(4009,!1);return this.capture(G),new z(Hr(G),this.parseMatrixParams())}parseMatrixParams(){const G={};for(;this.consumeOptional(";");)this.parseParam(G);return G}parseParam(G){const F=function Dt(R){const G=R.match(Ve);return G?G[0]:""}(this.remaining);if(!F)return;this.capture(F);let K="";if(this.consumeOptional("=")){const _e=Ge(this.remaining);_e&&(K=_e,this.capture(K))}G[Hr(F)]=Hr(K)}parseQueryParam(G){const F=function Bt(R){const G=R.match(ct);return G?G[0]:""}(this.remaining);if(!F)return;this.capture(F);let K="";if(this.consumeOptional("=")){const At=function qn(R){const G=R.match(wn);return G?G[0]:""}(this.remaining);At&&(K=At,this.capture(K))}const _e=Tr(F),We=Tr(K);if(G.hasOwnProperty(_e)){let At=G[_e];Array.isArray(At)||(At=[At],G[_e]=At),At.push(We)}else G[_e]=We}parseParens(G){const F={};for(this.capture("(");!this.consumeOptional(")")&&this.remaining.length>0;){const K=Ge(this.remaining),_e=this.remaining[K.length];if("/"!==_e&&")"!==_e&&";"!==_e)throw new i.wOt(4010,!1);let We;K.indexOf(":")>-1?(We=K.slice(0,K.indexOf(":")),this.capture(We),this.capture(":")):G&&(We=Ze);const At=this.parseChildren();F[We]=1===Object.keys(At).length?At[Ze]:new Je([],At),this.consumeOptional("//")}return F}peekStartsWith(G){return this.remaining.startsWith(G)}consumeOptional(G){return!!this.peekStartsWith(G)&&(this.remaining=this.remaining.substring(G.length),!0)}capture(G){if(!this.consumeOptional(G))throw new i.wOt(4011,!1)}}function si(R){return R.segments.length>0?new Je([],{[Ze]:R}):R}function hi(R){const G={};for(const[K,_e]of Object.entries(R.children)){const We=hi(_e);if(K===Ze&&0===We.segments.length&&We.hasChildren())for(const[At,fn]of Object.entries(We.children))G[At]=fn;else(We.segments.length>0||We.hasChildren())&&(G[K]=We)}return function Zi(R){if(1===R.numberOfChildren&&R.children[Ze]){const G=R.children[Ze];return new Je(R.segments.concat(G.segments),G.children)}return R}(new Je(R.segments,G))}function Jt(R){return R instanceof ke}function nt(R){let G;const _e=si(function F(We){const At={};for(const on of We.children){const ur=F(on);At[on.outlet]=ur}const fn=new Je(We.url,At);return We===R&&(G=fn),fn}(R.root));return G??_e}function Rt(R,G,F,K){let _e=R;for(;_e.parent;)_e=_e.parent;if(0===G.length)return dr(_e,_e,_e,F,K);const We=function ds(R){if("string"==typeof R[0]&&1===R.length&&"/"===R[0])return new Ni(!0,0,R);let G=0,F=!1;const K=R.reduce((_e,We,At)=>{if("object"==typeof We&&null!=We){if(We.outlets){const fn={};return Object.entries(We.outlets).forEach(([on,ur])=>{fn[on]="string"==typeof ur?ur.split("/"):ur}),[..._e,{outlets:fn}]}if(We.segmentPath)return[..._e,We.segmentPath]}return"string"!=typeof We?[..._e,We]:0===At?(We.split("/").forEach((fn,on)=>{0==on&&"."===fn||(0==on&&""===fn?F=!0:".."===fn?G++:""!=fn&&_e.push(fn))}),_e):[..._e,We]},[]);return new Ni(F,G,K)}(G);if(We.toRoot())return dr(_e,_e,new Je([],{}),F,K);const At=function ai(R,G,F){if(R.isAbsolute)return new $o(G,!0,0);if(!F)return new $o(G,!1,NaN);if(null===F.parent)return new $o(F,!0,0);const K=sn(R.commands[0])?0:1;return function qo(R,G,F){let K=R,_e=G,We=F;for(;We>_e;){if(We-=_e,K=K.parent,!K)throw new i.wOt(4005,!1);_e=K.segments.length}return new $o(K,!1,_e-We)}(F,F.segments.length-1+K,R.numberOfDoubleDots)}(We,_e,R),fn=At.processChildren?Fo(At.segmentGroup,At.index,We.commands):Jo(At.segmentGroup,At.index,We.commands);return dr(_e,At.segmentGroup,fn,F,K)}function sn(R){return"object"==typeof R&&null!=R&&!R.outlets&&!R.segmentPath}function mn(R){return"object"==typeof R&&null!=R&&R.outlets}function dr(R,G,F,K,_e){let At,We={};K&&Object.entries(K).forEach(([on,ur])=>{We[on]=Array.isArray(ur)?ur.map(ui=>`${ui}`):`${ur}`}),At=R===G?F:Co(R,G,F);const fn=si(hi(At));return new ke(fn,We,_e)}function Co(R,G,F){const K={};return Object.entries(R.children).forEach(([_e,We])=>{K[_e]=We===G?F:Co(We,G,F)}),new Je(R.segments,K)}class Ni{isAbsolute;numberOfDoubleDots;commands;constructor(G,F,K){if(this.isAbsolute=G,this.numberOfDoubleDots=F,this.commands=K,G&&K.length>0&&sn(K[0]))throw new i.wOt(4003,!1);const _e=K.find(mn);if(_e&&_e!==Kt(K))throw new i.wOt(4004,!1)}toRoot(){return this.isAbsolute&&1===this.commands.length&&"/"==this.commands[0]}}class $o{segmentGroup;processChildren;index;constructor(G,F,K){this.segmentGroup=G,this.processChildren=F,this.index=K}}function Jo(R,G,F){if(R??=new Je([],{}),0===R.segments.length&&R.hasChildren())return Fo(R,G,F);const K=function oa(R,G,F){let K=0,_e=G;const We={match:!1,pathIndex:0,commandIndex:0};for(;_e=F.length)return We;const At=R.segments[_e],fn=F[K];if(mn(fn))break;const on=`${fn}`,ur=K0&&void 0===on)break;if(on&&ur&&"object"==typeof ur&&void 0===ur.outlets){if(!Io(on,ur,At))return We;K+=2}else{if(!Io(on,{},At))return We;K++}_e++}return{match:!0,pathIndex:_e,commandIndex:K}}(R,G,F),_e=F.slice(K.commandIndex);if(K.match&&K.pathIndexWe!==Ze)&&R.children[Ze]&&1===R.numberOfChildren&&0===R.children[Ze].segments.length){const We=Fo(R.children[Ze],G,F);return new Je(R.segments,We.children)}return Object.entries(K).forEach(([We,At])=>{"string"==typeof At&&(At=[At]),null!==At&&(_e[We]=Jo(R.children[We],G,At))}),Object.entries(R.children).forEach(([We,At])=>{void 0===K[We]&&(_e[We]=At)}),new Je(R.segments,_e)}}function ao(R,G,F){const K=R.segments.slice(0,G);let _e=0;for(;_e{"string"==typeof K&&(K=[K]),null!==K&&(G[F]=ao(new Je([],{}),0,K))}),G}function Ii(R){const G={};return Object.entries(R).forEach(([F,K])=>G[F]=`${K}`),G}function Io(R,G,F){return R==F.path&&st(G,F.parameters)}const tt="imperative";var xt=function(R){return R[R.NavigationStart=0]="NavigationStart",R[R.NavigationEnd=1]="NavigationEnd",R[R.NavigationCancel=2]="NavigationCancel",R[R.NavigationError=3]="NavigationError",R[R.RoutesRecognized=4]="RoutesRecognized",R[R.ResolveStart=5]="ResolveStart",R[R.ResolveEnd=6]="ResolveEnd",R[R.GuardsCheckStart=7]="GuardsCheckStart",R[R.GuardsCheckEnd=8]="GuardsCheckEnd",R[R.RouteConfigLoadStart=9]="RouteConfigLoadStart",R[R.RouteConfigLoadEnd=10]="RouteConfigLoadEnd",R[R.ChildActivationStart=11]="ChildActivationStart",R[R.ChildActivationEnd=12]="ChildActivationEnd",R[R.ActivationStart=13]="ActivationStart",R[R.ActivationEnd=14]="ActivationEnd",R[R.Scroll=15]="Scroll",R[R.NavigationSkipped=16]="NavigationSkipped",R}(xt||{});class ht{id;url;constructor(G,F){this.id=G,this.url=F}}class ve extends ht{type=xt.NavigationStart;navigationTrigger;restoredState;constructor(G,F,K="imperative",_e=null){super(G,F),this.navigationTrigger=K,this.restoredState=_e}toString(){return`NavigationStart(id: ${this.id}, url: '${this.url}')`}}class Ye extends ht{urlAfterRedirects;type=xt.NavigationEnd;constructor(G,F,K){super(G,F),this.urlAfterRedirects=K}toString(){return`NavigationEnd(id: ${this.id}, url: '${this.url}', urlAfterRedirects: '${this.urlAfterRedirects}')`}}var Ne=function(R){return R[R.Redirect=0]="Redirect",R[R.SupersededByNewNavigation=1]="SupersededByNewNavigation",R[R.NoDataFromResolver=2]="NoDataFromResolver",R[R.GuardRejected=3]="GuardRejected",R}(Ne||{}),gt=function(R){return R[R.IgnoredSameUrlNavigation=0]="IgnoredSameUrlNavigation",R[R.IgnoredByUrlHandlingStrategy=1]="IgnoredByUrlHandlingStrategy",R}(gt||{});class Ht extends ht{reason;code;type=xt.NavigationCancel;constructor(G,F,K,_e){super(G,F),this.reason=K,this.code=_e}toString(){return`NavigationCancel(id: ${this.id}, url: '${this.url}')`}}class kt extends ht{reason;code;type=xt.NavigationSkipped;constructor(G,F,K,_e){super(G,F),this.reason=K,this.code=_e}}class hn extends ht{error;target;type=xt.NavigationError;constructor(G,F,K,_e){super(G,F),this.error=K,this.target=_e}toString(){return`NavigationError(id: ${this.id}, url: '${this.url}', error: ${this.error})`}}class Dn extends ht{urlAfterRedirects;state;type=xt.RoutesRecognized;constructor(G,F,K,_e){super(G,F),this.urlAfterRedirects=K,this.state=_e}toString(){return`RoutesRecognized(id: ${this.id}, url: '${this.url}', urlAfterRedirects: '${this.urlAfterRedirects}', state: ${this.state})`}}class Cn extends ht{urlAfterRedirects;state;type=xt.GuardsCheckStart;constructor(G,F,K,_e){super(G,F),this.urlAfterRedirects=K,this.state=_e}toString(){return`GuardsCheckStart(id: ${this.id}, url: '${this.url}', urlAfterRedirects: '${this.urlAfterRedirects}', state: ${this.state})`}}class Nn extends ht{urlAfterRedirects;state;shouldActivate;type=xt.GuardsCheckEnd;constructor(G,F,K,_e,We){super(G,F),this.urlAfterRedirects=K,this.state=_e,this.shouldActivate=We}toString(){return`GuardsCheckEnd(id: ${this.id}, url: '${this.url}', urlAfterRedirects: '${this.urlAfterRedirects}', state: ${this.state}, shouldActivate: ${this.shouldActivate})`}}class jn extends ht{urlAfterRedirects;state;type=xt.ResolveStart;constructor(G,F,K,_e){super(G,F),this.urlAfterRedirects=K,this.state=_e}toString(){return`ResolveStart(id: ${this.id}, url: '${this.url}', urlAfterRedirects: '${this.urlAfterRedirects}', state: ${this.state})`}}class Jn extends ht{urlAfterRedirects;state;type=xt.ResolveEnd;constructor(G,F,K,_e){super(G,F),this.urlAfterRedirects=K,this.state=_e}toString(){return`ResolveEnd(id: ${this.id}, url: '${this.url}', urlAfterRedirects: '${this.urlAfterRedirects}', state: ${this.state})`}}class ar{route;type=xt.RouteConfigLoadStart;constructor(G){this.route=G}toString(){return`RouteConfigLoadStart(path: ${this.route.path})`}}class wr{route;type=xt.RouteConfigLoadEnd;constructor(G){this.route=G}toString(){return`RouteConfigLoadEnd(path: ${this.route.path})`}}class xr{snapshot;type=xt.ChildActivationStart;constructor(G){this.snapshot=G}toString(){return`ChildActivationStart(path: '${this.snapshot.routeConfig&&this.snapshot.routeConfig.path||""}')`}}class gi{snapshot;type=xt.ChildActivationEnd;constructor(G){this.snapshot=G}toString(){return`ChildActivationEnd(path: '${this.snapshot.routeConfig&&this.snapshot.routeConfig.path||""}')`}}class ni{snapshot;type=xt.ActivationStart;constructor(G){this.snapshot=G}toString(){return`ActivationStart(path: '${this.snapshot.routeConfig&&this.snapshot.routeConfig.path||""}')`}}class Mi{snapshot;type=xt.ActivationEnd;constructor(G){this.snapshot=G}toString(){return`ActivationEnd(path: '${this.snapshot.routeConfig&&this.snapshot.routeConfig.path||""}')`}}class Or{routerEvent;position;anchor;type=xt.Scroll;constructor(G,F,K){this.routerEvent=G,this.position=F,this.anchor=K}toString(){return`Scroll(anchor: '${this.anchor}', position: '${this.position?`${this.position[0]}, ${this.position[1]}`:null}')`}}class Qr{}class Pr{url;navigationBehaviorOptions;constructor(G,F){this.url=G,this.navigationBehaviorOptions=F}}function No(R){return R.outlet||Ze}function Ko(R){if(!R)return null;if(R.routeConfig?._injector)return R.routeConfig._injector;for(let G=R.parent;G;G=G.parent){const F=G.routeConfig;if(F?._loadedInjector)return F._loadedInjector;if(F?._injector)return F._injector}return null}class mo{rootInjector;outlet=null;route=null;children;attachRef=null;get injector(){return Ko(this.route?.snapshot)??this.rootInjector}constructor(G){this.rootInjector=G,this.children=new Go(this.rootInjector)}}let Go=(()=>{class R{rootInjector;contexts=new Map;constructor(F){this.rootInjector=F}onChildOutletCreated(F,K){const _e=this.getOrCreateContext(F);_e.outlet=K,this.contexts.set(F,_e)}onChildOutletDestroyed(F){const K=this.getContext(F);K&&(K.outlet=null,K.attachRef=null)}onOutletDeactivated(){const F=this.contexts;return this.contexts=new Map,F}onOutletReAttached(F){this.contexts=F}getOrCreateContext(F){let K=this.getContext(F);return K||(K=new mo(this.rootInjector),this.contexts.set(F,K)),K}getContext(F){return this.contexts.get(F)||null}static \u0275fac=function(K){return new(K||R)(i.KVO(i.uvJ))};static \u0275prov=i.jDH({token:R,factory:R.\u0275fac,providedIn:"root"})}return R})();class Rs{_root;constructor(G){this._root=G}get root(){return this._root.value}parent(G){const F=this.pathFromRoot(G);return F.length>1?F[F.length-2]:null}children(G){const F=Xr(G,this._root);return F?F.children.map(K=>K.value):[]}firstChild(G){const F=Xr(G,this._root);return F&&F.children.length>0?F.children[0].value:null}siblings(G){const F=Ds(G,this._root);return F.length<2?[]:F[F.length-2].children.map(_e=>_e.value).filter(_e=>_e!==G)}pathFromRoot(G){return Ds(G,this._root).map(F=>F.value)}}function Xr(R,G){if(R===G.value)return G;for(const F of G.children){const K=Xr(R,F);if(K)return K}return null}function Ds(R,G){if(R===G.value)return[G];for(const F of G.children){const K=Ds(R,F);if(K.length)return K.unshift(G),K}return[]}class go{value;children;constructor(G,F){this.value=G,this.children=F}toString(){return`TreeNode(${this.value})`}}function io(R){const G={};return R&&R.children.forEach(F=>G[F.value.outlet]=F),G}class fs extends Rs{snapshot;constructor(G,F){super(G),this.snapshot=F,Gs(this,G)}toString(){return this.snapshot.toString()}}function Xo(R){const G=function Qa(R){const We=new lr([],{},{},"",{},Ze,R,null,{});return new As("",new go(We,[]))}(R),F=new w.t([new z("",{})]),K=new w.t({}),_e=new w.t({}),We=new w.t({}),At=new w.t(""),fn=new _o(F,K,We,At,_e,Ze,R,G.root);return fn.snapshot=G.root,new fs(new go(fn,[]),G)}class _o{urlSubject;paramsSubject;queryParamsSubject;fragmentSubject;dataSubject;outlet;component;snapshot;_futureSnapshot;_routerState;_paramMap;_queryParamMap;title;url;params;queryParams;fragment;data;constructor(G,F,K,_e,We,At,fn,on){this.urlSubject=G,this.paramsSubject=F,this.queryParamsSubject=K,this.fragmentSubject=_e,this.dataSubject=We,this.outlet=At,this.component=fn,this._futureSnapshot=on,this.title=this.dataSubject?.pipe((0,ae.T)(ur=>ur[it]))??(0,y.of)(void 0),this.url=G,this.params=F,this.queryParams=K,this.fragment=_e,this.data=We}get routeConfig(){return this._futureSnapshot.routeConfig}get root(){return this._routerState.root}get parent(){return this._routerState.parent(this)}get firstChild(){return this._routerState.firstChild(this)}get children(){return this._routerState.children(this)}get pathFromRoot(){return this._routerState.pathFromRoot(this)}get paramMap(){return this._paramMap??=this.params.pipe((0,ae.T)(G=>$t(G))),this._paramMap}get queryParamMap(){return this._queryParamMap??=this.queryParams.pipe((0,ae.T)(G=>$t(G))),this._queryParamMap}toString(){return this.snapshot?this.snapshot.toString():`Future(${this._futureSnapshot})`}}function Ao(R,G,F="emptyOnly"){let K;const{routeConfig:_e}=R;return K=null===G||"always"!==F&&""!==_e?.path&&(G.component||G.routeConfig?.loadComponent)?{params:{...R.params},data:{...R.data},resolve:{...R.data,...R._resolvedData??{}}}:{params:{...G.params,...R.params},data:{...G.data,...R.data},resolve:{...R.data,...G.data,..._e?.data,...R._resolvedData}},_e&&Vi(_e)&&(K.resolve[it]=_e.title),K}class lr{url;params;queryParams;fragment;data;outlet;component;routeConfig;_resolve;_resolvedData;_routerState;_paramMap;_queryParamMap;get title(){return this.data?.[it]}constructor(G,F,K,_e,We,At,fn,on,ur){this.url=G,this.params=F,this.queryParams=K,this.fragment=_e,this.data=We,this.outlet=At,this.component=fn,this.routeConfig=on,this._resolve=ur}get root(){return this._routerState.root}get parent(){return this._routerState.parent(this)}get firstChild(){return this._routerState.firstChild(this)}get children(){return this._routerState.children(this)}get pathFromRoot(){return this._routerState.pathFromRoot(this)}get paramMap(){return this._paramMap??=$t(this.params),this._paramMap}get queryParamMap(){return this._queryParamMap??=$t(this.queryParams),this._queryParamMap}toString(){return`Route(url:'${this.url.map(K=>K.toString()).join("/")}', path:'${this.routeConfig?this.routeConfig.path:""}')`}}class As extends Rs{url;constructor(G,F){super(F),this.url=G,Gs(this,F)}toString(){return _s(this._root)}}function Gs(R,G){G.value._routerState=R,G.children.forEach(F=>Gs(R,F))}function _s(R){const G=R.children.length>0?` { ${R.children.map(_s).join(", ")} } `:"";return`${R.value}${G}`}function la(R){if(R.snapshot){const G=R.snapshot,F=R._futureSnapshot;R.snapshot=F,st(G.queryParams,F.queryParams)||R.queryParamsSubject.next(F.queryParams),G.fragment!==F.fragment&&R.fragmentSubject.next(F.fragment),st(G.params,F.params)||R.paramsSubject.next(F.params),function Ee(R,G){if(R.length!==G.length)return!1;for(let F=0;Fst(F.parameters,G[K].parameters))}(R.url,G.url);return F&&!(!R.parent!=!G.parent)&&(!R.parent||ls(R.parent,G.parent))}function Vi(R){return"string"==typeof R.title||null===R.title}const ll=new i.nKC("");let ca=(()=>{class R{activated=null;get activatedComponentRef(){return this.activated}_activatedRoute=null;name=Ze;activateEvents=new i.bkB;deactivateEvents=new i.bkB;attachEvents=new i.bkB;detachEvents=new i.bkB;routerOutletData=(0,i.hFB)(void 0);parentContexts=(0,i.WQX)(Go);location=(0,i.WQX)(i.c1b);changeDetector=(0,i.WQX)(i.gRc);inputBinder=(0,i.WQX)(Ts,{optional:!0});supportsBindingToComponentInputs=!0;ngOnChanges(F){if(F.name){const{firstChange:K,previousValue:_e}=F.name;if(K)return;this.isTrackedInParentContexts(_e)&&(this.deactivate(),this.parentContexts.onChildOutletDestroyed(_e)),this.initializeOutletWithName()}}ngOnDestroy(){this.isTrackedInParentContexts(this.name)&&this.parentContexts.onChildOutletDestroyed(this.name),this.inputBinder?.unsubscribeFromRouteData(this)}isTrackedInParentContexts(F){return this.parentContexts.getContext(F)?.outlet===this}ngOnInit(){this.initializeOutletWithName()}initializeOutletWithName(){if(this.parentContexts.onChildOutletCreated(this.name,this),this.activated)return;const F=this.parentContexts.getContext(this.name);F?.route&&(F.attachRef?this.attach(F.attachRef,F.route):this.activateWith(F.route,F.injector))}get isActivated(){return!!this.activated}get component(){if(!this.activated)throw new i.wOt(4012,!1);return this.activated.instance}get activatedRoute(){if(!this.activated)throw new i.wOt(4012,!1);return this._activatedRoute}get activatedRouteData(){return this._activatedRoute?this._activatedRoute.snapshot.data:{}}detach(){if(!this.activated)throw new i.wOt(4012,!1);this.location.detach();const F=this.activated;return this.activated=null,this._activatedRoute=null,this.detachEvents.emit(F.instance),F}attach(F,K){this.activated=F,this._activatedRoute=K,this.location.insert(F.hostView),this.inputBinder?.bindActivatedRouteToOutletComponent(this),this.attachEvents.emit(F.instance)}deactivate(){if(this.activated){const F=this.component;this.activated.destroy(),this.activated=null,this._activatedRoute=null,this.deactivateEvents.emit(F)}}activateWith(F,K){if(this.isActivated)throw new i.wOt(4013,!1);this._activatedRoute=F;const _e=this.location,At=F.snapshot.component,fn=this.parentContexts.getOrCreateContext(this.name).children,on=new Ss(F,fn,_e.injector,this.routerOutletData);this.activated=_e.createComponent(At,{index:_e.length,injector:on,environmentInjector:K}),this.changeDetector.markForCheck(),this.inputBinder?.bindActivatedRouteToOutletComponent(this),this.activateEvents.emit(this.activated.instance)}static \u0275fac=function(K){return new(K||R)};static \u0275dir=i.FsC({type:R,selectors:[["router-outlet"]],inputs:{name:"name",routerOutletData:[1,"routerOutletData"]},outputs:{activateEvents:"activate",deactivateEvents:"deactivate",attachEvents:"attach",detachEvents:"detach"},exportAs:["outlet"],features:[i.OA$]})}return R})();class Ss{route;childContexts;parent;outletData;__ngOutletInjector(G){return new Ss(this.route,this.childContexts,G,this.outletData)}constructor(G,F,K,_e){this.route=G,this.childContexts=F,this.parent=K,this.outletData=_e}get(G,F){return G===_o?this.route:G===Go?this.childContexts:G===ll?this.outletData:this.parent.get(G,F)}}const Ts=new i.nKC("");let Ns=(()=>{class R{outletDataSubscriptions=new Map;bindActivatedRouteToOutletComponent(F){this.unsubscribeFromRouteData(F),this.subscribeToRouteData(F)}unsubscribeFromRouteData(F){this.outletDataSubscriptions.get(F)?.unsubscribe(),this.outletDataSubscriptions.delete(F)}subscribeToRouteData(F){const{activatedRoute:K}=F,_e=(0,C.z)([K.queryParams,K.params,K.data]).pipe((0,me.n)(([We,At,fn],on)=>(fn={...We,...At,...fn},0===on?(0,y.of)(fn):Promise.resolve(fn)))).subscribe(We=>{if(!F.isActivated||!F.activatedComponentRef||F.activatedRoute!==K||null===K.component)return void this.unsubscribeFromRouteData(F);const At=(0,i.HJs)(K.component);if(At)for(const{templateName:fn}of At.inputs)F.activatedComponentRef.setInput(fn,We[fn]);else this.unsubscribeFromRouteData(F)});this.outletDataSubscriptions.set(F,_e)}static \u0275fac=function(K){return new(K||R)};static \u0275prov=i.jDH({token:R,factory:R.\u0275fac})}return R})();function Bo(R,G,F){if(F&&R.shouldReuseRoute(G.value,F.value.snapshot)){const K=F.value;K._futureSnapshot=G.value;const _e=function lo(R,G,F){return G.children.map(K=>{for(const _e of F.children)if(R.shouldReuseRoute(K.value,_e.value.snapshot))return Bo(R,K,_e);return Bo(R,K)})}(R,G,F);return new go(K,_e)}{if(R.shouldAttach(G.value)){const We=R.retrieve(G.value);if(null!==We){const At=We.route;return At.value._futureSnapshot=G.value,At.children=G.children.map(fn=>Bo(R,fn)),At}}const K=function ps(R){return new _o(new w.t(R.url),new w.t(R.params),new w.t(R.queryParams),new w.t(R.fragment),new w.t(R.data),R.outlet,R.component,R)}(G.value),_e=G.children.map(We=>Bo(R,We));return new go(K,_e)}}class Da{redirectTo;navigationBehaviorOptions;constructor(G,F){this.redirectTo=G,this.navigationBehaviorOptions=F}}const Ms="ngNavigationCancelingError";function Us(R,G){const{redirectTo:F,navigationBehaviorOptions:K}=Jt(G)?{redirectTo:G,navigationBehaviorOptions:void 0}:G,_e=ua(!1,Ne.Redirect);return _e.url=F,_e.navigationBehaviorOptions=K,_e}function ua(R,G){const F=new Error(`NavigationCancelingError: ${R||""}`);return F[Ms]=!0,F.cancellationCode=G,F}function Aa(R){return!!R&&R[Ms]}class te{routeReuseStrategy;futureState;currState;forwardEvent;inputBindingEnabled;constructor(G,F,K,_e,We){this.routeReuseStrategy=G,this.futureState=F,this.currState=K,this.forwardEvent=_e,this.inputBindingEnabled=We}activate(G){const F=this.futureState._root,K=this.currState?this.currState._root:null;this.deactivateChildRoutes(F,K,G),la(this.futureState.root),this.activateChildRoutes(F,K,G)}deactivateChildRoutes(G,F,K){const _e=io(F);G.children.forEach(We=>{const At=We.value.outlet;this.deactivateRoutes(We,_e[At],K),delete _e[At]}),Object.values(_e).forEach(We=>{this.deactivateRouteAndItsChildren(We,K)})}deactivateRoutes(G,F,K){const _e=G.value,We=F?F.value:null;if(_e===We)if(_e.component){const At=K.getContext(_e.outlet);At&&this.deactivateChildRoutes(G,F,At.children)}else this.deactivateChildRoutes(G,F,K);else We&&this.deactivateRouteAndItsChildren(F,K)}deactivateRouteAndItsChildren(G,F){G.value.component&&this.routeReuseStrategy.shouldDetach(G.value.snapshot)?this.detachAndStoreRouteSubtree(G,F):this.deactivateRouteAndOutlet(G,F)}detachAndStoreRouteSubtree(G,F){const K=F.getContext(G.value.outlet),_e=K&&G.value.component?K.children:F,We=io(G);for(const At of Object.values(We))this.deactivateRouteAndItsChildren(At,_e);if(K&&K.outlet){const At=K.outlet.detach(),fn=K.children.onOutletDeactivated();this.routeReuseStrategy.store(G.value.snapshot,{componentRef:At,route:G,contexts:fn})}}deactivateRouteAndOutlet(G,F){const K=F.getContext(G.value.outlet),_e=K&&G.value.component?K.children:F,We=io(G);for(const At of Object.values(We))this.deactivateRouteAndItsChildren(At,_e);K&&(K.outlet&&(K.outlet.deactivate(),K.children.onOutletDeactivated()),K.attachRef=null,K.route=null)}activateChildRoutes(G,F,K){const _e=io(F);G.children.forEach(We=>{this.activateRoutes(We,_e[We.value.outlet],K),this.forwardEvent(new Mi(We.value.snapshot))}),G.children.length&&this.forwardEvent(new gi(G.value.snapshot))}activateRoutes(G,F,K){const _e=G.value,We=F?F.value:null;if(la(_e),_e===We)if(_e.component){const At=K.getOrCreateContext(_e.outlet);this.activateChildRoutes(G,F,At.children)}else this.activateChildRoutes(G,F,K);else if(_e.component){const At=K.getOrCreateContext(_e.outlet);if(this.routeReuseStrategy.shouldAttach(_e.snapshot)){const fn=this.routeReuseStrategy.retrieve(_e.snapshot);this.routeReuseStrategy.store(_e.snapshot,null),At.children.onOutletReAttached(fn.contexts),At.attachRef=fn.componentRef,At.route=fn.route.value,At.outlet&&At.outlet.attach(fn.componentRef,fn.route.value),la(fn.route.value),this.activateChildRoutes(G,null,At.children)}else At.attachRef=null,At.route=_e,At.outlet&&At.outlet.activateWith(_e,At.injector),this.activateChildRoutes(G,null,At.children)}else this.activateChildRoutes(G,null,K)}}class ot{path;route;constructor(G){this.path=G,this.route=this.path[this.path.length-1]}}class Ct{component;route;constructor(G,F){this.component=G,this.route=F}}function Bn(R,G,F){const K=R._root;return Qn(K,G?G._root:null,F,[K.value])}function Wn(R,G){const F=Symbol(),K=G.get(R,F);return K===F?"function"!=typeof R||(0,i.LfX)(R)?G.get(R):R:K}function Qn(R,G,F,K,_e={canDeactivateChecks:[],canActivateChecks:[]}){const We=io(G);return R.children.forEach(At=>{(function qr(R,G,F,K,_e={canDeactivateChecks:[],canActivateChecks:[]}){const We=R.value,At=G?G.value:null,fn=F?F.getContext(R.value.outlet):null;if(At&&We.routeConfig===At.routeConfig){const on=function zi(R,G,F){if("function"==typeof F)return F(R,G);switch(F){case"pathParamsChange":return!W(R.url,G.url);case"pathParamsOrQueryParamsChange":return!W(R.url,G.url)||!st(R.queryParams,G.queryParams);case"always":return!0;case"paramsOrQueryParamsChange":return!ls(R,G)||!st(R.queryParams,G.queryParams);default:return!ls(R,G)}}(At,We,We.routeConfig.runGuardsAndResolvers);on?_e.canActivateChecks.push(new ot(K)):(We.data=At.data,We._resolvedData=At._resolvedData),Qn(R,G,We.component?fn?fn.children:null:F,K,_e),on&&fn&&fn.outlet&&fn.outlet.isActivated&&_e.canDeactivateChecks.push(new Ct(fn.outlet.component,At))}else At&&Mr(G,fn,_e),_e.canActivateChecks.push(new ot(K)),Qn(R,null,We.component?fn?fn.children:null:F,K,_e)})(At,We[At.value.outlet],F,K.concat([At.value]),_e),delete We[At.value.outlet]}),Object.entries(We).forEach(([At,fn])=>Mr(fn,F.getContext(At),_e)),_e}function Mr(R,G,F){const K=io(R),_e=R.value;Object.entries(K).forEach(([We,At])=>{Mr(At,_e.component?G?G.children.getContext(We):null:G,F)}),F.canDeactivateChecks.push(new Ct(_e.component&&G&&G.outlet&&G.outlet.isActivated?G.outlet.component:null,_e))}function fi(R){return"function"==typeof R}function Ua(R){return R instanceof T.G||"EmptyError"===R?.name}const $a=Symbol("INITIAL_VALUE");function da(){return(0,me.n)(R=>(0,C.z)(R.map(G=>G.pipe((0,be.s)(1),(0,Oe.Z)($a)))).pipe((0,ae.T)(G=>{for(const F of G)if(!0!==F){if(F===$a)return $a;if(!1===F||de(F))return F}return!0}),(0,xe.p)(G=>G!==$a),(0,be.s)(1)))}function de(R){return Jt(R)||R instanceof Da}function ja(R){return(0,O.F)((0,Ce.M)(G=>{if("boolean"!=typeof G)throw Us(0,G)}),(0,ae.T)(G=>!0===G))}class cl{segmentGroup;constructor(G){this.segmentGroup=G||null}}class _i extends Error{urlTree;constructor(G){super(),this.urlTree=G}}function cs(R){return(0,L.$)(new cl(R))}class Pu{urlSerializer;urlTree;constructor(G,F){this.urlSerializer=G,this.urlTree=F}lineralizeSegments(G,F){let K=[],_e=F.root;for(;;){if(K=K.concat(_e.segments),0===_e.numberOfChildren)return(0,y.of)(K);if(_e.numberOfChildren>1||!_e.children[Ze])return(0,L.$)(new i.wOt(4e3,!1));_e=_e.children[Ze]}}applyRedirectCommands(G,F,K,_e,We){if("string"!=typeof F){const fn=F,{queryParams:on,fragment:ur,routeConfig:ui,url:kr,outlet:Gi,params:Is,data:is,title:Oa}=_e,us=(0,i.N4e)(We,()=>fn({params:Is,data:is,queryParams:on,fragment:ur,routeConfig:ui,url:kr,outlet:Gi,title:Oa}));if(us instanceof ke)throw new _i(us);F=us}const At=this.applyRedirectCreateUrlTree(F,this.urlSerializer.parse(F),G,K);if("/"===F[0])throw new _i(At);return At}applyRedirectCreateUrlTree(G,F,K,_e){const We=this.createSegmentGroup(G,F.root,K,_e);return new ke(We,this.createQueryParams(F.queryParams,this.urlTree.queryParams),F.fragment)}createQueryParams(G,F){const K={};return Object.entries(G).forEach(([_e,We])=>{if("string"==typeof We&&":"===We[0]){const fn=We.substring(1);K[_e]=F[fn]}else K[_e]=We}),K}createSegmentGroup(G,F,K,_e){const We=this.createSegments(G,F.segments,K,_e);let At={};return Object.entries(F.children).forEach(([fn,on])=>{At[fn]=this.createSegmentGroup(G,on,K,_e)}),new Je(We,At)}createSegments(G,F,K,_e){return F.map(We=>":"===We.path[0]?this.findPosParam(G,We,_e):this.findOrReturn(We,K))}findPosParam(G,F,K){const _e=K[F.path.substring(1)];if(!_e)throw new i.wOt(4001,!1);return _e}findOrReturn(G,F){let K=0;for(const _e of F){if(_e.path===G.path)return F.splice(K),_e;K++}return G}}const wl={matched:!1,consumedSegments:[],remainingSegments:[],parameters:{},positionalParamSegments:{}};function ul(R,G,F,K,_e){const We=yi(R,G,F);return We.matched?(K=function es(R,G){return R.providers&&!R._injector&&(R._injector=(0,i.Ol2)(R.providers,G,`Route: ${R.path}`)),R._injector??G}(G,K),function fc(R,G,F,K){const _e=G.canMatch;if(!_e||0===_e.length)return(0,y.of)(!0);const We=_e.map(At=>{const fn=Wn(At,R);return rt(function Ho(R){return R&&fi(R.canMatch)}(fn)?fn.canMatch(G,F):(0,i.N4e)(R,()=>fn(G,F)))});return(0,y.of)(We).pipe(da(),ja())}(K,G,F).pipe((0,ae.T)(At=>!0===At?We:{...wl}))):(0,y.of)(We)}function yi(R,G,F){if("**"===G.path)return function Il(R){return{matched:!0,parameters:R.length>0?Kt(R).parameters:{},consumedSegments:R,remainingSegments:[],positionalParamSegments:{}}}(F);if(""===G.path)return"full"===G.pathMatch&&(R.hasChildren()||F.length>0)?{...wl}:{matched:!0,consumedSegments:[],remainingSegments:F,parameters:{},positionalParamSegments:{}};const _e=(G.matcher||Te)(F,R,G);if(!_e)return{...wl};const We={};Object.entries(_e.posParams??{}).forEach(([fn,on])=>{We[fn]=on.path});const At=_e.consumed.length>0?{...We,..._e.consumed[_e.consumed.length-1].parameters}:We;return{matched:!0,consumedSegments:_e.consumed,remainingSegments:F.slice(_e.consumed.length),parameters:At,positionalParamSegments:_e.posParams??{}}}function eu(R,G,F,K){return F.length>0&&function $s(R,G,F){return F.some(K=>Sa(R,G,K)&&No(K)!==Ze)}(R,F,K)?{segmentGroup:new Je(G,dl(K,new Je(F,R.children))),slicedSegments:[]}:0===F.length&&function Ol(R,G,F){return F.some(K=>Sa(R,G,K))}(R,F,K)?{segmentGroup:new Je(R.segments,tu(R,F,K,R.children)),slicedSegments:F}:{segmentGroup:new Je(R.segments,R.children),slicedSegments:F}}function tu(R,G,F,K){const _e={};for(const We of F)if(Sa(R,G,We)&&!K[No(We)]){const At=new Je([],{});_e[No(We)]=At}return{...K,..._e}}function dl(R,G){const F={};F[Ze]=G;for(const K of R)if(""===K.path&&No(K)!==Ze){const _e=new Je([],{});F[No(K)]=_e}return F}function Sa(R,G,F){return(!(R.hasChildren()||G.length>0)||"full"!==F.pathMatch)&&""===F.path}class js{}class ru{injector;configLoader;rootComponentType;config;urlTree;paramsInheritanceStrategy;urlSerializer;applyRedirects;absoluteRedirectCount=0;allowRedirects=!0;constructor(G,F,K,_e,We,At,fn){this.injector=G,this.configLoader=F,this.rootComponentType=K,this.config=_e,this.urlTree=We,this.paramsInheritanceStrategy=At,this.urlSerializer=fn,this.applyRedirects=new Pu(this.urlSerializer,this.urlTree)}noMatchError(G){return new i.wOt(4002,`'${G.segmentGroup}'`)}recognize(){const G=eu(this.urlTree.root,[],[],this.config).segmentGroup;return this.match(G).pipe((0,ae.T)(({children:F,rootSnapshot:K})=>{const _e=new go(K,F),We=new As("",_e),At=function Tt(R,G,F=null,K=null){return Rt(nt(R),G,F,K)}(K,[],this.urlTree.queryParams,this.urlTree.fragment);return At.queryParams=this.urlTree.queryParams,We.url=this.urlSerializer.serialize(At),{state:We,tree:At}}))}match(G){const F=new lr([],Object.freeze({}),Object.freeze({...this.urlTree.queryParams}),this.urlTree.fragment,Object.freeze({}),Ze,this.rootComponentType,null,{});return this.processSegmentGroup(this.injector,this.config,G,Ze,F).pipe((0,ae.T)(K=>({children:K,rootSnapshot:F})),(0,Be.W)(K=>{if(K instanceof _i)return this.urlTree=K.urlTree,this.match(K.urlTree.root);throw K instanceof cl?this.noMatchError(K):K}))}processSegmentGroup(G,F,K,_e,We){return 0===K.segments.length&&K.hasChildren()?this.processChildren(G,F,K,We):this.processSegment(G,F,K,K.segments,_e,!0,We).pipe((0,ae.T)(At=>At instanceof go?[At]:[]))}processChildren(G,F,K,_e){const We=[];for(const At of Object.keys(K.children))"primary"===At?We.unshift(At):We.push(At);return(0,c.H)(We).pipe((0,ue.H)(At=>{const fn=K.children[At],on=function hs(R,G){const F=R.filter(K=>No(K)===G);return F.push(...R.filter(K=>No(K)!==G)),F}(F,At);return this.processSegmentGroup(G,on,fn,At,_e)}),function bt(R,G){return(0,at.N)((0,dt.S)(R,G,arguments.length>=2,!0))}((At,fn)=>(At.push(...fn),At)),(0,lt.U)(null),function yn(R,G){const F=arguments.length>=2;return K=>K.pipe(R?(0,xe.p)((_e,We)=>R(_e,We,K)):Vn.D,gn(1),F?(0,lt.U)(G):(0,bn.v)(()=>new T.G))}(),(0,De.Z)(At=>{if(null===At)return cs(K);const fn=jl(At);return function Mc(R){R.sort((G,F)=>G.value.outlet===Ze?-1:F.value.outlet===Ze?1:G.value.outlet.localeCompare(F.value.outlet))}(fn),(0,y.of)(fn)}))}processSegment(G,F,K,_e,We,At,fn){return(0,c.H)(F).pipe((0,ue.H)(on=>this.processSegmentAgainstRoute(on._injector??G,F,on,K,_e,We,At,fn).pipe((0,Be.W)(ur=>{if(ur instanceof cl)return(0,y.of)(null);throw ur}))),(0,ce.$)(on=>!!on),(0,Be.W)(on=>{if(Ua(on))return function ks(R,G,F){return 0===G.length&&!R.children[F]}(K,_e,We)?(0,y.of)(new js):cs(K);throw on}))}processSegmentAgainstRoute(G,F,K,_e,We,At,fn,on){return No(K)===At||At!==Ze&&Sa(_e,We,K)?void 0===K.redirectTo?this.matchSegmentAgainstRoute(G,_e,K,We,At,on):this.allowRedirects&&fn?this.expandSegmentAgainstRouteUsingRedirect(G,_e,F,K,We,At,on):cs(_e):cs(_e)}expandSegmentAgainstRouteUsingRedirect(G,F,K,_e,We,At,fn){const{matched:on,parameters:ur,consumedSegments:ui,positionalParamSegments:kr,remainingSegments:Gi}=yi(F,_e,We);if(!on)return cs(F);"string"==typeof _e.redirectTo&&"/"===_e.redirectTo[0]&&(this.absoluteRedirectCount++,this.absoluteRedirectCount>31&&(this.allowRedirects=!1));const Is=new lr(We,ur,Object.freeze({...this.urlTree.queryParams}),this.urlTree.fragment,Vl(_e),No(_e),_e.component??_e._loadedComponent??null,_e,Hl(_e)),is=Ao(Is,fn,this.paramsInheritanceStrategy);Is.params=Object.freeze(is.params),Is.data=Object.freeze(is.data);const Oa=this.applyRedirects.applyRedirectCommands(ui,_e.redirectTo,kr,Is,G);return this.applyRedirects.lineralizeSegments(_e,Oa).pipe((0,De.Z)(us=>this.processSegment(G,K,F,us.concat(Gi),At,!1,fn)))}matchSegmentAgainstRoute(G,F,K,_e,We,At){const fn=ul(F,K,_e,G);return"**"===K.path&&(F.children={}),fn.pipe((0,me.n)(on=>on.matched?this.getChildConfig(G=K._injector??G,K,_e).pipe((0,me.n)(({routes:ur})=>{const ui=K._loadedInjector??G,{parameters:kr,consumedSegments:Gi,remainingSegments:Is}=on,is=new lr(Gi,kr,Object.freeze({...this.urlTree.queryParams}),this.urlTree.fragment,Vl(K),No(K),K.component??K._loadedComponent??null,K,Hl(K)),Oa=Ao(is,At,this.paramsInheritanceStrategy);is.params=Object.freeze(Oa.params),is.data=Object.freeze(Oa.data);const{segmentGroup:us,slicedSegments:Wr}=eu(F,Gi,Is,ur);if(0===Wr.length&&us.hasChildren())return this.processChildren(ui,ur,us,is).pipe((0,ae.T)(Ka=>new go(is,Ka)));if(0===ur.length&&0===Wr.length)return(0,y.of)(new go(is,[]));const Ys=No(K)===We;return this.processSegment(ui,ur,us,Wr,Ys?Ze:We,!0,is).pipe((0,ae.T)(Ka=>new go(is,Ka instanceof go?[Ka]:[])))})):cs(F)))}getChildConfig(G,F,K){return F.children?(0,y.of)({routes:F.children,injector:G}):F.loadChildren?void 0!==F._loadedRoutes?(0,y.of)({routes:F._loadedRoutes,injector:F._loadedInjector}):function yl(R,G,F,K){const _e=G.canLoad;if(void 0===_e||0===_e.length)return(0,y.of)(!0);const We=_e.map(At=>{const fn=Wn(At,R);return rt(function di(R){return R&&fi(R.canLoad)}(fn)?fn.canLoad(G,F):(0,i.N4e)(R,()=>fn(G,F)))});return(0,y.of)(We).pipe(da(),ja())}(G,F,K).pipe((0,De.Z)(_e=>_e?this.configLoader.loadChildren(G,F).pipe((0,Ce.M)(We=>{F._loadedRoutes=We.routes,F._loadedInjector=We.injector})):function bl(){return(0,L.$)(ua(!1,Ne.GuardRejected))}())):(0,y.of)({routes:[],injector:G})}}function El(R){const G=R.value.routeConfig;return G&&""===G.path}function jl(R){const G=[],F=new Set;for(const K of R){if(!El(K)){G.push(K);continue}const _e=G.find(We=>K.value.routeConfig===We.value.routeConfig);void 0!==_e?(_e.children.push(...K.children),F.add(_e)):G.push(K)}for(const K of F){const _e=jl(K.children);G.push(new go(K.value,_e))}return G.filter(K=>!F.has(K))}function Vl(R){return R.data||{}}function Hl(R){return R.resolve||{}}function Vo(R){const G=R.children.map(F=>Vo(F)).flat();return[R,...G]}function Sr(R){return(0,me.n)(G=>{const F=R(G);return F?(0,c.H)(F).pipe((0,ae.T)(()=>G)):(0,y.of)(G)})}let Oi=(()=>{class R{buildTitle(F){let K,_e=F.root;for(;void 0!==_e;)K=this.getResolvedTitleForRoute(_e)??K,_e=_e.children.find(We=>We.outlet===Ze);return K}getResolvedTitleForRoute(F){return F.data[it]}static \u0275fac=function(K){return new(K||R)};static \u0275prov=i.jDH({token:R,factory:()=>(0,i.WQX)(ys),providedIn:"root"})}return R})(),ys=(()=>{class R extends Oi{title;constructor(F){super(),this.title=F}updateTitle(F){const K=this.buildTitle(F);void 0!==K&&this.title.setTitle(K)}static \u0275fac=function(K){return new(K||R)(i.KVO(Ke.hE))};static \u0275prov=i.jDH({token:R,factory:R.\u0275fac,providedIn:"root"})}return R})();const Qi=new i.nKC("",{providedIn:"root",factory:()=>({})});let so=(()=>{class R{static \u0275fac=function(K){return new(K||R)};static \u0275cmp=i.VBU({type:R,selectors:[["ng-component"]],decls:1,vars:0,template:function(K,_e){1&K&&i.nrm(0,"router-outlet")},dependencies:[ca],encapsulation:2})}return R})();function Bi(R){const G=R.children&&R.children.map(Bi),F=G?{...R,children:G}:{...R};return!F.component&&!F.loadComponent&&(G||F.loadChildren)&&F.outlet&&F.outlet!==Ze&&(F.component=so),F}const Ki=new i.nKC("");let no=(()=>{class R{componentLoaders=new WeakMap;childrenLoaders=new WeakMap;onLoadStartListener;onLoadEndListener;compiler=(0,i.WQX)(i.Ql9);loadComponent(F){if(this.componentLoaders.get(F))return this.componentLoaders.get(F);if(F._loadedComponent)return(0,y.of)(F._loadedComponent);this.onLoadStartListener&&this.onLoadStartListener(F);const K=rt(F.loadComponent()).pipe((0,ae.T)(Xs),(0,Ce.M)(We=>{this.onLoadEndListener&&this.onLoadEndListener(F),F._loadedComponent=We}),(0,_t.j)(()=>{this.componentLoaders.delete(F)})),_e=new q.G(K,()=>new re.B).pipe((0,ze.B)());return this.componentLoaders.set(F,_e),_e}loadChildren(F,K){if(this.childrenLoaders.get(K))return this.childrenLoaders.get(K);if(K._loadedRoutes)return(0,y.of)({routes:K._loadedRoutes,injector:K._loadedInjector});this.onLoadStartListener&&this.onLoadStartListener(K);const We=function co(R,G,F,K){return rt(R.loadChildren()).pipe((0,ae.T)(Xs),(0,De.Z)(_e=>_e instanceof i.Co$||Array.isArray(_e)?(0,y.of)(_e):(0,c.H)(G.compileModuleAsync(_e))),(0,ae.T)(_e=>{K&&K(R);let We,At,fn=!1;return Array.isArray(_e)?(At=_e,!0):(We=_e.create(F).injector,At=We.get(Ki,[],{optional:!0,self:!0}).flat()),{routes:At.map(Bi),injector:We}}))}(K,this.compiler,F,this.onLoadEndListener).pipe((0,_t.j)(()=>{this.childrenLoaders.delete(K)})),At=new q.G(We,()=>new re.B).pipe((0,ze.B)());return this.childrenLoaders.set(K,At),At}static \u0275fac=function(K){return new(K||R)};static \u0275prov=i.jDH({token:R,factory:R.\u0275fac,providedIn:"root"})}return R})();function Xs(R){return function ri(R){return R&&"object"==typeof R&&"default"in R}(R)?R.default:R}let Za=(()=>{class R{static \u0275fac=function(K){return new(K||R)};static \u0275prov=i.jDH({token:R,factory:()=>(0,i.WQX)(Uo),providedIn:"root"})}return R})(),Uo=(()=>{class R{shouldProcessUrl(F){return!0}extract(F){return F}merge(F,K){return F}static \u0275fac=function(K){return new(K||R)};static \u0275prov=i.jDH({token:R,factory:R.\u0275fac,providedIn:"root"})}return R})();const vo=new i.nKC(""),Ci=new i.nKC("");function Vs(R,G,F){const K=R.get(Ci),_e=R.get(se.qQ);return R.get(i.SKi).runOutsideAngular(()=>{if(!_e.startViewTransition||K.skipNextTransition)return K.skipNextTransition=!1,new Promise(ur=>setTimeout(ur));let We;const At=new Promise(ur=>{We=ur}),fn=_e.startViewTransition(()=>(We(),function uo(R){return new Promise(G=>{(0,i.mal)({read:()=>setTimeout(G)},{injector:R})})}(R))),{onViewTransitionCreated:on}=K;return on&&(0,i.N4e)(R,()=>on({transition:fn,from:G,to:F})),At})}const Ui=new i.nKC("");let U=(()=>{class R{currentNavigation=null;currentTransition=null;lastSuccessfulNavigation=null;events=new re.B;transitionAbortSubject=new re.B;configLoader=(0,i.WQX)(no);environmentInjector=(0,i.WQX)(i.uvJ);urlSerializer=(0,i.WQX)(ft);rootContexts=(0,i.WQX)(Go);location=(0,i.WQX)(se.aZ);inputBindingEnabled=null!==(0,i.WQX)(Ts,{optional:!0});titleStrategy=(0,i.WQX)(Oi);options=(0,i.WQX)(Qi,{optional:!0})||{};paramsInheritanceStrategy=this.options.paramsInheritanceStrategy||"emptyOnly";urlHandlingStrategy=(0,i.WQX)(Za);createViewTransition=(0,i.WQX)(vo,{optional:!0});navigationErrorHandler=(0,i.WQX)(Ui,{optional:!0});navigationId=0;get hasRequestedNavigation(){return 0!==this.navigationId}transitions;afterPreactivation=()=>(0,y.of)(void 0);rootComponentType=null;constructor(){this.configLoader.onLoadEndListener=_e=>this.events.next(new wr(_e)),this.configLoader.onLoadStartListener=_e=>this.events.next(new ar(_e))}complete(){this.transitions?.complete()}handleNavigationRequest(F){const K=++this.navigationId;this.transitions?.next({...this.transitions.value,...F,id:K})}setupNavigations(F,K,_e){return this.transitions=new w.t({id:0,currentUrlTree:K,currentRawUrl:K,extractedUrl:this.urlHandlingStrategy.extract(K),urlAfterRedirects:this.urlHandlingStrategy.extract(K),rawUrl:K,extras:{},resolve:()=>{},reject:()=>{},promise:Promise.resolve(!0),source:tt,restoredState:null,currentSnapshot:_e.snapshot,targetSnapshot:null,currentRouterState:_e,targetRouterState:null,guards:{canActivateChecks:[],canDeactivateChecks:[]},guardsResult:null}),this.transitions.pipe((0,xe.p)(We=>0!==We.id),(0,ae.T)(We=>({...We,extractedUrl:this.urlHandlingStrategy.extract(We.rawUrl)})),(0,me.n)(We=>{let At=!1,fn=!1;return(0,y.of)(We).pipe((0,me.n)(on=>{if(this.navigationId>We.id)return this.cancelNavigationTransition(We,"",Ne.SupersededByNewNavigation),Z.w;this.currentTransition=We,this.currentNavigation={id:on.id,initialUrl:on.rawUrl,extractedUrl:on.extractedUrl,targetBrowserUrl:"string"==typeof on.extras.browserUrl?this.urlSerializer.parse(on.extras.browserUrl):on.extras.browserUrl,trigger:on.source,extras:on.extras,previousNavigation:this.lastSuccessfulNavigation?{...this.lastSuccessfulNavigation,previousNavigation:null}:null};const ur=!F.navigated||this.isUpdatingInternalState()||this.isUpdatedBrowserUrl();if(!ur&&"reload"!==(on.extras.onSameUrlNavigation??F.onSameUrlNavigation)){const kr="";return this.events.next(new kt(on.id,this.urlSerializer.serialize(on.rawUrl),kr,gt.IgnoredSameUrlNavigation)),on.resolve(!1),Z.w}if(this.urlHandlingStrategy.shouldProcessUrl(on.rawUrl))return(0,y.of)(on).pipe((0,me.n)(kr=>{const Gi=this.transitions?.getValue();return this.events.next(new ve(kr.id,this.urlSerializer.serialize(kr.extractedUrl),kr.source,kr.restoredState)),Gi!==this.transitions?.getValue()?Z.w:Promise.resolve(kr)}),function ha(R,G,F,K,_e,We){return(0,De.Z)(At=>function nu(R,G,F,K,_e,We,At="emptyOnly"){return new ru(R,G,F,K,_e,At,We).recognize()}(R,G,F,K,At.extractedUrl,_e,We).pipe((0,ae.T)(({state:fn,tree:on})=>({...At,targetSnapshot:fn,urlAfterRedirects:on}))))}(this.environmentInjector,this.configLoader,this.rootComponentType,F.config,this.urlSerializer,this.paramsInheritanceStrategy),(0,Ce.M)(kr=>{We.targetSnapshot=kr.targetSnapshot,We.urlAfterRedirects=kr.urlAfterRedirects,this.currentNavigation={...this.currentNavigation,finalUrl:kr.urlAfterRedirects};const Gi=new Dn(kr.id,this.urlSerializer.serialize(kr.extractedUrl),this.urlSerializer.serialize(kr.urlAfterRedirects),kr.targetSnapshot);this.events.next(Gi)}));if(ur&&this.urlHandlingStrategy.shouldProcessUrl(on.currentRawUrl)){const{id:kr,extractedUrl:Gi,source:Is,restoredState:is,extras:Oa}=on,us=new ve(kr,this.urlSerializer.serialize(Gi),Is,is);this.events.next(us);const Wr=Xo(this.rootComponentType).snapshot;return this.currentTransition=We={...on,targetSnapshot:Wr,urlAfterRedirects:Gi,extras:{...Oa,skipLocationChange:!1,replaceUrl:!1}},this.currentNavigation.finalUrl=Gi,(0,y.of)(We)}{const kr="";return this.events.next(new kt(on.id,this.urlSerializer.serialize(on.extractedUrl),kr,gt.IgnoredByUrlHandlingStrategy)),on.resolve(!1),Z.w}}),(0,Ce.M)(on=>{const ur=new Cn(on.id,this.urlSerializer.serialize(on.extractedUrl),this.urlSerializer.serialize(on.urlAfterRedirects),on.targetSnapshot);this.events.next(ur)}),(0,ae.T)(on=>(this.currentTransition=We={...on,guards:Bn(on.targetSnapshot,on.currentSnapshot,this.rootContexts)},We)),function he(R,G){return(0,De.Z)(F=>{const{targetSnapshot:K,currentSnapshot:_e,guards:{canActivateChecks:We,canDeactivateChecks:At}}=F;return 0===At.length&&0===We.length?(0,y.of)({...F,guardsResult:!0}):function Y(R,G,F,K){return(0,c.H)(R).pipe((0,De.Z)(_e=>function kl(R,G,F,K,_e){const We=G&&G.routeConfig?G.routeConfig.canDeactivate:null;if(!We||0===We.length)return(0,y.of)(!0);const At=We.map(fn=>{const on=Ko(G)??_e,ur=Wn(fn,on);return rt(function jo(R){return R&&fi(R.canDeactivate)}(ur)?ur.canDeactivate(R,G,F,K):(0,i.N4e)(on,()=>ur(R,G,F,K))).pipe((0,ce.$)())});return(0,y.of)(At).pipe(da())}(_e.component,_e.route,F,G,K)),(0,ce.$)(_e=>!0!==_e,!0))}(At,K,_e,R).pipe((0,De.Z)(fn=>fn&&function zr(R){return"boolean"==typeof R}(fn)?function Ue(R,G,F,K){return(0,c.H)(G).pipe((0,ue.H)(_e=>(0,S.x)(function br(R,G){return null!==R&&G&&G(new xr(R)),(0,y.of)(!0)}(_e.route.parent,K),function jt(R,G){return null!==R&&G&&G(new ni(R)),(0,y.of)(!0)}(_e.route,K),function ts(R,G,F){const K=G[G.length-1],We=G.slice(0,G.length-1).reverse().map(At=>function On(R){const G=R.routeConfig?R.routeConfig.canActivateChild:null;return G&&0!==G.length?{node:R,guards:G}:null}(At)).filter(At=>null!==At).map(At=>(0,M.v)(()=>{const fn=At.guards.map(on=>{const ur=Ko(At.node)??F,ui=Wn(on,ur);return rt(function Ro(R){return R&&fi(R.canActivateChild)}(ui)?ui.canActivateChild(K,R):(0,i.N4e)(ur,()=>ui(K,R))).pipe((0,ce.$)())});return(0,y.of)(fn).pipe(da())}));return(0,y.of)(We).pipe(da())}(R,_e.path,F),function Jr(R,G,F){const K=G.routeConfig?G.routeConfig.canActivate:null;if(!K||0===K.length)return(0,y.of)(!0);const _e=K.map(We=>(0,M.v)(()=>{const At=Ko(G)??F,fn=Wn(We,At);return rt(function Fi(R){return R&&fi(R.canActivate)}(fn)?fn.canActivate(G,R):(0,i.N4e)(At,()=>fn(G,R))).pipe((0,ce.$)())}));return(0,y.of)(_e).pipe(da())}(R,_e.route,F))),(0,ce.$)(_e=>!0!==_e,!0))}(K,We,R,G):(0,y.of)(fn)),(0,ae.T)(fn=>({...F,guardsResult:fn})))})}(this.environmentInjector,on=>this.events.next(on)),(0,Ce.M)(on=>{if(We.guardsResult=on.guardsResult,on.guardsResult&&"boolean"!=typeof on.guardsResult)throw Us(0,on.guardsResult);const ur=new Nn(on.id,this.urlSerializer.serialize(on.extractedUrl),this.urlSerializer.serialize(on.urlAfterRedirects),on.targetSnapshot,!!on.guardsResult);this.events.next(ur)}),(0,xe.p)(on=>!!on.guardsResult||(this.cancelNavigationTransition(on,"",Ne.GuardRejected),!1)),Sr(on=>{if(on.guards.canActivateChecks.length)return(0,y.of)(on).pipe((0,Ce.M)(ur=>{const ui=new jn(ur.id,this.urlSerializer.serialize(ur.extractedUrl),this.urlSerializer.serialize(ur.urlAfterRedirects),ur.targetSnapshot);this.events.next(ui)}),(0,me.n)(ur=>{let ui=!1;return(0,y.of)(ur).pipe(function iu(R,G){return(0,De.Z)(F=>{const{targetSnapshot:K,guards:{canActivateChecks:_e}}=F;if(!_e.length)return(0,y.of)(F);const We=new Set(_e.map(on=>on.route)),At=new Set;for(const on of We)if(!At.has(on))for(const ur of Vo(on))At.add(ur);let fn=0;return(0,c.H)(At).pipe((0,ue.H)(on=>We.has(on)?function Wo(R,G,F,K){const _e=R.routeConfig,We=R._resolve;return void 0!==_e?.title&&!Vi(_e)&&(We[it]=_e.title),function oo(R,G,F,K){const _e=Xt(R);if(0===_e.length)return(0,y.of)({});const We={};return(0,c.H)(_e).pipe((0,De.Z)(At=>function Fn(R,G,F,K){const _e=Ko(G)??K,We=Wn(R,_e);return rt(We.resolve?We.resolve(G,F):(0,i.N4e)(_e,()=>We(G,F)))}(R[At],G,F,K).pipe((0,ce.$)(),(0,Ce.M)(fn=>{if(fn instanceof Da)throw Us(new mt,fn);We[At]=fn}))),gn(1),(0,qe.u)(We),(0,Be.W)(At=>Ua(At)?Z.w:(0,L.$)(At)))}(We,R,G,K).pipe((0,ae.T)(At=>(R._resolvedData=At,R.data=Ao(R,R.parent,F).resolve,null)))}(on,K,R,G):(on.data=Ao(on,on.parent,R).resolve,(0,y.of)(void 0))),(0,Ce.M)(()=>fn++),gn(1),(0,De.Z)(on=>fn===At.size?(0,y.of)(F):Z.w))})}(this.paramsInheritanceStrategy,this.environmentInjector),(0,Ce.M)({next:()=>ui=!0,complete:()=>{ui||this.cancelNavigationTransition(ur,"",Ne.NoDataFromResolver)}}))}),(0,Ce.M)(ur=>{const ui=new Jn(ur.id,this.urlSerializer.serialize(ur.extractedUrl),this.urlSerializer.serialize(ur.urlAfterRedirects),ur.targetSnapshot);this.events.next(ui)}))}),Sr(on=>{const ur=ui=>{const kr=[];ui.routeConfig?.loadComponent&&!ui.routeConfig._loadedComponent&&kr.push(this.configLoader.loadComponent(ui.routeConfig).pipe((0,Ce.M)(Gi=>{ui.component=Gi}),(0,ae.T)(()=>{})));for(const Gi of ui.children)kr.push(...ur(Gi));return kr};return(0,C.z)(ur(on.targetSnapshot.root)).pipe((0,lt.U)(null),(0,be.s)(1))}),Sr(()=>this.afterPreactivation()),(0,me.n)(()=>{const{currentSnapshot:on,targetSnapshot:ur}=We,ui=this.createViewTransition?.(this.environmentInjector,on.root,ur.root);return ui?(0,c.H)(ui).pipe((0,ae.T)(()=>We)):(0,y.of)(We)}),(0,ae.T)(on=>{const ur=function So(R,G,F){const K=Bo(R,G._root,F?F._root:void 0);return new fs(K,G)}(F.routeReuseStrategy,on.targetSnapshot,on.currentRouterState);return this.currentTransition=We={...on,targetRouterState:ur},this.currentNavigation.targetRouterState=ur,We}),(0,Ce.M)(()=>{this.events.next(new Qr)}),((R,G,F,K)=>(0,ae.T)(_e=>(new te(G,_e.targetRouterState,_e.currentRouterState,F,K).activate(R),_e)))(this.rootContexts,F.routeReuseStrategy,on=>this.events.next(on),this.inputBindingEnabled),(0,be.s)(1),(0,Ce.M)({next:on=>{At=!0,this.lastSuccessfulNavigation=this.currentNavigation,this.events.next(new Ye(on.id,this.urlSerializer.serialize(on.extractedUrl),this.urlSerializer.serialize(on.urlAfterRedirects))),this.titleStrategy?.updateTitle(on.targetRouterState.snapshot),on.resolve(!0)},complete:()=>{At=!0}}),(0,$e.Q)(this.transitionAbortSubject.pipe((0,Ce.M)(on=>{throw on}))),(0,_t.j)(()=>{!At&&!fn&&this.cancelNavigationTransition(We,"",Ne.SupersededByNewNavigation),this.currentTransition?.id===We.id&&(this.currentNavigation=null,this.currentTransition=null)}),(0,Be.W)(on=>{if(fn=!0,Aa(on))this.events.next(new Ht(We.id,this.urlSerializer.serialize(We.extractedUrl),on.message,on.cancellationCode)),function Ba(R){return Aa(R)&&Jt(R.url)}(on)?this.events.next(new Pr(on.url,on.navigationBehaviorOptions)):We.resolve(!1);else{const ur=new hn(We.id,this.urlSerializer.serialize(We.extractedUrl),on,We.targetSnapshot??void 0);try{const ui=(0,i.N4e)(this.environmentInjector,()=>this.navigationErrorHandler?.(ur));if(!(ui instanceof Da))throw this.events.next(ur),on;{const{message:kr,cancellationCode:Gi}=Us(0,ui);this.events.next(new Ht(We.id,this.urlSerializer.serialize(We.extractedUrl),kr,Gi)),this.events.next(new Pr(ui.redirectTo,ui.navigationBehaviorOptions))}}catch(ui){this.options.resolveNavigationPromiseOnError?We.resolve(!1):We.reject(ui)}}return Z.w}))}))}cancelNavigationTransition(F,K,_e){const We=new Ht(F.id,this.urlSerializer.serialize(F.extractedUrl),K,_e);this.events.next(We),F.resolve(!1)}isUpdatingInternalState(){return this.currentTransition?.extractedUrl.toString()!==this.currentTransition?.currentUrlTree.toString()}isUpdatedBrowserUrl(){const F=this.urlHandlingStrategy.extract(this.urlSerializer.parse(this.location.path(!0))),K=this.currentNavigation?.targetBrowserUrl??this.currentNavigation?.extractedUrl;return F.toString()!==K?.toString()&&!this.currentNavigation?.extras.skipLocationChange}static \u0275fac=function(K){return new(K||R)};static \u0275prov=i.jDH({token:R,factory:R.\u0275fac,providedIn:"root"})}return R})();function Ie(R){return R!==tt}let ne=(()=>{class R{static \u0275fac=function(K){return new(K||R)};static \u0275prov=i.jDH({token:R,factory:()=>(0,i.WQX)(Et),providedIn:"root"})}return R})();class ye{shouldDetach(G){return!1}store(G,F){}shouldAttach(G){return!1}retrieve(G){return null}shouldReuseRoute(G,F){return G.routeConfig===F.routeConfig}}let Et=(()=>{class R extends ye{static \u0275fac=(()=>{let F;return function(_e){return(F||(F=i.xGo(R)))(_e||R)}})();static \u0275prov=i.jDH({token:R,factory:R.\u0275fac,providedIn:"root"})}return R})(),Gt=(()=>{class R{static \u0275fac=function(K){return new(K||R)};static \u0275prov=i.jDH({token:R,factory:()=>(0,i.WQX)(Un),providedIn:"root"})}return R})(),Un=(()=>{class R extends Gt{location=(0,i.WQX)(se.aZ);urlSerializer=(0,i.WQX)(ft);options=(0,i.WQX)(Qi,{optional:!0})||{};canceledNavigationResolution=this.options.canceledNavigationResolution||"replace";urlHandlingStrategy=(0,i.WQX)(Za);urlUpdateStrategy=this.options.urlUpdateStrategy||"deferred";currentUrlTree=new ke;getCurrentUrlTree(){return this.currentUrlTree}rawUrlTree=this.currentUrlTree;getRawUrlTree(){return this.rawUrlTree}currentPageId=0;lastSuccessfulId=-1;restoredState(){return this.location.getState()}get browserPageId(){return"computed"!==this.canceledNavigationResolution?this.currentPageId:this.restoredState()?.\u0275routerPageId??this.currentPageId}routerState=Xo(null);getRouterState(){return this.routerState}stateMemento=this.createStateMemento();createStateMemento(){return{rawUrlTree:this.rawUrlTree,currentUrlTree:this.currentUrlTree,routerState:this.routerState}}registerNonRouterCurrentEntryChangeListener(F){return this.location.subscribe(K=>{"popstate"===K.type&&F(K.url,K.state)})}handleRouterEvent(F,K){if(F instanceof ve)this.stateMemento=this.createStateMemento();else if(F instanceof kt)this.rawUrlTree=K.initialUrl;else if(F instanceof Dn){if("eager"===this.urlUpdateStrategy&&!K.extras.skipLocationChange){const _e=this.urlHandlingStrategy.merge(K.finalUrl,K.initialUrl);this.setBrowserUrl(K.targetBrowserUrl??_e,K)}}else F instanceof Qr?(this.currentUrlTree=K.finalUrl,this.rawUrlTree=this.urlHandlingStrategy.merge(K.finalUrl,K.initialUrl),this.routerState=K.targetRouterState,"deferred"===this.urlUpdateStrategy&&!K.extras.skipLocationChange&&this.setBrowserUrl(K.targetBrowserUrl??this.rawUrlTree,K)):F instanceof Ht&&(F.code===Ne.GuardRejected||F.code===Ne.NoDataFromResolver)?this.restoreHistory(K):F instanceof hn?this.restoreHistory(K,!0):F instanceof Ye&&(this.lastSuccessfulId=F.id,this.currentPageId=this.browserPageId)}setBrowserUrl(F,K){const _e=F instanceof ke?this.urlSerializer.serialize(F):F;if(this.location.isCurrentPathEqualTo(_e)||K.extras.replaceUrl){const At={...K.extras.state,...this.generateNgRouterState(K.id,this.browserPageId)};this.location.replaceState(_e,"",At)}else{const We={...K.extras.state,...this.generateNgRouterState(K.id,this.browserPageId+1)};this.location.go(_e,"",We)}}restoreHistory(F,K=!1){if("computed"===this.canceledNavigationResolution){const We=this.currentPageId-this.browserPageId;0!==We?this.location.historyGo(We):this.currentUrlTree===F.finalUrl&&0===We&&(this.resetState(F),this.resetUrlToCurrentUrlTree())}else"replace"===this.canceledNavigationResolution&&(K&&this.resetState(F),this.resetUrlToCurrentUrlTree())}resetState(F){this.routerState=this.stateMemento.routerState,this.currentUrlTree=this.stateMemento.currentUrlTree,this.rawUrlTree=this.urlHandlingStrategy.merge(this.currentUrlTree,F.finalUrl??this.rawUrlTree)}resetUrlToCurrentUrlTree(){this.location.replaceState(this.urlSerializer.serialize(this.rawUrlTree),"",this.generateNgRouterState(this.lastSuccessfulId,this.currentPageId))}generateNgRouterState(F,K){return"computed"===this.canceledNavigationResolution?{navigationId:F,\u0275routerPageId:K}:{navigationId:F}}static \u0275fac=(()=>{let F;return function(_e){return(F||(F=i.xGo(R)))(_e||R)}})();static \u0275prov=i.jDH({token:R,factory:R.\u0275fac,providedIn:"root"})}return R})();var tr=function(R){return R[R.COMPLETE=0]="COMPLETE",R[R.FAILED=1]="FAILED",R[R.REDIRECTING=2]="REDIRECTING",R}(tr||{});function ci(R,G){R.events.pipe((0,xe.p)(F=>F instanceof Ye||F instanceof Ht||F instanceof hn||F instanceof kt),(0,ae.T)(F=>F instanceof Ye||F instanceof kt?tr.COMPLETE:F instanceof Ht&&(F.code===Ne.Redirect||F.code===Ne.SupersededByNewNavigation)?tr.REDIRECTING:tr.FAILED),(0,xe.p)(F=>F!==tr.REDIRECTING),(0,be.s)(1)).subscribe(()=>{G()})}const Di={paths:"exact",fragment:"ignored",matrixParams:"ignored",queryParams:"exact"},Rr={paths:"subset",fragment:"ignored",matrixParams:"ignored",queryParams:"subset"};let li=(()=>{class R{get currentUrlTree(){return this.stateManager.getCurrentUrlTree()}get rawUrlTree(){return this.stateManager.getRawUrlTree()}disposed=!1;nonRouterCurrentEntryChangeSubscription;console=(0,i.WQX)(i.H3F);stateManager=(0,i.WQX)(Gt);options=(0,i.WQX)(Qi,{optional:!0})||{};pendingTasks=(0,i.WQX)(i.TgB);urlUpdateStrategy=this.options.urlUpdateStrategy||"deferred";navigationTransitions=(0,i.WQX)(U);urlSerializer=(0,i.WQX)(ft);location=(0,i.WQX)(se.aZ);urlHandlingStrategy=(0,i.WQX)(Za);_events=new re.B;get events(){return this._events}get routerState(){return this.stateManager.getRouterState()}navigated=!1;routeReuseStrategy=(0,i.WQX)(ne);onSameUrlNavigation=this.options.onSameUrlNavigation||"ignore";config=(0,i.WQX)(Ki,{optional:!0})?.flat()??[];componentInputBindingEnabled=!!(0,i.WQX)(Ts,{optional:!0});constructor(){this.resetConfig(this.config),this.navigationTransitions.setupNavigations(this,this.currentUrlTree,this.routerState).subscribe({error:F=>{this.console.warn(F)}}),this.subscribeToNavigationEvents()}eventsSubscription=new pe.yU;subscribeToNavigationEvents(){const F=this.navigationTransitions.events.subscribe(K=>{try{const _e=this.navigationTransitions.currentTransition,We=this.navigationTransitions.currentNavigation;if(null!==_e&&null!==We)if(this.stateManager.handleRouterEvent(K,We),K instanceof Ht&&K.code!==Ne.Redirect&&K.code!==Ne.SupersededByNewNavigation)this.navigated=!0;else if(K instanceof Ye)this.navigated=!0;else if(K instanceof Pr){const At=K.navigationBehaviorOptions,fn=this.urlHandlingStrategy.merge(K.url,_e.currentRawUrl),on={browserUrl:_e.extras.browserUrl,info:_e.extras.info,skipLocationChange:_e.extras.skipLocationChange,replaceUrl:_e.extras.replaceUrl||"eager"===this.urlUpdateStrategy||Ie(_e.source),...At};this.scheduleNavigation(fn,tt,null,on,{resolve:_e.resolve,reject:_e.reject,promise:_e.promise})}(function wi(R){return!(R instanceof Qr||R instanceof Pr)})(K)&&this._events.next(K)}catch(_e){this.navigationTransitions.transitionAbortSubject.next(_e)}});this.eventsSubscription.add(F)}resetRootComponentType(F){this.routerState.root.component=F,this.navigationTransitions.rootComponentType=F}initialNavigation(){this.setUpLocationChangeListener(),this.navigationTransitions.hasRequestedNavigation||this.navigateToSyncWithBrowser(this.location.path(!0),tt,this.stateManager.restoredState())}setUpLocationChangeListener(){this.nonRouterCurrentEntryChangeSubscription??=this.stateManager.registerNonRouterCurrentEntryChangeListener((F,K)=>{setTimeout(()=>{this.navigateToSyncWithBrowser(F,"popstate",K)},0)})}navigateToSyncWithBrowser(F,K,_e){const We={replaceUrl:!0},At=_e?.navigationId?_e:null;if(_e){const on={..._e};delete on.navigationId,delete on.\u0275routerPageId,0!==Object.keys(on).length&&(We.state=on)}const fn=this.parseUrl(F);this.scheduleNavigation(fn,K,At,We)}get url(){return this.serializeUrl(this.currentUrlTree)}getCurrentNavigation(){return this.navigationTransitions.currentNavigation}get lastSuccessfulNavigation(){return this.navigationTransitions.lastSuccessfulNavigation}resetConfig(F){this.config=F.map(Bi),this.navigated=!1}ngOnDestroy(){this.dispose()}dispose(){this.navigationTransitions.complete(),this.nonRouterCurrentEntryChangeSubscription&&(this.nonRouterCurrentEntryChangeSubscription.unsubscribe(),this.nonRouterCurrentEntryChangeSubscription=void 0),this.disposed=!0,this.eventsSubscription.unsubscribe()}createUrlTree(F,K={}){const{relativeTo:_e,queryParams:We,fragment:At,queryParamsHandling:fn,preserveFragment:on}=K,ur=on?this.currentUrlTree.fragment:At;let kr,ui=null;switch(fn??this.options.defaultQueryParamsHandling){case"merge":ui={...this.currentUrlTree.queryParams,...We};break;case"preserve":ui=this.currentUrlTree.queryParams;break;default:ui=We||null}null!==ui&&(ui=this.removeEmptyProps(ui));try{kr=nt(_e?_e.snapshot:this.routerState.snapshot.root)}catch{("string"!=typeof F[0]||"/"!==F[0][0])&&(F=[]),kr=this.currentUrlTree.root}return Rt(kr,F,ui,ur??null)}navigateByUrl(F,K={skipLocationChange:!1}){const _e=Jt(F)?F:this.parseUrl(F),We=this.urlHandlingStrategy.merge(_e,this.rawUrlTree);return this.scheduleNavigation(We,tt,null,K)}navigate(F,K={skipLocationChange:!1}){return function ii(R){for(let G=0;G(null!=We&&(K[_e]=We),K),{})}scheduleNavigation(F,K,_e,We,At){if(this.disposed)return Promise.resolve(!1);let fn,on,ur;At?(fn=At.resolve,on=At.reject,ur=At.promise):ur=new Promise((kr,Gi)=>{fn=kr,on=Gi});const ui=this.pendingTasks.add();return ci(this,()=>{queueMicrotask(()=>this.pendingTasks.remove(ui))}),this.navigationTransitions.handleNavigationRequest({source:K,restoredState:_e,currentUrlTree:this.currentUrlTree,currentRawUrl:this.currentUrlTree,rawUrl:F,extras:We,resolve:fn,reject:on,promise:ur,currentSnapshot:this.routerState.snapshot,currentRouterState:this.routerState}),ur.catch(kr=>Promise.reject(kr))}static \u0275fac=function(K){return new(K||R)};static \u0275prov=i.jDH({token:R,factory:R.\u0275fac,providedIn:"root"})}return R})(),bs=(()=>{class R{router;route;tabIndexAttribute;renderer;el;locationStrategy;href=null;target;queryParams;fragment;queryParamsHandling;state;info;relativeTo;isAnchorElement;subscription;onChanges=new re.B;constructor(F,K,_e,We,At,fn){this.router=F,this.route=K,this.tabIndexAttribute=_e,this.renderer=We,this.el=At,this.locationStrategy=fn;const on=At.nativeElement.tagName?.toLowerCase();this.isAnchorElement="a"===on||"area"===on,this.isAnchorElement?this.subscription=F.events.subscribe(ur=>{ur instanceof Ye&&this.updateHref()}):this.setTabIndexIfNotOnNativeEl("0")}preserveFragment=!1;skipLocationChange=!1;replaceUrl=!1;setTabIndexIfNotOnNativeEl(F){null!=this.tabIndexAttribute||this.isAnchorElement||this.applyAttributeValue("tabindex",F)}ngOnChanges(F){this.isAnchorElement&&this.updateHref(),this.onChanges.next(this)}routerLinkInput=null;set routerLink(F){null==F?(this.routerLinkInput=null,this.setTabIndexIfNotOnNativeEl(null)):(this.routerLinkInput=Jt(F)||Array.isArray(F)?F:[F],this.setTabIndexIfNotOnNativeEl("0"))}onClick(F,K,_e,We,At){const fn=this.urlTree;return!!(null===fn||this.isAnchorElement&&(0!==F||K||_e||We||At||"string"==typeof this.target&&"_self"!=this.target))||(this.router.navigateByUrl(fn,{skipLocationChange:this.skipLocationChange,replaceUrl:this.replaceUrl,state:this.state,info:this.info}),!this.isAnchorElement)}ngOnDestroy(){this.subscription?.unsubscribe()}updateHref(){const F=this.urlTree;this.href=null!==F&&this.locationStrategy?this.locationStrategy?.prepareExternalUrl(this.router.serializeUrl(F)):null;const K=null===this.href?null:(0,i.n$t)(this.href,this.el.nativeElement.tagName.toLowerCase(),"href");this.applyAttributeValue("href",K)}applyAttributeValue(F,K){const _e=this.renderer,We=this.el.nativeElement;null!==K?_e.setAttribute(We,F,K):_e.removeAttribute(We,F)}get urlTree(){return null===this.routerLinkInput?null:Jt(this.routerLinkInput)?this.routerLinkInput:this.router.createUrlTree(this.routerLinkInput,{relativeTo:void 0!==this.relativeTo?this.relativeTo:this.route,queryParams:this.queryParams,fragment:this.fragment,queryParamsHandling:this.queryParamsHandling,preserveFragment:this.preserveFragment})}static \u0275fac=function(K){return new(K||R)(i.rXU(li),i.rXU(_o),i.kS0("tabindex"),i.rXU(i.sFG),i.rXU(i.aKT),i.rXU(se.hb))};static \u0275dir=i.FsC({type:R,selectors:[["","routerLink",""]],hostVars:1,hostBindings:function(K,_e){1&K&&i.bIt("click",function(At){return _e.onClick(At.button,At.ctrlKey,At.shiftKey,At.altKey,At.metaKey)}),2&K&&i.BMQ("target",_e.target)},inputs:{target:"target",queryParams:"queryParams",fragment:"fragment",queryParamsHandling:"queryParamsHandling",state:"state",info:"info",relativeTo:"relativeTo",preserveFragment:[2,"preserveFragment","preserveFragment",i.L39],skipLocationChange:[2,"skipLocationChange","skipLocationChange",i.L39],replaceUrl:[2,"replaceUrl","replaceUrl",i.L39],routerLink:"routerLink"},features:[i.GFd,i.OA$]})}return R})(),Lo=(()=>{class R{router;element;renderer;cdr;link;links;classes=[];routerEventsSubscription;linkInputChangesSubscription;_isActive=!1;get isActive(){return this._isActive}routerLinkActiveOptions={exact:!1};ariaCurrentWhenActive;isActiveChange=new i.bkB;constructor(F,K,_e,We,At){this.router=F,this.element=K,this.renderer=_e,this.cdr=We,this.link=At,this.routerEventsSubscription=F.events.subscribe(fn=>{fn instanceof Ye&&this.update()})}ngAfterContentInit(){(0,y.of)(this.links.changes,(0,y.of)(null)).pipe((0,Ft.U)()).subscribe(F=>{this.update(),this.subscribeToEachLinkOnChanges()})}subscribeToEachLinkOnChanges(){this.linkInputChangesSubscription?.unsubscribe();const F=[...this.links.toArray(),this.link].filter(K=>!!K).map(K=>K.onChanges);this.linkInputChangesSubscription=(0,c.H)(F).pipe((0,Ft.U)()).subscribe(K=>{this._isActive!==this.isLinkActive(this.router)(K)&&this.update()})}set routerLinkActive(F){const K=Array.isArray(F)?F:F.split(" ");this.classes=K.filter(_e=>!!_e)}ngOnChanges(F){this.update()}ngOnDestroy(){this.routerEventsSubscription.unsubscribe(),this.linkInputChangesSubscription?.unsubscribe()}update(){!this.links||!this.router.navigated||queueMicrotask(()=>{const F=this.hasActiveLinks();this.classes.forEach(K=>{F?this.renderer.addClass(this.element.nativeElement,K):this.renderer.removeClass(this.element.nativeElement,K)}),F&&void 0!==this.ariaCurrentWhenActive?this.renderer.setAttribute(this.element.nativeElement,"aria-current",this.ariaCurrentWhenActive.toString()):this.renderer.removeAttribute(this.element.nativeElement,"aria-current"),this._isActive!==F&&(this._isActive=F,this.cdr.markForCheck(),this.isActiveChange.emit(F))})}isLinkActive(F){const K=function fa(R){return!!R.paths}(this.routerLinkActiveOptions)?this.routerLinkActiveOptions:this.routerLinkActiveOptions.exact||!1;return _e=>{const We=_e.urlTree;return!!We&&F.isActive(We,K)}}hasActiveLinks(){const F=this.isLinkActive(this.router);return this.link&&F(this.link)||this.links.some(F)}static \u0275fac=function(K){return new(K||R)(i.rXU(li),i.rXU(i.aKT),i.rXU(i.sFG),i.rXU(i.gRc),i.rXU(bs,8))};static \u0275dir=i.FsC({type:R,selectors:[["","routerLinkActive",""]],contentQueries:function(K,_e,We){if(1&K&&i.wni(We,bs,5),2&K){let At;i.mGM(At=i.lsd())&&(_e.links=At)}},inputs:{routerLinkActiveOptions:"routerLinkActiveOptions",ariaCurrentWhenActive:"ariaCurrentWhenActive",routerLinkActive:"routerLinkActive"},outputs:{isActiveChange:"isActiveChange"},exportAs:["routerLinkActive"],features:[i.OA$]})}return R})();class Yo{}let Ta=(()=>{class R{router;injector;preloadingStrategy;loader;subscription;constructor(F,K,_e,We,At){this.router=F,this.injector=_e,this.preloadingStrategy=We,this.loader=At}setUpPreloading(){this.subscription=this.router.events.pipe((0,xe.p)(F=>F instanceof Ye),(0,ue.H)(()=>this.preload())).subscribe(()=>{})}preload(){return this.processRoutes(this.injector,this.router.config)}ngOnDestroy(){this.subscription&&this.subscription.unsubscribe()}processRoutes(F,K){const _e=[];for(const We of K){We.providers&&!We._injector&&(We._injector=(0,i.Ol2)(We.providers,F,`Route: ${We.path}`));const At=We._injector??F,fn=We._loadedInjector??At;(We.loadChildren&&!We._loadedRoutes&&void 0===We.canLoad||We.loadComponent&&!We._loadedComponent)&&_e.push(this.preloadConfig(At,We)),(We.children||We._loadedRoutes)&&_e.push(this.processRoutes(fn,We.children??We._loadedRoutes))}return(0,c.H)(_e).pipe((0,Ft.U)())}preloadConfig(F,K){return this.preloadingStrategy.preload(K,()=>{let _e;_e=K.loadChildren&&void 0===K.canLoad?this.loader.loadChildren(F,K):(0,y.of)(null);const We=_e.pipe((0,De.Z)(At=>null===At?(0,y.of)(void 0):(K._loadedRoutes=At.routes,K._loadedInjector=At.injector,this.processRoutes(At.injector??F,At.routes))));if(K.loadComponent&&!K._loadedComponent){const At=this.loader.loadComponent(K);return(0,c.H)([We,At]).pipe((0,Ft.U)())}return We})}static \u0275fac=function(K){return new(K||R)(i.KVO(li),i.KVO(i.Ql9),i.KVO(i.uvJ),i.KVO(Yo),i.KVO(no))};static \u0275prov=i.jDH({token:R,factory:R.\u0275fac,providedIn:"root"})}return R})();const Ma=new i.nKC("");let qa=(()=>{class R{urlSerializer;transitions;viewportScroller;zone;options;routerEventsSubscription;scrollEventsSubscription;lastId=0;lastSource="imperative";restoredId=0;store={};constructor(F,K,_e,We,At={}){this.urlSerializer=F,this.transitions=K,this.viewportScroller=_e,this.zone=We,this.options=At,At.scrollPositionRestoration||="disabled",At.anchorScrolling||="disabled"}init(){"disabled"!==this.options.scrollPositionRestoration&&this.viewportScroller.setHistoryScrollRestoration("manual"),this.routerEventsSubscription=this.createScrollEvents(),this.scrollEventsSubscription=this.consumeScrollEvents()}createScrollEvents(){return this.transitions.events.subscribe(F=>{F instanceof ve?(this.store[this.lastId]=this.viewportScroller.getScrollPosition(),this.lastSource=F.navigationTrigger,this.restoredId=F.restoredState?F.restoredState.navigationId:0):F instanceof Ye?(this.lastId=F.id,this.scheduleScrollEvent(F,this.urlSerializer.parse(F.urlAfterRedirects).fragment)):F instanceof kt&&F.code===gt.IgnoredSameUrlNavigation&&(this.lastSource=void 0,this.restoredId=0,this.scheduleScrollEvent(F,this.urlSerializer.parse(F.url).fragment))})}consumeScrollEvents(){return this.transitions.events.subscribe(F=>{F instanceof Or&&(F.position?"top"===this.options.scrollPositionRestoration?this.viewportScroller.scrollToPosition([0,0]):"enabled"===this.options.scrollPositionRestoration&&this.viewportScroller.scrollToPosition(F.position):F.anchor&&"enabled"===this.options.anchorScrolling?this.viewportScroller.scrollToAnchor(F.anchor):"disabled"!==this.options.scrollPositionRestoration&&this.viewportScroller.scrollToPosition([0,0]))})}scheduleScrollEvent(F,K){this.zone.runOutsideAngular(()=>{setTimeout(()=>{this.zone.run(()=>{this.transitions.events.next(new Or(F,"popstate"===this.lastSource?this.store[this.restoredId]:null,K))})},0)})}ngOnDestroy(){this.routerEventsSubscription?.unsubscribe(),this.scrollEventsSubscription?.unsubscribe()}static \u0275fac=function(K){i.QTQ()};static \u0275prov=i.jDH({token:R,factory:R.\u0275fac})}return R})();function ou(R,...G){return(0,i.EmA)([{provide:Ki,multi:!0,useValue:R},[],{provide:_o,useFactory:ka,deps:[li]},{provide:i.iLQ,multi:!0,useFactory:pc},G.map(F=>F.\u0275providers)])}function ka(R){return R.routerState.root}function Ia(R,G){return{\u0275kind:R,\u0275providers:G}}function Wl(R={}){return Ia(4,[{provide:Ma,useFactory:()=>{const F=(0,i.WQX)(se.Xr),K=(0,i.WQX)(i.SKi),_e=(0,i.WQX)(U),We=(0,i.WQX)(ft);return new qa(We,_e,F,K,R)}}])}function pc(){const R=(0,i.WQX)(i.zZn);return G=>{const F=R.get(i.o8S);if(G!==F.components[0])return;const K=R.get(li),_e=R.get(fl);1===R.get(yo)&&K.initialNavigation(),R.get(mc,null,i.$GK.Optional)?.setUpPreloading(),R.get(Ma,null,i.$GK.Optional)?.init(),K.resetRootComponentType(F.componentTypes[0]),_e.closed||(_e.next(),_e.complete(),_e.unsubscribe())}}const fl=new i.nKC("",{factory:()=>new re.B}),yo=new i.nKC("",{providedIn:"root",factory:()=>1}),mc=new i.nKC("");function lu(R){return Ia(0,[{provide:mc,useExisting:Ta},{provide:Yo,useExisting:R}])}function Ur(R){return Ia(9,[{provide:vo,useValue:Vs},{provide:Ci,useValue:{skipNextTransition:!!R?.skipInitialTransition,...R}}])}const Hs=new i.nKC("ROUTER_FORROOT_GUARD"),zl=[se.aZ,{provide:ft,useClass:mt},li,Go,{provide:_o,useFactory:ka,deps:[li]},no,[]];let Wa=(()=>{class R{constructor(F){}static forRoot(F,K){return{ngModule:R,providers:[zl,[],{provide:Ki,multi:!0,useValue:F},{provide:Hs,useFactory:pl,deps:[[li,new i.Xx1,new i.kdw]]},K?.errorHandler?{provide:Ui,useValue:K.errorHandler}:[],{provide:Qi,useValue:K||{}},K?.useHash?{provide:se.hb,useClass:se.fw}:{provide:se.hb,useClass:se.Sm},{provide:Ma,useFactory:()=>{const R=(0,i.WQX)(se.Xr),G=(0,i.WQX)(i.SKi),F=(0,i.WQX)(Qi),K=(0,i.WQX)(U),_e=(0,i.WQX)(ft);return F.scrollOffset&&R.setOffset(F.scrollOffset),new qa(_e,K,R,G,F)}},K?.preloadingStrategy?lu(K.preloadingStrategy).\u0275providers:[],K?.initialNavigation?gd(K):[],K?.bindToComponentInputs?Ia(8,[Ns,{provide:Ts,useExisting:Ns}]).\u0275providers:[],K?.enableViewTransitions?Ur().\u0275providers:[],[{provide:cu,useFactory:pc},{provide:i.iLQ,multi:!0,useExisting:cu}]]}}static forChild(F){return{ngModule:R,providers:[{provide:Ki,multi:!0,useValue:F}]}}static \u0275fac=function(K){return new(K||R)(i.KVO(Hs,8))};static \u0275mod=i.$C({type:R});static \u0275inj=i.G2t({})}return R})();function pl(R){return"guarded"}function gd(R){return["disabled"===R.initialNavigation?Ia(3,[{provide:i.hnV,multi:!0,useFactory:()=>{const G=(0,i.WQX)(li);return()=>{G.setUpLocationChangeListener()}}},{provide:yo,useValue:2}]).\u0275providers:[],"enabledBlocking"===R.initialNavigation?Ia(2,[{provide:yo,useValue:0},{provide:i.hnV,multi:!0,deps:[i.zZn],useFactory:G=>{const F=G.get(se.hj,Promise.resolve());return()=>F.then(()=>new Promise(K=>{const _e=G.get(li),We=G.get(fl);ci(_e,()=>{K(!0)}),G.get(U).afterPreactivation=()=>(K(!0),We.closed?(0,y.of)(void 0):We),_e.initialNavigation()}))}}]).\u0275providers:[]]}const cu=new i.nKC("")},8378:(o,s,r)=>{"use strict";r.d(s,{My:()=>Oe,aT:()=>ce});const be=Array.from({length:256},(qe,_t)=>_t.toString(16).padStart(2,"0"));function Oe(qe){!function c(qe,..._t){if(!function a(qe){return qe instanceof Uint8Array||ArrayBuffer.isView(qe)&&"Uint8Array"===qe.constructor.name}(qe))throw new Error("Uint8Array expected");if(_t.length>0&&!_t.includes(qe.length))throw new Error("Uint8Array expected of length "+_t+", got length="+qe.length)}(qe);let _t="";for(let ze=0;ze=xe._0&&qe<=xe._9?qe-xe._0:qe>=xe.A&&qe<=xe.F?qe-(xe.A-10):qe>=xe.a&&qe<=xe.f?qe-(xe.a-10):void 0}function ce(qe){if("string"!=typeof qe)throw new Error("hex string expected, got "+typeof qe);const _t=qe.length,ze=_t/2;if(_t%2)throw new Error("hex string expected, got unpadded hex of length "+_t);const $e=new Uint8Array(ze);for(let Ft=0,Ke=0;Ft{"use strict";function a(Mt){return Mt instanceof Uint8Array||null!=Mt&&"object"==typeof Mt&&"Uint8Array"===Mt.constructor.name}function c(...Mt){const Kt=kn=>kn,rt=(kn,Kn)=>Nr=>kn(Kn(Nr));return{encode:Mt.map(kn=>kn.encode).reduceRight(rt,Kt),decode:Mt.map(kn=>kn.decode).reduce(rt,Kt)}}function y(Mt){return{encode:Kt=>{if(!Array.isArray(Kt)||Kt.length&&"number"!=typeof Kt[0])throw new Error("alphabet.encode input should be an array of numbers");return Kt.map(rt=>{if(rt<0||rt>=Mt.length)throw new Error(`Digit index outside alphabet: ${rt} (alphabet: ${Mt.length})`);return Mt[rt]})},decode:Kt=>{if(!Array.isArray(Kt)||Kt.length&&"string"!=typeof Kt[0])throw new Error("alphabet.decode input should be array of strings");return Kt.map(rt=>{if("string"!=typeof rt)throw new Error(`alphabet.decode: not string element=${rt}`);const Vt=Mt.indexOf(rt);if(-1===Vt)throw new Error(`Unknown letter: "${rt}". Allowed: ${Mt}`);return Vt})}}}function w(Mt=""){if("string"!=typeof Mt)throw new Error("join separator should be string");return{encode:Kt=>{if(!Array.isArray(Kt)||Kt.length&&"string"!=typeof Kt[0])throw new Error("join.encode input should be array of strings");for(let rt of Kt)if("string"!=typeof rt)throw new Error(`join.encode: non-string input=${rt}`);return Kt.join(Mt)},decode:Kt=>{if("string"!=typeof Kt)throw new Error("join.decode input should be string");return Kt.split(Mt)}}}function C(Mt,Kt="="){if("string"!=typeof Kt)throw new Error("padding chr should be string");return{encode(rt){if(!Array.isArray(rt)||rt.length&&"string"!=typeof rt[0])throw new Error("padding.encode input should be array of strings");for(let Vt of rt)if("string"!=typeof Vt)throw new Error(`padding.encode: non-string input=${Vt}`);for(;rt.length*Mt%8;)rt.push(Kt);return rt},decode(rt){if(!Array.isArray(rt)||rt.length&&"string"!=typeof rt[0])throw new Error("padding.encode input should be array of strings");for(let en of rt)if("string"!=typeof en)throw new Error(`padding.decode: non-string input=${en}`);let Vt=rt.length;if(Vt*Mt%8)throw new Error("Invalid padding: string should have whole number of bytes");for(;Vt>0&&rt[Vt-1]===Kt;Vt--)if(!((Vt-1)*Mt%8))throw new Error("Invalid padding: string has too much padding");return rt.slice(0,Vt)}}}function S(Mt,Kt,rt){if(Kt<2)throw new Error(`convertRadix: wrong from=${Kt}, base cannot be less than 2`);if(rt<2)throw new Error(`convertRadix: wrong to=${rt}, base cannot be less than 2`);if(!Array.isArray(Mt))throw new Error("convertRadix: data should be array");if(!Mt.length)return[];let Vt=0;const en=[],kn=Array.from(Mt);for(kn.forEach(Kn=>{if(Kn<0||Kn>=Kt)throw new Error(`Wrong integer: ${Kn}`)});;){let Kn=0,Nr=!0;for(let Rn=Vt;RnFt,K3:()=>ce,Tq:()=>Vn});const M=(Mt,Kt)=>Kt?M(Kt,Mt%Kt):Mt,O=(Mt,Kt)=>Mt+(Kt-M(Mt,Kt));function L(Mt,Kt,rt,Vt){if(!Array.isArray(Mt))throw new Error("convertRadix2: data should be array");if(Kt<=0||Kt>32)throw new Error(`convertRadix2: wrong from=${Kt}`);if(rt<=0||rt>32)throw new Error(`convertRadix2: wrong to=${rt}`);if(O(Kt,rt)>32)throw new Error(`convertRadix2: carry overflow from=${Kt} to=${rt} carryBits=${O(Kt,rt)}`);let en=0,kn=0;const Kn=2**rt-1,Nr=[];for(const Rn of Mt){if(Rn>=2**Kt)throw new Error(`convertRadix2: invalid data word=${Rn} from=${Kt}`);if(en=en<32)throw new Error(`convertRadix2: carry overflow pos=${kn} from=${Kt}`);for(kn+=Kt;kn>=rt;kn-=rt)Nr.push((en>>kn-rt&Kn)>>>0);en&=2**kn-1}if(en=en<=Kt)throw new Error("Excess padding");if(!Vt&&en)throw new Error(`Non-zero padding: ${en}`);return Vt&&kn>0&&Nr.push(en>>>0),Nr}function Z(Mt){return{encode:Kt=>{if(!a(Kt))throw new Error("radix.encode input should be Uint8Array");return S(Array.from(Kt),256,Mt)},decode:Kt=>{if(!Array.isArray(Kt)||Kt.length&&"number"!=typeof Kt[0])throw new Error("radix.decode input should be array of numbers");return Uint8Array.from(S(Kt,Mt,256))}}}function q(Mt,Kt=!1){if(Mt<=0||Mt>32)throw new Error("radix2: bits should be in (0..32]");if(O(8,Mt)>32||O(Mt,8)>32)throw new Error("radix2: carry overflow");return{encode:rt=>{if(!a(rt))throw new Error("radix2.encode input should be Uint8Array");return L(Array.from(rt),8,Mt,!Kt)},decode:rt=>{if(!Array.isArray(rt)||rt.length&&"number"!=typeof rt[0])throw new Error("radix2.decode input should be array of numbers");return Uint8Array.from(L(rt,Mt,8,Kt))}}}function re(Mt){if("function"!=typeof Mt)throw new Error("unsafeWrapper fn should be function");return function(...Kt){try{return Mt.apply(null,Kt)}catch{}}}function pe(Mt,Kt){if("function"!=typeof Kt)throw new Error("checksum fn should be function");return{encode(rt){if(!a(rt))throw new Error("checksum.encode: input should be Uint8Array");const Vt=Kt(rt).slice(0,Mt),en=new Uint8Array(rt.length+Mt);return en.set(rt),en.set(Vt,rt.length),en},decode(rt){if(!a(rt))throw new Error("checksum.decode: input should be Uint8Array");const Vt=rt.slice(0,-Mt),en=Kt(Vt).slice(0,Mt),kn=rt.slice(-Mt);for(let Kn=0;Knc(Z(58),y("123456789ABCDEFGHJKLMNPQRSTUVWXYZabcdefghijkmnopqrstuvwxyz"),w("")))(),Vn=Mt=>c(pe(4,Kt=>Mt(Mt(Kt))),dt),yn=c(y("qpzry9x8gf2tvdw0s3jn54khce6mua7l"),w("")),qe=[996825010,642813549,513874426,1027748829,705979059];function _t(Mt){const Kt=Mt>>25;let rt=(33554431&Mt)<<5;for(let Vt=0;Vt>Vt&1)&&(rt^=qe[Vt]);return rt}function ze(Mt,Kt,rt=1){const Vt=Mt.length;let en=1;for(let kn=0;kn126)throw new Error(`Invalid prefix (${Mt})`);en=_t(en)^Kn>>5}en=_t(en);for(let kn=0;knJe)throw new TypeError(`Length ${z} exceeds limit ${Je}`);const N=Fe.toLowerCase(),W=ze(N,ke,Kt);return`${N}1${yn.encode(ke)}${W}`}function Nr(Fe,ke=90){if("string"!=typeof Fe)throw new Error("bech32.decode input should be string, not "+typeof Fe);if(Fe.length<8||!1!==ke&&Fe.length>ke)throw new TypeError(`Wrong string length: ${Fe.length} (${Fe}). Expected (8..${ke})`);const Je=Fe.toLowerCase();if(Fe!==Je&&Fe!==Fe.toUpperCase())throw new Error("String must be lowercase or uppercase");const z=Je.lastIndexOf("1");if(0===z||-1===z)throw new Error('Letter "1" must be present between prefix and data only');const N=Je.slice(0,z),W=Je.slice(z+1);if(W.length<6)throw new Error("Data must be at least 6 characters long");const Le=yn.decode(W).slice(0,-6),ft=ze(N,Le,Kt);if(!W.endsWith(ft))throw new Error(`Invalid checksum in ${Fe}: expected "${ft}"`);return{prefix:N,words:Le}}return{encode:Kn,decode:Nr,encodeFromBytes:function cn(Fe,ke){return Kn(Fe,en(ke))},decodeToBytes:function pr(Fe){const{prefix:ke,words:Je}=Nr(Fe,!1);return{prefix:ke,words:Je,bytes:Vt(Je)}},decodeUnsafe:re(Nr),fromWords:Vt,fromWordsUnsafe:kn,toWords:en}}const Ft=$e("bech32")},2769:(o,s,r)=>{"use strict";r.d(s,{A:()=>y});var i=r(3121),a=r(9311);const y=(0,i.A)(a.A,"Map")},1238:(o,s,r)=>{"use strict";r.d(s,{A:()=>ft});var c=r(2486);const w=function y(mt,St){for(var Tn=mt.length;Tn--;)if((0,c.A)(mt[Tn][0],St))return Tn;return-1};var T=Array.prototype.splice;function se(mt){var St=-1,Tn=null==mt?0:mt.length;for(this.clear();++St-1},se.prototype.set=function re(mt,St){var Tn=this.__data__,an=w(Tn,mt);return an<0?(++this.size,Tn.push([mt,St])):Tn[an][1]=St,this};const ae=se;var Be=r(2769);const bt=(0,r(3121).A)(Object,"create");var qe=Object.prototype.hasOwnProperty;var Ft=Object.prototype.hasOwnProperty;function Te(mt){var St=-1,Tn=null==mt?0:mt.length;for(this.clear();++St{"use strict";r.d(s,{A:()=>c});const c=r(9311).A.Symbol},6259:(o,s,r)=>{"use strict";r.d(s,{A:()=>L});var c=r(1656),y=r(9007),w=r(5303),C=r(3467),T=r(766),M=Object.prototype.hasOwnProperty;const L=function O(Z,q){var re=(0,y.A)(Z),pe=!re&&(0,c.A)(Z),se=!re&&!pe&&(0,w.A)(Z),ae=!re&&!pe&&!se&&(0,T.A)(Z),me=re||pe||se||ae,be=me?function i(Z,q){for(var re=-1,pe=Array(Z);++re{"use strict";r.d(s,{A:()=>C});var i=r(8758),a=r(2486),y=Object.prototype.hasOwnProperty;const C=function w(T,S,M){var O=T[S];(!y.call(T,S)||!(0,a.A)(O,M)||void 0===M&&!(S in T))&&(0,i.A)(T,S,M)}},8758:(o,s,r)=>{"use strict";r.d(s,{A:()=>c});var i=r(4133);const c=function a(y,w,C){"__proto__"==w&&i.A?(0,i.A)(y,w,{configurable:!0,enumerable:!0,value:C,writable:!0}):y[w]=C}},5688:(o,s,r)=>{"use strict";r.d(s,{A:()=>se});var i=r(4883),a=Object.prototype,c=a.hasOwnProperty,y=a.toString,w=i.A?i.A.toStringTag:void 0;var M=Object.prototype.toString;var re=i.A?i.A.toStringTag:void 0;const se=function pe(ae){return null==ae?void 0===ae?"[object Undefined]":"[object Null]":re&&re in Object(ae)?function C(ae){var me=c.call(ae,w),be=ae[w];try{ae[w]=void 0;var Oe=!0}catch{}var xe=y.call(ae);return Oe&&(me?ae[w]=be:delete ae[w]),xe}(ae):function O(ae){return M.call(ae)}(ae)}},4975:(o,s,r)=>{"use strict";r.d(s,{A:()=>a});const a=function i(c){return function(y){return c(y)}}},3031:(o,s,r)=>{"use strict";r.d(s,{A:()=>w});const c=r(9311).A.Uint8Array,w=function y(C){var T=new C.constructor(C.byteLength);return new c(T).set(new c(C)),T}},4224:(o,s,r)=>{"use strict";r.d(s,{A:()=>S});var i=r(9311),a="object"==typeof exports&&exports&&!exports.nodeType&&exports,c=a&&"object"==typeof module&&module&&!module.nodeType&&module,w=c&&c.exports===a?i.A.Buffer:void 0,C=w?w.allocUnsafe:void 0;const S=function T(M,O){if(O)return M.slice();var L=M.length,Z=C?C(L):new M.constructor(L);return M.copy(Z),Z}},7383:(o,s,r)=>{"use strict";r.d(s,{A:()=>c});var i=r(3031);const c=function a(y,w){var C=w?(0,i.A)(y.buffer):y.buffer;return new y.constructor(C,y.byteOffset,y.length)}},1369:(o,s,r)=>{"use strict";r.d(s,{A:()=>a});const a=function i(c,y){var w=-1,C=c.length;for(y||(y=Array(C));++w{"use strict";r.d(s,{A:()=>y});var i=r(2065),a=r(8758);const y=function c(w,C,T,S){var M=!T;T||(T={});for(var O=-1,L=C.length;++O{"use strict";r.d(s,{A:()=>c});var i=r(3121);const c=function(){try{var y=(0,i.A)(Object,"defineProperty");return y({},"",{}),y}catch{}}()},8618:(o,s,r)=>{"use strict";r.d(s,{A:()=>a});const a="object"==typeof global&&global&&global.Object===Object&&global},3121:(o,s,r)=>{"use strict";r.d(s,{A:()=>De});var ce,i=r(5656),c=r(9311).A["__core-js_shared__"],w=(ce=/[^.]+$/.exec(c&&c.keys&&c.keys.IE_PROTO||""))?"Symbol(src)_1."+ce:"";var S=r(7999),M=r(4435),L=/^\[object .+?Constructor\]$/,se=RegExp("^"+Function.prototype.toString.call(Object.prototype.hasOwnProperty).replace(/[\\^$.*+?()[\]{}|]/g,"\\$&").replace(/hasOwnProperty|(function).*?(?=\\\()| for .+?(?=\\\])/g,"$1.*?")+"$");const me=function ae(ce){return!(!(0,S.A)(ce)||function C(ce){return!!w&&w in ce}(ce))&&((0,i.A)(ce)?se:L).test((0,M.A)(ce))},De=function xe(ce,ue){var Ce=function be(ce,ue){return ce?.[ue]}(ce,ue);return me(Ce)?Ce:void 0}},5749:(o,s,r)=>{"use strict";r.d(s,{A:()=>c});const c=(0,r(5717).A)(Object.getPrototypeOf,Object)},223:(o,s,r)=>{"use strict";r.d(s,{A:()=>S});var i=r(7999),a=Object.create;const y=function(){function M(){}return function(O){if(!(0,i.A)(O))return{};if(a)return a(O);M.prototype=O;var L=new M;return M.prototype=void 0,L}}();var w=r(5749),C=r(1561);const S=function T(M){return"function"!=typeof M.constructor||(0,C.A)(M)?{}:y((0,w.A)(M))}},3467:(o,s,r)=>{"use strict";r.d(s,{A:()=>y});var a=/^(?:0|[1-9]\d*)$/;const y=function c(w,C){var T=typeof w;return!!(C=C??9007199254740991)&&("number"==T||"symbol"!=T&&a.test(w))&&w>-1&&w%1==0&&w{"use strict";r.d(s,{A:()=>c});var i=Object.prototype;const c=function a(y){var w=y&&y.constructor;return y===("function"==typeof w&&w.prototype||i)}},8583:(o,s,r)=>{"use strict";r.d(s,{A:()=>T});var i=r(8618),a="object"==typeof exports&&exports&&!exports.nodeType&&exports,c=a&&"object"==typeof module&&module&&!module.nodeType&&module,w=c&&c.exports===a&&i.A.process;const T=function(){try{return c&&c.require&&c.require("util").types||w&&w.binding&&w.binding("util")}catch{}}()},5717:(o,s,r)=>{"use strict";r.d(s,{A:()=>a});const a=function i(c,y){return function(w){return c(y(w))}}},9311:(o,s,r)=>{"use strict";r.d(s,{A:()=>y});var i=r(8618),a="object"==typeof self&&self&&self.Object===Object&&self;const y=i.A||a||Function("return this")()},4435:(o,s,r)=>{"use strict";r.d(s,{A:()=>y});var a=Function.prototype.toString;const y=function c(w){if(null!=w){try{return a.call(w)}catch{}try{return w+""}catch{}}return""}},2486:(o,s,r)=>{"use strict";r.d(s,{A:()=>a});const a=function i(c,y){return c===y||c!=c&&y!=y}},6143:(o,s,r)=>{"use strict";r.d(s,{A:()=>a});const a=function i(c){for(var y=-1,w=null==c?0:c.length,C={};++y{"use strict";r.d(s,{A:()=>O});var i=r(5688),a=r(2312);const w=function y(L){return(0,a.A)(L)&&"[object Arguments]"==(0,i.A)(L)};var C=Object.prototype,T=C.hasOwnProperty,S=C.propertyIsEnumerable;const O=w(function(){return arguments}())?w:function(L){return(0,a.A)(L)&&T.call(L,"callee")&&!S.call(L,"callee")}},9007:(o,s,r)=>{"use strict";r.d(s,{A:()=>a});const a=Array.isArray},2808:(o,s,r)=>{"use strict";r.d(s,{A:()=>y});var i=r(5656),a=r(4184);const y=function c(w){return null!=w&&(0,a.A)(w.length)&&!(0,i.A)(w)}},5303:(o,s,r)=>{"use strict";r.d(s,{A:()=>O});var i=r(9311),y="object"==typeof exports&&exports&&!exports.nodeType&&exports,w=y&&"object"==typeof module&&module&&!module.nodeType&&module,T=w&&w.exports===y?i.A.Buffer:void 0;const O=(T?T.isBuffer:void 0)||function a(){return!1}},5656:(o,s,r)=>{"use strict";r.d(s,{A:()=>S});var i=r(5688),a=r(7999);const S=function T(M){if(!(0,a.A)(M))return!1;var O=(0,i.A)(M);return"[object Function]"==O||"[object GeneratorFunction]"==O||"[object AsyncFunction]"==O||"[object Proxy]"==O}},4184:(o,s,r)=>{"use strict";r.d(s,{A:()=>c});const c=function a(y){return"number"==typeof y&&y>-1&&y%1==0&&y<=9007199254740991}},7999:(o,s,r)=>{"use strict";r.d(s,{A:()=>a});const a=function i(c){var y=typeof c;return null!=c&&("object"==y||"function"==y)}},2312:(o,s,r)=>{"use strict";r.d(s,{A:()=>a});const a=function i(c){return null!=c&&"object"==typeof c}},766:(o,s,r)=>{"use strict";r.d(s,{A:()=>yn});var i=r(5688),a=r(4184),c=r(2312),dt={};dt["[object Float32Array]"]=dt["[object Float64Array]"]=dt["[object Int8Array]"]=dt["[object Int16Array]"]=dt["[object Int32Array]"]=dt["[object Uint8Array]"]=dt["[object Uint8ClampedArray]"]=dt["[object Uint16Array]"]=dt["[object Uint32Array]"]=!0,dt["[object Arguments]"]=dt["[object Array]"]=dt["[object ArrayBuffer]"]=dt["[object Boolean]"]=dt["[object DataView]"]=dt["[object Date]"]=dt["[object Error]"]=dt["[object Function]"]=dt["[object Map]"]=dt["[object Number]"]=dt["[object Object]"]=dt["[object RegExp]"]=dt["[object Set]"]=dt["[object String]"]=dt["[object WeakMap]"]=!1;var rn=r(4975),gn=r(8583),bn=gn.A&&gn.A.isTypedArray;const yn=bn?(0,rn.A)(bn):function bt(qe){return(0,c.A)(qe)&&(0,a.A)(qe.length)&&!!dt[(0,i.A)(qe)]}},3959:(o,s,r)=>{"use strict";r.d(s,{A:()=>Z});var i=r(6259),a=r(7999),c=r(1561);var T=Object.prototype.hasOwnProperty;const M=function S(q){if(!(0,a.A)(q))return function y(q){var re=[];if(null!=q)for(var pe in Object(q))re.push(pe);return re}(q);var re=(0,c.A)(q),pe=[];for(var se in q)"constructor"==se&&(re||!T.call(q,se))||pe.push(se);return pe};var O=r(2808);const Z=function L(q){return(0,O.A)(q)?(0,i.A)(q,!0):M(q)}},4819:(o,s,r)=>{"use strict";r.d(s,{A:()=>Tn});var i=r(1238),a=r(8758),c=r(2486);const w=function y(an,dn,In){(void 0!==In&&!(0,c.A)(an[dn],In)||void 0===In&&!(dn in an))&&(0,a.A)(an,dn,In)},M=function C(an){return function(dn,In,sr){for(var xn=-1,Hr=Object(dn),Tr=sr(dn),Vr=Tr.length;Vr--;){var vt=Tr[an?Vr:++xn];if(!1===In(Hr[vt],vt,Hr))break}return dn}}();var O=r(4224),L=r(7383),Z=r(1369),q=r(223),re=r(1656),pe=r(9007),se=r(2808),ae=r(2312);var Oe=r(5303),xe=r(5656),De=r(7999),ce=r(5688),ue=r(5749),dt=Function.prototype.toString,bt=Object.prototype.hasOwnProperty,lt=dt.call(Object);var bn=r(766);const yn=function Vn(an,dn){if(("constructor"!==dn||"function"!=typeof an[dn])&&"__proto__"!=dn)return an[dn]};var qe=r(101),_t=r(3959);const Ke=function Ft(an,dn,In,sr,xn,Hr,Tr){var Vr=yn(an,In),vt=yn(dn,In),Wt=Tr.get(vt);if(Wt)w(an,In,Wt);else{var Re=Hr?Hr(Vr,vt,In+"",an,dn,Tr):void 0,Ge=void 0===Re;if(Ge){var Ve=(0,pe.A)(vt),Dt=!Ve&&(0,Oe.A)(vt),ct=!Ve&&!Dt&&(0,bn.A)(vt);Re=vt,Ve||Dt||ct?(0,pe.A)(Vr)?Re=Vr:function me(an){return(0,ae.A)(an)&&(0,se.A)(an)}(Vr)?Re=(0,Z.A)(Vr):Dt?(Ge=!1,Re=(0,O.A)(vt,!0)):ct?(Ge=!1,Re=(0,L.A)(vt,!0)):Re=[]:function rn(an){if(!(0,ae.A)(an)||"[object Object]"!=(0,ce.A)(an))return!1;var dn=(0,ue.A)(an);if(null===dn)return!0;var In=bt.call(dn,"constructor")&&dn.constructor;return"function"==typeof In&&In instanceof In&&dt.call(In)==lt}(vt)||(0,re.A)(vt)?(Re=Vr,(0,re.A)(Vr)?Re=function ze(an){return(0,qe.A)(an,(0,_t.A)(an))}(Vr):(!(0,De.A)(Vr)||(0,xe.A)(Vr))&&(Re=(0,q.A)(vt))):Ge=!1}Ge&&(Tr.set(vt,Re),xn(Re,vt,sr,Hr,Tr),Tr.delete(vt)),w(an,In,Re)}},it=function Ze(an,dn,In,sr,xn){an!==dn&&M(dn,function(Hr,Tr){if(xn||(xn=new i.A),(0,De.A)(Hr))Ke(an,dn,Tr,In,Ze,sr,xn);else{var Vr=sr?sr(yn(an,Tr),Hr,Tr+"",an,dn,xn):void 0;void 0===Vr&&(Vr=Hr),w(an,Tr,Vr)}},_t.A)},$t=function Ot(an){return an};var st=Math.max;const rt=function Kt(an){return function(){return an}};var Vt=r(4133),Rn=Date.now;const ke=function pr(an){var dn=0,In=0;return function(){var sr=Rn(),xn=16-(sr-In);if(In=sr,xn>0){if(++dn>=800)return arguments[0]}else dn=0;return an.apply(void 0,arguments)}}(Vt.A?function(an,dn){return(0,Vt.A)(an,"toString",{configurable:!0,enumerable:!1,value:rt(dn),writable:!0})}:$t),z=function Je(an,dn){return ke(function Xt(an,dn,In){return dn=st(void 0===dn?an.length-1:dn,0),function(){for(var sr=arguments,xn=-1,Hr=st(sr.length-dn,0),Tr=Array(Hr);++xn1?In[xn-1]:void 0,Tr=xn>2?In[2]:void 0;for(Hr=an.length>3&&"function"==typeof Hr?(xn--,Hr):void 0,Tr&&function W(an,dn,In){if(!(0,De.A)(In))return!1;var sr=typeof dn;return!!("number"==sr?(0,se.A)(In)&&(0,N.A)(dn,In.length):"string"==sr&&dn in In)&&(0,c.A)(In[dn],an)}(In[0],In[1],Tr)&&(Hr=xn<3?void 0:Hr,xn=1),dn=Object(dn);++sr{"use strict";__webpack_require__.d(__webpack_exports__,{Ts:()=>init,ql:()=>launch});var _home_runner_work_angor_hub_angor_hub_node_modules_angular_builders_custom_webpack_node_modules_babel_runtime_helpers_esm_asyncToGenerator_js__WEBPACK_IMPORTED_MODULE_1__=__webpack_require__(3014),_home_runner_work_angor_hub_angor_hub_node_modules_angular_builders_custom_webpack_node_modules_babel_runtime_helpers_esm_awaitAsyncGenerator_js__WEBPACK_IMPORTED_MODULE_2__=__webpack_require__(5137),_home_runner_work_angor_hub_angor_hub_node_modules_angular_builders_custom_webpack_node_modules_babel_runtime_helpers_esm_wrapAsyncGenerator_js__WEBPACK_IMPORTED_MODULE_0__=__webpack_require__(9129),BUILD={allRenderFn:!1,cmpDidLoad:!0,cmpDidUnload:!1,cmpDidUpdate:!0,cmpDidRender:!0,cmpWillLoad:!0,cmpWillUpdate:!0,cmpWillRender:!0,connectedCallback:!0,disconnectedCallback:!0,element:!0,event:!0,hasRenderFn:!0,lifecycle:!0,hostListener:!0,hostListenerTargetWindow:!0,hostListenerTargetDocument:!0,hostListenerTargetBody:!0,hostListenerTargetParent:!1,hostListenerTarget:!0,member:!0,method:!0,mode:!0,observeAttribute:!0,prop:!0,propMutable:!0,reflect:!0,scoped:!0,shadowDom:!0,slot:!0,cssAnnotations:!0,state:!0,style:!0,formAssociated:!1,svg:!0,updatable:!0,vdomAttribute:!0,vdomXlink:!0,vdomClass:!0,vdomFunctional:!0,vdomKey:!0,vdomListener:!0,vdomRef:!0,vdomPropOrAttr:!0,vdomRender:!0,vdomStyle:!0,vdomText:!0,watchCallback:!0,taskQueue:!0,hotModuleReplacement:!1,isDebug:!1,isDev:!1,isTesting:!1,hydrateServerSide:!1,hydrateClientSide:!1,lifecycleDOMEvents:!1,lazyLoad:!1,profile:!1,slotRelocation:!0,appendChildSlotFix:!1,cloneNodeFix:!1,hydratedAttribute:!1,hydratedClass:!0,scriptDataOpts:!1,scopedSlotTextContentFix:!1,shadowDomShim:!1,slotChildNodesFix:!1,invisiblePrehydration:!0,propBoolean:!0,propNumber:!0,propString:!0,constructableCSS:!0,cmpShouldUpdate:!0,devTools:!1,shadowDelegatesFocus:!0,initializeNextTick:!1,asyncLoading:!1,asyncQueue:!1,transformTagName:!1,attachStyles:!0,experimentalSlotFixes:!1},__defProp$1=Object.defineProperty,__export$1=(o,s)=>{for(var r in s)__defProp$1(o,r,{get:s[r],enumerable:!0})},hostRefs=new WeakMap,getHostRef=o=>hostRefs.get(o),registerHost=(o,s)=>hostRefs.set(o,{$flags$:0,$hostElement$:o,$cmpMeta$:s,$instanceValues$:new Map}),isMemberInElement=(o,s)=>s in o,consoleError=(o,s)=>(0,console.error)(o,s),styles=new Map,modeResolutionChain=[],SLOT_FB_CSS="slot-fb{display:contents}slot-fb[hidden]{display:none}",XLINK_NS="http://www.w3.org/1999/xlink",win=typeof window<"u"?window:{},doc=win.document||{head:{}},H=win.HTMLElement||class{},plt={$flags$:0,$resourcesUrl$:"",jmp:o=>o(),raf:o=>requestAnimationFrame(o),ael:(o,s,r,i)=>o.addEventListener(s,r,i),rel:(o,s,r,i)=>o.removeEventListener(s,r,i),ce:(o,s)=>new CustomEvent(o,s)},supportsListenerOptions=(()=>{let o=!1;try{doc.addEventListener("e",null,Object.defineProperty({},"passive",{get(){o=!0}}))}catch{}return o})(),promiseResolve=o=>Promise.resolve(o),supportsConstructableStylesheets=(()=>{try{return new CSSStyleSheet,"function"==typeof(new CSSStyleSheet).replaceSync}catch{}return!1})(),queuePending=!1,queueDomReads=[],queueDomWrites=[],queueTask=(o,s)=>r=>{o.push(r),queuePending||(queuePending=!0,s&&4&plt.$flags$?nextTick(flush):plt.raf(flush))},consume=o=>{for(let s=0;s{consume(queueDomReads),consume(queueDomWrites),(queuePending=queueDomReads.length>0)&&plt.raf(flush)},nextTick=o=>promiseResolve().then(o),writeTask=queueTask(queueDomWrites,!0),EMPTY_OBJ={},SVG_NS="http://www.w3.org/2000/svg",HTML_NS="http://www.w3.org/1999/xhtml",isDef=o=>null!=o,isComplexType=o=>"object"==(o=typeof o)||"function"===o;function queryNonceMetaTagContent(o){var s,r,i;return null!=(i=null==(r=null==(s=o.head)?void 0:s.querySelector('meta[name="csp-nonce"]'))?void 0:r.getAttribute("content"))?i:void 0}var result_exports={};__export$1(result_exports,{err:()=>err,map:()=>map,ok:()=>ok,unwrap:()=>unwrap$1,unwrapErr:()=>unwrapErr});var ok=o=>({isOk:!0,isErr:!1,value:o}),err=o=>({isOk:!1,isErr:!0,value:o});function map(o,s){if(o.isOk){const r=s(o.value);return r instanceof Promise?r.then(i=>ok(i)):ok(r)}if(o.isErr)return err(o.value);throw"should never get here"}var unwrap$1=o=>{if(o.isOk)return o.value;throw o.value},unwrapErr=o=>{if(o.isErr)return o.value;throw o.value},createTime=(o,s="")=>()=>{},h=(o,s,...r)=>{let i=null,a=null,c=null,y=!1,w=!1;const C=[],T=M=>{for(let O=0;OM[O]).join(" "))}}if("function"==typeof o)return o(null===s?{}:s,C,vdomFnUtils);const S=newVNode(o,null);return S.$attrs$=s,C.length>0&&(S.$children$=C),S.$key$=a,S.$name$=c,S},newVNode=(o,s)=>({$flags$:0,$tag$:o,$text$:s,$elm$:null,$children$:null,$attrs$:null,$key$:null,$name$:null}),Host={},isHost=o=>o&&o.$tag$===Host,vdomFnUtils={forEach:(o,s)=>o.map(convertToPublic).forEach(s),map:(o,s)=>o.map(convertToPublic).map(s).map(convertToPrivate)},convertToPublic=o=>({vattrs:o.$attrs$,vchildren:o.$children$,vkey:o.$key$,vname:o.$name$,vtag:o.$tag$,vtext:o.$text$}),convertToPrivate=o=>{if("function"==typeof o.vtag){const r={...o.vattrs};return o.vkey&&(r.key=o.vkey),o.vname&&(r.name=o.vname),h(o.vtag,r,...o.vchildren||[])}const s=newVNode(o.vtag,o.vtext);return s.$attrs$=o.vattrs,s.$children$=o.vchildren,s.$key$=o.vkey,s.$name$=o.vname,s},computeMode=o=>modeResolutionChain.map(s=>s(o)).find(s=>!!s),parsePropertyValue=(o,s)=>null==o||isComplexType(o)?o:4&s?"false"!==o&&(""===o||!!o):2&s?parseFloat(o):1&s?String(o):o,getElement=o=>o,createEvent=(o,s,r)=>{const i=getElement(o);return{emit:a=>emitEvent(i,s,{bubbles:!!(4&r),composed:!!(2&r),cancelable:!!(1&r),detail:a})}},emitEvent=(o,s,r)=>{const i=plt.ce(s,r);return o.dispatchEvent(i),i},rootAppliedStyles=new WeakMap,registerStyle=(o,s,r)=>{let i=styles.get(o);supportsConstructableStylesheets&&r?(i=i||new CSSStyleSheet,"string"==typeof i?i=s:i.replaceSync(s)):i=s,styles.set(o,i)},addStyle=(o,s,r)=>{var i;const a=getScopeId(s,r),c=styles.get(a);if(o=11===o.nodeType?o:doc,c)if("string"==typeof c){let y,w=rootAppliedStyles.get(o=o.head||o);if(w||rootAppliedStyles.set(o,w=new Set),!w.has(a)){{y=doc.createElement("style"),y.innerHTML=c;const C=null!=(i=plt.$nonce$)?i:queryNonceMetaTagContent(doc);null!=C&&y.setAttribute("nonce",C),(!(1&s.$flags$)||1&s.$flags$&&"HEAD"!==o.nodeName)&&o.insertBefore(y,o.querySelector("link"))}4&s.$flags$&&(y.innerHTML+=SLOT_FB_CSS),w&&w.add(a)}}else o.adoptedStyleSheets.includes(c)||(o.adoptedStyleSheets=[...o.adoptedStyleSheets,c]);return a},attachStyles=o=>{const s=o.$cmpMeta$,r=o.$hostElement$,i=s.$flags$,a=createTime("attachStyles",s.$tagName$),c=addStyle(r.shadowRoot?r.shadowRoot:r.getRootNode(),s,o.$modeName$);10&i&&2&i&&(r["s-sc"]=c,r.classList.add(c+"-h"),2&i&&r.classList.add(c+"-s")),a()},getScopeId=(o,s)=>"sc-"+(s&&32&o.$flags$?o.$tagName$+"-"+s:o.$tagName$),setAccessor=(o,s,r,i,a,c)=>{if(r!==i){let y=isMemberInElement(o,s),w=s.toLowerCase();if("class"===s){const C=o.classList,T=parseClassList(r),S=parseClassList(i);C.remove(...T.filter(M=>M&&!S.includes(M))),C.add(...S.filter(M=>M&&!T.includes(M)))}else if("style"===s){for(const C in r)i&&null!=i[C]||(C.includes("-")?o.style.removeProperty(C):o.style[C]="");for(const C in i)r&&i[C]===r[C]||(C.includes("-")?o.style.setProperty(C,i[C]):o.style[C]=i[C])}else if("key"!==s)if("ref"===s)i&&i(o);else if(o.__lookupSetter__(s)||"o"!==s[0]||"n"!==s[1]){const C=isComplexType(i);if((y||C&&null!==i)&&!a)try{if(o.tagName.includes("-"))o[s]=i;else{const S=i??"";"list"===s?y=!1:null!=r&&o[s]==S||(o[s]=S)}}catch{}let T=!1;w!==(w=w.replace(/^xlink\:?/,""))&&(s=w,T=!0),null==i||!1===i?!1===i&&""!==o.getAttribute(s)||(T?o.removeAttributeNS(XLINK_NS,s):o.removeAttribute(s)):(!y||4&c||a)&&!C&&(i=!0===i?"":i,T?o.setAttributeNS(XLINK_NS,s,i):o.setAttribute(s,i))}else if(s="-"===s[2]?s.slice(3):isMemberInElement(win,w)?w.slice(2):w[2]+s.slice(3),r||i){const C=s.endsWith(CAPTURE_EVENT_SUFFIX);s=s.replace(CAPTURE_EVENT_REGEX,""),r&&plt.rel(o,s,r,C),i&&plt.ael(o,s,i,C)}}},parseClassListRegex=/\s/,parseClassList=o=>o?o.split(parseClassListRegex):[],CAPTURE_EVENT_SUFFIX="Capture",CAPTURE_EVENT_REGEX=new RegExp(CAPTURE_EVENT_SUFFIX+"$"),updateElement=(o,s,r)=>{const i=11===s.$elm$.nodeType&&s.$elm$.host?s.$elm$.host:s.$elm$,a=o&&o.$attrs$||EMPTY_OBJ,c=s.$attrs$||EMPTY_OBJ;for(const y of sortedAttrNames(Object.keys(a)))y in c||setAccessor(i,y,a[y],void 0,r,s.$flags$);for(const y of sortedAttrNames(Object.keys(c)))setAccessor(i,y,a[y],c[y],r,s.$flags$)},scopeId,contentRef,hostTagName;function sortedAttrNames(o){return o.includes("ref")?[...o.filter(s=>"ref"!==s),"ref"]:o}var useNativeShadowDom=!1,checkSlotFallbackVisibility=!1,checkSlotRelocate=!1,isSvgMode=!1,createElm=(o,s,r,i)=>{var a;const c=s.$children$[r];let y,w,C,T=0;if(useNativeShadowDom||(checkSlotRelocate=!0,"slot"===c.$tag$&&(scopeId&&i.classList.add(scopeId+"-s"),c.$flags$|=c.$children$?2:1)),null!==c.$text$)y=c.$elm$=doc.createTextNode(c.$text$);else if(1&c.$flags$)y=c.$elm$=doc.createTextNode("");else{if(isSvgMode||(isSvgMode="svg"===c.$tag$),y=c.$elm$=doc.createElementNS(isSvgMode?SVG_NS:HTML_NS,!useNativeShadowDom&&BUILD.slotRelocation&&2&c.$flags$?"slot-fb":c.$tag$),isSvgMode&&"foreignObject"===c.$tag$&&(isSvgMode=!1),updateElement(null,c,isSvgMode),y.getRootNode().querySelector("body")&&BUILD.scoped&&isDef(scopeId)&&y["s-si"]!==scopeId&&y.classList.add(y["s-si"]=scopeId),updateElementScopeIds(y,i),c.$children$)for(T=0;T{plt.$flags$|=1;const r=Array.from(o.childNodes);if(o["s-sr"]&&BUILD.experimentalSlotFixes){let i=o;for(;i=i.nextSibling;)i&&i["s-sn"]===o["s-sn"]&&i["s-sh"]===hostTagName&&r.push(i)}for(let i=r.length-1;i>=0;i--){const a=r[i];a["s-hn"]!==hostTagName&&a["s-ol"]&&(insertBefore(parentReferenceNode(a),a,referenceNode(a)),a["s-ol"].remove(),a["s-ol"]=void 0,a["s-sh"]=void 0,checkSlotRelocate=!0),s&&putBackInOriginalLocation(a,s)}plt.$flags$&=-2},addVnodes=(o,s,r,i,a,c)=>{let y,w=o["s-cr"]&&o["s-cr"].parentNode||o;for(w.shadowRoot&&w.tagName===hostTagName&&(w=w.shadowRoot);a<=c;++a)i[a]&&(y=createElm(null,r,a,o),y&&(i[a].$elm$=y,insertBefore(w,y,referenceNode(s))))},removeVnodes=(o,s,r)=>{for(let i=s;i<=r;++i){const a=o[i];if(a){const c=a.$elm$;nullifyVNodeRefs(a),c&&(checkSlotFallbackVisibility=!0,c["s-ol"]?c["s-ol"].remove():putBackInOriginalLocation(c,!0),c.remove())}}},updateChildren=(o,s,r,i,a=!1)=>{let c,y,w=0,C=0,T=0,S=0,M=s.length-1,O=s[0],L=s[M],Z=i.length-1,q=i[0],re=i[Z];for(;w<=M&&C<=Z;)if(null==O)O=s[++w];else if(null==L)L=s[--M];else if(null==q)q=i[++C];else if(null==re)re=i[--Z];else if(isSameVnode(O,q,a))patch(O,q,a),O=s[++w],q=i[++C];else if(isSameVnode(L,re,a))patch(L,re,a),L=s[--M],re=i[--Z];else if(isSameVnode(O,re,a))"slot"!==O.$tag$&&"slot"!==re.$tag$||putBackInOriginalLocation(O.$elm$.parentNode,!1),patch(O,re,a),insertBefore(o,O.$elm$,L.$elm$.nextSibling),O=s[++w],re=i[--Z];else if(isSameVnode(L,q,a))"slot"!==O.$tag$&&"slot"!==re.$tag$||putBackInOriginalLocation(L.$elm$.parentNode,!1),patch(L,q,a),insertBefore(o,L.$elm$,O.$elm$),L=s[--M],q=i[++C];else{for(T=-1,S=w;S<=M;++S)if(s[S]&&null!==s[S].$key$&&s[S].$key$===q.$key$){T=S;break}T>=0?(y=s[T],y.$tag$!==q.$tag$?c=createElm(s&&s[C],r,T,o):(patch(y,q,a),s[T]=void 0,c=y.$elm$),q=i[++C]):(c=createElm(s&&s[C],r,C,o),q=i[++C]),c&&insertBefore(parentReferenceNode(O.$elm$),c,referenceNode(O.$elm$))}w>M?addVnodes(o,null==i[Z+1]?null:i[Z+1].$elm$,r,i,C,Z):C>Z&&removeVnodes(s,w,M)},isSameVnode=(o,s,r=!1)=>!(o.$tag$!==s.$tag$||("slot"===o.$tag$?"$nodeId$"in o&&r&&8!==o.$elm$.nodeType||o.$name$!==s.$name$:!r&&o.$key$!==s.$key$)),referenceNode=o=>o&&o["s-ol"]||o,parentReferenceNode=o=>(o["s-ol"]?o["s-ol"]:o).parentNode,patch=(o,s,r=!1)=>{const i=s.$elm$=o.$elm$,a=o.$children$,c=s.$children$,y=s.$tag$,w=s.$text$;let C;null===w?(isSvgMode="svg"===y||"foreignObject"!==y&&isSvgMode,("slot"!==y||useNativeShadowDom)&&updateElement(o,s,isSvgMode),null!==a&&null!==c?updateChildren(i,a,s,c,r):null!==c?(null!==o.$text$&&(i.textContent=""),addVnodes(i,null,s,c,0,c.length-1)):!r&&BUILD.updatable&&null!==a&&removeVnodes(a,0,a.length-1),isSvgMode&&"svg"===y&&(isSvgMode=!1)):(C=i["s-cr"])?C.parentNode.textContent=w:o.$text$!==w&&(i.data=w)},updateFallbackSlotVisibility=o=>{const s=o.childNodes;for(const r of s)if(1===r.nodeType){if(r["s-sr"]){const i=r["s-sn"];r.hidden=!1;for(const a of s)if(a!==r)if(a["s-hn"]!==r["s-hn"]||""!==i){if(1===a.nodeType&&(i===a.getAttribute("slot")||i===a["s-sn"])||3===a.nodeType&&i===a["s-sn"]){r.hidden=!0;break}}else if(1===a.nodeType||3===a.nodeType&&""!==a.textContent.trim()){r.hidden=!0;break}}updateFallbackSlotVisibility(r)}},relocateNodes=[],markSlotContentForRelocation=o=>{let s,r,i;for(const a of o.childNodes){if(a["s-sr"]&&(s=a["s-cr"])&&s.parentNode){r=s.parentNode.childNodes;const c=a["s-sn"];for(i=r.length-1;i>=0;i--)if(s=r[i],!s["s-cn"]&&!s["s-nr"]&&s["s-hn"]!==a["s-hn"]&&!BUILD.experimentalSlotFixes)if(isNodeLocatedInSlot(s,c)){let y=relocateNodes.find(w=>w.$nodeToRelocate$===s);checkSlotFallbackVisibility=!0,s["s-sn"]=s["s-sn"]||c,y?(y.$nodeToRelocate$["s-sh"]=a["s-hn"],y.$slotRefNode$=a):(s["s-sh"]=a["s-hn"],relocateNodes.push({$slotRefNode$:a,$nodeToRelocate$:s})),s["s-sr"]&&relocateNodes.map(w=>{isNodeLocatedInSlot(w.$nodeToRelocate$,s["s-sn"])&&(y=relocateNodes.find(C=>C.$nodeToRelocate$===s),y&&!w.$slotRefNode$&&(w.$slotRefNode$=y.$slotRefNode$))})}else relocateNodes.some(y=>y.$nodeToRelocate$===s)||relocateNodes.push({$nodeToRelocate$:s})}1===a.nodeType&&markSlotContentForRelocation(a)}},isNodeLocatedInSlot=(o,s)=>1===o.nodeType?null===o.getAttribute("slot")&&""===s||o.getAttribute("slot")===s:o["s-sn"]===s||""===s,nullifyVNodeRefs=o=>{o.$attrs$&&o.$attrs$.ref&&o.$attrs$.ref(null),o.$children$&&o.$children$.map(nullifyVNodeRefs)},insertBefore=(o,s,r)=>{const i=o?.insertBefore(s,r);return updateElementScopeIds(s,o),i},findScopeIds=o=>{const s=[];return o&&s.push(...o["s-scs"]||[],o["s-si"],o["s-sc"],...findScopeIds(o.parentElement)),s},updateElementScopeIds=(o,s,r=!1)=>{var i;if(o&&s&&1===o.nodeType){const a=new Set(findScopeIds(s).filter(Boolean));if(a.size&&(null==(i=o.classList)||i.add(...o["s-scs"]=[...a]),o["s-ol"]||r))for(const c of Array.from(o.childNodes))updateElementScopeIds(c,o,!0)}},renderVdom=(o,s,r=!1)=>{var i,a,c,y,w;const C=o.$hostElement$,T=o.$cmpMeta$,S=o.$vnode$||newVNode(null,null),M=isHost(s)?s:h(null,null,s);if(hostTagName=C.tagName,T.$attrsToReflect$&&(M.$attrs$=M.$attrs$||{},T.$attrsToReflect$.map(([O,L])=>M.$attrs$[L]=C[O])),r&&M.$attrs$)for(const O of Object.keys(M.$attrs$))C.hasAttribute(O)&&!["key","ref","style","class"].includes(O)&&(M.$attrs$[O]=C[O]);if(M.$tag$=null,M.$flags$|=4,o.$vnode$=M,M.$elm$=S.$elm$=C.shadowRoot||C,scopeId=C["s-sc"],useNativeShadowDom=!!(1&T.$flags$),contentRef=C["s-cr"],checkSlotFallbackVisibility=!1,patch(S,M,r),plt.$flags$|=1,checkSlotRelocate){markSlotContentForRelocation(M.$elm$);for(const O of relocateNodes){const L=O.$nodeToRelocate$;if(!L["s-ol"]){const Z=doc.createTextNode("");Z["s-nr"]=L,insertBefore(L.parentNode,L["s-ol"]=Z,L)}}for(const O of relocateNodes){const L=O.$nodeToRelocate$,Z=O.$slotRefNode$;if(Z){const q=Z.parentNode;let re=Z.nextSibling;{let pe=null==(i=L["s-ol"])?void 0:i.previousSibling;for(;pe;){let se=null!=(a=pe["s-nr"])?a:null;if(se&&se["s-sn"]===L["s-sn"]&&q===se.parentNode){for(se=se.nextSibling;se===L||se?.["s-sr"];)se=se?.nextSibling;if(!se||!se["s-nr"]){re=se;break}}pe=pe.previousSibling}}(!re&&q!==L.parentNode||L.nextSibling!==re)&&L!==re&&(!L["s-hn"]&&L["s-ol"]&&(L["s-hn"]=L["s-ol"].parentNode.nodeName),insertBefore(q,L,re),1===L.nodeType&&(L.hidden=null!=(c=L["s-ih"])&&c)),L&&"function"==typeof Z["s-rf"]&&Z["s-rf"](L)}else 1===L.nodeType&&(r&&(L["s-ih"]=null!=(y=L.hidden)&&y),L.hidden=!0)}}if(checkSlotFallbackVisibility&&updateFallbackSlotVisibility(M.$elm$),plt.$flags$&=-2,relocateNodes.length=0,BUILD.experimentalScopedSlotChanges&&2&T.$flags$)for(const O of M.$elm$.childNodes)O["s-hn"]===hostTagName||O["s-sh"]||(r&&null==O["s-ih"]&&(O["s-ih"]=null!=(w=O.hidden)&&w),O.hidden=!0);contentRef=void 0},attachToAncestor=(o,s)=>{},scheduleUpdate=(o,s)=>(o.$flags$|=16,attachToAncestor(o,o.$ancestorComponent$),writeTask(()=>dispatchHooks(o,s))),dispatchHooks=(o,s)=>{const r=o.$hostElement$,i=createTime("scheduleUpdate",o.$cmpMeta$.$tagName$),a=r;if(!a)throw new Error(`Can't render component <${r.tagName.toLowerCase()} /> with invalid Stencil runtime! Make sure this imported component is compiled with a \`externalRuntime: true\` flag. For more information, please refer to https://stenciljs.com/docs/custom-elements#externalruntime`);let c;return c=safeCall(a,s?"componentWillLoad":"componentWillUpdate"),c=enqueue(c,()=>safeCall(a,"componentWillRender")),i(),enqueue(c,()=>updateComponent(o,a,s))},enqueue=(o,s)=>isPromisey(o)?o.then(s).catch(r=>{console.error(r),s()}):s(),isPromisey=o=>o instanceof Promise||o&&o.then&&"function"==typeof o.then,updateComponent=function(){var o=(0,_home_runner_work_angor_hub_angor_hub_node_modules_angular_builders_custom_webpack_node_modules_babel_runtime_helpers_esm_asyncToGenerator_js__WEBPACK_IMPORTED_MODULE_1__.A)(function*(s,r,i){const a=s.$hostElement$,c=createTime("update",s.$cmpMeta$.$tagName$);i&&attachStyles(s);const y=createTime("render",s.$cmpMeta$.$tagName$);callRender(s,r,a,i),y(),c(),postUpdateComponent(s)});return function(r,i,a){return o.apply(this,arguments)}}(),renderingRef=null,callRender=(o,s,r,i)=>{try{renderingRef=s,s=s.render&&s.render(),o.$flags$&=-17,o.$flags$|=2,(BUILD.hasRenderFn||BUILD.reflect)&&(BUILD.vdomRender||BUILD.reflect)&&(BUILD.hydrateServerSide||renderVdom(o,s,i))}catch(a){consoleError(a,o.$hostElement$)}return renderingRef=null,null},getRenderingRef=()=>renderingRef,postUpdateComponent=o=>{const r=o.$hostElement$,i=createTime("postUpdate",o.$cmpMeta$.$tagName$),a=r;safeCall(a,"componentDidRender"),64&o.$flags$?(safeCall(a,"componentDidUpdate"),i()):(o.$flags$|=64,safeCall(a,"componentDidLoad"),i())},forceUpdate=o=>{{const s=getHostRef(o),r=s.$hostElement$.isConnected;return r&&2==(18&s.$flags$)&&scheduleUpdate(s,!1),r}},safeCall=(o,s,r)=>{if(o&&o[s])try{return o[s](r)}catch(i){consoleError(i)}},getValue=(o,s)=>getHostRef(o).$instanceValues$.get(s),setValue=(o,s,r,i)=>{const a=getHostRef(o),c=o,y=a.$instanceValues$.get(s),w=a.$flags$,C=c;r=parsePropertyValue(r,i.$members$[s][0]);const T=Number.isNaN(y)&&Number.isNaN(r);if(r!==y&&!T){if(a.$instanceValues$.set(s,r),i.$watchers$&&128&w){const S=i.$watchers$[s];S&&S.map(M=>{try{C[M](r,y,s)}catch(O){consoleError(O,c)}})}if(2==(18&w)){if(C.componentShouldUpdate&&!1===C.componentShouldUpdate(r,y,s))return;scheduleUpdate(a,!1)}}},proxyComponent=(o,s,r)=>{var i,a;const c=o.prototype;if(s.$members$||s.$watchers$||o.watchers){o.watchers&&!s.$watchers$&&(s.$watchers$=o.watchers);const y=Object.entries(null!=(i=s.$members$)?i:{});y.map(([w,[C]])=>{(31&C||32&C)&&Object.defineProperty(c,w,{get(){return getValue(this,w)},set(T){setValue(this,w,T,s)},configurable:!0,enumerable:!0})});{const w=new Map;c.attributeChangedCallback=function(C,T,S){plt.jmp(()=>{var M;const O=w.get(C);if(this.hasOwnProperty(O))S=this[O],delete this[O];else{if(c.hasOwnProperty(O)&&"number"==typeof this[O]&&this[O]==S)return;if(null==O){const L=getHostRef(this),Z=L?.$flags$;if(Z&&!(8&Z)&&128&Z&&S!==T){const q=this,re=null==(M=s.$watchers$)?void 0:M[C];re?.forEach(pe=>{null!=q[pe]&&q[pe].call(q,S,T,C)})}return}}this[O]=(null!==S||"boolean"!=typeof this[O])&&S})},o.observedAttributes=Array.from(new Set([...Object.keys(null!=(a=s.$watchers$)?a:{}),...y.filter(([C,T])=>15&T[0]).map(([C,T])=>{var S;const M=T[1]||C;return w.set(M,C),512&T[0]&&(null==(S=s.$attrsToReflect$)||S.push([C,M])),M})]))}}return o},initializeComponent=function(){var o=(0,_home_runner_work_angor_hub_angor_hub_node_modules_angular_builders_custom_webpack_node_modules_babel_runtime_helpers_esm_asyncToGenerator_js__WEBPACK_IMPORTED_MODULE_1__.A)(function*(s,r,i,a){let c;if(!(32&r.$flags$)&&(r.$flags$|=32,c=s.constructor,customElements.whenDefined(s.localName).then(()=>r.$flags$|=128),c&&c.style)){let y;"string"==typeof c.style?y=c.style:"string"!=typeof c.style&&(r.$modeName$=computeMode(s),r.$modeName$&&(y=c.style[r.$modeName$]));const w=getScopeId(i,r.$modeName$);if(!styles.has(w)){const C=createTime("registerStyles",i.$tagName$);registerStyle(w,y,!!(1&i.$flags$)),C()}}scheduleUpdate(r,!0)});return function(r,i,a,c){return o.apply(this,arguments)}}(),fireConnectedCallback=o=>{},connectedCallback=o=>{if(!(1&plt.$flags$)){const s=getHostRef(o),r=s.$cmpMeta$,i=createTime("connectedCallback",r.$tagName$);1&s.$flags$?(addHostEventListeners(o,s,r.$listeners$),s?.$lazyInstance$?fireConnectedCallback(s.$lazyInstance$):s?.$onReadyPromise$&&s.$onReadyPromise$.then(()=>fireConnectedCallback(s.$lazyInstance$))):(s.$flags$|=1,12&r.$flags$&&setContentReference(o),r.$members$&&Object.entries(r.$members$).map(([a,[c]])=>{if(31&c&&o.hasOwnProperty(a)){const y=o[a];delete o[a],o[a]=y}}),initializeComponent(o,s,r)),i()}},setContentReference=o=>{const s=o["s-cr"]=doc.createComment("");s["s-cn"]=!0,insertBefore(o,s,o.firstChild)},disconnectedCallback=function(){var o=(0,_home_runner_work_angor_hub_angor_hub_node_modules_angular_builders_custom_webpack_node_modules_babel_runtime_helpers_esm_asyncToGenerator_js__WEBPACK_IMPORTED_MODULE_1__.A)(function*(s){if(!(1&plt.$flags$)){const r=getHostRef(s);r.$rmListeners$&&(r.$rmListeners$.map(i=>i()),r.$rmListeners$=void 0)}});return function(r){return o.apply(this,arguments)}}(),proxyCustomElement=(o,s)=>{const r={$flags$:s[0],$tagName$:s[1]};r.$members$=s[2],r.$listeners$=s[3],r.$watchers$=o.$watchers$,r.$attrsToReflect$=[];const i=o.prototype.connectedCallback,a=o.prototype.disconnectedCallback;return Object.assign(o.prototype,{__registerHost(){registerHost(this,r)},connectedCallback(){const c=getHostRef(this);addHostEventListeners(this,c,r.$listeners$),connectedCallback(this),i&&i.call(this)},disconnectedCallback(){disconnectedCallback(this),a&&a.call(this)},__attachShadow(){if(this.shadowRoot){if("open"!==this.shadowRoot.mode)throw new Error(`Unable to re-use existing shadow root for ${r.$tagName$}! Mode is set to ${this.shadowRoot.mode} but Stencil only supports open shadow roots.`)}else this.attachShadow({mode:"open",delegatesFocus:!!(16&r.$flags$)})}}),o.is=r.$tagName$,proxyComponent(o,r)},Fragment=(o,s)=>s,addHostEventListeners=(o,s,r,i)=>{r&&r.map(([a,c,y])=>{const w=getHostListenerTarget(o,a),C=hostListenerProxy(s,y),T=hostListenerOpts(a);plt.ael(w,c,C,T),(s.$rmListeners$=s.$rmListeners$||[]).push(()=>plt.rel(w,c,C,T))})},hostListenerProxy=(o,s)=>r=>{try{BUILD.lazyLoad||o.$hostElement$[s](r)}catch(i){consoleError(i)}},getHostListenerTarget=(o,s)=>4&s?doc:8&s?win:16&s?doc.body:o,hostListenerOpts=o=>supportsListenerOptions?{passive:!!(1&o),capture:!!(2&o)}:!!(2&o),CURRENT_MODULE,METHOD_MODULE,o;o=CURRENT_MODULE||(CURRENT_MODULE={}),o.WELCOME="welcome",o.WELCOME_LOGIN="welcome-login",o.WELCOME_SIGNUP="welcome-signup",o.INFO="info",o.LOGIN_BUNKER_URL="login-bunker-url",o.LOGIN_READ_ONLY="login-read-only",o.CONFIRM_LOGOUT="confirm-logout",o.IMPORT_FLOW="import",o.IMPORT_OTP="import-otp",o.LOGIN="login",o.SIGNUP="signup",o.LOCAL_SIGNUP="local-signup",o.EXTENSION="extension",o.LOADING="loading",o.PREVIOUSLY_LOGGED="switch-account",o.LOGIN_OTP="otp",o.CONNECT="connect",o.CONNECTION_STRING="connection-string",o.IFRAME="iframe",function(o){o.LOGIN="login",o.SIGNUP="signup",o.LOGOUT="logout",o.CONFIRM="confirm"}(METHOD_MODULE||(METHOD_MODULE={}));const appendToMap=(o,s,r)=>{const i=o.get(s);i?i.includes(r)||i.push(r):o.set(s,[r])},debounce=(o,s)=>{let r;return(...i)=>{r&&clearTimeout(r),r=setTimeout(()=>{r=0,o(...i)},s)}},isConnected=o=>!("isConnected"in o)||o.isConnected,cleanupElements=debounce(o=>{for(let s of o.keys())o.set(s,o.get(s).filter(isConnected))},2e3),stencilSubscription=()=>{if("function"!=typeof getRenderingRef)return{};const o=new Map;return{dispose:()=>o.clear(),get:s=>{const r=getRenderingRef();r&&appendToMap(o,s,r)},set:s=>{const r=o.get(s);r&&o.set(s,r.filter(forceUpdate)),cleanupElements(o)},reset:()=>{o.forEach(s=>s.forEach(forceUpdate)),cleanupElements(o)}}},unwrap=o=>"function"==typeof o?o():o,createObservableMap=(o,s=(r,i)=>r!==i)=>{const r=unwrap(o);let i=new Map(Object.entries(r??{}));const a={dispose:[],get:[],set:[],reset:[]},c=()=>{var S;i=new Map(Object.entries(null!==(S=unwrap(o))&&void 0!==S?S:{})),a.reset.forEach(M=>M())},y=S=>(a.get.forEach(M=>M(S)),i.get(S)),w=(S,M)=>{const O=i.get(S);s(M,O,S)&&(i.set(S,M),a.set.forEach(L=>L(S,M,O)))},C=typeof Proxy>"u"?{}:new Proxy(r,{get:(S,M)=>y(M),ownKeys:S=>Array.from(i.keys()),getOwnPropertyDescriptor:()=>({enumerable:!0,configurable:!0}),has:(S,M)=>i.has(M),set:(S,M,O)=>(w(M,O),!0)}),T=(S,M)=>(a[S].push(M),()=>{removeFromArray(a[S],M)});return{state:C,get:y,set:w,on:T,onChange:(S,M)=>{const O=T("set",(Z,q)=>{Z===S&&M(q)}),L=T("reset",()=>M(unwrap(o)[S]));return()=>{O(),L()}},use:(...S)=>{const M=S.reduce((O,L)=>(L.set&&O.push(T("set",L.set)),L.get&&O.push(T("get",L.get)),L.reset&&O.push(T("reset",L.reset)),L.dispose&&O.push(T("dispose",L.dispose)),O),[]);return()=>M.forEach(O=>O())},dispose:()=>{a.dispose.forEach(S=>S()),c()},reset:c,forceUpdate:S=>{const M=i.get(S);a.set.forEach(O=>O(S,M,M))}}},removeFromArray=(o,s)=>{const r=o.indexOf(s);r>=0&&(o[r]=o[o.length-1],o.length--)},createStore=(o,s)=>{const r=createObservableMap(o,s);return r.use(stencilSubscription()),r},{state,onChange}=createStore({screen:CURRENT_MODULE.WELCOME,prevScreen:CURRENT_MODULE.WELCOME,path:[CURRENT_MODULE.WELCOME],error:"",isLoading:!1,isLoadingExtension:!1,isOTP:!1,authUrl:"",iframeUrl:"",localSignup:!1,nlSignin:{loginName:""},nlSignup:{signupName:"",domain:"",servers:[{name:"@nsec.app",value:"nsec.app"},{name:"@highlighter.com",value:"highlighter.com"}]},nlSigninBunkerUrl:{loginName:""},nlSigninReadOnly:{loginName:""},nlSigninOTP:{loginName:"",code:""},nlImport:null});onChange("screen",()=>{state.error="",state.nlSignin.loginName="",state.nlSignup.signupName="",state.nlSignup.domain=""});const baseCss="/*! tailwindcss v3.4.10 | MIT License | https://tailwindcss.com*/*,:after,:before{--tw-border-spacing-x:0;--tw-border-spacing-y:0;--tw-translate-x:0;--tw-translate-y:0;--tw-rotate:0;--tw-skew-x:0;--tw-skew-y:0;--tw-scale-x:1;--tw-scale-y:1;--tw-scroll-snap-strictness:proximity;--tw-ring-offset-width:0px;--tw-ring-offset-color:#fff;--tw-ring-color:rgba(59,130,246,.5);--tw-ring-offset-shadow:0 0 #0000;--tw-ring-shadow:0 0 #0000;--tw-shadow:0 0 #0000;--tw-shadow-colored:0 0 #0000;border:0 solid #e5e7eb;box-sizing:border-box}:after,:before{--tw-content:\"\"}:host,html{-webkit-text-size-adjust:100%;font-feature-settings:normal;-webkit-tap-highlight-color:transparent;font-family:ui-sans-serif,system-ui,sans-serif,Apple Color Emoji,Segoe UI Emoji,Segoe UI Symbol,Noto Color Emoji;font-variation-settings:normal;line-height:1.5;-moz-tab-size:4;tab-size:4}body{line-height:inherit;margin:0}hr{border-top-width:1px;color:inherit;height:0}abbr:where([title]){text-decoration:underline dotted}h1,h2,h3,h4,h5,h6{font-size:inherit;font-weight:inherit}a{color:inherit;text-decoration:inherit}b,strong{font-weight:bolder}code,kbd,pre,samp{font-feature-settings:normal;font-family:ui-monospace,SFMono-Regular,Menlo,Monaco,Consolas,Liberation Mono,Courier New,monospace;font-size:1em;font-variation-settings:normal}small{font-size:80%}sub,sup{font-size:75%;line-height:0;position:relative;vertical-align:baseline}sub{bottom:-.25em}sup{top:-.5em}table{border-collapse:collapse;border-color:inherit;text-indent:0}button,input,optgroup,select,textarea{font-feature-settings:inherit;color:inherit;font-family:inherit;font-size:100%;font-variation-settings:inherit;font-weight:inherit;letter-spacing:inherit;line-height:inherit;margin:0;padding:0}button,select{text-transform:none}button,input:where([type=button]),input:where([type=reset]),input:where([type=submit]){-webkit-appearance:button;background-color:transparent;background-image:none}:-moz-focusring{outline:auto}:-moz-ui-invalid{box-shadow:none}progress{vertical-align:baseline}::-webkit-inner-spin-button,::-webkit-outer-spin-button{height:auto}[type=search]{-webkit-appearance:textfield;outline-offset:-2px}::-webkit-search-decoration{-webkit-appearance:none}::-webkit-file-upload-button{-webkit-appearance:button;font:inherit}summary{display:list-item}blockquote,dd,dl,fieldset,figure,h1,h2,h3,h4,h5,h6,hr,p,pre{margin:0}fieldset,legend{padding:0}menu,ol,ul{list-style:none;margin:0;padding:0}dialog{padding:0}textarea{resize:vertical}input::placeholder,textarea::placeholder{color:#9ca3af;color:#6b7280;opacity:1}[role=button],button{cursor:pointer}:disabled{cursor:default}audio,canvas,embed,iframe,img,object,svg,video{display:block;vertical-align:middle}img,video{height:auto;max-width:100%}[hidden]{display:none}[multiple],[type=date],[type=datetime-local],[type=email],[type=month],[type=number],[type=password],[type=search],[type=tel],[type=text],[type=time],[type=url],[type=week],input:where(:not([type])),select,textarea{--tw-shadow:0 0 #0000;appearance:none;background-color:#fff;border-color:#6b7280;border-radius:0;border-width:1px;font-size:1rem;line-height:1.5rem;padding:.5rem .75rem}[multiple]:focus,[type=date]:focus,[type=datetime-local]:focus,[type=email]:focus,[type=month]:focus,[type=number]:focus,[type=password]:focus,[type=search]:focus,[type=tel]:focus,[type=text]:focus,[type=time]:focus,[type=url]:focus,[type=week]:focus,input:where(:not([type])):focus,select:focus,textarea:focus{--tw-ring-inset:var(--tw-empty, );--tw-ring-offset-width:0px;--tw-ring-offset-color:#fff;--tw-ring-color:#2563eb;--tw-ring-offset-shadow:var(--tw-ring-inset) 0 0 0 var(--tw-ring-offset-width) var(--tw-ring-offset-color);--tw-ring-shadow:var(--tw-ring-inset) 0 0 0 calc(1px + var(--tw-ring-offset-width)) var(--tw-ring-color);border-color:#2563eb;box-shadow:var(--tw-ring-offset-shadow),var(--tw-ring-shadow),var(--tw-shadow);outline:2px solid transparent;outline-offset:2px}::-webkit-datetime-edit-fields-wrapper{padding:0}::-webkit-date-and-time-value{min-height:1.5em;text-align:inherit}::-webkit-datetime-edit{display:inline-flex}::-webkit-datetime-edit,::-webkit-datetime-edit-day-field,::-webkit-datetime-edit-hour-field,::-webkit-datetime-edit-meridiem-field,::-webkit-datetime-edit-millisecond-field,::-webkit-datetime-edit-minute-field,::-webkit-datetime-edit-month-field,::-webkit-datetime-edit-second-field,::-webkit-datetime-edit-year-field{padding-bottom:0;padding-top:0}select{background-image:url(\"data:image/svg+xml;charset=utf-8,%3Csvg xmlns='http://www.w3.org/2000/svg' fill='none' viewBox='0 0 20 20'%3E%3Cpath stroke='%236b7280' stroke-linecap='round' stroke-linejoin='round' stroke-width='1.5' d='m6 8 4 4 4-4'/%3E%3C/svg%3E\");background-position:right .5rem center;background-repeat:no-repeat;background-size:1.5em 1.5em;padding-right:2.5rem;print-color-adjust:exact}[multiple],[size]:where(select:not([size=\"1\"])){background-image:none;background-position:0 0;background-repeat:unset;background-size:initial;padding-right:.75rem;print-color-adjust:unset}[type=checkbox],[type=radio]{--tw-shadow:0 0 #0000;appearance:none;background-color:#fff;background-origin:border-box;border-color:#6b7280;border-width:1px;color:#2563eb;display:inline-block;flex-shrink:0;height:1rem;padding:0;print-color-adjust:exact;user-select:none;vertical-align:middle;width:1rem}[type=checkbox]{border-radius:0}[type=radio]{border-radius:100%}[type=checkbox]:focus,[type=radio]:focus{--tw-ring-inset:var(--tw-empty, );--tw-ring-offset-width:2px;--tw-ring-offset-color:#fff;--tw-ring-color:#2563eb;--tw-ring-offset-shadow:var(--tw-ring-inset) 0 0 0 var(--tw-ring-offset-width) var(--tw-ring-offset-color);--tw-ring-shadow:var(--tw-ring-inset) 0 0 0 calc(2px + var(--tw-ring-offset-width)) var(--tw-ring-color);box-shadow:var(--tw-ring-offset-shadow),var(--tw-ring-shadow),var(--tw-shadow);outline:2px solid transparent;outline-offset:2px}[type=checkbox]:checked,[type=radio]:checked{background-color:currentColor;background-position:50%;background-repeat:no-repeat;background-size:100% 100%;border-color:transparent}[type=checkbox]:checked{background-image:url(\"data:image/svg+xml;charset=utf-8,%3Csvg viewBox='0 0 16 16' fill='%23fff' xmlns='http://www.w3.org/2000/svg'%3E%3Cpath d='M12.207 4.793a1 1 0 0 1 0 1.414l-5 5a1 1 0 0 1-1.414 0l-2-2a1 1 0 0 1 1.414-1.414L6.5 9.086l4.293-4.293a1 1 0 0 1 1.414 0z'/%3E%3C/svg%3E\")}@media (forced-colors:active){[type=checkbox]:checked{appearance:auto}}[type=radio]:checked{background-image:url(\"data:image/svg+xml;charset=utf-8,%3Csvg viewBox='0 0 16 16' fill='%23fff' xmlns='http://www.w3.org/2000/svg'%3E%3Ccircle cx='8' cy='8' r='3'/%3E%3C/svg%3E\")}@media (forced-colors:active){[type=radio]:checked{appearance:auto}}[type=checkbox]:checked:focus,[type=checkbox]:checked:hover,[type=radio]:checked:focus,[type=radio]:checked:hover{background-color:currentColor;border-color:transparent}[type=checkbox]:indeterminate{background-color:currentColor;background-image:url(\"data:image/svg+xml;charset=utf-8,%3Csvg xmlns='http://www.w3.org/2000/svg' fill='none' viewBox='0 0 16 16'%3E%3Cpath stroke='%23fff' stroke-linecap='round' stroke-linejoin='round' stroke-width='2' d='M4 8h8'/%3E%3C/svg%3E\");background-position:50%;background-repeat:no-repeat;background-size:100% 100%;border-color:transparent}@media (forced-colors:active){[type=checkbox]:indeterminate{appearance:auto}}[type=checkbox]:indeterminate:focus,[type=checkbox]:indeterminate:hover{background-color:currentColor;border-color:transparent}[type=file]{background:unset;border-color:inherit;border-radius:0;border-width:0;font-size:unset;line-height:inherit;padding:0}[type=file]:focus{outline:1px solid ButtonText;outline:1px auto -webkit-focus-ring-color}::backdrop{--tw-border-spacing-x:0;--tw-border-spacing-y:0;--tw-translate-x:0;--tw-translate-y:0;--tw-rotate:0;--tw-skew-x:0;--tw-skew-y:0;--tw-scale-x:1;--tw-scale-y:1;--tw-scroll-snap-strictness:proximity;--tw-ring-offset-width:0px;--tw-ring-offset-color:#fff;--tw-ring-color:rgba(59,130,246,.5);--tw-ring-offset-shadow:0 0 #0000;--tw-ring-shadow:0 0 #0000;--tw-shadow:0 0 #0000;--tw-shadow-colored:0 0 #0000;}.block{display:block}.transform{transform:translate(var(--tw-translate-x),var(--tw-translate-y)) rotate(var(--tw-rotate)) skewX(var(--tw-skew-x)) skewY(var(--tw-skew-y)) scaleX(var(--tw-scale-x)) scaleY(var(--tw-scale-y))}.theme-default .nl-bg{--tw-bg-opacity:1;--tw-shadow:0 1px 2px 0 rgba(0,0,0,.05);--tw-shadow-colored:0 1px 2px 0 var(--tw-shadow-color);background-color:rgb(255 255 255/var(--tw-bg-opacity));box-shadow:var(--tw-ring-offset-shadow,0 0 #0000),var(--tw-ring-shadow,0 0 #0000),var(--tw-shadow)}.theme-default .dark .nl-bg{--tw-bg-opacity:1;--tw-shadow-color:rgba(51,65,85,.7);--tw-shadow:var(--tw-shadow-colored);background-color:rgb(31 41 55/var(--tw-bg-opacity))}.theme-default .nl-description,.theme-default .nl-logo,.theme-default .nl-title{--tw-text-opacity:1;color:rgb(31 41 55/var(--tw-text-opacity))}.theme-default .dark .nl-description,.theme-default .dark .nl-logo,.theme-default .dark .nl-title{--tw-text-opacity:1;color:rgb(255 255 255/var(--tw-text-opacity))}.theme-default .nl-description a{--tw-text-opacity:1;color:rgb(30 64 175/var(--tw-text-opacity));text-decoration-line:underline}.theme-default .dark .nl-description a{--tw-text-opacity:1;color:rgb(191 219 254/var(--tw-text-opacity));text-decoration-line:underline}.theme-default .nl-action-button{--tw-text-opacity:1;color:rgb(31 41 55/var(--tw-text-opacity));outline:2px solid transparent;outline-offset:2px}.theme-default .nl-action-button:hover{--tw-bg-opacity:1;background-color:rgb(243 244 246/var(--tw-bg-opacity))}.theme-default .dark .nl-action-button{--tw-text-opacity:1;color:rgb(255 255 255/var(--tw-text-opacity));outline:2px solid transparent;outline-offset:2px}.theme-default .dark .nl-action-button:hover{--tw-bg-opacity:1;background-color:rgb(55 65 81/var(--tw-bg-opacity))}.theme-default .nl-title{--tw-text-opacity:1;color:rgb(31 41 55/var(--tw-text-opacity))}.theme-default .dark .nl-title{--tw-text-opacity:1;color:rgb(229 231 235/var(--tw-text-opacity))}.theme-default .nl-button{--tw-border-opacity:1;--tw-bg-opacity:1;--tw-text-opacity:1;--tw-shadow:0 1px 2px 0 rgba(0,0,0,.05);--tw-shadow-colored:0 1px 2px 0 var(--tw-shadow-color);background-color:rgb(255 255 255/var(--tw-bg-opacity));border-color:rgb(229 231 235/var(--tw-border-opacity));border-width:1px;box-shadow:var(--tw-ring-offset-shadow,0 0 #0000),var(--tw-ring-shadow,0 0 #0000),var(--tw-shadow);color:rgb(31 41 55/var(--tw-text-opacity))}.theme-default .nl-button:hover{--tw-bg-opacity:1;background-color:rgb(249 250 251/var(--tw-bg-opacity))}.theme-default .dark .nl-button{--tw-border-opacity:1;--tw-bg-opacity:1;--tw-text-opacity:1;background-color:rgb(15 23 42/var(--tw-bg-opacity));border-color:rgb(55 65 81/var(--tw-border-opacity));color:rgb(209 213 219/var(--tw-text-opacity))}.theme-default .dark .nl-button:hover{--tw-bg-opacity:1;background-color:rgb(31 41 55/var(--tw-bg-opacity))}.theme-default .nl-divider{--tw-text-opacity:1;color:rgb(156 163 175/var(--tw-text-opacity))}.theme-default .nl-divider:before{border-top-width:1px}.theme-default .nl-divider:after,.theme-default .nl-divider:before{--tw-border-opacity:1;border-color:rgb(229 231 235/var(--tw-border-opacity));content:var(--tw-content)}.theme-default .dark .nl-divider{--tw-text-opacity:1;color:rgb(107 114 128/var(--tw-text-opacity))}.theme-default .dark .nl-divider:after,.theme-default .dark .nl-divider:before{--tw-border-opacity:1;border-color:rgb(75 85 99/var(--tw-border-opacity));content:var(--tw-content)}.theme-default .nl-footer{--tw-text-opacity:1;color:rgb(31 41 55/var(--tw-text-opacity))}.theme-default .dark .nl-footer{--tw-text-opacity:1;color:rgb(229 231 235/var(--tw-text-opacity))}.theme-default .nl-error{--tw-text-opacity:1;color:rgb(153 27 27/var(--tw-text-opacity))}.theme-default .dark .nl-error{--tw-text-opacity:1;color:rgb(254 202 202/var(--tw-text-opacity))}.theme-default .nl-input{--tw-bg-opacity:1;background-color:rgb(243 244 246/var(--tw-bg-opacity))}.theme-default .nl-input:focus{--tw-border-opacity:1;--tw-ring-opacity:1;--tw-ring-color:rgb(168 85 247/var(--tw-ring-opacity));border-color:rgb(168 85 247/var(--tw-border-opacity))}.theme-default .dark .nl-input{--tw-bg-opacity:1;--tw-text-opacity:1;background-color:rgb(55 65 81/var(--tw-bg-opacity));color:rgb(156 163 175/var(--tw-text-opacity))}.theme-default .dark .nl-input:focus{--tw-ring-opacity:1;--tw-ring-color:rgb(75 85 99/var(--tw-ring-opacity))}.theme-default .nl-select{--tw-bg-opacity:1;background-color:rgb(243 244 246/var(--tw-bg-opacity))}.theme-default .nl-select:focus{--tw-border-opacity:1;--tw-ring-opacity:1;--tw-ring-color:rgb(168 85 247/var(--tw-ring-opacity));border-color:rgb(168 85 247/var(--tw-border-opacity))}.theme-default .dark .nl-select{--tw-bg-opacity:1;--tw-text-opacity:1;background-color:rgb(55 65 81/var(--tw-bg-opacity));color:rgb(156 163 175/var(--tw-text-opacity))}.theme-default .dark .nl-select:focus{--tw-ring-opacity:1;--tw-ring-color:rgb(75 85 99/var(--tw-ring-opacity))}.theme-default .nl-select-list{--tw-bg-opacity:1;background-color:rgb(243 244 246/var(--tw-bg-opacity))}.theme-default .dark .nl-select-list{--tw-bg-opacity:1;background-color:rgb(55 65 81/var(--tw-bg-opacity))}.theme-default .nl-select-option{--tw-text-opacity:1;color:rgb(31 41 55/var(--tw-text-opacity))}.theme-default .nl-select-option:hover{--tw-bg-opacity:1;background-color:rgb(229 231 235/var(--tw-bg-opacity))}.theme-default .nl-select-option.active-option{--tw-bg-opacity:1;--tw-text-opacity:1;background-color:rgb(209 213 219/var(--tw-bg-opacity));color:rgb(30 58 138/var(--tw-text-opacity))}.theme-default .dark .nl-select-option{--tw-text-opacity:1;color:rgb(156 163 175/var(--tw-text-opacity))}.theme-default .dark .nl-select-option:hover{--tw-bg-opacity:1;--tw-text-opacity:1;background-color:rgb(31 41 55/var(--tw-bg-opacity));color:rgb(209 213 219/var(--tw-text-opacity))}.theme-default .nl-text-error{--tw-text-opacity:1;color:rgb(248 113 113/var(--tw-text-opacity))}.theme-default .nl-text-success{--tw-text-opacity:1;color:rgb(45 212 191/var(--tw-text-opacity))}.theme-default .nl-banner{--tw-border-opacity:1;--tw-bg-opacity:1;--tw-text-opacity:1;--tw-shadow:0 1px 2px 0 rgba(0,0,0,.05);--tw-shadow-colored:0 1px 2px 0 var(--tw-shadow-color);background-color:rgb(255 255 255/var(--tw-bg-opacity));border-color:rgb(229 231 235/var(--tw-border-opacity));border-width:1px;box-shadow:var(--tw-ring-offset-shadow,0 0 #0000),var(--tw-ring-shadow,0 0 #0000),var(--tw-shadow);color:rgb(31 41 55/var(--tw-text-opacity))}.theme-default .dark .nl-banner{--tw-border-opacity:1;--tw-bg-opacity:1;--tw-text-opacity:1;background-color:rgb(15 23 42/var(--tw-bg-opacity));border-color:rgb(55 65 81/var(--tw-border-opacity));color:rgb(209 213 219/var(--tw-text-opacity))}.theme-ocean .nl-bg{--tw-bg-opacity:1;--tw-shadow:0 1px 2px 0 rgba(0,0,0,.05);--tw-shadow-colored:0 1px 2px 0 var(--tw-shadow-color);background-color:rgb(191 219 254/var(--tw-bg-opacity));box-shadow:var(--tw-ring-offset-shadow,0 0 #0000),var(--tw-ring-shadow,0 0 #0000),var(--tw-shadow)}.theme-ocean .dark .nl-bg{--tw-bg-opacity:1;--tw-shadow-color:rgba(51,65,85,.7);--tw-shadow:var(--tw-shadow-colored);background-color:rgb(8 47 73/var(--tw-bg-opacity))}.theme-ocean .nl-description,.theme-ocean .nl-logo,.theme-ocean .nl-title{--tw-text-opacity:1;color:rgb(8 47 73/var(--tw-text-opacity))}.theme-ocean .dark .nl-description,.theme-ocean .dark .nl-logo,.theme-ocean .dark .nl-title{--tw-text-opacity:1;color:rgb(186 230 253/var(--tw-text-opacity))}.theme-ocean .nl-action-button{--tw-text-opacity:1;color:rgb(8 47 73/var(--tw-text-opacity));outline:2px solid transparent;outline-offset:2px}.theme-ocean .nl-action-button:hover{--tw-bg-opacity:1;background-color:rgb(224 242 254/var(--tw-bg-opacity))}.theme-ocean .dark .nl-action-button{--tw-text-opacity:1;color:rgb(186 230 253/var(--tw-text-opacity));outline:2px solid transparent;outline-offset:2px}.theme-ocean .dark .nl-action-button:hover{--tw-bg-opacity:1;background-color:rgb(12 74 110/var(--tw-bg-opacity))}.theme-ocean .nl-button{--tw-border-opacity:1;--tw-bg-opacity:1;--tw-text-opacity:1;--tw-shadow:0 1px 2px 0 rgba(0,0,0,.05);--tw-shadow-colored:0 1px 2px 0 var(--tw-shadow-color);background-color:rgb(224 242 254/var(--tw-bg-opacity));border-color:rgb(186 230 253/var(--tw-border-opacity));border-width:1px;box-shadow:var(--tw-ring-offset-shadow,0 0 #0000),var(--tw-ring-shadow,0 0 #0000),var(--tw-shadow);color:rgb(8 47 73/var(--tw-text-opacity))}.theme-ocean .nl-button:hover{--tw-bg-opacity:1;background-color:rgb(240 249 255/var(--tw-bg-opacity))}.theme-ocean .dark .nl-button{--tw-border-opacity:1;--tw-bg-opacity:1;--tw-text-opacity:1;background-color:rgb(7 89 133/var(--tw-bg-opacity));border-color:rgb(8 47 73/var(--tw-border-opacity));color:rgb(186 230 253/var(--tw-text-opacity))}.theme-ocean .dark .nl-button:hover{--tw-bg-opacity:1;background-color:rgb(12 74 110/var(--tw-bg-opacity))}.theme-ocean .nl-divider{--tw-text-opacity:1;color:rgb(8 47 73/var(--tw-text-opacity))}.theme-ocean .nl-divider:after,.theme-ocean .nl-divider:before{--tw-border-opacity:1;border-color:rgb(8 47 73/var(--tw-border-opacity));content:var(--tw-content)}.theme-ocean .dark .nl-divider{--tw-text-opacity:1;color:rgb(186 230 253/var(--tw-text-opacity))}.theme-ocean .dark .nl-divider:after,.theme-ocean .dark .nl-divider:before{--tw-border-opacity:1;border-color:rgb(186 230 253/var(--tw-border-opacity));content:var(--tw-content)}.theme-ocean .nl-footer{--tw-text-opacity:1;color:rgb(8 47 73/var(--tw-text-opacity))}.theme-ocean .dark .nl-footer{--tw-text-opacity:1;color:rgb(186 230 253/var(--tw-text-opacity))}.theme-ocean .nl-error{--tw-text-opacity:1;color:rgb(153 27 27/var(--tw-text-opacity))}.theme-ocean .dark .nl-error{--tw-text-opacity:1;color:rgb(254 202 202/var(--tw-text-opacity))}.theme-ocean .nl-input{--tw-bg-opacity:1;background-color:rgb(224 242 254/var(--tw-bg-opacity))}.theme-ocean .nl-input:focus{--tw-border-opacity:1;--tw-ring-opacity:1;--tw-ring-color:rgb(14 165 233/var(--tw-ring-opacity));border-color:rgb(14 165 233/var(--tw-border-opacity))}.theme-ocean .dark .nl-input{--tw-bg-opacity:1;--tw-text-opacity:1;background-color:rgb(12 74 110/var(--tw-bg-opacity));color:rgb(56 189 248/var(--tw-text-opacity))}.theme-ocean .dark .nl-input:focus{--tw-ring-opacity:1;--tw-ring-color:rgb(2 132 199/var(--tw-ring-opacity))}.theme-ocean .nl-select{--tw-bg-opacity:1;background-color:rgb(224 242 254/var(--tw-bg-opacity))}.theme-ocean .nl-select:focus{--tw-border-opacity:1;--tw-ring-opacity:1;--tw-ring-color:rgb(14 165 233/var(--tw-ring-opacity));border-color:rgb(14 165 233/var(--tw-border-opacity))}.theme-ocean .dark .nl-select{--tw-bg-opacity:1;--tw-text-opacity:1;background-color:rgb(12 74 110/var(--tw-bg-opacity));color:rgb(56 189 248/var(--tw-text-opacity))}.theme-ocean .dark .nl-select:focus{--tw-ring-opacity:1;--tw-ring-color:rgb(2 132 199/var(--tw-ring-opacity))}.theme-ocean .nl-select-list{--tw-bg-opacity:1;background-color:rgb(224 242 254/var(--tw-bg-opacity))}.theme-ocean .dark .nl-select-list{--tw-bg-opacity:1;background-color:rgb(3 105 161/var(--tw-bg-opacity))}.theme-ocean .nl-select-option{--tw-text-opacity:1;color:rgb(7 89 133/var(--tw-text-opacity))}.theme-ocean .nl-select-option:hover{--tw-bg-opacity:1;background-color:rgb(186 230 253/var(--tw-bg-opacity))}.theme-ocean .dark .nl-select-option{--tw-text-opacity:1;color:rgb(56 189 248/var(--tw-text-opacity))}.theme-ocean .dark .nl-select-option:hover{--tw-bg-opacity:1;--tw-text-opacity:1;background-color:rgb(7 89 133/var(--tw-bg-opacity));color:rgb(125 211 252/var(--tw-text-opacity))}.theme-ocean .nl-text-error{--tw-text-opacity:1;color:rgb(220 38 38/var(--tw-text-opacity))}.theme-ocean .dark .nl-text-error{--tw-text-opacity:1;color:rgb(248 113 113/var(--tw-text-opacity))}.theme-ocean .nl-text-success{--tw-text-opacity:1;color:rgb(13 148 136/var(--tw-text-opacity))}.theme-ocean .dark .nl-text-success{--tw-text-opacity:1;color:rgb(45 212 191/var(--tw-text-opacity))}.theme-lemonade .nl-bg{--tw-bg-opacity:1;--tw-shadow:0 1px 2px 0 rgba(0,0,0,.05);--tw-shadow-colored:0 1px 2px 0 var(--tw-shadow-color);background-color:rgb(187 247 208/var(--tw-bg-opacity));box-shadow:var(--tw-ring-offset-shadow,0 0 #0000),var(--tw-ring-shadow,0 0 #0000),var(--tw-shadow)}.theme-lemonade .dark .nl-bg{--tw-bg-opacity:1;--tw-shadow-color:rgba(51,65,85,.7);--tw-shadow:var(--tw-shadow-colored);background-color:rgb(5 46 22/var(--tw-bg-opacity))}.theme-lemonade .nl-description,.theme-lemonade .nl-logo,.theme-lemonade .nl-title{--tw-text-opacity:1;color:rgb(5 46 22/var(--tw-text-opacity))}.theme-lemonade .dark .nl-description,.theme-lemonade .dark .nl-logo,.theme-lemonade .dark .nl-title{--tw-text-opacity:1;color:rgb(187 247 208/var(--tw-text-opacity))}.theme-lemonade .nl-action-button{--tw-text-opacity:1;color:rgb(5 46 22/var(--tw-text-opacity));outline:2px solid transparent;outline-offset:2px}.theme-lemonade .nl-action-button:hover{--tw-bg-opacity:1;background-color:rgb(220 252 231/var(--tw-bg-opacity))}.theme-lemonade .dark .nl-action-button{--tw-text-opacity:1;color:rgb(187 247 208/var(--tw-text-opacity));outline:2px solid transparent;outline-offset:2px}.theme-lemonade .dark .nl-action-button:hover{--tw-bg-opacity:1;background-color:rgb(20 83 45/var(--tw-bg-opacity))}.theme-lemonade .nl-button{--tw-border-opacity:1;--tw-bg-opacity:1;--tw-text-opacity:1;--tw-shadow:0 1px 2px 0 rgba(0,0,0,.05);--tw-shadow-colored:0 1px 2px 0 var(--tw-shadow-color);background-color:rgb(220 252 231/var(--tw-bg-opacity));border-color:rgb(187 247 208/var(--tw-border-opacity));border-width:1px;box-shadow:var(--tw-ring-offset-shadow,0 0 #0000),var(--tw-ring-shadow,0 0 #0000),var(--tw-shadow);color:rgb(5 46 22/var(--tw-text-opacity))}.theme-lemonade .nl-button:hover{--tw-bg-opacity:1;background-color:rgb(240 253 244/var(--tw-bg-opacity))}.theme-lemonade .dark .nl-button{--tw-border-opacity:1;--tw-bg-opacity:1;--tw-text-opacity:1;background-color:rgb(22 101 52/var(--tw-bg-opacity));border-color:rgb(5 46 22/var(--tw-border-opacity));color:rgb(187 247 208/var(--tw-text-opacity))}.theme-lemonade .dark .nl-button:hover{--tw-bg-opacity:1;background-color:rgb(20 83 45/var(--tw-bg-opacity))}.theme-lemonade .nl-divider{--tw-text-opacity:1;color:rgb(5 46 22/var(--tw-text-opacity))}.theme-lemonade .nl-divider:after,.theme-lemonade .nl-divider:before{--tw-border-opacity:1;border-color:rgb(5 46 22/var(--tw-border-opacity));content:var(--tw-content)}.theme-lemonade .dark .nl-divider{--tw-text-opacity:1;color:rgb(187 247 208/var(--tw-text-opacity))}.theme-lemonade .dark .nl-divider:after,.theme-lemonade .dark .nl-divider:before{--tw-border-opacity:1;border-color:rgb(187 247 208/var(--tw-border-opacity));content:var(--tw-content)}.theme-lemonade .nl-footer{--tw-text-opacity:1;color:rgb(5 46 22/var(--tw-text-opacity))}.theme-lemonade .dark .nl-footer{--tw-text-opacity:1;color:rgb(187 247 208/var(--tw-text-opacity))}.theme-lemonade .nl-error{--tw-text-opacity:1;color:rgb(153 27 27/var(--tw-text-opacity))}.theme-lemonade .dark .nl-error{--tw-text-opacity:1;color:rgb(254 202 202/var(--tw-text-opacity))}.theme-lemonade .nl-input{--tw-bg-opacity:1;background-color:rgb(220 252 231/var(--tw-bg-opacity))}.theme-lemonade .nl-input:focus{--tw-border-opacity:1;--tw-ring-opacity:1;--tw-ring-color:rgb(34 197 94/var(--tw-ring-opacity));border-color:rgb(34 197 94/var(--tw-border-opacity))}.theme-lemonade .dark .nl-input{--tw-bg-opacity:1;--tw-text-opacity:1;background-color:rgb(20 83 45/var(--tw-bg-opacity));color:rgb(74 222 128/var(--tw-text-opacity))}.theme-lemonade .dark .nl-input:focus{--tw-ring-opacity:1;--tw-ring-color:rgb(22 163 74/var(--tw-ring-opacity))}.theme-lemonade .nl-select{--tw-bg-opacity:1;background-color:rgb(220 252 231/var(--tw-bg-opacity))}.theme-lemonade .nl-select:focus{--tw-border-opacity:1;--tw-ring-opacity:1;--tw-ring-color:rgb(34 197 94/var(--tw-ring-opacity));border-color:rgb(34 197 94/var(--tw-border-opacity))}.theme-lemonade .dark .nl-select{--tw-bg-opacity:1;--tw-text-opacity:1;background-color:rgb(20 83 45/var(--tw-bg-opacity));color:rgb(74 222 128/var(--tw-text-opacity))}.theme-lemonade .dark .nl-select:focus{--tw-ring-opacity:1;--tw-ring-color:rgb(22 163 74/var(--tw-ring-opacity))}.theme-lemonade .nl-select-list{--tw-bg-opacity:1;background-color:rgb(220 252 231/var(--tw-bg-opacity))}.theme-lemonade .dark .nl-select-list{--tw-bg-opacity:1;background-color:rgb(21 128 61/var(--tw-bg-opacity))}.theme-lemonade .nl-select-option{--tw-text-opacity:1;color:rgb(22 101 52/var(--tw-text-opacity))}.theme-lemonade .nl-select-option:hover{--tw-bg-opacity:1;background-color:rgb(187 247 208/var(--tw-bg-opacity))}.theme-lemonade .dark .nl-select-option{--tw-text-opacity:1;color:rgb(74 222 128/var(--tw-text-opacity))}.theme-lemonade .dark .nl-select-option:hover{--tw-bg-opacity:1;--tw-text-opacity:1;background-color:rgb(22 101 52/var(--tw-bg-opacity));color:rgb(134 239 172/var(--tw-text-opacity))}.theme-lemonade .nl-text-error{--tw-text-opacity:1;color:rgb(220 38 38/var(--tw-text-opacity))}.theme-lemonade .dark .nl-text-error{--tw-text-opacity:1;color:rgb(248 113 113/var(--tw-text-opacity))}.theme-lemonade .nl-text-success{--tw-text-opacity:1;color:rgb(13 148 136/var(--tw-text-opacity))}.theme-lemonade .dark .nl-text-success{--tw-text-opacity:1;color:rgb(45 212 191/var(--tw-text-opacity))}.theme-purple .nl-bg{--tw-bg-opacity:1;--tw-shadow:0 1px 2px 0 rgba(0,0,0,.05);--tw-shadow-colored:0 1px 2px 0 var(--tw-shadow-color);background-color:rgb(233 213 255/var(--tw-bg-opacity));box-shadow:var(--tw-ring-offset-shadow,0 0 #0000),var(--tw-ring-shadow,0 0 #0000),var(--tw-shadow)}.theme-purple .dark .nl-bg{--tw-bg-opacity:1;--tw-shadow-color:rgba(51,65,85,.7);--tw-shadow:var(--tw-shadow-colored);background-color:rgb(59 7 100/var(--tw-bg-opacity))}.theme-purple .nl-description,.theme-purple .nl-logo,.theme-purple .nl-title{--tw-text-opacity:1;color:rgb(59 7 100/var(--tw-text-opacity))}.theme-purple .dark .nl-description,.theme-purple .dark .nl-logo,.theme-purple .dark .nl-title{--tw-text-opacity:1;color:rgb(233 213 255/var(--tw-text-opacity))}.theme-purple .nl-action-button{--tw-text-opacity:1;color:rgb(59 7 100/var(--tw-text-opacity));outline:2px solid transparent;outline-offset:2px}.theme-purple .nl-action-button:hover{--tw-bg-opacity:1;background-color:rgb(243 232 255/var(--tw-bg-opacity))}.theme-purple .dark .nl-action-button{--tw-text-opacity:1;color:rgb(233 213 255/var(--tw-text-opacity));outline:2px solid transparent;outline-offset:2px}.theme-purple .dark .nl-action-button:hover{--tw-bg-opacity:1;background-color:rgb(88 28 135/var(--tw-bg-opacity))}.theme-purple .nl-button{--tw-border-opacity:1;--tw-bg-opacity:1;--tw-text-opacity:1;--tw-shadow:0 1px 2px 0 rgba(0,0,0,.05);--tw-shadow-colored:0 1px 2px 0 var(--tw-shadow-color);background-color:rgb(243 232 255/var(--tw-bg-opacity));border-color:rgb(233 213 255/var(--tw-border-opacity));border-width:1px;box-shadow:var(--tw-ring-offset-shadow,0 0 #0000),var(--tw-ring-shadow,0 0 #0000),var(--tw-shadow);color:rgb(59 7 100/var(--tw-text-opacity))}.theme-purple .nl-button:hover{--tw-bg-opacity:1;background-color:rgb(250 245 255/var(--tw-bg-opacity))}.theme-purple .dark .nl-button{--tw-border-opacity:1;--tw-bg-opacity:1;--tw-text-opacity:1;background-color:rgb(107 33 168/var(--tw-bg-opacity));border-color:rgb(59 7 100/var(--tw-border-opacity));color:rgb(233 213 255/var(--tw-text-opacity))}.theme-purple .dark .nl-button:hover{--tw-bg-opacity:1;background-color:rgb(88 28 135/var(--tw-bg-opacity))}.theme-purple .nl-divider{--tw-text-opacity:1;color:rgb(59 7 100/var(--tw-text-opacity))}.theme-purple .nl-divider:after,.theme-purple .nl-divider:before{--tw-border-opacity:1;border-color:rgb(59 7 100/var(--tw-border-opacity));content:var(--tw-content)}.theme-purple .dark .nl-divider{--tw-text-opacity:1;color:rgb(233 213 255/var(--tw-text-opacity))}.theme-purple .dark .nl-divider:after,.theme-purple .dark .nl-divider:before{--tw-border-opacity:1;border-color:rgb(233 213 255/var(--tw-border-opacity));content:var(--tw-content)}.theme-purple .nl-footer{--tw-text-opacity:1;color:rgb(59 7 100/var(--tw-text-opacity))}.theme-purple .dark .nl-footer{--tw-text-opacity:1;color:rgb(233 213 255/var(--tw-text-opacity))}.theme-purple .nl-error{--tw-text-opacity:1;color:rgb(153 27 27/var(--tw-text-opacity))}.theme-purple .dark .nl-error{--tw-text-opacity:1;color:rgb(254 202 202/var(--tw-text-opacity))}.theme-purple .nl-input{--tw-bg-opacity:1;background-color:rgb(243 232 255/var(--tw-bg-opacity))}.theme-purple .nl-input:focus{--tw-border-opacity:1;--tw-ring-opacity:1;--tw-ring-color:rgb(168 85 247/var(--tw-ring-opacity));border-color:rgb(168 85 247/var(--tw-border-opacity))}.theme-purple .dark .nl-input{--tw-bg-opacity:1;--tw-text-opacity:1;background-color:rgb(88 28 135/var(--tw-bg-opacity));color:rgb(192 132 252/var(--tw-text-opacity))}.theme-purple .dark .nl-input:focus{--tw-ring-opacity:1;--tw-ring-color:rgb(147 51 234/var(--tw-ring-opacity))}.theme-purple .nl-select{--tw-bg-opacity:1;background-color:rgb(243 232 255/var(--tw-bg-opacity))}.theme-purple .nl-select:focus{--tw-border-opacity:1;--tw-ring-opacity:1;--tw-ring-color:rgb(168 85 247/var(--tw-ring-opacity));border-color:rgb(168 85 247/var(--tw-border-opacity))}.theme-purple .dark .nl-select{--tw-bg-opacity:1;--tw-text-opacity:1;background-color:rgb(88 28 135/var(--tw-bg-opacity));color:rgb(192 132 252/var(--tw-text-opacity))}.theme-purple .dark .nl-select:focus{--tw-ring-opacity:1;--tw-ring-color:rgb(147 51 234/var(--tw-ring-opacity))}.theme-purple .nl-select-list{--tw-bg-opacity:1;background-color:rgb(243 232 255/var(--tw-bg-opacity))}.theme-purple .dark .nl-select-list{--tw-bg-opacity:1;background-color:rgb(126 34 206/var(--tw-bg-opacity))}.theme-purple .nl-select-option{--tw-text-opacity:1;color:rgb(107 33 168/var(--tw-text-opacity))}.theme-purple .nl-select-option:hover{--tw-bg-opacity:1;background-color:rgb(233 213 255/var(--tw-bg-opacity))}.theme-purple .dark .nl-select-option{--tw-text-opacity:1;color:rgb(192 132 252/var(--tw-text-opacity))}.theme-purple .dark .nl-select-option:hover{--tw-bg-opacity:1;--tw-text-opacity:1;background-color:rgb(107 33 168/var(--tw-bg-opacity));color:rgb(216 180 254/var(--tw-text-opacity))}.theme-purple .nl-text-error{--tw-text-opacity:1;color:rgb(220 38 38/var(--tw-text-opacity))}.theme-purple .dark .nl-text-error{--tw-text-opacity:1;color:rgb(248 113 113/var(--tw-text-opacity))}.theme-purple .nl-text-success{--tw-text-opacity:1;color:rgb(13 148 136/var(--tw-text-opacity))}.theme-purple .dark .nl-text-success{--tw-text-opacity:1;color:rgb(45 212 191/var(--tw-text-opacity))}.theme-crab .nl-button{--tw-border-opacity:1;--tw-bg-opacity:1;--tw-text-opacity:1;--tw-shadow:0 1px 2px 0 rgba(0,0,0,.05);--tw-shadow-colored:0 1px 2px 0 var(--tw-shadow-color);background-color:rgb(254 226 226/var(--tw-bg-opacity));border-color:rgb(254 202 202/var(--tw-border-opacity));border-width:1px;box-shadow:var(--tw-ring-offset-shadow,0 0 #0000),var(--tw-ring-shadow,0 0 #0000),var(--tw-shadow);color:rgb(69 10 10/var(--tw-text-opacity))}.theme-crab .nl-button:hover{--tw-bg-opacity:1;background-color:rgb(254 242 242/var(--tw-bg-opacity))}.theme-crab .dark .nl-button{--tw-border-opacity:1;--tw-bg-opacity:1;--tw-text-opacity:1;background-color:rgb(153 27 27/var(--tw-bg-opacity));border-color:rgb(69 10 10/var(--tw-border-opacity));color:rgb(254 202 202/var(--tw-text-opacity))}.theme-crab .dark .nl-button:hover{--tw-bg-opacity:1;background-color:rgb(127 29 29/var(--tw-bg-opacity))}.show-slow{display:none;opacity:0;transition:.1s}.isOpen .show-slow{display:block;opacity:1;transition:.2s;transition-delay:.2s}:host{display:block}.animate-spin-loading{animation:spin2 1s linear infinite;background:var(--qa-dark-color)}@keyframes spin2{to{transform:rotate(1turn)}}.active{animation:blink .7s infinite alternate}@keyframes blink{0%{opacity:1}to{opacity:0}}.sr-only{clip:rect(0,0,0,0);border-width:0;height:1px;margin:-1px;overflow:hidden;padding:0;position:absolute;white-space:nowrap;width:1px}.static{position:static}.fixed{position:fixed}.absolute{position:absolute}.relative{position:relative}.left-0{left:0}.start-0{inset-inline-start:0}.top-0{top:0}.z-\\[80\\]{z-index:80}.z-\\[81\\]{z-index:81}.mx-auto{margin-left:auto;margin-right:auto}.flex{display:flex}.h-5{height:20px}.h-7{height:28px}.h-full{height:100%}.w-5{width:20px}.w-7{width:28px}.w-full{width:100%}.max-w-96{max-width:384px}.flex-shrink-0{flex-shrink:0}.cursor-pointer{cursor:pointer}.flex-col{flex-direction:column}.items-center{align-items:center}.justify-center{justify-content:center}.justify-between{justify-content:space-between}.gap-1{gap:4px}.gap-2{gap:8px}.overflow-y-auto{overflow-y:auto}.overflow-x-hidden{overflow-x:hidden}.rounded-full{border-radius:9999px}.rounded-xl{border-radius:.75rem}.border{border-width:1px}.border-transparent{border-color:transparent}.bg-gray-500{--tw-bg-opacity:1;background-color:rgb(107 114 128/var(--tw-bg-opacity))}.bg-opacity-75{--tw-bg-opacity:0.75}.p-4{padding:16px}.px-4{padding-left:16px;padding-right:16px}.py-3{padding-bottom:12px}.pt-3,.py-3{padding-top:12px}.text-center{text-align:center}.text-base{font-size:16px;line-height:24px}.text-sm{font-size:14px;line-height:20px}.font-bold{font-weight:700}.font-light{font-weight:300}.font-semibold{font-weight:600}.text-blue-400{--tw-text-opacity:1;color:rgb(96 165 250/var(--tw-text-opacity))}.shadow{--tw-shadow:0 1px 3px 0 rgba(0,0,0,.1),0 1px 2px -1px rgba(0,0,0,.1);--tw-shadow-colored:0 1px 3px 0 var(--tw-shadow-color),0 1px 2px -1px var(--tw-shadow-color);box-shadow:var(--tw-ring-offset-shadow,0 0 #0000),var(--tw-ring-shadow,0 0 #0000),var(--tw-shadow)}.dark\\:focus\\:outline-none:focus:is(.dark *){outline:2px solid transparent;outline-offset:2px}.dark\\:focus\\:ring-1:focus:is(.dark *){--tw-ring-offset-shadow:var(--tw-ring-inset) 0 0 0 var(--tw-ring-offset-width) var(--tw-ring-offset-color);--tw-ring-shadow:var(--tw-ring-inset) 0 0 0 calc(1px + var(--tw-ring-offset-width)) var(--tw-ring-color);box-shadow:var(--tw-ring-offset-shadow),var(--tw-ring-shadow),var(--tw-shadow,0 0 #0000)}.dark\\:focus\\:ring-gray-600:focus:is(.dark *){--tw-ring-opacity:1;--tw-ring-color:rgb(75 85 99/var(--tw-ring-opacity))}@media (min-width:640px){.sm\\:mx-auto{margin-left:auto;margin-right:auto}.sm\\:w-full{width:100%}.sm\\:max-w-lg{max-width:512px}}.inline-flex{display:inline-flex}.h-4{height:16px}.w-4{width:16px}.gap-x-2{column-gap:8px}.rounded-lg{border-radius:.5rem}.px-3{padding-left:12px;padding-right:12px}.py-2\\.5{padding-bottom:10px;padding-top:10px}.font-medium{font-weight:500}.disabled\\:pointer-events-none:disabled{pointer-events:none}.disabled\\:opacity-50:disabled{opacity:.5}.mt-0{margin-top:0}.mt-3{margin-top:12px}.max-h-0{max-height:0}.max-h-\\[500px\\]{max-height:500px}.max-w-52{max-width:208px}.max-w-7{max-width:28px}.rotate-0{--tw-rotate:0deg}.rotate-0,.rotate-180{transform:translate(var(--tw-translate-x),var(--tw-translate-y)) rotate(var(--tw-rotate)) skewX(var(--tw-skew-x)) skewY(var(--tw-skew-y)) scaleX(var(--tw-scale-x)) scaleY(var(--tw-scale-y))}.rotate-180{--tw-rotate:180deg}.gap-0\\.5{gap:2px}.gap-3{gap:12px}.gap-x-3\\.5{column-gap:14px}.overflow-hidden,.truncate{overflow:hidden}.truncate{text-overflow:ellipsis;white-space:nowrap}.border-b-\\[1px\\]{border-bottom-width:1px}.border-dashed{border-style:dashed}.border-blue-500{--tw-border-opacity:1;border-color:rgb(59 130 246/var(--tw-border-opacity))}.border-gray-200{--tw-border-opacity:1;border-color:rgb(229 231 235/var(--tw-border-opacity))}.border-gray-400{--tw-border-opacity:1;border-color:rgb(156 163 175/var(--tw-border-opacity))}.p-2{padding:8px}.py-2{padding-bottom:8px;padding-top:8px}.pb-1{padding-bottom:4px}.pb-1\\.5{padding-bottom:6px}.pb-5{padding-bottom:20px}.pe-4{padding-inline-end:16px}.ps-4{padding-inline-start:16px}.pt-5{padding-top:20px}.text-3xl{font-size:30px;line-height:36px}.uppercase{text-transform:uppercase}.text-blue-500{--tw-text-opacity:1;color:rgb(59 130 246/var(--tw-text-opacity))}.decoration-dashed{text-decoration-style:dashed}.duration-300{transition-duration:.3s}.duration-\\[0\\.25s\\]{transition-duration:.25s}.ease-in{transition-timing-function:cubic-bezier(.4,0,1,1)}.hover\\:bg-gray-300:hover{--tw-bg-opacity:1;background-color:rgb(209 213 219/var(--tw-bg-opacity))}.ml-auto,.mx-auto{margin-left:auto}.mr-auto{margin-right:auto}.w-60{width:240px}.pt-2{padding-top:8px}.text-4xl{font-size:36px;line-height:40px}.text-lg{font-size:18px;line-height:28px}.mb-0\\.5{margin-bottom:2px}.mb-2{margin-bottom:8px}.mb-5{margin-bottom:20px}.ml-auto{margin-left:auto}.inline-block{display:inline-block}.w-72{width:288px}.max-w-72{max-width:288px}.border-\\[3px\\]{border-width:3px}.border-current{border-color:currentColor}.border-t-transparent{border-top-color:transparent}.pb-2{padding-bottom:8px}.text-2xl{font-size:24px;line-height:32px}.text-slate-900{--tw-text-opacity:1;color:rgb(15 23 42/var(--tw-text-opacity))}.filter{filter:var(--tw-blur) var(--tw-brightness) var(--tw-contrast) var(--tw-grayscale) var(--tw-hue-rotate) var(--tw-invert) var(--tw-saturate) var(--tw-sepia) var(--tw-drop-shadow)}.dark\\:text-gray-300:is(.dark *){--tw-text-opacity:1;color:rgb(209 213 219/var(--tw-text-opacity))}.h-12{height:48px}.w-12{width:48px}.text-green-800{--tw-text-opacity:1;color:rgb(22 101 52/var(--tw-text-opacity))}.dark\\:text-green-200:is(.dark *){--tw-text-opacity:1;color:rgb(187 247 208/var(--tw-text-opacity))}.mb-10{margin-bottom:40px}.mt-10{margin-top:40px}.h-20{height:80px}.w-20{width:80px}.border-\\[4px\\]{border-width:4px}.w-auto{width:auto}.border-gray-300{--tw-border-opacity:1;border-color:rgb(209 213 219/var(--tw-border-opacity))}.border-orange-300{--tw-border-opacity:1;border-color:rgb(253 186 116/var(--tw-border-opacity))}.border-red-300{--tw-border-opacity:1;border-color:rgb(252 165 165/var(--tw-border-opacity))}.border-teal-300{--tw-border-opacity:1;border-color:rgb(94 234 212/var(--tw-border-opacity))}.border-yellow-300{--tw-border-opacity:1;border-color:rgb(253 224 71/var(--tw-border-opacity))}.bg-gray-100{--tw-bg-opacity:1;background-color:rgb(243 244 246/var(--tw-bg-opacity))}.bg-orange-100{--tw-bg-opacity:1;background-color:rgb(255 237 213/var(--tw-bg-opacity))}.bg-red-100{--tw-bg-opacity:1;background-color:rgb(254 226 226/var(--tw-bg-opacity))}.bg-teal-100{--tw-bg-opacity:1;background-color:rgb(204 251 241/var(--tw-bg-opacity))}.bg-yellow-100{--tw-bg-opacity:1;background-color:rgb(254 249 195/var(--tw-bg-opacity))}.px-1{padding-left:4px;padding-right:4px}.text-\\[10px\\]{font-size:10px}.text-gray-400{--tw-text-opacity:1;color:rgb(156 163 175/var(--tw-text-opacity))}.text-orange-600{--tw-text-opacity:1;color:rgb(234 88 12/var(--tw-text-opacity))}.text-red-600{--tw-text-opacity:1;color:rgb(220 38 38/var(--tw-text-opacity))}.text-teal-600{--tw-text-opacity:1;color:rgb(13 148 136/var(--tw-text-opacity))}.text-yellow-500{--tw-text-opacity:1;color:rgb(234 179 8/var(--tw-text-opacity))}.pointer-events-none{pointer-events:none}.inset-y-0{bottom:0;top:0}.ps-11{padding-inline-start:44px}.text-gray-500{--tw-text-opacity:1;color:rgb(107 114 128/var(--tw-text-opacity))}.peer:disabled~.peer-disabled\\:pointer-events-none{pointer-events:none}.peer:disabled~.peer-disabled\\:opacity-50{opacity:.5}.dark\\:border-transparent:is(.dark *){border-color:transparent}.right-\\[-2px\\]{right:-2px}.right-\\[-3px\\]{right:-3px}.top-\\[-2px\\]{top:-2px}.top-\\[-3px\\]{top:-3px}.h-1\\.5{height:6px}.h-3{height:12px}.h-6{height:24px}.w-1\\.5{width:6px}.w-3{width:12px}.max-w-6{max-width:24px}.border-2{border-width:2px}.border-blue-200{--tw-border-opacity:1;border-color:rgb(191 219 254/var(--tw-border-opacity))}.border-white{--tw-border-opacity:1;border-color:rgb(255 255 255/var(--tw-border-opacity))}.bg-green-500{--tw-bg-opacity:1;background-color:rgb(34 197 94/var(--tw-bg-opacity))}.bg-white{--tw-bg-opacity:1;background-color:rgb(255 255 255/var(--tw-bg-opacity))}.pb-3{padding-bottom:12px}.pt-0{padding-top:0}.text-red-500{--tw-text-opacity:1;color:rgb(239 68 68/var(--tw-text-opacity))}.hover\\:bg-gray-400:hover{--tw-bg-opacity:1;background-color:rgb(156 163 175/var(--tw-bg-opacity))}.hover\\:text-red-600:hover{--tw-text-opacity:1;color:rgb(220 38 38/var(--tw-text-opacity))}.group:hover .group-hover\\:border-blue-400{--tw-border-opacity:1;border-color:rgb(96 165 250/var(--tw-border-opacity))}.mt-1{margin-top:4px}.hidden{display:none}.min-w-\\[15rem\\]{min-width:15rem}.overflow-hidden,.truncate{overflow:hidden}.shadow-md{--tw-shadow:0 4px 6px -1px rgba(0,0,0,.1),0 2px 4px -2px rgba(0,0,0,.1);--tw-shadow-colored:0 4px 6px -1px var(--tw-shadow-color),0 2px 4px -2px var(--tw-shadow-color);box-shadow:var(--tw-ring-offset-shadow,0 0 #0000),var(--tw-ring-shadow,0 0 #0000),var(--tw-shadow)}.before\\:absolute:before{content:var(--tw-content);position:absolute}.before\\:-top-4:before{content:var(--tw-content);top:-16px}.before\\:start-0:before{content:var(--tw-content);inset-inline-start:0}.before\\:h-4:before{content:var(--tw-content);height:16px}.before\\:w-full:before{content:var(--tw-content);width:100%}.after\\:absolute:after{content:var(--tw-content);position:absolute}.after\\:-bottom-4:after{bottom:-16px;content:var(--tw-content)}.after\\:start-0:after{content:var(--tw-content);inset-inline-start:0}.after\\:h-4:after{content:var(--tw-content);height:16px}.after\\:w-full:after{content:var(--tw-content);width:100%}.end-0{inset-inline-end:0}.h-\\[20px\\]{height:20px}.w-\\[20px\\]{width:20px}.border-\\[2px\\]{border-width:2px}.pe-11{padding-inline-end:44px}.right-0{right:0}.right-2{right:8px}.top-2{top:8px}.top-52{top:208px}.z-0{z-index:0}.z-10{z-index:10}.z-20{z-index:20}.z-50{z-index:50}.m-auto{margin:auto}.ml-0{margin-left:0}.ml-\\[2px\\]{margin-left:2px}.mr-0{margin-right:0}.mr-2{margin-right:8px}.mr-3\\.5{margin-right:14px}.mt-2{margin-top:8px}.grid{display:grid}.h-0{height:0}.h-8{height:32px}.h-\\[46px\\]{height:46px}.h-auto{height:auto}.w-0{width:0}.w-16{width:64px}.w-52{width:208px}.w-6{width:24px}.w-8{width:32px}.w-\\[48px\\]{width:48px}.min-w-40{min-width:160px}.max-w-40{max-width:160px}@keyframes spin{to{transform:rotate(1turn)}}.animate-spin{animation:spin 1s linear infinite}.place-items-center{place-items:center}.text-nowrap{text-wrap:nowrap}.rounded-r-lg{border-bottom-right-radius:.5rem;border-top-right-radius:.5rem}.rounded-r-none{border-bottom-right-radius:0;border-top-right-radius:0}.border-\\[0px\\]{border-width:0}.p-3{padding:12px}.px-2{padding-left:8px;padding-right:8px}.pl-\\[11px\\]{padding-left:11px}.text-xs{font-size:12px;line-height:16px}.text-red-400{--tw-text-opacity:1;color:rgb(248 113 113/var(--tw-text-opacity))}.opacity-0{opacity:0}.transition-all{transition-duration:.15s;transition-property:all}.ease-in-out,.transition-all{transition-timing-function:cubic-bezier(.4,0,.2,1)}.hover\\:right-2:hover{right:8px}.hover\\:rounded-r-lg:hover{border-bottom-right-radius:.5rem;border-top-right-radius:.5rem}",buttonBaseCss=baseCss,ButtonBaseStyle0=buttonBaseCss,ButtonBase=proxyCustomElement(class extends H{constructor(){super(),this.__registerHost(),this.theme="default",this.darkMode=!1,this.titleBtn="Open modal",this.disabled=!1}componentDidRender(){const o=this.element.querySelector("svg");o&&(o.classList.add("flex-shrink-0","w-4","h-4","block"),o.removeAttribute("style"))}render(){return h("div",{key:"1048576f0a9839c56cac030b1de7899b25b5f39e",class:`theme-${this.theme}`},h("div",{key:"ea29f74a1f7e4268802c6e4aaca5867dfd2e4c9b",class:"animate-spin-loading active"}),h("button",{key:"71f84d47b11aa3971818b686f8dddb74e0d36eb0",disabled:this.disabled,type:"button",class:"nl-button py-2.5 px-3 w-full inline-flex justify-center items-center gap-x-2 text-sm font-medium rounded-lg disabled:opacity-50 disabled:pointer-events-none dark:focus:outline-none dark:focus:ring-1 dark:focus:ring-gray-600"},h("slot",{key:"91a91994e20dc10e3bbb2576e4214fa98533be8e",name:"icon-start"}),this.titleBtn))}get element(){return this}static get style(){return ButtonBaseStyle0}},[4,"button-base",{theme:[1025],darkMode:[1028,"dark-mode"],titleBtn:[1,"title-btn"],disabled:[4]}]);function defineCustomElement$q(){typeof customElements>"u"||["button-base"].forEach(o=>{"button-base"===o&&(customElements.get(o)||customElements.define(o,ButtonBase))})}defineCustomElement$q();const nlConfirmLogoutCss=baseCss,NlConfirmLogoutStyle0=nlConfirmLogoutCss,NlConfirmLogout$1=proxyCustomElement(class extends H{constructor(){super(),this.__registerHost(),this.handleLogoutBanner=createEvent(this,"handleLogoutBanner",7),this.handleBackUpModal=createEvent(this,"handleBackUpModal",7),this.nlCloseModal=createEvent(this,"nlCloseModal",7),this.titleModal="Delete keys?",this.description="Your profile keys are stored in this browser tab and will be deleted if you log out, and your profile will be inaccessible."}handleLogout(){this.handleLogoutBanner.emit(METHOD_MODULE.LOGOUT),this.nlCloseModal.emit()}handleCancel(){this.nlCloseModal.emit()}handleBackUp(){state.path=[CURRENT_MODULE.IMPORT_FLOW]}render(){return h("div",{key:"fe605f38f9d0a440fe53e21f19288c41e4762c22",class:"p-4 overflow-y-auto"},h("h1",{key:"84d14a59035515b2fd612d262400a038887a10d7",class:"nl-title font-bold text-center text-4xl"},this.titleModal),h("p",{key:"83ef73271c76309561be95e0207f8130d75a161c",class:"nl-description font-light text-center text-lg pt-2 max-w-96 mx-auto"},this.description),h("div",{key:"fce0f132846beb95dd9e41357f5ab87be7229a56",class:"mt-3 ml-auto mr-auto w-60 flex flex-col gap-2"},h("button-base",{key:"c4fc722a7c98d84e797963ed7fe928164411b701",onClick:()=>this.handleBackUp(),titleBtn:"Backup keys",theme:"lemonade"}),h("button-base",{key:"39df385a9a8dc3fcd74f4196d4191bc4a308a16d",onClick:()=>this.handleLogout(),theme:"crab",titleBtn:"Logout and delete keys"})))}static get style(){return NlConfirmLogoutStyle0}},[0,"nl-confirm-logout",{titleModal:[1,"title-modal"],description:[1]}]);function defineCustomElement$p(){typeof customElements>"u"||["nl-confirm-logout","button-base"].forEach(o=>{switch(o){case"nl-confirm-logout":customElements.get(o)||customElements.define(o,NlConfirmLogout$1);break;case"button-base":customElements.get(o)||defineCustomElement$q()}})}defineCustomElement$p();const nlConnectCss=baseCss,NlConnectStyle0=nlConnectCss,NlConnect=proxyCustomElement(class extends H{constructor(){super(),this.__registerHost(),this.nlNostrConnect=createEvent(this,"nlNostrConnect",7),this.nlNostrConnectDefault=createEvent(this,"nlNostrConnectDefault",7),this.titleWelcome="Connect to key store",this.authMethods=[],this.hasOTP=!1,this.connectionStringServices=[],this.isOpenAdvancedLogin=!1}handleChangeScreen(o){state.path=[...state.path,o]}handleOpenAdvanced(){this.isOpenAdvancedLogin=!this.isOpenAdvancedLogin}allowAuthMethod(o){return!this.authMethods.length||this.authMethods.includes(o)}componentWillLoad(){}handleOpenLink(o,s){o.preventDefault(),this.nlNostrConnect.emit(s)}handleConnectionString(){this.nlNostrConnectDefault.emit(),this.handleChangeScreen(CURRENT_MODULE.CONNECTION_STRING)}render(){const o=(this.isOpenAdvancedLogin?"rotate-180":"rotate-0")+" duration-300 flex-shrink-0 w-4 h-4 text-blue-500";return h(Fragment,{key:"a85f0a26b61b7e321025b7dd96e459a6c43958a9"},h("div",{key:"7af7ae501bed1bf028465e65f3caa3824a3948ca",class:"p-4 overflow-y-auto"},h("h1",{key:"7795a15c6d525d1b7ad0e6da63ad1889a64d6459",class:"nl-title font-bold text-center text-3xl"},this.titleWelcome)),h("div",{key:"cf5b947b22757334cbf92059dfc7ffaef0c95951",class:"p-4"},!!this.connectionStringServices.length&&h("div",{key:"c5de66ab74b14d69993dc20cf123777a3b8a016e",class:"max-w-96 mx-auto pt-5"},h("p",{key:"f7ac9e48789870264707bf39e3f1b2d73218aad5",class:"nl-description font-medium text-sm pb-1.5"},"Select key store:"),h("ul",{key:"07c1bd1bf9ffaa80f0868481ce22a8d5c73a345b",class:"p-2 rounded-lg border border-gray-200 flex flex-col w-full gap-0.5"},this.connectionStringServices.map(s=>h("li",null,h("a",{href:s.link,target:"_blank",onClick:r=>this.handleOpenLink(r,s),class:"flex items-center gap-x-3.5 w-full hover:bg-gray-300 flex cursor-pointer items-center gap-x-3.5 py-2 px-3 rounded-lg text-sm justify-between"},h("div",{class:"w-full max-w-7 h-7 flex relative"},h("div",{class:"uppercase font-bold w-full h-full rounded-full border border-gray-400 flex justify-center items-center"},s.img?h("img",{class:"w-full rounded-full",src:s.img,alt:s.name}):h("svg",{xmlns:"http://www.w3.org/2000/svg",fill:"none",viewBox:"0 0 24 24","stroke-width":"1.5",stroke:"#9ca3af",class:"w-4 h-4 block"},h("path",{"stroke-linecap":"round","stroke-linejoin":"round",d:"M15.75 5.25a3 3 0 0 1 3 3m3 0a6 6 0 0 1-7.029 5.912c-.563-.097-1.159.026-1.563.43L10.5 17.25H8.25v2.25H6v2.25H2.25v-2.818c0-.597.237-1.17.659-1.591l6.499-6.499c.404-.404.527-1 .43-1.563A6 6 0 1 1 21.75 8.25Z"})))),h("div",{class:"overflow-hidden flex flex-col w-full"},h("div",{class:"nl-title truncate overflow-hidden"},s.name)))))))),h("div",{key:"2a9094524ef58b138d04411484264a40ce42db7c",class:"ps-4 pe-4 overflow-y-auto"},h("p",{key:"d833546cba5fd4a904a0123e6e760b602fda0ff7",class:"nl-error font-light text-center text-sm max-w-96 mx-auto"},state.error)),h("div",{key:"700aa690c440f2685c9330feeb58986669b46f85",class:"max-w-52 mx-auto pb-5"},(this.allowAuthMethod("connect")||this.allowAuthMethod("readOnly"))&&h("div",{key:"058706b54702ac9ca3cd74a8096f521c211e5a16",class:"flex justify-center"},h("div",{key:"073f2567734817ba3cc8f34b32fa1a284d2b8ab1",onClick:()=>this.handleOpenAdvanced(),class:"text-blue-500 mt-3 decoration-dashed cursor-pointer inline-flex gap-2 items-center pb-1 border-dashed border-b-[1px] border-blue-500 text-sm font-light"},"Advanced",h("svg",{key:"d433319920bc751f771086bf726a3d5f1e31320e",class:o,xmlns:"http://www.w3.org/2000/svg",width:"24",height:"24",viewBox:"0 0 24 24",fill:"none",stroke:"currentColor","stroke-width":"2","stroke-linecap":"round","stroke-linejoin":"round"},h("path",{key:"4cc3a36807664b0402a26420c4979a68ba77df9c",d:"m6 9 6 6 6-6"})))),h("div",{key:"76dc95f39af78bd124e5f61309d96ee443d53f2f",class:(this.isOpenAdvancedLogin?"max-h-[500px] mt-3 duration-300":"max-h-0 mt-0 duration-[0.25s]")+" transition-max-height ease-in flex gap-3 flex-col overflow-hidden"},this.allowAuthMethod("connect")&&h("button-base",{key:"616d8de815233bc6264b51fa849fbf26d98758ed",titleBtn:"User name",onClick:()=>this.handleChangeScreen(CURRENT_MODULE.LOGIN)},h("svg",{key:"fa2f51ca2a111920d15a87106258c55a7b1961ff",style:{display:"none"},slot:"icon-start",xmlns:"http://www.w3.org/2000/svg",fill:"none",viewBox:"0 0 24 24","stroke-width":"2",stroke:"currentColor"},h("path",{key:"288dee2f9c21bde4471a7eebbf94c231c1acad12","stroke-linecap":"round","stroke-linejoin":"round",d:"M15.75 6a3.75 3.75 0 1 1-7.5 0 3.75 3.75 0 0 1 7.5 0ZM4.501 20.118a7.5 7.5 0 0 1 14.998 0A17.933 17.933 0 0 1 12 21.75c-2.676 0-5.216-.584-7.499-1.632Z"}))),this.allowAuthMethod("connect")&&h("button-base",{key:"8298c3ad602e2bc279ab084a5e5ea311fdc193e9",titleBtn:"Connection string",onClick:()=>this.handleConnectionString()},h("svg",{key:"b7f83a4b7fae0ff0965c2493aa70b09e1b1ab3d8",style:{display:"none"},slot:"icon-start",xmlns:"http://www.w3.org/2000/svg",fill:"none",viewBox:"0 0 24 24","stroke-width":"1.5",stroke:"currentColor"},h("path",{key:"d580fdbb1eee16439ffa4a46fa4f30cafbf0fd36","stroke-linecap":"round","stroke-linejoin":"round",d:"M3.75 4.875c0-.621.504-1.125 1.125-1.125h4.5c.621 0 1.125.504 1.125 1.125v4.5c0 .621-.504 1.125-1.125 1.125h-4.5A1.125 1.125 0 0 1 3.75 9.375v-4.5ZM3.75 14.625c0-.621.504-1.125 1.125-1.125h4.5c.621 0 1.125.504 1.125 1.125v4.5c0 .621-.504 1.125-1.125 1.125h-4.5a1.125 1.125 0 0 1-1.125-1.125v-4.5ZM13.5 4.875c0-.621.504-1.125 1.125-1.125h4.5c.621 0 1.125.504 1.125 1.125v4.5c0 .621-.504 1.125-1.125 1.125h-4.5A1.125 1.125 0 0 1 13.5 9.375v-4.5Z"}),h("path",{key:"ab90c206914cb2d6cae80b7e36ce45653c65b9b3","stroke-linecap":"round","stroke-linejoin":"round",d:"M6.75 6.75h.75v.75h-.75v-.75ZM6.75 16.5h.75v.75h-.75v-.75ZM16.5 6.75h.75v.75h-.75v-.75ZM13.5 13.5h.75v.75h-.75v-.75ZM13.5 19.5h.75v.75h-.75v-.75ZM19.5 13.5h.75v.75h-.75v-.75ZM19.5 19.5h.75v.75h-.75v-.75ZM16.5 16.5h.75v.75h-.75v-.75Z"}))),this.allowAuthMethod("connect")&&h("button-base",{key:"c923265e7da4bb6815cf91c54a4b393c19f3d16d",onClick:()=>this.handleChangeScreen(CURRENT_MODULE.LOGIN_BUNKER_URL),titleBtn:"Bunker URL"},h("svg",{key:"8c5bd04e91407a83d0021e4413ee58973b57aa54",style:{display:"none"},slot:"icon-start",xmlns:"http://www.w3.org/2000/svg",fill:"none",viewBox:"0 0 24 24","stroke-width":"1.5",stroke:"currentColor"},h("path",{key:"d115abfce6eee55572316a4cc2a808a176d17f46","stroke-linecap":"round","stroke-linejoin":"round",d:"M13.19 8.688a4.5 4.5 0 0 1 1.242 7.244l-4.5 4.5a4.5 4.5 0 0 1-6.364-6.364l1.757-1.757m13.35-.622 1.757-1.757a4.5 4.5 0 0 0-6.364-6.364l-4.5 4.5a4.5 4.5 0 0 0 1.242 7.244"}))))))}static get style(){return NlConnectStyle0}},[0,"nl-connect",{titleWelcome:[1,"title-welcome"],authMethods:[16],hasOTP:[4,"has-o-t-p"],connectionStringServices:[16],isOpenAdvancedLogin:[32]}]);function defineCustomElement$o(){typeof customElements>"u"||["nl-connect","button-base"].forEach(o=>{switch(o){case"nl-connect":customElements.get(o)||customElements.define(o,NlConnect);break;case"button-base":customElements.get(o)||defineCustomElement$q()}})}defineCustomElement$o();const nlIframeCss=baseCss,NlIframeStyle0=nlIframeCss,NlConfirmLogout=proxyCustomElement(class extends H{constructor(){super(),this.__registerHost(),this.nlCloseModal=createEvent(this,"nlCloseModal",7),this.titleModal="Confirm",this.description="Your profile keys are stored in this browser tab and will be deleted if you log out, and your profile will be inaccessible.",this.iframeUrl=""}handleCancel(){this.nlCloseModal.emit()}render(){return h("div",{key:"36ee9fd43bbb16768b7634783781ecffb1c9432a",class:"p-4 overflow-y-auto"},h("div",{key:"1634e1fd37bc44030f22bfdab9f7deec2806731b",class:"mt-3 flex flex-col gap-2"},this.iframeUrl&&h("iframe",{key:"2b1ab3032b152fb109f3531bb7600bb76aa1a562",src:this.iframeUrl,style:{width:"100%",height:"600px",border:"1px solid #ccc",borderRadius:"8px"}})))}static get style(){return NlIframeStyle0}},[0,"nl-iframe",{titleModal:[1,"title-modal"],description:[1],iframeUrl:[1,"iframe-url"]}]);function defineCustomElement$n(){typeof customElements>"u"||["nl-iframe"].forEach(o=>{"nl-iframe"===o&&(customElements.get(o)||customElements.define(o,NlConfirmLogout))})}defineCustomElement$n();const nlSelectCss=baseCss,NlSelectStyle0=nlSelectCss,NlSelect=proxyCustomElement(class extends H{constructor(){super(),this.__registerHost(),this.selectDomain=createEvent(this,"selectDomain",7),this.isOpen=!1,this.value=null,this.options=void 0,this.selected=void 0,this.mode=!1,this.darkMode=!1,this.themeState="default",this.theme="default"}handleWindowClick(){this.wrapperRef.querySelector(".listClass")&&(this.isOpen=!1)}toggleDropdown(){this.isOpen=!this.isOpen,this.calculateDropdownPosition()}watchPropHandler(o){this.themeState=o}watchModeHandler(o){this.mode=o}connectedCallback(){this.themeState=this.theme,this.mode=this.darkMode,this.value=this.options[this.selected],this.selectDomain.emit(this.value.value)}calculateDropdownPosition(){if(this.isOpen&&this.buttonRef){const o=this.buttonRef.getBoundingClientRect();this.ulRef.style.top=`${o.height}px`}}handleChange(o){this.value=o,this.isOpen=!1,this.selectDomain.emit(this.value.value)}render(){const o=(this.isOpen?"listClass":"hidden")+" min-w-[15rem] nl-select-list absolute left-0 shadow-md rounded-lg p-2 mt-1 after:h-4 after:absolute after:-bottom-4 after:start-0 after:w-full before:h-4 before:absolute before:-top-4 before:start-0 before:w-full",s=(this.isOpen?"rotate-180":"rotate-0")+" duration-300 flex-shrink-0 w-4 h-4 text-gray-500";return h("div",{key:"c86084c50712455e04682a4392e490bc0e20eb1d",class:`theme-${this.themeState}`},h("div",{key:"a90d9b4af52845a9971c39cec69c13493d511381",class:"relative",ref:r=>this.wrapperRef=r},h("button",{key:"1391137997bf8fcd0a5466cd9fa20c79b4ce27ba",ref:r=>this.buttonRef=r,onClick:()=>this.toggleDropdown(),type:"button",class:"nl-select peer py-3 px-4 flex items-center w-full justify-between border-transparent rounded-lg text-sm disabled:opacity-50 disabled:pointer-events-none dark:border-transparent"},h("span",{key:"224425ab92ba3599595924972e98a0fc9cb1a189",class:"truncate overflow-hidden"},this.value.name),h("svg",{key:"8eb2a2b552cb9ea36fb1abc61d804efb423afda6",class:s,xmlns:"http://www.w3.org/2000/svg",width:"24",height:"24",viewBox:"0 0 24 24",fill:"none",stroke:"currentColor","stroke-width":"2","stroke-linecap":"round","stroke-linejoin":"round"},h("path",{key:"feea1a7f54f4a111b7bf01e3945445311b97ab82",d:"m6 9 6 6 6-6"}))),h("ul",{key:"fca4982f04f4133d5c2a2f613a7e7d977dd5c241",ref:r=>this.ulRef=r,class:o},this.options.map(r=>h("li",{onClick:()=>this.handleChange(r),class:"nl-select-option flex cursor-pointer items-center gap-x-3.5 py-2 px-3 rounded-lg text-sm"},r.name)))))}get element(){return this}static get watchers(){return{theme:["watchPropHandler"],darkMode:["watchModeHandler"]}}static get style(){return NlSelectStyle0}},[0,"nl-select",{options:[16],selected:[2],darkMode:[4,"dark-mode"],theme:[1],isOpen:[32],value:[32],mode:[32],themeState:[32]},[[8,"click","handleWindowClick"]],{theme:["watchPropHandler"],darkMode:["watchModeHandler"]}]);function defineCustomElement$m(){typeof customElements>"u"||["nl-select"].forEach(o=>{"nl-select"===o&&(customElements.get(o)||customElements.define(o,NlSelect))})}defineCustomElement$m();const nlImportFlowCss=baseCss,NlImportFlowStyle0=nlImportFlowCss,NlImportFlow$1=proxyCustomElement(class extends H{constructor(){super(),this.__registerHost(),this.nlImportAccount=createEvent(this,"nlImportAccount",7),this.nlExportKeys=createEvent(this,"nlExportKeys",7),this.titleInfo="Back up your keys",this.titleImport="Choose a service",this.services=[],this.isContinued=!1,this.isKeyBackup=!1,this.isCopy=!1}handleDomainSelect(o){const s=this.services.find(r=>r.domain===o.detail);state.nlImport=s}handleCreateAccount(o){o.preventDefault(),this.nlImportAccount.emit(state.nlImport)}handleContinue(){this.isContinued=!0}handleContinueKeyBackup(){this.isKeyBackup=!0}copyToClipboard(){var o=this;return(0,_home_runner_work_angor_hub_angor_hub_node_modules_angular_builders_custom_webpack_node_modules_babel_runtime_helpers_esm_asyncToGenerator_js__WEBPACK_IMPORTED_MODULE_1__.A)(function*(){o.nlExportKeys.emit(),o.isCopy=!0,setTimeout(()=>{o.isCopy=!1},1500)})()}render(){if(!this.isContinued&&!this.isKeyBackup)return h("div",{class:"p-4 overflow-y-auto"},h("h1",{class:"nl-title font-bold text-center text-2xl"},this.titleInfo),h("p",{class:"nl-description font-light text-sm pt-2 pb-2 max-w-96 mx-auto"},"Nostr profiles are controlled by cryptographic keys.",h("br",null),h("br",null),"Your keys are currently only stored in this browser tab, and may be lost if you close it.",h("br",null),h("br",null),"You should backup your keys.",h("br",null),h("br",null),"We recommend to import your keys into a key store service, to protect them and to use with other apps."),h("div",{class:"ml-auto mr-auto mb-2 w-72"},h("button-base",{onClick:()=>this.handleContinue(),titleBtn:"Import to key store"})),h("div",{class:"ml-auto mr-auto w-72"},h("button-base",{onClick:()=>this.handleContinueKeyBackup(),titleBtn:"Export keys"})));if(this.isKeyBackup)return h("div",{class:"p-4 overflow-y-auto"},h("h1",{class:"nl-title font-bold text-center text-2xl"},"Key export"),h("p",{class:"nl-description font-light text-sm pt-2 pb-2 max-w-96 mx-auto"},"Copy your keys and store them in a safe place, like a password manager.",h("br",null),h("br",null),"You can sign into other Nostr apps by pasting your keys into them.",h("br",null),h("br",null),"Your keys must be kept secret, never share them with anyone."),h("div",{class:"max-w-72 mx-auto"},h("div",{class:"ml-auto mr-auto mb-2 w-72"},h("button-base",{onClick:()=>this.copyToClipboard(),titleBtn:this.isCopy?"Copied!":"Copy to clipboard"}))));const o=this.services.filter(s=>s.canImport).map(s=>({name:s.domain,value:s.domain}));return h(Fragment,null,h("div",{class:"p-4 overflow-y-auto"},h("h1",{class:"nl-title font-bold text-center text-2xl"},this.titleImport),h("p",{class:"nl-description font-light text-center text-sm pt-2 max-w-96 mx-auto"},"Your Nostr keys will be imported into the service you choose. You will manage your keys on their website.")),h("div",{class:"max-w-72 mx-auto mb-5"},h("div",{class:"mb-0.5"},h("nl-select",{onSelectDomain:s=>this.handleDomainSelect(s),selected:0,options:o})),h("p",{class:"nl-title font-light text-sm mb-2"},"Default provider is a fine choice to start with."),h("div",{class:"ps-4 pe-4 overflow-y-auto"},h("p",{class:"nl-error font-light text-center text-sm max-w-96 mx-auto"},state.error)),h("button-base",{disabled:state.isLoading,onClick:s=>this.handleCreateAccount(s),titleBtn:"Start importing"},state.isLoading?h("span",{slot:"icon-start",class:"animate-spin-loading inline-block w-4 h-4 border-[3px] border-current border-t-transparent text-slate-900 dark:text-gray-300 rounded-full",role:"status","aria-label":"loading"}):h("svg",{slot:"icon-start",style:{display:"none"},xmlns:"http://www.w3.org/2000/svg",fill:"none",viewBox:"0 0 24 24","stroke-width":"1.5",stroke:"currentColor"},h("path",{"stroke-linecap":"round","stroke-linejoin":"round",d:"M18 7.5v3m0 0v3m0-3h3m-3 0h-3m-2.25-4.125a3.375 3.375 0 1 1-6.75 0 3.375 3.375 0 0 1 6.75 0ZM3 19.235v-.11a6.375 6.375 0 0 1 12.75 0v.109A12.318 12.318 0 0 1 9.374 21c-2.331 0-4.512-.645-6.374-1.766Z"})))))}static get style(){return NlImportFlowStyle0}},[0,"nl-import-flow",{titleInfo:[1025,"title-info"],titleImport:[1,"title-import"],services:[16],isContinued:[32],isKeyBackup:[32],isCopy:[32]}]);function defineCustomElement$l(){typeof customElements>"u"||["nl-import-flow","button-base","nl-select"].forEach(o=>{switch(o){case"nl-import-flow":customElements.get(o)||customElements.define(o,NlImportFlow$1);break;case"button-base":customElements.get(o)||defineCustomElement$q();break;case"nl-select":customElements.get(o)||defineCustomElement$m()}})}defineCustomElement$l();const nlInfoCss=baseCss,NlInfoStyle0=nlInfoCss,NlInfo=proxyCustomElement(class extends H{constructor(){super(),this.__registerHost()}render(){return h("div",{key:"7463f42c27643903a9d6fb0160fbabe833679fcb",class:"p-4 overflow-y-auto"},h("svg",{key:"86c5f04f87b21553f3512d289425996b46eb6c57",class:"w-12 h-12 mx-auto mb-2",width:"225",height:"224",viewBox:"0 0 225 224",fill:"none",xmlns:"http://www.w3.org/2000/svg"},h("rect",{key:"6be61e0b2ff3d3f13e617e9b1df073fbe3b5678b",width:"224.047",height:"224",rx:"64",fill:"#6951FA"}),h("path",{key:"0c0aff7d5143022fe857de141cdae31397c3c2f4",d:"M162.441 135.941V88.0593C170.359 85.1674 176 77.5348 176 68.6696C176 57.2919 166.708 48 155.33 48C143.953 48 134.661 57.2444 134.661 68.6696C134.661 77.5822 140.302 85.1674 148.219 88.0593V135.941C147.698 136.13 147.176 136.367 146.655 136.604L87.3956 77.3452C88.6282 74.6904 89.2919 71.7511 89.2919 68.6696C89.2919 57.2444 80.0474 48 68.6696 48C57.2919 48 48 57.2444 48 68.6696C48 77.5822 53.6415 85.1674 61.5585 88.0593V135.941C53.6415 138.833 48 146.465 48 155.33C48 166.708 57.2444 176 68.6696 176C80.0948 176 89.3393 166.708 89.3393 155.33C89.3393 146.418 83.6978 138.833 75.7807 135.941V88.0593C76.3022 87.8696 76.8237 87.6326 77.3452 87.3956L136.604 146.655C135.372 149.31 134.708 152.249 134.708 155.33C134.708 166.708 143.953 176 155.378 176C166.803 176 176.047 166.708 176.047 155.33C176.047 146.418 170.406 138.833 162.489 135.941H162.441Z",fill:"white"})),h("h1",{key:"3a89ee5051e2d74945347dec6055749cec126f27",class:"nl-title font-bold text-center text-4xl"},"Nostr ",h("span",{key:"96a49c22dffa4a30639f387a949d7695604c6a1f",class:"font-light"},"Login")),h("p",{key:"a6dded720da9db673173a1ff02bc5544e6a66d38",class:"text-green-800 dark:text-green-200 font-light text-center text-lg pt-2 max-w-96 mx-auto"},"Version: 1.6.12"),h("p",{key:"9d9dbd36ade753d30db448139dc057921f29697d",class:"nl-description font-light text-center text-lg pt-2 max-w-96 mx-auto"},"Learn more about Nostr"," ",h("a",{key:"1811ad4f1acda7f5235566ea6f2ce8e70c62c91c",target:"_blank",href:"https://nostr.how"},"here"),".",h("br",{key:"127a6127e71f43caa1c262c6ec8108a5a6f40774"}),"This is an"," ",h("a",{key:"0e18839f8577229533eb2d2ef00f8657e6396aa1",target:"_blank",href:"https://github.com/nostrband/nostr-login"},"open-source")," ","tool by"," ",h("a",{key:"9affd14ad9dedae3e5d269a1477343eae63cd46b",target:"_blank",href:"https://nostr.band"},"Nostr.Band"),"."))}static get style(){return NlInfoStyle0}},[0,"nl-info"]);function defineCustomElement$k(){typeof customElements>"u"||["nl-info"].forEach(o=>{"nl-info"===o&&(customElements.get(o)||customElements.define(o,NlInfo))})}defineCustomElement$k();const nlInfoExtensionCss=baseCss,NlInfoExtensionStyle0=nlInfoExtensionCss,NlInfoExtension=proxyCustomElement(class extends H{constructor(){super(),this.__registerHost()}render(){return h("div",{key:"9335feb745c6d09a213a2e771c40262036341b54",class:"p-4 overflow-y-auto"},state.isLoadingExtension?h("div",null,h("h1",{class:"nl-title font-bold text-center text-4xl"},"Signing in..."),h("div",{class:"mt-10 mb-10 ml-auto mr-auto w-20"},h("span",{slot:"icon-start",class:"animate-spin-loading ml-auto mr-auto inline-block w-20 h-20 border-[4px] border-current border-t-transparent text-slate-900 dark:text-gray-300 rounded-full",role:"status","aria-label":"loading"})),h("div",{class:"ps-4 pe-4 overflow-y-auto"},h("p",{class:"nl-error font-light text-center text-sm max-w-96 mx-auto"},state.error))):h("div",null,h("h1",{class:"nl-title font-bold text-center text-4xl"},"Install browser extension!"),h("p",{class:"nl-description font-light text-center text-lg pt-2 max-w-96 mx-auto"},"Try"," ",h("a",{href:"https://getalby.com",target:"_blank"},"Alby"),","," ",h("a",{href:"https://chromewebstore.google.com/detail/nos2x/kpgefcfmnafjgpblomihpgmejjdanjjp",target:"_blank"},"nos2x")," ","or"," ",h("a",{href:"https://apps.apple.com/us/app/nostore/id1666553677",target:"_blank"},"Nostore"))))}static get style(){return NlInfoExtensionStyle0}},[0,"nl-info-extension"]);function defineCustomElement$j(){typeof customElements>"u"||["nl-info-extension"].forEach(o=>{"nl-info-extension"===o&&(customElements.get(o)||customElements.define(o,NlInfoExtension))})}defineCustomElement$j();const nlLoadingCss=baseCss,NlLoadingStyle0=nlLoadingCss,NlLoading=proxyCustomElement(class extends H{constructor(){super(),this.__registerHost(),this.stopFetchHandler=createEvent(this,"stopFetchHandler",7),this.handleContinue=createEvent(this,"handleContinue",7),this.path=void 0}handleStop(o){o.preventDefault(),this.stopFetchHandler.emit()}handleContinueClick(o){o.preventDefault(),this.handleContinue.emit()}render(){let o="Connecting...",s="Establishing connection to your key storage.";this.path===CURRENT_MODULE.LOCAL_SIGNUP?(o="Creating...",s="Publishing your profile on Nostr."):state.authUrl&&(state.isLoading?(o="Confirming...",s="Please confirm the connection in your key storage app."):(o="Almost ready!",s="Continue to confirm the connection to your key storage."));const r=this.path!==CURRENT_MODULE.LOCAL_SIGNUP,i=!state.isLoading&&state.iframeUrl&&state.authUrl,a=`${state.iframeUrl}?connect=${encodeURIComponent(state.authUrl)}`;return h("div",{key:"516866bac0ab965ad91fa153040e38cc94ecfe43",class:"p-4 overflow-y-auto"},h("h1",{key:"51fffb5a84be838536699741d19eb072d4318517",class:"nl-title font-bold text-center text-4xl"},o),h("p",{key:"8c0825a89ca531b74d1fb11fa06632b9bddf11b4",class:"nl-description font-light text-center text-lg pt-2 max-w-96 mx-auto"},s),!state.authUrl&&state.isLoading&&h("div",{key:"5b39a21b600a0524d7eff2885fa9b048b76daf8b",class:"mt-10 mb-10 ml-auto mr-auto w-20"},h("span",{key:"6ac53666049efdd495197b4c57536a3e09969cdb",slot:"icon-start",class:"animate-spin-loading ml-auto mr-auto inline-block w-20 h-20 border-[4px] border-current border-t-transparent text-slate-900 dark:text-gray-300 rounded-full",role:"status","aria-label":"loading"})),h("div",{key:"1a7211d6d3d9f6e14ff02a3605c6c7b1d2dbff09",class:"ps-4 pe-4 overflow-y-auto"},h("p",{key:"678cc1522ff896809fbc0309966497aafb308a36",class:"nl-error font-light text-center text-sm max-w-96 mx-auto"},state.error)),a&&h("div",{key:"6b68b0afd47bb420e142d6cefbe5fb286a6871be",class:"mt-3 ml-auto mr-auto w-72 flex justify-center"},h("iframe",{key:"69526e3b7af7d255b00f2ba1aeb9f688261958eb",src:a,width:"180px",height:"80px",style:{display:i?"block":"none"}})),!i&&r&&h("div",{key:"ea17236efcb5ae4aebec89508337a12f682e35cd",class:"mt-3 ml-auto mr-auto w-72"},h("button-base",{key:"7c6a62128ece1a50a5e01df43f8948f95f42fab2",onClick:c=>{state.authUrl&&!state.isLoading?this.handleContinueClick(c):this.handleStop(c)},titleBtn:state.isLoading?"Cancel":"Continue"})))}static get style(){return NlLoadingStyle0}},[0,"nl-loading",{path:[1]}]);function defineCustomElement$i(){typeof customElements>"u"||["nl-loading","button-base"].forEach(o=>{switch(o){case"nl-loading":customElements.get(o)||customElements.define(o,NlLoading);break;case"button-base":customElements.get(o)||defineCustomElement$q()}})}defineCustomElement$i();const nlLocalSignupCss=baseCss,NlLocalSignupStyle0=nlLocalSignupCss,NlLocalSignup=proxyCustomElement(class extends H{constructor(){super(),this.__registerHost(),this.nlLocalSignup=createEvent(this,"nlLocalSignup",7),this.fetchHandler=createEvent(this,"fetchHandler",7),this.titleSignup="Create Nostr profile",this.description="Choose any username, you can always change it later.",this.isAvailable=!1}handleInputChange(o){state.nlSignup.signupName=o.target.value}handleCreateAccount(o){o.preventDefault(),this.nlLocalSignup.emit(`${state.nlSignup.signupName}`)}render(){return h(Fragment,{key:"1ef0db8a3af10d6bd50c0ee084968abcef035b31"},h("div",{key:"966dbcd09fc2da235a817cbcf01b75e64ba2a3df",class:"p-4 overflow-y-auto"},h("h1",{key:"121ad8a12bb0d30785e26261993c73af716da22a",class:"nl-title font-bold text-center text-2xl"},this.titleSignup),h("p",{key:"6758bc49ee96973718cb301a96ce26949c446512",class:"nl-description font-light text-center text-sm pt-2 max-w-96 mx-auto"},this.description)),h("div",{key:"e8354901c534454753d055542226b56ae7a3ec67",class:"max-w-72 mx-auto"},h("div",{key:"2a84cdb7a830431318ddb3a32c10476ab7aa98c8",class:"relative mb-2"},h("input",{key:"50c84d948104ac51b647b941f1e086f4eecf03d9",onInput:o=>this.handleInputChange(o),type:"text",class:"nl-input peer py-3 px-4 ps-11 block w-full border-transparent rounded-lg text-sm disabled:opacity-50 disabled:pointer-events-none dark:border-transparent",placeholder:"Enter username",value:state.nlSignup.signupName}),h("div",{key:"8c52f3d644a8a0cd278af7646e9dbb0998b56afe",class:"absolute inset-y-0 start-0 flex items-center pointer-events-none ps-4 peer-disabled:opacity-50 peer-disabled:pointer-events-none"},h("svg",{key:"8923dc1949a04c7a10398db3c1211d00ce7fe925",xmlns:"http://www.w3.org/2000/svg",fill:"none",viewBox:"0 0 24 24","stroke-width":"2",stroke:this.isAvailable?"#00cc00":"currentColor",class:"flex-shrink-0 w-4 h-4 text-gray-500"},h("path",{key:"e3303cbea9146cb1a66e47d5ecf51da5a4a2e8b7","stroke-linecap":"round","stroke-linejoin":"round",d:"M15.75 6a3.75 3.75 0 1 1-7.5 0 3.75 3.75 0 0 1 7.5 0ZM4.501 20.118a7.5 7.5 0 0 1 14.998 0A17.933 17.933 0 0 1 12 21.75c-2.676 0-5.216-.584-7.499-1.632Z"})))),h("div",{key:"916d7e92cea31d802b74ce71dd202b7ae5f84ed8",class:"ps-4 pe-4 overflow-y-auto"},h("p",{key:"9bb8ffd3c9a7c2d62f700af314305d6403e9b54d",class:"nl-error font-light text-center text-sm max-w-96 mx-auto"},state.error)),h("button-base",{key:"dcd3530cb7878ec853ea1985cecfda1e03ab8011",disabled:state.isLoading,onClick:o=>this.handleCreateAccount(o),titleBtn:"Create profile"},state.isLoading?h("span",{slot:"icon-start",class:"animate-spin-loading inline-block w-4 h-4 border-[3px] border-current border-t-transparent text-slate-900 dark:text-gray-300 rounded-full",role:"status","aria-label":"loading"}):h("svg",{slot:"icon-start",style:{display:"none"},xmlns:"http://www.w3.org/2000/svg",fill:"none",viewBox:"0 0 24 24","stroke-width":"1.5",stroke:"currentColor"},h("path",{"stroke-linecap":"round","stroke-linejoin":"round",d:"M18 7.5v3m0 0v3m0-3h3m-3 0h-3m-2.25-4.125a3.375 3.375 0 1 1-6.75 0 3.375 3.375 0 0 1 6.75 0ZM3 19.235v-.11a6.375 6.375 0 0 1 12.75 0v.109A12.318 12.318 0 0 1 9.374 21c-2.331 0-4.512-.645-6.374-1.766Z"})))))}static get style(){return NlLocalSignupStyle0}},[0,"nl-local-signup",{titleSignup:[1,"title-signup"],description:[1],isAvailable:[32]}]);function defineCustomElement$h(){typeof customElements>"u"||["nl-local-signup","button-base"].forEach(o=>{switch(o){case"nl-local-signup":customElements.get(o)||customElements.define(o,NlLocalSignup);break;case"button-base":customElements.get(o)||defineCustomElement$q()}})}defineCustomElement$h();const NlLoginStatus=proxyCustomElement(class extends H{constructor(){super(),this.__registerHost(),this.info=void 0}render(){let o="",s="";if("extension"===this.info.authMethod)o="Extension",s="border-yellow-300 text-yellow-500 bg-yellow-100";else if("readOnly"===this.info.authMethod)o="Read only",s="border-gray-300 text-gray-400 bg-gray-100";else if("connect"===this.info.authMethod)o="Connect",s="border-teal-300 text-teal-600 bg-teal-100";else if("local"===this.info.authMethod)o="Temporary",s="border-red-300 text-red-600 bg-red-100";else{if("otp"!==this.info.authMethod)throw console.log("unknown auth method",this.info),new Error("Unknown auth method");o="Delegated",s="border-orange-300 text-orange-600 bg-orange-100"}return h("div",{key:"f7d43062e3d372b26fd7e9c462eabad823b762e1"},h("span",{key:"c79aafe47bf945f5c6bf26aa230debc4d950be71",class:`${s} rounded-xl border w-auto text-[10px] px-1 `},o))}},[0,"nl-login-status",{info:[16]}]);function defineCustomElement$g(){typeof customElements>"u"||["nl-login-status"].forEach(o=>{"nl-login-status"===o&&(customElements.get(o)||customElements.define(o,NlLoginStatus))})}defineCustomElement$g();const nlOtpMigrateCss=baseCss,NlOtpMigrateStyle0=nlOtpMigrateCss,NlImportFlow=proxyCustomElement(class extends H{constructor(){super(),this.__registerHost(),this.nlImportAccount=createEvent(this,"nlImportAccount",7),this.titleInfo="Import keys to storage service",this.titleImport="Choose a service",this.textImport="You will be prompted to import keys to the chosen service, and this website will connect to your keys.",this.services=[]}handleDomainSelect(o){const s=this.services.find(r=>r.domain===o.detail);state.nlImport=s}handleCreateAccount(o){o.preventDefault(),this.nlImportAccount.emit(state.nlImport)}render(){const o=this.services.filter(s=>s.canImport).map(s=>({name:s.domain,value:s.domain}));return h(Fragment,{key:"d27cbfa870975b4f9f0c6350ff6424e34b19dfad"},h("div",{key:"22618ac8a4e7cc53e111cfa47a7db3163ccc43ef",class:"p-4 overflow-y-auto"},h("h1",{key:"ebc3dc11334fa49479a1d071cf9a89bf204ca8ff",class:"nl-title font-bold text-center text-2xl"},this.titleImport),h("p",{key:"70795495de8e8f69488b2cebb2f8c5f1c2ace243",class:"nl-description font-light text-center text-sm pt-2 max-w-96 mx-auto"},this.textImport)),h("div",{key:"a9f4df9d99623c686d22ed200bddb7657984a4f8",class:"max-w-72 mx-auto mb-5"},h("div",{key:"c9a0fedecd1e036f9a84a12aaf44ac6fd8bde10b",class:"mb-0.5"},h("nl-select",{key:"3db03a9a4fd78f544f670c6b1917af67ca818696",onSelectDomain:s=>this.handleDomainSelect(s),selected:0,options:o})),h("p",{key:"fc392301b3553c3fea01ab17341d8e0c829af408",class:"nl-title font-light text-sm mb-2"},"Default provider is a fine choice to start with."),h("div",{key:"e0dd51b7f1f9fe7ca367f309ea945cf5feffedf2",class:"ps-4 pe-4 overflow-y-auto"},h("p",{key:"4316dfbf51fb06b68f55d34bffe4450c29fc273c",class:"nl-error font-light text-center text-sm max-w-96 mx-auto"},state.error)),h("button-base",{key:"dfbd68892ba44c72d4c319725dc82cf3a1af7d96",disabled:state.isLoading,onClick:s=>this.handleCreateAccount(s),titleBtn:"Start importing"},state.isLoading?h("span",{slot:"icon-start",class:"animate-spin-loading inline-block w-4 h-4 border-[3px] border-current border-t-transparent text-slate-900 dark:text-gray-300 rounded-full",role:"status","aria-label":"loading"}):h("svg",{slot:"icon-start",style:{display:"none"},xmlns:"http://www.w3.org/2000/svg",fill:"none",viewBox:"0 0 24 24","stroke-width":"1.5",stroke:"currentColor"},h("path",{"stroke-linecap":"round","stroke-linejoin":"round",d:"M18 7.5v3m0 0v3m0-3h3m-3 0h-3m-2.25-4.125a3.375 3.375 0 1 1-6.75 0 3.375 3.375 0 0 1 6.75 0ZM3 19.235v-.11a6.375 6.375 0 0 1 12.75 0v.109A12.318 12.318 0 0 1 9.374 21c-2.331 0-4.512-.645-6.374-1.766Z"})))))}static get style(){return NlOtpMigrateStyle0}},[0,"nl-otp-migrate",{titleInfo:[1025,"title-info"],titleImport:[1,"title-import"],textImport:[1,"text-import"],services:[16]}]);function defineCustomElement$f(){typeof customElements>"u"||["nl-otp-migrate","button-base","nl-select"].forEach(o=>{switch(o){case"nl-otp-migrate":customElements.get(o)||customElements.define(o,NlImportFlow);break;case"button-base":customElements.get(o)||defineCustomElement$q();break;case"nl-select":customElements.get(o)||defineCustomElement$m()}})}defineCustomElement$f();const nlPreviouslyLoggedCss=baseCss,NlPreviouslyLoggedStyle0=nlPreviouslyLoggedCss,NlPreviouslyLogged=proxyCustomElement(class extends H{constructor(){super(),this.__registerHost(),this.nlSwitchAccount=createEvent(this,"nlSwitchAccount",7),this.nlLoginRecentAccount=createEvent(this,"nlLoginRecentAccount",7),this.nlRemoveRecent=createEvent(this,"nlRemoveRecent",7),this.titlePage="Your profiles",this.description="Switch between active profiles or choose a recent one for fast login.",this.accounts=[],this.recents=[]}handleGoToWelcome(){state.path=[CURRENT_MODULE.WELCOME]}switchToWelcomeIfEmpty(){this.recents.length||this.accounts.length||(state.path=[CURRENT_MODULE.WELCOME])}watchAccounts(){this.switchToWelcomeIfEmpty()}watchRecents(){this.switchToWelcomeIfEmpty()}handleRemoveRecent(o){this.nlRemoveRecent.emit(o)}handleSwitch(o){this.nlSwitchAccount.emit(o)}handleLoginRecentAccount(o){this.nlLoginRecentAccount.emit(o)}render(){return h(Fragment,{key:"0b747732fe31ffb2d687859a8d5f5452de06cd82"},h("div",{key:"b696865acec55c2dc0f6f3ecf6360028f3911136",class:"p-4 pt-0 overflow-y-auto"},h("h1",{key:"156d95e32b1f14cdccfeabb2cb518bbba51b5da6",class:"nl-title font-bold text-center text-4xl"},this.titlePage),h("p",{key:"1d07d29dda5338c71c7831d4550c99af8717012d",class:"nl-description font-light text-center text-lg pt-2 max-w-96 mx-auto"},this.description)),h("div",{key:"3776d52ca658395479d7aaba1d96b707b144da5d",class:"p-4"},!!this.accounts.length&&h("div",{key:"77d80f7e11fd0ad09c5fa13c8b39939a9c011641",class:"max-w-96 mx-auto"},h("p",{key:"f32b9358755c561781e840383a2bc6b2bfe5c392",class:"nl-description font-medium text-sm pb-1.5"},"Active profiles"),h("ul",{key:"789082d6f3ad3d75ebe461cde35846d0ff37e912",class:"p-2 rounded-lg border border-blue-200 flex flex-col w-full gap-0.5"},this.accounts.map(o=>{const s=!!o?.picture,r=o.name||o.nip05||o.pubkey,i=!!r;return h("li",{onClick:()=>this.handleSwitch(o),class:"group hover:bg-gray-400 flex cursor-pointer gap-x-3.5 py-2 px-3 rounded-lg text-sm items-center justify-between"},h("div",{class:"flex items-center gap-x-3.5 w-full"},h("div",{class:"w-full max-w-7 h-7 flex relative"},h("div",{class:"absolute top-[-2px] right-[-2px] bg-white border-2 border-white rounded-xl"},h("div",{class:"active h-1.5 w-1.5 bg-green-500 rounded-xl"})),h("div",{class:"group-hover:border-blue-400 uppercase font-bold w-full h-full rounded-full border border-gray-400 flex justify-center items-center"},s?h("img",{class:"w-full rounded-full",src:o.picture,alt:"Logo"}):i?r[0]:h("svg",{xmlns:"http://www.w3.org/2000/svg",fill:"none",viewBox:"0 0 24 24","stroke-width":"1.5",stroke:"currentColor",class:"w-full"},h("path",{"stroke-linecap":"round","stroke-linejoin":"round",d:"M17.982 18.725A7.488 7.488 0 0 0 12 15.75a7.488 7.488 0 0 0-5.982 2.975m11.963 0a9 9 0 1 0-11.963 0m11.963 0A8.966 8.966 0 0 1 12 21a8.966 8.966 0 0 1-5.982-2.275M15 9.75a3 3 0 1 1-6 0 3 3 0 0 1 6 0Z"})))),h("div",{class:"overflow-hidden flex flex-col w-full"},h("div",{class:"nl-title truncate overflow-hidden"},r),h("nl-login-status",{info:o}))))}))),!!this.recents.length&&h("div",{key:"e89d6cda8386575a0a87a2188a89e5d929b55e8d",class:"max-w-96 mx-auto pt-5"},h("p",{key:"811958459f3694f5e31c2f22c75611c49973b17b",class:"nl-description font-medium text-sm pb-1.5"},"Recent profiles"),h("ul",{key:"0c042b8bec46a9871551bf2965eb9f561b012f22",class:"p-2 rounded-lg border border-gray-200 flex flex-col w-full gap-0.5"},this.recents.map(o=>{const s=!!o?.picture,r=o.name||o.nip05||o.pubkey,i=!!r;return h("li",{onClick:()=>this.handleLoginRecentAccount(o),class:"flex items-center gap-x-3.5 w-full hover:bg-gray-400 flex cursor-pointer items-center gap-x-3.5 py-2 px-3 rounded-lg text-sm justify-between"},h("div",{class:"w-full max-w-7 h-7 flex relative"},h("div",{class:"absolute top-[-3px] right-[-3px] bg-white border border-white rounded-xl"},h("svg",{xmlns:"http://www.w3.org/2000/svg",fill:"none",viewBox:"0 0 24 24","stroke-width":"1.5",stroke:"currentColor",class:"w-3 h-3"},h("path",{"stroke-linecap":"round","stroke-linejoin":"round",d:"M12 6v6h4.5m4.5 0a9 9 0 1 1-18 0 9 9 0 0 1 18 0Z"}))),h("div",{class:"uppercase font-bold w-full h-full rounded-full border border-gray-400 flex justify-center items-center"},s?h("img",{class:"w-full rounded-full",src:o.picture,alt:"Logo"}):i?r[0]:h("svg",{xmlns:"http://www.w3.org/2000/svg",fill:"none",viewBox:"0 0 24 24","stroke-width":"1.5",stroke:"currentColor",class:"w-full"},h("path",{"stroke-linecap":"round","stroke-linejoin":"round",d:"M17.982 18.725A7.488 7.488 0 0 0 12 15.75a7.488 7.488 0 0 0-5.982 2.975m11.963 0a9 9 0 1 0-11.963 0m11.963 0A8.966 8.966 0 0 1 12 21a8.966 8.966 0 0 1-5.982-2.275M15 9.75a3 3 0 1 1-6 0 3 3 0 0 1 6 0Z"})))),h("div",{class:"overflow-hidden flex flex-col w-full"},h("div",{class:"nl-title truncate overflow-hidden"},r),h("nl-login-status",{info:o})),h("svg",{onClick:a=>{a.stopPropagation(),this.handleRemoveRecent(o)},xmlns:"http://www.w3.org/2000/svg",fill:"none",viewBox:"0 0 24 24","stroke-width":"1.5",stroke:"currentColor",class:"w-full max-w-6 h-6 text-red-500 hover:text-red-600 ml-auto"},h("path",{"stroke-linecap":"round","stroke-linejoin":"round",d:"m14.74 9-.346 9m-4.788 0L9.26 9m9.968-3.21c.342.052.682.107 1.022.166m-1.022-.165L18.16 19.673a2.25 2.25 0 0 1-2.244 2.077H8.084a2.25 2.25 0 0 1-2.244-2.077L4.772 5.79m14.456 0a48.108 48.108 0 0 0-3.478-.397m-12 .562c.34-.059.68-.114 1.022-.165m0 0a48.11 48.11 0 0 1 3.478-.397m7.5 0v-.916c0-1.18-.91-2.164-2.09-2.201a51.964 51.964 0 0 0-3.32 0c-1.18.037-2.09 1.022-2.09 2.201v.916m7.5 0a48.667 48.667 0 0 0-7.5 0"})))})))),h("div",{key:"f70f67171d6727d25b9a38bdf48730146c46f4f2",class:"p-4 overflow-y-auto"},h("p",{key:"7289d6c89d90db640ecc63603657280dec8d3a82",class:"nl-footer font-light text-center text-sm max-w-96 mx-auto"},"You can also"," ",h("span",{key:"5c0d9e2954a37fc013d459a78b8a056b916cdd62",onClick:()=>this.handleGoToWelcome(),class:"cursor-pointer pb-3 text-blue-500"},"add another profile"))))}static get watchers(){return{accounts:["watchAccounts"],recents:["watchRecents"]}}static get style(){return NlPreviouslyLoggedStyle0}},[0,"nl-previously-logged",{titlePage:[1,"title-page"],description:[1],accounts:[16],recents:[16]},void 0,{accounts:["watchAccounts"],recents:["watchRecents"]}]);function defineCustomElement$e(){typeof customElements>"u"||["nl-previously-logged","nl-login-status"].forEach(o=>{switch(o){case"nl-previously-logged":customElements.get(o)||customElements.define(o,NlPreviouslyLogged);break;case"nl-login-status":customElements.get(o)||defineCustomElement$g()}})}defineCustomElement$e();const nlSigninCss=baseCss,NlSigninStyle0=nlSigninCss,NlSignin=proxyCustomElement(class extends H{constructor(){super(),this.__registerHost(),this.nlLogin=createEvent(this,"nlLogin",7),this.nlCheckLogin=createEvent(this,"nlCheckLogin",7),this.titleLogin="Connect to key store",this.description="Please enter your user name.",this.isGood=!1}handleInputChange(o){state.nlSignin.loginName=o.target.value,this.nlCheckLogin.emit(o.target.value)}handleLogin(o){o.preventDefault(),this.nlLogin.emit(state.nlSignin.loginName)}render(){return h(Fragment,{key:"70d5c41620a53b3b84157044f33fdce851d9054d"},h("div",{key:"f8880d45479ef512694fe1300a3c99df8dc756f2",class:"p-4 overflow-y-auto"},h("h1",{key:"fb0379faf61fa39d283fd2d159932b0dba56ed60",class:"nl-title font-bold text-center text-2xl"},this.titleLogin),h("p",{key:"389dcc582e456ba3241a202aa77026b5fe1f2f1c",class:"nl-description font-light text-center text-sm pt-2 max-w-96 mx-auto"},this.description)),h("div",{key:"0cbc1dd3dd3e8437d5f1be8c5612a48ebf589a73",class:"max-w-72 mx-auto"},h("div",{key:"6d8d1a649d6f9b4ec39e91cb50880ec55ae34469",class:"relative mb-2"},h("input",{key:"546c3c63fc1849275b86efdfb8fa5b016ae4282b",onInput:o=>this.handleInputChange(o),type:"text",class:"nl-input peer py-3 px-4 ps-11 block w-full border-transparent rounded-lg text-sm disabled:opacity-50 disabled:pointer-events-none dark:border-transparent",placeholder:"name@domain.com",value:state.nlSignin.loginName}),h("div",{key:"c91b2fb461ca2ee751a0811381a771ed227d1c7b",class:"absolute inset-y-0 start-0 flex items-center pointer-events-none ps-4 peer-disabled:opacity-50 peer-disabled:pointer-events-none"},h("svg",{key:"cd11d6e2e75a3e3e60696d825f494e49d587abc3",xmlns:"http://www.w3.org/2000/svg",fill:"none",viewBox:"0 0 24 24","stroke-width":"2",stroke:this.isGood?"#00cc00":"currentColor",class:"flex-shrink-0 w-4 h-4 text-gray-500"},h("path",{key:"dd3d6d8e13a01fdb449dadbb5daa79141ae74217","stroke-linecap":"round","stroke-linejoin":"round",d:"M15.75 6a3.75 3.75 0 1 1-7.5 0 3.75 3.75 0 0 1 7.5 0ZM4.501 20.118a7.5 7.5 0 0 1 14.998 0A17.933 17.933 0 0 1 12 21.75c-2.676 0-5.216-.584-7.499-1.632Z"})))),h("div",{key:"e2aff3f44b41a2365f9c561410c2d8733e93943d",class:"ps-4 pe-4 overflow-y-auto"},h("p",{key:"4f3b61256e93001cbf6cf8e0eea61e73265abd65",class:"nl-error font-light text-center text-sm max-w-96 mx-auto"},state.error)),h("button-base",{key:"64e9997f3163465cc99eae8600e7b13251ffe484",titleBtn:"Connect",disabled:state.isLoading,onClick:o=>this.handleLogin(o)},state.isLoading?h("span",{slot:"icon-start",class:"animate-spin-loading inline-block w-4 h-4 border-[3px] border-current border-t-transparent text-slate-900 dark:text-gray-300 rounded-full",role:"status","aria-label":"loading"}):h("svg",{style:{display:"none"},slot:"icon-start",xmlns:"http://www.w3.org/2000/svg",fill:"none",viewBox:"0 0 24 24","stroke-width":"1.5",stroke:"currentColor"},h("path",{"stroke-linecap":"round","stroke-linejoin":"round",d:"M8.25 9V5.25A2.25 2.25 0 0 1 10.5 3h6a2.25 2.25 0 0 1 2.25 2.25v13.5A2.25 2.25 0 0 1 16.5 21h-6a2.25 2.25 0 0 1-2.25-2.25V15M12 9l3 3m0 0-3 3m3-3H2.25"})))))}static get style(){return NlSigninStyle0}},[0,"nl-signin",{titleLogin:[1,"title-login"],description:[1],isGood:[32]}]);function defineCustomElement$d(){typeof customElements>"u"||["nl-signin","button-base"].forEach(o=>{switch(o){case"nl-signin":customElements.get(o)||customElements.define(o,NlSignin);break;case"button-base":customElements.get(o)||defineCustomElement$q()}})}defineCustomElement$d();const nlSigninBunkerUrlCss=baseCss,NlSigninBunkerUrlStyle0=nlSigninBunkerUrlCss,NlSigninBunkerUrl=proxyCustomElement(class extends H{constructor(){super(),this.__registerHost(),this.nlLogin=createEvent(this,"nlLogin",7),this.nlCheckLogin=createEvent(this,"nlCheckLogin",7),this.titleLogin="Connect with bunker url",this.description="Please enter a bunker url provided by key store.",this.isGood=!1}handleInputChange(o){state.nlSigninBunkerUrl.loginName=o.target.value,this.nlCheckLogin.emit(o.target.value)}handleLogin(o){o.preventDefault(),this.nlLogin.emit(state.nlSigninBunkerUrl.loginName)}render(){return h(Fragment,{key:"0ac12fea476faa724c8fa9ba34bebbd58c0b324d"},h("div",{key:"94fc0ef392c7d6abedc1bba2c833ff3e734fde23",class:"p-4 overflow-y-auto"},h("h1",{key:"c8426115b8d12e24e349813302360dc37ae935ca",class:"nl-title font-bold text-center text-2xl"},this.titleLogin),h("p",{key:"804a1e0b2329e78f80470da090cb06fd3165116f",class:"nl-description font-light text-center text-sm pt-2 max-w-96 mx-auto"},this.description)),h("div",{key:"3dad7e0005f66ad81c616983921455bf77b95c31",class:"max-w-72 mx-auto"},h("div",{key:"3e2f1825061c8f65c300676624d244240abb9590",class:"relative mb-2"},h("input",{key:"048e82df548ed4018684b92a93cd20c6ea60af95",onInput:o=>this.handleInputChange(o),type:"text",class:"nl-input peer py-3 px-4 ps-11 block w-full border-transparent rounded-lg text-sm disabled:opacity-50 disabled:pointer-events-none dark:border-transparent",placeholder:"bunker://...",value:state.nlSigninBunkerUrl.loginName}),h("div",{key:"29afff805cfc2d5e135ece3d5d791e6a1506294b",class:"absolute inset-y-0 start-0 flex items-center pointer-events-none ps-4 peer-disabled:opacity-50 peer-disabled:pointer-events-none"},h("svg",{key:"3ca9eb00e319357c690fa7d0027dba1e61d7fb83",xmlns:"http://www.w3.org/2000/svg",fill:"none",viewBox:"0 0 24 24","stroke-width":"2",stroke:this.isGood?"#00cc00":"currentColor",class:"flex-shrink-0 w-4 h-4 text-gray-500"},h("path",{key:"2914d12af813da649534f1aca80f3b80d1e53193","stroke-linecap":"round","stroke-linejoin":"round",d:"M13.19 8.688a4.5 4.5 0 0 1 1.242 7.244l-4.5 4.5a4.5 4.5 0 0 1-6.364-6.364l1.757-1.757m13.35-.622 1.757-1.757a4.5 4.5 0 0 0-6.364-6.364l-4.5 4.5a4.5 4.5 0 0 0 1.242 7.244"})))),h("div",{key:"83617653feed00b5d45b4d8318369a16185ca690",class:"ps-4 pe-4 overflow-y-auto"},h("p",{key:"3548cd177582a91b8c4b383311f04fd4b8b2002e",class:"nl-error font-light text-center text-sm max-w-96 mx-auto"},state.error)),h("button-base",{key:"8ae258e580cae2a08955ff02b4d21601a3be3aee",titleBtn:"Connect",disabled:state.isLoading,onClick:o=>this.handleLogin(o)},state.isLoading?h("span",{slot:"icon-start",class:"animate-spin-loading inline-block w-4 h-4 border-[3px] border-current border-t-transparent text-slate-900 dark:text-gray-300 rounded-full",role:"status","aria-label":"loading"}):h("svg",{style:{display:"none"},slot:"icon-start",xmlns:"http://www.w3.org/2000/svg",fill:"none",viewBox:"0 0 24 24","stroke-width":"1.5",stroke:"currentColor"},h("path",{"stroke-linecap":"round","stroke-linejoin":"round",d:"M8.25 9V5.25A2.25 2.25 0 0 1 10.5 3h6a2.25 2.25 0 0 1 2.25 2.25v13.5A2.25 2.25 0 0 1 16.5 21h-6a2.25 2.25 0 0 1-2.25-2.25V15M12 9l3 3m0 0-3 3m3-3H2.25"})))))}static get style(){return NlSigninBunkerUrlStyle0}},[0,"nl-signin-bunker-url",{titleLogin:[1,"title-login"],description:[1],isGood:[32]}]);function defineCustomElement$c(){typeof customElements>"u"||["nl-signin-bunker-url","button-base"].forEach(o=>{switch(o){case"nl-signin-bunker-url":customElements.get(o)||customElements.define(o,NlSigninBunkerUrl);break;case"button-base":customElements.get(o)||defineCustomElement$q()}})}defineCustomElement$c();var browser$1={},canPromise$1=function(){return"function"==typeof Promise&&Promise.prototype&&Promise.prototype.then},qrcode={},utils$1$1={};let toSJISFunction;const CODEWORDS_COUNT=[0,26,44,70,100,134,172,196,242,292,346,404,466,532,581,655,733,815,901,991,1085,1156,1258,1364,1474,1588,1706,1828,1921,2051,2185,2323,2465,2611,2761,2876,3034,3196,3362,3532,3706];utils$1$1.getSymbolSize=function(o){if(!o)throw new Error('"version" cannot be null or undefined');if(o<1||o>40)throw new Error('"version" should be in range from 1 to 40');return 4*o+17},utils$1$1.getSymbolTotalCodewords=function(o){return CODEWORDS_COUNT[o]},utils$1$1.getBCHDigit=function(o){let s=0;for(;0!==o;)s++,o>>>=1;return s},utils$1$1.setToSJISFunction=function(o){if("function"!=typeof o)throw new Error('"toSJISFunc" is not a valid function.');toSJISFunction=o},utils$1$1.isKanjiModeEnabled=function(){return void 0!==toSJISFunction},utils$1$1.toSJIS=function(o){return toSJISFunction(o)};var errorCorrectionLevel={},exports;function BitBuffer$1(){this.buffer=[],this.length=0}exports=errorCorrectionLevel,exports.L={bit:1},exports.M={bit:0},exports.Q={bit:3},exports.H={bit:2},exports.isValid=function(o){return o&&void 0!==o.bit&&o.bit>=0&&o.bit<4},exports.from=function(o,s){if(exports.isValid(o))return o;try{return function(r){if("string"!=typeof r)throw new Error("Param is not a string");switch(r.toLowerCase()){case"l":case"low":return exports.L;case"m":case"medium":return exports.M;case"q":case"quartile":return exports.Q;case"h":case"high":return exports.H;default:throw new Error("Unknown EC Level: "+r)}}(o)}catch{return s}},BitBuffer$1.prototype={get:function(o){const s=Math.floor(o/8);return 1==(this.buffer[s]>>>7-o%8&1)},put:function(o,s){for(let r=0;r>>s-r-1&1))},getLengthInBits:function(){return this.length},putBit:function(o){const s=Math.floor(this.length/8);this.buffer.length<=s&&this.buffer.push(0),o&&(this.buffer[s]|=128>>>this.length%8),this.length++}};var bitBuffer=BitBuffer$1;function BitMatrix$1(o){if(!o||o<1)throw new Error("BitMatrix size must be defined and greater than 0");this.size=o,this.data=new Uint8Array(o*o),this.reservedBit=new Uint8Array(o*o)}BitMatrix$1.prototype.set=function(o,s,r,i){const a=o*this.size+s;this.data[a]=r,i&&(this.reservedBit[a]=!0)},BitMatrix$1.prototype.get=function(o,s){return this.data[o*this.size+s]},BitMatrix$1.prototype.xor=function(o,s,r){this.data[o*this.size+s]^=r},BitMatrix$1.prototype.isReserved=function(o,s){return this.reservedBit[o*this.size+s]};var bitMatrix=BitMatrix$1,alignmentPattern={};!function(o){const s=utils$1$1.getSymbolSize;o.getRowColCoords=function(r){if(1===r)return[];const i=Math.floor(r/7)+2,a=s(r),c=145===a?26:2*Math.ceil((a-13)/(2*i-2)),y=[a-7];for(let w=1;w=0&&y<=7},o.from=function(y){return o.isValid(y)?parseInt(y,10):void 0},o.getPenaltyN1=function(y){const w=y.size;let C=0,T=0,S=0,M=null,O=null;for(let L=0;L=5&&(C+=T-5+3),M=q,T=1),q=y.get(Z,L),q===O?S++:(S>=5&&(C+=S-5+3),O=q,S=1)}T>=5&&(C+=T-5+3),S>=5&&(C+=S-5+3)}return C},o.getPenaltyN2=function(y){const w=y.size;let C=0;for(let T=0;T=10&&(1488===T||93===T)&&C++,S=S<<1&2047|y.get(O,M),O>=10&&(1488===S||93===S)&&C++}return 40*C},o.getPenaltyN4=function(y){let w=0;const C=y.data.length;for(let T=0;T=0;){const c=a[0];for(let w=0;w0){const a=new Uint8Array(this.degree);return a.set(r,i),a}return r};var reedSolomonEncoder=ReedSolomonEncoder$1,version={},mode={},versionCheck={isValid:function(o){return!isNaN(o)&&o>=1&&o<=40}},regex$1={};const numeric="[0-9]+",alphanumeric="[A-Z $%*+\\-./:]+";let kanji="(?:[u3000-u303F]|[u3040-u309F]|[u30A0-u30FF]|[uFF00-uFFEF]|[u4E00-u9FAF]|[u2605-u2606]|[u2190-u2195]|u203B|[u2010u2015u2018u2019u2025u2026u201Cu201Du2225u2260]|[u0391-u0451]|[u00A7u00A8u00B1u00B4u00D7u00F7])+";kanji=kanji.replace(/u/g,"\\u");const byte="(?:(?![A-Z0-9 $%*+\\-./:]|"+kanji+")(?:.|[\r\n]))+";regex$1.KANJI=new RegExp(kanji,"g"),regex$1.BYTE_KANJI=new RegExp("[^A-Z0-9 $%*+\\-./:]+","g"),regex$1.BYTE=new RegExp(byte,"g"),regex$1.NUMERIC=new RegExp(numeric,"g"),regex$1.ALPHANUMERIC=new RegExp(alphanumeric,"g");const TEST_KANJI=new RegExp("^"+kanji+"$"),TEST_NUMERIC=new RegExp("^"+numeric+"$"),TEST_ALPHANUMERIC=new RegExp("^[A-Z0-9 $%*+\\-./:]+$");regex$1.testKanji=function(o){return TEST_KANJI.test(o)},regex$1.testNumeric=function(o){return TEST_NUMERIC.test(o)},regex$1.testAlphanumeric=function(o){return TEST_ALPHANUMERIC.test(o)},function(o){const s=versionCheck,r=regex$1;o.NUMERIC={id:"Numeric",bit:1,ccBits:[10,12,14]},o.ALPHANUMERIC={id:"Alphanumeric",bit:2,ccBits:[9,11,13]},o.BYTE={id:"Byte",bit:4,ccBits:[8,16,16]},o.KANJI={id:"Kanji",bit:8,ccBits:[8,10,12]},o.MIXED={bit:-1},o.getCharCountIndicator=function(i,a){if(!i.ccBits)throw new Error("Invalid mode: "+i);if(!s.isValid(a))throw new Error("Invalid version: "+a);return a>=1&&a<10?i.ccBits[0]:a<27?i.ccBits[1]:i.ccBits[2]},o.getBestModeForData=function(i){return r.testNumeric(i)?o.NUMERIC:r.testAlphanumeric(i)?o.ALPHANUMERIC:r.testKanji(i)?o.KANJI:o.BYTE},o.toString=function(i){if(i&&i.id)return i.id;throw new Error("Invalid mode")},o.isValid=function(i){return i&&i.bit&&i.ccBits},o.from=function(i,a){if(o.isValid(i))return i;try{return function(c){if("string"!=typeof c)throw new Error("Param is not a string");switch(c.toLowerCase()){case"numeric":return o.NUMERIC;case"alphanumeric":return o.ALPHANUMERIC;case"kanji":return o.KANJI;case"byte":return o.BYTE;default:throw new Error("Unknown mode: "+c)}}(i)}catch{return a}}}(mode),function(o){const s=utils$1$1,r=errorCorrectionCode,i=errorCorrectionLevel,a=mode,c=versionCheck,y=s.getBCHDigit(7973);function w(T,S){return a.getCharCountIndicator(T,S)+4}function C(T,S){let M=0;return T.forEach(function(O){const L=w(O.mode,S);M+=L+O.getBitsLength()}),M}o.from=function(T,S){return c.isValid(T)?parseInt(T,10):S},o.getCapacity=function(T,S,M){if(!c.isValid(T))throw new Error("Invalid QR Code version");void 0===M&&(M=a.BYTE);const O=8*(s.getSymbolTotalCodewords(T)-r.getTotalCodewordsCount(T,S));if(M===a.MIXED)return O;const L=O-w(M,T);switch(M){case a.NUMERIC:return Math.floor(L/10*3);case a.ALPHANUMERIC:return Math.floor(L/11*2);case a.KANJI:return Math.floor(L/13);default:return Math.floor(L/8)}},o.getBestVersionForData=function(T,S){let M;const O=i.from(S,i.M);if(Array.isArray(T)){if(T.length>1)return function(L,Z){for(let q=1;q<=40;q++)if(C(L,q)<=o.getCapacity(q,Z,a.MIXED))return q}(T,O);if(0===T.length)return 1;M=T[0]}else M=T;return function(L,Z,q){for(let re=1;re<=40;re++)if(Z<=o.getCapacity(re,q,L))return re}(M.mode,M.getLength(),O)},o.getEncodedBits=function(T){if(!c.isValid(T)||T<7)throw new Error("Invalid QR Code version");let S=T<<12;for(;s.getBCHDigit(S)-y>=0;)S^=7973<=0;)i^=G15<0&&(r=this.data.substr(s),i=parseInt(r,10),o.put(i,3*a+1))};var numericData=NumericData;const Mode$3=mode,ALPHA_NUM_CHARS=["0","1","2","3","4","5","6","7","8","9","A","B","C","D","E","F","G","H","I","J","K","L","M","N","O","P","Q","R","S","T","U","V","W","X","Y","Z"," ","$","%","*","+","-",".","/",":"];function AlphanumericData(o){this.mode=Mode$3.ALPHANUMERIC,this.data=o}AlphanumericData.getBitsLength=function(o){return 11*Math.floor(o/2)+o%2*6},AlphanumericData.prototype.getLength=function(){return this.data.length},AlphanumericData.prototype.getBitsLength=function(){return AlphanumericData.getBitsLength(this.data.length)},AlphanumericData.prototype.write=function(o){let s;for(s=0;s+2<=this.data.length;s+=2){let r=45*ALPHA_NUM_CHARS.indexOf(this.data[s]);r+=ALPHA_NUM_CHARS.indexOf(this.data[s+1]),o.put(r,11)}this.data.length%2&&o.put(ALPHA_NUM_CHARS.indexOf(this.data[s]),6)};var alphanumericData=AlphanumericData;const Mode$2=mode;function ByteData(o){this.mode=Mode$2.BYTE,this.data="string"==typeof o?(new TextEncoder).encode(o):new Uint8Array(o)}ByteData.getBitsLength=function(o){return 8*o},ByteData.prototype.getLength=function(){return this.data.length},ByteData.prototype.getBitsLength=function(){return ByteData.getBitsLength(this.data.length)},ByteData.prototype.write=function(o){for(let s=0,r=this.data.length;s=33088&&r<=40956)r-=33088;else{if(!(r>=57408&&r<=60351))throw new Error("Invalid SJIS character: "+this.data[s]+"\nMake sure your charset is UTF-8");r-=49472}r=192*(r>>>8&255)+(255&r),o.put(r,13)}};var kanjiData=KanjiData,dijkstra={exports:{}};(function(o){var s={single_source_shortest_paths:function(r,i,a){var c={},y={};y[i]=0;var w,C,T,S,M,O,Z=s.PriorityQueue.make();for(Z.push(i,0);!Z.empty();)for(T in C=(w=Z.pop()).value,S=w.cost,M=r[C]||{})M.hasOwnProperty(T)&&(O=S+M[T],(void 0===y[T]||y[T]>O)&&(y[T]=O,Z.push(T,O),c[T]=C));if(void 0!==a&&void 0===y[a]){var q=["Could not find a path from ",i," to ",a,"."].join("");throw new Error(q)}return c},extract_shortest_path_from_predecessor_list:function(r,i){for(var a=[],c=i;c;)a.push(c),c=r[c];return a.reverse(),a},find_path:function(r,i,a){var c=s.single_source_shortest_paths(r,i,a);return s.extract_shortest_path_from_predecessor_list(c,a)},PriorityQueue:{make:function(r){var i,a=s.PriorityQueue,c={};for(i in r=r||{},a)a.hasOwnProperty(i)&&(c[i]=a[i]);return c.queue=[],c.sorter=r.sorter||a.default_sorter,c},default_sorter:function(r,i){return r.cost-i.cost},push:function(r,i){this.queue.push({value:r,cost:i}),this.queue.sort(this.sorter)},pop:function(){return this.queue.shift()},empty:function(){return 0===this.queue.length}}};o.exports=s})(dijkstra),function(o){const s=mode,r=numericData,i=alphanumericData,a=byteData,c=kanjiData,y=regex$1,w=utils$1$1,C=dijkstra.exports;function T(Z){return unescape(encodeURIComponent(Z)).length}function S(Z,q,re){const pe=[];let se;for(;null!==(se=Z.exec(re));)pe.push({data:se[0],index:se.index,mode:q,length:se[0].length});return pe}function M(Z){const q=S(y.NUMERIC,s.NUMERIC,Z),re=S(y.ALPHANUMERIC,s.ALPHANUMERIC,Z);let pe,se;return w.isKanjiModeEnabled()?(pe=S(y.BYTE,s.BYTE,Z),se=S(y.KANJI,s.KANJI,Z)):(pe=S(y.BYTE_KANJI,s.BYTE,Z),se=[]),q.concat(re,pe,se).sort(function(ae,me){return ae.index-me.index}).map(function(ae){return{data:ae.data,mode:ae.mode,length:ae.length}})}function O(Z,q){switch(q){case s.NUMERIC:return r.getBitsLength(Z);case s.ALPHANUMERIC:return i.getBitsLength(Z);case s.KANJI:return c.getBitsLength(Z);case s.BYTE:return a.getBitsLength(Z)}}function L(Z,q){let re;const pe=s.getBestModeForData(Z);if(re=s.from(q,pe),re!==s.BYTE&&re.bit=0?be[be.length-1]:null;return xe&&xe.mode===Oe.mode?(be[be.length-1].data+=Oe.data,be):(be.push(Oe),be)},[]))},o.rawSplit=function(Z){return o.fromArray(M(Z,w.isKanjiModeEnabled()))}}(segments);const Utils$1=utils$1$1,ECLevel=errorCorrectionLevel,BitBuffer=bitBuffer,BitMatrix=bitMatrix,AlignmentPattern=alignmentPattern,FinderPattern=finderPattern,MaskPattern=maskPattern,ECCode=errorCorrectionCode,ReedSolomonEncoder=reedSolomonEncoder,Version=version,FormatInfo=formatInfo,Mode=mode,Segments=segments;function setupFinderPattern(o,s){const r=o.size,i=FinderPattern.getPositions(s);for(let a=0;a=0&&w<=6&&(0===C||6===C)||C>=0&&C<=6&&(0===w||6===w)||w>=2&&w<=4&&C>=2&&C<=4,!0)}}function setupTimingPattern(o){const s=o.size;for(let r=8;r>w&1),o.set(a,c,y,!0),o.set(c,a,y,!0)}function setupFormatInfo(o,s,r){const i=o.size,a=FormatInfo.getEncodedBits(s,r);let c,y;for(c=0;c<15;c++)y=1==(a>>c&1),o.set(c<6?c:c<8?c+1:i-15+c,8,y,!0),o.set(8,c<8?i-c-1:c<9?15-c-1+1:15-c-1,y,!0);o.set(i-8,8,1,!0)}function setupData(o,s){const r=o.size;let i=-1,a=r-1,c=7,y=0;for(let w=r-1;w>0;w-=2)for(6===w&&w--;;){for(let C=0;C<2;C++)if(!o.isReserved(a,w-C)){let T=!1;y>>c&1)),o.set(a,w-C,T),c--,-1===c&&(y++,c=7)}if(a+=i,a<0||r<=a){a-=i,i=-i;break}}}function createData(o,s,r){const i=new BitBuffer;r.forEach(function(y){i.put(y.mode.bit,4),i.put(y.getLength(),Mode.getCharCountIndicator(y.mode,o)),y.write(i)});const a=8*(Utils$1.getSymbolTotalCodewords(o)-ECCode.getTotalCodewordsCount(o,s));for(i.getLengthInBits()+4<=a&&i.put(0,4);i.getLengthInBits()%8!=0;)i.putBit(0);const c=(a-i.getLengthInBits())/8;for(let y=0;y=7&&setupVersionInfo(C,s),setupData(C,y),isNaN(i)&&(i=MaskPattern.getBestMask(C,setupFormatInfo.bind(null,C,r))),MaskPattern.applyMask(i,C),setupFormatInfo(C,r,i),{modules:C,version:s,errorCorrectionLevel:r,maskPattern:i,segments:a}}qrcode.create=function(o,s){if(void 0===o||""===o)throw new Error("No input text");let r,i,a=ECLevel.M;return void 0!==s&&(a=ECLevel.from(s.errorCorrectionLevel,ECLevel.M),r=Version.from(s.version),i=MaskPattern.from(s.maskPattern),s.toSJISFunc&&Utils$1.setToSJISFunction(s.toSJISFunc)),createSymbol(o,r,a,i)};var canvas={},utils$3={};(function(o){function s(r){if("number"==typeof r&&(r=r.toString()),"string"!=typeof r)throw new Error("Color should be defined as hex string");let i=r.slice().replace("#","").split("");if(i.length<3||5===i.length||i.length>8)throw new Error("Invalid hex color: "+r);3!==i.length&&4!==i.length||(i=Array.prototype.concat.apply([],i.map(function(c){return[c,c]}))),6===i.length&&i.push("F","F");const a=parseInt(i.join(""),16);return{r:a>>24&255,g:a>>16&255,b:a>>8&255,a:255&a,hex:"#"+i.slice(0,6).join("")}}o.getOptions=function(r){r||(r={}),r.color||(r.color={});const a=r.width&&r.width>=21?r.width:void 0;return{width:a,scale:a?4:r.scale||4,margin:null==r.margin||r.margin<0?4:r.margin,color:{dark:s(r.color.dark||"#000000ff"),light:s(r.color.light||"#ffffffff")},type:r.type,rendererOpts:r.rendererOpts||{}}},o.getScale=function(r,i){return i.width&&i.width>=r+2*i.margin?i.width/(r+2*i.margin):i.scale},o.getImageWidth=function(r,i){const a=o.getScale(r,i);return Math.floor((r+2*i.margin)*a)},o.qrToImageData=function(r,i,a){const c=i.modules.size,y=i.modules.data,w=o.getScale(c,a),C=Math.floor((c+2*a.margin)*w),T=a.margin*w,S=[a.color.light,a.color.dark];for(let M=0;M=T&&O>=T&&M0&&C>0&&o[w-1]||(i+=c?svgCmd("M",C+r,.5+T+r):svgCmd("m",a,0),a=0,c=!1),C+1':"",C="',S=''+w+C+"\n";return"function"==typeof r&&r(null,S),S};const canPromise=canPromise$1,QRCode=qrcode,CanvasRenderer=canvas,SvgRenderer=svgTag;function renderCanvas(o,s,r,i,a){const c=[].slice.call(arguments,1),y=c.length,w="function"==typeof c[y-1];if(!w&&!canPromise())throw new Error("Callback required as last argument");if(!w){if(y<1)throw new Error("Too few arguments provided");return 1===y?(r=s,s=i=void 0):2!==y||s.getContext||(i=r,r=s,s=void 0),new Promise(function(C,T){try{const S=QRCode.create(r,i);C(o(S,s,i))}catch(S){T(S)}})}if(y<2)throw new Error("Too few arguments provided");2===y?(a=r,r=s,s=i=void 0):3===y&&(s.getContext&&void 0===a?(a=i,i=void 0):(a=i,i=r,r=s,s=void 0));try{const C=QRCode.create(r,i);a(null,o(C,s,i))}catch(C){a(C)}}browser$1.create=QRCode.create,browser$1.toCanvas=renderCanvas.bind(null,CanvasRenderer.render),browser$1.toDataURL=renderCanvas.bind(null,CanvasRenderer.renderToDataURL),browser$1.toString=renderCanvas.bind(null,function(o,s,r){return SvgRenderer.render(o,r)});const nlSigninConnectionStringCss=baseCss,NlSigninConnectionStringStyle0=nlSigninConnectionStringCss,NlSigninConnectionString=proxyCustomElement(class extends H{constructor(){super(),this.__registerHost(),this.titleLogin="Connection string",this.description="Scan or copy the connection string with key store app",this.connectionString="",this.isCopy=!1}componentDidLoad(){this.generateQRCode()}generateQRCode(){var o=this;return(0,_home_runner_work_angor_hub_angor_hub_node_modules_angular_builders_custom_webpack_node_modules_babel_runtime_helpers_esm_asyncToGenerator_js__WEBPACK_IMPORTED_MODULE_1__.A)(function*(){if(o.connectionString&&o.canvasElement)try{yield browser$1.toCanvas(o.canvasElement,o.connectionString)}catch(s){console.error("Error generating QR Code:",s)}})()}copyToClipboard(){var o=this;return(0,_home_runner_work_angor_hub_angor_hub_node_modules_angular_builders_custom_webpack_node_modules_babel_runtime_helpers_esm_asyncToGenerator_js__WEBPACK_IMPORTED_MODULE_1__.A)(function*(){try{yield navigator.clipboard.writeText(o.connectionString),o.isCopy=!0,setTimeout(()=>{o.isCopy=!1},1500)}catch(s){console.error("Failed to copy connectionString: ",s)}})()}render(){return h(Fragment,{key:"4dfdad6e2e948203e0dfe7aa8608d95cd3495c41"},h("div",{key:"852159a0231473f13c6452e307b90f02e7efd445",class:"p-4 overflow-y-auto"},h("h1",{key:"07859d4b83c5fb6ac12732f1708db3ba3b700380",class:"nl-title font-bold text-center text-2xl"},this.titleLogin),h("p",{key:"200d00f3785f4a684c798225f0061d9ef4ed2fa1",class:"nl-description font-light text-center text-sm pt-2 max-w-96 mx-auto"},this.description)),h("canvas",{key:"e27335a378a7853fd73cdf0b701a9922f9e87a98",class:"mx-auto mb-2",ref:o=>this.canvasElement=o}),h("div",{key:"5e93edcf3b13f1d02b6feca2a192ef275891032a",class:"px-4"},h("div",{key:"96643d192fc3e3c652027fc7b9da2c8186205b1f",class:"max-w-72 mx-auto"},h("div",{key:"24faf8ea390198fc185f94d77d0ac3faa3c03e9f",class:"relative mb-2"},h("input",{key:"45f531795476a136897925509955fa9fdaf66503",type:"text",class:"nl-input peer py-3 px-4 pe-11 ps-11 block w-full border-transparent rounded-lg text-sm disabled:opacity-50 disabled:pointer-events-none dark:border-transparent",placeholder:"npub or name@domain",value:this.connectionString,disabled:!0}),h("div",{key:"3f3bb777777890fb68152c94d16cd83abde57cac",class:"absolute inset-y-0 start-0 flex items-center pointer-events-none ps-4 peer-disabled:opacity-50 peer-disabled:pointer-events-none"},h("svg",{key:"c99e6d36b5f3e85a03b2922a3984803601ce4747",xmlns:"http://www.w3.org/2000/svg",fill:"none",viewBox:"0 0 24 24","stroke-width":"1.5",stroke:"currentColor",class:"flex-shrink-0 w-4 h-4 text-gray-500"},h("path",{key:"1d72c6d727215e897c88b923f1eb65a83bc9eda9","stroke-linecap":"round","stroke-linejoin":"round",d:"M2.036 12.322a1.012 1.012 0 0 1 0-.639C3.423 7.51 7.36 4.5 12 4.5c4.638 0 8.573 3.007 9.963 7.178.07.207.07.431 0 .639C20.577 16.49 16.64 19.5 12 19.5c-4.638 0-8.573-3.007-9.963-7.178Z"}),h("path",{key:"5c40e5fd22377e528bdc3fe77db8975dfe015286","stroke-linecap":"round","stroke-linejoin":"round",d:"M15 12a3 3 0 1 1-6 0 3 3 0 0 1 6 0Z"}))),this.isCopy?h("div",{class:"absolute inset-y-0 end-0 flex items-center p-2 rounded-lg"},h("svg",{xmlns:"http://www.w3.org/2000/svg",fill:"none",viewBox:"0 0 24 24","stroke-width":"1.5",stroke:"#00cc00",class:"flex-shrink-0 w-4 h-4 text-gray-500"},h("path",{"stroke-linecap":"round","stroke-linejoin":"round",d:"M9 12.75 11.25 15 15 9.75M21 12a9 9 0 1 1-18 0 9 9 0 0 1 18 0Z"}))):h("div",{class:"absolute inset-y-0 end-0 flex items-center cursor-pointer p-2 rounded-lg",onClick:()=>this.copyToClipboard()},h("svg",{xmlns:"http://www.w3.org/2000/svg",fill:"none",viewBox:"0 0 24 24","stroke-width":"1.5",stroke:"currentColor",class:"flex-shrink-0 w-4 h-4 text-gray-500"},h("path",{"stroke-linecap":"round","stroke-linejoin":"round",d:"M16.5 8.25V6a2.25 2.25 0 0 0-2.25-2.25H6A2.25 2.25 0 0 0 3.75 6v8.25A2.25 2.25 0 0 0 6 16.5h2.25m8.25-8.25H18a2.25 2.25 0 0 1 2.25 2.25V18A2.25 2.25 0 0 1 18 20.25h-7.5A2.25 2.25 0 0 1 8.25 18v-1.5m8.25-8.25h-6a2.25 2.25 0 0 0-2.25 2.25v6"})))),h("div",{key:"26403008de1debe9660fbacda25b6c5eb1ce81c8",class:"mt-10 justify-center items-center flex gap-2"},h("span",{key:"2cc09432eb515db009f4ca5909b8ba943c90bbd6",slot:"icon-start",class:"animate-spin-loading inline-block w-[20px] h-[20px] border-[2px] border-current border-t-transparent text-slate-900 dark:text-gray-300 rounded-full",role:"status","aria-label":"loading"}),h("span",{key:"b2d8a70b65950ec00d9544c4ba50a51bffc48335",class:"nl-footer"},"Waiting for connection")))))}static get style(){return NlSigninConnectionStringStyle0}},[0,"nl-signin-connection-string",{titleLogin:[1,"title-login"],description:[1],connectionString:[1,"connection-string"],isCopy:[32]}]);function defineCustomElement$b(){typeof customElements>"u"||["nl-signin-connection-string"].forEach(o=>{"nl-signin-connection-string"===o&&(customElements.get(o)||customElements.define(o,NlSigninConnectionString))})}defineCustomElement$b();const nlSigninOtpCss=baseCss,NlSigninOtpStyle0=nlSigninOtpCss,NlSigninOtp=proxyCustomElement(class extends H{constructor(){super(),this.__registerHost(),this.nlLoginOTPUser=createEvent(this,"nlLoginOTPUser",7),this.nlLoginOTPCode=createEvent(this,"nlLoginOTPCode",7),this.nlCheckLogin=createEvent(this,"nlCheckLogin",7),this.titleLogin="Log in with DM",this.description="Please enter your user name or npub, and we will send you a direct message with a one-time code.",this.titleLoginOTP="Enter the code",this.descriptionOTP="Please enter the one-time code we sent to you as a direct message on Nostr.",this.isGood=!1}handleInputChange(o){state.isOTP?state.nlSigninOTP.code=o.target.value:(state.nlSigninOTP.loginName=o.target.value,this.nlCheckLogin.emit(state.nlSigninOTP.loginName))}handleLogin(o){o.preventDefault(),state.isOTP?this.nlLoginOTPCode.emit(state.nlSigninOTP.code):this.nlLoginOTPUser.emit(state.nlSigninOTP.loginName)}render(){return h(Fragment,{key:"a93b9af1f6a2a881d75e9aa1e547a63678ad4dc5"},h("div",{key:"ae6c700a09e753e0148b5ddfd27f20c2a0850d3d",class:"p-4 overflow-y-auto"},h("h1",{key:"e0998107834bf9e90b6372580ccb31bb0d726904",class:"nl-title font-bold text-center text-2xl"},state.isOTP?this.titleLoginOTP:this.titleLogin),h("p",{key:"29e894bbfcdfb326ae807055c57fbb32b1b4bfa9",class:"nl-description font-light text-center text-sm pt-2 max-w-96 mx-auto"},state.isOTP?this.descriptionOTP:this.description)),h("div",{key:"911cee576416be96c64d38fc362cdb656293e198",class:"max-w-72 mx-auto"},h("div",{key:"f72d607dd7beb554c248c7c4128de6d33a8f246f",class:"relative mb-2"},h("input",{key:"24e6a78d257e84d4f5c71b4aee31c453a504cd93",onInput:o=>this.handleInputChange(o),type:"text",class:"nl-input peer py-3 px-4 ps-11 block w-full border-transparent rounded-lg text-sm disabled:opacity-50 disabled:pointer-events-none dark:border-transparent",placeholder:state.isOTP?"code from direct message":"npub or name@domain",value:state.isOTP?state.nlSigninOTP.code:state.nlSigninOTP.loginName}),h("div",{key:"438171f72c2c64d1754a2d5fda95a7b5d3816894",class:"absolute inset-y-0 start-0 flex items-center pointer-events-none ps-4 peer-disabled:opacity-50 peer-disabled:pointer-events-none"},h("svg",{key:"b31663307181bb1d58884a3ecce192728b164b70",xmlns:"http://www.w3.org/2000/svg",fill:"none",viewBox:"0 0 24 24","stroke-width":"1.5",stroke:this.isGood?"#00cc00":"currentColor",class:"flex-shrink-0 w-4 h-4 text-gray-500"},h("path",{key:"8b80421658eea7b0b49708c994a9d94b965895f1","stroke-linecap":"round","stroke-linejoin":"round",d:"M2.036 12.322a1.012 1.012 0 0 1 0-.639C3.423 7.51 7.36 4.5 12 4.5c4.638 0 8.573 3.007 9.963 7.178.07.207.07.431 0 .639C20.577 16.49 16.64 19.5 12 19.5c-4.638 0-8.573-3.007-9.963-7.178Z"}),h("path",{key:"6d184bdf20d124a312e1817e27111de1fd0b8eb1","stroke-linecap":"round","stroke-linejoin":"round",d:"M15 12a3 3 0 1 1-6 0 3 3 0 0 1 6 0Z"})))),h("div",{key:"ab8948cbd67e068fc2f113fcc5e61137d799e636",class:"ps-4 pe-4 overflow-y-auto"},h("p",{key:"719399b9f40ae23ba11ae22e4223314c815c821f",class:"nl-error font-light text-center text-sm max-w-96 mx-auto"},state.error)),h("button-base",{key:"b2ce8bbaceeddc82ea079dba280dc04600d7f725",titleBtn:"Log in",disabled:state.isLoading,onClick:o=>this.handleLogin(o)},state.isLoading&&h("span",{key:"7764fb6ecf8452c06047dc7832e274ebccdd6379",slot:"icon-start",class:"animate-spin-loading inline-block w-4 h-4 border-[3px] border-current border-t-transparent text-slate-900 dark:text-gray-300 rounded-full",role:"status","aria-label":"loading"}))))}static get style(){return NlSigninOtpStyle0}},[0,"nl-signin-otp",{titleLogin:[1,"title-login"],description:[1],titleLoginOTP:[1,"title-login-o-t-p"],descriptionOTP:[1,"description-o-t-p"],isGood:[32]}]);function defineCustomElement$a(){typeof customElements>"u"||["nl-signin-otp","button-base"].forEach(o=>{switch(o){case"nl-signin-otp":customElements.get(o)||customElements.define(o,NlSigninOtp);break;case"button-base":customElements.get(o)||defineCustomElement$q()}})}defineCustomElement$a();const nlSigninReadOnlyCss=baseCss,NlSigninReadOnlyStyle0=nlSigninReadOnlyCss,NlSigninReadOnly=proxyCustomElement(class extends H{constructor(){super(),this.__registerHost(),this.nlLoginReadOnly=createEvent(this,"nlLoginReadOnly",7),this.nlCheckLogin=createEvent(this,"nlCheckLogin",7),this.titleLogin="Log in to read only",this.description="Please enter the user name or npub of any Nostr user.",this.isGood=!1}handleInputChange(o){state.nlSigninReadOnly.loginName=o.target.value,this.nlCheckLogin.emit(o.target.value)}handleLogin(o){o.preventDefault(),this.nlLoginReadOnly.emit(state.nlSigninReadOnly.loginName)}render(){return h(Fragment,{key:"5ff970ee20c505cab00b3c9263dd9a6ebd6b62a8"},h("div",{key:"036a6b49de93c20ed4af3c47c7ecc10c81818f86",class:"p-4 overflow-y-auto"},h("h1",{key:"97951254c835d38f95832882225fdc2b50bf578a",class:"nl-title font-bold text-center text-2xl"},this.titleLogin),h("p",{key:"e811a52ee24540b018f95ebffd1406330005a5f2",class:"nl-description font-light text-center text-sm pt-2 max-w-96 mx-auto"},this.description)),h("div",{key:"ae07b4fbe663e17733b6bd1efaa1c974276c8fd6",class:"max-w-72 mx-auto"},h("div",{key:"0a935603a2742e049bd5b2ca3c1b13f07d63ac2b",class:"relative mb-2"},h("input",{key:"1221b6501de2c739fc1470f82142b623afe4749b",onInput:o=>this.handleInputChange(o),type:"text",class:"nl-input peer py-3 px-4 ps-11 block w-full border-transparent rounded-lg text-sm disabled:opacity-50 disabled:pointer-events-none dark:border-transparent",placeholder:"npub or name@domain",value:state.nlSigninReadOnly.loginName}),h("div",{key:"820f77d6c814aea1794463b6216df338c6f0863d",class:"absolute inset-y-0 start-0 flex items-center pointer-events-none ps-4 peer-disabled:opacity-50 peer-disabled:pointer-events-none"},h("svg",{key:"9922ba1b7b536ddc8d560d76087fd735e1aa000c",xmlns:"http://www.w3.org/2000/svg",fill:"none",viewBox:"0 0 24 24","stroke-width":"1.5",stroke:this.isGood?"#00cc00":"currentColor",class:"flex-shrink-0 w-4 h-4 text-gray-500"},h("path",{key:"250dae1273e5346920bb6d5cad3644c678a9eae8","stroke-linecap":"round","stroke-linejoin":"round",d:"M2.036 12.322a1.012 1.012 0 0 1 0-.639C3.423 7.51 7.36 4.5 12 4.5c4.638 0 8.573 3.007 9.963 7.178.07.207.07.431 0 .639C20.577 16.49 16.64 19.5 12 19.5c-4.638 0-8.573-3.007-9.963-7.178Z"}),h("path",{key:"e94192cf4f271cf3477ebe2f186597a5c5a7b474","stroke-linecap":"round","stroke-linejoin":"round",d:"M15 12a3 3 0 1 1-6 0 3 3 0 0 1 6 0Z"})))),h("div",{key:"8d548af75b9c39dfe0bf2eeae805e58d2cb324c1",class:"ps-4 pe-4 overflow-y-auto"},h("p",{key:"7cc88f5116a24e1b309e320c63c34f5cc8c5b656",class:"nl-error font-light text-center text-sm max-w-96 mx-auto"},state.error)),h("button-base",{key:"156e8a30228a8d34009c5cb020588c82f039eac5",titleBtn:"Log in",disabled:state.isLoading,onClick:o=>this.handleLogin(o)},state.isLoading&&h("span",{key:"14082758440bf5ec897629c92faf949f80895be8",slot:"icon-start",class:"animate-spin-loading inline-block w-4 h-4 border-[3px] border-current border-t-transparent text-slate-900 dark:text-gray-300 rounded-full",role:"status","aria-label":"loading"}))))}static get style(){return NlSigninReadOnlyStyle0}},[0,"nl-signin-read-only",{titleLogin:[1,"title-login"],description:[1],isGood:[32]}]);function defineCustomElement$9(){typeof customElements>"u"||["nl-signin-read-only","button-base"].forEach(o=>{switch(o){case"nl-signin-read-only":customElements.get(o)||customElements.define(o,NlSigninReadOnly);break;case"button-base":customElements.get(o)||defineCustomElement$q()}})}defineCustomElement$9();const nlSignupCss=baseCss,NlSignupStyle0=nlSignupCss,NlSignup=proxyCustomElement(class extends H{constructor(){super(),this.__registerHost(),this.nlSignup=createEvent(this,"nlSignup",7),this.nlCheckSignup=createEvent(this,"nlCheckSignup",7),this.fetchHandler=createEvent(this,"fetchHandler",7),this.titleSignup="Create keys with key store",this.description="Choose some username and a key store service.",this.bunkers="nsec.app,highlighter.com",this.isAvailable=!1}formatServers(o){return o.split(",").map(s=>({name:"@"+s,value:s}))}handleInputChange(o){state.nlSignup.signupName=o.target.value,this.nlCheckSignup.emit(`${o.target.value}@${state.nlSignup.domain}`)}handleDomainSelect(o){state.nlSignup.domain=o.detail,this.nlCheckSignup.emit(`${state.nlSignup.signupName}@${o.detail}`)}handleCreateAccount(o){o.preventDefault(),this.nlSignup.emit(`${state.nlSignup.signupName}@${state.nlSignup.domain}`)}watchBunkersHandler(o){state.nlSignup.servers=this.formatServers(o)}componentWillLoad(){state.nlSignup.servers=this.formatServers(this.bunkers)}render(){return h(Fragment,{key:"f7b56fee1ec9c6dd3632bed5d46c661b090a32cd"},h("div",{key:"a7fd1b6249688b0974a0c56a0573f36eb1f1d7a4",class:"p-4 overflow-y-auto"},h("h1",{key:"01d5a745026ea0a293fd248880f00d335355f5bf",class:"nl-title font-bold text-center text-2xl"},this.titleSignup),h("p",{key:"1fe9362df4c08bee7966a3d7f06aca0c8c9f9e38",class:"nl-description font-light text-center text-sm pt-2 max-w-96 mx-auto"},this.description)),h("div",{key:"15eadc1d7189a9a99efad1c42a430fb316d3ae1a",class:"max-w-72 mx-auto"},h("div",{key:"011c9eb5d2d16cd6b784f0d879fd4f504c522905",class:"relative mb-2"},h("input",{key:"123e130805b229fe68c64765c434a36840cc137e",onInput:o=>this.handleInputChange(o),type:"text",class:"nl-input peer py-3 px-4 ps-11 block w-full border-transparent rounded-lg text-sm disabled:opacity-50 disabled:pointer-events-none dark:border-transparent",placeholder:"Name",value:state.nlSignup.signupName}),h("div",{key:"ee00cfd158acb362567e909a6f90d2651a4acd05",class:"absolute inset-y-0 start-0 flex items-center pointer-events-none ps-4 peer-disabled:opacity-50 peer-disabled:pointer-events-none"},h("svg",{key:"bc8a81c9a62cb215efb0cdff30980ee447371ec5",xmlns:"http://www.w3.org/2000/svg",fill:"none",viewBox:"0 0 24 24","stroke-width":"2",stroke:this.isAvailable?"#00cc00":"currentColor",class:"flex-shrink-0 w-4 h-4 text-gray-500"},h("path",{key:"fb78fc743ec535bb92d30e2b43927d499f6299ca","stroke-linecap":"round","stroke-linejoin":"round",d:"M15.75 6a3.75 3.75 0 1 1-7.5 0 3.75 3.75 0 0 1 7.5 0ZM4.501 20.118a7.5 7.5 0 0 1 14.998 0A17.933 17.933 0 0 1 12 21.75c-2.676 0-5.216-.584-7.499-1.632Z"})))),h("div",{key:"f541cd6ed4d04a52afb093053c6fea85d0926ce1",class:"mb-2"},h("nl-select",{key:"dbce850d0c1d2e1cfdf4ce250978ce508abc173a",onSelectDomain:o=>this.handleDomainSelect(o),selected:0,options:state.nlSignup.servers})),h("div",{key:"a68612eabd83e3f7e61b533fd247f1768554b0c1",class:"ps-4 pe-4 overflow-y-auto"},h("p",{key:"25c8a89289071d5fca16b5e8918026c41afb3a77",class:"nl-error font-light text-center text-sm max-w-96 mx-auto"},state.error)),h("button-base",{key:"6cbf8ff97e9ebf1bd830e86337219ee386f978ea",disabled:state.isLoading,onClick:o=>this.handleCreateAccount(o),titleBtn:"Create profile"},state.isLoading?h("span",{slot:"icon-start",class:"animate-spin-loading inline-block w-4 h-4 border-[3px] border-current border-t-transparent text-slate-900 dark:text-gray-300 rounded-full",role:"status","aria-label":"loading"}):h("svg",{slot:"icon-start",style:{display:"none"},xmlns:"http://www.w3.org/2000/svg",fill:"none",viewBox:"0 0 24 24","stroke-width":"1.5",stroke:"currentColor"},h("path",{"stroke-linecap":"round","stroke-linejoin":"round",d:"M18 7.5v3m0 0v3m0-3h3m-3 0h-3m-2.25-4.125a3.375 3.375 0 1 1-6.75 0 3.375 3.375 0 0 1 6.75 0ZM3 19.235v-.11a6.375 6.375 0 0 1 12.75 0v.109A12.318 12.318 0 0 1 9.374 21c-2.331 0-4.512-.645-6.374-1.766Z"})))))}static get watchers(){return{bunkers:["watchBunkersHandler"]}}static get style(){return NlSignupStyle0}},[0,"nl-signup",{titleSignup:[1,"title-signup"],description:[1],bunkers:[1],isAvailable:[32]},void 0,{bunkers:["watchBunkersHandler"]}]);function defineCustomElement$8(){typeof customElements>"u"||["nl-signup","button-base","nl-select"].forEach(o=>{switch(o){case"nl-signup":customElements.get(o)||customElements.define(o,NlSignup);break;case"button-base":customElements.get(o)||defineCustomElement$q();break;case"nl-select":customElements.get(o)||defineCustomElement$m()}})}defineCustomElement$8();const nlWelcomeCss=baseCss,NlWelcomeStyle0=nlWelcomeCss,NlWelcome=proxyCustomElement(class extends H{constructor(){super(),this.__registerHost(),this.titleWelcome="Welcome to Nostr!",this.description="This website is part of the Nostr network. Log in with your Nostr profile or sign up to join."}handleChangeScreen(o){state.path=[...state.path,o]}render(){return h(Fragment,{key:"d3fb00029cb12cc8b00f26eaed6bd76e90402363"},h("div",{key:"e41a79654adb620ee433848c965fd872cdfcc58c",class:"p-4 overflow-y-auto"},h("h1",{key:"28e5c6ec6a4e4982a386daff93446db4efcd0737",class:"nl-title font-bold text-center text-4xl"},this.titleWelcome),h("p",{key:"d0afbc9587aafe4d93c547b34f5f55c268b42e48",class:"nl-description font-light text-center text-lg pt-2 max-w-96 mx-auto"},this.description)),h("div",{key:"d5570f014a56f326348b8077429c198b55b66683",class:"max-w-52 mx-auto pb-5"},h("div",{key:"3f4095a715c960544264eae1dc809c3bc68de2a8",class:"flex gap-3 flex-col mb-2"},h("button-base",{key:"a154d028e883fb9d9ea1823a5df0d2500bfdb726",titleBtn:"Log in",onClick:()=>this.handleChangeScreen(CURRENT_MODULE.WELCOME_LOGIN)},h("svg",{key:"2b256c1a23f88a3232e59fa3d56c344eae398690",style:{display:"none"},slot:"icon-start",xmlns:"http://www.w3.org/2000/svg",fill:"none",viewBox:"0 0 24 24","stroke-width":"1.5",stroke:"currentColor"},h("path",{key:"bf629d871a100f59c2b465d50f58081290b4300a","stroke-linecap":"round","stroke-linejoin":"round",d:"M15.75 5.25a3 3 0 0 1 3 3m3 0a6 6 0 0 1-7.029 5.912c-.563-.097-1.159.026-1.563.43L10.5 17.25H8.25v2.25H6v2.25H2.25v-2.818c0-.597.237-1.17.659-1.591l6.499-6.499c.404-.404.527-1 .43-1.563A6 6 0 1 1 21.75 8.25Z"})))),h("button-base",{key:"6fdf8ff44483ec67cff96015ebc7d1832a676fa3",onClick:()=>this.handleChangeScreen(CURRENT_MODULE.WELCOME_SIGNUP),titleBtn:"Sign up"},h("svg",{key:"6714790ee5ccb91a6bda3424e515ea273f2163f9",style:{display:"none"},slot:"icon-start",xmlns:"http://www.w3.org/2000/svg",fill:"none",viewBox:"0 0 24 24","stroke-width":"1.5",stroke:"currentColor"},h("path",{key:"e31e8d7667a33a8713387f8eb73252a4016b5de4","stroke-linecap":"round","stroke-linejoin":"round",d:"M18 7.5v3m0 0v3m0-3h3m-3 0h-3m-2.25-4.125a3.375 3.375 0 1 1-6.75 0 3.375 3.375 0 0 1 6.75 0ZM3 19.235v-.11a6.375 6.375 0 0 1 12.75 0v.109A12.318 12.318 0 0 1 9.374 21c-2.331 0-4.512-.645-6.374-1.766Z"})))))}static get style(){return NlWelcomeStyle0}},[0,"nl-welcome",{titleWelcome:[1,"title-welcome"],description:[1]}]);function defineCustomElement$7(){typeof customElements>"u"||["nl-welcome","button-base"].forEach(o=>{switch(o){case"nl-welcome":customElements.get(o)||customElements.define(o,NlWelcome);break;case"button-base":customElements.get(o)||defineCustomElement$q()}})}defineCustomElement$7();const nlWelcomeSigninCss=baseCss,NlWelcomeSigninStyle0=nlWelcomeSigninCss,NlWelcomeSignIn=proxyCustomElement(class extends H{constructor(){super(),this.__registerHost(),this.nlLoginExtension=createEvent(this,"nlLoginExtension",7),this.titleWelcome="Log in",this.hasExtension=!1,this.authMethods=[],this.hasOTP=!1}handleChangeScreen(o){state.path=[...state.path,o],o===CURRENT_MODULE.EXTENSION&&this.nlLoginExtension.emit()}allowAuthMethod(o){return!this.authMethods.length||this.authMethods.includes(o)}renderSignInWithExtension(){return h("button-base",{onClick:()=>this.handleChangeScreen(CURRENT_MODULE.EXTENSION),titleBtn:"With extension"},h("svg",{style:{display:"none"},slot:"icon-start",xmlns:"http://www.w3.org/2000/svg",fill:"none",viewBox:"0 0 24 24","stroke-width":"1.5",stroke:"currentColor"},h("path",{"stroke-linecap":"round","stroke-linejoin":"round",d:"M3 8.25V18a2.25 2.25 0 0 0 2.25 2.25h13.5A2.25 2.25 0 0 0 21 18V8.25m-18 0V6a2.25 2.25 0 0 1 2.25-2.25h13.5A2.25 2.25 0 0 1 21 6v2.25m-18 0h18M5.25 6h.008v.008H5.25V6ZM7.5 6h.008v.008H7.5V6Zm2.25 0h.008v.008H9.75V6Z"})))}render(){return h(Fragment,{key:"49598c3d31f3a4c2fc9d3579283163c43f19b6c7"},h("div",{key:"6b3c16634c1dc4be65c425edb65f5070990fee91",class:"p-4 overflow-y-auto"},h("h1",{key:"1f60d1f489afaa42c47e28563fadc0fa7b46a3df",class:"nl-title font-bold text-center text-3xl"},this.titleWelcome)),h("div",{key:"01507d2b6d0bba54527e12d664ddefd7244a9697",class:"max-w-52 mx-auto pb-5"},h("div",{key:"82deccfff688e1cbb67191c90a3ca6f22f285744",class:"flex gap-3 flex-col"},this.allowAuthMethod("connect")&&h("button-base",{key:"177bbcf244409242ab1c7c03cfb60300e848fed2",titleBtn:"Connect",onClick:()=>this.handleChangeScreen(CURRENT_MODULE.CONNECT)},h("svg",{key:"1fa2c695562eb093430389253dd7f94733d63976",style:{display:"none"},slot:"icon-start",xmlns:"http://www.w3.org/2000/svg",fill:"none",viewBox:"0 0 24 24","stroke-width":"1.5",stroke:"currentColor"},h("path",{key:"16323646bde098c55c787cc90b66b4952c803542","stroke-linecap":"round","stroke-linejoin":"round",d:"M8.25 9V5.25A2.25 2.25 0 0 1 10.5 3h6a2.25 2.25 0 0 1 2.25 2.25v13.5A2.25 2.25 0 0 1 16.5 21h-6a2.25 2.25 0 0 1-2.25-2.25V15M12 9l3 3m0 0-3 3m3-3H2.25"}))),this.allowAuthMethod("readOnly")&&h("button-base",{key:"9b6d546d7f34ca197baa13ec0f280890ff0d8c7f",onClick:()=>this.handleChangeScreen(CURRENT_MODULE.LOGIN_READ_ONLY),titleBtn:"Read only"},h("svg",{key:"2ab8c1763d88e7c5678cafc3c15817d60a7bb6c0",style:{display:"none"},slot:"icon-start",xmlns:"http://www.w3.org/2000/svg",fill:"none",viewBox:"0 0 24 24","stroke-width":"1.5",stroke:"currentColor"},h("path",{key:"faa5a61e8d35daf7fbb64fc5783c23b8881d8100","stroke-linecap":"round","stroke-linejoin":"round",d:"M2.036 12.322a1.012 1.012 0 0 1 0-.639C3.423 7.51 7.36 4.5 12 4.5c4.638 0 8.573 3.007 9.963 7.178.07.207.07.431 0 .639C20.577 16.49 16.64 19.5 12 19.5c-4.638 0-8.573-3.007-9.963-7.178Z"}),h("path",{key:"6083db853e798c9764b11ed4701dab048d4f30f2","stroke-linecap":"round","stroke-linejoin":"round",d:"M15 12a3 3 0 1 1-6 0 3 3 0 0 1 6 0Z"}))),this.hasOTP&&this.allowAuthMethod("otp")&&h("button-base",{key:"f45b1afed2d9b10a2d77eaa59b1aa168eabb191d",titleBtn:"One-time code",onClick:()=>this.handleChangeScreen(CURRENT_MODULE.LOGIN_OTP)},h("svg",{key:"84fbe5952fecd429f8074c65675d2111eb2d7fe8",style:{display:"none"},slot:"icon-start",xmlns:"http://www.w3.org/2000/svg",fill:"none",viewBox:"0 0 24 24","stroke-width":"1.5",stroke:"currentColor"},h("path",{key:"83dc6eaa4e128065dfd7e97f0950cd00f0be6d54","stroke-linecap":"round","stroke-linejoin":"round",d:"M12 6v6h4.5m4.5 0a9 9 0 1 1-18 0 9 9 0 0 1 18 0Z"}))),this.hasExtension&&this.allowAuthMethod("extension")&&this.renderSignInWithExtension(),!this.allowAuthMethod("connect")&&!this.hasExtension&&h("p",{key:"f94e3302a807855f45855302482542e6f79f8ec8",class:"nl-description font-light text-center text-lg pt-2 max-w-96 mx-auto"},"No Nostr extension!"),!this.allowAuthMethod("connect")&&this.hasExtension&&!this.allowAuthMethod("extension")&&h("p",{key:"552762dfd2b9d24c7279c1f500ccd94500e35be1",class:"nl-description font-light text-center text-lg pt-2 max-w-96 mx-auto"},"Use advanced options."))))}static get style(){return NlWelcomeSigninStyle0}},[0,"nl-welcome-signin",{titleWelcome:[1,"title-welcome"],hasExtension:[4,"has-extension"],authMethods:[16],hasOTP:[4,"has-o-t-p"]}]);function defineCustomElement$6(){typeof customElements>"u"||["nl-welcome-signin","button-base"].forEach(o=>{switch(o){case"nl-welcome-signin":customElements.get(o)||customElements.define(o,NlWelcomeSignIn);break;case"button-base":customElements.get(o)||defineCustomElement$q()}})}defineCustomElement$6();const nlWelcomeSignupCss=baseCss,NlWelcomeSignupStyle0=nlWelcomeSignupCss,NlWelcomeSignUp=proxyCustomElement(class extends H{constructor(){super(),this.__registerHost(),this.titleWelcome="Sign up",this.description="Nostr profiles are based on cryptographic keys. You can create keys right here, or with a key storage app."}handleChangeScreen(o){state.path=[...state.path,o]}render(){return h(Fragment,{key:"95a13ee24b5203b1f1fe9f355524abba9dc55dcb"},h("div",{key:"23209055b5ab42ed4e147f0d7e38ec320437f783",class:"p-4 overflow-y-auto"},h("h1",{key:"8f06a983aa9ca0caa01dd35d4907552696ffc996",class:"nl-title font-bold text-center text-3xl"},this.titleWelcome),h("p",{key:"14d88998c67951b047b79dd0d9358ae2b7a19895",class:"nl-description font-light text-center text-lg pt-2 max-w-96 mx-auto"},this.description)),h("div",{key:"62344241204e1c08e2d497b0bbc28b9aff3d7640",class:"max-w-52 mx-auto pb-5"},h("div",{key:"641c269ff23d94330acf465e62d294ce42b05212",class:"flex gap-3 flex-col"},h("button-base",{key:"aaa7f28f647f05506e93756df2895cef952b2912",onClick:()=>this.handleChangeScreen(CURRENT_MODULE.LOCAL_SIGNUP),titleBtn:"Create keys"},h("svg",{key:"2e8c77cdd122a51638f9a2e606d9ff33581b84c7",style:{display:"none"},slot:"icon-start",xmlns:"http://www.w3.org/2000/svg",fill:"none",viewBox:"0 0 24 24","stroke-width":"1.5",stroke:"currentColor"},h("path",{key:"b6d0e6199dcc11a7ac9f4ba47c86219e325fa987","stroke-linecap":"round","stroke-linejoin":"round",d:"M15.75 5.25a3 3 0 0 1 3 3m3 0a6 6 0 0 1-7.029 5.912c-.563-.097-1.159.026-1.563.43L10.5 17.25H8.25v2.25H6v2.25H2.25v-2.818c0-.597.237-1.17.659-1.591l6.499-6.499c.404-.404.527-1 .43-1.563A6 6 0 1 1 21.75 8.25Z"}))),h("button-base",{key:"3c239d1df872ac71424478fd3f6857c5a9148ef6",onClick:()=>this.handleChangeScreen(CURRENT_MODULE.SIGNUP),titleBtn:"With key store"},h("svg",{key:"4600c4e8bb4e62d9a0303ae1abc464c6d6fc7899",style:{display:"none"},slot:"icon-start",xmlns:"http://www.w3.org/2000/svg",fill:"none",viewBox:"0 0 24 24","stroke-width":"1.5",stroke:"currentColor"},h("path",{key:"c36bef296a15f3bb43c984ed083a8defeb530ab4","stroke-linecap":"round","stroke-linejoin":"round",d:"M20.25 6.375c0 2.278-3.694 4.125-8.25 4.125S3.75 8.653 3.75 6.375m16.5 0c0-2.278-3.694-4.125-8.25-4.125S3.75 4.097 3.75 6.375m16.5 0v11.25c0 2.278-3.694 4.125-8.25 4.125s-8.25-1.847-8.25-4.125V6.375m16.5 0v3.75m-16.5-3.75v3.75m16.5 0v3.75C20.25 16.153 16.556 18 12 18s-8.25-1.847-8.25-4.125v-3.75m16.5 0c0 2.278-3.694 4.125-8.25 4.125s-8.25-1.847-8.25-4.125"}))))))}static get style(){return NlWelcomeSignupStyle0}},[0,"nl-welcome-signup",{titleWelcome:[1,"title-welcome"],description:[1]}]);function defineCustomElement$5(){typeof customElements>"u"||["nl-welcome-signup","button-base"].forEach(o=>{switch(o){case"nl-welcome-signup":customElements.get(o)||customElements.define(o,NlWelcomeSignUp);break;case"button-base":customElements.get(o)||defineCustomElement$q()}})}defineCustomElement$5();const nlAuthCss=baseCss,NlAuthStyle0=nlAuthCss,NlAuth=proxyCustomElement(class extends H{constructor(){super(),this.__registerHost(),this.__attachShadow(),this.nlCloseModal=createEvent(this,"nlCloseModal",7),this.nlChangeDarkMode=createEvent(this,"nlChangeDarkMode",7),this.theme="default",this.bunkers="",this.startScreen=CURRENT_MODULE.WELCOME,this.authMethods=[],this.hasExtension=!1,this.hasOTP=!1,this.isLoading=!1,this.isLoadingExtension=!1,this.isOTP=!1,this.authUrl="",this.iframeUrl="",this.error="",this.localSignup=!1,this.accounts=[],this.recents=[],this.darkMode=!1,this.welcomeTitle="",this.welcomeDescription="",this.connectionString="",this.connectionStringServices=[]}watchLocalSignupHandler(o){state.localSignup=o}watchLoadingHandler(o){state.isLoading=o}watchLoadingExtensionHandler(o){state.isLoadingExtension=o}watchOTPHandler(o){state.isOTP=o}watchAuthUrlHandler(o){state.authUrl=o}watchIframeUrlHandler(o){state.iframeUrl=o}watchErrorHandler(o){state.error=o}handleClose(){this.nlCloseModal.emit()}handleChangeDarkMode(){this.nlChangeDarkMode.emit(!this.darkMode)}componentWillLoad(){state.path=[this.startScreen],state.localSignup=this.localSignup,state.error="",state.iframeUrl="",state.authUrl="",state.isLoading=!1,state.isLoadingExtension=!1,state.isOTP=!1,console.log("path",state.path)}handleClickToBack(){state.path.pop(),state.path=[...state.path],state.isLoading=!1,state.isLoadingExtension=!1,state.authUrl="",state.isOTP=!1}switchSignSignUpStrategy(o){state.path=CURRENT_MODULE.LOCAL_SIGNUP!==o?[CURRENT_MODULE.WELCOME,o]:[CURRENT_MODULE.WELCOME,CURRENT_MODULE.WELCOME_SIGNUP,o]}render(){const o="w-full h-full fixed top-0 start-0 z-[80] overflow-x-hidden overflow-y-auto flex items-center "+(this.darkMode?"dark":""),s=state.path.at(-1),r=state.isOTP||s!==CURRENT_MODULE.INFO&&s!==CURRENT_MODULE.CONFIRM_LOGOUT&&s!==CURRENT_MODULE.IMPORT_FLOW&&s!==CURRENT_MODULE.WELCOME&&s!==CURRENT_MODULE.EXTENSION&&s!==CURRENT_MODULE.IFRAME&&s!==CURRENT_MODULE.PREVIOUSLY_LOGGED,i=s!==CURRENT_MODULE.IFRAME&&(!this.authMethods.length||!this.localSignup&&this.authMethods.includes("connect")||this.localSignup&&this.authMethods.includes("local"));return h("div",{class:`theme-${this.theme}`},h("div",{class:o},h("div",{onClick:()=>this.handleClose(),class:"absolute top-0 left-0 w-full h-full bg-gray-500 bg-opacity-75 z-[80]"}),h("div",{class:"nl-bg relative z-[81] w-full flex flex-col rounded-xl sm:max-w-lg sm:w-full sm:mx-auto"},h("div",{class:"flex justify-between items-center py-3 px-4"},h("div",{class:"flex gap-2 items-center"},h("svg",{class:"w-7 h-7",width:"225",height:"224",viewBox:"0 0 225 224",fill:"none",xmlns:"http://www.w3.org/2000/svg"},h("rect",{width:"224.047",height:"224",rx:"64",fill:"#6951FA"}),h("path",{d:"M162.441 135.941V88.0593C170.359 85.1674 176 77.5348 176 68.6696C176 57.2919 166.708 48 155.33 48C143.953 48 134.661 57.2444 134.661 68.6696C134.661 77.5822 140.302 85.1674 148.219 88.0593V135.941C147.698 136.13 147.176 136.367 146.655 136.604L87.3956 77.3452C88.6282 74.6904 89.2919 71.7511 89.2919 68.6696C89.2919 57.2444 80.0474 48 68.6696 48C57.2919 48 48 57.2444 48 68.6696C48 77.5822 53.6415 85.1674 61.5585 88.0593V135.941C53.6415 138.833 48 146.465 48 155.33C48 166.708 57.2444 176 68.6696 176C80.0948 176 89.3393 166.708 89.3393 155.33C89.3393 146.418 83.6978 138.833 75.7807 135.941V88.0593C76.3022 87.8696 76.8237 87.6326 77.3452 87.3956L136.604 146.655C135.372 149.31 134.708 152.249 134.708 155.33C134.708 166.708 143.953 176 155.378 176C166.803 176 176.047 166.708 176.047 155.33C176.047 146.418 170.406 138.833 162.489 135.941H162.441Z",fill:"white"})),h("p",{class:"font-bold nl-logo text-base"},"Nostr ",h("span",{class:"font-light"},"Login"))),h("div",{class:"flex gap-1"},h("button",{onClick:()=>this.handleChangeDarkMode(),type:"button",class:"nl-action-button flex justify-center items-center w-7 h-7 text-sm font-semibold rounded-full border border-transparent"},h("span",{class:"sr-only"},"Change theme"),h("svg",{xmlns:"http://www.w3.org/2000/svg",fill:"none",viewBox:"0 0 24 24","stroke-width":"1.5",stroke:"currentColor",class:"flex-shrink-0 w-5 h-5"},h("path",this.darkMode?{"stroke-linecap":"round","stroke-linejoin":"round",d:"M12 3v2.25m6.364.386-1.591 1.591M21 12h-2.25m-.386 6.364-1.591-1.591M12 18.75V21m-4.773-4.227-1.591 1.591M5.25 12H3m4.227-4.773L5.636 5.636M15.75 12a3.75 3.75 0 1 1-7.5 0 3.75 3.75 0 0 1 7.5 0Z"}:{"stroke-linecap":"round","stroke-linejoin":"round",d:"M21.752 15.002A9.72 9.72 0 0 1 18 15.75c-5.385 0-9.75-4.365-9.75-9.75 0-1.33.266-2.597.748-3.752A9.753 9.753 0 0 0 3 11.25C3 16.635 7.365 21 12.75 21a9.753 9.753 0 0 0 9.002-5.998Z"}))),!state.isLoading&&h("button",{onClick:()=>state.path=[...state.path,CURRENT_MODULE.INFO],type:"button",class:"nl-action-button flex justify-center items-center w-7 h-7 text-sm font-semibold rounded-full border border-transparent"},h("span",{class:"sr-only"},"Info"),h("svg",{xmlns:"http://www.w3.org/2000/svg",fill:"none",viewBox:"0 0 24 24","stroke-width":"1.5",stroke:"currentColor",class:"flex-shrink-0 w-5 h-5"},h("path",{"stroke-linecap":"round","stroke-linejoin":"round",d:"m11.25 11.25.041-.02a.75.75 0 0 1 1.063.852l-.708 2.836a.75.75 0 0 0 1.063.853l.041-.021M21 12a9 9 0 1 1-18 0 9 9 0 0 1 18 0Zm-9-3.75h.008v.008H12V8.25Z"}))),h("button",{onClick:()=>this.handleClose(),type:"button",class:"nl-action-button flex justify-center items-center w-7 h-7 text-sm font-semibold rounded-full border border-transparent"},h("span",{class:"sr-only"},"Close"),h("svg",{class:"flex-shrink-0 w-5 h-5",xmlns:"http://www.w3.org/2000/svg",width:"24",height:"24",viewBox:"0 0 24 24",fill:"none",stroke:"currentColor","stroke-width":"2","stroke-linecap":"round","stroke-linejoin":"round"},h("path",{d:"M18 6 6 18"}),h("path",{d:"m6 6 12 12"}))))),state.path.length>1&&!state.isLoading&&h("div",{class:"p-4"},h("button",{onClick:()=>this.handleClickToBack(),type:"button",class:"nl-action-button flex justify-center items-center w-7 h-7 text-sm font-semibold rounded-full border border-transparent dark:focus:outline-none dark:focus:ring-1 dark:focus:ring-gray-600","data-hs-overlay":"#hs-vertically-centered-modal"},h("span",{class:"sr-only"},"Back"),h("svg",{xmlns:"http://www.w3.org/2000/svg",fill:"none",viewBox:"0 0 24 24","stroke-width":"1.5",stroke:"currentColor",class:"flex-shrink-0 w-5 h-5"},h("path",{"stroke-linecap":"round","stroke-linejoin":"round",d:"M10.5 19.5 3 12m0 0 7.5-7.5M3 12h18"})))),state.isLoading||state.authUrl?h("nl-loading",{path:s}):h(Fragment,null,(()=>{if(state.isOTP)return h("nl-signin-otp",null);switch(s){case CURRENT_MODULE.WELCOME:return h("nl-welcome",{titleWelcome:this.welcomeTitle||void 0,description:this.welcomeDescription||void 0});case CURRENT_MODULE.LOGIN:return h("nl-signin",null);case CURRENT_MODULE.SIGNUP:return h("nl-signup",{bunkers:this.bunkers});case CURRENT_MODULE.LOCAL_SIGNUP:return h("nl-local-signup",null);case CURRENT_MODULE.CONFIRM_LOGOUT:return h("nl-confirm-logout",null);case CURRENT_MODULE.IMPORT_FLOW:return h("nl-import-flow",{services:this.connectionStringServices});case CURRENT_MODULE.IMPORT_OTP:return h("nl-otp-migrate",{services:this.connectionStringServices});case CURRENT_MODULE.INFO:return h("nl-info",null);case CURRENT_MODULE.EXTENSION:return h("nl-info-extension",null);case CURRENT_MODULE.LOGIN_READ_ONLY:return h("nl-signin-read-only",null);case CURRENT_MODULE.LOGIN_BUNKER_URL:return h("nl-signin-bunker-url",null);case CURRENT_MODULE.LOGIN_OTP:return h("nl-signin-otp",null);case CURRENT_MODULE.WELCOME_LOGIN:return h("nl-welcome-signin",{hasOTP:this.hasOTP,authMethods:this.authMethods,hasExtension:this.hasExtension});case CURRENT_MODULE.WELCOME_SIGNUP:return h("nl-welcome-signup",null);case CURRENT_MODULE.CONNECTION_STRING:return h("nl-signin-connection-string",{connectionString:this.connectionString});case CURRENT_MODULE.CONNECT:return h("nl-connect",{connectionStringServices:this.connectionStringServices,authMethods:this.authMethods});case CURRENT_MODULE.PREVIOUSLY_LOGGED:return h("nl-previously-logged",{accounts:this.accounts,recents:this.recents});case CURRENT_MODULE.IFRAME:return h("nl-iframe",{iframeUrl:this.authUrl});default:return h("nl-welcome",null)}})(),r&&h(Fragment,null,s===CURRENT_MODULE.WELCOME_SIGNUP||s===CURRENT_MODULE.SIGNUP||s===CURRENT_MODULE.LOCAL_SIGNUP?h("div",{class:"p-4 overflow-y-auto"},h("p",{class:"nl-footer font-light text-center text-sm pt-3 max-w-96 mx-auto"},"If you already have a profile please"," ",h("span",{onClick:()=>this.switchSignSignUpStrategy(CURRENT_MODULE.WELCOME_LOGIN),class:"cursor-pointer text-blue-400"},"log in"),".")):i&&h("div",{class:"p-4 overflow-y-auto"},h("p",{class:"nl-footer font-light text-center text-sm pt-3 max-w-96 mx-auto"},"If you don't have a profile please"," ",h("span",{onClick:()=>this.switchSignSignUpStrategy(this.localSignup?CURRENT_MODULE.LOCAL_SIGNUP:CURRENT_MODULE.WELCOME_SIGNUP),class:"cursor-pointer text-blue-400"},"sign up"),".")))))))}static get watchers(){return{localSignup:["watchLocalSignupHandler"],isLoading:["watchLoadingHandler"],isLoadingExtension:["watchLoadingExtensionHandler"],isOTP:["watchOTPHandler"],authUrl:["watchAuthUrlHandler"],iframeUrl:["watchIframeUrlHandler"],error:["watchErrorHandler"]}}static get style(){return NlAuthStyle0}},[1,"nl-auth",{theme:[1025],bunkers:[1],startScreen:[1,"start-screen"],authMethods:[16],hasExtension:[4,"has-extension"],hasOTP:[4,"has-o-t-p"],isLoading:[4,"is-loading"],isLoadingExtension:[4,"is-loading-extension"],isOTP:[4,"is-o-t-p"],authUrl:[1,"auth-url"],iframeUrl:[1,"iframe-url"],error:[1],localSignup:[4,"local-signup"],accounts:[1040],recents:[1040],darkMode:[1028,"dark-mode"],welcomeTitle:[1,"welcome-title"],welcomeDescription:[1,"welcome-description"],connectionString:[1,"connection-string"],connectionStringServices:[16]},void 0,{localSignup:["watchLocalSignupHandler"],isLoading:["watchLoadingHandler"],isLoadingExtension:["watchLoadingExtensionHandler"],isOTP:["watchOTPHandler"],authUrl:["watchAuthUrlHandler"],iframeUrl:["watchIframeUrlHandler"],error:["watchErrorHandler"]}]);function defineCustomElement$4(){typeof customElements>"u"||["nl-auth","button-base","nl-confirm-logout","nl-connect","nl-iframe","nl-import-flow","nl-info","nl-info-extension","nl-loading","nl-local-signup","nl-login-status","nl-otp-migrate","nl-previously-logged","nl-select","nl-signin","nl-signin-bunker-url","nl-signin-connection-string","nl-signin-otp","nl-signin-read-only","nl-signup","nl-welcome","nl-welcome-signin","nl-welcome-signup"].forEach(o=>{switch(o){case"nl-auth":customElements.get(o)||customElements.define(o,NlAuth);break;case"button-base":customElements.get(o)||defineCustomElement$q();break;case"nl-confirm-logout":customElements.get(o)||defineCustomElement$p();break;case"nl-connect":customElements.get(o)||defineCustomElement$o();break;case"nl-iframe":customElements.get(o)||defineCustomElement$n();break;case"nl-import-flow":customElements.get(o)||defineCustomElement$l();break;case"nl-info":customElements.get(o)||defineCustomElement$k();break;case"nl-info-extension":customElements.get(o)||defineCustomElement$j();break;case"nl-loading":customElements.get(o)||defineCustomElement$i();break;case"nl-local-signup":customElements.get(o)||defineCustomElement$h();break;case"nl-login-status":customElements.get(o)||defineCustomElement$g();break;case"nl-otp-migrate":customElements.get(o)||defineCustomElement$f();break;case"nl-previously-logged":customElements.get(o)||defineCustomElement$e();break;case"nl-select":customElements.get(o)||defineCustomElement$m();break;case"nl-signin":customElements.get(o)||defineCustomElement$d();break;case"nl-signin-bunker-url":customElements.get(o)||defineCustomElement$c();break;case"nl-signin-connection-string":customElements.get(o)||defineCustomElement$b();break;case"nl-signin-otp":customElements.get(o)||defineCustomElement$a();break;case"nl-signin-read-only":customElements.get(o)||defineCustomElement$9();break;case"nl-signup":customElements.get(o)||defineCustomElement$8();break;case"nl-welcome":customElements.get(o)||defineCustomElement$7();break;case"nl-welcome-signin":customElements.get(o)||defineCustomElement$6();break;case"nl-welcome-signup":customElements.get(o)||defineCustomElement$5()}})}defineCustomElement$4();const NlButton=proxyCustomElement(class extends H{constructor(){super(),this.__registerHost(),this.__attachShadow(),this.theme="default",this.darkMode=!1,this.titleBtn="Open modal",this.disabled=!1}render(){return h("button-base",{key:"9f7936090efc7263cce71d1ad89490d7f5445991",theme:this.theme,darkMode:this.darkMode,titleBtn:this.titleBtn,disabled:this.disabled})}},[1,"nl-button",{theme:[1],darkMode:[4,"dark-mode"],titleBtn:[1,"title-btn"],disabled:[4]}]);function defineCustomElement$3(){typeof customElements>"u"||["nl-button","button-base"].forEach(o=>{switch(o){case"nl-button":customElements.get(o)||customElements.define(o,NlButton);break;case"button-base":customElements.get(o)||defineCustomElement$q()}})}defineCustomElement$3();const nlChangeAccountCss=baseCss,NlChangeAccountStyle0=nlChangeAccountCss,NLChangeAccount=proxyCustomElement(class extends H{constructor(){super(),this.__registerHost(),this.handleOpenWelcomeModal=createEvent(this,"handleOpenWelcomeModal",7),this.handleSwitchAccount=createEvent(this,"handleSwitchAccount",7),this.isOpen=!1,this.options=[],this.accounts=[],this.currentAccount=null,this.mode=!1,this.darkMode=!1,this.themeState="default",this.theme="default"}handleWindowClick(){this.wrapperRef.querySelector(".listClass")&&(this.isOpen=!1)}toggleDropdown(){this.isOpen=!this.isOpen,this.calculateDropdownPosition()}watchPropHandler(o){this.themeState=o}watchModeHandler(o){this.mode=o}watchAccountsHandler(o){this.options=o}connectedCallback(){this.themeState=this.theme,this.mode=this.darkMode}calculateDropdownPosition(){if(this.isOpen&&this.buttonRef){const o=this.buttonRef.getBoundingClientRect();this.ulRef.style.top=`${o.height}px`}}handleChange(o){this.handleSwitchAccount.emit(o)}handleOpenModal(){this.handleOpenWelcomeModal.emit()}render(){const o=(this.isOpen?"listClass flex flex-col gap-2":"hidden")+" w-full nl-select-list absolute z-10 left-0 shadow-md rounded-lg p-2 mt-1 after:h-4 after:absolute after:-bottom-4 after:start-0 after:w-full before:h-4 before:absolute before:-top-4 before:start-0 before:w-full",s=(this.isOpen?"rotate-180":"rotate-0")+" duration-300 flex-shrink-0 w-4 h-4 text-gray-500",r=this.options&&this.currentAccount?this.options.filter(i=>i.pubkey!==this.currentAccount.pubkey||i.authMethod!==this.currentAccount.authMethod):[];return h("div",{key:"4e15e39f7ac6a552bfc772396e3e9ef8eeca95cc",class:`theme-${this.themeState}`},h("div",{key:"eae10769ce35dc4cc072d2361c1ee1390c79c822",class:"relative",ref:i=>this.wrapperRef=i},h("button",{key:"e585a44168809f27b99201f7e13bd5db5e4f6569",ref:i=>this.buttonRef=i,onClick:()=>this.toggleDropdown(),type:"button",class:"nl-select peer py-3 px-4 flex items-center w-full justify-between border-transparent rounded-lg text-sm disabled:opacity-50 disabled:pointer-events-none dark:border-transparent"},h("span",{key:"006ed9a67b57227d4dab51f0b6bcb8290cd9d3ac",class:"text-gray-500"},"Switch profile"),h("svg",{key:"5f824a479165929698fab31b8837b89418587652",class:s,xmlns:"http://www.w3.org/2000/svg",width:"24",height:"24",viewBox:"0 0 24 24",fill:"none",stroke:"currentColor","stroke-width":"2","stroke-linecap":"round","stroke-linejoin":"round"},h("path",{key:"600914907723c9f8d01a15da357ccb825c1d1e6a",d:"m6 9 6 6 6-6"}))),h("ul",{key:"9b5b68724a3bce995e6b8b0a9d0eb653baedf79a",ref:i=>this.ulRef=i,class:o},this.options&&r.map(i=>{const c=i.name||i.nip05||i.pubkey;return h("li",{onClick:()=>this.handleChange(i),class:"nl-select-option flex cursor-pointer items-center gap-x-3.5 py-2 px-3 rounded-lg text-sm"},h("div",{class:"uppercase font-bold w-full max-w-6 h-6 rounded-full border border-gray-400 flex justify-center items-center"},i?.picture?h("img",{class:"w-full rounded-full",src:i.picture,alt:"Logo"}):c?c[0]:h("svg",{xmlns:"http://www.w3.org/2000/svg",fill:"none",viewBox:"0 0 24 24","stroke-width":"1.5",stroke:"currentColor",class:"w-full"},h("path",{"stroke-linecap":"round","stroke-linejoin":"round",d:"M17.982 18.725A7.488 7.488 0 0 0 12 15.75a7.488 7.488 0 0 0-5.982 2.975m11.963 0a9 9 0 1 0-11.963 0m11.963 0A8.966 8.966 0 0 1 12 21a8.966 8.966 0 0 1-5.982-2.275M15 9.75a3 3 0 1 1-6 0 3 3 0 0 1 6 0Z"}))),h("div",{class:"overflow-hidden flex flex-col w-full"},h("div",{class:"truncate overflow-hidden"},c),h("nl-login-status",{info:i})))}),h("li",{key:"936f2b75ca2dfca3483650d5d62fc50182cfc8f2",class:"first:pt-0 pt-2 border-t-[1px] first:border-none border-gray-300"},h("div",{key:"be0b4f29e70d8e2bc9fd1cc04c0fb43ad3dd5cac",onClick:()=>this.handleOpenModal(),class:"nl-select-option flex cursor-pointer items-center gap-x-3.5 py-2 px-3 rounded-lg text-sm"},h("div",{key:"bdd2a67e5763726666fcea91b0e7de67fe855994",class:"uppercase font-bold w-6 h-6 rounded-full border border-gray-400 flex justify-center items-center"},h("svg",{key:"f3a258f3e510ccb83b95bf3abecf65c248c8b0f1",xmlns:"http://www.w3.org/2000/svg",fill:"none",viewBox:"0 0 24 24","stroke-width":"1.5",stroke:"currentColor",class:"w-4 h-4"},h("path",{key:"dafaa898f3e042531a923a9a77b94511895c6102","stroke-linecap":"round","stroke-linejoin":"round",d:"M12 4.5v15m7.5-7.5h-15"}))),"Add profile")))))}get element(){return this}static get watchers(){return{theme:["watchPropHandler"],darkMode:["watchModeHandler"],accounts:["watchAccountsHandler"]}}static get style(){return NlChangeAccountStyle0}},[0,"nl-change-account",{accounts:[16],currentAccount:[16],darkMode:[4,"dark-mode"],theme:[1],isOpen:[32],options:[32],mode:[32],themeState:[32]},[[8,"click","handleWindowClick"]],{theme:["watchPropHandler"],darkMode:["watchModeHandler"],accounts:["watchAccountsHandler"]}]);function defineCustomElement$2(){typeof customElements>"u"||["nl-change-account","nl-login-status"].forEach(o=>{switch(o){case"nl-change-account":customElements.get(o)||customElements.define(o,NLChangeAccount);break;case"nl-login-status":customElements.get(o)||defineCustomElement$g()}})}defineCustomElement$2();const nlDialogCss=baseCss,NlDialogStyle0=nlDialogCss,NlDialog=proxyCustomElement(class extends H{constructor(){super(),this.__registerHost(),this.__attachShadow()}componentDidLoad(){var o;null===(o=this.dialogElement)||void 0===o||o.showModal()}disconnectedCallback(){var o;null===(o=this.dialogElement)||void 0===o||o.close()}render(){return h("dialog",{key:"9c20328d937c160bcb9b9bf731d744721e84f189",ref:o=>this.dialogElement=o,class:"m-auto nl-banner-dialog"},h("slot",{key:"2e047d7c9e8904d590c588b73a5480cb1605ff86"}))}static get style(){return NlDialogStyle0}},[1,"nl-dialog"]);function defineCustomElement$1(){typeof customElements>"u"||["nl-dialog"].forEach(o=>{"nl-dialog"===o&&(customElements.get(o)||customElements.define(o,NlDialog))})}defineCustomElement$1();const nlBannerCss=baseCss,NlBannerStyle0=nlBannerCss,NlBanner=proxyCustomElement(class extends H{constructor(){super(),this.__registerHost(),this.__attachShadow(),this.handleNotifyConfirmBanner=createEvent(this,"handleNotifyConfirmBanner",7),this.handleNotifyConfirmBannerIframe=createEvent(this,"handleNotifyConfirmBannerIframe",7),this.handleLoginBanner=createEvent(this,"handleLoginBanner",7),this.handleLogoutBanner=createEvent(this,"handleLogoutBanner",7),this.handleOpenWelcomeModal=createEvent(this,"handleOpenWelcomeModal",7),this.handleConfirmLogout=createEvent(this,"handleConfirmLogout",7),this.handleImportModal=createEvent(this,"handleImportModal",7),this.theme="default",this.darkMode=!1,this.hiddenMode=!1,this.titleBanner="",this.isOpen=!1,this.isLoading=!1,this.notify=null,this.userInfo=null,this.accounts=[],this.isUserImgError=!1,this.domain="",this.mode="",this.url="",this.isOpenConfirm=!1}watchNotifyHandler(o){var s,r,i,a;this.isOpen=!0,this.isOpenConfirm=!0,this.domain=(null===(s=this.userInfo)||void 0===s?void 0:s.domain)||(null===(a=null===(i=null===(r=this.userInfo)||void 0===r?void 0:r.nip05)||void 0===i?void 0:i.split("@"))||void 0===a?void 0:a[1])||"",this.mode=o.mode,this.url=o.url,this.mode||(this.isOpenConfirm=!1,this.isOpen=!1)}handleOpen(){this.userInfo?this.isOpen=!0:this.handleOpenWelcomeModal.emit()}handleClose(){this.isOpen=!1}handleLogin(){this.handleLoginBanner.emit(METHOD_MODULE.LOGIN),this.handleClose()}handleSignup(){this.handleLoginBanner.emit(METHOD_MODULE.SIGNUP),this.handleClose()}handleImport(){this.handleImportModal.emit(),this.handleClose()}handleLogout(){if(localStorage.getItem("backupKey"))return this.handleLogoutBanner.emit(METHOD_MODULE.LOGOUT),this.handleClose(),void localStorage.removeItem("backupKey");"local"===this.userInfo.authMethod?this.handleConfirmLogout.emit():this.handleLogoutBanner.emit(METHOD_MODULE.LOGOUT),this.handleClose()}handleConfirm(){switch(this.mode){case"authUrl":this.handleNotifyConfirmBanner.emit(this.url);break;case"iframeAuthUrl":this.handleNotifyConfirmBannerIframe.emit(this.url)}this.handleClose()}render(){var o,s,r,i,a,c;const y=!(null===(o=this.userInfo)||void 0===o||!o.picture),w=(null===(s=this.userInfo)||void 0===s?void 0:s.name)||(null===(a=null===(i=null===(r=this.userInfo)||void 0===r?void 0:r.nip05)||void 0===i?void 0:i.split("@"))||void 0===a?void 0:a[0])||(null===(c=this.userInfo)||void 0===c?void 0:c.pubkey)||"",C=!!w,T=this.userInfo&&"local"===this.userInfo.authMethod,S=localStorage.getItem("backupKey"),M=h("svg",{xmlns:"http://www.w3.org/2000/svg",fill:"none",viewBox:"0 0 24 24","stroke-width":"1.5",stroke:"currentColor",class:"w-full"},h("path",{"stroke-linecap":"round","stroke-linejoin":"round",d:"M17.982 18.725A7.488 7.488 0 0 0 12 15.75a7.488 7.488 0 0 0-5.982 2.975m11.963 0a9 9 0 1 0-11.963 0m11.963 0A8.966 8.966 0 0 1 12 21a8.966 8.966 0 0 1-5.982-2.275M15 9.75a3 3 0 1 1-6 0 3 3 0 0 1 6 0Z"})),O=h(Fragment,null,h("div",{class:"block w-[48px] h-[46px] relative z-10"},h("div",{onClick:()=>this.handleOpen(),class:"flex w-52 h-[46px] items-center pl-[11px]"},h("span",{class:(this.isLoading?"w-5 h-5 border-[2px] mr-3.5 ml-[2px] opacity-1":"w-0 h-0 border-[0px] mr-0 opacity-0 ml-0")+" animate-spin transition-all duration-300 ease-in-out inline-block border-current border-t-transparent text-slate-900 dark:text-gray-300 rounded-full",role:"status","aria-label":"loading"}),this.userInfo?h("div",{class:"uppercase font-bold w-6 h-6 mr-2 rounded-full border border-gray-200 flex justify-center items-center"},y?this.isUserImgError?M:h("img",{class:"w-full rounded-full",src:this.userInfo.picture,alt:"Logo",onError:()=>this.isUserImgError=!0}):C?w[0]:M):h("div",{class:"flex justify-center items-center"},h("svg",{class:"w-6 h-6",width:"225",height:"224",viewBox:"0 0 225 224",fill:"none",xmlns:"http://www.w3.org/2000/svg"},h("rect",{width:"224.047",height:"224",rx:"64",fill:"#6951FA"}),h("path",{d:"M162.441 135.941V88.0593C170.359 85.1674 176 77.5348 176 68.6696C176 57.2919 166.708 48 155.33 48C143.953 48 134.661 57.2444 134.661 68.6696C134.661 77.5822 140.302 85.1674 148.219 88.0593V135.941C147.698 136.13 147.176 136.367 146.655 136.604L87.3956 77.3452C88.6282 74.6904 89.2919 71.7511 89.2919 68.6696C89.2919 57.2444 80.0474 48 68.6696 48C57.2919 48 48 57.2444 48 68.6696C48 77.5822 53.6415 85.1674 61.5585 88.0593V135.941C53.6415 138.833 48 146.465 48 155.33C48 166.708 57.2444 176 68.6696 176C80.0948 176 89.3393 166.708 89.3393 155.33C89.3393 146.418 83.6978 138.833 75.7807 135.941V88.0593C76.3022 87.8696 76.8237 87.6326 77.3452 87.3956L136.604 146.655C135.372 149.31 134.708 152.249 134.708 155.33C134.708 166.708 143.953 176 155.378 176C166.803 176 176.047 166.708 176.047 155.33C176.047 146.418 170.406 138.833 162.489 135.941H162.441Z",fill:"white"})),this.isOpen&&h("span",{class:"px-2"},h("b",null,"Nostr")," Login")),this.isOpen&&C&&h("div",{class:"show-slow truncate w-16 text-xs"},w),this.isOpen&&C&&h("nl-login-status",{info:this.userInfo}))),h("button",{onClick:()=>this.handleClose(),type:"button",class:(this.isOpen?"z-20":"z-0")+" nl-action-button absolute right-2 top-2 z-0 show-slow grid place-items-center w-7 h-7 text-sm font-semibold rounded-full border border-transparent"},h("span",{class:"sr-only"},"Close"),h("svg",{class:"flex-shrink-0 w-5 h-5",xmlns:"http://www.w3.org/2000/svg",width:"24",height:"24",viewBox:"0 0 24 24",fill:"none",stroke:"currentColor","stroke-width":"2","stroke-linecap":"round","stroke-linejoin":"round"},h("path",{d:"M18 6 6 18"}),h("path",{d:"m6 6 12 12"}))),h("div",{class:"p-3 show-slow"},this.isOpenConfirm?h("div",null,h("div",{class:"w-8 h-8 p-1/2 rounded-full border border-gray-200 bg-white mb-2 mt-2 show-slow m-auto"},h("svg",{xmlns:"http://www.w3.org/2000/svg",fill:"none",viewBox:"0 0 24 24","stroke-width":"1.5",stroke:"#5a68ff",class:"w-full"},h("path",{"stroke-linecap":"round","stroke-linejoin":"round",d:"m11.25 11.25.041-.02a.75.75 0 0 1 1.063.852l-.708 2.836a.75.75 0 0 0 1.063.853l.041-.021M21 12a9 9 0 1 1-18 0 9 9 0 0 1 18 0Zm-9-3.75h.008v.008H12V8.25Z"}))),h("p",{class:"mb-2 text-center max-w-40 min-w-40 mx-auto"},"timeout"===this.mode?"Keys not responding, check your key storage app":`Confirmation required at ${this.domain}`),"timeout"===this.mode?h("a",{onClick:()=>this.handleClose(),href:`https://${this.domain}`,target:"_blank",class:"nl-button text-nowrap py-2.5 px-3 w-full inline-flex justify-center items-center gap-x-2 text-sm font-medium rounded-lg disabled:opacity-50 disabled:pointer-events-none dark:focus:outline-none dark:focus:ring-1 dark:focus:ring-gray-600"},"Go to ",this.domain):"rebind"===this.mode?h("iframe",{src:this.url,width:"180",height:"80"}):h("button-base",{onClick:()=>this.handleConfirm(),titleBtn:"Confirm"})):h("div",null,h("div",null,this.titleBanner&&h("p",{class:"mb-2 text-center show-slow max-w-40 min-w-40 mx-auto"},this.titleBanner),T&&h(Fragment,null,!S&&h("p",{class:"mb-2 text-center show-slow text-red-400 max-w-40 min-w-40 mx-auto"},"Your profile may be lost if you close this tab"),h("div",{class:"mb-2"},h("button-base",{onClick:()=>this.handleImport(),theme:"lemonade",titleBtn:"Back up profile"}))),h("div",{class:"mb-2"},h("nl-change-account",{currentAccount:this.userInfo,accounts:this.accounts})),this.userInfo?h("button-base",{onClick:()=>this.handleLogout(),titleBtn:"Log out"}):h("div",null,h("button-base",{onClick:()=>this.handleLogin(),titleBtn:"Log in"},h("svg",{style:{display:"none"},slot:"icon-start",xmlns:"http://www.w3.org/2000/svg",fill:"none",viewBox:"0 0 24 24","stroke-width":"1.5",stroke:"currentColor",class:"flex-shrink-0 w-4 h-4"},h("path",{"stroke-linecap":"round","stroke-linejoin":"round",d:"M15.75 5.25a3 3 0 0 1 3 3m3 0a6 6 0 0 1-7.029 5.912c-.563-.097-1.159.026-1.563.43L10.5 17.25H8.25v2.25H6v2.25H2.25v-2.818c0-.597.237-1.17.659-1.591l6.499-6.499c.404-.404.527-1 .43-1.563A6 6 0 1 1 21.75 8.25Z"}))),h("button-base",{onClick:()=>this.handleSignup(),titleBtn:"Sign up"},h("svg",{style:{display:"none"},slot:"icon-start",xmlns:"http://www.w3.org/2000/svg",fill:"none",viewBox:"0 0 24 24","stroke-width":"1.5",stroke:"currentColor",class:"flex-shrink-0 w-4 h-4"},h("path",{"stroke-linecap":"round","stroke-linejoin":"round",d:"M18 7.5v3m0 0v3m0-3h3m-3 0h-3m-2.25-4.125a3.375 3.375 0 1 1-6.75 0 3.375 3.375 0 0 1 6.75 0ZM3 19.235v-.11a6.375 6.375 0 0 1 12.75 0v.109A12.318 12.318 0 0 1 9.374 21c-2.331 0-4.512-.645-6.374-1.766Z"})))))))),Z=!!function q(re,pe){pe=pe||document.body;const se=Array.from(pe.querySelectorAll(re)),ae=function(me){q(re,me).forEach(be=>{se.includes(be)||se.push(be)})};pe.shadowRoot&&ae(pe.shadowRoot);for(const me of Array.from(pe.querySelectorAll("*")))me.shadowRoot&&ae(me.shadowRoot);return se}("dialog").find(q=>q.open&&!q.classList.contains("nl-banner-dialog"));return console.log("nostr-login need dialog",Z),h("div",{class:`theme-${this.theme} ${!this.isOpen&&this.hiddenMode?"hidden":""}`},h("div",{class:this.darkMode&&"dark"},this.isOpenConfirm&&Z?h("nl-dialog",null,h("div",{class:`nl-banner ${this.isOpen?"w-52 h-auto right-2 rounded-r-lg isOpen":"rounded-r-none hover:rounded-r-lg cursor-pointer"} z-50 w-12 h-12 fixed top-52 right-0 inline-block gap-x-2 text-sm font-medium rounded-lg hover:right-2 transition-all duration-300 ease-in-out`},O)):h("div",{class:`nl-banner ${this.isOpen?"w-52 h-auto right-2 rounded-r-lg isOpen":"rounded-r-none hover:rounded-r-lg cursor-pointer"} z-50 w-12 h-12 fixed top-52 right-0 inline-block gap-x-2 text-sm font-medium rounded-lg hover:right-2 transition-all duration-300 ease-in-out`},O)))}static get watchers(){return{notify:["watchNotifyHandler"]}}static get style(){return NlBannerStyle0}},[1,"nl-banner",{theme:[1025],darkMode:[1028,"dark-mode"],hiddenMode:[1028,"hidden-mode"],titleBanner:[1,"title-banner"],isOpen:[1028,"is-open"],isLoading:[4,"is-loading"],notify:[16],userInfo:[16],accounts:[1040],isUserImgError:[32],domain:[32],mode:[32],url:[32],isOpenConfirm:[32]},void 0,{notify:["watchNotifyHandler"]}]);function defineCustomElement(){typeof customElements>"u"||["nl-banner","button-base","nl-change-account","nl-dialog","nl-login-status"].forEach(o=>{switch(o){case"nl-banner":customElements.get(o)||customElements.define(o,NlBanner);break;case"button-base":customElements.get(o)||defineCustomElement$q();break;case"nl-change-account":customElements.get(o)||defineCustomElement$2();break;case"nl-dialog":customElements.get(o)||defineCustomElement$1();break;case"nl-login-status":customElements.get(o)||defineCustomElement$g()}})}defineCustomElement();var commonjsGlobal=typeof globalThis<"u"?globalThis:typeof window<"u"?window:typeof global<"u"?global:typeof self<"u"?self:{};function getDefaultExportFromCjs(o){return o&&o.__esModule&&Object.prototype.hasOwnProperty.call(o,"default")?o.default:o}var lib$1={},types={};Object.defineProperty(types,"__esModule",{value:!0});var ee={},taskCollection$1={},taskCollection={},bakeCollection={};(function(exports){Object.defineProperty(exports,"__esModule",{value:!0}),exports.bakeCollectionVariadic=exports.bakeCollectionAwait=exports.bakeCollection=exports.BAKED_EMPTY_FUNC=void 0,exports.BAKED_EMPTY_FUNC=function(){};var FORLOOP_FALLBACK=1500;function generateArgsDefCode(o){var s="";if(0===o)return s;for(var r=0;r1)s?((r=this._tasks).push.apply(r,arguments),this.length+=arguments.length):(this._tasks.push(o),this.length++);else if(s){var a;1===i?((a=Array(1+arguments.length)).push(a),a.push.apply(a,arguments),this._tasks=a):((a=Array(arguments.length)).push.apply(a,arguments),this._tasks=a),this.length+=arguments.length}else this._tasks=1===i?[this._tasks,o]:o,this.length++}function push_rebuild(o,s){var r,i=this.length;if(i>1)s?((r=this._tasks).push.apply(r,arguments),this.length+=arguments.length):(this._tasks.push(o),this.length++);else if(s){var a;1===i?((a=Array(1+arguments.length)).push(a),a.push.apply(a,arguments),this._tasks=a):((a=Array(arguments.length)).push.apply(a,arguments),this._tasks=a),this.length+=arguments.length}else this._tasks=1===i?[this._tasks,o]:o,this.length++;this.firstEmitBuildStrategy?this.call=rebuild_on_first_call:this.rebuild()}function _fast_remove_single(o,s){-1!==s&&(0===s?o.shift():s===o.length-1?o.length=o.length-1:o.splice(s,1))}function removeLast_norebuild(o){0!==this.length&&(1===this.length?this._tasks===o&&(this.length=0):(_fast_remove_single(this._tasks,this._tasks.lastIndexOf(o)),1===this._tasks.length?(this._tasks=this._tasks[0],this.length=1):this.length=this._tasks.length))}function removeLast_rebuild(o){if(0!==this.length){if(1===this.length)return this._tasks===o&&(this.length=0),this.firstEmitBuildStrategy?void(this.call=bake_collection_1.BAKED_EMPTY_FUNC):void this.rebuild();_fast_remove_single(this._tasks,this._tasks.lastIndexOf(o)),1===this._tasks.length?(this._tasks=this._tasks[0],this.length=1):this.length=this._tasks.length,this.firstEmitBuildStrategy?this.call=rebuild_on_first_call:this.rebuild()}}function insert_norebuild(o){for(var s,r=[],i=1;i0&&!s.includes(o.length))throw new Error(`Expected Uint8Array of length ${s}, not of length=${o.length}`)}function hash$3(o){if("function"!=typeof o||"function"!=typeof o.create)throw new Error("Hash should be wrapped by utils.wrapConstructor");number$3(o.outputLen),number$3(o.blockLen)}function exists$3(o,s=!0){if(o.destroyed)throw new Error("Hash instance has been destroyed");if(s&&o.finished)throw new Error("Hash#digest() has already been called")}function output$3(o,s){bytes$3(o);const r=s.outputLen;if(o.lengtho instanceof Uint8Array,createView$2=o=>new DataView(o.buffer,o.byteOffset,o.byteLength),rotr$2=(o,s)=>o<<32-s|o>>>s,isLE$3=68===new Uint8Array(new Uint32Array([287454020]).buffer)[0];if(!isLE$3)throw new Error("Non little-endian hardware is not supported");function utf8ToBytes$4(o){if("string"!=typeof o)throw new Error("utf8ToBytes expected string, got "+typeof o);return new Uint8Array((new TextEncoder).encode(o))}function toBytes$3(o){if("string"==typeof o&&(o=utf8ToBytes$4(o)),!u8a$3(o))throw new Error("expected Uint8Array, got "+typeof o);return o}function concatBytes$3(...o){const s=new Uint8Array(o.reduce((i,a)=>i+a.length,0));let r=0;return o.forEach(i=>{if(!u8a$3(i))throw new Error("Uint8Array expected");s.set(i,r),r+=i.length}),s}Array.from({length:256},(o,s)=>s.toString(16).padStart(2,"0"));let Hash$2=class{clone(){return this._cloneInto()}};function wrapConstructor$2(o){const s=i=>o().update(toBytes$3(i)).digest(),r=o();return s.outputLen=r.outputLen,s.blockLen=r.blockLen,s.create=()=>o(),s}function randomBytes$2(o=32){if(crypto$3&&"function"==typeof crypto$3.getRandomValues)return crypto$3.getRandomValues(new Uint8Array(o));throw new Error("crypto.getRandomValues must be defined")}function setBigUint64$2(o,s,r,i){if("function"==typeof o.setBigUint64)return o.setBigUint64(s,r,i);const a=BigInt(32),c=BigInt(4294967295),y=Number(r>>a&c),w=Number(r&c),T=i?0:4;o.setUint32(s+(i?4:0),y,i),o.setUint32(s+T,w,i)}let SHA2$2=class extends Hash$2{constructor(o,s,r,i){super(),this.blockLen=o,this.outputLen=s,this.padOffset=r,this.isLE=i,this.finished=!1,this.length=0,this.pos=0,this.destroyed=!1,this.buffer=new Uint8Array(o),this.view=createView$2(this.buffer)}update(o){assert$3.exists(this);const{view:s,buffer:r,blockLen:i}=this,a=(o=toBytes$3(o)).length;for(let c=0;ci-c&&(this.process(r,0),c=0);for(let S=c;ST.length)throw new Error("_sha2: outputLen bigger than state");for(let S=0;So&s^~o&r,Maj$2=(o,s,r)=>o&s^o&r^s&r,SHA256_K$2=new Uint32Array([1116352408,1899447441,3049323471,3921009573,961987163,1508970993,2453635748,2870763221,3624381080,310598401,607225278,1426881987,1925078388,2162078206,2614888103,3248222580,3835390401,4022224774,264347078,604807628,770255983,1249150122,1555081692,1996064986,2554220882,2821834349,2952996808,3210313671,3336571891,3584528711,113926993,338241895,666307205,773529912,1294757372,1396182291,1695183700,1986661051,2177026350,2456956037,2730485921,2820302411,3259730800,3345764771,3516065817,3600352804,4094571909,275423344,430227734,506948616,659060556,883997877,958139571,1322822218,1537002063,1747873779,1955562222,2024104815,2227730452,2361852424,2428436474,2756734187,3204031479,3329325298]),IV$2=new Uint32Array([1779033703,3144134277,1013904242,2773480762,1359893119,2600822924,528734635,1541459225]),SHA256_W$2=new Uint32Array(64);let SHA256$2=class extends SHA2$2{constructor(){super(64,32,8,!1),this.A=0|IV$2[0],this.B=0|IV$2[1],this.C=0|IV$2[2],this.D=0|IV$2[3],this.E=0|IV$2[4],this.F=0|IV$2[5],this.G=0|IV$2[6],this.H=0|IV$2[7]}get(){const{A:o,B:s,C:r,D:i,E:a,F:c,G:y,H:w}=this;return[o,s,r,i,a,c,y,w]}set(o,s,r,i,a,c,y,w){this.A=0|o,this.B=0|s,this.C=0|r,this.D=0|i,this.E=0|a,this.F=0|c,this.G=0|y,this.H=0|w}process(o,s){for(let S=0;S<16;S++,s+=4)SHA256_W$2[S]=o.getUint32(s,!1);for(let S=16;S<64;S++){const M=SHA256_W$2[S-15],O=SHA256_W$2[S-2],L=rotr$2(M,7)^rotr$2(M,18)^M>>>3,Z=rotr$2(O,17)^rotr$2(O,19)^O>>>10;SHA256_W$2[S]=Z+SHA256_W$2[S-7]+L+SHA256_W$2[S-16]|0}let{A:r,B:i,C:a,D:c,E:y,F:w,G:C,H:T}=this;for(let S=0;S<64;S++){const M=T+(rotr$2(y,6)^rotr$2(y,11)^rotr$2(y,25))+Chi$2(y,w,C)+SHA256_K$2[S]+SHA256_W$2[S]|0,O=(rotr$2(r,2)^rotr$2(r,13)^rotr$2(r,22))+Maj$2(r,i,a)|0;T=C,C=w,w=y,y=c+M|0,c=a,a=i,i=r,r=M+O|0}r=r+this.A|0,i=i+this.B|0,a=a+this.C|0,c=c+this.D|0,y=y+this.E|0,w=w+this.F|0,C=C+this.G|0,T=T+this.H|0,this.set(r,i,a,c,y,w,C,T)}roundClean(){SHA256_W$2.fill(0)}destroy(){this.set(0,0,0,0,0,0,0,0),this.buffer.fill(0)}},SHA224$1=class extends SHA256$2{constructor(){super(),this.A=-1056596264,this.B=914150663,this.C=812702999,this.D=-150054599,this.E=-4191439,this.F=1750603025,this.G=1694076839,this.H=-1090891868,this.outputLen=28}};const sha256$2=wrapConstructor$2(()=>new SHA256$2);wrapConstructor$2(()=>new SHA224$1);const _0n$4=BigInt(0),_1n$4=BigInt(1),_2n$2=BigInt(2),u8a$2=o=>o instanceof Uint8Array,hexes$2=Array.from({length:256},(o,s)=>s.toString(16).padStart(2,"0"));function bytesToHex$2(o){if(!u8a$2(o))throw new Error("Uint8Array expected");let s="";for(let r=0;ri+a.length,0));let r=0;return o.forEach(i=>{if(!u8a$2(i))throw new Error("Uint8Array expected");s.set(i,r),r+=i.length}),s}function equalBytes$1(o,s){if(o.length!==s.length)return!1;for(let r=0;r_0n$4;o>>=_1n$4,s+=1);return s}function bitGet(o,s){return o>>BigInt(s)&_1n$4}const bitSet=(o,s,r)=>o|(r?_1n$4:_0n$4)<(_2n$2<new Uint8Array(o),u8fr=o=>Uint8Array.from(o);function createHmacDrbg(o,s,r){if("number"!=typeof o||o<2)throw new Error("hashLen must be a number");if("number"!=typeof s||s<2)throw new Error("qByteLen must be a number");if("function"!=typeof r)throw new Error("hmacFn must be a function");let i=u8n(o),a=u8n(o),c=0;const y=()=>{i.fill(1),a.fill(0),c=0},w=(...S)=>r(a,i,...S),C=(S=u8n())=>{a=w(u8fr([0]),S),i=w(),0!==S.length&&(a=w(u8fr([1]),S),i=w())},T=()=>{if(c++>=1e3)throw new Error("drbg: tried 1000 values");let S=0;const M=[];for(;S{let O;for(y(),C(S);!(O=M(T()));)C();return y(),O}}const validatorFns={bigint:o=>"bigint"==typeof o,function:o=>"function"==typeof o,boolean:o=>"boolean"==typeof o,string:o=>"string"==typeof o,isSafeInteger:o=>Number.isSafeInteger(o),array:o=>Array.isArray(o),field:(o,s)=>s.Fp.isValid(o),hash:o=>"function"==typeof o&&Number.isSafeInteger(o.outputLen)};function validateObject(o,s,r={}){const i=(a,c,y)=>{const w=validatorFns[c];if("function"!=typeof w)throw new Error(`Invalid validator "${c}", expected function`);const C=o[a];if(!(y&&void 0===C||w(C,o)))throw new Error(`Invalid param ${String(a)}=${C} (${typeof C}), expected ${c}`)};for(const[a,c]of Object.entries(s))i(a,c,!1);for(const[a,c]of Object.entries(r))i(a,c,!0);return o}var ut=Object.freeze({__proto__:null,bitGet,bitLen,bitMask,bitSet,bytesToHex:bytesToHex$2,bytesToNumberBE,bytesToNumberLE,concatBytes:concatBytes$2,createHmacDrbg,ensureBytes:ensureBytes$1,equalBytes:equalBytes$1,hexToBytes:hexToBytes$2,hexToNumber,numberToBytesBE,numberToBytesLE,numberToHexUnpadded,numberToVarBytesBE,utf8ToBytes:utf8ToBytes$3,validateObject});const _0n$3=BigInt(0),_1n$3=BigInt(1),_2n$1=BigInt(2),_3n$1=BigInt(3),_4n=BigInt(4),_5n=BigInt(5),_8n=BigInt(8);function mod(o,s){const r=o%s;return r>=_0n$3?r:s+r}function pow(o,s,r){if(r<=_0n$3||s<_0n$3)throw new Error("Expected power/modulo > 0");if(r===_1n$3)return _0n$3;let i=_1n$3;for(;s>_0n$3;)s&_1n$3&&(i=i*o%r),o=o*o%r,s>>=_1n$3;return i}function pow2(o,s,r){let i=o;for(;s-- >_0n$3;)i*=i,i%=r;return i}function invert(o,s){if(o===_0n$3||s<=_0n$3)throw new Error(`invert: expected positive integers, got n=${o} mod=${s}`);let r=mod(o,s),i=s,a=_0n$3,c=_1n$3;for(;r!==_0n$3;){const y=i%r,w=a-c*(i/r);i=r,r=y,a=c,c=w}if(i!==_1n$3)throw new Error("invert: does not exist");return mod(a,s)}function tonelliShanks(o){const s=(o-_1n$3)/_2n$1;let r,i,a;for(r=o-_1n$3,i=0;r%_2n$1===_0n$3;r/=_2n$1,i++);for(a=_2n$1;a(r[i]="function",r),{ORDER:"bigint",MASK:"bigint",BYTES:"isSafeInteger",BITS:"isSafeInteger"}))}function FpPow(o,s,r){if(r<_0n$3)throw new Error("Expected power > 0");if(r===_0n$3)return o.ONE;if(r===_1n$3)return s;let i=o.ONE,a=s;for(;r>_0n$3;)r&_1n$3&&(i=o.mul(i,a)),a=o.sqr(a),r>>=_1n$3;return i}function FpInvertBatch(o,s){const r=new Array(s.length),i=s.reduce((c,y,w)=>o.is0(y)?c:(r[w]=c,o.mul(c,y)),o.ONE),a=o.inv(i);return s.reduceRight((c,y,w)=>o.is0(y)?c:(r[w]=o.mul(c,r[w]),o.mul(c,y)),a),r}function nLength(o,s){const r=void 0!==s?s:o.toString(2).length;return{nBitLength:r,nByteLength:Math.ceil(r/8)}}function Field(o,s,r=!1,i={}){if(o<=_0n$3)throw new Error(`Expected Fp ORDER > 0, got ${o}`);const{nBitLength:a,nByteLength:c}=nLength(o,s);if(c>2048)throw new Error("Field lengths over 2048 bytes are not supported");const y=FpSqrt(o),w=Object.freeze({ORDER:o,BITS:a,BYTES:c,MASK:bitMask(a),ZERO:_0n$3,ONE:_1n$3,create:C=>mod(C,o),isValid:C=>{if("bigint"!=typeof C)throw new Error("Invalid field element: expected bigint, got "+typeof C);return _0n$3<=C&&CC===_0n$3,isOdd:C=>(C&_1n$3)===_1n$3,neg:C=>mod(-C,o),eql:(C,T)=>C===T,sqr:C=>mod(C*C,o),add:(C,T)=>mod(C+T,o),sub:(C,T)=>mod(C-T,o),mul:(C,T)=>mod(C*T,o),pow:(C,T)=>FpPow(w,C,T),div:(C,T)=>mod(C*invert(T,o),o),sqrN:C=>C*C,addN:(C,T)=>C+T,subN:(C,T)=>C-T,mulN:(C,T)=>C*T,inv:C=>invert(C,o),sqrt:i.sqrt||(C=>y(w,C)),invertBatch:C=>FpInvertBatch(w,C),cmov:(C,T,S)=>S?T:C,toBytes:C=>r?numberToBytesLE(C,c):numberToBytesBE(C,c),fromBytes:C=>{if(C.length!==c)throw new Error(`Fp.fromBytes: expected ${c}, got ${C.length}`);return r?bytesToNumberLE(C):bytesToNumberBE(C)}});return Object.freeze(w)}function hashToPrivateScalar(o,s,r=!1){const i=(o=ensureBytes$1("privateHash",o)).length,a=nLength(s).nByteLength+8;if(a<24||i1024)throw new Error(`hashToPrivateScalar: expected ${a}-1024 bytes of input, got ${i}`);return mod(r?bytesToNumberLE(o):bytesToNumberBE(o),s-_1n$3)+_1n$3}const _0n$2=BigInt(0),_1n$2=BigInt(1);function wNAF(o,s){const r=(a,c)=>{const y=c.negate();return a?y:c},i=a=>({windows:Math.ceil(s/a)+1,windowSize:2**(a-1)});return{constTimeNegate:r,unsafeLadder(a,c){let y=o.ZERO,w=a;for(;c>_0n$2;)c&_1n$2&&(y=y.add(w)),w=w.double(),c>>=_1n$2;return y},precomputeWindow(a,c){const{windows:y,windowSize:w}=i(c),C=[];let T=a,S=T;for(let M=0;M>=L,re>C&&(re-=O,y+=_1n$2);const pe=q,se=q+Math.abs(re)-1,me=re<0;0===re?S=S.add(r(Z%2!=0,c[pe])):T=T.add(r(me,c[se]))}return{p:T,f:S}},wNAFCached(a,c,y,w){const C=a._WINDOW_SIZE||1;let T=c.get(a);return T||(T=this.precomputeWindow(a,C),1!==C&&c.set(a,w(T))),this.wNAF(C,T,y)}}}function validateBasic(o){return validateField(o.Fp),validateObject(o,{n:"bigint",h:"bigint",Gx:"field",Gy:"field"},{nBitLength:"isSafeInteger",nByteLength:"isSafeInteger"}),Object.freeze({...nLength(o.n,o.nBitLength),...o,p:o.Fp.ORDER})}function validatePointOpts(o){const s=validateBasic(o);validateObject(s,{a:"field",b:"field"},{allowedPrivateKeyLengths:"array",wrapPrivateKey:"boolean",isTorsionFree:"function",clearCofactor:"function",allowInfinityPoint:"boolean",fromBytes:"function",toBytes:"function"});const{endo:r,Fp:i,a}=s;if(r){if(!i.eql(a,i.ZERO))throw new Error("Endomorphism can only be defined for Koblitz curves that have a=0");if("object"!=typeof r||"bigint"!=typeof r.beta||"function"!=typeof r.splitScalar)throw new Error("Expected endomorphism with beta: bigint and splitScalar: function")}return Object.freeze({...s})}const{bytesToNumberBE:b2n,hexToBytes:h2b}=ut,DER={Err:class extends Error{constructor(o=""){super(o)}},_parseInt(o){const{Err:s}=DER;if(o.length<2||2!==o[0])throw new s("Invalid signature integer tag");const r=o[1],i=o.subarray(2,r+2);if(!r||i.length!==r)throw new s("Invalid signature integer: wrong length");if(128&i[0])throw new s("Invalid signature integer: negative");if(0===i[0]&&!(128&i[1]))throw new s("Invalid signature integer: unnecessary leading zero");return{d:b2n(i),l:o.subarray(r+2)}},toSig(o){const{Err:s}=DER,r="string"==typeof o?h2b(o):o;if(!(r instanceof Uint8Array))throw new Error("ui8a expected");let i=r.length;if(i<2||48!=r[0])throw new s("Invalid signature tag");if(r[1]!==i-2)throw new s("Invalid signature: incorrect length");const{d:a,l:c}=DER._parseInt(r.subarray(2)),{d:y,l:w}=DER._parseInt(c);if(w.length)throw new s("Invalid signature: left bytes after parsing");return{r:a,s:y}},hexFromSig(o){const s=T=>8&Number.parseInt(T[0],16)?"00"+T:T,r=T=>{const S=T.toString(16);return 1&S.length?`0${S}`:S},i=s(r(o.s)),a=s(r(o.r)),c=i.length/2,y=a.length/2,w=r(c),C=r(y);return`30${r(y+c+4)}02${C}${a}02${w}${i}`}},_0n$1=BigInt(0),_1n$1=BigInt(1);BigInt(2);const _3n=BigInt(3);function weierstrassPoints(o){const s=validatePointOpts(o),{Fp:r}=s,i=s.toBytes||((Z,q,re)=>{const pe=q.toAffine();return concatBytes$2(Uint8Array.from([4]),r.toBytes(pe.x),r.toBytes(pe.y))}),a=s.fromBytes||(Z=>{const q=Z.subarray(1);return{x:r.fromBytes(q.subarray(0,r.BYTES)),y:r.fromBytes(q.subarray(r.BYTES,2*r.BYTES))}});function c(Z){const{a:q,b:re}=s,pe=r.sqr(Z),se=r.mul(pe,Z);return r.add(r.add(se,r.mul(Z,q)),re)}if(!r.eql(r.sqr(s.Gy),c(s.Gx)))throw new Error("bad generator point: equation left != right");function y(Z){return"bigint"==typeof Z&&_0n$1r.eql(ae,r.ZERO);return se(re)&&se(pe)?M.ZERO:new M(re,pe,r.ONE)}get x(){return this.toAffine().x}get y(){return this.toAffine().y}static normalizeZ(q){const re=r.invertBatch(q.map(pe=>pe.pz));return q.map((pe,se)=>pe.toAffine(re[se])).map(M.fromAffine)}static fromHex(q){const re=M.fromAffine(a(ensureBytes$1("pointHex",q)));return re.assertValidity(),re}static fromPrivateKey(q){return M.BASE.multiply(C(q))}_setWindowSize(q){this._WINDOW_SIZE=q,T.delete(this)}assertValidity(){if(this.is0()){if(s.allowInfinityPoint)return;throw new Error("bad point: ZERO")}const{x:q,y:re}=this.toAffine();if(!r.isValid(q)||!r.isValid(re))throw new Error("bad point: x or y not FE");const pe=r.sqr(re),se=c(q);if(!r.eql(pe,se))throw new Error("bad point: equation left != right");if(!this.isTorsionFree())throw new Error("bad point: not in prime-order subgroup")}hasEvenY(){const{y:q}=this.toAffine();if(r.isOdd)return!r.isOdd(q);throw new Error("Field doesn't support isOdd")}equals(q){S(q);const{px:re,py:pe,pz:se}=this,{px:ae,py:me,pz:be}=q,Oe=r.eql(r.mul(re,be),r.mul(ae,se)),xe=r.eql(r.mul(pe,be),r.mul(me,se));return Oe&&xe}negate(){return new M(this.px,r.neg(this.py),this.pz)}double(){const{a:q,b:re}=s,pe=r.mul(re,_3n),{px:se,py:ae,pz:me}=this;let be=r.ZERO,Oe=r.ZERO,xe=r.ZERO,De=r.mul(se,se),ce=r.mul(ae,ae),ue=r.mul(me,me),Ce=r.mul(se,ae);return Ce=r.add(Ce,Ce),xe=r.mul(se,me),xe=r.add(xe,xe),be=r.mul(q,xe),Oe=r.mul(pe,ue),Oe=r.add(be,Oe),be=r.sub(ce,Oe),Oe=r.add(ce,Oe),Oe=r.mul(be,Oe),be=r.mul(Ce,be),xe=r.mul(pe,xe),ue=r.mul(q,ue),Ce=r.sub(De,ue),Ce=r.mul(q,Ce),Ce=r.add(Ce,xe),xe=r.add(De,De),De=r.add(xe,De),De=r.add(De,ue),De=r.mul(De,Ce),Oe=r.add(Oe,De),ue=r.mul(ae,me),ue=r.add(ue,ue),De=r.mul(ue,Ce),be=r.sub(be,De),xe=r.mul(ue,ce),xe=r.add(xe,xe),xe=r.add(xe,xe),new M(be,Oe,xe)}add(q){S(q);const{px:re,py:pe,pz:se}=this,{px:ae,py:me,pz:be}=q;let Oe=r.ZERO,xe=r.ZERO,De=r.ZERO;const ce=s.a,ue=r.mul(s.b,_3n);let Ce=r.mul(re,ae),Be=r.mul(pe,me),at=r.mul(se,be),dt=r.add(re,pe),bt=r.add(ae,me);dt=r.mul(dt,bt),bt=r.add(Ce,Be),dt=r.sub(dt,bt),bt=r.add(re,se);let lt=r.add(ae,be);return bt=r.mul(bt,lt),lt=r.add(Ce,at),bt=r.sub(bt,lt),lt=r.add(pe,se),Oe=r.add(me,be),lt=r.mul(lt,Oe),Oe=r.add(Be,at),lt=r.sub(lt,Oe),De=r.mul(ce,bt),Oe=r.mul(ue,at),De=r.add(Oe,De),Oe=r.sub(Be,De),De=r.add(Be,De),xe=r.mul(Oe,De),Be=r.add(Ce,Ce),Be=r.add(Be,Ce),at=r.mul(ce,at),bt=r.mul(ue,bt),Be=r.add(Be,at),at=r.sub(Ce,at),at=r.mul(ce,at),bt=r.add(bt,at),Ce=r.mul(Be,bt),xe=r.add(xe,Ce),Ce=r.mul(lt,bt),Oe=r.mul(dt,Oe),Oe=r.sub(Oe,Ce),Ce=r.mul(dt,Be),De=r.mul(lt,De),De=r.add(De,Ce),new M(Oe,xe,De)}subtract(q){return this.add(q.negate())}is0(){return this.equals(M.ZERO)}wNAF(q){return L.wNAFCached(this,T,q,re=>{const pe=r.invertBatch(re.map(se=>se.pz));return re.map((se,ae)=>se.toAffine(pe[ae])).map(M.fromAffine)})}multiplyUnsafe(q){const re=M.ZERO;if(q===_0n$1)return re;if(w(q),q===_1n$1)return this;const{endo:pe}=s;if(!pe)return L.unsafeLadder(this,q);let{k1neg:se,k1:ae,k2neg:me,k2:be}=pe.splitScalar(q),Oe=re,xe=re,De=this;for(;ae>_0n$1||be>_0n$1;)ae&_1n$1&&(Oe=Oe.add(De)),be&_1n$1&&(xe=xe.add(De)),De=De.double(),ae>>=_1n$1,be>>=_1n$1;return se&&(Oe=Oe.negate()),me&&(xe=xe.negate()),xe=new M(r.mul(xe.px,pe.beta),xe.py,xe.pz),Oe.add(xe)}multiply(q){w(q);let re,pe,se=q;const{endo:ae}=s;if(ae){const{k1neg:me,k1:be,k2neg:Oe,k2:xe}=ae.splitScalar(se);let{p:De,f:ce}=this.wNAF(be),{p:ue,f:Ce}=this.wNAF(xe);De=L.constTimeNegate(me,De),ue=L.constTimeNegate(Oe,ue),ue=new M(r.mul(ue.px,ae.beta),ue.py,ue.pz),re=De.add(ue),pe=ce.add(Ce)}else{const{p:me,f:be}=this.wNAF(se);re=me,pe=be}return M.normalizeZ([re,pe])[0]}multiplyAndAddUnsafe(q,re,pe){const se=M.BASE,ae=(be,Oe)=>Oe!==_0n$1&&Oe!==_1n$1&&be.equals(se)?be.multiply(Oe):be.multiplyUnsafe(Oe),me=ae(this,re).add(ae(q,pe));return me.is0()?void 0:me}toAffine(q){const{px:re,py:pe,pz:se}=this,ae=this.is0();null==q&&(q=ae?r.ONE:r.inv(se));const me=r.mul(re,q),be=r.mul(pe,q),Oe=r.mul(se,q);if(ae)return{x:r.ZERO,y:r.ZERO};if(!r.eql(Oe,r.ONE))throw new Error("invZ was invalid");return{x:me,y:be}}isTorsionFree(){const{h:q,isTorsionFree:re}=s;if(q===_1n$1)return!0;if(re)return re(M,this);throw new Error("isTorsionFree() has not been declared for the elliptic curve")}clearCofactor(){const{h:q,clearCofactor:re}=s;return q===_1n$1?this:re?re(M,this):this.multiplyUnsafe(s.h)}toRawBytes(q=!0){return this.assertValidity(),i(M,this,q)}toHex(q=!0){return bytesToHex$2(this.toRawBytes(q))}}M.BASE=new M(s.Gx,s.Gy,r.ONE),M.ZERO=new M(r.ZERO,r.ONE,r.ZERO);const O=s.nBitLength,L=wNAF(M,s.endo?Math.ceil(O/2):O);return{CURVE:s,ProjectivePoint:M,normPrivateKeyToScalar:C,weierstrassEquation:c,isWithinCurveOrder:y}}function validateOpts(o){const s=validateBasic(o);return validateObject(s,{hash:"hash",hmac:"function",randomBytes:"function"},{bits2int:"function",bits2int_modN:"function",lowS:"boolean"}),Object.freeze({lowS:!0,...s})}function weierstrass(o){const s=validateOpts(o),{Fp:r,n:i}=s,a=r.BYTES+1,c=2*r.BYTES+1;function y(ce){return mod(ce,i)}function w(ce){return invert(ce,i)}const{ProjectivePoint:C,normPrivateKeyToScalar:T,weierstrassEquation:S,isWithinCurveOrder:M}=weierstrassPoints({...s,toBytes(ce,ue,Ce){const Be=ue.toAffine(),at=r.toBytes(Be.x),dt=concatBytes$2;return Ce?dt(Uint8Array.from([ue.hasEvenY()?2:3]),at):dt(Uint8Array.from([4]),at,r.toBytes(Be.y))},fromBytes(ce){const ue=ce.length,Ce=ce[0],Be=ce.subarray(1);if(ue!==a||2!==Ce&&3!==Ce){if(ue===c&&4===Ce)return{x:r.fromBytes(Be.subarray(0,r.BYTES)),y:r.fromBytes(Be.subarray(r.BYTES,2*r.BYTES))};throw new Error(`Point of length ${ue} was invalid. Expected ${a} compressed bytes or ${c} uncompressed bytes`)}{const dt=bytesToNumberBE(Be);if(!(_0n$1<(at=dt)&&atbytesToHex$2(numberToBytesBE(ce,s.nByteLength));function L(ce){return ce>i>>_1n$1}const Z=(ce,ue,Ce)=>bytesToNumberBE(ce.slice(ue,Ce));class q{constructor(ue,Ce,Be){this.r=ue,this.s=Ce,this.recovery=Be,this.assertValidity()}static fromCompact(ue){const Ce=s.nByteLength;return ue=ensureBytes$1("compactSignature",ue,2*Ce),new q(Z(ue,0,Ce),Z(ue,Ce,2*Ce))}static fromDER(ue){const{r:Ce,s:Be}=DER.toSig(ensureBytes$1("DER",ue));return new q(Ce,Be)}assertValidity(){if(!M(this.r))throw new Error("r must be 0 < r < CURVE.n");if(!M(this.s))throw new Error("s must be 0 < s < CURVE.n")}addRecoveryBit(ue){return new q(this.r,this.s,ue)}recoverPublicKey(ue){const{r:Ce,s:Be,recovery:at}=this,dt=ae(ensureBytes$1("msgHash",ue));if(null==at||![0,1,2,3].includes(at))throw new Error("recovery id invalid");const bt=2===at||3===at?Ce+s.n:Ce;if(bt>=r.ORDER)throw new Error("recovery id 2 or 3 invalid");const rn=C.fromHex((1&at?"03":"02")+O(bt)),gn=w(bt),bn=y(-dt*gn),Vn=y(Be*gn),yn=C.BASE.multiplyAndAddUnsafe(rn,bn,Vn);if(!yn)throw new Error("point at infinify");return yn.assertValidity(),yn}hasHighS(){return L(this.s)}normalizeS(){return this.hasHighS()?new q(this.r,y(-this.s),this.recovery):this}toDERRawBytes(){return hexToBytes$2(this.toDERHex())}toDERHex(){return DER.hexFromSig({r:this.r,s:this.s})}toCompactRawBytes(){return hexToBytes$2(this.toCompactHex())}toCompactHex(){return O(this.r)+O(this.s)}}const re={isValidPrivateKey(ce){try{return T(ce),!0}catch{return!1}},normPrivateKeyToScalar:T,randomPrivateKey:()=>numberToBytesBE(hashToPrivateScalar(s.randomBytes(r.BYTES+8),i),s.nByteLength),precompute:(ce=8,ue=C.BASE)=>(ue._setWindowSize(ce),ue.multiply(BigInt(3)),ue)};function pe(ce){const ue=ce instanceof Uint8Array,Ce="string"==typeof ce,Be=(ue||Ce)&&ce.length;return ue?Be===a||Be===c:Ce?Be===2*a||Be===2*c:ce instanceof C}const se=s.bits2int||function(ce){const ue=bytesToNumberBE(ce),Ce=8*ce.length-s.nBitLength;return Ce>0?ue>>BigInt(Ce):ue},ae=s.bits2int_modN||function(ce){return y(se(ce))},me=bitMask(s.nBitLength);function be(ce){if("bigint"!=typeof ce)throw new Error("bigint expected");if(!(_0n$1<=ce&&ceqe in Ce))throw new Error("sign() legacy options not supported");const{hash:Be,randomBytes:at}=s;let{lowS:dt,prehash:bt,extraEntropy:lt}=Ce;null==dt&&(dt=!0),ce=ensureBytes$1("msgHash",ce),bt&&(ce=ensureBytes$1("prehashed msgHash",Be(ce)));const rn=ae(ce),gn=T(ue),bn=[be(gn),be(rn)];if(null!=lt){const qe=!0===lt?at(r.BYTES):lt;bn.push(ensureBytes$1("extraEntropy",qe,r.BYTES))}const Vn=concatBytes$2(...bn),yn=rn;return{seed:Vn,k2sig:function(qe){const _t=se(qe);if(!M(_t))return;const ze=w(_t),$e=C.BASE.multiply(_t).toAffine(),Ft=y($e.x);if(Ft===_0n$1)return;const Ke=y(ze*y(yn+Ft*gn));if(Ke===_0n$1)return;let Ze=($e.x===Ft?0:2)|Number($e.y&_1n$1),it=Ke;return dt&&L(Ke)&&(it=L(Ot=Ke)?y(-Ot):Ot,Ze^=1),new q(Ft,it,Ze);var Ot}}}(ce,ue,Ce);return createHmacDrbg(s.hash.outputLen,s.nByteLength,s.hmac)(Be,at)},verify:function(ce,ue,Ce,Be=De){const at=ce;if(ue=ensureBytes$1("msgHash",ue),Ce=ensureBytes$1("publicKey",Ce),"strict"in Be)throw new Error("options.strict was renamed to lowS");const{lowS:dt,prehash:bt}=Be;let lt,rn;try{if("string"==typeof at||at instanceof Uint8Array)try{lt=q.fromDER(at)}catch($e){if(!($e instanceof DER.Err))throw $e;lt=q.fromCompact(at)}else{if("object"!=typeof at||"bigint"!=typeof at.r||"bigint"!=typeof at.s)throw new Error("PARSE");{const{r:$e,s:Ft}=at;lt=new q($e,Ft)}}rn=C.fromHex(Ce)}catch($e){if("PARSE"===$e.message)throw new Error("signature must be Signature instance, Uint8Array or hex string");return!1}if(dt&<.hasHighS())return!1;bt&&(ue=s.hash(ue));const{r:gn,s:bn}=lt,Vn=ae(ue),yn=w(bn),qe=y(Vn*yn),_t=y(gn*yn),ze=C.BASE.multiplyAndAddUnsafe(rn,qe,_t)?.toAffine();return!!ze&&y(ze.x)===gn},ProjectivePoint:C,Signature:q,utils:re}}BigInt(4);let HMAC$2=class extends Hash$2{constructor(o,s){super(),this.finished=!1,this.destroyed=!1,assert$3.hash(o);const r=toBytes$3(s);if(this.iHash=o.create(),"function"!=typeof this.iHash.update)throw new Error("Expected instance of class which extends utils.Hash");this.blockLen=this.iHash.blockLen,this.outputLen=this.iHash.outputLen;const i=this.blockLen,a=new Uint8Array(i);a.set(r.length>i?o.create().update(r).digest():r);for(let c=0;cnew HMAC$2(o,s).update(r).digest();function getHash(o){return{hash:o,hmac:(s,...r)=>hmac$2(o,s,concatBytes$3(...r)),randomBytes:randomBytes$2}}function createCurve(o,s){const r=i=>weierstrass({...o,...getHash(i)});return Object.freeze({...r(s),create:r})}hmac$2.create=(o,s)=>new HMAC$2(o,s);const secp256k1P=BigInt("0xfffffffffffffffffffffffffffffffffffffffffffffffffffffffefffffc2f"),secp256k1N=BigInt("0xfffffffffffffffffffffffffffffffebaaedce6af48a03bbfd25e8cd0364141"),_1n=BigInt(1),_2n=BigInt(2),divNearest=(o,s)=>(o+s/_2n)/s;function sqrtMod(o){const s=secp256k1P,r=BigInt(3),i=BigInt(6),a=BigInt(11),c=BigInt(22),y=BigInt(23),w=BigInt(44),C=BigInt(88),T=o*o*o%s,S=T*T*o%s,M=pow2(S,r,s)*S%s,O=pow2(M,r,s)*S%s,L=pow2(O,_2n,s)*T%s,Z=pow2(L,a,s)*L%s,q=pow2(Z,c,s)*Z%s,re=pow2(q,w,s)*q%s,pe=pow2(re,C,s)*re%s,se=pow2(pe,w,s)*q%s,ae=pow2(se,r,s)*S%s,me=pow2(ae,y,s)*Z%s,be=pow2(me,i,s)*T%s,Oe=pow2(be,_2n,s);if(!Fp.eql(Fp.sqr(Oe),o))throw new Error("Cannot find square root");return Oe}const Fp=Field(secp256k1P,void 0,void 0,{sqrt:sqrtMod}),secp256k1=createCurve({a:BigInt(0),b:BigInt(7),Fp,n:secp256k1N,Gx:BigInt("55066263022277343669578718895168534326250603453777594175500187360389116729240"),Gy:BigInt("32670510020758816978083085130507043184471273380659243275938904335757337482424"),h:BigInt(1),lowS:!0,endo:{beta:BigInt("0x7ae96a2b657c07106e64479eac3434e99cf0497512f58995c1396c28719501ee"),splitScalar:o=>{const s=secp256k1N,r=BigInt("0x3086d221a7d46bcde86c90e49284eb15"),i=-_1n*BigInt("0xe4437ed6010e88286f547fa90abfe4c3"),a=BigInt("0x114ca50f7a8e2f3f657c1108d9d44cfd8"),c=r,y=BigInt("0x100000000000000000000000000000000"),w=divNearest(c*o,s),C=divNearest(-i*o,s);let T=mod(o-w*r-C*a,s),S=mod(-w*i-C*c,s);const M=T>y,O=S>y;if(M&&(T=s-T),O&&(S=s-S),T>y||S>y)throw new Error("splitScalar: Endomorphism failed, k="+o);return{k1neg:M,k1:T,k2neg:O,k2:S}}}},sha256$2),_0n=BigInt(0),fe=o=>"bigint"==typeof o&&_0n"bigint"==typeof o&&_0na.charCodeAt(0)));r=concatBytes$2(i,i),TAGGED_HASH_PREFIXES[o]=r}return sha256$2(concatBytes$2(r,...s))}const pointToBytes=o=>o.toRawBytes(!0).slice(1),numTo32b=o=>numberToBytesBE(o,32),modP=o=>mod(o,secp256k1P),modN=o=>mod(o,secp256k1N),Point$1=secp256k1.ProjectivePoint,GmulAdd=(o,s,r)=>Point$1.BASE.multiplyAndAddUnsafe(o,s,r);function schnorrGetExtPubKey(o){let s=secp256k1.utils.normPrivateKeyToScalar(o),r=Point$1.fromPrivateKey(s);return{scalar:r.hasEvenY()?s:modN(-s),bytes:pointToBytes(r)}}function lift_x(o){if(!fe(o))throw new Error("bad x: need 0 < x < p");const s=modP(o*o);let r=sqrtMod(modP(s*o+BigInt(7)));r%_2n!==_0n&&(r=modP(-r));const i=new Point$1(o,r,_1n);return i.assertValidity(),i}function challenge(...o){return modN(bytesToNumberBE(taggedHash("BIP0340/challenge",...o)))}function schnorrGetPublicKey(o){return schnorrGetExtPubKey(o).bytes}function schnorrSign(o,s,r=randomBytes$2(32)){const i=ensureBytes$1("message",o),{bytes:a,scalar:c}=schnorrGetExtPubKey(s),y=ensureBytes$1("auxRand",r,32),w=numTo32b(c^bytesToNumberBE(taggedHash("BIP0340/aux",y))),C=taggedHash("BIP0340/nonce",w,a,i),T=modN(bytesToNumberBE(C));if(T===_0n)throw new Error("sign failed: k is zero");const{bytes:S,scalar:M}=schnorrGetExtPubKey(T),O=challenge(S,a,i),L=new Uint8Array(64);if(L.set(S,0),L.set(numTo32b(modN(M+O*c)),32),!schnorrVerify(L,i,a))throw new Error("sign: Invalid signature produced");return L}function schnorrVerify(o,s,r){const i=ensureBytes$1("signature",o,64),a=ensureBytes$1("message",s),c=ensureBytes$1("publicKey",r,32);try{const y=lift_x(bytesToNumberBE(c)),w=bytesToNumberBE(i.subarray(0,32));if(!fe(w))return!1;const C=bytesToNumberBE(i.subarray(32,64));if(!ge(C))return!1;const T=challenge(numTo32b(w),pointToBytes(y),a),S=GmulAdd(y,C,modN(-T));return!(!S||!S.hasEvenY()||S.toAffine().x!==w)}catch{return!1}}const schnorr={getPublicKey:schnorrGetPublicKey,sign:schnorrSign,verify:schnorrVerify,utils:{randomPrivateKey:secp256k1.utils.randomPrivateKey,lift_x,pointToBytes,numberToBytesBE,bytesToNumberBE,taggedHash,mod}},crypto$2="object"==typeof globalThis&&"crypto"in globalThis?globalThis.crypto:void 0,u8a$1=o=>o instanceof Uint8Array,createView$1=o=>new DataView(o.buffer,o.byteOffset,o.byteLength),rotr$1=(o,s)=>o<<32-s|o>>>s,isLE$2=68===new Uint8Array(new Uint32Array([287454020]).buffer)[0];if(!isLE$2)throw new Error("Non little-endian hardware is not supported");const hexes$1=Array.from({length:256},(o,s)=>s.toString(16).padStart(2,"0"));function bytesToHex$1(o){if(!u8a$1(o))throw new Error("Uint8Array expected");let s="";for(let r=0;ri+a.length,0));let r=0;return o.forEach(i=>{if(!u8a$1(i))throw new Error("Uint8Array expected");s.set(i,r),r+=i.length}),s}let Hash$1=class{clone(){return this._cloneInto()}};function wrapConstructor$1(o){const s=i=>o().update(toBytes$2(i)).digest(),r=o();return s.outputLen=r.outputLen,s.blockLen=r.blockLen,s.create=()=>o(),s}function randomBytes$1(o=32){if(crypto$2&&"function"==typeof crypto$2.getRandomValues)return crypto$2.getRandomValues(new Uint8Array(o));throw new Error("crypto.getRandomValues must be defined")}function number$2(o){if(!Number.isSafeInteger(o)||o<0)throw new Error(`Wrong positive integer: ${o}`)}function bool$2(o){if("boolean"!=typeof o)throw new Error(`Expected boolean, not ${o}`)}function bytes$2(o,...s){if(!(o instanceof Uint8Array))throw new Error("Expected Uint8Array");if(s.length>0&&!s.includes(o.length))throw new Error(`Expected Uint8Array of length ${s}, not of length=${o.length}`)}function hash$2(o){if("function"!=typeof o||"function"!=typeof o.create)throw new Error("Hash should be wrapped by utils.wrapConstructor");number$2(o.outputLen),number$2(o.blockLen)}function exists$2(o,s=!0){if(o.destroyed)throw new Error("Hash instance has been destroyed");if(s&&o.finished)throw new Error("Hash#digest() has already been called")}function output$2(o,s){bytes$2(o);const r=s.outputLen;if(o.length>a&c),w=Number(r&c),T=i?0:4;o.setUint32(s+(i?4:0),y,i),o.setUint32(s+T,w,i)}let SHA2$1=class extends Hash$1{constructor(o,s,r,i){super(),this.blockLen=o,this.outputLen=s,this.padOffset=r,this.isLE=i,this.finished=!1,this.length=0,this.pos=0,this.destroyed=!1,this.buffer=new Uint8Array(o),this.view=createView$1(this.buffer)}update(o){assert$2.exists(this);const{view:s,buffer:r,blockLen:i}=this,a=(o=toBytes$2(o)).length;for(let c=0;ci-c&&(this.process(r,0),c=0);for(let S=c;ST.length)throw new Error("_sha2: outputLen bigger than state");for(let S=0;So&s^~o&r,Maj$1=(o,s,r)=>o&s^o&r^s&r,SHA256_K$1=new Uint32Array([1116352408,1899447441,3049323471,3921009573,961987163,1508970993,2453635748,2870763221,3624381080,310598401,607225278,1426881987,1925078388,2162078206,2614888103,3248222580,3835390401,4022224774,264347078,604807628,770255983,1249150122,1555081692,1996064986,2554220882,2821834349,2952996808,3210313671,3336571891,3584528711,113926993,338241895,666307205,773529912,1294757372,1396182291,1695183700,1986661051,2177026350,2456956037,2730485921,2820302411,3259730800,3345764771,3516065817,3600352804,4094571909,275423344,430227734,506948616,659060556,883997877,958139571,1322822218,1537002063,1747873779,1955562222,2024104815,2227730452,2361852424,2428436474,2756734187,3204031479,3329325298]),IV$1=new Uint32Array([1779033703,3144134277,1013904242,2773480762,1359893119,2600822924,528734635,1541459225]),SHA256_W$1=new Uint32Array(64);let SHA256$1=class extends SHA2$1{constructor(){super(64,32,8,!1),this.A=0|IV$1[0],this.B=0|IV$1[1],this.C=0|IV$1[2],this.D=0|IV$1[3],this.E=0|IV$1[4],this.F=0|IV$1[5],this.G=0|IV$1[6],this.H=0|IV$1[7]}get(){const{A:o,B:s,C:r,D:i,E:a,F:c,G:y,H:w}=this;return[o,s,r,i,a,c,y,w]}set(o,s,r,i,a,c,y,w){this.A=0|o,this.B=0|s,this.C=0|r,this.D=0|i,this.E=0|a,this.F=0|c,this.G=0|y,this.H=0|w}process(o,s){for(let S=0;S<16;S++,s+=4)SHA256_W$1[S]=o.getUint32(s,!1);for(let S=16;S<64;S++){const M=SHA256_W$1[S-15],O=SHA256_W$1[S-2],L=rotr$1(M,7)^rotr$1(M,18)^M>>>3,Z=rotr$1(O,17)^rotr$1(O,19)^O>>>10;SHA256_W$1[S]=Z+SHA256_W$1[S-7]+L+SHA256_W$1[S-16]|0}let{A:r,B:i,C:a,D:c,E:y,F:w,G:C,H:T}=this;for(let S=0;S<64;S++){const M=T+(rotr$1(y,6)^rotr$1(y,11)^rotr$1(y,25))+Chi$1(y,w,C)+SHA256_K$1[S]+SHA256_W$1[S]|0,O=(rotr$1(r,2)^rotr$1(r,13)^rotr$1(r,22))+Maj$1(r,i,a)|0;T=C,C=w,w=y,y=c+M|0,c=a,a=i,i=r,r=M+O|0}r=r+this.A|0,i=i+this.B|0,a=a+this.C|0,c=c+this.D|0,y=y+this.E|0,w=w+this.F|0,C=C+this.G|0,T=T+this.H|0,this.set(r,i,a,c,y,w,C,T)}roundClean(){SHA256_W$1.fill(0)}destroy(){this.set(0,0,0,0,0,0,0,0),this.buffer.fill(0)}};class SHA224 extends SHA256$1{constructor(){super(),this.A=-1056596264,this.B=914150663,this.C=812702999,this.D=-150054599,this.E=-4191439,this.F=1750603025,this.G=1694076839,this.H=-1090891868,this.outputLen=28}}const sha256$1=wrapConstructor$1(()=>new SHA256$1);function assertNumber(o){if(!Number.isSafeInteger(o))throw new Error(`Wrong integer: ${o}`)}function chain$1(...o){const s=(r,i)=>a=>r(i(a));return{encode:Array.from(o).reverse().reduce((r,i)=>r?s(r,i.encode):i.encode,void 0),decode:o.reduce((r,i)=>r?s(r,i.decode):i.decode,void 0)}}function alphabet$1(o){return{encode:s=>{if(!Array.isArray(s)||s.length&&"number"!=typeof s[0])throw new Error("alphabet.encode input should be an array of numbers");return s.map(r=>{if(assertNumber(r),r<0||r>=o.length)throw new Error(`Digit index outside alphabet: ${r} (alphabet: ${o.length})`);return o[r]})},decode:s=>{if(!Array.isArray(s)||s.length&&"string"!=typeof s[0])throw new Error("alphabet.decode input should be array of strings");return s.map(r=>{if("string"!=typeof r)throw new Error(`alphabet.decode: not string element=${r}`);const i=o.indexOf(r);if(-1===i)throw new Error(`Unknown letter: "${r}". Allowed: ${o}`);return i})}}}function join$1(o=""){if("string"!=typeof o)throw new Error("join separator should be string");return{encode:s=>{if(!Array.isArray(s)||s.length&&"string"!=typeof s[0])throw new Error("join.encode input should be array of strings");for(let r of s)if("string"!=typeof r)throw new Error(`join.encode: non-string input=${r}`);return s.join(o)},decode:s=>{if("string"!=typeof s)throw new Error("join.decode input should be string");return s.split(o)}}}function padding$1(o,s="="){if(assertNumber(o),"string"!=typeof s)throw new Error("padding chr should be string");return{encode(r){if(!Array.isArray(r)||r.length&&"string"!=typeof r[0])throw new Error("padding.encode input should be array of strings");for(let i of r)if("string"!=typeof i)throw new Error(`padding.encode: non-string input=${i}`);for(;r.length*o%8;)r.push(s);return r},decode(r){if(!Array.isArray(r)||r.length&&"string"!=typeof r[0])throw new Error("padding.encode input should be array of strings");for(let a of r)if("string"!=typeof a)throw new Error(`padding.decode: non-string input=${a}`);let i=r.length;if(i*o%8)throw new Error("Invalid padding: string should have whole number of bytes");for(;i>0&&r[i-1]===s;i--)if(!((i-1)*o%8))throw new Error("Invalid padding: string has too much padding");return r.slice(0,i)}}}function normalize$1(o){if("function"!=typeof o)throw new Error("normalize fn should be function");return{encode:s=>s,decode:s=>o(s)}}function convertRadix$1(o,s,r){if(s<2)throw new Error(`convertRadix: wrong from=${s}, base cannot be less than 2`);if(r<2)throw new Error(`convertRadix: wrong to=${r}, base cannot be less than 2`);if(!Array.isArray(o))throw new Error("convertRadix: data should be array");if(!o.length)return[];let i=0;const a=[],c=Array.from(o);for(c.forEach(y=>{if(assertNumber(y),y<0||y>=s)throw new Error(`Wrong integer: ${y}`)});;){let y=0,w=!0;for(let C=i;Cnew SHA224);const gcd$1=(o,s)=>s?gcd$1(s,o%s):o,radix2carry$1=(o,s)=>o+(s-gcd$1(o,s));function convertRadix2$1(o,s,r,i){if(!Array.isArray(o))throw new Error("convertRadix2: data should be array");if(s<=0||s>32)throw new Error(`convertRadix2: wrong from=${s}`);if(r<=0||r>32)throw new Error(`convertRadix2: wrong to=${r}`);if(radix2carry$1(s,r)>32)throw new Error(`convertRadix2: carry overflow from=${s} to=${r} carryBits=${radix2carry$1(s,r)}`);let a=0,c=0;const y=2**r-1,w=[];for(const C of o){if(assertNumber(C),C>=2**s)throw new Error(`convertRadix2: invalid data word=${C} from=${s}`);if(a=a<32)throw new Error(`convertRadix2: carry overflow pos=${c} from=${s}`);for(c+=s;c>=r;c-=r)w.push((a>>c-r&y)>>>0);a&=2**c-1}if(a=a<=s)throw new Error("Excess padding");if(!i&&a)throw new Error(`Non-zero padding: ${a}`);return i&&c>0&&w.push(a>>>0),w}function radix$1(o){return assertNumber(o),{encode:s=>{if(!(s instanceof Uint8Array))throw new Error("radix.encode input should be Uint8Array");return convertRadix$1(Array.from(s),256,o)},decode:s=>{if(!Array.isArray(s)||s.length&&"number"!=typeof s[0])throw new Error("radix.decode input should be array of strings");return Uint8Array.from(convertRadix$1(s,o,256))}}}function radix2$1(o,s=!1){if(assertNumber(o),o<=0||o>32)throw new Error("radix2: bits should be in (0..32]");if(radix2carry$1(8,o)>32||radix2carry$1(o,8)>32)throw new Error("radix2: carry overflow");return{encode:r=>{if(!(r instanceof Uint8Array))throw new Error("radix2.encode input should be Uint8Array");return convertRadix2$1(Array.from(r),8,o,!s)},decode:r=>{if(!Array.isArray(r)||r.length&&"number"!=typeof r[0])throw new Error("radix2.decode input should be array of strings");return Uint8Array.from(convertRadix2$1(r,o,8,s))}}}function unsafeWrapper$1(o){if("function"!=typeof o)throw new Error("unsafeWrapper fn should be function");return function(...s){try{return o.apply(null,s)}catch{}}}const base16=chain$1(radix2$1(4),alphabet$1("0123456789ABCDEF"),join$1("")),base32=chain$1(radix2$1(5),alphabet$1("ABCDEFGHIJKLMNOPQRSTUVWXYZ234567"),padding$1(5),join$1(""));chain$1(radix2$1(5),alphabet$1("0123456789ABCDEFGHIJKLMNOPQRSTUV"),padding$1(5),join$1("")),chain$1(radix2$1(5),alphabet$1("0123456789ABCDEFGHJKMNPQRSTVWXYZ"),join$1(""),normalize$1(o=>o.toUpperCase().replace(/O/g,"0").replace(/[IL]/g,"1")));const base64$1=chain$1(radix2$1(6),alphabet$1("ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/"),padding$1(6),join$1("")),base64url=chain$1(radix2$1(6),alphabet$1("ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789-_"),padding$1(6),join$1("")),genBase58$1=o=>chain$1(radix$1(58),alphabet$1(o),join$1("")),base58$1=genBase58$1("123456789ABCDEFGHJKLMNPQRSTUVWXYZabcdefghijkmnopqrstuvwxyz");genBase58$1("123456789abcdefghijkmnopqrstuvwxyzABCDEFGHJKLMNPQRSTUVWXYZ"),genBase58$1("rpshnaf39wBUDNEGHJKLM4PQRST7VWXYZ2bcdeCg65jkm8oFqi1tuvAxyz");const XMR_BLOCK_LEN=[0,2,3,5,6,7,9,10,11],base58xmr={encode(o){let s="";for(let r=0;r>25;let r=(33554431&o)<<5;for(let i=0;i>i&1)&&(r^=POLYMOD_GENERATORS$1[i]);return r}function bechChecksum$1(o,s,r=1){const i=o.length;let a=1;for(let c=0;c126)throw new Error(`Invalid prefix (${o})`);a=bech32Polymod$1(a)^y>>5}a=bech32Polymod$1(a);for(let c=0;cC)throw new TypeError(`Wrong string length: ${w.length} (${w}). Expected (8..${C})`);const T=w.toLowerCase();if(w!==T&&w!==w.toUpperCase())throw new Error("String must be lowercase or uppercase");const S=(w=T).lastIndexOf("1");if(0===S||-1===S)throw new Error('Letter "1" must be present between prefix and data only');const M=w.slice(0,S),O=w.slice(S+1);if(O.length<6)throw new Error("Data must be at least 6 characters long");const L=BECH_ALPHABET$1.decode(O).slice(0,-6),Z=bechChecksum$1(M,L,s);if(!O.endsWith(Z))throw new Error(`Invalid checksum in ${w}: expected "${Z}"`);return{prefix:M,words:L}}return{encode:function(w,C,T=90){if("string"!=typeof w)throw new Error("bech32.encode prefix should be string, not "+typeof w);if(!Array.isArray(C)||C.length&&"number"!=typeof C[0])throw new Error("bech32.encode words should be array of numbers, not "+typeof C);const S=w.length+7+C.length;if(!1!==T&&S>T)throw new TypeError(`Length ${S} exceeds limit ${T}`);return`${w=w.toLowerCase()}1${BECH_ALPHABET$1.encode(C)}${bechChecksum$1(w,C,s)}`},decode:y,decodeToBytes:function(w){const{prefix:C,words:T}=y(w,!1);return{prefix:C,words:T,bytes:i(T)}},decodeUnsafe:unsafeWrapper$1(y),fromWords:i,fromWordsUnsafe:c,toWords:a}}const bech32$1=genBech32$1("bech32");genBech32$1("bech32m");const utf8={encode:o=>(new TextDecoder).decode(o),decode:o=>(new TextEncoder).encode(o)},hex=chain$1(radix2$1(4),alphabet$1("0123456789abcdef"),join$1(""),normalize$1(o=>{if("string"!=typeof o||o.length%2)throw new TypeError(`hex.decode: expected string, got ${typeof o} with length ${o.length}`);return o.toLowerCase()})),CODERS={utf8,hex,base16,base32,base64:base64$1,base64url,base58:base58$1,base58xmr};Object.keys(CODERS).join(", ");const wordlist="abandon\nability\nable\nabout\nabove\nabsent\nabsorb\nabstract\nabsurd\nabuse\naccess\naccident\naccount\naccuse\nachieve\nacid\nacoustic\nacquire\nacross\nact\naction\nactor\nactress\nactual\nadapt\nadd\naddict\naddress\nadjust\nadmit\nadult\nadvance\nadvice\naerobic\naffair\nafford\nafraid\nagain\nage\nagent\nagree\nahead\naim\nair\nairport\naisle\nalarm\nalbum\nalcohol\nalert\nalien\nall\nalley\nallow\nalmost\nalone\nalpha\nalready\nalso\nalter\nalways\namateur\namazing\namong\namount\namused\nanalyst\nanchor\nancient\nanger\nangle\nangry\nanimal\nankle\nannounce\nannual\nanother\nanswer\nantenna\nantique\nanxiety\nany\napart\napology\nappear\napple\napprove\napril\narch\narctic\narea\narena\nargue\narm\narmed\narmor\narmy\naround\narrange\narrest\narrive\narrow\nart\nartefact\nartist\nartwork\nask\naspect\nassault\nasset\nassist\nassume\nasthma\nathlete\natom\nattack\nattend\nattitude\nattract\nauction\naudit\naugust\naunt\nauthor\nauto\nautumn\naverage\navocado\navoid\nawake\naware\naway\nawesome\nawful\nawkward\naxis\nbaby\nbachelor\nbacon\nbadge\nbag\nbalance\nbalcony\nball\nbamboo\nbanana\nbanner\nbar\nbarely\nbargain\nbarrel\nbase\nbasic\nbasket\nbattle\nbeach\nbean\nbeauty\nbecause\nbecome\nbeef\nbefore\nbegin\nbehave\nbehind\nbelieve\nbelow\nbelt\nbench\nbenefit\nbest\nbetray\nbetter\nbetween\nbeyond\nbicycle\nbid\nbike\nbind\nbiology\nbird\nbirth\nbitter\nblack\nblade\nblame\nblanket\nblast\nbleak\nbless\nblind\nblood\nblossom\nblouse\nblue\nblur\nblush\nboard\nboat\nbody\nboil\nbomb\nbone\nbonus\nbook\nboost\nborder\nboring\nborrow\nboss\nbottom\nbounce\nbox\nboy\nbracket\nbrain\nbrand\nbrass\nbrave\nbread\nbreeze\nbrick\nbridge\nbrief\nbright\nbring\nbrisk\nbroccoli\nbroken\nbronze\nbroom\nbrother\nbrown\nbrush\nbubble\nbuddy\nbudget\nbuffalo\nbuild\nbulb\nbulk\nbullet\nbundle\nbunker\nburden\nburger\nburst\nbus\nbusiness\nbusy\nbutter\nbuyer\nbuzz\ncabbage\ncabin\ncable\ncactus\ncage\ncake\ncall\ncalm\ncamera\ncamp\ncan\ncanal\ncancel\ncandy\ncannon\ncanoe\ncanvas\ncanyon\ncapable\ncapital\ncaptain\ncar\ncarbon\ncard\ncargo\ncarpet\ncarry\ncart\ncase\ncash\ncasino\ncastle\ncasual\ncat\ncatalog\ncatch\ncategory\ncattle\ncaught\ncause\ncaution\ncave\nceiling\ncelery\ncement\ncensus\ncentury\ncereal\ncertain\nchair\nchalk\nchampion\nchange\nchaos\nchapter\ncharge\nchase\nchat\ncheap\ncheck\ncheese\nchef\ncherry\nchest\nchicken\nchief\nchild\nchimney\nchoice\nchoose\nchronic\nchuckle\nchunk\nchurn\ncigar\ncinnamon\ncircle\ncitizen\ncity\ncivil\nclaim\nclap\nclarify\nclaw\nclay\nclean\nclerk\nclever\nclick\nclient\ncliff\nclimb\nclinic\nclip\nclock\nclog\nclose\ncloth\ncloud\nclown\nclub\nclump\ncluster\nclutch\ncoach\ncoast\ncoconut\ncode\ncoffee\ncoil\ncoin\ncollect\ncolor\ncolumn\ncombine\ncome\ncomfort\ncomic\ncommon\ncompany\nconcert\nconduct\nconfirm\ncongress\nconnect\nconsider\ncontrol\nconvince\ncook\ncool\ncopper\ncopy\ncoral\ncore\ncorn\ncorrect\ncost\ncotton\ncouch\ncountry\ncouple\ncourse\ncousin\ncover\ncoyote\ncrack\ncradle\ncraft\ncram\ncrane\ncrash\ncrater\ncrawl\ncrazy\ncream\ncredit\ncreek\ncrew\ncricket\ncrime\ncrisp\ncritic\ncrop\ncross\ncrouch\ncrowd\ncrucial\ncruel\ncruise\ncrumble\ncrunch\ncrush\ncry\ncrystal\ncube\nculture\ncup\ncupboard\ncurious\ncurrent\ncurtain\ncurve\ncushion\ncustom\ncute\ncycle\ndad\ndamage\ndamp\ndance\ndanger\ndaring\ndash\ndaughter\ndawn\nday\ndeal\ndebate\ndebris\ndecade\ndecember\ndecide\ndecline\ndecorate\ndecrease\ndeer\ndefense\ndefine\ndefy\ndegree\ndelay\ndeliver\ndemand\ndemise\ndenial\ndentist\ndeny\ndepart\ndepend\ndeposit\ndepth\ndeputy\nderive\ndescribe\ndesert\ndesign\ndesk\ndespair\ndestroy\ndetail\ndetect\ndevelop\ndevice\ndevote\ndiagram\ndial\ndiamond\ndiary\ndice\ndiesel\ndiet\ndiffer\ndigital\ndignity\ndilemma\ndinner\ndinosaur\ndirect\ndirt\ndisagree\ndiscover\ndisease\ndish\ndismiss\ndisorder\ndisplay\ndistance\ndivert\ndivide\ndivorce\ndizzy\ndoctor\ndocument\ndog\ndoll\ndolphin\ndomain\ndonate\ndonkey\ndonor\ndoor\ndose\ndouble\ndove\ndraft\ndragon\ndrama\ndrastic\ndraw\ndream\ndress\ndrift\ndrill\ndrink\ndrip\ndrive\ndrop\ndrum\ndry\nduck\ndumb\ndune\nduring\ndust\ndutch\nduty\ndwarf\ndynamic\neager\neagle\nearly\nearn\nearth\neasily\neast\neasy\necho\necology\neconomy\nedge\nedit\neducate\neffort\negg\neight\neither\nelbow\nelder\nelectric\nelegant\nelement\nelephant\nelevator\nelite\nelse\nembark\nembody\nembrace\nemerge\nemotion\nemploy\nempower\nempty\nenable\nenact\nend\nendless\nendorse\nenemy\nenergy\nenforce\nengage\nengine\nenhance\nenjoy\nenlist\nenough\nenrich\nenroll\nensure\nenter\nentire\nentry\nenvelope\nepisode\nequal\nequip\nera\nerase\nerode\nerosion\nerror\nerupt\nescape\nessay\nessence\nestate\neternal\nethics\nevidence\nevil\nevoke\nevolve\nexact\nexample\nexcess\nexchange\nexcite\nexclude\nexcuse\nexecute\nexercise\nexhaust\nexhibit\nexile\nexist\nexit\nexotic\nexpand\nexpect\nexpire\nexplain\nexpose\nexpress\nextend\nextra\neye\neyebrow\nfabric\nface\nfaculty\nfade\nfaint\nfaith\nfall\nfalse\nfame\nfamily\nfamous\nfan\nfancy\nfantasy\nfarm\nfashion\nfat\nfatal\nfather\nfatigue\nfault\nfavorite\nfeature\nfebruary\nfederal\nfee\nfeed\nfeel\nfemale\nfence\nfestival\nfetch\nfever\nfew\nfiber\nfiction\nfield\nfigure\nfile\nfilm\nfilter\nfinal\nfind\nfine\nfinger\nfinish\nfire\nfirm\nfirst\nfiscal\nfish\nfit\nfitness\nfix\nflag\nflame\nflash\nflat\nflavor\nflee\nflight\nflip\nfloat\nflock\nfloor\nflower\nfluid\nflush\nfly\nfoam\nfocus\nfog\nfoil\nfold\nfollow\nfood\nfoot\nforce\nforest\nforget\nfork\nfortune\nforum\nforward\nfossil\nfoster\nfound\nfox\nfragile\nframe\nfrequent\nfresh\nfriend\nfringe\nfrog\nfront\nfrost\nfrown\nfrozen\nfruit\nfuel\nfun\nfunny\nfurnace\nfury\nfuture\ngadget\ngain\ngalaxy\ngallery\ngame\ngap\ngarage\ngarbage\ngarden\ngarlic\ngarment\ngas\ngasp\ngate\ngather\ngauge\ngaze\ngeneral\ngenius\ngenre\ngentle\ngenuine\ngesture\nghost\ngiant\ngift\ngiggle\nginger\ngiraffe\ngirl\ngive\nglad\nglance\nglare\nglass\nglide\nglimpse\nglobe\ngloom\nglory\nglove\nglow\nglue\ngoat\ngoddess\ngold\ngood\ngoose\ngorilla\ngospel\ngossip\ngovern\ngown\ngrab\ngrace\ngrain\ngrant\ngrape\ngrass\ngravity\ngreat\ngreen\ngrid\ngrief\ngrit\ngrocery\ngroup\ngrow\ngrunt\nguard\nguess\nguide\nguilt\nguitar\ngun\ngym\nhabit\nhair\nhalf\nhammer\nhamster\nhand\nhappy\nharbor\nhard\nharsh\nharvest\nhat\nhave\nhawk\nhazard\nhead\nhealth\nheart\nheavy\nhedgehog\nheight\nhello\nhelmet\nhelp\nhen\nhero\nhidden\nhigh\nhill\nhint\nhip\nhire\nhistory\nhobby\nhockey\nhold\nhole\nholiday\nhollow\nhome\nhoney\nhood\nhope\nhorn\nhorror\nhorse\nhospital\nhost\nhotel\nhour\nhover\nhub\nhuge\nhuman\nhumble\nhumor\nhundred\nhungry\nhunt\nhurdle\nhurry\nhurt\nhusband\nhybrid\nice\nicon\nidea\nidentify\nidle\nignore\nill\nillegal\nillness\nimage\nimitate\nimmense\nimmune\nimpact\nimpose\nimprove\nimpulse\ninch\ninclude\nincome\nincrease\nindex\nindicate\nindoor\nindustry\ninfant\ninflict\ninform\ninhale\ninherit\ninitial\ninject\ninjury\ninmate\ninner\ninnocent\ninput\ninquiry\ninsane\ninsect\ninside\ninspire\ninstall\nintact\ninterest\ninto\ninvest\ninvite\ninvolve\niron\nisland\nisolate\nissue\nitem\nivory\njacket\njaguar\njar\njazz\njealous\njeans\njelly\njewel\njob\njoin\njoke\njourney\njoy\njudge\njuice\njump\njungle\njunior\njunk\njust\nkangaroo\nkeen\nkeep\nketchup\nkey\nkick\nkid\nkidney\nkind\nkingdom\nkiss\nkit\nkitchen\nkite\nkitten\nkiwi\nknee\nknife\nknock\nknow\nlab\nlabel\nlabor\nladder\nlady\nlake\nlamp\nlanguage\nlaptop\nlarge\nlater\nlatin\nlaugh\nlaundry\nlava\nlaw\nlawn\nlawsuit\nlayer\nlazy\nleader\nleaf\nlearn\nleave\nlecture\nleft\nleg\nlegal\nlegend\nleisure\nlemon\nlend\nlength\nlens\nleopard\nlesson\nletter\nlevel\nliar\nliberty\nlibrary\nlicense\nlife\nlift\nlight\nlike\nlimb\nlimit\nlink\nlion\nliquid\nlist\nlittle\nlive\nlizard\nload\nloan\nlobster\nlocal\nlock\nlogic\nlonely\nlong\nloop\nlottery\nloud\nlounge\nlove\nloyal\nlucky\nluggage\nlumber\nlunar\nlunch\nluxury\nlyrics\nmachine\nmad\nmagic\nmagnet\nmaid\nmail\nmain\nmajor\nmake\nmammal\nman\nmanage\nmandate\nmango\nmansion\nmanual\nmaple\nmarble\nmarch\nmargin\nmarine\nmarket\nmarriage\nmask\nmass\nmaster\nmatch\nmaterial\nmath\nmatrix\nmatter\nmaximum\nmaze\nmeadow\nmean\nmeasure\nmeat\nmechanic\nmedal\nmedia\nmelody\nmelt\nmember\nmemory\nmention\nmenu\nmercy\nmerge\nmerit\nmerry\nmesh\nmessage\nmetal\nmethod\nmiddle\nmidnight\nmilk\nmillion\nmimic\nmind\nminimum\nminor\nminute\nmiracle\nmirror\nmisery\nmiss\nmistake\nmix\nmixed\nmixture\nmobile\nmodel\nmodify\nmom\nmoment\nmonitor\nmonkey\nmonster\nmonth\nmoon\nmoral\nmore\nmorning\nmosquito\nmother\nmotion\nmotor\nmountain\nmouse\nmove\nmovie\nmuch\nmuffin\nmule\nmultiply\nmuscle\nmuseum\nmushroom\nmusic\nmust\nmutual\nmyself\nmystery\nmyth\nnaive\nname\nnapkin\nnarrow\nnasty\nnation\nnature\nnear\nneck\nneed\nnegative\nneglect\nneither\nnephew\nnerve\nnest\nnet\nnetwork\nneutral\nnever\nnews\nnext\nnice\nnight\nnoble\nnoise\nnominee\nnoodle\nnormal\nnorth\nnose\nnotable\nnote\nnothing\nnotice\nnovel\nnow\nnuclear\nnumber\nnurse\nnut\noak\nobey\nobject\noblige\nobscure\nobserve\nobtain\nobvious\noccur\nocean\noctober\nodor\noff\noffer\noffice\noften\noil\nokay\nold\nolive\nolympic\nomit\nonce\none\nonion\nonline\nonly\nopen\nopera\nopinion\noppose\noption\norange\norbit\norchard\norder\nordinary\norgan\norient\noriginal\norphan\nostrich\nother\noutdoor\nouter\noutput\noutside\noval\noven\nover\nown\nowner\noxygen\noyster\nozone\npact\npaddle\npage\npair\npalace\npalm\npanda\npanel\npanic\npanther\npaper\nparade\nparent\npark\nparrot\nparty\npass\npatch\npath\npatient\npatrol\npattern\npause\npave\npayment\npeace\npeanut\npear\npeasant\npelican\npen\npenalty\npencil\npeople\npepper\nperfect\npermit\nperson\npet\nphone\nphoto\nphrase\nphysical\npiano\npicnic\npicture\npiece\npig\npigeon\npill\npilot\npink\npioneer\npipe\npistol\npitch\npizza\nplace\nplanet\nplastic\nplate\nplay\nplease\npledge\npluck\nplug\nplunge\npoem\npoet\npoint\npolar\npole\npolice\npond\npony\npool\npopular\nportion\nposition\npossible\npost\npotato\npottery\npoverty\npowder\npower\npractice\npraise\npredict\nprefer\nprepare\npresent\npretty\nprevent\nprice\npride\nprimary\nprint\npriority\nprison\nprivate\nprize\nproblem\nprocess\nproduce\nprofit\nprogram\nproject\npromote\nproof\nproperty\nprosper\nprotect\nproud\nprovide\npublic\npudding\npull\npulp\npulse\npumpkin\npunch\npupil\npuppy\npurchase\npurity\npurpose\npurse\npush\nput\npuzzle\npyramid\nquality\nquantum\nquarter\nquestion\nquick\nquit\nquiz\nquote\nrabbit\nraccoon\nrace\nrack\nradar\nradio\nrail\nrain\nraise\nrally\nramp\nranch\nrandom\nrange\nrapid\nrare\nrate\nrather\nraven\nraw\nrazor\nready\nreal\nreason\nrebel\nrebuild\nrecall\nreceive\nrecipe\nrecord\nrecycle\nreduce\nreflect\nreform\nrefuse\nregion\nregret\nregular\nreject\nrelax\nrelease\nrelief\nrely\nremain\nremember\nremind\nremove\nrender\nrenew\nrent\nreopen\nrepair\nrepeat\nreplace\nreport\nrequire\nrescue\nresemble\nresist\nresource\nresponse\nresult\nretire\nretreat\nreturn\nreunion\nreveal\nreview\nreward\nrhythm\nrib\nribbon\nrice\nrich\nride\nridge\nrifle\nright\nrigid\nring\nriot\nripple\nrisk\nritual\nrival\nriver\nroad\nroast\nrobot\nrobust\nrocket\nromance\nroof\nrookie\nroom\nrose\nrotate\nrough\nround\nroute\nroyal\nrubber\nrude\nrug\nrule\nrun\nrunway\nrural\nsad\nsaddle\nsadness\nsafe\nsail\nsalad\nsalmon\nsalon\nsalt\nsalute\nsame\nsample\nsand\nsatisfy\nsatoshi\nsauce\nsausage\nsave\nsay\nscale\nscan\nscare\nscatter\nscene\nscheme\nschool\nscience\nscissors\nscorpion\nscout\nscrap\nscreen\nscript\nscrub\nsea\nsearch\nseason\nseat\nsecond\nsecret\nsection\nsecurity\nseed\nseek\nsegment\nselect\nsell\nseminar\nsenior\nsense\nsentence\nseries\nservice\nsession\nsettle\nsetup\nseven\nshadow\nshaft\nshallow\nshare\nshed\nshell\nsheriff\nshield\nshift\nshine\nship\nshiver\nshock\nshoe\nshoot\nshop\nshort\nshoulder\nshove\nshrimp\nshrug\nshuffle\nshy\nsibling\nsick\nside\nsiege\nsight\nsign\nsilent\nsilk\nsilly\nsilver\nsimilar\nsimple\nsince\nsing\nsiren\nsister\nsituate\nsix\nsize\nskate\nsketch\nski\nskill\nskin\nskirt\nskull\nslab\nslam\nsleep\nslender\nslice\nslide\nslight\nslim\nslogan\nslot\nslow\nslush\nsmall\nsmart\nsmile\nsmoke\nsmooth\nsnack\nsnake\nsnap\nsniff\nsnow\nsoap\nsoccer\nsocial\nsock\nsoda\nsoft\nsolar\nsoldier\nsolid\nsolution\nsolve\nsomeone\nsong\nsoon\nsorry\nsort\nsoul\nsound\nsoup\nsource\nsouth\nspace\nspare\nspatial\nspawn\nspeak\nspecial\nspeed\nspell\nspend\nsphere\nspice\nspider\nspike\nspin\nspirit\nsplit\nspoil\nsponsor\nspoon\nsport\nspot\nspray\nspread\nspring\nspy\nsquare\nsqueeze\nsquirrel\nstable\nstadium\nstaff\nstage\nstairs\nstamp\nstand\nstart\nstate\nstay\nsteak\nsteel\nstem\nstep\nstereo\nstick\nstill\nsting\nstock\nstomach\nstone\nstool\nstory\nstove\nstrategy\nstreet\nstrike\nstrong\nstruggle\nstudent\nstuff\nstumble\nstyle\nsubject\nsubmit\nsubway\nsuccess\nsuch\nsudden\nsuffer\nsugar\nsuggest\nsuit\nsummer\nsun\nsunny\nsunset\nsuper\nsupply\nsupreme\nsure\nsurface\nsurge\nsurprise\nsurround\nsurvey\nsuspect\nsustain\nswallow\nswamp\nswap\nswarm\nswear\nsweet\nswift\nswim\nswing\nswitch\nsword\nsymbol\nsymptom\nsyrup\nsystem\ntable\ntackle\ntag\ntail\ntalent\ntalk\ntank\ntape\ntarget\ntask\ntaste\ntattoo\ntaxi\nteach\nteam\ntell\nten\ntenant\ntennis\ntent\nterm\ntest\ntext\nthank\nthat\ntheme\nthen\ntheory\nthere\nthey\nthing\nthis\nthought\nthree\nthrive\nthrow\nthumb\nthunder\nticket\ntide\ntiger\ntilt\ntimber\ntime\ntiny\ntip\ntired\ntissue\ntitle\ntoast\ntobacco\ntoday\ntoddler\ntoe\ntogether\ntoilet\ntoken\ntomato\ntomorrow\ntone\ntongue\ntonight\ntool\ntooth\ntop\ntopic\ntopple\ntorch\ntornado\ntortoise\ntoss\ntotal\ntourist\ntoward\ntower\ntown\ntoy\ntrack\ntrade\ntraffic\ntragic\ntrain\ntransfer\ntrap\ntrash\ntravel\ntray\ntreat\ntree\ntrend\ntrial\ntribe\ntrick\ntrigger\ntrim\ntrip\ntrophy\ntrouble\ntruck\ntrue\ntruly\ntrumpet\ntrust\ntruth\ntry\ntube\ntuition\ntumble\ntuna\ntunnel\nturkey\nturn\nturtle\ntwelve\ntwenty\ntwice\ntwin\ntwist\ntwo\ntype\ntypical\nugly\numbrella\nunable\nunaware\nuncle\nuncover\nunder\nundo\nunfair\nunfold\nunhappy\nuniform\nunique\nunit\nuniverse\nunknown\nunlock\nuntil\nunusual\nunveil\nupdate\nupgrade\nuphold\nupon\nupper\nupset\nurban\nurge\nusage\nuse\nused\nuseful\nuseless\nusual\nutility\nvacant\nvacuum\nvague\nvalid\nvalley\nvalve\nvan\nvanish\nvapor\nvarious\nvast\nvault\nvehicle\nvelvet\nvendor\nventure\nvenue\nverb\nverify\nversion\nvery\nvessel\nveteran\nviable\nvibrant\nvicious\nvictory\nvideo\nview\nvillage\nvintage\nviolin\nvirtual\nvirus\nvisa\nvisit\nvisual\nvital\nvivid\nvocal\nvoice\nvoid\nvolcano\nvolume\nvote\nvoyage\nwage\nwagon\nwait\nwalk\nwall\nwalnut\nwant\nwarfare\nwarm\nwarrior\nwash\nwasp\nwaste\nwater\nwave\nway\nwealth\nweapon\nwear\nweasel\nweather\nweb\nwedding\nweekend\nweird\nwelcome\nwest\nwet\nwhale\nwhat\nwheat\nwheel\nwhen\nwhere\nwhip\nwhisper\nwide\nwidth\nwife\nwild\nwill\nwin\nwindow\nwine\nwing\nwink\nwinner\nwinter\nwire\nwisdom\nwise\nwish\nwitness\nwolf\nwoman\nwonder\nwood\nwool\nword\nwork\nworld\nworry\nworth\nwrap\nwreck\nwrestle\nwrist\nwrite\nwrong\nyard\nyear\nyellow\nyou\nyoung\nyouth\nzebra\nzero\nzone\nzoo".split("\n");function number$1(o){if(!Number.isSafeInteger(o)||o<0)throw new Error(`Wrong positive integer: ${o}`)}function bool$1(o){if("boolean"!=typeof o)throw new Error(`Expected boolean, not ${o}`)}function isBytes$2(o){return o instanceof Uint8Array||null!=o&&"object"==typeof o&&"Uint8Array"===o.constructor.name}function bytes$1(o,...s){if(!isBytes$2(o))throw new Error("Expected Uint8Array");if(s.length>0&&!s.includes(o.length))throw new Error(`Expected Uint8Array of length ${s}, not of length=${o.length}`)}function hash$1(o){if("function"!=typeof o||"function"!=typeof o.create)throw new Error("Hash should be wrapped by utils.wrapConstructor");number$1(o.outputLen),number$1(o.blockLen)}function exists$1(o,s=!0){if(o.destroyed)throw new Error("Hash instance has been destroyed");if(s&&o.finished)throw new Error("Hash#digest() has already been called")}function output$1(o,s){bytes$1(o);const r=s.outputLen;if(o.lengthnew DataView(o.buffer,o.byteOffset,o.byteLength),rotr=(o,s)=>o<<32-s|o>>>s,isLE$1=68===new Uint8Array(new Uint32Array([287454020]).buffer)[0];if(!isLE$1)throw new Error("Non little-endian hardware is not supported");const hexes=Array.from({length:256},(o,s)=>s.toString(16).padStart(2,"0"));function bytesToHex(o){if(!isBytes$1(o))throw new Error("Uint8Array expected");let s="";for(let r=0;r=asciis._0&&o<=asciis._9?o-asciis._0:o>=asciis._A&&o<=asciis._F?o-(asciis._A-10):o>=asciis._a&&o<=asciis._f?o-(asciis._a-10):void 0}function hexToBytes(o){if("string"!=typeof o)throw new Error("hex string expected, got "+typeof o);const s=o.length,r=s/2;if(s%2)throw new Error("padded hex string expected, got unpadded hex of length "+s);const i=new Uint8Array(r);for(let a=0,c=0;ao().update(toBytes$1(i)).digest(),r=o();return s.outputLen=r.outputLen,s.blockLen=r.blockLen,s.create=()=>o(),s}function randomBytes(o=32){if(crypto$1&&"function"==typeof crypto$1.getRandomValues)return crypto$1.getRandomValues(new Uint8Array(o));throw new Error("crypto.getRandomValues must be defined")}let HMAC$1=class extends Hash{constructor(o,s){super(),this.finished=!1,this.destroyed=!1,hash$1(o);const r=toBytes$1(s);if(this.iHash=o.create(),"function"!=typeof this.iHash.update)throw new Error("Expected instance of class which extends utils.Hash");this.blockLen=this.iHash.blockLen,this.outputLen=this.iHash.outputLen;const i=this.blockLen,a=new Uint8Array(i);a.set(r.length>i?o.create().update(r).digest():r);for(let c=0;cnew HMAC$1(o,s).update(r).digest();function pbkdf2Init(o,s,r,i){hash$1(o);const a=checkOpts$1({dkLen:32,asyncTick:10},i),{c,dkLen:y,asyncTick:w}=a;if(number$1(c),number$1(y),number$1(w),c<1)throw new Error("PBKDF2: iterations (c) should be >= 1");const C=toBytes$1(s),T=toBytes$1(r),S=new Uint8Array(y),M=hmac$1.create(o,C),O=M._cloneInto().update(T);return{c,dkLen:y,asyncTick:w,DK:S,PRF:M,PRFSalt:O}}function pbkdf2Output(o,s,r,i,a){return o.destroy(),s.destroy(),i&&i.destroy(),a.fill(0),r}function pbkdf2(o,s,r,i){const{c:a,dkLen:c,DK:y,PRF:w,PRFSalt:C}=pbkdf2Init(o,s,r,i);let T;const S=new Uint8Array(4),M=createView(S),O=new Uint8Array(w.outputLen);for(let L=1,Z=0;Z>a&c),w=Number(r&c),T=i?0:4;o.setUint32(s+(i?4:0),y,i),o.setUint32(s+T,w,i)}hmac$1.create=(o,s)=>new HMAC$1(o,s);class SHA2 extends Hash{constructor(s,r,i,a){super(),this.blockLen=s,this.outputLen=r,this.padOffset=i,this.isLE=a,this.finished=!1,this.length=0,this.pos=0,this.destroyed=!1,this.buffer=new Uint8Array(s),this.view=createView(this.buffer)}update(s){exists$1(this);const{view:r,buffer:i,blockLen:a}=this,c=(s=toBytes$1(s)).length;for(let y=0;ya-y&&(this.process(i,0),y=0);for(let M=y;MS.length)throw new Error("_sha2: outputLen bigger than state");for(let M=0;Mo&s^~o&r,Maj=(o,s,r)=>o&s^o&r^s&r,SHA256_K=new Uint32Array([1116352408,1899447441,3049323471,3921009573,961987163,1508970993,2453635748,2870763221,3624381080,310598401,607225278,1426881987,1925078388,2162078206,2614888103,3248222580,3835390401,4022224774,264347078,604807628,770255983,1249150122,1555081692,1996064986,2554220882,2821834349,2952996808,3210313671,3336571891,3584528711,113926993,338241895,666307205,773529912,1294757372,1396182291,1695183700,1986661051,2177026350,2456956037,2730485921,2820302411,3259730800,3345764771,3516065817,3600352804,4094571909,275423344,430227734,506948616,659060556,883997877,958139571,1322822218,1537002063,1747873779,1955562222,2024104815,2227730452,2361852424,2428436474,2756734187,3204031479,3329325298]),IV=new Uint32Array([1779033703,3144134277,1013904242,2773480762,1359893119,2600822924,528734635,1541459225]),SHA256_W=new Uint32Array(64);class SHA256 extends SHA2{constructor(){super(64,32,8,!1),this.A=0|IV[0],this.B=0|IV[1],this.C=0|IV[2],this.D=0|IV[3],this.E=0|IV[4],this.F=0|IV[5],this.G=0|IV[6],this.H=0|IV[7]}get(){const{A:s,B:r,C:i,D:a,E:c,F:y,G:w,H:C}=this;return[s,r,i,a,c,y,w,C]}set(s,r,i,a,c,y,w,C){this.A=0|s,this.B=0|r,this.C=0|i,this.D=0|a,this.E=0|c,this.F=0|y,this.G=0|w,this.H=0|C}process(s,r){for(let M=0;M<16;M++,r+=4)SHA256_W[M]=s.getUint32(r,!1);for(let M=16;M<64;M++){const O=SHA256_W[M-15],L=SHA256_W[M-2],Z=rotr(O,7)^rotr(O,18)^O>>>3,q=rotr(L,17)^rotr(L,19)^L>>>10;SHA256_W[M]=q+SHA256_W[M-7]+Z+SHA256_W[M-16]|0}let{A:i,B:a,C:c,D:y,E:w,F:C,G:T,H:S}=this;for(let M=0;M<64;M++){const O=S+(rotr(w,6)^rotr(w,11)^rotr(w,25))+Chi(w,C,T)+SHA256_K[M]+SHA256_W[M]|0,L=(rotr(i,2)^rotr(i,13)^rotr(i,22))+Maj(i,a,c)|0;S=T,T=C,C=w,w=y+O|0,y=c,c=a,a=i,i=O+L|0}i=i+this.A|0,a=a+this.B|0,c=c+this.C|0,y=y+this.D|0,w=w+this.E|0,C=C+this.F|0,T=T+this.G|0,S=S+this.H|0,this.set(i,a,c,y,w,C,T,S)}roundClean(){SHA256_W.fill(0)}destroy(){this.set(0,0,0,0,0,0,0,0),this.buffer.fill(0)}}const sha256=wrapConstructor(()=>new SHA256),U32_MASK64=BigInt(2**32-1),_32n=BigInt(32);function fromBig(o,s=!1){return s?{h:Number(o&U32_MASK64),l:Number(o>>_32n&U32_MASK64)}:{h:0|Number(o>>_32n&U32_MASK64),l:0|Number(o&U32_MASK64)}}function split(o,s=!1){let r=new Uint32Array(o.length),i=new Uint32Array(o.length);for(let a=0;aBigInt(o>>>0)<<_32n|BigInt(s>>>0),shrSH=(o,s,r)=>o>>>r,shrSL=(o,s,r)=>o<<32-r|s>>>r,rotrSH=(o,s,r)=>o>>>r|s<<32-r,rotrSL=(o,s,r)=>o<<32-r|s>>>r,rotrBH=(o,s,r)=>o<<64-r|s>>>r-32,rotrBL=(o,s,r)=>o>>>r-32|s<<64-r,rotr32H=(o,s)=>s,rotr32L=(o,s)=>o,rotlSH=(o,s,r)=>o<>>32-r,rotlSL=(o,s,r)=>s<>>32-r,rotlBH=(o,s,r)=>s<>>64-r,rotlBL=(o,s,r)=>o<>>64-r;function add(o,s,r,i){const a=(s>>>0)+(i>>>0);return{h:o+r+(a/2**32|0)|0,l:0|a}}const add3L=(o,s,r)=>(o>>>0)+(s>>>0)+(r>>>0),add3H=(o,s,r,i)=>s+r+i+(o/2**32|0)|0,add4L=(o,s,r,i)=>(o>>>0)+(s>>>0)+(r>>>0)+(i>>>0),add4H=(o,s,r,i,a)=>s+r+i+a+(o/2**32|0)|0,add5L=(o,s,r,i,a)=>(o>>>0)+(s>>>0)+(r>>>0)+(i>>>0)+(a>>>0),add5H=(o,s,r,i,a,c)=>s+r+i+a+c+(o/2**32|0)|0,u64={fromBig,split,toBig,shrSH,shrSL,rotrSH,rotrSL,rotrBH,rotrBL,rotr32H,rotr32L,rotlSH,rotlSL,rotlBH,rotlBL,add,add3L,add3H,add4L,add4H,add5H,add5L},[SHA512_Kh,SHA512_Kl]=u64.split(["0x428a2f98d728ae22","0x7137449123ef65cd","0xb5c0fbcfec4d3b2f","0xe9b5dba58189dbbc","0x3956c25bf348b538","0x59f111f1b605d019","0x923f82a4af194f9b","0xab1c5ed5da6d8118","0xd807aa98a3030242","0x12835b0145706fbe","0x243185be4ee4b28c","0x550c7dc3d5ffb4e2","0x72be5d74f27b896f","0x80deb1fe3b1696b1","0x9bdc06a725c71235","0xc19bf174cf692694","0xe49b69c19ef14ad2","0xefbe4786384f25e3","0x0fc19dc68b8cd5b5","0x240ca1cc77ac9c65","0x2de92c6f592b0275","0x4a7484aa6ea6e483","0x5cb0a9dcbd41fbd4","0x76f988da831153b5","0x983e5152ee66dfab","0xa831c66d2db43210","0xb00327c898fb213f","0xbf597fc7beef0ee4","0xc6e00bf33da88fc2","0xd5a79147930aa725","0x06ca6351e003826f","0x142929670a0e6e70","0x27b70a8546d22ffc","0x2e1b21385c26c926","0x4d2c6dfc5ac42aed","0x53380d139d95b3df","0x650a73548baf63de","0x766a0abb3c77b2a8","0x81c2c92e47edaee6","0x92722c851482353b","0xa2bfe8a14cf10364","0xa81a664bbc423001","0xc24b8b70d0f89791","0xc76c51a30654be30","0xd192e819d6ef5218","0xd69906245565a910","0xf40e35855771202a","0x106aa07032bbd1b8","0x19a4c116b8d2d0c8","0x1e376c085141ab53","0x2748774cdf8eeb99","0x34b0bcb5e19b48a8","0x391c0cb3c5c95a63","0x4ed8aa4ae3418acb","0x5b9cca4f7763e373","0x682e6ff3d6b2b8a3","0x748f82ee5defb2fc","0x78a5636f43172f60","0x84c87814a1f0ab72","0x8cc702081a6439ec","0x90befffa23631e28","0xa4506cebde82bde9","0xbef9a3f7b2c67915","0xc67178f2e372532b","0xca273eceea26619c","0xd186b8c721c0c207","0xeada7dd6cde0eb1e","0xf57d4f7fee6ed178","0x06f067aa72176fba","0x0a637dc5a2c898a6","0x113f9804bef90dae","0x1b710b35131c471b","0x28db77f523047d84","0x32caab7b40c72493","0x3c9ebe0a15c9bebc","0x431d67c49c100d4c","0x4cc5d4becb3e42b6","0x597f299cfc657e2a","0x5fcb6fab3ad6faec","0x6c44198c4a475817"].map(o=>BigInt(o))),SHA512_W_H=new Uint32Array(80),SHA512_W_L=new Uint32Array(80);class SHA512 extends SHA2{constructor(){super(128,64,16,!1),this.Ah=1779033703,this.Al=-205731576,this.Bh=-1150833019,this.Bl=-2067093701,this.Ch=1013904242,this.Cl=-23791573,this.Dh=-1521486534,this.Dl=1595750129,this.Eh=1359893119,this.El=-1377402159,this.Fh=-1694144372,this.Fl=725511199,this.Gh=528734635,this.Gl=-79577749,this.Hh=1541459225,this.Hl=327033209}get(){const{Ah:s,Al:r,Bh:i,Bl:a,Ch:c,Cl:y,Dh:w,Dl:C,Eh:T,El:S,Fh:M,Fl:O,Gh:L,Gl:Z,Hh:q,Hl:re}=this;return[s,r,i,a,c,y,w,C,T,S,M,O,L,Z,q,re]}set(s,r,i,a,c,y,w,C,T,S,M,O,L,Z,q,re){this.Ah=0|s,this.Al=0|r,this.Bh=0|i,this.Bl=0|a,this.Ch=0|c,this.Cl=0|y,this.Dh=0|w,this.Dl=0|C,this.Eh=0|T,this.El=0|S,this.Fh=0|M,this.Fl=0|O,this.Gh=0|L,this.Gl=0|Z,this.Hh=0|q,this.Hl=0|re}process(s,r){for(let ae=0;ae<16;ae++,r+=4)SHA512_W_H[ae]=s.getUint32(r),SHA512_W_L[ae]=s.getUint32(r+=4);for(let ae=16;ae<80;ae++){const me=0|SHA512_W_H[ae-15],be=0|SHA512_W_L[ae-15],Oe=u64.rotrSH(me,be,1)^u64.rotrSH(me,be,8)^u64.shrSH(me,be,7),xe=u64.rotrSL(me,be,1)^u64.rotrSL(me,be,8)^u64.shrSL(me,be,7),De=0|SHA512_W_H[ae-2],ce=0|SHA512_W_L[ae-2],ue=u64.rotrSH(De,ce,19)^u64.rotrBH(De,ce,61)^u64.shrSH(De,ce,6),Ce=u64.rotrSL(De,ce,19)^u64.rotrBL(De,ce,61)^u64.shrSL(De,ce,6),Be=u64.add4L(xe,Ce,SHA512_W_L[ae-7],SHA512_W_L[ae-16]),at=u64.add4H(Be,Oe,ue,SHA512_W_H[ae-7],SHA512_W_H[ae-16]);SHA512_W_H[ae]=0|at,SHA512_W_L[ae]=0|Be}let{Ah:i,Al:a,Bh:c,Bl:y,Ch:w,Cl:C,Dh:T,Dl:S,Eh:M,El:O,Fh:L,Fl:Z,Gh:q,Gl:re,Hh:pe,Hl:se}=this;for(let ae=0;ae<80;ae++){const me=u64.rotrSH(M,O,14)^u64.rotrSH(M,O,18)^u64.rotrBH(M,O,41),be=u64.rotrSL(M,O,14)^u64.rotrSL(M,O,18)^u64.rotrBL(M,O,41),Oe=M&L^~M&q,De=u64.add5L(se,be,O&Z^~O&re,SHA512_Kl[ae],SHA512_W_L[ae]),ce=u64.add5H(De,pe,me,Oe,SHA512_Kh[ae],SHA512_W_H[ae]),ue=0|De,Ce=u64.rotrSH(i,a,28)^u64.rotrBH(i,a,34)^u64.rotrBH(i,a,39),Be=u64.rotrSL(i,a,28)^u64.rotrBL(i,a,34)^u64.rotrBL(i,a,39),at=i&c^i&w^c&w,dt=a&y^a&C^y&C;pe=0|q,se=0|re,q=0|L,re=0|Z,L=0|M,Z=0|O,({h:M,l:O}=u64.add(0|T,0|S,0|ce,0|ue)),T=0|w,S=0|C,w=0|c,C=0|y,c=0|i,y=0|a;const bt=u64.add3L(ue,Be,dt);i=u64.add3H(bt,ce,Ce,at),a=0|bt}({h:i,l:a}=u64.add(0|this.Ah,0|this.Al,0|i,0|a)),({h:c,l:y}=u64.add(0|this.Bh,0|this.Bl,0|c,0|y)),({h:w,l:C}=u64.add(0|this.Ch,0|this.Cl,0|w,0|C)),({h:T,l:S}=u64.add(0|this.Dh,0|this.Dl,0|T,0|S)),({h:M,l:O}=u64.add(0|this.Eh,0|this.El,0|M,0|O)),({h:L,l:Z}=u64.add(0|this.Fh,0|this.Fl,0|L,0|Z)),({h:q,l:re}=u64.add(0|this.Gh,0|this.Gl,0|q,0|re)),({h:pe,l:se}=u64.add(0|this.Hh,0|this.Hl,0|pe,0|se)),this.set(i,a,c,y,w,C,T,S,M,O,L,Z,q,re,pe,se)}roundClean(){SHA512_W_H.fill(0),SHA512_W_L.fill(0)}destroy(){this.buffer.fill(0),this.set(0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0)}}const sha512=wrapConstructor(()=>new SHA512);function isBytes(o){return o instanceof Uint8Array||null!=o&&"object"==typeof o&&"Uint8Array"===o.constructor.name}function chain(...o){const s=i=>i,r=(i,a)=>c=>i(a(c));return{encode:o.map(i=>i.encode).reduceRight(r,s),decode:o.map(i=>i.decode).reduce(r,s)}}function alphabet(o){return{encode:s=>{if(!Array.isArray(s)||s.length&&"number"!=typeof s[0])throw new Error("alphabet.encode input should be an array of numbers");return s.map(r=>{if(r<0||r>=o.length)throw new Error(`Digit index outside alphabet: ${r} (alphabet: ${o.length})`);return o[r]})},decode:s=>{if(!Array.isArray(s)||s.length&&"string"!=typeof s[0])throw new Error("alphabet.decode input should be array of strings");return s.map(r=>{if("string"!=typeof r)throw new Error(`alphabet.decode: not string element=${r}`);const i=o.indexOf(r);if(-1===i)throw new Error(`Unknown letter: "${r}". Allowed: ${o}`);return i})}}}function join(o=""){if("string"!=typeof o)throw new Error("join separator should be string");return{encode:s=>{if(!Array.isArray(s)||s.length&&"string"!=typeof s[0])throw new Error("join.encode input should be array of strings");for(let r of s)if("string"!=typeof r)throw new Error(`join.encode: non-string input=${r}`);return s.join(o)},decode:s=>{if("string"!=typeof s)throw new Error("join.decode input should be string");return s.split(o)}}}function padding(o,s="="){if("string"!=typeof s)throw new Error("padding chr should be string");return{encode(r){if(!Array.isArray(r)||r.length&&"string"!=typeof r[0])throw new Error("padding.encode input should be array of strings");for(let i of r)if("string"!=typeof i)throw new Error(`padding.encode: non-string input=${i}`);for(;r.length*o%8;)r.push(s);return r},decode(r){if(!Array.isArray(r)||r.length&&"string"!=typeof r[0])throw new Error("padding.encode input should be array of strings");for(let a of r)if("string"!=typeof a)throw new Error(`padding.decode: non-string input=${a}`);let i=r.length;if(i*o%8)throw new Error("Invalid padding: string should have whole number of bytes");for(;i>0&&r[i-1]===s;i--)if(!((i-1)*o%8))throw new Error("Invalid padding: string has too much padding");return r.slice(0,i)}}}function convertRadix(o,s,r){if(s<2)throw new Error(`convertRadix: wrong from=${s}, base cannot be less than 2`);if(r<2)throw new Error(`convertRadix: wrong to=${r}, base cannot be less than 2`);if(!Array.isArray(o))throw new Error("convertRadix: data should be array");if(!o.length)return[];let i=0;const a=[],c=Array.from(o);for(c.forEach(y=>{if(y<0||y>=s)throw new Error(`Wrong integer: ${y}`)});;){let y=0,w=!0;for(let C=i;Cs?gcd(s,o%s):o,radix2carry=(o,s)=>o+(s-gcd(o,s));function convertRadix2(o,s,r,i){if(!Array.isArray(o))throw new Error("convertRadix2: data should be array");if(s<=0||s>32)throw new Error(`convertRadix2: wrong from=${s}`);if(r<=0||r>32)throw new Error(`convertRadix2: wrong to=${r}`);if(radix2carry(s,r)>32)throw new Error(`convertRadix2: carry overflow from=${s} to=${r} carryBits=${radix2carry(s,r)}`);let a=0,c=0;const y=2**r-1,w=[];for(const C of o){if(C>=2**s)throw new Error(`convertRadix2: invalid data word=${C} from=${s}`);if(a=a<32)throw new Error(`convertRadix2: carry overflow pos=${c} from=${s}`);for(c+=s;c>=r;c-=r)w.push((a>>c-r&y)>>>0);a&=2**c-1}if(a=a<=s)throw new Error("Excess padding");if(!i&&a)throw new Error(`Non-zero padding: ${a}`);return i&&c>0&&w.push(a>>>0),w}function radix(o){return{encode:s=>{if(!isBytes(s))throw new Error("radix.encode input should be Uint8Array");return convertRadix(Array.from(s),256,o)},decode:s=>{if(!Array.isArray(s)||s.length&&"number"!=typeof s[0])throw new Error("radix.decode input should be array of numbers");return Uint8Array.from(convertRadix(s,o,256))}}}function radix2(o,s=!1){if(o<=0||o>32)throw new Error("radix2: bits should be in (0..32]");if(radix2carry(8,o)>32||radix2carry(o,8)>32)throw new Error("radix2: carry overflow");return{encode:r=>{if(!isBytes(r))throw new Error("radix2.encode input should be Uint8Array");return convertRadix2(Array.from(r),8,o,!s)},decode:r=>{if(!Array.isArray(r)||r.length&&"number"!=typeof r[0])throw new Error("radix2.decode input should be array of numbers");return Uint8Array.from(convertRadix2(r,o,8,s))}}}function unsafeWrapper(o){if("function"!=typeof o)throw new Error("unsafeWrapper fn should be function");return function(...s){try{return o.apply(null,s)}catch{}}}function checksum(o,s){if("function"!=typeof s)throw new Error("checksum fn should be function");return{encode(r){if(!isBytes(r))throw new Error("checksum.encode: input should be Uint8Array");const i=s(r).slice(0,o),a=new Uint8Array(r.length+o);return a.set(r),a.set(i,r.length),a},decode(r){if(!isBytes(r))throw new Error("checksum.decode: input should be Uint8Array");const i=r.slice(0,-o),a=s(i).slice(0,o),c=r.slice(-o);for(let y=0;ychain(radix(58),alphabet(o),join("")),base58=genBase58("123456789ABCDEFGHJKLMNPQRSTUVWXYZabcdefghijkmnopqrstuvwxyz"),createBase58check=o=>chain(checksum(4,s=>o(o(s))),base58),base58check$1=createBase58check,BECH_ALPHABET=chain(alphabet("qpzry9x8gf2tvdw0s3jn54khce6mua7l"),join("")),POLYMOD_GENERATORS=[996825010,642813549,513874426,1027748829,705979059];function bech32Polymod(o){const s=o>>25;let r=(33554431&o)<<5;for(let i=0;i>i&1)&&(r^=POLYMOD_GENERATORS[i]);return r}function bechChecksum(o,s,r=1){const i=o.length;let a=1;for(let c=0;c126)throw new Error(`Invalid prefix (${o})`);a=bech32Polymod(a)^y>>5}a=bech32Polymod(a);for(let c=0;cC)throw new TypeError(`Wrong string length: ${w.length} (${w}). Expected (8..${C})`);const T=w.toLowerCase();if(w!==T&&w!==w.toUpperCase())throw new Error("String must be lowercase or uppercase");const S=(w=T).lastIndexOf("1");if(0===S||-1===S)throw new Error('Letter "1" must be present between prefix and data only');const M=w.slice(0,S),O=w.slice(S+1);if(O.length<6)throw new Error("Data must be at least 6 characters long");const L=BECH_ALPHABET.decode(O).slice(0,-6),Z=bechChecksum(M,L,s);if(!O.endsWith(Z))throw new Error(`Invalid checksum in ${w}: expected "${Z}"`);return{prefix:M,words:L}}return{encode:function(w,C,T=90){if("string"!=typeof w)throw new Error("bech32.encode prefix should be string, not "+typeof w);if(!Array.isArray(C)||C.length&&"number"!=typeof C[0])throw new Error("bech32.encode words should be array of numbers, not "+typeof C);const S=w.length+7+C.length;if(!1!==T&&S>T)throw new TypeError(`Length ${S} exceeds limit ${T}`);const M=w.toLowerCase(),O=bechChecksum(M,C,s);return`${M}1${BECH_ALPHABET.encode(C)}${O}`},decode:y,decodeToBytes:function(w){const{prefix:C,words:T}=y(w,!1);return{prefix:C,words:T,bytes:i(T)}},decodeUnsafe:unsafeWrapper(y),fromWords:i,fromWordsUnsafe:c,toWords:a}}const bech32=genBech32("bech32"),isJapanese=o=>"\u3042\u3044\u3053\u304f\u3057\u3093"===o[0];function nfkd(o){if("string"!=typeof o)throw new TypeError("Invalid mnemonic type: "+typeof o);return o.normalize("NFKD")}function normalize(o){const s=nfkd(o),r=s.split(" ");if(![12,15,18,21,24].includes(r.length))throw new Error("Invalid mnemonic");return{nfkd:s,words:r}}function assertEntropy(o){assert$1.bytes(o,16,20,24,28,32)}function generateMnemonic(o,s=128){if(assert$1.number(s),s%32!=0||s>256)throw new TypeError("Invalid entropy");return entropyToMnemonic(randomBytes(s/8),o)}const calcChecksum=o=>{const s=8-o.length/4;return new Uint8Array([sha256(o)[0]>>s<{if("string"!=typeof s)throw new Error(`Wordlist: non-string element: ${s}`)}),utils$1.chain(utils$1.checksum(1,calcChecksum),utils$1.radix2(11,!0),utils$1.alphabet(o))}function mnemonicToEntropy(o,s){const{words:r}=normalize(o),i=getCoder(s).decode(r);return assertEntropy(i),i}function entropyToMnemonic(o,s){return assertEntropy(o),getCoder(s).encode(o).join(isJapanese(s)?"\u3000":" ")}function validateMnemonic(o,s){try{mnemonicToEntropy(o,s)}catch{return!1}return!0}const salt=o=>nfkd(`mnemonic${o}`);function mnemonicToSeedSync(o,s=""){return pbkdf2(sha512,normalize(o).nfkd,salt(s),{c:2048,dkLen:64})}const Rho=new Uint8Array([7,4,13,1,10,6,15,3,12,0,9,5,2,14,11,8]),Id=Uint8Array.from({length:16},(o,s)=>s),Pi=Id.map(o=>(9*o+5)%16);let idxL=[Id],idxR=[Pi];for(let o=0;o<4;o++)for(let s of[idxL,idxR])s.push(s[o].map(r=>Rho[r]));const shifts=[[11,14,15,12,5,8,7,9,11,13,14,15,6,7,9,8],[12,13,11,15,6,9,9,7,12,15,11,13,7,8,7,7],[13,15,14,11,7,7,6,8,13,14,13,12,5,5,6,9],[14,11,12,14,8,6,5,5,15,12,15,14,9,9,8,6],[15,12,13,13,9,5,8,6,14,11,12,11,8,6,5,5]].map(o=>new Uint8Array(o)),shiftsL=idxL.map((o,s)=>o.map(r=>shifts[s][r])),shiftsR=idxR.map((o,s)=>o.map(r=>shifts[s][r])),Kl=new Uint32Array([0,1518500249,1859775393,2400959708,2840853838]),Kr=new Uint32Array([1352829926,1548603684,1836072691,2053994217,0]),rotl$1=(o,s)=>o<>>32-s;function f(o,s,r,i){return 0===o?s^r^i:1===o?s&r|~s&i:2===o?(s|~r)^i:3===o?s&i|r&~i:s^(r|~i)}const BUF=new Uint32Array(16);class RIPEMD160 extends SHA2{constructor(){super(64,20,8,!0),this.h0=1732584193,this.h1=-271733879,this.h2=-1732584194,this.h3=271733878,this.h4=-1009589776}get(){const{h0:s,h1:r,h2:i,h3:a,h4:c}=this;return[s,r,i,a,c]}set(s,r,i,a,c){this.h0=0|s,this.h1=0|r,this.h2=0|i,this.h3=0|a,this.h4=0|c}process(s,r){for(let L=0;L<16;L++,r+=4)BUF[L]=s.getUint32(r,!0);let i=0|this.h0,a=i,c=0|this.h1,y=c,w=0|this.h2,C=w,T=0|this.h3,S=T,M=0|this.h4,O=M;for(let L=0;L<5;L++){const Z=4-L,q=Kl[L],re=Kr[L],pe=idxL[L],se=idxR[L],ae=shiftsL[L],me=shiftsR[L];for(let be=0;be<16;be++){const Oe=rotl$1(i+f(L,c,w,T)+BUF[pe[be]]+q,ae[be])+M|0;i=M,M=T,T=0|rotl$1(w,10),w=c,c=Oe}for(let be=0;be<16;be++){const Oe=rotl$1(a+f(Z,y,C,S)+BUF[se[be]]+re,me[be])+O|0;a=O,O=S,S=0|rotl$1(C,10),C=y,y=Oe}}this.set(this.h1+w+S|0,this.h2+T+O|0,this.h3+M+a|0,this.h4+i+y|0,this.h0+c+C|0)}roundClean(){BUF.fill(0)}destroy(){this.destroyed=!0,this.buffer.fill(0),this.set(0,0,0,0,0)}}const ripemd160=wrapConstructor(()=>new RIPEMD160),Point=secp256k1.ProjectivePoint,base58check=base58check$1(sha256);function bytesToNumber(o){return BigInt(`0x${bytesToHex(o)}`)}function numberToBytes(o){return hexToBytes(o.toString(16).padStart(64,"0"))}const MASTER_SECRET=utf8ToBytes$1("Bitcoin seed"),BITCOIN_VERSIONS={private:76066276,public:76067358},HARDENED_OFFSET=2147483648,hash160=o=>ripemd160(sha256(o)),fromU32=o=>createView(o).getUint32(0,!1),toU32=o=>{if(!Number.isSafeInteger(o)||o<0||o>2**32-1)throw new Error(`Invalid number=${o}. Should be from 0 to 2 ** 32 - 1`);const s=new Uint8Array(4);return createView(s).setUint32(0,o,!1),s};class HDKey{get fingerprint(){if(!this.pubHash)throw new Error("No publicKey set!");return fromU32(this.pubHash)}get identifier(){return this.pubHash}get pubKeyHash(){return this.pubHash}get privateKey(){return this.privKeyBytes||null}get publicKey(){return this.pubKey||null}get privateExtendedKey(){const s=this.privateKey;if(!s)throw new Error("No private key");return base58check.encode(this.serialize(this.versions.private,concatBytes(new Uint8Array([0]),s)))}get publicExtendedKey(){if(!this.pubKey)throw new Error("No public key");return base58check.encode(this.serialize(this.versions.public,this.pubKey))}static fromMasterSeed(s,r=BITCOIN_VERSIONS){if(bytes$1(s),8*s.length<128||8*s.length>512)throw new Error(`HDKey: wrong seed length=${s.length}. Should be between 128 and 512 bits; 256 bits is advised)`);const i=hmac$1(sha512,MASTER_SECRET,s);return new HDKey({versions:r,chainCode:i.slice(32),privateKey:i.slice(0,32)})}static fromExtendedKey(s,r=BITCOIN_VERSIONS){const i=base58check.decode(s),a=createView(i),c=a.getUint32(0,!1),y={versions:r,depth:i[4],parentFingerprint:a.getUint32(5,!1),index:a.getUint32(9,!1),chainCode:i.slice(13,45)},w=i.slice(45),C=0===w[0];if(c!==r[C?"private":"public"])throw new Error("Version mismatch");return new HDKey(C?{...y,privateKey:w.slice(1)}:{...y,publicKey:w})}static fromJSON(s){return HDKey.fromExtendedKey(s.xpriv)}constructor(s){if(this.depth=0,this.index=0,this.chainCode=null,this.parentFingerprint=0,!s||"object"!=typeof s)throw new Error("HDKey.constructor must not be called directly");if(this.versions=s.versions||BITCOIN_VERSIONS,this.depth=s.depth||0,this.chainCode=s.chainCode,this.index=s.index||0,this.parentFingerprint=s.parentFingerprint||0,!this.depth&&(this.parentFingerprint||this.index))throw new Error("HDKey: zero depth with non-zero index/parent fingerprint");if(s.publicKey&&s.privateKey)throw new Error("HDKey: publicKey and privateKey at same time.");if(s.privateKey){if(!secp256k1.utils.isValidPrivateKey(s.privateKey))throw new Error("Invalid private key");this.privKey="bigint"==typeof s.privateKey?s.privateKey:bytesToNumber(s.privateKey),this.privKeyBytes=numberToBytes(this.privKey),this.pubKey=secp256k1.getPublicKey(s.privateKey,!0)}else{if(!s.publicKey)throw new Error("HDKey: no public or private key provided");this.pubKey=Point.fromHex(s.publicKey).toRawBytes(!0)}this.pubHash=hash160(this.pubKey)}derive(s){if(!/^[mM]'?/.test(s))throw new Error('Path must start with "m" or "M"');if(/^[mM]'?$/.test(s))return this;const r=s.replace(/^[mM]'?\//,"").split("/");let i=this;for(const a of r){const c=/^(\d+)('?)$/.exec(a);if(!c||3!==c.length)throw new Error(`Invalid child index: ${a}`);let y=+c[1];if(!Number.isSafeInteger(y)||y>=HARDENED_OFFSET)throw new Error("Invalid index");"'"===c[2]&&(y+=HARDENED_OFFSET),i=i.deriveChild(y)}return i}deriveChild(s){if(!this.pubKey||!this.chainCode)throw new Error("No publicKey or chainCode set");let r=toU32(s);if(s>=HARDENED_OFFSET){const w=this.privateKey;if(!w)throw new Error("Could not derive hardened child key");r=concatBytes(new Uint8Array([0]),w,r)}else r=concatBytes(this.pubKey,r);const i=hmac$1(sha512,this.chainCode,r),a=bytesToNumber(i.slice(0,32)),c=i.slice(32);if(!secp256k1.utils.isValidPrivateKey(a))throw new Error("Tweak bigger than curve order");const y={versions:this.versions,chainCode:c,depth:this.depth+1,parentFingerprint:this.fingerprint,index:s};try{if(this.privateKey){const w=mod(this.privKey+a,secp256k1.CURVE.n);if(!secp256k1.utils.isValidPrivateKey(w))throw new Error("The tweak was out of range or the resulted private key is invalid");y.privateKey=w}else{const w=Point.fromHex(this.pubKey).add(Point.fromPrivateKey(a));if(w.equals(Point.ZERO))throw new Error("The tweak was equal to negative P, which made the result key invalid");y.publicKey=w.toRawBytes(!0)}return new HDKey(y)}catch{return this.deriveChild(s+1)}}sign(s){if(!this.privateKey)throw new Error("No privateKey set!");return bytes$1(s,32),secp256k1.sign(s,this.privKey).toCompactRawBytes()}verify(s,r){if(bytes$1(s,32),bytes$1(r,64),!this.publicKey)throw new Error("No publicKey set!");let i;try{i=secp256k1.Signature.fromCompact(r)}catch{return!1}return secp256k1.verify(i,s,this.publicKey)}wipePrivateData(){return this.privKey=void 0,this.privKeyBytes&&(this.privKeyBytes.fill(0),this.privKeyBytes=void 0),this}toJSON(){return{xpriv:this.privateExtendedKey,xpub:this.publicExtendedKey}}serialize(s,r){if(!this.chainCode)throw new Error("No chainCode set");return bytes$1(r,33),concatBytes(toU32(s),new Uint8Array([this.depth]),toU32(this.parentFingerprint),toU32(this.index),this.chainCode,r)}}const u8a=o=>o instanceof Uint8Array,u32=o=>new Uint32Array(o.buffer,o.byteOffset,Math.floor(o.byteLength/4)),isLE=68===new Uint8Array(new Uint32Array([287454020]).buffer)[0];if(!isLE)throw new Error("Non little-endian hardware is not supported");function utf8ToBytes(o){if("string"!=typeof o)throw new Error("utf8ToBytes expected string, got "+typeof o);return new Uint8Array((new TextEncoder).encode(o))}function toBytes(o){if("string"==typeof o&&(o=utf8ToBytes(o)),!u8a(o))throw new Error("expected Uint8Array, got "+typeof o);return o}const isPlainObject=o=>"[object Object]"===Object.prototype.toString.call(o)&&o.constructor===Object;function checkOpts(o,s){if(void 0!==s&&("object"!=typeof s||!isPlainObject(s)))throw new Error("options must be object or undefined");return Object.assign(o,s)}function ensureBytes(o,s){if(!(o instanceof Uint8Array))throw new Error("Uint8Array expected");if("number"==typeof s&&o.length!==s)throw new Error(`Uint8Array length ${s} expected`)}function equalBytes(o,s){if(o.length!==s.length)throw new Error("equalBytes: Different size of Uint8Arrays");let r=!0;for(let i=0;i0&&!s.includes(o.length))throw new Error(`Expected Uint8Array of length ${s}, not of length=${o.length}`)}function hash(o){if("function"!=typeof o||"function"!=typeof o.create)throw new Error("hash must be wrapped by utils.wrapConstructor");number(o.outputLen),number(o.blockLen)}function exists(o,s=!0){if(o.destroyed)throw new Error("Hash instance has been destroyed");if(s&&o.finished)throw new Error("Hash#digest() has already been called")}function output(o,s){bytes(o);const r=s.outputLen;if(o.length255&o[s++]|(255&o[s++])<<8;class Poly1305{constructor(s){this.blockLen=16,this.outputLen=16,this.buffer=new Uint8Array(16),this.r=new Uint16Array(10),this.h=new Uint16Array(10),this.pad=new Uint16Array(8),this.pos=0,this.finished=!1,ensureBytes(s=toBytes(s),32);const r=u8to16(s,0),i=u8to16(s,2),a=u8to16(s,4),c=u8to16(s,6),y=u8to16(s,8),w=u8to16(s,10),C=u8to16(s,12),T=u8to16(s,14);this.r[0]=8191&r,this.r[1]=8191&(r>>>13|i<<3),this.r[2]=7939&(i>>>10|a<<6),this.r[3]=8191&(a>>>7|c<<9),this.r[4]=255&(c>>>4|y<<12),this.r[5]=y>>>1&8190,this.r[6]=8191&(y>>>14|w<<2),this.r[7]=8065&(w>>>11|C<<5),this.r[8]=8191&(C>>>8|T<<8),this.r[9]=T>>>5&127;for(let S=0;S<8;S++)this.pad[S]=u8to16(s,16+2*S)}process(s,r,i=!1){const a=i?0:2048,{h:c,r:y}=this,w=y[0],C=y[1],T=y[2],S=y[3],M=y[4],O=y[5],L=y[6],Z=y[7],q=y[8],re=y[9],pe=u8to16(s,r+0),se=u8to16(s,r+2),ae=u8to16(s,r+4),me=u8to16(s,r+6),be=u8to16(s,r+8),Oe=u8to16(s,r+10),xe=u8to16(s,r+12),De=u8to16(s,r+14);let ce=c[0]+(8191&pe),ue=c[1]+(8191&(pe>>>13|se<<3)),Ce=c[2]+(8191&(se>>>10|ae<<6)),Be=c[3]+(8191&(ae>>>7|me<<9)),at=c[4]+(8191&(me>>>4|be<<12)),dt=c[5]+(be>>>1&8191),bt=c[6]+(8191&(be>>>14|Oe<<2)),lt=c[7]+(8191&(Oe>>>11|xe<<5)),rn=c[8]+(8191&(xe>>>8|De<<8)),gn=c[9]+(De>>>5|a),bn=0,Vn=bn+ce*w+ue*(5*re)+Ce*(5*q)+Be*(5*Z)+at*(5*L);bn=Vn>>>13,Vn&=8191,Vn+=dt*(5*O)+bt*(5*M)+lt*(5*S)+rn*(5*T)+gn*(5*C),bn+=Vn>>>13,Vn&=8191;let yn=bn+ce*C+ue*w+Ce*(5*re)+Be*(5*q)+at*(5*Z);bn=yn>>>13,yn&=8191,yn+=dt*(5*L)+bt*(5*O)+lt*(5*M)+rn*(5*S)+gn*(5*T),bn+=yn>>>13,yn&=8191;let qe=bn+ce*T+ue*C+Ce*w+Be*(5*re)+at*(5*q);bn=qe>>>13,qe&=8191,qe+=dt*(5*Z)+bt*(5*L)+lt*(5*O)+rn*(5*M)+gn*(5*S),bn+=qe>>>13,qe&=8191;let _t=bn+ce*S+ue*T+Ce*C+Be*w+at*(5*re);bn=_t>>>13,_t&=8191,_t+=dt*(5*q)+bt*(5*Z)+lt*(5*L)+rn*(5*O)+gn*(5*M),bn+=_t>>>13,_t&=8191;let ze=bn+ce*M+ue*S+Ce*T+Be*C+at*w;bn=ze>>>13,ze&=8191,ze+=dt*(5*re)+bt*(5*q)+lt*(5*Z)+rn*(5*L)+gn*(5*O),bn+=ze>>>13,ze&=8191;let $e=bn+ce*O+ue*M+Ce*S+Be*T+at*C;bn=$e>>>13,$e&=8191,$e+=dt*w+bt*(5*re)+lt*(5*q)+rn*(5*Z)+gn*(5*L),bn+=$e>>>13,$e&=8191;let Ft=bn+ce*L+ue*O+Ce*M+Be*S+at*T;bn=Ft>>>13,Ft&=8191,Ft+=dt*C+bt*w+lt*(5*re)+rn*(5*q)+gn*(5*Z),bn+=Ft>>>13,Ft&=8191;let Ke=bn+ce*Z+ue*L+Ce*O+Be*M+at*S;bn=Ke>>>13,Ke&=8191,Ke+=dt*T+bt*C+lt*w+rn*(5*re)+gn*(5*q),bn+=Ke>>>13,Ke&=8191;let Ze=bn+ce*q+ue*Z+Ce*L+Be*O+at*M;bn=Ze>>>13,Ze&=8191,Ze+=dt*S+bt*T+lt*C+rn*w+gn*(5*re),bn+=Ze>>>13,Ze&=8191;let it=bn+ce*re+ue*q+Ce*Z+Be*L+at*O;bn=it>>>13,it&=8191,it+=dt*M+bt*S+lt*T+rn*C+gn*w,bn+=it>>>13,it&=8191,bn=(bn<<2)+bn|0,bn=bn+Vn|0,Vn=8191&bn,bn>>>=13,yn+=bn,c[0]=Vn,c[1]=yn,c[2]=qe,c[3]=_t,c[4]=ze,c[5]=$e,c[6]=Ft,c[7]=Ke,c[8]=Ze,c[9]=it}finalize(){const{h:s,pad:r}=this,i=new Uint16Array(10);let a=s[1]>>>13;s[1]&=8191;for(let w=2;w<10;w++)s[w]+=a,a=s[w]>>>13,s[w]&=8191;s[0]+=5*a,a=s[0]>>>13,s[0]&=8191,s[1]+=a,a=s[1]>>>13,s[1]&=8191,s[2]+=a,i[0]=s[0]+5,a=i[0]>>>13,i[0]&=8191;for(let w=1;w<10;w++)i[w]=s[w]+a,a=i[w]>>>13,i[w]&=8191;i[9]-=8192;let c=(1^a)-1;for(let w=0;w<10;w++)i[w]&=c;c=~c;for(let w=0;w<10;w++)s[w]=s[w]&c|i[w];s[0]=65535&(s[0]|s[1]<<13),s[1]=65535&(s[1]>>>3|s[2]<<10),s[2]=65535&(s[2]>>>6|s[3]<<7),s[3]=65535&(s[3]>>>9|s[4]<<4),s[4]=65535&(s[4]>>>12|s[5]<<1|s[6]<<14),s[5]=65535&(s[6]>>>2|s[7]<<11),s[6]=65535&(s[7]>>>5|s[8]<<8),s[7]=65535&(s[8]>>>8|s[9]<<5);let y=s[0]+r[0];s[0]=65535&y;for(let w=1;w<8;w++)y=(s[w]+r[w]|0)+(y>>>16)|0,s[w]=65535&y}update(s){assert.exists(this);const{buffer:r,blockLen:i}=this,a=(s=toBytes(s)).length;for(let c=0;c>>0,s[c++]=i[y]>>>8;return s}digest(){const{buffer:s,outputLen:r}=this;this.digestInto(s);const i=s.slice(0,r);return this.destroy(),i}}function wrapConstructorWithKey(o){const s=(i,a)=>o(a).update(toBytes(i)).digest(),r=o(new Uint8Array(32));return s.outputLen=r.outputLen,s.blockLen=r.blockLen,s.create=i=>o(i),s}wrapConstructorWithKey(o=>new Poly1305(o));const sigma16=utf8ToBytes("expand 16-byte k"),sigma32=utf8ToBytes("expand 32-byte k"),sigma16_32=u32(sigma16),sigma32_32=u32(sigma32),isAligned32=o=>!(o.byteOffset%4),salsaBasic=o=>{const{core:s,rounds:r,counterRight:i,counterLen:a,allow128bitKeys:c,extendNonceFn:y,blockLen:w}=checkOpts({rounds:20,counterRight:!1,counterLen:8,allow128bitKeys:!0,blockLen:64},o);assert.number(a),assert.number(r),assert.number(w),assert.bool(i),assert.bool(c);const C=w/4;if(w%4!=0)throw new Error("Salsa/ChaCha: blockLen must be aligned to 4 bytes");return(T,S,M,O,L=0)=>{if(assert.bytes(T),assert.bytes(S),assert.bytes(M),O||(O=new Uint8Array(M.length)),assert.bytes(O),assert.number(L),L<0||L>=2**32-1)throw new Error("Salsa/ChaCha: counter overflow");if(O.length=2**32-1)throw new Error("Salsa/ChaCha: counter overflow");const Ce=Math.min(w,De-ce);if(Ce===w&&xe&&Oe){const Be=ce/4;if(ce%4!=0)throw new Error("Salsa/ChaCha: invalid block position");for(let at=0;ato<>>32-s;function chachaCore(o,s,r,i,a,c=20){let y=o[0],w=o[1],C=o[2],T=o[3],S=s[0],M=s[1],O=s[2],L=s[3],Z=s[4],q=s[5],re=s[6],pe=s[7],se=a,ae=r[0],me=r[1],be=r[2],Oe=y,xe=w,De=C,ce=T,ue=S,Ce=M,Be=O,at=L,dt=Z,bt=q,lt=re,rn=pe,gn=se,bn=ae,Vn=me,yn=be;for(let _t=0;_ta?s.create().update(i).digest():i);for(let y=0;ynew HMAC(o,s).update(r).digest();function extract$1(o,s,r){return assert$2.hash(o),void 0===r&&(r=new Uint8Array(o.outputLen)),hmac(o,toBytes$2(r),toBytes$2(s))}hmac.create=(o,s)=>new HMAC(o,s);const HKDF_COUNTER$1=new Uint8Array([0]),EMPTY_BUFFER$1=new Uint8Array;function expand$1(o,s,r,i=32){if(assert$2.hash(o),assert$2.number(i),i>255*o.outputLen)throw new Error("Length should be <= 255*HashLen");const a=Math.ceil(i/o.outputLen);void 0===r&&(r=EMPTY_BUFFER$1);const c=new Uint8Array(a*o.outputLen),y=hmac.create(o,s),w=y._cloneInto(),C=new Uint8Array(y.outputLen);for(let T=0;Texpand$1(o,extract$1(o,s,r),i,a);var __defProp=Object.defineProperty,__export=(o,s)=>{for(var r in s)__defProp(o,r,{get:s[r],enumerable:!0})};function generatePrivateKey(){return bytesToHex$1(schnorr.utils.randomPrivateKey())}function getPublicKey(o){return bytesToHex$1(schnorr.getPublicKey(o))}var utils_exports={};__export(utils_exports,{MessageNode:()=>MessageNode,MessageQueue:()=>MessageQueue,insertEventIntoAscendingList:()=>insertEventIntoAscendingList,insertEventIntoDescendingList:()=>insertEventIntoDescendingList,normalizeURL:()=>normalizeURL,utf8Decoder:()=>utf8Decoder,utf8Encoder:()=>utf8Encoder});var utf8Decoder=new TextDecoder("utf-8"),utf8Encoder=new TextEncoder;function normalizeURL(o){let s=new URL(o);return s.pathname=s.pathname.replace(/\/+/g,"/"),s.pathname.endsWith("/")&&(s.pathname=s.pathname.slice(0,-1)),("80"===s.port&&"ws:"===s.protocol||"443"===s.port&&"wss:"===s.protocol)&&(s.port=""),s.searchParams.sort(),s.hash="",s.toString()}function insertEventIntoDescendingList(o,s){let r,i=0,a=o.length-1,c=i;if(a<0)c=0;else if(s.created_at=o[i].created_at)c=i;else for(;;){if(a<=i+1){c=a;break}if(r=Math.floor(i+(a-i)/2),o[r].created_at>s.created_at)i=r;else{if(!(o[r].created_ato[a].created_at)c=a+1;else if(s.created_at<=o[i].created_at)c=i;else for(;;){if(a<=i+1){c=a;break}if(r=Math.floor(i+(a-i)/2),o[r].created_ats.created_at)){c=r;break}a=r}}return o[c]?.id!==s.id?[...o.slice(0,c),s,...o.slice(c)]:o}var MessageNode=class{_value;_next;get value(){return this._value}set value(o){this._value=o}get next(){return this._next}set next(o){this._next=o}constructor(o){this._value=o,this._next=null}},MessageQueue=class{_first;_last;get first(){return this._first}set first(o){this._first=o}get last(){return this._last}set last(o){this._last=o}_size;get size(){return this._size}set size(o){this._size=o}constructor(){this._first=null,this._last=null,this._size=0}enqueue(o){const s=new MessageNode(o);return 0!==this._size&&this._last?(this._last.next=s,this._last=s):(this._first=s,this._last=s),this._size++,!0}dequeue(){if(0===this._size||!this._first)return null;let o=this._first;return this._first=o.next,o.next=null,this._size--,o.value}},verifiedSymbol=Symbol("verified");function getBlankEvent(o=255){return{kind:o,content:"",tags:[],created_at:0}}function finishEvent(o,s){const r=o;return r.pubkey=getPublicKey(s),r.id=getEventHash(r),r.sig=getSignature(r,s),r[verifiedSymbol]=!0,r}function serializeEvent(o){if(!validateEvent(o))throw new Error("can't serialize event with wrong or missing properties");return JSON.stringify([0,o.pubkey,o.created_at,o.kind,o.tags,o.content])}function getEventHash(o){return bytesToHex$1(sha256$1(utf8Encoder.encode(serializeEvent(o))))}var isRecord=o=>o instanceof Object;function validateEvent(o){if(!isRecord(o)||"number"!=typeof o.kind||"string"!=typeof o.content||"number"!=typeof o.created_at||"string"!=typeof o.pubkey||!o.pubkey.match(/^[a-f0-9]{64}$/)||!Array.isArray(o.tags))return!1;for(let s=0;ss.id.startsWith(r))||o.kinds&&-1===o.kinds.indexOf(s.kind)||o.authors&&-1===o.authors.indexOf(s.pubkey)&&!o.authors.some(r=>s.pubkey.startsWith(r)))return!1;for(let r in o)if("#"===r[0]){let i=o[`#${r.slice(1)}`];if(i&&!s.tags.find(([a,c])=>a===r.slice(1)&&-1!==i.indexOf(c)))return!1}return!(o.since&&s.created_ato.until)}function matchFilters(o,s){for(let r=0;rgetHex64,getInt:()=>getInt,getSubscriptionId:()=>getSubscriptionId,matchEventId:()=>matchEventId,matchEventKind:()=>matchEventKind,matchEventPubkey:()=>matchEventPubkey});var newListeners=()=>({connect:[],disconnect:[],error:[],notice:[],auth:[]});function relayInit(o,s={}){let{listTimeout:r=3e3,getTimeout:i=3e3,countTimeout:a=3e3}=s;var c,y,w={},C=newListeners(),T={},S={};function M(){return 1===c?.readyState}function O(re){return L.apply(this,arguments)}function L(){return(L=(0,_home_runner_work_angor_hub_angor_hub_node_modules_angular_builders_custom_webpack_node_modules_babel_runtime_helpers_esm_asyncToGenerator_js__WEBPACK_IMPORTED_MODULE_1__.A)(function*(re){let pe=JSON.stringify(re);if(M()||(yield new Promise(se=>setTimeout(se,1e3)),M()))try{c.send(pe)}catch(se){console.log(se)}})).apply(this,arguments)}const Z=(re,{verb:pe="REQ",skipVerification:se=!1,alreadyHaveEvent:ae=null,id:me=Math.random().toString().slice(2)}={})=>{let be=me;w[be]={id:be,filters:re,skipVerification:se,alreadyHaveEvent:ae},O([pe,be,...re]);let Oe={sub:(xe,De={})=>Z(xe||re,{skipVerification:De.skipVerification||se,alreadyHaveEvent:De.alreadyHaveEvent||ae,id:be}),unsub:()=>{delete w[be],delete T[be],O(["CLOSE",be])},on:(xe,De)=>{T[be]=T[be]||{event:[],count:[],eose:[]},T[be][xe].push(De)},off:(xe,De)=>{let ce=T[be],ue=ce[xe].indexOf(De);ue>=0&&ce[xe].splice(ue,1)},get events(){return eventsGenerator(Oe)}};return Oe};function q(re,pe){return new Promise((se,ae)=>{if(!re.id)return void ae(new Error(`event ${re} has no id`));let me=re.id;O([pe,re]),S[me]={resolve:se,reject:ae}})}return{url:o,sub:Z,on:(re,pe)=>{C[re].push(pe),"connect"===re&&1===c?.readyState&&pe()},off:(re,pe)=>{let se=C[re].indexOf(pe);-1!==se&&C[re].splice(se,1)},list:(re,pe)=>new Promise(se=>{let ae=Z(re,pe),me=[],be=setTimeout(()=>{ae.unsub(),se(me)},r);ae.on("eose",()=>{ae.unsub(),clearTimeout(be),se(me)}),ae.on("event",Oe=>{me.push(Oe)})}),get:(re,pe)=>new Promise(se=>{let ae=Z([re],pe),me=setTimeout(()=>{ae.unsub(),se(null)},i);ae.on("event",be=>{ae.unsub(),clearTimeout(me),se(be)})}),count:re=>new Promise(pe=>{let se=Z(re,{...Z,verb:"COUNT"}),ae=setTimeout(()=>{se.unsub(),pe(null)},a);se.on("count",me=>{se.unsub(),clearTimeout(ae),pe(me)})}),publish:re=>(0,_home_runner_work_angor_hub_angor_hub_node_modules_angular_builders_custom_webpack_node_modules_babel_runtime_helpers_esm_asyncToGenerator_js__WEBPACK_IMPORTED_MODULE_1__.A)(function*(){yield q(re,"EVENT")})(),auth:re=>(0,_home_runner_work_angor_hub_angor_hub_node_modules_angular_builders_custom_webpack_node_modules_babel_runtime_helpers_esm_asyncToGenerator_js__WEBPACK_IMPORTED_MODULE_1__.A)(function*(){yield q(re,"AUTH")})(),connect:(re=(0,_home_runner_work_angor_hub_angor_hub_node_modules_angular_builders_custom_webpack_node_modules_babel_runtime_helpers_esm_asyncToGenerator_js__WEBPACK_IMPORTED_MODULE_1__.A)(function*(){M()||(yield(0,_home_runner_work_angor_hub_angor_hub_node_modules_angular_builders_custom_webpack_node_modules_babel_runtime_helpers_esm_asyncToGenerator_js__WEBPACK_IMPORTED_MODULE_1__.A)(function*(){return y||(y=new Promise((pe,se)=>{try{c=new WebSocket(o)}catch(Oe){se(Oe)}c.onopen=()=>{C.connect.forEach(Oe=>Oe()),pe()},c.onerror=()=>{y=void 0,C.error.forEach(Oe=>Oe()),se()},c.onclose=(0,_home_runner_work_angor_hub_angor_hub_node_modules_angular_builders_custom_webpack_node_modules_babel_runtime_helpers_esm_asyncToGenerator_js__WEBPACK_IMPORTED_MODULE_1__.A)(function*(){y=void 0,C.disconnect.forEach(Oe=>Oe())});let ae,me=new MessageQueue;function be(){if(0===me.size)return clearInterval(ae),void(ae=null);var Oe=me.dequeue();if(!Oe)return;let xe=getSubscriptionId(Oe);if(xe){let De=w[xe];if(De&&De.alreadyHaveEvent&&De.alreadyHaveEvent(getHex64(Oe,"id"),o))return}try{let De=JSON.parse(Oe);switch(De[0]){case"EVENT":{let Be=De[1],at=De[2];return void(validateEvent(at)&&w[Be]&&(w[Be].skipVerification||verifySignature(at))&&matchFilters(w[Be].filters,at)&&(T[Be]?.event||[]).forEach(dt=>dt(at)))}case"COUNT":let ce=De[1],ue=De[2];return void(w[ce]&&(T[ce]?.count||[]).forEach(Be=>Be(ue)));case"EOSE":{let Be=De[1];return void(Be in T&&(T[Be].eose.forEach(at=>at()),T[Be].eose=[]))}case"OK":{let Be=De[1],at=De[2],dt=De[3]||"";if(Be in S){let{resolve:bt,reject:lt}=S[Be];at?bt(null):lt(new Error(dt))}return}case"NOTICE":let Ce=De[1];return void C.notice.forEach(Be=>Be(Ce));case"AUTH":{let Be=De[1];return void C.auth?.forEach(at=>at(Be))}}}catch{return}}c.onmessage=Oe=>{me.enqueue(Oe.data),ae||(ae=setInterval(be,0))}}))})())}),function(){return re.apply(this,arguments)}),close(){C=newListeners(),T={},S={},c?.readyState===WebSocket.OPEN&&c.close()},get status(){return c?.readyState??3}};var re}function eventsGenerator(o){return _eventsGenerator.apply(this,arguments)}function _eventsGenerator(){return _eventsGenerator=(0,_home_runner_work_angor_hub_angor_hub_node_modules_angular_builders_custom_webpack_node_modules_babel_runtime_helpers_esm_wrapAsyncGenerator_js__WEBPACK_IMPORTED_MODULE_0__.A)(function*(o){let s;const r=[],i=a=>{s?(s(a),s=void 0):r.push(a)};o.on("event",i);try{for(;;)r.length>0?yield r.shift():yield yield(0,_home_runner_work_angor_hub_angor_hub_node_modules_angular_builders_custom_webpack_node_modules_babel_runtime_helpers_esm_awaitAsyncGenerator_js__WEBPACK_IMPORTED_MODULE_2__.A)(new Promise(c=>{s=c}))}finally{o.off("event",i)}}),_eventsGenerator.apply(this,arguments)}var nip19_exports={};__export(nip19_exports,{BECH32_REGEX:()=>BECH32_REGEX,decode:()=>decode,naddrEncode:()=>naddrEncode,neventEncode:()=>neventEncode,noteEncode:()=>noteEncode,nprofileEncode:()=>nprofileEncode,npubEncode:()=>npubEncode,nrelayEncode:()=>nrelayEncode,nsecEncode:()=>nsecEncode});var Bech32MaxSize=5e3,BECH32_REGEX=/[\x21-\x7E]{1,83}1[023456789acdefghjklmnpqrstuvwxyz]{6,}/;function integerToUint8Array(o){const s=new Uint8Array(4);return s[0]=o>>24&255,s[1]=o>>16&255,s[2]=o>>8&255,s[3]=255&o,s}function decode(o){let{prefix:s,words:r}=bech32$1.decode(o,Bech32MaxSize),i=new Uint8Array(bech32$1.fromWords(r));switch(s){case"nprofile":{let a=parseTLV(i);if(!a[0]?.[0])throw new Error("missing TLV 0 for nprofile");if(32!==a[0][0].length)throw new Error("TLV 0 should be 32 bytes");return{type:"nprofile",data:{pubkey:bytesToHex$1(a[0][0]),relays:a[1]?a[1].map(c=>utf8Decoder.decode(c)):[]}}}case"nevent":{let a=parseTLV(i);if(!a[0]?.[0])throw new Error("missing TLV 0 for nevent");if(32!==a[0][0].length)throw new Error("TLV 0 should be 32 bytes");if(a[2]&&32!==a[2][0].length)throw new Error("TLV 2 should be 32 bytes");if(a[3]&&4!==a[3][0].length)throw new Error("TLV 3 should be 4 bytes");return{type:"nevent",data:{id:bytesToHex$1(a[0][0]),relays:a[1]?a[1].map(c=>utf8Decoder.decode(c)):[],author:a[2]?.[0]?bytesToHex$1(a[2][0]):void 0,kind:a[3]?.[0]?parseInt(bytesToHex$1(a[3][0]),16):void 0}}}case"naddr":{let a=parseTLV(i);if(!a[0]?.[0])throw new Error("missing TLV 0 for naddr");if(!a[2]?.[0])throw new Error("missing TLV 2 for naddr");if(32!==a[2][0].length)throw new Error("TLV 2 should be 32 bytes");if(!a[3]?.[0])throw new Error("missing TLV 3 for naddr");if(4!==a[3][0].length)throw new Error("TLV 3 should be 4 bytes");return{type:"naddr",data:{identifier:utf8Decoder.decode(a[0][0]),pubkey:bytesToHex$1(a[2][0]),kind:parseInt(bytesToHex$1(a[3][0]),16),relays:a[1]?a[1].map(c=>utf8Decoder.decode(c)):[]}}}case"nrelay":{let a=parseTLV(i);if(!a[0]?.[0])throw new Error("missing TLV 0 for nrelay");return{type:"nrelay",data:utf8Decoder.decode(a[0][0])}}case"nsec":case"npub":case"note":return{type:s,data:bytesToHex$1(i)};default:throw new Error(`unknown prefix ${s}`)}}function parseTLV(o){let s={},r=o;for(;r.length>0;){let i=r[0],a=r[1];if(!a)throw new Error(`malformed TLV ${i}`);let c=r.slice(2,2+a);if(r=r.slice(2+a),c.lengthutf8Encoder.encode(s))}))}function neventEncode(o){let s;return null!=o.kind&&(s=integerToUint8Array(o.kind)),encodeBech32("nevent",encodeTLV({0:[hexToBytes$1(o.id)],1:(o.relays||[]).map(r=>utf8Encoder.encode(r)),2:o.author?[hexToBytes$1(o.author)]:[],3:s?[new Uint8Array(s)]:[]}))}function naddrEncode(o){let s=new ArrayBuffer(4);return new DataView(s).setUint32(0,o.kind,!1),encodeBech32("naddr",encodeTLV({0:[utf8Encoder.encode(o.identifier)],1:(o.relays||[]).map(r=>utf8Encoder.encode(r)),2:[hexToBytes$1(o.pubkey)],3:[new Uint8Array(s)]}))}function nrelayEncode(o){return encodeBech32("nrelay",encodeTLV({0:[utf8Encoder.encode(o)]}))}function encodeTLV(o){let s=[];return Object.entries(o).forEach(([r,i])=>{i.forEach(a=>{let c=new Uint8Array(a.length+2);c.set([parseInt(r)],0),c.set([a.length],1),c.set(a,2),s.push(c)})}),concatBytes$1(...s)}var nip04_exports={};function encrypt$1(o,s,r){return _encrypt$.apply(this,arguments)}function _encrypt$(){return _encrypt$=(0,_home_runner_work_angor_hub_angor_hub_node_modules_angular_builders_custom_webpack_node_modules_babel_runtime_helpers_esm_asyncToGenerator_js__WEBPACK_IMPORTED_MODULE_1__.A)(function*(o,s,r){const i=getNormalizedX(secp256k1.getSharedSecret(o,"02"+s));let a=Uint8Array.from(randomBytes$1(16)),c=utf8Encoder.encode(r),y=yield crypto.subtle.importKey("raw",i,{name:"AES-CBC"},!1,["encrypt"]),w=yield crypto.subtle.encrypt({name:"AES-CBC",iv:a},y,c);return`${base64$1.encode(new Uint8Array(w))}?iv=${base64$1.encode(new Uint8Array(a.buffer))}`}),_encrypt$.apply(this,arguments)}function decrypt$1(o,s,r){return _decrypt$.apply(this,arguments)}function _decrypt$(){return _decrypt$=(0,_home_runner_work_angor_hub_angor_hub_node_modules_angular_builders_custom_webpack_node_modules_babel_runtime_helpers_esm_asyncToGenerator_js__WEBPACK_IMPORTED_MODULE_1__.A)(function*(o,s,r){let[i,a]=r.split("?iv="),c=getNormalizedX(secp256k1.getSharedSecret(o,"02"+s)),y=yield crypto.subtle.importKey("raw",c,{name:"AES-CBC"},!1,["decrypt"]),w=base64$1.decode(i),C=base64$1.decode(a),T=yield crypto.subtle.decrypt({name:"AES-CBC",iv:C},y,w);return utf8Decoder.decode(T)}),_decrypt$.apply(this,arguments)}function getNormalizedX(o){return o.slice(1,33)}__export(nip04_exports,{decrypt:()=>decrypt$1,encrypt:()=>encrypt$1}),typeof crypto<"u"&&!crypto.subtle&&crypto.webcrypto&&(crypto.subtle=crypto.webcrypto.subtle);var nip05_exports={};__export(nip05_exports,{NIP05_REGEX:()=>NIP05_REGEX$1,queryProfile:()=>queryProfile,searchDomain:()=>searchDomain,useFetchImplementation:()=>useFetchImplementation});var NIP05_REGEX$1=/^(?:([\w.+-]+)@)?([\w.-]+)$/,_fetch;try{_fetch=fetch}catch{}function useFetchImplementation(o){_fetch=o}function searchDomain(o){return _searchDomain.apply(this,arguments)}function _searchDomain(){return _searchDomain=(0,_home_runner_work_angor_hub_angor_hub_node_modules_angular_builders_custom_webpack_node_modules_babel_runtime_helpers_esm_asyncToGenerator_js__WEBPACK_IMPORTED_MODULE_1__.A)(function*(o,s=""){try{return(yield(yield _fetch(`https://${o}/.well-known/nostr.json?name=${s}`)).json()).names}catch{return{}}}),_searchDomain.apply(this,arguments)}function queryProfile(o){return _queryProfile.apply(this,arguments)}function _queryProfile(){return _queryProfile=(0,_home_runner_work_angor_hub_angor_hub_node_modules_angular_builders_custom_webpack_node_modules_babel_runtime_helpers_esm_asyncToGenerator_js__WEBPACK_IMPORTED_MODULE_1__.A)(function*(o){const s=o.match(NIP05_REGEX$1);if(!s)return null;const[r,i="_",a]=s;try{const c=yield _fetch(`https://${a}/.well-known/nostr.json?name=${i}`),{names:y,relays:w}=parseNIP05Result$1(yield c.json()),C=y[i];return C?{pubkey:C,relays:w?.[C]}:null}catch{return null}}),_queryProfile.apply(this,arguments)}function parseNIP05Result$1(o){const s={names:{}};for(const[r,i]of Object.entries(o.names))"string"==typeof r&&"string"==typeof i&&(s.names[r]=i);if(o.relays){s.relays={};for(const[r,i]of Object.entries(o.relays))"string"==typeof r&&Array.isArray(i)&&(s.relays[r]=i.filter(a=>"string"==typeof a))}return s}var nip06_exports={};function privateKeyFromSeedWords(o,s){let r=HDKey.fromMasterSeed(mnemonicToSeedSync(o,s)).derive("m/44'/1237'/0'/0/0").privateKey;if(!r)throw new Error("could not derive private key");return bytesToHex$1(r)}function generateSeedWords(){return generateMnemonic(wordlist)}function validateWords(o){return validateMnemonic(o,wordlist)}__export(nip06_exports,{generateSeedWords:()=>generateSeedWords,privateKeyFromSeedWords:()=>privateKeyFromSeedWords,validateWords:()=>validateWords});var nip10_exports={};function parse(o){const s={reply:void 0,root:void 0,mentions:[],profiles:[]},r=[];for(const i of o.tags)"e"===i[0]&&i[1]&&r.push(i),"p"===i[0]&&i[1]&&s.profiles.push({pubkey:i[1],relays:i[2]?[i[2]]:[]});for(let i=0;iparse});var nip13_exports={};function getPow(o){let s=0;for(let r=0;r=s)break}return i}__export(nip13_exports,{getPow:()=>getPow,minePow:()=>minePow});var nip18_exports={};function finishRepostEvent(o,s,r,i){return finishEvent({kind:6,tags:[...o.tags??[],["e",s.id,r],["p",s.pubkey]],content:""===o.content?"":JSON.stringify(s),created_at:o.created_at},i)}function getRepostedEventPointer(o){if(6!==o.kind)return;let s,r;for(let i=o.tags.length-1;i>=0&&(void 0===s||void 0===r);i--){const a=o.tags[i];a.length>=2&&("e"===a[0]&&void 0===s?s=a:"p"===a[0]&&void 0===r&&(r=a))}return void 0!==s?{id:s[1],relays:[s[2],r?.[2]].filter(i=>"string"==typeof i),author:r?.[1]}:void 0}function getRepostedEvent(o,{skipVerification:s}={}){const r=getRepostedEventPointer(o);if(void 0===r||""===o.content)return;let i;try{i=JSON.parse(o.content)}catch{return}return i.id===r.id&&(s||verifySignature(i))?i:void 0}__export(nip18_exports,{finishRepostEvent:()=>finishRepostEvent,getRepostedEvent:()=>getRepostedEvent,getRepostedEventPointer:()=>getRepostedEventPointer});var nip21_exports={};__export(nip21_exports,{NOSTR_URI_REGEX:()=>NOSTR_URI_REGEX,parse:()=>parse2,test:()=>test});var NOSTR_URI_REGEX=new RegExp(`nostr:(${BECH32_REGEX.source})`);function test(o){return"string"==typeof o&&new RegExp(`^${NOSTR_URI_REGEX.source}$`).test(o)}function parse2(o){const s=o.match(new RegExp(`^${NOSTR_URI_REGEX.source}$`));if(!s)throw new Error(`Invalid Nostr URI: ${o}`);return{uri:s[0],value:s[1],decoded:decode(s[1])}}var nip25_exports={};function finishReactionEvent(o,s,r){const i=s.tags.filter(a=>a.length>=2&&("e"===a[0]||"p"===a[0]));return finishEvent({...o,kind:7,tags:[...o.tags??[],...i,["e",s.id],["p",s.pubkey]],content:o.content??"+"},r)}function getReactedEventPointer(o){if(7!==o.kind)return;let s,r;for(let i=o.tags.length-1;i>=0&&(void 0===s||void 0===r);i--){const a=o.tags[i];a.length>=2&&("e"===a[0]&&void 0===s?s=a:"p"===a[0]&&void 0===r&&(r=a))}return void 0!==s&&void 0!==r?{id:s[1],relays:[s[2],r[2]].filter(i=>void 0!==i),author:r[1]}:void 0}__export(nip25_exports,{finishReactionEvent:()=>finishReactionEvent,getReactedEventPointer:()=>getReactedEventPointer});var nip26_exports={};function createDelegation(o,s){let r=[];(s.kind||-1)>=0&&r.push(`kind=${s.kind}`),s.until&&r.push(`created_at<${s.until}`),s.since&&r.push(`created_at>${s.since}`);let i=r.join("&");if(""===i)throw new Error("refusing to create a delegation without any conditions");let a=sha256$1(utf8Encoder.encode(`nostr:delegation:${s.pubkey}:${i}`)),c=bytesToHex$1(schnorr.sign(a,o));return{from:getPublicKey(o),to:s.pubkey,cond:i,sig:c}}function getDelegator(o){let s=o.tags.find(w=>"delegation"===w[0]&&w.length>=4);if(!s)return null;let r=s[1],i=s[2],a=s[3],c=i.split("&");for(let w=0;w"===T&&o.created_at>parseInt(S)))return null}let y=sha256$1(utf8Encoder.encode(`nostr:delegation:${o.pubkey}:${i}`));return schnorr.verify(a,y,r)?r:null}__export(nip26_exports,{createDelegation:()=>createDelegation,getDelegator:()=>getDelegator});var nip27_exports={};__export(nip27_exports,{matchAll:()=>matchAll,regex:()=>regex,replaceAll:()=>replaceAll});var regex=()=>new RegExp(`\\b${NOSTR_URI_REGEX.source}\\b`,"g");function*matchAll(o){const s=o.matchAll(regex());for(const r of s)try{const[i,a]=r;yield{uri:i,value:a,decoded:decode(a),start:r.index,end:r.index+i.length}}catch{}}function replaceAll(o,s){return o.replaceAll(regex(),(r,i)=>s({uri:r,value:i,decoded:decode(i)}))}var nip28_exports={};__export(nip28_exports,{channelCreateEvent:()=>channelCreateEvent,channelHideMessageEvent:()=>channelHideMessageEvent,channelMessageEvent:()=>channelMessageEvent,channelMetadataEvent:()=>channelMetadataEvent,channelMuteUserEvent:()=>channelMuteUserEvent});var channelCreateEvent=(o,s)=>{let r;if("object"==typeof o.content)r=JSON.stringify(o.content);else{if("string"!=typeof o.content)return;r=o.content}return finishEvent({kind:40,tags:[...o.tags??[]],content:r,created_at:o.created_at},s)},channelMetadataEvent=(o,s)=>{let r;if("object"==typeof o.content)r=JSON.stringify(o.content);else{if("string"!=typeof o.content)return;r=o.content}return finishEvent({kind:41,tags:[["e",o.channel_create_event_id],...o.tags??[]],content:r,created_at:o.created_at},s)},channelMessageEvent=(o,s)=>{const r=[["e",o.channel_create_event_id,o.relay_url,"root"]];return o.reply_to_channel_message_event_id&&r.push(["e",o.reply_to_channel_message_event_id,o.relay_url,"reply"]),finishEvent({kind:42,tags:[...r,...o.tags??[]],content:o.content,created_at:o.created_at},s)},channelHideMessageEvent=(o,s)=>{let r;if("object"==typeof o.content)r=JSON.stringify(o.content);else{if("string"!=typeof o.content)return;r=o.content}return finishEvent({kind:43,tags:[["e",o.channel_message_event_id],...o.tags??[]],content:r,created_at:o.created_at},s)},channelMuteUserEvent=(o,s)=>{let r;if("object"==typeof o.content)r=JSON.stringify(o.content);else{if("string"!=typeof o.content)return;r=o.content}return finishEvent({kind:44,tags:[["p",o.pubkey_to_mute],...o.tags??[]],content:r,created_at:o.created_at},s)},nip39_exports={},_fetch2;__export(nip39_exports,{useFetchImplementation:()=>useFetchImplementation2,validateGithub:()=>validateGithub});try{_fetch2=fetch}catch{}function useFetchImplementation2(o){_fetch2=o}function validateGithub(o,s,r){return _validateGithub.apply(this,arguments)}function _validateGithub(){return _validateGithub=(0,_home_runner_work_angor_hub_angor_hub_node_modules_angular_builders_custom_webpack_node_modules_babel_runtime_helpers_esm_asyncToGenerator_js__WEBPACK_IMPORTED_MODULE_1__.A)(function*(o,s,r){try{return(yield(yield _fetch2(`https://gist.github.com/${s}/${r}/raw`)).text())===`Verifying that I control the following Nostr public key: ${o}`}catch{return!1}}),_validateGithub.apply(this,arguments)}var nip42_exports={};__export(nip42_exports,{authenticate:()=>authenticate});var authenticate=function(){var o=(0,_home_runner_work_angor_hub_angor_hub_node_modules_angular_builders_custom_webpack_node_modules_babel_runtime_helpers_esm_asyncToGenerator_js__WEBPACK_IMPORTED_MODULE_1__.A)(function*({challenge:s,relay:r,sign:i}){const a={kind:22242,created_at:Math.floor(Date.now()/1e3),tags:[["relay",r.url],["challenge",s]],content:""};return r.auth(yield i(a))});return function(r){return o.apply(this,arguments)}}(),nip44_exports={};__export(nip44_exports,{decrypt:()=>decrypt2,encrypt:()=>encrypt2,utils:()=>utils});var utils={v2:{maxPlaintextSize:65408,minCiphertextSize:100,maxCiphertextSize:102400,getConversationKey:(o,s)=>secp256k1.getSharedSecret(o,"02"+s).subarray(1,33),getMessageKeys(o,s){const r=hkdf(sha256$1,o,s,"nip44-v2",76);return{encryption:r.subarray(0,32),nonce:r.subarray(32,44),auth:r.subarray(44,76)}},calcPadding(o){if(!Number.isSafeInteger(o)||o<0)throw new Error("expected positive integer");if(o<=32)return 32;const s=1<=utils.v2.maxPlaintextSize)throw new Error("invalid plaintext length: must be between 1b and 64KB");const i=utils.v2.calcPadding(r),a=new Uint8Array(i-r),c=new Uint8Array(2);return new DataView(c.buffer).setUint16(0,r),concatBytes$1(c,s,a)},unpad(o){const s=new DataView(o.buffer).getUint16(0),r=o.subarray(2,2+s);if(0===s||r.length!==s||o.length!==2+utils.v2.calcPadding(s))throw new Error("invalid padding");return utf8Decoder.decode(r)}}};function encrypt2(o,s,r={}){const i=r.version??2;if(2!==i)throw new Error("unknown encryption version "+i);const a=r.salt??randomBytes$1(32);ensureBytes(a,32);const c=utils.v2.getMessageKeys(o,a),y=utils.v2.pad(s),w=chacha20(c.encryption,c.nonce,y),C=hmac(sha256$1,c.auth,w);return base64$1.encode(concatBytes$1(new Uint8Array([i]),a,w,C))}function decrypt2(o,s){const r=utils.v2;ensureBytes(o,32);const i=s.length;if(i=r.maxCiphertextSize)throw new Error("invalid ciphertext length: "+i);if("#"===s[0])throw new Error("unknown encryption version");let a;try{a=base64$1.decode(s)}catch(M){throw new Error("invalid base64: "+M.message)}const c=a.subarray(0,1)[0];if(2!==c)throw new Error("unknown encryption version "+c);const y=a.subarray(1,33),w=a.subarray(33,-32),C=a.subarray(-32),T=r.getMessageKeys(o,y);if(!equalBytes(hmac(sha256$1,T.auth,w),C))throw new Error("invalid MAC");const S=chacha20(T.encryption,T.nonce,w);return r.unpad(S)}var nip47_exports={};function parseConnectionString(o){const{pathname:s,searchParams:r}=new URL(o),i=s,a=r.get("relay"),c=r.get("secret");if(!i||!a||!c)throw new Error("invalid connection string");return{pubkey:i,relay:a,secret:c}}function makeNwcRequestEvent(o){return _makeNwcRequestEvent.apply(this,arguments)}function _makeNwcRequestEvent(){return _makeNwcRequestEvent=(0,_home_runner_work_angor_hub_angor_hub_node_modules_angular_builders_custom_webpack_node_modules_babel_runtime_helpers_esm_asyncToGenerator_js__WEBPACK_IMPORTED_MODULE_1__.A)(function*({pubkey:o,secret:s,invoice:r}){const i={method:"pay_invoice",params:{invoice:r}},a=yield encrypt$1(s,o,JSON.stringify(i));return finishEvent({kind:23194,created_at:Math.round(Date.now()/1e3),content:a,tags:[["p",o]]},s)}),_makeNwcRequestEvent.apply(this,arguments)}__export(nip47_exports,{makeNwcRequestEvent:()=>makeNwcRequestEvent,parseConnectionString:()=>parseConnectionString});var nip57_exports={},_fetch3;__export(nip57_exports,{getZapEndpoint:()=>getZapEndpoint,makeZapReceipt:()=>makeZapReceipt,makeZapRequest:()=>makeZapRequest,useFetchImplementation:()=>useFetchImplementation3,validateZapRequest:()=>validateZapRequest});try{_fetch3=fetch}catch{}function useFetchImplementation3(o){_fetch3=o}function getZapEndpoint(o){return _getZapEndpoint.apply(this,arguments)}function _getZapEndpoint(){return _getZapEndpoint=(0,_home_runner_work_angor_hub_angor_hub_node_modules_angular_builders_custom_webpack_node_modules_babel_runtime_helpers_esm_asyncToGenerator_js__WEBPACK_IMPORTED_MODULE_1__.A)(function*(o){try{let s="",{lud06:r,lud16:i}=JSON.parse(o.content);if(r){let{words:y}=bech32$1.decode(r,1e3),w=bech32$1.fromWords(y);s=utf8Decoder.decode(w)}else{if(!i)return null;{let[y,w]=i.split("@");s=`https://${w}/.well-known/lnurlp/${y}`}}let a=yield _fetch3(s),c=yield a.json();if(c.allowsNostr&&c.nostrPubkey)return c.callback}catch{}return null}),_getZapEndpoint.apply(this,arguments)}function makeZapRequest({profile:o,event:s,amount:r,relays:i,comment:a=""}){if(!r)throw new Error("amount not given");if(!o)throw new Error("profile not given");let c={kind:9734,created_at:Math.round(Date.now()/1e3),content:a,tags:[["p",o],["amount",r.toString()],["relays",...i]]};return s&&c.tags.push(["e",s]),c}function validateZapRequest(o){let s;try{s=JSON.parse(o)}catch{return"Invalid zap request JSON."}if(!validateEvent(s))return"Zap request is not a valid Nostr event.";if(!verifySignature(s))return"Invalid signature on zap request.";let r=s.tags.find(([a,c])=>"p"===a&&c);if(!r)return"Zap request doesn't have a 'p' tag.";if(!r[1].match(/^[a-f0-9]{64}$/))return"Zap request 'p' tag is not valid hex.";let i=s.tags.find(([a,c])=>"e"===a&&c);return i&&!i[1].match(/^[a-f0-9]{64}$/)?"Zap request 'e' tag is not valid hex.":s.tags.find(([a,c])=>"relays"===a&&c)?null:"Zap request doesn't have a 'relays' tag."}function makeZapReceipt({zapRequest:o,preimage:s,bolt11:r,paidAt:i}){let a=JSON.parse(o).tags.filter(([y])=>"e"===y||"p"===y||"a"===y),c={kind:9735,created_at:Math.round(i.getTime()/1e3),content:"",tags:[...a,["bolt11",r],["description",o]]};return s&&c.tags.push(["preimage",s]),c}var nip98_exports={};__export(nip98_exports,{getToken:()=>getToken,unpackEventFromToken:()=>unpackEventFromToken,validateEvent:()=>validateEvent2,validateToken:()=>validateToken});var _authorizationScheme="Nostr ";function getToken(o,s,r){return _getToken.apply(this,arguments)}function _getToken(){return _getToken=(0,_home_runner_work_angor_hub_angor_hub_node_modules_angular_builders_custom_webpack_node_modules_babel_runtime_helpers_esm_asyncToGenerator_js__WEBPACK_IMPORTED_MODULE_1__.A)(function*(o,s,r,i=!1){if(!o||!s)throw new Error("Missing loginUrl or httpMethod");const a=getBlankEvent(27235);a.tags=[["u",o],["method",s]],a.created_at=Math.round((new Date).getTime()/1e3);const c=yield r(a);return(i?_authorizationScheme:"")+base64$1.encode(utf8Encoder.encode(JSON.stringify(c)))}),_getToken.apply(this,arguments)}function validateToken(o,s,r){return _validateToken.apply(this,arguments)}function _validateToken(){return _validateToken=(0,_home_runner_work_angor_hub_angor_hub_node_modules_angular_builders_custom_webpack_node_modules_babel_runtime_helpers_esm_asyncToGenerator_js__WEBPACK_IMPORTED_MODULE_1__.A)(function*(o,s,r){const i=yield unpackEventFromToken(o).catch(a=>{throw a});return yield validateEvent2(i,s,r).catch(a=>{throw a})}),_validateToken.apply(this,arguments)}function unpackEventFromToken(o){return _unpackEventFromToken.apply(this,arguments)}function _unpackEventFromToken(){return _unpackEventFromToken=(0,_home_runner_work_angor_hub_angor_hub_node_modules_angular_builders_custom_webpack_node_modules_babel_runtime_helpers_esm_asyncToGenerator_js__WEBPACK_IMPORTED_MODULE_1__.A)(function*(o){if(!o)throw new Error("Missing token");o=o.replace(_authorizationScheme,"");const s=utf8Decoder.decode(base64$1.decode(o));if(!s||0===s.length||!s.startsWith("{"))throw new Error("Invalid token");return JSON.parse(s)}),_unpackEventFromToken.apply(this,arguments)}function validateEvent2(o,s,r){return _validateEvent.apply(this,arguments)}function _validateEvent(){return _validateEvent=(0,_home_runner_work_angor_hub_angor_hub_node_modules_angular_builders_custom_webpack_node_modules_babel_runtime_helpers_esm_asyncToGenerator_js__WEBPACK_IMPORTED_MODULE_1__.A)(function*(o,s,r){if(!o)throw new Error("Invalid nostr event");if(!verifySignature(o))throw new Error("Invalid nostr event, signature invalid");if(27235!==o.kind)throw new Error("Invalid nostr event, kind invalid");if(!o.created_at)throw new Error("Invalid nostr event, created_at invalid");if(Math.round((new Date).getTime()/1e3)-o.created_at>60)throw new Error("Invalid nostr event, expired");const i=o.tags.find(c=>"u"===c[0]);if(1!==i?.length&&i?.[1]!==s)throw new Error("Invalid nostr event, url tag invalid");const a=o.tags.find(c=>"method"===c[0]);if(1!==a?.length&&a?.[1].toLowerCase()!==r.toLowerCase())throw new Error("Invalid nostr event, method tag invalid");return!0}),_validateEvent.apply(this,arguments)}var browser={exports:{}},ms,hasRequiredMs;function requireMs(){if(hasRequiredMs)return ms;hasRequiredMs=1;var o=1e3,s=60*o,r=60*s,i=24*r,a=7*i;function y(w,C,T,S){var M=C>=1.5*T;return Math.round(w/T)+" "+S+(M?"s":"")}return ms=function(w,C){C=C||{};var S,M,T=typeof w;if("string"===T&&w.length>0)return function(S){if(!((S=String(S)).length>100)){var M=/^(-?(?:\d+)?\.?\d+) *(milliseconds?|msecs?|ms|seconds?|secs?|s|minutes?|mins?|m|hours?|hrs?|h|days?|d|weeks?|w|years?|yrs?|y)?$/i.exec(S);if(M){var O=parseFloat(M[1]);switch((M[2]||"ms").toLowerCase()){case"years":case"year":case"yrs":case"yr":case"y":return 315576e5*O;case"weeks":case"week":case"w":return O*a;case"days":case"day":case"d":return O*i;case"hours":case"hour":case"hrs":case"hr":case"h":return O*r;case"minutes":case"minute":case"mins":case"min":case"m":return O*s;case"seconds":case"second":case"secs":case"sec":case"s":return O*o;case"milliseconds":case"millisecond":case"msecs":case"msec":case"ms":return O;default:return}}}}(w);if("number"===T&&isFinite(w))return C.long?(S=w,(M=Math.abs(S))>=i?y(S,M,i,"day"):M>=r?y(S,M,r,"hour"):M>=s?y(S,M,s,"minute"):M>=o?y(S,M,o,"second"):S+" ms"):function(S){var M=Math.abs(S);return M>=i?Math.round(S/i)+"d":M>=r?Math.round(S/r)+"h":M>=s?Math.round(S/s)+"m":M>=o?Math.round(S/o)+"s":S+"ms"}(w);throw new Error("val is not a non-empty string or a valid number. val="+JSON.stringify(w))}}function setup(o){function s(a){let c,y,w,C=null;function T(...S){if(!T.enabled)return;const M=T,O=Number(new Date);M.diff=O-(c||O),M.prev=c,M.curr=O,c=O,S[0]=s.coerce(S[0]),"string"!=typeof S[0]&&S.unshift("%O");let Z=0;S[0]=S[0].replace(/%([a-zA-Z%])/g,(q,re)=>{if("%%"===q)return"%";Z++;const pe=s.formatters[re];return"function"==typeof pe&&(q=pe.call(M,S[Z]),S.splice(Z,1),Z--),q}),s.formatArgs.call(M,S),(M.log||s.log).apply(M,S)}return T.namespace=a,T.useColors=s.useColors(),T.color=s.selectColor(a),T.extend=r,T.destroy=s.destroy,Object.defineProperty(T,"enabled",{enumerable:!0,configurable:!1,get:()=>null!==C?C:(y!==s.namespaces&&(y=s.namespaces,w=s.enabled(a)),w),set:S=>{C=S}}),"function"==typeof s.init&&s.init(T),T}function r(a,c){const y=s(this.namespace+(void 0===c?":":c)+a);return y.log=this.log,y}function i(a){return a.toString().substring(2,a.toString().length-2).replace(/\.\*\?$/,"*")}return s.debug=s,s.default=s,s.coerce=function(a){return a instanceof Error?a.stack||a.message:a},s.disable=function(){const a=[...s.names.map(i),...s.skips.map(i).map(c=>"-"+c)].join(",");return s.enable(""),a},s.enable=function(a){let c;s.save(a),s.namespaces=a,s.names=[],s.skips=[];const y=("string"==typeof a?a:"").split(/[\s,]+/),w=y.length;for(c=0;c{s[a]=o[a]}),s.names=[],s.skips=[],s.formatters={},s.selectColor=function(a){let c=0;for(let y=0;y{"%%"!==w&&(c++,"%c"===w&&(y=c))}),i.splice(y,0,a)},s.save=function(i){try{i?s.storage.setItem("debug",i):s.storage.removeItem("debug")}catch{}},s.load=function(){let i;try{i=s.storage.getItem("debug")}catch{}return!i&&typeof process<"u"&&"env"in process&&(i=process.env.DEBUG),i},s.useColors=function(){return!(!(typeof window<"u"&&window.process)||"renderer"!==window.process.type&&!window.process.__nwjs)||!(typeof navigator<"u"&&navigator.userAgent&&navigator.userAgent.toLowerCase().match(/(edge|trident)\/(\d+)/))&&(typeof document<"u"&&document.documentElement&&document.documentElement.style&&document.documentElement.style.WebkitAppearance||typeof window<"u"&&window.console&&(window.console.firebug||window.console.exception&&window.console.table)||typeof navigator<"u"&&navigator.userAgent&&navigator.userAgent.toLowerCase().match(/firefox\/(\d+)/)&&parseInt(RegExp.$1,10)>=31||typeof navigator<"u"&&navigator.userAgent&&navigator.userAgent.toLowerCase().match(/applewebkit\/(\d+)/))},s.storage=function(){try{return localStorage}catch{}}(),s.destroy=(()=>{let i=!1;return()=>{i||(i=!0,console.warn("Instance method `debug.destroy()` is deprecated and no longer does anything. It will be removed in the next major version of `debug`."))}})(),s.colors=["#0000CC","#0000FF","#0033CC","#0033FF","#0066CC","#0066FF","#0099CC","#0099FF","#00CC00","#00CC33","#00CC66","#00CC99","#00CCCC","#00CCFF","#3300CC","#3300FF","#3333CC","#3333FF","#3366CC","#3366FF","#3399CC","#3399FF","#33CC00","#33CC33","#33CC66","#33CC99","#33CCCC","#33CCFF","#6600CC","#6600FF","#6633CC","#6633FF","#66CC00","#66CC33","#9900CC","#9900FF","#9933CC","#9933FF","#99CC00","#99CC33","#CC0000","#CC0033","#CC0066","#CC0099","#CC00CC","#CC00FF","#CC3300","#CC3333","#CC3366","#CC3399","#CC33CC","#CC33FF","#CC6600","#CC6633","#CC9900","#CC9933","#CCCC00","#CCCC33","#FF0000","#FF0033","#FF0066","#FF0099","#FF00CC","#FF00FF","#FF3300","#FF3333","#FF3366","#FF3399","#FF33CC","#FF33FF","#FF6600","#FF6633","#FF9900","#FF9933","#FFCC00","#FFCC33"],s.log=console.debug||console.log||(()=>{}),o.exports=common(s);const{formatters:r}=o.exports;r.j=function(i){try{return JSON.stringify(i)}catch(a){return"[UnexpectedJSONParseError]: "+a.message}}}(browser,browser.exports);var browserExports=browser.exports,debug3=getDefaultExportFromCjs(browserExports),dist={},LRUCache$1={},LRUCacheNode$1={};Object.defineProperty(LRUCacheNode$1,"__esModule",{value:!0}),LRUCacheNode$1.LRUCacheNode=void 0;class LRUCacheNode{constructor(s,r,i){const{entryExpirationTimeInMS:a=null,next:c=null,prev:y=null,onEntryEvicted:w,onEntryMarkedAsMostRecentlyUsed:C,clone:T,cloneFn:S}=i??{};if("number"==typeof a&&(a<=0||Number.isNaN(a)))throw new Error("entryExpirationTimeInMS must either be null (no expiry) or greater than 0");this.clone=null!=T&&T,this.cloneFn=S??this.defaultClone,this.key=s,this.internalValue=this.clone?this.cloneFn(r):r,this.created=Date.now(),this.entryExpirationTimeInMS=a,this.next=c,this.prev=y,this.onEntryEvicted=w,this.onEntryMarkedAsMostRecentlyUsed=C}get value(){return this.clone?this.cloneFn(this.internalValue):this.internalValue}get isExpired(){return"number"==typeof this.entryExpirationTimeInMS&&Date.now()-this.created>this.entryExpirationTimeInMS}invokeOnEvicted(){if(this.onEntryEvicted){const{key:s,value:r,isExpired:i}=this;this.onEntryEvicted({key:s,value:r,isExpired:i})}}invokeOnEntryMarkedAsMostRecentlyUsed(){if(this.onEntryMarkedAsMostRecentlyUsed){const{key:s,value:r}=this;this.onEntryMarkedAsMostRecentlyUsed({key:s,value:r})}}defaultClone(s){return"boolean"==typeof s||"string"==typeof s||"number"==typeof s?s:JSON.parse(JSON.stringify(s))}}LRUCacheNode$1.LRUCacheNode=LRUCacheNode,Object.defineProperty(LRUCache$1,"__esModule",{value:!0}),LRUCache$1.LRUCache=void 0;const LRUCacheNode_1=LRUCacheNode$1;class LRUCache{constructor(s){this.lookupTable=new Map,this.head=null,this.tail=null;const{maxSize:r=25,entryExpirationTimeInMS:i=null,onEntryEvicted:a,onEntryMarkedAsMostRecentlyUsed:c,cloneFn:y,clone:w}=s??{};if(Number.isNaN(r)||r<=0)throw new Error("maxSize must be greater than 0.");if("number"==typeof i&&(i<=0||Number.isNaN(i)))throw new Error("entryExpirationTimeInMS must either be null (no expiry) or greater than 0");this.maxSizeInternal=r,this.entryExpirationTimeInMS=i,this.onEntryEvicted=a,this.onEntryMarkedAsMostRecentlyUsed=c,this.clone=w,this.cloneFn=y}get size(){return this.cleanCache(),this.lookupTable.size}get remainingSize(){return this.maxSizeInternal-this.size}get newest(){return this.head?this.head.isExpired?(this.removeNodeFromListAndLookupTable(this.head),this.newest):this.mapNodeToEntry(this.head):null}get oldest(){return this.tail?this.tail.isExpired?(this.removeNodeFromListAndLookupTable(this.tail),this.oldest):this.mapNodeToEntry(this.tail):null}get maxSize(){return this.maxSizeInternal}set maxSize(s){if(Number.isNaN(s)||s<=0)throw new Error("maxSize must be greater than 0.");this.maxSizeInternal=s,this.enforceSizeLimit()}set(s,r,i){const a=this.lookupTable.get(s);a&&this.removeNodeFromListAndLookupTable(a);const c=new LRUCacheNode_1.LRUCacheNode(s,r,{entryExpirationTimeInMS:this.entryExpirationTimeInMS,onEntryEvicted:this.onEntryEvicted,onEntryMarkedAsMostRecentlyUsed:this.onEntryMarkedAsMostRecentlyUsed,clone:this.clone,cloneFn:this.cloneFn,...i});return this.setNodeAsHead(c),this.lookupTable.set(s,c),this.enforceSizeLimit(),this}get(s){const r=this.lookupTable.get(s);return r?r.isExpired?(this.removeNodeFromListAndLookupTable(r),null):(this.setNodeAsHead(r),r.value):null}peek(s){const r=this.lookupTable.get(s);return r?r.isExpired?(this.removeNodeFromListAndLookupTable(r),null):r.value:null}delete(s){const r=this.lookupTable.get(s);return!!r&&this.removeNodeFromListAndLookupTable(r)}has(s){const r=this.lookupTable.get(s);return!(!r||r.isExpired&&(this.removeNodeFromListAndLookupTable(r),1))}clear(){this.head=null,this.tail=null,this.lookupTable.clear()}find(s){let r=this.head;for(;r;){if(r.isExpired){const a=r.next;this.removeNodeFromListAndLookupTable(r),r=a;continue}const i=this.mapNodeToEntry(r);if(s(i))return this.setNodeAsHead(r),i;r=r.next}return null}forEach(s){let r=this.head,i=0;for(;r;)if(r.isExpired){const a=r.next;this.removeNodeFromListAndLookupTable(r),r=a}else s(r.value,r.key,i),r=r.next,i++}*values(){let s=this.head;for(;s;)if(s.isExpired){const r=s.next;this.removeNodeFromListAndLookupTable(s),s=r}else yield s.value,s=s.next}*keys(){let s=this.head;for(;s;)if(s.isExpired){const r=s.next;this.removeNodeFromListAndLookupTable(s),s=r}else yield s.key,s=s.next}*entries(){let s=this.head;for(;s;)if(s.isExpired){const r=s.next;this.removeNodeFromListAndLookupTable(s),s=r}else yield this.mapNodeToEntry(s),s=s.next}*[Symbol.iterator](){let s=this.head;for(;s;)if(s.isExpired){const r=s.next;this.removeNodeFromListAndLookupTable(s),s=r}else yield this.mapNodeToEntry(s),s=s.next}enforceSizeLimit(){let s=this.tail;for(;null!==s&&this.size>this.maxSizeInternal;){const r=s.prev;this.removeNodeFromListAndLookupTable(s),s=r}}mapNodeToEntry({key:s,value:r}){return{key:s,value:r}}setNodeAsHead(s){this.removeNodeFromList(s),this.head?(s.next=this.head,this.head.prev=s,this.head=s):(this.head=s,this.tail=s),s.invokeOnEntryMarkedAsMostRecentlyUsed()}removeNodeFromList(s){null!==s.prev&&(s.prev.next=s.next),null!==s.next&&(s.next.prev=s.prev),this.head===s&&(this.head=s.next),this.tail===s&&(this.tail=s.prev),s.next=null,s.prev=null}removeNodeFromListAndLookupTable(s){return s.invokeOnEvicted(),this.removeNodeFromList(s),this.lookupTable.delete(s.key)}cleanCache(){if(!this.entryExpirationTimeInMS)return;const s=[];for(const r of this.lookupTable.values())r.isExpired&&s.push(r);s.forEach(r=>this.removeNodeFromListAndLookupTable(r))}}LRUCache$1.LRUCache=LRUCache,function(o){var s=commonjsGlobal&&commonjsGlobal.__createBinding||(Object.create?function(i,a,c,y){void 0===y&&(y=c);var w=Object.getOwnPropertyDescriptor(a,c);w&&!("get"in w?!a.__esModule:w.writable||w.configurable)||(w={enumerable:!0,get:function(){return a[c]}}),Object.defineProperty(i,y,w)}:function(i,a,c,y){void 0===y&&(y=c),i[y]=a[c]}),r=commonjsGlobal&&commonjsGlobal.__exportStar||function(i,a){for(var c in i)"default"===c||Object.prototype.hasOwnProperty.call(a,c)||s(a,i,c)};Object.defineProperty(o,"__esModule",{value:!0}),r(LRUCache$1,o)}(dist);var lib={};(function(o){function s(De){if(!Number.isSafeInteger(De))throw new Error(`Wrong integer: ${De}`)}function r(...De){const ce=(ue,Ce)=>Be=>ue(Ce(Be));return{encode:Array.from(De).reverse().reduce((ue,Ce)=>ue?ce(ue,Ce.encode):Ce.encode,void 0),decode:De.reduce((ue,Ce)=>ue?ce(ue,Ce.decode):Ce.decode,void 0)}}function i(De){return{encode:ce=>{if(!Array.isArray(ce)||ce.length&&"number"!=typeof ce[0])throw new Error("alphabet.encode input should be an array of numbers");return ce.map(ue=>{if(s(ue),ue<0||ue>=De.length)throw new Error(`Digit index outside alphabet: ${ue} (alphabet: ${De.length})`);return De[ue]})},decode:ce=>{if(!Array.isArray(ce)||ce.length&&"string"!=typeof ce[0])throw new Error("alphabet.decode input should be array of strings");return ce.map(ue=>{if("string"!=typeof ue)throw new Error(`alphabet.decode: not string element=${ue}`);const Ce=De.indexOf(ue);if(-1===Ce)throw new Error(`Unknown letter: "${ue}". Allowed: ${De}`);return Ce})}}}function a(De=""){if("string"!=typeof De)throw new Error("join separator should be string");return{encode:ce=>{if(!Array.isArray(ce)||ce.length&&"string"!=typeof ce[0])throw new Error("join.encode input should be array of strings");for(let ue of ce)if("string"!=typeof ue)throw new Error(`join.encode: non-string input=${ue}`);return ce.join(De)},decode:ce=>{if("string"!=typeof ce)throw new Error("join.decode input should be string");return ce.split(De)}}}function c(De,ce="="){if(s(De),"string"!=typeof ce)throw new Error("padding chr should be string");return{encode(ue){if(!Array.isArray(ue)||ue.length&&"string"!=typeof ue[0])throw new Error("padding.encode input should be array of strings");for(let Ce of ue)if("string"!=typeof Ce)throw new Error(`padding.encode: non-string input=${Ce}`);for(;ue.length*De%8;)ue.push(ce);return ue},decode(ue){if(!Array.isArray(ue)||ue.length&&"string"!=typeof ue[0])throw new Error("padding.encode input should be array of strings");for(let Be of ue)if("string"!=typeof Be)throw new Error(`padding.decode: non-string input=${Be}`);let Ce=ue.length;if(Ce*De%8)throw new Error("Invalid padding: string should have whole number of bytes");for(;Ce>0&&ue[Ce-1]===ce;Ce--)if(!((Ce-1)*De%8))throw new Error("Invalid padding: string has too much padding");return ue.slice(0,Ce)}}}function y(De){if("function"!=typeof De)throw new Error("normalize fn should be function");return{encode:ce=>ce,decode:ce=>De(ce)}}function w(De,ce,ue){if(ce<2)throw new Error(`convertRadix: wrong from=${ce}, base cannot be less than 2`);if(ue<2)throw new Error(`convertRadix: wrong to=${ue}, base cannot be less than 2`);if(!Array.isArray(De))throw new Error("convertRadix: data should be array");if(!De.length)return[];let Ce=0;const Be=[],at=Array.from(De);for(at.forEach(dt=>{if(s(dt),dt<0||dt>=ce)throw new Error(`Wrong integer: ${dt}`)});;){let dt=0,bt=!0;for(let lt=Ce;ltce?C(ce,De%ce):De,T=(De,ce)=>De+(ce-C(De,ce));function S(De,ce,ue,Ce){if(!Array.isArray(De))throw new Error("convertRadix2: data should be array");if(ce<=0||ce>32)throw new Error(`convertRadix2: wrong from=${ce}`);if(ue<=0||ue>32)throw new Error(`convertRadix2: wrong to=${ue}`);if(T(ce,ue)>32)throw new Error(`convertRadix2: carry overflow from=${ce} to=${ue} carryBits=${T(ce,ue)}`);let Be=0,at=0;const dt=2**ue-1,bt=[];for(const lt of De){if(s(lt),lt>=2**ce)throw new Error(`convertRadix2: invalid data word=${lt} from=${ce}`);if(Be=Be<32)throw new Error(`convertRadix2: carry overflow pos=${at} from=${ce}`);for(at+=ce;at>=ue;at-=ue)bt.push((Be>>at-ue&dt)>>>0);Be&=2**at-1}if(Be=Be<=ce)throw new Error("Excess padding");if(!Ce&&Be)throw new Error(`Non-zero padding: ${Be}`);return Ce&&at>0&&bt.push(Be>>>0),bt}function M(De){return s(De),{encode:ce=>{if(!(ce instanceof Uint8Array))throw new Error("radix.encode input should be Uint8Array");return w(Array.from(ce),256,De)},decode:ce=>{if(!Array.isArray(ce)||ce.length&&"number"!=typeof ce[0])throw new Error("radix.decode input should be array of strings");return Uint8Array.from(w(ce,De,256))}}}function O(De,ce=!1){if(s(De),De<=0||De>32)throw new Error("radix2: bits should be in (0..32]");if(T(8,De)>32||T(De,8)>32)throw new Error("radix2: carry overflow");return{encode:ue=>{if(!(ue instanceof Uint8Array))throw new Error("radix2.encode input should be Uint8Array");return S(Array.from(ue),8,De,!ce)},decode:ue=>{if(!Array.isArray(ue)||ue.length&&"number"!=typeof ue[0])throw new Error("radix2.decode input should be array of strings");return Uint8Array.from(S(ue,De,8,ce))}}}function L(De){if("function"!=typeof De)throw new Error("unsafeWrapper fn should be function");return function(...ce){try{return De.apply(null,ce)}catch{}}}function Z(De,ce){if(s(De),"function"!=typeof ce)throw new Error("checksum fn should be function");return{encode(ue){if(!(ue instanceof Uint8Array))throw new Error("checksum.encode: input should be Uint8Array");const Ce=ce(ue).slice(0,De),Be=new Uint8Array(ue.length+De);return Be.set(ue),Be.set(Ce,ue.length),Be},decode(ue){if(!(ue instanceof Uint8Array))throw new Error("checksum.decode: input should be Uint8Array");const Ce=ue.slice(0,-De),Be=ce(Ce).slice(0,De),at=ue.slice(-De);for(let dt=0;dtDe.toUpperCase().replace(/O/g,"0").replace(/[IL]/g,"1"))),o.base64=r(O(6),i("ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/"),c(6),a("")),o.base64url=r(O(6),i("ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789-_"),c(6),a(""));const q=De=>r(M(58),i(De),a(""));o.base58=q("123456789ABCDEFGHJKLMNPQRSTUVWXYZabcdefghijkmnopqrstuvwxyz"),o.base58flickr=q("123456789abcdefghijkmnopqrstuvwxyzABCDEFGHJKLMNPQRSTUVWXYZ"),o.base58xrp=q("rpshnaf39wBUDNEGHJKLM4PQRST7VWXYZ2bcdeCg65jkm8oFqi1tuvAxyz");const re=[0,2,3,5,6,7,9,10,11];o.base58xmr={encode(De){let ce="";for(let ue=0;uer(Z(4,ce=>De(De(ce))),o.base58);const pe=r(i("qpzry9x8gf2tvdw0s3jn54khce6mua7l"),a("")),se=[996825010,642813549,513874426,1027748829,705979059];function ae(De){const ce=De>>25;let ue=(33554431&De)<<5;for(let Ce=0;Ce>Ce&1)&&(ue^=se[Ce]);return ue}function me(De,ce,ue=1){const Ce=De.length;let Be=1;for(let at=0;at126)throw new Error(`Invalid prefix (${De})`);Be=ae(Be)^dt>>5}Be=ae(Be);for(let at=0;atlt)throw new TypeError(`Wrong string length: ${bt.length} (${bt}). Expected (8..${lt})`);const rn=bt.toLowerCase();if(bt!==rn&&bt!==bt.toUpperCase())throw new Error("String must be lowercase or uppercase");const gn=(bt=rn).lastIndexOf("1");if(0===gn||-1===gn)throw new Error('Letter "1" must be present between prefix and data only');const bn=bt.slice(0,gn),Vn=bt.slice(gn+1);if(Vn.length<6)throw new Error("Data must be at least 6 characters long");const yn=pe.decode(Vn).slice(0,-6),qe=me(bn,yn,ce);if(!Vn.endsWith(qe))throw new Error(`Invalid checksum in ${bt}: expected "${qe}"`);return{prefix:bn,words:yn}}return{encode:function(bt,lt,rn=90){if("string"!=typeof bt)throw new Error("bech32.encode prefix should be string, not "+typeof bt);if(!Array.isArray(lt)||lt.length&&"number"!=typeof lt[0])throw new Error("bech32.encode words should be array of numbers, not "+typeof lt);const gn=bt.length+7+lt.length;if(!1!==rn&&gn>rn)throw new TypeError(`Length ${gn} exceeds limit ${rn}`);return`${bt=bt.toLowerCase()}1${pe.encode(lt)}${me(bt,lt,ce)}`},decode:dt,decodeToBytes:function(bt){const{prefix:lt,words:rn}=dt(bt,!1);return{prefix:lt,words:rn,bytes:Ce(rn)}},decodeUnsafe:L(dt),fromWords:Ce,fromWordsUnsafe:at,toWords:Be}}o.bech32=be("bech32"),o.bech32m=be("bech32m"),o.utf8={encode:De=>(new TextDecoder).decode(De),decode:De=>(new TextEncoder).encode(De)},o.hex=r(O(4),i("0123456789abcdef"),a(""),y(De=>{if("string"!=typeof De||De.length%2)throw new TypeError(`hex.decode: expected string, got ${typeof De} with length ${De.length}`);return De.toLowerCase()}));const Oe={utf8:o.utf8,hex:o.hex,base16:o.base16,base32:o.base32,base64:o.base64,base64url:o.base64url,base58:o.base58,base58xmr:o.base58xmr},xe=`Invalid encoding type. Available types: ${Object.keys(Oe).join(", ")}`;o.bytesToString=(De,ce)=>{if("string"!=typeof De||!Oe.hasOwnProperty(De))throw new TypeError(xe);if(!(ce instanceof Uint8Array))throw new TypeError("bytesToString() expects Uint8Array");return Oe[De].encode(ce)},o.str=o.bytesToString,o.stringToBytes=(De,ce)=>{if(!Oe.hasOwnProperty(De))throw new TypeError(xe);if("string"!=typeof ce)throw new TypeError("stringToBytes() expects string");return Oe[De].decode(ce)},o.bytes=o.stringToBytes})(lib),BigInt(1e3),BigInt(1e6),BigInt(1e9),BigInt(1e12),BigInt("2100000000000000000"),BigInt(1e11);const TAGCODES={payment_hash:1,payment_secret:16,description:13,payee:19,description_hash:23,expiry:6,min_final_cltv_expiry:24,fallback_address:9,route_hint:3,feature_bits:5,metadata:27};for(let o=0,s=Object.keys(TAGCODES);othis.handleNotice(s))}initiateAuth(o={limit:1}){var s=this;return(0,_home_runner_work_angor_hub_angor_hub_node_modules_angular_builders_custom_webpack_node_modules_babel_runtime_helpers_esm_asyncToGenerator_js__WEBPACK_IMPORTED_MODULE_1__.A)(function*(){s.debug("Initiating authentication");const r=s.relay.sub([o],{id:"auth-test"});r.on("eose",()=>{r.unsub(),s._status=1,s.ndkRelay.emit("ready"),s.debug("Authentication not required"),r.unsub()}),s.debug("Authentication request started")})()}connect(){var o=this;return(0,_home_runner_work_angor_hub_angor_hub_node_modules_angular_builders_custom_webpack_node_modules_babel_runtime_helpers_esm_asyncToGenerator_js__WEBPACK_IMPORTED_MODULE_1__.A)(function*(){const s=()=>{o.updateConnectionStats.connected(),o.ndkRelay.authRequired?(o._status=6,o.ndkRelay.emit("connect"),o.initiateAuth()):(o._status=1,o.ndkRelay.emit("connect"),o.ndkRelay.emit("ready"))},r=()=>{o.updateConnectionStats.disconnected(),1===o._status&&(o._status=3,o.handleReconnection()),o.ndkRelay.emit("disconnect")},i=function(){var a=(0,_home_runner_work_angor_hub_angor_hub_node_modules_angular_builders_custom_webpack_node_modules_babel_runtime_helpers_esm_asyncToGenerator_js__WEBPACK_IMPORTED_MODULE_1__.A)(function*(c){o.debug("Relay requested authentication",{havePolicy:!!o.ndkRelay.authPolicy}),o.ndkRelay.authPolicy?7!==o._status&&(o._status=7,yield o.ndkRelay.authPolicy(o.ndkRelay,c),7===o._status&&(o.debug("Authentication policy finished"),o._status=1,o.ndkRelay.emit("ready"))):yield o.ndkRelay.emit("auth",c)});return function(y){return a.apply(this,arguments)}}();try{o.updateConnectionStats.attempt(),o._status=0,o.relay.off("connect",s),o.relay.off("disconnect",r),o.relay.on("connect",s),o.relay.on("disconnect",r),o.relay.on("auth",i),yield o.relay.connect()}catch(a){throw o.debug("Failed to connect",a),o._status=3,a}})()}disconnect(){this._status=2,this.relay.close()}get status(){return this._status}isAvailable(){return 1===this._status}isFlapping(){const o=this._connectionStats.durations;if(o.length%3!=0)return!1;const s=o.reduce((i,a)=>i+a,0)/o.length,r=o.map(i=>Math.pow(i-s,2)).reduce((i,a)=>i+a,0)/o.length;return Math.sqrt(r)<1e3}handleNotice(o){var s=this;return(0,_home_runner_work_angor_hub_angor_hub_node_modules_angular_builders_custom_webpack_node_modules_babel_runtime_helpers_esm_asyncToGenerator_js__WEBPACK_IMPORTED_MODULE_1__.A)(function*(){(o.includes("oo many")||o.includes("aximum"))&&(s.disconnect(),setTimeout(()=>s.connect(),2e3),s.debug(s.relay.url,"Relay complaining?",o)),s.ndkRelay.emit("notice",s,o)})()}handleReconnection(o=0){if(this.isFlapping())return this.ndkRelay.emit("flapping",this,this._connectionStats),void(this._status=5);const s=this.connectedAt?Math.max(0,6e4-(Date.now()-this.connectedAt)):0;setTimeout(()=>{this._status=4,this.connect().then(()=>{this.debug("Reconnected")}).catch(r=>{this.debug("Reconnect failed",r),o<5?setTimeout(()=>{this.handleReconnection(o+1)},6e4):this.debug("Reconnect failed after 5 attempts")})},s)}updateConnectionStats={connected:()=>{this._connectionStats.success++,this._connectionStats.connectedAt=Date.now()},disconnected:()=>{this._connectionStats.connectedAt&&(this._connectionStats.durations.push(Date.now()-this._connectionStats.connectedAt),this._connectionStats.durations.length>100&&this._connectionStats.durations.shift()),this._connectionStats.connectedAt=void 0},attempt:()=>{this._connectionStats.attempts++}};get connectionStats(){return this._connectionStats}},NDKRelayPublisher=class{ndkRelay;constructor(o){this.ndkRelay=o}publish(o,s=2500){var r=this;return(0,_home_runner_work_angor_hub_angor_hub_node_modules_angular_builders_custom_webpack_node_modules_babel_runtime_helpers_esm_asyncToGenerator_js__WEBPACK_IMPORTED_MODULE_1__.A)(function*(){const i=()=>new Promise((C,T)=>{try{r.publishEvent(o,s).then(S=>C(S)).catch(S=>T(S))}catch(S){T(S)}}),a=new Promise((C,T)=>{setTimeout(()=>T(new Error("Timeout")),s)}),c=()=>{i().then(C=>y(C)).catch(C=>w(C))};let y,w;return 1===r.ndkRelay.status?Promise.race([i(),a]):Promise.race([new Promise((C,T)=>{y=C,w=T,r.ndkRelay.once("connect",c)}),a]).finally(()=>{r.ndkRelay.removeListener("connect",c)})})()}publishEvent(o,s){var r=this;return(0,_home_runner_work_angor_hub_angor_hub_node_modules_angular_builders_custom_webpack_node_modules_babel_runtime_helpers_esm_asyncToGenerator_js__WEBPACK_IMPORTED_MODULE_1__.A)(function*(){const i=yield o.toNostrEvent(),a=r.ndkRelay.connectivity.relay.publish(i);let c;const y=new Promise((C,T)=>{a.then(()=>{clearTimeout(c),r.ndkRelay.emit("published",o),C(!0)}).catch(S=>{clearTimeout(c),r.ndkRelay.debug("Publish failed",S,o.id),r.ndkRelay.emit("publish:failed",o,S),T(S)})});if(!s||o.isEphemeral())return y;const w=new Promise((C,T)=>{c=setTimeout(()=>{r.ndkRelay.debug("Publish timed out",o.rawEvent()),r.ndkRelay.emit("publish:failed",o,"Timeout"),T(new Error("Publish operation timed out"))},s)});return Promise.race([y,w])})()}auth(o){var s=this;return(0,_home_runner_work_angor_hub_angor_hub_node_modules_angular_builders_custom_webpack_node_modules_babel_runtime_helpers_esm_asyncToGenerator_js__WEBPACK_IMPORTED_MODULE_1__.A)(function*(){return s.ndkRelay.connectivity.relay.auth(o.rawEvent())})()}};function calculateGroupableId(o){const s=[];for(const r of o){if(r.since||r.until)return null;const i=Object.keys(r||{}).sort().join("-");s.push(i)}return s.join("|")}function mergeFilters(o){const s={};return o.forEach(r=>{Object.entries(r).forEach(([i,a])=>{s[i]=Array.isArray(a)?void 0===s[i]?[...a]:Array.from(new Set([...s[i],...a])):a})}),s}var MAX_SUBID_LENGTH=20;function queryFullyFilled(o){return!(!filterIncludesIds(o.filter)||!resultHasAllRequestedIds(o))}function compareFilter(o,s){if(Object.keys(o).length!==Object.keys(s).length)return!1;for(const[r,i]of Object.entries(o)){const a=s[r];if(!a)return!1;if(Array.isArray(i)&&Array.isArray(a)){const c=i;for(const y of a)if(!c.includes(y))return!1}else if(a!==i)return!1}return!0}function filterIncludesIds(o){return!!o.ids}function resultHasAllRequestedIds(o){const s=o.filter.ids;return!!s&&s.length===o.eventFirstSeen.size}function generateSubId(o,s){const r=o.map(w=>w.subId).filter(Boolean),i=[],a=new Set,c=new Set;if(r.length>0)i.push(Array.from(new Set(r)).join(","));else{for(const w of s)for(const C of Object.keys(w))"kinds"===C?w.kinds?.forEach(T=>c.add(T)):a.add(C);c.size>0&&i.push("kinds:"+Array.from(c).join(",")),a.size>0&&i.push(Array.from(a).join(","))}let y=i.join("-");return y.length>MAX_SUBID_LENGTH&&(y=y.substring(0,MAX_SUBID_LENGTH)),1!==r.length&&(y+="-"+Math.floor(999*Math.random()).toString()),y}function filterFromId(o){let s;if(o.match(NIP33_A_REGEX)){const[r,i,a]=o.split(":"),c={authors:[i],kinds:[parseInt(r)]};return a&&(c["#d"]=[a]),c}try{switch(s=nip19_exports.decode(o),s.type){case"nevent":return{ids:[s.data.id]};case"note":return{ids:[s.data]};case"naddr":return{authors:[s.data.pubkey],"#d":[s.data.identifier],kinds:[s.data.kind]}}}catch{}return{ids:[o]}}function isNip33AValue(o){return null!==o.match(NIP33_A_REGEX)}var NIP33_A_REGEX=/^(\d+):([0-9A-Fa-f]+)(?::(.*))?$/;function relaysFromBech32(o){try{const s=nip19_exports.decode(o);if(["naddr","nevent"].includes(s?.type)){const r=s.data;if(r?.relays)return r.relays.map(i=>new NDKRelay(i))}}catch{}return[]}var NDKGroupedSubscriptions=class extends lib$1.EventEmitter{subscriptions;req;debug;constructor(o,s){super(),this.subscriptions=o,this.debug=s||this.subscriptions[0].subscription.debug.extend("grouped");for(const r of o)this.handleSubscriptionClosure(r)}addSubscription(o){this.subscriptions.push(o),this.handleSubscriptionClosure(o)}eventReceived(o){for(const s of this.subscriptions)s.eventReceived(o)}eoseReceived(o){Array.from(this.subscriptions).forEach(function(){var s=(0,_home_runner_work_angor_hub_angor_hub_node_modules_angular_builders_custom_webpack_node_modules_babel_runtime_helpers_esm_asyncToGenerator_js__WEBPACK_IMPORTED_MODULE_1__.A)(function*(r){r.subscription.eoseReceived(o)});return function(r){return s.apply(this,arguments)}}())}handleSubscriptionClosure(o){o.subscription.on("close",()=>{const s=this.subscriptions.findIndex(r=>r.subscription===o.subscription);this.subscriptions.splice(s,1),this.subscriptions.length<=0&&this.emit("close")})}map(o){return this.subscriptions.map(o)}[Symbol.iterator](){let o=0;const s=this.subscriptions;return{next:()=>omatchFilter(r,s))}};function findMatchingActiveSubscriptions(o,s){if(o.length!==s.length)return!1;for(let r=0;r{this.delayedItems.get(r)&&this.delayedItems.delete(r)}));let y=this.executionTimeoutsByGroupId.get(r);y&&"at-most"!==o.opts.groupableDelayType||(y=setTimeout(()=>{this.executeGroup(r,o)},o.opts.groupableDelay),this.executionTimeoutsByGroupId.set(r,y)),this.delayedTimers.has(r)?this.delayedTimers.get(r).push(y):this.delayedTimers.set(r,[y])}executeGroup(o,s){const r=this.delayedItems.get(o);this.delayedItems.delete(o);const i=this.delayedTimers.get(o);if(this.delayedTimers.delete(o),i)for(const a of i)clearTimeout(a);if(r){const a=r.subscriptions[0].filters.length,c=[];for(let y=0;yC.filters[y]);c.push(mergeFilters(w))}this.executeSubscriptions(o,r,c)}}executeSubscriptionsWhenConnected(o,s,r){const i=()=>{this.debug("new relay coming online for active subscription",{relay:this.ndkRelay.url,mergeFilters}),this.executeSubscriptionsConnected(o,s,r)};this.ndkRelay.once("ready",i),s.once("close",()=>{this.ndkRelay.removeListener("ready",i)})}executeSubscriptions(o,s,r){this.conn.isAvailable()?this.executeSubscriptionsConnected(o,s,r):this.executeSubscriptionsWhenConnected(o,s,r)}executeSubscriptionsConnected(o,s,r){const i=[];for(const{subscription:w}of s)i.push(w);const a=generateSubId(i,r);s.req=r;const c={id:a};(this.ndkRelay.trusted||i.every(w=>w.opts.skipVerification))&&(c.skipVerification=!0);const y=this.conn.relay.sub(r,c);return this.activeSubscriptions.set(y,s),o&&this.activeSubscriptionsByGroupId.set(o,{filters:r,sub:y}),y.on("event",w=>{const C=new NDKEvent(void 0,w);C.relay=this.ndkRelay,this.activeSubscriptions.get(y)?.eventReceived(C)}),y.on("eose",()=>{this.activeSubscriptions.get(y)?.eoseReceived(this.ndkRelay)}),s.once("close",()=>{y.unsub(),this.activeSubscriptions.delete(y),o&&this.activeSubscriptionsByGroupId.delete(o)}),this.executeSubscriptionsWhenConnected(o,s,r),y}executedFilters(){const o=new Map;for(const[,s]of this.activeSubscriptions)o.set(s.req,s.map(r=>r.subscription));return o}},NDKRelay=class extends lib$1.EventEmitter{url;scores;connectivity;subs;publisher;authPolicy;authRequired=!1;trusted=!1;complaining=!1;debug;constructor(o,s){super(),this.url=o,this.scores=new Map,this.debug=debug3(`ndk:relay:${o}`),this.connectivity=new NDKRelayConnectivity(this),this.subs=new NDKRelaySubscriptions(this),this.publisher=new NDKRelayPublisher(this),this.authPolicy=s}get status(){return this.connectivity.status}get connectionStats(){return this.connectivity.connectionStats}connect(){var o=this;return(0,_home_runner_work_angor_hub_angor_hub_node_modules_angular_builders_custom_webpack_node_modules_babel_runtime_helpers_esm_asyncToGenerator_js__WEBPACK_IMPORTED_MODULE_1__.A)(function*(){return o.connectivity.connect()})()}disconnect(){3!==this.status&&this.connectivity.disconnect()}subscribe(o,s){this.subs.subscribe(o,s)}publish(o,s=2500){var r=this;return(0,_home_runner_work_angor_hub_angor_hub_node_modules_angular_builders_custom_webpack_node_modules_babel_runtime_helpers_esm_asyncToGenerator_js__WEBPACK_IMPORTED_MODULE_1__.A)(function*(){return r.publisher.publish(o,s)})()}auth(o){var s=this;return(0,_home_runner_work_angor_hub_angor_hub_node_modules_angular_builders_custom_webpack_node_modules_babel_runtime_helpers_esm_asyncToGenerator_js__WEBPACK_IMPORTED_MODULE_1__.A)(function*(){return s.publisher.auth(o)})()}scoreSlowerEvent(o){}tagReference(o){const s=["r",this.url];return o&&s.push(o),s}referenceTags(){return[["r",this.url]]}activeSubscriptions(){return this.subs.executedFilters()}},PublishError=class extends Error{errors;constructor(o,s){super(o),this.errors=s}},NDKRelaySet=class dD{relays;debug;ndk;constructor(s,r){this.relays=s,this.ndk=r,this.debug=r.debug.extend("relayset")}addRelay(s){this.relays.add(s)}static fromRelayUrls(s,r){const i=new Set;for(const a of s){const c=r.pool.relays.get(a);if(c)i.add(c);else{const y=new NDKRelay(a);r.pool.useTemporaryRelay(y),i.add(y)}}return new dD(new Set(i),r)}publish(s,r){var i=this;return(0,_home_runner_work_angor_hub_angor_hub_node_modules_angular_builders_custom_webpack_node_modules_babel_runtime_helpers_esm_asyncToGenerator_js__WEBPACK_IMPORTED_MODULE_1__.A)(function*(){const a=new Set,c=new Map,y=s.isEphemeral(),w=Array.from(i.relays).map(C=>new Promise(T=>{C.publish(s,r).then(()=>{a.add(C),T()}).catch(S=>{y||(c.set(C,S),i.debug("error publishing to relay",{relay:C.url,err:S})),T()})}));if(yield Promise.all(w),0===a.size&&!y)throw new PublishError("No relay was able to receive the event",c);return a})()}size(){return this.relays.size}};function calculateRelaySetFromEvent(o,s){const r=new Set;return o.pool?.relays.forEach(i=>r.add(i)),new NDKRelaySet(r,o)}function getWriteRelaysFor(o,s){if(o.outboxTracker)return o.outboxTracker.data.get(s)?.writeRelays}function calculateRelaySetsFromFilter(o,s){const r=new Map,i=new Set;if(s.forEach(a=>{a.authors&&a.authors.forEach(c=>i.add(c))}),i.size>0){const a=new Map;for(const c of i){const y=getWriteRelaysFor(o,c);y&&y.size>0?(o.debug(`Adding ${y.size} relays for ${c}`),y.forEach(w=>{const C=a.get(w)||[];C.push(c),a.set(w,C)})):o.explicitRelayUrls?.forEach(w=>{const C=a.get(w)||[];C.push(c),a.set(w,C)})}for(const c of a.keys())r.set(c,[]);for(const c of s)if(c.authors)for(const[y,w]of a.entries()){const C=c.authors.filter(T=>w.includes(T));r.set(y,[...r.get(y),{...c,authors:C}])}else for(const y of a.keys())r.set(y,[...r.get(y),c])}else o.explicitRelayUrls?.forEach(a=>{r.set(a,s)});return r}function calculateRelaySetsFromFilters(o,s){return calculateRelaySetsFromFilter(o,s)}var DEFAULT_RELAYS=["wss://nos.lol","wss://relay.nostr.band","wss://relay.f7z.io","wss://relay.damus.io","wss://nostr.mom","wss://no.str.cr"],Zap=class extends lib$1.EventEmitter{ndk;zappedEvent;zappedUser;constructor(o){super(),this.ndk=o.ndk,this.zappedEvent=o.zappedEvent,this.zappedUser=o.zappedUser||this.ndk.getUser({hexpubkey:this.zappedEvent?.pubkey})}getZapEndpoint(){var o=this;return(0,_home_runner_work_angor_hub_angor_hub_node_modules_angular_builders_custom_webpack_node_modules_babel_runtime_helpers_esm_asyncToGenerator_js__WEBPACK_IMPORTED_MODULE_1__.A)(function*(){let s,r,i,a;if(o.zappedUser&&(o.zappedUser.profile||(yield o.zappedUser.fetchProfile({groupable:!1})),s=(o.zappedUser.profile||{}).lud06,r=(o.zappedUser.profile||{}).lud16),r&&!r.startsWith("LNURL")){const[c,y]=r.split("@");i=`https://${y}/.well-known/lnurlp/${c}`}else if(s){const{words:c}=bech32.decode(s,1e3),y=bech32.fromWords(c);i=new TextDecoder("utf-8").decode(y)}if(!i)throw new Error("No zap endpoint found");try{const c=o.ndk.httpFetch||fetch,y=yield c(i);if(200!==y.status){const C=yield y.text();throw new Error(`Unable to fetch zap endpoint ${i}: ${C}`)}const w=yield y.json();return w?.allowsNostr&&(w?.nostrPubkey||w?.nostrPubKey)&&(a=w.callback),a}catch(c){throw new Error(`Unable to fetch zap endpoint ${i}: ${c}`)}})()}createZapRequest(o,s,r,i,a){var c=this;return(0,_home_runner_work_angor_hub_angor_hub_node_modules_angular_builders_custom_webpack_node_modules_babel_runtime_helpers_esm_asyncToGenerator_js__WEBPACK_IMPORTED_MODULE_1__.A)(function*(){const y=yield c.generateZapRequest(o,s,r,i);if(!y)return null;const{event:w,zapEndpoint:C}=y;if(!w)throw new Error("No zap request event found");let T;yield w.sign(a);try{T=yield c.getInvoice(w,o,C)}catch(S){throw new Error("Failed to get invoice: "+S)}return T})()}getInvoice(o,s,r){return(0,_home_runner_work_angor_hub_angor_hub_node_modules_angular_builders_custom_webpack_node_modules_babel_runtime_helpers_esm_asyncToGenerator_js__WEBPACK_IMPORTED_MODULE_1__.A)(function*(){return(yield(yield fetch(`${r}?`+new URLSearchParams({amount:s.toString(),nostr:JSON.stringify(o.rawEvent())}))).json()).pr})()}generateZapRequest(o,s,r,i,a){var c=this;return(0,_home_runner_work_angor_hub_angor_hub_node_modules_angular_builders_custom_webpack_node_modules_babel_runtime_helpers_esm_asyncToGenerator_js__WEBPACK_IMPORTED_MODULE_1__.A)(function*(){const y=yield c.getZapEndpoint();if(!y)throw new Error("No zap endpoint found");if(!c.zappedEvent&&!c.zappedUser)throw new Error("No zapped event or user found");const w=nip57_exports.makeZapRequest({profile:c.zappedUser.pubkey,event:null,amount:o,comment:s||"",relays:i??c.relays()});if(c.zappedEvent){const T=c.zappedEvent.referenceTags();w.tags.push(...T)}w.tags.push(["lnurl",y]);const C=new NDKEvent(c.ndk,w);return r&&(C.tags=C.tags.concat(r)),{event:C,zapEndpoint:y}})()}relays(){let o=[];return this.ndk?.pool?.relays&&(o=this.ndk.pool.urls()),o.length||(o=DEFAULT_RELAYS),o}};function mergeTags(o,s){const r=new Map,i=(a,c)=>a.every((y,w)=>y===c[w]);return o.concat(s).forEach(a=>{for(let[c,y]of r)if(i(y,a)||i(a,y))return void(a.length>=y.length&&r.set(c,a));r.set(a.join(","),a)}),Array.from(r.values())}function generateContentTags(o){return _generateContentTags.apply(this,arguments)}function _generateContentTags(){return _generateContentTags=(0,_home_runner_work_angor_hub_angor_hub_node_modules_angular_builders_custom_webpack_node_modules_babel_runtime_helpers_esm_asyncToGenerator_js__WEBPACK_IMPORTED_MODULE_1__.A)(function*(o,s=[]){let r=[];const i=a=>{s.find(c=>c[0]===a[0]&&c[1]===a[1])||s.push(a)};return o=o.replace(/(@|nostr:)(npub|nprofile|note|nevent|naddr)[a-zA-Z0-9]+/g,a=>{try{const c=a.split(/(@|nostr:)/)[2],{type:y,data:w}=nip19_exports.decode(c);let C;switch(y){case"npub":C=["p",w];break;case"nprofile":C=["p",w.pubkey];break;case"note":r.push(new Promise(function(){var T=(0,_home_runner_work_angor_hub_angor_hub_node_modules_angular_builders_custom_webpack_node_modules_babel_runtime_helpers_esm_asyncToGenerator_js__WEBPACK_IMPORTED_MODULE_1__.A)(function*(S){i(["e",w,yield maybeGetEventRelayUrl(c),"mention"]),S()});return function(S){return T.apply(this,arguments)}}()));break;case"nevent":r.push(new Promise(function(){var T=(0,_home_runner_work_angor_hub_angor_hub_node_modules_angular_builders_custom_webpack_node_modules_babel_runtime_helpers_esm_asyncToGenerator_js__WEBPACK_IMPORTED_MODULE_1__.A)(function*(S){let{id:M,relays:O,author:L}=w;O&&0!==O.length||(O=[yield maybeGetEventRelayUrl(c)]),i(["e",M,O[0],"mention"]),L&&i(["p",L]),S()});return function(S){return T.apply(this,arguments)}}()));break;case"naddr":r.push(new Promise(function(){var T=(0,_home_runner_work_angor_hub_angor_hub_node_modules_angular_builders_custom_webpack_node_modules_babel_runtime_helpers_esm_asyncToGenerator_js__WEBPACK_IMPORTED_MODULE_1__.A)(function*(S){const M=[w.kind,w.pubkey,w.identifier].join(":");let O=w.relays??[];0===O.length&&(O=[yield maybeGetEventRelayUrl(c)]),i(["a",M,O[0],"mention"]),i(["p",w.pubkey]),S()});return function(S){return T.apply(this,arguments)}}()));break;default:return a}return C&&i(C),`nostr:${c}`}catch{return a}}),yield Promise.all(r),{content:o=o.replace(/#(\w+)/g,(a,c)=>{const y=["t",c];return s.find(w=>w[0]===y[0]&&w[1]===y[1])||s.push(y),a}),tags:s}}),_generateContentTags.apply(this,arguments)}function maybeGetEventRelayUrl(o){return _maybeGetEventRelayUrl.apply(this,arguments)}function _maybeGetEventRelayUrl(){return(_maybeGetEventRelayUrl=(0,_home_runner_work_angor_hub_angor_hub_node_modules_angular_builders_custom_webpack_node_modules_babel_runtime_helpers_esm_asyncToGenerator_js__WEBPACK_IMPORTED_MODULE_1__.A)(function*(o){return""})).apply(this,arguments)}function isReplaceable(){if(void 0===this.kind)throw new Error("Kind not set");return this.kind>=1e4&&this.kind<2e4}function isEphemeral(){if(void 0===this.kind)throw new Error("Kind not set");return this.kind>=2e4&&this.kind<3e4}function isParamReplaceable(){if(void 0===this.kind)throw new Error("Kind not set");return this.kind>=3e4&&this.kind<4e4}function encrypt(o,s){return _encrypt.apply(this,arguments)}function _encrypt(){return _encrypt=(0,_home_runner_work_angor_hub_angor_hub_node_modules_angular_builders_custom_webpack_node_modules_babel_runtime_helpers_esm_asyncToGenerator_js__WEBPACK_IMPORTED_MODULE_1__.A)(function*(o,s){if(!this.ndk)throw new Error("No NDK instance found!");if(s||(yield this.ndk.assertSigner(),s=this.ndk.signer),!o){const r=this.getMatchingTags("p");if(1!==r.length)throw new Error("No recipient could be determined and no explicit recipient was provided");o=this.ndk.getUser({hexpubkey:r[0][1]})}this.content=yield s?.encrypt(o,this.content)}),_encrypt.apply(this,arguments)}function decrypt(o,s){return _decrypt.apply(this,arguments)}function _decrypt(){return _decrypt=(0,_home_runner_work_angor_hub_angor_hub_node_modules_angular_builders_custom_webpack_node_modules_babel_runtime_helpers_esm_asyncToGenerator_js__WEBPACK_IMPORTED_MODULE_1__.A)(function*(o,s){if(!this.ndk)throw new Error("No NDK instance found!");s||(yield this.ndk.assertSigner(),s=this.ndk.signer),o||(o=this.author),this.content=yield s?.decrypt(o,this.content)}),_decrypt.apply(this,arguments)}function encode(){return this.isParamReplaceable()?nip19_exports.naddrEncode({kind:this.kind,pubkey:this.pubkey,identifier:this.replaceableDTag(),relays:this.relay?[this.relay.url]:[]}):this.relay?nip19_exports.neventEncode({id:this.tagId(),relays:[this.relay.url],author:this.pubkey}):nip19_exports.noteEncode(this.tagId())}function repost(){return _repost.apply(this,arguments)}function _repost(){return _repost=(0,_home_runner_work_angor_hub_angor_hub_node_modules_angular_builders_custom_webpack_node_modules_babel_runtime_helpers_esm_asyncToGenerator_js__WEBPACK_IMPORTED_MODULE_1__.A)(function*(o=!0,s){if(!s&&o){if(!this.ndk)throw new Error("No NDK instance found");this.ndk.assertSigner(),s=this.ndk.signer}const r=new NDKEvent(this.ndk,{kind:getKind(this),content:""});return r.tag(this),16===r.kind&&r.tags.push(["k",`${this.kind}`]),s&&(yield r.sign(s)),o&&(yield r.publish()),r}),_repost.apply(this,arguments)}function getKind(o){return 1===o.kind?6:16}var NDKEvent=class iy extends lib$1.EventEmitter{ndk;created_at;content="";tags=[];kind;id="";sig;pubkey="";_author=void 0;relay;constructor(s,r){super(),this.ndk=s,this.created_at=r?.created_at,this.content=r?.content||"",this.tags=r?.tags||[],this.id=r?.id||"",this.sig=r?.sig,this.pubkey=r?.pubkey||"",this.kind=r?.kind}rawEvent(){return{created_at:this.created_at,content:this.content,tags:this.tags,kind:this.kind,pubkey:this.pubkey,id:this.id,sig:this.sig}}set author(s){this.pubkey=s.hexpubkey,this._author=void 0}get author(){if(this._author)return this._author;if(!this.ndk)throw new Error("No NDK instance found");const s=this.ndk.getUser({hexpubkey:this.pubkey});return this._author=s,s}tag(s,r){let i=[];if(s instanceof NDKUser){const a=["p",s.pubkey];r&&a.push(r),i.push(a)}else if(s instanceof iy){const a=s;i=a.referenceTags(r,a?.pubkey===this.pubkey);for(const y of a.getMatchingTags("p"))y[1]!==this.pubkey&&(this.tags.find(w=>"p"===w[0]&&w[1]===y[1])||this.tags.push(["p",y[1]]))}else i=[s];this.tags=mergeTags(this.tags,i)}toNostrEvent(s){var r=this;return(0,_home_runner_work_angor_hub_angor_hub_node_modules_angular_builders_custom_webpack_node_modules_babel_runtime_helpers_esm_asyncToGenerator_js__WEBPACK_IMPORTED_MODULE_1__.A)(function*(){if(!s&&""===r.pubkey){const y=yield r.ndk?.signer?.user();r.pubkey=y?.hexpubkey||""}r.created_at||(r.created_at=Math.floor(Date.now()/1e3));const i=r.rawEvent(),{content:a,tags:c}=yield r.generateTags();i.content=a||"",i.tags=c;try{r.id=getEventHash(i)}catch{}return r.id&&(i.id=r.id),r.sig&&(i.sig=r.sig),i})()}isReplaceable=isReplaceable.bind(this);isEphemeral=isEphemeral.bind(this);isParamReplaceable=isParamReplaceable.bind(this);encode=encode.bind(this);encrypt=encrypt.bind(this);decrypt=decrypt.bind(this);getMatchingTags(s){return this.tags.filter(r=>r[0]===s)}tagValue(s){const r=this.getMatchingTags(s);if(0!==r.length)return r[0][1]}get alt(){return this.tagValue("alt")}set alt(s){this.removeTag("alt"),s&&this.tags.push(["alt",s])}removeTag(s){this.tags=this.tags.filter(r=>r[0]!==s)}sign(s){var r=this;return(0,_home_runner_work_angor_hub_angor_hub_node_modules_angular_builders_custom_webpack_node_modules_babel_runtime_helpers_esm_asyncToGenerator_js__WEBPACK_IMPORTED_MODULE_1__.A)(function*(){s?r.author=yield s.user():(r.ndk?.assertSigner(),s=r.ndk.signer),yield r.generateTags(),r.isReplaceable()&&(r.created_at=Math.floor(Date.now()/1e3));const i=yield r.toNostrEvent();return r.sig=yield s.sign(i),r.sig})()}publish(s,r){var i=this;return(0,_home_runner_work_angor_hub_angor_hub_node_modules_angular_builders_custom_webpack_node_modules_babel_runtime_helpers_esm_asyncToGenerator_js__WEBPACK_IMPORTED_MODULE_1__.A)(function*(){if(i.sig||(yield i.sign()),!i.ndk)throw new Error("NDKEvent must be associated with an NDK instance to publish");return s||(s=i.ndk.devWriteRelaySet||calculateRelaySetFromEvent(i.ndk)),s.publish(i,r)})()}generateTags(){var s=this;return(0,_home_runner_work_angor_hub_angor_hub_node_modules_angular_builders_custom_webpack_node_modules_babel_runtime_helpers_esm_asyncToGenerator_js__WEBPACK_IMPORTED_MODULE_1__.A)(function*(){let r=[];const i=yield generateContentTags(s.content,s.tags),a=i.content;if(r=i.tags,s.kind&&s.isParamReplaceable()&&!s.getMatchingTags("d")[0]){const c=s.tagValue("title");let y=[...Array(c?6:16)].map(()=>Math.random().toString(36)[2]).join("");c&&c.length>0&&(y=c.replace(/[^a-z0-9]+/gi,"-").replace(/^-|-$/g,"")+"-"+y),r.push(["d",y])}if((s.ndk?.clientName||s.ndk?.clientNip89)&&!s.tagValue("client")){const c=["client",s.ndk.clientName??""];s.ndk.clientNip89&&c.push(s.ndk.clientNip89),r.push(c)}return{content:a||"",tags:r}})()}muted(){const s=this.ndk?.mutedIds.get(this.pubkey);if(s&&"p"===s)return"author";const r=this.tagReference(),i=this.ndk?.mutedIds.get(r[1]);return i&&i===r[0]?"event":null}replaceableDTag(){if(this.kind&&this.kind>=3e4&&this.kind<=4e4){const s=this.getMatchingTags("d")[0];return s?s[1]:""}throw new Error("Event is not a parameterized replaceable event")}deduplicationKey(){return 0===this.kind||3===this.kind||this.kind&&this.kind>=1e4&&this.kind<2e4?`${this.kind}:${this.pubkey}`:this.tagId()}tagId(){return this.isParamReplaceable()?this.tagAddress():this.id}tagAddress(){if(!this.isParamReplaceable())throw new Error("This must only be called on replaceable events");const s=this.replaceableDTag();return`${this.kind}:${this.pubkey}:${s}`}tagReference(s){let r;return r=this.isParamReplaceable()?["a",this.tagAddress()]:["e",this.tagId()],r.push(this.relay?this.relay.url:""),s&&r.push(s),r}referenceTags(s,r){let i=[];return i=this.isParamReplaceable()?[["a",this.tagAddress()],["e",this.id]]:[["e",this.id]],this.relay?.url?i=i.map(a=>(a.push(this.relay?.url),a)):s&&(i=i.map(a=>(a.push(""),a))),s&&i.forEach(a=>a.push(s)),r||i.push(...this.author.referenceTags()),i}filter(){return this.isParamReplaceable()?{"#a":[this.tagId()]}:{"#e":[this.tagId()]}}zap(s,r,i,a,c){var y=this;return(0,_home_runner_work_angor_hub_angor_hub_node_modules_angular_builders_custom_webpack_node_modules_babel_runtime_helpers_esm_asyncToGenerator_js__WEBPACK_IMPORTED_MODULE_1__.A)(function*(){if(!y.ndk)throw new Error("No NDK instance found");c||y.ndk.assertSigner();const w=new Zap({ndk:y.ndk,zappedEvent:y,zappedUser:a}),C=Array.from(y.ndk.pool.relays.keys());return yield w.createZapRequest(s,r,i,C,c)})()}delete(s){var r=this;return(0,_home_runner_work_angor_hub_angor_hub_node_modules_angular_builders_custom_webpack_node_modules_babel_runtime_helpers_esm_asyncToGenerator_js__WEBPACK_IMPORTED_MODULE_1__.A)(function*(){if(!r.ndk)throw new Error("No NDK instance found");r.ndk.assertSigner();const i=new iy(r.ndk,{kind:5,content:s||""});return i.tag(r),yield i.publish(),i})()}repost=repost.bind(this);react(s,r=!0){var i=this;return(0,_home_runner_work_angor_hub_angor_hub_node_modules_angular_builders_custom_webpack_node_modules_babel_runtime_helpers_esm_asyncToGenerator_js__WEBPACK_IMPORTED_MODULE_1__.A)(function*(){if(!i.ndk)throw new Error("No NDK instance found");i.ndk.assertSigner();const a=new iy(i.ndk,{kind:7,content:s});return a.tag(i),r?yield a.publish():yield a.sign(),a})()}get isValid(){return!0}},READ_MARKER="read",WRITE_MARKER="write",NDKRelayList=class hD extends NDKEvent{constructor(s,r){super(s,r),this.kind??=10002}static from(s){return new hD(s.ndk,s.rawEvent())}get readRelayUrls(){return this.getMatchingTags("r").filter(s=>!s[2]||s[2]&&s[2]===READ_MARKER).map(s=>s[1])}set readRelayUrls(s){for(const r of s)this.tags.push(["r",r,READ_MARKER])}get writeRelayUrls(){return this.getMatchingTags("r").filter(s=>!s[2]||s[2]&&s[2]===WRITE_MARKER).map(s=>s[1])}set writeRelayUrls(s){for(const r of s)this.tags.push(["r",r,WRITE_MARKER])}get bothRelayUrls(){return this.getMatchingTags("r").filter(s=>!s[2]).map(s=>s[1])}set bothRelayUrls(s){for(const r of s)this.tags.push(["r",r])}get relays(){return this.getMatchingTags("r").map(s=>s[1])}},NDKSubscriptionCacheUsage=(o=>(o.ONLY_CACHE="ONLY_CACHE",o.CACHE_FIRST="CACHE_FIRST",o.PARALLEL="PARALLEL",o.ONLY_RELAY="ONLY_RELAY",o))(NDKSubscriptionCacheUsage||{}),defaultOpts={closeOnEose:!1,cacheUsage:"CACHE_FIRST",groupable:!0,groupableDelay:100,groupableDelayType:"at-most"},NDKSubscription=class extends lib$1.EventEmitter{subId;filters;opts;pool;skipVerification=!1;skipValidation=!1;relayFilters;relaySet;ndk;debug;eoseDebug;eventFirstSeen=new Map;eosesSeen=new Set;eventsPerRelay=new Map;lastEventReceivedAt;internalId;constructor(o,s,r,i,a){if(super(),this.ndk=o,this.pool=r?.pool||o.pool,this.opts={...defaultOpts,...r||{}},this.filters=s instanceof Array?s:[s],this.subId=a||r?.subId,this.internalId=Math.random().toString(36).substring(7),this.relaySet=i,this.debug=o.debug.extend(`subscription[${r?.subId??this.internalId}]`),this.eoseDebug=this.debug.extend("eose"),this.skipVerification=r?.skipVerification||!1,this.skipValidation=r?.skipValidation||!1,this.opts.closeOnEose||this.debug("Creating a permanent subscription",this.opts,JSON.stringify(this.filters)),"ONLY_CACHE"===this.opts.cacheUsage&&!this.opts.closeOnEose)throw new Error("Cannot use cache-only options with a persistent subscription")}get filter(){return this.filters[0]}isGroupable(){return this.opts?.groupable||!1}shouldQueryCache(){return"ONLY_RELAY"!==this.opts?.cacheUsage}shouldQueryRelays(){return"ONLY_CACHE"!==this.opts?.cacheUsage}shouldWaitForCache(){return this.opts.closeOnEose&&!!this.ndk.cacheAdapter?.locking&&"PARALLEL"!==this.opts.cacheUsage}start(){var o=this;return(0,_home_runner_work_angor_hub_angor_hub_node_modules_angular_builders_custom_webpack_node_modules_babel_runtime_helpers_esm_asyncToGenerator_js__WEBPACK_IMPORTED_MODULE_1__.A)(function*(){let s;o.shouldQueryCache()&&(s=o.startWithCache(),o.shouldWaitForCache()&&(yield s,queryFullyFilled(o)))?o.emit("eose",o):o.shouldQueryRelays()?o.startWithRelays():o.emit("eose",o)})()}stop(){this.emit("close",this),this.removeAllListeners()}hasAuthorsFilter(){return this.filters.some(o=>o.authors?.length)}startWithCache(){var o=this;return(0,_home_runner_work_angor_hub_angor_hub_node_modules_angular_builders_custom_webpack_node_modules_babel_runtime_helpers_esm_asyncToGenerator_js__WEBPACK_IMPORTED_MODULE_1__.A)(function*(){if(o.ndk.cacheAdapter?.query){const s=o.ndk.cacheAdapter.query(o);o.ndk.cacheAdapter.locking&&(yield s)}})()}startWithRelays(){if(this.relaySet){this.relayFilters=new Map;for(const o of this.relaySet.relays)this.relayFilters.set(o.url,this.filters)}else this.relayFilters=calculateRelaySetsFromFilters(this.ndk,this.filters);if(this.relayFilters&&0!==this.relayFilters.size)for(const[o,s]of this.relayFilters)this.pool.getRelay(o).subscribe(this,s);else this.debug("No relays to subscribe to",this.ndk.explicitRelayUrls)}eventReceived(o,s,r=!1){if(s&&(o.relay=s),s||(s=o.relay),this.skipValidation||o.isValid){if(!r&&s){let i=this.eventsPerRelay.get(s);if(i||(i=new Set,this.eventsPerRelay.set(s,i)),i.add(o.id),this.eventFirstSeen.has(o.id)){const a=Date.now()-(this.eventFirstSeen.get(o.id)||0);return s.scoreSlowerEvent(a),void this.emit("event:dup",o,s,a,this)}this.ndk.cacheAdapter&&this.ndk.cacheAdapter.setEvent(o,this.filters,s),this.eventFirstSeen.set(o.id,Date.now())}else this.eventFirstSeen.set(o.id,0);o.ndk||(o.ndk=this.ndk),this.emit("event",o,s,this),this.lastEventReceivedAt=Date.now()}else this.debug("Event failed validation",o)}eoseTimeout;eoseReceived(o){this.eosesSeen.add(o),this.eoseDebug(`received from ${o.url}`);let s=this.lastEventReceivedAt?Date.now()-this.lastEventReceivedAt:void 0;const r=this.eosesSeen.size===this.relayFilters?.size;if(queryFullyFilled(this))this.emit("eose"),this.eoseDebug("Query fully filled"),this.opts?.closeOnEose&&this.stop();else if(r)this.emit("eose"),this.eoseDebug("All EOSEs seen"),this.opts?.closeOnEose&&this.stop();else{let i=1e3;const a=this.eosesSeen.size/this.relayFilters.size;if(this.eosesSeen.size>=2&&a>=.5){i*=1-a,this.eoseTimeout&&clearTimeout(this.eoseTimeout);const c=()=>{s=this.lastEventReceivedAt?Date.now()-this.lastEventReceivedAt:void 0,void 0!==s&&s<20?this.eoseTimeout=setTimeout(c,i):(this.emit("eose"),this.opts?.closeOnEose&&this.stop())};this.eoseTimeout=setTimeout(c,i)}}}};function follows(o,s){return _follows.apply(this,arguments)}function _follows(){return _follows=(0,_home_runner_work_angor_hub_angor_hub_node_modules_angular_builders_custom_webpack_node_modules_babel_runtime_helpers_esm_asyncToGenerator_js__WEBPACK_IMPORTED_MODULE_1__.A)(function*(o,s,r=3){if(!this.ndk)throw new Error("NDK not set");const i=Array.from(yield this.ndk.fetchEvents({kinds:[r],authors:[this.pubkey]},o||{groupable:!1}))[0];if(i){const a=new Set;return i.tags.forEach(c=>{if("p"===c[0])try{a.add(c[1]),s&&this.ndk?.outboxTracker?.trackUsers([c[1]])}catch{}}),[...a].reduce((c,y)=>{const w=new NDKUser({pubkey:y});return w.ndk=this.ndk,c.add(w),c},new Set)}return new Set}),_follows.apply(this,arguments)}function profileFromEvent(o){const s={};let r;try{r=JSON.parse(o.content)}catch(i){throw new Error(`Failed to parse profile event: ${i}`)}return Object.keys(r).forEach(i=>{switch(i){case"name":s.name=r.name;break;case"display_name":s.displayName=r.display_name;break;case"image":case"picture":s.image=r.image||r.picture;break;case"banner":s.banner=r.banner;break;case"bio":s.bio=r.bio;break;case"nip05":s.nip05=r.nip05;break;case"lud06":s.lud06=r.lud06;break;case"lud16":s.lud16=r.lud16;break;case"about":s.about=r.about;break;case"zapService":s.zapService=r.zapService;break;case"website":s.website=r.website;break;default:s[i]=r[i]}}),s}function serializeProfile(o){const s={};for(const[r,i]of Object.entries(o))switch(r){case"username":case"name":s.name=i;break;case"displayName":s.display_name=i;break;case"image":case"picture":s.picture=i;break;case"bio":case"about":s.about=i;break;default:s[r]=i}return JSON.stringify(s)}var NDKList=class fD extends NDKEvent{_encryptedTags;encryptedTagsLength;constructor(s,r){super(s,r),this.kind??=30001}static from(s){return new fD(s.ndk,s.rawEvent())}get title(){const s=this.tagValue("title")||this.tagValue("name");return 3!==this.kind||s?1e4!==this.kind||s?10001!==this.kind||s?10002!==this.kind||s?10003!==this.kind||s?10004!==this.kind||s?10005!==this.kind||s?10006!==this.kind||s?10007!==this.kind||s?10015!==this.kind||s?10030!==this.kind||s?s??this.tagValue("d"):"Emojis":"Interests":"Search Relays":"Blocked Relays":"Public Chats":"Communities":"Bookmarks":"Relay Metadata":"Pinned Notes":"Mute":"Contacts"}set title(s){if(this.removeTag("title"),this.removeTag("name"),!s)throw new Error("Title cannot be empty");this.tags.push(["title",s])}get name(){const s=this.tagValue("name");return 3!==this.kind||s?1e4!==this.kind||s?10001!==this.kind||s?10002!==this.kind||s?10003!==this.kind||s?10004!==this.kind||s?10005!==this.kind||s?10006!==this.kind||s?10007!==this.kind||s?10015!==this.kind||s?10030!==this.kind||s?s??this.tagValue("d"):"Emojis":"Interests":"Search Relays":"Blocked Relays":"Public Chats":"Communities":"Bookmarks":"Relay Metadata":"Pinned Notes":"Mute":"Contacts"}set name(s){if(this.removeTag("name"),!s)throw new Error("Name cannot be empty");this.tags.push(["title",s])}get description(){return this.tagValue("description")}set description(s){s?this.tags.push(["description",s]):this.removeTag("description")}isEncryptedTagsCacheValid(){return!(!this._encryptedTags||this.encryptedTagsLength!==this.content.length)}encryptedTags(s=!0){var r=this;return(0,_home_runner_work_angor_hub_angor_hub_node_modules_angular_builders_custom_webpack_node_modules_babel_runtime_helpers_esm_asyncToGenerator_js__WEBPACK_IMPORTED_MODULE_1__.A)(function*(){if(s&&r.isEncryptedTagsCacheValid())return r._encryptedTags;if(!r.ndk)throw new Error("NDK instance not set");if(!r.ndk.signer)throw new Error("NDK signer not set");const i=yield r.ndk.signer.user();try{if(r.content.length>0)try{const a=yield r.ndk.signer.decrypt(i,r.content),c=JSON.parse(a);return c&&c[0]?(r.encryptedTagsLength=r.content.length,r._encryptedTags=c):(r.encryptedTagsLength=r.content.length,r._encryptedTags=[])}catch{console.log(`error decrypting ${r.content}`)}}catch{}return[]})()}validateTag(s){return!0}get items(){return this.tags.filter(s=>!["d","L","l","title","name","description","summary","image","thumb","alt","expiration","subject"].includes(s[0]))}addItem(s,r=void 0,i=!1){var a=this;return(0,_home_runner_work_angor_hub_angor_hub_node_modules_angular_builders_custom_webpack_node_modules_babel_runtime_helpers_esm_asyncToGenerator_js__WEBPACK_IMPORTED_MODULE_1__.A)(function*(){if(!a.ndk)throw new Error("NDK instance not set");if(!a.ndk.signer)throw new Error("NDK signer not set");let c;if(s instanceof NDKEvent)c=s.referenceTags();else if(s instanceof NDKUser)c=s.referenceTags();else if(s instanceof NDKRelay)c=s.referenceTags();else{if(!Array.isArray(s))throw new Error("Invalid object type");c=[s]}if(r&&c[0].push(r),i){const y=yield a.ndk.signer.user(),w=yield a.encryptedTags();w.push(...c),a._encryptedTags=w,a.encryptedTagsLength=a.content.length,a.content=JSON.stringify(w),yield a.encrypt(y)}else a.tags.push(...c);a.created_at=Math.floor(Date.now()/1e3),a.emit("change")})()}removeItem(s,r){var i=this;return(0,_home_runner_work_angor_hub_angor_hub_node_modules_angular_builders_custom_webpack_node_modules_babel_runtime_helpers_esm_asyncToGenerator_js__WEBPACK_IMPORTED_MODULE_1__.A)(function*(){if(!i.ndk)throw new Error("NDK instance not set");if(!i.ndk.signer)throw new Error("NDK signer not set");if(r){const a=yield i.ndk.signer.user(),c=yield i.encryptedTags();c.splice(s,1),i._encryptedTags=c,i.encryptedTagsLength=i.content.length,i.content=JSON.stringify(c),yield i.encrypt(a)}else i.tags.splice(s,1);return i.created_at=Math.floor(Date.now()/1e3),i.emit("change"),i})()}},lists_default=NDKList;function pin(o,s,r){return _pin.apply(this,arguments)}function _pin(){return _pin=(0,_home_runner_work_angor_hub_angor_hub_node_modules_angular_builders_custom_webpack_node_modules_babel_runtime_helpers_esm_asyncToGenerator_js__WEBPACK_IMPORTED_MODULE_1__.A)(function*(o,s,r){if(!this.ndk)throw new Error("No NDK instance found");if(this.ndk.assertSigner(),!s){const i=yield this.ndk.fetchEvents({kinds:[10001],authors:[this.pubkey]},{cacheUsage:"ONLY_RELAY"});s=i.size>0?lists_default.from(Array.from(i)[0]):new NDKEvent(this.ndk,{kind:10001})}return s.tag(o),r&&(yield s.publish()),s}),_pin.apply(this,arguments)}var NIP05_REGEX=/^(?:([\w.+-]+)@)?([\w.-]+)$/;function getNip05For(o){return _getNip05For.apply(this,arguments)}function _getNip05For(){return _getNip05For=(0,_home_runner_work_angor_hub_angor_hub_node_modules_angular_builders_custom_webpack_node_modules_babel_runtime_helpers_esm_asyncToGenerator_js__WEBPACK_IMPORTED_MODULE_1__.A)(function*(o,s=fetch,r={}){const i=o.match(NIP05_REGEX);if(!i)return null;const[a,c="_",y]=i;try{const w=yield s(`https://${y}/.well-known/nostr.json?name=${c}`,r),{names:C,relays:T,nip46:S}=parseNIP05Result(yield w.json()),M=C[c];return M?{pubkey:M,relays:T?.[M],nip46:S?.[M]}:null}catch{return null}}),_getNip05For.apply(this,arguments)}function parseNIP05Result(o){const s={names:{}};for(const[r,i]of Object.entries(o.names))"string"==typeof r&&"string"==typeof i&&(s.names[r]=i);if(o.relays){s.relays={};for(const[r,i]of Object.entries(o.relays))"string"==typeof r&&Array.isArray(i)&&(s.relays[r]=i.filter(a=>"string"==typeof a))}if(o.nip46){s.nip46={};for(const[r,i]of Object.entries(o.relays))"string"==typeof r&&Array.isArray(i)&&(s.nip46[r]=i.filter(a=>"string"==typeof a))}return s}var NDKUser=class Sw{ndk;profile;_npub;_pubkey;relayUrls=[];nip46Urls=[];constructor(s){s.npub&&(this._npub=s.npub),s.hexpubkey&&(this._pubkey=s.hexpubkey),s.pubkey&&(this._pubkey=s.pubkey),s.relayUrls&&(this.relayUrls=s.relayUrls),s.nip46Urls&&(this.nip46Urls=s.nip46Urls)}get npub(){if(!this._npub){if(!this._pubkey)throw new Error("hexpubkey not set");this._npub=nip19_exports.npubEncode(this.pubkey)}return this._npub}set npub(s){this._npub=s}get hexpubkey(){return this.pubkey}set hexpubkey(s){this._pubkey=s}get pubkey(){if(!this._pubkey){if(!this._npub)throw new Error("npub not set");this._pubkey=nip19_exports.decode(this.npub).data}return this._pubkey}set pubkey(s){this._pubkey=s}static fromNip05(s,r,i=!1){return(0,_home_runner_work_angor_hub_angor_hub_node_modules_angular_builders_custom_webpack_node_modules_babel_runtime_helpers_esm_asyncToGenerator_js__WEBPACK_IMPORTED_MODULE_1__.A)(function*(){if(r?.cacheAdapter&&r.cacheAdapter.loadNip05){const y=yield r.cacheAdapter.loadNip05(s);if(y){const w=new Sw({pubkey:y.pubkey,relayUrls:y.relays,nip46Urls:y.nip46});return w.ndk=r,w}}let a={};i&&(a.cache="no-cache");const c=yield getNip05For(s,r?.httpFetch,a);if(c&&r?.cacheAdapter&&r.cacheAdapter.saveNip05&&r?.cacheAdapter.saveNip05(s,c),c){const y=new Sw({pubkey:c.pubkey,relayUrls:c.relays,nip46Urls:c.nip46});return y.ndk=r,y}})()}fetchProfile(s){var r=this;return(0,_home_runner_work_angor_hub_angor_hub_node_modules_angular_builders_custom_webpack_node_modules_babel_runtime_helpers_esm_asyncToGenerator_js__WEBPACK_IMPORTED_MODULE_1__.A)(function*(){if(!r.ndk)throw new Error("NDK not set");r.profile||(r.profile={});let i=null;if(r.ndk.cacheAdapter&&r.ndk.cacheAdapter.fetchProfile&&"ONLY_RELAY"!==s?.cacheUsage){const c=yield r.ndk.cacheAdapter.fetchProfile(r.pubkey);if(c)return r.profile=c,c}!s&&r.ndk.cacheAdapter&&r.ndk.cacheAdapter.locking&&(i=yield r.ndk.fetchEvents({kinds:[0],authors:[r.pubkey]},{cacheUsage:"ONLY_CACHE",closeOnEose:!0,groupable:!1}),s={cacheUsage:"ONLY_RELAY",closeOnEose:!0,groupable:!0,groupableDelay:250}),i&&0!==i.size||(i=yield r.ndk.fetchEvents({kinds:[0],authors:[r.pubkey]},s));const a=Array.from(i).sort((c,y)=>c.created_at-y.created_at);return 0===a.length?null:(r.profile=profileFromEvent(a[0]),r.profile&&r.ndk.cacheAdapter&&r.ndk.cacheAdapter.saveProfile&&r.ndk.cacheAdapter.saveProfile(r.pubkey,r.profile),r.profile)})()}follows=follows.bind(this);pin=pin.bind(this);relayList(){var s=this;return(0,_home_runner_work_angor_hub_angor_hub_node_modules_angular_builders_custom_webpack_node_modules_babel_runtime_helpers_esm_asyncToGenerator_js__WEBPACK_IMPORTED_MODULE_1__.A)(function*(){if(!s.ndk)throw new Error("NDK not set");const r=s.ndk.outboxPool||s.ndk.pool,i=new Set;for(const y of r.relays.values())i.add(y);const a=new NDKRelaySet(i,s.ndk),c=yield s.ndk.fetchEvent({kinds:[10002],authors:[s.pubkey]},{closeOnEose:!0,pool:r,groupable:!0,subId:`relay-list-${s.pubkey.slice(0,6)}`},a);return c?NDKRelayList.from(c):yield s.relayListFromKind3()})()}relayListFromKind3(){var s=this;return(0,_home_runner_work_angor_hub_angor_hub_node_modules_angular_builders_custom_webpack_node_modules_babel_runtime_helpers_esm_asyncToGenerator_js__WEBPACK_IMPORTED_MODULE_1__.A)(function*(){if(!s.ndk)throw new Error("NDK not set");const r=yield s.ndk.fetchEvent({kinds:[3],authors:[s.pubkey]});if(r)try{const i=JSON.parse(r.content),a=new NDKRelayList(s.ndk),c=new Set,y=new Set;for(const[w,C]of Object.entries(i))if(C){const T=C;T.write&&y.add(w),T.read&&c.add(w)}else c.add(w),y.add(w);return a.readRelayUrls=Array.from(c),a.writeRelayUrls=Array.from(y),a}catch{}})()}tagReference(){return["p",this.pubkey]}referenceTags(s){const r=[["p",this.pubkey]];return s&&r[0].push("",s),r}publish(){var s=this;return(0,_home_runner_work_angor_hub_angor_hub_node_modules_angular_builders_custom_webpack_node_modules_babel_runtime_helpers_esm_asyncToGenerator_js__WEBPACK_IMPORTED_MODULE_1__.A)(function*(){if(!s.ndk)throw new Error("No NDK instance found");if(!s.profile)throw new Error("No profile available");s.ndk.assertSigner(),yield new NDKEvent(s.ndk,{kind:0,content:serializeProfile(s.profile)}).publish()})()}follow(s,r,i=3){var a=this;return(0,_home_runner_work_angor_hub_angor_hub_node_modules_angular_builders_custom_webpack_node_modules_babel_runtime_helpers_esm_asyncToGenerator_js__WEBPACK_IMPORTED_MODULE_1__.A)(function*(){if(!a.ndk)throw new Error("No NDK instance found");if(a.ndk.assertSigner(),r||(r=yield a.follows(void 0,void 0,i)),r.has(s))return!1;r.add(s);const c=new NDKEvent(a.ndk,{kind:i});for(const y of r)c.tag(y);return yield c.publish(),!0})()}validateNip05(s){var r=this;return(0,_home_runner_work_angor_hub_angor_hub_node_modules_angular_builders_custom_webpack_node_modules_babel_runtime_helpers_esm_asyncToGenerator_js__WEBPACK_IMPORTED_MODULE_1__.A)(function*(){if(!r.ndk)throw new Error("No NDK instance found");const i=yield getNip05For(s);return null===i?null:i.pubkey===r.pubkey})()}zap(s,r,i,a){var c=this;return(0,_home_runner_work_angor_hub_angor_hub_node_modules_angular_builders_custom_webpack_node_modules_babel_runtime_helpers_esm_asyncToGenerator_js__WEBPACK_IMPORTED_MODULE_1__.A)(function*(){if(!c.ndk)throw new Error("No NDK instance found");a||c.ndk.assertSigner();const y=new Zap({ndk:c.ndk,zappedUser:c}),w=Array.from(c.ndk.pool.relays.keys());return yield y.createZapRequest(s,r,i,w,a)})()}},NDKPrivateKeySigner=class pD{_user;privateKey;constructor(s){s&&(this.privateKey=s,this._user=new NDKUser({hexpubkey:getPublicKey(this.privateKey)}))}static generate(){const s=generatePrivateKey();return new pD(s)}blockUntilReady(){var s=this;return(0,_home_runner_work_angor_hub_angor_hub_node_modules_angular_builders_custom_webpack_node_modules_babel_runtime_helpers_esm_asyncToGenerator_js__WEBPACK_IMPORTED_MODULE_1__.A)(function*(){if(!s._user)throw new Error("NDKUser not initialized");return s._user})()}user(){var s=this;return(0,_home_runner_work_angor_hub_angor_hub_node_modules_angular_builders_custom_webpack_node_modules_babel_runtime_helpers_esm_asyncToGenerator_js__WEBPACK_IMPORTED_MODULE_1__.A)(function*(){return yield s.blockUntilReady(),s._user})()}sign(s){var r=this;return(0,_home_runner_work_angor_hub_angor_hub_node_modules_angular_builders_custom_webpack_node_modules_babel_runtime_helpers_esm_asyncToGenerator_js__WEBPACK_IMPORTED_MODULE_1__.A)(function*(){if(!r.privateKey)throw Error("Attempted to sign without a private key");return getSignature(s,r.privateKey)})()}encrypt(s,r){var i=this;return(0,_home_runner_work_angor_hub_angor_hub_node_modules_angular_builders_custom_webpack_node_modules_babel_runtime_helpers_esm_asyncToGenerator_js__WEBPACK_IMPORTED_MODULE_1__.A)(function*(){if(!i.privateKey)throw Error("Attempted to encrypt without a private key");const a=s.hexpubkey;return yield nip04_exports.encrypt(i.privateKey,a,r)})()}decrypt(s,r){var i=this;return(0,_home_runner_work_angor_hub_angor_hub_node_modules_angular_builders_custom_webpack_node_modules_babel_runtime_helpers_esm_asyncToGenerator_js__WEBPACK_IMPORTED_MODULE_1__.A)(function*(){if(!i.privateKey)throw Error("Attempted to decrypt without a private key");const a=s.hexpubkey;return yield nip04_exports.decrypt(i.privateKey,a,r)})()}},NDKNostrRpc=class extends lib$1.EventEmitter{ndk;signer;debug;constructor(o,s,r){super(),this.ndk=o,this.signer=s,this.debug=r.extend("rpc")}subscribe(o){var s=this;const r=this.ndk.subscribe(o,{closeOnEose:!1,groupable:!1});return r.on("event",function(){var i=(0,_home_runner_work_angor_hub_angor_hub_node_modules_angular_builders_custom_webpack_node_modules_babel_runtime_helpers_esm_asyncToGenerator_js__WEBPACK_IMPORTED_MODULE_1__.A)(function*(a){try{const c=yield s.parseEvent(a);s.emit(c.method?"request":`response-${c.id}`,c)}catch(c){s.debug("error parsing event",c,a.rawEvent())}});return function(a){return i.apply(this,arguments)}}()),new Promise((i,a)=>{r.on("eose",()=>i(r))})}parseEvent(o){var s=this;return(0,_home_runner_work_angor_hub_angor_hub_node_modules_angular_builders_custom_webpack_node_modules_babel_runtime_helpers_esm_asyncToGenerator_js__WEBPACK_IMPORTED_MODULE_1__.A)(function*(){const r=s.ndk.getUser({hexpubkey:o.pubkey});r.ndk=s.ndk;const i=yield s.signer.decrypt(r,o.content),a=JSON.parse(i),{id:c,method:y,params:w,result:C,error:T}=a;return y?{id:c,pubkey:o.pubkey,method:y,params:w,event:o}:{id:c,result:C,error:T,event:o}})()}sendResponse(o,s,r,i=24133,a){var c=this;return(0,_home_runner_work_angor_hub_angor_hub_node_modules_angular_builders_custom_webpack_node_modules_babel_runtime_helpers_esm_asyncToGenerator_js__WEBPACK_IMPORTED_MODULE_1__.A)(function*(){const y={id:o,result:r};a&&(y.error=a);const w=yield c.signer.user(),C=c.ndk.getUser({hexpubkey:s}),T=new NDKEvent(c.ndk,{kind:i,content:JSON.stringify(y),tags:[["p",s]],pubkey:w.hexpubkey});T.content=yield c.signer.encrypt(C,T.content),yield T.sign(c.signer),yield T.publish()})()}sendRequest(o,s,r=[],i=24133,a){var c=this;return(0,_home_runner_work_angor_hub_angor_hub_node_modules_angular_builders_custom_webpack_node_modules_babel_runtime_helpers_esm_asyncToGenerator_js__WEBPACK_IMPORTED_MODULE_1__.A)(function*(){const y=Math.random().toString(36).substring(7),w=yield c.signer.user(),C=c.ndk.getUser({hexpubkey:o}),T={id:y,method:s,params:r},S=new Promise(O=>{const L=Z=>{"auth_url"===Z.result?(c.once(`response-${y}`,L),c.emit("authUrl",Z.error)):a&&a(Z)};c.once(`response-${y}`,L)}),M=new NDKEvent(c.ndk,{kind:i,content:JSON.stringify(T),tags:[["p",o]],pubkey:w.pubkey});return M.content=yield c.signer.encrypt(C,M.content),yield M.sign(c.signer),c.debug(`sending ${s} request to`,o),yield M.publish(),S})()}},NDKNip46Signer=class extends lib$1.EventEmitter{ndk;remoteUser;remotePubkey;token;localSigner;nip05;rpc;debug;relayUrls=[];constructor(o,s,r){let i,a;if(super(),s.includes("#")){const c=s.split("#");i=new NDKUser({npub:c[0]}).pubkey,a=c[1]}else s.startsWith("npub")?i=new NDKUser({npub:s}).pubkey:s.match(/\./)?this.nip05=s:i=s;this.ndk=o,i&&(this.remotePubkey=i),this.token=a,this.debug=o.debug.extend("nip46:signer"),this.remoteUser=new NDKUser({pubkey:i}),this.localSigner=r||NDKPrivateKeySigner.generate(),this.rpc=new NDKNostrRpc(o,this.localSigner,this.debug),this.rpc.on("authUrl",(...c)=>{this.emit("authUrl",...c)}),this.localSigner.user().then(c=>{this.rpc.subscribe({kinds:[24133,24134],"#p":[c.pubkey]})})}user(){var o=this;return(0,_home_runner_work_angor_hub_angor_hub_node_modules_angular_builders_custom_webpack_node_modules_babel_runtime_helpers_esm_asyncToGenerator_js__WEBPACK_IMPORTED_MODULE_1__.A)(function*(){return o.remoteUser})()}blockUntilReady(){var o=this;return(0,_home_runner_work_angor_hub_angor_hub_node_modules_angular_builders_custom_webpack_node_modules_babel_runtime_helpers_esm_asyncToGenerator_js__WEBPACK_IMPORTED_MODULE_1__.A)(function*(){const s=yield o.localSigner.user(),r=o.ndk.getUser({pubkey:o.remotePubkey});if(o.nip05&&!o.remotePubkey&&NDKUser.fromNip05(o.nip05).then(i=>{i&&(o.remoteUser=i,o.remotePubkey=i.pubkey,o.relayUrls=i.nip46Urls)}),!o.remotePubkey)throw new Error("Remote pubkey not set");return new Promise((i,a)=>{setTimeout(()=>{const c=[s.pubkey];o.token&&c.push(o.token),o.rpc.sendRequest(o.remotePubkey,"connect",c,24133,y=>{"ack"===y.result?i(r):a(y.error)})},100)})})()}encrypt(o,s){var r=this;return(0,_home_runner_work_angor_hub_angor_hub_node_modules_angular_builders_custom_webpack_node_modules_babel_runtime_helpers_esm_asyncToGenerator_js__WEBPACK_IMPORTED_MODULE_1__.A)(function*(){return r.debug("asking for encryption"),new Promise((i,a)=>{r.rpc.sendRequest(r.remotePubkey,"nip04_encrypt",[o.pubkey,s],24133,c=>{c.error?a(c.error):i(c.result)})})})()}decrypt(o,s){var r=this;return(0,_home_runner_work_angor_hub_angor_hub_node_modules_angular_builders_custom_webpack_node_modules_babel_runtime_helpers_esm_asyncToGenerator_js__WEBPACK_IMPORTED_MODULE_1__.A)(function*(){return r.debug("asking for decryption"),new Promise((i,a)=>{r.rpc.sendRequest(r.remotePubkey,"nip04_decrypt",[o.pubkey,s],24133,c=>{if(c.error)a(c.error);else{const y=JSON.parse(c.result);i(y[0])}})})})()}sign(o){var s=this;return(0,_home_runner_work_angor_hub_angor_hub_node_modules_angular_builders_custom_webpack_node_modules_babel_runtime_helpers_esm_asyncToGenerator_js__WEBPACK_IMPORTED_MODULE_1__.A)(function*(){return s.debug("asking for a signature"),new Promise((r,i)=>{s.rpc.sendRequest(s.remotePubkey,"sign_event",[JSON.stringify(o)],24133,a=>{if(s.debug("got a response",a),a.error)i(a.error);else{const c=JSON.parse(a.result);r(c.sig)}})})})()}createAccount(o,s,r){var i=this;return(0,_home_runner_work_angor_hub_angor_hub_node_modules_angular_builders_custom_webpack_node_modules_babel_runtime_helpers_esm_asyncToGenerator_js__WEBPACK_IMPORTED_MODULE_1__.A)(function*(){i.debug("asking to create an account");const a=[];return o&&a.push(o),s&&a.push(s),r&&a.push(r),new Promise((c,y)=>{i.rpc.sendRequest(i.remotePubkey,"create_account",a,24134,w=>{i.debug("got a response",w),w.error?y(w.error):c(w.result)})})})()}};function dedup(o,s){return o.created_at>s.created_at?o:s}var OutboxItem=class{type;relayUrlScores;readRelays;writeRelays;constructor(o){this.type=o,this.relayUrlScores=new Map,this.readRelays=new Set,this.writeRelays=new Set}},OutboxTracker=class extends lib$1.EventEmitter{data;ndk;debug;constructor(o){super(),this.ndk=o,this.debug=o.debug.extend("outbox-tracker"),this.data=new dist.LRUCache({maxSize:1e5,entryExpirationTimeInMS:5e3})}trackUsers(o){for(const s of o){const r=getKeyFromItem(s);if(this.data.has(r))continue;const i=this.track(s,"user"),a=s instanceof NDKUser?s:new NDKUser({hexpubkey:s});a.ndk=this.ndk,a.relayList().then(c=>{if(c){i.readRelays=new Set(c.readRelayUrls),i.writeRelays=new Set(c.writeRelayUrls);for(const y of i.readRelays)this.ndk.pool.blacklistRelayUrls.has(y)&&(this.debug(`removing blacklisted relay ${y} from read relays`),i.readRelays.delete(y));for(const y of i.writeRelays)this.ndk.pool.blacklistRelayUrls.has(y)&&(this.debug(`removing blacklisted relay ${y} from write relays`),i.writeRelays.delete(y));this.data.set(r,i),this.debug(`Adding ${i.readRelays.size} read relays and ${i.writeRelays.size} write relays for ${a.hexpubkey}`)}})}}track(o,s){const r=getKeyFromItem(o);s??=getTypeFromItem(o);let i=this.data.get(r);return i||(i=new OutboxItem(s)),this.data.set(r,i),i}};function getKeyFromItem(o){return o instanceof NDKUser?o.hexpubkey:o}function getTypeFromItem(o){return o instanceof NDKUser?"user":"kind"}var NDKPool=class extends lib$1.EventEmitter{relays=new Map;blacklistRelayUrls;debug;temporaryRelayTimers=new Map;flappingRelays=new Set;backoffTimes=new Map;constructor(o=[],s=[],r,i){super(),this.debug=i??r.debug.extend("pool");for(const a of o){const c=new NDKRelay(a);this.addRelay(c,!1)}this.blacklistRelayUrls=new Set(s)}useTemporaryRelay(o,s=6e5){const r=this.relays.has(o.url);r||this.addRelay(o);const i=this.temporaryRelayTimers.get(o.url);if(i&&clearTimeout(i),!r||i){const a=setTimeout(()=>{this.removeRelay(o.url)},s);this.temporaryRelayTimers.set(o.url,a)}}addRelay(o,s=!0){var r=this;const i=o.url;this.blacklistRelayUrls?.has(i)?this.debug(`Relay ${i} is blacklisted`):(o.on("notice",function(){var a=(0,_home_runner_work_angor_hub_angor_hub_node_modules_angular_builders_custom_webpack_node_modules_babel_runtime_helpers_esm_asyncToGenerator_js__WEBPACK_IMPORTED_MODULE_1__.A)(function*(c,y){return r.emit("notice",c,y)});return function(c,y){return a.apply(this,arguments)}}()),o.on("connect",()=>this.handleRelayConnect(i)),o.on("ready",()=>this.handleRelayReady(o)),o.on("disconnect",(0,_home_runner_work_angor_hub_angor_hub_node_modules_angular_builders_custom_webpack_node_modules_babel_runtime_helpers_esm_asyncToGenerator_js__WEBPACK_IMPORTED_MODULE_1__.A)(function*(){return r.emit("relay:disconnect",o)})),o.on("flapping",()=>this.handleFlapping(o)),o.on("auth",function(){var a=(0,_home_runner_work_angor_hub_angor_hub_node_modules_angular_builders_custom_webpack_node_modules_babel_runtime_helpers_esm_asyncToGenerator_js__WEBPACK_IMPORTED_MODULE_1__.A)(function*(c){return r.emit("relay:auth",o,c)});return function(c){return a.apply(this,arguments)}}()),this.relays.set(i,o),s&&o.connect().catch(a=>{this.debug(`Failed to connect to relay ${i}`,a)}))}removeRelay(o){const s=this.relays.get(o);if(s)return s.disconnect(),this.relays.delete(o),this.emit("relay:disconnect",s),!0;const r=this.temporaryRelayTimers.get(o);return r&&(clearTimeout(r),this.temporaryRelayTimers.delete(o)),!1}getRelay(o,s=!0){let r=this.relays.get(o);return r||(r=new NDKRelay(o),this.addRelay(r,s)),r}handleRelayConnect(o){this.debug(`Relay ${o} connected`),this.emit("relay:connect",this.relays.get(o)),this.stats().connected===this.relays.size&&this.emit("connect")}handleRelayReady(o){this.debug(`Relay ${o.url} ready`),this.emit("relay:ready",o)}connect(o){var s=this;return(0,_home_runner_work_angor_hub_angor_hub_node_modules_angular_builders_custom_webpack_node_modules_babel_runtime_helpers_esm_asyncToGenerator_js__WEBPACK_IMPORTED_MODULE_1__.A)(function*(){const r=[];s.debug(`Connecting to ${s.relays.size} relays${o?`, timeout ${o}...`:""}`);for(const i of s.relays.values())if(o){const a=new Promise((c,y)=>{setTimeout(()=>y(`Timed out after ${o}ms`),o)});r.push(Promise.race([i.connect(),a]).catch(c=>{s.debug(`Failed to connect to relay ${i.url}: ${c??"No reason specified"}`)}))}else r.push(i.connect());o&&setTimeout(()=>{const i=s.stats().connected===s.relays.size,a=s.stats().connected>0;!i&&a&&s.emit("connect")},o),yield Promise.all(r)})()}checkOnFlappingRelays(){if(this.flappingRelays.size/this.relays.size>=.8)for(const o of this.flappingRelays)this.backoffTimes.set(o,0)}handleFlapping(o){this.debug(`Relay ${o.url} is flapping`);let s=this.backoffTimes.get(o.url)||5e3;s*=2,this.backoffTimes.set(o.url,s),this.debug(`Backoff time for ${o.url} is ${s}ms`),setTimeout(()=>{this.debug(`Attempting to reconnect to ${o.url}`),o.connect(),this.checkOnFlappingRelays()},s),o.disconnect(),this.emit("flapping",o)}size(){return this.relays.size}stats(){const o={total:0,connected:0,disconnected:0,connecting:0};for(const s of this.relays.values())o.total++,1===s.status?o.connected++:3===s.status?o.disconnected++:0===s.status&&o.connecting++;return o}connectedRelays(){return Array.from(this.relays.values()).filter(o=>1===o.status)}urls(){return Array.from(this.relays.keys())}};function correctRelaySet(o,s){const r=s.connectedRelays();if(!Array.from(o.relays).some(i=>r.map(a=>a.url).includes(i.url)))for(const i of r)o.addRelay(i);if(0===r.length)for(const i of s.relays.values())o.addRelay(i);return o}var SPEC_PATH="/.well-known/nostr/nip96.json",Nip96=class{ndk;spec;url;nip98Required=!1;constructor(o,s){this.url=`https://${o}${SPEC_PATH}`,this.ndk=s}prepareUpload(o,s="POST"){var r=this;return(0,_home_runner_work_angor_hub_angor_hub_node_modules_angular_builders_custom_webpack_node_modules_babel_runtime_helpers_esm_asyncToGenerator_js__WEBPACK_IMPORTED_MODULE_1__.A)(function*(){if(r.validateHttpFetch(),r.spec||(yield r.fetchSpec()),!r.spec)throw new Error("Failed to fetch NIP96 spec");let i={};return r.nip98Required&&(i={Authorization:yield r.generateNip98Header(r.spec.api_url,s,o)}),{url:r.spec.api_url,headers:i}})()}xhrUpload(o,s){var r=this;return(0,_home_runner_work_angor_hub_angor_hub_node_modules_angular_builders_custom_webpack_node_modules_babel_runtime_helpers_esm_asyncToGenerator_js__WEBPACK_IMPORTED_MODULE_1__.A)(function*(){const i="POST",{url:a,headers:c}=yield r.prepareUpload(s,i);o.open(i,a,!0),c.Authorization&&o.setRequestHeader("Authorization",c.Authorization);const y=new FormData;return y.append("file",s),new Promise((w,C)=>{o.onload=function(){o.status>=200&&o.status<300?w(JSON.parse(o.responseText)):C(new Error(o.statusText))},o.onerror=function(){C(new Error("Network Error"))},o.send(y)})})()}upload(o){var s=this;return(0,_home_runner_work_angor_hub_angor_hub_node_modules_angular_builders_custom_webpack_node_modules_babel_runtime_helpers_esm_asyncToGenerator_js__WEBPACK_IMPORTED_MODULE_1__.A)(function*(){const r="POST",{url:i,headers:a}=yield s.prepareUpload(o,r),c=new FormData;c.append("file",o);const y=yield s.ndk.httpFetch(s.spec.api_url,{method:r,headers:a,body:c});if(200!==y.status)throw new Error(`Failed to upload file to ${i}`);const w=yield y.json();if("success"!==w.status)throw new Error(w.message);return w})()}validateHttpFetch(){if(!this.ndk)throw new Error("NDK is required to fetch NIP96 spec");if(!this.ndk.httpFetch)throw new Error("NDK must have an httpFetch method to fetch NIP96 spec")}fetchSpec(){var o=this;return(0,_home_runner_work_angor_hub_angor_hub_node_modules_angular_builders_custom_webpack_node_modules_babel_runtime_helpers_esm_asyncToGenerator_js__WEBPACK_IMPORTED_MODULE_1__.A)(function*(){o.validateHttpFetch();const s=yield o.ndk.httpFetch(o.url);if(200!==s.status)throw new Error(`Failed to fetch NIP96 spec from ${o.url}`);const r=yield s.json();if(!r)throw new Error(`Failed to parse NIP96 spec from ${o.url}`);o.spec=r,o.nip98Required=o.spec.plans.free.is_nip98_required})()}generateNip98Header(o,s,r){var i=this;return(0,_home_runner_work_angor_hub_angor_hub_node_modules_angular_builders_custom_webpack_node_modules_babel_runtime_helpers_esm_asyncToGenerator_js__WEBPACK_IMPORTED_MODULE_1__.A)(function*(){const a=new NDKEvent(i.ndk,{kind:27235,tags:[["u",o],["method",s]]});if(["POST","PUT","PATCH"].includes(s)){const c=yield i.calculateSha256(r);a.tags.push(["payload",c])}return yield a.sign(),`Nostr ${btoa(JSON.stringify(a.rawEvent()))}`})()}calculateSha256(o){return(0,_home_runner_work_angor_hub_angor_hub_node_modules_angular_builders_custom_webpack_node_modules_babel_runtime_helpers_esm_asyncToGenerator_js__WEBPACK_IMPORTED_MODULE_1__.A)(function*(){const s=yield o.arrayBuffer(),r=yield crypto.subtle.digest("SHA-256",s);return Array.from(new Uint8Array(r)).map(i=>i.toString(16).padStart(2,"0")).join("")})()}},DEFAULT_OUTBOX_RELAYS=["wss://purplepag.es","wss://relay.snort.social"],DEFAULT_BLACKLISTED_RELAYS=["wss://brb.io"],NDK=class extends lib$1.EventEmitter{explicitRelayUrls;pool;outboxPool;_signer;_activeUser;cacheAdapter;debug;devWriteRelaySet;outboxTracker;mutedIds;clientName;clientNip89;relayAuthDefaultPolicy;httpFetch;autoConnectUserRelays=!0;autoFetchUserMutelist=!0;constructor(o={}){var s;super(),s=this,this.debug=o.debug||debug3("ndk"),this.explicitRelayUrls=o.explicitRelayUrls||[],this.pool=new NDKPool(o.explicitRelayUrls||[],o.blacklistRelayUrls,this),this.debug(`Starting with explicit relays: ${JSON.stringify(this.explicitRelayUrls)}`),this.pool.on("relay:auth",function(){var r=(0,_home_runner_work_angor_hub_angor_hub_node_modules_angular_builders_custom_webpack_node_modules_babel_runtime_helpers_esm_asyncToGenerator_js__WEBPACK_IMPORTED_MODULE_1__.A)(function*(i,a){s.relayAuthDefaultPolicy&&(yield s.relayAuthDefaultPolicy(i,a))});return function(i,a){return r.apply(this,arguments)}}()),this.autoConnectUserRelays=o.autoConnectUserRelays??!0,this.autoFetchUserMutelist=o.autoFetchUserMutelist??!0,this.clientName=o.clientName,this.clientNip89=o.clientNip89,this.relayAuthDefaultPolicy=o.relayAuthDefaultPolicy,o.enableOutboxModel&&(this.outboxPool=new NDKPool(o.outboxRelayUrls||DEFAULT_OUTBOX_RELAYS,o.blacklistRelayUrls||DEFAULT_BLACKLISTED_RELAYS,this,this.debug.extend("outbox-pool")),this.outboxTracker=new OutboxTracker(this)),this.signer=o.signer,this.cacheAdapter=o.cacheAdapter,this.mutedIds=o.mutedIds||new Map,o.devWriteRelayUrls&&(this.devWriteRelaySet=NDKRelaySet.fromRelayUrls(o.devWriteRelayUrls,this));try{this.httpFetch=fetch}catch{}}addExplicitRelay(o,s,r=!0){let i;return i="string"==typeof o?new NDKRelay(o,s):o,this.pool.addRelay(i,r),this.explicitRelayUrls.push(i.url),i}toJSON(){return{relayCount:this.pool.relays.size}.toString()}get activeUser(){return this._activeUser}set activeUser(o){var s=this;const r=this._activeUser?.pubkey!==o?.pubkey;if(this._activeUser=o,o&&r){const i=function(){var C=(0,_home_runner_work_angor_hub_angor_hub_node_modules_angular_builders_custom_webpack_node_modules_babel_runtime_helpers_esm_asyncToGenerator_js__WEBPACK_IMPORTED_MODULE_1__.A)(function*(T){const S=yield T.relayList();if(S){s.debug("Connecting to user relays",{npub:T.npub,relays:S.relays});for(const M of S.relays){let O=s.pool.relays.get(M);O||(O=new NDKRelay(M),s.pool.addRelay(O))}}else s.debug("No relay list found for user",{npub:T.npub})});return function(S){return C.apply(this,arguments)}}(),a=function(){var C=(0,_home_runner_work_angor_hub_angor_hub_node_modules_angular_builders_custom_webpack_node_modules_babel_runtime_helpers_esm_asyncToGenerator_js__WEBPACK_IMPORTED_MODULE_1__.A)(function*(T){const S=yield s.fetchEvents([{kinds:[1e4],authors:[T.pubkey]},{kinds:[3e4],authors:[T.pubkey],"#d":["mute"],limit:1}]);if(S)for(const M of S){const O=lists_default.from(M);for(const L of O.items)s.mutedIds.set(L[1],L[0])}else s.debug("No mute list found for user",{npub:T.npub})});return function(S){return C.apply(this,arguments)}}(),c=[];this.autoConnectUserRelays&&c.push(i),this.autoFetchUserMutelist&&c.push(a);const y=function(){var C=(0,_home_runner_work_angor_hub_angor_hub_node_modules_angular_builders_custom_webpack_node_modules_babel_runtime_helpers_esm_asyncToGenerator_js__WEBPACK_IMPORTED_MODULE_1__.A)(function*(T){for(const S of c)yield S(T)});return function(S){return C.apply(this,arguments)}}(),w=this.outboxPool||this.pool;w.connectedRelays.length>0?y(o):(this.debug("Waiting for connection to main relays"),w.once("relay:ready",C=>{this.debug("New relay ready",C?.url),y(o)}))}else o||(this.mutedIds=new Map)}get signer(){return this._signer}set signer(o){this._signer=o,this.emit("signer:ready",o),o?.user().then(s=>{s.ndk=this,this.activeUser=s})}connect(o){var s=this;return(0,_home_runner_work_angor_hub_angor_hub_node_modules_angular_builders_custom_webpack_node_modules_babel_runtime_helpers_esm_asyncToGenerator_js__WEBPACK_IMPORTED_MODULE_1__.A)(function*(){s._signer&&s.autoConnectUserRelays&&(s.debug("Attempting to connect to user relays specified by signer"),s._signer.relays)&&(yield s._signer.relays()).forEach(i=>s.pool.addRelay(i));const r=[s.pool.connect(o)];return s.outboxPool&&r.push(s.outboxPool.connect(o)),s.debug("Connecting to relays",{timeoutMs:o}),Promise.allSettled(r).then(()=>{})})()}getUser(o){const s=new NDKUser(o);return s.ndk=this,s}getUserFromNip05(o,s=!1){var r=this;return(0,_home_runner_work_angor_hub_angor_hub_node_modules_angular_builders_custom_webpack_node_modules_babel_runtime_helpers_esm_asyncToGenerator_js__WEBPACK_IMPORTED_MODULE_1__.A)(function*(){return NDKUser.fromNip05(o,r,s)})()}subscribe(o,s,r,i=!0){const a=new NDKSubscription(this,o,s,r);if(r)for(const c of r.relays)this.pool.useTemporaryRelay(c);if(this.outboxPool&&a.hasAuthorsFilter()){const c=a.filters.filter(y=>y.authors&&y.authors?.length>0).map(y=>y.authors).flat();this.outboxTracker?.trackUsers(c)}return i&&a.start(),a}publish(o,s,r){var i=this;return(0,_home_runner_work_angor_hub_angor_hub_node_modules_angular_builders_custom_webpack_node_modules_babel_runtime_helpers_esm_asyncToGenerator_js__WEBPACK_IMPORTED_MODULE_1__.A)(function*(){return i.debug("Deprecated: Use `event.publish()` instead"),o.publish(s,r)})()}fetchEvent(o,s,r){var i=this;return(0,_home_runner_work_angor_hub_angor_hub_node_modules_angular_builders_custom_webpack_node_modules_babel_runtime_helpers_esm_asyncToGenerator_js__WEBPACK_IMPORTED_MODULE_1__.A)(function*(){let a,c;if(r instanceof NDKRelay?c=new NDKRelaySet(new Set([r]),i):r instanceof NDKRelaySet&&(c=r),!r&&"string"==typeof o&&!isNip33AValue(o)){const y=relaysFromBech32(o);y.length>0&&(c=new NDKRelaySet(new Set(y),i),c=correctRelaySet(c,i.pool))}if(a="string"==typeof o?filterFromId(o):o,!a)throw new Error(`Invalid filter: ${JSON.stringify(o)}`);return new Promise(y=>{const w=i.subscribe(a,{...s||{},closeOnEose:!0},c,!1);w.on("event",C=>{C.ndk=i,y(C)}),w.on("eose",()=>{y(null)}),w.start()})})()}fetchEvents(o,s,r){var i=this;return(0,_home_runner_work_angor_hub_angor_hub_node_modules_angular_builders_custom_webpack_node_modules_babel_runtime_helpers_esm_asyncToGenerator_js__WEBPACK_IMPORTED_MODULE_1__.A)(function*(){return new Promise(a=>{const c=new Map,y=i.subscribe(o,{...s||{},closeOnEose:!0},r,!1),w=C=>{const T=C.deduplicationKey(),S=c.get(T);S&&(C=dedup(S,C)),C.ndk=i,c.set(T,C)};y.on("event",w),y.on("event:dup",w),y.on("eose",()=>{a(new Set(c.values()))}),y.start()})})()}assertSigner(){if(!this.signer)throw this.emit("signerRequired"),new Error("Signer required")}getNip96(o){return new Nip96(o,this)}};const LOCAL_STORE_KEY="__nostrlogin_nip46",LOGGED_IN_ACCOUNTS="__nostrlogin_accounts",RECENT_ACCOUNTS="__nostrlogin_recent",OUTBOX_RELAYS$1=["wss://purplepag.es","wss://relay.nos.social","wss://user.kindpag.es","wss://relay.damus.io","wss://nos.lol"],DEFAULT_SIGNUP_RELAYS=["wss://relay.damus.io/","wss://nos.lol/","wss://relay.primal.net/"],localStorageSetItem=(o,s)=>{localStorage.setItem(o,s)},localStorageGetItem=o=>{const s=window.localStorage.getItem(o);if(s)try{return JSON.parse(s)}catch{}return null},localStorageRemoveItem=o=>{localStorage.removeItem(o)},fetchProfile=function(){var o=(0,_home_runner_work_angor_hub_angor_hub_node_modules_angular_builders_custom_webpack_node_modules_babel_runtime_helpers_esm_asyncToGenerator_js__WEBPACK_IMPORTED_MODULE_1__.A)(function*(s,r){const i=new NDKUser({pubkey:s.pubkey});return i.ndk=r,yield i.fetchProfile()});return function(r,i){return o.apply(this,arguments)}}(),createProfile=function(){var o=(0,_home_runner_work_angor_hub_angor_hub_node_modules_angular_builders_custom_webpack_node_modules_babel_runtime_helpers_esm_asyncToGenerator_js__WEBPACK_IMPORTED_MODULE_1__.A)(function*(s,r,i,a){const c={name:s.name},y=new NDKEvent(r,{kind:0,created_at:Math.floor(Date.now()/1e3),pubkey:s.pubkey,content:JSON.stringify(c),tags:[]});window.location.hostname&&y.tags.push(["client",window.location.hostname]);const w=new NDKEvent(r,{kind:10002,created_at:Math.floor(Date.now()/1e3),pubkey:s.pubkey,content:"",tags:[]}),C=(a||"").split(",").map(T=>T.trim()).filter(T=>T.startsWith("ws"));C.length||C.push(...DEFAULT_SIGNUP_RELAYS);for(const T of C)w.tags.push(["r",T]);yield y.sign(i),console.log("signed profile",y),yield w.sign(i),console.log("signed relays",w),yield y.publish(NDKRelaySet.fromRelayUrls(OUTBOX_RELAYS$1,r)),console.log("published profile",y),yield w.publish(NDKRelaySet.fromRelayUrls(OUTBOX_RELAYS$1,r)),console.log("published relays",w)});return function(r,i,a,c){return o.apply(this,arguments)}}(),bunkerUrlToInfo=(o,s="")=>{const r=new URL(o);return{pubkey:r.hostname||r.pathname.split("//")[1],sk:s||generatePrivateKey(),relays:r.searchParams.getAll("relay"),token:r.searchParams.get("secret")||"",authMethod:"connect"}},isBunkerUrl=o=>o.startsWith("bunker://"),getBunkerUrl=function(){var o=(0,_home_runner_work_angor_hub_angor_hub_node_modules_angular_builders_custom_webpack_node_modules_babel_runtime_helpers_esm_asyncToGenerator_js__WEBPACK_IMPORTED_MODULE_1__.A)(function*(s,r){if(!s)return"";if(isBunkerUrl(s))return s;if(s.includes("@")){const[i,a]=s.toLocaleLowerCase().split("@"),c=r.devOverrideBunkerOrigin||`https://${a}`,y=`${c}/.well-known/nostr.json?name=_`,w=`${c}/.well-known/nostr.json?name=${i}`,C=yield fetch(y),T=yield C.json(),M=T.nip46[T.names._],O=yield fetch(w),L=(yield O.json()).names[i];if(!M.length)throw new Error("Bunker relay not provided");return`bunker://${L}?relay=${M[0]}`}throw new Error("Invalid user name or bunker url")});return function(r,i){return o.apply(this,arguments)}}(),checkNip05=function(){var o=(0,_home_runner_work_angor_hub_angor_hub_node_modules_angular_builders_custom_webpack_node_modules_babel_runtime_helpers_esm_asyncToGenerator_js__WEBPACK_IMPORTED_MODULE_1__.A)(function*(s){let r=!1,i="",a="";return yield(0,_home_runner_work_angor_hub_angor_hub_node_modules_angular_builders_custom_webpack_node_modules_babel_runtime_helpers_esm_asyncToGenerator_js__WEBPACK_IMPORTED_MODULE_1__.A)(function*(){if(!s||!s.includes("@"))return;const[c,y]=s.toLocaleLowerCase().split("@");if(!c)return;if(!new RegExp(/^[\w-.]+@([\w-]+\.)+[\w-]{2,8}$/g).test(s))return void(i="Invalid name");if(!y)return void(i="Select service");const w=`https://${y}/.well-known/nostr.json?name=${c.toLowerCase()}`;try{const C=yield fetch(w),T=yield C.json();if(T.names[c])return void(a=T.names[c])}catch{}r=!0})(),{available:r,taken:""!=a,error:i,pubkey:a}});return function(r){return o.apply(this,arguments)}}(),upgradeInfo=o=>{"typeAuthMethod"in o&&delete o.typeAuthMethod,o.authMethod||(o.authMethod="extension"in o&&o.extension?"extension":"readOnly"in o&&o.readOnly?"readOnly":"connect"),o.nip05&&isBunkerUrl(o.nip05)&&(o.bunkerUrl=o.nip05,o.nip05="")},localStorageAddAccount=o=>{localStorageSetItem(LOCAL_STORE_KEY,JSON.stringify(o));const s=localStorageGetItem(LOGGED_IN_ACCOUNTS)||[],r=localStorageGetItem(RECENT_ACCOUNTS)||[];s.forEach(y=>upgradeInfo(y)),r.forEach(y=>upgradeInfo(y));const i=s,a=s.findIndex(y=>y.pubkey===o.pubkey&&y.authMethod===o.authMethod);-1!==a?i[a]=o:i.push(o);const c=r.filter(y=>y.pubkey!==o.pubkey||y.authMethod!==o.authMethod);localStorageSetItem(RECENT_ACCOUNTS,JSON.stringify(c)),localStorageSetItem(LOGGED_IN_ACCOUNTS,JSON.stringify(i))},localStorageRemoveCurrentAccount=()=>{const o=localStorageGetItem(LOCAL_STORE_KEY);if(!o)return;upgradeInfo(o);const s={...o};delete s.sk,delete s.otpData;const r=localStorageGetItem(LOGGED_IN_ACCOUNTS)||[],i=localStorageGetItem(RECENT_ACCOUNTS)||[];r.forEach(y=>upgradeInfo(y)),i.forEach(y=>upgradeInfo(y));const a=i;if("connect"===s.authMethod&&s.bunkerUrl&&s.bunkerUrl.includes("secret="))console.log("nostr login bunker conn with a secret not saved to recent");else if("local"===s.authMethod)console.log("nostr login temporary local keys not save to recent");else{const y=i.findIndex(w=>w.pubkey===s.pubkey&&w.authMethod===s.authMethod);-1!==y?a[y]=s:a.push(s)}const c=r.filter(y=>y.pubkey!==o.pubkey||y.authMethod!==o.authMethod);localStorageSetItem(RECENT_ACCOUNTS,JSON.stringify(a)),localStorageSetItem(LOGGED_IN_ACCOUNTS,JSON.stringify(c)),localStorageRemoveItem(LOCAL_STORE_KEY)},localStorageRemoveRecent=o=>{const s=localStorageGetItem(RECENT_ACCOUNTS)||[];s.forEach(i=>upgradeInfo(i));const r=s.filter(i=>i.pubkey!==o.pubkey||i.authMethod!==o.authMethod);localStorageSetItem(RECENT_ACCOUNTS,JSON.stringify(r))},localStorageGetRecents=()=>{const o=localStorageGetItem(RECENT_ACCOUNTS)||[];return o.forEach(s=>upgradeInfo(s)),o},localStorageGetAccounts=()=>{const o=localStorageGetItem(LOGGED_IN_ACCOUNTS)||[];return o.forEach(s=>upgradeInfo(s)),o},localStorageGetCurrent=()=>{const o=localStorageGetItem(LOCAL_STORE_KEY);return o&&upgradeInfo(o),o},getDarkMode=o=>{const s=localStorage.getItem("nl-dark-mode");return s?!!JSON.parse(s):void 0!==o.darkMode?o.darkMode:!(!window.matchMedia||!window.matchMedia("(prefers-color-scheme: dark)").matches)},getIcon=function(){var o=(0,_home_runner_work_angor_hub_angor_hub_node_modules_angular_builders_custom_webpack_node_modules_babel_runtime_helpers_esm_asyncToGenerator_js__WEBPACK_IMPORTED_MODULE_1__.A)(function*(){return document.location.origin+"/favicon.ico"});return function(){return o.apply(this,arguments)}}();class NostrRpc extends NDKNostrRpc{pubkey;_ndk;_signer;requests=new Set;sub;_useNip44=!1;constructor(s,r,i){super(s,i,s.debug.extend("nip46:signer:rpc")),this._ndk=s,this._signer=i,this.pubkey=r}subscribe(s){var r=()=>super.subscribe,i=this;return(0,_home_runner_work_angor_hub_angor_hub_node_modules_angular_builders_custom_webpack_node_modules_babel_runtime_helpers_esm_asyncToGenerator_js__WEBPACK_IMPORTED_MODULE_1__.A)(function*(){return i.sub=yield r().call(i,s),i.sub})()}stop(){this.sub&&(this.sub.stop(),this.sub=void 0)}setUseNip44(s){this._useNip44=s}isNip04(s){const r=s.length;return!(r<28)&&"?"===s[r-28]&&"i"===s[r-27]&&"v"===s[r-26]&&"="===s[r-25]}parseEvent(s){var r=this;return(0,_home_runner_work_angor_hub_angor_hub_node_modules_angular_builders_custom_webpack_node_modules_babel_runtime_helpers_esm_asyncToGenerator_js__WEBPACK_IMPORTED_MODULE_1__.A)(function*(){const i=r._ndk.getUser({pubkey:s.pubkey});i.ndk=r._ndk;const a=r.isNip04(s.content)?r._signer.decrypt:r._signer.decryptNip44;console.log("client event nip04",r.isNip04(s.content));const c=yield a.call(r._signer,i,s.content),y=JSON.parse(c),{id:w,method:C,params:T,result:S,error:M}=y;return C?{id:w,pubkey:s.pubkey,method:C,params:T,event:s}:{id:w,result:S,error:M,event:s}})()}parseNostrConnectReply(s,r){var i=this;return(0,_home_runner_work_angor_hub_angor_hub_node_modules_angular_builders_custom_webpack_node_modules_babel_runtime_helpers_esm_asyncToGenerator_js__WEBPACK_IMPORTED_MODULE_1__.A)(function*(){const a=new NDKEvent(i._ndk,s),c=yield i.parseEvent(a);if(console.log("nostr connect parsedEvent",c),c.method)throw new Error("Bad nostr connect reply");if(c.result===r)return a.pubkey;throw new Error(c.error)})()}listen(s){var r=this;return(0,_home_runner_work_angor_hub_angor_hub_node_modules_angular_builders_custom_webpack_node_modules_babel_runtime_helpers_esm_asyncToGenerator_js__WEBPACK_IMPORTED_MODULE_1__.A)(function*(){const i=r.pubkey;console.log("nostr-login listening for conn to",i);const a=yield r.subscribe({kinds:[24133],"#p":[i]});return new Promise((c,y)=>{a.on("event",function(){var w=(0,_home_runner_work_angor_hub_angor_hub_node_modules_angular_builders_custom_webpack_node_modules_babel_runtime_helpers_esm_asyncToGenerator_js__WEBPACK_IMPORTED_MODULE_1__.A)(function*(C){try{const T=yield r.parseEvent(C);if(!T.method){const S=T;if("auth_url"===S.result)return;"ack"===S.result||S.result===s?c(C.pubkey):y(S.error)}}catch(T){console.log("error parsing event",T,C.rawEvent())}r.stop()});return function(C){return w.apply(this,arguments)}}())})})()}connect(s,r){var i=this;return(0,_home_runner_work_angor_hub_angor_hub_node_modules_angular_builders_custom_webpack_node_modules_babel_runtime_helpers_esm_asyncToGenerator_js__WEBPACK_IMPORTED_MODULE_1__.A)(function*(){return new Promise((a,c)=>{i.sendRequest(s.pubkey,"connect",[s.pubkey,s.token||"",r||""],24133,w=>{"ack"===w.result?a():c(w.error)})})})()}getId(){return Math.random().toString(36).substring(7)}sendRequest(s,r,i=[],a=24133,c){var y=this;return(0,_home_runner_work_angor_hub_angor_hub_node_modules_angular_builders_custom_webpack_node_modules_babel_runtime_helpers_esm_asyncToGenerator_js__WEBPACK_IMPORTED_MODULE_1__.A)(function*(){const w=y.getId();y.setResponseHandler(w,c),yield(yield y.createRequestEvent(w,s,r,i,a)).publish()})()}setResponseHandler(s,r){let i=!1;const a=Date.now();return new Promise(()=>{const c=y=>{"auth_url"===y.result?(this.once(`response-${s}`,c),i||(i=!0,this.emit("authUrl",y.error))):r&&this.requests.has(s)&&(this.requests.delete(s),console.log("nostr-login iframe processed request in",Date.now()-a,"ms"),r(y))};this.once(`response-${s}`,c)})}createRequestEvent(s,r,i,a=[],c=24133){var y=this;return(0,_home_runner_work_angor_hub_angor_hub_node_modules_angular_builders_custom_webpack_node_modules_babel_runtime_helpers_esm_asyncToGenerator_js__WEBPACK_IMPORTED_MODULE_1__.A)(function*(){y.requests.add(s);const w=yield y._signer.user(),C=y._ndk.getUser({pubkey:r}),S=new NDKEvent(y._ndk,{kind:c,content:JSON.stringify({id:s,method:i,params:a}),tags:[["p",r]],pubkey:w.pubkey}),M=y._useNip44&&"create_account"!==i?y._signer.encryptNip44:y._signer.encrypt;return S.content=yield M.call(y._signer,C,S.content),yield S.sign(y._signer),S})()}}class IframeNostrRpc extends NostrRpc{peerOrigin;iframePort;iframeRequests=new Map;constructor(s,r,i,a){super(s,r,i),this._ndk=s,this.peerOrigin=a}subscribe(s){var r=()=>super.subscribe,i=this;return(0,_home_runner_work_angor_hub_angor_hub_node_modules_angular_builders_custom_webpack_node_modules_babel_runtime_helpers_esm_asyncToGenerator_js__WEBPACK_IMPORTED_MODULE_1__.A)(function*(){return i.peerOrigin?new NDKSubscription(i._ndk,s,{closeOnEose:!0,cacheUsage:NDKSubscriptionCacheUsage.ONLY_CACHE}):r().call(i,s)})()}setWorkerIframePort(s){var r=this;if(!this.peerOrigin)throw new Error("Unexpected iframe port");this.iframePort=s,s.onmessage=function(){var i=(0,_home_runner_work_angor_hub_angor_hub_node_modules_angular_builders_custom_webpack_node_modules_babel_runtime_helpers_esm_asyncToGenerator_js__WEBPACK_IMPORTED_MODULE_1__.A)(function*(a){if(console.log("iframe-nip46 got response",a.data),"string"==typeof a.data&&a.data.startsWith("errorNoKey")){const c=a.data.split(":")[1],{id:y="",pubkey:w=""}=r.iframeRequests.get(c)||{};y&&w&&r.requests.has(y)&&r.emit(`iframeRestart-${w}`)}else try{const c=a.data;if(!validateEvent(c))throw new Error("Invalid event from iframe");if(!verifySignature(c))throw new Error("Invalid event signature from iframe");const y=new NDKEvent(r._ndk,c),w=yield r.parseEvent(y);w.method||(console.log("parsed response",w),r.emit(`response-${w.id}`,w))}catch(c){console.log("error parsing event",c,a.data)}});return function(a){return i.apply(this,arguments)}}()}sendRequest(s,r,i=[],a=24133,c){var y=this;return(0,_home_runner_work_angor_hub_angor_hub_node_modules_angular_builders_custom_webpack_node_modules_babel_runtime_helpers_esm_asyncToGenerator_js__WEBPACK_IMPORTED_MODULE_1__.A)(function*(){const w=y.getId(),C=yield y.createRequestEvent(w,s,r,i,a);y.setResponseHandler(w,c),y.iframePort?(y.iframeRequests.set(C.id,{id:w,pubkey:s}),console.log("iframe-nip46 sending request to",y.peerOrigin,C.rawEvent()),y.iframePort.postMessage(C.rawEvent())):yield C.publish()})()}}class ReadyListener{origin;messages;promise;constructor(s,r){var i=this;this.origin=r,this.messages=s,this.promise=new Promise(a=>{console.log(new Date,"started listener for",this.messages);const c=function(){var y=(0,_home_runner_work_angor_hub_angor_hub_node_modules_angular_builders_custom_webpack_node_modules_babel_runtime_helpers_esm_asyncToGenerator_js__WEBPACK_IMPORTED_MODULE_1__.A)(function*(w){const C=new URL(r).hostname,T=new URL(w.origin).hostname;(T===C||T.endsWith("."+C))&&Array.isArray(w.data)&&w.data.length&&i.messages.includes(w.data[0])&&(console.log(new Date,"got ready message from",w.origin,w.data),window.removeEventListener("message",c),a(w.data))});return function(C){return y.apply(this,arguments)}}();window.addEventListener("message",c)})}wait(){var s=this;return(0,_home_runner_work_angor_hub_angor_hub_node_modules_angular_builders_custom_webpack_node_modules_babel_runtime_helpers_esm_asyncToGenerator_js__WEBPACK_IMPORTED_MODULE_1__.A)(function*(){console.log(new Date,"waiting for",s.messages);const r=yield s.promise;return console.log(new Date,"finished waiting for",s.messages,r),r})()}}class BannerManager extends lib$1.EventEmitter{banner=null;iframeReady;params;constructor(s){super(),this.params=s}onAuthUrl(s,r){this.banner&&(this.banner.notify=s?{mode:r?"iframeAuthUrl":"authUrl",url:s}:{mode:""})}onIframeRestart(s){this.banner&&(this.iframeReady=new ReadyListener(["rebinderDone","rebinderError"],new URL(s).origin),this.banner.notify={mode:"rebind",url:s})}onUserInfo(s){this.banner&&(this.banner.userInfo=s)}onCallTimeout(){this.banner&&(this.banner.notify={mode:"timeout"})}onCallStart(){this.banner&&(this.banner.isLoading=!0)}onCallEnd(){var s=this;return(0,_home_runner_work_angor_hub_angor_hub_node_modules_angular_builders_custom_webpack_node_modules_babel_runtime_helpers_esm_asyncToGenerator_js__WEBPACK_IMPORTED_MODULE_1__.A)(function*(){s.banner&&(s.iframeReady&&(yield s.iframeReady.wait(),s.iframeReady=void 0),s.banner.isLoading=!1,s.banner.notify={mode:""})})()}onUpdateAccounts(s){this.banner&&(this.banner.accounts=s)}onDarkMode(s){this.banner&&(this.banner.darkMode=s)}launchAuthBanner(s){var r=this;this.banner=document.createElement("nl-banner"),this.banner.setAttribute("dark-mode",String(getDarkMode(s))),s.theme&&this.banner.setAttribute("theme",s.theme),s.noBanner&&this.banner.setAttribute("hidden-mode","true"),this.banner.addEventListener("handleLoginBanner",i=>{this.emit("launch",i.detail)}),this.banner.addEventListener("handleConfirmLogout",()=>{this.emit("onConfirmLogout")}),this.banner.addEventListener("handleLogoutBanner",(0,_home_runner_work_angor_hub_angor_hub_node_modules_angular_builders_custom_webpack_node_modules_babel_runtime_helpers_esm_asyncToGenerator_js__WEBPACK_IMPORTED_MODULE_1__.A)(function*(){r.emit("logout")})),this.banner.addEventListener("handleImportModal",i=>{this.emit("import")}),this.banner.addEventListener("handleNotifyConfirmBanner",i=>{this.emit("onAuthUrlClick",i.detail)}),this.banner.addEventListener("handleNotifyConfirmBannerIframe",i=>{this.emit("onIframeAuthUrlClick",i.detail)}),this.banner.addEventListener("handleSwitchAccount",i=>{this.emit("onSwitchAccount",i.detail)}),this.banner.addEventListener("handleOpenWelcomeModal",()=>{this.emit("launch",this.params.optionsModal.startScreen),this.banner&&(this.banner.isOpen=!1)}),document.body.appendChild(this.banner)}}function extract(o,s,r){return hash$1(o),void 0===r&&(r=new Uint8Array(o.outputLen)),hmac$1(o,toBytes$1(r),toBytes$1(s))}const HKDF_COUNTER=new Uint8Array([0]),EMPTY_BUFFER=new Uint8Array;function expand(o,s,r,i=32){if(hash$1(o),number$1(i),i>255*o.outputLen)throw new Error("Length should be <= 255*HashLen");const a=Math.ceil(i/o.outputLen);void 0===r&&(r=EMPTY_BUFFER);const c=new Uint8Array(a*o.outputLen),y=hmac$1.create(o,s),w=y._cloneInto(),C=new Uint8Array(y.outputLen);for(let T=0;Tdecoder.decode(o),getConversationKey(o,s){const r=secp256k1.getSharedSecret(o,"02"+s).subarray(1,33);return extract(sha256,r,"nip44-v2")},getMessageKeys(o,s){const r=expand(sha256,o,s,76);return{chacha_key:r.subarray(0,32),chacha_nonce:r.subarray(32,44),hmac_key:r.subarray(44,76)}},calcPaddedLen(o){if(!Number.isSafeInteger(o)||o<1)throw new Error("expected positive integer");if(o<=32)return 32;const s=1<u.maxPlaintextSize)throw new Error("invalid plaintext size: must be between 1 and 65535 bytes");const s=new Uint8Array(2);return new DataView(s.buffer).setUint16(0,o,!1),s},pad(o){const s=u.utf8Encode(o),r=s.length;return concatBytes(u.writeU16BE(r),s,new Uint8Array(u.calcPaddedLen(r)-r))},unpad(o){const s=new DataView(o.buffer).getUint16(0),r=o.subarray(2,2+s);if(su.maxPlaintextSize||r.length!==s||o.length!==2+u.calcPaddedLen(s))throw new Error("invalid padding");return u.utf8Decode(r)},hmacAad(o,s,r){if(32!==r.length)throw new Error("AAD associated data must be 32 bytes");const i=concatBytes(r,s);return hmac$1(sha256,o,i)},decodePayload(o){if("string"!=typeof o)throw new Error("payload must be a valid string");const s=o.length;if(s<132||s>87472)throw new Error("invalid payload length: "+s);if("#"===o[0])throw new Error("unknown encryption version");let r;try{r=base64.decode(o)}catch(c){throw new Error("invalid base64: "+c.message)}const i=r.length;if(i<99||i>65603)throw new Error("invalid data length: "+i);const a=r[0];if(2!==a)throw new Error("unknown encryption version "+a);return{nonce:r.subarray(1,33),ciphertext:r.subarray(33,-32),mac:r.subarray(-32)}}};function encryptNip44(o,s,r=randomBytes(32)){const{chacha_key:i,chacha_nonce:a,hmac_key:c}=u.getMessageKeys(s,r),y=u.pad(o),w=chacha20(i,a,y),C=u.hmacAad(c,w,r);return base64.encode(concatBytes(new Uint8Array([2]),r,w,C))}function decryptNip44(o,s){const{nonce:r,ciphertext:i,mac:a}=u.decodePayload(o),{chacha_key:c,chacha_nonce:y,hmac_key:w}=u.getMessageKeys(s,r);if(!equalBytes(u.hmacAad(w,i,r),a))throw new Error("invalid MAC");const C=chacha20(c,y,i);return u.unpad(C)}class Nip44{cache=new Map;createKey(s,r){return u.getConversationKey(s,r)}getKey(s,r,i){const a=getPublicKey(s)+r;let c=this.cache.get(a);if(c)return c;const y=this.createKey(s,r);return this.cache.set(a,y),y}encrypt(s,r,i){return encryptNip44(i,this.getKey(s,r))}decrypt(s,r,i){return decryptNip44(i,this.getKey(s,r))}}class PrivateKeySigner extends NDKPrivateKeySigner{nip44=new Nip44;constructor(s){super(s)}encryptNip44(s,r){return Promise.resolve(this.nip44.encrypt(this.privateKey,s.pubkey,r))}decryptNip44(s,r){return Promise.resolve(this.nip44.decrypt(this.privateKey,s.pubkey,r))}}const OUTBOX_RELAYS=["wss://user.kindpag.es","wss://purplepag.es","wss://relay.nos.social"],DEFAULT_NOSTRCONNECT_RELAY="wss://relay.nsec.app/",NOSTRCONNECT_APPS=[{name:"Nsec.app",domain:"nsec.app",canImport:!0,img:"https://nsec.app/assets/favicon.ico",link:"https://use.nsec.app/",relay:"wss://relay.nsec.app/"},{name:"Amber",img:"https://raw.githubusercontent.com/greenart7c3/Amber/master/app/src/main/res/mipmap-hdpi/ic_launcher.webp",link:"",relay:"wss://relay.nsec.app/"},{name:"Other key stores",img:"",link:"",relay:"wss://relay.nsec.app/"}];class AuthNostrService extends lib$1.EventEmitter{ndk;profileNdk;signer=null;localSigner=null;params;signerPromise;readyPromise;readyCallback;nip44Codec=new Nip44;nostrConnectKey="";nostrConnectSecret="";iframe;starterReady;nip04;nip44;constructor(s){super(),this.params=s,this.ndk=new NDK({enableOutboxModel:!1}),this.profileNdk=new NDK({enableOutboxModel:!0,explicitRelayUrls:OUTBOX_RELAYS}),this.profileNdk.connect(),this.nip04={encrypt:this.encrypt04.bind(this),decrypt:this.decrypt04.bind(this)},this.nip44={encrypt:this.encrypt44.bind(this),decrypt:this.decrypt44.bind(this)}}isIframe(){return!!this.iframe}waitReady(){var s=this;return(0,_home_runner_work_angor_hub_angor_hub_node_modules_angular_builders_custom_webpack_node_modules_babel_runtime_helpers_esm_asyncToGenerator_js__WEBPACK_IMPORTED_MODULE_1__.A)(function*(){if(s.signerPromise)try{yield s.signerPromise}catch{}if(s.readyPromise)try{yield s.readyPromise}catch{}})()}nostrConnect(s,{domain:r="",link:i="",iframeUrl:a="",importConnect:c=!1}={}){var y=this;return(0,_home_runner_work_angor_hub_angor_hub_node_modules_angular_builders_custom_webpack_node_modules_babel_runtime_helpers_esm_asyncToGenerator_js__WEBPACK_IMPORTED_MODULE_1__.A)(function*(){const w={authMethod:"connect",pubkey:"",sk:y.nostrConnectKey,domain:r,relays:[s=s||DEFAULT_NOSTRCONNECT_RELAY],iframeUrl:a};console.log("nostrconnect info",w,i),i&&!a&&window.open(i,"_blank","width=400,height=700");const C=yield y.initSigner(w,{listen:!0});if(!C)throw new Error("Bad remote pubkey");return w.pubkey=C,w.bunkerUrl=`bunker://${C}?relay=${s}`,c||y.onAuth("login",w),w})()}createNostrConnect(s){var r=this;return(0,_home_runner_work_angor_hub_angor_hub_node_modules_angular_builders_custom_webpack_node_modules_babel_runtime_helpers_esm_asyncToGenerator_js__WEBPACK_IMPORTED_MODULE_1__.A)(function*(){r.nostrConnectKey=generatePrivateKey(),r.nostrConnectSecret=Math.random().toString(36).substring(7);const i=getPublicKey(r.nostrConnectKey),a={name:document.location.host,url:document.location.href,icon:yield getIcon(),perms:r.params.optionsModal.perms};return`nostrconnect://${i}?metadata=${encodeURIComponent(JSON.stringify(a))}&secret=${r.nostrConnectSecret}${s?`&relay=${s}`:""}`})()}getNostrConnectServices(){var s=this;return(0,_home_runner_work_angor_hub_angor_hub_node_modules_angular_builders_custom_webpack_node_modules_babel_runtime_helpers_esm_asyncToGenerator_js__WEBPACK_IMPORTED_MODULE_1__.A)(function*(){const r=yield s.createNostrConnect(),i=NOSTRCONNECT_APPS.map(a=>({...a}));for(const a of i){let c=DEFAULT_NOSTRCONNECT_RELAY;if(a.link.startsWith("https://")){let w=a.domain||new URL(a.link).hostname;try{const C=yield(yield fetch(`https://${w}/.well-known/nostr.json`)).json(),S=C.nip46[C.names._];S&&S.length&&(c=S[0]),a.iframeUrl=C.nip46.iframe_url||""}catch(C){console.log("Bad app info",C,a)}}const y=r+"&relay="+c;a.link=a.iframeUrl?y:a.link.replace("",y)}return[r,i]})()}localSignup(s){var r=this;return(0,_home_runner_work_angor_hub_angor_hub_node_modules_angular_builders_custom_webpack_node_modules_babel_runtime_helpers_esm_asyncToGenerator_js__WEBPACK_IMPORTED_MODULE_1__.A)(function*(){const i=generatePrivateKey(),a={pubkey:getPublicKey(i),sk:i,name:s,authMethod:"local"};console.log(`localSignup name: ${s}`),yield r.setLocal(a,!0)})()}setLocal(s,r){var i=this;return(0,_home_runner_work_angor_hub_angor_hub_node_modules_angular_builders_custom_webpack_node_modules_babel_runtime_helpers_esm_asyncToGenerator_js__WEBPACK_IMPORTED_MODULE_1__.A)(function*(){i.releaseSigner(),i.localSigner=new PrivateKeySigner(s.sk),r&&(yield createProfile(s,i.profileNdk,i.localSigner,i.params.optionsModal.signupRelays)),i.onAuth("login",s)})()}prepareImportUrl(s){if("otp"===this.params.userInfo?.authMethod)return s+"&import=true";if(!this.localSigner||"local"!==this.params.userInfo?.authMethod)throw new Error("Most be local keys");return s+"#import="+nip19_exports.nsecEncode(this.localSigner.privateKey)}importAndConnect(s){var r=this;return(0,_home_runner_work_angor_hub_angor_hub_node_modules_angular_builders_custom_webpack_node_modules_babel_runtime_helpers_esm_asyncToGenerator_js__WEBPACK_IMPORTED_MODULE_1__.A)(function*(){const{relay:i,domain:a,link:c,iframeUrl:y}=s;if(!a)throw new Error("Domain required");const w=yield r.nostrConnect(i,{domain:a,link:c,importConnect:!0,iframeUrl:y});yield r.logout(!0),r.localSigner=null,r.onAuth("login",w)})()}setReadOnly(s){this.onAuth("login",{pubkey:s,authMethod:"readOnly"})}setExtension(s){this.onAuth("login",{pubkey:s,authMethod:"extension"})}setOTP(s,r){this.onAuth("login",{pubkey:s,authMethod:"otp",otpData:r})}setConnect(s){var r=this;return(0,_home_runner_work_angor_hub_angor_hub_node_modules_angular_builders_custom_webpack_node_modules_babel_runtime_helpers_esm_asyncToGenerator_js__WEBPACK_IMPORTED_MODULE_1__.A)(function*(){r.releaseSigner(),yield r.startAuth(),yield r.initSigner(s),r.onAuth("login",s),yield r.endAuth()})()}createAccount(s){var r=this;return(0,_home_runner_work_angor_hub_angor_hub_node_modules_angular_builders_custom_webpack_node_modules_babel_runtime_helpers_esm_asyncToGenerator_js__WEBPACK_IMPORTED_MODULE_1__.A)(function*(){const[i,a]=s.split("@"),c=yield getBunkerUrl(`_@${a}`,r.params.optionsModal);console.log("create account bunker's url",c);const y=bunkerUrlToInfo(c),w=!!r.params.userInfo;yield r.initSigner(y,{eventToAddAccount:w});const C=[i,a,"",r.params.optionsModal.perms||""];console.log("signer",r.signer);const T=yield new Promise(S=>{r.signer.rpc.sendRequest(y.pubkey,"create_account",C,void 0,S)});if(console.log("create_account pubkey",T),"error"===T.result)throw new Error(T.error);return{bunkerUrl:`bunker://${T.result}?relay=${y.relays?.[0]}`,sk:y.sk}})()}releaseSigner(){this.signer=null,this.localSigner=null;for(const s of this.ndk.pool.relays.keys())this.ndk.pool.removeRelay(s)}logout(s=!1){var r=this;return(0,_home_runner_work_angor_hub_angor_hub_node_modules_angular_builders_custom_webpack_node_modules_babel_runtime_helpers_esm_asyncToGenerator_js__WEBPACK_IMPORTED_MODULE_1__.A)(function*(){s||r.releaseSigner(),localStorageRemoveCurrentAccount(),r.onAuth("logout"),r.emit("updateAccounts")})()}setUserInfo(s){this.params.userInfo=s,this.emit("onUserInfo",s),s&&(localStorageAddAccount(s),this.emit("updateAccounts"))}exportKeys(){return this.params.userInfo?"local"!==this.params.userInfo.authMethod?"":nip19_exports.nsecEncode(this.params.userInfo.sk):""}onAuth(s,r=null){if("logout"!==s&&!r)throw new Error("No user info in onAuth");if(r&&this.params.userInfo&&(r.pubkey!==this.params.userInfo.pubkey||r.authMethod!==this.params.userInfo.authMethod)){const i=new CustomEvent("nlAuth",{detail:{type:"logout"}});console.log("nostr-login auth",i.detail),document.dispatchEvent(i)}this.setUserInfo(r),r&&fetchProfile(r,this.profileNdk).then(i=>{if(this.params.userInfo!==r)return;const a={...this.params.userInfo,picture:i?.image||i?.picture,name:i?.name||i?.displayName||i?.nip05||nip19_exports.npubEncode(r.pubkey)};this.setUserInfo(a)});try{const i=r?nip19_exports.npubEncode(r.pubkey):"",a={type:s};"logout"===s?(this.iframe&&this.iframe.remove(),this.iframe=void 0):(a.pubkey=r.pubkey,r.sk&&(a.localNsec=nip19_exports.nsecEncode(r.sk)),r.relays&&(a.relays=r.relays),r.otpData&&(a.otpData=r.otpData),a.method=r.authMethod||"connect");const c=new CustomEvent("nlAuth",{detail:a});console.log("nostr-login auth",a),document.dispatchEvent(c),this.params.optionsModal.onAuth&&this.params.optionsModal.onAuth(i,a)}catch(i){console.log("onAuth error",i)}}createIframe(s){return(0,_home_runner_work_angor_hub_angor_hub_node_modules_angular_builders_custom_webpack_node_modules_babel_runtime_helpers_esm_asyncToGenerator_js__WEBPACK_IMPORTED_MODULE_1__.A)(function*(){if(!s)return;const r=new URL(s);let i;const a="__nostr-login-worker-iframe-"+r.hostname.replaceAll(".","-");i=document.querySelector(`#${a}`),console.log("iframe",a,i),i||(i=document.createElement("iframe"),i.setAttribute("width","0"),i.setAttribute("height","0"),i.setAttribute("border","0"),i.style.display="none",i.id=a,document.body.append(i)),i.setAttribute("src",s);const c=new ReadyListener(["workerReady","workerError"],r.origin);yield new Promise(w=>{i.addEventListener("load",w)});const y=yield c.wait();return console.log("nostr-login iframe ready",s,y),{iframe:i,port:y[1]}})()}startAuth(){var s=this;return(0,_home_runner_work_angor_hub_angor_hub_node_modules_angular_builders_custom_webpack_node_modules_babel_runtime_helpers_esm_asyncToGenerator_js__WEBPACK_IMPORTED_MODULE_1__.A)(function*(){if(s.readyCallback)throw new Error("Already started");s.readyPromise=new Promise(r=>s.readyCallback=r)})()}endAuth(){var s=this;return(0,_home_runner_work_angor_hub_angor_hub_node_modules_angular_builders_custom_webpack_node_modules_babel_runtime_helpers_esm_asyncToGenerator_js__WEBPACK_IMPORTED_MODULE_1__.A)(function*(){if(console.log("endAuth",s.params.userInfo),s.params.userInfo&&s.params.userInfo.iframeUrl){const{iframe:r,port:i}=(yield s.createIframe(s.params.userInfo.iframeUrl))||{};if(s.iframe=r,!s.iframe||!i)return;s.signer.rpc.setWorkerIframePort(i)}s.readyCallback(),s.readyCallback=void 0})()}resetAuth(){this.readyCallback&&this.readyCallback(),this.readyCallback=void 0}listen(s,r){var i=this;return(0,_home_runner_work_angor_hub_angor_hub_node_modules_angular_builders_custom_webpack_node_modules_babel_runtime_helpers_esm_asyncToGenerator_js__WEBPACK_IMPORTED_MODULE_1__.A)(function*(){if(console.log("listen",s,r),!s.iframeUrl)return r.listen(i.nostrConnectSecret);const a=yield i.starterReady.wait();if("starterError"===a[0])throw new Error(a[1]);return i.signer.rpc.parseNostrConnectReply(a[1],i.nostrConnectSecret)})()}initSigner(s,{listen:r=!1,connect:i=!1,eventToAddAccount:a=!1}={}){var c=this;return(0,_home_runner_work_angor_hub_angor_hub_node_modules_angular_builders_custom_webpack_node_modules_babel_runtime_helpers_esm_asyncToGenerator_js__WEBPACK_IMPORTED_MODULE_1__.A)(function*(){if(c.signerPromise)try{yield c.signerPromise}catch{}console.log("initSigner info",s);const y=s.iframeUrl?new URL(s.iframeUrl).origin:void 0;return y&&(c.starterReady=new ReadyListener(["starterDone","starterError"],y)),c.emit("onIframeUrl",s.iframeUrl),c.signerPromise=new Promise(function(){var w=(0,_home_runner_work_angor_hub_angor_hub_node_modules_angular_builders_custom_webpack_node_modules_babel_runtime_helpers_esm_asyncToGenerator_js__WEBPACK_IMPORTED_MODULE_1__.A)(function*(C,T){try{if(s.relays&&!s.iframeUrl)for(const L of s.relays)c.ndk.addExplicitRelay(L,void 0);yield c.ndk.connect();const S=getPublicKey(s.sk),M=new PrivateKeySigner(s.sk);c.signer=new NDKNip46Signer(c.ndk,s.pubkey,M);const O=new IframeNostrRpc(c.ndk,S,M,y);if(O.setUseNip44(!0),c.signer.rpc=O,O.on(`iframeRestart-${s.pubkey}`,(0,_home_runner_work_angor_hub_angor_hub_node_modules_angular_builders_custom_webpack_node_modules_babel_runtime_helpers_esm_asyncToGenerator_js__WEBPACK_IMPORTED_MODULE_1__.A)(function*(){const L=s.iframeUrl+(s.iframeUrl.includes("?")?"&":"?")+"pubkey="+s.pubkey+"&rebind="+S;c.emit("iframeRestart",{pubkey:s.pubkey,iframeUrl:L})})),r||O.on("authUrl",L=>{console.log("nostr login auth url",L),c.emit("onAuthUrl",{url:L,iframeUrl:s.iframeUrl,eventToAddAccount:a})}),r){const L=yield c.listen(s,O);c.signer.remotePubkey=L,c.signer.remoteUser=new NDKUser({pubkey:L}),s.pubkey=L,C(L)}else i&&(yield O.connect(s,c.params.optionsModal.perms)),C(void 0)}catch(S){console.log("initSigner failure",S),c.signer=null,T(S)}});return function(C,T){return w.apply(this,arguments)}}()),c.signerPromise})()}authNip46(s,{name:r,bunkerUrl:i,sk:a="",domain:c="",iframeUrl:y=""}){var w=this;return(0,_home_runner_work_angor_hub_angor_hub_node_modules_angular_builders_custom_webpack_node_modules_babel_runtime_helpers_esm_asyncToGenerator_js__WEBPACK_IMPORTED_MODULE_1__.A)(function*(){try{const C=bunkerUrlToInfo(i,a);if(isBunkerUrl(r)?C.bunkerUrl=r:(C.nip05=r,C.domain=r.split("@")[1]),c&&(C.domain=c),y&&(C.iframeUrl=y),!C.pubkey||!C.sk||!C.relays?.[0])throw new Error(`Bad bunker url ${i}`);const T=!!w.params.userInfo;console.log("authNip46",s,C),yield w.initSigner(C,{connect:!0,eventToAddAccount:T}),w.onAuth(s,C)}catch(C){throw console.log("nostr login auth failed",C),C}})()}signEvent(s){var r=this;return(0,_home_runner_work_angor_hub_angor_hub_node_modules_angular_builders_custom_webpack_node_modules_babel_runtime_helpers_esm_asyncToGenerator_js__WEBPACK_IMPORTED_MODULE_1__.A)(function*(){return r.localSigner?(s.pubkey=getPublicKey(r.localSigner.privateKey),s.id=getEventHash(s),s.sig=yield r.localSigner.sign(s)):(s.pubkey=r.signer?.remotePubkey,s.id=getEventHash(s),s.sig=yield r.signer?.sign(s)),console.log("signed",{event:s}),s})()}codec_call(s,r,i){var a=this;return(0,_home_runner_work_angor_hub_angor_hub_node_modules_angular_builders_custom_webpack_node_modules_babel_runtime_helpers_esm_asyncToGenerator_js__WEBPACK_IMPORTED_MODULE_1__.A)(function*(){return new Promise((c,y)=>{a.signer.rpc.sendRequest(a.signer.remotePubkey,s,[r,i],24133,w=>{w.error?y(w.error):c(w.result)})})})()}encrypt04(s,r){var i=this;return(0,_home_runner_work_angor_hub_angor_hub_node_modules_angular_builders_custom_webpack_node_modules_babel_runtime_helpers_esm_asyncToGenerator_js__WEBPACK_IMPORTED_MODULE_1__.A)(function*(){return i.localSigner?i.localSigner.encrypt(new NDKUser({pubkey:s}),r):i.signer.encrypt(new NDKUser({pubkey:s}),r)})()}decrypt04(s,r){var i=this;return(0,_home_runner_work_angor_hub_angor_hub_node_modules_angular_builders_custom_webpack_node_modules_babel_runtime_helpers_esm_asyncToGenerator_js__WEBPACK_IMPORTED_MODULE_1__.A)(function*(){return i.localSigner?i.localSigner.decrypt(new NDKUser({pubkey:s}),r):i.codec_call("nip04_decrypt",s,r)})()}encrypt44(s,r){var i=this;return(0,_home_runner_work_angor_hub_angor_hub_node_modules_angular_builders_custom_webpack_node_modules_babel_runtime_helpers_esm_asyncToGenerator_js__WEBPACK_IMPORTED_MODULE_1__.A)(function*(){return i.localSigner?i.nip44Codec.encrypt(i.localSigner.privateKey,s,r):i.codec_call("nip44_encrypt",s,r)})()}decrypt44(s,r){var i=this;return(0,_home_runner_work_angor_hub_angor_hub_node_modules_angular_builders_custom_webpack_node_modules_babel_runtime_helpers_esm_asyncToGenerator_js__WEBPACK_IMPORTED_MODULE_1__.A)(function*(){return i.localSigner?i.nip44Codec.decrypt(i.localSigner.privateKey,s,r):i.codec_call("nip44_decrypt",s,r)})()}}class ModalManager extends lib$1.EventEmitter{modal=null;params;extensionService;authNostrService;launcherPromise;accounts=[];recents=[];opt;constructor(s,r,i){super(),this.params=s,this.extensionService=i,this.authNostrService=r}waitReady(){var s=this;return(0,_home_runner_work_angor_hub_angor_hub_node_modules_angular_builders_custom_webpack_node_modules_babel_runtime_helpers_esm_asyncToGenerator_js__WEBPACK_IMPORTED_MODULE_1__.A)(function*(){if(s.launcherPromise){try{yield s.launcherPromise}catch{}s.launcherPromise=void 0}})()}launch(s){var r=this;return(0,_home_runner_work_angor_hub_angor_hub_node_modules_angular_builders_custom_webpack_node_modules_babel_runtime_helpers_esm_asyncToGenerator_js__WEBPACK_IMPORTED_MODULE_1__.A)(function*(){r.launcherPromise&&(yield r.waitReady()),r.opt=s;const i=document.createElement("dialog");r.modal=document.createElement("nl-auth"),r.modal.accounts=r.accounts,r.modal.recents=r.recents,r.modal.setAttribute("dark-mode",String(getDarkMode(s))),s.theme&&r.modal.setAttribute("theme",s.theme),s.startScreen&&r.modal.setAttribute("start-screen",s.startScreen),r.modal.setAttribute("bunkers",s.bunkers?s.bunkers:"nsec.app,highlighter.com"),void 0!==s.methods&&(r.modal.authMethods=s.methods),void 0!==s.localSignup&&(r.modal.localSignup=s.localSignup),s.title&&(r.modal.welcomeTitle=s.title),s.description&&(r.modal.welcomeDescription=s.description),r.modal.hasExtension=r.extensionService.hasExtension(),r.modal.hasOTP=!!s.otpRequestUrl&&!!s.otpReplyUrl,r.modal.isLoadingExtension=!1,r.modal.isLoading=!1,[r.modal.connectionString,r.modal.connectionStringServices]=yield r.authNostrService.getNostrConnectServices(),i.appendChild(r.modal),document.body.appendChild(i);let a="";return r.launcherPromise=new Promise((c,y)=>{i.addEventListener("close",()=>{y(new Error("Closed")),r.authNostrService.resetAuth(),r.modal&&(document.body.removeChild(r.modal.parentNode),r.modal=null)});const w=function(){var pe=(0,_home_runner_work_angor_hub_angor_hub_node_modules_angular_builders_custom_webpack_node_modules_babel_runtime_helpers_esm_asyncToGenerator_js__WEBPACK_IMPORTED_MODULE_1__.A)(function*(se){r.modal&&(r.modal.isLoading=!1),yield r.authNostrService.endAuth(),i.close(),r.modal=null,se()});return function(ae){return pe.apply(this,arguments)}}(),C=function(){var pe=(0,_home_runner_work_angor_hub_angor_hub_node_modules_angular_builders_custom_webpack_node_modules_babel_runtime_helpers_esm_asyncToGenerator_js__WEBPACK_IMPORTED_MODULE_1__.A)(function*(se,ae){r.modal&&(r.modal.isLoading=!0);try{ae&&!ae.start||(yield r.authNostrService.startAuth()),yield se(),ae&&!ae.end||(yield w(c))}catch(me){console.log("error",me),r.modal&&(r.modal.isLoading=!1,r.modal.authUrl="",r.modal.iframeUrl="",r.modal.error=me.toString())}});return function(ae,me){return pe.apply(this,arguments)}}(),T=function(){var pe=(0,_home_runner_work_angor_hub_angor_hub_node_modules_angular_builders_custom_webpack_node_modules_babel_runtime_helpers_esm_asyncToGenerator_js__WEBPACK_IMPORTED_MODULE_1__.A)(function*(se,ae){yield C((0,_home_runner_work_angor_hub_angor_hub_node_modules_angular_builders_custom_webpack_node_modules_babel_runtime_helpers_esm_asyncToGenerator_js__WEBPACK_IMPORTED_MODULE_1__.A)(function*(){const me=yield getBunkerUrl(se,r.params.optionsModal);yield r.authNostrService.authNip46("login",{name:se,bunkerUrl:me,domain:ae})}))});return function(ae,me){return pe.apply(this,arguments)}}(),S=function(){var pe=(0,_home_runner_work_angor_hub_angor_hub_node_modules_angular_builders_custom_webpack_node_modules_babel_runtime_helpers_esm_asyncToGenerator_js__WEBPACK_IMPORTED_MODULE_1__.A)(function*(se){yield C((0,_home_runner_work_angor_hub_angor_hub_node_modules_angular_builders_custom_webpack_node_modules_babel_runtime_helpers_esm_asyncToGenerator_js__WEBPACK_IMPORTED_MODULE_1__.A)(function*(){const{bunkerUrl:ae,sk:me}=yield r.authNostrService.createAccount(se);yield r.authNostrService.authNip46("signup",{name:se,bunkerUrl:ae,sk:me})}))});return function(ae){return pe.apply(this,arguments)}}(),M=function(){var pe=(0,_home_runner_work_angor_hub_angor_hub_node_modules_angular_builders_custom_webpack_node_modules_babel_runtime_helpers_esm_asyncToGenerator_js__WEBPACK_IMPORTED_MODULE_1__.A)(function*(){try{yield navigator.clipboard.writeText(r.authNostrService.exportKeys()),localStorageSetItem("backupKey","true")}catch(se){console.error("Failed to copy to clipboard: ",se)}});return function(){return pe.apply(this,arguments)}}(),O=function(){var pe=(0,_home_runner_work_angor_hub_angor_hub_node_modules_angular_builders_custom_webpack_node_modules_babel_runtime_helpers_esm_asyncToGenerator_js__WEBPACK_IMPORTED_MODULE_1__.A)(function*(se){yield C((0,_home_runner_work_angor_hub_angor_hub_node_modules_angular_builders_custom_webpack_node_modules_babel_runtime_helpers_esm_asyncToGenerator_js__WEBPACK_IMPORTED_MODULE_1__.A)(function*(){const{iframeUrl:ae}=se,me=r.authNostrService.prepareImportUrl(se.link);r.modal&&ae&&(r.modal.authUrl=me,r.modal.iframeUrl=ae,r.modal.isLoading=!1,console.log("nostrconnect authUrl",r.modal.authUrl,r.modal.iframeUrl)),yield r.authNostrService.importAndConnect(se)}))});return function(ae){return pe.apply(this,arguments)}}(),L=function(){var pe=(0,_home_runner_work_angor_hub_angor_hub_node_modules_angular_builders_custom_webpack_node_modules_babel_runtime_helpers_esm_asyncToGenerator_js__WEBPACK_IMPORTED_MODULE_1__.A)(function*(se){yield C((0,_home_runner_work_angor_hub_angor_hub_node_modules_angular_builders_custom_webpack_node_modules_babel_runtime_helpers_esm_asyncToGenerator_js__WEBPACK_IMPORTED_MODULE_1__.A)(function*(){const{relay:ae,domain:me,link:be,iframeUrl:Oe}=se||{};console.log("nostrConnect",se,ae,me,be,Oe),r.modal&&(Oe&&(r.modal.authUrl=be,r.modal.iframeUrl=Oe,r.modal.isLoading=!1,console.log("nostrconnect authUrl",r.modal.authUrl,r.modal.iframeUrl)),se||(r.modal.isLoading=!1)),yield r.authNostrService.nostrConnect(ae,{domain:me,link:be,iframeUrl:Oe})}))});return function(ae){return pe.apply(this,arguments)}}(),Z=function(){var pe=(0,_home_runner_work_angor_hub_angor_hub_node_modules_angular_builders_custom_webpack_node_modules_babel_runtime_helpers_esm_asyncToGenerator_js__WEBPACK_IMPORTED_MODULE_1__.A)(function*(se){yield C((0,_home_runner_work_angor_hub_angor_hub_node_modules_angular_builders_custom_webpack_node_modules_babel_runtime_helpers_esm_asyncToGenerator_js__WEBPACK_IMPORTED_MODULE_1__.A)(function*(){if(!se)throw new Error("Please enter some nickname");yield r.authNostrService.localSignup(se)}))});return function(ae){return pe.apply(this,arguments)}}();if(!r.modal)throw new Error("WTH?");r.modal.addEventListener("handleContinue",()=>{r.modal&&(r.modal.isLoading=!0,r.emit("onAuthUrlClick",r.modal.authUrl))}),r.modal.addEventListener("nlLogin",pe=>{T(pe.detail)}),r.modal.addEventListener("nlSignup",pe=>{S(pe.detail)}),r.modal.addEventListener("nlLocalSignup",pe=>{Z(pe.detail)}),r.modal.addEventListener("nlImportAccount",pe=>{O(pe.detail)}),r.modal.addEventListener("nlExportKeys",pe=>{M()}),r.modal.addEventListener("handleLogoutBanner",()=>{r.emit("onLogoutBanner")}),r.modal.addEventListener("nlNostrConnect",pe=>{L(pe.detail)}),r.modal.addEventListener("nlNostrConnectDefault",()=>{L()}),r.modal.addEventListener("nlSwitchAccount",pe=>{r.emit("onSwitchAccount",pe.detail),setTimeout(()=>i.close(),300)}),r.modal.addEventListener("nlLoginRecentAccount",function(){var pe=(0,_home_runner_work_angor_hub_angor_hub_node_modules_angular_builders_custom_webpack_node_modules_babel_runtime_helpers_esm_asyncToGenerator_js__WEBPACK_IMPORTED_MODULE_1__.A)(function*(se){const ae=se.detail;if("readOnly"===ae.authMethod)r.authNostrService.setReadOnly(ae.pubkey),i.close();else if("otp"===ae.authMethod)try{r.modal.dispatchEvent(new CustomEvent("nlLoginOTPUser",{detail:ae.nip05||ae.pubkey}))}catch(me){console.error(me)}else if("extension"===ae.authMethod)yield r.extensionService.trySetExtensionForPubkey(ae.pubkey),i.close();else{const me=ae.bunkerUrl||ae.nip05;if(!me)throw new Error("Bad connect info");T(me,ae.domain)}});return function(se){return pe.apply(this,arguments)}}()),r.modal.addEventListener("nlRemoveRecent",pe=>{localStorageRemoveRecent(pe.detail),r.emit("updateAccounts")});const q=function(){var pe=(0,_home_runner_work_angor_hub_angor_hub_node_modules_angular_builders_custom_webpack_node_modules_babel_runtime_helpers_esm_asyncToGenerator_js__WEBPACK_IMPORTED_MODULE_1__.A)(function*(se){let ae="";if(se.includes("@")){const{error:me,pubkey:be}=yield checkNip05(se);if(!be)throw new Error(me);ae=be}else if(se.startsWith("npub")){const{type:me,data:be}=nip19_exports.decode(se);if("npub"!==me)throw new Error("Bad npub");ae=be}else 64===se.trim().length&&(ae=se.trim(),nip19_exports.npubEncode(ae));return ae});return function(ae){return pe.apply(this,arguments)}}();r.modal.addEventListener("nlLoginReadOnly",function(){var pe=(0,_home_runner_work_angor_hub_angor_hub_node_modules_angular_builders_custom_webpack_node_modules_babel_runtime_helpers_esm_asyncToGenerator_js__WEBPACK_IMPORTED_MODULE_1__.A)(function*(se){yield C((0,_home_runner_work_angor_hub_angor_hub_node_modules_angular_builders_custom_webpack_node_modules_babel_runtime_helpers_esm_asyncToGenerator_js__WEBPACK_IMPORTED_MODULE_1__.A)(function*(){const ae=se.detail,me=yield q(ae);r.authNostrService.setReadOnly(me)}))});return function(se){return pe.apply(this,arguments)}}()),r.modal.addEventListener("nlLoginExtension",(0,_home_runner_work_angor_hub_angor_hub_node_modules_angular_builders_custom_webpack_node_modules_babel_runtime_helpers_esm_asyncToGenerator_js__WEBPACK_IMPORTED_MODULE_1__.A)(function*(){if(!r.extensionService.hasExtension())throw new Error("No extension");yield C((0,_home_runner_work_angor_hub_angor_hub_node_modules_angular_builders_custom_webpack_node_modules_babel_runtime_helpers_esm_asyncToGenerator_js__WEBPACK_IMPORTED_MODULE_1__.A)(function*(){r.modal&&(r.modal.isLoadingExtension=!0,yield r.extensionService.setExtension(),r.modal.isLoadingExtension=!1)}))})),r.modal.addEventListener("nlLoginOTPUser",function(){var pe=(0,_home_runner_work_angor_hub_angor_hub_node_modules_angular_builders_custom_webpack_node_modules_babel_runtime_helpers_esm_asyncToGenerator_js__WEBPACK_IMPORTED_MODULE_1__.A)(function*(se){yield C((0,_home_runner_work_angor_hub_angor_hub_node_modules_angular_builders_custom_webpack_node_modules_babel_runtime_helpers_esm_asyncToGenerator_js__WEBPACK_IMPORTED_MODULE_1__.A)(function*(){if(!r.modal)return;const ae=se.detail,me=yield q(ae),be=r.opt.otpRequestUrl+(r.opt.otpRequestUrl.includes("?")?"&":"?")+"pubkey="+me,Oe=yield fetch(be);if(200!==Oe.status)throw console.warn("nostr-login: bad otp reply",Oe),new Error("Failed to send DM");r.modal.isOTP=!0,a=me,r.modal.isLoading=!1}),{start:!0})});return function(se){return pe.apply(this,arguments)}}()),r.modal.addEventListener("nlLoginOTPCode",function(){var pe=(0,_home_runner_work_angor_hub_angor_hub_node_modules_angular_builders_custom_webpack_node_modules_babel_runtime_helpers_esm_asyncToGenerator_js__WEBPACK_IMPORTED_MODULE_1__.A)(function*(se){yield C((0,_home_runner_work_angor_hub_angor_hub_node_modules_angular_builders_custom_webpack_node_modules_babel_runtime_helpers_esm_asyncToGenerator_js__WEBPACK_IMPORTED_MODULE_1__.A)(function*(){if(!r.modal)return;const ae=se.detail,me=r.opt.otpReplyUrl+(r.opt.otpRequestUrl.includes("?")?"&":"?")+"pubkey="+a+"&code="+ae,be=yield fetch(me);if(200!==be.status)throw console.warn("nostr-login: bad otp reply",be),new Error("Invalid code");const Oe=yield be.text();r.authNostrService.setOTP(a,Oe),r.modal.isOTP=!1}),{end:!0})});return function(se){return pe.apply(this,arguments)}}()),r.modal.addEventListener("nlCheckSignup",function(){var pe=(0,_home_runner_work_angor_hub_angor_hub_node_modules_angular_builders_custom_webpack_node_modules_babel_runtime_helpers_esm_asyncToGenerator_js__WEBPACK_IMPORTED_MODULE_1__.A)(function*(se){const{available:ae,taken:me,error:be}=yield checkNip05(se.detail);r.modal&&(r.modal.error=String(be),!be&&me&&(r.modal.error="Already taken"),r.modal.signupNameIsAvailable=ae)});return function(se){return pe.apply(this,arguments)}}()),r.modal.addEventListener("nlCheckLogin",function(){var pe=(0,_home_runner_work_angor_hub_angor_hub_node_modules_angular_builders_custom_webpack_node_modules_babel_runtime_helpers_esm_asyncToGenerator_js__WEBPACK_IMPORTED_MODULE_1__.A)(function*(se){const{available:ae,taken:me,error:be}=yield checkNip05(se.detail);r.modal&&(r.modal.error=String(be),ae&&(r.modal.error="Name not found"),r.modal.loginIsGood=me)});return function(se){return pe.apply(this,arguments)}}());const re=()=>{r.modal&&(r.modal.isLoading=!1),i.close(),y(new Error("Cancelled"))};r.modal.addEventListener("stopFetchHandler",re),r.modal.addEventListener("nlCloseModal",re),r.modal.addEventListener("nlChangeDarkMode",pe=>{setDarkMode(pe.detail),document.dispatchEvent(new CustomEvent("nlDarkMode",{detail:pe.detail}))}),r.on("onIframeAuthUrlCallEnd",()=>{i.close(),r.modal=null,c()}),i.showModal()}),r.launcherPromise})()}showIframeUrl(s){var r=this;return(0,_home_runner_work_angor_hub_angor_hub_node_modules_angular_builders_custom_webpack_node_modules_babel_runtime_helpers_esm_asyncToGenerator_js__WEBPACK_IMPORTED_MODULE_1__.A)(function*(){yield r.waitReady(),r.launch({startScreen:"iframe"}).catch(()=>console.log("closed auth iframe")),r.modal.authUrl=s})()}connectModals(s){var r=this;const i=function(){var c=(0,_home_runner_work_angor_hub_angor_hub_node_modules_angular_builders_custom_webpack_node_modules_babel_runtime_helpers_esm_asyncToGenerator_js__WEBPACK_IMPORTED_MODULE_1__.A)(function*(y){yield r.launch(y)});return function(w){return c.apply(this,arguments)}}(),a=document.getElementsByTagName("nl-button");for(let c=0;c{this.checkExtension(s)&&clearTimeout(r)},100)}checkExtension(s){return!(this.nostrExtension||!window.nostr||window.nostr===s||(this.initExtension(s),0))}initExtension(s,r){var i=this;return(0,_home_runner_work_angor_hub_angor_hub_node_modules_angular_builders_custom_webpack_node_modules_babel_runtime_helpers_esm_asyncToGenerator_js__WEBPACK_IMPORTED_MODULE_1__.A)(function*(){i.nostrExtension=window.nostr,window.nostr=s,"extension"===i.params.userInfo?.authMethod&&(yield i.trySetExtensionForPubkey(i.params.userInfo.pubkey)),r||setTimeout(()=>{window.nostr!==s&&i.nostrExtension!==window.nostr&&i.initExtension(s,!0)},300)})()}setExtensionReadPubkey(s){var r=this;return(0,_home_runner_work_angor_hub_angor_hub_node_modules_angular_builders_custom_webpack_node_modules_babel_runtime_helpers_esm_asyncToGenerator_js__WEBPACK_IMPORTED_MODULE_1__.A)(function*(){window.nostr=r.nostrExtension;const i=yield window.nostr.getPublicKey();s&&s!==i?r.emit("extensionLogout"):r.emit("extensionLogin",i)})()}trySetExtensionForPubkey(s){var r=this;return(0,_home_runner_work_angor_hub_angor_hub_node_modules_angular_builders_custom_webpack_node_modules_babel_runtime_helpers_esm_asyncToGenerator_js__WEBPACK_IMPORTED_MODULE_1__.A)(function*(){if(r.nostrExtension)return r.setExtensionReadPubkey(s)})()}setExtension(){var s=this;return(0,_home_runner_work_angor_hub_angor_hub_node_modules_angular_builders_custom_webpack_node_modules_babel_runtime_helpers_esm_asyncToGenerator_js__WEBPACK_IMPORTED_MODULE_1__.A)(function*(){return s.setExtensionReadPubkey()})()}unsetExtension(s){window.nostr===this.nostrExtension&&(window.nostr=s)}getExtension(){return this.nostrExtension}hasExtension(){return!!this.nostrExtension}}class NostrParams{userInfo;optionsModal;constructor(){this.userInfo=null,this.optionsModal={theme:"default",startScreen:"welcome",devOverrideBunkerOrigin:""}}}class Popup{popup=null;constructor(){}openPopup(s){if((!this.popup||this.popup.closed)&&(this.popup=window.open(s,"_blank","width=400,height=700"),console.log("popup",this.popup),!this.popup))throw new Error("Popup blocked. Try again, please!")}closePopup(){try{this.popup?.close(),this.popup=null}catch{}}}const CALL_TIMEOUT=5e3;class ProcessManager extends lib$1.EventEmitter{callCount=0;callTimer;constructor(){super()}onAuthUrl(){this.callTimer&&clearTimeout(this.callTimer)}onIframeUrl(){this.callTimer&&clearTimeout(this.callTimer)}wait(s){var r=this;return(0,_home_runner_work_angor_hub_angor_hub_node_modules_angular_builders_custom_webpack_node_modules_babel_runtime_helpers_esm_asyncToGenerator_js__WEBPACK_IMPORTED_MODULE_1__.A)(function*(){let i,a;r.callTimer||(r.callTimer=setTimeout(()=>r.emit("onCallTimeout"),CALL_TIMEOUT)),r.callCount||r.emit("onCallStart"),r.callCount++;try{a=yield s()}catch(c){i=c}if(r.callCount--,r.emit("onCallEnd"),r.callTimer&&clearTimeout(r.callTimer),r.callTimer=void 0,i)throw i;return a})()}}class NostrLoginInitializer{extensionService;params;authNostrService;nostr;processManager;popupManager;bannerManager;modalManager;constructor(){var s=this;this.params=new NostrParams,this.processManager=new ProcessManager,this.popupManager=new Popup,this.bannerManager=new BannerManager(this.params),this.authNostrService=new AuthNostrService(this.params),this.extensionService=new NostrExtensionService(this.params),this.modalManager=new ModalManager(this.params,this.authNostrService,this.extensionService);const r={waitReady:(i=(0,_home_runner_work_angor_hub_angor_hub_node_modules_angular_builders_custom_webpack_node_modules_babel_runtime_helpers_esm_asyncToGenerator_js__WEBPACK_IMPORTED_MODULE_1__.A)(function*(){yield s.authNostrService.waitReady(),yield s.modalManager.waitReady()}),function(){return i.apply(this,arguments)}),getUserInfo:()=>this.params.userInfo,getSigner:()=>{if("readOnly"===this.params.userInfo.authMethod)throw new Error("Read only");return"extension"===this.params.userInfo.authMethod?this.extensionService.getExtension():this.authNostrService},launch:()=>this.launch(),wait:i=>this.processManager.wait(i)};var i;this.nostr=new Nostr(r),this.processManager.on("onCallTimeout",()=>{this.bannerManager.onCallTimeout()}),this.processManager.on("onCallEnd",()=>{this.bannerManager.onCallEnd(),this.modalManager.onCallEnd()}),this.processManager.on("onCallStart",()=>{this.bannerManager.onCallStart()}),this.authNostrService.on("onIframeUrl",i=>{this.modalManager.onIframeUrl(i)}),this.authNostrService.on("iframeRestart",({iframeUrl:i})=>{this.processManager.onIframeUrl(),this.bannerManager.onIframeRestart(i)}),this.authNostrService.on("onAuthUrl",({url:i,iframeUrl:a,eventToAddAccount:c})=>{this.processManager.onAuthUrl(),c?this.modalManager.onAuthUrl(i):this.params.userInfo?this.bannerManager.onAuthUrl(i,a):this.modalManager.onAuthUrl(i)}),this.authNostrService.on("updateAccounts",()=>{this.updateAccounts()}),this.authNostrService.on("onUserInfo",i=>{this.bannerManager.onUserInfo(i)}),this.modalManager.on("onAuthUrlClick",i=>{this.openPopup(i)}),this.bannerManager.on("onIframeAuthUrlClick",i=>{this.modalManager.showIframeUrl(i)}),this.modalManager.on("onSwitchAccount",function(){var i=(0,_home_runner_work_angor_hub_angor_hub_node_modules_angular_builders_custom_webpack_node_modules_babel_runtime_helpers_esm_asyncToGenerator_js__WEBPACK_IMPORTED_MODULE_1__.A)(function*(a){s.switchAccount(a)});return function(a){return i.apply(this,arguments)}}()),this.modalManager.on("onLogoutBanner",function(){var i=(0,_home_runner_work_angor_hub_angor_hub_node_modules_angular_builders_custom_webpack_node_modules_babel_runtime_helpers_esm_asyncToGenerator_js__WEBPACK_IMPORTED_MODULE_1__.A)(function*(a){logout()});return function(a){return i.apply(this,arguments)}}()),this.bannerManager.on("onConfirmLogout",(0,_home_runner_work_angor_hub_angor_hub_node_modules_angular_builders_custom_webpack_node_modules_babel_runtime_helpers_esm_asyncToGenerator_js__WEBPACK_IMPORTED_MODULE_1__.A)(function*(){console.log(4),s.launch("confirm-logout")})),this.modalManager.on("updateAccounts",()=>{this.updateAccounts()}),this.bannerManager.on("logout",()=>{logout()}),this.bannerManager.on("onAuthUrlClick",i=>{this.openPopup(i)}),this.bannerManager.on("onSwitchAccount",function(){var i=(0,_home_runner_work_angor_hub_angor_hub_node_modules_angular_builders_custom_webpack_node_modules_babel_runtime_helpers_esm_asyncToGenerator_js__WEBPACK_IMPORTED_MODULE_1__.A)(function*(a){s.switchAccount(a)});return function(a){return i.apply(this,arguments)}}()),this.bannerManager.on("import",()=>{this.launch("import")}),this.extensionService.on("extensionLogin",i=>{this.authNostrService.setExtension(i)}),this.extensionService.on("extensionLogout",()=>{logout()}),this.bannerManager.on("launch",i=>{this.launch(i)})}openPopup(s){this.popupManager.openPopup(s)}switchAccount(s){var r=this;return(0,_home_runner_work_angor_hub_angor_hub_node_modules_angular_builders_custom_webpack_node_modules_babel_runtime_helpers_esm_asyncToGenerator_js__WEBPACK_IMPORTED_MODULE_1__.A)(function*(){if(console.log("nostr login switch to info",s),r.extensionService.unsetExtension(r.nostr),"readOnly"===s.authMethod)r.authNostrService.setReadOnly(s.pubkey);else if("otp"===s.authMethod)r.authNostrService.setOTP(s.pubkey,s.otpData||"");else if("local"===s.authMethod&&s.sk)r.authNostrService.setLocal(s);else if("extension"===s.authMethod)yield r.extensionService.trySetExtensionForPubkey(s.pubkey);else{if(!("connect"===s.authMethod&&s.sk&&s.relays&&s.relays[0]))throw new Error("Bad auth info");r.authNostrService.setConnect(s)}})()}updateAccounts(){const s=localStorageGetAccounts(),r=localStorageGetRecents();this.bannerManager.onUpdateAccounts(s),this.modalManager.onUpdateAccounts(s,r)}launch=s=>{const r=localStorageGetRecents(),i=localStorageGetAccounts(),a=s?{startScreen:s}:this.params.optionsModal;return s||!r?.length&&!i?.length||(a.startScreen="switch-account"),this.modalManager.launch(a).catch(()=>{})};init=(()=>{var r,s=this;return r=(0,_home_runner_work_angor_hub_angor_hub_node_modules_angular_builders_custom_webpack_node_modules_babel_runtime_helpers_esm_asyncToGenerator_js__WEBPACK_IMPORTED_MODULE_1__.A)(function*(i){s.extensionService.startCheckingExtension(s.nostr),window.nostr=s.nostr,s.modalManager.connectModals(i),s.bannerManager.launchAuthBanner(i),i&&(s.params.optionsModal={...i});try{const a=localStorageGetCurrent();if(a){if(!a.pubkey)throw new Error("Bad stored info");yield s.switchAccount(a)}}catch(a){console.log("nostr login init error",a),yield logout()}s.updateAccounts()}),function(i){return r.apply(this,arguments)}})();logout=(()=>{var s=this;return(0,_home_runner_work_angor_hub_angor_hub_node_modules_angular_builders_custom_webpack_node_modules_babel_runtime_helpers_esm_asyncToGenerator_js__WEBPACK_IMPORTED_MODULE_1__.A)(function*(){s.extensionService.unsetExtension(s.nostr),yield s.authNostrService.logout()})})();setDarkMode=s=>{localStorageSetItem("nl-dark-mode",`${s}`),this.bannerManager.onDarkMode(s),this.modalManager.onDarkMode(s)}}const initializer=new NostrLoginInitializer,{init,launch,logout,setDarkMode}=initializer;document.addEventListener("nlLogout",logout),document.addEventListener("nlLaunch",o=>{launch(o.detail||"")}),document.addEventListener("nlDarkMode",o=>{setDarkMode(!!o.detail)})},5492:(o,s,r)=>{"use strict";r.d(s,{lo:()=>Eh,pC:()=>Ja,Bq:()=>uu,dq:()=>Ql,lG:()=>du,sh:()=>Dh,Qe:()=>Cd});var i={};r.r(i),r.d(i,{OG:()=>W,My:()=>Mt,Ph:()=>en,lX:()=>kn,Id:()=>cn,fg:()=>mt,qj:()=>pr,aT:()=>Vt,lq:()=>Kn,z:()=>Nr,Q5:()=>Tn});var a=r(3014);function c(b){if(!Number.isSafeInteger(b)||b<0)throw new Error(`Wrong positive integer: ${b}`)}function w(b,...E){if(!(b instanceof Uint8Array))throw new Error("Expected Uint8Array");if(E.length>0&&!E.includes(b.length))throw new Error(`Expected Uint8Array of length ${E}, not of length=${b.length}`)}function T(b,E=!0){if(b.destroyed)throw new Error("Hash instance has been destroyed");if(E&&b.finished)throw new Error("Hash#digest() has already been called")}const L="object"==typeof globalThis&&"crypto"in globalThis?globalThis.crypto:void 0,Z=b=>b instanceof Uint8Array,pe=b=>new DataView(b.buffer,b.byteOffset,b.byteLength),se=(b,E)=>b<<32-E|b>>>E;if(68!==new Uint8Array(new Uint32Array([287454020]).buffer)[0])throw new Error("Non little-endian hardware is not supported");function Ce(b){if("string"==typeof b&&(b=function ue(b){if("string"!=typeof b)throw new Error("utf8ToBytes expected string, got "+typeof b);return new Uint8Array((new TextEncoder).encode(b))}(b)),!Z(b))throw new Error("expected Uint8Array, got "+typeof b);return b}class at{clone(){return this._cloneInto()}}function lt(b){const E=j=>b().update(Ce(j)).digest(),A=b();return E.outputLen=A.outputLen,E.blockLen=A.blockLen,E.create=()=>b(),E}function bn(b=32){if(L&&"function"==typeof L.getRandomValues)return L.getRandomValues(new Uint8Array(b));throw new Error("crypto.getRandomValues must be defined")}class yn extends at{constructor(E,A,j,X){super(),this.blockLen=E,this.outputLen=A,this.padOffset=j,this.isLE=X,this.finished=!1,this.length=0,this.pos=0,this.destroyed=!1,this.buffer=new Uint8Array(E),this.view=pe(this.buffer)}update(E){T(this);const{view:A,buffer:j,blockLen:X}=this,le=(E=Ce(E)).length;for(let Me=0;MeX-Me&&(this.process(j,0),Me=0);for(let Lt=Me;Lt>X&le),Pe=Number(A&le),wt=j?0:4;b.setUint32(E+(j?4:0),Me,j),b.setUint32(E+wt,Pe,j)})(j,X-8,BigInt(8*this.length),le),this.process(j,0);const Pe=pe(E),Qe=this.outputLen;if(Qe%4)throw new Error("_sha2: outputLen should be aligned to 32bit");const wt=Qe/4,Pt=this.get();if(wt>Pt.length)throw new Error("_sha2: outputLen bigger than state");for(let Lt=0;Ltb&E^~b&A,_t=(b,E,A)=>b&E^b&A^E&A,ze=new Uint32Array([1116352408,1899447441,3049323471,3921009573,961987163,1508970993,2453635748,2870763221,3624381080,310598401,607225278,1426881987,1925078388,2162078206,2614888103,3248222580,3835390401,4022224774,264347078,604807628,770255983,1249150122,1555081692,1996064986,2554220882,2821834349,2952996808,3210313671,3336571891,3584528711,113926993,338241895,666307205,773529912,1294757372,1396182291,1695183700,1986661051,2177026350,2456956037,2730485921,2820302411,3259730800,3345764771,3516065817,3600352804,4094571909,275423344,430227734,506948616,659060556,883997877,958139571,1322822218,1537002063,1747873779,1955562222,2024104815,2227730452,2361852424,2428436474,2756734187,3204031479,3329325298]),$e=new Uint32Array([1779033703,3144134277,1013904242,2773480762,1359893119,2600822924,528734635,1541459225]),Ft=new Uint32Array(64);class Ke extends yn{constructor(){super(64,32,8,!1),this.A=0|$e[0],this.B=0|$e[1],this.C=0|$e[2],this.D=0|$e[3],this.E=0|$e[4],this.F=0|$e[5],this.G=0|$e[6],this.H=0|$e[7]}get(){const{A:E,B:A,C:j,D:X,E:le,F:Me,G:Pe,H:Qe}=this;return[E,A,j,X,le,Me,Pe,Qe]}set(E,A,j,X,le,Me,Pe,Qe){this.A=0|E,this.B=0|A,this.C=0|j,this.D=0|X,this.E=0|le,this.F=0|Me,this.G=0|Pe,this.H=0|Qe}process(E,A){for(let Lt=0;Lt<16;Lt++,A+=4)Ft[Lt]=E.getUint32(A,!1);for(let Lt=16;Lt<64;Lt++){const nn=Ft[Lt-15],pn=Ft[Lt-2],tn=se(nn,7)^se(nn,18)^nn>>>3,Yt=se(pn,17)^se(pn,19)^pn>>>10;Ft[Lt]=Yt+Ft[Lt-7]+tn+Ft[Lt-16]|0}let{A:j,B:X,C:le,D:Me,E:Pe,F:Qe,G:wt,H:Pt}=this;for(let Lt=0;Lt<64;Lt++){const pn=Pt+(se(Pe,6)^se(Pe,11)^se(Pe,25))+qe(Pe,Qe,wt)+ze[Lt]+Ft[Lt]|0,Yt=(se(j,2)^se(j,13)^se(j,22))+_t(j,X,le)|0;Pt=wt,wt=Qe,Qe=Pe,Pe=Me+pn|0,Me=le,le=X,X=j,j=pn+Yt|0}j=j+this.A|0,X=X+this.B|0,le=le+this.C|0,Me=Me+this.D|0,Pe=Pe+this.E|0,Qe=Qe+this.F|0,wt=wt+this.G|0,Pt=Pt+this.H|0,this.set(j,X,le,Me,Pe,Qe,wt,Pt)}roundClean(){Ft.fill(0)}destroy(){this.set(0,0,0,0,0,0,0,0),this.buffer.fill(0)}}const it=lt(()=>new Ke),Te=(BigInt(0),BigInt(1)),Ee=BigInt(2),st=b=>b instanceof Uint8Array,Xt=Array.from({length:256},(b,E)=>E.toString(16).padStart(2,"0"));function Mt(b){if(!st(b))throw new Error("Uint8Array expected");let E="";for(let A=0;Aj+X.length,0));let A=0;return b.forEach(j=>{if(!st(j))throw new Error("Uint8Array expected");E.set(j,A),A+=j.length}),E}const W=b=>(Ee<new Uint8Array(b),ft=b=>Uint8Array.from(b);function mt(b,E,A){if("number"!=typeof b||b<2)throw new Error("hashLen must be a number");if("number"!=typeof E||E<2)throw new Error("qByteLen must be a number");if("function"!=typeof A)throw new Error("hmacFn must be a function");let j=Le(b),X=Le(b),le=0;const Me=()=>{j.fill(1),X.fill(0),le=0},Pe=(...Lt)=>A(X,j,...Lt),Qe=(Lt=Le())=>{X=Pe(ft([0]),Lt),j=Pe(),0!==Lt.length&&(X=Pe(ft([1]),Lt),j=Pe())},wt=()=>{if(le++>=1e3)throw new Error("drbg: tried 1000 values");let Lt=0;const nn=[];for(;Lt{let pn;for(Me(),Qe(Lt);!(pn=nn(wt()));)Qe();return Me(),pn}}const St={bigint:b=>"bigint"==typeof b,function:b=>"function"==typeof b,boolean:b=>"boolean"==typeof b,string:b=>"string"==typeof b,stringOrUint8Array:b=>"string"==typeof b||b instanceof Uint8Array,isSafeInteger:b=>Number.isSafeInteger(b),array:b=>Array.isArray(b),field:(b,E)=>E.Fp.isValid(b),hash:b=>"function"==typeof b&&Number.isSafeInteger(b.outputLen)};function Tn(b,E,A={}){const j=(X,le,Me)=>{const Pe=St[le];if("function"!=typeof Pe)throw new Error(`Invalid validator "${le}", expected function`);const Qe=b[X];if(!(Me&&void 0===Qe||Pe(Qe,b)))throw new Error(`Invalid param ${String(X)}=${Qe} (${typeof Qe}), expected ${le}`)};for(const[X,le]of Object.entries(E))j(X,le,!1);for(const[X,le]of Object.entries(A))j(X,le,!0);return b}const an=BigInt(0),dn=BigInt(1),In=BigInt(2),sr=BigInt(3),xn=BigInt(4),Hr=BigInt(5),Tr=BigInt(8);function Wt(b,E){const A=b%E;return A>=an?A:E+A}function Re(b,E,A){if(A<=an||E 0");if(A===dn)return an;let j=dn;for(;E>an;)E&dn&&(j=j*b%A),b=b*b%A,E>>=dn;return j}function Ge(b,E,A){let j=b;for(;E-- >an;)j*=j,j%=A;return j}function Ve(b,E){if(b===an||E<=an)throw new Error(`invert: expected positive integers, got n=${b} mod=${E}`);let A=Wt(b,E),j=E,X=an,le=dn,Me=dn,Pe=an;for(;A!==an;){const wt=j/A,Pt=j%A,Lt=X-Me*wt,nn=le-Pe*wt;j=A,A=Pt,X=Me,le=Pe,Me=Lt,Pe=nn}if(j!==dn)throw new Error("invert: does not exist");return Wt(X,E)}BigInt(9),BigInt(16);const wn=["create","isValid","is0","neg","inv","sqrt","sqr","eql","add","sub","mul","pow","div","addN","subN","mulN","sqrN"];function Jt(b,E){const A=void 0!==E?E:b.toString(2).length;return{nBitLength:A,nByteLength:Math.ceil(A/8)}}function mn(b){if("bigint"!=typeof b)throw new Error("field order must be bigint");const E=b.toString(2).length;return Math.ceil(E/8)}function dr(b){const E=mn(b);return E+Math.ceil(E/2)}class Ni extends at{constructor(E,A){super(),this.finished=!1,this.destroyed=!1,function C(b){if("function"!=typeof b||"function"!=typeof b.create)throw new Error("Hash should be wrapped by utils.wrapConstructor");c(b.outputLen),c(b.blockLen)}(E);const j=Ce(A);if(this.iHash=E.create(),"function"!=typeof this.iHash.update)throw new Error("Expected instance of class which extends utils.Hash");this.blockLen=this.iHash.blockLen,this.outputLen=this.iHash.outputLen;const X=this.blockLen,le=new Uint8Array(X);le.set(j.length>X?E.create().update(j).digest():j);for(let Me=0;Menew Ni(b,E).update(A).digest();ds.create=(b,E)=>new Ni(b,E);const $o=BigInt(0),ai=BigInt(1);function fo(b){return function qn(b){Tn(b,wn.reduce((j,X)=>(j[X]="function",j),{ORDER:"bigint",MASK:"bigint",BYTES:"isSafeInteger",BITS:"isSafeInteger"}))}(b.Fp),Tn(b,{n:"bigint",h:"bigint",Gx:"field",Gy:"field"},{nBitLength:"isSafeInteger",nByteLength:"isSafeInteger"}),Object.freeze({...Jt(b.n,b.nBitLength),...b,p:b.Fp.ORDER})}const{Ph:Fo,aT:oa}=i,ao={Err:class extends Error{constructor(E=""){super(E)}},_parseInt(b){const{Err:E}=ao;if(b.length<2||2!==b[0])throw new E("Invalid signature integer tag");const A=b[1],j=b.subarray(2,A+2);if(!A||j.length!==A)throw new E("Invalid signature integer: wrong length");if(128&j[0])throw new E("Invalid signature integer: negative");if(0===j[0]&&!(128&j[1]))throw new E("Invalid signature integer: unnecessary leading zero");return{d:Fo(j),l:b.subarray(A+2)}},toSig(b){const{Err:E}=ao,A="string"==typeof b?oa(b):b;if(!(A instanceof Uint8Array))throw new Error("ui8a expected");let j=A.length;if(j<2||48!=A[0])throw new E("Invalid signature tag");if(A[1]!==j-2)throw new E("Invalid signature: incorrect length");const{d:X,l:le}=ao._parseInt(A.subarray(2)),{d:Me,l:Pe}=ao._parseInt(le);if(Pe.length)throw new E("Invalid signature: left bytes after parsing");return{r:X,s:Me}},hexFromSig(b){const E=wt=>8&Number.parseInt(wt[0],16)?"00"+wt:wt,A=wt=>{const Pt=wt.toString(16);return 1&Pt.length?`0${Pt}`:Pt},j=E(A(b.s)),X=E(A(b.r)),le=j.length/2,Me=X.length/2,Pe=A(le),Qe=A(Me);return`30${A(Me+le+4)}02${Qe}${X}02${Pe}${j}`}},po=BigInt(0),Ii=BigInt(1),tt=(BigInt(2),BigInt(3));function Ye(b){const E=function ve(b){const E=fo(b);return Tn(E,{hash:"hash",hmac:"function",randomBytes:"function"},{bits2int:"function",bits2int_modN:"function",lowS:"boolean"}),Object.freeze({lowS:!0,...E})}(b),{Fp:A,n:j}=E,X=A.BYTES+1,le=2*A.BYTES+1;function Pe(rr){return Wt(rr,j)}function Qe(rr){return Ve(rr,j)}const{ProjectivePoint:wt,normPrivateKeyToScalar:Pt,weierstrassEquation:Lt,isWithinCurveOrder:nn}=function ht(b){const E=function Jo(b){const E=fo(b);Tn(E,{a:"field",b:"field"},{allowedPrivateKeyLengths:"array",wrapPrivateKey:"boolean",isTorsionFree:"function",clearCofactor:"function",allowInfinityPoint:"boolean",fromBytes:"function",toBytes:"function"});const{endo:A,Fp:j,a:X}=E;if(A){if(!j.eql(X,j.ZERO))throw new Error("Endomorphism can only be defined for Koblitz curves that have a=0");if("object"!=typeof A||"bigint"!=typeof A.beta||"function"!=typeof A.splitScalar)throw new Error("Expected endomorphism with beta: bigint and splitScalar: function")}return Object.freeze({...E})}(b),{Fp:A}=E,j=E.toBytes||((tn,Yt,Zt)=>{const vn=Yt.toAffine();return cn(Uint8Array.from([4]),A.toBytes(vn.x),A.toBytes(vn.y))}),X=E.fromBytes||(tn=>{const Yt=tn.subarray(1);return{x:A.fromBytes(Yt.subarray(0,A.BYTES)),y:A.fromBytes(Yt.subarray(A.BYTES,2*A.BYTES))}});function le(tn){const{a:Yt,b:Zt}=E,vn=A.sqr(tn),Sn=A.mul(vn,tn);return A.add(A.add(Sn,A.mul(tn,Yt)),Zt)}if(!A.eql(A.sqr(E.Gy),le(E.Gx)))throw new Error("bad generator point: equation left != right");function Me(tn){return"bigint"==typeof tn&&poA.eql(Zn,A.ZERO);return Sn(Zt)&&Sn(vn)?Lt.ZERO:new Lt(Zt,vn,A.ONE)}get x(){return this.toAffine().x}get y(){return this.toAffine().y}static normalizeZ(Yt){const Zt=A.invertBatch(Yt.map(vn=>vn.pz));return Yt.map((vn,Sn)=>vn.toAffine(Zt[Sn])).map(Lt.fromAffine)}static fromHex(Yt){const Zt=Lt.fromAffine(X(pr("pointHex",Yt)));return Zt.assertValidity(),Zt}static fromPrivateKey(Yt){return Lt.BASE.multiply(Qe(Yt))}_setWindowSize(Yt){this._WINDOW_SIZE=Yt,wt.delete(this)}assertValidity(){if(this.is0()){if(E.allowInfinityPoint&&!A.is0(this.py))return;throw new Error("bad point: ZERO")}const{x:Yt,y:Zt}=this.toAffine();if(!A.isValid(Yt)||!A.isValid(Zt))throw new Error("bad point: x or y not FE");const vn=A.sqr(Zt),Sn=le(Yt);if(!A.eql(vn,Sn))throw new Error("bad point: equation left != right");if(!this.isTorsionFree())throw new Error("bad point: not in prime-order subgroup")}hasEvenY(){const{y:Yt}=this.toAffine();if(A.isOdd)return!A.isOdd(Yt);throw new Error("Field doesn't support isOdd")}equals(Yt){Pt(Yt);const{px:Zt,py:vn,pz:Sn}=this,{px:Zn,py:or,pz:Lr}=Yt,mr=A.eql(A.mul(Zt,Lr),A.mul(Zn,Sn)),Ar=A.eql(A.mul(vn,Lr),A.mul(or,Sn));return mr&&Ar}negate(){return new Lt(this.px,A.neg(this.py),this.pz)}double(){const{a:Yt,b:Zt}=E,vn=A.mul(Zt,tt),{px:Sn,py:Zn,pz:or}=this;let Lr=A.ZERO,mr=A.ZERO,Ar=A.ZERO,$r=A.mul(Sn,Sn),Ri=A.mul(Zn,Zn),Ei=A.mul(or,or),ei=A.mul(Sn,Zn);return ei=A.add(ei,ei),Ar=A.mul(Sn,or),Ar=A.add(Ar,Ar),Lr=A.mul(Yt,Ar),mr=A.mul(vn,Ei),mr=A.add(Lr,mr),Lr=A.sub(Ri,mr),mr=A.add(Ri,mr),mr=A.mul(Lr,mr),Lr=A.mul(ei,Lr),Ar=A.mul(vn,Ar),Ei=A.mul(Yt,Ei),ei=A.sub($r,Ei),ei=A.mul(Yt,ei),ei=A.add(ei,Ar),Ar=A.add($r,$r),$r=A.add(Ar,$r),$r=A.add($r,Ei),$r=A.mul($r,ei),mr=A.add(mr,$r),Ei=A.mul(Zn,or),Ei=A.add(Ei,Ei),$r=A.mul(Ei,ei),Lr=A.sub(Lr,$r),Ar=A.mul(Ei,Ri),Ar=A.add(Ar,Ar),Ar=A.add(Ar,Ar),new Lt(Lr,mr,Ar)}add(Yt){Pt(Yt);const{px:Zt,py:vn,pz:Sn}=this,{px:Zn,py:or,pz:Lr}=Yt;let mr=A.ZERO,Ar=A.ZERO,$r=A.ZERO;const Ri=E.a,Ei=A.mul(E.b,tt);let ei=A.mul(Zt,Zn),eo=A.mul(vn,or),to=A.mul(Sn,Lr),wo=A.add(Zt,vn),rr=A.add(Zn,or);wo=A.mul(wo,rr),rr=A.add(ei,eo),wo=A.sub(wo,rr),rr=A.add(Zt,Sn);let hr=A.add(Zn,Lr);return rr=A.mul(rr,hr),hr=A.add(ei,to),rr=A.sub(rr,hr),hr=A.add(vn,Sn),mr=A.add(or,Lr),hr=A.mul(hr,mr),mr=A.add(eo,to),hr=A.sub(hr,mr),$r=A.mul(Ri,rr),mr=A.mul(Ei,to),$r=A.add(mr,$r),mr=A.sub(eo,$r),$r=A.add(eo,$r),Ar=A.mul(mr,$r),eo=A.add(ei,ei),eo=A.add(eo,ei),to=A.mul(Ri,to),rr=A.mul(Ei,rr),eo=A.add(eo,to),to=A.sub(ei,to),to=A.mul(Ri,to),rr=A.add(rr,to),ei=A.mul(eo,rr),Ar=A.add(Ar,ei),ei=A.mul(hr,rr),mr=A.mul(wo,mr),mr=A.sub(mr,ei),ei=A.mul(wo,eo),$r=A.mul(hr,$r),$r=A.add($r,ei),new Lt(mr,Ar,$r)}subtract(Yt){return this.add(Yt.negate())}is0(){return this.equals(Lt.ZERO)}wNAF(Yt){return pn.wNAFCached(this,wt,Yt,Zt=>{const vn=A.invertBatch(Zt.map(Sn=>Sn.pz));return Zt.map((Sn,Zn)=>Sn.toAffine(vn[Zn])).map(Lt.fromAffine)})}multiplyUnsafe(Yt){const Zt=Lt.ZERO;if(Yt===po)return Zt;if(Pe(Yt),Yt===Ii)return this;const{endo:vn}=E;if(!vn)return pn.unsafeLadder(this,Yt);let{k1neg:Sn,k1:Zn,k2neg:or,k2:Lr}=vn.splitScalar(Yt),mr=Zt,Ar=Zt,$r=this;for(;Zn>po||Lr>po;)Zn&Ii&&(mr=mr.add($r)),Lr&Ii&&(Ar=Ar.add($r)),$r=$r.double(),Zn>>=Ii,Lr>>=Ii;return Sn&&(mr=mr.negate()),or&&(Ar=Ar.negate()),Ar=new Lt(A.mul(Ar.px,vn.beta),Ar.py,Ar.pz),mr.add(Ar)}multiply(Yt){Pe(Yt);let vn,Sn,Zt=Yt;const{endo:Zn}=E;if(Zn){const{k1neg:or,k1:Lr,k2neg:mr,k2:Ar}=Zn.splitScalar(Zt);let{p:$r,f:Ri}=this.wNAF(Lr),{p:Ei,f:ei}=this.wNAF(Ar);$r=pn.constTimeNegate(or,$r),Ei=pn.constTimeNegate(mr,Ei),Ei=new Lt(A.mul(Ei.px,Zn.beta),Ei.py,Ei.pz),vn=$r.add(Ei),Sn=Ri.add(ei)}else{const{p:or,f:Lr}=this.wNAF(Zt);vn=or,Sn=Lr}return Lt.normalizeZ([vn,Sn])[0]}multiplyAndAddUnsafe(Yt,Zt,vn){const Sn=Lt.BASE,Zn=(Lr,mr)=>mr!==po&&mr!==Ii&&Lr.equals(Sn)?Lr.multiply(mr):Lr.multiplyUnsafe(mr),or=Zn(this,Zt).add(Zn(Yt,vn));return or.is0()?void 0:or}toAffine(Yt){const{px:Zt,py:vn,pz:Sn}=this,Zn=this.is0();null==Yt&&(Yt=Zn?A.ONE:A.inv(Sn));const or=A.mul(Zt,Yt),Lr=A.mul(vn,Yt),mr=A.mul(Sn,Yt);if(Zn)return{x:A.ZERO,y:A.ZERO};if(!A.eql(mr,A.ONE))throw new Error("invZ was invalid");return{x:or,y:Lr}}isTorsionFree(){const{h:Yt,isTorsionFree:Zt}=E;if(Yt===Ii)return!0;if(Zt)return Zt(Lt,this);throw new Error("isTorsionFree() has not been declared for the elliptic curve")}clearCofactor(){const{h:Yt,clearCofactor:Zt}=E;return Yt===Ii?this:Zt?Zt(Lt,this):this.multiplyUnsafe(E.h)}toRawBytes(Yt=!0){return this.assertValidity(),j(Lt,this,Yt)}toHex(Yt=!0){return Mt(this.toRawBytes(Yt))}}Lt.BASE=new Lt(E.Gx,E.Gy,A.ONE),Lt.ZERO=new Lt(A.ZERO,A.ONE,A.ZERO);const nn=E.nBitLength,pn=function qo(b,E){const A=(X,le)=>{const Me=le.negate();return X?Me:le},j=X=>({windows:Math.ceil(E/X)+1,windowSize:2**(X-1)});return{constTimeNegate:A,unsafeLadder(X,le){let Me=b.ZERO,Pe=X;for(;le>$o;)le&ai&&(Me=Me.add(Pe)),Pe=Pe.double(),le>>=ai;return Me},precomputeWindow(X,le){const{windows:Me,windowSize:Pe}=j(le),Qe=[];let wt=X,Pt=wt;for(let Lt=0;Lt>=pn,Zt>Qe&&(Zt-=nn,Me+=ai);const vn=Yt,Sn=Yt+Math.abs(Zt)-1,or=Zt<0;0===Zt?Pt=Pt.add(A(tn%2!=0,le[vn])):wt=wt.add(A(or,le[Sn]))}return{p:wt,f:Pt}},wNAFCached(X,le,Me,Pe){const Qe=X._WINDOW_SIZE||1;let wt=le.get(X);return wt||(wt=this.precomputeWindow(X,Qe),1!==Qe&&le.set(X,Pe(wt))),this.wNAF(Qe,wt,Me)}}}(Lt,E.endo?Math.ceil(nn/2):nn);return{CURVE:E,ProjectivePoint:Lt,normPrivateKeyToScalar:Qe,weierstrassEquation:le,isWithinCurveOrder:Me}}({...E,toBytes(rr,hr,Yr){const mi=hr.toAffine(),yr=A.toBytes(mi.x),oi=cn;return Yr?oi(Uint8Array.from([hr.hasEvenY()?2:3]),yr):oi(Uint8Array.from([4]),yr,A.toBytes(mi.y))},fromBytes(rr){const hr=rr.length,Yr=rr[0],mi=rr.subarray(1);if(hr!==X||2!==Yr&&3!==Yr){if(hr===le&&4===Yr)return{x:A.fromBytes(mi.subarray(0,A.BYTES)),y:A.fromBytes(mi.subarray(A.BYTES,2*A.BYTES))};throw new Error(`Point of length ${hr} was invalid. Expected ${X} compressed bytes or ${le} uncompressed bytes`)}{const yr=en(mi);if(!function Me(rr){return poMt(Kn(rr,E.nByteLength));function tn(rr){return rr>j>>Ii}const Zt=(rr,hr,Yr)=>en(rr.slice(hr,Yr));class vn{constructor(hr,Yr,mi){this.r=hr,this.s=Yr,this.recovery=mi,this.assertValidity()}static fromCompact(hr){const Yr=E.nByteLength;return hr=pr("compactSignature",hr,2*Yr),new vn(Zt(hr,0,Yr),Zt(hr,Yr,2*Yr))}static fromDER(hr){const{r:Yr,s:mi}=ao.toSig(pr("DER",hr));return new vn(Yr,mi)}assertValidity(){if(!nn(this.r))throw new Error("r must be 0 < r < CURVE.n");if(!nn(this.s))throw new Error("s must be 0 < s < CURVE.n")}addRecoveryBit(hr){return new vn(this.r,this.s,hr)}recoverPublicKey(hr){const{r:Yr,s:mi,recovery:yr}=this,oi=Ar(pr("msgHash",hr));if(null==yr||![0,1,2,3].includes(yr))throw new Error("recovery id invalid");const Eo=2===yr||3===yr?Yr+E.n:Yr;if(Eo>=A.ORDER)throw new Error("recovery id 2 or 3 invalid");const Bs=wt.fromHex((1&yr?"03":"02")+pn(Eo)),Na=Qe(Eo),rl=Pe(-oi*Na),gl=Pe(mi*Na),ba=wt.BASE.multiplyAndAddUnsafe(Bs,rl,gl);if(!ba)throw new Error("point at infinify");return ba.assertValidity(),ba}hasHighS(){return tn(this.s)}normalizeS(){return this.hasHighS()?new vn(this.r,Pe(-this.s),this.recovery):this}toDERRawBytes(){return Vt(this.toDERHex())}toDERHex(){return ao.hexFromSig({r:this.r,s:this.s})}toCompactRawBytes(){return Vt(this.toCompactHex())}toCompactHex(){return pn(this.r)+pn(this.s)}}const Sn={isValidPrivateKey(rr){try{return Pt(rr),!0}catch{return!1}},normPrivateKeyToScalar:Pt,randomPrivateKey:()=>{const rr=dr(E.n);return function Co(b,E,A=!1){const j=b.length,X=mn(E),le=dr(E);if(j<16||j1024)throw new Error(`expected ${le}-1024 bytes of input, got ${j}`);const Pe=Wt(A?en(b):kn(b),E-dn)+dn;return A?Nr(Pe,X):Kn(Pe,X)}(E.randomBytes(rr),E.n)},precompute:(rr=8,hr=wt.BASE)=>(hr._setWindowSize(rr),hr.multiply(BigInt(3)),hr)};function or(rr){const hr=rr instanceof Uint8Array,Yr="string"==typeof rr,mi=(hr||Yr)&&rr.length;return hr?mi===X||mi===le:Yr?mi===2*X||mi===2*le:rr instanceof wt}const mr=E.bits2int||function(rr){const hr=en(rr),Yr=8*rr.length-E.nBitLength;return Yr>0?hr>>BigInt(Yr):hr},Ar=E.bits2int_modN||function(rr){return Pe(mr(rr))},$r=W(E.nBitLength);function Ri(rr){if("bigint"!=typeof rr)throw new Error("bigint expected");if(!(po<=rr&&rr<$r))throw new Error(`bigint expected < 2^${E.nBitLength}`);return Kn(rr,E.nByteLength)}const ei={lowS:E.lowS,prehash:!1},eo={lowS:E.lowS,prehash:!1};return wt.BASE._setWindowSize(8),{CURVE:E,getPublicKey:function Zn(rr,hr=!0){return wt.fromPrivateKey(rr).toRawBytes(hr)},getSharedSecret:function Lr(rr,hr,Yr=!0){if(or(rr))throw new Error("first arg must be private key");if(!or(hr))throw new Error("second arg must be public key");return wt.fromHex(hr).multiply(Pt(rr)).toRawBytes(Yr)},sign:function to(rr,hr,Yr=ei){const{seed:mi,k2sig:yr}=function Ei(rr,hr,Yr=ei){if(["recovered","canonical"].some(wa=>wa in Yr))throw new Error("sign() legacy options not supported");const{hash:mi,randomBytes:yr}=E;let{lowS:oi,prehash:Eo,extraEntropy:Wi}=Yr;null==oi&&(oi=!0),rr=pr("msgHash",rr),Eo&&(rr=pr("prehashed msgHash",mi(rr)));const Bs=Ar(rr),Na=Pt(hr),rl=[Ri(Na),Ri(Bs)];if(null!=Wi){const wa=!0===Wi?yr(A.BYTES):Wi;rl.push(pr("extraEntropy",wa))}const gl=cn(...rl),ba=Bs;return{seed:gl,k2sig:function Xa(wa){const Vc=mr(wa);if(!nn(Vc))return;const $d=Qe(Vc),Po=wt.BASE.multiply(Vc).toAffine(),cc=Pe(Po.x);if(cc===po)return;const ea=Pe($d*Pe(ba+cc*Na));if(ea===po)return;let Zo=(Po.x===cc?0:2)|Number(Po.y&Ii),Hc=ea;return oi&&tn(ea)&&(Hc=function Yt(rr){return tn(rr)?Pe(-rr):rr}(ea),Zo^=1),new vn(cc,Hc,Zo)}}}(rr,hr,Yr);return mt(E.hash.outputLen,E.nByteLength,E.hmac)(mi,yr)},verify:function wo(rr,hr,Yr,mi=eo){const yr=rr;if(hr=pr("msgHash",hr),Yr=pr("publicKey",Yr),"strict"in mi)throw new Error("options.strict was renamed to lowS");const{lowS:oi,prehash:Eo}=mi;let Wi,Bs;try{if("string"==typeof yr||yr instanceof Uint8Array)try{Wi=vn.fromDER(yr)}catch(Po){if(!(Po instanceof ao.Err))throw Po;Wi=vn.fromCompact(yr)}else{if("object"!=typeof yr||"bigint"!=typeof yr.r||"bigint"!=typeof yr.s)throw new Error("PARSE");{const{r:Po,s:cc}=yr;Wi=new vn(Po,cc)}}Bs=wt.fromHex(Yr)}catch(Po){if("PARSE"===Po.message)throw new Error("signature must be Signature instance, Uint8Array or hex string");return!1}if(oi&&Wi.hasHighS())return!1;Eo&&(hr=E.hash(hr));const{r:Na,s:rl}=Wi,gl=Ar(hr),ba=Qe(rl),Xa=Pe(gl*ba),wa=Pe(Na*ba),Vc=wt.BASE.multiplyAndAddUnsafe(Bs,Xa,wa)?.toAffine();return!!Vc&&Pe(Vc.x)===Na},ProjectivePoint:wt,Signature:vn,utils:Sn}}function Ht(b){return{hash:b,hmac:(E,...A)=>ds(b,E,function Be(...b){const E=new Uint8Array(b.reduce((j,X)=>j+X.length,0));let A=0;return b.forEach(j=>{if(!Z(j))throw new Error("Uint8Array expected");E.set(j,A),A+=j.length}),E}(...A)),randomBytes:bn}}BigInt(4);const hn=BigInt("0xfffffffffffffffffffffffffffffffffffffffffffffffffffffffefffffc2f"),Dn=BigInt("0xfffffffffffffffffffffffffffffffebaaedce6af48a03bbfd25e8cd0364141"),Cn=BigInt(1),Nn=BigInt(2),jn=(b,E)=>(b+E/Nn)/E;function Jn(b){const E=hn,A=BigInt(3),j=BigInt(6),X=BigInt(11),le=BigInt(22),Me=BigInt(23),Pe=BigInt(44),Qe=BigInt(88),wt=b*b*b%E,Pt=wt*wt*b%E,Lt=Ge(Pt,A,E)*Pt%E,nn=Ge(Lt,A,E)*Pt%E,pn=Ge(nn,Nn,E)*wt%E,tn=Ge(pn,X,E)*pn%E,Yt=Ge(tn,le,E)*tn%E,Zt=Ge(Yt,Pe,E)*Yt%E,vn=Ge(Zt,Qe,E)*Zt%E,Sn=Ge(vn,Pe,E)*Yt%E,Zn=Ge(Sn,A,E)*Pt%E,or=Ge(Zn,Me,E)*tn%E,Lr=Ge(or,j,E)*wt%E,mr=Ge(Lr,Nn,E);if(!ar.eql(ar.sqr(mr),b))throw new Error("Cannot find square root");return mr}const ar=function Tt(b,E,A=!1,j={}){if(b<=an)throw new Error(`Expected Field ORDER > 0, got ${b}`);const{nBitLength:X,nByteLength:le}=Jt(b,E);if(le>2048)throw new Error("Field lengths over 2048 bytes are not supported");const Me=function ct(b){if(b%xn===sr){const E=(b+dn)/xn;return function(j,X){const le=j.pow(X,E);if(!j.eql(j.sqr(le),X))throw new Error("Cannot find square root");return le}}if(b%Tr===Hr){const E=(b-Hr)/Tr;return function(j,X){const le=j.mul(X,In),Me=j.pow(le,E),Pe=j.mul(X,Me),Qe=j.mul(j.mul(Pe,In),Me),wt=j.mul(Pe,j.sub(Qe,j.ONE));if(!j.eql(j.sqr(wt),X))throw new Error("Cannot find square root");return wt}}return function Dt(b){const E=(b-dn)/In;let A,j,X;for(A=b-dn,j=0;A%In===an;A/=In,j++);for(X=In;XWt(Qe,b),isValid:Qe=>{if("bigint"!=typeof Qe)throw new Error("Invalid field element: expected bigint, got "+typeof Qe);return an<=Qe&&QeQe===an,isOdd:Qe=>(Qe&dn)===dn,neg:Qe=>Wt(-Qe,b),eql:(Qe,wt)=>Qe===wt,sqr:Qe=>Wt(Qe*Qe,b),add:(Qe,wt)=>Wt(Qe+wt,b),sub:(Qe,wt)=>Wt(Qe-wt,b),mul:(Qe,wt)=>Wt(Qe*wt,b),pow:(Qe,wt)=>function Er(b,E,A){if(A 0");if(A===an)return b.ONE;if(A===dn)return E;let j=b.ONE,X=E;for(;A>an;)A&dn&&(j=b.mul(j,X)),X=b.sqr(X),A>>=dn;return j}(Pe,Qe,wt),div:(Qe,wt)=>Wt(Qe*Ve(wt,b),b),sqrN:Qe=>Qe*Qe,addN:(Qe,wt)=>Qe+wt,subN:(Qe,wt)=>Qe-wt,mulN:(Qe,wt)=>Qe*wt,inv:Qe=>Ve(Qe,b),sqrt:j.sqrt||(Qe=>Me(Pe,Qe)),invertBatch:Qe=>function si(b,E){const A=new Array(E.length),j=E.reduce((le,Me,Pe)=>b.is0(Me)?le:(A[Pe]=le,b.mul(le,Me)),b.ONE),X=b.inv(j);return E.reduceRight((le,Me,Pe)=>b.is0(Me)?le:(A[Pe]=b.mul(le,A[Pe]),b.mul(le,Me)),X),A}(Pe,Qe),cmov:(Qe,wt,Pt)=>Pt?wt:Qe,toBytes:Qe=>A?Nr(Qe,le):Kn(Qe,le),fromBytes:Qe=>{if(Qe.length!==le)throw new Error(`Fp.fromBytes: expected ${le}, got ${Qe.length}`);return A?kn(Qe):en(Qe)}});return Object.freeze(Pe)}(hn,void 0,void 0,{sqrt:Jn}),wr=function kt(b,E){const A=j=>Ye({...b,...Ht(j)});return Object.freeze({...A(E),create:A})}({a:BigInt(0),b:BigInt(7),Fp:ar,n:Dn,Gx:BigInt("55066263022277343669578718895168534326250603453777594175500187360389116729240"),Gy:BigInt("32670510020758816978083085130507043184471273380659243275938904335757337482424"),h:BigInt(1),lowS:!0,endo:{beta:BigInt("0x7ae96a2b657c07106e64479eac3434e99cf0497512f58995c1396c28719501ee"),splitScalar:b=>{const E=Dn,A=BigInt("0x3086d221a7d46bcde86c90e49284eb15"),j=-Cn*BigInt("0xe4437ed6010e88286f547fa90abfe4c3"),X=BigInt("0x114ca50f7a8e2f3f657c1108d9d44cfd8"),le=A,Me=BigInt("0x100000000000000000000000000000000"),Pe=jn(le*b,E),Qe=jn(-j*b,E);let wt=Wt(b-Pe*A-Qe*X,E),Pt=Wt(-Pe*j-Qe*le,E);const Lt=wt>Me,nn=Pt>Me;if(Lt&&(wt=E-wt),nn&&(Pt=E-Pt),wt>Me||Pt>Me)throw new Error("splitScalar: Endomorphism failed, k="+b);return{k1neg:Lt,k1:wt,k2neg:nn,k2:Pt}}}},it),xr=BigInt(0),gi=b=>"bigint"==typeof b&&xrX.charCodeAt(0)));A=cn(j,j),Mi[b]=A}return it(cn(A,...E))}const Qr=b=>b.toRawBytes(!0).slice(1),Pr=b=>Kn(b,32),Do=b=>Wt(b,hn),es=b=>Wt(b,Dn),zs=wr.ProjectivePoint;function Li(b){let E=wr.utils.normPrivateKeyToScalar(b),A=zs.fromPrivateKey(E);return{scalar:A.hasEvenY()?E:es(-E),bytes:Qr(A)}}function bi(b){if(!gi(b))throw new Error("bad x: need 0 < x < p");const E=Do(b*b);let j=Jn(Do(E*b+BigInt(7)));j%Nn!==xr&&(j=Do(-j));const X=new zs(b,j,Cn);return X.assertValidity(),X}function aa(...b){return es(en(Or("BIP0340/challenge",...b)))}function Cs(b,E,A){const j=pr("signature",b,64),X=pr("message",E),le=pr("publicKey",A,32);try{const Me=bi(en(le)),Pe=en(j.subarray(0,32));if(!gi(Pe))return!1;const Qe=en(j.subarray(32,64));if(!(b=>"bigint"==typeof b&&xrzs.BASE.multiplyAndAddUnsafe(b,E,A))(Me,Qe,es(-wt));return!(!Pt||!Pt.hasEvenY()||Pt.toAffine().x!==Pe)}catch{return!1}}const No={getPublicKey:function Ks(b){return Li(b).bytes},sign:function Oo(b,E,A=bn(32)){const j=pr("message",b),{bytes:X,scalar:le}=Li(E),Me=pr("auxRand",A,32),Pe=Pr(le^en(Or("BIP0340/aux",Me))),Qe=Or("BIP0340/nonce",Pe,X,j),wt=es(en(Qe));if(wt===xr)throw new Error("sign failed: k is zero");const{bytes:Pt,scalar:Lt}=Li(wt),nn=aa(Pt,X,j),pn=new Uint8Array(64);if(pn.set(Pt,0),pn.set(Pr(es(Lt+nn*le)),32),!Cs(pn,j,X))throw new Error("sign: Invalid signature produced");return pn},verify:Cs,utils:{randomPrivateKey:wr.utils.randomPrivateKey,lift_x:bi,pointToBytes:Qr,numberToBytesBE:Kn,bytesToNumberBE:en,taggedHash:Or,mod:Wt}};var Xr=r(4704);function Ds(b){if(!Number.isSafeInteger(b)||b<0)throw new Error(`Wrong positive integer: ${b}`)}function io(b,...E){if(!(b instanceof Uint8Array))throw new Error("Expected Uint8Array");if(E.length>0&&!E.includes(b.length))throw new Error(`Expected Uint8Array of length ${E}, not of length=${b.length}`)}const Ao={number:Ds,bool:function go(b){if("boolean"!=typeof b)throw new Error(`Expected boolean, not ${b}`)},bytes:io,hash:function fs(b){if("function"!=typeof b||"function"!=typeof b.create)throw new Error("Hash should be wrapped by utils.wrapConstructor");Ds(b.outputLen),Ds(b.blockLen)},exists:function Xo(b,E=!0){if(b.destroyed)throw new Error("Hash instance has been destroyed");if(E&&b.finished)throw new Error("Hash#digest() has already been called")},output:function Qa(b,E){io(b);const A=E.outputLen;if(b.lengthX-Me&&(this.process(j,0),Me=0);for(let Lt=Me;Lt>X&le),Pe=Number(A&le),wt=j?0:4;b.setUint32(E+(j?4:0),Me,j),b.setUint32(E+wt,Pe,j)})(j,X-8,BigInt(8*this.length),le),this.process(j,0);const Pe=(0,Xr.O8)(E),Qe=this.outputLen;if(Qe%4)throw new Error("_sha2: outputLen should be aligned to 32bit");const wt=Qe/4,Pt=this.get();if(wt>Pt.length)throw new Error("_sha2: outputLen bigger than state");for(let Lt=0;Ltb&E^~b&A,_s=(b,E,A)=>b&E^b&A^E&A,la=new Uint32Array([1116352408,1899447441,3049323471,3921009573,961987163,1508970993,2453635748,2870763221,3624381080,310598401,607225278,1426881987,1925078388,2162078206,2614888103,3248222580,3835390401,4022224774,264347078,604807628,770255983,1249150122,1555081692,1996064986,2554220882,2821834349,2952996808,3210313671,3336571891,3584528711,113926993,338241895,666307205,773529912,1294757372,1396182291,1695183700,1986661051,2177026350,2456956037,2730485921,2820302411,3259730800,3345764771,3516065817,3600352804,4094571909,275423344,430227734,506948616,659060556,883997877,958139571,1322822218,1537002063,1747873779,1955562222,2024104815,2227730452,2361852424,2428436474,2756734187,3204031479,3329325298]),ls=new Uint32Array([1779033703,3144134277,1013904242,2773480762,1359893119,2600822924,528734635,1541459225]),Vi=new Uint32Array(64);class ll extends As{constructor(){super(64,32,8,!1),this.A=0|ls[0],this.B=0|ls[1],this.C=0|ls[2],this.D=0|ls[3],this.E=0|ls[4],this.F=0|ls[5],this.G=0|ls[6],this.H=0|ls[7]}get(){const{A:E,B:A,C:j,D:X,E:le,F:Me,G:Pe,H:Qe}=this;return[E,A,j,X,le,Me,Pe,Qe]}set(E,A,j,X,le,Me,Pe,Qe){this.A=0|E,this.B=0|A,this.C=0|j,this.D=0|X,this.E=0|le,this.F=0|Me,this.G=0|Pe,this.H=0|Qe}process(E,A){for(let Lt=0;Lt<16;Lt++,A+=4)Vi[Lt]=E.getUint32(A,!1);for(let Lt=16;Lt<64;Lt++){const nn=Vi[Lt-15],pn=Vi[Lt-2],tn=(0,Xr.Ow)(nn,7)^(0,Xr.Ow)(nn,18)^nn>>>3,Yt=(0,Xr.Ow)(pn,17)^(0,Xr.Ow)(pn,19)^pn>>>10;Vi[Lt]=Yt+Vi[Lt-7]+tn+Vi[Lt-16]|0}let{A:j,B:X,C:le,D:Me,E:Pe,F:Qe,G:wt,H:Pt}=this;for(let Lt=0;Lt<64;Lt++){const pn=Pt+((0,Xr.Ow)(Pe,6)^(0,Xr.Ow)(Pe,11)^(0,Xr.Ow)(Pe,25))+Gs(Pe,Qe,wt)+la[Lt]+Vi[Lt]|0,Yt=((0,Xr.Ow)(j,2)^(0,Xr.Ow)(j,13)^(0,Xr.Ow)(j,22))+_s(j,X,le)|0;Pt=wt,wt=Qe,Qe=Pe,Pe=Me+pn|0,Me=le,le=X,X=j,j=pn+Yt|0}j=j+this.A|0,X=X+this.B|0,le=le+this.C|0,Me=Me+this.D|0,Pe=Pe+this.E|0,Qe=Qe+this.F|0,wt=wt+this.G|0,Pt=Pt+this.H|0,this.set(j,X,le,Me,Pe,Qe,wt,Pt)}roundClean(){Vi.fill(0)}destroy(){this.set(0,0,0,0,0,0,0,0),this.buffer.fill(0)}}class ca extends ll{constructor(){super(),this.A=-1056596264,this.B=914150663,this.C=812702999,this.D=-150054599,this.E=-4191439,this.F=1750603025,this.G=1694076839,this.H=-1090891868,this.outputLen=28}}const Ss=(0,Xr.ld)(()=>new ll);function Ns(b){if(!Number.isSafeInteger(b))throw new Error(`Wrong integer: ${b}`)}function So(...b){const E=(X,le)=>Me=>X(le(Me));return{encode:Array.from(b).reverse().reduce((X,le)=>X?E(X,le.encode):le.encode,void 0),decode:b.reduce((X,le)=>X?E(X,le.decode):le.decode,void 0)}}function Bo(b){return{encode:E=>{if(!Array.isArray(E)||E.length&&"number"!=typeof E[0])throw new Error("alphabet.encode input should be an array of numbers");return E.map(A=>{if(Ns(A),A<0||A>=b.length)throw new Error(`Digit index outside alphabet: ${A} (alphabet: ${b.length})`);return b[A]})},decode:E=>{if(!Array.isArray(E)||E.length&&"string"!=typeof E[0])throw new Error("alphabet.decode input should be array of strings");return E.map(A=>{if("string"!=typeof A)throw new Error(`alphabet.decode: not string element=${A}`);const j=b.indexOf(A);if(-1===j)throw new Error(`Unknown letter: "${A}". Allowed: ${b}`);return j})}}}function lo(b=""){if("string"!=typeof b)throw new Error("join separator should be string");return{encode:E=>{if(!Array.isArray(E)||E.length&&"string"!=typeof E[0])throw new Error("join.encode input should be array of strings");for(let A of E)if("string"!=typeof A)throw new Error(`join.encode: non-string input=${A}`);return E.join(b)},decode:E=>{if("string"!=typeof E)throw new Error("join.decode input should be string");return E.split(b)}}}function ps(b,E="="){if(Ns(b),"string"!=typeof E)throw new Error("padding chr should be string");return{encode(A){if(!Array.isArray(A)||A.length&&"string"!=typeof A[0])throw new Error("padding.encode input should be array of strings");for(let j of A)if("string"!=typeof j)throw new Error(`padding.encode: non-string input=${j}`);for(;A.length*b%8;)A.push(E);return A},decode(A){if(!Array.isArray(A)||A.length&&"string"!=typeof A[0])throw new Error("padding.encode input should be array of strings");for(let X of A)if("string"!=typeof X)throw new Error(`padding.decode: non-string input=${X}`);let j=A.length;if(j*b%8)throw new Error("Invalid padding: string should have whole number of bytes");for(;j>0&&A[j-1]===E;j--)if(!((j-1)*b%8))throw new Error("Invalid padding: string has too much padding");return A.slice(0,j)}}}function Da(b){if("function"!=typeof b)throw new Error("normalize fn should be function");return{encode:E=>E,decode:E=>b(E)}}function Ms(b,E,A){if(E<2)throw new Error(`convertRadix: wrong from=${E}, base cannot be less than 2`);if(A<2)throw new Error(`convertRadix: wrong to=${A}, base cannot be less than 2`);if(!Array.isArray(b))throw new Error("convertRadix: data should be array");if(!b.length)return[];let j=0;const X=[],le=Array.from(b);for(le.forEach(Me=>{if(Ns(Me),Me<0||Me>=E)throw new Error(`Wrong integer: ${Me}`)});;){let Me=0,Pe=!0;for(let Qe=j;Qenew ca);const Us=(b,E)=>E?Us(E,b%E):b,ua=(b,E)=>b+(E-Us(b,E));function Ba(b,E,A,j){if(!Array.isArray(b))throw new Error("convertRadix2: data should be array");if(E<=0||E>32)throw new Error(`convertRadix2: wrong from=${E}`);if(A<=0||A>32)throw new Error(`convertRadix2: wrong to=${A}`);if(ua(E,A)>32)throw new Error(`convertRadix2: carry overflow from=${E} to=${A} carryBits=${ua(E,A)}`);let X=0,le=0;const Me=2**A-1,Pe=[];for(const Qe of b){if(Ns(Qe),Qe>=2**E)throw new Error(`convertRadix2: invalid data word=${Qe} from=${E}`);if(X=X<32)throw new Error(`convertRadix2: carry overflow pos=${le} from=${E}`);for(le+=E;le>=A;le-=A)Pe.push((X>>le-A&Me)>>>0);X&=2**le-1}if(X=X<=E)throw new Error("Excess padding");if(!j&&X)throw new Error(`Non-zero padding: ${X}`);return j&&le>0&&Pe.push(X>>>0),Pe}function Q(b,E=!1){if(Ns(b),b<=0||b>32)throw new Error("radix2: bits should be in (0..32]");if(ua(8,b)>32||ua(b,8)>32)throw new Error("radix2: carry overflow");return{encode:A=>{if(!(A instanceof Uint8Array))throw new Error("radix2.encode input should be Uint8Array");return Ba(Array.from(A),8,b,!E)},decode:A=>{if(!Array.isArray(A)||A.length&&"number"!=typeof A[0])throw new Error("radix2.decode input should be array of strings");return Uint8Array.from(Ba(A,b,8,E))}}}function et(b){if("function"!=typeof b)throw new Error("unsafeWrapper fn should be function");return function(...E){try{return b.apply(null,E)}catch{}}}So(Q(4),Bo("0123456789ABCDEF"),lo("")),So(Q(5),Bo("ABCDEFGHIJKLMNOPQRSTUVWXYZ234567"),ps(5),lo(""));const Qn=(So(Q(5),Bo("0123456789ABCDEFGHIJKLMNOPQRSTUV"),ps(5),lo("")),So(Q(5),Bo("0123456789ABCDEFGHJKMNPQRSTVWXYZ"),lo(""),Da(b=>b.toUpperCase().replace(/O/g,"0").replace(/[IL]/g,"1"))),So(Q(6),Bo("ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/"),ps(6),lo(""))),zi=(So(Q(6),Bo("ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789-_"),ps(6),lo("")),b=>So(function Aa(b){return Ns(b),{encode:E=>{if(!(E instanceof Uint8Array))throw new Error("radix.encode input should be Uint8Array");return Ms(Array.from(E),256,b)},decode:E=>{if(!Array.isArray(E)||E.length&&"number"!=typeof E[0])throw new Error("radix.decode input should be array of strings");return Uint8Array.from(Ms(E,b,256))}}}(58),Bo(b),lo(""))),jo=(zi("123456789ABCDEFGHJKLMNPQRSTUVWXYZabcdefghijkmnopqrstuvwxyz"),zi("123456789abcdefghijkmnopqrstuvwxyzABCDEFGHJKLMNPQRSTUVWXYZ"),zi("rpshnaf39wBUDNEGHJKLM4PQRST7VWXYZ2bcdeCg65jkm8oFqi1tuvAxyz"),So(Bo("qpzry9x8gf2tvdw0s3jn54khce6mua7l"),lo(""))),Ho=[996825010,642813549,513874426,1027748829,705979059];function Ua(b){const E=b>>25;let A=(33554431&b)<<5;for(let j=0;j>j&1)&&(A^=Ho[j]);return A}function $a(b,E,A=1){const j=b.length;let X=1;for(let le=0;le126)throw new Error(`Invalid prefix (${b})`);X=Ua(X)^Me>>5}X=Ua(X);for(let le=0;leLt)throw new TypeError(`Wrong string length: ${Pt.length} (${Pt}). Expected (8..${Lt})`);const nn=Pt.toLowerCase();if(Pt!==nn&&Pt!==Pt.toUpperCase())throw new Error("String must be lowercase or uppercase");const pn=(Pt=nn).lastIndexOf("1");if(0===pn||-1===pn)throw new Error('Letter "1" must be present between prefix and data only');const tn=Pt.slice(0,pn),Yt=Pt.slice(pn+1);if(Yt.length<6)throw new Error("Data must be at least 6 characters long");const Zt=jo.decode(Yt).slice(0,-6),vn=$a(tn,Zt,E);if(!Yt.endsWith(vn))throw new Error(`Invalid checksum in ${Pt}: expected "${vn}"`);return{prefix:tn,words:Zt}}return{encode:function Me(Pt,Lt,nn=90){if("string"!=typeof Pt)throw new Error("bech32.encode prefix should be string, not "+typeof Pt);if(!Array.isArray(Lt)||Lt.length&&"number"!=typeof Lt[0])throw new Error("bech32.encode words should be array of numbers, not "+typeof Lt);const pn=Pt.length+7+Lt.length;if(!1!==nn&&pn>nn)throw new TypeError(`Length ${pn} exceeds limit ${nn}`);return`${Pt=Pt.toLowerCase()}1${jo.encode(Lt)}${$a(Pt,Lt,E)}`},decode:Pe,decodeToBytes:function wt(Pt){const{prefix:Lt,words:nn}=Pe(Pt,!1);return{prefix:Lt,words:nn,bytes:j(nn)}},decodeUnsafe:et(Pe),fromWords:j,fromWordsUnsafe:le,toWords:X}}const de=da("bech32");function ja(b){if(!Number.isSafeInteger(b)||b<0)throw new Error(`positive integer expected, not ${b}`)}function fc(b){if("boolean"!=typeof b)throw new Error(`boolean expected, not ${b}`)}function cl(b){return b instanceof Uint8Array||null!=b&&"object"==typeof b&&"Uint8Array"===b.constructor.name}function _i(b,...E){if(!cl(b))throw new Error("Uint8Array expected");if(E.length>0&&!E.includes(b.length))throw new Error(`Uint8Array expected of length ${E}, not of length=${b.length}`)}function vs(b,E=!0){if(b.destroyed)throw new Error("Hash instance has been destroyed");if(E&&b.finished)throw new Error("Hash#digest() has already been called")}function Va(b,E){_i(b);const A=E.outputLen;if(b.length{if("string"!=typeof b||b.length%2)throw new TypeError(`hex.decode: expected string, got ${typeof b} with length ${b.length}`);return b.toLowerCase()}));const yi=b=>new Uint32Array(b.buffer,b.byteOffset,Math.floor(b.byteLength/4)),Il=b=>new DataView(b.buffer,b.byteOffset,b.byteLength);if(68!==new Uint8Array(new Uint32Array([287454020]).buffer)[0])throw new Error("Non little-endian hardware is not supported");function hl(b){if("string"==typeof b)b=function El(b){if("string"!=typeof b)throw new Error("string expected, got "+typeof b);return new Uint8Array((new TextEncoder).encode(b))}(b);else{if(!cl(b))throw new Error("Uint8Array expected, got "+typeof b);b=b.slice()}return b}function ha(b,E){if(b.length!==E.length)return!1;let A=0;for(let j=0;j(Object.assign(E,b),E);function Wo(b,E,A,j){if("function"==typeof b.setBigUint64)return b.setBigUint64(E,A,j);const X=BigInt(32),le=BigInt(4294967295),Me=Number(A>>X&le),Pe=Number(A&le),wt=j?0:4;b.setUint32(E+(j?4:0),Me,j),b.setUint32(E+wt,Pe,j)}const Sr=new Uint8Array(16),Oi=yi(Sr),Qi=(b,E,A,j)=>({s3:A<<31|j>>>1,s2:E<<31|A>>>1,s1:b<<31|E>>>1,s0:b>>>1^225<<24&-(1&j)}),so=b=>(b>>>0&255)<<24|(b>>>8&255)<<16|(b>>>16&255)<<8|b>>>24&255;class no{constructor(E,A){this.blockLen=16,this.outputLen=16,this.s0=0,this.s1=0,this.s2=0,this.s3=0,this.finished=!1,_i(E=hl(E),16);const j=Il(E);let X=j.getUint32(0,!1),le=j.getUint32(4,!1),Me=j.getUint32(8,!1),Pe=j.getUint32(12,!1);const Qe=[];for(let tn=0;tn<128;tn++)Qe.push({s0:so(X),s1:so(le),s2:so(Me),s3:so(Pe)}),({s0:X,s1:le,s2:Me,s3:Pe}=Qi(X,le,Me,Pe));const wt=(b=A||1024)>65536?8:b>1024?4:2;var b;if(![1,2,4,8].includes(wt))throw new Error(`ghash: wrong window size=${wt}, should be 2, 4 or 8`);this.W=wt;const Lt=128/wt,nn=this.windowSize=2**wt,pn=[];for(let tn=0;tn>>wt-or-1&1))continue;const{s0:mr,s1:Ar,s2:$r,s3:Ri}=Qe[wt*tn+or];Zt^=mr,vn^=Ar,Sn^=$r,Zn^=Ri}pn.push({s0:Zt,s1:vn,s2:Sn,s3:Zn})}this.t=pn}_updateBlock(E,A,j,X){E^=this.s0,A^=this.s1,j^=this.s2,X^=this.s3;const{W:le,t:Me,windowSize:Pe}=this;let Qe=0,wt=0,Pt=0,Lt=0;const nn=(1<>>8*Yt&255;for(let vn=8/le-1;vn>=0;vn--){const Sn=Zt>>>le*vn&nn,{s0:Zn,s1:or,s2:Lr,s3:mr}=Me[pn*Pe+Sn];Qe^=Zn,wt^=or,Pt^=Lr,Lt^=mr,pn+=1}}this.s0=Qe,this.s1=wt,this.s2=Pt,this.s3=Lt}update(E){E=hl(E),vs(this);const A=yi(E),j=Math.floor(E.length/16),X=E.length%16;for(let le=0;le>>1|A,A=(1&X)<<7}return b[0]^=225&-E,b}((E=hl(E)).slice());super(j,A),j.fill(0)}update(E){E=hl(E),vs(this);const A=yi(E),j=E.length%16,X=Math.floor(E.length/16);for(let le=0;leb(X,j.length).update(hl(j)).digest(),A=b(new Uint8Array(16),0);return E.outputLen=A.outputLen,E.blockLen=A.blockLen,E.create=(j,X)=>b(j,X),E}ri((b,E)=>new no(b,E)),ri((b,E)=>new co(b,E)),new Uint8Array(16);const Vs=283;function uo(b){return b<<1^Vs&-(b>>7)}function Ui(b,E){let A=0;for(;E>0;E>>=1)A^=b&-(1&E),b=uo(b);return A}const U=(()=>{let b=new Uint8Array(256);for(let A=0,j=1;A<256;A++,j^=uo(j))b[A]=j;const E=new Uint8Array(256);E[0]=99;for(let A=0;A<255;A++){let j=b[255-A];j|=j<<8,E[b[A]]=255&(j^j>>4^j>>5^j>>6^j>>7^99)}return E})(),Ie=U.map((b,E)=>U.indexOf(E)),ne=b=>b<<24|b>>>8,ye=b=>b<<8|b>>>24;function Et(b,E){if(256!==b.length)throw new Error("Wrong sbox length");const A=new Uint32Array(256).map((wt,Pt)=>E(b[Pt])),j=A.map(ye),X=j.map(ye),le=X.map(ye),Me=new Uint32Array(65536),Pe=new Uint32Array(65536),Qe=new Uint16Array(65536);for(let wt=0;wt<256;wt++)for(let Pt=0;Pt<256;Pt++){const Lt=256*wt+Pt;Me[Lt]=A[wt]^j[Pt],Pe[Lt]=X[wt]^le[Pt],Qe[Lt]=b[wt]<<8|b[Pt]}return{sbox:b,sbox2:Qe,T0:A,T1:j,T2:X,T3:le,T01:Me,T23:Pe}}const Gt=Et(U,b=>Ui(b,3)<<24|b<<16|b<<8|Ui(b,2)),Un=Et(Ie,b=>Ui(b,11)<<24|Ui(b,13)<<16|Ui(b,9)<<8|Ui(b,14)),tr=(()=>{const b=new Uint8Array(16);for(let E=0,A=1;E<16;E++,A=uo(A))b[E]=A;return b})();function ci(b){_i(b);const E=b.length;if(![16,24,32].includes(E))throw new Error(`aes: wrong key size: should be 16, 24 or 32, got: ${E}`);const{sbox2:A}=Gt,j=yi(b),X=j.length,le=Pe=>Rr(A,Pe,Pe,Pe,Pe),Me=new Uint32Array(E+28);Me.set(j);for(let Pe=X;Pe6&&Pe%X==4&&(Qe=le(Qe)),Me[Pe]=Me[Pe-X]^Qe}return Me}function Di(b,E,A,j,X,le){return b[A<<8&65280|j>>>8&255]^E[X>>>8&65280|le>>>24&255]}function Rr(b,E,A,j,X){return b[255&E|65280&A]|b[j>>>16&255|X>>>16&65280]<<16}function li(b,E,A,j,X){const{sbox2:le,T01:Me,T23:Pe}=Gt;let Qe=0;E^=b[Qe++],A^=b[Qe++],j^=b[Qe++],X^=b[Qe++];const wt=b.length/4-2;for(let tn=0;tn{const Pe=ci(E),{b:Qe,o:wt,out:Pt}=function Ha(b,E,A){let j=b.length;const X=j%16;if(!E&&0!==X)throw new Error("aec/(cbc-ecb): unpadded plaintext with disabled padding");const le=yi(b);if(E){let Qe=16-X;Qe||(Qe=16),j+=Qe}const Me=wi(j,A);return{b:le,o:yi(Me),out:Me}}(le,X,Me),Lt=yi(A);let nn=Lt[0],pn=Lt[1],tn=Lt[2],Yt=Lt[3],Zt=0;for(;Zt+4<=Qe.length;)nn^=Qe[Zt+0],pn^=Qe[Zt+1],tn^=Qe[Zt+2],Yt^=Qe[Zt+3],({s0:nn,s1:pn,s2:tn,s3:Yt}=li(Pe,nn,pn,tn,Yt)),wt[Zt++]=nn,wt[Zt++]=pn,wt[Zt++]=tn,wt[Zt++]=Yt;if(X){const vn=function Ta(b){const E=new Uint8Array(16),A=yi(E);E.set(b);const j=16-b.length;for(let X=16-j;X<16;X++)E[X]=j;return A}(le.subarray(4*Zt));nn^=vn[0],pn^=vn[1],tn^=vn[2],Yt^=vn[3],({s0:nn,s1:pn,s2:tn,s3:Yt}=li(Pe,nn,pn,tn,Yt)),wt[Zt++]=nn,wt[Zt++]=pn,wt[Zt++]=tn,wt[Zt++]=Yt}return Pe.fill(0),Pt},decrypt:(le,Me)=>{!function Yo(b){if(_i(b),b.length%16!=0)throw new Error("aes/(cbc-ecb).decrypt ciphertext should consist of blocks with size 16")}(le);const Pe=function ki(b){const E=ci(b),A=E.slice(),j=E.length,{sbox2:X}=Gt,{T0:le,T1:Me,T2:Pe,T3:Qe}=Un;for(let wt=0;wt>>8&255]^Pe[Lt>>>16&255]^Qe[Lt>>>24]}return A}(E),Qe=yi(A),wt=wi(le.length,Me),Pt=yi(le),Lt=yi(wt);let nn=Qe[0],pn=Qe[1],tn=Qe[2],Yt=Qe[3];for(let Zt=0;Zt+4<=Pt.length;){const vn=nn,Sn=pn,Zn=tn,or=Yt;nn=Pt[Zt+0],pn=Pt[Zt+1],tn=Pt[Zt+2],Yt=Pt[Zt+3];const{s0:Lr,s1:mr,s2:Ar,s3:$r}=ii(Pe,nn,pn,tn,Yt);Lt[Zt++]=Lr^vn,Lt[Zt++]=mr^Sn,Lt[Zt++]=Ar^Zn,Lt[Zt++]=$r^or}return Pe.fill(0),function Ls(b,E){if(!E)return b;const A=b.length;if(!A)throw new Error("aes/pcks5: empty ciphertext not allowed");const j=b[A-1];if(j<=0||j>16)throw new Error(`aes/pcks5: wrong padding byte: ${j}`);const X=b.subarray(0,-j);for(let le=0;le255&b[E++]|(255&b[E++])<<8;class zo{constructor(E){this.blockLen=16,this.outputLen=16,this.buffer=new Uint8Array(16),this.r=new Uint16Array(10),this.h=new Uint16Array(10),this.pad=new Uint16Array(8),this.pos=0,this.finished=!1,_i(E=hl(E),32);const A=yo(E,0),j=yo(E,2),X=yo(E,4),le=yo(E,6),Me=yo(E,8),Pe=yo(E,10),Qe=yo(E,12),wt=yo(E,14);this.r[0]=8191&A,this.r[1]=8191&(A>>>13|j<<3),this.r[2]=7939&(j>>>10|X<<6),this.r[3]=8191&(X>>>7|le<<9),this.r[4]=255&(le>>>4|Me<<12),this.r[5]=Me>>>1&8190,this.r[6]=8191&(Me>>>14|Pe<<2),this.r[7]=8065&(Pe>>>11|Qe<<5),this.r[8]=8191&(Qe>>>8|wt<<8),this.r[9]=wt>>>5&127;for(let Pt=0;Pt<8;Pt++)this.pad[Pt]=yo(E,16+2*Pt)}process(E,A,j=!1){const X=j?0:2048,{h:le,r:Me}=this,Pe=Me[0],Qe=Me[1],wt=Me[2],Pt=Me[3],Lt=Me[4],nn=Me[5],pn=Me[6],tn=Me[7],Yt=Me[8],Zt=Me[9],vn=yo(E,A+0),Sn=yo(E,A+2),Zn=yo(E,A+4),or=yo(E,A+6),Lr=yo(E,A+8),mr=yo(E,A+10),Ar=yo(E,A+12),$r=yo(E,A+14);let Ri=le[0]+(8191&vn),Ei=le[1]+(8191&(vn>>>13|Sn<<3)),ei=le[2]+(8191&(Sn>>>10|Zn<<6)),eo=le[3]+(8191&(Zn>>>7|or<<9)),to=le[4]+(8191&(or>>>4|Lr<<12)),wo=le[5]+(Lr>>>1&8191),rr=le[6]+(8191&(Lr>>>14|mr<<2)),hr=le[7]+(8191&(mr>>>11|Ar<<5)),Yr=le[8]+(8191&(Ar>>>8|$r<<8)),mi=le[9]+($r>>>5|X),yr=0,oi=yr+Ri*Pe+Ei*(5*Zt)+ei*(5*Yt)+eo*(5*tn)+to*(5*pn);yr=oi>>>13,oi&=8191,oi+=wo*(5*nn)+rr*(5*Lt)+hr*(5*Pt)+Yr*(5*wt)+mi*(5*Qe),yr+=oi>>>13,oi&=8191;let Eo=yr+Ri*Qe+Ei*Pe+ei*(5*Zt)+eo*(5*Yt)+to*(5*tn);yr=Eo>>>13,Eo&=8191,Eo+=wo*(5*pn)+rr*(5*nn)+hr*(5*Lt)+Yr*(5*Pt)+mi*(5*wt),yr+=Eo>>>13,Eo&=8191;let Wi=yr+Ri*wt+Ei*Qe+ei*Pe+eo*(5*Zt)+to*(5*Yt);yr=Wi>>>13,Wi&=8191,Wi+=wo*(5*tn)+rr*(5*pn)+hr*(5*nn)+Yr*(5*Lt)+mi*(5*Pt),yr+=Wi>>>13,Wi&=8191;let Bs=yr+Ri*Pt+Ei*wt+ei*Qe+eo*Pe+to*(5*Zt);yr=Bs>>>13,Bs&=8191,Bs+=wo*(5*Yt)+rr*(5*tn)+hr*(5*pn)+Yr*(5*nn)+mi*(5*Lt),yr+=Bs>>>13,Bs&=8191;let Na=yr+Ri*Lt+Ei*Pt+ei*wt+eo*Qe+to*Pe;yr=Na>>>13,Na&=8191,Na+=wo*(5*Zt)+rr*(5*Yt)+hr*(5*tn)+Yr*(5*pn)+mi*(5*nn),yr+=Na>>>13,Na&=8191;let rl=yr+Ri*nn+Ei*Lt+ei*Pt+eo*wt+to*Qe;yr=rl>>>13,rl&=8191,rl+=wo*Pe+rr*(5*Zt)+hr*(5*Yt)+Yr*(5*tn)+mi*(5*pn),yr+=rl>>>13,rl&=8191;let gl=yr+Ri*pn+Ei*nn+ei*Lt+eo*Pt+to*wt;yr=gl>>>13,gl&=8191,gl+=wo*Qe+rr*Pe+hr*(5*Zt)+Yr*(5*Yt)+mi*(5*tn),yr+=gl>>>13,gl&=8191;let ba=yr+Ri*tn+Ei*pn+ei*nn+eo*Lt+to*Pt;yr=ba>>>13,ba&=8191,ba+=wo*wt+rr*Qe+hr*Pe+Yr*(5*Zt)+mi*(5*Yt),yr+=ba>>>13,ba&=8191;let Xa=yr+Ri*Yt+Ei*tn+ei*pn+eo*nn+to*Lt;yr=Xa>>>13,Xa&=8191,Xa+=wo*Pt+rr*wt+hr*Qe+Yr*Pe+mi*(5*Zt),yr+=Xa>>>13,Xa&=8191;let wa=yr+Ri*Zt+Ei*Yt+ei*tn+eo*pn+to*nn;yr=wa>>>13,wa&=8191,wa+=wo*Lt+rr*Pt+hr*wt+Yr*Qe+mi*Pe,yr+=wa>>>13,wa&=8191,yr=(yr<<2)+yr|0,yr=yr+oi|0,oi=8191&yr,yr>>>=13,Eo+=yr,le[0]=oi,le[1]=Eo,le[2]=Wi,le[3]=Bs,le[4]=Na,le[5]=rl,le[6]=gl,le[7]=ba,le[8]=Xa,le[9]=wa}finalize(){const{h:E,pad:A}=this,j=new Uint16Array(10);let X=E[1]>>>13;E[1]&=8191;for(let Pe=2;Pe<10;Pe++)E[Pe]+=X,X=E[Pe]>>>13,E[Pe]&=8191;E[0]+=5*X,X=E[0]>>>13,E[0]&=8191,E[1]+=X,X=E[1]>>>13,E[1]&=8191,E[2]+=X,j[0]=E[0]+5,X=j[0]>>>13,j[0]&=8191;for(let Pe=1;Pe<10;Pe++)j[Pe]=E[Pe]+X,X=j[Pe]>>>13,j[Pe]&=8191;j[9]-=8192;let le=(1^X)-1;for(let Pe=0;Pe<10;Pe++)j[Pe]&=le;le=~le;for(let Pe=0;Pe<10;Pe++)E[Pe]=E[Pe]&le|j[Pe];E[0]=65535&(E[0]|E[1]<<13),E[1]=65535&(E[1]>>>3|E[2]<<10),E[2]=65535&(E[2]>>>6|E[3]<<7),E[3]=65535&(E[3]>>>9|E[4]<<4),E[4]=65535&(E[4]>>>12|E[5]<<1|E[6]<<14),E[5]=65535&(E[6]>>>2|E[7]<<11),E[6]=65535&(E[7]>>>5|E[8]<<8),E[7]=65535&(E[8]>>>8|E[9]<<5);let Me=E[0]+A[0];E[0]=65535&Me;for(let Pe=1;Pe<8;Pe++)Me=(E[Pe]+A[Pe]|0)+(Me>>>16)|0,E[Pe]=65535&Me}update(E){vs(this);const{buffer:A,blockLen:j}=this,X=(E=hl(E)).length;for(let le=0;le>>0,E[le++]=j[Me]>>>8;return E}digest(){const{buffer:E,outputLen:A}=this;this.digestInto(E);const j=E.slice(0,A);return this.destroy(),j}}const au=function xl(b){const E=(j,X)=>b(X).update(hl(j)).digest(),A=b(new Uint8Array(32));return E.outputLen=A.outputLen,E.blockLen=A.blockLen,E.create=j=>b(j),E}(b=>new zo(b)),mc=b=>Uint8Array.from(b.split("").map(E=>E.charCodeAt(0))),lu=mc("expand 16-byte k"),Bu=mc("expand 32-byte k"),ah=yi(lu),Uu=yi(Bu);function Ur(b,E){return b<>>32-E}function kc(b){return b.byteOffset%4==0}Uu.slice();const Wa=2**32-1,Fr=new Uint32Array;function Xl(b,E){const{allowShortKeys:A,extendNonceFn:j,counterLength:X,counterRight:le,rounds:Me}=function Hl(b,E){if(null==E||"object"!=typeof E)throw new Error("options must be defined");return Object.assign(b,E)}({allowShortKeys:!1,counterLength:8,counterRight:!1,rounds:20},E);if("function"!=typeof b)throw new Error("core must be a function");return ja(X),ja(Me),fc(le),fc(A),(Pe,Qe,wt,Pt,Lt=0)=>{_i(Pe),_i(Qe),_i(wt);const nn=wt.length;if(Pt||(Pt=new Uint8Array(nn)),_i(Pt),ja(Lt),Lt<0||Lt>=Wa)throw new Error("arx: counter overflow");if(Pt.length=Wa)throw new Error("arx: counter overflow");const Yt=Math.min(64,Qe-tn);if(Lt&&64===Yt){const Zt=tn/4;if(tn%4!=0)throw new Error("arx: invalid block position");for(let Sn,vn=0;vn<16;vn++)Sn=Zt+vn,pn[Sn]=nn[Sn]^Pt[vn];tn+=64}else{for(let vn,Zt=0;Zt0;)pn.pop().fill(0);return Pt}}function pl(b,E,A,j,X,le=20){let Me=b[0],Pe=b[1],Qe=b[2],wt=b[3],Pt=E[0],Lt=E[1],nn=E[2],pn=E[3],tn=E[4],Yt=E[5],Zt=E[6],vn=E[7],Sn=X,Zn=A[0],or=A[1],Lr=A[2],mr=Me,Ar=Pe,$r=Qe,Ri=wt,Ei=Pt,ei=Lt,eo=nn,to=pn,wo=tn,rr=Yt,hr=Zt,Yr=vn,mi=Sn,yr=Zn,oi=or,Eo=Lr;for(let Bs=0;Bs{b.update(E);const A=E.length%16;A&&b.update(qi.subarray(A))},gc=new Uint8Array(32);function rs(b,E,A,j,X){const le=b(E,A,gc),Me=au.create(le);X&&Dr(Me,X),Dr(Me,j);const Pe=new Uint8Array(16),Qe=Il(Pe);Wo(Qe,0,BigInt(X?X.length:0),!0),Wo(Qe,8,BigInt(j.length),!0),Me.update(Pe);const wt=Me.digest();return le.fill(0),wt}const R=b=>(E,A,j)=>(_i(E,32),_i(A),{encrypt:(le,Me)=>{const Pe=le.length,Qe=Pe+16;Me?_i(Me,Qe):Me=new Uint8Array(Qe),b(E,A,le,Me,1);const wt=rs(b,E,A,Me.subarray(0,-16),j);return Me.set(wt,Pe),Me},decrypt:(le,Me)=>{const Pe=le.length,Qe=Pe-16;if(Pe<16)throw new Error("encrypted data must be at least 16 bytes");Me?_i(Me,Qe):Me=new Uint8Array(Qe);const wt=le.subarray(0,-16);if(!ha(le.subarray(-16),rs(b,E,A,wt,j)))throw new Error("invalid tag");return b(E,A,wt,Me,1),Me}});R(Yl),R(za);class K extends Xr.Vw{constructor(E,A){super(),this.finished=!1,this.destroyed=!1,Ao.hash(E);const j=(0,Xr.ZJ)(A);if(this.iHash=E.create(),"function"!=typeof this.iHash.update)throw new Error("Expected instance of class which extends utils.Hash");this.blockLen=this.iHash.blockLen,this.outputLen=this.iHash.outputLen;const X=this.blockLen,le=new Uint8Array(X);le.set(j.length>X?E.create().update(j).digest():j);for(let Me=0;Menew K(b,E).update(A).digest();_e.create=(b,E)=>new K(b,E);const At=new Uint8Array([0]),fn=new Uint8Array;var ui=Object.defineProperty,kr=(b,E)=>{for(var A in E)ui(b,A,{get:E[A],enumerable:!0})},Gi=Symbol("verified"),Is=b=>b instanceof Object;function is(b){if(!Is(b)||"number"!=typeof b.kind||"string"!=typeof b.content||"number"!=typeof b.created_at||"string"!=typeof b.pubkey||!b.pubkey.match(/^[a-f0-9]{64}$/)||!Array.isArray(b.tags))return!1;for(let E=0;Edh,QueueNode:()=>uh,binarySearch:()=>_d,insertEventIntoAscendingList:()=>Jp,insertEventIntoDescendingList:()=>$u,normalizeURL:()=>Ka,utf8Decoder:()=>Wr,utf8Encoder:()=>Ys});var Wr=new TextDecoder("utf-8"),Ys=new TextEncoder;function Ka(b){-1===b.indexOf("://")&&(b="wss://"+b);let E=new URL(b);return E.pathname=E.pathname.replace(/\/+/g,"/"),E.pathname.endsWith("/")&&(E.pathname=E.pathname.slice(0,-1)),("80"===E.port&&"ws:"===E.protocol||"443"===E.port&&"wss:"===E.protocol)&&(E.port=""),E.searchParams.sort(),E.hash="",E.toString()}function $u(b,E){const[A,j]=_d(b,X=>E.id===X.id?0:E.created_at===X.created_at?-1:X.created_at-E.created_at);return j||b.splice(A,0,E),b}function Jp(b,E){const[A,j]=_d(b,X=>E.id===X.id?0:E.created_at===X.created_at?-1:E.created_at-X.created_at);return j||b.splice(A,0,E),b}function _d(b,E){let A=0,j=b.length-1;for(;A<=j;){const X=Math.floor((A+j)/2),le=E(b[X]);if(0===le)return[X,!0];le<0?j=X-1:A=X+1}return[A,!1]}var uh=class{value;next=null;prev=null;constructor(b){this.value=b}},dh=class{first;last;constructor(){this.first=null,this.last=null}enqueue(b){const E=new uh(b);return this.last?this.last===this.first?(this.last=E,this.last.prev=this.first,this.first.next=E):(E.prev=this.last,this.last.next=E,this.last=E):(this.first=E,this.last=E),!0}dequeue(){if(!this.first)return null;if(this.first===this.last){const E=this.first;return this.first=null,this.last=null,E.value}const b=this.first;return this.first=b.next,b.value}};function Ql(b){let E=Ss(Ys.encode(function _c(b){if(!is(b))throw new Error("can't serialize event with wrong or missing properties");return JSON.stringify([0,b.pubkey,b.created_at,b.kind,b.tags,b.content])}(b)));return(0,Xr.My)(E)}var Zl=new class{generateSecretKey(){return No.utils.randomPrivateKey()}getPublicKey(b){return(0,Xr.My)(No.getPublicKey(b))}finalizeEvent(b,E){const A=b;return A.pubkey=(0,Xr.My)(No.getPublicKey(E)),A.id=Ql(A),A.sig=(0,Xr.My)(No.sign(Ql(A),E)),A[Gi]=!0,A}verifyEvent(b){if("boolean"==typeof b[Gi])return b[Gi];const E=Ql(b);if(E!==b.id)return b[Gi]=!1,!1;try{const A=No.verify(b.sig,E,b.pubkey);return b[Gi]=A,A}catch{return b[Gi]=!1,!1}}},uu=Zl.generateSecretKey,du=Zl.getPublicKey,Ja=Zl.finalizeEvent,En=Zl.verifyEvent;function Ic(b){return 1e3<=b&&b<1e4||[1,2,4,5,6,7,8,16,40,41,42,43,44].includes(b)}function hu(b){return[0,3].includes(b)||1e4<=b&&b<2e4}function Si(b){return 2e4<=b&&b<3e4}function Nl(b){return 3e4<=b&&b<4e4}function Ra(b){return Ic(b)?"regular":hu(b)?"replaceable":Si(b)?"ephemeral":Nl(b)?"parameterized":"unknown"}function Qs(b,E){const A=E instanceof Array?E:[E];return is(b)&&A.includes(b.kind)||!1}kr({},{Application:()=>wc,BadgeAward:()=>Zs,BadgeDefinition:()=>mh,BlockedRelaysList:()=>bo,BookmarkList:()=>ro,Bookmarksets:()=>yc,Calendar:()=>Ll,CalendarEventRSVP:()=>xf,ChannelCreation:()=>P,ChannelHideMessage:()=>Ae,ChannelMessage:()=>oe,ChannelMetadata:()=>$,ChannelMuteUser:()=>je,ClassifiedListing:()=>tm,ClientAuth:()=>gs,CommunitiesList:()=>Ji,CommunityDefinition:()=>rm,CommunityPostApproval:()=>nr,Contacts:()=>em,CreateOrUpdateProduct:()=>bc,CreateOrUpdateStall:()=>ml,Curationsets:()=>tc,Date:()=>nm,DirectMessageRelaysList:()=>jr,DraftClassifiedListing:()=>Wu,DraftLong:()=>ju,Emojisets:()=>Vu,EncryptedDirectMessage:()=>fh,EventDeletion:()=>ph,FileMetadata:()=>zt,FileServerPreference:()=>Hi,Followsets:()=>Jl,GenericRepost:()=>I,Genericlists:()=>vc,GiftWrap:()=>It,HTTPAuth:()=>Dl,Handlerinformation:()=>zu,Handlerrecommendation:()=>bd,Highlights:()=>ir,InterestsList:()=>ga,Interestsets:()=>Js,JobFeedback:()=>Xn,JobRequest:()=>Mn,JobResult:()=>Hn,Label:()=>zn,LightningPubRPC:()=>Mo,LiveChatMessage:()=>ln,LiveEvent:()=>gh,LongFormArticle:()=>nc,Metadata:()=>Oc,Mutelist:()=>Cr,NWCWalletInfo:()=>Yi,NWCWalletRequest:()=>qs,NWCWalletResponse:()=>Ps,NostrConnect:()=>el,OpenTimestamps:()=>pt,Pinlist:()=>Gr,PrivateDirectMessage:()=>yd,ProblemTracker:()=>An,ProfileBadges:()=>Rc,PublicChatsList:()=>Xi,Reaction:()=>ql,RecommendRelay:()=>vd,RelayList:()=>Br,Relaysets:()=>ec,Report:()=>Qt,Reporting:()=>Gn,Repost:()=>ma,Seal:()=>Cl,SearchRelaysList:()=>To,ShortTextNote:()=>pa,Time:()=>_h,UserEmojiList:()=>_r,UserStatuses:()=>Hu,Zap:()=>Ir,ZapGoal:()=>vr,ZapRequest:()=>$n,classifyKind:()=>Ra,isEphemeralKind:()=>Si,isKind:()=>Qs,isParameterizedReplaceableKind:()=>Nl,isRegularKind:()=>Ic,isReplaceableKind:()=>hu});var Oc=0,pa=1,vd=2,em=3,fh=4,ph=5,ma=6,ql=7,Zs=8,Cl=13,yd=14,I=16,P=40,$=41,oe=42,Ae=43,je=44,pt=1040,It=1059,zt=1063,ln=1311,An=1971,Qt=1984,Gn=1984,zn=1985,nr=4550,Mn=5999,Hn=6999,Xn=7e3,vr=9041,$n=9734,Ir=9735,ir=9802,Cr=1e4,Gr=10001,Br=10002,ro=10003,Ji=10004,Xi=10005,bo=10006,To=10007,ga=10015,_r=10030,jr=10050,Hi=10096,Yi=13194,Mo=21e3,gs=22242,qs=23194,Ps=23195,el=24133,Dl=27235,Jl=3e4,vc=30001,ec=30002,yc=30003,tc=30004,Rc=30008,mh=30009,Js=30015,ml=30017,bc=30018,nc=30023,ju=30024,Vu=30030,wc=30078,gh=30311,Hu=30315,tm=30402,Wu=30403,nm=31922,_h=31923,Ll=31924,xf=31925,bd=31989,zu=31990,rm=34550;function Pl(b,E){if(b.ids&&-1===b.ids.indexOf(E.id)||b.kinds&&-1===b.kinds.indexOf(E.kind)||b.authors&&-1===b.authors.indexOf(E.pubkey))return!1;for(let A in b)if("#"===A[0]){let X=b[`#${A.slice(1)}`];if(X&&!E.tags.find(([le,Me])=>le===A.slice(1)&&-1!==X.indexOf(Me)))return!1}return!(b.since&&E.created_atb.until)}function Nc(b,E){let A=E.length+3,j=b.indexOf(`"${E}":`)+A,X=b.slice(j).indexOf('"')+j+1;return b.slice(X,X+64)}function Lc(b,E){let A=E.length,j=b.indexOf(`"${E}":`)+A+3,X=b.slice(j),le=Math.min(X.indexOf(","),X.indexOf("}"));return parseInt(X.slice(0,le),10)}function Ed(b){let E=b.slice(0,22).indexOf('"EVENT"');if(-1===E)return null;let A=b.slice(E+7+1).indexOf('"');if(-1===A)return null;let j=E+7+1+A,X=b.slice(j+1,80).indexOf('"');return-1===X?null:b.slice(j+1,j+1+X)}function Ku(b,E){return E===Nc(b,"id")}function Df(b,E){return E===Nc(b,"pubkey")}function yh(b,E){return E===Lc(b,"kind")}function bh(b,E){return{kind:gs,created_at:Math.floor(Date.now()/1e3),tags:[["relay",b],["challenge",E]],content:""}}function fu(){return Fl.apply(this,arguments)}function Fl(){return(Fl=(0,a.A)(function*(){return new Promise(b=>{const E=new MessageChannel,A=()=>{E.port1.removeEventListener("message",A),b()};E.port1.addEventListener("message",A),E.port2.postMessage(0),E.port1.start()})})).apply(this,arguments)}kr({},{getHex64:()=>Nc,getInt:()=>Lc,getSubscriptionId:()=>Ed,matchEventId:()=>Ku,matchEventKind:()=>yh,matchEventPubkey:()=>Df}),kr({},{makeAuthEvent:()=>bh});var Pg=b=>(b[Gi]=!0,!0),xd=class{url;_connected=!1;onclose=null;onnotice=b=>console.debug(`NOTICE from ${this.url}: ${b}`);_onauth=null;baseEoseTimeout=4400;connectionTimeout=4400;publishTimeout=4400;openSubs=new Map;connectionTimeoutHandle;connectionPromise;openCountRequests=new Map;openEventPublishes=new Map;ws;incomingMessageQueue=new dh;queueRunning=!1;challenge;serial=0;verifyEvent;_WebSocket;constructor(b,E){this.url=Ka(b),this.verifyEvent=E.verifyEvent,this._WebSocket=E.websocketImplementation||WebSocket}static connect(b,E){return(0,a.A)(function*(){const A=new xd(b,E);return yield A.connect(),A})()}closeAllSubscriptions(b){for(let[E,A]of this.openSubs)A.close(b);this.openSubs.clear();for(let[E,A]of this.openEventPublishes)A.reject(new Error(b));this.openEventPublishes.clear();for(let[E,A]of this.openCountRequests)A.reject(new Error(b));this.openCountRequests.clear()}get connected(){return this._connected}connect(){var b=this;return(0,a.A)(function*(){return b.connectionPromise||(b.challenge=void 0,b.connectionPromise=new Promise((E,A)=>{b.connectionTimeoutHandle=setTimeout(()=>{A("connection timed out"),b.connectionPromise=void 0,b.onclose?.(),b.closeAllSubscriptions("relay connection timed out")},b.connectionTimeout);try{b.ws=new b._WebSocket(b.url)}catch(j){return void A(j)}b.ws.onopen=()=>{clearTimeout(b.connectionTimeoutHandle),b._connected=!0,E()},b.ws.onerror=j=>{A(j.message||"websocket error"),b._connected&&(b._connected=!1,b.connectionPromise=void 0,b.onclose?.(),b.closeAllSubscriptions("relay connection errored"))},b.ws.onclose=(0,a.A)(function*(){b._connected&&(b._connected=!1,b.connectionPromise=void 0,b.onclose?.(),b.closeAllSubscriptions("relay connection closed"))}),b.ws.onmessage=b._onmessage.bind(b)})),b.connectionPromise})()}runQueue(){var b=this;return(0,a.A)(function*(){for(b.queueRunning=!0;!1!==b.handleNext();)yield fu();b.queueRunning=!1})()}handleNext(){const b=this.incomingMessageQueue.dequeue();if(!b)return!1;const E=Ed(b);if(E){const A=this.openSubs.get(E);if(!A)return;const j=Nc(b,"id"),X=A.alreadyHaveEvent?.(j);if(A.receivedEvent?.(this,j),X)return}try{let A=JSON.parse(b);switch(A[0]){case"EVENT":{const j=this.openSubs.get(A[1]),X=A[2];return void(this.verifyEvent(X)&&function im(b,E){for(let A=0;A{E.ws?.send(b)})})()}auth(b){var E=this;return(0,a.A)(function*(){if(!E.challenge)throw new Error("can't perform auth, no challenge was received");const A=yield b(bh(E.url,E.challenge)),j=new Promise((X,le)=>{E.openEventPublishes.set(A.id,{resolve:X,reject:le})});return E.send('["AUTH",'+JSON.stringify(A)+"]"),j})()}publish(b){var E=this;return(0,a.A)(function*(){const A=new Promise((j,X)=>{E.openEventPublishes.set(b.id,{resolve:j,reject:X})});return E.send('["EVENT",'+JSON.stringify(b)+"]"),setTimeout(()=>{const j=E.openEventPublishes.get(b.id);j&&(j.reject(new Error("publish timed out")),E.openEventPublishes.delete(b.id))},E.publishTimeout),A})()}count(b,E){var A=this;return(0,a.A)(function*(){A.serial++;const j=E?.id||"count:"+A.serial,X=new Promise((le,Me)=>{A.openCountRequests.set(j,{resolve:le,reject:Me})});return A.send('["COUNT","'+j+'",'+JSON.stringify(b).substring(1)),X})()}subscribe(b,E){const A=this.prepareSubscription(b,E);return A.fire(),A}prepareSubscription(b,E){this.serial++;const A=E.id||"sub:"+this.serial,j=new wh(this,A,b,E);return this.openSubs.set(A,j),j}close(){this.closeAllSubscriptions("relay connection closed by us"),this._connected=!1,this.ws?.close()}_onmessage(b){this.incomingMessageQueue.enqueue(b.data),this.queueRunning||this.runQueue()}},wh=class{relay;id;closed=!1;eosed=!1;filters;alreadyHaveEvent;receivedEvent;onevent;oneose;onclose;eoseTimeout;eoseTimeoutHandle;constructor(b,E,A,j){this.relay=b,this.filters=A,this.id=E,this.alreadyHaveEvent=j.alreadyHaveEvent,this.receivedEvent=j.receivedEvent,this.eoseTimeout=j.eoseTimeout||b.baseEoseTimeout,this.oneose=j.oneose,this.onclose=j.onclose,this.onevent=j.onevent||(X=>{console.warn(`onevent() callback not defined for subscription '${this.id}' in relay ${this.relay.url}. event received:`,X)})}fire(){this.relay.send('["REQ","'+this.id+'",'+JSON.stringify(this.filters).substring(1)),this.eoseTimeoutHandle=setTimeout(this.receivedEose.bind(this),this.eoseTimeout)}receivedEose(){this.eosed||(clearTimeout(this.eoseTimeoutHandle),this.eosed=!0,this.oneose?.())}close(b="closed by caller"){!this.closed&&this.relay.connected&&(this.relay.send('["CLOSE",'+JSON.stringify(this.id)+"]"),this.closed=!0),this.relay.openSubs.delete(this.id),this.onclose?.(b)}};try{WebSocket}catch{}var Sf,Fs=class{relays=new Map;seenOn=new Map;trackRelays=!1;verifyEvent;trustedRelayURLs=new Set;_WebSocket;constructor(b){this.verifyEvent=b.verifyEvent,this._WebSocket=b.websocketImplementation}ensureRelay(b,E){var A=this;return(0,a.A)(function*(){b=Ka(b);let j=A.relays.get(b);return j||(j=new xd(b,{verifyEvent:A.trustedRelayURLs.has(b)?Pg:A.verifyEvent,websocketImplementation:A._WebSocket}),E?.connectionTimeout&&(j.connectionTimeout=E.connectionTimeout),A.relays.set(b,j)),yield j.connect(),j})()}close(b){b.map(Ka).forEach(E=>{this.relays.get(E)?.close()})}subscribeMany(b,E,A){return this.subscribeManyMap(Object.fromEntries(b.map(j=>[j,E])),A)}subscribeManyMap(b,E){var A=this;this.trackRelays&&(E.receivedEvent=(nn,pn)=>{let tn=this.seenOn.get(pn);tn||(tn=new Set,this.seenOn.set(pn,tn)),tn.add(nn)});const j=new Set,X=[],le=Object.keys(b).length,Me=[];let Pe=nn=>{Me[nn]=!0,Me.filter(pn=>pn).length===le&&(E.oneose?.(),Pe=()=>{})};const Qe=[];let wt=(nn,pn)=>{Pe(nn),Qe[nn]=pn,Qe.filter(tn=>tn).length===le&&(E.onclose?.(Qe),wt=()=>{})};const Pt=nn=>{if(E.alreadyHaveEvent?.(nn))return!0;const pn=j.has(nn);return j.add(nn),pn},Lt=Promise.all(Object.entries(b).map(function(){var nn=(0,a.A)(function*(pn,tn,Yt){if(Yt.indexOf(pn)!==tn)return void wt(tn,"duplicate url");let Sn,[Zt,vn]=pn;Zt=Ka(Zt);try{Sn=yield A.ensureRelay(Zt,{connectionTimeout:E.maxWait?Math.max(.8*E.maxWait,E.maxWait-1e3):void 0})}catch(or){return void wt(tn,or?.message||String(or))}let Zn=Sn.subscribe(vn,{...E,oneose:()=>Pe(tn),onclose:or=>wt(tn,or),alreadyHaveEvent:Pt,eoseTimeout:E.maxWait});X.push(Zn)});return function(pn,tn,Yt){return nn.apply(this,arguments)}}()));return{close:()=>(0,a.A)(function*(){yield Lt,X.forEach(nn=>{nn.close()})})()}}subscribeManyEose(b,E,A){const j=this.subscribeMany(b,E,{...A,oneose(){j.close()}});return j}querySync(b,E,A){var j=this;return(0,a.A)(function*(){return new Promise(function(){var X=(0,a.A)(function*(le){const Me=[];j.subscribeManyEose(b,[E],{...A,onevent(Pe){Me.push(Pe)},onclose(Pe){le(Me)}})});return function(le){return X.apply(this,arguments)}}())})()}get(b,E,A){var j=this;return(0,a.A)(function*(){E.limit=1;const X=yield j.querySync(b,E,A);return X.sort((le,Me)=>Me.created_at-le.created_at),X[0]||null})()}publish(b,E){var A=this;return b.map(Ka).map(function(){var j=(0,a.A)(function*(X,le,Me){if(Me.indexOf(X)!==le)return Promise.reject("duplicate url");let Pe=yield A.ensureRelay(X);return Pe.publish(E).then(Qe=>{if(A.trackRelays){let wt=A.seenOn.get(E.id);wt||(wt=new Set,A.seenOn.set(E.id,wt)),wt.add(Pe)}return Qe})});return function(X,le,Me){return j.apply(this,arguments)}}())}listConnectionStatus(){const b=new Map;return this.relays.forEach((E,A)=>b.set(A,E.connected)),b}destroy(){this.relays.forEach(b=>b.close()),this.relays=new Map}};try{Sf=WebSocket}catch{}var Eh=class extends Fs{constructor(){super({verifyEvent:En,websocketImplementation:Sf})}},Cd={};kr(Cd,{BECH32_REGEX:()=>Xu,Bech32MaxSize:()=>Gu,NostrTypeGuard:()=>om,decode:()=>mu,encodeBytes:()=>Ga,naddrEncode:()=>Td,neventEncode:()=>Qu,noteEncode:()=>Mf,nprofileEncode:()=>Sd,npubEncode:()=>Tf,nsecEncode:()=>Dd});var om={isNProfile:b=>/^nprofile1[a-z\d]+$/.test(b||""),isNEvent:b=>/^nevent1[a-z\d]+$/.test(b||""),isNAddr:b=>/^naddr1[a-z\d]+$/.test(b||""),isNSec:b=>/^nsec1[a-z\d]{58}$/.test(b||""),isNPub:b=>/^npub1[a-z\d]{58}$/.test(b||""),isNote:b=>/^note1[a-z\d]+$/.test(b||""),isNcryptsec:b=>/^ncryptsec1[a-z\d]+$/.test(b||"")},Gu=5e3,Xu=/[\x21-\x7E]{1,83}1[023456789acdefghjklmnpqrstuvwxyz]{6,}/;function mu(b){let{prefix:E,words:A}=de.decode(b,Gu),j=new Uint8Array(de.fromWords(A));switch(E){case"nprofile":{let X=Yu(j);if(!X[0]?.[0])throw new Error("missing TLV 0 for nprofile");if(32!==X[0][0].length)throw new Error("TLV 0 should be 32 bytes");return{type:"nprofile",data:{pubkey:(0,Xr.My)(X[0][0]),relays:X[1]?X[1].map(le=>Wr.decode(le)):[]}}}case"nevent":{let X=Yu(j);if(!X[0]?.[0])throw new Error("missing TLV 0 for nevent");if(32!==X[0][0].length)throw new Error("TLV 0 should be 32 bytes");if(X[2]&&32!==X[2][0].length)throw new Error("TLV 2 should be 32 bytes");if(X[3]&&4!==X[3][0].length)throw new Error("TLV 3 should be 4 bytes");return{type:"nevent",data:{id:(0,Xr.My)(X[0][0]),relays:X[1]?X[1].map(le=>Wr.decode(le)):[],author:X[2]?.[0]?(0,Xr.My)(X[2][0]):void 0,kind:X[3]?.[0]?parseInt((0,Xr.My)(X[3][0]),16):void 0}}}case"naddr":{let X=Yu(j);if(!X[0]?.[0])throw new Error("missing TLV 0 for naddr");if(!X[2]?.[0])throw new Error("missing TLV 2 for naddr");if(32!==X[2][0].length)throw new Error("TLV 2 should be 32 bytes");if(!X[3]?.[0])throw new Error("missing TLV 3 for naddr");if(4!==X[3][0].length)throw new Error("TLV 3 should be 4 bytes");return{type:"naddr",data:{identifier:Wr.decode(X[0][0]),pubkey:(0,Xr.My)(X[2][0]),kind:parseInt((0,Xr.My)(X[3][0]),16),relays:X[1]?X[1].map(le=>Wr.decode(le)):[]}}}case"nsec":return{type:E,data:j};case"npub":case"note":return{type:E,data:(0,Xr.My)(j)};default:throw new Error(`unknown prefix ${E}`)}}function Yu(b){let E={},A=b;for(;A.length>0;){let j=A[0],X=A[1],le=A.slice(2,2+X);if(A=A.slice(2+X),le.lengthYs.encode(A))}))}function Qu(b){let E;return void 0!==b.kind&&(E=function xh(b){const E=new Uint8Array(4);return E[0]=b>>24&255,E[1]=b>>16&255,E[2]=b>>8&255,E[3]=255&b,E}(b.kind)),Ad("nevent",Ch({0:[(0,Xr.aT)(b.id)],1:(b.relays||[]).map(j=>Ys.encode(j)),2:b.author?[(0,Xr.aT)(b.author)]:[],3:E?[new Uint8Array(E)]:[]}))}function Td(b){let E=new ArrayBuffer(4);return new DataView(E).setUint32(0,b.kind,!1),Ad("naddr",Ch({0:[Ys.encode(b.identifier)],1:(b.relays||[]).map(j=>Ys.encode(j)),2:[(0,Xr.aT)(b.pubkey)],3:[new Uint8Array(E)]}))}function Ch(b){let E=[];return Object.entries(b).reverse().forEach(([A,j])=>{j.forEach(X=>{let le=new Uint8Array(X.length+2);le.set([parseInt(A)],0),le.set([X.length],1),le.set(X,2),E.push(le)})}),(0,Xr.Id)(...E)}var Dh={};function Ah(b,E,A){return Qo.apply(this,arguments)}function Qo(){return(Qo=(0,a.A)(function*(b,E,A){const j=b instanceof Uint8Array?(0,Xr.My)(b):b,le=kf(wr.getSharedSecret(j,"02"+E));let Me=Uint8Array.from((0,Xr.po)(16)),Pe=Ys.encode(A),Qe=qa(le,Me).encrypt(Pe);return`${Qn.encode(new Uint8Array(Qe))}?iv=${Qn.encode(new Uint8Array(Me.buffer))}`})).apply(this,arguments)}function lm(b,E,A){return Md.apply(this,arguments)}function Md(){return(Md=(0,a.A)(function*(b,E,A){const j=b instanceof Uint8Array?(0,Xr.My)(b):b;let[X,le]=A.split("?iv="),Pe=kf(wr.getSharedSecret(j,"02"+E)),Qe=Qn.decode(le),wt=Qn.decode(X),Pt=qa(Pe,Qe).decrypt(wt);return Wr.decode(Pt)})).apply(this,arguments)}function kf(b){return b.slice(1,33)}kr(Dh,{decrypt:()=>lm,encrypt:()=>Ah}),kr({},{NIP05_REGEX:()=>ws,isNip05:()=>Fc,isValid:()=>Ec,queryProfile:()=>Od,searchDomain:()=>gu,useFetchImplementation:()=>rc});var kd,ws=/^(?:([\w.+-]+)@)?([\w_-]+(\.[\w_-]+)+)$/,Fc=b=>ws.test(b||"");try{kd=fetch}catch{}function rc(b){kd=b}function gu(b){return If.apply(this,arguments)}function If(){return(If=(0,a.A)(function*(b,E=""){try{const A=`https://${b}/.well-known/nostr.json?name=${E}`,j=yield kd(A,{redirect:"manual"});if(200!==j.status)throw Error("Wrong response code");return(yield j.json()).names}catch{return{}}})).apply(this,arguments)}function Od(b){return ic.apply(this,arguments)}function ic(){return(ic=(0,a.A)(function*(b){const E=b.match(ws);if(!E)return null;const[,A="_",j]=E;try{const X=`https://${j}/.well-known/nostr.json?name=${A}`,le=yield kd(X,{redirect:"manual"});if(200!==le.status)throw Error("Wrong response code");const Me=yield le.json(),Pe=Me.names[A];return Pe?{pubkey:Pe,relays:Me.relays?.[Pe]}:null}catch{return null}})).apply(this,arguments)}function Ec(b,E){return Th.apply(this,arguments)}function Th(){return(Th=(0,a.A)(function*(b,E){const A=yield Od(E);return!!A&&A.pubkey===b})).apply(this,arguments)}function oc(b){const E={reply:void 0,root:void 0,mentions:[],profiles:[],quotes:[]};let A,j;for(let X=b.tags.length-1;X>=0;X--){const le=b.tags[X];if("e"===le[0]&&le[1]){const[Me,Pe,Qe,wt,Pt]=le,Lt={id:Pe,relays:Qe?[Qe]:[],author:Pt};if("root"===wt){E.root=Lt;continue}if("reply"===wt){E.reply=Lt;continue}if("mention"===wt){E.mentions.push(Lt);continue}A?j=Lt:A=Lt,E.mentions.push(Lt)}else{if("q"===le[0]&&le[1]){const[Me,Pe,Qe]=le;E.quotes.push({id:Pe,relays:Qe?[Qe]:[]})}"p"===le[0]&&le[1]&&E.profiles.push({pubkey:le[1],relays:le[2]?[le[2]]:[]})}}return E.root||(E.root=j||A||E.reply),E.reply||(E.reply=A||E.root),[E.reply,E.root].forEach(X=>{if(!X)return;let le=E.mentions.indexOf(X);if(-1!==le&&E.mentions.splice(le,1),X.author){let Me=E.profiles.find(Pe=>Pe.pubkey===X.author);Me&&Me.relays&&(X.relays||(X.relays=[]),Me.relays.forEach(Pe=>{-1===X.relays?.indexOf(Pe)&&X.relays.push(Pe)}),Me.relays=X.relays)}}),E.mentions.forEach(X=>{if(X.author){let le=E.profiles.find(Me=>Me.pubkey===X.author);le&&le.relays&&(X.relays||(X.relays=[]),le.relays.forEach(Me=>{-1===X.relays.indexOf(Me)&&X.relays.push(Me)}),le.relays=X.relays)}}),E}kr({},{parse:()=>oc}),kr({},{fetchRelayInformation:()=>oy,useFetchImplementation:()=>cm});try{fetch}catch{}function cm(b){}function oy(b){return xc.apply(this,arguments)}function xc(){return(xc=(0,a.A)(function*(b){return yield(yield fetch(b.replace("ws://","http://").replace("wss://","https://"),{headers:{Accept:"application/nostr+json"}})).json()})).apply(this,arguments)}function kh(b){let E=0;for(let A=0;A<64;A+=8){const j=parseInt(b.substring(A,A+8),16);if(0!==j){E+=Math.clz32(j);break}E+=32}return E}function os(b,E){let A=0;const j=b,X=["nonce",A.toString(),E.toString()];for(j.tags.push(X);;){const le=Math.floor((new Date).getTime()/1e3);if(le!==j.created_at&&(A=0,j.created_at=le),X[1]=(++A).toString(),j.id=Of(j),kh(j.id)>=E)break}return j}function Of(b){return(0,Xr.My)(Ss(Ys.encode(JSON.stringify([0,b.pubkey,b.created_at,b.kind,b.tags,b.content]))))}function um(b,E,A,j){return Ja({kind:ma,tags:[...b.tags??[],["e",E.id,A],["p",E.pubkey]],content:""===b.content?"":JSON.stringify(E),created_at:b.created_at},j)}function Rf(b){if(b.kind!==ma)return;let E,A;for(let j=b.tags.length-1;j>=0&&(void 0===E||void 0===A);j--){const X=b.tags[j];X.length>=2&&("e"===X[0]&&void 0===E?E=X:"p"===X[0]&&void 0===A&&(A=X))}return void 0!==E?{id:E[1],relays:[E[2],A?.[2]].filter(j=>"string"==typeof j),author:A?.[1]}:void 0}function Oh(b,{skipVerification:E}={}){const A=Rf(b);if(void 0===A||""===b.content)return;let j;try{j=JSON.parse(b.content)}catch{return}return j.id===A.id&&(E||En(j))?j:void 0}kr({},{fastEventHash:()=>Of,getPow:()=>kh,minePow:()=>os}),kr({},{finishRepostEvent:()=>um,getRepostedEvent:()=>Oh,getRepostedEventPointer:()=>Rf}),kr({},{NOSTR_URI_REGEX:()=>vu,parse:()=>dm,test:()=>Rh});var vu=new RegExp(`nostr:(${Xu.source})`);function Rh(b){return"string"==typeof b&&new RegExp(`^${vu.source}$`).test(b)}function dm(b){const E=b.match(new RegExp(`^${vu.source}$`));if(!E)throw new Error(`Invalid Nostr URI: ${b}`);return{uri:E[0],value:E[1],decoded:mu(E[1])}}function Lf(b,E,A){const j=E.tags.filter(X=>X.length>=2&&("e"===X[0]||"p"===X[0]));return Ja({...b,kind:ql,tags:[...b.tags??[],...j,["e",E.id],["p",E.pubkey]],content:b.content??"+"},A)}function Bg(b){if(b.kind!==ql)return;let E,A;for(let j=b.tags.length-1;j>=0&&(void 0===E||void 0===A);j--){const X=b.tags[j];X.length>=2&&("e"===X[0]&&void 0===E?E=X:"p"===X[0]&&void 0===A&&(A=X))}return void 0!==E&&void 0!==A?{id:E[1],relays:[E[2],A[2]].filter(j=>void 0!==j),author:A[1]}:void 0}kr({},{finishReactionEvent:()=>Lf,getReactedEventPointer:()=>Bg}),kr({},{matchAll:()=>yu,regex:()=>qu,replaceAll:()=>Ug});var qu=()=>new RegExp(`\\b${vu.source}\\b`,"g");function*yu(b){const E=b.matchAll(qu());for(const A of E)try{const[j,X]=A;yield{uri:j,value:X,decoded:mu(X),start:A.index,end:A.index+j.length}}catch{}}function Ug(b,E){return b.replaceAll(qu(),(A,j)=>E({uri:A,value:j,decoded:mu(j)}))}kr({},{channelCreateEvent:()=>Pf,channelHideMessageEvent:()=>wu,channelMessageEvent:()=>$g,channelMetadataEvent:()=>bu,channelMuteUserEvent:()=>Dc});var Pf=(b,E)=>{let A;if("object"==typeof b.content)A=JSON.stringify(b.content);else{if("string"!=typeof b.content)return;A=b.content}return Ja({kind:P,tags:[...b.tags??[]],content:A,created_at:b.created_at},E)},bu=(b,E)=>{let A;if("object"==typeof b.content)A=JSON.stringify(b.content);else{if("string"!=typeof b.content)return;A=b.content}return Ja({kind:$,tags:[["e",b.channel_create_event_id],...b.tags??[]],content:A,created_at:b.created_at},E)},$g=(b,E)=>{const A=[["e",b.channel_create_event_id,b.relay_url,"root"]];return b.reply_to_channel_message_event_id&&A.push(["e",b.reply_to_channel_message_event_id,b.relay_url,"reply"]),Ja({kind:oe,tags:[...A,...b.tags??[]],content:b.content,created_at:b.created_at},E)},wu=(b,E)=>{let A;if("object"==typeof b.content)A=JSON.stringify(b.content);else{if("string"!=typeof b.content)return;A=b.content}return Ja({kind:Ae,tags:[["e",b.channel_message_event_id],...b.tags??[]],content:A,created_at:b.created_at},E)},Dc=(b,E)=>{let A;if("object"==typeof b.content)A=JSON.stringify(b.content);else{if("string"!=typeof b.content)return;A=b.content}return Ja({kind:je,tags:[["p",b.pubkey_to_mute],...b.tags??[]],content:A,created_at:b.created_at},E)};kr({},{EMOJI_SHORTCODE_REGEX:()=>Nh,matchAll:()=>Ff,regex:()=>Nd,replaceAll:()=>Ju});var ed,Nh=/:(\w+):/,Nd=()=>new RegExp(`\\B${Nh.source}\\B`,"g");function*Ff(b){const E=b.matchAll(Nd());for(const A of E)try{const[j,X]=A;yield{shortcode:j,name:X,start:A.index,end:A.index+j.length}}catch{}}function Ju(b,E){return b.replaceAll(Nd(),(A,j)=>E({shortcode:A,name:j}))}kr({},{useFetchImplementation:()=>Lh,validateGithub:()=>td});try{ed=fetch}catch{}function Lh(b){ed=b}function td(b,E,A){return Bc.apply(this,arguments)}function Bc(){return(Bc=(0,a.A)(function*(b,E,A){try{return(yield(yield ed(`https://gist.github.com/${E}/${A}/raw`)).text())===`Verifying that I control the following Nostr public key: ${b}`}catch{return!1}})).apply(this,arguments)}kr({},{decrypt:()=>Bh,encrypt:()=>rd,getConversationKey:()=>xu,v2:()=>Uc});var sc=1,nd=65535;function xu(b,E){const A=wr.getSharedSecret(b,"02"+E).subarray(1,33);return function We(b,E,A){return Ao.hash(b),void 0===A&&(A=new Uint8Array(b.outputLen)),_e(b,(0,Xr.ZJ)(A),(0,Xr.ZJ)(E))}(Ss,A,"nip44-v2")}function Bf(b,E){const A=function on(b,E,A,j=32){if(Ao.hash(b),Ao.number(j),j>255*b.outputLen)throw new Error("Length should be <= 255*HashLen");const X=Math.ceil(j/b.outputLen);void 0===A&&(A=fn);const le=new Uint8Array(X*b.outputLen),Me=_e.create(b,E),Pe=Me._cloneInto(),Qe=new Uint8Array(Me.outputLen);for(let wt=0;wtnd)throw new Error("invalid plaintext size: must be between 1 and 65535 bytes");const E=new Uint8Array(2);return new DataView(E.buffer).setUint16(0,b,!1),E}(A),X=new Uint8Array(Ld(A)-A);return(0,Xr.Id)(j,E,X)}(b),Pe=Yl(j,X,Me),Qe=$f(le,Pe,A);return Qn.encode((0,Xr.Id)(new Uint8Array([2]),A,Pe,Qe))}function Bh(b,E){const{nonce:A,ciphertext:j,mac:X}=function va(b){if("string"!=typeof b)throw new Error("payload must be a valid string");const E=b.length;if(E<132||E>87472)throw new Error("invalid payload length: "+E);if("#"===b[0])throw new Error("unknown encryption version");let A;try{A=Qn.decode(b)}catch(le){throw new Error("invalid base64: "+le.message)}const j=A.length;if(j<99||j>65603)throw new Error("invalid data length: "+j);const X=A[0];if(2!==X)throw new Error("unknown encryption version "+X);return{nonce:A.subarray(1,33),ciphertext:A.subarray(33,-32),mac:A.subarray(-32)}}(b),{chacha_key:le,chacha_nonce:Me,hmac_key:Pe}=Bf(E,A);if(!ha($f(Pe,j,A),X))throw new Error("invalid MAC");return function Uf(b){const E=new DataView(b.buffer).getUint16(0),A=b.subarray(2,2+E);if(End||A.length!==E||b.length!==2+Ld(E))throw new Error("invalid padding");return Wr.decode(A)}(Yl(le,Me,j))}var id,Uc={utils:{getConversationKey:xu,calcPaddedLen:Ld},encrypt:rd,decrypt:Bh};function fm(b){const{pathname:E,searchParams:A}=new URL(b),j=E,X=A.get("relay"),le=A.get("secret");if(!j||!X||!le)throw new Error("invalid connection string");return{pubkey:j,relay:X,secret:le}}function ya(b,E,A){return ac.apply(this,arguments)}function ac(){return(ac=(0,a.A)(function*(b,E,A){const X=yield Ah(E,b,JSON.stringify({method:"pay_invoice",params:{invoice:A}})),le={kind:qs,created_at:Math.round(Date.now()/1e3),content:X,tags:[["p",b]]};return Ja(le,E)})).apply(this,arguments)}kr({},{makeNwcRequestEvent:()=>ya,parseConnectionString:()=>fm}),kr({},{getZapEndpoint:()=>$h,makeZapReceipt:()=>jh,makeZapRequest:()=>Vf,useFetchImplementation:()=>jf,validateZapRequest:()=>Hf});try{id=fetch}catch{}function jf(b){id=b}function $h(b){return Pd.apply(this,arguments)}function Pd(){return(Pd=(0,a.A)(function*(b){try{let E="",{lud06:A,lud16:j}=JSON.parse(b.content);if(A){let{words:Me}=de.decode(A,1e3),Pe=de.fromWords(Me);E=Wr.decode(Pe)}else{if(!j)return null;{let[Me,Pe]=j.split("@");E=new URL(`/.well-known/lnurlp/${Me}`,`https://${Pe}`).toString()}}let le=yield(yield id(E)).json();if(le.allowsNostr&&le.nostrPubkey)return le.callback}catch{}return null})).apply(this,arguments)}function Vf({profile:b,event:E,amount:A,relays:j,comment:X=""}){if(!A)throw new Error("amount not given");if(!b)throw new Error("profile not given");let le={kind:9734,created_at:Math.round(Date.now()/1e3),content:X,tags:[["p",b],["amount",A.toString()],["relays",...j]]};return E&&le.tags.push(["e",E]),le}function Hf(b){let E;try{E=JSON.parse(b)}catch{return"Invalid zap request JSON."}if(!is(E))return"Zap request is not a valid Nostr event.";if(!En(E))return"Invalid signature on zap request.";let A=E.tags.find(([le,Me])=>"p"===le&&Me);if(!A)return"Zap request doesn't have a 'p' tag.";if(!A[1].match(/^[a-f0-9]{64}$/))return"Zap request 'p' tag is not valid hex.";let j=E.tags.find(([le,Me])=>"e"===le&&Me);return j&&!j[1].match(/^[a-f0-9]{64}$/)?"Zap request 'e' tag is not valid hex.":E.tags.find(([le,Me])=>"relays"===le&&Me)?null:"Zap request doesn't have a 'relays' tag."}function jh({zapRequest:b,preimage:E,bolt11:A,paidAt:j}){let X=JSON.parse(b),le=X.tags.filter(([Pe])=>"e"===Pe||"p"===Pe||"a"===Pe),Me={kind:9735,created_at:Math.round(j.getTime()/1e3),content:"",tags:[...le,["P",X.pubkey],["bolt11",A],["description",b]]};return E&&Me.tags.push(["preimage",E]),Me}kr({},{createRumor:()=>Fd,createSeal:()=>Bd,createWrap:()=>Ud,unwrapEvent:()=>mm,unwrapManyEvents:()=>Wh,wrapEvent:()=>Cu,wrapManyEvents:()=>Hh});var zf=()=>Math.round(Date.now()/1e3),Kf=()=>Math.round(zf()-172800*Math.random()),lc=(b,E)=>xu(b,E),Vh=(b,E,A)=>rd(JSON.stringify(b),lc(E,A)),od=(b,E)=>JSON.parse(Bh(b.content,lc(E,b.pubkey)));function Fd(b,E){const A={created_at:zf(),content:"",tags:[],...b,pubkey:du(E)};return A.id=Ql(A),A}function Bd(b,E,A){return Ja({kind:Cl,content:Vh(b,E,A),created_at:Kf(),tags:[]},E)}function Ud(b,E){const A=uu();return Ja({kind:It,content:Vh(b,A,E),created_at:Kf(),tags:[["p",E]]},A)}function Cu(b,E,A){return Ud(Bd(Fd(b,E),E,A),A)}function Hh(b,E,A){if(!A||0===A.length)throw new Error("At least one recipient is required.");const j=du(E),X=[Cu(b,E,j)];return A.forEach(le=>{X.push(Cu(b,E,le))}),X}function mm(b,E){const A=od(b,E);return od(A,E)}function Wh(b,E){let A=[];return b.forEach(j=>{A.push(mm(j,E))}),A.sort((j,X)=>j.created_at-X.created_at),A}kr({},{getToken:()=>Xf,hashPayload:()=>nl,unpackEventFromToken:()=>Yf,validateEvent:()=>Yh,validateEventKind:()=>Gh,validateEventMethodTag:()=>_m,validateEventPayloadTag:()=>Du,validateEventTimestamp:()=>Qf,validateEventUrlTag:()=>Xh,validateToken:()=>$c});var Gf="Nostr ";function Xf(b,E,A){return zh.apply(this,arguments)}function zh(){return(zh=(0,a.A)(function*(b,E,A,j=!1,X){const le={kind:Dl,tags:[["u",b],["method",E]],created_at:Math.round((new Date).getTime()/1e3),content:""};X&&le.tags.push(["payload",nl(X)]);const Me=yield A(le);return(j?Gf:"")+Qn.encode(Ys.encode(JSON.stringify(Me)))})).apply(this,arguments)}function $c(b,E,A){return jc.apply(this,arguments)}function jc(){return(jc=(0,a.A)(function*(b,E,A){const j=yield Yf(b).catch(le=>{throw le});return yield Yh(j,E,A).catch(le=>{throw le})})).apply(this,arguments)}function Yf(b){return Kh.apply(this,arguments)}function Kh(){return(Kh=(0,a.A)(function*(b){if(!b)throw new Error("Missing token");b=b.replace(Gf,"");const E=Wr.decode(Qn.decode(b));if(!E||0===E.length||!E.startsWith("{"))throw new Error("Invalid token");return JSON.parse(E)})).apply(this,arguments)}function Qf(b){return!!b.created_at&&Math.round((new Date).getTime()/1e3)-b.created_at<60}function Gh(b){return b.kind===Dl}function Xh(b,E){const A=b.tags.find(j=>"u"===j[0]);return!!A&&A.length>0&&A[1]===E}function _m(b,E){const A=b.tags.find(j=>"method"===j[0]);return!!A&&A.length>0&&A[1].toLowerCase()===E.toLowerCase()}function nl(b){const E=Ss(Ys.encode(JSON.stringify(b)));return(0,Xr.My)(E)}function Du(b,E){const A=b.tags.find(X=>"payload"===X[0]);if(!A)return!1;const j=nl(E);return A.length>0&&A[1]===j}function Yh(b,E,A,j){return sd.apply(this,arguments)}function sd(){return(sd=(0,a.A)(function*(b,E,A,j){if(!En(b))throw new Error("Invalid nostr event, signature invalid");if(!Gh(b))throw new Error("Invalid nostr event, kind invalid");if(!Qf(b))throw new Error("Invalid nostr event, created_at timestamp invalid");if(!Xh(b,E))throw new Error("Invalid nostr event, url tag invalid");if(!_m(b,A))throw new Error("Invalid nostr event, method tag invalid");if(j&&"object"==typeof j&&Object.keys(j).length>0&&!Du(b,j))throw new Error("Invalid nostr event, payload tag does not match request body hash");return!0})).apply(this,arguments)}},3797:(o,s,r)=>{"use strict";r.d(s,{OS:()=>O,av:()=>L,qT:()=>ae,rV:()=>re}),Symbol("verified");var O=0,L=1,re=4,ae=7},4704:(o,s,r)=>{"use strict";r.d(s,{Vw:()=>ae,My:()=>M,Id:()=>se,O8:()=>w,aT:()=>O,po:()=>ce,Ow:()=>C,ZJ:()=>pe,ld:()=>Oe});const i="object"==typeof globalThis&&"crypto"in globalThis?globalThis.crypto:void 0,a=ue=>ue instanceof Uint8Array,w=ue=>new DataView(ue.buffer,ue.byteOffset,ue.byteLength),C=(ue,Ce)=>ue<<32-Ce|ue>>>Ce;if(68!==new Uint8Array(new Uint32Array([287454020]).buffer)[0])throw new Error("Non little-endian hardware is not supported");const S=Array.from({length:256},(ue,Ce)=>Ce.toString(16).padStart(2,"0"));function M(ue){if(!a(ue))throw new Error("Uint8Array expected");let Ce="";for(let Be=0;Beat+dt.length,0));let Be=0;return ue.forEach(at=>{if(!a(at))throw new Error("Uint8Array expected");Ce.set(at,Be),Be+=at.length}),Ce}class ae{clone(){return this._cloneInto()}}function Oe(ue){const Ce=at=>ue().update(pe(at)).digest(),Be=ue();return Ce.outputLen=Be.outputLen,Ce.blockLen=Be.blockLen,Ce.create=()=>ue(),Ce}function ce(ue=32){if(i&&"function"==typeof i.getRandomValues)return i.getRandomValues(new Uint8Array(ue));throw new Error("crypto.getRandomValues must be defined")}},2661:(o,s,r)=>{"use strict";function i(a,c){this.v=a,this.k=c}r.d(s,{A:()=>i})},3014:(o,s,r)=>{"use strict";function i(c,y,w,C,T,S,M){try{var O=c[S](M),L=O.value}catch(Z){return void w(Z)}O.done?y(L):Promise.resolve(L).then(C,T)}function a(c){return function(){var y=this,w=arguments;return new Promise(function(C,T){var S=c.apply(y,w);function M(L){i(S,C,T,M,O,"next",L)}function O(L){i(S,C,T,M,O,"throw",L)}M(void 0)})}}r.d(s,{A:()=>a})},5137:(o,s,r)=>{"use strict";r.d(s,{A:()=>a});var i=r(2661);function a(c){return new i.A(c,0)}},9129:(o,s,r)=>{"use strict";r.d(s,{A:()=>a});var i=r(2661);function a(y){return function(){return new c(y.apply(this,arguments))}}function c(y){var w,C;function T(M,O){try{var L=y[M](O),Z=L.value,q=Z instanceof i.A;Promise.resolve(q?Z.v:Z).then(function(re){if(q){var pe="return"===M?"return":"next";if(!Z.k||re.done)return T(pe,re);re=y[pe](re).value}S(L.done?"return":"normal",re)},function(re){T("throw",re)})}catch(re){S("throw",re)}}function S(M,O){switch(M){case"return":w.resolve({value:O,done:!0});break;case"throw":w.reject(O);break;default:w.resolve({value:O,done:!1})}(w=w.next)?T(w.key,w.arg):C=null}this._invoke=function(M,O){return new Promise(function(L,Z){var q={key:M,arg:O,resolve:L,reject:Z,next:null};C?C=C.next=q:(w=C=q,T(M,O))})},"function"!=typeof y.return&&(this.return=void 0)}c.prototype["function"==typeof Symbol&&Symbol.asyncIterator||"@@asyncIterator"]=function(){return this},c.prototype.next=function(y){return this._invoke("next",y)},c.prototype.throw=function(y){return this._invoke("throw",y)},c.prototype.return=function(y){return this._invoke("return",y)}},1635:(o,s,r)=>{"use strict";function Z(ze,$e,Ft,Ke){return new(Ft||(Ft=Promise))(function(it,Ot){function $t(st){try{Ee(Ke.next(st))}catch(Xt){Ot(Xt)}}function Te(st){try{Ee(Ke.throw(st))}catch(Xt){Ot(Xt)}}function Ee(st){st.done?it(st.value):function Ze(it){return it instanceof Ft?it:new Ft(function(Ot){Ot(it)})}(st.value).then($t,Te)}Ee((Ke=Ke.apply(ze,$e||[])).next())})}function xe(ze){return this instanceof xe?(this.v=ze,this):new xe(ze)}function De(ze,$e,Ft){if(!Symbol.asyncIterator)throw new TypeError("Symbol.asyncIterator is not defined.");var Ze,Ke=Ft.apply(ze,$e||[]),it=[];return Ze=Object.create(("function"==typeof AsyncIterator?AsyncIterator:Object).prototype),$t("next"),$t("throw"),$t("return",function Ot(Kt){return function(rt){return Promise.resolve(rt).then(Kt,Xt)}}),Ze[Symbol.asyncIterator]=function(){return this},Ze;function $t(Kt,rt){Ke[Kt]&&(Ze[Kt]=function(Vt){return new Promise(function(en,kn){it.push([Kt,Vt,en,kn])>1||Te(Kt,Vt)})},rt&&(Ze[Kt]=rt(Ze[Kt])))}function Te(Kt,rt){try{!function Ee(Kt){Kt.value instanceof xe?Promise.resolve(Kt.value.v).then(st,Xt):Mt(it[0][2],Kt)}(Ke[Kt](rt))}catch(Vt){Mt(it[0][3],Vt)}}function st(Kt){Te("next",Kt)}function Xt(Kt){Te("throw",Kt)}function Mt(Kt,rt){Kt(rt),it.shift(),it.length&&Te(it[0][0],it[0][1])}}function ue(ze){if(!Symbol.asyncIterator)throw new TypeError("Symbol.asyncIterator is not defined.");var Ft,$e=ze[Symbol.asyncIterator];return $e?$e.call(ze):(ze=function se(ze){var $e="function"==typeof Symbol&&Symbol.iterator,Ft=$e&&ze[$e],Ke=0;if(Ft)return Ft.call(ze);if(ze&&"number"==typeof ze.length)return{next:function(){return ze&&Ke>=ze.length&&(ze=void 0),{value:ze&&ze[Ke++],done:!ze}}};throw new TypeError($e?"Object is not iterable.":"Symbol.iterator is not defined.")}(ze),Ft={},Ke("next"),Ke("throw"),Ke("return"),Ft[Symbol.asyncIterator]=function(){return this},Ft);function Ke(it){Ft[it]=ze[it]&&function(Ot){return new Promise(function($t,Te){!function Ze(it,Ot,$t,Te){Promise.resolve(Te).then(function(Ee){it({value:Ee,done:$t})},Ot)}($t,Te,(Ot=ze[it](Ot)).done,Ot.value)})}}}r.d(s,{AQ:()=>De,N3:()=>xe,sH:()=>Z,xN:()=>ue}),"function"==typeof SuppressedError&&SuppressedError}},o=>{o(o.s=770)}]); \ No newline at end of file diff --git a/ngsw.json b/ngsw.json index 8a9de2a..ff08318 100644 --- a/ngsw.json +++ b/ngsw.json @@ -1,6 +1,6 @@ { "configVersion": 1, - "timestamp": 1732731099443, + "timestamp": 1732732441432, "index": "/index.html", "assetGroups": [], "dataGroups": [], diff --git a/runtime.4b8589ab227394d2.js b/runtime.20d23fb106aeceea.js similarity index 55% rename from runtime.4b8589ab227394d2.js rename to runtime.20d23fb106aeceea.js index 1966ebf..461da24 100644 --- a/runtime.4b8589ab227394d2.js +++ b/runtime.20d23fb106aeceea.js @@ -1 +1 @@ -(()=>{"use strict";var e,v={},g={};function r(e){var n=g[e];if(void 0!==n)return n.exports;var a=g[e]={id:e,loaded:!1,exports:{}};return v[e].call(a.exports,a,a.exports,r),a.loaded=!0,a.exports}r.m=v,e=[],r.O=(n,a,i,d)=>{if(!a){var t=1/0;for(f=0;f=d)&&Object.keys(r.O).every(p=>r.O[p](a[o]))?a.splice(o--,1):(u=!1,d0&&e[f-1][2]>d;f--)e[f]=e[f-1];e[f]=[a,i,d]},r.n=e=>{var n=e&&e.__esModule?()=>e.default:()=>e;return r.d(n,{a:n}),n},r.d=(e,n)=>{for(var a in n)r.o(n,a)&&!r.o(e,a)&&Object.defineProperty(e,a,{enumerable:!0,get:n[a]})},r.f={},r.e=e=>Promise.all(Object.keys(r.f).reduce((n,a)=>(r.f[a](e,n),n),[])),r.u=e=>(76===e?"common":e)+"."+{76:"eaa9a83df7bd1472",87:"89382f6778c57112",126:"882bbf93d79b0241",232:"e86c6a10c949ded0",256:"0e13c4fd2d85a687",371:"1350987134a35fcd",394:"513ca13c1ebf9f48",512:"21e2f0687bbf0a15",523:"1d564178fdfd679e",544:"8d04d0914a5c873b",556:"14e4bee993e6d7c2",664:"8a10de4594052b2f",767:"e79dfcaf8d423435",785:"20609070e643f838",836:"d0157dec65ae8b51",859:"5c6e13c9e52b4d5a",900:"abf9e3e186379a0b",907:"7487904cafe54d75",957:"5e3037fca5fc8f88"}[e]+".js",r.miniCssF=e=>{},r.o=(e,n)=>Object.prototype.hasOwnProperty.call(e,n),(()=>{var e={},n="angor:";r.l=(a,i,d,f)=>{if(e[a])e[a].push(i);else{var t,u;if(void 0!==d)for(var o=document.getElementsByTagName("script"),l=0;l{t.onerror=t.onload=null,clearTimeout(s);var h=e[a];if(delete e[a],t.parentNode&&t.parentNode.removeChild(t),h&&h.forEach(_=>_(p)),m)return m(p)},s=setTimeout(b.bind(null,void 0,{type:"timeout",target:t}),12e4);t.onerror=b.bind(null,t.onerror),t.onload=b.bind(null,t.onload),u&&document.head.appendChild(t)}}})(),r.r=e=>{typeof Symbol<"u"&&Symbol.toStringTag&&Object.defineProperty(e,Symbol.toStringTag,{value:"Module"}),Object.defineProperty(e,"__esModule",{value:!0})},r.nmd=e=>(e.paths=[],e.children||(e.children=[]),e),(()=>{var e;r.tt=()=>(void 0===e&&(e={createScriptURL:n=>n},typeof trustedTypes<"u"&&trustedTypes.createPolicy&&(e=trustedTypes.createPolicy("angular#bundler",e))),e)})(),r.tu=e=>r.tt().createScriptURL(e),r.p="",(()=>{var e={121:0};r.f.j=(i,d)=>{var f=r.o(e,i)?e[i]:void 0;if(0!==f)if(f)d.push(f[2]);else if(121!=i){var t=new Promise((c,b)=>f=e[i]=[c,b]);d.push(f[2]=t);var u=r.p+r.u(i),o=new Error;r.l(u,c=>{if(r.o(e,i)&&(0!==(f=e[i])&&(e[i]=void 0),f)){var b=c&&("load"===c.type?"missing":c.type),s=c&&c.target&&c.target.src;o.message="Loading chunk "+i+" failed.\n("+b+": "+s+")",o.name="ChunkLoadError",o.type=b,o.request=s,f[1](o)}},"chunk-"+i,i)}else e[i]=0},r.O.j=i=>0===e[i];var n=(i,d)=>{var o,l,[f,t,u]=d,c=0;if(f.some(s=>0!==e[s])){for(o in t)r.o(t,o)&&(r.m[o]=t[o]);if(u)var b=u(r)}for(i&&i(d);c{"use strict";var e,v={},g={};function r(e){var n=g[e];if(void 0!==n)return n.exports;var a=g[e]={id:e,loaded:!1,exports:{}};return v[e].call(a.exports,a,a.exports,r),a.loaded=!0,a.exports}r.m=v,e=[],r.O=(n,a,i,d)=>{if(!a){var t=1/0;for(f=0;f=d)&&Object.keys(r.O).every(p=>r.O[p](a[o]))?a.splice(o--,1):(l=!1,d0&&e[f-1][2]>d;f--)e[f]=e[f-1];e[f]=[a,i,d]},r.n=e=>{var n=e&&e.__esModule?()=>e.default:()=>e;return r.d(n,{a:n}),n},r.d=(e,n)=>{for(var a in n)r.o(n,a)&&!r.o(e,a)&&Object.defineProperty(e,a,{enumerable:!0,get:n[a]})},r.f={},r.e=e=>Promise.all(Object.keys(r.f).reduce((n,a)=>(r.f[a](e,n),n),[])),r.u=e=>(76===e?"common":e)+"."+{76:"eaa9a83df7bd1472",87:"89382f6778c57112",126:"882bbf93d79b0241",232:"e86c6a10c949ded0",256:"0e13c4fd2d85a687",371:"1350987134a35fcd",394:"76c49ed2cbb10995",512:"5c8e193aa51cd3ec",523:"1d564178fdfd679e",544:"eda92231287fa498",556:"14e4bee993e6d7c2",664:"8a10de4594052b2f",767:"e79dfcaf8d423435",785:"20609070e643f838",836:"d0157dec65ae8b51",859:"5c6e13c9e52b4d5a",900:"abf9e3e186379a0b",907:"7487904cafe54d75",957:"5e3037fca5fc8f88"}[e]+".js",r.miniCssF=e=>{},r.o=(e,n)=>Object.prototype.hasOwnProperty.call(e,n),(()=>{var e={},n="angor:";r.l=(a,i,d,f)=>{if(e[a])e[a].push(i);else{var t,l;if(void 0!==d)for(var o=document.getElementsByTagName("script"),c=0;c{t.onerror=t.onload=null,clearTimeout(s);var h=e[a];if(delete e[a],t.parentNode&&t.parentNode.removeChild(t),h&&h.forEach(_=>_(p)),m)return m(p)},s=setTimeout(u.bind(null,void 0,{type:"timeout",target:t}),12e4);t.onerror=u.bind(null,t.onerror),t.onload=u.bind(null,t.onload),l&&document.head.appendChild(t)}}})(),r.r=e=>{typeof Symbol<"u"&&Symbol.toStringTag&&Object.defineProperty(e,Symbol.toStringTag,{value:"Module"}),Object.defineProperty(e,"__esModule",{value:!0})},r.nmd=e=>(e.paths=[],e.children||(e.children=[]),e),(()=>{var e;r.tt=()=>(void 0===e&&(e={createScriptURL:n=>n},typeof trustedTypes<"u"&&trustedTypes.createPolicy&&(e=trustedTypes.createPolicy("angular#bundler",e))),e)})(),r.tu=e=>r.tt().createScriptURL(e),r.p="",(()=>{var e={121:0};r.f.j=(i,d)=>{var f=r.o(e,i)?e[i]:void 0;if(0!==f)if(f)d.push(f[2]);else if(121!=i){var t=new Promise((b,u)=>f=e[i]=[b,u]);d.push(f[2]=t);var l=r.p+r.u(i),o=new Error;r.l(l,b=>{if(r.o(e,i)&&(0!==(f=e[i])&&(e[i]=void 0),f)){var u=b&&("load"===b.type?"missing":b.type),s=b&&b.target&&b.target.src;o.message="Loading chunk "+i+" failed.\n("+u+": "+s+")",o.name="ChunkLoadError",o.type=u,o.request=s,f[1](o)}},"chunk-"+i,i)}else e[i]=0},r.O.j=i=>0===e[i];var n=(i,d)=>{var o,c,[f,t,l]=d,b=0;if(f.some(s=>0!==e[s])){for(o in t)r.o(t,o)&&(r.m[o]=t[o]);if(l)var u=l(r)}for(i&&i(d);b