@tryghost/portal 2.10.0 → 2.11.2

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/umd/portal.min.js CHANGED
@@ -1,3 +1,3 @@
1
1
  /*! For license information please see portal.min.js.LICENSE.txt */
2
- !function(e){var t={};function n(r){if(t[r])return t[r].exports;var i=t[r]={i:r,l:!1,exports:{}};return e[r].call(i.exports,i,i.exports,n),i.l=!0,i.exports}n.m=e,n.c=t,n.d=function(e,t,r){n.o(e,t)||Object.defineProperty(e,t,{enumerable:!0,get:r})},n.r=function(e){"undefined"!==typeof Symbol&&Symbol.toStringTag&&Object.defineProperty(e,Symbol.toStringTag,{value:"Module"}),Object.defineProperty(e,"__esModule",{value:!0})},n.t=function(e,t){if(1&t&&(e=n(e)),8&t)return e;if(4&t&&"object"===typeof e&&e&&e.__esModule)return e;var r=Object.create(null);if(n.r(r),Object.defineProperty(r,"default",{enumerable:!0,value:e}),2&t&&"string"!=typeof e)for(var i in e)n.d(r,i,function(t){return e[t]}.bind(null,i));return r},n.n=function(e){var t=e&&e.__esModule?function(){return e.default}:function(){return e};return n.d(t,"a",t),t},n.o=function(e,t){return Object.prototype.hasOwnProperty.call(e,t)},n.p="/",n(n.s=49)}([function(e,t,n){"use strict";e.exports=n(42)},function(e,t,n){"use strict";e.exports=n(35)},function(e,t,n){"use strict";n.d(t,"b",(function(){return i})),n.d(t,"a",(function(){return o})),n.d(t,"e",(function(){return a})),n.d(t,"c",(function(){return l})),n.d(t,"d",(function(){return s}));var r=function(e,t){return r=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(e,t){e.__proto__=t}||function(e,t){for(var n in t)t.hasOwnProperty(n)&&(e[n]=t[n])},r(e,t)};function i(e,t){function n(){this.constructor=e}r(e,t),e.prototype=null===t?Object.create(t):(n.prototype=t.prototype,new n)}var o=function(){return o=Object.assign||function(e){for(var t,n=1,r=arguments.length;n<r;n++)for(var i in t=arguments[n])Object.prototype.hasOwnProperty.call(t,i)&&(e[i]=t[i]);return e},o.apply(this,arguments)};function a(e){var t="function"===typeof Symbol&&Symbol.iterator,n=t&&e[t],r=0;if(n)return n.call(e);if(e&&"number"===typeof e.length)return{next:function(){return e&&r>=e.length&&(e=void 0),{value:e&&e[r++],done:!e}}};throw new TypeError(t?"Object is not iterable.":"Symbol.iterator is not defined.")}function l(e,t){var n="function"===typeof Symbol&&e[Symbol.iterator];if(!n)return e;var r,i,o=n.call(e),a=[];try{for(;(void 0===t||t-- >0)&&!(r=o.next()).done;)a.push(r.value)}catch(l){i={error:l}}finally{try{r&&!r.done&&(n=o.return)&&n.call(o)}finally{if(i)throw i.error}}return a}function s(){for(var e=[],t=0;t<arguments.length;t++)e=e.concat(l(arguments[t]));return e}},function(e,t,n){"use strict";n.r(t),n.d(t,"removePortalLinkFromUrl",(function(){return a})),n.d(t,"getPortalLinkPath",(function(){return l})),n.d(t,"getPortalLink",(function(){return s})),n.d(t,"isCookiesDisabled",(function(){return c})),n.d(t,"isSentryEventAllowed",(function(){return u})),n.d(t,"getMemberSubscription",(function(){return p})),n.d(t,"isComplimentaryMember",(function(){return d})),n.d(t,"isPaidMember",(function(){return f})),n.d(t,"getProductCurrency",(function(){return h})),n.d(t,"getNewsletterFromUuid",(function(){return m})),n.d(t,"allowCompMemberUpgrade",(function(){return g})),n.d(t,"getCompExpiry",(function(){return b})),n.d(t,"getUpgradeProducts",(function(){return v})),n.d(t,"getFilteredPrices",(function(){return y})),n.d(t,"getPriceFromSubscription",(function(){return x})),n.d(t,"getMemberActivePrice",(function(){return w})),n.d(t,"isMemberActivePrice",(function(){return j})),n.d(t,"getSubscriptionFromId",(function(){return O})),n.d(t,"getMemberTierName",(function(){return k})),n.d(t,"hasOnlyFreePlan",(function(){return _})),n.d(t,"hasPrice",(function(){return S})),n.d(t,"getQueryPrice",(function(){return P})),n.d(t,"capitalize",(function(){return E})),n.d(t,"isInviteOnlySite",(function(){return C})),n.d(t,"hasMultipleProducts",(function(){return N})),n.d(t,"hasMultipleProductsFeature",(function(){return T})),n.d(t,"hasCommentsEnabled",(function(){return I})),n.d(t,"transformApiSiteData",(function(){return L})),n.d(t,"getAvailableProducts",(function(){return M})),n.d(t,"getFreeProduct",(function(){return F})),n.d(t,"getAllProductsForSite",(function(){return D})),n.d(t,"hasBenefits",(function(){return z})),n.d(t,"getSiteProducts",(function(){return R})),n.d(t,"hasFreeTrialTier",(function(){return U})),n.d(t,"getFreeProductBenefits",(function(){return A})),n.d(t,"getFreeTierTitle",(function(){return B})),n.d(t,"getFreeTierDescription",(function(){return H})),n.d(t,"freeHasBenefitsOrDescription",(function(){return q})),n.d(t,"getProductBenefits",(function(){return $})),n.d(t,"getProductFromId",(function(){return W})),n.d(t,"getPricesFromProducts",(function(){return Q})),n.d(t,"hasFreeProductPrice",(function(){return V})),n.d(t,"getSiteNewsletters",(function(){return Y})),n.d(t,"hasMultipleNewsletters",(function(){return K})),n.d(t,"hasOnlyFreeProduct",(function(){return G})),n.d(t,"getSubFreeTrialDaysLeft",(function(){return J})),n.d(t,"subscriptionHasFreeTrial",(function(){return X})),n.d(t,"getProductFromPrice",(function(){return ee})),n.d(t,"getProductCadenceFromPrice",(function(){return te})),n.d(t,"getAvailablePrices",(function(){return ne})),n.d(t,"getFreePriceCurrency",(function(){return re})),n.d(t,"getSitePrices",(function(){return ie})),n.d(t,"getMemberEmail",(function(){return oe})),n.d(t,"getFirstpromoterId",(function(){return ae})),n.d(t,"getMemberName",(function(){return le})),n.d(t,"getSupportAddress",(function(){return se})),n.d(t,"getSiteDomain",(function(){return ce})),n.d(t,"getCurrencySymbol",(function(){return ue})),n.d(t,"getStripeAmount",(function(){return pe})),n.d(t,"getPriceString",(function(){return de})),n.d(t,"formatNumber",(function(){return fe})),n.d(t,"createPopupNotification",(function(){return he})),n.d(t,"isSameCurrency",(function(){return me})),n.d(t,"getPriceIdFromPageQuery",(function(){return ge})),n.d(t,"getOfferOffAmount",(function(){return be})),n.d(t,"getUpdatedOfferPrice",(function(){return ve})),n.d(t,"isActiveOffer",(function(){return ye})),n.d(t,"transformApiTiersData",(function(){return xe})),n.d(t,"getUrlHistory",(function(){return we}));var r=n(4),i=n(6),o=n(11);function a(){var e=window.location.hash.substr(1).split("?"),t=Object(i.a)(e,1)[0];t&&/^\/portal\/?(?:\/(\w+(?:\/\w+)*))?\/?$/.test(t)&&window.history.pushState("",document.title,window.location.pathname+window.location.search)}function l(e){var t=e.page,n={signin:"#/portal/signin",signup:"#/portal/signup"};return Object.keys(n).includes(t)?n[t]:n.default}function s(e){var t=e.page,n=e.siteUrl||"".concat(window.location.protocol,"//").concat(window.location.host).concat(window.location.pathname),r=l({page:t});return"".concat(n).concat(r)}function c(){return!(navigator&&navigator.cookieEnabled)}function u(e){var t,n,r,i,o=e.event,a=((null===o||void 0===o||null===(t=o.exception)||void 0===t||null===(n=t.values)||void 0===n||null===(r=n[0])||void 0===r||null===(i=r.stacktrace)||void 0===i?void 0:i.frames)||[]).map((function(e){return e.filename})).filter((function(e){return!!e}));return(a[a.length-1]||"").includes("@tryghost/portal")}function p(e){var t=e.member,n=void 0===t?{}:t;if(f({member:n})){var r=(n.subscriptions||[]).find((function(e){return["active","trialing","unpaid","past_due"].includes(e.status)}));return null!==r&&void 0!==r&&r.price||null===r||void 0===r||!r.plan||(r.price=r.plan),r}return null}function d(e){var t=e.member,n=void 0===t?{}:t;if(!n)return!1;var r=p({member:n});if(r){var i=r.price;return i&&0===i.amount}return!(r||!n.paid)}function f(e){var t=e.member,n=void 0===t?{}:t;return n&&n.paid}function h(e){var t=e.product;return null!==t&&void 0!==t&&t.monthlyPrice?t.monthlyPrice.currency:null}function m(e){var t=e.site,n=e.uuid;if(!n)return null;var r=Y({site:t});return null===r||void 0===r?void 0:r.find((function(e){return e.uuid=n}))}function g(e){var t,n,r,i=e.member;return void 0!==(null===i||void 0===i||null===(t=i.subscriptions)||void 0===t||null===(n=t[0])||void 0===n||null===(r=n.tier)||void 0===r?void 0:r.expiry_at)}function b(e){var t,n,r,i=e.member;return null!==i&&void 0!==i&&null!==(t=i.subscriptions)&&void 0!==t&&null!==(n=t[0])&&void 0!==n&&null!==(r=n.tier)&&void 0!==r&&r.expiry_at?Object(o.a)(i.subscriptions[0].tier.expiry_at):""}function v(e){var t=e.site,n=w({member:e.member}),r=null===n||void 0===n?void 0:n.currency,i=M({site:t});return null!==n&&void 0!==n&&n.id?i.filter((function(e){return h({product:e})===r})):i}function y(e){var t=e.prices,n=e.currency;return t.filter((function(e){return(e.currency||"").toLowerCase()===(n||"").toLowerCase()}))}function x(e){var t,n,i=e.subscription;return i&&i.price?Object(r.a)(Object(r.a)({},i.price),{},{stripe_price_id:i.price.id,id:i.price.price_id,price:i.price.amount/100,name:i.price.nickname,tierId:null===(t=i.tier)||void 0===t?void 0:t.id,cadence:"month"===(null===(n=i.price)||void 0===n?void 0:n.interval)?"month":"year",currency:i.price.currency.toLowerCase(),currency_symbol:ue(i.price.currency)}):null}function w(e){return x({subscription:p({member:e.member})})}function j(e){var t=e.priceId,n=e.site,r=w({member:e.member}),i=te({site:n,priceId:t}),o=i.tierId,a=i.cadence;return(null===r||void 0===r?void 0:r.tierId)===o&&(null===r||void 0===r?void 0:r.cadence)===a}function O(e){var t=e.member,n=e.subscriptionId;return f({member:t})?(t.subscriptions||[]).find((function(e){return e.id===n})):null}function k(e){var t,n=p({member:e.member});return(null===n||void 0===n||null===(t=n.tier)||void 0===t?void 0:t.name)||""}function _(e){var t=e.plans,n=e.site;return!(t=t||ie({site:void 0===n?{}:n}))||0===t.length||1===t.length&&"free"===t[0].type}function S(e){var t=e.site,n=void 0===t?{}:t,r=e.plan,i=ie({site:n});return"free"===r?!i||0===i.length||i.find((function(e){return"free"===e.type})):"monthly"===r?i&&i.length>0&&i.find((function(e){return"Monthly"===e.name})):"yearly"===r?i&&i.length>0&&i.find((function(e){return"Yearly"===e.name})):!!r&&(i&&i.length>0&&i.find((function(e){return e.id===r})))}function P(e){var t=e.site,n=void 0===t?{}:t,r=e.priceId,i=ne({site:n});if("free"===r)return!i||0===i.length||i.find((function(e){return"free"===e.type}));if(i&&i.length>0&&"monthly"===r){var o=i.find((function(e){return"Monthly"===e.name})),a=i.find((function(e){return"month"===e.interval}));return o||a}if(i&&i.length>0&&"yearly"===r){var l=i.find((function(e){return"Yearly"===e.name})),s=i.find((function(e){return"year"===e.interval}));return l||s}return i&&i.length>0&&r?i.find((function(e){return e.id===r})):null}function E(e){return"string"===typeof e&&e?e.charAt(0).toUpperCase()+e.slice(1):""}function C(e){var t=e.site,n=void 0===t?{}:t,r=e.pageQuery;return 0===ie({site:n,pageQuery:void 0===r?"":r}).length||n&&"invite"===n.members_signup_access}function N(e){var t=M({site:e.site});return(null===t||void 0===t?void 0:t.length)>1}function T(e){return!!(e.site||{}).portal_products}function I(e){var t=e.site;return(null===t||void 0===t?void 0:t.comments_enabled)&&"off"!==(null===t||void 0===t?void 0:t.comments_enabled)}function L(e){var t,n,i,o=e.site;if(!o)return null;if(o.tiers&&(o.products=o.tiers),o.products=null===(t=o.products)||void 0===t?void 0:t.map((function(e){return Object(r.a)(Object(r.a)({},e),{},{monthlyPrice:e.monthly_price,yearlyPrice:e.yearly_price})})),o.is_stripe_configured=!!o.paid_members_enabled,o.members_signup_access="all",o.members_enabled||(o.members_signup_access="none"),o.members_invite_only&&(o.members_signup_access="invite"),o.allow_self_signup=!1,"all"!==o.members_signup_access&&(o.allow_self_signup=!1),o.paid_members_enabled&&(o.allow_self_signup=!0),o.portal_plans.includes("free")&&(o.allow_self_signup=!0),null!==(n=o.products)&&void 0!==n&&null!==(i=n[0])&&void 0!==i&&i.visibility){o.portal_products=o.products.filter((function(e){return"none"!==e.visibility&&"paid"===e.type})).map((function(e){return e.id}));var a,l,s=o.products.find((function(e){return"free"===e.type}));if(s)if(o.portal_plans=null===(a=o.portal_plans)||void 0===a?void 0:a.filter((function(e){return"free"!==e})),"public"===(null===s||void 0===s?void 0:s.visibility))null===(l=o.portal_plans)||void 0===l||l.push("free")}return o}function M(e){var t=e.site||{},n=t.portal_products,i=t.products,o=void 0===i?[]:i,a=t.portal_plans,l=void 0===a?[]:a;return l.includes("monthly")||l.includes("yearly")?o.filter((function(e){return!!e})).filter((function(e){return!(!e.monthlyPrice||!e.yearlyPrice)})).filter((function(e){return!!(Object.keys(e.monthlyPrice).length>0&&Object.keys(e.yearlyPrice).length>0)})).filter((function(e){return!(n&&o.length>1)||n.includes(e.id)})).sort((function(e,t){var n,r;return(null===e||void 0===e||null===(n=e.monthlyPrice)||void 0===n?void 0:n.amount)-(null===t||void 0===t||null===(r=t.monthlyPrice)||void 0===r?void 0:r.amount)})).map((function(e){return e.monthlyPrice=Object(r.a)(Object(r.a)({},e.monthlyPrice),{},{currency_symbol:ue(e.monthlyPrice.currency)}),e.yearlyPrice=Object(r.a)(Object(r.a)({},e.yearlyPrice),{},{currency_symbol:ue(e.yearlyPrice.currency)}),e})):[]}function F(e){var t=(e.site||{}).products;return(void 0===t?[]:t).find((function(e){return"free"===e.type}))}function D(e){var t=e.site||{},n=t.products,i=void 0===n?[]:n,o=t.portal_plans,a=void 0===o?[]:o;return a.includes("monthly")||a.includes("yearly")?i.filter((function(e){return!!e})).filter((function(e){return!(!e.monthlyPrice||!e.yearlyPrice)})).filter((function(e){return!!(Object.keys(e.monthlyPrice).length>0&&Object.keys(e.yearlyPrice).length>0)})).sort((function(e,t){var n,r;return(null===e||void 0===e||null===(n=e.monthlyPrice)||void 0===n?void 0:n.amount)-(null===t||void 0===t||null===(r=t.monthlyPrice)||void 0===r?void 0:r.amount)})).map((function(e){return e.monthlyPrice=Object(r.a)(Object(r.a)({},e.monthlyPrice),{},{currency_symbol:ue(e.monthlyPrice.currency)}),e.yearlyPrice=Object(r.a)(Object(r.a)({},e.yearlyPrice),{},{currency_symbol:ue(e.yearlyPrice.currency)}),e})):[]}function z(e){var t=e.prices;return!!T({site:e.site})&&(!(null===t||void 0===t||!t.length)&&t.some((function(e){var t;return null===e||void 0===e||null===(t=e.benefits)||void 0===t?void 0:t.length})))}function R(e){var t=e.site,n=e.pageQuery,r=M({site:t});return"free"===n&&V({site:t})?[]:(V({site:t})&&r.unshift({id:"free"}),r)}function U(e){return R({site:e.site}).some((function(e){return!(null===e||void 0===e||!e.trial_days)}))}function A(e){var t=F({site:e.site});return(null===t||void 0===t?void 0:t.benefits)||[]}function B(e){return G({site:e.site})?"Free membership":"Free"}function H(e){var t=F({site:e.site});return null===t||void 0===t?void 0:t.description}function q(e){var t,n=F({site:e.site});return!!(null!==n&&void 0!==n&&n.description||null!==n&&void 0!==n&&null!==(t=n.benefits)&&void 0!==t&&t.length)}function $(e){var t=e.product;e.site;if(null!==t&&void 0!==t&&t.monthlyPrice&&null!==t&&void 0!==t&&t.yearlyPrice){var n=(null===t||void 0===t?void 0:t.benefits)||[];return{monthly:n,yearly:n}}}function W(e){var t=e.site,n=e.productId;return D({site:t}).find((function(e){return e.id===n}))}function Q(e){var t=e.site,n=void 0===t?null:t,r=e.products,i=void 0===r?null:r;return n||i?(i||M({site:n})).reduce((function(e,t){return t.monthlyPrice&&t.yearlyPrice&&(e.push(t.monthlyPrice),e.push(t.yearlyPrice)),e}),[]):[]}function V(e){var t=e.site||{},n=t.allow_self_signup,r=t.portal_plans;return n&&r.includes("free")}function Y(e){var t=(e.site||{}).newsletters,n=void 0===t?[]:t;return null===n||void 0===n||n.sort((function(e,t){return e.sort_order-t.sort_order})),n}function K(e){var t=(e.site||{}).newsletters;return(null===t||void 0===t?void 0:t.length)>1}function G(e){var t=e.site;return 1===R({site:t}).length&&V({site:t})}function J(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{},t=e.sub;if(!X({sub:t}))return 0;var n=(new Date).setHours(0,0,0,0),r=new Date(t.trial_end_at).setHours(0,0,0,0),i=864e5;return Math.ceil((r-n)/i)}function X(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{},t=e.sub;return!(null===t||void 0===t||!t.trial_end_at||Z(new Date(null===t||void 0===t?void 0:t.trial_end_at)))}function Z(e){var t=new Date;return t.setHours(0,0,0,0),e<t}function ee(e){var t=e.site,n=e.priceId;return"free"===n?F({site:t}):D({site:t}).find((function(e){var t,r;return(null===e||void 0===e||null===(t=e.monthlyPrice)||void 0===t?void 0:t.id)===n||(null===e||void 0===e||null===(r=e.yearlyPrice)||void 0===r?void 0:r.id)===n}))}function te(e){var t,n=e.site,r=e.priceId;if("free"===r)return F({site:n});var i=D({site:n}).find((function(e){var t,n;return(null===e||void 0===e||null===(t=e.monthlyPrice)||void 0===t?void 0:t.id)===r||(null===e||void 0===e||null===(n=e.yearlyPrice)||void 0===n?void 0:n.id)===r})),o="month";return(null===i||void 0===i||null===(t=i.yearlyPrice)||void 0===t?void 0:t.id)===r&&(o="year"),{tierId:null===i||void 0===i?void 0:i.id,cadence:o}}function ne(e){var t=e.site,n=e.products,i=void 0===n?null:n,o=t||{},a=o.portal_plans,l=void 0===a?[]:a;return o.is_stripe_configured?Q({site:t,products:i}).filter((function(e){return!(!e||!e.id)})).map((function(e){return Object(r.a)(Object(r.a)({},e),{},{price_id:e.id,price:e.amount/100,name:e.nickname,currency_symbol:ue(e.currency)})})).filter((function(e){return 0!==e.amount&&"recurring"===e.type})).filter((function(e){return"month"===e.interval?l.includes("monthly"):"year"===e.interval&&l.includes("yearly")})).sort((function(e,t){return e.amount-t.amount})).sort((function(e,t){return e.currency&&t.currency?e.currency.localeCompare(t.currency,void 0,{ignorePunctuation:!0}):0})):[]}function re(e){var t=ne({site:e.site}),n={currency:"usd",currency_symbol:"$"};return(null===t||void 0===t?void 0:t.length)>0&&(n.currency=t[0].currency,n.currency_symbol=t[0].currency_symbol),n}function ie(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{},t=e.site,n=void 0===t?{}:t,i=e.pageQuery,o=void 0===i?"":i,a=n||{},l=a.allow_self_signup,s=a.portal_plans,c=[];if(l&&s.includes("free")){var u=re({site:n});c.push(Object(r.a)({id:"free",type:"free",price:0,amount:0,name:B({site:n})},u))}var p="free"===o&&V({site:n});if(!p){var d=ne({site:n});d.forEach((function(e){c.push(e)}))}return c}var oe=function(e){var t=e.member;return t?t.email:""},ae=function(e){var t=e.site;return t&&t.firstpromoter_account},le=function(e){var t=e.member;return t?t.name:""},se=function(e){var t,n=e.site,r=(n||{}).members_support_address;if((null===r||void 0===r?void 0:r.indexOf("@"))<0){var o=ce({site:n}),a=(null===o||void 0===o?void 0:o.replace(/^(www)\.(?=[^/]*\..{2,5})/,""))||"";return"".concat(r,"@").concat(a)}if((null===r||void 0===r||null===(t=r.split("@"))||void 0===t?void 0:t.length)>1){var l=null===r||void 0===r?void 0:r.split("@"),s=Object(i.a)(l,2),c=s[0],u=s[1],p=(null===u||void 0===u?void 0:u.replace(/^(www)\.(?=[^/]*\..{2,5})/,""))||"";return"".concat(c,"@").concat(p)}return r||""},ce=function(e){var t=e.site;try{return new URL(t.url).origin.replace(/^http(s?):\/\//,"").replace(/\/$/,"")}catch(n){return t.url.replace(/^http(s?):\/\//,"").replace(/\/$/,"")}},ue=function(e){return Intl.NumberFormat("en",{currency:e,style:"currency"}).format(0).replace(/[\d\s.]/g,"")},pe=function(e){return isNaN(e)?0:e/100},de=function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{},t=ue(e.currency),n=pe(e.amount);return"".concat(t).concat(n,"/").concat(e.interval)},fe=function(e){return void 0===e||null===e?"":e.toLocaleString()},he=function(e){var t=e.type,n=e.status,r=e.autoHide,i=e.duration,o=void 0===i?2600:i,a=e.closeable,l=e.state,s=e.message,c=e.meta,u=void 0===c?{}:c,p=0;return l&&l.popupNotification&&(p=(l.popupNotification.count||0)+1),{type:t,status:n,autoHide:r,closeable:a,duration:o,meta:u,message:s,count:p}};function me(e,t){return(null===e||void 0===e?void 0:e.toLowerCase())===(null===t||void 0===t?void 0:t.toLowerCase())}function ge(e){var t=e.site,n=e.pageQuery,r=/^(?:(\S+?))?\/monthly$/,o=/^(?:(\S+?))?\/yearly$/;if(r.test(n||"")){var a,l=n.match(r),s=W({site:t,productId:Object(i.a)(l,2)[1]});return null===s||void 0===s||null===(a=s.monthlyPrice)||void 0===a?void 0:a.id}if(o.test(n||"")){var c,u=n.match(o),p=W({site:t,productId:Object(i.a)(u,2)[1]});return null===p||void 0===p||null===(c=p.yearlyPrice)||void 0===c?void 0:c.id}return null}var be=function(e){var t=e.offer;return"fixed"===t.type?"".concat(ue(t.currency)).concat(t.amount/100):"percent"===t.type?"".concat(t.amount,"%"):""},ve=function(e){var t,n=e.offer,r=e.price,i=e.useFormatted,o=void 0!==i&&i,a=r.amount;return t="fixed"===n.type&&me(n.currency,r.currency)?(t=(a-n.amount)/100)>0?t:0:"percent"===n.type?(a-a*n.amount/100)/100:a/100,o?Intl.NumberFormat("en",{currency:null===r||void 0===r?void 0:r.currency,style:"currency"}).format(t):t},ye=function(e){var t=e.offer;return"active"===(null===t||void 0===t?void 0:t.status)};var xe=function(e){var t=e.tiers,n=0;return t.map((function(e){var t=function(e){var t=e.tier,n=e.priceId;return null!==t&&void 0!==t&&t.monthly_price?{id:"price-".concat(n),active:!0,type:"recurring",nickname:"Monthly",currency:t.currency,amount:t.monthly_price,interval:"month"}:null}({tier:e,priceId:n}),i=function(e){var t=e.tier,n=e.priceId;return null!==t&&void 0!==t&&t.yearly_price?{id:"price-".concat(n),active:!0,type:"recurring",nickname:"Yearly",currency:t.currency,amount:t.yearly_price,interval:"year"}:null}({tier:e,priceId:n+=1});n+=1;var o=function(e){var t,n=e.tier;return null===n||void 0===n||null===(t=n.benefits)||void 0===t?void 0:t.map((function(e){return{name:e}}))}({tier:e});return Object(r.a)(Object(r.a)({},e),{},{benefits:o,monthly_price:t,yearly_price:i})}))};function we(){try{var e=localStorage.getItem("ghost-history");if(e){var t=JSON.parse(e);if(Array.isArray(t))return t}}catch(n){console.warn("[Portal] Failed to load member URL history:",n)}}},function(e,t,n){"use strict";n.d(t,"a",(function(){return o}));var r=n(12);function i(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),n.push.apply(n,r)}return n}function o(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?i(Object(n),!0).forEach((function(t){Object(r.a)(e,t,n[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):i(Object(n)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))}))}return e}},function(e,t,n){e.exports=n(41)},function(e,t,n){"use strict";n.d(t,"a",(function(){return i}));var r=n(14);function i(e,t){return function(e){if(Array.isArray(e))return e}(e)||function(e,t){var n=null==e?null:"undefined"!==typeof Symbol&&e[Symbol.iterator]||e["@@iterator"];if(null!=n){var r,i,o=[],a=!0,l=!1;try{for(n=n.call(e);!(a=(r=n.next()).done)&&(o.push(r.value),!t||o.length!==t);a=!0);}catch(s){l=!0,i=s}finally{try{a||null==n.return||n.return()}finally{if(l)throw i}}return o}}(e,t)||Object(r.a)(e,t)||function(){throw new TypeError("Invalid attempt to destructure non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}()}},,function(e,t,n){"use strict";n.d(t,"d",(function(){return i})),n.d(t,"e",(function(){return a})),n.d(t,"a",(function(){return l})),n.d(t,"b",(function(){return s})),n.d(t,"l",(function(){return c})),n.d(t,"j",(function(){return u})),n.d(t,"i",(function(){return p})),n.d(t,"f",(function(){return d})),n.d(t,"c",(function(){return f})),n.d(t,"k",(function(){return h})),n.d(t,"n",(function(){return m})),n.d(t,"m",(function(){return g})),n.d(t,"h",(function(){return b})),n.d(t,"g",(function(){return v}));var r=Object.prototype.toString;function i(e){switch(r.call(e)){case"[object Error]":case"[object Exception]":case"[object DOMException]":return!0;default:return v(e,Error)}}function o(e,t){return r.call(e)==="[object "+t+"]"}function a(e){return o(e,"ErrorEvent")}function l(e){return o(e,"DOMError")}function s(e){return o(e,"DOMException")}function c(e){return o(e,"String")}function u(e){return null===e||"object"!==typeof e&&"function"!==typeof e}function p(e){return o(e,"Object")}function d(e){return"undefined"!==typeof Event&&v(e,Event)}function f(e){return"undefined"!==typeof Element&&v(e,Element)}function h(e){return o(e,"RegExp")}function m(e){return Boolean(e&&e.then&&"function"===typeof e.then)}function g(e){return p(e)&&"nativeEvent"in e&&"preventDefault"in e&&"stopPropagation"in e}function b(e){return"number"===typeof e&&e!==e}function v(e,t){try{return e instanceof t}catch(n){return!1}}},function(e,t,n){"use strict";(function(e){n.d(t,"a",(function(){return o})),n.d(t,"b",(function(){return a}));var r=n(17),i={};function o(){return Object(r.b)()?e:"undefined"!==typeof window?window:"undefined"!==typeof self?self:i}function a(e,t,n){var r=n||o(),i=r.__SENTRY__=r.__SENTRY__||{};return i[e]||(i[e]=t())}}).call(this,n(26))},function(e,t,n){"use strict";n.d(t,"e",(function(){return l})),n.d(t,"a",(function(){return s})),n.d(t,"g",(function(){return c})),n.d(t,"f",(function(){return u})),n.d(t,"h",(function(){return p})),n.d(t,"b",(function(){return d})),n.d(t,"d",(function(){return m})),n.d(t,"c",(function(){return g}));var r=n(2),i=n(31),o=n(8),a=n(13);function l(e,t,n){if(t in e){var r=e[t],i=n(r);if("function"===typeof i)try{c(i,r)}catch(o){}e[t]=i}}function s(e,t,n){Object.defineProperty(e,t,{value:n,writable:!0,configurable:!0})}function c(e,t){var n=t.prototype||{};e.prototype=t.prototype=n,s(e,"__sentry_original__",t)}function u(e){return e.__sentry_original__}function p(e){return Object.keys(e).map((function(t){return encodeURIComponent(t)+"="+encodeURIComponent(e[t])})).join("&")}function d(e){var t=e;if(Object(o.d)(e))t=Object(r.a)({message:e.message,name:e.name,stack:e.stack},h(e));else if(Object(o.f)(e)){var n=e;t=Object(r.a)({type:n.type,target:f(n.target),currentTarget:f(n.currentTarget)},h(n)),"undefined"!==typeof CustomEvent&&Object(o.g)(e,CustomEvent)&&(t.detail=n.detail)}return t}function f(e){try{return Object(o.c)(e)?Object(i.b)(e):Object.prototype.toString.call(e)}catch(t){return"<unknown>"}}function h(e){var t={};for(var n in e)Object.prototype.hasOwnProperty.call(e,n)&&(t[n]=e[n]);return t}function m(e,t){void 0===t&&(t=40);var n=Object.keys(d(e));if(n.sort(),!n.length)return"[object has no keys]";if(n[0].length>=t)return Object(a.d)(n[0],t);for(var r=n.length;r>0;r--){var i=n.slice(0,r).join(", ");if(!(i.length>t))return r===n.length?i:Object(a.d)(i,t)}return""}function g(e){var t,n;if(Object(o.i)(e)){var i={};try{for(var a=Object(r.e)(Object.keys(e)),l=a.next();!l.done;l=a.next()){var s=l.value;"undefined"!==typeof e[s]&&(i[s]=g(e[s]))}}catch(c){t={error:c}}finally{try{l&&!l.done&&(n=a.return)&&n.call(a)}finally{if(t)throw t.error}}return i}return Array.isArray(e)?e.map(g):e}},function(e,t,n){"use strict";n.d(t,"a",(function(){return r}));var r=function(e){if(!e)return"";return new Date(e).toLocaleDateString("en-GB",{year:"numeric",month:"short",day:"numeric"})}},function(e,t,n){"use strict";function r(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}n.d(t,"a",(function(){return r}))},function(e,t,n){"use strict";n.d(t,"d",(function(){return i})),n.d(t,"c",(function(){return o})),n.d(t,"b",(function(){return a})),n.d(t,"a",(function(){return l}));var r=n(8);function i(e,t){return void 0===t&&(t=0),"string"!==typeof e||0===t||e.length<=t?e:e.substr(0,t)+"..."}function o(e,t){var n=e,r=n.length;if(r<=150)return n;t>r&&(t=r);var i=Math.max(t-60,0);i<5&&(i=0);var o=Math.min(i+140,r);return o>r-5&&(o=r),o===r&&(i=Math.max(o-140,0)),n=n.slice(i,o),i>0&&(n="'{snip} "+n),o<r&&(n+=" {snip}"),n}function a(e,t){if(!Array.isArray(e))return"";for(var n=[],r=0;r<e.length;r++){var i=e[r];try{n.push(String(i))}catch(o){n.push("[value cannot be serialized]")}}return n.join(t)}function l(e,t){return!!Object(r.l)(e)&&(Object(r.k)(t)?t.test(e):"string"===typeof t&&-1!==e.indexOf(t))}},function(e,t,n){"use strict";n.d(t,"a",(function(){return i}));var r=n(16);function i(e,t){if(e){if("string"===typeof e)return Object(r.a)(e,t);var n=Object.prototype.toString.call(e).slice(8,-1);return"Object"===n&&e.constructor&&(n=e.constructor.name),"Map"===n||"Set"===n?Array.from(e):"Arguments"===n||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n)?Object(r.a)(e,t):void 0}}},function(e,t,n){"use strict";!function e(){if("undefined"!==typeof __REACT_DEVTOOLS_GLOBAL_HOOK__&&"function"===typeof __REACT_DEVTOOLS_GLOBAL_HOOK__.checkDCE)try{__REACT_DEVTOOLS_GLOBAL_HOOK__.checkDCE(e)}catch(t){console.error(t)}}(),e.exports=n(36)},function(e,t,n){"use strict";function r(e,t){(null==t||t>e.length)&&(t=e.length);for(var n=0,r=new Array(t);n<t;n++)r[n]=e[n];return r}n.d(t,"a",(function(){return r}))},function(e,t,n){"use strict";(function(e,r){n.d(t,"b",(function(){return o})),n.d(t,"a",(function(){return a}));var i=n(30);function o(){return!Object(i.a)()&&"[object process]"===Object.prototype.toString.call("undefined"!==typeof e?e:0)}function a(e,t){return e.require(t)}}).call(this,n(48),n(25)(e))},,,function(e,t,n){"use strict";e.exports=function(e){var t=[];return t.toString=function(){return this.map((function(t){var n=function(e,t){var n=e[1]||"",r=e[3];if(!r)return n;if(t&&"function"===typeof btoa){var i=function(e){var t=btoa(unescape(encodeURIComponent(JSON.stringify(e)))),n="sourceMappingURL=data:application/json;charset=utf-8;base64,".concat(t);return"/*# ".concat(n," */")}(r),o=r.sources.map((function(e){return"/*# sourceURL=".concat(r.sourceRoot||"").concat(e," */")}));return[n].concat(o).concat([i]).join("\n")}return[n].join("\n")}(t,e);return t[2]?"@media ".concat(t[2]," {").concat(n,"}"):n})).join("")},t.i=function(e,n,r){"string"===typeof e&&(e=[[null,e,""]]);var i={};if(r)for(var o=0;o<this.length;o++){var a=this[o][0];null!=a&&(i[a]=!0)}for(var l=0;l<e.length;l++){var s=[].concat(e[l]);r&&i[s[0]]||(n&&(s[2]?s[2]="".concat(n," and ").concat(s[2]):s[2]=n),t.push(s))}},t}},function(e,t){e.exports=function(e,t){if(isNaN(e)||isNaN(t))return 0;var n=e?100-Math.floor(t/12*100/e):0;return n>=1&&n<100?n:0}},function(e,t,n){"use strict";n.d(t,"a",(function(){return i})),n.d(t,"b",(function(){return l}));var r=n(2);function i(){for(var e=[],t=0;t<arguments.length;t++)e[t]=arguments[t];var n=e.sort((function(e,t){return e[0]-t[0]})).map((function(e){return e[1]}));return function(e,t){var i,a,l,s;void 0===t&&(t=0);var c=[];try{for(var u=Object(r.e)(e.split("\n").slice(t)),p=u.next();!p.done;p=u.next()){var d=p.value;try{for(var f=(l=void 0,Object(r.e)(n)),h=f.next();!h.done;h=f.next()){var m=(0,h.value)(d);if(m){c.push(m);break}}}catch(g){l={error:g}}finally{try{h&&!h.done&&(s=f.return)&&s.call(f)}finally{if(l)throw l.error}}}}catch(b){i={error:b}}finally{try{p&&!p.done&&(a=u.return)&&a.call(u)}finally{if(i)throw i.error}}return o(c)}}function o(e){if(!e.length)return[];var t=e,n=t[0].function||"",i=t[t.length-1].function||"";return-1===n.indexOf("captureMessage")&&-1===n.indexOf("captureException")||(t=t.slice(1)),-1!==i.indexOf("sentryWrapped")&&(t=t.slice(0,-1)),t.slice(0,50).map((function(e){return Object(r.a)(Object(r.a)({},e),{filename:e.filename||t[0].filename,function:e.function||"?"})})).reverse()}var a="<anonymous>";function l(e){try{return e&&"function"===typeof e&&e.name||a}catch(t){return a}}},function(e,t,n){"use strict";var r=Object.getOwnPropertySymbols,i=Object.prototype.hasOwnProperty,o=Object.prototype.propertyIsEnumerable;function a(e){if(null===e||void 0===e)throw new TypeError("Object.assign cannot be called with null or undefined");return Object(e)}e.exports=function(){try{if(!Object.assign)return!1;var e=new String("abc");if(e[5]="de","5"===Object.getOwnPropertyNames(e)[0])return!1;for(var t={},n=0;n<10;n++)t["_"+String.fromCharCode(n)]=n;if("0123456789"!==Object.getOwnPropertyNames(t).map((function(e){return t[e]})).join(""))return!1;var r={};return"abcdefghijklmnopqrst".split("").forEach((function(e){r[e]=e})),"abcdefghijklmnopqrst"===Object.keys(Object.assign({},r)).join("")}catch(i){return!1}}()?Object.assign:function(e,t){for(var n,l,s=a(e),c=1;c<arguments.length;c++){for(var u in n=Object(arguments[c]))i.call(n,u)&&(s[u]=n[u]);if(r){l=r(n);for(var p=0;p<l.length;p++)o.call(n,l[p])&&(s[l[p]]=n[l[p]])}}return s}},function(e,t,n){"use strict";var r=function(){var e;return function(){return"undefined"===typeof e&&(e=Boolean(window&&document&&document.all&&!window.atob)),e}}(),i=function(){var e={};return function(t){if("undefined"===typeof e[t]){var n=document.querySelector(t);if(window.HTMLIFrameElement&&n instanceof window.HTMLIFrameElement)try{n=n.contentDocument.head}catch(r){n=null}e[t]=n}return e[t]}}(),o=[];function a(e){for(var t=-1,n=0;n<o.length;n++)if(o[n].identifier===e){t=n;break}return t}function l(e,t){for(var n={},r=[],i=0;i<e.length;i++){var l=e[i],s=t.base?l[0]+t.base:l[0],c=n[s]||0,u="".concat(s," ").concat(c);n[s]=c+1;var p=a(u),d={css:l[1],media:l[2],sourceMap:l[3]};-1!==p?(o[p].references++,o[p].updater(d)):o.push({identifier:u,updater:h(d,t),references:1}),r.push(u)}return r}function s(e){var t=document.createElement("style"),r=e.attributes||{};if("undefined"===typeof r.nonce){var o=n.nc;o&&(r.nonce=o)}if(Object.keys(r).forEach((function(e){t.setAttribute(e,r[e])})),"function"===typeof e.insert)e.insert(t);else{var a=i(e.insert||"head");if(!a)throw new Error("Couldn't find a style target. This probably means that the value for the 'insert' parameter is invalid.");a.appendChild(t)}return t}var c=function(){var e=[];return function(t,n){return e[t]=n,e.filter(Boolean).join("\n")}}();function u(e,t,n,r){var i=n?"":r.media?"@media ".concat(r.media," {").concat(r.css,"}"):r.css;if(e.styleSheet)e.styleSheet.cssText=c(t,i);else{var o=document.createTextNode(i),a=e.childNodes;a[t]&&e.removeChild(a[t]),a.length?e.insertBefore(o,a[t]):e.appendChild(o)}}function p(e,t,n){var r=n.css,i=n.media,o=n.sourceMap;if(i?e.setAttribute("media",i):e.removeAttribute("media"),o&&"undefined"!==typeof btoa&&(r+="\n/*# sourceMappingURL=data:application/json;base64,".concat(btoa(unescape(encodeURIComponent(JSON.stringify(o))))," */")),e.styleSheet)e.styleSheet.cssText=r;else{for(;e.firstChild;)e.removeChild(e.firstChild);e.appendChild(document.createTextNode(r))}}var d=null,f=0;function h(e,t){var n,r,i;if(t.singleton){var o=f++;n=d||(d=s(t)),r=u.bind(null,n,o,!1),i=u.bind(null,n,o,!0)}else n=s(t),r=p.bind(null,n,t),i=function(){!function(e){if(null===e.parentNode)return!1;e.parentNode.removeChild(e)}(n)};return r(e),function(t){if(t){if(t.css===e.css&&t.media===e.media&&t.sourceMap===e.sourceMap)return;r(e=t)}else i()}}e.exports=function(e,t){(t=t||{}).singleton||"boolean"===typeof t.singleton||(t.singleton=r());var n=l(e=e||[],t);return function(e){if(e=e||[],"[object Array]"===Object.prototype.toString.call(e)){for(var r=0;r<n.length;r++){var i=a(n[r]);o[i].references--}for(var s=l(e,t),c=0;c<n.length;c++){var u=a(n[c]);0===o[u].references&&(o[u].updater(),o.splice(u,1))}n=s}}}},function(e,t){e.exports=function(e){if(!e.webpackPolyfill){var t=Object.create(e);t.children||(t.children=[]),Object.defineProperty(t,"loaded",{enumerable:!0,get:function(){return t.l}}),Object.defineProperty(t,"id",{enumerable:!0,get:function(){return t.i}}),Object.defineProperty(t,"exports",{enumerable:!0}),t.webpackPolyfill=1}return t}},function(e,t){var n;n=function(){return this}();try{n=n||new Function("return this")()}catch(r){"object"===typeof window&&(n=window)}e.exports=n},function(e,t){function n(t){return e.exports=n="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},e.exports.__esModule=!0,e.exports.default=e.exports,n(t)}e.exports=n,e.exports.__esModule=!0,e.exports.default=e.exports},function(e,t,n){"use strict";var r=n(46),i={childContextTypes:!0,contextType:!0,contextTypes:!0,defaultProps:!0,displayName:!0,getDefaultProps:!0,getDerivedStateFromError:!0,getDerivedStateFromProps:!0,mixins:!0,propTypes:!0,type:!0},o={name:!0,length:!0,prototype:!0,caller:!0,callee:!0,arguments:!0,arity:!0},a={$$typeof:!0,compare:!0,defaultProps:!0,displayName:!0,propTypes:!0,type:!0},l={};function s(e){return r.isMemo(e)?a:l[e.$$typeof]||i}l[r.ForwardRef]={$$typeof:!0,render:!0,defaultProps:!0,displayName:!0,propTypes:!0},l[r.Memo]=a;var c=Object.defineProperty,u=Object.getOwnPropertyNames,p=Object.getOwnPropertySymbols,d=Object.getOwnPropertyDescriptor,f=Object.getPrototypeOf,h=Object.prototype;e.exports=function e(t,n,r){if("string"!==typeof n){if(h){var i=f(n);i&&i!==h&&e(t,i,r)}var a=u(n);p&&(a=a.concat(p(n)));for(var l=s(t),m=s(n),g=0;g<a.length;++g){var b=a[g];if(!o[b]&&(!r||!r[b])&&(!m||!m[b])&&(!l||!l[b])){var v=d(n,b);try{c(t,b,v)}catch(y){}}}}return t}},function(e,t,n){"use strict";(function(e){n.d(t,"a",(function(){return s})),n.d(t,"b",(function(){return c}));var r=n(9),i=n(17),o={nowSeconds:function(){return Date.now()/1e3}};var a=Object(i.b)()?function(){try{return Object(i.a)(e,"perf_hooks").performance}catch(t){return}}():function(){var e=Object(r.a)().performance;if(e&&e.now)return{now:function(){return e.now()},timeOrigin:Date.now()-e.now()}}(),l=void 0===a?o:{nowSeconds:function(){return(a.timeOrigin+a.now())/1e3}},s=o.nowSeconds.bind(o),c=l.nowSeconds.bind(l);!function(){var e=Object(r.a)().performance;if(e&&e.now){var t=36e5,n=e.now(),i=Date.now(),o=e.timeOrigin?Math.abs(e.timeOrigin+n-i):t,a=o<t,l=e.timing&&e.timing.navigationStart,s="number"===typeof l?Math.abs(l+n-i):t;return a||s<t?o<=s?("timeOrigin",e.timeOrigin):("navigationStart",l):("dateNow",i)}"none"}()}).call(this,n(25)(e))},function(e,t,n){"use strict";function r(){return"undefined"!==typeof __SENTRY_BROWSER_BUNDLE__&&!!__SENTRY_BROWSER_BUNDLE__}n.d(t,"a",(function(){return r}))},function(e,t,n){"use strict";n.d(t,"b",(function(){return o})),n.d(t,"a",(function(){return l}));var r=n(9),i=n(8);function o(e,t){try{for(var n=e,r=[],i=0,o=0,l=" > ".length,s=void 0;n&&i++<5&&!("html"===(s=a(n,t))||i>1&&o+r.length*l+s.length>=80);)r.push(s),o+=s.length,n=n.parentNode;return r.reverse().join(" > ")}catch(c){return"<unknown>"}}function a(e,t){var n,r,o,a,l,s=e,c=[];if(!s||!s.tagName)return"";c.push(s.tagName.toLowerCase());var u=t&&t.length?t.filter((function(e){return s.getAttribute(e)})).map((function(e){return[e,s.getAttribute(e)]})):null;if(u&&u.length)u.forEach((function(e){c.push("["+e[0]+'="'+e[1]+'"]')}));else if(s.id&&c.push("#"+s.id),(n=s.className)&&Object(i.l)(n))for(r=n.split(/\s+/),l=0;l<r.length;l++)c.push("."+r[l]);var p=["type","name","title","alt"];for(l=0;l<p.length;l++)o=p[l],(a=s.getAttribute(o))&&c.push("["+o+'="'+a+'"]');return c.join("")}function l(){var e=Object(r.a)();try{return e.document.location.href}catch(t){return""}}},function(e,t,n){"use strict";function r(){var e="function"===typeof WeakSet,t=e?new WeakSet:[];return[function(n){if(e)return!!t.has(n)||(t.add(n),!1);for(var r=0;r<t.length;r++){if(t[r]===n)return!0}return t.push(n),!1},function(n){if(e)t.delete(n);else for(var r=0;r<t.length;r++)if(t[r]===n){t.splice(r,1);break}}]}n.d(t,"a",(function(){return r}))},,,function(e,t,n){"use strict";var r=n(23),i=60103,o=60106;t.Fragment=60107,t.StrictMode=60108,t.Profiler=60114;var a=60109,l=60110,s=60112;t.Suspense=60113;var c=60115,u=60116;if("function"===typeof Symbol&&Symbol.for){var p=Symbol.for;i=p("react.element"),o=p("react.portal"),t.Fragment=p("react.fragment"),t.StrictMode=p("react.strict_mode"),t.Profiler=p("react.profiler"),a=p("react.provider"),l=p("react.context"),s=p("react.forward_ref"),t.Suspense=p("react.suspense"),c=p("react.memo"),u=p("react.lazy")}var d="function"===typeof Symbol&&Symbol.iterator;function f(e){for(var t="https://reactjs.org/docs/error-decoder.html?invariant="+e,n=1;n<arguments.length;n++)t+="&args[]="+encodeURIComponent(arguments[n]);return"Minified React error #"+e+"; visit "+t+" for the full message or use the non-minified dev environment for full errors and additional helpful warnings."}var h={isMounted:function(){return!1},enqueueForceUpdate:function(){},enqueueReplaceState:function(){},enqueueSetState:function(){}},m={};function g(e,t,n){this.props=e,this.context=t,this.refs=m,this.updater=n||h}function b(){}function v(e,t,n){this.props=e,this.context=t,this.refs=m,this.updater=n||h}g.prototype.isReactComponent={},g.prototype.setState=function(e,t){if("object"!==typeof e&&"function"!==typeof e&&null!=e)throw Error(f(85));this.updater.enqueueSetState(this,e,t,"setState")},g.prototype.forceUpdate=function(e){this.updater.enqueueForceUpdate(this,e,"forceUpdate")},b.prototype=g.prototype;var y=v.prototype=new b;y.constructor=v,r(y,g.prototype),y.isPureReactComponent=!0;var x={current:null},w=Object.prototype.hasOwnProperty,j={key:!0,ref:!0,__self:!0,__source:!0};function O(e,t,n){var r,o={},a=null,l=null;if(null!=t)for(r in void 0!==t.ref&&(l=t.ref),void 0!==t.key&&(a=""+t.key),t)w.call(t,r)&&!j.hasOwnProperty(r)&&(o[r]=t[r]);var s=arguments.length-2;if(1===s)o.children=n;else if(1<s){for(var c=Array(s),u=0;u<s;u++)c[u]=arguments[u+2];o.children=c}if(e&&e.defaultProps)for(r in s=e.defaultProps)void 0===o[r]&&(o[r]=s[r]);return{$$typeof:i,type:e,key:a,ref:l,props:o,_owner:x.current}}function k(e){return"object"===typeof e&&null!==e&&e.$$typeof===i}var _=/\/+/g;function S(e,t){return"object"===typeof e&&null!==e&&null!=e.key?function(e){var t={"=":"=0",":":"=2"};return"$"+e.replace(/[=:]/g,(function(e){return t[e]}))}(""+e.key):t.toString(36)}function P(e,t,n,r,a){var l=typeof e;"undefined"!==l&&"boolean"!==l||(e=null);var s=!1;if(null===e)s=!0;else switch(l){case"string":case"number":s=!0;break;case"object":switch(e.$$typeof){case i:case o:s=!0}}if(s)return a=a(s=e),e=""===r?"."+S(s,0):r,Array.isArray(a)?(n="",null!=e&&(n=e.replace(_,"$&/")+"/"),P(a,t,n,"",(function(e){return e}))):null!=a&&(k(a)&&(a=function(e,t){return{$$typeof:i,type:e.type,key:t,ref:e.ref,props:e.props,_owner:e._owner}}(a,n+(!a.key||s&&s.key===a.key?"":(""+a.key).replace(_,"$&/")+"/")+e)),t.push(a)),1;if(s=0,r=""===r?".":r+":",Array.isArray(e))for(var c=0;c<e.length;c++){var u=r+S(l=e[c],c);s+=P(l,t,n,u,a)}else if(u=function(e){return null===e||"object"!==typeof e?null:"function"===typeof(e=d&&e[d]||e["@@iterator"])?e:null}(e),"function"===typeof u)for(e=u.call(e),c=0;!(l=e.next()).done;)s+=P(l=l.value,t,n,u=r+S(l,c++),a);else if("object"===l)throw t=""+e,Error(f(31,"[object Object]"===t?"object with keys {"+Object.keys(e).join(", ")+"}":t));return s}function E(e,t,n){if(null==e)return e;var r=[],i=0;return P(e,r,"","",(function(e){return t.call(n,e,i++)})),r}function C(e){if(-1===e._status){var t=e._result;t=t(),e._status=0,e._result=t,t.then((function(t){0===e._status&&(t=t.default,e._status=1,e._result=t)}),(function(t){0===e._status&&(e._status=2,e._result=t)}))}if(1===e._status)return e._result;throw e._result}var N={current:null};function T(){var e=N.current;if(null===e)throw Error(f(321));return e}var I={ReactCurrentDispatcher:N,ReactCurrentBatchConfig:{transition:0},ReactCurrentOwner:x,IsSomeRendererActing:{current:!1},assign:r};t.Children={map:E,forEach:function(e,t,n){E(e,(function(){t.apply(this,arguments)}),n)},count:function(e){var t=0;return E(e,(function(){t++})),t},toArray:function(e){return E(e,(function(e){return e}))||[]},only:function(e){if(!k(e))throw Error(f(143));return e}},t.Component=g,t.PureComponent=v,t.__SECRET_INTERNALS_DO_NOT_USE_OR_YOU_WILL_BE_FIRED=I,t.cloneElement=function(e,t,n){if(null===e||void 0===e)throw Error(f(267,e));var o=r({},e.props),a=e.key,l=e.ref,s=e._owner;if(null!=t){if(void 0!==t.ref&&(l=t.ref,s=x.current),void 0!==t.key&&(a=""+t.key),e.type&&e.type.defaultProps)var c=e.type.defaultProps;for(u in t)w.call(t,u)&&!j.hasOwnProperty(u)&&(o[u]=void 0===t[u]&&void 0!==c?c[u]:t[u])}var u=arguments.length-2;if(1===u)o.children=n;else if(1<u){c=Array(u);for(var p=0;p<u;p++)c[p]=arguments[p+2];o.children=c}return{$$typeof:i,type:e.type,key:a,ref:l,props:o,_owner:s}},t.createContext=function(e,t){return void 0===t&&(t=null),(e={$$typeof:l,_calculateChangedBits:t,_currentValue:e,_currentValue2:e,_threadCount:0,Provider:null,Consumer:null}).Provider={$$typeof:a,_context:e},e.Consumer=e},t.createElement=O,t.createFactory=function(e){var t=O.bind(null,e);return t.type=e,t},t.createRef=function(){return{current:null}},t.forwardRef=function(e){return{$$typeof:s,render:e}},t.isValidElement=k,t.lazy=function(e){return{$$typeof:u,_payload:{_status:-1,_result:e},_init:C}},t.memo=function(e,t){return{$$typeof:c,type:e,compare:void 0===t?null:t}},t.useCallback=function(e,t){return T().useCallback(e,t)},t.useContext=function(e,t){return T().useContext(e,t)},t.useDebugValue=function(){},t.useEffect=function(e,t){return T().useEffect(e,t)},t.useImperativeHandle=function(e,t,n){return T().useImperativeHandle(e,t,n)},t.useLayoutEffect=function(e,t){return T().useLayoutEffect(e,t)},t.useMemo=function(e,t){return T().useMemo(e,t)},t.useReducer=function(e,t,n){return T().useReducer(e,t,n)},t.useRef=function(e){return T().useRef(e)},t.useState=function(e){return T().useState(e)},t.version="17.0.2"},function(e,t,n){"use strict";var r=n(1),i=n(23),o=n(37);function a(e){for(var t="https://reactjs.org/docs/error-decoder.html?invariant="+e,n=1;n<arguments.length;n++)t+="&args[]="+encodeURIComponent(arguments[n]);return"Minified React error #"+e+"; visit "+t+" for the full message or use the non-minified dev environment for full errors and additional helpful warnings."}if(!r)throw Error(a(227));var l=new Set,s={};function c(e,t){u(e,t),u(e+"Capture",t)}function u(e,t){for(s[e]=t,e=0;e<t.length;e++)l.add(t[e])}var p=!("undefined"===typeof window||"undefined"===typeof window.document||"undefined"===typeof window.document.createElement),d=/^[:A-Z_a-z\u00C0-\u00D6\u00D8-\u00F6\u00F8-\u02FF\u0370-\u037D\u037F-\u1FFF\u200C-\u200D\u2070-\u218F\u2C00-\u2FEF\u3001-\uD7FF\uF900-\uFDCF\uFDF0-\uFFFD][:A-Z_a-z\u00C0-\u00D6\u00D8-\u00F6\u00F8-\u02FF\u0370-\u037D\u037F-\u1FFF\u200C-\u200D\u2070-\u218F\u2C00-\u2FEF\u3001-\uD7FF\uF900-\uFDCF\uFDF0-\uFFFD\-.0-9\u00B7\u0300-\u036F\u203F-\u2040]*$/,f=Object.prototype.hasOwnProperty,h={},m={};function g(e,t,n,r,i,o,a){this.acceptsBooleans=2===t||3===t||4===t,this.attributeName=r,this.attributeNamespace=i,this.mustUseProperty=n,this.propertyName=e,this.type=t,this.sanitizeURL=o,this.removeEmptyString=a}var b={};"children dangerouslySetInnerHTML defaultValue defaultChecked innerHTML suppressContentEditableWarning suppressHydrationWarning style".split(" ").forEach((function(e){b[e]=new g(e,0,!1,e,null,!1,!1)})),[["acceptCharset","accept-charset"],["className","class"],["htmlFor","for"],["httpEquiv","http-equiv"]].forEach((function(e){var t=e[0];b[t]=new g(t,1,!1,e[1],null,!1,!1)})),["contentEditable","draggable","spellCheck","value"].forEach((function(e){b[e]=new g(e,2,!1,e.toLowerCase(),null,!1,!1)})),["autoReverse","externalResourcesRequired","focusable","preserveAlpha"].forEach((function(e){b[e]=new g(e,2,!1,e,null,!1,!1)})),"allowFullScreen async autoFocus autoPlay controls default defer disabled disablePictureInPicture disableRemotePlayback formNoValidate hidden loop noModule noValidate open playsInline readOnly required reversed scoped seamless itemScope".split(" ").forEach((function(e){b[e]=new g(e,3,!1,e.toLowerCase(),null,!1,!1)})),["checked","multiple","muted","selected"].forEach((function(e){b[e]=new g(e,3,!0,e,null,!1,!1)})),["capture","download"].forEach((function(e){b[e]=new g(e,4,!1,e,null,!1,!1)})),["cols","rows","size","span"].forEach((function(e){b[e]=new g(e,6,!1,e,null,!1,!1)})),["rowSpan","start"].forEach((function(e){b[e]=new g(e,5,!1,e.toLowerCase(),null,!1,!1)}));var v=/[\-:]([a-z])/g;function y(e){return e[1].toUpperCase()}function x(e,t,n,r){var i=b.hasOwnProperty(t)?b[t]:null;(null!==i?0===i.type:!r&&(2<t.length&&("o"===t[0]||"O"===t[0])&&("n"===t[1]||"N"===t[1])))||(function(e,t,n,r){if(null===t||"undefined"===typeof t||function(e,t,n,r){if(null!==n&&0===n.type)return!1;switch(typeof t){case"function":case"symbol":return!0;case"boolean":return!r&&(null!==n?!n.acceptsBooleans:"data-"!==(e=e.toLowerCase().slice(0,5))&&"aria-"!==e);default:return!1}}(e,t,n,r))return!0;if(r)return!1;if(null!==n)switch(n.type){case 3:return!t;case 4:return!1===t;case 5:return isNaN(t);case 6:return isNaN(t)||1>t}return!1}(t,n,i,r)&&(n=null),r||null===i?function(e){return!!f.call(m,e)||!f.call(h,e)&&(d.test(e)?m[e]=!0:(h[e]=!0,!1))}(t)&&(null===n?e.removeAttribute(t):e.setAttribute(t,""+n)):i.mustUseProperty?e[i.propertyName]=null===n?3!==i.type&&"":n:(t=i.attributeName,r=i.attributeNamespace,null===n?e.removeAttribute(t):(n=3===(i=i.type)||4===i&&!0===n?"":""+n,r?e.setAttributeNS(r,t,n):e.setAttribute(t,n))))}"accent-height alignment-baseline arabic-form baseline-shift cap-height clip-path clip-rule color-interpolation color-interpolation-filters color-profile color-rendering dominant-baseline enable-background fill-opacity fill-rule flood-color flood-opacity font-family font-size font-size-adjust font-stretch font-style font-variant font-weight glyph-name glyph-orientation-horizontal glyph-orientation-vertical horiz-adv-x horiz-origin-x image-rendering letter-spacing lighting-color marker-end marker-mid marker-start overline-position overline-thickness paint-order panose-1 pointer-events rendering-intent shape-rendering stop-color stop-opacity strikethrough-position strikethrough-thickness stroke-dasharray stroke-dashoffset stroke-linecap stroke-linejoin stroke-miterlimit stroke-opacity stroke-width text-anchor text-decoration text-rendering underline-position underline-thickness unicode-bidi unicode-range units-per-em v-alphabetic v-hanging v-ideographic v-mathematical vector-effect vert-adv-y vert-origin-x vert-origin-y word-spacing writing-mode xmlns:xlink x-height".split(" ").forEach((function(e){var t=e.replace(v,y);b[t]=new g(t,1,!1,e,null,!1,!1)})),"xlink:actuate xlink:arcrole xlink:role xlink:show xlink:title xlink:type".split(" ").forEach((function(e){var t=e.replace(v,y);b[t]=new g(t,1,!1,e,"http://www.w3.org/1999/xlink",!1,!1)})),["xml:base","xml:lang","xml:space"].forEach((function(e){var t=e.replace(v,y);b[t]=new g(t,1,!1,e,"http://www.w3.org/XML/1998/namespace",!1,!1)})),["tabIndex","crossOrigin"].forEach((function(e){b[e]=new g(e,1,!1,e.toLowerCase(),null,!1,!1)})),b.xlinkHref=new g("xlinkHref",1,!1,"xlink:href","http://www.w3.org/1999/xlink",!0,!1),["src","href","action","formAction"].forEach((function(e){b[e]=new g(e,1,!1,e.toLowerCase(),null,!0,!0)}));var w=r.__SECRET_INTERNALS_DO_NOT_USE_OR_YOU_WILL_BE_FIRED,j=60103,O=60106,k=60107,_=60108,S=60114,P=60109,E=60110,C=60112,N=60113,T=60120,I=60115,L=60116,M=60121,F=60128,D=60129,z=60130,R=60131;if("function"===typeof Symbol&&Symbol.for){var U=Symbol.for;j=U("react.element"),O=U("react.portal"),k=U("react.fragment"),_=U("react.strict_mode"),S=U("react.profiler"),P=U("react.provider"),E=U("react.context"),C=U("react.forward_ref"),N=U("react.suspense"),T=U("react.suspense_list"),I=U("react.memo"),L=U("react.lazy"),M=U("react.block"),U("react.scope"),F=U("react.opaque.id"),D=U("react.debug_trace_mode"),z=U("react.offscreen"),R=U("react.legacy_hidden")}var A,B="function"===typeof Symbol&&Symbol.iterator;function H(e){return null===e||"object"!==typeof e?null:"function"===typeof(e=B&&e[B]||e["@@iterator"])?e:null}function q(e){if(void 0===A)try{throw Error()}catch(n){var t=n.stack.trim().match(/\n( *(at )?)/);A=t&&t[1]||""}return"\n"+A+e}var $=!1;function W(e,t){if(!e||$)return"";$=!0;var n=Error.prepareStackTrace;Error.prepareStackTrace=void 0;try{if(t)if(t=function(){throw Error()},Object.defineProperty(t.prototype,"props",{set:function(){throw Error()}}),"object"===typeof Reflect&&Reflect.construct){try{Reflect.construct(t,[])}catch(s){var r=s}Reflect.construct(e,[],t)}else{try{t.call()}catch(s){r=s}e.call(t.prototype)}else{try{throw Error()}catch(s){r=s}e()}}catch(s){if(s&&r&&"string"===typeof s.stack){for(var i=s.stack.split("\n"),o=r.stack.split("\n"),a=i.length-1,l=o.length-1;1<=a&&0<=l&&i[a]!==o[l];)l--;for(;1<=a&&0<=l;a--,l--)if(i[a]!==o[l]){if(1!==a||1!==l)do{if(a--,0>--l||i[a]!==o[l])return"\n"+i[a].replace(" at new "," at ")}while(1<=a&&0<=l);break}}}finally{$=!1,Error.prepareStackTrace=n}return(e=e?e.displayName||e.name:"")?q(e):""}function Q(e){switch(e.tag){case 5:return q(e.type);case 16:return q("Lazy");case 13:return q("Suspense");case 19:return q("SuspenseList");case 0:case 2:case 15:return e=W(e.type,!1);case 11:return e=W(e.type.render,!1);case 22:return e=W(e.type._render,!1);case 1:return e=W(e.type,!0);default:return""}}function V(e){if(null==e)return null;if("function"===typeof e)return e.displayName||e.name||null;if("string"===typeof e)return e;switch(e){case k:return"Fragment";case O:return"Portal";case S:return"Profiler";case _:return"StrictMode";case N:return"Suspense";case T:return"SuspenseList"}if("object"===typeof e)switch(e.$$typeof){case E:return(e.displayName||"Context")+".Consumer";case P:return(e._context.displayName||"Context")+".Provider";case C:var t=e.render;return t=t.displayName||t.name||"",e.displayName||(""!==t?"ForwardRef("+t+")":"ForwardRef");case I:return V(e.type);case M:return V(e._render);case L:t=e._payload,e=e._init;try{return V(e(t))}catch(n){}}return null}function Y(e){switch(typeof e){case"boolean":case"number":case"object":case"string":case"undefined":return e;default:return""}}function K(e){var t=e.type;return(e=e.nodeName)&&"input"===e.toLowerCase()&&("checkbox"===t||"radio"===t)}function G(e){e._valueTracker||(e._valueTracker=function(e){var t=K(e)?"checked":"value",n=Object.getOwnPropertyDescriptor(e.constructor.prototype,t),r=""+e[t];if(!e.hasOwnProperty(t)&&"undefined"!==typeof n&&"function"===typeof n.get&&"function"===typeof n.set){var i=n.get,o=n.set;return Object.defineProperty(e,t,{configurable:!0,get:function(){return i.call(this)},set:function(e){r=""+e,o.call(this,e)}}),Object.defineProperty(e,t,{enumerable:n.enumerable}),{getValue:function(){return r},setValue:function(e){r=""+e},stopTracking:function(){e._valueTracker=null,delete e[t]}}}}(e))}function J(e){if(!e)return!1;var t=e._valueTracker;if(!t)return!0;var n=t.getValue(),r="";return e&&(r=K(e)?e.checked?"true":"false":e.value),(e=r)!==n&&(t.setValue(e),!0)}function X(e){if("undefined"===typeof(e=e||("undefined"!==typeof document?document:void 0)))return null;try{return e.activeElement||e.body}catch(t){return e.body}}function Z(e,t){var n=t.checked;return i({},t,{defaultChecked:void 0,defaultValue:void 0,value:void 0,checked:null!=n?n:e._wrapperState.initialChecked})}function ee(e,t){var n=null==t.defaultValue?"":t.defaultValue,r=null!=t.checked?t.checked:t.defaultChecked;n=Y(null!=t.value?t.value:n),e._wrapperState={initialChecked:r,initialValue:n,controlled:"checkbox"===t.type||"radio"===t.type?null!=t.checked:null!=t.value}}function te(e,t){null!=(t=t.checked)&&x(e,"checked",t,!1)}function ne(e,t){te(e,t);var n=Y(t.value),r=t.type;if(null!=n)"number"===r?(0===n&&""===e.value||e.value!=n)&&(e.value=""+n):e.value!==""+n&&(e.value=""+n);else if("submit"===r||"reset"===r)return void e.removeAttribute("value");t.hasOwnProperty("value")?ie(e,t.type,n):t.hasOwnProperty("defaultValue")&&ie(e,t.type,Y(t.defaultValue)),null==t.checked&&null!=t.defaultChecked&&(e.defaultChecked=!!t.defaultChecked)}function re(e,t,n){if(t.hasOwnProperty("value")||t.hasOwnProperty("defaultValue")){var r=t.type;if(!("submit"!==r&&"reset"!==r||void 0!==t.value&&null!==t.value))return;t=""+e._wrapperState.initialValue,n||t===e.value||(e.value=t),e.defaultValue=t}""!==(n=e.name)&&(e.name=""),e.defaultChecked=!!e._wrapperState.initialChecked,""!==n&&(e.name=n)}function ie(e,t,n){"number"===t&&X(e.ownerDocument)===e||(null==n?e.defaultValue=""+e._wrapperState.initialValue:e.defaultValue!==""+n&&(e.defaultValue=""+n))}function oe(e,t){return e=i({children:void 0},t),(t=function(e){var t="";return r.Children.forEach(e,(function(e){null!=e&&(t+=e)})),t}(t.children))&&(e.children=t),e}function ae(e,t,n,r){if(e=e.options,t){t={};for(var i=0;i<n.length;i++)t["$"+n[i]]=!0;for(n=0;n<e.length;n++)i=t.hasOwnProperty("$"+e[n].value),e[n].selected!==i&&(e[n].selected=i),i&&r&&(e[n].defaultSelected=!0)}else{for(n=""+Y(n),t=null,i=0;i<e.length;i++){if(e[i].value===n)return e[i].selected=!0,void(r&&(e[i].defaultSelected=!0));null!==t||e[i].disabled||(t=e[i])}null!==t&&(t.selected=!0)}}function le(e,t){if(null!=t.dangerouslySetInnerHTML)throw Error(a(91));return i({},t,{value:void 0,defaultValue:void 0,children:""+e._wrapperState.initialValue})}function se(e,t){var n=t.value;if(null==n){if(n=t.children,t=t.defaultValue,null!=n){if(null!=t)throw Error(a(92));if(Array.isArray(n)){if(!(1>=n.length))throw Error(a(93));n=n[0]}t=n}null==t&&(t=""),n=t}e._wrapperState={initialValue:Y(n)}}function ce(e,t){var n=Y(t.value),r=Y(t.defaultValue);null!=n&&((n=""+n)!==e.value&&(e.value=n),null==t.defaultValue&&e.defaultValue!==n&&(e.defaultValue=n)),null!=r&&(e.defaultValue=""+r)}function ue(e){var t=e.textContent;t===e._wrapperState.initialValue&&""!==t&&null!==t&&(e.value=t)}var pe="http://www.w3.org/1999/xhtml",de="http://www.w3.org/2000/svg";function fe(e){switch(e){case"svg":return"http://www.w3.org/2000/svg";case"math":return"http://www.w3.org/1998/Math/MathML";default:return"http://www.w3.org/1999/xhtml"}}function he(e,t){return null==e||"http://www.w3.org/1999/xhtml"===e?fe(t):"http://www.w3.org/2000/svg"===e&&"foreignObject"===t?"http://www.w3.org/1999/xhtml":e}var me,ge,be=(ge=function(e,t){if(e.namespaceURI!==de||"innerHTML"in e)e.innerHTML=t;else{for((me=me||document.createElement("div")).innerHTML="<svg>"+t.valueOf().toString()+"</svg>",t=me.firstChild;e.firstChild;)e.removeChild(e.firstChild);for(;t.firstChild;)e.appendChild(t.firstChild)}},"undefined"!==typeof MSApp&&MSApp.execUnsafeLocalFunction?function(e,t,n,r){MSApp.execUnsafeLocalFunction((function(){return ge(e,t)}))}:ge);function ve(e,t){if(t){var n=e.firstChild;if(n&&n===e.lastChild&&3===n.nodeType)return void(n.nodeValue=t)}e.textContent=t}var ye={animationIterationCount:!0,borderImageOutset:!0,borderImageSlice:!0,borderImageWidth:!0,boxFlex:!0,boxFlexGroup:!0,boxOrdinalGroup:!0,columnCount:!0,columns:!0,flex:!0,flexGrow:!0,flexPositive:!0,flexShrink:!0,flexNegative:!0,flexOrder:!0,gridArea:!0,gridRow:!0,gridRowEnd:!0,gridRowSpan:!0,gridRowStart:!0,gridColumn:!0,gridColumnEnd:!0,gridColumnSpan:!0,gridColumnStart:!0,fontWeight:!0,lineClamp:!0,lineHeight:!0,opacity:!0,order:!0,orphans:!0,tabSize:!0,widows:!0,zIndex:!0,zoom:!0,fillOpacity:!0,floodOpacity:!0,stopOpacity:!0,strokeDasharray:!0,strokeDashoffset:!0,strokeMiterlimit:!0,strokeOpacity:!0,strokeWidth:!0},xe=["Webkit","ms","Moz","O"];function we(e,t,n){return null==t||"boolean"===typeof t||""===t?"":n||"number"!==typeof t||0===t||ye.hasOwnProperty(e)&&ye[e]?(""+t).trim():t+"px"}function je(e,t){for(var n in e=e.style,t)if(t.hasOwnProperty(n)){var r=0===n.indexOf("--"),i=we(n,t[n],r);"float"===n&&(n="cssFloat"),r?e.setProperty(n,i):e[n]=i}}Object.keys(ye).forEach((function(e){xe.forEach((function(t){t=t+e.charAt(0).toUpperCase()+e.substring(1),ye[t]=ye[e]}))}));var Oe=i({menuitem:!0},{area:!0,base:!0,br:!0,col:!0,embed:!0,hr:!0,img:!0,input:!0,keygen:!0,link:!0,meta:!0,param:!0,source:!0,track:!0,wbr:!0});function ke(e,t){if(t){if(Oe[e]&&(null!=t.children||null!=t.dangerouslySetInnerHTML))throw Error(a(137,e));if(null!=t.dangerouslySetInnerHTML){if(null!=t.children)throw Error(a(60));if("object"!==typeof t.dangerouslySetInnerHTML||!("__html"in t.dangerouslySetInnerHTML))throw Error(a(61))}if(null!=t.style&&"object"!==typeof t.style)throw Error(a(62))}}function _e(e,t){if(-1===e.indexOf("-"))return"string"===typeof t.is;switch(e){case"annotation-xml":case"color-profile":case"font-face":case"font-face-src":case"font-face-uri":case"font-face-format":case"font-face-name":case"missing-glyph":return!1;default:return!0}}function Se(e){return(e=e.target||e.srcElement||window).correspondingUseElement&&(e=e.correspondingUseElement),3===e.nodeType?e.parentNode:e}var Pe=null,Ee=null,Ce=null;function Ne(e){if(e=ri(e)){if("function"!==typeof Pe)throw Error(a(280));var t=e.stateNode;t&&(t=oi(t),Pe(e.stateNode,e.type,t))}}function Te(e){Ee?Ce?Ce.push(e):Ce=[e]:Ee=e}function Ie(){if(Ee){var e=Ee,t=Ce;if(Ce=Ee=null,Ne(e),t)for(e=0;e<t.length;e++)Ne(t[e])}}function Le(e,t){return e(t)}function Me(e,t,n,r,i){return e(t,n,r,i)}function Fe(){}var De=Le,ze=!1,Re=!1;function Ue(){null===Ee&&null===Ce||(Fe(),Ie())}function Ae(e,t){var n=e.stateNode;if(null===n)return null;var r=oi(n);if(null===r)return null;n=r[t];e:switch(t){case"onClick":case"onClickCapture":case"onDoubleClick":case"onDoubleClickCapture":case"onMouseDown":case"onMouseDownCapture":case"onMouseMove":case"onMouseMoveCapture":case"onMouseUp":case"onMouseUpCapture":case"onMouseEnter":(r=!r.disabled)||(r=!("button"===(e=e.type)||"input"===e||"select"===e||"textarea"===e)),e=!r;break e;default:e=!1}if(e)return null;if(n&&"function"!==typeof n)throw Error(a(231,t,typeof n));return n}var Be=!1;if(p)try{var He={};Object.defineProperty(He,"passive",{get:function(){Be=!0}}),window.addEventListener("test",He,He),window.removeEventListener("test",He,He)}catch(ge){Be=!1}function qe(e,t,n,r,i,o,a,l,s){var c=Array.prototype.slice.call(arguments,3);try{t.apply(n,c)}catch(u){this.onError(u)}}var $e=!1,We=null,Qe=!1,Ve=null,Ye={onError:function(e){$e=!0,We=e}};function Ke(e,t,n,r,i,o,a,l,s){$e=!1,We=null,qe.apply(Ye,arguments)}function Ge(e){var t=e,n=e;if(e.alternate)for(;t.return;)t=t.return;else{e=t;do{0!==(1026&(t=e).flags)&&(n=t.return),e=t.return}while(e)}return 3===t.tag?n:null}function Je(e){if(13===e.tag){var t=e.memoizedState;if(null===t&&(null!==(e=e.alternate)&&(t=e.memoizedState)),null!==t)return t.dehydrated}return null}function Xe(e){if(Ge(e)!==e)throw Error(a(188))}function Ze(e){if(e=function(e){var t=e.alternate;if(!t){if(null===(t=Ge(e)))throw Error(a(188));return t!==e?null:e}for(var n=e,r=t;;){var i=n.return;if(null===i)break;var o=i.alternate;if(null===o){if(null!==(r=i.return)){n=r;continue}break}if(i.child===o.child){for(o=i.child;o;){if(o===n)return Xe(i),e;if(o===r)return Xe(i),t;o=o.sibling}throw Error(a(188))}if(n.return!==r.return)n=i,r=o;else{for(var l=!1,s=i.child;s;){if(s===n){l=!0,n=i,r=o;break}if(s===r){l=!0,r=i,n=o;break}s=s.sibling}if(!l){for(s=o.child;s;){if(s===n){l=!0,n=o,r=i;break}if(s===r){l=!0,r=o,n=i;break}s=s.sibling}if(!l)throw Error(a(189))}}if(n.alternate!==r)throw Error(a(190))}if(3!==n.tag)throw Error(a(188));return n.stateNode.current===n?e:t}(e),!e)return null;for(var t=e;;){if(5===t.tag||6===t.tag)return t;if(t.child)t.child.return=t,t=t.child;else{if(t===e)break;for(;!t.sibling;){if(!t.return||t.return===e)return null;t=t.return}t.sibling.return=t.return,t=t.sibling}}return null}function et(e,t){for(var n=e.alternate;null!==t;){if(t===e||t===n)return!0;t=t.return}return!1}var tt,nt,rt,it,ot=!1,at=[],lt=null,st=null,ct=null,ut=new Map,pt=new Map,dt=[],ft="mousedown mouseup touchcancel touchend touchstart auxclick dblclick pointercancel pointerdown pointerup dragend dragstart drop compositionend compositionstart keydown keypress keyup input textInput copy cut paste click change contextmenu reset submit".split(" ");function ht(e,t,n,r,i){return{blockedOn:e,domEventName:t,eventSystemFlags:16|n,nativeEvent:i,targetContainers:[r]}}function mt(e,t){switch(e){case"focusin":case"focusout":lt=null;break;case"dragenter":case"dragleave":st=null;break;case"mouseover":case"mouseout":ct=null;break;case"pointerover":case"pointerout":ut.delete(t.pointerId);break;case"gotpointercapture":case"lostpointercapture":pt.delete(t.pointerId)}}function gt(e,t,n,r,i,o){return null===e||e.nativeEvent!==o?(e=ht(t,n,r,i,o),null!==t&&(null!==(t=ri(t))&&nt(t)),e):(e.eventSystemFlags|=r,t=e.targetContainers,null!==i&&-1===t.indexOf(i)&&t.push(i),e)}function bt(e){var t=ni(e.target);if(null!==t){var n=Ge(t);if(null!==n)if(13===(t=n.tag)){if(null!==(t=Je(n)))return e.blockedOn=t,void it(e.lanePriority,(function(){o.unstable_runWithPriority(e.priority,(function(){rt(n)}))}))}else if(3===t&&n.stateNode.hydrate)return void(e.blockedOn=3===n.tag?n.stateNode.containerInfo:null)}e.blockedOn=null}function vt(e){if(null!==e.blockedOn)return!1;for(var t=e.targetContainers;0<t.length;){var n=Zt(e.domEventName,e.eventSystemFlags,t[0],e.nativeEvent);if(null!==n)return null!==(t=ri(n))&&nt(t),e.blockedOn=n,!1;t.shift()}return!0}function yt(e,t,n){vt(e)&&n.delete(t)}function xt(){for(ot=!1;0<at.length;){var e=at[0];if(null!==e.blockedOn){null!==(e=ri(e.blockedOn))&&tt(e);break}for(var t=e.targetContainers;0<t.length;){var n=Zt(e.domEventName,e.eventSystemFlags,t[0],e.nativeEvent);if(null!==n){e.blockedOn=n;break}t.shift()}null===e.blockedOn&&at.shift()}null!==lt&&vt(lt)&&(lt=null),null!==st&&vt(st)&&(st=null),null!==ct&&vt(ct)&&(ct=null),ut.forEach(yt),pt.forEach(yt)}function wt(e,t){e.blockedOn===t&&(e.blockedOn=null,ot||(ot=!0,o.unstable_scheduleCallback(o.unstable_NormalPriority,xt)))}function jt(e){function t(t){return wt(t,e)}if(0<at.length){wt(at[0],e);for(var n=1;n<at.length;n++){var r=at[n];r.blockedOn===e&&(r.blockedOn=null)}}for(null!==lt&&wt(lt,e),null!==st&&wt(st,e),null!==ct&&wt(ct,e),ut.forEach(t),pt.forEach(t),n=0;n<dt.length;n++)(r=dt[n]).blockedOn===e&&(r.blockedOn=null);for(;0<dt.length&&null===(n=dt[0]).blockedOn;)bt(n),null===n.blockedOn&&dt.shift()}function Ot(e,t){var n={};return n[e.toLowerCase()]=t.toLowerCase(),n["Webkit"+e]="webkit"+t,n["Moz"+e]="moz"+t,n}var kt={animationend:Ot("Animation","AnimationEnd"),animationiteration:Ot("Animation","AnimationIteration"),animationstart:Ot("Animation","AnimationStart"),transitionend:Ot("Transition","TransitionEnd")},_t={},St={};function Pt(e){if(_t[e])return _t[e];if(!kt[e])return e;var t,n=kt[e];for(t in n)if(n.hasOwnProperty(t)&&t in St)return _t[e]=n[t];return e}p&&(St=document.createElement("div").style,"AnimationEvent"in window||(delete kt.animationend.animation,delete kt.animationiteration.animation,delete kt.animationstart.animation),"TransitionEvent"in window||delete kt.transitionend.transition);var Et=Pt("animationend"),Ct=Pt("animationiteration"),Nt=Pt("animationstart"),Tt=Pt("transitionend"),It=new Map,Lt=new Map,Mt=["abort","abort",Et,"animationEnd",Ct,"animationIteration",Nt,"animationStart","canplay","canPlay","canplaythrough","canPlayThrough","durationchange","durationChange","emptied","emptied","encrypted","encrypted","ended","ended","error","error","gotpointercapture","gotPointerCapture","load","load","loadeddata","loadedData","loadedmetadata","loadedMetadata","loadstart","loadStart","lostpointercapture","lostPointerCapture","playing","playing","progress","progress","seeking","seeking","stalled","stalled","suspend","suspend","timeupdate","timeUpdate",Tt,"transitionEnd","waiting","waiting"];function Ft(e,t){for(var n=0;n<e.length;n+=2){var r=e[n],i=e[n+1];i="on"+(i[0].toUpperCase()+i.slice(1)),Lt.set(r,t),It.set(r,i),c(i,[r])}}(0,o.unstable_now)();var Dt=8;function zt(e){if(0!==(1&e))return Dt=15,1;if(0!==(2&e))return Dt=14,2;if(0!==(4&e))return Dt=13,4;var t=24&e;return 0!==t?(Dt=12,t):0!==(32&e)?(Dt=11,32):0!==(t=192&e)?(Dt=10,t):0!==(256&e)?(Dt=9,256):0!==(t=3584&e)?(Dt=8,t):0!==(4096&e)?(Dt=7,4096):0!==(t=4186112&e)?(Dt=6,t):0!==(t=62914560&e)?(Dt=5,t):67108864&e?(Dt=4,67108864):0!==(134217728&e)?(Dt=3,134217728):0!==(t=805306368&e)?(Dt=2,t):0!==(1073741824&e)?(Dt=1,1073741824):(Dt=8,e)}function Rt(e,t){var n=e.pendingLanes;if(0===n)return Dt=0;var r=0,i=0,o=e.expiredLanes,a=e.suspendedLanes,l=e.pingedLanes;if(0!==o)r=o,i=Dt=15;else if(0!==(o=134217727&n)){var s=o&~a;0!==s?(r=zt(s),i=Dt):0!==(l&=o)&&(r=zt(l),i=Dt)}else 0!==(o=n&~a)?(r=zt(o),i=Dt):0!==l&&(r=zt(l),i=Dt);if(0===r)return 0;if(r=n&((0>(r=31-$t(r))?0:1<<r)<<1)-1,0!==t&&t!==r&&0===(t&a)){if(zt(t),i<=Dt)return t;Dt=i}if(0!==(t=e.entangledLanes))for(e=e.entanglements,t&=r;0<t;)i=1<<(n=31-$t(t)),r|=e[n],t&=~i;return r}function Ut(e){return 0!==(e=-1073741825&e.pendingLanes)?e:1073741824&e?1073741824:0}function At(e,t){switch(e){case 15:return 1;case 14:return 2;case 12:return 0===(e=Bt(24&~t))?At(10,t):e;case 10:return 0===(e=Bt(192&~t))?At(8,t):e;case 8:return 0===(e=Bt(3584&~t))&&(0===(e=Bt(4186112&~t))&&(e=512)),e;case 2:return 0===(t=Bt(805306368&~t))&&(t=268435456),t}throw Error(a(358,e))}function Bt(e){return e&-e}function Ht(e){for(var t=[],n=0;31>n;n++)t.push(e);return t}function qt(e,t,n){e.pendingLanes|=t;var r=t-1;e.suspendedLanes&=r,e.pingedLanes&=r,(e=e.eventTimes)[t=31-$t(t)]=n}var $t=Math.clz32?Math.clz32:function(e){return 0===e?32:31-(Wt(e)/Qt|0)|0},Wt=Math.log,Qt=Math.LN2;var Vt=o.unstable_UserBlockingPriority,Yt=o.unstable_runWithPriority,Kt=!0;function Gt(e,t,n,r){ze||Fe();var i=Xt,o=ze;ze=!0;try{Me(i,e,t,n,r)}finally{(ze=o)||Ue()}}function Jt(e,t,n,r){Yt(Vt,Xt.bind(null,e,t,n,r))}function Xt(e,t,n,r){var i;if(Kt)if((i=0===(4&t))&&0<at.length&&-1<ft.indexOf(e))e=ht(null,e,t,n,r),at.push(e);else{var o=Zt(e,t,n,r);if(null===o)i&&mt(e,r);else{if(i){if(-1<ft.indexOf(e))return e=ht(o,e,t,n,r),void at.push(e);if(function(e,t,n,r,i){switch(t){case"focusin":return lt=gt(lt,e,t,n,r,i),!0;case"dragenter":return st=gt(st,e,t,n,r,i),!0;case"mouseover":return ct=gt(ct,e,t,n,r,i),!0;case"pointerover":var o=i.pointerId;return ut.set(o,gt(ut.get(o)||null,e,t,n,r,i)),!0;case"gotpointercapture":return o=i.pointerId,pt.set(o,gt(pt.get(o)||null,e,t,n,r,i)),!0}return!1}(o,e,t,n,r))return;mt(e,r)}Fr(e,t,r,null,n)}}}function Zt(e,t,n,r){var i=Se(r);if(null!==(i=ni(i))){var o=Ge(i);if(null===o)i=null;else{var a=o.tag;if(13===a){if(null!==(i=Je(o)))return i;i=null}else if(3===a){if(o.stateNode.hydrate)return 3===o.tag?o.stateNode.containerInfo:null;i=null}else o!==i&&(i=null)}}return Fr(e,t,r,i,n),null}var en=null,tn=null,nn=null;function rn(){if(nn)return nn;var e,t,n=tn,r=n.length,i="value"in en?en.value:en.textContent,o=i.length;for(e=0;e<r&&n[e]===i[e];e++);var a=r-e;for(t=1;t<=a&&n[r-t]===i[o-t];t++);return nn=i.slice(e,1<t?1-t:void 0)}function on(e){var t=e.keyCode;return"charCode"in e?0===(e=e.charCode)&&13===t&&(e=13):e=t,10===e&&(e=13),32<=e||13===e?e:0}function an(){return!0}function ln(){return!1}function sn(e){function t(t,n,r,i,o){for(var a in this._reactName=t,this._targetInst=r,this.type=n,this.nativeEvent=i,this.target=o,this.currentTarget=null,e)e.hasOwnProperty(a)&&(t=e[a],this[a]=t?t(i):i[a]);return this.isDefaultPrevented=(null!=i.defaultPrevented?i.defaultPrevented:!1===i.returnValue)?an:ln,this.isPropagationStopped=ln,this}return i(t.prototype,{preventDefault:function(){this.defaultPrevented=!0;var e=this.nativeEvent;e&&(e.preventDefault?e.preventDefault():"unknown"!==typeof e.returnValue&&(e.returnValue=!1),this.isDefaultPrevented=an)},stopPropagation:function(){var e=this.nativeEvent;e&&(e.stopPropagation?e.stopPropagation():"unknown"!==typeof e.cancelBubble&&(e.cancelBubble=!0),this.isPropagationStopped=an)},persist:function(){},isPersistent:an}),t}var cn,un,pn,dn={eventPhase:0,bubbles:0,cancelable:0,timeStamp:function(e){return e.timeStamp||Date.now()},defaultPrevented:0,isTrusted:0},fn=sn(dn),hn=i({},dn,{view:0,detail:0}),mn=sn(hn),gn=i({},hn,{screenX:0,screenY:0,clientX:0,clientY:0,pageX:0,pageY:0,ctrlKey:0,shiftKey:0,altKey:0,metaKey:0,getModifierState:En,button:0,buttons:0,relatedTarget:function(e){return void 0===e.relatedTarget?e.fromElement===e.srcElement?e.toElement:e.fromElement:e.relatedTarget},movementX:function(e){return"movementX"in e?e.movementX:(e!==pn&&(pn&&"mousemove"===e.type?(cn=e.screenX-pn.screenX,un=e.screenY-pn.screenY):un=cn=0,pn=e),cn)},movementY:function(e){return"movementY"in e?e.movementY:un}}),bn=sn(gn),vn=sn(i({},gn,{dataTransfer:0})),yn=sn(i({},hn,{relatedTarget:0})),xn=sn(i({},dn,{animationName:0,elapsedTime:0,pseudoElement:0})),wn=i({},dn,{clipboardData:function(e){return"clipboardData"in e?e.clipboardData:window.clipboardData}}),jn=sn(wn),On=sn(i({},dn,{data:0})),kn={Esc:"Escape",Spacebar:" ",Left:"ArrowLeft",Up:"ArrowUp",Right:"ArrowRight",Down:"ArrowDown",Del:"Delete",Win:"OS",Menu:"ContextMenu",Apps:"ContextMenu",Scroll:"ScrollLock",MozPrintableKey:"Unidentified"},_n={8:"Backspace",9:"Tab",12:"Clear",13:"Enter",16:"Shift",17:"Control",18:"Alt",19:"Pause",20:"CapsLock",27:"Escape",32:" ",33:"PageUp",34:"PageDown",35:"End",36:"Home",37:"ArrowLeft",38:"ArrowUp",39:"ArrowRight",40:"ArrowDown",45:"Insert",46:"Delete",112:"F1",113:"F2",114:"F3",115:"F4",116:"F5",117:"F6",118:"F7",119:"F8",120:"F9",121:"F10",122:"F11",123:"F12",144:"NumLock",145:"ScrollLock",224:"Meta"},Sn={Alt:"altKey",Control:"ctrlKey",Meta:"metaKey",Shift:"shiftKey"};function Pn(e){var t=this.nativeEvent;return t.getModifierState?t.getModifierState(e):!!(e=Sn[e])&&!!t[e]}function En(){return Pn}var Cn=i({},hn,{key:function(e){if(e.key){var t=kn[e.key]||e.key;if("Unidentified"!==t)return t}return"keypress"===e.type?13===(e=on(e))?"Enter":String.fromCharCode(e):"keydown"===e.type||"keyup"===e.type?_n[e.keyCode]||"Unidentified":""},code:0,location:0,ctrlKey:0,shiftKey:0,altKey:0,metaKey:0,repeat:0,locale:0,getModifierState:En,charCode:function(e){return"keypress"===e.type?on(e):0},keyCode:function(e){return"keydown"===e.type||"keyup"===e.type?e.keyCode:0},which:function(e){return"keypress"===e.type?on(e):"keydown"===e.type||"keyup"===e.type?e.keyCode:0}}),Nn=sn(Cn),Tn=sn(i({},gn,{pointerId:0,width:0,height:0,pressure:0,tangentialPressure:0,tiltX:0,tiltY:0,twist:0,pointerType:0,isPrimary:0})),In=sn(i({},hn,{touches:0,targetTouches:0,changedTouches:0,altKey:0,metaKey:0,ctrlKey:0,shiftKey:0,getModifierState:En})),Ln=sn(i({},dn,{propertyName:0,elapsedTime:0,pseudoElement:0})),Mn=i({},gn,{deltaX:function(e){return"deltaX"in e?e.deltaX:"wheelDeltaX"in e?-e.wheelDeltaX:0},deltaY:function(e){return"deltaY"in e?e.deltaY:"wheelDeltaY"in e?-e.wheelDeltaY:"wheelDelta"in e?-e.wheelDelta:0},deltaZ:0,deltaMode:0}),Fn=sn(Mn),Dn=[9,13,27,32],zn=p&&"CompositionEvent"in window,Rn=null;p&&"documentMode"in document&&(Rn=document.documentMode);var Un=p&&"TextEvent"in window&&!Rn,An=p&&(!zn||Rn&&8<Rn&&11>=Rn),Bn=String.fromCharCode(32),Hn=!1;function qn(e,t){switch(e){case"keyup":return-1!==Dn.indexOf(t.keyCode);case"keydown":return 229!==t.keyCode;case"keypress":case"mousedown":case"focusout":return!0;default:return!1}}function $n(e){return"object"===typeof(e=e.detail)&&"data"in e?e.data:null}var Wn=!1;var Qn={color:!0,date:!0,datetime:!0,"datetime-local":!0,email:!0,month:!0,number:!0,password:!0,range:!0,search:!0,tel:!0,text:!0,time:!0,url:!0,week:!0};function Vn(e){var t=e&&e.nodeName&&e.nodeName.toLowerCase();return"input"===t?!!Qn[e.type]:"textarea"===t}function Yn(e,t,n,r){Te(r),0<(t=zr(t,"onChange")).length&&(n=new fn("onChange","change",null,n,r),e.push({event:n,listeners:t}))}var Kn=null,Gn=null;function Jn(e){Cr(e,0)}function Xn(e){if(J(ii(e)))return e}function Zn(e,t){if("change"===e)return t}var er=!1;if(p){var tr;if(p){var nr="oninput"in document;if(!nr){var rr=document.createElement("div");rr.setAttribute("oninput","return;"),nr="function"===typeof rr.oninput}tr=nr}else tr=!1;er=tr&&(!document.documentMode||9<document.documentMode)}function ir(){Kn&&(Kn.detachEvent("onpropertychange",or),Gn=Kn=null)}function or(e){if("value"===e.propertyName&&Xn(Gn)){var t=[];if(Yn(t,Gn,e,Se(e)),e=Jn,ze)e(t);else{ze=!0;try{Le(e,t)}finally{ze=!1,Ue()}}}}function ar(e,t,n){"focusin"===e?(ir(),Gn=n,(Kn=t).attachEvent("onpropertychange",or)):"focusout"===e&&ir()}function lr(e){if("selectionchange"===e||"keyup"===e||"keydown"===e)return Xn(Gn)}function sr(e,t){if("click"===e)return Xn(t)}function cr(e,t){if("input"===e||"change"===e)return Xn(t)}var ur="function"===typeof Object.is?Object.is:function(e,t){return e===t&&(0!==e||1/e===1/t)||e!==e&&t!==t},pr=Object.prototype.hasOwnProperty;function dr(e,t){if(ur(e,t))return!0;if("object"!==typeof e||null===e||"object"!==typeof t||null===t)return!1;var n=Object.keys(e),r=Object.keys(t);if(n.length!==r.length)return!1;for(r=0;r<n.length;r++)if(!pr.call(t,n[r])||!ur(e[n[r]],t[n[r]]))return!1;return!0}function fr(e){for(;e&&e.firstChild;)e=e.firstChild;return e}function hr(e,t){var n,r=fr(e);for(e=0;r;){if(3===r.nodeType){if(n=e+r.textContent.length,e<=t&&n>=t)return{node:r,offset:t-e};e=n}e:{for(;r;){if(r.nextSibling){r=r.nextSibling;break e}r=r.parentNode}r=void 0}r=fr(r)}}function mr(e,t){return!(!e||!t)&&(e===t||(!e||3!==e.nodeType)&&(t&&3===t.nodeType?mr(e,t.parentNode):"contains"in e?e.contains(t):!!e.compareDocumentPosition&&!!(16&e.compareDocumentPosition(t))))}function gr(){for(var e=window,t=X();t instanceof e.HTMLIFrameElement;){try{var n="string"===typeof t.contentWindow.location.href}catch(r){n=!1}if(!n)break;t=X((e=t.contentWindow).document)}return t}function br(e){var t=e&&e.nodeName&&e.nodeName.toLowerCase();return t&&("input"===t&&("text"===e.type||"search"===e.type||"tel"===e.type||"url"===e.type||"password"===e.type)||"textarea"===t||"true"===e.contentEditable)}var vr=p&&"documentMode"in document&&11>=document.documentMode,yr=null,xr=null,wr=null,jr=!1;function Or(e,t,n){var r=n.window===n?n.document:9===n.nodeType?n:n.ownerDocument;jr||null==yr||yr!==X(r)||("selectionStart"in(r=yr)&&br(r)?r={start:r.selectionStart,end:r.selectionEnd}:r={anchorNode:(r=(r.ownerDocument&&r.ownerDocument.defaultView||window).getSelection()).anchorNode,anchorOffset:r.anchorOffset,focusNode:r.focusNode,focusOffset:r.focusOffset},wr&&dr(wr,r)||(wr=r,0<(r=zr(xr,"onSelect")).length&&(t=new fn("onSelect","select",null,t,n),e.push({event:t,listeners:r}),t.target=yr)))}Ft("cancel cancel click click close close contextmenu contextMenu copy copy cut cut auxclick auxClick dblclick doubleClick dragend dragEnd dragstart dragStart drop drop focusin focus focusout blur input input invalid invalid keydown keyDown keypress keyPress keyup keyUp mousedown mouseDown mouseup mouseUp paste paste pause pause play play pointercancel pointerCancel pointerdown pointerDown pointerup pointerUp ratechange rateChange reset reset seeked seeked submit submit touchcancel touchCancel touchend touchEnd touchstart touchStart volumechange volumeChange".split(" "),0),Ft("drag drag dragenter dragEnter dragexit dragExit dragleave dragLeave dragover dragOver mousemove mouseMove mouseout mouseOut mouseover mouseOver pointermove pointerMove pointerout pointerOut pointerover pointerOver scroll scroll toggle toggle touchmove touchMove wheel wheel".split(" "),1),Ft(Mt,2);for(var kr="change selectionchange textInput compositionstart compositionend compositionupdate".split(" "),_r=0;_r<kr.length;_r++)Lt.set(kr[_r],0);u("onMouseEnter",["mouseout","mouseover"]),u("onMouseLeave",["mouseout","mouseover"]),u("onPointerEnter",["pointerout","pointerover"]),u("onPointerLeave",["pointerout","pointerover"]),c("onChange","change click focusin focusout input keydown keyup selectionchange".split(" ")),c("onSelect","focusout contextmenu dragend focusin keydown keyup mousedown mouseup selectionchange".split(" ")),c("onBeforeInput",["compositionend","keypress","textInput","paste"]),c("onCompositionEnd","compositionend focusout keydown keypress keyup mousedown".split(" ")),c("onCompositionStart","compositionstart focusout keydown keypress keyup mousedown".split(" ")),c("onCompositionUpdate","compositionupdate focusout keydown keypress keyup mousedown".split(" "));var Sr="abort canplay canplaythrough durationchange emptied encrypted ended error loadeddata loadedmetadata loadstart pause play playing progress ratechange seeked seeking stalled suspend timeupdate volumechange waiting".split(" "),Pr=new Set("cancel close invalid load scroll toggle".split(" ").concat(Sr));function Er(e,t,n){var r=e.type||"unknown-event";e.currentTarget=n,function(e,t,n,r,i,o,l,s,c){if(Ke.apply(this,arguments),$e){if(!$e)throw Error(a(198));var u=We;$e=!1,We=null,Qe||(Qe=!0,Ve=u)}}(r,t,void 0,e),e.currentTarget=null}function Cr(e,t){t=0!==(4&t);for(var n=0;n<e.length;n++){var r=e[n],i=r.event;r=r.listeners;e:{var o=void 0;if(t)for(var a=r.length-1;0<=a;a--){var l=r[a],s=l.instance,c=l.currentTarget;if(l=l.listener,s!==o&&i.isPropagationStopped())break e;Er(i,l,c),o=s}else for(a=0;a<r.length;a++){if(s=(l=r[a]).instance,c=l.currentTarget,l=l.listener,s!==o&&i.isPropagationStopped())break e;Er(i,l,c),o=s}}}if(Qe)throw e=Ve,Qe=!1,Ve=null,e}function Nr(e,t){var n=ai(t),r=e+"__bubble";n.has(r)||(Mr(t,e,2,!1),n.add(r))}var Tr="_reactListening"+Math.random().toString(36).slice(2);function Ir(e){e[Tr]||(e[Tr]=!0,l.forEach((function(t){Pr.has(t)||Lr(t,!1,e,null),Lr(t,!0,e,null)})))}function Lr(e,t,n,r){var i=4<arguments.length&&void 0!==arguments[4]?arguments[4]:0,o=n;if("selectionchange"===e&&9!==n.nodeType&&(o=n.ownerDocument),null!==r&&!t&&Pr.has(e)){if("scroll"!==e)return;i|=2,o=r}var a=ai(o),l=e+"__"+(t?"capture":"bubble");a.has(l)||(t&&(i|=4),Mr(o,e,i,t),a.add(l))}function Mr(e,t,n,r){var i=Lt.get(t);switch(void 0===i?2:i){case 0:i=Gt;break;case 1:i=Jt;break;default:i=Xt}n=i.bind(null,t,n,e),i=void 0,!Be||"touchstart"!==t&&"touchmove"!==t&&"wheel"!==t||(i=!0),r?void 0!==i?e.addEventListener(t,n,{capture:!0,passive:i}):e.addEventListener(t,n,!0):void 0!==i?e.addEventListener(t,n,{passive:i}):e.addEventListener(t,n,!1)}function Fr(e,t,n,r,i){var o=r;if(0===(1&t)&&0===(2&t)&&null!==r)e:for(;;){if(null===r)return;var a=r.tag;if(3===a||4===a){var l=r.stateNode.containerInfo;if(l===i||8===l.nodeType&&l.parentNode===i)break;if(4===a)for(a=r.return;null!==a;){var s=a.tag;if((3===s||4===s)&&((s=a.stateNode.containerInfo)===i||8===s.nodeType&&s.parentNode===i))return;a=a.return}for(;null!==l;){if(null===(a=ni(l)))return;if(5===(s=a.tag)||6===s){r=o=a;continue e}l=l.parentNode}}r=r.return}!function(e,t,n){if(Re)return e(t,n);Re=!0;try{De(e,t,n)}finally{Re=!1,Ue()}}((function(){var r=o,i=Se(n),a=[];e:{var l=It.get(e);if(void 0!==l){var s=fn,c=e;switch(e){case"keypress":if(0===on(n))break e;case"keydown":case"keyup":s=Nn;break;case"focusin":c="focus",s=yn;break;case"focusout":c="blur",s=yn;break;case"beforeblur":case"afterblur":s=yn;break;case"click":if(2===n.button)break e;case"auxclick":case"dblclick":case"mousedown":case"mousemove":case"mouseup":case"mouseout":case"mouseover":case"contextmenu":s=bn;break;case"drag":case"dragend":case"dragenter":case"dragexit":case"dragleave":case"dragover":case"dragstart":case"drop":s=vn;break;case"touchcancel":case"touchend":case"touchmove":case"touchstart":s=In;break;case Et:case Ct:case Nt:s=xn;break;case Tt:s=Ln;break;case"scroll":s=mn;break;case"wheel":s=Fn;break;case"copy":case"cut":case"paste":s=jn;break;case"gotpointercapture":case"lostpointercapture":case"pointercancel":case"pointerdown":case"pointermove":case"pointerout":case"pointerover":case"pointerup":s=Tn}var u=0!==(4&t),p=!u&&"scroll"===e,d=u?null!==l?l+"Capture":null:l;u=[];for(var f,h=r;null!==h;){var m=(f=h).stateNode;if(5===f.tag&&null!==m&&(f=m,null!==d&&(null!=(m=Ae(h,d))&&u.push(Dr(h,m,f)))),p)break;h=h.return}0<u.length&&(l=new s(l,c,null,n,i),a.push({event:l,listeners:u}))}}if(0===(7&t)){if(s="mouseout"===e||"pointerout"===e,(!(l="mouseover"===e||"pointerover"===e)||0!==(16&t)||!(c=n.relatedTarget||n.fromElement)||!ni(c)&&!c[ei])&&(s||l)&&(l=i.window===i?i:(l=i.ownerDocument)?l.defaultView||l.parentWindow:window,s?(s=r,null!==(c=(c=n.relatedTarget||n.toElement)?ni(c):null)&&(c!==(p=Ge(c))||5!==c.tag&&6!==c.tag)&&(c=null)):(s=null,c=r),s!==c)){if(u=bn,m="onMouseLeave",d="onMouseEnter",h="mouse","pointerout"!==e&&"pointerover"!==e||(u=Tn,m="onPointerLeave",d="onPointerEnter",h="pointer"),p=null==s?l:ii(s),f=null==c?l:ii(c),(l=new u(m,h+"leave",s,n,i)).target=p,l.relatedTarget=f,m=null,ni(i)===r&&((u=new u(d,h+"enter",c,n,i)).target=f,u.relatedTarget=p,m=u),p=m,s&&c)e:{for(d=c,h=0,f=u=s;f;f=Rr(f))h++;for(f=0,m=d;m;m=Rr(m))f++;for(;0<h-f;)u=Rr(u),h--;for(;0<f-h;)d=Rr(d),f--;for(;h--;){if(u===d||null!==d&&u===d.alternate)break e;u=Rr(u),d=Rr(d)}u=null}else u=null;null!==s&&Ur(a,l,s,u,!1),null!==c&&null!==p&&Ur(a,p,c,u,!0)}if("select"===(s=(l=r?ii(r):window).nodeName&&l.nodeName.toLowerCase())||"input"===s&&"file"===l.type)var g=Zn;else if(Vn(l))if(er)g=cr;else{g=lr;var b=ar}else(s=l.nodeName)&&"input"===s.toLowerCase()&&("checkbox"===l.type||"radio"===l.type)&&(g=sr);switch(g&&(g=g(e,r))?Yn(a,g,n,i):(b&&b(e,l,r),"focusout"===e&&(b=l._wrapperState)&&b.controlled&&"number"===l.type&&ie(l,"number",l.value)),b=r?ii(r):window,e){case"focusin":(Vn(b)||"true"===b.contentEditable)&&(yr=b,xr=r,wr=null);break;case"focusout":wr=xr=yr=null;break;case"mousedown":jr=!0;break;case"contextmenu":case"mouseup":case"dragend":jr=!1,Or(a,n,i);break;case"selectionchange":if(vr)break;case"keydown":case"keyup":Or(a,n,i)}var v;if(zn)e:{switch(e){case"compositionstart":var y="onCompositionStart";break e;case"compositionend":y="onCompositionEnd";break e;case"compositionupdate":y="onCompositionUpdate";break e}y=void 0}else Wn?qn(e,n)&&(y="onCompositionEnd"):"keydown"===e&&229===n.keyCode&&(y="onCompositionStart");y&&(An&&"ko"!==n.locale&&(Wn||"onCompositionStart"!==y?"onCompositionEnd"===y&&Wn&&(v=rn()):(tn="value"in(en=i)?en.value:en.textContent,Wn=!0)),0<(b=zr(r,y)).length&&(y=new On(y,e,null,n,i),a.push({event:y,listeners:b}),v?y.data=v:null!==(v=$n(n))&&(y.data=v))),(v=Un?function(e,t){switch(e){case"compositionend":return $n(t);case"keypress":return 32!==t.which?null:(Hn=!0,Bn);case"textInput":return(e=t.data)===Bn&&Hn?null:e;default:return null}}(e,n):function(e,t){if(Wn)return"compositionend"===e||!zn&&qn(e,t)?(e=rn(),nn=tn=en=null,Wn=!1,e):null;switch(e){case"paste":default:return null;case"keypress":if(!(t.ctrlKey||t.altKey||t.metaKey)||t.ctrlKey&&t.altKey){if(t.char&&1<t.char.length)return t.char;if(t.which)return String.fromCharCode(t.which)}return null;case"compositionend":return An&&"ko"!==t.locale?null:t.data}}(e,n))&&(0<(r=zr(r,"onBeforeInput")).length&&(i=new On("onBeforeInput","beforeinput",null,n,i),a.push({event:i,listeners:r}),i.data=v))}Cr(a,t)}))}function Dr(e,t,n){return{instance:e,listener:t,currentTarget:n}}function zr(e,t){for(var n=t+"Capture",r=[];null!==e;){var i=e,o=i.stateNode;5===i.tag&&null!==o&&(i=o,null!=(o=Ae(e,n))&&r.unshift(Dr(e,o,i)),null!=(o=Ae(e,t))&&r.push(Dr(e,o,i))),e=e.return}return r}function Rr(e){if(null===e)return null;do{e=e.return}while(e&&5!==e.tag);return e||null}function Ur(e,t,n,r,i){for(var o=t._reactName,a=[];null!==n&&n!==r;){var l=n,s=l.alternate,c=l.stateNode;if(null!==s&&s===r)break;5===l.tag&&null!==c&&(l=c,i?null!=(s=Ae(n,o))&&a.unshift(Dr(n,s,l)):i||null!=(s=Ae(n,o))&&a.push(Dr(n,s,l))),n=n.return}0!==a.length&&e.push({event:t,listeners:a})}function Ar(){}var Br=null,Hr=null;function qr(e,t){switch(e){case"button":case"input":case"select":case"textarea":return!!t.autoFocus}return!1}function $r(e,t){return"textarea"===e||"option"===e||"noscript"===e||"string"===typeof t.children||"number"===typeof t.children||"object"===typeof t.dangerouslySetInnerHTML&&null!==t.dangerouslySetInnerHTML&&null!=t.dangerouslySetInnerHTML.__html}var Wr="function"===typeof setTimeout?setTimeout:void 0,Qr="function"===typeof clearTimeout?clearTimeout:void 0;function Vr(e){1===e.nodeType?e.textContent="":9===e.nodeType&&(null!=(e=e.body)&&(e.textContent=""))}function Yr(e){for(;null!=e;e=e.nextSibling){var t=e.nodeType;if(1===t||3===t)break}return e}function Kr(e){e=e.previousSibling;for(var t=0;e;){if(8===e.nodeType){var n=e.data;if("$"===n||"$!"===n||"$?"===n){if(0===t)return e;t--}else"/$"===n&&t++}e=e.previousSibling}return null}var Gr=0;var Jr=Math.random().toString(36).slice(2),Xr="__reactFiber$"+Jr,Zr="__reactProps$"+Jr,ei="__reactContainer$"+Jr,ti="__reactEvents$"+Jr;function ni(e){var t=e[Xr];if(t)return t;for(var n=e.parentNode;n;){if(t=n[ei]||n[Xr]){if(n=t.alternate,null!==t.child||null!==n&&null!==n.child)for(e=Kr(e);null!==e;){if(n=e[Xr])return n;e=Kr(e)}return t}n=(e=n).parentNode}return null}function ri(e){return!(e=e[Xr]||e[ei])||5!==e.tag&&6!==e.tag&&13!==e.tag&&3!==e.tag?null:e}function ii(e){if(5===e.tag||6===e.tag)return e.stateNode;throw Error(a(33))}function oi(e){return e[Zr]||null}function ai(e){var t=e[ti];return void 0===t&&(t=e[ti]=new Set),t}var li=[],si=-1;function ci(e){return{current:e}}function ui(e){0>si||(e.current=li[si],li[si]=null,si--)}function pi(e,t){si++,li[si]=e.current,e.current=t}var di={},fi=ci(di),hi=ci(!1),mi=di;function gi(e,t){var n=e.type.contextTypes;if(!n)return di;var r=e.stateNode;if(r&&r.__reactInternalMemoizedUnmaskedChildContext===t)return r.__reactInternalMemoizedMaskedChildContext;var i,o={};for(i in n)o[i]=t[i];return r&&((e=e.stateNode).__reactInternalMemoizedUnmaskedChildContext=t,e.__reactInternalMemoizedMaskedChildContext=o),o}function bi(e){return null!==(e=e.childContextTypes)&&void 0!==e}function vi(){ui(hi),ui(fi)}function yi(e,t,n){if(fi.current!==di)throw Error(a(168));pi(fi,t),pi(hi,n)}function xi(e,t,n){var r=e.stateNode;if(e=t.childContextTypes,"function"!==typeof r.getChildContext)return n;for(var o in r=r.getChildContext())if(!(o in e))throw Error(a(108,V(t)||"Unknown",o));return i({},n,r)}function wi(e){return e=(e=e.stateNode)&&e.__reactInternalMemoizedMergedChildContext||di,mi=fi.current,pi(fi,e),pi(hi,hi.current),!0}function ji(e,t,n){var r=e.stateNode;if(!r)throw Error(a(169));n?(e=xi(e,t,mi),r.__reactInternalMemoizedMergedChildContext=e,ui(hi),ui(fi),pi(fi,e)):ui(hi),pi(hi,n)}var Oi=null,ki=null,_i=o.unstable_runWithPriority,Si=o.unstable_scheduleCallback,Pi=o.unstable_cancelCallback,Ei=o.unstable_shouldYield,Ci=o.unstable_requestPaint,Ni=o.unstable_now,Ti=o.unstable_getCurrentPriorityLevel,Ii=o.unstable_ImmediatePriority,Li=o.unstable_UserBlockingPriority,Mi=o.unstable_NormalPriority,Fi=o.unstable_LowPriority,Di=o.unstable_IdlePriority,zi={},Ri=void 0!==Ci?Ci:function(){},Ui=null,Ai=null,Bi=!1,Hi=Ni(),qi=1e4>Hi?Ni:function(){return Ni()-Hi};function $i(){switch(Ti()){case Ii:return 99;case Li:return 98;case Mi:return 97;case Fi:return 96;case Di:return 95;default:throw Error(a(332))}}function Wi(e){switch(e){case 99:return Ii;case 98:return Li;case 97:return Mi;case 96:return Fi;case 95:return Di;default:throw Error(a(332))}}function Qi(e,t){return e=Wi(e),_i(e,t)}function Vi(e,t,n){return e=Wi(e),Si(e,t,n)}function Yi(){if(null!==Ai){var e=Ai;Ai=null,Pi(e)}Ki()}function Ki(){if(!Bi&&null!==Ui){Bi=!0;var e=0;try{var t=Ui;Qi(99,(function(){for(;e<t.length;e++){var n=t[e];do{n=n(!0)}while(null!==n)}})),Ui=null}catch(n){throw null!==Ui&&(Ui=Ui.slice(e+1)),Si(Ii,Yi),n}finally{Bi=!1}}}var Gi=w.ReactCurrentBatchConfig;function Ji(e,t){if(e&&e.defaultProps){for(var n in t=i({},t),e=e.defaultProps)void 0===t[n]&&(t[n]=e[n]);return t}return t}var Xi=ci(null),Zi=null,eo=null,to=null;function no(){to=eo=Zi=null}function ro(e){var t=Xi.current;ui(Xi),e.type._context._currentValue=t}function io(e,t){for(;null!==e;){var n=e.alternate;if((e.childLanes&t)===t){if(null===n||(n.childLanes&t)===t)break;n.childLanes|=t}else e.childLanes|=t,null!==n&&(n.childLanes|=t);e=e.return}}function oo(e,t){Zi=e,to=eo=null,null!==(e=e.dependencies)&&null!==e.firstContext&&(0!==(e.lanes&t)&&(za=!0),e.firstContext=null)}function ao(e,t){if(to!==e&&!1!==t&&0!==t)if("number"===typeof t&&1073741823!==t||(to=e,t=1073741823),t={context:e,observedBits:t,next:null},null===eo){if(null===Zi)throw Error(a(308));eo=t,Zi.dependencies={lanes:0,firstContext:t,responders:null}}else eo=eo.next=t;return e._currentValue}var lo=!1;function so(e){e.updateQueue={baseState:e.memoizedState,firstBaseUpdate:null,lastBaseUpdate:null,shared:{pending:null},effects:null}}function co(e,t){e=e.updateQueue,t.updateQueue===e&&(t.updateQueue={baseState:e.baseState,firstBaseUpdate:e.firstBaseUpdate,lastBaseUpdate:e.lastBaseUpdate,shared:e.shared,effects:e.effects})}function uo(e,t){return{eventTime:e,lane:t,tag:0,payload:null,callback:null,next:null}}function po(e,t){if(null!==(e=e.updateQueue)){var n=(e=e.shared).pending;null===n?t.next=t:(t.next=n.next,n.next=t),e.pending=t}}function fo(e,t){var n=e.updateQueue,r=e.alternate;if(null!==r&&n===(r=r.updateQueue)){var i=null,o=null;if(null!==(n=n.firstBaseUpdate)){do{var a={eventTime:n.eventTime,lane:n.lane,tag:n.tag,payload:n.payload,callback:n.callback,next:null};null===o?i=o=a:o=o.next=a,n=n.next}while(null!==n);null===o?i=o=t:o=o.next=t}else i=o=t;return n={baseState:r.baseState,firstBaseUpdate:i,lastBaseUpdate:o,shared:r.shared,effects:r.effects},void(e.updateQueue=n)}null===(e=n.lastBaseUpdate)?n.firstBaseUpdate=t:e.next=t,n.lastBaseUpdate=t}function ho(e,t,n,r){var o=e.updateQueue;lo=!1;var a=o.firstBaseUpdate,l=o.lastBaseUpdate,s=o.shared.pending;if(null!==s){o.shared.pending=null;var c=s,u=c.next;c.next=null,null===l?a=u:l.next=u,l=c;var p=e.alternate;if(null!==p){var d=(p=p.updateQueue).lastBaseUpdate;d!==l&&(null===d?p.firstBaseUpdate=u:d.next=u,p.lastBaseUpdate=c)}}if(null!==a){for(d=o.baseState,l=0,p=u=c=null;;){s=a.lane;var f=a.eventTime;if((r&s)===s){null!==p&&(p=p.next={eventTime:f,lane:0,tag:a.tag,payload:a.payload,callback:a.callback,next:null});e:{var h=e,m=a;switch(s=t,f=n,m.tag){case 1:if("function"===typeof(h=m.payload)){d=h.call(f,d,s);break e}d=h;break e;case 3:h.flags=-4097&h.flags|64;case 0:if(null===(s="function"===typeof(h=m.payload)?h.call(f,d,s):h)||void 0===s)break e;d=i({},d,s);break e;case 2:lo=!0}}null!==a.callback&&(e.flags|=32,null===(s=o.effects)?o.effects=[a]:s.push(a))}else f={eventTime:f,lane:s,tag:a.tag,payload:a.payload,callback:a.callback,next:null},null===p?(u=p=f,c=d):p=p.next=f,l|=s;if(null===(a=a.next)){if(null===(s=o.shared.pending))break;a=s.next,s.next=null,o.lastBaseUpdate=s,o.shared.pending=null}}null===p&&(c=d),o.baseState=c,o.firstBaseUpdate=u,o.lastBaseUpdate=p,Bl|=l,e.lanes=l,e.memoizedState=d}}function mo(e,t,n){if(e=t.effects,t.effects=null,null!==e)for(t=0;t<e.length;t++){var r=e[t],i=r.callback;if(null!==i){if(r.callback=null,r=n,"function"!==typeof i)throw Error(a(191,i));i.call(r)}}}var go=(new r.Component).refs;function bo(e,t,n,r){n=null===(n=n(r,t=e.memoizedState))||void 0===n?t:i({},t,n),e.memoizedState=n,0===e.lanes&&(e.updateQueue.baseState=n)}var vo={isMounted:function(e){return!!(e=e._reactInternals)&&Ge(e)===e},enqueueSetState:function(e,t,n){e=e._reactInternals;var r=ds(),i=fs(e),o=uo(r,i);o.payload=t,void 0!==n&&null!==n&&(o.callback=n),po(e,o),hs(e,i,r)},enqueueReplaceState:function(e,t,n){e=e._reactInternals;var r=ds(),i=fs(e),o=uo(r,i);o.tag=1,o.payload=t,void 0!==n&&null!==n&&(o.callback=n),po(e,o),hs(e,i,r)},enqueueForceUpdate:function(e,t){e=e._reactInternals;var n=ds(),r=fs(e),i=uo(n,r);i.tag=2,void 0!==t&&null!==t&&(i.callback=t),po(e,i),hs(e,r,n)}};function yo(e,t,n,r,i,o,a){return"function"===typeof(e=e.stateNode).shouldComponentUpdate?e.shouldComponentUpdate(r,o,a):!t.prototype||!t.prototype.isPureReactComponent||(!dr(n,r)||!dr(i,o))}function xo(e,t,n){var r=!1,i=di,o=t.contextType;return"object"===typeof o&&null!==o?o=ao(o):(i=bi(t)?mi:fi.current,o=(r=null!==(r=t.contextTypes)&&void 0!==r)?gi(e,i):di),t=new t(n,o),e.memoizedState=null!==t.state&&void 0!==t.state?t.state:null,t.updater=vo,e.stateNode=t,t._reactInternals=e,r&&((e=e.stateNode).__reactInternalMemoizedUnmaskedChildContext=i,e.__reactInternalMemoizedMaskedChildContext=o),t}function wo(e,t,n,r){e=t.state,"function"===typeof t.componentWillReceiveProps&&t.componentWillReceiveProps(n,r),"function"===typeof t.UNSAFE_componentWillReceiveProps&&t.UNSAFE_componentWillReceiveProps(n,r),t.state!==e&&vo.enqueueReplaceState(t,t.state,null)}function jo(e,t,n,r){var i=e.stateNode;i.props=n,i.state=e.memoizedState,i.refs=go,so(e);var o=t.contextType;"object"===typeof o&&null!==o?i.context=ao(o):(o=bi(t)?mi:fi.current,i.context=gi(e,o)),ho(e,n,i,r),i.state=e.memoizedState,"function"===typeof(o=t.getDerivedStateFromProps)&&(bo(e,t,o,n),i.state=e.memoizedState),"function"===typeof t.getDerivedStateFromProps||"function"===typeof i.getSnapshotBeforeUpdate||"function"!==typeof i.UNSAFE_componentWillMount&&"function"!==typeof i.componentWillMount||(t=i.state,"function"===typeof i.componentWillMount&&i.componentWillMount(),"function"===typeof i.UNSAFE_componentWillMount&&i.UNSAFE_componentWillMount(),t!==i.state&&vo.enqueueReplaceState(i,i.state,null),ho(e,n,i,r),i.state=e.memoizedState),"function"===typeof i.componentDidMount&&(e.flags|=4)}var Oo=Array.isArray;function ko(e,t,n){if(null!==(e=n.ref)&&"function"!==typeof e&&"object"!==typeof e){if(n._owner){if(n=n._owner){if(1!==n.tag)throw Error(a(309));var r=n.stateNode}if(!r)throw Error(a(147,e));var i=""+e;return null!==t&&null!==t.ref&&"function"===typeof t.ref&&t.ref._stringRef===i?t.ref:(t=function(e){var t=r.refs;t===go&&(t=r.refs={}),null===e?delete t[i]:t[i]=e},t._stringRef=i,t)}if("string"!==typeof e)throw Error(a(284));if(!n._owner)throw Error(a(290,e))}return e}function _o(e,t){if("textarea"!==e.type)throw Error(a(31,"[object Object]"===Object.prototype.toString.call(t)?"object with keys {"+Object.keys(t).join(", ")+"}":t))}function So(e){function t(t,n){if(e){var r=t.lastEffect;null!==r?(r.nextEffect=n,t.lastEffect=n):t.firstEffect=t.lastEffect=n,n.nextEffect=null,n.flags=8}}function n(n,r){if(!e)return null;for(;null!==r;)t(n,r),r=r.sibling;return null}function r(e,t){for(e=new Map;null!==t;)null!==t.key?e.set(t.key,t):e.set(t.index,t),t=t.sibling;return e}function i(e,t){return(e=Qs(e,t)).index=0,e.sibling=null,e}function o(t,n,r){return t.index=r,e?null!==(r=t.alternate)?(r=r.index)<n?(t.flags=2,n):r:(t.flags=2,n):n}function l(t){return e&&null===t.alternate&&(t.flags=2),t}function s(e,t,n,r){return null===t||6!==t.tag?((t=Gs(n,e.mode,r)).return=e,t):((t=i(t,n)).return=e,t)}function c(e,t,n,r){return null!==t&&t.elementType===n.type?((r=i(t,n.props)).ref=ko(e,t,n),r.return=e,r):((r=Vs(n.type,n.key,n.props,null,e.mode,r)).ref=ko(e,t,n),r.return=e,r)}function u(e,t,n,r){return null===t||4!==t.tag||t.stateNode.containerInfo!==n.containerInfo||t.stateNode.implementation!==n.implementation?((t=Js(n,e.mode,r)).return=e,t):((t=i(t,n.children||[])).return=e,t)}function p(e,t,n,r,o){return null===t||7!==t.tag?((t=Ys(n,e.mode,r,o)).return=e,t):((t=i(t,n)).return=e,t)}function d(e,t,n){if("string"===typeof t||"number"===typeof t)return(t=Gs(""+t,e.mode,n)).return=e,t;if("object"===typeof t&&null!==t){switch(t.$$typeof){case j:return(n=Vs(t.type,t.key,t.props,null,e.mode,n)).ref=ko(e,null,t),n.return=e,n;case O:return(t=Js(t,e.mode,n)).return=e,t}if(Oo(t)||H(t))return(t=Ys(t,e.mode,n,null)).return=e,t;_o(e,t)}return null}function f(e,t,n,r){var i=null!==t?t.key:null;if("string"===typeof n||"number"===typeof n)return null!==i?null:s(e,t,""+n,r);if("object"===typeof n&&null!==n){switch(n.$$typeof){case j:return n.key===i?n.type===k?p(e,t,n.props.children,r,i):c(e,t,n,r):null;case O:return n.key===i?u(e,t,n,r):null}if(Oo(n)||H(n))return null!==i?null:p(e,t,n,r,null);_o(e,n)}return null}function h(e,t,n,r,i){if("string"===typeof r||"number"===typeof r)return s(t,e=e.get(n)||null,""+r,i);if("object"===typeof r&&null!==r){switch(r.$$typeof){case j:return e=e.get(null===r.key?n:r.key)||null,r.type===k?p(t,e,r.props.children,i,r.key):c(t,e,r,i);case O:return u(t,e=e.get(null===r.key?n:r.key)||null,r,i)}if(Oo(r)||H(r))return p(t,e=e.get(n)||null,r,i,null);_o(t,r)}return null}function m(i,a,l,s){for(var c=null,u=null,p=a,m=a=0,g=null;null!==p&&m<l.length;m++){p.index>m?(g=p,p=null):g=p.sibling;var b=f(i,p,l[m],s);if(null===b){null===p&&(p=g);break}e&&p&&null===b.alternate&&t(i,p),a=o(b,a,m),null===u?c=b:u.sibling=b,u=b,p=g}if(m===l.length)return n(i,p),c;if(null===p){for(;m<l.length;m++)null!==(p=d(i,l[m],s))&&(a=o(p,a,m),null===u?c=p:u.sibling=p,u=p);return c}for(p=r(i,p);m<l.length;m++)null!==(g=h(p,i,m,l[m],s))&&(e&&null!==g.alternate&&p.delete(null===g.key?m:g.key),a=o(g,a,m),null===u?c=g:u.sibling=g,u=g);return e&&p.forEach((function(e){return t(i,e)})),c}function g(i,l,s,c){var u=H(s);if("function"!==typeof u)throw Error(a(150));if(null==(s=u.call(s)))throw Error(a(151));for(var p=u=null,m=l,g=l=0,b=null,v=s.next();null!==m&&!v.done;g++,v=s.next()){m.index>g?(b=m,m=null):b=m.sibling;var y=f(i,m,v.value,c);if(null===y){null===m&&(m=b);break}e&&m&&null===y.alternate&&t(i,m),l=o(y,l,g),null===p?u=y:p.sibling=y,p=y,m=b}if(v.done)return n(i,m),u;if(null===m){for(;!v.done;g++,v=s.next())null!==(v=d(i,v.value,c))&&(l=o(v,l,g),null===p?u=v:p.sibling=v,p=v);return u}for(m=r(i,m);!v.done;g++,v=s.next())null!==(v=h(m,i,g,v.value,c))&&(e&&null!==v.alternate&&m.delete(null===v.key?g:v.key),l=o(v,l,g),null===p?u=v:p.sibling=v,p=v);return e&&m.forEach((function(e){return t(i,e)})),u}return function(e,r,o,s){var c="object"===typeof o&&null!==o&&o.type===k&&null===o.key;c&&(o=o.props.children);var u="object"===typeof o&&null!==o;if(u)switch(o.$$typeof){case j:e:{for(u=o.key,c=r;null!==c;){if(c.key===u){if(7===c.tag){if(o.type===k){n(e,c.sibling),(r=i(c,o.props.children)).return=e,e=r;break e}}else if(c.elementType===o.type){n(e,c.sibling),(r=i(c,o.props)).ref=ko(e,c,o),r.return=e,e=r;break e}n(e,c);break}t(e,c),c=c.sibling}o.type===k?((r=Ys(o.props.children,e.mode,s,o.key)).return=e,e=r):((s=Vs(o.type,o.key,o.props,null,e.mode,s)).ref=ko(e,r,o),s.return=e,e=s)}return l(e);case O:e:{for(c=o.key;null!==r;){if(r.key===c){if(4===r.tag&&r.stateNode.containerInfo===o.containerInfo&&r.stateNode.implementation===o.implementation){n(e,r.sibling),(r=i(r,o.children||[])).return=e,e=r;break e}n(e,r);break}t(e,r),r=r.sibling}(r=Js(o,e.mode,s)).return=e,e=r}return l(e)}if("string"===typeof o||"number"===typeof o)return o=""+o,null!==r&&6===r.tag?(n(e,r.sibling),(r=i(r,o)).return=e,e=r):(n(e,r),(r=Gs(o,e.mode,s)).return=e,e=r),l(e);if(Oo(o))return m(e,r,o,s);if(H(o))return g(e,r,o,s);if(u&&_o(e,o),"undefined"===typeof o&&!c)switch(e.tag){case 1:case 22:case 0:case 11:case 15:throw Error(a(152,V(e.type)||"Component"))}return n(e,r)}}var Po=So(!0),Eo=So(!1),Co={},No=ci(Co),To=ci(Co),Io=ci(Co);function Lo(e){if(e===Co)throw Error(a(174));return e}function Mo(e,t){switch(pi(Io,t),pi(To,e),pi(No,Co),e=t.nodeType){case 9:case 11:t=(t=t.documentElement)?t.namespaceURI:he(null,"");break;default:t=he(t=(e=8===e?t.parentNode:t).namespaceURI||null,e=e.tagName)}ui(No),pi(No,t)}function Fo(){ui(No),ui(To),ui(Io)}function Do(e){Lo(Io.current);var t=Lo(No.current),n=he(t,e.type);t!==n&&(pi(To,e),pi(No,n))}function zo(e){To.current===e&&(ui(No),ui(To))}var Ro=ci(0);function Uo(e){for(var t=e;null!==t;){if(13===t.tag){var n=t.memoizedState;if(null!==n&&(null===(n=n.dehydrated)||"$?"===n.data||"$!"===n.data))return t}else if(19===t.tag&&void 0!==t.memoizedProps.revealOrder){if(0!==(64&t.flags))return t}else if(null!==t.child){t.child.return=t,t=t.child;continue}if(t===e)break;for(;null===t.sibling;){if(null===t.return||t.return===e)return null;t=t.return}t.sibling.return=t.return,t=t.sibling}return null}var Ao=null,Bo=null,Ho=!1;function qo(e,t){var n=$s(5,null,null,0);n.elementType="DELETED",n.type="DELETED",n.stateNode=t,n.return=e,n.flags=8,null!==e.lastEffect?(e.lastEffect.nextEffect=n,e.lastEffect=n):e.firstEffect=e.lastEffect=n}function $o(e,t){switch(e.tag){case 5:var n=e.type;return null!==(t=1!==t.nodeType||n.toLowerCase()!==t.nodeName.toLowerCase()?null:t)&&(e.stateNode=t,!0);case 6:return null!==(t=""===e.pendingProps||3!==t.nodeType?null:t)&&(e.stateNode=t,!0);default:return!1}}function Wo(e){if(Ho){var t=Bo;if(t){var n=t;if(!$o(e,t)){if(!(t=Yr(n.nextSibling))||!$o(e,t))return e.flags=-1025&e.flags|2,Ho=!1,void(Ao=e);qo(Ao,n)}Ao=e,Bo=Yr(t.firstChild)}else e.flags=-1025&e.flags|2,Ho=!1,Ao=e}}function Qo(e){for(e=e.return;null!==e&&5!==e.tag&&3!==e.tag&&13!==e.tag;)e=e.return;Ao=e}function Vo(e){if(e!==Ao)return!1;if(!Ho)return Qo(e),Ho=!0,!1;var t=e.type;if(5!==e.tag||"head"!==t&&"body"!==t&&!$r(t,e.memoizedProps))for(t=Bo;t;)qo(e,t),t=Yr(t.nextSibling);if(Qo(e),13===e.tag){if(!(e=null!==(e=e.memoizedState)?e.dehydrated:null))throw Error(a(317));e:{for(e=e.nextSibling,t=0;e;){if(8===e.nodeType){var n=e.data;if("/$"===n){if(0===t){Bo=Yr(e.nextSibling);break e}t--}else"$"!==n&&"$!"!==n&&"$?"!==n||t++}e=e.nextSibling}Bo=null}}else Bo=Ao?Yr(e.stateNode.nextSibling):null;return!0}function Yo(){Bo=Ao=null,Ho=!1}var Ko=[];function Go(){for(var e=0;e<Ko.length;e++)Ko[e]._workInProgressVersionPrimary=null;Ko.length=0}var Jo=w.ReactCurrentDispatcher,Xo=w.ReactCurrentBatchConfig,Zo=0,ea=null,ta=null,na=null,ra=!1,ia=!1;function oa(){throw Error(a(321))}function aa(e,t){if(null===t)return!1;for(var n=0;n<t.length&&n<e.length;n++)if(!ur(e[n],t[n]))return!1;return!0}function la(e,t,n,r,i,o){if(Zo=o,ea=t,t.memoizedState=null,t.updateQueue=null,t.lanes=0,Jo.current=null===e||null===e.memoizedState?La:Ma,e=n(r,i),ia){o=0;do{if(ia=!1,!(25>o))throw Error(a(301));o+=1,na=ta=null,t.updateQueue=null,Jo.current=Fa,e=n(r,i)}while(ia)}if(Jo.current=Ia,t=null!==ta&&null!==ta.next,Zo=0,na=ta=ea=null,ra=!1,t)throw Error(a(300));return e}function sa(){var e={memoizedState:null,baseState:null,baseQueue:null,queue:null,next:null};return null===na?ea.memoizedState=na=e:na=na.next=e,na}function ca(){if(null===ta){var e=ea.alternate;e=null!==e?e.memoizedState:null}else e=ta.next;var t=null===na?ea.memoizedState:na.next;if(null!==t)na=t,ta=e;else{if(null===e)throw Error(a(310));e={memoizedState:(ta=e).memoizedState,baseState:ta.baseState,baseQueue:ta.baseQueue,queue:ta.queue,next:null},null===na?ea.memoizedState=na=e:na=na.next=e}return na}function ua(e,t){return"function"===typeof t?t(e):t}function pa(e){var t=ca(),n=t.queue;if(null===n)throw Error(a(311));n.lastRenderedReducer=e;var r=ta,i=r.baseQueue,o=n.pending;if(null!==o){if(null!==i){var l=i.next;i.next=o.next,o.next=l}r.baseQueue=i=o,n.pending=null}if(null!==i){i=i.next,r=r.baseState;var s=l=o=null,c=i;do{var u=c.lane;if((Zo&u)===u)null!==s&&(s=s.next={lane:0,action:c.action,eagerReducer:c.eagerReducer,eagerState:c.eagerState,next:null}),r=c.eagerReducer===e?c.eagerState:e(r,c.action);else{var p={lane:u,action:c.action,eagerReducer:c.eagerReducer,eagerState:c.eagerState,next:null};null===s?(l=s=p,o=r):s=s.next=p,ea.lanes|=u,Bl|=u}c=c.next}while(null!==c&&c!==i);null===s?o=r:s.next=l,ur(r,t.memoizedState)||(za=!0),t.memoizedState=r,t.baseState=o,t.baseQueue=s,n.lastRenderedState=r}return[t.memoizedState,n.dispatch]}function da(e){var t=ca(),n=t.queue;if(null===n)throw Error(a(311));n.lastRenderedReducer=e;var r=n.dispatch,i=n.pending,o=t.memoizedState;if(null!==i){n.pending=null;var l=i=i.next;do{o=e(o,l.action),l=l.next}while(l!==i);ur(o,t.memoizedState)||(za=!0),t.memoizedState=o,null===t.baseQueue&&(t.baseState=o),n.lastRenderedState=o}return[o,r]}function fa(e,t,n){var r=t._getVersion;r=r(t._source);var i=t._workInProgressVersionPrimary;if(null!==i?e=i===r:(e=e.mutableReadLanes,(e=(Zo&e)===e)&&(t._workInProgressVersionPrimary=r,Ko.push(t))),e)return n(t._source);throw Ko.push(t),Error(a(350))}function ha(e,t,n,r){var i=Ll;if(null===i)throw Error(a(349));var o=t._getVersion,l=o(t._source),s=Jo.current,c=s.useState((function(){return fa(i,t,n)})),u=c[1],p=c[0];c=na;var d=e.memoizedState,f=d.refs,h=f.getSnapshot,m=d.source;d=d.subscribe;var g=ea;return e.memoizedState={refs:f,source:t,subscribe:r},s.useEffect((function(){f.getSnapshot=n,f.setSnapshot=u;var e=o(t._source);if(!ur(l,e)){e=n(t._source),ur(p,e)||(u(e),e=fs(g),i.mutableReadLanes|=e&i.pendingLanes),e=i.mutableReadLanes,i.entangledLanes|=e;for(var r=i.entanglements,a=e;0<a;){var s=31-$t(a),c=1<<s;r[s]|=e,a&=~c}}}),[n,t,r]),s.useEffect((function(){return r(t._source,(function(){var e=f.getSnapshot,n=f.setSnapshot;try{n(e(t._source));var r=fs(g);i.mutableReadLanes|=r&i.pendingLanes}catch(o){n((function(){throw o}))}}))}),[t,r]),ur(h,n)&&ur(m,t)&&ur(d,r)||((e={pending:null,dispatch:null,lastRenderedReducer:ua,lastRenderedState:p}).dispatch=u=Ta.bind(null,ea,e),c.queue=e,c.baseQueue=null,p=fa(i,t,n),c.memoizedState=c.baseState=p),p}function ma(e,t,n){return ha(ca(),e,t,n)}function ga(e){var t=sa();return"function"===typeof e&&(e=e()),t.memoizedState=t.baseState=e,e=(e=t.queue={pending:null,dispatch:null,lastRenderedReducer:ua,lastRenderedState:e}).dispatch=Ta.bind(null,ea,e),[t.memoizedState,e]}function ba(e,t,n,r){return e={tag:e,create:t,destroy:n,deps:r,next:null},null===(t=ea.updateQueue)?(t={lastEffect:null},ea.updateQueue=t,t.lastEffect=e.next=e):null===(n=t.lastEffect)?t.lastEffect=e.next=e:(r=n.next,n.next=e,e.next=r,t.lastEffect=e),e}function va(e){return e={current:e},sa().memoizedState=e}function ya(){return ca().memoizedState}function xa(e,t,n,r){var i=sa();ea.flags|=e,i.memoizedState=ba(1|t,n,void 0,void 0===r?null:r)}function wa(e,t,n,r){var i=ca();r=void 0===r?null:r;var o=void 0;if(null!==ta){var a=ta.memoizedState;if(o=a.destroy,null!==r&&aa(r,a.deps))return void ba(t,n,o,r)}ea.flags|=e,i.memoizedState=ba(1|t,n,o,r)}function ja(e,t){return xa(516,4,e,t)}function Oa(e,t){return wa(516,4,e,t)}function ka(e,t){return wa(4,2,e,t)}function _a(e,t){return"function"===typeof t?(e=e(),t(e),function(){t(null)}):null!==t&&void 0!==t?(e=e(),t.current=e,function(){t.current=null}):void 0}function Sa(e,t,n){return n=null!==n&&void 0!==n?n.concat([e]):null,wa(4,2,_a.bind(null,t,e),n)}function Pa(){}function Ea(e,t){var n=ca();t=void 0===t?null:t;var r=n.memoizedState;return null!==r&&null!==t&&aa(t,r[1])?r[0]:(n.memoizedState=[e,t],e)}function Ca(e,t){var n=ca();t=void 0===t?null:t;var r=n.memoizedState;return null!==r&&null!==t&&aa(t,r[1])?r[0]:(e=e(),n.memoizedState=[e,t],e)}function Na(e,t){var n=$i();Qi(98>n?98:n,(function(){e(!0)})),Qi(97<n?97:n,(function(){var n=Xo.transition;Xo.transition=1;try{e(!1),t()}finally{Xo.transition=n}}))}function Ta(e,t,n){var r=ds(),i=fs(e),o={lane:i,action:n,eagerReducer:null,eagerState:null,next:null},a=t.pending;if(null===a?o.next=o:(o.next=a.next,a.next=o),t.pending=o,a=e.alternate,e===ea||null!==a&&a===ea)ia=ra=!0;else{if(0===e.lanes&&(null===a||0===a.lanes)&&null!==(a=t.lastRenderedReducer))try{var l=t.lastRenderedState,s=a(l,n);if(o.eagerReducer=a,o.eagerState=s,ur(s,l))return}catch(c){}hs(e,i,r)}}var Ia={readContext:ao,useCallback:oa,useContext:oa,useEffect:oa,useImperativeHandle:oa,useLayoutEffect:oa,useMemo:oa,useReducer:oa,useRef:oa,useState:oa,useDebugValue:oa,useDeferredValue:oa,useTransition:oa,useMutableSource:oa,useOpaqueIdentifier:oa,unstable_isNewReconciler:!1},La={readContext:ao,useCallback:function(e,t){return sa().memoizedState=[e,void 0===t?null:t],e},useContext:ao,useEffect:ja,useImperativeHandle:function(e,t,n){return n=null!==n&&void 0!==n?n.concat([e]):null,xa(4,2,_a.bind(null,t,e),n)},useLayoutEffect:function(e,t){return xa(4,2,e,t)},useMemo:function(e,t){var n=sa();return t=void 0===t?null:t,e=e(),n.memoizedState=[e,t],e},useReducer:function(e,t,n){var r=sa();return t=void 0!==n?n(t):t,r.memoizedState=r.baseState=t,e=(e=r.queue={pending:null,dispatch:null,lastRenderedReducer:e,lastRenderedState:t}).dispatch=Ta.bind(null,ea,e),[r.memoizedState,e]},useRef:va,useState:ga,useDebugValue:Pa,useDeferredValue:function(e){var t=ga(e),n=t[0],r=t[1];return ja((function(){var t=Xo.transition;Xo.transition=1;try{r(e)}finally{Xo.transition=t}}),[e]),n},useTransition:function(){var e=ga(!1),t=e[0];return va(e=Na.bind(null,e[1])),[e,t]},useMutableSource:function(e,t,n){var r=sa();return r.memoizedState={refs:{getSnapshot:t,setSnapshot:null},source:e,subscribe:n},ha(r,e,t,n)},useOpaqueIdentifier:function(){if(Ho){var e=!1,t=function(e){return{$$typeof:F,toString:e,valueOf:e}}((function(){throw e||(e=!0,n("r:"+(Gr++).toString(36))),Error(a(355))})),n=ga(t)[1];return 0===(2&ea.mode)&&(ea.flags|=516,ba(5,(function(){n("r:"+(Gr++).toString(36))}),void 0,null)),t}return ga(t="r:"+(Gr++).toString(36)),t},unstable_isNewReconciler:!1},Ma={readContext:ao,useCallback:Ea,useContext:ao,useEffect:Oa,useImperativeHandle:Sa,useLayoutEffect:ka,useMemo:Ca,useReducer:pa,useRef:ya,useState:function(){return pa(ua)},useDebugValue:Pa,useDeferredValue:function(e){var t=pa(ua),n=t[0],r=t[1];return Oa((function(){var t=Xo.transition;Xo.transition=1;try{r(e)}finally{Xo.transition=t}}),[e]),n},useTransition:function(){var e=pa(ua)[0];return[ya().current,e]},useMutableSource:ma,useOpaqueIdentifier:function(){return pa(ua)[0]},unstable_isNewReconciler:!1},Fa={readContext:ao,useCallback:Ea,useContext:ao,useEffect:Oa,useImperativeHandle:Sa,useLayoutEffect:ka,useMemo:Ca,useReducer:da,useRef:ya,useState:function(){return da(ua)},useDebugValue:Pa,useDeferredValue:function(e){var t=da(ua),n=t[0],r=t[1];return Oa((function(){var t=Xo.transition;Xo.transition=1;try{r(e)}finally{Xo.transition=t}}),[e]),n},useTransition:function(){var e=da(ua)[0];return[ya().current,e]},useMutableSource:ma,useOpaqueIdentifier:function(){return da(ua)[0]},unstable_isNewReconciler:!1},Da=w.ReactCurrentOwner,za=!1;function Ra(e,t,n,r){t.child=null===e?Eo(t,null,n,r):Po(t,e.child,n,r)}function Ua(e,t,n,r,i){n=n.render;var o=t.ref;return oo(t,i),r=la(e,t,n,r,o,i),null===e||za?(t.flags|=1,Ra(e,t,r,i),t.child):(t.updateQueue=e.updateQueue,t.flags&=-517,e.lanes&=~i,ol(e,t,i))}function Aa(e,t,n,r,i,o){if(null===e){var a=n.type;return"function"!==typeof a||Ws(a)||void 0!==a.defaultProps||null!==n.compare||void 0!==n.defaultProps?((e=Vs(n.type,null,r,t,t.mode,o)).ref=t.ref,e.return=t,t.child=e):(t.tag=15,t.type=a,Ba(e,t,a,r,i,o))}return a=e.child,0===(i&o)&&(i=a.memoizedProps,(n=null!==(n=n.compare)?n:dr)(i,r)&&e.ref===t.ref)?ol(e,t,o):(t.flags|=1,(e=Qs(a,r)).ref=t.ref,e.return=t,t.child=e)}function Ba(e,t,n,r,i,o){if(null!==e&&dr(e.memoizedProps,r)&&e.ref===t.ref){if(za=!1,0===(o&i))return t.lanes=e.lanes,ol(e,t,o);0!==(16384&e.flags)&&(za=!0)}return $a(e,t,n,r,o)}function Ha(e,t,n){var r=t.pendingProps,i=r.children,o=null!==e?e.memoizedState:null;if("hidden"===r.mode||"unstable-defer-without-hiding"===r.mode)if(0===(4&t.mode))t.memoizedState={baseLanes:0},js(t,n);else{if(0===(1073741824&n))return e=null!==o?o.baseLanes|n:n,t.lanes=t.childLanes=1073741824,t.memoizedState={baseLanes:e},js(t,e),null;t.memoizedState={baseLanes:0},js(t,null!==o?o.baseLanes:n)}else null!==o?(r=o.baseLanes|n,t.memoizedState=null):r=n,js(t,r);return Ra(e,t,i,n),t.child}function qa(e,t){var n=t.ref;(null===e&&null!==n||null!==e&&e.ref!==n)&&(t.flags|=128)}function $a(e,t,n,r,i){var o=bi(n)?mi:fi.current;return o=gi(t,o),oo(t,i),n=la(e,t,n,r,o,i),null===e||za?(t.flags|=1,Ra(e,t,n,i),t.child):(t.updateQueue=e.updateQueue,t.flags&=-517,e.lanes&=~i,ol(e,t,i))}function Wa(e,t,n,r,i){if(bi(n)){var o=!0;wi(t)}else o=!1;if(oo(t,i),null===t.stateNode)null!==e&&(e.alternate=null,t.alternate=null,t.flags|=2),xo(t,n,r),jo(t,n,r,i),r=!0;else if(null===e){var a=t.stateNode,l=t.memoizedProps;a.props=l;var s=a.context,c=n.contextType;"object"===typeof c&&null!==c?c=ao(c):c=gi(t,c=bi(n)?mi:fi.current);var u=n.getDerivedStateFromProps,p="function"===typeof u||"function"===typeof a.getSnapshotBeforeUpdate;p||"function"!==typeof a.UNSAFE_componentWillReceiveProps&&"function"!==typeof a.componentWillReceiveProps||(l!==r||s!==c)&&wo(t,a,r,c),lo=!1;var d=t.memoizedState;a.state=d,ho(t,r,a,i),s=t.memoizedState,l!==r||d!==s||hi.current||lo?("function"===typeof u&&(bo(t,n,u,r),s=t.memoizedState),(l=lo||yo(t,n,l,r,d,s,c))?(p||"function"!==typeof a.UNSAFE_componentWillMount&&"function"!==typeof a.componentWillMount||("function"===typeof a.componentWillMount&&a.componentWillMount(),"function"===typeof a.UNSAFE_componentWillMount&&a.UNSAFE_componentWillMount()),"function"===typeof a.componentDidMount&&(t.flags|=4)):("function"===typeof a.componentDidMount&&(t.flags|=4),t.memoizedProps=r,t.memoizedState=s),a.props=r,a.state=s,a.context=c,r=l):("function"===typeof a.componentDidMount&&(t.flags|=4),r=!1)}else{a=t.stateNode,co(e,t),l=t.memoizedProps,c=t.type===t.elementType?l:Ji(t.type,l),a.props=c,p=t.pendingProps,d=a.context,"object"===typeof(s=n.contextType)&&null!==s?s=ao(s):s=gi(t,s=bi(n)?mi:fi.current);var f=n.getDerivedStateFromProps;(u="function"===typeof f||"function"===typeof a.getSnapshotBeforeUpdate)||"function"!==typeof a.UNSAFE_componentWillReceiveProps&&"function"!==typeof a.componentWillReceiveProps||(l!==p||d!==s)&&wo(t,a,r,s),lo=!1,d=t.memoizedState,a.state=d,ho(t,r,a,i);var h=t.memoizedState;l!==p||d!==h||hi.current||lo?("function"===typeof f&&(bo(t,n,f,r),h=t.memoizedState),(c=lo||yo(t,n,c,r,d,h,s))?(u||"function"!==typeof a.UNSAFE_componentWillUpdate&&"function"!==typeof a.componentWillUpdate||("function"===typeof a.componentWillUpdate&&a.componentWillUpdate(r,h,s),"function"===typeof a.UNSAFE_componentWillUpdate&&a.UNSAFE_componentWillUpdate(r,h,s)),"function"===typeof a.componentDidUpdate&&(t.flags|=4),"function"===typeof a.getSnapshotBeforeUpdate&&(t.flags|=256)):("function"!==typeof a.componentDidUpdate||l===e.memoizedProps&&d===e.memoizedState||(t.flags|=4),"function"!==typeof a.getSnapshotBeforeUpdate||l===e.memoizedProps&&d===e.memoizedState||(t.flags|=256),t.memoizedProps=r,t.memoizedState=h),a.props=r,a.state=h,a.context=s,r=c):("function"!==typeof a.componentDidUpdate||l===e.memoizedProps&&d===e.memoizedState||(t.flags|=4),"function"!==typeof a.getSnapshotBeforeUpdate||l===e.memoizedProps&&d===e.memoizedState||(t.flags|=256),r=!1)}return Qa(e,t,n,r,o,i)}function Qa(e,t,n,r,i,o){qa(e,t);var a=0!==(64&t.flags);if(!r&&!a)return i&&ji(t,n,!1),ol(e,t,o);r=t.stateNode,Da.current=t;var l=a&&"function"!==typeof n.getDerivedStateFromError?null:r.render();return t.flags|=1,null!==e&&a?(t.child=Po(t,e.child,null,o),t.child=Po(t,null,l,o)):Ra(e,t,l,o),t.memoizedState=r.state,i&&ji(t,n,!0),t.child}function Va(e){var t=e.stateNode;t.pendingContext?yi(0,t.pendingContext,t.pendingContext!==t.context):t.context&&yi(0,t.context,!1),Mo(e,t.containerInfo)}var Ya,Ka,Ga,Ja={dehydrated:null,retryLane:0};function Xa(e,t,n){var r,i=t.pendingProps,o=Ro.current,a=!1;return(r=0!==(64&t.flags))||(r=(null===e||null!==e.memoizedState)&&0!==(2&o)),r?(a=!0,t.flags&=-65):null!==e&&null===e.memoizedState||void 0===i.fallback||!0===i.unstable_avoidThisFallback||(o|=1),pi(Ro,1&o),null===e?(void 0!==i.fallback&&Wo(t),e=i.children,o=i.fallback,a?(e=Za(t,e,o,n),t.child.memoizedState={baseLanes:n},t.memoizedState=Ja,e):"number"===typeof i.unstable_expectedLoadTime?(e=Za(t,e,o,n),t.child.memoizedState={baseLanes:n},t.memoizedState=Ja,t.lanes=33554432,e):((n=Ks({mode:"visible",children:e},t.mode,n,null)).return=t,t.child=n)):(e.memoizedState,a?(i=tl(e,t,i.children,i.fallback,n),a=t.child,o=e.child.memoizedState,a.memoizedState=null===o?{baseLanes:n}:{baseLanes:o.baseLanes|n},a.childLanes=e.childLanes&~n,t.memoizedState=Ja,i):(n=el(e,t,i.children,n),t.memoizedState=null,n))}function Za(e,t,n,r){var i=e.mode,o=e.child;return t={mode:"hidden",children:t},0===(2&i)&&null!==o?(o.childLanes=0,o.pendingProps=t):o=Ks(t,i,0,null),n=Ys(n,i,r,null),o.return=e,n.return=e,o.sibling=n,e.child=o,n}function el(e,t,n,r){var i=e.child;return e=i.sibling,n=Qs(i,{mode:"visible",children:n}),0===(2&t.mode)&&(n.lanes=r),n.return=t,n.sibling=null,null!==e&&(e.nextEffect=null,e.flags=8,t.firstEffect=t.lastEffect=e),t.child=n}function tl(e,t,n,r,i){var o=t.mode,a=e.child;e=a.sibling;var l={mode:"hidden",children:n};return 0===(2&o)&&t.child!==a?((n=t.child).childLanes=0,n.pendingProps=l,null!==(a=n.lastEffect)?(t.firstEffect=n.firstEffect,t.lastEffect=a,a.nextEffect=null):t.firstEffect=t.lastEffect=null):n=Qs(a,l),null!==e?r=Qs(e,r):(r=Ys(r,o,i,null)).flags|=2,r.return=t,n.return=t,n.sibling=r,t.child=n,r}function nl(e,t){e.lanes|=t;var n=e.alternate;null!==n&&(n.lanes|=t),io(e.return,t)}function rl(e,t,n,r,i,o){var a=e.memoizedState;null===a?e.memoizedState={isBackwards:t,rendering:null,renderingStartTime:0,last:r,tail:n,tailMode:i,lastEffect:o}:(a.isBackwards=t,a.rendering=null,a.renderingStartTime=0,a.last=r,a.tail=n,a.tailMode=i,a.lastEffect=o)}function il(e,t,n){var r=t.pendingProps,i=r.revealOrder,o=r.tail;if(Ra(e,t,r.children,n),0!==(2&(r=Ro.current)))r=1&r|2,t.flags|=64;else{if(null!==e&&0!==(64&e.flags))e:for(e=t.child;null!==e;){if(13===e.tag)null!==e.memoizedState&&nl(e,n);else if(19===e.tag)nl(e,n);else if(null!==e.child){e.child.return=e,e=e.child;continue}if(e===t)break e;for(;null===e.sibling;){if(null===e.return||e.return===t)break e;e=e.return}e.sibling.return=e.return,e=e.sibling}r&=1}if(pi(Ro,r),0===(2&t.mode))t.memoizedState=null;else switch(i){case"forwards":for(n=t.child,i=null;null!==n;)null!==(e=n.alternate)&&null===Uo(e)&&(i=n),n=n.sibling;null===(n=i)?(i=t.child,t.child=null):(i=n.sibling,n.sibling=null),rl(t,!1,i,n,o,t.lastEffect);break;case"backwards":for(n=null,i=t.child,t.child=null;null!==i;){if(null!==(e=i.alternate)&&null===Uo(e)){t.child=i;break}e=i.sibling,i.sibling=n,n=i,i=e}rl(t,!0,n,null,o,t.lastEffect);break;case"together":rl(t,!1,null,null,void 0,t.lastEffect);break;default:t.memoizedState=null}return t.child}function ol(e,t,n){if(null!==e&&(t.dependencies=e.dependencies),Bl|=t.lanes,0!==(n&t.childLanes)){if(null!==e&&t.child!==e.child)throw Error(a(153));if(null!==t.child){for(n=Qs(e=t.child,e.pendingProps),t.child=n,n.return=t;null!==e.sibling;)e=e.sibling,(n=n.sibling=Qs(e,e.pendingProps)).return=t;n.sibling=null}return t.child}return null}function al(e,t){if(!Ho)switch(e.tailMode){case"hidden":t=e.tail;for(var n=null;null!==t;)null!==t.alternate&&(n=t),t=t.sibling;null===n?e.tail=null:n.sibling=null;break;case"collapsed":n=e.tail;for(var r=null;null!==n;)null!==n.alternate&&(r=n),n=n.sibling;null===r?t||null===e.tail?e.tail=null:e.tail.sibling=null:r.sibling=null}}function ll(e,t,n){var r=t.pendingProps;switch(t.tag){case 2:case 16:case 15:case 0:case 11:case 7:case 8:case 12:case 9:case 14:return null;case 1:case 17:return bi(t.type)&&vi(),null;case 3:return Fo(),ui(hi),ui(fi),Go(),(r=t.stateNode).pendingContext&&(r.context=r.pendingContext,r.pendingContext=null),null!==e&&null!==e.child||(Vo(t)?t.flags|=4:r.hydrate||(t.flags|=256)),null;case 5:zo(t);var o=Lo(Io.current);if(n=t.type,null!==e&&null!=t.stateNode)Ka(e,t,n,r),e.ref!==t.ref&&(t.flags|=128);else{if(!r){if(null===t.stateNode)throw Error(a(166));return null}if(e=Lo(No.current),Vo(t)){r=t.stateNode,n=t.type;var l=t.memoizedProps;switch(r[Xr]=t,r[Zr]=l,n){case"dialog":Nr("cancel",r),Nr("close",r);break;case"iframe":case"object":case"embed":Nr("load",r);break;case"video":case"audio":for(e=0;e<Sr.length;e++)Nr(Sr[e],r);break;case"source":Nr("error",r);break;case"img":case"image":case"link":Nr("error",r),Nr("load",r);break;case"details":Nr("toggle",r);break;case"input":ee(r,l),Nr("invalid",r);break;case"select":r._wrapperState={wasMultiple:!!l.multiple},Nr("invalid",r);break;case"textarea":se(r,l),Nr("invalid",r)}for(var c in ke(n,l),e=null,l)l.hasOwnProperty(c)&&(o=l[c],"children"===c?"string"===typeof o?r.textContent!==o&&(e=["children",o]):"number"===typeof o&&r.textContent!==""+o&&(e=["children",""+o]):s.hasOwnProperty(c)&&null!=o&&"onScroll"===c&&Nr("scroll",r));switch(n){case"input":G(r),re(r,l,!0);break;case"textarea":G(r),ue(r);break;case"select":case"option":break;default:"function"===typeof l.onClick&&(r.onclick=Ar)}r=e,t.updateQueue=r,null!==r&&(t.flags|=4)}else{switch(c=9===o.nodeType?o:o.ownerDocument,e===pe&&(e=fe(n)),e===pe?"script"===n?((e=c.createElement("div")).innerHTML="<script><\/script>",e=e.removeChild(e.firstChild)):"string"===typeof r.is?e=c.createElement(n,{is:r.is}):(e=c.createElement(n),"select"===n&&(c=e,r.multiple?c.multiple=!0:r.size&&(c.size=r.size))):e=c.createElementNS(e,n),e[Xr]=t,e[Zr]=r,Ya(e,t),t.stateNode=e,c=_e(n,r),n){case"dialog":Nr("cancel",e),Nr("close",e),o=r;break;case"iframe":case"object":case"embed":Nr("load",e),o=r;break;case"video":case"audio":for(o=0;o<Sr.length;o++)Nr(Sr[o],e);o=r;break;case"source":Nr("error",e),o=r;break;case"img":case"image":case"link":Nr("error",e),Nr("load",e),o=r;break;case"details":Nr("toggle",e),o=r;break;case"input":ee(e,r),o=Z(e,r),Nr("invalid",e);break;case"option":o=oe(e,r);break;case"select":e._wrapperState={wasMultiple:!!r.multiple},o=i({},r,{value:void 0}),Nr("invalid",e);break;case"textarea":se(e,r),o=le(e,r),Nr("invalid",e);break;default:o=r}ke(n,o);var u=o;for(l in u)if(u.hasOwnProperty(l)){var p=u[l];"style"===l?je(e,p):"dangerouslySetInnerHTML"===l?null!=(p=p?p.__html:void 0)&&be(e,p):"children"===l?"string"===typeof p?("textarea"!==n||""!==p)&&ve(e,p):"number"===typeof p&&ve(e,""+p):"suppressContentEditableWarning"!==l&&"suppressHydrationWarning"!==l&&"autoFocus"!==l&&(s.hasOwnProperty(l)?null!=p&&"onScroll"===l&&Nr("scroll",e):null!=p&&x(e,l,p,c))}switch(n){case"input":G(e),re(e,r,!1);break;case"textarea":G(e),ue(e);break;case"option":null!=r.value&&e.setAttribute("value",""+Y(r.value));break;case"select":e.multiple=!!r.multiple,null!=(l=r.value)?ae(e,!!r.multiple,l,!1):null!=r.defaultValue&&ae(e,!!r.multiple,r.defaultValue,!0);break;default:"function"===typeof o.onClick&&(e.onclick=Ar)}qr(n,r)&&(t.flags|=4)}null!==t.ref&&(t.flags|=128)}return null;case 6:if(e&&null!=t.stateNode)Ga(0,t,e.memoizedProps,r);else{if("string"!==typeof r&&null===t.stateNode)throw Error(a(166));n=Lo(Io.current),Lo(No.current),Vo(t)?(r=t.stateNode,n=t.memoizedProps,r[Xr]=t,r.nodeValue!==n&&(t.flags|=4)):((r=(9===n.nodeType?n:n.ownerDocument).createTextNode(r))[Xr]=t,t.stateNode=r)}return null;case 13:return ui(Ro),r=t.memoizedState,0!==(64&t.flags)?(t.lanes=n,t):(r=null!==r,n=!1,null===e?void 0!==t.memoizedProps.fallback&&Vo(t):n=null!==e.memoizedState,r&&!n&&0!==(2&t.mode)&&(null===e&&!0!==t.memoizedProps.unstable_avoidThisFallback||0!==(1&Ro.current)?0===Rl&&(Rl=3):(0!==Rl&&3!==Rl||(Rl=4),null===Ll||0===(134217727&Bl)&&0===(134217727&Hl)||vs(Ll,Fl))),(r||n)&&(t.flags|=4),null);case 4:return Fo(),null===e&&Ir(t.stateNode.containerInfo),null;case 10:return ro(t),null;case 19:if(ui(Ro),null===(r=t.memoizedState))return null;if(l=0!==(64&t.flags),null===(c=r.rendering))if(l)al(r,!1);else{if(0!==Rl||null!==e&&0!==(64&e.flags))for(e=t.child;null!==e;){if(null!==(c=Uo(e))){for(t.flags|=64,al(r,!1),null!==(l=c.updateQueue)&&(t.updateQueue=l,t.flags|=4),null===r.lastEffect&&(t.firstEffect=null),t.lastEffect=r.lastEffect,r=n,n=t.child;null!==n;)e=r,(l=n).flags&=2,l.nextEffect=null,l.firstEffect=null,l.lastEffect=null,null===(c=l.alternate)?(l.childLanes=0,l.lanes=e,l.child=null,l.memoizedProps=null,l.memoizedState=null,l.updateQueue=null,l.dependencies=null,l.stateNode=null):(l.childLanes=c.childLanes,l.lanes=c.lanes,l.child=c.child,l.memoizedProps=c.memoizedProps,l.memoizedState=c.memoizedState,l.updateQueue=c.updateQueue,l.type=c.type,e=c.dependencies,l.dependencies=null===e?null:{lanes:e.lanes,firstContext:e.firstContext}),n=n.sibling;return pi(Ro,1&Ro.current|2),t.child}e=e.sibling}null!==r.tail&&qi()>Ql&&(t.flags|=64,l=!0,al(r,!1),t.lanes=33554432)}else{if(!l)if(null!==(e=Uo(c))){if(t.flags|=64,l=!0,null!==(n=e.updateQueue)&&(t.updateQueue=n,t.flags|=4),al(r,!0),null===r.tail&&"hidden"===r.tailMode&&!c.alternate&&!Ho)return null!==(t=t.lastEffect=r.lastEffect)&&(t.nextEffect=null),null}else 2*qi()-r.renderingStartTime>Ql&&1073741824!==n&&(t.flags|=64,l=!0,al(r,!1),t.lanes=33554432);r.isBackwards?(c.sibling=t.child,t.child=c):(null!==(n=r.last)?n.sibling=c:t.child=c,r.last=c)}return null!==r.tail?(n=r.tail,r.rendering=n,r.tail=n.sibling,r.lastEffect=t.lastEffect,r.renderingStartTime=qi(),n.sibling=null,t=Ro.current,pi(Ro,l?1&t|2:1&t),n):null;case 23:case 24:return Os(),null!==e&&null!==e.memoizedState!==(null!==t.memoizedState)&&"unstable-defer-without-hiding"!==r.mode&&(t.flags|=4),null}throw Error(a(156,t.tag))}function sl(e){switch(e.tag){case 1:bi(e.type)&&vi();var t=e.flags;return 4096&t?(e.flags=-4097&t|64,e):null;case 3:if(Fo(),ui(hi),ui(fi),Go(),0!==(64&(t=e.flags)))throw Error(a(285));return e.flags=-4097&t|64,e;case 5:return zo(e),null;case 13:return ui(Ro),4096&(t=e.flags)?(e.flags=-4097&t|64,e):null;case 19:return ui(Ro),null;case 4:return Fo(),null;case 10:return ro(e),null;case 23:case 24:return Os(),null;default:return null}}function cl(e,t){try{var n="",r=t;do{n+=Q(r),r=r.return}while(r);var i=n}catch(o){i="\nError generating stack: "+o.message+"\n"+o.stack}return{value:e,source:t,stack:i}}function ul(e,t){try{console.error(t.value)}catch(n){setTimeout((function(){throw n}))}}Ya=function(e,t){for(var n=t.child;null!==n;){if(5===n.tag||6===n.tag)e.appendChild(n.stateNode);else if(4!==n.tag&&null!==n.child){n.child.return=n,n=n.child;continue}if(n===t)break;for(;null===n.sibling;){if(null===n.return||n.return===t)return;n=n.return}n.sibling.return=n.return,n=n.sibling}},Ka=function(e,t,n,r){var o=e.memoizedProps;if(o!==r){e=t.stateNode,Lo(No.current);var a,l=null;switch(n){case"input":o=Z(e,o),r=Z(e,r),l=[];break;case"option":o=oe(e,o),r=oe(e,r),l=[];break;case"select":o=i({},o,{value:void 0}),r=i({},r,{value:void 0}),l=[];break;case"textarea":o=le(e,o),r=le(e,r),l=[];break;default:"function"!==typeof o.onClick&&"function"===typeof r.onClick&&(e.onclick=Ar)}for(p in ke(n,r),n=null,o)if(!r.hasOwnProperty(p)&&o.hasOwnProperty(p)&&null!=o[p])if("style"===p){var c=o[p];for(a in c)c.hasOwnProperty(a)&&(n||(n={}),n[a]="")}else"dangerouslySetInnerHTML"!==p&&"children"!==p&&"suppressContentEditableWarning"!==p&&"suppressHydrationWarning"!==p&&"autoFocus"!==p&&(s.hasOwnProperty(p)?l||(l=[]):(l=l||[]).push(p,null));for(p in r){var u=r[p];if(c=null!=o?o[p]:void 0,r.hasOwnProperty(p)&&u!==c&&(null!=u||null!=c))if("style"===p)if(c){for(a in c)!c.hasOwnProperty(a)||u&&u.hasOwnProperty(a)||(n||(n={}),n[a]="");for(a in u)u.hasOwnProperty(a)&&c[a]!==u[a]&&(n||(n={}),n[a]=u[a])}else n||(l||(l=[]),l.push(p,n)),n=u;else"dangerouslySetInnerHTML"===p?(u=u?u.__html:void 0,c=c?c.__html:void 0,null!=u&&c!==u&&(l=l||[]).push(p,u)):"children"===p?"string"!==typeof u&&"number"!==typeof u||(l=l||[]).push(p,""+u):"suppressContentEditableWarning"!==p&&"suppressHydrationWarning"!==p&&(s.hasOwnProperty(p)?(null!=u&&"onScroll"===p&&Nr("scroll",e),l||c===u||(l=[])):"object"===typeof u&&null!==u&&u.$$typeof===F?u.toString():(l=l||[]).push(p,u))}n&&(l=l||[]).push("style",n);var p=l;(t.updateQueue=p)&&(t.flags|=4)}},Ga=function(e,t,n,r){n!==r&&(t.flags|=4)};var pl="function"===typeof WeakMap?WeakMap:Map;function dl(e,t,n){(n=uo(-1,n)).tag=3,n.payload={element:null};var r=t.value;return n.callback=function(){Gl||(Gl=!0,Jl=r),ul(0,t)},n}function fl(e,t,n){(n=uo(-1,n)).tag=3;var r=e.type.getDerivedStateFromError;if("function"===typeof r){var i=t.value;n.payload=function(){return ul(0,t),r(i)}}var o=e.stateNode;return null!==o&&"function"===typeof o.componentDidCatch&&(n.callback=function(){"function"!==typeof r&&(null===Xl?Xl=new Set([this]):Xl.add(this),ul(0,t));var e=t.stack;this.componentDidCatch(t.value,{componentStack:null!==e?e:""})}),n}var hl="function"===typeof WeakSet?WeakSet:Set;function ml(e){var t=e.ref;if(null!==t)if("function"===typeof t)try{t(null)}catch(n){As(e,n)}else t.current=null}function gl(e,t){switch(t.tag){case 0:case 11:case 15:case 22:case 5:case 6:case 4:case 17:return;case 1:if(256&t.flags&&null!==e){var n=e.memoizedProps,r=e.memoizedState;t=(e=t.stateNode).getSnapshotBeforeUpdate(t.elementType===t.type?n:Ji(t.type,n),r),e.__reactInternalSnapshotBeforeUpdate=t}return;case 3:return void(256&t.flags&&Vr(t.stateNode.containerInfo))}throw Error(a(163))}function bl(e,t,n){switch(n.tag){case 0:case 11:case 15:case 22:if(null!==(t=null!==(t=n.updateQueue)?t.lastEffect:null)){e=t=t.next;do{if(3===(3&e.tag)){var r=e.create;e.destroy=r()}e=e.next}while(e!==t)}if(null!==(t=null!==(t=n.updateQueue)?t.lastEffect:null)){e=t=t.next;do{var i=e;r=i.next,0!==(4&(i=i.tag))&&0!==(1&i)&&(zs(n,e),Ds(n,e)),e=r}while(e!==t)}return;case 1:return e=n.stateNode,4&n.flags&&(null===t?e.componentDidMount():(r=n.elementType===n.type?t.memoizedProps:Ji(n.type,t.memoizedProps),e.componentDidUpdate(r,t.memoizedState,e.__reactInternalSnapshotBeforeUpdate))),void(null!==(t=n.updateQueue)&&mo(n,t,e));case 3:if(null!==(t=n.updateQueue)){if(e=null,null!==n.child)switch(n.child.tag){case 5:case 1:e=n.child.stateNode}mo(n,t,e)}return;case 5:return e=n.stateNode,void(null===t&&4&n.flags&&qr(n.type,n.memoizedProps)&&e.focus());case 6:case 4:case 12:case 19:case 17:case 20:case 21:case 23:case 24:return;case 13:return void(null===n.memoizedState&&(n=n.alternate,null!==n&&(n=n.memoizedState,null!==n&&(n=n.dehydrated,null!==n&&jt(n)))))}throw Error(a(163))}function vl(e,t){for(var n=e;;){if(5===n.tag){var r=n.stateNode;if(t)"function"===typeof(r=r.style).setProperty?r.setProperty("display","none","important"):r.display="none";else{r=n.stateNode;var i=n.memoizedProps.style;i=void 0!==i&&null!==i&&i.hasOwnProperty("display")?i.display:null,r.style.display=we("display",i)}}else if(6===n.tag)n.stateNode.nodeValue=t?"":n.memoizedProps;else if((23!==n.tag&&24!==n.tag||null===n.memoizedState||n===e)&&null!==n.child){n.child.return=n,n=n.child;continue}if(n===e)break;for(;null===n.sibling;){if(null===n.return||n.return===e)return;n=n.return}n.sibling.return=n.return,n=n.sibling}}function yl(e,t){if(ki&&"function"===typeof ki.onCommitFiberUnmount)try{ki.onCommitFiberUnmount(Oi,t)}catch(o){}switch(t.tag){case 0:case 11:case 14:case 15:case 22:if(null!==(e=t.updateQueue)&&null!==(e=e.lastEffect)){var n=e=e.next;do{var r=n,i=r.destroy;if(r=r.tag,void 0!==i)if(0!==(4&r))zs(t,n);else{r=t;try{i()}catch(o){As(r,o)}}n=n.next}while(n!==e)}break;case 1:if(ml(t),"function"===typeof(e=t.stateNode).componentWillUnmount)try{e.props=t.memoizedProps,e.state=t.memoizedState,e.componentWillUnmount()}catch(o){As(t,o)}break;case 5:ml(t);break;case 4:_l(e,t)}}function xl(e){e.alternate=null,e.child=null,e.dependencies=null,e.firstEffect=null,e.lastEffect=null,e.memoizedProps=null,e.memoizedState=null,e.pendingProps=null,e.return=null,e.updateQueue=null}function wl(e){return 5===e.tag||3===e.tag||4===e.tag}function jl(e){e:{for(var t=e.return;null!==t;){if(wl(t))break e;t=t.return}throw Error(a(160))}var n=t;switch(t=n.stateNode,n.tag){case 5:var r=!1;break;case 3:case 4:t=t.containerInfo,r=!0;break;default:throw Error(a(161))}16&n.flags&&(ve(t,""),n.flags&=-17);e:t:for(n=e;;){for(;null===n.sibling;){if(null===n.return||wl(n.return)){n=null;break e}n=n.return}for(n.sibling.return=n.return,n=n.sibling;5!==n.tag&&6!==n.tag&&18!==n.tag;){if(2&n.flags)continue t;if(null===n.child||4===n.tag)continue t;n.child.return=n,n=n.child}if(!(2&n.flags)){n=n.stateNode;break e}}r?Ol(e,n,t):kl(e,n,t)}function Ol(e,t,n){var r=e.tag,i=5===r||6===r;if(i)e=i?e.stateNode:e.stateNode.instance,t?8===n.nodeType?n.parentNode.insertBefore(e,t):n.insertBefore(e,t):(8===n.nodeType?(t=n.parentNode).insertBefore(e,n):(t=n).appendChild(e),null!==(n=n._reactRootContainer)&&void 0!==n||null!==t.onclick||(t.onclick=Ar));else if(4!==r&&null!==(e=e.child))for(Ol(e,t,n),e=e.sibling;null!==e;)Ol(e,t,n),e=e.sibling}function kl(e,t,n){var r=e.tag,i=5===r||6===r;if(i)e=i?e.stateNode:e.stateNode.instance,t?n.insertBefore(e,t):n.appendChild(e);else if(4!==r&&null!==(e=e.child))for(kl(e,t,n),e=e.sibling;null!==e;)kl(e,t,n),e=e.sibling}function _l(e,t){for(var n,r,i=t,o=!1;;){if(!o){o=i.return;e:for(;;){if(null===o)throw Error(a(160));switch(n=o.stateNode,o.tag){case 5:r=!1;break e;case 3:case 4:n=n.containerInfo,r=!0;break e}o=o.return}o=!0}if(5===i.tag||6===i.tag){e:for(var l=e,s=i,c=s;;)if(yl(l,c),null!==c.child&&4!==c.tag)c.child.return=c,c=c.child;else{if(c===s)break e;for(;null===c.sibling;){if(null===c.return||c.return===s)break e;c=c.return}c.sibling.return=c.return,c=c.sibling}r?(l=n,s=i.stateNode,8===l.nodeType?l.parentNode.removeChild(s):l.removeChild(s)):n.removeChild(i.stateNode)}else if(4===i.tag){if(null!==i.child){n=i.stateNode.containerInfo,r=!0,i.child.return=i,i=i.child;continue}}else if(yl(e,i),null!==i.child){i.child.return=i,i=i.child;continue}if(i===t)break;for(;null===i.sibling;){if(null===i.return||i.return===t)return;4===(i=i.return).tag&&(o=!1)}i.sibling.return=i.return,i=i.sibling}}function Sl(e,t){switch(t.tag){case 0:case 11:case 14:case 15:case 22:var n=t.updateQueue;if(null!==(n=null!==n?n.lastEffect:null)){var r=n=n.next;do{3===(3&r.tag)&&(e=r.destroy,r.destroy=void 0,void 0!==e&&e()),r=r.next}while(r!==n)}return;case 1:case 12:case 17:return;case 5:if(null!=(n=t.stateNode)){r=t.memoizedProps;var i=null!==e?e.memoizedProps:r;e=t.type;var o=t.updateQueue;if(t.updateQueue=null,null!==o){for(n[Zr]=r,"input"===e&&"radio"===r.type&&null!=r.name&&te(n,r),_e(e,i),t=_e(e,r),i=0;i<o.length;i+=2){var l=o[i],s=o[i+1];"style"===l?je(n,s):"dangerouslySetInnerHTML"===l?be(n,s):"children"===l?ve(n,s):x(n,l,s,t)}switch(e){case"input":ne(n,r);break;case"textarea":ce(n,r);break;case"select":e=n._wrapperState.wasMultiple,n._wrapperState.wasMultiple=!!r.multiple,null!=(o=r.value)?ae(n,!!r.multiple,o,!1):e!==!!r.multiple&&(null!=r.defaultValue?ae(n,!!r.multiple,r.defaultValue,!0):ae(n,!!r.multiple,r.multiple?[]:"",!1))}}}return;case 6:if(null===t.stateNode)throw Error(a(162));return void(t.stateNode.nodeValue=t.memoizedProps);case 3:return void((n=t.stateNode).hydrate&&(n.hydrate=!1,jt(n.containerInfo)));case 13:return null!==t.memoizedState&&(Wl=qi(),vl(t.child,!0)),void Pl(t);case 19:return void Pl(t);case 23:case 24:return void vl(t,null!==t.memoizedState)}throw Error(a(163))}function Pl(e){var t=e.updateQueue;if(null!==t){e.updateQueue=null;var n=e.stateNode;null===n&&(n=e.stateNode=new hl),t.forEach((function(t){var r=Hs.bind(null,e,t);n.has(t)||(n.add(t),t.then(r,r))}))}}function El(e,t){return null!==e&&(null===(e=e.memoizedState)||null!==e.dehydrated)&&(null!==(t=t.memoizedState)&&null===t.dehydrated)}var Cl=Math.ceil,Nl=w.ReactCurrentDispatcher,Tl=w.ReactCurrentOwner,Il=0,Ll=null,Ml=null,Fl=0,Dl=0,zl=ci(0),Rl=0,Ul=null,Al=0,Bl=0,Hl=0,ql=0,$l=null,Wl=0,Ql=1/0;function Vl(){Ql=qi()+500}var Yl,Kl=null,Gl=!1,Jl=null,Xl=null,Zl=!1,es=null,ts=90,ns=[],rs=[],is=null,os=0,as=null,ls=-1,ss=0,cs=0,us=null,ps=!1;function ds(){return 0!==(48&Il)?qi():-1!==ls?ls:ls=qi()}function fs(e){if(0===(2&(e=e.mode)))return 1;if(0===(4&e))return 99===$i()?1:2;if(0===ss&&(ss=Al),0!==Gi.transition){0!==cs&&(cs=null!==$l?$l.pendingLanes:0),e=ss;var t=4186112&~cs;return 0===(t&=-t)&&(0===(t=(e=4186112&~e)&-e)&&(t=8192)),t}return e=$i(),0!==(4&Il)&&98===e?e=At(12,ss):e=At(e=function(e){switch(e){case 99:return 15;case 98:return 10;case 97:case 96:return 8;case 95:return 2;default:return 0}}(e),ss),e}function hs(e,t,n){if(50<os)throw os=0,as=null,Error(a(185));if(null===(e=ms(e,t)))return null;qt(e,t,n),e===Ll&&(Hl|=t,4===Rl&&vs(e,Fl));var r=$i();1===t?0!==(8&Il)&&0===(48&Il)?ys(e):(gs(e,n),0===Il&&(Vl(),Yi())):(0===(4&Il)||98!==r&&99!==r||(null===is?is=new Set([e]):is.add(e)),gs(e,n)),$l=e}function ms(e,t){e.lanes|=t;var n=e.alternate;for(null!==n&&(n.lanes|=t),n=e,e=e.return;null!==e;)e.childLanes|=t,null!==(n=e.alternate)&&(n.childLanes|=t),n=e,e=e.return;return 3===n.tag?n.stateNode:null}function gs(e,t){for(var n=e.callbackNode,r=e.suspendedLanes,i=e.pingedLanes,o=e.expirationTimes,l=e.pendingLanes;0<l;){var s=31-$t(l),c=1<<s,u=o[s];if(-1===u){if(0===(c&r)||0!==(c&i)){u=t,zt(c);var p=Dt;o[s]=10<=p?u+250:6<=p?u+5e3:-1}}else u<=t&&(e.expiredLanes|=c);l&=~c}if(r=Rt(e,e===Ll?Fl:0),t=Dt,0===r)null!==n&&(n!==zi&&Pi(n),e.callbackNode=null,e.callbackPriority=0);else{if(null!==n){if(e.callbackPriority===t)return;n!==zi&&Pi(n)}15===t?(n=ys.bind(null,e),null===Ui?(Ui=[n],Ai=Si(Ii,Ki)):Ui.push(n),n=zi):14===t?n=Vi(99,ys.bind(null,e)):(n=function(e){switch(e){case 15:case 14:return 99;case 13:case 12:case 11:case 10:return 98;case 9:case 8:case 7:case 6:case 4:case 5:return 97;case 3:case 2:case 1:return 95;case 0:return 90;default:throw Error(a(358,e))}}(t),n=Vi(n,bs.bind(null,e))),e.callbackPriority=t,e.callbackNode=n}}function bs(e){if(ls=-1,cs=ss=0,0!==(48&Il))throw Error(a(327));var t=e.callbackNode;if(Fs()&&e.callbackNode!==t)return null;var n=Rt(e,e===Ll?Fl:0);if(0===n)return null;var r=n,i=Il;Il|=16;var o=Ss();for(Ll===e&&Fl===r||(Vl(),ks(e,r));;)try{Cs();break}catch(s){_s(e,s)}if(no(),Nl.current=o,Il=i,null!==Ml?r=0:(Ll=null,Fl=0,r=Rl),0!==(Al&Hl))ks(e,0);else if(0!==r){if(2===r&&(Il|=64,e.hydrate&&(e.hydrate=!1,Vr(e.containerInfo)),0!==(n=Ut(e))&&(r=Ps(e,n))),1===r)throw t=Ul,ks(e,0),vs(e,n),gs(e,qi()),t;switch(e.finishedWork=e.current.alternate,e.finishedLanes=n,r){case 0:case 1:throw Error(a(345));case 2:case 5:Is(e);break;case 3:if(vs(e,n),(62914560&n)===n&&10<(r=Wl+500-qi())){if(0!==Rt(e,0))break;if(((i=e.suspendedLanes)&n)!==n){ds(),e.pingedLanes|=e.suspendedLanes&i;break}e.timeoutHandle=Wr(Is.bind(null,e),r);break}Is(e);break;case 4:if(vs(e,n),(4186112&n)===n)break;for(r=e.eventTimes,i=-1;0<n;){var l=31-$t(n);o=1<<l,(l=r[l])>i&&(i=l),n&=~o}if(n=i,10<(n=(120>(n=qi()-n)?120:480>n?480:1080>n?1080:1920>n?1920:3e3>n?3e3:4320>n?4320:1960*Cl(n/1960))-n)){e.timeoutHandle=Wr(Is.bind(null,e),n);break}Is(e);break;default:throw Error(a(329))}}return gs(e,qi()),e.callbackNode===t?bs.bind(null,e):null}function vs(e,t){for(t&=~ql,t&=~Hl,e.suspendedLanes|=t,e.pingedLanes&=~t,e=e.expirationTimes;0<t;){var n=31-$t(t),r=1<<n;e[n]=-1,t&=~r}}function ys(e){if(0!==(48&Il))throw Error(a(327));if(Fs(),e===Ll&&0!==(e.expiredLanes&Fl)){var t=Fl,n=Ps(e,t);0!==(Al&Hl)&&(n=Ps(e,t=Rt(e,t)))}else n=Ps(e,t=Rt(e,0));if(0!==e.tag&&2===n&&(Il|=64,e.hydrate&&(e.hydrate=!1,Vr(e.containerInfo)),0!==(t=Ut(e))&&(n=Ps(e,t))),1===n)throw n=Ul,ks(e,0),vs(e,t),gs(e,qi()),n;return e.finishedWork=e.current.alternate,e.finishedLanes=t,Is(e),gs(e,qi()),null}function xs(e,t){var n=Il;Il|=1;try{return e(t)}finally{0===(Il=n)&&(Vl(),Yi())}}function ws(e,t){var n=Il;Il&=-2,Il|=8;try{return e(t)}finally{0===(Il=n)&&(Vl(),Yi())}}function js(e,t){pi(zl,Dl),Dl|=t,Al|=t}function Os(){Dl=zl.current,ui(zl)}function ks(e,t){e.finishedWork=null,e.finishedLanes=0;var n=e.timeoutHandle;if(-1!==n&&(e.timeoutHandle=-1,Qr(n)),null!==Ml)for(n=Ml.return;null!==n;){var r=n;switch(r.tag){case 1:null!==(r=r.type.childContextTypes)&&void 0!==r&&vi();break;case 3:Fo(),ui(hi),ui(fi),Go();break;case 5:zo(r);break;case 4:Fo();break;case 13:case 19:ui(Ro);break;case 10:ro(r);break;case 23:case 24:Os()}n=n.return}Ll=e,Ml=Qs(e.current,null),Fl=Dl=Al=t,Rl=0,Ul=null,ql=Hl=Bl=0}function _s(e,t){for(;;){var n=Ml;try{if(no(),Jo.current=Ia,ra){for(var r=ea.memoizedState;null!==r;){var i=r.queue;null!==i&&(i.pending=null),r=r.next}ra=!1}if(Zo=0,na=ta=ea=null,ia=!1,Tl.current=null,null===n||null===n.return){Rl=1,Ul=t,Ml=null;break}e:{var o=e,a=n.return,l=n,s=t;if(t=Fl,l.flags|=2048,l.firstEffect=l.lastEffect=null,null!==s&&"object"===typeof s&&"function"===typeof s.then){var c=s;if(0===(2&l.mode)){var u=l.alternate;u?(l.updateQueue=u.updateQueue,l.memoizedState=u.memoizedState,l.lanes=u.lanes):(l.updateQueue=null,l.memoizedState=null)}var p=0!==(1&Ro.current),d=a;do{var f;if(f=13===d.tag){var h=d.memoizedState;if(null!==h)f=null!==h.dehydrated;else{var m=d.memoizedProps;f=void 0!==m.fallback&&(!0!==m.unstable_avoidThisFallback||!p)}}if(f){var g=d.updateQueue;if(null===g){var b=new Set;b.add(c),d.updateQueue=b}else g.add(c);if(0===(2&d.mode)){if(d.flags|=64,l.flags|=16384,l.flags&=-2981,1===l.tag)if(null===l.alternate)l.tag=17;else{var v=uo(-1,1);v.tag=2,po(l,v)}l.lanes|=1;break e}s=void 0,l=t;var y=o.pingCache;if(null===y?(y=o.pingCache=new pl,s=new Set,y.set(c,s)):void 0===(s=y.get(c))&&(s=new Set,y.set(c,s)),!s.has(l)){s.add(l);var x=Bs.bind(null,o,c,l);c.then(x,x)}d.flags|=4096,d.lanes=t;break e}d=d.return}while(null!==d);s=Error((V(l.type)||"A React component")+" suspended while rendering, but no fallback UI was specified.\n\nAdd a <Suspense fallback=...> component higher in the tree to provide a loading indicator or placeholder to display.")}5!==Rl&&(Rl=2),s=cl(s,l),d=a;do{switch(d.tag){case 3:o=s,d.flags|=4096,t&=-t,d.lanes|=t,fo(d,dl(0,o,t));break e;case 1:o=s;var w=d.type,j=d.stateNode;if(0===(64&d.flags)&&("function"===typeof w.getDerivedStateFromError||null!==j&&"function"===typeof j.componentDidCatch&&(null===Xl||!Xl.has(j)))){d.flags|=4096,t&=-t,d.lanes|=t,fo(d,fl(d,o,t));break e}}d=d.return}while(null!==d)}Ts(n)}catch(O){t=O,Ml===n&&null!==n&&(Ml=n=n.return);continue}break}}function Ss(){var e=Nl.current;return Nl.current=Ia,null===e?Ia:e}function Ps(e,t){var n=Il;Il|=16;var r=Ss();for(Ll===e&&Fl===t||ks(e,t);;)try{Es();break}catch(i){_s(e,i)}if(no(),Il=n,Nl.current=r,null!==Ml)throw Error(a(261));return Ll=null,Fl=0,Rl}function Es(){for(;null!==Ml;)Ns(Ml)}function Cs(){for(;null!==Ml&&!Ei();)Ns(Ml)}function Ns(e){var t=Yl(e.alternate,e,Dl);e.memoizedProps=e.pendingProps,null===t?Ts(e):Ml=t,Tl.current=null}function Ts(e){var t=e;do{var n=t.alternate;if(e=t.return,0===(2048&t.flags)){if(null!==(n=ll(n,t,Dl)))return void(Ml=n);if(24!==(n=t).tag&&23!==n.tag||null===n.memoizedState||0!==(1073741824&Dl)||0===(4&n.mode)){for(var r=0,i=n.child;null!==i;)r|=i.lanes|i.childLanes,i=i.sibling;n.childLanes=r}null!==e&&0===(2048&e.flags)&&(null===e.firstEffect&&(e.firstEffect=t.firstEffect),null!==t.lastEffect&&(null!==e.lastEffect&&(e.lastEffect.nextEffect=t.firstEffect),e.lastEffect=t.lastEffect),1<t.flags&&(null!==e.lastEffect?e.lastEffect.nextEffect=t:e.firstEffect=t,e.lastEffect=t))}else{if(null!==(n=sl(t)))return n.flags&=2047,void(Ml=n);null!==e&&(e.firstEffect=e.lastEffect=null,e.flags|=2048)}if(null!==(t=t.sibling))return void(Ml=t);Ml=t=e}while(null!==t);0===Rl&&(Rl=5)}function Is(e){var t=$i();return Qi(99,Ls.bind(null,e,t)),null}function Ls(e,t){do{Fs()}while(null!==es);if(0!==(48&Il))throw Error(a(327));var n=e.finishedWork;if(null===n)return null;if(e.finishedWork=null,e.finishedLanes=0,n===e.current)throw Error(a(177));e.callbackNode=null;var r=n.lanes|n.childLanes,i=r,o=e.pendingLanes&~i;e.pendingLanes=i,e.suspendedLanes=0,e.pingedLanes=0,e.expiredLanes&=i,e.mutableReadLanes&=i,e.entangledLanes&=i,i=e.entanglements;for(var l=e.eventTimes,s=e.expirationTimes;0<o;){var c=31-$t(o),u=1<<c;i[c]=0,l[c]=-1,s[c]=-1,o&=~u}if(null!==is&&0===(24&r)&&is.has(e)&&is.delete(e),e===Ll&&(Ml=Ll=null,Fl=0),1<n.flags?null!==n.lastEffect?(n.lastEffect.nextEffect=n,r=n.firstEffect):r=n:r=n.firstEffect,null!==r){if(i=Il,Il|=32,Tl.current=null,Br=Kt,br(l=gr())){if("selectionStart"in l)s={start:l.selectionStart,end:l.selectionEnd};else e:if(s=(s=l.ownerDocument)&&s.defaultView||window,(u=s.getSelection&&s.getSelection())&&0!==u.rangeCount){s=u.anchorNode,o=u.anchorOffset,c=u.focusNode,u=u.focusOffset;try{s.nodeType,c.nodeType}catch(S){s=null;break e}var p=0,d=-1,f=-1,h=0,m=0,g=l,b=null;t:for(;;){for(var v;g!==s||0!==o&&3!==g.nodeType||(d=p+o),g!==c||0!==u&&3!==g.nodeType||(f=p+u),3===g.nodeType&&(p+=g.nodeValue.length),null!==(v=g.firstChild);)b=g,g=v;for(;;){if(g===l)break t;if(b===s&&++h===o&&(d=p),b===c&&++m===u&&(f=p),null!==(v=g.nextSibling))break;b=(g=b).parentNode}g=v}s=-1===d||-1===f?null:{start:d,end:f}}else s=null;s=s||{start:0,end:0}}else s=null;Hr={focusedElem:l,selectionRange:s},Kt=!1,us=null,ps=!1,Kl=r;do{try{Ms()}catch(S){if(null===Kl)throw Error(a(330));As(Kl,S),Kl=Kl.nextEffect}}while(null!==Kl);us=null,Kl=r;do{try{for(l=e;null!==Kl;){var y=Kl.flags;if(16&y&&ve(Kl.stateNode,""),128&y){var x=Kl.alternate;if(null!==x){var w=x.ref;null!==w&&("function"===typeof w?w(null):w.current=null)}}switch(1038&y){case 2:jl(Kl),Kl.flags&=-3;break;case 6:jl(Kl),Kl.flags&=-3,Sl(Kl.alternate,Kl);break;case 1024:Kl.flags&=-1025;break;case 1028:Kl.flags&=-1025,Sl(Kl.alternate,Kl);break;case 4:Sl(Kl.alternate,Kl);break;case 8:_l(l,s=Kl);var j=s.alternate;xl(s),null!==j&&xl(j)}Kl=Kl.nextEffect}}catch(S){if(null===Kl)throw Error(a(330));As(Kl,S),Kl=Kl.nextEffect}}while(null!==Kl);if(w=Hr,x=gr(),y=w.focusedElem,l=w.selectionRange,x!==y&&y&&y.ownerDocument&&mr(y.ownerDocument.documentElement,y)){null!==l&&br(y)&&(x=l.start,void 0===(w=l.end)&&(w=x),"selectionStart"in y?(y.selectionStart=x,y.selectionEnd=Math.min(w,y.value.length)):(w=(x=y.ownerDocument||document)&&x.defaultView||window).getSelection&&(w=w.getSelection(),s=y.textContent.length,j=Math.min(l.start,s),l=void 0===l.end?j:Math.min(l.end,s),!w.extend&&j>l&&(s=l,l=j,j=s),s=hr(y,j),o=hr(y,l),s&&o&&(1!==w.rangeCount||w.anchorNode!==s.node||w.anchorOffset!==s.offset||w.focusNode!==o.node||w.focusOffset!==o.offset)&&((x=x.createRange()).setStart(s.node,s.offset),w.removeAllRanges(),j>l?(w.addRange(x),w.extend(o.node,o.offset)):(x.setEnd(o.node,o.offset),w.addRange(x))))),x=[];for(w=y;w=w.parentNode;)1===w.nodeType&&x.push({element:w,left:w.scrollLeft,top:w.scrollTop});for("function"===typeof y.focus&&y.focus(),y=0;y<x.length;y++)(w=x[y]).element.scrollLeft=w.left,w.element.scrollTop=w.top}Kt=!!Br,Hr=Br=null,e.current=n,Kl=r;do{try{for(y=e;null!==Kl;){var O=Kl.flags;if(36&O&&bl(y,Kl.alternate,Kl),128&O){x=void 0;var k=Kl.ref;if(null!==k){var _=Kl.stateNode;Kl.tag,x=_,"function"===typeof k?k(x):k.current=x}}Kl=Kl.nextEffect}}catch(S){if(null===Kl)throw Error(a(330));As(Kl,S),Kl=Kl.nextEffect}}while(null!==Kl);Kl=null,Ri(),Il=i}else e.current=n;if(Zl)Zl=!1,es=e,ts=t;else for(Kl=r;null!==Kl;)t=Kl.nextEffect,Kl.nextEffect=null,8&Kl.flags&&((O=Kl).sibling=null,O.stateNode=null),Kl=t;if(0===(r=e.pendingLanes)&&(Xl=null),1===r?e===as?os++:(os=0,as=e):os=0,n=n.stateNode,ki&&"function"===typeof ki.onCommitFiberRoot)try{ki.onCommitFiberRoot(Oi,n,void 0,64===(64&n.current.flags))}catch(S){}if(gs(e,qi()),Gl)throw Gl=!1,e=Jl,Jl=null,e;return 0!==(8&Il)||Yi(),null}function Ms(){for(;null!==Kl;){var e=Kl.alternate;ps||null===us||(0!==(8&Kl.flags)?et(Kl,us)&&(ps=!0):13===Kl.tag&&El(e,Kl)&&et(Kl,us)&&(ps=!0));var t=Kl.flags;0!==(256&t)&&gl(e,Kl),0===(512&t)||Zl||(Zl=!0,Vi(97,(function(){return Fs(),null}))),Kl=Kl.nextEffect}}function Fs(){if(90!==ts){var e=97<ts?97:ts;return ts=90,Qi(e,Rs)}return!1}function Ds(e,t){ns.push(t,e),Zl||(Zl=!0,Vi(97,(function(){return Fs(),null})))}function zs(e,t){rs.push(t,e),Zl||(Zl=!0,Vi(97,(function(){return Fs(),null})))}function Rs(){if(null===es)return!1;var e=es;if(es=null,0!==(48&Il))throw Error(a(331));var t=Il;Il|=32;var n=rs;rs=[];for(var r=0;r<n.length;r+=2){var i=n[r],o=n[r+1],l=i.destroy;if(i.destroy=void 0,"function"===typeof l)try{l()}catch(c){if(null===o)throw Error(a(330));As(o,c)}}for(n=ns,ns=[],r=0;r<n.length;r+=2){i=n[r],o=n[r+1];try{var s=i.create;i.destroy=s()}catch(c){if(null===o)throw Error(a(330));As(o,c)}}for(s=e.current.firstEffect;null!==s;)e=s.nextEffect,s.nextEffect=null,8&s.flags&&(s.sibling=null,s.stateNode=null),s=e;return Il=t,Yi(),!0}function Us(e,t,n){po(e,t=dl(0,t=cl(n,t),1)),t=ds(),null!==(e=ms(e,1))&&(qt(e,1,t),gs(e,t))}function As(e,t){if(3===e.tag)Us(e,e,t);else for(var n=e.return;null!==n;){if(3===n.tag){Us(n,e,t);break}if(1===n.tag){var r=n.stateNode;if("function"===typeof n.type.getDerivedStateFromError||"function"===typeof r.componentDidCatch&&(null===Xl||!Xl.has(r))){var i=fl(n,e=cl(t,e),1);if(po(n,i),i=ds(),null!==(n=ms(n,1)))qt(n,1,i),gs(n,i);else if("function"===typeof r.componentDidCatch&&(null===Xl||!Xl.has(r)))try{r.componentDidCatch(t,e)}catch(o){}break}}n=n.return}}function Bs(e,t,n){var r=e.pingCache;null!==r&&r.delete(t),t=ds(),e.pingedLanes|=e.suspendedLanes&n,Ll===e&&(Fl&n)===n&&(4===Rl||3===Rl&&(62914560&Fl)===Fl&&500>qi()-Wl?ks(e,0):ql|=n),gs(e,t)}function Hs(e,t){var n=e.stateNode;null!==n&&n.delete(t),0===(t=0)&&(0===(2&(t=e.mode))?t=1:0===(4&t)?t=99===$i()?1:2:(0===ss&&(ss=Al),0===(t=Bt(62914560&~ss))&&(t=4194304))),n=ds(),null!==(e=ms(e,t))&&(qt(e,t,n),gs(e,n))}function qs(e,t,n,r){this.tag=e,this.key=n,this.sibling=this.child=this.return=this.stateNode=this.type=this.elementType=null,this.index=0,this.ref=null,this.pendingProps=t,this.dependencies=this.memoizedState=this.updateQueue=this.memoizedProps=null,this.mode=r,this.flags=0,this.lastEffect=this.firstEffect=this.nextEffect=null,this.childLanes=this.lanes=0,this.alternate=null}function $s(e,t,n,r){return new qs(e,t,n,r)}function Ws(e){return!(!(e=e.prototype)||!e.isReactComponent)}function Qs(e,t){var n=e.alternate;return null===n?((n=$s(e.tag,t,e.key,e.mode)).elementType=e.elementType,n.type=e.type,n.stateNode=e.stateNode,n.alternate=e,e.alternate=n):(n.pendingProps=t,n.type=e.type,n.flags=0,n.nextEffect=null,n.firstEffect=null,n.lastEffect=null),n.childLanes=e.childLanes,n.lanes=e.lanes,n.child=e.child,n.memoizedProps=e.memoizedProps,n.memoizedState=e.memoizedState,n.updateQueue=e.updateQueue,t=e.dependencies,n.dependencies=null===t?null:{lanes:t.lanes,firstContext:t.firstContext},n.sibling=e.sibling,n.index=e.index,n.ref=e.ref,n}function Vs(e,t,n,r,i,o){var l=2;if(r=e,"function"===typeof e)Ws(e)&&(l=1);else if("string"===typeof e)l=5;else e:switch(e){case k:return Ys(n.children,i,o,t);case D:l=8,i|=16;break;case _:l=8,i|=1;break;case S:return(e=$s(12,n,t,8|i)).elementType=S,e.type=S,e.lanes=o,e;case N:return(e=$s(13,n,t,i)).type=N,e.elementType=N,e.lanes=o,e;case T:return(e=$s(19,n,t,i)).elementType=T,e.lanes=o,e;case z:return Ks(n,i,o,t);case R:return(e=$s(24,n,t,i)).elementType=R,e.lanes=o,e;default:if("object"===typeof e&&null!==e)switch(e.$$typeof){case P:l=10;break e;case E:l=9;break e;case C:l=11;break e;case I:l=14;break e;case L:l=16,r=null;break e;case M:l=22;break e}throw Error(a(130,null==e?e:typeof e,""))}return(t=$s(l,n,t,i)).elementType=e,t.type=r,t.lanes=o,t}function Ys(e,t,n,r){return(e=$s(7,e,r,t)).lanes=n,e}function Ks(e,t,n,r){return(e=$s(23,e,r,t)).elementType=z,e.lanes=n,e}function Gs(e,t,n){return(e=$s(6,e,null,t)).lanes=n,e}function Js(e,t,n){return(t=$s(4,null!==e.children?e.children:[],e.key,t)).lanes=n,t.stateNode={containerInfo:e.containerInfo,pendingChildren:null,implementation:e.implementation},t}function Xs(e,t,n){this.tag=t,this.containerInfo=e,this.finishedWork=this.pingCache=this.current=this.pendingChildren=null,this.timeoutHandle=-1,this.pendingContext=this.context=null,this.hydrate=n,this.callbackNode=null,this.callbackPriority=0,this.eventTimes=Ht(0),this.expirationTimes=Ht(-1),this.entangledLanes=this.finishedLanes=this.mutableReadLanes=this.expiredLanes=this.pingedLanes=this.suspendedLanes=this.pendingLanes=0,this.entanglements=Ht(0),this.mutableSourceEagerHydrationData=null}function Zs(e,t,n){var r=3<arguments.length&&void 0!==arguments[3]?arguments[3]:null;return{$$typeof:O,key:null==r?null:""+r,children:e,containerInfo:t,implementation:n}}function ec(e,t,n,r){var i=t.current,o=ds(),l=fs(i);e:if(n){t:{if(Ge(n=n._reactInternals)!==n||1!==n.tag)throw Error(a(170));var s=n;do{switch(s.tag){case 3:s=s.stateNode.context;break t;case 1:if(bi(s.type)){s=s.stateNode.__reactInternalMemoizedMergedChildContext;break t}}s=s.return}while(null!==s);throw Error(a(171))}if(1===n.tag){var c=n.type;if(bi(c)){n=xi(n,c,s);break e}}n=s}else n=di;return null===t.context?t.context=n:t.pendingContext=n,(t=uo(o,l)).payload={element:e},null!==(r=void 0===r?null:r)&&(t.callback=r),po(i,t),hs(i,l,o),l}function tc(e){return(e=e.current).child?(e.child.tag,e.child.stateNode):null}function nc(e,t){if(null!==(e=e.memoizedState)&&null!==e.dehydrated){var n=e.retryLane;e.retryLane=0!==n&&n<t?n:t}}function rc(e,t){nc(e,t),(e=e.alternate)&&nc(e,t)}function ic(e,t,n){var r=null!=n&&null!=n.hydrationOptions&&n.hydrationOptions.mutableSources||null;if(n=new Xs(e,t,null!=n&&!0===n.hydrate),t=$s(3,null,null,2===t?7:1===t?3:0),n.current=t,t.stateNode=n,so(t),e[ei]=n.current,Ir(8===e.nodeType?e.parentNode:e),r)for(e=0;e<r.length;e++){var i=(t=r[e])._getVersion;i=i(t._source),null==n.mutableSourceEagerHydrationData?n.mutableSourceEagerHydrationData=[t,i]:n.mutableSourceEagerHydrationData.push(t,i)}this._internalRoot=n}function oc(e){return!(!e||1!==e.nodeType&&9!==e.nodeType&&11!==e.nodeType&&(8!==e.nodeType||" react-mount-point-unstable "!==e.nodeValue))}function ac(e,t,n,r,i){var o=n._reactRootContainer;if(o){var a=o._internalRoot;if("function"===typeof i){var l=i;i=function(){var e=tc(a);l.call(e)}}ec(t,a,e,i)}else{if(o=n._reactRootContainer=function(e,t){if(t||(t=!(!(t=e?9===e.nodeType?e.documentElement:e.firstChild:null)||1!==t.nodeType||!t.hasAttribute("data-reactroot"))),!t)for(var n;n=e.lastChild;)e.removeChild(n);return new ic(e,0,t?{hydrate:!0}:void 0)}(n,r),a=o._internalRoot,"function"===typeof i){var s=i;i=function(){var e=tc(a);s.call(e)}}ws((function(){ec(t,a,e,i)}))}return tc(a)}function lc(e,t){var n=2<arguments.length&&void 0!==arguments[2]?arguments[2]:null;if(!oc(t))throw Error(a(200));return Zs(e,t,null,n)}Yl=function(e,t,n){var r=t.lanes;if(null!==e)if(e.memoizedProps!==t.pendingProps||hi.current)za=!0;else{if(0===(n&r)){switch(za=!1,t.tag){case 3:Va(t),Yo();break;case 5:Do(t);break;case 1:bi(t.type)&&wi(t);break;case 4:Mo(t,t.stateNode.containerInfo);break;case 10:r=t.memoizedProps.value;var i=t.type._context;pi(Xi,i._currentValue),i._currentValue=r;break;case 13:if(null!==t.memoizedState)return 0!==(n&t.child.childLanes)?Xa(e,t,n):(pi(Ro,1&Ro.current),null!==(t=ol(e,t,n))?t.sibling:null);pi(Ro,1&Ro.current);break;case 19:if(r=0!==(n&t.childLanes),0!==(64&e.flags)){if(r)return il(e,t,n);t.flags|=64}if(null!==(i=t.memoizedState)&&(i.rendering=null,i.tail=null,i.lastEffect=null),pi(Ro,Ro.current),r)break;return null;case 23:case 24:return t.lanes=0,Ha(e,t,n)}return ol(e,t,n)}za=0!==(16384&e.flags)}else za=!1;switch(t.lanes=0,t.tag){case 2:if(r=t.type,null!==e&&(e.alternate=null,t.alternate=null,t.flags|=2),e=t.pendingProps,i=gi(t,fi.current),oo(t,n),i=la(null,t,r,e,i,n),t.flags|=1,"object"===typeof i&&null!==i&&"function"===typeof i.render&&void 0===i.$$typeof){if(t.tag=1,t.memoizedState=null,t.updateQueue=null,bi(r)){var o=!0;wi(t)}else o=!1;t.memoizedState=null!==i.state&&void 0!==i.state?i.state:null,so(t);var l=r.getDerivedStateFromProps;"function"===typeof l&&bo(t,r,l,e),i.updater=vo,t.stateNode=i,i._reactInternals=t,jo(t,r,e,n),t=Qa(null,t,r,!0,o,n)}else t.tag=0,Ra(null,t,i,n),t=t.child;return t;case 16:i=t.elementType;e:{switch(null!==e&&(e.alternate=null,t.alternate=null,t.flags|=2),e=t.pendingProps,i=(o=i._init)(i._payload),t.type=i,o=t.tag=function(e){if("function"===typeof e)return Ws(e)?1:0;if(void 0!==e&&null!==e){if((e=e.$$typeof)===C)return 11;if(e===I)return 14}return 2}(i),e=Ji(i,e),o){case 0:t=$a(null,t,i,e,n);break e;case 1:t=Wa(null,t,i,e,n);break e;case 11:t=Ua(null,t,i,e,n);break e;case 14:t=Aa(null,t,i,Ji(i.type,e),r,n);break e}throw Error(a(306,i,""))}return t;case 0:return r=t.type,i=t.pendingProps,$a(e,t,r,i=t.elementType===r?i:Ji(r,i),n);case 1:return r=t.type,i=t.pendingProps,Wa(e,t,r,i=t.elementType===r?i:Ji(r,i),n);case 3:if(Va(t),r=t.updateQueue,null===e||null===r)throw Error(a(282));if(r=t.pendingProps,i=null!==(i=t.memoizedState)?i.element:null,co(e,t),ho(t,r,null,n),(r=t.memoizedState.element)===i)Yo(),t=ol(e,t,n);else{if((o=(i=t.stateNode).hydrate)&&(Bo=Yr(t.stateNode.containerInfo.firstChild),Ao=t,o=Ho=!0),o){if(null!=(e=i.mutableSourceEagerHydrationData))for(i=0;i<e.length;i+=2)(o=e[i])._workInProgressVersionPrimary=e[i+1],Ko.push(o);for(n=Eo(t,null,r,n),t.child=n;n;)n.flags=-3&n.flags|1024,n=n.sibling}else Ra(e,t,r,n),Yo();t=t.child}return t;case 5:return Do(t),null===e&&Wo(t),r=t.type,i=t.pendingProps,o=null!==e?e.memoizedProps:null,l=i.children,$r(r,i)?l=null:null!==o&&$r(r,o)&&(t.flags|=16),qa(e,t),Ra(e,t,l,n),t.child;case 6:return null===e&&Wo(t),null;case 13:return Xa(e,t,n);case 4:return Mo(t,t.stateNode.containerInfo),r=t.pendingProps,null===e?t.child=Po(t,null,r,n):Ra(e,t,r,n),t.child;case 11:return r=t.type,i=t.pendingProps,Ua(e,t,r,i=t.elementType===r?i:Ji(r,i),n);case 7:return Ra(e,t,t.pendingProps,n),t.child;case 8:case 12:return Ra(e,t,t.pendingProps.children,n),t.child;case 10:e:{r=t.type._context,i=t.pendingProps,l=t.memoizedProps,o=i.value;var s=t.type._context;if(pi(Xi,s._currentValue),s._currentValue=o,null!==l)if(s=l.value,0===(o=ur(s,o)?0:0|("function"===typeof r._calculateChangedBits?r._calculateChangedBits(s,o):1073741823))){if(l.children===i.children&&!hi.current){t=ol(e,t,n);break e}}else for(null!==(s=t.child)&&(s.return=t);null!==s;){var c=s.dependencies;if(null!==c){l=s.child;for(var u=c.firstContext;null!==u;){if(u.context===r&&0!==(u.observedBits&o)){1===s.tag&&((u=uo(-1,n&-n)).tag=2,po(s,u)),s.lanes|=n,null!==(u=s.alternate)&&(u.lanes|=n),io(s.return,n),c.lanes|=n;break}u=u.next}}else l=10===s.tag&&s.type===t.type?null:s.child;if(null!==l)l.return=s;else for(l=s;null!==l;){if(l===t){l=null;break}if(null!==(s=l.sibling)){s.return=l.return,l=s;break}l=l.return}s=l}Ra(e,t,i.children,n),t=t.child}return t;case 9:return i=t.type,r=(o=t.pendingProps).children,oo(t,n),r=r(i=ao(i,o.unstable_observedBits)),t.flags|=1,Ra(e,t,r,n),t.child;case 14:return o=Ji(i=t.type,t.pendingProps),Aa(e,t,i,o=Ji(i.type,o),r,n);case 15:return Ba(e,t,t.type,t.pendingProps,r,n);case 17:return r=t.type,i=t.pendingProps,i=t.elementType===r?i:Ji(r,i),null!==e&&(e.alternate=null,t.alternate=null,t.flags|=2),t.tag=1,bi(r)?(e=!0,wi(t)):e=!1,oo(t,n),xo(t,r,i),jo(t,r,i,n),Qa(null,t,r,!0,e,n);case 19:return il(e,t,n);case 23:case 24:return Ha(e,t,n)}throw Error(a(156,t.tag))},ic.prototype.render=function(e){ec(e,this._internalRoot,null,null)},ic.prototype.unmount=function(){var e=this._internalRoot,t=e.containerInfo;ec(null,e,null,(function(){t[ei]=null}))},tt=function(e){13===e.tag&&(hs(e,4,ds()),rc(e,4))},nt=function(e){13===e.tag&&(hs(e,67108864,ds()),rc(e,67108864))},rt=function(e){if(13===e.tag){var t=ds(),n=fs(e);hs(e,n,t),rc(e,n)}},it=function(e,t){return t()},Pe=function(e,t,n){switch(t){case"input":if(ne(e,n),t=n.name,"radio"===n.type&&null!=t){for(n=e;n.parentNode;)n=n.parentNode;for(n=n.querySelectorAll("input[name="+JSON.stringify(""+t)+'][type="radio"]'),t=0;t<n.length;t++){var r=n[t];if(r!==e&&r.form===e.form){var i=oi(r);if(!i)throw Error(a(90));J(r),ne(r,i)}}}break;case"textarea":ce(e,n);break;case"select":null!=(t=n.value)&&ae(e,!!n.multiple,t,!1)}},Le=xs,Me=function(e,t,n,r,i){var o=Il;Il|=4;try{return Qi(98,e.bind(null,t,n,r,i))}finally{0===(Il=o)&&(Vl(),Yi())}},Fe=function(){0===(49&Il)&&(function(){if(null!==is){var e=is;is=null,e.forEach((function(e){e.expiredLanes|=24&e.pendingLanes,gs(e,qi())}))}Yi()}(),Fs())},De=function(e,t){var n=Il;Il|=2;try{return e(t)}finally{0===(Il=n)&&(Vl(),Yi())}};var sc={Events:[ri,ii,oi,Te,Ie,Fs,{current:!1}]},cc={findFiberByHostInstance:ni,bundleType:0,version:"17.0.2",rendererPackageName:"react-dom"},uc={bundleType:cc.bundleType,version:cc.version,rendererPackageName:cc.rendererPackageName,rendererConfig:cc.rendererConfig,overrideHookState:null,overrideHookStateDeletePath:null,overrideHookStateRenamePath:null,overrideProps:null,overridePropsDeletePath:null,overridePropsRenamePath:null,setSuspenseHandler:null,scheduleUpdate:null,currentDispatcherRef:w.ReactCurrentDispatcher,findHostInstanceByFiber:function(e){return null===(e=Ze(e))?null:e.stateNode},findFiberByHostInstance:cc.findFiberByHostInstance||function(){return null},findHostInstancesForRefresh:null,scheduleRefresh:null,scheduleRoot:null,setRefreshHandler:null,getCurrentFiber:null};if("undefined"!==typeof __REACT_DEVTOOLS_GLOBAL_HOOK__){var pc=__REACT_DEVTOOLS_GLOBAL_HOOK__;if(!pc.isDisabled&&pc.supportsFiber)try{Oi=pc.inject(uc),ki=pc}catch(ge){}}t.__SECRET_INTERNALS_DO_NOT_USE_OR_YOU_WILL_BE_FIRED=sc,t.createPortal=lc,t.findDOMNode=function(e){if(null==e)return null;if(1===e.nodeType)return e;var t=e._reactInternals;if(void 0===t){if("function"===typeof e.render)throw Error(a(188));throw Error(a(268,Object.keys(e)))}return e=null===(e=Ze(t))?null:e.stateNode},t.flushSync=function(e,t){var n=Il;if(0!==(48&n))return e(t);Il|=1;try{if(e)return Qi(99,e.bind(null,t))}finally{Il=n,Yi()}},t.hydrate=function(e,t,n){if(!oc(t))throw Error(a(200));return ac(null,e,t,!0,n)},t.render=function(e,t,n){if(!oc(t))throw Error(a(200));return ac(null,e,t,!1,n)},t.unmountComponentAtNode=function(e){if(!oc(e))throw Error(a(40));return!!e._reactRootContainer&&(ws((function(){ac(null,null,e,!1,(function(){e._reactRootContainer=null,e[ei]=null}))})),!0)},t.unstable_batchedUpdates=xs,t.unstable_createPortal=function(e,t){return lc(e,t,2<arguments.length&&void 0!==arguments[2]?arguments[2]:null)},t.unstable_renderSubtreeIntoContainer=function(e,t,n,r){if(!oc(n))throw Error(a(200));if(null==e||void 0===e._reactInternals)throw Error(a(38));return ac(e,t,n,!1,r)},t.version="17.0.2"},function(e,t,n){"use strict";e.exports=n(38)},function(e,t,n){"use strict";var r,i,o,a;if("object"===typeof performance&&"function"===typeof performance.now){var l=performance;t.unstable_now=function(){return l.now()}}else{var s=Date,c=s.now();t.unstable_now=function(){return s.now()-c}}if("undefined"===typeof window||"function"!==typeof MessageChannel){var u=null,p=null,d=function e(){if(null!==u)try{var n=t.unstable_now();u(!0,n),u=null}catch(r){throw setTimeout(e,0),r}};r=function(e){null!==u?setTimeout(r,0,e):(u=e,setTimeout(d,0))},i=function(e,t){p=setTimeout(e,t)},o=function(){clearTimeout(p)},t.unstable_shouldYield=function(){return!1},a=t.unstable_forceFrameRate=function(){}}else{var f=window.setTimeout,h=window.clearTimeout;if("undefined"!==typeof console){var m=window.cancelAnimationFrame;"function"!==typeof window.requestAnimationFrame&&console.error("This browser doesn't support requestAnimationFrame. Make sure that you load a polyfill in older browsers. https://reactjs.org/link/react-polyfills"),"function"!==typeof m&&console.error("This browser doesn't support cancelAnimationFrame. Make sure that you load a polyfill in older browsers. https://reactjs.org/link/react-polyfills")}var g=!1,b=null,v=-1,y=5,x=0;t.unstable_shouldYield=function(){return t.unstable_now()>=x},a=function(){},t.unstable_forceFrameRate=function(e){0>e||125<e?console.error("forceFrameRate takes a positive int between 0 and 125, forcing frame rates higher than 125 fps is not supported"):y=0<e?Math.floor(1e3/e):5};var w=new MessageChannel,j=w.port2;w.port1.onmessage=function(){if(null!==b){var e=t.unstable_now();x=e+y;try{b(!0,e)?j.postMessage(null):(g=!1,b=null)}catch(n){throw j.postMessage(null),n}}else g=!1},r=function(e){b=e,g||(g=!0,j.postMessage(null))},i=function(e,n){v=f((function(){e(t.unstable_now())}),n)},o=function(){h(v),v=-1}}function O(e,t){var n=e.length;e.push(t);e:for(;;){var r=n-1>>>1,i=e[r];if(!(void 0!==i&&0<S(i,t)))break e;e[r]=t,e[n]=i,n=r}}function k(e){return void 0===(e=e[0])?null:e}function _(e){var t=e[0];if(void 0!==t){var n=e.pop();if(n!==t){e[0]=n;e:for(var r=0,i=e.length;r<i;){var o=2*(r+1)-1,a=e[o],l=o+1,s=e[l];if(void 0!==a&&0>S(a,n))void 0!==s&&0>S(s,a)?(e[r]=s,e[l]=n,r=l):(e[r]=a,e[o]=n,r=o);else{if(!(void 0!==s&&0>S(s,n)))break e;e[r]=s,e[l]=n,r=l}}}return t}return null}function S(e,t){var n=e.sortIndex-t.sortIndex;return 0!==n?n:e.id-t.id}var P=[],E=[],C=1,N=null,T=3,I=!1,L=!1,M=!1;function F(e){for(var t=k(E);null!==t;){if(null===t.callback)_(E);else{if(!(t.startTime<=e))break;_(E),t.sortIndex=t.expirationTime,O(P,t)}t=k(E)}}function D(e){if(M=!1,F(e),!L)if(null!==k(P))L=!0,r(z);else{var t=k(E);null!==t&&i(D,t.startTime-e)}}function z(e,n){L=!1,M&&(M=!1,o()),I=!0;var r=T;try{for(F(n),N=k(P);null!==N&&(!(N.expirationTime>n)||e&&!t.unstable_shouldYield());){var a=N.callback;if("function"===typeof a){N.callback=null,T=N.priorityLevel;var l=a(N.expirationTime<=n);n=t.unstable_now(),"function"===typeof l?N.callback=l:N===k(P)&&_(P),F(n)}else _(P);N=k(P)}if(null!==N)var s=!0;else{var c=k(E);null!==c&&i(D,c.startTime-n),s=!1}return s}finally{N=null,T=r,I=!1}}var R=a;t.unstable_IdlePriority=5,t.unstable_ImmediatePriority=1,t.unstable_LowPriority=4,t.unstable_NormalPriority=3,t.unstable_Profiling=null,t.unstable_UserBlockingPriority=2,t.unstable_cancelCallback=function(e){e.callback=null},t.unstable_continueExecution=function(){L||I||(L=!0,r(z))},t.unstable_getCurrentPriorityLevel=function(){return T},t.unstable_getFirstCallbackNode=function(){return k(P)},t.unstable_next=function(e){switch(T){case 1:case 2:case 3:var t=3;break;default:t=T}var n=T;T=t;try{return e()}finally{T=n}},t.unstable_pauseExecution=function(){},t.unstable_requestPaint=R,t.unstable_runWithPriority=function(e,t){switch(e){case 1:case 2:case 3:case 4:case 5:break;default:e=3}var n=T;T=e;try{return t()}finally{T=n}},t.unstable_scheduleCallback=function(e,n,a){var l=t.unstable_now();switch("object"===typeof a&&null!==a?a="number"===typeof(a=a.delay)&&0<a?l+a:l:a=l,e){case 1:var s=-1;break;case 2:s=250;break;case 5:s=1073741823;break;case 4:s=1e4;break;default:s=5e3}return e={id:C++,callback:n,priorityLevel:e,startTime:a,expirationTime:s=a+s,sortIndex:-1},a>l?(e.sortIndex=a,O(E,e),null===k(P)&&e===k(E)&&(M?o():M=!0,i(D,a-l))):(e.sortIndex=s,O(P,e),L||I||(L=!0,r(z))),e},t.unstable_wrapCallback=function(e){var t=T;return function(){var n=T;T=t;try{return e.apply(this,arguments)}finally{T=n}}}},function(e,t,n){var r=n(24),i=n(40);"string"===typeof(i=i.__esModule?i.default:i)&&(i=[[e.i,i,""]]);var o={insert:"head",singleton:!1};r(i,o);e.exports=i.locals||{}},function(e,t,n){"use strict";n.r(t);var r=n(20),i=n.n(r)()(!0);i.push([e.i,"","",{version:3,sources:[],names:[],mappings:"",sourceRoot:""}]),t.default=i},function(e,t,n){var r=function(e){"use strict";var t,n=Object.prototype,r=n.hasOwnProperty,i="function"===typeof Symbol?Symbol:{},o=i.iterator||"@@iterator",a=i.asyncIterator||"@@asyncIterator",l=i.toStringTag||"@@toStringTag";function s(e,t,n){return Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}),e[t]}try{s({},"")}catch(T){s=function(e,t,n){return e[t]=n}}function c(e,t,n,r){var i=t&&t.prototype instanceof g?t:g,o=Object.create(i.prototype),a=new E(r||[]);return o._invoke=function(e,t,n){var r=p;return function(i,o){if(r===f)throw new Error("Generator is already running");if(r===h){if("throw"===i)throw o;return N()}for(n.method=i,n.arg=o;;){var a=n.delegate;if(a){var l=_(a,n);if(l){if(l===m)continue;return l}}if("next"===n.method)n.sent=n._sent=n.arg;else if("throw"===n.method){if(r===p)throw r=h,n.arg;n.dispatchException(n.arg)}else"return"===n.method&&n.abrupt("return",n.arg);r=f;var s=u(e,t,n);if("normal"===s.type){if(r=n.done?h:d,s.arg===m)continue;return{value:s.arg,done:n.done}}"throw"===s.type&&(r=h,n.method="throw",n.arg=s.arg)}}}(e,n,a),o}function u(e,t,n){try{return{type:"normal",arg:e.call(t,n)}}catch(T){return{type:"throw",arg:T}}}e.wrap=c;var p="suspendedStart",d="suspendedYield",f="executing",h="completed",m={};function g(){}function b(){}function v(){}var y={};s(y,o,(function(){return this}));var x=Object.getPrototypeOf,w=x&&x(x(C([])));w&&w!==n&&r.call(w,o)&&(y=w);var j=v.prototype=g.prototype=Object.create(y);function O(e){["next","throw","return"].forEach((function(t){s(e,t,(function(e){return this._invoke(t,e)}))}))}function k(e,t){function n(i,o,a,l){var s=u(e[i],e,o);if("throw"!==s.type){var c=s.arg,p=c.value;return p&&"object"===typeof p&&r.call(p,"__await")?t.resolve(p.__await).then((function(e){n("next",e,a,l)}),(function(e){n("throw",e,a,l)})):t.resolve(p).then((function(e){c.value=e,a(c)}),(function(e){return n("throw",e,a,l)}))}l(s.arg)}var i;this._invoke=function(e,r){function o(){return new t((function(t,i){n(e,r,t,i)}))}return i=i?i.then(o,o):o()}}function _(e,n){var r=e.iterator[n.method];if(r===t){if(n.delegate=null,"throw"===n.method){if(e.iterator.return&&(n.method="return",n.arg=t,_(e,n),"throw"===n.method))return m;n.method="throw",n.arg=new TypeError("The iterator does not provide a 'throw' method")}return m}var i=u(r,e.iterator,n.arg);if("throw"===i.type)return n.method="throw",n.arg=i.arg,n.delegate=null,m;var o=i.arg;return o?o.done?(n[e.resultName]=o.value,n.next=e.nextLoc,"return"!==n.method&&(n.method="next",n.arg=t),n.delegate=null,m):o:(n.method="throw",n.arg=new TypeError("iterator result is not an object"),n.delegate=null,m)}function S(e){var t={tryLoc:e[0]};1 in e&&(t.catchLoc=e[1]),2 in e&&(t.finallyLoc=e[2],t.afterLoc=e[3]),this.tryEntries.push(t)}function P(e){var t=e.completion||{};t.type="normal",delete t.arg,e.completion=t}function E(e){this.tryEntries=[{tryLoc:"root"}],e.forEach(S,this),this.reset(!0)}function C(e){if(e){var n=e[o];if(n)return n.call(e);if("function"===typeof e.next)return e;if(!isNaN(e.length)){var i=-1,a=function n(){for(;++i<e.length;)if(r.call(e,i))return n.value=e[i],n.done=!1,n;return n.value=t,n.done=!0,n};return a.next=a}}return{next:N}}function N(){return{value:t,done:!0}}return b.prototype=v,s(j,"constructor",v),s(v,"constructor",b),b.displayName=s(v,l,"GeneratorFunction"),e.isGeneratorFunction=function(e){var t="function"===typeof e&&e.constructor;return!!t&&(t===b||"GeneratorFunction"===(t.displayName||t.name))},e.mark=function(e){return Object.setPrototypeOf?Object.setPrototypeOf(e,v):(e.__proto__=v,s(e,l,"GeneratorFunction")),e.prototype=Object.create(j),e},e.awrap=function(e){return{__await:e}},O(k.prototype),s(k.prototype,a,(function(){return this})),e.AsyncIterator=k,e.async=function(t,n,r,i,o){void 0===o&&(o=Promise);var a=new k(c(t,n,r,i),o);return e.isGeneratorFunction(n)?a:a.next().then((function(e){return e.done?e.value:a.next()}))},O(j),s(j,l,"Generator"),s(j,o,(function(){return this})),s(j,"toString",(function(){return"[object Generator]"})),e.keys=function(e){var t=[];for(var n in e)t.push(n);return t.reverse(),function n(){for(;t.length;){var r=t.pop();if(r in e)return n.value=r,n.done=!1,n}return n.done=!0,n}},e.values=C,E.prototype={constructor:E,reset:function(e){if(this.prev=0,this.next=0,this.sent=this._sent=t,this.done=!1,this.delegate=null,this.method="next",this.arg=t,this.tryEntries.forEach(P),!e)for(var n in this)"t"===n.charAt(0)&&r.call(this,n)&&!isNaN(+n.slice(1))&&(this[n]=t)},stop:function(){this.done=!0;var e=this.tryEntries[0].completion;if("throw"===e.type)throw e.arg;return this.rval},dispatchException:function(e){if(this.done)throw e;var n=this;function i(r,i){return l.type="throw",l.arg=e,n.next=r,i&&(n.method="next",n.arg=t),!!i}for(var o=this.tryEntries.length-1;o>=0;--o){var a=this.tryEntries[o],l=a.completion;if("root"===a.tryLoc)return i("end");if(a.tryLoc<=this.prev){var s=r.call(a,"catchLoc"),c=r.call(a,"finallyLoc");if(s&&c){if(this.prev<a.catchLoc)return i(a.catchLoc,!0);if(this.prev<a.finallyLoc)return i(a.finallyLoc)}else if(s){if(this.prev<a.catchLoc)return i(a.catchLoc,!0)}else{if(!c)throw new Error("try statement without catch or finally");if(this.prev<a.finallyLoc)return i(a.finallyLoc)}}}},abrupt:function(e,t){for(var n=this.tryEntries.length-1;n>=0;--n){var i=this.tryEntries[n];if(i.tryLoc<=this.prev&&r.call(i,"finallyLoc")&&this.prev<i.finallyLoc){var o=i;break}}o&&("break"===e||"continue"===e)&&o.tryLoc<=t&&t<=o.finallyLoc&&(o=null);var a=o?o.completion:{};return a.type=e,a.arg=t,o?(this.method="next",this.next=o.finallyLoc,m):this.complete(a)},complete:function(e,t){if("throw"===e.type)throw e.arg;return"break"===e.type||"continue"===e.type?this.next=e.arg:"return"===e.type?(this.rval=this.arg=e.arg,this.method="return",this.next="end"):"normal"===e.type&&t&&(this.next=t),m},finish:function(e){for(var t=this.tryEntries.length-1;t>=0;--t){var n=this.tryEntries[t];if(n.finallyLoc===e)return this.complete(n.completion,n.afterLoc),P(n),m}},catch:function(e){for(var t=this.tryEntries.length-1;t>=0;--t){var n=this.tryEntries[t];if(n.tryLoc===e){var r=n.completion;if("throw"===r.type){var i=r.arg;P(n)}return i}}throw new Error("illegal catch attempt")},delegateYield:function(e,n,r){return this.delegate={iterator:C(e),resultName:n,nextLoc:r},"next"===this.method&&(this.arg=t),m}},e}(e.exports);try{regeneratorRuntime=r}catch(i){"object"===typeof globalThis?globalThis.regeneratorRuntime=r:Function("r","regeneratorRuntime = r")(r)}},function(e,t,n){"use strict";n(23);var r=n(1),i=60103;if(t.Fragment=60107,"function"===typeof Symbol&&Symbol.for){var o=Symbol.for;i=o("react.element"),t.Fragment=o("react.fragment")}var a=r.__SECRET_INTERNALS_DO_NOT_USE_OR_YOU_WILL_BE_FIRED.ReactCurrentOwner,l=Object.prototype.hasOwnProperty,s={key:!0,ref:!0,__self:!0,__source:!0};function c(e,t,n){var r,o={},c=null,u=null;for(r in void 0!==n&&(c=""+n),void 0!==t.key&&(c=""+t.key),void 0!==t.ref&&(u=t.ref),t)l.call(t,r)&&!s.hasOwnProperty(r)&&(o[r]=t[r]);if(e&&e.defaultProps)for(r in t=e.defaultProps)void 0===o[r]&&(o[r]=t[r]);return{$$typeof:i,type:e,key:c,ref:u,props:o,_owner:a.current}}t.jsx=c,t.jsxs=c},function(e,t,n){var r=n(24),i=n(44);"string"===typeof(i=i.__esModule?i.default:i)&&(i=[[e.i,i,""]]);var o={insert:"head",singleton:!1};r(i,o);e.exports=i.locals||{}},function(e,t,n){"use strict";n.r(t);var r=n(20),i=n.n(r)()(!0);i.push([e.i,"","",{version:3,sources:[],names:[],mappings:"",sourceRoot:""}]),t.default=i},function(e,t,n){var r=n(3).getQueryPrice;function i(e){var t=e.event,n=e.form,r=e.errorEl,i=e.siteUrl,o=e.submitHandler;n.removeEventListener("submit",o),t.preventDefault(),r&&(r.innerText=""),n.classList.remove("success","invalid","error");for(var a=t.target.querySelector("input[data-members-email]"),l=t.target.querySelector("input[data-members-name]"),s=null===a||void 0===a?void 0:a.value,c=l&&l.value||void 0,u=void 0,p=[],d=t.target.querySelectorAll("input[data-members-label]")||[],f=0;f<d.length;++f)p.push(d[f].value);n.dataset.membersForm&&(u=n.dataset.membersForm),n.classList.add("loading"),fetch("".concat(i,"/members/api/send-magic-link/"),{method:"POST",headers:{"Content-Type":"application/json"},body:JSON.stringify({email:s,emailType:u,labels:p,name:c})}).then((function(e){n.addEventListener("submit",o),n.classList.remove("loading"),e.ok?n.classList.add("success"):(r&&(r.innerText="There was an error sending the email, please try again"),n.classList.add("error"))}))}function o(e){var t=e.event,n=e.el,i=e.errorEl,o=e.siteUrl,a=e.site,l=e.member,s=e.clickHandler;n.removeEventListener("click",s),t.preventDefault();var c=n.dataset.membersPlan,u="";if(c){var p=r({site:a,priceId:c.toLowerCase()});u=p?p.id:c}var d,f,h=n.dataset.membersSuccess,m=n.dataset.membersCancel;h&&(d=new URL(h,window.location.href).href),m&&(f=new URL(m,window.location.href).href),i&&(i.innerText=""),n.classList.add("loading");var g=l?{checkoutType:"upgrade"}:{};return fetch("".concat(o,"/members/api/session"),{credentials:"same-origin"}).then((function(e){return e.ok?e.text():null})).then((function(e){return fetch("".concat(o,"/members/api/create-stripe-checkout-session/"),{method:"POST",headers:{"Content-Type":"application/json"},body:JSON.stringify({priceId:u,identity:e,successUrl:d,cancelUrl:f,metadata:g})}).then((function(e){if(!e.ok)throw new Error("Could not create stripe checkout session");return e.json()}))})).then((function(e){return window.Stripe(e.publicKey).redirectToCheckout({sessionId:e.sessionId})})).then((function(e){if(e.error)throw new Error(e.error.message)})).catch((function(e){console.error(e),n.addEventListener("click",s),n.classList.remove("loading"),i&&(i.innerText=e.message),n.classList.add("error")}))}e.exports={handleDataAttributes:function(e){var t=e.siteUrl,n=e.site,r=e.member;t&&(t=t.replace(/\/$/,""),Array.prototype.forEach.call(document.querySelectorAll("form[data-members-form]"),(function(e){var n=e.querySelector("[data-members-error]");e.addEventListener("submit",(function r(o){i({event:o,errorEl:n,form:e,siteUrl:t,submitHandler:r})}))})),Array.prototype.forEach.call(document.querySelectorAll("[data-members-plan]"),(function(e){var i=e.querySelector("[data-members-error]");e.addEventListener("click",(function a(l){o({el:e,event:l,errorEl:i,member:r,site:n,siteUrl:t,clickHandler:a})}))})),Array.prototype.forEach.call(document.querySelectorAll("[data-members-edit-billing]"),(function(e){var n,r,i=e.querySelector("[data-members-error]"),o=e.dataset.membersSuccess,a=e.dataset.membersCancel;o&&(n=new URL(o,window.location.href).href),a&&(r=new URL(a,window.location.href).href),e.addEventListener("click",(function o(a){e.removeEventListener("click",o),a.preventDefault(),i&&(i.innerText=""),e.classList.add("loading"),fetch("".concat(t,"/members/api/session"),{credentials:"same-origin"}).then((function(e){return e.ok?e.text():null})).then((function(e){return fetch("".concat(t,"/members/api/create-stripe-update-session/"),{method:"POST",headers:{"Content-Type":"application/json"},body:JSON.stringify({identity:e,successUrl:n,cancelUrl:r})}).then((function(e){if(!e.ok)throw new Error("Could not create stripe checkout session");return e.json()}))})).then((function(e){return window.Stripe(e.publicKey).redirectToCheckout({sessionId:e.sessionId})})).then((function(e){if(e.error)throw new Error(e.error.message)})).catch((function(t){console.error(t),e.addEventListener("click",o),e.classList.remove("loading"),i&&(i.innerText=t.message),e.classList.add("error")}))}))})),Array.prototype.forEach.call(document.querySelectorAll("[data-members-signout]"),(function(e){e.addEventListener("click",(function n(r){e.removeEventListener("click",n),r.preventDefault(),e.classList.remove("error"),e.classList.add("loading"),fetch("".concat(t,"/members/api/session"),{method:"DELETE"}).then((function(r){r.ok?window.location.replace(t):(e.addEventListener("click",n),e.classList.remove("loading"),e.classList.add("error"))}))}))})),Array.prototype.forEach.call(document.querySelectorAll("[data-members-cancel-subscription]"),(function(e){var n=e.parentElement.querySelector("[data-members-error]");e.addEventListener("click",(function r(i){e.removeEventListener("click",r),i.preventDefault(),e.classList.remove("error"),e.classList.add("loading");var o=e.dataset.membersCancelSubscription;return n&&(n.innerText=""),fetch("".concat(t,"/members/api/session"),{credentials:"same-origin"}).then((function(e){return e.ok?e.text():null})).then((function(e){return fetch("".concat(t,"/members/api/subscriptions/").concat(o,"/"),{method:"PUT",headers:{"Content-Type":"application/json"},body:JSON.stringify({identity:e,smart_cancel:!0})})})).then((function(t){t.ok?window.location.reload():(e.addEventListener("click",r),e.classList.remove("loading"),e.classList.add("error"),n&&(n.innerText="There was an error cancelling your subscription, please try again."))}))}))})),Array.prototype.forEach.call(document.querySelectorAll("[data-members-continue-subscription]"),(function(e){var n=e.parentElement.querySelector("[data-members-error]");e.addEventListener("click",(function r(i){e.removeEventListener("click",r),i.preventDefault(),e.classList.remove("error"),e.classList.add("loading");var o=e.dataset.membersContinueSubscription;return n&&(n.innerText=""),fetch("".concat(t,"/members/api/session"),{credentials:"same-origin"}).then((function(e){return e.ok?e.text():null})).then((function(e){return fetch("".concat(t,"/members/api/subscriptions/").concat(o,"/"),{method:"PUT",headers:{"Content-Type":"application/json"},body:JSON.stringify({identity:e,cancel_at_period_end:!1})})})).then((function(t){t.ok?window.location.reload():(e.addEventListener("click",r),e.classList.remove("loading"),e.classList.add("error"),n&&(n.innerText="There was an error continuing your subscription, please try again."))}))}))})))},formSubmitHandler:i,planClickHandler:o}},function(e,t,n){"use strict";e.exports=n(47)},function(e,t,n){"use strict";var r="function"===typeof Symbol&&Symbol.for,i=r?Symbol.for("react.element"):60103,o=r?Symbol.for("react.portal"):60106,a=r?Symbol.for("react.fragment"):60107,l=r?Symbol.for("react.strict_mode"):60108,s=r?Symbol.for("react.profiler"):60114,c=r?Symbol.for("react.provider"):60109,u=r?Symbol.for("react.context"):60110,p=r?Symbol.for("react.async_mode"):60111,d=r?Symbol.for("react.concurrent_mode"):60111,f=r?Symbol.for("react.forward_ref"):60112,h=r?Symbol.for("react.suspense"):60113,m=r?Symbol.for("react.suspense_list"):60120,g=r?Symbol.for("react.memo"):60115,b=r?Symbol.for("react.lazy"):60116,v=r?Symbol.for("react.block"):60121,y=r?Symbol.for("react.fundamental"):60117,x=r?Symbol.for("react.responder"):60118,w=r?Symbol.for("react.scope"):60119;function j(e){if("object"===typeof e&&null!==e){var t=e.$$typeof;switch(t){case i:switch(e=e.type){case p:case d:case a:case s:case l:case h:return e;default:switch(e=e&&e.$$typeof){case u:case f:case b:case g:case c:return e;default:return t}}case o:return t}}}function O(e){return j(e)===d}t.AsyncMode=p,t.ConcurrentMode=d,t.ContextConsumer=u,t.ContextProvider=c,t.Element=i,t.ForwardRef=f,t.Fragment=a,t.Lazy=b,t.Memo=g,t.Portal=o,t.Profiler=s,t.StrictMode=l,t.Suspense=h,t.isAsyncMode=function(e){return O(e)||j(e)===p},t.isConcurrentMode=O,t.isContextConsumer=function(e){return j(e)===u},t.isContextProvider=function(e){return j(e)===c},t.isElement=function(e){return"object"===typeof e&&null!==e&&e.$$typeof===i},t.isForwardRef=function(e){return j(e)===f},t.isFragment=function(e){return j(e)===a},t.isLazy=function(e){return j(e)===b},t.isMemo=function(e){return j(e)===g},t.isPortal=function(e){return j(e)===o},t.isProfiler=function(e){return j(e)===s},t.isStrictMode=function(e){return j(e)===l},t.isSuspense=function(e){return j(e)===h},t.isValidElementType=function(e){return"string"===typeof e||"function"===typeof e||e===a||e===d||e===s||e===l||e===h||e===m||"object"===typeof e&&null!==e&&(e.$$typeof===b||e.$$typeof===g||e.$$typeof===c||e.$$typeof===u||e.$$typeof===f||e.$$typeof===y||e.$$typeof===x||e.$$typeof===w||e.$$typeof===v)},t.typeOf=j},function(e,t){var n,r,i=e.exports={};function o(){throw new Error("setTimeout has not been defined")}function a(){throw new Error("clearTimeout has not been defined")}function l(e){if(n===setTimeout)return setTimeout(e,0);if((n===o||!n)&&setTimeout)return n=setTimeout,setTimeout(e,0);try{return n(e,0)}catch(t){try{return n.call(null,e,0)}catch(t){return n.call(this,e,0)}}}!function(){try{n="function"===typeof setTimeout?setTimeout:o}catch(e){n=o}try{r="function"===typeof clearTimeout?clearTimeout:a}catch(e){r=a}}();var s,c=[],u=!1,p=-1;function d(){u&&s&&(u=!1,s.length?c=s.concat(c):p=-1,c.length&&f())}function f(){if(!u){var e=l(d);u=!0;for(var t=c.length;t;){for(s=c,c=[];++p<t;)s&&s[p].run();p=-1,t=c.length}s=null,u=!1,function(e){if(r===clearTimeout)return clearTimeout(e);if((r===a||!r)&&clearTimeout)return r=clearTimeout,clearTimeout(e);try{r(e)}catch(t){try{return r.call(null,e)}catch(t){return r.call(this,e)}}}(e)}}function h(e,t){this.fun=e,this.array=t}function m(){}i.nextTick=function(e){var t=new Array(arguments.length-1);if(arguments.length>1)for(var n=1;n<arguments.length;n++)t[n-1]=arguments[n];c.push(new h(e,t)),1!==c.length||u||l(f)},h.prototype.run=function(){this.fun.apply(null,this.array)},i.title="browser",i.browser=!0,i.env={},i.argv=[],i.version="",i.versions={},i.on=m,i.addListener=m,i.once=m,i.off=m,i.removeListener=m,i.removeAllListeners=m,i.emit=m,i.prependListener=m,i.prependOnceListener=m,i.listeners=function(e){return[]},i.binding=function(e){throw new Error("process.binding is not supported")},i.cwd=function(){return"/"},i.chdir=function(e){throw new Error("process.chdir is not supported")},i.umask=function(){return 0}},function(e,t,n){"use strict";n.r(t);var r={};n.r(r),n.d(r,"FunctionToString",(function(){return fe})),n.d(r,"InboundFilters",(function(){return ge}));var i=n(1),o=n.n(i),a=n(15),l=n.n(a),s=(n(39),n(6)),c=n(14);function u(e,t){var n="undefined"!==typeof Symbol&&e[Symbol.iterator]||e["@@iterator"];if(!n){if(Array.isArray(e)||(n=Object(c.a)(e))||t&&e&&"number"===typeof e.length){n&&(e=n);var r=0,i=function(){};return{s:i,n:function(){return r>=e.length?{done:!0}:{done:!1,value:e[r++]}},e:function(e){throw e},f:i}}throw new TypeError("Invalid attempt to iterate non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}var o,a=!0,l=!1;return{s:function(){n=n.call(e)},n:function(){var e=n.next();return a=e.done,e},e:function(e){l=!0,o=e},f:function(){try{a||null==n.return||n.return()}finally{if(l)throw o}}}}function p(e,t){if(null==e)return{};var n,r,i=function(e,t){if(null==e)return{};var n,r,i={},o=Object.keys(e);for(r=0;r<o.length;r++)n=o[r],t.indexOf(n)>=0||(i[n]=e[n]);return i}(e,t);if(Object.getOwnPropertySymbols){var o=Object.getOwnPropertySymbols(e);for(r=0;r<o.length;r++)n=o[r],t.indexOf(n)>=0||Object.prototype.propertyIsEnumerable.call(e,n)&&(i[n]=e[n])}return i}function d(e,t,n,r,i,o,a){try{var l=e[o](a),s=l.value}catch(c){return void n(c)}l.done?t(s):Promise.resolve(s).then(r,i)}function f(e){return function(){var t=this,n=arguments;return new Promise((function(r,i){var o=e.apply(t,n);function a(e){d(o,r,i,a,l,"next",e)}function l(e){d(o,r,i,a,l,"throw",e)}a(void 0)}))}}function h(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function m(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}function g(e,t,n){return t&&m(e.prototype,t),n&&m(e,n),Object.defineProperty(e,"prototype",{writable:!1}),e}function b(e,t){return b=Object.setPrototypeOf||function(e,t){return e.__proto__=t,e},b(e,t)}function v(e,t){if("function"!==typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function");Object.defineProperty(e,"prototype",{value:Object.create(t&&t.prototype,{constructor:{value:e,writable:!0,configurable:!0}}),writable:!1}),t&&b(e,t)}function y(e){return y=Object.setPrototypeOf?Object.getPrototypeOf:function(e){return e.__proto__||Object.getPrototypeOf(e)},y(e)}var x=n(27),w=n.n(x);function j(e,t){if(t&&("object"===w()(t)||"function"===typeof t))return t;if(void 0!==t)throw new TypeError("Derived constructors may only return object or undefined");return function(e){if(void 0===e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}(e)}function O(e){var t=function(){if("undefined"===typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"===typeof Proxy)return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],(function(){}))),!0}catch(e){return!1}}();return function(){var n,r=y(e);if(t){var i=y(this).constructor;n=Reflect.construct(r,arguments,i)}else n=r.apply(this,arguments);return j(this,n)}}var k=n(4),_=n(5),S=n.n(_),P=n(2),E=n(9),C=n(10),N=n(13);function T(){var e=Object(E.a)(),t=e.crypto||e.msCrypto;if(void 0!==t&&t.getRandomValues){var n=new Uint16Array(8);t.getRandomValues(n),n[3]=4095&n[3]|16384,n[4]=16383&n[4]|32768;var r=function(e){for(var t=e.toString(16);t.length<4;)t="0"+t;return t};return r(n[0])+r(n[1])+r(n[2])+r(n[3])+r(n[4])+r(n[5])+r(n[6])+r(n[7])}return"xxxxxxxxxxxx4xxxyxxxxxxxxxxxxxxx".replace(/[xy]/g,(function(e){var t=16*Math.random()|0;return("x"===e?t:3&t|8).toString(16)}))}function I(e){if(!e)return{};var t=e.match(/^(([^:/?#]+):)?(\/\/([^/?#]*))?([^?#]*)(\?([^#]*))?(#(.*))?$/);if(!t)return{};var n=t[6]||"",r=t[8]||"";return{host:t[4],path:t[5],protocol:t[2],relative:t[5]+n+r}}function L(e){return e.exception&&e.exception.values?e.exception.values[0]:void 0}function M(e){var t=e.message,n=e.event_id;if(t)return t;var r=L(e);return r?r.type&&r.value?r.type+": "+r.value:r.type||r.value||n||"<unknown>":n||"<unknown>"}function F(e,t,n){var r=e.exception=e.exception||{},i=r.values=r.values||[],o=i[0]=i[0]||{};o.value||(o.value=t||""),o.type||(o.type=n||"Error")}function D(e,t){var n=L(e);if(n){var r=n.mechanism;if(n.mechanism=Object(P.a)(Object(P.a)(Object(P.a)({},{type:"generic",handled:!0}),r),t),t&&"data"in t){var i=Object(P.a)(Object(P.a)({},r&&r.data),t.data);n.mechanism.data=i}}}function z(e){if(e&&e.__sentry_captured__)return!0;try{Object(C.a)(e,"__sentry_captured__",!0)}catch(t){}return!1}var R,U=n(29),A="undefined"===typeof __SENTRY_DEBUG__||__SENTRY_DEBUG__,B=Object(E.a)(),H="Sentry Logger ",q=["debug","info","warn","error","log","assert"];function $(e){var t=Object(E.a)();if(!("console"in t))return e();var n=t.console,r={};q.forEach((function(e){var i=n[e]&&n[e].__sentry_original__;e in t.console&&i&&(r[e]=n[e],n[e]=i)}));try{return e()}finally{Object.keys(r).forEach((function(e){n[e]=r[e]}))}}function W(){var e=!1,t={enable:function(){e=!0},disable:function(){e=!1}};return A?q.forEach((function(n){t[n]=function(){for(var t=[],r=0;r<arguments.length;r++)t[r]=arguments[r];e&&$((function(){var e;(e=B.console)[n].apply(e,Object(P.d)([H+"["+n+"]:"],t))}))}})):q.forEach((function(e){t[e]=function(){}})),t}R=A?Object(E.b)("logger",W):W();var Q=n(17),V="undefined"===typeof __SENTRY_DEBUG__||__SENTRY_DEBUG__,Y=n(8);function K(e){return new J((function(t){t(e)}))}function G(e){return new J((function(t,n){n(e)}))}var J=function(){function e(e){var t=this;this._state=0,this._handlers=[],this._resolve=function(e){t._setResult(1,e)},this._reject=function(e){t._setResult(2,e)},this._setResult=function(e,n){0===t._state&&(Object(Y.n)(n)?n.then(t._resolve,t._reject):(t._state=e,t._value=n,t._executeHandlers()))},this._executeHandlers=function(){if(0!==t._state){var e=t._handlers.slice();t._handlers=[],e.forEach((function(e){e[0]||(1===t._state&&e[1](t._value),2===t._state&&e[2](t._value),e[0]=!0)}))}};try{e(this._resolve,this._reject)}catch(n){this._reject(n)}}return e.prototype.then=function(t,n){var r=this;return new e((function(e,i){r._handlers.push([!1,function(n){if(t)try{e(t(n))}catch(r){i(r)}else e(n)},function(t){if(n)try{e(n(t))}catch(r){i(r)}else i(t)}]),r._executeHandlers()}))},e.prototype.catch=function(e){return this.then((function(e){return e}),e)},e.prototype.finally=function(t){var n=this;return new e((function(e,r){var i,o;return n.then((function(e){o=!1,i=e,t&&t()}),(function(e){o=!0,i=e,t&&t()})).then((function(){o?r(i):e(i)}))}))},e}(),X=function(){function e(){this._notifyingListeners=!1,this._scopeListeners=[],this._eventProcessors=[],this._breadcrumbs=[],this._user={},this._tags={},this._extra={},this._contexts={},this._sdkProcessingMetadata={}}return e.clone=function(t){var n=new e;return t&&(n._breadcrumbs=Object(P.d)(t._breadcrumbs),n._tags=Object(P.a)({},t._tags),n._extra=Object(P.a)({},t._extra),n._contexts=Object(P.a)({},t._contexts),n._user=t._user,n._level=t._level,n._span=t._span,n._session=t._session,n._transactionName=t._transactionName,n._fingerprint=t._fingerprint,n._eventProcessors=Object(P.d)(t._eventProcessors),n._requestSession=t._requestSession),n},e.prototype.addScopeListener=function(e){this._scopeListeners.push(e)},e.prototype.addEventProcessor=function(e){return this._eventProcessors.push(e),this},e.prototype.setUser=function(e){return this._user=e||{},this._session&&this._session.update({user:e}),this._notifyScopeListeners(),this},e.prototype.getUser=function(){return this._user},e.prototype.getRequestSession=function(){return this._requestSession},e.prototype.setRequestSession=function(e){return this._requestSession=e,this},e.prototype.setTags=function(e){return this._tags=Object(P.a)(Object(P.a)({},this._tags),e),this._notifyScopeListeners(),this},e.prototype.setTag=function(e,t){var n;return this._tags=Object(P.a)(Object(P.a)({},this._tags),((n={})[e]=t,n)),this._notifyScopeListeners(),this},e.prototype.setExtras=function(e){return this._extra=Object(P.a)(Object(P.a)({},this._extra),e),this._notifyScopeListeners(),this},e.prototype.setExtra=function(e,t){var n;return this._extra=Object(P.a)(Object(P.a)({},this._extra),((n={})[e]=t,n)),this._notifyScopeListeners(),this},e.prototype.setFingerprint=function(e){return this._fingerprint=e,this._notifyScopeListeners(),this},e.prototype.setLevel=function(e){return this._level=e,this._notifyScopeListeners(),this},e.prototype.setTransactionName=function(e){return this._transactionName=e,this._notifyScopeListeners(),this},e.prototype.setTransaction=function(e){return this.setTransactionName(e)},e.prototype.setContext=function(e,t){var n;return null===t?delete this._contexts[e]:this._contexts=Object(P.a)(Object(P.a)({},this._contexts),((n={})[e]=t,n)),this._notifyScopeListeners(),this},e.prototype.setSpan=function(e){return this._span=e,this._notifyScopeListeners(),this},e.prototype.getSpan=function(){return this._span},e.prototype.getTransaction=function(){var e=this.getSpan();return e&&e.transaction},e.prototype.setSession=function(e){return e?this._session=e:delete this._session,this._notifyScopeListeners(),this},e.prototype.getSession=function(){return this._session},e.prototype.update=function(t){if(!t)return this;if("function"===typeof t){var n=t(this);return n instanceof e?n:this}return t instanceof e?(this._tags=Object(P.a)(Object(P.a)({},this._tags),t._tags),this._extra=Object(P.a)(Object(P.a)({},this._extra),t._extra),this._contexts=Object(P.a)(Object(P.a)({},this._contexts),t._contexts),t._user&&Object.keys(t._user).length&&(this._user=t._user),t._level&&(this._level=t._level),t._fingerprint&&(this._fingerprint=t._fingerprint),t._requestSession&&(this._requestSession=t._requestSession)):Object(Y.i)(t)&&(t=t,this._tags=Object(P.a)(Object(P.a)({},this._tags),t.tags),this._extra=Object(P.a)(Object(P.a)({},this._extra),t.extra),this._contexts=Object(P.a)(Object(P.a)({},this._contexts),t.contexts),t.user&&(this._user=t.user),t.level&&(this._level=t.level),t.fingerprint&&(this._fingerprint=t.fingerprint),t.requestSession&&(this._requestSession=t.requestSession)),this},e.prototype.clear=function(){return this._breadcrumbs=[],this._tags={},this._extra={},this._user={},this._contexts={},this._level=void 0,this._transactionName=void 0,this._fingerprint=void 0,this._requestSession=void 0,this._span=void 0,this._session=void 0,this._notifyScopeListeners(),this},e.prototype.addBreadcrumb=function(e,t){var n="number"===typeof t?Math.min(t,100):100;if(n<=0)return this;var r=Object(P.a)({timestamp:Object(U.a)()},e);return this._breadcrumbs=Object(P.d)(this._breadcrumbs,[r]).slice(-n),this._notifyScopeListeners(),this},e.prototype.clearBreadcrumbs=function(){return this._breadcrumbs=[],this._notifyScopeListeners(),this},e.prototype.applyToEvent=function(e,t){if(this._extra&&Object.keys(this._extra).length&&(e.extra=Object(P.a)(Object(P.a)({},this._extra),e.extra)),this._tags&&Object.keys(this._tags).length&&(e.tags=Object(P.a)(Object(P.a)({},this._tags),e.tags)),this._user&&Object.keys(this._user).length&&(e.user=Object(P.a)(Object(P.a)({},this._user),e.user)),this._contexts&&Object.keys(this._contexts).length&&(e.contexts=Object(P.a)(Object(P.a)({},this._contexts),e.contexts)),this._level&&(e.level=this._level),this._transactionName&&(e.transaction=this._transactionName),this._span){e.contexts=Object(P.a)({trace:this._span.getTraceContext()},e.contexts);var n=this._span.transaction&&this._span.transaction.name;n&&(e.tags=Object(P.a)({transaction:n},e.tags))}return this._applyFingerprint(e),e.breadcrumbs=Object(P.d)(e.breadcrumbs||[],this._breadcrumbs),e.breadcrumbs=e.breadcrumbs.length>0?e.breadcrumbs:void 0,e.sdkProcessingMetadata=this._sdkProcessingMetadata,this._notifyEventProcessors(Object(P.d)(Z(),this._eventProcessors),e,t)},e.prototype.setSDKProcessingMetadata=function(e){return this._sdkProcessingMetadata=Object(P.a)(Object(P.a)({},this._sdkProcessingMetadata),e),this},e.prototype._notifyEventProcessors=function(e,t,n,r){var i=this;return void 0===r&&(r=0),new J((function(o,a){var l=e[r];if(null===t||"function"!==typeof l)o(t);else{var s=l(Object(P.a)({},t),n);Object(Y.n)(s)?s.then((function(t){return i._notifyEventProcessors(e,t,n,r+1).then(o)})).then(null,a):i._notifyEventProcessors(e,s,n,r+1).then(o).then(null,a)}}))},e.prototype._notifyScopeListeners=function(){var e=this;this._notifyingListeners||(this._notifyingListeners=!0,this._scopeListeners.forEach((function(t){t(e)})),this._notifyingListeners=!1)},e.prototype._applyFingerprint=function(e){e.fingerprint=e.fingerprint?Array.isArray(e.fingerprint)?e.fingerprint:[e.fingerprint]:[],this._fingerprint&&(e.fingerprint=e.fingerprint.concat(this._fingerprint)),e.fingerprint&&!e.fingerprint.length&&delete e.fingerprint},e}();function Z(){return Object(E.b)("globalEventProcessors",(function(){return[]}))}function ee(e){Z().push(e)}var te,ne=function(){function e(e){this.errors=0,this.sid=T(),this.duration=0,this.status="ok",this.init=!0,this.ignoreDuration=!1;var t=Object(U.b)();this.timestamp=t,this.started=t,e&&this.update(e)}return e.prototype.update=function(e){if(void 0===e&&(e={}),e.user&&(!this.ipAddress&&e.user.ip_address&&(this.ipAddress=e.user.ip_address),this.did||e.did||(this.did=e.user.id||e.user.email||e.user.username)),this.timestamp=e.timestamp||Object(U.b)(),e.ignoreDuration&&(this.ignoreDuration=e.ignoreDuration),e.sid&&(this.sid=32===e.sid.length?e.sid:T()),void 0!==e.init&&(this.init=e.init),!this.did&&e.did&&(this.did=""+e.did),"number"===typeof e.started&&(this.started=e.started),this.ignoreDuration)this.duration=void 0;else if("number"===typeof e.duration)this.duration=e.duration;else{var t=this.timestamp-this.started;this.duration=t>=0?t:0}e.release&&(this.release=e.release),e.environment&&(this.environment=e.environment),!this.ipAddress&&e.ipAddress&&(this.ipAddress=e.ipAddress),!this.userAgent&&e.userAgent&&(this.userAgent=e.userAgent),"number"===typeof e.errors&&(this.errors=e.errors),e.status&&(this.status=e.status)},e.prototype.close=function(e){e?this.update({status:e}):"ok"===this.status?this.update({status:"exited"}):this.update()},e.prototype.toJSON=function(){return Object(C.c)({sid:""+this.sid,init:this.init,started:new Date(1e3*this.started).toISOString(),timestamp:new Date(1e3*this.timestamp).toISOString(),status:this.status,errors:this.errors,did:"number"===typeof this.did||"string"===typeof this.did?""+this.did:void 0,duration:this.duration,attrs:{release:this.release,environment:this.environment,ip_address:this.ipAddress,user_agent:this.userAgent}})},e}(),re=function(){function e(e,t,n){void 0===t&&(t=new X),void 0===n&&(n=4),this._version=n,this._stack=[{}],this.getStackTop().scope=t,e&&this.bindClient(e)}return e.prototype.isOlderThan=function(e){return this._version<e},e.prototype.bindClient=function(e){this.getStackTop().client=e,e&&e.setupIntegrations&&e.setupIntegrations()},e.prototype.pushScope=function(){var e=X.clone(this.getScope());return this.getStack().push({client:this.getClient(),scope:e}),e},e.prototype.popScope=function(){return!(this.getStack().length<=1)&&!!this.getStack().pop()},e.prototype.withScope=function(e){var t=this.pushScope();try{e(t)}finally{this.popScope()}},e.prototype.getClient=function(){return this.getStackTop().client},e.prototype.getScope=function(){return this.getStackTop().scope},e.prototype.getStack=function(){return this._stack},e.prototype.getStackTop=function(){return this._stack[this._stack.length-1]},e.prototype.captureException=function(e,t){var n=this._lastEventId=t&&t.event_id?t.event_id:T(),r=t;if(!t){var i=void 0;try{throw new Error("Sentry syntheticException")}catch(e){i=e}r={originalException:e,syntheticException:i}}return this._invokeClient("captureException",e,Object(P.a)(Object(P.a)({},r),{event_id:n})),n},e.prototype.captureMessage=function(e,t,n){var r=this._lastEventId=n&&n.event_id?n.event_id:T(),i=n;if(!n){var o=void 0;try{throw new Error(e)}catch(a){o=a}i={originalException:e,syntheticException:o}}return this._invokeClient("captureMessage",e,t,Object(P.a)(Object(P.a)({},i),{event_id:r})),r},e.prototype.captureEvent=function(e,t){var n=t&&t.event_id?t.event_id:T();return"transaction"!==e.type&&(this._lastEventId=n),this._invokeClient("captureEvent",e,Object(P.a)(Object(P.a)({},t),{event_id:n})),n},e.prototype.lastEventId=function(){return this._lastEventId},e.prototype.addBreadcrumb=function(e,t){var n=this.getStackTop(),r=n.scope,i=n.client;if(r&&i){var o=i.getOptions&&i.getOptions()||{},a=o.beforeBreadcrumb,l=void 0===a?null:a,s=o.maxBreadcrumbs,c=void 0===s?100:s;if(!(c<=0)){var u=Object(U.a)(),p=Object(P.a)({timestamp:u},e),d=l?$((function(){return l(p,t)})):p;null!==d&&r.addBreadcrumb(d,c)}}},e.prototype.setUser=function(e){var t=this.getScope();t&&t.setUser(e)},e.prototype.setTags=function(e){var t=this.getScope();t&&t.setTags(e)},e.prototype.setExtras=function(e){var t=this.getScope();t&&t.setExtras(e)},e.prototype.setTag=function(e,t){var n=this.getScope();n&&n.setTag(e,t)},e.prototype.setExtra=function(e,t){var n=this.getScope();n&&n.setExtra(e,t)},e.prototype.setContext=function(e,t){var n=this.getScope();n&&n.setContext(e,t)},e.prototype.configureScope=function(e){var t=this.getStackTop(),n=t.scope,r=t.client;n&&r&&e(n)},e.prototype.run=function(e){var t=oe(this);try{e(this)}finally{oe(t)}},e.prototype.getIntegration=function(e){var t=this.getClient();if(!t)return null;try{return t.getIntegration(e)}catch(n){return V&&R.warn("Cannot retrieve integration "+e.id+" from the current Hub"),null}},e.prototype.startSpan=function(e){return this._callExtensionMethod("startSpan",e)},e.prototype.startTransaction=function(e,t){return this._callExtensionMethod("startTransaction",e,t)},e.prototype.traceHeaders=function(){return this._callExtensionMethod("traceHeaders")},e.prototype.captureSession=function(e){if(void 0===e&&(e=!1),e)return this.endSession();this._sendSessionUpdate()},e.prototype.endSession=function(){var e=this.getStackTop(),t=e&&e.scope,n=t&&t.getSession();n&&n.close(),this._sendSessionUpdate(),t&&t.setSession()},e.prototype.startSession=function(e){var t=this.getStackTop(),n=t.scope,r=t.client,i=r&&r.getOptions()||{},o=i.release,a=i.environment,l=(Object(E.a)().navigator||{}).userAgent,s=new ne(Object(P.a)(Object(P.a)(Object(P.a)({release:o,environment:a},n&&{user:n.getUser()}),l&&{userAgent:l}),e));if(n){var c=n.getSession&&n.getSession();c&&"ok"===c.status&&c.update({status:"exited"}),this.endSession(),n.setSession(s)}return s},e.prototype._sendSessionUpdate=function(){var e=this.getStackTop(),t=e.scope,n=e.client;if(t){var r=t.getSession&&t.getSession();r&&n&&n.captureSession&&n.captureSession(r)}},e.prototype._invokeClient=function(e){for(var t,n=[],r=1;r<arguments.length;r++)n[r-1]=arguments[r];var i=this.getStackTop(),o=i.scope,a=i.client;a&&a[e]&&(t=a)[e].apply(t,Object(P.d)(n,[o]))},e.prototype._callExtensionMethod=function(e){for(var t=[],n=1;n<arguments.length;n++)t[n-1]=arguments[n];var r=ie(),i=r.__SENTRY__;if(i&&i.extensions&&"function"===typeof i.extensions[e])return i.extensions[e].apply(this,t);V&&R.warn("Extension method "+e+" couldn't be found, doing nothing.")},e}();function ie(){var e=Object(E.a)();return e.__SENTRY__=e.__SENTRY__||{extensions:{},hub:void 0},e}function oe(e){var t=ie(),n=se(t);return ce(t,e),n}function ae(){var e=ie();return le(e)&&!se(e).isOlderThan(4)||ce(e,new re),Object(Q.b)()?function(e){try{var t=ie().__SENTRY__,n=t&&t.extensions&&t.extensions.domain&&t.extensions.domain.active;if(!n)return se(e);if(!le(n)||se(n).isOlderThan(4)){var r=se(e).getStackTop();ce(n,new re(r.client,X.clone(r.scope)))}return se(n)}catch(i){return se(e)}}(e):se(e)}function le(e){return!!(e&&e.__SENTRY__&&e.__SENTRY__.hub)}function se(e){return Object(E.b)("hub",(function(){return new re}),e)}function ce(e,t){return!!e&&((e.__SENTRY__=e.__SENTRY__||{}).hub=t,!0)}function ue(e){for(var t=[],n=1;n<arguments.length;n++)t[n-1]=arguments[n];var r=ae();if(r&&r[e])return r[e].apply(r,Object(P.d)(t));throw new Error("No hub defined or "+e+" was not found on the hub, please open a bug report.")}function pe(e,t){return ue("captureException",e,{captureContext:t,originalException:e,syntheticException:new Error("Sentry syntheticException")})}function de(e){ue("withScope",e)}var fe=function(){function e(){this.name=e.id}return e.prototype.setupOnce=function(){te=Function.prototype.toString,Function.prototype.toString=function(){for(var e=[],t=0;t<arguments.length;t++)e[t]=arguments[t];var n=Object(C.f)(this)||this;return te.apply(n,e)}},e.id="FunctionToString",e}(),he="undefined"===typeof __SENTRY_DEBUG__||__SENTRY_DEBUG__,me=[/^Script error\.?$/,/^Javascript error: Script error\.? on line 0$/],ge=function(){function e(t){void 0===t&&(t={}),this._options=t,this.name=e.id}return e.prototype.setupOnce=function(t,n){t((function(t){var r=n();if(r){var i=r.getIntegration(e);if(i){var o=r.getClient(),a=o?o.getOptions():{},l=function(e,t){void 0===e&&(e={});void 0===t&&(t={});return{allowUrls:Object(P.d)(e.whitelistUrls||[],e.allowUrls||[],t.whitelistUrls||[],t.allowUrls||[]),denyUrls:Object(P.d)(e.blacklistUrls||[],e.denyUrls||[],t.blacklistUrls||[],t.denyUrls||[]),ignoreErrors:Object(P.d)(e.ignoreErrors||[],t.ignoreErrors||[],me),ignoreInternal:void 0===e.ignoreInternal||e.ignoreInternal}}(i._options,a);return function(e,t){if(t.ignoreInternal&&function(e){try{return"SentryError"===e.exception.values[0].type}catch(t){}return!1}(e))return he&&R.warn("Event dropped due to being internal Sentry Error.\nEvent: "+M(e)),!0;if(function(e,t){if(!t||!t.length)return!1;return function(e){if(e.message)return[e.message];if(e.exception)try{var t=e.exception.values&&e.exception.values[0]||{},n=t.type,r=void 0===n?"":n,i=t.value,o=void 0===i?"":i;return[""+o,r+": "+o]}catch(a){return he&&R.error("Cannot extract message for event "+M(e)),[]}return[]}(e).some((function(e){return t.some((function(t){return Object(N.a)(e,t)}))}))}(e,t.ignoreErrors))return he&&R.warn("Event dropped due to being matched by `ignoreErrors` option.\nEvent: "+M(e)),!0;if(function(e,t){if(!t||!t.length)return!1;var n=ve(e);return!!n&&t.some((function(e){return Object(N.a)(n,e)}))}(e,t.denyUrls))return he&&R.warn("Event dropped due to being matched by `denyUrls` option.\nEvent: "+M(e)+".\nUrl: "+ve(e)),!0;if(!function(e,t){if(!t||!t.length)return!0;var n=ve(e);return!n||t.some((function(e){return Object(N.a)(n,e)}))}(e,t.allowUrls))return he&&R.warn("Event dropped due to not being matched by `allowUrls` option.\nEvent: "+M(e)+".\nUrl: "+ve(e)),!0;return!1}(t,l)?null:t}}return t}))},e.id="InboundFilters",e}();function be(e){void 0===e&&(e=[]);for(var t=e.length-1;t>=0;t--){var n=e[t];if(n&&"<anonymous>"!==n.filename&&"[native code]"!==n.filename)return n.filename||null}return null}function ve(e){try{if(e.stacktrace)return be(e.stacktrace.frames);var t;try{t=e.exception.values[0].stacktrace.frames}catch(n){}return t?be(t):null}catch(r){return he&&R.error("Cannot extract url for event "+M(e)),null}}var ye=n(22);function xe(){if(!("fetch"in Object(E.a)()))return!1;try{return new Headers,new Request(""),new Response,!0}catch(e){return!1}}function we(e){return e&&/^function fetch\(\)\s+\{\s+\[native code\]\s+\}$/.test(e.toString())}function je(){if(!xe())return!1;try{return new Request("_",{referrerPolicy:"origin"}),!0}catch(e){return!1}}var Oe,ke=Object(E.a)(),_e={},Se={};function Pe(e){if(!Se[e])switch(Se[e]=!0,e){case"console":!function(){if(!("console"in ke))return;q.forEach((function(e){e in ke.console&&Object(C.e)(ke.console,e,(function(t){return function(){for(var n=[],r=0;r<arguments.length;r++)n[r]=arguments[r];Ce("console",{args:n,level:e}),t&&t.apply(ke.console,n)}}))}))}();break;case"dom":!function(){if(!("document"in ke))return;var e=Ce.bind(null,"dom"),t=Me(e,!0);ke.document.addEventListener("click",t,!1),ke.document.addEventListener("keypress",t,!1),["EventTarget","Node"].forEach((function(t){var n=ke[t]&&ke[t].prototype;n&&n.hasOwnProperty&&n.hasOwnProperty("addEventListener")&&(Object(C.e)(n,"addEventListener",(function(t){return function(n,r,i){if("click"===n||"keypress"==n)try{var o=this,a=o.__sentry_instrumentation_handlers__=o.__sentry_instrumentation_handlers__||{},l=a[n]=a[n]||{refCount:0};if(!l.handler){var s=Me(e);l.handler=s,t.call(this,n,s,i)}l.refCount+=1}catch(c){}return t.call(this,n,r,i)}})),Object(C.e)(n,"removeEventListener",(function(e){return function(t,n,r){if("click"===t||"keypress"==t)try{var i=this,o=i.__sentry_instrumentation_handlers__||{},a=o[t];a&&(a.refCount-=1,a.refCount<=0&&(e.call(this,t,a.handler,r),a.handler=void 0,delete o[t]),0===Object.keys(o).length&&delete i.__sentry_instrumentation_handlers__)}catch(l){}return e.call(this,t,n,r)}})))}))}();break;case"xhr":!function(){if(!("XMLHttpRequest"in ke))return;var e=XMLHttpRequest.prototype;Object(C.e)(e,"open",(function(e){return function(){for(var t=[],n=0;n<arguments.length;n++)t[n]=arguments[n];var r=this,i=t[1],o=r.__sentry_xhr__={method:Object(Y.l)(t[0])?t[0].toUpperCase():t[0],url:t[1]};Object(Y.l)(i)&&"POST"===o.method&&i.match(/sentry_key/)&&(r.__sentry_own_request__=!0);var a=function(){if(4===r.readyState){try{o.status_code=r.status}catch(e){}Ce("xhr",{args:t,endTimestamp:Date.now(),startTimestamp:Date.now(),xhr:r})}};return"onreadystatechange"in r&&"function"===typeof r.onreadystatechange?Object(C.e)(r,"onreadystatechange",(function(e){return function(){for(var t=[],n=0;n<arguments.length;n++)t[n]=arguments[n];return a(),e.apply(r,t)}})):r.addEventListener("readystatechange",a),e.apply(r,t)}})),Object(C.e)(e,"send",(function(e){return function(){for(var t=[],n=0;n<arguments.length;n++)t[n]=arguments[n];return this.__sentry_xhr__&&void 0!==t[0]&&(this.__sentry_xhr__.body=t[0]),Ce("xhr",{args:t,startTimestamp:Date.now(),xhr:this}),e.apply(this,t)}}))}();break;case"fetch":!function(){if(!function(){if(!xe())return!1;var e=Object(E.a)();if(we(e.fetch))return!0;var t=!1,n=e.document;if(n&&"function"===typeof n.createElement)try{var r=n.createElement("iframe");r.hidden=!0,n.head.appendChild(r),r.contentWindow&&r.contentWindow.fetch&&(t=we(r.contentWindow.fetch)),n.head.removeChild(r)}catch(i){A&&R.warn("Could not create sandbox iframe for pure fetch check, bailing to window.fetch: ",i)}return t}())return;Object(C.e)(ke,"fetch",(function(e){return function(){for(var t=[],n=0;n<arguments.length;n++)t[n]=arguments[n];var r={args:t,fetchData:{method:Ne(t),url:Te(t)},startTimestamp:Date.now()};return Ce("fetch",Object(P.a)({},r)),e.apply(ke,t).then((function(e){return Ce("fetch",Object(P.a)(Object(P.a)({},r),{endTimestamp:Date.now(),response:e})),e}),(function(e){throw Ce("fetch",Object(P.a)(Object(P.a)({},r),{endTimestamp:Date.now(),error:e})),e}))}}))}();break;case"history":!function(){if(!function(){var e=Object(E.a)(),t=e.chrome,n=t&&t.app&&t.app.runtime,r="history"in e&&!!e.history.pushState&&!!e.history.replaceState;return!n&&r}())return;var e=ke.onpopstate;function t(e){return function(){for(var t=[],n=0;n<arguments.length;n++)t[n]=arguments[n];var r=t.length>2?t[2]:void 0;if(r){var i=Oe,o=String(r);Oe=o,Ce("history",{from:i,to:o})}return e.apply(this,t)}}ke.onpopstate=function(){for(var t=[],n=0;n<arguments.length;n++)t[n]=arguments[n];var r=ke.location.href,i=Oe;if(Oe=r,Ce("history",{from:i,to:r}),e)try{return e.apply(this,t)}catch(o){}},Object(C.e)(ke.history,"pushState",t),Object(C.e)(ke.history,"replaceState",t)}();break;case"error":Fe=ke.onerror,ke.onerror=function(e,t,n,r,i){return Ce("error",{column:r,error:i,line:n,msg:e,url:t}),!!Fe&&Fe.apply(this,arguments)};break;case"unhandledrejection":De=ke.onunhandledrejection,ke.onunhandledrejection=function(e){return Ce("unhandledrejection",e),!De||De.apply(this,arguments)};break;default:return void(A&&R.warn("unknown instrumentation type:",e))}}function Ee(e,t){_e[e]=_e[e]||[],_e[e].push(t),Pe(e)}function Ce(e,t){var n,r;if(e&&_e[e])try{for(var i=Object(P.e)(_e[e]||[]),o=i.next();!o.done;o=i.next()){var a=o.value;try{a(t)}catch(l){A&&R.error("Error while triggering instrumentation handler.\nType: "+e+"\nName: "+Object(ye.b)(a)+"\nError:",l)}}}catch(s){n={error:s}}finally{try{o&&!o.done&&(r=i.return)&&r.call(i)}finally{if(n)throw n.error}}}function Ne(e){return void 0===e&&(e=[]),"Request"in ke&&Object(Y.g)(e[0],Request)&&e[0].method?String(e[0].method).toUpperCase():e[1]&&e[1].method?String(e[1].method).toUpperCase():"GET"}function Te(e){return void 0===e&&(e=[]),"string"===typeof e[0]?e[0]:"Request"in ke&&Object(Y.g)(e[0],Request)?e[0].url:String(e[0])}var Ie,Le;function Me(e,t){return void 0===t&&(t=!1),function(n){if(n&&Le!==n&&!function(e){if("keypress"!==e.type)return!1;try{var t=e.target;if(!t||!t.tagName)return!0;if("INPUT"===t.tagName||"TEXTAREA"===t.tagName||t.isContentEditable)return!1}catch(n){}return!0}(n)){var r="keypress"===n.type?"input":n.type;(void 0===Ie||function(e,t){if(!e)return!0;if(e.type!==t.type)return!0;try{if(e.target!==t.target)return!0}catch(n){}return!1}(Le,n))&&(e({event:n,name:r,global:t}),Le=n),clearTimeout(Ie),Ie=ke.setTimeout((function(){Ie=void 0}),1e3)}}}var Fe=null;var De=null;var ze="6.19.7",Re=Object.setPrototypeOf||({__proto__:[]}instanceof Array?function(e,t){return e.__proto__=t,e}:function(e,t){for(var n in t)Object.prototype.hasOwnProperty.call(e,n)||(e[n]=t[n]);return e});var Ue=function(e){function t(t){var n=this.constructor,r=e.call(this,t)||this;return r.message=t,r.name=n.prototype.constructor.name,Re(r,n.prototype),r}return Object(P.b)(t,e),t}(Error),Ae=/^(?:(\w+):)\/\/(?:(\w+)(?::(\w+))?@)([\w.-]+)(?::(\d+))?\/(.+)/;function Be(e,t){void 0===t&&(t=!1);var n=e.host,r=e.path,i=e.pass,o=e.port,a=e.projectId;return e.protocol+"://"+e.publicKey+(t&&i?":"+i:"")+"@"+n+(o?":"+o:"")+"/"+(r?r+"/":r)+a}function He(e){return"user"in e&&!("publicKey"in e)&&(e.publicKey=e.user),{user:e.publicKey||"",protocol:e.protocol,publicKey:e.publicKey||"",pass:e.pass||"",host:e.host,port:e.port||"",path:e.path||"",projectId:e.projectId}}function qe(e){var t="string"===typeof e?function(e){var t=Ae.exec(e);if(!t)throw new Ue("Invalid Sentry Dsn: "+e);var n=Object(P.c)(t.slice(1),6),r=n[0],i=n[1],o=n[2],a=void 0===o?"":o,l=n[3],s=n[4],c=void 0===s?"":s,u="",p=n[5],d=p.split("/");if(d.length>1&&(u=d.slice(0,-1).join("/"),p=d.pop()),p){var f=p.match(/^\d+/);f&&(p=f[0])}return He({host:l,pass:a,path:u,projectId:p,port:c,protocol:r,publicKey:i})}(e):He(e);return function(e){if(A){var t=e.port,n=e.projectId,r=e.protocol;if(["protocol","publicKey","host","projectId"].forEach((function(t){if(!e[t])throw new Ue("Invalid Sentry Dsn: "+t+" missing")})),!n.match(/^\d+$/))throw new Ue("Invalid Sentry Dsn: Invalid projectId "+n);if(!function(e){return"http"===e||"https"===e}(r))throw new Ue("Invalid Sentry Dsn: Invalid protocol "+r);if(t&&isNaN(parseInt(t,10)))throw new Ue("Invalid Sentry Dsn: Invalid port "+t)}}(t),t}var $e=n(52),We=[];function Qe(e){return e.reduce((function(e,t){return e.every((function(e){return t.name!==e.name}))&&e.push(t),e}),[])}function Ve(e){var t={};return function(e){var t=e.defaultIntegrations&&Object(P.d)(e.defaultIntegrations)||[],n=e.integrations,r=Object(P.d)(Qe(t));Array.isArray(n)?r=Object(P.d)(r.filter((function(e){return n.every((function(t){return t.name!==e.name}))})),Qe(n)):"function"===typeof n&&(r=n(r),r=Array.isArray(r)?r:[r]);var i=r.map((function(e){return e.name})),o="Debug";return-1!==i.indexOf(o)&&r.push.apply(r,Object(P.d)(r.splice(i.indexOf(o),1))),r}(e).forEach((function(e){t[e.name]=e,function(e){-1===We.indexOf(e.name)&&(e.setupOnce(ee,ae),We.push(e.name),he&&R.log("Integration installed: "+e.name))}(e)})),Object(C.a)(t,"initialized",!0),t}var Ye="Not capturing exception because it's already been captured.",Ke=function(){function e(e,t){this._integrations={},this._numProcessing=0,this._backend=new e(t),this._options=t,t.dsn&&(this._dsn=qe(t.dsn))}return e.prototype.captureException=function(e,t,n){var r=this;if(!z(e)){var i=t&&t.event_id;return this._process(this._getBackend().eventFromException(e,t).then((function(e){return r._captureEvent(e,t,n)})).then((function(e){i=e}))),i}he&&R.log(Ye)},e.prototype.captureMessage=function(e,t,n,r){var i=this,o=n&&n.event_id,a=Object(Y.j)(e)?this._getBackend().eventFromMessage(String(e),t,n):this._getBackend().eventFromException(e,n);return this._process(a.then((function(e){return i._captureEvent(e,n,r)})).then((function(e){o=e}))),o},e.prototype.captureEvent=function(e,t,n){if(!(t&&t.originalException&&z(t.originalException))){var r=t&&t.event_id;return this._process(this._captureEvent(e,t,n).then((function(e){r=e}))),r}he&&R.log(Ye)},e.prototype.captureSession=function(e){this._isEnabled()?"string"!==typeof e.release?he&&R.warn("Discarded session because of missing or non-string release"):(this._sendSession(e),e.update({init:!1})):he&&R.warn("SDK not enabled, will not capture session.")},e.prototype.getDsn=function(){return this._dsn},e.prototype.getOptions=function(){return this._options},e.prototype.getTransport=function(){return this._getBackend().getTransport()},e.prototype.flush=function(e){var t=this;return this._isClientDoneProcessing(e).then((function(n){return t.getTransport().close(e).then((function(e){return n&&e}))}))},e.prototype.close=function(e){var t=this;return this.flush(e).then((function(e){return t.getOptions().enabled=!1,e}))},e.prototype.setupIntegrations=function(){this._isEnabled()&&!this._integrations.initialized&&(this._integrations=Ve(this._options))},e.prototype.getIntegration=function(e){try{return this._integrations[e.id]||null}catch(t){return he&&R.warn("Cannot retrieve integration "+e.id+" from the current Client"),null}},e.prototype._updateSessionFromEvent=function(e,t){var n,r,i=!1,o=!1,a=t.exception&&t.exception.values;if(a){o=!0;try{for(var l=Object(P.e)(a),s=l.next();!s.done;s=l.next()){var c=s.value.mechanism;if(c&&!1===c.handled){i=!0;break}}}catch(p){n={error:p}}finally{try{s&&!s.done&&(r=l.return)&&r.call(l)}finally{if(n)throw n.error}}}var u="ok"===e.status;(u&&0===e.errors||u&&i)&&(e.update(Object(P.a)(Object(P.a)({},i&&{status:"crashed"}),{errors:e.errors||Number(o||i)})),this.captureSession(e))},e.prototype._sendSession=function(e){this._getBackend().sendSession(e)},e.prototype._isClientDoneProcessing=function(e){var t=this;return new J((function(n){var r=0,i=setInterval((function(){0==t._numProcessing?(clearInterval(i),n(!0)):(r+=1,e&&r>=e&&(clearInterval(i),n(!1)))}),1)}))},e.prototype._getBackend=function(){return this._backend},e.prototype._isEnabled=function(){return!1!==this.getOptions().enabled&&void 0!==this._dsn},e.prototype._prepareEvent=function(e,t,n){var r=this,i=this.getOptions(),o=i.normalizeDepth,a=void 0===o?3:o,l=i.normalizeMaxBreadth,s=void 0===l?1e3:l,c=Object(P.a)(Object(P.a)({},e),{event_id:e.event_id||(n&&n.event_id?n.event_id:T()),timestamp:e.timestamp||Object(U.a)()});this._applyClientOptions(c),this._applyIntegrationsMetadata(c);var u=t;n&&n.captureContext&&(u=X.clone(u).update(n.captureContext));var p=K(c);return u&&(p=u.applyToEvent(c,n)),p.then((function(e){return e&&(e.sdkProcessingMetadata=Object(P.a)(Object(P.a)({},e.sdkProcessingMetadata),{normalizeDepth:Object($e.a)(a)+" ("+typeof a+")"})),"number"===typeof a&&a>0?r._normalizeEvent(e,a,s):e}))},e.prototype._normalizeEvent=function(e,t,n){if(!e)return null;var r=Object(P.a)(Object(P.a)(Object(P.a)(Object(P.a)(Object(P.a)({},e),e.breadcrumbs&&{breadcrumbs:e.breadcrumbs.map((function(e){return Object(P.a)(Object(P.a)({},e),e.data&&{data:Object($e.a)(e.data,t,n)})}))}),e.user&&{user:Object($e.a)(e.user,t,n)}),e.contexts&&{contexts:Object($e.a)(e.contexts,t,n)}),e.extra&&{extra:Object($e.a)(e.extra,t,n)});return e.contexts&&e.contexts.trace&&(r.contexts.trace=e.contexts.trace),r.sdkProcessingMetadata=Object(P.a)(Object(P.a)({},r.sdkProcessingMetadata),{baseClientNormalized:!0}),r},e.prototype._applyClientOptions=function(e){var t=this.getOptions(),n=t.environment,r=t.release,i=t.dist,o=t.maxValueLength,a=void 0===o?250:o;"environment"in e||(e.environment="environment"in t?n:"production"),void 0===e.release&&void 0!==r&&(e.release=r),void 0===e.dist&&void 0!==i&&(e.dist=i),e.message&&(e.message=Object(N.d)(e.message,a));var l=e.exception&&e.exception.values&&e.exception.values[0];l&&l.value&&(l.value=Object(N.d)(l.value,a));var s=e.request;s&&s.url&&(s.url=Object(N.d)(s.url,a))},e.prototype._applyIntegrationsMetadata=function(e){var t=Object.keys(this._integrations);t.length>0&&(e.sdk=e.sdk||{},e.sdk.integrations=Object(P.d)(e.sdk.integrations||[],t))},e.prototype._sendEvent=function(e){this._getBackend().sendEvent(e)},e.prototype._captureEvent=function(e,t,n){return this._processEvent(e,t,n).then((function(e){return e.event_id}),(function(e){he&&R.error(e)}))},e.prototype._processEvent=function(e,t,n){var r=this,i=this.getOptions(),o=i.beforeSend,a=i.sampleRate,l=this.getTransport();function s(e,t){l.recordLostEvent&&l.recordLostEvent(e,t)}if(!this._isEnabled())return G(new Ue("SDK not enabled, will not capture event."));var c="transaction"===e.type;return!c&&"number"===typeof a&&Math.random()>a?(s("sample_rate","event"),G(new Ue("Discarding event because it's not included in the random sample (sampling rate = "+a+")"))):this._prepareEvent(e,n,t).then((function(n){if(null===n)throw s("event_processor",e.type||"event"),new Ue("An event processor returned null, will not send event.");return t&&t.data&&!0===t.data.__sentry__||c||!o?n:function(e){var t="`beforeSend` method has to return `null` or a valid event.";if(Object(Y.n)(e))return e.then((function(e){if(!Object(Y.i)(e)&&null!==e)throw new Ue(t);return e}),(function(e){throw new Ue("beforeSend rejected with "+e)}));if(!Object(Y.i)(e)&&null!==e)throw new Ue(t);return e}(o(n,t))})).then((function(t){if(null===t)throw s("before_send",e.type||"event"),new Ue("`beforeSend` returned `null`, will not send event.");var i=n&&n.getSession&&n.getSession();return!c&&i&&r._updateSessionFromEvent(i,t),r._sendEvent(t),t})).then(null,(function(e){if(e instanceof Ue)throw e;throw r.captureException(e,{data:{__sentry__:!0},originalException:e}),new Ue("Event processing pipeline threw an error, original event will not be sent. Details have been sent as a new event.\nReason: "+e)}))},e.prototype._process=function(e){var t=this;this._numProcessing+=1,e.then((function(e){return t._numProcessing-=1,e}),(function(e){return t._numProcessing-=1,e}))},e}();!function(){function e(e,t,n){void 0===t&&(t={}),this.dsn=e,this._dsnObject=qe(e),this.metadata=t,this._tunnel=n}e.prototype.getDsn=function(){return this._dsnObject},e.prototype.forceEnvelope=function(){return!!this._tunnel},e.prototype.getBaseApiEndpoint=function(){return Je(this._dsnObject)},e.prototype.getStoreEndpoint=function(){return et(this._dsnObject)},e.prototype.getStoreEndpointWithUrlEncodedAuth=function(){return tt(this._dsnObject)},e.prototype.getEnvelopeEndpointWithUrlEncodedAuth=function(){return nt(this._dsnObject,this._tunnel)}}();function Ge(e,t,n){return{initDsn:e,metadata:t||{},dsn:qe(e),tunnel:n}}function Je(e){var t=e.protocol?e.protocol+":":"",n=e.port?":"+e.port:"";return t+"//"+e.host+n+(e.path?"/"+e.path:"")+"/api/"}function Xe(e,t){return""+Je(e)+e.projectId+"/"+t+"/"}function Ze(e){return Object(C.h)({sentry_key:e.publicKey,sentry_version:"7"})}function et(e){return Xe(e,"store")}function tt(e){return et(e)+"?"+Ze(e)}function nt(e,t){return t||function(e){return Xe(e,"envelope")}(e)+"?"+Ze(e)}function rt(e,t){return void 0===t&&(t=[]),[e,t]}function it(e){var t=Object(P.c)(e,2),n=t[0],r=t[1],i=JSON.stringify(n);return r.reduce((function(e,t){var n=Object(P.c)(t,2),r=n[0],i=n[1],o=Object(Y.j)(i)?String(i):JSON.stringify(i);return e+"\n"+JSON.stringify(r)+"\n"+o}),i)}function ot(e){if(e.metadata&&e.metadata.sdk){var t=e.metadata.sdk;return{name:t.name,version:t.version}}}function at(e,t){return t?(e.sdk=e.sdk||{},e.sdk.name=e.sdk.name||t.name,e.sdk.version=e.sdk.version||t.version,e.sdk.integrations=Object(P.d)(e.sdk.integrations||[],t.integrations||[]),e.sdk.packages=Object(P.d)(e.sdk.packages||[],t.packages||[]),e):e}function lt(e,t){var n=ot(t),r="aggregates"in e?"sessions":"session";return[rt(Object(P.a)(Object(P.a)({sent_at:(new Date).toISOString()},n&&{sdk:n}),!!t.tunnel&&{dsn:Be(t.dsn)}),[[{type:r},e]]),r]}var st,ct=function(){function e(){}return e.prototype.sendEvent=function(e){return K({reason:"NoopTransport: Event has been skipped because no Dsn is configured.",status:"skipped"})},e.prototype.close=function(e){return K(!0)},e}(),ut=function(){function e(e){this._options=e,this._options.dsn||he&&R.warn("No DSN provided, backend will not do anything."),this._transport=this._setupTransport()}return e.prototype.eventFromException=function(e,t){throw new Ue("Backend has to implement `eventFromException` method")},e.prototype.eventFromMessage=function(e,t,n){throw new Ue("Backend has to implement `eventFromMessage` method")},e.prototype.sendEvent=function(e){if(this._newTransport&&this._options.dsn&&this._options._experiments&&this._options._experiments.newTransport){var t=function(e,t){var n=ot(t),r=e.type||"event",i=(e.sdkProcessingMetadata||{}).transactionSampling||{},o=i.method,a=i.rate;return at(e,t.metadata.sdk),e.tags=e.tags||{},e.extra=e.extra||{},e.sdkProcessingMetadata&&e.sdkProcessingMetadata.baseClientNormalized||(e.tags.skippedNormalization=!0,e.extra.normalizeDepth=e.sdkProcessingMetadata?e.sdkProcessingMetadata.normalizeDepth:"unset"),delete e.sdkProcessingMetadata,rt(Object(P.a)(Object(P.a)({event_id:e.event_id,sent_at:(new Date).toISOString()},n&&{sdk:n}),!!t.tunnel&&{dsn:Be(t.dsn)}),[[{type:r,sample_rates:[{id:o,rate:a}]},e]])}(e,Ge(this._options.dsn,this._options._metadata,this._options.tunnel));this._newTransport.send(t).then(null,(function(e){he&&R.error("Error while sending event:",e)}))}else this._transport.sendEvent(e).then(null,(function(e){he&&R.error("Error while sending event:",e)}))},e.prototype.sendSession=function(e){if(this._transport.sendSession)if(this._newTransport&&this._options.dsn&&this._options._experiments&&this._options._experiments.newTransport){var t=Ge(this._options.dsn,this._options._metadata,this._options.tunnel),n=Object(P.c)(lt(e,t),1)[0];this._newTransport.send(n).then(null,(function(e){he&&R.error("Error while sending session:",e)}))}else this._transport.sendSession(e).then(null,(function(e){he&&R.error("Error while sending session:",e)}));else he&&R.warn("Dropping session because custom transport doesn't implement sendSession")},e.prototype.getTransport=function(){return this._transport},e.prototype._setupTransport=function(){return new ct},e}();!function(e){e.Fatal="fatal",e.Error="error",e.Warning="warning",e.Log="log",e.Info="info",e.Debug="debug",e.Critical="critical"}(st||(st={}));var pt="?";function dt(e,t,n,r){var i={filename:e,function:t,in_app:!0};return void 0!==n&&(i.lineno=n),void 0!==r&&(i.colno=r),i}var ft=/^\s*at (?:(.*?) ?\((?:address at )?)?((?:file|https?|blob|chrome-extension|address|native|eval|webpack|<anonymous>|[-a-z]+:|.*bundle|\/).*?)(?::(\d+))?(?::(\d+))?\)?\s*$/i,ht=/\((\S*)(?::(\d+))(?::(\d+))\)/,mt=[30,function(e){var t=ft.exec(e);if(t){if(t[2]&&0===t[2].indexOf("eval")){var n=ht.exec(t[2]);n&&(t[2]=n[1],t[3]=n[2],t[4]=n[3])}var r=Object(P.c)(_t(t[1]||pt,t[2]),2),i=r[0];return dt(r[1],i,t[3]?+t[3]:void 0,t[4]?+t[4]:void 0)}}],gt=/^\s*(.*?)(?:\((.*?)\))?(?:^|@)?((?:file|https?|blob|chrome|webpack|resource|moz-extension|capacitor).*?:\/.*?|\[native code\]|[^@]*(?:bundle|\d+\.js)|\/[\w\-. /=]+)(?::(\d+))?(?::(\d+))?\s*$/i,bt=/(\S+) line (\d+)(?: > eval line \d+)* > eval/i,vt=[50,function(e){var t,n=gt.exec(e);if(n){if(n[3]&&n[3].indexOf(" > eval")>-1){var r=bt.exec(n[3]);r&&(n[1]=n[1]||"eval",n[3]=r[1],n[4]=r[2],n[5]="")}var i=n[3],o=n[1]||pt;return o=(t=Object(P.c)(_t(o,i),2))[0],dt(i=t[1],o,n[4]?+n[4]:void 0,n[5]?+n[5]:void 0)}}],yt=/^\s*at (?:((?:\[object object\])?.+) )?\(?((?:file|ms-appx|https?|webpack|blob):.*?):(\d+)(?::(\d+))?\)?\s*$/i,xt=[40,function(e){var t=yt.exec(e);return t?dt(t[2],t[1]||pt,+t[3],t[4]?+t[4]:void 0):void 0}],wt=/ line (\d+).*script (?:in )?(\S+)(?:: in function (\S+))?$/i,jt=[10,function(e){var t=wt.exec(e);return t?dt(t[2],t[3]||pt,+t[1]):void 0}],Ot=/ line (\d+), column (\d+)\s*(?:in (?:<anonymous function: ([^>]+)>|([^)]+))\(.*\))? in (.*):\s*$/i,kt=[20,function(e){var t=Ot.exec(e);return t?dt(t[5],t[3]||t[4]||pt,+t[1],+t[2]):void 0}],_t=function(e,t){var n=-1!==e.indexOf("safari-extension"),r=-1!==e.indexOf("safari-web-extension");return n||r?[-1!==e.indexOf("@")?e.split("@")[0]:pt,n?"safari-extension:"+t:"safari-web-extension:"+t]:[e,t]};function St(e){var t=Et(e),n={type:e&&e.name,value:Nt(e)};return t.length&&(n.stacktrace={frames:t}),void 0===n.type&&""===n.value&&(n.value="Unrecoverable error caught"),n}function Pt(e){return{exception:{values:[St(e)]}}}function Et(e){var t=e.stacktrace||e.stack||"",n=function(e){if(e){if("number"===typeof e.framesToPop)return e.framesToPop;if(Ct.test(e.message))return 1}return 0}(e);try{return Object(ye.a)(jt,kt,mt,xt,vt)(t,n)}catch(r){}return[]}var Ct=/Minified React error #\d+;/i;function Nt(e){var t=e&&e.message;return t?t.error&&"string"===typeof t.error.message?t.error.message:t:"No error message"}function Tt(e,t,n,r){var i;if(Object(Y.e)(e)&&e.error)return Pt(e.error);if(Object(Y.a)(e)||Object(Y.b)(e)){var o=e;if("stack"in e)i=Pt(e);else{var a=o.name||(Object(Y.a)(o)?"DOMError":"DOMException"),l=o.message?a+": "+o.message:a;F(i=It(l,t,n),l)}return"code"in o&&(i.tags=Object(P.a)(Object(P.a)({},i.tags),{"DOMException.code":""+o.code})),i}return Object(Y.d)(e)?Pt(e):Object(Y.i)(e)||Object(Y.f)(e)?(i=function(e,t,n){var r={exception:{values:[{type:Object(Y.f)(e)?e.constructor.name:n?"UnhandledRejection":"Error",value:"Non-Error "+(n?"promise rejection":"exception")+" captured with keys: "+Object(C.d)(e)}]},extra:{__serialized__:Object($e.b)(e)}};if(t){var i=Et(t);i.length&&(r.stacktrace={frames:i})}return r}(e,t,r),D(i,{synthetic:!0}),i):(F(i=It(e,t,n),""+e,void 0),D(i,{synthetic:!0}),i)}function It(e,t,n){var r={message:e};if(n&&t){var i=Et(t);i.length&&(r.stacktrace={frames:i})}return r}function Lt(e){var t=[];function n(e){return t.splice(t.indexOf(e),1)[0]}return{$:t,add:function(r){if(!(void 0===e||t.length<e))return G(new Ue("Not adding Promise due to buffer limit reached."));var i=r();return-1===t.indexOf(i)&&t.push(i),i.then((function(){return n(i)})).then(null,(function(){return n(i).then(null,(function(){}))})),i},drain:function(e){return new J((function(n,r){var i=t.length;if(!i)return n(!0);var o=setTimeout((function(){e&&e>0&&n(!1)}),e);t.forEach((function(e){K(e).then((function(){--i||(clearTimeout(o),n(!0))}),r)}))}))}}}function Mt(e,t){return e[t]||e.all||0}function Ft(e,t,n){return void 0===n&&(n=Date.now()),Mt(e,t)>n}function Dt(e,t,n){var r,i,o,a;void 0===n&&(n=Date.now());var l=Object(P.a)({},e),s=t["x-sentry-rate-limits"],c=t["retry-after"];if(s)try{for(var u=Object(P.e)(s.trim().split(",")),p=u.next();!p.done;p=u.next()){var d=p.value.split(":",2),f=parseInt(d[0],10),h=1e3*(isNaN(f)?60:f);if(d[1])try{for(var m=(o=void 0,Object(P.e)(d[1].split(";"))),g=m.next();!g.done;g=m.next()){l[g.value]=n+h}}catch(b){o={error:b}}finally{try{g&&!g.done&&(a=m.return)&&a.call(m)}finally{if(o)throw o.error}}else l.all=n+h}}catch(v){r={error:v}}finally{try{p&&!p.done&&(i=u.return)&&i.call(u)}finally{if(r)throw r.error}}else c&&(l.all=n+function(e,t){void 0===t&&(t=Date.now());var n=parseInt(""+e,10);if(!isNaN(n))return 1e3*n;var r=Date.parse(""+e);return isNaN(r)?6e4:r-t}(c,n));return l}function zt(e){return e>=200&&e<300?"success":429===e?"rate_limit":e>=400&&e<500?"invalid":e>=500?"failed":"unknown"}function Rt(e,t,n){void 0===n&&(n=Lt(e.bufferSize||30));var r={};return{send:function(e){var i=function(e){var t=Object(P.c)(e,2),n=Object(P.c)(t[1],1);return Object(P.c)(n[0],1)[0].type}(e),o="event"===i?"error":i,a={category:o,body:it(e)};return Ft(r,o)?G({status:"rate_limit",reason:Ut(r,o)}):n.add((function(){return t(a).then((function(e){var t=e.body,n=e.headers,i=e.reason,a=zt(e.statusCode);return n&&(r=Dt(r,n)),"success"===a?K({status:a,reason:i}):G({status:a,reason:i||t||("rate_limit"===a?Ut(r,o):"Unknown transport error")})}))}))},flush:function(e){return n.drain(e)}}}function Ut(e,t){return"Too many "+t+" requests, backing off until: "+new Date(Mt(e,t)).toISOString()}var At,Bt="undefined"===typeof __SENTRY_DEBUG__||__SENTRY_DEBUG__,Ht=Object(E.a)();function qt(){if(At)return At;if(we(Ht.fetch))return At=Ht.fetch.bind(Ht);var e=Ht.document,t=Ht.fetch;if(e&&"function"===typeof e.createElement)try{var n=e.createElement("iframe");n.hidden=!0,e.head.appendChild(n);var r=n.contentWindow;r&&r.fetch&&(t=r.fetch),e.head.removeChild(n)}catch(i){Bt&&R.warn("Could not create sandbox iframe for pure fetch check, bailing to window.fetch: ",i)}return At=t.bind(Ht)}function $t(e,t){if("[object Navigator]"===Object.prototype.toString.call(Ht&&Ht.navigator)&&"function"===typeof Ht.navigator.sendBeacon)return Ht.navigator.sendBeacon.bind(Ht.navigator)(e,t);if(xe()){var n=qt();n(e,{body:t,method:"POST",credentials:"omit",keepalive:!0}).then(null,(function(e){console.error(e)}))}else;}function Wt(e){return"event"===e?"error":e}var Qt=Object(E.a)(),Vt=function(){function e(e){var t=this;this.options=e,this._buffer=Lt(30),this._rateLimits={},this._outcomes={},this._api=Ge(e.dsn,e._metadata,e.tunnel),this.url=tt(this._api.dsn),this.options.sendClientReports&&Qt.document&&Qt.document.addEventListener("visibilitychange",(function(){"hidden"===Qt.document.visibilityState&&t._flushOutcomes()}))}return e.prototype.sendEvent=function(e){return this._sendRequest(function(e,t){var n,r=ot(t),i=e.type||"event",o="transaction"===i||!!t.tunnel,a=(e.sdkProcessingMetadata||{}).transactionSampling||{},l=a.method,s=a.rate;at(e,t.metadata.sdk),e.tags=e.tags||{},e.extra=e.extra||{},e.sdkProcessingMetadata&&e.sdkProcessingMetadata.baseClientNormalized||(e.tags.skippedNormalization=!0,e.extra.normalizeDepth=e.sdkProcessingMetadata?e.sdkProcessingMetadata.normalizeDepth:"unset"),delete e.sdkProcessingMetadata;try{n=JSON.stringify(e)}catch(d){e.tags.JSONStringifyError=!0,e.extra.JSONStringifyError=d;try{n=JSON.stringify(Object($e.a)(e))}catch(f){var c=f;n=JSON.stringify({message:"JSON.stringify error after renormalization",extra:{message:c.message,stack:c.stack}})}}var u={body:n,type:i,url:o?nt(t.dsn,t.tunnel):tt(t.dsn)};if(o){var p=rt(Object(P.a)(Object(P.a)({event_id:e.event_id,sent_at:(new Date).toISOString()},r&&{sdk:r}),!!t.tunnel&&{dsn:Be(t.dsn)}),[[{type:i,sample_rates:[{id:l,rate:s}]},u.body]]);u.body=it(p)}return u}(e,this._api),e)},e.prototype.sendSession=function(e){return this._sendRequest(function(e,t){var n=Object(P.c)(lt(e,t),2),r=n[0],i=n[1];return{body:it(r),type:i,url:nt(t.dsn,t.tunnel)}}(e,this._api),e)},e.prototype.close=function(e){return this._buffer.drain(e)},e.prototype.recordLostEvent=function(e,t){var n;if(this.options.sendClientReports){var r=Wt(t)+":"+e;Bt&&R.log("Adding outcome: "+r),this._outcomes[r]=(null!==(n=this._outcomes[r])&&void 0!==n?n:0)+1}},e.prototype._flushOutcomes=function(){if(this.options.sendClientReports){var e=this._outcomes;if(this._outcomes={},Object.keys(e).length){Bt&&R.log("Flushing outcomes:\n"+JSON.stringify(e,null,2));var t,n,r,i=nt(this._api.dsn,this._api.tunnel),o=Object.keys(e).map((function(t){var n=Object(P.c)(t.split(":"),2),r=n[0];return{reason:n[1],category:r,quantity:e[t]}})),a=(t=o,rt((n=this._api.tunnel&&Be(this._api.dsn))?{dsn:n}:{},[[{type:"client_report"},{timestamp:r||Object(U.a)(),discarded_events:t}]]));try{$t(i,it(a))}catch(l){Bt&&R.error(l)}}else Bt&&R.log("No outcomes to flush")}},e.prototype._handleResponse=function(e){var t=e.requestType,n=e.response,r=e.headers,i=e.resolve,o=e.reject,a=zt(n.status);this._rateLimits=Dt(this._rateLimits,r),this._isRateLimited(t)&&Bt&&R.warn("Too many "+t+" requests, backing off until: "+this._disabledUntil(t)),"success"!==a?o(n):i({status:a})},e.prototype._disabledUntil=function(e){var t=Wt(e);return new Date(Mt(this._rateLimits,t))},e.prototype._isRateLimited=function(e){var t=Wt(e);return Ft(this._rateLimits,t)},e}(),Yt=function(e){function t(t,n){void 0===n&&(n=qt());var r=e.call(this,t)||this;return r._fetch=n,r}return Object(P.b)(t,e),t.prototype._sendRequest=function(e,t){var n=this;if(this._isRateLimited(e.type))return this.recordLostEvent("ratelimit_backoff",e.type),Promise.reject({event:t,type:e.type,reason:"Transport for "+e.type+" requests locked till "+this._disabledUntil(e.type)+" due to too many requests.",status:429});var r={body:e.body,method:"POST",referrerPolicy:je()?"origin":""};return void 0!==this.options.fetchParameters&&Object.assign(r,this.options.fetchParameters),void 0!==this.options.headers&&(r.headers=this.options.headers),this._buffer.add((function(){return new J((function(t,i){n._fetch(e.url,r).then((function(r){var o={"x-sentry-rate-limits":r.headers.get("X-Sentry-Rate-Limits"),"retry-after":r.headers.get("Retry-After")};n._handleResponse({requestType:e.type,response:r,headers:o,resolve:t,reject:i})})).catch(i)}))})).then(void 0,(function(t){throw t instanceof Ue?n.recordLostEvent("queue_overflow",e.type):n.recordLostEvent("network_error",e.type),t}))},t}(Vt);var Kt=function(e){function t(){return null!==e&&e.apply(this,arguments)||this}return Object(P.b)(t,e),t.prototype._sendRequest=function(e,t){var n=this;return this._isRateLimited(e.type)?(this.recordLostEvent("ratelimit_backoff",e.type),Promise.reject({event:t,type:e.type,reason:"Transport for "+e.type+" requests locked till "+this._disabledUntil(e.type)+" due to too many requests.",status:429})):this._buffer.add((function(){return new J((function(t,r){var i=new XMLHttpRequest;for(var o in i.onreadystatechange=function(){if(4===i.readyState){var o={"x-sentry-rate-limits":i.getResponseHeader("X-Sentry-Rate-Limits"),"retry-after":i.getResponseHeader("Retry-After")};n._handleResponse({requestType:e.type,response:i,headers:o,resolve:t,reject:r})}},i.open("POST",e.url),n.options.headers)Object.prototype.hasOwnProperty.call(n.options.headers,o)&&i.setRequestHeader(o,n.options.headers[o]);i.send(e.body)}))})).then(void 0,(function(t){throw t instanceof Ue?n.recordLostEvent("queue_overflow",e.type):n.recordLostEvent("network_error",e.type),t}))},t}(Vt),Gt=function(e){function t(){return null!==e&&e.apply(this,arguments)||this}return Object(P.b)(t,e),t.prototype.eventFromException=function(e,t){return function(e,t,n){var r=Tt(e,t&&t.syntheticException||void 0,n);return D(r),r.level=st.Error,t&&t.event_id&&(r.event_id=t.event_id),K(r)}(e,t,this._options.attachStacktrace)},t.prototype.eventFromMessage=function(e,t,n){return void 0===t&&(t=st.Info),function(e,t,n,r){void 0===t&&(t=st.Info);var i=It(e,n&&n.syntheticException||void 0,r);return i.level=t,n&&n.event_id&&(i.event_id=n.event_id),K(i)}(e,t,n,this._options.attachStacktrace)},t.prototype._setupTransport=function(){if(!this._options.dsn)return e.prototype._setupTransport.call(this);var t,n,r=Object(P.a)(Object(P.a)({},this._options.transportOptions),{dsn:this._options.dsn,tunnel:this._options.tunnel,sendClientReports:this._options.sendClientReports,_metadata:this._options._metadata}),i=Ge(r.dsn,r._metadata,r.tunnel),o=nt(i.dsn,i.tunnel);if(this._options.transport)return new this._options.transport(r);if(xe()){var a=Object(P.a)({},r.fetchParameters);return this._newTransport=(t={requestOptions:a,url:o},void 0===n&&(n=qt()),Rt({bufferSize:t.bufferSize},(function(e){var r=Object(P.a)({body:e.body,method:"POST",referrerPolicy:"origin"},t.requestOptions);return n(t.url,r).then((function(e){return e.text().then((function(t){return{body:t,headers:{"x-sentry-rate-limits":e.headers.get("X-Sentry-Rate-Limits"),"retry-after":e.headers.get("Retry-After")},reason:e.statusText,statusCode:e.status}}))}))}))),new Yt(r)}return this._newTransport=function(e){return Rt({bufferSize:e.bufferSize},(function(t){return new J((function(n,r){var i=new XMLHttpRequest;for(var o in i.onreadystatechange=function(){if(4===i.readyState){var e={body:i.response,headers:{"x-sentry-rate-limits":i.getResponseHeader("X-Sentry-Rate-Limits"),"retry-after":i.getResponseHeader("Retry-After")},reason:i.statusText,statusCode:i.status};n(e)}},i.open("POST",e.url),e.headers)Object.prototype.hasOwnProperty.call(e.headers,o)&&i.setRequestHeader(o,e.headers[o]);i.send(t.body)}))}))}({url:o,headers:r.headers}),new Kt(r)},t}(ut),Jt=Object(E.a)(),Xt=0;function Zt(){return Xt>0}function en(){Xt+=1,setTimeout((function(){Xt-=1}))}function tn(e,t,n){if(void 0===t&&(t={}),"function"!==typeof e)return e;try{var r=e.__sentry_wrapped__;if(r)return r;if(Object(C.f)(e))return e}catch(a){return e}var i=function(){var r=Array.prototype.slice.call(arguments);try{n&&"function"===typeof n&&n.apply(this,arguments);var i=r.map((function(e){return tn(e,t)}));return e.apply(this,i)}catch(o){throw en(),de((function(e){e.addEventProcessor((function(e){return t.mechanism&&(F(e,void 0,void 0),D(e,t.mechanism)),e.extra=Object(P.a)(Object(P.a)({},e.extra),{arguments:r}),e})),pe(o)})),o}};try{for(var o in e)Object.prototype.hasOwnProperty.call(e,o)&&(i[o]=e[o])}catch(l){}Object(C.g)(i,e),Object(C.a)(e,"__sentry_wrapped__",i);try{Object.getOwnPropertyDescriptor(i,"name").configurable&&Object.defineProperty(i,"name",{get:function(){return e.name}})}catch(l){}return i}function nn(e){if(void 0===e&&(e={}),Jt.document)if(e.eventId)if(e.dsn){var t=Jt.document.createElement("script");t.async=!0,t.src=function(e,t){var n=qe(e),r=Je(n)+"embed/error-page/",i="dsn="+Be(n);for(var o in t)if("dsn"!==o)if("user"===o){if(!t.user)continue;t.user.name&&(i+="&name="+encodeURIComponent(t.user.name)),t.user.email&&(i+="&email="+encodeURIComponent(t.user.email))}else i+="&"+encodeURIComponent(o)+"="+encodeURIComponent(t[o]);return r+"?"+i}(e.dsn,e),e.onLoad&&(t.onload=e.onLoad);var n=Jt.document.head||Jt.document.body;n&&n.appendChild(t)}else Bt&&R.error("Missing dsn option in showReportDialog call");else Bt&&R.error("Missing eventId option in showReportDialog call")}var rn=n(31),on=["fatal","error","warning","log","info","debug","critical"];function an(e){return"warn"===e?st.Warning:function(e){return-1!==on.indexOf(e)}(e)?e:st.Log}var ln=function(){function e(t){this.name=e.id,this._options=Object(P.a)({console:!0,dom:!0,fetch:!0,history:!0,sentry:!0,xhr:!0},t)}return e.prototype.addSentryBreadcrumb=function(e){this._options.sentry&&ae().addBreadcrumb({category:"sentry."+("transaction"===e.type?"transaction":"event"),event_id:e.event_id,level:e.level,message:M(e)},{event:e})},e.prototype.setupOnce=function(){this._options.console&&Ee("console",sn),this._options.dom&&Ee("dom",function(e){function t(t){var n,r="object"===typeof e?e.serializeAttribute:void 0;"string"===typeof r&&(r=[r]);try{n=t.event.target?Object(rn.b)(t.event.target,r):Object(rn.b)(t.event,r)}catch(i){n="<unknown>"}0!==n.length&&ae().addBreadcrumb({category:"ui."+t.name,message:n},{event:t.event,name:t.name,global:t.global})}return t}(this._options.dom)),this._options.xhr&&Ee("xhr",cn),this._options.fetch&&Ee("fetch",un),this._options.history&&Ee("history",pn)},e.id="Breadcrumbs",e}();function sn(e){var t={category:"console",data:{arguments:e.args,logger:"console"},level:an(e.level),message:Object(N.b)(e.args," ")};if("assert"===e.level){if(!1!==e.args[0])return;t.message="Assertion failed: "+(Object(N.b)(e.args.slice(1)," ")||"console.assert"),t.data.arguments=e.args.slice(1)}ae().addBreadcrumb(t,{input:e.args,level:e.level})}function cn(e){if(e.endTimestamp){if(e.xhr.__sentry_own_request__)return;var t=e.xhr.__sentry_xhr__||{},n=t.method,r=t.url,i=t.status_code,o=t.body;ae().addBreadcrumb({category:"xhr",data:{method:n,url:r,status_code:i},type:"http"},{xhr:e.xhr,input:o})}else;}function un(e){e.endTimestamp&&(e.fetchData.url.match(/sentry_key/)&&"POST"===e.fetchData.method||(e.error?ae().addBreadcrumb({category:"fetch",data:e.fetchData,level:st.Error,type:"http"},{data:e.error,input:e.args}):ae().addBreadcrumb({category:"fetch",data:Object(P.a)(Object(P.a)({},e.fetchData),{status_code:e.response.status}),type:"http"},{input:e.args,response:e.response})))}function pn(e){var t=Object(E.a)(),n=e.from,r=e.to,i=I(t.location.href),o=I(n),a=I(r);o.path||(o=i),i.protocol===a.protocol&&i.host===a.host&&(r=a.relative),i.protocol===o.protocol&&i.host===o.host&&(n=o.relative),ae().addBreadcrumb({category:"navigation",data:{from:n,to:r}})}var dn=function(e){function t(t){void 0===t&&(t={});return t._metadata=t._metadata||{},t._metadata.sdk=t._metadata.sdk||{name:"sentry.javascript.browser",packages:[{name:"npm:@sentry/browser",version:ze}],version:ze},e.call(this,Gt,t)||this}return Object(P.b)(t,e),t.prototype.showReportDialog=function(e){void 0===e&&(e={}),Object(E.a)().document&&(this._isEnabled()?nn(Object(P.a)(Object(P.a)({},e),{dsn:e.dsn||this.getDsn()})):Bt&&R.error("Trying to call showReportDialog with Sentry Client disabled"))},t.prototype._prepareEvent=function(t,n,r){return t.platform=t.platform||"javascript",e.prototype._prepareEvent.call(this,t,n,r)},t.prototype._sendEvent=function(t){var n=this.getIntegration(ln);n&&n.addSentryBreadcrumb(t),e.prototype._sendEvent.call(this,t)},t}(Ke),fn=["EventTarget","Window","Node","ApplicationCache","AudioTrackList","ChannelMergerNode","CryptoOperation","EventSource","FileReader","HTMLUnknownElement","IDBDatabase","IDBRequest","IDBTransaction","KeyOperation","MediaController","MessagePort","ModalWindow","Notification","SVGElementInstance","Screen","TextTrack","TextTrackCue","TextTrackList","WebSocket","WebSocketWorker","Worker","XMLHttpRequest","XMLHttpRequestEventTarget","XMLHttpRequestUpload"],hn=function(){function e(t){this.name=e.id,this._options=Object(P.a)({XMLHttpRequest:!0,eventTarget:!0,requestAnimationFrame:!0,setInterval:!0,setTimeout:!0},t)}return e.prototype.setupOnce=function(){var e=Object(E.a)();this._options.setTimeout&&Object(C.e)(e,"setTimeout",mn),this._options.setInterval&&Object(C.e)(e,"setInterval",mn),this._options.requestAnimationFrame&&Object(C.e)(e,"requestAnimationFrame",gn),this._options.XMLHttpRequest&&"XMLHttpRequest"in e&&Object(C.e)(XMLHttpRequest.prototype,"send",bn);var t=this._options.eventTarget;t&&(Array.isArray(t)?t:fn).forEach(vn)},e.id="TryCatch",e}();function mn(e){return function(){for(var t=[],n=0;n<arguments.length;n++)t[n]=arguments[n];var r=t[0];return t[0]=tn(r,{mechanism:{data:{function:Object(ye.b)(e)},handled:!0,type:"instrument"}}),e.apply(this,t)}}function gn(e){return function(t){return e.apply(this,[tn(t,{mechanism:{data:{function:"requestAnimationFrame",handler:Object(ye.b)(e)},handled:!0,type:"instrument"}})])}}function bn(e){return function(){for(var t=[],n=0;n<arguments.length;n++)t[n]=arguments[n];var r=this,i=["onload","onerror","onprogress","onreadystatechange"];return i.forEach((function(e){e in r&&"function"===typeof r[e]&&Object(C.e)(r,e,(function(t){var n={mechanism:{data:{function:e,handler:Object(ye.b)(t)},handled:!0,type:"instrument"}},r=Object(C.f)(t);return r&&(n.mechanism.data.handler=Object(ye.b)(r)),tn(t,n)}))})),e.apply(this,t)}}function vn(e){var t=Object(E.a)(),n=t[e]&&t[e].prototype;n&&n.hasOwnProperty&&n.hasOwnProperty("addEventListener")&&(Object(C.e)(n,"addEventListener",(function(t){return function(n,r,i){try{"function"===typeof r.handleEvent&&(r.handleEvent=tn(r.handleEvent.bind(r),{mechanism:{data:{function:"handleEvent",handler:Object(ye.b)(r),target:e},handled:!0,type:"instrument"}}))}catch(o){}return t.apply(this,[n,tn(r,{mechanism:{data:{function:"addEventListener",handler:Object(ye.b)(r),target:e},handled:!0,type:"instrument"}}),i])}})),Object(C.e)(n,"removeEventListener",(function(e){return function(t,n,r){var i=n;try{var o=i&&i.__sentry_wrapped__;o&&e.call(this,t,o,r)}catch(a){}return e.call(this,t,i,r)}})))}var yn=function(){function e(t){this.name=e.id,this._installFunc={onerror:xn,onunhandledrejection:wn},this._options=Object(P.a)({onerror:!0,onunhandledrejection:!0},t)}return e.prototype.setupOnce=function(){Error.stackTraceLimit=50;var e,t=this._options;for(var n in t){var r=this._installFunc[n];r&&t[n]&&(e=n,Bt&&R.log("Global Handler attached: "+e),r(),this._installFunc[n]=void 0)}},e.id="GlobalHandlers",e}();function xn(){Ee("error",(function(e){var t=Object(P.c)(kn(),2),n=t[0],r=t[1];if(n.getIntegration(yn)){var i=e.msg,o=e.url,a=e.line,l=e.column,s=e.error;if(!(Zt()||s&&s.__sentry_own_request__)){var c=void 0===s&&Object(Y.l)(i)?function(e,t,n,r){var i=/^(?:[Uu]ncaught (?:exception: )?)?(?:((?:Eval|Internal|Range|Reference|Syntax|Type|URI|)Error): )?(.*)$/i,o=Object(Y.e)(e)?e.message:e,a="Error",l=o.match(i);l&&(a=l[1],o=l[2]);return jn({exception:{values:[{type:a,value:o}]}},t,n,r)}(i,o,a,l):jn(Tt(s||i,void 0,r,!1),o,a,l);c.level=st.Error,On(n,s,c,"onerror")}}}))}function wn(){Ee("unhandledrejection",(function(e){var t=Object(P.c)(kn(),2),n=t[0],r=t[1];if(n.getIntegration(yn)){var i=e;try{"reason"in e?i=e.reason:"detail"in e&&"reason"in e.detail&&(i=e.detail.reason)}catch(a){}if(Zt()||i&&i.__sentry_own_request__)return!0;var o=Object(Y.j)(i)?{exception:{values:[{type:"UnhandledRejection",value:"Non-Error promise rejection captured with value: "+String(i)}]}}:Tt(i,void 0,r,!0);o.level=st.Error,On(n,i,o,"onunhandledrejection")}}))}function jn(e,t,n,r){var i=e.exception=e.exception||{},o=i.values=i.values||[],a=o[0]=o[0]||{},l=a.stacktrace=a.stacktrace||{},s=l.frames=l.frames||[],c=isNaN(parseInt(r,10))?void 0:r,u=isNaN(parseInt(n,10))?void 0:n,p=Object(Y.l)(t)&&t.length>0?t:Object(rn.a)();return 0===s.length&&s.push({colno:c,filename:p,function:"?",in_app:!0,lineno:u}),e}function On(e,t,n,r){D(n,{handled:!1,type:r}),e.captureEvent(n,{originalException:t})}function kn(){var e=ae(),t=e.getClient();return[e,t&&t.getOptions().attachStacktrace]}var _n=function(){function e(t){void 0===t&&(t={}),this.name=e.id,this._key=t.key||"cause",this._limit=t.limit||5}return e.prototype.setupOnce=function(){ee((function(t,n){var r=ae().getIntegration(e);return r?function(e,t,n,r){if(!n.exception||!n.exception.values||!r||!Object(Y.g)(r.originalException,Error))return n;var i=Sn(t,r.originalException,e);return n.exception.values=Object(P.d)(i,n.exception.values),n}(r._key,r._limit,t,n):t}))},e.id="LinkedErrors",e}();function Sn(e,t,n,r){if(void 0===r&&(r=[]),!Object(Y.g)(t[n],Error)||r.length+1>=e)return r;var i=St(t[n]);return Sn(e,t[n],n,Object(P.d)([i],r))}var Pn=function(){function e(){this.name=e.id}return e.prototype.setupOnce=function(t,n){t((function(t){var r=n().getIntegration(e);if(r){try{if(function(e,t){if(!t)return!1;if(function(e,t){var n=e.message,r=t.message;if(!n&&!r)return!1;if(n&&!r||!n&&r)return!1;if(n!==r)return!1;if(!Cn(e,t))return!1;if(!En(e,t))return!1;return!0}(e,t))return!0;if(function(e,t){var n=Nn(t),r=Nn(e);if(!n||!r)return!1;if(n.type!==r.type||n.value!==r.value)return!1;if(!Cn(e,t))return!1;if(!En(e,t))return!1;return!0}(e,t))return!0;return!1}(t,r._previousEvent))return Bt&&R.warn("Event dropped due to being a duplicate of previously captured event."),null}catch(i){return r._previousEvent=t}return r._previousEvent=t}return t}))},e.id="Dedupe",e}();function En(e,t){var n=Tn(e),r=Tn(t);if(!n&&!r)return!0;if(n&&!r||!n&&r)return!1;if(n=n,(r=r).length!==n.length)return!1;for(var i=0;i<r.length;i++){var o=r[i],a=n[i];if(o.filename!==a.filename||o.lineno!==a.lineno||o.colno!==a.colno||o.function!==a.function)return!1}return!0}function Cn(e,t){var n=e.fingerprint,r=t.fingerprint;if(!n&&!r)return!0;if(n&&!r||!n&&r)return!1;n=n,r=r;try{return!(n.join("")!==r.join(""))}catch(i){return!1}}function Nn(e){return e.exception&&e.exception.values&&e.exception.values[0]}function Tn(e){var t=e.exception;if(t)try{return t.values[0].stacktrace.frames}catch(n){return}else if(e.stacktrace)return e.stacktrace.frames}var In=Object(E.a)(),Ln=function(){function e(){this.name=e.id}return e.prototype.setupOnce=function(){ee((function(t){if(ae().getIntegration(e)){if(!In.navigator&&!In.location&&!In.document)return t;var n=t.request&&t.request.url||In.location&&In.location.href,r=(In.document||{}).referrer,i=(In.navigator||{}).userAgent,o=Object(P.a)(Object(P.a)(Object(P.a)({},t.request&&t.request.headers),r&&{Referer:r}),i&&{"User-Agent":i}),a=Object(P.a)(Object(P.a)({},n&&{url:n}),{headers:o});return Object(P.a)(Object(P.a)({},t),{request:a})}return t}))},e.id="UserAgent",e}(),Mn=[new r.InboundFilters,new r.FunctionToString,new hn,new ln,new yn,new _n,new Pn,new Ln];function Fn(e){if(void 0===e&&(e={}),void 0===e.defaultIntegrations&&(e.defaultIntegrations=Mn),void 0===e.release){var t=Object(E.a)();t.SENTRY_RELEASE&&t.SENTRY_RELEASE.id&&(e.release=t.SENTRY_RELEASE.id)}void 0===e.autoSessionTracking&&(e.autoSessionTracking=!0),void 0===e.sendClientReports&&(e.sendClientReports=!0),function(e,t){!0===t.debug&&(he?R.enable():console.warn("[Sentry] Cannot initialize SDK with `debug` option using a non-debug bundle."));var n=ae(),r=n.getScope();r&&r.update(t.initialScope);var i=new e(t);n.bindClient(i)}(dn,e),e.autoSessionTracking&&function(){if("undefined"===typeof Object(E.a)().document)return void(Bt&&R.warn("Session tracking in non-browser environment with @sentry/browser is not supported."));var e=ae();if(!e.captureSession)return;Dn(e),Ee("history",(function(e){var t=e.from,n=e.to;void 0!==t&&t!==n&&Dn(ae())}))}()}function Dn(e){e.startSession({ignoreDuration:!0}),e.captureSession()}n(28);var zn="undefined"===typeof __SENTRY_DEBUG__||__SENTRY_DEBUG__;var Rn={componentStack:null,error:null,eventId:null},Un=function(e){function t(){var t=null!==e&&e.apply(this,arguments)||this;return t.state=Rn,t.resetErrorBoundary=function(){var e=t.props.onReset,n=t.state,r=n.error,i=n.componentStack,o=n.eventId;e&&e(r,i,o),t.setState(Rn)},t}return Object(P.b)(t,e),t.prototype.componentDidCatch=function(e,t){var n=this,r=t.componentStack,o=this.props,a=o.beforeCapture,l=o.onError,s=o.showDialog,c=o.dialogOptions;de((function(t){if(function(e){var t=e.match(/^([^.]+)/);return null!==t&&parseInt(t[0])>=17}(i.version)){var o=new Error(e.message);o.name="React ErrorBoundary "+o.name,o.stack=r,e.cause=o}a&&a(t,e,r);var u=pe(e,{contexts:{react:{componentStack:r}}});l&&l(e,r,u),s&&function(e){void 0===e&&(e={});var t=ae(),n=t.getScope();n&&(e.user=Object(P.a)(Object(P.a)({},n.getUser()),e.user)),e.eventId||(e.eventId=t.lastEventId());var r=t.getClient();r&&r.showReportDialog(e)}(Object(P.a)(Object(P.a)({},c),{eventId:u})),n.setState({error:e,componentStack:r,eventId:u})}))},t.prototype.componentDidMount=function(){var e=this.props.onMount;e&&e()},t.prototype.componentWillUnmount=function(){var e=this.state,t=e.error,n=e.componentStack,r=e.eventId,i=this.props.onUnmount;i&&i(t,n,r)},t.prototype.render=function(){var e=this.props,t=e.fallback,n=e.children,r=this.state,o=r.error,a=r.componentStack,l=r.eventId;if(o){var s=void 0;return s="function"===typeof t?t({error:o,componentStack:a,resetError:this.resetErrorBoundary,eventId:l}):t,i.isValidElement(s)?s:(t&&zn&&R.warn("fallback did not produce a valid ReactElement"),null)}return"function"===typeof n?n():n},t}(i.Component);var An,Bn,Hn,qn,$n=n(0),Wn=["children","head","title","style"],Qn=function(e){v(n,e);var t=O(n);function n(){var e;h(this,n);for(var r=arguments.length,i=new Array(r),o=0;o<r;o++)i[o]=arguments[o];return(e=t.call.apply(t,[this].concat(i))).handleLoad=function(){e.setupFrameBaseStyle()},e}return g(n,[{key:"componentDidMount",value:function(){this.node.addEventListener("load",this.handleLoad)}},{key:"componentWillUnmout",value:function(){this.node.removeEventListener("load",this.handleLoad)}},{key:"setupFrameBaseStyle",value:function(){this.node.contentDocument&&(this.iframeHtml=this.node.contentDocument.documentElement,this.iframeHead=this.node.contentDocument.head,this.iframeRoot=this.node.contentDocument.body,this.forceUpdate())}},{key:"render",value:function(){var e=this,t=this.props,n=t.children,r=t.head,i=t.title,o=void 0===i?"":i,l=t.style,s=void 0===l?{}:l,c=p(t,Wn);return Object($n.jsxs)("iframe",Object(k.a)(Object(k.a)({srcDoc:"<!DOCTYPE html>"},c),{},{ref:function(t){return e.node=t},title:o,style:s,frameBorder:"0",children:[this.iframeHead&&Object(a.createPortal)(r,this.iframeHead),this.iframeRoot&&Object(a.createPortal)(n,this.iframeRoot)]}))}}]),n}(i.Component),Vn=["title","titleId"];function Yn(){return Yn=Object.assign||function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(e[r]=n[r])}return e},Yn.apply(this,arguments)}function Kn(e,t){if(null==e)return{};var n,r,i=function(e,t){if(null==e)return{};var n,r,i={},o=Object.keys(e);for(r=0;r<o.length;r++)n=o[r],t.indexOf(n)>=0||(i[n]=e[n]);return i}(e,t);if(Object.getOwnPropertySymbols){var o=Object.getOwnPropertySymbols(e);for(r=0;r<o.length;r++)n=o[r],t.indexOf(n)>=0||Object.prototype.propertyIsEnumerable.call(e,n)&&(i[n]=e[n])}return i}function Gn(e,t){var n=e.title,r=e.titleId,o=Kn(e,Vn);return i.createElement("svg",Yn({id:"Regular",xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24",ref:t,"aria-labelledby":r},o),n?i.createElement("title",{id:r},n):null,An||(An=i.createElement("defs",null,i.createElement("style",null,".cls-1{fill:none;stroke:currentColor;stroke-linecap:round;stroke-linejoin:round;stroke-width:0.8px;}"))),Bn||(Bn=i.createElement("circle",{className:"cls-1",cx:12,cy:9.75,r:5.25})),Hn||(Hn=i.createElement("path",{className:"cls-1",d:"M18.913,20.876a9.746,9.746,0,0,0-13.826,0"})),qn||(qn=i.createElement("circle",{className:"cls-1",cx:12,cy:12,r:11.25})))}var Jn=i.forwardRef(Gn),Xn=(n.p,"\n .gh-portal-avatar {\n position: relative;\n display: flex;\n align-items: center;\n justify-content: center;\n overflow: hidden;\n margin: 0 0 8px 0;\n border-radius: 999px;\n }\n\n .gh-portal-avatar img {\n position: absolute;\n display: block;\n top: -2px;\n right: -2px;\n bottom: -2px;\n left: -2px;\n width: calc(100% + 4px);\n height: calc(100% + 4px);\n opacity: 1;\n max-width: unset;\n }\n");var Zn,er=function(e){var t=e.gravatar,n=function(e){var t=e.style,n=void 0===t?{}:t;return{avatarContainer:Object(k.a)({},n.avatarContainer||{}),gravatar:Object(k.a)({},n.avatarContainer||{}),userIcon:Object(k.a)({width:"34px",height:"34px",color:"#fff"},n.userIcon||{})}}({style:e.style});return Object($n.jsxs)("figure",{className:"gh-portal-avatar",style:n.avatarContainer,children:[Object($n.jsx)(Jn,{style:n.userIcon}),t?Object($n.jsx)("img",{style:n.gravatar,src:t,alt:""}):null]})},tr=n(1).createContext({site:{},member:{},action:"",lastPage:"",brandColor:"",pageData:{},onAction:function(e,t){return{action:e,data:t}}}),nr=["title","titleId"];function rr(){return rr=Object.assign||function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(e[r]=n[r])}return e},rr.apply(this,arguments)}function ir(e,t){if(null==e)return{};var n,r,i=function(e,t){if(null==e)return{};var n,r,i={},o=Object.keys(e);for(r=0;r<o.length;r++)n=o[r],t.indexOf(n)>=0||(i[n]=e[n]);return i}(e,t);if(Object.getOwnPropertySymbols){var o=Object.getOwnPropertySymbols(e);for(r=0;r<o.length;r++)n=o[r],t.indexOf(n)>=0||Object.prototype.propertyIsEnumerable.call(e,n)&&(i[n]=e[n])}return i}function or(e,t){var n=e.title,r=e.titleId,o=ir(e,nr);return i.createElement("svg",rr({width:21,height:24,viewBox:"0 0 21 24",fill:"none",xmlns:"http://www.w3.org/2000/svg",ref:t,"aria-labelledby":r},o),n?i.createElement("title",{id:r},n):null,Zn||(Zn=i.createElement("path",{d:"M10.533 11.267c2.835 0 5.134-2.299 5.134-5.134C15.667 3.298 13.368 1 10.533 1 7.698 1 5.4 3.298 5.4 6.133s2.298 5.134 5.133 5.134zM1 23c0-2.529 1.004-4.953 2.792-6.741 1.788-1.788 4.213-2.792 6.741-2.792 2.529 0 4.954 1.004 6.741 2.792 1.788 1.788 2.793 4.212 2.793 6.74",stroke:"#fff",strokeWidth:1.5,strokeLinecap:"round",strokeLinejoin:"round"})))}var ar,lr=i.forwardRef(or),sr=(n.p,["title","titleId"]);function cr(){return cr=Object.assign||function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(e[r]=n[r])}return e},cr.apply(this,arguments)}function ur(e,t){if(null==e)return{};var n,r,i=function(e,t){if(null==e)return{};var n,r,i={},o=Object.keys(e);for(r=0;r<o.length;r++)n=o[r],t.indexOf(n)>=0||(i[n]=e[n]);return i}(e,t);if(Object.getOwnPropertySymbols){var o=Object.getOwnPropertySymbols(e);for(r=0;r<o.length;r++)n=o[r],t.indexOf(n)>=0||Object.prototype.propertyIsEnumerable.call(e,n)&&(i[n]=e[n])}return i}function pr(e,t){var n=e.title,r=e.titleId,o=ur(e,sr);return i.createElement("svg",cr({width:24,height:24,viewBox:"0 0 24 24",xmlns:"http://www.w3.org/2000/svg",ref:t,"aria-labelledby":r},o),n?i.createElement("title",{id:r},n):null,ar||(ar=i.createElement("g",{fill:"none",fillRule:"evenodd"},i.createElement("path",{stroke:"#FFF",strokeWidth:1.5,strokeLinecap:"round",d:"M12.5 2v20M2 12.5h20"}))))}var dr,fr,hr=i.forwardRef(pr),mr=(n.p,["title","titleId"]);function gr(){return gr=Object.assign||function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(e[r]=n[r])}return e},gr.apply(this,arguments)}function br(e,t){if(null==e)return{};var n,r,i=function(e,t){if(null==e)return{};var n,r,i={},o=Object.keys(e);for(r=0;r<o.length;r++)n=o[r],t.indexOf(n)>=0||(i[n]=e[n]);return i}(e,t);if(Object.getOwnPropertySymbols){var o=Object.getOwnPropertySymbols(e);for(r=0;r<o.length;r++)n=o[r],t.indexOf(n)>=0||Object.prototype.propertyIsEnumerable.call(e,n)&&(i[n]=e[n])}return i}function vr(e,t){var n=e.title,r=e.titleId,o=br(e,mr);return i.createElement("svg",gr({width:25,height:24,viewBox:"0 0 25 24",fill:"none",xmlns:"http://www.w3.org/2000/svg",ref:t,"aria-labelledby":r},o),n?i.createElement("title",{id:r},n):null,dr||(dr=i.createElement("path",{d:"M23.5 6v14.25c0 .597-.237 1.169-.659 1.591-.422.422-.994.659-1.591.659s-1.169-.237-1.591-.659c-.422-.422-.659-.994-.659-1.591V3c0-.398-.158-.78-.44-1.06-.28-.282-.662-.44-1.06-.44h-15c-.398 0-.78.158-1.06.44C1.157 2.22 1 2.601 1 3v17.25c0 .597.237 1.169.659 1.591.422.422.994.659 1.591.659h18M4.75 15h10.5M4.75 18h6",stroke:"#fff",strokeWidth:1.5,strokeLinecap:"round",strokeLinejoin:"round"})),fr||(fr=i.createElement("path",{d:"M14.5 5.25h-9c-.414 0-.75.336-.75.75v4.5c0 .414.336.75.75.75h9c.414 0 .75-.336.75-.75V6c0-.414-.336-.75-.75-.75z",stroke:"#fff",strokeWidth:1.5,strokeLinecap:"round",strokeLinejoin:"round"})))}var yr,xr,wr=i.forwardRef(vr),jr=(n.p,["title","titleId"]);function Or(){return Or=Object.assign||function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(e[r]=n[r])}return e},Or.apply(this,arguments)}function kr(e,t){if(null==e)return{};var n,r,i=function(e,t){if(null==e)return{};var n,r,i={},o=Object.keys(e);for(r=0;r<o.length;r++)n=o[r],t.indexOf(n)>=0||(i[n]=e[n]);return i}(e,t);if(Object.getOwnPropertySymbols){var o=Object.getOwnPropertySymbols(e);for(r=0;r<o.length;r++)n=o[r],t.indexOf(n)>=0||Object.prototype.propertyIsEnumerable.call(e,n)&&(i[n]=e[n])}return i}function _r(e,t){var n=e.title,r=e.titleId,o=kr(e,jr);return i.createElement("svg",Or({width:24,height:18,viewBox:"0 0 24 18",fill:"none",xmlns:"http://www.w3.org/2000/svg",ref:t,"aria-labelledby":r},o),n?i.createElement("title",{id:r},n):null,yr||(yr=i.createElement("path",{d:"M21.75 1.5H2.25c-.828 0-1.5.672-1.5 1.5v12c0 .828.672 1.5 1.5 1.5h19.5c.828 0 1.5-.672 1.5-1.5V3c0-.828-.672-1.5-1.5-1.5zM15.687 6.975L19.5 10.5M8.313 6.975L4.5 10.5",stroke:"#fff",strokeWidth:1.5,strokeLinecap:"round",strokeLinejoin:"round"})),xr||(xr=i.createElement("path",{d:"M22.88 2.014l-9.513 6.56C12.965 8.851 12.488 9 12 9s-.965-.149-1.367-.426L1.12 2.014",stroke:"#fff",strokeWidth:1.5,strokeLinecap:"round",strokeLinejoin:"round"})))}var Sr,Pr,Er=i.forwardRef(_r),Cr=(n.p,["title","titleId"]);function Nr(){return Nr=Object.assign||function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(e[r]=n[r])}return e},Nr.apply(this,arguments)}function Tr(e,t){if(null==e)return{};var n,r,i=function(e,t){if(null==e)return{};var n,r,i={},o=Object.keys(e);for(r=0;r<o.length;r++)n=o[r],t.indexOf(n)>=0||(i[n]=e[n]);return i}(e,t);if(Object.getOwnPropertySymbols){var o=Object.getOwnPropertySymbols(e);for(r=0;r<o.length;r++)n=o[r],t.indexOf(n)>=0||Object.prototype.propertyIsEnumerable.call(e,n)&&(i[n]=e[n])}return i}function Ir(e,t){var n=e.title,r=e.titleId,o=Tr(e,Cr);return i.createElement("svg",Nr({width:26,height:26,viewBox:"0 0 26 26",fill:"none",xmlns:"http://www.w3.org/2000/svg",ref:t,"aria-labelledby":r},o),n?i.createElement("title",{id:r},n):null,Sr||(Sr=i.createElement("path",{d:"M17.903 12.016c-.332-1.665-1.491-3.032-3.031-3.654M11.037 8.4C9.252 9.163 8 10.935 8 13c0 .432.055.85.158 1.25M10.44 17.296c.748.447 1.624.704 2.56.704 1.71 0 3.22-.858 4.12-2.167M15.171 21.22c3.643-.96 6.329-4.276 6.329-8.22 0-1.084-.203-2.121-.573-3.075M18.611 6.615C17.114 5.3 15.151 4.5 13 4.5c-2.149 0-4.112.797-5.608 2.113M5.112 9.826c-.395.98-.612 2.052-.612 3.174 0 4.015 2.783 7.38 6.526 8.27",stroke:"#fff",strokeWidth:1.5,strokeLinecap:"round"})),Pr||(Pr=i.createElement("path",{d:"M8.924 24.29c1.273.46 2.645.71 4.076.71 5.52 0 10.17-3.727 11.57-8.803M6.712 2.777C3.285 4.89 1 8.678 1 13c0 3.545 1.537 6.731 3.982 8.928M24.849 11.089C23.933 5.369 18.977 1 13 1c-.69 0-1.367.058-2.025.17",stroke:"#fff",strokeWidth:1.5,strokeLinecap:"round"})))}var Lr=i.forwardRef(Ir),Mr=(n.p,'\n /* Colors\n /* ----------------------------------------------------- */\n :root {\n --black: #000;\n --grey0: #1d1d1d;\n --grey1: #333;\n --grey2: #3d3d3d;\n --grey3: #474747;\n --grey4: #515151;\n --grey5: #686868;\n --grey6: #7f7f7f;\n --grey7: #979797;\n --grey8: #aeaeae;\n --grey9: #c5c5c5;\n --grey10: #dcdcdc;\n --grey11: #e1e1e1;\n --grey12: #eaeaea;\n --grey13: #f9f9f9;\n --grey14: #fbfbfb;\n --white: #fff;\n --red: #f02525;\n --yellow: #FFDC15;\n --green: #7FC724;\n }\n\n /* Globals\n /* ----------------------------------------------------- */\n html {\n font-size: 62.5%;\n height: 100%;\n }\n\n body {\n margin: 0px;\n font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Oxygen, Ubuntu, Cantarell, "Open Sans", "Helvetica Neue", sans-serif;\n font-size: 1.6rem;\n height: 100%;\n line-height: 1.6em;\n font-weight: 400;\n font-style: normal;\n color: var(--grey2);\n box-sizing: border-box;\n overflow: hidden;\n }\n\n button,\n button span {\n font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Oxygen, Ubuntu, Cantarell, "Open Sans", "Helvetica Neue", sans-serif;\n }\n\n *, ::after, ::before {\n box-sizing: border-box;\n }\n\n h1, h2, h3, h4, h5, h6, p {\n line-height: 1.15em;\n padding: 0;\n margin: 0;\n }\n\n h1 {\n font-size: 35px;\n font-weight: 700;\n letter-spacing: -0.022em;\n }\n\n h2 {\n font-size: 32px;\n font-weight: 700;\n letter-spacing: -0.021em;\n }\n\n h3 {\n font-size: 24px;\n font-weight: 700;\n letter-spacing: -0.019em;\n }\n\n p {\n font-size: 15px;\n line-height: 1.5em;\n margin-bottom: 24px;\n }\n\n strong {\n font-weight: 600;\n }\n\n a,\n .gh-portal-link {\n cursor: pointer;\n }\n\n svg {\n box-sizing: content-box;\n }\n\n input,\n textarea {\n font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Oxygen, Ubuntu, Cantarell, "Open Sans", "Helvetica Neue", sans-serif;\n font-size: 1.5rem;\n }\n\n textarea {\n padding: 10px;\n line-height: 1.5em;\n }\n\n @media (max-width: 1440px) {\n h1 {\n font-size: 32px;\n letter-spacing: -0.022em;\n }\n\n h2 {\n font-size: 28px;\n letter-spacing: -0.021em;\n }\n\n h3 {\n font-size: 26px;\n letter-spacing: -0.02em;\n }\n }\n\n @media (max-width: 480px) {\n h1 {\n font-size: 30px;\n letter-spacing: -0.021em;\n }\n\n h2 {\n font-size: 26px;\n letter-spacing: -0.02em;\n }\n\n h3 {\n font-size: 24px;\n letter-spacing: -0.019em;\n }\n }\n'),Fr=n(3),Dr=function(){var e=window.location.hash.substr(1).split("?");return"/portal/preview"===Object(s.a)(e,1)[0]},zr=function(){var e=window.location.hash.substr(1).split("?");return"/portal/preview/offer"===Object(s.a)(e,1)[0]},Rr={preview:function(){return Dr()||zr()},offerPreview:zr,dev:function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{};e.customSiteUrl;return!1},test:function(){return!1}},Ur=function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:[],t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{};return e.some((function(e){var n=Rr[e];return!(!n||!n(t))}))},Ar=n(1),Br={"icon-1":lr,"icon-2":hr,"icon-3":wr,"icon-4":Er,"icon-5":Lr},Hr=function(e){e.brandColor;var t=e.hasText,n=Object(k.a)(Object(k.a)({},t?{}:{width:"105px"}),Ur(["preview"])?{opacity:1}:{});return{frame:Object(k.a)({zIndex:"3999998",position:"fixed",bottom:"0",right:"0",width:"500px",maxWidth:"500px",height:"98px",animation:"250ms ease 0s 1 normal none running animation-bhegco",transition:"opacity 0.3s ease 0s",overflow:"hidden"},n),userIcon:{width:"34px",height:"34px",color:"#fff"},buttonIcon:{width:"24px",height:"24px",color:"#fff"},closeIcon:{width:"20px",height:"20px",color:"#fff"}}},qr=function(e){v(n,e);var t=O(n);function n(e){var r;return h(this,n),(r=t.call(this,e)).state={},r.container=Ar.createRef(),r.height=null,r.width=null,r}return g(n,[{key:"updateHeight",value:function(e){this.props.updateHeight&&this.props.updateHeight(e)}},{key:"updateWidth",value:function(e){this.props.updateWidth&&this.props.updateWidth(e)}},{key:"componentDidMount",value:function(){this.container&&(this.height=this.container.current&&this.container.current.offsetHeight,this.width=this.container.current&&this.container.current.offsetWidth,this.updateHeight(this.height),this.updateWidth(this.width))}},{key:"componentDidUpdate",value:function(){if(this.container){var e=this.container.current&&this.container.current.offsetHeight,t=this.container.current&&this.container.current.offsetWidth;e!==this.height&&(this.height=e,this.updateHeight(this.height)),t!==this.width&&(this.width=t,this.updateWidth(this.width))}}},{key:"renderTriggerIcon",value:function(){var e=this.context.site||{},t=e.portal_button_icon,n=void 0===t?"":t,r=e.portal_button_style,i=void 0===r?"":r,o=Hr({brandColor:this.context.brandColor}),a=this.context.member&&this.context.member.avatar_image;if(!i.includes("icon")&&!this.context.member)return null;if(a)return Object($n.jsx)(er,{gravatar:a});if(this.context.member)return Object($n.jsx)(Jn,{style:o.userIcon});if(Object.keys(Br).includes(n)){var l=Br[n];return Object($n.jsx)(l,{style:o.buttonIcon})}return n?Object($n.jsx)("img",{style:{width:"26px",height:"26px"},src:n,alt:""}):(this.hasText()&&(o.userIcon.width="26px",o.userIcon.height="26px"),Object($n.jsx)(Jn,{style:o.userIcon}))}},{key:"hasText",value:function(){var e=this.context.site,t=e.portal_button_signup_text,n=e.portal_button_style;return["icon-and-text","text-only"].includes(n)&&!this.context.member&&t}},{key:"renderText",value:function(){var e=this.context.site.portal_button_signup_text;return this.hasText()?Object($n.jsxs)("span",{className:"gh-portal-triggerbtn-label",children:[" ",e," "]}):null}},{key:"onToggle",value:function(){var e=this.context,t=e.showPopup,n=e.member,r=e.site;if(t)this.context.onAction("closePopup");else{var i=Object(Fr.isInviteOnlySite)({site:r})?"signin":"signup",o=n?"accountHome":i;this.context.onAction("openPopup",{page:o})}}},{key:"render",value:function(){var e=this,t=this.hasText(),n=this.context.member?"halo":"";return t?Object($n.jsx)("div",{className:"gh-portal-triggerbtn-wrapper",ref:this.container,children:Object($n.jsxs)("div",{className:"gh-portal-triggerbtn-container with-label",onClick:function(t){return e.onToggle(t)},children:[this.renderTriggerIcon(),t?this.renderText():""]})}):Object($n.jsx)("div",{className:"gh-portal-triggerbtn-wrapper",children:Object($n.jsx)("div",{className:"gh-portal-triggerbtn-container "+n,onClick:function(t){return e.onToggle(t)},children:this.renderTriggerIcon()})})}}]),n}(Ar.Component);qr.contextType=tr;var $r=function(e){v(n,e);var t=O(n);function n(e){var r;return h(this,n),(r=t.call(this,e)).state={width:null},r}return g(n,[{key:"onWidthChange",value:function(e){this.setState({width:e})}},{key:"hasText",value:function(){var e=this.context.site,t=e.portal_button_signup_text,n=e.portal_button_style;return["icon-and-text","text-only"].includes(n)&&!this.context.member&&t}},{key:"renderFrameStyles",value:function(){var e="\n :root {\n --brandcolor: ".concat(this.context.brandColor,"\n }\n ")+'\n /* Colors\n /* ----------------------------------------------------- */\n :root {\n --black: #000;\n --grey0: #1d1d1d;\n --grey1: #333;\n --grey2: #3d3d3d;\n --grey3: #474747;\n --grey4: #515151;\n --grey5: #686868;\n --grey6: #7f7f7f;\n --grey7: #979797;\n --grey8: #aeaeae;\n --grey9: #c5c5c5;\n --grey10: #dcdcdc;\n --grey11: #e1e1e1;\n --grey12: #eaeaea;\n --grey13: #f9f9f9;\n --grey14: #fbfbfb;\n --white: #fff;\n --red: #f02525;\n --yellow: #FFDC15;\n --green: #7FC724;\n }\n\n /* Globals\n /* ----------------------------------------------------- */\n html {\n font-size: 62.5%;\n height: 100%;\n }\n\n body {\n margin: 0px;\n font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Oxygen, Ubuntu, Cantarell, "Open Sans", "Helvetica Neue", sans-serif;\n font-size: 1.6rem;\n height: 100%;\n line-height: 1.6em;\n font-weight: 400;\n font-style: normal;\n color: var(--grey2);\n box-sizing: border-box;\n overflow: hidden;\n }\n\n button,\n button span {\n font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Oxygen, Ubuntu, Cantarell, "Open Sans", "Helvetica Neue", sans-serif;\n }\n\n *, ::after, ::before {\n box-sizing: border-box;\n }\n\n h1, h2, h3, h4, h5, h6, p {\n line-height: 1.15em;\n padding: 0;\n margin: 0;\n }\n\n h1 {\n font-size: 35px;\n font-weight: 700;\n letter-spacing: -0.022em;\n }\n\n h2 {\n font-size: 32px;\n font-weight: 700;\n letter-spacing: -0.021em;\n }\n\n h3 {\n font-size: 24px;\n font-weight: 700;\n letter-spacing: -0.019em;\n }\n\n p {\n font-size: 15px;\n line-height: 1.5em;\n margin-bottom: 24px;\n }\n\n strong {\n font-weight: 600;\n }\n\n a,\n .gh-portal-link {\n cursor: pointer;\n }\n\n svg {\n box-sizing: content-box;\n }\n\n input,\n textarea {\n font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Oxygen, Ubuntu, Cantarell, "Open Sans", "Helvetica Neue", sans-serif;\n font-size: 1.5rem;\n }\n\n textarea {\n padding: 10px;\n line-height: 1.5em;\n }\n\n @media (max-width: 1440px) {\n h1 {\n font-size: 32px;\n letter-spacing: -0.022em;\n }\n\n h2 {\n font-size: 28px;\n letter-spacing: -0.021em;\n }\n\n h3 {\n font-size: 26px;\n letter-spacing: -0.02em;\n }\n }\n\n @media (max-width: 480px) {\n h1 {\n font-size: 30px;\n letter-spacing: -0.021em;\n }\n\n h2 {\n font-size: 26px;\n letter-spacing: -0.02em;\n }\n\n h3 {\n font-size: 24px;\n letter-spacing: -0.019em;\n }\n }\n\n .gh-portal-triggerbtn-wrapper {\n display: inline-flex;\n align-items: flex-start;\n justify-content: flex-end;\n height: 100%;\n opacity: 1;\n transition: transform 0.16s linear 0s; opacity 0.08s linear 0s;\n user-select: none;\n line-height: 1;\n padding: 10px 28px 0 17px;\n }\n \n .gh-portal-triggerbtn-wrapper span {\n margin-bottom: 1px;\n }\n \n .gh-portal-triggerbtn-container {\n position: relative;\n cursor: pointer;\n display: flex;\n align-items: center;\n justify-content: center;\n background: var(--brandcolor);\n height: 60px;\n min-width: 60px;\n box-shadow: rgba(0, 0, 0, 0.24) 0px 8px 16px -2px;\n border-radius: 999px;\n transition: opacity 0.3s ease;\n }\n\n .gh-portal-triggerbtn-container:before {\n position: absolute;\n content: "";\n top: 0;\n right: 0;\n bottom: 0;\n left: 0;\n border-radius: 999px;\n background: rgba(255, 255, 255, 0);\n transition: background 0.3s ease;\n }\n\n .gh-portal-triggerbtn-container:hover:before {\n background: rgba(255, 255, 255, 0.08);\n }\n\n .gh-portal-triggerbtn-container.halo:before {\n top: -4px;\n right: -4px;\n bottom: -4px;\n left: -4px;\n border: 4px solid rgba(255, 255, 255, 0.15);\n }\n\n .gh-portal-triggerbtn-container.with-label {\n padding: 0 12px 0 16px;\n }\n\n .gh-portal-triggerbtn-label {\n padding: 8px;\n color: rgb(255, 255, 255);\n display: block;\n white-space: nowrap;\n max-width: 380px;\n overflow: hidden;\n text-overflow: ellipsis;\n }\n\n .gh-portal-avatar {\n margin-bottom: 0px !important;\n width: 60px;\n height: 60px;\n }\n\n .gh-portal-avatar {\n position: relative;\n display: flex;\n align-items: center;\n justify-content: center;\n overflow: hidden;\n margin: 0 0 8px 0;\n border-radius: 999px;\n }\n\n .gh-portal-avatar img {\n position: absolute;\n display: block;\n top: -2px;\n right: -2px;\n bottom: -2px;\n left: -2px;\n width: calc(100% + 4px);\n height: calc(100% + 4px);\n opacity: 1;\n max-width: unset;\n }\n';return Object($n.jsx)("style",{dangerouslySetInnerHTML:{__html:e}})}},{key:"render",value:function(){var e=this,t=this.context.site.portal_button,n=this.context.showPopup;if(!t||Ur(["offerPreview"]))return null;var r=this.hasText(),i=Hr({brandColor:this.context.brandColor,hasText:r}),o=Object(k.a)({},i.frame);if(this.state.width){var a=this.state.width+2;o.width="".concat(a,"px")}return Object($n.jsx)(Qn,{className:"gh-portal-triggerbtn-iframe",style:o,title:"portal-trigger",head:this.renderFrameStyles(),children:Object($n.jsx)(qr,{isPopupOpen:n,updateWidth:function(t){return e.onWidthChange(t)}})})}}]),n}(Ar.Component);$r.contextType=tr;var Wr,Qr,Vr=["title","titleId"];function Yr(){return Yr=Object.assign||function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(e[r]=n[r])}return e},Yr.apply(this,arguments)}function Kr(e,t){if(null==e)return{};var n,r,i=function(e,t){if(null==e)return{};var n,r,i={},o=Object.keys(e);for(r=0;r<o.length;r++)n=o[r],t.indexOf(n)>=0||(i[n]=e[n]);return i}(e,t);if(Object.getOwnPropertySymbols){var o=Object.getOwnPropertySymbols(e);for(r=0;r<o.length;r++)n=o[r],t.indexOf(n)>=0||Object.prototype.propertyIsEnumerable.call(e,n)&&(i[n]=e[n])}return i}function Gr(e,t){var n=e.title,r=e.titleId,o=Kr(e,Vr);return i.createElement("svg",Yr({xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24",ref:t,"aria-labelledby":r},o),n?i.createElement("title",{id:r},n):null,Wr||(Wr=i.createElement("defs",null,i.createElement("style",null,".a{fill:none;stroke:currentColor;stroke-linecap:round;stroke-linejoin:round;stroke-width:1.2px !important;}"))),Qr||(Qr=i.createElement("path",{className:"a",d:"M.75 23.249l22.5-22.5M23.25 23.249L.75.749"})))}var Jr,Xr,Zr=i.forwardRef(Gr),ei=(n.p,["title","titleId"]);function ti(){return ti=Object.assign||function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(e[r]=n[r])}return e},ti.apply(this,arguments)}function ni(e,t){if(null==e)return{};var n,r,i=function(e,t){if(null==e)return{};var n,r,i={},o=Object.keys(e);for(r=0;r<o.length;r++)n=o[r],t.indexOf(n)>=0||(i[n]=e[n]);return i}(e,t);if(Object.getOwnPropertySymbols){var o=Object.getOwnPropertySymbols(e);for(r=0;r<o.length;r++)n=o[r],t.indexOf(n)>=0||Object.prototype.propertyIsEnumerable.call(e,n)&&(i[n]=e[n])}return i}function ri(e,t){var n=e.title,r=e.titleId,o=ni(e,ei);return i.createElement("svg",ti({xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24",ref:t,"aria-labelledby":r},o),n?i.createElement("title",{id:r},n):null,Jr||(Jr=i.createElement("defs",null,i.createElement("style",null,".checkmark-icon-fill{fill:currentColor;}"))),Xr||(Xr=i.createElement("path",{className:"checkmark-icon-fill",d:"M12,0A12,12,0,1,0,24,12,12.014,12.014,0,0,0,12,0Zm6.927,8.2-6.845,9.289a1.011,1.011,0,0,1-1.43.188L5.764,13.769a1,1,0,1,1,1.25-1.562l4.076,3.261,6.227-8.451A1,1,0,1,1,18.927,8.2Z"})))}var ii,oi,ai=i.forwardRef(ri),li=(n.p,["title","titleId"]);function si(){return si=Object.assign||function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(e[r]=n[r])}return e},si.apply(this,arguments)}function ci(e,t){if(null==e)return{};var n,r,i=function(e,t){if(null==e)return{};var n,r,i={},o=Object.keys(e);for(r=0;r<o.length;r++)n=o[r],t.indexOf(n)>=0||(i[n]=e[n]);return i}(e,t);if(Object.getOwnPropertySymbols){var o=Object.getOwnPropertySymbols(e);for(r=0;r<o.length;r++)n=o[r],t.indexOf(n)>=0||Object.prototype.propertyIsEnumerable.call(e,n)&&(i[n]=e[n])}return i}function ui(e,t){var n=e.title,r=e.titleId,o=ci(e,li);return i.createElement("svg",si({xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24",ref:t,"aria-labelledby":r},o),n?i.createElement("title",{id:r},n):null,ii||(ii=i.createElement("defs",null,i.createElement("style",null,".warning-icon-fill{fill:currentColor;}"))),oi||(oi=i.createElement("path",{className:"warning-icon-fill",d:"M23.25,23.235a.75.75,0,0,0,.661-1.105l-11.25-21a.782.782,0,0,0-1.322,0l-11.25,21A.75.75,0,0,0,.75,23.235ZM12,20.485a1.5,1.5,0,1,1,1.5-1.5A1.5,1.5,0,0,1,12,20.485Zm0-12.25a1,1,0,0,1,1,1V14.7a1,1,0,0,1-2,0V9.235A1,1,0,0,1,12,8.235Z"})))}var pi=i.forwardRef(ui),di=(n.p,function(e){e.qsParams;var t=e.action,n=e.status;if(n&&["true","false"].includes(n)){var r=JSON.parse(n);return{type:t,status:r?"success":"error",duration:3e3,autoHide:!!r}}return{}}),fi=function(e){var t=e.status,n=e.billingOnly;return!n&&["success"].includes(t)?{type:"stripe:checkout",status:["success"].includes(t)?"success":"warning",duration:3e3,autoHide:!0}:n&&["billing-update-success","billing-update-cancel"].includes(t)?{type:"stripe:billing-update",status:"billing-update-success"===t?"success":"warning",duration:3e3,autoHide:!0,closeable:!0}:void 0},hi=function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:[],t=window.location.search||"",n=new URLSearchParams(t);e.forEach((function(e){n.delete(e)}));var r=n.toString()?"?".concat(n):"";window.history.replaceState({},"","".concat(window.location.pathname).concat(r))};function mi(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{},t=e.billingOnly,n=void 0!==t&&t,r=window.location.search;if(!r)return null;var i=new URLSearchParams(r),o=i.get("action"),a=i.get("success"),l=i.get("stripe"),s=null;return l?fi({qsParams:i,status:l,billingOnly:n}):o&&a&&!n?di({qsParams:i,action:o,status:a}):s}var gi=n(1),bi=function(e){var t=e.type,n=e.status,r=e.context,i=Object(Fr.getPortalLink)({page:"signin",siteUrl:r.site.url}),o=Object(Fr.getPortalLink)({page:"signup",siteUrl:r.site.url});if("signin"===t&&"success"===n&&r.member){var a=r.member.firstname||"";return Object($n.jsxs)("p",{children:["Welcome back",a?", "+a:"","!",Object($n.jsx)("br",{}),"You've successfully signed in."]})}return"signin"===t&&"error"===n?Object($n.jsxs)("p",{children:["Could not sign in. Login link expired. ",Object($n.jsx)("a",{href:i,target:"_parent",children:"Click here to retry"})]}):"signup"===t&&"success"===n||"signup-paid"===t&&"success"===n?Object($n.jsxs)("p",{children:["You've successfully subscribed to ",Object($n.jsx)("br",{}),Object($n.jsx)("strong",{children:r.site.title})]}):"updateEmail"===t&&"success"===n?Object($n.jsx)("p",{children:"Success! Your email is updated."}):"updateEmail"===t&&"error"===n?Object($n.jsx)("p",{children:"Could not update email! Invalid link."}):"signup"===t&&"error"===n||"signup-paid"===t&&"error"===n?Object($n.jsxs)("p",{children:["Signup error: Invalid link ",Object($n.jsx)("br",{}),Object($n.jsx)("a",{href:o,target:"_parent",children:"Click here to retry"})]}):"stripe:checkout"===t&&"success"===n?r.member?Object($n.jsx)("p",{children:"Success! Your account is fully activated, you now have access to all content."}):Object($n.jsx)("p",{children:"Success! Check your email for magic link to sign-in."}):"stripe:checkout"===t&&"warning"===n?r.member?Object($n.jsx)("p",{children:"Plan upgrade was cancelled."}):Object($n.jsx)("p",{children:"Plan checkout was cancelled."}):Object($n.jsx)("p",{children:"success"===n?"Success":"Error"})},vi=function(e){v(n,e);var t=O(n);function n(){var e;return h(this,n),(e=t.call(this)).state={className:""},e}return g(n,[{key:"componentWillUnmount",value:function(){clearTimeout(this.timeoutId)}},{key:"onNotificationClose",value:function(){this.props.onHideNotification()}},{key:"componentDidUpdate",value:function(){var e=this.context.showPopup;!this.state.className&&e&&this.setState({className:"slideout"})}},{key:"componentDidMount",value:function(){var e=this,t=this.props,n=t.autoHide,r=t.duration,i=void 0===r?2400:r;this.context.showPopup?this.setState({className:"slideout"}):n&&(this.timeoutId=setTimeout((function(){e.setState({className:"slideout"})}),i))}},{key:"onAnimationEnd",value:function(e){"notification-slideout"!==e.animationName&&"notification-slideout-mobile"!==e.animationName||this.props.onHideNotification(e)}},{key:"render",value:function(){var e=this,t=this.props,n=t.type,r=t.status,i=this.state.className,o=void 0===i?"":i,a=r?" ".concat(r):" neutral",l=o?" ".concat(o):"";return Object($n.jsx)("div",{className:"gh-portal-notification-wrapper",children:Object($n.jsxs)("div",{className:"gh-portal-notification".concat(a).concat(l),onAnimationEnd:function(t){return e.onAnimationEnd(t)},children:["error"===r?Object($n.jsx)(pi,{className:"gh-portal-notification-icon error",alt:""}):Object($n.jsx)(ai,{className:"gh-portal-notification-icon success",alt:""}),Object($n.jsx)(bi,{type:n,status:r,context:this.context}),Object($n.jsx)(Zr,{className:"gh-portal-notification-closeicon",alt:"Close",onClick:function(t){return e.onNotificationClose(t)}})]})})}}]),n}(gi.Component);vi.contextType=tr;var yi,xi,wi=function(e){v(n,e);var t=O(n);function n(){var e;h(this,n),e=t.call(this);var r=mi()||{},i=r.type,o=r.status,a=r.autoHide,l=r.duration;return e.state={active:!0,type:i,status:o,autoHide:a,duration:l,className:""},e}return g(n,[{key:"onHideNotification",value:function(){var e=this.state.type,t=[];["signin","signup"].includes(e)?t.push("action","success"):["stripe:checkout"].includes(e)&&t.push("stripe"),hi(t),this.context.onAction("refreshMemberData"),this.setState({active:!1})}},{key:"renderFrameStyles",value:function(){var e="\n :root {\n --brandcolor: ".concat(this.context.brandColor,"\n }\n ")+'\n /* Colors\n /* ----------------------------------------------------- */\n :root {\n --black: #000;\n --grey0: #1d1d1d;\n --grey1: #333;\n --grey2: #3d3d3d;\n --grey3: #474747;\n --grey4: #515151;\n --grey5: #686868;\n --grey6: #7f7f7f;\n --grey7: #979797;\n --grey8: #aeaeae;\n --grey9: #c5c5c5;\n --grey10: #dcdcdc;\n --grey11: #e1e1e1;\n --grey12: #eaeaea;\n --grey13: #f9f9f9;\n --grey14: #fbfbfb;\n --white: #fff;\n --red: #f02525;\n --yellow: #FFDC15;\n --green: #7FC724;\n }\n\n /* Globals\n /* ----------------------------------------------------- */\n html {\n font-size: 62.5%;\n height: 100%;\n }\n\n body {\n margin: 0px;\n font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Oxygen, Ubuntu, Cantarell, "Open Sans", "Helvetica Neue", sans-serif;\n font-size: 1.6rem;\n height: 100%;\n line-height: 1.6em;\n font-weight: 400;\n font-style: normal;\n color: var(--grey2);\n box-sizing: border-box;\n overflow: hidden;\n }\n\n button,\n button span {\n font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Oxygen, Ubuntu, Cantarell, "Open Sans", "Helvetica Neue", sans-serif;\n }\n\n *, ::after, ::before {\n box-sizing: border-box;\n }\n\n h1, h2, h3, h4, h5, h6, p {\n line-height: 1.15em;\n padding: 0;\n margin: 0;\n }\n\n h1 {\n font-size: 35px;\n font-weight: 700;\n letter-spacing: -0.022em;\n }\n\n h2 {\n font-size: 32px;\n font-weight: 700;\n letter-spacing: -0.021em;\n }\n\n h3 {\n font-size: 24px;\n font-weight: 700;\n letter-spacing: -0.019em;\n }\n\n p {\n font-size: 15px;\n line-height: 1.5em;\n margin-bottom: 24px;\n }\n\n strong {\n font-weight: 600;\n }\n\n a,\n .gh-portal-link {\n cursor: pointer;\n }\n\n svg {\n box-sizing: content-box;\n }\n\n input,\n textarea {\n font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Oxygen, Ubuntu, Cantarell, "Open Sans", "Helvetica Neue", sans-serif;\n font-size: 1.5rem;\n }\n\n textarea {\n padding: 10px;\n line-height: 1.5em;\n }\n\n @media (max-width: 1440px) {\n h1 {\n font-size: 32px;\n letter-spacing: -0.022em;\n }\n\n h2 {\n font-size: 28px;\n letter-spacing: -0.021em;\n }\n\n h3 {\n font-size: 26px;\n letter-spacing: -0.02em;\n }\n }\n\n @media (max-width: 480px) {\n h1 {\n font-size: 30px;\n letter-spacing: -0.021em;\n }\n\n h2 {\n font-size: 26px;\n letter-spacing: -0.02em;\n }\n\n h3 {\n font-size: 24px;\n letter-spacing: -0.019em;\n }\n }\n\n .gh-portal-notification-wrapper {\n position: relative;\n overflow: hidden;\n height: 100%;\n width: 100%;\n }\n\n .gh-portal-notification {\n position: absolute;\n display: flex;\n align-items: center;\n top: 12px;\n right: 12px;\n width: 100%;\n padding: 14px 44px 18px 20px;\n max-width: 380px;\n min-height: 66px;\n font-size: 1.3rem;\n letter-spacing: 0.2px;\n background: rgba(33,33,33,0.95);\n backdrop-filter: blur(8px);\n color: var(--white);\n border-radius: 7px;\n box-shadow: 0 3.2px 3.6px rgba(0, 0, 0, 0.024), 0 8.8px 10px -5px rgba(0, 0, 0, 0.08);\n animation: notification-slidein 0.55s cubic-bezier(0.215, 0.610, 0.355, 1.000);\n }\n\n .gh-portal-notification.slideout {\n animation: notification-slideout 0.4s cubic-bezier(0.550, 0.055, 0.675, 0.190);\n }\n\n .gh-portal-notification.hide {\n display: none;\n }\n\n .gh-portal-notification p {\n flex-grow: 1;\n font-size: 1.4rem;\n line-height: 1.5em;\n text-align: left;\n margin: 0;\n padding: 0 0 0 40px;\n color: var(--grey13);\n }\n\n .gh-portal-notification p strong {\n color: var(--white);\n }\n\n .gh-portal-notification a {\n color: var(--white);\n text-decoration: underline;\n transition: all 0.2s ease-in-out;\n outline: none;\n }\n\n .gh-portal-notification a:hover {\n opacity: 0.8;\n }\n\n .gh-portal-notification-icon {\n position: absolute;\n top: calc(50% - 14px);\n left: 17px;\n width: 28px;\n height: 28px;\n }\n\n .gh-portal-notification-icon.success {\n color: var(--green);\n }\n\n .gh-portal-notification-icon.error {\n color: #FF2828;\n }\n\n .gh-portal-notification-closeicon {\n position: absolute;\n top: 5px;\n bottom: 0;\n right: 5px;\n color: var(--white);\n cursor: pointer;\n width: 12px;\n height: 12px;\n padding: 10px;\n transition: all 0.2s ease-in-out forwards;\n opacity: 0.8;\n }\n\n .gh-portal-notification-closeicon:hover {\n opacity: 1.0;\n } \n\n @keyframes notification-slidein {\n 0% { transform: translateX(380px); }\n 60% { transform: translateX(-6px); }\n 100% { transform: translateX(0); }\n }\n\n @keyframes notification-slideout {\n 0% { transform: translateX(0); }\n 30% { transform: translateX(-10px); }\n 100% { transform: translateX(380px); }\n }\n\n @keyframes notification-slidein-mobile {\n 0% { transform: translateY(-150px); }\n 50% { transform: translateY(6px); }\n 100% { transform: translateY(0); }\n }\n\n @keyframes notification-slideout-mobile {\n 0% { transform: translateY(0); }\n 35% { transform: translateY(6px); }\n 100% { transform: translateY(-150px); }\n }\n\n @media (max-width: 414px) {\n .gh-portal-notification {\n left: 12px;\n max-width: calc(100% - 24px);\n animation-name: notification-slidein-mobile;\n }\n\n .gh-portal-notification.slideout {\n animation-duration: 0.55s;\n animation-name: notification-slideout-mobile;\n }\n }\n';return Object($n.jsx)("style",{dangerouslySetInnerHTML:{__html:e}})}},{key:"render",value:function(){var e=this,t=(this.context.brandColor,{frame:{zIndex:"4000000",position:"fixed",top:"0",right:"0",maxWidth:"415px",width:"100%",height:"120px",animation:"250ms ease 0s 1 normal none running animation-bhegco",transition:"opacity 0.3s ease 0s",overflow:"hidden"}}),n=Object(k.a)({},t.frame);if(!this.state.active)return null;var r=this.state,i=r.type,o=r.status,a=r.autoHide,l=r.duration;return i&&o?Object($n.jsx)(Qn,{style:n,title:"portal-notification",head:this.renderFrameStyles(),className:"gh-portal-notification-iframe",children:Object($n.jsx)(vi,{type:i,status:o,autoHide:a,duration:l,onHideNotification:function(t){return e.onHideNotification(t)}})}):null}}]),n}(gi.Component);wi.contextType=tr;var ji=["title","titleId"];function Oi(){return Oi=Object.assign||function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(e[r]=n[r])}return e},Oi.apply(this,arguments)}function ki(e,t){if(null==e)return{};var n,r,i=function(e,t){if(null==e)return{};var n,r,i={},o=Object.keys(e);for(r=0;r<o.length;r++)n=o[r],t.indexOf(n)>=0||(i[n]=e[n]);return i}(e,t);if(Object.getOwnPropertySymbols){var o=Object.getOwnPropertySymbols(e);for(r=0;r<o.length;r++)n=o[r],t.indexOf(n)>=0||Object.prototype.propertyIsEnumerable.call(e,n)&&(i[n]=e[n])}return i}function _i(e,t){var n=e.title,r=e.titleId,o=ki(e,ji);return i.createElement("svg",Oi({id:"loader-1",xmlns:"http://www.w3.org/2000/svg",xmlnsXlink:"http://www.w3.org/1999/xlink",x:"0px",y:"0px",width:"40px",height:"40px",viewBox:"0 0 40 40",enableBackground:"new 0 0 40 40",xmlSpace:"preserve",ref:t,"aria-labelledby":r},o),n?i.createElement("title",{id:r},n):null,yi||(yi=i.createElement("path",{opacity:.2,fill:"#000",d:"M20.201,5.169c-8.254,0-14.946,6.692-14.946,14.946c0,8.255,6.692,14.946,14.946,14.946 s14.946-6.691,14.946-14.946C35.146,11.861,28.455,5.169,20.201,5.169z M20.201,31.749c-6.425,0-11.634-5.208-11.634-11.634 c0-6.425,5.209-11.634,11.634-11.634c6.425,0,11.633,5.209,11.633,11.634C31.834,26.541,26.626,31.749,20.201,31.749z"})),xi||(xi=i.createElement("path",{fill:"#000",d:"M26.013,10.047l1.654-2.866c-2.198-1.272-4.743-2.012-7.466-2.012h0v3.312h0 C22.32,8.481,24.301,9.057,26.013,10.047z"},i.createElement("animateTransform",{attributeType:"xml",attributeName:"transform",type:"rotate",from:"0 20 20",to:"360 20 20",dur:"0.5s",repeatCount:"indefinite"}))))}var Si=i.forwardRef(_i);n.p;var Pi,Ei,Ci=function(e){var t=e.label,n=(e.type,e.onClick),r=e.disabled,i=void 0!==r&&r,o=e.retry,a=void 0!==o&&o,l=e.brandColor,s=e.isRunning,c=e.isPrimary,u=void 0===c||c,p=e.isDestructive,d=void 0!==p&&p,f=e.classes,h=void 0===f?"":f,m=e.style,g=void 0===m?{}:m,b=e.tabindex,v=void 0===b?void 0:b,y=function(e){var t=e.brandColor,n=(e.retry,e.disabled),r=e.style,i=void 0===r?{}:r,o=e.isPrimary,a=t||"#3eb0ef",l="1.0",s="auto";return n&&(l="0.5",s="none"),{button:Object(k.a)(Object(k.a)(Object(k.a)({},o?{color:"#fff"}:{}),o?{backgroundColor:a}:{}),{},{opacity:l,pointerEvents:s},i||{})}}({disabled:i,retry:a,brandColor:l,style:g,isPrimary:u}),x="gh-portal-btn";u&&(x+=" gh-portal-btn-main gh-portal-btn-primary"),d&&(x+=" gh-portal-btn-destructive"),h&&(x+=" "+h),Object(Fr.isCookiesDisabled)()&&(i=!0);var w=u?"gh-portal-loadingicon":"gh-portal-loadingicon dark";return Object($n.jsx)("button",{className:x,style:y.button,onClick:function(e){return n(e)},disabled:i,type:"submit",tabIndex:v,children:s?Object($n.jsx)(Si,{className:w}):t})},Ni=["title","titleId"];function Ti(){return Ti=Object.assign||function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(e[r]=n[r])}return e},Ti.apply(this,arguments)}function Ii(e,t){if(null==e)return{};var n,r,i=function(e,t){if(null==e)return{};var n,r,i={},o=Object.keys(e);for(r=0;r<o.length;r++)n=o[r],t.indexOf(n)>=0||(i[n]=e[n]);return i}(e,t);if(Object.getOwnPropertySymbols){var o=Object.getOwnPropertySymbols(e);for(r=0;r<o.length;r++)n=o[r],t.indexOf(n)>=0||Object.prototype.propertyIsEnumerable.call(e,n)&&(i[n]=e[n])}return i}function Li(e,t){var n=e.title,r=e.titleId,o=Ii(e,Ni);return i.createElement("svg",Ti({id:"Regular",xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24",ref:t,"aria-labelledby":r},o),n?i.createElement("title",{id:r},n):null,Pi||(Pi=i.createElement("defs",null,i.createElement("style",null,".cls-1{fill:none;stroke:currentColor;stroke-linecap:round;stroke-linejoin:round;stroke-width:1.5px;fill-rule:evenodd;}"))),Ei||(Ei=i.createElement("path",{className:"cls-1",d:"M16.25,23.25,5.53,12.53a.749.749,0,0,1,0-1.06L16.25.75"})))}var Mi=i.forwardRef(Li);n.p;var Fi=function(e){var t=e.label,n=void 0===t?"Back":t,r=(e.brandColor,e.hidden),i=void 0!==r&&r,o=e.onClick;return i?null:Object($n.jsxs)("button",{className:"gh-portal-btn gh-portal-btn-back",onClick:function(e){return o(e)},children:[Object($n.jsx)(Mi,{})," ",n]})};var Di=function(e){var t=e.id,n=e.label,r=void 0===n?"":n,o=e.onToggle,a=e.checked,l=void 0!==a&&a,c=Object(i.useContext)(tr).action,u=Object(i.useState)(l),p=Object(s.a)(u,2),d=p[0],f=p[1],h=["updateNewsletter:failed","updateNewsletter:success"].includes(c);return Object(i.useEffect)((function(){f(l)}),[l,h]),Object($n.jsx)("div",{className:"gh-portal-for-switch",children:Object($n.jsxs)("label",{className:"switch",htmlFor:t,children:[Object($n.jsx)("input",{type:"checkbox",checked:d,id:t,onChange:function(){},"aria-label":r}),Object($n.jsx)("span",{className:"input-toggle-component",onClick:function(e){f(!d),o(e,!d)},"data-testid":"switch-input"})]})})},zi=function(e){v(n,e);var t=O(n);function n(){return h(this,n),t.apply(this,arguments)}return g(n,[{key:"render",value:function(){var e=this;return Object($n.jsx)("div",{className:"gh-portal-closeicon-container",children:Object($n.jsx)(Zr,{className:"gh-portal-closeicon",alt:"Close",onClick:function(){return e.context.onAction("closePopup")}})})}}]),n}(o.a.Component);zi.contextType=tr;var Ri,Ui,Ai,Bi=n(11),Hi=["title","titleId"];function qi(){return qi=Object.assign||function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(e[r]=n[r])}return e},qi.apply(this,arguments)}function $i(e,t){if(null==e)return{};var n,r,i=function(e,t){if(null==e)return{};var n,r,i={},o=Object.keys(e);for(r=0;r<o.length;r++)n=o[r],t.indexOf(n)>=0||(i[n]=e[n]);return i}(e,t);if(Object.getOwnPropertySymbols){var o=Object.getOwnPropertySymbols(e);for(r=0;r<o.length;r++)n=o[r],t.indexOf(n)>=0||Object.prototype.propertyIsEnumerable.call(e,n)&&(i[n]=e[n])}return i}function Wi(e,t){var n=e.title,r=e.titleId,o=$i(e,Hi);return i.createElement("svg",qi({width:24,height:24,viewBox:"0 0 24 24",fill:"none",xmlns:"http://www.w3.org/2000/svg",ref:t,"aria-labelledby":r},o),n?i.createElement("title",{id:r},n):null,Ri||(Ri=i.createElement("defs",null,i.createElement("style",null,".a{fill:none;stroke:currentColor;stroke-linecap:round;stroke-linejoin:round;stroke-width:1.5px;}"))),Ui||(Ui=i.createElement("path",{d:"M22.939 2.56V8.817C22.9391 9.61244 22.6232 10.3754 22.061 10.938L10.5 22.5C10.2187 22.7812 9.83721 22.9392 9.43946 22.9392C9.04172 22.9392 8.66026 22.7812 8.37896 22.5L1.49997 15.62C1.21876 15.3387 1.06079 14.9572 1.06079 14.5595C1.06079 14.1618 1.21876 13.7803 1.49997 13.499L13.061 1.938C13.6236 1.37572 14.3865 1.0599 15.182 1.06H21.439C21.8368 1.06 22.2183 1.21803 22.4996 1.49934C22.7809 1.78064 22.939 2.16217 22.939 2.56V2.56Z",className:"a"})),Ai||(Ai=i.createElement("path",{d:"M17.689 7.81C16.8605 7.81 16.189 7.13842 16.189 6.31C16.189 5.48157 16.8605 4.81 17.689 4.81C18.5174 4.81 19.189 5.48157 19.189 6.31C19.189 7.13842 18.5174 7.81 17.689 7.81Z",className:"a"})))}var Qi=i.forwardRef(Wi),Vi=(n.p,n(1)),Yi=function(e){var t=e.avatar,n=e.brandColor;return Object($n.jsx)($n.Fragment,{children:Object($n.jsx)(er,{gravatar:t,style:{userIcon:{color:n,width:"56px",height:"56px",padding:"2px"}}})})},Ki=function(e){e.onClose;var t=e.handleSignout,n=e.supportAddress,r="mailto:".concat(void 0===n?"":n);return Object($n.jsxs)("footer",{className:"gh-portal-account-footer",children:[Object($n.jsx)("ul",{className:"gh-portal-account-footermenu",children:Object($n.jsx)("li",{children:Object($n.jsx)("button",{className:"gh-portal-btn",name:"logout","aria-label":"logout",onClick:function(e){return t(e)},children:"Sign out"})})}),Object($n.jsx)("div",{className:"gh-portal-account-footerright",children:Object($n.jsx)("ul",{className:"gh-portal-account-footermenu",children:Object($n.jsx)("li",{children:Object($n.jsx)("a",{className:"gh-portal-btn gh-portal-btn-branded",href:r,onClick:function(){r&&window.open(r)},children:"Contact support"})})})})]})},Gi=function(){var e=Object(i.useContext)(tr),t=e.member,n=e.brandColor,r=t.avatar_image;return Object($n.jsxs)("header",{className:"gh-portal-account-header",children:[Object($n.jsx)(Yi,{avatar:r,brandColor:n}),Object($n.jsx)("h2",{className:"gh-portal-main-title",children:"Your account"})]})};function Ji(e){var t=e.subscription;e.priceLabel;if(Object(Fr.subscriptionHasFreeTrial)({sub:t})){var n=Object(Bi.a)(t.trial_end_at);return Object($n.jsx)("p",{className:"gh-portal-account-discountcontainer",children:Object($n.jsx)("div",{children:Object($n.jsxs)("span",{children:["Free Trial \u2013 Ends ",n]})})})}return null}var Xi=function(){var e=Object(i.useContext)(tr),t=e.member,n=e.site,r=e.onAction,o=function(e){var n=e.price,r=e.isComplimentary,i=e.subscription,o=i||{},a=o.offer,l=o.start_date,s="";if(n){var c=n.amount,u=void 0===c?0:c,p=n.currency,d=n.interval;s="".concat(Intl.NumberFormat("en",{currency:p,style:"currency"}).format(u/100),"/").concat(d)}var f=function(e){var t=e.offer,n=e.price,r=e.subscriptionStartDate,i="";if(t){var o=t.duration,a="";if("forever"===o)a="Forever";else if("repeating"===o){var l=t.duration_in_months||0,s=new Date(r),c=new Date(s.setMonth(s.getMonth()+l));a="Ends ".concat(Object(Bi.a)(c))}i="".concat(Object(Fr.getUpdatedOfferPrice)({offer:t,price:n,useFormatted:!0}),"/").concat(n.interval).concat(a?" \u2014 ".concat(a):"")}return i}({price:n,offer:a,subscriptionStartDate:l}),h=Object(Fr.getCompExpiry)({member:t});r&&(s=h?"Complimentary - Expires ".concat(h):s?"Complimentary (".concat(s,")"):"Complimentary");var m="";f&&(m="gh-portal-account-old-price");var g=function(){return f?Object($n.jsxs)("p",{className:"gh-portal-account-discountcontainer",children:[Object($n.jsx)(Qi,{className:"gh-portal-account-tagicon"}),Object($n.jsx)("span",{children:f})]}):null},b=Object(Fr.subscriptionHasFreeTrial)({sub:i});return b&&(m="gh-portal-account-old-price"),b?Object($n.jsxs)($n.Fragment,{children:[Object($n.jsx)("p",{className:m,children:s}),Object($n.jsx)(Ji,{subscription:i})]}):Object($n.jsxs)($n.Fragment,{children:[Object($n.jsx)("p",{className:m,children:s}),Object($n.jsx)(g,{})]})},a=function(e){var i=e.isComplimentary;return!Object(Fr.allowCompMemberUpgrade)({member:t})&&i||Object(Fr.hasOnlyFreePlan)({site:n})?null:Object($n.jsx)("button",{className:"gh-portal-btn gh-portal-btn-list",onClick:function(e){n.is_stripe_configured&&r("switchPage",{page:"accountPlan",lastPage:"accountHome"})},children:"Change"})},l=function(e){var t=e.defaultCardLast4;if(t){var n="**** **** **** ".concat(t);return Object($n.jsx)("p",{children:n})}return null},s=function(e){var n=e.defaultCardLast4,o=e.isComplimentary,a="editBilling:running"===Object(i.useContext)(tr).action?Object($n.jsx)(Si,{className:"gh-portal-billing-button-loader"}):"Update";return o?null:Object($n.jsxs)("section",{children:[Object($n.jsxs)("div",{className:"gh-portal-list-detail",children:[Object($n.jsx)("h3",{children:"Billing info"}),Object($n.jsx)(l,{defaultCardLast4:n})]}),Object($n.jsx)("button",{className:"gh-portal-btn gh-portal-btn-list",onClick:function(e){return function(){var e=Object(Fr.getMemberSubscription)({member:t});r("editBilling",{subscriptionId:e.id})}()},children:a})]})},c=Object(Fr.getMemberSubscription)({member:t}),u=Object(Fr.isComplimentaryMember)({member:t});if(c||u){var p=c||{},d=p.price,f=p.default_payment_card_last4,h="Plan";return Object(Fr.hasMultipleProductsFeature)({site:n})&&Object(Fr.getMemberTierName)({member:t})&&(h=Object(Fr.getMemberTierName)({member:t})),Object($n.jsxs)($n.Fragment,{children:[Object($n.jsxs)("section",{children:[Object($n.jsxs)("div",{className:"gh-portal-list-detail",children:[Object($n.jsx)("h3",{children:h}),Object($n.jsx)(o,{price:d,isComplimentary:u,subscription:c})]}),Object($n.jsx)(a,{isComplimentary:u})]}),Object($n.jsx)(s,{isComplimentary:u,defaultCardLast4:f})]})}return null},Zi=function(){var e=Object(i.useContext)(tr),t=e.member,n=e.onAction,r=t.name,o=t.email;return Object($n.jsx)("div",{children:Object($n.jsxs)("div",{className:"gh-portal-list",children:[Object($n.jsxs)("section",{children:[Object($n.jsxs)("div",{className:"gh-portal-list-detail",children:[Object($n.jsx)("h3",{children:r||"Account"}),Object($n.jsx)("p",{children:o})]}),Object($n.jsx)("button",{className:"gh-portal-btn gh-portal-btn-list",onClick:function(e){n("switchPage",{page:"accountProfile",lastPage:"accountHome"})},children:"Edit"})]}),Object($n.jsx)(Xi,{}),Object($n.jsx)(to,{}),Object($n.jsx)(eo,{})]})})};function eo(){var e=Object(i.useContext)(tr),t=e.member,n=e.site,r=e.onAction,o=t.newsletters;if(Object(Fr.hasMultipleNewsletters)({site:n})||Object(Fr.hasCommentsEnabled)({site:n}))return null;var a=!(null===o||void 0===o||!o.length),l=a?"Subscribed":"Unsubscribed";return Object($n.jsxs)("section",{children:[Object($n.jsxs)("div",{className:"gh-portal-list-detail",children:[Object($n.jsx)("h3",{children:"Email newsletter"}),Object($n.jsx)("p",{children:l})]}),Object($n.jsx)("div",{children:Object($n.jsx)(Di,{id:"default-newsletter-toggle",onToggle:function(e){!function(e,i){var o;e.preventDefault();var a=Object(Fr.getSiteNewsletters)({site:n}),l=null!==t&&void 0!==t&&null!==(o=t.newsletters)&&void 0!==o&&o.length?[]:a;r("updateNewsletterPreference",{newsletters:l})}(e)},checked:a})})]})}function to(){var e=Object(i.useContext)(tr),t=e.site,n=e.onAction;return Object(Fr.hasMultipleNewsletters)({site:t})||Object(Fr.hasCommentsEnabled)({site:t})?Object($n.jsxs)("section",{children:[Object($n.jsxs)("div",{className:"gh-portal-list-detail",children:[Object($n.jsx)("h3",{children:"Emails"}),Object($n.jsx)("p",{children:"Update your preferences"})]}),Object($n.jsx)("button",{className:"gh-portal-btn gh-portal-btn-list",onClick:function(e){n("switchPage",{page:"accountEmail",lastPage:"accountHome"})},children:"Manage"})]}):null}var no=function(){var e=Object(i.useContext)(tr),t=e.site,n=e.action,r=e.brandColor,o=e.onAction;if(!t.is_stripe_configured||Object(Fr.hasOnlyFreePlan)({site:t}))return null;var a=["checkoutPlan:running"].includes(n);return Object($n.jsx)(Ci,{isRunning:a,label:"View plans",onClick:function(){o("switchPage",{page:"accountPlan",lastPage:"accountHome"})},brandColor:r,style:{width:"100%"}})},ro=function(){var e=Object(i.useContext)(tr),t=e.member,n=e.site;if(!n.is_stripe_configured||Object(Fr.hasOnlyFreePlan)({site:n}))return null;var r=Object(Fr.getMemberSubscription)({member:t}),o=Object(Fr.isComplimentaryMember)({member:t});if(o&&!r)return null;if(r){var a=null===r||void 0===r?void 0:r.current_period_end;if(o&&Object(Fr.getCompExpiry)({member:t})){var l=Object(Fr.getCompExpiry)({member:t}),s=Object(Bi.a)(l);return Object($n.jsx)("div",{className:"gh-portal-section",children:Object($n.jsxs)("p",{className:"gh-portal-text-center gh-portal-free-ctatext",children:["Your subscription will expire on ",s]})})}if(null!==r&&void 0!==r&&r.cancel_at_period_end)return null;if(Object(Fr.subscriptionHasFreeTrial)({sub:r})){var c=Object(Bi.a)(r.trial_end_at);return Object($n.jsx)("div",{className:"gh-portal-section",children:Object($n.jsxs)("p",{className:"gh-portal-text-center gh-portal-free-ctatext",children:["Your subscription will start on ",c]})})}return Object($n.jsx)("div",{className:"gh-portal-section",children:Object($n.jsxs)("p",{className:"gh-portal-text-center gh-portal-free-ctatext",children:["Your subscription will renew on ",Object(Bi.a)(a)]})})}return Object($n.jsxs)("div",{className:"gh-portal-section",children:[Object($n.jsx)("p",{className:"gh-portal-text-center gh-portal-free-ctatext",children:"You currently have a free membership, upgrade to a paid subscription for full access."}),Object($n.jsx)(no,{})]})},io=function(){var e=Object(i.useContext)(tr),t=e.member,n=e.onAction,r=e.action,o=e.brandColor,a=Object(Fr.getMemberSubscription)({member:t});if(!a)return null;if(!a.cancel_at_period_end)return null;var l=a.cancel_at_period_end?"Continue subscription":"Cancel subscription",s=["cancelSubscription:running"].includes(r),c=!!s,u=!!a.cancel_at_period_end,p=function(){if(!a.cancel_at_period_end)return null;var e=a.current_period_end;return Object($n.jsxs)("p",{className:"gh-portal-text-center gh-portal-free-ctatext",children:["Your subscription will expire on ",Object(Bi.a)(e)]})};return Object($n.jsxs)("div",{className:"gh-portal-cancelcontinue-container",children:[Object($n.jsx)(p,{}),Object($n.jsx)(Ci,{onClick:function(e){n("continueSubscription",{subscriptionId:a.id})},isRunning:s,disabled:c,isPrimary:u,brandColor:o,label:l,style:{width:"100%"}})]})},oo=function(){return Object($n.jsxs)("div",{className:"gh-portal-content gh-portal-account-main",children:[Object($n.jsx)(zi,{}),Object($n.jsx)(Gi,{}),Object($n.jsxs)("section",{className:"gh-portal-account-data",children:[Object($n.jsx)(ro,{}),Object($n.jsx)(io,{}),Object($n.jsx)(Zi,{})]})]})},ao=function(e){v(n,e);var t=O(n);function n(){return h(this,n),t.apply(this,arguments)}return g(n,[{key:"componentDidMount",value:function(){this.context.member||this.context.onAction("switchPage",{page:"signin"})}},{key:"handleSignout",value:function(e){e.preventDefault(),this.context.onAction("signout")}},{key:"render",value:function(){var e=this,t=this.context,n=t.member,r=t.site,i=Object(Fr.getSupportAddress)({site:r});return n?Object($n.jsxs)("div",{className:"gh-portal-account-wrapper",children:[Object($n.jsx)(oo,{}),Object($n.jsx)(Ki,{onClose:function(){return e.context.onAction("closePopup")},handleSignout:function(t){return e.handleSignout(t)},supportAddress:i})]}):null}}]),n}(Vi.Component);ao.contextType=tr;var lo,so=n(21),co=n.n(so),uo=["title","titleId"];function po(){return po=Object.assign||function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(e[r]=n[r])}return e},po.apply(this,arguments)}function fo(e,t){if(null==e)return{};var n,r,i=function(e,t){if(null==e)return{};var n,r,i={},o=Object.keys(e);for(r=0;r<o.length;r++)n=o[r],t.indexOf(n)>=0||(i[n]=e[n]);return i}(e,t);if(Object.getOwnPropertySymbols){var o=Object.getOwnPropertySymbols(e);for(r=0;r<o.length;r++)n=o[r],t.indexOf(n)>=0||Object.prototype.propertyIsEnumerable.call(e,n)&&(i[n]=e[n])}return i}function ho(e,t){var n=e.title,r=e.titleId,o=fo(e,uo);return i.createElement("svg",po({width:15,height:14,viewBox:"0 0 15 14",fill:"none",xmlns:"http://www.w3.org/2000/svg",ref:t,"aria-labelledby":r},o),n?i.createElement("title",{id:r},n):null,lo||(lo=i.createElement("path",{d:"M1 6.89286L6.10714 12L13.9643 1",stroke:"#222222",strokeWidth:2})))}var mo=i.forwardRef(ho),go=(n.p,o.a.createContext({selectedInterval:"month",selectedProduct:"free",selectedPlan:null,setSelectedProduct:null}));function bo(e){var t=e.product;return t.benefits&&t.benefits.length?t.benefits.map((function(e,t){var n=(null===e||void 0===e?void 0:e.id)||"benefit-".concat(t);return Object($n.jsxs)("div",{className:"gh-portal-product-benefit",children:[Object($n.jsx)(mo,{className:"gh-portal-benefit-checkmark",alt:""}),Object($n.jsx)("div",{className:"gh-portal-benefit-title",children:e.name})]},n)})):null}function vo(e){var t=e.product,n=e.hide,r=void 0!==n&&n;if(!t.benefits||!t.benefits.length||r)return null;return Object($n.jsx)("div",{className:"gh-portal-product-benefits",children:Object($n.jsx)(bo,{product:t})})}function yo(e){var t=e.price,n=Object(i.useContext)(tr).site.portal_plans;return n.includes("monthly")&&n.includes("yearly")?Object($n.jsx)("div",{className:"gh-portal-product-alternative-price",children:Object(Fr.getPriceString)(t)}):Object($n.jsx)("div",{className:"gh-portal-product-alternative-price"})}function xo(e){var t=e.trialDays,n=e.discount,r=e.selectedInterval,o=Object(i.useContext)(tr).site;return Object(Fr.hasFreeTrialTier)({site:o})?t?Object($n.jsxs)("span",{className:"gh-portal-discount-label",children:[t," days free"]}):null:"year"===r?Object($n.jsxs)("span",{className:"gh-portal-discount-label",children:[n,"% discount"]}):null}function wo(e){var t=e.product,n=Object(i.useContext)(go).selectedInterval,r=Object(i.useContext)(tr).site,o=t.monthlyPrice,a=t.yearlyPrice,l=t.trial_days,s="month"===n?o:a,c="month"===n?a:o;if(!o||!a)return null;var u=co()(t.monthlyPrice.amount,t.yearlyPrice.amount),p=Object(Fr.getCurrencySymbol)(s.currency);return Object(Fr.hasFreeTrialTier)({site:r})?Object($n.jsx)($n.Fragment,{children:Object($n.jsxs)("div",{className:"gh-portal-product-card-pricecontainer",children:[Object($n.jsxs)("div",{className:"gh-portal-product-card-price-trial",children:[Object($n.jsxs)("div",{className:"gh-portal-product-price",children:[Object($n.jsx)("span",{className:"currency-sign"+(p.length>1?" long":""),children:p}),Object($n.jsx)("span",{className:"amount",children:Object(Fr.formatNumber)(Object(Fr.getStripeAmount)(s.amount))}),Object($n.jsxs)("span",{className:"billing-period",children:["/",s.interval]})]}),Object($n.jsx)(xo,{trialDays:l,discount:u,selectedInterval:n})]}),"year"===n?Object($n.jsx)(So,{discount:u,trialDays:l}):"",Object($n.jsx)(yo,{price:c})]})}):Object($n.jsxs)("div",{className:"gh-portal-product-card-pricecontainer",children:[Object($n.jsxs)("div",{className:"gh-portal-product-card-price-trial",children:[Object($n.jsxs)("div",{className:"gh-portal-product-price",children:[Object($n.jsx)("span",{className:"currency-sign"+(p.length>1?" long":""),children:p}),Object($n.jsx)("span",{className:"amount",children:Object(Fr.formatNumber)(Object(Fr.getStripeAmount)(s.amount))}),Object($n.jsxs)("span",{className:"billing-period",children:["/",s.interval]})]}),"year"===n?Object($n.jsx)(So,{discount:u}):""]}),Object($n.jsx)(yo,{price:c})]})}function jo(e){var t=e.products,n=e.handleChooseSignup,r=Object(i.useContext)(tr),o=r.site,a=r.action,l=Object(i.useContext)(go),s=l.selectedProduct,c=l.setSelectedProduct,u="free"===s?"gh-portal-product-card free checked":"gh-portal-product-card free",p=Object(Fr.getFreeProduct)({site:o}),d=Object(Fr.getFreeTierDescription)({site:o}),f="signup:running"===a;Object(Fr.isCookiesDisabled)()&&(f=!0);var h="$";h=t&&t[1]?Object(Fr.getCurrencySymbol)(t[1].monthlyPrice.currency):"$";var m=Object(Fr.hasOnlyFreeProduct)({site:o}),g=Object(Fr.getFreeProductBenefits)({site:o});if(m){if(!d&&!g.length)return null;u+=" only-free"}return d||g.length||(d="Free preview"),Object($n.jsx)($n.Fragment,{children:Object($n.jsxs)("div",{className:u,onClick:function(e){e.stopPropagation(),c("free")},children:[Object($n.jsxs)("div",{className:"gh-portal-product-card-header",children:[Object($n.jsx)("h4",{className:"gh-portal-product-name",children:Object(Fr.getFreeTierTitle)({site:o})}),m?"":Object($n.jsx)("div",{className:"gh-portal-product-card-pricecontainer free-trial-disabled",children:Object($n.jsxs)("div",{className:"gh-portal-product-price",children:[Object($n.jsx)("span",{className:"currency-sign"+(h.length>1?" long":""),children:h}),Object($n.jsx)("span",{className:"amount",children:"0"})]})})]}),Object($n.jsxs)("div",{className:"gh-portal-product-card-details",children:[Object($n.jsxs)("div",{className:"gh-portal-product-card-detaildata",children:[d?Object($n.jsx)("div",{className:"gh-portal-product-description",children:d}):"",Object($n.jsx)(vo,{product:p})]}),m?"":Object($n.jsx)("div",{className:"gh-portal-btn-product",children:Object($n.jsx)("button",{className:"gh-portal-btn",disabled:f,onClick:function(e){n(e,"free")},children:"free"===s&&f?Object($n.jsx)(Si,{className:"gh-portal-loadingicon"}):"Choose"})})]})]})})}function Oo(e){var t=e.selectedProduct,n=e.product,r=e.disabled,i=e.noOfProducts,o=e.trialDays;return t===n.id&&r?Object($n.jsx)(Si,{className:"gh-portal-loadingicon"}):o>0?"Start "+o+"-day free trial":i>1?"Choose":"Continue"}function ko(e){var t,n=e.product,r=e.products,o=e.selectedInterval,a=e.handleChooseSignup,l=Object(i.useContext)(go),s=l.selectedProduct,c=l.setSelectedProduct,u=Object(i.useContext)(tr).action,p=n.trial_days,d=s===n.id?"gh-portal-product-card checked":"gh-portal-product-card",f=null===r||void 0===r||null===(t=r.filter((function(e){return"paid"===e.type})))||void 0===t?void 0:t.length,h=!!["signup:running","checkoutPlan:running"].includes(u);Object(Fr.isCookiesDisabled)()&&(h=!0);var m=n.description;return n.benefits&&n.benefits.length||m||(m="Full access"),Object($n.jsx)($n.Fragment,{children:Object($n.jsxs)("div",{className:d,onClick:function(e){e.stopPropagation(),c(n.id)},children:[Object($n.jsxs)("div",{className:"gh-portal-product-card-header",children:[Object($n.jsx)("h4",{className:"gh-portal-product-name",children:n.name}),Object($n.jsx)(wo,{product:n})]}),Object($n.jsxs)("div",{className:"gh-portal-product-card-details",children:[Object($n.jsxs)("div",{className:"gh-portal-product-card-detaildata",children:[Object($n.jsx)("div",{className:"gh-portal-product-description",children:m}),Object($n.jsx)(vo,{product:n})]}),Object($n.jsx)("div",{className:"gh-portal-btn-product",children:Object($n.jsx)("button",{disabled:h,className:"gh-portal-btn",onClick:function(e){var t=Eo({products:r,selectedInterval:o,selectedProduct:n.id});a(e,t.id)},children:Object($n.jsx)(Oo,{selectedProduct:s,product:n,disabled:h,noOfProducts:f,trialDays:p})})})]})]},n.id)})}function _o(e){var t=e.products,n=e.selectedInterval,r=e.handleChooseSignup;return t.map((function(e){return"free"===e.id?Object($n.jsx)(jo,{products:t,handleChooseSignup:r},e.id):Object($n.jsx)(ko,{products:t,product:e,selectedInterval:n,handleChooseSignup:r},e.id)}))}function So(e){var t=e.discount,n=(e.trialDays,Object(i.useContext)(tr).site),r=n.portal_plans;return 0!==t&&r.includes("monthly")?Object(Fr.hasFreeTrialTier)({site:n})?Object($n.jsx)($n.Fragment,{children:Object($n.jsxs)("span",{className:"gh-portal-discount-label-trial",children:[t,"% discount"]})}):Object($n.jsx)($n.Fragment,{children:Object($n.jsxs)("span",{className:"gh-portal-discount-label",children:[t,"% discount"]})}):null}function Po(e){e.products;var t=e.selectedInterval,n=e.setSelectedInterval,r=Object(i.useContext)(tr).site.portal_plans;return r.includes("monthly")&&r.includes("yearly")?Object($n.jsx)("div",{className:"gh-portal-logged-out-form-container",children:Object($n.jsxs)("div",{className:"gh-portal-products-pricetoggle"+("month"===t?" left":""),children:[Object($n.jsx)("button",{className:"gh-portal-btn"+("month"===t?" active":""),onClick:function(e){n("month")},children:"Monthly"}),Object($n.jsx)("button",{className:"gh-portal-btn"+("year"===t?" active":""),onClick:function(e){n("year")},children:"Yearly"})]})}):null}function Eo(e){var t=e.products,n=e.selectedProduct,r=e.selectedInterval,i=null;if("free"===n)i={id:"free"};else{var o,a,l=t.find((function(e){return e.id===n}));l||(l=t.find((function(e){return"paid"===e.type}))),i="month"===r?null===(o=l)||void 0===o?void 0:o.monthlyPrice:null===(a=l)||void 0===a?void 0:a.yearlyPrice}return i}function Co(e){var t=e.portalPlans,n=e.selectedInterval,r=void 0===n?"year":n;return"month"===r&&t.includes("monthly")?"month":"year"===r&&t.includes("yearly")?"year":t.includes("monthly")?"month":t.includes("yearly")?"year":void 0}function No(e){var t,n=e.onPlanSelect,r=e.selectedPlan,o=e.products,a=e.type,l=void 0===a?null:a,c=Object(i.useContext)(tr),u=c.site,p=c.member,d=u.portal_plans,f=Object(Fr.getMemberActivePrice)({member:p}),h=Object(Fr.getProductFromPrice)({site:u,priceId:f.id}),m=Co({portalPlans:d,selectedInterval:f.interval}),g=(null===h||void 0===h?void 0:h.id)||(null===o||void 0===o||null===(t=o[0])||void 0===t?void 0:t.id),b=Object(i.useState)(m),v=Object(s.a)(b,2),y=v[0],x=v[1],w=Object(i.useState)(g),j=Object(s.a)(w,2),O=j[0],k=j[1],_=Co({portalPlans:d,selectedInterval:y});if(Object(i.useEffect)((function(){k(g)}),[g]),!d.includes("monthly")&&!d.includes("yearly"))return null;if(0===o.length)return null;var S="gh-portal-products";return"upgrade"===l&&(S+=" gh-portal-upgrade-product"),"changePlan"===l&&(S+=" gh-portal-upgrade-product gh-portal-change-plan"),Object($n.jsx)(go.Provider,{value:{selectedInterval:_,selectedProduct:O,selectedPlan:r,setSelectedProduct:k},children:Object($n.jsxs)("section",{className:S,children:[Object($n.jsx)(Po,{selectedInterval:_,setSelectedInterval:x}),Object($n.jsx)("div",{className:"gh-portal-products-grid",children:Object($n.jsx)(Lo,{products:o,onPlanSelect:n})})]})})}function To(e){var t=e.product;e.selectedPrice,e.activePrice;return null!==t&&void 0!==t&&t.description?Object($n.jsx)("div",{className:"gh-portal-product-description",children:t.description}):null}function Io(e){var t=e.product,n=e.onPlanSelect,r=Object(i.useContext)(tr),o=r.member,a=r.site,l=Object(i.useContext)(go),s=l.selectedProduct,c=l.setSelectedProduct,u=l.selectedInterval,p=s===t.id?"gh-portal-product-card checked":"gh-portal-product-card",d=t.monthlyPrice,f=t.yearlyPrice,h=Object(Fr.getMemberActivePrice)({member:o}),m="month"===u?d:f,g=Object(Fr.isMemberActivePrice)({member:o,site:a,priceId:m.id});return Object($n.jsxs)("div",{className:p+(g?" disabled":""),onClick:function(e){e.stopPropagation(),c(t.id)},children:[Object($n.jsxs)("div",{className:"gh-portal-product-card-header",children:[Object($n.jsx)("h4",{className:"gh-portal-product-name",children:t.name}),Object($n.jsx)(wo,{product:t})]}),Object($n.jsxs)("div",{className:"gh-portal-product-card-details",children:[Object($n.jsxs)("div",{className:"gh-portal-product-card-detaildata",children:[t.description?Object($n.jsx)(To,{product:t,selectedPrice:m,activePrice:h}):"",Object($n.jsx)(vo,{product:t})]}),g?Object($n.jsx)("div",{className:"gh-portal-btn-product",children:Object($n.jsx)("span",{className:"gh-portal-current-plan",children:Object($n.jsx)("span",{children:"Current plan"})})}):Object($n.jsx)("div",{className:"gh-portal-btn-product",children:Object($n.jsx)("button",{className:"gh-portal-btn",onClick:function(){n(null,null===m||void 0===m?void 0:m.id)},children:"Choose"})})]})]},t.id)}function Lo(e){var t=e.products,n=e.onPlanSelect;return t.map((function(e){return"free"===e.id?null:Object($n.jsx)(Io,{product:e,onPlanSelect:n},e.id)}))}var Mo=function(e){var t,n,r=e.onPlanSelect,o=e.products,a=e.type,l=void 0===a?null:a,c=e.handleChooseSignup,u=Object(i.useContext)(tr).site,p=u.portal_plans,d=Co({portalPlans:p}),f=o.length>0?o[0].id:"free",h=Object(i.useState)(d),m=Object(s.a)(h,2),g=m[0],b=m[1],v=Object(i.useState)(f),y=Object(s.a)(v,2),x=y[0],w=y[1],j=Eo({products:o,selectedInterval:g,selectedProduct:x}),O=Co({portalPlans:p,selectedInterval:g});if(Object(i.useEffect)((function(){w(f)}),[f]),Object(i.useEffect)((function(){r(null,j.id)}),[j.id,r]),!p.includes("monthly")&&!p.includes("yearly"))return null;if(0===o.length)return null;var k="gh-portal-products";"upgrade"===l&&(k+=" gh-portal-upgrade-product");var _=(null===(t=o.find((function(e){return e.id===x})))||void 0===t?void 0:t.id)||(null===(n=o.find((function(e){return"paid"===e.type})))||void 0===n?void 0:n.id);return Object($n.jsx)(go.Provider,{value:{selectedInterval:O,selectedProduct:_,setSelectedProduct:w},children:Object($n.jsxs)("section",{className:k,children:[Object(Fr.hasOnlyFreeProduct)({site:u})?"":Object($n.jsx)(Po,{products:o,selectedInterval:O,setSelectedInterval:b}),Object($n.jsx)("div",{className:"gh-portal-products-grid",children:Object($n.jsx)(_o,{products:o,selectedInterval:O,handleChooseSignup:c})})]})})};function Fo(e){var t=e.products,n=e.selectedPlan,r=e.onPlanSelect,i=e.onPlanCheckout,o=e.changePlan,a=void 0!==o&&o;return Object(Fr.isCookiesDisabled)()&&(r=function(){}),a?Object($n.jsx)("section",{className:"gh-portal-plans",children:Object($n.jsx)("div",{children:Object($n.jsx)(No,{type:"changePlan",products:t,selectedPlan:n,onPlanSelect:r})})}):Object($n.jsx)("section",{className:"gh-portal-plans",children:Object($n.jsx)("div",{children:Object($n.jsx)(Mo,{type:"upgrade",products:t,onPlanSelect:r,handleChooseSignup:function(){i.apply(void 0,arguments)}})})})}var Do=n(1);var zo=function(e){e.onBack;var t=e.showConfirmation,n=e.confirmationType,r=Object(i.useContext)(tr).member,o=Object(Fr.isPaidMember)({member:r})?"Change plan":"Choose a plan";return t&&(o=function(e){var t=e.confirmationType;return"changePlan"===t?"Confirm subscription":"cancel"===t?"Cancel subscription":"subscribe"===t?"Subscribe":void 0}({confirmationType:n})),Object($n.jsx)("header",{className:"gh-portal-detail-header",children:Object($n.jsx)("h3",{className:"gh-portal-main-title",children:o})})},Ro=function(e){var t=e.member,n=e.onCancelSubscription,r=e.action,o=e.brandColor,a=Object(i.useContext)(tr).site;if(!t.paid)return null;var l=Object(Fr.getMemberSubscription)({member:t});if(!l)return null;if(l.cancel_at_period_end)return null;var s=["cancelSubscription:running"].includes(r),c=!!s,u=!!l.cancel_at_period_end,p=!l.cancelAtPeriodEnd;return Object($n.jsx)("div",{className:"gh-portal-expire-container",children:Object($n.jsx)(Ci,{onClick:function(e){n({subscriptionId:l.id,cancelAtPeriodEnd:!0})},isRunning:s,disabled:c,isPrimary:u,isDestructive:p,classes:Object(Fr.hasMultipleProductsFeature)({site:a})?"gh-portal-btn-text mt2 mb4":"",brandColor:o,label:"Cancel subscription",style:{width:"100%"}})})},Uo=function(e){var t=e.plan,n=e.type,r=e.onConfirm,o=Object(i.useContext)(tr),a=o.site,l=o.action,c=o.member,u=o.brandColor,p=Object(i.useState)(""),d=Object(s.a)(p,2),f=d[0],h=d[1],m=Object(Fr.getMemberSubscription)({member:c}),g=["updateSubscription:running","checkoutPlan:running","cancelSubscription:running"].includes(l),b="Confirm",v=Object(Bi.a)(m.current_period_end);Object(Fr.getMemberActivePrice)({member:c}).id!==t.id&&(v="today");var y=Object(Fr.formatNumber)(t.price),x="".concat(t.currency_symbol).concat(y,"/").concat(t.interval," \u2013 Starting ").concat(v),w=Object(Fr.getProductFromPrice)({site:a,priceId:null===t||void 0===t?void 0:t.id}),j=Object(Fr.hasMultipleProductsFeature)({site:a})?null===w||void 0===w?void 0:w.name:"Price";return"changePlan"===n?Object($n.jsxs)("div",{className:"gh-portal-logged-out-form-container",children:[Object($n.jsxs)("div",{className:"gh-portal-list mb6",children:[Object($n.jsx)("section",{children:Object($n.jsxs)("div",{className:"gh-portal-list-detail",children:[Object($n.jsx)("h3",{children:"Account"}),Object($n.jsx)("p",{children:c.email})]})}),Object($n.jsx)("section",{children:Object($n.jsxs)("div",{className:"gh-portal-list-detail",children:[Object($n.jsx)("h3",{children:j}),Object($n.jsx)("p",{children:x})]})})]}),Object($n.jsx)(Ci,{onClick:function(e){return r(e,t)},isRunning:g,isPrimary:!0,brandColor:u,label:b,style:{width:"100%",height:"40px"}})]}):Object($n.jsxs)("div",{className:"gh-portal-logged-out-form-container gh-portal-cancellation-form",children:[Object($n.jsxs)("p",{children:["If you cancel your subscription now, you will continue to have access until ",Object($n.jsx)("strong",{children:Object(Bi.a)(m.current_period_end)}),"."]}),Object($n.jsxs)("section",{className:"gh-portal-input-section",children:[Object($n.jsx)("div",{className:"gh-portal-input-labelcontainer",children:Object($n.jsx)("label",{className:"gh-portal-input-label",children:"Cancellation reason"})}),Object($n.jsx)("textarea",{className:"gh-portal-input",label:"Cancellation reason",type:"text",name:"cancellation_reason",placeholder:"",value:f,onChange:function(e){return h(e.target.value)},rows:"2",maxLength:"500"},"cancellation_reason")]}),Object($n.jsx)(Ci,{onClick:function(e){return r(e,f)},isRunning:g,isPrimary:!0,brandColor:u,label:b+" cancellation",style:{width:"100%",height:"40px"}})]})},Ao=function(e){var t=e.plans,n=e.selectedPlan,r=e.onPlanSelect,o=e.onCancelSubscription,a=Object(i.useContext)(tr),l=a.member,s=a.action,c=a.brandColor;return Object($n.jsxs)("section",{children:[Object($n.jsx)("div",{className:"gh-portal-section gh-portal-accountplans-main",children:Object($n.jsx)(Bo,{showLabel:!1,plans:t,selectedPlan:n,onPlanSelect:r,changePlan:!0})}),Object($n.jsx)(Ro,{member:l,onCancelSubscription:o,action:s,brandColor:c})]})};function Bo(e){e.showLabel,e.plans;var t=e.selectedPlan,n=e.onPlanSelect,r=e.onPlanCheckout,o=e.changePlan,a=void 0!==o&&o,l=Object(i.useContext)(tr),s=l.site,c=l.member,u=Object(Fr.getUpgradeProducts)({site:s,member:c});return Object($n.jsx)(Fo,{products:u,selectedPlan:t,changePlan:a,onPlanSelect:n,onPlanCheckout:r})}var Ho=function(e){var t=e.plans,n=e.selectedPlan,r=e.onPlanSelect,i=e.onPlanCheckout,o="";return 1===t.length&&(o="singleplan"),Object($n.jsx)("section",{children:Object($n.jsx)("div",{className:"gh-portal-section gh-portal-accountplans-main ".concat(o),children:Object($n.jsx)(Bo,{showLabel:!1,plans:t,selectedPlan:n,onPlanSelect:r,onPlanCheckout:i})})})},qo=function(e){var t=e.plans,n=e.selectedPlan,r=e.confirmationPlan,o=e.confirmationType,a=e.showConfirmation,l=void 0!==a&&a,s=e.onPlanSelect,c=e.onPlanCheckout,u=e.onConfirm,p=e.onCancelSubscription,d=Object(i.useContext)(tr).member,f=Object(Fr.allowCompMemberUpgrade)({member:d})&&Object(Fr.isComplimentaryMember)({member:d});return!Object(Fr.isPaidMember)({member:d})||f?Object($n.jsx)(Ho,{plans:t,selectedPlan:n,onPlanSelect:s,onPlanCheckout:c}):l?Object($n.jsx)(Uo,{plan:r,type:o,onConfirm:u}):Object($n.jsx)(Ao,{plans:t,selectedPlan:n,onCancelSubscription:p,onPlanSelect:s})},$o=function(e){v(n,e);var t=O(n);function n(e,r){var i;return h(this,n),(i=t.call(this,e,r)).onPlanSelect=function(e,t){null===e||void 0===e||e.preventDefault();var n=i.context.member,r=!!Object(Fr.allowCompMemberUpgrade)({member:n})&&Object(Fr.isComplimentaryMember)({member:n});if(!Object(Fr.isPaidMember)({member:n})||r)i.timeoutId=setTimeout((function(){i.setState((function(){return{selectedPlan:t}}))}),5);else{var o=i.prices.find((function(e){return e.id===t})),a=i.getActivePriceId({member:n})?"changePlan":"subscribe";t!==i.state.selectedPlan&&i.setState({confirmationPlan:o,confirmationType:a,showConfirmation:!0})}},i.state=i.getInitialState(),i}return g(n,[{key:"componentDidMount",value:function(){this.context.member||this.context.onAction("switchPage",{page:"signin"})}},{key:"componentWillUnmount",value:function(){clearTimeout(this.timeoutId)}},{key:"getInitialState",value:function(){var e=this.context,t=e.member,n=e.site;this.prices=Object(Fr.getAvailablePrices)({site:n});var r=Object(Fr.getMemberActivePrice)({member:t});r&&(this.prices=Object(Fr.getFilteredPrices)({prices:this.prices,currency:r.currency}));var i=r?this.prices.find((function(e){return e.id===r.id})):null;return!Object(Fr.isPaidMember)({member:t})&&this.prices.length>0&&(i=this.prices[0]),{selectedPlan:i?i.id:null}}},{key:"handleSignout",value:function(e){e.preventDefault(),this.context.onAction("signout")}},{key:"onBack",value:function(e){this.state.showConfirmation?this.cancelConfirmPage():this.context.onAction("back")}},{key:"cancelConfirmPage",value:function(){this.setState({showConfirmation:!1,confirmationPlan:null,confirmationType:null})}},{key:"onPlanCheckout",value:function(e,t){var n=this.context,r=n.onAction,i=n.member,o=this.state,a=o.confirmationPlan,l=o.selectedPlan;t&&(l=t);var s=!Object(Fr.allowCompMemberUpgrade)({member:i})||!Object(Fr.isComplimentaryMember)({member:i});if(Object(Fr.isPaidMember)({member:i})&&s){var c=Object(Fr.getMemberSubscription)({member:i}),u=c?c.id:"";u&&r("updateSubscription",{plan:a.name,planId:a.id,subscriptionId:u,cancelAtPeriodEnd:!1})}else r("checkoutPlan",{plan:l})}},{key:"onCancelSubscription",value:function(e){var t=e.subscriptionId,n=(e.cancelAtPeriodEnd,this.context.member),r=Object(Fr.getSubscriptionFromId)({subscriptionId:t,member:n}),i=Object(Fr.getPriceFromSubscription)({subscription:r});this.setState({showConfirmation:!0,confirmationPlan:i,confirmationType:"cancel"})}},{key:"onCancelSubscriptionConfirmation",value:function(e){var t=this.context.member,n=Object(Fr.getMemberSubscription)({member:t});if(!n)return null;this.context.onAction("cancelSubscription",{subscriptionId:n.id,cancelAtPeriodEnd:!0,cancellationReason:e})}},{key:"getActivePriceId",value:function(e){var t=e.member,n=Object(Fr.getMemberActivePrice)({member:t});return n?n.id:null}},{key:"onConfirm",value:function(e,t){var n=this.state.confirmationType;return"cancel"===n?this.onCancelSubscriptionConfirmation(t):["changePlan","subscribe"].includes(n)?this.onPlanCheckout():void 0}},{key:"render",value:function(){var e=this,t=this.prices,n=this.state,r=n.selectedPlan,i=n.showConfirmation,o=n.confirmationPlan,a=n.confirmationType,l=this.context.lastPage;return Object($n.jsx)($n.Fragment,{children:Object($n.jsxs)("div",{className:"gh-portal-content",children:[Object($n.jsx)(Fi,{onClick:function(t){return e.onBack(t)},hidden:!l&&!i}),Object($n.jsx)(zi,{}),Object($n.jsx)(zo,{onBack:function(t){return e.onBack(t)},confirmationType:a,showConfirmation:i}),Object($n.jsx)(qo,{plans:t,selectedPlan:r,showConfirmation:i,confirmationPlan:o,confirmationType:a,onConfirm:function(){return e.onConfirm.apply(e,arguments)},onCancelSubscription:function(t){return e.onCancelSubscription(t)},onPlanSelect:this.onPlanSelect,onPlanCheckout:function(t,n){return e.onPlanCheckout(t,n)}})]})})}}]),n}(Do.Component);$o.contextType=tr;function Wo(e){var t=e.message,n=e.style;return t?Object($n.jsx)("p",{style:Object(k.a)({},n||{}),children:t}):null}var Qo=function(e){var t=e.name,n=e.id,r=e.label,o=e.hideLabel,a=e.type,l=e.value,s=e.placeholder,c=e.disabled,u=void 0!==c&&c,p=e.onChange,d=void 0===p?function(){}:p,f=e.onBlur,h=void 0===f?function(){}:f,m=e.onKeyDown,g=void 0===m?function(){}:m,b=e.tabindex,v=e.maxlength,y=e.autoFocus,x=e.errorMessage,w=Object(i.useRef)(null);n=n||"input-".concat(t);var j=o?"gh-portal-input-label hidden":"gh-portal-input-label",O=x?"gh-portal-input error":"gh-portal-input";Object(Fr.isCookiesDisabled)()&&(u=!0),Ur(["preview"])&&(u=!0);var k="",_="",S="";switch(n){case"input-email":k="off",_="off",S="off";break;case"input-name":k="off",_="off"}return Object(i.useEffect)((function(){y&&w.current.focus()}),[y]),Object($n.jsxs)("section",{className:"gh-portal-input-section",children:[Object($n.jsxs)("div",{className:"gh-portal-input-labelcontainer",children:[Object($n.jsxs)("label",{htmlFor:n,className:j,children:[" ",r," "]}),Object($n.jsx)(Wo,{message:x,name:t})]}),Object($n.jsx)("input",{ref:w,id:n,className:O,type:a,name:t,value:l,placeholder:s,onChange:function(e){return d(e,t)},onKeyDown:function(e){return g(e,t)},onBlur:function(e){return h(e,t)},disabled:u,tabIndex:b,maxLength:v,autoComplete:k,autoCorrect:_,autoCapitalize:S,"aria-label":r})]})},Vo=n(12),Yo=function(e){v(n,e);var t=O(n);function n(){return h(this,n),t.apply(this,arguments)}return g(n,[{key:"render",value:function(){var e=this;return Object($n.jsx)($n.Fragment,{children:Object($n.jsxs)("button",{className:"gh-portal-btn gh-portal-btn-site-title-back",onClick:function(){e.props.onBack?e.props.onBack():e.context.onAction("closePopup")},children:[Object($n.jsx)("span",{children:"\u2190 "})," Back"]})})}}]),n}(o.a.Component);Yo.contextType=tr;var Ko=["title","titleId"];function Go(){return Go=Object.assign||function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(e[r]=n[r])}return e},Go.apply(this,arguments)}function Jo(e,t){if(null==e)return{};var n,r,i=function(e,t){if(null==e)return{};var n,r,i={},o=Object.keys(e);for(r=0;r<o.length;r++)n=o[r],t.indexOf(n)>=0||(i[n]=e[n]);return i}(e,t);if(Object.getOwnPropertySymbols){var o=Object.getOwnPropertySymbols(e);for(r=0;r<o.length;r++)n=o[r],t.indexOf(n)>=0||Object.prototype.propertyIsEnumerable.call(e,n)&&(i[n]=e[n])}return i}function Xo(e,t){var n=e.title,r=e.titleId,o=Jo(e,Ko);return i.createElement("svg",Go({xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 16 16",ref:t,"aria-labelledby":r},o),n?i.createElement("title",{id:r},n):null,i.createElement("g",{transform:"matrix(0.6666666666666666,0,0,0.6666666666666666,0,0)"},i.createElement("path",{d:"M19.5,9.5h-.75V6.75a6.75,6.75,0,0,0-13.5,0V9.5H4.5a2,2,0,0,0-2,2V22a2,2,0,0,0,2,2h15a2,2,0,0,0,2-2V11.5A2,2,0,0,0,19.5,9.5Zm-7.5,9a2,2,0,1,1,2-2A2,2,0,0,1,12,18.5ZM16.25,9a.5.5,0,0,1-.5.5H8.25a.5.5,0,0,1-.5-.5V6.75a4.25,4.25,0,0,1,8.5,0Z",style:{fill:"#000000"}})))}var Zo=i.forwardRef(Xo);n.p,n(1);function ea(e){var t=e.newsletter,n=e.subscribedNewsletters,r=e.setSubscribedNewsletters,i=n.some((function(e){return e.id===(null===t||void 0===t?void 0:t.id)}));return t.paid?Object($n.jsxs)("section",{className:"gh-portal-list-toggle-wrapper",children:[Object($n.jsxs)("div",{className:"gh-portal-list-detail gh-portal-list-big",children:[Object($n.jsx)("h3",{children:t.name}),Object($n.jsx)("p",{children:t.description})]}),Object($n.jsx)("div",{class:"gh-portal-lock-icon-container",children:Object($n.jsx)(Zo,{className:"gh-portal-lock-icon",alt:"",title:"Unlock access to all newsletters by becoming a paid subscriber."})})]}):Object($n.jsxs)("section",{className:"gh-portal-list-toggle-wrapper",children:[Object($n.jsxs)("div",{className:"gh-portal-list-detail gh-portal-list-big",children:[Object($n.jsx)("h3",{children:t.name}),Object($n.jsx)("p",{children:t.description})]}),Object($n.jsx)("div",{children:Object($n.jsx)(Di,{id:t.id,onToggle:function(e,i){var o=[];o=i?n.filter((function(e){return e.id!==t.id})).concat(t):n.filter((function(e){return e.id!==t.id})),r(o)},checked:i})})]})}function ta(e){var t=e.subscribedNewsletters,n=e.setSubscribedNewsletters,r=Object(i.useContext)(tr).site;return Object(Fr.getSiteNewsletters)({site:r}).map((function(e){return Object($n.jsx)(ea,{newsletter:e,subscribedNewsletters:t,setSubscribedNewsletters:n},null===e||void 0===e?void 0:e.id)}))}function na(e){var t=e.pageData,n=e.onBack,r=Object(i.useContext)(tr),o=r.brandColor,a=r.site,l=r.onAction,c=r.action,u=Object(Fr.getSiteNewsletters)({site:a}).filter((function(e){return e.subscribe_on_signup})),p=!1;"signup:running"===c&&(p=!0);var d="Continue",f=!1;"signup:failed"===c&&(d="Retry",f=!0);var h="signup:running"===c,m=Object(i.useState)(u),g=Object(s.a)(m,2),b=g[0],v=g[1];return Object($n.jsxs)("div",{className:"gh-portal-content with-footer gh-portal-newsletter-selection",children:[Object($n.jsx)("p",{className:"gh-portal-text-center gh-portal-text-large",children:"Choose your newsletters"}),Object($n.jsx)("div",{className:"gh-portal-section",children:Object($n.jsx)("div",{className:"gh-portal-list",children:Object($n.jsx)(ta,{subscribedNewsletters:b,setSubscribedNewsletters:v})})}),Object($n.jsx)("footer",{className:"gh-portal-action-footer",children:Object($n.jsxs)("div",{style:{width:"100%"},children:[Object($n.jsx)("div",{style:{marginBottom:"20px"},children:Object($n.jsx)(Ci,{isRunning:p,retry:f,disabled:h,onClick:function(e){var n=b.map((function(e){return{id:e.id}})),r=t.name,i=t.email,o=t.plan,a=t.offerId;l("signup",{name:r,email:i,plan:o,newsletters:n,offerId:a})},brandColor:o,label:d,style:{width:"100%"}})}),Object($n.jsx)("div",{children:Object($n.jsx)("button",{className:"gh-portal-btn gh-portal-btn-link gh-portal-btn-different-plan",onClick:function(){n()},children:Object($n.jsx)("span",{children:"Choose a different plan"})})})]})})]})}var ra,ia,oa=function(e){var t=e.field,n=e.onChange,r=e.onBlur,i=void 0===r?function(){}:r,o=e.onKeyDown,a=void 0===o?function(){}:o;return t?Object($n.jsx)($n.Fragment,{children:Object($n.jsx)(Qo,{label:t.label,type:t.type,name:t.name,placeholder:t.placeholder,disabled:t.disabled,value:t.value,onKeyDown:a,onChange:function(e){return n(e,t)},onBlur:function(e){return i(e,t)},tabIndex:t.tabindex,errorMessage:t.errorMessage,autoFocus:t.autoFocus},t.name)}):null},aa=function(e){v(n,e);var t=O(n);function n(e){var r;return h(this,n),(r=t.call(this,e)).state={},r}return g(n,[{key:"render",value:function(){var e=this.props,t=e.fields,n=e.onChange,r=e.onBlur,i=e.onKeyDown,o=t.map((function(e){return Object($n.jsx)(oa,{field:e,onChange:n,onBlur:r,onKeyDown:i},e.name)}));return Object($n.jsx)($n.Fragment,{children:o})}}]),n}(i.Component),la=function(e){var t,n=e.field;if(n.required&&!n.value)switch(n.name){case"name":return"Enter your name";case"email":return"Enter your email address";default:return"Please enter ".concat(n.name)}return"email"!==n.type||(t=n.value)&&/^[a-zA-Z0-9.!#$%&'*+/=?^_`{|}~-]+@[a-zA-Z0-9](?:[a-zA-Z0-9-]{0,61}[a-zA-Z0-9])?(?:\.[a-zA-Z0-9](?:[a-zA-Z0-9-]{0,61}[a-zA-Z0-9])?)*$/.test(String(t).toLowerCase())?null:"Invalid email address"},sa=function(e){var t=e.fields,n={};return t.forEach((function(e){var t=e.name,r=la({field:e});n[t]=r})),n},ca=["title","titleId"];function ua(){return ua=Object.assign||function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(e[r]=n[r])}return e},ua.apply(this,arguments)}function pa(e,t){if(null==e)return{};var n,r,i=function(e,t){if(null==e)return{};var n,r,i={},o=Object.keys(e);for(r=0;r<o.length;r++)n=o[r],t.indexOf(n)>=0||(i[n]=e[n]);return i}(e,t);if(Object.getOwnPropertySymbols){var o=Object.getOwnPropertySymbols(e);for(r=0;r<o.length;r++)n=o[r],t.indexOf(n)>=0||Object.prototype.propertyIsEnumerable.call(e,n)&&(i[n]=e[n])}return i}function da(e,t){var n=e.title,r=e.titleId,o=pa(e,ca);return i.createElement("svg",ua({xmlns:"http://www.w3.org/2000/svg",width:24,height:24,viewBox:"0 0 24 24",ref:t,"aria-labelledby":r},o),n?i.createElement("title",{id:r},n):null,ra||(ra=i.createElement("defs",null,i.createElement("style",null,".inviteicon{fill: currentColor;}"))),ia||(ia=i.createElement("path",{className:"inviteicon",d:"M23.991 11.464l-.036-.146-.028-.068-.011-.027-.115-.114-.018-.021-.008-.005h-.001l-3.774-2.596v-7.987c0-.276-.224-.5-.5-.5h-15c-.276 0-.5.224-.5.5v7.987l-3.774 2.595-.003.002-.006.004-.015.016-.118.118-.011.027-.028.068-.036.146-.009.037v10.5c0 1.103.897 2 2 2h20c1.103 0 2-.897 2-2v-10.5l-.009-.036zm-1.383.03l-2.608 1.738v-3.531l2.608 1.793zm-18.608 1.738l-2.608-1.739 2.608-1.792v3.531zm18 9.768h-20c-.551 0-1-.449-1-1v-9.566l5.223 3.482c.085.057.181.084.276.084.162 0 .32-.078.417-.223.153-.23.091-.54-.139-.693l-1.777-1.185v-12.899h14v12.899l-1.777 1.185c-.23.153-.292.463-.139.693.096.145.255.223.416.223.095 0 .191-.027.277-.084l5.223-3.482v9.566c0 .551-.449 1-1 1zM15.812 16.109c-.088-.07-.198-.109-.312-.109h-7c-.114 0-.224.039-.312.109l-5 4c-.215.173-.25.487-.078.703.173.215.487.251.703.078l4.862-3.89h6.649l4.863 3.891c.093.073.203.109.313.109.147 0 .292-.065.391-.188.172-.216.137-.53-.078-.703l-5.001-4zM11.706 12.779c.087.064.191.096.294.096s.207-.032.294-.096c.482-.35 4.706-3.497 4.706-6.101 0-1.868-1.387-2.984-2.728-2.984-.772 0-1.674.379-2.272 1.368-.598-.988-1.5-1.368-2.272-1.368-1.341-.001-2.728 1.116-2.728 2.984 0 2.604 4.224 5.751 4.706 6.101zm-1.978-8.086c.844 0 1.511.681 1.786 1.822.108.45.864.45.973 0 .274-1.141.942-1.822 1.786-1.822.85 0 1.728.742 1.728 1.984 0 1.646-2.658 4.037-4 5.072-1.342-1.035-4-3.426-4-5.072-.001-1.241.877-1.984 1.727-1.984z"})))}var fa=i.forwardRef(da),ha=(n.p,n(1)),ma=function(e){v(n,e);var t=O(n);function n(e){var r;return h(this,n),(r=t.call(this,e)).handleSelectPlan=function(e,t){e&&e.preventDefault(),r.timeoutId=setTimeout((function(){r.setState((function(e){return{plan:t}}))}),5)},r.state={name:"",email:"",plan:"free",showNewsletterSelection:!1},r}return g(n,[{key:"componentDidMount",value:function(){this.context.member&&this.context.onAction("switchPage",{page:"accountHome"}),this.handleSelectedPlan()}},{key:"componentDidUpdate",value:function(){this.handleSelectedPlan()}},{key:"handleSelectedPlan",value:function(){var e=this.context,t=e.site,n=e.pageQuery,r=Object(Fr.getSitePrices)({site:t,pageQuery:n}),i=this.getSelectedPriceId(r,this.state.plan);i!==this.state.plan&&this.setState({plan:i})}},{key:"componentWillUnmount",value:function(){clearTimeout(this.timeoutId)}},{key:"handleSignup",value:function(e){var t=this,n=this.context,r=n.site,i=n.onAction;e.preventDefault(),this.setState((function(e){return{errors:sa({fields:t.getInputFields({state:e})})}}),(function(){var e=t.state,n=e.name,o=e.email,a=e.plan,l=e.errors;l&&Object.values(l).filter((function(e){return!!e})).length>0||(Object(Fr.hasMultipleNewsletters)({site:r})?t.setState({showNewsletterSelection:!0,pageData:{name:n,email:o,plan:a},errors:{}}):(t.setState({errors:{}}),i("signup",{name:n,email:o,plan:a})))}))}},{key:"handleChooseSignup",value:function(e,t){var n=this;e.preventDefault(),this.setState((function(e){return{errors:sa({fields:n.getInputFields({state:e})})}}),(function(){var e=n.context,r=e.onAction,i=e.site,o=n.state,a=o.name,l=o.email,s=o.errors;s&&Object.values(s).filter((function(e){return!!e})).length>0||(Object(Fr.hasMultipleNewsletters)({site:i})?n.setState({showNewsletterSelection:!0,pageData:{name:a,email:l,plan:t},errors:{}}):(r("signup",{name:a,email:l,plan:t}),n.setState({errors:{}})))}))}},{key:"handleInputChange",value:function(e,t){var n=t.name,r=e.target.value;this.setState(Object(Vo.a)({},n,r))}},{key:"onKeyDown",value:function(e){13===e.keyCode&&this.handleSignup(e)}},{key:"getSelectedPriceId",value:function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:[],t=arguments.length>1?arguments[1]:void 0;if(!e||0===e.length)return"free";var n=e.some((function(e){return e.id===t}));return n?t:e[0].id||"free"}},{key:"getInputFields",value:function(e){var t=e.state,n=e.fieldNames,r=this.context.site.portal_name,i=t.errors||{},o=[{type:"email",value:t.email,placeholder:"jamie@example.com",label:"Email",name:"email",required:!0,tabindex:2,errorMessage:i.email||""}];return r&&o.unshift({type:"text",value:t.name,placeholder:"Jamie Larson",label:"Name",name:"name",required:!0,tabindex:1,errorMessage:i.name||""}),o[0].autoFocus=!0,n&&n.length>0?o.filter((function(e){return n.includes(e.name)})):o}},{key:"renderSubmitButton",value:function(){var e=this,t=this.context,n=t.action,r=t.site,i=t.brandColor,o=t.pageQuery;if(Object(Fr.isInviteOnlySite)({site:r,pageQuery:o}))return null;var a="Continue",l="free"===o&&Object(Fr.hasFreeProductPrice)({site:r});if(!Object(Fr.hasOnlyFreePlan)({site:r})&&!l)return null;a="Sign up";var s=!1;"signup:running"===n&&(a="Sending...",s=!0);var c=!1;"signup:failed"===n&&(a="Retry",c=!0);var u="signup:running"===n;return Object($n.jsx)(Ci,{style:{width:"100%"},retry:c,onClick:function(t){return e.handleSignup(t)},disabled:u,brandColor:i,label:a,isRunning:s,tabIndex:"3"})}},{key:"renderProducts",value:function(){var e=this,t=this.context,n=t.site,r=t.pageQuery,i=Object(Fr.getSiteProducts)({site:n,pageQuery:r});return Object($n.jsx)($n.Fragment,{children:Object($n.jsx)(Mo,{handleChooseSignup:function(){return e.handleChooseSignup.apply(e,arguments)},products:i,onPlanSelect:this.handleSelectPlan})})}},{key:"renderFreeTrialMessage",value:function(){var e=this.context.site;return Object(Fr.hasFreeTrialTier)({site:e})?Object($n.jsx)("p",{className:"gh-portal-free-trial-notification",children:"After a free trial ends, you will be charged regular price for the tier you\u2019ve chosen. You can always cancel before then."}):null}},{key:"renderLoginMessage",value:function(){var e=this.context,t=e.brandColor,n=e.onAction;return Object($n.jsxs)("div",{children:[this.renderFreeTrialMessage(),Object($n.jsxs)("div",{className:"gh-portal-signup-message",children:[Object($n.jsx)("div",{children:"Already a member?"}),Object($n.jsx)("button",{className:"gh-portal-btn gh-portal-btn-link",style:{color:t},onClick:function(){return n("switchPage",{page:"signin"})},children:Object($n.jsx)("span",{children:"Sign in"})})]})]})}},{key:"renderForm",value:function(){var e=this,t=this.getInputFields({state:this.state}),n=this.context,r=n.site,i=n.pageQuery;if(this.state.showNewsletterSelection)return Object($n.jsx)(na,{pageData:this.state.pageData,onBack:function(){e.setState({showNewsletterSelection:!1})}});if(Object(Fr.isInviteOnlySite)({site:r,pageQuery:i}))return Object($n.jsx)("section",{children:Object($n.jsxs)("div",{className:"gh-portal-section",children:[Object($n.jsx)("p",{className:"gh-portal-invite-only-notification",children:"This site is invite-only, contact the owner for access."}),this.renderLoginMessage()]})});var o=Object(Fr.getFreeProductBenefits)({site:r}),a=Object(Fr.getFreeTierDescription)({site:r}),l="free"===i&&Object(Fr.hasFreeProductPrice)({site:r}),s=Object(Fr.hasOnlyFreeProduct)({site:r})||l,c=!l&&(o.length||a);return Object($n.jsx)("section",{className:"gh-portal-signup",children:Object($n.jsxs)("div",{className:"gh-portal-section",children:[Object($n.jsx)("div",{className:"gh-portal-logged-out-form-container",children:Object($n.jsx)(aa,{fields:t,onChange:function(t,n){return e.handleInputChange(t,n)},onKeyDown:function(t){return e.onKeyDown(t)}})}),Object($n.jsxs)("div",{children:[this.renderProducts(),s?Object($n.jsx)("div",{className:"gh-portal-btn-container"+(c?" sticky m24":""),children:Object($n.jsxs)("div",{className:"gh-portal-logged-out-form-container",children:[this.renderSubmitButton(),this.renderLoginMessage()]})}):this.renderLoginMessage()]})]})})}},{key:"renderSiteLogo",value:function(){var e=this.context,t=e.site,n=e.pageQuery,r=t.icon;return r?("url(".concat(r,")"),Object($n.jsx)("img",{className:"gh-portal-signup-logo",src:r,alt:t.title})):Object(Fr.isInviteOnlySite)({site:t,pageQuery:n})?Object($n.jsx)(fa,{className:"gh-portal-icon gh-portal-icon-invitation"}):null}},{key:"renderFormHeader",value:function(){var e=this.context.site.title||"";return Object($n.jsxs)("header",{className:"gh-portal-signup-header",children:[this.renderSiteLogo(),Object($n.jsx)("h1",{className:"gh-portal-main-title",children:e})]})}},{key:"getClassNames",value:function(){var e=this.context,t=e.site,n=e.pageQuery,r=Object(Fr.getSitePrices)({site:t,pageQuery:n}),i=this.getInputFields({state:this.state}),o="",a="";return(r.length<=1||Object(Fr.isInviteOnlySite)({site:t}))&&(1===r.length&&"free"===r[0].type||Object(Fr.isInviteOnlySite)({site:t,pageQuery:n})?(o=Object(Fr.freeHasBenefitsOrDescription)({site:t})?"singleplan":"noplan",1===i.length&&(o="single-field"),Object(Fr.isInviteOnlySite)({site:t})&&(a="invite-only",o="invite-only")):o="singleplan"),{sectionClass:o,footerClass:a}}},{key:"render",value:function(){var e=this,t=this.getClassNames().sectionClass;return Object($n.jsxs)($n.Fragment,{children:[Object($n.jsx)("div",{className:"gh-portal-back-sitetitle",children:Object($n.jsx)(Yo,{onBack:function(){e.state.showNewsletterSelection?e.setState({showNewsletterSelection:!1}):e.context.onAction("closePopup")}})}),Object($n.jsx)(zi,{}),Object($n.jsxs)("div",{className:"gh-portal-content signup "+t,children:[this.renderFormHeader(),this.renderForm()]})]})}}]),n}(ha.Component);ma.contextType=tr;var ga,ba,va,ya,xa,wa=ma,ja=["title","titleId"];function Oa(){return Oa=Object.assign||function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(e[r]=n[r])}return e},Oa.apply(this,arguments)}function ka(e,t){if(null==e)return{};var n,r,i=function(e,t){if(null==e)return{};var n,r,i={},o=Object.keys(e);for(r=0;r<o.length;r++)n=o[r],t.indexOf(n)>=0||(i[n]=e[n]);return i}(e,t);if(Object.getOwnPropertySymbols){var o=Object.getOwnPropertySymbols(e);for(r=0;r<o.length;r++)n=o[r],t.indexOf(n)>=0||Object.prototype.propertyIsEnumerable.call(e,n)&&(i[n]=e[n])}return i}function _a(e,t){var n=e.title,r=e.titleId,o=ka(e,ja);return i.createElement("svg",Oa({xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24",ref:t,"aria-labelledby":r},o),n?i.createElement("title",{id:r},n):null,ga||(ga=i.createElement("defs",null,i.createElement("style",null,".a{fill:none;stroke:currentColor;stroke-linecap:round;stroke-linejoin:round;stroke-width:1px;}"))),ba||(ba=i.createElement("rect",{className:"a",x:.75,y:4.5,width:22.5,height:15,rx:1.5,ry:1.5})),va||(va=i.createElement("line",{className:"a",x1:15.687,y1:9.975,x2:19.5,y2:13.5})),ya||(ya=i.createElement("line",{className:"a",x1:8.313,y1:9.975,x2:4.5,y2:13.5})),xa||(xa=i.createElement("path",{className:"a",d:"M22.88,5.014l-9.513,6.56a2.406,2.406,0,0,1-2.734,0L1.12,5.014"})))}var Sa=i.forwardRef(_a),Pa=(n.p,n(1)),Ea=function(e){v(n,e);var t=O(n);function n(){return h(this,n),t.apply(this,arguments)}return g(n,[{key:"renderFormHeader",value:function(){var e="We've sent you a login link!",t="If the email doesn't arrive in 3 minutes, be sure to check your spam folder!";return"signup"===this.context.lastPage&&(e="Now check your email!",t="To complete signup, click the confirmation link in your inbox. If it doesn\u2019t arrive within 3 minutes, check your spam folder!"),Object($n.jsxs)("section",{className:"gh-portal-inbox-notification",children:[Object($n.jsxs)("header",{className:"gh-portal-header",children:[Object($n.jsx)(Sa,{className:"gh-portal-icon gh-portal-icon-envelope"}),Object($n.jsx)("h2",{className:"gh-portal-main-title",children:e})]}),Object($n.jsx)("p",{children:t})]})}},{key:"renderLoginMessage",value:function(){var e=this;return Object($n.jsx)($n.Fragment,{children:Object($n.jsx)("div",{style:{color:"#1d1d1d",fontWeight:"bold",cursor:"pointer"},onClick:function(){return e.context.onAction("switchPage",{page:"signin"})},children:"Back to Log in"})})}},{key:"handleClose",value:function(e){this.context.onAction("closePopup")}},{key:"renderCloseButton",value:function(){var e=this;return Object($n.jsx)(Ci,{style:{width:"100%"},onClick:function(t){return e.handleClose(t)},brandColor:this.context.brandColor,label:"Close"})}},{key:"render",value:function(){return Object($n.jsxs)("div",{className:"gh-portal-content",children:[Object($n.jsx)(zi,{}),this.renderFormHeader(),this.renderCloseButton()]})}}]),n}(Pa.Component);Ea.contextType=tr;var Ca=function(e){var t=e.hide,n=void 0!==t&&t,r=e.onClose;return n?null:Object($n.jsx)(Zr,{className:"closeicon",alt:"Close",onClick:r})},Na=function(e){var t=e.message,n=e.site,r=Object(Fr.getSupportAddress)({site:n}),i="mailto:".concat(r);return t?Object($n.jsx)("p",{children:t}):Object($n.jsxs)("p",{children:[" An unexpected error occured. Please try again or ",Object($n.jsx)("a",{href:i,onClick:function(){i&&window.open(i)},children:"contact support"})," if the error persists."]})},Ta=function(e){v(n,e);var t=O(n);function n(){var e;return h(this,n),(e=t.call(this)).state={className:""},e}return g(n,[{key:"onAnimationEnd",value:function(e){var t=(this.context.popupNotification||{}).type;"popupnotification-slideout"===e.animationName&&("stripe:billing-update"===t&&hi(["stripe"]),this.context.onAction("clearPopupNotification"))}},{key:"closeNotification",value:function(e){this.context.onAction("clearPopupNotification")}},{key:"componentDidUpdate",value:function(){var e=this.context.popupNotification;e.count!==this.state.notificationCount&&(clearTimeout(this.timeoutId),this.handlePopupNotification({popupNotification:e}))}},{key:"handlePopupNotification",value:function(e){var t=this,n=e.popupNotification;if(this.setState({notificationCount:n.count}),n.autoHide){var r=n.duration,i=void 0===r?2600:r;this.timeoutId=setTimeout((function(){t.setState((function(e){return"slideout"!==e.className?{className:"slideout",notificationCount:n.count}:{}}))}),i)}}},{key:"componentDidMount",value:function(){var e=this.context.popupNotification;this.handlePopupNotification({popupNotification:e})}},{key:"componentWillUnmount",value:function(){clearTimeout(this.timeoutId)}},{key:"render",value:function(){var e=this,t=this.context,n=t.popupNotification,r=t.site,i=this.state.className,o=n.type,a=n.status,l=n.closeable,s=n.message,c=a?" ".concat(a):"",u=i?" ".concat(i):"";return Object($n.jsxs)("div",{className:"gh-portal-popupnotification".concat(c).concat(u),onAnimationEnd:function(t){return e.onAnimationEnd(t)},children:["error"===a?Object($n.jsx)(pi,{className:"gh-portal-popupnotification-icon error",alt:""}):Object($n.jsx)(ai,{className:"gh-portal-popupnotification-icon success",alt:""}),Object($n.jsx)(Na,{type:o,status:a,message:s,site:r}),Object($n.jsx)(Ca,{hide:!l,onClose:function(t){return e.closeNotification(t)}})]})}}]),n}(o.a.Component);Ta.contextType=tr;var Ia=n(1),La=function(e){v(n,e);var t=O(n);function n(e,r){var i,o,a;return h(this,n),(a=t.call(this,e,r)).state={name:(null===r||void 0===r||null===(i=r.member)||void 0===i?void 0:i.name)||"",email:(null===r||void 0===r||null===(o=r.member)||void 0===o?void 0:o.email)||"",plan:"free",showNewsletterSelection:!1},a}return g(n,[{key:"getInputFields",value:function(e){var t=e.state,n=e.fieldNames,r=this.context.site.portal_name,i=this.context.member,o=t.errors||{},a=[{type:"email",value:(null===i||void 0===i?void 0:i.email)||t.email,placeholder:"jamie@example.com",label:"Email",name:"email",disabled:!!i,required:!0,tabindex:2,errorMessage:o.email||""}],l=!!r;return!i||null!==i&&void 0!==i&&i.name||(l=!1),l&&a.unshift({type:"text",value:(null===i||void 0===i?void 0:i.name)||t.name,placeholder:"Jamie Larson",label:"Name",name:"name",disabled:!!i,required:!0,tabindex:1,errorMessage:o.name||""}),a[0].autoFocus=!0,n&&n.length>0?a.filter((function(e){return n.includes(e.name)})):a}},{key:"onKeyDown",value:function(e){13===e.keyCode&&this.handleSignup(e)}},{key:"handleSignup",value:function(e){var t=this;e.preventDefault();var n=this.context,r=n.pageData,i=n.site;if(!r)return null;var o=Object(Fr.getProductFromId)({site:i,productId:r.tier.id}),a="month"===r.cadence?o.monthlyPrice:o.yearlyPrice;this.setState((function(e){return{errors:sa({fields:t.getInputFields({state:e})})}}),(function(){var e=t.context.onAction,n=t.state,o=n.name,l=n.email,s=n.errors;if(!(s&&Object.values(s).filter((function(e){return!!e})).length>0)){var c={name:o,email:l,plan:null===a||void 0===a?void 0:a.id,offerId:null===r||void 0===r?void 0:r.id};Object(Fr.hasMultipleNewsletters)({site:i})?t.setState({showNewsletterSelection:!0,pageData:c,errors:{}}):(e("signup",c),t.setState({errors:{}}))}}))}},{key:"handleInputChange",value:function(e,t){var n=t.name,r=e.target.value;this.setState(Object(Vo.a)({},n,r))}},{key:"renderSiteLogo",value:function(){var e=this.context.site,t=e.icon;return t?("url(".concat(t,")"),Object($n.jsx)("img",{className:"gh-portal-signup-logo",src:t,alt:e.title})):null}},{key:"renderFormHeader",value:function(){var e=this.context.site.title||"";return Object($n.jsxs)("header",{className:"gh-portal-signup-header",children:[this.renderSiteLogo(),Object($n.jsx)("h2",{className:"gh-portal-main-title",children:e})]})}},{key:"renderForm",value:function(){var e=this,t=this.getInputFields({state:this.state});return this.state.showNewsletterSelection?Object($n.jsx)(na,{pageData:this.state.pageData,onBack:function(){e.setState({showNewsletterSelection:!1})}}):Object($n.jsx)("section",{children:Object($n.jsx)("div",{className:"gh-portal-section",children:Object($n.jsx)(aa,{fields:t,onChange:function(t,n){return e.handleInputChange(t,n)},onKeyDown:function(t){return e.onKeyDown(t)}})})})}},{key:"renderSubmitButton",value:function(){var e=this,t=this.context,n=t.action,r=t.brandColor,i=this.context.pageData,o="Continue";"trial"===i.type&&(o="Start "+i.amount+"-day free trial");var a=!1;"signup:running"===n&&(o="Sending...",a=!0);var l=!1;"signup:failed"===n&&(o="Retry",l=!0);var s="signup:running"===n;return Object($n.jsx)(Ci,{style:{width:"100%"},retry:l,onClick:function(t){return e.handleSignup(t)},disabled:s,brandColor:r,label:o,isRunning:a,tabindex:"3",classes:"sticky bottom"})}},{key:"renderLoginMessage",value:function(){if(this.context.member)return null;var e=this.context,t=e.brandColor,n=e.onAction;return Object($n.jsxs)("div",{className:"gh-portal-signup-message",children:[Object($n.jsx)("div",{children:"Already a member?"}),Object($n.jsx)("button",{className:"gh-portal-btn gh-portal-btn-link",style:{color:t},onClick:function(){return n("switchPage",{page:"signin"})},children:Object($n.jsx)("span",{children:"Sign in"})})]})}},{key:"renderOfferTag",value:function(){var e=this.context.pageData;return e.amount<=0?Object($n.jsx)($n.Fragment,{}):"fixed"===e.type?Object($n.jsxs)("h5",{className:"gh-portal-discount-label",children:[Object(Fr.getCurrencySymbol)(e.currency),e.amount/100," off"]}):"trial"===e.type?Object($n.jsxs)("h5",{className:"gh-portal-discount-label",children:[e.amount," days free"]}):Object($n.jsxs)("h5",{className:"gh-portal-discount-label",children:[e.amount,"% off"]})}},{key:"renderBenefits",value:function(e){var t=e.product.benefits||[];if(null!==t&&void 0!==t&&t.length){var n=t.map((function(e,t){return Object($n.jsxs)("div",{className:"gh-portal-product-benefit",children:[Object($n.jsx)(mo,{className:"gh-portal-benefit-checkmark"}),Object($n.jsx)("div",{className:"gh-portal-benefit-title",children:e.name})]},"".concat(e.name,"-").concat(t))}));return Object($n.jsx)("div",{className:"gh-portal-product-benefits",children:n})}}},{key:"getOriginalPrice",value:function(e){var t=e.offer,n=e.product,r="month"===t.cadence?n.monthlyPrice:n.yearlyPrice,i=this.renderRoundedPrice(r.amount/100);return"".concat(Object(Fr.getCurrencySymbol)(r.currency)).concat(i,"/").concat(t.cadence)}},{key:"getUpdatedPrice",value:function(e){var t,n=e.offer,r=e.product,i="month"===n.cadence?r.monthlyPrice:r.yearlyPrice,o=i.amount;return"fixed"===n.type&&Object(Fr.isSameCurrency)(n.currency,i.currency)?(t=(o-n.amount)/100)>0?t:0:"percent"===n.type?t=(o-o*n.amount/100)/100:o/100}},{key:"renderRoundedPrice",value:function(e){if(e%1!==0){var t=Math.round(100*e)/100;return Number(t).toFixed(2)}return e}},{key:"getOffAmount",value:function(e){var t=e.offer;return"fixed"===t.type?"".concat(Object(Fr.getCurrencySymbol)(t.currency)).concat(t.amount/100):"percent"===t.type?"".concat(t.amount,"%"):"trial"===t.type?t.amount:""}},{key:"renderOfferMessage",value:function(e){var t=e.offer,n=e.product,r=(e.price,t.duration),i="",o=this.getOriginalPrice({offer:t,product:n}),a="";if("once"===r)i="for first ".concat(t.cadence),a="Renews at ".concat(o,".");else if("forever"===r)i="forever";else if("repeating"===r){var l=t.duration_in_months||"";i=1===l?"for first month":"for first ".concat(l," months"),a="Renews at ".concat(o,".")}return"trial"===r?Object($n.jsxs)("p",{className:"footnote",children:["Try free for ",t.amount," days, then ",o,". ",Object($n.jsx)("span",{class:"gh-portal-cancel",children:"Cancel anytime."})]}):Object($n.jsxs)("p",{className:"footnote",children:[this.getOffAmount({offer:t})," off ",i,". ",a]})}},{key:"renderProductLabel",value:function(e){var t=e.product,n=e.offer,r=this.context.site;return Object(Fr.hasMultipleProductsFeature)({site:r})?Object($n.jsxs)("h4",{className:"gh-portal-plan-name",children:[t.name," - ","month"===n.cadence?"Monthly":"Yearly"]}):Object($n.jsx)("h4",{className:"gh-portal-plan-name",children:"month"===n.cadence?"Monthly":"Yearly"})}},{key:"renderUpdatedTierPrice",value:function(e){var t=e.offer,n=e.currencyClass,r=e.updatedPrice,i=e.price;return"trial"===t.type?Object($n.jsx)("div",{className:"gh-portal-product-card-pricecontainer offer-type-trial",children:Object($n.jsxs)("div",{className:"gh-portal-product-price",children:[Object($n.jsx)("span",{className:"currency-sign "+n,children:Object(Fr.getCurrencySymbol)(i.currency)}),Object($n.jsx)("span",{className:"amount",children:Object(Fr.formatNumber)(this.renderRoundedPrice(r))})]})}):Object($n.jsx)("div",{className:"gh-portal-product-card-pricecontainer",children:Object($n.jsxs)("div",{className:"gh-portal-product-price",children:[Object($n.jsx)("span",{className:"currency-sign "+n,children:Object(Fr.getCurrencySymbol)(i.currency)}),Object($n.jsx)("span",{className:"amount",children:Object(Fr.formatNumber)(this.renderRoundedPrice(r))})]})})}},{key:"renderOldTierPrice",value:function(e){var t=e.offer,n=e.price;return"trial"===t.type?null:Object($n.jsxs)("div",{className:"gh-portal-offer-oldprice",children:[Object(Fr.getCurrencySymbol)(n.currency)," ",Object(Fr.formatNumber)(n.amount/100)]})}},{key:"renderProductCard",value:function(e){var t=e.product,n=e.offer,r=e.currencyClass,i=e.updatedPrice,o=e.price,a=e.benefits;return this.state.showNewsletterSelection?null:Object($n.jsxs)($n.Fragment,{children:[Object($n.jsx)("div",{className:"gh-portal-product-card top",children:Object($n.jsxs)("div",{className:"gh-portal-product-card-header",children:[Object($n.jsxs)("h4",{className:"gh-portal-product-name",children:[t.name," - ","month"===n.cadence?"Monthly":"Yearly"]}),this.renderOldTierPrice({offer:n,price:o}),this.renderUpdatedTierPrice({offer:n,currencyClass:r,updatedPrice:i,price:o}),this.renderOfferMessage({offer:n,product:t,price:o})]})}),Object($n.jsxs)("div",{children:[Object($n.jsx)("div",{className:"gh-portal-product-card bottom",children:Object($n.jsxs)("div",{className:"gh-portal-product-card-detaildata",children:[t.description?Object($n.jsx)("div",{className:"gh-portal-product-description",children:t.description}):"",a.length?this.renderBenefits({product:t}):""]})}),Object($n.jsx)("div",{className:"gh-portal-btn-container sticky m32",children:this.renderSubmitButton()}),this.renderLoginMessage()]})]})}},{key:"render",value:function(){var e=this.context,t=e.pageData,n=e.site;if(!t)return null;var r=Object(Fr.getProductFromId)({site:n,productId:t.tier.id}),i="month"===t.cadence?r.monthlyPrice:r.yearlyPrice,o=this.getUpdatedPrice({offer:t,product:r}),a=r.benefits||[],l=Object(Fr.getCurrencySymbol)(i.currency).length>1?"long":"";return Object($n.jsx)($n.Fragment,{children:Object($n.jsxs)("div",{className:"gh-portal-content gh-portal-offer",children:[Object($n.jsx)(zi,{}),this.renderFormHeader(),Object($n.jsxs)("div",{className:"gh-portal-offer-bar",children:[Object($n.jsxs)("div",{className:"gh-portal-offer-title",children:[t.display_title?Object($n.jsx)("h4",{children:t.display_title}):Object($n.jsx)("h4",{className:"placeholder",children:"Black Friday"}),this.renderOfferTag()]}),t.display_description?Object($n.jsx)("p",{children:t.display_description}):""]}),this.renderForm(),this.renderProductCard({product:r,offer:t,currencyClass:l,updatedPrice:o,price:i,benefits:a})]})})}}]),n}(Ia.Component);La.contextType=tr;var Ma=function(e){v(n,e);var t=O(n);function n(e){var r;return h(this,n),(r=t.call(this,e)).state={email:""},r}return g(n,[{key:"componentDidMount",value:function(){this.context.member&&this.context.onAction("switchPage",{page:"accountHome"})}},{key:"handleSignin",value:function(e){var t=this;e.preventDefault(),this.setState((function(e){return{errors:sa({fields:t.getInputFields({state:e})})}}),(function(){var e=t.state,n=e.email,r=e.errors;r&&Object.values(r).filter((function(e){return!!e})).length>0||t.context.onAction("signin",{email:n})}))}},{key:"handleInputChange",value:function(e,t){var n=t.name;this.setState(Object(Vo.a)({},n,e.target.value))}},{key:"onKeyDown",value:function(e){13===e.keyCode&&this.handleSignin(e)}},{key:"getInputFields",value:function(e){var t=e.state,n=t.errors||{};return[{type:"email",value:t.email,placeholder:"jamie@example.com",label:"Email",name:"email",required:!0,errorMessage:n.email||"",autoFocus:!0}]}},{key:"renderSubmitButton",value:function(){var e=this,t=this.context.action,n=!1,r="signin:running"===t,i=r?"Sending login link...":"Continue",o=!!r;return"signin:failed"===t&&(i="Retry",n=!0),Object($n.jsx)(Ci,{retry:n,style:{width:"100%"},onClick:function(t){return e.handleSignin(t)},disabled:o,brandColor:this.context.brandColor,label:i,isRunning:r})}},{key:"renderSignupMessage",value:function(){var e=this,t=this.context.brandColor;return Object($n.jsxs)("div",{className:"gh-portal-signup-message",children:[Object($n.jsx)("div",{children:"Don't have an account?"}),Object($n.jsx)("button",{className:"gh-portal-btn gh-portal-btn-link",style:{color:t},onClick:function(){return e.context.onAction("switchPage",{page:"signup"})},children:Object($n.jsx)("span",{children:"Sign up"})})]})}},{key:"renderForm",value:function(){var e=this;return Object($n.jsx)("section",{children:Object($n.jsx)("div",{className:"gh-portal-section",children:Object($n.jsx)(aa,{fields:this.getInputFields({state:this.state}),onChange:function(t,n){return e.handleInputChange(t,n)},onKeyDown:function(t,n){return e.onKeyDown(t,n)}})})})}},{key:"renderSiteLogo",value:function(){var e=this.context.site.icon;return e?("url(".concat(e,")"),Object($n.jsx)("img",{className:"gh-portal-signup-logo",src:e,alt:this.context.site.title})):null}},{key:"renderFormHeader",value:function(){return Object($n.jsxs)("header",{className:"gh-portal-signin-header",children:[this.renderSiteLogo(),Object($n.jsx)("h1",{className:"gh-portal-main-title",children:"Sign in"})]})}},{key:"render",value:function(){return Object($n.jsxs)($n.Fragment,{children:[Object($n.jsx)(zi,{}),Object($n.jsxs)("div",{className:"gh-portal-logged-out-form-container",children:[Object($n.jsxs)("div",{className:"gh-portal-content signin",children:[this.renderFormHeader(),this.renderForm()]}),Object($n.jsxs)("footer",{className:"gh-portal-signin-footer",children:[this.renderSubmitButton(),this.renderSignupMessage()]})]})]})}}]),n}(n(1).Component);Ma.contextType=tr;var Fa=function(e){v(n,e);var t=O(n);function n(){return h(this,n),t.apply(this,arguments)}return g(n,[{key:"render",value:function(){return Object($n.jsx)("div",{style:{display:"flex",flexDirection:"column",color:"#313131"},children:Object($n.jsx)("div",{style:{paddingLeft:"16px",paddingRight:"16px",paddingTop:"12px",height:"50px"},children:Object($n.jsx)(Si,{className:"gh-portal-loadingicon dark"})})})}}]),n}(n(1).Component),Da=function(e){v(n,e);var t=O(n);function n(e,r){var i;h(this,n),i=t.call(this,e,r);var o=r.member||{},a=o.name,l=void 0===a?"":a,s=o.email,c=void 0===s?"":s;return i.state={name:l,email:c},i}return g(n,[{key:"componentDidMount",value:function(){this.context.member||this.context.onAction("switchPage",{page:"signin"})}},{key:"handleSignout",value:function(e){e.preventDefault(),this.context.onAction("signout")}},{key:"onBack",value:function(e){this.context.onAction("back")}},{key:"onProfileSave",value:function(e){var t=this;e.preventDefault(),this.setState((function(e){return{errors:sa({fields:t.getInputFields({state:e})})}}),(function(){var e=t.state,n=e.email,r=e.name,i=e.errors;i&&Object.values(i).filter((function(e){return!!e})).length>0||(t.context.onAction("clearPopupNotification"),t.context.onAction("updateProfile",{email:n,name:r}))}))}},{key:"renderSaveButton",value:function(){var e=this,t="updateProfile:running"===this.context.action,n="Save";"updateProfile:failed"===this.context.action&&(n="Retry");var r=!!t;return Object($n.jsx)(Ci,{isRunning:t,onClick:function(t){return e.onProfileSave(t)},disabled:r,brandColor:this.context.brandColor,label:n,style:{width:"100%"}})}},{key:"renderDeleteAccountButton",value:function(){return Object($n.jsx)("div",{style:{cursor:"pointer",color:"red"},role:"button",children:"Delete account"})}},{key:"renderAccountFooter",value:function(){return Object($n.jsx)("footer",{className:"gh-portal-action-footer",children:this.renderSaveButton()})}},{key:"renderHeader",value:function(){var e=this;return Object($n.jsxs)("header",{className:"gh-portal-detail-header",children:[Object($n.jsx)(Fi,{brandColor:this.context.brandColor,hidden:!this.context.lastPage,onClick:function(t){return e.onBack(t)}}),Object($n.jsx)("h3",{className:"gh-portal-main-title",children:"Account settings"})]})}},{key:"renderUserAvatar",value:function(){var e=this.context.member&&this.context.member.avatar_image;return Object($n.jsx)("div",{style:{position:"relative",display:"flex",width:"64px",height:"64px",marginBottom:"6px",borderRadius:"100%",boxShadow:"0 0 0 3px #fff",border:"1px solid gray",overflow:"hidden",justifyContent:"center",alignItems:"center"},children:Object($n.jsx)(er,{gravatar:e,style:{userIcon:{color:"black",width:"56px",height:"56px"}}})})}},{key:"handleInputChange",value:function(e,t){var n=t.name;this.setState(Object(Vo.a)({},n,e.target.value))}},{key:"getInputFields",value:function(e){var t=e.state,n=e.fieldNames,r=t.errors||{},i=[{type:"text",value:t.name,placeholder:"Jamie Larson",label:"Name",name:"name",required:!0,errorMessage:r.name||""},{type:"email",value:t.email,placeholder:"jamie@example.com",label:"Email",name:"email",required:!0,errorMessage:r.email||""}];return n&&n.length>0?i.filter((function(e){return n.includes(e.name)})):i}},{key:"onKeyDown",value:function(e){13===e.keyCode&&this.onProfileSave(e)}},{key:"renderProfileData",value:function(){var e=this;return Object($n.jsx)("div",{className:"gh-portal-section",children:Object($n.jsx)(aa,{fields:this.getInputFields({state:this.state}),onChange:function(t,n){return e.handleInputChange(t,n)},onKeyDown:function(t,n){return e.onKeyDown(t,n)}})})}},{key:"render",value:function(){return this.context.member?Object($n.jsxs)($n.Fragment,{children:[Object($n.jsxs)("div",{className:"gh-portal-content with-footer",children:[Object($n.jsx)(zi,{}),this.renderHeader(),Object($n.jsx)("div",{className:"gh-portal-section",children:this.renderProfileData()})]}),this.renderAccountFooter()]}):null}}]),n}(n(1).Component);Da.contextType=tr;var za,Ra,Ua,Aa=n(16);function Ba(e){return function(e){if(Array.isArray(e))return Object(Aa.a)(e)}(e)||function(e){if("undefined"!==typeof Symbol&&null!=e[Symbol.iterator]||null!=e["@@iterator"])return Array.from(e)}(e)||Object(c.a)(e)||function(){throw new TypeError("Invalid attempt to spread non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}()}var Ha=["title","titleId"];function qa(){return qa=Object.assign||function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(e[r]=n[r])}return e},qa.apply(this,arguments)}function $a(e,t){if(null==e)return{};var n,r,i=function(e,t){if(null==e)return{};var n,r,i={},o=Object.keys(e);for(r=0;r<o.length;r++)n=o[r],t.indexOf(n)>=0||(i[n]=e[n]);return i}(e,t);if(Object.getOwnPropertySymbols){var o=Object.getOwnPropertySymbols(e);for(r=0;r<o.length;r++)n=o[r],t.indexOf(n)>=0||Object.prototype.propertyIsEnumerable.call(e,n)&&(i[n]=e[n])}return i}function Wa(e,t){var n=e.title,r=e.titleId,o=$a(e,Ha);return i.createElement("svg",qa({xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24",ref:t,"aria-labelledby":r},o),za||(za=i.createElement("defs",null,i.createElement("style",null,".a{fill:none;stroke:currentColor;stroke-linecap:round;stroke-linejoin:round;stroke-width:1.5px!important;}\n "))),void 0===n?i.createElement("title",{id:r},"check-circle-1"):n?i.createElement("title",{id:r},n):null,Ra||(Ra=i.createElement("path",{className:"a",d:"M6,13.223,8.45,16.7a1.049,1.049,0,0,0,1.707.051L18,6.828"})),Ua||(Ua=i.createElement("circle",{className:"a",cx:12,cy:11.999,r:11.25})))}var Qa=i.forwardRef(Wa);n.p,n(1);function Va(){var e=Object(i.useContext)(tr),t=e.brandColor,n=e.lastPage,r=e.onAction;return Object($n.jsxs)("header",{className:"gh-portal-detail-header",children:[Object($n.jsx)(Fi,{brandColor:t,hidden:!n,onClick:function(e){r("back")}}),Object($n.jsx)("h3",{className:"gh-portal-main-title",children:"Email preferences"})]})}function Ya(e){var t=e.show,n=e.checked,r=[];return t&&r.push("gh-portal-checkmark-show"),n&&r.push("gh-portal-toggle-checked"),r.push("gh-portal-checkmark-container"),Object($n.jsx)("div",{className:r.join(" "),children:Object($n.jsx)(Qa,{className:"gh-portal-checkmark-icon",alt:""})})}function Ka(e){var t=e.newsletter,n=e.subscribedNewsletters,r=e.setSubscribedNewsletters,o=n.some((function(e){return e.id===(null===t||void 0===t?void 0:t.id)})),a=Object(i.useState)(!1),l=Object(s.a)(a,2),c=l[0],u=l[1],p=Object(i.useState)(null),d=Object(s.a)(p,2),f=d[0],h=d[1];return Object($n.jsxs)("section",{className:"gh-portal-list-toggle-wrapper",children:[Object($n.jsxs)("div",{className:"gh-portal-list-detail",children:[Object($n.jsx)("h3",{children:t.name}),Object($n.jsx)("p",{children:null===t||void 0===t?void 0:t.description})]}),Object($n.jsxs)("div",{style:{display:"flex",alignItems:"center"},children:[Object($n.jsx)(Ya,{show:c,checked:o}),Object($n.jsx)(Di,{id:t.id,onToggle:function(e,i){var o=[];if(i){o=n.filter((function(e){return e.id!==t.id})).concat(t),u(!0),clearTimeout(f);var a=setTimeout((function(){u(!1)}),2e3);h(a)}else{o=n.filter((function(e){return e.id!==t.id})),u(!0),clearTimeout(f);var l=setTimeout((function(){u(!1)}),2e3);h(l)}r(o)},checked:o})]})]})}function Ga(e){var t=e.updateCommentNotifications,n=e.isCommentsEnabled,r=!!e.enableCommentNotifications,o=Object(i.useState)(!1),a=Object(s.a)(o,2),l=a[0],c=a[1],u=Object(i.useState)(null),p=Object(s.a)(u,2),d=p[0],f=p[1];return n?Object($n.jsxs)("section",{className:"gh-portal-list-toggle-wrapper",children:[Object($n.jsxs)("div",{className:"gh-portal-list-detail",children:[Object($n.jsx)("h3",{children:"Comments"}),Object($n.jsx)("p",{children:"Get notified when someone replies to your comment"})]}),Object($n.jsxs)("div",{style:{display:"flex",alignItems:"center"},children:[Object($n.jsx)(Ya,{show:l,checked:r}),Object($n.jsx)(Di,{id:"comments",onToggle:function(e,n){c(!0),clearTimeout(d);var r=setTimeout((function(){c(!1)}),2e3);f(r),t(n)},checked:r})]})]}):null}function Ja(e){var t=e.subscribedNewsletters,n=e.setSubscribedNewsletters,r=Object(i.useContext)(tr).site;return Object(Fr.getSiteNewsletters)({site:r}).map((function(e){return Object($n.jsx)(Ka,{newsletter:e,subscribedNewsletters:t,setSubscribedNewsletters:n},null===e||void 0===e?void 0:e.id)}))}function Xa(e){var t=e.site;return e.isPaid?Object($n.jsxs)("p",{style:{textAlign:"center",marginTop:"12px",marginBottom:"0",color:"var(--grey6)"},children:["Unsubscribing from emails will not cancel your paid subscription to ",null===t||void 0===t?void 0:t.title]}):null}function Za(e){var t=e.notification,n=e.subscribedNewsletters,r=e.updateSubscribedNewsletters,o=e.updateCommentNotifications,a=e.unsubscribeAll,l=e.isPaidMember,s=e.isCommentsEnabled,c=e.enableCommentNotifications,u=Object(i.useContext)(tr),p=u.brandColor,d=u.site,f=!(null!==n&&void 0!==n&&n.length)&&(s&&!c||!s),h=t||function(){return null};return Object($n.jsxs)("div",{className:"gh-portal-content with-footer",children:[Object($n.jsx)(zi,{}),Object($n.jsx)(Va,{}),Object($n.jsx)(h,{}),Object($n.jsx)("div",{className:"gh-portal-section",children:Object($n.jsxs)("div",{className:"gh-portal-list",children:[Object($n.jsx)(Ja,{subscribedNewsletters:n,setSubscribedNewsletters:function(e){var t=e.map((function(e){return{id:e.id}}));r(t)}}),Object($n.jsx)(Ga,{isCommentsEnabled:s,enableCommentNotifications:c,updateCommentNotifications:o})]})}),Object($n.jsx)("footer",{className:"gh-portal-action-footer",children:Object($n.jsxs)("div",{style:{width:"100%"},children:[Object($n.jsx)(Ci,{isRunning:!1,onClick:function(e){a()},disabled:f,brandColor:p,isPrimary:!1,label:"Unsubscribe from all emails",isDestructive:!0,style:{width:"100%"}}),Object($n.jsx)(Xa,{isPaid:l,site:d})]})})]})}n(1);var el=function(e){var t=e.siteUrl,n=void 0===t?window.location.origin:t,r=e.apiUrl,i=e.apiKey;function o(e){var t=e.type,r=e.resource;if("members"===t)return"".concat(n.replace(/\/$/,""),"/").concat("members/api","/").concat(r,"/")}function a(e){var t=e.resource,n=e.params,o=void 0===n?"":n;return r&&i?"".concat(r.replace(/\/$/,""),"/").concat(t,"/?key=").concat(i,"&limit=all").concat(o):""}function l(e){var t=e.url,n=e.method,r=void 0===n?"GET":n,i=e.headers,o=void 0===i?{}:i,a=e.credentials,l=void 0===a?void 0:a,s=e.body;return fetch(t,{method:r,headers:o,credentials:l,body:void 0===s?void 0:s})}var c={};return c.analytics={pushEvent:function(e){return f(S.a.mark((function t(){var n,r,i;return S.a.wrap((function(t){for(;;)switch(t.prev=t.next){case 0:return n=o({type:"members",resource:"events"}),t.next=3,c.member.identity();case 3:return r=t.sent,e.identity=r,i={events:[e]},t.abrupt("return",l({url:n,method:"POST",headers:{"Content-Type":"application/json"},body:JSON.stringify(i)}).then((function(e){return e.ok?e.text():null})));case 7:case"end":return t.stop()}}),t)})))()}},c.site={read:function(){return l({url:o({type:"members",resource:"site"}),method:"GET",headers:{"Content-Type":"application/json"}}).then((function(e){if(e.ok)return e.json();throw new Error("Failed to fetch site data")}))},newsletters:function(){return l({url:a({resource:"newsletters"}),method:"GET",headers:{"Content-Type":"application/json"}}).then((function(e){if(e.ok)return e.json();throw new Error("Failed to fetch site data")}))},tiers:function(){return l({url:a({resource:"tiers",params:"&include=monthly_price,yearly_price,benefits"}),method:"GET",headers:{"Content-Type":"application/json"}}).then((function(e){if(e.ok)return e.json();throw new Error("Failed to fetch site data")}))},settings:function(){return l({url:a({resource:"settings"}),method:"GET",headers:{"Content-Type":"application/json"}}).then((function(e){if(e.ok)return e.json();throw new Error("Failed to fetch site data")}))},offer:function(e){var t=e.offerId;return l({url:a({resource:"offers/".concat(t)}),method:"GET",headers:{"Content-Type":"application/json"}}).then((function(e){if(e.ok)return e.json();throw new Error("Failed to fetch offer data")}))}},c.member={identity:function(){return l({url:o({type:"members",resource:"session"}),credentials:"same-origin"}).then((function(e){return e.ok&&204!==e.status?e.text():null}))},sessionData:function(){return l({url:o({type:"members",resource:"member"}),credentials:"same-origin"}).then((function(e){return e.ok&&204!==e.status?e.json():null}))},update:function(e){var t=e.name,n=e.subscribed,r=e.newsletters,i=e.enableCommentNotifications,a=o({type:"members",resource:"member"}),s={name:t,subscribed:n,newsletters:r};return void 0!==i&&(s.enable_comment_notifications=i),l({url:a,method:"PUT",headers:{"Content-Type":"application/json"},credentials:"same-origin",body:JSON.stringify(s)}).then((function(e){return e.ok?e.json():null}))},sendMagicLink:function(e){var t=e.email,n=e.emailType,r=e.labels,i=e.name,a=e.oldEmail,s=e.newsletters,c=o({type:"members",resource:"send-magic-link"}),u={name:i,email:t,newsletters:s,oldEmail:a,emailType:n,labels:r,requestSrc:"portal"},p=Object(Fr.getUrlHistory)();return p&&(u.urlHistory=p),l({url:c,method:"POST",headers:{"Content-Type":"application/json"},body:JSON.stringify(u)}).then((function(e){if(e.ok)return"Success";throw new Error("Failed to send magic link email")}))},signout:function(){return l({url:o({type:"members",resource:"session"}),method:"DELETE"}).then((function(e){if(e.ok)return window.location.replace(n),"Success";throw new Error("Failed to signout")}))},newsletters:function(e){return f(S.a.mark((function t(){var n,r;return S.a.wrap((function(t){for(;;)switch(t.prev=t.next){case 0:return n=e.uuid,r=o({type:"members",resource:"member/newsletters"}),r+="?uuid=".concat(n),t.abrupt("return",l({url:r,credentials:"same-origin"}).then((function(e){return e.ok&&204!==e.status?e.json():null})));case 4:case"end":return t.stop()}}),t)})))()},updateNewsletters:function(e){return f(S.a.mark((function t(){var n,r,i,a,s;return S.a.wrap((function(t){for(;;)switch(t.prev=t.next){case 0:return n=e.uuid,r=e.newsletters,i=e.enableCommentNotifications,a=o({type:"members",resource:"member/newsletters"}),a+="?uuid=".concat(n),s={newsletters:r},void 0!==i&&(s.enable_comment_notifications=i),t.abrupt("return",l({url:a,method:"PUT",headers:{"Content-Type":"application/json"},body:JSON.stringify(s)}).then((function(e){if(e.ok)return e.json();throw new Error("Failed to update email preferences")})));case 6:case"end":return t.stop()}}),t)})))()},updateEmailAddress:function(e){return f(S.a.mark((function t(){var n,r,i,a;return S.a.wrap((function(t){for(;;)switch(t.prev=t.next){case 0:return n=e.email,t.next=3,c.member.identity();case 3:return r=t.sent,i=o({type:"members",resource:"member/email"}),a={email:n,identity:r},t.abrupt("return",l({url:i,method:"POST",headers:{"Content-Type":"application/json"},body:JSON.stringify(a)}).then((function(e){if(e.ok)return"Success";throw new Error("Failed to send email address verification email")})));case 7:case"end":return t.stop()}}),t)})))()},checkoutPlan:function(){var e=arguments;return f(S.a.mark((function t(){var r,i,a,s,u,p,d,h,m,g,b,v,y,x,w,j,O,_,P,E;return S.a.wrap((function(t){for(;;)switch(t.prev=t.next){case 0:return a=e.length>0&&void 0!==e[0]?e[0]:{},s=a.plan,u=a.tierId,p=a.cadence,d=a.cancelUrl,h=a.successUrl,m=a.email,g=a.name,b=a.offerId,v=a.newsletters,y=a.metadata,x=void 0===y?{}:y,w=new URL(n),t.next=4,c.member.identity();case 4:return j=t.sent,O=o({type:"members",resource:"create-stripe-checkout-session"}),d||((_=window.location.href.startsWith(w.href)?new URL(window.location.href):new URL(n)).searchParams.set("stripe","cancel"),d=_.href),P=Object(k.a)({name:g,newsletters:JSON.stringify(v),requestSrc:"portal",fp_tid:null===(r=window.FPROM||window.$FPROM)||void 0===r||null===(i=r.data)||void 0===i?void 0:i.tid,urlHistory:Object(Fr.getUrlHistory)()},x),E={priceId:b?null:s,offerId:b,identity:j,metadata:P,successUrl:h,cancelUrl:d},m&&(E.customerEmail=m),u&&p&&(delete E.priceId,E.tierId=b?null:u,E.cadence=b?null:p),t.abrupt("return",l({url:O,method:"POST",headers:{"Content-Type":"application/json"},body:JSON.stringify(E)}).then(function(){var e=f(S.a.mark((function e(t){var n,r,i,o;return S.a.wrap((function(e){for(;;)switch(e.prev=e.next){case 0:if(t.ok){e.next=6;break}return e.next=3,t.json();case 3:throw i=e.sent,o=(null===i||void 0===i||null===(n=i.errors)||void 0===n||null===(r=n[0])||void 0===r?void 0:r.message)||"Failed to signup, please try again.",new Error(o);case 6:return e.abrupt("return",t.json());case 7:case"end":return e.stop()}}),e)})));return function(t){return e.apply(this,arguments)}}()).then((function(e){return window.Stripe(e.publicKey).redirectToCheckout({sessionId:e.sessionId})})).then((function(e){if(e.error)throw new Error(e.error.message)})).catch((function(e){throw e})));case 12:case"end":return t.stop()}}),t)})))()},editBilling:function(){var e=arguments;return f(S.a.mark((function t(){var r,i,a,s,u,p,d,f,h;return S.a.wrap((function(t){for(;;)switch(t.prev=t.next){case 0:return r=e.length>0&&void 0!==e[0]?e[0]:{},i=r.successUrl,a=r.cancelUrl,s=r.subscriptionId,u=new URL(n),t.next=4,c.member.identity();case 4:return p=t.sent,d=o({type:"members",resource:"create-stripe-update-session"}),i||((f=new URL(n)).searchParams.set("stripe","billing-update-success"),i=f.href),a||((h=window.location.href.startsWith(u.href)?new URL(window.location.href):new URL(n)).searchParams.set("stripe","billing-update-cancel"),a=h.href),t.abrupt("return",l({url:d,method:"POST",headers:{"Content-Type":"application/json"},body:JSON.stringify({identity:p,subscription_id:s,successUrl:i,cancelUrl:a})}).then((function(e){if(!e.ok)throw new Error("Unable to create stripe checkout session");return e.json()})).then((function(e){return window.Stripe(e.publicKey).redirectToCheckout({sessionId:e.sessionId})})).then((function(e){if(e.error)throw new Error(e.error.message)})).catch((function(e){throw e})));case 9:case"end":return t.stop()}}),t)})))()},updateSubscription:function(e){return f(S.a.mark((function t(){var n,r,i,a,s,u,p,d,f,h;return S.a.wrap((function(t){for(;;)switch(t.prev=t.next){case 0:return n=e.subscriptionId,r=e.tierId,i=e.cadence,a=e.planId,s=e.smartCancel,u=e.cancelAtPeriodEnd,p=e.cancellationReason,t.next=3,c.member.identity();case 3:return d=t.sent,f=o({type:"members",resource:"subscriptions"})+n+"/",h={smart_cancel:s,cancel_at_period_end:u,cancellation_reason:p,identity:d,priceId:a},r&&i&&(delete h.priceId,h.tierId=r,h.cadence=i),t.abrupt("return",l({url:f,method:"PUT",headers:{"Content-Type":"application/json"},body:JSON.stringify(h)}));case 8:case"end":return t.stop()}}),t)})))()}},c.init=f(S.a.mark((function e(){var t,n,r,i,o,a,l,u,p;return S.a.wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return e.next=2,Promise.all([c.member.sessionData()]);case 2:return t=e.sent,n=Object(s.a)(t,1),r=n[0],i={},o=[],a=[],l={},e.prev=9,e.next=12,Promise.all([c.site.settings(),c.site.tiers(),c.site.newsletters()]);case 12:u=e.sent,p=Object(s.a)(u,3),l=p[0].settings,a=p[1].tiers,o=p[2].newsletters,i=Object(k.a)(Object(k.a)({},l),{},{newsletters:o,tiers:Object(Fr.transformApiTiersData)({tiers:a})}),e.next=22;break;case 20:e.prev=20,e.t0=e.catch(9);case 22:return i=Object(Fr.transformApiSiteData)({site:i}),e.abrupt("return",{site:i,member:r});case 24:case"end":return e.stop()}}),e,null,[[9,20]])}))),c};n(1);function tl(){var e=Object(i.useContext)(tr).site,t=e.icon;return t?Object($n.jsx)("img",{className:"gh-portal-unsubscribe-logo",src:t,alt:e.title}):null}function nl(){var e=Object(i.useContext)(tr).site.title||"";return Object($n.jsxs)("header",{className:"gh-portal-header",children:[Object($n.jsx)(tl,{}),Object($n.jsx)("h2",{className:"gh-portal-publication-title",children:e})]})}function rl(e){return il.apply(this,arguments)}function il(){return(il=f(S.a.mark((function e(t){var n,r,i,o;return S.a.wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return n=t.api,r=t.memberUuid,i=t.newsletters,o=t.enableCommentNotifications,e.prev=1,e.next=4,n.member.updateNewsletters({uuid:r,newsletters:i,enableCommentNotifications:o});case 4:return e.abrupt("return",e.sent);case 7:e.prev=7,e.t0=e.catch(1);case 9:case"end":return e.stop()}}),e,null,[[1,7]])})))).apply(this,arguments)}var ol,al={signin:Ma,signup:wa,accountHome:ao,accountPlan:$o,accountProfile:Da,accountEmail:function(){var e=Object(i.useContext)(tr),t=e.member,n=e.onAction,r=e.site,o=Ba((null===t||void 0===t?void 0:t.newsletters)||[]),a=Object(i.useState)(o),l=Object(s.a)(a,2),c=l[0],u=l[1],p=r.comments_enabled,d=t.enable_comment_notifications;return Object(i.useEffect)((function(){t||n("switchPage",{page:"signin"})}),[t,n]),Object(i.useEffect)((function(){u((null===t||void 0===t?void 0:t.newsletters)||[])}),[null===t||void 0===t?void 0:t.newsletters]),Object($n.jsx)(Za,{notification:null,subscribedNewsletters:c,updateSubscribedNewsletters:function(e){u(e),n("updateNewsletterPreference",{newsletters:e})},updateCommentNotifications:function(){var e=f(S.a.mark((function e(t){return S.a.wrap((function(e){for(;;)switch(e.prev=e.next){case 0:n("updateNewsletterPreference",{enableCommentNotifications:t});case 1:case"end":return e.stop()}}),e)})));return function(t){return e.apply(this,arguments)}}(),unsubscribeAll:function(){u([]),n("showPopupNotification",{action:"updated:success",message:"Email preference updated."});var e={newsletters:[]};p&&(e.enableCommentNotifications=!1),n("updateNewsletterPreference",e)},isPaidMember:Object(Fr.isPaidMember)({member:t}),isCommentsEnabled:"off"!==p,enableCommentNotifications:d})},signupNewsletter:na,unsubscribe:function(){var e=Object(i.useContext)(tr),t=e.site,n=e.pageData,r=e.onAction,o=el({siteUrl:t.url}),a=Object(i.useState)(),l=Object(s.a)(a,2),c=l[0],u=l[1],p=Object(Fr.getSiteNewsletters)({site:t}),d=p.filter((function(e){return e.subscribe_on_signup})),h=Object(i.useState)(!1),m=Object(s.a)(h,2),g=m[0],b=m[1],v=Object(i.useState)(d),y=Object(s.a)(v,2),x=y[0],w=y[1],j=Object(i.useState)(!1),O=Object(s.a)(j,2),k=O[0],_=O[1],P=t.comments_enabled,E=(c||{}).enable_comment_notifications,C=void 0!==E&&E;return Object(i.useEffect)((function(){var e=el({siteUrl:t.url});f(S.a.mark((function t(){var r,i,o,a,l;return S.a.wrap((function(t){for(;;)switch(t.prev=t.next){case 0:return t.next=2,e.member.newsletters({uuid:n.uuid});case 2:if(r=t.sent,u(r),i=(null===r||void 0===r?void 0:r.newsletters)||[],w(i),1!==(null===p||void 0===p?void 0:p.length)||P){t.next=13;break}return t.next=9,rl({api:e,memberUuid:n.uuid,newsletters:[]});case 9:o=t.sent,w(o.newsletters),t.next=25;break;case 13:if(!n.newsletterUuid){t.next=20;break}return t.next=16,rl({api:e,memberUuid:n.uuid,newsletters:null===i||void 0===i?void 0:i.filter((function(e){return e.uuid!==n.newsletterUuid}))});case 16:a=t.sent,w(a.newsletters),t.next=25;break;case 20:if(!n.comments||!P){t.next=25;break}return t.next=23,rl({api:e,memberUuid:n.uuid,enableCommentNotifications:!1});case 23:l=t.sent,u(l);case 25:case"end":return t.stop()}}),t)})))()}),[P,n.uuid,n.newsletterUuid,n.comments,t.url,null===p||void 0===p?void 0:p.length]),null===c?Object($n.jsxs)("div",{className:"gh-portal-content gh-portal-unsubscribe with-footer",children:[Object($n.jsx)(zi,{}),Object($n.jsx)(nl,{}),Object($n.jsx)("h1",{className:"gh-portal-main-title",children:"Unsubscribe failed"}),Object($n.jsx)("div",{children:Object($n.jsx)("p",{className:"gh-portal-text-center",children:"Email address not found."})})]}):1!==(null===p||void 0===p?void 0:p.length)||P||k?Object($n.jsx)(Za,{notification:function(){if(n.comments&&P){var e=g?"gh-portal-hide":"";return Object($n.jsx)($n.Fragment,{children:Object($n.jsxs)("p",{className:"gh-portal-text-center gh-portal-header-message ".concat(e),children:[Object($n.jsx)("strong",{children:null===c||void 0===c?void 0:c.email})," will no longer receive emails when someone replies to your comments."]})})}var t=null===p||void 0===p?void 0:p.find((function(e){return e.uuid===n.newsletterUuid})),r=g?"gh-portal-hide":"";return Object($n.jsx)($n.Fragment,{children:Object($n.jsxs)("p",{className:"gh-portal-text-center gh-portal-header-message ".concat(r),children:[Object($n.jsx)("strong",{children:null===c||void 0===c?void 0:c.email})," will no longer receive ",Object($n.jsx)("strong",{children:null===t||void 0===t?void 0:t.name})," newsletter."]})})},subscribedNewsletters:x,updateSubscribedNewsletters:function(){var e=f(S.a.mark((function e(t){return S.a.wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return w(t),b(!0),e.next=4,o.member.updateNewsletters({uuid:n.uuid,newsletters:t});case 4:case"end":return e.stop()}}),e)})));return function(t){return e.apply(this,arguments)}}(),updateCommentNotifications:function(){var e=f(S.a.mark((function e(t){var r;return S.a.wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return e.next=2,o.member.updateNewsletters({uuid:n.uuid,enableCommentNotifications:t});case 2:r=e.sent,u(r);case 4:case"end":return e.stop()}}),e)})));return function(t){return e.apply(this,arguments)}}(),unsubscribeAll:f(S.a.mark((function e(){var t;return S.a.wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return b(!0),w([]),r("showPopupNotification",{action:"updated:success",message:"Email preference updated."}),e.next=5,o.member.updateNewsletters({uuid:n.uuid,newsletters:[],enableCommentNotifications:!1});case 5:t=e.sent,u(t);case 7:case"end":return e.stop()}}),e)}))),isPaidMember:"free"!==(null===c||void 0===c?void 0:c.status),isCommentsEnabled:"off"!==P,enableCommentNotifications:C}):Object($n.jsxs)("div",{className:"gh-portal-content gh-portal-unsubscribe with-footer",children:[Object($n.jsx)(zi,{}),Object($n.jsx)(nl,{}),Object($n.jsx)("h1",{className:"gh-portal-main-title",children:"Successfully unsubscribed"}),Object($n.jsxs)("div",{children:[Object($n.jsxs)("p",{className:"gh-portal-text-center",children:[Object($n.jsx)("strong",{children:null===c||void 0===c?void 0:c.email})," will no longer receive this newsletter."]}),Object($n.jsxs)("p",{className:"gh-portal-text-center",children:["Didn't mean to do this? Manage your preferences",Object($n.jsx)("button",{className:"gh-portal-btn-link gh-portal-btn-branded gh-portal-btn-inline",onClick:function(){_(!0)},children:"here"}),"."]})]})]})},magiclink:Ea,loading:Fa,offer:La},ll=function(e){var t=e.page;return Object.keys(al).includes(t)?t:"signup"},sl=al,cl=["title","titleId"];function ul(){return ul=Object.assign||function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(e[r]=n[r])}return e},ul.apply(this,arguments)}function pl(e,t){if(null==e)return{};var n,r,i=function(e,t){if(null==e)return{};var n,r,i={},o=Object.keys(e);for(r=0;r<o.length;r++)n=o[r],t.indexOf(n)>=0||(i[n]=e[n]);return i}(e,t);if(Object.getOwnPropertySymbols){var o=Object.getOwnPropertySymbols(e);for(r=0;r<o.length;r++)n=o[r],t.indexOf(n)>=0||Object.prototype.propertyIsEnumerable.call(e,n)&&(i[n]=e[n])}return i}function dl(e,t){var n=e.title,r=e.titleId,o=pl(e,cl);return i.createElement("svg",ul({width:24,height:24,viewBox:"0 0 24 24",fill:"none",xmlns:"http://www.w3.org/2000/svg",ref:t,"aria-labelledby":r},o),n?i.createElement("title",{id:r},n):null,ol||(ol=i.createElement("path",{fillRule:"evenodd",clipRule:"evenodd",d:"M24 12C24 18.6274 18.6274 24 12 24C5.37258 24 0 18.6274 0 12C0 5.37258 5.37258 0 12 0C18.6274 0 24 5.37258 24 12ZM11.8326 2.33879C6.37785 2.95189 3.95901 5.20797 3.41126 9.74699C3.34896 10.2632 3.22642 10.7805 3.10443 11.2954C2.93277 12.02 2.76221 12.74 2.76221 13.4458C2.76221 17.9885 6.5856 21.556 11.1283 21.556C12.8959 21.556 14.4433 20.8144 15.8756 20.048C19.0536 18.3478 22.0328 16.2597 22.0328 12.5411C22.0328 9.91512 20.1051 7.56932 18.466 5.5747C18.3834 5.47416 18.3015 5.37451 18.2206 5.27577C17.3866 4.25742 14.4333 2.04643 11.8326 2.33879Z",fill:"#15171A"})))}var fl=i.forwardRef(dl),hl=(n.p,function(e){v(n,e);var t=O(n);function n(){return h(this,n),t.apply(this,arguments)}return g(n,[{key:"render",value:function(){return Object($n.jsxs)("a",{href:"https://ghost.org",target:"_blank",rel:"noopener noreferrer",onClick:function(){window.open("https://ghost.org","_blank")},children:[Object($n.jsx)(fl,{}),"Powered by Ghost"]})}}]),n}(o.a.Component)),ml=n(1),gl=function(e){e.member;return{modalContainer:{zIndex:"3999999",position:"fixed",left:"0",top:"0",width:"100%",height:"100%",overflow:"hidden"},frame:{common:{margin:"auto",position:"relative",padding:"0",outline:"0",width:"100%",opacity:"1",overflow:"hidden",height:"100%"}},page:{links:{width:"600px"}}}};function bl(e){var t=e.message;return Object(Fr.isCookiesDisabled)()?Object($n.jsx)("div",{className:"gh-portal-cookiebanner",children:t}):null}var vl=function(e){v(n,e);var t=O(n);function n(){return h(this,n),t.apply(this,arguments)}return g(n,[{key:"componentDidMount",value:function(){var e=this;this.node&&!Ur(["preview"])&&(this.node.focus(),this.keyUphandler=function(t){var n=t.target&&t.target.tagName;"Escape"===t.key&&"INPUT"!==n&&e.context.onAction("closePopup")},this.node.ownerDocument.removeEventListener("keyup",this.keyUphandler),this.node.ownerDocument.addEventListener("keyup",this.keyUphandler)),this.sendContainerHeightChangeEvent()}},{key:"sendContainerHeightChangeEvent",value:function(){var e,t;this.node&&Ur(["preview"])&&((null===(e=this.node)||void 0===e?void 0:e.clientHeight)!==this.lastContainerHeight&&(this.lastContainerHeight=null===(t=this.node)||void 0===t?void 0:t.clientHeight,window.document.body.style.overflow="hidden",window.document.body.style["scrollbar-width"]="none",window.parent.postMessage({type:"portal-preview-updated",payload:{height:this.lastContainerHeight}},"*")))}},{key:"componentDidUpdate",value:function(){this.sendContainerHeightChangeEvent()}},{key:"componentWillUnmount",value:function(){this.node&&this.node.ownerDocument.removeEventListener("keyup",this.keyUphandler)}},{key:"handlePopupClose",value:function(e){Ur(["preview"])||(e.preventDefault(),e.target===e.currentTarget&&this.context.onAction("closePopup"))}},{key:"renderActivePage",value:function(){var e=this.context.page;ll({page:e});var t=sl[e];return Object($n.jsx)(t,{})}},{key:"renderPopupNotification",value:function(){var e=this.context.popupNotification;return e&&e.type?Object($n.jsx)(Ta,{}):null}},{key:"render",value:function(){var e=this,t=this.context,n=t.page,r=t.pageQuery,i=t.site,o=t.customSiteUrl,a=Object(Fr.getSiteProducts)({site:i}).length;ll({page:n});var l=gl({page:n}),s=Object(k.a)({},l.page[n]),c="regular",u="",p=n;switch(n){case"signup":u="Cookies must be enabled in your browser to sign up.";break;case"signin":u="Cookies must be enabled in your browser to sign in.";break;case"accountHome":p="account-home";break;case"accountProfile":p="account-profile";break;case"accountPlan":p="account-plan";break;default:u="Cookies must be enabled in your browser.",p=n}a>1&&!Object(Fr.isInviteOnlySite)({site:i,pageQuery:r})&&"signup"===n&&(p+=" full-size",c="full");var d=Object(Fr.hasFreeProductPrice)({site:i});(d&&a>2||!d&&a>1)&&"accountPlan"===n&&(p+=" full-size",c="full");var f="gh-portal-popup-container";Ur(["preview"])&&(p+=" preview"),Ur(["preview"],{customSiteUrl:o})&&!i.disableBackground&&(f+=" preview"),Ur(["dev"])&&(f+=" dev");var h="".concat(f," ").concat(""," ").concat(p);return Object($n.jsxs)($n.Fragment,{children:[Object($n.jsx)("div",{className:"gh-portal-popup-wrapper "+p,onClick:function(t){return e.handlePopupClose(t)},children:Object($n.jsxs)("div",{className:h,style:s,ref:function(t){return e.node=t},tabIndex:-1,children:[Object($n.jsx)(bl,{message:u}),this.renderPopupNotification(),this.renderActivePage(),"full"===c?Object($n.jsx)("div",{className:"gh-portal-powered inside "+(Ur(["preview"])?"hidden ":"")+p,children:Object($n.jsx)(hl,{})}):""]})}),Object($n.jsx)("div",{className:"gh-portal-powered outside "+(Ur(["preview"])?"hidden ":"")+p,children:Object($n.jsx)(hl,{})})]})}}]),n}(ml.Component);vl.contextType=tr;var yl,xl=function(e){v(n,e);var t=O(n);function n(e){var r;return h(this,n),(r=t.call(this,e)).state={height:null},r}return g(n,[{key:"renderCurrentPage",value:function(e){var t=sl[e];return Object($n.jsx)(t,{})}},{key:"onHeightChange",value:function(e){this.setState({height:e})}},{key:"handlePopupClose",value:function(e){e.preventDefault(),e.target===e.currentTarget&&this.context.onAction("closePopup")}},{key:"renderFrameStyles",value:function(){var e=function(e){var t=e.site,n=Mr+'\n.gh-portal-main-title {\n text-align: center;\n color: var(--grey0);\n line-height: 1.1em;\n}\n\n.gh-portal-text-disabled {\n color: var(--grey3);\n font-weight: normal;\n opacity: 0.35;\n}\n\n.gh-portal-text-center {\n text-align: center;\n}\n\n.gh-portal-input-label {\n color: var(--grey1);\n font-size: 1.3rem;\n font-weight: 600;\n margin-bottom: 2px;\n letter-spacing: 0px;\n}\n\n.gh-portal-setting-data {\n color: var(--grey6);\n font-size: 1.3rem;\n line-height: 1.15em;\n}\n\n.gh-portal-error {\n color: var(--red);\n font-size: 1.4rem;\n line-height: 1.6em;\n margin: 12px 0;\n}\n\n/* Buttons\n/* ----------------------------------------------------- */\n.gh-portal-btn {\n position: relative;\n display: flex;\n align-items: center;\n justify-content: center;\n font-size: 1.5rem;\n font-weight: 500;\n line-height: 1em;\n letter-spacing: 0.2px;\n text-align: center;\n white-space: nowrap;\n text-decoration: none;\n color: var(--grey0);\n background: var(--white);\n border: 1px solid var(--grey12);\n min-width: 80px;\n height: 44px;\n padding: 0 1.8rem;\n border-radius: 6px;\n cursor: pointer;\n transition: all .25s ease;\n box-shadow: none;\n user-select: none;\n outline: none;\n}\n\n.gh-portal-btn:hover {\n border-color: var(--grey10);\n}\n\n.gh-portal-btn:disabled {\n opacity: 0.5 !important;\n cursor: auto;\n}\n\n.gh-portal-btn-container.sticky {\n transition: none;\n position: sticky;\n bottom: 0;\n margin: 0 0 -32px;\n padding: 32px 0 32px;\n background: linear-gradient(0deg, rgba(255,255,255,1) 75%, rgba(255,255,255,0) 100%);\n}\n\n.gh-portal-btn-container.sticky.m28 {\n margin: 0 0 -28px;\n padding: 28px 0 28px;\n}\n\n.gh-portal-btn-container.sticky.m24 {\n margin: 0 0 -24px;\n padding: 24px 0 24px;\n}\n\n.gh-portal-btn-container .gh-portal-btn {\n margin: 0;\n}\n\n.gh-portal-btn-icon svg {\n width: 16px;\n height: 16px;\n margin-right: 4px;\n stroke: currentColor;\n}\n\n.gh-portal-btn-icon svg path {\n stroke: currentColor;\n}\n\n.gh-portal-btn-link {\n line-height: 1;\n background: none;\n padding: 0;\n height: unset;\n min-width: unset;\n box-shadow: none;\n border: none;\n}\n\n.gh-portal-btn-link:hover {\n box-shadow: none;\n opacity: 0.85;\n}\n\n.gh-portal-btn-branded {\n color: var(--brandcolor);\n}\n\n.gh-portal-btn-list {\n font-size: 1.5rem;\n color: var(--brandcolor);\n height: 38px;\n width: unset;\n min-width: unset;\n padding: 0 4px;\n margin: 0 -4px;\n box-shadow: none;\n border: none;\n}\n\n.gh-portal-btn-list:hover {\n box-shadow: none;\n opacity: 0.75;\n}\n\n.gh-portal-btn-logout {\n position: absolute;\n top: 22px;\n left: 24px;\n background: none;\n border: none;\n height: unset;\n color: var(--grey3);\n padding: 0;\n margin: 0;\n z-index: 999;\n box-shadow: none;\n}\n\n.gh-portal-btn-logout .label {\n opacity: 0;\n transform: translateX(-6px);\n transition: all 0.2s ease-in-out;\n}\n\n.gh-portal-btn-logout:hover {\n padding: 0;\n margin: 0;\n background: none;\n border: none;\n height: unset;\n box-shadow: none;\n}\n\n.gh-portal-btn-logout:hover .label {\n opacity: 1.0;\n transform: translateX(-4px);\n}\n\n.gh-portal-btn-site-title-back {\n transition: transform 0.25s ease-in-out;\n z-index: 10000;\n}\n\n.gh-portal-btn-site-title-back span {\n margin-right: 4px;\n transition: transform 0.4s cubic-bezier(0.1, 0.7, 0.1, 1);\n}\n\n\n.gh-portal-btn-site-title-back:hover span {\n transform: translateX(-3px);\n}\n\n@media (max-width: 960px) {\n .gh-portal-btn-site-title-back {\n display: none;\n }\n}\n\n.gh-portal-logouticon {\n color: var(--grey9);\n cursor: pointer;\n width: 23px;\n height: 23px;\n padding: 6px;\n transform: translateX(0);\n transition: all 0.2s ease-in-out;\n}\n\n.gh-portal-logouticon path {\n stroke: var(--grey9);\n transition: all 0.2s ease-in-out;\n}\n\n.gh-portal-btn-logout:hover .gh-portal-logouticon {\n transform: translateX(-2px);\n}\n\n.gh-portal-btn-logout:hover .gh-portal-logouticon path {\n stroke: var(--grey3);\n}\n\n/* Global layout styles\n/* ----------------------------------------------------- */\n.gh-portal-popup-background {\n position: absolute;\n display: block;\n top: 0;\n right: 0;\n bottom: 0;\n left: 0;\n animation: fadein 0.2s;\n background: linear-gradient(315deg , rgba(0,0,0,0.2) 0%, rgba(0,0,0,0.1) 100%);\n backdrop-filter: blur(2px);\n -webkit-backdrop-filter: blur(2px);\n -webkit-transform: translate3d(0, 0, 0);\n -moz-transform: translate3d(0, 0, 0);\n -ms-transform: translate3d(0, 0, 0);\n transform: translate3d(0, 0, 0);\n}\n\n.gh-portal-popup-background.preview {\n background: linear-gradient(45deg, rgba(255,255,255,1) 0%, rgba(249,249,250,1) 100%);\n animation: none;\n pointer-events: none;\n}\n\n@keyframes fadein {\n 0% { opacity: 0; }\n 100%{ opacity: 1.0; }\n}\n\n.gh-portal-popup-wrapper {\n position: relative;\n padding: 5vmin 0 0;\n height: 100%;\n max-height: 100vh;\n overflow: scroll;\n}\n\n/* Hiding scrollbars */\n.gh-portal-popup-wrapper {\n padding-right: 30px !important;\n margin-right: -30px !important;\n -ms-overflow-style: none;\n scrollbar-width: none;\n}\n\n.gh-portal-popup-wrapper::-webkit-scrollbar {\n display: none;\n}\n\n.gh-portal-popup-wrapper.full-size {\n height: 100vh;\n padding: 0;\n}\n\n.gh-portal-popup-container {\n outline: none;\n position: relative;\n display: flex;\n box-sizing: border-box;\n flex-direction: column;\n justify-content: flex-start;\n font-size: 1.5rem;\n text-align: left;\n letter-spacing: 0;\n text-rendering: optimizeLegibility;\n background: var(--white);\n width: 500px;\n margin: 0 auto 40px;\n padding: 32px;\n transform: translateY(0px);\n border-radius: 10px;\n box-shadow: 0 3.8px 2.2px rgba(0, 0, 0, 0.028), 0 9.2px 5.3px rgba(0, 0, 0, 0.04), 0 17.3px 10px rgba(0, 0, 0, 0.05), 0 30.8px 17.9px rgba(0, 0, 0, 0.06), 0 57.7px 33.4px rgba(0, 0, 0, 0.072), 0 138px 80px rgba(0, 0, 0, 0.1);\n animation: popup 0.25s ease-in-out;\n z-index: 9999;\n}\n\n.gh-portal-popup-container.full-size {\n width: 100vw;\n min-height: 100vh;\n justify-content: flex-start;\n animation: popup-full-size 0.25s ease-in-out;\n margin: 0;\n border-radius: 0;\n transform: translateY(0px);\n transform-origin: top;\n padding: 2vmin 6vmin;\n padding-bottom: 4vw;\n}\n\n.gh-portal-popup-container.full-size.account-plan {\n justify-content: flex-start;\n padding-top: 4vw;\n}\n\n.gh-portal-popup-container.preview {\n animation: none !important;\n}\n\n@keyframes popup {\n 0% {\n transform: translateY(-30px);\n opacity: 0;\n }\n 1% {\n transform: translateY(30px);\n opacity: 0;\n }\n 100%{\n transform: translateY(0);\n opacity: 1.0;\n }\n}\n\n@keyframes popup-full-size {\n 0% {\n transform: translateY(0px);\n opacity: 0;\n }\n 1% {\n transform: translateY(30px);\n opacity: 0;\n }\n 100%{\n transform: translateY(0);\n opacity: 1.0;\n }\n}\n\n.gh-portal-powered {\n position: absolute;\n bottom: 24px;\n left: 24px;\n z-index: 9999;\n}\n\n.gh-portal-powered a {\n border: none;\n display: flex;\n align-items: center;\n line-height: 0;\n border-radius: 4px;\n background: #ffffff;\n padding: 6px 8px 6px 7px;\n color: #303336;\n font-size: 1.25rem;\n letter-spacing: -0.2px;\n font-weight: 500;\n text-decoration: none;\n transition: color 0.5s ease-in-out;\n width: 146px;\n height: 28px;\n line-height: 28px;\n}\n\n.gh-portal-powered a:hover {\n color: #15171A;\n}\n\n@keyframes powered-fade-in {\n 0% {\n transform: scale(0.98);\n opacity: 0;\n }\n 75% {\n opacity: 1.0;\n }\n 100%{\n transform: scale(1);\n }\n}\n\n.gh-portal-powered a svg {\n height: 16px;\n width: 16px;\n margin: 0 6px 0 0;\n}\n\n.gh-portal-powered.outside.full-size {\n display: none;\n}\n\n/* Sets the main content area of the popup scrollable.\n/* 12vw is the sum horizontal padding of the popup container\n*/\n.gh-portal-content {\n position: relative;\n}\n\n/* Hide scrollbar for Chrome, Safari and Opera */\n.gh-portal-content::-webkit-scrollbar {\n display: none;\n}\n\n/* Hide scrollbar for IE, Edge and Firefox */\n.gh-portal-content {\n -ms-overflow-style: none; /* IE and Edge */\n scrollbar-width: none; /* Firefox */\n}\n\n.gh-portal-closeicon-container {\n position: fixed;\n top: 24px;\n right: 24px;\n z-index: 10000;\n}\n\n.gh-portal-closeicon {\n color: var(--grey10);\n cursor: pointer;\n width: 20px;\n height: 20px;\n padding: 12px;\n transition: all 0.2s ease-in-out;\n}\n\n.gh-portal-closeicon:hover {\n color: var(--grey5);\n}\n\n.gh-portal-popup-wrapper.full-size .gh-portal-closeicon-container,\n.gh-portal-popup-container.full-size .gh-portal-closeicon-container {\n top: 20px;\n right: 20px;\n}\n\n.gh-portal-popup-wrapper.full-size .gh-portal-closeicon,\n.gh-portal-popup-container.full-size .gh-portal-closeicon {\n color: var(--grey6);\n width: 24px;\n height: 24px;\n}\n\n.gh-portal-logout-container {\n position: absolute;\n top: 8px;\n left: 8px;\n}\n\n.gh-portal-header {\n display: flex;\n flex-direction: column;\n align-items: center;\n padding-bottom: 24px;\n}\n\n.gh-portal-section {\n margin-bottom: 40px;\n}\n\n.gh-portal-section.form {\n margin-bottom: 20px;\n}\n\n.gh-portal-detail-header {\n position: relative;\n display: flex;\n align-items: center;\n justify-content: center;\n margin: -2px 0 40px;\n}\n\n.gh-portal-detail-footer .gh-portal-btn {\n min-width: 90px;\n}\n\n.gh-portal-action-footer {\n display: flex;\n align-items: center;\n justify-content: space-between;\n}\n\n.gh-portal-list-header {\n font-size: 1.25rem;\n font-weight: 500;\n color: var(--grey3);\n text-transform: uppercase;\n letter-spacing: 0.2px;\n line-height: 1.7em;\n margin-bottom: 4px;\n}\n\n.gh-portal-list + .gh-portal-list-header {\n margin-top: 28px;\n}\n\n.gh-portal-list + .gh-portal-action-footer {\n margin-top: 40px;\n}\n\n.gh-portal-list {\n background: var(--white);\n padding: 20px;\n border-radius: 8px;\n border: 1px solid var(--grey12);\n}\n\n.gh-portal-newsletter-selection {\n max-width: 460px;\n margin: 0 auto;\n}\n\n.gh-portal-newsletter-selection .gh-portal-list {\n margin-bottom: 40px;\n}\n\n.gh-portal-lock-icon-container {\n display: flex;\n justify-content: center;\n flex: 44px 0 0;\n padding-top: 6px;\n}\n\n.gh-portal-lock-icon {\n width: 14px;\n height: 14px;\n overflow: visible;\n}\n\n.gh-portal-lock-icon path {\n color: var(--grey2);\n}\n\n.gh-portal-text-large {\n font-size: 1.8rem;\n font-weight: 600;\n}\n\n.gh-portal-list section {\n display: flex;\n align-items: center;\n margin: 0 -20px 20px;\n padding: 0 20px 20px;\n border-bottom: 1px solid var(--grey12);\n}\n\n.gh-portal-list section:last-of-type {\n margin-bottom: 0;\n padding-bottom: 0;\n border: none;\n}\n\n.gh-portal-list-detail {\n flex-grow: 1;\n}\n\n.gh-portal-list-detail h3 {\n font-size: 1.5rem;\n font-weight: 600;\n}\n\n.gh-portal-list-detail.gh-portal-list-big h3 {\n font-size: 1.6rem;\n font-weight: 600;\n}\n\n.gh-portal-list-detail p {\n font-size: 1.45rem;\n letter-spacing: 0.3px;\n line-height: 1.3em;\n padding: 0;\n margin: 5px 8px 0 0;\n color: var(--grey6);\n word-break: break-word;\n}\n\n.gh-portal-list-detail.gh-portal-list-big p {\n font-size: 1.5rem;\n}\n\n.gh-portal-list-toggle-wrapper {\n align-items: flex-start !important;\n justify-content: space-between;\n}\n\n.gh-portal-list-toggle-wrapper .gh-portal-list-detail {\n padding: 4px 24px 4px 0px;\n}\n\n.gh-portal-list-detail .old-price {\n text-decoration: line-through;\n}\n\n.gh-portal-right-arrow {\n line-height: 1;\n color: var(--grey8);\n}\n\n.gh-portal-right-arrow svg {\n width: 17px;\n height: 17px;\n margin-top: 1px;\n margin-right: -6px;\n}\n\n.gh-portal-expire-warning {\n text-align: center;\n color: var(--red);\n font-weight: 500;\n font-size: 1.4rem;\n margin: 12px 0;\n}\n\n.gh-portal-cookiebanner {\n background: var(--red);\n color: var(--white);\n text-align: center;\n font-size: 1.4rem;\n letter-spacing: 0.2px;\n line-height: 1.4em;\n padding: 8px;\n}\n\n.gh-portal-publication-title {\n text-align: center;\n font-size: 1.6rem;\n letter-spacing: -.1px;\n font-weight: 700;\n text-transform: uppercase;\n color: #15212a;\n margin-top: 6px;\n}\n\n/* Icons\n/* ----------------------------------------------------- */\n.gh-portal-icon {\n color: var(--brandcolor);\n}\n\n/* Spacing modifiers\n/* ----------------------------------------------------- */\n.gh-portal-strong { font-weight: 600; }\n\n.mt1 { margin-top: 4px; }\n.mt2 { margin-top: 8px; }\n.mt3 { margin-top: 12px; }\n.mt4 { margin-top: 16px; }\n.mt5 { margin-top: 20px; }\n.mt6 { margin-top: 24px; }\n.mt7 { margin-top: 28px; }\n.mt8 { margin-top: 32px; }\n.mt9 { margin-top: 36px; }\n.mt10 { margin-top: 40px; }\n\n.mr1 { margin-right: 4px; }\n.mr2 { margin-right: 8px; }\n.mr3 { margin-right: 12px; }\n.mr4 { margin-right: 16px; }\n.mr5 { margin-right: 20px; }\n.mr6 { margin-right: 24px; }\n.mr7 { margin-right: 28px; }\n.mr8 { margin-right: 32px; }\n.mr9 { margin-right: 36px; }\n.mr10 { margin-right: 40px; }\n\n.mb1 { margin-bottom: 4px; }\n.mb2 { margin-bottom: 8px; }\n.mb3 { margin-bottom: 12px; }\n.mb4 { margin-bottom: 16px; }\n.mb5 { margin-bottom: 20px; }\n.mb6 { margin-bottom: 24px; }\n.mb7 { margin-bottom: 28px; }\n.mb8 { margin-bottom: 32px; }\n.mb9 { margin-bottom: 36px; }\n.mb10 { margin-bottom: 40px; }\n\n.ml1 { margin-left: 4px; }\n.ml2 { margin-left: 8px; }\n.ml3 { margin-left: 12px; }\n.ml4 { margin-left: 16px; }\n.ml5 { margin-left: 20px; }\n.ml6 { margin-left: 24px; }\n.ml7 { margin-left: 28px; }\n.ml8 { margin-left: 32px; }\n.ml9 { margin-left: 36px; }\n.ml10 { margin-left: 40px; }\n\n.pt1 { padding-top: 4px; }\n.pt2 { padding-top: 8px; }\n.pt3 { padding-top: 12px; }\n.pt4 { padding-top: 16px; }\n.pt5 { padding-top: 20px; }\n.pt6 { padding-top: 24px; }\n.pt7 { padding-top: 28px; }\n.pt8 { padding-top: 32px; }\n.pt9 { padding-top: 36px; }\n.pt10 { padding-top: 40px; }\n\n.pr1 { padding-right: 4px; }\n.pr2 { padding-right: 8px; }\n.pr3 { padding-right: 12px; }\n.pr4 { padding-right: 16px; }\n.pr5 { padding-right: 20px; }\n.pr6 { padding-right: 24px; }\n.pr7 { padding-right: 28px; }\n.pr8 { padding-right: 32px; }\n.pr9 { padding-right: 36px; }\n.pr10 { padding-right: 40px; }\n\n.pb1 { padding-bottom: 4px; }\n.pb2 { padding-bottom: 8px; }\n.pb3 { padding-bottom: 12px; }\n.pb4 { padding-bottom: 16px; }\n.pb5 { padding-bottom: 20px; }\n.pb6 { padding-bottom: 24px; }\n.pb7 { padding-bottom: 28px; }\n.pb8 { padding-bottom: 32px; }\n.pb9 { padding-bottom: 36px; }\n.pb10 { padding-bottom: 40px; }\n\n.pl1 { padding-left: 4px; }\n.pl2 { padding-left: 8px; }\n.pl3 { padding-left: 12px; }\n.pl4 { padding-left: 16px; }\n.pl5 { padding-left: 20px; }\n.pl6 { padding-left: 24px; }\n.pl7 { padding-left: 28px; }\n.pl8 { padding-left: 32px; }\n.pl9 { padding-left: 36px; }\n.pl10 { padding-left: 40px; }\n\n.hidden { display: none !important; }\n\n .gh-portal-account-header {\n display: flex;\n flex-direction: column;\n align-items: center;\n margin: 0 0 32px;\n }\n\n .gh-portal-account-header .gh-portal-avatar {\n margin: 6px 0 8px !important;\n }\n\n .gh-portal-account-data {\n margin-bottom: 40px;\n }\n\n footer.gh-portal-account-footer {\n display: flex;\n }\n\n .gh-portal-account-footer.paid {\n margin-top: 12px;\n }\n\n .gh-portal-account-footermenu {\n display: flex;\n align-items: center;\n list-style: none;\n padding: 0;\n margin: 0;\n }\n\n .gh-portal-account-footerright {\n display: flex;\n flex-grow: 1;\n align-items: center;\n justify-content: flex-end;\n }\n\n .gh-portal-account-footermenu li {\n margin-right: 16px;\n }\n\n .gh-portal-account-footermenu li:last-of-type {\n margin-right: 0;\n }\n\n .gh-portal-freeaccount-newsletter {\n display: flex;\n align-items: center;\n justify-content: space-between;\n margin-top: 24px;\n }\n\n .gh-portal-freeaccount-newsletter .label {\n display: flex;\n flex-direction: column;\n flex-grow: 1;\n }\n\n .gh-portal-free-ctatext {\n margin-top: -12px;\n }\n\n .gh-portal-cancelcontinue-container {\n margin: 24px 0 32px;\n }\n\n .gh-portal-billing-button-loader {\n width: 32px;\n height: 32px;\n margin-right: -3px;\n opacity: 0.6;\n }\n\n .gh-portal-product-icon {\n width: 52px;\n margin-right: 12px;\n border-radius: 2px;\n }\n\n .gh-portal-account-discountcontainer {\n position: relative;\n display: flex;\n align-items: center;\n }\n\n .gh-portal-account-old-price {\n text-decoration: line-through;\n color: var(--grey9) !important;\n }\n\n .gh-portal-account-tagicon {\n width: 16px;\n height: 16px;\n color: var(--brandcolor);\n margin-right: 5px;\n z-index: 999;\n }\n\n @media (max-width: 390px) {\n .gh-portal-account-footer {\n padding: 0 !important;\n }\n }\n\n @media (max-width: 340px) {\n .gh-portal-account-footer {\n padding: 0 !important;\n flex-wrap: wrap;\n gap: 12px;\n }\n\n .gh-portal-account-footer .gh-portal-account-footerright {\n justify-content: flex-start;\n }\n }\n\n .account-plan.full-size .gh-portal-main-title {\n font-size: 3.2rem;\n margin-top: 44px;\n }\n\n .gh-portal-accountplans-main {\n margin-top: 24px;\n margin-bottom: 0;\n }\n\n .gh-portal-expire-container {\n margin: 32px 0 0;\n }\n\n .gh-portal-cancellation-form p {\n margin-bottom: 12px;\n }\n\n .gh-portal-cancellation-form .gh-portal-input-section {\n margin-bottom: 20px;\n }\n\n .gh-portal-cancellation-form .gh-portal-input {\n resize: none;\n width: 100%;\n height: 62px;\n padding: 6px 12px;\n }\n\n .gh-portal-input {\n -webkit-appearance: none;\n -moz-appearance: none;\n appearance: none;\n\n display: block;\n box-sizing: border-box;\n font-size: 1.5rem;\n color: inherit;\n background: transparent;\n outline: none;\n border: 1px solid var(--grey11);\n border-radius: 6px;\n width: 100%;\n height: 44px;\n padding: 0 12px;\n margin-bottom: 18px;\n letter-spacing: 0.2px;\n transition: border-color 0.25s ease-in-out;\n }\n\n .gh-portal-input-labelcontainer {\n display: flex;\n justify-content: space-between;\n width: 100%;\n }\n\n .gh-portal-input-labelcontainer p {\n color: var(--red);\n font-size: 1.3rem;\n letter-spacing: 0.35px;\n line-height: 1.6em;\n margin-bottom: 0;\n }\n\n .gh-portal-input-label.hidden {\n display: none;\n }\n\n .gh-portal-input:focus {\n border-color: var(--grey8);\n }\n\n .gh-portal-input.error {\n border-color: var(--red);\n }\n\n .gh-portal-input::placeholder {\n color: var(--grey8);\n }\n\n .gh-portal-popup-container:not(.preview) .gh-portal-input:disabled {\n background: var(--grey13);\n color: var(--grey9);\n box-shadow: none;\n }\n\n .gh-portal-popup-container:not(.preview) .gh-portal-input:disabled::placeholder {\n color: var(--grey9);\n }\n\n .gh-portal-plans-container {\n display: flex;\n align-items: stretch;\n border: 1px solid var(--grey11);\n border-radius: 5px;\n }\n\n .gh-portal-plan-section {\n display: flex;\n flex-direction: column;\n flex: 1;\n position: relative;\n align-items: center;\n justify-items: center;\n font-size: 1.4rem;\n line-height: 1.35em;\n border-right: 1px solid var(--grey11);\n padding: 24px 10px;\n cursor: pointer;\n user-select: none;\n }\n\n .gh-portal-change-plan-section {\n border-top-left-radius: 0;\n border-top-right-radius: 0;\n }\n\n .gh-portal-plans-container.disabled .gh-portal-plan-section {\n cursor: auto;\n }\n\n .gh-portal-plan-section.checked::before {\n position: absolute;\n display: block;\n top: -1px;\n right: -1px;\n bottom: -1px;\n left: -1px;\n content: "";\n z-index: 999;\n border: 2px solid var(--brandcolor);\n pointer-events: none;\n }\n\n .gh-portal-plan-section:first-of-type::before {\n border-top-left-radius: 5px;\n border-bottom-left-radius: 5px;\n }\n\n .gh-portal-plan-section:last-of-type::before {\n border-top-right-radius: 5px;\n border-bottom-right-radius: 5px;\n }\n\n .gh-portal-plan-section:last-of-type {\n border-right: none;\n }\n\n .gh-portal-plans-container:not(.empty-selected-benefits) .gh-portal-plan-section::before {\n border-bottom-left-radius: 0;\n border-bottom-right-radius: 0;\n }\n\n .gh-portal-plans-container.has-discount {\n margin-top: 40px;\n }\n\n .gh-portal-plans-container.has-discount,\n .gh-portal-plans-container.has-discount .gh-portal-plan-section:last-of-type::before {\n border-top-right-radius: 0;\n }\n\n .gh-portal-plans-container.is-change-plan .gh-portal-plan-section::before {\n border-top-left-radius: 0;\n border-top-right-radius: 0;\n }\n\n .gh-portal-plans-container.disabled .gh-portal-plan-section.checked::before {\n opacity: 0.3;\n }\n\n .gh-portal-plan-pricelabel {\n display: flex;\n flex-direction: row;\n min-height: 28px;\n margin-top: 2px;\n }\n\n .gh-portal-plans-container .gh-portal-plan-pricelabel {\n min-height: unset;\n }\n\n .gh-portal-plan-pricecontainer {\n display: flex;\n }\n\n .gh-portal-plan-priceinterval {\n font-size: 1.25rem;\n line-height: 2;\n color: var(--grey7);\n }\n\n .gh-portal-plan-name {\n display: flex;\n align-items: center;\n font-size: 1.2rem;\n font-weight: 500;\n line-height: 1.0em;\n letter-spacing: 0.5px;\n text-transform: uppercase;\n margin-top: 4px;\n text-align: center;\n min-height: 24px;\n word-break: break-word;\n }\n\n .gh-portal-plan-currency {\n position: relative;\n bottom: 2px;\n font-size: 1.4rem;\n font-weight: 500;\n letter-spacing: 0.4px;\n }\n\n .gh-portal-plan-currency-code {\n margin-right: 2px;\n font-size: 1.15rem;\n }\n\n .gh-portal-plan-price {\n font-size: 2.2rem;\n font-weight: 500;\n letter-spacing: 0.1px;\n }\n\n .gh-portal-plan-type {\n color: var(--grey7);\n }\n\n .gh-portal-plan-featurewrapper {\n display: flex;\n flex-direction: column;\n align-items: center;\n border-top: 1px solid var(--grey12);\n padding-top: 12px;\n width: 100%;\n }\n\n .gh-portal-plan-feature {\n font-size: 1.25rem;\n font-weight: 500;\n line-height: 1.25em;\n text-align: center;\n letter-spacing: 0.2px;\n word-break: break-word;\n }\n\n .gh-portal-content.signup.singleplan .gh-portal-plan-section {\n cursor: auto;\n }\n\n .gh-portal-content.signup.singleplan .gh-portal-plan-section.checked::before {\n display: none;\n }\n\n .gh-portal-content.signup.singleplan .gh-portal-plan-name {\n margin-top: 0;\n }\n\n .gh-portal-plan-section:not(.checked)::before {\n position: absolute;\n display: block;\n top: -1px;\n right: -1px;\n bottom: -1px;\n left: -1px;\n content: "";\n z-index: 999;\n border: 1px solid var(--brandcolor);\n pointer-events: none;\n opacity: 0;\n transition: all 0.2s ease-in-out;\n }\n\n .gh-portal-plans-container.disabled .gh-portal-plan-section:not(.checked):hover::before {\n opacity: 0;\n }\n\n .gh-portal-plans-container.hide-checkbox .gh-portal-plan-section {\n padding-top: 12px;\n padding-bottom: 12px;\n }\n\n .gh-portal-plan-current {\n display: block;\n font-size: 1.25rem;\n letter-spacing: 0.2px;\n line-height: 1.25em;\n color: var(--brandcolor);\n margin: 3px 0 -2px;\n }\n\n .gh-portal-plans-container:not(.empty-selected-benefits) {\n border-bottom-left-radius: 0;\n border-bottom-right-radius: 0;\n }\n\n .gh-portal-plans-container.is-change-plan {\n border-radius: 0 0 5px 5px;\n border-top: none;\n }\n\n .gh-portal-plans-container.is-change-plan .gh-portal-plan-section {\n min-height: 90px;\n }\n\n .gh-portal-plan-product {\n border: 1px solid var(--grey11);\n border-radius: 5px;\n }\n\n .gh-portal-plan-product:not(:last-of-type) {\n margin-bottom: 20px;\n }\n\n .gh-portal-plan-productname {\n border-radius: 5px 5px 0 0;\n padding: 2px 10px;\n font-size: 1.25rem;\n letter-spacing: 0.3px;\n text-transform: uppercase;\n font-weight: 600;\n border-bottom: 1px solid var(--grey12);\n }\n\n .gh-portal-accountplans-main .gh-portal-plan-section:hover:not(.checked) {\n background: var(--grey14);\n }\n\n .gh-portal-accountplans-main .gh-portal-plan-section:last-of-type {\n border-radius: 0 0 5px 5px;\n }\n\n .gh-portal-singleproduct-benefits {\n display: flex;\n flex-direction: column;\n border: 1px solid var(--grey11);\n border-top: none !important;\n margin: 0 0 4px !important;\n padding: 16px 24px 12px !important;\n border-radius: 0 0 5px 5px;\n }\n\n .gh-portal-singleproduct-benefits.onlyfree {\n border-top: 1px solid var(--grey11) !important;\n border-radius: 5px;\n margin-top: 30px !important;\n }\n\n .gh-portal-singleproduct-benefits .gh-portal-product-benefit {\n padding: 0 8px;\n }\n\n .gh-portal-singleproduct-benefits .gh-portal-product-benefit:last-of-type {\n margin-bottom: 16px;\n }\n\n .gh-portal-singleproduct-benefits.onlyfree .gh-portal-product-benefit:last-of-type {\n margin-bottom: 4px;\n }\n\n .gh-portal-singleproduct-benefits:not(.no-benefits) .gh-portal-product-description {\n border-bottom: 1px solid var(--grey12);\n padding-bottom: 20px;\n margin-bottom: 16px;\n }\n'+function(e){return e.site,'\n .gh-portal-products {\n display: flex;\n flex-direction: column;\n align-items: center;\n }\n\n .gh-portal-products-pricetoggle {\n position: relative;\n display: flex;\n background: #F3F3F3;\n width: 100%;\n border-radius: 999px;\n padding: 4px;\n height: 44px;\n margin: 0 0 40px;\n }\n\n .gh-portal-products-pricetoggle:before {\n position: absolute;\n content: "";\n display: block;\n width: 50%;\n top: 4px;\n bottom: 4px;\n right: 4px;\n background: #fff;\n box-shadow: 0px 1px 3px rgba(0, 0, 0, 0.08);\n border-radius: 999px;\n transition: all 0.15s ease-in-out;\n }\n\n .gh-portal-products-pricetoggle.left:before {\n transform: translateX(calc(-100% + 8px));\n }\n\n .gh-portal-products-pricetoggle .gh-portal-btn {\n border: 0;\n height: 100% !important;\n width: 50%;\n border-radius: 999px;\n color: var(--grey7);\n background: transparent;\n font-size: 1.5rem;\n }\n\n .gh-portal-products-pricetoggle .gh-portal-btn.active {\n border: 0;\n height: 100%;\n width: 50%;\n color: var(--grey0);\n /*background: white;\n box-shadow: 0px 1px 3px rgba(0, 0, 0, 0.08);*/\n }\n\n .gh-portal-priceoption-label {\n font-size: 1.4rem;\n font-weight: 400;\n letter-spacing: 0.3px;\n margin: 0 6px;\n min-width: 180px;\n }\n\n .gh-portal-priceoption-label.monthly {\n text-align: right;\n }\n\n .gh-portal-priceoption-label.inactive {\n color: var(--grey8);\n }\n\n .gh-portal-products-grid {\n display: flex;\n flex-wrap: wrap;\n align-items: stretch;\n justify-content: center;\n gap: 40px;\n margin: 0 auto;\n padding: 0;\n width: 100%;\n }\n\n .gh-portal-product-card {\n flex: 1;\n max-width: 420px;\n min-width: 320px;\n position: relative;\n display: flex;\n flex-direction: column;\n align-items: flex-start;\n justify-content: stretch;\n background: white;\n padding: 32px;\n border-radius: 7px;\n border: 1px solid var(--grey11);\n min-height: 200px;\n transition: border-color 0.25s ease-in-out;\n }\n\n .gh-portal-product-card.top {\n border-bottom: none;\n border-radius: 7px 7px 0 0;\n padding-bottom: 0;\n }\n\n .gh-portal-product-card.bottom {\n border-top: none;\n border-radius: 0 0 7px 7px;\n padding-top: 0;\n }\n\n .gh-portal-product-card:not(.disabled):hover {\n border-color: var(--grey9);\n }\n\n .gh-portal-product-card.checked::before {\n position: absolute;\n display: block;\n top: -2px;\n right: -2px;\n bottom: -2px;\n left: -2px;\n content: "";\n z-index: 999;\n border: 0px solid var(--brandcolor);\n pointer-events: none;\n border-radius: 7px;\n }\n\n .gh-portal-product-card-header {\n width: 100%;\n min-height: 56px;\n }\n\n .gh-portal-product-card-name-trial {\n display: flex;\n align-items: center;\n }\n\n .gh-portal-product-card-name-trial .gh-portal-discount-label {\n margin-top: -4px;\n }\n\n .gh-portal-product-card-details {\n flex: 1;\n display: flex;\n flex-direction: column;\n width: 100%;\n }\n\n .gh-portal-product-name {\n font-size: 1.8rem;\n font-weight: 600;\n line-height: 1.3em;\n letter-spacing: 0px;\n margin-top: -4px;\n word-break: break-word;\n width: 100%;\n color: var(--brandcolor);\n }\n\n .gh-portal-discount-label-trial {\n color: var(--brandcolor);\n font-weight: 600;\n font-size: 1.3rem;\n line-height: 1;\n margin-top: 4px;\n }\n\n .gh-portal-discount-label {\n position: relative;\n font-size: 1.25rem;\n line-height: 1em;\n font-weight: 600;\n letter-spacing: 0.3px;\n color: var(--grey0);\n padding: 6px 9px;\n text-align: center;\n white-space: nowrap;\n border-radius: 999px;\n margin-right: -4px;\n max-height: 24.5px;\n }\n\n .gh-portal-discount-label:before {\n position: absolute;\n content: "";\n display: block;\n background: var(--brandcolor);\n top: 0;\n right: 0;\n bottom: 0;\n left: 0;\n border-radius: 999px;\n opacity: 0.2;\n }\n\n .gh-portal-product-card-price-trial {\n display: flex;\n flex-direction: row;\n align-items: flex-end;\n justify-content: space-between;\n flex-wrap: wrap;\n row-gap: 10px;\n column-gap: 4px;\n width: 100%;\n }\n\n .gh-portal-product-card-pricecontainer {\n display: flex;\n flex-direction: column;\n align-items: flex-start;\n width: 100%;\n margin-top: 16px;\n }\n\n .gh-portal-product-price {\n display: flex;\n justify-content: center;\n color: var(--grey0);\n }\n\n .gh-portal-product-price .currency-sign {\n align-self: flex-start;\n font-size: 2.7rem;\n font-weight: 700;\n line-height: 1.135em;\n }\n\n .gh-portal-product-price .currency-sign.long {\n margin-right: 5px;\n }\n\n .gh-portal-product-price .amount {\n font-size: 3.5rem;\n font-weight: 700;\n line-height: 1em;\n letter-spacing: -1.3px;\n color: var(--grey0);\n }\n\n .gh-portal-product-price .amount.trial-duration {\n letter-spacing: -0.022em;\n }\n\n .gh-portal-product-price .billing-period {\n align-self: flex-end;\n font-size: 1.5rem;\n line-height: 1.6em;\n color: var(--grey5);\n letter-spacing: 0.3px;\n margin-left: 5px;\n }\n\n .gh-portal-product-alternative-price {\n font-size: 1.3rem;\n line-height: 1.6em;\n color: var(--grey8);\n letter-spacing: 0.3px;\n display: none;\n }\n\n .after-trial-amount {\n display: block;\n font-size: 1.5rem;\n color: var(--grey5);\n margin-top: 6px;\n margin-bottom: 6px;\n line-height: 1;\n }\n\n .gh-portal-product-card-detaildata {\n flex: 1;\n }\n\n .gh-portal-product-description {\n font-size: 1.55rem;\n font-weight: 600;\n line-height: 1.4em;\n width: 100%;\n margin-top: 16px;\n }\n\n .gh-portal-product-benefits {\n font-size: 1.5rem;\n line-height: 1.4em;\n width: 100%;\n margin-top: 16px;\n }\n\n .gh-portal-product-benefit {\n display: flex;\n align-items: flex-start;\n margin-bottom: 10px;\n }\n\n .gh-portal-benefit-checkmark {\n width: 14px;\n height: 14px;\n min-width: 14px;\n margin: 3px 10px 0 0;\n overflow: visible;\n }\n\n .gh-portal-benefit-checkmark polyline,\n .gh-portal-benefit-checkmark g {\n stroke-width: 3px;\n }\n\n .gh-portal-products-grid.change-plan {\n padding: 0;\n }\n\n .gh-portal-btn-product {\n position: sticky;\n bottom: 0;\n display: flex;\n flex-direction: row;\n align-items: flex-end;\n width: 100%;\n justify-self: flex-end;\n padding: 40px 0 32px;\n margin-bottom: -32px;\n /*background: rgb(255,255,255);\n background: linear-gradient(0deg, rgba(255,255,255,1) 75%, rgba(255,255,255,0) 100%);*/\n background: transparent;\n }\n\n .gh-portal-btn-product::before {\n position: absolute;\n content: "";\n display: block;\n top: -16px;\n left: 0;\n right: 0;\n bottom: 0;\n background: linear-gradient(0deg, rgba(255,255,255,1) 60%, rgba(255,255,255,0) 100%);\n z-index: 800;\n }\n\n .gh-portal-btn-product .gh-portal-btn {\n background: var(--brandcolor);\n color: #fff;\n border: none;\n width: 100%;\n z-index: 900;\n }\n\n .gh-portal-btn-product .gh-portal-btn:hover {\n opacity: 0.9;\n }\n\n .gh-portal-current-plan {\n display: flex;\n align-items: center;\n justify-content: center;\n text-align: center;\n white-space: nowrap;\n width: 100%;\n height: 44px;\n border-radius: 5px;\n color: var(--grey5);\n font-size: 1.4rem;\n font-weight: 500;\n line-height: 1em;\n letter-spacing: 0.2px;\n font-weight: 500;\n background: #f0f0f0;\n z-index: 900;\n }\n\n .gh-portal-product-card.only-free {\n margin: 0 0 16px;\n min-height: unset;\n }\n\n .gh-portal-product-card.only-free .gh-portal-product-card-header {\n min-height: unset;\n }\n\n @media (max-width: 670px) {\n .gh-portal-products-grid {\n grid-template-columns: unset;\n grid-gap: 20px;\n width: 100%;\n max-width: 440px;\n }\n\n .gh-portal-priceoption-label {\n font-size: 1.25rem;\n }\n\n .gh-portal-products-priceswitch .gh-portal-discount-label {\n display: none;\n }\n\n .gh-portal-products-priceswitch {\n padding-top: 18px;\n }\n\n .gh-portal-product-card {\n min-height: unset;\n }\n\n .gh-portal-singleproduct-benefits .gh-portal-product-description {\n text-align: center;\n }\n\n .gh-portal-product-benefit:last-of-type {\n margin-bottom: 0;\n }\n }\n\n @media (max-width: 480px) {\n .gh-portal-product-price .amount {\n font-size: 3.4rem;\n }\n\n .gh-portal-product-card {\n min-width: unset;\n }\n\n .gh-portal-btn-product {\n position: static;\n }\n\n .gh-portal-btn-product::before {\n display: none;\n }\n }\n\n @media (max-width: 370px) {\n .gh-portal-product-price .currency-sign {\n font-size: 1.8rem;\n }\n\n .gh-portal-product-price .amount {\n font-size: 2.8rem;\n }\n }\n\n\n /* Upgrade and change plan*/\n .gh-portal-upgrade-product {\n margin-top: -70px;\n padding-top: 60px;\n }\n\n .gh-portal-upgrade-product .gh-portal-products-grid {\n grid-template-columns: unset;\n grid-gap: 20px;\n width: 100%;\n }\n\n .gh-portal-upgrade-product .gh-portal-discount-label {\n display: none;\n }\n\n .gh-portal-upgrade-product .gh-portal-product-card .gh-portal-plan-current {\n display: inline-block;\n position: relative;\n padding: 2px 8px;\n font-size: 1.2rem;\n letter-spacing: 0.3px;\n text-transform: uppercase;\n margin-bottom: 4px;\n }\n\n .gh-portal-upgrade-product .gh-portal-product-card .gh-portal-plan-current::before {\n position: absolute;\n content: "";\n top: 0;\n right: 0;\n bottom: 0;\n left: 0;\n border-radius: 999px;\n background: var(--brandcolor);\n opacity: 0.15;\n }\n\n @media (max-width: 880px) {\n .gh-portal-products-grid {\n flex-direction: column;\n margin: 0 auto;\n max-width: 420px;\n }\n\n .gh-portal-product-card-header {\n min-height: unset;\n }\n }\n '}({site:t})+'\n .gh-portal-for-switch label,\n .gh-portal-for-switch .container {\n position: relative;\n display: inline-block;\n width: 44px !important;\n height: 26px !important;\n cursor: pointer;\n }\n\n .gh-portal-for-switch label p,\n .gh-portal-for-switch .container p {\n overflow: auto;\n color: var(--grey0);\n font-weight: normal;\n }\n\n .gh-portal-for-switch input {\n opacity: 0;\n width: 0;\n height: 0;\n }\n\n .gh-portal-for-switch .input-toggle-component {\n position: absolute;\n top: 0;\n left: 0;\n right: 0;\n bottom: 0;\n background: #e9e9e9;\n transition: .3s;\n width: 44px !important;\n height: 26px !important;\n border-radius: 999px;\n transition: background 0.15s ease-in-out, border-color 0.15s ease-in-out;\n cursor: pointer;\n }\n\n .gh-portal-for-switch label:hover input:not(:checked) + .input-toggle-component,\n .gh-portal-for-switch .container:hover input:not(:checked) + .input-toggle-component {\n border-color: var(--grey9);\n }\n\n .gh-portal-for-switch .input-toggle-component:before {\n position: absolute;\n content: "";\n top: 3px !important;\n left: 3px !important;\n height: 20px !important;\n width: 20px !important;\n background-color: white;\n transition: .3s;\n border-radius: 999px;\n }\n\n .gh-portal-for-switch input:checked + .input-toggle-component {\n background: var(--brandcolor);\n border-color: transparent;\n }\n\n .gh-portal-for-switch input:checked + .input-toggle-component:before {\n transform: translateX(18px);\n box-shadow: none;\n }\n\n .gh-portal-for-switch .container {\n width: 38px !important;\n height: 22px !important;\n }\n\n .gh-portal-btn-main {\n box-shadow: none;\n position: relative;\n border: none;\n }\n\n .gh-portal-btn-main:hover,\n .gh-portal-btn-main:focus {\n box-shadow: none;\n border: none;\n }\n\n .gh-portal-btn-primary:hover,\n .gh-portal-btn-primary:focus {\n opacity: 0.92 !important;\n }\n\n .gh-portal-btn-primary:disabled:hover::before {\n display: none;\n }\n\n .gh-portal-btn-destructive:not(:disabled):hover {\n color: var(--red);\n border-color: var(--red);\n }\n\n .gh-portal-btn-text {\n padding: 0;\n font-weight: 500;\n height: unset;\n border: none;\n box-shadow: none;\n }\n\n .gh-portal-loadingicon {\n position: absolute;\n left: 50%;\n display: inline-block;\n margin-left: -19px;\n height: 31px;\n }\n\n .gh-portal-loadingicon path,\n .gh-portal-loadingicon rect {\n fill: #fff;\n }\n\n .gh-portal-loadingicon.dark path,\n .gh-portal-loadingicon.dark rect {\n fill: #1d1d1d;\n }\n\n .gh-portal-btn-back,\n .gh-portal-btn-back:hover {\n box-shadow: none;\n position: relative;\n height: unset;\n min-width: unset;\n position: fixed;\n top: 29px;\n left: 25px;\n background: none;\n padding: 8px;\n margin: 0;\n box-shadow: none;\n color: var(--grey3);\n border: none;\n z-index: 10000;\n }\n\n .gh-portal-btn-back:hover {\n color: var(--grey1);\n transform: translateX(-4px);\n }\n\n .gh-portal-btn-back svg {\n width: 17px;\n height: 17px;\n margin-top: 1px;\n margin-right: 2px;\n }\n'+Xn+"\n .gh-portal-icon-envelope {\n width: 44px;\n margin: 12px 0 10px;\n }\n\n .gh-portal-inbox-notification {\n display: flex;\n flex-direction: column;\n align-items: center;\n }\n\n .gh-portal-inbox-notification p {\n text-align: center;\n margin-bottom: 30px;\n }\n\n.gh-portal-back-sitetitle {\n position: absolute;\n top: 35px;\n left: 32px;\n}\n\n.gh-portal-back-sitetitle .gh-portal-btn {\n padding: 0;\n border: 0;\n font-size: 1.5rem;\n height: auto;\n line-height: 1em;\n color: var(--grey1);\n}\n\n.gh-portal-popup-wrapper:not(.full-size) .gh-portal-back-sitetitle,\n.gh-portal-popup-wrapper.preview .gh-portal-back-sitetitle {\n display: none;\n}\n\n.gh-portal-signup-logo {\n position: relative;\n display: block;\n background-position: 50%;\n background-size: cover;\n border-radius: 2px;\n width: 60px;\n height: 60px;\n margin: 12px 0 10px;\n}\n\n.gh-portal-signup-header,\n.gh-portal-signin-header {\n display: flex;\n flex-direction: column;\n align-items: center;\n padding: 0 32px;\n margin-bottom: 32px;\n}\n\n.gh-portal-popup-wrapper.full-size .gh-portal-signup-header {\n margin-top: 32px;\n}\n\n.gh-portal-signup-header .gh-portal-main-title,\n.gh-portal-signin-header .gh-portal-main-title {\n margin-top: 12px;\n}\n\n.gh-portal-signup-logo + .gh-portal-main-title {\n margin: 4px 0 0;\n}\n\n.gh-portal-signup-header .gh-portal-main-subtitle {\n font-size: 1.5rem;\n text-align: center;\n line-height: 1.45em;\n margin: 4px 0 0;\n color: var(--grey3);\n}\n\n.gh-portal-logged-out-form-container {\n width: 100%;\n max-width: 420px;\n margin: 0 auto;\n}\n\n.signup .gh-portal-input-section:last-of-type {\n margin-bottom: 40px;\n}\n\n.gh-portal-signup-message {\n display: flex;\n justify-content: center;\n color: var(--grey4);\n font-size: 1.5rem;\n margin: 16px 0 0;\n}\n\n.gh-portal-signup-message,\n.gh-portal-signup-message * {\n z-index: 9999;\n}\n\n.full-size .gh-portal-signup-message {\n margin: 24px 0 40px;\n}\n\n@media (max-width: 480px) {\n .preview .gh-portal-products + .gh-portal-signup-message {\n margin-bottom: 40px;\n }\n}\n\n.gh-portal-signup-message button {\n font-size: 1.4rem;\n font-weight: 600;\n margin-left: 4px !important;\n}\n\n.gh-portal-signup-message button span {\n display: inline-block;\n padding-bottom: 2px;\n margin-bottom: -2px;\n}\n\n.gh-portal-content.signup.invite-only {\n background: none;\n}\n\nfooter.gh-portal-signup-footer,\nfooter.gh-portal-signin-footer {\n display: flex;\n flex-direction: column;\n align-items: center;\n position: relative;\n padding-top: 24px;\n height: unset;\n}\n\n.gh-portal-content.signup,\n.gh-portal-content.signin {\n max-height: unset !important;\n padding-bottom: 0;\n}\n\n.gh-portal-content.signin {\n padding-bottom: 4px;\n}\n\n.gh-portal-content.signup .gh-portal-section {\n margin-bottom: 0;\n}\n\n.gh-portal-content.signup.single-field {\n margin-bottom: 4px;\n}\n\n.gh-portal-content.signup.single-field .gh-portal-input,\n.gh-portal-content.signin .gh-portal-input {\n margin-bottom: 8px;\n}\n\n.gh-portal-content.signup.single-field + .gh-portal-signup-footer,\nfooter.gh-portal-signin-footer {\n padding-top: 12px;\n}\n\n.gh-portal-content.signin .gh-portal-section {\n margin-bottom: 0;\n}\n\nfooter.gh-portal-signup-footer.invite-only {\n height: unset;\n}\n\nfooter.gh-portal-signup-footer.invite-only .gh-portal-signup-message {\n margin-top: 0;\n}\n\n.gh-portal-invite-only-notification {\n margin: 8px 32px 24px;\n padding: 0;\n text-align: center;\n color: var(--grey2);\n}\n\n.gh-portal-icon-invitation {\n width: 44px;\n height: 44px;\n margin: 12px 0 2px;\n}\n\n.gh-portal-popup-wrapper.full-size .gh-portal-popup-container.preview footer.gh-portal-signup-footer {\n padding-bottom: 32px;\n}\n\n.gh-portal-invite-only-notification + .gh-portal-signup-message {\n margin-bottom: 12px;\n}\n\n.gh-portal-free-trial-notification {\n max-width: 480px;\n text-align: center;\n margin: 24px auto;\n color: var(--grey4);\n}\n\n@media (min-width: 480px) {\n\n}\n\n@media (max-width: 480px) {\n .gh-portal-signup-logo {\n width: 48px;\n height: 48px;\n }\n}\n\n@media (min-width: 480px) and (max-width: 820px) {\n .gh-portal-powered.outside {\n left: 50%;\n transform: translateX(-50%);\n }\n}\n"+function(e){return e.site,"\n.gh-portal-offer {\n padding-bottom: 0;\n overflow: unset;\n max-height: unset;\n}\n\n.gh-portal-offer-container {\n display: flex;\n flex-direction: column;\n}\n\n.gh-portal-plans-container.offer {\n justify-content: space-between;\n border-color: var(--grey12);\n border-top: none;\n border-top-left-radius: 0;\n border-top-right-radius: 0;\n padding: 12px 16px;\n font-size: 1.3rem;\n}\n\n.gh-portal-offer-bar {\n position: relative;\n padding: 26px 28px 28px;\n margin-bottom: 24px;\n /*border: 1px dashed var(--brandcolor);*/\n background-image: url(\"data:image/svg+xml,%3csvg width='100%25' height='99.9%25' xmlns='http://www.w3.org/2000/svg'%3e%3crect width='100%25' height='100%25' fill='none' stroke='%23C3C3C3' stroke-width='3' stroke-dasharray='3%2c 9' stroke-dashoffset='0' stroke-linecap='square'/%3e%3c/svg%3e\");\n border-radius: 6px;\n}\n\n.gh-portal-offer-title {\n display: flex;\n justify-content: space-between;\n align-items: center;\n}\n\n.gh-portal-offer-title h4 {\n font-size: 1.8rem;\n margin: 0 110px 0 0;\n width: 100%;\n}\n\n.gh-portal-offer-title h4.placeholder {\n opacity: 0.4;\n}\n\n.gh-portal-offer-bar .gh-portal-discount-label {\n position: absolute;\n top: 23px;\n right: 25px;\n}\n\n.gh-portal-offer-bar p {\n padding-bottom: 0;\n margin: 12px 0 0;\n}\n\n.gh-portal-offer-title h4 + p {\n margin: 12px 0 0;\n}\n\n.gh-portal-offer-details .gh-portal-plan-name,\n.gh-portal-offer-details p {\n margin-right: 8px;\n}\n\n.gh-portal-offer .footnote {\n font-size: 1.35rem;\n color: var(--grey8);\n margin: 4px 0 0;\n}\n\n.offer .gh-portal-product-card {\n max-width: unset;\n min-height: 0;\n}\n\n.offer .gh-portal-product-card .gh-portal-product-card-pricecontainer:not(.offer-type-trial) {\n margin-top: 0px;\n}\n\n.offer .gh-portal-product-card-header {\n display: flex;\n flex-direction: column;\n align-items: flex-start;\n}\n\n.gh-portal-offer-oldprice {\n display: flex;\n position: relative;\n font-size: 1.8rem;\n font-weight: 300;\n color: var(--grey8);\n line-height: 1;\n white-space: nowrap;\n margin: 16px 0 4px;\n}\n\n.gh-portal-offer-oldprice:after {\n position: absolute;\n display: block;\n content: \"\";\n left: 0;\n top: 50%;\n right: 0;\n height: 1px;\n background: var(--grey8);\n}\n\n.gh-portal-offer-details p {\n margin-bottom: 12px;\n}\n\n.offer .after-trial-amount {\n margin-bottom: 0;\n}\n\n.offer .trial-duration {\n margin-top: 16px;\n}\n\n.gh-portal-cancel {\n white-space: nowrap;\n}\n "}({site:t})+'\n .gh-portal-popupnotification {\n position: absolute;\n top: 8px;\n left: 8px;\n right: 8px;\n padding: 12px;\n background: var(--grey2);\n z-index: 11000;\n border-radius: 5px;\n font-size: 1.5rem;\n box-shadow: 0px 0.8151839971542358px 0.8151839971542358px 0px rgba(0,0,0,0.01),\n 0px 2.2538793087005615px 2.2538793087005615px 0px rgba(0,0,0,0.02),\n 0px 5.426473140716553px 5.426473140716553px 0px rgba(0,0,0,0.03),\n 0px 18px 18px 0px rgba(0,0,0,0.04);\n animation: popupnotification-slidein 0.3s ease-in-out;\n }\n\n .gh-portal-popupnotification.slideout {\n animation: popupnotification-slideout 0.48s ease-in;\n }\n\n .gh-portal-popupnotification p {\n color: var(--white);\n margin: 0;\n padding: 0 20px;\n font-size: 1.5rem;\n line-height: 1.5em;\n letter-spacing: 0.2px;\n text-align: center;\n }\n\n .gh-portal-popupnotification a {\n color: var(--white);\n }\n\n .gh-portal-popupnotification-icon {\n position: absolute;\n top: 12px;\n left: 12px;\n width: 20px;\n height: 20px;\n }\n\n .gh-portal-popupnotification-icon.success {\n color: var(--green);\n }\n\n .gh-portal-popupnotification-icon.error {\n color: #FF2828;\n }\n\n .gh-portal-popupnotification .closeicon {\n position: absolute;\n top: 3px;\n bottom: 0;\n right: 3px;\n color: var(--white);\n cursor: pointer;\n width: 16px;\n height: 16px;\n padding: 12px;\n transition: all 0.15s ease-in-out forwards;\n opacity: 0.8;\n }\n\n .gh-portal-popupnotification .closeicon:hover {\n opacity: 1.0;\n }\n\n @keyframes popupnotification-slidein {\n 0% { \n transform: translateY(-10px); \n opacity: 0;\n }\n 60% { transform: translateY(2px); }\n 100% { \n transform: translateY(0); \n opacity: 1.0;\n }\n }\n\n @keyframes popupnotification-slideout {\n 0% { \n transform: translateY(0);\n opacity: 1.0;\n }\n 40% { transform: translateY(2px); }\n 100% { \n transform: translateY(-10px);\n opacity: 0;\n }\n }\n\n@media (max-width: 1440px) {\n .gh-portal-popup-container:not(.full-size):not(.preview) {\n width: 460px;\n }\n\n .gh-portal-input {\n height: 42px;\n margin-bottom: 16px;\n }\n\n button[class="gh-portal-btn"],\n .gh-portal-btn-main,\n .gh-portal-btn-primary {\n height: 42px;\n }\n\n .gh-portal-product-price .amount {\n font-size: 32px;\n letter-spacing: -0.022em;\n }\n}\n\n@media (max-width: 960px) {\n .gh-portal-powered {\n display: flex;\n position: relative;\n bottom: unset;\n left: unset;\n background: var(--white);\n justify-content: center;\n width: 100%;\n padding-top: 32px;\n }\n}\n\n@media (min-width: 520px) {\n .gh-portal-popup-wrapper.full-size .gh-portal-popup-container.preview {\n box-shadow:\n 0 0 0 1px rgba(0,0,0,0.02),\n 0 2.8px 2.2px rgba(0, 0, 0, 0.02),\n 0 6.7px 5.3px rgba(0, 0, 0, 0.028),\n 0 12.5px 10px rgba(0, 0, 0, 0.035),\n 0 22.3px 17.9px rgba(0, 0, 0, 0.042),\n 0 41.8px 33.4px rgba(0, 0, 0, 0.05),\n 0 100px 80px rgba(0, 0, 0, 0.07);\n animation: none;\n margin: 32px;\n padding: 32px 32px 0;\n width: calc(100vw - 64px);\n height: calc(100vh - 160px);\n min-height: unset;\n border-radius: 12px;\n overflow: auto;\n justify-content: flex-start;\n }\n}\n\n@media (max-width: 480px) {\n .gh-portal-detail-header {\n margin-top: 4px;\n }\n\n .gh-portal-popup-wrapper {\n height: 100%;\n padding: 0;\n display: flex;\n flex-direction: column;\n align-items: center;\n justify-content: space-between;\n background: var(--white);\n overflow-y: auto;\n }\n\n .gh-portal-popup-container {\n width: 100% !important;\n border-radius: 0;\n overflow: unset;\n animation: popup-mobile 0.25s ease-in-out;\n box-shadow: none !important;\n transform: translateY(0);\n padding: 28px !important;\n }\n\n .gh-portal-popup-container.full-size {\n justify-content: flex-start;\n }\n\n .gh-portal-popup-wrapper.account-home,\n .gh-portal-popup-container.account-home {\n background: var(--grey13);\n }\n\n .gh-portal-popup-wrapper.full-size .gh-portal-closeicon, \n .gh-portal-popup-container.full-size .gh-portal-closeicon {\n width: 16px;\n height: 16px;\n }\n\n /* Small width preview in Admin */\n .gh-portal-popup-wrapper.preview:not(.full-size) footer.gh-portal-signup-footer, \n .gh-portal-popup-wrapper.preview:not(.full-size) footer.gh-portal-signin-footer {\n padding-bottom: 32px;\n }\n\n .gh-portal-popup-container.preview:not(.full-size) {\n max-height: 660px;\n margin-bottom: 0;\n }\n\n .gh-portal-popup-container.preview:not(.full-size).offer {\n max-height: 860px;\n padding-bottom: 0 !important;\n }\n\n .gh-portal-popup-wrapper.preview.full-size {\n height: unset;\n max-height: 660px;\n }\n\n .gh-portal-popup-container.preview.full-size {\n max-height: 660px;\n margin-bottom: 0;\n }\n \n .preview .gh-portal-invite-only-notification + .gh-portal-signup-message {\n margin-bottom: 16px;\n }\n\n .preview .gh-portal-btn-container.sticky {\n margin-bottom: 32px;\n padding-bottom: 0;\n }\n\n .gh-portal-powered {\n padding-top: 12px;\n padding-bottom: 24px;\n }\n}\n\n@media (max-width: 390px) {\n .gh-portal-popup-container:not(.account-plan) .gh-portal-detail-header .gh-portal-main-title {\n font-size: 2.1rem;\n margin-top: 1px;\n padding: 0 74px;\n text-align: center;\n }\n\n .gh-portal-input {\n margin-bottom: 16px;\n }\n\n .gh-portal-signup-header,\n .gh-portal-signin-header {\n padding-bottom: 16px;\n }\n}\n\n@media (min-width: 480px) and (max-height: 880px) {\n .gh-portal-popup-wrapper {\n padding: 4vmin 0 0;\n }\n}\n\n@keyframes popup-mobile {\n 0% {\n opacity: 0;\n }\n 100%{\n opacity: 1.0;\n }\n}\n\n/* Prevent zoom */\n@media (hover:none) {\n select, textarea, input[type="text"], input[type="text"], input[type="password"],\n input[type="datetime"], input[type="datetime-local"],\n input[type="date"], input[type="month"], input[type="time"],\n input[type="week"], input[type="number"], input[type="email"],\n input[type="url"] {\n font-size: 16px !important;\n }\n}\n\n.gh-portal-popup-wrapper.multiple-products .gh-portal-input-section {\n max-width: 420px;\n margin: 0 auto;\n}\n\n/* Multiple product signup/signin-only modifications! */\n.gh-portal-popup-wrapper.multiple-products {\n background: #fff;\n box-shadow: 0 3.8px 2.2px rgba(0, 0, 0, 0.028), 0 9.2px 5.3px rgba(0, 0, 0, 0.04), 0 17.3px 10px rgba(0, 0, 0, 0.05), 0 30.8px 17.9px rgba(0, 0, 0, 0.06), 0 57.7px 33.4px rgba(0, 0, 0, 0.072), 0 138px 80px rgba(0, 0, 0, 0.1);\n padding: 0;\n border-radius: 5px;\n height: calc(100vh - 64px);\n max-width: calc(100vw - 64px);\n}\n\n.gh-portal-popup-wrapper.multiple-products.signup {\n overflow-y: scroll;\n overflow-x: clip;\n margin: 32px auto !important;\n padding-right: 0 !important; /* Override scrollbar hiding */\n}\n\n.gh-portal-popup-wrapper.multiple-products.signin {\n margin: 10vmin auto;\n max-width: 480px;\n height: unset;\n}\n\n.gh-portal-popup-wrapper.multiple-products.preview {\n height: calc(100vh - 150px) !important;\n}\n\n.gh-portal-popup-wrapper.multiple-products .gh-portal-popup-container {\n align-items: center;\n width: 100% !important;\n box-shadow: none !important;\n animation: fadein 0.35s ease-in-out;\n padding: 1vmin 0;\n transform: translateY(0px);\n margin-bottom: 0;\n}\n\n.gh-portal-popup-wrapper.multiple-products.signup .gh-portal-popup-container {\n min-height: calc(100vh - 64px);\n position: unset;\n}\n\n.gh-portal-popup-wrapper.multiple-products .gh-portal-powered {\n position: relative;\n display: flex;\n flex: 1;\n align-items: flex-end;\n justify-content: flex-start;\n bottom: unset;\n left: unset;\n width: 100%;\n z-index: 10000;\n padding-bottom: 32px;\n}\n\n@media (max-width: 670px) {\n .gh-portal-popup-wrapper.multiple-products .gh-portal-powered {\n justify-content: center;\n }\n}\n\n.gh-portal-popup-wrapper.multiple-products .gh-portal-content {\n position: unset;\n overflow-y: visible;\n max-height: unset !important;\n}\n\n@media (max-width: 960px) {\n .gh-portal-popup-wrapper.multiple-products.signup:not(.preview) {\n margin: 20px !important;\n height: 100%;\n }\n}\n\n@media (max-width: 480px) {\n .gh-portal-popup-wrapper.multiple-products {\n margin: 0 !important;\n max-width: unset !important;\n max-height: 100% !important;\n height: 100% !important;\n border-radius: 0px;\n box-shadow: none;\n }\n\n .gh-portal-popup-wrapper.multiple-products.signup:not(.preview) {\n margin: 0 !important;\n }\n\n .gh-portal-popup-wrapper.multiple-products.preview {\n height: unset !important;\n margin: 0 !important;\n }\n\n .gh-portal-popup-wrapper.multiple-products:not(.dev) .gh-portal-popup-container.preview {\n max-height: 640px;\n }\n}\n\n.gh-portal-popup-container.preview * {\n pointer-events: none !important;\n}\n\n.gh-portal-unsubscribe-logo {\n width: 60px;\n height: 60px;\n border-radius: 2px;\n margin-top: 12px;\n margin-bottom: 6px;\n}\n\n@media (max-width: 480px) {\n .gh-portal-unsubscribe-logo {\n width: 48px;\n height: 48px;\n }\n}\n\n.gh-portal-unsubscribe .gh-portal-main-title {\n margin-bottom: 16px;\n font-size: 2.6rem;\n}\n\n.gh-portal-unsubscribe p {\n margin-bottom: 16px;\n}\n\n.gh-portal-unsubscribe p:last-of-type {\n margin-bottom: 0;\n}\n\n.gh-portal-btn-inline {\n display: inline-block;\n margin-left: 4px;\n font-size: 1.5rem;\n font-weight: 600;\n cursor: pointer;\n}\n\n.gh-portal-toggle-checked {\n transition: all 0.3s;\n transition-delay: 2s;\n}\n\n.gh-portal-checkmark-container {\n display: flex;\n opacity: 0;\n margin-right: 8px;\n transition: opacity ease 0.4s 0.2s;\n}\n\n.gh-portal-checkmark-show {\n opacity: 1;\n}\n\n.gh-portal-checkmark-icon {\n height: 22px;\n color: #30cf43;\n}\n\n@keyframes fadeIn {\n 0% {\n opacity: 0;\n }\n 100% {\n opacity: 1;\n }\n}\n\n@keyframes fadeOut {\n 0% {\n opacity: 1;\n }\n 100% {\n opacity: 0;\n }\n}\n\n.gh-portal-newsletter-selection {\n animation: 0.5s ease-in-out fadeIn;\n}\n\n.gh-portal-signup {\n animation: 0.5s ease-in-out fadeIn;\n}\n\n.gh-portal-btn-different-plan {\n margin: 0 auto 24px;\n color: var(--grey6);\n font-weight: 400;\n}\n\n.gh-portal-hide {\n display: none;\n}\n';return n}({site:this.context.site}),t="\n :root {\n --brandcolor: ".concat(this.context.brandColor,"\n }\n ")+e;return Object($n.jsxs)($n.Fragment,{children:[Object($n.jsx)("style",{dangerouslySetInnerHTML:{__html:t}}),Object($n.jsx)("meta",{name:"viewport",content:"width=device-width, initial-scale=1, maximum-scale=1"})]})}},{key:"renderFrameContainer",value:function(){var e=this,t=this.context,n=t.member,r=t.site,i=t.customSiteUrl,o=gl({member:n}),a=Object(k.a)({},o.frame.common),l="gh-portal-popup-background";return Ur(["preview"])&&(o.modalContainer.zIndex="3999997"),Ur(["preview"],{customSiteUrl:i})&&!r.disableBackground&&(l+=" preview"),Ur(["dev"])&&(l+=" dev"),Object($n.jsx)("div",{style:o.modalContainer,children:Object($n.jsxs)(Qn,{style:a,title:"portal-popup",head:this.renderFrameStyles(),children:[Object($n.jsx)("div",{className:l,onClick:function(t){return e.handlePopupClose(t)}}),Object($n.jsx)(vl,{})]})})}},{key:"render",value:function(){return this.context.showPopup?this.renderFrameContainer():null}}]),n}(ml.Component);xl.contextType=tr;jl({products:_l({numOfProducts:1})});function wl(){return((new Date).getTime()/1e3|0).toString(16)+"xxxxxxxxxxxxxxxx".replace(/[x]/g,(function(){return(16*Math.random()|0).toString(16)})).toLowerCase()}function jl(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{},t=e.title,n=void 0===t?"The Blueprint":t,r=e.description,i=void 0===r?"Thoughts, stories and ideas.":r,o=e.logo,a=void 0===o?"https://static.ghost.org/v4.0.0/images/ghost-orb-1.png":o,l=e.icon,s=void 0===l?"https://static.ghost.org/v4.0.0/images/ghost-orb-1.png":l,c=e.url,u=void 0===c?"https://portal.localhost":c,p=e.plans,d=void 0===p?{monthly:5e3,yearly:15e4,currency:"USD"}:p,f=e.products,h=void 0===f?_l({numOfProducts:1}):f,m=e.portalProducts,g=void 0===m?h.map((function(e){return e.id})):m,b=e.accentColor,v=void 0===b?"#45C32E":b,y=e.portalPlans,x=void 0===y?["free","monthly","yearly"]:y,w=e.allowSelfSignup,j=void 0===w||w,O=e.membersSignupAccess,k=void 0===O?"all":O,_=e.freePriceName,S=void 0===_?"Free":_,P=e.freePriceDescription,E=void 0===P?"Free preview":P,C=e.isStripeConfigured,N=void 0===C||C,T=e.portalButton,I=void 0===T||T,L=e.portalName,M=void 0===L||L,F=e.portalButtonIcon,D=void 0===F?"icon-1":F,z=e.portalButtonSignupText,R=void 0===z?"Subscribe now":z,U=e.portalButtonStyle,A=void 0===U?"icon-and-text":U,B=e.membersSupportAddress,H=void 0===B?"support@example.com":B,q=e.newsletters,$=void 0===q?[]:q,W=e.commentsEnabled;return{title:n,description:i,logo:a,icon:s,accent_color:v,url:u,plans:d,products:h,portal_products:g,allow_self_signup:j,members_signup_access:k,free_price_name:S,free_price_description:E,is_stripe_configured:N,portal_button:I,portal_name:M,portal_plans:x,portal_button_icon:D,portal_button_signup_text:R,portal_button_style:A,members_support_address:H,comments_enabled:!!W,newsletters:$}}function Ol(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{},t=e.name,n=void 0===t?"Black Friday":t,r=e.code,i=void 0===r?"black-friday":r,o=e.displayTitle,a=void 0===o?"Black Friday Sale!":o,l=e.displayDescription,s=void 0===l?"Special deal for Black Friday. Subscribe now for only $15 per month and get additional benefits like accessing our podcast.":l,c=e.type,u=void 0===c?"percent":c,p=e.cadence,d=void 0===p?"month":p,f=e.amount,h=void 0===f?50:f,m=e.duration,g=void 0===m?"repeating":m,b=e.durationInMonths,v=void 0===b?null:b,y=e.currencyRestriction,x=void 0!==y&&y,w=e.currency,j=void 0===w?null:w,O=e.status,k=void 0===O?"active":O,_=e.tierId,S=void 0===_?"":_,P=e.tierName,E=void 0===P?"Basic":P;return{id:"offer_".concat(wl()),name:n,code:i,display_title:a,display_description:s,type:u,cadence:d,amount:h,duration:g,duration_in_months:v,currency_restriction:x,currency:j,status:k,tier:{id:"".concat(S),name:E}}}function kl(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{},t=e.name,n=void 0===t?"Jamie Larson":t,r=e.email,i=void 0===r?"jamie@example.com":r,o=e.firstname,a=void 0===o?"Jamie":o,l=e.subscriptions,s=void 0===l?[]:l,c=e.paid,u=void 0!==c&&c,p=e.avatarImage,d=void 0===p?"":p,f=e.subscribed,h=void 0===f||f;return{uuid:"member_".concat(wl()),email:i,name:n,firstname:a,paid:u,subscribed:h,avatar_image:d,subscriptions:s}}function _l(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{},t=e.numOfProducts,n=void 0===t?3:t,r=[Sl({name:"Bronze",description:"Access to all members articles",monthlyPrice:Nl({interval:"month",amount:700}),yearlyPrice:Nl({interval:"year",amount:7e3}),numOfBenefits:2}),Sl({name:"Silver",description:"Access to all members articles and weekly podcast",monthlyPrice:Nl({interval:"month",amount:1200}),yearlyPrice:Nl({interval:"year",amount:12e3}),numOfBenefits:3}),Sl({name:"Friends of the Blueprint",description:"Get access to everything and lock in early adopter pricing for life + listen to my podcast",monthlyPrice:Nl({interval:"month",amount:18e3}),yearlyPrice:Nl({interval:"year",amount:17e3}),numOfBenefits:4})],i=r.slice(0,n),o=Pl({});return[].concat(Ba(i),[o])}function Sl(e){var t=e.type,n=void 0===t?"paid":t,r=e.name,i=void 0===r?"Basic":r,o=e.description,a=void 0===o?"":o,l=e.id,s=void 0===l?"product_".concat(wl()):l,c=e.monthlyPrice,u=void 0===c?Nl():c,p=e.yearlyPrice,d=void 0===p?Nl({interval:"year"}):p,f=e.numOfBenefits;return{id:s,name:i,description:a,monthlyPrice:"free"===n?null:u,yearlyPrice:"free"===n?null:d,type:n,benefits:El({numOfBenefits:void 0===f?2:f})}}function Pl(e){var t=e.name,n=void 0===t?"Free tier":t,r=e.description,i=void 0===r?"Free tier description":r,o=e.id,a=void 0===o?"product_".concat(wl()):o,l=e.numOfBenefits;return{id:a,name:n,type:"free",description:i,benefits:El({numOfBenefits:void 0===l?2:l})}}function El(e){var t=e.numOfBenefits;return[Cl({name:"Limited early adopter pricing"}),Cl({name:"Latest gear reviews"}),Cl({name:"Weekly email newsletter"}),Cl({name:"Listen to my podcast"})].slice(0,t)}function Cl(e){var t=e.id,n=void 0===t?"benefit_".concat(wl()):t,r=e.name;return{id:n,name:void 0===r?"Benefit":r}}function Nl(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{},t=e.interval,n=void 0===t?"month":t,r=e.amount,i=void 0===r?"month"===n?500:5e3:r,o=e.nickname,a=void 0===o?"month"===n?"Monthly":"Yearly":o,l=e.description,s=void 0===l?null:l,c=e.currency,u=void 0===c?"usd":c,p=e.active,d=void 0===p||p,f=e.id,h=void 0===f?"price_".concat(wl()):f;return{id:h,active:d,nickname:a,currency:u,amount:i,interval:n,description:s,stripe_price_id:"price_".concat(wl()),stripe_product_id:"prod_".concat(wl()),type:"recurring"}}function Tl(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{},t=e.id,n=void 0===t?"sub_".concat(wl()):t,r=e.status,i=void 0===r?"active":r,o=e.currency,a=void 0===o?"USD":o,l=e.interval,s=void 0===l?"year":l,c=e.amount,u=void 0===c?"month"===s?500:5e3:c,p=e.nickname,d=void 0===p?"month"===s?"Monthly":"Yearly":p,f=e.cardLast4,h=void 0===f?"4242":f,m=e.offer,g=void 0===m?Ml:m,b=e.priceId,v=void 0===b?"price_".concat(wl()):b,y=e.startDate,x=void 0===y?"2021-10-05T03:18:30.000Z":y,w=e.currentPeriodEnd,j=void 0===w?"2022-10-05T03:18:30.000Z":w,O=e.cancelAtPeriodEnd,k=void 0!==O&&O;return{id:n,customer:{id:"cus_".concat(wl()),name:"Jamie",email:"jamie@example.com"},plan:{id:"price_".concat(wl()),nickname:d,amount:u,interval:s,currency:a},offer:g,status:i,start_date:x,default_payment_card_last4:h,cancel_at_period_end:k,cancellation_reason:null,current_period_end:j,price:{id:"stripe_price_".concat(wl()),price_id:v,nickname:d,amount:u,interval:s,type:"recurring",currency:a,product:{id:"stripe_prod_".concat(wl()),product_id:"prod_".concat(wl())}}}}function Il(){var e=_l({numOfProducts:1}),t=e.map((function(e){return e.id}));return jl({products:e,portalPlans:["free","monthly","yearly"],portalProducts:t})}Il();var Ll,Ml=Ol({tierId:null===(yl=jl({products:[Sl({numOfBenefits:2,type:"free"})]}).products[0])||void 0===yl?void 0:yl.id});kl(),kl({paid:!0,subscriptions:[Tl()]}),kl({paid:!0,subscriptions:[]}),kl({paid:!0,subscriptions:[Tl({amount:0})]}),kl({paid:!0,subscriptions:[Tl({amount:1500,startDate:"2019-05-01T11:42:40.000Z",currentPeriodEnd:"2021-06-05T11:42:40.000Z"})]});Il();var Fl=[Pl({name:"Free",description:"Free tier description which is actually a pretty long description",numOfBenefits:2}),Sl({name:"The Blueprint",description:"",monthlyPrice:Nl({interval:"month",amount:500}),yearlyPrice:Nl({interval:"year",amount:5e3}),numOfBenefits:3}),Sl({name:"Friends of the Blueprint Silver",description:"Access to all members articles and weekly podcast",monthlyPrice:Nl({interval:"month",amount:1200}),yearlyPrice:Nl({interval:"year",amount:11e3}),numOfBenefits:4})],Dl=jl({title:"The Blueprint",description:"Thoughts, stories and ideas.",logo:"https://static.ghost.org/v4.0.0/images/ghost-orb-1.png",icon:"https://static.ghost.org/v4.0.0/images/ghost-orb-1.png",accentColor:"#45C32E",url:"https://portal.localhost",plans:{monthly:5e3,yearly:15e4,currency:"USD"},products:Fl,portalProducts:Fl.map((function(e){return e.id})),allowSelfSignup:!0,membersSignupAccess:"all",freePriceName:"Free",freePriceDescription:"Free preview",isStripeConfigured:!0,portalButton:!0,portalName:!0,portalPlans:["free","monthly","yearly"],portalButtonIcon:"icon-1",portalButtonSignupText:"Subscribe now",portalButtonStyle:"icon-and-text",membersSupportAddress:"support@example.com",commentsEnabled:!0,newsletters:[{id:"weekly",name:"Weekly Rundown",description:"Best of last week",subscribe_on_signup:!0,paid:!0},{id:"daily",name:"Daily Brief",description:"One email every day",subscribe_on_signup:!1,paid:!1}]}),zl=Ol({tierId:null===(Ll=Dl.products[1])||void 0===Ll?void 0:Ll.id}),Rl={free:kl({name:"Jamie Larson",email:"jamie@example.com",firstname:"Jamie",subscriptions:[],paid:!1,avatarImage:"",subscribed:!0}),paid:kl({paid:!0,subscriptions:[Tl({status:"active",currency:"USD",interval:"year",amount:5e3,cardLast4:"4242",startDate:"2021-10-05T03:18:30.000Z",currentPeriodEnd:"2022-10-05T03:18:30.000Z",cancelAtPeriodEnd:!1})]}),complimentary:kl({paid:!0,subscriptions:[]}),complimentaryWithSubscription:kl({paid:!0,subscriptions:[Tl({amount:0})]}),preview:kl({paid:!0,subscriptions:[Tl({amount:1500,startDate:"2019-05-01T11:42:40.000Z",currentPeriodEnd:"2021-06-05T11:42:40.000Z"})]})};function Ul(e){var t=e.state;return Object(Fr.removePortalLinkFromUrl)(),{showPopup:!1,lastPage:null,pageQuery:"",popupNotification:null,page:"magiclink"===t.page?"":t.page}}function Al(){return(Al=f(S.a.mark((function e(t){var n,r;return S.a.wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return n=t.api,r=t.state,e.prev=1,e.next=4,n.member.signout();case 4:return e.abrupt("return",{action:"signout:success"});case 7:return e.prev=7,e.t0=e.catch(1),e.abrupt("return",{action:"signout:failed",popupNotification:Object(Fr.createPopupNotification)({type:"signout:failed",autoHide:!1,closeable:!0,state:r,status:"error",message:"Failed to log out, please try again"})});case 10:case"end":return e.stop()}}),e,null,[[1,7]])})))).apply(this,arguments)}function Bl(){return(Bl=f(S.a.mark((function e(t){var n,r,i;return S.a.wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return n=t.data,r=t.api,i=t.state,e.prev=1,e.next=4,r.member.sendMagicLink(n);case 4:return e.abrupt("return",{page:"magiclink",lastPage:"signin"});case 7:return e.prev=7,e.t0=e.catch(1),e.abrupt("return",{action:"signin:failed",popupNotification:Object(Fr.createPopupNotification)({type:"signin:failed",autoHide:!1,closeable:!0,state:i,status:"error",message:"Failed to log in, please try again"})});case 10:case"end":return e.stop()}}),e,null,[[1,7]])})))).apply(this,arguments)}function Hl(){return(Hl=f(S.a.mark((function e(t){var n,r,i,o,a,l,s,c,u,p,d,f;return S.a.wrap((function(e){for(;;)switch(e.prev=e.next){case 0:if(n=t.data,r=t.state,i=t.api,e.prev=1,o=n.plan,a=n.tierId,l=n.cadence,s=n.email,c=n.name,u=n.newsletters,p=n.offerId,"free"!==o.toLowerCase()){e.next=8;break}return e.next=6,i.member.sendMagicLink(n);case 6:case 11:e.next=18;break;case 8:if(!a||!l){e.next=13;break}return e.next=11,i.member.checkoutPlan({plan:o,tierId:a,cadence:l,email:s,name:c,newsletters:u,offerId:p});case 13:return d=Object(Fr.getProductCadenceFromPrice)({site:null===r||void 0===r?void 0:r.site,priceId:o}),a=d.tierId,l=d.cadence,e.next=18,i.member.checkoutPlan({plan:o,tierId:a,cadence:l,email:s,name:c,newsletters:u,offerId:p});case 18:return e.abrupt("return",{page:"magiclink",lastPage:"signup"});case 21:return e.prev=21,e.t0=e.catch(1),f=(null===e.t0||void 0===e.t0?void 0:e.t0.message)||"Failed to sign up, please try again",e.abrupt("return",{action:"signup:failed",popupNotification:Object(Fr.createPopupNotification)({type:"signup:failed",autoHide:!1,closeable:!0,state:r,status:"error",message:f})});case 25:case"end":return e.stop()}}),e,null,[[1,21]])})))).apply(this,arguments)}function ql(){return(ql=f(S.a.mark((function e(t){var n,r,i,o,a,l,s,c;return S.a.wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return n=t.data,r=t.state,i=t.api,e.prev=1,o=n.plan,a=n.offerId,l=n.tierId,s=n.cadence,l&&s||(c=Object(Fr.getProductCadenceFromPrice)({site:null===r||void 0===r?void 0:r.site,priceId:o}),l=c.tierId,s=c.cadence),e.next=6,i.member.checkoutPlan({plan:o,tierId:l,cadence:s,offerId:a,metadata:{checkoutType:"upgrade"}});case 6:e.next=11;break;case 8:return e.prev=8,e.t0=e.catch(1),e.abrupt("return",{action:"checkoutPlan:failed",popupNotification:Object(Fr.createPopupNotification)({type:"checkoutPlan:failed",autoHide:!1,closeable:!0,state:r,status:"error",message:"Failed to process checkout, please try again"})});case 11:case"end":return e.stop()}}),e,null,[[1,8]])})))).apply(this,arguments)}function $l(){return($l=f(S.a.mark((function e(t){var n,r,i,o,a,l,s,c,u,p,d,f;return S.a.wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return n=t.data,r=t.state,i=t.api,e.prev=1,o=n.plan,a=n.planId,l=n.subscriptionId,s=n.cancelAtPeriodEnd,c=Object(Fr.getProductCadenceFromPrice)({site:null===r||void 0===r?void 0:r.site,priceId:a}),u=c.tierId,p=c.cadence,e.next=6,i.member.updateSubscription({planName:o,tierId:u,cadence:p,subscriptionId:l,cancelAtPeriodEnd:s,planId:a});case 6:return e.next=8,i.member.sessionData();case 8:return d=e.sent,f="updateSubscription:success",e.abrupt("return",{action:f,popupNotification:Object(Fr.createPopupNotification)({type:f,autoHide:!0,closeable:!0,state:r,status:"success",message:"Subscription plan updated successfully"}),page:"accountHome",member:d});case 13:return e.prev=13,e.t0=e.catch(1),e.abrupt("return",{action:"updateSubscription:failed",popupNotification:Object(Fr.createPopupNotification)({type:"updateSubscription:failed",autoHide:!1,closeable:!0,state:r,status:"error",message:"Failed to update subscription, please try again"})});case 16:case"end":return e.stop()}}),e,null,[[1,13]])})))).apply(this,arguments)}function Wl(){return(Wl=f(S.a.mark((function e(t){var n,r,i,o,a,l;return S.a.wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return n=t.data,r=t.state,i=t.api,e.prev=1,o=n.subscriptionId,a=n.cancellationReason,e.next=5,i.member.updateSubscription({subscriptionId:o,smartCancel:!0,cancellationReason:a});case 5:return e.next=7,i.member.sessionData();case 7:return l=e.sent,"cancelSubscription:success",e.abrupt("return",{action:"cancelSubscription:success",page:"accountHome",member:l});case 12:return e.prev=12,e.t0=e.catch(1),e.abrupt("return",{action:"cancelSubscription:failed",popupNotification:Object(Fr.createPopupNotification)({type:"cancelSubscription:failed",autoHide:!1,closeable:!0,state:r,status:"error",message:"Failed to cancel subscription, please try again"})});case 15:case"end":return e.stop()}}),e,null,[[1,12]])})))).apply(this,arguments)}function Ql(){return(Ql=f(S.a.mark((function e(t){var n,r,i,o,a;return S.a.wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return n=t.data,r=t.state,i=t.api,e.prev=1,o=n.subscriptionId,e.next=5,i.member.updateSubscription({subscriptionId:o,cancelAtPeriodEnd:!1});case 5:return e.next=7,i.member.sessionData();case 7:return a=e.sent,"continueSubscription:success",e.abrupt("return",{action:"continueSubscription:success",page:"accountHome",member:a});case 12:return e.prev=12,e.t0=e.catch(1),e.abrupt("return",{action:"continueSubscription:failed",popupNotification:Object(Fr.createPopupNotification)({type:"continueSubscription:failed",autoHide:!1,closeable:!0,state:r,status:"error",message:"Failed to cancel subscription, please try again"})});case 15:case"end":return e.stop()}}),e,null,[[1,12]])})))).apply(this,arguments)}function Vl(){return(Vl=f(S.a.mark((function e(t){var n,r,i;return S.a.wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return n=t.data,r=t.state,i=t.api,e.prev=1,e.next=4,i.member.editBilling(n);case 4:e.next=9;break;case 6:return e.prev=6,e.t0=e.catch(1),e.abrupt("return",{action:"editBilling:failed",popupNotification:Object(Fr.createPopupNotification)({type:"editBilling:failed",autoHide:!1,closeable:!0,state:r,status:"error",message:"Failed to update billing information, please try again"})});case 9:case"end":return e.stop()}}),e,null,[[1,6]])})))).apply(this,arguments)}function Yl(){return(Yl=f(S.a.mark((function e(){return S.a.wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return e.abrupt("return",{popupNotification:null});case 1:case"end":return e.stop()}}),e)})))).apply(this,arguments)}function Kl(){return(Kl=f(S.a.mark((function e(t){var n,r,i,o,a;return S.a.wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return n=t.data,r=t.state,i=n.action,o=n.message,a=void 0===o?"":o,i=i||"showPopupNotification:success",e.abrupt("return",{popupNotification:Object(Fr.createPopupNotification)({type:i,autoHide:!0,closeable:!0,state:r,status:"success",message:a})});case 4:case"end":return e.stop()}}),e)})))).apply(this,arguments)}function Gl(){return(Gl=f(S.a.mark((function e(t){var n,r,i,o,a,l,s;return S.a.wrap((function(e){for(;;)switch(e.prev=e.next){case 0:if(n=t.data,r=t.state,i=t.api,e.prev=1,o=n.newsletters,a=n.enableCommentNotifications,o||void 0!==a){e.next=5;break}return e.abrupt("return",{});case 5:return l={},o&&(l.newsletters=o),void 0!==a&&(l.enableCommentNotifications=a),e.next=10,i.member.update(l);case 10:return s=e.sent,"updateNewsletterPref:success",e.abrupt("return",{action:"updateNewsletterPref:success",member:s});case 15:return e.prev=15,e.t0=e.catch(1),e.abrupt("return",{action:"updateNewsletterPref:failed",popupNotification:Object(Fr.createPopupNotification)({type:"updateNewsletter:failed",autoHide:!0,closeable:!0,state:r,status:"error",message:"Failed to update newsletter settings"})});case 18:case"end":return e.stop()}}),e,null,[[1,15]])})))).apply(this,arguments)}function Jl(){return(Jl=f(S.a.mark((function e(t){var n,r,i,o,a,l;return S.a.wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return n=t.data,r=t.state,i=t.api,e.prev=1,o=n.subscribed,e.next=5,i.member.update({subscribed:o});case 5:if(a=e.sent){e.next=8;break}throw new Error("Failed to update newsletter");case 8:return l="updateNewsletter:success",e.abrupt("return",{action:l,member:a,popupNotification:Object(Fr.createPopupNotification)({type:l,autoHide:!0,closeable:!0,state:r,status:"success",message:"Email newsletter settings updated"})});case 12:return e.prev=12,e.t0=e.catch(1),e.abrupt("return",{action:"updateNewsletter:failed",popupNotification:Object(Fr.createPopupNotification)({type:"updateNewsletter:failed",autoHide:!0,closeable:!0,state:r,status:"error",message:"Failed to update newsletter settings"})});case 15:case"end":return e.stop()}}),e,null,[[1,12]])})))).apply(this,arguments)}function Xl(e){return Zl.apply(this,arguments)}function Zl(){return(Zl=f(S.a.mark((function e(t){var n,r,i,o,a;return S.a.wrap((function(e){for(;;)switch(e.prev=e.next){case 0:if(n=t.data,r=t.state,i=t.api,o=n.email,a=Object(Fr.getMemberEmail)({member:r.member}),o===a){e.next=13;break}return e.prev=4,e.next=7,i.member.updateEmailAddress({email:o});case 7:return e.abrupt("return",{success:!0});case 10:return e.prev=10,e.t0=e.catch(4),e.abrupt("return",{success:!1,error:e.t0});case 13:return e.abrupt("return",null);case 14:case"end":return e.stop()}}),e,null,[[4,10]])})))).apply(this,arguments)}function es(e){return ts.apply(this,arguments)}function ts(){return(ts=f(S.a.mark((function e(t){var n,r,i,o,a;return S.a.wrap((function(e){for(;;)switch(e.prev=e.next){case 0:if(n=t.data,r=t.state,i=t.api,o=n.name,Object(Fr.getMemberName)({member:r.member})===o){e.next=16;break}return e.prev=4,e.next=7,i.member.update({name:o});case 7:if(a=e.sent){e.next=10;break}throw new Error("Failed to update member");case 10:return e.abrupt("return",{member:a,success:!0});case 13:return e.prev=13,e.t0=e.catch(4),e.abrupt("return",{success:!1,error:e.t0});case 16:return e.abrupt("return",null);case 17:case"end":return e.stop()}}),e,null,[[4,13]])})))).apply(this,arguments)}function ns(){return(ns=f(S.a.mark((function e(t){var n,r,i;return S.a.wrap((function(e){for(;;)switch(e.prev=e.next){case 0:if(n=t.state,r=t.api,!n.member){e.next=14;break}return e.prev=2,e.next=5,r.member.sessionData();case 5:if(!(i=e.sent)){e.next=8;break}return e.abrupt("return",{member:i,success:!0});case 8:case 14:return e.abrupt("return",null);case 11:return e.prev=11,e.t0=e.catch(2),e.abrupt("return",{success:!1,error:e.t0});case 15:case"end":return e.stop()}}),e,null,[[2,11]])})))).apply(this,arguments)}function rs(){return(rs=f(S.a.mark((function e(t){var n,r,i,o,a,l,c,u,p,d,f,h,m,g;return S.a.wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return n=t.data,r=t.state,i=t.api,e.next=3,Promise.all([es({data:n,state:r,api:i}),Xl({data:n,state:r,api:i})]);case 3:if(o=e.sent,a=Object(s.a)(o,2),l=a[0],c=a[1],!l||!c){e.next=14;break}if(!c.success){e.next=10;break}return e.abrupt("return",Object(k.a)(Object(k.a)({action:"updateProfile:success"},l.success?{member:l.member}:{}),{},{page:"accountHome",popupNotification:Object(Fr.createPopupNotification)({type:"updateProfile:success",autoHide:!0,closeable:!0,status:"success",state:r,message:"Check your inbox to verify email update"})}));case 10:return u=l.success?"Failed to send verification email":"Failed to update account data",e.abrupt("return",Object(k.a)(Object(k.a)({action:"updateProfile:failed"},l.success?{member:l.member}:{}),{},{popupNotification:Object(Fr.createPopupNotification)({type:"updateProfile:failed",autoHide:!0,closeable:!0,status:"error",message:u,state:r})}));case 14:if(!l){e.next=21;break}return p=l.success?"updateProfile:success":"updateProfile:failed",d=l.success?"success":"error",f=l.success?"Account details updated successfully":"Failed to update account details",e.abrupt("return",Object(k.a)(Object(k.a)(Object(k.a)({action:p},l.success?{member:l.member}:{}),l.success?{page:"accountHome"}:{}),{},{popupNotification:Object(Fr.createPopupNotification)({type:p,autoHide:l.success,closeable:!0,status:d,state:r,message:f})}));case 21:if(!c){e.next=26;break}return h=c.success?"updateProfile:success":"updateProfile:failed",m=c.success?"success":"error",g=c.success?"Check your inbox to verify email update":"Failed to send verification email",e.abrupt("return",Object(k.a)(Object(k.a)({action:h},c.success?{page:"accountHome"}:{}),{},{popupNotification:Object(Fr.createPopupNotification)({type:h,autoHide:c.success,closeable:!0,status:m,state:r,message:g})}));case 26:return e.abrupt("return",{action:"updateProfile:success",page:"accountHome",popupNotification:Object(Fr.createPopupNotification)({type:"updateProfile:success",autoHide:!0,closeable:!0,status:"success",state:r,message:"Account details updated successfully"})});case 27:case"end":return e.stop()}}),e)})))).apply(this,arguments)}var is={togglePopup:function(e){return{showPopup:!e.state.showPopup}},openPopup:function(e){var t=e.data;return Object(k.a)(Object(k.a)({showPopup:!0,page:t.page},t.pageQuery?{pageQuery:t.pageQuery}:{}),t.pageData?{pageData:t.pageData}:{})},closePopup:Ul,switchPage:function(e){var t=e.data,n=e.state;return{page:t.page,popupNotification:null,lastPage:t.lastPage||null,pageData:t.pageData||n.pageData}},openNotification:function(e){var t=e.data;return Object(k.a)({showNotification:!0},t)},closeNotification:function(e){return e.state,{showNotification:!1}},back:function(e){var t=e.state;return t.lastPage?{page:t.lastPage}:Ul({state:t})},signout:function(e){return Al.apply(this,arguments)},signin:function(e){return Bl.apply(this,arguments)},signup:function(e){return Hl.apply(this,arguments)},updateSubscription:function(e){return $l.apply(this,arguments)},cancelSubscription:function(e){return Wl.apply(this,arguments)},continueSubscription:function(e){return Ql.apply(this,arguments)},updateNewsletter:function(e){return Jl.apply(this,arguments)},updateProfile:function(e){return rs.apply(this,arguments)},refreshMemberData:function(e){return ns.apply(this,arguments)},clearPopupNotification:function(){return Yl.apply(this,arguments)},editBilling:function(e){return Vl.apply(this,arguments)},checkoutPlan:function(e){return ql.apply(this,arguments)},updateNewsletterPreference:function(e){return Gl.apply(this,arguments)},showPopupNotification:function(e){return Kl.apply(this,arguments)}};function os(e){return as.apply(this,arguments)}function as(){return(as=f(S.a.mark((function e(t){var n,r,i,o,a;return S.a.wrap((function(e){for(;;)switch(e.prev=e.next){case 0:if(n=t.action,r=t.data,i=t.state,o=t.api,!(a=is[n])){e.next=9;break}return e.next=5,a({data:r,state:i,api:o});case 5:if(e.t0=e.sent,e.t0){e.next=8;break}e.t0={};case 8:return e.abrupt("return",e.t0);case 9:return e.abrupt("return",{});case 10:case"end":return e.stop()}}),e)})))).apply(this,arguments)}n(43);var ls=["site"],ss=["site"],cs=["site"],us=["site"],ps=["site"],ds=["site"],fs=n(45).handleDataAttributes,hs=n(1),ms=Object(k.a)(Object(k.a)({showPopup:!0,site:Dl,member:Rl.free,page:"accountEmail"},function(){var e;if(!Fl||!Fl[1])return null;var t=null===Dl||void 0===Dl||null===(e=Dl.products)||void 0===e?void 0:e[1].monthlyPrice,n=kl({paid:!0,subscriptions:[Tl({offer:null,priceId:null===t||void 0===t?void 0:t.id,status:"active",currency:null===t||void 0===t?void 0:t.currency,interval:null===t||void 0===t?void 0:t.interval,amount:null===t||void 0===t?void 0:t.amount,cardLast4:"4242",startDate:"2021-10-05T03:18:30.000Z",currentPeriodEnd:"2022-10-05T03:18:30.000Z",cancelAtPeriodEnd:!1})]});return{site:Dl,member:n}}()),{},{pageData:zl});function gs(e){var t=e.site,n=e.children,r=(t||{}).portal_sentry;return r&&r.dsn?Object($n.jsx)(Un,{children:n}):Object($n.jsx)($n.Fragment,{children:n})}var bs=function(e){v(n,e);var t=O(n);function n(e){var r;return h(this,n),(r=t.call(this,e)).setupCustomTriggerButton(e),r.state={site:null,member:null,page:"loading",showPopup:!1,action:"init:running",initStatus:"running",lastPage:null,customSiteUrl:e.customSiteUrl},r}return g(n,[{key:"componentDidMount",value:function(){this.initSetup()}},{key:"componentDidUpdate",value:function(e,t){if(t.showPopup!==this.state.showPopup){this.handleCustomTriggerClassUpdate();try{var n,r,i;if(this.state.showPopup)this.bodyScroll=null===(n=window.document)||void 0===n||null===(r=n.body)||void 0===r||null===(i=r.style)||void 0===i?void 0:i.overflow,window.document.body.style.overflow="hidden";else window.document.body.style.overflow=this.bodyScroll||""}catch(l){}}if("success"===this.state.initStatus&&t.initStatus!==this.state.initStatus){var o=this.props.siteUrl,a=this.getContextFromState();this.sendPortalReadyEvent(),fs({siteUrl:o,site:a.site,member:a.member})}}},{key:"componentWillUnmount",value:function(){var e=this;clearTimeout(this.timeoutId),this.customTriggerButtons&&this.customTriggerButtons.forEach((function(t){t.removeEventListener("click",e.clickHandler)})),window.removeEventListener("hashchange",this.hashHandler,!1)}},{key:"sendPortalReadyEvent",value:function(){window.self!==window.parent&&window.parent.postMessage({type:"portal-ready",payload:{}},"*")}},{key:"setupCustomTriggerButton",value:function(){var e=this;this.clickHandler=function(t){t.preventDefault();var n=t.currentTarget,r=n&&n.dataset.portal,i=e.getPageFromLinkPath(r)||{},o=i.page,a=i.pageQuery;"success"===e.state.initStatus&&(a&&"free"!==a?e.handleSignupQuery({site:e.state.site,pageQuery:a}):e.dispatchAction("openPopup",{page:o,pageQuery:a}))};this.customTriggerButtons=document.querySelectorAll("[data-portal]")||[],this.customTriggerButtons.forEach((function(t){t.classList.add("gh-portal-close"),t.removeEventListener("click",e.clickHandler),t.addEventListener("click",e.clickHandler)}))}},{key:"handleCustomTriggerClassUpdate",value:function(){var e,t=this,n="gh-portal-open",r="gh-portal-close";null===(e=this.customTriggerButtons)||void 0===e||e.forEach((function(e){var i=t.state.showPopup?n:r,o=t.state.showPopup?r:n;e.classList.add(i),e.classList.remove(o)}))}},{key:"initSetup",value:function(){var e=f(S.a.mark((function e(){var t,n,r,i,o,a,l,s,c,u,p=this;return S.a.wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return e.prev=0,e.next=3,this.fetchData();case 3:t=e.sent,n=t.site,r=t.member,i=t.page,o=t.showPopup,a=t.popupNotification,l=t.lastPage,s=t.pageQuery,c=t.pageData,u={site:n,member:r,page:i,lastPage:l,pageQuery:s,showPopup:o,pageData:c,popupNotification:a,action:"init:success",initStatus:"success"},this.handleSignupQuery({site:n,pageQuery:s,member:r}),this.setState(u),this.hashHandler=function(){p.updateStateForPreviewLinks()},window.addEventListener("hashchange",this.hashHandler,!1),e.next=23;break;case 19:e.prev=19,e.t0=e.catch(0),console.error("[Portal] Failed to initialize:",e.t0),this.setState({action:"init:failed",initStatus:"failed"});case 23:case"end":return e.stop()}}),e,this,[[0,19]])})));return function(){return e.apply(this,arguments)}}()},{key:"fetchData",value:function(){var e=f(S.a.mark((function e(){var t,n,r,i,o,a,l,s,c,u,d,f,h,m,g;return S.a.wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return e.next=2,this.fetchApiData();case 2:return t=e.sent,n=t.site,r=t.member,i=this.fetchDevData(),o=i.site,a=p(i,ls),l=this.fetchLinkData(),s=l.site,c=p(l,ss),u=this.fetchPreviewData(),d=u.site,f=p(u,cs),h=this.fetchNotificationData(),m=h.site,g=p(h,us),"",e.abrupt("return",Object(k.a)(Object(k.a)(Object(k.a)(Object(k.a)({member:r,page:"",site:Object(k.a)(Object(k.a)(Object(k.a)(Object(k.a)(Object(k.a)(Object(k.a)({},n),s),d),m),o),{},{plans:Object(k.a)(Object(k.a)(Object(k.a)({},(o||{}).plans),(n||{}).plans),(d||{}).plans)})},a),c),g),f));case 11:case"end":return e.stop()}}),e,this)})));return function(){return e.apply(this,arguments)}}()},{key:"fetchDevData",value:function(){return Ur(["dev"])&&!this.state.customSiteUrl?ms:Ur(["test"])?{showPopup:void 0===this.props.showPopup||this.props.showPopup}:{}}},{key:"fetchOfferQueryStrData",value:function(){var e,t=arguments.length>0&&void 0!==arguments[0]?arguments[0]:"",n=new URLSearchParams(t),r={},i=u(n.entries());try{for(i.s();!(e=i.n()).done;){var o=e.value,a=o[0],l=decodeURIComponent(o[1]);"name"===a?r.name=l||"":"code"===a?r.code=l||"":"display_title"===a?r.display_title=l||"":"display_description"===a?r.display_description=l||"":"type"===a?r.type=l||"":"cadence"===a?r.cadence=l||"":"duration"===a?r.duration=l||"":"duration_in_months"!==a||isNaN(Number(l))?"amount"!==a||isNaN(Number(l))?"currency"===a?r.currency=l||"":"status"===a?r.status=l||"":"tier_id"===a&&(r.tier={id:l||zl.tier.id}):r.amount=Number(l):r.duration_in_months=Number(l)}}catch(s){i.e(s)}finally{i.f()}return{page:"offer",pageData:r}}},{key:"fetchQueryStrData",value:function(){var e,t,n,r,i,o=arguments.length>0&&void 0!==arguments[0]?arguments[0]:"",a=new URLSearchParams(o),l={site:{plans:{}}},s=[],c=null,p=u(a.entries());try{for(p.s();!(i=p.n()).done;){var d=i.value,f=d[0],h=decodeURIComponent(d[1]);if("button"===f)l.site.portal_button=JSON.parse(h);else if("name"===f)l.site.portal_name=JSON.parse(h);else if("isFree"===f&&JSON.parse(h))s.push("free");else if("isMonthly"===f&&JSON.parse(h))s.push("monthly");else if("isYearly"===f&&JSON.parse(h))s.push("yearly");else if("portalPrices"===f)e=h?h.split(","):[];else if("portalProducts"===f)c=h?h.split(","):[];else if("page"===f&&h)l.page=h;else if("accentColor"!==f||""!==h&&!h)if("buttonIcon"===f&&h)l.site.portal_button_icon=h;else if("signupButtonText"===f)l.site.portal_button_signup_text=h||"";else if("buttonStyle"===f&&h)l.site.portal_button_style=h;else if("monthlyPrice"!==f||isNaN(Number(h)))if("yearlyPrice"!==f||isNaN(Number(h)))if("currency"===f&&h){var m=h.toUpperCase();l.site.plans.currency=m,l.site.plans.currency_symbol=Object(Fr.getCurrencySymbol)(m),r=m}else"disableBackground"===f?l.site.disableBackground=JSON.parse(h):"allowSelfSignup"===f?l.site.allow_self_signup=JSON.parse(h):"membersSignupAccess"===f&&h&&(l.site.members_signup_access=h);else l.site.plans.yearly=Number(h),n=Number(h);else l.site.plans.monthly=Number(h),t=Number(h);else l.site.accent_color=h}}catch(g){p.e(g)}finally{p.f()}return l.site.portal_plans=s,l.site.portal_products=c,e?l.site.portal_plans=e:t&&n&&r&&(l.site.prices=[{id:"monthly",stripe_price_id:"dummy_stripe_monthly",stripe_product_id:"dummy_stripe_product",active:1,nickname:"Monthly",currency:r,amount:t,type:"recurring",interval:"month"},{id:"yearly",stripe_price_id:"dummy_stripe_yearly",stripe_product_id:"dummy_stripe_product",active:1,nickname:"Yearly",currency:r,amount:n,type:"recurring",interval:"year"}]),l}},{key:"fetchNotificationData",value:function(){var e=mi({billingOnly:!0})||{},t=e.type,n=e.status,r=e.duration,i=e.autoHide,o=e.closeable;return["stripe:billing-update"].includes(t)?"success"===n?{showPopup:!0,popupNotification:Object(Fr.createPopupNotification)({type:t,status:n,duration:r,closeable:o,autoHide:i,state:this.state,message:"success"===n?"Billing info updated successfully":""})}:{showPopup:!0}:{}}},{key:"fetchLinkData",value:function(){var e=new URLSearchParams(window.location.search);if(e.get("uuid")&&"unsubscribe"===e.get("action"))return{showPopup:!0,page:"unsubscribe",pageData:{uuid:e.get("uuid"),newsletterUuid:e.get("newsletter"),comments:e.get("comments")}};var t=window.location.hash.substr(1).split("?"),n=Object(s.a)(t,1)[0],r=/^\/portal\/?(?:\/(\w+(?:\/\w+)*))?\/?$/;if(n&&r.test(n)){var i=n.match(r),o=Object(s.a)(i,2)[1],a=this.getPageFromLinkPath(o)||{},l=a.page,c=a.pageQuery,u=["accountPlan","accountProfile"].includes(l)?"accountHome":null,p=!(["monthly","yearly"].includes(c)||/^(?:(\w+?))?\/monthly$/.test(c)||/^(?:(\w+?))?\/yearly$/.test(c)||/^offers\/(\w+?)\/?$/.test(c));return Object(k.a)(Object(k.a)(Object(k.a)({showPopup:p},l?{page:l}:{}),c?{pageQuery:c}:{}),u?{lastPage:u}:{})}return{}}},{key:"fetchPreviewData",value:function(){var e=window.location.hash.substr(1).split("?"),t=Object(s.a)(e,2)[1];if(Ur(["preview"])){var n={};return n=Ur(["offerPreview"])?this.fetchOfferQueryStrData(t):this.fetchQueryStrData(t),Object(k.a)(Object(k.a)({},n),{},{showPopup:!0})}return{}}},{key:"getColorOverride",value:function(){var e=document.querySelector("script[data-ghost]");return!(!e||!e.dataset.accentColor)&&e.dataset.accentColor}},{key:"fetchApiData",value:function(){var e=f(S.a.mark((function e(){var t,n,r,i,o,a,l,s,c;return S.a.wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return t=this.props,n=t.siteUrl,r=t.customSiteUrl,i=t.apiUrl,o=t.apiKey,e.prev=1,this.GhostApi=this.props.api||el({siteUrl:n,apiUrl:i,apiKey:o}),e.next=5,this.GhostApi.init();case 5:return a=e.sent,l=a.site,s=a.member,(c=this.getColorOverride())&&(l.accent_color=c),this.setupFirstPromoter({site:l,member:s}),this.setupSentry({site:l}),e.abrupt("return",{site:l,member:s});case 15:if(e.prev=15,e.t0=e.catch(1),!Ur(["dev","test"],{customSiteUrl:r})){e.next=19;break}return e.abrupt("return",{});case 19:throw e.t0;case 20:case"end":return e.stop()}}),e,this,[[1,15]])})));return function(){return e.apply(this,arguments)}}()},{key:"setupSentry",value:function(e){var t=e.site;if(Ur(["test"]))return null;var n,r=t.portal_sentry,i=(t.portal_version,t.version),o="portal@".concat("2.10.0","|ghost@").concat(i);r&&r.dsn&&((n={dsn:r.dsn,environment:r.env||"development",release:o,beforeSend:function(e){return Object(Fr.isSentryEventAllowed)({event:e})?e:null},allowUrls:[/https?:\/\/((www)\.)?unpkg\.com\/@tryghost\/portal/]})._metadata=n._metadata||{},n._metadata.sdk=n._metadata.sdk||{name:"sentry.javascript.react",packages:[{name:"npm:@sentry/react",version:ze}],version:ze},Fn(n))}},{key:"setupFirstPromoter",value:function(e){var t=e.site,n=e.member;if(Ur(["test"]))return null;var r=Object(Fr.getFirstpromoterId)({site:t}),i=Object(Fr.getSiteDomain)({site:t});if(r&&i){var o=document.createElement("script");o.type="text/javascript",o.async=!0,o.src="https://cdn.firstpromoter.com/fprom.js",o.onload=o.onreadystatechange=function(){var e=this.readyState;if(!e||"complete"===e||"loaded"===e)try{if(window.$FPROM.init(r,i),n){var t=n.email,o=n.uuid;if(window.$FPROM)window.$FPROM.trackSignup({email:t,uid:o});else{var a=window._fprom||[];window._fprom=a,a.push(["event","signup"]),a.push(["email",t]),a.push(["uid",o])}}}catch(l){}};var a=document.getElementsByTagName("script")[0];a.parentNode.insertBefore(o,a)}}},{key:"dispatchAction",value:function(){var e=f(S.a.mark((function e(t,n){var r,i,o=this;return S.a.wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return clearTimeout(this.timeoutId),this.setState({action:"".concat(t,":running")}),e.prev=2,e.next=5,os({action:t,data:n,state:this.state,api:this.GhostApi});case 5:r=e.sent,this.setState(r),r&&r.action&&!r.action.includes(":failed")&&(this.timeoutId=setTimeout((function(){o.setState({action:""})}),2e3)),e.next=14;break;case 10:e.prev=10,e.t0=e.catch(2),i=Object(Fr.createPopupNotification)({type:"".concat(t,":failed"),autoHide:!0,closeable:!0,status:"error",state:this.state,meta:{error:e.t0}}),this.setState({action:"".concat(t,":failed"),popupNotification:i});case 14:case"end":return e.stop()}}),e,this,[[2,10]])})));return function(t,n){return e.apply(this,arguments)}}()},{key:"updateStateForPreviewLinks",value:function(){var e=this.fetchPreviewData(),t=e.site,n=p(e,ps),r=this.fetchLinkData(),i=r.site,o=p(r,ds),a=Object(k.a)(Object(k.a)({site:Object(k.a)(Object(k.a)(Object(k.a)(Object(k.a)({},this.state.site),i||{}),t||{}),{},{plans:Object(k.a)(Object(k.a)(Object(k.a)({},this.state.site&&this.state.site.plans),(i||{}).plans),(t||{}).plans)})},o),n);this.handleSignupQuery({site:a.site,pageQuery:a.pageQuery}),this.setState(a)}},{key:"handleOfferQuery",value:function(){var e=f(S.a.mark((function e(t){var n,r,i,o,a,l,s,c,u,p,d,f,h,m,g;return S.a.wrap((function(e){for(;;)switch(e.prev=e.next){case 0:if(n=t.site,r=t.offerId,i=t.member,o=void 0===i?this.state.member:i,a=n.portal_button,Object(Fr.removePortalLinkFromUrl)(),Object(Fr.isPaidMember)({member:o})){e.next=14;break}return e.prev=4,e.next=7,this.GhostApi.site.offer({offerId:r});case 7:l=e.sent,s=null===l||void 0===l?void 0:l.offers[0],Object(Fr.isActiveOffer)({offer:s})&&(a?this.dispatchAction("openPopup",{page:"offer",pageData:null===l||void 0===l?void 0:l.offers[0]}):(c=Object(Fr.getProductFromId)({site:n,productId:s.tier.id}),u="month"===s.cadence?c.monthlyPrice:c.yearlyPrice,this.dispatchAction("openPopup",{page:"loading"}),o?(p=Object(Fr.getProductCadenceFromPrice)({site:n,priceId:u.id}),d=p.tierId,f=p.cadence,this.dispatchAction("checkoutPlan",{plan:u.id,offerId:r,tierId:d,cadence:f})):(h=Object(Fr.getProductCadenceFromPrice)({site:n,priceId:u.id}),m=h.tierId,g=h.cadence,this.dispatchAction("signup",{plan:u.id,offerId:r,tierId:m,cadence:g})))),e.next=14;break;case 12:e.prev=12,e.t0=e.catch(4);case 14:case"end":return e.stop()}}),e,this,[[4,12]])})));return function(t){return e.apply(this,arguments)}}()},{key:"handleSignupQuery",value:function(e){var t=e.site,n=e.pageQuery,r=e.member,i=/^offers\/(\w+?)\/?$/,o=n;if(i.test(n||"")){var a=n.match(i),l=Object(s.a)(a,2)[1];this.handleOfferQuery({site:t,offerId:l,member:r})}else{Object(Fr.getPriceIdFromPageQuery)({site:t,pageQuery:n})&&(o=Object(Fr.getPriceIdFromPageQuery)({site:t,pageQuery:n}));var c=Object(Fr.getQueryPrice)({site:t,priceId:o});if(n&&"free"!==n){Object(Fr.removePortalLinkFromUrl)();var u=(null===c||void 0===c?void 0:c.id)||o;"free"!==u&&this.dispatchAction("openPopup",{page:"loading"});var p=Object(Fr.getProductCadenceFromPrice)({site:t,priceId:u}),d=p.tierId,f=p.cadence;this.dispatchAction("signup",{plan:u,tierId:d,cadence:f})}}}},{key:"getPageFromLinkPath",value:function(e){var t=/^signup\/?(?:\/(\w+?))?\/?$/,n=/^signup\/?(?:\/(\w+?))\/monthly\/?$/,r=/^signup\/?(?:\/(\w+?))\/yearly\/?$/;if(/^offers\/(\w+?)\/?$/.test(e))return{pageQuery:e};if("signup"===e)return{page:"signup"};if(n.test(e)){var i=e.match(n),o=Object(s.a)(i,2)[1];return{page:"signup",pageQuery:"".concat(o,"/monthly")}}if(r.test(e)){var a=e.match(r),l=Object(s.a)(a,2)[1];return{page:"signup",pageQuery:"".concat(l,"/yearly")}}if(t.test(e)){var c=e.match(t);return{page:"signup",pageQuery:Object(s.a)(c,2)[1]}}return"signup/free"===e?{page:"signup",pageQuery:"free"}:"signup/monthly"===e?{page:"signup",pageQuery:"monthly"}:"signup/yearly"===e?{page:"signup",pageQuery:"yearly"}:"signin"===e?{page:"signin"}:"account"===e?{page:"accountHome"}:"account/plans"===e?{page:"accountPlan"}:"account/profile"===e?{page:"accountProfile"}:"account/newsletters"===e?{page:"accountEmail"}:{}}},{key:"getAccentColor",value:function(){return(this.state.site||{}).accent_color}},{key:"getContextPage",value:function(e){var t=e.site,n=e.page,r=e.member;if(!n){var i=Object(Fr.isInviteOnlySite)({site:t})?"signin":"signup";n=r?"accountHome":i}return"accountPlan"===n&&Object(Fr.isComplimentaryMember)({member:r})&&!Object(Fr.allowCompMemberUpgrade)({member:r})&&(n="accountHome"),ll({page:n})}},{key:"getContextMember",value:function(e){var t=e.page,n=e.member,r=e.customSiteUrl;return Ur(["dev","preview"],{customSiteUrl:r})?{page:t}.page.includes("account")||{page:t}.page.includes("offer")?Ur(["dev"],{customSiteUrl:r})?n||Rl.free:Ur(["preview"])?Rl.preview:Rl.paid:null:n}},{key:"getContextFromState",value:function(){var e=this,t=this.state,n=t.site,r=t.member,i=t.action,o=t.page,a=t.lastPage,l=t.showPopup,s=t.pageQuery,c=t.pageData,u=t.popupNotification,p=t.customSiteUrl,d=this.getContextPage({site:n,page:o,member:r}),f=this.getContextMember({page:d,member:r,customSiteUrl:p});return{site:n,action:i,brandColor:this.getAccentColor(),page:d,pageQuery:s,pageData:c,member:f,lastPage:a,showPopup:l,popupNotification:u,customSiteUrl:p,onAction:function(t,n){return e.dispatchAction(t,n)}}}},{key:"render",value:function(){return"success"===this.state.initStatus?Object($n.jsx)(gs,{site:this.state.site,children:Object($n.jsxs)(tr.Provider,{value:this.getContextFromState(),children:[Object($n.jsx)(xl,{}),Object($n.jsx)($r,{}),Object($n.jsx)(wi,{})]})}):null}}]),n}(hs.Component);var vs=function(e){var t=e.siteUrl;return function(e){var t=e.analyticsId,n=e.api;t&&n.analytics.pushEvent({type:"entry_view",entry_id:t,entry_url:window.location.href,created_at:new Date})}({analyticsId:e.analyticsId,api:el({siteUrl:t})}),{}},ys="ghost-portal-root";function xs(e){var t=e.siteUrl;!function(){var e=document.createElement("div");e.id=ys,document.body.appendChild(e)}(),function(){var e=new URL(window.location.href);e.searchParams.get("token")&&(e.searchParams.delete("token"),window.history.replaceState({},document.title,e.href))}(),function(e){var t=e.siteUrl,n=document.querySelector("meta[name=ghost-analytics-id]"),r=null===n||void 0===n?void 0:n.content;t&&n&&vs({siteUrl:t,analyticsId:r})}({siteUrl:t})}!function(){var e=function(){var e=document.querySelector("script[data-ghost]");return e?{siteUrl:e.dataset.ghost,apiKey:e.dataset.key,apiUrl:e.dataset.api}:{}}(),t=e.siteUrl,n=e.apiKey,r=e.apiUrl,i=t||window.location.origin;xs({siteUrl:i}),l.a.render(Object($n.jsx)(o.a.StrictMode,{children:Object($n.jsx)(bs,{siteUrl:i,customSiteUrl:t,apiKey:n,apiUrl:r})}),document.getElementById(ys))}()},,,function(e,t,n){"use strict";(function(e){n.d(t,"a",(function(){return s})),n.d(t,"b",(function(){return c}));var r=n(2),i=n(8),o=n(32),a=n(10),l=n(22);function s(e,t,n){void 0===t&&(t=1/0),void 0===n&&(n=1/0);try{return u("",e,t,n)}catch(r){return{ERROR:"**non-serializable** ("+r+")"}}}function c(e,t,n){void 0===t&&(t=3),void 0===n&&(n=102400);var r,i=s(e,t);return r=i,function(e){return~-encodeURI(e).split(/%..|./).length}(JSON.stringify(r))>n?c(e,t-1,n):i}function u(t,n,s,c,p){void 0===s&&(s=1/0),void 0===c&&(c=1/0),void 0===p&&(p=Object(o.a)());var d=Object(r.c)(p,2),f=d[0],h=d[1],m=n;if(m&&"function"===typeof m.toJSON)try{return m.toJSON()}catch(j){}if(null===n||["number","boolean","string"].includes(typeof n)&&!Object(i.h)(n))return n;var g=function(t,n){try{return"domain"===t&&n&&"object"===typeof n&&n._events?"[Domain]":"domainEmitter"===t?"[DomainEmitter]":"undefined"!==typeof e&&n===e?"[Global]":"undefined"!==typeof window&&n===window?"[Window]":"undefined"!==typeof document&&n===document?"[Document]":Object(i.m)(n)?"[SyntheticEvent]":"number"===typeof n&&n!==n?"[NaN]":void 0===n?"[undefined]":"function"===typeof n?"[Function: "+Object(l.b)(n)+"]":"symbol"===typeof n?"["+String(n)+"]":"bigint"===typeof n?"[BigInt: "+String(n)+"]":"[object "+Object.getPrototypeOf(n).constructor.name+"]"}catch(j){return"**non-serializable** ("+j+")"}}(t,n);if(!g.startsWith("[object "))return g;if(0===s)return g.replace("object ","");if(f(n))return"[Circular ~]";var b=Array.isArray(n)?[]:{},v=0,y=Object(i.d)(n)||Object(i.f)(n)?Object(a.b)(n):n;for(var x in y)if(Object.prototype.hasOwnProperty.call(y,x)){if(v>=c){b[x]="[MaxProperties ~]";break}var w=y[x];b[x]=u(x,w,s-1,c,p),v+=1}return h(n),b}}).call(this,n(26))}]);
2
+ !function(e){var t={};function n(r){if(t[r])return t[r].exports;var i=t[r]={i:r,l:!1,exports:{}};return e[r].call(i.exports,i,i.exports,n),i.l=!0,i.exports}n.m=e,n.c=t,n.d=function(e,t,r){n.o(e,t)||Object.defineProperty(e,t,{enumerable:!0,get:r})},n.r=function(e){"undefined"!==typeof Symbol&&Symbol.toStringTag&&Object.defineProperty(e,Symbol.toStringTag,{value:"Module"}),Object.defineProperty(e,"__esModule",{value:!0})},n.t=function(e,t){if(1&t&&(e=n(e)),8&t)return e;if(4&t&&"object"===typeof e&&e&&e.__esModule)return e;var r=Object.create(null);if(n.r(r),Object.defineProperty(r,"default",{enumerable:!0,value:e}),2&t&&"string"!=typeof e)for(var i in e)n.d(r,i,function(t){return e[t]}.bind(null,i));return r},n.n=function(e){var t=e&&e.__esModule?function(){return e.default}:function(){return e};return n.d(t,"a",t),t},n.o=function(e,t){return Object.prototype.hasOwnProperty.call(e,t)},n.p="/",n(n.s=46)}([function(e,t,n){"use strict";e.exports=n(39)},function(e,t,n){"use strict";e.exports=n(33)},function(e,t,n){"use strict";n.d(t,"b",(function(){return i})),n.d(t,"a",(function(){return o})),n.d(t,"e",(function(){return a})),n.d(t,"c",(function(){return l})),n.d(t,"d",(function(){return s}));var r=function(e,t){return r=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(e,t){e.__proto__=t}||function(e,t){for(var n in t)t.hasOwnProperty(n)&&(e[n]=t[n])},r(e,t)};function i(e,t){function n(){this.constructor=e}r(e,t),e.prototype=null===t?Object.create(t):(n.prototype=t.prototype,new n)}var o=function(){return o=Object.assign||function(e){for(var t,n=1,r=arguments.length;n<r;n++)for(var i in t=arguments[n])Object.prototype.hasOwnProperty.call(t,i)&&(e[i]=t[i]);return e},o.apply(this,arguments)};function a(e){var t="function"===typeof Symbol&&Symbol.iterator,n=t&&e[t],r=0;if(n)return n.call(e);if(e&&"number"===typeof e.length)return{next:function(){return e&&r>=e.length&&(e=void 0),{value:e&&e[r++],done:!e}}};throw new TypeError(t?"Object is not iterable.":"Symbol.iterator is not defined.")}function l(e,t){var n="function"===typeof Symbol&&e[Symbol.iterator];if(!n)return e;var r,i,o=n.call(e),a=[];try{for(;(void 0===t||t-- >0)&&!(r=o.next()).done;)a.push(r.value)}catch(l){i={error:l}}finally{try{r&&!r.done&&(n=o.return)&&n.call(o)}finally{if(i)throw i.error}}return a}function s(){for(var e=[],t=0;t<arguments.length;t++)e=e.concat(l(arguments[t]));return e}},function(e,t,n){"use strict";n.r(t),n.d(t,"removePortalLinkFromUrl",(function(){return a})),n.d(t,"getPortalLinkPath",(function(){return l})),n.d(t,"getPortalLink",(function(){return s})),n.d(t,"isCookiesDisabled",(function(){return c})),n.d(t,"isSentryEventAllowed",(function(){return u})),n.d(t,"getMemberSubscription",(function(){return p})),n.d(t,"isComplimentaryMember",(function(){return d})),n.d(t,"isPaidMember",(function(){return f})),n.d(t,"getProductCurrency",(function(){return h})),n.d(t,"getNewsletterFromUuid",(function(){return m})),n.d(t,"allowCompMemberUpgrade",(function(){return g})),n.d(t,"getCompExpiry",(function(){return b})),n.d(t,"getUpgradeProducts",(function(){return v})),n.d(t,"getFilteredPrices",(function(){return y})),n.d(t,"getPriceFromSubscription",(function(){return x})),n.d(t,"getMemberActivePrice",(function(){return w})),n.d(t,"isMemberActivePrice",(function(){return j})),n.d(t,"getSubscriptionFromId",(function(){return O})),n.d(t,"getMemberTierName",(function(){return k})),n.d(t,"hasOnlyFreePlan",(function(){return _})),n.d(t,"hasPrice",(function(){return S})),n.d(t,"getQueryPrice",(function(){return P})),n.d(t,"capitalize",(function(){return E})),n.d(t,"isInviteOnlySite",(function(){return C})),n.d(t,"hasMultipleProducts",(function(){return N})),n.d(t,"hasMultipleProductsFeature",(function(){return T})),n.d(t,"hasCommentsEnabled",(function(){return I})),n.d(t,"transformApiSiteData",(function(){return L})),n.d(t,"getAvailableProducts",(function(){return M})),n.d(t,"getFreeProduct",(function(){return F})),n.d(t,"getAllProductsForSite",(function(){return D})),n.d(t,"hasBenefits",(function(){return z})),n.d(t,"getSiteProducts",(function(){return R})),n.d(t,"hasFreeTrialTier",(function(){return U})),n.d(t,"getFreeProductBenefits",(function(){return A})),n.d(t,"getFreeTierTitle",(function(){return B})),n.d(t,"getFreeTierDescription",(function(){return H})),n.d(t,"freeHasBenefitsOrDescription",(function(){return q})),n.d(t,"getProductBenefits",(function(){return $})),n.d(t,"getProductFromId",(function(){return W})),n.d(t,"getPricesFromProducts",(function(){return Q})),n.d(t,"hasFreeProductPrice",(function(){return V})),n.d(t,"getSiteNewsletters",(function(){return Y})),n.d(t,"hasMultipleNewsletters",(function(){return K})),n.d(t,"hasOnlyFreeProduct",(function(){return G})),n.d(t,"getSubFreeTrialDaysLeft",(function(){return J})),n.d(t,"subscriptionHasFreeTrial",(function(){return X})),n.d(t,"getProductFromPrice",(function(){return ee})),n.d(t,"getProductCadenceFromPrice",(function(){return te})),n.d(t,"getAvailablePrices",(function(){return ne})),n.d(t,"getFreePriceCurrency",(function(){return re})),n.d(t,"getSitePrices",(function(){return ie})),n.d(t,"getMemberEmail",(function(){return oe})),n.d(t,"getFirstpromoterId",(function(){return ae})),n.d(t,"getMemberName",(function(){return le})),n.d(t,"getSupportAddress",(function(){return se})),n.d(t,"getSiteDomain",(function(){return ce})),n.d(t,"getCurrencySymbol",(function(){return ue})),n.d(t,"getStripeAmount",(function(){return pe})),n.d(t,"getPriceString",(function(){return de})),n.d(t,"formatNumber",(function(){return fe})),n.d(t,"createPopupNotification",(function(){return he})),n.d(t,"isSameCurrency",(function(){return me})),n.d(t,"getPriceIdFromPageQuery",(function(){return ge})),n.d(t,"getOfferOffAmount",(function(){return be})),n.d(t,"getUpdatedOfferPrice",(function(){return ve})),n.d(t,"isActiveOffer",(function(){return ye})),n.d(t,"transformApiTiersData",(function(){return xe})),n.d(t,"getUrlHistory",(function(){return we}));var r=n(4),i=n(5),o=n(10);function a(){var e=window.location.hash.substr(1).split("?"),t=Object(i.a)(e,1)[0];t&&/^\/portal\/?(?:\/(\w+(?:\/\w+)*))?\/?$/.test(t)&&window.history.pushState("",document.title,window.location.pathname+window.location.search)}function l(e){var t=e.page,n={signin:"#/portal/signin",signup:"#/portal/signup"};return Object.keys(n).includes(t)?n[t]:n.default}function s(e){var t=e.page,n=e.siteUrl||"".concat(window.location.protocol,"//").concat(window.location.host).concat(window.location.pathname),r=l({page:t});return"".concat(n).concat(r)}function c(){return!(navigator&&navigator.cookieEnabled)}function u(e){var t,n,r,i,o=e.event,a=((null===o||void 0===o||null===(t=o.exception)||void 0===t||null===(n=t.values)||void 0===n||null===(r=n[0])||void 0===r||null===(i=r.stacktrace)||void 0===i?void 0:i.frames)||[]).map((function(e){return e.filename})).filter((function(e){return!!e}));return(a[a.length-1]||"").includes("@tryghost/portal")}function p(e){var t=e.member,n=void 0===t?{}:t;if(f({member:n})){var r=(n.subscriptions||[]).find((function(e){return["active","trialing","unpaid","past_due"].includes(e.status)}));return null!==r&&void 0!==r&&r.price||null===r||void 0===r||!r.plan||(r.price=r.plan),r}return null}function d(e){var t=e.member,n=void 0===t?{}:t;if(!n)return!1;var r=p({member:n});if(r){var i=r.price;return i&&0===i.amount}return!(r||!n.paid)}function f(e){var t=e.member,n=void 0===t?{}:t;return n&&n.paid}function h(e){var t=e.product;return null!==t&&void 0!==t&&t.monthlyPrice?t.monthlyPrice.currency:null}function m(e){var t=e.site,n=e.uuid;if(!n)return null;var r=Y({site:t});return null===r||void 0===r?void 0:r.find((function(e){return e.uuid=n}))}function g(e){var t,n,r,i=e.member;return void 0!==(null===i||void 0===i||null===(t=i.subscriptions)||void 0===t||null===(n=t[0])||void 0===n||null===(r=n.tier)||void 0===r?void 0:r.expiry_at)}function b(e){var t,n,r,i=e.member;return null!==i&&void 0!==i&&null!==(t=i.subscriptions)&&void 0!==t&&null!==(n=t[0])&&void 0!==n&&null!==(r=n.tier)&&void 0!==r&&r.expiry_at?Object(o.a)(i.subscriptions[0].tier.expiry_at):""}function v(e){var t=e.site,n=w({member:e.member}),r=null===n||void 0===n?void 0:n.currency,i=M({site:t});return null!==n&&void 0!==n&&n.id?i.filter((function(e){return h({product:e})===r})):i}function y(e){var t=e.prices,n=e.currency;return t.filter((function(e){return(e.currency||"").toLowerCase()===(n||"").toLowerCase()}))}function x(e){var t,n,i=e.subscription;return i&&i.price?Object(r.a)(Object(r.a)({},i.price),{},{stripe_price_id:i.price.id,id:i.price.price_id,price:i.price.amount/100,name:i.price.nickname,tierId:null===(t=i.tier)||void 0===t?void 0:t.id,cadence:"month"===(null===(n=i.price)||void 0===n?void 0:n.interval)?"month":"year",currency:i.price.currency.toLowerCase(),currency_symbol:ue(i.price.currency)}):null}function w(e){return x({subscription:p({member:e.member})})}function j(e){var t=e.priceId,n=e.site,r=w({member:e.member}),i=te({site:n,priceId:t}),o=i.tierId,a=i.cadence;return(null===r||void 0===r?void 0:r.tierId)===o&&(null===r||void 0===r?void 0:r.cadence)===a}function O(e){var t=e.member,n=e.subscriptionId;return f({member:t})?(t.subscriptions||[]).find((function(e){return e.id===n})):null}function k(e){var t,n=p({member:e.member});return(null===n||void 0===n||null===(t=n.tier)||void 0===t?void 0:t.name)||""}function _(e){var t=e.plans,n=e.site;return!(t=t||ie({site:void 0===n?{}:n}))||0===t.length||1===t.length&&"free"===t[0].type}function S(e){var t=e.site,n=void 0===t?{}:t,r=e.plan,i=ie({site:n});return"free"===r?!i||0===i.length||i.find((function(e){return"free"===e.type})):"monthly"===r?i&&i.length>0&&i.find((function(e){return"Monthly"===e.name})):"yearly"===r?i&&i.length>0&&i.find((function(e){return"Yearly"===e.name})):!!r&&(i&&i.length>0&&i.find((function(e){return e.id===r})))}function P(e){var t=e.site,n=void 0===t?{}:t,r=e.priceId,i=ne({site:n});if("free"===r)return!i||0===i.length||i.find((function(e){return"free"===e.type}));if(i&&i.length>0&&"monthly"===r){var o=i.find((function(e){return"Monthly"===e.name})),a=i.find((function(e){return"month"===e.interval}));return o||a}if(i&&i.length>0&&"yearly"===r){var l=i.find((function(e){return"Yearly"===e.name})),s=i.find((function(e){return"year"===e.interval}));return l||s}return i&&i.length>0&&r?i.find((function(e){return e.id===r})):null}function E(e){return"string"===typeof e&&e?e.charAt(0).toUpperCase()+e.slice(1):""}function C(e){var t=e.site,n=void 0===t?{}:t,r=e.pageQuery;return 0===ie({site:n,pageQuery:void 0===r?"":r}).length||n&&"invite"===n.members_signup_access}function N(e){var t=M({site:e.site});return(null===t||void 0===t?void 0:t.length)>1}function T(e){return!!(e.site||{}).portal_products}function I(e){var t=e.site;return(null===t||void 0===t?void 0:t.comments_enabled)&&"off"!==(null===t||void 0===t?void 0:t.comments_enabled)}function L(e){var t,n,i,o=e.site;if(!o)return null;if(o.tiers&&(o.products=o.tiers),o.products=null===(t=o.products)||void 0===t?void 0:t.map((function(e){return Object(r.a)(Object(r.a)({},e),{},{monthlyPrice:e.monthly_price,yearlyPrice:e.yearly_price})})),o.is_stripe_configured=!!o.paid_members_enabled,o.members_signup_access="all",o.members_enabled||(o.members_signup_access="none"),o.members_invite_only&&(o.members_signup_access="invite"),o.allow_self_signup=!1,"all"!==o.members_signup_access&&(o.allow_self_signup=!1),o.paid_members_enabled&&(o.allow_self_signup=!0),o.portal_plans.includes("free")&&(o.allow_self_signup=!0),null!==(n=o.products)&&void 0!==n&&null!==(i=n[0])&&void 0!==i&&i.visibility){o.portal_products=o.products.filter((function(e){return"none"!==e.visibility&&"paid"===e.type})).map((function(e){return e.id}));var a,l,s=o.products.find((function(e){return"free"===e.type}));if(s)if(o.portal_plans=null===(a=o.portal_plans)||void 0===a?void 0:a.filter((function(e){return"free"!==e})),"public"===(null===s||void 0===s?void 0:s.visibility))null===(l=o.portal_plans)||void 0===l||l.push("free")}return o}function M(e){var t=e.site||{},n=t.portal_products,i=t.products,o=void 0===i?[]:i,a=t.portal_plans,l=void 0===a?[]:a;return l.includes("monthly")||l.includes("yearly")?o.filter((function(e){return!!e})).filter((function(e){return!(!e.monthlyPrice||!e.yearlyPrice)})).filter((function(e){return!!(Object.keys(e.monthlyPrice).length>0&&Object.keys(e.yearlyPrice).length>0)})).filter((function(e){return!(n&&o.length>1)||n.includes(e.id)})).sort((function(e,t){var n,r;return(null===e||void 0===e||null===(n=e.monthlyPrice)||void 0===n?void 0:n.amount)-(null===t||void 0===t||null===(r=t.monthlyPrice)||void 0===r?void 0:r.amount)})).map((function(e){return e.monthlyPrice=Object(r.a)(Object(r.a)({},e.monthlyPrice),{},{currency_symbol:ue(e.monthlyPrice.currency)}),e.yearlyPrice=Object(r.a)(Object(r.a)({},e.yearlyPrice),{},{currency_symbol:ue(e.yearlyPrice.currency)}),e})):[]}function F(e){var t=(e.site||{}).products;return(void 0===t?[]:t).find((function(e){return"free"===e.type}))}function D(e){var t=e.site||{},n=t.products,i=void 0===n?[]:n,o=t.portal_plans,a=void 0===o?[]:o;return a.includes("monthly")||a.includes("yearly")?i.filter((function(e){return!!e})).filter((function(e){return!(!e.monthlyPrice||!e.yearlyPrice)})).filter((function(e){return!!(Object.keys(e.monthlyPrice).length>0&&Object.keys(e.yearlyPrice).length>0)})).sort((function(e,t){var n,r;return(null===e||void 0===e||null===(n=e.monthlyPrice)||void 0===n?void 0:n.amount)-(null===t||void 0===t||null===(r=t.monthlyPrice)||void 0===r?void 0:r.amount)})).map((function(e){return e.monthlyPrice=Object(r.a)(Object(r.a)({},e.monthlyPrice),{},{currency_symbol:ue(e.monthlyPrice.currency)}),e.yearlyPrice=Object(r.a)(Object(r.a)({},e.yearlyPrice),{},{currency_symbol:ue(e.yearlyPrice.currency)}),e})):[]}function z(e){var t=e.prices;return!!T({site:e.site})&&(!(null===t||void 0===t||!t.length)&&t.some((function(e){var t;return null===e||void 0===e||null===(t=e.benefits)||void 0===t?void 0:t.length})))}function R(e){var t=e.site,n=e.pageQuery,r=M({site:t});return"free"===n&&V({site:t})?[]:(V({site:t})&&r.unshift({id:"free"}),r)}function U(e){return R({site:e.site}).some((function(e){return!(null===e||void 0===e||!e.trial_days)}))}function A(e){var t=F({site:e.site});return(null===t||void 0===t?void 0:t.benefits)||[]}function B(e){return G({site:e.site})?"Free membership":"Free"}function H(e){var t=F({site:e.site});return null===t||void 0===t?void 0:t.description}function q(e){var t,n=F({site:e.site});return!!(null!==n&&void 0!==n&&n.description||null!==n&&void 0!==n&&null!==(t=n.benefits)&&void 0!==t&&t.length)}function $(e){var t=e.product;e.site;if(null!==t&&void 0!==t&&t.monthlyPrice&&null!==t&&void 0!==t&&t.yearlyPrice){var n=(null===t||void 0===t?void 0:t.benefits)||[];return{monthly:n,yearly:n}}}function W(e){var t=e.site,n=e.productId;return D({site:t}).find((function(e){return e.id===n}))}function Q(e){var t=e.site,n=void 0===t?null:t,r=e.products,i=void 0===r?null:r;return n||i?(i||M({site:n})).reduce((function(e,t){return t.monthlyPrice&&t.yearlyPrice&&(e.push(t.monthlyPrice),e.push(t.yearlyPrice)),e}),[]):[]}function V(e){var t=e.site||{},n=t.allow_self_signup,r=t.portal_plans;return n&&r.includes("free")}function Y(e){var t=(e.site||{}).newsletters,n=void 0===t?[]:t;return null===n||void 0===n||n.sort((function(e,t){return e.sort_order-t.sort_order})),n}function K(e){var t=(e.site||{}).newsletters;return(null===t||void 0===t?void 0:t.length)>1}function G(e){var t=e.site;return 1===R({site:t}).length&&V({site:t})}function J(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{},t=e.sub;if(!X({sub:t}))return 0;var n=(new Date).setHours(0,0,0,0),r=new Date(t.trial_end_at).setHours(0,0,0,0),i=864e5;return Math.ceil((r-n)/i)}function X(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{},t=e.sub;return!(null===t||void 0===t||!t.trial_end_at||Z(new Date(null===t||void 0===t?void 0:t.trial_end_at)))}function Z(e){var t=new Date;return t.setHours(0,0,0,0),e<t}function ee(e){var t=e.site,n=e.priceId;return"free"===n?F({site:t}):D({site:t}).find((function(e){var t,r;return(null===e||void 0===e||null===(t=e.monthlyPrice)||void 0===t?void 0:t.id)===n||(null===e||void 0===e||null===(r=e.yearlyPrice)||void 0===r?void 0:r.id)===n}))}function te(e){var t,n=e.site,r=e.priceId;if("free"===r)return F({site:n});var i=D({site:n}).find((function(e){var t,n;return(null===e||void 0===e||null===(t=e.monthlyPrice)||void 0===t?void 0:t.id)===r||(null===e||void 0===e||null===(n=e.yearlyPrice)||void 0===n?void 0:n.id)===r})),o="month";return(null===i||void 0===i||null===(t=i.yearlyPrice)||void 0===t?void 0:t.id)===r&&(o="year"),{tierId:null===i||void 0===i?void 0:i.id,cadence:o}}function ne(e){var t=e.site,n=e.products,i=void 0===n?null:n,o=t||{},a=o.portal_plans,l=void 0===a?[]:a;return o.is_stripe_configured?Q({site:t,products:i}).filter((function(e){return!(!e||!e.id)})).map((function(e){return Object(r.a)(Object(r.a)({},e),{},{price_id:e.id,price:e.amount/100,name:e.nickname,currency_symbol:ue(e.currency)})})).filter((function(e){return 0!==e.amount&&"recurring"===e.type})).filter((function(e){return"month"===e.interval?l.includes("monthly"):"year"===e.interval&&l.includes("yearly")})).sort((function(e,t){return e.amount-t.amount})).sort((function(e,t){return e.currency&&t.currency?e.currency.localeCompare(t.currency,void 0,{ignorePunctuation:!0}):0})):[]}function re(e){var t=ne({site:e.site}),n={currency:"usd",currency_symbol:"$"};return(null===t||void 0===t?void 0:t.length)>0&&(n.currency=t[0].currency,n.currency_symbol=t[0].currency_symbol),n}function ie(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{},t=e.site,n=void 0===t?{}:t,i=e.pageQuery,o=void 0===i?"":i,a=n||{},l=a.allow_self_signup,s=a.portal_plans,c=[];if(l&&s.includes("free")){var u=re({site:n});c.push(Object(r.a)({id:"free",type:"free",price:0,amount:0,name:B({site:n})},u))}var p="free"===o&&V({site:n});if(!p){var d=ne({site:n});d.forEach((function(e){c.push(e)}))}return c}var oe=function(e){var t=e.member;return t?t.email:""},ae=function(e){var t=e.site;return t&&t.firstpromoter_account},le=function(e){var t=e.member;return t?t.name:""},se=function(e){var t,n=e.site,r=(n||{}).members_support_address;if((null===r||void 0===r?void 0:r.indexOf("@"))<0){var o=ce({site:n}),a=(null===o||void 0===o?void 0:o.replace(/^(www)\.(?=[^/]*\..{2,5})/,""))||"";return"".concat(r,"@").concat(a)}if((null===r||void 0===r||null===(t=r.split("@"))||void 0===t?void 0:t.length)>1){var l=null===r||void 0===r?void 0:r.split("@"),s=Object(i.a)(l,2),c=s[0],u=s[1],p=(null===u||void 0===u?void 0:u.replace(/^(www)\.(?=[^/]*\..{2,5})/,""))||"";return"".concat(c,"@").concat(p)}return r||""},ce=function(e){var t=e.site;try{return new URL(t.url).origin.replace(/^http(s?):\/\//,"").replace(/\/$/,"")}catch(n){return t.url.replace(/^http(s?):\/\//,"").replace(/\/$/,"")}},ue=function(e){return Intl.NumberFormat("en",{currency:e,style:"currency"}).format(0).replace(/[\d\s.]/g,"")},pe=function(e){return isNaN(e)?0:e/100},de=function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{},t=ue(e.currency),n=pe(e.amount);return"".concat(t).concat(n,"/").concat(e.interval)},fe=function(e){return void 0===e||null===e?"":e.toLocaleString()},he=function(e){var t=e.type,n=e.status,r=e.autoHide,i=e.duration,o=void 0===i?2600:i,a=e.closeable,l=e.state,s=e.message,c=e.meta,u=void 0===c?{}:c,p=0;return l&&l.popupNotification&&(p=(l.popupNotification.count||0)+1),{type:t,status:n,autoHide:r,closeable:a,duration:o,meta:u,message:s,count:p}};function me(e,t){return(null===e||void 0===e?void 0:e.toLowerCase())===(null===t||void 0===t?void 0:t.toLowerCase())}function ge(e){var t=e.site,n=e.pageQuery,r=/^(?:(\S+?))?\/monthly$/,o=/^(?:(\S+?))?\/yearly$/;if(r.test(n||"")){var a,l=n.match(r),s=W({site:t,productId:Object(i.a)(l,2)[1]});return null===s||void 0===s||null===(a=s.monthlyPrice)||void 0===a?void 0:a.id}if(o.test(n||"")){var c,u=n.match(o),p=W({site:t,productId:Object(i.a)(u,2)[1]});return null===p||void 0===p||null===(c=p.yearlyPrice)||void 0===c?void 0:c.id}return null}var be=function(e){var t=e.offer;return"fixed"===t.type?"".concat(ue(t.currency)).concat(t.amount/100):"percent"===t.type?"".concat(t.amount,"%"):""},ve=function(e){var t,n=e.offer,r=e.price,i=e.useFormatted,o=void 0!==i&&i,a=r.amount;return t="fixed"===n.type&&me(n.currency,r.currency)?(t=(a-n.amount)/100)>0?t:0:"percent"===n.type?(a-a*n.amount/100)/100:a/100,o?Intl.NumberFormat("en",{currency:null===r||void 0===r?void 0:r.currency,style:"currency"}).format(t):t},ye=function(e){var t=e.offer;return"active"===(null===t||void 0===t?void 0:t.status)};var xe=function(e){var t=e.tiers,n=0;return t.map((function(e){var t=function(e){var t=e.tier,n=e.priceId;return null!==t&&void 0!==t&&t.monthly_price?{id:"price-".concat(n),active:!0,type:"recurring",nickname:"Monthly",currency:t.currency,amount:t.monthly_price,interval:"month"}:null}({tier:e,priceId:n}),i=function(e){var t=e.tier,n=e.priceId;return null!==t&&void 0!==t&&t.yearly_price?{id:"price-".concat(n),active:!0,type:"recurring",nickname:"Yearly",currency:t.currency,amount:t.yearly_price,interval:"year"}:null}({tier:e,priceId:n+=1});n+=1;var o=function(e){var t,n=e.tier;return null===n||void 0===n||null===(t=n.benefits)||void 0===t?void 0:t.map((function(e){return{name:e}}))}({tier:e});return Object(r.a)(Object(r.a)({},e),{},{benefits:o,monthly_price:t,yearly_price:i})}))};function we(){try{var e=localStorage.getItem("ghost-history");if(e){var t=JSON.parse(e);if(Array.isArray(t))return t}}catch(n){console.warn("[Portal] Failed to load member URL history:",n)}}},function(e,t,n){"use strict";n.d(t,"a",(function(){return o}));var r=n(11);function i(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),n.push.apply(n,r)}return n}function o(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?i(Object(n),!0).forEach((function(t){Object(r.a)(e,t,n[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):i(Object(n)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))}))}return e}},function(e,t,n){"use strict";n.d(t,"a",(function(){return i}));var r=n(13);function i(e,t){return function(e){if(Array.isArray(e))return e}(e)||function(e,t){var n=null==e?null:"undefined"!==typeof Symbol&&e[Symbol.iterator]||e["@@iterator"];if(null!=n){var r,i,o=[],a=!0,l=!1;try{for(n=n.call(e);!(a=(r=n.next()).done)&&(o.push(r.value),!t||o.length!==t);a=!0);}catch(s){l=!0,i=s}finally{try{a||null==n.return||n.return()}finally{if(l)throw i}}return o}}(e,t)||Object(r.a)(e,t)||function(){throw new TypeError("Invalid attempt to destructure non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}()}},,function(e,t,n){"use strict";n.d(t,"d",(function(){return i})),n.d(t,"e",(function(){return a})),n.d(t,"a",(function(){return l})),n.d(t,"b",(function(){return s})),n.d(t,"l",(function(){return c})),n.d(t,"j",(function(){return u})),n.d(t,"i",(function(){return p})),n.d(t,"f",(function(){return d})),n.d(t,"c",(function(){return f})),n.d(t,"k",(function(){return h})),n.d(t,"n",(function(){return m})),n.d(t,"m",(function(){return g})),n.d(t,"h",(function(){return b})),n.d(t,"g",(function(){return v}));var r=Object.prototype.toString;function i(e){switch(r.call(e)){case"[object Error]":case"[object Exception]":case"[object DOMException]":return!0;default:return v(e,Error)}}function o(e,t){return r.call(e)==="[object "+t+"]"}function a(e){return o(e,"ErrorEvent")}function l(e){return o(e,"DOMError")}function s(e){return o(e,"DOMException")}function c(e){return o(e,"String")}function u(e){return null===e||"object"!==typeof e&&"function"!==typeof e}function p(e){return o(e,"Object")}function d(e){return"undefined"!==typeof Event&&v(e,Event)}function f(e){return"undefined"!==typeof Element&&v(e,Element)}function h(e){return o(e,"RegExp")}function m(e){return Boolean(e&&e.then&&"function"===typeof e.then)}function g(e){return p(e)&&"nativeEvent"in e&&"preventDefault"in e&&"stopPropagation"in e}function b(e){return"number"===typeof e&&e!==e}function v(e,t){try{return e instanceof t}catch(n){return!1}}},function(e,t,n){"use strict";(function(e){n.d(t,"a",(function(){return o})),n.d(t,"b",(function(){return a}));var r=n(16),i={};function o(){return Object(r.b)()?e:"undefined"!==typeof window?window:"undefined"!==typeof self?self:i}function a(e,t,n){var r=n||o(),i=r.__SENTRY__=r.__SENTRY__||{};return i[e]||(i[e]=t())}}).call(this,n(25))},function(e,t,n){"use strict";n.d(t,"e",(function(){return l})),n.d(t,"a",(function(){return s})),n.d(t,"g",(function(){return c})),n.d(t,"f",(function(){return u})),n.d(t,"h",(function(){return p})),n.d(t,"b",(function(){return d})),n.d(t,"d",(function(){return m})),n.d(t,"c",(function(){return g}));var r=n(2),i=n(29),o=n(7),a=n(12);function l(e,t,n){if(t in e){var r=e[t],i=n(r);if("function"===typeof i)try{c(i,r)}catch(o){}e[t]=i}}function s(e,t,n){Object.defineProperty(e,t,{value:n,writable:!0,configurable:!0})}function c(e,t){var n=t.prototype||{};e.prototype=t.prototype=n,s(e,"__sentry_original__",t)}function u(e){return e.__sentry_original__}function p(e){return Object.keys(e).map((function(t){return encodeURIComponent(t)+"="+encodeURIComponent(e[t])})).join("&")}function d(e){var t=e;if(Object(o.d)(e))t=Object(r.a)({message:e.message,name:e.name,stack:e.stack},h(e));else if(Object(o.f)(e)){var n=e;t=Object(r.a)({type:n.type,target:f(n.target),currentTarget:f(n.currentTarget)},h(n)),"undefined"!==typeof CustomEvent&&Object(o.g)(e,CustomEvent)&&(t.detail=n.detail)}return t}function f(e){try{return Object(o.c)(e)?Object(i.b)(e):Object.prototype.toString.call(e)}catch(t){return"<unknown>"}}function h(e){var t={};for(var n in e)Object.prototype.hasOwnProperty.call(e,n)&&(t[n]=e[n]);return t}function m(e,t){void 0===t&&(t=40);var n=Object.keys(d(e));if(n.sort(),!n.length)return"[object has no keys]";if(n[0].length>=t)return Object(a.d)(n[0],t);for(var r=n.length;r>0;r--){var i=n.slice(0,r).join(", ");if(!(i.length>t))return r===n.length?i:Object(a.d)(i,t)}return""}function g(e){var t,n;if(Object(o.i)(e)){var i={};try{for(var a=Object(r.e)(Object.keys(e)),l=a.next();!l.done;l=a.next()){var s=l.value;"undefined"!==typeof e[s]&&(i[s]=g(e[s]))}}catch(c){t={error:c}}finally{try{l&&!l.done&&(n=a.return)&&n.call(a)}finally{if(t)throw t.error}}return i}return Array.isArray(e)?e.map(g):e}},function(e,t,n){"use strict";n.d(t,"a",(function(){return r}));var r=function(e){if(!e)return"";return new Date(e).toLocaleDateString("en-GB",{year:"numeric",month:"short",day:"numeric"})}},function(e,t,n){"use strict";function r(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}n.d(t,"a",(function(){return r}))},function(e,t,n){"use strict";n.d(t,"d",(function(){return i})),n.d(t,"c",(function(){return o})),n.d(t,"b",(function(){return a})),n.d(t,"a",(function(){return l}));var r=n(7);function i(e,t){return void 0===t&&(t=0),"string"!==typeof e||0===t||e.length<=t?e:e.substr(0,t)+"..."}function o(e,t){var n=e,r=n.length;if(r<=150)return n;t>r&&(t=r);var i=Math.max(t-60,0);i<5&&(i=0);var o=Math.min(i+140,r);return o>r-5&&(o=r),o===r&&(i=Math.max(o-140,0)),n=n.slice(i,o),i>0&&(n="'{snip} "+n),o<r&&(n+=" {snip}"),n}function a(e,t){if(!Array.isArray(e))return"";for(var n=[],r=0;r<e.length;r++){var i=e[r];try{n.push(String(i))}catch(o){n.push("[value cannot be serialized]")}}return n.join(t)}function l(e,t){return!!Object(r.l)(e)&&(Object(r.k)(t)?t.test(e):"string"===typeof t&&-1!==e.indexOf(t))}},function(e,t,n){"use strict";n.d(t,"a",(function(){return i}));var r=n(15);function i(e,t){if(e){if("string"===typeof e)return Object(r.a)(e,t);var n=Object.prototype.toString.call(e).slice(8,-1);return"Object"===n&&e.constructor&&(n=e.constructor.name),"Map"===n||"Set"===n?Array.from(e):"Arguments"===n||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n)?Object(r.a)(e,t):void 0}}},function(e,t,n){"use strict";!function e(){if("undefined"!==typeof __REACT_DEVTOOLS_GLOBAL_HOOK__&&"function"===typeof __REACT_DEVTOOLS_GLOBAL_HOOK__.checkDCE)try{__REACT_DEVTOOLS_GLOBAL_HOOK__.checkDCE(e)}catch(t){console.error(t)}}(),e.exports=n(34)},function(e,t,n){"use strict";function r(e,t){(null==t||t>e.length)&&(t=e.length);for(var n=0,r=new Array(t);n<t;n++)r[n]=e[n];return r}n.d(t,"a",(function(){return r}))},function(e,t,n){"use strict";(function(e,r){n.d(t,"b",(function(){return o})),n.d(t,"a",(function(){return a}));var i=n(28);function o(){return!Object(i.a)()&&"[object process]"===Object.prototype.toString.call("undefined"!==typeof e?e:0)}function a(e,t){return e.require(t)}}).call(this,n(45),n(24)(e))},,,function(e,t,n){"use strict";e.exports=function(e){var t=[];return t.toString=function(){return this.map((function(t){var n=function(e,t){var n=e[1]||"",r=e[3];if(!r)return n;if(t&&"function"===typeof btoa){var i=function(e){var t=btoa(unescape(encodeURIComponent(JSON.stringify(e)))),n="sourceMappingURL=data:application/json;charset=utf-8;base64,".concat(t);return"/*# ".concat(n," */")}(r),o=r.sources.map((function(e){return"/*# sourceURL=".concat(r.sourceRoot||"").concat(e," */")}));return[n].concat(o).concat([i]).join("\n")}return[n].join("\n")}(t,e);return t[2]?"@media ".concat(t[2]," {").concat(n,"}"):n})).join("")},t.i=function(e,n,r){"string"===typeof e&&(e=[[null,e,""]]);var i={};if(r)for(var o=0;o<this.length;o++){var a=this[o][0];null!=a&&(i[a]=!0)}for(var l=0;l<e.length;l++){var s=[].concat(e[l]);r&&i[s[0]]||(n&&(s[2]?s[2]="".concat(n," and ").concat(s[2]):s[2]=n),t.push(s))}},t}},function(e,t){e.exports=function(e,t){if(isNaN(e)||isNaN(t))return 0;var n=e?100-Math.floor(t/12*100/e):0;return n>=1&&n<100?n:0}},function(e,t,n){"use strict";n.d(t,"a",(function(){return i})),n.d(t,"b",(function(){return l}));var r=n(2);function i(){for(var e=[],t=0;t<arguments.length;t++)e[t]=arguments[t];var n=e.sort((function(e,t){return e[0]-t[0]})).map((function(e){return e[1]}));return function(e,t){var i,a,l,s;void 0===t&&(t=0);var c=[];try{for(var u=Object(r.e)(e.split("\n").slice(t)),p=u.next();!p.done;p=u.next()){var d=p.value;try{for(var f=(l=void 0,Object(r.e)(n)),h=f.next();!h.done;h=f.next()){var m=(0,h.value)(d);if(m){c.push(m);break}}}catch(g){l={error:g}}finally{try{h&&!h.done&&(s=f.return)&&s.call(f)}finally{if(l)throw l.error}}}}catch(b){i={error:b}}finally{try{p&&!p.done&&(a=u.return)&&a.call(u)}finally{if(i)throw i.error}}return o(c)}}function o(e){if(!e.length)return[];var t=e,n=t[0].function||"",i=t[t.length-1].function||"";return-1===n.indexOf("captureMessage")&&-1===n.indexOf("captureException")||(t=t.slice(1)),-1!==i.indexOf("sentryWrapped")&&(t=t.slice(0,-1)),t.slice(0,50).map((function(e){return Object(r.a)(Object(r.a)({},e),{filename:e.filename||t[0].filename,function:e.function||"?"})})).reverse()}var a="<anonymous>";function l(e){try{return e&&"function"===typeof e&&e.name||a}catch(t){return a}}},function(e,t,n){"use strict";var r=Object.getOwnPropertySymbols,i=Object.prototype.hasOwnProperty,o=Object.prototype.propertyIsEnumerable;function a(e){if(null===e||void 0===e)throw new TypeError("Object.assign cannot be called with null or undefined");return Object(e)}e.exports=function(){try{if(!Object.assign)return!1;var e=new String("abc");if(e[5]="de","5"===Object.getOwnPropertyNames(e)[0])return!1;for(var t={},n=0;n<10;n++)t["_"+String.fromCharCode(n)]=n;if("0123456789"!==Object.getOwnPropertyNames(t).map((function(e){return t[e]})).join(""))return!1;var r={};return"abcdefghijklmnopqrst".split("").forEach((function(e){r[e]=e})),"abcdefghijklmnopqrst"===Object.keys(Object.assign({},r)).join("")}catch(i){return!1}}()?Object.assign:function(e,t){for(var n,l,s=a(e),c=1;c<arguments.length;c++){for(var u in n=Object(arguments[c]))i.call(n,u)&&(s[u]=n[u]);if(r){l=r(n);for(var p=0;p<l.length;p++)o.call(n,l[p])&&(s[l[p]]=n[l[p]])}}return s}},function(e,t,n){"use strict";var r=function(){var e;return function(){return"undefined"===typeof e&&(e=Boolean(window&&document&&document.all&&!window.atob)),e}}(),i=function(){var e={};return function(t){if("undefined"===typeof e[t]){var n=document.querySelector(t);if(window.HTMLIFrameElement&&n instanceof window.HTMLIFrameElement)try{n=n.contentDocument.head}catch(r){n=null}e[t]=n}return e[t]}}(),o=[];function a(e){for(var t=-1,n=0;n<o.length;n++)if(o[n].identifier===e){t=n;break}return t}function l(e,t){for(var n={},r=[],i=0;i<e.length;i++){var l=e[i],s=t.base?l[0]+t.base:l[0],c=n[s]||0,u="".concat(s," ").concat(c);n[s]=c+1;var p=a(u),d={css:l[1],media:l[2],sourceMap:l[3]};-1!==p?(o[p].references++,o[p].updater(d)):o.push({identifier:u,updater:h(d,t),references:1}),r.push(u)}return r}function s(e){var t=document.createElement("style"),r=e.attributes||{};if("undefined"===typeof r.nonce){var o=n.nc;o&&(r.nonce=o)}if(Object.keys(r).forEach((function(e){t.setAttribute(e,r[e])})),"function"===typeof e.insert)e.insert(t);else{var a=i(e.insert||"head");if(!a)throw new Error("Couldn't find a style target. This probably means that the value for the 'insert' parameter is invalid.");a.appendChild(t)}return t}var c=function(){var e=[];return function(t,n){return e[t]=n,e.filter(Boolean).join("\n")}}();function u(e,t,n,r){var i=n?"":r.media?"@media ".concat(r.media," {").concat(r.css,"}"):r.css;if(e.styleSheet)e.styleSheet.cssText=c(t,i);else{var o=document.createTextNode(i),a=e.childNodes;a[t]&&e.removeChild(a[t]),a.length?e.insertBefore(o,a[t]):e.appendChild(o)}}function p(e,t,n){var r=n.css,i=n.media,o=n.sourceMap;if(i?e.setAttribute("media",i):e.removeAttribute("media"),o&&"undefined"!==typeof btoa&&(r+="\n/*# sourceMappingURL=data:application/json;base64,".concat(btoa(unescape(encodeURIComponent(JSON.stringify(o))))," */")),e.styleSheet)e.styleSheet.cssText=r;else{for(;e.firstChild;)e.removeChild(e.firstChild);e.appendChild(document.createTextNode(r))}}var d=null,f=0;function h(e,t){var n,r,i;if(t.singleton){var o=f++;n=d||(d=s(t)),r=u.bind(null,n,o,!1),i=u.bind(null,n,o,!0)}else n=s(t),r=p.bind(null,n,t),i=function(){!function(e){if(null===e.parentNode)return!1;e.parentNode.removeChild(e)}(n)};return r(e),function(t){if(t){if(t.css===e.css&&t.media===e.media&&t.sourceMap===e.sourceMap)return;r(e=t)}else i()}}e.exports=function(e,t){(t=t||{}).singleton||"boolean"===typeof t.singleton||(t.singleton=r());var n=l(e=e||[],t);return function(e){if(e=e||[],"[object Array]"===Object.prototype.toString.call(e)){for(var r=0;r<n.length;r++){var i=a(n[r]);o[i].references--}for(var s=l(e,t),c=0;c<n.length;c++){var u=a(n[c]);0===o[u].references&&(o[u].updater(),o.splice(u,1))}n=s}}}},function(e,t){e.exports=function(e){if(!e.webpackPolyfill){var t=Object.create(e);t.children||(t.children=[]),Object.defineProperty(t,"loaded",{enumerable:!0,get:function(){return t.l}}),Object.defineProperty(t,"id",{enumerable:!0,get:function(){return t.i}}),Object.defineProperty(t,"exports",{enumerable:!0}),t.webpackPolyfill=1}return t}},function(e,t){var n;n=function(){return this}();try{n=n||new Function("return this")()}catch(r){"object"===typeof window&&(n=window)}e.exports=n},function(e,t,n){"use strict";var r=n(43),i={childContextTypes:!0,contextType:!0,contextTypes:!0,defaultProps:!0,displayName:!0,getDefaultProps:!0,getDerivedStateFromError:!0,getDerivedStateFromProps:!0,mixins:!0,propTypes:!0,type:!0},o={name:!0,length:!0,prototype:!0,caller:!0,callee:!0,arguments:!0,arity:!0},a={$$typeof:!0,compare:!0,defaultProps:!0,displayName:!0,propTypes:!0,type:!0},l={};function s(e){return r.isMemo(e)?a:l[e.$$typeof]||i}l[r.ForwardRef]={$$typeof:!0,render:!0,defaultProps:!0,displayName:!0,propTypes:!0},l[r.Memo]=a;var c=Object.defineProperty,u=Object.getOwnPropertyNames,p=Object.getOwnPropertySymbols,d=Object.getOwnPropertyDescriptor,f=Object.getPrototypeOf,h=Object.prototype;e.exports=function e(t,n,r){if("string"!==typeof n){if(h){var i=f(n);i&&i!==h&&e(t,i,r)}var a=u(n);p&&(a=a.concat(p(n)));for(var l=s(t),m=s(n),g=0;g<a.length;++g){var b=a[g];if(!o[b]&&(!r||!r[b])&&(!m||!m[b])&&(!l||!l[b])){var v=d(n,b);try{c(t,b,v)}catch(y){}}}}return t}},function(e,t,n){"use strict";(function(e){n.d(t,"a",(function(){return s})),n.d(t,"b",(function(){return c}));var r=n(8),i=n(16),o={nowSeconds:function(){return Date.now()/1e3}};var a=Object(i.b)()?function(){try{return Object(i.a)(e,"perf_hooks").performance}catch(t){return}}():function(){var e=Object(r.a)().performance;if(e&&e.now)return{now:function(){return e.now()},timeOrigin:Date.now()-e.now()}}(),l=void 0===a?o:{nowSeconds:function(){return(a.timeOrigin+a.now())/1e3}},s=o.nowSeconds.bind(o),c=l.nowSeconds.bind(l);!function(){var e=Object(r.a)().performance;if(e&&e.now){var t=36e5,n=e.now(),i=Date.now(),o=e.timeOrigin?Math.abs(e.timeOrigin+n-i):t,a=o<t,l=e.timing&&e.timing.navigationStart,s="number"===typeof l?Math.abs(l+n-i):t;return a||s<t?o<=s?("timeOrigin",e.timeOrigin):("navigationStart",l):("dateNow",i)}"none"}()}).call(this,n(24)(e))},function(e,t,n){"use strict";function r(){return"undefined"!==typeof __SENTRY_BROWSER_BUNDLE__&&!!__SENTRY_BROWSER_BUNDLE__}n.d(t,"a",(function(){return r}))},function(e,t,n){"use strict";n.d(t,"b",(function(){return o})),n.d(t,"a",(function(){return l}));var r=n(8),i=n(7);function o(e,t){try{for(var n=e,r=[],i=0,o=0,l=" > ".length,s=void 0;n&&i++<5&&!("html"===(s=a(n,t))||i>1&&o+r.length*l+s.length>=80);)r.push(s),o+=s.length,n=n.parentNode;return r.reverse().join(" > ")}catch(c){return"<unknown>"}}function a(e,t){var n,r,o,a,l,s=e,c=[];if(!s||!s.tagName)return"";c.push(s.tagName.toLowerCase());var u=t&&t.length?t.filter((function(e){return s.getAttribute(e)})).map((function(e){return[e,s.getAttribute(e)]})):null;if(u&&u.length)u.forEach((function(e){c.push("["+e[0]+'="'+e[1]+'"]')}));else if(s.id&&c.push("#"+s.id),(n=s.className)&&Object(i.l)(n))for(r=n.split(/\s+/),l=0;l<r.length;l++)c.push("."+r[l]);var p=["type","name","title","alt"];for(l=0;l<p.length;l++)o=p[l],(a=s.getAttribute(o))&&c.push("["+o+'="'+a+'"]');return c.join("")}function l(){var e=Object(r.a)();try{return e.document.location.href}catch(t){return""}}},function(e,t,n){"use strict";function r(){var e="function"===typeof WeakSet,t=e?new WeakSet:[];return[function(n){if(e)return!!t.has(n)||(t.add(n),!1);for(var r=0;r<t.length;r++){if(t[r]===n)return!0}return t.push(n),!1},function(n){if(e)t.delete(n);else for(var r=0;r<t.length;r++)if(t[r]===n){t.splice(r,1);break}}]}n.d(t,"a",(function(){return r}))},,,function(e,t,n){"use strict";var r=n(22),i=60103,o=60106;t.Fragment=60107,t.StrictMode=60108,t.Profiler=60114;var a=60109,l=60110,s=60112;t.Suspense=60113;var c=60115,u=60116;if("function"===typeof Symbol&&Symbol.for){var p=Symbol.for;i=p("react.element"),o=p("react.portal"),t.Fragment=p("react.fragment"),t.StrictMode=p("react.strict_mode"),t.Profiler=p("react.profiler"),a=p("react.provider"),l=p("react.context"),s=p("react.forward_ref"),t.Suspense=p("react.suspense"),c=p("react.memo"),u=p("react.lazy")}var d="function"===typeof Symbol&&Symbol.iterator;function f(e){for(var t="https://reactjs.org/docs/error-decoder.html?invariant="+e,n=1;n<arguments.length;n++)t+="&args[]="+encodeURIComponent(arguments[n]);return"Minified React error #"+e+"; visit "+t+" for the full message or use the non-minified dev environment for full errors and additional helpful warnings."}var h={isMounted:function(){return!1},enqueueForceUpdate:function(){},enqueueReplaceState:function(){},enqueueSetState:function(){}},m={};function g(e,t,n){this.props=e,this.context=t,this.refs=m,this.updater=n||h}function b(){}function v(e,t,n){this.props=e,this.context=t,this.refs=m,this.updater=n||h}g.prototype.isReactComponent={},g.prototype.setState=function(e,t){if("object"!==typeof e&&"function"!==typeof e&&null!=e)throw Error(f(85));this.updater.enqueueSetState(this,e,t,"setState")},g.prototype.forceUpdate=function(e){this.updater.enqueueForceUpdate(this,e,"forceUpdate")},b.prototype=g.prototype;var y=v.prototype=new b;y.constructor=v,r(y,g.prototype),y.isPureReactComponent=!0;var x={current:null},w=Object.prototype.hasOwnProperty,j={key:!0,ref:!0,__self:!0,__source:!0};function O(e,t,n){var r,o={},a=null,l=null;if(null!=t)for(r in void 0!==t.ref&&(l=t.ref),void 0!==t.key&&(a=""+t.key),t)w.call(t,r)&&!j.hasOwnProperty(r)&&(o[r]=t[r]);var s=arguments.length-2;if(1===s)o.children=n;else if(1<s){for(var c=Array(s),u=0;u<s;u++)c[u]=arguments[u+2];o.children=c}if(e&&e.defaultProps)for(r in s=e.defaultProps)void 0===o[r]&&(o[r]=s[r]);return{$$typeof:i,type:e,key:a,ref:l,props:o,_owner:x.current}}function k(e){return"object"===typeof e&&null!==e&&e.$$typeof===i}var _=/\/+/g;function S(e,t){return"object"===typeof e&&null!==e&&null!=e.key?function(e){var t={"=":"=0",":":"=2"};return"$"+e.replace(/[=:]/g,(function(e){return t[e]}))}(""+e.key):t.toString(36)}function P(e,t,n,r,a){var l=typeof e;"undefined"!==l&&"boolean"!==l||(e=null);var s=!1;if(null===e)s=!0;else switch(l){case"string":case"number":s=!0;break;case"object":switch(e.$$typeof){case i:case o:s=!0}}if(s)return a=a(s=e),e=""===r?"."+S(s,0):r,Array.isArray(a)?(n="",null!=e&&(n=e.replace(_,"$&/")+"/"),P(a,t,n,"",(function(e){return e}))):null!=a&&(k(a)&&(a=function(e,t){return{$$typeof:i,type:e.type,key:t,ref:e.ref,props:e.props,_owner:e._owner}}(a,n+(!a.key||s&&s.key===a.key?"":(""+a.key).replace(_,"$&/")+"/")+e)),t.push(a)),1;if(s=0,r=""===r?".":r+":",Array.isArray(e))for(var c=0;c<e.length;c++){var u=r+S(l=e[c],c);s+=P(l,t,n,u,a)}else if(u=function(e){return null===e||"object"!==typeof e?null:"function"===typeof(e=d&&e[d]||e["@@iterator"])?e:null}(e),"function"===typeof u)for(e=u.call(e),c=0;!(l=e.next()).done;)s+=P(l=l.value,t,n,u=r+S(l,c++),a);else if("object"===l)throw t=""+e,Error(f(31,"[object Object]"===t?"object with keys {"+Object.keys(e).join(", ")+"}":t));return s}function E(e,t,n){if(null==e)return e;var r=[],i=0;return P(e,r,"","",(function(e){return t.call(n,e,i++)})),r}function C(e){if(-1===e._status){var t=e._result;t=t(),e._status=0,e._result=t,t.then((function(t){0===e._status&&(t=t.default,e._status=1,e._result=t)}),(function(t){0===e._status&&(e._status=2,e._result=t)}))}if(1===e._status)return e._result;throw e._result}var N={current:null};function T(){var e=N.current;if(null===e)throw Error(f(321));return e}var I={ReactCurrentDispatcher:N,ReactCurrentBatchConfig:{transition:0},ReactCurrentOwner:x,IsSomeRendererActing:{current:!1},assign:r};t.Children={map:E,forEach:function(e,t,n){E(e,(function(){t.apply(this,arguments)}),n)},count:function(e){var t=0;return E(e,(function(){t++})),t},toArray:function(e){return E(e,(function(e){return e}))||[]},only:function(e){if(!k(e))throw Error(f(143));return e}},t.Component=g,t.PureComponent=v,t.__SECRET_INTERNALS_DO_NOT_USE_OR_YOU_WILL_BE_FIRED=I,t.cloneElement=function(e,t,n){if(null===e||void 0===e)throw Error(f(267,e));var o=r({},e.props),a=e.key,l=e.ref,s=e._owner;if(null!=t){if(void 0!==t.ref&&(l=t.ref,s=x.current),void 0!==t.key&&(a=""+t.key),e.type&&e.type.defaultProps)var c=e.type.defaultProps;for(u in t)w.call(t,u)&&!j.hasOwnProperty(u)&&(o[u]=void 0===t[u]&&void 0!==c?c[u]:t[u])}var u=arguments.length-2;if(1===u)o.children=n;else if(1<u){c=Array(u);for(var p=0;p<u;p++)c[p]=arguments[p+2];o.children=c}return{$$typeof:i,type:e.type,key:a,ref:l,props:o,_owner:s}},t.createContext=function(e,t){return void 0===t&&(t=null),(e={$$typeof:l,_calculateChangedBits:t,_currentValue:e,_currentValue2:e,_threadCount:0,Provider:null,Consumer:null}).Provider={$$typeof:a,_context:e},e.Consumer=e},t.createElement=O,t.createFactory=function(e){var t=O.bind(null,e);return t.type=e,t},t.createRef=function(){return{current:null}},t.forwardRef=function(e){return{$$typeof:s,render:e}},t.isValidElement=k,t.lazy=function(e){return{$$typeof:u,_payload:{_status:-1,_result:e},_init:C}},t.memo=function(e,t){return{$$typeof:c,type:e,compare:void 0===t?null:t}},t.useCallback=function(e,t){return T().useCallback(e,t)},t.useContext=function(e,t){return T().useContext(e,t)},t.useDebugValue=function(){},t.useEffect=function(e,t){return T().useEffect(e,t)},t.useImperativeHandle=function(e,t,n){return T().useImperativeHandle(e,t,n)},t.useLayoutEffect=function(e,t){return T().useLayoutEffect(e,t)},t.useMemo=function(e,t){return T().useMemo(e,t)},t.useReducer=function(e,t,n){return T().useReducer(e,t,n)},t.useRef=function(e){return T().useRef(e)},t.useState=function(e){return T().useState(e)},t.version="17.0.2"},function(e,t,n){"use strict";var r=n(1),i=n(22),o=n(35);function a(e){for(var t="https://reactjs.org/docs/error-decoder.html?invariant="+e,n=1;n<arguments.length;n++)t+="&args[]="+encodeURIComponent(arguments[n]);return"Minified React error #"+e+"; visit "+t+" for the full message or use the non-minified dev environment for full errors and additional helpful warnings."}if(!r)throw Error(a(227));var l=new Set,s={};function c(e,t){u(e,t),u(e+"Capture",t)}function u(e,t){for(s[e]=t,e=0;e<t.length;e++)l.add(t[e])}var p=!("undefined"===typeof window||"undefined"===typeof window.document||"undefined"===typeof window.document.createElement),d=/^[:A-Z_a-z\u00C0-\u00D6\u00D8-\u00F6\u00F8-\u02FF\u0370-\u037D\u037F-\u1FFF\u200C-\u200D\u2070-\u218F\u2C00-\u2FEF\u3001-\uD7FF\uF900-\uFDCF\uFDF0-\uFFFD][:A-Z_a-z\u00C0-\u00D6\u00D8-\u00F6\u00F8-\u02FF\u0370-\u037D\u037F-\u1FFF\u200C-\u200D\u2070-\u218F\u2C00-\u2FEF\u3001-\uD7FF\uF900-\uFDCF\uFDF0-\uFFFD\-.0-9\u00B7\u0300-\u036F\u203F-\u2040]*$/,f=Object.prototype.hasOwnProperty,h={},m={};function g(e,t,n,r,i,o,a){this.acceptsBooleans=2===t||3===t||4===t,this.attributeName=r,this.attributeNamespace=i,this.mustUseProperty=n,this.propertyName=e,this.type=t,this.sanitizeURL=o,this.removeEmptyString=a}var b={};"children dangerouslySetInnerHTML defaultValue defaultChecked innerHTML suppressContentEditableWarning suppressHydrationWarning style".split(" ").forEach((function(e){b[e]=new g(e,0,!1,e,null,!1,!1)})),[["acceptCharset","accept-charset"],["className","class"],["htmlFor","for"],["httpEquiv","http-equiv"]].forEach((function(e){var t=e[0];b[t]=new g(t,1,!1,e[1],null,!1,!1)})),["contentEditable","draggable","spellCheck","value"].forEach((function(e){b[e]=new g(e,2,!1,e.toLowerCase(),null,!1,!1)})),["autoReverse","externalResourcesRequired","focusable","preserveAlpha"].forEach((function(e){b[e]=new g(e,2,!1,e,null,!1,!1)})),"allowFullScreen async autoFocus autoPlay controls default defer disabled disablePictureInPicture disableRemotePlayback formNoValidate hidden loop noModule noValidate open playsInline readOnly required reversed scoped seamless itemScope".split(" ").forEach((function(e){b[e]=new g(e,3,!1,e.toLowerCase(),null,!1,!1)})),["checked","multiple","muted","selected"].forEach((function(e){b[e]=new g(e,3,!0,e,null,!1,!1)})),["capture","download"].forEach((function(e){b[e]=new g(e,4,!1,e,null,!1,!1)})),["cols","rows","size","span"].forEach((function(e){b[e]=new g(e,6,!1,e,null,!1,!1)})),["rowSpan","start"].forEach((function(e){b[e]=new g(e,5,!1,e.toLowerCase(),null,!1,!1)}));var v=/[\-:]([a-z])/g;function y(e){return e[1].toUpperCase()}function x(e,t,n,r){var i=b.hasOwnProperty(t)?b[t]:null;(null!==i?0===i.type:!r&&(2<t.length&&("o"===t[0]||"O"===t[0])&&("n"===t[1]||"N"===t[1])))||(function(e,t,n,r){if(null===t||"undefined"===typeof t||function(e,t,n,r){if(null!==n&&0===n.type)return!1;switch(typeof t){case"function":case"symbol":return!0;case"boolean":return!r&&(null!==n?!n.acceptsBooleans:"data-"!==(e=e.toLowerCase().slice(0,5))&&"aria-"!==e);default:return!1}}(e,t,n,r))return!0;if(r)return!1;if(null!==n)switch(n.type){case 3:return!t;case 4:return!1===t;case 5:return isNaN(t);case 6:return isNaN(t)||1>t}return!1}(t,n,i,r)&&(n=null),r||null===i?function(e){return!!f.call(m,e)||!f.call(h,e)&&(d.test(e)?m[e]=!0:(h[e]=!0,!1))}(t)&&(null===n?e.removeAttribute(t):e.setAttribute(t,""+n)):i.mustUseProperty?e[i.propertyName]=null===n?3!==i.type&&"":n:(t=i.attributeName,r=i.attributeNamespace,null===n?e.removeAttribute(t):(n=3===(i=i.type)||4===i&&!0===n?"":""+n,r?e.setAttributeNS(r,t,n):e.setAttribute(t,n))))}"accent-height alignment-baseline arabic-form baseline-shift cap-height clip-path clip-rule color-interpolation color-interpolation-filters color-profile color-rendering dominant-baseline enable-background fill-opacity fill-rule flood-color flood-opacity font-family font-size font-size-adjust font-stretch font-style font-variant font-weight glyph-name glyph-orientation-horizontal glyph-orientation-vertical horiz-adv-x horiz-origin-x image-rendering letter-spacing lighting-color marker-end marker-mid marker-start overline-position overline-thickness paint-order panose-1 pointer-events rendering-intent shape-rendering stop-color stop-opacity strikethrough-position strikethrough-thickness stroke-dasharray stroke-dashoffset stroke-linecap stroke-linejoin stroke-miterlimit stroke-opacity stroke-width text-anchor text-decoration text-rendering underline-position underline-thickness unicode-bidi unicode-range units-per-em v-alphabetic v-hanging v-ideographic v-mathematical vector-effect vert-adv-y vert-origin-x vert-origin-y word-spacing writing-mode xmlns:xlink x-height".split(" ").forEach((function(e){var t=e.replace(v,y);b[t]=new g(t,1,!1,e,null,!1,!1)})),"xlink:actuate xlink:arcrole xlink:role xlink:show xlink:title xlink:type".split(" ").forEach((function(e){var t=e.replace(v,y);b[t]=new g(t,1,!1,e,"http://www.w3.org/1999/xlink",!1,!1)})),["xml:base","xml:lang","xml:space"].forEach((function(e){var t=e.replace(v,y);b[t]=new g(t,1,!1,e,"http://www.w3.org/XML/1998/namespace",!1,!1)})),["tabIndex","crossOrigin"].forEach((function(e){b[e]=new g(e,1,!1,e.toLowerCase(),null,!1,!1)})),b.xlinkHref=new g("xlinkHref",1,!1,"xlink:href","http://www.w3.org/1999/xlink",!0,!1),["src","href","action","formAction"].forEach((function(e){b[e]=new g(e,1,!1,e.toLowerCase(),null,!0,!0)}));var w=r.__SECRET_INTERNALS_DO_NOT_USE_OR_YOU_WILL_BE_FIRED,j=60103,O=60106,k=60107,_=60108,S=60114,P=60109,E=60110,C=60112,N=60113,T=60120,I=60115,L=60116,M=60121,F=60128,D=60129,z=60130,R=60131;if("function"===typeof Symbol&&Symbol.for){var U=Symbol.for;j=U("react.element"),O=U("react.portal"),k=U("react.fragment"),_=U("react.strict_mode"),S=U("react.profiler"),P=U("react.provider"),E=U("react.context"),C=U("react.forward_ref"),N=U("react.suspense"),T=U("react.suspense_list"),I=U("react.memo"),L=U("react.lazy"),M=U("react.block"),U("react.scope"),F=U("react.opaque.id"),D=U("react.debug_trace_mode"),z=U("react.offscreen"),R=U("react.legacy_hidden")}var A,B="function"===typeof Symbol&&Symbol.iterator;function H(e){return null===e||"object"!==typeof e?null:"function"===typeof(e=B&&e[B]||e["@@iterator"])?e:null}function q(e){if(void 0===A)try{throw Error()}catch(n){var t=n.stack.trim().match(/\n( *(at )?)/);A=t&&t[1]||""}return"\n"+A+e}var $=!1;function W(e,t){if(!e||$)return"";$=!0;var n=Error.prepareStackTrace;Error.prepareStackTrace=void 0;try{if(t)if(t=function(){throw Error()},Object.defineProperty(t.prototype,"props",{set:function(){throw Error()}}),"object"===typeof Reflect&&Reflect.construct){try{Reflect.construct(t,[])}catch(s){var r=s}Reflect.construct(e,[],t)}else{try{t.call()}catch(s){r=s}e.call(t.prototype)}else{try{throw Error()}catch(s){r=s}e()}}catch(s){if(s&&r&&"string"===typeof s.stack){for(var i=s.stack.split("\n"),o=r.stack.split("\n"),a=i.length-1,l=o.length-1;1<=a&&0<=l&&i[a]!==o[l];)l--;for(;1<=a&&0<=l;a--,l--)if(i[a]!==o[l]){if(1!==a||1!==l)do{if(a--,0>--l||i[a]!==o[l])return"\n"+i[a].replace(" at new "," at ")}while(1<=a&&0<=l);break}}}finally{$=!1,Error.prepareStackTrace=n}return(e=e?e.displayName||e.name:"")?q(e):""}function Q(e){switch(e.tag){case 5:return q(e.type);case 16:return q("Lazy");case 13:return q("Suspense");case 19:return q("SuspenseList");case 0:case 2:case 15:return e=W(e.type,!1);case 11:return e=W(e.type.render,!1);case 22:return e=W(e.type._render,!1);case 1:return e=W(e.type,!0);default:return""}}function V(e){if(null==e)return null;if("function"===typeof e)return e.displayName||e.name||null;if("string"===typeof e)return e;switch(e){case k:return"Fragment";case O:return"Portal";case S:return"Profiler";case _:return"StrictMode";case N:return"Suspense";case T:return"SuspenseList"}if("object"===typeof e)switch(e.$$typeof){case E:return(e.displayName||"Context")+".Consumer";case P:return(e._context.displayName||"Context")+".Provider";case C:var t=e.render;return t=t.displayName||t.name||"",e.displayName||(""!==t?"ForwardRef("+t+")":"ForwardRef");case I:return V(e.type);case M:return V(e._render);case L:t=e._payload,e=e._init;try{return V(e(t))}catch(n){}}return null}function Y(e){switch(typeof e){case"boolean":case"number":case"object":case"string":case"undefined":return e;default:return""}}function K(e){var t=e.type;return(e=e.nodeName)&&"input"===e.toLowerCase()&&("checkbox"===t||"radio"===t)}function G(e){e._valueTracker||(e._valueTracker=function(e){var t=K(e)?"checked":"value",n=Object.getOwnPropertyDescriptor(e.constructor.prototype,t),r=""+e[t];if(!e.hasOwnProperty(t)&&"undefined"!==typeof n&&"function"===typeof n.get&&"function"===typeof n.set){var i=n.get,o=n.set;return Object.defineProperty(e,t,{configurable:!0,get:function(){return i.call(this)},set:function(e){r=""+e,o.call(this,e)}}),Object.defineProperty(e,t,{enumerable:n.enumerable}),{getValue:function(){return r},setValue:function(e){r=""+e},stopTracking:function(){e._valueTracker=null,delete e[t]}}}}(e))}function J(e){if(!e)return!1;var t=e._valueTracker;if(!t)return!0;var n=t.getValue(),r="";return e&&(r=K(e)?e.checked?"true":"false":e.value),(e=r)!==n&&(t.setValue(e),!0)}function X(e){if("undefined"===typeof(e=e||("undefined"!==typeof document?document:void 0)))return null;try{return e.activeElement||e.body}catch(t){return e.body}}function Z(e,t){var n=t.checked;return i({},t,{defaultChecked:void 0,defaultValue:void 0,value:void 0,checked:null!=n?n:e._wrapperState.initialChecked})}function ee(e,t){var n=null==t.defaultValue?"":t.defaultValue,r=null!=t.checked?t.checked:t.defaultChecked;n=Y(null!=t.value?t.value:n),e._wrapperState={initialChecked:r,initialValue:n,controlled:"checkbox"===t.type||"radio"===t.type?null!=t.checked:null!=t.value}}function te(e,t){null!=(t=t.checked)&&x(e,"checked",t,!1)}function ne(e,t){te(e,t);var n=Y(t.value),r=t.type;if(null!=n)"number"===r?(0===n&&""===e.value||e.value!=n)&&(e.value=""+n):e.value!==""+n&&(e.value=""+n);else if("submit"===r||"reset"===r)return void e.removeAttribute("value");t.hasOwnProperty("value")?ie(e,t.type,n):t.hasOwnProperty("defaultValue")&&ie(e,t.type,Y(t.defaultValue)),null==t.checked&&null!=t.defaultChecked&&(e.defaultChecked=!!t.defaultChecked)}function re(e,t,n){if(t.hasOwnProperty("value")||t.hasOwnProperty("defaultValue")){var r=t.type;if(!("submit"!==r&&"reset"!==r||void 0!==t.value&&null!==t.value))return;t=""+e._wrapperState.initialValue,n||t===e.value||(e.value=t),e.defaultValue=t}""!==(n=e.name)&&(e.name=""),e.defaultChecked=!!e._wrapperState.initialChecked,""!==n&&(e.name=n)}function ie(e,t,n){"number"===t&&X(e.ownerDocument)===e||(null==n?e.defaultValue=""+e._wrapperState.initialValue:e.defaultValue!==""+n&&(e.defaultValue=""+n))}function oe(e,t){return e=i({children:void 0},t),(t=function(e){var t="";return r.Children.forEach(e,(function(e){null!=e&&(t+=e)})),t}(t.children))&&(e.children=t),e}function ae(e,t,n,r){if(e=e.options,t){t={};for(var i=0;i<n.length;i++)t["$"+n[i]]=!0;for(n=0;n<e.length;n++)i=t.hasOwnProperty("$"+e[n].value),e[n].selected!==i&&(e[n].selected=i),i&&r&&(e[n].defaultSelected=!0)}else{for(n=""+Y(n),t=null,i=0;i<e.length;i++){if(e[i].value===n)return e[i].selected=!0,void(r&&(e[i].defaultSelected=!0));null!==t||e[i].disabled||(t=e[i])}null!==t&&(t.selected=!0)}}function le(e,t){if(null!=t.dangerouslySetInnerHTML)throw Error(a(91));return i({},t,{value:void 0,defaultValue:void 0,children:""+e._wrapperState.initialValue})}function se(e,t){var n=t.value;if(null==n){if(n=t.children,t=t.defaultValue,null!=n){if(null!=t)throw Error(a(92));if(Array.isArray(n)){if(!(1>=n.length))throw Error(a(93));n=n[0]}t=n}null==t&&(t=""),n=t}e._wrapperState={initialValue:Y(n)}}function ce(e,t){var n=Y(t.value),r=Y(t.defaultValue);null!=n&&((n=""+n)!==e.value&&(e.value=n),null==t.defaultValue&&e.defaultValue!==n&&(e.defaultValue=n)),null!=r&&(e.defaultValue=""+r)}function ue(e){var t=e.textContent;t===e._wrapperState.initialValue&&""!==t&&null!==t&&(e.value=t)}var pe="http://www.w3.org/1999/xhtml",de="http://www.w3.org/2000/svg";function fe(e){switch(e){case"svg":return"http://www.w3.org/2000/svg";case"math":return"http://www.w3.org/1998/Math/MathML";default:return"http://www.w3.org/1999/xhtml"}}function he(e,t){return null==e||"http://www.w3.org/1999/xhtml"===e?fe(t):"http://www.w3.org/2000/svg"===e&&"foreignObject"===t?"http://www.w3.org/1999/xhtml":e}var me,ge,be=(ge=function(e,t){if(e.namespaceURI!==de||"innerHTML"in e)e.innerHTML=t;else{for((me=me||document.createElement("div")).innerHTML="<svg>"+t.valueOf().toString()+"</svg>",t=me.firstChild;e.firstChild;)e.removeChild(e.firstChild);for(;t.firstChild;)e.appendChild(t.firstChild)}},"undefined"!==typeof MSApp&&MSApp.execUnsafeLocalFunction?function(e,t,n,r){MSApp.execUnsafeLocalFunction((function(){return ge(e,t)}))}:ge);function ve(e,t){if(t){var n=e.firstChild;if(n&&n===e.lastChild&&3===n.nodeType)return void(n.nodeValue=t)}e.textContent=t}var ye={animationIterationCount:!0,borderImageOutset:!0,borderImageSlice:!0,borderImageWidth:!0,boxFlex:!0,boxFlexGroup:!0,boxOrdinalGroup:!0,columnCount:!0,columns:!0,flex:!0,flexGrow:!0,flexPositive:!0,flexShrink:!0,flexNegative:!0,flexOrder:!0,gridArea:!0,gridRow:!0,gridRowEnd:!0,gridRowSpan:!0,gridRowStart:!0,gridColumn:!0,gridColumnEnd:!0,gridColumnSpan:!0,gridColumnStart:!0,fontWeight:!0,lineClamp:!0,lineHeight:!0,opacity:!0,order:!0,orphans:!0,tabSize:!0,widows:!0,zIndex:!0,zoom:!0,fillOpacity:!0,floodOpacity:!0,stopOpacity:!0,strokeDasharray:!0,strokeDashoffset:!0,strokeMiterlimit:!0,strokeOpacity:!0,strokeWidth:!0},xe=["Webkit","ms","Moz","O"];function we(e,t,n){return null==t||"boolean"===typeof t||""===t?"":n||"number"!==typeof t||0===t||ye.hasOwnProperty(e)&&ye[e]?(""+t).trim():t+"px"}function je(e,t){for(var n in e=e.style,t)if(t.hasOwnProperty(n)){var r=0===n.indexOf("--"),i=we(n,t[n],r);"float"===n&&(n="cssFloat"),r?e.setProperty(n,i):e[n]=i}}Object.keys(ye).forEach((function(e){xe.forEach((function(t){t=t+e.charAt(0).toUpperCase()+e.substring(1),ye[t]=ye[e]}))}));var Oe=i({menuitem:!0},{area:!0,base:!0,br:!0,col:!0,embed:!0,hr:!0,img:!0,input:!0,keygen:!0,link:!0,meta:!0,param:!0,source:!0,track:!0,wbr:!0});function ke(e,t){if(t){if(Oe[e]&&(null!=t.children||null!=t.dangerouslySetInnerHTML))throw Error(a(137,e));if(null!=t.dangerouslySetInnerHTML){if(null!=t.children)throw Error(a(60));if("object"!==typeof t.dangerouslySetInnerHTML||!("__html"in t.dangerouslySetInnerHTML))throw Error(a(61))}if(null!=t.style&&"object"!==typeof t.style)throw Error(a(62))}}function _e(e,t){if(-1===e.indexOf("-"))return"string"===typeof t.is;switch(e){case"annotation-xml":case"color-profile":case"font-face":case"font-face-src":case"font-face-uri":case"font-face-format":case"font-face-name":case"missing-glyph":return!1;default:return!0}}function Se(e){return(e=e.target||e.srcElement||window).correspondingUseElement&&(e=e.correspondingUseElement),3===e.nodeType?e.parentNode:e}var Pe=null,Ee=null,Ce=null;function Ne(e){if(e=ri(e)){if("function"!==typeof Pe)throw Error(a(280));var t=e.stateNode;t&&(t=oi(t),Pe(e.stateNode,e.type,t))}}function Te(e){Ee?Ce?Ce.push(e):Ce=[e]:Ee=e}function Ie(){if(Ee){var e=Ee,t=Ce;if(Ce=Ee=null,Ne(e),t)for(e=0;e<t.length;e++)Ne(t[e])}}function Le(e,t){return e(t)}function Me(e,t,n,r,i){return e(t,n,r,i)}function Fe(){}var De=Le,ze=!1,Re=!1;function Ue(){null===Ee&&null===Ce||(Fe(),Ie())}function Ae(e,t){var n=e.stateNode;if(null===n)return null;var r=oi(n);if(null===r)return null;n=r[t];e:switch(t){case"onClick":case"onClickCapture":case"onDoubleClick":case"onDoubleClickCapture":case"onMouseDown":case"onMouseDownCapture":case"onMouseMove":case"onMouseMoveCapture":case"onMouseUp":case"onMouseUpCapture":case"onMouseEnter":(r=!r.disabled)||(r=!("button"===(e=e.type)||"input"===e||"select"===e||"textarea"===e)),e=!r;break e;default:e=!1}if(e)return null;if(n&&"function"!==typeof n)throw Error(a(231,t,typeof n));return n}var Be=!1;if(p)try{var He={};Object.defineProperty(He,"passive",{get:function(){Be=!0}}),window.addEventListener("test",He,He),window.removeEventListener("test",He,He)}catch(ge){Be=!1}function qe(e,t,n,r,i,o,a,l,s){var c=Array.prototype.slice.call(arguments,3);try{t.apply(n,c)}catch(u){this.onError(u)}}var $e=!1,We=null,Qe=!1,Ve=null,Ye={onError:function(e){$e=!0,We=e}};function Ke(e,t,n,r,i,o,a,l,s){$e=!1,We=null,qe.apply(Ye,arguments)}function Ge(e){var t=e,n=e;if(e.alternate)for(;t.return;)t=t.return;else{e=t;do{0!==(1026&(t=e).flags)&&(n=t.return),e=t.return}while(e)}return 3===t.tag?n:null}function Je(e){if(13===e.tag){var t=e.memoizedState;if(null===t&&(null!==(e=e.alternate)&&(t=e.memoizedState)),null!==t)return t.dehydrated}return null}function Xe(e){if(Ge(e)!==e)throw Error(a(188))}function Ze(e){if(e=function(e){var t=e.alternate;if(!t){if(null===(t=Ge(e)))throw Error(a(188));return t!==e?null:e}for(var n=e,r=t;;){var i=n.return;if(null===i)break;var o=i.alternate;if(null===o){if(null!==(r=i.return)){n=r;continue}break}if(i.child===o.child){for(o=i.child;o;){if(o===n)return Xe(i),e;if(o===r)return Xe(i),t;o=o.sibling}throw Error(a(188))}if(n.return!==r.return)n=i,r=o;else{for(var l=!1,s=i.child;s;){if(s===n){l=!0,n=i,r=o;break}if(s===r){l=!0,r=i,n=o;break}s=s.sibling}if(!l){for(s=o.child;s;){if(s===n){l=!0,n=o,r=i;break}if(s===r){l=!0,r=o,n=i;break}s=s.sibling}if(!l)throw Error(a(189))}}if(n.alternate!==r)throw Error(a(190))}if(3!==n.tag)throw Error(a(188));return n.stateNode.current===n?e:t}(e),!e)return null;for(var t=e;;){if(5===t.tag||6===t.tag)return t;if(t.child)t.child.return=t,t=t.child;else{if(t===e)break;for(;!t.sibling;){if(!t.return||t.return===e)return null;t=t.return}t.sibling.return=t.return,t=t.sibling}}return null}function et(e,t){for(var n=e.alternate;null!==t;){if(t===e||t===n)return!0;t=t.return}return!1}var tt,nt,rt,it,ot=!1,at=[],lt=null,st=null,ct=null,ut=new Map,pt=new Map,dt=[],ft="mousedown mouseup touchcancel touchend touchstart auxclick dblclick pointercancel pointerdown pointerup dragend dragstart drop compositionend compositionstart keydown keypress keyup input textInput copy cut paste click change contextmenu reset submit".split(" ");function ht(e,t,n,r,i){return{blockedOn:e,domEventName:t,eventSystemFlags:16|n,nativeEvent:i,targetContainers:[r]}}function mt(e,t){switch(e){case"focusin":case"focusout":lt=null;break;case"dragenter":case"dragleave":st=null;break;case"mouseover":case"mouseout":ct=null;break;case"pointerover":case"pointerout":ut.delete(t.pointerId);break;case"gotpointercapture":case"lostpointercapture":pt.delete(t.pointerId)}}function gt(e,t,n,r,i,o){return null===e||e.nativeEvent!==o?(e=ht(t,n,r,i,o),null!==t&&(null!==(t=ri(t))&&nt(t)),e):(e.eventSystemFlags|=r,t=e.targetContainers,null!==i&&-1===t.indexOf(i)&&t.push(i),e)}function bt(e){var t=ni(e.target);if(null!==t){var n=Ge(t);if(null!==n)if(13===(t=n.tag)){if(null!==(t=Je(n)))return e.blockedOn=t,void it(e.lanePriority,(function(){o.unstable_runWithPriority(e.priority,(function(){rt(n)}))}))}else if(3===t&&n.stateNode.hydrate)return void(e.blockedOn=3===n.tag?n.stateNode.containerInfo:null)}e.blockedOn=null}function vt(e){if(null!==e.blockedOn)return!1;for(var t=e.targetContainers;0<t.length;){var n=Zt(e.domEventName,e.eventSystemFlags,t[0],e.nativeEvent);if(null!==n)return null!==(t=ri(n))&&nt(t),e.blockedOn=n,!1;t.shift()}return!0}function yt(e,t,n){vt(e)&&n.delete(t)}function xt(){for(ot=!1;0<at.length;){var e=at[0];if(null!==e.blockedOn){null!==(e=ri(e.blockedOn))&&tt(e);break}for(var t=e.targetContainers;0<t.length;){var n=Zt(e.domEventName,e.eventSystemFlags,t[0],e.nativeEvent);if(null!==n){e.blockedOn=n;break}t.shift()}null===e.blockedOn&&at.shift()}null!==lt&&vt(lt)&&(lt=null),null!==st&&vt(st)&&(st=null),null!==ct&&vt(ct)&&(ct=null),ut.forEach(yt),pt.forEach(yt)}function wt(e,t){e.blockedOn===t&&(e.blockedOn=null,ot||(ot=!0,o.unstable_scheduleCallback(o.unstable_NormalPriority,xt)))}function jt(e){function t(t){return wt(t,e)}if(0<at.length){wt(at[0],e);for(var n=1;n<at.length;n++){var r=at[n];r.blockedOn===e&&(r.blockedOn=null)}}for(null!==lt&&wt(lt,e),null!==st&&wt(st,e),null!==ct&&wt(ct,e),ut.forEach(t),pt.forEach(t),n=0;n<dt.length;n++)(r=dt[n]).blockedOn===e&&(r.blockedOn=null);for(;0<dt.length&&null===(n=dt[0]).blockedOn;)bt(n),null===n.blockedOn&&dt.shift()}function Ot(e,t){var n={};return n[e.toLowerCase()]=t.toLowerCase(),n["Webkit"+e]="webkit"+t,n["Moz"+e]="moz"+t,n}var kt={animationend:Ot("Animation","AnimationEnd"),animationiteration:Ot("Animation","AnimationIteration"),animationstart:Ot("Animation","AnimationStart"),transitionend:Ot("Transition","TransitionEnd")},_t={},St={};function Pt(e){if(_t[e])return _t[e];if(!kt[e])return e;var t,n=kt[e];for(t in n)if(n.hasOwnProperty(t)&&t in St)return _t[e]=n[t];return e}p&&(St=document.createElement("div").style,"AnimationEvent"in window||(delete kt.animationend.animation,delete kt.animationiteration.animation,delete kt.animationstart.animation),"TransitionEvent"in window||delete kt.transitionend.transition);var Et=Pt("animationend"),Ct=Pt("animationiteration"),Nt=Pt("animationstart"),Tt=Pt("transitionend"),It=new Map,Lt=new Map,Mt=["abort","abort",Et,"animationEnd",Ct,"animationIteration",Nt,"animationStart","canplay","canPlay","canplaythrough","canPlayThrough","durationchange","durationChange","emptied","emptied","encrypted","encrypted","ended","ended","error","error","gotpointercapture","gotPointerCapture","load","load","loadeddata","loadedData","loadedmetadata","loadedMetadata","loadstart","loadStart","lostpointercapture","lostPointerCapture","playing","playing","progress","progress","seeking","seeking","stalled","stalled","suspend","suspend","timeupdate","timeUpdate",Tt,"transitionEnd","waiting","waiting"];function Ft(e,t){for(var n=0;n<e.length;n+=2){var r=e[n],i=e[n+1];i="on"+(i[0].toUpperCase()+i.slice(1)),Lt.set(r,t),It.set(r,i),c(i,[r])}}(0,o.unstable_now)();var Dt=8;function zt(e){if(0!==(1&e))return Dt=15,1;if(0!==(2&e))return Dt=14,2;if(0!==(4&e))return Dt=13,4;var t=24&e;return 0!==t?(Dt=12,t):0!==(32&e)?(Dt=11,32):0!==(t=192&e)?(Dt=10,t):0!==(256&e)?(Dt=9,256):0!==(t=3584&e)?(Dt=8,t):0!==(4096&e)?(Dt=7,4096):0!==(t=4186112&e)?(Dt=6,t):0!==(t=62914560&e)?(Dt=5,t):67108864&e?(Dt=4,67108864):0!==(134217728&e)?(Dt=3,134217728):0!==(t=805306368&e)?(Dt=2,t):0!==(1073741824&e)?(Dt=1,1073741824):(Dt=8,e)}function Rt(e,t){var n=e.pendingLanes;if(0===n)return Dt=0;var r=0,i=0,o=e.expiredLanes,a=e.suspendedLanes,l=e.pingedLanes;if(0!==o)r=o,i=Dt=15;else if(0!==(o=134217727&n)){var s=o&~a;0!==s?(r=zt(s),i=Dt):0!==(l&=o)&&(r=zt(l),i=Dt)}else 0!==(o=n&~a)?(r=zt(o),i=Dt):0!==l&&(r=zt(l),i=Dt);if(0===r)return 0;if(r=n&((0>(r=31-$t(r))?0:1<<r)<<1)-1,0!==t&&t!==r&&0===(t&a)){if(zt(t),i<=Dt)return t;Dt=i}if(0!==(t=e.entangledLanes))for(e=e.entanglements,t&=r;0<t;)i=1<<(n=31-$t(t)),r|=e[n],t&=~i;return r}function Ut(e){return 0!==(e=-1073741825&e.pendingLanes)?e:1073741824&e?1073741824:0}function At(e,t){switch(e){case 15:return 1;case 14:return 2;case 12:return 0===(e=Bt(24&~t))?At(10,t):e;case 10:return 0===(e=Bt(192&~t))?At(8,t):e;case 8:return 0===(e=Bt(3584&~t))&&(0===(e=Bt(4186112&~t))&&(e=512)),e;case 2:return 0===(t=Bt(805306368&~t))&&(t=268435456),t}throw Error(a(358,e))}function Bt(e){return e&-e}function Ht(e){for(var t=[],n=0;31>n;n++)t.push(e);return t}function qt(e,t,n){e.pendingLanes|=t;var r=t-1;e.suspendedLanes&=r,e.pingedLanes&=r,(e=e.eventTimes)[t=31-$t(t)]=n}var $t=Math.clz32?Math.clz32:function(e){return 0===e?32:31-(Wt(e)/Qt|0)|0},Wt=Math.log,Qt=Math.LN2;var Vt=o.unstable_UserBlockingPriority,Yt=o.unstable_runWithPriority,Kt=!0;function Gt(e,t,n,r){ze||Fe();var i=Xt,o=ze;ze=!0;try{Me(i,e,t,n,r)}finally{(ze=o)||Ue()}}function Jt(e,t,n,r){Yt(Vt,Xt.bind(null,e,t,n,r))}function Xt(e,t,n,r){var i;if(Kt)if((i=0===(4&t))&&0<at.length&&-1<ft.indexOf(e))e=ht(null,e,t,n,r),at.push(e);else{var o=Zt(e,t,n,r);if(null===o)i&&mt(e,r);else{if(i){if(-1<ft.indexOf(e))return e=ht(o,e,t,n,r),void at.push(e);if(function(e,t,n,r,i){switch(t){case"focusin":return lt=gt(lt,e,t,n,r,i),!0;case"dragenter":return st=gt(st,e,t,n,r,i),!0;case"mouseover":return ct=gt(ct,e,t,n,r,i),!0;case"pointerover":var o=i.pointerId;return ut.set(o,gt(ut.get(o)||null,e,t,n,r,i)),!0;case"gotpointercapture":return o=i.pointerId,pt.set(o,gt(pt.get(o)||null,e,t,n,r,i)),!0}return!1}(o,e,t,n,r))return;mt(e,r)}Fr(e,t,r,null,n)}}}function Zt(e,t,n,r){var i=Se(r);if(null!==(i=ni(i))){var o=Ge(i);if(null===o)i=null;else{var a=o.tag;if(13===a){if(null!==(i=Je(o)))return i;i=null}else if(3===a){if(o.stateNode.hydrate)return 3===o.tag?o.stateNode.containerInfo:null;i=null}else o!==i&&(i=null)}}return Fr(e,t,r,i,n),null}var en=null,tn=null,nn=null;function rn(){if(nn)return nn;var e,t,n=tn,r=n.length,i="value"in en?en.value:en.textContent,o=i.length;for(e=0;e<r&&n[e]===i[e];e++);var a=r-e;for(t=1;t<=a&&n[r-t]===i[o-t];t++);return nn=i.slice(e,1<t?1-t:void 0)}function on(e){var t=e.keyCode;return"charCode"in e?0===(e=e.charCode)&&13===t&&(e=13):e=t,10===e&&(e=13),32<=e||13===e?e:0}function an(){return!0}function ln(){return!1}function sn(e){function t(t,n,r,i,o){for(var a in this._reactName=t,this._targetInst=r,this.type=n,this.nativeEvent=i,this.target=o,this.currentTarget=null,e)e.hasOwnProperty(a)&&(t=e[a],this[a]=t?t(i):i[a]);return this.isDefaultPrevented=(null!=i.defaultPrevented?i.defaultPrevented:!1===i.returnValue)?an:ln,this.isPropagationStopped=ln,this}return i(t.prototype,{preventDefault:function(){this.defaultPrevented=!0;var e=this.nativeEvent;e&&(e.preventDefault?e.preventDefault():"unknown"!==typeof e.returnValue&&(e.returnValue=!1),this.isDefaultPrevented=an)},stopPropagation:function(){var e=this.nativeEvent;e&&(e.stopPropagation?e.stopPropagation():"unknown"!==typeof e.cancelBubble&&(e.cancelBubble=!0),this.isPropagationStopped=an)},persist:function(){},isPersistent:an}),t}var cn,un,pn,dn={eventPhase:0,bubbles:0,cancelable:0,timeStamp:function(e){return e.timeStamp||Date.now()},defaultPrevented:0,isTrusted:0},fn=sn(dn),hn=i({},dn,{view:0,detail:0}),mn=sn(hn),gn=i({},hn,{screenX:0,screenY:0,clientX:0,clientY:0,pageX:0,pageY:0,ctrlKey:0,shiftKey:0,altKey:0,metaKey:0,getModifierState:En,button:0,buttons:0,relatedTarget:function(e){return void 0===e.relatedTarget?e.fromElement===e.srcElement?e.toElement:e.fromElement:e.relatedTarget},movementX:function(e){return"movementX"in e?e.movementX:(e!==pn&&(pn&&"mousemove"===e.type?(cn=e.screenX-pn.screenX,un=e.screenY-pn.screenY):un=cn=0,pn=e),cn)},movementY:function(e){return"movementY"in e?e.movementY:un}}),bn=sn(gn),vn=sn(i({},gn,{dataTransfer:0})),yn=sn(i({},hn,{relatedTarget:0})),xn=sn(i({},dn,{animationName:0,elapsedTime:0,pseudoElement:0})),wn=i({},dn,{clipboardData:function(e){return"clipboardData"in e?e.clipboardData:window.clipboardData}}),jn=sn(wn),On=sn(i({},dn,{data:0})),kn={Esc:"Escape",Spacebar:" ",Left:"ArrowLeft",Up:"ArrowUp",Right:"ArrowRight",Down:"ArrowDown",Del:"Delete",Win:"OS",Menu:"ContextMenu",Apps:"ContextMenu",Scroll:"ScrollLock",MozPrintableKey:"Unidentified"},_n={8:"Backspace",9:"Tab",12:"Clear",13:"Enter",16:"Shift",17:"Control",18:"Alt",19:"Pause",20:"CapsLock",27:"Escape",32:" ",33:"PageUp",34:"PageDown",35:"End",36:"Home",37:"ArrowLeft",38:"ArrowUp",39:"ArrowRight",40:"ArrowDown",45:"Insert",46:"Delete",112:"F1",113:"F2",114:"F3",115:"F4",116:"F5",117:"F6",118:"F7",119:"F8",120:"F9",121:"F10",122:"F11",123:"F12",144:"NumLock",145:"ScrollLock",224:"Meta"},Sn={Alt:"altKey",Control:"ctrlKey",Meta:"metaKey",Shift:"shiftKey"};function Pn(e){var t=this.nativeEvent;return t.getModifierState?t.getModifierState(e):!!(e=Sn[e])&&!!t[e]}function En(){return Pn}var Cn=i({},hn,{key:function(e){if(e.key){var t=kn[e.key]||e.key;if("Unidentified"!==t)return t}return"keypress"===e.type?13===(e=on(e))?"Enter":String.fromCharCode(e):"keydown"===e.type||"keyup"===e.type?_n[e.keyCode]||"Unidentified":""},code:0,location:0,ctrlKey:0,shiftKey:0,altKey:0,metaKey:0,repeat:0,locale:0,getModifierState:En,charCode:function(e){return"keypress"===e.type?on(e):0},keyCode:function(e){return"keydown"===e.type||"keyup"===e.type?e.keyCode:0},which:function(e){return"keypress"===e.type?on(e):"keydown"===e.type||"keyup"===e.type?e.keyCode:0}}),Nn=sn(Cn),Tn=sn(i({},gn,{pointerId:0,width:0,height:0,pressure:0,tangentialPressure:0,tiltX:0,tiltY:0,twist:0,pointerType:0,isPrimary:0})),In=sn(i({},hn,{touches:0,targetTouches:0,changedTouches:0,altKey:0,metaKey:0,ctrlKey:0,shiftKey:0,getModifierState:En})),Ln=sn(i({},dn,{propertyName:0,elapsedTime:0,pseudoElement:0})),Mn=i({},gn,{deltaX:function(e){return"deltaX"in e?e.deltaX:"wheelDeltaX"in e?-e.wheelDeltaX:0},deltaY:function(e){return"deltaY"in e?e.deltaY:"wheelDeltaY"in e?-e.wheelDeltaY:"wheelDelta"in e?-e.wheelDelta:0},deltaZ:0,deltaMode:0}),Fn=sn(Mn),Dn=[9,13,27,32],zn=p&&"CompositionEvent"in window,Rn=null;p&&"documentMode"in document&&(Rn=document.documentMode);var Un=p&&"TextEvent"in window&&!Rn,An=p&&(!zn||Rn&&8<Rn&&11>=Rn),Bn=String.fromCharCode(32),Hn=!1;function qn(e,t){switch(e){case"keyup":return-1!==Dn.indexOf(t.keyCode);case"keydown":return 229!==t.keyCode;case"keypress":case"mousedown":case"focusout":return!0;default:return!1}}function $n(e){return"object"===typeof(e=e.detail)&&"data"in e?e.data:null}var Wn=!1;var Qn={color:!0,date:!0,datetime:!0,"datetime-local":!0,email:!0,month:!0,number:!0,password:!0,range:!0,search:!0,tel:!0,text:!0,time:!0,url:!0,week:!0};function Vn(e){var t=e&&e.nodeName&&e.nodeName.toLowerCase();return"input"===t?!!Qn[e.type]:"textarea"===t}function Yn(e,t,n,r){Te(r),0<(t=zr(t,"onChange")).length&&(n=new fn("onChange","change",null,n,r),e.push({event:n,listeners:t}))}var Kn=null,Gn=null;function Jn(e){Cr(e,0)}function Xn(e){if(J(ii(e)))return e}function Zn(e,t){if("change"===e)return t}var er=!1;if(p){var tr;if(p){var nr="oninput"in document;if(!nr){var rr=document.createElement("div");rr.setAttribute("oninput","return;"),nr="function"===typeof rr.oninput}tr=nr}else tr=!1;er=tr&&(!document.documentMode||9<document.documentMode)}function ir(){Kn&&(Kn.detachEvent("onpropertychange",or),Gn=Kn=null)}function or(e){if("value"===e.propertyName&&Xn(Gn)){var t=[];if(Yn(t,Gn,e,Se(e)),e=Jn,ze)e(t);else{ze=!0;try{Le(e,t)}finally{ze=!1,Ue()}}}}function ar(e,t,n){"focusin"===e?(ir(),Gn=n,(Kn=t).attachEvent("onpropertychange",or)):"focusout"===e&&ir()}function lr(e){if("selectionchange"===e||"keyup"===e||"keydown"===e)return Xn(Gn)}function sr(e,t){if("click"===e)return Xn(t)}function cr(e,t){if("input"===e||"change"===e)return Xn(t)}var ur="function"===typeof Object.is?Object.is:function(e,t){return e===t&&(0!==e||1/e===1/t)||e!==e&&t!==t},pr=Object.prototype.hasOwnProperty;function dr(e,t){if(ur(e,t))return!0;if("object"!==typeof e||null===e||"object"!==typeof t||null===t)return!1;var n=Object.keys(e),r=Object.keys(t);if(n.length!==r.length)return!1;for(r=0;r<n.length;r++)if(!pr.call(t,n[r])||!ur(e[n[r]],t[n[r]]))return!1;return!0}function fr(e){for(;e&&e.firstChild;)e=e.firstChild;return e}function hr(e,t){var n,r=fr(e);for(e=0;r;){if(3===r.nodeType){if(n=e+r.textContent.length,e<=t&&n>=t)return{node:r,offset:t-e};e=n}e:{for(;r;){if(r.nextSibling){r=r.nextSibling;break e}r=r.parentNode}r=void 0}r=fr(r)}}function mr(e,t){return!(!e||!t)&&(e===t||(!e||3!==e.nodeType)&&(t&&3===t.nodeType?mr(e,t.parentNode):"contains"in e?e.contains(t):!!e.compareDocumentPosition&&!!(16&e.compareDocumentPosition(t))))}function gr(){for(var e=window,t=X();t instanceof e.HTMLIFrameElement;){try{var n="string"===typeof t.contentWindow.location.href}catch(r){n=!1}if(!n)break;t=X((e=t.contentWindow).document)}return t}function br(e){var t=e&&e.nodeName&&e.nodeName.toLowerCase();return t&&("input"===t&&("text"===e.type||"search"===e.type||"tel"===e.type||"url"===e.type||"password"===e.type)||"textarea"===t||"true"===e.contentEditable)}var vr=p&&"documentMode"in document&&11>=document.documentMode,yr=null,xr=null,wr=null,jr=!1;function Or(e,t,n){var r=n.window===n?n.document:9===n.nodeType?n:n.ownerDocument;jr||null==yr||yr!==X(r)||("selectionStart"in(r=yr)&&br(r)?r={start:r.selectionStart,end:r.selectionEnd}:r={anchorNode:(r=(r.ownerDocument&&r.ownerDocument.defaultView||window).getSelection()).anchorNode,anchorOffset:r.anchorOffset,focusNode:r.focusNode,focusOffset:r.focusOffset},wr&&dr(wr,r)||(wr=r,0<(r=zr(xr,"onSelect")).length&&(t=new fn("onSelect","select",null,t,n),e.push({event:t,listeners:r}),t.target=yr)))}Ft("cancel cancel click click close close contextmenu contextMenu copy copy cut cut auxclick auxClick dblclick doubleClick dragend dragEnd dragstart dragStart drop drop focusin focus focusout blur input input invalid invalid keydown keyDown keypress keyPress keyup keyUp mousedown mouseDown mouseup mouseUp paste paste pause pause play play pointercancel pointerCancel pointerdown pointerDown pointerup pointerUp ratechange rateChange reset reset seeked seeked submit submit touchcancel touchCancel touchend touchEnd touchstart touchStart volumechange volumeChange".split(" "),0),Ft("drag drag dragenter dragEnter dragexit dragExit dragleave dragLeave dragover dragOver mousemove mouseMove mouseout mouseOut mouseover mouseOver pointermove pointerMove pointerout pointerOut pointerover pointerOver scroll scroll toggle toggle touchmove touchMove wheel wheel".split(" "),1),Ft(Mt,2);for(var kr="change selectionchange textInput compositionstart compositionend compositionupdate".split(" "),_r=0;_r<kr.length;_r++)Lt.set(kr[_r],0);u("onMouseEnter",["mouseout","mouseover"]),u("onMouseLeave",["mouseout","mouseover"]),u("onPointerEnter",["pointerout","pointerover"]),u("onPointerLeave",["pointerout","pointerover"]),c("onChange","change click focusin focusout input keydown keyup selectionchange".split(" ")),c("onSelect","focusout contextmenu dragend focusin keydown keyup mousedown mouseup selectionchange".split(" ")),c("onBeforeInput",["compositionend","keypress","textInput","paste"]),c("onCompositionEnd","compositionend focusout keydown keypress keyup mousedown".split(" ")),c("onCompositionStart","compositionstart focusout keydown keypress keyup mousedown".split(" ")),c("onCompositionUpdate","compositionupdate focusout keydown keypress keyup mousedown".split(" "));var Sr="abort canplay canplaythrough durationchange emptied encrypted ended error loadeddata loadedmetadata loadstart pause play playing progress ratechange seeked seeking stalled suspend timeupdate volumechange waiting".split(" "),Pr=new Set("cancel close invalid load scroll toggle".split(" ").concat(Sr));function Er(e,t,n){var r=e.type||"unknown-event";e.currentTarget=n,function(e,t,n,r,i,o,l,s,c){if(Ke.apply(this,arguments),$e){if(!$e)throw Error(a(198));var u=We;$e=!1,We=null,Qe||(Qe=!0,Ve=u)}}(r,t,void 0,e),e.currentTarget=null}function Cr(e,t){t=0!==(4&t);for(var n=0;n<e.length;n++){var r=e[n],i=r.event;r=r.listeners;e:{var o=void 0;if(t)for(var a=r.length-1;0<=a;a--){var l=r[a],s=l.instance,c=l.currentTarget;if(l=l.listener,s!==o&&i.isPropagationStopped())break e;Er(i,l,c),o=s}else for(a=0;a<r.length;a++){if(s=(l=r[a]).instance,c=l.currentTarget,l=l.listener,s!==o&&i.isPropagationStopped())break e;Er(i,l,c),o=s}}}if(Qe)throw e=Ve,Qe=!1,Ve=null,e}function Nr(e,t){var n=ai(t),r=e+"__bubble";n.has(r)||(Mr(t,e,2,!1),n.add(r))}var Tr="_reactListening"+Math.random().toString(36).slice(2);function Ir(e){e[Tr]||(e[Tr]=!0,l.forEach((function(t){Pr.has(t)||Lr(t,!1,e,null),Lr(t,!0,e,null)})))}function Lr(e,t,n,r){var i=4<arguments.length&&void 0!==arguments[4]?arguments[4]:0,o=n;if("selectionchange"===e&&9!==n.nodeType&&(o=n.ownerDocument),null!==r&&!t&&Pr.has(e)){if("scroll"!==e)return;i|=2,o=r}var a=ai(o),l=e+"__"+(t?"capture":"bubble");a.has(l)||(t&&(i|=4),Mr(o,e,i,t),a.add(l))}function Mr(e,t,n,r){var i=Lt.get(t);switch(void 0===i?2:i){case 0:i=Gt;break;case 1:i=Jt;break;default:i=Xt}n=i.bind(null,t,n,e),i=void 0,!Be||"touchstart"!==t&&"touchmove"!==t&&"wheel"!==t||(i=!0),r?void 0!==i?e.addEventListener(t,n,{capture:!0,passive:i}):e.addEventListener(t,n,!0):void 0!==i?e.addEventListener(t,n,{passive:i}):e.addEventListener(t,n,!1)}function Fr(e,t,n,r,i){var o=r;if(0===(1&t)&&0===(2&t)&&null!==r)e:for(;;){if(null===r)return;var a=r.tag;if(3===a||4===a){var l=r.stateNode.containerInfo;if(l===i||8===l.nodeType&&l.parentNode===i)break;if(4===a)for(a=r.return;null!==a;){var s=a.tag;if((3===s||4===s)&&((s=a.stateNode.containerInfo)===i||8===s.nodeType&&s.parentNode===i))return;a=a.return}for(;null!==l;){if(null===(a=ni(l)))return;if(5===(s=a.tag)||6===s){r=o=a;continue e}l=l.parentNode}}r=r.return}!function(e,t,n){if(Re)return e(t,n);Re=!0;try{De(e,t,n)}finally{Re=!1,Ue()}}((function(){var r=o,i=Se(n),a=[];e:{var l=It.get(e);if(void 0!==l){var s=fn,c=e;switch(e){case"keypress":if(0===on(n))break e;case"keydown":case"keyup":s=Nn;break;case"focusin":c="focus",s=yn;break;case"focusout":c="blur",s=yn;break;case"beforeblur":case"afterblur":s=yn;break;case"click":if(2===n.button)break e;case"auxclick":case"dblclick":case"mousedown":case"mousemove":case"mouseup":case"mouseout":case"mouseover":case"contextmenu":s=bn;break;case"drag":case"dragend":case"dragenter":case"dragexit":case"dragleave":case"dragover":case"dragstart":case"drop":s=vn;break;case"touchcancel":case"touchend":case"touchmove":case"touchstart":s=In;break;case Et:case Ct:case Nt:s=xn;break;case Tt:s=Ln;break;case"scroll":s=mn;break;case"wheel":s=Fn;break;case"copy":case"cut":case"paste":s=jn;break;case"gotpointercapture":case"lostpointercapture":case"pointercancel":case"pointerdown":case"pointermove":case"pointerout":case"pointerover":case"pointerup":s=Tn}var u=0!==(4&t),p=!u&&"scroll"===e,d=u?null!==l?l+"Capture":null:l;u=[];for(var f,h=r;null!==h;){var m=(f=h).stateNode;if(5===f.tag&&null!==m&&(f=m,null!==d&&(null!=(m=Ae(h,d))&&u.push(Dr(h,m,f)))),p)break;h=h.return}0<u.length&&(l=new s(l,c,null,n,i),a.push({event:l,listeners:u}))}}if(0===(7&t)){if(s="mouseout"===e||"pointerout"===e,(!(l="mouseover"===e||"pointerover"===e)||0!==(16&t)||!(c=n.relatedTarget||n.fromElement)||!ni(c)&&!c[ei])&&(s||l)&&(l=i.window===i?i:(l=i.ownerDocument)?l.defaultView||l.parentWindow:window,s?(s=r,null!==(c=(c=n.relatedTarget||n.toElement)?ni(c):null)&&(c!==(p=Ge(c))||5!==c.tag&&6!==c.tag)&&(c=null)):(s=null,c=r),s!==c)){if(u=bn,m="onMouseLeave",d="onMouseEnter",h="mouse","pointerout"!==e&&"pointerover"!==e||(u=Tn,m="onPointerLeave",d="onPointerEnter",h="pointer"),p=null==s?l:ii(s),f=null==c?l:ii(c),(l=new u(m,h+"leave",s,n,i)).target=p,l.relatedTarget=f,m=null,ni(i)===r&&((u=new u(d,h+"enter",c,n,i)).target=f,u.relatedTarget=p,m=u),p=m,s&&c)e:{for(d=c,h=0,f=u=s;f;f=Rr(f))h++;for(f=0,m=d;m;m=Rr(m))f++;for(;0<h-f;)u=Rr(u),h--;for(;0<f-h;)d=Rr(d),f--;for(;h--;){if(u===d||null!==d&&u===d.alternate)break e;u=Rr(u),d=Rr(d)}u=null}else u=null;null!==s&&Ur(a,l,s,u,!1),null!==c&&null!==p&&Ur(a,p,c,u,!0)}if("select"===(s=(l=r?ii(r):window).nodeName&&l.nodeName.toLowerCase())||"input"===s&&"file"===l.type)var g=Zn;else if(Vn(l))if(er)g=cr;else{g=lr;var b=ar}else(s=l.nodeName)&&"input"===s.toLowerCase()&&("checkbox"===l.type||"radio"===l.type)&&(g=sr);switch(g&&(g=g(e,r))?Yn(a,g,n,i):(b&&b(e,l,r),"focusout"===e&&(b=l._wrapperState)&&b.controlled&&"number"===l.type&&ie(l,"number",l.value)),b=r?ii(r):window,e){case"focusin":(Vn(b)||"true"===b.contentEditable)&&(yr=b,xr=r,wr=null);break;case"focusout":wr=xr=yr=null;break;case"mousedown":jr=!0;break;case"contextmenu":case"mouseup":case"dragend":jr=!1,Or(a,n,i);break;case"selectionchange":if(vr)break;case"keydown":case"keyup":Or(a,n,i)}var v;if(zn)e:{switch(e){case"compositionstart":var y="onCompositionStart";break e;case"compositionend":y="onCompositionEnd";break e;case"compositionupdate":y="onCompositionUpdate";break e}y=void 0}else Wn?qn(e,n)&&(y="onCompositionEnd"):"keydown"===e&&229===n.keyCode&&(y="onCompositionStart");y&&(An&&"ko"!==n.locale&&(Wn||"onCompositionStart"!==y?"onCompositionEnd"===y&&Wn&&(v=rn()):(tn="value"in(en=i)?en.value:en.textContent,Wn=!0)),0<(b=zr(r,y)).length&&(y=new On(y,e,null,n,i),a.push({event:y,listeners:b}),v?y.data=v:null!==(v=$n(n))&&(y.data=v))),(v=Un?function(e,t){switch(e){case"compositionend":return $n(t);case"keypress":return 32!==t.which?null:(Hn=!0,Bn);case"textInput":return(e=t.data)===Bn&&Hn?null:e;default:return null}}(e,n):function(e,t){if(Wn)return"compositionend"===e||!zn&&qn(e,t)?(e=rn(),nn=tn=en=null,Wn=!1,e):null;switch(e){case"paste":default:return null;case"keypress":if(!(t.ctrlKey||t.altKey||t.metaKey)||t.ctrlKey&&t.altKey){if(t.char&&1<t.char.length)return t.char;if(t.which)return String.fromCharCode(t.which)}return null;case"compositionend":return An&&"ko"!==t.locale?null:t.data}}(e,n))&&(0<(r=zr(r,"onBeforeInput")).length&&(i=new On("onBeforeInput","beforeinput",null,n,i),a.push({event:i,listeners:r}),i.data=v))}Cr(a,t)}))}function Dr(e,t,n){return{instance:e,listener:t,currentTarget:n}}function zr(e,t){for(var n=t+"Capture",r=[];null!==e;){var i=e,o=i.stateNode;5===i.tag&&null!==o&&(i=o,null!=(o=Ae(e,n))&&r.unshift(Dr(e,o,i)),null!=(o=Ae(e,t))&&r.push(Dr(e,o,i))),e=e.return}return r}function Rr(e){if(null===e)return null;do{e=e.return}while(e&&5!==e.tag);return e||null}function Ur(e,t,n,r,i){for(var o=t._reactName,a=[];null!==n&&n!==r;){var l=n,s=l.alternate,c=l.stateNode;if(null!==s&&s===r)break;5===l.tag&&null!==c&&(l=c,i?null!=(s=Ae(n,o))&&a.unshift(Dr(n,s,l)):i||null!=(s=Ae(n,o))&&a.push(Dr(n,s,l))),n=n.return}0!==a.length&&e.push({event:t,listeners:a})}function Ar(){}var Br=null,Hr=null;function qr(e,t){switch(e){case"button":case"input":case"select":case"textarea":return!!t.autoFocus}return!1}function $r(e,t){return"textarea"===e||"option"===e||"noscript"===e||"string"===typeof t.children||"number"===typeof t.children||"object"===typeof t.dangerouslySetInnerHTML&&null!==t.dangerouslySetInnerHTML&&null!=t.dangerouslySetInnerHTML.__html}var Wr="function"===typeof setTimeout?setTimeout:void 0,Qr="function"===typeof clearTimeout?clearTimeout:void 0;function Vr(e){1===e.nodeType?e.textContent="":9===e.nodeType&&(null!=(e=e.body)&&(e.textContent=""))}function Yr(e){for(;null!=e;e=e.nextSibling){var t=e.nodeType;if(1===t||3===t)break}return e}function Kr(e){e=e.previousSibling;for(var t=0;e;){if(8===e.nodeType){var n=e.data;if("$"===n||"$!"===n||"$?"===n){if(0===t)return e;t--}else"/$"===n&&t++}e=e.previousSibling}return null}var Gr=0;var Jr=Math.random().toString(36).slice(2),Xr="__reactFiber$"+Jr,Zr="__reactProps$"+Jr,ei="__reactContainer$"+Jr,ti="__reactEvents$"+Jr;function ni(e){var t=e[Xr];if(t)return t;for(var n=e.parentNode;n;){if(t=n[ei]||n[Xr]){if(n=t.alternate,null!==t.child||null!==n&&null!==n.child)for(e=Kr(e);null!==e;){if(n=e[Xr])return n;e=Kr(e)}return t}n=(e=n).parentNode}return null}function ri(e){return!(e=e[Xr]||e[ei])||5!==e.tag&&6!==e.tag&&13!==e.tag&&3!==e.tag?null:e}function ii(e){if(5===e.tag||6===e.tag)return e.stateNode;throw Error(a(33))}function oi(e){return e[Zr]||null}function ai(e){var t=e[ti];return void 0===t&&(t=e[ti]=new Set),t}var li=[],si=-1;function ci(e){return{current:e}}function ui(e){0>si||(e.current=li[si],li[si]=null,si--)}function pi(e,t){si++,li[si]=e.current,e.current=t}var di={},fi=ci(di),hi=ci(!1),mi=di;function gi(e,t){var n=e.type.contextTypes;if(!n)return di;var r=e.stateNode;if(r&&r.__reactInternalMemoizedUnmaskedChildContext===t)return r.__reactInternalMemoizedMaskedChildContext;var i,o={};for(i in n)o[i]=t[i];return r&&((e=e.stateNode).__reactInternalMemoizedUnmaskedChildContext=t,e.__reactInternalMemoizedMaskedChildContext=o),o}function bi(e){return null!==(e=e.childContextTypes)&&void 0!==e}function vi(){ui(hi),ui(fi)}function yi(e,t,n){if(fi.current!==di)throw Error(a(168));pi(fi,t),pi(hi,n)}function xi(e,t,n){var r=e.stateNode;if(e=t.childContextTypes,"function"!==typeof r.getChildContext)return n;for(var o in r=r.getChildContext())if(!(o in e))throw Error(a(108,V(t)||"Unknown",o));return i({},n,r)}function wi(e){return e=(e=e.stateNode)&&e.__reactInternalMemoizedMergedChildContext||di,mi=fi.current,pi(fi,e),pi(hi,hi.current),!0}function ji(e,t,n){var r=e.stateNode;if(!r)throw Error(a(169));n?(e=xi(e,t,mi),r.__reactInternalMemoizedMergedChildContext=e,ui(hi),ui(fi),pi(fi,e)):ui(hi),pi(hi,n)}var Oi=null,ki=null,_i=o.unstable_runWithPriority,Si=o.unstable_scheduleCallback,Pi=o.unstable_cancelCallback,Ei=o.unstable_shouldYield,Ci=o.unstable_requestPaint,Ni=o.unstable_now,Ti=o.unstable_getCurrentPriorityLevel,Ii=o.unstable_ImmediatePriority,Li=o.unstable_UserBlockingPriority,Mi=o.unstable_NormalPriority,Fi=o.unstable_LowPriority,Di=o.unstable_IdlePriority,zi={},Ri=void 0!==Ci?Ci:function(){},Ui=null,Ai=null,Bi=!1,Hi=Ni(),qi=1e4>Hi?Ni:function(){return Ni()-Hi};function $i(){switch(Ti()){case Ii:return 99;case Li:return 98;case Mi:return 97;case Fi:return 96;case Di:return 95;default:throw Error(a(332))}}function Wi(e){switch(e){case 99:return Ii;case 98:return Li;case 97:return Mi;case 96:return Fi;case 95:return Di;default:throw Error(a(332))}}function Qi(e,t){return e=Wi(e),_i(e,t)}function Vi(e,t,n){return e=Wi(e),Si(e,t,n)}function Yi(){if(null!==Ai){var e=Ai;Ai=null,Pi(e)}Ki()}function Ki(){if(!Bi&&null!==Ui){Bi=!0;var e=0;try{var t=Ui;Qi(99,(function(){for(;e<t.length;e++){var n=t[e];do{n=n(!0)}while(null!==n)}})),Ui=null}catch(n){throw null!==Ui&&(Ui=Ui.slice(e+1)),Si(Ii,Yi),n}finally{Bi=!1}}}var Gi=w.ReactCurrentBatchConfig;function Ji(e,t){if(e&&e.defaultProps){for(var n in t=i({},t),e=e.defaultProps)void 0===t[n]&&(t[n]=e[n]);return t}return t}var Xi=ci(null),Zi=null,eo=null,to=null;function no(){to=eo=Zi=null}function ro(e){var t=Xi.current;ui(Xi),e.type._context._currentValue=t}function io(e,t){for(;null!==e;){var n=e.alternate;if((e.childLanes&t)===t){if(null===n||(n.childLanes&t)===t)break;n.childLanes|=t}else e.childLanes|=t,null!==n&&(n.childLanes|=t);e=e.return}}function oo(e,t){Zi=e,to=eo=null,null!==(e=e.dependencies)&&null!==e.firstContext&&(0!==(e.lanes&t)&&(za=!0),e.firstContext=null)}function ao(e,t){if(to!==e&&!1!==t&&0!==t)if("number"===typeof t&&1073741823!==t||(to=e,t=1073741823),t={context:e,observedBits:t,next:null},null===eo){if(null===Zi)throw Error(a(308));eo=t,Zi.dependencies={lanes:0,firstContext:t,responders:null}}else eo=eo.next=t;return e._currentValue}var lo=!1;function so(e){e.updateQueue={baseState:e.memoizedState,firstBaseUpdate:null,lastBaseUpdate:null,shared:{pending:null},effects:null}}function co(e,t){e=e.updateQueue,t.updateQueue===e&&(t.updateQueue={baseState:e.baseState,firstBaseUpdate:e.firstBaseUpdate,lastBaseUpdate:e.lastBaseUpdate,shared:e.shared,effects:e.effects})}function uo(e,t){return{eventTime:e,lane:t,tag:0,payload:null,callback:null,next:null}}function po(e,t){if(null!==(e=e.updateQueue)){var n=(e=e.shared).pending;null===n?t.next=t:(t.next=n.next,n.next=t),e.pending=t}}function fo(e,t){var n=e.updateQueue,r=e.alternate;if(null!==r&&n===(r=r.updateQueue)){var i=null,o=null;if(null!==(n=n.firstBaseUpdate)){do{var a={eventTime:n.eventTime,lane:n.lane,tag:n.tag,payload:n.payload,callback:n.callback,next:null};null===o?i=o=a:o=o.next=a,n=n.next}while(null!==n);null===o?i=o=t:o=o.next=t}else i=o=t;return n={baseState:r.baseState,firstBaseUpdate:i,lastBaseUpdate:o,shared:r.shared,effects:r.effects},void(e.updateQueue=n)}null===(e=n.lastBaseUpdate)?n.firstBaseUpdate=t:e.next=t,n.lastBaseUpdate=t}function ho(e,t,n,r){var o=e.updateQueue;lo=!1;var a=o.firstBaseUpdate,l=o.lastBaseUpdate,s=o.shared.pending;if(null!==s){o.shared.pending=null;var c=s,u=c.next;c.next=null,null===l?a=u:l.next=u,l=c;var p=e.alternate;if(null!==p){var d=(p=p.updateQueue).lastBaseUpdate;d!==l&&(null===d?p.firstBaseUpdate=u:d.next=u,p.lastBaseUpdate=c)}}if(null!==a){for(d=o.baseState,l=0,p=u=c=null;;){s=a.lane;var f=a.eventTime;if((r&s)===s){null!==p&&(p=p.next={eventTime:f,lane:0,tag:a.tag,payload:a.payload,callback:a.callback,next:null});e:{var h=e,m=a;switch(s=t,f=n,m.tag){case 1:if("function"===typeof(h=m.payload)){d=h.call(f,d,s);break e}d=h;break e;case 3:h.flags=-4097&h.flags|64;case 0:if(null===(s="function"===typeof(h=m.payload)?h.call(f,d,s):h)||void 0===s)break e;d=i({},d,s);break e;case 2:lo=!0}}null!==a.callback&&(e.flags|=32,null===(s=o.effects)?o.effects=[a]:s.push(a))}else f={eventTime:f,lane:s,tag:a.tag,payload:a.payload,callback:a.callback,next:null},null===p?(u=p=f,c=d):p=p.next=f,l|=s;if(null===(a=a.next)){if(null===(s=o.shared.pending))break;a=s.next,s.next=null,o.lastBaseUpdate=s,o.shared.pending=null}}null===p&&(c=d),o.baseState=c,o.firstBaseUpdate=u,o.lastBaseUpdate=p,Bl|=l,e.lanes=l,e.memoizedState=d}}function mo(e,t,n){if(e=t.effects,t.effects=null,null!==e)for(t=0;t<e.length;t++){var r=e[t],i=r.callback;if(null!==i){if(r.callback=null,r=n,"function"!==typeof i)throw Error(a(191,i));i.call(r)}}}var go=(new r.Component).refs;function bo(e,t,n,r){n=null===(n=n(r,t=e.memoizedState))||void 0===n?t:i({},t,n),e.memoizedState=n,0===e.lanes&&(e.updateQueue.baseState=n)}var vo={isMounted:function(e){return!!(e=e._reactInternals)&&Ge(e)===e},enqueueSetState:function(e,t,n){e=e._reactInternals;var r=ds(),i=fs(e),o=uo(r,i);o.payload=t,void 0!==n&&null!==n&&(o.callback=n),po(e,o),hs(e,i,r)},enqueueReplaceState:function(e,t,n){e=e._reactInternals;var r=ds(),i=fs(e),o=uo(r,i);o.tag=1,o.payload=t,void 0!==n&&null!==n&&(o.callback=n),po(e,o),hs(e,i,r)},enqueueForceUpdate:function(e,t){e=e._reactInternals;var n=ds(),r=fs(e),i=uo(n,r);i.tag=2,void 0!==t&&null!==t&&(i.callback=t),po(e,i),hs(e,r,n)}};function yo(e,t,n,r,i,o,a){return"function"===typeof(e=e.stateNode).shouldComponentUpdate?e.shouldComponentUpdate(r,o,a):!t.prototype||!t.prototype.isPureReactComponent||(!dr(n,r)||!dr(i,o))}function xo(e,t,n){var r=!1,i=di,o=t.contextType;return"object"===typeof o&&null!==o?o=ao(o):(i=bi(t)?mi:fi.current,o=(r=null!==(r=t.contextTypes)&&void 0!==r)?gi(e,i):di),t=new t(n,o),e.memoizedState=null!==t.state&&void 0!==t.state?t.state:null,t.updater=vo,e.stateNode=t,t._reactInternals=e,r&&((e=e.stateNode).__reactInternalMemoizedUnmaskedChildContext=i,e.__reactInternalMemoizedMaskedChildContext=o),t}function wo(e,t,n,r){e=t.state,"function"===typeof t.componentWillReceiveProps&&t.componentWillReceiveProps(n,r),"function"===typeof t.UNSAFE_componentWillReceiveProps&&t.UNSAFE_componentWillReceiveProps(n,r),t.state!==e&&vo.enqueueReplaceState(t,t.state,null)}function jo(e,t,n,r){var i=e.stateNode;i.props=n,i.state=e.memoizedState,i.refs=go,so(e);var o=t.contextType;"object"===typeof o&&null!==o?i.context=ao(o):(o=bi(t)?mi:fi.current,i.context=gi(e,o)),ho(e,n,i,r),i.state=e.memoizedState,"function"===typeof(o=t.getDerivedStateFromProps)&&(bo(e,t,o,n),i.state=e.memoizedState),"function"===typeof t.getDerivedStateFromProps||"function"===typeof i.getSnapshotBeforeUpdate||"function"!==typeof i.UNSAFE_componentWillMount&&"function"!==typeof i.componentWillMount||(t=i.state,"function"===typeof i.componentWillMount&&i.componentWillMount(),"function"===typeof i.UNSAFE_componentWillMount&&i.UNSAFE_componentWillMount(),t!==i.state&&vo.enqueueReplaceState(i,i.state,null),ho(e,n,i,r),i.state=e.memoizedState),"function"===typeof i.componentDidMount&&(e.flags|=4)}var Oo=Array.isArray;function ko(e,t,n){if(null!==(e=n.ref)&&"function"!==typeof e&&"object"!==typeof e){if(n._owner){if(n=n._owner){if(1!==n.tag)throw Error(a(309));var r=n.stateNode}if(!r)throw Error(a(147,e));var i=""+e;return null!==t&&null!==t.ref&&"function"===typeof t.ref&&t.ref._stringRef===i?t.ref:(t=function(e){var t=r.refs;t===go&&(t=r.refs={}),null===e?delete t[i]:t[i]=e},t._stringRef=i,t)}if("string"!==typeof e)throw Error(a(284));if(!n._owner)throw Error(a(290,e))}return e}function _o(e,t){if("textarea"!==e.type)throw Error(a(31,"[object Object]"===Object.prototype.toString.call(t)?"object with keys {"+Object.keys(t).join(", ")+"}":t))}function So(e){function t(t,n){if(e){var r=t.lastEffect;null!==r?(r.nextEffect=n,t.lastEffect=n):t.firstEffect=t.lastEffect=n,n.nextEffect=null,n.flags=8}}function n(n,r){if(!e)return null;for(;null!==r;)t(n,r),r=r.sibling;return null}function r(e,t){for(e=new Map;null!==t;)null!==t.key?e.set(t.key,t):e.set(t.index,t),t=t.sibling;return e}function i(e,t){return(e=Qs(e,t)).index=0,e.sibling=null,e}function o(t,n,r){return t.index=r,e?null!==(r=t.alternate)?(r=r.index)<n?(t.flags=2,n):r:(t.flags=2,n):n}function l(t){return e&&null===t.alternate&&(t.flags=2),t}function s(e,t,n,r){return null===t||6!==t.tag?((t=Gs(n,e.mode,r)).return=e,t):((t=i(t,n)).return=e,t)}function c(e,t,n,r){return null!==t&&t.elementType===n.type?((r=i(t,n.props)).ref=ko(e,t,n),r.return=e,r):((r=Vs(n.type,n.key,n.props,null,e.mode,r)).ref=ko(e,t,n),r.return=e,r)}function u(e,t,n,r){return null===t||4!==t.tag||t.stateNode.containerInfo!==n.containerInfo||t.stateNode.implementation!==n.implementation?((t=Js(n,e.mode,r)).return=e,t):((t=i(t,n.children||[])).return=e,t)}function p(e,t,n,r,o){return null===t||7!==t.tag?((t=Ys(n,e.mode,r,o)).return=e,t):((t=i(t,n)).return=e,t)}function d(e,t,n){if("string"===typeof t||"number"===typeof t)return(t=Gs(""+t,e.mode,n)).return=e,t;if("object"===typeof t&&null!==t){switch(t.$$typeof){case j:return(n=Vs(t.type,t.key,t.props,null,e.mode,n)).ref=ko(e,null,t),n.return=e,n;case O:return(t=Js(t,e.mode,n)).return=e,t}if(Oo(t)||H(t))return(t=Ys(t,e.mode,n,null)).return=e,t;_o(e,t)}return null}function f(e,t,n,r){var i=null!==t?t.key:null;if("string"===typeof n||"number"===typeof n)return null!==i?null:s(e,t,""+n,r);if("object"===typeof n&&null!==n){switch(n.$$typeof){case j:return n.key===i?n.type===k?p(e,t,n.props.children,r,i):c(e,t,n,r):null;case O:return n.key===i?u(e,t,n,r):null}if(Oo(n)||H(n))return null!==i?null:p(e,t,n,r,null);_o(e,n)}return null}function h(e,t,n,r,i){if("string"===typeof r||"number"===typeof r)return s(t,e=e.get(n)||null,""+r,i);if("object"===typeof r&&null!==r){switch(r.$$typeof){case j:return e=e.get(null===r.key?n:r.key)||null,r.type===k?p(t,e,r.props.children,i,r.key):c(t,e,r,i);case O:return u(t,e=e.get(null===r.key?n:r.key)||null,r,i)}if(Oo(r)||H(r))return p(t,e=e.get(n)||null,r,i,null);_o(t,r)}return null}function m(i,a,l,s){for(var c=null,u=null,p=a,m=a=0,g=null;null!==p&&m<l.length;m++){p.index>m?(g=p,p=null):g=p.sibling;var b=f(i,p,l[m],s);if(null===b){null===p&&(p=g);break}e&&p&&null===b.alternate&&t(i,p),a=o(b,a,m),null===u?c=b:u.sibling=b,u=b,p=g}if(m===l.length)return n(i,p),c;if(null===p){for(;m<l.length;m++)null!==(p=d(i,l[m],s))&&(a=o(p,a,m),null===u?c=p:u.sibling=p,u=p);return c}for(p=r(i,p);m<l.length;m++)null!==(g=h(p,i,m,l[m],s))&&(e&&null!==g.alternate&&p.delete(null===g.key?m:g.key),a=o(g,a,m),null===u?c=g:u.sibling=g,u=g);return e&&p.forEach((function(e){return t(i,e)})),c}function g(i,l,s,c){var u=H(s);if("function"!==typeof u)throw Error(a(150));if(null==(s=u.call(s)))throw Error(a(151));for(var p=u=null,m=l,g=l=0,b=null,v=s.next();null!==m&&!v.done;g++,v=s.next()){m.index>g?(b=m,m=null):b=m.sibling;var y=f(i,m,v.value,c);if(null===y){null===m&&(m=b);break}e&&m&&null===y.alternate&&t(i,m),l=o(y,l,g),null===p?u=y:p.sibling=y,p=y,m=b}if(v.done)return n(i,m),u;if(null===m){for(;!v.done;g++,v=s.next())null!==(v=d(i,v.value,c))&&(l=o(v,l,g),null===p?u=v:p.sibling=v,p=v);return u}for(m=r(i,m);!v.done;g++,v=s.next())null!==(v=h(m,i,g,v.value,c))&&(e&&null!==v.alternate&&m.delete(null===v.key?g:v.key),l=o(v,l,g),null===p?u=v:p.sibling=v,p=v);return e&&m.forEach((function(e){return t(i,e)})),u}return function(e,r,o,s){var c="object"===typeof o&&null!==o&&o.type===k&&null===o.key;c&&(o=o.props.children);var u="object"===typeof o&&null!==o;if(u)switch(o.$$typeof){case j:e:{for(u=o.key,c=r;null!==c;){if(c.key===u){if(7===c.tag){if(o.type===k){n(e,c.sibling),(r=i(c,o.props.children)).return=e,e=r;break e}}else if(c.elementType===o.type){n(e,c.sibling),(r=i(c,o.props)).ref=ko(e,c,o),r.return=e,e=r;break e}n(e,c);break}t(e,c),c=c.sibling}o.type===k?((r=Ys(o.props.children,e.mode,s,o.key)).return=e,e=r):((s=Vs(o.type,o.key,o.props,null,e.mode,s)).ref=ko(e,r,o),s.return=e,e=s)}return l(e);case O:e:{for(c=o.key;null!==r;){if(r.key===c){if(4===r.tag&&r.stateNode.containerInfo===o.containerInfo&&r.stateNode.implementation===o.implementation){n(e,r.sibling),(r=i(r,o.children||[])).return=e,e=r;break e}n(e,r);break}t(e,r),r=r.sibling}(r=Js(o,e.mode,s)).return=e,e=r}return l(e)}if("string"===typeof o||"number"===typeof o)return o=""+o,null!==r&&6===r.tag?(n(e,r.sibling),(r=i(r,o)).return=e,e=r):(n(e,r),(r=Gs(o,e.mode,s)).return=e,e=r),l(e);if(Oo(o))return m(e,r,o,s);if(H(o))return g(e,r,o,s);if(u&&_o(e,o),"undefined"===typeof o&&!c)switch(e.tag){case 1:case 22:case 0:case 11:case 15:throw Error(a(152,V(e.type)||"Component"))}return n(e,r)}}var Po=So(!0),Eo=So(!1),Co={},No=ci(Co),To=ci(Co),Io=ci(Co);function Lo(e){if(e===Co)throw Error(a(174));return e}function Mo(e,t){switch(pi(Io,t),pi(To,e),pi(No,Co),e=t.nodeType){case 9:case 11:t=(t=t.documentElement)?t.namespaceURI:he(null,"");break;default:t=he(t=(e=8===e?t.parentNode:t).namespaceURI||null,e=e.tagName)}ui(No),pi(No,t)}function Fo(){ui(No),ui(To),ui(Io)}function Do(e){Lo(Io.current);var t=Lo(No.current),n=he(t,e.type);t!==n&&(pi(To,e),pi(No,n))}function zo(e){To.current===e&&(ui(No),ui(To))}var Ro=ci(0);function Uo(e){for(var t=e;null!==t;){if(13===t.tag){var n=t.memoizedState;if(null!==n&&(null===(n=n.dehydrated)||"$?"===n.data||"$!"===n.data))return t}else if(19===t.tag&&void 0!==t.memoizedProps.revealOrder){if(0!==(64&t.flags))return t}else if(null!==t.child){t.child.return=t,t=t.child;continue}if(t===e)break;for(;null===t.sibling;){if(null===t.return||t.return===e)return null;t=t.return}t.sibling.return=t.return,t=t.sibling}return null}var Ao=null,Bo=null,Ho=!1;function qo(e,t){var n=$s(5,null,null,0);n.elementType="DELETED",n.type="DELETED",n.stateNode=t,n.return=e,n.flags=8,null!==e.lastEffect?(e.lastEffect.nextEffect=n,e.lastEffect=n):e.firstEffect=e.lastEffect=n}function $o(e,t){switch(e.tag){case 5:var n=e.type;return null!==(t=1!==t.nodeType||n.toLowerCase()!==t.nodeName.toLowerCase()?null:t)&&(e.stateNode=t,!0);case 6:return null!==(t=""===e.pendingProps||3!==t.nodeType?null:t)&&(e.stateNode=t,!0);default:return!1}}function Wo(e){if(Ho){var t=Bo;if(t){var n=t;if(!$o(e,t)){if(!(t=Yr(n.nextSibling))||!$o(e,t))return e.flags=-1025&e.flags|2,Ho=!1,void(Ao=e);qo(Ao,n)}Ao=e,Bo=Yr(t.firstChild)}else e.flags=-1025&e.flags|2,Ho=!1,Ao=e}}function Qo(e){for(e=e.return;null!==e&&5!==e.tag&&3!==e.tag&&13!==e.tag;)e=e.return;Ao=e}function Vo(e){if(e!==Ao)return!1;if(!Ho)return Qo(e),Ho=!0,!1;var t=e.type;if(5!==e.tag||"head"!==t&&"body"!==t&&!$r(t,e.memoizedProps))for(t=Bo;t;)qo(e,t),t=Yr(t.nextSibling);if(Qo(e),13===e.tag){if(!(e=null!==(e=e.memoizedState)?e.dehydrated:null))throw Error(a(317));e:{for(e=e.nextSibling,t=0;e;){if(8===e.nodeType){var n=e.data;if("/$"===n){if(0===t){Bo=Yr(e.nextSibling);break e}t--}else"$"!==n&&"$!"!==n&&"$?"!==n||t++}e=e.nextSibling}Bo=null}}else Bo=Ao?Yr(e.stateNode.nextSibling):null;return!0}function Yo(){Bo=Ao=null,Ho=!1}var Ko=[];function Go(){for(var e=0;e<Ko.length;e++)Ko[e]._workInProgressVersionPrimary=null;Ko.length=0}var Jo=w.ReactCurrentDispatcher,Xo=w.ReactCurrentBatchConfig,Zo=0,ea=null,ta=null,na=null,ra=!1,ia=!1;function oa(){throw Error(a(321))}function aa(e,t){if(null===t)return!1;for(var n=0;n<t.length&&n<e.length;n++)if(!ur(e[n],t[n]))return!1;return!0}function la(e,t,n,r,i,o){if(Zo=o,ea=t,t.memoizedState=null,t.updateQueue=null,t.lanes=0,Jo.current=null===e||null===e.memoizedState?La:Ma,e=n(r,i),ia){o=0;do{if(ia=!1,!(25>o))throw Error(a(301));o+=1,na=ta=null,t.updateQueue=null,Jo.current=Fa,e=n(r,i)}while(ia)}if(Jo.current=Ia,t=null!==ta&&null!==ta.next,Zo=0,na=ta=ea=null,ra=!1,t)throw Error(a(300));return e}function sa(){var e={memoizedState:null,baseState:null,baseQueue:null,queue:null,next:null};return null===na?ea.memoizedState=na=e:na=na.next=e,na}function ca(){if(null===ta){var e=ea.alternate;e=null!==e?e.memoizedState:null}else e=ta.next;var t=null===na?ea.memoizedState:na.next;if(null!==t)na=t,ta=e;else{if(null===e)throw Error(a(310));e={memoizedState:(ta=e).memoizedState,baseState:ta.baseState,baseQueue:ta.baseQueue,queue:ta.queue,next:null},null===na?ea.memoizedState=na=e:na=na.next=e}return na}function ua(e,t){return"function"===typeof t?t(e):t}function pa(e){var t=ca(),n=t.queue;if(null===n)throw Error(a(311));n.lastRenderedReducer=e;var r=ta,i=r.baseQueue,o=n.pending;if(null!==o){if(null!==i){var l=i.next;i.next=o.next,o.next=l}r.baseQueue=i=o,n.pending=null}if(null!==i){i=i.next,r=r.baseState;var s=l=o=null,c=i;do{var u=c.lane;if((Zo&u)===u)null!==s&&(s=s.next={lane:0,action:c.action,eagerReducer:c.eagerReducer,eagerState:c.eagerState,next:null}),r=c.eagerReducer===e?c.eagerState:e(r,c.action);else{var p={lane:u,action:c.action,eagerReducer:c.eagerReducer,eagerState:c.eagerState,next:null};null===s?(l=s=p,o=r):s=s.next=p,ea.lanes|=u,Bl|=u}c=c.next}while(null!==c&&c!==i);null===s?o=r:s.next=l,ur(r,t.memoizedState)||(za=!0),t.memoizedState=r,t.baseState=o,t.baseQueue=s,n.lastRenderedState=r}return[t.memoizedState,n.dispatch]}function da(e){var t=ca(),n=t.queue;if(null===n)throw Error(a(311));n.lastRenderedReducer=e;var r=n.dispatch,i=n.pending,o=t.memoizedState;if(null!==i){n.pending=null;var l=i=i.next;do{o=e(o,l.action),l=l.next}while(l!==i);ur(o,t.memoizedState)||(za=!0),t.memoizedState=o,null===t.baseQueue&&(t.baseState=o),n.lastRenderedState=o}return[o,r]}function fa(e,t,n){var r=t._getVersion;r=r(t._source);var i=t._workInProgressVersionPrimary;if(null!==i?e=i===r:(e=e.mutableReadLanes,(e=(Zo&e)===e)&&(t._workInProgressVersionPrimary=r,Ko.push(t))),e)return n(t._source);throw Ko.push(t),Error(a(350))}function ha(e,t,n,r){var i=Ll;if(null===i)throw Error(a(349));var o=t._getVersion,l=o(t._source),s=Jo.current,c=s.useState((function(){return fa(i,t,n)})),u=c[1],p=c[0];c=na;var d=e.memoizedState,f=d.refs,h=f.getSnapshot,m=d.source;d=d.subscribe;var g=ea;return e.memoizedState={refs:f,source:t,subscribe:r},s.useEffect((function(){f.getSnapshot=n,f.setSnapshot=u;var e=o(t._source);if(!ur(l,e)){e=n(t._source),ur(p,e)||(u(e),e=fs(g),i.mutableReadLanes|=e&i.pendingLanes),e=i.mutableReadLanes,i.entangledLanes|=e;for(var r=i.entanglements,a=e;0<a;){var s=31-$t(a),c=1<<s;r[s]|=e,a&=~c}}}),[n,t,r]),s.useEffect((function(){return r(t._source,(function(){var e=f.getSnapshot,n=f.setSnapshot;try{n(e(t._source));var r=fs(g);i.mutableReadLanes|=r&i.pendingLanes}catch(o){n((function(){throw o}))}}))}),[t,r]),ur(h,n)&&ur(m,t)&&ur(d,r)||((e={pending:null,dispatch:null,lastRenderedReducer:ua,lastRenderedState:p}).dispatch=u=Ta.bind(null,ea,e),c.queue=e,c.baseQueue=null,p=fa(i,t,n),c.memoizedState=c.baseState=p),p}function ma(e,t,n){return ha(ca(),e,t,n)}function ga(e){var t=sa();return"function"===typeof e&&(e=e()),t.memoizedState=t.baseState=e,e=(e=t.queue={pending:null,dispatch:null,lastRenderedReducer:ua,lastRenderedState:e}).dispatch=Ta.bind(null,ea,e),[t.memoizedState,e]}function ba(e,t,n,r){return e={tag:e,create:t,destroy:n,deps:r,next:null},null===(t=ea.updateQueue)?(t={lastEffect:null},ea.updateQueue=t,t.lastEffect=e.next=e):null===(n=t.lastEffect)?t.lastEffect=e.next=e:(r=n.next,n.next=e,e.next=r,t.lastEffect=e),e}function va(e){return e={current:e},sa().memoizedState=e}function ya(){return ca().memoizedState}function xa(e,t,n,r){var i=sa();ea.flags|=e,i.memoizedState=ba(1|t,n,void 0,void 0===r?null:r)}function wa(e,t,n,r){var i=ca();r=void 0===r?null:r;var o=void 0;if(null!==ta){var a=ta.memoizedState;if(o=a.destroy,null!==r&&aa(r,a.deps))return void ba(t,n,o,r)}ea.flags|=e,i.memoizedState=ba(1|t,n,o,r)}function ja(e,t){return xa(516,4,e,t)}function Oa(e,t){return wa(516,4,e,t)}function ka(e,t){return wa(4,2,e,t)}function _a(e,t){return"function"===typeof t?(e=e(),t(e),function(){t(null)}):null!==t&&void 0!==t?(e=e(),t.current=e,function(){t.current=null}):void 0}function Sa(e,t,n){return n=null!==n&&void 0!==n?n.concat([e]):null,wa(4,2,_a.bind(null,t,e),n)}function Pa(){}function Ea(e,t){var n=ca();t=void 0===t?null:t;var r=n.memoizedState;return null!==r&&null!==t&&aa(t,r[1])?r[0]:(n.memoizedState=[e,t],e)}function Ca(e,t){var n=ca();t=void 0===t?null:t;var r=n.memoizedState;return null!==r&&null!==t&&aa(t,r[1])?r[0]:(e=e(),n.memoizedState=[e,t],e)}function Na(e,t){var n=$i();Qi(98>n?98:n,(function(){e(!0)})),Qi(97<n?97:n,(function(){var n=Xo.transition;Xo.transition=1;try{e(!1),t()}finally{Xo.transition=n}}))}function Ta(e,t,n){var r=ds(),i=fs(e),o={lane:i,action:n,eagerReducer:null,eagerState:null,next:null},a=t.pending;if(null===a?o.next=o:(o.next=a.next,a.next=o),t.pending=o,a=e.alternate,e===ea||null!==a&&a===ea)ia=ra=!0;else{if(0===e.lanes&&(null===a||0===a.lanes)&&null!==(a=t.lastRenderedReducer))try{var l=t.lastRenderedState,s=a(l,n);if(o.eagerReducer=a,o.eagerState=s,ur(s,l))return}catch(c){}hs(e,i,r)}}var Ia={readContext:ao,useCallback:oa,useContext:oa,useEffect:oa,useImperativeHandle:oa,useLayoutEffect:oa,useMemo:oa,useReducer:oa,useRef:oa,useState:oa,useDebugValue:oa,useDeferredValue:oa,useTransition:oa,useMutableSource:oa,useOpaqueIdentifier:oa,unstable_isNewReconciler:!1},La={readContext:ao,useCallback:function(e,t){return sa().memoizedState=[e,void 0===t?null:t],e},useContext:ao,useEffect:ja,useImperativeHandle:function(e,t,n){return n=null!==n&&void 0!==n?n.concat([e]):null,xa(4,2,_a.bind(null,t,e),n)},useLayoutEffect:function(e,t){return xa(4,2,e,t)},useMemo:function(e,t){var n=sa();return t=void 0===t?null:t,e=e(),n.memoizedState=[e,t],e},useReducer:function(e,t,n){var r=sa();return t=void 0!==n?n(t):t,r.memoizedState=r.baseState=t,e=(e=r.queue={pending:null,dispatch:null,lastRenderedReducer:e,lastRenderedState:t}).dispatch=Ta.bind(null,ea,e),[r.memoizedState,e]},useRef:va,useState:ga,useDebugValue:Pa,useDeferredValue:function(e){var t=ga(e),n=t[0],r=t[1];return ja((function(){var t=Xo.transition;Xo.transition=1;try{r(e)}finally{Xo.transition=t}}),[e]),n},useTransition:function(){var e=ga(!1),t=e[0];return va(e=Na.bind(null,e[1])),[e,t]},useMutableSource:function(e,t,n){var r=sa();return r.memoizedState={refs:{getSnapshot:t,setSnapshot:null},source:e,subscribe:n},ha(r,e,t,n)},useOpaqueIdentifier:function(){if(Ho){var e=!1,t=function(e){return{$$typeof:F,toString:e,valueOf:e}}((function(){throw e||(e=!0,n("r:"+(Gr++).toString(36))),Error(a(355))})),n=ga(t)[1];return 0===(2&ea.mode)&&(ea.flags|=516,ba(5,(function(){n("r:"+(Gr++).toString(36))}),void 0,null)),t}return ga(t="r:"+(Gr++).toString(36)),t},unstable_isNewReconciler:!1},Ma={readContext:ao,useCallback:Ea,useContext:ao,useEffect:Oa,useImperativeHandle:Sa,useLayoutEffect:ka,useMemo:Ca,useReducer:pa,useRef:ya,useState:function(){return pa(ua)},useDebugValue:Pa,useDeferredValue:function(e){var t=pa(ua),n=t[0],r=t[1];return Oa((function(){var t=Xo.transition;Xo.transition=1;try{r(e)}finally{Xo.transition=t}}),[e]),n},useTransition:function(){var e=pa(ua)[0];return[ya().current,e]},useMutableSource:ma,useOpaqueIdentifier:function(){return pa(ua)[0]},unstable_isNewReconciler:!1},Fa={readContext:ao,useCallback:Ea,useContext:ao,useEffect:Oa,useImperativeHandle:Sa,useLayoutEffect:ka,useMemo:Ca,useReducer:da,useRef:ya,useState:function(){return da(ua)},useDebugValue:Pa,useDeferredValue:function(e){var t=da(ua),n=t[0],r=t[1];return Oa((function(){var t=Xo.transition;Xo.transition=1;try{r(e)}finally{Xo.transition=t}}),[e]),n},useTransition:function(){var e=da(ua)[0];return[ya().current,e]},useMutableSource:ma,useOpaqueIdentifier:function(){return da(ua)[0]},unstable_isNewReconciler:!1},Da=w.ReactCurrentOwner,za=!1;function Ra(e,t,n,r){t.child=null===e?Eo(t,null,n,r):Po(t,e.child,n,r)}function Ua(e,t,n,r,i){n=n.render;var o=t.ref;return oo(t,i),r=la(e,t,n,r,o,i),null===e||za?(t.flags|=1,Ra(e,t,r,i),t.child):(t.updateQueue=e.updateQueue,t.flags&=-517,e.lanes&=~i,ol(e,t,i))}function Aa(e,t,n,r,i,o){if(null===e){var a=n.type;return"function"!==typeof a||Ws(a)||void 0!==a.defaultProps||null!==n.compare||void 0!==n.defaultProps?((e=Vs(n.type,null,r,t,t.mode,o)).ref=t.ref,e.return=t,t.child=e):(t.tag=15,t.type=a,Ba(e,t,a,r,i,o))}return a=e.child,0===(i&o)&&(i=a.memoizedProps,(n=null!==(n=n.compare)?n:dr)(i,r)&&e.ref===t.ref)?ol(e,t,o):(t.flags|=1,(e=Qs(a,r)).ref=t.ref,e.return=t,t.child=e)}function Ba(e,t,n,r,i,o){if(null!==e&&dr(e.memoizedProps,r)&&e.ref===t.ref){if(za=!1,0===(o&i))return t.lanes=e.lanes,ol(e,t,o);0!==(16384&e.flags)&&(za=!0)}return $a(e,t,n,r,o)}function Ha(e,t,n){var r=t.pendingProps,i=r.children,o=null!==e?e.memoizedState:null;if("hidden"===r.mode||"unstable-defer-without-hiding"===r.mode)if(0===(4&t.mode))t.memoizedState={baseLanes:0},js(t,n);else{if(0===(1073741824&n))return e=null!==o?o.baseLanes|n:n,t.lanes=t.childLanes=1073741824,t.memoizedState={baseLanes:e},js(t,e),null;t.memoizedState={baseLanes:0},js(t,null!==o?o.baseLanes:n)}else null!==o?(r=o.baseLanes|n,t.memoizedState=null):r=n,js(t,r);return Ra(e,t,i,n),t.child}function qa(e,t){var n=t.ref;(null===e&&null!==n||null!==e&&e.ref!==n)&&(t.flags|=128)}function $a(e,t,n,r,i){var o=bi(n)?mi:fi.current;return o=gi(t,o),oo(t,i),n=la(e,t,n,r,o,i),null===e||za?(t.flags|=1,Ra(e,t,n,i),t.child):(t.updateQueue=e.updateQueue,t.flags&=-517,e.lanes&=~i,ol(e,t,i))}function Wa(e,t,n,r,i){if(bi(n)){var o=!0;wi(t)}else o=!1;if(oo(t,i),null===t.stateNode)null!==e&&(e.alternate=null,t.alternate=null,t.flags|=2),xo(t,n,r),jo(t,n,r,i),r=!0;else if(null===e){var a=t.stateNode,l=t.memoizedProps;a.props=l;var s=a.context,c=n.contextType;"object"===typeof c&&null!==c?c=ao(c):c=gi(t,c=bi(n)?mi:fi.current);var u=n.getDerivedStateFromProps,p="function"===typeof u||"function"===typeof a.getSnapshotBeforeUpdate;p||"function"!==typeof a.UNSAFE_componentWillReceiveProps&&"function"!==typeof a.componentWillReceiveProps||(l!==r||s!==c)&&wo(t,a,r,c),lo=!1;var d=t.memoizedState;a.state=d,ho(t,r,a,i),s=t.memoizedState,l!==r||d!==s||hi.current||lo?("function"===typeof u&&(bo(t,n,u,r),s=t.memoizedState),(l=lo||yo(t,n,l,r,d,s,c))?(p||"function"!==typeof a.UNSAFE_componentWillMount&&"function"!==typeof a.componentWillMount||("function"===typeof a.componentWillMount&&a.componentWillMount(),"function"===typeof a.UNSAFE_componentWillMount&&a.UNSAFE_componentWillMount()),"function"===typeof a.componentDidMount&&(t.flags|=4)):("function"===typeof a.componentDidMount&&(t.flags|=4),t.memoizedProps=r,t.memoizedState=s),a.props=r,a.state=s,a.context=c,r=l):("function"===typeof a.componentDidMount&&(t.flags|=4),r=!1)}else{a=t.stateNode,co(e,t),l=t.memoizedProps,c=t.type===t.elementType?l:Ji(t.type,l),a.props=c,p=t.pendingProps,d=a.context,"object"===typeof(s=n.contextType)&&null!==s?s=ao(s):s=gi(t,s=bi(n)?mi:fi.current);var f=n.getDerivedStateFromProps;(u="function"===typeof f||"function"===typeof a.getSnapshotBeforeUpdate)||"function"!==typeof a.UNSAFE_componentWillReceiveProps&&"function"!==typeof a.componentWillReceiveProps||(l!==p||d!==s)&&wo(t,a,r,s),lo=!1,d=t.memoizedState,a.state=d,ho(t,r,a,i);var h=t.memoizedState;l!==p||d!==h||hi.current||lo?("function"===typeof f&&(bo(t,n,f,r),h=t.memoizedState),(c=lo||yo(t,n,c,r,d,h,s))?(u||"function"!==typeof a.UNSAFE_componentWillUpdate&&"function"!==typeof a.componentWillUpdate||("function"===typeof a.componentWillUpdate&&a.componentWillUpdate(r,h,s),"function"===typeof a.UNSAFE_componentWillUpdate&&a.UNSAFE_componentWillUpdate(r,h,s)),"function"===typeof a.componentDidUpdate&&(t.flags|=4),"function"===typeof a.getSnapshotBeforeUpdate&&(t.flags|=256)):("function"!==typeof a.componentDidUpdate||l===e.memoizedProps&&d===e.memoizedState||(t.flags|=4),"function"!==typeof a.getSnapshotBeforeUpdate||l===e.memoizedProps&&d===e.memoizedState||(t.flags|=256),t.memoizedProps=r,t.memoizedState=h),a.props=r,a.state=h,a.context=s,r=c):("function"!==typeof a.componentDidUpdate||l===e.memoizedProps&&d===e.memoizedState||(t.flags|=4),"function"!==typeof a.getSnapshotBeforeUpdate||l===e.memoizedProps&&d===e.memoizedState||(t.flags|=256),r=!1)}return Qa(e,t,n,r,o,i)}function Qa(e,t,n,r,i,o){qa(e,t);var a=0!==(64&t.flags);if(!r&&!a)return i&&ji(t,n,!1),ol(e,t,o);r=t.stateNode,Da.current=t;var l=a&&"function"!==typeof n.getDerivedStateFromError?null:r.render();return t.flags|=1,null!==e&&a?(t.child=Po(t,e.child,null,o),t.child=Po(t,null,l,o)):Ra(e,t,l,o),t.memoizedState=r.state,i&&ji(t,n,!0),t.child}function Va(e){var t=e.stateNode;t.pendingContext?yi(0,t.pendingContext,t.pendingContext!==t.context):t.context&&yi(0,t.context,!1),Mo(e,t.containerInfo)}var Ya,Ka,Ga,Ja={dehydrated:null,retryLane:0};function Xa(e,t,n){var r,i=t.pendingProps,o=Ro.current,a=!1;return(r=0!==(64&t.flags))||(r=(null===e||null!==e.memoizedState)&&0!==(2&o)),r?(a=!0,t.flags&=-65):null!==e&&null===e.memoizedState||void 0===i.fallback||!0===i.unstable_avoidThisFallback||(o|=1),pi(Ro,1&o),null===e?(void 0!==i.fallback&&Wo(t),e=i.children,o=i.fallback,a?(e=Za(t,e,o,n),t.child.memoizedState={baseLanes:n},t.memoizedState=Ja,e):"number"===typeof i.unstable_expectedLoadTime?(e=Za(t,e,o,n),t.child.memoizedState={baseLanes:n},t.memoizedState=Ja,t.lanes=33554432,e):((n=Ks({mode:"visible",children:e},t.mode,n,null)).return=t,t.child=n)):(e.memoizedState,a?(i=tl(e,t,i.children,i.fallback,n),a=t.child,o=e.child.memoizedState,a.memoizedState=null===o?{baseLanes:n}:{baseLanes:o.baseLanes|n},a.childLanes=e.childLanes&~n,t.memoizedState=Ja,i):(n=el(e,t,i.children,n),t.memoizedState=null,n))}function Za(e,t,n,r){var i=e.mode,o=e.child;return t={mode:"hidden",children:t},0===(2&i)&&null!==o?(o.childLanes=0,o.pendingProps=t):o=Ks(t,i,0,null),n=Ys(n,i,r,null),o.return=e,n.return=e,o.sibling=n,e.child=o,n}function el(e,t,n,r){var i=e.child;return e=i.sibling,n=Qs(i,{mode:"visible",children:n}),0===(2&t.mode)&&(n.lanes=r),n.return=t,n.sibling=null,null!==e&&(e.nextEffect=null,e.flags=8,t.firstEffect=t.lastEffect=e),t.child=n}function tl(e,t,n,r,i){var o=t.mode,a=e.child;e=a.sibling;var l={mode:"hidden",children:n};return 0===(2&o)&&t.child!==a?((n=t.child).childLanes=0,n.pendingProps=l,null!==(a=n.lastEffect)?(t.firstEffect=n.firstEffect,t.lastEffect=a,a.nextEffect=null):t.firstEffect=t.lastEffect=null):n=Qs(a,l),null!==e?r=Qs(e,r):(r=Ys(r,o,i,null)).flags|=2,r.return=t,n.return=t,n.sibling=r,t.child=n,r}function nl(e,t){e.lanes|=t;var n=e.alternate;null!==n&&(n.lanes|=t),io(e.return,t)}function rl(e,t,n,r,i,o){var a=e.memoizedState;null===a?e.memoizedState={isBackwards:t,rendering:null,renderingStartTime:0,last:r,tail:n,tailMode:i,lastEffect:o}:(a.isBackwards=t,a.rendering=null,a.renderingStartTime=0,a.last=r,a.tail=n,a.tailMode=i,a.lastEffect=o)}function il(e,t,n){var r=t.pendingProps,i=r.revealOrder,o=r.tail;if(Ra(e,t,r.children,n),0!==(2&(r=Ro.current)))r=1&r|2,t.flags|=64;else{if(null!==e&&0!==(64&e.flags))e:for(e=t.child;null!==e;){if(13===e.tag)null!==e.memoizedState&&nl(e,n);else if(19===e.tag)nl(e,n);else if(null!==e.child){e.child.return=e,e=e.child;continue}if(e===t)break e;for(;null===e.sibling;){if(null===e.return||e.return===t)break e;e=e.return}e.sibling.return=e.return,e=e.sibling}r&=1}if(pi(Ro,r),0===(2&t.mode))t.memoizedState=null;else switch(i){case"forwards":for(n=t.child,i=null;null!==n;)null!==(e=n.alternate)&&null===Uo(e)&&(i=n),n=n.sibling;null===(n=i)?(i=t.child,t.child=null):(i=n.sibling,n.sibling=null),rl(t,!1,i,n,o,t.lastEffect);break;case"backwards":for(n=null,i=t.child,t.child=null;null!==i;){if(null!==(e=i.alternate)&&null===Uo(e)){t.child=i;break}e=i.sibling,i.sibling=n,n=i,i=e}rl(t,!0,n,null,o,t.lastEffect);break;case"together":rl(t,!1,null,null,void 0,t.lastEffect);break;default:t.memoizedState=null}return t.child}function ol(e,t,n){if(null!==e&&(t.dependencies=e.dependencies),Bl|=t.lanes,0!==(n&t.childLanes)){if(null!==e&&t.child!==e.child)throw Error(a(153));if(null!==t.child){for(n=Qs(e=t.child,e.pendingProps),t.child=n,n.return=t;null!==e.sibling;)e=e.sibling,(n=n.sibling=Qs(e,e.pendingProps)).return=t;n.sibling=null}return t.child}return null}function al(e,t){if(!Ho)switch(e.tailMode){case"hidden":t=e.tail;for(var n=null;null!==t;)null!==t.alternate&&(n=t),t=t.sibling;null===n?e.tail=null:n.sibling=null;break;case"collapsed":n=e.tail;for(var r=null;null!==n;)null!==n.alternate&&(r=n),n=n.sibling;null===r?t||null===e.tail?e.tail=null:e.tail.sibling=null:r.sibling=null}}function ll(e,t,n){var r=t.pendingProps;switch(t.tag){case 2:case 16:case 15:case 0:case 11:case 7:case 8:case 12:case 9:case 14:return null;case 1:case 17:return bi(t.type)&&vi(),null;case 3:return Fo(),ui(hi),ui(fi),Go(),(r=t.stateNode).pendingContext&&(r.context=r.pendingContext,r.pendingContext=null),null!==e&&null!==e.child||(Vo(t)?t.flags|=4:r.hydrate||(t.flags|=256)),null;case 5:zo(t);var o=Lo(Io.current);if(n=t.type,null!==e&&null!=t.stateNode)Ka(e,t,n,r),e.ref!==t.ref&&(t.flags|=128);else{if(!r){if(null===t.stateNode)throw Error(a(166));return null}if(e=Lo(No.current),Vo(t)){r=t.stateNode,n=t.type;var l=t.memoizedProps;switch(r[Xr]=t,r[Zr]=l,n){case"dialog":Nr("cancel",r),Nr("close",r);break;case"iframe":case"object":case"embed":Nr("load",r);break;case"video":case"audio":for(e=0;e<Sr.length;e++)Nr(Sr[e],r);break;case"source":Nr("error",r);break;case"img":case"image":case"link":Nr("error",r),Nr("load",r);break;case"details":Nr("toggle",r);break;case"input":ee(r,l),Nr("invalid",r);break;case"select":r._wrapperState={wasMultiple:!!l.multiple},Nr("invalid",r);break;case"textarea":se(r,l),Nr("invalid",r)}for(var c in ke(n,l),e=null,l)l.hasOwnProperty(c)&&(o=l[c],"children"===c?"string"===typeof o?r.textContent!==o&&(e=["children",o]):"number"===typeof o&&r.textContent!==""+o&&(e=["children",""+o]):s.hasOwnProperty(c)&&null!=o&&"onScroll"===c&&Nr("scroll",r));switch(n){case"input":G(r),re(r,l,!0);break;case"textarea":G(r),ue(r);break;case"select":case"option":break;default:"function"===typeof l.onClick&&(r.onclick=Ar)}r=e,t.updateQueue=r,null!==r&&(t.flags|=4)}else{switch(c=9===o.nodeType?o:o.ownerDocument,e===pe&&(e=fe(n)),e===pe?"script"===n?((e=c.createElement("div")).innerHTML="<script><\/script>",e=e.removeChild(e.firstChild)):"string"===typeof r.is?e=c.createElement(n,{is:r.is}):(e=c.createElement(n),"select"===n&&(c=e,r.multiple?c.multiple=!0:r.size&&(c.size=r.size))):e=c.createElementNS(e,n),e[Xr]=t,e[Zr]=r,Ya(e,t),t.stateNode=e,c=_e(n,r),n){case"dialog":Nr("cancel",e),Nr("close",e),o=r;break;case"iframe":case"object":case"embed":Nr("load",e),o=r;break;case"video":case"audio":for(o=0;o<Sr.length;o++)Nr(Sr[o],e);o=r;break;case"source":Nr("error",e),o=r;break;case"img":case"image":case"link":Nr("error",e),Nr("load",e),o=r;break;case"details":Nr("toggle",e),o=r;break;case"input":ee(e,r),o=Z(e,r),Nr("invalid",e);break;case"option":o=oe(e,r);break;case"select":e._wrapperState={wasMultiple:!!r.multiple},o=i({},r,{value:void 0}),Nr("invalid",e);break;case"textarea":se(e,r),o=le(e,r),Nr("invalid",e);break;default:o=r}ke(n,o);var u=o;for(l in u)if(u.hasOwnProperty(l)){var p=u[l];"style"===l?je(e,p):"dangerouslySetInnerHTML"===l?null!=(p=p?p.__html:void 0)&&be(e,p):"children"===l?"string"===typeof p?("textarea"!==n||""!==p)&&ve(e,p):"number"===typeof p&&ve(e,""+p):"suppressContentEditableWarning"!==l&&"suppressHydrationWarning"!==l&&"autoFocus"!==l&&(s.hasOwnProperty(l)?null!=p&&"onScroll"===l&&Nr("scroll",e):null!=p&&x(e,l,p,c))}switch(n){case"input":G(e),re(e,r,!1);break;case"textarea":G(e),ue(e);break;case"option":null!=r.value&&e.setAttribute("value",""+Y(r.value));break;case"select":e.multiple=!!r.multiple,null!=(l=r.value)?ae(e,!!r.multiple,l,!1):null!=r.defaultValue&&ae(e,!!r.multiple,r.defaultValue,!0);break;default:"function"===typeof o.onClick&&(e.onclick=Ar)}qr(n,r)&&(t.flags|=4)}null!==t.ref&&(t.flags|=128)}return null;case 6:if(e&&null!=t.stateNode)Ga(0,t,e.memoizedProps,r);else{if("string"!==typeof r&&null===t.stateNode)throw Error(a(166));n=Lo(Io.current),Lo(No.current),Vo(t)?(r=t.stateNode,n=t.memoizedProps,r[Xr]=t,r.nodeValue!==n&&(t.flags|=4)):((r=(9===n.nodeType?n:n.ownerDocument).createTextNode(r))[Xr]=t,t.stateNode=r)}return null;case 13:return ui(Ro),r=t.memoizedState,0!==(64&t.flags)?(t.lanes=n,t):(r=null!==r,n=!1,null===e?void 0!==t.memoizedProps.fallback&&Vo(t):n=null!==e.memoizedState,r&&!n&&0!==(2&t.mode)&&(null===e&&!0!==t.memoizedProps.unstable_avoidThisFallback||0!==(1&Ro.current)?0===Rl&&(Rl=3):(0!==Rl&&3!==Rl||(Rl=4),null===Ll||0===(134217727&Bl)&&0===(134217727&Hl)||vs(Ll,Fl))),(r||n)&&(t.flags|=4),null);case 4:return Fo(),null===e&&Ir(t.stateNode.containerInfo),null;case 10:return ro(t),null;case 19:if(ui(Ro),null===(r=t.memoizedState))return null;if(l=0!==(64&t.flags),null===(c=r.rendering))if(l)al(r,!1);else{if(0!==Rl||null!==e&&0!==(64&e.flags))for(e=t.child;null!==e;){if(null!==(c=Uo(e))){for(t.flags|=64,al(r,!1),null!==(l=c.updateQueue)&&(t.updateQueue=l,t.flags|=4),null===r.lastEffect&&(t.firstEffect=null),t.lastEffect=r.lastEffect,r=n,n=t.child;null!==n;)e=r,(l=n).flags&=2,l.nextEffect=null,l.firstEffect=null,l.lastEffect=null,null===(c=l.alternate)?(l.childLanes=0,l.lanes=e,l.child=null,l.memoizedProps=null,l.memoizedState=null,l.updateQueue=null,l.dependencies=null,l.stateNode=null):(l.childLanes=c.childLanes,l.lanes=c.lanes,l.child=c.child,l.memoizedProps=c.memoizedProps,l.memoizedState=c.memoizedState,l.updateQueue=c.updateQueue,l.type=c.type,e=c.dependencies,l.dependencies=null===e?null:{lanes:e.lanes,firstContext:e.firstContext}),n=n.sibling;return pi(Ro,1&Ro.current|2),t.child}e=e.sibling}null!==r.tail&&qi()>Ql&&(t.flags|=64,l=!0,al(r,!1),t.lanes=33554432)}else{if(!l)if(null!==(e=Uo(c))){if(t.flags|=64,l=!0,null!==(n=e.updateQueue)&&(t.updateQueue=n,t.flags|=4),al(r,!0),null===r.tail&&"hidden"===r.tailMode&&!c.alternate&&!Ho)return null!==(t=t.lastEffect=r.lastEffect)&&(t.nextEffect=null),null}else 2*qi()-r.renderingStartTime>Ql&&1073741824!==n&&(t.flags|=64,l=!0,al(r,!1),t.lanes=33554432);r.isBackwards?(c.sibling=t.child,t.child=c):(null!==(n=r.last)?n.sibling=c:t.child=c,r.last=c)}return null!==r.tail?(n=r.tail,r.rendering=n,r.tail=n.sibling,r.lastEffect=t.lastEffect,r.renderingStartTime=qi(),n.sibling=null,t=Ro.current,pi(Ro,l?1&t|2:1&t),n):null;case 23:case 24:return Os(),null!==e&&null!==e.memoizedState!==(null!==t.memoizedState)&&"unstable-defer-without-hiding"!==r.mode&&(t.flags|=4),null}throw Error(a(156,t.tag))}function sl(e){switch(e.tag){case 1:bi(e.type)&&vi();var t=e.flags;return 4096&t?(e.flags=-4097&t|64,e):null;case 3:if(Fo(),ui(hi),ui(fi),Go(),0!==(64&(t=e.flags)))throw Error(a(285));return e.flags=-4097&t|64,e;case 5:return zo(e),null;case 13:return ui(Ro),4096&(t=e.flags)?(e.flags=-4097&t|64,e):null;case 19:return ui(Ro),null;case 4:return Fo(),null;case 10:return ro(e),null;case 23:case 24:return Os(),null;default:return null}}function cl(e,t){try{var n="",r=t;do{n+=Q(r),r=r.return}while(r);var i=n}catch(o){i="\nError generating stack: "+o.message+"\n"+o.stack}return{value:e,source:t,stack:i}}function ul(e,t){try{console.error(t.value)}catch(n){setTimeout((function(){throw n}))}}Ya=function(e,t){for(var n=t.child;null!==n;){if(5===n.tag||6===n.tag)e.appendChild(n.stateNode);else if(4!==n.tag&&null!==n.child){n.child.return=n,n=n.child;continue}if(n===t)break;for(;null===n.sibling;){if(null===n.return||n.return===t)return;n=n.return}n.sibling.return=n.return,n=n.sibling}},Ka=function(e,t,n,r){var o=e.memoizedProps;if(o!==r){e=t.stateNode,Lo(No.current);var a,l=null;switch(n){case"input":o=Z(e,o),r=Z(e,r),l=[];break;case"option":o=oe(e,o),r=oe(e,r),l=[];break;case"select":o=i({},o,{value:void 0}),r=i({},r,{value:void 0}),l=[];break;case"textarea":o=le(e,o),r=le(e,r),l=[];break;default:"function"!==typeof o.onClick&&"function"===typeof r.onClick&&(e.onclick=Ar)}for(p in ke(n,r),n=null,o)if(!r.hasOwnProperty(p)&&o.hasOwnProperty(p)&&null!=o[p])if("style"===p){var c=o[p];for(a in c)c.hasOwnProperty(a)&&(n||(n={}),n[a]="")}else"dangerouslySetInnerHTML"!==p&&"children"!==p&&"suppressContentEditableWarning"!==p&&"suppressHydrationWarning"!==p&&"autoFocus"!==p&&(s.hasOwnProperty(p)?l||(l=[]):(l=l||[]).push(p,null));for(p in r){var u=r[p];if(c=null!=o?o[p]:void 0,r.hasOwnProperty(p)&&u!==c&&(null!=u||null!=c))if("style"===p)if(c){for(a in c)!c.hasOwnProperty(a)||u&&u.hasOwnProperty(a)||(n||(n={}),n[a]="");for(a in u)u.hasOwnProperty(a)&&c[a]!==u[a]&&(n||(n={}),n[a]=u[a])}else n||(l||(l=[]),l.push(p,n)),n=u;else"dangerouslySetInnerHTML"===p?(u=u?u.__html:void 0,c=c?c.__html:void 0,null!=u&&c!==u&&(l=l||[]).push(p,u)):"children"===p?"string"!==typeof u&&"number"!==typeof u||(l=l||[]).push(p,""+u):"suppressContentEditableWarning"!==p&&"suppressHydrationWarning"!==p&&(s.hasOwnProperty(p)?(null!=u&&"onScroll"===p&&Nr("scroll",e),l||c===u||(l=[])):"object"===typeof u&&null!==u&&u.$$typeof===F?u.toString():(l=l||[]).push(p,u))}n&&(l=l||[]).push("style",n);var p=l;(t.updateQueue=p)&&(t.flags|=4)}},Ga=function(e,t,n,r){n!==r&&(t.flags|=4)};var pl="function"===typeof WeakMap?WeakMap:Map;function dl(e,t,n){(n=uo(-1,n)).tag=3,n.payload={element:null};var r=t.value;return n.callback=function(){Gl||(Gl=!0,Jl=r),ul(0,t)},n}function fl(e,t,n){(n=uo(-1,n)).tag=3;var r=e.type.getDerivedStateFromError;if("function"===typeof r){var i=t.value;n.payload=function(){return ul(0,t),r(i)}}var o=e.stateNode;return null!==o&&"function"===typeof o.componentDidCatch&&(n.callback=function(){"function"!==typeof r&&(null===Xl?Xl=new Set([this]):Xl.add(this),ul(0,t));var e=t.stack;this.componentDidCatch(t.value,{componentStack:null!==e?e:""})}),n}var hl="function"===typeof WeakSet?WeakSet:Set;function ml(e){var t=e.ref;if(null!==t)if("function"===typeof t)try{t(null)}catch(n){As(e,n)}else t.current=null}function gl(e,t){switch(t.tag){case 0:case 11:case 15:case 22:case 5:case 6:case 4:case 17:return;case 1:if(256&t.flags&&null!==e){var n=e.memoizedProps,r=e.memoizedState;t=(e=t.stateNode).getSnapshotBeforeUpdate(t.elementType===t.type?n:Ji(t.type,n),r),e.__reactInternalSnapshotBeforeUpdate=t}return;case 3:return void(256&t.flags&&Vr(t.stateNode.containerInfo))}throw Error(a(163))}function bl(e,t,n){switch(n.tag){case 0:case 11:case 15:case 22:if(null!==(t=null!==(t=n.updateQueue)?t.lastEffect:null)){e=t=t.next;do{if(3===(3&e.tag)){var r=e.create;e.destroy=r()}e=e.next}while(e!==t)}if(null!==(t=null!==(t=n.updateQueue)?t.lastEffect:null)){e=t=t.next;do{var i=e;r=i.next,0!==(4&(i=i.tag))&&0!==(1&i)&&(zs(n,e),Ds(n,e)),e=r}while(e!==t)}return;case 1:return e=n.stateNode,4&n.flags&&(null===t?e.componentDidMount():(r=n.elementType===n.type?t.memoizedProps:Ji(n.type,t.memoizedProps),e.componentDidUpdate(r,t.memoizedState,e.__reactInternalSnapshotBeforeUpdate))),void(null!==(t=n.updateQueue)&&mo(n,t,e));case 3:if(null!==(t=n.updateQueue)){if(e=null,null!==n.child)switch(n.child.tag){case 5:case 1:e=n.child.stateNode}mo(n,t,e)}return;case 5:return e=n.stateNode,void(null===t&&4&n.flags&&qr(n.type,n.memoizedProps)&&e.focus());case 6:case 4:case 12:case 19:case 17:case 20:case 21:case 23:case 24:return;case 13:return void(null===n.memoizedState&&(n=n.alternate,null!==n&&(n=n.memoizedState,null!==n&&(n=n.dehydrated,null!==n&&jt(n)))))}throw Error(a(163))}function vl(e,t){for(var n=e;;){if(5===n.tag){var r=n.stateNode;if(t)"function"===typeof(r=r.style).setProperty?r.setProperty("display","none","important"):r.display="none";else{r=n.stateNode;var i=n.memoizedProps.style;i=void 0!==i&&null!==i&&i.hasOwnProperty("display")?i.display:null,r.style.display=we("display",i)}}else if(6===n.tag)n.stateNode.nodeValue=t?"":n.memoizedProps;else if((23!==n.tag&&24!==n.tag||null===n.memoizedState||n===e)&&null!==n.child){n.child.return=n,n=n.child;continue}if(n===e)break;for(;null===n.sibling;){if(null===n.return||n.return===e)return;n=n.return}n.sibling.return=n.return,n=n.sibling}}function yl(e,t){if(ki&&"function"===typeof ki.onCommitFiberUnmount)try{ki.onCommitFiberUnmount(Oi,t)}catch(o){}switch(t.tag){case 0:case 11:case 14:case 15:case 22:if(null!==(e=t.updateQueue)&&null!==(e=e.lastEffect)){var n=e=e.next;do{var r=n,i=r.destroy;if(r=r.tag,void 0!==i)if(0!==(4&r))zs(t,n);else{r=t;try{i()}catch(o){As(r,o)}}n=n.next}while(n!==e)}break;case 1:if(ml(t),"function"===typeof(e=t.stateNode).componentWillUnmount)try{e.props=t.memoizedProps,e.state=t.memoizedState,e.componentWillUnmount()}catch(o){As(t,o)}break;case 5:ml(t);break;case 4:_l(e,t)}}function xl(e){e.alternate=null,e.child=null,e.dependencies=null,e.firstEffect=null,e.lastEffect=null,e.memoizedProps=null,e.memoizedState=null,e.pendingProps=null,e.return=null,e.updateQueue=null}function wl(e){return 5===e.tag||3===e.tag||4===e.tag}function jl(e){e:{for(var t=e.return;null!==t;){if(wl(t))break e;t=t.return}throw Error(a(160))}var n=t;switch(t=n.stateNode,n.tag){case 5:var r=!1;break;case 3:case 4:t=t.containerInfo,r=!0;break;default:throw Error(a(161))}16&n.flags&&(ve(t,""),n.flags&=-17);e:t:for(n=e;;){for(;null===n.sibling;){if(null===n.return||wl(n.return)){n=null;break e}n=n.return}for(n.sibling.return=n.return,n=n.sibling;5!==n.tag&&6!==n.tag&&18!==n.tag;){if(2&n.flags)continue t;if(null===n.child||4===n.tag)continue t;n.child.return=n,n=n.child}if(!(2&n.flags)){n=n.stateNode;break e}}r?Ol(e,n,t):kl(e,n,t)}function Ol(e,t,n){var r=e.tag,i=5===r||6===r;if(i)e=i?e.stateNode:e.stateNode.instance,t?8===n.nodeType?n.parentNode.insertBefore(e,t):n.insertBefore(e,t):(8===n.nodeType?(t=n.parentNode).insertBefore(e,n):(t=n).appendChild(e),null!==(n=n._reactRootContainer)&&void 0!==n||null!==t.onclick||(t.onclick=Ar));else if(4!==r&&null!==(e=e.child))for(Ol(e,t,n),e=e.sibling;null!==e;)Ol(e,t,n),e=e.sibling}function kl(e,t,n){var r=e.tag,i=5===r||6===r;if(i)e=i?e.stateNode:e.stateNode.instance,t?n.insertBefore(e,t):n.appendChild(e);else if(4!==r&&null!==(e=e.child))for(kl(e,t,n),e=e.sibling;null!==e;)kl(e,t,n),e=e.sibling}function _l(e,t){for(var n,r,i=t,o=!1;;){if(!o){o=i.return;e:for(;;){if(null===o)throw Error(a(160));switch(n=o.stateNode,o.tag){case 5:r=!1;break e;case 3:case 4:n=n.containerInfo,r=!0;break e}o=o.return}o=!0}if(5===i.tag||6===i.tag){e:for(var l=e,s=i,c=s;;)if(yl(l,c),null!==c.child&&4!==c.tag)c.child.return=c,c=c.child;else{if(c===s)break e;for(;null===c.sibling;){if(null===c.return||c.return===s)break e;c=c.return}c.sibling.return=c.return,c=c.sibling}r?(l=n,s=i.stateNode,8===l.nodeType?l.parentNode.removeChild(s):l.removeChild(s)):n.removeChild(i.stateNode)}else if(4===i.tag){if(null!==i.child){n=i.stateNode.containerInfo,r=!0,i.child.return=i,i=i.child;continue}}else if(yl(e,i),null!==i.child){i.child.return=i,i=i.child;continue}if(i===t)break;for(;null===i.sibling;){if(null===i.return||i.return===t)return;4===(i=i.return).tag&&(o=!1)}i.sibling.return=i.return,i=i.sibling}}function Sl(e,t){switch(t.tag){case 0:case 11:case 14:case 15:case 22:var n=t.updateQueue;if(null!==(n=null!==n?n.lastEffect:null)){var r=n=n.next;do{3===(3&r.tag)&&(e=r.destroy,r.destroy=void 0,void 0!==e&&e()),r=r.next}while(r!==n)}return;case 1:case 12:case 17:return;case 5:if(null!=(n=t.stateNode)){r=t.memoizedProps;var i=null!==e?e.memoizedProps:r;e=t.type;var o=t.updateQueue;if(t.updateQueue=null,null!==o){for(n[Zr]=r,"input"===e&&"radio"===r.type&&null!=r.name&&te(n,r),_e(e,i),t=_e(e,r),i=0;i<o.length;i+=2){var l=o[i],s=o[i+1];"style"===l?je(n,s):"dangerouslySetInnerHTML"===l?be(n,s):"children"===l?ve(n,s):x(n,l,s,t)}switch(e){case"input":ne(n,r);break;case"textarea":ce(n,r);break;case"select":e=n._wrapperState.wasMultiple,n._wrapperState.wasMultiple=!!r.multiple,null!=(o=r.value)?ae(n,!!r.multiple,o,!1):e!==!!r.multiple&&(null!=r.defaultValue?ae(n,!!r.multiple,r.defaultValue,!0):ae(n,!!r.multiple,r.multiple?[]:"",!1))}}}return;case 6:if(null===t.stateNode)throw Error(a(162));return void(t.stateNode.nodeValue=t.memoizedProps);case 3:return void((n=t.stateNode).hydrate&&(n.hydrate=!1,jt(n.containerInfo)));case 13:return null!==t.memoizedState&&(Wl=qi(),vl(t.child,!0)),void Pl(t);case 19:return void Pl(t);case 23:case 24:return void vl(t,null!==t.memoizedState)}throw Error(a(163))}function Pl(e){var t=e.updateQueue;if(null!==t){e.updateQueue=null;var n=e.stateNode;null===n&&(n=e.stateNode=new hl),t.forEach((function(t){var r=Hs.bind(null,e,t);n.has(t)||(n.add(t),t.then(r,r))}))}}function El(e,t){return null!==e&&(null===(e=e.memoizedState)||null!==e.dehydrated)&&(null!==(t=t.memoizedState)&&null===t.dehydrated)}var Cl=Math.ceil,Nl=w.ReactCurrentDispatcher,Tl=w.ReactCurrentOwner,Il=0,Ll=null,Ml=null,Fl=0,Dl=0,zl=ci(0),Rl=0,Ul=null,Al=0,Bl=0,Hl=0,ql=0,$l=null,Wl=0,Ql=1/0;function Vl(){Ql=qi()+500}var Yl,Kl=null,Gl=!1,Jl=null,Xl=null,Zl=!1,es=null,ts=90,ns=[],rs=[],is=null,os=0,as=null,ls=-1,ss=0,cs=0,us=null,ps=!1;function ds(){return 0!==(48&Il)?qi():-1!==ls?ls:ls=qi()}function fs(e){if(0===(2&(e=e.mode)))return 1;if(0===(4&e))return 99===$i()?1:2;if(0===ss&&(ss=Al),0!==Gi.transition){0!==cs&&(cs=null!==$l?$l.pendingLanes:0),e=ss;var t=4186112&~cs;return 0===(t&=-t)&&(0===(t=(e=4186112&~e)&-e)&&(t=8192)),t}return e=$i(),0!==(4&Il)&&98===e?e=At(12,ss):e=At(e=function(e){switch(e){case 99:return 15;case 98:return 10;case 97:case 96:return 8;case 95:return 2;default:return 0}}(e),ss),e}function hs(e,t,n){if(50<os)throw os=0,as=null,Error(a(185));if(null===(e=ms(e,t)))return null;qt(e,t,n),e===Ll&&(Hl|=t,4===Rl&&vs(e,Fl));var r=$i();1===t?0!==(8&Il)&&0===(48&Il)?ys(e):(gs(e,n),0===Il&&(Vl(),Yi())):(0===(4&Il)||98!==r&&99!==r||(null===is?is=new Set([e]):is.add(e)),gs(e,n)),$l=e}function ms(e,t){e.lanes|=t;var n=e.alternate;for(null!==n&&(n.lanes|=t),n=e,e=e.return;null!==e;)e.childLanes|=t,null!==(n=e.alternate)&&(n.childLanes|=t),n=e,e=e.return;return 3===n.tag?n.stateNode:null}function gs(e,t){for(var n=e.callbackNode,r=e.suspendedLanes,i=e.pingedLanes,o=e.expirationTimes,l=e.pendingLanes;0<l;){var s=31-$t(l),c=1<<s,u=o[s];if(-1===u){if(0===(c&r)||0!==(c&i)){u=t,zt(c);var p=Dt;o[s]=10<=p?u+250:6<=p?u+5e3:-1}}else u<=t&&(e.expiredLanes|=c);l&=~c}if(r=Rt(e,e===Ll?Fl:0),t=Dt,0===r)null!==n&&(n!==zi&&Pi(n),e.callbackNode=null,e.callbackPriority=0);else{if(null!==n){if(e.callbackPriority===t)return;n!==zi&&Pi(n)}15===t?(n=ys.bind(null,e),null===Ui?(Ui=[n],Ai=Si(Ii,Ki)):Ui.push(n),n=zi):14===t?n=Vi(99,ys.bind(null,e)):(n=function(e){switch(e){case 15:case 14:return 99;case 13:case 12:case 11:case 10:return 98;case 9:case 8:case 7:case 6:case 4:case 5:return 97;case 3:case 2:case 1:return 95;case 0:return 90;default:throw Error(a(358,e))}}(t),n=Vi(n,bs.bind(null,e))),e.callbackPriority=t,e.callbackNode=n}}function bs(e){if(ls=-1,cs=ss=0,0!==(48&Il))throw Error(a(327));var t=e.callbackNode;if(Fs()&&e.callbackNode!==t)return null;var n=Rt(e,e===Ll?Fl:0);if(0===n)return null;var r=n,i=Il;Il|=16;var o=Ss();for(Ll===e&&Fl===r||(Vl(),ks(e,r));;)try{Cs();break}catch(s){_s(e,s)}if(no(),Nl.current=o,Il=i,null!==Ml?r=0:(Ll=null,Fl=0,r=Rl),0!==(Al&Hl))ks(e,0);else if(0!==r){if(2===r&&(Il|=64,e.hydrate&&(e.hydrate=!1,Vr(e.containerInfo)),0!==(n=Ut(e))&&(r=Ps(e,n))),1===r)throw t=Ul,ks(e,0),vs(e,n),gs(e,qi()),t;switch(e.finishedWork=e.current.alternate,e.finishedLanes=n,r){case 0:case 1:throw Error(a(345));case 2:case 5:Is(e);break;case 3:if(vs(e,n),(62914560&n)===n&&10<(r=Wl+500-qi())){if(0!==Rt(e,0))break;if(((i=e.suspendedLanes)&n)!==n){ds(),e.pingedLanes|=e.suspendedLanes&i;break}e.timeoutHandle=Wr(Is.bind(null,e),r);break}Is(e);break;case 4:if(vs(e,n),(4186112&n)===n)break;for(r=e.eventTimes,i=-1;0<n;){var l=31-$t(n);o=1<<l,(l=r[l])>i&&(i=l),n&=~o}if(n=i,10<(n=(120>(n=qi()-n)?120:480>n?480:1080>n?1080:1920>n?1920:3e3>n?3e3:4320>n?4320:1960*Cl(n/1960))-n)){e.timeoutHandle=Wr(Is.bind(null,e),n);break}Is(e);break;default:throw Error(a(329))}}return gs(e,qi()),e.callbackNode===t?bs.bind(null,e):null}function vs(e,t){for(t&=~ql,t&=~Hl,e.suspendedLanes|=t,e.pingedLanes&=~t,e=e.expirationTimes;0<t;){var n=31-$t(t),r=1<<n;e[n]=-1,t&=~r}}function ys(e){if(0!==(48&Il))throw Error(a(327));if(Fs(),e===Ll&&0!==(e.expiredLanes&Fl)){var t=Fl,n=Ps(e,t);0!==(Al&Hl)&&(n=Ps(e,t=Rt(e,t)))}else n=Ps(e,t=Rt(e,0));if(0!==e.tag&&2===n&&(Il|=64,e.hydrate&&(e.hydrate=!1,Vr(e.containerInfo)),0!==(t=Ut(e))&&(n=Ps(e,t))),1===n)throw n=Ul,ks(e,0),vs(e,t),gs(e,qi()),n;return e.finishedWork=e.current.alternate,e.finishedLanes=t,Is(e),gs(e,qi()),null}function xs(e,t){var n=Il;Il|=1;try{return e(t)}finally{0===(Il=n)&&(Vl(),Yi())}}function ws(e,t){var n=Il;Il&=-2,Il|=8;try{return e(t)}finally{0===(Il=n)&&(Vl(),Yi())}}function js(e,t){pi(zl,Dl),Dl|=t,Al|=t}function Os(){Dl=zl.current,ui(zl)}function ks(e,t){e.finishedWork=null,e.finishedLanes=0;var n=e.timeoutHandle;if(-1!==n&&(e.timeoutHandle=-1,Qr(n)),null!==Ml)for(n=Ml.return;null!==n;){var r=n;switch(r.tag){case 1:null!==(r=r.type.childContextTypes)&&void 0!==r&&vi();break;case 3:Fo(),ui(hi),ui(fi),Go();break;case 5:zo(r);break;case 4:Fo();break;case 13:case 19:ui(Ro);break;case 10:ro(r);break;case 23:case 24:Os()}n=n.return}Ll=e,Ml=Qs(e.current,null),Fl=Dl=Al=t,Rl=0,Ul=null,ql=Hl=Bl=0}function _s(e,t){for(;;){var n=Ml;try{if(no(),Jo.current=Ia,ra){for(var r=ea.memoizedState;null!==r;){var i=r.queue;null!==i&&(i.pending=null),r=r.next}ra=!1}if(Zo=0,na=ta=ea=null,ia=!1,Tl.current=null,null===n||null===n.return){Rl=1,Ul=t,Ml=null;break}e:{var o=e,a=n.return,l=n,s=t;if(t=Fl,l.flags|=2048,l.firstEffect=l.lastEffect=null,null!==s&&"object"===typeof s&&"function"===typeof s.then){var c=s;if(0===(2&l.mode)){var u=l.alternate;u?(l.updateQueue=u.updateQueue,l.memoizedState=u.memoizedState,l.lanes=u.lanes):(l.updateQueue=null,l.memoizedState=null)}var p=0!==(1&Ro.current),d=a;do{var f;if(f=13===d.tag){var h=d.memoizedState;if(null!==h)f=null!==h.dehydrated;else{var m=d.memoizedProps;f=void 0!==m.fallback&&(!0!==m.unstable_avoidThisFallback||!p)}}if(f){var g=d.updateQueue;if(null===g){var b=new Set;b.add(c),d.updateQueue=b}else g.add(c);if(0===(2&d.mode)){if(d.flags|=64,l.flags|=16384,l.flags&=-2981,1===l.tag)if(null===l.alternate)l.tag=17;else{var v=uo(-1,1);v.tag=2,po(l,v)}l.lanes|=1;break e}s=void 0,l=t;var y=o.pingCache;if(null===y?(y=o.pingCache=new pl,s=new Set,y.set(c,s)):void 0===(s=y.get(c))&&(s=new Set,y.set(c,s)),!s.has(l)){s.add(l);var x=Bs.bind(null,o,c,l);c.then(x,x)}d.flags|=4096,d.lanes=t;break e}d=d.return}while(null!==d);s=Error((V(l.type)||"A React component")+" suspended while rendering, but no fallback UI was specified.\n\nAdd a <Suspense fallback=...> component higher in the tree to provide a loading indicator or placeholder to display.")}5!==Rl&&(Rl=2),s=cl(s,l),d=a;do{switch(d.tag){case 3:o=s,d.flags|=4096,t&=-t,d.lanes|=t,fo(d,dl(0,o,t));break e;case 1:o=s;var w=d.type,j=d.stateNode;if(0===(64&d.flags)&&("function"===typeof w.getDerivedStateFromError||null!==j&&"function"===typeof j.componentDidCatch&&(null===Xl||!Xl.has(j)))){d.flags|=4096,t&=-t,d.lanes|=t,fo(d,fl(d,o,t));break e}}d=d.return}while(null!==d)}Ts(n)}catch(O){t=O,Ml===n&&null!==n&&(Ml=n=n.return);continue}break}}function Ss(){var e=Nl.current;return Nl.current=Ia,null===e?Ia:e}function Ps(e,t){var n=Il;Il|=16;var r=Ss();for(Ll===e&&Fl===t||ks(e,t);;)try{Es();break}catch(i){_s(e,i)}if(no(),Il=n,Nl.current=r,null!==Ml)throw Error(a(261));return Ll=null,Fl=0,Rl}function Es(){for(;null!==Ml;)Ns(Ml)}function Cs(){for(;null!==Ml&&!Ei();)Ns(Ml)}function Ns(e){var t=Yl(e.alternate,e,Dl);e.memoizedProps=e.pendingProps,null===t?Ts(e):Ml=t,Tl.current=null}function Ts(e){var t=e;do{var n=t.alternate;if(e=t.return,0===(2048&t.flags)){if(null!==(n=ll(n,t,Dl)))return void(Ml=n);if(24!==(n=t).tag&&23!==n.tag||null===n.memoizedState||0!==(1073741824&Dl)||0===(4&n.mode)){for(var r=0,i=n.child;null!==i;)r|=i.lanes|i.childLanes,i=i.sibling;n.childLanes=r}null!==e&&0===(2048&e.flags)&&(null===e.firstEffect&&(e.firstEffect=t.firstEffect),null!==t.lastEffect&&(null!==e.lastEffect&&(e.lastEffect.nextEffect=t.firstEffect),e.lastEffect=t.lastEffect),1<t.flags&&(null!==e.lastEffect?e.lastEffect.nextEffect=t:e.firstEffect=t,e.lastEffect=t))}else{if(null!==(n=sl(t)))return n.flags&=2047,void(Ml=n);null!==e&&(e.firstEffect=e.lastEffect=null,e.flags|=2048)}if(null!==(t=t.sibling))return void(Ml=t);Ml=t=e}while(null!==t);0===Rl&&(Rl=5)}function Is(e){var t=$i();return Qi(99,Ls.bind(null,e,t)),null}function Ls(e,t){do{Fs()}while(null!==es);if(0!==(48&Il))throw Error(a(327));var n=e.finishedWork;if(null===n)return null;if(e.finishedWork=null,e.finishedLanes=0,n===e.current)throw Error(a(177));e.callbackNode=null;var r=n.lanes|n.childLanes,i=r,o=e.pendingLanes&~i;e.pendingLanes=i,e.suspendedLanes=0,e.pingedLanes=0,e.expiredLanes&=i,e.mutableReadLanes&=i,e.entangledLanes&=i,i=e.entanglements;for(var l=e.eventTimes,s=e.expirationTimes;0<o;){var c=31-$t(o),u=1<<c;i[c]=0,l[c]=-1,s[c]=-1,o&=~u}if(null!==is&&0===(24&r)&&is.has(e)&&is.delete(e),e===Ll&&(Ml=Ll=null,Fl=0),1<n.flags?null!==n.lastEffect?(n.lastEffect.nextEffect=n,r=n.firstEffect):r=n:r=n.firstEffect,null!==r){if(i=Il,Il|=32,Tl.current=null,Br=Kt,br(l=gr())){if("selectionStart"in l)s={start:l.selectionStart,end:l.selectionEnd};else e:if(s=(s=l.ownerDocument)&&s.defaultView||window,(u=s.getSelection&&s.getSelection())&&0!==u.rangeCount){s=u.anchorNode,o=u.anchorOffset,c=u.focusNode,u=u.focusOffset;try{s.nodeType,c.nodeType}catch(S){s=null;break e}var p=0,d=-1,f=-1,h=0,m=0,g=l,b=null;t:for(;;){for(var v;g!==s||0!==o&&3!==g.nodeType||(d=p+o),g!==c||0!==u&&3!==g.nodeType||(f=p+u),3===g.nodeType&&(p+=g.nodeValue.length),null!==(v=g.firstChild);)b=g,g=v;for(;;){if(g===l)break t;if(b===s&&++h===o&&(d=p),b===c&&++m===u&&(f=p),null!==(v=g.nextSibling))break;b=(g=b).parentNode}g=v}s=-1===d||-1===f?null:{start:d,end:f}}else s=null;s=s||{start:0,end:0}}else s=null;Hr={focusedElem:l,selectionRange:s},Kt=!1,us=null,ps=!1,Kl=r;do{try{Ms()}catch(S){if(null===Kl)throw Error(a(330));As(Kl,S),Kl=Kl.nextEffect}}while(null!==Kl);us=null,Kl=r;do{try{for(l=e;null!==Kl;){var y=Kl.flags;if(16&y&&ve(Kl.stateNode,""),128&y){var x=Kl.alternate;if(null!==x){var w=x.ref;null!==w&&("function"===typeof w?w(null):w.current=null)}}switch(1038&y){case 2:jl(Kl),Kl.flags&=-3;break;case 6:jl(Kl),Kl.flags&=-3,Sl(Kl.alternate,Kl);break;case 1024:Kl.flags&=-1025;break;case 1028:Kl.flags&=-1025,Sl(Kl.alternate,Kl);break;case 4:Sl(Kl.alternate,Kl);break;case 8:_l(l,s=Kl);var j=s.alternate;xl(s),null!==j&&xl(j)}Kl=Kl.nextEffect}}catch(S){if(null===Kl)throw Error(a(330));As(Kl,S),Kl=Kl.nextEffect}}while(null!==Kl);if(w=Hr,x=gr(),y=w.focusedElem,l=w.selectionRange,x!==y&&y&&y.ownerDocument&&mr(y.ownerDocument.documentElement,y)){null!==l&&br(y)&&(x=l.start,void 0===(w=l.end)&&(w=x),"selectionStart"in y?(y.selectionStart=x,y.selectionEnd=Math.min(w,y.value.length)):(w=(x=y.ownerDocument||document)&&x.defaultView||window).getSelection&&(w=w.getSelection(),s=y.textContent.length,j=Math.min(l.start,s),l=void 0===l.end?j:Math.min(l.end,s),!w.extend&&j>l&&(s=l,l=j,j=s),s=hr(y,j),o=hr(y,l),s&&o&&(1!==w.rangeCount||w.anchorNode!==s.node||w.anchorOffset!==s.offset||w.focusNode!==o.node||w.focusOffset!==o.offset)&&((x=x.createRange()).setStart(s.node,s.offset),w.removeAllRanges(),j>l?(w.addRange(x),w.extend(o.node,o.offset)):(x.setEnd(o.node,o.offset),w.addRange(x))))),x=[];for(w=y;w=w.parentNode;)1===w.nodeType&&x.push({element:w,left:w.scrollLeft,top:w.scrollTop});for("function"===typeof y.focus&&y.focus(),y=0;y<x.length;y++)(w=x[y]).element.scrollLeft=w.left,w.element.scrollTop=w.top}Kt=!!Br,Hr=Br=null,e.current=n,Kl=r;do{try{for(y=e;null!==Kl;){var O=Kl.flags;if(36&O&&bl(y,Kl.alternate,Kl),128&O){x=void 0;var k=Kl.ref;if(null!==k){var _=Kl.stateNode;Kl.tag,x=_,"function"===typeof k?k(x):k.current=x}}Kl=Kl.nextEffect}}catch(S){if(null===Kl)throw Error(a(330));As(Kl,S),Kl=Kl.nextEffect}}while(null!==Kl);Kl=null,Ri(),Il=i}else e.current=n;if(Zl)Zl=!1,es=e,ts=t;else for(Kl=r;null!==Kl;)t=Kl.nextEffect,Kl.nextEffect=null,8&Kl.flags&&((O=Kl).sibling=null,O.stateNode=null),Kl=t;if(0===(r=e.pendingLanes)&&(Xl=null),1===r?e===as?os++:(os=0,as=e):os=0,n=n.stateNode,ki&&"function"===typeof ki.onCommitFiberRoot)try{ki.onCommitFiberRoot(Oi,n,void 0,64===(64&n.current.flags))}catch(S){}if(gs(e,qi()),Gl)throw Gl=!1,e=Jl,Jl=null,e;return 0!==(8&Il)||Yi(),null}function Ms(){for(;null!==Kl;){var e=Kl.alternate;ps||null===us||(0!==(8&Kl.flags)?et(Kl,us)&&(ps=!0):13===Kl.tag&&El(e,Kl)&&et(Kl,us)&&(ps=!0));var t=Kl.flags;0!==(256&t)&&gl(e,Kl),0===(512&t)||Zl||(Zl=!0,Vi(97,(function(){return Fs(),null}))),Kl=Kl.nextEffect}}function Fs(){if(90!==ts){var e=97<ts?97:ts;return ts=90,Qi(e,Rs)}return!1}function Ds(e,t){ns.push(t,e),Zl||(Zl=!0,Vi(97,(function(){return Fs(),null})))}function zs(e,t){rs.push(t,e),Zl||(Zl=!0,Vi(97,(function(){return Fs(),null})))}function Rs(){if(null===es)return!1;var e=es;if(es=null,0!==(48&Il))throw Error(a(331));var t=Il;Il|=32;var n=rs;rs=[];for(var r=0;r<n.length;r+=2){var i=n[r],o=n[r+1],l=i.destroy;if(i.destroy=void 0,"function"===typeof l)try{l()}catch(c){if(null===o)throw Error(a(330));As(o,c)}}for(n=ns,ns=[],r=0;r<n.length;r+=2){i=n[r],o=n[r+1];try{var s=i.create;i.destroy=s()}catch(c){if(null===o)throw Error(a(330));As(o,c)}}for(s=e.current.firstEffect;null!==s;)e=s.nextEffect,s.nextEffect=null,8&s.flags&&(s.sibling=null,s.stateNode=null),s=e;return Il=t,Yi(),!0}function Us(e,t,n){po(e,t=dl(0,t=cl(n,t),1)),t=ds(),null!==(e=ms(e,1))&&(qt(e,1,t),gs(e,t))}function As(e,t){if(3===e.tag)Us(e,e,t);else for(var n=e.return;null!==n;){if(3===n.tag){Us(n,e,t);break}if(1===n.tag){var r=n.stateNode;if("function"===typeof n.type.getDerivedStateFromError||"function"===typeof r.componentDidCatch&&(null===Xl||!Xl.has(r))){var i=fl(n,e=cl(t,e),1);if(po(n,i),i=ds(),null!==(n=ms(n,1)))qt(n,1,i),gs(n,i);else if("function"===typeof r.componentDidCatch&&(null===Xl||!Xl.has(r)))try{r.componentDidCatch(t,e)}catch(o){}break}}n=n.return}}function Bs(e,t,n){var r=e.pingCache;null!==r&&r.delete(t),t=ds(),e.pingedLanes|=e.suspendedLanes&n,Ll===e&&(Fl&n)===n&&(4===Rl||3===Rl&&(62914560&Fl)===Fl&&500>qi()-Wl?ks(e,0):ql|=n),gs(e,t)}function Hs(e,t){var n=e.stateNode;null!==n&&n.delete(t),0===(t=0)&&(0===(2&(t=e.mode))?t=1:0===(4&t)?t=99===$i()?1:2:(0===ss&&(ss=Al),0===(t=Bt(62914560&~ss))&&(t=4194304))),n=ds(),null!==(e=ms(e,t))&&(qt(e,t,n),gs(e,n))}function qs(e,t,n,r){this.tag=e,this.key=n,this.sibling=this.child=this.return=this.stateNode=this.type=this.elementType=null,this.index=0,this.ref=null,this.pendingProps=t,this.dependencies=this.memoizedState=this.updateQueue=this.memoizedProps=null,this.mode=r,this.flags=0,this.lastEffect=this.firstEffect=this.nextEffect=null,this.childLanes=this.lanes=0,this.alternate=null}function $s(e,t,n,r){return new qs(e,t,n,r)}function Ws(e){return!(!(e=e.prototype)||!e.isReactComponent)}function Qs(e,t){var n=e.alternate;return null===n?((n=$s(e.tag,t,e.key,e.mode)).elementType=e.elementType,n.type=e.type,n.stateNode=e.stateNode,n.alternate=e,e.alternate=n):(n.pendingProps=t,n.type=e.type,n.flags=0,n.nextEffect=null,n.firstEffect=null,n.lastEffect=null),n.childLanes=e.childLanes,n.lanes=e.lanes,n.child=e.child,n.memoizedProps=e.memoizedProps,n.memoizedState=e.memoizedState,n.updateQueue=e.updateQueue,t=e.dependencies,n.dependencies=null===t?null:{lanes:t.lanes,firstContext:t.firstContext},n.sibling=e.sibling,n.index=e.index,n.ref=e.ref,n}function Vs(e,t,n,r,i,o){var l=2;if(r=e,"function"===typeof e)Ws(e)&&(l=1);else if("string"===typeof e)l=5;else e:switch(e){case k:return Ys(n.children,i,o,t);case D:l=8,i|=16;break;case _:l=8,i|=1;break;case S:return(e=$s(12,n,t,8|i)).elementType=S,e.type=S,e.lanes=o,e;case N:return(e=$s(13,n,t,i)).type=N,e.elementType=N,e.lanes=o,e;case T:return(e=$s(19,n,t,i)).elementType=T,e.lanes=o,e;case z:return Ks(n,i,o,t);case R:return(e=$s(24,n,t,i)).elementType=R,e.lanes=o,e;default:if("object"===typeof e&&null!==e)switch(e.$$typeof){case P:l=10;break e;case E:l=9;break e;case C:l=11;break e;case I:l=14;break e;case L:l=16,r=null;break e;case M:l=22;break e}throw Error(a(130,null==e?e:typeof e,""))}return(t=$s(l,n,t,i)).elementType=e,t.type=r,t.lanes=o,t}function Ys(e,t,n,r){return(e=$s(7,e,r,t)).lanes=n,e}function Ks(e,t,n,r){return(e=$s(23,e,r,t)).elementType=z,e.lanes=n,e}function Gs(e,t,n){return(e=$s(6,e,null,t)).lanes=n,e}function Js(e,t,n){return(t=$s(4,null!==e.children?e.children:[],e.key,t)).lanes=n,t.stateNode={containerInfo:e.containerInfo,pendingChildren:null,implementation:e.implementation},t}function Xs(e,t,n){this.tag=t,this.containerInfo=e,this.finishedWork=this.pingCache=this.current=this.pendingChildren=null,this.timeoutHandle=-1,this.pendingContext=this.context=null,this.hydrate=n,this.callbackNode=null,this.callbackPriority=0,this.eventTimes=Ht(0),this.expirationTimes=Ht(-1),this.entangledLanes=this.finishedLanes=this.mutableReadLanes=this.expiredLanes=this.pingedLanes=this.suspendedLanes=this.pendingLanes=0,this.entanglements=Ht(0),this.mutableSourceEagerHydrationData=null}function Zs(e,t,n){var r=3<arguments.length&&void 0!==arguments[3]?arguments[3]:null;return{$$typeof:O,key:null==r?null:""+r,children:e,containerInfo:t,implementation:n}}function ec(e,t,n,r){var i=t.current,o=ds(),l=fs(i);e:if(n){t:{if(Ge(n=n._reactInternals)!==n||1!==n.tag)throw Error(a(170));var s=n;do{switch(s.tag){case 3:s=s.stateNode.context;break t;case 1:if(bi(s.type)){s=s.stateNode.__reactInternalMemoizedMergedChildContext;break t}}s=s.return}while(null!==s);throw Error(a(171))}if(1===n.tag){var c=n.type;if(bi(c)){n=xi(n,c,s);break e}}n=s}else n=di;return null===t.context?t.context=n:t.pendingContext=n,(t=uo(o,l)).payload={element:e},null!==(r=void 0===r?null:r)&&(t.callback=r),po(i,t),hs(i,l,o),l}function tc(e){return(e=e.current).child?(e.child.tag,e.child.stateNode):null}function nc(e,t){if(null!==(e=e.memoizedState)&&null!==e.dehydrated){var n=e.retryLane;e.retryLane=0!==n&&n<t?n:t}}function rc(e,t){nc(e,t),(e=e.alternate)&&nc(e,t)}function ic(e,t,n){var r=null!=n&&null!=n.hydrationOptions&&n.hydrationOptions.mutableSources||null;if(n=new Xs(e,t,null!=n&&!0===n.hydrate),t=$s(3,null,null,2===t?7:1===t?3:0),n.current=t,t.stateNode=n,so(t),e[ei]=n.current,Ir(8===e.nodeType?e.parentNode:e),r)for(e=0;e<r.length;e++){var i=(t=r[e])._getVersion;i=i(t._source),null==n.mutableSourceEagerHydrationData?n.mutableSourceEagerHydrationData=[t,i]:n.mutableSourceEagerHydrationData.push(t,i)}this._internalRoot=n}function oc(e){return!(!e||1!==e.nodeType&&9!==e.nodeType&&11!==e.nodeType&&(8!==e.nodeType||" react-mount-point-unstable "!==e.nodeValue))}function ac(e,t,n,r,i){var o=n._reactRootContainer;if(o){var a=o._internalRoot;if("function"===typeof i){var l=i;i=function(){var e=tc(a);l.call(e)}}ec(t,a,e,i)}else{if(o=n._reactRootContainer=function(e,t){if(t||(t=!(!(t=e?9===e.nodeType?e.documentElement:e.firstChild:null)||1!==t.nodeType||!t.hasAttribute("data-reactroot"))),!t)for(var n;n=e.lastChild;)e.removeChild(n);return new ic(e,0,t?{hydrate:!0}:void 0)}(n,r),a=o._internalRoot,"function"===typeof i){var s=i;i=function(){var e=tc(a);s.call(e)}}ws((function(){ec(t,a,e,i)}))}return tc(a)}function lc(e,t){var n=2<arguments.length&&void 0!==arguments[2]?arguments[2]:null;if(!oc(t))throw Error(a(200));return Zs(e,t,null,n)}Yl=function(e,t,n){var r=t.lanes;if(null!==e)if(e.memoizedProps!==t.pendingProps||hi.current)za=!0;else{if(0===(n&r)){switch(za=!1,t.tag){case 3:Va(t),Yo();break;case 5:Do(t);break;case 1:bi(t.type)&&wi(t);break;case 4:Mo(t,t.stateNode.containerInfo);break;case 10:r=t.memoizedProps.value;var i=t.type._context;pi(Xi,i._currentValue),i._currentValue=r;break;case 13:if(null!==t.memoizedState)return 0!==(n&t.child.childLanes)?Xa(e,t,n):(pi(Ro,1&Ro.current),null!==(t=ol(e,t,n))?t.sibling:null);pi(Ro,1&Ro.current);break;case 19:if(r=0!==(n&t.childLanes),0!==(64&e.flags)){if(r)return il(e,t,n);t.flags|=64}if(null!==(i=t.memoizedState)&&(i.rendering=null,i.tail=null,i.lastEffect=null),pi(Ro,Ro.current),r)break;return null;case 23:case 24:return t.lanes=0,Ha(e,t,n)}return ol(e,t,n)}za=0!==(16384&e.flags)}else za=!1;switch(t.lanes=0,t.tag){case 2:if(r=t.type,null!==e&&(e.alternate=null,t.alternate=null,t.flags|=2),e=t.pendingProps,i=gi(t,fi.current),oo(t,n),i=la(null,t,r,e,i,n),t.flags|=1,"object"===typeof i&&null!==i&&"function"===typeof i.render&&void 0===i.$$typeof){if(t.tag=1,t.memoizedState=null,t.updateQueue=null,bi(r)){var o=!0;wi(t)}else o=!1;t.memoizedState=null!==i.state&&void 0!==i.state?i.state:null,so(t);var l=r.getDerivedStateFromProps;"function"===typeof l&&bo(t,r,l,e),i.updater=vo,t.stateNode=i,i._reactInternals=t,jo(t,r,e,n),t=Qa(null,t,r,!0,o,n)}else t.tag=0,Ra(null,t,i,n),t=t.child;return t;case 16:i=t.elementType;e:{switch(null!==e&&(e.alternate=null,t.alternate=null,t.flags|=2),e=t.pendingProps,i=(o=i._init)(i._payload),t.type=i,o=t.tag=function(e){if("function"===typeof e)return Ws(e)?1:0;if(void 0!==e&&null!==e){if((e=e.$$typeof)===C)return 11;if(e===I)return 14}return 2}(i),e=Ji(i,e),o){case 0:t=$a(null,t,i,e,n);break e;case 1:t=Wa(null,t,i,e,n);break e;case 11:t=Ua(null,t,i,e,n);break e;case 14:t=Aa(null,t,i,Ji(i.type,e),r,n);break e}throw Error(a(306,i,""))}return t;case 0:return r=t.type,i=t.pendingProps,$a(e,t,r,i=t.elementType===r?i:Ji(r,i),n);case 1:return r=t.type,i=t.pendingProps,Wa(e,t,r,i=t.elementType===r?i:Ji(r,i),n);case 3:if(Va(t),r=t.updateQueue,null===e||null===r)throw Error(a(282));if(r=t.pendingProps,i=null!==(i=t.memoizedState)?i.element:null,co(e,t),ho(t,r,null,n),(r=t.memoizedState.element)===i)Yo(),t=ol(e,t,n);else{if((o=(i=t.stateNode).hydrate)&&(Bo=Yr(t.stateNode.containerInfo.firstChild),Ao=t,o=Ho=!0),o){if(null!=(e=i.mutableSourceEagerHydrationData))for(i=0;i<e.length;i+=2)(o=e[i])._workInProgressVersionPrimary=e[i+1],Ko.push(o);for(n=Eo(t,null,r,n),t.child=n;n;)n.flags=-3&n.flags|1024,n=n.sibling}else Ra(e,t,r,n),Yo();t=t.child}return t;case 5:return Do(t),null===e&&Wo(t),r=t.type,i=t.pendingProps,o=null!==e?e.memoizedProps:null,l=i.children,$r(r,i)?l=null:null!==o&&$r(r,o)&&(t.flags|=16),qa(e,t),Ra(e,t,l,n),t.child;case 6:return null===e&&Wo(t),null;case 13:return Xa(e,t,n);case 4:return Mo(t,t.stateNode.containerInfo),r=t.pendingProps,null===e?t.child=Po(t,null,r,n):Ra(e,t,r,n),t.child;case 11:return r=t.type,i=t.pendingProps,Ua(e,t,r,i=t.elementType===r?i:Ji(r,i),n);case 7:return Ra(e,t,t.pendingProps,n),t.child;case 8:case 12:return Ra(e,t,t.pendingProps.children,n),t.child;case 10:e:{r=t.type._context,i=t.pendingProps,l=t.memoizedProps,o=i.value;var s=t.type._context;if(pi(Xi,s._currentValue),s._currentValue=o,null!==l)if(s=l.value,0===(o=ur(s,o)?0:0|("function"===typeof r._calculateChangedBits?r._calculateChangedBits(s,o):1073741823))){if(l.children===i.children&&!hi.current){t=ol(e,t,n);break e}}else for(null!==(s=t.child)&&(s.return=t);null!==s;){var c=s.dependencies;if(null!==c){l=s.child;for(var u=c.firstContext;null!==u;){if(u.context===r&&0!==(u.observedBits&o)){1===s.tag&&((u=uo(-1,n&-n)).tag=2,po(s,u)),s.lanes|=n,null!==(u=s.alternate)&&(u.lanes|=n),io(s.return,n),c.lanes|=n;break}u=u.next}}else l=10===s.tag&&s.type===t.type?null:s.child;if(null!==l)l.return=s;else for(l=s;null!==l;){if(l===t){l=null;break}if(null!==(s=l.sibling)){s.return=l.return,l=s;break}l=l.return}s=l}Ra(e,t,i.children,n),t=t.child}return t;case 9:return i=t.type,r=(o=t.pendingProps).children,oo(t,n),r=r(i=ao(i,o.unstable_observedBits)),t.flags|=1,Ra(e,t,r,n),t.child;case 14:return o=Ji(i=t.type,t.pendingProps),Aa(e,t,i,o=Ji(i.type,o),r,n);case 15:return Ba(e,t,t.type,t.pendingProps,r,n);case 17:return r=t.type,i=t.pendingProps,i=t.elementType===r?i:Ji(r,i),null!==e&&(e.alternate=null,t.alternate=null,t.flags|=2),t.tag=1,bi(r)?(e=!0,wi(t)):e=!1,oo(t,n),xo(t,r,i),jo(t,r,i,n),Qa(null,t,r,!0,e,n);case 19:return il(e,t,n);case 23:case 24:return Ha(e,t,n)}throw Error(a(156,t.tag))},ic.prototype.render=function(e){ec(e,this._internalRoot,null,null)},ic.prototype.unmount=function(){var e=this._internalRoot,t=e.containerInfo;ec(null,e,null,(function(){t[ei]=null}))},tt=function(e){13===e.tag&&(hs(e,4,ds()),rc(e,4))},nt=function(e){13===e.tag&&(hs(e,67108864,ds()),rc(e,67108864))},rt=function(e){if(13===e.tag){var t=ds(),n=fs(e);hs(e,n,t),rc(e,n)}},it=function(e,t){return t()},Pe=function(e,t,n){switch(t){case"input":if(ne(e,n),t=n.name,"radio"===n.type&&null!=t){for(n=e;n.parentNode;)n=n.parentNode;for(n=n.querySelectorAll("input[name="+JSON.stringify(""+t)+'][type="radio"]'),t=0;t<n.length;t++){var r=n[t];if(r!==e&&r.form===e.form){var i=oi(r);if(!i)throw Error(a(90));J(r),ne(r,i)}}}break;case"textarea":ce(e,n);break;case"select":null!=(t=n.value)&&ae(e,!!n.multiple,t,!1)}},Le=xs,Me=function(e,t,n,r,i){var o=Il;Il|=4;try{return Qi(98,e.bind(null,t,n,r,i))}finally{0===(Il=o)&&(Vl(),Yi())}},Fe=function(){0===(49&Il)&&(function(){if(null!==is){var e=is;is=null,e.forEach((function(e){e.expiredLanes|=24&e.pendingLanes,gs(e,qi())}))}Yi()}(),Fs())},De=function(e,t){var n=Il;Il|=2;try{return e(t)}finally{0===(Il=n)&&(Vl(),Yi())}};var sc={Events:[ri,ii,oi,Te,Ie,Fs,{current:!1}]},cc={findFiberByHostInstance:ni,bundleType:0,version:"17.0.2",rendererPackageName:"react-dom"},uc={bundleType:cc.bundleType,version:cc.version,rendererPackageName:cc.rendererPackageName,rendererConfig:cc.rendererConfig,overrideHookState:null,overrideHookStateDeletePath:null,overrideHookStateRenamePath:null,overrideProps:null,overridePropsDeletePath:null,overridePropsRenamePath:null,setSuspenseHandler:null,scheduleUpdate:null,currentDispatcherRef:w.ReactCurrentDispatcher,findHostInstanceByFiber:function(e){return null===(e=Ze(e))?null:e.stateNode},findFiberByHostInstance:cc.findFiberByHostInstance||function(){return null},findHostInstancesForRefresh:null,scheduleRefresh:null,scheduleRoot:null,setRefreshHandler:null,getCurrentFiber:null};if("undefined"!==typeof __REACT_DEVTOOLS_GLOBAL_HOOK__){var pc=__REACT_DEVTOOLS_GLOBAL_HOOK__;if(!pc.isDisabled&&pc.supportsFiber)try{Oi=pc.inject(uc),ki=pc}catch(ge){}}t.__SECRET_INTERNALS_DO_NOT_USE_OR_YOU_WILL_BE_FIRED=sc,t.createPortal=lc,t.findDOMNode=function(e){if(null==e)return null;if(1===e.nodeType)return e;var t=e._reactInternals;if(void 0===t){if("function"===typeof e.render)throw Error(a(188));throw Error(a(268,Object.keys(e)))}return e=null===(e=Ze(t))?null:e.stateNode},t.flushSync=function(e,t){var n=Il;if(0!==(48&n))return e(t);Il|=1;try{if(e)return Qi(99,e.bind(null,t))}finally{Il=n,Yi()}},t.hydrate=function(e,t,n){if(!oc(t))throw Error(a(200));return ac(null,e,t,!0,n)},t.render=function(e,t,n){if(!oc(t))throw Error(a(200));return ac(null,e,t,!1,n)},t.unmountComponentAtNode=function(e){if(!oc(e))throw Error(a(40));return!!e._reactRootContainer&&(ws((function(){ac(null,null,e,!1,(function(){e._reactRootContainer=null,e[ei]=null}))})),!0)},t.unstable_batchedUpdates=xs,t.unstable_createPortal=function(e,t){return lc(e,t,2<arguments.length&&void 0!==arguments[2]?arguments[2]:null)},t.unstable_renderSubtreeIntoContainer=function(e,t,n,r){if(!oc(n))throw Error(a(200));if(null==e||void 0===e._reactInternals)throw Error(a(38));return ac(e,t,n,!1,r)},t.version="17.0.2"},function(e,t,n){"use strict";e.exports=n(36)},function(e,t,n){"use strict";var r,i,o,a;if("object"===typeof performance&&"function"===typeof performance.now){var l=performance;t.unstable_now=function(){return l.now()}}else{var s=Date,c=s.now();t.unstable_now=function(){return s.now()-c}}if("undefined"===typeof window||"function"!==typeof MessageChannel){var u=null,p=null,d=function e(){if(null!==u)try{var n=t.unstable_now();u(!0,n),u=null}catch(r){throw setTimeout(e,0),r}};r=function(e){null!==u?setTimeout(r,0,e):(u=e,setTimeout(d,0))},i=function(e,t){p=setTimeout(e,t)},o=function(){clearTimeout(p)},t.unstable_shouldYield=function(){return!1},a=t.unstable_forceFrameRate=function(){}}else{var f=window.setTimeout,h=window.clearTimeout;if("undefined"!==typeof console){var m=window.cancelAnimationFrame;"function"!==typeof window.requestAnimationFrame&&console.error("This browser doesn't support requestAnimationFrame. Make sure that you load a polyfill in older browsers. https://reactjs.org/link/react-polyfills"),"function"!==typeof m&&console.error("This browser doesn't support cancelAnimationFrame. Make sure that you load a polyfill in older browsers. https://reactjs.org/link/react-polyfills")}var g=!1,b=null,v=-1,y=5,x=0;t.unstable_shouldYield=function(){return t.unstable_now()>=x},a=function(){},t.unstable_forceFrameRate=function(e){0>e||125<e?console.error("forceFrameRate takes a positive int between 0 and 125, forcing frame rates higher than 125 fps is not supported"):y=0<e?Math.floor(1e3/e):5};var w=new MessageChannel,j=w.port2;w.port1.onmessage=function(){if(null!==b){var e=t.unstable_now();x=e+y;try{b(!0,e)?j.postMessage(null):(g=!1,b=null)}catch(n){throw j.postMessage(null),n}}else g=!1},r=function(e){b=e,g||(g=!0,j.postMessage(null))},i=function(e,n){v=f((function(){e(t.unstable_now())}),n)},o=function(){h(v),v=-1}}function O(e,t){var n=e.length;e.push(t);e:for(;;){var r=n-1>>>1,i=e[r];if(!(void 0!==i&&0<S(i,t)))break e;e[r]=t,e[n]=i,n=r}}function k(e){return void 0===(e=e[0])?null:e}function _(e){var t=e[0];if(void 0!==t){var n=e.pop();if(n!==t){e[0]=n;e:for(var r=0,i=e.length;r<i;){var o=2*(r+1)-1,a=e[o],l=o+1,s=e[l];if(void 0!==a&&0>S(a,n))void 0!==s&&0>S(s,a)?(e[r]=s,e[l]=n,r=l):(e[r]=a,e[o]=n,r=o);else{if(!(void 0!==s&&0>S(s,n)))break e;e[r]=s,e[l]=n,r=l}}}return t}return null}function S(e,t){var n=e.sortIndex-t.sortIndex;return 0!==n?n:e.id-t.id}var P=[],E=[],C=1,N=null,T=3,I=!1,L=!1,M=!1;function F(e){for(var t=k(E);null!==t;){if(null===t.callback)_(E);else{if(!(t.startTime<=e))break;_(E),t.sortIndex=t.expirationTime,O(P,t)}t=k(E)}}function D(e){if(M=!1,F(e),!L)if(null!==k(P))L=!0,r(z);else{var t=k(E);null!==t&&i(D,t.startTime-e)}}function z(e,n){L=!1,M&&(M=!1,o()),I=!0;var r=T;try{for(F(n),N=k(P);null!==N&&(!(N.expirationTime>n)||e&&!t.unstable_shouldYield());){var a=N.callback;if("function"===typeof a){N.callback=null,T=N.priorityLevel;var l=a(N.expirationTime<=n);n=t.unstable_now(),"function"===typeof l?N.callback=l:N===k(P)&&_(P),F(n)}else _(P);N=k(P)}if(null!==N)var s=!0;else{var c=k(E);null!==c&&i(D,c.startTime-n),s=!1}return s}finally{N=null,T=r,I=!1}}var R=a;t.unstable_IdlePriority=5,t.unstable_ImmediatePriority=1,t.unstable_LowPriority=4,t.unstable_NormalPriority=3,t.unstable_Profiling=null,t.unstable_UserBlockingPriority=2,t.unstable_cancelCallback=function(e){e.callback=null},t.unstable_continueExecution=function(){L||I||(L=!0,r(z))},t.unstable_getCurrentPriorityLevel=function(){return T},t.unstable_getFirstCallbackNode=function(){return k(P)},t.unstable_next=function(e){switch(T){case 1:case 2:case 3:var t=3;break;default:t=T}var n=T;T=t;try{return e()}finally{T=n}},t.unstable_pauseExecution=function(){},t.unstable_requestPaint=R,t.unstable_runWithPriority=function(e,t){switch(e){case 1:case 2:case 3:case 4:case 5:break;default:e=3}var n=T;T=e;try{return t()}finally{T=n}},t.unstable_scheduleCallback=function(e,n,a){var l=t.unstable_now();switch("object"===typeof a&&null!==a?a="number"===typeof(a=a.delay)&&0<a?l+a:l:a=l,e){case 1:var s=-1;break;case 2:s=250;break;case 5:s=1073741823;break;case 4:s=1e4;break;default:s=5e3}return e={id:C++,callback:n,priorityLevel:e,startTime:a,expirationTime:s=a+s,sortIndex:-1},a>l?(e.sortIndex=a,O(E,e),null===k(P)&&e===k(E)&&(M?o():M=!0,i(D,a-l))):(e.sortIndex=s,O(P,e),L||I||(L=!0,r(z))),e},t.unstable_wrapCallback=function(e){var t=T;return function(){var n=T;T=t;try{return e.apply(this,arguments)}finally{T=n}}}},function(e,t,n){var r=n(23),i=n(38);"string"===typeof(i=i.__esModule?i.default:i)&&(i=[[e.i,i,""]]);var o={insert:"head",singleton:!1};r(i,o);e.exports=i.locals||{}},function(e,t,n){"use strict";n.r(t);var r=n(19),i=n.n(r)()(!0);i.push([e.i,"","",{version:3,sources:[],names:[],mappings:"",sourceRoot:""}]),t.default=i},function(e,t,n){"use strict";n(22);var r=n(1),i=60103;if(t.Fragment=60107,"function"===typeof Symbol&&Symbol.for){var o=Symbol.for;i=o("react.element"),t.Fragment=o("react.fragment")}var a=r.__SECRET_INTERNALS_DO_NOT_USE_OR_YOU_WILL_BE_FIRED.ReactCurrentOwner,l=Object.prototype.hasOwnProperty,s={key:!0,ref:!0,__self:!0,__source:!0};function c(e,t,n){var r,o={},c=null,u=null;for(r in void 0!==n&&(c=""+n),void 0!==t.key&&(c=""+t.key),void 0!==t.ref&&(u=t.ref),t)l.call(t,r)&&!s.hasOwnProperty(r)&&(o[r]=t[r]);if(e&&e.defaultProps)for(r in t=e.defaultProps)void 0===o[r]&&(o[r]=t[r]);return{$$typeof:i,type:e,key:c,ref:u,props:o,_owner:a.current}}t.jsx=c,t.jsxs=c},function(e,t,n){var r=n(23),i=n(41);"string"===typeof(i=i.__esModule?i.default:i)&&(i=[[e.i,i,""]]);var o={insert:"head",singleton:!1};r(i,o);e.exports=i.locals||{}},function(e,t,n){"use strict";n.r(t);var r=n(19),i=n.n(r)()(!0);i.push([e.i,"","",{version:3,sources:[],names:[],mappings:"",sourceRoot:""}]),t.default=i},function(e,t,n){var r=n(3).getQueryPrice;function i(e){var t,n=e.event,r=e.form,i=e.errorEl,o=e.siteUrl,a=e.submitHandler;r.removeEventListener("submit",a),n.preventDefault(),i&&(i.innerText=""),r.classList.remove("success","invalid","error");for(var l=n.target.querySelector("input[data-members-email]"),s=n.target.querySelector("input[data-members-name]"),c=(null===r||void 0===r||null===(t=r.dataset)||void 0===t?void 0:t.membersAutoredirect)||"true",u=null===l||void 0===l?void 0:l.value,p=s&&s.value||void 0,d=void 0,f=[],h=n.target.querySelectorAll("input[data-members-label]")||[],m=0;m<h.length;++m)f.push(h[m].value);r.dataset.membersForm&&(d=r.dataset.membersForm),r.classList.add("loading"),fetch("".concat(o,"/members/api/send-magic-link/"),{method:"POST",headers:{"Content-Type":"application/json"},body:JSON.stringify({email:u,emailType:d,labels:f,name:p,autoRedirect:"true"===c})}).then((function(e){r.addEventListener("submit",a),r.classList.remove("loading"),e.ok?r.classList.add("success"):(i&&(i.innerText="There was an error sending the email, please try again"),r.classList.add("error"))}))}function o(e){var t=e.event,n=e.el,i=e.errorEl,o=e.siteUrl,a=e.site,l=e.member,s=e.clickHandler;n.removeEventListener("click",s),t.preventDefault();var c=n.dataset.membersPlan,u="";if(c){var p=r({site:a,priceId:c.toLowerCase()});u=p?p.id:c}var d,f,h=n.dataset.membersSuccess,m=n.dataset.membersCancel;h&&(d=new URL(h,window.location.href).href),m&&(f=new URL(m,window.location.href).href),i&&(i.innerText=""),n.classList.add("loading");var g=l?{checkoutType:"upgrade"}:{};return fetch("".concat(o,"/members/api/session"),{credentials:"same-origin"}).then((function(e){return e.ok?e.text():null})).then((function(e){return fetch("".concat(o,"/members/api/create-stripe-checkout-session/"),{method:"POST",headers:{"Content-Type":"application/json"},body:JSON.stringify({priceId:u,identity:e,successUrl:d,cancelUrl:f,metadata:g})}).then((function(e){if(!e.ok)throw new Error("Could not create stripe checkout session");return e.json()}))})).then((function(e){return window.Stripe(e.publicKey).redirectToCheckout({sessionId:e.sessionId})})).then((function(e){if(e.error)throw new Error(e.error.message)})).catch((function(e){console.error(e),n.addEventListener("click",s),n.classList.remove("loading"),i&&(i.innerText=e.message),n.classList.add("error")}))}e.exports={handleDataAttributes:function(e){var t=e.siteUrl,n=e.site,r=e.member;t&&(t=t.replace(/\/$/,""),Array.prototype.forEach.call(document.querySelectorAll("form[data-members-form]"),(function(e){var n=e.querySelector("[data-members-error]");e.addEventListener("submit",(function r(o){i({event:o,errorEl:n,form:e,siteUrl:t,submitHandler:r})}))})),Array.prototype.forEach.call(document.querySelectorAll("[data-members-plan]"),(function(e){var i=e.querySelector("[data-members-error]");e.addEventListener("click",(function a(l){o({el:e,event:l,errorEl:i,member:r,site:n,siteUrl:t,clickHandler:a})}))})),Array.prototype.forEach.call(document.querySelectorAll("[data-members-edit-billing]"),(function(e){var n,r,i=e.querySelector("[data-members-error]"),o=e.dataset.membersSuccess,a=e.dataset.membersCancel;o&&(n=new URL(o,window.location.href).href),a&&(r=new URL(a,window.location.href).href),e.addEventListener("click",(function o(a){e.removeEventListener("click",o),a.preventDefault(),i&&(i.innerText=""),e.classList.add("loading"),fetch("".concat(t,"/members/api/session"),{credentials:"same-origin"}).then((function(e){return e.ok?e.text():null})).then((function(e){return fetch("".concat(t,"/members/api/create-stripe-update-session/"),{method:"POST",headers:{"Content-Type":"application/json"},body:JSON.stringify({identity:e,successUrl:n,cancelUrl:r})}).then((function(e){if(!e.ok)throw new Error("Could not create stripe checkout session");return e.json()}))})).then((function(e){return window.Stripe(e.publicKey).redirectToCheckout({sessionId:e.sessionId})})).then((function(e){if(e.error)throw new Error(e.error.message)})).catch((function(t){console.error(t),e.addEventListener("click",o),e.classList.remove("loading"),i&&(i.innerText=t.message),e.classList.add("error")}))}))})),Array.prototype.forEach.call(document.querySelectorAll("[data-members-signout]"),(function(e){e.addEventListener("click",(function n(r){e.removeEventListener("click",n),r.preventDefault(),e.classList.remove("error"),e.classList.add("loading"),fetch("".concat(t,"/members/api/session"),{method:"DELETE"}).then((function(r){r.ok?window.location.replace(t):(e.addEventListener("click",n),e.classList.remove("loading"),e.classList.add("error"))}))}))})),Array.prototype.forEach.call(document.querySelectorAll("[data-members-cancel-subscription]"),(function(e){var n=e.parentElement.querySelector("[data-members-error]");e.addEventListener("click",(function r(i){e.removeEventListener("click",r),i.preventDefault(),e.classList.remove("error"),e.classList.add("loading");var o=e.dataset.membersCancelSubscription;return n&&(n.innerText=""),fetch("".concat(t,"/members/api/session"),{credentials:"same-origin"}).then((function(e){return e.ok?e.text():null})).then((function(e){return fetch("".concat(t,"/members/api/subscriptions/").concat(o,"/"),{method:"PUT",headers:{"Content-Type":"application/json"},body:JSON.stringify({identity:e,smart_cancel:!0})})})).then((function(t){t.ok?window.location.reload():(e.addEventListener("click",r),e.classList.remove("loading"),e.classList.add("error"),n&&(n.innerText="There was an error cancelling your subscription, please try again."))}))}))})),Array.prototype.forEach.call(document.querySelectorAll("[data-members-continue-subscription]"),(function(e){var n=e.parentElement.querySelector("[data-members-error]");e.addEventListener("click",(function r(i){e.removeEventListener("click",r),i.preventDefault(),e.classList.remove("error"),e.classList.add("loading");var o=e.dataset.membersContinueSubscription;return n&&(n.innerText=""),fetch("".concat(t,"/members/api/session"),{credentials:"same-origin"}).then((function(e){return e.ok?e.text():null})).then((function(e){return fetch("".concat(t,"/members/api/subscriptions/").concat(o,"/"),{method:"PUT",headers:{"Content-Type":"application/json"},body:JSON.stringify({identity:e,cancel_at_period_end:!1})})})).then((function(t){t.ok?window.location.reload():(e.addEventListener("click",r),e.classList.remove("loading"),e.classList.add("error"),n&&(n.innerText="There was an error continuing your subscription, please try again."))}))}))})))},formSubmitHandler:i,planClickHandler:o}},function(e,t,n){"use strict";e.exports=n(44)},function(e,t,n){"use strict";var r="function"===typeof Symbol&&Symbol.for,i=r?Symbol.for("react.element"):60103,o=r?Symbol.for("react.portal"):60106,a=r?Symbol.for("react.fragment"):60107,l=r?Symbol.for("react.strict_mode"):60108,s=r?Symbol.for("react.profiler"):60114,c=r?Symbol.for("react.provider"):60109,u=r?Symbol.for("react.context"):60110,p=r?Symbol.for("react.async_mode"):60111,d=r?Symbol.for("react.concurrent_mode"):60111,f=r?Symbol.for("react.forward_ref"):60112,h=r?Symbol.for("react.suspense"):60113,m=r?Symbol.for("react.suspense_list"):60120,g=r?Symbol.for("react.memo"):60115,b=r?Symbol.for("react.lazy"):60116,v=r?Symbol.for("react.block"):60121,y=r?Symbol.for("react.fundamental"):60117,x=r?Symbol.for("react.responder"):60118,w=r?Symbol.for("react.scope"):60119;function j(e){if("object"===typeof e&&null!==e){var t=e.$$typeof;switch(t){case i:switch(e=e.type){case p:case d:case a:case s:case l:case h:return e;default:switch(e=e&&e.$$typeof){case u:case f:case b:case g:case c:return e;default:return t}}case o:return t}}}function O(e){return j(e)===d}t.AsyncMode=p,t.ConcurrentMode=d,t.ContextConsumer=u,t.ContextProvider=c,t.Element=i,t.ForwardRef=f,t.Fragment=a,t.Lazy=b,t.Memo=g,t.Portal=o,t.Profiler=s,t.StrictMode=l,t.Suspense=h,t.isAsyncMode=function(e){return O(e)||j(e)===p},t.isConcurrentMode=O,t.isContextConsumer=function(e){return j(e)===u},t.isContextProvider=function(e){return j(e)===c},t.isElement=function(e){return"object"===typeof e&&null!==e&&e.$$typeof===i},t.isForwardRef=function(e){return j(e)===f},t.isFragment=function(e){return j(e)===a},t.isLazy=function(e){return j(e)===b},t.isMemo=function(e){return j(e)===g},t.isPortal=function(e){return j(e)===o},t.isProfiler=function(e){return j(e)===s},t.isStrictMode=function(e){return j(e)===l},t.isSuspense=function(e){return j(e)===h},t.isValidElementType=function(e){return"string"===typeof e||"function"===typeof e||e===a||e===d||e===s||e===l||e===h||e===m||"object"===typeof e&&null!==e&&(e.$$typeof===b||e.$$typeof===g||e.$$typeof===c||e.$$typeof===u||e.$$typeof===f||e.$$typeof===y||e.$$typeof===x||e.$$typeof===w||e.$$typeof===v)},t.typeOf=j},function(e,t){var n,r,i=e.exports={};function o(){throw new Error("setTimeout has not been defined")}function a(){throw new Error("clearTimeout has not been defined")}function l(e){if(n===setTimeout)return setTimeout(e,0);if((n===o||!n)&&setTimeout)return n=setTimeout,setTimeout(e,0);try{return n(e,0)}catch(t){try{return n.call(null,e,0)}catch(t){return n.call(this,e,0)}}}!function(){try{n="function"===typeof setTimeout?setTimeout:o}catch(e){n=o}try{r="function"===typeof clearTimeout?clearTimeout:a}catch(e){r=a}}();var s,c=[],u=!1,p=-1;function d(){u&&s&&(u=!1,s.length?c=s.concat(c):p=-1,c.length&&f())}function f(){if(!u){var e=l(d);u=!0;for(var t=c.length;t;){for(s=c,c=[];++p<t;)s&&s[p].run();p=-1,t=c.length}s=null,u=!1,function(e){if(r===clearTimeout)return clearTimeout(e);if((r===a||!r)&&clearTimeout)return r=clearTimeout,clearTimeout(e);try{r(e)}catch(t){try{return r.call(null,e)}catch(t){return r.call(this,e)}}}(e)}}function h(e,t){this.fun=e,this.array=t}function m(){}i.nextTick=function(e){var t=new Array(arguments.length-1);if(arguments.length>1)for(var n=1;n<arguments.length;n++)t[n-1]=arguments[n];c.push(new h(e,t)),1!==c.length||u||l(f)},h.prototype.run=function(){this.fun.apply(null,this.array)},i.title="browser",i.browser=!0,i.env={},i.argv=[],i.version="",i.versions={},i.on=m,i.addListener=m,i.once=m,i.off=m,i.removeListener=m,i.removeAllListeners=m,i.emit=m,i.prependListener=m,i.prependOnceListener=m,i.listeners=function(e){return[]},i.binding=function(e){throw new Error("process.binding is not supported")},i.cwd=function(){return"/"},i.chdir=function(e){throw new Error("process.chdir is not supported")},i.umask=function(){return 0}},function(e,t,n){"use strict";n.r(t);var r={};n.r(r),n.d(r,"FunctionToString",(function(){return pe})),n.d(r,"InboundFilters",(function(){return he}));var i=n(1),o=n.n(i),a=n(14),l=n.n(a),s=(n(37),n(5)),c=n(13);function u(e,t){var n="undefined"!==typeof Symbol&&e[Symbol.iterator]||e["@@iterator"];if(!n){if(Array.isArray(e)||(n=Object(c.a)(e))||t&&e&&"number"===typeof e.length){n&&(e=n);var r=0,i=function(){};return{s:i,n:function(){return r>=e.length?{done:!0}:{done:!1,value:e[r++]}},e:function(e){throw e},f:i}}throw new TypeError("Invalid attempt to iterate non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}var o,a=!0,l=!1;return{s:function(){n=n.call(e)},n:function(){var e=n.next();return a=e.done,e},e:function(e){l=!0,o=e},f:function(){try{a||null==n.return||n.return()}finally{if(l)throw o}}}}function p(e,t){if(null==e)return{};var n,r,i=function(e,t){if(null==e)return{};var n,r,i={},o=Object.keys(e);for(r=0;r<o.length;r++)n=o[r],t.indexOf(n)>=0||(i[n]=e[n]);return i}(e,t);if(Object.getOwnPropertySymbols){var o=Object.getOwnPropertySymbols(e);for(r=0;r<o.length;r++)n=o[r],t.indexOf(n)>=0||Object.prototype.propertyIsEnumerable.call(e,n)&&(i[n]=e[n])}return i}function d(e){return d="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},d(e)}function f(){f=function(){return e};var e={},t=Object.prototype,n=t.hasOwnProperty,r="function"==typeof Symbol?Symbol:{},i=r.iterator||"@@iterator",o=r.asyncIterator||"@@asyncIterator",a=r.toStringTag||"@@toStringTag";function l(e,t,n){return Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}),e[t]}try{l({},"")}catch(E){l=function(e,t,n){return e[t]=n}}function s(e,t,n,r){var i=t&&t.prototype instanceof p?t:p,o=Object.create(i.prototype),a=new _(r||[]);return o._invoke=function(e,t,n){var r="suspendedStart";return function(i,o){if("executing"===r)throw new Error("Generator is already running");if("completed"===r){if("throw"===i)throw o;return P()}for(n.method=i,n.arg=o;;){var a=n.delegate;if(a){var l=j(a,n);if(l){if(l===u)continue;return l}}if("next"===n.method)n.sent=n._sent=n.arg;else if("throw"===n.method){if("suspendedStart"===r)throw r="completed",n.arg;n.dispatchException(n.arg)}else"return"===n.method&&n.abrupt("return",n.arg);r="executing";var s=c(e,t,n);if("normal"===s.type){if(r=n.done?"completed":"suspendedYield",s.arg===u)continue;return{value:s.arg,done:n.done}}"throw"===s.type&&(r="completed",n.method="throw",n.arg=s.arg)}}}(e,n,a),o}function c(e,t,n){try{return{type:"normal",arg:e.call(t,n)}}catch(E){return{type:"throw",arg:E}}}e.wrap=s;var u={};function p(){}function h(){}function m(){}var g={};l(g,i,(function(){return this}));var b=Object.getPrototypeOf,v=b&&b(b(S([])));v&&v!==t&&n.call(v,i)&&(g=v);var y=m.prototype=p.prototype=Object.create(g);function x(e){["next","throw","return"].forEach((function(t){l(e,t,(function(e){return this._invoke(t,e)}))}))}function w(e,t){function r(i,o,a,l){var s=c(e[i],e,o);if("throw"!==s.type){var u=s.arg,p=u.value;return p&&"object"==d(p)&&n.call(p,"__await")?t.resolve(p.__await).then((function(e){r("next",e,a,l)}),(function(e){r("throw",e,a,l)})):t.resolve(p).then((function(e){u.value=e,a(u)}),(function(e){return r("throw",e,a,l)}))}l(s.arg)}var i;this._invoke=function(e,n){function o(){return new t((function(t,i){r(e,n,t,i)}))}return i=i?i.then(o,o):o()}}function j(e,t){var n=e.iterator[t.method];if(void 0===n){if(t.delegate=null,"throw"===t.method){if(e.iterator.return&&(t.method="return",t.arg=void 0,j(e,t),"throw"===t.method))return u;t.method="throw",t.arg=new TypeError("The iterator does not provide a 'throw' method")}return u}var r=c(n,e.iterator,t.arg);if("throw"===r.type)return t.method="throw",t.arg=r.arg,t.delegate=null,u;var i=r.arg;return i?i.done?(t[e.resultName]=i.value,t.next=e.nextLoc,"return"!==t.method&&(t.method="next",t.arg=void 0),t.delegate=null,u):i:(t.method="throw",t.arg=new TypeError("iterator result is not an object"),t.delegate=null,u)}function O(e){var t={tryLoc:e[0]};1 in e&&(t.catchLoc=e[1]),2 in e&&(t.finallyLoc=e[2],t.afterLoc=e[3]),this.tryEntries.push(t)}function k(e){var t=e.completion||{};t.type="normal",delete t.arg,e.completion=t}function _(e){this.tryEntries=[{tryLoc:"root"}],e.forEach(O,this),this.reset(!0)}function S(e){if(e){var t=e[i];if(t)return t.call(e);if("function"==typeof e.next)return e;if(!isNaN(e.length)){var r=-1,o=function t(){for(;++r<e.length;)if(n.call(e,r))return t.value=e[r],t.done=!1,t;return t.value=void 0,t.done=!0,t};return o.next=o}}return{next:P}}function P(){return{value:void 0,done:!0}}return h.prototype=m,l(y,"constructor",m),l(m,"constructor",h),h.displayName=l(m,a,"GeneratorFunction"),e.isGeneratorFunction=function(e){var t="function"==typeof e&&e.constructor;return!!t&&(t===h||"GeneratorFunction"===(t.displayName||t.name))},e.mark=function(e){return Object.setPrototypeOf?Object.setPrototypeOf(e,m):(e.__proto__=m,l(e,a,"GeneratorFunction")),e.prototype=Object.create(y),e},e.awrap=function(e){return{__await:e}},x(w.prototype),l(w.prototype,o,(function(){return this})),e.AsyncIterator=w,e.async=function(t,n,r,i,o){void 0===o&&(o=Promise);var a=new w(s(t,n,r,i),o);return e.isGeneratorFunction(n)?a:a.next().then((function(e){return e.done?e.value:a.next()}))},x(y),l(y,a,"Generator"),l(y,i,(function(){return this})),l(y,"toString",(function(){return"[object Generator]"})),e.keys=function(e){var t=[];for(var n in e)t.push(n);return t.reverse(),function n(){for(;t.length;){var r=t.pop();if(r in e)return n.value=r,n.done=!1,n}return n.done=!0,n}},e.values=S,_.prototype={constructor:_,reset:function(e){if(this.prev=0,this.next=0,this.sent=this._sent=void 0,this.done=!1,this.delegate=null,this.method="next",this.arg=void 0,this.tryEntries.forEach(k),!e)for(var t in this)"t"===t.charAt(0)&&n.call(this,t)&&!isNaN(+t.slice(1))&&(this[t]=void 0)},stop:function(){this.done=!0;var e=this.tryEntries[0].completion;if("throw"===e.type)throw e.arg;return this.rval},dispatchException:function(e){if(this.done)throw e;var t=this;function r(n,r){return a.type="throw",a.arg=e,t.next=n,r&&(t.method="next",t.arg=void 0),!!r}for(var i=this.tryEntries.length-1;i>=0;--i){var o=this.tryEntries[i],a=o.completion;if("root"===o.tryLoc)return r("end");if(o.tryLoc<=this.prev){var l=n.call(o,"catchLoc"),s=n.call(o,"finallyLoc");if(l&&s){if(this.prev<o.catchLoc)return r(o.catchLoc,!0);if(this.prev<o.finallyLoc)return r(o.finallyLoc)}else if(l){if(this.prev<o.catchLoc)return r(o.catchLoc,!0)}else{if(!s)throw new Error("try statement without catch or finally");if(this.prev<o.finallyLoc)return r(o.finallyLoc)}}}},abrupt:function(e,t){for(var r=this.tryEntries.length-1;r>=0;--r){var i=this.tryEntries[r];if(i.tryLoc<=this.prev&&n.call(i,"finallyLoc")&&this.prev<i.finallyLoc){var o=i;break}}o&&("break"===e||"continue"===e)&&o.tryLoc<=t&&t<=o.finallyLoc&&(o=null);var a=o?o.completion:{};return a.type=e,a.arg=t,o?(this.method="next",this.next=o.finallyLoc,u):this.complete(a)},complete:function(e,t){if("throw"===e.type)throw e.arg;return"break"===e.type||"continue"===e.type?this.next=e.arg:"return"===e.type?(this.rval=this.arg=e.arg,this.method="return",this.next="end"):"normal"===e.type&&t&&(this.next=t),u},finish:function(e){for(var t=this.tryEntries.length-1;t>=0;--t){var n=this.tryEntries[t];if(n.finallyLoc===e)return this.complete(n.completion,n.afterLoc),k(n),u}},catch:function(e){for(var t=this.tryEntries.length-1;t>=0;--t){var n=this.tryEntries[t];if(n.tryLoc===e){var r=n.completion;if("throw"===r.type){var i=r.arg;k(n)}return i}}throw new Error("illegal catch attempt")},delegateYield:function(e,t,n){return this.delegate={iterator:S(e),resultName:t,nextLoc:n},"next"===this.method&&(this.arg=void 0),u}},e}function h(e,t,n,r,i,o,a){try{var l=e[o](a),s=l.value}catch(c){return void n(c)}l.done?t(s):Promise.resolve(s).then(r,i)}function m(e){return function(){var t=this,n=arguments;return new Promise((function(r,i){var o=e.apply(t,n);function a(e){h(o,r,i,a,l,"next",e)}function l(e){h(o,r,i,a,l,"throw",e)}a(void 0)}))}}function g(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function b(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}function v(e,t,n){return t&&b(e.prototype,t),n&&b(e,n),Object.defineProperty(e,"prototype",{writable:!1}),e}function y(e,t){return y=Object.setPrototypeOf?Object.setPrototypeOf.bind():function(e,t){return e.__proto__=t,e},y(e,t)}function x(e,t){if("function"!==typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function");e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,writable:!0,configurable:!0}}),Object.defineProperty(e,"prototype",{writable:!1}),t&&y(e,t)}function w(e){return w=Object.setPrototypeOf?Object.getPrototypeOf.bind():function(e){return e.__proto__||Object.getPrototypeOf(e)},w(e)}function j(e,t){if(t&&("object"===d(t)||"function"===typeof t))return t;if(void 0!==t)throw new TypeError("Derived constructors may only return object or undefined");return function(e){if(void 0===e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}(e)}function O(e){var t=function(){if("undefined"===typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"===typeof Proxy)return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],(function(){}))),!0}catch(e){return!1}}();return function(){var n,r=w(e);if(t){var i=w(this).constructor;n=Reflect.construct(r,arguments,i)}else n=r.apply(this,arguments);return j(this,n)}}var k=n(4),_=n(2),S=n(8),P=n(9),E=n(12);function C(){var e=Object(S.a)(),t=e.crypto||e.msCrypto;if(void 0!==t&&t.getRandomValues){var n=new Uint16Array(8);t.getRandomValues(n),n[3]=4095&n[3]|16384,n[4]=16383&n[4]|32768;var r=function(e){for(var t=e.toString(16);t.length<4;)t="0"+t;return t};return r(n[0])+r(n[1])+r(n[2])+r(n[3])+r(n[4])+r(n[5])+r(n[6])+r(n[7])}return"xxxxxxxxxxxx4xxxyxxxxxxxxxxxxxxx".replace(/[xy]/g,(function(e){var t=16*Math.random()|0;return("x"===e?t:3&t|8).toString(16)}))}function N(e){if(!e)return{};var t=e.match(/^(([^:/?#]+):)?(\/\/([^/?#]*))?([^?#]*)(\?([^#]*))?(#(.*))?$/);if(!t)return{};var n=t[6]||"",r=t[8]||"";return{host:t[4],path:t[5],protocol:t[2],relative:t[5]+n+r}}function T(e){return e.exception&&e.exception.values?e.exception.values[0]:void 0}function I(e){var t=e.message,n=e.event_id;if(t)return t;var r=T(e);return r?r.type&&r.value?r.type+": "+r.value:r.type||r.value||n||"<unknown>":n||"<unknown>"}function L(e,t,n){var r=e.exception=e.exception||{},i=r.values=r.values||[],o=i[0]=i[0]||{};o.value||(o.value=t||""),o.type||(o.type=n||"Error")}function M(e,t){var n=T(e);if(n){var r=n.mechanism;if(n.mechanism=Object(_.a)(Object(_.a)(Object(_.a)({},{type:"generic",handled:!0}),r),t),t&&"data"in t){var i=Object(_.a)(Object(_.a)({},r&&r.data),t.data);n.mechanism.data=i}}}function F(e){if(e&&e.__sentry_captured__)return!0;try{Object(P.a)(e,"__sentry_captured__",!0)}catch(t){}return!1}var D,z=n(27),R="undefined"===typeof __SENTRY_DEBUG__||__SENTRY_DEBUG__,U=Object(S.a)(),A="Sentry Logger ",B=["debug","info","warn","error","log","assert"];function H(e){var t=Object(S.a)();if(!("console"in t))return e();var n=t.console,r={};B.forEach((function(e){var i=n[e]&&n[e].__sentry_original__;e in t.console&&i&&(r[e]=n[e],n[e]=i)}));try{return e()}finally{Object.keys(r).forEach((function(e){n[e]=r[e]}))}}function q(){var e=!1,t={enable:function(){e=!0},disable:function(){e=!1}};return R?B.forEach((function(n){t[n]=function(){for(var t=[],r=0;r<arguments.length;r++)t[r]=arguments[r];e&&H((function(){var e;(e=U.console)[n].apply(e,Object(_.d)([A+"["+n+"]:"],t))}))}})):B.forEach((function(e){t[e]=function(){}})),t}D=R?Object(S.b)("logger",q):q();var $=n(16),W="undefined"===typeof __SENTRY_DEBUG__||__SENTRY_DEBUG__,Q=n(7);function V(e){return new K((function(t){t(e)}))}function Y(e){return new K((function(t,n){n(e)}))}var K=function(){function e(e){var t=this;this._state=0,this._handlers=[],this._resolve=function(e){t._setResult(1,e)},this._reject=function(e){t._setResult(2,e)},this._setResult=function(e,n){0===t._state&&(Object(Q.n)(n)?n.then(t._resolve,t._reject):(t._state=e,t._value=n,t._executeHandlers()))},this._executeHandlers=function(){if(0!==t._state){var e=t._handlers.slice();t._handlers=[],e.forEach((function(e){e[0]||(1===t._state&&e[1](t._value),2===t._state&&e[2](t._value),e[0]=!0)}))}};try{e(this._resolve,this._reject)}catch(n){this._reject(n)}}return e.prototype.then=function(t,n){var r=this;return new e((function(e,i){r._handlers.push([!1,function(n){if(t)try{e(t(n))}catch(r){i(r)}else e(n)},function(t){if(n)try{e(n(t))}catch(r){i(r)}else i(t)}]),r._executeHandlers()}))},e.prototype.catch=function(e){return this.then((function(e){return e}),e)},e.prototype.finally=function(t){var n=this;return new e((function(e,r){var i,o;return n.then((function(e){o=!1,i=e,t&&t()}),(function(e){o=!0,i=e,t&&t()})).then((function(){o?r(i):e(i)}))}))},e}(),G=function(){function e(){this._notifyingListeners=!1,this._scopeListeners=[],this._eventProcessors=[],this._breadcrumbs=[],this._user={},this._tags={},this._extra={},this._contexts={},this._sdkProcessingMetadata={}}return e.clone=function(t){var n=new e;return t&&(n._breadcrumbs=Object(_.d)(t._breadcrumbs),n._tags=Object(_.a)({},t._tags),n._extra=Object(_.a)({},t._extra),n._contexts=Object(_.a)({},t._contexts),n._user=t._user,n._level=t._level,n._span=t._span,n._session=t._session,n._transactionName=t._transactionName,n._fingerprint=t._fingerprint,n._eventProcessors=Object(_.d)(t._eventProcessors),n._requestSession=t._requestSession),n},e.prototype.addScopeListener=function(e){this._scopeListeners.push(e)},e.prototype.addEventProcessor=function(e){return this._eventProcessors.push(e),this},e.prototype.setUser=function(e){return this._user=e||{},this._session&&this._session.update({user:e}),this._notifyScopeListeners(),this},e.prototype.getUser=function(){return this._user},e.prototype.getRequestSession=function(){return this._requestSession},e.prototype.setRequestSession=function(e){return this._requestSession=e,this},e.prototype.setTags=function(e){return this._tags=Object(_.a)(Object(_.a)({},this._tags),e),this._notifyScopeListeners(),this},e.prototype.setTag=function(e,t){var n;return this._tags=Object(_.a)(Object(_.a)({},this._tags),((n={})[e]=t,n)),this._notifyScopeListeners(),this},e.prototype.setExtras=function(e){return this._extra=Object(_.a)(Object(_.a)({},this._extra),e),this._notifyScopeListeners(),this},e.prototype.setExtra=function(e,t){var n;return this._extra=Object(_.a)(Object(_.a)({},this._extra),((n={})[e]=t,n)),this._notifyScopeListeners(),this},e.prototype.setFingerprint=function(e){return this._fingerprint=e,this._notifyScopeListeners(),this},e.prototype.setLevel=function(e){return this._level=e,this._notifyScopeListeners(),this},e.prototype.setTransactionName=function(e){return this._transactionName=e,this._notifyScopeListeners(),this},e.prototype.setTransaction=function(e){return this.setTransactionName(e)},e.prototype.setContext=function(e,t){var n;return null===t?delete this._contexts[e]:this._contexts=Object(_.a)(Object(_.a)({},this._contexts),((n={})[e]=t,n)),this._notifyScopeListeners(),this},e.prototype.setSpan=function(e){return this._span=e,this._notifyScopeListeners(),this},e.prototype.getSpan=function(){return this._span},e.prototype.getTransaction=function(){var e=this.getSpan();return e&&e.transaction},e.prototype.setSession=function(e){return e?this._session=e:delete this._session,this._notifyScopeListeners(),this},e.prototype.getSession=function(){return this._session},e.prototype.update=function(t){if(!t)return this;if("function"===typeof t){var n=t(this);return n instanceof e?n:this}return t instanceof e?(this._tags=Object(_.a)(Object(_.a)({},this._tags),t._tags),this._extra=Object(_.a)(Object(_.a)({},this._extra),t._extra),this._contexts=Object(_.a)(Object(_.a)({},this._contexts),t._contexts),t._user&&Object.keys(t._user).length&&(this._user=t._user),t._level&&(this._level=t._level),t._fingerprint&&(this._fingerprint=t._fingerprint),t._requestSession&&(this._requestSession=t._requestSession)):Object(Q.i)(t)&&(this._tags=Object(_.a)(Object(_.a)({},this._tags),t.tags),this._extra=Object(_.a)(Object(_.a)({},this._extra),t.extra),this._contexts=Object(_.a)(Object(_.a)({},this._contexts),t.contexts),t.user&&(this._user=t.user),t.level&&(this._level=t.level),t.fingerprint&&(this._fingerprint=t.fingerprint),t.requestSession&&(this._requestSession=t.requestSession)),this},e.prototype.clear=function(){return this._breadcrumbs=[],this._tags={},this._extra={},this._user={},this._contexts={},this._level=void 0,this._transactionName=void 0,this._fingerprint=void 0,this._requestSession=void 0,this._span=void 0,this._session=void 0,this._notifyScopeListeners(),this},e.prototype.addBreadcrumb=function(e,t){var n="number"===typeof t?Math.min(t,100):100;if(n<=0)return this;var r=Object(_.a)({timestamp:Object(z.a)()},e);return this._breadcrumbs=Object(_.d)(this._breadcrumbs,[r]).slice(-n),this._notifyScopeListeners(),this},e.prototype.clearBreadcrumbs=function(){return this._breadcrumbs=[],this._notifyScopeListeners(),this},e.prototype.applyToEvent=function(e,t){if(this._extra&&Object.keys(this._extra).length&&(e.extra=Object(_.a)(Object(_.a)({},this._extra),e.extra)),this._tags&&Object.keys(this._tags).length&&(e.tags=Object(_.a)(Object(_.a)({},this._tags),e.tags)),this._user&&Object.keys(this._user).length&&(e.user=Object(_.a)(Object(_.a)({},this._user),e.user)),this._contexts&&Object.keys(this._contexts).length&&(e.contexts=Object(_.a)(Object(_.a)({},this._contexts),e.contexts)),this._level&&(e.level=this._level),this._transactionName&&(e.transaction=this._transactionName),this._span){e.contexts=Object(_.a)({trace:this._span.getTraceContext()},e.contexts);var n=this._span.transaction&&this._span.transaction.name;n&&(e.tags=Object(_.a)({transaction:n},e.tags))}return this._applyFingerprint(e),e.breadcrumbs=Object(_.d)(e.breadcrumbs||[],this._breadcrumbs),e.breadcrumbs=e.breadcrumbs.length>0?e.breadcrumbs:void 0,e.sdkProcessingMetadata=this._sdkProcessingMetadata,this._notifyEventProcessors(Object(_.d)(J(),this._eventProcessors),e,t)},e.prototype.setSDKProcessingMetadata=function(e){return this._sdkProcessingMetadata=Object(_.a)(Object(_.a)({},this._sdkProcessingMetadata),e),this},e.prototype._notifyEventProcessors=function(e,t,n,r){var i=this;return void 0===r&&(r=0),new K((function(o,a){var l=e[r];if(null===t||"function"!==typeof l)o(t);else{var s=l(Object(_.a)({},t),n);Object(Q.n)(s)?s.then((function(t){return i._notifyEventProcessors(e,t,n,r+1).then(o)})).then(null,a):i._notifyEventProcessors(e,s,n,r+1).then(o).then(null,a)}}))},e.prototype._notifyScopeListeners=function(){var e=this;this._notifyingListeners||(this._notifyingListeners=!0,this._scopeListeners.forEach((function(t){t(e)})),this._notifyingListeners=!1)},e.prototype._applyFingerprint=function(e){e.fingerprint=e.fingerprint?Array.isArray(e.fingerprint)?e.fingerprint:[e.fingerprint]:[],this._fingerprint&&(e.fingerprint=e.fingerprint.concat(this._fingerprint)),e.fingerprint&&!e.fingerprint.length&&delete e.fingerprint},e}();function J(){return Object(S.b)("globalEventProcessors",(function(){return[]}))}function X(e){J().push(e)}var Z,ee=function(){function e(e){this.errors=0,this.sid=C(),this.duration=0,this.status="ok",this.init=!0,this.ignoreDuration=!1;var t=Object(z.b)();this.timestamp=t,this.started=t,e&&this.update(e)}return e.prototype.update=function(e){if(void 0===e&&(e={}),e.user&&(!this.ipAddress&&e.user.ip_address&&(this.ipAddress=e.user.ip_address),this.did||e.did||(this.did=e.user.id||e.user.email||e.user.username)),this.timestamp=e.timestamp||Object(z.b)(),e.ignoreDuration&&(this.ignoreDuration=e.ignoreDuration),e.sid&&(this.sid=32===e.sid.length?e.sid:C()),void 0!==e.init&&(this.init=e.init),!this.did&&e.did&&(this.did=""+e.did),"number"===typeof e.started&&(this.started=e.started),this.ignoreDuration)this.duration=void 0;else if("number"===typeof e.duration)this.duration=e.duration;else{var t=this.timestamp-this.started;this.duration=t>=0?t:0}e.release&&(this.release=e.release),e.environment&&(this.environment=e.environment),!this.ipAddress&&e.ipAddress&&(this.ipAddress=e.ipAddress),!this.userAgent&&e.userAgent&&(this.userAgent=e.userAgent),"number"===typeof e.errors&&(this.errors=e.errors),e.status&&(this.status=e.status)},e.prototype.close=function(e){e?this.update({status:e}):"ok"===this.status?this.update({status:"exited"}):this.update()},e.prototype.toJSON=function(){return Object(P.c)({sid:""+this.sid,init:this.init,started:new Date(1e3*this.started).toISOString(),timestamp:new Date(1e3*this.timestamp).toISOString(),status:this.status,errors:this.errors,did:"number"===typeof this.did||"string"===typeof this.did?""+this.did:void 0,duration:this.duration,attrs:{release:this.release,environment:this.environment,ip_address:this.ipAddress,user_agent:this.userAgent}})},e}(),te=function(){function e(e,t,n){void 0===t&&(t=new G),void 0===n&&(n=4),this._version=n,this._stack=[{}],this.getStackTop().scope=t,e&&this.bindClient(e)}return e.prototype.isOlderThan=function(e){return this._version<e},e.prototype.bindClient=function(e){this.getStackTop().client=e,e&&e.setupIntegrations&&e.setupIntegrations()},e.prototype.pushScope=function(){var e=G.clone(this.getScope());return this.getStack().push({client:this.getClient(),scope:e}),e},e.prototype.popScope=function(){return!(this.getStack().length<=1)&&!!this.getStack().pop()},e.prototype.withScope=function(e){var t=this.pushScope();try{e(t)}finally{this.popScope()}},e.prototype.getClient=function(){return this.getStackTop().client},e.prototype.getScope=function(){return this.getStackTop().scope},e.prototype.getStack=function(){return this._stack},e.prototype.getStackTop=function(){return this._stack[this._stack.length-1]},e.prototype.captureException=function(e,t){var n=this._lastEventId=t&&t.event_id?t.event_id:C(),r=t;if(!t){var i=void 0;try{throw new Error("Sentry syntheticException")}catch(e){i=e}r={originalException:e,syntheticException:i}}return this._invokeClient("captureException",e,Object(_.a)(Object(_.a)({},r),{event_id:n})),n},e.prototype.captureMessage=function(e,t,n){var r=this._lastEventId=n&&n.event_id?n.event_id:C(),i=n;if(!n){var o=void 0;try{throw new Error(e)}catch(a){o=a}i={originalException:e,syntheticException:o}}return this._invokeClient("captureMessage",e,t,Object(_.a)(Object(_.a)({},i),{event_id:r})),r},e.prototype.captureEvent=function(e,t){var n=t&&t.event_id?t.event_id:C();return"transaction"!==e.type&&(this._lastEventId=n),this._invokeClient("captureEvent",e,Object(_.a)(Object(_.a)({},t),{event_id:n})),n},e.prototype.lastEventId=function(){return this._lastEventId},e.prototype.addBreadcrumb=function(e,t){var n=this.getStackTop(),r=n.scope,i=n.client;if(r&&i){var o=i.getOptions&&i.getOptions()||{},a=o.beforeBreadcrumb,l=void 0===a?null:a,s=o.maxBreadcrumbs,c=void 0===s?100:s;if(!(c<=0)){var u=Object(z.a)(),p=Object(_.a)({timestamp:u},e),d=l?H((function(){return l(p,t)})):p;null!==d&&r.addBreadcrumb(d,c)}}},e.prototype.setUser=function(e){var t=this.getScope();t&&t.setUser(e)},e.prototype.setTags=function(e){var t=this.getScope();t&&t.setTags(e)},e.prototype.setExtras=function(e){var t=this.getScope();t&&t.setExtras(e)},e.prototype.setTag=function(e,t){var n=this.getScope();n&&n.setTag(e,t)},e.prototype.setExtra=function(e,t){var n=this.getScope();n&&n.setExtra(e,t)},e.prototype.setContext=function(e,t){var n=this.getScope();n&&n.setContext(e,t)},e.prototype.configureScope=function(e){var t=this.getStackTop(),n=t.scope,r=t.client;n&&r&&e(n)},e.prototype.run=function(e){var t=re(this);try{e(this)}finally{re(t)}},e.prototype.getIntegration=function(e){var t=this.getClient();if(!t)return null;try{return t.getIntegration(e)}catch(n){return W&&D.warn("Cannot retrieve integration "+e.id+" from the current Hub"),null}},e.prototype.startSpan=function(e){return this._callExtensionMethod("startSpan",e)},e.prototype.startTransaction=function(e,t){return this._callExtensionMethod("startTransaction",e,t)},e.prototype.traceHeaders=function(){return this._callExtensionMethod("traceHeaders")},e.prototype.captureSession=function(e){if(void 0===e&&(e=!1),e)return this.endSession();this._sendSessionUpdate()},e.prototype.endSession=function(){var e=this.getStackTop(),t=e&&e.scope,n=t&&t.getSession();n&&n.close(),this._sendSessionUpdate(),t&&t.setSession()},e.prototype.startSession=function(e){var t=this.getStackTop(),n=t.scope,r=t.client,i=r&&r.getOptions()||{},o=i.release,a=i.environment,l=(Object(S.a)().navigator||{}).userAgent,s=new ee(Object(_.a)(Object(_.a)(Object(_.a)({release:o,environment:a},n&&{user:n.getUser()}),l&&{userAgent:l}),e));if(n){var c=n.getSession&&n.getSession();c&&"ok"===c.status&&c.update({status:"exited"}),this.endSession(),n.setSession(s)}return s},e.prototype._sendSessionUpdate=function(){var e=this.getStackTop(),t=e.scope,n=e.client;if(t){var r=t.getSession&&t.getSession();r&&n&&n.captureSession&&n.captureSession(r)}},e.prototype._invokeClient=function(e){for(var t,n=[],r=1;r<arguments.length;r++)n[r-1]=arguments[r];var i=this.getStackTop(),o=i.scope,a=i.client;a&&a[e]&&(t=a)[e].apply(t,Object(_.d)(n,[o]))},e.prototype._callExtensionMethod=function(e){for(var t=[],n=1;n<arguments.length;n++)t[n-1]=arguments[n];var r=ne(),i=r.__SENTRY__;if(i&&i.extensions&&"function"===typeof i.extensions[e])return i.extensions[e].apply(this,t);W&&D.warn("Extension method "+e+" couldn't be found, doing nothing.")},e}();function ne(){var e=Object(S.a)();return e.__SENTRY__=e.__SENTRY__||{extensions:{},hub:void 0},e}function re(e){var t=ne(),n=ae(t);return le(t,e),n}function ie(){var e=ne();return oe(e)&&!ae(e).isOlderThan(4)||le(e,new te),Object($.b)()?function(e){try{var t=ne().__SENTRY__,n=t&&t.extensions&&t.extensions.domain&&t.extensions.domain.active;if(!n)return ae(e);if(!oe(n)||ae(n).isOlderThan(4)){var r=ae(e).getStackTop();le(n,new te(r.client,G.clone(r.scope)))}return ae(n)}catch(i){return ae(e)}}(e):ae(e)}function oe(e){return!!(e&&e.__SENTRY__&&e.__SENTRY__.hub)}function ae(e){return Object(S.b)("hub",(function(){return new te}),e)}function le(e,t){return!!e&&((e.__SENTRY__=e.__SENTRY__||{}).hub=t,!0)}function se(e){for(var t=[],n=1;n<arguments.length;n++)t[n-1]=arguments[n];var r=ie();if(r&&r[e])return r[e].apply(r,Object(_.d)(t));throw new Error("No hub defined or "+e+" was not found on the hub, please open a bug report.")}function ce(e,t){return se("captureException",e,{captureContext:t,originalException:e,syntheticException:new Error("Sentry syntheticException")})}function ue(e){se("withScope",e)}var pe=function(){function e(){this.name=e.id}return e.prototype.setupOnce=function(){Z=Function.prototype.toString,Function.prototype.toString=function(){for(var e=[],t=0;t<arguments.length;t++)e[t]=arguments[t];var n=Object(P.f)(this)||this;return Z.apply(n,e)}},e.id="FunctionToString",e}(),de="undefined"===typeof __SENTRY_DEBUG__||__SENTRY_DEBUG__,fe=[/^Script error\.?$/,/^Javascript error: Script error\.? on line 0$/],he=function(){function e(t){void 0===t&&(t={}),this._options=t,this.name=e.id}return e.prototype.setupOnce=function(t,n){t((function(t){var r=n();if(r){var i=r.getIntegration(e);if(i){var o=r.getClient(),a=o?o.getOptions():{},l=function(e,t){void 0===e&&(e={});void 0===t&&(t={});return{allowUrls:Object(_.d)(e.whitelistUrls||[],e.allowUrls||[],t.whitelistUrls||[],t.allowUrls||[]),denyUrls:Object(_.d)(e.blacklistUrls||[],e.denyUrls||[],t.blacklistUrls||[],t.denyUrls||[]),ignoreErrors:Object(_.d)(e.ignoreErrors||[],t.ignoreErrors||[],fe),ignoreInternal:void 0===e.ignoreInternal||e.ignoreInternal}}(i._options,a);return function(e,t){if(t.ignoreInternal&&function(e){try{return"SentryError"===e.exception.values[0].type}catch(t){}return!1}(e))return de&&D.warn("Event dropped due to being internal Sentry Error.\nEvent: "+I(e)),!0;if(function(e,t){if(!t||!t.length)return!1;return function(e){if(e.message)return[e.message];if(e.exception)try{var t=e.exception.values&&e.exception.values[0]||{},n=t.type,r=void 0===n?"":n,i=t.value,o=void 0===i?"":i;return[""+o,r+": "+o]}catch(a){return de&&D.error("Cannot extract message for event "+I(e)),[]}return[]}(e).some((function(e){return t.some((function(t){return Object(E.a)(e,t)}))}))}(e,t.ignoreErrors))return de&&D.warn("Event dropped due to being matched by `ignoreErrors` option.\nEvent: "+I(e)),!0;if(function(e,t){if(!t||!t.length)return!1;var n=ge(e);return!!n&&t.some((function(e){return Object(E.a)(n,e)}))}(e,t.denyUrls))return de&&D.warn("Event dropped due to being matched by `denyUrls` option.\nEvent: "+I(e)+".\nUrl: "+ge(e)),!0;if(!function(e,t){if(!t||!t.length)return!0;var n=ge(e);return!n||t.some((function(e){return Object(E.a)(n,e)}))}(e,t.allowUrls))return de&&D.warn("Event dropped due to not being matched by `allowUrls` option.\nEvent: "+I(e)+".\nUrl: "+ge(e)),!0;return!1}(t,l)?null:t}}return t}))},e.id="InboundFilters",e}();function me(e){void 0===e&&(e=[]);for(var t=e.length-1;t>=0;t--){var n=e[t];if(n&&"<anonymous>"!==n.filename&&"[native code]"!==n.filename)return n.filename||null}return null}function ge(e){try{if(e.stacktrace)return me(e.stacktrace.frames);var t;try{t=e.exception.values[0].stacktrace.frames}catch(n){}return t?me(t):null}catch(r){return de&&D.error("Cannot extract url for event "+I(e)),null}}var be=n(21);function ve(){if(!("fetch"in Object(S.a)()))return!1;try{return new Headers,new Request(""),new Response,!0}catch(e){return!1}}function ye(e){return e&&/^function fetch\(\)\s+\{\s+\[native code\]\s+\}$/.test(e.toString())}function xe(){if(!ve())return!1;try{return new Request("_",{referrerPolicy:"origin"}),!0}catch(e){return!1}}var we,je=Object(S.a)(),Oe={},ke={};function _e(e){if(!ke[e])switch(ke[e]=!0,e){case"console":!function(){if(!("console"in je))return;B.forEach((function(e){e in je.console&&Object(P.e)(je.console,e,(function(t){return function(){for(var n=[],r=0;r<arguments.length;r++)n[r]=arguments[r];Pe("console",{args:n,level:e}),t&&t.apply(je.console,n)}}))}))}();break;case"dom":!function(){if(!("document"in je))return;var e=Pe.bind(null,"dom"),t=Ie(e,!0);je.document.addEventListener("click",t,!1),je.document.addEventListener("keypress",t,!1),["EventTarget","Node"].forEach((function(t){var n=je[t]&&je[t].prototype;n&&n.hasOwnProperty&&n.hasOwnProperty("addEventListener")&&(Object(P.e)(n,"addEventListener",(function(t){return function(n,r,i){if("click"===n||"keypress"==n)try{var o=this,a=o.__sentry_instrumentation_handlers__=o.__sentry_instrumentation_handlers__||{},l=a[n]=a[n]||{refCount:0};if(!l.handler){var s=Ie(e);l.handler=s,t.call(this,n,s,i)}l.refCount+=1}catch(c){}return t.call(this,n,r,i)}})),Object(P.e)(n,"removeEventListener",(function(e){return function(t,n,r){if("click"===t||"keypress"==t)try{var i=this,o=i.__sentry_instrumentation_handlers__||{},a=o[t];a&&(a.refCount-=1,a.refCount<=0&&(e.call(this,t,a.handler,r),a.handler=void 0,delete o[t]),0===Object.keys(o).length&&delete i.__sentry_instrumentation_handlers__)}catch(l){}return e.call(this,t,n,r)}})))}))}();break;case"xhr":!function(){if(!("XMLHttpRequest"in je))return;var e=XMLHttpRequest.prototype;Object(P.e)(e,"open",(function(e){return function(){for(var t=[],n=0;n<arguments.length;n++)t[n]=arguments[n];var r=this,i=t[1],o=r.__sentry_xhr__={method:Object(Q.l)(t[0])?t[0].toUpperCase():t[0],url:t[1]};Object(Q.l)(i)&&"POST"===o.method&&i.match(/sentry_key/)&&(r.__sentry_own_request__=!0);var a=function(){if(4===r.readyState){try{o.status_code=r.status}catch(e){}Pe("xhr",{args:t,endTimestamp:Date.now(),startTimestamp:Date.now(),xhr:r})}};return"onreadystatechange"in r&&"function"===typeof r.onreadystatechange?Object(P.e)(r,"onreadystatechange",(function(e){return function(){for(var t=[],n=0;n<arguments.length;n++)t[n]=arguments[n];return a(),e.apply(r,t)}})):r.addEventListener("readystatechange",a),e.apply(r,t)}})),Object(P.e)(e,"send",(function(e){return function(){for(var t=[],n=0;n<arguments.length;n++)t[n]=arguments[n];return this.__sentry_xhr__&&void 0!==t[0]&&(this.__sentry_xhr__.body=t[0]),Pe("xhr",{args:t,startTimestamp:Date.now(),xhr:this}),e.apply(this,t)}}))}();break;case"fetch":!function(){if(!function(){if(!ve())return!1;var e=Object(S.a)();if(ye(e.fetch))return!0;var t=!1,n=e.document;if(n&&"function"===typeof n.createElement)try{var r=n.createElement("iframe");r.hidden=!0,n.head.appendChild(r),r.contentWindow&&r.contentWindow.fetch&&(t=ye(r.contentWindow.fetch)),n.head.removeChild(r)}catch(i){R&&D.warn("Could not create sandbox iframe for pure fetch check, bailing to window.fetch: ",i)}return t}())return;Object(P.e)(je,"fetch",(function(e){return function(){for(var t=[],n=0;n<arguments.length;n++)t[n]=arguments[n];var r={args:t,fetchData:{method:Ee(t),url:Ce(t)},startTimestamp:Date.now()};return Pe("fetch",Object(_.a)({},r)),e.apply(je,t).then((function(e){return Pe("fetch",Object(_.a)(Object(_.a)({},r),{endTimestamp:Date.now(),response:e})),e}),(function(e){throw Pe("fetch",Object(_.a)(Object(_.a)({},r),{endTimestamp:Date.now(),error:e})),e}))}}))}();break;case"history":!function(){if(!function(){var e=Object(S.a)(),t=e.chrome,n=t&&t.app&&t.app.runtime,r="history"in e&&!!e.history.pushState&&!!e.history.replaceState;return!n&&r}())return;var e=je.onpopstate;function t(e){return function(){for(var t=[],n=0;n<arguments.length;n++)t[n]=arguments[n];var r=t.length>2?t[2]:void 0;if(r){var i=we,o=String(r);we=o,Pe("history",{from:i,to:o})}return e.apply(this,t)}}je.onpopstate=function(){for(var t=[],n=0;n<arguments.length;n++)t[n]=arguments[n];var r=je.location.href,i=we;if(we=r,Pe("history",{from:i,to:r}),e)try{return e.apply(this,t)}catch(o){}},Object(P.e)(je.history,"pushState",t),Object(P.e)(je.history,"replaceState",t)}();break;case"error":Le=je.onerror,je.onerror=function(e,t,n,r,i){return Pe("error",{column:r,error:i,line:n,msg:e,url:t}),!!Le&&Le.apply(this,arguments)};break;case"unhandledrejection":Me=je.onunhandledrejection,je.onunhandledrejection=function(e){return Pe("unhandledrejection",e),!Me||Me.apply(this,arguments)};break;default:return void(R&&D.warn("unknown instrumentation type:",e))}}function Se(e,t){Oe[e]=Oe[e]||[],Oe[e].push(t),_e(e)}function Pe(e,t){var n,r;if(e&&Oe[e])try{for(var i=Object(_.e)(Oe[e]||[]),o=i.next();!o.done;o=i.next()){var a=o.value;try{a(t)}catch(l){R&&D.error("Error while triggering instrumentation handler.\nType: "+e+"\nName: "+Object(be.b)(a)+"\nError:",l)}}}catch(s){n={error:s}}finally{try{o&&!o.done&&(r=i.return)&&r.call(i)}finally{if(n)throw n.error}}}function Ee(e){return void 0===e&&(e=[]),"Request"in je&&Object(Q.g)(e[0],Request)&&e[0].method?String(e[0].method).toUpperCase():e[1]&&e[1].method?String(e[1].method).toUpperCase():"GET"}function Ce(e){return void 0===e&&(e=[]),"string"===typeof e[0]?e[0]:"Request"in je&&Object(Q.g)(e[0],Request)?e[0].url:String(e[0])}var Ne,Te;function Ie(e,t){return void 0===t&&(t=!1),function(n){if(n&&Te!==n&&!function(e){if("keypress"!==e.type)return!1;try{var t=e.target;if(!t||!t.tagName)return!0;if("INPUT"===t.tagName||"TEXTAREA"===t.tagName||t.isContentEditable)return!1}catch(n){}return!0}(n)){var r="keypress"===n.type?"input":n.type;(void 0===Ne||function(e,t){if(!e)return!0;if(e.type!==t.type)return!0;try{if(e.target!==t.target)return!0}catch(n){}return!1}(Te,n))&&(e({event:n,name:r,global:t}),Te=n),clearTimeout(Ne),Ne=je.setTimeout((function(){Ne=void 0}),1e3)}}}var Le=null;var Me=null;var Fe="6.19.7",De=Object.setPrototypeOf||({__proto__:[]}instanceof Array?function(e,t){return e.__proto__=t,e}:function(e,t){for(var n in t)Object.prototype.hasOwnProperty.call(e,n)||(e[n]=t[n]);return e});var ze=function(e){function t(t){var n=this.constructor,r=e.call(this,t)||this;return r.message=t,r.name=n.prototype.constructor.name,De(r,n.prototype),r}return Object(_.b)(t,e),t}(Error),Re=/^(?:(\w+):)\/\/(?:(\w+)(?::(\w+))?@)([\w.-]+)(?::(\d+))?\/(.+)/;function Ue(e,t){void 0===t&&(t=!1);var n=e.host,r=e.path,i=e.pass,o=e.port,a=e.projectId;return e.protocol+"://"+e.publicKey+(t&&i?":"+i:"")+"@"+n+(o?":"+o:"")+"/"+(r?r+"/":r)+a}function Ae(e){return"user"in e&&!("publicKey"in e)&&(e.publicKey=e.user),{user:e.publicKey||"",protocol:e.protocol,publicKey:e.publicKey||"",pass:e.pass||"",host:e.host,port:e.port||"",path:e.path||"",projectId:e.projectId}}function Be(e){var t="string"===typeof e?function(e){var t=Re.exec(e);if(!t)throw new ze("Invalid Sentry Dsn: "+e);var n=Object(_.c)(t.slice(1),6),r=n[0],i=n[1],o=n[2],a=void 0===o?"":o,l=n[3],s=n[4],c=void 0===s?"":s,u="",p=n[5],d=p.split("/");if(d.length>1&&(u=d.slice(0,-1).join("/"),p=d.pop()),p){var f=p.match(/^\d+/);f&&(p=f[0])}return Ae({host:l,pass:a,path:u,projectId:p,port:c,protocol:r,publicKey:i})}(e):Ae(e);return function(e){if(R){var t=e.port,n=e.projectId,r=e.protocol;if(["protocol","publicKey","host","projectId"].forEach((function(t){if(!e[t])throw new ze("Invalid Sentry Dsn: "+t+" missing")})),!n.match(/^\d+$/))throw new ze("Invalid Sentry Dsn: Invalid projectId "+n);if(!function(e){return"http"===e||"https"===e}(r))throw new ze("Invalid Sentry Dsn: Invalid protocol "+r);if(t&&isNaN(parseInt(t,10)))throw new ze("Invalid Sentry Dsn: Invalid port "+t)}}(t),t}var He=n(49),qe=[];function $e(e){return e.reduce((function(e,t){return e.every((function(e){return t.name!==e.name}))&&e.push(t),e}),[])}function We(e){var t={};return function(e){var t=e.defaultIntegrations&&Object(_.d)(e.defaultIntegrations)||[],n=e.integrations,r=Object(_.d)($e(t));Array.isArray(n)?r=Object(_.d)(r.filter((function(e){return n.every((function(t){return t.name!==e.name}))})),$e(n)):"function"===typeof n&&(r=n(r),r=Array.isArray(r)?r:[r]);var i=r.map((function(e){return e.name})),o="Debug";return-1!==i.indexOf(o)&&r.push.apply(r,Object(_.d)(r.splice(i.indexOf(o),1))),r}(e).forEach((function(e){t[e.name]=e,function(e){-1===qe.indexOf(e.name)&&(e.setupOnce(X,ie),qe.push(e.name),de&&D.log("Integration installed: "+e.name))}(e)})),Object(P.a)(t,"initialized",!0),t}var Qe="Not capturing exception because it's already been captured.",Ve=function(){function e(e,t){this._integrations={},this._numProcessing=0,this._backend=new e(t),this._options=t,t.dsn&&(this._dsn=Be(t.dsn))}return e.prototype.captureException=function(e,t,n){var r=this;if(!F(e)){var i=t&&t.event_id;return this._process(this._getBackend().eventFromException(e,t).then((function(e){return r._captureEvent(e,t,n)})).then((function(e){i=e}))),i}de&&D.log(Qe)},e.prototype.captureMessage=function(e,t,n,r){var i=this,o=n&&n.event_id,a=Object(Q.j)(e)?this._getBackend().eventFromMessage(String(e),t,n):this._getBackend().eventFromException(e,n);return this._process(a.then((function(e){return i._captureEvent(e,n,r)})).then((function(e){o=e}))),o},e.prototype.captureEvent=function(e,t,n){if(!(t&&t.originalException&&F(t.originalException))){var r=t&&t.event_id;return this._process(this._captureEvent(e,t,n).then((function(e){r=e}))),r}de&&D.log(Qe)},e.prototype.captureSession=function(e){this._isEnabled()?"string"!==typeof e.release?de&&D.warn("Discarded session because of missing or non-string release"):(this._sendSession(e),e.update({init:!1})):de&&D.warn("SDK not enabled, will not capture session.")},e.prototype.getDsn=function(){return this._dsn},e.prototype.getOptions=function(){return this._options},e.prototype.getTransport=function(){return this._getBackend().getTransport()},e.prototype.flush=function(e){var t=this;return this._isClientDoneProcessing(e).then((function(n){return t.getTransport().close(e).then((function(e){return n&&e}))}))},e.prototype.close=function(e){var t=this;return this.flush(e).then((function(e){return t.getOptions().enabled=!1,e}))},e.prototype.setupIntegrations=function(){this._isEnabled()&&!this._integrations.initialized&&(this._integrations=We(this._options))},e.prototype.getIntegration=function(e){try{return this._integrations[e.id]||null}catch(t){return de&&D.warn("Cannot retrieve integration "+e.id+" from the current Client"),null}},e.prototype._updateSessionFromEvent=function(e,t){var n,r,i=!1,o=!1,a=t.exception&&t.exception.values;if(a){o=!0;try{for(var l=Object(_.e)(a),s=l.next();!s.done;s=l.next()){var c=s.value.mechanism;if(c&&!1===c.handled){i=!0;break}}}catch(p){n={error:p}}finally{try{s&&!s.done&&(r=l.return)&&r.call(l)}finally{if(n)throw n.error}}}var u="ok"===e.status;(u&&0===e.errors||u&&i)&&(e.update(Object(_.a)(Object(_.a)({},i&&{status:"crashed"}),{errors:e.errors||Number(o||i)})),this.captureSession(e))},e.prototype._sendSession=function(e){this._getBackend().sendSession(e)},e.prototype._isClientDoneProcessing=function(e){var t=this;return new K((function(n){var r=0,i=setInterval((function(){0==t._numProcessing?(clearInterval(i),n(!0)):(r+=1,e&&r>=e&&(clearInterval(i),n(!1)))}),1)}))},e.prototype._getBackend=function(){return this._backend},e.prototype._isEnabled=function(){return!1!==this.getOptions().enabled&&void 0!==this._dsn},e.prototype._prepareEvent=function(e,t,n){var r=this,i=this.getOptions(),o=i.normalizeDepth,a=void 0===o?3:o,l=i.normalizeMaxBreadth,s=void 0===l?1e3:l,c=Object(_.a)(Object(_.a)({},e),{event_id:e.event_id||(n&&n.event_id?n.event_id:C()),timestamp:e.timestamp||Object(z.a)()});this._applyClientOptions(c),this._applyIntegrationsMetadata(c);var u=t;n&&n.captureContext&&(u=G.clone(u).update(n.captureContext));var p=V(c);return u&&(p=u.applyToEvent(c,n)),p.then((function(e){return e&&(e.sdkProcessingMetadata=Object(_.a)(Object(_.a)({},e.sdkProcessingMetadata),{normalizeDepth:Object(He.a)(a)+" ("+typeof a+")"})),"number"===typeof a&&a>0?r._normalizeEvent(e,a,s):e}))},e.prototype._normalizeEvent=function(e,t,n){if(!e)return null;var r=Object(_.a)(Object(_.a)(Object(_.a)(Object(_.a)(Object(_.a)({},e),e.breadcrumbs&&{breadcrumbs:e.breadcrumbs.map((function(e){return Object(_.a)(Object(_.a)({},e),e.data&&{data:Object(He.a)(e.data,t,n)})}))}),e.user&&{user:Object(He.a)(e.user,t,n)}),e.contexts&&{contexts:Object(He.a)(e.contexts,t,n)}),e.extra&&{extra:Object(He.a)(e.extra,t,n)});return e.contexts&&e.contexts.trace&&(r.contexts.trace=e.contexts.trace),r.sdkProcessingMetadata=Object(_.a)(Object(_.a)({},r.sdkProcessingMetadata),{baseClientNormalized:!0}),r},e.prototype._applyClientOptions=function(e){var t=this.getOptions(),n=t.environment,r=t.release,i=t.dist,o=t.maxValueLength,a=void 0===o?250:o;"environment"in e||(e.environment="environment"in t?n:"production"),void 0===e.release&&void 0!==r&&(e.release=r),void 0===e.dist&&void 0!==i&&(e.dist=i),e.message&&(e.message=Object(E.d)(e.message,a));var l=e.exception&&e.exception.values&&e.exception.values[0];l&&l.value&&(l.value=Object(E.d)(l.value,a));var s=e.request;s&&s.url&&(s.url=Object(E.d)(s.url,a))},e.prototype._applyIntegrationsMetadata=function(e){var t=Object.keys(this._integrations);t.length>0&&(e.sdk=e.sdk||{},e.sdk.integrations=Object(_.d)(e.sdk.integrations||[],t))},e.prototype._sendEvent=function(e){this._getBackend().sendEvent(e)},e.prototype._captureEvent=function(e,t,n){return this._processEvent(e,t,n).then((function(e){return e.event_id}),(function(e){de&&D.error(e)}))},e.prototype._processEvent=function(e,t,n){var r=this,i=this.getOptions(),o=i.beforeSend,a=i.sampleRate,l=this.getTransport();function s(e,t){l.recordLostEvent&&l.recordLostEvent(e,t)}if(!this._isEnabled())return Y(new ze("SDK not enabled, will not capture event."));var c="transaction"===e.type;return!c&&"number"===typeof a&&Math.random()>a?(s("sample_rate","event"),Y(new ze("Discarding event because it's not included in the random sample (sampling rate = "+a+")"))):this._prepareEvent(e,n,t).then((function(n){if(null===n)throw s("event_processor",e.type||"event"),new ze("An event processor returned null, will not send event.");return t&&t.data&&!0===t.data.__sentry__||c||!o?n:function(e){var t="`beforeSend` method has to return `null` or a valid event.";if(Object(Q.n)(e))return e.then((function(e){if(!Object(Q.i)(e)&&null!==e)throw new ze(t);return e}),(function(e){throw new ze("beforeSend rejected with "+e)}));if(!Object(Q.i)(e)&&null!==e)throw new ze(t);return e}(o(n,t))})).then((function(t){if(null===t)throw s("before_send",e.type||"event"),new ze("`beforeSend` returned `null`, will not send event.");var i=n&&n.getSession&&n.getSession();return!c&&i&&r._updateSessionFromEvent(i,t),r._sendEvent(t),t})).then(null,(function(e){if(e instanceof ze)throw e;throw r.captureException(e,{data:{__sentry__:!0},originalException:e}),new ze("Event processing pipeline threw an error, original event will not be sent. Details have been sent as a new event.\nReason: "+e)}))},e.prototype._process=function(e){var t=this;this._numProcessing+=1,e.then((function(e){return t._numProcessing-=1,e}),(function(e){return t._numProcessing-=1,e}))},e}();!function(){function e(e,t,n){void 0===t&&(t={}),this.dsn=e,this._dsnObject=Be(e),this.metadata=t,this._tunnel=n}e.prototype.getDsn=function(){return this._dsnObject},e.prototype.forceEnvelope=function(){return!!this._tunnel},e.prototype.getBaseApiEndpoint=function(){return Ke(this._dsnObject)},e.prototype.getStoreEndpoint=function(){return Xe(this._dsnObject)},e.prototype.getStoreEndpointWithUrlEncodedAuth=function(){return Ze(this._dsnObject)},e.prototype.getEnvelopeEndpointWithUrlEncodedAuth=function(){return et(this._dsnObject,this._tunnel)}}();function Ye(e,t,n){return{initDsn:e,metadata:t||{},dsn:Be(e),tunnel:n}}function Ke(e){var t=e.protocol?e.protocol+":":"",n=e.port?":"+e.port:"";return t+"//"+e.host+n+(e.path?"/"+e.path:"")+"/api/"}function Ge(e,t){return""+Ke(e)+e.projectId+"/"+t+"/"}function Je(e){return Object(P.h)({sentry_key:e.publicKey,sentry_version:"7"})}function Xe(e){return Ge(e,"store")}function Ze(e){return Xe(e)+"?"+Je(e)}function et(e,t){return t||function(e){return Ge(e,"envelope")}(e)+"?"+Je(e)}function tt(e,t){return void 0===t&&(t=[]),[e,t]}function nt(e){var t=Object(_.c)(e,2),n=t[0],r=t[1],i=JSON.stringify(n);return r.reduce((function(e,t){var n=Object(_.c)(t,2),r=n[0],i=n[1],o=Object(Q.j)(i)?String(i):JSON.stringify(i);return e+"\n"+JSON.stringify(r)+"\n"+o}),i)}function rt(e){if(e.metadata&&e.metadata.sdk){var t=e.metadata.sdk;return{name:t.name,version:t.version}}}function it(e,t){return t?(e.sdk=e.sdk||{},e.sdk.name=e.sdk.name||t.name,e.sdk.version=e.sdk.version||t.version,e.sdk.integrations=Object(_.d)(e.sdk.integrations||[],t.integrations||[]),e.sdk.packages=Object(_.d)(e.sdk.packages||[],t.packages||[]),e):e}function ot(e,t){var n=rt(t),r="aggregates"in e?"sessions":"session";return[tt(Object(_.a)(Object(_.a)({sent_at:(new Date).toISOString()},n&&{sdk:n}),!!t.tunnel&&{dsn:Ue(t.dsn)}),[[{type:r},e]]),r]}var at,lt=function(){function e(){}return e.prototype.sendEvent=function(e){return V({reason:"NoopTransport: Event has been skipped because no Dsn is configured.",status:"skipped"})},e.prototype.close=function(e){return V(!0)},e}(),st=function(){function e(e){this._options=e,this._options.dsn||de&&D.warn("No DSN provided, backend will not do anything."),this._transport=this._setupTransport()}return e.prototype.eventFromException=function(e,t){throw new ze("Backend has to implement `eventFromException` method")},e.prototype.eventFromMessage=function(e,t,n){throw new ze("Backend has to implement `eventFromMessage` method")},e.prototype.sendEvent=function(e){if(this._newTransport&&this._options.dsn&&this._options._experiments&&this._options._experiments.newTransport){var t=function(e,t){var n=rt(t),r=e.type||"event",i=(e.sdkProcessingMetadata||{}).transactionSampling||{},o=i.method,a=i.rate;return it(e,t.metadata.sdk),e.tags=e.tags||{},e.extra=e.extra||{},e.sdkProcessingMetadata&&e.sdkProcessingMetadata.baseClientNormalized||(e.tags.skippedNormalization=!0,e.extra.normalizeDepth=e.sdkProcessingMetadata?e.sdkProcessingMetadata.normalizeDepth:"unset"),delete e.sdkProcessingMetadata,tt(Object(_.a)(Object(_.a)({event_id:e.event_id,sent_at:(new Date).toISOString()},n&&{sdk:n}),!!t.tunnel&&{dsn:Ue(t.dsn)}),[[{type:r,sample_rates:[{id:o,rate:a}]},e]])}(e,Ye(this._options.dsn,this._options._metadata,this._options.tunnel));this._newTransport.send(t).then(null,(function(e){de&&D.error("Error while sending event:",e)}))}else this._transport.sendEvent(e).then(null,(function(e){de&&D.error("Error while sending event:",e)}))},e.prototype.sendSession=function(e){if(this._transport.sendSession)if(this._newTransport&&this._options.dsn&&this._options._experiments&&this._options._experiments.newTransport){var t=Ye(this._options.dsn,this._options._metadata,this._options.tunnel),n=Object(_.c)(ot(e,t),1)[0];this._newTransport.send(n).then(null,(function(e){de&&D.error("Error while sending session:",e)}))}else this._transport.sendSession(e).then(null,(function(e){de&&D.error("Error while sending session:",e)}));else de&&D.warn("Dropping session because custom transport doesn't implement sendSession")},e.prototype.getTransport=function(){return this._transport},e.prototype._setupTransport=function(){return new lt},e}();!function(e){e.Fatal="fatal",e.Error="error",e.Warning="warning",e.Log="log",e.Info="info",e.Debug="debug",e.Critical="critical"}(at||(at={}));var ct="?";function ut(e,t,n,r){var i={filename:e,function:t,in_app:!0};return void 0!==n&&(i.lineno=n),void 0!==r&&(i.colno=r),i}var pt=/^\s*at (?:(.*?) ?\((?:address at )?)?((?:file|https?|blob|chrome-extension|address|native|eval|webpack|<anonymous>|[-a-z]+:|.*bundle|\/).*?)(?::(\d+))?(?::(\d+))?\)?\s*$/i,dt=/\((\S*)(?::(\d+))(?::(\d+))\)/,ft=[30,function(e){var t=pt.exec(e);if(t){if(t[2]&&0===t[2].indexOf("eval")){var n=dt.exec(t[2]);n&&(t[2]=n[1],t[3]=n[2],t[4]=n[3])}var r=Object(_.c)(Ot(t[1]||ct,t[2]),2),i=r[0];return ut(r[1],i,t[3]?+t[3]:void 0,t[4]?+t[4]:void 0)}}],ht=/^\s*(.*?)(?:\((.*?)\))?(?:^|@)?((?:file|https?|blob|chrome|webpack|resource|moz-extension|capacitor).*?:\/.*?|\[native code\]|[^@]*(?:bundle|\d+\.js)|\/[\w\-. /=]+)(?::(\d+))?(?::(\d+))?\s*$/i,mt=/(\S+) line (\d+)(?: > eval line \d+)* > eval/i,gt=[50,function(e){var t,n=ht.exec(e);if(n){if(n[3]&&n[3].indexOf(" > eval")>-1){var r=mt.exec(n[3]);r&&(n[1]=n[1]||"eval",n[3]=r[1],n[4]=r[2],n[5]="")}var i=n[3],o=n[1]||ct;return o=(t=Object(_.c)(Ot(o,i),2))[0],ut(i=t[1],o,n[4]?+n[4]:void 0,n[5]?+n[5]:void 0)}}],bt=/^\s*at (?:((?:\[object object\])?.+) )?\(?((?:file|ms-appx|https?|webpack|blob):.*?):(\d+)(?::(\d+))?\)?\s*$/i,vt=[40,function(e){var t=bt.exec(e);return t?ut(t[2],t[1]||ct,+t[3],t[4]?+t[4]:void 0):void 0}],yt=/ line (\d+).*script (?:in )?(\S+)(?:: in function (\S+))?$/i,xt=[10,function(e){var t=yt.exec(e);return t?ut(t[2],t[3]||ct,+t[1]):void 0}],wt=/ line (\d+), column (\d+)\s*(?:in (?:<anonymous function: ([^>]+)>|([^)]+))\(.*\))? in (.*):\s*$/i,jt=[20,function(e){var t=wt.exec(e);return t?ut(t[5],t[3]||t[4]||ct,+t[1],+t[2]):void 0}],Ot=function(e,t){var n=-1!==e.indexOf("safari-extension"),r=-1!==e.indexOf("safari-web-extension");return n||r?[-1!==e.indexOf("@")?e.split("@")[0]:ct,n?"safari-extension:"+t:"safari-web-extension:"+t]:[e,t]};function kt(e){var t=St(e),n={type:e&&e.name,value:Et(e)};return t.length&&(n.stacktrace={frames:t}),void 0===n.type&&""===n.value&&(n.value="Unrecoverable error caught"),n}function _t(e){return{exception:{values:[kt(e)]}}}function St(e){var t=e.stacktrace||e.stack||"",n=function(e){if(e){if("number"===typeof e.framesToPop)return e.framesToPop;if(Pt.test(e.message))return 1}return 0}(e);try{return Object(be.a)(xt,jt,ft,vt,gt)(t,n)}catch(r){}return[]}var Pt=/Minified React error #\d+;/i;function Et(e){var t=e&&e.message;return t?t.error&&"string"===typeof t.error.message?t.error.message:t:"No error message"}function Ct(e,t,n,r){var i;if(Object(Q.e)(e)&&e.error)return _t(e.error);if(Object(Q.a)(e)||Object(Q.b)(e)){var o=e;if("stack"in e)i=_t(e);else{var a=o.name||(Object(Q.a)(o)?"DOMError":"DOMException"),l=o.message?a+": "+o.message:a;L(i=Nt(l,t,n),l)}return"code"in o&&(i.tags=Object(_.a)(Object(_.a)({},i.tags),{"DOMException.code":""+o.code})),i}return Object(Q.d)(e)?_t(e):Object(Q.i)(e)||Object(Q.f)(e)?(i=function(e,t,n){var r={exception:{values:[{type:Object(Q.f)(e)?e.constructor.name:n?"UnhandledRejection":"Error",value:"Non-Error "+(n?"promise rejection":"exception")+" captured with keys: "+Object(P.d)(e)}]},extra:{__serialized__:Object(He.b)(e)}};if(t){var i=St(t);i.length&&(r.stacktrace={frames:i})}return r}(e,t,r),M(i,{synthetic:!0}),i):(L(i=Nt(e,t,n),""+e,void 0),M(i,{synthetic:!0}),i)}function Nt(e,t,n){var r={message:e};if(n&&t){var i=St(t);i.length&&(r.stacktrace={frames:i})}return r}function Tt(e){var t=[];function n(e){return t.splice(t.indexOf(e),1)[0]}return{$:t,add:function(r){if(!(void 0===e||t.length<e))return Y(new ze("Not adding Promise due to buffer limit reached."));var i=r();return-1===t.indexOf(i)&&t.push(i),i.then((function(){return n(i)})).then(null,(function(){return n(i).then(null,(function(){}))})),i},drain:function(e){return new K((function(n,r){var i=t.length;if(!i)return n(!0);var o=setTimeout((function(){e&&e>0&&n(!1)}),e);t.forEach((function(e){V(e).then((function(){--i||(clearTimeout(o),n(!0))}),r)}))}))}}}function It(e,t){return e[t]||e.all||0}function Lt(e,t,n){return void 0===n&&(n=Date.now()),It(e,t)>n}function Mt(e,t,n){var r,i,o,a;void 0===n&&(n=Date.now());var l=Object(_.a)({},e),s=t["x-sentry-rate-limits"],c=t["retry-after"];if(s)try{for(var u=Object(_.e)(s.trim().split(",")),p=u.next();!p.done;p=u.next()){var d=p.value.split(":",2),f=parseInt(d[0],10),h=1e3*(isNaN(f)?60:f);if(d[1])try{for(var m=(o=void 0,Object(_.e)(d[1].split(";"))),g=m.next();!g.done;g=m.next()){l[g.value]=n+h}}catch(b){o={error:b}}finally{try{g&&!g.done&&(a=m.return)&&a.call(m)}finally{if(o)throw o.error}}else l.all=n+h}}catch(v){r={error:v}}finally{try{p&&!p.done&&(i=u.return)&&i.call(u)}finally{if(r)throw r.error}}else c&&(l.all=n+function(e,t){void 0===t&&(t=Date.now());var n=parseInt(""+e,10);if(!isNaN(n))return 1e3*n;var r=Date.parse(""+e);return isNaN(r)?6e4:r-t}(c,n));return l}function Ft(e){return e>=200&&e<300?"success":429===e?"rate_limit":e>=400&&e<500?"invalid":e>=500?"failed":"unknown"}function Dt(e,t,n){void 0===n&&(n=Tt(e.bufferSize||30));var r={};return{send:function(e){var i=function(e){var t=Object(_.c)(e,2),n=Object(_.c)(t[1],1);return Object(_.c)(n[0],1)[0].type}(e),o="event"===i?"error":i,a={category:o,body:nt(e)};return Lt(r,o)?Y({status:"rate_limit",reason:zt(r,o)}):n.add((function(){return t(a).then((function(e){var t=e.body,n=e.headers,i=e.reason,a=Ft(e.statusCode);return n&&(r=Mt(r,n)),"success"===a?V({status:a,reason:i}):Y({status:a,reason:i||t||("rate_limit"===a?zt(r,o):"Unknown transport error")})}))}))},flush:function(e){return n.drain(e)}}}function zt(e,t){return"Too many "+t+" requests, backing off until: "+new Date(It(e,t)).toISOString()}var Rt,Ut="undefined"===typeof __SENTRY_DEBUG__||__SENTRY_DEBUG__,At=Object(S.a)();function Bt(){if(Rt)return Rt;if(ye(At.fetch))return Rt=At.fetch.bind(At);var e=At.document,t=At.fetch;if(e&&"function"===typeof e.createElement)try{var n=e.createElement("iframe");n.hidden=!0,e.head.appendChild(n);var r=n.contentWindow;r&&r.fetch&&(t=r.fetch),e.head.removeChild(n)}catch(i){Ut&&D.warn("Could not create sandbox iframe for pure fetch check, bailing to window.fetch: ",i)}return Rt=t.bind(At)}function Ht(e,t){if("[object Navigator]"===Object.prototype.toString.call(At&&At.navigator)&&"function"===typeof At.navigator.sendBeacon)return At.navigator.sendBeacon.bind(At.navigator)(e,t);if(ve()){var n=Bt();n(e,{body:t,method:"POST",credentials:"omit",keepalive:!0}).then(null,(function(e){console.error(e)}))}else;}function qt(e){return"event"===e?"error":e}var $t=Object(S.a)(),Wt=function(){function e(e){var t=this;this.options=e,this._buffer=Tt(30),this._rateLimits={},this._outcomes={},this._api=Ye(e.dsn,e._metadata,e.tunnel),this.url=Ze(this._api.dsn),this.options.sendClientReports&&$t.document&&$t.document.addEventListener("visibilitychange",(function(){"hidden"===$t.document.visibilityState&&t._flushOutcomes()}))}return e.prototype.sendEvent=function(e){return this._sendRequest(function(e,t){var n,r=rt(t),i=e.type||"event",o="transaction"===i||!!t.tunnel,a=(e.sdkProcessingMetadata||{}).transactionSampling||{},l=a.method,s=a.rate;it(e,t.metadata.sdk),e.tags=e.tags||{},e.extra=e.extra||{},e.sdkProcessingMetadata&&e.sdkProcessingMetadata.baseClientNormalized||(e.tags.skippedNormalization=!0,e.extra.normalizeDepth=e.sdkProcessingMetadata?e.sdkProcessingMetadata.normalizeDepth:"unset"),delete e.sdkProcessingMetadata;try{n=JSON.stringify(e)}catch(d){e.tags.JSONStringifyError=!0,e.extra.JSONStringifyError=d;try{n=JSON.stringify(Object(He.a)(e))}catch(f){var c=f;n=JSON.stringify({message:"JSON.stringify error after renormalization",extra:{message:c.message,stack:c.stack}})}}var u={body:n,type:i,url:o?et(t.dsn,t.tunnel):Ze(t.dsn)};if(o){var p=tt(Object(_.a)(Object(_.a)({event_id:e.event_id,sent_at:(new Date).toISOString()},r&&{sdk:r}),!!t.tunnel&&{dsn:Ue(t.dsn)}),[[{type:i,sample_rates:[{id:l,rate:s}]},u.body]]);u.body=nt(p)}return u}(e,this._api),e)},e.prototype.sendSession=function(e){return this._sendRequest(function(e,t){var n=Object(_.c)(ot(e,t),2),r=n[0],i=n[1];return{body:nt(r),type:i,url:et(t.dsn,t.tunnel)}}(e,this._api),e)},e.prototype.close=function(e){return this._buffer.drain(e)},e.prototype.recordLostEvent=function(e,t){var n;if(this.options.sendClientReports){var r=qt(t)+":"+e;Ut&&D.log("Adding outcome: "+r),this._outcomes[r]=(null!==(n=this._outcomes[r])&&void 0!==n?n:0)+1}},e.prototype._flushOutcomes=function(){if(this.options.sendClientReports){var e=this._outcomes;if(this._outcomes={},Object.keys(e).length){Ut&&D.log("Flushing outcomes:\n"+JSON.stringify(e,null,2));var t,n,r,i=et(this._api.dsn,this._api.tunnel),o=Object.keys(e).map((function(t){var n=Object(_.c)(t.split(":"),2),r=n[0];return{reason:n[1],category:r,quantity:e[t]}})),a=(t=o,tt((n=this._api.tunnel&&Ue(this._api.dsn))?{dsn:n}:{},[[{type:"client_report"},{timestamp:r||Object(z.a)(),discarded_events:t}]]));try{Ht(i,nt(a))}catch(l){Ut&&D.error(l)}}else Ut&&D.log("No outcomes to flush")}},e.prototype._handleResponse=function(e){var t=e.requestType,n=e.response,r=e.headers,i=e.resolve,o=e.reject,a=Ft(n.status);this._rateLimits=Mt(this._rateLimits,r),this._isRateLimited(t)&&Ut&&D.warn("Too many "+t+" requests, backing off until: "+this._disabledUntil(t)),"success"!==a?o(n):i({status:a})},e.prototype._disabledUntil=function(e){var t=qt(e);return new Date(It(this._rateLimits,t))},e.prototype._isRateLimited=function(e){var t=qt(e);return Lt(this._rateLimits,t)},e}(),Qt=function(e){function t(t,n){void 0===n&&(n=Bt());var r=e.call(this,t)||this;return r._fetch=n,r}return Object(_.b)(t,e),t.prototype._sendRequest=function(e,t){var n=this;if(this._isRateLimited(e.type))return this.recordLostEvent("ratelimit_backoff",e.type),Promise.reject({event:t,type:e.type,reason:"Transport for "+e.type+" requests locked till "+this._disabledUntil(e.type)+" due to too many requests.",status:429});var r={body:e.body,method:"POST",referrerPolicy:xe()?"origin":""};return void 0!==this.options.fetchParameters&&Object.assign(r,this.options.fetchParameters),void 0!==this.options.headers&&(r.headers=this.options.headers),this._buffer.add((function(){return new K((function(t,i){n._fetch(e.url,r).then((function(r){var o={"x-sentry-rate-limits":r.headers.get("X-Sentry-Rate-Limits"),"retry-after":r.headers.get("Retry-After")};n._handleResponse({requestType:e.type,response:r,headers:o,resolve:t,reject:i})})).catch(i)}))})).then(void 0,(function(t){throw t instanceof ze?n.recordLostEvent("queue_overflow",e.type):n.recordLostEvent("network_error",e.type),t}))},t}(Wt);var Vt=function(e){function t(){return null!==e&&e.apply(this,arguments)||this}return Object(_.b)(t,e),t.prototype._sendRequest=function(e,t){var n=this;return this._isRateLimited(e.type)?(this.recordLostEvent("ratelimit_backoff",e.type),Promise.reject({event:t,type:e.type,reason:"Transport for "+e.type+" requests locked till "+this._disabledUntil(e.type)+" due to too many requests.",status:429})):this._buffer.add((function(){return new K((function(t,r){var i=new XMLHttpRequest;for(var o in i.onreadystatechange=function(){if(4===i.readyState){var o={"x-sentry-rate-limits":i.getResponseHeader("X-Sentry-Rate-Limits"),"retry-after":i.getResponseHeader("Retry-After")};n._handleResponse({requestType:e.type,response:i,headers:o,resolve:t,reject:r})}},i.open("POST",e.url),n.options.headers)Object.prototype.hasOwnProperty.call(n.options.headers,o)&&i.setRequestHeader(o,n.options.headers[o]);i.send(e.body)}))})).then(void 0,(function(t){throw t instanceof ze?n.recordLostEvent("queue_overflow",e.type):n.recordLostEvent("network_error",e.type),t}))},t}(Wt),Yt=function(e){function t(){return null!==e&&e.apply(this,arguments)||this}return Object(_.b)(t,e),t.prototype.eventFromException=function(e,t){return function(e,t,n){var r=Ct(e,t&&t.syntheticException||void 0,n);return M(r),r.level=at.Error,t&&t.event_id&&(r.event_id=t.event_id),V(r)}(e,t,this._options.attachStacktrace)},t.prototype.eventFromMessage=function(e,t,n){return void 0===t&&(t=at.Info),function(e,t,n,r){void 0===t&&(t=at.Info);var i=Nt(e,n&&n.syntheticException||void 0,r);return i.level=t,n&&n.event_id&&(i.event_id=n.event_id),V(i)}(e,t,n,this._options.attachStacktrace)},t.prototype._setupTransport=function(){if(!this._options.dsn)return e.prototype._setupTransport.call(this);var t,n,r=Object(_.a)(Object(_.a)({},this._options.transportOptions),{dsn:this._options.dsn,tunnel:this._options.tunnel,sendClientReports:this._options.sendClientReports,_metadata:this._options._metadata}),i=Ye(r.dsn,r._metadata,r.tunnel),o=et(i.dsn,i.tunnel);if(this._options.transport)return new this._options.transport(r);if(ve()){var a=Object(_.a)({},r.fetchParameters);return this._newTransport=(t={requestOptions:a,url:o},void 0===n&&(n=Bt()),Dt({bufferSize:t.bufferSize},(function(e){var r=Object(_.a)({body:e.body,method:"POST",referrerPolicy:"origin"},t.requestOptions);return n(t.url,r).then((function(e){return e.text().then((function(t){return{body:t,headers:{"x-sentry-rate-limits":e.headers.get("X-Sentry-Rate-Limits"),"retry-after":e.headers.get("Retry-After")},reason:e.statusText,statusCode:e.status}}))}))}))),new Qt(r)}return this._newTransport=function(e){return Dt({bufferSize:e.bufferSize},(function(t){return new K((function(n,r){var i=new XMLHttpRequest;for(var o in i.onreadystatechange=function(){if(4===i.readyState){var e={body:i.response,headers:{"x-sentry-rate-limits":i.getResponseHeader("X-Sentry-Rate-Limits"),"retry-after":i.getResponseHeader("Retry-After")},reason:i.statusText,statusCode:i.status};n(e)}},i.open("POST",e.url),e.headers)Object.prototype.hasOwnProperty.call(e.headers,o)&&i.setRequestHeader(o,e.headers[o]);i.send(t.body)}))}))}({url:o,headers:r.headers}),new Vt(r)},t}(st),Kt=Object(S.a)(),Gt=0;function Jt(){return Gt>0}function Xt(){Gt+=1,setTimeout((function(){Gt-=1}))}function Zt(e,t,n){if(void 0===t&&(t={}),"function"!==typeof e)return e;try{var r=e.__sentry_wrapped__;if(r)return r;if(Object(P.f)(e))return e}catch(a){return e}var i=function(){var r=Array.prototype.slice.call(arguments);try{n&&"function"===typeof n&&n.apply(this,arguments);var i=r.map((function(e){return Zt(e,t)}));return e.apply(this,i)}catch(o){throw Xt(),ue((function(e){e.addEventProcessor((function(e){return t.mechanism&&(L(e,void 0,void 0),M(e,t.mechanism)),e.extra=Object(_.a)(Object(_.a)({},e.extra),{arguments:r}),e})),ce(o)})),o}};try{for(var o in e)Object.prototype.hasOwnProperty.call(e,o)&&(i[o]=e[o])}catch(l){}Object(P.g)(i,e),Object(P.a)(e,"__sentry_wrapped__",i);try{Object.getOwnPropertyDescriptor(i,"name").configurable&&Object.defineProperty(i,"name",{get:function(){return e.name}})}catch(l){}return i}function en(e){if(void 0===e&&(e={}),Kt.document)if(e.eventId)if(e.dsn){var t=Kt.document.createElement("script");t.async=!0,t.src=function(e,t){var n=Be(e),r=Ke(n)+"embed/error-page/",i="dsn="+Ue(n);for(var o in t)if("dsn"!==o)if("user"===o){if(!t.user)continue;t.user.name&&(i+="&name="+encodeURIComponent(t.user.name)),t.user.email&&(i+="&email="+encodeURIComponent(t.user.email))}else i+="&"+encodeURIComponent(o)+"="+encodeURIComponent(t[o]);return r+"?"+i}(e.dsn,e),e.onLoad&&(t.onload=e.onLoad);var n=Kt.document.head||Kt.document.body;n&&n.appendChild(t)}else Ut&&D.error("Missing dsn option in showReportDialog call");else Ut&&D.error("Missing eventId option in showReportDialog call")}var tn=n(29),nn=["fatal","error","warning","log","info","debug","critical"];function rn(e){return"warn"===e?at.Warning:function(e){return-1!==nn.indexOf(e)}(e)?e:at.Log}var on=function(){function e(t){this.name=e.id,this._options=Object(_.a)({console:!0,dom:!0,fetch:!0,history:!0,sentry:!0,xhr:!0},t)}return e.prototype.addSentryBreadcrumb=function(e){this._options.sentry&&ie().addBreadcrumb({category:"sentry."+("transaction"===e.type?"transaction":"event"),event_id:e.event_id,level:e.level,message:I(e)},{event:e})},e.prototype.setupOnce=function(){this._options.console&&Se("console",an),this._options.dom&&Se("dom",function(e){function t(t){var n,r="object"===typeof e?e.serializeAttribute:void 0;"string"===typeof r&&(r=[r]);try{n=t.event.target?Object(tn.b)(t.event.target,r):Object(tn.b)(t.event,r)}catch(i){n="<unknown>"}0!==n.length&&ie().addBreadcrumb({category:"ui."+t.name,message:n},{event:t.event,name:t.name,global:t.global})}return t}(this._options.dom)),this._options.xhr&&Se("xhr",ln),this._options.fetch&&Se("fetch",sn),this._options.history&&Se("history",cn)},e.id="Breadcrumbs",e}();function an(e){var t={category:"console",data:{arguments:e.args,logger:"console"},level:rn(e.level),message:Object(E.b)(e.args," ")};if("assert"===e.level){if(!1!==e.args[0])return;t.message="Assertion failed: "+(Object(E.b)(e.args.slice(1)," ")||"console.assert"),t.data.arguments=e.args.slice(1)}ie().addBreadcrumb(t,{input:e.args,level:e.level})}function ln(e){if(e.endTimestamp){if(e.xhr.__sentry_own_request__)return;var t=e.xhr.__sentry_xhr__||{},n=t.method,r=t.url,i=t.status_code,o=t.body;ie().addBreadcrumb({category:"xhr",data:{method:n,url:r,status_code:i},type:"http"},{xhr:e.xhr,input:o})}else;}function sn(e){e.endTimestamp&&(e.fetchData.url.match(/sentry_key/)&&"POST"===e.fetchData.method||(e.error?ie().addBreadcrumb({category:"fetch",data:e.fetchData,level:at.Error,type:"http"},{data:e.error,input:e.args}):ie().addBreadcrumb({category:"fetch",data:Object(_.a)(Object(_.a)({},e.fetchData),{status_code:e.response.status}),type:"http"},{input:e.args,response:e.response})))}function cn(e){var t=Object(S.a)(),n=e.from,r=e.to,i=N(t.location.href),o=N(n),a=N(r);o.path||(o=i),i.protocol===a.protocol&&i.host===a.host&&(r=a.relative),i.protocol===o.protocol&&i.host===o.host&&(n=o.relative),ie().addBreadcrumb({category:"navigation",data:{from:n,to:r}})}var un=function(e){function t(t){void 0===t&&(t={});return t._metadata=t._metadata||{},t._metadata.sdk=t._metadata.sdk||{name:"sentry.javascript.browser",packages:[{name:"npm:@sentry/browser",version:Fe}],version:Fe},e.call(this,Yt,t)||this}return Object(_.b)(t,e),t.prototype.showReportDialog=function(e){void 0===e&&(e={}),Object(S.a)().document&&(this._isEnabled()?en(Object(_.a)(Object(_.a)({},e),{dsn:e.dsn||this.getDsn()})):Ut&&D.error("Trying to call showReportDialog with Sentry Client disabled"))},t.prototype._prepareEvent=function(t,n,r){return t.platform=t.platform||"javascript",e.prototype._prepareEvent.call(this,t,n,r)},t.prototype._sendEvent=function(t){var n=this.getIntegration(on);n&&n.addSentryBreadcrumb(t),e.prototype._sendEvent.call(this,t)},t}(Ve),pn=["EventTarget","Window","Node","ApplicationCache","AudioTrackList","ChannelMergerNode","CryptoOperation","EventSource","FileReader","HTMLUnknownElement","IDBDatabase","IDBRequest","IDBTransaction","KeyOperation","MediaController","MessagePort","ModalWindow","Notification","SVGElementInstance","Screen","TextTrack","TextTrackCue","TextTrackList","WebSocket","WebSocketWorker","Worker","XMLHttpRequest","XMLHttpRequestEventTarget","XMLHttpRequestUpload"],dn=function(){function e(t){this.name=e.id,this._options=Object(_.a)({XMLHttpRequest:!0,eventTarget:!0,requestAnimationFrame:!0,setInterval:!0,setTimeout:!0},t)}return e.prototype.setupOnce=function(){var e=Object(S.a)();this._options.setTimeout&&Object(P.e)(e,"setTimeout",fn),this._options.setInterval&&Object(P.e)(e,"setInterval",fn),this._options.requestAnimationFrame&&Object(P.e)(e,"requestAnimationFrame",hn),this._options.XMLHttpRequest&&"XMLHttpRequest"in e&&Object(P.e)(XMLHttpRequest.prototype,"send",mn);var t=this._options.eventTarget;t&&(Array.isArray(t)?t:pn).forEach(gn)},e.id="TryCatch",e}();function fn(e){return function(){for(var t=[],n=0;n<arguments.length;n++)t[n]=arguments[n];var r=t[0];return t[0]=Zt(r,{mechanism:{data:{function:Object(be.b)(e)},handled:!0,type:"instrument"}}),e.apply(this,t)}}function hn(e){return function(t){return e.apply(this,[Zt(t,{mechanism:{data:{function:"requestAnimationFrame",handler:Object(be.b)(e)},handled:!0,type:"instrument"}})])}}function mn(e){return function(){for(var t=[],n=0;n<arguments.length;n++)t[n]=arguments[n];var r=this,i=["onload","onerror","onprogress","onreadystatechange"];return i.forEach((function(e){e in r&&"function"===typeof r[e]&&Object(P.e)(r,e,(function(t){var n={mechanism:{data:{function:e,handler:Object(be.b)(t)},handled:!0,type:"instrument"}},r=Object(P.f)(t);return r&&(n.mechanism.data.handler=Object(be.b)(r)),Zt(t,n)}))})),e.apply(this,t)}}function gn(e){var t=Object(S.a)(),n=t[e]&&t[e].prototype;n&&n.hasOwnProperty&&n.hasOwnProperty("addEventListener")&&(Object(P.e)(n,"addEventListener",(function(t){return function(n,r,i){try{"function"===typeof r.handleEvent&&(r.handleEvent=Zt(r.handleEvent.bind(r),{mechanism:{data:{function:"handleEvent",handler:Object(be.b)(r),target:e},handled:!0,type:"instrument"}}))}catch(o){}return t.apply(this,[n,Zt(r,{mechanism:{data:{function:"addEventListener",handler:Object(be.b)(r),target:e},handled:!0,type:"instrument"}}),i])}})),Object(P.e)(n,"removeEventListener",(function(e){return function(t,n,r){var i=n;try{var o=i&&i.__sentry_wrapped__;o&&e.call(this,t,o,r)}catch(a){}return e.call(this,t,i,r)}})))}var bn=function(){function e(t){this.name=e.id,this._installFunc={onerror:vn,onunhandledrejection:yn},this._options=Object(_.a)({onerror:!0,onunhandledrejection:!0},t)}return e.prototype.setupOnce=function(){Error.stackTraceLimit=50;var e,t=this._options;for(var n in t){var r=this._installFunc[n];r&&t[n]&&(e=n,Ut&&D.log("Global Handler attached: "+e),r(),this._installFunc[n]=void 0)}},e.id="GlobalHandlers",e}();function vn(){Se("error",(function(e){var t=Object(_.c)(jn(),2),n=t[0],r=t[1];if(n.getIntegration(bn)){var i=e.msg,o=e.url,a=e.line,l=e.column,s=e.error;if(!(Jt()||s&&s.__sentry_own_request__)){var c=void 0===s&&Object(Q.l)(i)?function(e,t,n,r){var i=/^(?:[Uu]ncaught (?:exception: )?)?(?:((?:Eval|Internal|Range|Reference|Syntax|Type|URI|)Error): )?(.*)$/i,o=Object(Q.e)(e)?e.message:e,a="Error",l=o.match(i);l&&(a=l[1],o=l[2]);return xn({exception:{values:[{type:a,value:o}]}},t,n,r)}(i,o,a,l):xn(Ct(s||i,void 0,r,!1),o,a,l);c.level=at.Error,wn(n,s,c,"onerror")}}}))}function yn(){Se("unhandledrejection",(function(e){var t=Object(_.c)(jn(),2),n=t[0],r=t[1];if(n.getIntegration(bn)){var i=e;try{"reason"in e?i=e.reason:"detail"in e&&"reason"in e.detail&&(i=e.detail.reason)}catch(a){}if(Jt()||i&&i.__sentry_own_request__)return!0;var o=Object(Q.j)(i)?{exception:{values:[{type:"UnhandledRejection",value:"Non-Error promise rejection captured with value: "+String(i)}]}}:Ct(i,void 0,r,!0);o.level=at.Error,wn(n,i,o,"onunhandledrejection")}}))}function xn(e,t,n,r){var i=e.exception=e.exception||{},o=i.values=i.values||[],a=o[0]=o[0]||{},l=a.stacktrace=a.stacktrace||{},s=l.frames=l.frames||[],c=isNaN(parseInt(r,10))?void 0:r,u=isNaN(parseInt(n,10))?void 0:n,p=Object(Q.l)(t)&&t.length>0?t:Object(tn.a)();return 0===s.length&&s.push({colno:c,filename:p,function:"?",in_app:!0,lineno:u}),e}function wn(e,t,n,r){M(n,{handled:!1,type:r}),e.captureEvent(n,{originalException:t})}function jn(){var e=ie(),t=e.getClient();return[e,t&&t.getOptions().attachStacktrace]}var On=function(){function e(t){void 0===t&&(t={}),this.name=e.id,this._key=t.key||"cause",this._limit=t.limit||5}return e.prototype.setupOnce=function(){X((function(t,n){var r=ie().getIntegration(e);return r?function(e,t,n,r){if(!n.exception||!n.exception.values||!r||!Object(Q.g)(r.originalException,Error))return n;var i=kn(t,r.originalException,e);return n.exception.values=Object(_.d)(i,n.exception.values),n}(r._key,r._limit,t,n):t}))},e.id="LinkedErrors",e}();function kn(e,t,n,r){if(void 0===r&&(r=[]),!Object(Q.g)(t[n],Error)||r.length+1>=e)return r;var i=kt(t[n]);return kn(e,t[n],n,Object(_.d)([i],r))}var _n=function(){function e(){this.name=e.id}return e.prototype.setupOnce=function(t,n){t((function(t){var r=n().getIntegration(e);if(r){try{if(function(e,t){if(!t)return!1;if(function(e,t){var n=e.message,r=t.message;if(!n&&!r)return!1;if(n&&!r||!n&&r)return!1;if(n!==r)return!1;if(!Pn(e,t))return!1;if(!Sn(e,t))return!1;return!0}(e,t))return!0;if(function(e,t){var n=En(t),r=En(e);if(!n||!r)return!1;if(n.type!==r.type||n.value!==r.value)return!1;if(!Pn(e,t))return!1;if(!Sn(e,t))return!1;return!0}(e,t))return!0;return!1}(t,r._previousEvent))return Ut&&D.warn("Event dropped due to being a duplicate of previously captured event."),null}catch(i){return r._previousEvent=t}return r._previousEvent=t}return t}))},e.id="Dedupe",e}();function Sn(e,t){var n=Cn(e),r=Cn(t);if(!n&&!r)return!0;if(n&&!r||!n&&r)return!1;if(r.length!==n.length)return!1;for(var i=0;i<r.length;i++){var o=r[i],a=n[i];if(o.filename!==a.filename||o.lineno!==a.lineno||o.colno!==a.colno||o.function!==a.function)return!1}return!0}function Pn(e,t){var n=e.fingerprint,r=t.fingerprint;if(!n&&!r)return!0;if(n&&!r||!n&&r)return!1;try{return!(n.join("")!==r.join(""))}catch(i){return!1}}function En(e){return e.exception&&e.exception.values&&e.exception.values[0]}function Cn(e){var t=e.exception;if(t)try{return t.values[0].stacktrace.frames}catch(n){return}else if(e.stacktrace)return e.stacktrace.frames}var Nn=Object(S.a)(),Tn=function(){function e(){this.name=e.id}return e.prototype.setupOnce=function(){X((function(t){if(ie().getIntegration(e)){if(!Nn.navigator&&!Nn.location&&!Nn.document)return t;var n=t.request&&t.request.url||Nn.location&&Nn.location.href,r=(Nn.document||{}).referrer,i=(Nn.navigator||{}).userAgent,o=Object(_.a)(Object(_.a)(Object(_.a)({},t.request&&t.request.headers),r&&{Referer:r}),i&&{"User-Agent":i}),a=Object(_.a)(Object(_.a)({},n&&{url:n}),{headers:o});return Object(_.a)(Object(_.a)({},t),{request:a})}return t}))},e.id="UserAgent",e}(),In=[new r.InboundFilters,new r.FunctionToString,new dn,new on,new bn,new On,new _n,new Tn];function Ln(e){if(void 0===e&&(e={}),void 0===e.defaultIntegrations&&(e.defaultIntegrations=In),void 0===e.release){var t=Object(S.a)();t.SENTRY_RELEASE&&t.SENTRY_RELEASE.id&&(e.release=t.SENTRY_RELEASE.id)}void 0===e.autoSessionTracking&&(e.autoSessionTracking=!0),void 0===e.sendClientReports&&(e.sendClientReports=!0),function(e,t){!0===t.debug&&(de?D.enable():console.warn("[Sentry] Cannot initialize SDK with `debug` option using a non-debug bundle."));var n=ie(),r=n.getScope();r&&r.update(t.initialScope);var i=new e(t);n.bindClient(i)}(un,e),e.autoSessionTracking&&function(){if("undefined"===typeof Object(S.a)().document)return void(Ut&&D.warn("Session tracking in non-browser environment with @sentry/browser is not supported."));var e=ie();if(!e.captureSession)return;Mn(e),Se("history",(function(e){var t=e.from,n=e.to;void 0!==t&&t!==n&&Mn(ie())}))}()}function Mn(e){e.startSession({ignoreDuration:!0}),e.captureSession()}n(26);var Fn="undefined"===typeof __SENTRY_DEBUG__||__SENTRY_DEBUG__;var Dn={componentStack:null,error:null,eventId:null},zn=function(e){function t(){var t=null!==e&&e.apply(this,arguments)||this;return t.state=Dn,t.resetErrorBoundary=function(){var e=t.props.onReset,n=t.state,r=n.error,i=n.componentStack,o=n.eventId;e&&e(r,i,o),t.setState(Dn)},t}return Object(_.b)(t,e),t.prototype.componentDidCatch=function(e,t){var n=this,r=t.componentStack,o=this.props,a=o.beforeCapture,l=o.onError,s=o.showDialog,c=o.dialogOptions;ue((function(t){if(function(e){var t=e.match(/^([^.]+)/);return null!==t&&parseInt(t[0])>=17}(i.version)){var o=new Error(e.message);o.name="React ErrorBoundary "+o.name,o.stack=r,e.cause=o}a&&a(t,e,r);var u=ce(e,{contexts:{react:{componentStack:r}}});l&&l(e,r,u),s&&function(e){void 0===e&&(e={});var t=ie(),n=t.getScope();n&&(e.user=Object(_.a)(Object(_.a)({},n.getUser()),e.user)),e.eventId||(e.eventId=t.lastEventId());var r=t.getClient();r&&r.showReportDialog(e)}(Object(_.a)(Object(_.a)({},c),{eventId:u})),n.setState({error:e,componentStack:r,eventId:u})}))},t.prototype.componentDidMount=function(){var e=this.props.onMount;e&&e()},t.prototype.componentWillUnmount=function(){var e=this.state,t=e.error,n=e.componentStack,r=e.eventId,i=this.props.onUnmount;i&&i(t,n,r)},t.prototype.render=function(){var e=this.props,t=e.fallback,n=e.children,r=this.state,o=r.error,a=r.componentStack,l=r.eventId;if(o){var s=void 0;return s="function"===typeof t?t({error:o,componentStack:a,resetError:this.resetErrorBoundary,eventId:l}):t,i.isValidElement(s)?s:(t&&Fn&&D.warn("fallback did not produce a valid ReactElement"),null)}return"function"===typeof n?n():n},t}(i.Component);var Rn,Un,An,Bn,Hn=n(0),qn=["children","head","title","style"],$n=function(e){x(n,e);var t=O(n);function n(){var e;g(this,n);for(var r=arguments.length,i=new Array(r),o=0;o<r;o++)i[o]=arguments[o];return(e=t.call.apply(t,[this].concat(i))).handleLoad=function(){e.setupFrameBaseStyle()},e}return v(n,[{key:"componentDidMount",value:function(){this.node.addEventListener("load",this.handleLoad)}},{key:"componentWillUnmout",value:function(){this.node.removeEventListener("load",this.handleLoad)}},{key:"setupFrameBaseStyle",value:function(){this.node.contentDocument&&(this.iframeHtml=this.node.contentDocument.documentElement,this.iframeHead=this.node.contentDocument.head,this.iframeRoot=this.node.contentDocument.body,this.forceUpdate())}},{key:"render",value:function(){var e=this,t=this.props,n=t.children,r=t.head,i=t.title,o=void 0===i?"":i,l=t.style,s=void 0===l?{}:l,c=p(t,qn);return Object(Hn.jsxs)("iframe",Object(k.a)(Object(k.a)({srcDoc:"<!DOCTYPE html>"},c),{},{ref:function(t){return e.node=t},title:o,style:s,frameBorder:"0",children:[this.iframeHead&&Object(a.createPortal)(r,this.iframeHead),this.iframeRoot&&Object(a.createPortal)(n,this.iframeRoot)]}))}}]),n}(i.Component),Wn=["title","titleId"];function Qn(){return Qn=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(e[r]=n[r])}return e},Qn.apply(this,arguments)}function Vn(e,t){if(null==e)return{};var n,r,i=function(e,t){if(null==e)return{};var n,r,i={},o=Object.keys(e);for(r=0;r<o.length;r++)n=o[r],t.indexOf(n)>=0||(i[n]=e[n]);return i}(e,t);if(Object.getOwnPropertySymbols){var o=Object.getOwnPropertySymbols(e);for(r=0;r<o.length;r++)n=o[r],t.indexOf(n)>=0||Object.prototype.propertyIsEnumerable.call(e,n)&&(i[n]=e[n])}return i}function Yn(e,t){var n=e.title,r=e.titleId,o=Vn(e,Wn);return i.createElement("svg",Qn({id:"Regular",xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24",ref:t,"aria-labelledby":r},o),n?i.createElement("title",{id:r},n):null,Rn||(Rn=i.createElement("defs",null,i.createElement("style",null,".cls-1{fill:none;stroke:currentColor;stroke-linecap:round;stroke-linejoin:round;stroke-width:0.8px;}"))),Un||(Un=i.createElement("circle",{className:"cls-1",cx:12,cy:9.75,r:5.25})),An||(An=i.createElement("path",{className:"cls-1",d:"M18.913,20.876a9.746,9.746,0,0,0-13.826,0"})),Bn||(Bn=i.createElement("circle",{className:"cls-1",cx:12,cy:12,r:11.25})))}var Kn=i.forwardRef(Yn),Gn=(n.p,"\n .gh-portal-avatar {\n position: relative;\n display: flex;\n align-items: center;\n justify-content: center;\n overflow: hidden;\n margin: 0 0 8px 0;\n border-radius: 999px;\n }\n\n .gh-portal-avatar img {\n position: absolute;\n display: block;\n top: -2px;\n right: -2px;\n bottom: -2px;\n left: -2px;\n width: calc(100% + 4px);\n height: calc(100% + 4px);\n opacity: 1;\n max-width: unset;\n }\n");var Jn,Xn=function(e){var t=e.gravatar,n=function(e){var t=e.style,n=void 0===t?{}:t;return{avatarContainer:Object(k.a)({},n.avatarContainer||{}),gravatar:Object(k.a)({},n.avatarContainer||{}),userIcon:Object(k.a)({width:"34px",height:"34px",color:"#fff"},n.userIcon||{})}}({style:e.style});return Object(Hn.jsxs)("figure",{className:"gh-portal-avatar",style:n.avatarContainer,children:[Object(Hn.jsx)(Kn,{style:n.userIcon}),t?Object(Hn.jsx)("img",{style:n.gravatar,src:t,alt:""}):null]})},Zn=n(1).createContext({site:{},member:{},action:"",lastPage:"",brandColor:"",pageData:{},onAction:function(e,t){return{action:e,data:t}}}),er=["title","titleId"];function tr(){return tr=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(e[r]=n[r])}return e},tr.apply(this,arguments)}function nr(e,t){if(null==e)return{};var n,r,i=function(e,t){if(null==e)return{};var n,r,i={},o=Object.keys(e);for(r=0;r<o.length;r++)n=o[r],t.indexOf(n)>=0||(i[n]=e[n]);return i}(e,t);if(Object.getOwnPropertySymbols){var o=Object.getOwnPropertySymbols(e);for(r=0;r<o.length;r++)n=o[r],t.indexOf(n)>=0||Object.prototype.propertyIsEnumerable.call(e,n)&&(i[n]=e[n])}return i}function rr(e,t){var n=e.title,r=e.titleId,o=nr(e,er);return i.createElement("svg",tr({width:21,height:24,viewBox:"0 0 21 24",fill:"none",xmlns:"http://www.w3.org/2000/svg",ref:t,"aria-labelledby":r},o),n?i.createElement("title",{id:r},n):null,Jn||(Jn=i.createElement("path",{d:"M10.533 11.267c2.835 0 5.134-2.299 5.134-5.134C15.667 3.298 13.368 1 10.533 1 7.698 1 5.4 3.298 5.4 6.133s2.298 5.134 5.133 5.134zM1 23c0-2.529 1.004-4.953 2.792-6.741 1.788-1.788 4.213-2.792 6.741-2.792 2.529 0 4.954 1.004 6.741 2.792 1.788 1.788 2.793 4.212 2.793 6.74",stroke:"#fff",strokeWidth:1.5,strokeLinecap:"round",strokeLinejoin:"round"})))}var ir,or=i.forwardRef(rr),ar=(n.p,["title","titleId"]);function lr(){return lr=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(e[r]=n[r])}return e},lr.apply(this,arguments)}function sr(e,t){if(null==e)return{};var n,r,i=function(e,t){if(null==e)return{};var n,r,i={},o=Object.keys(e);for(r=0;r<o.length;r++)n=o[r],t.indexOf(n)>=0||(i[n]=e[n]);return i}(e,t);if(Object.getOwnPropertySymbols){var o=Object.getOwnPropertySymbols(e);for(r=0;r<o.length;r++)n=o[r],t.indexOf(n)>=0||Object.prototype.propertyIsEnumerable.call(e,n)&&(i[n]=e[n])}return i}function cr(e,t){var n=e.title,r=e.titleId,o=sr(e,ar);return i.createElement("svg",lr({width:24,height:24,viewBox:"0 0 24 24",xmlns:"http://www.w3.org/2000/svg",ref:t,"aria-labelledby":r},o),n?i.createElement("title",{id:r},n):null,ir||(ir=i.createElement("g",{fill:"none",fillRule:"evenodd"},i.createElement("path",{stroke:"#FFF",strokeWidth:1.5,strokeLinecap:"round",d:"M12.5 2v20M2 12.5h20"}))))}var ur,pr,dr=i.forwardRef(cr),fr=(n.p,["title","titleId"]);function hr(){return hr=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(e[r]=n[r])}return e},hr.apply(this,arguments)}function mr(e,t){if(null==e)return{};var n,r,i=function(e,t){if(null==e)return{};var n,r,i={},o=Object.keys(e);for(r=0;r<o.length;r++)n=o[r],t.indexOf(n)>=0||(i[n]=e[n]);return i}(e,t);if(Object.getOwnPropertySymbols){var o=Object.getOwnPropertySymbols(e);for(r=0;r<o.length;r++)n=o[r],t.indexOf(n)>=0||Object.prototype.propertyIsEnumerable.call(e,n)&&(i[n]=e[n])}return i}function gr(e,t){var n=e.title,r=e.titleId,o=mr(e,fr);return i.createElement("svg",hr({width:25,height:24,viewBox:"0 0 25 24",fill:"none",xmlns:"http://www.w3.org/2000/svg",ref:t,"aria-labelledby":r},o),n?i.createElement("title",{id:r},n):null,ur||(ur=i.createElement("path",{d:"M23.5 6v14.25c0 .597-.237 1.169-.659 1.591-.422.422-.994.659-1.591.659s-1.169-.237-1.591-.659c-.422-.422-.659-.994-.659-1.591V3c0-.398-.158-.78-.44-1.06-.28-.282-.662-.44-1.06-.44h-15c-.398 0-.78.158-1.06.44C1.157 2.22 1 2.601 1 3v17.25c0 .597.237 1.169.659 1.591.422.422.994.659 1.591.659h18M4.75 15h10.5M4.75 18h6",stroke:"#fff",strokeWidth:1.5,strokeLinecap:"round",strokeLinejoin:"round"})),pr||(pr=i.createElement("path",{d:"M14.5 5.25h-9c-.414 0-.75.336-.75.75v4.5c0 .414.336.75.75.75h9c.414 0 .75-.336.75-.75V6c0-.414-.336-.75-.75-.75z",stroke:"#fff",strokeWidth:1.5,strokeLinecap:"round",strokeLinejoin:"round"})))}var br,vr,yr=i.forwardRef(gr),xr=(n.p,["title","titleId"]);function wr(){return wr=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(e[r]=n[r])}return e},wr.apply(this,arguments)}function jr(e,t){if(null==e)return{};var n,r,i=function(e,t){if(null==e)return{};var n,r,i={},o=Object.keys(e);for(r=0;r<o.length;r++)n=o[r],t.indexOf(n)>=0||(i[n]=e[n]);return i}(e,t);if(Object.getOwnPropertySymbols){var o=Object.getOwnPropertySymbols(e);for(r=0;r<o.length;r++)n=o[r],t.indexOf(n)>=0||Object.prototype.propertyIsEnumerable.call(e,n)&&(i[n]=e[n])}return i}function Or(e,t){var n=e.title,r=e.titleId,o=jr(e,xr);return i.createElement("svg",wr({width:24,height:18,viewBox:"0 0 24 18",fill:"none",xmlns:"http://www.w3.org/2000/svg",ref:t,"aria-labelledby":r},o),n?i.createElement("title",{id:r},n):null,br||(br=i.createElement("path",{d:"M21.75 1.5H2.25c-.828 0-1.5.672-1.5 1.5v12c0 .828.672 1.5 1.5 1.5h19.5c.828 0 1.5-.672 1.5-1.5V3c0-.828-.672-1.5-1.5-1.5zM15.687 6.975L19.5 10.5M8.313 6.975L4.5 10.5",stroke:"#fff",strokeWidth:1.5,strokeLinecap:"round",strokeLinejoin:"round"})),vr||(vr=i.createElement("path",{d:"M22.88 2.014l-9.513 6.56C12.965 8.851 12.488 9 12 9s-.965-.149-1.367-.426L1.12 2.014",stroke:"#fff",strokeWidth:1.5,strokeLinecap:"round",strokeLinejoin:"round"})))}var kr,_r,Sr=i.forwardRef(Or),Pr=(n.p,["title","titleId"]);function Er(){return Er=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(e[r]=n[r])}return e},Er.apply(this,arguments)}function Cr(e,t){if(null==e)return{};var n,r,i=function(e,t){if(null==e)return{};var n,r,i={},o=Object.keys(e);for(r=0;r<o.length;r++)n=o[r],t.indexOf(n)>=0||(i[n]=e[n]);return i}(e,t);if(Object.getOwnPropertySymbols){var o=Object.getOwnPropertySymbols(e);for(r=0;r<o.length;r++)n=o[r],t.indexOf(n)>=0||Object.prototype.propertyIsEnumerable.call(e,n)&&(i[n]=e[n])}return i}function Nr(e,t){var n=e.title,r=e.titleId,o=Cr(e,Pr);return i.createElement("svg",Er({width:26,height:26,viewBox:"0 0 26 26",fill:"none",xmlns:"http://www.w3.org/2000/svg",ref:t,"aria-labelledby":r},o),n?i.createElement("title",{id:r},n):null,kr||(kr=i.createElement("path",{d:"M17.903 12.016c-.332-1.665-1.491-3.032-3.031-3.654M11.037 8.4C9.252 9.163 8 10.935 8 13c0 .432.055.85.158 1.25M10.44 17.296c.748.447 1.624.704 2.56.704 1.71 0 3.22-.858 4.12-2.167M15.171 21.22c3.643-.96 6.329-4.276 6.329-8.22 0-1.084-.203-2.121-.573-3.075M18.611 6.615C17.114 5.3 15.151 4.5 13 4.5c-2.149 0-4.112.797-5.608 2.113M5.112 9.826c-.395.98-.612 2.052-.612 3.174 0 4.015 2.783 7.38 6.526 8.27",stroke:"#fff",strokeWidth:1.5,strokeLinecap:"round"})),_r||(_r=i.createElement("path",{d:"M8.924 24.29c1.273.46 2.645.71 4.076.71 5.52 0 10.17-3.727 11.57-8.803M6.712 2.777C3.285 4.89 1 8.678 1 13c0 3.545 1.537 6.731 3.982 8.928M24.849 11.089C23.933 5.369 18.977 1 13 1c-.69 0-1.367.058-2.025.17",stroke:"#fff",strokeWidth:1.5,strokeLinecap:"round"})))}var Tr=i.forwardRef(Nr),Ir=(n.p,'\n /* Colors\n /* ----------------------------------------------------- */\n :root {\n --black: #000;\n --grey0: #1d1d1d;\n --grey1: #333;\n --grey2: #3d3d3d;\n --grey3: #474747;\n --grey4: #515151;\n --grey5: #686868;\n --grey6: #7f7f7f;\n --grey7: #979797;\n --grey8: #aeaeae;\n --grey9: #c5c5c5;\n --grey10: #dcdcdc;\n --grey11: #e1e1e1;\n --grey12: #eaeaea;\n --grey13: #f9f9f9;\n --grey14: #fbfbfb;\n --white: #fff;\n --red: #f02525;\n --yellow: #FFDC15;\n --green: #7FC724;\n }\n\n /* Globals\n /* ----------------------------------------------------- */\n html {\n font-size: 62.5%;\n height: 100%;\n }\n\n body {\n margin: 0px;\n font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Oxygen, Ubuntu, Cantarell, "Open Sans", "Helvetica Neue", sans-serif;\n font-size: 1.6rem;\n height: 100%;\n line-height: 1.6em;\n font-weight: 400;\n font-style: normal;\n color: var(--grey2);\n box-sizing: border-box;\n overflow: hidden;\n }\n\n button,\n button span {\n font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Oxygen, Ubuntu, Cantarell, "Open Sans", "Helvetica Neue", sans-serif;\n }\n\n *, ::after, ::before {\n box-sizing: border-box;\n }\n\n h1, h2, h3, h4, h5, h6, p {\n line-height: 1.15em;\n padding: 0;\n margin: 0;\n }\n\n h1 {\n font-size: 35px;\n font-weight: 700;\n letter-spacing: -0.022em;\n }\n\n h2 {\n font-size: 32px;\n font-weight: 700;\n letter-spacing: -0.021em;\n }\n\n h3 {\n font-size: 24px;\n font-weight: 700;\n letter-spacing: -0.019em;\n }\n\n p {\n font-size: 15px;\n line-height: 1.5em;\n margin-bottom: 24px;\n }\n\n strong {\n font-weight: 600;\n }\n\n a,\n .gh-portal-link {\n cursor: pointer;\n }\n\n svg {\n box-sizing: content-box;\n }\n\n input,\n textarea {\n font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Oxygen, Ubuntu, Cantarell, "Open Sans", "Helvetica Neue", sans-serif;\n font-size: 1.5rem;\n }\n\n textarea {\n padding: 10px;\n line-height: 1.5em;\n }\n\n @media (max-width: 1440px) {\n h1 {\n font-size: 32px;\n letter-spacing: -0.022em;\n }\n\n h2 {\n font-size: 28px;\n letter-spacing: -0.021em;\n }\n\n h3 {\n font-size: 26px;\n letter-spacing: -0.02em;\n }\n }\n\n @media (max-width: 480px) {\n h1 {\n font-size: 30px;\n letter-spacing: -0.021em;\n }\n\n h2 {\n font-size: 26px;\n letter-spacing: -0.02em;\n }\n\n h3 {\n font-size: 24px;\n letter-spacing: -0.019em;\n }\n }\n'),Lr=n(3),Mr=function(){var e=window.location.hash.substr(1).split("?");return"/portal/preview"===Object(s.a)(e,1)[0]},Fr=function(){var e=window.location.hash.substr(1).split("?");return"/portal/preview/offer"===Object(s.a)(e,1)[0]},Dr={preview:function(){return Mr()||Fr()},offerPreview:Fr,dev:function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{};e.customSiteUrl;return!1},test:function(){return!1}},zr=function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:[],t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{};return e.some((function(e){var n=Dr[e];return!(!n||!n(t))}))},Rr=n(1),Ur={"icon-1":or,"icon-2":dr,"icon-3":yr,"icon-4":Sr,"icon-5":Tr},Ar=function(e){e.brandColor;var t=e.hasText,n=Object(k.a)(Object(k.a)({},t?{}:{width:"105px"}),zr(["preview"])?{opacity:1}:{});return{frame:Object(k.a)({zIndex:"3999998",position:"fixed",bottom:"0",right:"0",width:"500px",maxWidth:"500px",height:"98px",animation:"250ms ease 0s 1 normal none running animation-bhegco",transition:"opacity 0.3s ease 0s",overflow:"hidden"},n),userIcon:{width:"34px",height:"34px",color:"#fff"},buttonIcon:{width:"24px",height:"24px",color:"#fff"},closeIcon:{width:"20px",height:"20px",color:"#fff"}}},Br=function(e){x(n,e);var t=O(n);function n(e){var r;return g(this,n),(r=t.call(this,e)).state={},r.container=Rr.createRef(),r.height=null,r.width=null,r}return v(n,[{key:"updateHeight",value:function(e){this.props.updateHeight&&this.props.updateHeight(e)}},{key:"updateWidth",value:function(e){this.props.updateWidth&&this.props.updateWidth(e)}},{key:"componentDidMount",value:function(){this.container&&(this.height=this.container.current&&this.container.current.offsetHeight,this.width=this.container.current&&this.container.current.offsetWidth,this.updateHeight(this.height),this.updateWidth(this.width))}},{key:"componentDidUpdate",value:function(){if(this.container){var e=this.container.current&&this.container.current.offsetHeight,t=this.container.current&&this.container.current.offsetWidth;e!==this.height&&(this.height=e,this.updateHeight(this.height)),t!==this.width&&(this.width=t,this.updateWidth(this.width))}}},{key:"renderTriggerIcon",value:function(){var e=this.context.site||{},t=e.portal_button_icon,n=void 0===t?"":t,r=e.portal_button_style,i=void 0===r?"":r,o=Ar({brandColor:this.context.brandColor}),a=this.context.member&&this.context.member.avatar_image;if(!i.includes("icon")&&!this.context.member)return null;if(a)return Object(Hn.jsx)(Xn,{gravatar:a});if(this.context.member)return Object(Hn.jsx)(Kn,{style:o.userIcon});if(Object.keys(Ur).includes(n)){var l=Ur[n];return Object(Hn.jsx)(l,{style:o.buttonIcon})}return n?Object(Hn.jsx)("img",{style:{width:"26px",height:"26px"},src:n,alt:""}):(this.hasText()&&(o.userIcon.width="26px",o.userIcon.height="26px"),Object(Hn.jsx)(Kn,{style:o.userIcon}))}},{key:"hasText",value:function(){var e=this.context.site,t=e.portal_button_signup_text,n=e.portal_button_style;return["icon-and-text","text-only"].includes(n)&&!this.context.member&&t}},{key:"renderText",value:function(){var e=this.context.site.portal_button_signup_text;return this.hasText()?Object(Hn.jsxs)("span",{className:"gh-portal-triggerbtn-label",children:[" ",e," "]}):null}},{key:"onToggle",value:function(){var e=this.context,t=e.showPopup,n=e.member,r=e.site;if(t)this.context.onAction("closePopup");else{var i=Object(Lr.isInviteOnlySite)({site:r})?"signin":"signup",o=n?"accountHome":i;this.context.onAction("openPopup",{page:o})}}},{key:"render",value:function(){var e=this,t=this.hasText(),n=this.context.member?"halo":"";return t?Object(Hn.jsx)("div",{className:"gh-portal-triggerbtn-wrapper",ref:this.container,children:Object(Hn.jsxs)("div",{className:"gh-portal-triggerbtn-container with-label",onClick:function(t){return e.onToggle(t)},children:[this.renderTriggerIcon(),t?this.renderText():""]})}):Object(Hn.jsx)("div",{className:"gh-portal-triggerbtn-wrapper",children:Object(Hn.jsx)("div",{className:"gh-portal-triggerbtn-container "+n,onClick:function(t){return e.onToggle(t)},children:this.renderTriggerIcon()})})}}]),n}(Rr.Component);Br.contextType=Zn;var Hr=function(e){x(n,e);var t=O(n);function n(e){var r;return g(this,n),(r=t.call(this,e)).state={width:null},r}return v(n,[{key:"onWidthChange",value:function(e){this.setState({width:e})}},{key:"hasText",value:function(){var e=this.context.site,t=e.portal_button_signup_text,n=e.portal_button_style;return["icon-and-text","text-only"].includes(n)&&!this.context.member&&t}},{key:"renderFrameStyles",value:function(){var e="\n :root {\n --brandcolor: ".concat(this.context.brandColor,"\n }\n ")+'\n /* Colors\n /* ----------------------------------------------------- */\n :root {\n --black: #000;\n --grey0: #1d1d1d;\n --grey1: #333;\n --grey2: #3d3d3d;\n --grey3: #474747;\n --grey4: #515151;\n --grey5: #686868;\n --grey6: #7f7f7f;\n --grey7: #979797;\n --grey8: #aeaeae;\n --grey9: #c5c5c5;\n --grey10: #dcdcdc;\n --grey11: #e1e1e1;\n --grey12: #eaeaea;\n --grey13: #f9f9f9;\n --grey14: #fbfbfb;\n --white: #fff;\n --red: #f02525;\n --yellow: #FFDC15;\n --green: #7FC724;\n }\n\n /* Globals\n /* ----------------------------------------------------- */\n html {\n font-size: 62.5%;\n height: 100%;\n }\n\n body {\n margin: 0px;\n font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Oxygen, Ubuntu, Cantarell, "Open Sans", "Helvetica Neue", sans-serif;\n font-size: 1.6rem;\n height: 100%;\n line-height: 1.6em;\n font-weight: 400;\n font-style: normal;\n color: var(--grey2);\n box-sizing: border-box;\n overflow: hidden;\n }\n\n button,\n button span {\n font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Oxygen, Ubuntu, Cantarell, "Open Sans", "Helvetica Neue", sans-serif;\n }\n\n *, ::after, ::before {\n box-sizing: border-box;\n }\n\n h1, h2, h3, h4, h5, h6, p {\n line-height: 1.15em;\n padding: 0;\n margin: 0;\n }\n\n h1 {\n font-size: 35px;\n font-weight: 700;\n letter-spacing: -0.022em;\n }\n\n h2 {\n font-size: 32px;\n font-weight: 700;\n letter-spacing: -0.021em;\n }\n\n h3 {\n font-size: 24px;\n font-weight: 700;\n letter-spacing: -0.019em;\n }\n\n p {\n font-size: 15px;\n line-height: 1.5em;\n margin-bottom: 24px;\n }\n\n strong {\n font-weight: 600;\n }\n\n a,\n .gh-portal-link {\n cursor: pointer;\n }\n\n svg {\n box-sizing: content-box;\n }\n\n input,\n textarea {\n font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Oxygen, Ubuntu, Cantarell, "Open Sans", "Helvetica Neue", sans-serif;\n font-size: 1.5rem;\n }\n\n textarea {\n padding: 10px;\n line-height: 1.5em;\n }\n\n @media (max-width: 1440px) {\n h1 {\n font-size: 32px;\n letter-spacing: -0.022em;\n }\n\n h2 {\n font-size: 28px;\n letter-spacing: -0.021em;\n }\n\n h3 {\n font-size: 26px;\n letter-spacing: -0.02em;\n }\n }\n\n @media (max-width: 480px) {\n h1 {\n font-size: 30px;\n letter-spacing: -0.021em;\n }\n\n h2 {\n font-size: 26px;\n letter-spacing: -0.02em;\n }\n\n h3 {\n font-size: 24px;\n letter-spacing: -0.019em;\n }\n }\n\n .gh-portal-triggerbtn-wrapper {\n display: inline-flex;\n align-items: flex-start;\n justify-content: flex-end;\n height: 100%;\n opacity: 1;\n transition: transform 0.16s linear 0s; opacity 0.08s linear 0s;\n user-select: none;\n line-height: 1;\n padding: 10px 28px 0 17px;\n }\n \n .gh-portal-triggerbtn-wrapper span {\n margin-bottom: 1px;\n }\n \n .gh-portal-triggerbtn-container {\n position: relative;\n cursor: pointer;\n display: flex;\n align-items: center;\n justify-content: center;\n background: var(--brandcolor);\n height: 60px;\n min-width: 60px;\n box-shadow: rgba(0, 0, 0, 0.24) 0px 8px 16px -2px;\n border-radius: 999px;\n transition: opacity 0.3s ease;\n }\n\n .gh-portal-triggerbtn-container:before {\n position: absolute;\n content: "";\n top: 0;\n right: 0;\n bottom: 0;\n left: 0;\n border-radius: 999px;\n background: rgba(255, 255, 255, 0);\n transition: background 0.3s ease;\n }\n\n .gh-portal-triggerbtn-container:hover:before {\n background: rgba(255, 255, 255, 0.08);\n }\n\n .gh-portal-triggerbtn-container.halo:before {\n top: -4px;\n right: -4px;\n bottom: -4px;\n left: -4px;\n border: 4px solid rgba(255, 255, 255, 0.15);\n }\n\n .gh-portal-triggerbtn-container.with-label {\n padding: 0 12px 0 16px;\n }\n\n .gh-portal-triggerbtn-label {\n padding: 8px;\n color: rgb(255, 255, 255);\n display: block;\n white-space: nowrap;\n max-width: 380px;\n overflow: hidden;\n text-overflow: ellipsis;\n }\n\n .gh-portal-avatar {\n margin-bottom: 0px !important;\n width: 60px;\n height: 60px;\n }\n\n .gh-portal-avatar {\n position: relative;\n display: flex;\n align-items: center;\n justify-content: center;\n overflow: hidden;\n margin: 0 0 8px 0;\n border-radius: 999px;\n }\n\n .gh-portal-avatar img {\n position: absolute;\n display: block;\n top: -2px;\n right: -2px;\n bottom: -2px;\n left: -2px;\n width: calc(100% + 4px);\n height: calc(100% + 4px);\n opacity: 1;\n max-width: unset;\n }\n';return Object(Hn.jsx)("style",{dangerouslySetInnerHTML:{__html:e}})}},{key:"render",value:function(){var e=this,t=this.context.site.portal_button,n=this.context.showPopup;if(!t||zr(["offerPreview"]))return null;var r=this.hasText(),i=Ar({brandColor:this.context.brandColor,hasText:r}),o=Object(k.a)({},i.frame);if(this.state.width){var a=this.state.width+2;o.width="".concat(a,"px")}return Object(Hn.jsx)($n,{className:"gh-portal-triggerbtn-iframe",style:o,title:"portal-trigger",head:this.renderFrameStyles(),children:Object(Hn.jsx)(Br,{isPopupOpen:n,updateWidth:function(t){return e.onWidthChange(t)}})})}}]),n}(Rr.Component);Hr.contextType=Zn;var qr,$r,Wr=["title","titleId"];function Qr(){return Qr=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(e[r]=n[r])}return e},Qr.apply(this,arguments)}function Vr(e,t){if(null==e)return{};var n,r,i=function(e,t){if(null==e)return{};var n,r,i={},o=Object.keys(e);for(r=0;r<o.length;r++)n=o[r],t.indexOf(n)>=0||(i[n]=e[n]);return i}(e,t);if(Object.getOwnPropertySymbols){var o=Object.getOwnPropertySymbols(e);for(r=0;r<o.length;r++)n=o[r],t.indexOf(n)>=0||Object.prototype.propertyIsEnumerable.call(e,n)&&(i[n]=e[n])}return i}function Yr(e,t){var n=e.title,r=e.titleId,o=Vr(e,Wr);return i.createElement("svg",Qr({xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24",ref:t,"aria-labelledby":r},o),n?i.createElement("title",{id:r},n):null,qr||(qr=i.createElement("defs",null,i.createElement("style",null,".a{fill:none;stroke:currentColor;stroke-linecap:round;stroke-linejoin:round;stroke-width:1.2px !important;}"))),$r||($r=i.createElement("path",{className:"a",d:"M.75 23.249l22.5-22.5M23.25 23.249L.75.749"})))}var Kr,Gr,Jr=i.forwardRef(Yr),Xr=(n.p,["title","titleId"]);function Zr(){return Zr=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(e[r]=n[r])}return e},Zr.apply(this,arguments)}function ei(e,t){if(null==e)return{};var n,r,i=function(e,t){if(null==e)return{};var n,r,i={},o=Object.keys(e);for(r=0;r<o.length;r++)n=o[r],t.indexOf(n)>=0||(i[n]=e[n]);return i}(e,t);if(Object.getOwnPropertySymbols){var o=Object.getOwnPropertySymbols(e);for(r=0;r<o.length;r++)n=o[r],t.indexOf(n)>=0||Object.prototype.propertyIsEnumerable.call(e,n)&&(i[n]=e[n])}return i}function ti(e,t){var n=e.title,r=e.titleId,o=ei(e,Xr);return i.createElement("svg",Zr({xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24",ref:t,"aria-labelledby":r},o),n?i.createElement("title",{id:r},n):null,Kr||(Kr=i.createElement("defs",null,i.createElement("style",null,".checkmark-icon-fill{fill:currentColor;}"))),Gr||(Gr=i.createElement("path",{className:"checkmark-icon-fill",d:"M12,0A12,12,0,1,0,24,12,12.014,12.014,0,0,0,12,0Zm6.927,8.2-6.845,9.289a1.011,1.011,0,0,1-1.43.188L5.764,13.769a1,1,0,1,1,1.25-1.562l4.076,3.261,6.227-8.451A1,1,0,1,1,18.927,8.2Z"})))}var ni,ri,ii=i.forwardRef(ti),oi=(n.p,["title","titleId"]);function ai(){return ai=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(e[r]=n[r])}return e},ai.apply(this,arguments)}function li(e,t){if(null==e)return{};var n,r,i=function(e,t){if(null==e)return{};var n,r,i={},o=Object.keys(e);for(r=0;r<o.length;r++)n=o[r],t.indexOf(n)>=0||(i[n]=e[n]);return i}(e,t);if(Object.getOwnPropertySymbols){var o=Object.getOwnPropertySymbols(e);for(r=0;r<o.length;r++)n=o[r],t.indexOf(n)>=0||Object.prototype.propertyIsEnumerable.call(e,n)&&(i[n]=e[n])}return i}function si(e,t){var n=e.title,r=e.titleId,o=li(e,oi);return i.createElement("svg",ai({xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24",ref:t,"aria-labelledby":r},o),n?i.createElement("title",{id:r},n):null,ni||(ni=i.createElement("defs",null,i.createElement("style",null,".warning-icon-fill{fill:currentColor;}"))),ri||(ri=i.createElement("path",{className:"warning-icon-fill",d:"M23.25,23.235a.75.75,0,0,0,.661-1.105l-11.25-21a.782.782,0,0,0-1.322,0l-11.25,21A.75.75,0,0,0,.75,23.235ZM12,20.485a1.5,1.5,0,1,1,1.5-1.5A1.5,1.5,0,0,1,12,20.485Zm0-12.25a1,1,0,0,1,1,1V14.7a1,1,0,0,1-2,0V9.235A1,1,0,0,1,12,8.235Z"})))}var ci=i.forwardRef(si),ui=(n.p,function(e){e.qsParams;var t=e.action,n=e.status;if(n&&["true","false"].includes(n)){var r=JSON.parse(n);return{type:t,status:r?"success":"error",duration:3e3,autoHide:!!r}}return{}}),pi=function(e){var t=e.status,n=e.billingOnly;return!n&&["success"].includes(t)?{type:"stripe:checkout",status:["success"].includes(t)?"success":"warning",duration:3e3,autoHide:!0}:n&&["billing-update-success","billing-update-cancel"].includes(t)?{type:"stripe:billing-update",status:"billing-update-success"===t?"success":"warning",duration:3e3,autoHide:!0,closeable:!0}:void 0},di=function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:[],t=window.location.search||"",n=new URLSearchParams(t);e.forEach((function(e){n.delete(e)}));var r=n.toString()?"?".concat(n):"";window.history.replaceState({},"","".concat(window.location.pathname).concat(r))};function fi(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{},t=e.billingOnly,n=void 0!==t&&t,r=window.location.search;if(!r)return null;var i=new URLSearchParams(r),o=i.get("action"),a=i.get("success"),l=i.get("stripe"),s=null;return l?pi({qsParams:i,status:l,billingOnly:n}):o&&a&&!n?ui({qsParams:i,action:o,status:a}):s}var hi=n(1),mi=function(e){var t=e.type,n=e.status,r=e.context,i=Object(Lr.getPortalLink)({page:"signin",siteUrl:r.site.url}),o=Object(Lr.getPortalLink)({page:"signup",siteUrl:r.site.url});if("signin"===t&&"success"===n&&r.member){var a=r.member.firstname||"";return Object(Hn.jsxs)("p",{children:["Welcome back",a?", "+a:"","!",Object(Hn.jsx)("br",{}),"You've successfully signed in."]})}return"signin"===t&&"error"===n?Object(Hn.jsxs)("p",{children:["Could not sign in. Login link expired. ",Object(Hn.jsx)("a",{href:i,target:"_parent",children:"Click here to retry"})]}):"signup"===t&&"success"===n||"signup-paid"===t&&"success"===n?Object(Hn.jsxs)("p",{children:["You've successfully subscribed to ",Object(Hn.jsx)("br",{}),Object(Hn.jsx)("strong",{children:r.site.title})]}):"updateEmail"===t&&"success"===n?Object(Hn.jsx)("p",{children:"Success! Your email is updated."}):"updateEmail"===t&&"error"===n?Object(Hn.jsx)("p",{children:"Could not update email! Invalid link."}):"signup"===t&&"error"===n||"signup-paid"===t&&"error"===n?Object(Hn.jsxs)("p",{children:["Signup error: Invalid link ",Object(Hn.jsx)("br",{}),Object(Hn.jsx)("a",{href:o,target:"_parent",children:"Click here to retry"})]}):"stripe:checkout"===t&&"success"===n?r.member?Object(Hn.jsx)("p",{children:"Success! Your account is fully activated, you now have access to all content."}):Object(Hn.jsx)("p",{children:"Success! Check your email for magic link to sign-in."}):"stripe:checkout"===t&&"warning"===n?r.member?Object(Hn.jsx)("p",{children:"Plan upgrade was cancelled."}):Object(Hn.jsx)("p",{children:"Plan checkout was cancelled."}):Object(Hn.jsx)("p",{children:"success"===n?"Success":"Error"})},gi=function(e){x(n,e);var t=O(n);function n(){var e;return g(this,n),(e=t.call(this)).state={className:""},e}return v(n,[{key:"componentWillUnmount",value:function(){clearTimeout(this.timeoutId)}},{key:"onNotificationClose",value:function(){this.props.onHideNotification()}},{key:"componentDidUpdate",value:function(){var e=this.context.showPopup;!this.state.className&&e&&this.setState({className:"slideout"})}},{key:"componentDidMount",value:function(){var e=this,t=this.props,n=t.autoHide,r=t.duration,i=void 0===r?2400:r;this.context.showPopup?this.setState({className:"slideout"}):n&&(this.timeoutId=setTimeout((function(){e.setState({className:"slideout"})}),i))}},{key:"onAnimationEnd",value:function(e){"notification-slideout"!==e.animationName&&"notification-slideout-mobile"!==e.animationName||this.props.onHideNotification(e)}},{key:"render",value:function(){var e=this,t=this.props,n=t.type,r=t.status,i=this.state.className,o=void 0===i?"":i,a=r?" ".concat(r):" neutral",l=o?" ".concat(o):"";return Object(Hn.jsx)("div",{className:"gh-portal-notification-wrapper",children:Object(Hn.jsxs)("div",{className:"gh-portal-notification".concat(a).concat(l),onAnimationEnd:function(t){return e.onAnimationEnd(t)},children:["error"===r?Object(Hn.jsx)(ci,{className:"gh-portal-notification-icon error",alt:""}):Object(Hn.jsx)(ii,{className:"gh-portal-notification-icon success",alt:""}),Object(Hn.jsx)(mi,{type:n,status:r,context:this.context}),Object(Hn.jsx)(Jr,{className:"gh-portal-notification-closeicon",alt:"Close",onClick:function(t){return e.onNotificationClose(t)}})]})})}}]),n}(hi.Component);gi.contextType=Zn;var bi,vi,yi=function(e){x(n,e);var t=O(n);function n(){var e;g(this,n),e=t.call(this);var r=fi()||{},i=r.type,o=r.status,a=r.autoHide,l=r.duration;return e.state={active:!0,type:i,status:o,autoHide:a,duration:l,className:""},e}return v(n,[{key:"onHideNotification",value:function(){var e=this.state.type,t=[];["signin","signup"].includes(e)?t.push("action","success"):["stripe:checkout"].includes(e)&&t.push("stripe"),di(t),this.context.onAction("refreshMemberData"),this.setState({active:!1})}},{key:"renderFrameStyles",value:function(){var e="\n :root {\n --brandcolor: ".concat(this.context.brandColor,"\n }\n ")+'\n /* Colors\n /* ----------------------------------------------------- */\n :root {\n --black: #000;\n --grey0: #1d1d1d;\n --grey1: #333;\n --grey2: #3d3d3d;\n --grey3: #474747;\n --grey4: #515151;\n --grey5: #686868;\n --grey6: #7f7f7f;\n --grey7: #979797;\n --grey8: #aeaeae;\n --grey9: #c5c5c5;\n --grey10: #dcdcdc;\n --grey11: #e1e1e1;\n --grey12: #eaeaea;\n --grey13: #f9f9f9;\n --grey14: #fbfbfb;\n --white: #fff;\n --red: #f02525;\n --yellow: #FFDC15;\n --green: #7FC724;\n }\n\n /* Globals\n /* ----------------------------------------------------- */\n html {\n font-size: 62.5%;\n height: 100%;\n }\n\n body {\n margin: 0px;\n font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Oxygen, Ubuntu, Cantarell, "Open Sans", "Helvetica Neue", sans-serif;\n font-size: 1.6rem;\n height: 100%;\n line-height: 1.6em;\n font-weight: 400;\n font-style: normal;\n color: var(--grey2);\n box-sizing: border-box;\n overflow: hidden;\n }\n\n button,\n button span {\n font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Oxygen, Ubuntu, Cantarell, "Open Sans", "Helvetica Neue", sans-serif;\n }\n\n *, ::after, ::before {\n box-sizing: border-box;\n }\n\n h1, h2, h3, h4, h5, h6, p {\n line-height: 1.15em;\n padding: 0;\n margin: 0;\n }\n\n h1 {\n font-size: 35px;\n font-weight: 700;\n letter-spacing: -0.022em;\n }\n\n h2 {\n font-size: 32px;\n font-weight: 700;\n letter-spacing: -0.021em;\n }\n\n h3 {\n font-size: 24px;\n font-weight: 700;\n letter-spacing: -0.019em;\n }\n\n p {\n font-size: 15px;\n line-height: 1.5em;\n margin-bottom: 24px;\n }\n\n strong {\n font-weight: 600;\n }\n\n a,\n .gh-portal-link {\n cursor: pointer;\n }\n\n svg {\n box-sizing: content-box;\n }\n\n input,\n textarea {\n font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Oxygen, Ubuntu, Cantarell, "Open Sans", "Helvetica Neue", sans-serif;\n font-size: 1.5rem;\n }\n\n textarea {\n padding: 10px;\n line-height: 1.5em;\n }\n\n @media (max-width: 1440px) {\n h1 {\n font-size: 32px;\n letter-spacing: -0.022em;\n }\n\n h2 {\n font-size: 28px;\n letter-spacing: -0.021em;\n }\n\n h3 {\n font-size: 26px;\n letter-spacing: -0.02em;\n }\n }\n\n @media (max-width: 480px) {\n h1 {\n font-size: 30px;\n letter-spacing: -0.021em;\n }\n\n h2 {\n font-size: 26px;\n letter-spacing: -0.02em;\n }\n\n h3 {\n font-size: 24px;\n letter-spacing: -0.019em;\n }\n }\n\n .gh-portal-notification-wrapper {\n position: relative;\n overflow: hidden;\n height: 100%;\n width: 100%;\n }\n\n .gh-portal-notification {\n position: absolute;\n display: flex;\n align-items: center;\n top: 12px;\n right: 12px;\n width: 100%;\n padding: 14px 44px 18px 20px;\n max-width: 380px;\n min-height: 66px;\n font-size: 1.3rem;\n letter-spacing: 0.2px;\n background: rgba(33,33,33,0.95);\n backdrop-filter: blur(8px);\n color: var(--white);\n border-radius: 7px;\n box-shadow: 0 3.2px 3.6px rgba(0, 0, 0, 0.024), 0 8.8px 10px -5px rgba(0, 0, 0, 0.08);\n animation: notification-slidein 0.55s cubic-bezier(0.215, 0.610, 0.355, 1.000);\n }\n\n .gh-portal-notification.slideout {\n animation: notification-slideout 0.4s cubic-bezier(0.550, 0.055, 0.675, 0.190);\n }\n\n .gh-portal-notification.hide {\n display: none;\n }\n\n .gh-portal-notification p {\n flex-grow: 1;\n font-size: 1.4rem;\n line-height: 1.5em;\n text-align: left;\n margin: 0;\n padding: 0 0 0 40px;\n color: var(--grey13);\n }\n\n .gh-portal-notification p strong {\n color: var(--white);\n }\n\n .gh-portal-notification a {\n color: var(--white);\n text-decoration: underline;\n transition: all 0.2s ease-in-out;\n outline: none;\n }\n\n .gh-portal-notification a:hover {\n opacity: 0.8;\n }\n\n .gh-portal-notification-icon {\n position: absolute;\n top: calc(50% - 14px);\n left: 17px;\n width: 28px;\n height: 28px;\n }\n\n .gh-portal-notification-icon.success {\n color: var(--green);\n }\n\n .gh-portal-notification-icon.error {\n color: #FF2828;\n }\n\n .gh-portal-notification-closeicon {\n position: absolute;\n top: 5px;\n bottom: 0;\n right: 5px;\n color: var(--white);\n cursor: pointer;\n width: 12px;\n height: 12px;\n padding: 10px;\n transition: all 0.2s ease-in-out forwards;\n opacity: 0.8;\n }\n\n .gh-portal-notification-closeicon:hover {\n opacity: 1.0;\n } \n\n @keyframes notification-slidein {\n 0% { transform: translateX(380px); }\n 60% { transform: translateX(-6px); }\n 100% { transform: translateX(0); }\n }\n\n @keyframes notification-slideout {\n 0% { transform: translateX(0); }\n 30% { transform: translateX(-10px); }\n 100% { transform: translateX(380px); }\n }\n\n @keyframes notification-slidein-mobile {\n 0% { transform: translateY(-150px); }\n 50% { transform: translateY(6px); }\n 100% { transform: translateY(0); }\n }\n\n @keyframes notification-slideout-mobile {\n 0% { transform: translateY(0); }\n 35% { transform: translateY(6px); }\n 100% { transform: translateY(-150px); }\n }\n\n @media (max-width: 414px) {\n .gh-portal-notification {\n left: 12px;\n max-width: calc(100% - 24px);\n animation-name: notification-slidein-mobile;\n }\n\n .gh-portal-notification.slideout {\n animation-duration: 0.55s;\n animation-name: notification-slideout-mobile;\n }\n }\n';return Object(Hn.jsx)("style",{dangerouslySetInnerHTML:{__html:e}})}},{key:"render",value:function(){var e=this,t=(this.context.brandColor,{frame:{zIndex:"4000000",position:"fixed",top:"0",right:"0",maxWidth:"415px",width:"100%",height:"120px",animation:"250ms ease 0s 1 normal none running animation-bhegco",transition:"opacity 0.3s ease 0s",overflow:"hidden"}}),n=Object(k.a)({},t.frame);if(!this.state.active)return null;var r=this.state,i=r.type,o=r.status,a=r.autoHide,l=r.duration;return i&&o?Object(Hn.jsx)($n,{style:n,title:"portal-notification",head:this.renderFrameStyles(),className:"gh-portal-notification-iframe",children:Object(Hn.jsx)(gi,{type:i,status:o,autoHide:a,duration:l,onHideNotification:function(t){return e.onHideNotification(t)}})}):null}}]),n}(hi.Component);yi.contextType=Zn;var xi=["title","titleId"];function wi(){return wi=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(e[r]=n[r])}return e},wi.apply(this,arguments)}function ji(e,t){if(null==e)return{};var n,r,i=function(e,t){if(null==e)return{};var n,r,i={},o=Object.keys(e);for(r=0;r<o.length;r++)n=o[r],t.indexOf(n)>=0||(i[n]=e[n]);return i}(e,t);if(Object.getOwnPropertySymbols){var o=Object.getOwnPropertySymbols(e);for(r=0;r<o.length;r++)n=o[r],t.indexOf(n)>=0||Object.prototype.propertyIsEnumerable.call(e,n)&&(i[n]=e[n])}return i}function Oi(e,t){var n=e.title,r=e.titleId,o=ji(e,xi);return i.createElement("svg",wi({id:"loader-1",xmlns:"http://www.w3.org/2000/svg",xmlnsXlink:"http://www.w3.org/1999/xlink",x:"0px",y:"0px",width:"40px",height:"40px",viewBox:"0 0 40 40",enableBackground:"new 0 0 40 40",xmlSpace:"preserve",ref:t,"aria-labelledby":r},o),n?i.createElement("title",{id:r},n):null,bi||(bi=i.createElement("path",{opacity:.2,fill:"#000",d:"M20.201,5.169c-8.254,0-14.946,6.692-14.946,14.946c0,8.255,6.692,14.946,14.946,14.946 s14.946-6.691,14.946-14.946C35.146,11.861,28.455,5.169,20.201,5.169z M20.201,31.749c-6.425,0-11.634-5.208-11.634-11.634 c0-6.425,5.209-11.634,11.634-11.634c6.425,0,11.633,5.209,11.633,11.634C31.834,26.541,26.626,31.749,20.201,31.749z"})),vi||(vi=i.createElement("path",{fill:"#000",d:"M26.013,10.047l1.654-2.866c-2.198-1.272-4.743-2.012-7.466-2.012h0v3.312h0 C22.32,8.481,24.301,9.057,26.013,10.047z"},i.createElement("animateTransform",{attributeType:"xml",attributeName:"transform",type:"rotate",from:"0 20 20",to:"360 20 20",dur:"0.5s",repeatCount:"indefinite"}))))}var ki=i.forwardRef(Oi);n.p;var _i,Si,Pi=function(e){var t=e.label,n=(e.type,e.onClick),r=e.disabled,i=void 0!==r&&r,o=e.retry,a=void 0!==o&&o,l=e.brandColor,s=e.isRunning,c=e.isPrimary,u=void 0===c||c,p=e.isDestructive,d=void 0!==p&&p,f=e.classes,h=void 0===f?"":f,m=e.style,g=void 0===m?{}:m,b=e.tabindex,v=void 0===b?void 0:b,y=function(e){var t=e.brandColor,n=(e.retry,e.disabled),r=e.style,i=void 0===r?{}:r,o=e.isPrimary,a=t||"#3eb0ef",l="1.0",s="auto";return n&&(l="0.5",s="none"),{button:Object(k.a)(Object(k.a)(Object(k.a)({},o?{color:"#fff"}:{}),o?{backgroundColor:a}:{}),{},{opacity:l,pointerEvents:s},i||{})}}({disabled:i,retry:a,brandColor:l,style:g,isPrimary:u}),x="gh-portal-btn";u&&(x+=" gh-portal-btn-main gh-portal-btn-primary"),d&&(x+=" gh-portal-btn-destructive"),h&&(x+=" "+h),Object(Lr.isCookiesDisabled)()&&(i=!0);var w=u?"gh-portal-loadingicon":"gh-portal-loadingicon dark";return Object(Hn.jsx)("button",{className:x,style:y.button,onClick:function(e){return n(e)},disabled:i,type:"submit",tabIndex:v,children:s?Object(Hn.jsx)(ki,{className:w}):t})},Ei=["title","titleId"];function Ci(){return Ci=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(e[r]=n[r])}return e},Ci.apply(this,arguments)}function Ni(e,t){if(null==e)return{};var n,r,i=function(e,t){if(null==e)return{};var n,r,i={},o=Object.keys(e);for(r=0;r<o.length;r++)n=o[r],t.indexOf(n)>=0||(i[n]=e[n]);return i}(e,t);if(Object.getOwnPropertySymbols){var o=Object.getOwnPropertySymbols(e);for(r=0;r<o.length;r++)n=o[r],t.indexOf(n)>=0||Object.prototype.propertyIsEnumerable.call(e,n)&&(i[n]=e[n])}return i}function Ti(e,t){var n=e.title,r=e.titleId,o=Ni(e,Ei);return i.createElement("svg",Ci({id:"Regular",xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24",ref:t,"aria-labelledby":r},o),n?i.createElement("title",{id:r},n):null,_i||(_i=i.createElement("defs",null,i.createElement("style",null,".cls-1{fill:none;stroke:currentColor;stroke-linecap:round;stroke-linejoin:round;stroke-width:1.5px;fill-rule:evenodd;}"))),Si||(Si=i.createElement("path",{className:"cls-1",d:"M16.25,23.25,5.53,12.53a.749.749,0,0,1,0-1.06L16.25.75"})))}var Ii=i.forwardRef(Ti);n.p;var Li=function(e){var t=e.label,n=void 0===t?"Back":t,r=(e.brandColor,e.hidden),i=void 0!==r&&r,o=e.onClick;return i?null:Object(Hn.jsxs)("button",{className:"gh-portal-btn gh-portal-btn-back",onClick:function(e){return o(e)},children:[Object(Hn.jsx)(Ii,{})," ",n]})};var Mi=function(e){var t=e.id,n=e.label,r=void 0===n?"":n,o=e.onToggle,a=e.checked,l=void 0!==a&&a,c=Object(i.useContext)(Zn).action,u=Object(i.useState)(l),p=Object(s.a)(u,2),d=p[0],f=p[1],h=["updateNewsletter:failed","updateNewsletter:success"].includes(c);return Object(i.useEffect)((function(){f(l)}),[l,h]),Object(Hn.jsx)("div",{className:"gh-portal-for-switch",children:Object(Hn.jsxs)("label",{className:"switch",htmlFor:t,children:[Object(Hn.jsx)("input",{type:"checkbox",checked:d,id:t,onChange:function(){},"aria-label":r}),Object(Hn.jsx)("span",{className:"input-toggle-component",onClick:function(e){f(!d),o(e,!d)},"data-testid":"switch-input"})]})})},Fi=function(e){x(n,e);var t=O(n);function n(){return g(this,n),t.apply(this,arguments)}return v(n,[{key:"render",value:function(){var e=this;return Object(Hn.jsx)("div",{className:"gh-portal-closeicon-container",children:Object(Hn.jsx)(Jr,{className:"gh-portal-closeicon",alt:"Close",onClick:function(){return e.context.onAction("closePopup")}})})}}]),n}(o.a.Component);Fi.contextType=Zn;var Di,zi,Ri,Ui=n(10),Ai=["title","titleId"];function Bi(){return Bi=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(e[r]=n[r])}return e},Bi.apply(this,arguments)}function Hi(e,t){if(null==e)return{};var n,r,i=function(e,t){if(null==e)return{};var n,r,i={},o=Object.keys(e);for(r=0;r<o.length;r++)n=o[r],t.indexOf(n)>=0||(i[n]=e[n]);return i}(e,t);if(Object.getOwnPropertySymbols){var o=Object.getOwnPropertySymbols(e);for(r=0;r<o.length;r++)n=o[r],t.indexOf(n)>=0||Object.prototype.propertyIsEnumerable.call(e,n)&&(i[n]=e[n])}return i}function qi(e,t){var n=e.title,r=e.titleId,o=Hi(e,Ai);return i.createElement("svg",Bi({width:24,height:24,viewBox:"0 0 24 24",fill:"none",xmlns:"http://www.w3.org/2000/svg",ref:t,"aria-labelledby":r},o),n?i.createElement("title",{id:r},n):null,Di||(Di=i.createElement("defs",null,i.createElement("style",null,".a{fill:none;stroke:currentColor;stroke-linecap:round;stroke-linejoin:round;stroke-width:1.5px;}"))),zi||(zi=i.createElement("path",{d:"M22.939 2.56V8.817C22.9391 9.61244 22.6232 10.3754 22.061 10.938L10.5 22.5C10.2187 22.7812 9.83721 22.9392 9.43946 22.9392C9.04172 22.9392 8.66026 22.7812 8.37896 22.5L1.49997 15.62C1.21876 15.3387 1.06079 14.9572 1.06079 14.5595C1.06079 14.1618 1.21876 13.7803 1.49997 13.499L13.061 1.938C13.6236 1.37572 14.3865 1.0599 15.182 1.06H21.439C21.8368 1.06 22.2183 1.21803 22.4996 1.49934C22.7809 1.78064 22.939 2.16217 22.939 2.56V2.56Z",className:"a"})),Ri||(Ri=i.createElement("path",{d:"M17.689 7.81C16.8605 7.81 16.189 7.13842 16.189 6.31C16.189 5.48157 16.8605 4.81 17.689 4.81C18.5174 4.81 19.189 5.48157 19.189 6.31C19.189 7.13842 18.5174 7.81 17.689 7.81Z",className:"a"})))}var $i=i.forwardRef(qi),Wi=(n.p,n(1)),Qi=function(e){var t=e.avatar,n=e.brandColor;return Object(Hn.jsx)(Hn.Fragment,{children:Object(Hn.jsx)(Xn,{gravatar:t,style:{userIcon:{color:n,width:"56px",height:"56px",padding:"2px"}}})})},Vi=function(e){e.onClose;var t=e.handleSignout,n=e.supportAddress,r="mailto:".concat(void 0===n?"":n);return Object(Hn.jsxs)("footer",{className:"gh-portal-account-footer",children:[Object(Hn.jsx)("ul",{className:"gh-portal-account-footermenu",children:Object(Hn.jsx)("li",{children:Object(Hn.jsx)("button",{className:"gh-portal-btn",name:"logout","aria-label":"logout",onClick:function(e){return t(e)},children:"Sign out"})})}),Object(Hn.jsx)("div",{className:"gh-portal-account-footerright",children:Object(Hn.jsx)("ul",{className:"gh-portal-account-footermenu",children:Object(Hn.jsx)("li",{children:Object(Hn.jsx)("a",{className:"gh-portal-btn gh-portal-btn-branded",href:r,onClick:function(){r&&window.open(r)},children:"Contact support"})})})})]})},Yi=function(){var e=Object(i.useContext)(Zn),t=e.member,n=e.brandColor,r=t.avatar_image;return Object(Hn.jsxs)("header",{className:"gh-portal-account-header",children:[Object(Hn.jsx)(Qi,{avatar:r,brandColor:n}),Object(Hn.jsx)("h2",{className:"gh-portal-main-title",children:"Your account"})]})};function Ki(e){var t=e.subscription;e.priceLabel;if(Object(Lr.subscriptionHasFreeTrial)({sub:t})){var n=Object(Ui.a)(t.trial_end_at);return Object(Hn.jsx)("p",{className:"gh-portal-account-discountcontainer",children:Object(Hn.jsx)("div",{children:Object(Hn.jsxs)("span",{children:["Free Trial \u2013 Ends ",n]})})})}return null}var Gi=function(){var e=Object(i.useContext)(Zn),t=e.member,n=e.site,r=e.onAction,o=function(e){var n=e.price,r=e.isComplimentary,i=e.subscription,o=i||{},a=o.offer,l=o.start_date,s="";if(n){var c=n.amount,u=void 0===c?0:c,p=n.currency,d=n.interval;s="".concat(Intl.NumberFormat("en",{currency:p,style:"currency"}).format(u/100),"/").concat(d)}var f=function(e){var t=e.offer,n=e.price,r=e.subscriptionStartDate,i="";if(t){var o=t.duration,a="";if("forever"===o)a="Forever";else if("repeating"===o){var l=t.duration_in_months||0,s=new Date(r),c=new Date(s.setMonth(s.getMonth()+l));a="Ends ".concat(Object(Ui.a)(c))}i="".concat(Object(Lr.getUpdatedOfferPrice)({offer:t,price:n,useFormatted:!0}),"/").concat(n.interval).concat(a?" \u2014 ".concat(a):"")}return i}({price:n,offer:a,subscriptionStartDate:l}),h=Object(Lr.getCompExpiry)({member:t});r&&(s=h?"Complimentary - Expires ".concat(h):s?"Complimentary (".concat(s,")"):"Complimentary");var m="";f&&(m="gh-portal-account-old-price");var g=function(){return f?Object(Hn.jsxs)("p",{className:"gh-portal-account-discountcontainer",children:[Object(Hn.jsx)($i,{className:"gh-portal-account-tagicon"}),Object(Hn.jsx)("span",{children:f})]}):null},b=Object(Lr.subscriptionHasFreeTrial)({sub:i});return b&&(m="gh-portal-account-old-price"),b?Object(Hn.jsxs)(Hn.Fragment,{children:[Object(Hn.jsx)("p",{className:m,children:s}),Object(Hn.jsx)(Ki,{subscription:i})]}):Object(Hn.jsxs)(Hn.Fragment,{children:[Object(Hn.jsx)("p",{className:m,children:s}),Object(Hn.jsx)(g,{})]})},a=function(e){var i=e.isComplimentary;return!Object(Lr.allowCompMemberUpgrade)({member:t})&&i||Object(Lr.hasOnlyFreePlan)({site:n})?null:Object(Hn.jsx)("button",{className:"gh-portal-btn gh-portal-btn-list",onClick:function(e){n.is_stripe_configured&&r("switchPage",{page:"accountPlan",lastPage:"accountHome"})},children:"Change"})},l=function(e){var t=e.defaultCardLast4;if(t){var n="**** **** **** ".concat(t);return Object(Hn.jsx)("p",{children:n})}return null},s=function(e){var n=e.defaultCardLast4,o=e.isComplimentary,a="editBilling:running"===Object(i.useContext)(Zn).action?Object(Hn.jsx)(ki,{className:"gh-portal-billing-button-loader"}):"Update";return o?null:Object(Hn.jsxs)("section",{children:[Object(Hn.jsxs)("div",{className:"gh-portal-list-detail",children:[Object(Hn.jsx)("h3",{children:"Billing info"}),Object(Hn.jsx)(l,{defaultCardLast4:n})]}),Object(Hn.jsx)("button",{className:"gh-portal-btn gh-portal-btn-list",onClick:function(e){return function(){var e=Object(Lr.getMemberSubscription)({member:t});r("editBilling",{subscriptionId:e.id})}()},children:a})]})},c=Object(Lr.getMemberSubscription)({member:t}),u=Object(Lr.isComplimentaryMember)({member:t});if(c||u){var p=c||{},d=p.price,f=p.default_payment_card_last4,h="Plan";return Object(Lr.hasMultipleProductsFeature)({site:n})&&Object(Lr.getMemberTierName)({member:t})&&(h=Object(Lr.getMemberTierName)({member:t})),Object(Hn.jsxs)(Hn.Fragment,{children:[Object(Hn.jsxs)("section",{children:[Object(Hn.jsxs)("div",{className:"gh-portal-list-detail",children:[Object(Hn.jsx)("h3",{children:h}),Object(Hn.jsx)(o,{price:d,isComplimentary:u,subscription:c})]}),Object(Hn.jsx)(a,{isComplimentary:u})]}),Object(Hn.jsx)(s,{isComplimentary:u,defaultCardLast4:f})]})}return null},Ji=function(){var e=Object(i.useContext)(Zn),t=e.member,n=e.onAction,r=t.name,o=t.email;return Object(Hn.jsx)("div",{children:Object(Hn.jsxs)("div",{className:"gh-portal-list",children:[Object(Hn.jsxs)("section",{children:[Object(Hn.jsxs)("div",{className:"gh-portal-list-detail",children:[Object(Hn.jsx)("h3",{children:r||"Account"}),Object(Hn.jsx)("p",{children:o})]}),Object(Hn.jsx)("button",{className:"gh-portal-btn gh-portal-btn-list",onClick:function(e){n("switchPage",{page:"accountProfile",lastPage:"accountHome"})},children:"Edit"})]}),Object(Hn.jsx)(Gi,{}),Object(Hn.jsx)(Zi,{}),Object(Hn.jsx)(Xi,{})]})})};function Xi(){var e=Object(i.useContext)(Zn),t=e.member,n=e.site,r=e.onAction,o=t.newsletters;if(Object(Lr.hasMultipleNewsletters)({site:n})||Object(Lr.hasCommentsEnabled)({site:n}))return null;var a=!(null===o||void 0===o||!o.length),l=a?"Subscribed":"Unsubscribed";return Object(Hn.jsxs)("section",{children:[Object(Hn.jsxs)("div",{className:"gh-portal-list-detail",children:[Object(Hn.jsx)("h3",{children:"Email newsletter"}),Object(Hn.jsx)("p",{children:l})]}),Object(Hn.jsx)("div",{children:Object(Hn.jsx)(Mi,{id:"default-newsletter-toggle",onToggle:function(e){!function(e,i){var o;e.preventDefault();var a=Object(Lr.getSiteNewsletters)({site:n}),l=null!==t&&void 0!==t&&null!==(o=t.newsletters)&&void 0!==o&&o.length?[]:a;r("updateNewsletterPreference",{newsletters:l})}(e)},checked:a})})]})}function Zi(){var e=Object(i.useContext)(Zn),t=e.site,n=e.onAction;return Object(Lr.hasMultipleNewsletters)({site:t})||Object(Lr.hasCommentsEnabled)({site:t})?Object(Hn.jsxs)("section",{children:[Object(Hn.jsxs)("div",{className:"gh-portal-list-detail",children:[Object(Hn.jsx)("h3",{children:"Emails"}),Object(Hn.jsx)("p",{children:"Update your preferences"})]}),Object(Hn.jsx)("button",{className:"gh-portal-btn gh-portal-btn-list",onClick:function(e){n("switchPage",{page:"accountEmail",lastPage:"accountHome"})},children:"Manage"})]}):null}var eo=function(){var e=Object(i.useContext)(Zn),t=e.site,n=e.action,r=e.brandColor,o=e.onAction;if(!t.is_stripe_configured||Object(Lr.hasOnlyFreePlan)({site:t}))return null;var a=["checkoutPlan:running"].includes(n);return Object(Hn.jsx)(Pi,{isRunning:a,label:"View plans",onClick:function(){o("switchPage",{page:"accountPlan",lastPage:"accountHome"})},brandColor:r,style:{width:"100%"}})},to=function(){var e=Object(i.useContext)(Zn),t=e.member,n=e.site;if(!n.is_stripe_configured||Object(Lr.hasOnlyFreePlan)({site:n}))return null;var r=Object(Lr.getMemberSubscription)({member:t}),o=Object(Lr.isComplimentaryMember)({member:t});if(o&&!r)return null;if(r){var a=null===r||void 0===r?void 0:r.current_period_end;if(o&&Object(Lr.getCompExpiry)({member:t})){var l=Object(Lr.getCompExpiry)({member:t}),s=Object(Ui.a)(l);return Object(Hn.jsx)("div",{className:"gh-portal-section",children:Object(Hn.jsxs)("p",{className:"gh-portal-text-center gh-portal-free-ctatext",children:["Your subscription will expire on ",s]})})}if(null!==r&&void 0!==r&&r.cancel_at_period_end)return null;if(Object(Lr.subscriptionHasFreeTrial)({sub:r})){var c=Object(Ui.a)(r.trial_end_at);return Object(Hn.jsx)("div",{className:"gh-portal-section",children:Object(Hn.jsxs)("p",{className:"gh-portal-text-center gh-portal-free-ctatext",children:["Your subscription will start on ",c]})})}return Object(Hn.jsx)("div",{className:"gh-portal-section",children:Object(Hn.jsxs)("p",{className:"gh-portal-text-center gh-portal-free-ctatext",children:["Your subscription will renew on ",Object(Ui.a)(a)]})})}return Object(Hn.jsxs)("div",{className:"gh-portal-section",children:[Object(Hn.jsx)("p",{className:"gh-portal-text-center gh-portal-free-ctatext",children:"You currently have a free membership, upgrade to a paid subscription for full access."}),Object(Hn.jsx)(eo,{})]})},no=function(){var e=Object(i.useContext)(Zn),t=e.member,n=e.onAction,r=e.action,o=e.brandColor,a=Object(Lr.getMemberSubscription)({member:t});if(!a)return null;if(!a.cancel_at_period_end)return null;var l=a.cancel_at_period_end?"Continue subscription":"Cancel subscription",s=["cancelSubscription:running"].includes(r),c=!!s,u=!!a.cancel_at_period_end,p=function(){if(!a.cancel_at_period_end)return null;var e=a.current_period_end;return Object(Hn.jsxs)("p",{className:"gh-portal-text-center gh-portal-free-ctatext",children:["Your subscription will expire on ",Object(Ui.a)(e)]})};return Object(Hn.jsxs)("div",{className:"gh-portal-cancelcontinue-container",children:[Object(Hn.jsx)(p,{}),Object(Hn.jsx)(Pi,{onClick:function(e){n("continueSubscription",{subscriptionId:a.id})},isRunning:s,disabled:c,isPrimary:u,brandColor:o,label:l,style:{width:"100%"}})]})},ro=function(){return Object(Hn.jsxs)("div",{className:"gh-portal-content gh-portal-account-main",children:[Object(Hn.jsx)(Fi,{}),Object(Hn.jsx)(Yi,{}),Object(Hn.jsxs)("section",{className:"gh-portal-account-data",children:[Object(Hn.jsx)(to,{}),Object(Hn.jsx)(no,{}),Object(Hn.jsx)(Ji,{})]})]})},io=function(e){x(n,e);var t=O(n);function n(){return g(this,n),t.apply(this,arguments)}return v(n,[{key:"componentDidMount",value:function(){this.context.member||this.context.onAction("switchPage",{page:"signin"})}},{key:"handleSignout",value:function(e){e.preventDefault(),this.context.onAction("signout")}},{key:"render",value:function(){var e=this,t=this.context,n=t.member,r=t.site,i=Object(Lr.getSupportAddress)({site:r});return n?Object(Hn.jsxs)("div",{className:"gh-portal-account-wrapper",children:[Object(Hn.jsx)(ro,{}),Object(Hn.jsx)(Vi,{onClose:function(){return e.context.onAction("closePopup")},handleSignout:function(t){return e.handleSignout(t)},supportAddress:i})]}):null}}]),n}(Wi.Component);io.contextType=Zn;var oo,ao=n(20),lo=n.n(ao),so=["title","titleId"];function co(){return co=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(e[r]=n[r])}return e},co.apply(this,arguments)}function uo(e,t){if(null==e)return{};var n,r,i=function(e,t){if(null==e)return{};var n,r,i={},o=Object.keys(e);for(r=0;r<o.length;r++)n=o[r],t.indexOf(n)>=0||(i[n]=e[n]);return i}(e,t);if(Object.getOwnPropertySymbols){var o=Object.getOwnPropertySymbols(e);for(r=0;r<o.length;r++)n=o[r],t.indexOf(n)>=0||Object.prototype.propertyIsEnumerable.call(e,n)&&(i[n]=e[n])}return i}function po(e,t){var n=e.title,r=e.titleId,o=uo(e,so);return i.createElement("svg",co({width:15,height:14,viewBox:"0 0 15 14",fill:"none",xmlns:"http://www.w3.org/2000/svg",ref:t,"aria-labelledby":r},o),n?i.createElement("title",{id:r},n):null,oo||(oo=i.createElement("path",{d:"M1 6.89286L6.10714 12L13.9643 1",stroke:"#222222",strokeWidth:2})))}var fo=i.forwardRef(po),ho=(n.p,o.a.createContext({selectedInterval:"month",selectedProduct:"free",selectedPlan:null,setSelectedProduct:null}));function mo(e){var t=e.product;return t.benefits&&t.benefits.length?t.benefits.map((function(e,t){var n=(null===e||void 0===e?void 0:e.id)||"benefit-".concat(t);return Object(Hn.jsxs)("div",{className:"gh-portal-product-benefit",children:[Object(Hn.jsx)(fo,{className:"gh-portal-benefit-checkmark",alt:""}),Object(Hn.jsx)("div",{className:"gh-portal-benefit-title",children:e.name})]},n)})):null}function go(e){var t=e.product,n=e.hide,r=void 0!==n&&n;if(!t.benefits||!t.benefits.length||r)return null;return Object(Hn.jsx)("div",{className:"gh-portal-product-benefits",children:Object(Hn.jsx)(mo,{product:t})})}function bo(e){var t=e.price,n=Object(i.useContext)(Zn).site.portal_plans;return n.includes("monthly")&&n.includes("yearly")?Object(Hn.jsx)("div",{className:"gh-portal-product-alternative-price",children:Object(Lr.getPriceString)(t)}):Object(Hn.jsx)("div",{className:"gh-portal-product-alternative-price"})}function vo(e){var t=e.trialDays,n=e.discount,r=e.selectedInterval,o=Object(i.useContext)(Zn).site;return Object(Lr.hasFreeTrialTier)({site:o})?t?Object(Hn.jsxs)("span",{className:"gh-portal-discount-label",children:[t," days free"]}):null:"year"===r?Object(Hn.jsxs)("span",{className:"gh-portal-discount-label",children:[n,"% discount"]}):null}function yo(e){var t=e.product,n=Object(i.useContext)(ho).selectedInterval,r=Object(i.useContext)(Zn).site,o=t.monthlyPrice,a=t.yearlyPrice,l=t.trial_days,s="month"===n?o:a,c="month"===n?a:o;if(!o||!a)return null;var u=lo()(t.monthlyPrice.amount,t.yearlyPrice.amount),p=Object(Lr.getCurrencySymbol)(s.currency);return Object(Lr.hasFreeTrialTier)({site:r})?Object(Hn.jsx)(Hn.Fragment,{children:Object(Hn.jsxs)("div",{className:"gh-portal-product-card-pricecontainer",children:[Object(Hn.jsxs)("div",{className:"gh-portal-product-card-price-trial",children:[Object(Hn.jsxs)("div",{className:"gh-portal-product-price",children:[Object(Hn.jsx)("span",{className:"currency-sign"+(p.length>1?" long":""),children:p}),Object(Hn.jsx)("span",{className:"amount",children:Object(Lr.formatNumber)(Object(Lr.getStripeAmount)(s.amount))}),Object(Hn.jsxs)("span",{className:"billing-period",children:["/",s.interval]})]}),Object(Hn.jsx)(vo,{trialDays:l,discount:u,selectedInterval:n})]}),"year"===n?Object(Hn.jsx)(ko,{discount:u,trialDays:l}):"",Object(Hn.jsx)(bo,{price:c})]})}):Object(Hn.jsxs)("div",{className:"gh-portal-product-card-pricecontainer",children:[Object(Hn.jsxs)("div",{className:"gh-portal-product-card-price-trial",children:[Object(Hn.jsxs)("div",{className:"gh-portal-product-price",children:[Object(Hn.jsx)("span",{className:"currency-sign"+(p.length>1?" long":""),children:p}),Object(Hn.jsx)("span",{className:"amount",children:Object(Lr.formatNumber)(Object(Lr.getStripeAmount)(s.amount))}),Object(Hn.jsxs)("span",{className:"billing-period",children:["/",s.interval]})]}),"year"===n?Object(Hn.jsx)(ko,{discount:u}):""]}),Object(Hn.jsx)(bo,{price:c})]})}function xo(e){var t=e.products,n=e.handleChooseSignup,r=Object(i.useContext)(Zn),o=r.site,a=r.action,l=Object(i.useContext)(ho),s=l.selectedProduct,c=l.setSelectedProduct,u="free"===s?"gh-portal-product-card free checked":"gh-portal-product-card free",p=Object(Lr.getFreeProduct)({site:o}),d=Object(Lr.getFreeTierDescription)({site:o}),f="signup:running"===a;Object(Lr.isCookiesDisabled)()&&(f=!0);var h="$";h=t&&t[1]?Object(Lr.getCurrencySymbol)(t[1].monthlyPrice.currency):"$";var m=Object(Lr.hasOnlyFreeProduct)({site:o}),g=Object(Lr.getFreeProductBenefits)({site:o});if(m){if(!d&&!g.length)return null;u+=" only-free"}return d||g.length||(d="Free preview"),Object(Hn.jsx)(Hn.Fragment,{children:Object(Hn.jsxs)("div",{className:u,onClick:function(e){e.stopPropagation(),c("free")},children:[Object(Hn.jsxs)("div",{className:"gh-portal-product-card-header",children:[Object(Hn.jsx)("h4",{className:"gh-portal-product-name",children:Object(Lr.getFreeTierTitle)({site:o})}),m?"":Object(Hn.jsx)("div",{className:"gh-portal-product-card-pricecontainer free-trial-disabled",children:Object(Hn.jsxs)("div",{className:"gh-portal-product-price",children:[Object(Hn.jsx)("span",{className:"currency-sign"+(h.length>1?" long":""),children:h}),Object(Hn.jsx)("span",{className:"amount",children:"0"})]})})]}),Object(Hn.jsxs)("div",{className:"gh-portal-product-card-details",children:[Object(Hn.jsxs)("div",{className:"gh-portal-product-card-detaildata",children:[d?Object(Hn.jsx)("div",{className:"gh-portal-product-description",children:d}):"",Object(Hn.jsx)(go,{product:p})]}),m?"":Object(Hn.jsx)("div",{className:"gh-portal-btn-product",children:Object(Hn.jsx)("button",{className:"gh-portal-btn",disabled:f,onClick:function(e){n(e,"free")},children:"free"===s&&f?Object(Hn.jsx)(ki,{className:"gh-portal-loadingicon"}):"Choose"})})]})]})})}function wo(e){var t=e.selectedProduct,n=e.product,r=e.disabled,i=e.noOfProducts,o=e.trialDays;return t===n.id&&r?Object(Hn.jsx)(ki,{className:"gh-portal-loadingicon"}):o>0?"Start "+o+"-day free trial":i>1?"Choose":"Continue"}function jo(e){var t,n=e.product,r=e.products,o=e.selectedInterval,a=e.handleChooseSignup,l=Object(i.useContext)(ho),s=l.selectedProduct,c=l.setSelectedProduct,u=Object(i.useContext)(Zn).action,p=n.trial_days,d=s===n.id?"gh-portal-product-card checked":"gh-portal-product-card",f=null===r||void 0===r||null===(t=r.filter((function(e){return"paid"===e.type})))||void 0===t?void 0:t.length,h=!!["signup:running","checkoutPlan:running"].includes(u);Object(Lr.isCookiesDisabled)()&&(h=!0);var m=n.description;return n.benefits&&n.benefits.length||m||(m="Full access"),Object(Hn.jsx)(Hn.Fragment,{children:Object(Hn.jsxs)("div",{className:d,onClick:function(e){e.stopPropagation(),c(n.id)},children:[Object(Hn.jsxs)("div",{className:"gh-portal-product-card-header",children:[Object(Hn.jsx)("h4",{className:"gh-portal-product-name",children:n.name}),Object(Hn.jsx)(yo,{product:n})]}),Object(Hn.jsxs)("div",{className:"gh-portal-product-card-details",children:[Object(Hn.jsxs)("div",{className:"gh-portal-product-card-detaildata",children:[Object(Hn.jsx)("div",{className:"gh-portal-product-description",children:m}),Object(Hn.jsx)(go,{product:n})]}),Object(Hn.jsx)("div",{className:"gh-portal-btn-product",children:Object(Hn.jsx)("button",{disabled:h,className:"gh-portal-btn",onClick:function(e){var t=So({products:r,selectedInterval:o,selectedProduct:n.id});a(e,t.id)},children:Object(Hn.jsx)(wo,{selectedProduct:s,product:n,disabled:h,noOfProducts:f,trialDays:p})})})]})]},n.id)})}function Oo(e){var t=e.products,n=e.selectedInterval,r=e.handleChooseSignup;return t.map((function(e){return"free"===e.id?Object(Hn.jsx)(xo,{products:t,handleChooseSignup:r},e.id):Object(Hn.jsx)(jo,{products:t,product:e,selectedInterval:n,handleChooseSignup:r},e.id)}))}function ko(e){var t=e.discount,n=(e.trialDays,Object(i.useContext)(Zn).site),r=n.portal_plans;return 0!==t&&r.includes("monthly")?Object(Lr.hasFreeTrialTier)({site:n})?Object(Hn.jsx)(Hn.Fragment,{children:Object(Hn.jsxs)("span",{className:"gh-portal-discount-label-trial",children:[t,"% discount"]})}):Object(Hn.jsx)(Hn.Fragment,{children:Object(Hn.jsxs)("span",{className:"gh-portal-discount-label",children:[t,"% discount"]})}):null}function _o(e){e.products;var t=e.selectedInterval,n=e.setSelectedInterval,r=Object(i.useContext)(Zn).site.portal_plans;return r.includes("monthly")&&r.includes("yearly")?Object(Hn.jsx)("div",{className:"gh-portal-logged-out-form-container",children:Object(Hn.jsxs)("div",{className:"gh-portal-products-pricetoggle"+("month"===t?" left":""),children:[Object(Hn.jsx)("button",{className:"gh-portal-btn"+("month"===t?" active":""),onClick:function(e){n("month")},children:"Monthly"}),Object(Hn.jsx)("button",{className:"gh-portal-btn"+("year"===t?" active":""),onClick:function(e){n("year")},children:"Yearly"})]})}):null}function So(e){var t=e.products,n=e.selectedProduct,r=e.selectedInterval,i=null;if("free"===n)i={id:"free"};else{var o,a,l=t.find((function(e){return e.id===n}));l||(l=t.find((function(e){return"paid"===e.type}))),i="month"===r?null===(o=l)||void 0===o?void 0:o.monthlyPrice:null===(a=l)||void 0===a?void 0:a.yearlyPrice}return i}function Po(e){var t=e.portalPlans,n=e.selectedInterval,r=void 0===n?"year":n;return"month"===r&&t.includes("monthly")?"month":"year"===r&&t.includes("yearly")?"year":t.includes("monthly")?"month":t.includes("yearly")?"year":void 0}function Eo(e){var t,n=e.onPlanSelect,r=e.selectedPlan,o=e.products,a=e.type,l=void 0===a?null:a,c=Object(i.useContext)(Zn),u=c.site,p=c.member,d=u.portal_plans,f=Object(Lr.getMemberActivePrice)({member:p}),h=Object(Lr.getProductFromPrice)({site:u,priceId:f.id}),m=Po({portalPlans:d,selectedInterval:f.interval}),g=(null===h||void 0===h?void 0:h.id)||(null===o||void 0===o||null===(t=o[0])||void 0===t?void 0:t.id),b=Object(i.useState)(m),v=Object(s.a)(b,2),y=v[0],x=v[1],w=Object(i.useState)(g),j=Object(s.a)(w,2),O=j[0],k=j[1],_=Po({portalPlans:d,selectedInterval:y});if(Object(i.useEffect)((function(){k(g)}),[g]),!d.includes("monthly")&&!d.includes("yearly"))return null;if(0===o.length)return null;var S="gh-portal-products";return"upgrade"===l&&(S+=" gh-portal-upgrade-product"),"changePlan"===l&&(S+=" gh-portal-upgrade-product gh-portal-change-plan"),Object(Hn.jsx)(ho.Provider,{value:{selectedInterval:_,selectedProduct:O,selectedPlan:r,setSelectedProduct:k},children:Object(Hn.jsxs)("section",{className:S,children:[Object(Hn.jsx)(_o,{selectedInterval:_,setSelectedInterval:x}),Object(Hn.jsx)("div",{className:"gh-portal-products-grid",children:Object(Hn.jsx)(To,{products:o,onPlanSelect:n})})]})})}function Co(e){var t=e.product;e.selectedPrice,e.activePrice;return null!==t&&void 0!==t&&t.description?Object(Hn.jsx)("div",{className:"gh-portal-product-description",children:t.description}):null}function No(e){var t=e.product,n=e.onPlanSelect,r=Object(i.useContext)(Zn),o=r.member,a=r.site,l=Object(i.useContext)(ho),s=l.selectedProduct,c=l.setSelectedProduct,u=l.selectedInterval,p=s===t.id?"gh-portal-product-card checked":"gh-portal-product-card",d=t.monthlyPrice,f=t.yearlyPrice,h=Object(Lr.getMemberActivePrice)({member:o}),m="month"===u?d:f,g=Object(Lr.isMemberActivePrice)({member:o,site:a,priceId:m.id});return Object(Hn.jsxs)("div",{className:p+(g?" disabled":""),onClick:function(e){e.stopPropagation(),c(t.id)},children:[Object(Hn.jsxs)("div",{className:"gh-portal-product-card-header",children:[Object(Hn.jsx)("h4",{className:"gh-portal-product-name",children:t.name}),Object(Hn.jsx)(yo,{product:t})]}),Object(Hn.jsxs)("div",{className:"gh-portal-product-card-details",children:[Object(Hn.jsxs)("div",{className:"gh-portal-product-card-detaildata",children:[t.description?Object(Hn.jsx)(Co,{product:t,selectedPrice:m,activePrice:h}):"",Object(Hn.jsx)(go,{product:t})]}),g?Object(Hn.jsx)("div",{className:"gh-portal-btn-product",children:Object(Hn.jsx)("span",{className:"gh-portal-current-plan",children:Object(Hn.jsx)("span",{children:"Current plan"})})}):Object(Hn.jsx)("div",{className:"gh-portal-btn-product",children:Object(Hn.jsx)("button",{className:"gh-portal-btn",onClick:function(){n(null,null===m||void 0===m?void 0:m.id)},children:"Choose"})})]})]},t.id)}function To(e){var t=e.products,n=e.onPlanSelect;return t.map((function(e){return"free"===e.id?null:Object(Hn.jsx)(No,{product:e,onPlanSelect:n},e.id)}))}var Io=function(e){var t,n,r=e.onPlanSelect,o=e.products,a=e.type,l=void 0===a?null:a,c=e.handleChooseSignup,u=Object(i.useContext)(Zn).site,p=u.portal_plans,d=Po({portalPlans:p}),f=o.length>0?o[0].id:"free",h=Object(i.useState)(d),m=Object(s.a)(h,2),g=m[0],b=m[1],v=Object(i.useState)(f),y=Object(s.a)(v,2),x=y[0],w=y[1],j=So({products:o,selectedInterval:g,selectedProduct:x}),O=Po({portalPlans:p,selectedInterval:g});if(Object(i.useEffect)((function(){w(f)}),[f]),Object(i.useEffect)((function(){r(null,j.id)}),[j.id,r]),!p.includes("monthly")&&!p.includes("yearly"))return null;if(0===o.length)return null;var k="gh-portal-products";"upgrade"===l&&(k+=" gh-portal-upgrade-product");var _=(null===(t=o.find((function(e){return e.id===x})))||void 0===t?void 0:t.id)||(null===(n=o.find((function(e){return"paid"===e.type})))||void 0===n?void 0:n.id);return Object(Hn.jsx)(ho.Provider,{value:{selectedInterval:O,selectedProduct:_,setSelectedProduct:w},children:Object(Hn.jsxs)("section",{className:k,children:[Object(Lr.hasOnlyFreeProduct)({site:u})?"":Object(Hn.jsx)(_o,{products:o,selectedInterval:O,setSelectedInterval:b}),Object(Hn.jsx)("div",{className:"gh-portal-products-grid",children:Object(Hn.jsx)(Oo,{products:o,selectedInterval:O,handleChooseSignup:c})})]})})};function Lo(e){var t=e.products,n=e.selectedPlan,r=e.onPlanSelect,i=e.onPlanCheckout,o=e.changePlan,a=void 0!==o&&o;return Object(Lr.isCookiesDisabled)()&&(r=function(){}),a?Object(Hn.jsx)("section",{className:"gh-portal-plans",children:Object(Hn.jsx)("div",{children:Object(Hn.jsx)(Eo,{type:"changePlan",products:t,selectedPlan:n,onPlanSelect:r})})}):Object(Hn.jsx)("section",{className:"gh-portal-plans",children:Object(Hn.jsx)("div",{children:Object(Hn.jsx)(Io,{type:"upgrade",products:t,onPlanSelect:r,handleChooseSignup:function(){i.apply(void 0,arguments)}})})})}var Mo=n(1);var Fo=function(e){e.onBack;var t=e.showConfirmation,n=e.confirmationType,r=Object(i.useContext)(Zn).member,o=Object(Lr.isPaidMember)({member:r})?"Change plan":"Choose a plan";return t&&(o=function(e){var t=e.confirmationType;return"changePlan"===t?"Confirm subscription":"cancel"===t?"Cancel subscription":"subscribe"===t?"Subscribe":void 0}({confirmationType:n})),Object(Hn.jsx)("header",{className:"gh-portal-detail-header",children:Object(Hn.jsx)("h3",{className:"gh-portal-main-title",children:o})})},Do=function(e){var t=e.member,n=e.onCancelSubscription,r=e.action,o=e.brandColor,a=Object(i.useContext)(Zn).site;if(!t.paid)return null;var l=Object(Lr.getMemberSubscription)({member:t});if(!l)return null;if(l.cancel_at_period_end)return null;var s=["cancelSubscription:running"].includes(r),c=!!s,u=!!l.cancel_at_period_end,p=!l.cancelAtPeriodEnd;return Object(Hn.jsx)("div",{className:"gh-portal-expire-container",children:Object(Hn.jsx)(Pi,{onClick:function(e){n({subscriptionId:l.id,cancelAtPeriodEnd:!0})},isRunning:s,disabled:c,isPrimary:u,isDestructive:p,classes:Object(Lr.hasMultipleProductsFeature)({site:a})?"gh-portal-btn-text mt2 mb4":"",brandColor:o,label:"Cancel subscription",style:{width:"100%"}})})},zo=function(e){var t=e.plan,n=e.type,r=e.onConfirm,o=Object(i.useContext)(Zn),a=o.site,l=o.action,c=o.member,u=o.brandColor,p=Object(i.useState)(""),d=Object(s.a)(p,2),f=d[0],h=d[1],m=Object(Lr.getMemberSubscription)({member:c}),g=["updateSubscription:running","checkoutPlan:running","cancelSubscription:running"].includes(l),b="Confirm",v=Object(Ui.a)(m.current_period_end);Object(Lr.getMemberActivePrice)({member:c}).id!==t.id&&(v="today");var y=Object(Lr.formatNumber)(t.price),x="".concat(t.currency_symbol).concat(y,"/").concat(t.interval," \u2013 Starting ").concat(v),w=Object(Lr.getProductFromPrice)({site:a,priceId:null===t||void 0===t?void 0:t.id}),j=Object(Lr.hasMultipleProductsFeature)({site:a})?null===w||void 0===w?void 0:w.name:"Price";return"changePlan"===n?Object(Hn.jsxs)("div",{className:"gh-portal-logged-out-form-container",children:[Object(Hn.jsxs)("div",{className:"gh-portal-list mb6",children:[Object(Hn.jsx)("section",{children:Object(Hn.jsxs)("div",{className:"gh-portal-list-detail",children:[Object(Hn.jsx)("h3",{children:"Account"}),Object(Hn.jsx)("p",{children:c.email})]})}),Object(Hn.jsx)("section",{children:Object(Hn.jsxs)("div",{className:"gh-portal-list-detail",children:[Object(Hn.jsx)("h3",{children:j}),Object(Hn.jsx)("p",{children:x})]})})]}),Object(Hn.jsx)(Pi,{onClick:function(e){return r(e,t)},isRunning:g,isPrimary:!0,brandColor:u,label:b,style:{width:"100%",height:"40px"}})]}):Object(Hn.jsxs)("div",{className:"gh-portal-logged-out-form-container gh-portal-cancellation-form",children:[Object(Hn.jsxs)("p",{children:["If you cancel your subscription now, you will continue to have access until ",Object(Hn.jsx)("strong",{children:Object(Ui.a)(m.current_period_end)}),"."]}),Object(Hn.jsxs)("section",{className:"gh-portal-input-section",children:[Object(Hn.jsx)("div",{className:"gh-portal-input-labelcontainer",children:Object(Hn.jsx)("label",{className:"gh-portal-input-label",children:"Cancellation reason"})}),Object(Hn.jsx)("textarea",{className:"gh-portal-input",label:"Cancellation reason",type:"text",name:"cancellation_reason",placeholder:"",value:f,onChange:function(e){return h(e.target.value)},rows:"2",maxLength:"500"},"cancellation_reason")]}),Object(Hn.jsx)(Pi,{onClick:function(e){return r(e,f)},isRunning:g,isPrimary:!0,brandColor:u,label:b+" cancellation",style:{width:"100%",height:"40px"}})]})},Ro=function(e){var t=e.plans,n=e.selectedPlan,r=e.onPlanSelect,o=e.onCancelSubscription,a=Object(i.useContext)(Zn),l=a.member,s=a.action,c=a.brandColor;return Object(Hn.jsxs)("section",{children:[Object(Hn.jsx)("div",{className:"gh-portal-section gh-portal-accountplans-main",children:Object(Hn.jsx)(Uo,{showLabel:!1,plans:t,selectedPlan:n,onPlanSelect:r,changePlan:!0})}),Object(Hn.jsx)(Do,{member:l,onCancelSubscription:o,action:s,brandColor:c})]})};function Uo(e){e.showLabel,e.plans;var t=e.selectedPlan,n=e.onPlanSelect,r=e.onPlanCheckout,o=e.changePlan,a=void 0!==o&&o,l=Object(i.useContext)(Zn),s=l.site,c=l.member,u=Object(Lr.getUpgradeProducts)({site:s,member:c});return Object(Hn.jsx)(Lo,{products:u,selectedPlan:t,changePlan:a,onPlanSelect:n,onPlanCheckout:r})}var Ao=function(e){var t=e.plans,n=e.selectedPlan,r=e.onPlanSelect,i=e.onPlanCheckout,o="";return 1===t.length&&(o="singleplan"),Object(Hn.jsx)("section",{children:Object(Hn.jsx)("div",{className:"gh-portal-section gh-portal-accountplans-main ".concat(o),children:Object(Hn.jsx)(Uo,{showLabel:!1,plans:t,selectedPlan:n,onPlanSelect:r,onPlanCheckout:i})})})},Bo=function(e){var t=e.plans,n=e.selectedPlan,r=e.confirmationPlan,o=e.confirmationType,a=e.showConfirmation,l=void 0!==a&&a,s=e.onPlanSelect,c=e.onPlanCheckout,u=e.onConfirm,p=e.onCancelSubscription,d=Object(i.useContext)(Zn).member,f=Object(Lr.allowCompMemberUpgrade)({member:d})&&Object(Lr.isComplimentaryMember)({member:d});return!Object(Lr.isPaidMember)({member:d})||f?Object(Hn.jsx)(Ao,{plans:t,selectedPlan:n,onPlanSelect:s,onPlanCheckout:c}):l?Object(Hn.jsx)(zo,{plan:r,type:o,onConfirm:u}):Object(Hn.jsx)(Ro,{plans:t,selectedPlan:n,onCancelSubscription:p,onPlanSelect:s})},Ho=function(e){x(n,e);var t=O(n);function n(e,r){var i;return g(this,n),(i=t.call(this,e,r)).onPlanSelect=function(e,t){null===e||void 0===e||e.preventDefault();var n=i.context.member,r=!!Object(Lr.allowCompMemberUpgrade)({member:n})&&Object(Lr.isComplimentaryMember)({member:n});if(!Object(Lr.isPaidMember)({member:n})||r)i.timeoutId=setTimeout((function(){i.setState((function(){return{selectedPlan:t}}))}),5);else{var o=i.prices.find((function(e){return e.id===t})),a=i.getActivePriceId({member:n})?"changePlan":"subscribe";t!==i.state.selectedPlan&&i.setState({confirmationPlan:o,confirmationType:a,showConfirmation:!0})}},i.state=i.getInitialState(),i}return v(n,[{key:"componentDidMount",value:function(){this.context.member||this.context.onAction("switchPage",{page:"signin"})}},{key:"componentWillUnmount",value:function(){clearTimeout(this.timeoutId)}},{key:"getInitialState",value:function(){var e=this.context,t=e.member,n=e.site;this.prices=Object(Lr.getAvailablePrices)({site:n});var r=Object(Lr.getMemberActivePrice)({member:t});r&&(this.prices=Object(Lr.getFilteredPrices)({prices:this.prices,currency:r.currency}));var i=r?this.prices.find((function(e){return e.id===r.id})):null;return!Object(Lr.isPaidMember)({member:t})&&this.prices.length>0&&(i=this.prices[0]),{selectedPlan:i?i.id:null}}},{key:"handleSignout",value:function(e){e.preventDefault(),this.context.onAction("signout")}},{key:"onBack",value:function(e){this.state.showConfirmation?this.cancelConfirmPage():this.context.onAction("back")}},{key:"cancelConfirmPage",value:function(){this.setState({showConfirmation:!1,confirmationPlan:null,confirmationType:null})}},{key:"onPlanCheckout",value:function(e,t){var n=this.context,r=n.onAction,i=n.member,o=this.state,a=o.confirmationPlan,l=o.selectedPlan;t&&(l=t);var s=!Object(Lr.allowCompMemberUpgrade)({member:i})||!Object(Lr.isComplimentaryMember)({member:i});if(Object(Lr.isPaidMember)({member:i})&&s){var c=Object(Lr.getMemberSubscription)({member:i}),u=c?c.id:"";u&&r("updateSubscription",{plan:a.name,planId:a.id,subscriptionId:u,cancelAtPeriodEnd:!1})}else r("checkoutPlan",{plan:l})}},{key:"onCancelSubscription",value:function(e){var t=e.subscriptionId,n=(e.cancelAtPeriodEnd,this.context.member),r=Object(Lr.getSubscriptionFromId)({subscriptionId:t,member:n}),i=Object(Lr.getPriceFromSubscription)({subscription:r});this.setState({showConfirmation:!0,confirmationPlan:i,confirmationType:"cancel"})}},{key:"onCancelSubscriptionConfirmation",value:function(e){var t=this.context.member,n=Object(Lr.getMemberSubscription)({member:t});if(!n)return null;this.context.onAction("cancelSubscription",{subscriptionId:n.id,cancelAtPeriodEnd:!0,cancellationReason:e})}},{key:"getActivePriceId",value:function(e){var t=e.member,n=Object(Lr.getMemberActivePrice)({member:t});return n?n.id:null}},{key:"onConfirm",value:function(e,t){var n=this.state.confirmationType;return"cancel"===n?this.onCancelSubscriptionConfirmation(t):["changePlan","subscribe"].includes(n)?this.onPlanCheckout():void 0}},{key:"render",value:function(){var e=this,t=this.prices,n=this.state,r=n.selectedPlan,i=n.showConfirmation,o=n.confirmationPlan,a=n.confirmationType,l=this.context.lastPage;return Object(Hn.jsx)(Hn.Fragment,{children:Object(Hn.jsxs)("div",{className:"gh-portal-content",children:[Object(Hn.jsx)(Li,{onClick:function(t){return e.onBack(t)},hidden:!l&&!i}),Object(Hn.jsx)(Fi,{}),Object(Hn.jsx)(Fo,{onBack:function(t){return e.onBack(t)},confirmationType:a,showConfirmation:i}),Object(Hn.jsx)(Bo,{plans:t,selectedPlan:r,showConfirmation:i,confirmationPlan:o,confirmationType:a,onConfirm:function(){return e.onConfirm.apply(e,arguments)},onCancelSubscription:function(t){return e.onCancelSubscription(t)},onPlanSelect:this.onPlanSelect,onPlanCheckout:function(t,n){return e.onPlanCheckout(t,n)}})]})})}}]),n}(Mo.Component);Ho.contextType=Zn;function qo(e){var t=e.message,n=e.style;return t?Object(Hn.jsx)("p",{style:Object(k.a)({},n||{}),children:t}):null}var $o=function(e){var t=e.name,n=e.id,r=e.label,o=e.hideLabel,a=e.type,l=e.value,s=e.placeholder,c=e.disabled,u=void 0!==c&&c,p=e.onChange,d=void 0===p?function(){}:p,f=e.onBlur,h=void 0===f?function(){}:f,m=e.onKeyDown,g=void 0===m?function(){}:m,b=e.tabindex,v=e.maxlength,y=e.autoFocus,x=e.errorMessage,w=Object(i.useRef)(null);n=n||"input-".concat(t);var j=o?"gh-portal-input-label hidden":"gh-portal-input-label",O=x?"gh-portal-input error":"gh-portal-input";Object(Lr.isCookiesDisabled)()&&(u=!0),zr(["preview"])&&(u=!0);var k="",_="",S="";switch(n){case"input-email":k="off",_="off",S="off";break;case"input-name":k="off",_="off"}return Object(i.useEffect)((function(){y&&w.current.focus()}),[y]),Object(Hn.jsxs)("section",{className:"gh-portal-input-section",children:[Object(Hn.jsxs)("div",{className:"gh-portal-input-labelcontainer",children:[Object(Hn.jsxs)("label",{htmlFor:n,className:j,children:[" ",r," "]}),Object(Hn.jsx)(qo,{message:x,name:t})]}),Object(Hn.jsx)("input",{ref:w,id:n,className:O,type:a,name:t,value:l,placeholder:s,onChange:function(e){return d(e,t)},onKeyDown:function(e){return g(e,t)},onBlur:function(e){return h(e,t)},disabled:u,tabIndex:b,maxLength:v,autoComplete:k,autoCorrect:_,autoCapitalize:S,"aria-label":r})]})},Wo=n(11),Qo=function(e){x(n,e);var t=O(n);function n(){return g(this,n),t.apply(this,arguments)}return v(n,[{key:"render",value:function(){var e=this;return Object(Hn.jsx)(Hn.Fragment,{children:Object(Hn.jsxs)("button",{className:"gh-portal-btn gh-portal-btn-site-title-back",onClick:function(){e.props.onBack?e.props.onBack():e.context.onAction("closePopup")},children:[Object(Hn.jsx)("span",{children:"\u2190 "})," Back"]})})}}]),n}(o.a.Component);Qo.contextType=Zn;var Vo=["title","titleId"];function Yo(){return Yo=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(e[r]=n[r])}return e},Yo.apply(this,arguments)}function Ko(e,t){if(null==e)return{};var n,r,i=function(e,t){if(null==e)return{};var n,r,i={},o=Object.keys(e);for(r=0;r<o.length;r++)n=o[r],t.indexOf(n)>=0||(i[n]=e[n]);return i}(e,t);if(Object.getOwnPropertySymbols){var o=Object.getOwnPropertySymbols(e);for(r=0;r<o.length;r++)n=o[r],t.indexOf(n)>=0||Object.prototype.propertyIsEnumerable.call(e,n)&&(i[n]=e[n])}return i}function Go(e,t){var n=e.title,r=e.titleId,o=Ko(e,Vo);return i.createElement("svg",Yo({xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 16 16",ref:t,"aria-labelledby":r},o),n?i.createElement("title",{id:r},n):null,i.createElement("g",{transform:"matrix(0.6666666666666666,0,0,0.6666666666666666,0,0)"},i.createElement("path",{d:"M19.5,9.5h-.75V6.75a6.75,6.75,0,0,0-13.5,0V9.5H4.5a2,2,0,0,0-2,2V22a2,2,0,0,0,2,2h15a2,2,0,0,0,2-2V11.5A2,2,0,0,0,19.5,9.5Zm-7.5,9a2,2,0,1,1,2-2A2,2,0,0,1,12,18.5ZM16.25,9a.5.5,0,0,1-.5.5H8.25a.5.5,0,0,1-.5-.5V6.75a4.25,4.25,0,0,1,8.5,0Z",style:{fill:"#000000"}})))}var Jo=i.forwardRef(Go);n.p,n(1);function Xo(e){var t=e.newsletter,n=e.subscribedNewsletters,r=e.setSubscribedNewsletters,i=n.some((function(e){return e.id===(null===t||void 0===t?void 0:t.id)}));return t.paid?Object(Hn.jsxs)("section",{className:"gh-portal-list-toggle-wrapper",children:[Object(Hn.jsxs)("div",{className:"gh-portal-list-detail gh-portal-list-big",children:[Object(Hn.jsx)("h3",{children:t.name}),Object(Hn.jsx)("p",{children:t.description})]}),Object(Hn.jsx)("div",{class:"gh-portal-lock-icon-container",children:Object(Hn.jsx)(Jo,{className:"gh-portal-lock-icon",alt:"",title:"Unlock access to all newsletters by becoming a paid subscriber."})})]}):Object(Hn.jsxs)("section",{className:"gh-portal-list-toggle-wrapper",children:[Object(Hn.jsxs)("div",{className:"gh-portal-list-detail gh-portal-list-big",children:[Object(Hn.jsx)("h3",{children:t.name}),Object(Hn.jsx)("p",{children:t.description})]}),Object(Hn.jsx)("div",{children:Object(Hn.jsx)(Mi,{id:t.id,onToggle:function(e,i){var o=[];o=i?n.filter((function(e){return e.id!==t.id})).concat(t):n.filter((function(e){return e.id!==t.id})),r(o)},checked:i})})]})}function Zo(e){var t=e.subscribedNewsletters,n=e.setSubscribedNewsletters,r=Object(i.useContext)(Zn).site;return Object(Lr.getSiteNewsletters)({site:r}).map((function(e){return Object(Hn.jsx)(Xo,{newsletter:e,subscribedNewsletters:t,setSubscribedNewsletters:n},null===e||void 0===e?void 0:e.id)}))}function ea(e){var t=e.pageData,n=e.onBack,r=Object(i.useContext)(Zn),o=r.brandColor,a=r.site,l=r.onAction,c=r.action,u=Object(Lr.getSiteNewsletters)({site:a}).filter((function(e){return e.subscribe_on_signup})),p=!1;"signup:running"===c&&(p=!0);var d="Continue",f=!1;"signup:failed"===c&&(d="Retry",f=!0);var h="signup:running"===c,m=Object(i.useState)(u),g=Object(s.a)(m,2),b=g[0],v=g[1];return Object(Hn.jsxs)("div",{className:"gh-portal-content with-footer gh-portal-newsletter-selection",children:[Object(Hn.jsx)("p",{className:"gh-portal-text-center gh-portal-text-large",children:"Choose your newsletters"}),Object(Hn.jsx)("div",{className:"gh-portal-section",children:Object(Hn.jsx)("div",{className:"gh-portal-list",children:Object(Hn.jsx)(Zo,{subscribedNewsletters:b,setSubscribedNewsletters:v})})}),Object(Hn.jsx)("footer",{className:"gh-portal-action-footer",children:Object(Hn.jsxs)("div",{style:{width:"100%"},children:[Object(Hn.jsx)("div",{style:{marginBottom:"20px"},children:Object(Hn.jsx)(Pi,{isRunning:p,retry:f,disabled:h,onClick:function(e){var n=b.map((function(e){return{id:e.id}})),r=t.name,i=t.email,o=t.plan,a=t.offerId;l("signup",{name:r,email:i,plan:o,newsletters:n,offerId:a})},brandColor:o,label:d,style:{width:"100%"}})}),Object(Hn.jsx)("div",{children:Object(Hn.jsx)("button",{className:"gh-portal-btn gh-portal-btn-link gh-portal-btn-different-plan",onClick:function(){n()},children:Object(Hn.jsx)("span",{children:"Choose a different plan"})})})]})})]})}var ta,na,ra=function(e){var t=e.field,n=e.onChange,r=e.onBlur,i=void 0===r?function(){}:r,o=e.onKeyDown,a=void 0===o?function(){}:o;return t?Object(Hn.jsx)(Hn.Fragment,{children:Object(Hn.jsx)($o,{label:t.label,type:t.type,name:t.name,placeholder:t.placeholder,disabled:t.disabled,value:t.value,onKeyDown:a,onChange:function(e){return n(e,t)},onBlur:function(e){return i(e,t)},tabIndex:t.tabindex,errorMessage:t.errorMessage,autoFocus:t.autoFocus},t.name)}):null},ia=function(e){x(n,e);var t=O(n);function n(e){var r;return g(this,n),(r=t.call(this,e)).state={},r}return v(n,[{key:"render",value:function(){var e=this.props,t=e.fields,n=e.onChange,r=e.onBlur,i=e.onKeyDown,o=t.map((function(e){return Object(Hn.jsx)(ra,{field:e,onChange:n,onBlur:r,onKeyDown:i},e.name)}));return Object(Hn.jsx)(Hn.Fragment,{children:o})}}]),n}(i.Component),oa=function(e){var t,n=e.field;if(n.required&&!n.value)switch(n.name){case"name":return"Enter your name";case"email":return"Enter your email address";default:return"Please enter ".concat(n.name)}return"email"!==n.type||(t=n.value)&&/^[a-zA-Z0-9.!#$%&'*+/=?^_`{|}~-]+@[a-zA-Z0-9](?:[a-zA-Z0-9-]{0,61}[a-zA-Z0-9])?(?:\.[a-zA-Z0-9](?:[a-zA-Z0-9-]{0,61}[a-zA-Z0-9])?)*$/.test(String(t).toLowerCase())?null:"Invalid email address"},aa=function(e){var t=e.fields,n={};return t.forEach((function(e){var t=e.name,r=oa({field:e});n[t]=r})),n},la=["title","titleId"];function sa(){return sa=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(e[r]=n[r])}return e},sa.apply(this,arguments)}function ca(e,t){if(null==e)return{};var n,r,i=function(e,t){if(null==e)return{};var n,r,i={},o=Object.keys(e);for(r=0;r<o.length;r++)n=o[r],t.indexOf(n)>=0||(i[n]=e[n]);return i}(e,t);if(Object.getOwnPropertySymbols){var o=Object.getOwnPropertySymbols(e);for(r=0;r<o.length;r++)n=o[r],t.indexOf(n)>=0||Object.prototype.propertyIsEnumerable.call(e,n)&&(i[n]=e[n])}return i}function ua(e,t){var n=e.title,r=e.titleId,o=ca(e,la);return i.createElement("svg",sa({xmlns:"http://www.w3.org/2000/svg",width:24,height:24,viewBox:"0 0 24 24",ref:t,"aria-labelledby":r},o),n?i.createElement("title",{id:r},n):null,ta||(ta=i.createElement("defs",null,i.createElement("style",null,".inviteicon{fill: currentColor;}"))),na||(na=i.createElement("path",{className:"inviteicon",d:"M23.991 11.464l-.036-.146-.028-.068-.011-.027-.115-.114-.018-.021-.008-.005h-.001l-3.774-2.596v-7.987c0-.276-.224-.5-.5-.5h-15c-.276 0-.5.224-.5.5v7.987l-3.774 2.595-.003.002-.006.004-.015.016-.118.118-.011.027-.028.068-.036.146-.009.037v10.5c0 1.103.897 2 2 2h20c1.103 0 2-.897 2-2v-10.5l-.009-.036zm-1.383.03l-2.608 1.738v-3.531l2.608 1.793zm-18.608 1.738l-2.608-1.739 2.608-1.792v3.531zm18 9.768h-20c-.551 0-1-.449-1-1v-9.566l5.223 3.482c.085.057.181.084.276.084.162 0 .32-.078.417-.223.153-.23.091-.54-.139-.693l-1.777-1.185v-12.899h14v12.899l-1.777 1.185c-.23.153-.292.463-.139.693.096.145.255.223.416.223.095 0 .191-.027.277-.084l5.223-3.482v9.566c0 .551-.449 1-1 1zM15.812 16.109c-.088-.07-.198-.109-.312-.109h-7c-.114 0-.224.039-.312.109l-5 4c-.215.173-.25.487-.078.703.173.215.487.251.703.078l4.862-3.89h6.649l4.863 3.891c.093.073.203.109.313.109.147 0 .292-.065.391-.188.172-.216.137-.53-.078-.703l-5.001-4zM11.706 12.779c.087.064.191.096.294.096s.207-.032.294-.096c.482-.35 4.706-3.497 4.706-6.101 0-1.868-1.387-2.984-2.728-2.984-.772 0-1.674.379-2.272 1.368-.598-.988-1.5-1.368-2.272-1.368-1.341-.001-2.728 1.116-2.728 2.984 0 2.604 4.224 5.751 4.706 6.101zm-1.978-8.086c.844 0 1.511.681 1.786 1.822.108.45.864.45.973 0 .274-1.141.942-1.822 1.786-1.822.85 0 1.728.742 1.728 1.984 0 1.646-2.658 4.037-4 5.072-1.342-1.035-4-3.426-4-5.072-.001-1.241.877-1.984 1.727-1.984z"})))}var pa=i.forwardRef(ua),da=(n.p,n(1)),fa=function(e){x(n,e);var t=O(n);function n(e){var r;return g(this,n),(r=t.call(this,e)).handleSelectPlan=function(e,t){e&&e.preventDefault(),r.timeoutId=setTimeout((function(){r.setState((function(e){return{plan:t}}))}),5)},r.state={name:"",email:"",plan:"free",showNewsletterSelection:!1},r}return v(n,[{key:"componentDidMount",value:function(){this.context.member&&this.context.onAction("switchPage",{page:"accountHome"}),this.handleSelectedPlan()}},{key:"componentDidUpdate",value:function(){this.handleSelectedPlan()}},{key:"handleSelectedPlan",value:function(){var e=this.context,t=e.site,n=e.pageQuery,r=Object(Lr.getSitePrices)({site:t,pageQuery:n}),i=this.getSelectedPriceId(r,this.state.plan);i!==this.state.plan&&this.setState({plan:i})}},{key:"componentWillUnmount",value:function(){clearTimeout(this.timeoutId)}},{key:"handleSignup",value:function(e){var t=this,n=this.context,r=n.site,i=n.onAction;e.preventDefault(),this.setState((function(e){return{errors:aa({fields:t.getInputFields({state:e})})}}),(function(){var e=t.state,n=e.name,o=e.email,a=e.plan,l=e.errors;l&&Object.values(l).filter((function(e){return!!e})).length>0||(Object(Lr.hasMultipleNewsletters)({site:r})?t.setState({showNewsletterSelection:!0,pageData:{name:n,email:o,plan:a},errors:{}}):(t.setState({errors:{}}),i("signup",{name:n,email:o,plan:a})))}))}},{key:"handleChooseSignup",value:function(e,t){var n=this;e.preventDefault(),this.setState((function(e){return{errors:aa({fields:n.getInputFields({state:e})})}}),(function(){var e=n.context,r=e.onAction,i=e.site,o=n.state,a=o.name,l=o.email,s=o.errors;s&&Object.values(s).filter((function(e){return!!e})).length>0||(Object(Lr.hasMultipleNewsletters)({site:i})?n.setState({showNewsletterSelection:!0,pageData:{name:a,email:l,plan:t},errors:{}}):(r("signup",{name:a,email:l,plan:t}),n.setState({errors:{}})))}))}},{key:"handleInputChange",value:function(e,t){var n=t.name,r=e.target.value;this.setState(Object(Wo.a)({},n,r))}},{key:"onKeyDown",value:function(e){13===e.keyCode&&this.handleSignup(e)}},{key:"getSelectedPriceId",value:function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:[],t=arguments.length>1?arguments[1]:void 0;if(!e||0===e.length)return"free";var n=e.some((function(e){return e.id===t}));return n?t:e[0].id||"free"}},{key:"getInputFields",value:function(e){var t=e.state,n=e.fieldNames,r=this.context.site.portal_name,i=t.errors||{},o=[{type:"email",value:t.email,placeholder:"jamie@example.com",label:"Email",name:"email",required:!0,tabindex:2,errorMessage:i.email||""}];return r&&o.unshift({type:"text",value:t.name,placeholder:"Jamie Larson",label:"Name",name:"name",required:!0,tabindex:1,errorMessage:i.name||""}),o[0].autoFocus=!0,n&&n.length>0?o.filter((function(e){return n.includes(e.name)})):o}},{key:"renderSubmitButton",value:function(){var e=this,t=this.context,n=t.action,r=t.site,i=t.brandColor,o=t.pageQuery;if(Object(Lr.isInviteOnlySite)({site:r,pageQuery:o}))return null;var a="Continue",l="free"===o&&Object(Lr.hasFreeProductPrice)({site:r});if(!Object(Lr.hasOnlyFreePlan)({site:r})&&!l)return null;a="Sign up";var s=!1;"signup:running"===n&&(a="Sending...",s=!0);var c=!1;"signup:failed"===n&&(a="Retry",c=!0);var u="signup:running"===n;return Object(Hn.jsx)(Pi,{style:{width:"100%"},retry:c,onClick:function(t){return e.handleSignup(t)},disabled:u,brandColor:i,label:a,isRunning:s,tabIndex:"3"})}},{key:"renderProducts",value:function(){var e=this,t=this.context,n=t.site,r=t.pageQuery,i=Object(Lr.getSiteProducts)({site:n,pageQuery:r});return Object(Hn.jsx)(Hn.Fragment,{children:Object(Hn.jsx)(Io,{handleChooseSignup:function(){return e.handleChooseSignup.apply(e,arguments)},products:i,onPlanSelect:this.handleSelectPlan})})}},{key:"renderFreeTrialMessage",value:function(){var e=this.context.site;return Object(Lr.hasFreeTrialTier)({site:e})?Object(Hn.jsx)("p",{className:"gh-portal-free-trial-notification",children:"After a free trial ends, you will be charged regular price for the tier you\u2019ve chosen. You can always cancel before then."}):null}},{key:"renderLoginMessage",value:function(){var e=this.context,t=e.brandColor,n=e.onAction;return Object(Hn.jsxs)("div",{children:[this.renderFreeTrialMessage(),Object(Hn.jsxs)("div",{className:"gh-portal-signup-message",children:[Object(Hn.jsx)("div",{children:"Already a member?"}),Object(Hn.jsx)("button",{className:"gh-portal-btn gh-portal-btn-link",style:{color:t},onClick:function(){return n("switchPage",{page:"signin"})},children:Object(Hn.jsx)("span",{children:"Sign in"})})]})]})}},{key:"renderForm",value:function(){var e=this,t=this.getInputFields({state:this.state}),n=this.context,r=n.site,i=n.pageQuery;if(this.state.showNewsletterSelection)return Object(Hn.jsx)(ea,{pageData:this.state.pageData,onBack:function(){e.setState({showNewsletterSelection:!1})}});if(Object(Lr.isInviteOnlySite)({site:r,pageQuery:i}))return Object(Hn.jsx)("section",{children:Object(Hn.jsxs)("div",{className:"gh-portal-section",children:[Object(Hn.jsx)("p",{className:"gh-portal-invite-only-notification",children:"This site is invite-only, contact the owner for access."}),this.renderLoginMessage()]})});var o=Object(Lr.getFreeProductBenefits)({site:r}),a=Object(Lr.getFreeTierDescription)({site:r}),l="free"===i&&Object(Lr.hasFreeProductPrice)({site:r}),s=Object(Lr.hasOnlyFreeProduct)({site:r})||l,c=!l&&(o.length||a);return Object(Hn.jsx)("section",{className:"gh-portal-signup",children:Object(Hn.jsxs)("div",{className:"gh-portal-section",children:[Object(Hn.jsx)("div",{className:"gh-portal-logged-out-form-container",children:Object(Hn.jsx)(ia,{fields:t,onChange:function(t,n){return e.handleInputChange(t,n)},onKeyDown:function(t){return e.onKeyDown(t)}})}),Object(Hn.jsxs)("div",{children:[this.renderProducts(),s?Object(Hn.jsx)("div",{className:"gh-portal-btn-container"+(c?" sticky m24":""),children:Object(Hn.jsxs)("div",{className:"gh-portal-logged-out-form-container",children:[this.renderSubmitButton(),this.renderLoginMessage()]})}):this.renderLoginMessage()]})]})})}},{key:"renderSiteLogo",value:function(){var e=this.context,t=e.site,n=e.pageQuery,r=t.icon;return r?("url(".concat(r,")"),Object(Hn.jsx)("img",{className:"gh-portal-signup-logo",src:r,alt:t.title})):Object(Lr.isInviteOnlySite)({site:t,pageQuery:n})?Object(Hn.jsx)(pa,{className:"gh-portal-icon gh-portal-icon-invitation"}):null}},{key:"renderFormHeader",value:function(){var e=this.context.site.title||"";return Object(Hn.jsxs)("header",{className:"gh-portal-signup-header",children:[this.renderSiteLogo(),Object(Hn.jsx)("h1",{className:"gh-portal-main-title",children:e})]})}},{key:"getClassNames",value:function(){var e=this.context,t=e.site,n=e.pageQuery,r=Object(Lr.getSitePrices)({site:t,pageQuery:n}),i=this.getInputFields({state:this.state}),o="",a="";return(r.length<=1||Object(Lr.isInviteOnlySite)({site:t}))&&(1===r.length&&"free"===r[0].type||Object(Lr.isInviteOnlySite)({site:t,pageQuery:n})?(o=Object(Lr.freeHasBenefitsOrDescription)({site:t})?"singleplan":"noplan",1===i.length&&(o="single-field"),Object(Lr.isInviteOnlySite)({site:t})&&(a="invite-only",o="invite-only")):o="singleplan"),{sectionClass:o,footerClass:a}}},{key:"render",value:function(){var e=this,t=this.getClassNames().sectionClass;return Object(Hn.jsxs)(Hn.Fragment,{children:[Object(Hn.jsx)("div",{className:"gh-portal-back-sitetitle",children:Object(Hn.jsx)(Qo,{onBack:function(){e.state.showNewsletterSelection?e.setState({showNewsletterSelection:!1}):e.context.onAction("closePopup")}})}),Object(Hn.jsx)(Fi,{}),Object(Hn.jsxs)("div",{className:"gh-portal-content signup "+t,children:[this.renderFormHeader(),this.renderForm()]})]})}}]),n}(da.Component);fa.contextType=Zn;var ha,ma,ga,ba,va,ya=fa,xa=["title","titleId"];function wa(){return wa=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(e[r]=n[r])}return e},wa.apply(this,arguments)}function ja(e,t){if(null==e)return{};var n,r,i=function(e,t){if(null==e)return{};var n,r,i={},o=Object.keys(e);for(r=0;r<o.length;r++)n=o[r],t.indexOf(n)>=0||(i[n]=e[n]);return i}(e,t);if(Object.getOwnPropertySymbols){var o=Object.getOwnPropertySymbols(e);for(r=0;r<o.length;r++)n=o[r],t.indexOf(n)>=0||Object.prototype.propertyIsEnumerable.call(e,n)&&(i[n]=e[n])}return i}function Oa(e,t){var n=e.title,r=e.titleId,o=ja(e,xa);return i.createElement("svg",wa({xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24",ref:t,"aria-labelledby":r},o),n?i.createElement("title",{id:r},n):null,ha||(ha=i.createElement("defs",null,i.createElement("style",null,".a{fill:none;stroke:currentColor;stroke-linecap:round;stroke-linejoin:round;stroke-width:1px;}"))),ma||(ma=i.createElement("rect",{className:"a",x:.75,y:4.5,width:22.5,height:15,rx:1.5,ry:1.5})),ga||(ga=i.createElement("line",{className:"a",x1:15.687,y1:9.975,x2:19.5,y2:13.5})),ba||(ba=i.createElement("line",{className:"a",x1:8.313,y1:9.975,x2:4.5,y2:13.5})),va||(va=i.createElement("path",{className:"a",d:"M22.88,5.014l-9.513,6.56a2.406,2.406,0,0,1-2.734,0L1.12,5.014"})))}var ka=i.forwardRef(Oa),_a=(n.p,n(1)),Sa=function(e){x(n,e);var t=O(n);function n(){return g(this,n),t.apply(this,arguments)}return v(n,[{key:"renderFormHeader",value:function(){var e="We've sent you a login link!",t="If the email doesn't arrive in 3 minutes, be sure to check your spam folder!";return"signup"===this.context.lastPage&&(e="Now check your email!",t="To complete signup, click the confirmation link in your inbox. If it doesn\u2019t arrive within 3 minutes, check your spam folder!"),Object(Hn.jsxs)("section",{className:"gh-portal-inbox-notification",children:[Object(Hn.jsxs)("header",{className:"gh-portal-header",children:[Object(Hn.jsx)(ka,{className:"gh-portal-icon gh-portal-icon-envelope"}),Object(Hn.jsx)("h2",{className:"gh-portal-main-title",children:e})]}),Object(Hn.jsx)("p",{children:t})]})}},{key:"renderLoginMessage",value:function(){var e=this;return Object(Hn.jsx)(Hn.Fragment,{children:Object(Hn.jsx)("div",{style:{color:"#1d1d1d",fontWeight:"bold",cursor:"pointer"},onClick:function(){return e.context.onAction("switchPage",{page:"signin"})},children:"Back to Log in"})})}},{key:"handleClose",value:function(e){this.context.onAction("closePopup")}},{key:"renderCloseButton",value:function(){var e=this;return Object(Hn.jsx)(Pi,{style:{width:"100%"},onClick:function(t){return e.handleClose(t)},brandColor:this.context.brandColor,label:"Close"})}},{key:"render",value:function(){return Object(Hn.jsxs)("div",{className:"gh-portal-content",children:[Object(Hn.jsx)(Fi,{}),this.renderFormHeader(),this.renderCloseButton()]})}}]),n}(_a.Component);Sa.contextType=Zn;var Pa=function(e){var t=e.hide,n=void 0!==t&&t,r=e.onClose;return n?null:Object(Hn.jsx)(Jr,{className:"closeicon",alt:"Close",onClick:r})},Ea=function(e){var t=e.message,n=e.site,r=Object(Lr.getSupportAddress)({site:n}),i="mailto:".concat(r);return t?Object(Hn.jsx)("p",{children:t}):Object(Hn.jsxs)("p",{children:[" An unexpected error occured. Please try again or ",Object(Hn.jsx)("a",{href:i,onClick:function(){i&&window.open(i)},children:"contact support"})," if the error persists."]})},Ca=function(e){x(n,e);var t=O(n);function n(){var e;return g(this,n),(e=t.call(this)).state={className:""},e}return v(n,[{key:"onAnimationEnd",value:function(e){var t=(this.context.popupNotification||{}).type;"popupnotification-slideout"===e.animationName&&("stripe:billing-update"===t&&di(["stripe"]),this.context.onAction("clearPopupNotification"))}},{key:"closeNotification",value:function(e){this.context.onAction("clearPopupNotification")}},{key:"componentDidUpdate",value:function(){var e=this.context.popupNotification;e.count!==this.state.notificationCount&&(clearTimeout(this.timeoutId),this.handlePopupNotification({popupNotification:e}))}},{key:"handlePopupNotification",value:function(e){var t=this,n=e.popupNotification;if(this.setState({notificationCount:n.count}),n.autoHide){var r=n.duration,i=void 0===r?2600:r;this.timeoutId=setTimeout((function(){t.setState((function(e){return"slideout"!==e.className?{className:"slideout",notificationCount:n.count}:{}}))}),i)}}},{key:"componentDidMount",value:function(){var e=this.context.popupNotification;this.handlePopupNotification({popupNotification:e})}},{key:"componentWillUnmount",value:function(){clearTimeout(this.timeoutId)}},{key:"render",value:function(){var e=this,t=this.context,n=t.popupNotification,r=t.site,i=this.state.className,o=n.type,a=n.status,l=n.closeable,s=n.message,c=a?" ".concat(a):"",u=i?" ".concat(i):"";return Object(Hn.jsxs)("div",{className:"gh-portal-popupnotification".concat(c).concat(u),onAnimationEnd:function(t){return e.onAnimationEnd(t)},children:["error"===a?Object(Hn.jsx)(ci,{className:"gh-portal-popupnotification-icon error",alt:""}):Object(Hn.jsx)(ii,{className:"gh-portal-popupnotification-icon success",alt:""}),Object(Hn.jsx)(Ea,{type:o,status:a,message:s,site:r}),Object(Hn.jsx)(Pa,{hide:!l,onClose:function(t){return e.closeNotification(t)}})]})}}]),n}(o.a.Component);Ca.contextType=Zn;var Na=n(1),Ta=function(e){x(n,e);var t=O(n);function n(e,r){var i,o,a;return g(this,n),(a=t.call(this,e,r)).state={name:(null===r||void 0===r||null===(i=r.member)||void 0===i?void 0:i.name)||"",email:(null===r||void 0===r||null===(o=r.member)||void 0===o?void 0:o.email)||"",plan:"free",showNewsletterSelection:!1},a}return v(n,[{key:"getInputFields",value:function(e){var t=e.state,n=e.fieldNames,r=this.context.site.portal_name,i=this.context.member,o=t.errors||{},a=[{type:"email",value:(null===i||void 0===i?void 0:i.email)||t.email,placeholder:"jamie@example.com",label:"Email",name:"email",disabled:!!i,required:!0,tabindex:2,errorMessage:o.email||""}],l=!!r;return!i||null!==i&&void 0!==i&&i.name||(l=!1),l&&a.unshift({type:"text",value:(null===i||void 0===i?void 0:i.name)||t.name,placeholder:"Jamie Larson",label:"Name",name:"name",disabled:!!i,required:!0,tabindex:1,errorMessage:o.name||""}),a[0].autoFocus=!0,n&&n.length>0?a.filter((function(e){return n.includes(e.name)})):a}},{key:"onKeyDown",value:function(e){13===e.keyCode&&this.handleSignup(e)}},{key:"handleSignup",value:function(e){var t=this;e.preventDefault();var n=this.context,r=n.pageData,i=n.site;if(!r)return null;var o=Object(Lr.getProductFromId)({site:i,productId:r.tier.id}),a="month"===r.cadence?o.monthlyPrice:o.yearlyPrice;this.setState((function(e){return{errors:aa({fields:t.getInputFields({state:e})})}}),(function(){var e=t.context.onAction,n=t.state,o=n.name,l=n.email,s=n.errors;if(!(s&&Object.values(s).filter((function(e){return!!e})).length>0)){var c={name:o,email:l,plan:null===a||void 0===a?void 0:a.id,offerId:null===r||void 0===r?void 0:r.id};Object(Lr.hasMultipleNewsletters)({site:i})?t.setState({showNewsletterSelection:!0,pageData:c,errors:{}}):(e("signup",c),t.setState({errors:{}}))}}))}},{key:"handleInputChange",value:function(e,t){var n=t.name,r=e.target.value;this.setState(Object(Wo.a)({},n,r))}},{key:"renderSiteLogo",value:function(){var e=this.context.site,t=e.icon;return t?("url(".concat(t,")"),Object(Hn.jsx)("img",{className:"gh-portal-signup-logo",src:t,alt:e.title})):null}},{key:"renderFormHeader",value:function(){var e=this.context.site.title||"";return Object(Hn.jsxs)("header",{className:"gh-portal-signup-header",children:[this.renderSiteLogo(),Object(Hn.jsx)("h2",{className:"gh-portal-main-title",children:e})]})}},{key:"renderForm",value:function(){var e=this,t=this.getInputFields({state:this.state});return this.state.showNewsletterSelection?Object(Hn.jsx)(ea,{pageData:this.state.pageData,onBack:function(){e.setState({showNewsletterSelection:!1})}}):Object(Hn.jsx)("section",{children:Object(Hn.jsx)("div",{className:"gh-portal-section",children:Object(Hn.jsx)(ia,{fields:t,onChange:function(t,n){return e.handleInputChange(t,n)},onKeyDown:function(t){return e.onKeyDown(t)}})})})}},{key:"renderSubmitButton",value:function(){var e=this,t=this.context,n=t.action,r=t.brandColor,i=this.context.pageData,o="Continue";"trial"===i.type&&(o="Start "+i.amount+"-day free trial");var a=!1;"signup:running"===n&&(o="Sending...",a=!0);var l=!1;"signup:failed"===n&&(o="Retry",l=!0);var s="signup:running"===n;return Object(Hn.jsx)(Pi,{style:{width:"100%"},retry:l,onClick:function(t){return e.handleSignup(t)},disabled:s,brandColor:r,label:o,isRunning:a,tabindex:"3",classes:"sticky bottom"})}},{key:"renderLoginMessage",value:function(){if(this.context.member)return null;var e=this.context,t=e.brandColor,n=e.onAction;return Object(Hn.jsxs)("div",{className:"gh-portal-signup-message",children:[Object(Hn.jsx)("div",{children:"Already a member?"}),Object(Hn.jsx)("button",{className:"gh-portal-btn gh-portal-btn-link",style:{color:t},onClick:function(){return n("switchPage",{page:"signin"})},children:Object(Hn.jsx)("span",{children:"Sign in"})})]})}},{key:"renderOfferTag",value:function(){var e=this.context.pageData;return e.amount<=0?Object(Hn.jsx)(Hn.Fragment,{}):"fixed"===e.type?Object(Hn.jsxs)("h5",{className:"gh-portal-discount-label",children:[Object(Lr.getCurrencySymbol)(e.currency),e.amount/100," off"]}):"trial"===e.type?Object(Hn.jsxs)("h5",{className:"gh-portal-discount-label",children:[e.amount," days free"]}):Object(Hn.jsxs)("h5",{className:"gh-portal-discount-label",children:[e.amount,"% off"]})}},{key:"renderBenefits",value:function(e){var t=e.product.benefits||[];if(null!==t&&void 0!==t&&t.length){var n=t.map((function(e,t){return Object(Hn.jsxs)("div",{className:"gh-portal-product-benefit",children:[Object(Hn.jsx)(fo,{className:"gh-portal-benefit-checkmark"}),Object(Hn.jsx)("div",{className:"gh-portal-benefit-title",children:e.name})]},"".concat(e.name,"-").concat(t))}));return Object(Hn.jsx)("div",{className:"gh-portal-product-benefits",children:n})}}},{key:"getOriginalPrice",value:function(e){var t=e.offer,n=e.product,r="month"===t.cadence?n.monthlyPrice:n.yearlyPrice,i=this.renderRoundedPrice(r.amount/100);return"".concat(Object(Lr.getCurrencySymbol)(r.currency)).concat(i,"/").concat(t.cadence)}},{key:"getUpdatedPrice",value:function(e){var t,n=e.offer,r=e.product,i="month"===n.cadence?r.monthlyPrice:r.yearlyPrice,o=i.amount;return"fixed"===n.type&&Object(Lr.isSameCurrency)(n.currency,i.currency)?(t=(o-n.amount)/100)>0?t:0:"percent"===n.type?t=(o-o*n.amount/100)/100:o/100}},{key:"renderRoundedPrice",value:function(e){if(e%1!==0){var t=Math.round(100*e)/100;return Number(t).toFixed(2)}return e}},{key:"getOffAmount",value:function(e){var t=e.offer;return"fixed"===t.type?"".concat(Object(Lr.getCurrencySymbol)(t.currency)).concat(t.amount/100):"percent"===t.type?"".concat(t.amount,"%"):"trial"===t.type?t.amount:""}},{key:"renderOfferMessage",value:function(e){var t=e.offer,n=e.product,r=(e.price,t.duration),i="",o=this.getOriginalPrice({offer:t,product:n}),a="";if("once"===r)i="for first ".concat(t.cadence),a="Renews at ".concat(o,".");else if("forever"===r)i="forever";else if("repeating"===r){var l=t.duration_in_months||"";i=1===l?"for first month":"for first ".concat(l," months"),a="Renews at ".concat(o,".")}return"trial"===r?Object(Hn.jsxs)("p",{className:"footnote",children:["Try free for ",t.amount," days, then ",o,". ",Object(Hn.jsx)("span",{class:"gh-portal-cancel",children:"Cancel anytime."})]}):Object(Hn.jsxs)("p",{className:"footnote",children:[this.getOffAmount({offer:t})," off ",i,". ",a]})}},{key:"renderProductLabel",value:function(e){var t=e.product,n=e.offer,r=this.context.site;return Object(Lr.hasMultipleProductsFeature)({site:r})?Object(Hn.jsxs)("h4",{className:"gh-portal-plan-name",children:[t.name," - ","month"===n.cadence?"Monthly":"Yearly"]}):Object(Hn.jsx)("h4",{className:"gh-portal-plan-name",children:"month"===n.cadence?"Monthly":"Yearly"})}},{key:"renderUpdatedTierPrice",value:function(e){var t=e.offer,n=e.currencyClass,r=e.updatedPrice,i=e.price;return"trial"===t.type?Object(Hn.jsx)("div",{className:"gh-portal-product-card-pricecontainer offer-type-trial",children:Object(Hn.jsxs)("div",{className:"gh-portal-product-price",children:[Object(Hn.jsx)("span",{className:"currency-sign "+n,children:Object(Lr.getCurrencySymbol)(i.currency)}),Object(Hn.jsx)("span",{className:"amount",children:Object(Lr.formatNumber)(this.renderRoundedPrice(r))})]})}):Object(Hn.jsx)("div",{className:"gh-portal-product-card-pricecontainer",children:Object(Hn.jsxs)("div",{className:"gh-portal-product-price",children:[Object(Hn.jsx)("span",{className:"currency-sign "+n,children:Object(Lr.getCurrencySymbol)(i.currency)}),Object(Hn.jsx)("span",{className:"amount",children:Object(Lr.formatNumber)(this.renderRoundedPrice(r))})]})})}},{key:"renderOldTierPrice",value:function(e){var t=e.offer,n=e.price;return"trial"===t.type?null:Object(Hn.jsxs)("div",{className:"gh-portal-offer-oldprice",children:[Object(Lr.getCurrencySymbol)(n.currency)," ",Object(Lr.formatNumber)(n.amount/100)]})}},{key:"renderProductCard",value:function(e){var t=e.product,n=e.offer,r=e.currencyClass,i=e.updatedPrice,o=e.price,a=e.benefits;return this.state.showNewsletterSelection?null:Object(Hn.jsxs)(Hn.Fragment,{children:[Object(Hn.jsx)("div",{className:"gh-portal-product-card top",children:Object(Hn.jsxs)("div",{className:"gh-portal-product-card-header",children:[Object(Hn.jsxs)("h4",{className:"gh-portal-product-name",children:[t.name," - ","month"===n.cadence?"Monthly":"Yearly"]}),this.renderOldTierPrice({offer:n,price:o}),this.renderUpdatedTierPrice({offer:n,currencyClass:r,updatedPrice:i,price:o}),this.renderOfferMessage({offer:n,product:t,price:o})]})}),Object(Hn.jsxs)("div",{children:[Object(Hn.jsx)("div",{className:"gh-portal-product-card bottom",children:Object(Hn.jsxs)("div",{className:"gh-portal-product-card-detaildata",children:[t.description?Object(Hn.jsx)("div",{className:"gh-portal-product-description",children:t.description}):"",a.length?this.renderBenefits({product:t}):""]})}),Object(Hn.jsx)("div",{className:"gh-portal-btn-container sticky m32",children:this.renderSubmitButton()}),this.renderLoginMessage()]})]})}},{key:"render",value:function(){var e=this.context,t=e.pageData,n=e.site;if(!t)return null;var r=Object(Lr.getProductFromId)({site:n,productId:t.tier.id}),i="month"===t.cadence?r.monthlyPrice:r.yearlyPrice,o=this.getUpdatedPrice({offer:t,product:r}),a=r.benefits||[],l=Object(Lr.getCurrencySymbol)(i.currency).length>1?"long":"";return Object(Hn.jsx)(Hn.Fragment,{children:Object(Hn.jsxs)("div",{className:"gh-portal-content gh-portal-offer",children:[Object(Hn.jsx)(Fi,{}),this.renderFormHeader(),Object(Hn.jsxs)("div",{className:"gh-portal-offer-bar",children:[Object(Hn.jsxs)("div",{className:"gh-portal-offer-title",children:[t.display_title?Object(Hn.jsx)("h4",{children:t.display_title}):Object(Hn.jsx)("h4",{className:"placeholder",children:"Black Friday"}),this.renderOfferTag()]}),t.display_description?Object(Hn.jsx)("p",{children:t.display_description}):""]}),this.renderForm(),this.renderProductCard({product:r,offer:t,currencyClass:l,updatedPrice:o,price:i,benefits:a})]})})}}]),n}(Na.Component);Ta.contextType=Zn;var Ia=function(e){x(n,e);var t=O(n);function n(e){var r;return g(this,n),(r=t.call(this,e)).state={email:""},r}return v(n,[{key:"componentDidMount",value:function(){this.context.member&&this.context.onAction("switchPage",{page:"accountHome"})}},{key:"handleSignin",value:function(e){var t=this;e.preventDefault(),this.setState((function(e){return{errors:aa({fields:t.getInputFields({state:e})})}}),(function(){var e=t.state,n=e.email,r=e.errors;r&&Object.values(r).filter((function(e){return!!e})).length>0||t.context.onAction("signin",{email:n})}))}},{key:"handleInputChange",value:function(e,t){var n=t.name;this.setState(Object(Wo.a)({},n,e.target.value))}},{key:"onKeyDown",value:function(e){13===e.keyCode&&this.handleSignin(e)}},{key:"getInputFields",value:function(e){var t=e.state,n=t.errors||{};return[{type:"email",value:t.email,placeholder:"jamie@example.com",label:"Email",name:"email",required:!0,errorMessage:n.email||"",autoFocus:!0}]}},{key:"renderSubmitButton",value:function(){var e=this,t=this.context.action,n=!1,r="signin:running"===t,i=r?"Sending login link...":"Continue",o=!!r;return"signin:failed"===t&&(i="Retry",n=!0),Object(Hn.jsx)(Pi,{retry:n,style:{width:"100%"},onClick:function(t){return e.handleSignin(t)},disabled:o,brandColor:this.context.brandColor,label:i,isRunning:r})}},{key:"renderSignupMessage",value:function(){var e=this,t=this.context.brandColor;return Object(Hn.jsxs)("div",{className:"gh-portal-signup-message",children:[Object(Hn.jsx)("div",{children:"Don't have an account?"}),Object(Hn.jsx)("button",{className:"gh-portal-btn gh-portal-btn-link",style:{color:t},onClick:function(){return e.context.onAction("switchPage",{page:"signup"})},children:Object(Hn.jsx)("span",{children:"Sign up"})})]})}},{key:"renderForm",value:function(){var e=this;return Object(Hn.jsx)("section",{children:Object(Hn.jsx)("div",{className:"gh-portal-section",children:Object(Hn.jsx)(ia,{fields:this.getInputFields({state:this.state}),onChange:function(t,n){return e.handleInputChange(t,n)},onKeyDown:function(t,n){return e.onKeyDown(t,n)}})})})}},{key:"renderSiteLogo",value:function(){var e=this.context.site.icon;return e?("url(".concat(e,")"),Object(Hn.jsx)("img",{className:"gh-portal-signup-logo",src:e,alt:this.context.site.title})):null}},{key:"renderFormHeader",value:function(){return Object(Hn.jsxs)("header",{className:"gh-portal-signin-header",children:[this.renderSiteLogo(),Object(Hn.jsx)("h1",{className:"gh-portal-main-title",children:"Sign in"})]})}},{key:"render",value:function(){return Object(Hn.jsxs)(Hn.Fragment,{children:[Object(Hn.jsx)(Fi,{}),Object(Hn.jsxs)("div",{className:"gh-portal-logged-out-form-container",children:[Object(Hn.jsxs)("div",{className:"gh-portal-content signin",children:[this.renderFormHeader(),this.renderForm()]}),Object(Hn.jsxs)("footer",{className:"gh-portal-signin-footer",children:[this.renderSubmitButton(),this.renderSignupMessage()]})]})]})}}]),n}(n(1).Component);Ia.contextType=Zn;var La=function(e){x(n,e);var t=O(n);function n(){return g(this,n),t.apply(this,arguments)}return v(n,[{key:"render",value:function(){return Object(Hn.jsx)("div",{style:{display:"flex",flexDirection:"column",color:"#313131"},children:Object(Hn.jsx)("div",{style:{paddingLeft:"16px",paddingRight:"16px",paddingTop:"12px",height:"50px"},children:Object(Hn.jsx)(ki,{className:"gh-portal-loadingicon dark"})})})}}]),n}(n(1).Component),Ma=function(e){x(n,e);var t=O(n);function n(e,r){var i;g(this,n),i=t.call(this,e,r);var o=r.member||{},a=o.name,l=void 0===a?"":a,s=o.email,c=void 0===s?"":s;return i.state={name:l,email:c},i}return v(n,[{key:"componentDidMount",value:function(){this.context.member||this.context.onAction("switchPage",{page:"signin"})}},{key:"handleSignout",value:function(e){e.preventDefault(),this.context.onAction("signout")}},{key:"onBack",value:function(e){this.context.onAction("back")}},{key:"onProfileSave",value:function(e){var t=this;e.preventDefault(),this.setState((function(e){return{errors:aa({fields:t.getInputFields({state:e})})}}),(function(){var e=t.state,n=e.email,r=e.name,i=e.errors;i&&Object.values(i).filter((function(e){return!!e})).length>0||(t.context.onAction("clearPopupNotification"),t.context.onAction("updateProfile",{email:n,name:r}))}))}},{key:"renderSaveButton",value:function(){var e=this,t="updateProfile:running"===this.context.action,n="Save";"updateProfile:failed"===this.context.action&&(n="Retry");var r=!!t;return Object(Hn.jsx)(Pi,{isRunning:t,onClick:function(t){return e.onProfileSave(t)},disabled:r,brandColor:this.context.brandColor,label:n,style:{width:"100%"}})}},{key:"renderDeleteAccountButton",value:function(){return Object(Hn.jsx)("div",{style:{cursor:"pointer",color:"red"},role:"button",children:"Delete account"})}},{key:"renderAccountFooter",value:function(){return Object(Hn.jsx)("footer",{className:"gh-portal-action-footer",children:this.renderSaveButton()})}},{key:"renderHeader",value:function(){var e=this;return Object(Hn.jsxs)("header",{className:"gh-portal-detail-header",children:[Object(Hn.jsx)(Li,{brandColor:this.context.brandColor,hidden:!this.context.lastPage,onClick:function(t){return e.onBack(t)}}),Object(Hn.jsx)("h3",{className:"gh-portal-main-title",children:"Account settings"})]})}},{key:"renderUserAvatar",value:function(){var e=this.context.member&&this.context.member.avatar_image;return Object(Hn.jsx)("div",{style:{position:"relative",display:"flex",width:"64px",height:"64px",marginBottom:"6px",borderRadius:"100%",boxShadow:"0 0 0 3px #fff",border:"1px solid gray",overflow:"hidden",justifyContent:"center",alignItems:"center"},children:Object(Hn.jsx)(Xn,{gravatar:e,style:{userIcon:{color:"black",width:"56px",height:"56px"}}})})}},{key:"handleInputChange",value:function(e,t){var n=t.name;this.setState(Object(Wo.a)({},n,e.target.value))}},{key:"getInputFields",value:function(e){var t=e.state,n=e.fieldNames,r=t.errors||{},i=[{type:"text",value:t.name,placeholder:"Jamie Larson",label:"Name",name:"name",required:!0,errorMessage:r.name||""},{type:"email",value:t.email,placeholder:"jamie@example.com",label:"Email",name:"email",required:!0,errorMessage:r.email||""}];return n&&n.length>0?i.filter((function(e){return n.includes(e.name)})):i}},{key:"onKeyDown",value:function(e){13===e.keyCode&&this.onProfileSave(e)}},{key:"renderProfileData",value:function(){var e=this;return Object(Hn.jsx)("div",{className:"gh-portal-section",children:Object(Hn.jsx)(ia,{fields:this.getInputFields({state:this.state}),onChange:function(t,n){return e.handleInputChange(t,n)},onKeyDown:function(t,n){return e.onKeyDown(t,n)}})})}},{key:"render",value:function(){return this.context.member?Object(Hn.jsxs)(Hn.Fragment,{children:[Object(Hn.jsxs)("div",{className:"gh-portal-content with-footer",children:[Object(Hn.jsx)(Fi,{}),this.renderHeader(),Object(Hn.jsx)("div",{className:"gh-portal-section",children:this.renderProfileData()})]}),this.renderAccountFooter()]}):null}}]),n}(n(1).Component);Ma.contextType=Zn;var Fa,Da,za,Ra=n(15);function Ua(e){return function(e){if(Array.isArray(e))return Object(Ra.a)(e)}(e)||function(e){if("undefined"!==typeof Symbol&&null!=e[Symbol.iterator]||null!=e["@@iterator"])return Array.from(e)}(e)||Object(c.a)(e)||function(){throw new TypeError("Invalid attempt to spread non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}()}var Aa=["title","titleId"];function Ba(){return Ba=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(e[r]=n[r])}return e},Ba.apply(this,arguments)}function Ha(e,t){if(null==e)return{};var n,r,i=function(e,t){if(null==e)return{};var n,r,i={},o=Object.keys(e);for(r=0;r<o.length;r++)n=o[r],t.indexOf(n)>=0||(i[n]=e[n]);return i}(e,t);if(Object.getOwnPropertySymbols){var o=Object.getOwnPropertySymbols(e);for(r=0;r<o.length;r++)n=o[r],t.indexOf(n)>=0||Object.prototype.propertyIsEnumerable.call(e,n)&&(i[n]=e[n])}return i}function qa(e,t){var n=e.title,r=e.titleId,o=Ha(e,Aa);return i.createElement("svg",Ba({xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24",ref:t,"aria-labelledby":r},o),Fa||(Fa=i.createElement("defs",null,i.createElement("style",null,".a{fill:none;stroke:currentColor;stroke-linecap:round;stroke-linejoin:round;stroke-width:1.5px!important;}\n "))),void 0===n?i.createElement("title",{id:r},"check-circle-1"):n?i.createElement("title",{id:r},n):null,Da||(Da=i.createElement("path",{className:"a",d:"M6,13.223,8.45,16.7a1.049,1.049,0,0,0,1.707.051L18,6.828"})),za||(za=i.createElement("circle",{className:"a",cx:12,cy:11.999,r:11.25})))}var $a=i.forwardRef(qa);n.p,n(1);function Wa(){var e=Object(i.useContext)(Zn),t=e.brandColor,n=e.lastPage,r=e.onAction;return Object(Hn.jsxs)("header",{className:"gh-portal-detail-header",children:[Object(Hn.jsx)(Li,{brandColor:t,hidden:!n,onClick:function(e){r("back")}}),Object(Hn.jsx)("h3",{className:"gh-portal-main-title",children:"Email preferences"})]})}function Qa(e){var t=e.show,n=e.checked,r=[];return t&&r.push("gh-portal-checkmark-show"),n&&r.push("gh-portal-toggle-checked"),r.push("gh-portal-checkmark-container"),Object(Hn.jsx)("div",{className:r.join(" "),children:Object(Hn.jsx)($a,{className:"gh-portal-checkmark-icon",alt:""})})}function Va(e){var t=e.newsletter,n=e.subscribedNewsletters,r=e.setSubscribedNewsletters,o=n.some((function(e){return e.id===(null===t||void 0===t?void 0:t.id)})),a=Object(i.useState)(!1),l=Object(s.a)(a,2),c=l[0],u=l[1],p=Object(i.useState)(null),d=Object(s.a)(p,2),f=d[0],h=d[1];return Object(Hn.jsxs)("section",{className:"gh-portal-list-toggle-wrapper",children:[Object(Hn.jsxs)("div",{className:"gh-portal-list-detail",children:[Object(Hn.jsx)("h3",{children:t.name}),Object(Hn.jsx)("p",{children:null===t||void 0===t?void 0:t.description})]}),Object(Hn.jsxs)("div",{style:{display:"flex",alignItems:"center"},children:[Object(Hn.jsx)(Qa,{show:c,checked:o}),Object(Hn.jsx)(Mi,{id:t.id,onToggle:function(e,i){var o=[];if(i){o=n.filter((function(e){return e.id!==t.id})).concat(t),u(!0),clearTimeout(f);var a=setTimeout((function(){u(!1)}),2e3);h(a)}else{o=n.filter((function(e){return e.id!==t.id})),u(!0),clearTimeout(f);var l=setTimeout((function(){u(!1)}),2e3);h(l)}r(o)},checked:o})]})]})}function Ya(e){var t=e.updateCommentNotifications,n=e.isCommentsEnabled,r=!!e.enableCommentNotifications,o=Object(i.useState)(!1),a=Object(s.a)(o,2),l=a[0],c=a[1],u=Object(i.useState)(null),p=Object(s.a)(u,2),d=p[0],f=p[1];return n?Object(Hn.jsxs)("section",{className:"gh-portal-list-toggle-wrapper",children:[Object(Hn.jsxs)("div",{className:"gh-portal-list-detail",children:[Object(Hn.jsx)("h3",{children:"Comments"}),Object(Hn.jsx)("p",{children:"Get notified when someone replies to your comment"})]}),Object(Hn.jsxs)("div",{style:{display:"flex",alignItems:"center"},children:[Object(Hn.jsx)(Qa,{show:l,checked:r}),Object(Hn.jsx)(Mi,{id:"comments",onToggle:function(e,n){c(!0),clearTimeout(d);var r=setTimeout((function(){c(!1)}),2e3);f(r),t(n)},checked:r})]})]}):null}function Ka(e){var t=e.subscribedNewsletters,n=e.setSubscribedNewsletters,r=Object(i.useContext)(Zn).site;return Object(Lr.getSiteNewsletters)({site:r}).map((function(e){return Object(Hn.jsx)(Va,{newsletter:e,subscribedNewsletters:t,setSubscribedNewsletters:n},null===e||void 0===e?void 0:e.id)}))}function Ga(e){var t=e.site;return e.isPaid?Object(Hn.jsxs)("p",{style:{textAlign:"center",marginTop:"12px",marginBottom:"0",color:"var(--grey6)"},children:["Unsubscribing from emails will not cancel your paid subscription to ",null===t||void 0===t?void 0:t.title]}):null}function Ja(e){var t=e.notification,n=e.subscribedNewsletters,r=e.updateSubscribedNewsletters,o=e.updateCommentNotifications,a=e.unsubscribeAll,l=e.isPaidMember,s=e.isCommentsEnabled,c=e.enableCommentNotifications,u=Object(i.useContext)(Zn),p=u.brandColor,d=u.site,f=!(null!==n&&void 0!==n&&n.length)&&(s&&!c||!s),h=t||function(){return null};return Object(Hn.jsxs)("div",{className:"gh-portal-content with-footer",children:[Object(Hn.jsx)(Fi,{}),Object(Hn.jsx)(Wa,{}),Object(Hn.jsx)(h,{}),Object(Hn.jsx)("div",{className:"gh-portal-section",children:Object(Hn.jsxs)("div",{className:"gh-portal-list",children:[Object(Hn.jsx)(Ka,{subscribedNewsletters:n,setSubscribedNewsletters:function(e){var t=e.map((function(e){return{id:e.id}}));r(t)}}),Object(Hn.jsx)(Ya,{isCommentsEnabled:s,enableCommentNotifications:c,updateCommentNotifications:o})]})}),Object(Hn.jsx)("footer",{className:"gh-portal-action-footer",children:Object(Hn.jsxs)("div",{style:{width:"100%"},children:[Object(Hn.jsx)(Pi,{isRunning:!1,onClick:function(e){a()},disabled:f,brandColor:p,isPrimary:!1,label:"Unsubscribe from all emails",isDestructive:!0,style:{width:"100%"}}),Object(Hn.jsx)(Ga,{isPaid:l,site:d})]})})]})}n(1);var Xa=function(e){var t=e.siteUrl,n=void 0===t?window.location.origin:t,r=e.apiUrl,i=e.apiKey;function o(e){var t=e.type,r=e.resource;if("members"===t)return"".concat(n.replace(/\/$/,""),"/").concat("members/api","/").concat(r,"/")}function a(e){var t=e.resource,n=e.params,o=void 0===n?"":n;return r&&i?"".concat(r.replace(/\/$/,""),"/").concat(t,"/?key=").concat(i,"&limit=all").concat(o):""}function l(e){var t=e.url,n=e.method,r=void 0===n?"GET":n,i=e.headers,o=void 0===i?{}:i,a=e.credentials,l=void 0===a?void 0:a,s=e.body;return fetch(t,{method:r,headers:o,credentials:l,body:void 0===s?void 0:s})}var c={};return c.analytics={pushEvent:function(e){return m(f().mark((function t(){var n,r,i;return f().wrap((function(t){for(;;)switch(t.prev=t.next){case 0:return n=o({type:"members",resource:"events"}),t.next=3,c.member.identity();case 3:return r=t.sent,e.identity=r,i={events:[e]},t.abrupt("return",l({url:n,method:"POST",headers:{"Content-Type":"application/json"},body:JSON.stringify(i)}).then((function(e){return e.ok?e.text():null})));case 7:case"end":return t.stop()}}),t)})))()}},c.site={read:function(){return l({url:o({type:"members",resource:"site"}),method:"GET",headers:{"Content-Type":"application/json"}}).then((function(e){if(e.ok)return e.json();throw new Error("Failed to fetch site data")}))},newsletters:function(){return l({url:a({resource:"newsletters"}),method:"GET",headers:{"Content-Type":"application/json"}}).then((function(e){if(e.ok)return e.json();throw new Error("Failed to fetch site data")}))},tiers:function(){return l({url:a({resource:"tiers",params:"&include=monthly_price,yearly_price,benefits"}),method:"GET",headers:{"Content-Type":"application/json"}}).then((function(e){if(e.ok)return e.json();throw new Error("Failed to fetch site data")}))},settings:function(){return l({url:a({resource:"settings"}),method:"GET",headers:{"Content-Type":"application/json"}}).then((function(e){if(e.ok)return e.json();throw new Error("Failed to fetch site data")}))},offer:function(e){var t=e.offerId;return l({url:a({resource:"offers/".concat(t)}),method:"GET",headers:{"Content-Type":"application/json"}}).then((function(e){if(e.ok)return e.json();throw new Error("Failed to fetch offer data")}))}},c.member={identity:function(){return l({url:o({type:"members",resource:"session"}),credentials:"same-origin"}).then((function(e){return e.ok&&204!==e.status?e.text():null}))},sessionData:function(){return l({url:o({type:"members",resource:"member"}),credentials:"same-origin"}).then((function(e){return e.ok&&204!==e.status?e.json():null}))},update:function(e){var t=e.name,n=e.subscribed,r=e.newsletters,i=e.enableCommentNotifications,a=o({type:"members",resource:"member"}),s={name:t,subscribed:n,newsletters:r};return void 0!==i&&(s.enable_comment_notifications=i),l({url:a,method:"PUT",headers:{"Content-Type":"application/json"},credentials:"same-origin",body:JSON.stringify(s)}).then((function(e){return e.ok?e.json():null}))},sendMagicLink:function(e){var t=e.email,n=e.emailType,r=e.labels,i=e.name,a=e.oldEmail,s=e.newsletters,c=o({type:"members",resource:"send-magic-link"}),u={name:i,email:t,newsletters:s,oldEmail:a,emailType:n,labels:r,requestSrc:"portal"},p=Object(Lr.getUrlHistory)();return p&&(u.urlHistory=p),l({url:c,method:"POST",headers:{"Content-Type":"application/json"},body:JSON.stringify(u)}).then((function(e){if(e.ok)return"Success";throw new Error("Failed to send magic link email")}))},signout:function(){return l({url:o({type:"members",resource:"session"}),method:"DELETE"}).then((function(e){if(e.ok)return window.location.replace(n),"Success";throw new Error("Failed to signout")}))},newsletters:function(e){return m(f().mark((function t(){var n,r;return f().wrap((function(t){for(;;)switch(t.prev=t.next){case 0:return n=e.uuid,r=o({type:"members",resource:"member/newsletters"}),r+="?uuid=".concat(n),t.abrupt("return",l({url:r,credentials:"same-origin"}).then((function(e){return e.ok&&204!==e.status?e.json():null})));case 4:case"end":return t.stop()}}),t)})))()},updateNewsletters:function(e){return m(f().mark((function t(){var n,r,i,a,s;return f().wrap((function(t){for(;;)switch(t.prev=t.next){case 0:return n=e.uuid,r=e.newsletters,i=e.enableCommentNotifications,a=o({type:"members",resource:"member/newsletters"}),a+="?uuid=".concat(n),s={newsletters:r},void 0!==i&&(s.enable_comment_notifications=i),t.abrupt("return",l({url:a,method:"PUT",headers:{"Content-Type":"application/json"},body:JSON.stringify(s)}).then((function(e){if(e.ok)return e.json();throw new Error("Failed to update email preferences")})));case 6:case"end":return t.stop()}}),t)})))()},updateEmailAddress:function(e){return m(f().mark((function t(){var n,r,i,a;return f().wrap((function(t){for(;;)switch(t.prev=t.next){case 0:return n=e.email,t.next=3,c.member.identity();case 3:return r=t.sent,i=o({type:"members",resource:"member/email"}),a={email:n,identity:r},t.abrupt("return",l({url:i,method:"POST",headers:{"Content-Type":"application/json"},body:JSON.stringify(a)}).then((function(e){if(e.ok)return"Success";throw new Error("Failed to send email address verification email")})));case 7:case"end":return t.stop()}}),t)})))()},checkoutPlan:function(){var e=arguments;return m(f().mark((function t(){var r,i,a,s,u,p,d,h,g,b,v,y,x,w,j,O,_,S,P,E;return f().wrap((function(t){for(;;)switch(t.prev=t.next){case 0:return a=e.length>0&&void 0!==e[0]?e[0]:{},s=a.plan,u=a.tierId,p=a.cadence,d=a.cancelUrl,h=a.successUrl,g=a.email,b=a.name,v=a.offerId,y=a.newsletters,x=a.metadata,w=void 0===x?{}:x,j=new URL(n),t.next=4,c.member.identity();case 4:return O=t.sent,_=o({type:"members",resource:"create-stripe-checkout-session"}),d||((S=window.location.href.startsWith(j.href)?new URL(window.location.href):new URL(n)).searchParams.set("stripe","cancel"),d=S.href),P=Object(k.a)({name:b,newsletters:JSON.stringify(y),requestSrc:"portal",fp_tid:null===(r=window.FPROM||window.$FPROM)||void 0===r||null===(i=r.data)||void 0===i?void 0:i.tid,urlHistory:Object(Lr.getUrlHistory)()},w),E={priceId:v?null:s,offerId:v,identity:O,metadata:P,successUrl:h,cancelUrl:d},g&&(E.customerEmail=g),u&&p&&(delete E.priceId,E.tierId=v?null:u,E.cadence=v?null:p),t.abrupt("return",l({url:_,method:"POST",headers:{"Content-Type":"application/json"},body:JSON.stringify(E)}).then(function(){var e=m(f().mark((function e(t){var n,r,i,o;return f().wrap((function(e){for(;;)switch(e.prev=e.next){case 0:if(t.ok){e.next=6;break}return e.next=3,t.json();case 3:throw i=e.sent,o=(null===i||void 0===i||null===(n=i.errors)||void 0===n||null===(r=n[0])||void 0===r?void 0:r.message)||"Failed to signup, please try again.",new Error(o);case 6:return e.abrupt("return",t.json());case 7:case"end":return e.stop()}}),e)})));return function(t){return e.apply(this,arguments)}}()).then((function(e){return window.Stripe(e.publicKey).redirectToCheckout({sessionId:e.sessionId})})).then((function(e){if(e.error)throw new Error(e.error.message)})).catch((function(e){throw e})));case 12:case"end":return t.stop()}}),t)})))()},editBilling:function(){var e=arguments;return m(f().mark((function t(){var r,i,a,s,u,p,d,h,m;return f().wrap((function(t){for(;;)switch(t.prev=t.next){case 0:return r=e.length>0&&void 0!==e[0]?e[0]:{},i=r.successUrl,a=r.cancelUrl,s=r.subscriptionId,u=new URL(n),t.next=4,c.member.identity();case 4:return p=t.sent,d=o({type:"members",resource:"create-stripe-update-session"}),i||((h=new URL(n)).searchParams.set("stripe","billing-update-success"),i=h.href),a||((m=window.location.href.startsWith(u.href)?new URL(window.location.href):new URL(n)).searchParams.set("stripe","billing-update-cancel"),a=m.href),t.abrupt("return",l({url:d,method:"POST",headers:{"Content-Type":"application/json"},body:JSON.stringify({identity:p,subscription_id:s,successUrl:i,cancelUrl:a})}).then((function(e){if(!e.ok)throw new Error("Unable to create stripe checkout session");return e.json()})).then((function(e){return window.Stripe(e.publicKey).redirectToCheckout({sessionId:e.sessionId})})).then((function(e){if(e.error)throw new Error(e.error.message)})).catch((function(e){throw e})));case 9:case"end":return t.stop()}}),t)})))()},updateSubscription:function(e){return m(f().mark((function t(){var n,r,i,a,s,u,p,d,h,m;return f().wrap((function(t){for(;;)switch(t.prev=t.next){case 0:return n=e.subscriptionId,r=e.tierId,i=e.cadence,a=e.planId,s=e.smartCancel,u=e.cancelAtPeriodEnd,p=e.cancellationReason,t.next=3,c.member.identity();case 3:return d=t.sent,h=o({type:"members",resource:"subscriptions"})+n+"/",m={smart_cancel:s,cancel_at_period_end:u,cancellation_reason:p,identity:d,priceId:a},r&&i&&(delete m.priceId,m.tierId=r,m.cadence=i),t.abrupt("return",l({url:h,method:"PUT",headers:{"Content-Type":"application/json"},body:JSON.stringify(m)}));case 8:case"end":return t.stop()}}),t)})))()}},c.init=m(f().mark((function e(){var t,n,r,i,o,a,l,u,p;return f().wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return e.next=2,Promise.all([c.member.sessionData()]);case 2:return t=e.sent,n=Object(s.a)(t,1),r=n[0],i={},o=[],a=[],l={},e.prev=9,e.next=12,Promise.all([c.site.settings(),c.site.tiers(),c.site.newsletters()]);case 12:u=e.sent,p=Object(s.a)(u,3),l=p[0].settings,a=p[1].tiers,o=p[2].newsletters,i=Object(k.a)(Object(k.a)({},l),{},{newsletters:o,tiers:Object(Lr.transformApiTiersData)({tiers:a})}),e.next=22;break;case 20:e.prev=20,e.t0=e.catch(9);case 22:return i=Object(Lr.transformApiSiteData)({site:i}),e.abrupt("return",{site:i,member:r});case 24:case"end":return e.stop()}}),e,null,[[9,20]])}))),c};n(1);function Za(){var e=Object(i.useContext)(Zn).site,t=e.icon;return t?Object(Hn.jsx)("img",{className:"gh-portal-unsubscribe-logo",src:t,alt:e.title}):null}function el(){var e=Object(i.useContext)(Zn).site.title||"";return Object(Hn.jsxs)("header",{className:"gh-portal-header",children:[Object(Hn.jsx)(Za,{}),Object(Hn.jsx)("h2",{className:"gh-portal-publication-title",children:e})]})}function tl(e){return nl.apply(this,arguments)}function nl(){return(nl=m(f().mark((function e(t){var n,r,i,o;return f().wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return n=t.api,r=t.memberUuid,i=t.newsletters,o=t.enableCommentNotifications,e.prev=1,e.next=4,n.member.updateNewsletters({uuid:r,newsletters:i,enableCommentNotifications:o});case 4:return e.abrupt("return",e.sent);case 7:e.prev=7,e.t0=e.catch(1);case 9:case"end":return e.stop()}}),e,null,[[1,7]])})))).apply(this,arguments)}var rl,il={signin:Ia,signup:ya,accountHome:io,accountPlan:Ho,accountProfile:Ma,accountEmail:function(){var e=Object(i.useContext)(Zn),t=e.member,n=e.onAction,r=e.site,o=Ua((null===t||void 0===t?void 0:t.newsletters)||[]),a=Object(i.useState)(o),l=Object(s.a)(a,2),c=l[0],u=l[1],p=r.comments_enabled,d=t.enable_comment_notifications;return Object(i.useEffect)((function(){t||n("switchPage",{page:"signin"})}),[t,n]),Object(i.useEffect)((function(){u((null===t||void 0===t?void 0:t.newsletters)||[])}),[null===t||void 0===t?void 0:t.newsletters]),Object(Hn.jsx)(Ja,{notification:null,subscribedNewsletters:c,updateSubscribedNewsletters:function(e){u(e),n("updateNewsletterPreference",{newsletters:e})},updateCommentNotifications:function(){var e=m(f().mark((function e(t){return f().wrap((function(e){for(;;)switch(e.prev=e.next){case 0:n("updateNewsletterPreference",{enableCommentNotifications:t});case 1:case"end":return e.stop()}}),e)})));return function(t){return e.apply(this,arguments)}}(),unsubscribeAll:function(){u([]),n("showPopupNotification",{action:"updated:success",message:"Email preference updated."});var e={newsletters:[]};p&&(e.enableCommentNotifications=!1),n("updateNewsletterPreference",e)},isPaidMember:Object(Lr.isPaidMember)({member:t}),isCommentsEnabled:"off"!==p,enableCommentNotifications:d})},signupNewsletter:ea,unsubscribe:function(){var e=Object(i.useContext)(Zn),t=e.site,n=e.pageData,r=e.onAction,o=Xa({siteUrl:t.url}),a=Object(i.useState)(),l=Object(s.a)(a,2),c=l[0],u=l[1],p=Object(Lr.getSiteNewsletters)({site:t}),d=p.filter((function(e){return e.subscribe_on_signup})),h=Object(i.useState)(!1),g=Object(s.a)(h,2),b=g[0],v=g[1],y=Object(i.useState)(d),x=Object(s.a)(y,2),w=x[0],j=x[1],O=Object(i.useState)(!1),k=Object(s.a)(O,2),_=k[0],S=k[1],P=t.comments_enabled,E=(c||{}).enable_comment_notifications,C=void 0!==E&&E;return Object(i.useEffect)((function(){var e=Xa({siteUrl:t.url});m(f().mark((function t(){var r,i,o,a,l;return f().wrap((function(t){for(;;)switch(t.prev=t.next){case 0:return t.next=2,e.member.newsletters({uuid:n.uuid});case 2:if(r=t.sent,u(r),i=(null===r||void 0===r?void 0:r.newsletters)||[],j(i),1!==(null===p||void 0===p?void 0:p.length)||P){t.next=13;break}return t.next=9,tl({api:e,memberUuid:n.uuid,newsletters:[]});case 9:o=t.sent,j(o.newsletters),t.next=25;break;case 13:if(!n.newsletterUuid){t.next=20;break}return t.next=16,tl({api:e,memberUuid:n.uuid,newsletters:null===i||void 0===i?void 0:i.filter((function(e){return e.uuid!==n.newsletterUuid}))});case 16:a=t.sent,j(a.newsletters),t.next=25;break;case 20:if(!n.comments||!P){t.next=25;break}return t.next=23,tl({api:e,memberUuid:n.uuid,enableCommentNotifications:!1});case 23:l=t.sent,u(l);case 25:case"end":return t.stop()}}),t)})))()}),[P,n.uuid,n.newsletterUuid,n.comments,t.url,null===p||void 0===p?void 0:p.length]),null===c?Object(Hn.jsxs)("div",{className:"gh-portal-content gh-portal-unsubscribe with-footer",children:[Object(Hn.jsx)(Fi,{}),Object(Hn.jsx)(el,{}),Object(Hn.jsx)("h1",{className:"gh-portal-main-title",children:"Unsubscribe failed"}),Object(Hn.jsx)("div",{children:Object(Hn.jsx)("p",{className:"gh-portal-text-center",children:"Email address not found."})})]}):1!==(null===p||void 0===p?void 0:p.length)||P||_?Object(Hn.jsx)(Ja,{notification:function(){if(n.comments&&P){var e=b?"gh-portal-hide":"";return Object(Hn.jsx)(Hn.Fragment,{children:Object(Hn.jsxs)("p",{className:"gh-portal-text-center gh-portal-header-message ".concat(e),children:[Object(Hn.jsx)("strong",{children:null===c||void 0===c?void 0:c.email})," will no longer receive emails when someone replies to your comments."]})})}var t=null===p||void 0===p?void 0:p.find((function(e){return e.uuid===n.newsletterUuid})),r=b?"gh-portal-hide":"";return Object(Hn.jsx)(Hn.Fragment,{children:Object(Hn.jsxs)("p",{className:"gh-portal-text-center gh-portal-header-message ".concat(r),children:[Object(Hn.jsx)("strong",{children:null===c||void 0===c?void 0:c.email})," will no longer receive ",Object(Hn.jsx)("strong",{children:null===t||void 0===t?void 0:t.name})," newsletter."]})})},subscribedNewsletters:w,updateSubscribedNewsletters:function(){var e=m(f().mark((function e(t){return f().wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return j(t),v(!0),e.next=4,o.member.updateNewsletters({uuid:n.uuid,newsletters:t});case 4:case"end":return e.stop()}}),e)})));return function(t){return e.apply(this,arguments)}}(),updateCommentNotifications:function(){var e=m(f().mark((function e(t){var r;return f().wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return e.next=2,o.member.updateNewsletters({uuid:n.uuid,enableCommentNotifications:t});case 2:r=e.sent,u(r);case 4:case"end":return e.stop()}}),e)})));return function(t){return e.apply(this,arguments)}}(),unsubscribeAll:m(f().mark((function e(){var t;return f().wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return v(!0),j([]),r("showPopupNotification",{action:"updated:success",message:"Email preference updated."}),e.next=5,o.member.updateNewsletters({uuid:n.uuid,newsletters:[],enableCommentNotifications:!1});case 5:t=e.sent,u(t);case 7:case"end":return e.stop()}}),e)}))),isPaidMember:"free"!==(null===c||void 0===c?void 0:c.status),isCommentsEnabled:"off"!==P,enableCommentNotifications:C}):Object(Hn.jsxs)("div",{className:"gh-portal-content gh-portal-unsubscribe with-footer",children:[Object(Hn.jsx)(Fi,{}),Object(Hn.jsx)(el,{}),Object(Hn.jsx)("h1",{className:"gh-portal-main-title",children:"Successfully unsubscribed"}),Object(Hn.jsxs)("div",{children:[Object(Hn.jsxs)("p",{className:"gh-portal-text-center",children:[Object(Hn.jsx)("strong",{children:null===c||void 0===c?void 0:c.email})," will no longer receive this newsletter."]}),Object(Hn.jsxs)("p",{className:"gh-portal-text-center",children:["Didn't mean to do this? Manage your preferences",Object(Hn.jsx)("button",{className:"gh-portal-btn-link gh-portal-btn-branded gh-portal-btn-inline",onClick:function(){S(!0)},children:"here"}),"."]})]})]})},magiclink:Sa,loading:La,offer:Ta},ol=function(e){var t=e.page;return Object.keys(il).includes(t)?t:"signup"},al=il,ll=["title","titleId"];function sl(){return sl=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(e[r]=n[r])}return e},sl.apply(this,arguments)}function cl(e,t){if(null==e)return{};var n,r,i=function(e,t){if(null==e)return{};var n,r,i={},o=Object.keys(e);for(r=0;r<o.length;r++)n=o[r],t.indexOf(n)>=0||(i[n]=e[n]);return i}(e,t);if(Object.getOwnPropertySymbols){var o=Object.getOwnPropertySymbols(e);for(r=0;r<o.length;r++)n=o[r],t.indexOf(n)>=0||Object.prototype.propertyIsEnumerable.call(e,n)&&(i[n]=e[n])}return i}function ul(e,t){var n=e.title,r=e.titleId,o=cl(e,ll);return i.createElement("svg",sl({width:24,height:24,viewBox:"0 0 24 24",fill:"none",xmlns:"http://www.w3.org/2000/svg",ref:t,"aria-labelledby":r},o),n?i.createElement("title",{id:r},n):null,rl||(rl=i.createElement("path",{fillRule:"evenodd",clipRule:"evenodd",d:"M24 12C24 18.6274 18.6274 24 12 24C5.37258 24 0 18.6274 0 12C0 5.37258 5.37258 0 12 0C18.6274 0 24 5.37258 24 12ZM11.8326 2.33879C6.37785 2.95189 3.95901 5.20797 3.41126 9.74699C3.34896 10.2632 3.22642 10.7805 3.10443 11.2954C2.93277 12.02 2.76221 12.74 2.76221 13.4458C2.76221 17.9885 6.5856 21.556 11.1283 21.556C12.8959 21.556 14.4433 20.8144 15.8756 20.048C19.0536 18.3478 22.0328 16.2597 22.0328 12.5411C22.0328 9.91512 20.1051 7.56932 18.466 5.5747C18.3834 5.47416 18.3015 5.37451 18.2206 5.27577C17.3866 4.25742 14.4333 2.04643 11.8326 2.33879Z",fill:"#15171A"})))}var pl=i.forwardRef(ul),dl=(n.p,function(e){x(n,e);var t=O(n);function n(){return g(this,n),t.apply(this,arguments)}return v(n,[{key:"render",value:function(){return Object(Hn.jsxs)("a",{href:"https://ghost.org",target:"_blank",rel:"noopener noreferrer",onClick:function(){window.open("https://ghost.org","_blank")},children:[Object(Hn.jsx)(pl,{}),"Powered by Ghost"]})}}]),n}(o.a.Component)),fl=n(1),hl=function(e){e.member;return{modalContainer:{zIndex:"3999999",position:"fixed",left:"0",top:"0",width:"100%",height:"100%",overflow:"hidden"},frame:{common:{margin:"auto",position:"relative",padding:"0",outline:"0",width:"100%",opacity:"1",overflow:"hidden",height:"100%"}},page:{links:{width:"600px"}}}};function ml(e){var t=e.message;return Object(Lr.isCookiesDisabled)()?Object(Hn.jsx)("div",{className:"gh-portal-cookiebanner",children:t}):null}var gl=function(e){x(n,e);var t=O(n);function n(){return g(this,n),t.apply(this,arguments)}return v(n,[{key:"componentDidMount",value:function(){var e=this;this.node&&!zr(["preview"])&&(this.node.focus(),this.keyUphandler=function(t){"Escape"===t.key&&e.dismissPopup(t)},this.node.ownerDocument.removeEventListener("keyup",this.keyUphandler),this.node.ownerDocument.addEventListener("keyup",this.keyUphandler)),this.sendContainerHeightChangeEvent()}},{key:"dismissPopup",value:function(e){var t,n=e.target&&e.target.tagName;("INPUT"!==n||"INPUT"===n&&!(null!==e&&void 0!==e&&null!==(t=e.target)&&void 0!==t&&t.value))&&this.context.onAction("closePopup")}},{key:"sendContainerHeightChangeEvent",value:function(){var e,t;this.node&&zr(["preview"])&&((null===(e=this.node)||void 0===e?void 0:e.clientHeight)!==this.lastContainerHeight&&(this.lastContainerHeight=null===(t=this.node)||void 0===t?void 0:t.clientHeight,window.document.body.style.overflow="hidden",window.document.body.style["scrollbar-width"]="none",window.parent.postMessage({type:"portal-preview-updated",payload:{height:this.lastContainerHeight}},"*")))}},{key:"componentDidUpdate",value:function(){this.sendContainerHeightChangeEvent()}},{key:"componentWillUnmount",value:function(){this.node&&this.node.ownerDocument.removeEventListener("keyup",this.keyUphandler)}},{key:"handlePopupClose",value:function(e){zr(["preview"])||(e.preventDefault(),e.target===e.currentTarget&&this.context.onAction("closePopup"))}},{key:"renderActivePage",value:function(){var e=this.context.page;ol({page:e});var t=al[e];return Object(Hn.jsx)(t,{})}},{key:"renderPopupNotification",value:function(){var e=this.context.popupNotification;return e&&e.type?Object(Hn.jsx)(Ca,{}):null}},{key:"render",value:function(){var e=this,t=this.context,n=t.page,r=t.pageQuery,i=t.site,o=t.customSiteUrl,a=Object(Lr.getSiteProducts)({site:i}).length;ol({page:n});var l=hl({page:n}),s=Object(k.a)({},l.page[n]),c="regular",u="",p=n;switch(n){case"signup":u="Cookies must be enabled in your browser to sign up.";break;case"signin":u="Cookies must be enabled in your browser to sign in.";break;case"accountHome":p="account-home";break;case"accountProfile":p="account-profile";break;case"accountPlan":p="account-plan";break;default:u="Cookies must be enabled in your browser.",p=n}a>1&&!Object(Lr.isInviteOnlySite)({site:i,pageQuery:r})&&"signup"===n&&(p+=" full-size",c="full");var d=Object(Lr.hasFreeProductPrice)({site:i});(d&&a>2||!d&&a>1)&&"accountPlan"===n&&(p+=" full-size",c="full");var f="gh-portal-popup-container";zr(["preview"])&&(p+=" preview"),zr(["preview"],{customSiteUrl:o})&&!i.disableBackground&&(f+=" preview"),zr(["dev"])&&(f+=" dev");var h="".concat(f," ").concat(""," ").concat(p);return Object(Hn.jsxs)(Hn.Fragment,{children:[Object(Hn.jsx)("div",{className:"gh-portal-popup-wrapper "+p,onClick:function(t){return e.handlePopupClose(t)},children:Object(Hn.jsxs)("div",{className:h,style:s,ref:function(t){return e.node=t},tabIndex:-1,children:[Object(Hn.jsx)(ml,{message:u}),this.renderPopupNotification(),this.renderActivePage(),"full"===c?Object(Hn.jsx)("div",{className:"gh-portal-powered inside "+(zr(["preview"])?"hidden ":"")+p,children:Object(Hn.jsx)(dl,{})}):""]})}),Object(Hn.jsx)("div",{className:"gh-portal-powered outside "+(zr(["preview"])?"hidden ":"")+p,children:Object(Hn.jsx)(dl,{})})]})}}]),n}(fl.Component);gl.contextType=Zn;var bl,vl=function(e){x(n,e);var t=O(n);function n(e){var r;return g(this,n),(r=t.call(this,e)).state={height:null},r}return v(n,[{key:"renderCurrentPage",value:function(e){var t=al[e];return Object(Hn.jsx)(t,{})}},{key:"onHeightChange",value:function(e){this.setState({height:e})}},{key:"handlePopupClose",value:function(e){e.preventDefault(),e.target===e.currentTarget&&this.context.onAction("closePopup")}},{key:"renderFrameStyles",value:function(){var e=function(e){var t=e.site,n=Ir+'\n.gh-portal-main-title {\n text-align: center;\n color: var(--grey0);\n line-height: 1.1em;\n}\n\n.gh-portal-text-disabled {\n color: var(--grey3);\n font-weight: normal;\n opacity: 0.35;\n}\n\n.gh-portal-text-center {\n text-align: center;\n}\n\n.gh-portal-input-label {\n color: var(--grey1);\n font-size: 1.3rem;\n font-weight: 600;\n margin-bottom: 2px;\n letter-spacing: 0px;\n}\n\n.gh-portal-setting-data {\n color: var(--grey6);\n font-size: 1.3rem;\n line-height: 1.15em;\n}\n\n.gh-portal-error {\n color: var(--red);\n font-size: 1.4rem;\n line-height: 1.6em;\n margin: 12px 0;\n}\n\n/* Buttons\n/* ----------------------------------------------------- */\n.gh-portal-btn {\n position: relative;\n display: flex;\n align-items: center;\n justify-content: center;\n font-size: 1.5rem;\n font-weight: 500;\n line-height: 1em;\n letter-spacing: 0.2px;\n text-align: center;\n white-space: nowrap;\n text-decoration: none;\n color: var(--grey0);\n background: var(--white);\n border: 1px solid var(--grey12);\n min-width: 80px;\n height: 44px;\n padding: 0 1.8rem;\n border-radius: 6px;\n cursor: pointer;\n transition: all .25s ease;\n box-shadow: none;\n user-select: none;\n outline: none;\n}\n\n.gh-portal-btn:hover {\n border-color: var(--grey10);\n}\n\n.gh-portal-btn:disabled {\n opacity: 0.5 !important;\n cursor: auto;\n}\n\n.gh-portal-btn-container.sticky {\n transition: none;\n position: sticky;\n bottom: 0;\n margin: 0 0 -32px;\n padding: 32px 0 32px;\n background: linear-gradient(0deg, rgba(255,255,255,1) 75%, rgba(255,255,255,0) 100%);\n}\n\n.gh-portal-btn-container.sticky.m28 {\n margin: 0 0 -28px;\n padding: 28px 0 28px;\n}\n\n.gh-portal-btn-container.sticky.m24 {\n margin: 0 0 -24px;\n padding: 24px 0 24px;\n}\n\n.gh-portal-btn-container .gh-portal-btn {\n margin: 0;\n}\n\n.gh-portal-btn-icon svg {\n width: 16px;\n height: 16px;\n margin-right: 4px;\n stroke: currentColor;\n}\n\n.gh-portal-btn-icon svg path {\n stroke: currentColor;\n}\n\n.gh-portal-btn-link {\n line-height: 1;\n background: none;\n padding: 0;\n height: unset;\n min-width: unset;\n box-shadow: none;\n border: none;\n}\n\n.gh-portal-btn-link:hover {\n box-shadow: none;\n opacity: 0.85;\n}\n\n.gh-portal-btn-branded {\n color: var(--brandcolor);\n}\n\n.gh-portal-btn-list {\n font-size: 1.5rem;\n color: var(--brandcolor);\n height: 38px;\n width: unset;\n min-width: unset;\n padding: 0 4px;\n margin: 0 -4px;\n box-shadow: none;\n border: none;\n}\n\n.gh-portal-btn-list:hover {\n box-shadow: none;\n opacity: 0.75;\n}\n\n.gh-portal-btn-logout {\n position: absolute;\n top: 22px;\n left: 24px;\n background: none;\n border: none;\n height: unset;\n color: var(--grey3);\n padding: 0;\n margin: 0;\n z-index: 999;\n box-shadow: none;\n}\n\n.gh-portal-btn-logout .label {\n opacity: 0;\n transform: translateX(-6px);\n transition: all 0.2s ease-in-out;\n}\n\n.gh-portal-btn-logout:hover {\n padding: 0;\n margin: 0;\n background: none;\n border: none;\n height: unset;\n box-shadow: none;\n}\n\n.gh-portal-btn-logout:hover .label {\n opacity: 1.0;\n transform: translateX(-4px);\n}\n\n.gh-portal-btn-site-title-back {\n transition: transform 0.25s ease-in-out;\n z-index: 10000;\n}\n\n.gh-portal-btn-site-title-back span {\n margin-right: 4px;\n transition: transform 0.4s cubic-bezier(0.1, 0.7, 0.1, 1);\n}\n\n\n.gh-portal-btn-site-title-back:hover span {\n transform: translateX(-3px);\n}\n\n@media (max-width: 960px) {\n .gh-portal-btn-site-title-back {\n display: none;\n }\n}\n\n.gh-portal-logouticon {\n color: var(--grey9);\n cursor: pointer;\n width: 23px;\n height: 23px;\n padding: 6px;\n transform: translateX(0);\n transition: all 0.2s ease-in-out;\n}\n\n.gh-portal-logouticon path {\n stroke: var(--grey9);\n transition: all 0.2s ease-in-out;\n}\n\n.gh-portal-btn-logout:hover .gh-portal-logouticon {\n transform: translateX(-2px);\n}\n\n.gh-portal-btn-logout:hover .gh-portal-logouticon path {\n stroke: var(--grey3);\n}\n\n/* Global layout styles\n/* ----------------------------------------------------- */\n.gh-portal-popup-background {\n position: absolute;\n display: block;\n top: 0;\n right: 0;\n bottom: 0;\n left: 0;\n animation: fadein 0.2s;\n background: linear-gradient(315deg , rgba(0,0,0,0.2) 0%, rgba(0,0,0,0.1) 100%);\n backdrop-filter: blur(2px);\n -webkit-backdrop-filter: blur(2px);\n -webkit-transform: translate3d(0, 0, 0);\n -moz-transform: translate3d(0, 0, 0);\n -ms-transform: translate3d(0, 0, 0);\n transform: translate3d(0, 0, 0);\n}\n\n.gh-portal-popup-background.preview {\n background: linear-gradient(45deg, rgba(255,255,255,1) 0%, rgba(249,249,250,1) 100%);\n animation: none;\n pointer-events: none;\n}\n\n@keyframes fadein {\n 0% { opacity: 0; }\n 100%{ opacity: 1.0; }\n}\n\n.gh-portal-popup-wrapper {\n position: relative;\n padding: 5vmin 0 0;\n height: 100%;\n max-height: 100vh;\n overflow: scroll;\n}\n\n/* Hiding scrollbars */\n.gh-portal-popup-wrapper {\n padding-right: 30px !important;\n margin-right: -30px !important;\n -ms-overflow-style: none;\n scrollbar-width: none;\n}\n\n.gh-portal-popup-wrapper::-webkit-scrollbar {\n display: none;\n}\n\n.gh-portal-popup-wrapper.full-size {\n height: 100vh;\n padding: 0;\n}\n\n.gh-portal-popup-container {\n outline: none;\n position: relative;\n display: flex;\n box-sizing: border-box;\n flex-direction: column;\n justify-content: flex-start;\n font-size: 1.5rem;\n text-align: left;\n letter-spacing: 0;\n text-rendering: optimizeLegibility;\n background: var(--white);\n width: 500px;\n margin: 0 auto 40px;\n padding: 32px;\n transform: translateY(0px);\n border-radius: 10px;\n box-shadow: 0 3.8px 2.2px rgba(0, 0, 0, 0.028), 0 9.2px 5.3px rgba(0, 0, 0, 0.04), 0 17.3px 10px rgba(0, 0, 0, 0.05), 0 30.8px 17.9px rgba(0, 0, 0, 0.06), 0 57.7px 33.4px rgba(0, 0, 0, 0.072), 0 138px 80px rgba(0, 0, 0, 0.1);\n animation: popup 0.25s ease-in-out;\n z-index: 9999;\n}\n\n.gh-portal-popup-container.full-size {\n width: 100vw;\n min-height: 100vh;\n justify-content: flex-start;\n animation: popup-full-size 0.25s ease-in-out;\n margin: 0;\n border-radius: 0;\n transform: translateY(0px);\n transform-origin: top;\n padding: 2vmin 6vmin;\n padding-bottom: 4vw;\n}\n\n.gh-portal-popup-container.full-size.account-plan {\n justify-content: flex-start;\n padding-top: 4vw;\n}\n\n.gh-portal-popup-container.preview {\n animation: none !important;\n}\n\n@keyframes popup {\n 0% {\n transform: translateY(-30px);\n opacity: 0;\n }\n 1% {\n transform: translateY(30px);\n opacity: 0;\n }\n 100%{\n transform: translateY(0);\n opacity: 1.0;\n }\n}\n\n@keyframes popup-full-size {\n 0% {\n transform: translateY(0px);\n opacity: 0;\n }\n 1% {\n transform: translateY(30px);\n opacity: 0;\n }\n 100%{\n transform: translateY(0);\n opacity: 1.0;\n }\n}\n\n.gh-portal-powered {\n position: absolute;\n bottom: 24px;\n left: 24px;\n z-index: 9999;\n}\n\n.gh-portal-powered a {\n border: none;\n display: flex;\n align-items: center;\n line-height: 0;\n border-radius: 4px;\n background: #ffffff;\n padding: 6px 8px 6px 7px;\n color: #303336;\n font-size: 1.25rem;\n letter-spacing: -0.2px;\n font-weight: 500;\n text-decoration: none;\n transition: color 0.5s ease-in-out;\n width: 146px;\n height: 28px;\n line-height: 28px;\n}\n\n.gh-portal-powered a:hover {\n color: #15171A;\n}\n\n@keyframes powered-fade-in {\n 0% {\n transform: scale(0.98);\n opacity: 0;\n }\n 75% {\n opacity: 1.0;\n }\n 100%{\n transform: scale(1);\n }\n}\n\n.gh-portal-powered a svg {\n height: 16px;\n width: 16px;\n margin: 0 6px 0 0;\n}\n\n.gh-portal-powered.outside.full-size {\n display: none;\n}\n\n/* Sets the main content area of the popup scrollable.\n/* 12vw is the sum horizontal padding of the popup container\n*/\n.gh-portal-content {\n position: relative;\n}\n\n/* Hide scrollbar for Chrome, Safari and Opera */\n.gh-portal-content::-webkit-scrollbar {\n display: none;\n}\n\n/* Hide scrollbar for IE, Edge and Firefox */\n.gh-portal-content {\n -ms-overflow-style: none; /* IE and Edge */\n scrollbar-width: none; /* Firefox */\n}\n\n.gh-portal-closeicon-container {\n position: fixed;\n top: 24px;\n right: 24px;\n z-index: 10000;\n}\n\n.gh-portal-closeicon {\n color: var(--grey10);\n cursor: pointer;\n width: 20px;\n height: 20px;\n padding: 12px;\n transition: all 0.2s ease-in-out;\n}\n\n.gh-portal-closeicon:hover {\n color: var(--grey5);\n}\n\n.gh-portal-popup-wrapper.full-size .gh-portal-closeicon-container,\n.gh-portal-popup-container.full-size .gh-portal-closeicon-container {\n top: 20px;\n right: 20px;\n}\n\n.gh-portal-popup-wrapper.full-size .gh-portal-closeicon,\n.gh-portal-popup-container.full-size .gh-portal-closeicon {\n color: var(--grey6);\n width: 24px;\n height: 24px;\n}\n\n.gh-portal-logout-container {\n position: absolute;\n top: 8px;\n left: 8px;\n}\n\n.gh-portal-header {\n display: flex;\n flex-direction: column;\n align-items: center;\n padding-bottom: 24px;\n}\n\n.gh-portal-section {\n margin-bottom: 40px;\n}\n\n.gh-portal-section.form {\n margin-bottom: 20px;\n}\n\n.gh-portal-detail-header {\n position: relative;\n display: flex;\n align-items: center;\n justify-content: center;\n margin: -2px 0 40px;\n}\n\n.gh-portal-detail-footer .gh-portal-btn {\n min-width: 90px;\n}\n\n.gh-portal-action-footer {\n display: flex;\n align-items: center;\n justify-content: space-between;\n}\n\n.gh-portal-list-header {\n font-size: 1.25rem;\n font-weight: 500;\n color: var(--grey3);\n text-transform: uppercase;\n letter-spacing: 0.2px;\n line-height: 1.7em;\n margin-bottom: 4px;\n}\n\n.gh-portal-list + .gh-portal-list-header {\n margin-top: 28px;\n}\n\n.gh-portal-list + .gh-portal-action-footer {\n margin-top: 40px;\n}\n\n.gh-portal-list {\n background: var(--white);\n padding: 20px;\n border-radius: 8px;\n border: 1px solid var(--grey12);\n}\n\n.gh-portal-newsletter-selection {\n max-width: 460px;\n margin: 0 auto;\n}\n\n.gh-portal-newsletter-selection .gh-portal-list {\n margin-bottom: 40px;\n}\n\n.gh-portal-lock-icon-container {\n display: flex;\n justify-content: center;\n flex: 44px 0 0;\n padding-top: 6px;\n}\n\n.gh-portal-lock-icon {\n width: 14px;\n height: 14px;\n overflow: visible;\n}\n\n.gh-portal-lock-icon path {\n color: var(--grey2);\n}\n\n.gh-portal-text-large {\n font-size: 1.8rem;\n font-weight: 600;\n}\n\n.gh-portal-list section {\n display: flex;\n align-items: center;\n margin: 0 -20px 20px;\n padding: 0 20px 20px;\n border-bottom: 1px solid var(--grey12);\n}\n\n.gh-portal-list section:last-of-type {\n margin-bottom: 0;\n padding-bottom: 0;\n border: none;\n}\n\n.gh-portal-list-detail {\n flex-grow: 1;\n}\n\n.gh-portal-list-detail h3 {\n font-size: 1.5rem;\n font-weight: 600;\n}\n\n.gh-portal-list-detail.gh-portal-list-big h3 {\n font-size: 1.6rem;\n font-weight: 600;\n}\n\n.gh-portal-list-detail p {\n font-size: 1.45rem;\n letter-spacing: 0.3px;\n line-height: 1.3em;\n padding: 0;\n margin: 5px 8px 0 0;\n color: var(--grey6);\n word-break: break-word;\n}\n\n.gh-portal-list-detail.gh-portal-list-big p {\n font-size: 1.5rem;\n}\n\n.gh-portal-list-toggle-wrapper {\n align-items: flex-start !important;\n justify-content: space-between;\n}\n\n.gh-portal-list-toggle-wrapper .gh-portal-list-detail {\n padding: 4px 24px 4px 0px;\n}\n\n.gh-portal-list-detail .old-price {\n text-decoration: line-through;\n}\n\n.gh-portal-right-arrow {\n line-height: 1;\n color: var(--grey8);\n}\n\n.gh-portal-right-arrow svg {\n width: 17px;\n height: 17px;\n margin-top: 1px;\n margin-right: -6px;\n}\n\n.gh-portal-expire-warning {\n text-align: center;\n color: var(--red);\n font-weight: 500;\n font-size: 1.4rem;\n margin: 12px 0;\n}\n\n.gh-portal-cookiebanner {\n background: var(--red);\n color: var(--white);\n text-align: center;\n font-size: 1.4rem;\n letter-spacing: 0.2px;\n line-height: 1.4em;\n padding: 8px;\n}\n\n.gh-portal-publication-title {\n text-align: center;\n font-size: 1.6rem;\n letter-spacing: -.1px;\n font-weight: 700;\n text-transform: uppercase;\n color: #15212a;\n margin-top: 6px;\n}\n\n/* Icons\n/* ----------------------------------------------------- */\n.gh-portal-icon {\n color: var(--brandcolor);\n}\n\n/* Spacing modifiers\n/* ----------------------------------------------------- */\n.gh-portal-strong { font-weight: 600; }\n\n.mt1 { margin-top: 4px; }\n.mt2 { margin-top: 8px; }\n.mt3 { margin-top: 12px; }\n.mt4 { margin-top: 16px; }\n.mt5 { margin-top: 20px; }\n.mt6 { margin-top: 24px; }\n.mt7 { margin-top: 28px; }\n.mt8 { margin-top: 32px; }\n.mt9 { margin-top: 36px; }\n.mt10 { margin-top: 40px; }\n\n.mr1 { margin-right: 4px; }\n.mr2 { margin-right: 8px; }\n.mr3 { margin-right: 12px; }\n.mr4 { margin-right: 16px; }\n.mr5 { margin-right: 20px; }\n.mr6 { margin-right: 24px; }\n.mr7 { margin-right: 28px; }\n.mr8 { margin-right: 32px; }\n.mr9 { margin-right: 36px; }\n.mr10 { margin-right: 40px; }\n\n.mb1 { margin-bottom: 4px; }\n.mb2 { margin-bottom: 8px; }\n.mb3 { margin-bottom: 12px; }\n.mb4 { margin-bottom: 16px; }\n.mb5 { margin-bottom: 20px; }\n.mb6 { margin-bottom: 24px; }\n.mb7 { margin-bottom: 28px; }\n.mb8 { margin-bottom: 32px; }\n.mb9 { margin-bottom: 36px; }\n.mb10 { margin-bottom: 40px; }\n\n.ml1 { margin-left: 4px; }\n.ml2 { margin-left: 8px; }\n.ml3 { margin-left: 12px; }\n.ml4 { margin-left: 16px; }\n.ml5 { margin-left: 20px; }\n.ml6 { margin-left: 24px; }\n.ml7 { margin-left: 28px; }\n.ml8 { margin-left: 32px; }\n.ml9 { margin-left: 36px; }\n.ml10 { margin-left: 40px; }\n\n.pt1 { padding-top: 4px; }\n.pt2 { padding-top: 8px; }\n.pt3 { padding-top: 12px; }\n.pt4 { padding-top: 16px; }\n.pt5 { padding-top: 20px; }\n.pt6 { padding-top: 24px; }\n.pt7 { padding-top: 28px; }\n.pt8 { padding-top: 32px; }\n.pt9 { padding-top: 36px; }\n.pt10 { padding-top: 40px; }\n\n.pr1 { padding-right: 4px; }\n.pr2 { padding-right: 8px; }\n.pr3 { padding-right: 12px; }\n.pr4 { padding-right: 16px; }\n.pr5 { padding-right: 20px; }\n.pr6 { padding-right: 24px; }\n.pr7 { padding-right: 28px; }\n.pr8 { padding-right: 32px; }\n.pr9 { padding-right: 36px; }\n.pr10 { padding-right: 40px; }\n\n.pb1 { padding-bottom: 4px; }\n.pb2 { padding-bottom: 8px; }\n.pb3 { padding-bottom: 12px; }\n.pb4 { padding-bottom: 16px; }\n.pb5 { padding-bottom: 20px; }\n.pb6 { padding-bottom: 24px; }\n.pb7 { padding-bottom: 28px; }\n.pb8 { padding-bottom: 32px; }\n.pb9 { padding-bottom: 36px; }\n.pb10 { padding-bottom: 40px; }\n\n.pl1 { padding-left: 4px; }\n.pl2 { padding-left: 8px; }\n.pl3 { padding-left: 12px; }\n.pl4 { padding-left: 16px; }\n.pl5 { padding-left: 20px; }\n.pl6 { padding-left: 24px; }\n.pl7 { padding-left: 28px; }\n.pl8 { padding-left: 32px; }\n.pl9 { padding-left: 36px; }\n.pl10 { padding-left: 40px; }\n\n.hidden { display: none !important; }\n\n .gh-portal-account-header {\n display: flex;\n flex-direction: column;\n align-items: center;\n margin: 0 0 32px;\n }\n\n .gh-portal-account-header .gh-portal-avatar {\n margin: 6px 0 8px !important;\n }\n\n .gh-portal-account-data {\n margin-bottom: 40px;\n }\n\n footer.gh-portal-account-footer {\n display: flex;\n }\n\n .gh-portal-account-footer.paid {\n margin-top: 12px;\n }\n\n .gh-portal-account-footermenu {\n display: flex;\n align-items: center;\n list-style: none;\n padding: 0;\n margin: 0;\n }\n\n .gh-portal-account-footerright {\n display: flex;\n flex-grow: 1;\n align-items: center;\n justify-content: flex-end;\n }\n\n .gh-portal-account-footermenu li {\n margin-right: 16px;\n }\n\n .gh-portal-account-footermenu li:last-of-type {\n margin-right: 0;\n }\n\n .gh-portal-freeaccount-newsletter {\n display: flex;\n align-items: center;\n justify-content: space-between;\n margin-top: 24px;\n }\n\n .gh-portal-freeaccount-newsletter .label {\n display: flex;\n flex-direction: column;\n flex-grow: 1;\n }\n\n .gh-portal-free-ctatext {\n margin-top: -12px;\n }\n\n .gh-portal-cancelcontinue-container {\n margin: 24px 0 32px;\n }\n\n .gh-portal-billing-button-loader {\n width: 32px;\n height: 32px;\n margin-right: -3px;\n opacity: 0.6;\n }\n\n .gh-portal-product-icon {\n width: 52px;\n margin-right: 12px;\n border-radius: 2px;\n }\n\n .gh-portal-account-discountcontainer {\n position: relative;\n display: flex;\n align-items: center;\n }\n\n .gh-portal-account-old-price {\n text-decoration: line-through;\n color: var(--grey9) !important;\n }\n\n .gh-portal-account-tagicon {\n width: 16px;\n height: 16px;\n color: var(--brandcolor);\n margin-right: 5px;\n z-index: 999;\n }\n\n @media (max-width: 390px) {\n .gh-portal-account-footer {\n padding: 0 !important;\n }\n }\n\n @media (max-width: 340px) {\n .gh-portal-account-footer {\n padding: 0 !important;\n flex-wrap: wrap;\n gap: 12px;\n }\n\n .gh-portal-account-footer .gh-portal-account-footerright {\n justify-content: flex-start;\n }\n }\n\n .account-plan.full-size .gh-portal-main-title {\n font-size: 3.2rem;\n margin-top: 44px;\n }\n\n .gh-portal-accountplans-main {\n margin-top: 24px;\n margin-bottom: 0;\n }\n\n .gh-portal-expire-container {\n margin: 32px 0 0;\n }\n\n .gh-portal-cancellation-form p {\n margin-bottom: 12px;\n }\n\n .gh-portal-cancellation-form .gh-portal-input-section {\n margin-bottom: 20px;\n }\n\n .gh-portal-cancellation-form .gh-portal-input {\n resize: none;\n width: 100%;\n height: 62px;\n padding: 6px 12px;\n }\n\n .gh-portal-input {\n -webkit-appearance: none;\n -moz-appearance: none;\n appearance: none;\n\n display: block;\n box-sizing: border-box;\n font-size: 1.5rem;\n color: inherit;\n background: transparent;\n outline: none;\n border: 1px solid var(--grey11);\n border-radius: 6px;\n width: 100%;\n height: 44px;\n padding: 0 12px;\n margin-bottom: 18px;\n letter-spacing: 0.2px;\n transition: border-color 0.25s ease-in-out;\n }\n\n .gh-portal-input-labelcontainer {\n display: flex;\n justify-content: space-between;\n width: 100%;\n }\n\n .gh-portal-input-labelcontainer p {\n color: var(--red);\n font-size: 1.3rem;\n letter-spacing: 0.35px;\n line-height: 1.6em;\n margin-bottom: 0;\n }\n\n .gh-portal-input-label.hidden {\n display: none;\n }\n\n .gh-portal-input:focus {\n border-color: var(--grey8);\n }\n\n .gh-portal-input.error {\n border-color: var(--red);\n }\n\n .gh-portal-input::placeholder {\n color: var(--grey8);\n }\n\n .gh-portal-popup-container:not(.preview) .gh-portal-input:disabled {\n background: var(--grey13);\n color: var(--grey9);\n box-shadow: none;\n }\n\n .gh-portal-popup-container:not(.preview) .gh-portal-input:disabled::placeholder {\n color: var(--grey9);\n }\n\n .gh-portal-plans-container {\n display: flex;\n align-items: stretch;\n border: 1px solid var(--grey11);\n border-radius: 5px;\n }\n\n .gh-portal-plan-section {\n display: flex;\n flex-direction: column;\n flex: 1;\n position: relative;\n align-items: center;\n justify-items: center;\n font-size: 1.4rem;\n line-height: 1.35em;\n border-right: 1px solid var(--grey11);\n padding: 24px 10px;\n cursor: pointer;\n user-select: none;\n }\n\n .gh-portal-change-plan-section {\n border-top-left-radius: 0;\n border-top-right-radius: 0;\n }\n\n .gh-portal-plans-container.disabled .gh-portal-plan-section {\n cursor: auto;\n }\n\n .gh-portal-plan-section.checked::before {\n position: absolute;\n display: block;\n top: -1px;\n right: -1px;\n bottom: -1px;\n left: -1px;\n content: "";\n z-index: 999;\n border: 2px solid var(--brandcolor);\n pointer-events: none;\n }\n\n .gh-portal-plan-section:first-of-type::before {\n border-top-left-radius: 5px;\n border-bottom-left-radius: 5px;\n }\n\n .gh-portal-plan-section:last-of-type::before {\n border-top-right-radius: 5px;\n border-bottom-right-radius: 5px;\n }\n\n .gh-portal-plan-section:last-of-type {\n border-right: none;\n }\n\n .gh-portal-plans-container:not(.empty-selected-benefits) .gh-portal-plan-section::before {\n border-bottom-left-radius: 0;\n border-bottom-right-radius: 0;\n }\n\n .gh-portal-plans-container.has-discount {\n margin-top: 40px;\n }\n\n .gh-portal-plans-container.has-discount,\n .gh-portal-plans-container.has-discount .gh-portal-plan-section:last-of-type::before {\n border-top-right-radius: 0;\n }\n\n .gh-portal-plans-container.is-change-plan .gh-portal-plan-section::before {\n border-top-left-radius: 0;\n border-top-right-radius: 0;\n }\n\n .gh-portal-plans-container.disabled .gh-portal-plan-section.checked::before {\n opacity: 0.3;\n }\n\n .gh-portal-plan-pricelabel {\n display: flex;\n flex-direction: row;\n min-height: 28px;\n margin-top: 2px;\n }\n\n .gh-portal-plans-container .gh-portal-plan-pricelabel {\n min-height: unset;\n }\n\n .gh-portal-plan-pricecontainer {\n display: flex;\n }\n\n .gh-portal-plan-priceinterval {\n font-size: 1.25rem;\n line-height: 2;\n color: var(--grey7);\n }\n\n .gh-portal-plan-name {\n display: flex;\n align-items: center;\n font-size: 1.2rem;\n font-weight: 500;\n line-height: 1.0em;\n letter-spacing: 0.5px;\n text-transform: uppercase;\n margin-top: 4px;\n text-align: center;\n min-height: 24px;\n word-break: break-word;\n }\n\n .gh-portal-plan-currency {\n position: relative;\n bottom: 2px;\n font-size: 1.4rem;\n font-weight: 500;\n letter-spacing: 0.4px;\n }\n\n .gh-portal-plan-currency-code {\n margin-right: 2px;\n font-size: 1.15rem;\n }\n\n .gh-portal-plan-price {\n font-size: 2.2rem;\n font-weight: 500;\n letter-spacing: 0.1px;\n }\n\n .gh-portal-plan-type {\n color: var(--grey7);\n }\n\n .gh-portal-plan-featurewrapper {\n display: flex;\n flex-direction: column;\n align-items: center;\n border-top: 1px solid var(--grey12);\n padding-top: 12px;\n width: 100%;\n }\n\n .gh-portal-plan-feature {\n font-size: 1.25rem;\n font-weight: 500;\n line-height: 1.25em;\n text-align: center;\n letter-spacing: 0.2px;\n word-break: break-word;\n }\n\n .gh-portal-content.signup.singleplan .gh-portal-plan-section {\n cursor: auto;\n }\n\n .gh-portal-content.signup.singleplan .gh-portal-plan-section.checked::before {\n display: none;\n }\n\n .gh-portal-content.signup.singleplan .gh-portal-plan-name {\n margin-top: 0;\n }\n\n .gh-portal-plan-section:not(.checked)::before {\n position: absolute;\n display: block;\n top: -1px;\n right: -1px;\n bottom: -1px;\n left: -1px;\n content: "";\n z-index: 999;\n border: 1px solid var(--brandcolor);\n pointer-events: none;\n opacity: 0;\n transition: all 0.2s ease-in-out;\n }\n\n .gh-portal-plans-container.disabled .gh-portal-plan-section:not(.checked):hover::before {\n opacity: 0;\n }\n\n .gh-portal-plans-container.hide-checkbox .gh-portal-plan-section {\n padding-top: 12px;\n padding-bottom: 12px;\n }\n\n .gh-portal-plan-current {\n display: block;\n font-size: 1.25rem;\n letter-spacing: 0.2px;\n line-height: 1.25em;\n color: var(--brandcolor);\n margin: 3px 0 -2px;\n }\n\n .gh-portal-plans-container:not(.empty-selected-benefits) {\n border-bottom-left-radius: 0;\n border-bottom-right-radius: 0;\n }\n\n .gh-portal-plans-container.is-change-plan {\n border-radius: 0 0 5px 5px;\n border-top: none;\n }\n\n .gh-portal-plans-container.is-change-plan .gh-portal-plan-section {\n min-height: 90px;\n }\n\n .gh-portal-plan-product {\n border: 1px solid var(--grey11);\n border-radius: 5px;\n }\n\n .gh-portal-plan-product:not(:last-of-type) {\n margin-bottom: 20px;\n }\n\n .gh-portal-plan-productname {\n border-radius: 5px 5px 0 0;\n padding: 2px 10px;\n font-size: 1.25rem;\n letter-spacing: 0.3px;\n text-transform: uppercase;\n font-weight: 600;\n border-bottom: 1px solid var(--grey12);\n }\n\n .gh-portal-accountplans-main .gh-portal-plan-section:hover:not(.checked) {\n background: var(--grey14);\n }\n\n .gh-portal-accountplans-main .gh-portal-plan-section:last-of-type {\n border-radius: 0 0 5px 5px;\n }\n\n .gh-portal-singleproduct-benefits {\n display: flex;\n flex-direction: column;\n border: 1px solid var(--grey11);\n border-top: none !important;\n margin: 0 0 4px !important;\n padding: 16px 24px 12px !important;\n border-radius: 0 0 5px 5px;\n }\n\n .gh-portal-singleproduct-benefits.onlyfree {\n border-top: 1px solid var(--grey11) !important;\n border-radius: 5px;\n margin-top: 30px !important;\n }\n\n .gh-portal-singleproduct-benefits .gh-portal-product-benefit {\n padding: 0 8px;\n }\n\n .gh-portal-singleproduct-benefits .gh-portal-product-benefit:last-of-type {\n margin-bottom: 16px;\n }\n\n .gh-portal-singleproduct-benefits.onlyfree .gh-portal-product-benefit:last-of-type {\n margin-bottom: 4px;\n }\n\n .gh-portal-singleproduct-benefits:not(.no-benefits) .gh-portal-product-description {\n border-bottom: 1px solid var(--grey12);\n padding-bottom: 20px;\n margin-bottom: 16px;\n }\n'+function(e){return e.site,'\n .gh-portal-products {\n display: flex;\n flex-direction: column;\n align-items: center;\n }\n\n .gh-portal-products-pricetoggle {\n position: relative;\n display: flex;\n background: #F3F3F3;\n width: 100%;\n border-radius: 999px;\n padding: 4px;\n height: 44px;\n margin: 0 0 40px;\n }\n\n .gh-portal-products-pricetoggle:before {\n position: absolute;\n content: "";\n display: block;\n width: 50%;\n top: 4px;\n bottom: 4px;\n right: 4px;\n background: #fff;\n box-shadow: 0px 1px 3px rgba(0, 0, 0, 0.08);\n border-radius: 999px;\n transition: all 0.15s ease-in-out;\n }\n\n .gh-portal-products-pricetoggle.left:before {\n transform: translateX(calc(-100% + 8px));\n }\n\n .gh-portal-products-pricetoggle .gh-portal-btn {\n border: 0;\n height: 100% !important;\n width: 50%;\n border-radius: 999px;\n color: var(--grey7);\n background: transparent;\n font-size: 1.5rem;\n }\n\n .gh-portal-products-pricetoggle .gh-portal-btn.active {\n border: 0;\n height: 100%;\n width: 50%;\n color: var(--grey0);\n /*background: white;\n box-shadow: 0px 1px 3px rgba(0, 0, 0, 0.08);*/\n }\n\n .gh-portal-priceoption-label {\n font-size: 1.4rem;\n font-weight: 400;\n letter-spacing: 0.3px;\n margin: 0 6px;\n min-width: 180px;\n }\n\n .gh-portal-priceoption-label.monthly {\n text-align: right;\n }\n\n .gh-portal-priceoption-label.inactive {\n color: var(--grey8);\n }\n\n .gh-portal-products-grid {\n display: flex;\n flex-wrap: wrap;\n align-items: stretch;\n justify-content: center;\n gap: 40px;\n margin: 0 auto;\n padding: 0;\n width: 100%;\n }\n\n .gh-portal-product-card {\n flex: 1;\n max-width: 420px;\n min-width: 320px;\n position: relative;\n display: flex;\n flex-direction: column;\n align-items: flex-start;\n justify-content: stretch;\n background: white;\n padding: 32px;\n border-radius: 7px;\n border: 1px solid var(--grey11);\n min-height: 200px;\n transition: border-color 0.25s ease-in-out;\n }\n\n .gh-portal-product-card.top {\n border-bottom: none;\n border-radius: 7px 7px 0 0;\n padding-bottom: 0;\n }\n\n .gh-portal-product-card.bottom {\n border-top: none;\n border-radius: 0 0 7px 7px;\n padding-top: 0;\n }\n\n .gh-portal-product-card:not(.disabled):hover {\n border-color: var(--grey9);\n }\n\n .gh-portal-product-card.checked::before {\n position: absolute;\n display: block;\n top: -2px;\n right: -2px;\n bottom: -2px;\n left: -2px;\n content: "";\n z-index: 999;\n border: 0px solid var(--brandcolor);\n pointer-events: none;\n border-radius: 7px;\n }\n\n .gh-portal-product-card-header {\n width: 100%;\n min-height: 56px;\n }\n\n .gh-portal-product-card-name-trial {\n display: flex;\n align-items: center;\n }\n\n .gh-portal-product-card-name-trial .gh-portal-discount-label {\n margin-top: -4px;\n }\n\n .gh-portal-product-card-details {\n flex: 1;\n display: flex;\n flex-direction: column;\n width: 100%;\n }\n\n .gh-portal-product-name {\n font-size: 1.8rem;\n font-weight: 600;\n line-height: 1.3em;\n letter-spacing: 0px;\n margin-top: -4px;\n word-break: break-word;\n width: 100%;\n color: var(--brandcolor);\n }\n\n .gh-portal-discount-label-trial {\n color: var(--brandcolor);\n font-weight: 600;\n font-size: 1.3rem;\n line-height: 1;\n margin-top: 4px;\n }\n\n .gh-portal-discount-label {\n position: relative;\n font-size: 1.25rem;\n line-height: 1em;\n font-weight: 600;\n letter-spacing: 0.3px;\n color: var(--grey0);\n padding: 6px 9px;\n text-align: center;\n white-space: nowrap;\n border-radius: 999px;\n margin-right: -4px;\n max-height: 24.5px;\n }\n\n .gh-portal-discount-label:before {\n position: absolute;\n content: "";\n display: block;\n background: var(--brandcolor);\n top: 0;\n right: 0;\n bottom: 0;\n left: 0;\n border-radius: 999px;\n opacity: 0.2;\n }\n\n .gh-portal-product-card-price-trial {\n display: flex;\n flex-direction: row;\n align-items: flex-end;\n justify-content: space-between;\n flex-wrap: wrap;\n row-gap: 10px;\n column-gap: 4px;\n width: 100%;\n }\n\n .gh-portal-product-card-pricecontainer {\n display: flex;\n flex-direction: column;\n align-items: flex-start;\n width: 100%;\n margin-top: 16px;\n }\n\n .gh-portal-product-price {\n display: flex;\n justify-content: center;\n color: var(--grey0);\n }\n\n .gh-portal-product-price .currency-sign {\n align-self: flex-start;\n font-size: 2.7rem;\n font-weight: 700;\n line-height: 1.135em;\n }\n\n .gh-portal-product-price .currency-sign.long {\n margin-right: 5px;\n }\n\n .gh-portal-product-price .amount {\n font-size: 3.5rem;\n font-weight: 700;\n line-height: 1em;\n letter-spacing: -1.3px;\n color: var(--grey0);\n }\n\n .gh-portal-product-price .amount.trial-duration {\n letter-spacing: -0.022em;\n }\n\n .gh-portal-product-price .billing-period {\n align-self: flex-end;\n font-size: 1.5rem;\n line-height: 1.6em;\n color: var(--grey5);\n letter-spacing: 0.3px;\n margin-left: 5px;\n }\n\n .gh-portal-product-alternative-price {\n font-size: 1.3rem;\n line-height: 1.6em;\n color: var(--grey8);\n letter-spacing: 0.3px;\n display: none;\n }\n\n .after-trial-amount {\n display: block;\n font-size: 1.5rem;\n color: var(--grey5);\n margin-top: 6px;\n margin-bottom: 6px;\n line-height: 1;\n }\n\n .gh-portal-product-card-detaildata {\n flex: 1;\n }\n\n .gh-portal-product-description {\n font-size: 1.55rem;\n font-weight: 600;\n line-height: 1.4em;\n width: 100%;\n margin-top: 16px;\n }\n\n .gh-portal-product-benefits {\n font-size: 1.5rem;\n line-height: 1.4em;\n width: 100%;\n margin-top: 16px;\n }\n\n .gh-portal-product-benefit {\n display: flex;\n align-items: flex-start;\n margin-bottom: 10px;\n }\n\n .gh-portal-benefit-checkmark {\n width: 14px;\n height: 14px;\n min-width: 14px;\n margin: 3px 10px 0 0;\n overflow: visible;\n }\n\n .gh-portal-benefit-checkmark polyline,\n .gh-portal-benefit-checkmark g {\n stroke-width: 3px;\n }\n\n .gh-portal-products-grid.change-plan {\n padding: 0;\n }\n\n .gh-portal-btn-product {\n position: sticky;\n bottom: 0;\n display: flex;\n flex-direction: row;\n align-items: flex-end;\n width: 100%;\n justify-self: flex-end;\n padding: 40px 0 32px;\n margin-bottom: -32px;\n /*background: rgb(255,255,255);\n background: linear-gradient(0deg, rgba(255,255,255,1) 75%, rgba(255,255,255,0) 100%);*/\n background: transparent;\n }\n\n .gh-portal-btn-product::before {\n position: absolute;\n content: "";\n display: block;\n top: -16px;\n left: 0;\n right: 0;\n bottom: 0;\n background: linear-gradient(0deg, rgba(255,255,255,1) 60%, rgba(255,255,255,0) 100%);\n z-index: 800;\n }\n\n .gh-portal-btn-product .gh-portal-btn {\n background: var(--brandcolor);\n color: #fff;\n border: none;\n width: 100%;\n z-index: 900;\n }\n\n .gh-portal-btn-product .gh-portal-btn:hover {\n opacity: 0.9;\n }\n\n .gh-portal-current-plan {\n display: flex;\n align-items: center;\n justify-content: center;\n text-align: center;\n white-space: nowrap;\n width: 100%;\n height: 44px;\n border-radius: 5px;\n color: var(--grey5);\n font-size: 1.4rem;\n font-weight: 500;\n line-height: 1em;\n letter-spacing: 0.2px;\n font-weight: 500;\n background: #f0f0f0;\n z-index: 900;\n }\n\n .gh-portal-product-card.only-free {\n margin: 0 0 16px;\n min-height: unset;\n }\n\n .gh-portal-product-card.only-free .gh-portal-product-card-header {\n min-height: unset;\n }\n\n @media (max-width: 670px) {\n .gh-portal-products-grid {\n grid-template-columns: unset;\n grid-gap: 20px;\n width: 100%;\n max-width: 440px;\n }\n\n .gh-portal-priceoption-label {\n font-size: 1.25rem;\n }\n\n .gh-portal-products-priceswitch .gh-portal-discount-label {\n display: none;\n }\n\n .gh-portal-products-priceswitch {\n padding-top: 18px;\n }\n\n .gh-portal-product-card {\n min-height: unset;\n }\n\n .gh-portal-singleproduct-benefits .gh-portal-product-description {\n text-align: center;\n }\n\n .gh-portal-product-benefit:last-of-type {\n margin-bottom: 0;\n }\n }\n\n @media (max-width: 480px) {\n .gh-portal-product-price .amount {\n font-size: 3.4rem;\n }\n\n .gh-portal-product-card {\n min-width: unset;\n }\n\n .gh-portal-btn-product {\n position: static;\n }\n\n .gh-portal-btn-product::before {\n display: none;\n }\n }\n\n @media (max-width: 370px) {\n .gh-portal-product-price .currency-sign {\n font-size: 1.8rem;\n }\n\n .gh-portal-product-price .amount {\n font-size: 2.8rem;\n }\n }\n\n\n /* Upgrade and change plan*/\n .gh-portal-upgrade-product {\n margin-top: -70px;\n padding-top: 60px;\n }\n\n .gh-portal-upgrade-product .gh-portal-products-grid {\n grid-template-columns: unset;\n grid-gap: 20px;\n width: 100%;\n }\n\n .gh-portal-upgrade-product .gh-portal-product-card .gh-portal-plan-current {\n display: inline-block;\n position: relative;\n padding: 2px 8px;\n font-size: 1.2rem;\n letter-spacing: 0.3px;\n text-transform: uppercase;\n margin-bottom: 4px;\n }\n\n .gh-portal-upgrade-product .gh-portal-product-card .gh-portal-plan-current::before {\n position: absolute;\n content: "";\n top: 0;\n right: 0;\n bottom: 0;\n left: 0;\n border-radius: 999px;\n background: var(--brandcolor);\n opacity: 0.15;\n }\n\n @media (max-width: 880px) {\n .gh-portal-products-grid {\n flex-direction: column;\n margin: 0 auto;\n max-width: 420px;\n }\n\n .gh-portal-product-card-header {\n min-height: unset;\n }\n }\n '}({site:t})+'\n .gh-portal-for-switch label,\n .gh-portal-for-switch .container {\n position: relative;\n display: inline-block;\n width: 44px !important;\n height: 26px !important;\n cursor: pointer;\n }\n\n .gh-portal-for-switch label p,\n .gh-portal-for-switch .container p {\n overflow: auto;\n color: var(--grey0);\n font-weight: normal;\n }\n\n .gh-portal-for-switch input {\n opacity: 0;\n width: 0;\n height: 0;\n }\n\n .gh-portal-for-switch .input-toggle-component {\n position: absolute;\n top: 0;\n left: 0;\n right: 0;\n bottom: 0;\n background: #e9e9e9;\n transition: .3s;\n width: 44px !important;\n height: 26px !important;\n border-radius: 999px;\n transition: background 0.15s ease-in-out, border-color 0.15s ease-in-out;\n cursor: pointer;\n }\n\n .gh-portal-for-switch label:hover input:not(:checked) + .input-toggle-component,\n .gh-portal-for-switch .container:hover input:not(:checked) + .input-toggle-component {\n border-color: var(--grey9);\n }\n\n .gh-portal-for-switch .input-toggle-component:before {\n position: absolute;\n content: "";\n top: 3px !important;\n left: 3px !important;\n height: 20px !important;\n width: 20px !important;\n background-color: white;\n transition: .3s;\n border-radius: 999px;\n }\n\n .gh-portal-for-switch input:checked + .input-toggle-component {\n background: var(--brandcolor);\n border-color: transparent;\n }\n\n .gh-portal-for-switch input:checked + .input-toggle-component:before {\n transform: translateX(18px);\n box-shadow: none;\n }\n\n .gh-portal-for-switch .container {\n width: 38px !important;\n height: 22px !important;\n }\n\n .gh-portal-btn-main {\n box-shadow: none;\n position: relative;\n border: none;\n }\n\n .gh-portal-btn-main:hover,\n .gh-portal-btn-main:focus {\n box-shadow: none;\n border: none;\n }\n\n .gh-portal-btn-primary:hover,\n .gh-portal-btn-primary:focus {\n opacity: 0.92 !important;\n }\n\n .gh-portal-btn-primary:disabled:hover::before {\n display: none;\n }\n\n .gh-portal-btn-destructive:not(:disabled):hover {\n color: var(--red);\n border-color: var(--red);\n }\n\n .gh-portal-btn-text {\n padding: 0;\n font-weight: 500;\n height: unset;\n border: none;\n box-shadow: none;\n }\n\n .gh-portal-loadingicon {\n position: absolute;\n left: 50%;\n display: inline-block;\n margin-left: -19px;\n height: 31px;\n }\n\n .gh-portal-loadingicon path,\n .gh-portal-loadingicon rect {\n fill: #fff;\n }\n\n .gh-portal-loadingicon.dark path,\n .gh-portal-loadingicon.dark rect {\n fill: #1d1d1d;\n }\n\n .gh-portal-btn-back,\n .gh-portal-btn-back:hover {\n box-shadow: none;\n position: relative;\n height: unset;\n min-width: unset;\n position: fixed;\n top: 29px;\n left: 25px;\n background: none;\n padding: 8px;\n margin: 0;\n box-shadow: none;\n color: var(--grey3);\n border: none;\n z-index: 10000;\n }\n\n .gh-portal-btn-back:hover {\n color: var(--grey1);\n transform: translateX(-4px);\n }\n\n .gh-portal-btn-back svg {\n width: 17px;\n height: 17px;\n margin-top: 1px;\n margin-right: 2px;\n }\n'+Gn+"\n .gh-portal-icon-envelope {\n width: 44px;\n margin: 12px 0 10px;\n }\n\n .gh-portal-inbox-notification {\n display: flex;\n flex-direction: column;\n align-items: center;\n }\n\n .gh-portal-inbox-notification p {\n text-align: center;\n margin-bottom: 30px;\n }\n\n.gh-portal-back-sitetitle {\n position: absolute;\n top: 35px;\n left: 32px;\n}\n\n.gh-portal-back-sitetitle .gh-portal-btn {\n padding: 0;\n border: 0;\n font-size: 1.5rem;\n height: auto;\n line-height: 1em;\n color: var(--grey1);\n}\n\n.gh-portal-popup-wrapper:not(.full-size) .gh-portal-back-sitetitle,\n.gh-portal-popup-wrapper.preview .gh-portal-back-sitetitle {\n display: none;\n}\n\n.gh-portal-signup-logo {\n position: relative;\n display: block;\n background-position: 50%;\n background-size: cover;\n border-radius: 2px;\n width: 60px;\n height: 60px;\n margin: 12px 0 10px;\n}\n\n.gh-portal-signup-header,\n.gh-portal-signin-header {\n display: flex;\n flex-direction: column;\n align-items: center;\n padding: 0 32px;\n margin-bottom: 32px;\n}\n\n.gh-portal-popup-wrapper.full-size .gh-portal-signup-header {\n margin-top: 32px;\n}\n\n.gh-portal-signup-header .gh-portal-main-title,\n.gh-portal-signin-header .gh-portal-main-title {\n margin-top: 12px;\n}\n\n.gh-portal-signup-logo + .gh-portal-main-title {\n margin: 4px 0 0;\n}\n\n.gh-portal-signup-header .gh-portal-main-subtitle {\n font-size: 1.5rem;\n text-align: center;\n line-height: 1.45em;\n margin: 4px 0 0;\n color: var(--grey3);\n}\n\n.gh-portal-logged-out-form-container {\n width: 100%;\n max-width: 420px;\n margin: 0 auto;\n}\n\n.signup .gh-portal-input-section:last-of-type {\n margin-bottom: 40px;\n}\n\n.gh-portal-signup-message {\n display: flex;\n justify-content: center;\n color: var(--grey4);\n font-size: 1.5rem;\n margin: 16px 0 0;\n}\n\n.gh-portal-signup-message,\n.gh-portal-signup-message * {\n z-index: 9999;\n}\n\n.full-size .gh-portal-signup-message {\n margin: 24px 0 40px;\n}\n\n@media (max-width: 480px) {\n .preview .gh-portal-products + .gh-portal-signup-message {\n margin-bottom: 40px;\n }\n}\n\n.gh-portal-signup-message button {\n font-size: 1.4rem;\n font-weight: 600;\n margin-left: 4px !important;\n}\n\n.gh-portal-signup-message button span {\n display: inline-block;\n padding-bottom: 2px;\n margin-bottom: -2px;\n}\n\n.gh-portal-content.signup.invite-only {\n background: none;\n}\n\nfooter.gh-portal-signup-footer,\nfooter.gh-portal-signin-footer {\n display: flex;\n flex-direction: column;\n align-items: center;\n position: relative;\n padding-top: 24px;\n height: unset;\n}\n\n.gh-portal-content.signup,\n.gh-portal-content.signin {\n max-height: unset !important;\n padding-bottom: 0;\n}\n\n.gh-portal-content.signin {\n padding-bottom: 4px;\n}\n\n.gh-portal-content.signup .gh-portal-section {\n margin-bottom: 0;\n}\n\n.gh-portal-content.signup.single-field {\n margin-bottom: 4px;\n}\n\n.gh-portal-content.signup.single-field .gh-portal-input,\n.gh-portal-content.signin .gh-portal-input {\n margin-bottom: 8px;\n}\n\n.gh-portal-content.signup.single-field + .gh-portal-signup-footer,\nfooter.gh-portal-signin-footer {\n padding-top: 12px;\n}\n\n.gh-portal-content.signin .gh-portal-section {\n margin-bottom: 0;\n}\n\nfooter.gh-portal-signup-footer.invite-only {\n height: unset;\n}\n\nfooter.gh-portal-signup-footer.invite-only .gh-portal-signup-message {\n margin-top: 0;\n}\n\n.gh-portal-invite-only-notification {\n margin: 8px 32px 24px;\n padding: 0;\n text-align: center;\n color: var(--grey2);\n}\n\n.gh-portal-icon-invitation {\n width: 44px;\n height: 44px;\n margin: 12px 0 2px;\n}\n\n.gh-portal-popup-wrapper.full-size .gh-portal-popup-container.preview footer.gh-portal-signup-footer {\n padding-bottom: 32px;\n}\n\n.gh-portal-invite-only-notification + .gh-portal-signup-message {\n margin-bottom: 12px;\n}\n\n.gh-portal-free-trial-notification {\n max-width: 480px;\n text-align: center;\n margin: 24px auto;\n color: var(--grey4);\n}\n\n@media (min-width: 480px) {\n\n}\n\n@media (max-width: 480px) {\n .gh-portal-signup-logo {\n width: 48px;\n height: 48px;\n }\n}\n\n@media (min-width: 480px) and (max-width: 820px) {\n .gh-portal-powered.outside {\n left: 50%;\n transform: translateX(-50%);\n }\n}\n"+function(e){return e.site,"\n.gh-portal-offer {\n padding-bottom: 0;\n overflow: unset;\n max-height: unset;\n}\n\n.gh-portal-offer-container {\n display: flex;\n flex-direction: column;\n}\n\n.gh-portal-plans-container.offer {\n justify-content: space-between;\n border-color: var(--grey12);\n border-top: none;\n border-top-left-radius: 0;\n border-top-right-radius: 0;\n padding: 12px 16px;\n font-size: 1.3rem;\n}\n\n.gh-portal-offer-bar {\n position: relative;\n padding: 26px 28px 28px;\n margin-bottom: 24px;\n /*border: 1px dashed var(--brandcolor);*/\n background-image: url(\"data:image/svg+xml,%3csvg width='100%25' height='99.9%25' xmlns='http://www.w3.org/2000/svg'%3e%3crect width='100%25' height='100%25' fill='none' stroke='%23C3C3C3' stroke-width='3' stroke-dasharray='3%2c 9' stroke-dashoffset='0' stroke-linecap='square'/%3e%3c/svg%3e\");\n border-radius: 6px;\n}\n\n.gh-portal-offer-title {\n display: flex;\n justify-content: space-between;\n align-items: center;\n}\n\n.gh-portal-offer-title h4 {\n font-size: 1.8rem;\n margin: 0 110px 0 0;\n width: 100%;\n}\n\n.gh-portal-offer-title h4.placeholder {\n opacity: 0.4;\n}\n\n.gh-portal-offer-bar .gh-portal-discount-label {\n position: absolute;\n top: 23px;\n right: 25px;\n}\n\n.gh-portal-offer-bar p {\n padding-bottom: 0;\n margin: 12px 0 0;\n}\n\n.gh-portal-offer-title h4 + p {\n margin: 12px 0 0;\n}\n\n.gh-portal-offer-details .gh-portal-plan-name,\n.gh-portal-offer-details p {\n margin-right: 8px;\n}\n\n.gh-portal-offer .footnote {\n font-size: 1.35rem;\n color: var(--grey8);\n margin: 4px 0 0;\n}\n\n.offer .gh-portal-product-card {\n max-width: unset;\n min-height: 0;\n}\n\n.offer .gh-portal-product-card .gh-portal-product-card-pricecontainer:not(.offer-type-trial) {\n margin-top: 0px;\n}\n\n.offer .gh-portal-product-card-header {\n display: flex;\n flex-direction: column;\n align-items: flex-start;\n}\n\n.gh-portal-offer-oldprice {\n display: flex;\n position: relative;\n font-size: 1.8rem;\n font-weight: 300;\n color: var(--grey8);\n line-height: 1;\n white-space: nowrap;\n margin: 16px 0 4px;\n}\n\n.gh-portal-offer-oldprice:after {\n position: absolute;\n display: block;\n content: \"\";\n left: 0;\n top: 50%;\n right: 0;\n height: 1px;\n background: var(--grey8);\n}\n\n.gh-portal-offer-details p {\n margin-bottom: 12px;\n}\n\n.offer .after-trial-amount {\n margin-bottom: 0;\n}\n\n.offer .trial-duration {\n margin-top: 16px;\n}\n\n.gh-portal-cancel {\n white-space: nowrap;\n}\n "}({site:t})+'\n .gh-portal-popupnotification {\n position: absolute;\n top: 8px;\n left: 8px;\n right: 8px;\n padding: 12px;\n background: var(--grey2);\n z-index: 11000;\n border-radius: 5px;\n font-size: 1.5rem;\n box-shadow: 0px 0.8151839971542358px 0.8151839971542358px 0px rgba(0,0,0,0.01),\n 0px 2.2538793087005615px 2.2538793087005615px 0px rgba(0,0,0,0.02),\n 0px 5.426473140716553px 5.426473140716553px 0px rgba(0,0,0,0.03),\n 0px 18px 18px 0px rgba(0,0,0,0.04);\n animation: popupnotification-slidein 0.3s ease-in-out;\n }\n\n .gh-portal-popupnotification.slideout {\n animation: popupnotification-slideout 0.48s ease-in;\n }\n\n .gh-portal-popupnotification p {\n color: var(--white);\n margin: 0;\n padding: 0 20px;\n font-size: 1.5rem;\n line-height: 1.5em;\n letter-spacing: 0.2px;\n text-align: center;\n }\n\n .gh-portal-popupnotification a {\n color: var(--white);\n }\n\n .gh-portal-popupnotification-icon {\n position: absolute;\n top: 12px;\n left: 12px;\n width: 20px;\n height: 20px;\n }\n\n .gh-portal-popupnotification-icon.success {\n color: var(--green);\n }\n\n .gh-portal-popupnotification-icon.error {\n color: #FF2828;\n }\n\n .gh-portal-popupnotification .closeicon {\n position: absolute;\n top: 3px;\n bottom: 0;\n right: 3px;\n color: var(--white);\n cursor: pointer;\n width: 16px;\n height: 16px;\n padding: 12px;\n transition: all 0.15s ease-in-out forwards;\n opacity: 0.8;\n }\n\n .gh-portal-popupnotification .closeicon:hover {\n opacity: 1.0;\n }\n\n @keyframes popupnotification-slidein {\n 0% { \n transform: translateY(-10px); \n opacity: 0;\n }\n 60% { transform: translateY(2px); }\n 100% { \n transform: translateY(0); \n opacity: 1.0;\n }\n }\n\n @keyframes popupnotification-slideout {\n 0% { \n transform: translateY(0);\n opacity: 1.0;\n }\n 40% { transform: translateY(2px); }\n 100% { \n transform: translateY(-10px);\n opacity: 0;\n }\n }\n\n@media (max-width: 1440px) {\n .gh-portal-popup-container:not(.full-size):not(.preview) {\n width: 460px;\n }\n\n .gh-portal-input {\n height: 42px;\n margin-bottom: 16px;\n }\n\n button[class="gh-portal-btn"],\n .gh-portal-btn-main,\n .gh-portal-btn-primary {\n height: 42px;\n }\n\n .gh-portal-product-price .amount {\n font-size: 32px;\n letter-spacing: -0.022em;\n }\n}\n\n@media (max-width: 960px) {\n .gh-portal-powered {\n display: flex;\n position: relative;\n bottom: unset;\n left: unset;\n background: var(--white);\n justify-content: center;\n width: 100%;\n padding-top: 32px;\n }\n}\n\n@media (min-width: 520px) {\n .gh-portal-popup-wrapper.full-size .gh-portal-popup-container.preview {\n box-shadow:\n 0 0 0 1px rgba(0,0,0,0.02),\n 0 2.8px 2.2px rgba(0, 0, 0, 0.02),\n 0 6.7px 5.3px rgba(0, 0, 0, 0.028),\n 0 12.5px 10px rgba(0, 0, 0, 0.035),\n 0 22.3px 17.9px rgba(0, 0, 0, 0.042),\n 0 41.8px 33.4px rgba(0, 0, 0, 0.05),\n 0 100px 80px rgba(0, 0, 0, 0.07);\n animation: none;\n margin: 32px;\n padding: 32px 32px 0;\n width: calc(100vw - 64px);\n height: calc(100vh - 160px);\n min-height: unset;\n border-radius: 12px;\n overflow: auto;\n justify-content: flex-start;\n }\n}\n\n@media (max-width: 480px) {\n .gh-portal-detail-header {\n margin-top: 4px;\n }\n\n .gh-portal-popup-wrapper {\n height: 100%;\n padding: 0;\n display: flex;\n flex-direction: column;\n align-items: center;\n justify-content: space-between;\n background: var(--white);\n overflow-y: auto;\n }\n\n .gh-portal-popup-container {\n width: 100% !important;\n border-radius: 0;\n overflow: unset;\n animation: popup-mobile 0.25s ease-in-out;\n box-shadow: none !important;\n transform: translateY(0);\n padding: 28px !important;\n }\n\n .gh-portal-popup-container.full-size {\n justify-content: flex-start;\n }\n\n .gh-portal-popup-wrapper.account-home,\n .gh-portal-popup-container.account-home {\n background: var(--grey13);\n }\n\n .gh-portal-popup-wrapper.full-size .gh-portal-closeicon, \n .gh-portal-popup-container.full-size .gh-portal-closeicon {\n width: 16px;\n height: 16px;\n }\n\n /* Small width preview in Admin */\n .gh-portal-popup-wrapper.preview:not(.full-size) footer.gh-portal-signup-footer, \n .gh-portal-popup-wrapper.preview:not(.full-size) footer.gh-portal-signin-footer {\n padding-bottom: 32px;\n }\n\n .gh-portal-popup-container.preview:not(.full-size) {\n max-height: 660px;\n margin-bottom: 0;\n }\n\n .gh-portal-popup-container.preview:not(.full-size).offer {\n max-height: 860px;\n padding-bottom: 0 !important;\n }\n\n .gh-portal-popup-wrapper.preview.full-size {\n height: unset;\n max-height: 660px;\n }\n\n .gh-portal-popup-container.preview.full-size {\n max-height: 660px;\n margin-bottom: 0;\n }\n \n .preview .gh-portal-invite-only-notification + .gh-portal-signup-message {\n margin-bottom: 16px;\n }\n\n .preview .gh-portal-btn-container.sticky {\n margin-bottom: 32px;\n padding-bottom: 0;\n }\n\n .gh-portal-powered {\n padding-top: 12px;\n padding-bottom: 24px;\n }\n}\n\n@media (max-width: 390px) {\n .gh-portal-popup-container:not(.account-plan) .gh-portal-detail-header .gh-portal-main-title {\n font-size: 2.1rem;\n margin-top: 1px;\n padding: 0 74px;\n text-align: center;\n }\n\n .gh-portal-input {\n margin-bottom: 16px;\n }\n\n .gh-portal-signup-header,\n .gh-portal-signin-header {\n padding-bottom: 16px;\n }\n}\n\n@media (min-width: 480px) and (max-height: 880px) {\n .gh-portal-popup-wrapper {\n padding: 4vmin 0 0;\n }\n}\n\n@keyframes popup-mobile {\n 0% {\n opacity: 0;\n }\n 100%{\n opacity: 1.0;\n }\n}\n\n/* Prevent zoom */\n@media (hover:none) {\n select, textarea, input[type="text"], input[type="text"], input[type="password"],\n input[type="datetime"], input[type="datetime-local"],\n input[type="date"], input[type="month"], input[type="time"],\n input[type="week"], input[type="number"], input[type="email"],\n input[type="url"] {\n font-size: 16px !important;\n }\n}\n\n.gh-portal-popup-wrapper.multiple-products .gh-portal-input-section {\n max-width: 420px;\n margin: 0 auto;\n}\n\n/* Multiple product signup/signin-only modifications! */\n.gh-portal-popup-wrapper.multiple-products {\n background: #fff;\n box-shadow: 0 3.8px 2.2px rgba(0, 0, 0, 0.028), 0 9.2px 5.3px rgba(0, 0, 0, 0.04), 0 17.3px 10px rgba(0, 0, 0, 0.05), 0 30.8px 17.9px rgba(0, 0, 0, 0.06), 0 57.7px 33.4px rgba(0, 0, 0, 0.072), 0 138px 80px rgba(0, 0, 0, 0.1);\n padding: 0;\n border-radius: 5px;\n height: calc(100vh - 64px);\n max-width: calc(100vw - 64px);\n}\n\n.gh-portal-popup-wrapper.multiple-products.signup {\n overflow-y: scroll;\n overflow-x: clip;\n margin: 32px auto !important;\n padding-right: 0 !important; /* Override scrollbar hiding */\n}\n\n.gh-portal-popup-wrapper.multiple-products.signin {\n margin: 10vmin auto;\n max-width: 480px;\n height: unset;\n}\n\n.gh-portal-popup-wrapper.multiple-products.preview {\n height: calc(100vh - 150px) !important;\n}\n\n.gh-portal-popup-wrapper.multiple-products .gh-portal-popup-container {\n align-items: center;\n width: 100% !important;\n box-shadow: none !important;\n animation: fadein 0.35s ease-in-out;\n padding: 1vmin 0;\n transform: translateY(0px);\n margin-bottom: 0;\n}\n\n.gh-portal-popup-wrapper.multiple-products.signup .gh-portal-popup-container {\n min-height: calc(100vh - 64px);\n position: unset;\n}\n\n.gh-portal-popup-wrapper.multiple-products .gh-portal-powered {\n position: relative;\n display: flex;\n flex: 1;\n align-items: flex-end;\n justify-content: flex-start;\n bottom: unset;\n left: unset;\n width: 100%;\n z-index: 10000;\n padding-bottom: 32px;\n}\n\n@media (max-width: 670px) {\n .gh-portal-popup-wrapper.multiple-products .gh-portal-powered {\n justify-content: center;\n }\n}\n\n.gh-portal-popup-wrapper.multiple-products .gh-portal-content {\n position: unset;\n overflow-y: visible;\n max-height: unset !important;\n}\n\n@media (max-width: 960px) {\n .gh-portal-popup-wrapper.multiple-products.signup:not(.preview) {\n margin: 20px !important;\n height: 100%;\n }\n}\n\n@media (max-width: 480px) {\n .gh-portal-popup-wrapper.multiple-products {\n margin: 0 !important;\n max-width: unset !important;\n max-height: 100% !important;\n height: 100% !important;\n border-radius: 0px;\n box-shadow: none;\n }\n\n .gh-portal-popup-wrapper.multiple-products.signup:not(.preview) {\n margin: 0 !important;\n }\n\n .gh-portal-popup-wrapper.multiple-products.preview {\n height: unset !important;\n margin: 0 !important;\n }\n\n .gh-portal-popup-wrapper.multiple-products:not(.dev) .gh-portal-popup-container.preview {\n max-height: 640px;\n }\n}\n\n.gh-portal-popup-container.preview * {\n pointer-events: none !important;\n}\n\n.gh-portal-unsubscribe-logo {\n width: 60px;\n height: 60px;\n border-radius: 2px;\n margin-top: 12px;\n margin-bottom: 6px;\n}\n\n@media (max-width: 480px) {\n .gh-portal-unsubscribe-logo {\n width: 48px;\n height: 48px;\n }\n}\n\n.gh-portal-unsubscribe .gh-portal-main-title {\n margin-bottom: 16px;\n font-size: 2.6rem;\n}\n\n.gh-portal-unsubscribe p {\n margin-bottom: 16px;\n}\n\n.gh-portal-unsubscribe p:last-of-type {\n margin-bottom: 0;\n}\n\n.gh-portal-btn-inline {\n display: inline-block;\n margin-left: 4px;\n font-size: 1.5rem;\n font-weight: 600;\n cursor: pointer;\n}\n\n.gh-portal-toggle-checked {\n transition: all 0.3s;\n transition-delay: 2s;\n}\n\n.gh-portal-checkmark-container {\n display: flex;\n opacity: 0;\n margin-right: 8px;\n transition: opacity ease 0.4s 0.2s;\n}\n\n.gh-portal-checkmark-show {\n opacity: 1;\n}\n\n.gh-portal-checkmark-icon {\n height: 22px;\n color: #30cf43;\n}\n\n@keyframes fadeIn {\n 0% {\n opacity: 0;\n }\n 100% {\n opacity: 1;\n }\n}\n\n@keyframes fadeOut {\n 0% {\n opacity: 1;\n }\n 100% {\n opacity: 0;\n }\n}\n\n.gh-portal-newsletter-selection {\n animation: 0.5s ease-in-out fadeIn;\n}\n\n.gh-portal-signup {\n animation: 0.5s ease-in-out fadeIn;\n}\n\n.gh-portal-btn-different-plan {\n margin: 0 auto 24px;\n color: var(--grey6);\n font-weight: 400;\n}\n\n.gh-portal-hide {\n display: none;\n}\n';return n}({site:this.context.site}),t="\n :root {\n --brandcolor: ".concat(this.context.brandColor,"\n }\n ")+e;return Object(Hn.jsxs)(Hn.Fragment,{children:[Object(Hn.jsx)("style",{dangerouslySetInnerHTML:{__html:t}}),Object(Hn.jsx)("meta",{name:"viewport",content:"width=device-width, initial-scale=1, maximum-scale=1"})]})}},{key:"renderFrameContainer",value:function(){var e=this,t=this.context,n=t.member,r=t.site,i=t.customSiteUrl,o=hl({member:n}),a=Object(k.a)({},o.frame.common),l="gh-portal-popup-background";return zr(["preview"])&&(o.modalContainer.zIndex="3999997"),zr(["preview"],{customSiteUrl:i})&&!r.disableBackground&&(l+=" preview"),zr(["dev"])&&(l+=" dev"),Object(Hn.jsx)("div",{style:o.modalContainer,children:Object(Hn.jsxs)($n,{style:a,title:"portal-popup",head:this.renderFrameStyles(),children:[Object(Hn.jsx)("div",{className:l,onClick:function(t){return e.handlePopupClose(t)}}),Object(Hn.jsx)(gl,{})]})})}},{key:"render",value:function(){return this.context.showPopup?this.renderFrameContainer():null}}]),n}(fl.Component);vl.contextType=Zn;xl({products:Ol({numOfProducts:1})});function yl(){return((new Date).getTime()/1e3|0).toString(16)+"xxxxxxxxxxxxxxxx".replace(/[x]/g,(function(){return(16*Math.random()|0).toString(16)})).toLowerCase()}function xl(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{},t=e.title,n=void 0===t?"The Blueprint":t,r=e.description,i=void 0===r?"Thoughts, stories and ideas.":r,o=e.logo,a=void 0===o?"https://static.ghost.org/v4.0.0/images/ghost-orb-1.png":o,l=e.icon,s=void 0===l?"https://static.ghost.org/v4.0.0/images/ghost-orb-1.png":l,c=e.url,u=void 0===c?"https://portal.localhost":c,p=e.plans,d=void 0===p?{monthly:5e3,yearly:15e4,currency:"USD"}:p,f=e.products,h=void 0===f?Ol({numOfProducts:1}):f,m=e.portalProducts,g=void 0===m?h.map((function(e){return e.id})):m,b=e.accentColor,v=void 0===b?"#45C32E":b,y=e.portalPlans,x=void 0===y?["free","monthly","yearly"]:y,w=e.allowSelfSignup,j=void 0===w||w,O=e.membersSignupAccess,k=void 0===O?"all":O,_=e.freePriceName,S=void 0===_?"Free":_,P=e.freePriceDescription,E=void 0===P?"Free preview":P,C=e.isStripeConfigured,N=void 0===C||C,T=e.portalButton,I=void 0===T||T,L=e.portalName,M=void 0===L||L,F=e.portalButtonIcon,D=void 0===F?"icon-1":F,z=e.portalButtonSignupText,R=void 0===z?"Subscribe now":z,U=e.portalButtonStyle,A=void 0===U?"icon-and-text":U,B=e.membersSupportAddress,H=void 0===B?"support@example.com":B,q=e.newsletters,$=void 0===q?[]:q,W=e.commentsEnabled;return{title:n,description:i,logo:a,icon:s,accent_color:v,url:u,plans:d,products:h,portal_products:g,allow_self_signup:j,members_signup_access:k,free_price_name:S,free_price_description:E,is_stripe_configured:N,portal_button:I,portal_name:M,portal_plans:x,portal_button_icon:D,portal_button_signup_text:R,portal_button_style:A,members_support_address:H,comments_enabled:!!W,newsletters:$}}function wl(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{},t=e.name,n=void 0===t?"Black Friday":t,r=e.code,i=void 0===r?"black-friday":r,o=e.displayTitle,a=void 0===o?"Black Friday Sale!":o,l=e.displayDescription,s=void 0===l?"Special deal for Black Friday. Subscribe now for only $15 per month and get additional benefits like accessing our podcast.":l,c=e.type,u=void 0===c?"percent":c,p=e.cadence,d=void 0===p?"month":p,f=e.amount,h=void 0===f?50:f,m=e.duration,g=void 0===m?"repeating":m,b=e.durationInMonths,v=void 0===b?null:b,y=e.currencyRestriction,x=void 0!==y&&y,w=e.currency,j=void 0===w?null:w,O=e.status,k=void 0===O?"active":O,_=e.tierId,S=void 0===_?"":_,P=e.tierName,E=void 0===P?"Basic":P;return{id:"offer_".concat(yl()),name:n,code:i,display_title:a,display_description:s,type:u,cadence:d,amount:h,duration:g,duration_in_months:v,currency_restriction:x,currency:j,status:k,tier:{id:"".concat(S),name:E}}}function jl(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{},t=e.name,n=void 0===t?"Jamie Larson":t,r=e.email,i=void 0===r?"jamie@example.com":r,o=e.firstname,a=void 0===o?"Jamie":o,l=e.subscriptions,s=void 0===l?[]:l,c=e.paid,u=void 0!==c&&c,p=e.avatarImage,d=void 0===p?"":p,f=e.subscribed,h=void 0===f||f;return{uuid:"member_".concat(yl()),email:i,name:n,firstname:a,paid:u,subscribed:h,avatar_image:d,subscriptions:s}}function Ol(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{},t=e.numOfProducts,n=void 0===t?3:t,r=[kl({name:"Bronze",description:"Access to all members articles",monthlyPrice:El({interval:"month",amount:700}),yearlyPrice:El({interval:"year",amount:7e3}),numOfBenefits:2}),kl({name:"Silver",description:"Access to all members articles and weekly podcast",monthlyPrice:El({interval:"month",amount:1200}),yearlyPrice:El({interval:"year",amount:12e3}),numOfBenefits:3}),kl({name:"Friends of the Blueprint",description:"Get access to everything and lock in early adopter pricing for life + listen to my podcast",monthlyPrice:El({interval:"month",amount:18e3}),yearlyPrice:El({interval:"year",amount:17e3}),numOfBenefits:4})],i=r.slice(0,n),o=_l({});return[].concat(Ua(i),[o])}function kl(e){var t=e.type,n=void 0===t?"paid":t,r=e.name,i=void 0===r?"Basic":r,o=e.description,a=void 0===o?"":o,l=e.id,s=void 0===l?"product_".concat(yl()):l,c=e.monthlyPrice,u=void 0===c?El():c,p=e.yearlyPrice,d=void 0===p?El({interval:"year"}):p,f=e.numOfBenefits;return{id:s,name:i,description:a,monthlyPrice:"free"===n?null:u,yearlyPrice:"free"===n?null:d,type:n,benefits:Sl({numOfBenefits:void 0===f?2:f})}}function _l(e){var t=e.name,n=void 0===t?"Free tier":t,r=e.description,i=void 0===r?"Free tier description":r,o=e.id,a=void 0===o?"product_".concat(yl()):o,l=e.numOfBenefits;return{id:a,name:n,type:"free",description:i,benefits:Sl({numOfBenefits:void 0===l?2:l})}}function Sl(e){var t=e.numOfBenefits;return[Pl({name:"Limited early adopter pricing"}),Pl({name:"Latest gear reviews"}),Pl({name:"Weekly email newsletter"}),Pl({name:"Listen to my podcast"})].slice(0,t)}function Pl(e){var t=e.id,n=void 0===t?"benefit_".concat(yl()):t,r=e.name;return{id:n,name:void 0===r?"Benefit":r}}function El(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{},t=e.interval,n=void 0===t?"month":t,r=e.amount,i=void 0===r?"month"===n?500:5e3:r,o=e.nickname,a=void 0===o?"month"===n?"Monthly":"Yearly":o,l=e.description,s=void 0===l?null:l,c=e.currency,u=void 0===c?"usd":c,p=e.active,d=void 0===p||p,f=e.id,h=void 0===f?"price_".concat(yl()):f;return{id:h,active:d,nickname:a,currency:u,amount:i,interval:n,description:s,stripe_price_id:"price_".concat(yl()),stripe_product_id:"prod_".concat(yl()),type:"recurring"}}function Cl(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{},t=e.id,n=void 0===t?"sub_".concat(yl()):t,r=e.status,i=void 0===r?"active":r,o=e.currency,a=void 0===o?"USD":o,l=e.interval,s=void 0===l?"year":l,c=e.amount,u=void 0===c?"month"===s?500:5e3:c,p=e.nickname,d=void 0===p?"month"===s?"Monthly":"Yearly":p,f=e.cardLast4,h=void 0===f?"4242":f,m=e.offer,g=void 0===m?Il:m,b=e.priceId,v=void 0===b?"price_".concat(yl()):b,y=e.startDate,x=void 0===y?"2021-10-05T03:18:30.000Z":y,w=e.currentPeriodEnd,j=void 0===w?"2022-10-05T03:18:30.000Z":w,O=e.cancelAtPeriodEnd,k=void 0!==O&&O;return{id:n,customer:{id:"cus_".concat(yl()),name:"Jamie",email:"jamie@example.com"},plan:{id:"price_".concat(yl()),nickname:d,amount:u,interval:s,currency:a},offer:g,status:i,start_date:x,default_payment_card_last4:h,cancel_at_period_end:k,cancellation_reason:null,current_period_end:j,price:{id:"stripe_price_".concat(yl()),price_id:v,nickname:d,amount:u,interval:s,type:"recurring",currency:a,product:{id:"stripe_prod_".concat(yl()),product_id:"prod_".concat(yl())}}}}function Nl(){var e=Ol({numOfProducts:1}),t=e.map((function(e){return e.id}));return xl({products:e,portalPlans:["free","monthly","yearly"],portalProducts:t})}Nl();var Tl,Il=wl({tierId:null===(bl=xl({products:[kl({numOfBenefits:2,type:"free"})]}).products[0])||void 0===bl?void 0:bl.id});jl(),jl({paid:!0,subscriptions:[Cl()]}),jl({paid:!0,subscriptions:[]}),jl({paid:!0,subscriptions:[Cl({amount:0})]}),jl({paid:!0,subscriptions:[Cl({amount:1500,startDate:"2019-05-01T11:42:40.000Z",currentPeriodEnd:"2021-06-05T11:42:40.000Z"})]});Nl();var Ll=[_l({name:"Free",description:"Free tier description which is actually a pretty long description",numOfBenefits:2}),kl({name:"The Blueprint",description:"",monthlyPrice:El({interval:"month",amount:500}),yearlyPrice:El({interval:"year",amount:5e3}),numOfBenefits:3}),kl({name:"Friends of the Blueprint Silver",description:"Access to all members articles and weekly podcast",monthlyPrice:El({interval:"month",amount:1200}),yearlyPrice:El({interval:"year",amount:11e3}),numOfBenefits:4})],Ml=xl({title:"The Blueprint",description:"Thoughts, stories and ideas.",logo:"https://static.ghost.org/v4.0.0/images/ghost-orb-1.png",icon:"https://static.ghost.org/v4.0.0/images/ghost-orb-1.png",accentColor:"#45C32E",url:"https://portal.localhost",plans:{monthly:5e3,yearly:15e4,currency:"USD"},products:Ll,portalProducts:Ll.map((function(e){return e.id})),allowSelfSignup:!0,membersSignupAccess:"all",freePriceName:"Free",freePriceDescription:"Free preview",isStripeConfigured:!0,portalButton:!0,portalName:!0,portalPlans:["free","monthly","yearly"],portalButtonIcon:"icon-1",portalButtonSignupText:"Subscribe now",portalButtonStyle:"icon-and-text",membersSupportAddress:"support@example.com",commentsEnabled:!0,newsletters:[{id:"weekly",name:"Weekly Rundown",description:"Best of last week",subscribe_on_signup:!0,paid:!0},{id:"daily",name:"Daily Brief",description:"One email every day",subscribe_on_signup:!1,paid:!1}]}),Fl=wl({tierId:null===(Tl=Ml.products[1])||void 0===Tl?void 0:Tl.id}),Dl={free:jl({name:"Jamie Larson",email:"jamie@example.com",firstname:"Jamie",subscriptions:[],paid:!1,avatarImage:"",subscribed:!0}),paid:jl({paid:!0,subscriptions:[Cl({status:"active",currency:"USD",interval:"year",amount:5e3,cardLast4:"4242",startDate:"2021-10-05T03:18:30.000Z",currentPeriodEnd:"2022-10-05T03:18:30.000Z",cancelAtPeriodEnd:!1})]}),complimentary:jl({paid:!0,subscriptions:[]}),complimentaryWithSubscription:jl({paid:!0,subscriptions:[Cl({amount:0})]}),preview:jl({paid:!0,subscriptions:[Cl({amount:1500,startDate:"2019-05-01T11:42:40.000Z",currentPeriodEnd:"2021-06-05T11:42:40.000Z"})]})};function zl(e){var t=e.state;return Object(Lr.removePortalLinkFromUrl)(),{showPopup:!1,lastPage:null,pageQuery:"",popupNotification:null,page:"magiclink"===t.page?"":t.page}}function Rl(){return(Rl=m(f().mark((function e(t){var n,r;return f().wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return n=t.api,r=t.state,e.prev=1,e.next=4,n.member.signout();case 4:return e.abrupt("return",{action:"signout:success"});case 7:return e.prev=7,e.t0=e.catch(1),e.abrupt("return",{action:"signout:failed",popupNotification:Object(Lr.createPopupNotification)({type:"signout:failed",autoHide:!1,closeable:!0,state:r,status:"error",message:"Failed to log out, please try again"})});case 10:case"end":return e.stop()}}),e,null,[[1,7]])})))).apply(this,arguments)}function Ul(){return(Ul=m(f().mark((function e(t){var n,r,i;return f().wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return n=t.data,r=t.api,i=t.state,e.prev=1,e.next=4,r.member.sendMagicLink(n);case 4:return e.abrupt("return",{page:"magiclink",lastPage:"signin"});case 7:return e.prev=7,e.t0=e.catch(1),e.abrupt("return",{action:"signin:failed",popupNotification:Object(Lr.createPopupNotification)({type:"signin:failed",autoHide:!1,closeable:!0,state:i,status:"error",message:"Failed to log in, please try again"})});case 10:case"end":return e.stop()}}),e,null,[[1,7]])})))).apply(this,arguments)}function Al(){return(Al=m(f().mark((function e(t){var n,r,i,o,a,l,s,c,u,p,d,h;return f().wrap((function(e){for(;;)switch(e.prev=e.next){case 0:if(n=t.data,r=t.state,i=t.api,e.prev=1,o=n.plan,a=n.tierId,l=n.cadence,s=n.email,c=n.name,u=n.newsletters,p=n.offerId,"free"!==o.toLowerCase()){e.next=8;break}return e.next=6,i.member.sendMagicLink(n);case 6:case 11:e.next=18;break;case 8:if(!a||!l){e.next=13;break}return e.next=11,i.member.checkoutPlan({plan:o,tierId:a,cadence:l,email:s,name:c,newsletters:u,offerId:p});case 13:return d=Object(Lr.getProductCadenceFromPrice)({site:null===r||void 0===r?void 0:r.site,priceId:o}),a=d.tierId,l=d.cadence,e.next=18,i.member.checkoutPlan({plan:o,tierId:a,cadence:l,email:s,name:c,newsletters:u,offerId:p});case 18:return e.abrupt("return",{page:"magiclink",lastPage:"signup"});case 21:return e.prev=21,e.t0=e.catch(1),h=(null===e.t0||void 0===e.t0?void 0:e.t0.message)||"Failed to sign up, please try again",e.abrupt("return",{action:"signup:failed",popupNotification:Object(Lr.createPopupNotification)({type:"signup:failed",autoHide:!1,closeable:!0,state:r,status:"error",message:h})});case 25:case"end":return e.stop()}}),e,null,[[1,21]])})))).apply(this,arguments)}function Bl(){return(Bl=m(f().mark((function e(t){var n,r,i,o,a,l,s,c;return f().wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return n=t.data,r=t.state,i=t.api,e.prev=1,o=n.plan,a=n.offerId,l=n.tierId,s=n.cadence,l&&s||(c=Object(Lr.getProductCadenceFromPrice)({site:null===r||void 0===r?void 0:r.site,priceId:o}),l=c.tierId,s=c.cadence),e.next=6,i.member.checkoutPlan({plan:o,tierId:l,cadence:s,offerId:a,metadata:{checkoutType:"upgrade"}});case 6:e.next=11;break;case 8:return e.prev=8,e.t0=e.catch(1),e.abrupt("return",{action:"checkoutPlan:failed",popupNotification:Object(Lr.createPopupNotification)({type:"checkoutPlan:failed",autoHide:!1,closeable:!0,state:r,status:"error",message:"Failed to process checkout, please try again"})});case 11:case"end":return e.stop()}}),e,null,[[1,8]])})))).apply(this,arguments)}function Hl(){return(Hl=m(f().mark((function e(t){var n,r,i,o,a,l,s,c,u,p,d,h;return f().wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return n=t.data,r=t.state,i=t.api,e.prev=1,o=n.plan,a=n.planId,l=n.subscriptionId,s=n.cancelAtPeriodEnd,c=Object(Lr.getProductCadenceFromPrice)({site:null===r||void 0===r?void 0:r.site,priceId:a}),u=c.tierId,p=c.cadence,e.next=6,i.member.updateSubscription({planName:o,tierId:u,cadence:p,subscriptionId:l,cancelAtPeriodEnd:s,planId:a});case 6:return e.next=8,i.member.sessionData();case 8:return d=e.sent,h="updateSubscription:success",e.abrupt("return",{action:h,popupNotification:Object(Lr.createPopupNotification)({type:h,autoHide:!0,closeable:!0,state:r,status:"success",message:"Subscription plan updated successfully"}),page:"accountHome",member:d});case 13:return e.prev=13,e.t0=e.catch(1),e.abrupt("return",{action:"updateSubscription:failed",popupNotification:Object(Lr.createPopupNotification)({type:"updateSubscription:failed",autoHide:!1,closeable:!0,state:r,status:"error",message:"Failed to update subscription, please try again"})});case 16:case"end":return e.stop()}}),e,null,[[1,13]])})))).apply(this,arguments)}function ql(){return(ql=m(f().mark((function e(t){var n,r,i,o,a,l;return f().wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return n=t.data,r=t.state,i=t.api,e.prev=1,o=n.subscriptionId,a=n.cancellationReason,e.next=5,i.member.updateSubscription({subscriptionId:o,smartCancel:!0,cancellationReason:a});case 5:return e.next=7,i.member.sessionData();case 7:return l=e.sent,"cancelSubscription:success",e.abrupt("return",{action:"cancelSubscription:success",page:"accountHome",member:l});case 12:return e.prev=12,e.t0=e.catch(1),e.abrupt("return",{action:"cancelSubscription:failed",popupNotification:Object(Lr.createPopupNotification)({type:"cancelSubscription:failed",autoHide:!1,closeable:!0,state:r,status:"error",message:"Failed to cancel subscription, please try again"})});case 15:case"end":return e.stop()}}),e,null,[[1,12]])})))).apply(this,arguments)}function $l(){return($l=m(f().mark((function e(t){var n,r,i,o,a;return f().wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return n=t.data,r=t.state,i=t.api,e.prev=1,o=n.subscriptionId,e.next=5,i.member.updateSubscription({subscriptionId:o,cancelAtPeriodEnd:!1});case 5:return e.next=7,i.member.sessionData();case 7:return a=e.sent,"continueSubscription:success",e.abrupt("return",{action:"continueSubscription:success",page:"accountHome",member:a});case 12:return e.prev=12,e.t0=e.catch(1),e.abrupt("return",{action:"continueSubscription:failed",popupNotification:Object(Lr.createPopupNotification)({type:"continueSubscription:failed",autoHide:!1,closeable:!0,state:r,status:"error",message:"Failed to cancel subscription, please try again"})});case 15:case"end":return e.stop()}}),e,null,[[1,12]])})))).apply(this,arguments)}function Wl(){return(Wl=m(f().mark((function e(t){var n,r,i;return f().wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return n=t.data,r=t.state,i=t.api,e.prev=1,e.next=4,i.member.editBilling(n);case 4:e.next=9;break;case 6:return e.prev=6,e.t0=e.catch(1),e.abrupt("return",{action:"editBilling:failed",popupNotification:Object(Lr.createPopupNotification)({type:"editBilling:failed",autoHide:!1,closeable:!0,state:r,status:"error",message:"Failed to update billing information, please try again"})});case 9:case"end":return e.stop()}}),e,null,[[1,6]])})))).apply(this,arguments)}function Ql(){return(Ql=m(f().mark((function e(){return f().wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return e.abrupt("return",{popupNotification:null});case 1:case"end":return e.stop()}}),e)})))).apply(this,arguments)}function Vl(){return(Vl=m(f().mark((function e(t){var n,r,i,o,a;return f().wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return n=t.data,r=t.state,i=n.action,o=n.message,a=void 0===o?"":o,i=i||"showPopupNotification:success",e.abrupt("return",{popupNotification:Object(Lr.createPopupNotification)({type:i,autoHide:!0,closeable:!0,state:r,status:"success",message:a})});case 4:case"end":return e.stop()}}),e)})))).apply(this,arguments)}function Yl(){return(Yl=m(f().mark((function e(t){var n,r,i,o,a,l,s;return f().wrap((function(e){for(;;)switch(e.prev=e.next){case 0:if(n=t.data,r=t.state,i=t.api,e.prev=1,o=n.newsletters,a=n.enableCommentNotifications,o||void 0!==a){e.next=5;break}return e.abrupt("return",{});case 5:return l={},o&&(l.newsletters=o),void 0!==a&&(l.enableCommentNotifications=a),e.next=10,i.member.update(l);case 10:return s=e.sent,"updateNewsletterPref:success",e.abrupt("return",{action:"updateNewsletterPref:success",member:s});case 15:return e.prev=15,e.t0=e.catch(1),e.abrupt("return",{action:"updateNewsletterPref:failed",popupNotification:Object(Lr.createPopupNotification)({type:"updateNewsletter:failed",autoHide:!0,closeable:!0,state:r,status:"error",message:"Failed to update newsletter settings"})});case 18:case"end":return e.stop()}}),e,null,[[1,15]])})))).apply(this,arguments)}function Kl(){return(Kl=m(f().mark((function e(t){var n,r,i,o,a,l;return f().wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return n=t.data,r=t.state,i=t.api,e.prev=1,o=n.subscribed,e.next=5,i.member.update({subscribed:o});case 5:if(a=e.sent){e.next=8;break}throw new Error("Failed to update newsletter");case 8:return l="updateNewsletter:success",e.abrupt("return",{action:l,member:a,popupNotification:Object(Lr.createPopupNotification)({type:l,autoHide:!0,closeable:!0,state:r,status:"success",message:"Email newsletter settings updated"})});case 12:return e.prev=12,e.t0=e.catch(1),e.abrupt("return",{action:"updateNewsletter:failed",popupNotification:Object(Lr.createPopupNotification)({type:"updateNewsletter:failed",autoHide:!0,closeable:!0,state:r,status:"error",message:"Failed to update newsletter settings"})});case 15:case"end":return e.stop()}}),e,null,[[1,12]])})))).apply(this,arguments)}function Gl(e){return Jl.apply(this,arguments)}function Jl(){return(Jl=m(f().mark((function e(t){var n,r,i,o,a;return f().wrap((function(e){for(;;)switch(e.prev=e.next){case 0:if(n=t.data,r=t.state,i=t.api,o=n.email,a=Object(Lr.getMemberEmail)({member:r.member}),o===a){e.next=13;break}return e.prev=4,e.next=7,i.member.updateEmailAddress({email:o});case 7:return e.abrupt("return",{success:!0});case 10:return e.prev=10,e.t0=e.catch(4),e.abrupt("return",{success:!1,error:e.t0});case 13:return e.abrupt("return",null);case 14:case"end":return e.stop()}}),e,null,[[4,10]])})))).apply(this,arguments)}function Xl(e){return Zl.apply(this,arguments)}function Zl(){return(Zl=m(f().mark((function e(t){var n,r,i,o,a;return f().wrap((function(e){for(;;)switch(e.prev=e.next){case 0:if(n=t.data,r=t.state,i=t.api,o=n.name,Object(Lr.getMemberName)({member:r.member})===o){e.next=16;break}return e.prev=4,e.next=7,i.member.update({name:o});case 7:if(a=e.sent){e.next=10;break}throw new Error("Failed to update member");case 10:return e.abrupt("return",{member:a,success:!0});case 13:return e.prev=13,e.t0=e.catch(4),e.abrupt("return",{success:!1,error:e.t0});case 16:return e.abrupt("return",null);case 17:case"end":return e.stop()}}),e,null,[[4,13]])})))).apply(this,arguments)}function es(){return(es=m(f().mark((function e(t){var n,r,i;return f().wrap((function(e){for(;;)switch(e.prev=e.next){case 0:if(n=t.state,r=t.api,!n.member){e.next=14;break}return e.prev=2,e.next=5,r.member.sessionData();case 5:if(!(i=e.sent)){e.next=8;break}return e.abrupt("return",{member:i,success:!0});case 8:case 14:return e.abrupt("return",null);case 11:return e.prev=11,e.t0=e.catch(2),e.abrupt("return",{success:!1,error:e.t0});case 15:case"end":return e.stop()}}),e,null,[[2,11]])})))).apply(this,arguments)}function ts(){return(ts=m(f().mark((function e(t){var n,r,i,o,a,l,c,u,p,d,h,m,g,b;return f().wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return n=t.data,r=t.state,i=t.api,e.next=3,Promise.all([Xl({data:n,state:r,api:i}),Gl({data:n,state:r,api:i})]);case 3:if(o=e.sent,a=Object(s.a)(o,2),l=a[0],c=a[1],!l||!c){e.next=14;break}if(!c.success){e.next=10;break}return e.abrupt("return",Object(k.a)(Object(k.a)({action:"updateProfile:success"},l.success?{member:l.member}:{}),{},{page:"accountHome",popupNotification:Object(Lr.createPopupNotification)({type:"updateProfile:success",autoHide:!0,closeable:!0,status:"success",state:r,message:"Check your inbox to verify email update"})}));case 10:return u=l.success?"Failed to send verification email":"Failed to update account data",e.abrupt("return",Object(k.a)(Object(k.a)({action:"updateProfile:failed"},l.success?{member:l.member}:{}),{},{popupNotification:Object(Lr.createPopupNotification)({type:"updateProfile:failed",autoHide:!0,closeable:!0,status:"error",message:u,state:r})}));case 14:if(!l){e.next=21;break}return p=l.success?"updateProfile:success":"updateProfile:failed",d=l.success?"success":"error",h=l.success?"Account details updated successfully":"Failed to update account details",e.abrupt("return",Object(k.a)(Object(k.a)(Object(k.a)({action:p},l.success?{member:l.member}:{}),l.success?{page:"accountHome"}:{}),{},{popupNotification:Object(Lr.createPopupNotification)({type:p,autoHide:l.success,closeable:!0,status:d,state:r,message:h})}));case 21:if(!c){e.next=26;break}return m=c.success?"updateProfile:success":"updateProfile:failed",g=c.success?"success":"error",b=c.success?"Check your inbox to verify email update":"Failed to send verification email",e.abrupt("return",Object(k.a)(Object(k.a)({action:m},c.success?{page:"accountHome"}:{}),{},{popupNotification:Object(Lr.createPopupNotification)({type:m,autoHide:c.success,closeable:!0,status:g,state:r,message:b})}));case 26:return e.abrupt("return",{action:"updateProfile:success",page:"accountHome",popupNotification:Object(Lr.createPopupNotification)({type:"updateProfile:success",autoHide:!0,closeable:!0,status:"success",state:r,message:"Account details updated successfully"})});case 27:case"end":return e.stop()}}),e)})))).apply(this,arguments)}var ns={togglePopup:function(e){return{showPopup:!e.state.showPopup}},openPopup:function(e){var t=e.data;return Object(k.a)(Object(k.a)({showPopup:!0,page:t.page},t.pageQuery?{pageQuery:t.pageQuery}:{}),t.pageData?{pageData:t.pageData}:{})},closePopup:zl,switchPage:function(e){var t=e.data,n=e.state;return{page:t.page,popupNotification:null,lastPage:t.lastPage||null,pageData:t.pageData||n.pageData}},openNotification:function(e){var t=e.data;return Object(k.a)({showNotification:!0},t)},closeNotification:function(e){return e.state,{showNotification:!1}},back:function(e){var t=e.state;return t.lastPage?{page:t.lastPage}:zl({state:t})},signout:function(e){return Rl.apply(this,arguments)},signin:function(e){return Ul.apply(this,arguments)},signup:function(e){return Al.apply(this,arguments)},updateSubscription:function(e){return Hl.apply(this,arguments)},cancelSubscription:function(e){return ql.apply(this,arguments)},continueSubscription:function(e){return $l.apply(this,arguments)},updateNewsletter:function(e){return Kl.apply(this,arguments)},updateProfile:function(e){return ts.apply(this,arguments)},refreshMemberData:function(e){return es.apply(this,arguments)},clearPopupNotification:function(){return Ql.apply(this,arguments)},editBilling:function(e){return Wl.apply(this,arguments)},checkoutPlan:function(e){return Bl.apply(this,arguments)},updateNewsletterPreference:function(e){return Yl.apply(this,arguments)},showPopupNotification:function(e){return Vl.apply(this,arguments)}};function rs(e){return is.apply(this,arguments)}function is(){return(is=m(f().mark((function e(t){var n,r,i,o,a;return f().wrap((function(e){for(;;)switch(e.prev=e.next){case 0:if(n=t.action,r=t.data,i=t.state,o=t.api,!(a=ns[n])){e.next=9;break}return e.next=5,a({data:r,state:i,api:o});case 5:if(e.t0=e.sent,e.t0){e.next=8;break}e.t0={};case 8:return e.abrupt("return",e.t0);case 9:return e.abrupt("return",{});case 10:case"end":return e.stop()}}),e)})))).apply(this,arguments)}n(40);var os=["site"],as=["site"],ls=["site"],ss=["site"],cs=["site"],us=["site"],ps=n(42).handleDataAttributes,ds=n(1),fs=Object(k.a)(Object(k.a)({showPopup:!0,site:Ml,member:Dl.free,page:"accountEmail"},function(){var e;if(!Ll||!Ll[1])return null;var t=null===Ml||void 0===Ml||null===(e=Ml.products)||void 0===e?void 0:e[1].monthlyPrice,n=jl({paid:!0,subscriptions:[Cl({offer:null,priceId:null===t||void 0===t?void 0:t.id,status:"active",currency:null===t||void 0===t?void 0:t.currency,interval:null===t||void 0===t?void 0:t.interval,amount:null===t||void 0===t?void 0:t.amount,cardLast4:"4242",startDate:"2021-10-05T03:18:30.000Z",currentPeriodEnd:"2022-10-05T03:18:30.000Z",cancelAtPeriodEnd:!1})]});return{site:Ml,member:n}}()),{},{pageData:Fl});function hs(e){var t=e.site,n=e.children,r=(t||{}).portal_sentry;return r&&r.dsn?Object(Hn.jsx)(zn,{children:n}):Object(Hn.jsx)(Hn.Fragment,{children:n})}var ms=function(e){x(n,e);var t=O(n);function n(e){var r;return g(this,n),(r=t.call(this,e)).setupCustomTriggerButton(e),r.state={site:null,member:null,page:"loading",showPopup:!1,action:"init:running",initStatus:"running",lastPage:null,customSiteUrl:e.customSiteUrl},r}return v(n,[{key:"componentDidMount",value:function(){this.initSetup()}},{key:"componentDidUpdate",value:function(e,t){if(t.showPopup!==this.state.showPopup){this.handleCustomTriggerClassUpdate();try{var n,r,i;if(this.state.showPopup)this.bodyScroll=null===(n=window.document)||void 0===n||null===(r=n.body)||void 0===r||null===(i=r.style)||void 0===i?void 0:i.overflow,window.document.body.style.overflow="hidden";else window.document.body.style.overflow=this.bodyScroll||""}catch(l){}}if("success"===this.state.initStatus&&t.initStatus!==this.state.initStatus){var o=this.props.siteUrl,a=this.getContextFromState();this.sendPortalReadyEvent(),ps({siteUrl:o,site:a.site,member:a.member})}}},{key:"componentWillUnmount",value:function(){var e=this;clearTimeout(this.timeoutId),this.customTriggerButtons&&this.customTriggerButtons.forEach((function(t){t.removeEventListener("click",e.clickHandler)})),window.removeEventListener("hashchange",this.hashHandler,!1)}},{key:"sendPortalReadyEvent",value:function(){window.self!==window.parent&&window.parent.postMessage({type:"portal-ready",payload:{}},"*")}},{key:"setupCustomTriggerButton",value:function(){var e=this;this.clickHandler=function(t){t.preventDefault();var n=t.currentTarget,r=n&&n.dataset.portal,i=e.getPageFromLinkPath(r)||{},o=i.page,a=i.pageQuery;"success"===e.state.initStatus&&(a&&"free"!==a?e.handleSignupQuery({site:e.state.site,pageQuery:a}):e.dispatchAction("openPopup",{page:o,pageQuery:a}))};this.customTriggerButtons=document.querySelectorAll("[data-portal]")||[],this.customTriggerButtons.forEach((function(t){t.classList.add("gh-portal-close"),t.removeEventListener("click",e.clickHandler),t.addEventListener("click",e.clickHandler)}))}},{key:"handleCustomTriggerClassUpdate",value:function(){var e,t=this,n="gh-portal-open",r="gh-portal-close";null===(e=this.customTriggerButtons)||void 0===e||e.forEach((function(e){var i=t.state.showPopup?n:r,o=t.state.showPopup?r:n;e.classList.add(i),e.classList.remove(o)}))}},{key:"initSetup",value:function(){var e=m(f().mark((function e(){var t,n,r,i,o,a,l,s,c,u,p=this;return f().wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return e.prev=0,e.next=3,this.fetchData();case 3:t=e.sent,n=t.site,r=t.member,i=t.page,o=t.showPopup,a=t.popupNotification,l=t.lastPage,s=t.pageQuery,c=t.pageData,u={site:n,member:r,page:i,lastPage:l,pageQuery:s,showPopup:o,pageData:c,popupNotification:a,action:"init:success",initStatus:"success"},this.handleSignupQuery({site:n,pageQuery:s,member:r}),this.setState(u),this.hashHandler=function(){p.updateStateForPreviewLinks()},window.addEventListener("hashchange",this.hashHandler,!1),e.next=23;break;case 19:e.prev=19,e.t0=e.catch(0),console.error("[Portal] Failed to initialize:",e.t0),this.setState({action:"init:failed",initStatus:"failed"});case 23:case"end":return e.stop()}}),e,this,[[0,19]])})));return function(){return e.apply(this,arguments)}}()},{key:"fetchData",value:function(){var e=m(f().mark((function e(){var t,n,r,i,o,a,l,s,c,u,d,h,m,g,b;return f().wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return e.next=2,this.fetchApiData();case 2:return t=e.sent,n=t.site,r=t.member,i=this.fetchDevData(),o=i.site,a=p(i,os),l=this.fetchLinkData(),s=l.site,c=p(l,as),u=this.fetchPreviewData(),d=u.site,h=p(u,ls),m=this.fetchNotificationData(),g=m.site,b=p(m,ss),"",e.abrupt("return",Object(k.a)(Object(k.a)(Object(k.a)(Object(k.a)({member:r,page:"",site:Object(k.a)(Object(k.a)(Object(k.a)(Object(k.a)(Object(k.a)(Object(k.a)({},n),s),d),g),o),{},{plans:Object(k.a)(Object(k.a)(Object(k.a)({},(o||{}).plans),(n||{}).plans),(d||{}).plans)})},a),c),b),h));case 11:case"end":return e.stop()}}),e,this)})));return function(){return e.apply(this,arguments)}}()},{key:"fetchDevData",value:function(){return zr(["dev"])&&!this.state.customSiteUrl?fs:zr(["test"])?{showPopup:void 0===this.props.showPopup||this.props.showPopup}:{}}},{key:"fetchOfferQueryStrData",value:function(){var e,t=arguments.length>0&&void 0!==arguments[0]?arguments[0]:"",n=new URLSearchParams(t),r={},i=u(n.entries());try{for(i.s();!(e=i.n()).done;){var o=e.value,a=o[0],l=decodeURIComponent(o[1]);"name"===a?r.name=l||"":"code"===a?r.code=l||"":"display_title"===a?r.display_title=l||"":"display_description"===a?r.display_description=l||"":"type"===a?r.type=l||"":"cadence"===a?r.cadence=l||"":"duration"===a?r.duration=l||"":"duration_in_months"!==a||isNaN(Number(l))?"amount"!==a||isNaN(Number(l))?"currency"===a?r.currency=l||"":"status"===a?r.status=l||"":"tier_id"===a&&(r.tier={id:l||Fl.tier.id}):r.amount=Number(l):r.duration_in_months=Number(l)}}catch(s){i.e(s)}finally{i.f()}return{page:"offer",pageData:r}}},{key:"fetchQueryStrData",value:function(){var e,t,n,r,i,o=arguments.length>0&&void 0!==arguments[0]?arguments[0]:"",a=new URLSearchParams(o),l={site:{plans:{}}},s=[],c=null,p=u(a.entries());try{for(p.s();!(i=p.n()).done;){var d=i.value,f=d[0],h=decodeURIComponent(d[1]);if("button"===f)l.site.portal_button=JSON.parse(h);else if("name"===f)l.site.portal_name=JSON.parse(h);else if("isFree"===f&&JSON.parse(h))s.push("free");else if("isMonthly"===f&&JSON.parse(h))s.push("monthly");else if("isYearly"===f&&JSON.parse(h))s.push("yearly");else if("portalPrices"===f)e=h?h.split(","):[];else if("portalProducts"===f)c=h?h.split(","):[];else if("page"===f&&h)l.page=h;else if("accentColor"!==f||""!==h&&!h)if("buttonIcon"===f&&h)l.site.portal_button_icon=h;else if("signupButtonText"===f)l.site.portal_button_signup_text=h||"";else if("buttonStyle"===f&&h)l.site.portal_button_style=h;else if("monthlyPrice"!==f||isNaN(Number(h)))if("yearlyPrice"!==f||isNaN(Number(h)))if("currency"===f&&h){var m=h.toUpperCase();l.site.plans.currency=m,l.site.plans.currency_symbol=Object(Lr.getCurrencySymbol)(m),r=m}else"disableBackground"===f?l.site.disableBackground=JSON.parse(h):"allowSelfSignup"===f?l.site.allow_self_signup=JSON.parse(h):"membersSignupAccess"===f&&h&&(l.site.members_signup_access=h);else l.site.plans.yearly=Number(h),n=Number(h);else l.site.plans.monthly=Number(h),t=Number(h);else l.site.accent_color=h}}catch(g){p.e(g)}finally{p.f()}return l.site.portal_plans=s,l.site.portal_products=c,e?l.site.portal_plans=e:t&&n&&r&&(l.site.prices=[{id:"monthly",stripe_price_id:"dummy_stripe_monthly",stripe_product_id:"dummy_stripe_product",active:1,nickname:"Monthly",currency:r,amount:t,type:"recurring",interval:"month"},{id:"yearly",stripe_price_id:"dummy_stripe_yearly",stripe_product_id:"dummy_stripe_product",active:1,nickname:"Yearly",currency:r,amount:n,type:"recurring",interval:"year"}]),l}},{key:"fetchNotificationData",value:function(){var e=fi({billingOnly:!0})||{},t=e.type,n=e.status,r=e.duration,i=e.autoHide,o=e.closeable;return["stripe:billing-update"].includes(t)?"success"===n?{showPopup:!0,popupNotification:Object(Lr.createPopupNotification)({type:t,status:n,duration:r,closeable:o,autoHide:i,state:this.state,message:"success"===n?"Billing info updated successfully":""})}:{showPopup:!0}:{}}},{key:"fetchLinkData",value:function(){var e=new URLSearchParams(window.location.search);if(e.get("uuid")&&"unsubscribe"===e.get("action"))return{showPopup:!0,page:"unsubscribe",pageData:{uuid:e.get("uuid"),newsletterUuid:e.get("newsletter"),comments:e.get("comments")}};var t=window.location.hash.substr(1).split("?"),n=Object(s.a)(t,1)[0],r=/^\/portal\/?(?:\/(\w+(?:\/\w+)*))?\/?$/;if(n&&r.test(n)){var i=n.match(r),o=Object(s.a)(i,2)[1],a=this.getPageFromLinkPath(o)||{},l=a.page,c=a.pageQuery,u=["accountPlan","accountProfile"].includes(l)?"accountHome":null,p=!(["monthly","yearly"].includes(c)||/^(?:(\w+?))?\/monthly$/.test(c)||/^(?:(\w+?))?\/yearly$/.test(c)||/^offers\/(\w+?)\/?$/.test(c));return Object(k.a)(Object(k.a)(Object(k.a)({showPopup:p},l?{page:l}:{}),c?{pageQuery:c}:{}),u?{lastPage:u}:{})}return{}}},{key:"fetchPreviewData",value:function(){var e=window.location.hash.substr(1).split("?"),t=Object(s.a)(e,2)[1];if(zr(["preview"])){var n={};return n=zr(["offerPreview"])?this.fetchOfferQueryStrData(t):this.fetchQueryStrData(t),Object(k.a)(Object(k.a)({},n),{},{showPopup:!0})}return{}}},{key:"getColorOverride",value:function(){var e=document.querySelector("script[data-ghost]");return!(!e||!e.dataset.accentColor)&&e.dataset.accentColor}},{key:"fetchApiData",value:function(){var e=m(f().mark((function e(){var t,n,r,i,o,a,l,s,c;return f().wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return t=this.props,n=t.siteUrl,r=t.customSiteUrl,i=t.apiUrl,o=t.apiKey,e.prev=1,this.GhostApi=this.props.api||Xa({siteUrl:n,apiUrl:i,apiKey:o}),e.next=5,this.GhostApi.init();case 5:return a=e.sent,l=a.site,s=a.member,(c=this.getColorOverride())&&(l.accent_color=c),this.setupFirstPromoter({site:l,member:s}),this.setupSentry({site:l}),e.abrupt("return",{site:l,member:s});case 15:if(e.prev=15,e.t0=e.catch(1),!zr(["dev","test"],{customSiteUrl:r})){e.next=19;break}return e.abrupt("return",{});case 19:throw e.t0;case 20:case"end":return e.stop()}}),e,this,[[1,15]])})));return function(){return e.apply(this,arguments)}}()},{key:"setupSentry",value:function(e){var t=e.site;if(zr(["test"]))return null;var n,r=t.portal_sentry,i=(t.portal_version,t.version),o="portal@".concat("2.11.2","|ghost@").concat(i);r&&r.dsn&&((n={dsn:r.dsn,environment:r.env||"development",release:o,beforeSend:function(e){return Object(Lr.isSentryEventAllowed)({event:e})?e:null},allowUrls:[/https?:\/\/((www)\.)?unpkg\.com\/@tryghost\/portal/]})._metadata=n._metadata||{},n._metadata.sdk=n._metadata.sdk||{name:"sentry.javascript.react",packages:[{name:"npm:@sentry/react",version:Fe}],version:Fe},Ln(n))}},{key:"setupFirstPromoter",value:function(e){var t=e.site,n=e.member;if(zr(["test"]))return null;var r=Object(Lr.getFirstpromoterId)({site:t}),i=Object(Lr.getSiteDomain)({site:t});if(r&&i){var o=document.createElement("script");o.type="text/javascript",o.async=!0,o.src="https://cdn.firstpromoter.com/fprom.js",o.onload=o.onreadystatechange=function(){var e=this.readyState;if(!e||"complete"===e||"loaded"===e)try{if(window.$FPROM.init(r,i),n){var t=n.email,o=n.uuid;if(window.$FPROM)window.$FPROM.trackSignup({email:t,uid:o});else{var a=window._fprom||[];window._fprom=a,a.push(["event","signup"]),a.push(["email",t]),a.push(["uid",o])}}}catch(l){}};var a=document.getElementsByTagName("script")[0];a.parentNode.insertBefore(o,a)}}},{key:"dispatchAction",value:function(){var e=m(f().mark((function e(t,n){var r,i,o=this;return f().wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return clearTimeout(this.timeoutId),this.setState({action:"".concat(t,":running")}),e.prev=2,e.next=5,rs({action:t,data:n,state:this.state,api:this.GhostApi});case 5:r=e.sent,this.setState(r),r&&r.action&&!r.action.includes(":failed")&&(this.timeoutId=setTimeout((function(){o.setState({action:""})}),2e3)),e.next=14;break;case 10:e.prev=10,e.t0=e.catch(2),i=Object(Lr.createPopupNotification)({type:"".concat(t,":failed"),autoHide:!0,closeable:!0,status:"error",state:this.state,meta:{error:e.t0}}),this.setState({action:"".concat(t,":failed"),popupNotification:i});case 14:case"end":return e.stop()}}),e,this,[[2,10]])})));return function(t,n){return e.apply(this,arguments)}}()},{key:"updateStateForPreviewLinks",value:function(){var e=this.fetchPreviewData(),t=e.site,n=p(e,cs),r=this.fetchLinkData(),i=r.site,o=p(r,us),a=Object(k.a)(Object(k.a)({site:Object(k.a)(Object(k.a)(Object(k.a)(Object(k.a)({},this.state.site),i||{}),t||{}),{},{plans:Object(k.a)(Object(k.a)(Object(k.a)({},this.state.site&&this.state.site.plans),(i||{}).plans),(t||{}).plans)})},o),n);this.handleSignupQuery({site:a.site,pageQuery:a.pageQuery}),this.setState(a)}},{key:"handleOfferQuery",value:function(){var e=m(f().mark((function e(t){var n,r,i,o,a,l,s,c,u,p,d,h,m,g,b;return f().wrap((function(e){for(;;)switch(e.prev=e.next){case 0:if(n=t.site,r=t.offerId,i=t.member,o=void 0===i?this.state.member:i,a=n.portal_button,Object(Lr.removePortalLinkFromUrl)(),Object(Lr.isPaidMember)({member:o})){e.next=14;break}return e.prev=4,e.next=7,this.GhostApi.site.offer({offerId:r});case 7:l=e.sent,s=null===l||void 0===l?void 0:l.offers[0],Object(Lr.isActiveOffer)({offer:s})&&(a?this.dispatchAction("openPopup",{page:"offer",pageData:null===l||void 0===l?void 0:l.offers[0]}):(c=Object(Lr.getProductFromId)({site:n,productId:s.tier.id}),u="month"===s.cadence?c.monthlyPrice:c.yearlyPrice,this.dispatchAction("openPopup",{page:"loading"}),o?(p=Object(Lr.getProductCadenceFromPrice)({site:n,priceId:u.id}),d=p.tierId,h=p.cadence,this.dispatchAction("checkoutPlan",{plan:u.id,offerId:r,tierId:d,cadence:h})):(m=Object(Lr.getProductCadenceFromPrice)({site:n,priceId:u.id}),g=m.tierId,b=m.cadence,this.dispatchAction("signup",{plan:u.id,offerId:r,tierId:g,cadence:b})))),e.next=14;break;case 12:e.prev=12,e.t0=e.catch(4);case 14:case"end":return e.stop()}}),e,this,[[4,12]])})));return function(t){return e.apply(this,arguments)}}()},{key:"handleSignupQuery",value:function(e){var t=e.site,n=e.pageQuery,r=e.member,i=/^offers\/(\w+?)\/?$/,o=n;if(i.test(n||"")){var a=n.match(i),l=Object(s.a)(a,2)[1];this.handleOfferQuery({site:t,offerId:l,member:r})}else{Object(Lr.getPriceIdFromPageQuery)({site:t,pageQuery:n})&&(o=Object(Lr.getPriceIdFromPageQuery)({site:t,pageQuery:n}));var c=Object(Lr.getQueryPrice)({site:t,priceId:o});if(n&&"free"!==n){Object(Lr.removePortalLinkFromUrl)();var u=(null===c||void 0===c?void 0:c.id)||o;"free"!==u&&this.dispatchAction("openPopup",{page:"loading"});var p=Object(Lr.getProductCadenceFromPrice)({site:t,priceId:u}),d=p.tierId,f=p.cadence;this.dispatchAction("signup",{plan:u,tierId:d,cadence:f})}}}},{key:"getPageFromLinkPath",value:function(e){var t=/^signup\/?(?:\/(\w+?))?\/?$/,n=/^signup\/?(?:\/(\w+?))\/monthly\/?$/,r=/^signup\/?(?:\/(\w+?))\/yearly\/?$/;if(/^offers\/(\w+?)\/?$/.test(e))return{pageQuery:e};if("signup"===e)return{page:"signup"};if(n.test(e)){var i=e.match(n),o=Object(s.a)(i,2)[1];return{page:"signup",pageQuery:"".concat(o,"/monthly")}}if(r.test(e)){var a=e.match(r),l=Object(s.a)(a,2)[1];return{page:"signup",pageQuery:"".concat(l,"/yearly")}}if(t.test(e)){var c=e.match(t);return{page:"signup",pageQuery:Object(s.a)(c,2)[1]}}return"signup/free"===e?{page:"signup",pageQuery:"free"}:"signup/monthly"===e?{page:"signup",pageQuery:"monthly"}:"signup/yearly"===e?{page:"signup",pageQuery:"yearly"}:"signin"===e?{page:"signin"}:"account"===e?{page:"accountHome"}:"account/plans"===e?{page:"accountPlan"}:"account/profile"===e?{page:"accountProfile"}:"account/newsletters"===e?{page:"accountEmail"}:{}}},{key:"getAccentColor",value:function(){return(this.state.site||{}).accent_color}},{key:"getContextPage",value:function(e){var t=e.site,n=e.page,r=e.member;if(!n){var i=Object(Lr.isInviteOnlySite)({site:t})?"signin":"signup";n=r?"accountHome":i}return"accountPlan"===n&&Object(Lr.isComplimentaryMember)({member:r})&&!Object(Lr.allowCompMemberUpgrade)({member:r})&&(n="accountHome"),ol({page:n})}},{key:"getContextMember",value:function(e){var t=e.page,n=e.member,r=e.customSiteUrl;return zr(["dev","preview"],{customSiteUrl:r})?{page:t}.page.includes("account")||{page:t}.page.includes("offer")?zr(["dev"],{customSiteUrl:r})?n||Dl.free:zr(["preview"])?Dl.preview:Dl.paid:null:n}},{key:"getContextFromState",value:function(){var e=this,t=this.state,n=t.site,r=t.member,i=t.action,o=t.page,a=t.lastPage,l=t.showPopup,s=t.pageQuery,c=t.pageData,u=t.popupNotification,p=t.customSiteUrl,d=this.getContextPage({site:n,page:o,member:r}),f=this.getContextMember({page:d,member:r,customSiteUrl:p});return{site:n,action:i,brandColor:this.getAccentColor(),page:d,pageQuery:s,pageData:c,member:f,lastPage:a,showPopup:l,popupNotification:u,customSiteUrl:p,onAction:function(t,n){return e.dispatchAction(t,n)}}}},{key:"render",value:function(){return"success"===this.state.initStatus?Object(Hn.jsx)(hs,{site:this.state.site,children:Object(Hn.jsxs)(Zn.Provider,{value:this.getContextFromState(),children:[Object(Hn.jsx)(vl,{}),Object(Hn.jsx)(Hr,{}),Object(Hn.jsx)(yi,{})]})}):null}}]),n}(ds.Component);var gs=function(e){var t=e.siteUrl;return function(e){var t=e.analyticsId,n=e.api;t&&n.analytics.pushEvent({type:"entry_view",entry_id:t,entry_url:window.location.href,created_at:new Date})}({analyticsId:e.analyticsId,api:Xa({siteUrl:t})}),{}},bs="ghost-portal-root";function vs(e){var t=e.siteUrl;!function(){var e=document.createElement("div");e.id=bs,document.body.appendChild(e)}(),function(){var e=new URL(window.location.href);e.searchParams.get("token")&&(e.searchParams.delete("token"),window.history.replaceState({},document.title,e.href))}(),function(e){var t=e.siteUrl,n=document.querySelector("meta[name=ghost-analytics-id]"),r=null===n||void 0===n?void 0:n.content;t&&n&&gs({siteUrl:t,analyticsId:r})}({siteUrl:t})}!function(){var e=function(){var e=document.querySelector("script[data-ghost]");return e?{siteUrl:e.dataset.ghost,apiKey:e.dataset.key,apiUrl:e.dataset.api}:{}}(),t=e.siteUrl,n=e.apiKey,r=e.apiUrl,i=t||window.location.origin;vs({siteUrl:i}),l.a.render(Object(Hn.jsx)(o.a.StrictMode,{children:Object(Hn.jsx)(ms,{siteUrl:i,customSiteUrl:t,apiKey:n,apiUrl:r})}),document.getElementById(bs))}()},,,function(e,t,n){"use strict";(function(e){n.d(t,"a",(function(){return s})),n.d(t,"b",(function(){return c}));var r=n(2),i=n(7),o=n(30),a=n(9),l=n(21);function s(e,t,n){void 0===t&&(t=1/0),void 0===n&&(n=1/0);try{return u("",e,t,n)}catch(r){return{ERROR:"**non-serializable** ("+r+")"}}}function c(e,t,n){void 0===t&&(t=3),void 0===n&&(n=102400);var r,i=s(e,t);return r=i,function(e){return~-encodeURI(e).split(/%..|./).length}(JSON.stringify(r))>n?c(e,t-1,n):i}function u(t,n,s,c,p){void 0===s&&(s=1/0),void 0===c&&(c=1/0),void 0===p&&(p=Object(o.a)());var d=Object(r.c)(p,2),f=d[0],h=d[1],m=n;if(m&&"function"===typeof m.toJSON)try{return m.toJSON()}catch(j){}if(null===n||["number","boolean","string"].includes(typeof n)&&!Object(i.h)(n))return n;var g=function(t,n){try{return"domain"===t&&n&&"object"===typeof n&&n._events?"[Domain]":"domainEmitter"===t?"[DomainEmitter]":"undefined"!==typeof e&&n===e?"[Global]":"undefined"!==typeof window&&n===window?"[Window]":"undefined"!==typeof document&&n===document?"[Document]":Object(i.m)(n)?"[SyntheticEvent]":"number"===typeof n&&n!==n?"[NaN]":void 0===n?"[undefined]":"function"===typeof n?"[Function: "+Object(l.b)(n)+"]":"symbol"===typeof n?"["+String(n)+"]":"bigint"===typeof n?"[BigInt: "+String(n)+"]":"[object "+Object.getPrototypeOf(n).constructor.name+"]"}catch(j){return"**non-serializable** ("+j+")"}}(t,n);if(!g.startsWith("[object "))return g;if(0===s)return g.replace("object ","");if(f(n))return"[Circular ~]";var b=Array.isArray(n)?[]:{},v=0,y=Object(i.d)(n)||Object(i.f)(n)?Object(a.b)(n):n;for(var x in y)if(Object.prototype.hasOwnProperty.call(y,x)){if(v>=c){b[x]="[MaxProperties ~]";break}var w=y[x];b[x]=u(x,w,s-1,c,p),v+=1}return h(n),b}}).call(this,n(25))}]);
3
3
  //# sourceMappingURL=portal.min.js.map