1(self.webpackChunk_N_E=self.webpackChunk_N_E||[]).push([[2888],{27655:function(e,t,i){var n={"./ar/common":[51389,1111],"./ar/common.json":[51389,1111],"./ar/generate":[4225,4225],"./ar/generate.json":[4225,4225],"./ar/landing":[84931,4931],"./ar/landing.json":[84931,4931],"./ar/tools":[43981,3981],"./ar/tools.json":[43981,3981],"./ar/translation":[82410,2410],"./ar/translation.json":[82410,2410],"./cs/common":[38913,8913],"./cs/common.json":[38913,8913],"./cs/generate":[88047,8047],"./cs/generate.json":[88047,8047],"./cs/landing":[3655,3655],"./cs/landing.json":[3655,3655],"./cs/tools":[96762,6762],"./cs/tools.json":[96762,6762],"./cs/translation":[95470,5470],"./cs/translation.json":[95470,5470],"./de/common":[21545,1545],"./de/common.json":[21545,1545],"./de/generate":[75423,5423],"./de/generate.json":[75423,5423],"./de/landing":[79727,9727],"./de/landing.json":[79727,9727],"./de/tools":[11123,1123],"./de/tools.json":[11123,1123],"./de/translation":[30772,772],"./de/translation.json":[30772,772],"./el/common":[3319,3319],"./el/common.json":[3319,3319],"./el/generate":[5835,5835],"./el/generate.json":[5835,5835],"./el/landing":[85499,5499],"./el/landing.json":[85499,5499],"./el/tools":[57709,7709],"./el/tools.json":[57709,7709],"./el/translation":[38214,8214],"./el/translation.json":[38214,8214],"./en/common":[40464,464],"./en/common.json":[40464,464],"./en/generate":[55022,2252],"./en/generate.json":[55022,2252],"./en/landing":[39942,9942],"./en/landing.json":[39942,9942],"./en/tools":[55444,7293],"./en/tools.json":[55444,7293],"./en/translation":[87551,7551],"./en/translation.json":[87551,7551],"./es/common":[10357,357],"./es/common.json":[10357,357],"./es/generate":[67376,7376],"./es/generate.json":[67376,7376],"./es/landing":[94478,4478],"./es/landing.json":[94478,4478],"./es/tools":[38218,8218],"./es/tools.json":[38218,8218],"./es/translation":[31238,1238],"./es/translation.json":[31238,1238],"./et/common":[61646,1646],"./et/common.json":[61646,1646],"./et/generate":[54374,4374],"./et/generate.json":[54374,4374],"./et/landing":[83840,3840],"./et/landing.json":[83840,3840],"./et/tools":[58759,8759],"./et/tools.json":[58759,8759],"./et/translation":[81169,1169],"./et/translation.json":[81169,1169],"./fr/common":[45167,5167],"./fr/common.json":[45167,5167],"./fr/generate":[18752,8752],"./fr/generate.json":[18752,8752],"./fr/landing":[15921,5921],"./fr/landing.json":[15921,5921],"./fr/tools":[79771,9771],"./fr/tools.json":[79771,9771],"./fr/translation":[66207,6207],"./fr/translation.json":[66207,6207],"./id/common":[81610,1610],"./id/common.json":[81610,1610],"./id/generate":[15037,5037],"./id/generate.json":[15037,5037],"./id/landing":[38434,8858],"./id/landing.json":[38434,8858],"./id/tools":[96912,6912],"./id/tools.json":[96912,6912],"./id/translation":[74978,4978],"./id/translation.json":[74978,4978],"./it/common":[9486,9486],"./it/common.json":[9486,9486],"./it/generate":[35161,5161],"./it/generate.json":[35161,5161],"./it/landing":[34778,4778],"./it/landing.json":[34778,4778],"./it/tools":[20534,534],"./it/tools.json":[20534,534],"./it/translation":[16200,6200],"./it/translation.json":[16200,6200],"./ja/common":[20459,459],"./ja/common.json":[20459,459],"./ja/generate":[37902,7902],"./ja/generate.json":[37902,7902],"./ja/landing":[37855,7855],"./ja/landing.json":[37855,7855],"./ja/tools":[73154,3154],"./ja/tools.json":[73154,3154],"./ja/translation":[82820,2820],"./ja/translation.json":[82820,2820],"./ko/common":[95271,5271],"./ko/common.json":[95271,5271],"./ko/generate":[85008,8605],"./ko/generate.json":[85008,8605],"./ko/landing":[35889,5889],"./ko/landing.json":[35889,5889],"./ko/tools":[60825,825],"./ko/tools.json":[60825,825],"./ko/translation":[644,644],"./ko/translation.json":[644,644],"./nl/common":[1211,1211],"./nl/common.json":[1211,1211],"./nl/generate":[85325,5325],"./nl/generate.json":[85325,5325],"./nl/landing":[71166,1166],"./nl/landing.json":[71166,1166],"./nl/tools":[11171,1171],"./nl/tools.json":[11171,1171],"./nl/translation":[23137,3137],"./nl/translation.json":[23137,3137],"./pl/common":[45878,5878],"./pl/common.json":[45878,5878],"./pl/generate":[14407,4407],"./pl/generate.json":[14407,4407],"./pl/landing":[91754,1754],"./pl/landing.json":[91754,1754],"./pl/tools":[24078,4078],"./pl/tools.json":[24078,4078],"./pl/translation":[51825,1825],"./pl/translation.json":[51825,1825],"./pt/common":[41400,1400],"./pt/common.json":[41400,1400],"./pt/generate":[22666,2666],"./pt/generate.json":[22666,2666],"./pt/landing":[97074,7074],"./pt/landing.json":[97074,7074],"./pt/tools":[59705,9705],"./pt/tools.json":[59705,9705],"./pt/translation":[30575,575],"./pt/translation.json":[30575,575],"./ro/common":[4686,4686],"./ro/common.json":[4686,4686],"./ro/generate":[90656,656],"./ro/generate.json":[90656,656],"./ro/landing":[74925,4925],"./ro/landing.json":[74925,4925],"./ro/tools":[43357,3357],"./ro/tools.json":[43357,3357],"./ro/translation":[42595,2595],"./ro/translation.json":[42595,2595],"./ru/common":[77247,7247],"./ru/common.json":[77247,7247],"./ru/generate":[81940,1940],"./ru/generate.json":[81940,1940],"./ru/landing":[45900,5900],"./ru/landing.json":[45900,5900],"./ru/tools":[549,549],"./ru/tools.json":[549,549],"./ru/translation":[91089,1089],"./ru/translation.json":[91089,1089],"./sl/common":[52068,2068],"./sl/common.json":[52068,2068],"./sl/generate":[34172,4172],"./sl/generate.json":[34172,4172],"./sl/landing":[61682,1682],"./sl/landing.json":[61682,1682],"./sl/tools":[15578,5578],"./sl/tools.json":[15578,5578],"./sl/translation":[75912,5912],"./sl/translation.json":[75912,5912],"./sv/common":[56504,6504],"./sv/common.json":[56504,6504],"./sv/generate":[17335,7335],"./sv/generate.json":[17335,7335],"./sv/landing":[55519,5519],"./sv/landing.json":[55519,5519],"./sv/tools":[7724,7724],"./sv/tools.json":[7724,7724],"./sv/translation":[67171,7171],"./sv/translation.json":[67171,7171],"./tr/common":[72973,2973],"./tr/common.json":[72973,2973],"./tr/generate":[20620,620],"./tr/generate.json":[20620,620],"./tr/landing":[74092,4092],"./tr/landing.json":[74092,4092],"./tr/tools":[32627,2627],"./tr/tools.json":[32627,2627],"./tr/translation":[95501,5501],"./tr/translation.json":[95501,5501],"./vi/common":[79789,9789],"./vi/common.json":[79789,9789],"./vi/generate":[98540,8540],"./vi/generate.json":[98540,8540],"./vi/landing":[65790,5790],"./vi/landing.json":[65790,5790],"./vi/tools":[59324,9324],"./vi/tools.json":[59324,9324],"./vi/translation":[11007,1007],"./vi/translation.json":[11007,1007],"./zh/common":[66671,6671],"./zh/common.json":[66671,6671],"./zh/generate":[70282,1628],"./zh/generate.json":[70282,1628],"./zh/landing":[79093,9093],"./zh/landing.json":[79093,9093],"./zh/tools":[83488,3488],"./zh/tools.json":[83488,3488],"./zh/translation":[12834,2834],"./zh/translation.json":[12834,2834]};function r(e){if(!i.o(n,e))return Promise.resolve().then(function(){var t=Error("Cannot find module '"+e+"'");throw t.code="MODULE_NOT_FOUND",t});var t=n[e],r=t[0];return i.e(t[1]).then(function(){return i.t(r,19)})}r.keys=function(){return Object.keys(n)},r.id=27655,e.exports=r},15330:function(e,t,i){var n={"./ar/common.json":[51389,1111],"./ar/generate.json":[4225,4225],"./ar/landing.json":[84931,4931],"./ar/tools.json":[43981,3981],"./ar/translation.json":[82410,2410
1],"./cs/common.json":[38913,8913],"./cs/generate.json":[88047,8047],"./cs/landing.json":[3655,3655],"./cs/tools.json":[96762,6762],"./cs/translation.json":[95470,5470],"./de/common.json":[21545,1545],"./de/generate.json":[75423,5423],"./de/landing.json":[79727,9727],"./de/tools.json":[11123,1123],"./de/translation.json":[30772,772],"./el/common.json":[3319,3319],"./el/generate.json":[5835,5835],"./el/landing.json":[85499,5499],"./el/tools.json":[57709,7709],"./el/translation.json":[38214,8214],"./en/common.json":[40464,464],"./en/generate.json":[55022,2252],"./en/landing.json":[39942,9942],"./en/tools.json":[55444,7293],"./en/translation.json":[87551,7551],"./es/common.json":[10357,357],"./es/generate.json":[67376,7376],"./es/landing.json":[94478,4478],"./es/tools.json":[38218,8218],"./es/translation.json":[31238,1238],"./et/common.json":[61646,1646],"./et/generate.json":[54374,4374],"./et/landing.json":[83840,3840],"./et/tools.json":[58759,8759],"./et/translation.json":[81169,1169],"./fr/common.json":[45167,5167],"./fr/generate.json":[18752,8752],"./fr/landing.json":[15921,5921],"./fr/tools.json":[79771,9771],"./fr/translation.json":[66207,6207],"./id/common.json":[81610,1610],"./id/generate.json":[15037,5037],"./id/landing.json":[38434,8858],"./id/tools.json":[96912,6912],"./id/translation.json":[74978,4978],"./it/common.json":[9486,9486],"./it/generate.json":[35161,5161],"./it/landing.json":[34778,4778],"./it/tools.json":[20534,534],"./it/translation.json":[16200,6200],"./ja/common.json":[20459,459],"./ja/generate.json":[37902,7902],"./ja/landing.json":[37855,7855],"./ja/tools.json":[73154,3154],"./ja/translation.json":[82820,2820],"./ko/common.json":[95271,5271],"./ko/generate.json":[85008,8605],"./ko/landing.json":[35889,5889],"./ko/tools.json":[60825,825],"./ko/translation.json":[644,644],"./nl/common.json":[1211,1211],"./nl/generate.json":[85325,5325],"./nl/landing.json":[71166,1166],"./nl/tools.json":[11171,1171],"./nl/translation.json":[23137,3137],"./pl/common.json":[45878,5878],"./pl/generate.json":[14407,4407],"./pl/landing.json":[91754,1754],"./pl/tools.json":[24078,4078],"./pl/translation.json":[51825,1825],"./pt/common.json":[41400,1400],"./pt/generate.json":[22666,2666],"./pt/landing.json":[97074,7074],"./pt/tools.json":[59705,9705],"./pt/translation.json":[30575,575],"./ro/common.json":[4686,4686],"./ro/generate.json":[90656,656],"./ro/landing.json":[74925,4925],"./ro/tools.json":[43357,3357],"./ro/translation.json":[42595,2595],"./ru/common.json":[77247,7247],"./ru/generate.json":[81940,1940],"./ru/landing.json":[45900,5900],"./ru/tools.json":[549,549],"./ru/translation.json":[91089,1089],"./sl/common.json":[52068,2068],"./sl/generate.json":[34172,4172],"./sl/landing.json":[61682,1682],"./sl/tools.json":[15578,5578],"./sl/translation.json":[75912,5912],"./sv/common.json":[56504,6504],"./sv/generate.json":[17335,7335],"./sv/landing.json":[55519,5519],"./sv/tools.json":[7724,7724],"./sv/translation.json":[67171,7171],"./tr/common.json":[72973,2973],"./tr/generate.json":[20620,620],"./tr/landing.json":[74092,4092],"./tr/tools.json":[32627,2627],"./tr/translation.json":[95501,5501],"./vi/common.json":[79789,9789],"./vi/generate.json":[98540,8540],"./vi/landing.json":[65790,5790],"./vi/tools.json":[59324,9324],"./vi/translation.json":[11007,1007],"./zh/common.json":[66671,6671],"./zh/generate.json":[70282,1628],"./zh/landing.json":[79093,9093],"./zh/tools.json":[83488,3488],"./zh/translation.json":[12834,2834]};function r(e){if(!i.o(n,e))return Promise.resolve().then(function(){var t=Error("Cannot find module '"+e+"'");throw t.code="MODULE_NOT_FOUND",t});var t=n[e],r=t[0];return i.e(t[1]).then(function(){return i.t(r,19)})}r.keys=function(){return Object.keys(n)},r.id=15330,e.exports=r},76473:function(e,t,i){"use strict";i.d(t,{PB:function(){return v},lX:function(){return g}});var n=i(57242),r=i(33326),s=i.n(r);function o(){return(o=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var i=arguments[t];for(var n in i)Object.prototype.hasOwnProperty.call(i,n)&&(e[n]=i[n])}return e}).apply(this,arguments)}function a(e,t){if(null==e)return{};var i,n,r={},s=Object.keys(e);for(n=0;n<s.length;n++)i=s[n],t.indexOf(i)>=0||(r[i]=e[i]);return r}var l=["keyOverride"],c=["crossOrigin"],u={templateTitle:"",noindex:!1,nofollow:!1,norobots:!1,defaultOpenGra
1phImageWidth:0,defaultOpenGraphImageHeight:0,defaultOpenGraphVideoWidth:0,defaultOpenGraphVideoHeight:0},d=function(e,t,i){void 0===t&&(t=[]);var r=void 0===i?{}:i,s=r.defaultWidth,o=r.defaultHeight;return t.reduce(function(t,i,r){return t.push(n.createElement("meta",{key:"og:"+e+":0"+r,property:"og:"+e,content:i.url})),i.alt&&t.push(n.createElement("meta",{key:"og:"+e+":alt0"+r,property:"og:"+e+":alt",content:i.alt})),i.secureUrl&&t.push(n.createElement("meta",{key:"og:"+e+":secure_url0"+r,property:"og:"+e+":secure_url",content:i.secureUrl.toString()})),i.type&&t.push(n.createElement("meta",{key:"og:"+e+":type0"+r,property:"og:"+e+":type",content:i.type.toString()})),i.width?t.push(n.createElement("meta",{key:"og:"+e+":width0"+r,property:"og:"+e+":width",content:i.width.toString()})):s&&t.push(n.createElement("meta",{key:"og:"+e+":width0"+r,property:"og:"+e+":width",content:s.toString()})),i.height?t.push(n.createElement("meta",{key:"og:"+e+":height"+r,property:"og:"+e+":height",content:i.height.toString()})):o&&t.push(n.createElement("meta",{key:"og:"+e+":height"+r,property:"og:"+e+":height",content:o.toString()})),t},[])},h=function(e){var t,i,r,s,h,p=[];e.titleTemplate&&(u.templateTitle=e.titleTemplate);var g="";e.title?(g=e.title,u.templateTitle&&(g=u.templateTitle.replace(/%s/g,function(){return g}))):e.defaultTitle&&(g=e.defaultTitle),g&&p.push(n.createElement("title",{key:"title"},g));var v=void 0===e.noindex?u.noindex||e.dangerouslySetAllPagesToNoIndex:e.noindex,f=void 0===e.nofollow?u.nofollow||e.dangerouslySetAllPagesToNoFollow:e.nofollow,_=e.norobots||u.norobots,m="";if(e.robotsProps){var y=e.robotsProps,b=y.nosnippet,E=y.maxSnippet,w=y.maxImagePreview,S=y.maxVideoPreview,T=y.noarchive,I=y.noimageindex,k=y.notranslate,x=y.unavailableAfter;m=(b?",nosnippet":"")+(E?",max-snippet:"+E:"")+(w?",max-image-preview:"+w:"")+(T?",noarchive":"")+(x?",unavailable_after:"+x:"")+(I?",noimageindex":"")+(S?",max-video-preview:"+S:"")+(k?",notranslate":"")}if(e.norobots&&(u.norobots=!0),v||f?(e.dangerouslySetAllPagesToNoIndex&&(u.noindex=!0),e.dangerouslySetAllPagesToNoFollow&&(u.nofollow=!0),p.push(n.createElement("meta",{key:"robots",name:"robots",content:(v?"noindex":"index")+","+(f?"nofollow":"follow")+m}))):(!_||m)&&p.push(n.createElement("meta",{key:"robots",name:"robots",content:"index,follow"+m})),e.description&&p.push(n.createElement("meta",{key:"description",name:"description",content:e.description})),e.themeColor&&p.push(n.createElement("meta",{key:"theme-color",name:"theme-color",content:e.themeColor})),e.mobileAlternate&&p.push(n.createElement("link",{rel:"alternate",key:"mobileAlternate",media:e.mobileAlternate.media,href:e.mobileAlternate.href})),e.languageAlternates&&e.languageAlternates.length>0&&e.languageAlternates.forEach(function(e){p.push(n.createElement("link",{rel:"alternate",key:"languageAlternate-"+e.hrefLang,hrefLang:e.hrefLang,href:e.href}))}),e.twitter&&(e.twitter.cardType&&p.push(n.createElement("meta",{key:"twitter:card",name:"twitter:card",content:e.twitter.cardType})),e.twitter.site&&p.push(n.createElement("meta",{key:"twitter:site",name:"twitter:site",content:e.twitter.site})),e.twitter.handle&&p.push(n.createElement("meta",{key:"twitter:creator",name:"twitter:creator",content:e.twitter.handle}))),e.facebook&&e.facebook.appId&&p.push(n.createElement("meta",{key:"fb:app_id",property:"fb:app_id",content:e.facebook.appId})),(null!=(t=e.openGraph)&&t.title||g)&&p.push(n.createElement("meta",{key:"og:title",property:"og:title",content:(null==(s=e.openGraph)?void 0:s.title)||g})),(null!=(i=e.openGraph)&&i.description||e.description)&&p.push(n.createElement("meta",{key:"og:description",property:"og:description",content:(null==(h=e.openGraph)?void 0:h.description)||e.description})),e.openGraph){if((e.openGraph.url||e.canonical)&&p.push(n.createElement("meta",{key:"og:url",property:"og:url",content:e.openGraph.url||e.canonical})),e.openGraph.type){var O=e.openGraph.type.toLowerCase();p.push(n.createElement("meta",{key:"og:type",property:"og:type",content:O})),"profile"===O&&e.openGraph.profile?(e.openGraph.profile.firstName&&p.push(n.createElement("meta",{key:"profile:first_name",property:"profile:first_name",content:e.openGraph.profile.firstName})),e.openGraph.profile.lastName&&p.push(n.createElement("meta",{key:"profile:last_name",property:"profile:last_name",content:e.openGraph.profile.lastName})),e.openGraph.profile.username&&p.push(n.createElement("meta",{key:"profile:username",property:"profile:username",content:e.openGraph.profile.username})),e.openGraph.profile.gender&&p.push(n.createElement("meta",{key:"profile:gender",property:"profile:gender",content:e.openGraph.profile.gender}))):"book"===O&&e.openGraph.book?(e.openGraph.book.authors&&e.openGraph.book.authors.length&&e.openGraph.book.authors.forEac
1h(function(e,t){p.push(n.createElement("meta",{key:"book:author:0"+t,property:"book:author",content:e}))}),e.openGraph.book.isbn&&p.push(n.createElement("meta",{key:"book:isbn",property:"book:isbn",content:e.openGraph.book.isbn})),e.openGraph.book.releaseDate&&p.push(n.createElement("meta",{key:"book:release_date",property:"book:release_date",content:e.openGraph.book.releaseDate})),e.openGraph.book.tags&&e.openGraph.book.tags.length&&e.openGraph.book.tags.forEach(function(e,t){p.push(n.createElement("meta",{key:"book:tag:0"+t,property:"book:tag",content:e}))})):"article"===O&&e.openGraph.article?(e.openGraph.article.publishedTime&&p.push(n.createElement("meta",{key:"article:published_time",property:"article:published_time",content:e.openGraph.article.publishedTime})),e.openGraph.article.modifiedTime&&p.push(n.createElement("meta",{key:"article:modified_time",property:"article:modified_time",content:e.openGraph.article.modifiedTime})),e.openGraph.article.expirationTime&&p.push(n.createElement("meta",{key:"article:expiration_time",property:"article:expiration_time",content:e.openGraph.article.expirationTime})),e.openGraph.article.authors&&e.openGraph.article.authors.length&&e.openGraph.article.authors.forEach(function(e,t){p.push(n.createElement("meta",{key:"article:author:0"+t,property:"article:author",content:e}))}),e.openGraph.article.section&&p.push(n.createElement("meta",{key:"article:section",property:"article:section",content:e.openGraph.article.section})),e.openGraph.article.tags&&e.openGraph.article.tags.length&&e.openGraph.article.tags.forEach(function(e,t){p.push(n.createElement("meta",{key:"article:tag:0"+t,property:"article:tag",content:e}))})):("video.movie"===O||"video.episode"===O||"video.tv_show"===O||"video.other"===O)&&e.openGraph.video&&(e.openGraph.video.actors&&e.openGraph.video.actors.length&&e.openGraph.video.actors.forEach(function(e,t){e.profile&&p.push(n.createElement("meta",{key:"video:actor:0"+t,property:"video:actor",content:e.profile})),e.role&&p.push(n.createElement("meta",{key:"video:actor:role:0"+t,property:"video:actor:role",content:e.role}))}),e.openGraph.video.directors&&e.openGraph.video.directors.length&&e.openGraph.video.directors.forEach(function(e,t){p.push(n.createElement("meta",{key:"video:director:0"+t,property:"video:director",content:e}))}),e.openGraph.video.writers&&e.openGraph.video.writers.length&&e.openGraph.video.writers.forEach(function(e,t){p.push(n.createElement("meta",{key:"video:writer:0"+t,property:"video:writer",content:e}))}),e.openGraph.video.duration&&p.push(n.createElement("meta",{key:"video:duration",property:"video:duration",content:e.openGraph.video.duration.toString()})),e.openGraph.video.releaseDate&&p.push(n.createElement("meta",{key:"video:release_date",property:"video:release_date",content:e.openGraph.video.releaseDate})),e.openGraph.video.tags&&e.openGraph.video.tags.length&&e.openGraph.video.tags.forEac
1h(function(e,t){p.push(n.createElement("meta",{key:"video:tag:0"+t,property:"video:tag",content:e}))}),e.openGraph.video.series&&p.push(n.createElement("meta",{key:"video:series",property:"video:series",content:e.openGraph.video.series})))}e.defaultOpenGraphImageWidth&&(u.defaultOpenGraphImageWidth=e.defaultOpenGraphImageWidth),e.defaultOpenGraphImageHeight&&(u.defaultOpenGraphImageHeight=e.defaultOpenGraphImageHeight),e.openGraph.images&&e.openGraph.images.length&&p.push.apply(p,d("image",e.openGraph.images,{defaultWidth:u.defaultOpenGraphImageWidth,defaultHeight:u.defaultOpenGraphImageHeight})),e.defaultOpenGraphVideoWidth&&(u.defaultOpenGraphVideoWidth=e.defaultOpenGraphVideoWidth),e.defaultOpenGraphVideoHeight&&(u.defaultOpenGraphVideoHeight=e.defaultOpenGraphVideoHeight),e.openGraph.videos&&e.openGraph.videos.length&&p.push.apply(p,d("video",e.openGraph.videos,{defaultWidth:u.defaultOpenGraphVideoWidth,defaultHeight:u.defaultOpenGraphVideoHeight})),e.openGraph.audio&&p.push.apply(p,d("audio",e.openGraph.audio)),e.openGraph.locale&&p.push(n.createElement("meta",{key:"og:locale",property:"og:locale",content:e.openGraph.locale})),(e.openGraph.siteName||e.openGraph.site_name)&&p.push(n.createElement("meta",{key:"og:site_name",property:"og:site_name",content:e.openGraph.siteName||e.openGraph.site_name}))}return e.canonical&&p.push(n.createElement("link",{rel:"canonical",href:e.canonical,key:"canonical"})),e.additionalMetaTags&&e.additionalMetaTags.length>0&&e.additionalMetaTags.forEach(function(e){var t,i,r=e.keyOverride,s=a(e,l);p.push(n.createElement("meta",o({key:"meta:"+(null!=(t=null!=(i=null!=r?r:s.name)?i:s.property)?t:s.httpEquiv)},s)))}),null!=(r=e.additionalLinkTags)&&r.length&&e.additionalLinkTags.forEach(function(e){var t,i=e.crossOrigin,r=a(e,c);p.push(n.createElement("link",o({key:"link"+(null!=(t=r.keyOverride)?t:r.href)+r.rel},r,{crossOrigin:"anonymous"===i||"use-credentials"===i||""===i?i:void 0})))}),p},p=function(e){return n.createElement(s(),null,h(e))},g=function(e){var t=e.title,i=e.titleTemplate,r=e.defaultTitle,s=e.themeColor,o=e.dangerouslySetAllPagesToNoIndex,a=e.dangerouslySetAllPagesToNoFollow,l=e.description,c=e.canonical,u=e.facebook,d=e.openGraph,h=e.additionalMetaTags,g=e.twitter,v=e.defaultOpenGraphImageWidth,f=e.defaultOpenGraphImageHeight,_=e.defaultOpenGraphVideoWidth,m=e.defaultOpenGraphVideoHeight,y=e.mobileAlternate,b=e.languageAlternates,E=e.additionalLinkTags,w=e.robotsProps,S=e.norobots;return n.createElement(p,{title:t,titleTemplate:i,defaultTitle:r,themeColor:s,dangerouslySetAllPagesToNoIndex:void 0!==o&&o,dangerouslySetAllPagesToNoFollow:void 0!==a&&a,description:l,canonical:c,facebook:u,openGraph:d,additionalMetaTags:h,twitter:g,defaultOpenGraphImageWidth:v,defaultOpenGraphImageHeight:f,defaultOpenGraphVideoWidth:_,defaultOpenGraphVideoHeight:m,mobileAlternate:y,languageAlternates:b,additionalLinkTags:E,robotsProps:w,norobots:S})},v=function(e){var t=e.title,i=e.themeColor,r=e.noindex,s=e.nofollow,o=e.robotsProps,a=e.description,l=e.canonical,c=e.openGraph,u=e.facebook,d=e.twitter,h=e.additionalMetaTags,g=e.titleTemplate,v=e.defaultTitle,f=e.mobileAlternate,_=e.languageAlternates,m=e.additionalLinkTags;return n.createElement(n.Fragment,null,n.createElement(p,{title:t,themeColor:i,noindex:r,nofollow:s,robotsProps:o,description:a,canonical:l,facebook:u,openGraph:c,additionalMetaTags:h,twitter:d,titleTemplate:g,defaultTitle:v,mobileAlternate:f,languageAlternates:_,additionalLinkTags:m}))};RegExp("["+Object.keys(Object.freeze({"&":"&","<":"<",">":">",'"':""","'":"'"})).join("")+"]","g")},12380:function(e,t,i){"use strict";var n,r=i(57242);"function"==typeof r.createContext&&(n=(0,r.createContext)({t:function(e){return Array.isArray(e)?e[0]:e},lang:""})),t.Z=n},76379:function(e,t,i){"use strict";i.d(t,{Z:function(){return r}});var n=function(){return(n=Object.assign||function(e){for(var t,i=1,n=arguments.length;i<n;i++)for(var r in t=arguments[i])Object.prototype.hasOwnProperty.call(t,r)&&(e[r]=t[r]);return e}).apply(this,arguments)};function r(e){var t=e.config,i=e.allNamespaces,r=e.pluralRules,l=e.lang,c=t.logger,u=void 0===c?a:c,d=t.allowEmptyStrings,h=void 0===d||d,p=function(e,i){return Array.isArray(e)?e.map(function(e){return p(e,i)}):e instanceof Object?function e(t){var i=t.obj,n=t.query,r=t.config,s=t.lang;
1return n&&0!==Object.keys(n).length&&Object.keys(i).forEach(function(t){i[t]instanceof Object&&e({obj:i[t],query:n,config:r,lang:s}),"string"==typeof i[t]&&(i[t]=o({text:i[t],query:n,config:r,lang:s}))}),i}({obj:e,query:i,config:t,lang:l}):o({text:e,query:i,config:t,lang:l})},g=function(e,o,a){void 0===e&&(e="");var l,c=Array.isArray(e)?e[0]:e,d=t.nsSeparator,v=t.loggerEnvironment,f=void 0===v?"browser":v,_=function(e,t){if(!t)return{i18nKey:e};var i=e.indexOf(t);return i<0?{i18nKey:e}:{namespace:e.slice(0,i),i18nKey:e.slice(i+t.length)}}(c,void 0===d?":":d),m=_.i18nKey,y=_.namespace,b=void 0===y?null!==(l=null==a?void 0:a.ns)&&void 0!==l?l:t.defaultNS:y,E=b&&i[b]||{},w=function(e,t,i,n,r){if(!r||"number"!=typeof r.count)return i;var o="".concat(i,"_").concat(r.count);if(void 0!==s(t,o,n))return o;var a="".concat(i,"_").concat(e.select(r.count));if(void 0!==s(t,a,n))return a;var l="".concat(i,".").concat(r.count);if(void 0!==s(t,l,n))return l;var c="".concat(i,".").concat(e.select(r.count));return void 0!==s(t,c,n)?c:i}(r,E,m,t,o),S=s(E,w,t,a),T="object"==typeof S?JSON.parse(JSON.stringify(S)):S,I=void 0===T||"object"==typeof T&&!Object.keys(T).length||""===T&&!h,k="string"==typeof(null==a?void 0:a.fallback)?[a.fallback]:(null==a?void 0:a.fallback)||[];if(I&&("both"===f||f===("undefined"==typeof window?"node":"browser"))&&u({namespace:b,i18nKey:m}),I&&Array.isArray(k)&&k.length){var x=k[0],O=k.slice(1);if("string"==typeof x)return g(x,o,n(n({},a),{fallback:O}))}return I&&a&&a.hasOwnProperty("default")&&!(null==k?void 0:k.length)?a.default?p(a.default,o):a.default:I?c:p(T,o)};return g}function s(e,t,i,n){void 0===t&&(t=""),void 0===n&&(n={returnObjects:!1});var r=(i||{}).keySeparator,s=void 0===r?".":r,o=s?t.split(s):[t];if(t===s&&n.returnObjects)return e;var a=o.reduce(function(e,t){if("string"==typeof e)return{};var i=e[t];return i||("string"==typeof i?i:{})},e);if("string"==typeof a||a instanceof Object&&n.returnObjects)return a}function o(e){var t=e.text,i=e.query,n=e.config,r=e.lang;if(!t||!i)return t||"";var s=function(e){return e.replace(/[-\/\\^$*+?.()|[\]{}]/g,"\\$&")},o=n.interpolation||{},a=o.format,l=void 0===a?null:a,c=o.prefix,u=void 0===c?"{{":c,d=o.suffix,h=void 0===d?"}}":d,p=""===h?"":"(?:[\\s,]+([\\w-]*))?\\s*".concat(s(h));return Object.keys(i).reduce(function(e,t){var n=RegExp("".concat(s(u),"\\s*").concat(t).concat(p),"gm");return e.replace(n,function(e,n){return n&&l?l(i[t],n,r):i[t]})},t)}function a(e){e.namespace,e.i18nKey}},5724:function(e,t,i){"use strict";i.d(t,{Z:function(){return c}});var n=i(57242),r=function(){return(r=Object.assign||function(e){for(var t,i=1,n=arguments.length;i<n;i++)for(var r in t=arguments[i])Object.prototype.hasOwnProperty.call(t,r)&&(e[r]=t[r]);return e}).apply(this,arguments)};function s(e,t){return"string"!=typeof t?e:function(i,n,s){return e(i,n,r({ns:t},s))}}var o=i(12380),a=i(76379),l=function(){return(l=Object.assign||function(e){for(var t,i=1,n=arguments.length;i<n;i++)for(var r in t=arguments[i])Object.prototype.hasOwnProperty.call(t,r)&&(e[r]=t[r]);return e}).apply(this,arguments)};function c(e){var t=globalThis.__NEXT_TRANSLATE__;return((null==t?void 0:t.config)?function(e){var t,i=null!==(t=globalThis.__NEXT_TRANSLATE__)&&void 0!==t?t:{},n=i.lang,r=i.namespaces,o=i.config,l=o.localesToIgnore||["default"],c=!n||l.includes(n);return{t:s((0,a.Z)({config:o,allNamespaces:r,pluralRules:new Intl.PluralRules(c?void 0:n),lang:n}),e),lang:n}}:function(e){var t=(0,n.useContext)(o.Z);return(0,n.useMemo)(function(){return l(l({},t),{t:s(t.t,e)})},[t,e])})(e)}},75409:function(e,t,i){"use strict";var n,r;e.exports=(null==(n=i.g.process)?void 0:n.env)&&"object"==typeof(null==(r=i.g.process)?void 0:r.env)?i.g.process:i(40863)},40863:function(e){!function(){var t={229:function(e){var t,i,n,r=e.exports={};function s(){throw Error("setTimeout has not been defined")}function o(){throw Error("clearTimeout has not been defined")}function a(e){if(t===setTimeout)return setTimeout(e,0);if((t===s||!t)&&setTimeout)return t=setTimeout,setTimeout(e,0);try{return t(e,0)}catch(i){try{return t.call(null,e,0)}catch(i){return t.call(this,e,0)}}}!function(){try{t="function"==typeof setTimeout?setTimeout:s}
1catch(e){t=s}try{i="function"==typeof clearTimeout?clearTimeout:o}catch(e){i=o}}();var l=[],c=!1,u=-1;function d(){c&&n&&(c=!1,n.length?l=n.concat(l):u=-1,l.length&&h())}function h(){if(!c){var e=a(d);c=!0;for(var t=l.length;t;){for(n=l,l=[];++u<t;)n&&n[u].run();u=-1,t=l.length}n=null,c=!1,function(e){if(i===clearTimeout)return clearTimeout(e);if((i===o||!i)&&clearTimeout)return i=clearTimeout,clearTimeout(e);try{i(e)}catch(t){try{return i.call(null,e)}catch(t){return i.call(this,e)}}}(e)}}function p(e,t){this.fun=e,this.array=t}function g(){}r.nextTick=function(e){var t=Array(arguments.length-1);if(arguments.length>1)for(var i=1;i<arguments.length;i++)t[i-1]=arguments[i];l.push(new p(e,t)),1!==l.length||c||a(h)},p.prototype.run=function(){this.fun.apply(null,this.array)},r.title="browser",r.browser=!0,r.env={},r.argv=[],r.version="",r.versions={},r.on=g,r.addListener=g,r.once=g,r.off=g,r.removeListener=g,r.removeAllListeners=g,r.emit=g,r.prependListener=g,r.prependOnceListener=g,r.listeners=function(e){return[]},r.binding=function(e){throw Error("process.binding is not supported")},r.cwd=function(){return"/"},r.chdir=function(e){throw Error("process.chdir is not supported")},r.umask=function(){return 0}}},i={};function n(e){var r=i[e];if(void 0!==r)return r.exports;var s=i[e]={exports:{}},o=!0;try{t[e](s,s.exports,n),o=!1}finally{o&&delete i[e]}return s.exports}n.ab="//";var r=n(229);e.exports=r}()},33326:function(e,t,i){e.exports=i(10873)},5762:function(e,t,i){e.exports=i(92081)},68725:function(e,t,i){e.exports=i(47512)},38867:function(e,t,i){"use strict";i.d(t,{ZP:function(){return sq}});var n="undefined"!=typeof window?window:void 0,r="undefined"!=typeof globalThis?globalThis:n;"undefined"==typeof self&&(r.self=r),"undefined"==typeof File&&(r.File=function(){});var s=null==r?void 0:r.navigator,o=null==r?void 0:r.document,a=null==r?void 0:r.location,l=null==r?void 0:r.fetch,c=null!=r&&r.XMLHttpRequest&&"withCredentials"in new r.XMLHttpRequest?r.XMLHttpRequest:void 0,u=null==r?void 0:r.AbortController,d=null==r?void 0:r.CompressionStream,h=null==s?void 0:s.userAgent,p=null!=n?n:{},g="1.368.2",v={DEBUG:!1,LIB_VERSION:g,LIB_NAME:"web",JS_SDK_VERSION:g};function f(e,t,i,n,r,s,o){try{var a=e[s](o),l=a.value}catch(e){return void i(e)}a.done?t(l):Promise.resolve(l).then(n,r)}function _(e){return function(){var t=this,i=arguments;return new Promise(function(n,r){var s=e.apply(t,i);function o(e){f(s,n,r,o,a,"next",e)}function a(e){f(s,n,r,o,a,"throw",e)}o(void 0)})}}function m(){return(m=Object.assign?Object.assign.bind():function(e){for(var t=1;arguments.length>t;t++){var i=arguments[t];for(var n in i)({}).hasOwnProperty.call(i,n)&&(e[n]=i[n])}return e}).apply(null,arguments)}function y(e,t){if(null==e)return{};var i={};for(var n in e)if(({}).hasOwnProperty.call(e,n)){if(-1!==t.indexOf(n))continue;i[n]=e[n]}return i}function b(){return(b=_(function*(e,t,i){void 0===t&&(t=!0);try{var n=new Blob([e],{type:"text/plain"}).stream().pipeThrough(new CompressionStream("gzip"));return yield new Response(n).blob()}catch(e){if(null!=i&&i.rethrow)throw e;return t&&console.error("Failed to gzip compress data",e),null}})).apply(this,arguments)}var E=["$snapshot","$pageview","$pageleave","$set","survey dismissed","survey sent","survey shown","$identify","$groupidentify","$create_alias","$$client_ingestion_warning","$web_experiment_applied","$feature_enrollment_update","$feature_flag_called"],w=["amazonbot","amazonproductbot","app.hypefactors.com","applebot","archive.org_bot","awariobot","backlinksextendedbot","baiduspider","bingbot","bingpreview","chrome-lighthouse","dataforseobot","deepscan","duckduckbot","facebookexternal","facebookcatalog","http://yandex.com/bots","hubspot","ia_archiver","leikibot","linkedinbot","meta-externalagent","mj12bot","msnbot","nessus","petalbot","pinterest","prerender","rogerbot","screaming frog","sebot-wa","sitebulb","slackbot","slurp","trendictionbot","turnitin","twitterbot","vercel-screenshot","vercelbot","yahoo! slurp","yandexbot","zoombot","bot.htm","bot.php","(bot;","bot/","crawler","ahrefsbot","ahrefssiteaudit","semrushbot","siteauditbot","splitsignalbot","gptbot","oai-searchbot","chatgpt-user","perplexitybot","better uptime bot","sentryuptimebot","uptimerobot","headlesschrome","cypress","google-hoteladsverifier","adsbot-google","apis-google","duplexweb-google","feedfetcher-google","google favicon","google web preview","google-read-aloud","googlebot","googleother","google-cloudvertexbot","googleweblight","mediapartners-google","storebot-google","google-inspectiontool","bytespider"],S=function(e,t){if(void 0===t&&(t=[]),!e)return!1;var i=e.toLowerCase();return w.concat(t).some(e=>{var t=e.toLowerCase();return -1!==i.indexOf(t)})};function T(e,t){return -1!==e.indexOf(t)}var I=function(e){return e.trim()},k=function(e){return e.replace(/^\$/,"")},x=Object.prototype,O=x.hasOwnProperty,P=x.toString,R=Array.isArray||function(e){return"[object Array]"===P.call(e)},A=e=>"function"==typeof e,C=e=>e===Object(e)&&!R(e),L=e=>{if(C(e)){for(var t in e)if(O.call(e,t))return!1;return!0}return!1},j=e=>void 0===e,N=e=>"[object String]"==P.call(e),F=e=>N(e)&&0===e.trim().length,M=e=>null===e,$=e=>j(e)||M(e),D=e=>"[object Number]"==P.call(e)&&e==e,G=e=>D(e)&&e>0,U=e=>"[object Boolean]"===P.call(e),H=e=>e instanceof FormData,W=e=>T(E,e);function q(e){return null===e||"object"!=typeof e}function B(e,t){return({}).toString.call(e)==="[object "+t+"]"}function V(e){return"undefined"!=typeof Event&&function(e,t){try{return e instanceof t}catch(e){return!1}}(e,Event)}var z=[!0,"true",1,"1","yes"],Y=e=>
1T(z,e),X=[!1,"false",0,"0","no"];function K(e,t,i,n,r){return t>i&&(n.warn("min cannot be greater than max."),t=i),D(e)?e>i?(n.warn(" cannot be greater than max: "+i+". Using max value instead."),i):t>e?(n.warn(" cannot be less than min: "+t+". Using min value instead."),t):e:(n.warn(" must be a number. using max or fallback. max: "+i+", fallback: "+r),K(r||i,t,i,n))}class J{constructor(e){this.Pt={},this.Dt=e.Dt,this.jt=K(e.bucketSize,0,100,e.qt),this.$t=K(e.refillRate,0,this.jt,e.qt),this.Vt=K(e.refillInterval,0,864e5,e.qt)}Ht(e,t){var i=Math.floor((t-e.lastAccess)/this.Vt);i>0&&(e.tokens=Math.min(e.tokens+i*this.$t,this.jt),e.lastAccess=e.lastAccess+i*this.Vt)}consumeRateLimit(e){var t,i=Date.now(),n=String(e),r=this.Pt[n];return r?this.Ht(r,i):this.Pt[n]=r={tokens:this.jt,lastAccess:i},0===r.tokens||(r.tokens--,0===r.tokens&&(null==(t=this.Dt)||t.call(this,e)),0===r.tokens)}stop(){this.Pt={}}}var Z,Q,ee,et="Mobile",ei="Android",en="Tablet",er=ei+" "+en,es="iPad",eo="Apple",ea=eo+" Watch",el="Safari",ec="BlackBerry",eu="Samsung",ed=eu+"Browser",eh=eu+" Internet",ep="Chrome",eg=ep+" OS",ev=ep+" iOS",ef="Internet Explorer",e_=ef+" "+et,em="Opera",ey=em+" Mini",eb="Edge",eE="Microsoft "+eb,ew="Firefox",eS=ew+" iOS",eT="Nintendo",eI="PlayStation",ek="Xbox",ex=ei+" "+et,eO=et+" "+el,eP="Windows",eR=eP+" Phone",eA="Nokia",eC="Ouya",eL="Generic",ej=eL+" "+et.toLowerCase(),eN=eL+" "+en.toLowerCase(),eF="Konqueror",eM="(\\d+(\\.\\d+)?)",e$=RegExp("Version/"+eM),eD=RegExp(ek,"i"),eG=RegExp(eI+" \\w+","i"),eU=RegExp(eT+" \\w+","i"),eH=RegExp(ec+"|PlayBook|BB10","i"),eW={"NT3.51":"NT 3.11","NT4.0":"NT 4.0","5.0":"2000",5.1:"XP",5.2:"XP","6.0":"Vista",6.1:"7",6.2:"8",6.3:"8.1",6.4:"10","10.0":"10"},eq=function(e,t){var i;return t=t||"",T(e," OPR/")&&T(e,"Mini")?ey:T(e," OPR/")?em:eH.test(e)?ec:T(e,"IE"+et)||T(e,"WPDesktop")?e_:T(e,ed)?eh:T(e,eb)||T(e,"Edg/")?eE:T(e,"FBIOS")?"Facebook "+et:T(e,"UCWEB")||T(e,"UCBrowser")?"UC Browser":T(e,"CriOS")?ev:T(e,"CrMo")||T(e,ep)?ep:T(e,ei)&&T(e,el)?ex:T(e,"FxiOS")?eS:T(e.toLowerCase(),eF.toLowerCase())?eF:(i=t)&&T(i,eo)||T(e,el)&&!T(e,ep)&&!T(e,ei)?T(e,et)?eO:el:T(e,ew)?ew:T(e,"MSIE")||T(e,"Trident/")?ef:T(e,"Gecko")?ew:""},eB={[e_]:[RegExp("rv:"+eM)],[eE]:[RegExp(eb+"?\\/"+eM)],[ep]:[RegExp("("+ep+"|CrMo)\\/"+eM)],[ev]:[RegExp("CriOS\\/"+eM)],"UC Browser":[RegExp("(UCBrowser|UCWEB)\\/"+eM)],[el]:[e$],[eO]:[e$],[em]:[RegExp("(Opera|OPR)\\/"+eM)],[ew]:[RegExp(ew+"\\/"+eM)],[eS]:[RegExp("FxiOS\\/"+eM)],[eF]:[RegExp("Konqueror[:/]?"+eM,"i")],[ec]:[RegExp(ec+" "+eM),e$],[ex]:[RegExp("android\\s"+eM,"i")],[eh]:[RegExp(ed+"\\/"+eM)],[ef]:[RegExp("(rv:|MSIE )"+eM)],Mozilla:[RegExp("rv:"+eM)]},eV=function(e,t){var i=eB[eq(e,t)];if(j(i))return null;for(var n=0;i.length>n;n++){var r=e.match(i[n]);if(r)return parseFloat(r[r.length-2])}return null},ez=[[RegExp(ek+"; "+ek+" (.*?)[);]","i"),e=>[ek,e&&e[1]||""]],[RegExp(eT,"i"),[eT,""]],[RegExp(eI,"i"),[eI,""]],[eH,[ec,""]],[RegExp(eP,"i"),(e,t)=>{if(/Phone/.test(t)||/WPDesktop/.test(t))return[eR,""];if(new RegExp(et).test(t)&&!/IEMobile\b/.test(t))return[eP+" "+et,""];var i=/Windows NT ([0-9.]+)/i.exec(t);if(i&&i[1]){var n=eW[i[1]]||"";return/arm/i.test(t)&&(n="RT"),[eP,n]}return[eP,""]}],[/((iPhone|iPad|iPod).*?OS (\d+)_(\d+)_?(\d+)?|iPhone)/,e=>e&&e[3]?["iOS",[e[3],e[4],e[5]||"0"].join(".")]:["iOS",""]],[/(watch.*\/(\d+\.\d+\.\d+)|watch os,(\d+\.\d+),)/i,e=>{var t="";return e&&e.length>=3&&(t=j(e[2])?e[3]:e[2]),["watchOS",t]}],[RegExp("("+ei+" (\\d+)\\.(\\d+)\\.?(\\d+)?|"+ei+")","i"),e=>e&&e[2]?[ei,[e[2],e[3],e[4]||"0"].join(".")]:[ei,""]],[/Mac OS X (\d+)[_.](\d+)[_.]?(\d+)?/i,e=>{var t=["Mac OS X",""];return e&&e[1]&&(t[1]=[e[1],e[2],e[3]||"0"].join(".")),t}],[/Mac/i,["Mac OS X",""]],[/CrOS/,[eg,""]],[/Linux|debian/i,["Linux",""]]],eY=function(e){return eU.test(e)?eT:eG.test(e)?eI:eD.test(e)?ek:RegExp(eC,"i").test(e)?eC:RegExp("("+eR+"|WPDesktop)","i").test(e)?eR:/iPad/.test(e)?es:/iPod/.test(e)?"iPod Touch":/iPhone/.test(e)?"iPhone":/(watch)(?: ?os[,/]|\d,\d\/)[\d.]+/i.test(e)?ea:eH.test(e)?ec:/(kobo)\s(ereader|touch)/i.test(e)?"Kobo":RegExp(eA,"i").test(e)?eA:/(kf[a-z]{2}wi|aeo[c-r]{2})( bui|\))/i.test(e)||/(kf[a-z]+)( bui|\)).+silk\//i.test(e)?"Kindle Fire":/(Android|ZTE)/i.test(e)?new RegExp(et).test(e)&&!/(9138B|TB782B|Nexus [97]|pixel c|HUAWEISHT|BTV|noble nook|smart ultra 6)/i.test(e)||/pixel[\daxl ]{1,6}/i.test(e)&&!/pixel c/i.test(e)||/(huaweimed-al00|tah-|APA|SM-G92|i980|zte|U304AA)/i.test(e)||/lmy47v/i.test(e)&&!/QTAQZ3/i.test(e)?ei:er:RegExp("(pda|"+et+")","i").test(e)?ej:RegExp(en,"i").test(e)&&!RegExp(en+" pc","i").test(e)?eN:""},eX=e=>e instanceof Error;class eK{constructor(e,t,i){void 0===i&&(i=[]),this.coercers=e,this.stackParser=t,this.modifiers=i}buildFromUnknown(e,t){void 0===t&&(t={});var i=t&&t.mechanism||{handled:!0,type:"generic"},n=this.buildCoercingContext(i,t,0).apply(e),r=this.buildParsingContext(t),s=this.parseStacktrace(n,r);return{$exception_list:this.convertToExceptionList(s,i),$exception_level:"error"}}modifyFrames(e){var t=this;return _(function*(){for(var i of e)i.stacktrace&&i.stacktrace.frames&&R(i.stacktrace.frames)&&(i.stacktrace.frames=yield t.applyModifiers(i.stacktrace.frames));return e})()}coerceFallback(e){var t;return{type:"Error",value:"Unknown error",stack:null==(t=e.syntheticException)?void 0:t.stack,synthetic:!0}}parseStacktrace(e,t){var i,n;return null!=e.cause&&(i=this.parseStacktrace(e.cause,t)),""!=e.stack&&null!=e.stack&&(n=this.applyChunkIds(this.stackParser(e.stack,e.synthetic?t.ski
1pFirstLines:0),t.chunkIdMap)),m({},e,{cause:i,stack:n})}applyChunkIds(e,t){return e.map(e=>(e.filename&&t&&(e.chunk_id=t[e.filename]),e))}applyCoercers(e,t){for(var i of this.coercers)if(i.match(e))return i.coerce(e,t);return this.coerceFallback(t)}applyModifiers(e){var t=this;return _(function*(){var i=e;for(var n of t.modifiers)i=yield n(i);return i})()}convertToExceptionList(e,t){var i,n,r,s={type:e.type,value:e.value,mechanism:{type:null!==(i=t.type)&&void 0!==i?i:"generic",handled:null===(n=t.handled)||void 0===n||n,synthetic:null!==(r=e.synthetic)&&void 0!==r&&r}};e.stack&&(s.stacktrace={type:"raw",frames:e.stack});var o=[s];return null!=e.cause&&o.push(...this.convertToExceptionList(e.cause,m({},t,{handled:!0}))),o}buildParsingContext(e){var t;return{chunkIdMap:function(e){var t=globalThis._posthogChunkIds;if(t){var i=Object.keys(t);return ee&&i.length===Q||(Q=i.length,ee=i.reduce((i,n)=>{Z||(Z={});var r=Z[n];if(r)i[r[0]]=r[1];else for(var s=e(n),o=s.length-1;o>=0;o--){var a=s[o],l=null==a?void 0:a.filename,c=t[n];if(l&&c){i[l]=c,Z[n]=[l,c];break}}return i},{})),ee}}(this.stackParser),skipFirstLines:null!==(t=e.skipFirstLines)&&void 0!==t?t:1}}buildCoercingContext(e,t,i){void 0===i&&(i=0);var n=(i,n)=>{if(4>=n){var r=this.buildCoercingContext(e,t,n);return this.applyCoercers(i,r)}};return m({},t,{syntheticException:0==i?t.syntheticException:void 0,mechanism:e,apply:e=>n(e,i),next:e=>n(e,i+1)})}}function eJ(e,t,i,n,r){var s={platform:e,filename:t,function:"<anonymous>"===i?"?":i,in_app:!0};return j(n)||(s.lineno=n),j(r)||(s.colno=r),s}var eZ=(e,t)=>{var i=-1!==e.indexOf("safari-extension"),n=-1!==e.indexOf("safari-web-extension");return i||n?[-1!==e.indexOf("@")?e.split("@")[0]:"?",i?"safari-extension:"+t:"safari-web-extension:"+t]:[e,t]},eQ=/^\s*at (\S+?)(?::(\d+))(?::(\d+))\s*$/i,e0=/^\s*at (?:(.+?\)(?: \[.+\])?|.*?) ?\((?:address at )?)?(?:async )?((?:<anonymous>|[-a-z]+:|.*bundle|\/)?.*?)(?::(\d+))?(?::(\d+))?\)?\s*$/i,e1=/\((\S*)(?::(\d+))(?::(\d+))\)/,e2=(e,t)=>{var i=eQ.exec(e);if(i){var[,n,r,s]=i;return eJ(t,n,"?",+r,+s)}var o=e0.exec(e);if(o){if(o[2]&&0===o[2].indexOf("eval")){var a=e1.exec(o[2]);a&&(o[2]=a[1],o[3]=a[2],o[4]=a[3])}var[l,c]=eZ(o[1]||"?",o[2]);return eJ(t,c,l,o[3]?+o[3]:void 0,o[4]?+o[4]:void 0)}},e5=/^\s*(.*?)(?:\((.*?)\))?(?:^|@)?((?:[-a-z]+)?:\/.*?|\[native code\]|[^@]*(?:bundle|\d+\.js)|\/[\w\-. /=]+)(?::(\d+))?(?::(\d+))?\s*$/i,e7=/(\S+) line (\d+)(?: > eval line \d+)* > eval/i,e3=(e,t)=>
1{var i=e5.exec(e);if(i){if(i[3]&&i[3].indexOf(" > eval")>-1){var n=e7.exec(i[3]);n&&(i[1]=i[1]||"eval",i[3]=n[1],i[4]=n[2],i[5]="")}var r=i[3],s=i[1]||"?";return[s,r]=eZ(s,r),eJ(t,r,s,i[4]?+i[4]:void 0,i[5]?+i[5]:void 0)}},e4=/\(error: (.*)\)/;class e8{match(e){return this.isDOMException(e)||this.isDOMError(e)}coerce(e,t){var i=N(e.stack);return{type:this.getType(e),value:this.getValue(e),stack:i?e.stack:void 0,cause:e.cause?t.next(e.cause):void 0,synthetic:!1}}getType(e){return this.isDOMError(e)?"DOMError":"DOMException"}getValue(e){var t=e.name||(this.isDOMError(e)?"DOMError":"DOMException");return e.message?t+": "+e.message:t}isDOMException(e){return B(e,"DOMException")}isDOMError(e){return B(e,"DOMError")}}class e6{match(e){return e instanceof Error}coerce(e,t){return{type:this.getType(e),value:this.getMessage(e,t),stack:this.getStack(e),cause:e.cause?t.next(e.cause):void 0,synthetic:!1}}getType(e){return e.name||e.constructor.name}getMessage(e,t){var i=e.message;return String(i.error&&"string"==typeof i.error.message?i.error.message:i)}getStack(e){return e.stacktrace||e.stack||void 0}}class e9{constructor(){}match(e){return B(e,"ErrorEvent")&&null!=e.error}coerce(e,t){var i;return t.apply(e.error)||{type:"ErrorEvent",value:e.message,stack:null==(i=t.syntheticException)?void 0:i.stack,synthetic:!0}}}var te=/^(?:[Uu]ncaught (?:exception: )?)?(?:((?:Eval|Internal|Range|Reference|Syntax|Type|URI|)Error): )?(.*)$/i;class tt{match(e){return"string"==typeof e}coerce(e,t){var i,[n,r]=this.getInfos(e);return{type:null!=n?n:"Error",value:null!=r?r:e,stack:null==(i=t.syntheticException)?void 0:i.stack,synthetic:!0}}getInfos(e){var t="Error",i=e,n=e.match(te);return n&&(t=n[1],i=n[2]),[t,i]}}var ti=["fatal","error","warning","log","info","debug"];function tn(e,t){void 0===t&&(t=40);var i=Object.keys(e);if(i.sort(),!i.length)return"[object has no keys]";for(var n=i.length;n>0;n--){var r=i.slice(0,n).join(", ");if(t>=r.length)return n===i.length?r:r.length>t?r.slice(0,t)+"...":r}return""}class tr{match(e){return"object"==typeof e&&null!==e}coerce(e,t){var i,n=this.getErrorPropertyFromObject(e);return n?t.apply(n):{type:this.getType(e),value:this.getValue(e),stack:null==(i=t.syntheticException)?void 0:i.stack,level:this.isSeverityLevel(e.level)?e.level:"error",synthetic:!0}}getType(e){return V(e)?e.constructor.name:"Error"}getValue(e){if("name"in e&&"string"==typeof e.name){var t="'"+e.name+"' captured as exception";return"message"in e&&"string"==typeof e.message&&(t+=" with message: '"+e.message+"'"),t}if("message"in e&&"string"==typeof e.message)return e.message;var i=this.getObjectClassName(e);return(i&&"Object"!==i?"'"+i+"'":"Object")+" captured as exception with keys: "+tn(e)}isSeverityLevel(e){return N(e)&&!F(e)&&ti.indexOf(e)>=0}getErrorPropertyFromObject(e){for(var t in e)if(({}).hasOwnProperty.call(e,t)){var i=e[t];if(eX(i))return i}}getObjectClassName(e){try{var t=Object.getPrototypeOf(e);return t?t.constructor.name:void 0}catch(e){return}}}class ts{match(e){return V(e)}coerce(e,t){var i,n=e.constructor.name;return{type:n,value:n+" captured as exception with keys: "+tn(e),stack:null==(i=t.syntheticException)?void 0:i.stack,synthetic:!0}}}class to{match(e){return q(e)}coerce(e,t){var i;return{type:"Error",value:"Primitive value captured as exception: "+String(e),stack:null==(i=t.syntheticException)?void 0:i.stack,synthetic:!0}}}class ta{match(e){return B(e,"PromiseRejectionEvent")||this.isCustomEventWrappingRejection(e)}isCustomEventWrappingRejection(e){if(!V(e))return!1;try{var t=e.detail;return null!=t&&"object"==typeof t&&"reason"in t}catch(e){return!1}}coerce(e,t){var i,n=this.getUnhandledRejectionReason(e);return q(n)?{type:"UnhandledRejection",value:"Non-Error promise rejection captured with value: "+String(n),stack:null==(i=t.syntheticException)?void 0:i.stack,synthetic:!0}:t.apply(n)}getUnhandledRejectionReason(e){try{if("reason"in e)return e.reason;if("detail"in e&&null!=e.detail&&"object"==typeof e.detail&&"reason"in e.detail)return e.detail.reason}catch(e){}return e}}var tl=function(e,t){var{debugEnabled:i}=void 0===t?{}:t,r={C(t){if(n&&(v.DEBUG||p.POSTHOG_DEBUG||i)&&!j(n.console)&&n.c
1onsole){for(var r=("__rrweb_original__"in n.console[t])?n.console[t].__rrweb_original__:n.console[t],s=arguments.length,o=Array(s>1?s-1:0),a=1;s>a;a++)o[a-1]=arguments[a];r(e,...o)}},info(){for(var e=arguments.length,t=Array(e),i=0;e>i;i++)t[i]=arguments[i];r.C("log",...t)},warn(){for(var e=arguments.length,t=Array(e),i=0;e>i;i++)t[i]=arguments[i];r.C("warn",...t)},error(){for(var e=arguments.length,t=Array(e),i=0;e>i;i++)t[i]=arguments[i];r.C("error",...t)},critical(){for(var t=arguments.length,i=Array(t),n=0;t>n;n++)i[n]=arguments[n];console.error(e,...i)},uninitializedWarning(e){r.error("You must initialize PostHog before calling "+e)},createLogger:(t,i)=>tl(e+" "+t,i)};return r},tc=tl("[PostHog.js]"),tu=tc.createLogger,td=tu("[ExternalScriptsLoader]"),th=(e,t,i)=>{if(e.config.disable_external_dependency_loading)return td.warn(t+" was requested but loading of external scripts is disabled."),i("Loading of external scripts is disabled");var n=null==o?void 0:o.querySelectorAll("script");if(n){for(var r,s=0;n.length>s;s++)if(r=function(){if(n[s].src===t){var e=n[s];return e.__posthog_loading_callback_fired?{v:i()}:(e.addEventListener("load",t=>{e.__posthog_loading_callback_fired=!0,i(void 0,t)}),e.onerror=e=>i(e),{v:void 0})}}())return r.v}var a=()=>{if(!o)return i("document not found");var n=o.createElement("script");if(n.type="text/javascript",n.crossOrigin="anonymous",n.src=t,n.onload=e=>{n.__posthog_loading_callback_fired=!0,i(void 0,e)},n.onerror=e=>i(e),e.config.prepare_external_dependency_script&&(n=e.config.prepare_external_dependency_script(n)),!n)return i("prepare_external_dependency_script returned null");if("head"===e.config.external_scripts_inject_target)o.head.appendChild(n);else{var r,s=o.querySelectorAll("body > script");s.length>0?null==(r=s[0].parentNode)||r.insertBefore(n,s[0]):o.body.appendChild(n)}};null!=o&&o.body?a():null==o||o.addEventListener("DOMContentLoaded",a)};p.__PosthogExtensions__=p.__PosthogExtensions__||{},p.__PosthogExtensions__.loadExternalDependency=(e,t,i)=>{if("remote-config"!==t){if(e._resolvedSdkVersion){var n=e.requestRouter.endpointFor("assets","/static/"+e._resolvedSdkVersion+"/"+t+".js");th(e,n,i)}else{var r="/static/"+t+".js?v="+e.version;"toolbar"===t&&(r=r+"&t="+3e5*Math.floor(Date.now()/3e5));var s=e.requestRouter.endpointFor("assets",r);th(e,s,i)}}else{var o=e.requestRouter.endpointFor("assets","/array/"+e.config.token+"/config.js");th(e,o,i)}},p.__PosthogExtensions__.loadSiteApp=(e,t,i)=>{var n=e.requestRouter.endpointFor("api",t);th(e,n,i)};var tp="$people_distinct_id",tg="$device_id",tv="__alias",tf="__timers",t_="$autocapture_disabled_server_side",tm="$heatmaps_enabled_server_side",ty="$exception_capture_enabled_server_side",tb="$error_tracking_suppression_rules",tE="$error_tracking_capture_extension_exceptions",tw="$web_vitals_enabled_server_side",tS="$dead_clicks_enabled_server_side",tT="$product_tours_enabled_server_side",tI="$web_vitals_allowed_metrics",tk="$session_recording_remote_config",tx="$sesid",tO="$session_is_sampled",tP="$enabled_feature_flags",tR="$early_access_features",tA="$feature_flag_details",tC="$stored_person_properties",tL="$stored_group_properties",tj="$surveys",tN="$flag_call_reported",tF="$flag_call_reported_session_id",tM="$feature_flag_errors",t$="$feature_flag_evaluated_at",tD="$user_state",tG="$client_session_props",tU="$capture_rate_limit",tH="$initial_campaign_params",tW="$initial_referrer_info",tq="$initial_person_info",tB="$epp",tV="__POSTHOG_TOOLBAR__",tz="$posthog_cookieless",tY=[tp,tv,"__cmpns",tf,"$session_recording_enabled_server_side",tm,tx,tP,tb,tD,tR,tA,tL,tC,tj,tN,tF,tM,t$,tG,tU,tH,tW,tB,tq],tX="PostHog loadExternalDependency extension not found.",tK="on_reject",tJ="always",tZ="anonymous",tQ="identified",t0="identified_only",t1="visibilitychange",t2="beforeunload",t5="$pageview",t7="$pageleave",t3="$identify",t4="$groupidentify";function t8(e,t){R(e)&&e.forEach(t)}function t6(e,t){if(!$(e)){if(R(e))e.forEach(t);else if(H(e))e.forEach((e,i)=>t(e,i));else for(var i in e)O.call(e,i)&&t(e[i],i)}}var t9=function(e){for(var t=arguments.length,i=Array(t>1?t-1:0),n=1;t>n;n++)i[n-1]=arguments[n];for(var r of i)for(var s in r)void 0!==r[s]&&(e[s]=r[s]);return e};function ie(e){for(var t=Object.keys(e),i=t.length,n=Array(i);i--;)n[i]=[t[i],e[t[i]]];return n}var it=function(e){try{return e()}catch(e){return}},ii=function(e){return function(){try{for(var t=arguments.length,i=Array(t),n=0;t>n;n++)i[n]=arguments[n];return e.apply(this,i)}catch(e){tc.critical("Implementation error. Please turn on debug mode and open a ticket on https://app.posthog.com/home#panel=support%3Asupport%3A."),tc.critical(e)}}},ir=function(e){var t={};return t6(e,function(e,i){(N(e)&&e.length>0||D(e))&&(t[i]=e)}),t},is=["herokuapp.com","vercel.app","netlify.app"];function io(e,t,i,n){var{capture:r=!1,passive:s=!0}=null!=n?n:{};null==e||e.addEventListener(t,i,{capture:r,passive:s})}function ia(e){return"ph_toolbar_internal"===e.name}Math.trunc||(Math.trunc=function(e){return 0>e?Math.ceil(e):Math.floor(e)}),Number.isInteger||(Number.isInteger=function(e){return D(e)&&isFinite(e)&&Math.floor(e)===e});class il{constructor(e){if(this.bytes=e,16!==e.length)throw TypeError("not 128-bit length")}static fromFieldsV7(e,t,i,n){if(!Number.isInteger(e)||!Number.isInteger(t)||!Number.isInteger(i)||!Number.isInteger(n)||0>e||0>t||0>i||0>n||e>0xffffffffffff||t>4095||i>1073741823||n>4294967295)throw RangeError("invalid field value");
1var r=new Uint8Array(16);return r[0]=e/1099511627776,r[1]=e/4294967296,r[2]=e/16777216,r[3]=e/65536,r[4]=e/256,r[5]=e,r[6]=112|t>>>8,r[7]=t,r[8]=128|i>>>24,r[9]=i>>>16,r[10]=i>>>8,r[11]=i,r[12]=n>>>24,r[13]=n>>>16,r[14]=n>>>8,r[15]=n,new il(r)}toString(){for(var e="",t=0;this.bytes.length>t;t++)e=e+(this.bytes[t]>>>4).toString(16)+(15&this.bytes[t]).toString(16),3!==t&&5!==t&&7!==t&&9!==t||(e+="-");if(36!==e.length)throw Error("Invalid UUIDv7 was generated");return e}clone(){return new il(this.bytes.slice(0))}equals(e){return 0===this.compareTo(e)}compareTo(e){for(var t=0;16>t;t++){var i=this.bytes[t]-e.bytes[t];if(0!==i)return Math.sign(i)}return 0}}class ic{constructor(){this.I=0,this.S=0,this.k=new ih}generate(){var e=this.generateOrAbort();if(j(e)){this.I=0;var t=this.generateOrAbort();if(j(t))throw Error("Could not generate UUID after timestamp reset");return t}return e}generateOrAbort(){var e=Date.now();if(e>this.I)this.I=e,this.A();else{if(this.I>=e+1e4)return;this.S++,this.S>4398046511103&&(this.I++,this.A())}return il.fromFieldsV7(this.I,Math.trunc(this.S/1073741824),1073741823&this.S,this.k.nextUint32())}A(){this.S=1024*this.k.nextUint32()+(1023&this.k.nextUint32())}}var iu,id=e=>{if("undefined"!=typeof UUIDV7_DENY_WEAK_RNG&&UUIDV7_DENY_WEAK_RNG)throw Error("no cryptographically strong RNG available");for(var t=0;e.length>t;t++)e[t]=65536*Math.trunc(65536*Math.random())+Math.trunc(65536*Math.random());return e};n&&!j(n.crypto)&&crypto.getRandomValues&&(id=e=>crypto.getRandomValues(e));class ih{constructor(){this.T=new Uint32Array(8),this.N=1/0}nextUint32(){return this.T.length>this.N||(id(this.T),this.N=0),this.T[this.N++]}}var ip=()=>ig().toString(),ig=()=>(iu||(iu=new ic)).generate(),iv="",i_=/[a-z0-9][a-z0-9-]+\.[a-z]{2,}$/i,im={Ut:()=>!!o,Yt(e){tc.error("cookieStore error: "+e)},Wt(e){if(o){try{for(var t=e+"=",i=o.cookie.split(";").filter(e=>e.length),n=0;i.length>n;n++){for(var r=i[n];" "==r.charAt(0);)r=r.substring(1,r.length);if(0===r.indexOf(t))return decodeURIComponent(r.substring(t.length,r.length))}}catch(e){}return null}},Gt(e){var t;try{t=JSON.parse(im.Wt(e))||{}}catch(e){}return t},Xt(e,t,i,n,r){if(o)try{var s="",a="",l=function(e,t){if(t){var i=function(e,t){if(void 0===t&&(t=o),iv)return iv;if(!t||["localhost","127.0.0.1"].includes(e))return"";for(var i=e.split("."),n=Math.min(i.length,8),r="dmn_chk_"+ip();!iv&&n--;){var s=i.slice(n).join("."),a=r+"=1;domain=."+s+";path=/";t.cookie=a+";max-age=3",t.cookie.includes(r)&&(t.cookie=a+";max-age=0",iv=s)}return iv}(e);if(!i){var n,r=(n=e.match(i_))?n[0]:"";r!==i&&tc.info("Warning: cookie subdomain discovery mismatch",r,i),i=r}return i?"; domain=."+i:""}return""}(o.location.hostname,n);if(i){var c=new Date;c.setTime(c.getTime()+864e5*i),s="; expires="+c.toUTCString()}r&&(a="; secure");var u=e+"="+encodeURIComponent(JSON.stringify(t))+s+"; SameSite=Lax; path=/"+l+a;return u.length>3686.4&&tc.warn("cookieStore warning: large cookie, len="+u.length),o.cookie=u,u}catch(e){return}},Jt(e,t){if(null!=o&&o.cookie)try{im.Xt(e,"",-1,t)}catch(e){return}}},iy=null,ib={Ut(){if(!M(iy))return iy;var e=!0;if(j(n))e=!1;else try{var t="__mplssupport__";ib.Xt(t,"xyz"),'"xyz"'!==ib.Wt(t)&&(e=!1),ib.Jt(t)}catch(t){e=!1}return e||tc.error("localStorage unsupported; falling back to cookie store"),iy=e,e},Yt(e){tc.error("localStorage error: "+e)},Wt(e){try{return null==n?void 0:n.localStorage.getItem(e)}catch(e){ib.Yt(e)}return null},Gt(e){try{return JSON.parse(ib.Wt(e))||{}}catch(e){}return null},Xt(e,t){try{null==n||n.localStorage.setItem(e,JSON.stringify(t))}catch(e){ib.Yt(e)}},Jt(e){try{null==n||n.localStorage.removeItem(e)}catch(e){ib.Yt(e)}}},iE=[tg,"distinct_id",tx,tO,tB,tq,tD],iw={},iS={Ut:()=>!0,Yt(e){tc.error("memoryStorage error: "+e)},Wt:e=>iw[e]||null,Gt:e=>iw[e]||null,Xt(e,t){iw[e]=t},Jt(e){delete iw[e]}},iT=null,iI={Ut(){if(!M(iT))return iT;if(iT=!0,j(n))iT=!1;else try{var e="__support__";iI.Xt(e,"xyz"),'"xyz"'!==iI.Wt(e)&&(iT=!1),iI.Jt(e)}catch(e){iT=!1}return iT},Yt(e){tc.error("sessionStorage error: ",e)},Wt(e){try{return null==n?void 0:n.sessionStorage.getItem(e)}catch(e){iI.Yt(e)}return null},Gt(e){try{return JSON.parse(iI.Wt(e))||null}catch(e){}return null},Xt(e,t){try{null==n||n.sessionStorage.setItem(e,JSON.stringify(t))}catch(e){iI.Yt(e)}},Jt(e){try{null==n||n.sessionStorage.removeItem(e)}catch(e){iI.Yt(e)}}};class ik{constructor(e){this._instance=e}get Rt(){return this._instance.config}get consent(){return this.Kt()?0:this.Qt}isOptedOut(){return this.Rt.cookieless_mode===tJ||0===this.consent||-1===this.consent&&(this.Rt.opt_out_capturing_by_default||this.Rt.cookieless_mode===tK)}isOptedIn(){return!this.isOptedOut()}isExplicitlyOptedOut(){return 0===this.consent}optInOut(e){this.ti.Xt(this.ei,e?1:0,this.Rt.cookie_expiration,this.Rt.cross_subdomain_cookie,this.Rt.secure_cookie)}reset(){this.ti.Jt(this.ei,this.Rt.cross_subdomain_cookie)}get ei(){var{token:e,opt_out_capturing_cookie_prefix:t,consent_persistence_name:i}=this._instance.config;
1return i||(t?t+e:"__ph_opt_in_out_"+e)}get Qt(){var e=this.ti.Wt(this.ei);return Y(e)?1:T(X,e)?0:-1}get ti(){var e=this.Rt.opt_out_capturing_persistence_type,t="localStorage"===e?ib:im;if(!this.ii||this.ii!==t){this.ii=t;var i="localStorage"===e?im:ib;i.Wt(this.ei)&&(this.ii.Wt(this.ei)||this.optInOut(Y(i.Wt(this.ei))),i.Jt(this.ei,this.Rt.cross_subdomain_cookie))}return this.ii}Kt(){return!!this.Rt.respect_dnt&&[null==s?void 0:s.doNotTrack,null==s?void 0:s.msDoNotTrack,p.doNotTrack].some(e=>Y(e))}}var ix=tu("[Dead Clicks]"),iO=()=>!0,iP=e=>{var t,i=!(null==(t=e.instance.persistence)||!t.get_property(tS)),n=e.instance.config.capture_dead_clicks;return U(n)?n:!!C(n)||i};class iR{get lazyLoadedDeadClicksAutocapture(){return this.ri}constructor(e,t,i){this.instance=e,this.isEnabled=t,this.onCapture=i,this.startIfEnabledOrStop()}onRemoteConfig(e){"captureDeadClicks"in e&&(this.instance.persistence&&this.instance.persistence.register({[tS]:e.captureDeadClicks}),this.startIfEnabledOrStop())}startIfEnabledOrStop(){this.isEnabled(this)?this.ni(()=>{this.si()}):this.stop()}ni(e){var t,i;null!=(t=p.__PosthogExtensions__)&&t.initDeadClicksAutocapture&&e(),null==(i=p.__PosthogExtensions__)||null==i.loadExternalDependency||i.loadExternalDependency(this.instance,"dead-clicks-autocapture",t=>{t?ix.error("failed to load script",t):e()})}si(){var e;if(o){if(!this.ri&&null!=(e=p.__PosthogExtensions__)&&e.initDeadClicksAutocapture){var t=C(this.instance.config.capture_dead_clicks)?this.instance.config.capture_dead_clicks:{};t.__onCapture=this.onCapture,this.ri=p.__PosthogExtensions__.initDeadClicksAutocapture(this.instance,t),this.ri.start(o),ix.info("starting...")}}else ix.error("`document` not found. Cannot start.")}stop(){this.ri&&(this.ri.stop(),this.ri=void 0,ix.info("stopping..."))}}var iA=tu("[SegmentIntegration]"),iC="posthog-js";function iL(e,t){var{organization:i,projectId:n,prefix:r,severityAllowList:s=["error"],sendExceptionsToPostHog:o=!0}=void 0===t?{}:t;return t=>{if("*"!==s&&!s.includes(t.level)||!e.__loaded)return t;t.tags||(t.tags={});var a=e.requestRouter.endpointFor("ui","/project/"+e.config.token+"/person/"+e.get_distinct_id());t.tags["PostHog Person URL"]=a,e.sessionRecordingStarted()&&(t.tags["PostHog Recording URL"]=e.get_session_replay_url({withTimestamp:!0}));var l,c,u,d,h,p,g=(null==(l=t.exception)?void 0:l.values)||[],v=g.map(e=>m({},e,{stacktrace:e.stacktrace?m({},e.stacktrace,{type:"raw",frames:(e.stacktrace.frames||[]).map(e=>m({},e,{platform:"web:javascript"}))}):void 0})),f={$exception_message:(null==(c=g[0])?void 0:c.value)||t.message,$exception_type:null==(u=g[0])?void 0:u.type,$exception_level:t.level,$exception_list:v,$sentry_event_id:t.event_id,$sentry_exception:t.exception,$sentry_exception_message:(null==(d=g[0])?void 0:d.value)||t.message,$sentry_exception_type:null==(h=g[0])?void 0:h.type,$sentry_tags:t.tags};return i&&n&&(f.$sentry_url=(r||"https://sentry.io/organizations/")+i+"/issues/?project="+n+"&query="+t.event_id),o&&(null==(p=e.exceptions)||p.sendExceptionEvent(f)),t}}class ij{constructor(e,t,i,n,r,s){this.name=iC,this.setupOnce=function(o){o(iL(e,{organization:t,projectId:i,prefix:n,severityAllowList:r,sendExceptionsToPostHog:null==s||s}))}}}class iN{constructor(e){this.oi=(e,t,i)=>{i&&(i.noSessionId||i.activityTimeout||i.sessionPastMaximumLength)&&(tc.info("[PageViewManager] Session rotated, clearing pageview state",{sessionId:e,changeReason:i}),this.ai=void 0,this._instance.scrollManager.resetContext())},this._instance=e,this.li()}li(){var e;this.ui=null==(e=this._instance.sessionManager)?void 0:e.onSessionId(this.oi)}destroy(){var e;null==(e=this.ui)||e.call(this),this.ui=void 0}doPageView(e,t){var i,r=this.hi(e,t);return this.ai={pathname:null!==(i=null==n?void 0:n.location.pathname)&&void 0!==i?i:"",pageViewId:t,timestamp:e},this._instance.scrollManager.resetContext(),r}doPageLeave(e){var t;return this.hi(e,null==(t=this.ai)?void 0:t.pageViewId)}doEvent(){var e;return{$pageview_id:null==(e=this.ai)?void 0:e.pageViewId}}hi(e,t){var i=this.ai;if(!i)return{$pageview_id:t};var n={$pageview_id:t,$prev_pageview_id:i.pageViewId},r=this._instance.scrollManager.getContext();if(r&&!this._instance.config.disable_scroll_properties){var{maxScrollHeight:s,lastScrollY:o,maxScrollY:a,maxContentHeight:l,lastContentY:c,maxContentY:u}=r;if(!(j(s)||j(o)||j(a)||j(l)||j(c)||j(u))){s=Math.ceil(s),o=Math.ceil(o),a=Math.ceil(a),l=Math.ceil(l),c=Math.ceil(c),u=Math.ceil(u);var d=s>
11?K(o/s,0,1,tc):1,h=s>1?K(a/s,0,1,tc):1,p=l>1?K(c/l,0,1,tc):1,g=l>1?K(u/l,0,1,tc):1;n=t9(n,{$prev_pageview_last_scroll:o,$prev_pageview_last_scroll_percentage:d,$prev_pageview_max_scroll:a,$prev_pageview_max_scroll_percentage:h,$prev_pageview_last_content:c,$prev_pageview_last_content_percentage:p,$prev_pageview_max_content:u,$prev_pageview_max_content_percentage:g})}}return i.pathname&&(n.$prev_pageview_pathname=i.pathname),i.timestamp&&(n.$prev_pageview_duration=(e.getTime()-i.timestamp.getTime())/1e3),n}}var iF=e=>{var t=null==o?void 0:o.createElement("a");return j(t)?null:(t.href=e,t)},iM=function(e,t){for(var i,n=((e.split("#")[0]||"").split(/\?(.*)/)[1]||"").replace(/^\?+/g,"").split("&"),r=0;n.length>r;r++){var s=n[r].split("=");if(s[0]===t){i=s;break}}if(!R(i)||2>i.length)return"";var o=i[1];try{o=decodeURIComponent(o)}catch(e){tc.error("Skipping decoding for malformed query param: "+o)}return o.replace(/\+/g," ")},i$=function(e,t,i){if(!e||!t||!t.length)return e;for(var n=e.split("#"),r=n[1],s=(n[0]||"").split("?"),o=s[1],a=s[0],l=(o||"").split("&"),c=[],u=0;l.length>u;u++){var d=l[u].split("=");R(d)&&(t.includes(d[0])?c.push(d[0]+"="+i):c.push(l[u]))}var h=a;return null!=o&&(h+="?"+c.join("&")),null!=r&&(h+="#"+r),h},iD=function(e,t){var i=e.match(RegExp(t+"=([^&]*)"));return i?i[1]:null},iG="https?://(.*)",iU=["gclid","gclsrc","dclid","gbraid","wbraid","fbclid","msclkid","twclid","li_fat_id","igshid","ttclid","rdt_cid","epik","qclid","sccid","irclid","_kx"],iH=["utm_source","utm_medium","utm_campaign","utm_content","utm_term","gad_source","mc_cid",...iU],iW="<masked>",iq=["li_fat_id"];function iB(e,t,i){if(!o)return{};var n,r=t?[...iU,...i||[]]:[],s=iV(i$(o.URL,r,iW),e);return t9((n={},t6(iq,function(e){var t=im.Wt(e);n[e]=t||null}),n),s)}function iV(e,t){var i=iH.concat(t||[]),n={};return t6(i,function(t){var i=iM(e,t);n[t]=i||null}),n}function iz(e){var t=e?0===e.search(iG+"google.([^/?]*)")?"google":0===e.search(iG+"bing.com")?"bing":0===e.search(iG+"yahoo.com")?"yahoo":0===e.search(iG+"duckduckgo.com")?"duckduckgo":null:null,i={};if(!M(t)){i.$search_engine=t;var n=o?iM(o.referrer,"yahoo"!=t?"q":"p"):"";n.length&&(i.ph_keyword=n)}return i}function iY(){return navigator.language||navigator.userLanguage}var iX="$direct";function iK(){return(null==o?void 0:o.referrer)||iX}function iJ(e,t){var i=e?[...iU,...t||[]]:[],n=null==a?void 0:a.href.substring(0,1e3);return{r:iK().substring(0,1e3),u:n?i$(n,i,iW):void 0}}function iZ(e){var t,{r:i,u:n}=e,r={$referrer:i,$referring_domain:null==i?void 0:i==iX?iX:null==(t=iF(i))?void 0:t.host};if(n){r.$current_url=n;var s=iF(n);r.$host=null==s?void 0:s.host,r.$pathname=null==s?void 0:s.pathname,t9(r,iV(n))}return i&&t9(r,iz(i)),r}function iQ(){try{return Intl.DateTimeFormat().resolvedOptions().timeZone}catch(e){return}}var i0=["cookie","localstorage","localstorage+cookie","sessionstorage","memory"];class i1{constructor(e,t){var i;this.Rt=e,this.props={},this.ci=!1,this.di=(i="",e.token&&(i=e.token.replace(/\+/g,"PL").replace(/\//g,"SL").replace(/=/g,"EQ")),e.persistence_name?"ph_"+e.persistence_name:"ph_"+i+"_posthog"),this.ti=this.vi(e),this.load(),e.debug&&tc.info("Persistence loaded",e.persistence,m({},this.props)),this.update_config(e,e,t),this.save()}isDisabled(){return!!this.fi}vi(e){-1===i0.indexOf(e.persistence.toLowerCase())&&(tc.critical("Unknown persistence type "+e.persistence+"; falling back to localStorage+cookie"),e.persistence="localStorage+cookie");var t,i,r=(void 0===(t=e.cookie_persisted_properties||[])&&(t=[]),i=[...iE,...t],m({},ib,{Gt(e){try{var t={};try{t=im.Gt(e)||{}}catch(e){}var i=t9(t,JSON.parse(ib.Wt(e)||"{}"));return ib.Xt(e,i),i}catch(e){}return null},Xt(e,t,n,r,s,o){try{ib.Xt(e,t,void 0,void 0,o);var a={};i.forEach(e=>{t[e]&&(a[e]=t[e])}),Object.keys(a).length&&im.Xt(e,a,n,r,s,o)}catch(e){ib.Yt(e)}},Jt(e,t){try{null==n||n.localStorage.removeItem(e),im.Jt(e,t)}catch(e){ib.Yt(e)}}})),s=e.persistence.toLowerCase();return"localstorage"===s&&ib.Ut()?ib:"localstorage+cookie"===s&&r.Ut()?r:"sessionstorage"===s&&iI.Ut()?iI:"memory"===s?iS:"cookie"===s?im:r.Ut()?r:im}pi(e){var t=null!=e?e:this.Rt.feature_flag_cache_ttl_ms;if(!t||0>=t)return!1;var i=this.props[t$];return!i||"number"!=typeof i||Date.now()-i>t}properties(){var e={};return t6(this.props,(t,i)=>{if(i===tP&&C(t)){if(!this.pi())for(var n=Object.keys(t),r=0;n.length>r;r++)e["$feature/"+n[r]]=t[n[r]]}else -1===tY.indexOf(i)&&(e[i]=t)}),e}load(){if(!this.fi){var e=this.ti.Gt(this.di);e&&(this.props=t9({},e))}}save(){this.fi||this.ti.Xt(this.di,this.props,this.gi,this.mi,this.yi,this.Rt.debug)}remove(){this.ti.Jt(this.di,!1),this.ti.Jt(this.di,!0)}clear(){this.remove(),this.props={}}register_once(e,t,i){if(C(e)){j(t)&&(t="None"),this.gi=j(i)?this.bi:i;var n=!1;if(t6(e,(e,i)=>{this.props.hasOwnProperty(i)&&this.props[i]!==t||(this.props[i]=e,n=!0)}),n)return this.save(),!0}return!1}register(e,t){if(C(e)){this.gi=j(t)?this.bi:t;var i=!1;if(t6(e,(t,n)=>{e.hasOwnProperty(n)&&this.props[n]!==t&&(this.props[n]=t,i=!0)}),i)return this.save(),!0}return!1}unregister(e){e in this.props&&(delete this.props[e],this.save())}update_campaign_params(){if(!this.ci){var e=iB(this.Rt.custom_campaign_params,this.Rt.mask_personal_data_properties,this.Rt.custom_personal_data_properties);L(ir(e))||this.register(e),this.ci=!0}}update_search_keyword(){var e;this.register((e=null==o?void 0:o.referrer)?iz(e):{})}update_referrer_info(){var e;this.register_once({$referrer:iK(),$referring_domain:null!=o&&o.referrer&&(null==(e=iF(o.referrer))?void 0:e.host)||iX},void 0)}set_initial_person_info(){this.props[tH]||this.props[tW]||this.register_once({[tq]:iJ(this.Rt.mask_personal_data_properties,this.Rt.custom_personal_data_properties)},void 0)}get_initial_props(){var e={};t6([tW,tH],t=>{var i=this.props[t];i&&t6(i,function(t,i){e["$initial_"+k(i)]=t})});var t,i,n=this.props[tq];return n&&t9(e,(t=iZ(n),i={},t6(t,function(e,t){i["$initial_"+k(t)]=e}),i)),e}safe_merge(e){return t6(this.props,function(t,i){i in e||(e[i]=t)}),e}update_config(e,t,i){if(this.bi=this.gi=e.cookie_expiration,this.set_disabled(e.disable_persistence||!!i),this.set_cross_subdomain(e.cross_subdomain_cookie),this.set_secure(e.secure_cookie),e.persistence!==t.persistence||!((e,t)=>{if(e.length!==t.length)return!1;var i=[...e].sort(),n=[...t].sort();return i.every((e,t)=>e===n[t])})(e.cookie_persisted_properties||[],t.cookie_persisted_properties||[])){var n=this.vi(e),r=this.props;this.clear(),this.ti=n,this.props=r,this.save()}}set_disabled(e){this.fi=e,this.fi?this.remove():this.save()}set_cross_subdomain(e){e!==this.mi&&(this.mi=e,this.remove(),this.save())}set_secure(e){e!==this.yi&&(this.yi=e,this.remove(),this.save())}set_event_timer(e,t){var i=this.props[tf]||{};i[e]=t,this.props[tf]=i,this.save()}remove_event_timer(e){var t=(this.props[tf]||{})[e];return j(t)||(delete this.props[tf][e],this.save()),t}get_property(e){return this.props[e]}set_property(e,t){this.props[e]=t,this.save()}}var i2={Activation:"events",Cancellation:"cancelEvents"},i5={Popover:"popover",API:"api",Widget:"widget"},i7={SHOWN:"survey shown",DISMISSED:"survey dismissed",SENT:"survey sent"},i3={SURVEY_ID:"$survey_id",SURVEY_ITERATION:"$survey_iteration",SURVEY_LAST_SEEN_DATE:"$survey_last_seen_date"},i4={Popover:"popover",Inline:"inline"},i8={SHOWN:"product tour shown"},i6={TOUR_LAST_SEEN_DATE:"$product_tour_last_seen_date",TOUR_TYPE:"$product_tour_type"},i9=tu("[RateLimiter]");class ne{constructor(e){this.serverLimits={},this.lastEventRateLimited=!1,this.checkForLimiting=e=>{var t=e.text;
1if(t&&t.length)try{(JSON.parse(t).quota_limited||[]).forEach(e=>{i9.info((e||"events")+" is quota limited."),this.serverLimits[e]=(new Date).getTime()+6e4})}catch(e){return void i9.warn('could not rate limit - continuing. Error: "'+(null==e?void 0:e.message)+'"',{text:t})}},this.instance=e,this.lastEventRateLimited=this.clientRateLimitContext(!0).isRateLimited}get captureEventsPerSecond(){var e;return(null==(e=this.instance.config.rate_limiting)?void 0:e.events_per_second)||10}get captureEventsBurstLimit(){var e;return Math.max((null==(e=this.instance.config.rate_limiting)?void 0:e.events_burst_limit)||10*this.captureEventsPerSecond,this.captureEventsPerSecond)}clientRateLimitContext(e){void 0===e&&(e=!1);var t,i,n,{captureEventsBurstLimit:r,captureEventsPerSecond:s}=this,o=(new Date).getTime(),a=null!==(t=null==(i=this.instance.persistence)?void 0:i.get_property(tU))&&void 0!==t?t:{tokens:r,last:o};a.tokens+=(o-a.last)/1e3*s,a.last=o,a.tokens>r&&(a.tokens=r);var l=1>a.tokens;return l||e||(a.tokens=Math.max(0,a.tokens-1)),!l||this.lastEventRateLimited||e||this.instance.capture("$$client_ingestion_warning",{$$client_ingestion_warning_message:"posthog-js client rate limited. Config is set to "+s+" events per second and "+r+" events burst limit."},{skip_client_rate_limiting:!0}),this.lastEventRateLimited=l,null==(n=this.instance.persistence)||n.set_property(tU,a),{isRateLimited:l,remainingTokens:a.tokens}}isServerRateLimited(e){var t=this.serverLimits[e||"events"]||!1;return!1!==t&&(new Date).getTime()<t}}var nt=tu("[RemoteConfig]");class ni{constructor(e){this._instance=e}get remoteConfig(){var e;return null==(e=p._POSTHOG_REMOTE_CONFIG)||null==(e=e[this._instance.config.token])?void 0:e.config}wi(e){var t,i;null!=(t=p.__PosthogExtensions__)&&t.loadExternalDependency?null==(i=p.__PosthogExtensions__)||null==i.loadExternalDependency||i.loadExternalDependency(this._instance,"remote-config",()=>e(this.remoteConfig)):e()}Ii(e){this._instance._send_request({method:"GET",url:this._instance.requestRouter.endpointFor("assets","/array/"+this._instance.config.token+"/config"),callback(t){e(t.json)}})}load(){try{if(this.remoteConfig)return nt.info("Using preloaded remote config",this.remoteConfig),this.Ci(this.remoteConfig),void this.Si();if(this._instance.ki())return void nt.warn("Remote config is disabled. Falling back to local config.");this.wi(e=>{if(!e)return nt.info("No config found after loading remote JS config. Falling back to JSON."),void this.Ii(e=>{this.Ci(e),this.Si()});this.Ci(e),this.Si()})}catch(e){nt.error("Error loading remote config",e)}}stop(){this.xi&&(clearInterval(this.xi),this.xi=void 0)}refresh(){this._instance.ki()||"hidden"===(null==o?void 0:o.visibilityState)||this._instance.reloadFeatureFlags()}Si(){var e;if(!this.xi){var t=null!==(e=this._instance.config.remote_config_refresh_interval_ms)&&void 0!==e?e:3e5;0!==t&&(this.xi=setInterval(()=>{this.refresh()},t))}}Ci(e){var t;e||nt.error("Failed to fetch remote config from PostHog."),this._instance.Ci(null!=e?e:{}),!1!==(null==e?void 0:e.hasFeatureFlags)&&(this._instance.config.advanced_disable_feature_flags_on_first_load||null==(t=this._instance.featureFlags)||t.ensureFlagsLoaded())}}var nn={GZipJS:"gzip-js",Base64:"base64"},nr=Uint8Array,ns=Uint16Array,no=Uint32Array,na=new nr([0,0,0,0,0,0,0,0,1,1,1,1,2,2,2,2,3,3,3,3,4,4,4,4,5,5,5,5,0,0,0,0]),nl=new nr([0,0,0,0,1,1,2,2,3,3,4,4,5,5,6,6,7,7,8,8,9,9,10,10,11,11,12,12,13,13,0,0]),nc=new nr([16,17,18,0,8,7,9,6,10,5,11,4,12,3,13,2,14,1,15]),nu=function(e,t){for(var i=new ns(31),n=0;31>n;++n)i[n]=t+=1<<e[n-1];var r=new no(i[30]);for(n=1;30>n;++n)for(var s=i[n];i[n+1]>s;++s)r[s]=s-i[n]<<5|n;return[i,r]},nd=nu(na,2),nh=nd[1];nd[0][28]=258,nh[258]=28;for(var np=nu(nl,0)[1],ng=new ns(32768),nv=0;32768>nv;++nv){var nf=(43690&nv)>>>1|(21845&nv)<<1;ng[nv]=((65280&(nf=(61680&(nf=(52428&nf)>>>2|(13107&nf)<<2))>>>4|(3855&nf)<<4))>>>8|(255&nf)<<8)>>>1}var n_=function(e,t,i){for(var n=e.length,r=0,s=new ns(t);n>r;++r)++s[e[r]-1];var o,a=new ns(t);for(r=0;t>r;++r)a[r]=a[r-1]+s[r-1]<<1;if(i){o=new ns(1<<t);var l=15-t;for(r=0;n>r;++r)if(e[r])for(var c=r<<4|e[r],u=t-e[r],d=a[e[r]-1]++<<u,h=d|(1<<u)-1;h>=d;++d)o[ng[d]>>>l]=c}else for(o=new ns(n),r=0;n>r;++r)o[r]=ng[a[e[r]-1]++]>>>15-e[r];return o},nm=new nr(288);for(nv=0;144>nv;++nv)nm[nv]=8;for(nv=144;256>nv;++nv)nm[nv]=9;for(nv=256;280>nv;++nv)nm[nv]=7;for(nv=280;288>nv;++nv)nm[nv]=8;var ny=new nr(32);for(nv=0;32>nv;++nv)ny[nv]=5;var nb=n_(nm,9,0),nE=n_(ny,5,0),nw=function(e){return(e/8>>0)+(7&e&&1)},nS=function(e,t,i){(null==i||i>e.length)&&(i=e.length);var n=new(e instanceof ns?ns:e instanceof no?no:nr)(i-t);return n.set(e.subarray(t,i)),n},nT=function(e,t,i){var n=t/8>>0;e[n]|=i<<=7&t,e[n+1]|=i>>>8},nI=function(e,t,i){var n=t/8>>0;e[n]|=i<<=7&t,e[n+1]|=i>>>8,e[n+2]|=i>>>16},nk=function(e,t){for(var i=[],n=0;e.length>n;
1++n)e[n]&&i.push({s:n,f:e[n]});var r=i.length,s=i.slice();if(!r)return[new nr(0),0];if(1==r){var o=new nr(i[0].s+1);return o[i[0].s]=1,[o,1]}i.sort(function(e,t){return e.f-t.f}),i.push({s:-1,f:25001});var a=i[0],l=i[1],c=0,u=1,d=2;for(i[0]={s:-1,f:a.f+l.f,l:a,r:l};u!=r-1;)a=i[i[d].f>i[c].f?c++:d++],l=i[c!=u&&i[d].f>i[c].f?c++:d++],i[u++]={s:-1,f:a.f+l.f,l:a,r:l};var h=s[0].s;for(n=1;r>n;++n)s[n].s>h&&(h=s[n].s);var p=new ns(h+1),g=nx(i[u-1],p,0);if(g>t){n=0;var v=0,f=g-t,_=1<<f;for(s.sort(function(e,t){return p[t.s]-p[e.s]||e.f-t.f});r>n;++n){var m=s[n].s;if(t>=p[m])break;v+=_-(1<<g-p[m]),p[m]=t}for(v>>>=f;v>0;){var y=s[n].s;t>p[y]?v-=1<<t-p[y]++-1:++n}for(;n>=0&&v;--n){var b=s[n].s;p[b]==t&&(--p[b],++v)}g=t}return[new nr(p),g]},nx=function(e,t,i){return -1==e.s?Math.max(nx(e.l,t,i+1),nx(e.r,t,i+1)):t[e.s]=i},nO=function(e){for(var t=e.length;t&&!e[--t];);for(var i=new ns(++t),n=0,r=e[0],s=1,o=function(e){i[n++]=e},a=1;t>=a;++a)if(e[a]==r&&a!=t)++s;else{if(!r&&s>2){for(;s>138;s-=138)o(32754);s>2&&(o(s>10?s-11<<5|28690:s-3<<5|12305),s=0)}else if(s>3){for(o(r),--s;s>6;s-=6)o(8304);s>2&&(o(s-3<<5|8208),s=0)}for(;s--;)o(r);s=1,r=e[a]}return[i.subarray(0,n),t]},nP=function(e,t){for(var i=0,n=0;t.length>n;++n)i+=e[n]*t[n];return i},nR=function(e,t,i){var n=i.length,r=nw(t+2);e[r]=255&n,e[r+1]=n>>>8,e[r+2]=255^e[r],e[r+3]=255^e[r+1];for(var s=0;n>s;++s)e[r+s+4]=i[s];return 8*(r+4+n)},nA=function(e,t,i,n,r,s,o,a,l,c,u){nT(t,u++,i),++r[256];for(var d=nk(r,15),h=d[0],p=d[1],g=nk(s,15),v=g[0],f=g[1],_=nO(h),m=_[0],y=_[1],b=nO(v),E=b[0],w=b[1],S=new ns(19),T=0;m.length>T;++T)S[31&m[T]]++;for(T=0;E.length>T;++T)S[31&E[T]]++;for(var I=nk(S,7),k=I[0],x=I[1],O=19;O>4&&!k[nc[O-1]];--O);var P,R,A,C,L=c+5<<3,j=nP(r,nm)+nP(s,ny)+o,N=nP(r,h)+nP(s,v)+o+14+3*O+nP(S,k)+(2*S[16]+3*S[17]+7*S[18]);if(j>=L&&N>=L)return nR(t,u,e.subarray(l,l+c));if(nT(t,u,1+(j>N)),u+=2,j>N){P=n_(h,p,0),R=h,A=n_(v,f,0),C=v;var F=n_(k,x,0);for(nT(t,u,y-257),nT(t,u+5,w-1),nT(t,u+10,O-4),u+=14,T=0;O>T;++T)nT(t,u+3*T,k[nc[T]]);u+=3*O;for(var M=[m,E],$=0;2>$;++$){var D=M[$];for(T=0;D.length>T;++T)nT(t,u,F[G=31&D[T]]),u+=k[G],G>15&&(nT(t,u,D[T]>>>5&127),u+=D[T]>>>12)}}else P=nb,R=nm,A=nE,C=ny;for(T=0;a>T;++T)if(n[T]>255){nI(t,u,P[257+(G=n[T]>>>18&31)]),u+=R[G+257],G>7&&(nT(t,u,n[T]>>>23&31),u+=na[G]);var G,U=31&n[T];nI(t,u,A[U]),u+=C[U],U>3&&(nI(t,u,n[T]>>>5&8191),u+=nl[U])}else nI(t,u,P[n[T]]),u+=R[n[T]];return nI(t,u,P[256]),u+R[256]},nC=new no([65540,131080,131088,131104,262176,1048704,1048832,2114560,2117632]),nL=function(){for(var e=new no(256),t=0;256>t;++t){for(var i=t,n=9;--n;)i=(1&i&&3988292384)^i>>>1;e[t]=i}return e}(),nj=function(e,t,i){for(;i;++t)e[t]=i,i>>>=8},nN=!!c||!!l,nF="text/plain",nM=!1,n$=function(e,t,i){void 0===i&&(i=!0);var n,r,s,o,a,[l,c]=e.split("?"),u=m({},t),d=null!==(a=null==c?void 0:c.split("&").map(e=>{var t,[n,r]=e.split("="),s=i&&null!==(t=u[n])&&void 0!==t?t:r;return delete u[n],n+"="+s}))&&void 0!==a?a:[],h=(void 0===n&&(n="&"),o=[],t6(u,function(e,t){j(e)||j(t)||"undefined"===t||(r=encodeURIComponent(e instanceof File?e.name:e.toString()),s=encodeURIComponent(t),o[o.length]=s+"="+r)}),o.join(n));return h&&d.push(h),l+"?"+d.join("&")},nD=(e,t)=>JSON.stringify(e,(e,t)=>"bigint"==typeof t?t.toString():t,t),nG=e=>{if(e.zt)return e.zt;var{data:t,compression:i}=e;if(t){if(i===nn.GZipJS){var n,r,s,o,a,l,c,u,d=(n=function(e,t){var i=e.length;if("undefined"!=typeof TextEncoder)return(new TextEncoder).encode(e);for(var n=new nr(e.length+(e.length>>>1)),r=0,s=function(e){n[r++]=e},o=0;i>o;++o){if(r+5>n.length){var a=new nr(r+8+(i-o<<1));a.set(n),n=a}var l=e.charCodeAt(o);128>l?s(l):(2048>l?s(192|l>>>6):(l>55295&&57344>l?(s(240|(l=65536+(1047552&l)|1023&e.charCodeAt(++o))>>>18),s(128|l>>>12&63)):s(224|l>>>12),s(128|l>>>6&63)),s(128|63&l))}return nS(n,0,r)}(nD(t)),r={mtime:0},s=4294967295,o={p(e){for(var t=s,i=0;e.length>i;++i)t=nL[255&t^e[i]]^t>>>8;s=t},d:()=>4294967295^s},a=n.length,o.p(n),u=(l=10+(r.filename&&r.filename.length+1||0),c=function(e,t,i,n,r,s){var o=e.length,a=new nr(n+o+5*(1+Math.floor(o/7e3))+r),l=a.subarray(n,a.length-r),c=0;if(!t||8>o)for(var u=0;o>=u;u+=65535){var d=u+65535;o>d?c=nR(l,c,e.subarray(u,d)):(l[u]=!0,c=nR(l,c,e.subarray(u,o)))}else{for(var h=nC[t-1],p=h>>>13,g=8191&h,v=(1<<i)-1,f=new ns(32768),_=new ns(v+1),m=Math.ceil(i/3),y=2*m,b=function(t){return(e[t]^e[t+1]<<m^e[t+2]<<y)&v},E=new no(25e3),w=new ns(288),S=new ns(32),T=0,I=0,k=(u=0,0),x=0,O=0;o>u;++u){var P=b(u),R=32767&u,A=_[P];if(f[R]=A,_[P]=R,u>=x){var C=o-u;if((T>7e3||k>24576)&&C>423){c=nA(e,l,0,E,w,S,I,k,O,u-O,c),k=T=I=0,O=u;for(var L=0;286>L;++L)w[L]=0;for(L=0;30>L;++L)S[L]=0}var j=2,N=0,F=g,M=R-A&32767;if(C>2&&P==b(u-M))for(var $=Math.min(p,C)-1,D=Math.min(32767,u),G=Math.min(258,C);D>=M&&--F&&R!=A;){if(e[u+j]==e[u+j-M]){for(var U=0;G>U&&e[u+U]==e[u+U-M];++U);if(U>j){if(j=U,N=M,U>$)break;var H=Math.min(M,U-2),W=0;for(L=0;H>L;++L){var q=u-M+L+32768&32767,B=q-f[q]+32768&32767;B>W&&(W=B,A=q)}}}M+=(R=A)-(A=f[R])+32768&32767}if(N){E[k++]=268435456|nh[j]<<18|np[N];var V=31&nh[j],z=31&np[N];I+=na[V]+nl[z],++w[257+V],++S[z],x=u+j,++T}else E[k++]=e[u],++w[e[u]]}}c=nA(e,l,!0,E,w,S,I,k,O,u-O,c)}return nS(a,0,n+nw(c)+r)}(n,null==r.level?6:r.level,null==r.mem?Math.ceil(1.5*Math.max(8,Math.min(13,Math.log(n.length)))):12+r.mem,l,8)).length,function(e,t){var i=t.filename;if(e[0]=31,e[1]=139,e[2]=8,e[8]=2>t.level?4:9==t.level?2:0,e[9]=3,0!=t.mtime&&nj(e,4,Math.floor(new Date(t.mtime||Date.now())/1e3)),i){e[3]=8;for(var n=0;i.length>=n;++n)e[n+10]=i.charCodeAt(n)}}(c,r),nj(c,u-8,o.d()),nj(c,u-4,a),c);return{contentType:nF,body:d.buffer.slice(d.byteOffset,d.byteOffset+d.byteLength),estimatedSize:d.byteLength}}if(i===nn.Base64){var h,p,g="data="+encodeURIComponent("string"==typeof(p=(h=nD(t))?btoa(encodeURIComponent(h).replace(/%([0-9A-F]{2})/g,(e,t)=>
1String.fromCharCode(parseInt(t,16)))):h)?p:nD(p));return{contentType:"application/x-www-form-urlencoded",body:g,estimatedSize:new Blob([g]).size}}var v=nD(t);return{contentType:"application/json",body:v,estimatedSize:new Blob([v]).size}}},nU=(ra=_(function*(e){var t=nD(e.data),i=yield function(e,t,i){return b.apply(this,arguments)}(t,v.DEBUG,{rethrow:!0});if(!i)return e;var n=yield i.arrayBuffer();return m({},e,{zt:{contentType:nF,body:n,estimatedSize:n.byteLength}})}),function(e){return ra.apply(this,arguments)}),nH=(e,t)=>n$(e,{_:(new Date).getTime().toString(),ver:v.JS_SDK_VERSION,compression:t}),nW=[];l&&nW.push({transport:"fetch",method(e){var t,i,{contentType:n,body:r,estimatedSize:s}=null!==(t=nG(e))&&void 0!==t?t:{},o=new Headers;t6(e.headers,function(e,t){o.append(t,e)}),n&&o.append("Content-Type",n);var a=e.url,c=null;if(u){var d=new u;c={signal:d.signal,timeout:setTimeout(()=>d.abort(),e.timeout)}}l(a,m({method:(null==e?void 0:e.method)||"GET",headers:o,keepalive:"POST"===e.method&&52428.8>(s||0),body:r,signal:null==(i=c)?void 0:i.signal},e.fetchOptions)).then(t=>t.text().then(i=>{var n={statusCode:t.status,text:i};if(200===t.status)try{n.json=JSON.parse(i)}catch(e){tc.error(e)}null==e.callback||e.callback(n)})).catch(t=>{tc.error(t),null==e.callback||e.callback({statusCode:0,error:t})}).finally(()=>c?clearTimeout(c.timeout):null)}}),c&&nW.push({transport:"XHR",method(e){var t,i=new c;i.open(e.method||"GET",e.url,!0);var{contentType:n,body:r}=null!==(t=nG(e))&&void 0!==t?t:{};t6(e.headers,function(e,t){i.setRequestHeader(t,e)}),n&&i.setRequestHeader("Content-Type",n),e.timeout&&(i.timeout=e.timeout),e.disableXHRCredentials||(i.withCredentials=!0),i.onreadystatechange=()=>{if(4===i.readyState){var t={statusCode:i.status,text:i.responseText};if(200===i.status)try{t.json=JSON.parse(i.responseText)}catch(e){}null==e.callback||e.callback(t)}},i.send(r)}}),null!=s&&s.sendBeacon&&nW.push({transport:"sendBeacon",method(e){var t=n$(e.url,{beacon:"1"});try{var i,{contentType:n,body:r}=null!==(i=nG(e))&&void 0!==i?i:{};if(!r)return;var o=r instanceof Blob?r:new Blob([r],{type:n});s.sendBeacon(t,o)}catch(e){}}});
1class nq{constructor(e,t){this.Ti=!0,this.Ai=[],this.Ei=K((null==t?void 0:t.flush_interval_ms)||3e3,250,5e3,tc.createLogger("flush interval"),3e3),this.Ri=e}enqueue(e){this.Ai.push(e),this.Ni||this.Mi()}unload(){this.Fi();var e=Object.values(this.Ai.length>0?this.Oi():{});[...e.filter(e=>0===e.url.indexOf("/e")),...e.filter(e=>0!==e.url.indexOf("/e"))].map(e=>{this.Ri(m({},e,{transport:"sendBeacon"}))})}enable(){this.Ti=!1,this.Mi()}Mi(){var e=this;this.Ti||(this.Ni=setTimeout(()=>{if(this.Fi(),this.Ai.length>0){var t=this.Oi();for(var i in t)!function(){var n=t[i],r=(new Date).getTime();n.data&&R(n.data)&&t6(n.data,e=>{e.offset=Math.abs(e.timestamp-r),delete e.timestamp}),e.Ri(n)}()}},this.Ei))}Fi(){clearTimeout(this.Ni),this.Ni=void 0}Oi(){var e={};return t6(this.Ai,t=>{var i,n=(t?t.batchKey:null)||t.url;j(e[n])&&(e[n]=m({},t,{data:[]})),null==(i=e[n].data)||i.push(t.data)}),this.Ai=[],e}}var nB=["retriesPerformedSoFar"];class nV{constructor(e){this.Pi=!1,this.Li=3e3,this.Ai=[],this._instance=e,this.Ai=[],this.Di=!0,!j(n)&&"onLine"in n.navigator&&(this.Di=n.navigator.onLine,this.Bi=()=>{this.Di=!0,this.ji()},this.qi=()=>{this.Di=!1},io(n,"online",this.Bi),io(n,"offline",this.qi))}get length(){return this.Ai.length}retriableRequest(e){var{retriesPerformedSoFar:t}=e,i=y(e,nB);G(t)&&(i.url=n$(i.url,{retry_count:t})),this._instance._send_request(m({},i,{callback:e=>{200===e.statusCode||e.statusCode>=400&&500>e.statusCode||(null!=t?t:0)>=10?null==i.callback||i.callback(e):this.Zi(m({retriesPerformedSoFar:t},i))}}))}Zi(e){var t,i,n=e.retriesPerformedSoFar||0;e.retriesPerformedSoFar=n+1;var r=Math.ceil((i=Math.min(18e5,t=3e3*Math.pow(2,n)))+(Math.random()-.5)*(i-t/2)),s=Date.now()+r;this.Ai.push({retryAt:s,requestOptions:e});var o="Enqueued failed request for retry in "+r;navigator.onLine||(o+=" (Browser is offline)"),tc.warn(o),this.Pi||(this.Pi=!0,this.$i())}$i(){if(this.Vi&&clearTimeout(this.Vi),0===this.Ai.length)return this.Pi=!1,void(this.Vi=void 0);this.Vi=setTimeout(()=>{this.Di&&this.Ai.length>0&&this.ji(),this.$i()},this.Li)}ji(){var e=Date.now(),t=[],i=this.Ai.filter(i=>e>i.retryAt||(t.push(i),!1));if(this.Ai=t,i.length>0)for(var{requestOptions:n}of i)this.retriableRequest(n)}unload(){for(var{requestOptions:e}of(this.Vi&&(clearTimeout(this.Vi),this.Vi=void 0),this.Pi=!1,j(n)||(this.Bi&&(n.removeEventListener("online",this.Bi),this.Bi=void 0),this.qi&&(n.removeEventListener("offline",this.qi),this.qi=void 0)),this.Ai))try{this._instance._send_request(m({},e,{transport:"sendBeacon"}))}catch(e){tc.error(e)}this.Ai=[]}}class nz{constructor(e){this.Hi=()=>{this.zi||(this.zi={});var e,t,i,n,r=this.scrollElement(),s=this.scrollY(),o=r?Math.max(0,r.scrollHeight-r.clientHeight):0,a=s+((null==r?void 0:r.clientHeight)||0),l=(null==r?void 0:r.scrollHeight)||0;this.zi.lastScrollY=Math.ceil(s),this.zi.maxScrollY=Math.max(s,null!==(e=this.zi.maxScrollY)&&void 0!==e?e:0),this.zi.maxScrollHeight=Math.max(o,null!==(t=this.zi.maxScrollHeight)&&void 0!==t?t:0),this.zi.lastContentY=a,this.zi.maxContentY=Math.max(a,null!==(i=this.zi.maxContentY)&&void 0!==i?i:0),this.zi.maxContentHeight=Math.max(l,null!==(n=this.zi.maxContentHeight)&&void 0!==n?n:0)},this._instance=e}get Ui(){return this._instance.config.scroll_root_selector}getContext(){return this.zi}resetContext(){var e=this.zi;return setTimeout(this.Hi,0),e}startMeasuringScrollPosition(){io(n,"scroll",this.Hi,{capture:!0}),io(n,"scrollend",this.Hi,{capture:!0}),io(n,"resize",this.Hi)}scrollElement(){if(!this.Ui)return null==n?void 0:n.document.documentElement;for(var e of R(this.Ui)?this.Ui:[this.Ui]){var t=null==n?void 0:n.document.querySelector(e);if(t)return t}}scrollY(){if(this.Ui){var e=this.scrollElement();return e&&e.scrollTop||0}return n&&(n.scrollY||n.pageYOffset||n.document.documentElement.scrollTop)||0}scrollX(){if(this.Ui){var e=this.scrollElement();return e&&e.scrollLeft||0}return n&&(n.scrollX||n.pageXOffset||n.document.documentElement.scrollLeft)||0}}var nY=e=>iJ(null==e?void 0:e.config.mask_personal_data_properties,null==e?void 0:e.config.custom_personal_data_properties);
1class nX{constructor(e,t,i,n){this.Yi=e=>{var t=this.Wi();if(!t||t.sessionId!==e){var i={sessionId:e,props:this.Gi(this._instance)};this.Xi.register({[tG]:i})}},this._instance=e,this.Ji=t,this.Xi=i,this.Gi=n||nY,this.Ji.onSessionId(this.Yi)}Wi(){return this.Xi.props[tG]}getSetOnceProps(){var e,t=null==(e=this.Wi())?void 0:e.props;return t?"r"in t?iZ(t):{$referring_domain:t.referringDomain,$pathname:t.initialPathName,utm_source:t.utm_source,utm_campaign:t.utm_campaign,utm_medium:t.utm_medium,utm_content:t.utm_content,utm_term:t.utm_term}:{}}getSessionProps(){var e={};return t6(ir(this.getSetOnceProps()),(t,i)=>{"$current_url"===i&&(i="url"),e["$session_entry_"+k(i)]=t}),e}}class nK{constructor(){this.Ki={}}on(e,t){return this.Ki[e]||(this.Ki[e]=[]),this.Ki[e].push(t),()=>{this.Ki[e]=this.Ki[e].filter(e=>e!==t)}}emit(e,t){for(var i of this.Ki[e]||[])i(t);for(var n of this.Ki["*"]||[])n(e,t)}}var nJ=tu("[SessionId]");class nZ{on(e,t){return this.Qi.on(e,t)}constructor(e,t,i){if(this.tr=[],this.er=void 0,this.Qi=new nK,this.ir=(e,t)=>!(!G(e)||!G(t))&&Math.abs(e-t)>this.sessionTimeoutMs,!e.persistence)throw Error("SessionIdManager requires a PostHogPersistence instance");if(e.config.cookieless_mode===tJ)throw Error('SessionIdManager cannot be used with cookieless_mode="always"');this.Rt=e.config,this.Xi=e.persistence,this.rr=void 0,this.nr=void 0,this._sessionStartTimestamp=null,this._sessionActivityTimestamp=null,this.sr=t||ip,this.ar=i||ip;var n,r=this.Rt.persistence_name||this.Rt.token;if(this._sessionTimeoutMs=1e3*K(this.Rt.session_idle_timeout_seconds||1800,60,36e3,nJ.createLogger("session_idle_timeout_seconds"),1800),e.register({$configured_session_timeout_ms:this._sessionTimeoutMs}),this.lr(),this.ur="ph_"+r+"_window_id",this.hr="ph_"+r+"_primary_window_exists",this.cr()){var s=iI.Gt(this.ur),o=iI.Gt(this.hr);s&&!o?this.rr=s:iI.Jt(this.ur),iI.Xt(this.hr,!0)}if(null!=(n=this.Rt.bootstrap)&&n.sessionID)try{var a=(e=>{var t=this.Rt.bootstrap.sessionID.replace(/-/g,"");if(32!==t.length)throw Error("Not a valid UUID");if("7"!==t[12])throw Error("Not a UUIDv7");return parseInt(t.substring(0,12),16)})();this.dr(this.Rt.bootstrap.sessionID,(new Date).getTime(),a)}catch(e){nJ.error("Invalid sessionID in bootstrap",e)}this.vr()}get sessionTimeoutMs(){return this._sessionTimeoutMs}onSessionId(e){return j(this.tr)&&(this.tr=[]),this.tr.push(e),this.nr&&e(this.nr,this.rr),()=>{this.tr=this.tr.filter(t=>t!==e)}}cr(){return"memory"!==this.Rt.persistence&&!this.Xi.fi&&iI.Ut()}pr(e){e!==this.rr&&(this.rr=e,this.cr()&&iI.Xt(this.ur,e))}gr(){return this.rr?this.rr:this.cr()?iI.Gt(this.ur):null}dr(e,t,i){e===this.nr&&t===this._sessionActivityTimestamp&&i===this._sessionStartTimestamp||(this._sessionStartTimestamp=i,this._sessionActivityTimestamp=t,this.nr=e,this.Xi.register({[tx]:[t,e,i]}))}mr(){var e=this.Xi.props[tx];return R(e)&&2===e.length&&e.push(e[0]),e||[0,null,0]}resetSessionId(){this.dr(null,null,null)}destroy(){clearTimeout(this.yr),this.yr=void 0,this.er&&n&&(n.removeEventListener(t2,this.er,{capture:!1}),this.er=void 0),this.tr=[]}vr(){this.er=()=>{this.cr()&&iI.Jt(this.hr)},io(n,t2,this.er,{capture:!1})}checkAndGetSessionAndWindowId(e,t){if(void 0===e&&(e=!1),void 0===t&&(t=null),this.Rt.cookieless_mode===tJ)throw Error('checkAndGetSessionAndWindowId should not be called with cookieless_mode="always"');var i=t||(new Date).getTime(),[n,r,s]=this.mr(),o=this.gr(),a=G(s)&&Math.abs(i-s)>864e5,l=!1,c=!r,u=!c&&!e&&this.ir(i,n);c||u||a?(r=this.sr(),o=this.ar(),nJ.info("new session ID generated",{sessionId:r,windowId:o,changeReason:{noSessionId:c,activityTimeout:u,sessionPastMaximumLength:a}}),s=i,l=!0):o||(o=this.ar(),l=!0);var d=G(n)&&e&&!a?n:i,h=G(s)?s:(new Date).getTime();return this.pr(o),this.dr(r,d,h),e||this.lr(),l&&this.tr.forEach(e=>e(r,o,l?{noSessionId:c,activityTimeout:u,sessionPastMaximumLength:a}:void 0)),{sessionId:r,windowId:o,sessionStartTimestamp:h,changeReason:l?{noSessionId:c,activityTimeout:u,sessionPastMaximumLength:a}:void 0,lastActivityTimestamp:n}}lr(){clearTimeout(this.yr),this.yr=setTimeout(()=>{var[e]=this.mr();if(this.ir((new Date).getTime(),e)){var t=this.nr;
1this.resetSessionId(),this.Qi.emit("forcedIdleReset",{idleSessionId:t})}},1.1*this.sessionTimeoutMs)}}var nQ=function(e,t){if(!e)return!1;var i=e.userAgent;if(i&&S(i,t))return!0;try{var n=null==e?void 0:e.userAgentData;if(null!=n&&n.brands&&n.brands.some(e=>S(null==e?void 0:e.brand,t)))return!0}catch(e){}return!!e.webdriver},n0=function(e,t){if(!function(e){try{new RegExp(e)}catch(e){return!1}return!0}(t))return!1;try{return new RegExp(t).test(e)}catch(e){return!1}};function n1(e,t,i){return nD({distinct_id:e,userPropertiesToSet:t,userPropertiesToSetOnce:i})}var n2={exact:(e,t)=>t.some(t=>e.some(e=>t===e)),is_not:(e,t)=>t.every(t=>e.every(e=>t!==e)),regex:(e,t)=>t.some(t=>e.some(e=>n0(t,e))),not_regex:(e,t)=>t.every(t=>e.every(e=>!n0(t,e))),icontains:(e,t)=>t.map(n5).some(t=>e.map(n5).some(e=>t.includes(e))),not_icontains:(e,t)=>t.map(n5).every(t=>e.map(n5).every(e=>!t.includes(e))),gt:(e,t)=>t.some(t=>{var i=parseFloat(t);return!isNaN(i)&&e.some(e=>i>parseFloat(e))}),lt:(e,t)=>t.some(t=>{var i=parseFloat(t);return!isNaN(i)&&e.some(e=>i<parseFloat(e))})},n5=e=>e.toLowerCase();function n7(e,t){return!e||Object.entries(e).every(e=>{var[i,n]=e,r=null==t?void 0:t[i];if(j(r)||M(r))return!1;var s=[String(r)],o=n2[n.operator];return!!o&&o(n.values,s)})}var n3="custom",n4="i.posthog.com";class n8{constructor(e){this.br={},this.instance=e}get apiHost(){var e=this.instance.config.api_host.trim().replace(/\/$/,"");return"https://app.posthog.com"===e?"https://us.i.posthog.com":e}get flagsApiHost(){var e=this.instance.config.flags_api_host;return e?e.trim().replace(/\/$/,""):this.apiHost}get uiHost(){var e,t=null==(e=this.instance.config.ui_host)?void 0:e.replace(/\/$/,"");return t||(t=this.apiHost.replace("."+n4,".posthog.com")),"https://app.posthog.com"===t?"https://us.posthog.com":t}get region(){return this.br[this.apiHost]||(this.br[this.apiHost]=/https:\/\/(app|us|us-assets)(\.i)?\.posthog\.com/i.test(this.apiHost)?"us":/https:\/\/(eu|eu-assets)(\.i)?\.posthog\.com/i.test(this.apiHost)?"eu":n3),this.br[this.apiHost]}endpointFor(e,t){if(void 0===t&&(t=""),t&&(t="/"===t[0]?t:"/"+t),"ui"===e)return this.uiHost+t;if("flags"===e)return this.flagsApiHost+t;if(this.region===n3)return this.apiHost+t;var i=n4+t;switch(e){case"assets":return"https://"+this.region+"-assets."+i;case"api":return"https://"+this.region+"."+i}}}var n6=tu("[Surveys]"),n9="seenSurvey_",re=(e,t)=>{var i="$survey_"+t+"/"+e.id;return e.current_iteration&&e.current_iteration>0&&(i="$survey_"+t+"/"+e.id+"/"+e.current_iteration),i},rt=e=>{var t;return t=""+n9+e.id,e.current_iteration&&e.current_iteration>0&&(t=""+n9+e.id+"_"+e.current_iteration),t},ri=[i5.Popover,i5.Widget,i5.API],rn={ignoreConditions:!1,ignoreDelay:!1,displayType:i4.Popover},rr=tu("[PostHog ExternalIntegrations]"),rs={intercom:"intercom-integration",crispChat:"crisp-chat-integration"};class ro{constructor(e){this._instance=e}ni(e,t){var i;null==(i=p.__PosthogExtensions__)||null==i.loadExternalDependency||i.loadExternalDependency(this._instance,e,e=>{if(e)return rr.error("failed to load script",e);t()})}startIfEnabledOrStop(){var e,t=this,i=function(e){var i,n,s;!r||null!=(i=p.__PosthogExtensions__)&&null!=(i=i.integrations)&&i[e]||t.ni(rs[e],()=>{var i;null==(i=p.__PosthogExtensions__)||null==(i=i.integrations)||null==(i=i[e])||i.start(t._instance)}),!r&&null!=(n=p.__PosthogExtensions__)&&null!=(n=n.integrations)&&n[e]&&(null==(s=p.__PosthogExtensions__)||null==(s=s.integrations)||null==(s=s[e])||s.stop())};for(var[n,r]of Object.entries(null!==(e=this._instance.config.integrations)&&void 0!==e?e:{}))i(n)}}var ra,rl,rc={},ru=0,rd=()=>{},rh='Consent opt in/out is not valid with cookieless_mode="always" and will be ignored',rp="Surveys module not available",rg="sanitize_properties is deprecated. Use before_send instead",rv="Invalid value for property_denylist config: ",rf=/^\d+\.\d+\.\d+(?:-[0-9A-Za-z-]+(?:\.[0-9A-Za-z-]+)*)?$/,r_="posthog",rm=!nN&&-1===(null==h?void 0:h.indexOf("MSIE"))&&-1===(null==h?void 0:h.indexOf("Mozilla")),ry=e=>{var t;return m({api_host:"https://us.i.posthog.com",flags_api_host:null,ui_host:null,token:"",autocapture:!0,cross_subdomain_cookie:function(e){var t=null==e?void 0:e.hostname;if(!N(t))return!1;var i=t.split(".").slice(-2).join(".");for(var n of is)if(i===n)return!1;return!0}(null==o?void 0:o.location),persistence:"localStorage+cookie",persistence_name:"",cookie_persisted_properties:[],loaded:rd,save_campaign_params:!0,custom_campaign_params:[],custom_blocked_useragents:[],save_referrer:!0,capture_pageleave:"if_capture_pageview",defaults:null!=e?e:"unset",__preview_deferred_init_extensions:!1,debug:a&&N(null==a?void 0:a.search)&&-1!==a.search.indexOf("__posthog_debug=true")||!1,cookie_expiration:365,upgrade:!1,disable_session_recording:!1,disable_persistence:!1,disable_web_experiments:!0,disable_surveys:!1,disable_surveys_automatic_display:!1,disable_conversations:!1,disable_product_tours:!1,disable_external_dependency_loading:!1,enable_recording_console_log:void 0,secure_cookie:"https:"===(null==n||null==(t=n.location)?void 0:t.protocol),ip:!1,opt_out_capturing_by_default:!1,opt_out_persistence_by_default:!1,opt_out_useragent_filter:!1,opt_out_capturing_persistence_type:"localStorage",consent_persistence_name:null,opt_out_capturing_cookie_prefix:null,opt_in_site_apps:!1,property_denylist:[],respect_dnt:!1,sanitize_properties:null,request_headers:{},request_batching:!0,properties_string_max_length:65535,mask_all_element_attributes:!1,mask_all_text:!1,mask_personal_data_properties:!1,custom_personal_data_properties:[],advanced_disable_flags:!1,advanced_disable_decide:!1,advanced_disable_feature_flags:!1,advanced_disable_feature_flags_on_first_load:!1,advanced_only_evaluate_survey_feature_flags:!1,advanced_feature_flags_dedup_per_session:!1,advanced_enable_surveys:!1,advanced_disable_toolbar_metrics:!1,feature_flag_request_timeout_ms:3e3,surveys_request_timeout_ms:1e4,on_request_error(e){tc.error("Bad HTTP status: "+e.statusCode+" "+e.text)},get_device_id:e=>e,capture_performance:void 0,name:"posthog",bootstrap:{},disable_compression:!1,session_idle_timeout_seconds:1800,person_profiles:t0,before_send:void 0,request_queue_config:{flush_interval_ms:3e3},error_tracking:{},_onCapture:rd,__preview_eager_load_replay:!1},{rageclick:!e||"2025-11-30">e||{content_ignorelist:!0},capture_pageview:!e||"2025-05-24">e||"history_change",session_recording:e&&e>="2025-11-30"?{strictMinimumDuration:!0}:{},external_scripts_inject_target:e&&e>="2026-01-30"?"head":"body",internal_or_test_user_hostname:e&&e>="2026-01-30"?/^(localhost|127\.0\.0\.1)$/:void 0})},rb=[["process_person","person_profiles"],["xhr_headers","request_headers"],["cookie_name","persistence_name"],["disable_cookie","disable_persistence"],["store_google","save_campaign_params"],["verbose","debug"]],rE=e=>{var t={};for(var[i,n]of rb)j(e[i])||(t[n]=e[i]);var r=t9({},t,e);return R(e.property_blacklist)&&(j(e.property_denylist)?r.property_denylist=e.property_blacklist:R(e.property_denylist)?r.property_denylist=[...e.property_blacklist,...e.property_denylist]:tc.error(rv+e.property_denylist)),r};class rw{constructor(){this.__forceAllowLocalhost=!1}get wr(){return this.__forceAllowLocalhost}set wr(e){tc.error("WebPerformanceObserver is deprecated and has no impact on network capture. Use `_forceAllowLocalhostNetworkCapture` on `posthog.sessionRecording`"),this.__forceAllowLocalhost=e}}class rS{_r(e,t){if(e){var i=this.Ir.indexOf(e);-1!==i&&this.Ir.splice(i,1)}return this.Ir.push(t),null==t.initialize||t.initialize(),t}get decideEndpointWasHit(){var e,t;return null!==(e=null==(t=this.featureFlags)?void 0:t.hasLoadedFlags)&&void 0!==e&&e}get flagsEndpointWasHit(){var e,t;return null!==(e=null==(t=this.featureFlags)?void 0:t.hasLoadedFlags)&&void 0!==e&&e}constructor(){this.webPerformance=new rw,this.Cr=!1,this.version=v.LIB_VERSION,this.Sr=new nK,this.Ir=[],this._calculate_event_properties=this.calculateEventProperties.bind(this),this.config=ry(),this.SentryIntegration=ij,this.sentryIntegration=e=>{var t;return t=iL(this,e),{name:iC,processEvent:e=>t(e)}},this.__request_queue=[],this.__loaded=!1,this.analyticsDefaultEndpoint="/e/",this.kr=!1,this.Tr=null,this.Ar=null,this.Er=null,this.scrollManager=new nz(this),this.pageViewM
1anager=new iN(this),this.rateLimiter=new ne(this),this.requestRouter=new n8(this),this.consent=new ik(this),this.externalIntegrations=new ro(this);var e,t=null!==(e=rS.__defaultExtensionClasses)&&void 0!==e?e:{};this.featureFlags=t.featureFlags&&new t.featureFlags(this),this.toolbar=t.toolbar&&new t.toolbar(this),this.surveys=t.surveys&&new t.surveys(this),this.conversations=t.conversations&&new t.conversations(this),this.logs=t.logs&&new t.logs(this),this.experiments=t.experiments&&new t.experiments(this),this.exceptions=t.exceptions&&new t.exceptions(this),this.people={set:(e,t,i)=>{var n=N(e)?{[e]:t}:e;this.setPersonProperties(n),null==i||i({})},set_once:(e,t,i)=>{var n=N(e)?{[e]:t}:e;this.setPersonProperties(void 0,n),null==i||i({})}},this.on("eventCaptured",e=>tc.info('send "'+(null==e?void 0:e.event)+'"',e))}init(e,t,i){if(i&&i!==r_){var n,r=null!==(n=rc[i])&&void 0!==n?n:new rS;return r._init(e,t,i),rc[i]=r,rc[r_][i]=r,r}return this._init(e,t,i)}_init(e,t,i){if(void 0===t&&(t={}),j(e)||F(e))return tc.critical("PostHog was initialized without a token. This likely indicates a misconfiguration. Please check the first argument passed to posthog.init()"),this;if(this.__loaded)return console.warn("[PostHog.js]","You have already initialized PostHog! Re-initializing is a no-op"),this;this.__loaded=!0,this.config={},t.debug=this.Rr(t.debug),this.Nr=t,this.Mr=[],t.person_profiles?this.Ar=t.person_profiles:t.process_person&&(this.Ar=t.process_person),this.set_config(t9({},ry(t.defaults),rE(t),{name:i,token:e})),this.config.on_xhr_error&&tc.error("on_xhr_error is deprecated. Use on_request_error instead"),this.compression=t.disable_compression?void 0:nn.GZipJS;var r,s,o,a,l=this.Fr();this.persistence=new i1(this.config,l),this.sessionPersistence="sessionStorage"===this.config.persistence||"memory"===this.config.persistence?this.persistence:new i1(m({},this.config,{persistence:"sessionStorage"}),l);var c=m({},this.persistence.props),u=m({},this.sessionPersistence.props);this.register({$initialization_time:(new Date).toISOString()}),this.Or=new nq(e=>this.Pr(e),this.config.request_queue_config),this.Lr=new nV(this),this.__request_queue=[];var d=this.config.cookieless_mode===tJ||this.config.cookieless_mode===tK&&this.consent.isExplicitlyOptedOut();d||(this.sessionManager=new nZ(this),this.sessionPropsManager=new nX(this,this.sessionManager,this.persistence));var h=null==(r=p._POSTHOG_REMOTE_CONFIG)||null==(r=r[this.config.token])?void 0:r.config,g=null==h||null==(s=h.sdkVersion)?void 0:s.resolved;if(g&&(rf.test(g)?this._resolvedSdkVersion=g:tc.warn("Ignoring invalid preloaded sdkVersion.resolved from remote config: "+g)),this.config.__preview_deferred_init_extensions?(tc.info("Deferring extension initialization to improve startup performance"),setTimeout(()=>{this.Dr(d)},0)):(tc.info("Initializing extensions synchronously"),this.Dr(d)),v.DEBUG=v.DEBUG||this.config.debug,v.DEBUG&&tc.info("Starting in debug mode",{this:this,config:t,thisC:m({},this.config),p:c,s:u}),!this.config.identity_distinct_id||null!=(o=t.bootstrap)&&o.distinctID||(t.bootstrap=m({},t.bootstrap,{distinctID:this.config.identity_distinct_id,isIdentifiedID:!0})),void 0!==(null==(a=t.bootstrap)?void 0:a.distinctID)){var f=t.bootstrap.distinctID,_=this.get_distinct_id(),y=this.persistence.get_property(tD);if(t.bootstrap.isIdentifiedID&&null!=_&&_!==f&&y===tZ)this.identify(f);else if(t.bootstrap.isIdentifiedID&&null!=_&&_!==f&&y===tQ)tc.warn("Bootstrap distinctID differs from an already-identified user. The existing identity is preserved. Call reset() before reinitializing if you intend to switch users.");else{var b=this.config.get_device_id(ip()),E=t.bootstrap.isIdentifiedID?b:f;this.persistence.set_property(tD,t.bootstrap.isIdentifiedID?tQ:tZ),this.register({distinct_id:f,$device_id:E})}}if(d)this.register_once({distinct_id:tz,$device_id:null},"");else if(!this.get_distinct_id()){var w=this.config.get_device_id(ip());this.register_once({distinct_id:w,$device_id:w},""),this.persistence.set_property(tD,tZ)}return io(n,"onpagehide"in self?"pagehide":"unload",this._handle_unload.bind(this),{passive:!1}),t.segment?function(e,t){var i=e.config.segment;if(!i)return t();!function(e,t){var i=e.config.segment;if(!i)return t();var n=i=>{var n=()=>i.anonymousId()||ip();e.config.get_device_id=n,i.id()&&(e.register({distinct_id:i.id(),$device_id:n()}),e.persistence.set_property(tD,tQ)),t()},r=i.user();"then"in r&&A(r.then)?r.then(n):n(r)}(e,()=>{var n;i.register((Promise&&Promise.resolve||iA.warn("This browser does not have Promise support, and can not use the segment integration"),n=(t,i)=>{if(!i)return t;t.event.userId||t.event.anonymousId===e.get_distinct_id()||(iA.info("No userId set, resetting PostHog"),e.reset()),t.event.userId&&t.event.userId!==e.get_distinct_id()&&(iA.info("UserId set, identifying with PostHog"),e.identify(t.event.userId)
1);var n=e.calculateEventProperties(i,t.event.properties);return t.event.properties=Object.assign({},n,t.event.properties),t},{name:"PostHog JS",type:"enrichment",version:"1.0.0",isLoaded:()=>!0,load:()=>Promise.resolve(),track:e=>n(e,e.event.event),page:e=>n(e,t5),identify:e=>n(e,t3),screen:e=>n(e,"$screen")})).then(()=>{t()})})}(this,()=>this.Br()):this.Br(),A(this.config._onCapture)&&this.config._onCapture!==rd&&(tc.warn("onCapture is deprecated. Please use `before_send` instead"),this.on("eventCaptured",e=>this.config._onCapture(e.event,e))),this.config.ip&&tc.warn('The `ip` config option has NO EFFECT AT ALL and has been deprecated. Use a custom transformation or "Discard IP data" project setting instead. See https://posthog.com/tutorials/web-redact-properties#hiding-customer-ip-address for more information.'),this}Dr(e){var t,i,n,r,s,o,a,l=performance.now(),c=m({},rS.__defaultExtensionClasses,this.config.__extensionClasses),u=[];c.featureFlags&&this.Ir.push(this.featureFlags=null!==(t=this.featureFlags)&&void 0!==t?t:new c.featureFlags(this)),c.exceptions&&this.Ir.push(this.exceptions=null!==(i=this.exceptions)&&void 0!==i?i:new c.exceptions(this)),c.historyAutocapture&&this.Ir.push(this.historyAutocapture=new c.historyAutocapture(this)),c.tracingHeaders&&this.Ir.push(new c.tracingHeaders(this)),c.siteApps&&this.Ir.push(this.siteApps=new c.siteApps(this)),c.sessionRecording&&!e&&this.Ir.push(this.sessionRecording=new c.sessionRecording(this)),this.config.disable_scroll_properties||u.push(()=>{this.scrollManager.startMeasuringScrollPosition()}),c.autocapture&&this.Ir.push(this.autocapture=new c.autocapture(this)),c.surveys&&this.Ir.push(this.surveys=null!==(n=this.surveys)&&void 0!==n?n:new c.surveys(this)),c.logs&&this.Ir.push(this.logs=null!==(r=this.logs)&&void 0!==r?r:new c.logs(this)),c.conversations&&this.Ir.push(this.conversations=null!==(s=this.conversations)&&void 0!==s?s:new c.conversations(this)),c.productTours&&this.Ir.push(this.productTours=new c.productTours(this)),c.heatmaps&&this.Ir.push(this.heatmaps=new c.heatmaps(this)),c.webVitalsAutocapture&&this.Ir.push(this.webVitalsAutocapture=new c.webVitalsAutocapture(this)),c.exceptionObserver&&this.Ir.push(this.exceptionObserver=new c.exceptionObserver(this)),c.deadClicksAutocapture&&this.Ir.push(this.deadClicksAutocapture=new c.deadClicksAutocapture(this,iP)),c.toolbar&&this.Ir.push(this.toolbar=null!==(o=this.toolbar)&&void 0!==o?o:new c.toolbar(this)),c.experiments&&this.Ir.push(this.experiments=null!==(a=this.experiments)&&void 0!==a?a:new c.experiments(this)),this.Ir.forEach(e=>{e.initialize&&u.push(()=>{null==e.initialize||e.initialize()})}),u.push(()=>{if(this.jr){var e=this.jr;this.jr=void 0,this.Ci(e)}}),this.qr(u,l)}qr(e,t){for(;e.length>0;){if(this.config.__preview_deferred_init_extensions&&performance.now()-t>=30&&e.length>0)return void setTimeout(()=>{this.qr(e,t)},0);var i=e.shift();if(i)try{i()}catch(e){tc.error("Error initializing extension:",e)}}var n=Math.round(performance.now()-t);this.register_for_session({$sdk_debug_extensions_init_method:this.config.__preview_deferred_init_extensions?"deferred":"synchronous",$sdk_debug_extensions_init_time_ms:n}),this.config.__preview_deferred_init_extensions&&tc.info("PostHog extensions initialized ("+n+"ms)")}Ci(e){var t;if(!o||!o.body)return tc.info("document not ready yet, trying again in 500 milliseconds..."),void setTimeout(()=>{this.Ci(e)},500);this.config.__preview_deferred_init_extensions&&(this.jr=e),this.compression=void 0,e.supportedCompression&&!this.config.disable_compression&&(this.compression=T(e.supportedCompression,nn.GZipJS)?nn.GZipJS:T(e.supportedCompression,nn.Base64)?nn.Base64:void 0),null!=(t=e.analytics)&&t.endpoint&&(this.analyticsDefaultEndpoint=e.analytics.endpoint),this.set_config({person_profiles:this.Ar?this.Ar:t0}),this.Ir.forEach(t=>null==t.onRemoteConfig?void 0:t.onRemoteConfig(e))}Br(){try{this.config.loaded(this)}catch(e){tc.critical("`loaded` function failed",e)}if(this.Zr(),this.config.internal_or_test_user_hostname&&null!=a&&a.hostname){var e=a.hostname,t=this.config.internal_or_test_user_hostname;("string"==typeof t?e===t:t.test(e))&&this.setInternalOrTestUser()}this.config.capture_pageview&&setTimeout(()=>{(this.consent.isOptedIn()||this.config.cookieless_mode===tJ)&&this.$r()},1),this.Vr=new ni(this),this.Vr.load()}Zr(){var e;this.is_capturing()&&this.config.request_batching&&(null==(e=this.Or)||e.enable())}_dom_loaded(){this.is_capturing()&&t8(this.__request_queue,e=>this.Pr(e)),this.__request_queue=[],this.Zr()}_handle_unload(){var e,t,i,n;null==(e=this.surveys)||e.handlePageUnload(),this.config.request_batching?(this.Hr()&&this.capture(t7),null==(t=this.logs)||t.flushLogs("sendBeacon"),null==(i=this.Or)||i.unload(),null==(n=this.Lr)||n.unload()):this.Hr()&&this.capture(t7,null,{transport:"sendBeacon"})}_send_request(e){this.__loaded&&(rm?this.__request_queue.push(e):this.rateLimiter.isServerRateLimited(e.batchKey)||(e.transport=e.transport||this.config.api_transport,e.url=n$(e.url,{ip:this.config.ip?1:0}),e.headers=m({},this.config.request_headers,e.headers),e.compression="best-available"===e.compression?this.compression:e.compression,e.disableXHRCredentials=this.config.__preview_disable_xhr_credentials,this.config.__preview_disable_beacon&&(e.disableTransport=["sendBeacon"]),e.fetchOptions=e.fetchOptions||this.config.fetch_options,
1(e=>{var t,i,n,r=m({},e);r.timeout=r.timeout||6e4,r.url=nH(r.url,r.compression);var s=null!==(t=r.transport)&&void 0!==t?t:"fetch",o=nW.filter(e=>!r.disableTransport||!e.transport||!r.disableTransport.includes(e.transport)),a=null!==(i=null==(n=function(e,t){for(var i=0;e.length>i;i++)if(e[i].transport===s)return e[i]}(o))?void 0:n.method)&&void 0!==i?i:o[0].method;if(!a)throw Error("No available transport method");"sendBeacon"!==s&&r.data&&r.compression===nn.GZipJS&&d&&!nM?nU(r).then(e=>{a(e)}).catch(t=>{if(!(!t||"object"!=typeof t)&&"NotReadableError"===("name"in t?String(t.name):""))return nM=!0,void a(m({},r,{compression:void 0,url:nH(e.url,void 0)}));a(r)}):a(r)})(m({},e,{callback:t=>{var i,n;this.rateLimiter.checkForLimiting(t),400>t.statusCode||null==(i=(n=this.config).on_request_error)||i.call(n,t),null==e.callback||e.callback(t)}}))))}Pr(e){this.Lr?this.Lr.retriableRequest(e):this._send_request(e)}_execute_array(e){ru++;try{var t,i=[],n=[],r=[];t8(e,e=>{e&&(R(t=e[0])?r.push(e):A(e)?e.call(this):R(e)&&"alias"===t?i.push(e):R(e)&&-1!==t.indexOf("capture")&&A(this[t])?r.push(e):n.push(e))});var s=function(e,t){t8(e,function(e){if(R(e[0])){var i=t;t6(e,function(e){i=i[e[0]].apply(i,e.slice(1))})}else t[e[0]].apply(t,e.slice(1))})};s(i,this),s(n,this),s(r,this)}finally{ru--}}push(e){if(ru>0&&R(e)&&N(e[0])){var t=rS.prototype[e[0]];A(t)&&t.apply(this,e.slice(1))}else this._execute_array([e])}capture(e,t,i){var n,r,s,o,a;if(this.__loaded&&this.persistence&&this.sessionPersistence&&this.Or){if(this.is_capturing()){if(!j(e)&&N(e)){var l=!this.config.opt_out_useragent_filter&&this._is_bot();if(!l||this.config.__preview_capture_bot_pageviews){var c=null!=i&&i.skip_client_rate_limiting?void 0:this.rateLimiter.clientRateLimitContext();if(null==c||!c.isRateLimited){null!=t&&t.$current_url&&!N(null==t?void 0:t.$current_url)&&(tc.error("Invalid `$current_url` property provided to `posthog.capture`. Input must be a string. Ignoring provided value."),null==t||delete t.$current_url),"$exception"!==e||null!=i&&i.zr||tc.warn("Using `posthog.capture('$exception')` is unreliable because it does not attach required metadata. Use `posthog.captureException(error)` instead, which attaches required metadata automatically."),this.sessionPersistence.update_search_keyword(),this.config.save_campaign_params&&this.sessionPersistence.update_campaign_params(),this.config.save_referrer&&this.sessionPersistence.update_referrer_info(),(this.config.save_campaign_params||this.config.save_referrer)&&this.persistence.set_initial_person_info();var u=new Date,d=(null==i?void 0:i.timestamp)||u,h=ip(),p={uuid:h,event:e,properties:this.calculateEventProperties(e,t||{},d,h)};e===t5&&this.config.__preview_capture_bot_pageviews&&l&&(p.event="$bot_pageview",p.properties.$browser_type="bot"),c&&(p.properties.$lib_rate_limit_remaining_tokens=c.remainingTokens),(null==i?void 0:i.$set)&&(p.$set=null==i?void 0:i.$set);var g,v=this.Ur(null==i?void 0:i.$set_once,e!==t4,e===t3);if(v&&(p.$set_once=v),null!=i&&i._noTruncate||(r=this.config.properties_string_max_length,s=p,o=e=>N(e)?e.slice(0,r):e,a=new Set,p=function e(t,i){var n;return t!==Object(t)?o?o(t):t:a.has(t)?void 0:(a.add(t),R(t)?(n=[],t8(t,t=>{n.push(e(t))})):(n={},t6(t,(t,i)=>{a.has(t)||(n[i]=e(t,i))})),n)}(s)),p.timestamp=d,j(null==i?void 0:i.timestamp)||(p.properties.$event_time_override_provided=!0,p.properties.$event_time_override_system_time=u),e===i7.DISMISSED||e===i7.SENT){var f=null==t?void 0:t[i3.SURVEY_ID],_=null==t?void 0:t[i3.SURVEY_ITERATION];g={id:f,current_iteration:_},localStorage.getItem(rt(g))||localStorage.setItem(rt(g),"true"),p.$set=m({},p.$set,{[re({id:f,current_iteration:_},e===i7.SENT?"responded":"dismissed")]:!0})}else e===i7.SHOWN&&(p.$set=m({},p.$set,{[i3.SURVEY_LAST_SEEN_DATE]:(new Date).toISOString()}));if(e===i8.SHOWN){var y=null==t?void 0:t[i6.TOUR_TYPE];y&&(p.$set=m({},p.$set,{[i6.TOUR_LAST_SEEN_DATE+"/"+y]:(new Date).toISOString()}))}var b=m({},p.properties.$set,p.$set);if(L(b)||this.setPersonPropertiesForFlags(b),!$(this.config.before_send)){var E=this.Yr(p);if(!E)return;p=E}this.Sr.emit("eventCaptured",p);var w={method:"POST",url:null!==(n=null==i?void 0:i._url)&&void 0!==n?n:this.requestRouter.endpointFor("api",this.analyticsDefaultEndpoint),data:p,compression:"best-available",batchKey:null==i?void 0:i._batchKey};return!this.config.request_batching||i&&(null==i||!i._batchKey)||null!=i&&i.send_instantly?this.Pr(w):this.Or.enqueue(w),p}tc.critical("This capture call is ignored due to client rate limiting.")}}else tc.error("No event name provided to posthog.capture")}}else tc.uninitializedWarning("posthog.capture")}_addCaptureHook(e){return this.on("eventCaptured",t=>e(t.event,t))}calculateEventProperties(e,t,i,r,s){if(i=i||new Date,!this.persistence||!this.sessionPersistence)return t;var l,c=s?void 0:this.persistence.remove_event_timer(e),u=m({},t);if(u.token=this.config.token,u.$config_defaults=this.config.defaults,(this.config.cookieless_mode==tJ||this.config.cookieless_mode==tK&&this.consent.isExplicitlyOptedOut())&&(u.$cookieless_mode=!0),"$snapshot"===e){var d=m({},this.persistence.properties(),this.sessionPersistence.properties());return u.distinct_id=d.distinct_id,(!N(u.distinct_id)&&!D(u.distinct_id)||F(u.distinct_id))&&tc.error("Invalid distinct_id for replay event. This indicates a bug in your implementation"),u}var p,g=function(e,t){if(!h)return{};var i,r,s,o,l,c,u,d,p,g,f,_=e?[...iU,...t||[]]:[],[m,y]=function(e){for(var t=0;ez.length>t;t++){var[i,n]=ez[t],r=i.exec(e),s=r&&(A(n)?n(r,e):n);if(s)return s}return["",""]}(h);return t9(ir({$os:m,$os_version:y,$browser:eq(h,navigator.vendor),$device:eY(h),$device_type:(c={userAgentDataPlatform:null==(i=navigator)||null==(i=i.userAgentData)?void 0:i.platform,maxTouchPoints:null==(r=navigator)?void 0:r.maxTouchPoints,screenWidth:null==n||null==(s=n.screen)?void 0:s.width,screenHeight:null==n||null==(o=n.screen)?void 0:o.height,devicePixelRatio:null==n?void 0:n.devicePixelRatio},(f=eY(h))===es||f===er||"Kobo"===f||"Kindle Fire"===f||f===eN?en:f===eT||f===ek||f===eI||f===eC?"Console":f===ea?"Wearable":f?et:"Android"===(null==c?void 0:c.userAgentDataPlatform)&&(null!==(u=null==c?void 0:c.maxTouchPoints)&&void 0!==u?u:0)>0?600>Math.min(null!==(d=null==c?void 0:c.screenWidth)&&void 0!==d?d:0,null!==(p=null==c?void 0:c.screenHeight)&&void 0!==p?p:0)/(null!==(g=null==c?void 0:c.devicePixelRatio)&&void 0!==g?g:1)?et:en:"Desktop"),$timezone:iQ(),$timezone_offset:function(){try{return(new Date).getTimezoneOffset()}catch(e){return}}()}),{$current_url:i$(null==a?void 0:a.href,_,iW),$host:null==a?void 0:a.host,$pathname:null==a?void 0:a.pathname,$raw_user_agent:h.length>1e3?h.substring(0,997)+"...":h,$browser_version:eV(h,navigator.vendor),$browser_language:iY(),$browser_language_prefix:"string"==typeof(l=iY())?l.split("-")[0]:void 0,$screen_height:null==n?void 0:n.screen.height,$screen_width:null==n?void 0:n.screen.width,$viewport_height:null==n?void 0:n.innerHeight,$viewport_width:null==n?void 0:n.innerWidth,$lib:v.LIB_NAME,$lib_version:v.LIB_VERSION,$insert_id:Math.random().toString(36).substring(2,10)+Math.random().toString(36).substring(2,10),$time:Date.now()/1e3})}(this.config.mask_personal_data_properties,this.config.custom_personal_data_properties);if(this.sessionManager){var{sessionId:f,windowId:_}=this.sessionManager.checkAndGetSessionAndWindowId(s,i.getTime());u.$session_id=f,u.$window_id=_}this.sessionPropsManager&&t9(u,this.sessionPropsManager.getSessionProps());try{this.sessionRecording&&t9(u,this.sessionRecording.sdkDebugProperties),u.$sdk_debug_retry_queue_size=null==(l=this.Lr)?void 0:l.length}catch(e){u.$sdk_debug_error_capturing_properties=String(e)}if(this.requestRouter.region===n3&&(u.$lib_custom_api_host=this.config.api_host),p=e!==t5||s?e!==t7||s?this.pageViewM
1anager.doEvent():this.pageViewManager.doPageLeave(i):this.pageViewManager.doPageView(i,r),u=t9(u,p),e===t5&&o&&(u.title=o.title),!j(c)){var y=i.getTime()-c;u.$duration=parseFloat((y/1e3).toFixed(3))}h&&this.config.opt_out_useragent_filter&&(u.$browser_type=this._is_bot()?"bot":"browser"),(u=t9({},g,this.persistence.properties(),this.sessionPersistence.properties(),u)).$is_identified=this._isIdentified(),R(this.config.property_denylist)?t6(this.config.property_denylist,function(e){delete u[e]}):tc.error(rv+this.config.property_denylist+" or property_blacklist config: "+this.config.property_blacklist);var b=this.config.sanitize_properties;b&&(tc.error(rg),u=b(u,e));var E=this.Wr();return u.$process_person_profile=E,E&&!s&&this.Gr("_calculate_event_properties"),u}Ur(e,t,i){if(void 0===t&&(t=!0),void 0===i&&(i=!1),!this.persistence||!this.Wr()||this.Cr&&!i)return e;var n,r=t9({},this.persistence.get_initial_props(),(null==(n=this.sessionPropsManager)?void 0:n.getSetOnceProps())||{},e||{}),s=this.config.sanitize_properties;return s&&(tc.error(rg),r=s(r,"$set_once")),t&&(this.Cr=!0),L(r)?void 0:r}register(e,t){var i;null==(i=this.persistence)||i.register(e,t)}register_once(e,t,i){var n;null==(n=this.persistence)||n.register_once(e,t,i)}register_for_session(e){var t;null==(t=this.sessionPersistence)||t.register(e)}unregister(e){var t;null==(t=this.persistence)||t.unregister(e)}unregister_for_session(e){var t;null==(t=this.sessionPersistence)||t.unregister(e)}Xr(e,t){this.register({[e]:t})}getFeatureFlag(e,t){var i;return null==(i=this.featureFlags)?void 0:i.getFeatureFlag(e,t)}getFeatureFlagPayload(e){var t;return null==(t=this.featureFlags)?void 0:t.getFeatureFlagPayload(e)}getFeatureFlagResult(e,t){var i;return null==(i=this.featureFlags)?void 0:i.getFeatureFlagResult(e,t)}isFeatureEnabled(e,t){var i;return null==(i=this.featureFlags)?void 0:i.isFeatureEnabled(e,t)}reloadFeatureFlags(){var e;null==(e=this.featureFlags)||e.reloadFeatureFlags()}updateFlags(e,t,i){var n;null==(n=this.featureFlags)||n.updateFlags(e,t,i)}updateEarlyAccessFeatureEnrollment(e,t,i){var n;null==(n=this.featureFlags)||n.updateEarlyAccessFeatureEnrollment(e,t,i)}getEarlyAccessFeatures(e,t,i){var n;return void 0===t&&(t=!1),null==(n=this.featureFlags)?void 0:n.getEarlyAccessFeatures(e,t,i)}on(e,t){return this.Sr.on(e,t)}onFeatureFlags(e){return this.featureFlags?this.featureFlags.onFeatureFlags(e):(e([],{},{errorsLoading:!0}),()=>{})}onSurveysLoaded(e){return this.surveys?this.surveys.onSurveysLoaded(e):(e([],{isLoaded:!1,error:rp}),()=>{})}onSessionId(e){var t,i;return null!==(t=null==(i=this.sessionManager)?void 0:i.onSessionId(e))&&void 0!==t?t:()=>{}}getSurveys(e,t){void 0===t&&(t=!1),this.surveys?this.surveys.getSurveys(e,t):e([],{isLoaded:!1,error:rp})}getActiveMatchingSurveys(e,t){void 0===t&&(t=!1),this.surveys?this.surveys.getActiveMatchingSurveys(e,t):e([],{isLoaded:!1,error:rp})}renderSurvey(e,t){var i;null==(i=this.surveys)||i.renderSurvey(e,t)}displaySurvey(e,t){var i;void 0===t&&(t=rn),null==(i=this.surveys)||i.displaySurvey(e,t)}cancelPendingSurvey(e){var t;null==(t=this.surveys)||t.cancelPendingSurvey(e)}canRenderSurvey(e){var t,i;return null!==(t=null==(i=this.surveys)?void 0:i.canRenderSurvey(e))&&void 0!==t?t:{visible:!1,disabledReason:rp}}canRenderSurveyAsync(e,t){var i,n;return void 0===t&&(t=!1),null!==(i=null==(n=this.surveys)?void 0:n.canRenderSurveyAsync(e,t))&&void 0!==i?i:Promise.resolve({visible:!1,disabledReason:rp})}Jr(e){return!e||F(e)?(tc.critical("Unique user id has not been set in posthog.identify"),!1):e===tz?(tc.critical('The string "'+e+'" was set in posthog.identify which indicates an error. This ID is only used as a sentinel value.'),!1):!["distinct_id","distinctid"].includes(e.toLowerCase())&&!["undefined","null"].includes(e.toLowerCase())||(tc.critical('The string "'+e+'" was set in posthog.identify which indicates an error. This ID should be unique to the user and not a hardcoded string.'),!1)}identify(e,t,i){if(!this.__loaded||!this.persistence)return tc.uninitializedWarning("posthog.identify");if(D(e)&&(e=e.toString(),tc.warn("The first argument to posthog.identify was a number, but it should be a string. It has been converted to a string.")),this.Jr(e)&&this.Gr("posthog.identify")){var n=this.get_distinct_id();this.register({$user_id:e}),this.get_property(tg)||this.register_once({$had_persisted_distinct_id:!0,$device_id:n},""),e!==n&&e!==this.get_property(tv)&&(this.unregister(tv),this.register({distinct_id:e}));var r,s=(this.persistence.get_property(tD)||tZ)===tZ;e!==n&&s?(this.persistence.set_property(tD,tQ),this.setPersonPropertiesForFlags({$set:t||{},$set_once:i||{}},!1),this.capture(t3,{distinct_id:e,$anon_distinct_id:n},{$set:t||{},$set_once:i||{}}),this.Er=n1(e,t,i),null==(r=this.featureFlags)||r.setAnonymousDistinctId(n)):(t||i)&&this.setPersonProperties(t,i),e!==n&&(this.reloadFeatureFlags(),this.unregister(tN))}}setPersonProperties(e,t){if((e||t)&&this.Gr("posthog.setPersonProperties")){var i=n1(this.get_distinct_id(),e,t);this.Er!==i?(this.setPersonPropertiesForFlags({$set:e||{},$set_once:t||{}},!0),this.capture("$set",{$set:e||{},$set_once:t||{}}),this.Er=i):tc.info("A duplicate setPersonProperties call was made with the same properties. It has been ignored.")}}group(e,t,i){if(e&&t){var n=this.getGroups(),r=n[e]!==t;if(r&&this.resetGroupPropertiesForFlags(e),this.register({$groups:m({},n,{[e]:t})}),r||i){var s={$group_type:e,$group_key:t};
1i&&(s.$group_set=i),this.capture(t4,s)}i&&this.setGroupPropertiesForFlags({[e]:i}),r&&!i&&this.reloadFeatureFlags()}else tc.error("posthog.group requires a group type and group key")}resetGroups(){this.register({$groups:{}}),this.resetGroupPropertiesForFlags(),this.reloadFeatureFlags()}setPersonPropertiesForFlags(e,t){var i;void 0===t&&(t=!0),null==(i=this.featureFlags)||i.setPersonPropertiesForFlags(e,t)}resetPersonPropertiesForFlags(){var e;null==(e=this.featureFlags)||e.resetPersonPropertiesForFlags()}setGroupPropertiesForFlags(e,t){var i;void 0===t&&(t=!0),this.Gr("posthog.setGroupPropertiesForFlags")&&(null==(i=this.featureFlags)||i.setGroupPropertiesForFlags(e,t))}resetGroupPropertiesForFlags(e){var t;null==(t=this.featureFlags)||t.resetGroupPropertiesForFlags(e)}reset(e){if(tc.info("reset"),!this.__loaded)return tc.uninitializedWarning("posthog.reset");var t,i,n,r,s,o,a,l,c=this.get_property(tg);if(this.consent.reset(),null==(t=this.persistence)||t.clear(),null==(i=this.sessionPersistence)||i.clear(),null==(n=this.surveys)||n.reset(),null==(r=this.Vr)||r.stop(),null==(s=this.featureFlags)||s.reset(),null==(o=this.conversations)||o.reset(),null==(a=this.persistence)||a.set_property(tD,tZ),null==(l=this.sessionManager)||l.resetSessionId(),this.Er=null,this.config.cookieless_mode===tJ)this.register_once({distinct_id:tz,$device_id:null},"");else{var u=this.config.get_device_id(ip());this.register_once({distinct_id:u,$device_id:e?u:c},"")}this.register({$last_posthog_reset:(new Date).toISOString()},1),delete this.config.identity_distinct_id,delete this.config.identity_hash,this.reloadFeatureFlags()}setIdentity(e,t){var i;this.config.identity_distinct_id=e,this.config.identity_hash=t,this.alias(e),null==(i=this.conversations)||i.Kr()}clearIdentity(){var e;delete this.config.identity_distinct_id,delete this.config.identity_hash,null==(e=this.conversations)||e.Qr()}get_distinct_id(){return this.get_property("distinct_id")}getGroups(){return this.get_property("$groups")||{}}get_session_id(){var e,t;return null!==(e=null==(t=this.sessionManager)?void 0:t.checkAndGetSessionAndWindowId(!0).sessionId)&&void 0!==e?e:""}get_session_replay_url(e){if(!this.sessionManager)return"";var{sessionId:t,sessionStartTimestamp:i}=this.sessionManager.checkAndGetSessionAndWindowId(!0),n=this.requestRouter.endpointFor("ui","/project/"+this.config.token+"/replay/"+t);if(null!=e&&e.withTimestamp&&i){var r,s=null!==(r=e.timestampLookBack)&&void 0!==r?r:10;if(!i)return n;n+="?t="+Math.max(Math.floor(((new Date).getTime()-i)/1e3)-s,0)}return n}alias(e,t){return e===this.get_property(tp)?(tc.critical("Attempting to create alias for existing People user - aborting."),-2):this.Gr("posthog.alias")?(j(t)&&(t=this.get_distinct_id()),e!==t?(this.Xr(tv,e),this.capture("$create_alias",{alias:e,distinct_id:t})):(tc.warn("alias matches current distinct_id - skipping api call."),this.identify(e),-1)):void 0}set_config(e){var t=m({},this.config);if(C(e)){t9(this.config,rE(e));var i,n,r,s,o,a,l,c,u,d=this.Fr();null==(i=this.persistence)||i.update_config(this.config,t,d),this.sessionPersistence="sessionStorage"===this.config.persistence||"memory"===this.config.persistence?this.persistence:new i1(m({},this.config,{persistence:"sessionStorage"}),d);var h=this.Rr(this.config.debug);U(h)&&(this.config.debug=h),U(this.config.debug)&&(this.config.debug?(v.DEBUG=!0,ib.Ut()&&ib.Xt("ph_debug",!0),tc.info("set_config",{config:e,oldConfig:t,newConfig:m({},this.config)})):(v.DEBUG=!1,ib.Ut()&&ib.Jt("ph_debug"))),null==(n=this.exceptionObserver)||n.onConfigChange(),null==(r=this.sessionRecording)||r.startIfEnabledOrStop(),null==(s=this.autocapture)||s.startIfEnabled(),null==(o=this.heatmaps)||o.startIfEnabled(),null==(a=this.exceptionObserver)||a.startIfEnabledOrStop(),null==(l=this.deadClicksAutocapture)||l.startIfEnabledOrStop(),null==(c=this.surveys)||c.loadIfEnabled(),this.tn(),null==(u=this.externalIntegrations)||u.startIfEnabledOrStop()}}_overrideSDKInfo(e,t){v.LIB_NAME=e,v.LIB_VERSION=t}startSessionRecording(e){var t,i,n,r,s,o=!0===e,a={sampling:o||!(null==e||!e.sampling),linked_flag:o||!(null==e||!e.linked_flag),url_trigger:o||!(null==e||!e.url_trigger),event_trigger:o||!(null==e||!e.event_trigger)};Object.values(a).some(Boolean)&&(null==(t=this.sessionManager)||t.checkAndGetSessionAndWindowId(),a.sampling&&(null==(i=this.sessionRecording)||i.overrideSampling()),a.linked_flag&&(null==(n=this.sessionRecording)||n.overrideLinkedFlag()),a.url_trigger&&(null==(r=this.sessionRecording)||r.overrideTrigger("url")),a.event_trigger&&(null==(s=this.sessionRecording)||s.overrideTrigger("event"))),this.set_config({disable_session_recording:!1})}stopSessionRecording(){this.set_config({disable_session_recording:!0})}sessionRecordingStarted(){var e;return!(null==(e=this.sessionRecording)||!e.started)}captureException(e,t){if(this.exceptions){var i=Error("PostHog syntheticException"),n=this.exceptions.buildProperties(e,{handled:!0,syntheticException:i});return this.exceptions.sendExceptionEvent(m({},n,t))}}captureLog(e){var t;null==(t=this.logs)||t.captureLog(e)}get logger(){var e,t;return null!==(e=null==(t=this.logs)?void 0:t.logger)&&void 0!==e?e:rS.en}startExceptionAutocapture(e){this.set_config({capture_exceptions:null==e||e})}stopExceptionAutocapture(){this.set_config({capture_exceptions:!1})}loadToolbar(e){var t,i;return null!==(t=null==(i=this.toolbar)?void 0:i.loadToolbar(e))&&void 0!==t&&t}get_property(e){var t;return null==(t=this.persistence)?void 0:t.props[e]}getSessionProperty(e){var t;return null==(t=this.sessionPersistence)?void 0:t.props[e]}toString(){var e,t=null!==(e=this.config.name)&&void 0!==e?e:r_;return t!==r_&&(t=r_+"."+t),t}_isIdentified(){var e,t;return(null==(e=this.persistence)?void 0:e.get_property(tD))===tQ||(null==(t=this.sessionPersistence)?void 0:t.get_property(tD))===tQ}Wr(){var e,t;return!("never"===this.config.person_profiles||this.config.person_profiles===t0&&!this._isIdentified()&&L(this.getGroups())&&(null==(e=this.persistence)||null==(e=e.props)||!e[tv])&&(null==(t=this.persistence)||null==(t=t.props)||!t[tB]))}Hr(){return!0===this.config.capture_pageleave||"if_capture_pageview"===this.config.capture_pageleave&&(!0===this.config.capture_pageview||"history_change"===this.config.capture_pageview)}createPersonProfile(){this.Wr()||this.Gr("posthog.createPersonProfile")&&this.setPersonProperties({},{})}setInternalOrTestUser(){this.Gr("posthog.setInternalOrTestUser")&&this.setPersonProperties({$internal_or_test_user:!0})}Gr(e){return"never"===this.config.person_profiles?(tc.error(e+' was called, but process_person is set to "never". This call will be ignored.'),!1):(this.Xr(tB,!0),!0)}Fr(){if("always"===this.config.cookieless_mode)return!0;var e=this.consent.isOptedOut();return this.config.disable_persistence||e&&!(!this.config.opt_out_persistence_by_default&&this.config.cookieless_mode!==tK)}tn(){var e,t,i,n,r=this.Fr();return(null==(e=this.persistence)?void 0:e.fi)!==r&&(null==(i=this.persistence)||i.set_disabled(r)),(null==(t=this.sessionPersistence)?void 0:t.fi)!==r&&(null==(n=this.sessionPersistence)||n.set_disabled(r)),r}opt_in_capturing(e){var t;if(this.config.cookieless_mode!==tJ){if(this.config.cookieless_mode===tK&&this.consent.isExplicitlyOptedOut()){this.reset(!0),null==(r=this.sessionManager)||r.destroy(),null==(s=this.pageViewM
1anager)||s.destroy(),this.sessionManager=new nZ(this),this.pageViewManager=new iN(this),this.persistence&&(this.sessionPropsManager=new nX(this,this.sessionManager,this.persistence));var i,n,r,s,o,a,l,c=null!==(o=null==(a=this.config.__extensionClasses)?void 0:a.sessionRecording)&&void 0!==o?o:null==(l=rS.__defaultExtensionClasses)?void 0:l.sessionRecording;c&&(this.sessionRecording=this._r(this.sessionRecording,new c(this)))}this.consent.optInOut(!0),this.tn(),this.Zr(),null==(t=this.sessionRecording)||t.startIfEnabledOrStop(),this.config.cookieless_mode==tK&&(null==(i=this.surveys)||i.loadIfEnabled()),(j(null==e?void 0:e.captureEventName)||null!=e&&e.captureEventName)&&this.capture(null!==(n=null==e?void 0:e.captureEventName)&&void 0!==n?n:"$opt_in",null==e?void 0:e.captureProperties,{send_instantly:!0}),this.config.capture_pageview&&this.$r()}else tc.warn(rh)}opt_out_capturing(){var e,t,i;this.config.cookieless_mode!==tJ?(this.config.cookieless_mode===tK&&this.consent.isOptedIn()&&this.reset(!0),this.consent.optInOut(!1),this.tn(),this.config.cookieless_mode===tK&&(this.register({distinct_id:tz,$device_id:null}),null==(e=this.sessionManager)||e.destroy(),null==(t=this.pageViewManager)||t.destroy(),this.sessionManager=void 0,this.sessionPropsManager=void 0,null==(i=this.sessionRecording)||i.stopRecording(),this.sessionRecording=void 0,this.$r())):tc.warn(rh)}has_opted_in_capturing(){return this.consent.isOptedIn()}has_opted_out_capturing(){return this.consent.isOptedOut()}get_explicit_consent_status(){var e=this.consent.consent;return 1===e?"granted":0===e?"denied":"pending"}is_capturing(){return this.config.cookieless_mode===tJ||(this.config.cookieless_mode===tK?this.consent.isExplicitlyOptedOut()||this.consent.isOptedIn():!this.has_opted_out_capturing())}clear_opt_in_out_capturing(){this.consent.reset(),this.tn()}_is_bot(){return s?nQ(s,this.config.custom_blocked_useragents):void 0}$r(){o&&("visible"===o.visibilityState?this.kr||(this.kr=!0,this.capture(t5,{title:o.title},{send_instantly:!0}),this.Tr&&(o.removeEventListener(t1,this.Tr),this.Tr=null)):this.Tr||(this.Tr=this.$r.bind(this),io(o,t1,this.Tr)))}debug(e){!1===e?(null==n||n.console.log("You've disabled debug mode."),this.set_config({debug:!1})):(null==n||n.console.log("You're now in debug mode. All calls to PostHog will be logged in your console.\nYou can disable this with `posthog.debug(false)`."),this.set_config({debug:!0}))}ki(){var e,t,i,n,r=this.Nr||{};return"advanced_disable_flags"in r?!!r.advanced_disable_flags:!1!==this.config.advanced_disable_flags?!!this.config.advanced_disable_flags:!0===this.config.advanced_disable_decide?(tc.warn("Config field 'advanced_disable_decide' is deprecated. Please use 'advanced_disable_flags' instead. The old field will be removed in a future major version."),!0):(t="advanced_disable_decide",i=(e="advanced_disable_flags")in r&&!$(r[e]),n=t in r&&!$(r[t]),i?r[e]:!!n&&(tc&&tc.warn("Config field '"+t+"' is deprecated. Please use '"+e+"' instead. The old field will be removed in a future major version."),r[t]))}Yr(e){if($(this.config.before_send))return e;var t=R(this.config.before_send)?this.config.before_send:[this.config.before_send],i=e;for(var n of t){if($(i=n(i))){var r="Event '"+e.event+"' was rejected in beforeSend function";return W(e.event)?tc.warn(r+". This can cause unexpected behavior."):tc.info(r),null}i.properties&&!L(i.properties)||tc.warn("Event '"+e.event+"' has no properties after beforeSend function, this is likely an error.")}return i}getPageViewId(){var e;return null==(e=this.pageViewManager.ai)?void 0:e.pageViewId}captureTraceFeedback(e,t){this.capture("$ai_feedback",{$ai_trace_id:String(e),$ai_feedback_text:t})}captureTraceMetric(e,t,i){this.capture("$ai_metric",{$ai_trace_id:String(e),$ai_metric_name:t,$ai_metric_value:String(i)})}Rr(e){var t=U(e)&&!e,i=ib.Ut()&&"true"===ib.Wt("ph_debug");return!t&&(!!i||e)}}function rT(e){return e instanceof Element&&(e.id===tV||!(null==e.closest||!e.closest(".toolbar-global-fade-container")))}function rI(e){return!!e&&1===e.nodeType}function rk(e,t){return!!e&&!!e.tagName&&e.tagName.toLowerCase()===t.toLowerCase()}
1function rx(e){return!!e&&3===e.nodeType}function rO(e){return!!e&&11===e.nodeType}function rP(e){return e?I(e).split(/\s+/):[]}function rR(e){var t=null==n?void 0:n.location.href;return!!(t&&e&&e.some(e=>t.match(e)))}function rA(e){var t="";switch(typeof e.className){case"string":t=e.className;break;case"object":t=(e.className&&"baseVal"in e.className?e.className.baseVal:null)||e.getAttribute("class")||"";break;default:t=""}return rP(t)}function rC(e){return $(e)?null:I(e).split(/(\s+)/).filter(e=>rK(e)).join("").replace(/[\r\n]/g," ").replace(/[ ]+/g," ").substring(0,255)}function rL(e){var t="";return rH(e)&&!rW(e)&&e.childNodes&&e.childNodes.length&&t6(e.childNodes,function(e){var i;rx(e)&&e.textContent&&(t+=null!==(i=rC(e.textContent))&&void 0!==i?i:"")}),I(t)}function rj(e){var t;return j(e.target)?e.srcElement||null:null!=(t=e.target)&&t.shadowRoot?e.composedPath()[0]||null:e.target||null}rS.__defaultExtensionClasses={},rS.en={trace:rl=()=>{},debug:rl,info:rl,warn:rl,error:rl,fatal:rl},function(e,t){for(var i=0;t.length>i;i++)e.prototype[t[i]]=ii(e.prototype[t[i]])}(rS,["identify"]);var rN=["a","button","form","input","select","textarea","label"];function rF(e,t){if(j(t))return!0;var i,n=function(e){if(t.some(t=>e.matches(t)))return{v:!0}};for(var r of e)if(i=n(r))return i.v;return!1}function rM(e){var t=e.parentNode;return!(!t||!rI(t))&&t}var r$=["next","previous","prev",">","<"],rD=[".ph-no-rageclick",".ph-no-capture"],rG=e=>!e||rk(e,"html")||!rI(e),rU=(e,t)=>{if(!n||rG(e))return{parentIsUsefulElement:!1,targetElementList:[]};for(var i=!1,r=[e],s=e;s.parentNode&&!rk(s,"body");)if(rO(s.parentNode))r.push(s.parentNode.host),s=s.parentNode.host;else{var o=rM(s);if(!o)break;if(t||rN.indexOf(o.tagName.toLowerCase())>-1)i=!0;else{var a=n.getComputedStyle(o);a&&"pointer"===a.getPropertyValue("cursor")&&(i=!0)}r.push(o),s=o}return{parentIsUsefulElement:i,targetElementList:r}};function rH(e){for(var t=e;t.parentNode&&!rk(t,"body");t=t.parentNode){var i=rA(t);if(T(i,"ph-sensitive")||T(i,"ph-no-capture"))return!1}if(T(rA(e),"ph-include"))return!0;var n=e.type||"";if(N(n))switch(n.toLowerCase()){case"hidden":case"password":return!1}var r=e.name||e.id||"";return!N(r)||!/^cc|cardnum|ccnum|creditcard|csc|cvc|cvv|exp|pass|pwd|routing|seccode|securitycode|securitynum|socialsec|socsec|ssn/i.test(r.replace(/[^a-zA-Z0-9]/g,""))}function rW(e){return!!(rk(e,"input")&&!["button","checkbox","submit","reset"].includes(e.type)||rk(e,"select")||rk(e,"textarea")||"true"===e.getAttribute("contenteditable"))}var rq="(4[0-9]{12}(?:[0-9]{3})?)|(5[1-5][0-9]{14})|(6(?:011|5[0-9]{2})[0-9]{12})|(3[47][0-9]{13})|(3(?:0[0-5]|[68][0-9])[0-9]{11})|((?:2131|1800|35[0-9]{3})[0-9]{11})",rB=RegExp("^(?:"+rq+")$"),rV=new RegExp(rq),rz="\\d{3}-?\\d{2}-?\\d{4}",rY=RegExp("^("+rz+")$"),rX=RegExp("("+rz+")");function rK(e,t){return void 0===t&&(t=!0),!($(e)||N(e)&&(e=I(e),(t?rB:rV).test((e||"").replace(/[- ]/g,""))||(t?rY:rX).test(e)))}function rJ(e){var t=rL(e);return rK(t=(t+" "+function e(t){var i="";return t&&t.childNodes&&t.childNodes.length&&t6(t.childNodes,function(t){var n;if(t&&"span"===(null==(n=t.tagName)?void 0:n.toLowerCase()))try{var r=rL(t);i=(i+" "+r).trim(),t.childNodes&&t.childNodes.length&&(i=(i+" "+e(t)).trim())}catch(e){tc.error("[AutoCapture]",e)}}),i}(e)).trim())?t:""}function rZ(e){return e.replace(/"|\\"/g,'\\"')}class rQ{constructor(e){this.disabled=!1===e;var t=C(e)?e:{};this.thresholdPx=t.threshold_px||30,this.timeoutMs=t.timeout_ms||1e3,this.clickCount=t.click_count||3,this.clicks=[]}isRageClick(e,t,i){if(this.disabled)return!1;var n=this.clicks[this.clicks.length-1];if(n&&Math.abs(e-n.x)+Math.abs(t-n.y)<this.thresholdPx&&this.timeoutMs>i-n.timestamp){if(this.clicks.push({x:e,y:t,timestamp:i}),this.clicks.length===this.clickCount)return!0}else this.clicks=[{x:e,y:t,timestamp:i}];return!1}}var r0="$copy_autocapture",r1=tu("[AutoCapture]");function r2(e,t){return t.length>e?t.slice(0,e)+"...":t}var r5=tu("[ExceptionAutocapture]");function r7(e,t,i){try{if(!(t in e))return()=>{};var n=e[t],r=i(n);return A(r)&&(r.prototype=r.prototype||{},Object.defineProperties(r,{__posthog_wrapped__:{enumerable:!1,value:!0}})),e[t]=r,()=>{e[t]=n}}catch(e){return()=>{}}}var r3=tu("[TracingHeaders]"),r4=tu("[Web Vitals]"),r8="disabled",r6="lazy_loading",r9="awaiting_config",se="missing_config";tu("[SessionRecording]");var st="[SessionRecording]",si=tu(st),sn=tu("[Heatmaps]");function sr(e){return C(e)&&"clientX"in e&&"clientY"in e&&D(e.clientX)&&D(e.clientY)}var ss=tu("[Product Tours]"),so="ph_product_tours",sa=["$set_once","$set"],sl=tu("[SiteApps]"),sc="Error while initializing PostHog app with config id ";function su(e,t,i){if($(e))return!1;switch(i){case"exact":return e===t;case"contains":return RegExp(t.replace(/[.*+?^${}()|[\]\\]/g,"\\$&").replace(/_/g,".").replace(/%/g,".*"),"i").test(e);case"regex":try{return new RegExp(t).test(e)}catch(e){return!1}default:return!1}}class sd{constructor(e){this.rn=new nK,this.nn=(e,t)=>this.sn(e,t)&&this.an(e,t)&&this.ln(e,t)&&this.un(e,t),this.sn=(e,t)=>null==t||!t.event||(null==e?void 0:e.event)===(null==t?void 0:t.event),this._instance=e,this.hn=new Set,this.cn=new Set}init(){var e,t;j(null==(e=this._instance)?void 0:e._addCaptureHook)||null==(t=this._instance)||t._addCaptureHook((e,t)=>{this.on(e,t)})}register(e){var t,i;if(!j(null==(t=this._instance)?void 0:t._addCaptureHook)&&(e.forEach(e
1=>{var t,i;null==(t=this.cn)||t.add(e),null==(i=e.steps)||i.forEach(e=>{var t;null==(t=this.hn)||t.add((null==e?void 0:e.event)||"")})}),null!=(i=this._instance)&&i.autocapture)){var n,r=new Set;e.forEach(e=>{var t;null==(t=e.steps)||t.forEach(e=>{null!=e&&e.selector&&r.add(null==e?void 0:e.selector)})}),null==(n=this._instance)||n.autocapture.setElementSelectors(r)}}on(e,t){var i;null!=t&&0!=e.length&&(this.hn.has(e)||this.hn.has(null==t?void 0:t.event))&&this.cn&&(null==(i=this.cn)?void 0:i.size)>0&&this.cn.forEach(e=>{this.dn(t,e)&&this.rn.emit("actionCaptured",e.name)})}vn(e){this.onAction("actionCaptured",t=>e(t))}dn(e,t){if(null==(null==t?void 0:t.steps))return!1;for(var i of t.steps)if(this.nn(e,i))return!0;return!1}onAction(e,t){return this.rn.on(e,t)}an(e,t){if(null!=t&&t.url){var i,n=null==e||null==(i=e.properties)?void 0:i.$current_url;if(!n||"string"!=typeof n||!su(n,t.url,t.url_matching||"contains"))return!1}return!0}ln(e,t){return!!this.fn(e,t)&&!!this.pn(e,t)&&!!this.gn(e,t)}fn(e,t){if(null==t||!t.href)return!0;var i=this.mn(e);if(i.length>0)return i.some(e=>su(e.href,t.href,t.href_matching||"exact"));var n,r,s=(null==e||null==(n=e.properties)?void 0:n.$elements_chain)||"";return!!s&&su((r=s.match(/(?::|")href="(.*?)"/))?r[1]:"",t.href,t.href_matching||"exact")}pn(e,t){if(null==t||!t.text)return!0;var i=this.mn(e);if(i.length>0)return i.some(e=>su(e.text,t.text,t.text_matching||"exact")||su(e.$el_text,t.text,t.text_matching||"exact"));var n,r,s,o,a=(null==e||null==(n=e.properties)?void 0:n.$elements_chain)||"";return!!a&&(r=function(e){for(var t,i=[],n=/(?::|")text="(.*?)"/g;!$(t=n.exec(e));)i.includes(t[1])||i.push(t[1]);return i}(a),s=t.text,o=t.text_matching||"exact",r.some(e=>su(e,s,o)))}gn(e,t){if(null==t||!t.selector)return!0;var i,n,r=null==e||null==(i=e.properties)?void 0:i.$element_selectors;if(null!=r&&r.includes(t.selector))return!0;var s=(null==e||null==(n=e.properties)?void 0:n.$elements_chain)||"";if(t.selector_regex&&s)try{return new RegExp(t.selector_regex).test(s)}catch(e){}return!1}mn(e){var t;return null==(null==e||null==(t=e.properties)?void 0:t.$elements)?[]:null==e?void 0:e.properties.$elements}un(e,t){return null==t||!t.properties||0===t.properties.length||n7(t.properties.reduce((e,t)=>{var i=R(t.value)?t.value.map(String):null!=t.value?[String(t.value)]:[];return e[t.key]={values:i,operator:t.operator||"exact"},e},{}),null==e?void 0:e.properties)}}class sh{constructor(e){this._instance=e,this.yn=new Map,this.bn=new Map,this.wn=new Map}_n(e,t){return!!e&&n7(e.propertyFilters,null==t?void 0:t.properties)}In(e,t){var i=new Map;return e.forEach(e=>{var n;null==(n=e.conditions)||null==(n=n[t])||null==(n=n.values)||n.forEach(t=>{if(null!=t&&t.name){var n=i.get(t.name)||[];n.push(e.id),i.set(t.name,n)}})}),i}Cn(e,t,i){var n=(i===i2.Activation?this.yn:this.bn).get(e),r=[];return this.Sn(e=>{r=e.filter(e=>null==n?void 0:n.includes(e.id))}),r.filter(n=>{var r,s=null==(r=n.conditions)||null==(r=r[i])||null==(r=r.values)?void 0:r.find(t=>t.name===e);return this._n(s,t)})}register(e){var t;j(null==(t=this._instance)?void 0:t._addCaptureHook)||(this.kn(e),this.xn(e))}xn(e){var t=e.filter(e=>{var t,i;return(null==(t=e.conditions)?void 0:t.actions)&&(null==(i=e.conditions)||null==(i=i.actions)||null==(i=i.values)?void 0:i.length)>0});0!==t.length&&(null==this.Tn&&(this.Tn=new sd(this._instance),this.Tn.init(),this.Tn.vn(e=>{this.onAction(e)})),t.forEach(e=>{var t,i,n,r,s;e.conditions&&null!=(t=e.conditions)&&t.actions&&null!=(i=e.conditions)&&null!=(i=i.actions)&&i.values&&(null==(n=e.conditions)||null==(n=n.actions)||null==(n=n.values)?void 0:n.length)>0&&(null==(r=this.Tn)||r.register(e.conditions.actions.values),null==(s=e.conditions)||null==(s=s.actions)||null==(s=s.values)||s.forEach(t=>{if(t&&t.name){var i=this.wn.get(t.name);i&&i.push(e.id),this.wn.set(t.name,i||[e.id])}}))}))}kn(e){var t,i=e.filter(e=>{var t,i;return(null==(t=e.conditions)?void 0:t.events)&&(null==(i=e.conditions)||null==(i=i.events)||null==(i=i.values)?void 0:i.length)>0}),n=e.filter(e=>{var t,i;return(null==(t=e.conditions)?void 0:t.cancelEvents)&&(null==(i=e.conditions)||null==(i=i.cancelEvents)||null==(i=i.values)?void 0:i.length)>0});0===i.length&&0===n.length||(null==(t=this._instance)||t._addCaptureHook((e,t)=>{this.onEvent(e,t)}),this.yn=this.In(e,i2.Activation),this.bn=this.In(e,i2.Cancellation))}onEvent(e,t){var i,n=this.re(),r=this.An(),s=this.En(),o=(null==(i=this._instance)||null==(i=i.persistence)?void 0:i.props[r])||[];
1if(s===e&&t&&o.length>0){n.info("event matched, removing item from activated items",{event:e,eventPayload:t,existingActivatedItems:o});var a,l,c=(null==t||null==(a=t.properties)?void 0:a.$survey_id)||(null==t||null==(l=t.properties)?void 0:l.$product_tour_id);if(c){var u=o.indexOf(c);0>u||(o.splice(u,1),this.Rn(o))}}else{if(this.bn.has(e)){var d=this.Cn(e,t,i2.Cancellation);d.length>0&&(n.info("cancel event matched, cancelling items",{event:e,itemsToCancel:d.map(e=>e.id)}),d.forEach(e=>{var t=o.indexOf(e.id);0>t||o.splice(t,1),this.Nn(e.id)}),this.Rn(o))}if(this.yn.has(e)){n.info("event name matched",{event:e,eventPayload:t,items:this.yn.get(e)});var h=this.Cn(e,t,i2.Activation);this.Rn(o.concat(h.map(e=>e.id)||[]))}}}onAction(e){var t,i=this.An(),n=(null==(t=this._instance)||null==(t=t.persistence)?void 0:t.props[i])||[];this.wn.has(e)&&this.Rn(n.concat(this.wn.get(e)||[]))}Rn(e){var t,i=this.re(),n=this.An(),r=[...new Set(e)].filter(e=>!this.Mn(e));i.info("updating activated items",{activatedItems:r}),null==(t=this._instance)||null==(t=t.persistence)||t.register({[n]:r})}getActivatedIds(){var e,t=this.An();return(null==(e=this._instance)||null==(e=e.persistence)?void 0:e.props[t])||[]}getEventToItemsMap(){return this.yn}Fn(){return this.Tn}}class sp extends sh{constructor(e){super(e)}An(){return"$surveys_activated"}En(){return i7.SHOWN}Sn(e){var t;null==(t=this._instance)||t.getSurveys(e)}Nn(e){var t;null==(t=this._instance)||t.cancelPendingSurvey(e)}re(){return n6}Mn(){return!1}getSurveys(){return this.getActivatedIds()}getEventToSurveys(){return this.getEventToItemsMap()}}var sg="SDK is not enabled or survey functionality is not yet loaded",sv="Disabled. Not loading surveys.",sf=null!=n&&n.location?iD(n.location.hash,"__posthog")||iD(location.hash,"state"):null,s_="_postHogToolbarParams",sm=tu("[Toolbar]"),sy=tu("[FeatureFlags]"),sb=tu("[FeatureFlags]",{debugEnabled:!0}),sE="\" failed. Feature flags didn't load in time.",sw="$active_feature_flags",sS="$override_feature_flags",sT="$feature_flag_payloads",sI="$override_feature_flag_payloads",sk="$feature_flag_request_id",sx=e=>{for(var t={},i=0;e.length>i;i++)t[e[i]]=!0;return t},sO=e=>{var t={};for(var[i,n]of ie(e||{}))n&&(t[i]=n);return t},sP=tu("[Error tracking]"),sR="Refusing to render web experiment since the viewer is a likely bot",sA={icontains:(e,t)=>!!n&&t.href.toLowerCase().indexOf(e.toLowerCase())>-1,not_icontains:(e,t)=>!!n&&-1===t.href.toLowerCase().indexOf(e.toLowerCase()),regex:(e,t)=>!!n&&n0(t.href,e),not_regex:(e,t)=>!!n&&!n0(t.href,e),exact:(e,t)=>t.href===e,is_not:(e,t)=>t.href!==e};class sC{get Rt(){return this._instance.config}constructor(e){var t=this;this.getWebExperimentsAndEvaluateDisplayLogic=function(e){void 0===e&&(e=!1),t.getWebExperiments(e=>{sC.On("retrieved web experiments from the server"),t.Pn=new Map,e.forEach(e=>{if(e.feature_flag_key){t.Pn&&(sC.On("setting flag key ",e.feature_flag_key," to web experiment ",e),null==(i=t.Pn)||i.set(e.feature_flag_key,e));var i,n=t._instance.getFeatureFlag(e.feature_flag_key);N(n)&&e.variants[n]&&t.Ln(e.name,n,e.variants[n].transforms)}else if(e.variants)for(var r in e.variants){var s=e.variants[r];sC.Dn(s)&&t.Ln(e.name,r,s.transforms)}})},e)},this._instance=e,this._instance.onFeatureFlags(e=>{this.onFeatureFlags(e)})}initialize(){}onFeatureFlags(e){if(this._is_bot())sC.On(sR);else if(!this.Rt.disable_web_experiments){if($(this.Pn))return this.Pn=new Map,this.loadIfEnabled(),void this.previewWebExperiment();sC.On("applying feature flags",e),e.forEach(e=>{var t;if(this.Pn&&null!=(t=this.Pn)&&t.has(e)){var i,n=this._instance.getFeatureFlag(e),r=null==(i=this.Pn)?void 0:i.get(e);n&&null!=r&&r.variants[n]&&this.Ln(r.name,n,r.variants[n].transforms)}})}}previewWebExperiment(){var e=sC.getWindowLocation();if(null!=e&&e.search){var t=iM(null==e?void 0:e.search,"__experiment_id"),i=iM(null==e?void 0:e.search,"__experiment_variant");t&&i&&(sC.On("previewing web experiments "+t+" && "+i),this.getWebExperiments(e=>{this.Bn(parseInt(t),i,e)},!1,!0))}}loadIfEnabled(){this.Rt.disable_web_experiments||this.getWebExperimentsAndEvaluateDisplayLogic()}getWebExperiments(e,t,i){if(this.Rt.disable_web_experiments&&!i)return e([]);var n=this._instance.get_property("$web_experiments");if(n&&!t)return e(n);this._instance._send_request({url:this._instance.requestRouter.endpointFor("api","/api/web_experiments/?token="+this.Rt.token),method:"GET",callback:t=>e(200===t.statusCode&&t.json&&t.json.experiments||[])})}Bn(e,t,i){var n=i.filter(t=>t.id===e);n&&n.length>0&&(sC.On("Previewing web experiment ["+n[0].name+"] with variant ["+t+"]"),this.Ln(n[0].name,t,n[0].variants[t].transforms))}static Dn(e){return!$(e.conditions)&&sC.jn(e)&&sC.qn(e)}static jn(e){if($(e.conditions)||$(null==(t=e.conditions)?void 0:t.url))return!0;var t,i,n,r,s=sC.getWindowLocation();return!!s&&(null==(i=e.conditions)||!i.url||sA[null!==(n=null==(r=e.conditions)?void 0:r.urlMatchType)&&void 0!==n?n:"icontains"](e.conditions.url,s))}
1static getWindowLocation(){return null==n?void 0:n.location}static qn(e){if($(e.conditions)||$(null==(i=e.conditions)?void 0:i.utm))return!0;var t=iB();if(t.utm_source){var i,n,r,s,o,a,l,c,u,d=null==(n=e.conditions)||null==(n=n.utm)||!n.utm_campaign||(null==(r=e.conditions)||null==(r=r.utm)?void 0:r.utm_campaign)==t.utm_campaign,h=null==(s=e.conditions)||null==(s=s.utm)||!s.utm_source||(null==(o=e.conditions)||null==(o=o.utm)?void 0:o.utm_source)==t.utm_source,p=null==(a=e.conditions)||null==(a=a.utm)||!a.utm_medium||(null==(l=e.conditions)||null==(l=l.utm)?void 0:l.utm_medium)==t.utm_medium,g=null==(c=e.conditions)||null==(c=c.utm)||!c.utm_term||(null==(u=e.conditions)||null==(u=u.utm)?void 0:u.utm_term)==t.utm_term;return d&&p&&g&&h}return!1}static On(e){for(var t=arguments.length,i=Array(t>1?t-1:0),n=1;t>n;n++)i[n-1]=arguments[n];tc.info("[WebExperiments] "+e,i)}Ln(e,t,i){this._is_bot()?sC.On(sR):"control"!==t?i.forEach(i=>{if(i.selector){sC.On("applying transform of variant "+t+" for experiment "+e+" ",i);var n,r=null==(n=document)?void 0:n.querySelectorAll(i.selector);null==r||r.forEach(e=>{i.html&&(e.innerHTML=i.html),i.css&&e.setAttribute("style",i.css)})}}):sC.On("Control variants leave the page unmodified.")}_is_bot(){return s&&this._instance?nQ(s,this.Rt.custom_blocked_useragents):void 0}}var sL=tu("[Conversations]"),sj="Conversations not available yet.",sN={trace:{text:"TRACE",number:1},debug:{text:"DEBUG",number:5},info:{text:"INFO",number:9},warn:{text:"WARN",number:13},error:{text:"ERROR",number:17},fatal:{text:"FATAL",number:21}},sF=sN.info;function sM(e){var t=[];for(var i in e){var n=e[i];M(n)||j(n)||t.push({key:i,value:function e(t){if(U(t))return{boolValue:t};if(D(t))return Number.isInteger(t)?{intValue:t}:{doubleValue:t};if("string"==typeof t)return{stringValue:t};if(R(t))return{arrayValue:{values:t.map(t=>e(t))}};try{return{stringValue:JSON.stringify(t)}}catch(e){return{stringValue:String(t)}}}(n)})}return t}var s$={featureFlags:class{constructor(e){this.Zn=!1,this.$n=!1,this.Vn=!1,this.Hn=!1,this.zn=!1,this.Un=!1,this.Yn=!1,this.Wn=!1,this._instance=e,this.featureFlagEventHandlers=[]}get Rt(){return this._instance.config}get Xi(){return this._instance.persistence}Gn(e){return this._instance.get_property(e)}Xn(){var e,t;return null!==(e=null==(t=this.Xi)?void 0:t.pi(this.Rt.feature_flag_cache_ttl_ms))&&void 0!==e&&e}Jn(){return!!this.Xn()&&(this.Wn||this.Vn||(this.Wn=!0,sy.warn("Feature flag cache is stale, triggering refresh..."),this.reloadFeatureFlags()),!0)}Kn(){var e,t=null!==(e=this.Rt.evaluation_contexts)&&void 0!==e?e:this.Rt.evaluation_environments;return!this.Rt.evaluation_environments||this.Rt.evaluation_contexts||this.Yn||(sy.warn("evaluation_environments is deprecated. Use evaluation_contexts instead. evaluation_environments will be removed in a future version."),this.Yn=!0),null!=t&&t.length?t.filter(e=>{var t=e&&"string"==typeof e&&e.trim().length>0;return t||sy.error("Invalid evaluation context found:",e,"Expected non-empty string"),t}):[]}Qn(){return this.Kn().length>0}initialize(){var e,t,{config:i}=this._instance,n=null!==(e=null==(t=i.bootstrap)?void 0:t.featureFlags)&&void 0!==e?e:{};if(Object.keys(n).length){var r,s,o=null!==(r=null==(s=i.bootstrap)?void 0:s.featureFlagPayloads)&&void 0!==r?r:{},a=Object.keys(n).filter(e=>!!n[e]).reduce((e,t)=>(e[t]=n[t]||!1,e),{}),l=Object.keys(o).filter(e=>a[e]).reduce((e,t)=>(o[t]&&(e[t]=o[t]),e),{});this.receivedFeatureFlags({featureFlags:a,featureFlagPayloads:l})}}updateFlags(e,t,i){var n=null!=i&&i.merge?this.getFlagVariants():{},r=null!=i&&i.merge?this.getFlagPayloads():{},s=m({},n,e),o=m({},r,t),a={};for(var[l,c]of Object.entries(s)){var u="string"==typeof c;
1a[l]={key:l,enabled:!!u||!!c,variant:u?c:void 0,reason:void 0,metadata:j(null==o?void 0:o[l])?void 0:{id:0,version:void 0,description:void 0,payload:o[l]}}}this.receivedFeatureFlags({flags:a})}get hasLoadedFlags(){return this.$n}getFlags(){return Object.keys(this.getFlagVariants())}getFlagsWithDetails(){var e=this.Gn(tA),t=this.Gn(sS),i=this.Gn(sI);if(!i&&!t)return e||{};var n=t9({},e||{});for(var r of[...new Set([...Object.keys(i||{}),...Object.keys(t||{})])]){var s,o,a=n[r],l=null==t?void 0:t[r],c=j(l)?null!==(s=null==a?void 0:a.enabled)&&void 0!==s&&s:!!l,u=j(l)?a.variant:"string"==typeof l?l:void 0,d=null==i?void 0:i[r],h=m({},a,{enabled:c,variant:c?null!=u?u:null==a?void 0:a.variant:void 0});c!==(null==a?void 0:a.enabled)&&(h.original_enabled=null==a?void 0:a.enabled),u!==(null==a?void 0:a.variant)&&(h.original_variant=null==a?void 0:a.variant),d&&(h.metadata=m({},null==a?void 0:a.metadata,{payload:d,original_payload:null==a||null==(o=a.metadata)?void 0:o.payload})),n[r]=h}return this.Zn||(sy.warn(" Overriding feature flag details!",{flagDetails:e,overriddenPayloads:i,finalDetails:n}),this.Zn=!0),n}getFlagVariants(){var e=this.Gn(tP),t=this.Gn(sS);if(!t)return e||{};for(var i=t9({},e),n=Object.keys(t),r=0;n.length>r;r++)i[n[r]]=t[n[r]];return this.Zn||(sy.warn(" Overriding feature flags!",{enabledFlags:e,overriddenFlags:t,finalFlags:i}),this.Zn=!0),i}getFlagPayloads(){var e=this.Gn(sT),t=this.Gn(sI);if(!t)return e||{};for(var i=t9({},e||{}),n=Object.keys(t),r=0;n.length>r;r++)i[n[r]]=t[n[r]];return this.Zn||(sy.warn(" Overriding feature flag payloads!",{flagPayloads:e,overriddenPayloads:t,finalPayloads:i}),this.Zn=!0),i}reloadFeatureFlags(){this.Hn||this.Rt.advanced_disable_feature_flags||this.ts||(this._instance.Sr.emit("featureFlagsReloading",!0),this.ts=setTimeout(()=>{this.es()},5))}rs(){clearTimeout(this.ts),this.ts=void 0}ensureFlagsLoaded(){this.$n||this.Vn||this.ts||this.reloadFeatureFlags()}setAnonymousDistinctId(e){this.$anon_distinct_id=e}setReloadingPaused(e){this.Hn=e}es(e){var t;if(this.rs(),!this._instance.ki()){if(this.Vn)this.zn=!0;else{var i=this.Rt.token,n=this.Gn(tg),r={token:i,distinct_id:this._instance.get_distinct_id(),groups:this._instance.getGroups(),$anon_distinct_id:this.$anon_distinct_id,person_properties:m({},(null==(t=this.Xi)?void 0:t.get_initial_props())||{},this.Gn(tC)||{}),group_properties:this.Gn(tL),timezone:iQ()};M(n)||j(n)||(r.$device_id=n),(null!=e&&e.disableFlags||this.Rt.advanced_disable_feature_flags)&&(r.disable_flags=!0),this.Qn()&&(r.evaluation_contexts=this.Kn());var s=this._instance.requestRouter.endpointFor("flags","/flags/?v=2"+(this.Rt.advanced_only_evaluate_survey_feature_flags?"&only_evaluate_survey_feature_flags=true":""));this.Vn=!0,this._instance._send_request({method:"POST",url:s,data:r,compression:this.Rt.disable_compression?void 0:nn.Base64,timeout:this.Rt.feature_flag_request_timeout_ms,callback:e=>{var t,i,n,s=!0;if(200===e.statusCode&&(this.zn||(this.$anon_distinct_id=void 0),s=!1),this.Vn=!1,!r.disable_flags||this.zn){this.Un=!s;var o=[];e.error?e.error instanceof Error?o.push("AbortError"===e.error.name?"timeout":"connection_error"):o.push("unknown_error"):200!==e.statusCode&&o.push("api_error_"+e.statusCode),null!=(t=e.json)&&t.errorsWhileComputingFlags&&o.push("errors_while_computing_flags");var a,l=!(null==(i=e.json)||null==(i=i.quotaLimited)||!i.includes("feature_flags"));(l&&o.push("quota_limited"),null==(n=this.Xi)||n.register({[tM]:o}),l)?sy.warn("You have hit your feature flags quota limit, and will not be able to load feature flags until the quota is reset. Please visit https://posthog.com/docs/billing/limits-alerts to learn more."):(r.disable_flags||this.receivedFeatureFlags(null!==(a=e.json)&&void 0!==a?a:{},s,{partialResponse:!!this.Rt.advanced_only_evaluate_survey_feature_flags}
1),this.zn&&(this.zn=!1,this.es()))}}})}}}getFeatureFlag(e,t){var i;if(void 0===t&&(t={}),!t.fresh||this.Un){if(this.$n||this.getFlags()&&this.getFlags().length>0){if(!this.Jn()){var n=this.getFeatureFlagResult(e,t);return null!==(i=null==n?void 0:n.variant)&&void 0!==i?i:null==n?void 0:n.enabled}}else sy.warn('getFeatureFlag for key "'+e+sE)}}getFeatureFlagDetails(e){return this.getFlagsWithDetails()[e]}getFeatureFlagPayload(e){var t=this.getFeatureFlagResult(e,{send_event:!1});return null==t?void 0:t.payload}getFeatureFlagResult(e,t){if(void 0===t&&(t={}),!t.fresh||this.Un){if(this.$n||this.getFlags()&&this.getFlags().length>0){if(!this.Jn()){var i=this.getFlagVariants(),n=e in i,r=i[e],s=this.getFlagPayloads()[e],o=String(r),a=this.Gn(sk)||void 0,l=this.Gn(t$)||void 0,c=this.Gn(tN)||{};if(this.Rt.advanced_feature_flags_dedup_per_session){var u,d=this._instance.get_session_id(),h=this.Gn(tF);d&&d!==h&&(c={},null==(u=this.Xi)||u.register({[tN]:c,[tF]:d}))}if((t.send_event||!("send_event"in t))&&(!(e in c)||!c[e].includes(o))){R(c[e])?c[e].push(o):c[e]=[o],null==(f=this.Xi)||f.register({[tN]:c});var p=this.getFeatureFlagDetails(e),g=[...null!==(_=this.Gn(tM))&&void 0!==_?_:[]];j(r)&&g.push("flag_missing");var v={$feature_flag:e,$feature_flag_response:r,$feature_flag_payload:s||null,$feature_flag_request_id:a,$feature_flag_evaluated_at:l,$feature_flag_bootstrapped_response:(null==(m=this.Rt.bootstrap)||null==(m
1=m.featureFlags)?void 0:m[e])||null,$feature_flag_bootstrapped_payload:(null==(y=this.Rt.bootstrap)||null==(y=y.featureFlagPayloads)?void 0:y[e])||null,$used_bootstrap_value:!this.Un};j(null==p||null==(b=p.metadata)?void 0:b.version)||(v.$feature_flag_version=p.metadata.version);var f,_,m,y,b,E,w,S,T,I,k,x=null!==(E=null==p||null==(w=p.reason)?void 0:w.description)&&void 0!==E?E:null==p||null==(S=p.reason)?void 0:S.code;x&&(v.$feature_flag_reason=x),null!=p&&null!=(T=p.metadata)&&T.id&&(v.$feature_flag_id=p.metadata.id),j(null==p?void 0:p.original_variant)&&j(null==p?void 0:p.original_enabled)||(v.$feature_flag_original_response=j(p.original_variant)?p.original_enabled:p.original_variant),null!=p&&null!=(I=p.metadata)&&I.original_payload&&(v.$feature_flag_original_payload=null==p||null==(k=p.metadata)?void 0:k.original_payload),g.length&&(v.$feature_flag_error=g.join(",")),this._instance.capture("$feature_flag_called",v)}if(n){var O=s;if(!j(s))try{O=JSON.parse(s)}catch(e){}return{key:e,enabled:!!r,variant:"string"==typeof r?r:void 0,payload:O}}}}else sy.warn('getFeatureFlagResult for key "'+e+sE)}}getRemoteConfigPayload(e,t){var i=this.Rt.token,n={distinct_id:this._instance.get_distinct_id(),token:i};this.Qn()&&(n.evaluation_contexts=this.Kn()),this._instance._send_request({method:"POST",url:this._instance.requestRouter.endpointFor("flags","/flags/?v=2"),data:n,compression:this.Rt.disable_compression?void 0:nn.Base64,timeout:this.Rt.feature_flag_request_timeout_ms,callback(i){var n,r=null==(n=i.json)?void 0:n.featureFlagPayloads;t((null==r?void 0:r[e])||void 0)}})}isFeatureEnabled(e,t){if(void 0===t&&(t={}),!t.fresh||this.Un){if(this.$n||this.getFlags()&&this.getFlags().length>0){var i=this.getFeatureFlag(e,t);return j(i)?void 0:!!i}sy.warn('isFeatureEnabled for key "'+e+sE)}}addFeatureFlagsHandler(e){this.featureFlagEventHandlers.push(e)}removeFeatureFlagsHandler(e){this.featureFlagEventHandlers=this.featureFlagEventHandlers.filter(t=>t!==e)}receivedFeatureFlags(e,t,i){if(this.Xi){this.$n=!0;var n=this.getFlagVariants(),r=this.getFlagPayloads(),s=this.getFlagsWithDetails();!function(e,t,i,n,r,s){void 0===i&&(i={}),void 0===n&&(n={}),void 0===r&&(r={});var o,a=((o=e.flags)?(e.featureFlags=Object.fromEntries(Object.keys(o).map(e=>{var t;return[e,null!==(t=o[e].variant)&&void 0!==t?t:o[e].enabled]})),e.featureFlagPayloads=Object.fromEntries(Object.keys(o).filter(e=>o[e].enabled).filter(e=>{var t;return null==(t=o[e].metadata)?void 0:t.payload}).map(e=>{var t;return[e,null==(t=o[e].metadata)?void 0:t.payload]}))):sy.warn("Using an older version of the feature flags endpoint. Please upgrade your PostHog server to the latest version"),e),l=a.flags,c=a.featureFlags,u=a.featureFlagPayloads;if(c){var d=e.requestId,h=e.evaluatedAt;if(R(c)){sy.warn("v1 of the feature flags endpoint is deprecated. Please use the latest version.");var p={};if(c)for(var g=0;c.length>g;g++)p[c[g]]=!0;t&&t.register({[sw]:c,[tP]:p})}else{var v=c,f=u,_=l;if(null!=s&&s.partialResponse)v=m({},i,v),f=m({},n,f),_=m({},r,_);else if(e.errorsWhileComputingFlags){if(l){var y=new Set(Object.keys(l).filter(e=>{var t;return!(null!=(t=l[e])&&t.failed)}));v=m({},i,Object.fromEntries(Object.entries(v).filter(e=>{var[t]=e;return y.has(t)}))),f=m({},n,Object.fromEntries(Object.entries(f||{}).filter(e=>{var[t]=e;return y.has(t)}))),_=m({},r,Object.fromEntries(Object.entries(_||{}).filter(e=>{var[t]=e;return y.has(t)})))}else v=m({},i,v),f=m({},n,f),_=m({},r,_)}t&&t.register(m({[sw]:Object.keys(sO(v)),[tP]:v||{},[sT]:f||{},[tA]:_||{}},d?{[sk]:d}:{},h?{[t$]:h}:{}))}}}(e,this.Xi,n,r,s,i),t||(this.Wn=!1),this.ns(t)}}override(e,t){void 0===t&&(t=!1),sy.warn("override is deprecated. Please use overrideFeatureFlags instead."),this.overrideFeatureFlags({flags:e,suppressWarning:t})}overrideFeatureFlags(e){if(!this._instance.__loaded||!this.Xi)return sy.uninitializedWarning("posthog.featureFlags.overrideFeatureFlags");if(!1===e)return this.Xi.unregister(sS),this.Xi.unregister(sI),this.ns(),sb.info("All overrides cleared");if(R(e)){var t,i=sx(e);return this.Xi.register({[sS]:i}),this.ns(),sb.info("Flag overrides set",{flags:e})}if(e&&"object"==typeof e&&("flags"in e||"payloads"in e)){if(this.Zn=!!(null!==(t=e.suppressWarning)&&void 0!==t&&t),"flags"in e){if(!1===e.flags)this.Xi.unregister(sS),sb.info("Flag overrides cleared");else if(e.flags){if(R(e.flags)){var n=sx(e.flags);this.Xi.register({[sS]:n})}else this.Xi.register({[sS]:e.flags});sb.info("Flag overrides set",{flags:e.flags})}}return"payloads"in e&&(!1===e.payloads?(this.Xi.unregister(sI),sb.info("Payload overrides cleared")):e.payloads&&(this.Xi.register({[sI]:e.payloads}),sb.info("Payload overrides set",{payloads:e.payloads}))),void this.ns()}if(e&&"object"==typeof e)return this.Xi.register({[sS]:e}),this.ns(),sb.info("Flag overrides set",{flags:e});sy.warn("Invalid overrideOptions provided to overrideFeatureFlags",{overrideOptions:e})}onFeatureFlags(e){if(this.addFeatureFlagsHandler(e),this.$n){var{flags:t,flagVariants:i}=this.ss();e(t,i)}return()=>this.removeFeatureFlagsHandler(e)}updateEarlyAccessFeatureEnrollment(e,t,i){var n,r=(this.Gn(tR)||[]).find(t=>t.flagKey===e),s={["$feature_enrollment/"+e]:t},o={$feature_flag:e,$feature_enrollment:t,$set:s};r&&(o.$early_access_feature_name=r.name),i&&(o.$feature_enrollment_stage=i),this._instance.capture("$feature_enrollment_update",o),this.setPersonPropertiesForFlags(s,!1);var a=m({},this.getFlagVariants(),{[e]:t});null==(n=this.Xi)||n.register({[sw]:Object.keys(sO(a)),[tP]:a}),this.ns()}getEarlyAccessFeatures(e,t,i){void 0===t&&(t=!1);var n=this.Gn(tR),r=i?"&"+i.map(e=>"stage="+e).join("&"):"";if(n&&!t)return e(n);this._instance._send_request({url:this._instance.requestRouter.endpointFor("api","/api/early_access_features/?token="+this.Rt.token+r),method:"GET",callback:t=>{var i,n;if(t.json){var r=t.json.earlyAccessFeatures;return null==(i=this.Xi)||i.unregister(tR),null==(n=this.Xi)||n.register({[tR]:r}),e(r)}}})}ss(){var e=this.getFlags(),t=this.getFlagVariants();return{flags:e.filter(e=>t[e]),flagVariants:Object.keys(t).filter(e=>t[e]).reduce((e,i)=>(e[i]=t[i],e),{})}}ns(e){var{flags:t,flagVariants:i}=this.ss();
1this.featureFlagEventHandlers.forEach(n=>n(t,i,{errorsLoading:e}))}setPersonPropertiesForFlags(e,t){void 0===t&&(t=!0);var i=this.Gn(tC)||{},n=(null==e?void 0:e.$set)||(null!=e&&e.$set_once?{}:e),r=null==e?void 0:e.$set_once,s={};if(r)for(var o in r)({}).hasOwnProperty.call(r,o)&&(o in i||(s[o]=r[o]));this._instance.register({[tC]:m({},i,s,n)}),t&&this._instance.reloadFeatureFlags()}resetPersonPropertiesForFlags(){this._instance.unregister(tC)}setGroupPropertiesForFlags(e,t){void 0===t&&(t=!0);var i=this.Gn(tL)||{};0!==Object.keys(i).length&&Object.keys(i).forEach(t=>{i[t]=m({},i[t],e[t]),delete e[t]}),this._instance.register({[tL]:m({},i,e)}),t&&this._instance.reloadFeatureFlags()}resetGroupPropertiesForFlags(e){if(e){var t=this.Gn(tL)||{};this._instance.register({[tL]:m({},t,{[e]:{}})})}else this._instance.unregister(tL)}reset(){this.$n=!1,this.Vn=!1,this.Hn=!1,this.zn=!1,this.Un=!1,this.$anon_distinct_id=void 0,this.rs(),this.Zn=!1}}},sD=m({productTours:class{get Xi(){return this._instance.persistence}constructor(e){this.co=null,this.do=null,this._instance=e}initialize(){this.loadIfEnabled()}onRemoteConfig(e){"productTours"in e&&(this.Xi&&this.Xi.register({[tT]:!!e.productTours}),this.loadIfEnabled())}loadIfEnabled(){var e,t;this.co||(e=this._instance).config.disable_product_tours||null==(t=e.persistence)||!t.get_property(tT)||this.ni(()=>this.vo())}ni(e){var t,i;null!=(t=p.__PosthogExtensions__)&&t.generateProductTours?e():null==(i=p.__PosthogExtensions__)||null==i.loadExternalDependency||i.loadExternalDependency(this._instance,"product-tours",t=>{t?ss.error("Could not load product tours script",t):e()})}vo(){var e;!this.co&&null!=(e=p.__PosthogExtensions__)&&e.generateProductTours&&(this.co=p.__PosthogExtensions__.generateProductTours(this._instance,!0))}getProductTours(e,t){if(void 0===t&&(t=!1),!R(this.do)||t){var i=this.Xi;if(i){var n=i.props[so];if(R(n)&&!t)return this.do=n,void e(n,{isLoaded:!0})}this._instance._send_request({url:this._instance.requestRouter.endpointFor("api","/api/product_tours/?token="+this._instance.config.token),method:"GET",callback:t=>{var n=t.statusCode;if(200!==n||!t.json){var r="Product Tours API could not be loaded, status: "+n;return ss.error(r),void e([],{isLoaded:!1,error:r})}var s=R(t.json.product_tours)?t.json.product_tours:[];this.do=s,i&&i.register({[so]:s}),e(s,{isLoaded:!0})}})}else e(this.do,{isLoaded:!0})}getActiveProductTours(e){$(this.co)?e([],{isLoaded:!1,error:"Product tours not loaded"}):this.co.getActiveProductTours(e)}showProductTour(e){var t;null==(t=this.co)||t.showTourById(e)}previewTour(e){this.co?this.co.previewTour(e):this.ni(()=>{var t;this.vo(),null==(t=this.co)||t.previewTour(e)})}dismissProductTour(){var e;null==(e=this.co)||e.dismissTour("user_clicked_skip")}nextStep(){var e;null==(e=this.co)||e.nextStep()}previousStep(){var e;null==(e=this.co)||e.previousStep()}clearCache(){var e;this.do=null,null==(e=this.Xi)||e.unregister(so)}resetTour(e){var t;null==(t=this.co)||t.resetTour(e)}resetAllTours(){var e;null==(e=this.co)||e.resetAllTours()}cancelPendingTour(e){var t;null==(t=this.co)||t.cancelPendingTour(e)}}},s$),sG=m({surveys:class{get Rt(){return this._instance.config}constructor(e){this.Io=void 0,this._surveyManager=null,this.Co=!1,this.So=[],this.ko=null,this._instance=e,this._surveyEventReceiver=null}initialize(){this.loadIfEnabled()}onRemoteConfig(e){if(!this.Rt.disable_surveys){var t=e.surveys;if($(t))return n6.warn("Flags not loaded yet. Not loading surveys.");var i=R(t);this.Io=i?t.length>0:t,n6.info("flags response received, isSurveysEnabled: "+this.Io),this.loadIfEnabled()}}reset(){localStorage.removeItem("lastSeenSurveyDate");for(var e=[],t=0;t<localStorage.length;t++){var i=localStorage.key(t);(null!=i&&i.startsWith(n9)||null!=i&&i.startsWith("inProgressSurvey_"))&&e.push(i)}e.forEach(e=>localStorage.removeItem(e))}loadIfEnabled(){if(!this._surveyManager){if(this.Co)n6.info("Already initializing surveys, skipping...");else if(this.Rt.disable_surveys)n6.info(sv);else if(this.Rt.cookieless_mode&&this._instance.consent.isOptedOut())n6.info("Not loading surveys in cookieless mode without consent.");else{var e=null==p?void 0:p.__PosthogExtensions__;if(e){if(!j(this.Io)||this.Rt.advanced_enable_surveys){var t=this.Io||this.Rt.advanced_enable_surveys;this.Co=!0;try{var i=e.generateSurveys;if(i)return void this.xo(i,t);var n=e.loadExternalDependency;if(!n)return void this.To(tX);n(this._instance,"surveys",i=>{i||!e.generateSurveys?this.To("Could not load surveys script",i):this.xo(e.generateSurveys,t)})}catch(e){throw this.To("Error initializing surveys",e),e}finally{this.Co=!1}}}else n6.error("PostHog Extensions not found.")}}}xo(e,t){this._surveyManager=e(this._instance,t),this._surveyEventReceiver=new sp(this._instance),n6.info("Surveys loaded successfully"),this.Ao({isLoaded:!0})}To(e,t){n6.error(e,t),this.Ao({isLoaded:!1,error:e})}onSurveysLoaded(e){return this.So.push(e),this._surveyManager&&this.Ao({isLoaded:!0}),()=>{this.So=this.So.filter(t=>t!==e)}}getSurveys(e,t){if(void 0===t&&(t=!1),this.Rt.disable_surveys)return n6.info(sv),e([]);var i,n=this._instance.get_property(tj);if(n&&!t)return e(n,{isLoaded:!0});"undefined"!=typeof Promise&&this.ko?this.ko.then(t=>{var{surveys:i,context:n}=t;return e(i,n)}):("undefined"!=typeof Promise&&(this.ko=new Promise(e=>{i=e})),this._instance._send_request({url:this._instance.requestRouter.endpointFor("api","/api/surveys/?token="+this.Rt.token),method:"GET",timeout:this.Rt.surveys_request_timeout_ms,callback:t=>{this.ko=null;var n=t.statusCode;if(200!==n||!t.json){var r="Surveys API could not be loaded, status: "+n;n6.error(r);var s={isLoaded:!1,error:r};return e([],s),void(null==i||i({surveys:[],context:s}))}
1var o,a,l=t.json.surveys||[],c=l.filter(e=>{var t,i;return!(!e.start_date||e.end_date)&&(!(null==(t=e.conditions)||null==(t=t.events)||null==(t=t.values)||!t.length)||!(null==(i=e.conditions)||null==(i=i.actions)||null==(i=i.values)||!i.length))});c.length>0&&(null==(a=this._surveyEventReceiver)||a.register(c)),null==(o=this._instance.persistence)||o.register({[tj]:l});var u={isLoaded:!0};e(l,u),null==i||i({surveys:l,context:u})}}))}Ao(e){for(var t of this.So)try{if(!e.isLoaded)return t([],e);this.getSurveys(t)}catch(e){n6.error("Error in survey callback",e)}}getActiveMatchingSurveys(e,t){if(void 0===t&&(t=!1),!$(this._surveyManager))return this._surveyManager.getActiveMatchingSurveys(e,t);n6.warn("init was not called")}Eo(e){var t=null;return this.getSurveys(i=>{var n;t=null!==(n=i.find(t=>t.id===e))&&void 0!==n?n:null}),t}Ro(e){if($(this._surveyManager))return{eligible:!1,reason:sg};var t="string"==typeof e?this.Eo(e):e;return t?this._surveyManager.checkSurveyEligibility(t):{eligible:!1,reason:"Survey not found"}}canRenderSurvey(e){if($(this._surveyManager))return n6.warn("init was not called"),{visible:!1,disabledReason:sg};var t=this.Ro(e);return{visible:t.eligible,disabledReason:t.reason}}canRenderSurveyAsync(e,t){return $(this._surveyManager)?(n6.warn("init was not called"),Promise.resolve({visible:!1,disabledReason:sg})):new Promise(i=>{this.getSurveys(t=>{var n,r=null!==(n=t.find(t=>t.id===e))&&void 0!==n?n:null;if(r){var s=this.Ro(r);i({visible:s.eligible,disabledReason:s.reason})}else i({visible:!1,disabledReason:"Survey not found"})},t)})}renderSurvey(e,t,i){var n;if($(this._surveyManager))n6.warn("init was not called");else{var r="string"==typeof e?this.Eo(e):e;if(null!=r&&r.id){if(ri.includes(r.type)){var s=null==o?void 0:o.querySelector(t);if(s)return null!=(n=r.appearance)&&n.surveyPopupDelaySeconds?(n6.info("Rendering survey "+r.id+" with delay of "+r.appearance.surveyPopupDelaySeconds+" seconds"),void setTimeout(()=>{var e,t;n6.info("Rendering survey "+r.id+" with delay of "+(null==(e=r.appearance)?void 0:e.surveyPopupDelaySeconds)+" seconds"),null==(t=this._surveyManager)||t.renderSurvey(r,s,i),n6.info("Survey "+r.id+" rendered")},1e3*r.appearance.surveyPopupDelaySeconds)):void this._surveyManager.renderSurvey(r,s,i);n6.warn("Survey element not found")}else n6.warn("Surveys of type "+r.type+" cannot be rendered in the app")}else n6.warn("Survey not found")}}displaySurvey(e,t){var i;if($(this._surveyManager))n6.warn("init was not called");else{var n=this.Eo(e);if(n){var r=n;if(null!=(i=n.appearance)&&i.surveyPopupDelaySeconds&&t.ignoreDelay&&(r=m({},n,{appearance:m({},n.appearance,{surveyPopupDelaySeconds:0})})),t.displayType!==i4.Popover&&t.initialResponses&&n6.warn("initialResponses is only supported for popover surveys. prefill will not be applied."),!1===t.ignoreConditions){var s=this.canRenderSurvey(n);if(!s.visible)return void n6.warn("Survey is not eligible to be displayed: ",s.disabledReason)}t.displayType!==i4.Inline?this._surveyManager.handlePopoverSurvey(r,t):this.renderSurvey(r,t.selector,t.properties)}else n6.warn("Survey not found")}}cancelPendingSurvey(e){$(this._surveyManager)?n6.warn("init was not called"):this._surveyManager.cancelSurvey(e)}handlePageUnload(){var e;null==(e=this._surveyManager)||e.handlePageUnload()}}},s$),sU=m({experiments:sC},s$),sH=m({},s$,{sessionRecording:class{get Rt(){return this._instance.config}get Xi(){return this._instance.persistence}get started(){var e;return!(null==(e=this.os)||!e.isStarted)}get status(){var e,t;return this.ls===r9||this.ls===se?this.ls:null!==(e=null==(t=this.os)?void 0:t.status)&&void 0!==e?e:this.ls}constructor(e){if(this._forceAllowLocalhostNetworkCapture=!1,this.ls=r8,this.us=void 0,this._instance=e,!this._instance.sessionManager)throw si.error("started without valid sessionManager"),Error(st+" started without valid sessionManager. This is a bug.");if(this.Rt.cookieless_mode===tJ)throw Error(st+' cannot be used with cookieless_mode="always"')}initialize(){this.startIfEnabledOrStop()}get hs(){var e,t=!(null==(e=this._instance.get_property(tk))||!e.enabled),i=!this.Rt.disable_session_recording,r=this.Rt.disable_session_recording||this._instance.consent.isOptedOut();return n&&t&&i&&!r}startIfEnabledOrStop(e){var t;if(!this.hs||null==(t=this.os)||!t.isStarted){var i=!j(Object.assign)&&!j(Array.from);this.hs&&i?(this.cs(e),si.info("starting")):(this.ls=r8,this.stopRecording())}}cs(e){var t,i,n;this.hs&&(this.ls!==r9&&this.ls!==se&&(this.ls=r6),null!=p&&null!=(t=p.__PosthogExtensions__)&&null!=(t=t.rrweb)&&t.record&&null!=(i=p.__PosthogExtensions__)&&i.initSessionRecording?this.ds(e):null==(n=p.__PosthogExtensions__)||null==n.loadExternalDependency||n.loadExternalDependency(this._instance,this.vs,t=>{if(t)return si.error("could not load recorder",t);this.ds(e)}))}stopRecording(){var e,t;null==(e=this.us)||e.call(this),this.us=void 0,null==(t=this.os)||t.stop()}fs(){var e,t;null==(e=this.us)||e.call(this),this.us=void 0,null==(t=this.os)||t.discard()}ps(){var e;null==(e=this.Xi)||e.unregister(tO)}gs(e,t){if($(e))return null;var i=D(e)?e:parseFloat(e);return"number"!=typeof i||!Number.isFinite(i)||0>i||i>1?(si.warn(t+" must be between 0 and 1. Ignoring invalid value:",e),null):i}ys(e){if(this.Xi){var t,i,n=this.Xi,r=()=>{var t,i=!1===e.sessionRecording?void 0:e.sessionRecording,r=this.gs(null==(t=this.Rt.session_recording)?void 0:t.sampleRate,"session_recording.sampleRate"),s=this.gs(null==i?void 0:i.sampleRate,"remote config sampleRate"),o=null!=r?r:s;
1$(o)&&this.ps();var a=null==i?void 0:i.minimumDurationMilliseconds;n.register({[tk]:m({cache_timestamp:Date.now(),enabled:!!i},i,{networkPayloadCapture:m({capturePerformance:e.capturePerformance},null==i?void 0:i.networkPayloadCapture),canvasRecording:{enabled:null==i?void 0:i.recordCanvas,fps:null==i?void 0:i.canvasFps,quality:null==i?void 0:i.canvasQuality},sampleRate:o,minimumDurationMilliseconds:j(a)?null:a,endpoint:null==i?void 0:i.endpoint,triggerMatchType:null==i?void 0:i.triggerMatchType,masking:null==i?void 0:i.masking,urlTriggers:null==i?void 0:i.urlTriggers})})};r(),null==(t=this.us)||t.call(this),this.us=null==(i=this._instance.sessionManager)?void 0:i.onSessionId(r)}}onRemoteConfig(e){return"sessionRecording"in e?!1===e.sessionRecording?(this.ys(e),void this.fs()):(this.ys(e),void this.startIfEnabledOrStop()):(this.ls===r9&&(this.ls=se,si.warn("config refresh failed, recording will not start until page reload")),void this.startIfEnabledOrStop())}log(e,t){var i;void 0===t&&(t="log"),null!=(i=this.os)&&i.log?this.os.log(e,t):si.warn("log called before recorder was ready")}get vs(){var e,t,i=null==(e=this._instance)||null==(e=e.persistence)?void 0:e.get_property(tk);return(null==i||null==(t=i.scriptConfig)?void 0:t.script)||"lazy-recorder"}bs(){var e,t=this._instance.get_property(tk);if(!t)return!1;var i=null!==(e=("object"==typeof t?t:JSON.parse(t)).cache_timestamp)&&void 0!==e?e:Date.now();return 36e5>=Date.now()-i}ds(e){var t,i;if(null==(t=p.__PosthogExtensions__)||!t.initSessionRecording)return si.warn("Called on script loaded before session recording is available. This can be caused by adblockers."),void this._instance.register_for_session({$sdk_debug_recording_script_not_loaded:!0});if(this.os||(this.os=null==(i=p.__PosthogExtensions__)?void 0:i.initSessionRecording(this._instance),this.os._forceAllowLocalhostNetworkCapture=this._forceAllowLocalhostNetworkCapture),!this.bs()){if(this.ls===se||this.ls===r9)return;return this.ls=r9,si.info("persisted remote config is stale, requesting fresh config before starting"),void new ni(this._instance).load()}this.ls=r6,this.os.start(e)}onRRwebEmit(e){var t;null==(t=this.os)||null==t.onRRwebEmit||t.onRRwebEmit(e)}overrideLinkedFlag(){var e,t;this.os||null==(t=this.Xi)||t.register({$replay_override_linked_flag:!0}),null==(e=this.os)||e.overrideLinkedFlag()}overrideSampling(){var e,t;this.os||null==(t=this.Xi)||t.register({$replay_override_sampling:!0}),null==(e=this.os)||e.overrideSampling()}overrideTrigger(e){var t,i;this.os||null==(i=this.Xi)||i.register({["url"===e?"$replay_override_url_trigger":"$replay_override_event_trigger"]:!0}),null==(t=this.os)||t.overrideTrigger(e)}get sdkDebugProperties(){var e;return(null==(e=this.os)?void 0:e.sdkDebugProperties)||{$recording_status:this.status}}tryAddCustomEvent(e,t){var i;return!(null==(i=this.os)||!i.tryAddCustomEvent(e,t))}}},{autocapture:class{constructor(e){this.ws=!1,this._s=null,this.Is=!1,this.instance=e,this.rageclicks=new rQ(e.config.rageclick),this.Cs=null}initialize(){this.startIfEnabled()}get Rt(){var e,t,i=C(this.instance.config.autocapture)?this.instance.config.autocapture:{};return i.url_allowlist=null==(e=i.url_allowlist)?void 0:e.map(e=>new RegExp(e)),i.url_ignorelist=null==(t=i.url_ignorelist)?void 0:t.map(e=>new RegExp(e)),i}Ss(){if(this.isBrowserSupported()){if(n&&o){var e=e=>{e=e||(null==n?void 0:n.event);try{this.ks(e)}catch(e){r1.error("Failed to capture event",e)}};if(io(o,"submit",e,{capture:!0}),io(o,"change",e,{capture:!0}),io(o,"click",e,{capture:!0}),this.Rt.capture_copied_text){var t=e=>{this.ks(e=e||(null==n?void 0:n.event),r0)};io(o,"copy",t,{capture:!0}),io(o,"cut",t,{capture:!0})}}}else r1.info("Disabling Automatic Event Collection because this browser is not supported")}startIfEnabled(){this.isEnabled&&!this.ws&&(this.Ss(),this.ws=!0)}onRemoteConfig(e){e.elementsChainAsString&&(this.Is=e.elementsChainAsString),this.instance.persistence&&this.instance.persistence.register({[t_]:!!e.autocapture_opt_out}),this._s=!!e.autocapture_opt_out,this.startIfEnabled()}setElementSelectors(e){this.Cs=e}getElementSelectors(e){var t,i=[];return null==(t=this.Cs)||t.forEach(t=>{var n=null==o?void 0:o.querySelectorAll(t);
1null==n||n.forEach(n=>{e===n&&i.push(t)})}),i}get isEnabled(){var e,t,i=null==(e=this.instance.persistence)?void 0:e.props[t_];if(M(this._s)&&!U(i)&&!this.instance.ki())return!1;var n=null!==(t=this._s)&&void 0!==t?t:!!i;return!!this.instance.config.autocapture&&!n}ks(e,t){if(void 0===t&&(t="$autocapture"),this.isEnabled){var i,r=rj(e);rx(r)&&(r=r.parentNode||null),"$autocapture"===t&&"click"===e.type&&e instanceof MouseEvent&&this.instance.config.rageclick&&null!=(i=this.rageclicks)&&i.isRageClick(e.clientX,e.clientY,e.timeStamp||(new Date).getTime())&&function(e,t){if(!n||rG(e)||(U(t)?(i=!!t&&rD,r=void 0):(i=null!==(s=null==t?void 0:t.css_selector_ignorelist)&&void 0!==s?s:rD,r=null==t?void 0:t.content_ignorelist),!1===i))return!1;var i,r,s,{targetElementList:o}=rU(e,!1);return!function(e,t){var i;if(!1===e||j(e))return!1;if(!0===e)i=r$;else{if(!R(e))return!1;if(e.length>10)return tc.error("[PostHog] content_ignorelist array cannot exceed 10 items. Use css_selector_ignorelist for more complex matching."),!1;i=e.map(e=>e.toLowerCase())}return t.some(e=>{var{safeText:t,ariaLabel:n}=e;return i.some(e=>t.includes(e)||n.includes(e))})}(r,o.map(e=>{var t;return{safeText:rL(e).toLowerCase(),ariaLabel:(null==(t=e.getAttribute("aria-label"))?void 0:t.toLowerCase().trim())||""}}))&&!rF(o,i)}(r,this.instance.config.rageclick)&&this.ks(e,"$rageclick");var s=t===r0;if(r&&function(e,t,i,r,s){if(void 0===i&&(i=void 0),!n||rG(e)||null!=(o=i)&&o.url_allowlist&&!rR(i.url_allowlist)||null!=(a=i)&&a.url_ignorelist&&rR(i.url_ignorelist))return!1;if(null!=(l=i)&&l.dom_event_allowlist){var o,a,l,c,u=i.dom_event_allowlist;if(u&&!u.some(e=>t.type===e))return!1}var{parentIsUsefulElement:d,targetElementList:h}=rU(e,r);if(!function(e,t){var i=null==t?void 0:t.element_allowlist;if(j(i))return!0;var n,r=function(e){if(i.some(t=>e.tagName.toLowerCase()===t))return{v:!0}};for(var s of e)if(n=r(s))return n.v;return!1}(h,i)||!rF(h,null==(c=i)?void 0:c.css_selector_allowlist))return!1;var p=n.getComputedStyle(e);if(p&&"pointer"===p.getPropertyValue("cursor")&&"click"===t.type)return!0;var g=e.tagName.toLowerCase();switch(g){case"html":return!1;case"form":return(s||["submit"]).indexOf(t.type)>=0;case"input":case"select":case"textarea":return(s||["change","click"]).indexOf(t.type)>=0;default:return d?(s||["click"]).indexOf(t.type)>=0:(s||["click"]).indexOf(t.type)>=0&&(rN.indexOf(g)>-1||"true"===e.getAttribute("contenteditable"))}}(r,e,this.Rt,s,s?["copy","cut"]:void 0)){var{props:o,explicitNoCapture:a}=function(e,t){for(var i,r,{e:s,maskAllElementAttributes:o,maskAllText:a,elementAttributeIgnoreList:l,elementsChainAsString:c}=t,u=[e],d=e;d.parentNode&&!rk(d,"body");)rO(d.parentNode)?(u.push(d.parentNode.host),d=d.parentNode.host):(u.push(d.parentNode),d=d.parentNode);var h,p=[],g={},v=!1,f=!1;if(t6(u,e=>{var t=rH(e);"a"===e.tagName.toLowerCase()&&(v=e.getAttribute("href"),v=t&&v&&rK(v)&&v),T(rA(e),"ph-no-capture")&&(f=!0),p.push(function(e,t,i,n){var r=e.tagName.toLowerCase(),s={tag_name:r};rN.indexOf(r)>-1&&!i&&(s.$el_text="a"===r.toLowerCase()||"button"===r.toLowerCase()?r2(1024,rJ(e)):r2(1024,rL(e)));var o=rA(e);o.length>0&&(s.classes=o.filter(function(e){return""!==e})),t6(e.attributes,function(i){var r;if((!rW(e)||-1!==["name","id","class","aria-label"].indexOf(i.name))&&(null==n||!n.includes(i.name))&&!t&&rK(i.value)&&(!N(r=i.name)||"_ngcontent"!==r.substring(0,10)&&"_nghost"!==r.substring(0,7))){var o=i.value;"class"===i.name&&(o=rP(o).join(" ")),s["attr__"+i.name]=r2(1024,o)}});for(var a=1,l=1,c=e;c=function(e){if(e.previousElementSibling)return e.previousElementSibling;var t=e;do t=t.previousSibling;while(t&&!rI(t));return t}(c);)a++,c.tagName===e.tagName&&l++;return s.nth_child=a,s.nth_of_type=l,s}(e,o,a,l)),t9(g,function(e){if(!rH(e))return{};var t={};return t6(e.attributes,function(e){if(e.name&&0===e.name.indexOf("data-ph-capture-attribute")){var i=e.name.replace("data-ph-capture-attribute-",""),n=e.value;i&&n&&rK(n)&&(t[i]=n)}}),t}(e))}),f)return{props:{},explicitNoCapture:f};if(a||(p[0].$el_text="a"===e.tagName.toLowerCase()||"button"===e.tagName.toLowerCase()?rJ(e):rL(e)),v){p[0].attr__href=v;var _,y,b=null==(_=iF(v))?void 0:_.host,E=null==n||null==(y=n.location)?void 0:y.host;b&&E&&b!==E&&(h=v)}return{props:t9({$event_type:s.type,$ce_version:1},c?{}:{$elements:p},{$elements_chain:p.map(e=>{var t,i,n,r={text:null==(i=e.$el_text)?void 0:i.slice(0,400),tag_name:e.tag_name,href:null==(n=e.attr__href)?void 0:n.slice(0,2048),attr_class:(t=e.attr__class)?R(t)?t:rP(t):void 0,attr_id:e.attr__id,nth_child:e.nth_child,nth_of_type:e.nth_of_type,attributes:{}};return ie(e).filter(e=>{var[t]=e;return 0===t.indexOf("attr__")}
1).forEach(e=>{var[t,i]=e;return r.attributes[t]=i}),r}).map(e=>{var t,i,n="";if(e.tag_name&&(n+=e.tag_name),e.attr_class)for(var r of(e.attr_class.sort(),e.attr_class))n+="."+r.replace(/"/g,"");var s=m({},e.text?{text:e.text}:{},{"nth-child":null!==(t=e.nth_child)&&void 0!==t?t:0,"nth-of-type":null!==(i=e.nth_of_type)&&void 0!==i?i:0},e.href?{href:e.href}:{},e.attr_id?{attr_id:e.attr_id}:{},e.attributes),o={};return ie(s).sort((e,t)=>{var[i]=e,[n]=t;return i.localeCompare(n)}).forEach(e=>{var[t,i]=e;return o[rZ(t.toString())]=rZ(i.toString())}),(n+=":")+ie(o).map(e=>{var[t,i]=e;return t+'="'+i+'"'}).join("")}).join(";")},null!=(i=p[0])&&i.$el_text?{$el_text:null==(r=p[0])?void 0:r.$el_text}:{},h&&"click"===s.type?{$external_click_url:h}:{},g)}}(r,{e:e,maskAllElementAttributes:this.instance.config.mask_all_element_attributes,maskAllText:this.instance.config.mask_all_text,elementAttributeIgnoreList:this.Rt.element_attribute_ignorelist,elementsChainAsString:this.Is});if(a)return!1;var l=this.getElementSelectors(r);if(l&&l.length>0&&(o.$element_selectors=l),t===r0){var c,u=rC(null==n||null==(c=n.getSelection())?void 0:c.toString()),d=e.type||"clipboard";if(!u)return!1;o.$selected_content=u,o.$copy_type=d}return this.instance.capture(t,o),!0}}}isBrowserSupported(){return A(null==o?void 0:o.querySelectorAll)}},historyAutocapture:class{constructor(e){var t;this._instance=e,this.xs=(null==n||null==(t=n.location)?void 0:t.pathname)||""}initialize(){this.startIfEnabled()}get isEnabled(){return"history_change"===this._instance.config.capture_pageview}startIfEnabled(){this.isEnabled&&(tc.info("History API monitoring enabled, starting..."),this.monitorHistoryChanges())}stop(){this.Ts&&this.Ts(),this.Ts=void 0,tc.info("History API monitoring stopped")}monitorHistoryChanges(){var e,t;if(n&&n.history){var i=this;null!=(e=n.history.pushState)&&e.__posthog_wrapped__||r7(n.history,"pushState",e=>function(t,n,r){e.call(this,t,n,r),i.As("pushState")}),null!=(t=n.history.replaceState)&&t.__posthog_wrapped__||r7(n.history,"replaceState",e=>function(t,n,r){e.call(this,t,n,r),i.As("replaceState")}),this.Es()}}As(e){try{var t,i=null==n||null==(t=n.location)?void 0:t.pathname;if(!i)return;i!==this.xs&&this.isEnabled&&this._instance.capture(t5,{navigation_type:e}),this.xs=i}catch(t){tc.error("Error capturing "+e+" pageview",t)}}Es(){if(!this.Ts){var e=()=>{this.As("popstate")};io(n,"popstate",e),this.Ts=()=>{n&&n.removeEventListener("popstate",e)}}}},heatmaps:class{get Rt(){return this.instance.config}constructor(e){var t;this.Rs=!1,this.ws=!1,this.Ns=null,this.instance=e,this.Rs=!(null==(t=this.instance.persistence)||!t.props[tm]),this.rageclicks=new rQ(e.config.rageclick)}initialize(){this.startIfEnabled()}get flushIntervalMilliseconds(){var e=5e3;return C(this.Rt.capture_heatmaps)&&this.Rt.capture_heatmaps.flush_interval_milliseconds&&(e=this.Rt.capture_heatmaps.flush_interval_milliseconds),e}get isEnabled(){return $(this.Rt.capture_heatmaps)?$(this.Rt.enable_heatmaps)?this.Rs:this.Rt.enable_heatmaps:!1!==this.Rt.capture_heatmaps}startIfEnabled(){if(this.isEnabled)this.ws||(sn.info("starting..."),this.Ms(),this.Tt());else{var e;clearInterval(null!==(e=this.Ns)&&void 0!==e?e:void 0),this.Fs(),this.getAndClearBuffer()}}onRemoteConfig(e){if("heatmaps"in e){var t=!!e.heatmaps;this.instance.persistence&&this.instance.persistence.register({[tm]:t}),this.Rs=t,this.startIfEnabled()}}getAndClearBuffer(){var e=this.T;return this.T=void 0,e}Os(e){this.wt(e.originalEvent,"deadclick")}Tt(){this.Ns&&clearInterval(this.Ns),this.Ns="visible"===(null==o?void 0:o.visibilityState)?setInterval(this.ji.bind(this),this.flushIntervalMilliseconds):null}Ms(){n&&o&&(this.Ps=this.ji.bind(this),io(n,t2,this.Ps),this.Ls=e=>this.wt(e||(null==n?void 0:n.event)),io(o,"click",this.Ls,{capture:!0}),this.Ds=e=>this.Bs(e||(null==n?void 0:n.event)),io(o,"mousemove",this.Ds,{capture:!0}),this.js=new iR(this.instance,iO,this.Os.bind(this)),this.js.startIfEnabledOrStop(),this.qs=this.Tt.bind(this),io(o,t1,this.qs),this.ws=!0)}Fs(){var e;n&&o&&(this.Ps&&n.removeEventListener(t2,this.Ps),this.Ls&&o.removeEventListener("click",this.Ls,{capture:!0}),this.Ds&&o.removeEventListener("mousemove",this.Ds,{capture:!0}),this.qs&&o.removeEventListener(t1,this.qs),clearTimeout(this.Zs),null==(e=this.js)||e.stop(),this.ws=!1)}$s(e,t){var i=this.instance.scrollManager.scrollY(),r=this.instance.scrollManager.scrollX(),s=this.instance.scrollManager.scrollElement(),o=function(e,t,i){for(var r=e;r&&rI(r)&&!rk(r,"body")&&r!==i;){if(T(t,null==n?void 0:n.getComputedStyle(r).position))return!0;r=rM(r)}return!1}(rj(e),["fixed","sticky"],s);return{x:e.clientX+(o?0:r),y:e.clientY+(o?0:i),target_fixed:o,type:t}}wt(e,t){var i;if(void 0===t&&(t="click"),!rT(e.target)&&sr(e)){var n=this.$s(e,t);null!=(i=this.rageclicks)&&i.isRageClick(e.clientX,e.clientY,(new Date).getTime())&&this.Vs(m({}
1,n,{type:"rageclick"})),this.Vs(n)}}Bs(e){!rT(e.target)&&sr(e)&&(clearTimeout(this.Zs),this.Zs=setTimeout(()=>{this.Vs(this.$s(e,"mousemove"))},500))}Vs(e){if(n){var t=n.location.href,i=this.Rt.custom_personal_data_properties,r=i$(t,this.Rt.mask_personal_data_properties?[...iU,...i||[]]:[],iW);this.T=this.T||{},this.T[r]||(this.T[r]=[]),this.T[r].push(e)}}ji(){this.T&&!L(this.T)&&this.instance.capture("$$heatmap",{$heatmap_data:this.getAndClearBuffer()})}},deadClicksAutocapture:iR,webVitalsAutocapture:class{constructor(e){var t;this.Rs=!1,this.ws=!1,this.T={url:void 0,metrics:[],firstMetricTimestamp:void 0},this.Hs=()=>{clearTimeout(this.zs),0!==this.T.metrics.length&&(this._instance.capture("$web_vitals",this.T.metrics.reduce((e,t)=>m({},e,{["$web_vitals_"+t.name+"_event"]:m({},t),["$web_vitals_"+t.name+"_value"]:t.value}),{})),this.T={url:void 0,metrics:[],firstMetricTimestamp:void 0})},this.nt=e=>{var t,i=null==(t=this._instance.sessionManager)?void 0:t.checkAndGetSessionAndWindowId(!0);if(j(i))r4.error("Could not read session ID. Dropping metrics!");else{this.T=this.T||{url:void 0,metrics:[],firstMetricTimestamp:void 0};var n=this.Us();j(n)||($(null==e?void 0:e.name)||$(null==e?void 0:e.value)?r4.error("Invalid metric received",e):!this.Ys||this.Ys>e.value?(this.T.url!==n&&(this.Hs(),this.zs=setTimeout(this.Hs,this.flushToCaptureTimeoutMs)),j(this.T.url)&&(this.T.url=n),this.T.firstMetricTimestamp=j(this.T.firstMetricTimestamp)?Date.now():this.T.firstMetricTimestamp,e.attribution&&e.attribution.interactionTargetElement&&(e.attribution.interactionTargetElement=void 0),this.T.metrics.push(m({},e,{$current_url:n,$session_id:i.sessionId,$window_id:i.windowId,timestamp:Date.now()})),this.T.metrics.length===this.allowedMetrics.length&&this.Hs()):r4.error("Ignoring metric with value >= "+this.Ys,e))}},this.Ws=()=>{if(!this.ws){var e,t,i,n,r=p.__PosthogExtensions__;j(r)||j(r.postHogWebVitalsCallbacks)||({onLCP:e,onCLS:t,onFCP:i,onINP:n}=r.postHogWebVitalsCallbacks),e&&t&&i&&n?(this.allowedMetrics.indexOf("LCP")>-1&&e(this.nt.bind(this)),this.allowedMetrics.indexOf("CLS")>-1&&t(this.nt.bind(this)),this.allowedMetrics.indexOf("FCP")>-1&&i(this.nt.bind(this)),this.allowedMetrics.indexOf("INP")>-1&&n(this.nt.bind(this)),this.ws=!0):r4.error("web vitals callbacks not loaded - not starting")}},this._instance=e,this.Rs=!(null==(t=this._instance.persistence)||!t.props[tw]),this.startIfEnabled()}get Gs(){return this._instance.config.capture_performance}get allowedMetrics(){var e,t,i=C(this.Gs)?null==(e=this.Gs)?void 0:e.web_vitals_allowed_metrics:void 0;return $(i)?(null==(t=this._instance.persistence)?void 0:t.props[tI])||["CLS","FCP","INP","LCP"]:i}get flushToCaptureTimeoutMs(){return(C(this.Gs)?this.Gs.web_vitals_delayed_flush_ms:void 0)||5e3}get useAttribution(){var e=C(this.Gs)?this.Gs.web_vitals_attribution:void 0;return null!=e&&e}get Ys(){var e=C(this.Gs)&&D(this.Gs.__web_vitals_max_value)?this.Gs.__web_vitals_max_value:9e5;return e>0&&6e4>=e?9e5:e}get isEnabled(){var e=null==a?void 0:a.protocol;if("http:"!==e&&"https:"!==e)return r4.info("Web Vitals are disabled on non-http/https protocols"),!1;var t=C(this.Gs)?this.Gs.web_vitals:U(this.Gs)?this.Gs:void 0;return U(t)?t:this.Rs}startIfEnabled(){this.isEnabled&&!this.ws&&(r4.info("enabled, starting..."),this.ni(this.Ws))}onRemoteConfig(e){if("capturePerformance"in e){var t=C(e.capturePerformance)&&!!e.capturePerformance.web_vitals,i=C(e.capturePerformance)?e.capturePerformance.web_vitals_allowed_metrics:void 0;this._instance.persistence&&(this._instance.persistence.register({[tw]:t}),this._instance.persistence.register({[tI]:i})),this.Rs=t,this.startIfEnabled()}}ni(e){var t,i;null!=(t=p.__PosthogExtensions__)&&t.postHogWebVitalsCallbacks?e():null==(i=p.__PosthogExtensions__)||null==i.loadExternalDependency||i.loadExternalDependency(this._instance,this.useAttribution?"web-vitals-with-attribution":"web-vitals",t=>{t?r4.error("failed to load script",t):e()})}Us(){var e=n?n.location.href:void 0;if(e){var t=this._instance.config.custom_personal_data_properties;return i$(e,this._instance.config.mask_personal_data_properties?[...iU,...t||[]]:[],iW)}r4.error("Could not determine current URL")}}},{exceptionObserver:class{constructor(e){var t,i,r;this.Ws=()=>{var e;if(n&&this.isEnabled&&null!=(e=p.__PosthogExtensions__)&&e.errorWrappingFunctions){var t=p.__PosthogExtensions__.errorWrappingFunctions.wrapOnError,i=p.__PosthogExtensions__.errorWrappingFunctions.wrapUnhandledRejection,r=p.__PosthogExtensions__.errorWrappingFunctions.wrapConsoleError;try{!this.Xs&&this.Rt.capture_unhandled_errors&&(this.Xs=t(this.captureException.bind(this))),!this.Js&&this.Rt.capture_unhandled_rejections&&(this.Js=i(this.captureException.bind(this))),!this.Ks&&this.Rt.capture_console_errors&&(this.Ks=r(this.captureException.bind(this)))}catch(e){r5.error("failed to start",e),this.Qs()}}},this._instance=e,this.eo=!(null==(t=this._instance.persistence)||!t.props[ty]),this.io=new J({refillRate:null!==(i=this._instance.config.error_tracking.__exceptionRateLimiterRefillRate)&&void 0!==i?i:1,bucketSize:null!==(r=this._instance.config.error_tracking.__exceptionRateLimiterBucketSize)&&void 0!==r?r:10,refillInterval:1e4,qt:r5}),this.Rt=this.ro(),this.startIfEnabledOrStop()}ro(){var e=this._instance.config.capture_exceptions,t={capture_unhandled_errors:!1,capture_unhandled_rejections:!1,capture_console_errors:!1};return C(e)?t=m({},t,e):(j(e)?this.eo:e)&&(t=m({},t,{capture_unhandled_errors:!0,capture_unhandled_rejections:!0})),t}get isEnabled(){return this.Rt.capture_console_errors||this.Rt.capture_unhandled_errors||this.Rt.capture_unhandled_rejections}startIfEnabledOrStop(){this.isEnabled?(r5.info("enabled"),this.Qs(),this.ni(this.Ws)):this.Qs()}ni(e){var t,i;
1null!=(t=p.__PosthogExtensions__)&&t.errorWrappingFunctions&&e(),null==(i=p.__PosthogExtensions__)||null==i.loadExternalDependency||i.loadExternalDependency(this._instance,"exception-autocapture",t=>{if(t)return r5.error("failed to load script",t);e()})}Qs(){var e,t,i;null==(e=this.Xs)||e.call(this),this.Xs=void 0,null==(t=this.Js)||t.call(this),this.Js=void 0,null==(i=this.Ks)||i.call(this),this.Ks=void 0}onRemoteConfig(e){"autocaptureExceptions"in e&&(this.eo=!!e.autocaptureExceptions,this._instance.persistence&&this._instance.persistence.register({[ty]:this.eo}),this.Rt=this.ro(),this.startIfEnabledOrStop())}onConfigChange(){this.Rt=this.ro()}captureException(e){var t,i,n,r=null!==(t=null==e||null==(i=e.$exception_list)||null==(i=i[0])?void 0:i.type)&&void 0!==t?t:"Exception";this.io.consumeRateLimit(r)?r5.info("Skipping exception capture because of client rate limiting.",{exception:r}):null==(n=this._instance.exceptions)||n.sendExceptionEvent(e)}},exceptions:class{constructor(e){var t,i;this.no=[],this.so=new eK([new e8,new ta,new e9,new e6,new ts,new tr,new tt,new to],function(e){for(var t=arguments.length,i=Array(t>1?t-1:0),n=1;t>n;n++)i[n-1]=arguments[n];return function(t,n){void 0===n&&(n=0);for(var r=[],s=t.split("\n"),o=n;s.length>o;o++){var a=s[o];if(1024>=a.length){var l=e4.test(a)?a.replace(e4,"$1"):a;if(!l.match(/\S*Error: /)){for(var c of i){var u=c(l,e);if(u){r.push(u);break}}if(r.length>=50)break}}}return function(e){if(!e.length)return[];var t=Array.from(e);return t.reverse(),t.slice(0,50).map(e=>m({},e,{filename:e.filename||(t[t.length-1]||{}).filename,function:e.function||"?"}))}(r)}}("web:javascript",e2,e3)),this._instance=e,this.no=null!==(t=null==(i=this._instance.persistence)?void 0:i.get_property(tb))&&void 0!==t?t:[]}onRemoteConfig(e){var t,i,n;if("errorTracking"in e){var r=null!==(t=null==(i=e.errorTracking)?void 0:i.suppressionRules)&&void 0!==t?t:[],s=null==(n=e.errorTracking)?void 0:n.captureExtensionExceptions;this.no=r,this._instance.persistence&&this._instance.persistence.register({[tb]:this.no,[tE]:s})}}get oo(){var e,t=!!this._instance.get_property(tE),i=this._instance.config.error_tracking.captureExtensionExceptions;return null!==(e=null!=i?i:t)&&void 0!==e&&e}buildProperties(e,t){return this.so.buildFromUnknown(e,{syntheticException:null==t?void 0:t.syntheticException,mechanism:{handled:null==t?void 0:t.handled}})}sendExceptionEvent(e){var t=e.$exception_list;if(this.ao(t)){if(this.lo(t))return void sP.info("Skipping exception capture because a suppression rule matched");if(!this.oo&&this.uo(t))return void sP.info("Skipping exception capture because it was thrown by an extension");if(!this._instance.config.error_tracking.__capturePostHogExceptions&&this.ho(t))return void sP.info("Skipping exception capture because it was thrown by the PostHog SDK")}return this._instance.capture("$exception",e,{_noTruncate:!0,_batchKey:"exceptionEvent",zr:!0})}lo(e){if(0===e.length)return!1;var t=e.reduce((e,t)=>{var{type:i,value:n}=t;return N(i)&&i.length>0&&e.$exception_types.push(i),N(n)&&n.length>0&&e.$exception_values.push(n),e},{$exception_types:[],$exception_values:[]});return this.no.some(e=>{var i=e.values.map(e=>{var i,n=n2[e.operator],r=R(e.value)?e.value:[e.value],s=null!==(i=t[e.key])&&void 0!==i?i:[];return r.length>0&&n(r,s)});return"OR"===e.type?i.some(Boolean):i.every(Boolean)})}uo(e){return e.flatMap(e=>{var t,i;return null!==(t=null==(i=e.stacktrace)?void 0:i.frames)&&void 0!==t?t:[]}).some(e=>e.filename&&e.filename.startsWith("chrome-extension://"))}ho(e){if(e.length>0){var t,i,n,r,s=null!==(t=null==(i=e[0].stacktrace)?void 0:i.frames)&&void 0!==t?t:[],o=s[s.length-1];return null!==(n=null==o||null==(r=o.filename)?void 0:r.includes("posthog.com/static"))&&void 0!==n&&n}return!1}ao(e){return!$(e)&&R(e)}}},sD,{siteApps:class{constructor(e){this._instance=e,this.fo=[],this.apps={}}get isEnabled(){return!!this._instance.config.opt_in_site_apps}po(e,t){if(t){var i=this.globalsForEvent(t);this.fo.push(i),this.fo.length>1e3&&(this.fo=this.fo.slice(10))}}get siteAppLoaders(){var e;return null==(e=p._POSTHOG_REMOTE_CONFIG)||null==(e=e[this._instance.config.token])?void 0:e.siteApps}initialize(){if(this.isEnabled){var e=this._instance._addCaptureHook(this.po.bind(this));this.mo=()=>{e(),this.fo=[],this.mo=void 0}}}globalsForEvent(e){if(!e)throw Error("Event payload is required");var t,i,n,r,s,o,a,l={},c=this._instance.get_property("$groups")||[];for(var[u,d]of Object.entries(this._instance.get_property("$stored_group_properties")||{}))l[u]={id:c[u],type:u,properties:d};var{$set_once:h,$set:p}=e;return{event:m({},y(e,sa),{properties:m({},e.properties,p?{$set:m({},null!==(t=null==(i=e.properties)?void 0:i.$set)&&void 0!==t?t:{},p)}:{},h?{$set_once:m({},null!==(n=null==(r=e.properties)?void 0:r.$set_once)&&void 0!==n?n:{},h)}:{}),elements_chain:null!==(s=null==(o=e.properties)?void 0:o.$elements_chain)&&void 0!==s?s:"",distinct_id:null==(a=e.properties)?void 0:a.distinct_id}),person:{properties:this._instance.get_property("$stored_person_properties")},groups:l}}setupSiteApp(e){var t=this.apps[e.id],i=()=>{var i;!t.errored&&this.fo.length&&(sl.info("Processing "+this.fo.length+" events for site app with id "+e.id),this.fo.forEach(e
1=>null==t.processEvent?void 0:t.processEvent(e)),t.processedBuffer=!0),Object.values(this.apps).every(e=>e.processedBuffer||e.errored)&&(null==(i=this.mo)||i.call(this))},n=!1,r=r=>{t.errored=!r,t.loaded=!0,sl.info("Site app with id "+e.id+" "+(r?"loaded":"errored")),n&&i()};try{var{processEvent:s}=e.init({posthog:this._instance,callback(e){r(e)}});s&&(t.processEvent=s),n=!0}catch(t){sl.error(sc+e.id,t),r(!1)}if(n&&t.loaded)try{i()}catch(i){sl.error("Error while processing buffered events PostHog app with config id "+e.id,i),t.errored=!0}}yo(){var e=this.siteAppLoaders||[];for(var t of e)this.apps[t.id]={id:t.id,loaded:!1,errored:!1,processedBuffer:!1};for(var i of e)this.setupSiteApp(i)}bo(e){if(0!==Object.keys(this.apps).length){var t=this.globalsForEvent(e);for(var i of Object.values(this.apps))try{null==i.processEvent||i.processEvent(t)}catch(t){sl.error("Error while processing event "+e.event+" for site app "+i.id,t)}}}onRemoteConfig(e){var t,i,n,r=this;if(null!=(t=this.siteAppLoaders)&&t.length)return this.isEnabled?(this.yo(),void this._instance.on("eventCaptured",e=>this.bo(e))):void sl.error('PostHog site apps are disabled. Enable the "opt_in_site_apps" config to proceed.');if(null==(i=this.mo)||i.call(this),null!=(n=e.siteApps)&&n.length){if(this.isEnabled){var s=function(e){var t;p["__$$ph_site_app_"+e]=r._instance,null==(t=p.__PosthogExtensions__)||null==t.loadSiteApp||t.loadSiteApp(r._instance,a,t=>{if(t)return sl.error(sc+e,t)})};for(var{id:o,url:a}of e.siteApps)s(o)}else sl.error('PostHog site apps are disabled. Enable the "opt_in_site_apps" config to proceed.')}}}},sG,{tracingHeaders:class{constructor(e){this.wo=void 0,this._o=void 0,this.Ws=()=>{var e,t;j(this.wo)&&(null==(e=p.__PosthogExtensions__)||null==(e=e.tracingHeadersPatchFns)||e._patchXHR(this._instance.config.__add_tracing_headers||[],this._instance.get_distinct_id(),this._instance.sessionManager)),j(this._o)&&(null==(t=p.__PosthogExtensions__)||null==(t=t.tracingHeadersPatchFns)||t._patchFetch(this._instance.config.__add_tracing_headers||[],this._instance.get_distinct_id(),this._instance.sessionManager))},this._instance=e}initialize(){this.startIfEnabledOrStop()}ni(e){var t,i;null!=(t=p.__PosthogExtensions__)&&t.tracingHeadersPatchFns&&e(),null==(i=p.__PosthogExtensions__)||null==i.loadExternalDependency||i.loadExternalDependency(this._instance,"tracing-headers",t=>{if(t)return r3.error("failed to load script",t);e()})}startIfEnabledOrStop(){var e,t;this._instance.config.__add_tracing_headers?this.ni(this.Ws):(null==(e=this.wo)||e.call(this),null==(t=this._o)||t.call(this),this.wo=void 0,this._o=void 0)}}},{toolbar:class{constructor(e){this.instance=e}No(e){p.ph_toolbar_state=e}Mo(){var e;return null!==(e=p.ph_toolbar_state)&&void 0!==e?e:0}initialize(){return this.maybeLoadToolbar()}maybeLoadToolbar(e,t,i){if(void 0===e&&(e=void 0),void 0===t&&(t=void 0),void 0===i&&(i=void 0),ia(this.instance.config)||!n||!o)return!1;e=null!=e?e:n.location,i=null!=i?i:n.history;try{if(!t){try{n.localStorage.setItem("test","test"),n.localStorage.removeItem("test")}catch(e){return!1}t=null==n?void 0:n.localStorage}var r,s=sf||iD(e.hash,"__posthog")||iD(e.hash,"state"),a=s?it(()=>JSON.parse(atob(decodeURIComponent(s))))||it(()=>JSON.parse(decodeURIComponent(s))):null;return a&&"ph_authorize"===a.action?((r=a).source="url",r&&Object.keys(r).length>0&&(a.desiredHash?e.hash=a.desiredHash:i?i.replaceState(i.state,"",e.pathname+e.search):e.hash="")):((r=JSON.parse(t.getItem(s_)||"{}")).source="localstorage",delete r.userIntent),!(!r.token||this.instance.config.token!==r.token||(this.loadToolbar(r),0))}catch(e){return!1}}Fo(e){var t=p.ph_load_toolbar||p.ph_load_editor;!$(t)&&A(t)?t(e,this.instance):sm.warn("No toolbar load function found")}loadToolbar(e){var t,i=!(null==o||!o.getElementById(tV));if(!n||i)return!1;var r="custom"===this.instance.requestRouter.region&&this.instance.config.advanced_disable_toolbar_metrics,s=m({token:this.instance.config.token},e,{apiURL:this.instance.requestRouter.endpointFor("ui")},r?{instrument:!1}:{});return(n.localStorage.setItem(s_,JSON.stringify(m({},s,{source:void 0}))),2===this.Mo())?this.Fo(s):0===this.Mo()&&(this.No(1),null==(t=p.__PosthogExtensions__)||null==t.loadExternalDependency||t.loadExternalDependency(this.instance,"toolbar",e=>{if(e)return sm.error("[Toolbar] Failed to load",e),void this.No(0);this.No(2),this.Fo(s)}),io(n,"turbolinks:load",()=>{this.No(0),this.loadToolbar(s)})),!0}Oo(e){return this.loadToolbar(e)}maybeLoadEditor(e,t,i){return void 0===e&&(e=void 0),void 0===t&&(t=void 0),void 0===i&&(i=void 0),this.maybeLoadToolbar(e,t,i)}}},sU,{conversations:class{constructor(e){this.Po=void 0,this._conversationsManager=null,this.Lo=!1,this.Do=null,this._instance=e}initialize(){this.loadIfEnabled()}onRemoteConfig(e){if(!this._instance.config.disable_conversations){var t=e.conversations;$(t)||(U(t)?this.Po=t:(this.Po=t.enabled,this.Do=t),this.loadIfEnabled())}}reset(){var e;null==(e=this._conversationsManager)||e.reset(),this._conversationsManager=null,this.Po=void 0,this.Do=null}loadIfEnabled(){if(!(this._conversationsManager||this.Lo||this._instance.config.disable_conversations||ia(this._instance.config)||this._instance.config.cookieless_mode&&this._instance.consent.isOptedOut())){var e=null==p?void 0:p.__PosthogExtensions__;if(e&&!j(this.Po)&&this.Po){if(this.Do&&this.Do.token){this.Lo=!0;try{var t=e.initConversations;if(t)return this.Bo(t),void(this.Lo=!1);var i=e.loadExternalDependency;if(!i)return void this.jo(tX);i(this._instance,"conversations",t=>{t||!e.initConversations?this.jo("Could not load conversations script",t):this.Bo(e.initConversations),this.Lo=!1})}catch(e){this.jo("Error initializing conversations",e),this.Lo=!1}}else sL.error("Conversations enabled but missing token in remote config.")}}}Bo(e){if(this.Do)try{this._conversationsManager=e(this.Do,this._instance),sL.info("Conversations loaded successfully")}catch(e){this.jo("Error completing conversations initialization",e)}else sL.error("Cannot complete initialization: remote config is null")}jo(e,t){sL.error(e,t),this._conversationsManager=null,this.Lo=!1}show(){this._conversationsManager?this._conversationsManager.show():sL.warn("Conversations not loaded yet.")}hide(){this._conversationsManager&&this._conversationsManager.hide()}isAvailable(){return!0===this.Po&&!M(this._conversationsManager)}isVisible(){var e,t;return null!==(e=null==(t=this._conversationsManager)?void 0:t.isVisible())&&void 0!==e&&e}
1sendMessage(e,t,i){var n=this;return _(function*(){return n._conversationsManager?n._conversationsManager.sendMessage(e,t,i):(sL.warn(sj),null)})()}getMessages(e,t){var i=this;return _(function*(){return i._conversationsManager?i._conversationsManager.getMessages(e,t):(sL.warn(sj),null)})()}markAsRead(e){var t=this;return _(function*(){return t._conversationsManager?t._conversationsManager.markAsRead(e):(sL.warn(sj),null)})()}getTickets(e){var t=this;return _(function*(){return t._conversationsManager?t._conversationsManager.getTickets(e):(sL.warn(sj),null)})()}requestRestoreLink(e){var t=this;return _(function*(){return t._conversationsManager?t._conversationsManager.requestRestoreLink(e):(sL.warn(sj),null)})()}restoreFromToken(e){var t=this;return _(function*(){return t._conversationsManager?t._conversationsManager.restoreFromToken(e):(sL.warn(sj),null)})()}restoreFromUrlToken(){var e=this;return _(function*(){return e._conversationsManager?e._conversationsManager.restoreFromUrlToken():(sL.warn(sj),null)})()}getCurrentTicketId(){var e,t;return null!==(e=null==(t=this._conversationsManager)?void 0:t.getCurrentTicketId())&&void 0!==e?e:null}getWidgetSessionId(){var e,t;return null!==(e=null==(t=this._conversationsManager)?void 0:t.getWidgetSessionId())&&void 0!==e?e:null}Kr(){var e;null==(e=this._conversationsManager)||e.setIdentity()}Qr(){var e;null==(e=this._conversationsManager)||e.clearIdentity()}}},{logs:class{constructor(e){var t;this.qo=!1,this.Zo=!1,this.qt=tu("[logs]"),this.$o=[],this.Vo=0,this.Ho=0,this.zo=!1,this._instance=e,this._instance&&null!=(t=this._instance.config.logs)&&t.captureConsoleLogs&&(this.qo=!0)}initialize(){this.loadIfEnabled()}onRemoteConfig(e){var t,i=null==(t=e.logs)?void 0:t.captureConsoleLogs;!$(i)&&i&&(this.qo=!0,this.loadIfEnabled())}reset(){this.$o=[],this.Ni&&(clearTimeout(this.Ni),this.Ni=void 0),this.Vo=0,this.Ho=0,this.zo=!1}loadIfEnabled(){if(this.qo&&!this.Zo){var e=null==p?void 0:p.__PosthogExtensions__;if(e){var t=e.loadExternalDependency;t?t(this._instance,"logs",t=>{var i;t||null==(i=e.logs)||!i.initializeLogs?this.qt.error("Could not load logs script",t):(e.logs.initializeLogs(this._instance),this.Zo=!0)}):this.qt.error(tX)}else this.qt.error("PostHog Extensions not found.")}}captureLog(e){var t,i,n,r,s,o;if(this._instance.is_capturing()){if(e&&e.body){var a=null!==(t=null==(i=this._instance.config.logs)?void 0:i.flushIntervalMs)&&void 0!==t?t:3e3,l=null!==(n=null==(r=this._instance.config.logs)?void 0:r.maxLogsPerInterval)&&void 0!==n?n:1e3,c=Date.now();if(a>c-this.Ho||(this.Ho=c,this.Vo=0,this.zo=!1),l>this.Vo){this.Vo++;var u=function(e,t){var{text:i,number:n}=sN[e.level||"info"]||sF,r=String(Date.now())+"000000",s={};t.distinctId&&(s.posthogDistinctId=t.distinctId),t.sessionId&&(s.sessionId=t.sessionId),t.currentUrl&&(s["url.full"]=t.currentUrl),t.activeFeatureFlags&&t.activeFeatureFlags.length>0&&(s.feature_flags=t.activeFeatureFlags);var o=m({},s,e.attributes||{}),a={timeUnixNano:r,observedTimeUnixNano:r,severityNumber:n,severityText:i,body:{stringValue:e.body},attributes:sM(o)};return e.trace_id&&(a.traceId=e.trace_id),e.span_id&&(a.spanId=e.span_id),j(e.trace_flags)||(a.flags=e.trace_flags),a}(e,this.Uo());this.$o.push({record:u}),(null!==(s=null==(o=this._instance.config.logs)?void 0:o.maxBufferSize)&&void 0!==s?s:100)>this.$o.length?this.Yo():this.flushLogs()}else this.zo||(this.qt.warn("captureLog dropping logs: exceeded "+l+" logs per "+a+"ms"),this.zo=!0)}else this.qt.warn("captureLog requires a body")}}get logger(){return this.Wo||(this.Wo={trace:(e,t)=>this.captureLog({body:e,level:"trace",attributes:t}),debug:(e,t)=>this.captureLog({body:e,level:"debug",attributes:t}),info:(e,t)=>this.captureLog({body:e,level:"info",attributes:t}),warn:(e,t)=>this.captureLog({body:e,level:"warn",attributes:t}),error:(e,t)=>this.captureLog({body:e,level:"error",attributes:t}),fatal:(e,t)=>this.captureLog({body:e,level:"fatal",attributes:t})}),this.Wo}flushLogs(e){if(this.Ni&&(clearTimeout(this.Ni),this.Ni=void 0),0!==this.$o.length){var t,i=this.$o;this.$o=[];var n=this._instance.config.logs,r=m({"service.name":(null==n?void 0:n.serviceName)||"unknown_service"},(null==n?void 0:n.environment)&&{"deployment.environment":n.environment},(null==n?void 0:n.serviceVersion)&&{"service.version":n.serviceVersion},null==n?void 0:n.resourceAttributes),s=(t=i.map(e=>e.record),{resourceLogs:[{resource:{attributes:sM(r)},scopeLogs:[{scope:{name:v.LIB_NAME},logRecords:t}]}]}),o=this._instance.requestRouter.endpointFor("api","/i/v1/logs")+"?token="+encodeURIComponent(this._instance.config.token);this._instance.Pr({method:"POST",url:o,data:s,compression:"best-available",batchKey:"logs",transport:e})}}Yo(){var e,t;this.Ni||(this.Ni=setTimeout(()=>{this.Ni=void 0,this.flushLogs()},null!==(e=null==(t=this._instance.config.logs)?void 0:t.flushIntervalMs)&&void 0!==e?e:3e3))}Uo(){var e,t={lib:v.LIB_NAME};if(t.distinctId=this._instance.get_distinct_id(),this._instance.sessionManager){var{sessionId:i}=this._instance.sessionManager.checkAndGetSessionAndWindowId(!0);t.sessionId=i}if(null!=p&&null!=(e=p.location)&&e.href&&(t.currentUrl=p.location.href),this._instance.featureFlags){var n=this._instance.featureFlags.getFlags();n&&n.length>0&&(t.activeFeatureFlags=n)}return t}}});rS.__defaultExtensionClasses=m({},sH);var sW,sq=(sW=rc[r_]=new rS,function(){function e(){e.done||(e.done=!0,rm=!1,t6(rc,function(e){e._dom_loaded()}))}null!=o&&o.addEventListener?"complete"===o.readyState?e():io(o,"DOMContentLoaded",e,{capture:!1}):n&&tc.error("Browser doesn't support `document.addEventListener` so PostHog couldn't be initialized")}(),sW)},23837:function(e,t,i){(window.__NEXT_P=window.__NEXT_P||[]).push(["/_app",function(){return i(65877)}])},27401:function(e,t,i){"use strict";e.exports={locales:["en","it","es","fr","ja","pt","de","ar","zh","ru","id","ko","cs","vi","tr","sv","pl","el","nl","et","ro","sl"],defaultLocale:"en",pages:{"/blog/[slug]":[],"/templates/*":[],"/templates":[],"/generate/topic-to-ppt":["common","generate"],"/generate/notes-to-ppt":["common","generate"],"/generate/script-to-ppt":["common","generate"],"/generate/document-to-ppt":["common","generate"],"/":["common","translation"],"/checkout-success":["common","translation"],"/auth/callback":["common","translation"],"/use-cases/students":["common","translation"],"/use-cases/professionals":["common","translation"],"/use-cases/educators":["common","translation"],"/about":["common","translation"],"/pricing":["common","translation"],"/pricing/teams/checkout-success":["common","translation"],"/compare/[slug]":["common","translation"],"/chatgpt-presentation-maker":["common","translation"],"/ai-powerpoint-generator":["common","translation"],"/ai-google-slides-generator":["common","translation"],"/ai-presentation-maker":["common","translation"],"/terms-of-use":["common","translation"],"/privacy-policy":["common","translation"],"/platform":["translation","landing"],"/free-tools":["common","tools"],"/free-tools/powerpoint-compressor":["common","tools"],"/free-tools/combine-merge-powerpoint":["common","tools"],"/free-tools/powerpoint-to-pdf":["common","tools"],"/free-tools/pdf-to-ppt":["common","tools"],"/free-tools/pdf-to-google-slides":["common","tools"],"/free-tools/word-to-ppt":["common","tools"],"/free-tools/html-to-ppt":["common","tools"],"/free-tools/powerpoint-to-text":["common","tools"],"/free-tools/ai-powerpoint-summarizer":["common","tools"],"/free-tools/extract-images-from-powerpoint":["common","tools"],"/free-tools/split-powerpoint":["common","tools"],"/free-tools/download-expired":["common","tools"],"*":["common"]},loadLocaleFrom:(e,t)=>i(15330)(`./${e}/${t}.json`).then(e=>e.default)}},94817:function(e,t,i){"use strict";i.d(t,{Cq:function(){return f},F5:function(){return c},Gd:function(){return d},PN:function(){return p},PX:function(){return g},Z2:function(){return u},_c:function(){return h},uA:function(){return v}});let n=["/blog","/compare","/quick-animate-for-google-slides","/template","/templates"],r=()=>"https://www.slidesai.io".replace(/\/+$/,""),s=(e="/")=>{let t=e.split(/[?#]/,1)[0]||"/",i=t.startsWith("/")?t:`/${t}`;return"/"===i?"/":i.replace(/\/+$/,"")},o=e=>e.replace(/[.*+?^${}()|[\]\\]/g,"\\$&"),a=e=>{let t=s(e);return n.some(e=>t===e||t.startsWith(`${e}/`))},l=(e,t=[])=>{let i=s(e);
1if("/"===i||0===t.length)return i;let n=t.map(o).join("|"),r=RegExp(`^/(${n})(?=/|$)`),a=i.replace(r,"")||"/";return a.startsWith("/")?a:`/${a}`},c=(e,{locale:t,localized:i=!a(e)}={})=>{let n=s(e),o=r();return i&&t&&"en"!==t?"/"===n?`${o}/${t}`:`${o}/${t}${n}`:"/"===n?`${o}/`:`${o}${n}`},u=(e,{locale:t,localized:i,locales:n}={})=>c(l(e,n),{locale:t,localized:i}),d=(e=[],t,{localized:i=!a(t)}={})=>{let n=c(t,{localized:!1});return i?[...e.map(e=>({hrefLang:e,href:c(t,{locale:e,localized:!0})})),{hrefLang:"x-default",href:n}]:[{hrefLang:"en",href:n},{hrefLang:"x-default",href:n}]},h=(e,t={})=>({title:e("mainPageTitle",null,{default:"AI Presentation Maker | Free PPT & Google Slides Generator"}),description:e("mainPageDescription",null,{default:"Create stunning PPTs & Slides in seconds with our free AI Presentation Maker! Instantly turn text into slides-perfect for teachers, students, and professionals."}),openGraph:{title:e("mainOpenGraphTitle",null,{default:"AI Presentation Maker | Free PPT & Google Slides Generator"}),type:"website",url:c(t.path||"/",t),description:e("mainOpenGraphDescription",null,{default:"Create stunning PPTs & Slides in seconds with our free AI Presentation Maker! Instantly turn text into slides-perfect for teachers, students, and professionals."}),siteName:"SlidesAI",images:[{url:"https://cdn.slidesai.io/website/og-image.png",width:1800,height:941,alt:e("mainOpenGraphImageAlt",null,{default:"SlidesAI OG Image"})}]},twitter:{cardType:"summary_large_image",site:"@SlidesAI_io",handle:"@SlidesAI_io"}}),p=e=>({title:e("blogPageTitle",null,{default:"Learn powerful presentation skills with SlidesAI Blogs"}),description:e("blogPageDescription",null,{default:"Learn tips and tricks to enhance your presentations and improve your productivity with SlidesAI Blogs."}),openGraph:{title:e("blogOpenGraphTitle",null,{default:"Learn powerful presentation skills with SlidesAI Blogs"}),description:e("blogOpenGraphDescription",null,{default:"Learn tips and tricks to enhance your presentations and improve your productivity with SlidesAI Blogs."}),url:"https://slidesai.io/blog",images:[{url:"https://cdn.slidesai.io/website/og-image.png",width:1800,height:941,alt:e("blogOpenGraphImageAlt",null,{default:"SlidesAI Blog OG Image"})}]},twitter:{cardType:"summary_large_image",site:"@SlidesAI_io",handle:"@SlidesAI_io"}}),g={title:"Category Page",description:"Available posts of the selected cateogry",openGraph:{title:"Category Page",description:"Available posts of the selected cateogry",url:"https://slidesai.io/guides",images:[{url:"https://cdn.slidesai.io/website/og-image.png",width:1800,height:941,alt:"SlidesAI Guides OG Image"}]}},v={title:"Free Google Slides and PowerPoint Presentation Templates | SlidesAI",description:"Download SlidesAI's free, professionally designed Google Slides and PowerPoint presentation templates for business, education, and creative needs.",openGraph:{title:"Free Google Slides and PowerPoint Presentation Templates | SlidesAI",description:"Download SlidesAI's free, professionally designed Google Slides and PowerPoint presentation templates for business, education, and creative needs.",url:"https://slidesai.io/templates",images:[{url:"https://cdn.slidesai.io/website/og-image.png",width:1800,height:941,alt:"SlidesAI Template OG Image"}]}},f={title:"Comprehensive Comparisons: SlidesAI vs Other Presentation Tools",description:"AI Presentation Tools Face-Off: SlideAI or others? Compare features, ease, and design. Click to reveal the ultimate choice for powerful storytelling.",openGraph:{title:"Compare SlidesAI with other presentation tools",description:"Discover how SlidesAI compares with other presentation tools in the market",url:"https://slidesai.io/compare",images:[{url:"https://cdn.slidesai.io/website/og-image.png",width:1800,height:941,alt:"SlidesAI Compare OG Image"}]}}},89435:function(e,t,i){"use strict";i.d(t,{iz:function(){return o},mr:function(){return a}});var n=i(43577),r=i(57242);let s=r.createContext({globalLocale:"",setGlobalLocale:()=>{}}),o=({children:e})=>{let[t,i]=(0,r.useState)("");return(0,n.jsx)(s.Provider,{value:{globalLocale:t,setGlobalLocale:i},children:(0,n.jsx)(n.Fragment,{children:e})})},a=()=>(0,r.useContext)(s)},65877:function(e,t,i){"use strict";i.r(t),i.d(t,{default:function(){return H}});var n=i(43577),r=i(27401),s=i.n(r),o=i(57242),a=i(5762),l=i(12380),c=i(76379),u=i(5724),d=function(){return(d=Object.assign||function(e){for(var t,i=1,n=arguments.length;i<n;i++)for(var r in t=arguments[i])Object.prototype.hasOwnProperty.call(t,r)&&(e[r]=t[r]);return e}).apply(this,arguments)},h=(0,o.createContext)({ns:{},config:{}});function p(e){var t,i,n=e.lang,r=e.namespaces,s=e.children,p=e.config,g=(0,u.Z)().lang,v=(0,a.useRouter)()||{},f=v.locale,_=v.defaultLocale,m=(0,o.useContext)(h),y=d(d(d({},"undefined"==typeof window?{}:(null===(i=null===(t=window.__NEXT_DATA__)||void 0===t?void 0:t.props)||void 0===i?void 0:i.__namespaces)||{}),m.ns),void 0===r?{}:r),b=n||g||f||_||"",E=d(d({},m.config),void 0===p?{}:p),w=E.localesToIgnore||["default"],S=!b||w.includes(b),T=new Intl.PluralRules(S?void 0:b),I=(0,c.Z)({config:E,allNamespaces:y,pluralRules:T,lang:b});return o.createElement(l.Z.Provider,{value:{lang:b,t:I}},o.createElement(h.Provider,{value:{ns:y,config:E}},s))}
1var g=function(e,t,i,n){return new(i||(i=Promise))(function(r,s){function o(e){try{l(n.next(e))}catch(e){s(e)}}function a(e){try{l(n.throw(e))}catch(e){s(e)}}function l(e){var t;e.done?r(e.value):((t=e.value)instanceof i?t:new i(function(e){e(t)})).then(o,a)}l((n=n.apply(e,t||[])).next())})},v=function(e,t){var i,n,r,s,o={label:0,sent:function(){if(1&r[0])throw r[1];return r[1]},trys:[],ops:[]};return s={next:a(0),throw:a(1),return:a(2)},"function"==typeof Symbol&&(s[Symbol.iterator]=function(){return this}),s;function a(a){return function(l){return function(a){if(i)throw TypeError("Generator is already executing.");for(;s&&(s=0,a[0]&&(o=0)),o;)try{if(i=1,n&&(r=2&a[0]?n.return:a[0]?n.throw||((r=n.return)&&r.call(n),0):n.next)&&!(r=r.call(n,a[1])).done)return r;switch(n=0,r&&(a=[2&a[0],r.value]),a[0]){case 0:case 1:r=a;break;case 4:return o.label++,{value:a[1],done:!1};case 5:o.label++,n=a[1],a=[0];continue;case 7:a=o.ops.pop(),o.trys.pop();continue;default:if(!(r=(r=o.trys).length>0&&r[r.length-1])&&(6===a[0]||2===a[0])){o=0;continue}if(3===a[0]&&(!r||a[1]>r[0]&&a[1]<r[3])){o.label=a[1];break}if(6===a[0]&&o.label<r[1]){o.label=r[1],r=a;break}if(r&&o.label<r[2]){o.label=r[2],o.ops.push(a);break}r[2]&&o.ops.pop(),o.trys.pop();continue}a=t.call(e,o)}catch(e){a=[6,e],n=0}finally{i=r=0}if(5&a[0])throw a[1];return{value:a[0]?a[1]:void 0,done:!0}}([a,l])}}},f=function(e,t,i){if(i||2==arguments.length)for(var n,r=0,s=t.length;r<s;r++)!n&&r in t||(n||(n=Array.prototype.slice.call(t,0,r)),n[r]=t[r]);return e.concat(n||Array.prototype.slice.call(t))};function _(e){return e.reduce(function(e,t){return e.concat(t)},[])}var m=i(75409),y=function(){return(y=Object.assign||function(e){for(var t,i=1,n=arguments.length;i<n;i++)for(var r in t=arguments[i])Object.prototype.hasOwnProperty.call(t,r)&&(e[r]=t[r]);return e}).apply(this,arguments)},b=function(e,t){var i,n,r,s,o={label:0,sent:function(){if(1&r[0])throw r[1];return r[1]},trys:[],ops:[]};return s={next:a(0),throw:a(1),return:a(2)},"function"==typeof Symbol&&(s[Symbol.iterator]=function(){return this}),s;function a(a){return function(l){return function(a){if(i)throw TypeError("Generator is already executing.");for(;s&&(s=0,a[0]&&(o=0)),o;)try{if(i=1,n&&(r=2&a[0]?n.return:a[0]?n.throw||((r=n.return)&&r.call(n),0):n.next)&&!(r=r.call(n,a[1])).done)return r;switch(n=0,r&&(a=[2&a[0],r.value]),a[0]){case 0:case 1:r=a;break;case 4:return o.label++,{value:a[1],done:!1};case 5:o.label++,n=a[1],a=[0];continue;case 7:a=o.ops.pop(),o.trys.pop();continue;default:if(!(r=(r=o.trys).length>0&&r[r.length-1])&&(6===a[0]||2===a[0])){o=0;continue}if(3===a[0]&&(!r||a[1]>r[0]&&a[1]<r[3])){o.label=a[1];break}if(6===a[0]&&o.label<r[1]){o.label=r[1],r=a;break}if(r&&o.label<r[2]){o.label=r[2],o.ops.push(a);break}r[2]&&o.ops.pop(),o.trys.pop();continue}a=t.call(e,o)}catch(e){a=[6,e],n=0}finally{i=r=0}if(5&a[0])throw a[1];return{value:a[0]?a[1]:void 0,done:!0}}([a,l])}}},E=function(){return(E=Object.assign||function(e){for(var t,i=1,n=arguments.length;i<n;i++)for(var r in t=arguments[i])Object.prototype.hasOwnProperty.call(t,r)&&(e[r]=t[r]);return e}).apply(this,arguments)},w=function(e,t){var i,n,r,s,o={label:0,sent:function(){if(1&r[0])throw r[1];return r[1]},trys:[],ops:[]};return s={next:a(0),throw:a(1),return:a(2)},"function"==typeof Symbol&&(s[Symbol.iterator]=function(){return this}),s;function a(a){return function(l){return function(a){if(i)throw TypeError("Generator is already executing.");for(;s&&(s=0,a[0]&&(o=0)),o;)try{if(i=1,n&&(r=2&a[0]?n.return:a[0]?n.throw||((r=n.return)&&r.call(n),0):n.next)&&!(r=r.call(n,a[1])).done)return r;switch(n=0,r&&(a=[2&a[0],r.value]),a[0]){case 0:case 1:r=a;break;case 4:return o.label++,{value:a[1],done:!1};case 5:o.label++,n=a[1],a=[0];continue;case 7:a=o.ops.pop(),o.trys.pop();continue;default:if(!(r=(r=o.trys).length>0&&r[r.length-1])&&(6===a[0]||2===a[0])){o=0;continue}if(3===a[0]&&(!r||a[1]>r[0]&&a[1]<r[3])){o.label=a[1];break}if(6===a[0]&&o.label<r[1]){o.label=r[1],r=a;break}if(r&&o.label<r[2]){o.label=r[2],o.ops.push(a);break}r[2]&&o.ops.pop(),o.trys.pop();continue}a=t.call(e,o)}catch(e){a=[6,e],n=0}finally{i=r=0}if(5&a[0])throw a[1];return{value:a[0]?a[1]:void 0,done:!0}}([a,l])}}},S=i(79535),T=i.n(S),I=i(35218),k=i.n(I),x=i(45407),O=()=>Promise.all([i.e(7753),i.e(3022),i.e(7014),i.e(2876)]).then(i.bind(i,2876)).then(e=>e.domAnimation),P=i(33326),R=i.n(P),A=i(68725),C=i.n(A),L=i(38867),j=i(12585);let N=!1,F=e=>{if(N)return;let t=window.GLOBAL_ENV?.NODE_ENV==="development";L.ZP.init((0,j.uK)(),{api_host:"https://us.i.posthog.com",opt_in_site_apps:!0,autocapture:!1,persistence:"localStorage+cookie",disable_session_recording:!1,session_recording:{maskAllInputs:!1},debug:t,..."web"===e?{api_host:"https://kamikaze.slidesai.io",loaded:e=>{e.register({app:"web"})},enable_heatmaps:!0,disable_session_recording:!1}:{}}),N=!0};var M=i(69240);i(7611),i(20964),i(96154);var $=i(76473),D=i(94817),G=i(89435),U=i(75409),H=function(e,t){var n=this;function r(i){var n,r,s=t.defaultLocale;return o.createElement(p,{lang:(null===(n=i.pageProps)||void 0===n?void 0:n.__lang)||i.__lang||s,namespaces:(null===(r=i.pageProps)||void 0===r?void 0:r.__namespaces)||i.__namespaces,config:t},o.createElement(e,E({},i)))}return void 0===t&&(t={}),t.isLoader||!1===t.loader||console.warn('\uD83D\uDEA8 [next-translate] You can remove the "appWithI18n" HoC on the _app.js, unless you set "loader: false" in your i18n config file.'),"function"==typeof t.staticsHoc&&t.staticsHoc(r,e),"undefined"==typeof window?i.g.i18nConfig=t:window.i18nConfig=t,t.skipInitialProps||(r.getInitialProps=function(r){var s,o,a;return s=void 0,o=void 0,a=function(){var n,s,o;return w(this,function(a){switch(a.label){case 0:if(n=E(E({},r.ctx||{}),r||{}),s={pageProps:{}},!e.getInitialProps)return[3,2];return[4,e.getInitialProps(r)];case 1:s=a.sent()||{},a.label=2;case 2:return o=[E({},s)],[4,function(e){var t,n,r,s,o,a;return void 0===e&&(e={}),r=this,s=void 0,o=void 0,a=function(){var r,s,o,a,l,c;return b(this,function(u){switch(u.label){case 0:var d;if(s=(r=y(y({},("undefined"==typeof window?i.g:window).i18nConfig),e)).localesToIgnore||["default"],o=(null===(t=r.req)||void 0===t?void 0:t.locale)||r.locale||(null===(n=r.router)||void 0===n?void 0:n.locale)||r.defaultLocale||"",!r.pathname)return console.warn('\uD83D\uDEA8 [next-translate] You forgot to pass the "pathname" inside "loadNamespaces" configuration'),[2,{__lang:o}];if(s.includes(o))return[2,{__lang:o}];return r.loaderName||!1===r.loader||console.warn('\uD83D\uDEA8 [next-translate] You can remove the "loadNamespaces" helper, unless you set "loader: false" in your i18n config file.'),void 0===(d=r.pathname.replace(/\/index$/,""))&&(d=""),a=(d.length>1&&d.endsWith("/")?d.slice(0,-1):d)||"/",[4,function(e,t,i){var n=e.pages,r=void 0===n?{}:n;return g(this,void 0,void 0,function(){var e,n,s,o,a,l,c,u=this;return v(this,function(d){switch(d.label){case 0:return e="rgx:",n=function(e){return g(u,void 0,void 0,function(){return v(this,function(t){return[2,"function"==typeof e?e(i):e||[]]})})},s=Object.keys(r).reduce(function(i,s){return s.substring(0,e.length)===e&&new RegExp(s.replace(e,"")).test(t)&&i.push(n(r[s])),i},[]),o=[[]],[4,n(r["*"])];case 1:return a=[f.apply(void 0,o.concat([d.sent(),!0]))],[4,n(r[t])];case 2:return l=[f.apply(void 0,a.concat([d.sent(),!0]))],c=_,[4,Promise.all(s)];case 3:return[2,f.apply(void 0,l.concat([c.apply(void 0,[d.sent()]),!0]))]}})})}(r,a,r)];case 1:return[4,Promise.all((l=u.sent()).map(function(e){return"function"==typeof r.loadLocaleFrom?r.loadLocaleFrom(o,e).catch(function(){return{}}):Promise.resolve({})}))];case 2:return c=u.sent()||[],function(e,t){var i=t.page,n=t.lang,r=t.namespaces;if(!1!==e.logBuild&&"undefined"==typeof window){var s=null==m.env.NODE_DISABLE_COLORS&&null==m.env.NO_COLOR&&"dumb"!==m.env.TERM&&"0"!==m.env.FORCE_COLOR,o=function(e){return s?"\x1b[36m".concat(e,"\x1b[0m"):e};console.log(o("next-translate"),"- compiled page:",o(i),"- locale:",o(n),"- namespaces:",o(r.join(", ")),"- used loader:",o(e.loaderName||"-"))}}(r,{page:a,lang:o,namespaces:l}),[2,{__lang:o,__namespaces:l.reduce(function(e,t,i){return e[t]=c[i]||null,e},{})}]}})},new(o||(o=Promise))(function(e,t){function i(e){try{l(a.next(e))}catch(e){t(e)}}function n(e){try{l(a.throw(e))}catch(e){t(e)}}function l(t){var r;t.done?e(t.value):((r=t.value)instanceof o?r:new o(function(e){e(r)})).then(i,n)}l((a=a.apply(r,s||[])).next())})}(E(E(E({},n),t),{loaderName:"getInitialProps"}))];case 3:return[2,E.apply(void 0,o.concat([a.sent()]))]}})},new(o||(o=Promise))(function(e,t){function i(e){try{l(a.next(e))}catch(e){t(e)}}function r(e){try{l(a.throw(e))}catch(e){t(e)}}function l(t){var n;t.done?e(t.value):((n=t.value)instanceof o?n:new o(function(e){e(n)})).then(i,r)}l((a=a.apply(n,s||[])).next())})}),r}(function({Component:e,pageProps:t}){let i=(0,a.useRouter)(),{i18n:r,t:s}=(0,u.Z)(),l=t?.canonicalUrl||e?.canonicalUrl||(0,D.Z2)(i.asPath,{locale:i.locale,locales:i.locales});return(0,o.useEffect)(()=>{F("web"),(0,M.Jr)()},[]),(0,o.useEffect)(()=>{},[]),(0,o.useEffect)(()=>{let e=new URLSearchParams(window.location.search);if((e.has("via")||e.has("ref")||e.has("aff"))&&!e.get("gclid")){let e=document.createElement("script");e.src="https://cdn.tolt.io/tolt.js",e.async=!0,e.setAttribute("data-tolt","8796c8aa-747c-43a4-84bc-203a974901ce"),document.head.appendChild(e)}},[]),(0,o.useEffect)(()=>{let e=!1,t=()=>{if(!e){var r,s,o,a,l,c;e=!0,r=window,s=document,a="script",r[o="profitwell"]=r[o]||function(){(r[o].q=r[o].q||[]).push(arguments)},l=s.createElement(a),c=s.getElementsByTagName(a)[0],l.async=1,l.src="https://public.profitwell.com/js/profitwell.js?auth=be3ffacea8b7a9503e0bd0726dbaf80b",c.parentNode.insertBefore(l,c),window.profitwell("start",{}
1),i.forEach(e=>window.removeEventListener(e,t)),clearTimeout(n)}},i=["mousedown","touchstart","keydown","scroll"];i.forEach(e=>window.addEventListener(e,t,{once:!0,passive:!0}));let n=setTimeout(t,3e3);return()=>{i.forEach(e=>window.removeEventListener(e,t)),clearTimeout(n)}},[]),(0,o.useEffect)(()=>{let e=!1,t=()=>{if(e)return;e=!0,window.$crisp=[],window.CRISP_WEBSITE_ID="c6d0cd68-6929-433a-8ac2-3190033c8bde";let r=document.createElement("script");r.src="https://client.crisp.chat/l.js",r.async=!0,document.head.appendChild(r),window.$crisp.push(["config","position:reverse",[!0]]),i.forEach(e=>window.removeEventListener(e,t)),clearTimeout(n)};if("true"===new URLSearchParams(window.location.search).get("openCrisp")){t();return}let i=["mousedown","touchstart","keydown","scroll"];i.forEach(e=>window.addEventListener(e,t,{once:!0,passive:!0}));let n=setTimeout(t,5e3);return()=>{i.forEach(e=>window.removeEventListener(e,t)),clearTimeout(n)}},[]),(0,o.useEffect)(()=>{if(!r||!r?.on)return;let e=()=>{let e=["ar","he","fa"].includes(r.language)?"rtl":"ltr";document.documentElement.setAttribute("dir",e)};return e(),r.on("languageChanged",e),()=>{r.off("languageChanged",e)}},[r]),(0,o.useEffect)(()=>{let e=()=>{window.dataLayer=window.dataLayer||[],window.dataLayer.push({event:"pageview",page:{url:window.location.href,title:document.title}}),L.ZP?.capture("$pageview"),"function"==typeof window.fbq&&window.fbq("track","PageView")};return i.events.on("routeChangeComplete",e),()=>{i.events.off("routeChangeComplete",e)}},[i.events]),(0,n.jsxs)("div",{className:`${T().variable} ${k().variable} contents`,children:[(0,n.jsx)(C(),{id:"gtm-script",strategy:"lazyOnload",dangerouslySetInnerHTML:{__html:"
vendor: 323 bytes, line 1
1(function(w,d,s,l,i){w[l]=w[l]||[];w[l].push({'gtm.start':new Date().getTime(),event:'gtm.js'});var f=d.getElementsByTagName(s)[0],j=d.createElement(s),dl=l!='dataLayer'?'&l='+l:'';j.async=true;j.src='https://www.googletagmanager.com/gtm.js?id='+i+dl;f.parentNode.insertBefore(j,f);})(window,document,'script','dataLayer','
1GTM-TWPL86SL
vendor: 3 bytes, line 1
1');
1"}}),(0,n.jsx)(C(),{id:"tally-script",src:"https://tally.so/widgets/embed.js",strategy:"lazyOnload"}),(0,n.jsx)(C(),{id:"meta-pixel",strategy:"afterInteractive",dangerouslySetInnerHTML:{__html:`
vendor: 396 bytes, lines 1-9
1!function(f,b,e,v,n,t,s) 2{if(f.fbq)return;n=f.fbq=function(){n.callMethod? 3n.callMethod.apply(n,arguments):n.queue.push(arguments)}; 4if(!f._fbq)f._fbq=n;n.push=n;n.loaded=!0;n.version='2.0'; 5n.queue=[];t=b.createElement(e);t.async=!0; 6t.src=v;s=b.getElementsByTagName(e)[0]; 7s.parentNode.insertBefore(t,s)}(window,document,'script', 8'https://connect.facebook.net/en_US/fbevents.js'); 9fbq('init','
91610763656785773
vendor: 28 bytes, lines 9-10
9'); 10fbq('track','PageView');
10`}}),(0,n.jsx)(C(),{id:"tiktok-pixel",strategy:"afterInteractive",dangerouslySetInnerHTML:{__html:`!function (w, d, t) { 11 w.TiktokAnalyticsObject=t;var ttq=w[t]=w[t]||[];ttq.methods=["page","track","identify","instances","debug","on","off","once","ready","alias","group","enableCookie","disableCookie","holdConsent","revokeConsent","grantConsent"],ttq.setAndDefer=function(t,e){t[e]=function(){t.push([e].concat(Array.prototype.slice.call(arguments,0)))}};for(var i=0;i<ttq.methods.length;i++)ttq.setAndDefer(ttq,ttq.methods[i]);ttq.instance=function(t){for( 12var e=ttq._i[t]||[],n=0;n<ttq.methods.length;n++)ttq.setAndDefer(e,ttq.methods[n]);return e},ttq.load=function(e,n){var r="https://analytics.tiktok.com/i18n/pixel/events.js",o=n&&n.partner;ttq._i=ttq._i||{},ttq._i[e]=[],ttq._i[e]._u=r,ttq._t=ttq._t||{},ttq._t[e]=+new Date,ttq._o=ttq._o||{},ttq._o[e]=n||{};n=document.createElement("script") 13;n.type="text/javascript",n.async=!0,n.src=r+"?sdkid="+e+"&lib="+t;e=document.getElementsByTagName("script")[0];e.parentNode.insertBefore(n,e)}; 14 15 16 ttq.load('DAHEJK3C77UC8FLK0F4G'); 17 ttq.page(); 18}(window, document, 'ttq');`}}),(0,n.jsx)($.lX,{...(0,D._c)(s),dangerouslySetAllPagesToNoIndex:"development"===U.env.NEXT_PUBLIC_APP_ENV,dangerouslySetAllPagesToNoFollow:"development"===U.env.NEXT_PUBLIC_APP_ENV}),(0,n.jsx)(R(),{children:(0,n.jsx)("link",{rel:"canonical",href:l})}),(0,n.jsx)(x.X,{features:O,children:(0,n.jsx)(G.iz,{children:(0,n.jsx)(e,{...t})})})]})},{...s(),isLoader:!0,skipInitialProps:!0,loadLocaleFrom:s()&&s().loadLocaleFrom||((e,t)=>i(27655)(`./${e}/${t}`).then(e=>e.default))})},69240:function(e,t,i){"use strict";i.d(t,{hl:function(){return a},Jr:function(){return o},NO:function(){return l}});var n={init(e){!function(e){try{var t,i,n,r,s,o;t=window,i=document,n="clarity",r="script",i.getElementById("clarity-script")||(t[n]=t[n]||function(){(t[n].q=t[n].q||[]).push(arguments)},(s=i.createElement(r)).async=1,s.src="https://www.clarity.ms/tag/"+e+"?ref=npm",s.id="clarity-script",(o=i.getElementsByTagName(r)[0]).parentNode.insertBefore(s,o))}catch(e){return}}(e,"clarity-script")},setTag(e,t){window.clarity("set",e,t)},identify(e,t,i,n){window.clarity("identify",e,t,i,n)},consent(e=!0){window.clarity("consent",e)},consentV2(e={ad_Storage:"granted",analytics_Storage:"granted"}){window.clarity("consentv2",e)},upgrade(e){window.clarity("upgrade",e)},event(e){window.clarity("event",e)}},r=i(12585);let s=!1;function o(){if(s)return;s=!0;let e=(0,r.mA)(),t=(0,r.Je)();if(!t){n.init(e);return}!function(){let e=window;if(e.clarity)return;let t=function(...e){(t.q=t.q||[]).push(e)};e.clarity=t}();let i=!1,o=()=>{i||function(e){if(document.querySelector(`script[src^="${e}/scripts/"]`))return!0;let t=window.clarity;return!!(t&&t.t)}(t)||(i=!0,n.init(e),"undefined"!=typeof console&&console.warn("[clarity] proxy load failed or stalled; fell back to clarity.ms"))},a=document.createElement("script");a.async=!0,a.src=`${t}/www/tag/${e}`,a.onerror=o,function(e){let t=document.getElementsByTagName("script")[0];t?.parentNode?t.parentNode.insertBefore(e,t):document.head.appendChild(e)}(a),window.setTimeout(o,1e4)}function a(e){s&&e&&n.identify(e)}function l(){s&&n.identify(null)}},12585:function(e,t,i){"use strict";var n,r;i.d(t,{$M:function(){return D},$V:function(){return c},AW:function(){return T},Ay:function(){return M},FI:function(){return N},Ff:function(){return A},H3:function(){return b},I:function(){return m},Iz:function(){return u},Je:function(){return v},K0:function(){return E},Kj:function(){return y},LW:function(){return C},Qw:function(){return l},RZ:function(){return o},Rq:function(){return w},Tw:function(){return R},Vc:function(){return L},YR:function(){return _},Z6:function(){return $},ZE:function(){return x},by:function(){return d},f4:function(){return a},g:function(){return O},hJ:function(){return j},lU:function(){return F},mA:function(){return g},mL:function(){return G},nB:function(){return s},q4:function(){return n},r4:function(){return k},rP:function(){return P},sd:function(){return f},uK:function(){return p},ub:function(){return U},wp:function(){return I},y8:function(){return S}});let s="5.3.26",o=600,a=1e3,l=6e3,c=12e3,u={CHARACTER_LIMIT_EXCEEDED:"upload_document_character_limit_exceeded",PROCESSING_TIMEOUT:"upload_document_processing_timeout",RATE_LIMIT_EXCEEDED:"upload_document_rate_limit_exceeded",FILE_NOT_PROVIDED:"upload_document_file_not_provided",INVALID_FILE_TYPE:"upload_document_invalid_file_type",PARSE_FAILED:"upload_document_parse_failed",EMPTY_CONTENT:"upload_document_empty_content",UNAUTHORIZED:"upload_document_unauthorized",NETWORK_E
18RROR:"upload_document_network_error",INTERNAL_ERROR:"upload_document_internal_error"},d="prompt",h=window.location.host.includes("develop.slidesai.io")||window.location.host.includes("127.0.0.1")||window.location.host.includes("localhost"),p=()=>h?"phc_j5N2r6M3rgKjqDR1TJ8B48IZAYf1F4TntKhXx7dN5Di":"phc_JVHrwdgpLAYsWiyulV4nkDnZp0d3wLWtehxvwp6j0Gb",g=()=>h?"x24vdgppuw":"x0hkl69dgy",v=()=>h?null:"https://clarity.slidesai.io",f=()=>h?"131650509604-pvq1lr3l1ctu9irrc6ri20aestb7jvo7.apps.googleusercontent.com":"131650509604-74bh3db4d3bjaat0s7eke8shn9p5ri2t.apps.googleusercontent.com",_=()=>h?"6b87b20e387045036ab8fd0cf1e37920":"285afacb2ff29e117895eea4be44b420";(r=n||(n={})).SLIDESAI_SIMPLE="SlidesAI Simple",r.SUNNY_SCRIBBLES="Sunny Scribbles",r.PUZZLE_JOURNEY="Puzzle Journey",r.PLAYFUL_VOYAGE="Playful Voyage";let m={REVIEW_COMPLETED:"_sai_usr_prf_rvw_cpl",REVIEW_DISMISSED:"_sai_usr_prf_rvw_tmp",ONBOARDING_PLAN_SELECTION:"_sai_in_pl_v"},y=[{label:"English",value:"en"},{label:"Espa\xf1ol",value:"es"},{label:"Fran\xe7ais",value:"fr"},{label:"Deutsch",value:"de"},{label:"Italiano",value:"it"},{label:"Portugu\xeas",value:"pt"},{label:"Nederlands",value:"nl"},{label:"Polski",value:"pl"},{label:"Ð ÑÑÑкий",value:"ru"},{label:"æ¥æ¬èª",value:"ja"},{label:"íêµì´",value:"ko"},{label:"䏿",value:"zh"},{label:"हिनà¥à¤¦à¥",value:"hi"},{label:"Ø§ÙØ¹Ø±Ø¨ÙØ©",value:"ar"},{label:"T\xfcrk\xe7e",value:"tr"},{label:"Tiếng Viá»t",value:"vi"},{label:"à¹à¸à¸¢",value:"th"},{label:"ÄeÅ¡tina",value:"cs"},{label:"Dansk",value:"da"},{label:"Suomi",value:"fi"},{label:"Îλληνικά",value:"el"},{label:"Magyar",value:"hu"},{label:"Bahasa Indonesia",value:"id"},{label:"Norsk",value:"no"},{label:"Rom\xe2nÄ",value:"ro"},{label:"Svenska",value:"sv"},{label:"УкÑаÑнÑÑка",value:"uk"}],b={DEBUG_MODE_KEY:"d-m",SLIDE_TITLE_LOCAL_STORAGE_KEY:"slidesai-slide-title",SLIDE_TEXT_LOCAL_STORAGE_KEY:"slidesai-slide-text",TEXT_LOCAL_STORAGE_KEY:"slidesai-user-text",TOPIC_TEXT_LOCAL_STORAGE_KEY:"slidesai-topic-text",USER_INPUT_HISTORY_KEY:"slidesai-user-input-history",INITIAL_ROUTE:"initial-route",ICONS_KEY:"icons",SELECTED_ACCORDION:"selectedAccordion",AI_IMAGES_STYLE:"ai-images-style",SELECTED_STYLE_NAME:"selected-style-name",SELECTED_STYLE_CATEGORY:"selected-style-category",GENERATED_RUNS_IDS:"magic-write-generated-runs-ids",RUN_TEST_COLUMN_FILTERS:"run-test-column-filters",RECENT_THEMES:"recent-themes",PREFERRED_TRANSLATE_LANGUAGE:"p-t-l",DOCUMENT_ID:"document-id",DOCUMENT_UPLOAD_STORAGE_KEY:"document-upload-info",HAS_OPENED_WEBSITE:"has-opened-website",AUTH_TOKEN:"auth_token",SLIDESAI_PROGRESS:"slidesai_progress",SLIDESAI_RESTORING_FROM_HISTORY:"slidesai_restoring_from_history",USER_AUTH_TOKEN:"user_auth_token",DISMISSED_BANNERS_KEY:"slidesai-dismissed-banners",ONGOING_PRESENTATION_KEY:"ongoing_presentation",ONBOARDING_DATA:"slidesai_onboarding",PRESENTATION_URL:"presentation_url",USER_LOCATION:"u-l-d",DISMISSED_BANNERS:"dismissed_banners",INSTRUCTION_SELECTIONS_HISTORY:"instruction_selections_history",HIDE_PREVIEW_SPEED_BUMP:"h-p-s-b",CHECKOUT_STARTED:"checkout_started",SHEETS_PERMISSION_CHECK:"sheets_permission_check",STYLE_CHANGE_INFO_STORAGE_KEY:"style-change-info",SCROLL_INDICATOR_DISMISSED:"scroll-indicator-dismissed",IMAGE_PREFERENCE_KEY:"slidesai-image-preference",NOTES_COMPARISON_MODAL_SHOWN_KEY:"slidesai_notes_comparison_modal_shown",LAST_VIEWED_CHANGELOG_TIMESTAMP:"slidesai-last-viewed-changelog",AUTO_REGENERATE_MARKDOWN:"auto-regen-md",WEB_EARLY_LOGIN_DESTINATION:"slidesai_web_early_login_destination"},E={SLIDE_PREVIEW_INFO:"slide-preview-info",INSTRUCTION_PRESET_SUGGESTION:"instruction-preset-suggestion"},w=[{label:"Abril Fatface",value:"Abril Fatface"},{label:"Fira Sans",value:"Fira Sans"},{label:"Comfortaa",value:"Comfortaa"},{label:"Gaegu",value:"Gaegu"},{label:"Gochi Hand",value:"Gochi Hand"},{label:"Hanken Grotesk",value:"Hanken Grotesk"},{label:"Inconsolata",value:"Inconsolata"},{label:"Inter",value:"Inter"},{label:"Italiana",value:"Italiana"},{label:"Josefin Sans",value:"Josefin Sans"},{label:"Krona One",value:"Krona One"},{label:"Lato",value:"Lato"},{label:"League Spartan",value:"League Spartan"},{label:"Lexend",value:"Lexend"},{label:"Lora",value:"Lora"},{label:"Merriweather",value:"Merriweather"},{label:"Molle",value:"Molle"},{label:"Montserrat",value:"Montserrat"},{label:"Noto Sans",value:"Noto Sans"},{label:"Noto Serif",value:"Noto Serif"},{label:"Nunito",value:"Nunito"},{label:"Open Sans",value:"Open Sans"},{label:"Oswald",value:"Oswald"},{label:"Pacifico",value:"Pacifico"},{label:"Playfair Display",value:"Playfair Display"},{label:"Poppins",value:"Poppins"},{label:"Proza Libre",value:"Proza Libre"},{label:"PT Sans",value:"PT Sans"},{label:"Raleway",value:"Raleway"},{label:"Roboto",value:"Roboto"},{label:"Source Sans Pro",value:"Source Sans Pro"},{label:"Space Grotesk",value:"Space Grotesk"},{label:"Spectral",value:"Spectral"},{label:"Syne",value:"Syne"},{label:"Varela Round",value:"Varela Round"},{label:"Verdana",value:"Verdana"}],S={TOPIC_TO_PPT:"topic-to-ppt",EARLY_ACCESS:"early-access",AUTO_SLIDE:"auto-slide",AI_IMAGES:"ae",PROFITWELL:"pf",CONTROL_SUMMARIZATION:"control-summarization",SMART_LAYOUTS:"smart-layouts-access",CAPTURE_SCREENSHOTS:"cs",SHOW_TEST_THEMES:"stt",SHOW_REVIEW_WIDGET_SLIDE:"srfw-s",SHOW_REVIEW_WIDGET_POWERPOINT:"srfw-p",GRANT_FREE_PPTS:"gfslds",GRANT_FREE_PPTS_POWERPOINT:"gfppt",
18SHOW_PPT_FEEDBACK:"shw-p-f",SHOW_CUSTOM_THEMES:"show_custom_themes",USE_CITATIONS:"use-citations",USE_AI_IMAGES:"use-ai-images",ALLOW_EDIT_WITH_SLIDESAI:"allow-edit-with-slidesai",ASK_EDUCATOR_CLASSROOM:"ask-educator-google-classroom-usage",PLAYFUL_STYLES:"playful-styles",SHOW_OUTLINE:"s-o-o-tt-t-ppt",OUTLINE_ACCESS:"outline-access",SHOW_DEBUGGER:"s-d",SHOW_LIMIT_REACHED_WEB_DROPDOWN:"slrwd",OUTLINE_SLIDE_LIMIT:"osl",BLACK_FRIDAY_2025:"bf25",FREE_PLAN_LIMITS:"fpl",NEW_YEAR_2025:"ny25",NEW_YEAR_2026:"ny26",SUMMER_2025:"summer25",BACK_TO_SCHOOL_2025:"b2s-25",WORKER_EDIT_SLIDES:"wrkr-e",TRY_EXAMPLES:"try-examples",SESSION_RECORDING:"session-replay",DISABLE_ANALYTICS:"disable-analytics",FREE_PRESENTATION_LIMIT:"fpr-l",WEBSITE_TO_PPT:"w-t-p",ONBOARDING_PLAN_SELECTION:"onps",SCRIPT_DOCUMENT_UPLOAD:"scriptDoc",SHOW_CHANGE_THEME:"sct",SLIDE_PREVIEW:"sl-prev",SMARTV3:"smartv3",CLARIFYING_QUESTIONS:"clarifyingQuestions",TRY_NEW_EDITOR:"tne",SHOW_WEB_ONBOARDING:"swo",PHEXP:"phexp",GSPHEXP:"gsphexp",HTML_SKILLS:"htsk"},T={[S.TOPIC_TO_PPT]:"topicToPPTEnabled",[S.EARLY_ACCESS]:"allowEarlyAccess",[S.AUTO_SLIDE]:"autoSlide",[S.AI_IMAGES]:"aiImagesGeneration",[S.PROFITWELL]:"pf",[S.CONTROL_SUMMARIZATION]:"controlSummarization",[S.SMART_LAYOUTS]:"smartLayouts",[S.CAPTURE_SCREENSHOTS]:"captureScreenshots",[S.SHOW_TEST_THEMES]:"showTestThemes",[S.SHOW_REVIEW_WIDGET_SLIDE]:"showReviewWidget",[S.SHOW_REVIEW_WIDGET_POWERPOINT]:"showReviewWidget",[S.GRANT_FREE_PPTS]:"grantFreePPTs",[S.GRANT_FREE_PPTS_POWERPOINT]:"grantFreePPTsPowerpoint",[S.SHOW_PPT_FEEDBACK]:"showPPTFeedback",[S.SHOW_CUSTOM_THEMES]:"showCustomTheme",[S.USE_CITATIONS]:"useCitations",[S.USE_AI_IMAGES]:"useAIImages",[S.ALLOW_EDIT_WITH_SLIDESAI]:"allowEditWithSlidesAI",[S.ASK_EDUCATOR_CLASSROOM]:"askEducatorGoogleClassroomUsage",[S.PLAYFUL_STYLES]:"playfulStyles",[S.SHOW_OUTLINE]:"showOutline",[S.OUTLINE_ACCESS]:"outlineAccess",[S.SHOW_DEBUGGER]:"showDebugger",[S.SHOW_LIMIT_REACHED_WEB_DROPDOWN]:"showLimitReachedWebDropdown",[S.OUTLINE_SLIDE_LIMIT]:"outlineSlideLimit",[S.BLACK_FRIDAY_2025]:"bf25",[S.FREE_PLAN_LIMITS]:"freePlanLimits",[S.NEW_YEAR_2025]:"ny25",[S.NEW_YEAR_2026]:"ny26",[S.DISABLE_ANALYTICS]:"disable-analytics",[S.SESSION_RECORDING]:"session-replay",[S.FREE_PRESENTATION_LIMIT]:"freePresentationLimit",[S.WEBSITE_TO_PPT]:"websiteToPPT",[S.ONBOARDING_PLAN_SELECTION]:"onboardingPlanSelection",[S.SUMMER_2025]:"summer25",[S.BACK_TO_SCHOOL_2025]:"b2s-25",[S.SCRIPT_DOCUMENT_UPLOAD]:"scriptDocumentUpload",[S.WORKER_EDIT_SLIDES]:"workerEditWithSlidesAI",[S.TRY_EXAMPLES]:"tryExamples",[S.HTML_SKILLS]:"htmlSkills",[S.SHOW_CHANGE_THEME]:"showChangeTheme",[S.SLIDE_PREVIEW]:"slidePreviewFlow",[S.SMARTV3]:"smartv3",[S.CLARIFYING_QUESTIONS]:"clarifyingQuestions",[S.TRY_NEW_EDITOR]:"tryNewEditor",[S.SHOW_WEB_ONBOARDING]:"showWebOnboarding",[S.PHEXP]:"phexp",[S.GSPHEXP]:"gsphexp"};S.NEW_YEAR_2026;let I=[S.BLACK_FRIDAY_2025,S.NEW_YEAR_2025,S.NEW_YEAR_2026,S.SUMMER_2025,S.BACK_TO_SCHOOL_2025,S.WORKER_EDIT_SLIDES],k=10485760,x=7340032,O=10,P=700,R=1200,A={DEFAULT_TEAM_MEMBER_COUNT:10,BASE_PRICING_URL:"https://www.slidesai.io/pricing",CHECKOUT_PATH:"/teams/checkout-success"},C={POWERPOINT_TASK_PANE_TIMEOUT:2e4,WEBSOCKET_CONNECTION_TIMEOUT:5e3,WEBSOCKET_RECONNECT_DELAY:3e3,WEBSOCKET_RECONNECT_AFTER_DISCONNECT_DELAY:2e3,POWERPOINT_CREATION_TIMEOUT:12e3,DEFAULT_CREATION_TIMEOUT:3e3,EXTENDED_CREATION_TIMEOUT:8e3,PROGRESS_EXPIRATION_TIME:3e5,TOAST_NOTIFICATION_DURATION:3e3,MAX_POLLING_ATTEMPTS:200,POLLING_INTERVAL_MS:5e3,LARGE_PRESENTATION_SLIDE_THRESHOLD:30,MIN_TITLE_LENGTH:3,MIN_CONTENT_LENGTH:3,STATUS_CHECK_MAX_ATTEMPTS:4,STATUS_CHECK_INTERVAL_MS:9e4,STATUS_CHECK_INITIAL_DELAY_MS:12e4},L=5e3,j=1e4,N=5e3,F={topic:"/generate/topic-to-ppt",notes:"/generate/notes-to-ppt",script:"/generate/script-to-ppt",source:"/generate/document-to-ppt"},M=[{code:"en_US",shortCode:"en",name:"English"},{code:"es_ES",shortCode:"es",name:"Espa\xf1ol"},{code:"it_IT",shortCode:"it",name:"Italiano"},{code:"fr_FR",shortCode:"fr",name:"Fran\xe7ais"},{code:"ja_JP",shortCode:"ja",name:"æ¥æ¬èª"},{code:"ru_RU",shortCode:"ru",name:"Ð ÑÑÑкий"},{code:"pt_PT",shortCode:"pt",name:"Portugu\xeas"},{code:"de_DE",shortCode:"de",name:"Deutsch"},{code:"zh_CN",shortCode:"zh",name:"䏿"},{code:"id_ID",shortCode:"id",name:"Bahasa Indonesia"},{code:"ko_KR",shortCode:"ko",name:"íêµì´"},{code:"cs_CZ",shortCode:"cs",name:"ÄeÅ¡tina"},{code:"vi_VN",shortCode:"vi",name:"Tiếng Viá»t"},{code:"tr_TR",shortCode:"tr",name:"T\xfcrk\xe7e"},{code:"sv_SE",shortCode:"sv",name:"Svenska"},{code:"pl_PL",shortCode:"pl",name:"Polski"},{code:"el_GR",shortCode:"el",name:"Îλληνικά"},{code:"nl_NL",shortCode:"nl",name:"Nederlands"},{code:"et_EE",shortCode:"et",name:"eesti"},{code:"ro_RO",shortCode:"ro",name:"Rom\xe2nÄ"},{code:"sl_SI",shortCode:"sl",name:"slovenÅ¡Äina"}],$={ONBOARDING:"/onboarding",ONBOARDING_PLAN_SELECTION:"/onboarding-plan-selection",STEPPER:"/stepper",STEPPER_TOPIC:"/stepper/topic",STEPPER_CONTENT:"/stepper/content",STEPPER_INSTRUCTIONS:"/stepper/instructions",STEPPER_CONTEXT:"/stepper/context",STEPPER_OUTLINE:"/stepper/outline",STEPPER_SLIDES_PREVIEW:"/stepper/slides-preview",STEPPER_DESIGN:"/stepper/design",SUCCESS:"/success",PROFILE:"/profile",ORGANIZATION_PROFILE:"/profile/organization",TEAM_PROFILE:"/profile/team/:teamId",MANAGE_SUBSCRIPTION:"/profile/team/:teamId/subscription",HISTORY:"/history",HELP:"/help",EARLY_ACCESS:"/early-access",ERROR:"/error",RUN_TEST:"/run-test",TOPIC:"/topic",TEXT:"/text",OUTLINE:"/outline",PPT_EDITOR:"/ppt-editor",APPEARANCE:"/appearance",UPGRADE:"/upgrade",YOUTUBE:"/youtube",WEBSITE:"/website",SUGGESTION:"/suggestion",DOCUMENT_TO_PPT:"/document-to-ppt"},D="\n---\n",G={SPEAKER_NOTES_REGEX:/\[SPEAKER NOTES::\s*(.+?)\]/s,SPEAKER_NOTES_REGEX_GLOBAL:/\[SPEAKER NOTES::\s*.+?\]\s*/gs,SPEAKER_NOTES_REGEX_LINE:/^\[SPEAKER NOTES::\s*(.+?)\]\s*$/,SLIDE_SOURCE_REGEX_GLOBAL:/<!--\s*source:\s*(.+?)\s+â\s+(https?:\/\/[^\s>]+?)\s*-->
18/gi,LAYOUT_TAG_REGEX:/\[LAYOUT::\s*.*?\]\s*/g,ESCAPED_QUOTE_REGEX:/\\"/g,HTML_COMMENT_REGEX:/<!--[\s\S]*?-->/g,MULTIPLE_NEWLINES_REGEX:/\n{3,}/g,MARKDOWN_HEADING_REGEX:/^(#{1,6}[^\n]*\n?)/m},U=new Set(["gmail.com","googlemail.com","outlook.com","hotmail.com","yahoo.com","icloud.com","protonmail.com","proton.me","aol.com","live.com","me.com","msn.com","gmx.com","mail.com","yandex.com","zoho.com","fastmail.com","qq.com","163.com","126.com","naver.com"])},7611:function(){},20964:function(){},96154:function(){},79535:function(e){e.exports={style:{fontFamily:"'__Inter_f367f3', '__Inter_Fallback_f367f3'",fontStyle:"normal"},className:"__className_f367f3",variable:"__variable_f367f3"}},35218:function(e){e.exports={style:{fontFamily:"'__Lexend_9f8be8', '__Lexend_Fallback_9f8be8'",fontStyle:"normal"},className:"__className_9f8be8",variable:"__variable_9f8be8"}},45407:function(e,t,i){"use strict";i.d(t,{X:function(){return a}});var n=i(43577),r=i(57242),s=i(85513),o=i(44295);function a({children:e,features:t,strict:i=!1}){let[,a]=(0,r.useState)(!l(t)),c=(0,r.useRef)(void 0);if(!l(t)){let{renderer:e,...i}=t;c.current=e,(0,o.K)(i)}return(0,r.useEffect)(()=>
18{l(t)&&t().then(({renderer:e,...t})=>{(0,o.K)(t),c.current=e,a(!0)})},[]),(0,n.jsx)(s.u.Provider,{value:{renderer:c.current,strict:i},children:e})}function l(e){return"function"==typeof e}},85513:function(e,t,i){"use strict";i.d(t,{u:function(){return n}});let n=(0,i(57242).createContext)({strict:!1})},58968:function(e,t,i){"use strict";i.d(t,{featureDefinitions:function(){return r}});let n={animation:["animate","variants","whileHover","whileTap","exit","whileInView","whileFocus","whileDrag"],exit:["exit"],drag:["drag","dragControls"],focus:["whileFocus"],hover:["whileHover","onHoverStart","onHoverEnd"],tap:["whileTap","onTap","onTapStart","onTapCancel"],pan:["onPan","onPanStart","onPanSessionStart","onPanEnd"],inView:["whileInView","onViewportEnter","onViewportLeave"],layout:["layout","layoutId"]},r={};for(let e in n)r[e]={isEnabled:t=>n[e].some(e=>!!t[e])}},44295:function(e,t,i){"use strict";i.d(t,{K:function(){return r}});var n=i(58968);function r(e){for(let t in e)n.featureDefinitions[t]={...n.featureDefinitions[t],...e[t]}}}},function(e){var t=function(t){return e(e.s=t)};e.O(0,[9774,179],function(){return t(23837),t(92081)}),_N_E=e.O()}]);
Line numbers count LF bytes from the start of the resource, as the search results do. Vendor segments are library code the classifier recognised; they are stored but not indexed. Bytes are shown as Latin1 characters, one per byte.