@stigg/react-sdk 7.10.0 → 7.11.0

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.
@@ -1,10 +1,10 @@
1
1
  'use strict';var Uv=require('react'),iC=require('@emotion/styled'),O2=require('classnames'),da=require('@mui/material/Grid'),react=require('@emotion/react'),jsxRuntime=require('react/jsx-runtime'),lodash=require('lodash'),QD=require('react-spinners/ClipLoader'),sc=require('color'),zD=require('lodash/merge'),G1=require('moment'),lm=require('lodash/isNil'),o2=require('currency-symbol-map'),f2=require('@mui/material/InputAdornment'),a2=require('@mui/material/Button'),c2=require('@mui/material/TextField'),HP=require('@mui/material/Divider'),nl=require('react-loading-skeleton'),h2=require('@mui/material/OutlinedInput'),m2=require('@mui/material/Select'),g2=require('@mui/material/MenuItem'),material=require('@mui/material'),rA=require('react-switch'),fx=require('lodash/sortBy'),styles=require('@mui/material/styles'),nO=require('lodash/flatMap'),bg=require('@mui/material/Box'),lP=require('@mui/material/Tab'),rO=require('lodash/isEmpty'),cO=require('@mui/material/Tabs'),reactFeather=require('react-feather'),HO=require('@mui/material/Link'),$O=require('@mui/material/Tooltip'),QO=require('@mui/material/LinearProgress'),JP=require('lodash/isUndefined'),uv=require('lodash/lowerCase'),immer=require('immer'),CR=require('lodash/cloneDeep'),SR=require('lodash/remove'),lE=require('lodash/keyBy'),cE=require('lodash/compact'),reactStripeJs=require('@stripe/react-stripe-js'),h3=require('@mui/material/StepIcon'),wL=require('lodash/partition'),T3=require('@mui/material/CircularProgress'),AL=require('@mui/material/Paper'),K3=require('react-lottie'),xL=require('@mui/material/Collapse'),e5=require('@mui/material/Alert'),t5=require('@mui/material/Radio'),l5=require('@mui/material/Chip'),reactChartjs2=require('react-chartjs-2'),r9=require('lodash/debounce');function _interopDefault(e){return e&&e.__esModule?e:{default:e}}var Uv__default=/*#__PURE__*/_interopDefault(Uv);var iC__default=/*#__PURE__*/_interopDefault(iC);var O2__default=/*#__PURE__*/_interopDefault(O2);var da__default=/*#__PURE__*/_interopDefault(da);var QD__default=/*#__PURE__*/_interopDefault(QD);var sc__default=/*#__PURE__*/_interopDefault(sc);var zD__default=/*#__PURE__*/_interopDefault(zD);var G1__default=/*#__PURE__*/_interopDefault(G1);var lm__default=/*#__PURE__*/_interopDefault(lm);var o2__default=/*#__PURE__*/_interopDefault(o2);var f2__default=/*#__PURE__*/_interopDefault(f2);var a2__default=/*#__PURE__*/_interopDefault(a2);var c2__default=/*#__PURE__*/_interopDefault(c2);var HP__default=/*#__PURE__*/_interopDefault(HP);var nl__default=/*#__PURE__*/_interopDefault(nl);var h2__default=/*#__PURE__*/_interopDefault(h2);var m2__default=/*#__PURE__*/_interopDefault(m2);var g2__default=/*#__PURE__*/_interopDefault(g2);var rA__default=/*#__PURE__*/_interopDefault(rA);var fx__default=/*#__PURE__*/_interopDefault(fx);var nO__default=/*#__PURE__*/_interopDefault(nO);var bg__default=/*#__PURE__*/_interopDefault(bg);var lP__default=/*#__PURE__*/_interopDefault(lP);var rO__default=/*#__PURE__*/_interopDefault(rO);var cO__default=/*#__PURE__*/_interopDefault(cO);var HO__default=/*#__PURE__*/_interopDefault(HO);var $O__default=/*#__PURE__*/_interopDefault($O);var QO__default=/*#__PURE__*/_interopDefault(QO);var JP__default=/*#__PURE__*/_interopDefault(JP);var uv__default=/*#__PURE__*/_interopDefault(uv);var CR__default=/*#__PURE__*/_interopDefault(CR);var SR__default=/*#__PURE__*/_interopDefault(SR);var lE__default=/*#__PURE__*/_interopDefault(lE);var cE__default=/*#__PURE__*/_interopDefault(cE);var h3__default=/*#__PURE__*/_interopDefault(h3);var wL__default=/*#__PURE__*/_interopDefault(wL);var T3__default=/*#__PURE__*/_interopDefault(T3);var AL__default=/*#__PURE__*/_interopDefault(AL);var K3__default=/*#__PURE__*/_interopDefault(K3);var xL__default=/*#__PURE__*/_interopDefault(xL);var e5__default=/*#__PURE__*/_interopDefault(e5);var t5__default=/*#__PURE__*/_interopDefault(t5);var l5__default=/*#__PURE__*/_interopDefault(l5);var r9__default=/*#__PURE__*/_interopDefault(r9);var Gk=Object.create;var kp=Object.defineProperty,jk=Object.defineProperties,Vk=Object.getOwnPropertyDescriptor,zk=Object.getOwnPropertyDescriptors,Hk=Object.getOwnPropertyNames,Zh=Object.getOwnPropertySymbols,Wk=Object.getPrototypeOf,fb=Object.prototype.hasOwnProperty,Q1=Object.prototype.propertyIsEnumerable;var Y1=(t,e,n)=>e in t?kp(t,e,{enumerable:true,configurable:true,writable:true,value:n}):t[e]=n,W=(t,e)=>{for(var n in e||(e={}))fb.call(e,n)&&Y1(t,n,e[n]);if(Zh)for(var n of Zh(e))Q1.call(e,n)&&Y1(t,n,e[n]);return t},St=(t,e)=>jk(t,zk(e));var On=(t,e)=>{var n={};for(var r in t)fb.call(t,r)&&e.indexOf(r)<0&&(n[r]=t[r]);if(t!=null&&Zh)for(var r of Zh(t))e.indexOf(r)<0&&Q1.call(t,r)&&(n[r]=t[r]);return n};var Wn=(t,e)=>()=>(t&&(e=t(t=0)),e);var qk=(t,e)=>()=>(e||t((e={exports:{}}).exports,e),e.exports),K1=(t,e)=>{for(var n in e)kp(t,n,{get:e[n],enumerable:true});},X1=(t,e,n,r)=>{if(e&&typeof e=="object"||typeof e=="function")for(let i of Hk(e))!fb.call(t,i)&&i!==n&&kp(t,i,{get:()=>e[i],enumerable:!(r=Vk(e,i))||r.enumerable});return t};var Z1=(t,e,n)=>(n=t!=null?Gk(Wk(t)):{},X1(!t||!t.__esModule?kp(n,"default",{value:t,enumerable:true}):n,t)),Yk=t=>X1(kp({},"__esModule",{value:true}),t);var ce=(t,e,n)=>new Promise((r,i)=>{var o=p=>{try{c(n.next(p));}catch(h){i(h);}},s=p=>{try{c(n.throw(p));}catch(h){i(h);}},c=p=>p.done?r(p.value):Promise.resolve(p.value).then(o,s);c((n=n.apply(t,e)).next());});var qp,Px=Wn(()=>{qp=function(){return qp=Object.assign||function(e){for(var n,r=1,i=arguments.length;r<i;r++){n=arguments[r];for(var o in n)Object.prototype.hasOwnProperty.call(n,o)&&(e[o]=n[o]);}return e},qp.apply(this,arguments)};});function hc(t,e){throw new Error(e)}var fv=Wn(()=>{});function Um(t){"@babel/helpers - typeof";return typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?Um=function(n){return typeof n}:Um=function(n){return n&&typeof Symbol=="function"&&n.constructor===Symbol&&n!==Symbol.prototype?"symbol":typeof n},Um(t)}function hv(t){return Um(t)=="object"&&t!==null}var xx=Wn(()=>{});var $m,mv=Wn(()=>{$m=typeof Symbol=="function"&&Symbol.toStringTag!=null?Symbol.toStringTag:"@@toStringTag";});function qu(t,e){for(var n=/\r\n|[\n\r]/g,r=1,i=e+1,o;(o=n.exec(t.body))&&o.index<e;)r+=1,i=e+1-(o.index+o[0].length);return {line:r,column:i}}var gv=Wn(()=>{});function yv(t){return jm(t.source,qu(t.source,t.start))}function jm(t,e){var n=t.locationOffset.column-1,r=Gm(n)+t.body,i=e.line-1,o=t.locationOffset.line-1,s=e.line+o,c=e.line===1?n:0,p=e.column+c,h="".concat(t.name,":").concat(s,":").concat(p,`
2
- `),v=r.split(/\r\n|[\n\r]/g),P=v[i];if(P.length>120){for(var x=Math.floor(p/80),T=p%80,I=[],F=0;F<P.length;F+=80)I.push(P.slice(F,F+80));return h+Ex([["".concat(s),I[0]]].concat(I.slice(1,x+1).map(function(A){return ["",A]}),[[" ",Gm(T-1)+"^"],["",I[x+1]]]))}return h+Ex([["".concat(s-1),v[i-1]],["".concat(s),P],["",Gm(p-1)+"^"],["".concat(s+1),v[i+1]]])}function Ex(t){var e=t.filter(function(r){r[0];var o=r[1];return o!==void 0}),n=Math.max.apply(Math,e.map(function(r){var i=r[0];return i.length}));return e.map(function(r){var i=r[0],o=r[1];return DR(n,i)+(o?" | "+o:" |")}).join(`
2
+ `),v=r.split(/\r\n|[\n\r]/g),P=v[i];if(P.length>120){for(var x=Math.floor(p/80),T=p%80,I=[],R=0;R<P.length;R+=80)I.push(P.slice(R,R+80));return h+Ex([["".concat(s),I[0]]].concat(I.slice(1,x+1).map(function(A){return ["",A]}),[[" ",Gm(T-1)+"^"],["",I[x+1]]]))}return h+Ex([["".concat(s-1),v[i-1]],["".concat(s),P],["",Gm(p-1)+"^"],["".concat(s+1),v[i+1]]])}function Ex(t){var e=t.filter(function(r){r[0];var o=r[1];return o!==void 0}),n=Math.max.apply(Math,e.map(function(r){var i=r[0];return i.length}));return e.map(function(r){var i=r[0],o=r[1];return DR(n,i)+(o?" | "+o:" |")}).join(`
3
3
  `)}function Gm(t){return Array(t+1).join(" ")}function DR(t,e){return Gm(t-e.length)+e}var _x=Wn(()=>{gv();});function Vm(t){"@babel/helpers - typeof";return typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?Vm=function(n){return typeof n}:Vm=function(n){return n&&typeof Symbol=="function"&&n.constructor===Symbol&&n!==Symbol.prototype?"symbol":typeof n},Vm(t)}function Tx(t,e){var n=Object.keys(t);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(t);e&&(r=r.filter(function(i){return Object.getOwnPropertyDescriptor(t,i).enumerable})),n.push.apply(n,r);}return n}function AR(t){for(var e=1;e<arguments.length;e++){var n=arguments[e]!=null?arguments[e]:{};e%2?Tx(Object(n),true).forEach(function(r){OR(t,r,n[r]);}):Object.getOwnPropertyDescriptors?Object.defineProperties(t,Object.getOwnPropertyDescriptors(n)):Tx(Object(n)).forEach(function(r){Object.defineProperty(t,r,Object.getOwnPropertyDescriptor(n,r));});}return t}function OR(t,e,n){return e in t?Object.defineProperty(t,e,{value:n,enumerable:true,configurable:true,writable:true}):t[e]=n,t}function RR(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}function wx(t,e){for(var n=0;n<e.length;n++){var r=e[n];r.enumerable=r.enumerable||false,r.configurable=true,"value"in r&&(r.writable=true),Object.defineProperty(t,r.key,r);}}function FR(t,e,n){return e&&wx(t.prototype,e),t}function MR(t,e){if(typeof e!="function"&&e!==null)throw new TypeError("Super expression must either be null or a function");t.prototype=Object.create(e&&e.prototype,{constructor:{value:t,writable:true,configurable:true}}),e&&Qp(t,e);}function NR(t){var e=Dx();return function(){var r=Kp(t),i;if(e){var o=Kp(this).constructor;i=Reflect.construct(r,arguments,o);}else i=r.apply(this,arguments);return kx(this,i)}}function kx(t,e){return e&&(Vm(e)==="object"||typeof e=="function")?e:Yp(t)}function Yp(t){if(t===void 0)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return t}function bv(t){var e=typeof Map=="function"?new Map:void 0;return bv=function(r){if(r===null||!LR(r))return r;if(typeof r!="function")throw new TypeError("Super expression must either be null or a function");if(typeof e!="undefined"){if(e.has(r))return e.get(r);e.set(r,i);}function i(){return zm(r,arguments,Kp(this).constructor)}return i.prototype=Object.create(r.prototype,{constructor:{value:i,enumerable:false,writable:true,configurable:true}}),Qp(i,r)},bv(t)}function zm(t,e,n){return Dx()?zm=Reflect.construct:zm=function(i,o,s){var c=[null];c.push.apply(c,o);var p=Function.bind.apply(i,c),h=new p;return s&&Qp(h,s.prototype),h},zm.apply(null,arguments)}function Dx(){if(typeof Reflect=="undefined"||!Reflect.construct||Reflect.construct.sham)return false;if(typeof Proxy=="function")return true;try{return Date.prototype.toString.call(Reflect.construct(Date,[],function(){})),!0}catch(t){return false}}function LR(t){return Function.toString.call(t).indexOf("[native code]")!==-1}function Qp(t,e){return Qp=Object.setPrototypeOf||function(r,i){return r.__proto__=i,r},Qp(t,e)}function Kp(t){return Kp=Object.setPrototypeOf?Object.getPrototypeOf:function(n){return n.__proto__||Object.getPrototypeOf(n)},Kp(t)}function Ix(t){return t===void 0||t.length===0?void 0:t}function BR(t){var e=t.message;if(t.nodes)for(var n=0,r=t.nodes;n<r.length;n++){var i=r[n];i.loc&&(e+=`
4
4
 
5
5
  `+yv(i.loc));}else if(t.source&&t.locations)for(var o=0,s=t.locations;o<s.length;o++){var c=s[o];e+=`
6
6
 
7
- `+jm(t.source,c);}return e}function UR(t){var e;t||hc(0,"Received null or undefined error.");var n=(e=t.message)!==null&&e!==void 0?e:"An unknown error occurred.",r=t.locations,i=t.path,o=t.extensions;return o&&Object.keys(o).length>0?{message:n,locations:r,path:i,extensions:o}:{message:n,locations:r,path:i}}var Ax,Ox=Wn(()=>{fv();xx();mv();gv();_x();Ax=(function(t){MR(n,t);var e=NR(n);function n(r,i,o,s,c,p,h){var v,P,x,T;RR(this,n),T=e.call(this,r),T.name="GraphQLError",T.originalError=p!=null?p:void 0,T.nodes=Ix(Array.isArray(i)?i:i?[i]:void 0);for(var I=[],F=0,A=(O=T.nodes)!==null&&O!==void 0?O:[];F<A.length;F++){var O,N=A[F],V=N.loc;V!=null&&I.push(V);}I=Ix(I),T.source=o!=null?o:(v=I)===null||v===void 0?void 0:v[0].source,T.positions=s!=null?s:(P=I)===null||P===void 0?void 0:P.map(function(X){return X.start}),T.locations=s&&o?s.map(function(X){return qu(o,X)}):(x=I)===null||x===void 0?void 0:x.map(function(X){return qu(X.source,X.start)}),T.path=c!=null?c:void 0;var G=p==null?void 0:p.extensions;return h==null&&hv(G)?T.extensions=AR({},G):T.extensions=h!=null?h:{},Object.defineProperties(Yp(T),{message:{enumerable:true},locations:{enumerable:T.locations!=null},path:{enumerable:T.path!=null},extensions:{enumerable:T.extensions!=null&&Object.keys(T.extensions).length>0},name:{enumerable:false},nodes:{enumerable:false},source:{enumerable:false},positions:{enumerable:false},originalError:{enumerable:false}}),p!=null&&p.stack?(Object.defineProperty(Yp(T),"stack",{value:p.stack,writable:true,configurable:true}),kx(T)):(Error.captureStackTrace?Error.captureStackTrace(Yp(T),n):Object.defineProperty(Yp(T),"stack",{value:Error().stack,writable:true,configurable:true}),T)}return FR(n,[{key:"toString",value:function(){return BR(this)}},{key:"toJSON",value:function(){return UR(this)}},{key:$m,get:function(){return "Object"}}]),n})(bv(Error));});function oi(t,e,n){return new Ax("Syntax Error: ".concat(n),void 0,t,[e])}var vv=Wn(()=>{Ox();});var Se,Rx=Wn(()=>{Se=Object.freeze({NAME:"Name",DOCUMENT:"Document",OPERATION_DEFINITION:"OperationDefinition",VARIABLE_DEFINITION:"VariableDefinition",SELECTION_SET:"SelectionSet",FIELD:"Field",ARGUMENT:"Argument",FRAGMENT_SPREAD:"FragmentSpread",INLINE_FRAGMENT:"InlineFragment",FRAGMENT_DEFINITION:"FragmentDefinition",VARIABLE:"Variable",INT:"IntValue",FLOAT:"FloatValue",STRING:"StringValue",BOOLEAN:"BooleanValue",NULL:"NullValue",ENUM:"EnumValue",LIST:"ListValue",OBJECT:"ObjectValue",OBJECT_FIELD:"ObjectField",DIRECTIVE:"Directive",NAMED_TYPE:"NamedType",LIST_TYPE:"ListType",NON_NULL_TYPE:"NonNullType",SCHEMA_DEFINITION:"SchemaDefinition",OPERATION_TYPE_DEFINITION:"OperationTypeDefinition",SCALAR_TYPE_DEFINITION:"ScalarTypeDefinition",OBJECT_TYPE_DEFINITION:"ObjectTypeDefinition",FIELD_DEFINITION:"FieldDefinition",INPUT_VALUE_DEFINITION:"InputValueDefinition",INTERFACE_TYPE_DEFINITION:"InterfaceTypeDefinition",UNION_TYPE_DEFINITION:"UnionTypeDefinition",ENUM_TYPE_DEFINITION:"EnumTypeDefinition",ENUM_VALUE_DEFINITION:"EnumValueDefinition",INPUT_OBJECT_TYPE_DEFINITION:"InputObjectTypeDefinition",DIRECTIVE_DEFINITION:"DirectiveDefinition",SCHEMA_EXTENSION:"SchemaExtension",SCALAR_TYPE_EXTENSION:"ScalarTypeExtension",OBJECT_TYPE_EXTENSION:"ObjectTypeExtension",INTERFACE_TYPE_EXTENSION:"InterfaceTypeExtension",UNION_TYPE_EXTENSION:"UnionTypeExtension",ENUM_TYPE_EXTENSION:"EnumTypeExtension",INPUT_OBJECT_TYPE_EXTENSION:"InputObjectTypeExtension"});});function Cv(t,e){throw new Error("Unexpected invariant triggered.")}var Fx=Wn(()=>{});var $R,Xp,Sv=Wn(()=>{$R=typeof Symbol=="function"&&typeof Symbol.for=="function"?Symbol.for("nodejs.util.inspect.custom"):void 0,Xp=$R;});function Hm(t){var e=t.prototype.toJSON;typeof e=="function"||Cv(),t.prototype.inspect=e,Xp&&(t.prototype[Xp]=e);}var Mx=Wn(()=>{Fx();Sv();});var Wm,Yn,Pv=Wn(()=>{Mx();Wm=(function(){function t(n,r,i){this.start=n.start,this.end=r.end,this.startToken=n,this.endToken=r,this.source=i;}var e=t.prototype;return e.toJSON=function(){return {start:this.start,end:this.end}},t})();Hm(Wm);Yn=(function(){function t(n,r,i,o,s,c,p){this.kind=n,this.start=r,this.end=i,this.line=o,this.column=s,this.value=p,this.prev=c,this.next=null;}var e=t.prototype;return e.toJSON=function(){return {kind:this.kind,value:this.value,line:this.line,column:this.column}},t})();Hm(Yn);});var Ot,xv=Wn(()=>{Ot=Object.freeze({SOF:"<SOF>",EOF:"<EOF>",BANG:"!",DOLLAR:"$",AMP:"&",PAREN_L:"(",PAREN_R:")",SPREAD:"...",COLON:":",EQUALS:"=",AT:"@",BRACKET_L:"[",BRACKET_R:"]",BRACE_L:"{",PIPE:"|",BRACE_R:"}",NAME:"Name",INT:"Int",FLOAT:"Float",STRING:"String",BLOCK_STRING:"BlockString",COMMENT:"Comment"});});function qm(t){"@babel/helpers - typeof";return typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?qm=function(n){return typeof n}:qm=function(n){return n&&typeof Symbol=="function"&&n.constructor===Symbol&&n!==Symbol.prototype?"symbol":typeof n},qm(t)}function Ev(t){return Ym(t,[])}function Ym(t,e){switch(qm(t)){case "string":return JSON.stringify(t);case "function":return t.name?"[function ".concat(t.name,"]"):"[function]";case "object":return t===null?"null":jR(t,e);default:return String(t)}}function jR(t,e){if(e.indexOf(t)!==-1)return "[Circular]";var n=[].concat(e,[t]),r=HR(t);if(r!==void 0){var i=r.call(t);if(i!==t)return typeof i=="string"?i:Ym(i,n)}else if(Array.isArray(t))return zR(t,n);return VR(t,n)}function VR(t,e){var n=Object.keys(t);if(n.length===0)return "{}";if(e.length>Nx)return "["+WR(t)+"]";var r=n.map(function(i){var o=Ym(t[i],e);return i+": "+o});return "{ "+r.join(", ")+" }"}function zR(t,e){if(t.length===0)return "[]";if(e.length>Nx)return "[Array]";for(var n=Math.min(GR,t.length),r=t.length-n,i=[],o=0;o<n;++o)i.push(Ym(t[o],e));return r===1?i.push("... 1 more item"):r>1&&i.push("... ".concat(r," more items")),"["+i.join(", ")+"]"}function HR(t){var e=t[String(Xp)];if(typeof e=="function")return e;if(typeof t.inspect=="function")return t.inspect}function WR(t){var e=Object.prototype.toString.call(t).replace(/^\[object /,"").replace(/]$/,"");if(e==="Object"&&typeof t.constructor=="function"){var n=t.constructor.name;if(typeof n=="string"&&n!=="")return n}return e}var GR,Nx,Lx=Wn(()=>{Sv();GR=10,Nx=2;});var Bx,Ux=Wn(()=>{Bx=function(e,n){return e instanceof n};});function $x(t,e){for(var n=0;n<e.length;n++){var r=e[n];r.enumerable=r.enumerable||false,r.configurable=true,"value"in r&&(r.writable=true),Object.defineProperty(t,r.key,r);}}function qR(t,e,n){return e&&$x(t.prototype,e),t}function Gx(t){return Bx(t,Qm)}var Qm,jx=Wn(()=>{mv();Lx();fv();Ux();Qm=(function(){function t(e){var n=arguments.length>1&&arguments[1]!==void 0?arguments[1]:"GraphQL request",r=arguments.length>2&&arguments[2]!==void 0?arguments[2]:{line:1,column:1};typeof e=="string"||hc(0,"Body must be a string. Received: ".concat(Ev(e),".")),this.body=e,this.name=n,this.locationOffset=r,this.locationOffset.line>0||hc(0,"line in locationOffset is 1-indexed and must be positive."),this.locationOffset.column>0||hc(0,"column in locationOffset is 1-indexed and must be positive.");}return qR(t,[{key:$m,get:function(){return "Source"}}]),t})();});var _v,Vx=Wn(()=>{_v=Object.freeze({QUERY:"QUERY",MUTATION:"MUTATION",SUBSCRIPTION:"SUBSCRIPTION",FIELD:"FIELD",FRAGMENT_DEFINITION:"FRAGMENT_DEFINITION",FRAGMENT_SPREAD:"FRAGMENT_SPREAD",INLINE_FRAGMENT:"INLINE_FRAGMENT",VARIABLE_DEFINITION:"VARIABLE_DEFINITION",SCHEMA:"SCHEMA",SCALAR:"SCALAR",OBJECT:"OBJECT",FIELD_DEFINITION:"FIELD_DEFINITION",ARGUMENT_DEFINITION:"ARGUMENT_DEFINITION",INTERFACE:"INTERFACE",UNION:"UNION",ENUM:"ENUM",ENUM_VALUE:"ENUM_VALUE",INPUT_OBJECT:"INPUT_OBJECT",INPUT_FIELD_DEFINITION:"INPUT_FIELD_DEFINITION"});});function Hx(t){var e=t.split(/\r\n|[\n\r]/g),n=YR(t);if(n!==0)for(var r=1;r<e.length;r++)e[r]=e[r].slice(n);for(var i=0;i<e.length&&zx(e[i]);)++i;for(var o=e.length;o>i&&zx(e[o-1]);)--o;return e.slice(i,o).join(`
7
+ `+jm(t.source,c);}return e}function UR(t){var e;t||hc(0,"Received null or undefined error.");var n=(e=t.message)!==null&&e!==void 0?e:"An unknown error occurred.",r=t.locations,i=t.path,o=t.extensions;return o&&Object.keys(o).length>0?{message:n,locations:r,path:i,extensions:o}:{message:n,locations:r,path:i}}var Ax,Ox=Wn(()=>{fv();xx();mv();gv();_x();Ax=(function(t){MR(n,t);var e=NR(n);function n(r,i,o,s,c,p,h){var v,P,x,T;RR(this,n),T=e.call(this,r),T.name="GraphQLError",T.originalError=p!=null?p:void 0,T.nodes=Ix(Array.isArray(i)?i:i?[i]:void 0);for(var I=[],R=0,A=(O=T.nodes)!==null&&O!==void 0?O:[];R<A.length;R++){var O,N=A[R],V=N.loc;V!=null&&I.push(V);}I=Ix(I),T.source=o!=null?o:(v=I)===null||v===void 0?void 0:v[0].source,T.positions=s!=null?s:(P=I)===null||P===void 0?void 0:P.map(function(X){return X.start}),T.locations=s&&o?s.map(function(X){return qu(o,X)}):(x=I)===null||x===void 0?void 0:x.map(function(X){return qu(X.source,X.start)}),T.path=c!=null?c:void 0;var G=p==null?void 0:p.extensions;return h==null&&hv(G)?T.extensions=AR({},G):T.extensions=h!=null?h:{},Object.defineProperties(Yp(T),{message:{enumerable:true},locations:{enumerable:T.locations!=null},path:{enumerable:T.path!=null},extensions:{enumerable:T.extensions!=null&&Object.keys(T.extensions).length>0},name:{enumerable:false},nodes:{enumerable:false},source:{enumerable:false},positions:{enumerable:false},originalError:{enumerable:false}}),p!=null&&p.stack?(Object.defineProperty(Yp(T),"stack",{value:p.stack,writable:true,configurable:true}),kx(T)):(Error.captureStackTrace?Error.captureStackTrace(Yp(T),n):Object.defineProperty(Yp(T),"stack",{value:Error().stack,writable:true,configurable:true}),T)}return FR(n,[{key:"toString",value:function(){return BR(this)}},{key:"toJSON",value:function(){return UR(this)}},{key:$m,get:function(){return "Object"}}]),n})(bv(Error));});function oi(t,e,n){return new Ax("Syntax Error: ".concat(n),void 0,t,[e])}var vv=Wn(()=>{Ox();});var Se,Rx=Wn(()=>{Se=Object.freeze({NAME:"Name",DOCUMENT:"Document",OPERATION_DEFINITION:"OperationDefinition",VARIABLE_DEFINITION:"VariableDefinition",SELECTION_SET:"SelectionSet",FIELD:"Field",ARGUMENT:"Argument",FRAGMENT_SPREAD:"FragmentSpread",INLINE_FRAGMENT:"InlineFragment",FRAGMENT_DEFINITION:"FragmentDefinition",VARIABLE:"Variable",INT:"IntValue",FLOAT:"FloatValue",STRING:"StringValue",BOOLEAN:"BooleanValue",NULL:"NullValue",ENUM:"EnumValue",LIST:"ListValue",OBJECT:"ObjectValue",OBJECT_FIELD:"ObjectField",DIRECTIVE:"Directive",NAMED_TYPE:"NamedType",LIST_TYPE:"ListType",NON_NULL_TYPE:"NonNullType",SCHEMA_DEFINITION:"SchemaDefinition",OPERATION_TYPE_DEFINITION:"OperationTypeDefinition",SCALAR_TYPE_DEFINITION:"ScalarTypeDefinition",OBJECT_TYPE_DEFINITION:"ObjectTypeDefinition",FIELD_DEFINITION:"FieldDefinition",INPUT_VALUE_DEFINITION:"InputValueDefinition",INTERFACE_TYPE_DEFINITION:"InterfaceTypeDefinition",UNION_TYPE_DEFINITION:"UnionTypeDefinition",ENUM_TYPE_DEFINITION:"EnumTypeDefinition",ENUM_VALUE_DEFINITION:"EnumValueDefinition",INPUT_OBJECT_TYPE_DEFINITION:"InputObjectTypeDefinition",DIRECTIVE_DEFINITION:"DirectiveDefinition",SCHEMA_EXTENSION:"SchemaExtension",SCALAR_TYPE_EXTENSION:"ScalarTypeExtension",OBJECT_TYPE_EXTENSION:"ObjectTypeExtension",INTERFACE_TYPE_EXTENSION:"InterfaceTypeExtension",UNION_TYPE_EXTENSION:"UnionTypeExtension",ENUM_TYPE_EXTENSION:"EnumTypeExtension",INPUT_OBJECT_TYPE_EXTENSION:"InputObjectTypeExtension"});});function Cv(t,e){throw new Error("Unexpected invariant triggered.")}var Fx=Wn(()=>{});var $R,Xp,Sv=Wn(()=>{$R=typeof Symbol=="function"&&typeof Symbol.for=="function"?Symbol.for("nodejs.util.inspect.custom"):void 0,Xp=$R;});function Hm(t){var e=t.prototype.toJSON;typeof e=="function"||Cv(),t.prototype.inspect=e,Xp&&(t.prototype[Xp]=e);}var Mx=Wn(()=>{Fx();Sv();});var Wm,Yn,Pv=Wn(()=>{Mx();Wm=(function(){function t(n,r,i){this.start=n.start,this.end=r.end,this.startToken=n,this.endToken=r,this.source=i;}var e=t.prototype;return e.toJSON=function(){return {start:this.start,end:this.end}},t})();Hm(Wm);Yn=(function(){function t(n,r,i,o,s,c,p){this.kind=n,this.start=r,this.end=i,this.line=o,this.column=s,this.value=p,this.prev=c,this.next=null;}var e=t.prototype;return e.toJSON=function(){return {kind:this.kind,value:this.value,line:this.line,column:this.column}},t})();Hm(Yn);});var Ot,xv=Wn(()=>{Ot=Object.freeze({SOF:"<SOF>",EOF:"<EOF>",BANG:"!",DOLLAR:"$",AMP:"&",PAREN_L:"(",PAREN_R:")",SPREAD:"...",COLON:":",EQUALS:"=",AT:"@",BRACKET_L:"[",BRACKET_R:"]",BRACE_L:"{",PIPE:"|",BRACE_R:"}",NAME:"Name",INT:"Int",FLOAT:"Float",STRING:"String",BLOCK_STRING:"BlockString",COMMENT:"Comment"});});function qm(t){"@babel/helpers - typeof";return typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?qm=function(n){return typeof n}:qm=function(n){return n&&typeof Symbol=="function"&&n.constructor===Symbol&&n!==Symbol.prototype?"symbol":typeof n},qm(t)}function Ev(t){return Ym(t,[])}function Ym(t,e){switch(qm(t)){case "string":return JSON.stringify(t);case "function":return t.name?"[function ".concat(t.name,"]"):"[function]";case "object":return t===null?"null":jR(t,e);default:return String(t)}}function jR(t,e){if(e.indexOf(t)!==-1)return "[Circular]";var n=[].concat(e,[t]),r=HR(t);if(r!==void 0){var i=r.call(t);if(i!==t)return typeof i=="string"?i:Ym(i,n)}else if(Array.isArray(t))return zR(t,n);return VR(t,n)}function VR(t,e){var n=Object.keys(t);if(n.length===0)return "{}";if(e.length>Nx)return "["+WR(t)+"]";var r=n.map(function(i){var o=Ym(t[i],e);return i+": "+o});return "{ "+r.join(", ")+" }"}function zR(t,e){if(t.length===0)return "[]";if(e.length>Nx)return "[Array]";for(var n=Math.min(GR,t.length),r=t.length-n,i=[],o=0;o<n;++o)i.push(Ym(t[o],e));return r===1?i.push("... 1 more item"):r>1&&i.push("... ".concat(r," more items")),"["+i.join(", ")+"]"}function HR(t){var e=t[String(Xp)];if(typeof e=="function")return e;if(typeof t.inspect=="function")return t.inspect}function WR(t){var e=Object.prototype.toString.call(t).replace(/^\[object /,"").replace(/]$/,"");if(e==="Object"&&typeof t.constructor=="function"){var n=t.constructor.name;if(typeof n=="string"&&n!=="")return n}return e}var GR,Nx,Lx=Wn(()=>{Sv();GR=10,Nx=2;});var Bx,Ux=Wn(()=>{Bx=function(e,n){return e instanceof n};});function $x(t,e){for(var n=0;n<e.length;n++){var r=e[n];r.enumerable=r.enumerable||false,r.configurable=true,"value"in r&&(r.writable=true),Object.defineProperty(t,r.key,r);}}function qR(t,e,n){return e&&$x(t.prototype,e),t}function Gx(t){return Bx(t,Qm)}var Qm,jx=Wn(()=>{mv();Lx();fv();Ux();Qm=(function(){function t(e){var n=arguments.length>1&&arguments[1]!==void 0?arguments[1]:"GraphQL request",r=arguments.length>2&&arguments[2]!==void 0?arguments[2]:{line:1,column:1};typeof e=="string"||hc(0,"Body must be a string. Received: ".concat(Ev(e),".")),this.body=e,this.name=n,this.locationOffset=r,this.locationOffset.line>0||hc(0,"line in locationOffset is 1-indexed and must be positive."),this.locationOffset.column>0||hc(0,"column in locationOffset is 1-indexed and must be positive.");}return qR(t,[{key:$m,get:function(){return "Source"}}]),t})();});var _v,Vx=Wn(()=>{_v=Object.freeze({QUERY:"QUERY",MUTATION:"MUTATION",SUBSCRIPTION:"SUBSCRIPTION",FIELD:"FIELD",FRAGMENT_DEFINITION:"FRAGMENT_DEFINITION",FRAGMENT_SPREAD:"FRAGMENT_SPREAD",INLINE_FRAGMENT:"INLINE_FRAGMENT",VARIABLE_DEFINITION:"VARIABLE_DEFINITION",SCHEMA:"SCHEMA",SCALAR:"SCALAR",OBJECT:"OBJECT",FIELD_DEFINITION:"FIELD_DEFINITION",ARGUMENT_DEFINITION:"ARGUMENT_DEFINITION",INTERFACE:"INTERFACE",UNION:"UNION",ENUM:"ENUM",ENUM_VALUE:"ENUM_VALUE",INPUT_OBJECT:"INPUT_OBJECT",INPUT_FIELD_DEFINITION:"INPUT_FIELD_DEFINITION"});});function Hx(t){var e=t.split(/\r\n|[\n\r]/g),n=YR(t);if(n!==0)for(var r=1;r<e.length;r++)e[r]=e[r].slice(n);for(var i=0;i<e.length&&zx(e[i]);)++i;for(var o=e.length;o>i&&zx(e[o-1]);)--o;return e.slice(i,o).join(`
8
8
  `)}function zx(t){for(var e=0;e<t.length;++e)if(t[e]!==" "&&t[e]!==" ")return false;return true}function YR(t){for(var e,n=true,r=true,i=0,o=null,s=0;s<t.length;++s)switch(t.charCodeAt(s)){case 13:t.charCodeAt(s+1)===10&&++s;case 10:n=false,r=true,i=0;break;case 9:case 32:++i;break;default:r&&!n&&(o===null||i<o)&&(o=i),r=false;}return (e=o)!==null&&e!==void 0?e:0}var Wx=Wn(()=>{});function qx(t){return t===Ot.BANG||t===Ot.DOLLAR||t===Ot.AMP||t===Ot.PAREN_L||t===Ot.PAREN_R||t===Ot.SPREAD||t===Ot.COLON||t===Ot.EQUALS||t===Ot.AT||t===Ot.BRACKET_L||t===Ot.BRACKET_R||t===Ot.BRACE_L||t===Ot.PIPE||t===Ot.BRACE_R}function mc(t){return isNaN(t)?Ot.EOF:t<127?JSON.stringify(String.fromCharCode(t)):'"\\u'.concat(("00"+t.toString(16).toUpperCase()).slice(-4),'"')}function QR(t,e){for(var n=t.source,r=n.body,i=r.length,o=e.end;o<i;){var s=r.charCodeAt(o),c=t.line,p=1+o-t.lineStart;switch(s){case 65279:case 9:case 32:case 44:++o;continue;case 10:++o,++t.line,t.lineStart=o;continue;case 13:r.charCodeAt(o+1)===10?o+=2:++o,++t.line,t.lineStart=o;continue;case 33:return new Yn(Ot.BANG,o,o+1,c,p,e);case 35:return XR(n,o,c,p,e);case 36:return new Yn(Ot.DOLLAR,o,o+1,c,p,e);case 38:return new Yn(Ot.AMP,o,o+1,c,p,e);case 40:return new Yn(Ot.PAREN_L,o,o+1,c,p,e);case 41:return new Yn(Ot.PAREN_R,o,o+1,c,p,e);case 46:if(r.charCodeAt(o+1)===46&&r.charCodeAt(o+2)===46)return new Yn(Ot.SPREAD,o,o+3,c,p,e);break;case 58:return new Yn(Ot.COLON,o,o+1,c,p,e);case 61:return new Yn(Ot.EQUALS,o,o+1,c,p,e);case 64:return new Yn(Ot.AT,o,o+1,c,p,e);case 91:return new Yn(Ot.BRACKET_L,o,o+1,c,p,e);case 93:return new Yn(Ot.BRACKET_R,o,o+1,c,p,e);case 123:return new Yn(Ot.BRACE_L,o,o+1,c,p,e);case 124:return new Yn(Ot.PIPE,o,o+1,c,p,e);case 125:return new Yn(Ot.BRACE_R,o,o+1,c,p,e);case 34:return r.charCodeAt(o+1)===34&&r.charCodeAt(o+2)===34?tF(n,o,c,p,e,t):JR(n,o,c,p,e);case 45:case 48:case 49:case 50:case 51:case 52:case 53:case 54:case 55:case 56:case 57:return ZR(n,o,s,c,p,e);case 65:case 66:case 67:case 68:case 69:case 70:case 71:case 72:case 73:case 74:case 75:case 76:case 77:case 78:case 79:case 80:case 81:case 82:case 83:case 84:case 85:case 86:case 87:case 88:case 89:case 90:case 95:case 97:case 98:case 99:case 100:case 101:case 102:case 103:case 104:case 105:case 106:case 107:case 108:case 109:case 110:case 111:case 112:case 113:case 114:case 115:case 116:case 117:case 118:case 119:case 120:case 121:case 122:return nF(n,o,c,p,e)}throw oi(n,o,KR(s))}var h=t.line,v=1+o-t.lineStart;return new Yn(Ot.EOF,i,i,h,v,e)}function KR(t){return t<32&&t!==9&&t!==10&&t!==13?"Cannot contain the invalid character ".concat(mc(t),"."):t===39?`Unexpected single quote character ('), did you mean to use a double quote (")?`:"Cannot parse the unexpected character ".concat(mc(t),".")}function XR(t,e,n,r,i){var o=t.body,s,c=e;do s=o.charCodeAt(++c);while(!isNaN(s)&&(s>31||s===9));return new Yn(Ot.COMMENT,e,c,n,r,i,o.slice(e+1,c))}function ZR(t,e,n,r,i,o){var s=t.body,c=n,p=e,h=false;if(c===45&&(c=s.charCodeAt(++p)),c===48){if(c=s.charCodeAt(++p),c>=48&&c<=57)throw oi(t,p,"Invalid number, unexpected digit after 0: ".concat(mc(c),"."))}else p=Tv(t,p,c),c=s.charCodeAt(p);if(c===46&&(h=true,c=s.charCodeAt(++p),p=Tv(t,p,c),c=s.charCodeAt(p)),(c===69||c===101)&&(h=true,c=s.charCodeAt(++p),(c===43||c===45)&&(c=s.charCodeAt(++p)),p=Tv(t,p,c),c=s.charCodeAt(p)),c===46||rF(c))throw oi(t,p,"Invalid number, expected digit but got: ".concat(mc(c),"."));return new Yn(h?Ot.FLOAT:Ot.INT,e,p,r,i,o,s.slice(e,p))}function Tv(t,e,n){var r=t.body,i=e,o=n;if(o>=48&&o<=57){do o=r.charCodeAt(++i);while(o>=48&&o<=57);return i}throw oi(t,i,"Invalid number, expected digit but got: ".concat(mc(o),"."))}function JR(t,e,n,r,i){for(var o=t.body,s=e+1,c=s,p=0,h="";s<o.length&&!isNaN(p=o.charCodeAt(s))&&p!==10&&p!==13;){if(p===34)return h+=o.slice(c,s),new Yn(Ot.STRING,e,s+1,n,r,i,h);if(p<32&&p!==9)throw oi(t,s,"Invalid character within String: ".concat(mc(p),"."));if(++s,p===92){switch(h+=o.slice(c,s-1),p=o.charCodeAt(s),p){case 34:h+='"';break;case 47:h+="/";break;case 92:h+="\\";break;case 98:h+="\b";break;case 102:h+="\f";break;case 110:h+=`
9
9
  `;break;case 114:h+="\r";break;case 116:h+=" ";break;case 117:{var v=eF(o.charCodeAt(s+1),o.charCodeAt(s+2),o.charCodeAt(s+3),o.charCodeAt(s+4));if(v<0){var P=o.slice(s+1,s+5);throw oi(t,s,"Invalid character escape sequence: \\u".concat(P,"."))}h+=String.fromCharCode(v),s+=4;break}default:throw oi(t,s,"Invalid character escape sequence: \\".concat(String.fromCharCode(p),"."))}++s,c=s;}}throw oi(t,s,"Unterminated string.")}function tF(t,e,n,r,i,o){for(var s=t.body,c=e+3,p=c,h=0,v="";c<s.length&&!isNaN(h=s.charCodeAt(c));){if(h===34&&s.charCodeAt(c+1)===34&&s.charCodeAt(c+2)===34)return v+=s.slice(p,c),new Yn(Ot.BLOCK_STRING,e,c+3,n,r,i,Hx(v));if(h<32&&h!==9&&h!==10&&h!==13)throw oi(t,c,"Invalid character within String: ".concat(mc(h),"."));h===10?(++c,++o.line,o.lineStart=c):h===13?(s.charCodeAt(c+1)===10?c+=2:++c,++o.line,o.lineStart=c):h===92&&s.charCodeAt(c+1)===34&&s.charCodeAt(c+2)===34&&s.charCodeAt(c+3)===34?(v+=s.slice(p,c)+'"""',c+=4,p=c):++c;}throw oi(t,c,"Unterminated string.")}function eF(t,e,n,r){return Km(t)<<12|Km(e)<<8|Km(n)<<4|Km(r)}function Km(t){return t>=48&&t<=57?t-48:t>=65&&t<=70?t-55:t>=97&&t<=102?t-87:-1}function nF(t,e,n,r,i){for(var o=t.body,s=o.length,c=e+1,p=0;c!==s&&!isNaN(p=o.charCodeAt(c))&&(p===95||p>=48&&p<=57||p>=65&&p<=90||p>=97&&p<=122);)++c;return new Yn(Ot.NAME,e,c,n,r,i,o.slice(e,c))}function rF(t){return t===95||t>=65&&t<=90||t>=97&&t<=122}var wv,Yx=Wn(()=>{vv();Pv();xv();Wx();wv=(function(){function t(n){var r=new Yn(Ot.SOF,0,0,0,0,null);this.source=n,this.lastToken=r,this.token=r,this.line=1,this.lineStart=0;}var e=t.prototype;return e.advance=function(){this.lastToken=this.token;var r=this.token=this.lookahead();return r},e.lookahead=function(){var r=this.token;if(r.kind!==Ot.EOF)do{var i;r=(i=r.next)!==null&&i!==void 0?i:r.next=QR(this,r);}while(r.kind===Ot.COMMENT);return r},t})();});function Xm(t,e){var n=new iF(t,e);return n.parseDocument()}function Iv(t){var e=t.value;return Qx(t.kind)+(e!=null?' "'.concat(e,'"'):"")}function Qx(t){return qx(t)?'"'.concat(t,'"'):t}var iF,Kx=Wn(()=>{vv();Rx();Pv();xv();jx();Vx();Yx();iF=(function(){function t(n,r){var i=Gx(n)?n:new Qm(n);this._lexer=new wv(i),this._options=r;}var e=t.prototype;return e.parseName=function(){var r=this.expectToken(Ot.NAME);return {kind:Se.NAME,value:r.value,loc:this.loc(r)}},e.parseDocument=function(){var r=this._lexer.token;return {kind:Se.DOCUMENT,definitions:this.many(Ot.SOF,this.parseDefinition,Ot.EOF),loc:this.loc(r)}},e.parseDefinition=function(){if(this.peek(Ot.NAME))switch(this._lexer.token.value){case "query":case "mutation":case "subscription":return this.parseOperationDefinition();case "fragment":return this.parseFragmentDefinition();case "schema":case "scalar":case "type":case "interface":case "union":case "enum":case "input":case "directive":return this.parseTypeSystemDefinition();case "extend":return this.parseTypeSystemExtension()}else {if(this.peek(Ot.BRACE_L))return this.parseOperationDefinition();if(this.peekDescription())return this.parseTypeSystemDefinition()}throw this.unexpected()},e.parseOperationDefinition=function(){var r=this._lexer.token;if(this.peek(Ot.BRACE_L))return {kind:Se.OPERATION_DEFINITION,operation:"query",name:void 0,variableDefinitions:[],directives:[],selectionSet:this.parseSelectionSet(),loc:this.loc(r)};var i=this.parseOperationType(),o;return this.peek(Ot.NAME)&&(o=this.parseName()),{kind:Se.OPERATION_DEFINITION,operation:i,name:o,variableDefinitions:this.parseVariableDefinitions(),directives:this.parseDirectives(false),selectionSet:this.parseSelectionSet(),loc:this.loc(r)}},e.parseOperationType=function(){var r=this.expectToken(Ot.NAME);switch(r.value){case "query":return "query";case "mutation":return "mutation";case "subscription":return "subscription"}throw this.unexpected(r)},e.parseVariableDefinitions=function(){return this.optionalMany(Ot.PAREN_L,this.parseVariableDefinition,Ot.PAREN_R)},e.parseVariableDefinition=function(){var r=this._lexer.token;return {kind:Se.VARIABLE_DEFINITION,variable:this.parseVariable(),type:(this.expectToken(Ot.COLON),this.parseTypeReference()),defaultValue:this.expectOptionalToken(Ot.EQUALS)?this.parseValueLiteral(true):void 0,directives:this.parseDirectives(true),loc:this.loc(r)}},e.parseVariable=function(){var r=this._lexer.token;return this.expectToken(Ot.DOLLAR),{kind:Se.VARIABLE,name:this.parseName(),loc:this.loc(r)}},e.parseSelectionSet=function(){var r=this._lexer.token;return {kind:Se.SELECTION_SET,selections:this.many(Ot.BRACE_L,this.parseSelection,Ot.BRACE_R),loc:this.loc(r)}},e.parseSelection=function(){return this.peek(Ot.SPREAD)?this.parseFragment():this.parseField()},e.parseField=function(){var r=this._lexer.token,i=this.parseName(),o,s;return this.expectOptionalToken(Ot.COLON)?(o=i,s=this.parseName()):s=i,{kind:Se.FIELD,alias:o,name:s,arguments:this.parseArguments(false),directives:this.parseDirectives(false),selectionSet:this.peek(Ot.BRACE_L)?this.parseSelectionSet():void 0,loc:this.loc(r)}},e.parseArguments=function(r){var i=r?this.parseConstArgument:this.parseArgument;return this.optionalMany(Ot.PAREN_L,i,Ot.PAREN_R)},e.parseArgument=function(){var r=this._lexer.token,i=this.parseName();return this.expectToken(Ot.COLON),{kind:Se.ARGUMENT,name:i,value:this.parseValueLiteral(false),loc:this.loc(r)}},e.parseConstArgument=function(){var r=this._lexer.token;return {kind:Se.ARGUMENT,name:this.parseName(),value:(this.expectToken(Ot.COLON),this.parseValueLiteral(true)),loc:this.loc(r)}},e.parseFragment=function(){var r=this._lexer.token;this.expectToken(Ot.SPREAD);var i=this.expectOptionalKeyword("on");return !i&&this.peek(Ot.NAME)?{kind:Se.FRAGMENT_SPREAD,name:this.parseFragmentName(),directives:this.parseDirectives(false),loc:this.loc(r)}:{kind:Se.INLINE_FRAGMENT,typeCondition:i?this.parseNamedType():void 0,directives:this.parseDirectives(false),selectionSet:this.parseSelectionSet(),loc:this.loc(r)}},e.parseFragmentDefinition=function(){var r,i=this._lexer.token;return this.expectKeyword("fragment"),((r=this._options)===null||r===void 0?void 0:r.experimentalFragmentVariables)===true?{kind:Se.FRAGMENT_DEFINITION,name:this.parseFragmentName(),variableDefinitions:this.parseVariableDefinitions(),typeCondition:(this.expectKeyword("on"),this.parseNamedType()),directives:this.parseDirectives(false),selectionSet:this.parseSelectionSet(),loc:this.loc(i)}:{kind:Se.FRAGMENT_DEFINITION,name:this.parseFragmentName(),typeCondition:(this.expectKeyword("on"),this.parseNamedType()),directives:this.parseDirectives(false),selectionSet:this.parseSelectionSet(),loc:this.loc(i)}},e.parseFragmentName=function(){if(this._lexer.token.value==="on")throw this.unexpected();return this.parseName()},e.parseValueLiteral=function(r){var i=this._lexer.token;switch(i.kind){case Ot.BRACKET_L:return this.parseList(r);case Ot.BRACE_L:return this.parseObject(r);case Ot.INT:return this._lexer.advance(),{kind:Se.INT,value:i.value,loc:this.loc(i)};case Ot.FLOAT:return this._lexer.advance(),{kind:Se.FLOAT,value:i.value,loc:this.loc(i)};case Ot.STRING:case Ot.BLOCK_STRING:return this.parseStringLiteral();case Ot.NAME:switch(this._lexer.advance(),i.value){case "true":return {kind:Se.BOOLEAN,value:true,loc:this.loc(i)};case "false":return {kind:Se.BOOLEAN,value:false,loc:this.loc(i)};case "null":return {kind:Se.NULL,loc:this.loc(i)};default:return {kind:Se.ENUM,value:i.value,loc:this.loc(i)}}case Ot.DOLLAR:if(!r)return this.parseVariable();break}throw this.unexpected()},e.parseStringLiteral=function(){var r=this._lexer.token;return this._lexer.advance(),{kind:Se.STRING,value:r.value,block:r.kind===Ot.BLOCK_STRING,loc:this.loc(r)}},e.parseList=function(r){var i=this,o=this._lexer.token,s=function(){return i.parseValueLiteral(r)};return {kind:Se.LIST,values:this.any(Ot.BRACKET_L,s,Ot.BRACKET_R),loc:this.loc(o)}},e.parseObject=function(r){var i=this,o=this._lexer.token,s=function(){return i.parseObjectField(r)};return {kind:Se.OBJECT,fields:this.any(Ot.BRACE_L,s,Ot.BRACE_R),loc:this.loc(o)}},e.parseObjectField=function(r){var i=this._lexer.token,o=this.parseName();return this.expectToken(Ot.COLON),{kind:Se.OBJECT_FIELD,name:o,value:this.parseValueLiteral(r),loc:this.loc(i)}},e.parseDirectives=function(r){for(var i=[];this.peek(Ot.AT);)i.push(this.parseDirective(r));return i},e.parseDirective=function(r){var i=this._lexer.token;return this.expectToken(Ot.AT),{kind:Se.DIRECTIVE,name:this.parseName(),arguments:this.parseArguments(r),loc:this.loc(i)}},e.parseTypeReference=function(){var r=this._lexer.token,i;return this.expectOptionalToken(Ot.BRACKET_L)?(i=this.parseTypeReference(),this.expectToken(Ot.BRACKET_R),i={kind:Se.LIST_TYPE,type:i,loc:this.loc(r)}):i=this.parseNamedType(),this.expectOptionalToken(Ot.BANG)?{kind:Se.NON_NULL_TYPE,type:i,loc:this.loc(r)}:i},e.parseNamedType=function(){var r=this._lexer.token;return {kind:Se.NAMED_TYPE,name:this.parseName(),loc:this.loc(r)}},e.parseTypeSystemDefinition=function(){var r=this.peekDescription()?this._lexer.lookahead():this._lexer.token;if(r.kind===Ot.NAME)switch(r.value){case "schema":return this.parseSchemaDefinition();case "scalar":return this.parseScalarTypeDefinition();case "type":return this.parseObjectTypeDefinition();case "interface":return this.parseInterfaceTypeDefinition();case "union":return this.parseUnionTypeDefinition();case "enum":return this.parseEnumTypeDefinition();case "input":return this.parseInputObjectTypeDefinition();case "directive":return this.parseDirectiveDefinition()}throw this.unexpected(r)},e.peekDescription=function(){return this.peek(Ot.STRING)||this.peek(Ot.BLOCK_STRING)},e.parseDescription=function(){if(this.peekDescription())return this.parseStringLiteral()},e.parseSchemaDefinition=function(){var r=this._lexer.token,i=this.parseDescription();this.expectKeyword("schema");var o=this.parseDirectives(true),s=this.many(Ot.BRACE_L,this.parseOperationTypeDefinition,Ot.BRACE_R);return {kind:Se.SCHEMA_DEFINITION,description:i,directives:o,operationTypes:s,loc:this.loc(r)}},e.parseOperationTypeDefinition=function(){var r=this._lexer.token,i=this.parseOperationType();this.expectToken(Ot.COLON);var o=this.parseNamedType();return {kind:Se.OPERATION_TYPE_DEFINITION,operation:i,type:o,loc:this.loc(r)}},e.parseScalarTypeDefinition=function(){var r=this._lexer.token,i=this.parseDescription();this.expectKeyword("scalar");var o=this.parseName(),s=this.parseDirectives(true);return {kind:Se.SCALAR_TYPE_DEFINITION,description:i,name:o,directives:s,loc:this.loc(r)}},e.parseObjectTypeDefinition=function(){var r=this._lexer.token,i=this.parseDescription();this.expectKeyword("type");var o=this.parseName(),s=this.parseImplementsInterfaces(),c=this.parseDirectives(true),p=this.parseFieldsDefinition();return {kind:Se.OBJECT_TYPE_DEFINITION,description:i,name:o,interfaces:s,directives:c,fields:p,loc:this.loc(r)}},e.parseImplementsInterfaces=function(){var r;if(!this.expectOptionalKeyword("implements"))return [];if(((r=this._options)===null||r===void 0?void 0:r.allowLegacySDLImplementsInterfaces)===true){var i=[];this.expectOptionalToken(Ot.AMP);do i.push(this.parseNamedType());while(this.expectOptionalToken(Ot.AMP)||this.peek(Ot.NAME));return i}return this.delimitedMany(Ot.AMP,this.parseNamedType)},e.parseFieldsDefinition=function(){var r;return ((r=this._options)===null||r===void 0?void 0:r.allowLegacySDLEmptyFields)===true&&this.peek(Ot.BRACE_L)&&this._lexer.lookahead().kind===Ot.BRACE_R?(this._lexer.advance(),this._lexer.advance(),[]):this.optionalMany(Ot.BRACE_L,this.parseFieldDefinition,Ot.BRACE_R)},e.parseFieldDefinition=function(){var r=this._lexer.token,i=this.parseDescription(),o=this.parseName(),s=this.parseArgumentDefs();this.expectToken(Ot.COLON);var c=this.parseTypeReference(),p=this.parseDirectives(true);return {kind:Se.FIELD_DEFINITION,description:i,name:o,arguments:s,type:c,directives:p,loc:this.loc(r)}},e.parseArgumentDefs=function(){return this.optionalMany(Ot.PAREN_L,this.parseInputValueDef,Ot.PAREN_R)},e.parseInputValueDef=function(){var r=this._lexer.token,i=this.parseDescription(),o=this.parseName();this.expectToken(Ot.COLON);var s=this.parseTypeReference(),c;this.expectOptionalToken(Ot.EQUALS)&&(c=this.parseValueLiteral(true));var p=this.parseDirectives(true);return {kind:Se.INPUT_VALUE_DEFINITION,description:i,name:o,type:s,defaultValue:c,directives:p,loc:this.loc(r)}},e.parseInterfaceTypeDefinition=function(){var r=this._lexer.token,i=this.parseDescription();this.expectKeyword("interface");var o=this.parseName(),s=this.parseImplementsInterfaces(),c=this.parseDirectives(true),p=this.parseFieldsDefinition();return {kind:Se.INTERFACE_TYPE_DEFINITION,description:i,name:o,interfaces:s,directives:c,fields:p,loc:this.loc(r)}},e.parseUnionTypeDefinition=function(){var r=this._lexer.token,i=this.parseDescription();this.expectKeyword("union");var o=this.parseName(),s=this.parseDirectives(true),c=this.parseUnionMemberTypes();return {kind:Se.UNION_TYPE_DEFINITION,description:i,name:o,directives:s,types:c,loc:this.loc(r)}},e.parseUnionMemberTypes=function(){return this.expectOptionalToken(Ot.EQUALS)?this.delimitedMany(Ot.PIPE,this.parseNamedType):[]},e.parseEnumTypeDefinition=function(){var r=this._lexer.token,i=this.parseDescription();this.expectKeyword("enum");var o=this.parseName(),s=this.parseDirectives(true),c=this.parseEnumValuesDefinition();return {kind:Se.ENUM_TYPE_DEFINITION,description:i,name:o,directives:s,values:c,loc:this.loc(r)}},e.parseEnumValuesDefinition=function(){return this.optionalMany(Ot.BRACE_L,this.parseEnumValueDefinition,Ot.BRACE_R)},e.parseEnumValueDefinition=function(){var r=this._lexer.token,i=this.parseDescription(),o=this.parseName(),s=this.parseDirectives(true);return {kind:Se.ENUM_VALUE_DEFINITION,description:i,name:o,directives:s,loc:this.loc(r)}},e.parseInputObjectTypeDefinition=function(){var r=this._lexer.token,i=this.parseDescription();this.expectKeyword("input");var o=this.parseName(),s=this.parseDirectives(true),c=this.parseInputFieldsDefinition();return {kind:Se.INPUT_OBJECT_TYPE_DEFINITION,description:i,name:o,directives:s,fields:c,loc:this.loc(r)}},e.parseInputFieldsDefinition=function(){return this.optionalMany(Ot.BRACE_L,this.parseInputValueDef,Ot.BRACE_R)},e.parseTypeSystemExtension=function(){var r=this._lexer.lookahead();if(r.kind===Ot.NAME)switch(r.value){case "schema":return this.parseSchemaExtension();case "scalar":return this.parseScalarTypeExtension();case "type":return this.parseObjectTypeExtension();case "interface":return this.parseInterfaceTypeExtension();case "union":return this.parseUnionTypeExtension();case "enum":return this.parseEnumTypeExtension();case "input":return this.parseInputObjectTypeExtension()}throw this.unexpected(r)},e.parseSchemaExtension=function(){var r=this._lexer.token;this.expectKeyword("extend"),this.expectKeyword("schema");var i=this.parseDirectives(true),o=this.optionalMany(Ot.BRACE_L,this.parseOperationTypeDefinition,Ot.BRACE_R);if(i.length===0&&o.length===0)throw this.unexpected();return {kind:Se.SCHEMA_EXTENSION,directives:i,operationTypes:o,loc:this.loc(r)}},e.parseScalarTypeExtension=function(){var r=this._lexer.token;this.expectKeyword("extend"),this.expectKeyword("scalar");var i=this.parseName(),o=this.parseDirectives(true);if(o.length===0)throw this.unexpected();return {kind:Se.SCALAR_TYPE_EXTENSION,name:i,directives:o,loc:this.loc(r)}},e.parseObjectTypeExtension=function(){var r=this._lexer.token;this.expectKeyword("extend"),this.expectKeyword("type");var i=this.parseName(),o=this.parseImplementsInterfaces(),s=this.parseDirectives(true),c=this.parseFieldsDefinition();if(o.length===0&&s.length===0&&c.length===0)throw this.unexpected();return {kind:Se.OBJECT_TYPE_EXTENSION,name:i,interfaces:o,directives:s,fields:c,loc:this.loc(r)}},e.parseInterfaceTypeExtension=function(){var r=this._lexer.token;this.expectKeyword("extend"),this.expectKeyword("interface");var i=this.parseName(),o=this.parseImplementsInterfaces(),s=this.parseDirectives(true),c=this.parseFieldsDefinition();if(o.length===0&&s.length===0&&c.length===0)throw this.unexpected();return {kind:Se.INTERFACE_TYPE_EXTENSION,name:i,interfaces:o,directives:s,fields:c,loc:this.loc(r)}},e.parseUnionTypeExtension=function(){var r=this._lexer.token;this.expectKeyword("extend"),this.expectKeyword("union");var i=this.parseName(),o=this.parseDirectives(true),s=this.parseUnionMemberTypes();if(o.length===0&&s.length===0)throw this.unexpected();return {kind:Se.UNION_TYPE_EXTENSION,name:i,directives:o,types:s,loc:this.loc(r)}},e.parseEnumTypeExtension=function(){var r=this._lexer.token;this.expectKeyword("extend"),this.expectKeyword("enum");var i=this.parseName(),o=this.parseDirectives(true),s=this.parseEnumValuesDefinition();if(o.length===0&&s.length===0)throw this.unexpected();return {kind:Se.ENUM_TYPE_EXTENSION,name:i,directives:o,values:s,loc:this.loc(r)}},e.parseInputObjectTypeExtension=function(){var r=this._lexer.token;this.expectKeyword("extend"),this.expectKeyword("input");var i=this.parseName(),o=this.parseDirectives(true),s=this.parseInputFieldsDefinition();if(o.length===0&&s.length===0)throw this.unexpected();return {kind:Se.INPUT_OBJECT_TYPE_EXTENSION,name:i,directives:o,fields:s,loc:this.loc(r)}},e.parseDirectiveDefinition=function(){var r=this._lexer.token,i=this.parseDescription();this.expectKeyword("directive"),this.expectToken(Ot.AT);var o=this.parseName(),s=this.parseArgumentDefs(),c=this.expectOptionalKeyword("repeatable");this.expectKeyword("on");var p=this.parseDirectiveLocations();return {kind:Se.DIRECTIVE_DEFINITION,description:i,name:o,arguments:s,repeatable:c,locations:p,loc:this.loc(r)}},e.parseDirectiveLocations=function(){return this.delimitedMany(Ot.PIPE,this.parseDirectiveLocation)},e.parseDirectiveLocation=function(){var r=this._lexer.token,i=this.parseName();if(_v[i.value]!==void 0)return i;throw this.unexpected(r)},e.loc=function(r){var i;if(((i=this._options)===null||i===void 0?void 0:i.noLocation)!==true)return new Wm(r,this._lexer.lastToken,this._lexer.source)},e.peek=function(r){return this._lexer.token.kind===r},e.expectToken=function(r){var i=this._lexer.token;if(i.kind===r)return this._lexer.advance(),i;throw oi(this._lexer.source,i.start,"Expected ".concat(Qx(r),", found ").concat(Iv(i),"."))},e.expectOptionalToken=function(r){var i=this._lexer.token;if(i.kind===r)return this._lexer.advance(),i},e.expectKeyword=function(r){var i=this._lexer.token;if(i.kind===Ot.NAME&&i.value===r)this._lexer.advance();else throw oi(this._lexer.source,i.start,'Expected "'.concat(r,'", found ').concat(Iv(i),"."))},e.expectOptionalKeyword=function(r){var i=this._lexer.token;return i.kind===Ot.NAME&&i.value===r?(this._lexer.advance(),true):false},e.unexpected=function(r){var i=r!=null?r:this._lexer.token;return oi(this._lexer.source,i.start,"Unexpected ".concat(Iv(i),"."))},e.any=function(r,i,o){this.expectToken(r);for(var s=[];!this.expectOptionalToken(o);)s.push(i.call(this));return s},e.optionalMany=function(r,i,o){if(this.expectOptionalToken(r)){var s=[];do s.push(i.call(this));while(!this.expectOptionalToken(o));return s}return []},e.many=function(r,i,o){this.expectToken(r);var s=[];do s.push(i.call(this));while(!this.expectOptionalToken(o));return s},e.delimitedMany=function(r,i){this.expectOptionalToken(r);var o=[];do o.push(i.call(this));while(this.expectOptionalToken(r));return o},t})();});var Xx=Wn(()=>{Kx();});var Zx=Wn(()=>{Xx();});var oE={};K1(oE,{default:()=>dF,disableExperimentalFragmentVariables:()=>iE,disableFragmentWarnings:()=>nE,enableExperimentalFragmentVariables:()=>rE,gql:()=>gc,resetCaches:()=>eE});function tE(t){return t.replace(/[\s,]+/g," ").trim()}function sF(t){return tE(t.source.body.substring(t.start,t.end))}function lF(t){var e=new Set,n=[];return t.definitions.forEach(function(r){if(r.kind==="FragmentDefinition"){var i=r.name.value,o=sF(r.loc),s=kv.get(i);s&&!s.has(o)?Jx&&console.warn("Warning: fragment with name "+i+` already exists.
10
10
  graphql-tag enforces all fragment names across your application to be unique; read more about
@@ -2291,19 +2291,19 @@ ${C.FeatureFragmentDoc}`;C.OnPackagePublishedDocument=(0, Pt.default)`
2291
2291
  ...CreditBalanceUpdatedPayload
2292
2292
  }
2293
2293
  }
2294
- ${C.CreditBalanceUpdatedPayloadFragmentDoc}`;var wN=(t,e,n)=>t();function IN(t,e=wN){return {ProvisionCustomer(n,r){return e(i=>t.request(C.ProvisionCustomerDocument,n,Object.assign(Object.assign({},r),i)),"ProvisionCustomer","mutation")},ImportCustomerBulk(n,r){return e(i=>t.request(C.ImportCustomerBulkDocument,n,Object.assign(Object.assign({},r),i)),"ImportCustomerBulk","mutation")},ImportCustomer(n,r){return e(i=>t.request(C.ImportCustomerDocument,n,Object.assign(Object.assign({},r),i)),"ImportCustomer","mutation")},UpdateCustomer(n,r){return e(i=>t.request(C.UpdateCustomerDocument,n,Object.assign(Object.assign({},r),i)),"UpdateCustomer","mutation")},DetachCustomerPaymentMethod(n,r){return e(i=>t.request(C.DetachCustomerPaymentMethodDocument,n,Object.assign(Object.assign({},r),i)),"DetachCustomerPaymentMethod","mutation")},GrantPromotionalEntitlements(n,r){return e(i=>t.request(C.GrantPromotionalEntitlementsDocument,n,Object.assign(Object.assign({},r),i)),"GrantPromotionalEntitlements","mutation")},RevokePromotionalEntitlement(n,r){return e(i=>t.request(C.RevokePromotionalEntitlementDocument,n,Object.assign(Object.assign({},r),i)),"RevokePromotionalEntitlement","mutation")},ProvisionSubscription(n,r){return e(i=>t.request(C.ProvisionSubscriptionDocument,n,Object.assign(Object.assign({},r),i)),"ProvisionSubscription","mutation")},ApplySubscription(n,r){return e(i=>t.request(C.ApplySubscriptionDocument,n,Object.assign(Object.assign({},r),i)),"ApplySubscription","mutation")},ImportSubscriptionsBulk(n,r){return e(i=>t.request(C.ImportSubscriptionsBulkDocument,n,Object.assign(Object.assign({},r),i)),"ImportSubscriptionsBulk","mutation")},UpdateSubscription(n,r){return e(i=>t.request(C.UpdateSubscriptionDocument,n,Object.assign(Object.assign({},r),i)),"UpdateSubscription","mutation")},CancelSubscription(n,r){return e(i=>t.request(C.CancelSubscriptionDocument,n,Object.assign(Object.assign({},r),i)),"CancelSubscription","mutation")},EstimateSubscription(n,r){return e(i=>t.request(C.EstimateSubscriptionDocument,n,Object.assign(Object.assign({},r),i)),"EstimateSubscription","mutation")},EstimateSubscriptionUpdate(n,r){return e(i=>t.request(C.EstimateSubscriptionUpdateDocument,n,Object.assign(Object.assign({},r),i)),"EstimateSubscriptionUpdate","mutation")},PreviewSubscription(n,r){return e(i=>t.request(C.PreviewSubscriptionDocument,n,Object.assign(Object.assign({},r),i)),"PreviewSubscription","mutation")},PreviewNextInvoice(n,r){return e(i=>t.request(C.PreviewNextInvoiceDocument,n,Object.assign(Object.assign({},r),i)),"PreviewNextInvoice","mutation")},CancelSubscriptionUpdates(n,r){return e(i=>t.request(C.CancelSubscriptionUpdatesDocument,n,Object.assign(Object.assign({},r),i)),"CancelSubscriptionUpdates","mutation")},ReportUsage(n,r){return e(i=>t.request(C.ReportUsageDocument,n,Object.assign(Object.assign({},r),i)),"ReportUsage","mutation")},ReportUsageBulk(n,r){return e(i=>t.request(C.ReportUsageBulkDocument,n,Object.assign(Object.assign({},r),i)),"ReportUsageBulk","mutation")},ReportEvent(n,r){return e(i=>t.request(C.ReportEventDocument,n,Object.assign(Object.assign({},r),i)),"ReportEvent","mutation")},ReportEntitlementCheckRequested(n,r){return e(i=>t.request(C.ReportEntitlementCheckRequestedDocument,n,Object.assign(Object.assign({},r),i)),"ReportEntitlementCheckRequested","mutation")},CreateSubscription(n,r){return e(i=>t.request(C.CreateSubscriptionDocument,n,Object.assign(Object.assign({},r),i)),"CreateSubscription","mutation")},MigrateSubscriptionToLatest(n,r){return e(i=>t.request(C.MigrateSubscriptionToLatestDocument,n,Object.assign(Object.assign({},r),i)),"MigrateSubscriptionToLatest","mutation")},ArchiveCustomer(n,r){return e(i=>t.request(C.ArchiveCustomerDocument,n,Object.assign(Object.assign({},r),i)),"ArchiveCustomer","mutation")},UnarchiveCustomer(n,r){return e(i=>t.request(C.UnarchiveCustomerDocument,n,Object.assign(Object.assign({},r),i)),"UnarchiveCustomer","mutation")},TransferSubscription(n,r){return e(i=>t.request(C.TransferSubscriptionDocument,n,Object.assign(Object.assign({},r),i)),"TransferSubscription","mutation")},DelegateSubscriptionToCustomer(n,r){return e(i=>t.request(C.DelegateSubscriptionToCustomerDocument,n,Object.assign(Object.assign({},r),i)),"DelegateSubscriptionToCustomer","mutation")},TransferSubscriptionToResource(n,r){return e(i=>t.request(C.TransferSubscriptionToResourceDocument,n,Object.assign(Object.assign({},r),i)),"TransferSubscriptionToResource","mutation")},GrantCredits(n,r){return e(i=>t.request(C.GrantCreditsDocument,n,Object.assign(Object.assign({},r),i)),"GrantCredits","mutation")},GrantPromotionalEntitlementsGroup(n,r){return e(i=>t.request(C.GrantPromotionalEntitlementsGroupDocument,n,Object.assign(Object.assign({},r),i)),"GrantPromotionalEntitlementsGroup","mutation")},RevokePromotionalEntitlementsGroup(n,r){return e(i=>t.request(C.RevokePromotionalEntitlementsGroupDocument,n,Object.assign(Object.assign({},r),i)),"RevokePromotionalEntitlementsGroup","mutation")},UnlinkPromotionalEntitlementsGroup(n,r){return e(i=>t.request(C.UnlinkPromotionalEntitlementsGroupDocument,n,Object.assign(Object.assign({},r),i)),"UnlinkPromotionalEntitlementsGroup","mutation")},CreatePaymentSession(n,r){return e(i=>t.request(C.CreatePaymentSessionDocument,n,Object.assign(Object.assign({},r),i)),"CreatePaymentSession","mutation")},VoidCreditGrant(n,r){return e(i=>t.request(C.VoidCreditGrantDocument,n,Object.assign(Object.assign({},r),i)),"VoidCreditGrant","mutation")},GetCustomerById(n,r){return e(i=>t.request(C.GetCustomerByIdDocument,n,Object.assign(Object.assign({},r),i)),"GetCustomerById","query")},GetCustomerStatistics(n,r){return e(i=>t.request(C.GetCustomerStatisticsDocument,n,Object.assign(Object.assign({},r),i)),"GetCustomerStatistics","query")},GetActiveSubscriptions(n,r){return e(i=>t.request(C.GetActiveSubscriptionsDocument,n,Object.assign(Object.assign({},r),i)),"GetActiveSubscriptions","query")},GetActiveSubscriptionsList(n,r){return e(i=>t.request(C.GetActiveSubscriptionsListDocument,n,Object.assign(Object.assign({},r),i)),"GetActiveSubscriptionsList","query")},GetSubscriptions(n,r){return e(i=>t.request(C.GetSubscriptionsDocument,n,Object.assign(Object.assign({},r),i)),"GetSubscriptions","query")},GetSubscription(n,r){return e(i=>t.request(C.GetSubscriptionDocument,n,Object.assign(Object.assign({},r),i)),"GetSubscription","query")},GetCoupons(n,r){return e(i=>t.request(C.GetCouponsDocument,n,Object.assign(Object.assign({},r),i)),"GetCoupons","query")},GetPaywall(n,r){return e(i=>t.request(C.GetPaywallDocument,n,Object.assign(Object.assign({},r),i)),"GetPaywall","query")},GetEntitlements(n,r){return e(i=>t.request(C.GetEntitlementsDocument,n,Object.assign(Object.assign({},r),i)),"GetEntitlements","query")},GetEntitlementsState(n,r){return e(i=>t.request(C.GetEntitlementsStateDocument,n,Object.assign(Object.assign({},r),i)),"GetEntitlementsState","query")},GetEntitlement(n,r){return e(i=>t.request(C.GetEntitlementDocument,n,Object.assign(Object.assign({},r),i)),"GetEntitlement","query")},GetProducts(n,r){return e(i=>t.request(C.GetProductsDocument,n,Object.assign(Object.assign({},r),i)),"GetProducts","query")},GetSdkConfiguration(n,r){return e(i=>t.request(C.GetSdkConfigurationDocument,n,Object.assign(Object.assign({},r),i)),"GetSdkConfiguration","query")},GetCustomerPortalByRefId(n,r){return e(i=>t.request(C.GetCustomerPortalByRefIdDocument,n,Object.assign(Object.assign({},r),i)),"GetCustomerPortalByRefId","query")},GetCheckoutState(n,r){return e(i=>t.request(C.GetCheckoutStateDocument,n,Object.assign(Object.assign({},r),i)),"GetCheckoutState","query")},GetMockPaywall(n,r){return e(i=>t.request(C.GetMockPaywallDocument,n,Object.assign(Object.assign({},r),i)),"GetMockPaywall","query")},GetUsageHistory(n,r){return e(i=>t.request(C.GetUsageHistoryDocument,n,Object.assign(Object.assign({},r),i)),"GetUsageHistory","query")},GetUsageHistoryV2(n,r){return e(i=>t.request(C.GetUsageHistoryV2Document,n,Object.assign(Object.assign({},r),i)),"GetUsageHistoryV2","query")},GetCreditBalance(n,r){return e(i=>t.request(C.GetCreditBalanceDocument,n,Object.assign(Object.assign({},r),i)),"GetCreditBalance","query")},GetCreditGrants(n,r){return e(i=>t.request(C.GetCreditGrantsDocument,n,Object.assign(Object.assign({},r),i)),"GetCreditGrants","query")},GetCreditLedger(n,r){return e(i=>t.request(C.GetCreditLedgerDocument,n,Object.assign(Object.assign({},r),i)),"GetCreditLedger","query")},GetCreditUsage(n,r){return e(i=>t.request(C.GetCreditUsageDocument,n,Object.assign(Object.assign({},r),i)),"GetCreditUsage","query")},OnEntitlementsUpdated(n,r){return e(i=>t.request(C.OnEntitlementsUpdatedDocument,n,Object.assign(Object.assign({},r),i)),"OnEntitlementsUpdated","subscription")},OnUsageUpdated(n,r){return e(i=>t.request(C.OnUsageUpdatedDocument,n,Object.assign(Object.assign({},r),i)),"OnUsageUpdated","subscription")},OnPackagePublished(n,r){return e(i=>t.request(C.OnPackagePublishedDocument,n,Object.assign(Object.assign({},r),i)),"OnPackagePublished","subscription")},OnCreditBalanceUpdated(n,r){return e(i=>t.request(C.OnCreditBalanceUpdatedDocument,n,Object.assign(Object.assign({},r),i)),"OnCreditBalanceUpdated","subscription")}}}C.getSdk=IN;});var Qk={2991:(t,e,n)=>{n.d(e,{R:()=>o,Y:()=>s});var r=n(2176),i={};function o(){return (0, r.KV)()?n.g:typeof window!="undefined"?window:typeof self!="undefined"?self:i}function s(c,p,h){var v=h||o(),P=v.__SENTRY__=v.__SENTRY__||{};return P[c]||(P[c]=p())}},2176:(t,e,n)=>{function r(){return !(typeof __SENTRY_BROWSER_BUNDLE__!="undefined"&&__SENTRY_BROWSER_BUNDLE__)&&Object.prototype.toString.call(typeof process!="undefined"?process:0)==="[object process]"}function i(o,s){return o.require(s)}n.d(e,{l$:()=>i,KV:()=>r}),t=n.hmd(t);},1170:(t,e,n)=>{n.d(e,{yW:()=>p,ph:()=>h});var r=n(2991),i=n(2176);t=n.hmd(t);var o={nowSeconds:()=>Date.now()/1e3},s=(0, i.KV)()?(function(){try{return (0,i.l$)(t,"perf_hooks").performance}catch(P){return}})():(function(){let{performance:P}=(0, r.R)();if(P&&P.now)return {now:()=>P.now(),timeOrigin:Date.now()-P.now()}})(),c=s===void 0?o:{nowSeconds:()=>(s.timeOrigin+s.now())/1e3},p=o.nowSeconds.bind(o),h=c.nowSeconds.bind(c);(()=>{let{performance:P}=(0, r.R)();if(P&&P.now){var x=36e5,T=P.now(),I=Date.now(),F=P.timeOrigin?Math.abs(P.timeOrigin+T-I):x,A=F<x,O=P.timing&&P.timing.navigationStart,N=typeof O=="number"?Math.abs(O+T-I):x;return A||N<x?F<=N?(P.timeOrigin):(O):(I)}})();},1905:function(){(function(t){(function(e){var n="URLSearchParams"in t,r="Symbol"in t&&"iterator"in Symbol,i="FileReader"in t&&"Blob"in t&&(function(){try{return new Blob,!0}catch(U){return false}})(),o="FormData"in t,s="ArrayBuffer"in t;if(s)var c=["[object Int8Array]","[object Uint8Array]","[object Uint8ClampedArray]","[object Int16Array]","[object Uint16Array]","[object Int32Array]","[object Uint32Array]","[object Float32Array]","[object Float64Array]"],p=ArrayBuffer.isView||function(U){return U&&c.indexOf(Object.prototype.toString.call(U))>-1};function h(U){if(typeof U!="string"&&(U=String(U)),/[^a-z0-9\-#$%&'*+.^_`|~]/i.test(U))throw new TypeError("Invalid character in header field name");return U.toLowerCase()}function v(U){return typeof U!="string"&&(U=String(U)),U}function P(U){var j={next:function(){var ut=U.shift();return {done:ut===void 0,value:ut}}};return r&&(j[Symbol.iterator]=function(){return j}),j}function x(U){this.map={},U instanceof x?U.forEach((function(j,ut){this.append(ut,j);}),this):Array.isArray(U)?U.forEach((function(j){this.append(j[0],j[1]);}),this):U&&Object.getOwnPropertyNames(U).forEach((function(j){this.append(j,U[j]);}),this);}function T(U){if(U.bodyUsed)return Promise.reject(new TypeError("Already read"));U.bodyUsed=true;}function I(U){return new Promise((function(j,ut){U.onload=function(){j(U.result);},U.onerror=function(){ut(U.error);};}))}function F(U){var j=new FileReader,ut=I(j);return j.readAsArrayBuffer(U),ut}function A(U){if(U.slice)return U.slice(0);var j=new Uint8Array(U.byteLength);return j.set(new Uint8Array(U)),j.buffer}function O(){return this.bodyUsed=false,this._initBody=function(U){var j;this._bodyInit=U,U?typeof U=="string"?this._bodyText=U:i&&Blob.prototype.isPrototypeOf(U)?this._bodyBlob=U:o&&FormData.prototype.isPrototypeOf(U)?this._bodyFormData=U:n&&URLSearchParams.prototype.isPrototypeOf(U)?this._bodyText=U.toString():s&&i&&(j=U)&&DataView.prototype.isPrototypeOf(j)?(this._bodyArrayBuffer=A(U.buffer),this._bodyInit=new Blob([this._bodyArrayBuffer])):s&&(ArrayBuffer.prototype.isPrototypeOf(U)||p(U))?this._bodyArrayBuffer=A(U):this._bodyText=U=Object.prototype.toString.call(U):this._bodyText="",this.headers.get("content-type")||(typeof U=="string"?this.headers.set("content-type","text/plain;charset=UTF-8"):this._bodyBlob&&this._bodyBlob.type?this.headers.set("content-type",this._bodyBlob.type):n&&URLSearchParams.prototype.isPrototypeOf(U)&&this.headers.set("content-type","application/x-www-form-urlencoded;charset=UTF-8"));},i&&(this.blob=function(){var U=T(this);if(U)return U;if(this._bodyBlob)return Promise.resolve(this._bodyBlob);if(this._bodyArrayBuffer)return Promise.resolve(new Blob([this._bodyArrayBuffer]));if(this._bodyFormData)throw new Error("could not read FormData body as blob");return Promise.resolve(new Blob([this._bodyText]))},this.arrayBuffer=function(){return this._bodyArrayBuffer?T(this)||Promise.resolve(this._bodyArrayBuffer):this.blob().then(F)}),this.text=function(){var U,j,ut,Y=T(this);if(Y)return Y;if(this._bodyBlob)return U=this._bodyBlob,ut=I(j=new FileReader),j.readAsText(U),ut;if(this._bodyArrayBuffer)return Promise.resolve((function(at){for(var pt=new Uint8Array(at),dt=new Array(pt.length),mt=0;mt<pt.length;mt++)dt[mt]=String.fromCharCode(pt[mt]);return dt.join("")})(this._bodyArrayBuffer));if(this._bodyFormData)throw new Error("could not read FormData body as text");return Promise.resolve(this._bodyText)},o&&(this.formData=function(){return this.text().then(G)}),this.json=function(){return this.text().then(JSON.parse)},this}x.prototype.append=function(U,j){U=h(U),j=v(j);var ut=this.map[U];this.map[U]=ut?ut+", "+j:j;},x.prototype.delete=function(U){delete this.map[h(U)];},x.prototype.get=function(U){return U=h(U),this.has(U)?this.map[U]:null},x.prototype.has=function(U){return this.map.hasOwnProperty(h(U))},x.prototype.set=function(U,j){this.map[h(U)]=v(j);},x.prototype.forEach=function(U,j){for(var ut in this.map)this.map.hasOwnProperty(ut)&&U.call(j,this.map[ut],ut,this);},x.prototype.keys=function(){var U=[];return this.forEach((function(j,ut){U.push(ut);})),P(U)},x.prototype.values=function(){var U=[];return this.forEach((function(j){U.push(j);})),P(U)},x.prototype.entries=function(){var U=[];return this.forEach((function(j,ut){U.push([ut,j]);})),P(U)},r&&(x.prototype[Symbol.iterator]=x.prototype.entries);var N=["DELETE","GET","HEAD","OPTIONS","POST","PUT"];function V(U,j){var ut,Y,at=(j=j||{}).body;if(U instanceof V){if(U.bodyUsed)throw new TypeError("Already read");this.url=U.url,this.credentials=U.credentials,j.headers||(this.headers=new x(U.headers)),this.method=U.method,this.mode=U.mode,this.signal=U.signal,at||U._bodyInit==null||(at=U._bodyInit,U.bodyUsed=true);}else this.url=String(U);if(this.credentials=j.credentials||this.credentials||"same-origin",!j.headers&&this.headers||(this.headers=new x(j.headers)),this.method=(Y=(ut=j.method||this.method||"GET").toUpperCase(),N.indexOf(Y)>-1?Y:ut),this.mode=j.mode||this.mode||null,this.signal=j.signal||this.signal,this.referrer=null,(this.method==="GET"||this.method==="HEAD")&&at)throw new TypeError("Body not allowed for GET or HEAD requests");this._initBody(at);}function G(U){var j=new FormData;return U.trim().split("&").forEach((function(ut){if(ut){var Y=ut.split("="),at=Y.shift().replace(/\+/g," "),pt=Y.join("=").replace(/\+/g," ");j.append(decodeURIComponent(at),decodeURIComponent(pt));}})),j}function X(U,j){j||(j={}),this.type="default",this.status=j.status===void 0?200:j.status,this.ok=this.status>=200&&this.status<300,this.statusText="statusText"in j?j.statusText:"OK",this.headers=new x(j.headers),this.url=j.url||"",this._initBody(U);}V.prototype.clone=function(){return new V(this,{body:this._bodyInit})},O.call(V.prototype),O.call(X.prototype),X.prototype.clone=function(){return new X(this._bodyInit,{status:this.status,statusText:this.statusText,headers:new x(this.headers),url:this.url})},X.error=function(){var U=new X(null,{status:0,statusText:""});return U.type="error",U};var nt=[301,302,303,307,308];X.redirect=function(U,j){if(nt.indexOf(j)===-1)throw new RangeError("Invalid status code");return new X(null,{status:j,headers:{location:U}})},e.DOMException=t.DOMException;try{new e.DOMException;}catch(U){e.DOMException=function(j,ut){this.message=j,this.name=ut;var Y=Error(j);this.stack=Y.stack;},e.DOMException.prototype=Object.create(Error.prototype),e.DOMException.prototype.constructor=e.DOMException;}function st(U,j){return new Promise((function(ut,Y){var at=new V(U,j);if(at.signal&&at.signal.aborted)return Y(new e.DOMException("Aborted","AbortError"));var pt=new XMLHttpRequest;function dt(){pt.abort();}pt.onload=function(){var mt,Ct,jt={status:pt.status,statusText:pt.statusText,headers:(mt=pt.getAllResponseHeaders()||"",Ct=new x,mt.replace(/\r?\n[\t ]+/g," ").split(/\r?\n/).forEach((function(Jt){var ee=Jt.split(":"),re=ee.shift().trim();if(re){var Ee=ee.join(":").trim();Ct.append(re,Ee);}})),Ct)};jt.url="responseURL"in pt?pt.responseURL:jt.headers.get("X-Request-URL");var Gt="response"in pt?pt.response:pt.responseText;ut(new X(Gt,jt));},pt.onerror=function(){Y(new TypeError("Network request failed"));},pt.ontimeout=function(){Y(new TypeError("Network request failed"));},pt.onabort=function(){Y(new e.DOMException("Aborted","AbortError"));},pt.open(at.method,at.url,true),at.credentials==="include"?pt.withCredentials=true:at.credentials==="omit"&&(pt.withCredentials=false),"responseType"in pt&&i&&(pt.responseType="blob"),at.headers.forEach((function(mt,Ct){pt.setRequestHeader(Ct,mt);})),at.signal&&(at.signal.addEventListener("abort",dt),pt.onreadystatechange=function(){pt.readyState===4&&at.signal.removeEventListener("abort",dt);}),pt.send(at._bodyInit===void 0?null:at._bodyInit);}))}st.polyfill=true,t.fetch||(t.fetch=st,t.Headers=x,t.Request=V,t.Response=X),e.Headers=x,e.Request=V,e.Response=X,e.fetch=st,Object.defineProperty(e,"__esModule",{value:true});})({});})(typeof self!="undefined"?self:this);},7484:function(t){t.exports=(function(){var e=6e4,n=36e5,r="millisecond",i="second",o="minute",s="hour",c="day",p="week",h="month",v="quarter",P="year",x="date",T="Invalid Date",I=/^(\d{4})[-/]?(\d{1,2})?[-/]?(\d{0,2})[Tt\s]*(\d{1,2})?:?(\d{1,2})?:?(\d{1,2})?[.:]?(\d+)?$/,F=/\[([^\]]+)]|Y{1,4}|M{1,4}|D{1,2}|d{1,4}|H{1,2}|h{1,2}|a|A|m{1,2}|s{1,2}|Z{1,2}|SSS/g,A={name:"en",weekdays:"Sunday_Monday_Tuesday_Wednesday_Thursday_Friday_Saturday".split("_"),months:"January_February_March_April_May_June_July_August_September_October_November_December".split("_"),ordinal:function(at){var pt=["th","st","nd","rd"],dt=at%100;return "["+at+(pt[(dt-20)%10]||pt[dt]||pt[0])+"]"}},O=function(at,pt,dt){var mt=String(at);return !mt||mt.length>=pt?at:""+Array(pt+1-mt.length).join(dt)+at},N={s:O,z:function(at){var pt=-at.utcOffset(),dt=Math.abs(pt),mt=Math.floor(dt/60),Ct=dt%60;return (pt<=0?"+":"-")+O(mt,2,"0")+":"+O(Ct,2,"0")},m:function at(pt,dt){if(pt.date()<dt.date())return -at(dt,pt);var mt=12*(dt.year()-pt.year())+(dt.month()-pt.month()),Ct=pt.clone().add(mt,h),jt=dt-Ct<0,Gt=pt.clone().add(mt+(jt?-1:1),h);return +(-(mt+(dt-Ct)/(jt?Ct-Gt:Gt-Ct))||0)},a:function(at){return at<0?Math.ceil(at)||0:Math.floor(at)},p:function(at){return {M:h,y:P,w:p,d:c,D:x,h:s,m:o,s:i,ms:r,Q:v}[at]||String(at||"").toLowerCase().replace(/s$/,"")},u:function(at){return at===void 0}},V="en",G={};G[V]=A;var X="$isDayjsObject",nt=function(at){return at instanceof ut||!(!at||!at[X])},st=function at(pt,dt,mt){var Ct;if(!pt)return V;if(typeof pt=="string"){var jt=pt.toLowerCase();G[jt]&&(Ct=jt),dt&&(G[jt]=dt,Ct=jt);var Gt=pt.split("-");if(!Ct&&Gt.length>1)return at(Gt[0])}else {var Jt=pt.name;G[Jt]=pt,Ct=Jt;}return !mt&&Ct&&(V=Ct),Ct||!mt&&V},U=function(at,pt){if(nt(at))return at.clone();var dt=typeof pt=="object"?pt:{};return dt.date=at,dt.args=arguments,new ut(dt)},j=N;j.l=st,j.i=nt,j.w=function(at,pt){return U(at,{locale:pt.$L,utc:pt.$u,x:pt.$x,$offset:pt.$offset})};var ut=(function(){function at(dt){this.$L=st(dt.locale,null,true),this.parse(dt),this.$x=this.$x||dt.x||{},this[X]=true;}var pt=at.prototype;return pt.parse=function(dt){this.$d=(function(mt){var Ct=mt.date,jt=mt.utc;if(Ct===null)return new Date(NaN);if(j.u(Ct))return new Date;if(Ct instanceof Date)return new Date(Ct);if(typeof Ct=="string"&&!/Z$/i.test(Ct)){var Gt=Ct.match(I);if(Gt){var Jt=Gt[2]-1||0,ee=(Gt[7]||"0").substring(0,3);return jt?new Date(Date.UTC(Gt[1],Jt,Gt[3]||1,Gt[4]||0,Gt[5]||0,Gt[6]||0,ee)):new Date(Gt[1],Jt,Gt[3]||1,Gt[4]||0,Gt[5]||0,Gt[6]||0,ee)}}return new Date(Ct)})(dt),this.init();},pt.init=function(){var dt=this.$d;this.$y=dt.getFullYear(),this.$M=dt.getMonth(),this.$D=dt.getDate(),this.$W=dt.getDay(),this.$H=dt.getHours(),this.$m=dt.getMinutes(),this.$s=dt.getSeconds(),this.$ms=dt.getMilliseconds();},pt.$utils=function(){return j},pt.isValid=function(){return this.$d.toString()!==T},pt.isSame=function(dt,mt){var Ct=U(dt);return this.startOf(mt)<=Ct&&Ct<=this.endOf(mt)},pt.isAfter=function(dt,mt){return U(dt)<this.startOf(mt)},pt.isBefore=function(dt,mt){return this.endOf(mt)<U(dt)},pt.$g=function(dt,mt,Ct){return j.u(dt)?this[mt]:this.set(Ct,dt)},pt.unix=function(){return Math.floor(this.valueOf()/1e3)},pt.valueOf=function(){return this.$d.getTime()},pt.startOf=function(dt,mt){var Ct=this,jt=!!j.u(mt)||mt,Gt=j.p(dt),Jt=function(Gn,ln){var Ke=j.w(Ct.$u?Date.UTC(Ct.$y,ln,Gn):new Date(Ct.$y,ln,Gn),Ct);return jt?Ke:Ke.endOf(c)},ee=function(Gn,ln){return j.w(Ct.toDate()[Gn].apply(Ct.toDate("s"),(jt?[0,0,0,0]:[23,59,59,999]).slice(ln)),Ct)},re=this.$W,Ee=this.$M,je=this.$D,sn="set"+(this.$u?"UTC":"");switch(Gt){case P:return jt?Jt(1,0):Jt(31,11);case h:return jt?Jt(1,Ee):Jt(0,Ee+1);case p:var Ze=this.$locale().weekStart||0,Pn=(re<Ze?re+7:re)-Ze;return Jt(jt?je-Pn:je+(6-Pn),Ee);case c:case x:return ee(sn+"Hours",0);case s:return ee(sn+"Minutes",1);case o:return ee(sn+"Seconds",2);case i:return ee(sn+"Milliseconds",3);default:return this.clone()}},pt.endOf=function(dt){return this.startOf(dt,false)},pt.$set=function(dt,mt){var Ct,jt=j.p(dt),Gt="set"+(this.$u?"UTC":""),Jt=(Ct={},Ct[c]=Gt+"Date",Ct[x]=Gt+"Date",Ct[h]=Gt+"Month",Ct[P]=Gt+"FullYear",Ct[s]=Gt+"Hours",Ct[o]=Gt+"Minutes",Ct[i]=Gt+"Seconds",Ct[r]=Gt+"Milliseconds",Ct)[jt],ee=jt===c?this.$D+(mt-this.$W):mt;if(jt===h||jt===P){var re=this.clone().set(x,1);re.$d[Jt](ee),re.init(),this.$d=re.set(x,Math.min(this.$D,re.daysInMonth())).$d;}else Jt&&this.$d[Jt](ee);return this.init(),this},pt.set=function(dt,mt){return this.clone().$set(dt,mt)},pt.get=function(dt){return this[j.p(dt)]()},pt.add=function(dt,mt){var Ct,jt=this;dt=Number(dt);var Gt=j.p(mt),Jt=function(Ee){var je=U(jt);return j.w(je.date(je.date()+Math.round(Ee*dt)),jt)};if(Gt===h)return this.set(h,this.$M+dt);if(Gt===P)return this.set(P,this.$y+dt);if(Gt===c)return Jt(1);if(Gt===p)return Jt(7);var ee=(Ct={},Ct[o]=e,Ct[s]=n,Ct[i]=1e3,Ct)[Gt]||1,re=this.$d.getTime()+dt*ee;return j.w(re,this)},pt.subtract=function(dt,mt){return this.add(-1*dt,mt)},pt.format=function(dt){var mt=this,Ct=this.$locale();if(!this.isValid())return Ct.invalidDate||T;var jt=dt||"YYYY-MM-DDTHH:mm:ssZ",Gt=j.z(this),Jt=this.$H,ee=this.$m,re=this.$M,Ee=Ct.weekdays,je=Ct.months,sn=Ct.meridiem,Ze=function(ln,Ke,dn,or){return ln&&(ln[Ke]||ln(mt,jt))||dn[Ke].slice(0,or)},Pn=function(ln){return j.s(Jt%12||12,ln,"0")},Gn=sn||function(ln,Ke,dn){var or=ln<12?"AM":"PM";return dn?or.toLowerCase():or};return jt.replace(F,(function(ln,Ke){return Ke||(function(dn){switch(dn){case "YY":return String(mt.$y).slice(-2);case "YYYY":return j.s(mt.$y,4,"0");case "M":return re+1;case "MM":return j.s(re+1,2,"0");case "MMM":return Ze(Ct.monthsShort,re,je,3);case "MMMM":return Ze(je,re);case "D":return mt.$D;case "DD":return j.s(mt.$D,2,"0");case "d":return String(mt.$W);case "dd":return Ze(Ct.weekdaysMin,mt.$W,Ee,2);case "ddd":return Ze(Ct.weekdaysShort,mt.$W,Ee,3);case "dddd":return Ee[mt.$W];case "H":return String(Jt);case "HH":return j.s(Jt,2,"0");case "h":return Pn(1);case "hh":return Pn(2);case "a":return Gn(Jt,ee,true);case "A":return Gn(Jt,ee,false);case "m":return String(ee);case "mm":return j.s(ee,2,"0");case "s":return String(mt.$s);case "ss":return j.s(mt.$s,2,"0");case "SSS":return j.s(mt.$ms,3,"0");case "Z":return Gt}return null})(ln)||Gt.replace(":","")}))},pt.utcOffset=function(){return 15*-Math.round(this.$d.getTimezoneOffset()/15)},pt.diff=function(dt,mt,Ct){var jt,Gt=this,Jt=j.p(mt),ee=U(dt),re=(ee.utcOffset()-this.utcOffset())*e,Ee=this-ee,je=function(){return j.m(Gt,ee)};switch(Jt){case P:jt=je()/12;break;case h:jt=je();break;case v:jt=je()/3;break;case p:jt=(Ee-re)/6048e5;break;case c:jt=(Ee-re)/864e5;break;case s:jt=Ee/n;break;case o:jt=Ee/e;break;case i:jt=Ee/1e3;break;default:jt=Ee;}return Ct?jt:j.a(jt)},pt.daysInMonth=function(){return this.endOf(h).$D},pt.$locale=function(){return G[this.$L]},pt.locale=function(dt,mt){if(!dt)return this.$L;var Ct=this.clone(),jt=st(dt,mt,true);return jt&&(Ct.$L=jt),Ct},pt.clone=function(){return j.w(this.$d,this)},pt.toDate=function(){return new Date(this.valueOf())},pt.toJSON=function(){return this.isValid()?this.toISOString():null},pt.toISOString=function(){return this.$d.toISOString()},pt.toString=function(){return this.$d.toUTCString()},at})(),Y=ut.prototype;return U.prototype=Y,[["$ms",r],["$s",i],["$m",o],["$H",s],["$W",c],["$M",h],["$y",P],["$D",x]].forEach((function(at){Y[at[1]]=function(pt){return this.$g(pt,at[0],at[1])};})),U.extend=function(at,pt){return at.$i||(at(pt,ut,U),at.$i=true),U},U.locale=st,U.isDayjs=nt,U.unix=function(at){return U(1e3*at)},U.en=G[V],U.Ls=G,U.p={},U})();},7187:t=>{var e,n=typeof Reflect=="object"?Reflect:null,r=n&&typeof n.apply=="function"?n.apply:function(A,O,N){return Function.prototype.apply.call(A,O,N)};e=n&&typeof n.ownKeys=="function"?n.ownKeys:Object.getOwnPropertySymbols?function(A){return Object.getOwnPropertyNames(A).concat(Object.getOwnPropertySymbols(A))}:function(A){return Object.getOwnPropertyNames(A)};var i=Number.isNaN||function(A){return A!=A};function o(){o.init.call(this);}t.exports=o,t.exports.once=function(A,O){return new Promise((function(N,V){function G(nt){A.removeListener(O,X),V(nt);}function X(){typeof A.removeListener=="function"&&A.removeListener("error",G),N([].slice.call(arguments));}F(A,O,X,{once:true}),O!=="error"&&(function(nt,st,U){typeof nt.on=="function"&&F(nt,"error",st,{once:true});})(A,G);}))},o.EventEmitter=o,o.prototype._events=void 0,o.prototype._eventsCount=0,o.prototype._maxListeners=void 0;var s=10;function c(A){if(typeof A!="function")throw new TypeError('The "listener" argument must be of type Function. Received type '+typeof A)}function p(A){return A._maxListeners===void 0?o.defaultMaxListeners:A._maxListeners}function h(A,O,N,V){var G,X,nt,st;if(c(N),(X=A._events)===void 0?(X=A._events=Object.create(null),A._eventsCount=0):(X.newListener!==void 0&&(A.emit("newListener",O,N.listener?N.listener:N),X=A._events),nt=X[O]),nt===void 0)nt=X[O]=N,++A._eventsCount;else if(typeof nt=="function"?nt=X[O]=V?[N,nt]:[nt,N]:V?nt.unshift(N):nt.push(N),(G=p(A))>0&&nt.length>G&&!nt.warned){nt.warned=true;var U=new Error("Possible EventEmitter memory leak detected. "+nt.length+" "+String(O)+" listeners added. Use emitter.setMaxListeners() to increase limit");U.name="MaxListenersExceededWarning",U.emitter=A,U.type=O,U.count=nt.length,st=U,console&&console.warn&&console.warn(st);}return A}function v(){if(!this.fired)return this.target.removeListener(this.type,this.wrapFn),this.fired=true,arguments.length===0?this.listener.call(this.target):this.listener.apply(this.target,arguments)}function P(A,O,N){var V={fired:false,wrapFn:void 0,target:A,type:O,listener:N},G=v.bind(V);return G.listener=N,V.wrapFn=G,G}function x(A,O,N){var V=A._events;if(V===void 0)return [];var G=V[O];return G===void 0?[]:typeof G=="function"?N?[G.listener||G]:[G]:N?(function(X){for(var nt=new Array(X.length),st=0;st<nt.length;++st)nt[st]=X[st].listener||X[st];return nt})(G):I(G,G.length)}function T(A){var O=this._events;if(O!==void 0){var N=O[A];if(typeof N=="function")return 1;if(N!==void 0)return N.length}return 0}function I(A,O){for(var N=new Array(O),V=0;V<O;++V)N[V]=A[V];return N}function F(A,O,N,V){if(typeof A.on=="function")V.once?A.once(O,N):A.on(O,N);else {if(typeof A.addEventListener!="function")throw new TypeError('The "emitter" argument must be of type EventEmitter. Received type '+typeof A);A.addEventListener(O,(function G(X){V.once&&A.removeEventListener(O,G),N(X);}));}}Object.defineProperty(o,"defaultMaxListeners",{enumerable:true,get:function(){return s},set:function(A){if(typeof A!="number"||A<0||i(A))throw new RangeError('The value of "defaultMaxListeners" is out of range. It must be a non-negative number. Received '+A+".");s=A;}}),o.init=function(){this._events!==void 0&&this._events!==Object.getPrototypeOf(this)._events||(this._events=Object.create(null),this._eventsCount=0),this._maxListeners=this._maxListeners||void 0;},o.prototype.setMaxListeners=function(A){if(typeof A!="number"||A<0||i(A))throw new RangeError('The value of "n" is out of range. It must be a non-negative number. Received '+A+".");return this._maxListeners=A,this},o.prototype.getMaxListeners=function(){return p(this)},o.prototype.emit=function(A){for(var O=[],N=1;N<arguments.length;N++)O.push(arguments[N]);var V=A==="error",G=this._events;if(G!==void 0)V=V&&G.error===void 0;else if(!V)return false;if(V){var X;if(O.length>0&&(X=O[0]),X instanceof Error)throw X;var nt=new Error("Unhandled error."+(X?" ("+X.message+")":""));throw nt.context=X,nt}var st=G[A];if(st===void 0)return false;if(typeof st=="function")r(st,this,O);else {var U=st.length,j=I(st,U);for(N=0;N<U;++N)r(j[N],this,O);}return true},o.prototype.addListener=function(A,O){return h(this,A,O,false)},o.prototype.on=o.prototype.addListener,o.prototype.prependListener=function(A,O){return h(this,A,O,true)},o.prototype.once=function(A,O){return c(O),this.on(A,P(this,A,O)),this},o.prototype.prependOnceListener=function(A,O){return c(O),this.prependListener(A,P(this,A,O)),this},o.prototype.removeListener=function(A,O){var N,V,G,X,nt;if(c(O),(V=this._events)===void 0)return this;if((N=V[A])===void 0)return this;if(N===O||N.listener===O)--this._eventsCount==0?this._events=Object.create(null):(delete V[A],V.removeListener&&this.emit("removeListener",A,N.listener||O));else if(typeof N!="function"){for(G=-1,X=N.length-1;X>=0;X--)if(N[X]===O||N[X].listener===O){nt=N[X].listener,G=X;break}if(G<0)return this;G===0?N.shift():(function(st,U){for(;U+1<st.length;U++)st[U]=st[U+1];st.pop();})(N,G),N.length===1&&(V[A]=N[0]),V.removeListener!==void 0&&this.emit("removeListener",A,nt||O);}return this},o.prototype.off=o.prototype.removeListener,o.prototype.removeAllListeners=function(A){var O,N,V;if((N=this._events)===void 0)return this;if(N.removeListener===void 0)return arguments.length===0?(this._events=Object.create(null),this._eventsCount=0):N[A]!==void 0&&(--this._eventsCount==0?this._events=Object.create(null):delete N[A]),this;if(arguments.length===0){var G,X=Object.keys(N);for(V=0;V<X.length;++V)(G=X[V])!=="removeListener"&&this.removeAllListeners(G);return this.removeAllListeners("removeListener"),this._events=Object.create(null),this._eventsCount=0,this}if(typeof(O=N[A])=="function")this.removeListener(A,O);else if(O!==void 0)for(V=O.length-1;V>=0;V--)this.removeListener(A,O[V]);return this},o.prototype.listeners=function(A){return x(this,A,true)},o.prototype.rawListeners=function(A){return x(this,A,false)},o.listenerCount=function(A,O){return typeof A.listenerCount=="function"?A.listenerCount(O):T.call(A,O)},o.prototype.listenerCount=T,o.prototype.eventNames=function(){return this._eventsCount>0?e(this._events):[]};},4139:function(t){t.exports=(function(){function e(r){return Number.isInteger(r)&&r>=0}function n(r){this.name="ArgumentError",this.message=r;}return function(r,i){if(i=i||{},typeof r!="function")throw new n("fetch must be a function");if(typeof i!="object")throw new n("defaults must be an object");if(i.retries!==void 0&&!e(i.retries))throw new n("retries must be a positive integer");if(i.retryDelay!==void 0&&!e(i.retryDelay)&&typeof i.retryDelay!="function")throw new n("retryDelay must be a positive integer or a function returning a positive integer");if(i.retryOn!==void 0&&!Array.isArray(i.retryOn)&&typeof i.retryOn!="function")throw new n("retryOn property expects an array or function");return i=Object.assign({retries:3,retryDelay:1e3,retryOn:[]},i),function(o,s){var c=i.retries,p=i.retryDelay,h=i.retryOn;if(s&&s.retries!==void 0){if(!e(s.retries))throw new n("retries must be a positive integer");c=s.retries;}if(s&&s.retryDelay!==void 0){if(!e(s.retryDelay)&&typeof s.retryDelay!="function")throw new n("retryDelay must be a positive integer or a function returning a positive integer");p=s.retryDelay;}if(s&&s.retryOn){if(!Array.isArray(s.retryOn)&&typeof s.retryOn!="function")throw new n("retryOn property expects an array or function");h=s.retryOn;}return new Promise((function(v,P){var x=function(I){var F=typeof Request!="undefined"&&o instanceof Request?o.clone():o;r(F,s).then((function(A){if(Array.isArray(h)&&h.indexOf(A.status)===-1)v(A);else if(typeof h=="function")try{return Promise.resolve(h(I,null,A)).then((function(O){O?T(I,null,A):v(A);})).catch(P)}catch(O){P(O);}else I<c?T(I,null,A):v(A);})).catch((function(A){if(typeof h=="function")try{Promise.resolve(h(I,A,null)).then((function(O){O?T(I,A,null):P(A);})).catch((function(O){P(O);}));}catch(O){P(O);}else I<c?T(I,A,null):P(A);}));};function T(I,F,A){var O=typeof p=="function"?p(I,F,A):p;setTimeout((function(){x(++I);}),O);}x(0);}))}}})();},5185:(t,e,n)=>{n.r(e),n.d(e,{default:()=>Vt,disableExperimentalFragmentVariables:()=>Jn,disableFragmentWarnings:()=>ar,enableExperimentalFragmentVariables:()=>sr,gql:()=>Ve,resetCaches:()=>bt});var r=function(){return r=Object.assign||function(gt){for(var ot,Z=1,it=arguments.length;Z<it;Z++)for(var _t in ot=arguments[Z])Object.prototype.hasOwnProperty.call(ot,_t)&&(gt[_t]=ot[_t]);return gt},r.apply(this,arguments)};function i(gt){return i=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(ot){return typeof ot}:function(ot){return ot&&typeof Symbol=="function"&&ot.constructor===Symbol&&ot!==Symbol.prototype?"symbol":typeof ot},i(gt)}var o=n(9763);function s(gt,ot){for(var Z,it=/\r\n|[\n\r]/g,_t=1,ft=ot+1;(Z=it.exec(gt.body))&&Z.index<ot;)_t+=1,ft=ot+1-(Z.index+Z[0].length);return {line:_t,column:ft}}function c(gt){return p(gt.source,s(gt.source,gt.start))}function p(gt,ot){var Z=gt.locationOffset.column-1,it=v(Z)+gt.body,_t=ot.line-1,ft=gt.locationOffset.line-1,Lt=ot.line+ft,It=ot.line===1?Z:0,Nt=ot.column+It,se="".concat(gt.name,":").concat(Lt,":").concat(Nt,`
2294
+ ${C.CreditBalanceUpdatedPayloadFragmentDoc}`;var wN=(t,e,n)=>t();function IN(t,e=wN){return {ProvisionCustomer(n,r){return e(i=>t.request(C.ProvisionCustomerDocument,n,Object.assign(Object.assign({},r),i)),"ProvisionCustomer","mutation")},ImportCustomerBulk(n,r){return e(i=>t.request(C.ImportCustomerBulkDocument,n,Object.assign(Object.assign({},r),i)),"ImportCustomerBulk","mutation")},ImportCustomer(n,r){return e(i=>t.request(C.ImportCustomerDocument,n,Object.assign(Object.assign({},r),i)),"ImportCustomer","mutation")},UpdateCustomer(n,r){return e(i=>t.request(C.UpdateCustomerDocument,n,Object.assign(Object.assign({},r),i)),"UpdateCustomer","mutation")},DetachCustomerPaymentMethod(n,r){return e(i=>t.request(C.DetachCustomerPaymentMethodDocument,n,Object.assign(Object.assign({},r),i)),"DetachCustomerPaymentMethod","mutation")},GrantPromotionalEntitlements(n,r){return e(i=>t.request(C.GrantPromotionalEntitlementsDocument,n,Object.assign(Object.assign({},r),i)),"GrantPromotionalEntitlements","mutation")},RevokePromotionalEntitlement(n,r){return e(i=>t.request(C.RevokePromotionalEntitlementDocument,n,Object.assign(Object.assign({},r),i)),"RevokePromotionalEntitlement","mutation")},ProvisionSubscription(n,r){return e(i=>t.request(C.ProvisionSubscriptionDocument,n,Object.assign(Object.assign({},r),i)),"ProvisionSubscription","mutation")},ApplySubscription(n,r){return e(i=>t.request(C.ApplySubscriptionDocument,n,Object.assign(Object.assign({},r),i)),"ApplySubscription","mutation")},ImportSubscriptionsBulk(n,r){return e(i=>t.request(C.ImportSubscriptionsBulkDocument,n,Object.assign(Object.assign({},r),i)),"ImportSubscriptionsBulk","mutation")},UpdateSubscription(n,r){return e(i=>t.request(C.UpdateSubscriptionDocument,n,Object.assign(Object.assign({},r),i)),"UpdateSubscription","mutation")},CancelSubscription(n,r){return e(i=>t.request(C.CancelSubscriptionDocument,n,Object.assign(Object.assign({},r),i)),"CancelSubscription","mutation")},EstimateSubscription(n,r){return e(i=>t.request(C.EstimateSubscriptionDocument,n,Object.assign(Object.assign({},r),i)),"EstimateSubscription","mutation")},EstimateSubscriptionUpdate(n,r){return e(i=>t.request(C.EstimateSubscriptionUpdateDocument,n,Object.assign(Object.assign({},r),i)),"EstimateSubscriptionUpdate","mutation")},PreviewSubscription(n,r){return e(i=>t.request(C.PreviewSubscriptionDocument,n,Object.assign(Object.assign({},r),i)),"PreviewSubscription","mutation")},PreviewNextInvoice(n,r){return e(i=>t.request(C.PreviewNextInvoiceDocument,n,Object.assign(Object.assign({},r),i)),"PreviewNextInvoice","mutation")},CancelSubscriptionUpdates(n,r){return e(i=>t.request(C.CancelSubscriptionUpdatesDocument,n,Object.assign(Object.assign({},r),i)),"CancelSubscriptionUpdates","mutation")},ReportUsage(n,r){return e(i=>t.request(C.ReportUsageDocument,n,Object.assign(Object.assign({},r),i)),"ReportUsage","mutation")},ReportUsageBulk(n,r){return e(i=>t.request(C.ReportUsageBulkDocument,n,Object.assign(Object.assign({},r),i)),"ReportUsageBulk","mutation")},ReportEvent(n,r){return e(i=>t.request(C.ReportEventDocument,n,Object.assign(Object.assign({},r),i)),"ReportEvent","mutation")},ReportEntitlementCheckRequested(n,r){return e(i=>t.request(C.ReportEntitlementCheckRequestedDocument,n,Object.assign(Object.assign({},r),i)),"ReportEntitlementCheckRequested","mutation")},CreateSubscription(n,r){return e(i=>t.request(C.CreateSubscriptionDocument,n,Object.assign(Object.assign({},r),i)),"CreateSubscription","mutation")},MigrateSubscriptionToLatest(n,r){return e(i=>t.request(C.MigrateSubscriptionToLatestDocument,n,Object.assign(Object.assign({},r),i)),"MigrateSubscriptionToLatest","mutation")},ArchiveCustomer(n,r){return e(i=>t.request(C.ArchiveCustomerDocument,n,Object.assign(Object.assign({},r),i)),"ArchiveCustomer","mutation")},UnarchiveCustomer(n,r){return e(i=>t.request(C.UnarchiveCustomerDocument,n,Object.assign(Object.assign({},r),i)),"UnarchiveCustomer","mutation")},TransferSubscription(n,r){return e(i=>t.request(C.TransferSubscriptionDocument,n,Object.assign(Object.assign({},r),i)),"TransferSubscription","mutation")},DelegateSubscriptionToCustomer(n,r){return e(i=>t.request(C.DelegateSubscriptionToCustomerDocument,n,Object.assign(Object.assign({},r),i)),"DelegateSubscriptionToCustomer","mutation")},TransferSubscriptionToResource(n,r){return e(i=>t.request(C.TransferSubscriptionToResourceDocument,n,Object.assign(Object.assign({},r),i)),"TransferSubscriptionToResource","mutation")},GrantCredits(n,r){return e(i=>t.request(C.GrantCreditsDocument,n,Object.assign(Object.assign({},r),i)),"GrantCredits","mutation")},GrantPromotionalEntitlementsGroup(n,r){return e(i=>t.request(C.GrantPromotionalEntitlementsGroupDocument,n,Object.assign(Object.assign({},r),i)),"GrantPromotionalEntitlementsGroup","mutation")},RevokePromotionalEntitlementsGroup(n,r){return e(i=>t.request(C.RevokePromotionalEntitlementsGroupDocument,n,Object.assign(Object.assign({},r),i)),"RevokePromotionalEntitlementsGroup","mutation")},UnlinkPromotionalEntitlementsGroup(n,r){return e(i=>t.request(C.UnlinkPromotionalEntitlementsGroupDocument,n,Object.assign(Object.assign({},r),i)),"UnlinkPromotionalEntitlementsGroup","mutation")},CreatePaymentSession(n,r){return e(i=>t.request(C.CreatePaymentSessionDocument,n,Object.assign(Object.assign({},r),i)),"CreatePaymentSession","mutation")},VoidCreditGrant(n,r){return e(i=>t.request(C.VoidCreditGrantDocument,n,Object.assign(Object.assign({},r),i)),"VoidCreditGrant","mutation")},GetCustomerById(n,r){return e(i=>t.request(C.GetCustomerByIdDocument,n,Object.assign(Object.assign({},r),i)),"GetCustomerById","query")},GetCustomerStatistics(n,r){return e(i=>t.request(C.GetCustomerStatisticsDocument,n,Object.assign(Object.assign({},r),i)),"GetCustomerStatistics","query")},GetActiveSubscriptions(n,r){return e(i=>t.request(C.GetActiveSubscriptionsDocument,n,Object.assign(Object.assign({},r),i)),"GetActiveSubscriptions","query")},GetActiveSubscriptionsList(n,r){return e(i=>t.request(C.GetActiveSubscriptionsListDocument,n,Object.assign(Object.assign({},r),i)),"GetActiveSubscriptionsList","query")},GetSubscriptions(n,r){return e(i=>t.request(C.GetSubscriptionsDocument,n,Object.assign(Object.assign({},r),i)),"GetSubscriptions","query")},GetSubscription(n,r){return e(i=>t.request(C.GetSubscriptionDocument,n,Object.assign(Object.assign({},r),i)),"GetSubscription","query")},GetCoupons(n,r){return e(i=>t.request(C.GetCouponsDocument,n,Object.assign(Object.assign({},r),i)),"GetCoupons","query")},GetPaywall(n,r){return e(i=>t.request(C.GetPaywallDocument,n,Object.assign(Object.assign({},r),i)),"GetPaywall","query")},GetEntitlements(n,r){return e(i=>t.request(C.GetEntitlementsDocument,n,Object.assign(Object.assign({},r),i)),"GetEntitlements","query")},GetEntitlementsState(n,r){return e(i=>t.request(C.GetEntitlementsStateDocument,n,Object.assign(Object.assign({},r),i)),"GetEntitlementsState","query")},GetEntitlement(n,r){return e(i=>t.request(C.GetEntitlementDocument,n,Object.assign(Object.assign({},r),i)),"GetEntitlement","query")},GetProducts(n,r){return e(i=>t.request(C.GetProductsDocument,n,Object.assign(Object.assign({},r),i)),"GetProducts","query")},GetSdkConfiguration(n,r){return e(i=>t.request(C.GetSdkConfigurationDocument,n,Object.assign(Object.assign({},r),i)),"GetSdkConfiguration","query")},GetCustomerPortalByRefId(n,r){return e(i=>t.request(C.GetCustomerPortalByRefIdDocument,n,Object.assign(Object.assign({},r),i)),"GetCustomerPortalByRefId","query")},GetCheckoutState(n,r){return e(i=>t.request(C.GetCheckoutStateDocument,n,Object.assign(Object.assign({},r),i)),"GetCheckoutState","query")},GetMockPaywall(n,r){return e(i=>t.request(C.GetMockPaywallDocument,n,Object.assign(Object.assign({},r),i)),"GetMockPaywall","query")},GetUsageHistory(n,r){return e(i=>t.request(C.GetUsageHistoryDocument,n,Object.assign(Object.assign({},r),i)),"GetUsageHistory","query")},GetUsageHistoryV2(n,r){return e(i=>t.request(C.GetUsageHistoryV2Document,n,Object.assign(Object.assign({},r),i)),"GetUsageHistoryV2","query")},GetCreditBalance(n,r){return e(i=>t.request(C.GetCreditBalanceDocument,n,Object.assign(Object.assign({},r),i)),"GetCreditBalance","query")},GetCreditGrants(n,r){return e(i=>t.request(C.GetCreditGrantsDocument,n,Object.assign(Object.assign({},r),i)),"GetCreditGrants","query")},GetCreditLedger(n,r){return e(i=>t.request(C.GetCreditLedgerDocument,n,Object.assign(Object.assign({},r),i)),"GetCreditLedger","query")},GetCreditUsage(n,r){return e(i=>t.request(C.GetCreditUsageDocument,n,Object.assign(Object.assign({},r),i)),"GetCreditUsage","query")},OnEntitlementsUpdated(n,r){return e(i=>t.request(C.OnEntitlementsUpdatedDocument,n,Object.assign(Object.assign({},r),i)),"OnEntitlementsUpdated","subscription")},OnUsageUpdated(n,r){return e(i=>t.request(C.OnUsageUpdatedDocument,n,Object.assign(Object.assign({},r),i)),"OnUsageUpdated","subscription")},OnPackagePublished(n,r){return e(i=>t.request(C.OnPackagePublishedDocument,n,Object.assign(Object.assign({},r),i)),"OnPackagePublished","subscription")},OnCreditBalanceUpdated(n,r){return e(i=>t.request(C.OnCreditBalanceUpdatedDocument,n,Object.assign(Object.assign({},r),i)),"OnCreditBalanceUpdated","subscription")}}}C.getSdk=IN;});var Qk={2991:(t,e,n)=>{n.d(e,{R:()=>o,Y:()=>s});var r=n(2176),i={};function o(){return (0, r.KV)()?n.g:typeof window!="undefined"?window:typeof self!="undefined"?self:i}function s(c,p,h){var v=h||o(),P=v.__SENTRY__=v.__SENTRY__||{};return P[c]||(P[c]=p())}},2176:(t,e,n)=>{function r(){return !(typeof __SENTRY_BROWSER_BUNDLE__!="undefined"&&__SENTRY_BROWSER_BUNDLE__)&&Object.prototype.toString.call(typeof process!="undefined"?process:0)==="[object process]"}function i(o,s){return o.require(s)}n.d(e,{l$:()=>i,KV:()=>r}),t=n.hmd(t);},1170:(t,e,n)=>{n.d(e,{yW:()=>p,ph:()=>h});var r=n(2991),i=n(2176);t=n.hmd(t);var o={nowSeconds:()=>Date.now()/1e3},s=(0, i.KV)()?(function(){try{return (0,i.l$)(t,"perf_hooks").performance}catch(P){return}})():(function(){let{performance:P}=(0, r.R)();if(P&&P.now)return {now:()=>P.now(),timeOrigin:Date.now()-P.now()}})(),c=s===void 0?o:{nowSeconds:()=>(s.timeOrigin+s.now())/1e3},p=o.nowSeconds.bind(o),h=c.nowSeconds.bind(c);(()=>{let{performance:P}=(0, r.R)();if(P&&P.now){var x=36e5,T=P.now(),I=Date.now(),R=P.timeOrigin?Math.abs(P.timeOrigin+T-I):x,A=R<x,O=P.timing&&P.timing.navigationStart,N=typeof O=="number"?Math.abs(O+T-I):x;return A||N<x?R<=N?(P.timeOrigin):(O):(I)}})();},1905:function(){(function(t){(function(e){var n="URLSearchParams"in t,r="Symbol"in t&&"iterator"in Symbol,i="FileReader"in t&&"Blob"in t&&(function(){try{return new Blob,!0}catch(U){return false}})(),o="FormData"in t,s="ArrayBuffer"in t;if(s)var c=["[object Int8Array]","[object Uint8Array]","[object Uint8ClampedArray]","[object Int16Array]","[object Uint16Array]","[object Int32Array]","[object Uint32Array]","[object Float32Array]","[object Float64Array]"],p=ArrayBuffer.isView||function(U){return U&&c.indexOf(Object.prototype.toString.call(U))>-1};function h(U){if(typeof U!="string"&&(U=String(U)),/[^a-z0-9\-#$%&'*+.^_`|~]/i.test(U))throw new TypeError("Invalid character in header field name");return U.toLowerCase()}function v(U){return typeof U!="string"&&(U=String(U)),U}function P(U){var j={next:function(){var ut=U.shift();return {done:ut===void 0,value:ut}}};return r&&(j[Symbol.iterator]=function(){return j}),j}function x(U){this.map={},U instanceof x?U.forEach((function(j,ut){this.append(ut,j);}),this):Array.isArray(U)?U.forEach((function(j){this.append(j[0],j[1]);}),this):U&&Object.getOwnPropertyNames(U).forEach((function(j){this.append(j,U[j]);}),this);}function T(U){if(U.bodyUsed)return Promise.reject(new TypeError("Already read"));U.bodyUsed=true;}function I(U){return new Promise((function(j,ut){U.onload=function(){j(U.result);},U.onerror=function(){ut(U.error);};}))}function R(U){var j=new FileReader,ut=I(j);return j.readAsArrayBuffer(U),ut}function A(U){if(U.slice)return U.slice(0);var j=new Uint8Array(U.byteLength);return j.set(new Uint8Array(U)),j.buffer}function O(){return this.bodyUsed=false,this._initBody=function(U){var j;this._bodyInit=U,U?typeof U=="string"?this._bodyText=U:i&&Blob.prototype.isPrototypeOf(U)?this._bodyBlob=U:o&&FormData.prototype.isPrototypeOf(U)?this._bodyFormData=U:n&&URLSearchParams.prototype.isPrototypeOf(U)?this._bodyText=U.toString():s&&i&&(j=U)&&DataView.prototype.isPrototypeOf(j)?(this._bodyArrayBuffer=A(U.buffer),this._bodyInit=new Blob([this._bodyArrayBuffer])):s&&(ArrayBuffer.prototype.isPrototypeOf(U)||p(U))?this._bodyArrayBuffer=A(U):this._bodyText=U=Object.prototype.toString.call(U):this._bodyText="",this.headers.get("content-type")||(typeof U=="string"?this.headers.set("content-type","text/plain;charset=UTF-8"):this._bodyBlob&&this._bodyBlob.type?this.headers.set("content-type",this._bodyBlob.type):n&&URLSearchParams.prototype.isPrototypeOf(U)&&this.headers.set("content-type","application/x-www-form-urlencoded;charset=UTF-8"));},i&&(this.blob=function(){var U=T(this);if(U)return U;if(this._bodyBlob)return Promise.resolve(this._bodyBlob);if(this._bodyArrayBuffer)return Promise.resolve(new Blob([this._bodyArrayBuffer]));if(this._bodyFormData)throw new Error("could not read FormData body as blob");return Promise.resolve(new Blob([this._bodyText]))},this.arrayBuffer=function(){return this._bodyArrayBuffer?T(this)||Promise.resolve(this._bodyArrayBuffer):this.blob().then(R)}),this.text=function(){var U,j,ut,Y=T(this);if(Y)return Y;if(this._bodyBlob)return U=this._bodyBlob,ut=I(j=new FileReader),j.readAsText(U),ut;if(this._bodyArrayBuffer)return Promise.resolve((function(at){for(var pt=new Uint8Array(at),dt=new Array(pt.length),mt=0;mt<pt.length;mt++)dt[mt]=String.fromCharCode(pt[mt]);return dt.join("")})(this._bodyArrayBuffer));if(this._bodyFormData)throw new Error("could not read FormData body as text");return Promise.resolve(this._bodyText)},o&&(this.formData=function(){return this.text().then(G)}),this.json=function(){return this.text().then(JSON.parse)},this}x.prototype.append=function(U,j){U=h(U),j=v(j);var ut=this.map[U];this.map[U]=ut?ut+", "+j:j;},x.prototype.delete=function(U){delete this.map[h(U)];},x.prototype.get=function(U){return U=h(U),this.has(U)?this.map[U]:null},x.prototype.has=function(U){return this.map.hasOwnProperty(h(U))},x.prototype.set=function(U,j){this.map[h(U)]=v(j);},x.prototype.forEach=function(U,j){for(var ut in this.map)this.map.hasOwnProperty(ut)&&U.call(j,this.map[ut],ut,this);},x.prototype.keys=function(){var U=[];return this.forEach((function(j,ut){U.push(ut);})),P(U)},x.prototype.values=function(){var U=[];return this.forEach((function(j){U.push(j);})),P(U)},x.prototype.entries=function(){var U=[];return this.forEach((function(j,ut){U.push([ut,j]);})),P(U)},r&&(x.prototype[Symbol.iterator]=x.prototype.entries);var N=["DELETE","GET","HEAD","OPTIONS","POST","PUT"];function V(U,j){var ut,Y,at=(j=j||{}).body;if(U instanceof V){if(U.bodyUsed)throw new TypeError("Already read");this.url=U.url,this.credentials=U.credentials,j.headers||(this.headers=new x(U.headers)),this.method=U.method,this.mode=U.mode,this.signal=U.signal,at||U._bodyInit==null||(at=U._bodyInit,U.bodyUsed=true);}else this.url=String(U);if(this.credentials=j.credentials||this.credentials||"same-origin",!j.headers&&this.headers||(this.headers=new x(j.headers)),this.method=(Y=(ut=j.method||this.method||"GET").toUpperCase(),N.indexOf(Y)>-1?Y:ut),this.mode=j.mode||this.mode||null,this.signal=j.signal||this.signal,this.referrer=null,(this.method==="GET"||this.method==="HEAD")&&at)throw new TypeError("Body not allowed for GET or HEAD requests");this._initBody(at);}function G(U){var j=new FormData;return U.trim().split("&").forEach((function(ut){if(ut){var Y=ut.split("="),at=Y.shift().replace(/\+/g," "),pt=Y.join("=").replace(/\+/g," ");j.append(decodeURIComponent(at),decodeURIComponent(pt));}})),j}function X(U,j){j||(j={}),this.type="default",this.status=j.status===void 0?200:j.status,this.ok=this.status>=200&&this.status<300,this.statusText="statusText"in j?j.statusText:"OK",this.headers=new x(j.headers),this.url=j.url||"",this._initBody(U);}V.prototype.clone=function(){return new V(this,{body:this._bodyInit})},O.call(V.prototype),O.call(X.prototype),X.prototype.clone=function(){return new X(this._bodyInit,{status:this.status,statusText:this.statusText,headers:new x(this.headers),url:this.url})},X.error=function(){var U=new X(null,{status:0,statusText:""});return U.type="error",U};var nt=[301,302,303,307,308];X.redirect=function(U,j){if(nt.indexOf(j)===-1)throw new RangeError("Invalid status code");return new X(null,{status:j,headers:{location:U}})},e.DOMException=t.DOMException;try{new e.DOMException;}catch(U){e.DOMException=function(j,ut){this.message=j,this.name=ut;var Y=Error(j);this.stack=Y.stack;},e.DOMException.prototype=Object.create(Error.prototype),e.DOMException.prototype.constructor=e.DOMException;}function st(U,j){return new Promise((function(ut,Y){var at=new V(U,j);if(at.signal&&at.signal.aborted)return Y(new e.DOMException("Aborted","AbortError"));var pt=new XMLHttpRequest;function dt(){pt.abort();}pt.onload=function(){var mt,Ct,jt={status:pt.status,statusText:pt.statusText,headers:(mt=pt.getAllResponseHeaders()||"",Ct=new x,mt.replace(/\r?\n[\t ]+/g," ").split(/\r?\n/).forEach((function(Jt){var ee=Jt.split(":"),re=ee.shift().trim();if(re){var Ee=ee.join(":").trim();Ct.append(re,Ee);}})),Ct)};jt.url="responseURL"in pt?pt.responseURL:jt.headers.get("X-Request-URL");var Gt="response"in pt?pt.response:pt.responseText;ut(new X(Gt,jt));},pt.onerror=function(){Y(new TypeError("Network request failed"));},pt.ontimeout=function(){Y(new TypeError("Network request failed"));},pt.onabort=function(){Y(new e.DOMException("Aborted","AbortError"));},pt.open(at.method,at.url,true),at.credentials==="include"?pt.withCredentials=true:at.credentials==="omit"&&(pt.withCredentials=false),"responseType"in pt&&i&&(pt.responseType="blob"),at.headers.forEach((function(mt,Ct){pt.setRequestHeader(Ct,mt);})),at.signal&&(at.signal.addEventListener("abort",dt),pt.onreadystatechange=function(){pt.readyState===4&&at.signal.removeEventListener("abort",dt);}),pt.send(at._bodyInit===void 0?null:at._bodyInit);}))}st.polyfill=true,t.fetch||(t.fetch=st,t.Headers=x,t.Request=V,t.Response=X),e.Headers=x,e.Request=V,e.Response=X,e.fetch=st,Object.defineProperty(e,"__esModule",{value:true});})({});})(typeof self!="undefined"?self:this);},7484:function(t){t.exports=(function(){var e=6e4,n=36e5,r="millisecond",i="second",o="minute",s="hour",c="day",p="week",h="month",v="quarter",P="year",x="date",T="Invalid Date",I=/^(\d{4})[-/]?(\d{1,2})?[-/]?(\d{0,2})[Tt\s]*(\d{1,2})?:?(\d{1,2})?:?(\d{1,2})?[.:]?(\d+)?$/,R=/\[([^\]]+)]|Y{1,4}|M{1,4}|D{1,2}|d{1,4}|H{1,2}|h{1,2}|a|A|m{1,2}|s{1,2}|Z{1,2}|SSS/g,A={name:"en",weekdays:"Sunday_Monday_Tuesday_Wednesday_Thursday_Friday_Saturday".split("_"),months:"January_February_March_April_May_June_July_August_September_October_November_December".split("_"),ordinal:function(at){var pt=["th","st","nd","rd"],dt=at%100;return "["+at+(pt[(dt-20)%10]||pt[dt]||pt[0])+"]"}},O=function(at,pt,dt){var mt=String(at);return !mt||mt.length>=pt?at:""+Array(pt+1-mt.length).join(dt)+at},N={s:O,z:function(at){var pt=-at.utcOffset(),dt=Math.abs(pt),mt=Math.floor(dt/60),Ct=dt%60;return (pt<=0?"+":"-")+O(mt,2,"0")+":"+O(Ct,2,"0")},m:function at(pt,dt){if(pt.date()<dt.date())return -at(dt,pt);var mt=12*(dt.year()-pt.year())+(dt.month()-pt.month()),Ct=pt.clone().add(mt,h),jt=dt-Ct<0,Gt=pt.clone().add(mt+(jt?-1:1),h);return +(-(mt+(dt-Ct)/(jt?Ct-Gt:Gt-Ct))||0)},a:function(at){return at<0?Math.ceil(at)||0:Math.floor(at)},p:function(at){return {M:h,y:P,w:p,d:c,D:x,h:s,m:o,s:i,ms:r,Q:v}[at]||String(at||"").toLowerCase().replace(/s$/,"")},u:function(at){return at===void 0}},V="en",G={};G[V]=A;var X="$isDayjsObject",nt=function(at){return at instanceof ut||!(!at||!at[X])},st=function at(pt,dt,mt){var Ct;if(!pt)return V;if(typeof pt=="string"){var jt=pt.toLowerCase();G[jt]&&(Ct=jt),dt&&(G[jt]=dt,Ct=jt);var Gt=pt.split("-");if(!Ct&&Gt.length>1)return at(Gt[0])}else {var Jt=pt.name;G[Jt]=pt,Ct=Jt;}return !mt&&Ct&&(V=Ct),Ct||!mt&&V},U=function(at,pt){if(nt(at))return at.clone();var dt=typeof pt=="object"?pt:{};return dt.date=at,dt.args=arguments,new ut(dt)},j=N;j.l=st,j.i=nt,j.w=function(at,pt){return U(at,{locale:pt.$L,utc:pt.$u,x:pt.$x,$offset:pt.$offset})};var ut=(function(){function at(dt){this.$L=st(dt.locale,null,true),this.parse(dt),this.$x=this.$x||dt.x||{},this[X]=true;}var pt=at.prototype;return pt.parse=function(dt){this.$d=(function(mt){var Ct=mt.date,jt=mt.utc;if(Ct===null)return new Date(NaN);if(j.u(Ct))return new Date;if(Ct instanceof Date)return new Date(Ct);if(typeof Ct=="string"&&!/Z$/i.test(Ct)){var Gt=Ct.match(I);if(Gt){var Jt=Gt[2]-1||0,ee=(Gt[7]||"0").substring(0,3);return jt?new Date(Date.UTC(Gt[1],Jt,Gt[3]||1,Gt[4]||0,Gt[5]||0,Gt[6]||0,ee)):new Date(Gt[1],Jt,Gt[3]||1,Gt[4]||0,Gt[5]||0,Gt[6]||0,ee)}}return new Date(Ct)})(dt),this.init();},pt.init=function(){var dt=this.$d;this.$y=dt.getFullYear(),this.$M=dt.getMonth(),this.$D=dt.getDate(),this.$W=dt.getDay(),this.$H=dt.getHours(),this.$m=dt.getMinutes(),this.$s=dt.getSeconds(),this.$ms=dt.getMilliseconds();},pt.$utils=function(){return j},pt.isValid=function(){return this.$d.toString()!==T},pt.isSame=function(dt,mt){var Ct=U(dt);return this.startOf(mt)<=Ct&&Ct<=this.endOf(mt)},pt.isAfter=function(dt,mt){return U(dt)<this.startOf(mt)},pt.isBefore=function(dt,mt){return this.endOf(mt)<U(dt)},pt.$g=function(dt,mt,Ct){return j.u(dt)?this[mt]:this.set(Ct,dt)},pt.unix=function(){return Math.floor(this.valueOf()/1e3)},pt.valueOf=function(){return this.$d.getTime()},pt.startOf=function(dt,mt){var Ct=this,jt=!!j.u(mt)||mt,Gt=j.p(dt),Jt=function(Gn,ln){var Ke=j.w(Ct.$u?Date.UTC(Ct.$y,ln,Gn):new Date(Ct.$y,ln,Gn),Ct);return jt?Ke:Ke.endOf(c)},ee=function(Gn,ln){return j.w(Ct.toDate()[Gn].apply(Ct.toDate("s"),(jt?[0,0,0,0]:[23,59,59,999]).slice(ln)),Ct)},re=this.$W,Ee=this.$M,je=this.$D,sn="set"+(this.$u?"UTC":"");switch(Gt){case P:return jt?Jt(1,0):Jt(31,11);case h:return jt?Jt(1,Ee):Jt(0,Ee+1);case p:var Ze=this.$locale().weekStart||0,Pn=(re<Ze?re+7:re)-Ze;return Jt(jt?je-Pn:je+(6-Pn),Ee);case c:case x:return ee(sn+"Hours",0);case s:return ee(sn+"Minutes",1);case o:return ee(sn+"Seconds",2);case i:return ee(sn+"Milliseconds",3);default:return this.clone()}},pt.endOf=function(dt){return this.startOf(dt,false)},pt.$set=function(dt,mt){var Ct,jt=j.p(dt),Gt="set"+(this.$u?"UTC":""),Jt=(Ct={},Ct[c]=Gt+"Date",Ct[x]=Gt+"Date",Ct[h]=Gt+"Month",Ct[P]=Gt+"FullYear",Ct[s]=Gt+"Hours",Ct[o]=Gt+"Minutes",Ct[i]=Gt+"Seconds",Ct[r]=Gt+"Milliseconds",Ct)[jt],ee=jt===c?this.$D+(mt-this.$W):mt;if(jt===h||jt===P){var re=this.clone().set(x,1);re.$d[Jt](ee),re.init(),this.$d=re.set(x,Math.min(this.$D,re.daysInMonth())).$d;}else Jt&&this.$d[Jt](ee);return this.init(),this},pt.set=function(dt,mt){return this.clone().$set(dt,mt)},pt.get=function(dt){return this[j.p(dt)]()},pt.add=function(dt,mt){var Ct,jt=this;dt=Number(dt);var Gt=j.p(mt),Jt=function(Ee){var je=U(jt);return j.w(je.date(je.date()+Math.round(Ee*dt)),jt)};if(Gt===h)return this.set(h,this.$M+dt);if(Gt===P)return this.set(P,this.$y+dt);if(Gt===c)return Jt(1);if(Gt===p)return Jt(7);var ee=(Ct={},Ct[o]=e,Ct[s]=n,Ct[i]=1e3,Ct)[Gt]||1,re=this.$d.getTime()+dt*ee;return j.w(re,this)},pt.subtract=function(dt,mt){return this.add(-1*dt,mt)},pt.format=function(dt){var mt=this,Ct=this.$locale();if(!this.isValid())return Ct.invalidDate||T;var jt=dt||"YYYY-MM-DDTHH:mm:ssZ",Gt=j.z(this),Jt=this.$H,ee=this.$m,re=this.$M,Ee=Ct.weekdays,je=Ct.months,sn=Ct.meridiem,Ze=function(ln,Ke,dn,or){return ln&&(ln[Ke]||ln(mt,jt))||dn[Ke].slice(0,or)},Pn=function(ln){return j.s(Jt%12||12,ln,"0")},Gn=sn||function(ln,Ke,dn){var or=ln<12?"AM":"PM";return dn?or.toLowerCase():or};return jt.replace(R,(function(ln,Ke){return Ke||(function(dn){switch(dn){case "YY":return String(mt.$y).slice(-2);case "YYYY":return j.s(mt.$y,4,"0");case "M":return re+1;case "MM":return j.s(re+1,2,"0");case "MMM":return Ze(Ct.monthsShort,re,je,3);case "MMMM":return Ze(je,re);case "D":return mt.$D;case "DD":return j.s(mt.$D,2,"0");case "d":return String(mt.$W);case "dd":return Ze(Ct.weekdaysMin,mt.$W,Ee,2);case "ddd":return Ze(Ct.weekdaysShort,mt.$W,Ee,3);case "dddd":return Ee[mt.$W];case "H":return String(Jt);case "HH":return j.s(Jt,2,"0");case "h":return Pn(1);case "hh":return Pn(2);case "a":return Gn(Jt,ee,true);case "A":return Gn(Jt,ee,false);case "m":return String(ee);case "mm":return j.s(ee,2,"0");case "s":return String(mt.$s);case "ss":return j.s(mt.$s,2,"0");case "SSS":return j.s(mt.$ms,3,"0");case "Z":return Gt}return null})(ln)||Gt.replace(":","")}))},pt.utcOffset=function(){return 15*-Math.round(this.$d.getTimezoneOffset()/15)},pt.diff=function(dt,mt,Ct){var jt,Gt=this,Jt=j.p(mt),ee=U(dt),re=(ee.utcOffset()-this.utcOffset())*e,Ee=this-ee,je=function(){return j.m(Gt,ee)};switch(Jt){case P:jt=je()/12;break;case h:jt=je();break;case v:jt=je()/3;break;case p:jt=(Ee-re)/6048e5;break;case c:jt=(Ee-re)/864e5;break;case s:jt=Ee/n;break;case o:jt=Ee/e;break;case i:jt=Ee/1e3;break;default:jt=Ee;}return Ct?jt:j.a(jt)},pt.daysInMonth=function(){return this.endOf(h).$D},pt.$locale=function(){return G[this.$L]},pt.locale=function(dt,mt){if(!dt)return this.$L;var Ct=this.clone(),jt=st(dt,mt,true);return jt&&(Ct.$L=jt),Ct},pt.clone=function(){return j.w(this.$d,this)},pt.toDate=function(){return new Date(this.valueOf())},pt.toJSON=function(){return this.isValid()?this.toISOString():null},pt.toISOString=function(){return this.$d.toISOString()},pt.toString=function(){return this.$d.toUTCString()},at})(),Y=ut.prototype;return U.prototype=Y,[["$ms",r],["$s",i],["$m",o],["$H",s],["$W",c],["$M",h],["$y",P],["$D",x]].forEach((function(at){Y[at[1]]=function(pt){return this.$g(pt,at[0],at[1])};})),U.extend=function(at,pt){return at.$i||(at(pt,ut,U),at.$i=true),U},U.locale=st,U.isDayjs=nt,U.unix=function(at){return U(1e3*at)},U.en=G[V],U.Ls=G,U.p={},U})();},7187:t=>{var e,n=typeof Reflect=="object"?Reflect:null,r=n&&typeof n.apply=="function"?n.apply:function(A,O,N){return Function.prototype.apply.call(A,O,N)};e=n&&typeof n.ownKeys=="function"?n.ownKeys:Object.getOwnPropertySymbols?function(A){return Object.getOwnPropertyNames(A).concat(Object.getOwnPropertySymbols(A))}:function(A){return Object.getOwnPropertyNames(A)};var i=Number.isNaN||function(A){return A!=A};function o(){o.init.call(this);}t.exports=o,t.exports.once=function(A,O){return new Promise((function(N,V){function G(nt){A.removeListener(O,X),V(nt);}function X(){typeof A.removeListener=="function"&&A.removeListener("error",G),N([].slice.call(arguments));}R(A,O,X,{once:true}),O!=="error"&&(function(nt,st,U){typeof nt.on=="function"&&R(nt,"error",st,{once:true});})(A,G);}))},o.EventEmitter=o,o.prototype._events=void 0,o.prototype._eventsCount=0,o.prototype._maxListeners=void 0;var s=10;function c(A){if(typeof A!="function")throw new TypeError('The "listener" argument must be of type Function. Received type '+typeof A)}function p(A){return A._maxListeners===void 0?o.defaultMaxListeners:A._maxListeners}function h(A,O,N,V){var G,X,nt,st;if(c(N),(X=A._events)===void 0?(X=A._events=Object.create(null),A._eventsCount=0):(X.newListener!==void 0&&(A.emit("newListener",O,N.listener?N.listener:N),X=A._events),nt=X[O]),nt===void 0)nt=X[O]=N,++A._eventsCount;else if(typeof nt=="function"?nt=X[O]=V?[N,nt]:[nt,N]:V?nt.unshift(N):nt.push(N),(G=p(A))>0&&nt.length>G&&!nt.warned){nt.warned=true;var U=new Error("Possible EventEmitter memory leak detected. "+nt.length+" "+String(O)+" listeners added. Use emitter.setMaxListeners() to increase limit");U.name="MaxListenersExceededWarning",U.emitter=A,U.type=O,U.count=nt.length,st=U,console&&console.warn&&console.warn(st);}return A}function v(){if(!this.fired)return this.target.removeListener(this.type,this.wrapFn),this.fired=true,arguments.length===0?this.listener.call(this.target):this.listener.apply(this.target,arguments)}function P(A,O,N){var V={fired:false,wrapFn:void 0,target:A,type:O,listener:N},G=v.bind(V);return G.listener=N,V.wrapFn=G,G}function x(A,O,N){var V=A._events;if(V===void 0)return [];var G=V[O];return G===void 0?[]:typeof G=="function"?N?[G.listener||G]:[G]:N?(function(X){for(var nt=new Array(X.length),st=0;st<nt.length;++st)nt[st]=X[st].listener||X[st];return nt})(G):I(G,G.length)}function T(A){var O=this._events;if(O!==void 0){var N=O[A];if(typeof N=="function")return 1;if(N!==void 0)return N.length}return 0}function I(A,O){for(var N=new Array(O),V=0;V<O;++V)N[V]=A[V];return N}function R(A,O,N,V){if(typeof A.on=="function")V.once?A.once(O,N):A.on(O,N);else {if(typeof A.addEventListener!="function")throw new TypeError('The "emitter" argument must be of type EventEmitter. Received type '+typeof A);A.addEventListener(O,(function G(X){V.once&&A.removeEventListener(O,G),N(X);}));}}Object.defineProperty(o,"defaultMaxListeners",{enumerable:true,get:function(){return s},set:function(A){if(typeof A!="number"||A<0||i(A))throw new RangeError('The value of "defaultMaxListeners" is out of range. It must be a non-negative number. Received '+A+".");s=A;}}),o.init=function(){this._events!==void 0&&this._events!==Object.getPrototypeOf(this)._events||(this._events=Object.create(null),this._eventsCount=0),this._maxListeners=this._maxListeners||void 0;},o.prototype.setMaxListeners=function(A){if(typeof A!="number"||A<0||i(A))throw new RangeError('The value of "n" is out of range. It must be a non-negative number. Received '+A+".");return this._maxListeners=A,this},o.prototype.getMaxListeners=function(){return p(this)},o.prototype.emit=function(A){for(var O=[],N=1;N<arguments.length;N++)O.push(arguments[N]);var V=A==="error",G=this._events;if(G!==void 0)V=V&&G.error===void 0;else if(!V)return false;if(V){var X;if(O.length>0&&(X=O[0]),X instanceof Error)throw X;var nt=new Error("Unhandled error."+(X?" ("+X.message+")":""));throw nt.context=X,nt}var st=G[A];if(st===void 0)return false;if(typeof st=="function")r(st,this,O);else {var U=st.length,j=I(st,U);for(N=0;N<U;++N)r(j[N],this,O);}return true},o.prototype.addListener=function(A,O){return h(this,A,O,false)},o.prototype.on=o.prototype.addListener,o.prototype.prependListener=function(A,O){return h(this,A,O,true)},o.prototype.once=function(A,O){return c(O),this.on(A,P(this,A,O)),this},o.prototype.prependOnceListener=function(A,O){return c(O),this.prependListener(A,P(this,A,O)),this},o.prototype.removeListener=function(A,O){var N,V,G,X,nt;if(c(O),(V=this._events)===void 0)return this;if((N=V[A])===void 0)return this;if(N===O||N.listener===O)--this._eventsCount==0?this._events=Object.create(null):(delete V[A],V.removeListener&&this.emit("removeListener",A,N.listener||O));else if(typeof N!="function"){for(G=-1,X=N.length-1;X>=0;X--)if(N[X]===O||N[X].listener===O){nt=N[X].listener,G=X;break}if(G<0)return this;G===0?N.shift():(function(st,U){for(;U+1<st.length;U++)st[U]=st[U+1];st.pop();})(N,G),N.length===1&&(V[A]=N[0]),V.removeListener!==void 0&&this.emit("removeListener",A,nt||O);}return this},o.prototype.off=o.prototype.removeListener,o.prototype.removeAllListeners=function(A){var O,N,V;if((N=this._events)===void 0)return this;if(N.removeListener===void 0)return arguments.length===0?(this._events=Object.create(null),this._eventsCount=0):N[A]!==void 0&&(--this._eventsCount==0?this._events=Object.create(null):delete N[A]),this;if(arguments.length===0){var G,X=Object.keys(N);for(V=0;V<X.length;++V)(G=X[V])!=="removeListener"&&this.removeAllListeners(G);return this.removeAllListeners("removeListener"),this._events=Object.create(null),this._eventsCount=0,this}if(typeof(O=N[A])=="function")this.removeListener(A,O);else if(O!==void 0)for(V=O.length-1;V>=0;V--)this.removeListener(A,O[V]);return this},o.prototype.listeners=function(A){return x(this,A,true)},o.prototype.rawListeners=function(A){return x(this,A,false)},o.listenerCount=function(A,O){return typeof A.listenerCount=="function"?A.listenerCount(O):T.call(A,O)},o.prototype.listenerCount=T,o.prototype.eventNames=function(){return this._eventsCount>0?e(this._events):[]};},4139:function(t){t.exports=(function(){function e(r){return Number.isInteger(r)&&r>=0}function n(r){this.name="ArgumentError",this.message=r;}return function(r,i){if(i=i||{},typeof r!="function")throw new n("fetch must be a function");if(typeof i!="object")throw new n("defaults must be an object");if(i.retries!==void 0&&!e(i.retries))throw new n("retries must be a positive integer");if(i.retryDelay!==void 0&&!e(i.retryDelay)&&typeof i.retryDelay!="function")throw new n("retryDelay must be a positive integer or a function returning a positive integer");if(i.retryOn!==void 0&&!Array.isArray(i.retryOn)&&typeof i.retryOn!="function")throw new n("retryOn property expects an array or function");return i=Object.assign({retries:3,retryDelay:1e3,retryOn:[]},i),function(o,s){var c=i.retries,p=i.retryDelay,h=i.retryOn;if(s&&s.retries!==void 0){if(!e(s.retries))throw new n("retries must be a positive integer");c=s.retries;}if(s&&s.retryDelay!==void 0){if(!e(s.retryDelay)&&typeof s.retryDelay!="function")throw new n("retryDelay must be a positive integer or a function returning a positive integer");p=s.retryDelay;}if(s&&s.retryOn){if(!Array.isArray(s.retryOn)&&typeof s.retryOn!="function")throw new n("retryOn property expects an array or function");h=s.retryOn;}return new Promise((function(v,P){var x=function(I){var R=typeof Request!="undefined"&&o instanceof Request?o.clone():o;r(R,s).then((function(A){if(Array.isArray(h)&&h.indexOf(A.status)===-1)v(A);else if(typeof h=="function")try{return Promise.resolve(h(I,null,A)).then((function(O){O?T(I,null,A):v(A);})).catch(P)}catch(O){P(O);}else I<c?T(I,null,A):v(A);})).catch((function(A){if(typeof h=="function")try{Promise.resolve(h(I,A,null)).then((function(O){O?T(I,A,null):P(A);})).catch((function(O){P(O);}));}catch(O){P(O);}else I<c?T(I,A,null):P(A);}));};function T(I,R,A){var O=typeof p=="function"?p(I,R,A):p;setTimeout((function(){x(++I);}),O);}x(0);}))}}})();},5185:(t,e,n)=>{n.r(e),n.d(e,{default:()=>Vt,disableExperimentalFragmentVariables:()=>Jn,disableFragmentWarnings:()=>ar,enableExperimentalFragmentVariables:()=>sr,gql:()=>Ve,resetCaches:()=>bt});var r=function(){return r=Object.assign||function(gt){for(var ot,Z=1,it=arguments.length;Z<it;Z++)for(var _t in ot=arguments[Z])Object.prototype.hasOwnProperty.call(ot,_t)&&(gt[_t]=ot[_t]);return gt},r.apply(this,arguments)};function i(gt){return i=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(ot){return typeof ot}:function(ot){return ot&&typeof Symbol=="function"&&ot.constructor===Symbol&&ot!==Symbol.prototype?"symbol":typeof ot},i(gt)}var o=n(9763);function s(gt,ot){for(var Z,it=/\r\n|[\n\r]/g,_t=1,ft=ot+1;(Z=it.exec(gt.body))&&Z.index<ot;)_t+=1,ft=ot+1-(Z.index+Z[0].length);return {line:_t,column:ft}}function c(gt){return p(gt.source,s(gt.source,gt.start))}function p(gt,ot){var Z=gt.locationOffset.column-1,it=v(Z)+gt.body,_t=ot.line-1,ft=gt.locationOffset.line-1,Lt=ot.line+ft,It=ot.line===1?Z:0,Nt=ot.column+It,se="".concat(gt.name,":").concat(Lt,":").concat(Nt,`
2295
2295
  `),ne=it.split(/\r\n|[\n\r]/g),kn=ne[_t];if(kn.length>120){for(var Ae=Math.floor(Nt/80),cn=Nt%80,pn=[],Ir=0;Ir<kn.length;Ir+=80)pn.push(kn.slice(Ir,Ir+80));return se+h([["".concat(Lt),pn[0]]].concat(pn.slice(1,Ae+1).map((function(cr){return ["",cr]})),[[" ",v(cn-1)+"^"],["",pn[Ae+1]]]))}return se+h([["".concat(Lt-1),ne[_t-1]],["".concat(Lt),kn],["",v(Nt-1)+"^"],["".concat(Lt+1),ne[_t+1]]])}function h(gt){var ot=gt.filter((function(it){return it[0],it[1]!==void 0})),Z=Math.max.apply(Math,ot.map((function(it){return it[0].length})));return ot.map((function(it){var _t,ft=it[0],Lt=it[1];return v(Z-(_t=ft).length)+_t+(Lt?" | "+Lt:" |")})).join(`
2296
- `)}function v(gt){return Array(gt+1).join(" ")}function P(gt){return P=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(ot){return typeof ot}:function(ot){return ot&&typeof Symbol=="function"&&ot.constructor===Symbol&&ot!==Symbol.prototype?"symbol":typeof ot},P(gt)}function x(gt,ot){var Z=Object.keys(gt);if(Object.getOwnPropertySymbols){var it=Object.getOwnPropertySymbols(gt);ot&&(it=it.filter((function(_t){return Object.getOwnPropertyDescriptor(gt,_t).enumerable}))),Z.push.apply(Z,it);}return Z}function T(gt,ot,Z){return ot in gt?Object.defineProperty(gt,ot,{value:Z,enumerable:true,configurable:true,writable:true}):gt[ot]=Z,gt}function I(gt,ot){for(var Z=0;Z<ot.length;Z++){var it=ot[Z];it.enumerable=it.enumerable||false,it.configurable=true,"value"in it&&(it.writable=true),Object.defineProperty(gt,it.key,it);}}function F(gt,ot){return !ot||P(ot)!=="object"&&typeof ot!="function"?A(gt):ot}function A(gt){if(gt===void 0)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return gt}function O(gt){var ot=typeof Map=="function"?new Map:void 0;return O=function(Z){if(Z===null||(it=Z,Function.toString.call(it).indexOf("[native code]")===-1))return Z;var it;if(typeof Z!="function")throw new TypeError("Super expression must either be null or a function");if(ot!==void 0){if(ot.has(Z))return ot.get(Z);ot.set(Z,_t);}function _t(){return N(Z,arguments,X(this).constructor)}return _t.prototype=Object.create(Z.prototype,{constructor:{value:_t,enumerable:false,writable:true,configurable:true}}),G(_t,Z)},O(gt)}function N(gt,ot,Z){return N=V()?Reflect.construct:function(it,_t,ft){var Lt=[null];Lt.push.apply(Lt,_t);var It=new(Function.bind.apply(it,Lt));return ft&&G(It,ft.prototype),It},N.apply(null,arguments)}function V(){if(typeof Reflect=="undefined"||!Reflect.construct||Reflect.construct.sham)return false;if(typeof Proxy=="function")return true;try{return Date.prototype.toString.call(Reflect.construct(Date,[],(function(){}))),!0}catch(gt){return false}}function G(gt,ot){return G=Object.setPrototypeOf||function(Z,it){return Z.__proto__=it,Z},G(gt,ot)}function X(gt){return X=Object.setPrototypeOf?Object.getPrototypeOf:function(ot){return ot.__proto__||Object.getPrototypeOf(ot)},X(gt)}var nt=(function(gt){(function(It,Nt){if(typeof Nt!="function"&&Nt!==null)throw new TypeError("Super expression must either be null or a function");It.prototype=Object.create(Nt&&Nt.prototype,{constructor:{value:It,writable:true,configurable:true}}),Nt&&G(It,Nt);})(Lt,gt);var ot,Z,it,_t,ft=(ot=Lt,Z=V(),function(){var It,Nt=X(ot);if(Z){var se=X(this).constructor;It=Reflect.construct(Nt,arguments,se);}else It=Nt.apply(this,arguments);return F(this,It)});function Lt(It,Nt,se,ne,kn,Ae,cn){var pn,Ir,cr,en;((function(fn,dr){if(!(fn instanceof dr))throw new TypeError("Cannot call a class as a function")}))(this,Lt),(en=ft.call(this,It)).name="GraphQLError",en.originalError=Ae!=null?Ae:void 0,en.nodes=st(Array.isArray(Nt)?Nt:Nt?[Nt]:void 0);for(var ur=[],$t=0,Vr=(xn=en.nodes)!==null&&xn!==void 0?xn:[];$t<Vr.length;$t++){var xn,jn=Vr[$t].loc;jn!=null&&ur.push(jn);}ur=st(ur),en.source=se!=null?se:(pn=ur)===null||pn===void 0?void 0:pn[0].source,en.positions=ne!=null?ne:(Ir=ur)===null||Ir===void 0?void 0:Ir.map((function(fn){return fn.start})),en.locations=ne&&se?ne.map((function(fn){return s(se,fn)})):(cr=ur)===null||cr===void 0?void 0:cr.map((function(fn){return s(fn.source,fn.start)})),en.path=kn!=null?kn:void 0;var ct,si=Ae==null?void 0:Ae.extensions;return cn==null&&i(ct=si)=="object"&&ct!==null?en.extensions=(function(fn){for(var dr=1;dr<arguments.length;dr++){var kr=arguments[dr]!=null?arguments[dr]:{};dr%2?x(Object(kr),true).forEach((function(Ii){T(fn,Ii,kr[Ii]);})):Object.getOwnPropertyDescriptors?Object.defineProperties(fn,Object.getOwnPropertyDescriptors(kr)):x(Object(kr)).forEach((function(Ii){Object.defineProperty(fn,Ii,Object.getOwnPropertyDescriptor(kr,Ii));}));}return fn})({},si):en.extensions=cn!=null?cn:{},Object.defineProperties(A(en),{message:{enumerable:true},locations:{enumerable:en.locations!=null},path:{enumerable:en.path!=null},extensions:{enumerable:en.extensions!=null&&Object.keys(en.extensions).length>0},name:{enumerable:false},nodes:{enumerable:false},source:{enumerable:false},positions:{enumerable:false},originalError:{enumerable:false}}),Ae!=null&&Ae.stack?(Object.defineProperty(A(en),"stack",{value:Ae.stack,writable:true,configurable:true}),F(en)):(Error.captureStackTrace?Error.captureStackTrace(A(en),Lt):Object.defineProperty(A(en),"stack",{value:Error().stack,writable:true,configurable:true}),en)}return it=Lt,(_t=[{key:"toString",value:function(){return (function(It){var Nt=It.message;if(It.nodes)for(var se=0,ne=It.nodes;se<ne.length;se++){var kn=ne[se];kn.loc&&(Nt+=`
2296
+ `)}function v(gt){return Array(gt+1).join(" ")}function P(gt){return P=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(ot){return typeof ot}:function(ot){return ot&&typeof Symbol=="function"&&ot.constructor===Symbol&&ot!==Symbol.prototype?"symbol":typeof ot},P(gt)}function x(gt,ot){var Z=Object.keys(gt);if(Object.getOwnPropertySymbols){var it=Object.getOwnPropertySymbols(gt);ot&&(it=it.filter((function(_t){return Object.getOwnPropertyDescriptor(gt,_t).enumerable}))),Z.push.apply(Z,it);}return Z}function T(gt,ot,Z){return ot in gt?Object.defineProperty(gt,ot,{value:Z,enumerable:true,configurable:true,writable:true}):gt[ot]=Z,gt}function I(gt,ot){for(var Z=0;Z<ot.length;Z++){var it=ot[Z];it.enumerable=it.enumerable||false,it.configurable=true,"value"in it&&(it.writable=true),Object.defineProperty(gt,it.key,it);}}function R(gt,ot){return !ot||P(ot)!=="object"&&typeof ot!="function"?A(gt):ot}function A(gt){if(gt===void 0)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return gt}function O(gt){var ot=typeof Map=="function"?new Map:void 0;return O=function(Z){if(Z===null||(it=Z,Function.toString.call(it).indexOf("[native code]")===-1))return Z;var it;if(typeof Z!="function")throw new TypeError("Super expression must either be null or a function");if(ot!==void 0){if(ot.has(Z))return ot.get(Z);ot.set(Z,_t);}function _t(){return N(Z,arguments,X(this).constructor)}return _t.prototype=Object.create(Z.prototype,{constructor:{value:_t,enumerable:false,writable:true,configurable:true}}),G(_t,Z)},O(gt)}function N(gt,ot,Z){return N=V()?Reflect.construct:function(it,_t,ft){var Lt=[null];Lt.push.apply(Lt,_t);var It=new(Function.bind.apply(it,Lt));return ft&&G(It,ft.prototype),It},N.apply(null,arguments)}function V(){if(typeof Reflect=="undefined"||!Reflect.construct||Reflect.construct.sham)return false;if(typeof Proxy=="function")return true;try{return Date.prototype.toString.call(Reflect.construct(Date,[],(function(){}))),!0}catch(gt){return false}}function G(gt,ot){return G=Object.setPrototypeOf||function(Z,it){return Z.__proto__=it,Z},G(gt,ot)}function X(gt){return X=Object.setPrototypeOf?Object.getPrototypeOf:function(ot){return ot.__proto__||Object.getPrototypeOf(ot)},X(gt)}var nt=(function(gt){(function(It,Nt){if(typeof Nt!="function"&&Nt!==null)throw new TypeError("Super expression must either be null or a function");It.prototype=Object.create(Nt&&Nt.prototype,{constructor:{value:It,writable:true,configurable:true}}),Nt&&G(It,Nt);})(Lt,gt);var ot,Z,it,_t,ft=(ot=Lt,Z=V(),function(){var It,Nt=X(ot);if(Z){var se=X(this).constructor;It=Reflect.construct(Nt,arguments,se);}else It=Nt.apply(this,arguments);return R(this,It)});function Lt(It,Nt,se,ne,kn,Ae,cn){var pn,Ir,cr,en;((function(fn,dr){if(!(fn instanceof dr))throw new TypeError("Cannot call a class as a function")}))(this,Lt),(en=ft.call(this,It)).name="GraphQLError",en.originalError=Ae!=null?Ae:void 0,en.nodes=st(Array.isArray(Nt)?Nt:Nt?[Nt]:void 0);for(var ur=[],$t=0,Vr=(xn=en.nodes)!==null&&xn!==void 0?xn:[];$t<Vr.length;$t++){var xn,jn=Vr[$t].loc;jn!=null&&ur.push(jn);}ur=st(ur),en.source=se!=null?se:(pn=ur)===null||pn===void 0?void 0:pn[0].source,en.positions=ne!=null?ne:(Ir=ur)===null||Ir===void 0?void 0:Ir.map((function(fn){return fn.start})),en.locations=ne&&se?ne.map((function(fn){return s(se,fn)})):(cr=ur)===null||cr===void 0?void 0:cr.map((function(fn){return s(fn.source,fn.start)})),en.path=kn!=null?kn:void 0;var ct,si=Ae==null?void 0:Ae.extensions;return cn==null&&i(ct=si)=="object"&&ct!==null?en.extensions=(function(fn){for(var dr=1;dr<arguments.length;dr++){var kr=arguments[dr]!=null?arguments[dr]:{};dr%2?x(Object(kr),true).forEach((function(Ii){T(fn,Ii,kr[Ii]);})):Object.getOwnPropertyDescriptors?Object.defineProperties(fn,Object.getOwnPropertyDescriptors(kr)):x(Object(kr)).forEach((function(Ii){Object.defineProperty(fn,Ii,Object.getOwnPropertyDescriptor(kr,Ii));}));}return fn})({},si):en.extensions=cn!=null?cn:{},Object.defineProperties(A(en),{message:{enumerable:true},locations:{enumerable:en.locations!=null},path:{enumerable:en.path!=null},extensions:{enumerable:en.extensions!=null&&Object.keys(en.extensions).length>0},name:{enumerable:false},nodes:{enumerable:false},source:{enumerable:false},positions:{enumerable:false},originalError:{enumerable:false}}),Ae!=null&&Ae.stack?(Object.defineProperty(A(en),"stack",{value:Ae.stack,writable:true,configurable:true}),R(en)):(Error.captureStackTrace?Error.captureStackTrace(A(en),Lt):Object.defineProperty(A(en),"stack",{value:Error().stack,writable:true,configurable:true}),en)}return it=Lt,(_t=[{key:"toString",value:function(){return (function(It){var Nt=It.message;if(It.nodes)for(var se=0,ne=It.nodes;se<ne.length;se++){var kn=ne[se];kn.loc&&(Nt+=`
2297
2297
 
2298
2298
  `+c(kn.loc));}else if(It.source&&It.locations)for(var Ae=0,cn=It.locations;Ae<cn.length;Ae++){var pn=cn[Ae];Nt+=`
2299
2299
 
2300
2300
  `+p(It.source,pn);}return Nt})(this)}},{key:o.YF,get:function(){return "Object"}}])&&I(it.prototype,_t),Lt})(O(Error));function st(gt){return gt===void 0||gt.length===0?void 0:gt}function U(gt,ot,Z){return new nt("Syntax Error: ".concat(Z),void 0,gt,[ot])}var j=Object.freeze({NAME:"Name",DOCUMENT:"Document",OPERATION_DEFINITION:"OperationDefinition",VARIABLE_DEFINITION:"VariableDefinition",SELECTION_SET:"SelectionSet",FIELD:"Field",ARGUMENT:"Argument",FRAGMENT_SPREAD:"FragmentSpread",INLINE_FRAGMENT:"InlineFragment",FRAGMENT_DEFINITION:"FragmentDefinition",VARIABLE:"Variable",INT:"IntValue",FLOAT:"FloatValue",STRING:"StringValue",BOOLEAN:"BooleanValue",NULL:"NullValue",ENUM:"EnumValue",LIST:"ListValue",OBJECT:"ObjectValue",OBJECT_FIELD:"ObjectField",DIRECTIVE:"Directive",NAMED_TYPE:"NamedType",LIST_TYPE:"ListType",NON_NULL_TYPE:"NonNullType",SCHEMA_DEFINITION:"SchemaDefinition",OPERATION_TYPE_DEFINITION:"OperationTypeDefinition",SCALAR_TYPE_DEFINITION:"ScalarTypeDefinition",OBJECT_TYPE_DEFINITION:"ObjectTypeDefinition",FIELD_DEFINITION:"FieldDefinition",INPUT_VALUE_DEFINITION:"InputValueDefinition",INTERFACE_TYPE_DEFINITION:"InterfaceTypeDefinition",UNION_TYPE_DEFINITION:"UnionTypeDefinition",ENUM_TYPE_DEFINITION:"EnumTypeDefinition",ENUM_VALUE_DEFINITION:"EnumValueDefinition",INPUT_OBJECT_TYPE_DEFINITION:"InputObjectTypeDefinition",DIRECTIVE_DEFINITION:"DirectiveDefinition",SCHEMA_EXTENSION:"SchemaExtension",SCALAR_TYPE_EXTENSION:"ScalarTypeExtension",OBJECT_TYPE_EXTENSION:"ObjectTypeExtension",INTERFACE_TYPE_EXTENSION:"InterfaceTypeExtension",UNION_TYPE_EXTENSION:"UnionTypeExtension",ENUM_TYPE_EXTENSION:"EnumTypeExtension",INPUT_OBJECT_TYPE_EXTENSION:"InputObjectTypeExtension"}),ut=n(5217),Y=Object.freeze({SOF:"<SOF>",EOF:"<EOF>",BANG:"!",DOLLAR:"$",AMP:"&",PAREN_L:"(",PAREN_R:")",SPREAD:"...",COLON:":",EQUALS:"=",AT:"@",BRACKET_L:"[",BRACKET_R:"]",BRACE_L:"{",PIPE:"|",BRACE_R:"}",NAME:"Name",INT:"Int",FLOAT:"Float",STRING:"String",BLOCK_STRING:"BlockString",COMMENT:"Comment"}),at=n(143),pt=Object.freeze({QUERY:"QUERY",MUTATION:"MUTATION",SUBSCRIPTION:"SUBSCRIPTION",FIELD:"FIELD",FRAGMENT_DEFINITION:"FRAGMENT_DEFINITION",FRAGMENT_SPREAD:"FRAGMENT_SPREAD",INLINE_FRAGMENT:"INLINE_FRAGMENT",VARIABLE_DEFINITION:"VARIABLE_DEFINITION",SCHEMA:"SCHEMA",SCALAR:"SCALAR",OBJECT:"OBJECT",FIELD_DEFINITION:"FIELD_DEFINITION",ARGUMENT_DEFINITION:"ARGUMENT_DEFINITION",INTERFACE:"INTERFACE",UNION:"UNION",ENUM:"ENUM",ENUM_VALUE:"ENUM_VALUE",INPUT_OBJECT:"INPUT_OBJECT",INPUT_FIELD_DEFINITION:"INPUT_FIELD_DEFINITION"}),dt=n(7392),mt=(function(){function gt(Z){var it=new ut.WU(Y.SOF,0,0,0,0,null);this.source=Z,this.lastToken=it,this.token=it,this.line=1,this.lineStart=0;}var ot=gt.prototype;return ot.advance=function(){return this.lastToken=this.token,this.token=this.lookahead()},ot.lookahead=function(){var Z=this.token;if(Z.kind!==Y.EOF)do{var it;Z=(it=Z.next)!==null&&it!==void 0?it:Z.next=jt(this,Z);}while(Z.kind===Y.COMMENT);return Z},gt})();function Ct(gt){return isNaN(gt)?Y.EOF:gt<127?JSON.stringify(String.fromCharCode(gt)):'"\\u'.concat(("00"+gt.toString(16).toUpperCase()).slice(-4),'"')}function jt(gt,ot){for(var Z=gt.source,it=Z.body,_t=it.length,ft=ot.end;ft<_t;){var Lt=it.charCodeAt(ft),It=gt.line,Nt=1+ft-gt.lineStart;switch(Lt){case 65279:case 9:case 32:case 44:++ft;continue;case 10:++ft,++gt.line,gt.lineStart=ft;continue;case 13:it.charCodeAt(ft+1)===10?ft+=2:++ft,++gt.line,gt.lineStart=ft;continue;case 33:return new ut.WU(Y.BANG,ft,ft+1,It,Nt,ot);case 35:return Jt(Z,ft,It,Nt,ot);case 36:return new ut.WU(Y.DOLLAR,ft,ft+1,It,Nt,ot);case 38:return new ut.WU(Y.AMP,ft,ft+1,It,Nt,ot);case 40:return new ut.WU(Y.PAREN_L,ft,ft+1,It,Nt,ot);case 41:return new ut.WU(Y.PAREN_R,ft,ft+1,It,Nt,ot);case 46:if(it.charCodeAt(ft+1)===46&&it.charCodeAt(ft+2)===46)return new ut.WU(Y.SPREAD,ft,ft+3,It,Nt,ot);break;case 58:return new ut.WU(Y.COLON,ft,ft+1,It,Nt,ot);case 61:return new ut.WU(Y.EQUALS,ft,ft+1,It,Nt,ot);case 64:return new ut.WU(Y.AT,ft,ft+1,It,Nt,ot);case 91:return new ut.WU(Y.BRACKET_L,ft,ft+1,It,Nt,ot);case 93:return new ut.WU(Y.BRACKET_R,ft,ft+1,It,Nt,ot);case 123:return new ut.WU(Y.BRACE_L,ft,ft+1,It,Nt,ot);case 124:return new ut.WU(Y.PIPE,ft,ft+1,It,Nt,ot);case 125:return new ut.WU(Y.BRACE_R,ft,ft+1,It,Nt,ot);case 34:return it.charCodeAt(ft+1)===34&&it.charCodeAt(ft+2)===34?je(Z,ft,It,Nt,ot,gt):Ee(Z,ft,It,Nt,ot);case 45:case 48:case 49:case 50:case 51:case 52:case 53:case 54:case 55:case 56:case 57:return ee(Z,ft,Lt,It,Nt,ot);case 65:case 66:case 67:case 68:case 69:case 70:case 71:case 72:case 73:case 74:case 75:case 76:case 77:case 78:case 79:case 80:case 81:case 82:case 83:case 84:case 85:case 86:case 87:case 88:case 89:case 90:case 95:case 97:case 98:case 99:case 100:case 101:case 102:case 103:case 104:case 105:case 106:case 107:case 108:case 109:case 110:case 111:case 112:case 113:case 114:case 115:case 116:case 117:case 118:case 119:case 120:case 121:case 122:return Ze(Z,ft,It,Nt,ot)}throw U(Z,ft,Gt(Lt))}var se=gt.line,ne=1+ft-gt.lineStart;return new ut.WU(Y.EOF,_t,_t,se,ne,ot)}function Gt(gt){return gt<32&&gt!==9&&gt!==10&&gt!==13?"Cannot contain the invalid character ".concat(Ct(gt),"."):gt===39?`Unexpected single quote character ('), did you mean to use a double quote (")?`:"Cannot parse the unexpected character ".concat(Ct(gt),".")}function Jt(gt,ot,Z,it,_t){var ft,Lt=gt.body,It=ot;do ft=Lt.charCodeAt(++It);while(!isNaN(ft)&&(ft>31||ft===9));return new ut.WU(Y.COMMENT,ot,It,Z,it,_t,Lt.slice(ot+1,It))}function ee(gt,ot,Z,it,_t,ft){var Lt=gt.body,It=Z,Nt=ot,se=false;if(It===45&&(It=Lt.charCodeAt(++Nt)),It===48){if((It=Lt.charCodeAt(++Nt))>=48&&It<=57)throw U(gt,Nt,"Invalid number, unexpected digit after 0: ".concat(Ct(It),"."))}else Nt=re(gt,Nt,It),It=Lt.charCodeAt(Nt);if(It===46&&(se=true,It=Lt.charCodeAt(++Nt),Nt=re(gt,Nt,It),It=Lt.charCodeAt(Nt)),It!==69&&It!==101||(se=true,(It=Lt.charCodeAt(++Nt))!==43&&It!==45||(It=Lt.charCodeAt(++Nt)),Nt=re(gt,Nt,It),It=Lt.charCodeAt(Nt)),It===46||(function(ne){return ne===95||ne>=65&&ne<=90||ne>=97&&ne<=122})(It))throw U(gt,Nt,"Invalid number, expected digit but got: ".concat(Ct(It),"."));return new ut.WU(se?Y.FLOAT:Y.INT,ot,Nt,it,_t,ft,Lt.slice(ot,Nt))}function re(gt,ot,Z){var it=gt.body,_t=ot,ft=Z;if(ft>=48&&ft<=57){do ft=it.charCodeAt(++_t);while(ft>=48&&ft<=57);return _t}throw U(gt,_t,"Invalid number, expected digit but got: ".concat(Ct(ft),"."))}function Ee(gt,ot,Z,it,_t){for(var ft,Lt,It,Nt,se=gt.body,ne=ot+1,kn=ne,Ae=0,cn="";ne<se.length&&!isNaN(Ae=se.charCodeAt(ne))&&Ae!==10&&Ae!==13;){if(Ae===34)return cn+=se.slice(kn,ne),new ut.WU(Y.STRING,ot,ne+1,Z,it,_t,cn);if(Ae<32&&Ae!==9)throw U(gt,ne,"Invalid character within String: ".concat(Ct(Ae),"."));if(++ne,Ae===92){switch(cn+=se.slice(kn,ne-1),Ae=se.charCodeAt(ne)){case 34:cn+='"';break;case 47:cn+="/";break;case 92:cn+="\\";break;case 98:cn+="\b";break;case 102:cn+="\f";break;case 110:cn+=`
2301
2301
  `;break;case 114:cn+="\r";break;case 116:cn+=" ";break;case 117:var pn=(ft=se.charCodeAt(ne+1),Lt=se.charCodeAt(ne+2),It=se.charCodeAt(ne+3),Nt=se.charCodeAt(ne+4),sn(ft)<<12|sn(Lt)<<8|sn(It)<<4|sn(Nt));if(pn<0){var Ir=se.slice(ne+1,ne+5);throw U(gt,ne,"Invalid character escape sequence: \\u".concat(Ir,"."))}cn+=String.fromCharCode(pn),ne+=4;break;default:throw U(gt,ne,"Invalid character escape sequence: \\".concat(String.fromCharCode(Ae),"."))}kn=++ne;}}throw U(gt,ne,"Unterminated string.")}function je(gt,ot,Z,it,_t,ft){for(var Lt=gt.body,It=ot+3,Nt=It,se=0,ne="";It<Lt.length&&!isNaN(se=Lt.charCodeAt(It));){if(se===34&&Lt.charCodeAt(It+1)===34&&Lt.charCodeAt(It+2)===34)return ne+=Lt.slice(Nt,It),new ut.WU(Y.BLOCK_STRING,ot,It+3,Z,it,_t,(0, dt.W7)(ne));if(se<32&&se!==9&&se!==10&&se!==13)throw U(gt,It,"Invalid character within String: ".concat(Ct(se),"."));se===10?(++It,++ft.line,ft.lineStart=It):se===13?(Lt.charCodeAt(It+1)===10?It+=2:++It,++ft.line,ft.lineStart=It):se===92&&Lt.charCodeAt(It+1)===34&&Lt.charCodeAt(It+2)===34&&Lt.charCodeAt(It+3)===34?(ne+=Lt.slice(Nt,It)+'"""',Nt=It+=4):++It;}throw U(gt,It,"Unterminated string.")}function sn(gt){return gt>=48&&gt<=57?gt-48:gt>=65&&gt<=70?gt-55:gt>=97&&gt<=102?gt-87:-1}function Ze(gt,ot,Z,it,_t){for(var ft=gt.body,Lt=ft.length,It=ot+1,Nt=0;It!==Lt&&!isNaN(Nt=ft.charCodeAt(It))&&(Nt===95||Nt>=48&&Nt<=57||Nt>=65&&Nt<=90||Nt>=97&&Nt<=122);)++It;return new ut.WU(Y.NAME,ot,It,Z,it,_t,ft.slice(ot,It))}var Pn=(function(){function gt(Z,it){var _t=(0, at.T)(Z)?Z:new at.H(Z);this._lexer=new mt(_t),this._options=it;}var ot=gt.prototype;return ot.parseName=function(){var Z=this.expectToken(Y.NAME);return {kind:j.NAME,value:Z.value,loc:this.loc(Z)}},ot.parseDocument=function(){var Z=this._lexer.token;return {kind:j.DOCUMENT,definitions:this.many(Y.SOF,this.parseDefinition,Y.EOF),loc:this.loc(Z)}},ot.parseDefinition=function(){if(this.peek(Y.NAME))switch(this._lexer.token.value){case "query":case "mutation":case "subscription":return this.parseOperationDefinition();case "fragment":return this.parseFragmentDefinition();case "schema":case "scalar":case "type":case "interface":case "union":case "enum":case "input":case "directive":return this.parseTypeSystemDefinition();case "extend":return this.parseTypeSystemExtension()}else {if(this.peek(Y.BRACE_L))return this.parseOperationDefinition();if(this.peekDescription())return this.parseTypeSystemDefinition()}throw this.unexpected()},ot.parseOperationDefinition=function(){var Z=this._lexer.token;if(this.peek(Y.BRACE_L))return {kind:j.OPERATION_DEFINITION,operation:"query",name:void 0,variableDefinitions:[],directives:[],selectionSet:this.parseSelectionSet(),loc:this.loc(Z)};var it,_t=this.parseOperationType();return this.peek(Y.NAME)&&(it=this.parseName()),{kind:j.OPERATION_DEFINITION,operation:_t,name:it,variableDefinitions:this.parseVariableDefinitions(),directives:this.parseDirectives(false),selectionSet:this.parseSelectionSet(),loc:this.loc(Z)}},ot.parseOperationType=function(){var Z=this.expectToken(Y.NAME);switch(Z.value){case "query":return "query";case "mutation":return "mutation";case "subscription":return "subscription"}throw this.unexpected(Z)},ot.parseVariableDefinitions=function(){return this.optionalMany(Y.PAREN_L,this.parseVariableDefinition,Y.PAREN_R)},ot.parseVariableDefinition=function(){var Z=this._lexer.token;return {kind:j.VARIABLE_DEFINITION,variable:this.parseVariable(),type:(this.expectToken(Y.COLON),this.parseTypeReference()),defaultValue:this.expectOptionalToken(Y.EQUALS)?this.parseValueLiteral(true):void 0,directives:this.parseDirectives(true),loc:this.loc(Z)}},ot.parseVariable=function(){var Z=this._lexer.token;return this.expectToken(Y.DOLLAR),{kind:j.VARIABLE,name:this.parseName(),loc:this.loc(Z)}},ot.parseSelectionSet=function(){var Z=this._lexer.token;return {kind:j.SELECTION_SET,selections:this.many(Y.BRACE_L,this.parseSelection,Y.BRACE_R),loc:this.loc(Z)}},ot.parseSelection=function(){return this.peek(Y.SPREAD)?this.parseFragment():this.parseField()},ot.parseField=function(){var Z,it,_t=this._lexer.token,ft=this.parseName();return this.expectOptionalToken(Y.COLON)?(Z=ft,it=this.parseName()):it=ft,{kind:j.FIELD,alias:Z,name:it,arguments:this.parseArguments(false),directives:this.parseDirectives(false),selectionSet:this.peek(Y.BRACE_L)?this.parseSelectionSet():void 0,loc:this.loc(_t)}},ot.parseArguments=function(Z){var it=Z?this.parseConstArgument:this.parseArgument;return this.optionalMany(Y.PAREN_L,it,Y.PAREN_R)},ot.parseArgument=function(){var Z=this._lexer.token,it=this.parseName();return this.expectToken(Y.COLON),{kind:j.ARGUMENT,name:it,value:this.parseValueLiteral(false),loc:this.loc(Z)}},ot.parseConstArgument=function(){var Z=this._lexer.token;return {kind:j.ARGUMENT,name:this.parseName(),value:(this.expectToken(Y.COLON),this.parseValueLiteral(true)),loc:this.loc(Z)}},ot.parseFragment=function(){var Z=this._lexer.token;this.expectToken(Y.SPREAD);var it=this.expectOptionalKeyword("on");return !it&&this.peek(Y.NAME)?{kind:j.FRAGMENT_SPREAD,name:this.parseFragmentName(),directives:this.parseDirectives(false),loc:this.loc(Z)}:{kind:j.INLINE_FRAGMENT,typeCondition:it?this.parseNamedType():void 0,directives:this.parseDirectives(false),selectionSet:this.parseSelectionSet(),loc:this.loc(Z)}},ot.parseFragmentDefinition=function(){var Z,it=this._lexer.token;return this.expectKeyword("fragment"),((Z=this._options)===null||Z===void 0?void 0:Z.experimentalFragmentVariables)===true?{kind:j.FRAGMENT_DEFINITION,name:this.parseFragmentName(),variableDefinitions:this.parseVariableDefinitions(),typeCondition:(this.expectKeyword("on"),this.parseNamedType()),directives:this.parseDirectives(false),selectionSet:this.parseSelectionSet(),loc:this.loc(it)}:{kind:j.FRAGMENT_DEFINITION,name:this.parseFragmentName(),typeCondition:(this.expectKeyword("on"),this.parseNamedType()),directives:this.parseDirectives(false),selectionSet:this.parseSelectionSet(),loc:this.loc(it)}},ot.parseFragmentName=function(){if(this._lexer.token.value==="on")throw this.unexpected();return this.parseName()},ot.parseValueLiteral=function(Z){var it=this._lexer.token;switch(it.kind){case Y.BRACKET_L:return this.parseList(Z);case Y.BRACE_L:return this.parseObject(Z);case Y.INT:return this._lexer.advance(),{kind:j.INT,value:it.value,loc:this.loc(it)};case Y.FLOAT:return this._lexer.advance(),{kind:j.FLOAT,value:it.value,loc:this.loc(it)};case Y.STRING:case Y.BLOCK_STRING:return this.parseStringLiteral();case Y.NAME:switch(this._lexer.advance(),it.value){case "true":return {kind:j.BOOLEAN,value:true,loc:this.loc(it)};case "false":return {kind:j.BOOLEAN,value:false,loc:this.loc(it)};case "null":return {kind:j.NULL,loc:this.loc(it)};default:return {kind:j.ENUM,value:it.value,loc:this.loc(it)}}case Y.DOLLAR:if(!Z)return this.parseVariable()}throw this.unexpected()},ot.parseStringLiteral=function(){var Z=this._lexer.token;return this._lexer.advance(),{kind:j.STRING,value:Z.value,block:Z.kind===Y.BLOCK_STRING,loc:this.loc(Z)}},ot.parseList=function(Z){var it=this,_t=this._lexer.token;return {kind:j.LIST,values:this.any(Y.BRACKET_L,(function(){return it.parseValueLiteral(Z)}),Y.BRACKET_R),loc:this.loc(_t)}},ot.parseObject=function(Z){var it=this,_t=this._lexer.token;return {kind:j.OBJECT,fields:this.any(Y.BRACE_L,(function(){return it.parseObjectField(Z)}),Y.BRACE_R),loc:this.loc(_t)}},ot.parseObjectField=function(Z){var it=this._lexer.token,_t=this.parseName();return this.expectToken(Y.COLON),{kind:j.OBJECT_FIELD,name:_t,value:this.parseValueLiteral(Z),loc:this.loc(it)}},ot.parseDirectives=function(Z){for(var it=[];this.peek(Y.AT);)it.push(this.parseDirective(Z));return it},ot.parseDirective=function(Z){var it=this._lexer.token;return this.expectToken(Y.AT),{kind:j.DIRECTIVE,name:this.parseName(),arguments:this.parseArguments(Z),loc:this.loc(it)}},ot.parseTypeReference=function(){var Z,it=this._lexer.token;return this.expectOptionalToken(Y.BRACKET_L)?(Z=this.parseTypeReference(),this.expectToken(Y.BRACKET_R),Z={kind:j.LIST_TYPE,type:Z,loc:this.loc(it)}):Z=this.parseNamedType(),this.expectOptionalToken(Y.BANG)?{kind:j.NON_NULL_TYPE,type:Z,loc:this.loc(it)}:Z},ot.parseNamedType=function(){var Z=this._lexer.token;return {kind:j.NAMED_TYPE,name:this.parseName(),loc:this.loc(Z)}},ot.parseTypeSystemDefinition=function(){var Z=this.peekDescription()?this._lexer.lookahead():this._lexer.token;if(Z.kind===Y.NAME)switch(Z.value){case "schema":return this.parseSchemaDefinition();case "scalar":return this.parseScalarTypeDefinition();case "type":return this.parseObjectTypeDefinition();case "interface":return this.parseInterfaceTypeDefinition();case "union":return this.parseUnionTypeDefinition();case "enum":return this.parseEnumTypeDefinition();case "input":return this.parseInputObjectTypeDefinition();case "directive":return this.parseDirectiveDefinition()}throw this.unexpected(Z)},ot.peekDescription=function(){return this.peek(Y.STRING)||this.peek(Y.BLOCK_STRING)},ot.parseDescription=function(){if(this.peekDescription())return this.parseStringLiteral()},ot.parseSchemaDefinition=function(){var Z=this._lexer.token,it=this.parseDescription();this.expectKeyword("schema");var _t=this.parseDirectives(true),ft=this.many(Y.BRACE_L,this.parseOperationTypeDefinition,Y.BRACE_R);return {kind:j.SCHEMA_DEFINITION,description:it,directives:_t,operationTypes:ft,loc:this.loc(Z)}},ot.parseOperationTypeDefinition=function(){var Z=this._lexer.token,it=this.parseOperationType();this.expectToken(Y.COLON);var _t=this.parseNamedType();return {kind:j.OPERATION_TYPE_DEFINITION,operation:it,type:_t,loc:this.loc(Z)}},ot.parseScalarTypeDefinition=function(){var Z=this._lexer.token,it=this.parseDescription();this.expectKeyword("scalar");var _t=this.parseName(),ft=this.parseDirectives(true);return {kind:j.SCALAR_TYPE_DEFINITION,description:it,name:_t,directives:ft,loc:this.loc(Z)}},ot.parseObjectTypeDefinition=function(){var Z=this._lexer.token,it=this.parseDescription();this.expectKeyword("type");var _t=this.parseName(),ft=this.parseImplementsInterfaces(),Lt=this.parseDirectives(true),It=this.parseFieldsDefinition();return {kind:j.OBJECT_TYPE_DEFINITION,description:it,name:_t,interfaces:ft,directives:Lt,fields:It,loc:this.loc(Z)}},ot.parseImplementsInterfaces=function(){var Z;if(!this.expectOptionalKeyword("implements"))return [];if(((Z=this._options)===null||Z===void 0?void 0:Z.allowLegacySDLImplementsInterfaces)===true){var it=[];this.expectOptionalToken(Y.AMP);do it.push(this.parseNamedType());while(this.expectOptionalToken(Y.AMP)||this.peek(Y.NAME));return it}return this.delimitedMany(Y.AMP,this.parseNamedType)},ot.parseFieldsDefinition=function(){var Z;return ((Z=this._options)===null||Z===void 0?void 0:Z.allowLegacySDLEmptyFields)===true&&this.peek(Y.BRACE_L)&&this._lexer.lookahead().kind===Y.BRACE_R?(this._lexer.advance(),this._lexer.advance(),[]):this.optionalMany(Y.BRACE_L,this.parseFieldDefinition,Y.BRACE_R)},ot.parseFieldDefinition=function(){var Z=this._lexer.token,it=this.parseDescription(),_t=this.parseName(),ft=this.parseArgumentDefs();this.expectToken(Y.COLON);var Lt=this.parseTypeReference(),It=this.parseDirectives(true);return {kind:j.FIELD_DEFINITION,description:it,name:_t,arguments:ft,type:Lt,directives:It,loc:this.loc(Z)}},ot.parseArgumentDefs=function(){return this.optionalMany(Y.PAREN_L,this.parseInputValueDef,Y.PAREN_R)},ot.parseInputValueDef=function(){var Z=this._lexer.token,it=this.parseDescription(),_t=this.parseName();this.expectToken(Y.COLON);var ft,Lt=this.parseTypeReference();this.expectOptionalToken(Y.EQUALS)&&(ft=this.parseValueLiteral(true));var It=this.parseDirectives(true);return {kind:j.INPUT_VALUE_DEFINITION,description:it,name:_t,type:Lt,defaultValue:ft,directives:It,loc:this.loc(Z)}},ot.parseInterfaceTypeDefinition=function(){var Z=this._lexer.token,it=this.parseDescription();this.expectKeyword("interface");var _t=this.parseName(),ft=this.parseImplementsInterfaces(),Lt=this.parseDirectives(true),It=this.parseFieldsDefinition();return {kind:j.INTERFACE_TYPE_DEFINITION,description:it,name:_t,interfaces:ft,directives:Lt,fields:It,loc:this.loc(Z)}},ot.parseUnionTypeDefinition=function(){var Z=this._lexer.token,it=this.parseDescription();this.expectKeyword("union");var _t=this.parseName(),ft=this.parseDirectives(true),Lt=this.parseUnionMemberTypes();return {kind:j.UNION_TYPE_DEFINITION,description:it,name:_t,directives:ft,types:Lt,loc:this.loc(Z)}},ot.parseUnionMemberTypes=function(){return this.expectOptionalToken(Y.EQUALS)?this.delimitedMany(Y.PIPE,this.parseNamedType):[]},ot.parseEnumTypeDefinition=function(){var Z=this._lexer.token,it=this.parseDescription();this.expectKeyword("enum");var _t=this.parseName(),ft=this.parseDirectives(true),Lt=this.parseEnumValuesDefinition();return {kind:j.ENUM_TYPE_DEFINITION,description:it,name:_t,directives:ft,values:Lt,loc:this.loc(Z)}},ot.parseEnumValuesDefinition=function(){return this.optionalMany(Y.BRACE_L,this.parseEnumValueDefinition,Y.BRACE_R)},ot.parseEnumValueDefinition=function(){var Z=this._lexer.token,it=this.parseDescription(),_t=this.parseName(),ft=this.parseDirectives(true);return {kind:j.ENUM_VALUE_DEFINITION,description:it,name:_t,directives:ft,loc:this.loc(Z)}},ot.parseInputObjectTypeDefinition=function(){var Z=this._lexer.token,it=this.parseDescription();this.expectKeyword("input");var _t=this.parseName(),ft=this.parseDirectives(true),Lt=this.parseInputFieldsDefinition();return {kind:j.INPUT_OBJECT_TYPE_DEFINITION,description:it,name:_t,directives:ft,fields:Lt,loc:this.loc(Z)}},ot.parseInputFieldsDefinition=function(){return this.optionalMany(Y.BRACE_L,this.parseInputValueDef,Y.BRACE_R)},ot.parseTypeSystemExtension=function(){var Z=this._lexer.lookahead();if(Z.kind===Y.NAME)switch(Z.value){case "schema":return this.parseSchemaExtension();case "scalar":return this.parseScalarTypeExtension();case "type":return this.parseObjectTypeExtension();case "interface":return this.parseInterfaceTypeExtension();case "union":return this.parseUnionTypeExtension();case "enum":return this.parseEnumTypeExtension();case "input":return this.parseInputObjectTypeExtension()}throw this.unexpected(Z)},ot.parseSchemaExtension=function(){var Z=this._lexer.token;this.expectKeyword("extend"),this.expectKeyword("schema");var it=this.parseDirectives(true),_t=this.optionalMany(Y.BRACE_L,this.parseOperationTypeDefinition,Y.BRACE_R);if(it.length===0&&_t.length===0)throw this.unexpected();return {kind:j.SCHEMA_EXTENSION,directives:it,operationTypes:_t,loc:this.loc(Z)}},ot.parseScalarTypeExtension=function(){var Z=this._lexer.token;this.expectKeyword("extend"),this.expectKeyword("scalar");var it=this.parseName(),_t=this.parseDirectives(true);if(_t.length===0)throw this.unexpected();return {kind:j.SCALAR_TYPE_EXTENSION,name:it,directives:_t,loc:this.loc(Z)}},ot.parseObjectTypeExtension=function(){var Z=this._lexer.token;this.expectKeyword("extend"),this.expectKeyword("type");var it=this.parseName(),_t=this.parseImplementsInterfaces(),ft=this.parseDirectives(true),Lt=this.parseFieldsDefinition();if(_t.length===0&&ft.length===0&&Lt.length===0)throw this.unexpected();return {kind:j.OBJECT_TYPE_EXTENSION,name:it,interfaces:_t,directives:ft,fields:Lt,loc:this.loc(Z)}},ot.parseInterfaceTypeExtension=function(){var Z=this._lexer.token;this.expectKeyword("extend"),this.expectKeyword("interface");var it=this.parseName(),_t=this.parseImplementsInterfaces(),ft=this.parseDirectives(true),Lt=this.parseFieldsDefinition();if(_t.length===0&&ft.length===0&&Lt.length===0)throw this.unexpected();return {kind:j.INTERFACE_TYPE_EXTENSION,name:it,interfaces:_t,directives:ft,fields:Lt,loc:this.loc(Z)}},ot.parseUnionTypeExtension=function(){var Z=this._lexer.token;this.expectKeyword("extend"),this.expectKeyword("union");var it=this.parseName(),_t=this.parseDirectives(true),ft=this.parseUnionMemberTypes();if(_t.length===0&&ft.length===0)throw this.unexpected();return {kind:j.UNION_TYPE_EXTENSION,name:it,directives:_t,types:ft,loc:this.loc(Z)}},ot.parseEnumTypeExtension=function(){var Z=this._lexer.token;this.expectKeyword("extend"),this.expectKeyword("enum");var it=this.parseName(),_t=this.parseDirectives(true),ft=this.parseEnumValuesDefinition();if(_t.length===0&&ft.length===0)throw this.unexpected();return {kind:j.ENUM_TYPE_EXTENSION,name:it,directives:_t,values:ft,loc:this.loc(Z)}},ot.parseInputObjectTypeExtension=function(){var Z=this._lexer.token;this.expectKeyword("extend"),this.expectKeyword("input");var it=this.parseName(),_t=this.parseDirectives(true),ft=this.parseInputFieldsDefinition();if(_t.length===0&&ft.length===0)throw this.unexpected();return {kind:j.INPUT_OBJECT_TYPE_EXTENSION,name:it,directives:_t,fields:ft,loc:this.loc(Z)}},ot.parseDirectiveDefinition=function(){var Z=this._lexer.token,it=this.parseDescription();this.expectKeyword("directive"),this.expectToken(Y.AT);var _t=this.parseName(),ft=this.parseArgumentDefs(),Lt=this.expectOptionalKeyword("repeatable");this.expectKeyword("on");var It=this.parseDirectiveLocations();return {kind:j.DIRECTIVE_DEFINITION,description:it,name:_t,arguments:ft,repeatable:Lt,locations:It,loc:this.loc(Z)}},ot.parseDirectiveLocations=function(){return this.delimitedMany(Y.PIPE,this.parseDirectiveLocation)},ot.parseDirectiveLocation=function(){var Z=this._lexer.token,it=this.parseName();if(pt[it.value]!==void 0)return it;throw this.unexpected(Z)},ot.loc=function(Z){var it;if(((it=this._options)===null||it===void 0?void 0:it.noLocation)!==true)return new ut.Ye(Z,this._lexer.lastToken,this._lexer.source)},ot.peek=function(Z){return this._lexer.token.kind===Z},ot.expectToken=function(Z){var it=this._lexer.token;if(it.kind===Z)return this._lexer.advance(),it;throw U(this._lexer.source,it.start,"Expected ".concat(ln(Z),", found ").concat(Gn(it),"."))},ot.expectOptionalToken=function(Z){var it=this._lexer.token;if(it.kind===Z)return this._lexer.advance(),it},ot.expectKeyword=function(Z){var it=this._lexer.token;if(it.kind!==Y.NAME||it.value!==Z)throw U(this._lexer.source,it.start,'Expected "'.concat(Z,'", found ').concat(Gn(it),"."));this._lexer.advance();},ot.expectOptionalKeyword=function(Z){var it=this._lexer.token;return it.kind===Y.NAME&&it.value===Z&&(this._lexer.advance(),true)},ot.unexpected=function(Z){var it=Z!=null?Z:this._lexer.token;return U(this._lexer.source,it.start,"Unexpected ".concat(Gn(it),"."))},ot.any=function(Z,it,_t){this.expectToken(Z);for(var ft=[];!this.expectOptionalToken(_t);)ft.push(it.call(this));return ft},ot.optionalMany=function(Z,it,_t){if(this.expectOptionalToken(Z)){var ft=[];do ft.push(it.call(this));while(!this.expectOptionalToken(_t));return ft}return []},ot.many=function(Z,it,_t){this.expectToken(Z);var ft=[];do ft.push(it.call(this));while(!this.expectOptionalToken(_t));return ft},ot.delimitedMany=function(Z,it){this.expectOptionalToken(Z);var _t=[];do _t.push(it.call(this));while(this.expectOptionalToken(Z));return _t},gt})();function Gn(gt){var ot=gt.value;return ln(gt.kind)+(ot!=null?' "'.concat(ot,'"'):"")}function ln(gt){return (function(ot){return ot===Y.BANG||ot===Y.DOLLAR||ot===Y.AMP||ot===Y.PAREN_L||ot===Y.PAREN_R||ot===Y.SPREAD||ot===Y.COLON||ot===Y.EQUALS||ot===Y.AT||ot===Y.BRACKET_L||ot===Y.BRACKET_R||ot===Y.BRACE_L||ot===Y.PIPE||ot===Y.BRACE_R})(gt)?'"'.concat(gt,'"'):gt}var Ke=new Map,dn=new Map,or=true,_e=false;function De(gt){return gt.replace(/[\s,]+/g," ").trim()}function vr(gt){var ot=De(gt);if(!Ke.has(ot)){var Z=(function(it,_t){return new Pn(it,_t).parseDocument()})(gt,{experimentalFragmentVariables:_e,allowLegacyFragmentVariables:_e});if(!Z||Z.kind!=="Document")throw new Error("Not a valid GraphQL document.");Ke.set(ot,(function(it){var _t=new Set(it.definitions);_t.forEach((function(Lt){Lt.loc&&delete Lt.loc,Object.keys(Lt).forEach((function(It){var Nt=Lt[It];Nt&&typeof Nt=="object"&&_t.add(Nt);}));}));var ft=it.loc;return ft&&(delete ft.startToken,delete ft.endToken),it})((function(it){var _t=new Set,ft=[];return it.definitions.forEach((function(Lt){if(Lt.kind==="FragmentDefinition"){var It=Lt.name.value,Nt=De((ne=Lt.loc).source.body.substring(ne.start,ne.end)),se=dn.get(It);se&&!se.has(Nt)?or&&console.warn("Warning: fragment with name "+It+` already exists.
2302
2302
  graphql-tag enforces all fragment names across your application to be unique; read more about
2303
- this in the docs: http://dev.apollodata.com/core/fragments.html#unique-names`):se||dn.set(It,se=new Set),se.add(Nt),_t.has(Nt)||(_t.add(Nt),ft.push(Lt));}else ft.push(Lt);var ne;})),r(r({},it),{definitions:ft})})(Z)));}return Ke.get(ot)}function Ve(gt){for(var ot=[],Z=1;Z<arguments.length;Z++)ot[Z-1]=arguments[Z];typeof gt=="string"&&(gt=[gt]);var it=gt[0];return ot.forEach((function(_t,ft){_t&&_t.kind==="Document"?it+=_t.loc.source.body:it+=_t,it+=gt[ft+1];})),vr(it)}function bt(){Ke.clear(),dn.clear();}function ar(){or=false;}function sr(){_e=true;}function Jn(){_e=false;}var lr,wi=Ve,vo=bt,jr=ar,Co=sr,Ce=Jn;(lr=Ve||(Ve={})).gql=wi,lr.resetCaches=vo,lr.disableFragmentWarnings=jr,lr.enableExperimentalFragmentVariables=Co,lr.disableExperimentalFragmentVariables=Ce,Ve.default=Ve;let Vt=Ve;},8552:(t,e,n)=>{var r=n(852)(n(5639),"DataView");t.exports=r;},1989:(t,e,n)=>{var r=n(1789),i=n(401),o=n(7667),s=n(1327),c=n(1866);function p(h){var v=-1,P=h==null?0:h.length;for(this.clear();++v<P;){var x=h[v];this.set(x[0],x[1]);}}p.prototype.clear=r,p.prototype.delete=i,p.prototype.get=o,p.prototype.has=s,p.prototype.set=c,t.exports=p;},8407:(t,e,n)=>{var r=n(7040),i=n(4125),o=n(2117),s=n(7529),c=n(4705);function p(h){var v=-1,P=h==null?0:h.length;for(this.clear();++v<P;){var x=h[v];this.set(x[0],x[1]);}}p.prototype.clear=r,p.prototype.delete=i,p.prototype.get=o,p.prototype.has=s,p.prototype.set=c,t.exports=p;},7071:(t,e,n)=>{var r=n(852)(n(5639),"Map");t.exports=r;},3369:(t,e,n)=>{var r=n(4785),i=n(1285),o=n(6e3),s=n(9916),c=n(5265);function p(h){var v=-1,P=h==null?0:h.length;for(this.clear();++v<P;){var x=h[v];this.set(x[0],x[1]);}}p.prototype.clear=r,p.prototype.delete=i,p.prototype.get=o,p.prototype.has=s,p.prototype.set=c,t.exports=p;},3818:(t,e,n)=>{var r=n(852)(n(5639),"Promise");t.exports=r;},8525:(t,e,n)=>{var r=n(852)(n(5639),"Set");t.exports=r;},8668:(t,e,n)=>{var r=n(3369),i=n(619),o=n(2385);function s(c){var p=-1,h=c==null?0:c.length;for(this.__data__=new r;++p<h;)this.add(c[p]);}s.prototype.add=s.prototype.push=i,s.prototype.has=o,t.exports=s;},6384:(t,e,n)=>{var r=n(8407),i=n(7465),o=n(3779),s=n(7599),c=n(4758),p=n(4309);function h(v){var P=this.__data__=new r(v);this.size=P.size;}h.prototype.clear=i,h.prototype.delete=o,h.prototype.get=s,h.prototype.has=c,h.prototype.set=p,t.exports=h;},2705:(t,e,n)=>{var r=n(5639).Symbol;t.exports=r;},1149:(t,e,n)=>{var r=n(5639).Uint8Array;t.exports=r;},577:(t,e,n)=>{var r=n(852)(n(5639),"WeakMap");t.exports=r;},6874:t=>{t.exports=function(e,n,r){switch(r.length){case 0:return e.call(n);case 1:return e.call(n,r[0]);case 2:return e.call(n,r[0],r[1]);case 3:return e.call(n,r[0],r[1],r[2])}return e.apply(n,r)};},7412:t=>{t.exports=function(e,n){for(var r=-1,i=e==null?0:e.length;++r<i&&n(e[r],r,e)!==false;);return e};},4963:t=>{t.exports=function(e,n){for(var r=-1,i=e==null?0:e.length,o=0,s=[];++r<i;){var c=e[r];n(c,r,e)&&(s[o++]=c);}return s};},4636:(t,e,n)=>{var r=n(2545),i=n(5694),o=n(1469),s=n(4144),c=n(5776),p=n(6719),h=Object.prototype.hasOwnProperty;t.exports=function(v,P){var x=o(v),T=!x&&i(v),I=!x&&!T&&s(v),F=!x&&!T&&!I&&p(v),A=x||T||I||F,O=A?r(v.length,String):[],N=O.length;for(var V in v)!P&&!h.call(v,V)||A&&(V=="length"||I&&(V=="offset"||V=="parent")||F&&(V=="buffer"||V=="byteLength"||V=="byteOffset")||c(V,N))||O.push(V);return O};},9932:t=>{t.exports=function(e,n){for(var r=-1,i=e==null?0:e.length,o=Array(i);++r<i;)o[r]=n(e[r],r,e);return o};},2488:t=>{t.exports=function(e,n){for(var r=-1,i=n.length,o=e.length;++r<i;)e[o+r]=n[r];return e};},2908:t=>{t.exports=function(e,n){for(var r=-1,i=e==null?0:e.length;++r<i;)if(n(e[r],r,e))return true;return false};},6556:(t,e,n)=>{var r=n(9465),i=n(7813);t.exports=function(o,s,c){(c!==void 0&&!i(o[s],c)||c===void 0&&!(s in o))&&r(o,s,c);};},4865:(t,e,n)=>{var r=n(9465),i=n(7813),o=Object.prototype.hasOwnProperty;t.exports=function(s,c,p){var h=s[c];o.call(s,c)&&i(h,p)&&(p!==void 0||c in s)||r(s,c,p);};},8470:(t,e,n)=>{var r=n(7813);t.exports=function(i,o){for(var s=i.length;s--;)if(r(i[s][0],o))return s;return -1};},4037:(t,e,n)=>{var r=n(8363),i=n(3674);t.exports=function(o,s){return o&&r(s,i(s),o)};},3886:(t,e,n)=>{var r=n(8363),i=n(1704);t.exports=function(o,s){return o&&r(s,i(s),o)};},9465:(t,e,n)=>{var r=n(8777);t.exports=function(i,o,s){o=="__proto__"&&r?r(i,o,{configurable:true,enumerable:true,value:s,writable:true}):i[o]=s;};},5990:(t,e,n)=>{var r=n(6384),i=n(7412),o=n(4865),s=n(4037),c=n(3886),p=n(4626),h=n(278),v=n(8805),P=n(1911),x=n(8234),T=n(6904),I=n(4160),F=n(3824),A=n(9148),O=n(8517),N=n(1469),V=n(4144),G=n(6688),X=n(3218),nt=n(2928),st=n(3674),U=n(1704),j="[object Arguments]",ut="[object Function]",Y="[object Object]",at={};at[j]=at["[object Array]"]=at["[object ArrayBuffer]"]=at["[object DataView]"]=at["[object Boolean]"]=at["[object Date]"]=at["[object Float32Array]"]=at["[object Float64Array]"]=at["[object Int8Array]"]=at["[object Int16Array]"]=at["[object Int32Array]"]=at["[object Map]"]=at["[object Number]"]=at[Y]=at["[object RegExp]"]=at["[object Set]"]=at["[object String]"]=at["[object Symbol]"]=at["[object Uint8Array]"]=at["[object Uint8ClampedArray]"]=at["[object Uint16Array]"]=at["[object Uint32Array]"]=true,at["[object Error]"]=at[ut]=at["[object WeakMap]"]=false,t.exports=function pt(dt,mt,Ct,jt,Gt,Jt){var ee,re=1&mt,Ee=2&mt,je=4&mt;if(Ct&&(ee=Gt?Ct(dt,jt,Gt,Jt):Ct(dt)),ee!==void 0)return ee;if(!X(dt))return dt;var sn=N(dt);if(sn){if(ee=F(dt),!re)return h(dt,ee)}else {var Ze=I(dt),Pn=Ze==ut||Ze=="[object GeneratorFunction]";if(V(dt))return p(dt,re);if(Ze==Y||Ze==j||Pn&&!Gt){if(ee=Ee||Pn?{}:O(dt),!re)return Ee?P(dt,c(ee,dt)):v(dt,s(ee,dt))}else {if(!at[Ze])return Gt?dt:{};ee=A(dt,Ze,re);}}Jt||(Jt=new r);var Gn=Jt.get(dt);if(Gn)return Gn;Jt.set(dt,ee),nt(dt)?dt.forEach((function(Ke){ee.add(pt(Ke,mt,Ct,Ke,dt,Jt));})):G(dt)&&dt.forEach((function(Ke,dn){ee.set(dn,pt(Ke,mt,Ct,dn,dt,Jt));}));var ln=sn?void 0:(je?Ee?T:x:Ee?U:st)(dt);return i(ln||dt,(function(Ke,dn){ln&&(Ke=dt[dn=Ke]),o(ee,dn,pt(Ke,mt,Ct,dn,dt,Jt));})),ee};},3118:(t,e,n)=>{var r=n(3218),i=Object.create,o=(function(){function s(){}return function(c){if(!r(c))return {};if(i)return i(c);s.prototype=c;var p=new s;return s.prototype=void 0,p}})();t.exports=o;},4140:(t,e,n)=>{var r=n(7816),i=n(9291)(r);t.exports=i;},1848:t=>{t.exports=function(e,n,r,i){for(var o=e.length,s=r+(i?1:-1);i?s--:++s<o;)if(n(e[s],s,e))return s;return -1};},1078:(t,e,n)=>{var r=n(2488),i=n(7285);t.exports=function o(s,c,p,h,v){var P=-1,x=s.length;for(p||(p=i),v||(v=[]);++P<x;){var T=s[P];c>0&&p(T)?c>1?o(T,c-1,p,h,v):r(v,T):h||(v[v.length]=T);}return v};},8483:(t,e,n)=>{var r=n(5063)();t.exports=r;},7816:(t,e,n)=>{var r=n(8483),i=n(3674);t.exports=function(o,s){return o&&r(o,s,i)};},7786:(t,e,n)=>{var r=n(1811),i=n(327);t.exports=function(o,s){for(var c=0,p=(s=r(s,o)).length;o!=null&&c<p;)o=o[i(s[c++])];return c&&c==p?o:void 0};},8866:(t,e,n)=>{var r=n(2488),i=n(1469);t.exports=function(o,s,c){var p=s(o);return i(o)?p:r(p,c(o))};},4239:(t,e,n)=>{var r=n(2705),i=n(9607),o=n(2333),s=r?r.toStringTag:void 0;t.exports=function(c){return c==null?c===void 0?"[object Undefined]":"[object Null]":s&&s in Object(c)?i(c):o(c)};},13:t=>{t.exports=function(e,n){return e!=null&&n in Object(e)};},2118:(t,e,n)=>{var r=n(1848),i=n(2722),o=n(2351);t.exports=function(s,c,p){return c==c?o(s,c,p):r(s,i,p)};},9454:(t,e,n)=>{var r=n(4239),i=n(7005);t.exports=function(o){return i(o)&&r(o)=="[object Arguments]"};},939:(t,e,n)=>{var r=n(1299),i=n(7005);t.exports=function o(s,c,p,h,v){return s===c||(s==null||c==null||!i(s)&&!i(c)?s!=s&&c!=c:r(s,c,p,h,o,v))};},1299:(t,e,n)=>{var r=n(6384),i=n(7114),o=n(8351),s=n(6096),c=n(4160),p=n(1469),h=n(4144),v=n(6719),P="[object Arguments]",x="[object Array]",T="[object Object]",I=Object.prototype.hasOwnProperty;t.exports=function(F,A,O,N,V,G){var X=p(F),nt=p(A),st=X?x:c(F),U=nt?x:c(A),j=(st=st==P?T:st)==T,ut=(U=U==P?T:U)==T,Y=st==U;if(Y&&h(F)){if(!h(A))return false;X=true,j=false;}if(Y&&!j)return G||(G=new r),X||v(F)?i(F,A,O,N,V,G):o(F,A,st,O,N,V,G);if(!(1&O)){var at=j&&I.call(F,"__wrapped__"),pt=ut&&I.call(A,"__wrapped__");if(at||pt){var dt=at?F.value():F,mt=pt?A.value():A;return G||(G=new r),V(dt,mt,O,N,G)}}return !!Y&&(G||(G=new r),s(F,A,O,N,V,G))};},5588:(t,e,n)=>{var r=n(4160),i=n(7005);t.exports=function(o){return i(o)&&r(o)=="[object Map]"};},2958:(t,e,n)=>{var r=n(6384),i=n(939);t.exports=function(o,s,c,p){var h=c.length,v=h,P=!p;if(o==null)return !v;for(o=Object(o);h--;){var x=c[h];if(P&&x[2]?x[1]!==o[x[0]]:!(x[0]in o))return false}for(;++h<v;){var T=(x=c[h])[0],I=o[T],F=x[1];if(P&&x[2]){if(I===void 0&&!(T in o))return false}else {var A=new r;if(p)var O=p(I,F,T,o,s,A);if(!(O===void 0?i(F,I,3,p,A):O))return false}}return true};},2722:t=>{t.exports=function(e){return e!=e};},8458:(t,e,n)=>{var r=n(3560),i=n(5346),o=n(3218),s=n(346),c=/^\[object .+?Constructor\]$/,p=Function.prototype,h=Object.prototype,v=p.toString,P=h.hasOwnProperty,x=RegExp("^"+v.call(P).replace(/[\\^$.*+?()[\]{}|]/g,"\\$&").replace(/hasOwnProperty|(function).*?(?=\\\()| for .+?(?=\\\])/g,"$1.*?")+"$");t.exports=function(T){return !(!o(T)||i(T))&&(r(T)?x:c).test(s(T))};},9221:(t,e,n)=>{var r=n(4160),i=n(7005);t.exports=function(o){return i(o)&&r(o)=="[object Set]"};},8749:(t,e,n)=>{var r=n(4239),i=n(1780),o=n(7005),s={};s["[object Float32Array]"]=s["[object Float64Array]"]=s["[object Int8Array]"]=s["[object Int16Array]"]=s["[object Int32Array]"]=s["[object Uint8Array]"]=s["[object Uint8ClampedArray]"]=s["[object Uint16Array]"]=s["[object Uint32Array]"]=true,s["[object Arguments]"]=s["[object Array]"]=s["[object ArrayBuffer]"]=s["[object Boolean]"]=s["[object DataView]"]=s["[object Date]"]=s["[object Error]"]=s["[object Function]"]=s["[object Map]"]=s["[object Number]"]=s["[object Object]"]=s["[object RegExp]"]=s["[object Set]"]=s["[object String]"]=s["[object WeakMap]"]=false,t.exports=function(c){return o(c)&&i(c.length)&&!!s[r(c)]};},7206:(t,e,n)=>{var r=n(1573),i=n(6432),o=n(6557),s=n(1469),c=n(9601);t.exports=function(p){return typeof p=="function"?p:p==null?o:typeof p=="object"?s(p)?i(p[0],p[1]):r(p):c(p)};},280:(t,e,n)=>{var r=n(5726),i=n(6916),o=Object.prototype.hasOwnProperty;t.exports=function(s){if(!r(s))return i(s);var c=[];for(var p in Object(s))o.call(s,p)&&p!="constructor"&&c.push(p);return c};},313:(t,e,n)=>{var r=n(3218),i=n(5726),o=n(3498),s=Object.prototype.hasOwnProperty;t.exports=function(c){if(!r(c))return o(c);var p=i(c),h=[];for(var v in c)(v!="constructor"||!p&&s.call(c,v))&&h.push(v);return h};},9199:(t,e,n)=>{var r=n(4140),i=n(8612);t.exports=function(o,s){var c=-1,p=i(o)?Array(o.length):[];return r(o,(function(h,v,P){p[++c]=s(h,v,P);})),p};},1573:(t,e,n)=>{var r=n(2958),i=n(1499),o=n(2634);t.exports=function(s){var c=i(s);return c.length==1&&c[0][2]?o(c[0][0],c[0][1]):function(p){return p===s||r(p,s,c)}};},6432:(t,e,n)=>{var r=n(939),i=n(7361),o=n(9095),s=n(5403),c=n(9162),p=n(2634),h=n(327);t.exports=function(v,P){return s(v)&&c(P)?p(h(v),P):function(x){var T=i(x,v);return T===void 0&&T===P?o(x,v):r(P,T,3)}};},2980:(t,e,n)=>{var r=n(6384),i=n(6556),o=n(8483),s=n(9783),c=n(3218),p=n(1704),h=n(6390);t.exports=function v(P,x,T,I,F){P!==x&&o(x,(function(A,O){if(F||(F=new r),c(A))s(P,x,O,T,v,I,F);else {var N=I?I(h(P,O),A,O+"",P,x,F):void 0;N===void 0&&(N=A),i(P,O,N);}}),p);};},9783:(t,e,n)=>{var r=n(6556),i=n(4626),o=n(7133),s=n(278),c=n(8517),p=n(5694),h=n(1469),v=n(9246),P=n(4144),x=n(3560),T=n(3218),I=n(8630),F=n(6719),A=n(6390),O=n(9881);t.exports=function(N,V,G,X,nt,st,U){var j=A(N,G),ut=A(V,G),Y=U.get(ut);if(Y)r(N,G,Y);else {var at=st?st(j,ut,G+"",N,V,U):void 0,pt=at===void 0;if(pt){var dt=h(ut),mt=!dt&&P(ut),Ct=!dt&&!mt&&F(ut);at=ut,dt||mt||Ct?h(j)?at=j:v(j)?at=s(j):mt?(pt=false,at=i(ut,true)):Ct?(pt=false,at=o(ut,true)):at=[]:I(ut)||p(ut)?(at=j,p(j)?at=O(j):T(j)&&!x(j)||(at=c(ut))):pt=false;}pt&&(U.set(ut,at),nt(at,ut,X,st,U),U.delete(ut)),r(N,G,at);}};},371:t=>{t.exports=function(e){return function(n){return n==null?void 0:n[e]}};},9152:(t,e,n)=>{var r=n(7786);t.exports=function(i){return function(o){return r(o,i)}};},5976:(t,e,n)=>{var r=n(6557),i=n(5357),o=n(61);t.exports=function(s,c){return o(i(s,c,r),s+"")};},6560:(t,e,n)=>{var r=n(5703),i=n(8777),o=n(6557),s=i?function(c,p){return i(c,"toString",{configurable:true,enumerable:false,value:r(p),writable:true})}:o;t.exports=s;},4259:t=>{t.exports=function(e,n,r){var i=-1,o=e.length;n<0&&(n=-n>o?0:o+n),(r=r>o?o:r)<0&&(r+=o),o=n>r?0:r-n>>>0,n>>>=0;for(var s=Array(o);++i<o;)s[i]=e[i+n];return s};},5076:(t,e,n)=>{var r=n(4140);t.exports=function(i,o){var s;return r(i,(function(c,p,h){return !(s=o(c,p,h))})),!!s};},2545:t=>{t.exports=function(e,n){for(var r=-1,i=Array(e);++r<e;)i[r]=n(r);return i};},531:(t,e,n)=>{var r=n(2705),i=n(9932),o=n(1469),s=n(3448),c=r?r.prototype:void 0,p=c?c.toString:void 0;t.exports=function h(v){if(typeof v=="string")return v;if(o(v))return i(v,h)+"";if(s(v))return p?p.call(v):"";var P=v+"";return P=="0"&&1/v==-1/0?"-0":P};},7561:(t,e,n)=>{var r=n(7990),i=/^\s+/;t.exports=function(o){return o&&o.slice(0,r(o)+1).replace(i,"")};},7518:t=>{t.exports=function(e){return function(n){return e(n)}};},7406:(t,e,n)=>{var r=n(1811),i=n(928),o=n(292),s=n(327);t.exports=function(c,p){return p=r(p,c),(c=o(c,p))==null||delete c[s(i(p))]};},7415:(t,e,n)=>{var r=n(9932);t.exports=function(i,o){return r(o,(function(s){return i[s]}))};},4757:t=>{t.exports=function(e,n){return e.has(n)};},1811:(t,e,n)=>{var r=n(1469),i=n(5403),o=n(5514),s=n(9833);t.exports=function(c,p){return r(c)?c:i(c,p)?[c]:o(s(c))};},4318:(t,e,n)=>{var r=n(1149);t.exports=function(i){var o=new i.constructor(i.byteLength);return new r(o).set(new r(i)),o};},4626:(t,e,n)=>{t=n.nmd(t);var r=n(5639),i=e&&!e.nodeType&&e,o=i&&t&&!t.nodeType&&t,s=o&&o.exports===i?r.Buffer:void 0,c=s?s.allocUnsafe:void 0;t.exports=function(p,h){if(h)return p.slice();var v=p.length,P=c?c(v):new p.constructor(v);return p.copy(P),P};},7157:(t,e,n)=>{var r=n(4318);t.exports=function(i,o){var s=o?r(i.buffer):i.buffer;return new i.constructor(s,i.byteOffset,i.byteLength)};},3147:t=>{var e=/\w*$/;t.exports=function(n){var r=new n.constructor(n.source,e.exec(n));return r.lastIndex=n.lastIndex,r};},419:(t,e,n)=>{var r=n(2705),i=r?r.prototype:void 0,o=i?i.valueOf:void 0;t.exports=function(s){return o?Object(o.call(s)):{}};},7133:(t,e,n)=>{var r=n(4318);t.exports=function(i,o){var s=o?r(i.buffer):i.buffer;return new i.constructor(s,i.byteOffset,i.length)};},278:t=>{t.exports=function(e,n){var r=-1,i=e.length;for(n||(n=Array(i));++r<i;)n[r]=e[r];return n};},8363:(t,e,n)=>{var r=n(4865),i=n(9465);t.exports=function(o,s,c,p){var h=!c;c||(c={});for(var v=-1,P=s.length;++v<P;){var x=s[v],T=p?p(c[x],o[x],x,c,o):void 0;T===void 0&&(T=o[x]),h?i(c,x,T):r(c,x,T);}return c};},8805:(t,e,n)=>{var r=n(8363),i=n(9551);t.exports=function(o,s){return r(o,i(o),s)};},1911:(t,e,n)=>{var r=n(8363),i=n(1442);t.exports=function(o,s){return r(o,i(o),s)};},4429:(t,e,n)=>{var r=n(5639)["__core-js_shared__"];t.exports=r;},1463:(t,e,n)=>{var r=n(5976),i=n(6612);t.exports=function(o){return r((function(s,c){var p=-1,h=c.length,v=h>1?c[h-1]:void 0,P=h>2?c[2]:void 0;for(v=o.length>3&&typeof v=="function"?(h--,v):void 0,P&&i(c[0],c[1],P)&&(v=h<3?void 0:v,h=1),s=Object(s);++p<h;){var x=c[p];x&&o(s,x,p,v);}return s}))};},9291:(t,e,n)=>{var r=n(8612);t.exports=function(i,o){return function(s,c){if(s==null)return s;if(!r(s))return i(s,c);for(var p=s.length,h=o?p:-1,v=Object(s);(o?h--:++h<p)&&c(v[h],h,v)!==false;);return s}};},5063:t=>{t.exports=function(e){return function(n,r,i){for(var o=-1,s=Object(n),c=i(n),p=c.length;p--;){var h=c[e?p:++o];if(r(s[h],h,s)===false)break}return n}};},696:(t,e,n)=>{var r=n(8630);t.exports=function(i){return r(i)?void 0:i};},8777:(t,e,n)=>{var r=n(852),i=(function(){try{var o=r(Object,"defineProperty");return o({},"",{}),o}catch(s){}})();t.exports=i;},7114:(t,e,n)=>{var r=n(8668),i=n(2908),o=n(4757);t.exports=function(s,c,p,h,v,P){var x=1&p,T=s.length,I=c.length;if(T!=I&&!(x&&I>T))return false;var F=P.get(s),A=P.get(c);if(F&&A)return F==c&&A==s;var O=-1,N=true,V=2&p?new r:void 0;for(P.set(s,c),P.set(c,s);++O<T;){var G=s[O],X=c[O];if(h)var nt=x?h(X,G,O,c,s,P):h(G,X,O,s,c,P);if(nt!==void 0){if(nt)continue;N=false;break}if(V){if(!i(c,(function(st,U){if(!o(V,U)&&(G===st||v(G,st,p,h,P)))return V.push(U)}))){N=false;break}}else if(G!==X&&!v(G,X,p,h,P)){N=false;break}}return P.delete(s),P.delete(c),N};},8351:(t,e,n)=>{var r=n(2705),i=n(1149),o=n(7813),s=n(7114),c=n(8776),p=n(1814),h=r?r.prototype:void 0,v=h?h.valueOf:void 0;t.exports=function(P,x,T,I,F,A,O){switch(T){case "[object DataView]":if(P.byteLength!=x.byteLength||P.byteOffset!=x.byteOffset)return false;P=P.buffer,x=x.buffer;case "[object ArrayBuffer]":return !(P.byteLength!=x.byteLength||!A(new i(P),new i(x)));case "[object Boolean]":case "[object Date]":case "[object Number]":return o(+P,+x);case "[object Error]":return P.name==x.name&&P.message==x.message;case "[object RegExp]":case "[object String]":return P==x+"";case "[object Map]":var N=c;case "[object Set]":var V=1&I;if(N||(N=p),P.size!=x.size&&!V)return false;var G=O.get(P);if(G)return G==x;I|=2,O.set(P,x);var X=s(N(P),N(x),I,F,A,O);return O.delete(P),X;case "[object Symbol]":if(v)return v.call(P)==v.call(x)}return false};},6096:(t,e,n)=>{var r=n(8234),i=Object.prototype.hasOwnProperty;t.exports=function(o,s,c,p,h,v){var P=1&c,x=r(o),T=x.length;if(T!=r(s).length&&!P)return false;for(var I=T;I--;){var F=x[I];if(!(P?F in s:i.call(s,F)))return false}var A=v.get(o),O=v.get(s);if(A&&O)return A==s&&O==o;var N=true;v.set(o,s),v.set(s,o);for(var V=P;++I<T;){var G=o[F=x[I]],X=s[F];if(p)var nt=P?p(X,G,F,s,o,v):p(G,X,F,o,s,v);if(!(nt===void 0?G===X||h(G,X,c,p,v):nt)){N=false;break}V||(V=F=="constructor");}if(N&&!V){var st=o.constructor,U=s.constructor;st==U||!("constructor"in o)||!("constructor"in s)||typeof st=="function"&&st instanceof st&&typeof U=="function"&&U instanceof U||(N=false);}return v.delete(o),v.delete(s),N};},9021:(t,e,n)=>{var r=n(5564),i=n(5357),o=n(61);t.exports=function(s){return o(i(s,void 0,r),s+"")};},1957:(t,e,n)=>{var r=typeof n.g=="object"&&n.g&&n.g.Object===Object&&n.g;t.exports=r;},8234:(t,e,n)=>{var r=n(8866),i=n(9551),o=n(3674);t.exports=function(s){return r(s,o,i)};},6904:(t,e,n)=>{var r=n(8866),i=n(1442),o=n(1704);t.exports=function(s){return r(s,o,i)};},5050:(t,e,n)=>{var r=n(7019);t.exports=function(i,o){var s=i.__data__;return r(o)?s[typeof o=="string"?"string":"hash"]:s.map};},1499:(t,e,n)=>{var r=n(9162),i=n(3674);t.exports=function(o){for(var s=i(o),c=s.length;c--;){var p=s[c],h=o[p];s[c]=[p,h,r(h)];}return s};},852:(t,e,n)=>{var r=n(8458),i=n(7801);t.exports=function(o,s){var c=i(o,s);return r(c)?c:void 0};},5924:(t,e,n)=>{var r=n(5569)(Object.getPrototypeOf,Object);t.exports=r;},9607:(t,e,n)=>{var r=n(2705),i=Object.prototype,o=i.hasOwnProperty,s=i.toString,c=r?r.toStringTag:void 0;t.exports=function(p){var h=o.call(p,c),v=p[c];try{p[c]=void 0;var P=!0;}catch(T){}var x=s.call(p);return P&&(h?p[c]=v:delete p[c]),x};},9551:(t,e,n)=>{var r=n(4963),i=n(479),o=Object.prototype.propertyIsEnumerable,s=Object.getOwnPropertySymbols,c=s?function(p){return p==null?[]:(p=Object(p),r(s(p),(function(h){return o.call(p,h)})))}:i;t.exports=c;},1442:(t,e,n)=>{var r=n(2488),i=n(5924),o=n(9551),s=n(479),c=Object.getOwnPropertySymbols?function(p){for(var h=[];p;)r(h,o(p)),p=i(p);return h}:s;t.exports=c;},4160:(t,e,n)=>{var r=n(8552),i=n(7071),o=n(3818),s=n(8525),c=n(577),p=n(4239),h=n(346),v="[object Map]",P="[object Promise]",x="[object Set]",T="[object WeakMap]",I="[object DataView]",F=h(r),A=h(i),O=h(o),N=h(s),V=h(c),G=p;(r&&G(new r(new ArrayBuffer(1)))!=I||i&&G(new i)!=v||o&&G(o.resolve())!=P||s&&G(new s)!=x||c&&G(new c)!=T)&&(G=function(X){var nt=p(X),st=nt=="[object Object]"?X.constructor:void 0,U=st?h(st):"";if(U)switch(U){case F:return I;case A:return v;case O:return P;case N:return x;case V:return T}return nt}),t.exports=G;},7801:t=>{t.exports=function(e,n){return e==null?void 0:e[n]};},222:(t,e,n)=>{var r=n(1811),i=n(5694),o=n(1469),s=n(5776),c=n(1780),p=n(327);t.exports=function(h,v,P){for(var x=-1,T=(v=r(v,h)).length,I=false;++x<T;){var F=p(v[x]);if(!(I=h!=null&&P(h,F)))break;h=h[F];}return I||++x!=T?I:!!(T=h==null?0:h.length)&&c(T)&&s(F,T)&&(o(h)||i(h))};},1789:(t,e,n)=>{var r=n(4536);t.exports=function(){this.__data__=r?r(null):{},this.size=0;};},401:t=>{t.exports=function(e){var n=this.has(e)&&delete this.__data__[e];return this.size-=n?1:0,n};},7667:(t,e,n)=>{var r=n(4536),i=Object.prototype.hasOwnProperty;t.exports=function(o){var s=this.__data__;if(r){var c=s[o];return c==="__lodash_hash_undefined__"?void 0:c}return i.call(s,o)?s[o]:void 0};},1327:(t,e,n)=>{var r=n(4536),i=Object.prototype.hasOwnProperty;t.exports=function(o){var s=this.__data__;return r?s[o]!==void 0:i.call(s,o)};},1866:(t,e,n)=>{var r=n(4536);t.exports=function(i,o){var s=this.__data__;return this.size+=this.has(i)?0:1,s[i]=r&&o===void 0?"__lodash_hash_undefined__":o,this};},3824:t=>{var e=Object.prototype.hasOwnProperty;t.exports=function(n){var r=n.length,i=new n.constructor(r);return r&&typeof n[0]=="string"&&e.call(n,"index")&&(i.index=n.index,i.input=n.input),i};},9148:(t,e,n)=>{var r=n(4318),i=n(7157),o=n(3147),s=n(419),c=n(7133);t.exports=function(p,h,v){var P=p.constructor;switch(h){case "[object ArrayBuffer]":return r(p);case "[object Boolean]":case "[object Date]":return new P(+p);case "[object DataView]":return i(p,v);case "[object Float32Array]":case "[object Float64Array]":case "[object Int8Array]":case "[object Int16Array]":case "[object Int32Array]":case "[object Uint8Array]":case "[object Uint8ClampedArray]":case "[object Uint16Array]":case "[object Uint32Array]":return c(p,v);case "[object Map]":case "[object Set]":return new P;case "[object Number]":case "[object String]":return new P(p);case "[object RegExp]":return o(p);case "[object Symbol]":return s(p)}};},8517:(t,e,n)=>{var r=n(3118),i=n(5924),o=n(5726);t.exports=function(s){return typeof s.constructor!="function"||o(s)?{}:r(i(s))};},7285:(t,e,n)=>{var r=n(2705),i=n(5694),o=n(1469),s=r?r.isConcatSpreadable:void 0;t.exports=function(c){return o(c)||i(c)||!!(s&&c&&c[s])};},5776:t=>{var e=/^(?:0|[1-9]\d*)$/;t.exports=function(n,r){var i=typeof n;return !!(r=r==null?9007199254740991:r)&&(i=="number"||i!="symbol"&&e.test(n))&&n>-1&&n%1==0&&n<r};},6612:(t,e,n)=>{var r=n(7813),i=n(8612),o=n(5776),s=n(3218);t.exports=function(c,p,h){if(!s(h))return false;var v=typeof p;return !!(v=="number"?i(h)&&o(p,h.length):v=="string"&&p in h)&&r(h[p],c)};},5403:(t,e,n)=>{var r=n(1469),i=n(3448),o=/\.|\[(?:[^[\]]*|(["'])(?:(?!\1)[^\\]|\\.)*?\1)\]/,s=/^\w*$/;t.exports=function(c,p){if(r(c))return false;var h=typeof c;return !(h!="number"&&h!="symbol"&&h!="boolean"&&c!=null&&!i(c))||s.test(c)||!o.test(c)||p!=null&&c in Object(p)};},7019:t=>{t.exports=function(e){var n=typeof e;return n=="string"||n=="number"||n=="symbol"||n=="boolean"?e!=="__proto__":e===null};},5346:(t,e,n)=>{var r,i=n(4429),o=(r=/[^.]+$/.exec(i&&i.keys&&i.keys.IE_PROTO||""))?"Symbol(src)_1."+r:"";t.exports=function(s){return !!o&&o in s};},5726:t=>{var e=Object.prototype;t.exports=function(n){var r=n&&n.constructor;return n===(typeof r=="function"&&r.prototype||e)};},9162:(t,e,n)=>{var r=n(3218);t.exports=function(i){return i==i&&!r(i)};},7040:t=>{t.exports=function(){this.__data__=[],this.size=0;};},4125:(t,e,n)=>{var r=n(8470),i=Array.prototype.splice;t.exports=function(o){var s=this.__data__,c=r(s,o);return !(c<0||(c==s.length-1?s.pop():i.call(s,c,1),--this.size,0))};},2117:(t,e,n)=>{var r=n(8470);t.exports=function(i){var o=this.__data__,s=r(o,i);return s<0?void 0:o[s][1]};},7529:(t,e,n)=>{var r=n(8470);t.exports=function(i){return r(this.__data__,i)>-1};},4705:(t,e,n)=>{var r=n(8470);t.exports=function(i,o){var s=this.__data__,c=r(s,i);return c<0?(++this.size,s.push([i,o])):s[c][1]=o,this};},4785:(t,e,n)=>{var r=n(1989),i=n(8407),o=n(7071);t.exports=function(){this.size=0,this.__data__={hash:new r,map:new(o||i),string:new r};};},1285:(t,e,n)=>{var r=n(5050);t.exports=function(i){var o=r(this,i).delete(i);return this.size-=o?1:0,o};},6e3:(t,e,n)=>{var r=n(5050);t.exports=function(i){return r(this,i).get(i)};},9916:(t,e,n)=>{var r=n(5050);t.exports=function(i){return r(this,i).has(i)};},5265:(t,e,n)=>{var r=n(5050);t.exports=function(i,o){var s=r(this,i),c=s.size;return s.set(i,o),this.size+=s.size==c?0:1,this};},8776:t=>{t.exports=function(e){var n=-1,r=Array(e.size);return e.forEach((function(i,o){r[++n]=[o,i];})),r};},2634:t=>{t.exports=function(e,n){return function(r){return r!=null&&r[e]===n&&(n!==void 0||e in Object(r))}};},4523:(t,e,n)=>{var r=n(8306);t.exports=function(i){var o=r(i,(function(c){return s.size===500&&s.clear(),c})),s=o.cache;return o};},4536:(t,e,n)=>{var r=n(852)(Object,"create");t.exports=r;},6916:(t,e,n)=>{var r=n(5569)(Object.keys,Object);t.exports=r;},3498:t=>{t.exports=function(e){var n=[];if(e!=null)for(var r in Object(e))n.push(r);return n};},1167:(t,e,n)=>{t=n.nmd(t);var r=n(1957),i=e&&!e.nodeType&&e,o=i&&t&&!t.nodeType&&t,s=o&&o.exports===i&&r.process,c=(function(){try{return o&&o.require&&o.require("util").types||s&&s.binding&&s.binding("util")}catch(p){}})();t.exports=c;},2333:t=>{var e=Object.prototype.toString;t.exports=function(n){return e.call(n)};},5569:t=>{t.exports=function(e,n){return function(r){return e(n(r))}};},5357:(t,e,n)=>{var r=n(6874),i=Math.max;t.exports=function(o,s,c){return s=i(s===void 0?o.length-1:s,0),function(){for(var p=arguments,h=-1,v=i(p.length-s,0),P=Array(v);++h<v;)P[h]=p[s+h];h=-1;for(var x=Array(s+1);++h<s;)x[h]=p[h];return x[s]=c(P),r(o,this,x)}};},292:(t,e,n)=>{var r=n(7786),i=n(4259);t.exports=function(o,s){return s.length<2?o:r(o,i(s,0,-1))};},5639:(t,e,n)=>{var r=n(1957),i=typeof self=="object"&&self&&self.Object===Object&&self,o=r||i||Function("return this")();t.exports=o;},6390:t=>{t.exports=function(e,n){if((n!=="constructor"||typeof e[n]!="function")&&n!="__proto__")return e[n]};},619:t=>{t.exports=function(e){return this.__data__.set(e,"__lodash_hash_undefined__"),this};},2385:t=>{t.exports=function(e){return this.__data__.has(e)};},1814:t=>{t.exports=function(e){var n=-1,r=Array(e.size);return e.forEach((function(i){r[++n]=i;})),r};},61:(t,e,n)=>{var r=n(6560),i=n(1275)(r);t.exports=i;},1275:t=>{var e=Date.now;t.exports=function(n){var r=0,i=0;return function(){var o=e(),s=16-(o-i);if(i=o,s>0){if(++r>=800)return arguments[0]}else r=0;return n.apply(void 0,arguments)}};},7465:(t,e,n)=>{var r=n(8407);t.exports=function(){this.__data__=new r,this.size=0;};},3779:t=>{t.exports=function(e){var n=this.__data__,r=n.delete(e);return this.size=n.size,r};},7599:t=>{t.exports=function(e){return this.__data__.get(e)};},4758:t=>{t.exports=function(e){return this.__data__.has(e)};},4309:(t,e,n)=>{var r=n(8407),i=n(7071),o=n(3369);t.exports=function(s,c){var p=this.__data__;if(p instanceof r){var h=p.__data__;if(!i||h.length<199)return h.push([s,c]),this.size=++p.size,this;p=this.__data__=new o(h);}return p.set(s,c),this.size=p.size,this};},2351:t=>{t.exports=function(e,n,r){for(var i=r-1,o=e.length;++i<o;)if(e[i]===n)return i;return -1};},5514:(t,e,n)=>{var r=n(4523),i=/[^.[\]]+|\[(?:(-?\d+(?:\.\d+)?)|(["'])((?:(?!\2)[^\\]|\\.)*?)\2)\]|(?=(?:\.|\[\])(?:\.|\[\]|$))/g,o=/\\(\\)?/g,s=r((function(c){var p=[];return c.charCodeAt(0)===46&&p.push(""),c.replace(i,(function(h,v,P,x){p.push(P?x.replace(o,"$1"):v||h);})),p}));t.exports=s;},327:(t,e,n)=>{var r=n(3448);t.exports=function(i){if(typeof i=="string"||r(i))return i;var o=i+"";return o=="0"&&1/i==-1/0?"-0":o};},346:t=>{var e=Function.prototype.toString;t.exports=function(n){if(n!=null){try{return e.call(n)}catch(r){}try{return n+""}catch(r){}}return ""};},7990:t=>{var e=/\s/;t.exports=function(n){for(var r=n.length;r--&&e.test(n.charAt(r)););return r};},5703:t=>{t.exports=function(e){return function(){return e}};},7813:t=>{t.exports=function(e,n){return e===n||e!=e&&n!=n};},5564:(t,e,n)=>{var r=n(1078);t.exports=function(i){return i!=null&&i.length?r(i,1):[]};},7361:(t,e,n)=>{var r=n(7786);t.exports=function(i,o,s){var c=i==null?void 0:r(i,o);return c===void 0?s:c};},9095:(t,e,n)=>{var r=n(13),i=n(222);t.exports=function(o,s){return o!=null&&i(o,s,r)};},6557:t=>{t.exports=function(e){return e};},4721:(t,e,n)=>{var r=n(2118),i=n(8612),o=n(7037),s=n(554),c=n(2628),p=Math.max;t.exports=function(h,v,P,x){h=i(h)?h:c(h),P=P&&!x?s(P):0;var T=h.length;return P<0&&(P=p(T+P,0)),o(h)?P<=T&&h.indexOf(v,P)>-1:!!T&&r(h,v,P)>-1};},5694:(t,e,n)=>{var r=n(9454),i=n(7005),o=Object.prototype,s=o.hasOwnProperty,c=o.propertyIsEnumerable,p=r((function(){return arguments})())?r:function(h){return i(h)&&s.call(h,"callee")&&!c.call(h,"callee")};t.exports=p;},1469:t=>{var e=Array.isArray;t.exports=e;},8612:(t,e,n)=>{var r=n(3560),i=n(1780);t.exports=function(o){return o!=null&&i(o.length)&&!r(o)};},9246:(t,e,n)=>{var r=n(8612),i=n(7005);t.exports=function(o){return i(o)&&r(o)};},4144:(t,e,n)=>{t=n.nmd(t);var r=n(5639),i=n(5062),o=e&&!e.nodeType&&e,s=o&&t&&!t.nodeType&&t,c=s&&s.exports===o?r.Buffer:void 0,p=(c?c.isBuffer:void 0)||i;t.exports=p;},1609:(t,e,n)=>{var r=n(280),i=n(4160),o=n(5694),s=n(1469),c=n(8612),p=n(4144),h=n(5726),v=n(6719),P=Object.prototype.hasOwnProperty;t.exports=function(x){if(x==null)return true;if(c(x)&&(s(x)||typeof x=="string"||typeof x.splice=="function"||p(x)||v(x)||o(x)))return !x.length;var T=i(x);if(T=="[object Map]"||T=="[object Set]")return !x.size;if(h(x))return !r(x).length;for(var I in x)if(P.call(x,I))return false;return true};},3560:(t,e,n)=>{var r=n(4239),i=n(3218);t.exports=function(o){if(!i(o))return false;var s=r(o);return s=="[object Function]"||s=="[object GeneratorFunction]"||s=="[object AsyncFunction]"||s=="[object Proxy]"};},1780:t=>{t.exports=function(e){return typeof e=="number"&&e>-1&&e%1==0&&e<=9007199254740991};},6688:(t,e,n)=>{var r=n(5588),i=n(7518),o=n(1167),s=o&&o.isMap,c=s?i(s):r;t.exports=c;},3218:t=>{t.exports=function(e){var n=typeof e;return e!=null&&(n=="object"||n=="function")};},7005:t=>{t.exports=function(e){return e!=null&&typeof e=="object"};},8630:(t,e,n)=>{var r=n(4239),i=n(5924),o=n(7005),s=Function.prototype,c=Object.prototype,p=s.toString,h=c.hasOwnProperty,v=p.call(Object);t.exports=function(P){if(!o(P)||r(P)!="[object Object]")return false;var x=i(P);if(x===null)return true;var T=h.call(x,"constructor")&&x.constructor;return typeof T=="function"&&T instanceof T&&p.call(T)==v};},2928:(t,e,n)=>{var r=n(9221),i=n(7518),o=n(1167),s=o&&o.isSet,c=s?i(s):r;t.exports=c;},7037:(t,e,n)=>{var r=n(4239),i=n(1469),o=n(7005);t.exports=function(s){return typeof s=="string"||!i(s)&&o(s)&&r(s)=="[object String]"};},3448:(t,e,n)=>{var r=n(4239),i=n(7005);t.exports=function(o){return typeof o=="symbol"||i(o)&&r(o)=="[object Symbol]"};},6719:(t,e,n)=>{var r=n(8749),i=n(7518),o=n(1167),s=o&&o.isTypedArray,c=s?i(s):r;t.exports=c;},3674:(t,e,n)=>{var r=n(4636),i=n(280),o=n(8612);t.exports=function(s){return o(s)?r(s):i(s)};},1704:(t,e,n)=>{var r=n(4636),i=n(313),o=n(8612);t.exports=function(s){return o(s)?r(s,true):i(s)};},928:t=>{t.exports=function(e){var n=e==null?0:e.length;return n?e[n-1]:void 0};},6486:function(t,e,n){var r;t=n.nmd(t),function(){var i,o="Expected a function",s="__lodash_hash_undefined__",c="__lodash_placeholder__",p=32,h=128,v=1/0,P=9007199254740991,x=NaN,T=4294967295,I=[["ary",h],["bind",1],["bindKey",2],["curry",8],["curryRight",16],["flip",512],["partial",p],["partialRight",64],["rearg",256]],F="[object Arguments]",A="[object Array]",O="[object Boolean]",N="[object Date]",V="[object Error]",G="[object Function]",X="[object GeneratorFunction]",nt="[object Map]",st="[object Number]",U="[object Object]",j="[object Promise]",ut="[object RegExp]",Y="[object Set]",at="[object String]",pt="[object Symbol]",dt="[object WeakMap]",mt="[object ArrayBuffer]",Ct="[object DataView]",jt="[object Float32Array]",Gt="[object Float64Array]",Jt="[object Int8Array]",ee="[object Int16Array]",re="[object Int32Array]",Ee="[object Uint8Array]",je="[object Uint8ClampedArray]",sn="[object Uint16Array]",Ze="[object Uint32Array]",Pn=/\b__p \+= '';/g,Gn=/\b(__p \+=) '' \+/g,ln=/(__e\(.*?\)|\b__t\)) \+\n'';/g,Ke=/&(?:amp|lt|gt|quot|#39);/g,dn=/[&<>"']/g,or=RegExp(Ke.source),_e=RegExp(dn.source),De=/<%-([\s\S]+?)%>/g,vr=/<%([\s\S]+?)%>/g,Ve=/<%=([\s\S]+?)%>/g,bt=/\.|\[(?:[^[\]]*|(["'])(?:(?!\1)[^\\]|\\.)*?\1)\]/,ar=/^\w*$/,sr=/[^.[\]]+|\[(?:(-?\d+(?:\.\d+)?)|(["'])((?:(?!\2)[^\\]|\\.)*?)\2)\]|(?=(?:\.|\[\])(?:\.|\[\]|$))/g,Jn=/[\\^$.*+?()[\]{}|]/g,lr=RegExp(Jn.source),wi=/^\s+/,vo=/\s/,jr=/\{(?:\n\/\* \[wrapped with .+\] \*\/)?\n?/,Co=/\{\n\/\* \[wrapped with (.+)\] \*/,Ce=/,? & /,Vt=/[^\x00-\x2f\x3a-\x40\x5b-\x60\x7b-\x7f]+/g,gt=/[()=,{}\[\]\/\s]/,ot=/\\(\\)?/g,Z=/\$\{([^\\}]*(?:\\.[^\\}]*)*)\}/g,it=/\w*$/,_t=/^[-+]0x[0-9a-f]+$/i,ft=/^0b[01]+$/i,Lt=/^\[object .+?Constructor\]$/,It=/^0o[0-7]+$/i,Nt=/^(?:0|[1-9]\d*)$/,se=/[\xc0-\xd6\xd8-\xf6\xf8-\xff\u0100-\u017f]/g,ne=/($^)/,kn=/['\n\r\u2028\u2029\\]/g,Ae="\\u0300-\\u036f\\ufe20-\\ufe2f\\u20d0-\\u20ff",cn="a-z\\xdf-\\xf6\\xf8-\\xff",pn="A-Z\\xc0-\\xd6\\xd8-\\xde",Ir="\\xac\\xb1\\xd7\\xf7\\x00-\\x2f\\x3a-\\x40\\x5b-\\x60\\x7b-\\xbf\\u2000-\\u206f \\t\\x0b\\f\\xa0\\ufeff\\n\\r\\u2028\\u2029\\u1680\\u180e\\u2000\\u2001\\u2002\\u2003\\u2004\\u2005\\u2006\\u2007\\u2008\\u2009\\u200a\\u202f\\u205f\\u3000",cr="["+Ir+"]",en="["+Ae+"]",ur="\\d+",$t="["+cn+"]",Vr="[^\\ud800-\\udfff"+Ir+ur+"\\u2700-\\u27bf"+cn+pn+"]",xn="\\ud83c[\\udffb-\\udfff]",jn="[^\\ud800-\\udfff]",ct="(?:\\ud83c[\\udde6-\\uddff]){2}",si="[\\ud800-\\udbff][\\udc00-\\udfff]",fn="["+pn+"]",dr="(?:"+$t+"|"+Vr+")",kr="(?:"+fn+"|"+Vr+")",Ii="(?:['\u2019](?:d|ll|m|re|s|t|ve))?",Wi="(?:['\u2019](?:D|LL|M|RE|S|T|VE))?",ki="(?:"+en+"|"+xn+")?",hs="[\\ufe0e\\ufe0f]?",Sa=hs+ki+"(?:\\u200d(?:"+[jn,ct,si].join("|")+")"+hs+ki+")*",ms="(?:"+["[\\u2700-\\u27bf]",ct,si].join("|")+")"+Sa,Di="(?:"+[jn+en+"?",en,ct,si,"[\\ud800-\\udfff]"].join("|")+")",hn=RegExp("['\u2019]","g"),pr=RegExp(en,"g"),Je=RegExp(xn+"(?="+xn+")|"+Di+Sa,"g"),vt=RegExp([fn+"?"+$t+"+"+Ii+"(?="+[cr,fn,"$"].join("|")+")",kr+"+"+Wi+"(?="+[cr,fn+dr,"$"].join("|")+")",fn+"?"+dr+"+"+Ii,fn+"+"+Wi,"\\d*(?:1ST|2ND|3RD|(?![123])\\dTH)(?=\\b|[a-z_])","\\d*(?:1st|2nd|3rd|(?![123])\\dth)(?=\\b|[A-Z_])",ur,ms].join("|"),"g"),gs=RegExp("[\\u200d\\ud800-\\udfff"+Ae+"\\ufe0e\\ufe0f]"),So=/[a-z][A-Z]|[A-Z]{2}[a-z]|[0-9][a-zA-Z]|[a-zA-Z][0-9]|[^a-zA-Z0-9 ]/,Pa=["Array","Buffer","DataView","Date","Error","Float32Array","Float64Array","Function","Int8Array","Int16Array","Int32Array","Map","Math","Object","Promise","RegExp","Set","String","Symbol","TypeError","Uint8Array","Uint8ClampedArray","Uint16Array","Uint32Array","WeakMap","_","clearTimeout","isFinite","parseInt","setTimeout"],qi=-1,ae={};ae[jt]=ae[Gt]=ae[Jt]=ae[ee]=ae[re]=ae[Ee]=ae[je]=ae[sn]=ae[Ze]=true,ae[F]=ae[A]=ae[mt]=ae[O]=ae[Ct]=ae[N]=ae[V]=ae[G]=ae[nt]=ae[st]=ae[U]=ae[ut]=ae[Y]=ae[at]=ae[dt]=false;var Ue={};Ue[F]=Ue[A]=Ue[mt]=Ue[Ct]=Ue[O]=Ue[N]=Ue[jt]=Ue[Gt]=Ue[Jt]=Ue[ee]=Ue[re]=Ue[nt]=Ue[st]=Ue[U]=Ue[ut]=Ue[Y]=Ue[at]=Ue[pt]=Ue[Ee]=Ue[je]=Ue[sn]=Ue[Ze]=true,Ue[V]=Ue[G]=Ue[dt]=false;var Yr={"\\":"\\","'":"'","\n":"n","\r":"r","\u2028":"u2028","\u2029":"u2029"},li=parseFloat,Yi=parseInt,xl=typeof n.g=="object"&&n.g&&n.g.Object===Object&&n.g,El=typeof self=="object"&&self&&self.Object===Object&&self,on=xl||El||Function("return this")(),xa=e&&!e.nodeType&&e,tr=xa&&t&&!t.nodeType&&t,Ea=tr&&tr.exports===xa,ci=Ea&&xl.process,Kn=(function(){try{return tr&&tr.require&&tr.require("util").types||ci&&ci.binding&&ci.binding("util")}catch(ht){}})(),Ai=Kn&&Kn.isArrayBuffer,er=Kn&&Kn.isDate,ys=Kn&&Kn.isMap,_a=Kn&&Kn.isRegExp,zo=Kn&&Kn.isSet,Cr=Kn&&Kn.isTypedArray;function nr(ht,At,Dt){switch(Dt.length){case 0:return ht.call(At);case 1:return ht.call(At,Dt[0]);case 2:return ht.call(At,Dt[0],Dt[1]);case 3:return ht.call(At,Dt[0],Dt[1],Dt[2])}return ht.apply(At,Dt)}function Kt(ht,At,Dt,Ht){for(var xe=-1,Ne=ht==null?0:ht.length;++xe<Ne;){var En=ht[xe];At(Ht,En,Dt(En),ht);}return Ht}function Wt(ht,At){for(var Dt=-1,Ht=ht==null?0:ht.length;++Dt<Ht&&At(ht[Dt],Dt,ht)!==false;);return ht}function Tt(ht,At){for(var Dt=ht==null?0:ht.length;Dt--&&At(ht[Dt],Dt,ht)!==false;);return ht}function kt(ht,At){for(var Dt=-1,Ht=ht==null?0:ht.length;++Dt<Ht;)if(!At(ht[Dt],Dt,ht))return false;return true}function xt(ht,At){for(var Dt=-1,Ht=ht==null?0:ht.length,xe=0,Ne=[];++Dt<Ht;){var En=ht[Dt];At(En,Dt,ht)&&(Ne[xe++]=En);}return Ne}function jc(ht,At){return !(ht==null||!ht.length)&&Dr(ht,At,0)>-1}function Vc(ht,At,Dt){for(var Ht=-1,xe=ht==null?0:ht.length;++Ht<xe;)if(Dt(At,ht[Ht]))return true;return false}function We(ht,At){for(var Dt=-1,Ht=ht==null?0:ht.length,xe=Array(Ht);++Dt<Ht;)xe[Dt]=At(ht[Dt],Dt,ht);return xe}function Ho(ht,At){for(var Dt=-1,Ht=At.length,xe=ht.length;++Dt<Ht;)ht[xe+Dt]=At[Dt];return ht}function _l(ht,At,Dt,Ht){var xe=-1,Ne=ht==null?0:ht.length;for(Ht&&Ne&&(Dt=ht[++xe]);++xe<Ne;)Dt=At(Dt,ht[xe],xe,ht);return Dt}function Uf(ht,At,Dt,Ht){var xe=ht==null?0:ht.length;for(Ht&&xe&&(Dt=ht[--xe]);xe--;)Dt=At(Dt,ht[xe],xe,ht);return Dt}function zc(ht,At){for(var Dt=-1,Ht=ht==null?0:ht.length;++Dt<Ht;)if(At(ht[Dt],Dt,ht))return true;return false}var Vy=bs("length");function $f(ht,At,Dt){var Ht;return Dt(ht,(function(xe,Ne,En){if(At(xe,Ne,En))return Ht=Ne,false})),Ht}function Hc(ht,At,Dt,Ht){for(var xe=ht.length,Ne=Dt+(Ht?1:-1);Ht?Ne--:++Ne<xe;)if(At(ht[Ne],Ne,ht))return Ne;return -1}function Dr(ht,At,Dt){return At==At?(function(Ht,xe,Ne){for(var En=Ne-1,Oi=Ht.length;++En<Oi;)if(Ht[En]===xe)return En;return -1})(ht,At,Dt):Hc(ht,ui,Dt)}function te(ht,At,Dt,Ht){for(var xe=Dt-1,Ne=ht.length;++xe<Ne;)if(Ht(ht[xe],At))return xe;return -1}function ui(ht){return ht!=ht}function Dn(ht,At){var Dt=ht==null?0:ht.length;return Dt?xd(ht,At)/Dt:x}function bs(ht){return function(At){return At==null?i:At[ht]}}function Sd(ht){return function(At){return ht==null?i:ht[At]}}function Pd(ht,At,Dt,Ht,xe){return xe(ht,(function(Ne,En,Oi){Dt=Ht?(Ht=false,Ne):At(Dt,Ne,En,Oi);})),Dt}function xd(ht,At){for(var Dt,Ht=-1,xe=ht.length;++Ht<xe;){var Ne=At(ht[Ht]);Ne!==i&&(Dt=Dt===i?Ne:Dt+Ne);}return Dt}function Ed(ht,At){for(var Dt=-1,Ht=Array(ht);++Dt<ht;)Ht[Dt]=At(Dt);return Ht}function _d(ht){return ht&&ht.slice(0,zf(ht)+1).replace(wi,"")}function zr(ht){return function(At){return ht(At)}}function Wc(ht,At){return We(At,(function(Dt){return ht[Dt]}))}function Ta(ht,At){return ht.has(At)}function vs(ht,At){for(var Dt=-1,Ht=ht.length;++Dt<Ht&&Dr(At,ht[Dt],0)>-1;);return Dt}function Td(ht,At){for(var Dt=ht.length;Dt--&&Dr(At,ht[Dt],0)>-1;);return Dt}function Gf(ht,At){for(var Dt=ht.length,Ht=0;Dt--;)ht[Dt]===At&&++Ht;return Ht}var zy=Sd({\u00C0:"A",\u00C1:"A",\u00C2:"A",\u00C3:"A",\u00C4:"A",\u00C5:"A",\u00E0:"a",\u00E1:"a",\u00E2:"a",\u00E3:"a",\u00E4:"a",\u00E5:"a",\u00C7:"C",\u00E7:"c",\u00D0:"D",\u00F0:"d",\u00C8:"E",\u00C9:"E",\u00CA:"E",\u00CB:"E",\u00E8:"e",\u00E9:"e",\u00EA:"e",\u00EB:"e",\u00CC:"I",\u00CD:"I",\u00CE:"I",\u00CF:"I",\u00EC:"i",\u00ED:"i",\u00EE:"i",\u00EF:"i",\u00D1:"N",\u00F1:"n",\u00D2:"O",\u00D3:"O",\u00D4:"O",\u00D5:"O",\u00D6:"O",\u00D8:"O",\u00F2:"o",\u00F3:"o",\u00F4:"o",\u00F5:"o",\u00F6:"o",\u00F8:"o",\u00D9:"U",\u00DA:"U",\u00DB:"U",\u00DC:"U",\u00F9:"u",\u00FA:"u",\u00FB:"u",\u00FC:"u",\u00DD:"Y",\u00FD:"y",\u00FF:"y",\u00C6:"Ae",\u00E6:"ae",\u00DE:"Th",\u00FE:"th",\u00DF:"ss",\u0100:"A",\u0102:"A",\u0104:"A",\u0101:"a",\u0103:"a",\u0105:"a",\u0106:"C",\u0108:"C",\u010A:"C",\u010C:"C",\u0107:"c",\u0109:"c",\u010B:"c",\u010D:"c",\u010E:"D",\u0110:"D",\u010F:"d",\u0111:"d",\u0112:"E",\u0114:"E",\u0116:"E",\u0118:"E",\u011A:"E",\u0113:"e",\u0115:"e",\u0117:"e",\u0119:"e",\u011B:"e",\u011C:"G",\u011E:"G",\u0120:"G",\u0122:"G",\u011D:"g",\u011F:"g",\u0121:"g",\u0123:"g",\u0124:"H",\u0126:"H",\u0125:"h",\u0127:"h",\u0128:"I",\u012A:"I",\u012C:"I",\u012E:"I",\u0130:"I",\u0129:"i",\u012B:"i",\u012D:"i",\u012F:"i",\u0131:"i",\u0134:"J",\u0135:"j",\u0136:"K",\u0137:"k",\u0138:"k",\u0139:"L",\u013B:"L",\u013D:"L",\u013F:"L",\u0141:"L",\u013A:"l",\u013C:"l",\u013E:"l",\u0140:"l",\u0142:"l",\u0143:"N",\u0145:"N",\u0147:"N",\u014A:"N",\u0144:"n",\u0146:"n",\u0148:"n",\u014B:"n",\u014C:"O",\u014E:"O",\u0150:"O",\u014D:"o",\u014F:"o",\u0151:"o",\u0154:"R",\u0156:"R",\u0158:"R",\u0155:"r",\u0157:"r",\u0159:"r",\u015A:"S",\u015C:"S",\u015E:"S",\u0160:"S",\u015B:"s",\u015D:"s",\u015F:"s",\u0161:"s",\u0162:"T",\u0164:"T",\u0166:"T",\u0163:"t",\u0165:"t",\u0167:"t",\u0168:"U",\u016A:"U",\u016C:"U",\u016E:"U",\u0170:"U",\u0172:"U",\u0169:"u",\u016B:"u",\u016D:"u",\u016F:"u",\u0171:"u",\u0173:"u",\u0174:"W",\u0175:"w",\u0176:"Y",\u0177:"y",\u0178:"Y",\u0179:"Z",\u017B:"Z",\u017D:"Z",\u017A:"z",\u017C:"z",\u017E:"z",\u0132:"IJ",\u0133:"ij",\u0152:"Oe",\u0153:"oe",\u0149:"'n",\u017F:"s"}),jf=Sd({"&":"&amp;","<":"&lt;",">":"&gt;",'"':"&quot;","'":"&#39;"});function wd(ht){return "\\"+Yr[ht]}function Nn(ht){return gs.test(ht)}function Tl(ht){var At=-1,Dt=Array(ht.size);return ht.forEach((function(Ht,xe){Dt[++At]=[xe,Ht];})),Dt}function Id(ht,At){return function(Dt){return ht(At(Dt))}}function Wo(ht,At){for(var Dt=-1,Ht=ht.length,xe=0,Ne=[];++Dt<Ht;){var En=ht[Dt];En!==At&&En!==c||(ht[Dt]=c,Ne[xe++]=Dt);}return Ne}function qc(ht){var At=-1,Dt=Array(ht.size);return ht.forEach((function(Ht){Dt[++At]=Ht;})),Dt}function Vf(ht){var At=-1,Dt=Array(ht.size);return ht.forEach((function(Ht){Dt[++At]=[Ht,Ht];})),Dt}function qo(ht){return Nn(ht)?(function(At){for(var Dt=Je.lastIndex=0;Je.test(At);)++Dt;return Dt})(ht):Vy(ht)}function Qr(ht){return Nn(ht)?(function(At){return At.match(Je)||[]})(ht):(function(At){return At.split("")})(ht)}function zf(ht){for(var At=ht.length;At--&&vo.test(ht.charAt(At)););return At}var Hf=Sd({"&amp;":"&","&lt;":"<","&gt;":">","&quot;":'"',"&#39;":"'"}),Yc=(function ht(At){var Dt,Ht=(At=At==null?on:Yc.defaults(on.Object(),At,Yc.pick(on,Pa))).Array,xe=At.Date,Ne=At.Error,En=At.Function,Oi=At.Math,mn=At.Object,Cs=At.RegExp,Wf=At.String,Kr=At.TypeError,wl=Ht.prototype,kd=En.prototype,wa=mn.prototype,Il=At["__core-js_shared__"],Ss=kd.toString,an=wa.hasOwnProperty,qf=0,Yf=(Dt=/[^.]+$/.exec(Il&&Il.keys&&Il.keys.IE_PROTO||""))?"Symbol(src)_1."+Dt:"",Ia=wa.toString,Dd=Ss.call(mn),Hy=on._,Qf=Cs("^"+Ss.call(an).replace(Jn,"\\$&").replace(/hasOwnProperty|(function).*?(?=\\\()| for .+?(?=\\\])/g,"$1.*?")+"$"),Ps=Ea?At.Buffer:i,di=At.Symbol,kl=At.Uint8Array,Ad=Ps?Ps.allocUnsafe:i,un=Id(mn.getPrototypeOf,mn),xs=mn.create,Es=wa.propertyIsEnumerable,Qc=wl.splice,Od=di?di.isConcatSpreadable:i,ka=di?di.iterator:i,Da=di?di.toStringTag:i,Kc=(function(){try{var u=La(mn,"defineProperty");return u({},"",{}),u}catch(g){}})(),Kf=At.clearTimeout!==on.clearTimeout&&At.clearTimeout,Rd=xe&&xe.now!==on.Date.now&&xe.now,Wy=At.setTimeout!==on.setTimeout&&At.setTimeout,Dl=Oi.ceil,Xc=Oi.floor,Zc=mn.getOwnPropertySymbols,Fd=Ps?Ps.isBuffer:i,Xf=At.isFinite,Md=wl.join,Sr=Id(mn.keys,mn),Xn=Oi.max,Ar=Oi.min,Nd=xe.now,Ld=At.parseInt,Al=Oi.random,qy=wl.reverse,Jc=La(At,"DataView"),Ol=La(At,"Map"),_s=La(At,"Promise"),Ts=La(At,"Set"),Aa=La(At,"WeakMap"),Yo=La(mn,"create"),Qo=Aa&&new Aa,Ri={},Zf=ra(Jc),Yy=ra(Ol),Jf=ra(_s),Qy=ra(Ts),Ko=ra(Aa),Rl=di?di.prototype:i,ws=Rl?Rl.valueOf:i,tu=Rl?Rl.toString:i;function L(u){if(zn(u)&&!ge(u)&&!(u instanceof Re)){if(u instanceof Xr)return u;if(an.call(u,"__wrapped__"))return Io(u)}return new Xr(u)}var Oa=(function(){function u(){}return function(g){if(!Bn(g))return {};if(xs)return xs(g);u.prototype=g;var S=new u;return u.prototype=i,S}})();function Fl(){}function Xr(u,g){this.__wrapped__=u,this.__actions__=[],this.__chain__=!!g,this.__index__=0,this.__values__=i;}function Re(u){this.__wrapped__=u,this.__actions__=[],this.__dir__=1,this.__filtered__=false,this.__iteratees__=[],this.__takeCount__=T,this.__views__=[];}function Ra(u){var g=-1,S=u==null?0:u.length;for(this.clear();++g<S;){var k=u[g];this.set(k[0],k[1]);}}function Qi(u){var g=-1,S=u==null?0:u.length;for(this.clear();++g<S;){var k=u[g];this.set(k[0],k[1]);}}function Ki(u){var g=-1,S=u==null?0:u.length;for(this.clear();++g<S;){var k=u[g];this.set(k[0],k[1]);}}function Po(u){var g=-1,S=u==null?0:u.length;for(this.__data__=new Ki;++g<S;)this.add(u[g]);}function Hr(u){var g=this.__data__=new Qi(u);this.size=g.size;}function eu(u,g){var S=ge(u),k=!S&&mi(u),R=!S&&!k&&Do(u),$=!S&&!k&&!R&&qs(u),q=S||k||R||$,et=q?Ed(u.length,Wf):[],lt=et.length;for(var Et in u)!g&&!an.call(u,Et)||q&&(Et=="length"||R&&(Et=="offset"||Et=="parent")||$&&(Et=="buffer"||Et=="byteLength"||Et=="byteOffset")||Br(Et,lt))||et.push(Et);return et}function Bd(u){var g=u.length;return g?u[Qd(0,g-1)]:i}function Ml(u,g){return xu(mr(u),xo(g,0,u.length))}function th(u){return xu(mr(u))}function Ud(u,g,S){(S!==i&&!Rr(u[g],S)||S===i&&!(g in u))&&Xi(u,g,S);}function Nl(u,g,S){var k=u[g];an.call(u,g)&&Rr(k,S)&&(S!==i||g in u)||Xi(u,g,S);}function Ll(u,g){for(var S=u.length;S--;)if(Rr(u[S][0],g))return S;return -1}function Is(u,g,S,k){return Xo(u,(function(R,$,q){g(k,R,S(R),q);})),k}function nu(u,g){return u&&fi(g,Zn(g),u)}function Xi(u,g,S){g=="__proto__"&&Kc?Kc(u,g,{configurable:true,enumerable:true,value:S,writable:true}):u[g]=S;}function Bl(u,g){for(var S=-1,k=g.length,R=Ht(k),$=u==null;++S<k;)R[S]=$?i:Du(u,g[S]);return R}function xo(u,g,S){return u==u&&(S!==i&&(u=u<=S?u:S),g!==i&&(u=u>=g?u:g)),u}function pi(u,g,S,k,R,$){var q,et=1&g,lt=2&g,Et=4&g;if(S&&(q=R?S(u,k,R,$):S(u)),q!==i)return q;if(!Bn(u))return u;var wt=ge(u);if(wt){if(q=(function(Ft){var Ut=Ft.length,ie=new Ft.constructor(Ut);return Ut&&typeof Ft[0]=="string"&&an.call(Ft,"index")&&(ie.index=Ft.index,ie.input=Ft.input),ie})(u),!et)return mr(u,q)}else {var Mt=Er(u),Yt=Mt==G||Mt==X;if(Do(u))return mh(u,et);if(Mt==U||Mt==F||Yt&&!R){if(q=lt||Yt?{}:Ba(u),!et)return lt?(function(Ft,Ut){return fi(Ft,op(Ft),Ut)})(u,(function(Ft,Ut){return Ft&&fi(Ut,Wr(Ut),Ft)})(q,u)):(function(Ft,Ut){return fi(Ft,Gs(Ft),Ut)})(u,nu(q,u))}else {if(!Ue[Mt])return R?u:{};q=(function(Ft,Ut,ie){var Xt,he=Ft.constructor;switch(Ut){case mt:return du(Ft);case O:case N:return new he(+Ft);case Ct:return (function(Pe,Ge){var le=Ge?du(Pe.buffer):Pe.buffer;return new Pe.constructor(le,Pe.byteOffset,Pe.byteLength)})(Ft,ie);case jt:case Gt:case Jt:case ee:case re:case Ee:case je:case sn:case Ze:return ta(Ft,ie);case nt:return new he;case st:case at:return new he(Ft);case ut:return (function(Pe){var Ge=new Pe.constructor(Pe.source,it.exec(Pe));return Ge.lastIndex=Pe.lastIndex,Ge})(Ft);case Y:return new he;case pt:return Xt=Ft,ws?mn(ws.call(Xt)):{}}})(u,Mt,et);}}$||($=new Hr);var Qt=$.get(u);if(Qt)return Qt;$.set(u,q),Sp(u)?u.forEach((function(Ft){q.add(pi(Ft,g,S,Ft,u,$));})):Mh(u)&&u.forEach((function(Ft,Ut){q.set(Ut,pi(Ft,g,S,Ut,u,$));}));var oe=wt?i:(Et?lt?bu:yu:lt?Wr:Zn)(u);return Wt(oe||u,(function(Ft,Ut){oe&&(Ft=u[Ut=Ft]),Nl(q,Ut,pi(Ft,g,S,Ut,u,$));})),q}function eh(u,g,S){var k=S.length;if(u==null)return !k;for(u=mn(u);k--;){var R=S[k],$=g[R],q=u[R];if(q===i&&!(R in u)||!$(q))return false}return true}function $d(u,g,S){if(typeof u!="function")throw new Kr(o);return ro((function(){u.apply(i,S);}),g)}function Fa(u,g,S,k){var R=-1,$=jc,q=true,et=u.length,lt=[],Et=g.length;if(!et)return lt;S&&(g=We(g,zr(S))),k?($=Vc,q=false):g.length>=200&&($=Ta,q=false,g=new Po(g));t:for(;++R<et;){var wt=u[R],Mt=S==null?wt:S(wt);if(wt=k||wt!==0?wt:0,q&&Mt==Mt){for(var Yt=Et;Yt--;)if(g[Yt]===Mt)continue t;lt.push(wt);}else $(g,Mt,k)||lt.push(wt);}return lt}L.templateSettings={escape:De,evaluate:vr,interpolate:Ve,variable:"",imports:{_:L}},L.prototype=Fl.prototype,L.prototype.constructor=L,Xr.prototype=Oa(Fl.prototype),Xr.prototype.constructor=Xr,Re.prototype=Oa(Fl.prototype),Re.prototype.constructor=Re,Ra.prototype.clear=function(){this.__data__=Yo?Yo(null):{},this.size=0;},Ra.prototype.delete=function(u){var g=this.has(u)&&delete this.__data__[u];return this.size-=g?1:0,g},Ra.prototype.get=function(u){var g=this.__data__;if(Yo){var S=g[u];return S===s?i:S}return an.call(g,u)?g[u]:i},Ra.prototype.has=function(u){var g=this.__data__;return Yo?g[u]!==i:an.call(g,u)},Ra.prototype.set=function(u,g){var S=this.__data__;return this.size+=this.has(u)?0:1,S[u]=Yo&&g===i?s:g,this},Qi.prototype.clear=function(){this.__data__=[],this.size=0;},Qi.prototype.delete=function(u){var g=this.__data__,S=Ll(g,u);return !(S<0||(S==g.length-1?g.pop():Qc.call(g,S,1),--this.size,0))},Qi.prototype.get=function(u){var g=this.__data__,S=Ll(g,u);return S<0?i:g[S][1]},Qi.prototype.has=function(u){return Ll(this.__data__,u)>-1},Qi.prototype.set=function(u,g){var S=this.__data__,k=Ll(S,u);return k<0?(++this.size,S.push([u,g])):S[k][1]=g,this},Ki.prototype.clear=function(){this.size=0,this.__data__={hash:new Ra,map:new(Ol||Qi),string:new Ra};},Ki.prototype.delete=function(u){var g=ql(this,u).delete(u);return this.size-=g?1:0,g},Ki.prototype.get=function(u){return ql(this,u).get(u)},Ki.prototype.has=function(u){return ql(this,u).has(u)},Ki.prototype.set=function(u,g){var S=ql(this,u),k=S.size;return S.set(u,g),this.size+=S.size==k?0:1,this},Po.prototype.add=Po.prototype.push=function(u){return this.__data__.set(u,s),this},Po.prototype.has=function(u){return this.__data__.has(u)},Hr.prototype.clear=function(){this.__data__=new Qi,this.size=0;},Hr.prototype.delete=function(u){var g=this.__data__,S=g.delete(u);return this.size=g.size,S},Hr.prototype.get=function(u){return this.__data__.get(u)},Hr.prototype.has=function(u){return this.__data__.has(u)},Hr.prototype.set=function(u,g){var S=this.__data__;if(S instanceof Qi){var k=S.__data__;if(!Ol||k.length<199)return k.push([u,g]),this.size=++S.size,this;S=this.__data__=new Ki(k);}return S.set(u,g),this.size=S.size,this};var Xo=yh(Fi),nh=yh(Zi,true);function rh(u,g){var S=true;return Xo(u,(function(k,R,$){return S=!!g(k,R,$)})),S}function ks(u,g,S){for(var k=-1,R=u.length;++k<R;){var $=u[k],q=g($);if(q!=null&&(et===i?q==q&&!Fr(q):S(q,et)))var et=q,lt=$;}return lt}function fr(u,g){var S=[];return Xo(u,(function(k,R,$){g(k,R,$)&&S.push(k);})),S}function hr(u,g,S,k,R){var $=-1,q=u.length;for(S||(S=vh),R||(R=[]);++$<q;){var et=u[$];g>0&&S(et)?g>1?hr(et,g-1,S,k,R):Ho(R,et):k||(R[R.length]=et);}return R}var ru=fu(),Gd=fu(true);function Fi(u,g){return u&&ru(u,g,Zn)}function Zi(u,g){return u&&Gd(u,g,Zn)}function Ds(u,g){return xt(g,(function(S){return $r(u[S])}))}function Mi(u,g){for(var S=0,k=(g=Xe(g,u)).length;u!=null&&S<k;)u=u[Ln(g[S++])];return S&&S==k?u:i}function Ul(u,g,S){var k=g(u);return ge(u)?k:Ho(k,S(u))}function Pr(u){return u==null?u===i?"[object Undefined]":"[object Null]":Da&&Da in mn(u)?(function(g){var S=an.call(g,Da),k=g[Da];try{g[Da]=i;var R=!0;}catch(q){}var $=Ia.call(g);return R&&(S?g[Da]=k:delete g[Da]),$})(u):(function(g){return Ia.call(g)})(u)}function iu(u,g){return u>g}function $l(u,g){return u!=null&&an.call(u,g)}function ih(u,g){return u!=null&&g in mn(u)}function Gl(u,g,S){for(var k=S?Vc:jc,R=u[0].length,$=u.length,q=$,et=Ht($),lt=1/0,Et=[];q--;){var wt=u[q];q&&g&&(wt=We(wt,zr(g))),lt=Ar(wt.length,lt),et[q]=!S&&(g||R>=120&&wt.length>=120)?new Po(q&&wt):i;}wt=u[0];var Mt=-1,Yt=et[0];t:for(;++Mt<R&&Et.length<lt;){var Qt=wt[Mt],oe=g?g(Qt):Qt;if(Qt=S||Qt!==0?Qt:0,!(Yt?Ta(Yt,oe):k(Et,oe,S))){for(q=$;--q;){var Ft=et[q];if(!(Ft?Ta(Ft,oe):k(u[q],oe,S)))continue t}Yt&&Yt.push(oe),Et.push(Qt);}}return Et}function As(u,g,S){var k=(u=Ch(u,g=Xe(g,u)))==null?u:u[Ln(hi(g))];return k==null?i:nr(k,u,S)}function Eo(u){return zn(u)&&Pr(u)==F}function jl(u,g,S,k,R){return u===g||(u==null||g==null||!zn(u)&&!zn(g)?u!=u&&g!=g:(function($,q,et,lt,Et,wt){var Mt=ge($),Yt=ge(q),Qt=Mt?A:Er($),oe=Yt?A:Er(q),Ft=(Qt=Qt==F?U:Qt)==U,Ut=(oe=oe==F?U:oe)==U,ie=Qt==oe;if(ie&&Do($)){if(!Do(q))return false;Mt=true,Ft=false;}if(ie&&!Ft)return wt||(wt=new Hr),Mt||qs($)?ip($,q,et,lt,Et,wt):(function(le,ye,Tr,Bi,sa,wr,Wa){switch(Tr){case Ct:if(le.byteLength!=ye.byteLength||le.byteOffset!=ye.byteOffset)return false;le=le.buffer,ye=ye.buffer;case mt:return !(le.byteLength!=ye.byteLength||!wr(new kl(le),new kl(ye)));case O:case N:case st:return Rr(+le,+ye);case V:return le.name==ye.name&&le.message==ye.message;case ut:case at:return le==ye+"";case nt:var Qs=Tl;case Y:var Ip=1&Bi;if(Qs||(Qs=qc),le.size!=ye.size&&!Ip)return false;var rc=Wa.get(le);if(rc)return rc==ye;Bi|=2,Wa.set(le,ye);var qa=ip(Qs(le),Qs(ye),Bi,sa,wr,Wa);return Wa.delete(le),qa;case pt:if(ws)return ws.call(le)==ws.call(ye)}return false})($,q,Qt,et,lt,Et,wt);if(!(1&et)){var Xt=Ft&&an.call($,"__wrapped__"),he=Ut&&an.call(q,"__wrapped__");if(Xt||he){var Pe=Xt?$.value():$,Ge=he?q.value():q;return wt||(wt=new Hr),Et(Pe,Ge,et,lt,wt)}}return !!ie&&(wt||(wt=new Hr),(function(le,ye,Tr,Bi,sa,wr){var Wa=1&Tr,Qs=yu(le),Ip=Qs.length;if(Ip!=yu(ye).length&&!Wa)return false;for(var rc=Ip;rc--;){var qa=Qs[rc];if(!(Wa?qa in ye:an.call(ye,qa)))return false}var H1=wr.get(le),W1=wr.get(ye);if(H1&&W1)return H1==ye&&W1==le;var qh=true;wr.set(le,ye),wr.set(ye,le);for(var pb=Wa;++rc<Ip;){var Yh=le[qa=Qs[rc]],Qh=ye[qa];if(Bi)var q1=Wa?Bi(Qh,Yh,qa,ye,le,wr):Bi(Yh,Qh,qa,le,ye,wr);if(!(q1===i?Yh===Qh||sa(Yh,Qh,Tr,Bi,wr):q1)){qh=false;break}pb||(pb=qa=="constructor");}if(qh&&!pb){var Kh=le.constructor,Xh=ye.constructor;Kh==Xh||!("constructor"in le)||!("constructor"in ye)||typeof Kh=="function"&&Kh instanceof Kh&&typeof Xh=="function"&&Xh instanceof Xh||(qh=false);}return wr.delete(le),wr.delete(ye),qh})($,q,et,lt,Et,wt))})(u,g,S,k,jl,R))}function jd(u,g,S,k){var R=S.length,$=R,q=!k;if(u==null)return !$;for(u=mn(u);R--;){var et=S[R];if(q&&et[2]?et[1]!==u[et[0]]:!(et[0]in u))return false}for(;++R<$;){var lt=(et=S[R])[0],Et=u[lt],wt=et[1];if(q&&et[2]){if(Et===i&&!(lt in u))return false}else {var Mt=new Hr;if(k)var Yt=k(Et,wt,lt,u,g,Mt);if(!(Yt===i?jl(wt,Et,3,k,Mt):Yt))return false}}return true}function Os(u){return !(!Bn(u)||(g=u,Yf&&Yf in g))&&($r(u)?Qf:Lt).test(ra(u));var g;}function Vd(u){return typeof u=="function"?u:u==null?b:typeof u=="object"?ge(u)?Wd(u[0],u[1]):Hd(u):J(u)}function ou(u){if(!eo(u))return Sr(u);var g=[];for(var S in mn(u))an.call(u,S)&&S!="constructor"&&g.push(S);return g}function zd(u,g){return u<g}function oh(u,g){var S=-1,k=Ur(u)?Ht(u.length):[];return Xo(u,(function(R,$,q){k[++S]=g(R,$,q);})),k}function Hd(u){var g=Na(u);return g.length==1&&g[0][2]?no(g[0][0],g[0][1]):function(S){return S===u||jd(S,u,g)}}function Wd(u,g){return Ua(u)&&Yl(g)?no(Ln(u),g):function(S){var k=Du(S,u);return k===i&&k===g?Au(S,u):jl(g,k,3)}}function Rs(u,g,S,k,R){u!==g&&ru(g,(function($,q){if(R||(R=new Hr),Bn($))(function(lt,Et,wt,Mt,Yt,Qt,oe){var Ft=Ql(lt,wt),Ut=Ql(Et,wt),ie=oe.get(Ut);if(ie)Ud(lt,wt,ie);else {var Xt=Qt?Qt(Ft,Ut,wt+"",lt,Et,oe):i,he=Xt===i;if(he){var Pe=ge(Ut),Ge=!Pe&&Do(Ut),le=!Pe&&!Ge&&qs(Ut);Xt=Ut,Pe||Ge||le?ge(Ft)?Xt=Ft:Vn(Ft)?Xt=mr(Ft):Ge?(he=false,Xt=mh(Ut,true)):le?(he=false,Xt=ta(Ut,true)):Xt=[]:nc(Ut)||mi(Ut)?(Xt=Ft,mi(Ft)?Xt=gi(Ft):Bn(Ft)&&!$r(Ft)||(Xt=Ba(Ut))):he=false;}he&&(oe.set(Ut,Xt),Yt(Xt,Ut,Mt,Qt,oe),oe.delete(Ut)),Ud(lt,wt,Xt);}})(u,g,q,S,Rs,k,R);else {var et=k?k(Ql(u,q),$,q+"",u,g,R):i;et===i&&(et=$),Ud(u,q,et);}}),Wr);}function Vl(u,g){var S=u.length;if(S)return Br(g+=g<0?S:0,S)?u[g]:i}function qd(u,g,S){g=g.length?We(g,(function($){return ge($)?function(q){return Mi(q,$.length===1?$[0]:$)}:$})):[b];var k=-1;g=We(g,zr(ue()));var R=oh(u,(function($,q,et){var lt=We(g,(function(Et){return Et($)}));return {criteria:lt,index:++k,value:$}}));return (function($,q){var et=$.length;for($.sort((function(lt,Et){return (function(wt,Mt,Yt){for(var Qt=-1,oe=wt.criteria,Ft=Mt.criteria,Ut=oe.length,ie=Yt.length;++Qt<Ut;){var Xt=gh(oe[Qt],Ft[Qt]);if(Xt)return Qt>=ie?Xt:Xt*(Yt[Qt]=="desc"?-1:1)}return wt.index-Mt.index})(lt,Et,S)}));et--;)$[et]=$[et].value;return $})(R)}function Yd(u,g,S){for(var k=-1,R=g.length,$={};++k<R;){var q=g[k],et=Mi(u,q);S(et,q)&&Fs($,Xe(q,u),et);}return $}function au(u,g,S,k){var R=k?te:Dr,$=-1,q=g.length,et=u;for(u===g&&(g=mr(g)),S&&(et=We(u,zr(S)));++$<q;)for(var lt=0,Et=g[$],wt=S?S(Et):Et;(lt=R(et,wt,lt,k))>-1;)et!==u&&Qc.call(et,lt,1),Qc.call(u,lt,1);return u}function su(u,g){for(var S=u?g.length:0,k=S-1;S--;){var R=g[S];if(S==k||R!==$){var $=R;Br(R)?Qc.call(u,R,1):Jd(u,R);}}return u}function Qd(u,g){return u+Xc(Al()*(g-u+1))}function lu(u,g){var S="";if(!u||g<1||g>P)return S;do g%2&&(S+=u),(g=Xc(g/2))&&(u+=u);while(g);return S}function Ie(u,g){return io($a(u,g,b),u+"")}function ah(u){return Bd(Oo(u))}function Ky(u,g){var S=Oo(u);return xu(S,xo(g,0,S.length))}function Fs(u,g,S,k){if(!Bn(u))return u;for(var R=-1,$=(g=Xe(g,u)).length,q=$-1,et=u;et!=null&&++R<$;){var lt=Ln(g[R]),Et=S;if(lt==="__proto__"||lt==="constructor"||lt==="prototype")return u;if(R!=q){var wt=et[lt];(Et=k?k(wt,lt,et):i)===i&&(Et=Bn(wt)?wt:Br(g[R+1])?[]:{});}Nl(et,lt,Et),et=et[lt];}return u}var Kd=Qo?function(u,g){return Qo.set(u,g),u}:b,sh=Kc?function(u,g){return Kc(u,"toString",{configurable:true,enumerable:false,value:d(g),writable:true})}:b;function lh(u){return xu(Oo(u))}function Zr(u,g,S){var k=-1,R=u.length;g<0&&(g=-g>R?0:R+g),(S=S>R?R:S)<0&&(S+=R),R=g>S?0:S-g>>>0,g>>>=0;for(var $=Ht(R);++k<R;)$[k]=u[k+g];return $}function Xd(u,g){var S;return Xo(u,(function(k,R,$){return !(S=g(k,R,$))})),!!S}function cu(u,g,S){var k=0,R=u==null?k:u.length;if(typeof g=="number"&&g==g&&R<=2147483647){for(;k<R;){var $=k+R>>>1,q=u[$];q!==null&&!Fr(q)&&(S?q<=g:q<g)?k=$+1:R=$;}return R}return Zd(u,g,b,S)}function Zd(u,g,S,k){var R=0,$=u==null?0:u.length;if($===0)return 0;for(var q=(g=S(g))!=g,et=g===null,lt=Fr(g),Et=g===i;R<$;){var wt=Xc((R+$)/2),Mt=S(u[wt]),Yt=Mt!==i,Qt=Mt===null,oe=Mt==Mt,Ft=Fr(Mt);if(q)var Ut=k||oe;else Ut=Et?oe&&(k||Yt):et?oe&&Yt&&(k||!Qt):lt?oe&&Yt&&!Qt&&(k||!Ft):!Qt&&!Ft&&(k?Mt<=g:Mt<g);Ut?R=wt+1:$=wt;}return Ar($,4294967294)}function ch(u,g){for(var S=-1,k=u.length,R=0,$=[];++S<k;){var q=u[S],et=g?g(q):q;if(!S||!Rr(et,lt)){var lt=et;$[R++]=q===0?0:q;}}return $}function uh(u){return typeof u=="number"?u:Fr(u)?x:+u}function Jr(u){if(typeof u=="string")return u;if(ge(u))return We(u,Jr)+"";if(Fr(u))return tu?tu.call(u):"";var g=u+"";return g=="0"&&1/u==-1/0?"-0":g}function Zo(u,g,S){var k=-1,R=jc,$=u.length,q=true,et=[],lt=et;if(S)q=false,R=Vc;else if($>=200){var Et=g?null:Xy(u);if(Et)return qc(Et);q=false,R=Ta,lt=new Po;}else lt=g?[]:et;t:for(;++k<$;){var wt=u[k],Mt=g?g(wt):wt;if(wt=S||wt!==0?wt:0,q&&Mt==Mt){for(var Yt=lt.length;Yt--;)if(lt[Yt]===Mt)continue t;g&&lt.push(Mt),et.push(wt);}else R(lt,Mt,S)||(lt!==et&&lt.push(Mt),et.push(wt));}return et}function Jd(u,g){return (u=Ch(u,g=Xe(g,u)))==null||delete u[Ln(hi(g))]}function dh(u,g,S,k){return Fs(u,g,S(Mi(u,g)),k)}function Ji(u,g,S,k){for(var R=u.length,$=k?R:-1;(k?$--:++$<R)&&g(u[$],$,u););return S?Zr(u,k?0:$,k?$+1:R):Zr(u,k?$+1:0,k?R:$)}function ph(u,g){var S=u;return S instanceof Re&&(S=S.value()),_l(g,(function(k,R){return R.func.apply(R.thisArg,Ho([k],R.args))}),S)}function uu(u,g,S){var k=u.length;if(k<2)return k?Zo(u[0]):[];for(var R=-1,$=Ht(k);++R<k;)for(var q=u[R],et=-1;++et<k;)et!=R&&($[R]=Fa($[R]||q,u[et],g,S));return Zo(hr($,1),g,S)}function fh(u,g,S){for(var k=-1,R=u.length,$=g.length,q={};++k<R;){var et=k<$?g[k]:i;S(q,u[k],et);}return q}function tp(u){return Vn(u)?u:[]}function zl(u){return typeof u=="function"?u:b}function Xe(u,g){return ge(u)?u:Ua(u,g)?[u]:sp(qe(u))}var hh=Ie;function Jo(u,g,S){var k=u.length;return S=S===i?k:S,!g&&S>=k?u:Zr(u,g,S)}var Ms=Kf||function(u){return on.clearTimeout(u)};function mh(u,g){if(g)return u.slice();var S=u.length,k=Ad?Ad(S):new u.constructor(S);return u.copy(k),k}function du(u){var g=new u.constructor(u.byteLength);return new kl(g).set(new kl(u)),g}function ta(u,g){var S=g?du(u.buffer):u.buffer;return new u.constructor(S,u.byteOffset,u.length)}function gh(u,g){if(u!==g){var S=u!==i,k=u===null,R=u==u,$=Fr(u),q=g!==i,et=g===null,lt=g==g,Et=Fr(g);if(!et&&!Et&&!$&&u>g||$&&q&&lt&&!et&&!Et||k&&q&&lt||!S&&lt||!R)return 1;if(!k&&!$&&!Et&&u<g||Et&&S&&R&&!k&&!$||et&&S&&R||!q&&R||!lt)return -1}return 0}function ti(u,g,S,k){for(var R=-1,$=u.length,q=S.length,et=-1,lt=g.length,Et=Xn($-q,0),wt=Ht(lt+Et),Mt=!k;++et<lt;)wt[et]=g[et];for(;++R<q;)(Mt||R<$)&&(wt[S[R]]=u[R]);for(;Et--;)wt[et++]=u[R++];return wt}function Ns(u,g,S,k){for(var R=-1,$=u.length,q=-1,et=S.length,lt=-1,Et=g.length,wt=Xn($-et,0),Mt=Ht(wt+Et),Yt=!k;++R<wt;)Mt[R]=u[R];for(var Qt=R;++lt<Et;)Mt[Qt+lt]=g[lt];for(;++q<et;)(Yt||R<$)&&(Mt[Qt+S[q]]=u[R++]);return Mt}function mr(u,g){var S=-1,k=u.length;for(g||(g=Ht(k));++S<k;)g[S]=u[S];return g}function fi(u,g,S,k){var R=!S;S||(S={});for(var $=-1,q=g.length;++$<q;){var et=g[$],lt=k?k(S[et],u[et],et,S,u):i;lt===i&&(lt=u[et]),R?Xi(S,et,lt):Nl(S,et,lt);}return S}function pu(u,g){return function(S,k){var R=ge(S)?Kt:Is,$=g?g():{};return R(S,u,ue(k,2),$)}}function Ls(u){return Ie((function(g,S){var k=-1,R=S.length,$=R>1?S[R-1]:i,q=R>2?S[2]:i;for($=u.length>3&&typeof $=="function"?(R--,$):i,q&&_r(S[0],S[1],q)&&($=R<3?i:$,R=1),g=mn(g);++k<R;){var et=S[k];et&&u(g,et,k,$);}return g}))}function yh(u,g){return function(S,k){if(S==null)return S;if(!Ur(S))return u(S,k);for(var R=S.length,$=g?R:-1,q=mn(S);(g?$--:++$<R)&&k(q[$],$,q)!==false;);return S}}function fu(u){return function(g,S,k){for(var R=-1,$=mn(g),q=k(g),et=q.length;et--;){var lt=q[u?et:++R];if(S($[lt],lt,$)===false)break}return g}}function bh(u){return function(g){var S=Nn(g=qe(g))?Qr(g):i,k=S?S[0]:g.charAt(0),R=S?Jo(S,1).join(""):g.slice(1);return k[u]()+R}}function _n(u){return function(g){return _l(f(de(g).replace(hn,"")),u,"")}}function Bs(u){return function(){var g=arguments;switch(g.length){case 0:return new u;case 1:return new u(g[0]);case 2:return new u(g[0],g[1]);case 3:return new u(g[0],g[1],g[2]);case 4:return new u(g[0],g[1],g[2],g[3]);case 5:return new u(g[0],g[1],g[2],g[3],g[4]);case 6:return new u(g[0],g[1],g[2],g[3],g[4],g[5]);case 7:return new u(g[0],g[1],g[2],g[3],g[4],g[5],g[6])}var S=Oa(u.prototype),k=u.apply(S,g);return Bn(k)?k:S}}function ep(u){return function(g,S,k){var R=mn(g);if(!Ur(g)){var $=ue(S,3);g=Zn(g),S=function(et){return $(R[et],et,R)};}var q=u(g,S,k);return q>-1?R[$?g[q]:q]:i}}function Ma(u){return Ni((function(g){var S=g.length,k=S,R=Xr.prototype.thru;for(u&&g.reverse();k--;){var $=g[k];if(typeof $!="function")throw new Kr(o);if(R&&!q&&Cu($)=="wrapper")var q=new Xr([],true);}for(k=q?k:S;++k<S;){var et=Cu($=g[k]),lt=et=="wrapper"?vu($):i;q=lt&&Su(lt[0])&&lt[1]==424&&!lt[4].length&&lt[9]==1?q[Cu(lt[0])].apply(q,lt[3]):$.length==1&&Su($)?q[et]():q.thru($);}return function(){var Et=arguments,wt=Et[0];if(q&&Et.length==1&&ge(wt))return q.plant(wt).value();for(var Mt=0,Yt=S?g[Mt].apply(this,Et):wt;++Mt<S;)Yt=g[Mt].call(this,Yt);return Yt}}))}function Hl(u,g,S,k,R,$,q,et,lt,Et){var wt=g&h,Mt=1&g,Yt=2&g,Qt=24&g,oe=512&g,Ft=Yt?i:Bs(u);return function Ut(){for(var ie=arguments.length,Xt=Ht(ie),he=ie;he--;)Xt[he]=arguments[he];if(Qt)var Pe=ea(Ut),Ge=Gf(Xt,Pe);if(k&&(Xt=ti(Xt,k,R,Qt)),$&&(Xt=Ns(Xt,$,q,Qt)),ie-=Ge,Qt&&ie<Et){var le=Wo(Xt,Pe);return wo(u,g,Hl,Ut.placeholder,S,Xt,le,et,lt,Et-ie)}var ye=Mt?S:this,Tr=Yt?ye[u]:u;return ie=Xt.length,et?Xt=Ga(Xt,et):oe&&ie>1&&Xt.reverse(),wt&&lt<ie&&(Xt.length=lt),this&&this!==on&&this instanceof Ut&&(Tr=Ft||Bs(Tr)),Tr.apply(ye,Xt)}}function np(u,g){return function(S,k){return (function(R,$,q,et){return Fi(R,(function(lt,Et,wt){$(et,q(lt),Et,wt);})),et})(S,u,g(k),{})}}function _o(u,g){return function(S,k){var R;if(S===i&&k===i)return g;if(S!==i&&(R=S),k!==i){if(R===i)return k;typeof S=="string"||typeof k=="string"?(S=Jr(S),k=Jr(k)):(S=uh(S),k=uh(k)),R=u(S,k);}return R}}function hu(u){return Ni((function(g){return g=We(g,zr(ue())),Ie((function(S){var k=this;return u(g,(function(R){return nr(R,k,S)}))}))}))}function To(u,g){var S=(g=g===i?" ":Jr(g)).length;if(S<2)return S?lu(g,u):g;var k=lu(g,Dl(u/qo(g)));return Nn(g)?Jo(Qr(k),0,u).join(""):k.slice(0,u)}function mu(u){return function(g,S,k){return k&&typeof k!="number"&&_r(g,S,k)&&(S=k=i),g=Ao(g),S===i?(S=g,g=0):S=Ao(S),(function(R,$,q,et){for(var lt=-1,Et=Xn(Dl(($-R)/(q||1)),0),wt=Ht(Et);Et--;)wt[et?Et:++lt]=R,R+=q;return wt})(g,S,k=k===i?g<S?1:-1:Ao(k),u)}}function Us(u){return function(g,S){return typeof g=="string"&&typeof S=="string"||(g=ei(g),S=ei(S)),u(g,S)}}function wo(u,g,S,k,R,$,q,et,lt,Et){var wt=8&g;g|=wt?p:64,4&(g&=~(wt?64:p))||(g&=-4);var Mt=[u,g,R,wt?$:i,wt?q:i,wt?i:$,wt?i:q,et,lt,Et],Yt=S.apply(i,Mt);return Su(u)&&Or(Yt,Mt),Yt.placeholder=k,ap(Yt,u,g)}function Wl(u){var g=Oi[u];return function(S,k){if(S=ei(S),(k=k==null?0:Ar(we(k),292))&&Xf(S)){var R=(qe(S)+"e").split("e");return +((R=(qe(g(R[0]+"e"+(+R[1]+k)))+"e").split("e"))[0]+"e"+(+R[1]-k))}return g(S)}}var Xy=Ts&&1/qc(new Ts([,-0]))[1]==v?function(u){return new Ts(u)}:M;function $s(u){return function(g){var S=Er(g);return S==nt?Tl(g):S==Y?Vf(g):(function(k,R){return We(R,(function($){return [$,k[$]]}))})(g,u(g))}}function to(u,g,S,k,R,$,q,et){var lt=2&g;if(!lt&&typeof u!="function")throw new Kr(o);var Et=k?k.length:0;if(Et||(g&=-97,k=R=i),q=q===i?q:Xn(we(q),0),et=et===i?et:we(et),Et-=R?R.length:0,64&g){var wt=k,Mt=R;k=R=i;}var Yt=lt?i:vu(u),Qt=[u,g,S,k,R,wt,Mt,$,q,et];if(Yt&&(function(Ft,Ut){var ie=Ft[1],Xt=Ut[1],he=ie|Xt,Pe=he<131,Ge=Xt==h&&ie==8||Xt==h&&ie==256&&Ft[7].length<=Ut[8]||Xt==384&&Ut[7].length<=Ut[8]&&ie==8;if(!Pe&&!Ge)return Ft;1&Xt&&(Ft[2]=Ut[2],he|=1&ie?0:4);var le=Ut[3];if(le){var ye=Ft[3];Ft[3]=ye?ti(ye,le,Ut[4]):le,Ft[4]=ye?Wo(Ft[3],c):Ut[4];}(le=Ut[5])&&(ye=Ft[5],Ft[5]=ye?Ns(ye,le,Ut[6]):le,Ft[6]=ye?Wo(Ft[5],c):Ut[6]),(le=Ut[7])&&(Ft[7]=le),Xt&h&&(Ft[8]=Ft[8]==null?Ut[8]:Ar(Ft[8],Ut[8])),Ft[9]==null&&(Ft[9]=Ut[9]),Ft[0]=Ut[0],Ft[1]=he;})(Qt,Yt),u=Qt[0],g=Qt[1],S=Qt[2],k=Qt[3],R=Qt[4],!(et=Qt[9]=Qt[9]===i?lt?0:u.length:Xn(Qt[9]-Et,0))&&24&g&&(g&=-25),g&&g!=1)oe=g==8||g==16?(function(Ft,Ut,ie){var Xt=Bs(Ft);return function he(){for(var Pe=arguments.length,Ge=Ht(Pe),le=Pe,ye=ea(he);le--;)Ge[le]=arguments[le];var Tr=Pe<3&&Ge[0]!==ye&&Ge[Pe-1]!==ye?[]:Wo(Ge,ye);return (Pe-=Tr.length)<ie?wo(Ft,Ut,Hl,he.placeholder,i,Ge,Tr,i,i,ie-Pe):nr(this&&this!==on&&this instanceof he?Xt:Ft,this,Ge)}})(u,g,et):g!=p&&g!=33||R.length?Hl.apply(i,Qt):(function(Ft,Ut,ie,Xt){var he=1&Ut,Pe=Bs(Ft);return function Ge(){for(var le=-1,ye=arguments.length,Tr=-1,Bi=Xt.length,sa=Ht(Bi+ye),wr=this&&this!==on&&this instanceof Ge?Pe:Ft;++Tr<Bi;)sa[Tr]=Xt[Tr];for(;ye--;)sa[Tr++]=arguments[++le];return nr(wr,he?ie:this,sa)}})(u,g,S,k);else var oe=(function(Ft,Ut,ie){var Xt=1&Ut,he=Bs(Ft);return function Pe(){return (this&&this!==on&&this instanceof Pe?he:Ft).apply(Xt?ie:this,arguments)}})(u,g,S);return ap((Yt?Kd:Or)(oe,Qt),u,g)}function gu(u,g,S,k){return u===i||Rr(u,wa[S])&&!an.call(k,S)?g:u}function xr(u,g,S,k,R,$){return Bn(u)&&Bn(g)&&($.set(g,u),Rs(u,g,i,xr,$),$.delete(g)),u}function rp(u){return nc(u)?i:u}function ip(u,g,S,k,R,$){var q=1&S,et=u.length,lt=g.length;if(et!=lt&&!(q&&lt>et))return false;var Et=$.get(u),wt=$.get(g);if(Et&&wt)return Et==g&&wt==u;var Mt=-1,Yt=true,Qt=2&S?new Po:i;for($.set(u,g),$.set(g,u);++Mt<et;){var oe=u[Mt],Ft=g[Mt];if(k)var Ut=q?k(Ft,oe,Mt,g,u,$):k(oe,Ft,Mt,u,g,$);if(Ut!==i){if(Ut)continue;Yt=false;break}if(Qt){if(!zc(g,(function(ie,Xt){if(!Ta(Qt,Xt)&&(oe===ie||R(oe,ie,S,k,$)))return Qt.push(Xt)}))){Yt=false;break}}else if(oe!==Ft&&!R(oe,Ft,S,k,$)){Yt=false;break}}return $.delete(u),$.delete(g),Yt}function Ni(u){return io($a(u,i,Tn),u+"")}function yu(u){return Ul(u,Zn,Gs)}function bu(u){return Ul(u,Wr,op)}var vu=Qo?function(u){return Qo.get(u)}:M;function Cu(u){for(var g=u.name+"",S=Ri[g],k=an.call(Ri,g)?S.length:0;k--;){var R=S[k],$=R.func;if($==null||$==u)return R.name}return g}function ea(u){return (an.call(L,"placeholder")?L:u).placeholder}function ue(){var u=L.iteratee||E;return u=u===E?Vd:u,arguments.length?u(arguments[0],arguments[1]):u}function ql(u,g){var S,k,R=u.__data__;return ((k=typeof(S=g))=="string"||k=="number"||k=="symbol"||k=="boolean"?S!=="__proto__":S===null)?R[typeof g=="string"?"string":"hash"]:R.map}function Na(u){for(var g=Zn(u),S=g.length;S--;){var k=g[S],R=u[k];g[S]=[k,R,Yl(R)];}return g}function La(u,g){var S=(function(k,R){return k==null?i:k[R]})(u,g);return Os(S)?S:i}var Gs=Zc?function(u){return u==null?[]:(u=mn(u),xt(Zc(u),(function(g){return Es.call(u,g)})))}:Rt,op=Zc?function(u){for(var g=[];u;)Ho(g,Gs(u)),u=un(u);return g}:Rt,Er=Pr;function Fe(u,g,S){for(var k=-1,R=(g=Xe(g,u)).length,$=false;++k<R;){var q=Ln(g[k]);if(!($=u!=null&&S(u,q)))break;u=u[q];}return $||++k!=R?$:!!(R=u==null?0:u.length)&&Ws(R)&&Br(q,R)&&(ge(u)||mi(u))}function Ba(u){return typeof u.constructor!="function"||eo(u)?{}:Oa(un(u))}function vh(u){return ge(u)||mi(u)||!!(Od&&u&&u[Od])}function Br(u,g){var S=typeof u;return !!(g=g==null?P:g)&&(S=="number"||S!="symbol"&&Nt.test(u))&&u>-1&&u%1==0&&u<g}function _r(u,g,S){if(!Bn(S))return false;var k=typeof g;return !!(k=="number"?Ur(S)&&Br(g,S.length):k=="string"&&g in S)&&Rr(S[g],u)}function Ua(u,g){if(ge(u))return false;var S=typeof u;return !(S!="number"&&S!="symbol"&&S!="boolean"&&u!=null&&!Fr(u))||ar.test(u)||!bt.test(u)||g!=null&&u in mn(g)}function Su(u){var g=Cu(u),S=L[g];if(typeof S!="function"||!(g in Re.prototype))return false;if(u===S)return true;var k=vu(S);return !!k&&u===k[0]}(Jc&&Er(new Jc(new ArrayBuffer(1)))!=Ct||Ol&&Er(new Ol)!=nt||_s&&Er(_s.resolve())!=j||Ts&&Er(new Ts)!=Y||Aa&&Er(new Aa)!=dt)&&(Er=function(u){var g=Pr(u),S=g==U?u.constructor:i,k=S?ra(S):"";if(k)switch(k){case Zf:return Ct;case Yy:return nt;case Jf:return j;case Qy:return Y;case Ko:return dt}return g});var Zy=Il?$r:Zt;function eo(u){var g=u&&u.constructor;return u===(typeof g=="function"&&g.prototype||wa)}function Yl(u){return u==u&&!Bn(u)}function no(u,g){return function(S){return S!=null&&S[u]===g&&(g!==i||u in mn(S))}}function $a(u,g,S){return g=Xn(g===i?u.length-1:g,0),function(){for(var k=arguments,R=-1,$=Xn(k.length-g,0),q=Ht($);++R<$;)q[R]=k[g+R];R=-1;for(var et=Ht(g+1);++R<g;)et[R]=k[R];return et[g]=S(q),nr(u,this,et)}}function Ch(u,g){return g.length<2?u:Mi(u,Zr(g,0,-1))}function Ga(u,g){for(var S=u.length,k=Ar(g.length,S),R=mr(u);k--;){var $=g[k];u[k]=Br($,S)?R[$]:i;}return u}function Ql(u,g){if((g!=="constructor"||typeof u[g]!="function")&&g!="__proto__")return u[g]}var Or=Pu(Kd),ro=Wy||function(u,g){return on.setTimeout(u,g)},io=Pu(sh);function ap(u,g,S){var k=g+"";return io(u,(function(R,$){var q=$.length;if(!q)return R;var et=q-1;return $[et]=(q>1?"& ":"")+$[et],$=$.join(q>2?", ":" "),R.replace(jr,`{
2303
+ this in the docs: http://dev.apollodata.com/core/fragments.html#unique-names`):se||dn.set(It,se=new Set),se.add(Nt),_t.has(Nt)||(_t.add(Nt),ft.push(Lt));}else ft.push(Lt);var ne;})),r(r({},it),{definitions:ft})})(Z)));}return Ke.get(ot)}function Ve(gt){for(var ot=[],Z=1;Z<arguments.length;Z++)ot[Z-1]=arguments[Z];typeof gt=="string"&&(gt=[gt]);var it=gt[0];return ot.forEach((function(_t,ft){_t&&_t.kind==="Document"?it+=_t.loc.source.body:it+=_t,it+=gt[ft+1];})),vr(it)}function bt(){Ke.clear(),dn.clear();}function ar(){or=false;}function sr(){_e=true;}function Jn(){_e=false;}var lr,wi=Ve,vo=bt,jr=ar,Co=sr,Ce=Jn;(lr=Ve||(Ve={})).gql=wi,lr.resetCaches=vo,lr.disableFragmentWarnings=jr,lr.enableExperimentalFragmentVariables=Co,lr.disableExperimentalFragmentVariables=Ce,Ve.default=Ve;let Vt=Ve;},8552:(t,e,n)=>{var r=n(852)(n(5639),"DataView");t.exports=r;},1989:(t,e,n)=>{var r=n(1789),i=n(401),o=n(7667),s=n(1327),c=n(1866);function p(h){var v=-1,P=h==null?0:h.length;for(this.clear();++v<P;){var x=h[v];this.set(x[0],x[1]);}}p.prototype.clear=r,p.prototype.delete=i,p.prototype.get=o,p.prototype.has=s,p.prototype.set=c,t.exports=p;},8407:(t,e,n)=>{var r=n(7040),i=n(4125),o=n(2117),s=n(7529),c=n(4705);function p(h){var v=-1,P=h==null?0:h.length;for(this.clear();++v<P;){var x=h[v];this.set(x[0],x[1]);}}p.prototype.clear=r,p.prototype.delete=i,p.prototype.get=o,p.prototype.has=s,p.prototype.set=c,t.exports=p;},7071:(t,e,n)=>{var r=n(852)(n(5639),"Map");t.exports=r;},3369:(t,e,n)=>{var r=n(4785),i=n(1285),o=n(6e3),s=n(9916),c=n(5265);function p(h){var v=-1,P=h==null?0:h.length;for(this.clear();++v<P;){var x=h[v];this.set(x[0],x[1]);}}p.prototype.clear=r,p.prototype.delete=i,p.prototype.get=o,p.prototype.has=s,p.prototype.set=c,t.exports=p;},3818:(t,e,n)=>{var r=n(852)(n(5639),"Promise");t.exports=r;},8525:(t,e,n)=>{var r=n(852)(n(5639),"Set");t.exports=r;},8668:(t,e,n)=>{var r=n(3369),i=n(619),o=n(2385);function s(c){var p=-1,h=c==null?0:c.length;for(this.__data__=new r;++p<h;)this.add(c[p]);}s.prototype.add=s.prototype.push=i,s.prototype.has=o,t.exports=s;},6384:(t,e,n)=>{var r=n(8407),i=n(7465),o=n(3779),s=n(7599),c=n(4758),p=n(4309);function h(v){var P=this.__data__=new r(v);this.size=P.size;}h.prototype.clear=i,h.prototype.delete=o,h.prototype.get=s,h.prototype.has=c,h.prototype.set=p,t.exports=h;},2705:(t,e,n)=>{var r=n(5639).Symbol;t.exports=r;},1149:(t,e,n)=>{var r=n(5639).Uint8Array;t.exports=r;},577:(t,e,n)=>{var r=n(852)(n(5639),"WeakMap");t.exports=r;},6874:t=>{t.exports=function(e,n,r){switch(r.length){case 0:return e.call(n);case 1:return e.call(n,r[0]);case 2:return e.call(n,r[0],r[1]);case 3:return e.call(n,r[0],r[1],r[2])}return e.apply(n,r)};},7412:t=>{t.exports=function(e,n){for(var r=-1,i=e==null?0:e.length;++r<i&&n(e[r],r,e)!==false;);return e};},4963:t=>{t.exports=function(e,n){for(var r=-1,i=e==null?0:e.length,o=0,s=[];++r<i;){var c=e[r];n(c,r,e)&&(s[o++]=c);}return s};},4636:(t,e,n)=>{var r=n(2545),i=n(5694),o=n(1469),s=n(4144),c=n(5776),p=n(6719),h=Object.prototype.hasOwnProperty;t.exports=function(v,P){var x=o(v),T=!x&&i(v),I=!x&&!T&&s(v),R=!x&&!T&&!I&&p(v),A=x||T||I||R,O=A?r(v.length,String):[],N=O.length;for(var V in v)!P&&!h.call(v,V)||A&&(V=="length"||I&&(V=="offset"||V=="parent")||R&&(V=="buffer"||V=="byteLength"||V=="byteOffset")||c(V,N))||O.push(V);return O};},9932:t=>{t.exports=function(e,n){for(var r=-1,i=e==null?0:e.length,o=Array(i);++r<i;)o[r]=n(e[r],r,e);return o};},2488:t=>{t.exports=function(e,n){for(var r=-1,i=n.length,o=e.length;++r<i;)e[o+r]=n[r];return e};},2908:t=>{t.exports=function(e,n){for(var r=-1,i=e==null?0:e.length;++r<i;)if(n(e[r],r,e))return true;return false};},6556:(t,e,n)=>{var r=n(9465),i=n(7813);t.exports=function(o,s,c){(c!==void 0&&!i(o[s],c)||c===void 0&&!(s in o))&&r(o,s,c);};},4865:(t,e,n)=>{var r=n(9465),i=n(7813),o=Object.prototype.hasOwnProperty;t.exports=function(s,c,p){var h=s[c];o.call(s,c)&&i(h,p)&&(p!==void 0||c in s)||r(s,c,p);};},8470:(t,e,n)=>{var r=n(7813);t.exports=function(i,o){for(var s=i.length;s--;)if(r(i[s][0],o))return s;return -1};},4037:(t,e,n)=>{var r=n(8363),i=n(3674);t.exports=function(o,s){return o&&r(s,i(s),o)};},3886:(t,e,n)=>{var r=n(8363),i=n(1704);t.exports=function(o,s){return o&&r(s,i(s),o)};},9465:(t,e,n)=>{var r=n(8777);t.exports=function(i,o,s){o=="__proto__"&&r?r(i,o,{configurable:true,enumerable:true,value:s,writable:true}):i[o]=s;};},5990:(t,e,n)=>{var r=n(6384),i=n(7412),o=n(4865),s=n(4037),c=n(3886),p=n(4626),h=n(278),v=n(8805),P=n(1911),x=n(8234),T=n(6904),I=n(4160),R=n(3824),A=n(9148),O=n(8517),N=n(1469),V=n(4144),G=n(6688),X=n(3218),nt=n(2928),st=n(3674),U=n(1704),j="[object Arguments]",ut="[object Function]",Y="[object Object]",at={};at[j]=at["[object Array]"]=at["[object ArrayBuffer]"]=at["[object DataView]"]=at["[object Boolean]"]=at["[object Date]"]=at["[object Float32Array]"]=at["[object Float64Array]"]=at["[object Int8Array]"]=at["[object Int16Array]"]=at["[object Int32Array]"]=at["[object Map]"]=at["[object Number]"]=at[Y]=at["[object RegExp]"]=at["[object Set]"]=at["[object String]"]=at["[object Symbol]"]=at["[object Uint8Array]"]=at["[object Uint8ClampedArray]"]=at["[object Uint16Array]"]=at["[object Uint32Array]"]=true,at["[object Error]"]=at[ut]=at["[object WeakMap]"]=false,t.exports=function pt(dt,mt,Ct,jt,Gt,Jt){var ee,re=1&mt,Ee=2&mt,je=4&mt;if(Ct&&(ee=Gt?Ct(dt,jt,Gt,Jt):Ct(dt)),ee!==void 0)return ee;if(!X(dt))return dt;var sn=N(dt);if(sn){if(ee=R(dt),!re)return h(dt,ee)}else {var Ze=I(dt),Pn=Ze==ut||Ze=="[object GeneratorFunction]";if(V(dt))return p(dt,re);if(Ze==Y||Ze==j||Pn&&!Gt){if(ee=Ee||Pn?{}:O(dt),!re)return Ee?P(dt,c(ee,dt)):v(dt,s(ee,dt))}else {if(!at[Ze])return Gt?dt:{};ee=A(dt,Ze,re);}}Jt||(Jt=new r);var Gn=Jt.get(dt);if(Gn)return Gn;Jt.set(dt,ee),nt(dt)?dt.forEach((function(Ke){ee.add(pt(Ke,mt,Ct,Ke,dt,Jt));})):G(dt)&&dt.forEach((function(Ke,dn){ee.set(dn,pt(Ke,mt,Ct,dn,dt,Jt));}));var ln=sn?void 0:(je?Ee?T:x:Ee?U:st)(dt);return i(ln||dt,(function(Ke,dn){ln&&(Ke=dt[dn=Ke]),o(ee,dn,pt(Ke,mt,Ct,dn,dt,Jt));})),ee};},3118:(t,e,n)=>{var r=n(3218),i=Object.create,o=(function(){function s(){}return function(c){if(!r(c))return {};if(i)return i(c);s.prototype=c;var p=new s;return s.prototype=void 0,p}})();t.exports=o;},4140:(t,e,n)=>{var r=n(7816),i=n(9291)(r);t.exports=i;},1848:t=>{t.exports=function(e,n,r,i){for(var o=e.length,s=r+(i?1:-1);i?s--:++s<o;)if(n(e[s],s,e))return s;return -1};},1078:(t,e,n)=>{var r=n(2488),i=n(7285);t.exports=function o(s,c,p,h,v){var P=-1,x=s.length;for(p||(p=i),v||(v=[]);++P<x;){var T=s[P];c>0&&p(T)?c>1?o(T,c-1,p,h,v):r(v,T):h||(v[v.length]=T);}return v};},8483:(t,e,n)=>{var r=n(5063)();t.exports=r;},7816:(t,e,n)=>{var r=n(8483),i=n(3674);t.exports=function(o,s){return o&&r(o,s,i)};},7786:(t,e,n)=>{var r=n(1811),i=n(327);t.exports=function(o,s){for(var c=0,p=(s=r(s,o)).length;o!=null&&c<p;)o=o[i(s[c++])];return c&&c==p?o:void 0};},8866:(t,e,n)=>{var r=n(2488),i=n(1469);t.exports=function(o,s,c){var p=s(o);return i(o)?p:r(p,c(o))};},4239:(t,e,n)=>{var r=n(2705),i=n(9607),o=n(2333),s=r?r.toStringTag:void 0;t.exports=function(c){return c==null?c===void 0?"[object Undefined]":"[object Null]":s&&s in Object(c)?i(c):o(c)};},13:t=>{t.exports=function(e,n){return e!=null&&n in Object(e)};},2118:(t,e,n)=>{var r=n(1848),i=n(2722),o=n(2351);t.exports=function(s,c,p){return c==c?o(s,c,p):r(s,i,p)};},9454:(t,e,n)=>{var r=n(4239),i=n(7005);t.exports=function(o){return i(o)&&r(o)=="[object Arguments]"};},939:(t,e,n)=>{var r=n(1299),i=n(7005);t.exports=function o(s,c,p,h,v){return s===c||(s==null||c==null||!i(s)&&!i(c)?s!=s&&c!=c:r(s,c,p,h,o,v))};},1299:(t,e,n)=>{var r=n(6384),i=n(7114),o=n(8351),s=n(6096),c=n(4160),p=n(1469),h=n(4144),v=n(6719),P="[object Arguments]",x="[object Array]",T="[object Object]",I=Object.prototype.hasOwnProperty;t.exports=function(R,A,O,N,V,G){var X=p(R),nt=p(A),st=X?x:c(R),U=nt?x:c(A),j=(st=st==P?T:st)==T,ut=(U=U==P?T:U)==T,Y=st==U;if(Y&&h(R)){if(!h(A))return false;X=true,j=false;}if(Y&&!j)return G||(G=new r),X||v(R)?i(R,A,O,N,V,G):o(R,A,st,O,N,V,G);if(!(1&O)){var at=j&&I.call(R,"__wrapped__"),pt=ut&&I.call(A,"__wrapped__");if(at||pt){var dt=at?R.value():R,mt=pt?A.value():A;return G||(G=new r),V(dt,mt,O,N,G)}}return !!Y&&(G||(G=new r),s(R,A,O,N,V,G))};},5588:(t,e,n)=>{var r=n(4160),i=n(7005);t.exports=function(o){return i(o)&&r(o)=="[object Map]"};},2958:(t,e,n)=>{var r=n(6384),i=n(939);t.exports=function(o,s,c,p){var h=c.length,v=h,P=!p;if(o==null)return !v;for(o=Object(o);h--;){var x=c[h];if(P&&x[2]?x[1]!==o[x[0]]:!(x[0]in o))return false}for(;++h<v;){var T=(x=c[h])[0],I=o[T],R=x[1];if(P&&x[2]){if(I===void 0&&!(T in o))return false}else {var A=new r;if(p)var O=p(I,R,T,o,s,A);if(!(O===void 0?i(R,I,3,p,A):O))return false}}return true};},2722:t=>{t.exports=function(e){return e!=e};},8458:(t,e,n)=>{var r=n(3560),i=n(5346),o=n(3218),s=n(346),c=/^\[object .+?Constructor\]$/,p=Function.prototype,h=Object.prototype,v=p.toString,P=h.hasOwnProperty,x=RegExp("^"+v.call(P).replace(/[\\^$.*+?()[\]{}|]/g,"\\$&").replace(/hasOwnProperty|(function).*?(?=\\\()| for .+?(?=\\\])/g,"$1.*?")+"$");t.exports=function(T){return !(!o(T)||i(T))&&(r(T)?x:c).test(s(T))};},9221:(t,e,n)=>{var r=n(4160),i=n(7005);t.exports=function(o){return i(o)&&r(o)=="[object Set]"};},8749:(t,e,n)=>{var r=n(4239),i=n(1780),o=n(7005),s={};s["[object Float32Array]"]=s["[object Float64Array]"]=s["[object Int8Array]"]=s["[object Int16Array]"]=s["[object Int32Array]"]=s["[object Uint8Array]"]=s["[object Uint8ClampedArray]"]=s["[object Uint16Array]"]=s["[object Uint32Array]"]=true,s["[object Arguments]"]=s["[object Array]"]=s["[object ArrayBuffer]"]=s["[object Boolean]"]=s["[object DataView]"]=s["[object Date]"]=s["[object Error]"]=s["[object Function]"]=s["[object Map]"]=s["[object Number]"]=s["[object Object]"]=s["[object RegExp]"]=s["[object Set]"]=s["[object String]"]=s["[object WeakMap]"]=false,t.exports=function(c){return o(c)&&i(c.length)&&!!s[r(c)]};},7206:(t,e,n)=>{var r=n(1573),i=n(6432),o=n(6557),s=n(1469),c=n(9601);t.exports=function(p){return typeof p=="function"?p:p==null?o:typeof p=="object"?s(p)?i(p[0],p[1]):r(p):c(p)};},280:(t,e,n)=>{var r=n(5726),i=n(6916),o=Object.prototype.hasOwnProperty;t.exports=function(s){if(!r(s))return i(s);var c=[];for(var p in Object(s))o.call(s,p)&&p!="constructor"&&c.push(p);return c};},313:(t,e,n)=>{var r=n(3218),i=n(5726),o=n(3498),s=Object.prototype.hasOwnProperty;t.exports=function(c){if(!r(c))return o(c);var p=i(c),h=[];for(var v in c)(v!="constructor"||!p&&s.call(c,v))&&h.push(v);return h};},9199:(t,e,n)=>{var r=n(4140),i=n(8612);t.exports=function(o,s){var c=-1,p=i(o)?Array(o.length):[];return r(o,(function(h,v,P){p[++c]=s(h,v,P);})),p};},1573:(t,e,n)=>{var r=n(2958),i=n(1499),o=n(2634);t.exports=function(s){var c=i(s);return c.length==1&&c[0][2]?o(c[0][0],c[0][1]):function(p){return p===s||r(p,s,c)}};},6432:(t,e,n)=>{var r=n(939),i=n(7361),o=n(9095),s=n(5403),c=n(9162),p=n(2634),h=n(327);t.exports=function(v,P){return s(v)&&c(P)?p(h(v),P):function(x){var T=i(x,v);return T===void 0&&T===P?o(x,v):r(P,T,3)}};},2980:(t,e,n)=>{var r=n(6384),i=n(6556),o=n(8483),s=n(9783),c=n(3218),p=n(1704),h=n(6390);t.exports=function v(P,x,T,I,R){P!==x&&o(x,(function(A,O){if(R||(R=new r),c(A))s(P,x,O,T,v,I,R);else {var N=I?I(h(P,O),A,O+"",P,x,R):void 0;N===void 0&&(N=A),i(P,O,N);}}),p);};},9783:(t,e,n)=>{var r=n(6556),i=n(4626),o=n(7133),s=n(278),c=n(8517),p=n(5694),h=n(1469),v=n(9246),P=n(4144),x=n(3560),T=n(3218),I=n(8630),R=n(6719),A=n(6390),O=n(9881);t.exports=function(N,V,G,X,nt,st,U){var j=A(N,G),ut=A(V,G),Y=U.get(ut);if(Y)r(N,G,Y);else {var at=st?st(j,ut,G+"",N,V,U):void 0,pt=at===void 0;if(pt){var dt=h(ut),mt=!dt&&P(ut),Ct=!dt&&!mt&&R(ut);at=ut,dt||mt||Ct?h(j)?at=j:v(j)?at=s(j):mt?(pt=false,at=i(ut,true)):Ct?(pt=false,at=o(ut,true)):at=[]:I(ut)||p(ut)?(at=j,p(j)?at=O(j):T(j)&&!x(j)||(at=c(ut))):pt=false;}pt&&(U.set(ut,at),nt(at,ut,X,st,U),U.delete(ut)),r(N,G,at);}};},371:t=>{t.exports=function(e){return function(n){return n==null?void 0:n[e]}};},9152:(t,e,n)=>{var r=n(7786);t.exports=function(i){return function(o){return r(o,i)}};},5976:(t,e,n)=>{var r=n(6557),i=n(5357),o=n(61);t.exports=function(s,c){return o(i(s,c,r),s+"")};},6560:(t,e,n)=>{var r=n(5703),i=n(8777),o=n(6557),s=i?function(c,p){return i(c,"toString",{configurable:true,enumerable:false,value:r(p),writable:true})}:o;t.exports=s;},4259:t=>{t.exports=function(e,n,r){var i=-1,o=e.length;n<0&&(n=-n>o?0:o+n),(r=r>o?o:r)<0&&(r+=o),o=n>r?0:r-n>>>0,n>>>=0;for(var s=Array(o);++i<o;)s[i]=e[i+n];return s};},5076:(t,e,n)=>{var r=n(4140);t.exports=function(i,o){var s;return r(i,(function(c,p,h){return !(s=o(c,p,h))})),!!s};},2545:t=>{t.exports=function(e,n){for(var r=-1,i=Array(e);++r<e;)i[r]=n(r);return i};},531:(t,e,n)=>{var r=n(2705),i=n(9932),o=n(1469),s=n(3448),c=r?r.prototype:void 0,p=c?c.toString:void 0;t.exports=function h(v){if(typeof v=="string")return v;if(o(v))return i(v,h)+"";if(s(v))return p?p.call(v):"";var P=v+"";return P=="0"&&1/v==-1/0?"-0":P};},7561:(t,e,n)=>{var r=n(7990),i=/^\s+/;t.exports=function(o){return o&&o.slice(0,r(o)+1).replace(i,"")};},7518:t=>{t.exports=function(e){return function(n){return e(n)}};},7406:(t,e,n)=>{var r=n(1811),i=n(928),o=n(292),s=n(327);t.exports=function(c,p){return p=r(p,c),(c=o(c,p))==null||delete c[s(i(p))]};},7415:(t,e,n)=>{var r=n(9932);t.exports=function(i,o){return r(o,(function(s){return i[s]}))};},4757:t=>{t.exports=function(e,n){return e.has(n)};},1811:(t,e,n)=>{var r=n(1469),i=n(5403),o=n(5514),s=n(9833);t.exports=function(c,p){return r(c)?c:i(c,p)?[c]:o(s(c))};},4318:(t,e,n)=>{var r=n(1149);t.exports=function(i){var o=new i.constructor(i.byteLength);return new r(o).set(new r(i)),o};},4626:(t,e,n)=>{t=n.nmd(t);var r=n(5639),i=e&&!e.nodeType&&e,o=i&&t&&!t.nodeType&&t,s=o&&o.exports===i?r.Buffer:void 0,c=s?s.allocUnsafe:void 0;t.exports=function(p,h){if(h)return p.slice();var v=p.length,P=c?c(v):new p.constructor(v);return p.copy(P),P};},7157:(t,e,n)=>{var r=n(4318);t.exports=function(i,o){var s=o?r(i.buffer):i.buffer;return new i.constructor(s,i.byteOffset,i.byteLength)};},3147:t=>{var e=/\w*$/;t.exports=function(n){var r=new n.constructor(n.source,e.exec(n));return r.lastIndex=n.lastIndex,r};},419:(t,e,n)=>{var r=n(2705),i=r?r.prototype:void 0,o=i?i.valueOf:void 0;t.exports=function(s){return o?Object(o.call(s)):{}};},7133:(t,e,n)=>{var r=n(4318);t.exports=function(i,o){var s=o?r(i.buffer):i.buffer;return new i.constructor(s,i.byteOffset,i.length)};},278:t=>{t.exports=function(e,n){var r=-1,i=e.length;for(n||(n=Array(i));++r<i;)n[r]=e[r];return n};},8363:(t,e,n)=>{var r=n(4865),i=n(9465);t.exports=function(o,s,c,p){var h=!c;c||(c={});for(var v=-1,P=s.length;++v<P;){var x=s[v],T=p?p(c[x],o[x],x,c,o):void 0;T===void 0&&(T=o[x]),h?i(c,x,T):r(c,x,T);}return c};},8805:(t,e,n)=>{var r=n(8363),i=n(9551);t.exports=function(o,s){return r(o,i(o),s)};},1911:(t,e,n)=>{var r=n(8363),i=n(1442);t.exports=function(o,s){return r(o,i(o),s)};},4429:(t,e,n)=>{var r=n(5639)["__core-js_shared__"];t.exports=r;},1463:(t,e,n)=>{var r=n(5976),i=n(6612);t.exports=function(o){return r((function(s,c){var p=-1,h=c.length,v=h>1?c[h-1]:void 0,P=h>2?c[2]:void 0;for(v=o.length>3&&typeof v=="function"?(h--,v):void 0,P&&i(c[0],c[1],P)&&(v=h<3?void 0:v,h=1),s=Object(s);++p<h;){var x=c[p];x&&o(s,x,p,v);}return s}))};},9291:(t,e,n)=>{var r=n(8612);t.exports=function(i,o){return function(s,c){if(s==null)return s;if(!r(s))return i(s,c);for(var p=s.length,h=o?p:-1,v=Object(s);(o?h--:++h<p)&&c(v[h],h,v)!==false;);return s}};},5063:t=>{t.exports=function(e){return function(n,r,i){for(var o=-1,s=Object(n),c=i(n),p=c.length;p--;){var h=c[e?p:++o];if(r(s[h],h,s)===false)break}return n}};},696:(t,e,n)=>{var r=n(8630);t.exports=function(i){return r(i)?void 0:i};},8777:(t,e,n)=>{var r=n(852),i=(function(){try{var o=r(Object,"defineProperty");return o({},"",{}),o}catch(s){}})();t.exports=i;},7114:(t,e,n)=>{var r=n(8668),i=n(2908),o=n(4757);t.exports=function(s,c,p,h,v,P){var x=1&p,T=s.length,I=c.length;if(T!=I&&!(x&&I>T))return false;var R=P.get(s),A=P.get(c);if(R&&A)return R==c&&A==s;var O=-1,N=true,V=2&p?new r:void 0;for(P.set(s,c),P.set(c,s);++O<T;){var G=s[O],X=c[O];if(h)var nt=x?h(X,G,O,c,s,P):h(G,X,O,s,c,P);if(nt!==void 0){if(nt)continue;N=false;break}if(V){if(!i(c,(function(st,U){if(!o(V,U)&&(G===st||v(G,st,p,h,P)))return V.push(U)}))){N=false;break}}else if(G!==X&&!v(G,X,p,h,P)){N=false;break}}return P.delete(s),P.delete(c),N};},8351:(t,e,n)=>{var r=n(2705),i=n(1149),o=n(7813),s=n(7114),c=n(8776),p=n(1814),h=r?r.prototype:void 0,v=h?h.valueOf:void 0;t.exports=function(P,x,T,I,R,A,O){switch(T){case "[object DataView]":if(P.byteLength!=x.byteLength||P.byteOffset!=x.byteOffset)return false;P=P.buffer,x=x.buffer;case "[object ArrayBuffer]":return !(P.byteLength!=x.byteLength||!A(new i(P),new i(x)));case "[object Boolean]":case "[object Date]":case "[object Number]":return o(+P,+x);case "[object Error]":return P.name==x.name&&P.message==x.message;case "[object RegExp]":case "[object String]":return P==x+"";case "[object Map]":var N=c;case "[object Set]":var V=1&I;if(N||(N=p),P.size!=x.size&&!V)return false;var G=O.get(P);if(G)return G==x;I|=2,O.set(P,x);var X=s(N(P),N(x),I,R,A,O);return O.delete(P),X;case "[object Symbol]":if(v)return v.call(P)==v.call(x)}return false};},6096:(t,e,n)=>{var r=n(8234),i=Object.prototype.hasOwnProperty;t.exports=function(o,s,c,p,h,v){var P=1&c,x=r(o),T=x.length;if(T!=r(s).length&&!P)return false;for(var I=T;I--;){var R=x[I];if(!(P?R in s:i.call(s,R)))return false}var A=v.get(o),O=v.get(s);if(A&&O)return A==s&&O==o;var N=true;v.set(o,s),v.set(s,o);for(var V=P;++I<T;){var G=o[R=x[I]],X=s[R];if(p)var nt=P?p(X,G,R,s,o,v):p(G,X,R,o,s,v);if(!(nt===void 0?G===X||h(G,X,c,p,v):nt)){N=false;break}V||(V=R=="constructor");}if(N&&!V){var st=o.constructor,U=s.constructor;st==U||!("constructor"in o)||!("constructor"in s)||typeof st=="function"&&st instanceof st&&typeof U=="function"&&U instanceof U||(N=false);}return v.delete(o),v.delete(s),N};},9021:(t,e,n)=>{var r=n(5564),i=n(5357),o=n(61);t.exports=function(s){return o(i(s,void 0,r),s+"")};},1957:(t,e,n)=>{var r=typeof n.g=="object"&&n.g&&n.g.Object===Object&&n.g;t.exports=r;},8234:(t,e,n)=>{var r=n(8866),i=n(9551),o=n(3674);t.exports=function(s){return r(s,o,i)};},6904:(t,e,n)=>{var r=n(8866),i=n(1442),o=n(1704);t.exports=function(s){return r(s,o,i)};},5050:(t,e,n)=>{var r=n(7019);t.exports=function(i,o){var s=i.__data__;return r(o)?s[typeof o=="string"?"string":"hash"]:s.map};},1499:(t,e,n)=>{var r=n(9162),i=n(3674);t.exports=function(o){for(var s=i(o),c=s.length;c--;){var p=s[c],h=o[p];s[c]=[p,h,r(h)];}return s};},852:(t,e,n)=>{var r=n(8458),i=n(7801);t.exports=function(o,s){var c=i(o,s);return r(c)?c:void 0};},5924:(t,e,n)=>{var r=n(5569)(Object.getPrototypeOf,Object);t.exports=r;},9607:(t,e,n)=>{var r=n(2705),i=Object.prototype,o=i.hasOwnProperty,s=i.toString,c=r?r.toStringTag:void 0;t.exports=function(p){var h=o.call(p,c),v=p[c];try{p[c]=void 0;var P=!0;}catch(T){}var x=s.call(p);return P&&(h?p[c]=v:delete p[c]),x};},9551:(t,e,n)=>{var r=n(4963),i=n(479),o=Object.prototype.propertyIsEnumerable,s=Object.getOwnPropertySymbols,c=s?function(p){return p==null?[]:(p=Object(p),r(s(p),(function(h){return o.call(p,h)})))}:i;t.exports=c;},1442:(t,e,n)=>{var r=n(2488),i=n(5924),o=n(9551),s=n(479),c=Object.getOwnPropertySymbols?function(p){for(var h=[];p;)r(h,o(p)),p=i(p);return h}:s;t.exports=c;},4160:(t,e,n)=>{var r=n(8552),i=n(7071),o=n(3818),s=n(8525),c=n(577),p=n(4239),h=n(346),v="[object Map]",P="[object Promise]",x="[object Set]",T="[object WeakMap]",I="[object DataView]",R=h(r),A=h(i),O=h(o),N=h(s),V=h(c),G=p;(r&&G(new r(new ArrayBuffer(1)))!=I||i&&G(new i)!=v||o&&G(o.resolve())!=P||s&&G(new s)!=x||c&&G(new c)!=T)&&(G=function(X){var nt=p(X),st=nt=="[object Object]"?X.constructor:void 0,U=st?h(st):"";if(U)switch(U){case R:return I;case A:return v;case O:return P;case N:return x;case V:return T}return nt}),t.exports=G;},7801:t=>{t.exports=function(e,n){return e==null?void 0:e[n]};},222:(t,e,n)=>{var r=n(1811),i=n(5694),o=n(1469),s=n(5776),c=n(1780),p=n(327);t.exports=function(h,v,P){for(var x=-1,T=(v=r(v,h)).length,I=false;++x<T;){var R=p(v[x]);if(!(I=h!=null&&P(h,R)))break;h=h[R];}return I||++x!=T?I:!!(T=h==null?0:h.length)&&c(T)&&s(R,T)&&(o(h)||i(h))};},1789:(t,e,n)=>{var r=n(4536);t.exports=function(){this.__data__=r?r(null):{},this.size=0;};},401:t=>{t.exports=function(e){var n=this.has(e)&&delete this.__data__[e];return this.size-=n?1:0,n};},7667:(t,e,n)=>{var r=n(4536),i=Object.prototype.hasOwnProperty;t.exports=function(o){var s=this.__data__;if(r){var c=s[o];return c==="__lodash_hash_undefined__"?void 0:c}return i.call(s,o)?s[o]:void 0};},1327:(t,e,n)=>{var r=n(4536),i=Object.prototype.hasOwnProperty;t.exports=function(o){var s=this.__data__;return r?s[o]!==void 0:i.call(s,o)};},1866:(t,e,n)=>{var r=n(4536);t.exports=function(i,o){var s=this.__data__;return this.size+=this.has(i)?0:1,s[i]=r&&o===void 0?"__lodash_hash_undefined__":o,this};},3824:t=>{var e=Object.prototype.hasOwnProperty;t.exports=function(n){var r=n.length,i=new n.constructor(r);return r&&typeof n[0]=="string"&&e.call(n,"index")&&(i.index=n.index,i.input=n.input),i};},9148:(t,e,n)=>{var r=n(4318),i=n(7157),o=n(3147),s=n(419),c=n(7133);t.exports=function(p,h,v){var P=p.constructor;switch(h){case "[object ArrayBuffer]":return r(p);case "[object Boolean]":case "[object Date]":return new P(+p);case "[object DataView]":return i(p,v);case "[object Float32Array]":case "[object Float64Array]":case "[object Int8Array]":case "[object Int16Array]":case "[object Int32Array]":case "[object Uint8Array]":case "[object Uint8ClampedArray]":case "[object Uint16Array]":case "[object Uint32Array]":return c(p,v);case "[object Map]":case "[object Set]":return new P;case "[object Number]":case "[object String]":return new P(p);case "[object RegExp]":return o(p);case "[object Symbol]":return s(p)}};},8517:(t,e,n)=>{var r=n(3118),i=n(5924),o=n(5726);t.exports=function(s){return typeof s.constructor!="function"||o(s)?{}:r(i(s))};},7285:(t,e,n)=>{var r=n(2705),i=n(5694),o=n(1469),s=r?r.isConcatSpreadable:void 0;t.exports=function(c){return o(c)||i(c)||!!(s&&c&&c[s])};},5776:t=>{var e=/^(?:0|[1-9]\d*)$/;t.exports=function(n,r){var i=typeof n;return !!(r=r==null?9007199254740991:r)&&(i=="number"||i!="symbol"&&e.test(n))&&n>-1&&n%1==0&&n<r};},6612:(t,e,n)=>{var r=n(7813),i=n(8612),o=n(5776),s=n(3218);t.exports=function(c,p,h){if(!s(h))return false;var v=typeof p;return !!(v=="number"?i(h)&&o(p,h.length):v=="string"&&p in h)&&r(h[p],c)};},5403:(t,e,n)=>{var r=n(1469),i=n(3448),o=/\.|\[(?:[^[\]]*|(["'])(?:(?!\1)[^\\]|\\.)*?\1)\]/,s=/^\w*$/;t.exports=function(c,p){if(r(c))return false;var h=typeof c;return !(h!="number"&&h!="symbol"&&h!="boolean"&&c!=null&&!i(c))||s.test(c)||!o.test(c)||p!=null&&c in Object(p)};},7019:t=>{t.exports=function(e){var n=typeof e;return n=="string"||n=="number"||n=="symbol"||n=="boolean"?e!=="__proto__":e===null};},5346:(t,e,n)=>{var r,i=n(4429),o=(r=/[^.]+$/.exec(i&&i.keys&&i.keys.IE_PROTO||""))?"Symbol(src)_1."+r:"";t.exports=function(s){return !!o&&o in s};},5726:t=>{var e=Object.prototype;t.exports=function(n){var r=n&&n.constructor;return n===(typeof r=="function"&&r.prototype||e)};},9162:(t,e,n)=>{var r=n(3218);t.exports=function(i){return i==i&&!r(i)};},7040:t=>{t.exports=function(){this.__data__=[],this.size=0;};},4125:(t,e,n)=>{var r=n(8470),i=Array.prototype.splice;t.exports=function(o){var s=this.__data__,c=r(s,o);return !(c<0||(c==s.length-1?s.pop():i.call(s,c,1),--this.size,0))};},2117:(t,e,n)=>{var r=n(8470);t.exports=function(i){var o=this.__data__,s=r(o,i);return s<0?void 0:o[s][1]};},7529:(t,e,n)=>{var r=n(8470);t.exports=function(i){return r(this.__data__,i)>-1};},4705:(t,e,n)=>{var r=n(8470);t.exports=function(i,o){var s=this.__data__,c=r(s,i);return c<0?(++this.size,s.push([i,o])):s[c][1]=o,this};},4785:(t,e,n)=>{var r=n(1989),i=n(8407),o=n(7071);t.exports=function(){this.size=0,this.__data__={hash:new r,map:new(o||i),string:new r};};},1285:(t,e,n)=>{var r=n(5050);t.exports=function(i){var o=r(this,i).delete(i);return this.size-=o?1:0,o};},6e3:(t,e,n)=>{var r=n(5050);t.exports=function(i){return r(this,i).get(i)};},9916:(t,e,n)=>{var r=n(5050);t.exports=function(i){return r(this,i).has(i)};},5265:(t,e,n)=>{var r=n(5050);t.exports=function(i,o){var s=r(this,i),c=s.size;return s.set(i,o),this.size+=s.size==c?0:1,this};},8776:t=>{t.exports=function(e){var n=-1,r=Array(e.size);return e.forEach((function(i,o){r[++n]=[o,i];})),r};},2634:t=>{t.exports=function(e,n){return function(r){return r!=null&&r[e]===n&&(n!==void 0||e in Object(r))}};},4523:(t,e,n)=>{var r=n(8306);t.exports=function(i){var o=r(i,(function(c){return s.size===500&&s.clear(),c})),s=o.cache;return o};},4536:(t,e,n)=>{var r=n(852)(Object,"create");t.exports=r;},6916:(t,e,n)=>{var r=n(5569)(Object.keys,Object);t.exports=r;},3498:t=>{t.exports=function(e){var n=[];if(e!=null)for(var r in Object(e))n.push(r);return n};},1167:(t,e,n)=>{t=n.nmd(t);var r=n(1957),i=e&&!e.nodeType&&e,o=i&&t&&!t.nodeType&&t,s=o&&o.exports===i&&r.process,c=(function(){try{return o&&o.require&&o.require("util").types||s&&s.binding&&s.binding("util")}catch(p){}})();t.exports=c;},2333:t=>{var e=Object.prototype.toString;t.exports=function(n){return e.call(n)};},5569:t=>{t.exports=function(e,n){return function(r){return e(n(r))}};},5357:(t,e,n)=>{var r=n(6874),i=Math.max;t.exports=function(o,s,c){return s=i(s===void 0?o.length-1:s,0),function(){for(var p=arguments,h=-1,v=i(p.length-s,0),P=Array(v);++h<v;)P[h]=p[s+h];h=-1;for(var x=Array(s+1);++h<s;)x[h]=p[h];return x[s]=c(P),r(o,this,x)}};},292:(t,e,n)=>{var r=n(7786),i=n(4259);t.exports=function(o,s){return s.length<2?o:r(o,i(s,0,-1))};},5639:(t,e,n)=>{var r=n(1957),i=typeof self=="object"&&self&&self.Object===Object&&self,o=r||i||Function("return this")();t.exports=o;},6390:t=>{t.exports=function(e,n){if((n!=="constructor"||typeof e[n]!="function")&&n!="__proto__")return e[n]};},619:t=>{t.exports=function(e){return this.__data__.set(e,"__lodash_hash_undefined__"),this};},2385:t=>{t.exports=function(e){return this.__data__.has(e)};},1814:t=>{t.exports=function(e){var n=-1,r=Array(e.size);return e.forEach((function(i){r[++n]=i;})),r};},61:(t,e,n)=>{var r=n(6560),i=n(1275)(r);t.exports=i;},1275:t=>{var e=Date.now;t.exports=function(n){var r=0,i=0;return function(){var o=e(),s=16-(o-i);if(i=o,s>0){if(++r>=800)return arguments[0]}else r=0;return n.apply(void 0,arguments)}};},7465:(t,e,n)=>{var r=n(8407);t.exports=function(){this.__data__=new r,this.size=0;};},3779:t=>{t.exports=function(e){var n=this.__data__,r=n.delete(e);return this.size=n.size,r};},7599:t=>{t.exports=function(e){return this.__data__.get(e)};},4758:t=>{t.exports=function(e){return this.__data__.has(e)};},4309:(t,e,n)=>{var r=n(8407),i=n(7071),o=n(3369);t.exports=function(s,c){var p=this.__data__;if(p instanceof r){var h=p.__data__;if(!i||h.length<199)return h.push([s,c]),this.size=++p.size,this;p=this.__data__=new o(h);}return p.set(s,c),this.size=p.size,this};},2351:t=>{t.exports=function(e,n,r){for(var i=r-1,o=e.length;++i<o;)if(e[i]===n)return i;return -1};},5514:(t,e,n)=>{var r=n(4523),i=/[^.[\]]+|\[(?:(-?\d+(?:\.\d+)?)|(["'])((?:(?!\2)[^\\]|\\.)*?)\2)\]|(?=(?:\.|\[\])(?:\.|\[\]|$))/g,o=/\\(\\)?/g,s=r((function(c){var p=[];return c.charCodeAt(0)===46&&p.push(""),c.replace(i,(function(h,v,P,x){p.push(P?x.replace(o,"$1"):v||h);})),p}));t.exports=s;},327:(t,e,n)=>{var r=n(3448);t.exports=function(i){if(typeof i=="string"||r(i))return i;var o=i+"";return o=="0"&&1/i==-1/0?"-0":o};},346:t=>{var e=Function.prototype.toString;t.exports=function(n){if(n!=null){try{return e.call(n)}catch(r){}try{return n+""}catch(r){}}return ""};},7990:t=>{var e=/\s/;t.exports=function(n){for(var r=n.length;r--&&e.test(n.charAt(r)););return r};},5703:t=>{t.exports=function(e){return function(){return e}};},7813:t=>{t.exports=function(e,n){return e===n||e!=e&&n!=n};},5564:(t,e,n)=>{var r=n(1078);t.exports=function(i){return i!=null&&i.length?r(i,1):[]};},7361:(t,e,n)=>{var r=n(7786);t.exports=function(i,o,s){var c=i==null?void 0:r(i,o);return c===void 0?s:c};},9095:(t,e,n)=>{var r=n(13),i=n(222);t.exports=function(o,s){return o!=null&&i(o,s,r)};},6557:t=>{t.exports=function(e){return e};},4721:(t,e,n)=>{var r=n(2118),i=n(8612),o=n(7037),s=n(554),c=n(2628),p=Math.max;t.exports=function(h,v,P,x){h=i(h)?h:c(h),P=P&&!x?s(P):0;var T=h.length;return P<0&&(P=p(T+P,0)),o(h)?P<=T&&h.indexOf(v,P)>-1:!!T&&r(h,v,P)>-1};},5694:(t,e,n)=>{var r=n(9454),i=n(7005),o=Object.prototype,s=o.hasOwnProperty,c=o.propertyIsEnumerable,p=r((function(){return arguments})())?r:function(h){return i(h)&&s.call(h,"callee")&&!c.call(h,"callee")};t.exports=p;},1469:t=>{var e=Array.isArray;t.exports=e;},8612:(t,e,n)=>{var r=n(3560),i=n(1780);t.exports=function(o){return o!=null&&i(o.length)&&!r(o)};},9246:(t,e,n)=>{var r=n(8612),i=n(7005);t.exports=function(o){return i(o)&&r(o)};},4144:(t,e,n)=>{t=n.nmd(t);var r=n(5639),i=n(5062),o=e&&!e.nodeType&&e,s=o&&t&&!t.nodeType&&t,c=s&&s.exports===o?r.Buffer:void 0,p=(c?c.isBuffer:void 0)||i;t.exports=p;},1609:(t,e,n)=>{var r=n(280),i=n(4160),o=n(5694),s=n(1469),c=n(8612),p=n(4144),h=n(5726),v=n(6719),P=Object.prototype.hasOwnProperty;t.exports=function(x){if(x==null)return true;if(c(x)&&(s(x)||typeof x=="string"||typeof x.splice=="function"||p(x)||v(x)||o(x)))return !x.length;var T=i(x);if(T=="[object Map]"||T=="[object Set]")return !x.size;if(h(x))return !r(x).length;for(var I in x)if(P.call(x,I))return false;return true};},3560:(t,e,n)=>{var r=n(4239),i=n(3218);t.exports=function(o){if(!i(o))return false;var s=r(o);return s=="[object Function]"||s=="[object GeneratorFunction]"||s=="[object AsyncFunction]"||s=="[object Proxy]"};},1780:t=>{t.exports=function(e){return typeof e=="number"&&e>-1&&e%1==0&&e<=9007199254740991};},6688:(t,e,n)=>{var r=n(5588),i=n(7518),o=n(1167),s=o&&o.isMap,c=s?i(s):r;t.exports=c;},3218:t=>{t.exports=function(e){var n=typeof e;return e!=null&&(n=="object"||n=="function")};},7005:t=>{t.exports=function(e){return e!=null&&typeof e=="object"};},8630:(t,e,n)=>{var r=n(4239),i=n(5924),o=n(7005),s=Function.prototype,c=Object.prototype,p=s.toString,h=c.hasOwnProperty,v=p.call(Object);t.exports=function(P){if(!o(P)||r(P)!="[object Object]")return false;var x=i(P);if(x===null)return true;var T=h.call(x,"constructor")&&x.constructor;return typeof T=="function"&&T instanceof T&&p.call(T)==v};},2928:(t,e,n)=>{var r=n(9221),i=n(7518),o=n(1167),s=o&&o.isSet,c=s?i(s):r;t.exports=c;},7037:(t,e,n)=>{var r=n(4239),i=n(1469),o=n(7005);t.exports=function(s){return typeof s=="string"||!i(s)&&o(s)&&r(s)=="[object String]"};},3448:(t,e,n)=>{var r=n(4239),i=n(7005);t.exports=function(o){return typeof o=="symbol"||i(o)&&r(o)=="[object Symbol]"};},6719:(t,e,n)=>{var r=n(8749),i=n(7518),o=n(1167),s=o&&o.isTypedArray,c=s?i(s):r;t.exports=c;},3674:(t,e,n)=>{var r=n(4636),i=n(280),o=n(8612);t.exports=function(s){return o(s)?r(s):i(s)};},1704:(t,e,n)=>{var r=n(4636),i=n(313),o=n(8612);t.exports=function(s){return o(s)?r(s,true):i(s)};},928:t=>{t.exports=function(e){var n=e==null?0:e.length;return n?e[n-1]:void 0};},6486:function(t,e,n){var r;t=n.nmd(t),function(){var i,o="Expected a function",s="__lodash_hash_undefined__",c="__lodash_placeholder__",p=32,h=128,v=1/0,P=9007199254740991,x=NaN,T=4294967295,I=[["ary",h],["bind",1],["bindKey",2],["curry",8],["curryRight",16],["flip",512],["partial",p],["partialRight",64],["rearg",256]],R="[object Arguments]",A="[object Array]",O="[object Boolean]",N="[object Date]",V="[object Error]",G="[object Function]",X="[object GeneratorFunction]",nt="[object Map]",st="[object Number]",U="[object Object]",j="[object Promise]",ut="[object RegExp]",Y="[object Set]",at="[object String]",pt="[object Symbol]",dt="[object WeakMap]",mt="[object ArrayBuffer]",Ct="[object DataView]",jt="[object Float32Array]",Gt="[object Float64Array]",Jt="[object Int8Array]",ee="[object Int16Array]",re="[object Int32Array]",Ee="[object Uint8Array]",je="[object Uint8ClampedArray]",sn="[object Uint16Array]",Ze="[object Uint32Array]",Pn=/\b__p \+= '';/g,Gn=/\b(__p \+=) '' \+/g,ln=/(__e\(.*?\)|\b__t\)) \+\n'';/g,Ke=/&(?:amp|lt|gt|quot|#39);/g,dn=/[&<>"']/g,or=RegExp(Ke.source),_e=RegExp(dn.source),De=/<%-([\s\S]+?)%>/g,vr=/<%([\s\S]+?)%>/g,Ve=/<%=([\s\S]+?)%>/g,bt=/\.|\[(?:[^[\]]*|(["'])(?:(?!\1)[^\\]|\\.)*?\1)\]/,ar=/^\w*$/,sr=/[^.[\]]+|\[(?:(-?\d+(?:\.\d+)?)|(["'])((?:(?!\2)[^\\]|\\.)*?)\2)\]|(?=(?:\.|\[\])(?:\.|\[\]|$))/g,Jn=/[\\^$.*+?()[\]{}|]/g,lr=RegExp(Jn.source),wi=/^\s+/,vo=/\s/,jr=/\{(?:\n\/\* \[wrapped with .+\] \*\/)?\n?/,Co=/\{\n\/\* \[wrapped with (.+)\] \*/,Ce=/,? & /,Vt=/[^\x00-\x2f\x3a-\x40\x5b-\x60\x7b-\x7f]+/g,gt=/[()=,{}\[\]\/\s]/,ot=/\\(\\)?/g,Z=/\$\{([^\\}]*(?:\\.[^\\}]*)*)\}/g,it=/\w*$/,_t=/^[-+]0x[0-9a-f]+$/i,ft=/^0b[01]+$/i,Lt=/^\[object .+?Constructor\]$/,It=/^0o[0-7]+$/i,Nt=/^(?:0|[1-9]\d*)$/,se=/[\xc0-\xd6\xd8-\xf6\xf8-\xff\u0100-\u017f]/g,ne=/($^)/,kn=/['\n\r\u2028\u2029\\]/g,Ae="\\u0300-\\u036f\\ufe20-\\ufe2f\\u20d0-\\u20ff",cn="a-z\\xdf-\\xf6\\xf8-\\xff",pn="A-Z\\xc0-\\xd6\\xd8-\\xde",Ir="\\xac\\xb1\\xd7\\xf7\\x00-\\x2f\\x3a-\\x40\\x5b-\\x60\\x7b-\\xbf\\u2000-\\u206f \\t\\x0b\\f\\xa0\\ufeff\\n\\r\\u2028\\u2029\\u1680\\u180e\\u2000\\u2001\\u2002\\u2003\\u2004\\u2005\\u2006\\u2007\\u2008\\u2009\\u200a\\u202f\\u205f\\u3000",cr="["+Ir+"]",en="["+Ae+"]",ur="\\d+",$t="["+cn+"]",Vr="[^\\ud800-\\udfff"+Ir+ur+"\\u2700-\\u27bf"+cn+pn+"]",xn="\\ud83c[\\udffb-\\udfff]",jn="[^\\ud800-\\udfff]",ct="(?:\\ud83c[\\udde6-\\uddff]){2}",si="[\\ud800-\\udbff][\\udc00-\\udfff]",fn="["+pn+"]",dr="(?:"+$t+"|"+Vr+")",kr="(?:"+fn+"|"+Vr+")",Ii="(?:['\u2019](?:d|ll|m|re|s|t|ve))?",Wi="(?:['\u2019](?:D|LL|M|RE|S|T|VE))?",ki="(?:"+en+"|"+xn+")?",hs="[\\ufe0e\\ufe0f]?",Sa=hs+ki+"(?:\\u200d(?:"+[jn,ct,si].join("|")+")"+hs+ki+")*",ms="(?:"+["[\\u2700-\\u27bf]",ct,si].join("|")+")"+Sa,Di="(?:"+[jn+en+"?",en,ct,si,"[\\ud800-\\udfff]"].join("|")+")",hn=RegExp("['\u2019]","g"),pr=RegExp(en,"g"),Je=RegExp(xn+"(?="+xn+")|"+Di+Sa,"g"),vt=RegExp([fn+"?"+$t+"+"+Ii+"(?="+[cr,fn,"$"].join("|")+")",kr+"+"+Wi+"(?="+[cr,fn+dr,"$"].join("|")+")",fn+"?"+dr+"+"+Ii,fn+"+"+Wi,"\\d*(?:1ST|2ND|3RD|(?![123])\\dTH)(?=\\b|[a-z_])","\\d*(?:1st|2nd|3rd|(?![123])\\dth)(?=\\b|[A-Z_])",ur,ms].join("|"),"g"),gs=RegExp("[\\u200d\\ud800-\\udfff"+Ae+"\\ufe0e\\ufe0f]"),So=/[a-z][A-Z]|[A-Z]{2}[a-z]|[0-9][a-zA-Z]|[a-zA-Z][0-9]|[^a-zA-Z0-9 ]/,Pa=["Array","Buffer","DataView","Date","Error","Float32Array","Float64Array","Function","Int8Array","Int16Array","Int32Array","Map","Math","Object","Promise","RegExp","Set","String","Symbol","TypeError","Uint8Array","Uint8ClampedArray","Uint16Array","Uint32Array","WeakMap","_","clearTimeout","isFinite","parseInt","setTimeout"],qi=-1,ae={};ae[jt]=ae[Gt]=ae[Jt]=ae[ee]=ae[re]=ae[Ee]=ae[je]=ae[sn]=ae[Ze]=true,ae[R]=ae[A]=ae[mt]=ae[O]=ae[Ct]=ae[N]=ae[V]=ae[G]=ae[nt]=ae[st]=ae[U]=ae[ut]=ae[Y]=ae[at]=ae[dt]=false;var Ue={};Ue[R]=Ue[A]=Ue[mt]=Ue[Ct]=Ue[O]=Ue[N]=Ue[jt]=Ue[Gt]=Ue[Jt]=Ue[ee]=Ue[re]=Ue[nt]=Ue[st]=Ue[U]=Ue[ut]=Ue[Y]=Ue[at]=Ue[pt]=Ue[Ee]=Ue[je]=Ue[sn]=Ue[Ze]=true,Ue[V]=Ue[G]=Ue[dt]=false;var Yr={"\\":"\\","'":"'","\n":"n","\r":"r","\u2028":"u2028","\u2029":"u2029"},li=parseFloat,Yi=parseInt,xl=typeof n.g=="object"&&n.g&&n.g.Object===Object&&n.g,El=typeof self=="object"&&self&&self.Object===Object&&self,on=xl||El||Function("return this")(),xa=e&&!e.nodeType&&e,tr=xa&&t&&!t.nodeType&&t,Ea=tr&&tr.exports===xa,ci=Ea&&xl.process,Kn=(function(){try{return tr&&tr.require&&tr.require("util").types||ci&&ci.binding&&ci.binding("util")}catch(ht){}})(),Ai=Kn&&Kn.isArrayBuffer,er=Kn&&Kn.isDate,ys=Kn&&Kn.isMap,_a=Kn&&Kn.isRegExp,zo=Kn&&Kn.isSet,Cr=Kn&&Kn.isTypedArray;function nr(ht,At,Dt){switch(Dt.length){case 0:return ht.call(At);case 1:return ht.call(At,Dt[0]);case 2:return ht.call(At,Dt[0],Dt[1]);case 3:return ht.call(At,Dt[0],Dt[1],Dt[2])}return ht.apply(At,Dt)}function Kt(ht,At,Dt,Ht){for(var xe=-1,Ne=ht==null?0:ht.length;++xe<Ne;){var En=ht[xe];At(Ht,En,Dt(En),ht);}return Ht}function Wt(ht,At){for(var Dt=-1,Ht=ht==null?0:ht.length;++Dt<Ht&&At(ht[Dt],Dt,ht)!==false;);return ht}function Tt(ht,At){for(var Dt=ht==null?0:ht.length;Dt--&&At(ht[Dt],Dt,ht)!==false;);return ht}function kt(ht,At){for(var Dt=-1,Ht=ht==null?0:ht.length;++Dt<Ht;)if(!At(ht[Dt],Dt,ht))return false;return true}function xt(ht,At){for(var Dt=-1,Ht=ht==null?0:ht.length,xe=0,Ne=[];++Dt<Ht;){var En=ht[Dt];At(En,Dt,ht)&&(Ne[xe++]=En);}return Ne}function jc(ht,At){return !(ht==null||!ht.length)&&Dr(ht,At,0)>-1}function Vc(ht,At,Dt){for(var Ht=-1,xe=ht==null?0:ht.length;++Ht<xe;)if(Dt(At,ht[Ht]))return true;return false}function We(ht,At){for(var Dt=-1,Ht=ht==null?0:ht.length,xe=Array(Ht);++Dt<Ht;)xe[Dt]=At(ht[Dt],Dt,ht);return xe}function Ho(ht,At){for(var Dt=-1,Ht=At.length,xe=ht.length;++Dt<Ht;)ht[xe+Dt]=At[Dt];return ht}function _l(ht,At,Dt,Ht){var xe=-1,Ne=ht==null?0:ht.length;for(Ht&&Ne&&(Dt=ht[++xe]);++xe<Ne;)Dt=At(Dt,ht[xe],xe,ht);return Dt}function Uf(ht,At,Dt,Ht){var xe=ht==null?0:ht.length;for(Ht&&xe&&(Dt=ht[--xe]);xe--;)Dt=At(Dt,ht[xe],xe,ht);return Dt}function zc(ht,At){for(var Dt=-1,Ht=ht==null?0:ht.length;++Dt<Ht;)if(At(ht[Dt],Dt,ht))return true;return false}var Vy=bs("length");function $f(ht,At,Dt){var Ht;return Dt(ht,(function(xe,Ne,En){if(At(xe,Ne,En))return Ht=Ne,false})),Ht}function Hc(ht,At,Dt,Ht){for(var xe=ht.length,Ne=Dt+(Ht?1:-1);Ht?Ne--:++Ne<xe;)if(At(ht[Ne],Ne,ht))return Ne;return -1}function Dr(ht,At,Dt){return At==At?(function(Ht,xe,Ne){for(var En=Ne-1,Oi=Ht.length;++En<Oi;)if(Ht[En]===xe)return En;return -1})(ht,At,Dt):Hc(ht,ui,Dt)}function te(ht,At,Dt,Ht){for(var xe=Dt-1,Ne=ht.length;++xe<Ne;)if(Ht(ht[xe],At))return xe;return -1}function ui(ht){return ht!=ht}function Dn(ht,At){var Dt=ht==null?0:ht.length;return Dt?xd(ht,At)/Dt:x}function bs(ht){return function(At){return At==null?i:At[ht]}}function Sd(ht){return function(At){return ht==null?i:ht[At]}}function Pd(ht,At,Dt,Ht,xe){return xe(ht,(function(Ne,En,Oi){Dt=Ht?(Ht=false,Ne):At(Dt,Ne,En,Oi);})),Dt}function xd(ht,At){for(var Dt,Ht=-1,xe=ht.length;++Ht<xe;){var Ne=At(ht[Ht]);Ne!==i&&(Dt=Dt===i?Ne:Dt+Ne);}return Dt}function Ed(ht,At){for(var Dt=-1,Ht=Array(ht);++Dt<ht;)Ht[Dt]=At(Dt);return Ht}function _d(ht){return ht&&ht.slice(0,zf(ht)+1).replace(wi,"")}function zr(ht){return function(At){return ht(At)}}function Wc(ht,At){return We(At,(function(Dt){return ht[Dt]}))}function Ta(ht,At){return ht.has(At)}function vs(ht,At){for(var Dt=-1,Ht=ht.length;++Dt<Ht&&Dr(At,ht[Dt],0)>-1;);return Dt}function Td(ht,At){for(var Dt=ht.length;Dt--&&Dr(At,ht[Dt],0)>-1;);return Dt}function Gf(ht,At){for(var Dt=ht.length,Ht=0;Dt--;)ht[Dt]===At&&++Ht;return Ht}var zy=Sd({\u00C0:"A",\u00C1:"A",\u00C2:"A",\u00C3:"A",\u00C4:"A",\u00C5:"A",\u00E0:"a",\u00E1:"a",\u00E2:"a",\u00E3:"a",\u00E4:"a",\u00E5:"a",\u00C7:"C",\u00E7:"c",\u00D0:"D",\u00F0:"d",\u00C8:"E",\u00C9:"E",\u00CA:"E",\u00CB:"E",\u00E8:"e",\u00E9:"e",\u00EA:"e",\u00EB:"e",\u00CC:"I",\u00CD:"I",\u00CE:"I",\u00CF:"I",\u00EC:"i",\u00ED:"i",\u00EE:"i",\u00EF:"i",\u00D1:"N",\u00F1:"n",\u00D2:"O",\u00D3:"O",\u00D4:"O",\u00D5:"O",\u00D6:"O",\u00D8:"O",\u00F2:"o",\u00F3:"o",\u00F4:"o",\u00F5:"o",\u00F6:"o",\u00F8:"o",\u00D9:"U",\u00DA:"U",\u00DB:"U",\u00DC:"U",\u00F9:"u",\u00FA:"u",\u00FB:"u",\u00FC:"u",\u00DD:"Y",\u00FD:"y",\u00FF:"y",\u00C6:"Ae",\u00E6:"ae",\u00DE:"Th",\u00FE:"th",\u00DF:"ss",\u0100:"A",\u0102:"A",\u0104:"A",\u0101:"a",\u0103:"a",\u0105:"a",\u0106:"C",\u0108:"C",\u010A:"C",\u010C:"C",\u0107:"c",\u0109:"c",\u010B:"c",\u010D:"c",\u010E:"D",\u0110:"D",\u010F:"d",\u0111:"d",\u0112:"E",\u0114:"E",\u0116:"E",\u0118:"E",\u011A:"E",\u0113:"e",\u0115:"e",\u0117:"e",\u0119:"e",\u011B:"e",\u011C:"G",\u011E:"G",\u0120:"G",\u0122:"G",\u011D:"g",\u011F:"g",\u0121:"g",\u0123:"g",\u0124:"H",\u0126:"H",\u0125:"h",\u0127:"h",\u0128:"I",\u012A:"I",\u012C:"I",\u012E:"I",\u0130:"I",\u0129:"i",\u012B:"i",\u012D:"i",\u012F:"i",\u0131:"i",\u0134:"J",\u0135:"j",\u0136:"K",\u0137:"k",\u0138:"k",\u0139:"L",\u013B:"L",\u013D:"L",\u013F:"L",\u0141:"L",\u013A:"l",\u013C:"l",\u013E:"l",\u0140:"l",\u0142:"l",\u0143:"N",\u0145:"N",\u0147:"N",\u014A:"N",\u0144:"n",\u0146:"n",\u0148:"n",\u014B:"n",\u014C:"O",\u014E:"O",\u0150:"O",\u014D:"o",\u014F:"o",\u0151:"o",\u0154:"R",\u0156:"R",\u0158:"R",\u0155:"r",\u0157:"r",\u0159:"r",\u015A:"S",\u015C:"S",\u015E:"S",\u0160:"S",\u015B:"s",\u015D:"s",\u015F:"s",\u0161:"s",\u0162:"T",\u0164:"T",\u0166:"T",\u0163:"t",\u0165:"t",\u0167:"t",\u0168:"U",\u016A:"U",\u016C:"U",\u016E:"U",\u0170:"U",\u0172:"U",\u0169:"u",\u016B:"u",\u016D:"u",\u016F:"u",\u0171:"u",\u0173:"u",\u0174:"W",\u0175:"w",\u0176:"Y",\u0177:"y",\u0178:"Y",\u0179:"Z",\u017B:"Z",\u017D:"Z",\u017A:"z",\u017C:"z",\u017E:"z",\u0132:"IJ",\u0133:"ij",\u0152:"Oe",\u0153:"oe",\u0149:"'n",\u017F:"s"}),jf=Sd({"&":"&amp;","<":"&lt;",">":"&gt;",'"':"&quot;","'":"&#39;"});function wd(ht){return "\\"+Yr[ht]}function Nn(ht){return gs.test(ht)}function Tl(ht){var At=-1,Dt=Array(ht.size);return ht.forEach((function(Ht,xe){Dt[++At]=[xe,Ht];})),Dt}function Id(ht,At){return function(Dt){return ht(At(Dt))}}function Wo(ht,At){for(var Dt=-1,Ht=ht.length,xe=0,Ne=[];++Dt<Ht;){var En=ht[Dt];En!==At&&En!==c||(ht[Dt]=c,Ne[xe++]=Dt);}return Ne}function qc(ht){var At=-1,Dt=Array(ht.size);return ht.forEach((function(Ht){Dt[++At]=Ht;})),Dt}function Vf(ht){var At=-1,Dt=Array(ht.size);return ht.forEach((function(Ht){Dt[++At]=[Ht,Ht];})),Dt}function qo(ht){return Nn(ht)?(function(At){for(var Dt=Je.lastIndex=0;Je.test(At);)++Dt;return Dt})(ht):Vy(ht)}function Qr(ht){return Nn(ht)?(function(At){return At.match(Je)||[]})(ht):(function(At){return At.split("")})(ht)}function zf(ht){for(var At=ht.length;At--&&vo.test(ht.charAt(At)););return At}var Hf=Sd({"&amp;":"&","&lt;":"<","&gt;":">","&quot;":'"',"&#39;":"'"}),Yc=(function ht(At){var Dt,Ht=(At=At==null?on:Yc.defaults(on.Object(),At,Yc.pick(on,Pa))).Array,xe=At.Date,Ne=At.Error,En=At.Function,Oi=At.Math,mn=At.Object,Cs=At.RegExp,Wf=At.String,Kr=At.TypeError,wl=Ht.prototype,kd=En.prototype,wa=mn.prototype,Il=At["__core-js_shared__"],Ss=kd.toString,an=wa.hasOwnProperty,qf=0,Yf=(Dt=/[^.]+$/.exec(Il&&Il.keys&&Il.keys.IE_PROTO||""))?"Symbol(src)_1."+Dt:"",Ia=wa.toString,Dd=Ss.call(mn),Hy=on._,Qf=Cs("^"+Ss.call(an).replace(Jn,"\\$&").replace(/hasOwnProperty|(function).*?(?=\\\()| for .+?(?=\\\])/g,"$1.*?")+"$"),Ps=Ea?At.Buffer:i,di=At.Symbol,kl=At.Uint8Array,Ad=Ps?Ps.allocUnsafe:i,un=Id(mn.getPrototypeOf,mn),xs=mn.create,Es=wa.propertyIsEnumerable,Qc=wl.splice,Od=di?di.isConcatSpreadable:i,ka=di?di.iterator:i,Da=di?di.toStringTag:i,Kc=(function(){try{var u=La(mn,"defineProperty");return u({},"",{}),u}catch(g){}})(),Kf=At.clearTimeout!==on.clearTimeout&&At.clearTimeout,Rd=xe&&xe.now!==on.Date.now&&xe.now,Wy=At.setTimeout!==on.setTimeout&&At.setTimeout,Dl=Oi.ceil,Xc=Oi.floor,Zc=mn.getOwnPropertySymbols,Fd=Ps?Ps.isBuffer:i,Xf=At.isFinite,Md=wl.join,Sr=Id(mn.keys,mn),Xn=Oi.max,Ar=Oi.min,Nd=xe.now,Ld=At.parseInt,Al=Oi.random,qy=wl.reverse,Jc=La(At,"DataView"),Ol=La(At,"Map"),_s=La(At,"Promise"),Ts=La(At,"Set"),Aa=La(At,"WeakMap"),Yo=La(mn,"create"),Qo=Aa&&new Aa,Ri={},Zf=ra(Jc),Yy=ra(Ol),Jf=ra(_s),Qy=ra(Ts),Ko=ra(Aa),Rl=di?di.prototype:i,ws=Rl?Rl.valueOf:i,tu=Rl?Rl.toString:i;function L(u){if(zn(u)&&!ge(u)&&!(u instanceof Re)){if(u instanceof Xr)return u;if(an.call(u,"__wrapped__"))return Io(u)}return new Xr(u)}var Oa=(function(){function u(){}return function(g){if(!Bn(g))return {};if(xs)return xs(g);u.prototype=g;var S=new u;return u.prototype=i,S}})();function Fl(){}function Xr(u,g){this.__wrapped__=u,this.__actions__=[],this.__chain__=!!g,this.__index__=0,this.__values__=i;}function Re(u){this.__wrapped__=u,this.__actions__=[],this.__dir__=1,this.__filtered__=false,this.__iteratees__=[],this.__takeCount__=T,this.__views__=[];}function Ra(u){var g=-1,S=u==null?0:u.length;for(this.clear();++g<S;){var k=u[g];this.set(k[0],k[1]);}}function Qi(u){var g=-1,S=u==null?0:u.length;for(this.clear();++g<S;){var k=u[g];this.set(k[0],k[1]);}}function Ki(u){var g=-1,S=u==null?0:u.length;for(this.clear();++g<S;){var k=u[g];this.set(k[0],k[1]);}}function Po(u){var g=-1,S=u==null?0:u.length;for(this.__data__=new Ki;++g<S;)this.add(u[g]);}function Hr(u){var g=this.__data__=new Qi(u);this.size=g.size;}function eu(u,g){var S=ge(u),k=!S&&mi(u),F=!S&&!k&&Do(u),$=!S&&!k&&!F&&qs(u),q=S||k||F||$,et=q?Ed(u.length,Wf):[],lt=et.length;for(var Et in u)!g&&!an.call(u,Et)||q&&(Et=="length"||F&&(Et=="offset"||Et=="parent")||$&&(Et=="buffer"||Et=="byteLength"||Et=="byteOffset")||Br(Et,lt))||et.push(Et);return et}function Bd(u){var g=u.length;return g?u[Qd(0,g-1)]:i}function Ml(u,g){return xu(mr(u),xo(g,0,u.length))}function th(u){return xu(mr(u))}function Ud(u,g,S){(S!==i&&!Rr(u[g],S)||S===i&&!(g in u))&&Xi(u,g,S);}function Nl(u,g,S){var k=u[g];an.call(u,g)&&Rr(k,S)&&(S!==i||g in u)||Xi(u,g,S);}function Ll(u,g){for(var S=u.length;S--;)if(Rr(u[S][0],g))return S;return -1}function Is(u,g,S,k){return Xo(u,(function(F,$,q){g(k,F,S(F),q);})),k}function nu(u,g){return u&&fi(g,Zn(g),u)}function Xi(u,g,S){g=="__proto__"&&Kc?Kc(u,g,{configurable:true,enumerable:true,value:S,writable:true}):u[g]=S;}function Bl(u,g){for(var S=-1,k=g.length,F=Ht(k),$=u==null;++S<k;)F[S]=$?i:Du(u,g[S]);return F}function xo(u,g,S){return u==u&&(S!==i&&(u=u<=S?u:S),g!==i&&(u=u>=g?u:g)),u}function pi(u,g,S,k,F,$){var q,et=1&g,lt=2&g,Et=4&g;if(S&&(q=F?S(u,k,F,$):S(u)),q!==i)return q;if(!Bn(u))return u;var wt=ge(u);if(wt){if(q=(function(Ft){var Ut=Ft.length,ie=new Ft.constructor(Ut);return Ut&&typeof Ft[0]=="string"&&an.call(Ft,"index")&&(ie.index=Ft.index,ie.input=Ft.input),ie})(u),!et)return mr(u,q)}else {var Mt=Er(u),Yt=Mt==G||Mt==X;if(Do(u))return mh(u,et);if(Mt==U||Mt==R||Yt&&!F){if(q=lt||Yt?{}:Ba(u),!et)return lt?(function(Ft,Ut){return fi(Ft,op(Ft),Ut)})(u,(function(Ft,Ut){return Ft&&fi(Ut,Wr(Ut),Ft)})(q,u)):(function(Ft,Ut){return fi(Ft,Gs(Ft),Ut)})(u,nu(q,u))}else {if(!Ue[Mt])return F?u:{};q=(function(Ft,Ut,ie){var Xt,he=Ft.constructor;switch(Ut){case mt:return du(Ft);case O:case N:return new he(+Ft);case Ct:return (function(Pe,Ge){var le=Ge?du(Pe.buffer):Pe.buffer;return new Pe.constructor(le,Pe.byteOffset,Pe.byteLength)})(Ft,ie);case jt:case Gt:case Jt:case ee:case re:case Ee:case je:case sn:case Ze:return ta(Ft,ie);case nt:return new he;case st:case at:return new he(Ft);case ut:return (function(Pe){var Ge=new Pe.constructor(Pe.source,it.exec(Pe));return Ge.lastIndex=Pe.lastIndex,Ge})(Ft);case Y:return new he;case pt:return Xt=Ft,ws?mn(ws.call(Xt)):{}}})(u,Mt,et);}}$||($=new Hr);var Qt=$.get(u);if(Qt)return Qt;$.set(u,q),Sp(u)?u.forEach((function(Ft){q.add(pi(Ft,g,S,Ft,u,$));})):Mh(u)&&u.forEach((function(Ft,Ut){q.set(Ut,pi(Ft,g,S,Ut,u,$));}));var oe=wt?i:(Et?lt?bu:yu:lt?Wr:Zn)(u);return Wt(oe||u,(function(Ft,Ut){oe&&(Ft=u[Ut=Ft]),Nl(q,Ut,pi(Ft,g,S,Ut,u,$));})),q}function eh(u,g,S){var k=S.length;if(u==null)return !k;for(u=mn(u);k--;){var F=S[k],$=g[F],q=u[F];if(q===i&&!(F in u)||!$(q))return false}return true}function $d(u,g,S){if(typeof u!="function")throw new Kr(o);return ro((function(){u.apply(i,S);}),g)}function Fa(u,g,S,k){var F=-1,$=jc,q=true,et=u.length,lt=[],Et=g.length;if(!et)return lt;S&&(g=We(g,zr(S))),k?($=Vc,q=false):g.length>=200&&($=Ta,q=false,g=new Po(g));t:for(;++F<et;){var wt=u[F],Mt=S==null?wt:S(wt);if(wt=k||wt!==0?wt:0,q&&Mt==Mt){for(var Yt=Et;Yt--;)if(g[Yt]===Mt)continue t;lt.push(wt);}else $(g,Mt,k)||lt.push(wt);}return lt}L.templateSettings={escape:De,evaluate:vr,interpolate:Ve,variable:"",imports:{_:L}},L.prototype=Fl.prototype,L.prototype.constructor=L,Xr.prototype=Oa(Fl.prototype),Xr.prototype.constructor=Xr,Re.prototype=Oa(Fl.prototype),Re.prototype.constructor=Re,Ra.prototype.clear=function(){this.__data__=Yo?Yo(null):{},this.size=0;},Ra.prototype.delete=function(u){var g=this.has(u)&&delete this.__data__[u];return this.size-=g?1:0,g},Ra.prototype.get=function(u){var g=this.__data__;if(Yo){var S=g[u];return S===s?i:S}return an.call(g,u)?g[u]:i},Ra.prototype.has=function(u){var g=this.__data__;return Yo?g[u]!==i:an.call(g,u)},Ra.prototype.set=function(u,g){var S=this.__data__;return this.size+=this.has(u)?0:1,S[u]=Yo&&g===i?s:g,this},Qi.prototype.clear=function(){this.__data__=[],this.size=0;},Qi.prototype.delete=function(u){var g=this.__data__,S=Ll(g,u);return !(S<0||(S==g.length-1?g.pop():Qc.call(g,S,1),--this.size,0))},Qi.prototype.get=function(u){var g=this.__data__,S=Ll(g,u);return S<0?i:g[S][1]},Qi.prototype.has=function(u){return Ll(this.__data__,u)>-1},Qi.prototype.set=function(u,g){var S=this.__data__,k=Ll(S,u);return k<0?(++this.size,S.push([u,g])):S[k][1]=g,this},Ki.prototype.clear=function(){this.size=0,this.__data__={hash:new Ra,map:new(Ol||Qi),string:new Ra};},Ki.prototype.delete=function(u){var g=ql(this,u).delete(u);return this.size-=g?1:0,g},Ki.prototype.get=function(u){return ql(this,u).get(u)},Ki.prototype.has=function(u){return ql(this,u).has(u)},Ki.prototype.set=function(u,g){var S=ql(this,u),k=S.size;return S.set(u,g),this.size+=S.size==k?0:1,this},Po.prototype.add=Po.prototype.push=function(u){return this.__data__.set(u,s),this},Po.prototype.has=function(u){return this.__data__.has(u)},Hr.prototype.clear=function(){this.__data__=new Qi,this.size=0;},Hr.prototype.delete=function(u){var g=this.__data__,S=g.delete(u);return this.size=g.size,S},Hr.prototype.get=function(u){return this.__data__.get(u)},Hr.prototype.has=function(u){return this.__data__.has(u)},Hr.prototype.set=function(u,g){var S=this.__data__;if(S instanceof Qi){var k=S.__data__;if(!Ol||k.length<199)return k.push([u,g]),this.size=++S.size,this;S=this.__data__=new Ki(k);}return S.set(u,g),this.size=S.size,this};var Xo=yh(Fi),nh=yh(Zi,true);function rh(u,g){var S=true;return Xo(u,(function(k,F,$){return S=!!g(k,F,$)})),S}function ks(u,g,S){for(var k=-1,F=u.length;++k<F;){var $=u[k],q=g($);if(q!=null&&(et===i?q==q&&!Fr(q):S(q,et)))var et=q,lt=$;}return lt}function fr(u,g){var S=[];return Xo(u,(function(k,F,$){g(k,F,$)&&S.push(k);})),S}function hr(u,g,S,k,F){var $=-1,q=u.length;for(S||(S=vh),F||(F=[]);++$<q;){var et=u[$];g>0&&S(et)?g>1?hr(et,g-1,S,k,F):Ho(F,et):k||(F[F.length]=et);}return F}var ru=fu(),Gd=fu(true);function Fi(u,g){return u&&ru(u,g,Zn)}function Zi(u,g){return u&&Gd(u,g,Zn)}function Ds(u,g){return xt(g,(function(S){return $r(u[S])}))}function Mi(u,g){for(var S=0,k=(g=Xe(g,u)).length;u!=null&&S<k;)u=u[Ln(g[S++])];return S&&S==k?u:i}function Ul(u,g,S){var k=g(u);return ge(u)?k:Ho(k,S(u))}function Pr(u){return u==null?u===i?"[object Undefined]":"[object Null]":Da&&Da in mn(u)?(function(g){var S=an.call(g,Da),k=g[Da];try{g[Da]=i;var F=!0;}catch(q){}var $=Ia.call(g);return F&&(S?g[Da]=k:delete g[Da]),$})(u):(function(g){return Ia.call(g)})(u)}function iu(u,g){return u>g}function $l(u,g){return u!=null&&an.call(u,g)}function ih(u,g){return u!=null&&g in mn(u)}function Gl(u,g,S){for(var k=S?Vc:jc,F=u[0].length,$=u.length,q=$,et=Ht($),lt=1/0,Et=[];q--;){var wt=u[q];q&&g&&(wt=We(wt,zr(g))),lt=Ar(wt.length,lt),et[q]=!S&&(g||F>=120&&wt.length>=120)?new Po(q&&wt):i;}wt=u[0];var Mt=-1,Yt=et[0];t:for(;++Mt<F&&Et.length<lt;){var Qt=wt[Mt],oe=g?g(Qt):Qt;if(Qt=S||Qt!==0?Qt:0,!(Yt?Ta(Yt,oe):k(Et,oe,S))){for(q=$;--q;){var Ft=et[q];if(!(Ft?Ta(Ft,oe):k(u[q],oe,S)))continue t}Yt&&Yt.push(oe),Et.push(Qt);}}return Et}function As(u,g,S){var k=(u=Ch(u,g=Xe(g,u)))==null?u:u[Ln(hi(g))];return k==null?i:nr(k,u,S)}function Eo(u){return zn(u)&&Pr(u)==R}function jl(u,g,S,k,F){return u===g||(u==null||g==null||!zn(u)&&!zn(g)?u!=u&&g!=g:(function($,q,et,lt,Et,wt){var Mt=ge($),Yt=ge(q),Qt=Mt?A:Er($),oe=Yt?A:Er(q),Ft=(Qt=Qt==R?U:Qt)==U,Ut=(oe=oe==R?U:oe)==U,ie=Qt==oe;if(ie&&Do($)){if(!Do(q))return false;Mt=true,Ft=false;}if(ie&&!Ft)return wt||(wt=new Hr),Mt||qs($)?ip($,q,et,lt,Et,wt):(function(le,ye,Tr,Bi,sa,wr,Wa){switch(Tr){case Ct:if(le.byteLength!=ye.byteLength||le.byteOffset!=ye.byteOffset)return false;le=le.buffer,ye=ye.buffer;case mt:return !(le.byteLength!=ye.byteLength||!wr(new kl(le),new kl(ye)));case O:case N:case st:return Rr(+le,+ye);case V:return le.name==ye.name&&le.message==ye.message;case ut:case at:return le==ye+"";case nt:var Qs=Tl;case Y:var Ip=1&Bi;if(Qs||(Qs=qc),le.size!=ye.size&&!Ip)return false;var rc=Wa.get(le);if(rc)return rc==ye;Bi|=2,Wa.set(le,ye);var qa=ip(Qs(le),Qs(ye),Bi,sa,wr,Wa);return Wa.delete(le),qa;case pt:if(ws)return ws.call(le)==ws.call(ye)}return false})($,q,Qt,et,lt,Et,wt);if(!(1&et)){var Xt=Ft&&an.call($,"__wrapped__"),he=Ut&&an.call(q,"__wrapped__");if(Xt||he){var Pe=Xt?$.value():$,Ge=he?q.value():q;return wt||(wt=new Hr),Et(Pe,Ge,et,lt,wt)}}return !!ie&&(wt||(wt=new Hr),(function(le,ye,Tr,Bi,sa,wr){var Wa=1&Tr,Qs=yu(le),Ip=Qs.length;if(Ip!=yu(ye).length&&!Wa)return false;for(var rc=Ip;rc--;){var qa=Qs[rc];if(!(Wa?qa in ye:an.call(ye,qa)))return false}var H1=wr.get(le),W1=wr.get(ye);if(H1&&W1)return H1==ye&&W1==le;var qh=true;wr.set(le,ye),wr.set(ye,le);for(var pb=Wa;++rc<Ip;){var Yh=le[qa=Qs[rc]],Qh=ye[qa];if(Bi)var q1=Wa?Bi(Qh,Yh,qa,ye,le,wr):Bi(Yh,Qh,qa,le,ye,wr);if(!(q1===i?Yh===Qh||sa(Yh,Qh,Tr,Bi,wr):q1)){qh=false;break}pb||(pb=qa=="constructor");}if(qh&&!pb){var Kh=le.constructor,Xh=ye.constructor;Kh==Xh||!("constructor"in le)||!("constructor"in ye)||typeof Kh=="function"&&Kh instanceof Kh&&typeof Xh=="function"&&Xh instanceof Xh||(qh=false);}return wr.delete(le),wr.delete(ye),qh})($,q,et,lt,Et,wt))})(u,g,S,k,jl,F))}function jd(u,g,S,k){var F=S.length,$=F,q=!k;if(u==null)return !$;for(u=mn(u);F--;){var et=S[F];if(q&&et[2]?et[1]!==u[et[0]]:!(et[0]in u))return false}for(;++F<$;){var lt=(et=S[F])[0],Et=u[lt],wt=et[1];if(q&&et[2]){if(Et===i&&!(lt in u))return false}else {var Mt=new Hr;if(k)var Yt=k(Et,wt,lt,u,g,Mt);if(!(Yt===i?jl(wt,Et,3,k,Mt):Yt))return false}}return true}function Os(u){return !(!Bn(u)||(g=u,Yf&&Yf in g))&&($r(u)?Qf:Lt).test(ra(u));var g;}function Vd(u){return typeof u=="function"?u:u==null?b:typeof u=="object"?ge(u)?Wd(u[0],u[1]):Hd(u):J(u)}function ou(u){if(!eo(u))return Sr(u);var g=[];for(var S in mn(u))an.call(u,S)&&S!="constructor"&&g.push(S);return g}function zd(u,g){return u<g}function oh(u,g){var S=-1,k=Ur(u)?Ht(u.length):[];return Xo(u,(function(F,$,q){k[++S]=g(F,$,q);})),k}function Hd(u){var g=Na(u);return g.length==1&&g[0][2]?no(g[0][0],g[0][1]):function(S){return S===u||jd(S,u,g)}}function Wd(u,g){return Ua(u)&&Yl(g)?no(Ln(u),g):function(S){var k=Du(S,u);return k===i&&k===g?Au(S,u):jl(g,k,3)}}function Rs(u,g,S,k,F){u!==g&&ru(g,(function($,q){if(F||(F=new Hr),Bn($))(function(lt,Et,wt,Mt,Yt,Qt,oe){var Ft=Ql(lt,wt),Ut=Ql(Et,wt),ie=oe.get(Ut);if(ie)Ud(lt,wt,ie);else {var Xt=Qt?Qt(Ft,Ut,wt+"",lt,Et,oe):i,he=Xt===i;if(he){var Pe=ge(Ut),Ge=!Pe&&Do(Ut),le=!Pe&&!Ge&&qs(Ut);Xt=Ut,Pe||Ge||le?ge(Ft)?Xt=Ft:Vn(Ft)?Xt=mr(Ft):Ge?(he=false,Xt=mh(Ut,true)):le?(he=false,Xt=ta(Ut,true)):Xt=[]:nc(Ut)||mi(Ut)?(Xt=Ft,mi(Ft)?Xt=gi(Ft):Bn(Ft)&&!$r(Ft)||(Xt=Ba(Ut))):he=false;}he&&(oe.set(Ut,Xt),Yt(Xt,Ut,Mt,Qt,oe),oe.delete(Ut)),Ud(lt,wt,Xt);}})(u,g,q,S,Rs,k,F);else {var et=k?k(Ql(u,q),$,q+"",u,g,F):i;et===i&&(et=$),Ud(u,q,et);}}),Wr);}function Vl(u,g){var S=u.length;if(S)return Br(g+=g<0?S:0,S)?u[g]:i}function qd(u,g,S){g=g.length?We(g,(function($){return ge($)?function(q){return Mi(q,$.length===1?$[0]:$)}:$})):[b];var k=-1;g=We(g,zr(ue()));var F=oh(u,(function($,q,et){var lt=We(g,(function(Et){return Et($)}));return {criteria:lt,index:++k,value:$}}));return (function($,q){var et=$.length;for($.sort((function(lt,Et){return (function(wt,Mt,Yt){for(var Qt=-1,oe=wt.criteria,Ft=Mt.criteria,Ut=oe.length,ie=Yt.length;++Qt<Ut;){var Xt=gh(oe[Qt],Ft[Qt]);if(Xt)return Qt>=ie?Xt:Xt*(Yt[Qt]=="desc"?-1:1)}return wt.index-Mt.index})(lt,Et,S)}));et--;)$[et]=$[et].value;return $})(F)}function Yd(u,g,S){for(var k=-1,F=g.length,$={};++k<F;){var q=g[k],et=Mi(u,q);S(et,q)&&Fs($,Xe(q,u),et);}return $}function au(u,g,S,k){var F=k?te:Dr,$=-1,q=g.length,et=u;for(u===g&&(g=mr(g)),S&&(et=We(u,zr(S)));++$<q;)for(var lt=0,Et=g[$],wt=S?S(Et):Et;(lt=F(et,wt,lt,k))>-1;)et!==u&&Qc.call(et,lt,1),Qc.call(u,lt,1);return u}function su(u,g){for(var S=u?g.length:0,k=S-1;S--;){var F=g[S];if(S==k||F!==$){var $=F;Br(F)?Qc.call(u,F,1):Jd(u,F);}}return u}function Qd(u,g){return u+Xc(Al()*(g-u+1))}function lu(u,g){var S="";if(!u||g<1||g>P)return S;do g%2&&(S+=u),(g=Xc(g/2))&&(u+=u);while(g);return S}function Ie(u,g){return io($a(u,g,b),u+"")}function ah(u){return Bd(Oo(u))}function Ky(u,g){var S=Oo(u);return xu(S,xo(g,0,S.length))}function Fs(u,g,S,k){if(!Bn(u))return u;for(var F=-1,$=(g=Xe(g,u)).length,q=$-1,et=u;et!=null&&++F<$;){var lt=Ln(g[F]),Et=S;if(lt==="__proto__"||lt==="constructor"||lt==="prototype")return u;if(F!=q){var wt=et[lt];(Et=k?k(wt,lt,et):i)===i&&(Et=Bn(wt)?wt:Br(g[F+1])?[]:{});}Nl(et,lt,Et),et=et[lt];}return u}var Kd=Qo?function(u,g){return Qo.set(u,g),u}:b,sh=Kc?function(u,g){return Kc(u,"toString",{configurable:true,enumerable:false,value:d(g),writable:true})}:b;function lh(u){return xu(Oo(u))}function Zr(u,g,S){var k=-1,F=u.length;g<0&&(g=-g>F?0:F+g),(S=S>F?F:S)<0&&(S+=F),F=g>S?0:S-g>>>0,g>>>=0;for(var $=Ht(F);++k<F;)$[k]=u[k+g];return $}function Xd(u,g){var S;return Xo(u,(function(k,F,$){return !(S=g(k,F,$))})),!!S}function cu(u,g,S){var k=0,F=u==null?k:u.length;if(typeof g=="number"&&g==g&&F<=2147483647){for(;k<F;){var $=k+F>>>1,q=u[$];q!==null&&!Fr(q)&&(S?q<=g:q<g)?k=$+1:F=$;}return F}return Zd(u,g,b,S)}function Zd(u,g,S,k){var F=0,$=u==null?0:u.length;if($===0)return 0;for(var q=(g=S(g))!=g,et=g===null,lt=Fr(g),Et=g===i;F<$;){var wt=Xc((F+$)/2),Mt=S(u[wt]),Yt=Mt!==i,Qt=Mt===null,oe=Mt==Mt,Ft=Fr(Mt);if(q)var Ut=k||oe;else Ut=Et?oe&&(k||Yt):et?oe&&Yt&&(k||!Qt):lt?oe&&Yt&&!Qt&&(k||!Ft):!Qt&&!Ft&&(k?Mt<=g:Mt<g);Ut?F=wt+1:$=wt;}return Ar($,4294967294)}function ch(u,g){for(var S=-1,k=u.length,F=0,$=[];++S<k;){var q=u[S],et=g?g(q):q;if(!S||!Rr(et,lt)){var lt=et;$[F++]=q===0?0:q;}}return $}function uh(u){return typeof u=="number"?u:Fr(u)?x:+u}function Jr(u){if(typeof u=="string")return u;if(ge(u))return We(u,Jr)+"";if(Fr(u))return tu?tu.call(u):"";var g=u+"";return g=="0"&&1/u==-1/0?"-0":g}function Zo(u,g,S){var k=-1,F=jc,$=u.length,q=true,et=[],lt=et;if(S)q=false,F=Vc;else if($>=200){var Et=g?null:Xy(u);if(Et)return qc(Et);q=false,F=Ta,lt=new Po;}else lt=g?[]:et;t:for(;++k<$;){var wt=u[k],Mt=g?g(wt):wt;if(wt=S||wt!==0?wt:0,q&&Mt==Mt){for(var Yt=lt.length;Yt--;)if(lt[Yt]===Mt)continue t;g&&lt.push(Mt),et.push(wt);}else F(lt,Mt,S)||(lt!==et&&lt.push(Mt),et.push(wt));}return et}function Jd(u,g){return (u=Ch(u,g=Xe(g,u)))==null||delete u[Ln(hi(g))]}function dh(u,g,S,k){return Fs(u,g,S(Mi(u,g)),k)}function Ji(u,g,S,k){for(var F=u.length,$=k?F:-1;(k?$--:++$<F)&&g(u[$],$,u););return S?Zr(u,k?0:$,k?$+1:F):Zr(u,k?$+1:0,k?F:$)}function ph(u,g){var S=u;return S instanceof Re&&(S=S.value()),_l(g,(function(k,F){return F.func.apply(F.thisArg,Ho([k],F.args))}),S)}function uu(u,g,S){var k=u.length;if(k<2)return k?Zo(u[0]):[];for(var F=-1,$=Ht(k);++F<k;)for(var q=u[F],et=-1;++et<k;)et!=F&&($[F]=Fa($[F]||q,u[et],g,S));return Zo(hr($,1),g,S)}function fh(u,g,S){for(var k=-1,F=u.length,$=g.length,q={};++k<F;){var et=k<$?g[k]:i;S(q,u[k],et);}return q}function tp(u){return Vn(u)?u:[]}function zl(u){return typeof u=="function"?u:b}function Xe(u,g){return ge(u)?u:Ua(u,g)?[u]:sp(qe(u))}var hh=Ie;function Jo(u,g,S){var k=u.length;return S=S===i?k:S,!g&&S>=k?u:Zr(u,g,S)}var Ms=Kf||function(u){return on.clearTimeout(u)};function mh(u,g){if(g)return u.slice();var S=u.length,k=Ad?Ad(S):new u.constructor(S);return u.copy(k),k}function du(u){var g=new u.constructor(u.byteLength);return new kl(g).set(new kl(u)),g}function ta(u,g){var S=g?du(u.buffer):u.buffer;return new u.constructor(S,u.byteOffset,u.length)}function gh(u,g){if(u!==g){var S=u!==i,k=u===null,F=u==u,$=Fr(u),q=g!==i,et=g===null,lt=g==g,Et=Fr(g);if(!et&&!Et&&!$&&u>g||$&&q&&lt&&!et&&!Et||k&&q&&lt||!S&&lt||!F)return 1;if(!k&&!$&&!Et&&u<g||Et&&S&&F&&!k&&!$||et&&S&&F||!q&&F||!lt)return -1}return 0}function ti(u,g,S,k){for(var F=-1,$=u.length,q=S.length,et=-1,lt=g.length,Et=Xn($-q,0),wt=Ht(lt+Et),Mt=!k;++et<lt;)wt[et]=g[et];for(;++F<q;)(Mt||F<$)&&(wt[S[F]]=u[F]);for(;Et--;)wt[et++]=u[F++];return wt}function Ns(u,g,S,k){for(var F=-1,$=u.length,q=-1,et=S.length,lt=-1,Et=g.length,wt=Xn($-et,0),Mt=Ht(wt+Et),Yt=!k;++F<wt;)Mt[F]=u[F];for(var Qt=F;++lt<Et;)Mt[Qt+lt]=g[lt];for(;++q<et;)(Yt||F<$)&&(Mt[Qt+S[q]]=u[F++]);return Mt}function mr(u,g){var S=-1,k=u.length;for(g||(g=Ht(k));++S<k;)g[S]=u[S];return g}function fi(u,g,S,k){var F=!S;S||(S={});for(var $=-1,q=g.length;++$<q;){var et=g[$],lt=k?k(S[et],u[et],et,S,u):i;lt===i&&(lt=u[et]),F?Xi(S,et,lt):Nl(S,et,lt);}return S}function pu(u,g){return function(S,k){var F=ge(S)?Kt:Is,$=g?g():{};return F(S,u,ue(k,2),$)}}function Ls(u){return Ie((function(g,S){var k=-1,F=S.length,$=F>1?S[F-1]:i,q=F>2?S[2]:i;for($=u.length>3&&typeof $=="function"?(F--,$):i,q&&_r(S[0],S[1],q)&&($=F<3?i:$,F=1),g=mn(g);++k<F;){var et=S[k];et&&u(g,et,k,$);}return g}))}function yh(u,g){return function(S,k){if(S==null)return S;if(!Ur(S))return u(S,k);for(var F=S.length,$=g?F:-1,q=mn(S);(g?$--:++$<F)&&k(q[$],$,q)!==false;);return S}}function fu(u){return function(g,S,k){for(var F=-1,$=mn(g),q=k(g),et=q.length;et--;){var lt=q[u?et:++F];if(S($[lt],lt,$)===false)break}return g}}function bh(u){return function(g){var S=Nn(g=qe(g))?Qr(g):i,k=S?S[0]:g.charAt(0),F=S?Jo(S,1).join(""):g.slice(1);return k[u]()+F}}function _n(u){return function(g){return _l(f(de(g).replace(hn,"")),u,"")}}function Bs(u){return function(){var g=arguments;switch(g.length){case 0:return new u;case 1:return new u(g[0]);case 2:return new u(g[0],g[1]);case 3:return new u(g[0],g[1],g[2]);case 4:return new u(g[0],g[1],g[2],g[3]);case 5:return new u(g[0],g[1],g[2],g[3],g[4]);case 6:return new u(g[0],g[1],g[2],g[3],g[4],g[5]);case 7:return new u(g[0],g[1],g[2],g[3],g[4],g[5],g[6])}var S=Oa(u.prototype),k=u.apply(S,g);return Bn(k)?k:S}}function ep(u){return function(g,S,k){var F=mn(g);if(!Ur(g)){var $=ue(S,3);g=Zn(g),S=function(et){return $(F[et],et,F)};}var q=u(g,S,k);return q>-1?F[$?g[q]:q]:i}}function Ma(u){return Ni((function(g){var S=g.length,k=S,F=Xr.prototype.thru;for(u&&g.reverse();k--;){var $=g[k];if(typeof $!="function")throw new Kr(o);if(F&&!q&&Cu($)=="wrapper")var q=new Xr([],true);}for(k=q?k:S;++k<S;){var et=Cu($=g[k]),lt=et=="wrapper"?vu($):i;q=lt&&Su(lt[0])&&lt[1]==424&&!lt[4].length&&lt[9]==1?q[Cu(lt[0])].apply(q,lt[3]):$.length==1&&Su($)?q[et]():q.thru($);}return function(){var Et=arguments,wt=Et[0];if(q&&Et.length==1&&ge(wt))return q.plant(wt).value();for(var Mt=0,Yt=S?g[Mt].apply(this,Et):wt;++Mt<S;)Yt=g[Mt].call(this,Yt);return Yt}}))}function Hl(u,g,S,k,F,$,q,et,lt,Et){var wt=g&h,Mt=1&g,Yt=2&g,Qt=24&g,oe=512&g,Ft=Yt?i:Bs(u);return function Ut(){for(var ie=arguments.length,Xt=Ht(ie),he=ie;he--;)Xt[he]=arguments[he];if(Qt)var Pe=ea(Ut),Ge=Gf(Xt,Pe);if(k&&(Xt=ti(Xt,k,F,Qt)),$&&(Xt=Ns(Xt,$,q,Qt)),ie-=Ge,Qt&&ie<Et){var le=Wo(Xt,Pe);return wo(u,g,Hl,Ut.placeholder,S,Xt,le,et,lt,Et-ie)}var ye=Mt?S:this,Tr=Yt?ye[u]:u;return ie=Xt.length,et?Xt=Ga(Xt,et):oe&&ie>1&&Xt.reverse(),wt&&lt<ie&&(Xt.length=lt),this&&this!==on&&this instanceof Ut&&(Tr=Ft||Bs(Tr)),Tr.apply(ye,Xt)}}function np(u,g){return function(S,k){return (function(F,$,q,et){return Fi(F,(function(lt,Et,wt){$(et,q(lt),Et,wt);})),et})(S,u,g(k),{})}}function _o(u,g){return function(S,k){var F;if(S===i&&k===i)return g;if(S!==i&&(F=S),k!==i){if(F===i)return k;typeof S=="string"||typeof k=="string"?(S=Jr(S),k=Jr(k)):(S=uh(S),k=uh(k)),F=u(S,k);}return F}}function hu(u){return Ni((function(g){return g=We(g,zr(ue())),Ie((function(S){var k=this;return u(g,(function(F){return nr(F,k,S)}))}))}))}function To(u,g){var S=(g=g===i?" ":Jr(g)).length;if(S<2)return S?lu(g,u):g;var k=lu(g,Dl(u/qo(g)));return Nn(g)?Jo(Qr(k),0,u).join(""):k.slice(0,u)}function mu(u){return function(g,S,k){return k&&typeof k!="number"&&_r(g,S,k)&&(S=k=i),g=Ao(g),S===i?(S=g,g=0):S=Ao(S),(function(F,$,q,et){for(var lt=-1,Et=Xn(Dl(($-F)/(q||1)),0),wt=Ht(Et);Et--;)wt[et?Et:++lt]=F,F+=q;return wt})(g,S,k=k===i?g<S?1:-1:Ao(k),u)}}function Us(u){return function(g,S){return typeof g=="string"&&typeof S=="string"||(g=ei(g),S=ei(S)),u(g,S)}}function wo(u,g,S,k,F,$,q,et,lt,Et){var wt=8&g;g|=wt?p:64,4&(g&=~(wt?64:p))||(g&=-4);var Mt=[u,g,F,wt?$:i,wt?q:i,wt?i:$,wt?i:q,et,lt,Et],Yt=S.apply(i,Mt);return Su(u)&&Or(Yt,Mt),Yt.placeholder=k,ap(Yt,u,g)}function Wl(u){var g=Oi[u];return function(S,k){if(S=ei(S),(k=k==null?0:Ar(we(k),292))&&Xf(S)){var F=(qe(S)+"e").split("e");return +((F=(qe(g(F[0]+"e"+(+F[1]+k)))+"e").split("e"))[0]+"e"+(+F[1]-k))}return g(S)}}var Xy=Ts&&1/qc(new Ts([,-0]))[1]==v?function(u){return new Ts(u)}:M;function $s(u){return function(g){var S=Er(g);return S==nt?Tl(g):S==Y?Vf(g):(function(k,F){return We(F,(function($){return [$,k[$]]}))})(g,u(g))}}function to(u,g,S,k,F,$,q,et){var lt=2&g;if(!lt&&typeof u!="function")throw new Kr(o);var Et=k?k.length:0;if(Et||(g&=-97,k=F=i),q=q===i?q:Xn(we(q),0),et=et===i?et:we(et),Et-=F?F.length:0,64&g){var wt=k,Mt=F;k=F=i;}var Yt=lt?i:vu(u),Qt=[u,g,S,k,F,wt,Mt,$,q,et];if(Yt&&(function(Ft,Ut){var ie=Ft[1],Xt=Ut[1],he=ie|Xt,Pe=he<131,Ge=Xt==h&&ie==8||Xt==h&&ie==256&&Ft[7].length<=Ut[8]||Xt==384&&Ut[7].length<=Ut[8]&&ie==8;if(!Pe&&!Ge)return Ft;1&Xt&&(Ft[2]=Ut[2],he|=1&ie?0:4);var le=Ut[3];if(le){var ye=Ft[3];Ft[3]=ye?ti(ye,le,Ut[4]):le,Ft[4]=ye?Wo(Ft[3],c):Ut[4];}(le=Ut[5])&&(ye=Ft[5],Ft[5]=ye?Ns(ye,le,Ut[6]):le,Ft[6]=ye?Wo(Ft[5],c):Ut[6]),(le=Ut[7])&&(Ft[7]=le),Xt&h&&(Ft[8]=Ft[8]==null?Ut[8]:Ar(Ft[8],Ut[8])),Ft[9]==null&&(Ft[9]=Ut[9]),Ft[0]=Ut[0],Ft[1]=he;})(Qt,Yt),u=Qt[0],g=Qt[1],S=Qt[2],k=Qt[3],F=Qt[4],!(et=Qt[9]=Qt[9]===i?lt?0:u.length:Xn(Qt[9]-Et,0))&&24&g&&(g&=-25),g&&g!=1)oe=g==8||g==16?(function(Ft,Ut,ie){var Xt=Bs(Ft);return function he(){for(var Pe=arguments.length,Ge=Ht(Pe),le=Pe,ye=ea(he);le--;)Ge[le]=arguments[le];var Tr=Pe<3&&Ge[0]!==ye&&Ge[Pe-1]!==ye?[]:Wo(Ge,ye);return (Pe-=Tr.length)<ie?wo(Ft,Ut,Hl,he.placeholder,i,Ge,Tr,i,i,ie-Pe):nr(this&&this!==on&&this instanceof he?Xt:Ft,this,Ge)}})(u,g,et):g!=p&&g!=33||F.length?Hl.apply(i,Qt):(function(Ft,Ut,ie,Xt){var he=1&Ut,Pe=Bs(Ft);return function Ge(){for(var le=-1,ye=arguments.length,Tr=-1,Bi=Xt.length,sa=Ht(Bi+ye),wr=this&&this!==on&&this instanceof Ge?Pe:Ft;++Tr<Bi;)sa[Tr]=Xt[Tr];for(;ye--;)sa[Tr++]=arguments[++le];return nr(wr,he?ie:this,sa)}})(u,g,S,k);else var oe=(function(Ft,Ut,ie){var Xt=1&Ut,he=Bs(Ft);return function Pe(){return (this&&this!==on&&this instanceof Pe?he:Ft).apply(Xt?ie:this,arguments)}})(u,g,S);return ap((Yt?Kd:Or)(oe,Qt),u,g)}function gu(u,g,S,k){return u===i||Rr(u,wa[S])&&!an.call(k,S)?g:u}function xr(u,g,S,k,F,$){return Bn(u)&&Bn(g)&&($.set(g,u),Rs(u,g,i,xr,$),$.delete(g)),u}function rp(u){return nc(u)?i:u}function ip(u,g,S,k,F,$){var q=1&S,et=u.length,lt=g.length;if(et!=lt&&!(q&&lt>et))return false;var Et=$.get(u),wt=$.get(g);if(Et&&wt)return Et==g&&wt==u;var Mt=-1,Yt=true,Qt=2&S?new Po:i;for($.set(u,g),$.set(g,u);++Mt<et;){var oe=u[Mt],Ft=g[Mt];if(k)var Ut=q?k(Ft,oe,Mt,g,u,$):k(oe,Ft,Mt,u,g,$);if(Ut!==i){if(Ut)continue;Yt=false;break}if(Qt){if(!zc(g,(function(ie,Xt){if(!Ta(Qt,Xt)&&(oe===ie||F(oe,ie,S,k,$)))return Qt.push(Xt)}))){Yt=false;break}}else if(oe!==Ft&&!F(oe,Ft,S,k,$)){Yt=false;break}}return $.delete(u),$.delete(g),Yt}function Ni(u){return io($a(u,i,Tn),u+"")}function yu(u){return Ul(u,Zn,Gs)}function bu(u){return Ul(u,Wr,op)}var vu=Qo?function(u){return Qo.get(u)}:M;function Cu(u){for(var g=u.name+"",S=Ri[g],k=an.call(Ri,g)?S.length:0;k--;){var F=S[k],$=F.func;if($==null||$==u)return F.name}return g}function ea(u){return (an.call(L,"placeholder")?L:u).placeholder}function ue(){var u=L.iteratee||E;return u=u===E?Vd:u,arguments.length?u(arguments[0],arguments[1]):u}function ql(u,g){var S,k,F=u.__data__;return ((k=typeof(S=g))=="string"||k=="number"||k=="symbol"||k=="boolean"?S!=="__proto__":S===null)?F[typeof g=="string"?"string":"hash"]:F.map}function Na(u){for(var g=Zn(u),S=g.length;S--;){var k=g[S],F=u[k];g[S]=[k,F,Yl(F)];}return g}function La(u,g){var S=(function(k,F){return k==null?i:k[F]})(u,g);return Os(S)?S:i}var Gs=Zc?function(u){return u==null?[]:(u=mn(u),xt(Zc(u),(function(g){return Es.call(u,g)})))}:Rt,op=Zc?function(u){for(var g=[];u;)Ho(g,Gs(u)),u=un(u);return g}:Rt,Er=Pr;function Fe(u,g,S){for(var k=-1,F=(g=Xe(g,u)).length,$=false;++k<F;){var q=Ln(g[k]);if(!($=u!=null&&S(u,q)))break;u=u[q];}return $||++k!=F?$:!!(F=u==null?0:u.length)&&Ws(F)&&Br(q,F)&&(ge(u)||mi(u))}function Ba(u){return typeof u.constructor!="function"||eo(u)?{}:Oa(un(u))}function vh(u){return ge(u)||mi(u)||!!(Od&&u&&u[Od])}function Br(u,g){var S=typeof u;return !!(g=g==null?P:g)&&(S=="number"||S!="symbol"&&Nt.test(u))&&u>-1&&u%1==0&&u<g}function _r(u,g,S){if(!Bn(S))return false;var k=typeof g;return !!(k=="number"?Ur(S)&&Br(g,S.length):k=="string"&&g in S)&&Rr(S[g],u)}function Ua(u,g){if(ge(u))return false;var S=typeof u;return !(S!="number"&&S!="symbol"&&S!="boolean"&&u!=null&&!Fr(u))||ar.test(u)||!bt.test(u)||g!=null&&u in mn(g)}function Su(u){var g=Cu(u),S=L[g];if(typeof S!="function"||!(g in Re.prototype))return false;if(u===S)return true;var k=vu(S);return !!k&&u===k[0]}(Jc&&Er(new Jc(new ArrayBuffer(1)))!=Ct||Ol&&Er(new Ol)!=nt||_s&&Er(_s.resolve())!=j||Ts&&Er(new Ts)!=Y||Aa&&Er(new Aa)!=dt)&&(Er=function(u){var g=Pr(u),S=g==U?u.constructor:i,k=S?ra(S):"";if(k)switch(k){case Zf:return Ct;case Yy:return nt;case Jf:return j;case Qy:return Y;case Ko:return dt}return g});var Zy=Il?$r:Zt;function eo(u){var g=u&&u.constructor;return u===(typeof g=="function"&&g.prototype||wa)}function Yl(u){return u==u&&!Bn(u)}function no(u,g){return function(S){return S!=null&&S[u]===g&&(g!==i||u in mn(S))}}function $a(u,g,S){return g=Xn(g===i?u.length-1:g,0),function(){for(var k=arguments,F=-1,$=Xn(k.length-g,0),q=Ht($);++F<$;)q[F]=k[g+F];F=-1;for(var et=Ht(g+1);++F<g;)et[F]=k[F];return et[g]=S(q),nr(u,this,et)}}function Ch(u,g){return g.length<2?u:Mi(u,Zr(g,0,-1))}function Ga(u,g){for(var S=u.length,k=Ar(g.length,S),F=mr(u);k--;){var $=g[k];u[k]=Br($,S)?F[$]:i;}return u}function Ql(u,g){if((g!=="constructor"||typeof u[g]!="function")&&g!="__proto__")return u[g]}var Or=Pu(Kd),ro=Wy||function(u,g){return on.setTimeout(u,g)},io=Pu(sh);function ap(u,g,S){var k=g+"";return io(u,(function(F,$){var q=$.length;if(!q)return F;var et=q-1;return $[et]=(q>1?"& ":"")+$[et],$=$.join(q>2?", ":" "),F.replace(jr,`{
2304
2304
  /* [wrapped with `+$+`] */
2305
- `)})(k,(function(R,$){return Wt(I,(function(q){var et="_."+q[0];$&q[1]&&!jc(R,et)&&R.push(et);})),R.sort()})((function(R){var $=R.match(Co);return $?$[1].split(Ce):[]})(k),S)))}function Pu(u){var g=0,S=0;return function(){var k=Nd(),R=16-(k-S);if(S=k,R>0){if(++g>=800)return arguments[0]}else g=0;return u.apply(i,arguments)}}function xu(u,g){var S=-1,k=u.length,R=k-1;for(g=g===i?k:g;++S<g;){var $=Qd(S,R),q=u[$];u[$]=u[S],u[S]=q;}return u.length=g,u}var na,js,sp=(na=Jl((function(u){var g=[];return u.charCodeAt(0)===46&&g.push(""),u.replace(sr,(function(S,k,R,$){g.push(R?$.replace(ot,"$1"):k||S);})),g}),(function(u){return js.size===500&&js.clear(),u})),js=na.cache,na);function Ln(u){if(typeof u=="string"||Fr(u))return u;var g=u+"";return g=="0"&&1/u==-1/0?"-0":g}function ra(u){if(u!=null){try{return Ss.call(u)}catch(g){}try{return u+""}catch(g){}}return ""}function Io(u){if(u instanceof Re)return u.clone();var g=new Xr(u.__wrapped__,u.__chain__);return g.__actions__=mr(u.__actions__),g.__index__=u.__index__,g.__values__=u.__values__,g}var lp=Ie((function(u,g){return Vn(u)?Fa(u,hr(g,1,Vn,true)):[]})),Sh=Ie((function(u,g){var S=hi(g);return Vn(S)&&(S=i),Vn(u)?Fa(u,hr(g,1,Vn,true),ue(S,2)):[]})),ia=Ie((function(u,g){var S=hi(g);return Vn(S)&&(S=i),Vn(u)?Fa(u,hr(g,1,Vn,true),i,S):[]}));function Eu(u,g,S){var k=u==null?0:u.length;if(!k)return -1;var R=S==null?0:we(S);return R<0&&(R=Xn(k+R,0)),Hc(u,ue(g,3),R)}function _u(u,g,S){var k=u==null?0:u.length;if(!k)return -1;var R=k-1;return S!==i&&(R=we(S),R=S<0?Xn(k+R,0):Ar(R,k-1)),Hc(u,ue(g,3),R,true)}function Tn(u){return u!=null&&u.length?hr(u,1):[]}function Vs(u){return u&&u.length?u[0]:i}var Ph=Ie((function(u){var g=We(u,tp);return g.length&&g[0]===u[0]?Gl(g):[]})),ja=Ie((function(u){var g=hi(u),S=We(u,tp);return g===hi(S)?g=i:S.pop(),S.length&&S[0]===u[0]?Gl(S,ue(g,2)):[]})),Li=Ie((function(u){var g=hi(u),S=We(u,tp);return (g=typeof g=="function"?g:i)&&S.pop(),S.length&&S[0]===u[0]?Gl(S,i,g):[]}));function hi(u){var g=u==null?0:u.length;return g?u[g-1]:i}var Jy=Ie(Kl);function Kl(u,g){return u&&u.length&&g&&g.length?au(u,g):u}var Tu=Ni((function(u,g){var S=u==null?0:u.length,k=Bl(u,g);return su(u,We(g,(function(R){return Br(R,S)?+R:R})).sort(gh)),k}));function Xl(u){return u==null?u:qy.call(u)}var xh=Ie((function(u){return Zo(hr(u,1,Vn,true))})),cp=Ie((function(u){var g=hi(u);return Vn(g)&&(g=i),Zo(hr(u,1,Vn,true),ue(g,2))})),up=Ie((function(u){var g=hi(u);return g=typeof g=="function"?g:i,Zo(hr(u,1,Vn,true),i,g)}));function ko(u){if(!u||!u.length)return [];var g=0;return u=xt(u,(function(S){if(Vn(S))return g=Xn(S.length,g),true})),Ed(g,(function(S){return We(u,bs(S))}))}function dp(u,g){if(!u||!u.length)return [];var S=ko(u);return g==null?S:We(S,(function(k){return nr(g,i,k)}))}var pp=Ie((function(u,g){return Vn(u)?Fa(u,g):[]})),Eh=Ie((function(u){return uu(xt(u,Vn))})),fp=Ie((function(u){var g=hi(u);return Vn(g)&&(g=i),uu(xt(u,Vn),ue(g,2))})),hp=Ie((function(u){var g=hi(u);return g=typeof g=="function"?g:i,uu(xt(u,Vn),i,g)})),tb=Ie(ko),eb=Ie((function(u){var g=u.length,S=g>1?u[g-1]:i;return S=typeof S=="function"?(u.pop(),S):i,dp(u,S)}));function wu(u){var g=L(u);return g.__chain__=true,g}function zs(u,g){return g(u)}var nb=Ni((function(u){var g=u.length,S=g?u[0]:0,k=this.__wrapped__,R=function($){return Bl($,u)};return !(g>1||this.__actions__.length)&&k instanceof Re&&Br(S)?((k=k.slice(S,+S+(g?1:0))).__actions__.push({func:zs,args:[R],thisArg:i}),new Xr(k,this.__chain__).thru((function($){return g&&!$.length&&$.push(i),$}))):this.thru(R)})),rb=pu((function(u,g,S){an.call(u,S)?++u[S]:Xi(u,S,1);})),mp=ep(Eu),_h=ep(_u);function Th(u,g){return (ge(u)?Wt:Xo)(u,ue(g,3))}function Va(u,g){return (ge(u)?Tt:nh)(u,ue(g,3))}var oa=pu((function(u,g,S){an.call(u,S)?u[S].push(g):Xi(u,S,[g]);})),ib=Ie((function(u,g,S){var k=-1,R=typeof g=="function",$=Ur(u)?Ht(u.length):[];return Xo(u,(function(q){$[++k]=R?nr(g,q,S):As(q,g,S);})),$})),ob=pu((function(u,g,S){Xi(u,S,g);}));function Zl(u,g){return (ge(u)?We:oh)(u,ue(g,3))}var wh=pu((function(u,g,S){u[S?0:1].push(g);}),(function(){return [[],[]]})),Ih=Ie((function(u,g){if(u==null)return [];var S=g.length;return S>1&&_r(u,g[0],g[1])?g=[]:S>2&&_r(g[0],g[1],g[2])&&(g=[g[0]]),qd(u,hr(g,1),[])})),Iu=Rd||function(){return on.Date.now()};function Hs(u,g,S){return g=S?i:g,g=u&&g==null?u.length:g,to(u,h,i,i,i,i,g)}function gp(u,g){var S;if(typeof g!="function")throw new Kr(o);return u=we(u),function(){return --u>0&&(S=g.apply(this,arguments)),u<=1&&(g=i),S}}var yp=Ie((function(u,g,S){var k=1;if(S.length){var R=Wo(S,ea(yp));k|=p;}return to(u,k,g,S,R)})),kh=Ie((function(u,g,S){var k=3;if(S.length){var R=Wo(S,ea(kh));k|=p;}return to(g,k,u,S,R)}));function Dh(u,g,S){var k,R,$,q,et,lt,Et=0,wt=false,Mt=false,Yt=true;if(typeof u!="function")throw new Kr(o);function Qt(he){var Pe=k,Ge=R;return k=R=i,Et=he,q=u.apply(Ge,Pe)}function oe(he){return Et=he,et=ro(Ut,g),wt?Qt(he):q}function Ft(he){var Pe=he-lt;return lt===i||Pe>=g||Pe<0||Mt&&he-Et>=$}function Ut(){var he=Iu();if(Ft(he))return ie(he);et=ro(Ut,(function(Pe){var Ge=g-(Pe-lt);return Mt?Ar(Ge,$-(Pe-Et)):Ge})(he));}function ie(he){return et=i,Yt&&k?Qt(he):(k=R=i,q)}function Xt(){var he=Iu(),Pe=Ft(he);if(k=arguments,R=this,lt=he,Pe){if(et===i)return oe(lt);if(Mt)return Ms(et),et=ro(Ut,g),Qt(lt)}return et===i&&(et=ro(Ut,g)),q}return g=ei(g)||0,Bn(S)&&(wt=!!S.leading,$=(Mt="maxWait"in S)?Xn(ei(S.maxWait)||0,g):$,Yt="trailing"in S?!!S.trailing:Yt),Xt.cancel=function(){et!==i&&Ms(et),Et=0,k=lt=R=et=i;},Xt.flush=function(){return et===i?q:ie(Iu())},Xt}var ab=Ie((function(u,g){return $d(u,1,g)})),bp=Ie((function(u,g,S){return $d(u,ei(g)||0,S)}));function Jl(u,g){if(typeof u!="function"||g!=null&&typeof g!="function")throw new Kr(o);var S=function(){var k=arguments,R=g?g.apply(this,k):k[0],$=S.cache;if($.has(R))return $.get(R);var q=u.apply(this,k);return S.cache=$.set(R,q)||$,q};return S.cache=new(Jl.Cache||Ki),S}function aa(u){if(typeof u!="function")throw new Kr(o);return function(){var g=arguments;switch(g.length){case 0:return !u.call(this);case 1:return !u.call(this,g[0]);case 2:return !u.call(this,g[0],g[1]);case 3:return !u.call(this,g[0],g[1],g[2])}return !u.apply(this,g)}}Jl.Cache=Ki;var sb=hh((function(u,g){var S=(g=g.length==1&&ge(g[0])?We(g[0],zr(ue())):We(hr(g,1),zr(ue()))).length;return Ie((function(k){for(var R=-1,$=Ar(k.length,S);++R<$;)k[R]=g[R].call(this,k[R]);return nr(u,this,k)}))})),vp=Ie((function(u,g){var S=Wo(g,ea(vp));return to(u,p,i,g,S)})),Ah=Ie((function(u,g){var S=Wo(g,ea(Ah));return to(u,64,i,g,S)})),lb=Ni((function(u,g){return to(u,256,i,i,i,g)}));function Rr(u,g){return u===g||u!=u&&g!=g}var Oh=Us(iu),za=Us((function(u,g){return u>=g})),mi=Eo((function(){return arguments})())?Eo:function(u){return zn(u)&&an.call(u,"callee")&&!Es.call(u,"callee")},ge=Ht.isArray,Rh=Ai?zr(Ai):function(u){return zn(u)&&Pr(u)==mt};function Ur(u){return u!=null&&Ws(u.length)&&!$r(u)}function Vn(u){return zn(u)&&Ur(u)}var Do=Fd||Zt,Fh=er?zr(er):function(u){return zn(u)&&Pr(u)==N};function tc(u){if(!zn(u))return false;var g=Pr(u);return g==V||g=="[object DOMException]"||typeof u.message=="string"&&typeof u.name=="string"&&!nc(u)}function $r(u){if(!Bn(u))return false;var g=Pr(u);return g==G||g==X||g=="[object AsyncFunction]"||g=="[object Proxy]"}function ec(u){return typeof u=="number"&&u==we(u)}function Ws(u){return typeof u=="number"&&u>-1&&u%1==0&&u<=P}function Bn(u){var g=typeof u;return u!=null&&(g=="object"||g=="function")}function zn(u){return u!=null&&typeof u=="object"}var Mh=ys?zr(ys):function(u){return zn(u)&&Er(u)==nt};function Nh(u){return typeof u=="number"||zn(u)&&Pr(u)==st}function nc(u){if(!zn(u)||Pr(u)!=U)return false;var g=un(u);if(g===null)return true;var S=an.call(g,"constructor")&&g.constructor;return typeof S=="function"&&S instanceof S&&Ss.call(S)==Dd}var Cp=_a?zr(_a):function(u){return zn(u)&&Pr(u)==ut},Sp=zo?zr(zo):function(u){return zn(u)&&Er(u)==Y};function rr(u){return typeof u=="string"||!ge(u)&&zn(u)&&Pr(u)==at}function Fr(u){return typeof u=="symbol"||zn(u)&&Pr(u)==pt}var qs=Cr?zr(Cr):function(u){return zn(u)&&Ws(u.length)&&!!ae[Pr(u)]},Lh=Us(zd),Pp=Us((function(u,g){return u<=g}));function xp(u){if(!u)return [];if(Ur(u))return rr(u)?Qr(u):mr(u);if(ka&&u[ka])return (function(S){for(var k,R=[];!(k=S.next()).done;)R.push(k.value);return R})(u[ka]());var g=Er(u);return (g==nt?Tl:g==Y?qc:Oo)(u)}function Ao(u){return u?(u=ei(u))===v||u===-1/0?17976931348623157e292*(u<0?-1:1):u==u?u:0:u===0?u:0}function we(u){var g=Ao(u),S=g%1;return g==g?S?g-S:g:0}function Ep(u){return u?xo(we(u),0,T):0}function ei(u){if(typeof u=="number")return u;if(Fr(u))return x;if(Bn(u)){var g=typeof u.valueOf=="function"?u.valueOf():u;u=Bn(g)?g+"":g;}if(typeof u!="string")return u===0?u:+u;u=_d(u);var S=ft.test(u);return S||It.test(u)?Yi(u.slice(2),S?2:8):_t.test(u)?x:+u}function gi(u){return fi(u,Wr(u))}function qe(u){return u==null?"":Jr(u)}var Bh=Ls((function(u,g){if(eo(g)||Ur(g))fi(g,Zn(g),u);else for(var S in g)an.call(g,S)&&Nl(u,S,g[S]);})),Uh=Ls((function(u,g){fi(g,Wr(g),u);})),ku=Ls((function(u,g,S,k){fi(g,Wr(g),u,k);})),cb=Ls((function(u,g,S,k){fi(g,Zn(g),u,k);})),_p=Ni(Bl),$h=Ie((function(u,g){u=mn(u);var S=-1,k=g.length,R=k>2?g[2]:i;for(R&&_r(g[0],g[1],R)&&(k=1);++S<k;)for(var $=g[S],q=Wr($),et=-1,lt=q.length;++et<lt;){var Et=q[et],wt=u[Et];(wt===i||Rr(wt,wa[Et])&&!an.call(u,Et))&&(u[Et]=$[Et]);}return u})),Gh=Ie((function(u){return u.push(i,xr),nr(zh,i,u)}));function Du(u,g,S){var k=u==null?i:Mi(u,g);return k===i?S:k}function Au(u,g){return u!=null&&Fe(u,g,ih)}var jh=np((function(u,g,S){g!=null&&typeof g.toString!="function"&&(g=Ia.call(g)),u[g]=S;}),d(b)),Ys=np((function(u,g,S){g!=null&&typeof g.toString!="function"&&(g=Ia.call(g)),an.call(u,g)?u[g].push(S):u[g]=[S];}),ue),Vh=Ie(As);function Zn(u){return Ur(u)?eu(u):ou(u)}function Wr(u){return Ur(u)?eu(u,true):(function(g){if(!Bn(g))return (function($){var q=[];if($!=null)for(var et in mn($))q.push(et);return q})(g);var S=eo(g),k=[];for(var R in g)(R!="constructor"||!S&&an.call(g,R))&&k.push(R);return k})(u)}var ub=Ls((function(u,g,S){Rs(u,g,S);})),zh=Ls((function(u,g,S,k){Rs(u,g,S,k);})),Ou=Ni((function(u,g){var S={};if(u==null)return S;var k=false;g=We(g,(function($){return $=Xe($,u),k||(k=$.length>1),$})),fi(u,bu(u),S),k&&(S=pi(S,7,rp));for(var R=g.length;R--;)Jd(S,g[R]);return S})),Tp=Ni((function(u,g){return u==null?{}:(function(S,k){return Yd(S,k,(function(R,$){return Au(S,$)}))})(u,g)}));function wp(u,g){if(u==null)return {};var S=We(bu(u),(function(k){return [k]}));return g=ue(g),Yd(u,S,(function(k,R){return g(k,R[0])}))}var Ha=$s(Zn),vn=$s(Wr);function Oo(u){return u==null?[]:Wc(u,Zn(u))}var Hh=_n((function(u,g,S){return g=g.toLowerCase(),u+(S?Hn(g):g)}));function Hn(u){return Ru(qe(u).toLowerCase())}function de(u){return (u=qe(u))&&u.replace(se,zy).replace(pr,"")}var pe=_n((function(u,g,S){return u+(S?"-":"")+g.toLowerCase()})),Wh=_n((function(u,g,S){return u+(S?" ":"")+g.toLowerCase()})),db=bh("toLowerCase"),oo=_n((function(u,g,S){return u+(S?"_":"")+g.toLowerCase()})),gn=_n((function(u,g,S){return u+(S?" ":"")+Ru(g)})),yn=_n((function(u,g,S){return u+(S?" ":"")+g.toUpperCase()})),Ru=bh("toUpperCase");function f(u,g,S){return u=qe(u),(g=S?i:g)===i?(function(k){return So.test(k)})(u)?(function(k){return k.match(vt)||[]})(u):(function(k){return k.match(Vt)||[]})(u):u.match(g)||[]}var a=Ie((function(u,g){try{return nr(u,i,g)}catch(S){return tc(S)?S:new Ne(S)}})),l=Ni((function(u,g){return Wt(g,(function(S){S=Ln(S),Xi(u,S,yp(u[S],u));})),u}));function d(u){return function(){return u}}var m=Ma(),y=Ma(true);function b(u){return u}function E(u){return Vd(typeof u=="function"?u:pi(u,1))}var w=Ie((function(u,g){return function(S){return As(S,u,g)}})),D=Ie((function(u,g){return function(S){return As(u,S,g)}}));function _(u,g,S){var k=Zn(g),R=Ds(g,k);S!=null||Bn(g)&&(R.length||!k.length)||(S=g,g=u,u=this,R=Ds(g,Zn(g)));var $=!(Bn(S)&&"chain"in S&&!S.chain),q=$r(u);return Wt(R,(function(et){var lt=g[et];u[et]=lt,q&&(u.prototype[et]=function(){var Et=this.__chain__;if($||Et){var wt=u(this.__wrapped__),Mt=wt.__actions__=mr(this.__actions__);return Mt.push({func:lt,args:arguments,thisArg:u}),wt.__chain__=Et,wt}return lt.apply(u,Ho([this.value()],arguments))});})),u}function M(){}var B=hu(We),H=hu(kt),K=hu(zc);function J(u){return Ua(u)?bs(Ln(u)):(function(g){return function(S){return Mi(S,g)}})(u)}var tt=mu(),yt=mu(true);function Rt(){return []}function Zt(){return false}var zt,Bt=_o((function(u,g){return u+g}),0),qt=Wl("ceil"),$e=_o((function(u,g){return u/g}),1),fe=Wl("floor"),Oe=_o((function(u,g){return u*g}),1),An=Wl("round"),Mr=_o((function(u,g){return u-g}),0);return L.after=function(u,g){if(typeof g!="function")throw new Kr(o);return u=we(u),function(){if(--u<1)return g.apply(this,arguments)}},L.ary=Hs,L.assign=Bh,L.assignIn=Uh,L.assignInWith=ku,L.assignWith=cb,L.at=_p,L.before=gp,L.bind=yp,L.bindAll=l,L.bindKey=kh,L.castArray=function(){if(!arguments.length)return [];var u=arguments[0];return ge(u)?u:[u]},L.chain=wu,L.chunk=function(u,g,S){g=(S?_r(u,g,S):g===i)?1:Xn(we(g),0);var k=u==null?0:u.length;if(!k||g<1)return [];for(var R=0,$=0,q=Ht(Dl(k/g));R<k;)q[$++]=Zr(u,R,R+=g);return q},L.compact=function(u){for(var g=-1,S=u==null?0:u.length,k=0,R=[];++g<S;){var $=u[g];$&&(R[k++]=$);}return R},L.concat=function(){var u=arguments.length;if(!u)return [];for(var g=Ht(u-1),S=arguments[0],k=u;k--;)g[k-1]=arguments[k];return Ho(ge(S)?mr(S):[S],hr(g,1))},L.cond=function(u){var g=u==null?0:u.length,S=ue();return u=g?We(u,(function(k){if(typeof k[1]!="function")throw new Kr(o);return [S(k[0]),k[1]]})):[],Ie((function(k){for(var R=-1;++R<g;){var $=u[R];if(nr($[0],this,k))return nr($[1],this,k)}}))},L.conforms=function(u){return (function(g){var S=Zn(g);return function(k){return eh(k,g,S)}})(pi(u,1))},L.constant=d,L.countBy=rb,L.create=function(u,g){var S=Oa(u);return g==null?S:nu(S,g)},L.curry=function u(g,S,k){var R=to(g,8,i,i,i,i,i,S=k?i:S);return R.placeholder=u.placeholder,R},L.curryRight=function u(g,S,k){var R=to(g,16,i,i,i,i,i,S=k?i:S);return R.placeholder=u.placeholder,R},L.debounce=Dh,L.defaults=$h,L.defaultsDeep=Gh,L.defer=ab,L.delay=bp,L.difference=lp,L.differenceBy=Sh,L.differenceWith=ia,L.drop=function(u,g,S){var k=u==null?0:u.length;return k?Zr(u,(g=S||g===i?1:we(g))<0?0:g,k):[]},L.dropRight=function(u,g,S){var k=u==null?0:u.length;return k?Zr(u,0,(g=k-(g=S||g===i?1:we(g)))<0?0:g):[]},L.dropRightWhile=function(u,g){return u&&u.length?Ji(u,ue(g,3),true,true):[]},L.dropWhile=function(u,g){return u&&u.length?Ji(u,ue(g,3),true):[]},L.fill=function(u,g,S,k){var R=u==null?0:u.length;return R?(S&&typeof S!="number"&&_r(u,g,S)&&(S=0,k=R),(function($,q,et,lt){var Et=$.length;for((et=we(et))<0&&(et=-et>Et?0:Et+et),(lt=lt===i||lt>Et?Et:we(lt))<0&&(lt+=Et),lt=et>lt?0:Ep(lt);et<lt;)$[et++]=q;return $})(u,g,S,k)):[]},L.filter=function(u,g){return (ge(u)?xt:fr)(u,ue(g,3))},L.flatMap=function(u,g){return hr(Zl(u,g),1)},L.flatMapDeep=function(u,g){return hr(Zl(u,g),v)},L.flatMapDepth=function(u,g,S){return S=S===i?1:we(S),hr(Zl(u,g),S)},L.flatten=Tn,L.flattenDeep=function(u){return u!=null&&u.length?hr(u,v):[]},L.flattenDepth=function(u,g){return u!=null&&u.length?hr(u,g=g===i?1:we(g)):[]},L.flip=function(u){return to(u,512)},L.flow=m,L.flowRight=y,L.fromPairs=function(u){for(var g=-1,S=u==null?0:u.length,k={};++g<S;){var R=u[g];k[R[0]]=R[1];}return k},L.functions=function(u){return u==null?[]:Ds(u,Zn(u))},L.functionsIn=function(u){return u==null?[]:Ds(u,Wr(u))},L.groupBy=oa,L.initial=function(u){return u!=null&&u.length?Zr(u,0,-1):[]},L.intersection=Ph,L.intersectionBy=ja,L.intersectionWith=Li,L.invert=jh,L.invertBy=Ys,L.invokeMap=ib,L.iteratee=E,L.keyBy=ob,L.keys=Zn,L.keysIn=Wr,L.map=Zl,L.mapKeys=function(u,g){var S={};return g=ue(g,3),Fi(u,(function(k,R,$){Xi(S,g(k,R,$),k);})),S},L.mapValues=function(u,g){var S={};return g=ue(g,3),Fi(u,(function(k,R,$){Xi(S,R,g(k,R,$));})),S},L.matches=function(u){return Hd(pi(u,1))},L.matchesProperty=function(u,g){return Wd(u,pi(g,1))},L.memoize=Jl,L.merge=ub,L.mergeWith=zh,L.method=w,L.methodOf=D,L.mixin=_,L.negate=aa,L.nthArg=function(u){return u=we(u),Ie((function(g){return Vl(g,u)}))},L.omit=Ou,L.omitBy=function(u,g){return wp(u,aa(ue(g)))},L.once=function(u){return gp(2,u)},L.orderBy=function(u,g,S,k){return u==null?[]:(ge(g)||(g=g==null?[]:[g]),ge(S=k?i:S)||(S=S==null?[]:[S]),qd(u,g,S))},L.over=B,L.overArgs=sb,L.overEvery=H,L.overSome=K,L.partial=vp,L.partialRight=Ah,L.partition=wh,L.pick=Tp,L.pickBy=wp,L.property=J,L.propertyOf=function(u){return function(g){return u==null?i:Mi(u,g)}},L.pull=Jy,L.pullAll=Kl,L.pullAllBy=function(u,g,S){return u&&u.length&&g&&g.length?au(u,g,ue(S,2)):u},L.pullAllWith=function(u,g,S){return u&&u.length&&g&&g.length?au(u,g,i,S):u},L.pullAt=Tu,L.range=tt,L.rangeRight=yt,L.rearg=lb,L.reject=function(u,g){return (ge(u)?xt:fr)(u,aa(ue(g,3)))},L.remove=function(u,g){var S=[];if(!u||!u.length)return S;var k=-1,R=[],$=u.length;for(g=ue(g,3);++k<$;){var q=u[k];g(q,k,u)&&(S.push(q),R.push(k));}return su(u,R),S},L.rest=function(u,g){if(typeof u!="function")throw new Kr(o);return Ie(u,g=g===i?g:we(g))},L.reverse=Xl,L.sampleSize=function(u,g,S){return g=(S?_r(u,g,S):g===i)?1:we(g),(ge(u)?Ml:Ky)(u,g)},L.set=function(u,g,S){return u==null?u:Fs(u,g,S)},L.setWith=function(u,g,S,k){return k=typeof k=="function"?k:i,u==null?u:Fs(u,g,S,k)},L.shuffle=function(u){return (ge(u)?th:lh)(u)},L.slice=function(u,g,S){var k=u==null?0:u.length;return k?(S&&typeof S!="number"&&_r(u,g,S)?(g=0,S=k):(g=g==null?0:we(g),S=S===i?k:we(S)),Zr(u,g,S)):[]},L.sortBy=Ih,L.sortedUniq=function(u){return u&&u.length?ch(u):[]},L.sortedUniqBy=function(u,g){return u&&u.length?ch(u,ue(g,2)):[]},L.split=function(u,g,S){return S&&typeof S!="number"&&_r(u,g,S)&&(g=S=i),(S=S===i?T:S>>>0)?(u=qe(u))&&(typeof g=="string"||g!=null&&!Cp(g))&&!(g=Jr(g))&&Nn(u)?Jo(Qr(u),0,S):u.split(g,S):[]},L.spread=function(u,g){if(typeof u!="function")throw new Kr(o);return g=g==null?0:Xn(we(g),0),Ie((function(S){var k=S[g],R=Jo(S,0,g);return k&&Ho(R,k),nr(u,this,R)}))},L.tail=function(u){var g=u==null?0:u.length;return g?Zr(u,1,g):[]},L.take=function(u,g,S){return u&&u.length?Zr(u,0,(g=S||g===i?1:we(g))<0?0:g):[]},L.takeRight=function(u,g,S){var k=u==null?0:u.length;return k?Zr(u,(g=k-(g=S||g===i?1:we(g)))<0?0:g,k):[]},L.takeRightWhile=function(u,g){return u&&u.length?Ji(u,ue(g,3),false,true):[]},L.takeWhile=function(u,g){return u&&u.length?Ji(u,ue(g,3)):[]},L.tap=function(u,g){return g(u),u},L.throttle=function(u,g,S){var k=true,R=true;if(typeof u!="function")throw new Kr(o);return Bn(S)&&(k="leading"in S?!!S.leading:k,R="trailing"in S?!!S.trailing:R),Dh(u,g,{leading:k,maxWait:g,trailing:R})},L.thru=zs,L.toArray=xp,L.toPairs=Ha,L.toPairsIn=vn,L.toPath=function(u){return ge(u)?We(u,Ln):Fr(u)?[u]:mr(sp(qe(u)))},L.toPlainObject=gi,L.transform=function(u,g,S){var k=ge(u),R=k||Do(u)||qs(u);if(g=ue(g,4),S==null){var $=u&&u.constructor;S=R?k?new $:[]:Bn(u)&&$r($)?Oa(un(u)):{};}return (R?Wt:Fi)(u,(function(q,et,lt){return g(S,q,et,lt)})),S},L.unary=function(u){return Hs(u,1)},L.union=xh,L.unionBy=cp,L.unionWith=up,L.uniq=function(u){return u&&u.length?Zo(u):[]},L.uniqBy=function(u,g){return u&&u.length?Zo(u,ue(g,2)):[]},L.uniqWith=function(u,g){return g=typeof g=="function"?g:i,u&&u.length?Zo(u,i,g):[]},L.unset=function(u,g){return u==null||Jd(u,g)},L.unzip=ko,L.unzipWith=dp,L.update=function(u,g,S){return u==null?u:dh(u,g,zl(S))},L.updateWith=function(u,g,S,k){return k=typeof k=="function"?k:i,u==null?u:dh(u,g,zl(S),k)},L.values=Oo,L.valuesIn=function(u){return u==null?[]:Wc(u,Wr(u))},L.without=pp,L.words=f,L.wrap=function(u,g){return vp(zl(g),u)},L.xor=Eh,L.xorBy=fp,L.xorWith=hp,L.zip=tb,L.zipObject=function(u,g){return fh(u||[],g||[],Nl)},L.zipObjectDeep=function(u,g){return fh(u||[],g||[],Fs)},L.zipWith=eb,L.entries=Ha,L.entriesIn=vn,L.extend=Uh,L.extendWith=ku,_(L,L),L.add=Bt,L.attempt=a,L.camelCase=Hh,L.capitalize=Hn,L.ceil=qt,L.clamp=function(u,g,S){return S===i&&(S=g,g=i),S!==i&&(S=(S=ei(S))==S?S:0),g!==i&&(g=(g=ei(g))==g?g:0),xo(ei(u),g,S)},L.clone=function(u){return pi(u,4)},L.cloneDeep=function(u){return pi(u,5)},L.cloneDeepWith=function(u,g){return pi(u,5,g=typeof g=="function"?g:i)},L.cloneWith=function(u,g){return pi(u,4,g=typeof g=="function"?g:i)},L.conformsTo=function(u,g){return g==null||eh(u,g,Zn(g))},L.deburr=de,L.defaultTo=function(u,g){return u==null||u!=u?g:u},L.divide=$e,L.endsWith=function(u,g,S){u=qe(u),g=Jr(g);var k=u.length,R=S=S===i?k:xo(we(S),0,k);return (S-=g.length)>=0&&u.slice(S,R)==g},L.eq=Rr,L.escape=function(u){return (u=qe(u))&&_e.test(u)?u.replace(dn,jf):u},L.escapeRegExp=function(u){return (u=qe(u))&&lr.test(u)?u.replace(Jn,"\\$&"):u},L.every=function(u,g,S){var k=ge(u)?kt:rh;return S&&_r(u,g,S)&&(g=i),k(u,ue(g,3))},L.find=mp,L.findIndex=Eu,L.findKey=function(u,g){return $f(u,ue(g,3),Fi)},L.findLast=_h,L.findLastIndex=_u,L.findLastKey=function(u,g){return $f(u,ue(g,3),Zi)},L.floor=fe,L.forEach=Th,L.forEachRight=Va,L.forIn=function(u,g){return u==null?u:ru(u,ue(g,3),Wr)},L.forInRight=function(u,g){return u==null?u:Gd(u,ue(g,3),Wr)},L.forOwn=function(u,g){return u&&Fi(u,ue(g,3))},L.forOwnRight=function(u,g){return u&&Zi(u,ue(g,3))},L.get=Du,L.gt=Oh,L.gte=za,L.has=function(u,g){return u!=null&&Fe(u,g,$l)},L.hasIn=Au,L.head=Vs,L.identity=b,L.includes=function(u,g,S,k){u=Ur(u)?u:Oo(u),S=S&&!k?we(S):0;var R=u.length;return S<0&&(S=Xn(R+S,0)),rr(u)?S<=R&&u.indexOf(g,S)>-1:!!R&&Dr(u,g,S)>-1},L.indexOf=function(u,g,S){var k=u==null?0:u.length;if(!k)return -1;var R=S==null?0:we(S);return R<0&&(R=Xn(k+R,0)),Dr(u,g,R)},L.inRange=function(u,g,S){return g=Ao(g),S===i?(S=g,g=0):S=Ao(S),(function(k,R,$){return k>=Ar(R,$)&&k<Xn(R,$)})(u=ei(u),g,S)},L.invoke=Vh,L.isArguments=mi,L.isArray=ge,L.isArrayBuffer=Rh,L.isArrayLike=Ur,L.isArrayLikeObject=Vn,L.isBoolean=function(u){return u===true||u===false||zn(u)&&Pr(u)==O},L.isBuffer=Do,L.isDate=Fh,L.isElement=function(u){return zn(u)&&u.nodeType===1&&!nc(u)},L.isEmpty=function(u){if(u==null)return true;if(Ur(u)&&(ge(u)||typeof u=="string"||typeof u.splice=="function"||Do(u)||qs(u)||mi(u)))return !u.length;var g=Er(u);if(g==nt||g==Y)return !u.size;if(eo(u))return !ou(u).length;for(var S in u)if(an.call(u,S))return false;return true},L.isEqual=function(u,g){return jl(u,g)},L.isEqualWith=function(u,g,S){var k=(S=typeof S=="function"?S:i)?S(u,g):i;return k===i?jl(u,g,i,S):!!k},L.isError=tc,L.isFinite=function(u){return typeof u=="number"&&Xf(u)},L.isFunction=$r,L.isInteger=ec,L.isLength=Ws,L.isMap=Mh,L.isMatch=function(u,g){return u===g||jd(u,g,Na(g))},L.isMatchWith=function(u,g,S){return S=typeof S=="function"?S:i,jd(u,g,Na(g),S)},L.isNaN=function(u){return Nh(u)&&u!=+u},L.isNative=function(u){if(Zy(u))throw new Ne("Unsupported core-js use. Try https://npms.io/search?q=ponyfill.");return Os(u)},L.isNil=function(u){return u==null},L.isNull=function(u){return u===null},L.isNumber=Nh,L.isObject=Bn,L.isObjectLike=zn,L.isPlainObject=nc,L.isRegExp=Cp,L.isSafeInteger=function(u){return ec(u)&&u>=-9007199254740991&&u<=P},L.isSet=Sp,L.isString=rr,L.isSymbol=Fr,L.isTypedArray=qs,L.isUndefined=function(u){return u===i},L.isWeakMap=function(u){return zn(u)&&Er(u)==dt},L.isWeakSet=function(u){return zn(u)&&Pr(u)=="[object WeakSet]"},L.join=function(u,g){return u==null?"":Md.call(u,g)},L.kebabCase=pe,L.last=hi,L.lastIndexOf=function(u,g,S){var k=u==null?0:u.length;if(!k)return -1;var R=k;return S!==i&&(R=(R=we(S))<0?Xn(k+R,0):Ar(R,k-1)),g==g?(function($,q,et){for(var lt=et+1;lt--;)if($[lt]===q)return lt;return lt})(u,g,R):Hc(u,ui,R,true)},L.lowerCase=Wh,L.lowerFirst=db,L.lt=Lh,L.lte=Pp,L.max=function(u){return u&&u.length?ks(u,b,iu):i},L.maxBy=function(u,g){return u&&u.length?ks(u,ue(g,2),iu):i},L.mean=function(u){return Dn(u,b)},L.meanBy=function(u,g){return Dn(u,ue(g,2))},L.min=function(u){return u&&u.length?ks(u,b,zd):i},L.minBy=function(u,g){return u&&u.length?ks(u,ue(g,2),zd):i},L.stubArray=Rt,L.stubFalse=Zt,L.stubObject=function(){return {}},L.stubString=function(){return ""},L.stubTrue=function(){return true},L.multiply=Oe,L.nth=function(u,g){return u&&u.length?Vl(u,we(g)):i},L.noConflict=function(){return on._===this&&(on._=Hy),this},L.noop=M,L.now=Iu,L.pad=function(u,g,S){u=qe(u);var k=(g=we(g))?qo(u):0;if(!g||k>=g)return u;var R=(g-k)/2;return To(Xc(R),S)+u+To(Dl(R),S)},L.padEnd=function(u,g,S){u=qe(u);var k=(g=we(g))?qo(u):0;return g&&k<g?u+To(g-k,S):u},L.padStart=function(u,g,S){u=qe(u);var k=(g=we(g))?qo(u):0;return g&&k<g?To(g-k,S)+u:u},L.parseInt=function(u,g,S){return S||g==null?g=0:g&&(g=+g),Ld(qe(u).replace(wi,""),g||0)},L.random=function(u,g,S){if(S&&typeof S!="boolean"&&_r(u,g,S)&&(g=S=i),S===i&&(typeof g=="boolean"?(S=g,g=i):typeof u=="boolean"&&(S=u,u=i)),u===i&&g===i?(u=0,g=1):(u=Ao(u),g===i?(g=u,u=0):g=Ao(g)),u>g){var k=u;u=g,g=k;}if(S||u%1||g%1){var R=Al();return Ar(u+R*(g-u+li("1e-"+((R+"").length-1))),g)}return Qd(u,g)},L.reduce=function(u,g,S){var k=ge(u)?_l:Pd,R=arguments.length<3;return k(u,ue(g,4),S,R,Xo)},L.reduceRight=function(u,g,S){var k=ge(u)?Uf:Pd,R=arguments.length<3;return k(u,ue(g,4),S,R,nh)},L.repeat=function(u,g,S){return g=(S?_r(u,g,S):g===i)?1:we(g),lu(qe(u),g)},L.replace=function(){var u=arguments,g=qe(u[0]);return u.length<3?g:g.replace(u[1],u[2])},L.result=function(u,g,S){var k=-1,R=(g=Xe(g,u)).length;for(R||(R=1,u=i);++k<R;){var $=u==null?i:u[Ln(g[k])];$===i&&(k=R,$=S),u=$r($)?$.call(u):$;}return u},L.round=An,L.runInContext=ht,L.sample=function(u){return (ge(u)?Bd:ah)(u)},L.size=function(u){if(u==null)return 0;if(Ur(u))return rr(u)?qo(u):u.length;var g=Er(u);return g==nt||g==Y?u.size:ou(u).length},L.snakeCase=oo,L.some=function(u,g,S){var k=ge(u)?zc:Xd;return S&&_r(u,g,S)&&(g=i),k(u,ue(g,3))},L.sortedIndex=function(u,g){return cu(u,g)},L.sortedIndexBy=function(u,g,S){return Zd(u,g,ue(S,2))},L.sortedIndexOf=function(u,g){var S=u==null?0:u.length;if(S){var k=cu(u,g);if(k<S&&Rr(u[k],g))return k}return -1},L.sortedLastIndex=function(u,g){return cu(u,g,true)},L.sortedLastIndexBy=function(u,g,S){return Zd(u,g,ue(S,2),true)},L.sortedLastIndexOf=function(u,g){if(u!=null&&u.length){var S=cu(u,g,true)-1;if(Rr(u[S],g))return S}return -1},L.startCase=gn,L.startsWith=function(u,g,S){return u=qe(u),S=S==null?0:xo(we(S),0,u.length),g=Jr(g),u.slice(S,S+g.length)==g},L.subtract=Mr,L.sum=function(u){return u&&u.length?xd(u,b):0},L.sumBy=function(u,g){return u&&u.length?xd(u,ue(g,2)):0},L.template=function(u,g,S){var k=L.templateSettings;S&&_r(u,g,S)&&(g=i),u=qe(u),g=ku({},g,k,gu);var R,$,q=ku({},g.imports,k.imports,gu),et=Zn(q),lt=Wc(q,et),Et=0,wt=g.interpolate||ne,Mt="__p += '",Yt=Cs((g.escape||ne).source+"|"+wt.source+"|"+(wt===Ve?Z:ne).source+"|"+(g.evaluate||ne).source+"|$","g"),Qt="//# sourceURL="+(an.call(g,"sourceURL")?(g.sourceURL+"").replace(/\s/g," "):"lodash.templateSources["+ ++qi+"]")+`
2306
- `;u.replace(Yt,(function(Ut,ie,Xt,he,Pe,Ge){return Xt||(Xt=he),Mt+=u.slice(Et,Ge).replace(kn,wd),ie&&(R=true,Mt+=`' +
2305
+ `)})(k,(function(F,$){return Wt(I,(function(q){var et="_."+q[0];$&q[1]&&!jc(F,et)&&F.push(et);})),F.sort()})((function(F){var $=F.match(Co);return $?$[1].split(Ce):[]})(k),S)))}function Pu(u){var g=0,S=0;return function(){var k=Nd(),F=16-(k-S);if(S=k,F>0){if(++g>=800)return arguments[0]}else g=0;return u.apply(i,arguments)}}function xu(u,g){var S=-1,k=u.length,F=k-1;for(g=g===i?k:g;++S<g;){var $=Qd(S,F),q=u[$];u[$]=u[S],u[S]=q;}return u.length=g,u}var na,js,sp=(na=Jl((function(u){var g=[];return u.charCodeAt(0)===46&&g.push(""),u.replace(sr,(function(S,k,F,$){g.push(F?$.replace(ot,"$1"):k||S);})),g}),(function(u){return js.size===500&&js.clear(),u})),js=na.cache,na);function Ln(u){if(typeof u=="string"||Fr(u))return u;var g=u+"";return g=="0"&&1/u==-1/0?"-0":g}function ra(u){if(u!=null){try{return Ss.call(u)}catch(g){}try{return u+""}catch(g){}}return ""}function Io(u){if(u instanceof Re)return u.clone();var g=new Xr(u.__wrapped__,u.__chain__);return g.__actions__=mr(u.__actions__),g.__index__=u.__index__,g.__values__=u.__values__,g}var lp=Ie((function(u,g){return Vn(u)?Fa(u,hr(g,1,Vn,true)):[]})),Sh=Ie((function(u,g){var S=hi(g);return Vn(S)&&(S=i),Vn(u)?Fa(u,hr(g,1,Vn,true),ue(S,2)):[]})),ia=Ie((function(u,g){var S=hi(g);return Vn(S)&&(S=i),Vn(u)?Fa(u,hr(g,1,Vn,true),i,S):[]}));function Eu(u,g,S){var k=u==null?0:u.length;if(!k)return -1;var F=S==null?0:we(S);return F<0&&(F=Xn(k+F,0)),Hc(u,ue(g,3),F)}function _u(u,g,S){var k=u==null?0:u.length;if(!k)return -1;var F=k-1;return S!==i&&(F=we(S),F=S<0?Xn(k+F,0):Ar(F,k-1)),Hc(u,ue(g,3),F,true)}function Tn(u){return u!=null&&u.length?hr(u,1):[]}function Vs(u){return u&&u.length?u[0]:i}var Ph=Ie((function(u){var g=We(u,tp);return g.length&&g[0]===u[0]?Gl(g):[]})),ja=Ie((function(u){var g=hi(u),S=We(u,tp);return g===hi(S)?g=i:S.pop(),S.length&&S[0]===u[0]?Gl(S,ue(g,2)):[]})),Li=Ie((function(u){var g=hi(u),S=We(u,tp);return (g=typeof g=="function"?g:i)&&S.pop(),S.length&&S[0]===u[0]?Gl(S,i,g):[]}));function hi(u){var g=u==null?0:u.length;return g?u[g-1]:i}var Jy=Ie(Kl);function Kl(u,g){return u&&u.length&&g&&g.length?au(u,g):u}var Tu=Ni((function(u,g){var S=u==null?0:u.length,k=Bl(u,g);return su(u,We(g,(function(F){return Br(F,S)?+F:F})).sort(gh)),k}));function Xl(u){return u==null?u:qy.call(u)}var xh=Ie((function(u){return Zo(hr(u,1,Vn,true))})),cp=Ie((function(u){var g=hi(u);return Vn(g)&&(g=i),Zo(hr(u,1,Vn,true),ue(g,2))})),up=Ie((function(u){var g=hi(u);return g=typeof g=="function"?g:i,Zo(hr(u,1,Vn,true),i,g)}));function ko(u){if(!u||!u.length)return [];var g=0;return u=xt(u,(function(S){if(Vn(S))return g=Xn(S.length,g),true})),Ed(g,(function(S){return We(u,bs(S))}))}function dp(u,g){if(!u||!u.length)return [];var S=ko(u);return g==null?S:We(S,(function(k){return nr(g,i,k)}))}var pp=Ie((function(u,g){return Vn(u)?Fa(u,g):[]})),Eh=Ie((function(u){return uu(xt(u,Vn))})),fp=Ie((function(u){var g=hi(u);return Vn(g)&&(g=i),uu(xt(u,Vn),ue(g,2))})),hp=Ie((function(u){var g=hi(u);return g=typeof g=="function"?g:i,uu(xt(u,Vn),i,g)})),tb=Ie(ko),eb=Ie((function(u){var g=u.length,S=g>1?u[g-1]:i;return S=typeof S=="function"?(u.pop(),S):i,dp(u,S)}));function wu(u){var g=L(u);return g.__chain__=true,g}function zs(u,g){return g(u)}var nb=Ni((function(u){var g=u.length,S=g?u[0]:0,k=this.__wrapped__,F=function($){return Bl($,u)};return !(g>1||this.__actions__.length)&&k instanceof Re&&Br(S)?((k=k.slice(S,+S+(g?1:0))).__actions__.push({func:zs,args:[F],thisArg:i}),new Xr(k,this.__chain__).thru((function($){return g&&!$.length&&$.push(i),$}))):this.thru(F)})),rb=pu((function(u,g,S){an.call(u,S)?++u[S]:Xi(u,S,1);})),mp=ep(Eu),_h=ep(_u);function Th(u,g){return (ge(u)?Wt:Xo)(u,ue(g,3))}function Va(u,g){return (ge(u)?Tt:nh)(u,ue(g,3))}var oa=pu((function(u,g,S){an.call(u,S)?u[S].push(g):Xi(u,S,[g]);})),ib=Ie((function(u,g,S){var k=-1,F=typeof g=="function",$=Ur(u)?Ht(u.length):[];return Xo(u,(function(q){$[++k]=F?nr(g,q,S):As(q,g,S);})),$})),ob=pu((function(u,g,S){Xi(u,S,g);}));function Zl(u,g){return (ge(u)?We:oh)(u,ue(g,3))}var wh=pu((function(u,g,S){u[S?0:1].push(g);}),(function(){return [[],[]]})),Ih=Ie((function(u,g){if(u==null)return [];var S=g.length;return S>1&&_r(u,g[0],g[1])?g=[]:S>2&&_r(g[0],g[1],g[2])&&(g=[g[0]]),qd(u,hr(g,1),[])})),Iu=Rd||function(){return on.Date.now()};function Hs(u,g,S){return g=S?i:g,g=u&&g==null?u.length:g,to(u,h,i,i,i,i,g)}function gp(u,g){var S;if(typeof g!="function")throw new Kr(o);return u=we(u),function(){return --u>0&&(S=g.apply(this,arguments)),u<=1&&(g=i),S}}var yp=Ie((function(u,g,S){var k=1;if(S.length){var F=Wo(S,ea(yp));k|=p;}return to(u,k,g,S,F)})),kh=Ie((function(u,g,S){var k=3;if(S.length){var F=Wo(S,ea(kh));k|=p;}return to(g,k,u,S,F)}));function Dh(u,g,S){var k,F,$,q,et,lt,Et=0,wt=false,Mt=false,Yt=true;if(typeof u!="function")throw new Kr(o);function Qt(he){var Pe=k,Ge=F;return k=F=i,Et=he,q=u.apply(Ge,Pe)}function oe(he){return Et=he,et=ro(Ut,g),wt?Qt(he):q}function Ft(he){var Pe=he-lt;return lt===i||Pe>=g||Pe<0||Mt&&he-Et>=$}function Ut(){var he=Iu();if(Ft(he))return ie(he);et=ro(Ut,(function(Pe){var Ge=g-(Pe-lt);return Mt?Ar(Ge,$-(Pe-Et)):Ge})(he));}function ie(he){return et=i,Yt&&k?Qt(he):(k=F=i,q)}function Xt(){var he=Iu(),Pe=Ft(he);if(k=arguments,F=this,lt=he,Pe){if(et===i)return oe(lt);if(Mt)return Ms(et),et=ro(Ut,g),Qt(lt)}return et===i&&(et=ro(Ut,g)),q}return g=ei(g)||0,Bn(S)&&(wt=!!S.leading,$=(Mt="maxWait"in S)?Xn(ei(S.maxWait)||0,g):$,Yt="trailing"in S?!!S.trailing:Yt),Xt.cancel=function(){et!==i&&Ms(et),Et=0,k=lt=F=et=i;},Xt.flush=function(){return et===i?q:ie(Iu())},Xt}var ab=Ie((function(u,g){return $d(u,1,g)})),bp=Ie((function(u,g,S){return $d(u,ei(g)||0,S)}));function Jl(u,g){if(typeof u!="function"||g!=null&&typeof g!="function")throw new Kr(o);var S=function(){var k=arguments,F=g?g.apply(this,k):k[0],$=S.cache;if($.has(F))return $.get(F);var q=u.apply(this,k);return S.cache=$.set(F,q)||$,q};return S.cache=new(Jl.Cache||Ki),S}function aa(u){if(typeof u!="function")throw new Kr(o);return function(){var g=arguments;switch(g.length){case 0:return !u.call(this);case 1:return !u.call(this,g[0]);case 2:return !u.call(this,g[0],g[1]);case 3:return !u.call(this,g[0],g[1],g[2])}return !u.apply(this,g)}}Jl.Cache=Ki;var sb=hh((function(u,g){var S=(g=g.length==1&&ge(g[0])?We(g[0],zr(ue())):We(hr(g,1),zr(ue()))).length;return Ie((function(k){for(var F=-1,$=Ar(k.length,S);++F<$;)k[F]=g[F].call(this,k[F]);return nr(u,this,k)}))})),vp=Ie((function(u,g){var S=Wo(g,ea(vp));return to(u,p,i,g,S)})),Ah=Ie((function(u,g){var S=Wo(g,ea(Ah));return to(u,64,i,g,S)})),lb=Ni((function(u,g){return to(u,256,i,i,i,g)}));function Rr(u,g){return u===g||u!=u&&g!=g}var Oh=Us(iu),za=Us((function(u,g){return u>=g})),mi=Eo((function(){return arguments})())?Eo:function(u){return zn(u)&&an.call(u,"callee")&&!Es.call(u,"callee")},ge=Ht.isArray,Rh=Ai?zr(Ai):function(u){return zn(u)&&Pr(u)==mt};function Ur(u){return u!=null&&Ws(u.length)&&!$r(u)}function Vn(u){return zn(u)&&Ur(u)}var Do=Fd||Zt,Fh=er?zr(er):function(u){return zn(u)&&Pr(u)==N};function tc(u){if(!zn(u))return false;var g=Pr(u);return g==V||g=="[object DOMException]"||typeof u.message=="string"&&typeof u.name=="string"&&!nc(u)}function $r(u){if(!Bn(u))return false;var g=Pr(u);return g==G||g==X||g=="[object AsyncFunction]"||g=="[object Proxy]"}function ec(u){return typeof u=="number"&&u==we(u)}function Ws(u){return typeof u=="number"&&u>-1&&u%1==0&&u<=P}function Bn(u){var g=typeof u;return u!=null&&(g=="object"||g=="function")}function zn(u){return u!=null&&typeof u=="object"}var Mh=ys?zr(ys):function(u){return zn(u)&&Er(u)==nt};function Nh(u){return typeof u=="number"||zn(u)&&Pr(u)==st}function nc(u){if(!zn(u)||Pr(u)!=U)return false;var g=un(u);if(g===null)return true;var S=an.call(g,"constructor")&&g.constructor;return typeof S=="function"&&S instanceof S&&Ss.call(S)==Dd}var Cp=_a?zr(_a):function(u){return zn(u)&&Pr(u)==ut},Sp=zo?zr(zo):function(u){return zn(u)&&Er(u)==Y};function rr(u){return typeof u=="string"||!ge(u)&&zn(u)&&Pr(u)==at}function Fr(u){return typeof u=="symbol"||zn(u)&&Pr(u)==pt}var qs=Cr?zr(Cr):function(u){return zn(u)&&Ws(u.length)&&!!ae[Pr(u)]},Lh=Us(zd),Pp=Us((function(u,g){return u<=g}));function xp(u){if(!u)return [];if(Ur(u))return rr(u)?Qr(u):mr(u);if(ka&&u[ka])return (function(S){for(var k,F=[];!(k=S.next()).done;)F.push(k.value);return F})(u[ka]());var g=Er(u);return (g==nt?Tl:g==Y?qc:Oo)(u)}function Ao(u){return u?(u=ei(u))===v||u===-1/0?17976931348623157e292*(u<0?-1:1):u==u?u:0:u===0?u:0}function we(u){var g=Ao(u),S=g%1;return g==g?S?g-S:g:0}function Ep(u){return u?xo(we(u),0,T):0}function ei(u){if(typeof u=="number")return u;if(Fr(u))return x;if(Bn(u)){var g=typeof u.valueOf=="function"?u.valueOf():u;u=Bn(g)?g+"":g;}if(typeof u!="string")return u===0?u:+u;u=_d(u);var S=ft.test(u);return S||It.test(u)?Yi(u.slice(2),S?2:8):_t.test(u)?x:+u}function gi(u){return fi(u,Wr(u))}function qe(u){return u==null?"":Jr(u)}var Bh=Ls((function(u,g){if(eo(g)||Ur(g))fi(g,Zn(g),u);else for(var S in g)an.call(g,S)&&Nl(u,S,g[S]);})),Uh=Ls((function(u,g){fi(g,Wr(g),u);})),ku=Ls((function(u,g,S,k){fi(g,Wr(g),u,k);})),cb=Ls((function(u,g,S,k){fi(g,Zn(g),u,k);})),_p=Ni(Bl),$h=Ie((function(u,g){u=mn(u);var S=-1,k=g.length,F=k>2?g[2]:i;for(F&&_r(g[0],g[1],F)&&(k=1);++S<k;)for(var $=g[S],q=Wr($),et=-1,lt=q.length;++et<lt;){var Et=q[et],wt=u[Et];(wt===i||Rr(wt,wa[Et])&&!an.call(u,Et))&&(u[Et]=$[Et]);}return u})),Gh=Ie((function(u){return u.push(i,xr),nr(zh,i,u)}));function Du(u,g,S){var k=u==null?i:Mi(u,g);return k===i?S:k}function Au(u,g){return u!=null&&Fe(u,g,ih)}var jh=np((function(u,g,S){g!=null&&typeof g.toString!="function"&&(g=Ia.call(g)),u[g]=S;}),d(b)),Ys=np((function(u,g,S){g!=null&&typeof g.toString!="function"&&(g=Ia.call(g)),an.call(u,g)?u[g].push(S):u[g]=[S];}),ue),Vh=Ie(As);function Zn(u){return Ur(u)?eu(u):ou(u)}function Wr(u){return Ur(u)?eu(u,true):(function(g){if(!Bn(g))return (function($){var q=[];if($!=null)for(var et in mn($))q.push(et);return q})(g);var S=eo(g),k=[];for(var F in g)(F!="constructor"||!S&&an.call(g,F))&&k.push(F);return k})(u)}var ub=Ls((function(u,g,S){Rs(u,g,S);})),zh=Ls((function(u,g,S,k){Rs(u,g,S,k);})),Ou=Ni((function(u,g){var S={};if(u==null)return S;var k=false;g=We(g,(function($){return $=Xe($,u),k||(k=$.length>1),$})),fi(u,bu(u),S),k&&(S=pi(S,7,rp));for(var F=g.length;F--;)Jd(S,g[F]);return S})),Tp=Ni((function(u,g){return u==null?{}:(function(S,k){return Yd(S,k,(function(F,$){return Au(S,$)}))})(u,g)}));function wp(u,g){if(u==null)return {};var S=We(bu(u),(function(k){return [k]}));return g=ue(g),Yd(u,S,(function(k,F){return g(k,F[0])}))}var Ha=$s(Zn),vn=$s(Wr);function Oo(u){return u==null?[]:Wc(u,Zn(u))}var Hh=_n((function(u,g,S){return g=g.toLowerCase(),u+(S?Hn(g):g)}));function Hn(u){return Ru(qe(u).toLowerCase())}function de(u){return (u=qe(u))&&u.replace(se,zy).replace(pr,"")}var pe=_n((function(u,g,S){return u+(S?"-":"")+g.toLowerCase()})),Wh=_n((function(u,g,S){return u+(S?" ":"")+g.toLowerCase()})),db=bh("toLowerCase"),oo=_n((function(u,g,S){return u+(S?"_":"")+g.toLowerCase()})),gn=_n((function(u,g,S){return u+(S?" ":"")+Ru(g)})),yn=_n((function(u,g,S){return u+(S?" ":"")+g.toUpperCase()})),Ru=bh("toUpperCase");function f(u,g,S){return u=qe(u),(g=S?i:g)===i?(function(k){return So.test(k)})(u)?(function(k){return k.match(vt)||[]})(u):(function(k){return k.match(Vt)||[]})(u):u.match(g)||[]}var a=Ie((function(u,g){try{return nr(u,i,g)}catch(S){return tc(S)?S:new Ne(S)}})),l=Ni((function(u,g){return Wt(g,(function(S){S=Ln(S),Xi(u,S,yp(u[S],u));})),u}));function d(u){return function(){return u}}var m=Ma(),y=Ma(true);function b(u){return u}function E(u){return Vd(typeof u=="function"?u:pi(u,1))}var w=Ie((function(u,g){return function(S){return As(S,u,g)}})),D=Ie((function(u,g){return function(S){return As(u,S,g)}}));function _(u,g,S){var k=Zn(g),F=Ds(g,k);S!=null||Bn(g)&&(F.length||!k.length)||(S=g,g=u,u=this,F=Ds(g,Zn(g)));var $=!(Bn(S)&&"chain"in S&&!S.chain),q=$r(u);return Wt(F,(function(et){var lt=g[et];u[et]=lt,q&&(u.prototype[et]=function(){var Et=this.__chain__;if($||Et){var wt=u(this.__wrapped__),Mt=wt.__actions__=mr(this.__actions__);return Mt.push({func:lt,args:arguments,thisArg:u}),wt.__chain__=Et,wt}return lt.apply(u,Ho([this.value()],arguments))});})),u}function M(){}var B=hu(We),H=hu(kt),K=hu(zc);function J(u){return Ua(u)?bs(Ln(u)):(function(g){return function(S){return Mi(S,g)}})(u)}var tt=mu(),yt=mu(true);function Rt(){return []}function Zt(){return false}var zt,Bt=_o((function(u,g){return u+g}),0),qt=Wl("ceil"),$e=_o((function(u,g){return u/g}),1),fe=Wl("floor"),Oe=_o((function(u,g){return u*g}),1),An=Wl("round"),Mr=_o((function(u,g){return u-g}),0);return L.after=function(u,g){if(typeof g!="function")throw new Kr(o);return u=we(u),function(){if(--u<1)return g.apply(this,arguments)}},L.ary=Hs,L.assign=Bh,L.assignIn=Uh,L.assignInWith=ku,L.assignWith=cb,L.at=_p,L.before=gp,L.bind=yp,L.bindAll=l,L.bindKey=kh,L.castArray=function(){if(!arguments.length)return [];var u=arguments[0];return ge(u)?u:[u]},L.chain=wu,L.chunk=function(u,g,S){g=(S?_r(u,g,S):g===i)?1:Xn(we(g),0);var k=u==null?0:u.length;if(!k||g<1)return [];for(var F=0,$=0,q=Ht(Dl(k/g));F<k;)q[$++]=Zr(u,F,F+=g);return q},L.compact=function(u){for(var g=-1,S=u==null?0:u.length,k=0,F=[];++g<S;){var $=u[g];$&&(F[k++]=$);}return F},L.concat=function(){var u=arguments.length;if(!u)return [];for(var g=Ht(u-1),S=arguments[0],k=u;k--;)g[k-1]=arguments[k];return Ho(ge(S)?mr(S):[S],hr(g,1))},L.cond=function(u){var g=u==null?0:u.length,S=ue();return u=g?We(u,(function(k){if(typeof k[1]!="function")throw new Kr(o);return [S(k[0]),k[1]]})):[],Ie((function(k){for(var F=-1;++F<g;){var $=u[F];if(nr($[0],this,k))return nr($[1],this,k)}}))},L.conforms=function(u){return (function(g){var S=Zn(g);return function(k){return eh(k,g,S)}})(pi(u,1))},L.constant=d,L.countBy=rb,L.create=function(u,g){var S=Oa(u);return g==null?S:nu(S,g)},L.curry=function u(g,S,k){var F=to(g,8,i,i,i,i,i,S=k?i:S);return F.placeholder=u.placeholder,F},L.curryRight=function u(g,S,k){var F=to(g,16,i,i,i,i,i,S=k?i:S);return F.placeholder=u.placeholder,F},L.debounce=Dh,L.defaults=$h,L.defaultsDeep=Gh,L.defer=ab,L.delay=bp,L.difference=lp,L.differenceBy=Sh,L.differenceWith=ia,L.drop=function(u,g,S){var k=u==null?0:u.length;return k?Zr(u,(g=S||g===i?1:we(g))<0?0:g,k):[]},L.dropRight=function(u,g,S){var k=u==null?0:u.length;return k?Zr(u,0,(g=k-(g=S||g===i?1:we(g)))<0?0:g):[]},L.dropRightWhile=function(u,g){return u&&u.length?Ji(u,ue(g,3),true,true):[]},L.dropWhile=function(u,g){return u&&u.length?Ji(u,ue(g,3),true):[]},L.fill=function(u,g,S,k){var F=u==null?0:u.length;return F?(S&&typeof S!="number"&&_r(u,g,S)&&(S=0,k=F),(function($,q,et,lt){var Et=$.length;for((et=we(et))<0&&(et=-et>Et?0:Et+et),(lt=lt===i||lt>Et?Et:we(lt))<0&&(lt+=Et),lt=et>lt?0:Ep(lt);et<lt;)$[et++]=q;return $})(u,g,S,k)):[]},L.filter=function(u,g){return (ge(u)?xt:fr)(u,ue(g,3))},L.flatMap=function(u,g){return hr(Zl(u,g),1)},L.flatMapDeep=function(u,g){return hr(Zl(u,g),v)},L.flatMapDepth=function(u,g,S){return S=S===i?1:we(S),hr(Zl(u,g),S)},L.flatten=Tn,L.flattenDeep=function(u){return u!=null&&u.length?hr(u,v):[]},L.flattenDepth=function(u,g){return u!=null&&u.length?hr(u,g=g===i?1:we(g)):[]},L.flip=function(u){return to(u,512)},L.flow=m,L.flowRight=y,L.fromPairs=function(u){for(var g=-1,S=u==null?0:u.length,k={};++g<S;){var F=u[g];k[F[0]]=F[1];}return k},L.functions=function(u){return u==null?[]:Ds(u,Zn(u))},L.functionsIn=function(u){return u==null?[]:Ds(u,Wr(u))},L.groupBy=oa,L.initial=function(u){return u!=null&&u.length?Zr(u,0,-1):[]},L.intersection=Ph,L.intersectionBy=ja,L.intersectionWith=Li,L.invert=jh,L.invertBy=Ys,L.invokeMap=ib,L.iteratee=E,L.keyBy=ob,L.keys=Zn,L.keysIn=Wr,L.map=Zl,L.mapKeys=function(u,g){var S={};return g=ue(g,3),Fi(u,(function(k,F,$){Xi(S,g(k,F,$),k);})),S},L.mapValues=function(u,g){var S={};return g=ue(g,3),Fi(u,(function(k,F,$){Xi(S,F,g(k,F,$));})),S},L.matches=function(u){return Hd(pi(u,1))},L.matchesProperty=function(u,g){return Wd(u,pi(g,1))},L.memoize=Jl,L.merge=ub,L.mergeWith=zh,L.method=w,L.methodOf=D,L.mixin=_,L.negate=aa,L.nthArg=function(u){return u=we(u),Ie((function(g){return Vl(g,u)}))},L.omit=Ou,L.omitBy=function(u,g){return wp(u,aa(ue(g)))},L.once=function(u){return gp(2,u)},L.orderBy=function(u,g,S,k){return u==null?[]:(ge(g)||(g=g==null?[]:[g]),ge(S=k?i:S)||(S=S==null?[]:[S]),qd(u,g,S))},L.over=B,L.overArgs=sb,L.overEvery=H,L.overSome=K,L.partial=vp,L.partialRight=Ah,L.partition=wh,L.pick=Tp,L.pickBy=wp,L.property=J,L.propertyOf=function(u){return function(g){return u==null?i:Mi(u,g)}},L.pull=Jy,L.pullAll=Kl,L.pullAllBy=function(u,g,S){return u&&u.length&&g&&g.length?au(u,g,ue(S,2)):u},L.pullAllWith=function(u,g,S){return u&&u.length&&g&&g.length?au(u,g,i,S):u},L.pullAt=Tu,L.range=tt,L.rangeRight=yt,L.rearg=lb,L.reject=function(u,g){return (ge(u)?xt:fr)(u,aa(ue(g,3)))},L.remove=function(u,g){var S=[];if(!u||!u.length)return S;var k=-1,F=[],$=u.length;for(g=ue(g,3);++k<$;){var q=u[k];g(q,k,u)&&(S.push(q),F.push(k));}return su(u,F),S},L.rest=function(u,g){if(typeof u!="function")throw new Kr(o);return Ie(u,g=g===i?g:we(g))},L.reverse=Xl,L.sampleSize=function(u,g,S){return g=(S?_r(u,g,S):g===i)?1:we(g),(ge(u)?Ml:Ky)(u,g)},L.set=function(u,g,S){return u==null?u:Fs(u,g,S)},L.setWith=function(u,g,S,k){return k=typeof k=="function"?k:i,u==null?u:Fs(u,g,S,k)},L.shuffle=function(u){return (ge(u)?th:lh)(u)},L.slice=function(u,g,S){var k=u==null?0:u.length;return k?(S&&typeof S!="number"&&_r(u,g,S)?(g=0,S=k):(g=g==null?0:we(g),S=S===i?k:we(S)),Zr(u,g,S)):[]},L.sortBy=Ih,L.sortedUniq=function(u){return u&&u.length?ch(u):[]},L.sortedUniqBy=function(u,g){return u&&u.length?ch(u,ue(g,2)):[]},L.split=function(u,g,S){return S&&typeof S!="number"&&_r(u,g,S)&&(g=S=i),(S=S===i?T:S>>>0)?(u=qe(u))&&(typeof g=="string"||g!=null&&!Cp(g))&&!(g=Jr(g))&&Nn(u)?Jo(Qr(u),0,S):u.split(g,S):[]},L.spread=function(u,g){if(typeof u!="function")throw new Kr(o);return g=g==null?0:Xn(we(g),0),Ie((function(S){var k=S[g],F=Jo(S,0,g);return k&&Ho(F,k),nr(u,this,F)}))},L.tail=function(u){var g=u==null?0:u.length;return g?Zr(u,1,g):[]},L.take=function(u,g,S){return u&&u.length?Zr(u,0,(g=S||g===i?1:we(g))<0?0:g):[]},L.takeRight=function(u,g,S){var k=u==null?0:u.length;return k?Zr(u,(g=k-(g=S||g===i?1:we(g)))<0?0:g,k):[]},L.takeRightWhile=function(u,g){return u&&u.length?Ji(u,ue(g,3),false,true):[]},L.takeWhile=function(u,g){return u&&u.length?Ji(u,ue(g,3)):[]},L.tap=function(u,g){return g(u),u},L.throttle=function(u,g,S){var k=true,F=true;if(typeof u!="function")throw new Kr(o);return Bn(S)&&(k="leading"in S?!!S.leading:k,F="trailing"in S?!!S.trailing:F),Dh(u,g,{leading:k,maxWait:g,trailing:F})},L.thru=zs,L.toArray=xp,L.toPairs=Ha,L.toPairsIn=vn,L.toPath=function(u){return ge(u)?We(u,Ln):Fr(u)?[u]:mr(sp(qe(u)))},L.toPlainObject=gi,L.transform=function(u,g,S){var k=ge(u),F=k||Do(u)||qs(u);if(g=ue(g,4),S==null){var $=u&&u.constructor;S=F?k?new $:[]:Bn(u)&&$r($)?Oa(un(u)):{};}return (F?Wt:Fi)(u,(function(q,et,lt){return g(S,q,et,lt)})),S},L.unary=function(u){return Hs(u,1)},L.union=xh,L.unionBy=cp,L.unionWith=up,L.uniq=function(u){return u&&u.length?Zo(u):[]},L.uniqBy=function(u,g){return u&&u.length?Zo(u,ue(g,2)):[]},L.uniqWith=function(u,g){return g=typeof g=="function"?g:i,u&&u.length?Zo(u,i,g):[]},L.unset=function(u,g){return u==null||Jd(u,g)},L.unzip=ko,L.unzipWith=dp,L.update=function(u,g,S){return u==null?u:dh(u,g,zl(S))},L.updateWith=function(u,g,S,k){return k=typeof k=="function"?k:i,u==null?u:dh(u,g,zl(S),k)},L.values=Oo,L.valuesIn=function(u){return u==null?[]:Wc(u,Wr(u))},L.without=pp,L.words=f,L.wrap=function(u,g){return vp(zl(g),u)},L.xor=Eh,L.xorBy=fp,L.xorWith=hp,L.zip=tb,L.zipObject=function(u,g){return fh(u||[],g||[],Nl)},L.zipObjectDeep=function(u,g){return fh(u||[],g||[],Fs)},L.zipWith=eb,L.entries=Ha,L.entriesIn=vn,L.extend=Uh,L.extendWith=ku,_(L,L),L.add=Bt,L.attempt=a,L.camelCase=Hh,L.capitalize=Hn,L.ceil=qt,L.clamp=function(u,g,S){return S===i&&(S=g,g=i),S!==i&&(S=(S=ei(S))==S?S:0),g!==i&&(g=(g=ei(g))==g?g:0),xo(ei(u),g,S)},L.clone=function(u){return pi(u,4)},L.cloneDeep=function(u){return pi(u,5)},L.cloneDeepWith=function(u,g){return pi(u,5,g=typeof g=="function"?g:i)},L.cloneWith=function(u,g){return pi(u,4,g=typeof g=="function"?g:i)},L.conformsTo=function(u,g){return g==null||eh(u,g,Zn(g))},L.deburr=de,L.defaultTo=function(u,g){return u==null||u!=u?g:u},L.divide=$e,L.endsWith=function(u,g,S){u=qe(u),g=Jr(g);var k=u.length,F=S=S===i?k:xo(we(S),0,k);return (S-=g.length)>=0&&u.slice(S,F)==g},L.eq=Rr,L.escape=function(u){return (u=qe(u))&&_e.test(u)?u.replace(dn,jf):u},L.escapeRegExp=function(u){return (u=qe(u))&&lr.test(u)?u.replace(Jn,"\\$&"):u},L.every=function(u,g,S){var k=ge(u)?kt:rh;return S&&_r(u,g,S)&&(g=i),k(u,ue(g,3))},L.find=mp,L.findIndex=Eu,L.findKey=function(u,g){return $f(u,ue(g,3),Fi)},L.findLast=_h,L.findLastIndex=_u,L.findLastKey=function(u,g){return $f(u,ue(g,3),Zi)},L.floor=fe,L.forEach=Th,L.forEachRight=Va,L.forIn=function(u,g){return u==null?u:ru(u,ue(g,3),Wr)},L.forInRight=function(u,g){return u==null?u:Gd(u,ue(g,3),Wr)},L.forOwn=function(u,g){return u&&Fi(u,ue(g,3))},L.forOwnRight=function(u,g){return u&&Zi(u,ue(g,3))},L.get=Du,L.gt=Oh,L.gte=za,L.has=function(u,g){return u!=null&&Fe(u,g,$l)},L.hasIn=Au,L.head=Vs,L.identity=b,L.includes=function(u,g,S,k){u=Ur(u)?u:Oo(u),S=S&&!k?we(S):0;var F=u.length;return S<0&&(S=Xn(F+S,0)),rr(u)?S<=F&&u.indexOf(g,S)>-1:!!F&&Dr(u,g,S)>-1},L.indexOf=function(u,g,S){var k=u==null?0:u.length;if(!k)return -1;var F=S==null?0:we(S);return F<0&&(F=Xn(k+F,0)),Dr(u,g,F)},L.inRange=function(u,g,S){return g=Ao(g),S===i?(S=g,g=0):S=Ao(S),(function(k,F,$){return k>=Ar(F,$)&&k<Xn(F,$)})(u=ei(u),g,S)},L.invoke=Vh,L.isArguments=mi,L.isArray=ge,L.isArrayBuffer=Rh,L.isArrayLike=Ur,L.isArrayLikeObject=Vn,L.isBoolean=function(u){return u===true||u===false||zn(u)&&Pr(u)==O},L.isBuffer=Do,L.isDate=Fh,L.isElement=function(u){return zn(u)&&u.nodeType===1&&!nc(u)},L.isEmpty=function(u){if(u==null)return true;if(Ur(u)&&(ge(u)||typeof u=="string"||typeof u.splice=="function"||Do(u)||qs(u)||mi(u)))return !u.length;var g=Er(u);if(g==nt||g==Y)return !u.size;if(eo(u))return !ou(u).length;for(var S in u)if(an.call(u,S))return false;return true},L.isEqual=function(u,g){return jl(u,g)},L.isEqualWith=function(u,g,S){var k=(S=typeof S=="function"?S:i)?S(u,g):i;return k===i?jl(u,g,i,S):!!k},L.isError=tc,L.isFinite=function(u){return typeof u=="number"&&Xf(u)},L.isFunction=$r,L.isInteger=ec,L.isLength=Ws,L.isMap=Mh,L.isMatch=function(u,g){return u===g||jd(u,g,Na(g))},L.isMatchWith=function(u,g,S){return S=typeof S=="function"?S:i,jd(u,g,Na(g),S)},L.isNaN=function(u){return Nh(u)&&u!=+u},L.isNative=function(u){if(Zy(u))throw new Ne("Unsupported core-js use. Try https://npms.io/search?q=ponyfill.");return Os(u)},L.isNil=function(u){return u==null},L.isNull=function(u){return u===null},L.isNumber=Nh,L.isObject=Bn,L.isObjectLike=zn,L.isPlainObject=nc,L.isRegExp=Cp,L.isSafeInteger=function(u){return ec(u)&&u>=-9007199254740991&&u<=P},L.isSet=Sp,L.isString=rr,L.isSymbol=Fr,L.isTypedArray=qs,L.isUndefined=function(u){return u===i},L.isWeakMap=function(u){return zn(u)&&Er(u)==dt},L.isWeakSet=function(u){return zn(u)&&Pr(u)=="[object WeakSet]"},L.join=function(u,g){return u==null?"":Md.call(u,g)},L.kebabCase=pe,L.last=hi,L.lastIndexOf=function(u,g,S){var k=u==null?0:u.length;if(!k)return -1;var F=k;return S!==i&&(F=(F=we(S))<0?Xn(k+F,0):Ar(F,k-1)),g==g?(function($,q,et){for(var lt=et+1;lt--;)if($[lt]===q)return lt;return lt})(u,g,F):Hc(u,ui,F,true)},L.lowerCase=Wh,L.lowerFirst=db,L.lt=Lh,L.lte=Pp,L.max=function(u){return u&&u.length?ks(u,b,iu):i},L.maxBy=function(u,g){return u&&u.length?ks(u,ue(g,2),iu):i},L.mean=function(u){return Dn(u,b)},L.meanBy=function(u,g){return Dn(u,ue(g,2))},L.min=function(u){return u&&u.length?ks(u,b,zd):i},L.minBy=function(u,g){return u&&u.length?ks(u,ue(g,2),zd):i},L.stubArray=Rt,L.stubFalse=Zt,L.stubObject=function(){return {}},L.stubString=function(){return ""},L.stubTrue=function(){return true},L.multiply=Oe,L.nth=function(u,g){return u&&u.length?Vl(u,we(g)):i},L.noConflict=function(){return on._===this&&(on._=Hy),this},L.noop=M,L.now=Iu,L.pad=function(u,g,S){u=qe(u);var k=(g=we(g))?qo(u):0;if(!g||k>=g)return u;var F=(g-k)/2;return To(Xc(F),S)+u+To(Dl(F),S)},L.padEnd=function(u,g,S){u=qe(u);var k=(g=we(g))?qo(u):0;return g&&k<g?u+To(g-k,S):u},L.padStart=function(u,g,S){u=qe(u);var k=(g=we(g))?qo(u):0;return g&&k<g?To(g-k,S)+u:u},L.parseInt=function(u,g,S){return S||g==null?g=0:g&&(g=+g),Ld(qe(u).replace(wi,""),g||0)},L.random=function(u,g,S){if(S&&typeof S!="boolean"&&_r(u,g,S)&&(g=S=i),S===i&&(typeof g=="boolean"?(S=g,g=i):typeof u=="boolean"&&(S=u,u=i)),u===i&&g===i?(u=0,g=1):(u=Ao(u),g===i?(g=u,u=0):g=Ao(g)),u>g){var k=u;u=g,g=k;}if(S||u%1||g%1){var F=Al();return Ar(u+F*(g-u+li("1e-"+((F+"").length-1))),g)}return Qd(u,g)},L.reduce=function(u,g,S){var k=ge(u)?_l:Pd,F=arguments.length<3;return k(u,ue(g,4),S,F,Xo)},L.reduceRight=function(u,g,S){var k=ge(u)?Uf:Pd,F=arguments.length<3;return k(u,ue(g,4),S,F,nh)},L.repeat=function(u,g,S){return g=(S?_r(u,g,S):g===i)?1:we(g),lu(qe(u),g)},L.replace=function(){var u=arguments,g=qe(u[0]);return u.length<3?g:g.replace(u[1],u[2])},L.result=function(u,g,S){var k=-1,F=(g=Xe(g,u)).length;for(F||(F=1,u=i);++k<F;){var $=u==null?i:u[Ln(g[k])];$===i&&(k=F,$=S),u=$r($)?$.call(u):$;}return u},L.round=An,L.runInContext=ht,L.sample=function(u){return (ge(u)?Bd:ah)(u)},L.size=function(u){if(u==null)return 0;if(Ur(u))return rr(u)?qo(u):u.length;var g=Er(u);return g==nt||g==Y?u.size:ou(u).length},L.snakeCase=oo,L.some=function(u,g,S){var k=ge(u)?zc:Xd;return S&&_r(u,g,S)&&(g=i),k(u,ue(g,3))},L.sortedIndex=function(u,g){return cu(u,g)},L.sortedIndexBy=function(u,g,S){return Zd(u,g,ue(S,2))},L.sortedIndexOf=function(u,g){var S=u==null?0:u.length;if(S){var k=cu(u,g);if(k<S&&Rr(u[k],g))return k}return -1},L.sortedLastIndex=function(u,g){return cu(u,g,true)},L.sortedLastIndexBy=function(u,g,S){return Zd(u,g,ue(S,2),true)},L.sortedLastIndexOf=function(u,g){if(u!=null&&u.length){var S=cu(u,g,true)-1;if(Rr(u[S],g))return S}return -1},L.startCase=gn,L.startsWith=function(u,g,S){return u=qe(u),S=S==null?0:xo(we(S),0,u.length),g=Jr(g),u.slice(S,S+g.length)==g},L.subtract=Mr,L.sum=function(u){return u&&u.length?xd(u,b):0},L.sumBy=function(u,g){return u&&u.length?xd(u,ue(g,2)):0},L.template=function(u,g,S){var k=L.templateSettings;S&&_r(u,g,S)&&(g=i),u=qe(u),g=ku({},g,k,gu);var F,$,q=ku({},g.imports,k.imports,gu),et=Zn(q),lt=Wc(q,et),Et=0,wt=g.interpolate||ne,Mt="__p += '",Yt=Cs((g.escape||ne).source+"|"+wt.source+"|"+(wt===Ve?Z:ne).source+"|"+(g.evaluate||ne).source+"|$","g"),Qt="//# sourceURL="+(an.call(g,"sourceURL")?(g.sourceURL+"").replace(/\s/g," "):"lodash.templateSources["+ ++qi+"]")+`
2306
+ `;u.replace(Yt,(function(Ut,ie,Xt,he,Pe,Ge){return Xt||(Xt=he),Mt+=u.slice(Et,Ge).replace(kn,wd),ie&&(F=true,Mt+=`' +
2307
2307
  __e(`+ie+`) +
2308
2308
  '`),Pe&&($=true,Mt+=`';
2309
2309
  `+Pe+`;
@@ -2315,13 +2315,13 @@ __p += '`),Xt&&(Mt+=`' +
2315
2315
  }
2316
2316
  `;Mt=($?Mt.replace(Pn,""):Mt).replace(Gn,"$1").replace(ln,"$1;"),Mt="function("+(oe||"obj")+`) {
2317
2317
  `+(oe?"":`obj || (obj = {});
2318
- `)+"var __t, __p = ''"+(R?", __e = _.escape":"")+($?`, __j = Array.prototype.join;
2318
+ `)+"var __t, __p = ''"+(F?", __e = _.escape":"")+($?`, __j = Array.prototype.join;
2319
2319
  function print() { __p += __j.call(arguments, '') }
2320
2320
  `:`;
2321
2321
  `)+Mt+`return __p
2322
- }`;var Ft=a((function(){return En(et,Qt+"return "+Mt).apply(i,lt)}));if(Ft.source=Mt,tc(Ft))throw Ft;return Ft},L.times=function(u,g){if((u=we(u))<1||u>P)return [];var S=T,k=Ar(u,T);g=ue(g),u-=T;for(var R=Ed(k,g);++S<u;)g(S);return R},L.toFinite=Ao,L.toInteger=we,L.toLength=Ep,L.toLower=function(u){return qe(u).toLowerCase()},L.toNumber=ei,L.toSafeInteger=function(u){return u?xo(we(u),-9007199254740991,P):u===0?u:0},L.toString=qe,L.toUpper=function(u){return qe(u).toUpperCase()},L.trim=function(u,g,S){if((u=qe(u))&&(S||g===i))return _d(u);if(!u||!(g=Jr(g)))return u;var k=Qr(u),R=Qr(g);return Jo(k,vs(k,R),Td(k,R)+1).join("")},L.trimEnd=function(u,g,S){if((u=qe(u))&&(S||g===i))return u.slice(0,zf(u)+1);if(!u||!(g=Jr(g)))return u;var k=Qr(u);return Jo(k,0,Td(k,Qr(g))+1).join("")},L.trimStart=function(u,g,S){if((u=qe(u))&&(S||g===i))return u.replace(wi,"");if(!u||!(g=Jr(g)))return u;var k=Qr(u);return Jo(k,vs(k,Qr(g))).join("")},L.truncate=function(u,g){var S=30,k="...";if(Bn(g)){var R="separator"in g?g.separator:R;S="length"in g?we(g.length):S,k="omission"in g?Jr(g.omission):k;}var $=(u=qe(u)).length;if(Nn(u)){var q=Qr(u);$=q.length;}if(S>=$)return u;var et=S-qo(k);if(et<1)return k;var lt=q?Jo(q,0,et).join(""):u.slice(0,et);if(R===i)return lt+k;if(q&&(et+=lt.length-et),Cp(R)){if(u.slice(et).search(R)){var Et,wt=lt;for(R.global||(R=Cs(R.source,qe(it.exec(R))+"g")),R.lastIndex=0;Et=R.exec(wt);)var Mt=Et.index;lt=lt.slice(0,Mt===i?et:Mt);}}else if(u.indexOf(Jr(R),et)!=et){var Yt=lt.lastIndexOf(R);Yt>-1&&(lt=lt.slice(0,Yt));}return lt+k},L.unescape=function(u){return (u=qe(u))&&or.test(u)?u.replace(Ke,Hf):u},L.uniqueId=function(u){var g=++qf;return qe(u)+g},L.upperCase=yn,L.upperFirst=Ru,L.each=Th,L.eachRight=Va,L.first=Vs,_(L,(zt={},Fi(L,(function(u,g){an.call(L.prototype,g)||(zt[g]=u);})),zt),{chain:false}),L.VERSION="4.17.21",Wt(["bind","bindKey","curry","curryRight","partial","partialRight"],(function(u){L[u].placeholder=L;})),Wt(["drop","take"],(function(u,g){Re.prototype[u]=function(S){S=S===i?1:Xn(we(S),0);var k=this.__filtered__&&!g?new Re(this):this.clone();return k.__filtered__?k.__takeCount__=Ar(S,k.__takeCount__):k.__views__.push({size:Ar(S,T),type:u+(k.__dir__<0?"Right":"")}),k},Re.prototype[u+"Right"]=function(S){return this.reverse()[u](S).reverse()};})),Wt(["filter","map","takeWhile"],(function(u,g){var S=g+1,k=S==1||S==3;Re.prototype[u]=function(R){var $=this.clone();return $.__iteratees__.push({iteratee:ue(R,3),type:S}),$.__filtered__=$.__filtered__||k,$};})),Wt(["head","last"],(function(u,g){var S="take"+(g?"Right":"");Re.prototype[u]=function(){return this[S](1).value()[0]};})),Wt(["initial","tail"],(function(u,g){var S="drop"+(g?"":"Right");Re.prototype[u]=function(){return this.__filtered__?new Re(this):this[S](1)};})),Re.prototype.compact=function(){return this.filter(b)},Re.prototype.find=function(u){return this.filter(u).head()},Re.prototype.findLast=function(u){return this.reverse().find(u)},Re.prototype.invokeMap=Ie((function(u,g){return typeof u=="function"?new Re(this):this.map((function(S){return As(S,u,g)}))})),Re.prototype.reject=function(u){return this.filter(aa(ue(u)))},Re.prototype.slice=function(u,g){u=we(u);var S=this;return S.__filtered__&&(u>0||g<0)?new Re(S):(u<0?S=S.takeRight(-u):u&&(S=S.drop(u)),g!==i&&(S=(g=we(g))<0?S.dropRight(-g):S.take(g-u)),S)},Re.prototype.takeRightWhile=function(u){return this.reverse().takeWhile(u).reverse()},Re.prototype.toArray=function(){return this.take(T)},Fi(Re.prototype,(function(u,g){var S=/^(?:filter|find|map|reject)|While$/.test(g),k=/^(?:head|last)$/.test(g),R=L[k?"take"+(g=="last"?"Right":""):g],$=k||/^find/.test(g);R&&(L.prototype[g]=function(){var q=this.__wrapped__,et=k?[1]:arguments,lt=q instanceof Re,Et=et[0],wt=lt||ge(q),Mt=function(ie){var Xt=R.apply(L,Ho([ie],et));return k&&Yt?Xt[0]:Xt};wt&&S&&typeof Et=="function"&&Et.length!=1&&(lt=wt=false);var Yt=this.__chain__,Qt=!!this.__actions__.length,oe=$&&!Yt,Ft=lt&&!Qt;if(!$&&wt){q=Ft?q:new Re(this);var Ut=u.apply(q,et);return Ut.__actions__.push({func:zs,args:[Mt],thisArg:i}),new Xr(Ut,Yt)}return oe&&Ft?u.apply(this,et):(Ut=this.thru(Mt),oe?k?Ut.value()[0]:Ut.value():Ut)});})),Wt(["pop","push","shift","sort","splice","unshift"],(function(u){var g=wl[u],S=/^(?:push|sort|unshift)$/.test(u)?"tap":"thru",k=/^(?:pop|shift)$/.test(u);L.prototype[u]=function(){var R=arguments;if(k&&!this.__chain__){var $=this.value();return g.apply(ge($)?$:[],R)}return this[S]((function(q){return g.apply(ge(q)?q:[],R)}))};})),Fi(Re.prototype,(function(u,g){var S=L[g];if(S){var k=S.name+"";an.call(Ri,k)||(Ri[k]=[]),Ri[k].push({name:g,func:S});}})),Ri[Hl(i,2).name]=[{name:"wrapper",func:i}],Re.prototype.clone=function(){var u=new Re(this.__wrapped__);return u.__actions__=mr(this.__actions__),u.__dir__=this.__dir__,u.__filtered__=this.__filtered__,u.__iteratees__=mr(this.__iteratees__),u.__takeCount__=this.__takeCount__,u.__views__=mr(this.__views__),u},Re.prototype.reverse=function(){if(this.__filtered__){var u=new Re(this);u.__dir__=-1,u.__filtered__=true;}else (u=this.clone()).__dir__*=-1;return u},Re.prototype.value=function(){var u=this.__wrapped__.value(),g=this.__dir__,S=ge(u),k=g<0,R=S?u.length:0,$=(function(Ge,le,ye){for(var Tr=-1,Bi=ye.length;++Tr<Bi;){var sa=ye[Tr],wr=sa.size;switch(sa.type){case "drop":Ge+=wr;break;case "dropRight":le-=wr;break;case "take":le=Ar(le,Ge+wr);break;case "takeRight":Ge=Xn(Ge,le-wr);}}return {start:Ge,end:le}})(0,R,this.__views__),q=$.start,et=$.end,lt=et-q,Et=k?et:q-1,wt=this.__iteratees__,Mt=wt.length,Yt=0,Qt=Ar(lt,this.__takeCount__);if(!S||!k&&R==lt&&Qt==lt)return ph(u,this.__actions__);var oe=[];t:for(;lt--&&Yt<Qt;){for(var Ft=-1,Ut=u[Et+=g];++Ft<Mt;){var ie=wt[Ft],Xt=ie.iteratee,he=ie.type,Pe=Xt(Ut);if(he==2)Ut=Pe;else if(!Pe){if(he==1)continue t;break t}}oe[Yt++]=Ut;}return oe},L.prototype.at=nb,L.prototype.chain=function(){return wu(this)},L.prototype.commit=function(){return new Xr(this.value(),this.__chain__)},L.prototype.next=function(){this.__values__===i&&(this.__values__=xp(this.value()));var u=this.__index__>=this.__values__.length;return {done:u,value:u?i:this.__values__[this.__index__++]}},L.prototype.plant=function(u){for(var g,S=this;S instanceof Fl;){var k=Io(S);k.__index__=0,k.__values__=i,g?R.__wrapped__=k:g=k;var R=k;S=S.__wrapped__;}return R.__wrapped__=u,g},L.prototype.reverse=function(){var u=this.__wrapped__;if(u instanceof Re){var g=u;return this.__actions__.length&&(g=new Re(this)),(g=g.reverse()).__actions__.push({func:zs,args:[Xl],thisArg:i}),new Xr(g,this.__chain__)}return this.thru(Xl)},L.prototype.toJSON=L.prototype.valueOf=L.prototype.value=function(){return ph(this.__wrapped__,this.__actions__)},L.prototype.first=L.prototype.head,ka&&(L.prototype[ka]=function(){return this}),L})();on._=Yc,(r=function(){return Yc}.call(e,n,e,t))===i||(t.exports=r);}.call(this);},5161:(t,e,n)=>{var r=n(9932),i=n(7206),o=n(9199),s=n(1469);t.exports=function(c,p){return (s(c)?r:o)(c,i(p,3))};},8306:(t,e,n)=>{var r=n(3369);function i(o,s){if(typeof o!="function"||s!=null&&typeof s!="function")throw new TypeError("Expected a function");var c=function(){var p=arguments,h=s?s.apply(this,p):p[0],v=c.cache;if(v.has(h))return v.get(h);var P=o.apply(this,p);return c.cache=v.set(h,P)||v,P};return c.cache=new(i.Cache||r),c}i.Cache=r,t.exports=i;},2492:(t,e,n)=>{var r=n(2980),i=n(1463)((function(o,s,c){r(o,s,c);}));t.exports=i;},7557:(t,e,n)=>{var r=n(9932),i=n(5990),o=n(7406),s=n(1811),c=n(8363),p=n(696),h=n(9021),v=n(6904),P=h((function(x,T){var I={};if(x==null)return I;var F=false;T=r(T,(function(O){return O=s(O,x),F||(F=O.length>1),O})),c(x,v(x),I),F&&(I=i(I,7,p));for(var A=T.length;A--;)o(I,T[A]);return I}));t.exports=P;},9601:(t,e,n)=>{var r=n(371),i=n(9152),o=n(5403),s=n(327);t.exports=function(c){return o(c)?r(s(c)):i(c)};},9704:(t,e,n)=>{var r=n(2908),i=n(7206),o=n(5076),s=n(1469),c=n(6612);t.exports=function(p,h,v){var P=s(p)?r:o;return v&&c(p,h,v)&&(h=void 0),P(p,i(h,3))};},479:t=>{t.exports=function(){return []};},5062:t=>{t.exports=function(){return false};},8601:(t,e,n)=>{var r=n(4841);t.exports=function(i){return i?(i=r(i))===1/0||i===-1/0?17976931348623157e292*(i<0?-1:1):i==i?i:0:i===0?i:0};},554:(t,e,n)=>{var r=n(8601);t.exports=function(i){var o=r(i),s=o%1;return o==o?s?o-s:o:0};},4841:(t,e,n)=>{var r=n(7561),i=n(3218),o=n(3448),s=/^[-+]0x[0-9a-f]+$/i,c=/^0b[01]+$/i,p=/^0o[0-7]+$/i,h=parseInt;t.exports=function(v){if(typeof v=="number")return v;if(o(v))return NaN;if(i(v)){var P=typeof v.valueOf=="function"?v.valueOf():v;v=i(P)?P+"":P;}if(typeof v!="string")return v===0?v:+v;v=r(v);var x=c.test(v);return x||p.test(v)?h(v.slice(2),x?2:8):s.test(v)?NaN:+v};},9881:(t,e,n)=>{var r=n(8363),i=n(1704);t.exports=function(o){return r(o,i(o))};},9833:(t,e,n)=>{var r=n(531);t.exports=function(i){return i==null?"":r(i)};},2628:(t,e,n)=>{var r=n(7415),i=n(3674);t.exports=function(o){return o==null?[]:r(o,i(o))};},2527:(t,e,n)=>{e.TypedEmitter=n(7187).EventEmitter;},5078:(t,e,n)=>{n.d(e,{fEx:()=>h.fEx,zVd:()=>h.zVd,zu7:()=>h.zu7,dpb:()=>h.dpb,T0E:()=>h.T0E,d4U:()=>h.d4U,nwm:()=>h.nwm,Ijf:()=>h.Ijf,v2N:()=>h.v2N,Mbo:()=>h.Mbo,E34:()=>h.E34,Bkk:()=>h.Bkk,Y92:()=>h.Y92,m06:()=>h.m06,bM9:()=>h.bM9,sZY:()=>v,PLi:()=>h.PLi,yTz:()=>h.yTz,FzK:()=>h.FzK,tvV:()=>h.tvV,ugv:()=>h.ugv,x3v:()=>h.x3v,jAf:()=>h.jAf,u4I:()=>h.u4I,bEP:()=>h.bEP,weZ:()=>h.weZ,uS8:()=>h.uS8,zdd:()=>h.zdd,i2A:()=>h.i2A,fc5:()=>h.fc5,K79:()=>h.K79,$i2:()=>h.$i2,$QI:()=>h.$QI,WJn:()=>h.WJn,Pzm:()=>h.Pzm,Q_D:()=>h.Q_D,lj3:()=>h.lj3,bSK:()=>h.bSK,Eq9:()=>h.Eq9,mKD:()=>h.mKD,_Yx:()=>h._Yx,uMJ:()=>h.uMJ,oiL:()=>h.oiL,Fa6:()=>h.Fa6,hk_:()=>h.hk_,vjn:()=>I,_d$:()=>h._d$,NSU:()=>h.NSU,Eph:()=>h.Eph,g31:()=>h.g31,u9g:()=>h.u9g,aqW:()=>h.aqW,LBz:()=>h.LBz,qYx:()=>h.qYx,X$1:()=>h.X$1,OoB:()=>h.OoB,pDu:()=>h.pDu,rpU:()=>h.rpU,fYe:()=>h.fYe,Pg9:()=>h.Pg9,GBW:()=>h.GBW,vQb:()=>h.vQb,yEZ:()=>h.yEZ,Wky:()=>h.Wky,C2e:()=>h.C2e,Lbh:()=>h.Lbh,RCf:()=>T,AVk:()=>h.AVk,cUI:()=>h.cUI,XHu:()=>h.XHu,cG4:()=>h.cG4,JrM:()=>h.JrM,bII:()=>h.bII,FT8:()=>h.FT8,Pr8:()=>h.Pr8,IZr:()=>h.IZr,$BG:()=>h.$BG,Qj0:()=>h.Qj0,jKp:()=>h.jKp,m5b:()=>h.m5b,wO5:()=>h.wO5,Zr9:()=>h.Zr9,g3t:()=>h.g3t,m72:()=>h.m72,i3Z:()=>h.i3Z,zOd:()=>h.zOd,o_I:()=>h.o_I,bWm:()=>h.bWm,o5f:()=>h.o5f,i4m:()=>h.i4m,sEr:()=>h.sEr,GAT:()=>h.GAT,iKc:()=>h.iKc,Tex:()=>h.Tex,XsQ:()=>h.XsQ,U9t:()=>h.U9t,OpC:()=>h.OpC,bgy:()=>h.bgy,jPD:()=>h.jPD,Q$1:()=>h.Q$1,Cmg:()=>h.Cmg,$Iz:()=>h.$Iz,tIq:()=>h.tIq,zHr:()=>h.zHr,ZeH:()=>h.ZeH,$Av:()=>h.$Av,TpL:()=>h.TpL,pWb:()=>h.pWb,roX:()=>h.roX,RXg:()=>h.RXg,_xu:()=>h._xu,RVX:()=>h.RVX,Fd7:()=>h.Fd7,N9K:()=>h.N9K,do1:()=>h.do1,hH:()=>h.hH,K0T:()=>h.K0T,p7R:()=>h.p7R,E7k:()=>h.E7k,Mal:()=>h.Mal,KeG:()=>h.KeG,uMn:()=>h.uMn,qBr:()=>h.qBr,DFP:()=>h.DFP,m76:()=>h.m76,$jJ:()=>h.$jJ,B8X:()=>h.B8X,N5j:()=>h.N5j,Us3:()=>h.Us3,isD:()=>h.isD,nN6:()=>h.nN6,ini:()=>o,VsH:()=>x,Kyg:()=>h.Kyg,XY6:()=>h.XY6,puT:()=>h.puT,bGN:()=>h.bGN,$Bh:()=>h.$Bh,hVT:()=>h.hVT,k8_:()=>h.k8_,wn5:()=>h.wn5,lgL:()=>h.lgL,VeJ:()=>h.VeJ,pSI:()=>h.pSI,ctk:()=>P,gpE:()=>h.gpE,PVi:()=>h.PVi,opi:()=>Ru,AQp:()=>h.AQp,Bve:()=>h.Bve,zBW:()=>h.zBW,LpH:()=>h.LpH,q5V:()=>h.q5V,BoX:()=>h.BoX,zv6:()=>h.zv6,RzF:()=>h.RzF,iI3:()=>h.iI3,jCI:()=>h.jCI,OeJ:()=>h.OeJ,ab2:()=>h.ab2,TVs:()=>h.TVs,JU:()=>h.JU,QdX:()=>h.QdX,Kf7:()=>h.Kf7,LtK:()=>h.LtK,r6R:()=>h.r6R,fvX:()=>h.fvX,r4r:()=>h.r4r,FcI:()=>h.FcI,qw4:()=>h.qw4,Cc7:()=>h.Cc7,kd9:()=>h.kd9,bOA:()=>h.bOA,qXR:()=>h.qXR,yGq:()=>h.yGq,ZD9:()=>h.ZD9,wEB:()=>h.wEB,YGW:()=>h.YGW,Chb:()=>h.Chb,_HY:()=>h._HY,cMT:()=>h.cMT,p_C:()=>h.p_C,Ehw:()=>h.Ehw,JkE:()=>h.JkE,ku9:()=>h.ku9,$Vq:()=>h.$Vq,QZw:()=>h.QZw,q6C:()=>h.q6C,YlF:()=>h.YlF,rDA:()=>h.rDA,CjA:()=>h.CjA,u0j:()=>h.u0j,Zam:()=>h.Zam,JDz:()=>h.JDz,ZSL:()=>h.ZSL,dO5:()=>h.dO5,K5h:()=>h.K5h,UK7:()=>h.UK7,JyR:()=>h.JyR,GHz:()=>h.GHz,_He:()=>h._He,nM6:()=>h.nM6,zWW:()=>h.zWW,xrg:()=>h.xrg,bj8:()=>h.bj8,bGH:()=>h.bGH,cTO:()=>h.cTO,SrV:()=>h.SrV,Xm9:()=>h.Xm9,PO0:()=>h.PO0,Yo2:()=>h.Yo2,ueJ:()=>h.ueJ,w1y:()=>h.w1y,c06:()=>h.c06,lS0:()=>h.lS0,abb:()=>h.abb,ird:()=>h.ird,_oj:()=>h._oj,e1Q:()=>h.e1Q,Ugm:()=>h.Ugm,hvo:()=>h.hvo,tV1:()=>h.tV1,FL0:()=>h.FL0,Dxn:()=>h.Dxn,G6j:()=>h.G6j,eSW:()=>h.eSW,DWP:()=>h.DWP,zjf:()=>h.zjf,Eam:()=>h.Eam,URA:()=>h.URA,yBL:()=>h.yBL,SQC:()=>h.SQC,_q5:()=>h._q5,o88:()=>h.o88,cUf:()=>h.cUf,YVG:()=>h.YVG,J5K:()=>h.J5K,nOi:()=>h.nOi,yhH:()=>h.yhH,HsO:()=>h.HsO,XqI:()=>h.XqI,wRo:()=>h.wRo,hYU:()=>h.hYU,UAI:()=>h.UAI,PNd:()=>h.PNd,N9N:()=>h.N9N,$02:()=>h.$02,Dc_:()=>h.Dc_,bk4:()=>h.bk4,p13:()=>h.p13,mGS:()=>h.mGS,_gQ:()=>h._gQ,Dfv:()=>h.Dfv,bd6:()=>h.bd6,eKV:()=>h.eKV,EQD:()=>h.EQD,QNm:()=>h.QNm,yaX:()=>h.yaX,X3h:()=>h.X3h,Buv:()=>h.Buv,_yy:()=>h._yy,l3m:()=>h.l3m,FoD:()=>h.FoD,O0T:()=>h.O0T,yyj:()=>h.yyj,rCU:()=>h.rCU,l9N:()=>h.l9N,EOH:()=>h.EOH,LkV:()=>h.LkV,X$v:()=>h.X$v,ZPm:()=>Wh,mKo:()=>h.mKo});var r={};n.r(r),n.d(r,{FunctionToString:()=>Na,InboundFilters:()=>eo});var i={};n.r(i),n.d(i,{Breadcrumbs:()=>aa,Dedupe:()=>ge,GlobalHandlers:()=>oa,HttpContext:()=>mi,LinkedErrors:()=>Rr,TryCatch:()=>Hs});var o,s=n(4721),c=n.n(s);(function(f){f.ALL="ALL",f.NONE="NONE",f.LOG="LOG",f.ERROR="ERROR";})(o||(o={}));var p=(function(){function f(a,l){this.logger=a,this.logLevel=l;}return f.prototype.error=function(a,l){this.logLevel!==o.NONE&&this.logger.error("[Stigg] ".concat(a),l||{});},f.prototype.log=function(a,l){c()([o.ERROR,o.NONE],this.logLevel)||this.logger.log("[Stigg] ".concat(a),l||{});},f.prototype.debug=function(a,l){c()([o.LOG,o.ALL],this.logLevel)&&this.logger.debug("[Stigg] ".concat(a),l||{});},f})(),h=n(890),v={isFallback:true,hasAccess:false,accessDeniedReason:h.fEx.Unknown},P={isFallback:true,hasAccess:false,isUnlimited:false,accessDeniedReason:h.fEx.Unknown},x={isFallback:true,hasAccess:false,isUnlimited:false,currentUsage:0,requestedUsage:1,accessDeniedReason:h.fEx.Unknown},T={isFallback:true,hasAccess:false,enumValues:[],accessDeniedReason:h.fEx.Unknown},I=(function(){function f(a){Object.assign(this,a);}return f.prototype.getActiveSubscriptions=function(){return this.subscriptions.filter((function(a){return a.status===h.yhH.Active}))},f.prototype.getActiveTrials=function(){return this.subscriptions.filter((function(a){return a.status===h.yhH.InTrial}))},f.prototype.getActivePromotionalEntitlements=function(){return this.promotionalEntitlements.filter((function(a){return a.status===h.$Vq.Active}))},f})(),F=n(6486);let A=(function(){function f(a,l){this.client=a,this.edgeApiClient=l;}return f.prototype.getSdkConfiguration=function(){return this.edgeApiClient?this.edgeApiClient.getSdkConfiguration():this.client.query({query:h.N9K})},f})();var O=function(){return O=Object.assign||function(f){for(var a,l=1,d=arguments.length;l<d;l++)for(var m in a=arguments[l])Object.prototype.hasOwnProperty.call(a,m)&&(f[m]=a[m]);return f},O.apply(this,arguments)},N=(function(){function f(a,l){this.client=a,this.edgeApiClient=l;}return f.prototype.getPaywall=function(a){var l=a.productId,d=a.customerId,m=a.resourceId,y=a.context,b=a.billingCountryCode,E=a.includeHiddenPlans;return !d&&this.edgeApiClient?this.edgeApiClient.getPaywall(l,b,E):this.client.query({query:h.RVX,fetchPolicy:"no-cache",variables:{input:O(O(O(O(O(O({},l?{productId:l}:{}),d?{customerId:d}:{}),m?{resourceId:m}:{}),y?{context:y}:{}),b?{billingCountryCode:b}:{}),E?{includeHiddenPlans:E}:{})}})},f})();let V=N;var G=function(f,a,l,d){return new(l||(l=Promise))((function(m,y){function b(D){try{w(d.next(D));}catch(_){y(_);}}function E(D){try{w(d.throw(D));}catch(_){y(_);}}function w(D){var _;D.done?m(D.value):(_=D.value,_ instanceof l?_:new l((function(M){M(_);}))).then(b,E);}w((d=d.apply(f,[])).next());}))},X=function(f,a){var l,d,m,y,b={label:0,sent:function(){if(1&m[0])throw m[1];return m[1]},trys:[],ops:[]};return y={next:E(0),throw:E(1),return:E(2)},typeof Symbol=="function"&&(y[Symbol.iterator]=function(){return this}),y;function E(w){return function(D){return (function(_){if(l)throw new TypeError("Generator is already executing.");for(;b;)try{if(l=1,d&&(m=2&_[0]?d.return:_[0]?d.throw||((m=d.return)&&m.call(d),0):d.next)&&!(m=m.call(d,_[1])).done)return m;switch(d=0,m&&(_=[2&_[0],m.value]),_[0]){case 0:case 1:m=_;break;case 4:return b.label++,{value:_[1],done:!1};case 5:b.label++,d=_[1],_=[0];continue;case 7:_=b.ops.pop(),b.trys.pop();continue;default:if(!((m=(m=b.trys).length>0&&m[m.length-1])||_[0]!==6&&_[0]!==2)){b=0;continue}if(_[0]===3&&(!m||_[1]>m[0]&&_[1]<m[3])){b.label=_[1];break}if(_[0]===6&&b.label<m[1]){b.label=m[1],m=_;break}if(m&&b.label<m[2]){b.label=m[2],b.ops.push(_);break}m[2]&&b.ops.pop(),b.trys.pop();continue}_=a.call(f,b);}catch(M){_=[6,M],d=0;}finally{l=m=0;}if(5&_[0])throw _[1];return {value:_[0]?_[1]:void 0,done:true}})([w,D])}}},nt=(function(){function f(a,l){this.client=a,this.edgeApiClient=l;}return f.prototype.getCustomer=function(a){return this.client.query({query:h.ZeH,variables:{input:{customerId:a}},fetchPolicy:"no-cache"})},f.prototype.getActiveSubscriptions=function(a,l){return G(this,void 0,void 0,(function(){return X(this,(function(d){return [2,this.client.query({query:h.OpC,variables:{input:(0, F.isArray)(l)?{customerId:a,resourceIds:l}:{customerId:a,resourceId:l}},fetchPolicy:"no-cache"})]}))}))},f.prototype.getActiveSubscriptionsList=function(a,l){return G(this,void 0,void 0,(function(){return X(this,(function(d){return this.edgeApiClient?[2,this.edgeApiClient.getActiveSubscriptionsList(a,l)]:[2,this.client.query({query:h.bgy,variables:{input:(0, F.isArray)(l)?{customerId:a,resourceIds:l}:{customerId:a,resourceId:l}},fetchPolicy:"no-cache"})]}))}))},f.prototype.getSubscription=function(a){return G(this,void 0,void 0,(function(){return X(this,(function(l){return [2,this.client.query({query:h.do1,variables:{input:{subscriptionId:a}},fetchPolicy:"no-cache"})]}))}))},f.prototype.getCustomerPortal=function(a,l,d){return this.client.query({query:h.$Av,variables:{input:{customerId:a,resourceId:l,productId:d}},fetchPolicy:"no-cache"})},f.prototype.fetchUsageHistory=function(a){var l=a.customerId,d=a.resourceId,m=a.endDate,y=a.startDate,b=a.featureId;return G(this,void 0,void 0,(function(){return X(this,(function(E){return [2,this.client.query({query:h.K0T,variables:{usageHistoryInput:{customerRefId:l,featureRefId:b,resourceRefId:d,startDate:y,endDate:m||new Date}},fetchPolicy:"no-cache"})]}))}))},f})();let st=nt,U=(function(){function f(a){this.client=a;}return f.prototype.getCoupons=function(){return this.client.query({query:h.Q$1,fetchPolicy:"no-cache"})},f})();var j=function(){return j=Object.assign||function(f){for(var a,l=1,d=arguments.length;l<d;l++)for(var m in a=arguments[l])Object.prototype.hasOwnProperty.call(a,m)&&(f[m]=a[m]);return f},j.apply(this,arguments)},ut=(function(){function f(a){this.client=a;}return f.prototype.applySubscription=function(a){var l=a.customerId,d=a.payingCustomerId,m=a.planId,y=a.paymentMethodId,b=a.addons,E=a.billableFeatures,w=a.billingInformation,D=a.billingCountryCode,_=a.billingId,M=a.billingPeriod,B=a.metadata,H=a.promotionCode,K=a.resourceId,J=a.skipTrial,tt=a.startDate,yt=a.unitQuantity,Rt=a.scheduleStrategy;return this.client.mutate({mutation:h.Bkk,variables:{input:{customerId:l,payingCustomerId:d,planId:m,paymentMethodId:y,startDate:tt,addons:b,billingId:_,billingPeriod:M,unitQuantity:yt,billableFeatures:E,additionalMetaData:B,resourceId:K,skipTrial:J,promotionCode:H,billingInformation:this.mapBillingInformation(w),billingCountryCode:D,scheduleStrategy:Rt}}})},f.prototype.getSubscriptions=function(a,l,d,m,y){return y===void 0&&(y={limit:10}),b=this,E=void 0,D=function(){return (function(_,M){var B,H,K,J,tt={label:0,sent:function(){if(1&K[0])throw K[1];return K[1]},trys:[],ops:[]};return J={next:yt(0),throw:yt(1),return:yt(2)},typeof Symbol=="function"&&(J[Symbol.iterator]=function(){return this}),J;function yt(Rt){return function(Zt){return (function(zt){if(B)throw new TypeError("Generator is already executing.");for(;tt;)try{if(B=1,H&&(K=2&zt[0]?H.return:zt[0]?H.throw||((K=H.return)&&K.call(H),0):H.next)&&!(K=K.call(H,zt[1])).done)return K;switch(H=0,K&&(zt=[2&zt[0],K.value]),zt[0]){case 0:case 1:K=zt;break;case 4:return tt.label++,{value:zt[1],done:!1};case 5:tt.label++,H=zt[1],zt=[0];continue;case 7:zt=tt.ops.pop(),tt.trys.pop();continue;default:if(!((K=(K=tt.trys).length>0&&K[K.length-1])||zt[0]!==6&&zt[0]!==2)){tt=0;continue}if(zt[0]===3&&(!K||zt[1]>K[0]&&zt[1]<K[3])){tt.label=zt[1];break}if(zt[0]===6&&tt.label<K[1]){tt.label=K[1],K=zt;break}if(K&&tt.label<K[2]){tt.label=K[2],tt.ops.push(zt);break}K[2]&&tt.ops.pop(),tt.trys.pop();continue}zt=M.call(_,tt);}catch(Bt){zt=[6,Bt],H=0;}finally{B=K=0;}if(5&zt[0])throw zt[1];return {value:zt[0]?zt[1]:void 0,done:true}})([Rt,Zt])}}})(this,(function(_){return [2,this.client.query({query:h.hH,variables:j({filter:j(j(j(j({},a?{customerId:{eq:a}}:{}),l?{resourceId:(0, F.isArray)(l)?{in:l}:{eq:l}}:{}),d?{status:(0, F.isArray)(d)?{in:d}:{eq:d}}:{}),m?{productId:(0, F.isArray)(m)?{in:m}:{eq:m}}:{})},y?{paging:j({},y.startingAfter?{first:y.limit,after:y.startingAfter}:y.endingBefore?{last:y.limit,before:y.endingBefore}:{first:y.limit})}:{}),fetchPolicy:"no-cache"})]}))},new((w=void 0)||(w=Promise))((function(_,M){function B(J){try{K(D.next(J));}catch(tt){M(tt);}}function H(J){try{K(D.throw(J));}catch(tt){M(tt);}}function K(J){var tt;J.done?_(J.value):(tt=J.value,tt instanceof w?tt:new w((function(yt){yt(tt);}))).then(B,H);}K((D=D.apply(b,E||[])).next());}));var b,E,w,D;},f.prototype.checkoutState=function(a){var l=a.customerId,d=a.resourceId,m=a.planId,y=a.billingCountryCode;return this.client.query({query:h.jPD,fetchPolicy:"no-cache",variables:{input:j(j({planId:m,customerId:l},d?{resourceId:d}:{}),y?{billingCountryCode:y}:{})}})},f.prototype.mapBillingInformation=function(a){if(a)return {taxRateIds:a==null?void 0:a.taxRateIds,billingAddress:a==null?void 0:a.billingAddress,integrationId:a==null?void 0:a.integrationId,prorationBehavior:a==null?void 0:a.prorationBehavior}},f})();let Y=ut;var at=function(f,a,l,d){return new(l||(l=Promise))((function(m,y){function b(D){try{w(d.next(D));}catch(_){y(_);}}function E(D){try{w(d.throw(D));}catch(_){y(_);}}function w(D){var _;D.done?m(D.value):(_=D.value,_ instanceof l?_:new l((function(M){M(_);}))).then(b,E);}w((d=d.apply(f,[])).next());}))},pt=function(f,a){var l,d,m,y,b={label:0,sent:function(){if(1&m[0])throw m[1];return m[1]},trys:[],ops:[]};return y={next:E(0),throw:E(1),return:E(2)},typeof Symbol=="function"&&(y[Symbol.iterator]=function(){return this}),y;function E(w){return function(D){return (function(_){if(l)throw new TypeError("Generator is already executing.");for(;b;)try{if(l=1,d&&(m=2&_[0]?d.return:_[0]?d.throw||((m=d.return)&&m.call(d),0):d.next)&&!(m=m.call(d,_[1])).done)return m;switch(d=0,m&&(_=[2&_[0],m.value]),_[0]){case 0:case 1:m=_;break;case 4:return b.label++,{value:_[1],done:!1};case 5:b.label++,d=_[1],_=[0];continue;case 7:_=b.ops.pop(),b.trys.pop();continue;default:if(!((m=(m=b.trys).length>0&&m[m.length-1])||_[0]!==6&&_[0]!==2)){b=0;continue}if(_[0]===3&&(!m||_[1]>m[0]&&_[1]<m[3])){b.label=_[1];break}if(_[0]===6&&b.label<m[1]){b.label=m[1],m=_;break}if(m&&b.label<m[2]){b.label=m[2],b.ops.push(_);break}m[2]&&b.ops.pop(),b.trys.pop();continue}_=a.call(f,b);}catch(M){_=[6,M],d=0;}finally{l=m=0;}if(5&_[0])throw _[1];return {value:_[0]?_[1]:void 0,done:true}})([w,D])}}},dt=(function(){function f(a){this.client=a;}return f.prototype.estimateSubscription=function(a){var l,d;return at(this,void 0,void 0,(function(){return pt(this,(function(m){return [2,this.client.mutate({mutation:h.m5b,variables:{input:{resourceId:a.resourceId,planId:a.planId,customerId:a.customerId,payingCustomerId:a.payingCustomerId,startDate:a.startDate,addons:a.addons,billingPeriod:a.billingPeriod,priceUnitAmount:a.unitQuantity,billableFeatures:a.billableFeatures,billingInformation:{taxRateIds:(l=a==null?void 0:a.billingInformation)===null||l===void 0?void 0:l.taxRateIds,taxPercentage:(d=a==null?void 0:a.billingInformation)===null||d===void 0?void 0:d.taxPercentage},promotionCode:a.promotionCode,billingCountryCode:a.billingCountryCode,skipTrial:a.skipTrial}}})]}))}))},f.prototype.estimateSubscriptionUpdate=function(a){return at(this,void 0,void 0,(function(){return pt(this,(function(l){return [2,this.client.mutate({mutation:h.wO5,variables:{input:{subscriptionId:a.subscriptionId,unitQuantity:a.unitQuantity,billableFeatures:a.billableFeatures,addons:a.addons,promotionCode:a.promotionCode}}})]}))}))},f.prototype.previewNextInvoice=function(a){return at(this,void 0,void 0,(function(){return pt(this,(function(l){return [2,this.client.mutate({mutation:h.yGq,fetchPolicy:"no-cache",variables:{input:{subscriptionId:a.subscriptionId}}})]}))}))},f.prototype.previewSubscription=function(a){var l,d,m;return at(this,void 0,void 0,(function(){return pt(this,(function(y){return [2,this.client.mutate({mutation:h.ZD9,fetchPolicy:"no-cache",variables:{input:{planId:a.planId,customerId:a.customerId,payingCustomerId:a.payingCustomerId,resourceId:a.resourceId,startDate:a.startDate,addons:a.addons,billingPeriod:a.billingPeriod,billableFeatures:a.billableFeatures,promotionCode:a.promotionCode,scheduleStrategy:a.scheduleStrategy,billingCountryCode:a.billingCountryCode,billingInformation:{taxRateIds:(l=a==null?void 0:a.billingInformation)===null||l===void 0?void 0:l.taxRateIds,taxPercentage:(d=a==null?void 0:a.billingInformation)===null||d===void 0?void 0:d.taxPercentage,billingAddress:(m=a==null?void 0:a.billingInformation)===null||m===void 0?void 0:m.billingAddress}}}})]}))}))},f})();let mt=dt;var Ct=function(){return Ct=Object.assign||function(f){for(var a,l=1,d=arguments.length;l<d;l++)for(var m in a=arguments[l])Object.prototype.hasOwnProperty.call(a,m)&&(f[m]=a[m]);return f},Ct.apply(this,arguments)},jt=(function(){function f(a){this.client=a;}return f.prototype.getMockPaywall=function(a){var l=a.productId,d=a.customerId,m=a.context;return this.client.query({query:h._xu,fetchPolicy:"no-cache",variables:{input:Ct(Ct(Ct({},l?{productId:l}:{}),d?{customerId:d}:{}),m?{context:m}:{})}})},f})();let Gt=jt;var Jt=(function(){function f(a){this.client=a;}return f.prototype.getUsageHistoryV2=function(a){return l=this,d=void 0,y=function(){return (function(b,E){var w,D,_,M,B={label:0,sent:function(){if(1&_[0])throw _[1];return _[1]},trys:[],ops:[]};return M={next:H(0),throw:H(1),return:H(2)},typeof Symbol=="function"&&(M[Symbol.iterator]=function(){return this}),M;function H(K){return function(J){return (function(tt){if(w)throw new TypeError("Generator is already executing.");for(;B;)try{if(w=1,D&&(_=2&tt[0]?D.return:tt[0]?D.throw||((_=D.return)&&_.call(D),0):D.next)&&!(_=_.call(D,tt[1])).done)return _;switch(D=0,_&&(tt=[2&tt[0],_.value]),tt[0]){case 0:case 1:_=tt;break;case 4:return B.label++,{value:tt[1],done:!1};case 5:B.label++,D=tt[1],tt=[0];continue;case 7:tt=B.ops.pop(),B.trys.pop();continue;default:if(!((_=(_=B.trys).length>0&&_[_.length-1])||tt[0]!==6&&tt[0]!==2)){B=0;continue}if(tt[0]===3&&(!_||tt[1]>_[0]&&tt[1]<_[3])){B.label=tt[1];break}if(tt[0]===6&&B.label<_[1]){B.label=_[1],_=tt;break}if(_&&B.label<_[2]){B.label=_[2],B.ops.push(tt);break}_[2]&&B.ops.pop(),B.trys.pop();continue}tt=E.call(b,B);}catch(yt){tt=[6,yt],D=0;}finally{w=_=0;}if(5&tt[0])throw tt[1];return {value:tt[0]?tt[1]:void 0,done:true}})([K,J])}}})(this,(function(b){return [2,this.client.query({query:h.p7R,variables:{input:a},fetchPolicy:"no-cache"})]}))},new((m=void 0)||(m=Promise))((function(b,E){function w(M){try{_(y.next(M));}catch(B){E(B);}}function D(M){try{_(y.throw(M));}catch(B){E(B);}}function _(M){var B;M.done?b(M.value):(B=M.value,B instanceof m?B:new m((function(H){H(B);}))).then(w,D);}_((y=y.apply(l,d||[])).next());}));var l,d,m,y;},f})(),ee=function(f,a,l,d){return new(l||(l=Promise))((function(m,y){function b(D){try{w(d.next(D));}catch(_){y(_);}}function E(D){try{w(d.throw(D));}catch(_){y(_);}}function w(D){var _;D.done?m(D.value):(_=D.value,_ instanceof l?_:new l((function(M){M(_);}))).then(b,E);}w((d=d.apply(f,[])).next());}))},re=function(f,a){var l,d,m,y,b={label:0,sent:function(){if(1&m[0])throw m[1];return m[1]},trys:[],ops:[]};return y={next:E(0),throw:E(1),return:E(2)},typeof Symbol=="function"&&(y[Symbol.iterator]=function(){return this}),y;function E(w){return function(D){return (function(_){if(l)throw new TypeError("Generator is already executing.");for(;b;)try{if(l=1,d&&(m=2&_[0]?d.return:_[0]?d.throw||((m=d.return)&&m.call(d),0):d.next)&&!(m=m.call(d,_[1])).done)return m;switch(d=0,m&&(_=[2&_[0],m.value]),_[0]){case 0:case 1:m=_;break;case 4:return b.label++,{value:_[1],done:!1};case 5:b.label++,d=_[1],_=[0];continue;case 7:_=b.ops.pop(),b.trys.pop();continue;default:if(!((m=(m=b.trys).length>0&&m[m.length-1])||_[0]!==6&&_[0]!==2)){b=0;continue}if(_[0]===3&&(!m||_[1]>m[0]&&_[1]<m[3])){b.label=_[1];break}if(_[0]===6&&b.label<m[1]){b.label=m[1],m=_;break}if(m&&b.label<m[2]){b.label=m[2],b.ops.push(_);break}m[2]&&b.ops.pop(),b.trys.pop();continue}_=a.call(f,b);}catch(M){_=[6,M],d=0;}finally{l=m=0;}if(5&_[0])throw _[1];return {value:_[0]?_[1]:void 0,done:true}})([w,D])}}};let Ee=(function(){function f(a){this.client=a;}return f.prototype.getCreditBalance=function(a){return ee(this,void 0,void 0,(function(){return re(this,(function(l){return [2,this.client.query({query:h.Cmg,variables:{input:a},fetchPolicy:"no-cache"})]}))}))},f.prototype.getCreditGrants=function(a){return ee(this,void 0,void 0,(function(){return re(this,(function(l){return [2,this.client.query({query:h.$Iz,variables:{input:a},fetchPolicy:"no-cache"})]}))}))},f.prototype.getCreditLedger=function(a){return ee(this,void 0,void 0,(function(){return re(this,(function(l){return [2,this.client.query({query:h.tIq,variables:{input:a},fetchPolicy:"no-cache"})]}))}))},f.prototype.getCreditUsage=function(a){return ee(this,void 0,void 0,(function(){return re(this,(function(l){return [2,this.client.query({query:h.zHr,variables:{input:a},fetchPolicy:"no-cache"})]}))}))},f})(),je=(function(){function f(a){this.client=a;}return f.prototype.createPaymentSession=function(a){return this.client.mutate({mutation:h.$QI,variables:{input:a}})},f})(),sn=function(f,a){this.sdkConfiguration=new A(f,a),this.paywall=new V(f,a),this.subscriptions=new Y(f),this.mockPaywall=new Gt(f),this.customers=new st(f,a),this.coupons=new U(f),this.subscriptionEstimations=new mt(f),this.usageHistoryApi=new Jt(f),this.credits=new Ee(f),this.checkout=new je(f);};var Ze=n(1609),Pn=n.n(Ze),Gn=n(2492),ln=n.n(Gn),Ke=h.PO0.JsClientSdk,dn="js-client-sdk",or=["localhost","127.0.0.1","::1"];function _e(f){var a=new URL(f);return or.includes(a.hostname)?a.port="3060":a.hostname="edge.".concat(a.hostname),a.toString().slice(0,-1)}function De(f){var a=f.customerId;if(!a||Pn()(a))throw new Error("You must set customer ID first, use setCustomerId function or pass it via the constructor");return a}var vr=function(f,a){return vr=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(l,d){l.__proto__=d;}||function(l,d){for(var m in d)Object.prototype.hasOwnProperty.call(d,m)&&(l[m]=d[m]);},vr(f,a)};function Ve(f,a){if(typeof a!="function"&&a!==null)throw new TypeError("Class extends value "+String(a)+" is not a constructor or null");function l(){this.constructor=f;}vr(f,a),f.prototype=a===null?Object.create(a):(l.prototype=a.prototype,new l);}var bt=function(){return bt=Object.assign||function(f){for(var a,l=1,d=arguments.length;l<d;l++)for(var m in a=arguments[l])Object.prototype.hasOwnProperty.call(a,m)&&(f[m]=a[m]);return f},bt.apply(this,arguments)};function ar(f,a){var l={};for(var d in f)Object.prototype.hasOwnProperty.call(f,d)&&a.indexOf(d)<0&&(l[d]=f[d]);if(f!=null&&typeof Object.getOwnPropertySymbols=="function"){var m=0;for(d=Object.getOwnPropertySymbols(f);m<d.length;m++)a.indexOf(d[m])<0&&Object.prototype.propertyIsEnumerable.call(f,d[m])&&(l[d[m]]=f[d[m]]);}return l}function sr(f,a,l,d){return new(l||(l=Promise))((function(m,y){function b(D){try{w(d.next(D));}catch(_){y(_);}}function E(D){try{w(d.throw(D));}catch(_){y(_);}}function w(D){var _;D.done?m(D.value):(_=D.value,_ instanceof l?_:new l((function(M){M(_);}))).then(b,E);}w((d=d.apply(f,[])).next());}))}function Jn(f,a){var l,d,m,y,b={label:0,sent:function(){if(1&m[0])throw m[1];return m[1]},trys:[],ops:[]};return y={next:E(0),throw:E(1),return:E(2)},typeof Symbol=="function"&&(y[Symbol.iterator]=function(){return this}),y;function E(w){return function(D){return (function(_){if(l)throw new TypeError("Generator is already executing.");for(;b;)try{if(l=1,d&&(m=2&_[0]?d.return:_[0]?d.throw||((m=d.return)&&m.call(d),0):d.next)&&!(m=m.call(d,_[1])).done)return m;switch(d=0,m&&(_=[2&_[0],m.value]),_[0]){case 0:case 1:m=_;break;case 4:return b.label++,{value:_[1],done:!1};case 5:b.label++,d=_[1],_=[0];continue;case 7:_=b.ops.pop(),b.trys.pop();continue;default:if(!((m=(m=b.trys).length>0&&m[m.length-1])||_[0]!==6&&_[0]!==2)){b=0;continue}if(_[0]===3&&(!m||_[1]>m[0]&&_[1]<m[3])){b.label=_[1];break}if(_[0]===6&&b.label<m[1]){b.label=m[1],m=_;break}if(m&&b.label<m[2]){b.label=m[2],b.ops.push(_);break}m[2]&&b.ops.pop(),b.trys.pop();continue}_=a.call(f,b);}catch(M){_=[6,M],d=0;}finally{l=m=0;}if(5&_[0])throw _[1];return {value:_[0]?_[1]:void 0,done:true}})([w,D])}}}function lr(f,a,l){if(l||arguments.length===2)for(var d,m=0,y=a.length;m<y;m++)!d&&m in a||(d||(d=Array.prototype.slice.call(a,0,m)),d[m]=a[m]);return f.concat(d||Array.prototype.slice.call(a))}var wi=function(f,a){return wi=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(l,d){l.__proto__=d;}||function(l,d){for(var m in d)Object.prototype.hasOwnProperty.call(d,m)&&(l[m]=d[m]);},wi(f,a)},vo="Invariant Violation",jr=Object.setPrototypeOf,Co=jr===void 0?function(f,a){return f.__proto__=a,f}:jr,Ce=(function(f){function a(l){l===void 0&&(l=vo);var d=f.call(this,typeof l=="number"?vo+": "+l+" (see https://github.com/apollographql/invariant-packages)":l)||this;return d.framesToPop=1,d.name=vo,Co(d,a.prototype),d}return (function(l,d){if(typeof d!="function"&&d!==null)throw new TypeError("Class extends value "+String(d)+" is not a constructor or null");function m(){this.constructor=l;}wi(l,d),l.prototype=d===null?Object.create(d):(m.prototype=d.prototype,new m);})(a,f),a})(Error);function Vt(f,a){if(!f)throw new Ce(a)}var gt=["debug","log","warn","error","silent"],ot=gt.indexOf("log");function Z(f){return function(){if(gt.indexOf(f)>=ot){var a=console[f]||console.log;return a.apply(console,arguments)}}}function it(f){try{return f()}catch(a){}}(function(f){f.debug=Z("debug"),f.log=Z("log"),f.warn=Z("warn"),f.error=Z("error");})(Vt||(Vt={}));let _t=it((function(){return globalThis}))||it((function(){return window}))||it((function(){return self}))||it((function(){return n.g}))||it((function(){return Function("return this")()}));var ft="__",Lt=[ft,ft].join("DEV");let It=(function(){try{return !!__DEV__}catch(f){return Object.defineProperty(_t,Lt,{value:it((function(){return "production"}))!=="production",enumerable:false,configurable:true,writable:true}),_t[Lt]}})();function Nt(f){try{return f()}catch(a){}}var se=Nt((function(){return globalThis}))||Nt((function(){return window}))||Nt((function(){return self}))||Nt((function(){return n.g}))||Nt((function(){return Function("return this")()})),ne=false;function kn(f){return Array.isArray(f)&&f.length>0}!se||Nt((function(){return "production"}))||Nt((function(){return process}))||(Object.defineProperty(se,"process",{value:{env:{NODE_ENV:"production"}},configurable:true,enumerable:false,writable:true}),ne=true),n(143).H,ne&&(delete se.process,ne=false),__DEV__?Vt(typeof It=="boolean",It):Vt(typeof It=="boolean",38);var Ae=(function(f){function a(l){var d,m,y=l.graphQLErrors,b=l.clientErrors,E=l.networkError,w=l.errorMessage,D=l.extraInfo,_=f.call(this,w)||this;return _.graphQLErrors=y||[],_.clientErrors=b||[],_.networkError=E||null,_.message=w||(m="",(kn((d=_).graphQLErrors)||kn(d.clientErrors))&&(d.graphQLErrors||[]).concat(d.clientErrors||[]).forEach((function(M){var B=M?M.message:"Error message not found.";m+=B+`
2322
+ }`;var Ft=a((function(){return En(et,Qt+"return "+Mt).apply(i,lt)}));if(Ft.source=Mt,tc(Ft))throw Ft;return Ft},L.times=function(u,g){if((u=we(u))<1||u>P)return [];var S=T,k=Ar(u,T);g=ue(g),u-=T;for(var F=Ed(k,g);++S<u;)g(S);return F},L.toFinite=Ao,L.toInteger=we,L.toLength=Ep,L.toLower=function(u){return qe(u).toLowerCase()},L.toNumber=ei,L.toSafeInteger=function(u){return u?xo(we(u),-9007199254740991,P):u===0?u:0},L.toString=qe,L.toUpper=function(u){return qe(u).toUpperCase()},L.trim=function(u,g,S){if((u=qe(u))&&(S||g===i))return _d(u);if(!u||!(g=Jr(g)))return u;var k=Qr(u),F=Qr(g);return Jo(k,vs(k,F),Td(k,F)+1).join("")},L.trimEnd=function(u,g,S){if((u=qe(u))&&(S||g===i))return u.slice(0,zf(u)+1);if(!u||!(g=Jr(g)))return u;var k=Qr(u);return Jo(k,0,Td(k,Qr(g))+1).join("")},L.trimStart=function(u,g,S){if((u=qe(u))&&(S||g===i))return u.replace(wi,"");if(!u||!(g=Jr(g)))return u;var k=Qr(u);return Jo(k,vs(k,Qr(g))).join("")},L.truncate=function(u,g){var S=30,k="...";if(Bn(g)){var F="separator"in g?g.separator:F;S="length"in g?we(g.length):S,k="omission"in g?Jr(g.omission):k;}var $=(u=qe(u)).length;if(Nn(u)){var q=Qr(u);$=q.length;}if(S>=$)return u;var et=S-qo(k);if(et<1)return k;var lt=q?Jo(q,0,et).join(""):u.slice(0,et);if(F===i)return lt+k;if(q&&(et+=lt.length-et),Cp(F)){if(u.slice(et).search(F)){var Et,wt=lt;for(F.global||(F=Cs(F.source,qe(it.exec(F))+"g")),F.lastIndex=0;Et=F.exec(wt);)var Mt=Et.index;lt=lt.slice(0,Mt===i?et:Mt);}}else if(u.indexOf(Jr(F),et)!=et){var Yt=lt.lastIndexOf(F);Yt>-1&&(lt=lt.slice(0,Yt));}return lt+k},L.unescape=function(u){return (u=qe(u))&&or.test(u)?u.replace(Ke,Hf):u},L.uniqueId=function(u){var g=++qf;return qe(u)+g},L.upperCase=yn,L.upperFirst=Ru,L.each=Th,L.eachRight=Va,L.first=Vs,_(L,(zt={},Fi(L,(function(u,g){an.call(L.prototype,g)||(zt[g]=u);})),zt),{chain:false}),L.VERSION="4.17.21",Wt(["bind","bindKey","curry","curryRight","partial","partialRight"],(function(u){L[u].placeholder=L;})),Wt(["drop","take"],(function(u,g){Re.prototype[u]=function(S){S=S===i?1:Xn(we(S),0);var k=this.__filtered__&&!g?new Re(this):this.clone();return k.__filtered__?k.__takeCount__=Ar(S,k.__takeCount__):k.__views__.push({size:Ar(S,T),type:u+(k.__dir__<0?"Right":"")}),k},Re.prototype[u+"Right"]=function(S){return this.reverse()[u](S).reverse()};})),Wt(["filter","map","takeWhile"],(function(u,g){var S=g+1,k=S==1||S==3;Re.prototype[u]=function(F){var $=this.clone();return $.__iteratees__.push({iteratee:ue(F,3),type:S}),$.__filtered__=$.__filtered__||k,$};})),Wt(["head","last"],(function(u,g){var S="take"+(g?"Right":"");Re.prototype[u]=function(){return this[S](1).value()[0]};})),Wt(["initial","tail"],(function(u,g){var S="drop"+(g?"":"Right");Re.prototype[u]=function(){return this.__filtered__?new Re(this):this[S](1)};})),Re.prototype.compact=function(){return this.filter(b)},Re.prototype.find=function(u){return this.filter(u).head()},Re.prototype.findLast=function(u){return this.reverse().find(u)},Re.prototype.invokeMap=Ie((function(u,g){return typeof u=="function"?new Re(this):this.map((function(S){return As(S,u,g)}))})),Re.prototype.reject=function(u){return this.filter(aa(ue(u)))},Re.prototype.slice=function(u,g){u=we(u);var S=this;return S.__filtered__&&(u>0||g<0)?new Re(S):(u<0?S=S.takeRight(-u):u&&(S=S.drop(u)),g!==i&&(S=(g=we(g))<0?S.dropRight(-g):S.take(g-u)),S)},Re.prototype.takeRightWhile=function(u){return this.reverse().takeWhile(u).reverse()},Re.prototype.toArray=function(){return this.take(T)},Fi(Re.prototype,(function(u,g){var S=/^(?:filter|find|map|reject)|While$/.test(g),k=/^(?:head|last)$/.test(g),F=L[k?"take"+(g=="last"?"Right":""):g],$=k||/^find/.test(g);F&&(L.prototype[g]=function(){var q=this.__wrapped__,et=k?[1]:arguments,lt=q instanceof Re,Et=et[0],wt=lt||ge(q),Mt=function(ie){var Xt=F.apply(L,Ho([ie],et));return k&&Yt?Xt[0]:Xt};wt&&S&&typeof Et=="function"&&Et.length!=1&&(lt=wt=false);var Yt=this.__chain__,Qt=!!this.__actions__.length,oe=$&&!Yt,Ft=lt&&!Qt;if(!$&&wt){q=Ft?q:new Re(this);var Ut=u.apply(q,et);return Ut.__actions__.push({func:zs,args:[Mt],thisArg:i}),new Xr(Ut,Yt)}return oe&&Ft?u.apply(this,et):(Ut=this.thru(Mt),oe?k?Ut.value()[0]:Ut.value():Ut)});})),Wt(["pop","push","shift","sort","splice","unshift"],(function(u){var g=wl[u],S=/^(?:push|sort|unshift)$/.test(u)?"tap":"thru",k=/^(?:pop|shift)$/.test(u);L.prototype[u]=function(){var F=arguments;if(k&&!this.__chain__){var $=this.value();return g.apply(ge($)?$:[],F)}return this[S]((function(q){return g.apply(ge(q)?q:[],F)}))};})),Fi(Re.prototype,(function(u,g){var S=L[g];if(S){var k=S.name+"";an.call(Ri,k)||(Ri[k]=[]),Ri[k].push({name:g,func:S});}})),Ri[Hl(i,2).name]=[{name:"wrapper",func:i}],Re.prototype.clone=function(){var u=new Re(this.__wrapped__);return u.__actions__=mr(this.__actions__),u.__dir__=this.__dir__,u.__filtered__=this.__filtered__,u.__iteratees__=mr(this.__iteratees__),u.__takeCount__=this.__takeCount__,u.__views__=mr(this.__views__),u},Re.prototype.reverse=function(){if(this.__filtered__){var u=new Re(this);u.__dir__=-1,u.__filtered__=true;}else (u=this.clone()).__dir__*=-1;return u},Re.prototype.value=function(){var u=this.__wrapped__.value(),g=this.__dir__,S=ge(u),k=g<0,F=S?u.length:0,$=(function(Ge,le,ye){for(var Tr=-1,Bi=ye.length;++Tr<Bi;){var sa=ye[Tr],wr=sa.size;switch(sa.type){case "drop":Ge+=wr;break;case "dropRight":le-=wr;break;case "take":le=Ar(le,Ge+wr);break;case "takeRight":Ge=Xn(Ge,le-wr);}}return {start:Ge,end:le}})(0,F,this.__views__),q=$.start,et=$.end,lt=et-q,Et=k?et:q-1,wt=this.__iteratees__,Mt=wt.length,Yt=0,Qt=Ar(lt,this.__takeCount__);if(!S||!k&&F==lt&&Qt==lt)return ph(u,this.__actions__);var oe=[];t:for(;lt--&&Yt<Qt;){for(var Ft=-1,Ut=u[Et+=g];++Ft<Mt;){var ie=wt[Ft],Xt=ie.iteratee,he=ie.type,Pe=Xt(Ut);if(he==2)Ut=Pe;else if(!Pe){if(he==1)continue t;break t}}oe[Yt++]=Ut;}return oe},L.prototype.at=nb,L.prototype.chain=function(){return wu(this)},L.prototype.commit=function(){return new Xr(this.value(),this.__chain__)},L.prototype.next=function(){this.__values__===i&&(this.__values__=xp(this.value()));var u=this.__index__>=this.__values__.length;return {done:u,value:u?i:this.__values__[this.__index__++]}},L.prototype.plant=function(u){for(var g,S=this;S instanceof Fl;){var k=Io(S);k.__index__=0,k.__values__=i,g?F.__wrapped__=k:g=k;var F=k;S=S.__wrapped__;}return F.__wrapped__=u,g},L.prototype.reverse=function(){var u=this.__wrapped__;if(u instanceof Re){var g=u;return this.__actions__.length&&(g=new Re(this)),(g=g.reverse()).__actions__.push({func:zs,args:[Xl],thisArg:i}),new Xr(g,this.__chain__)}return this.thru(Xl)},L.prototype.toJSON=L.prototype.valueOf=L.prototype.value=function(){return ph(this.__wrapped__,this.__actions__)},L.prototype.first=L.prototype.head,ka&&(L.prototype[ka]=function(){return this}),L})();on._=Yc,(r=function(){return Yc}.call(e,n,e,t))===i||(t.exports=r);}.call(this);},5161:(t,e,n)=>{var r=n(9932),i=n(7206),o=n(9199),s=n(1469);t.exports=function(c,p){return (s(c)?r:o)(c,i(p,3))};},8306:(t,e,n)=>{var r=n(3369);function i(o,s){if(typeof o!="function"||s!=null&&typeof s!="function")throw new TypeError("Expected a function");var c=function(){var p=arguments,h=s?s.apply(this,p):p[0],v=c.cache;if(v.has(h))return v.get(h);var P=o.apply(this,p);return c.cache=v.set(h,P)||v,P};return c.cache=new(i.Cache||r),c}i.Cache=r,t.exports=i;},2492:(t,e,n)=>{var r=n(2980),i=n(1463)((function(o,s,c){r(o,s,c);}));t.exports=i;},7557:(t,e,n)=>{var r=n(9932),i=n(5990),o=n(7406),s=n(1811),c=n(8363),p=n(696),h=n(9021),v=n(6904),P=h((function(x,T){var I={};if(x==null)return I;var R=false;T=r(T,(function(O){return O=s(O,x),R||(R=O.length>1),O})),c(x,v(x),I),R&&(I=i(I,7,p));for(var A=T.length;A--;)o(I,T[A]);return I}));t.exports=P;},9601:(t,e,n)=>{var r=n(371),i=n(9152),o=n(5403),s=n(327);t.exports=function(c){return o(c)?r(s(c)):i(c)};},9704:(t,e,n)=>{var r=n(2908),i=n(7206),o=n(5076),s=n(1469),c=n(6612);t.exports=function(p,h,v){var P=s(p)?r:o;return v&&c(p,h,v)&&(h=void 0),P(p,i(h,3))};},479:t=>{t.exports=function(){return []};},5062:t=>{t.exports=function(){return false};},8601:(t,e,n)=>{var r=n(4841);t.exports=function(i){return i?(i=r(i))===1/0||i===-1/0?17976931348623157e292*(i<0?-1:1):i==i?i:0:i===0?i:0};},554:(t,e,n)=>{var r=n(8601);t.exports=function(i){var o=r(i),s=o%1;return o==o?s?o-s:o:0};},4841:(t,e,n)=>{var r=n(7561),i=n(3218),o=n(3448),s=/^[-+]0x[0-9a-f]+$/i,c=/^0b[01]+$/i,p=/^0o[0-7]+$/i,h=parseInt;t.exports=function(v){if(typeof v=="number")return v;if(o(v))return NaN;if(i(v)){var P=typeof v.valueOf=="function"?v.valueOf():v;v=i(P)?P+"":P;}if(typeof v!="string")return v===0?v:+v;v=r(v);var x=c.test(v);return x||p.test(v)?h(v.slice(2),x?2:8):s.test(v)?NaN:+v};},9881:(t,e,n)=>{var r=n(8363),i=n(1704);t.exports=function(o){return r(o,i(o))};},9833:(t,e,n)=>{var r=n(531);t.exports=function(i){return i==null?"":r(i)};},2628:(t,e,n)=>{var r=n(7415),i=n(3674);t.exports=function(o){return o==null?[]:r(o,i(o))};},2527:(t,e,n)=>{e.TypedEmitter=n(7187).EventEmitter;},5078:(t,e,n)=>{n.d(e,{fEx:()=>h.fEx,zVd:()=>h.zVd,zu7:()=>h.zu7,dpb:()=>h.dpb,T0E:()=>h.T0E,d4U:()=>h.d4U,nwm:()=>h.nwm,Ijf:()=>h.Ijf,v2N:()=>h.v2N,Mbo:()=>h.Mbo,E34:()=>h.E34,Bkk:()=>h.Bkk,Y92:()=>h.Y92,m06:()=>h.m06,bM9:()=>h.bM9,sZY:()=>v,PLi:()=>h.PLi,yTz:()=>h.yTz,FzK:()=>h.FzK,tvV:()=>h.tvV,ugv:()=>h.ugv,x3v:()=>h.x3v,jAf:()=>h.jAf,u4I:()=>h.u4I,bEP:()=>h.bEP,weZ:()=>h.weZ,uS8:()=>h.uS8,zdd:()=>h.zdd,i2A:()=>h.i2A,fc5:()=>h.fc5,K79:()=>h.K79,$i2:()=>h.$i2,$QI:()=>h.$QI,WJn:()=>h.WJn,Pzm:()=>h.Pzm,Q_D:()=>h.Q_D,lj3:()=>h.lj3,bSK:()=>h.bSK,Eq9:()=>h.Eq9,mKD:()=>h.mKD,_Yx:()=>h._Yx,uMJ:()=>h.uMJ,oiL:()=>h.oiL,Fa6:()=>h.Fa6,hk_:()=>h.hk_,vjn:()=>I,_d$:()=>h._d$,NSU:()=>h.NSU,Eph:()=>h.Eph,g31:()=>h.g31,u9g:()=>h.u9g,aqW:()=>h.aqW,LBz:()=>h.LBz,qYx:()=>h.qYx,X$1:()=>h.X$1,OoB:()=>h.OoB,pDu:()=>h.pDu,rpU:()=>h.rpU,fYe:()=>h.fYe,Pg9:()=>h.Pg9,GBW:()=>h.GBW,vQb:()=>h.vQb,yEZ:()=>h.yEZ,Wky:()=>h.Wky,C2e:()=>h.C2e,Lbh:()=>h.Lbh,RCf:()=>T,AVk:()=>h.AVk,cUI:()=>h.cUI,XHu:()=>h.XHu,cG4:()=>h.cG4,JrM:()=>h.JrM,bII:()=>h.bII,FT8:()=>h.FT8,Pr8:()=>h.Pr8,IZr:()=>h.IZr,$BG:()=>h.$BG,Qj0:()=>h.Qj0,jKp:()=>h.jKp,m5b:()=>h.m5b,wO5:()=>h.wO5,Zr9:()=>h.Zr9,g3t:()=>h.g3t,m72:()=>h.m72,i3Z:()=>h.i3Z,zOd:()=>h.zOd,o_I:()=>h.o_I,bWm:()=>h.bWm,o5f:()=>h.o5f,i4m:()=>h.i4m,sEr:()=>h.sEr,GAT:()=>h.GAT,iKc:()=>h.iKc,Tex:()=>h.Tex,XsQ:()=>h.XsQ,U9t:()=>h.U9t,OpC:()=>h.OpC,bgy:()=>h.bgy,jPD:()=>h.jPD,Q$1:()=>h.Q$1,Cmg:()=>h.Cmg,$Iz:()=>h.$Iz,tIq:()=>h.tIq,zHr:()=>h.zHr,ZeH:()=>h.ZeH,$Av:()=>h.$Av,TpL:()=>h.TpL,pWb:()=>h.pWb,roX:()=>h.roX,RXg:()=>h.RXg,_xu:()=>h._xu,RVX:()=>h.RVX,Fd7:()=>h.Fd7,N9K:()=>h.N9K,do1:()=>h.do1,hH:()=>h.hH,K0T:()=>h.K0T,p7R:()=>h.p7R,E7k:()=>h.E7k,Mal:()=>h.Mal,KeG:()=>h.KeG,uMn:()=>h.uMn,qBr:()=>h.qBr,DFP:()=>h.DFP,m76:()=>h.m76,$jJ:()=>h.$jJ,B8X:()=>h.B8X,N5j:()=>h.N5j,Us3:()=>h.Us3,isD:()=>h.isD,nN6:()=>h.nN6,ini:()=>o,VsH:()=>x,Kyg:()=>h.Kyg,XY6:()=>h.XY6,puT:()=>h.puT,bGN:()=>h.bGN,$Bh:()=>h.$Bh,hVT:()=>h.hVT,k8_:()=>h.k8_,wn5:()=>h.wn5,lgL:()=>h.lgL,VeJ:()=>h.VeJ,pSI:()=>h.pSI,ctk:()=>P,gpE:()=>h.gpE,PVi:()=>h.PVi,opi:()=>Ru,AQp:()=>h.AQp,Bve:()=>h.Bve,zBW:()=>h.zBW,LpH:()=>h.LpH,q5V:()=>h.q5V,BoX:()=>h.BoX,zv6:()=>h.zv6,RzF:()=>h.RzF,iI3:()=>h.iI3,jCI:()=>h.jCI,OeJ:()=>h.OeJ,ab2:()=>h.ab2,TVs:()=>h.TVs,JU:()=>h.JU,QdX:()=>h.QdX,Kf7:()=>h.Kf7,LtK:()=>h.LtK,r6R:()=>h.r6R,fvX:()=>h.fvX,r4r:()=>h.r4r,FcI:()=>h.FcI,qw4:()=>h.qw4,Cc7:()=>h.Cc7,kd9:()=>h.kd9,bOA:()=>h.bOA,qXR:()=>h.qXR,yGq:()=>h.yGq,ZD9:()=>h.ZD9,wEB:()=>h.wEB,YGW:()=>h.YGW,Chb:()=>h.Chb,_HY:()=>h._HY,cMT:()=>h.cMT,p_C:()=>h.p_C,Ehw:()=>h.Ehw,JkE:()=>h.JkE,ku9:()=>h.ku9,$Vq:()=>h.$Vq,QZw:()=>h.QZw,q6C:()=>h.q6C,YlF:()=>h.YlF,rDA:()=>h.rDA,CjA:()=>h.CjA,u0j:()=>h.u0j,Zam:()=>h.Zam,JDz:()=>h.JDz,ZSL:()=>h.ZSL,dO5:()=>h.dO5,K5h:()=>h.K5h,UK7:()=>h.UK7,JyR:()=>h.JyR,GHz:()=>h.GHz,_He:()=>h._He,nM6:()=>h.nM6,zWW:()=>h.zWW,xrg:()=>h.xrg,bj8:()=>h.bj8,bGH:()=>h.bGH,cTO:()=>h.cTO,SrV:()=>h.SrV,Xm9:()=>h.Xm9,PO0:()=>h.PO0,Yo2:()=>h.Yo2,ueJ:()=>h.ueJ,w1y:()=>h.w1y,c06:()=>h.c06,lS0:()=>h.lS0,abb:()=>h.abb,ird:()=>h.ird,_oj:()=>h._oj,e1Q:()=>h.e1Q,Ugm:()=>h.Ugm,hvo:()=>h.hvo,tV1:()=>h.tV1,FL0:()=>h.FL0,Dxn:()=>h.Dxn,G6j:()=>h.G6j,eSW:()=>h.eSW,DWP:()=>h.DWP,zjf:()=>h.zjf,Eam:()=>h.Eam,URA:()=>h.URA,yBL:()=>h.yBL,SQC:()=>h.SQC,_q5:()=>h._q5,o88:()=>h.o88,cUf:()=>h.cUf,YVG:()=>h.YVG,J5K:()=>h.J5K,nOi:()=>h.nOi,yhH:()=>h.yhH,HsO:()=>h.HsO,XqI:()=>h.XqI,wRo:()=>h.wRo,hYU:()=>h.hYU,UAI:()=>h.UAI,PNd:()=>h.PNd,N9N:()=>h.N9N,$02:()=>h.$02,Dc_:()=>h.Dc_,bk4:()=>h.bk4,p13:()=>h.p13,mGS:()=>h.mGS,_gQ:()=>h._gQ,Dfv:()=>h.Dfv,bd6:()=>h.bd6,eKV:()=>h.eKV,EQD:()=>h.EQD,QNm:()=>h.QNm,yaX:()=>h.yaX,X3h:()=>h.X3h,Buv:()=>h.Buv,_yy:()=>h._yy,l3m:()=>h.l3m,FoD:()=>h.FoD,O0T:()=>h.O0T,yyj:()=>h.yyj,rCU:()=>h.rCU,l9N:()=>h.l9N,EOH:()=>h.EOH,LkV:()=>h.LkV,X$v:()=>h.X$v,ZPm:()=>Wh,mKo:()=>h.mKo});var r={};n.r(r),n.d(r,{FunctionToString:()=>Na,InboundFilters:()=>eo});var i={};n.r(i),n.d(i,{Breadcrumbs:()=>aa,Dedupe:()=>ge,GlobalHandlers:()=>oa,HttpContext:()=>mi,LinkedErrors:()=>Rr,TryCatch:()=>Hs});var o,s=n(4721),c=n.n(s);(function(f){f.ALL="ALL",f.NONE="NONE",f.LOG="LOG",f.ERROR="ERROR";})(o||(o={}));var p=(function(){function f(a,l){this.logger=a,this.logLevel=l;}return f.prototype.error=function(a,l){this.logLevel!==o.NONE&&this.logger.error("[Stigg] ".concat(a),l||{});},f.prototype.log=function(a,l){c()([o.ERROR,o.NONE],this.logLevel)||this.logger.log("[Stigg] ".concat(a),l||{});},f.prototype.debug=function(a,l){c()([o.LOG,o.ALL],this.logLevel)&&this.logger.debug("[Stigg] ".concat(a),l||{});},f})(),h=n(890),v={isFallback:true,hasAccess:false,accessDeniedReason:h.fEx.Unknown},P={isFallback:true,hasAccess:false,isUnlimited:false,accessDeniedReason:h.fEx.Unknown},x={isFallback:true,hasAccess:false,isUnlimited:false,currentUsage:0,requestedUsage:1,accessDeniedReason:h.fEx.Unknown},T={isFallback:true,hasAccess:false,enumValues:[],accessDeniedReason:h.fEx.Unknown},I=(function(){function f(a){Object.assign(this,a);}return f.prototype.getActiveSubscriptions=function(){return this.subscriptions.filter((function(a){return a.status===h.yhH.Active}))},f.prototype.getActiveTrials=function(){return this.subscriptions.filter((function(a){return a.status===h.yhH.InTrial}))},f.prototype.getActivePromotionalEntitlements=function(){return this.promotionalEntitlements.filter((function(a){return a.status===h.$Vq.Active}))},f})(),R=n(6486);let A=(function(){function f(a,l){this.client=a,this.edgeApiClient=l;}return f.prototype.getSdkConfiguration=function(){return this.edgeApiClient?this.edgeApiClient.getSdkConfiguration():this.client.query({query:h.N9K})},f})();var O=function(){return O=Object.assign||function(f){for(var a,l=1,d=arguments.length;l<d;l++)for(var m in a=arguments[l])Object.prototype.hasOwnProperty.call(a,m)&&(f[m]=a[m]);return f},O.apply(this,arguments)},N=(function(){function f(a,l){this.client=a,this.edgeApiClient=l;}return f.prototype.getPaywall=function(a){var l=a.productId,d=a.customerId,m=a.resourceId,y=a.context,b=a.billingCountryCode,E=a.includeHiddenPlans;return !d&&this.edgeApiClient?this.edgeApiClient.getPaywall(l,b,E):this.client.query({query:h.RVX,fetchPolicy:"no-cache",variables:{input:O(O(O(O(O(O({},l?{productId:l}:{}),d?{customerId:d}:{}),m?{resourceId:m}:{}),y?{context:y}:{}),b?{billingCountryCode:b}:{}),E?{includeHiddenPlans:E}:{})}})},f})();let V=N;var G=function(f,a,l,d){return new(l||(l=Promise))((function(m,y){function b(D){try{w(d.next(D));}catch(_){y(_);}}function E(D){try{w(d.throw(D));}catch(_){y(_);}}function w(D){var _;D.done?m(D.value):(_=D.value,_ instanceof l?_:new l((function(M){M(_);}))).then(b,E);}w((d=d.apply(f,[])).next());}))},X=function(f,a){var l,d,m,y,b={label:0,sent:function(){if(1&m[0])throw m[1];return m[1]},trys:[],ops:[]};return y={next:E(0),throw:E(1),return:E(2)},typeof Symbol=="function"&&(y[Symbol.iterator]=function(){return this}),y;function E(w){return function(D){return (function(_){if(l)throw new TypeError("Generator is already executing.");for(;b;)try{if(l=1,d&&(m=2&_[0]?d.return:_[0]?d.throw||((m=d.return)&&m.call(d),0):d.next)&&!(m=m.call(d,_[1])).done)return m;switch(d=0,m&&(_=[2&_[0],m.value]),_[0]){case 0:case 1:m=_;break;case 4:return b.label++,{value:_[1],done:!1};case 5:b.label++,d=_[1],_=[0];continue;case 7:_=b.ops.pop(),b.trys.pop();continue;default:if(!((m=(m=b.trys).length>0&&m[m.length-1])||_[0]!==6&&_[0]!==2)){b=0;continue}if(_[0]===3&&(!m||_[1]>m[0]&&_[1]<m[3])){b.label=_[1];break}if(_[0]===6&&b.label<m[1]){b.label=m[1],m=_;break}if(m&&b.label<m[2]){b.label=m[2],b.ops.push(_);break}m[2]&&b.ops.pop(),b.trys.pop();continue}_=a.call(f,b);}catch(M){_=[6,M],d=0;}finally{l=m=0;}if(5&_[0])throw _[1];return {value:_[0]?_[1]:void 0,done:true}})([w,D])}}},nt=(function(){function f(a,l){this.client=a,this.edgeApiClient=l;}return f.prototype.getCustomer=function(a){return this.client.query({query:h.ZeH,variables:{input:{customerId:a}},fetchPolicy:"no-cache"})},f.prototype.getActiveSubscriptions=function(a,l){return G(this,void 0,void 0,(function(){return X(this,(function(d){return [2,this.client.query({query:h.OpC,variables:{input:(0, R.isArray)(l)?{customerId:a,resourceIds:l}:{customerId:a,resourceId:l}},fetchPolicy:"no-cache"})]}))}))},f.prototype.getActiveSubscriptionsList=function(a,l){return G(this,void 0,void 0,(function(){return X(this,(function(d){return this.edgeApiClient?[2,this.edgeApiClient.getActiveSubscriptionsList(a,l)]:[2,this.client.query({query:h.bgy,variables:{input:(0, R.isArray)(l)?{customerId:a,resourceIds:l}:{customerId:a,resourceId:l}},fetchPolicy:"no-cache"})]}))}))},f.prototype.getSubscription=function(a){return G(this,void 0,void 0,(function(){return X(this,(function(l){return [2,this.client.query({query:h.do1,variables:{input:{subscriptionId:a}},fetchPolicy:"no-cache"})]}))}))},f.prototype.getCustomerPortal=function(a,l,d){return this.client.query({query:h.$Av,variables:{input:{customerId:a,resourceId:l,productId:d}},fetchPolicy:"no-cache"})},f.prototype.fetchUsageHistory=function(a){var l=a.customerId,d=a.resourceId,m=a.endDate,y=a.startDate,b=a.featureId;return G(this,void 0,void 0,(function(){return X(this,(function(E){return [2,this.client.query({query:h.K0T,variables:{usageHistoryInput:{customerRefId:l,featureRefId:b,resourceRefId:d,startDate:y,endDate:m||new Date}},fetchPolicy:"no-cache"})]}))}))},f})();let st=nt,U=(function(){function f(a){this.client=a;}return f.prototype.getCoupons=function(){return this.client.query({query:h.Q$1,fetchPolicy:"no-cache"})},f})();var j=function(){return j=Object.assign||function(f){for(var a,l=1,d=arguments.length;l<d;l++)for(var m in a=arguments[l])Object.prototype.hasOwnProperty.call(a,m)&&(f[m]=a[m]);return f},j.apply(this,arguments)},ut=(function(){function f(a){this.client=a;}return f.prototype.applySubscription=function(a){var l=a.customerId,d=a.payingCustomerId,m=a.planId,y=a.paymentMethodId,b=a.addons,E=a.billableFeatures,w=a.billingInformation,D=a.billingCountryCode,_=a.billingId,M=a.billingPeriod,B=a.metadata,H=a.promotionCode,K=a.resourceId,J=a.skipTrial,tt=a.startDate,yt=a.unitQuantity,Rt=a.scheduleStrategy;return this.client.mutate({mutation:h.Bkk,variables:{input:{customerId:l,payingCustomerId:d,planId:m,paymentMethodId:y,startDate:tt,addons:b,billingId:_,billingPeriod:M,unitQuantity:yt,billableFeatures:E,additionalMetaData:B,resourceId:K,skipTrial:J,promotionCode:H,billingInformation:this.mapBillingInformation(w),billingCountryCode:D,scheduleStrategy:Rt}}})},f.prototype.getSubscriptions=function(a,l,d,m,y){return y===void 0&&(y={limit:10}),b=this,E=void 0,D=function(){return (function(_,M){var B,H,K,J,tt={label:0,sent:function(){if(1&K[0])throw K[1];return K[1]},trys:[],ops:[]};return J={next:yt(0),throw:yt(1),return:yt(2)},typeof Symbol=="function"&&(J[Symbol.iterator]=function(){return this}),J;function yt(Rt){return function(Zt){return (function(zt){if(B)throw new TypeError("Generator is already executing.");for(;tt;)try{if(B=1,H&&(K=2&zt[0]?H.return:zt[0]?H.throw||((K=H.return)&&K.call(H),0):H.next)&&!(K=K.call(H,zt[1])).done)return K;switch(H=0,K&&(zt=[2&zt[0],K.value]),zt[0]){case 0:case 1:K=zt;break;case 4:return tt.label++,{value:zt[1],done:!1};case 5:tt.label++,H=zt[1],zt=[0];continue;case 7:zt=tt.ops.pop(),tt.trys.pop();continue;default:if(!((K=(K=tt.trys).length>0&&K[K.length-1])||zt[0]!==6&&zt[0]!==2)){tt=0;continue}if(zt[0]===3&&(!K||zt[1]>K[0]&&zt[1]<K[3])){tt.label=zt[1];break}if(zt[0]===6&&tt.label<K[1]){tt.label=K[1],K=zt;break}if(K&&tt.label<K[2]){tt.label=K[2],tt.ops.push(zt);break}K[2]&&tt.ops.pop(),tt.trys.pop();continue}zt=M.call(_,tt);}catch(Bt){zt=[6,Bt],H=0;}finally{B=K=0;}if(5&zt[0])throw zt[1];return {value:zt[0]?zt[1]:void 0,done:true}})([Rt,Zt])}}})(this,(function(_){return [2,this.client.query({query:h.hH,variables:j({filter:j(j(j(j({},a?{customerId:{eq:a}}:{}),l?{resourceId:(0, R.isArray)(l)?{in:l}:{eq:l}}:{}),d?{status:(0, R.isArray)(d)?{in:d}:{eq:d}}:{}),m?{productId:(0, R.isArray)(m)?{in:m}:{eq:m}}:{})},y?{paging:j({},y.startingAfter?{first:y.limit,after:y.startingAfter}:y.endingBefore?{last:y.limit,before:y.endingBefore}:{first:y.limit})}:{}),fetchPolicy:"no-cache"})]}))},new((w=void 0)||(w=Promise))((function(_,M){function B(J){try{K(D.next(J));}catch(tt){M(tt);}}function H(J){try{K(D.throw(J));}catch(tt){M(tt);}}function K(J){var tt;J.done?_(J.value):(tt=J.value,tt instanceof w?tt:new w((function(yt){yt(tt);}))).then(B,H);}K((D=D.apply(b,E||[])).next());}));var b,E,w,D;},f.prototype.checkoutState=function(a){var l=a.customerId,d=a.resourceId,m=a.planId,y=a.billingCountryCode;return this.client.query({query:h.jPD,fetchPolicy:"no-cache",variables:{input:j(j({planId:m,customerId:l},d?{resourceId:d}:{}),y?{billingCountryCode:y}:{})}})},f.prototype.mapBillingInformation=function(a){if(a)return {taxRateIds:a==null?void 0:a.taxRateIds,billingAddress:a==null?void 0:a.billingAddress,integrationId:a==null?void 0:a.integrationId,prorationBehavior:a==null?void 0:a.prorationBehavior}},f})();let Y=ut;var at=function(f,a,l,d){return new(l||(l=Promise))((function(m,y){function b(D){try{w(d.next(D));}catch(_){y(_);}}function E(D){try{w(d.throw(D));}catch(_){y(_);}}function w(D){var _;D.done?m(D.value):(_=D.value,_ instanceof l?_:new l((function(M){M(_);}))).then(b,E);}w((d=d.apply(f,[])).next());}))},pt=function(f,a){var l,d,m,y,b={label:0,sent:function(){if(1&m[0])throw m[1];return m[1]},trys:[],ops:[]};return y={next:E(0),throw:E(1),return:E(2)},typeof Symbol=="function"&&(y[Symbol.iterator]=function(){return this}),y;function E(w){return function(D){return (function(_){if(l)throw new TypeError("Generator is already executing.");for(;b;)try{if(l=1,d&&(m=2&_[0]?d.return:_[0]?d.throw||((m=d.return)&&m.call(d),0):d.next)&&!(m=m.call(d,_[1])).done)return m;switch(d=0,m&&(_=[2&_[0],m.value]),_[0]){case 0:case 1:m=_;break;case 4:return b.label++,{value:_[1],done:!1};case 5:b.label++,d=_[1],_=[0];continue;case 7:_=b.ops.pop(),b.trys.pop();continue;default:if(!((m=(m=b.trys).length>0&&m[m.length-1])||_[0]!==6&&_[0]!==2)){b=0;continue}if(_[0]===3&&(!m||_[1]>m[0]&&_[1]<m[3])){b.label=_[1];break}if(_[0]===6&&b.label<m[1]){b.label=m[1],m=_;break}if(m&&b.label<m[2]){b.label=m[2],b.ops.push(_);break}m[2]&&b.ops.pop(),b.trys.pop();continue}_=a.call(f,b);}catch(M){_=[6,M],d=0;}finally{l=m=0;}if(5&_[0])throw _[1];return {value:_[0]?_[1]:void 0,done:true}})([w,D])}}},dt=(function(){function f(a){this.client=a;}return f.prototype.estimateSubscription=function(a){var l,d;return at(this,void 0,void 0,(function(){return pt(this,(function(m){return [2,this.client.mutate({mutation:h.m5b,variables:{input:{resourceId:a.resourceId,planId:a.planId,customerId:a.customerId,payingCustomerId:a.payingCustomerId,startDate:a.startDate,addons:a.addons,billingPeriod:a.billingPeriod,priceUnitAmount:a.unitQuantity,billableFeatures:a.billableFeatures,billingInformation:{taxRateIds:(l=a==null?void 0:a.billingInformation)===null||l===void 0?void 0:l.taxRateIds,taxPercentage:(d=a==null?void 0:a.billingInformation)===null||d===void 0?void 0:d.taxPercentage},promotionCode:a.promotionCode,billingCountryCode:a.billingCountryCode,skipTrial:a.skipTrial}}})]}))}))},f.prototype.estimateSubscriptionUpdate=function(a){return at(this,void 0,void 0,(function(){return pt(this,(function(l){return [2,this.client.mutate({mutation:h.wO5,variables:{input:{subscriptionId:a.subscriptionId,unitQuantity:a.unitQuantity,billableFeatures:a.billableFeatures,addons:a.addons,promotionCode:a.promotionCode}}})]}))}))},f.prototype.previewNextInvoice=function(a){return at(this,void 0,void 0,(function(){return pt(this,(function(l){return [2,this.client.mutate({mutation:h.yGq,fetchPolicy:"no-cache",variables:{input:{subscriptionId:a.subscriptionId}}})]}))}))},f.prototype.previewSubscription=function(a){var l,d,m;return at(this,void 0,void 0,(function(){return pt(this,(function(y){return [2,this.client.mutate({mutation:h.ZD9,fetchPolicy:"no-cache",variables:{input:{planId:a.planId,customerId:a.customerId,payingCustomerId:a.payingCustomerId,resourceId:a.resourceId,startDate:a.startDate,addons:a.addons,billingPeriod:a.billingPeriod,billableFeatures:a.billableFeatures,promotionCode:a.promotionCode,scheduleStrategy:a.scheduleStrategy,billingCountryCode:a.billingCountryCode,billingInformation:{taxRateIds:(l=a==null?void 0:a.billingInformation)===null||l===void 0?void 0:l.taxRateIds,taxPercentage:(d=a==null?void 0:a.billingInformation)===null||d===void 0?void 0:d.taxPercentage,billingAddress:(m=a==null?void 0:a.billingInformation)===null||m===void 0?void 0:m.billingAddress}}}})]}))}))},f})();let mt=dt;var Ct=function(){return Ct=Object.assign||function(f){for(var a,l=1,d=arguments.length;l<d;l++)for(var m in a=arguments[l])Object.prototype.hasOwnProperty.call(a,m)&&(f[m]=a[m]);return f},Ct.apply(this,arguments)},jt=(function(){function f(a){this.client=a;}return f.prototype.getMockPaywall=function(a){var l=a.productId,d=a.customerId,m=a.context;return this.client.query({query:h._xu,fetchPolicy:"no-cache",variables:{input:Ct(Ct(Ct({},l?{productId:l}:{}),d?{customerId:d}:{}),m?{context:m}:{})}})},f})();let Gt=jt;var Jt=(function(){function f(a){this.client=a;}return f.prototype.getUsageHistoryV2=function(a){return l=this,d=void 0,y=function(){return (function(b,E){var w,D,_,M,B={label:0,sent:function(){if(1&_[0])throw _[1];return _[1]},trys:[],ops:[]};return M={next:H(0),throw:H(1),return:H(2)},typeof Symbol=="function"&&(M[Symbol.iterator]=function(){return this}),M;function H(K){return function(J){return (function(tt){if(w)throw new TypeError("Generator is already executing.");for(;B;)try{if(w=1,D&&(_=2&tt[0]?D.return:tt[0]?D.throw||((_=D.return)&&_.call(D),0):D.next)&&!(_=_.call(D,tt[1])).done)return _;switch(D=0,_&&(tt=[2&tt[0],_.value]),tt[0]){case 0:case 1:_=tt;break;case 4:return B.label++,{value:tt[1],done:!1};case 5:B.label++,D=tt[1],tt=[0];continue;case 7:tt=B.ops.pop(),B.trys.pop();continue;default:if(!((_=(_=B.trys).length>0&&_[_.length-1])||tt[0]!==6&&tt[0]!==2)){B=0;continue}if(tt[0]===3&&(!_||tt[1]>_[0]&&tt[1]<_[3])){B.label=tt[1];break}if(tt[0]===6&&B.label<_[1]){B.label=_[1],_=tt;break}if(_&&B.label<_[2]){B.label=_[2],B.ops.push(tt);break}_[2]&&B.ops.pop(),B.trys.pop();continue}tt=E.call(b,B);}catch(yt){tt=[6,yt],D=0;}finally{w=_=0;}if(5&tt[0])throw tt[1];return {value:tt[0]?tt[1]:void 0,done:true}})([K,J])}}})(this,(function(b){return [2,this.client.query({query:h.p7R,variables:{input:a},fetchPolicy:"no-cache"})]}))},new((m=void 0)||(m=Promise))((function(b,E){function w(M){try{_(y.next(M));}catch(B){E(B);}}function D(M){try{_(y.throw(M));}catch(B){E(B);}}function _(M){var B;M.done?b(M.value):(B=M.value,B instanceof m?B:new m((function(H){H(B);}))).then(w,D);}_((y=y.apply(l,d||[])).next());}));var l,d,m,y;},f})(),ee=function(f,a,l,d){return new(l||(l=Promise))((function(m,y){function b(D){try{w(d.next(D));}catch(_){y(_);}}function E(D){try{w(d.throw(D));}catch(_){y(_);}}function w(D){var _;D.done?m(D.value):(_=D.value,_ instanceof l?_:new l((function(M){M(_);}))).then(b,E);}w((d=d.apply(f,[])).next());}))},re=function(f,a){var l,d,m,y,b={label:0,sent:function(){if(1&m[0])throw m[1];return m[1]},trys:[],ops:[]};return y={next:E(0),throw:E(1),return:E(2)},typeof Symbol=="function"&&(y[Symbol.iterator]=function(){return this}),y;function E(w){return function(D){return (function(_){if(l)throw new TypeError("Generator is already executing.");for(;b;)try{if(l=1,d&&(m=2&_[0]?d.return:_[0]?d.throw||((m=d.return)&&m.call(d),0):d.next)&&!(m=m.call(d,_[1])).done)return m;switch(d=0,m&&(_=[2&_[0],m.value]),_[0]){case 0:case 1:m=_;break;case 4:return b.label++,{value:_[1],done:!1};case 5:b.label++,d=_[1],_=[0];continue;case 7:_=b.ops.pop(),b.trys.pop();continue;default:if(!((m=(m=b.trys).length>0&&m[m.length-1])||_[0]!==6&&_[0]!==2)){b=0;continue}if(_[0]===3&&(!m||_[1]>m[0]&&_[1]<m[3])){b.label=_[1];break}if(_[0]===6&&b.label<m[1]){b.label=m[1],m=_;break}if(m&&b.label<m[2]){b.label=m[2],b.ops.push(_);break}m[2]&&b.ops.pop(),b.trys.pop();continue}_=a.call(f,b);}catch(M){_=[6,M],d=0;}finally{l=m=0;}if(5&_[0])throw _[1];return {value:_[0]?_[1]:void 0,done:true}})([w,D])}}};let Ee=(function(){function f(a){this.client=a;}return f.prototype.getCreditBalance=function(a){return ee(this,void 0,void 0,(function(){return re(this,(function(l){return [2,this.client.query({query:h.Cmg,variables:{input:a},fetchPolicy:"no-cache"})]}))}))},f.prototype.getCreditGrants=function(a){return ee(this,void 0,void 0,(function(){return re(this,(function(l){return [2,this.client.query({query:h.$Iz,variables:{input:a},fetchPolicy:"no-cache"})]}))}))},f.prototype.getCreditLedger=function(a){return ee(this,void 0,void 0,(function(){return re(this,(function(l){return [2,this.client.query({query:h.tIq,variables:{input:a},fetchPolicy:"no-cache"})]}))}))},f.prototype.getCreditUsage=function(a){return ee(this,void 0,void 0,(function(){return re(this,(function(l){return [2,this.client.query({query:h.zHr,variables:{input:a},fetchPolicy:"no-cache"})]}))}))},f})(),je=(function(){function f(a){this.client=a;}return f.prototype.createPaymentSession=function(a){return this.client.mutate({mutation:h.$QI,variables:{input:a}})},f})(),sn=function(f,a){this.sdkConfiguration=new A(f,a),this.paywall=new V(f,a),this.subscriptions=new Y(f),this.mockPaywall=new Gt(f),this.customers=new st(f,a),this.coupons=new U(f),this.subscriptionEstimations=new mt(f),this.usageHistoryApi=new Jt(f),this.credits=new Ee(f),this.checkout=new je(f);};var Ze=n(1609),Pn=n.n(Ze),Gn=n(2492),ln=n.n(Gn),Ke=h.PO0.JsClientSdk,dn="js-client-sdk",or=["localhost","127.0.0.1","::1"];function _e(f){var a=new URL(f);return or.includes(a.hostname)?a.port="3060":a.hostname="edge.".concat(a.hostname),a.toString().slice(0,-1)}function De(f){var a=f.customerId;if(!a||Pn()(a))throw new Error("You must set customer ID first, use setCustomerId function or pass it via the constructor");return a}var vr=function(f,a){return vr=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(l,d){l.__proto__=d;}||function(l,d){for(var m in d)Object.prototype.hasOwnProperty.call(d,m)&&(l[m]=d[m]);},vr(f,a)};function Ve(f,a){if(typeof a!="function"&&a!==null)throw new TypeError("Class extends value "+String(a)+" is not a constructor or null");function l(){this.constructor=f;}vr(f,a),f.prototype=a===null?Object.create(a):(l.prototype=a.prototype,new l);}var bt=function(){return bt=Object.assign||function(f){for(var a,l=1,d=arguments.length;l<d;l++)for(var m in a=arguments[l])Object.prototype.hasOwnProperty.call(a,m)&&(f[m]=a[m]);return f},bt.apply(this,arguments)};function ar(f,a){var l={};for(var d in f)Object.prototype.hasOwnProperty.call(f,d)&&a.indexOf(d)<0&&(l[d]=f[d]);if(f!=null&&typeof Object.getOwnPropertySymbols=="function"){var m=0;for(d=Object.getOwnPropertySymbols(f);m<d.length;m++)a.indexOf(d[m])<0&&Object.prototype.propertyIsEnumerable.call(f,d[m])&&(l[d[m]]=f[d[m]]);}return l}function sr(f,a,l,d){return new(l||(l=Promise))((function(m,y){function b(D){try{w(d.next(D));}catch(_){y(_);}}function E(D){try{w(d.throw(D));}catch(_){y(_);}}function w(D){var _;D.done?m(D.value):(_=D.value,_ instanceof l?_:new l((function(M){M(_);}))).then(b,E);}w((d=d.apply(f,[])).next());}))}function Jn(f,a){var l,d,m,y,b={label:0,sent:function(){if(1&m[0])throw m[1];return m[1]},trys:[],ops:[]};return y={next:E(0),throw:E(1),return:E(2)},typeof Symbol=="function"&&(y[Symbol.iterator]=function(){return this}),y;function E(w){return function(D){return (function(_){if(l)throw new TypeError("Generator is already executing.");for(;b;)try{if(l=1,d&&(m=2&_[0]?d.return:_[0]?d.throw||((m=d.return)&&m.call(d),0):d.next)&&!(m=m.call(d,_[1])).done)return m;switch(d=0,m&&(_=[2&_[0],m.value]),_[0]){case 0:case 1:m=_;break;case 4:return b.label++,{value:_[1],done:!1};case 5:b.label++,d=_[1],_=[0];continue;case 7:_=b.ops.pop(),b.trys.pop();continue;default:if(!((m=(m=b.trys).length>0&&m[m.length-1])||_[0]!==6&&_[0]!==2)){b=0;continue}if(_[0]===3&&(!m||_[1]>m[0]&&_[1]<m[3])){b.label=_[1];break}if(_[0]===6&&b.label<m[1]){b.label=m[1],m=_;break}if(m&&b.label<m[2]){b.label=m[2],b.ops.push(_);break}m[2]&&b.ops.pop(),b.trys.pop();continue}_=a.call(f,b);}catch(M){_=[6,M],d=0;}finally{l=m=0;}if(5&_[0])throw _[1];return {value:_[0]?_[1]:void 0,done:true}})([w,D])}}}function lr(f,a,l){if(l||arguments.length===2)for(var d,m=0,y=a.length;m<y;m++)!d&&m in a||(d||(d=Array.prototype.slice.call(a,0,m)),d[m]=a[m]);return f.concat(d||Array.prototype.slice.call(a))}var wi=function(f,a){return wi=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(l,d){l.__proto__=d;}||function(l,d){for(var m in d)Object.prototype.hasOwnProperty.call(d,m)&&(l[m]=d[m]);},wi(f,a)},vo="Invariant Violation",jr=Object.setPrototypeOf,Co=jr===void 0?function(f,a){return f.__proto__=a,f}:jr,Ce=(function(f){function a(l){l===void 0&&(l=vo);var d=f.call(this,typeof l=="number"?vo+": "+l+" (see https://github.com/apollographql/invariant-packages)":l)||this;return d.framesToPop=1,d.name=vo,Co(d,a.prototype),d}return (function(l,d){if(typeof d!="function"&&d!==null)throw new TypeError("Class extends value "+String(d)+" is not a constructor or null");function m(){this.constructor=l;}wi(l,d),l.prototype=d===null?Object.create(d):(m.prototype=d.prototype,new m);})(a,f),a})(Error);function Vt(f,a){if(!f)throw new Ce(a)}var gt=["debug","log","warn","error","silent"],ot=gt.indexOf("log");function Z(f){return function(){if(gt.indexOf(f)>=ot){var a=console[f]||console.log;return a.apply(console,arguments)}}}function it(f){try{return f()}catch(a){}}(function(f){f.debug=Z("debug"),f.log=Z("log"),f.warn=Z("warn"),f.error=Z("error");})(Vt||(Vt={}));let _t=it((function(){return globalThis}))||it((function(){return window}))||it((function(){return self}))||it((function(){return n.g}))||it((function(){return Function("return this")()}));var ft="__",Lt=[ft,ft].join("DEV");let It=(function(){try{return !!__DEV__}catch(f){return Object.defineProperty(_t,Lt,{value:it((function(){return "production"}))!=="production",enumerable:false,configurable:true,writable:true}),_t[Lt]}})();function Nt(f){try{return f()}catch(a){}}var se=Nt((function(){return globalThis}))||Nt((function(){return window}))||Nt((function(){return self}))||Nt((function(){return n.g}))||Nt((function(){return Function("return this")()})),ne=false;function kn(f){return Array.isArray(f)&&f.length>0}!se||Nt((function(){return "production"}))||Nt((function(){return process}))||(Object.defineProperty(se,"process",{value:{env:{NODE_ENV:"production"}},configurable:true,enumerable:false,writable:true}),ne=true),n(143).H,ne&&(delete se.process,ne=false),__DEV__?Vt(typeof It=="boolean",It):Vt(typeof It=="boolean",38);var Ae=(function(f){function a(l){var d,m,y=l.graphQLErrors,b=l.clientErrors,E=l.networkError,w=l.errorMessage,D=l.extraInfo,_=f.call(this,w)||this;return _.graphQLErrors=y||[],_.clientErrors=b||[],_.networkError=E||null,_.message=w||(m="",(kn((d=_).graphQLErrors)||kn(d.clientErrors))&&(d.graphQLErrors||[]).concat(d.clientErrors||[]).forEach((function(M){var B=M?M.message:"Error message not found.";m+=B+`
2323
2323
  `;})),d.networkError&&(m+=d.networkError.message+`
2324
- `),m=m.replace(/\n$/,"")),_.extraInfo=D,_.__proto__=a.prototype,_}return Ve(a,f),a})(Error),cn=(n(1905),n(4139)),pn=fetch,Ir=n.n(cn)()(fetch,{retryOn:function(f,a,l){return !(f>5)&&(a!==null||!(l!=null&&l.status)||l.status>=500)},retryDelay:function(f){return 1e3*Math.pow(2,f)}}),cr=(function(){function f(a,l){this.config=a,this.dynamicData=l;}return f.create=function(a,l){return a.enableEdge?new f(a,l):null},f.prototype.getPaywall=function(a,l,d){var m=a?"/p/".concat(a):"",y=l?"billingCountryCode=".concat(l):"",b=d?"&includeHiddenPlans=".concat(d):"";return this.get("/v1".concat(m,"/paywall.json?").concat(y).concat(b))},f.prototype.getEntitlements=function(a,l){var d=l?"?resourceId=".concat(l):"";return this.get("/v1/c/".concat(a,"/entitlements.json").concat(d))},f.prototype.getActiveSubscriptionsList=function(a,l){var d=new URLSearchParams;(0, F.isString)(l)?d.set("resourceId",l):(0, F.isArray)(l)&&l.forEach((function(y){return d.append("resourceIds",y)}));var m="/v1/c/".concat(a,"/subscriptions.json?").concat(d.toString());return this.get(m)},f.prototype.getSdkConfiguration=function(){return this.get("/v1/config/client-sdk-configuration.json")},f.prototype.get=function(a){return l=this,d=void 0,y=function(){var b,E,w,D,_;return (function(M,B){var H,K,J,tt,yt={label:0,sent:function(){if(1&J[0])throw J[1];return J[1]},trys:[],ops:[]};return tt={next:Rt(0),throw:Rt(1),return:Rt(2)},typeof Symbol=="function"&&(tt[Symbol.iterator]=function(){return this}),tt;function Rt(Zt){return function(zt){return (function(Bt){if(H)throw new TypeError("Generator is already executing.");for(;yt;)try{if(H=1,K&&(J=2&Bt[0]?K.return:Bt[0]?K.throw||((J=K.return)&&J.call(K),0):K.next)&&!(J=J.call(K,Bt[1])).done)return J;switch(K=0,J&&(Bt=[2&Bt[0],J.value]),Bt[0]){case 0:case 1:J=Bt;break;case 4:return yt.label++,{value:Bt[1],done:!1};case 5:yt.label++,K=Bt[1],Bt=[0];continue;case 7:Bt=yt.ops.pop(),yt.trys.pop();continue;default:if(!((J=(J=yt.trys).length>0&&J[J.length-1])||Bt[0]!==6&&Bt[0]!==2)){yt=0;continue}if(Bt[0]===3&&(!J||Bt[1]>J[0]&&Bt[1]<J[3])){yt.label=Bt[1];break}if(Bt[0]===6&&yt.label<J[1]){yt.label=J[1],J=Bt;break}if(J&&yt.label<J[2]){yt.label=J[2],yt.ops.push(Bt);break}J[2]&&yt.ops.pop(),yt.trys.pop();continue}Bt=B.call(M,yt);}catch(qt){Bt=[6,qt],K=0;}finally{H=J=0;}if(5&Bt[0])throw Bt[1];return {value:Bt[0]?Bt[1]:void 0,done:true}})([Zt,zt])}}})(this,(function(M){switch(M.label){case 0:return (b=new Headers).append("X-API-KEY",this.config.apiKey),b.append("X-API-VERSION","1"),b.append("source",Ke),(E=this.dynamicData.customerToken)&&b.append("X-CUSTOMER-KEY",E),[4,Ir("".concat(this.config.baseEdgeUri).concat(a),{headers:b,method:"GET"})];case 1:if(!(w=M.sent()).ok)throw (D=new Error("Failed to fetch data from Edge. Reason: ".concat(w.statusText))).response=w,D;return [4,w.json()];case 2:if(_=M.sent(),!Pn()(_.errors))throw new Ae({graphQLErrors:_.errors});return [2,_]}}))},new((m=void 0)||(m=Promise))((function(b,E){function w(M){try{_(y.next(M));}catch(B){E(B);}}function D(M){try{_(y.throw(M));}catch(B){E(B);}}function _(M){var B;M.done?b(M.value):(B=M.value,B instanceof m?B:new m((function(H){H(B);}))).then(w,D);}_((y=y.apply(l,d||[])).next());}));var l,d,m,y;},f})();function en(f,a){(a==null||a>f.length)&&(a=f.length);for(var l=0,d=new Array(a);l<a;l++)d[l]=f[l];return d}function ur(f,a){for(var l=0;l<a.length;l++){var d=a[l];d.enumerable=d.enumerable||false,d.configurable=true,"value"in d&&(d.writable=true),Object.defineProperty(f,d.key,d);}}function $t(f,a,l){return a&&ur(f.prototype,a),l&&ur(f,l),f}var Vr=function(){return typeof Symbol=="function"},xn=function(f){return Vr()&&!!Symbol[f]},jn=function(f){return xn(f)?Symbol[f]:"@@"+f};Vr()&&!xn("observable")&&(Symbol.observable=Symbol("observable"));var ct=jn("iterator"),si=jn("observable"),fn=jn("species");function dr(f,a){var l=f[a];if(l!=null){if(typeof l!="function")throw new TypeError(l+" is not a function");return l}}function kr(f){var a=f.constructor;return a!==void 0&&(a=a[fn])===null&&(a=void 0),a!==void 0?a:Je}function Ii(f){return f instanceof Je}function Wi(f){Wi.log?Wi.log(f):setTimeout((function(){throw f}));}function ki(f){Promise.resolve().then((function(){try{f();}catch(a){Wi(a);}}));}function hs(f){var a=f._cleanup;if(a!==void 0&&(f._cleanup=void 0,a))try{if(typeof a=="function")a();else {var l=dr(a,"unsubscribe");l&&l.call(a);}}catch(d){Wi(d);}}function Sa(f){f._observer=void 0,f._queue=void 0,f._state="closed";}function ms(f,a,l){f._state="running";var d=f._observer;try{var m=dr(d,a);switch(a){case "next":m&&m.call(d,l);break;case "error":if(Sa(f),!m)throw l;m.call(d,l);break;case "complete":Sa(f),m&&m.call(d);}}catch(y){Wi(y);}f._state==="closed"?hs(f):f._state==="running"&&(f._state="ready");}function Di(f,a,l){if(f._state!=="closed"){if(f._state!=="buffering")return f._state!=="ready"?(f._state="buffering",f._queue=[{type:a,value:l}],void ki((function(){return (function(d){var m=d._queue;if(m){d._queue=void 0,d._state="ready";for(var y=0;y<m.length&&(ms(d,m[y].type,m[y].value),d._state!=="closed");++y);}})(f)}))):void ms(f,a,l);f._queue.push({type:a,value:l});}}var hn=(function(){function f(a,l){this._cleanup=void 0,this._observer=a,this._queue=void 0,this._state="initializing";var d=new pr(this);try{this._cleanup=l.call(void 0,d);}catch(m){d.error(m);}this._state==="initializing"&&(this._state="ready");}return f.prototype.unsubscribe=function(){this._state!=="closed"&&(Sa(this),hs(this));},$t(f,[{key:"closed",get:function(){return this._state==="closed"}}]),f})(),pr=(function(){function f(l){this._subscription=l;}var a=f.prototype;return a.next=function(l){Di(this._subscription,"next",l);},a.error=function(l){Di(this._subscription,"error",l);},a.complete=function(){Di(this._subscription,"complete");},$t(f,[{key:"closed",get:function(){return this._subscription._state==="closed"}}]),f})(),Je=(function(){function f(l){if(!(this instanceof f))throw new TypeError("Observable cannot be called as a function");if(typeof l!="function")throw new TypeError("Observable initializer must be a function");this._subscriber=l;}var a=f.prototype;return a.subscribe=function(l){return typeof l=="object"&&l!==null||(l={next:l,error:arguments[1],complete:arguments[2]}),new hn(l,this._subscriber)},a.forEach=function(l){var d=this;return new Promise((function(m,y){if(typeof l=="function")var b=d.subscribe({next:function(w){try{l(w,E);}catch(D){y(D),b.unsubscribe();}},error:y,complete:m});else y(new TypeError(l+" is not a function"));function E(){b.unsubscribe(),m();}}))},a.map=function(l){var d=this;if(typeof l!="function")throw new TypeError(l+" is not a function");return new(kr(this))((function(m){return d.subscribe({next:function(y){try{y=l(y);}catch(b){return m.error(b)}m.next(y);},error:function(y){m.error(y);},complete:function(){m.complete();}})}))},a.filter=function(l){var d=this;if(typeof l!="function")throw new TypeError(l+" is not a function");return new(kr(this))((function(m){return d.subscribe({next:function(y){try{if(!l(y))return}catch(b){return m.error(b)}m.next(y);},error:function(y){m.error(y);},complete:function(){m.complete();}})}))},a.reduce=function(l){var d=this;if(typeof l!="function")throw new TypeError(l+" is not a function");var m=kr(this),y=arguments.length>1,b=false,E=arguments[1],w=E;return new m((function(D){return d.subscribe({next:function(_){var M=!b;if(b=true,!M||y)try{w=l(w,_);}catch(B){return D.error(B)}else w=_;},error:function(_){D.error(_);},complete:function(){if(!b&&!y)return D.error(new TypeError("Cannot reduce an empty sequence"));D.next(w),D.complete();}})}))},a.concat=function(){for(var l=this,d=arguments.length,m=new Array(d),y=0;y<d;y++)m[y]=arguments[y];var b=kr(this);return new b((function(E){var w,D=0;return (function _(M){w=M.subscribe({next:function(B){E.next(B);},error:function(B){E.error(B);},complete:function(){D===m.length?(w=void 0,E.complete()):_(b.from(m[D++]));}});})(l),function(){w&&(w.unsubscribe(),w=void 0);}}))},a.flatMap=function(l){var d=this;if(typeof l!="function")throw new TypeError(l+" is not a function");var m=kr(this);return new m((function(y){var b=[],E=d.subscribe({next:function(D){if(l)try{D=l(D);}catch(M){return y.error(M)}var _=m.from(D).subscribe({next:function(M){y.next(M);},error:function(M){y.error(M);},complete:function(){var M=b.indexOf(_);M>=0&&b.splice(M,1),w();}});b.push(_);},error:function(D){y.error(D);},complete:function(){w();}});function w(){E.closed&&b.length===0&&y.complete();}return function(){b.forEach((function(D){return D.unsubscribe()})),E.unsubscribe();}}))},a[si]=function(){return this},f.from=function(l){var d=typeof this=="function"?this:f;if(l==null)throw new TypeError(l+" is not an object");var m=dr(l,si);if(m){var y=m.call(l);if(Object(y)!==y)throw new TypeError(y+" is not an object");return Ii(y)&&y.constructor===d?y:new d((function(b){return y.subscribe(b)}))}if(xn("iterator")&&(m=dr(l,ct)))return new d((function(b){ki((function(){if(!b.closed){for(var E,w=(function(_,M){var B=typeof Symbol!="undefined"&&_[Symbol.iterator]||_["@@iterator"];if(B)return (B=B.call(_)).next.bind(B);if(Array.isArray(_)||(B=(function(K,J){if(K){if(typeof K=="string")return en(K,J);var tt=Object.prototype.toString.call(K).slice(8,-1);return tt==="Object"&&K.constructor&&(tt=K.constructor.name),tt==="Map"||tt==="Set"?Array.from(K):tt==="Arguments"||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(tt)?en(K,J):void 0}})(_))||M&&_&&typeof _.length=="number"){B&&(_=B);var H=0;return function(){return H>=_.length?{done:!0}:{done:!1,value:_[H++]}}}throw new TypeError(`Invalid attempt to iterate non-iterable instance.
2324
+ `),m=m.replace(/\n$/,"")),_.extraInfo=D,_.__proto__=a.prototype,_}return Ve(a,f),a})(Error),cn=(n(1905),n(4139)),pn=fetch,Ir=n.n(cn)()(fetch,{retryOn:function(f,a,l){return !(f>5)&&(a!==null||!(l!=null&&l.status)||l.status>=500)},retryDelay:function(f){return 1e3*Math.pow(2,f)}}),cr=(function(){function f(a,l){this.config=a,this.dynamicData=l;}return f.create=function(a,l){return a.enableEdge?new f(a,l):null},f.prototype.getPaywall=function(a,l,d){var m=a?"/p/".concat(a):"",y=l?"billingCountryCode=".concat(l):"",b=d?"&includeHiddenPlans=".concat(d):"";return this.get("/v1".concat(m,"/paywall.json?").concat(y).concat(b))},f.prototype.getEntitlements=function(a,l){var d=l?"?resourceId=".concat(l):"";return this.get("/v1/c/".concat(a,"/entitlements.json").concat(d))},f.prototype.getActiveSubscriptionsList=function(a,l){var d=new URLSearchParams;(0, R.isString)(l)?d.set("resourceId",l):(0, R.isArray)(l)&&l.forEach((function(y){return d.append("resourceIds",y)}));var m="/v1/c/".concat(a,"/subscriptions.json?").concat(d.toString());return this.get(m)},f.prototype.getSdkConfiguration=function(){return this.get("/v1/config/client-sdk-configuration.json")},f.prototype.get=function(a){return l=this,d=void 0,y=function(){var b,E,w,D,_;return (function(M,B){var H,K,J,tt,yt={label:0,sent:function(){if(1&J[0])throw J[1];return J[1]},trys:[],ops:[]};return tt={next:Rt(0),throw:Rt(1),return:Rt(2)},typeof Symbol=="function"&&(tt[Symbol.iterator]=function(){return this}),tt;function Rt(Zt){return function(zt){return (function(Bt){if(H)throw new TypeError("Generator is already executing.");for(;yt;)try{if(H=1,K&&(J=2&Bt[0]?K.return:Bt[0]?K.throw||((J=K.return)&&J.call(K),0):K.next)&&!(J=J.call(K,Bt[1])).done)return J;switch(K=0,J&&(Bt=[2&Bt[0],J.value]),Bt[0]){case 0:case 1:J=Bt;break;case 4:return yt.label++,{value:Bt[1],done:!1};case 5:yt.label++,K=Bt[1],Bt=[0];continue;case 7:Bt=yt.ops.pop(),yt.trys.pop();continue;default:if(!((J=(J=yt.trys).length>0&&J[J.length-1])||Bt[0]!==6&&Bt[0]!==2)){yt=0;continue}if(Bt[0]===3&&(!J||Bt[1]>J[0]&&Bt[1]<J[3])){yt.label=Bt[1];break}if(Bt[0]===6&&yt.label<J[1]){yt.label=J[1],J=Bt;break}if(J&&yt.label<J[2]){yt.label=J[2],yt.ops.push(Bt);break}J[2]&&yt.ops.pop(),yt.trys.pop();continue}Bt=B.call(M,yt);}catch(qt){Bt=[6,qt],K=0;}finally{H=J=0;}if(5&Bt[0])throw Bt[1];return {value:Bt[0]?Bt[1]:void 0,done:true}})([Zt,zt])}}})(this,(function(M){switch(M.label){case 0:return (b=new Headers).append("X-API-KEY",this.config.apiKey),b.append("X-API-VERSION","1"),b.append("source",Ke),(E=this.dynamicData.customerToken)&&b.append("X-CUSTOMER-KEY",E),[4,Ir("".concat(this.config.baseEdgeUri).concat(a),{headers:b,method:"GET"})];case 1:if(!(w=M.sent()).ok)throw (D=new Error("Failed to fetch data from Edge. Reason: ".concat(w.statusText))).response=w,D;return [4,w.json()];case 2:if(_=M.sent(),!Pn()(_.errors))throw new Ae({graphQLErrors:_.errors});return [2,_]}}))},new((m=void 0)||(m=Promise))((function(b,E){function w(M){try{_(y.next(M));}catch(B){E(B);}}function D(M){try{_(y.throw(M));}catch(B){E(B);}}function _(M){var B;M.done?b(M.value):(B=M.value,B instanceof m?B:new m((function(H){H(B);}))).then(w,D);}_((y=y.apply(l,d||[])).next());}));var l,d,m,y;},f})();function en(f,a){(a==null||a>f.length)&&(a=f.length);for(var l=0,d=new Array(a);l<a;l++)d[l]=f[l];return d}function ur(f,a){for(var l=0;l<a.length;l++){var d=a[l];d.enumerable=d.enumerable||false,d.configurable=true,"value"in d&&(d.writable=true),Object.defineProperty(f,d.key,d);}}function $t(f,a,l){return a&&ur(f.prototype,a),l&&ur(f,l),f}var Vr=function(){return typeof Symbol=="function"},xn=function(f){return Vr()&&!!Symbol[f]},jn=function(f){return xn(f)?Symbol[f]:"@@"+f};Vr()&&!xn("observable")&&(Symbol.observable=Symbol("observable"));var ct=jn("iterator"),si=jn("observable"),fn=jn("species");function dr(f,a){var l=f[a];if(l!=null){if(typeof l!="function")throw new TypeError(l+" is not a function");return l}}function kr(f){var a=f.constructor;return a!==void 0&&(a=a[fn])===null&&(a=void 0),a!==void 0?a:Je}function Ii(f){return f instanceof Je}function Wi(f){Wi.log?Wi.log(f):setTimeout((function(){throw f}));}function ki(f){Promise.resolve().then((function(){try{f();}catch(a){Wi(a);}}));}function hs(f){var a=f._cleanup;if(a!==void 0&&(f._cleanup=void 0,a))try{if(typeof a=="function")a();else {var l=dr(a,"unsubscribe");l&&l.call(a);}}catch(d){Wi(d);}}function Sa(f){f._observer=void 0,f._queue=void 0,f._state="closed";}function ms(f,a,l){f._state="running";var d=f._observer;try{var m=dr(d,a);switch(a){case "next":m&&m.call(d,l);break;case "error":if(Sa(f),!m)throw l;m.call(d,l);break;case "complete":Sa(f),m&&m.call(d);}}catch(y){Wi(y);}f._state==="closed"?hs(f):f._state==="running"&&(f._state="ready");}function Di(f,a,l){if(f._state!=="closed"){if(f._state!=="buffering")return f._state!=="ready"?(f._state="buffering",f._queue=[{type:a,value:l}],void ki((function(){return (function(d){var m=d._queue;if(m){d._queue=void 0,d._state="ready";for(var y=0;y<m.length&&(ms(d,m[y].type,m[y].value),d._state!=="closed");++y);}})(f)}))):void ms(f,a,l);f._queue.push({type:a,value:l});}}var hn=(function(){function f(a,l){this._cleanup=void 0,this._observer=a,this._queue=void 0,this._state="initializing";var d=new pr(this);try{this._cleanup=l.call(void 0,d);}catch(m){d.error(m);}this._state==="initializing"&&(this._state="ready");}return f.prototype.unsubscribe=function(){this._state!=="closed"&&(Sa(this),hs(this));},$t(f,[{key:"closed",get:function(){return this._state==="closed"}}]),f})(),pr=(function(){function f(l){this._subscription=l;}var a=f.prototype;return a.next=function(l){Di(this._subscription,"next",l);},a.error=function(l){Di(this._subscription,"error",l);},a.complete=function(){Di(this._subscription,"complete");},$t(f,[{key:"closed",get:function(){return this._subscription._state==="closed"}}]),f})(),Je=(function(){function f(l){if(!(this instanceof f))throw new TypeError("Observable cannot be called as a function");if(typeof l!="function")throw new TypeError("Observable initializer must be a function");this._subscriber=l;}var a=f.prototype;return a.subscribe=function(l){return typeof l=="object"&&l!==null||(l={next:l,error:arguments[1],complete:arguments[2]}),new hn(l,this._subscriber)},a.forEach=function(l){var d=this;return new Promise((function(m,y){if(typeof l=="function")var b=d.subscribe({next:function(w){try{l(w,E);}catch(D){y(D),b.unsubscribe();}},error:y,complete:m});else y(new TypeError(l+" is not a function"));function E(){b.unsubscribe(),m();}}))},a.map=function(l){var d=this;if(typeof l!="function")throw new TypeError(l+" is not a function");return new(kr(this))((function(m){return d.subscribe({next:function(y){try{y=l(y);}catch(b){return m.error(b)}m.next(y);},error:function(y){m.error(y);},complete:function(){m.complete();}})}))},a.filter=function(l){var d=this;if(typeof l!="function")throw new TypeError(l+" is not a function");return new(kr(this))((function(m){return d.subscribe({next:function(y){try{if(!l(y))return}catch(b){return m.error(b)}m.next(y);},error:function(y){m.error(y);},complete:function(){m.complete();}})}))},a.reduce=function(l){var d=this;if(typeof l!="function")throw new TypeError(l+" is not a function");var m=kr(this),y=arguments.length>1,b=false,E=arguments[1],w=E;return new m((function(D){return d.subscribe({next:function(_){var M=!b;if(b=true,!M||y)try{w=l(w,_);}catch(B){return D.error(B)}else w=_;},error:function(_){D.error(_);},complete:function(){if(!b&&!y)return D.error(new TypeError("Cannot reduce an empty sequence"));D.next(w),D.complete();}})}))},a.concat=function(){for(var l=this,d=arguments.length,m=new Array(d),y=0;y<d;y++)m[y]=arguments[y];var b=kr(this);return new b((function(E){var w,D=0;return (function _(M){w=M.subscribe({next:function(B){E.next(B);},error:function(B){E.error(B);},complete:function(){D===m.length?(w=void 0,E.complete()):_(b.from(m[D++]));}});})(l),function(){w&&(w.unsubscribe(),w=void 0);}}))},a.flatMap=function(l){var d=this;if(typeof l!="function")throw new TypeError(l+" is not a function");var m=kr(this);return new m((function(y){var b=[],E=d.subscribe({next:function(D){if(l)try{D=l(D);}catch(M){return y.error(M)}var _=m.from(D).subscribe({next:function(M){y.next(M);},error:function(M){y.error(M);},complete:function(){var M=b.indexOf(_);M>=0&&b.splice(M,1),w();}});b.push(_);},error:function(D){y.error(D);},complete:function(){w();}});function w(){E.closed&&b.length===0&&y.complete();}return function(){b.forEach((function(D){return D.unsubscribe()})),E.unsubscribe();}}))},a[si]=function(){return this},f.from=function(l){var d=typeof this=="function"?this:f;if(l==null)throw new TypeError(l+" is not an object");var m=dr(l,si);if(m){var y=m.call(l);if(Object(y)!==y)throw new TypeError(y+" is not an object");return Ii(y)&&y.constructor===d?y:new d((function(b){return y.subscribe(b)}))}if(xn("iterator")&&(m=dr(l,ct)))return new d((function(b){ki((function(){if(!b.closed){for(var E,w=(function(_,M){var B=typeof Symbol!="undefined"&&_[Symbol.iterator]||_["@@iterator"];if(B)return (B=B.call(_)).next.bind(B);if(Array.isArray(_)||(B=(function(K,J){if(K){if(typeof K=="string")return en(K,J);var tt=Object.prototype.toString.call(K).slice(8,-1);return tt==="Object"&&K.constructor&&(tt=K.constructor.name),tt==="Map"||tt==="Set"?Array.from(K):tt==="Arguments"||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(tt)?en(K,J):void 0}})(_))||M&&_&&typeof _.length=="number"){B&&(_=B);var H=0;return function(){return H>=_.length?{done:!0}:{done:!1,value:_[H++]}}}throw new TypeError(`Invalid attempt to iterate non-iterable instance.
2325
2325
  In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`)})(m.call(l));!(E=w()).done;){var D=E.value;if(b.next(D),b.closed)return}b.complete();}}));}));if(Array.isArray(l))return new d((function(b){ki((function(){if(!b.closed){for(var E=0;E<l.length;++E)if(b.next(l[E]),b.closed)return;b.complete();}}));}));throw new TypeError(l+" is not observable")},f.of=function(){for(var l=arguments.length,d=new Array(l),m=0;m<l;m++)d[m]=arguments[m];var y=typeof this=="function"?this:f;return new y((function(b){ki((function(){if(!b.closed){for(var E=0;E<d.length;++E)if(b.next(d[E]),b.closed)return;b.complete();}}));}))},$t(f,null,[{key:fn,get:function(){return this}}]),f})();function vt(f){return f!==null&&typeof f=="object"}function gs(f,a){var l=a,d=[];return f.definitions.forEach((function(m){if(m.kind==="OperationDefinition")throw __DEV__?new Ce("Found a "+m.operation+" operation"+(m.name?" named '"+m.name.value+"'":"")+". No operations are allowed when using a fragment as a query. Only fragments are allowed."):new Ce(43);m.kind==="FragmentDefinition"&&d.push(m);})),l===void 0&&(__DEV__?Vt(d.length===1,"Found "+d.length+" fragments. `fragmentName` must be provided when there is not exactly 1 fragment."):Vt(d.length===1,44),l=d[0].name.value),bt(bt({},f),{definitions:lr([{kind:"OperationDefinition",operation:"query",selectionSet:{kind:"SelectionSet",selections:[{kind:"FragmentSpread",name:{kind:"Name",value:l}}]}}],f.definitions,true)})}function So(f){f===void 0&&(f=[]);var a={};return f.forEach((function(l){a[l.name.value]=l;})),a}function Pa(f,a){switch(f.kind){case "InlineFragment":return f;case "FragmentSpread":var l=a&&a[f.name.value];return __DEV__?Vt(l,"No fragment named "+f.name.value+"."):Vt(l,45),l;default:return null}}function qi(f){return {__ref:String(f)}}function ae(f){return !!(f&&typeof f=="object"&&typeof f.__ref=="string")}function Ue(f,a,l,d){if((function(b){return b.kind==="IntValue"})(l)||(function(b){return b.kind==="FloatValue"})(l))f[a.value]=Number(l.value);else if((function(b){return b.kind==="BooleanValue"})(l)||(function(b){return b.kind==="StringValue"})(l))f[a.value]=l.value;else if((function(b){return b.kind==="ObjectValue"})(l)){var m={};l.fields.map((function(b){return Ue(m,b.name,b.value,d)})),f[a.value]=m;}else if((function(b){return b.kind==="Variable"})(l)){var y=(d||{})[l.name.value];f[a.value]=y;}else if((function(b){return b.kind==="ListValue"})(l))f[a.value]=l.values.map((function(b){var E={};return Ue(E,a,b,d),E[a.value]}));else if((function(b){return b.kind==="EnumValue"})(l))f[a.value]=l.value;else {if(!(function(b){return b.kind==="NullValue"})(l))throw __DEV__?new Ce('The inline argument "'+a.value+'" of kind "'+l.kind+'"is not supported. Use variables instead of inline arguments to overcome this limitation.'):new Ce(54);f[a.value]=null;}}Vr()&&Object.defineProperty(Je,Symbol("extensions"),{value:{symbol:si,hostReportError:Wi},configurable:true});var Yr=["connection","include","skip","client","rest","export"],li=Object.assign((function(f,a,l){if(a&&l&&l.connection&&l.connection.key){if(l.connection.filter&&l.connection.filter.length>0){var d=l.connection.filter?l.connection.filter:[];d.sort();var m={};return d.forEach((function(E){m[E]=a[E];})),l.connection.key+"("+Yi(m)+")"}return l.connection.key}var y=f;if(a){var b=Yi(a);y+="("+b+")";}return l&&Object.keys(l).forEach((function(E){Yr.indexOf(E)===-1&&(l[E]&&Object.keys(l[E]).length?y+="@"+E+"("+Yi(l[E])+")":y+="@"+E);})),y}),{setStringify:function(f){var a=Yi;return Yi=f,a}}),Yi=function(f){return JSON.stringify(f,xl)};function xl(f,a){return vt(a)&&!Array.isArray(a)&&(a=Object.keys(a).sort().reduce((function(l,d){return l[d]=a[d],l}),{})),a}function El(f,a){if(f.arguments&&f.arguments.length){var l={};return f.arguments.forEach((function(d){var m=d.name,y=d.value;return Ue(l,m,y,a)})),l}return null}function on(f){return f.alias?f.alias.value:f.name.value}function xa(f,a,l){if(typeof f.__typename=="string")return f.__typename;for(var d=0,m=a.selections;d<m.length;d++){var y=m[d];if(tr(y)){if(y.name.value==="__typename")return f[on(y)]}else {var b=xa(f,Pa(y,l).selectionSet,l);if(typeof b=="string")return b}}}function tr(f){return f.kind==="Field"}function Ea(f){return f.kind==="InlineFragment"}function ci(f){__DEV__?Vt(f&&f.kind==="Document",'Expecting a parsed GraphQL document. Perhaps you need to wrap the query string in a "gql" tag? http://docs.apollostack.com/apollo-client/core.html#gql'):Vt(f&&f.kind==="Document",46);var a=f.definitions.filter((function(l){return l.kind!=="FragmentDefinition"})).map((function(l){if(l.kind!=="OperationDefinition")throw __DEV__?new Ce('Schema type definitions not allowed in queries. Found: "'+l.kind+'"'):new Ce(47);return l}));return __DEV__?Vt(a.length<=1,"Ambiguous GraphQL document: contains "+a.length+" operations"):Vt(a.length<=1,48),f}function Kn(f){return ci(f),f.definitions.filter((function(a){return a.kind==="OperationDefinition"}))[0]}function Ai(f){return f.definitions.filter((function(a){return a.kind==="OperationDefinition"&&a.name})).map((function(a){return a.name.value}))[0]||null}function er(f){return f.definitions.filter((function(a){return a.kind==="FragmentDefinition"}))}function ys(f){var a=Kn(f);return __DEV__?Vt(a&&a.operation==="query","Must contain a query definition."):Vt(a&&a.operation==="query",49),a}function _a(f){var a;ci(f);for(var l=0,d=f.definitions;l<d.length;l++){var m=d[l];if(m.kind==="OperationDefinition"){var y=m.operation;if(y==="query"||y==="mutation"||y==="subscription")return m}m.kind!=="FragmentDefinition"||a||(a=m);}if(a)return a;throw __DEV__?new Ce("Expected a parsed GraphQL query with a query, mutation, subscription, or a fragment."):new Ce(53)}function zo(f){var a=Object.create(null),l=f&&f.variableDefinitions;return l&&l.length&&l.forEach((function(d){d.defaultValue&&Ue(a,d.variable.name,d.defaultValue);})),a}function Cr(f,a){return a?a(f):Je.of()}function nr(f){return typeof f=="function"?new Tt(f):f}function Kt(f){return f.request.length<=1}var Wt=(function(f){function a(l,d){var m=f.call(this,l)||this;return m.link=d,m}return Ve(a,f),a})(Error),Tt=(function(){function f(a){a&&(this.request=a);}return f.empty=function(){return new f((function(){return Je.of()}))},f.from=function(a){return a.length===0?f.empty():a.map(nr).reduce((function(l,d){return l.concat(d)}))},f.split=function(a,l,d){var m=nr(l),y=nr(d||new f(Cr));return Kt(m)&&Kt(y)?new f((function(b){return a(b)?m.request(b)||Je.of():y.request(b)||Je.of()})):new f((function(b,E){return a(b)?m.request(b,E)||Je.of():y.request(b,E)||Je.of()}))},f.execute=function(a,l){return a.request((function(d,m){var y=bt({},d);return Object.defineProperty(m,"setContext",{enumerable:false,value:function(b){y=bt(bt({},y),typeof b=="function"?b(y):b);}}),Object.defineProperty(m,"getContext",{enumerable:false,value:function(){return bt({},y)}}),m})(l.context,(function(d){var m={variables:d.variables||{},extensions:d.extensions||{},operationName:d.operationName,query:d.query};return m.operationName||(m.operationName=typeof m.query!="string"?Ai(m.query)||void 0:""),m})((function(d){for(var m=["query","operationName","variables","extensions","context"],y=0,b=Object.keys(d);y<b.length;y++){var E=b[y];if(m.indexOf(E)<0)throw __DEV__?new Ce("illegal argument: "+E):new Ce(26)}return d})(l))))||Je.of()},f.concat=function(a,l){var d=nr(a);if(Kt(d))return __DEV__&&Vt.warn(new Wt("You are calling concat on a terminating link, which will have no effect",d)),d;var m=nr(l);return Kt(m)?new f((function(y){return d.request(y,(function(b){return m.request(b)||Je.of()}))||Je.of()})):new f((function(y,b){return d.request(y,(function(E){return m.request(E,b)||Je.of()}))||Je.of()}))},f.prototype.split=function(a,l,d){return this.concat(f.split(a,l,d||new f(Cr)))},f.prototype.concat=function(a){return f.concat(this,a)},f.prototype.request=function(a,l){throw __DEV__?new Ce("request is not implemented"):new Ce(21)},f.prototype.onError=function(a,l){if(l&&l.error)return l.error(a),false;throw a},f.prototype.setOnError=function(a){return this.onError=a,this},f})(),kt=n(5821),xt=n(5217),jc={Name:[],Document:["definitions"],OperationDefinition:["name","variableDefinitions","directives","selectionSet"],VariableDefinition:["variable","type","defaultValue","directives"],Variable:["name"],SelectionSet:["selections"],Field:["alias","name","arguments","directives","selectionSet"],Argument:["name","value"],FragmentSpread:["name","directives"],InlineFragment:["typeCondition","directives","selectionSet"],FragmentDefinition:["name","variableDefinitions","typeCondition","directives","selectionSet"],IntValue:[],FloatValue:[],StringValue:[],BooleanValue:[],NullValue:[],EnumValue:[],ListValue:["values"],ObjectValue:["fields"],ObjectField:["name","value"],Directive:["name","arguments"],NamedType:["name"],ListType:["type"],NonNullType:["type"],SchemaDefinition:["description","directives","operationTypes"],OperationTypeDefinition:["type"],ScalarTypeDefinition:["description","name","directives"],ObjectTypeDefinition:["description","name","interfaces","directives","fields"],FieldDefinition:["description","name","arguments","type","directives"],InputValueDefinition:["description","name","type","defaultValue","directives"],InterfaceTypeDefinition:["description","name","interfaces","directives","fields"],UnionTypeDefinition:["description","name","directives","types"],EnumTypeDefinition:["description","name","directives","values"],EnumValueDefinition:["description","name","directives"],InputObjectTypeDefinition:["description","name","directives","fields"],DirectiveDefinition:["description","name","arguments","locations"],SchemaExtension:["directives","operationTypes"],ScalarTypeExtension:["name","directives"],ObjectTypeExtension:["name","interfaces","directives","fields"],InterfaceTypeExtension:["name","interfaces","directives","fields"],UnionTypeExtension:["name","directives","types"],EnumTypeExtension:["name","directives","values"],InputObjectTypeExtension:["name","directives","fields"]},Vc=Object.freeze({});function We(f,a){var l=arguments.length>2&&arguments[2]!==void 0?arguments[2]:jc,d=void 0,m=Array.isArray(f),y=[f],b=-1,E=[],w=void 0,D=void 0,_=void 0,M=[],B=[],H=f;do{var K=++b===y.length,J=K&&E.length!==0;if(K){if(D=B.length===0?void 0:M[M.length-1],w=_,_=B.pop(),J){if(m)w=w.slice();else {for(var tt={},yt=0,Rt=Object.keys(w);yt<Rt.length;yt++){var Zt=Rt[yt];tt[Zt]=w[Zt];}w=tt;}for(var zt=0,Bt=0;Bt<E.length;Bt++){var qt=E[Bt][0],$e=E[Bt][1];m&&(qt-=zt),m&&$e===null?(w.splice(qt,1),zt++):w[qt]=$e;}}b=d.index,y=d.keys,E=d.edits,m=d.inArray,d=d.prev;}else {if(D=_?m?b:y[b]:void 0,(w=_?_[D]:H)==null)continue;_&&M.push(D);}var fe,Oe=void 0;if(!Array.isArray(w)){if(!(0, xt.UG)(w))throw new Error("Invalid AST Node: ".concat((0, kt.Z)(w),"."));var An=Ho(a,w.kind,K);if(An){if((Oe=An.call(a,w,D,_,M,B))===Vc)break;if(Oe===false){if(!K){M.pop();continue}}else if(Oe!==void 0&&(E.push([D,Oe]),!K)){if(!(0, xt.UG)(Oe)){M.pop();continue}w=Oe;}}}Oe===void 0&&J&&E.push([D,w]),K?M.pop():(d={inArray:m,index:b,keys:y,edits:E,prev:d},y=(m=Array.isArray(w))?w:(fe=l[w.kind])!==null&&fe!==void 0?fe:[],b=-1,E=[],_&&B.push(_),_=w);}while(d!==void 0);return E.length!==0&&(H=E[E.length-1][1]),H}function Ho(f,a,l){var d=f[a];if(d){if(!l&&typeof d=="function")return d;var m=l?d.leave:d.enter;if(typeof m=="function")return m}else {var y=l?f.leave:f.enter;if(y){if(typeof y=="function")return y;var b=y[a];if(typeof b=="function")return b}}}var _l=function(f,a){var l;try{l=JSON.stringify(f);}catch(m){var d=__DEV__?new Ce("Network request failed. "+a+" is not serializable: "+m.message):new Ce(23);throw d.parseError=m,d}return l},Uf=function(f,a,l){var d=new Error(l);throw d.name="ServerError",d.response=f,d.statusCode=f.status,d.result=a,d},zc=Object.prototype.hasOwnProperty,Vy=n(7392);function $f(f){return We(f,{leave:Hc})}var Hc={Name:function(f){return f.value},Variable:function(f){return "$"+f.name},Document:function(f){return te(f.definitions,`
2326
2326
 
2327
2327
  `)+`
@@ -2348,7 +2348,7 @@ import { ApolloClient, HttpLink } from '@apollo/client';
2348
2348
  const client = new ApolloClient({
2349
2349
  link: new HttpLink({ uri: '/graphql', fetch })
2350
2350
  });
2351
- `):new Ce(22)})(E||zr);var H={http:{includeExtensions:w},options:B.fetchOptions,credentials:B.credentials,headers:B.headers};return new Tt((function(K){var J=(function(q,et){return q.getContext().uri||(typeof et=="function"?et(q):et||"/graphql")})(K,b),tt=K.getContext(),yt={};if(tt.clientAwareness){var Rt=tt.clientAwareness,Zt=Rt.name,zt=Rt.version;Zt&&(yt["apollographql-client-name"]=Zt),zt&&(yt["apollographql-client-version"]=zt);}var Bt,qt=bt(bt({},yt),tt.headers),$e={http:tt.http,options:tt.fetchOptions,credentials:tt.credentials,headers:qt},fe=(function(q,et){for(var lt=[],Et=2;Et<arguments.length;Et++)lt[Et-2]=arguments[Et];var wt=bt(bt({},et.options),{headers:et.headers,credentials:et.credentials}),Mt=et.http||{};lt.forEach((function(ie){wt=bt(bt(bt({},wt),ie.options),{headers:bt(bt({},wt.headers),Ed(ie.headers))}),ie.credentials&&(wt.credentials=ie.credentials),Mt=bt(bt({},Mt),ie.http);}));var Yt=q.operationName,Qt=q.extensions,oe=q.variables,Ft=q.query,Ut={operationName:Yt,variables:oe};return Mt.includeExtensions&&(Ut.extensions=Qt),Mt.includeQuery&&(Ut.query=$f(Ft)),{options:wt,body:Ut}})(K,xd,H,$e),Oe=fe.options,An=fe.body;if(An.variables&&!M){var Mr=new Set(Object.keys(An.variables));We(K.query,{Variable:function(q,et,lt){lt&&lt.kind!=="VariableDefinition"&&Mr.delete(q.name.value);}}),Mr.size&&(An.variables=bt({},An.variables),Mr.forEach((function(q){delete An.variables[q];})));}if(!Oe.signal){var u=(function(){if(typeof AbortController=="undefined")return {controller:false,signal:false};var q=new AbortController;return {controller:q,signal:q.signal}})(),g=u.controller,S=u.signal;(Bt=g)&&(Oe.signal=S);}if(D&&!K.query.definitions.some((function(q){return q.kind==="OperationDefinition"&&q.operation==="mutation"}))&&(Oe.method="GET"),Oe.method==="GET"){var k=(function(q,et){var lt=[],Et=function(Ut,ie){lt.push(Ut+"="+encodeURIComponent(ie));};if("query"in et&&Et("query",et.query),et.operationName&&Et("operationName",et.operationName),et.variables){var wt=void 0;try{wt=_l(et.variables,"Variables map");}catch(Ut){return {parseError:Ut}}Et("variables",wt);}if(et.extensions){var Mt=void 0;try{Mt=_l(et.extensions,"Extensions map");}catch(Ut){return {parseError:Ut}}Et("extensions",Mt);}var Yt="",Qt=q,oe=q.indexOf("#");oe!==-1&&(Yt=q.substr(oe),Qt=q.substr(0,oe));var Ft=Qt.indexOf("?")===-1?"?":"&";return {newURI:Qt+Ft+lt.join("&")+Yt}})(J,An),R=k.newURI,$=k.parseError;if($)return _d($);J=R;}else try{Oe.body=_l(An,"Payload");}catch(q){return _d(q)}return new Je((function(q){var et;return (E||it((function(){return fetch}))||zr)(J,Oe).then((function(lt){return K.setContext({response:lt}),lt})).then((et=K,function(lt){return lt.text().then((function(Et){try{return JSON.parse(Et)}catch(Mt){var wt=Mt;throw wt.name="ServerParseError",wt.response=lt,wt.statusCode=lt.status,wt.bodyText=Et,wt}})).then((function(Et){return lt.status>=300&&Uf(lt,Et,"Response not successful: Received status code "+lt.status),Array.isArray(Et)||zc.call(Et,"data")||zc.call(Et,"errors")||Uf(lt,Et,"Server response was missing for query '"+(Array.isArray(et)?et.map((function(wt){return wt.operationName})):et.operationName)+"'."),Et}))})).then((function(lt){return q.next(lt),q.complete(),lt})).catch((function(lt){lt.name!=="AbortError"&&(lt.result&&lt.result.errors&&lt.result.data&&q.next(lt.result),q.error(lt));})),function(){Bt&&Bt.abort();}}))}))})(l).request)||this;return d.options=l,d}return Ve(a,f),a})(Tt),Ta=Tt.execute;function vs(){for(var f=[],a=0;a<arguments.length;a++)f[a]=arguments[a];var l=Object.create(null);return f.forEach((function(d){d&&Object.keys(d).forEach((function(m){var y=d[m];y!==void 0&&(l[m]=y);}));})),l}var Td=Object.prototype,Gf=Td.toString,zy=Td.hasOwnProperty,jf=Function.prototype.toString,wd=new Map;function Nn(f,a){try{return Tl(f,a)}finally{wd.clear();}}function Tl(f,a){if(f===a)return true;var l,d,m,y=Gf.call(f);if(y!==Gf.call(a))return false;switch(y){case "[object Array]":if(f.length!==a.length)return false;case "[object Object]":if(Vf(f,a))return true;var b=Id(f),E=Id(a),w=b.length;if(w!==E.length)return false;for(var D=0;D<w;++D)if(!zy.call(a,b[D]))return false;for(D=0;D<w;++D){var _=b[D];if(!Tl(f[_],a[_]))return false}return true;case "[object Error]":return f.name===a.name&&f.message===a.message;case "[object Number]":if(f!=f)return a!=a;case "[object Boolean]":case "[object Date]":return +f==+a;case "[object RegExp]":case "[object String]":return f==""+a;case "[object Map]":case "[object Set]":if(f.size!==a.size)return false;if(Vf(f,a))return true;for(var M=f.entries(),B=y==="[object Map]";;){var H=M.next();if(H.done)break;var K=H.value,J=K[0],tt=K[1];if(!a.has(J)||B&&!Tl(tt,a.get(J)))return false}return true;case "[object Uint16Array]":case "[object Uint8Array]":case "[object Uint32Array]":case "[object Int32Array]":case "[object Int8Array]":case "[object Int16Array]":case "[object ArrayBuffer]":f=new Uint8Array(f),a=new Uint8Array(a);case "[object DataView]":var yt=f.byteLength;if(yt===a.byteLength)for(;yt--&&f[yt]===a[yt];);return yt===-1;case "[object AsyncFunction]":case "[object GeneratorFunction]":case "[object AsyncGeneratorFunction]":case "[object Function]":var Rt=jf.call(f);return Rt===jf.call(a)&&(d=qc,!((m=(l=Rt).length-d.length)>=0&&l.indexOf(d,m)===m))}return false}function Id(f){return Object.keys(f).filter(Wo,f)}function Wo(f){return this[f]!==void 0}var qc="{ [native code] }";function Vf(f,a){var l=wd.get(f);if(l){if(l.has(a))return true}else wd.set(f,l=new Set);return l.add(a),false}var qo,Qr,zf=function(){return Object.create(null)},Hf=Array.prototype,Yc=Hf.forEach,ht=Hf.slice,At=(function(){function f(a,l){a===void 0&&(a=true),l===void 0&&(l=zf),this.weakness=a,this.makeData=l;}return f.prototype.lookup=function(){for(var a=[],l=0;l<arguments.length;l++)a[l]=arguments[l];return this.lookupArray(a)},f.prototype.lookupArray=function(a){var l=this;return Yc.call(a,(function(d){return l=l.getChildTrie(d)})),l.data||(l.data=this.makeData(ht.call(a)))},f.prototype.getChildTrie=function(a){var l=this.weakness&&(function(m){switch(typeof m){case "object":if(m===null)break;case "function":return true}return false})(a)?this.weak||(this.weak=new WeakMap):this.strong||(this.strong=new Map),d=l.get(a);return d||l.set(a,d=new f(this.weakness,this.makeData)),d},f})(),Dt=typeof WeakMap=="function"&&!(typeof navigator=="object"&&navigator.product==="ReactNative"),Ht=typeof WeakSet=="function",xe=typeof Symbol=="function"&&typeof Symbol.for=="function",Ne=(function(){function f(){this.known=new(Ht?WeakSet:Set),this.pool=new At(Dt),this.passes=new WeakMap,this.keysByJSON=new Map,this.empty=this.admit({});}return f.prototype.isKnown=function(a){return vt(a)&&this.known.has(a)},f.prototype.pass=function(a){if(vt(a)){var l=(function(d){return vt(d)?Array.isArray(d)?d.slice(0):bt({__proto__:Object.getPrototypeOf(d)},d):d})(a);return this.passes.set(l,a),l}return a},f.prototype.admit=function(a){var l=this;if(vt(a)){var d=this.passes.get(a);if(d)return d;switch(Object.getPrototypeOf(a)){case Array.prototype:if(this.known.has(a))return a;var m=a.map(this.admit,this);return (w=this.pool.lookupArray(m)).array||(this.known.add(w.array=m),__DEV__&&Object.freeze(m)),w.array;case null:case Object.prototype:if(this.known.has(a))return a;var y=Object.getPrototypeOf(a),b=[y],E=this.sortedKeys(a);b.push(E.json);var w,D=b.length;if(E.sorted.forEach((function(M){b.push(l.admit(a[M]));})),!(w=this.pool.lookupArray(b)).object){var _=w.object=Object.create(y);this.known.add(_),E.sorted.forEach((function(M,B){_[M]=b[D+B];})),__DEV__&&Object.freeze(_);}return w.object}}return a},f.prototype.sortedKeys=function(a){var l=Object.keys(a),d=this.pool.lookupArray(l);if(!d.keys){l.sort();var m=JSON.stringify(l);(d.keys=this.keysByJSON.get(m))||this.keysByJSON.set(m,d.keys={sorted:l,json:m});}return d.keys},f})(),En=Object.assign((function(f){if(vt(f)){qo===void 0&&Oi();var a=qo.admit(f),l=Qr.get(a);return l===void 0&&Qr.set(a,l=JSON.stringify(a)),l}return JSON.stringify(f)}),{reset:Oi});function Oi(){qo=new Ne,Qr=new(Dt?WeakMap:Map);}function mn(f,a,l){return new Je((function(d){var m=d.next,y=d.error,b=d.complete,E=0,w=false,D={then:function(H){return new Promise((function(K){return K(H())}))}};function _(H,K){return H?function(J){++E;var tt=function(){return H(J)};D=D.then(tt,tt).then((function(yt){--E,m&&m.call(d,yt),w&&M.complete();}),(function(yt){throw --E,yt})).catch((function(yt){y&&y.call(d,yt);}));}:function(J){return K&&K.call(d,J)}}var M={next:_(a,m),error:_(l,y),complete:function(){w=true,E||b&&b.call(d);}},B=f.subscribe(M);return function(){return B.unsubscribe()}}))}function Cs(f){return f.errors&&f.errors.length>0||false}function Wf(f,a,l){var d=0;return f.forEach((function(m,y){a.call(this,m,y,f)&&(f[d++]=m);}),l),f.length=d,f}var Kr={kind:"Field",name:{kind:"Name",value:"__typename"}};function wl(f,a){return f.selectionSet.selections.every((function(l){return l.kind==="FragmentSpread"&&wl(a[l.name.value],a)}))}function kd(f){return wl(Kn(f)||(function(a){__DEV__?Vt(a.kind==="Document",'Expecting a parsed GraphQL document. Perhaps you need to wrap the query string in a "gql" tag? http://docs.apollostack.com/apollo-client/core.html#gql'):Vt(a.kind==="Document",50),__DEV__?Vt(a.definitions.length<=1,"Fragment must have exactly one definition."):Vt(a.definitions.length<=1,51);var l=a.definitions[0];return __DEV__?Vt(l.kind==="FragmentDefinition","Must be a fragment definition."):Vt(l.kind==="FragmentDefinition",52),l})(f),So(er(f)))?null:f}function wa(f){return function(a){return f.some((function(l){return l.name&&l.name===a.name.value||l.test&&l.test(a)}))}}function Il(f,a){var l=Object.create(null),d=[],m=Object.create(null),y=[],b=kd(We(a,{Variable:{enter:function(E,w,D){D.kind!=="VariableDefinition"&&(l[E.name.value]=true);}},Field:{enter:function(E){if(f&&E.directives&&f.some((function(w){return w.remove}))&&E.directives&&E.directives.some(wa(f)))return E.arguments&&E.arguments.forEach((function(w){w.value.kind==="Variable"&&d.push({name:w.value.name.value});})),E.selectionSet&&qf(E.selectionSet).forEach((function(w){y.push({name:w.name.value});})),null}},FragmentSpread:{enter:function(E){m[E.name.value]=true;}},Directive:{enter:function(E){if(wa(f)(E))return null}}}));return b&&Wf(d,(function(E){return !!E.name&&!l[E.name]})).length&&(b=(function(E,w){var D=(function(_){return function(M){return _.some((function(B){return M.value&&M.value.kind==="Variable"&&M.value.name&&(B.name===M.value.name.value||B.test&&B.test(M))}))}})(E);return kd(We(w,{OperationDefinition:{enter:function(_){return bt(bt({},_),{variableDefinitions:_.variableDefinitions?_.variableDefinitions.filter((function(M){return !E.some((function(B){return B.name===M.variable.name.value}))})):[]})}},Field:{enter:function(_){if(E.some((function(B){return B.remove}))){var M=0;if(_.arguments&&_.arguments.forEach((function(B){D(B)&&(M+=1);})),M===1)return null}}},Argument:{enter:function(_){if(D(_))return null}}}))})(d,b)),b&&Wf(y,(function(E){return !!E.name&&!m[E.name]})).length&&(b=(function(E,w){function D(_){if(E.some((function(M){return M.name===_.name.value})))return null}return kd(We(w,{FragmentSpread:{enter:D},FragmentDefinition:{enter:D}}))})(y,b)),b}var Ss=Object.assign((function(f){return We(ci(f),{SelectionSet:{enter:function(a,l,d){if(!d||d.kind!=="OperationDefinition"){var m=a.selections;if(m&&!m.some((function(b){return tr(b)&&(b.name.value==="__typename"||b.name.value.lastIndexOf("__",0)===0)}))){var y=d;if(!(tr(y)&&y.directives&&y.directives.some((function(b){return b.name.value==="export"}))))return bt(bt({},a),{selections:lr(lr([],m,true),[Kr],false)})}}}}})}),{added:function(f){return f===Kr}}),an={test:function(f){var a=f.name.value==="connection";return a&&(f.arguments&&f.arguments.some((function(l){return l.name.value==="key"}))||__DEV__&&Vt.warn("Removing an @connection directive even though it does not have a key. You may want to use the key parameter to specify a store key.")),a}};function qf(f){var a=[];return f.selections.forEach((function(l){(tr(l)||Ea(l))&&l.selectionSet?qf(l.selectionSet).forEach((function(d){return a.push(d)})):l.kind==="FragmentSpread"&&a.push(l);})),a}function Yf(f){if(_a(f).operation==="query")return f;var a=We(f,{OperationDefinition:{enter:function(l){return bt(bt({},l),{operation:"query"})}}});return a}function Ia(f,a){var l=f.directives;return !l||!l.length||(function(d){var m=[];return d&&d.length&&d.forEach((function(y){if((function(_){var M=_.name.value;return M==="skip"||M==="include"})(y)){var b=y.arguments,E=y.name.value;__DEV__?Vt(b&&b.length===1,"Incorrect number of arguments for the @"+E+" directive."):Vt(b&&b.length===1,40);var w=b[0];__DEV__?Vt(w.name&&w.name.value==="if","Invalid argument for the @"+E+" directive."):Vt(w.name&&w.name.value==="if",41);var D=w.value;__DEV__?Vt(D&&(D.kind==="Variable"||D.kind==="BooleanValue"),"Argument for the @"+E+" directive must be a variable or a boolean value."):Vt(D&&(D.kind==="Variable"||D.kind==="BooleanValue"),42),m.push({directive:y,ifArgument:w});}})),m})(l).every((function(d){var m=d.directive,y=d.ifArgument,b=false;return y.value.kind==="Variable"?(b=a&&a[y.value.name.value],__DEV__?Vt(b!==void 0,"Invalid variable referenced in @"+m.name.value+" directive."):Vt(b!==void 0,39)):b=y.value.value,m.name.value==="skip"?!b:b}))}function Dd(f,a){return (function(l){var d=[];return We(l,{Directive:function(m){d.push(m.name.value);}}),d})(a).some((function(l){return f.indexOf(l)>-1}))}function Hy(f){return f&&Dd(["client"],f)&&Dd(["export"],f)}var Qf=new Map;function Ps(f){var a=Qf.get(f)||1;return Qf.set(f,a+1),f+":"+a+":"+Math.random().toString(36).slice(2)}function di(f,a,l){var d=[];f.forEach((function(m){return m[a]&&d.push(m)})),d.forEach((function(m){return m[a](l)}));}function kl(f){function a(l){Object.defineProperty(f,l,{value:Je});}return xe&&Symbol.species&&a(Symbol.species),a("@@species"),f}function Ad(f){return f&&typeof f.then=="function"}var un,xs=(function(f){function a(l){var d=f.call(this,(function(m){return d.addObserver(m),function(){return d.removeObserver(m)}}))||this;return d.observers=new Set,d.addCount=0,d.promise=new Promise((function(m,y){d.resolve=m,d.reject=y;})),d.handlers={next:function(m){d.sub!==null&&(d.latest=["next",m],di(d.observers,"next",m));},error:function(m){var y=d.sub;y!==null&&(y&&setTimeout((function(){return y.unsubscribe()})),d.sub=null,d.latest=["error",m],d.reject(m),di(d.observers,"error",m));},complete:function(){if(d.sub!==null){var m=d.sources.shift();m?Ad(m)?m.then((function(y){return d.sub=y.subscribe(d.handlers)})):d.sub=m.subscribe(d.handlers):(d.sub=null,d.latest&&d.latest[0]==="next"?d.resolve(d.latest[1]):d.resolve(),di(d.observers,"complete"));}}},d.cancel=function(m){d.reject(m),d.sources=[],d.handlers.complete();},d.promise.catch((function(m){})),typeof l=="function"&&(l=[new Je(l)]),Ad(l)?l.then((function(m){return d.start(m)}),d.handlers.error):d.start(l),d}return Ve(a,f),a.prototype.start=function(l){this.sub===void 0&&(this.sources=Array.from(l),this.handlers.complete());},a.prototype.deliverLastMessage=function(l){if(this.latest){var d=this.latest[0],m=l[d];m&&m.call(l,this.latest[1]),this.sub===null&&d==="next"&&l.complete&&l.complete();}},a.prototype.addObserver=function(l){this.observers.has(l)||(this.deliverLastMessage(l),this.observers.add(l),++this.addCount);},a.prototype.removeObserver=function(l,d){this.observers.delete(l)&&--this.addCount<1&&!d&&this.handlers.error(new Error("Observable cancelled prematurely"));},a.prototype.cleanup=function(l){var d=this,m=false,y=function(){m||(m=true,d.observers.delete(b),l());},b={next:y,error:y,complete:y},E=this.addCount;this.addObserver(b),this.addCount=E;},a})(Je);function Es(f){return !!f&&f<7}kl(xs),(function(f){f[f.loading=1]="loading",f[f.setVariables=2]="setVariables",f[f.fetchMore=3]="fetchMore",f[f.refetch=4]="refetch",f[f.poll=6]="poll",f[f.ready=7]="ready",f[f.error=8]="error";})(un||(un={}));var Qc=Object.prototype.toString;function Od(f){return ka(f)}function ka(f,a){switch(Qc.call(f)){case "[object Array]":if((a=a||new Map).has(f))return a.get(f);var l=f.slice(0);return a.set(f,l),l.forEach((function(m,y){l[y]=ka(m,a);})),l;case "[object Object]":if((a=a||new Map).has(f))return a.get(f);var d=Object.create(Object.getPrototypeOf(f));return a.set(f,d),Object.keys(f).forEach((function(m){d[m]=ka(f[m],a);})),d;default:return f}}var Da=Object.assign,Kc=Object.hasOwnProperty,Kf=false,Rd=(function(f){function a(l){var d=l.queryManager,m=l.queryInfo,y=l.options,b=f.call(this,(function(w){try{var D=w._subscription._observer;D&&!D.error&&(D.error=Wy);}catch(B){}var _=!b.observers.size;b.observers.add(w);var M=b.last;return M&&M.error?w.error&&w.error(M.error):M&&M.result&&w.next&&w.next(M.result),_&&b.reobserve().catch((function(){})),function(){b.observers.delete(w)&&!b.observers.size&&b.tearDownQuery();}}))||this;b.observers=new Set,b.subscriptions=new Set,b.isTornDown=false,b.options=y,b.queryId=m.queryId||d.generateQueryId();var E=Kn(y.query);return b.queryName=E&&E.name&&E.name.value,b.initialFetchPolicy=y.fetchPolicy||"cache-first",b.queryManager=d,b.queryInfo=m,b}return Ve(a,f),Object.defineProperty(a.prototype,"variables",{get:function(){return this.options.variables},enumerable:false,configurable:true}),a.prototype.result=function(){var l=this;return new Promise((function(d,m){var y={next:function(E){d(E),l.observers.delete(y),l.observers.size||l.queryManager.removeQuery(l.queryId),setTimeout((function(){b.unsubscribe();}),0);},error:m},b=l.subscribe(y);}))},a.prototype.getCurrentResult=function(l){l===void 0&&(l=true);var d=this.getLastResult(true),m=this.queryInfo.networkStatus||d&&d.networkStatus||un.ready,y=bt(bt({},d),{loading:Es(m),networkStatus:m}),b=this.options.fetchPolicy,E=b===void 0?"cache-first":b;if((d||E!=="network-only"&&E!=="no-cache"&&E!=="standby")&&!this.queryManager.transform(this.options.query).hasForcedResolvers){var w=this.queryInfo.getDiff();(w.complete||this.options.returnPartialData)&&(y.data=w.result),Nn(y.data,{})&&(y.data=void 0),w.complete?(y.networkStatus!==un.loading||E!=="cache-first"&&E!=="cache-only"||(y.networkStatus=un.ready,y.loading=false),delete y.partial):E!=="no-cache"&&(y.partial=true),!__DEV__||w.complete||this.options.partialRefetch||y.loading||y.data||y.error||Dl(w.missing);}return l&&this.updateLastResult(y),y},a.prototype.isDifferentFromLastResult=function(l){return !this.last||!Nn(this.last.result,l)},a.prototype.getLast=function(l,d){var m=this.last;if(m&&m[l]&&(!d||Nn(m.variables,this.variables)))return m[l]},a.prototype.getLastResult=function(l){return this.getLast("result",l)},a.prototype.getLastError=function(l){return this.getLast("error",l)},a.prototype.resetLastResults=function(){delete this.last,this.isTornDown=false;},a.prototype.resetQueryStoreErrors=function(){this.queryManager.resetErrors(this.queryId);},a.prototype.refetch=function(l){var d,m={pollInterval:0},y=this.options.fetchPolicy;if(y==="no-cache"?m.fetchPolicy="no-cache":y!=="cache-and-network"&&(m.fetchPolicy="network-only"),__DEV__&&l&&Kc.call(l,"variables")){var b=ys(this.options.query),E=b.variableDefinitions;E&&E.some((function(w){return w.variable.name.value==="variables"}))||__DEV__&&Vt.warn("Called refetch("+JSON.stringify(l)+") for query "+(((d=b.name)===null||d===void 0?void 0:d.value)||JSON.stringify(b))+`, which does not declare a $variables variable.
2351
+ `):new Ce(22)})(E||zr);var H={http:{includeExtensions:w},options:B.fetchOptions,credentials:B.credentials,headers:B.headers};return new Tt((function(K){var J=(function(q,et){return q.getContext().uri||(typeof et=="function"?et(q):et||"/graphql")})(K,b),tt=K.getContext(),yt={};if(tt.clientAwareness){var Rt=tt.clientAwareness,Zt=Rt.name,zt=Rt.version;Zt&&(yt["apollographql-client-name"]=Zt),zt&&(yt["apollographql-client-version"]=zt);}var Bt,qt=bt(bt({},yt),tt.headers),$e={http:tt.http,options:tt.fetchOptions,credentials:tt.credentials,headers:qt},fe=(function(q,et){for(var lt=[],Et=2;Et<arguments.length;Et++)lt[Et-2]=arguments[Et];var wt=bt(bt({},et.options),{headers:et.headers,credentials:et.credentials}),Mt=et.http||{};lt.forEach((function(ie){wt=bt(bt(bt({},wt),ie.options),{headers:bt(bt({},wt.headers),Ed(ie.headers))}),ie.credentials&&(wt.credentials=ie.credentials),Mt=bt(bt({},Mt),ie.http);}));var Yt=q.operationName,Qt=q.extensions,oe=q.variables,Ft=q.query,Ut={operationName:Yt,variables:oe};return Mt.includeExtensions&&(Ut.extensions=Qt),Mt.includeQuery&&(Ut.query=$f(Ft)),{options:wt,body:Ut}})(K,xd,H,$e),Oe=fe.options,An=fe.body;if(An.variables&&!M){var Mr=new Set(Object.keys(An.variables));We(K.query,{Variable:function(q,et,lt){lt&&lt.kind!=="VariableDefinition"&&Mr.delete(q.name.value);}}),Mr.size&&(An.variables=bt({},An.variables),Mr.forEach((function(q){delete An.variables[q];})));}if(!Oe.signal){var u=(function(){if(typeof AbortController=="undefined")return {controller:false,signal:false};var q=new AbortController;return {controller:q,signal:q.signal}})(),g=u.controller,S=u.signal;(Bt=g)&&(Oe.signal=S);}if(D&&!K.query.definitions.some((function(q){return q.kind==="OperationDefinition"&&q.operation==="mutation"}))&&(Oe.method="GET"),Oe.method==="GET"){var k=(function(q,et){var lt=[],Et=function(Ut,ie){lt.push(Ut+"="+encodeURIComponent(ie));};if("query"in et&&Et("query",et.query),et.operationName&&Et("operationName",et.operationName),et.variables){var wt=void 0;try{wt=_l(et.variables,"Variables map");}catch(Ut){return {parseError:Ut}}Et("variables",wt);}if(et.extensions){var Mt=void 0;try{Mt=_l(et.extensions,"Extensions map");}catch(Ut){return {parseError:Ut}}Et("extensions",Mt);}var Yt="",Qt=q,oe=q.indexOf("#");oe!==-1&&(Yt=q.substr(oe),Qt=q.substr(0,oe));var Ft=Qt.indexOf("?")===-1?"?":"&";return {newURI:Qt+Ft+lt.join("&")+Yt}})(J,An),F=k.newURI,$=k.parseError;if($)return _d($);J=F;}else try{Oe.body=_l(An,"Payload");}catch(q){return _d(q)}return new Je((function(q){var et;return (E||it((function(){return fetch}))||zr)(J,Oe).then((function(lt){return K.setContext({response:lt}),lt})).then((et=K,function(lt){return lt.text().then((function(Et){try{return JSON.parse(Et)}catch(Mt){var wt=Mt;throw wt.name="ServerParseError",wt.response=lt,wt.statusCode=lt.status,wt.bodyText=Et,wt}})).then((function(Et){return lt.status>=300&&Uf(lt,Et,"Response not successful: Received status code "+lt.status),Array.isArray(Et)||zc.call(Et,"data")||zc.call(Et,"errors")||Uf(lt,Et,"Server response was missing for query '"+(Array.isArray(et)?et.map((function(wt){return wt.operationName})):et.operationName)+"'."),Et}))})).then((function(lt){return q.next(lt),q.complete(),lt})).catch((function(lt){lt.name!=="AbortError"&&(lt.result&&lt.result.errors&&lt.result.data&&q.next(lt.result),q.error(lt));})),function(){Bt&&Bt.abort();}}))}))})(l).request)||this;return d.options=l,d}return Ve(a,f),a})(Tt),Ta=Tt.execute;function vs(){for(var f=[],a=0;a<arguments.length;a++)f[a]=arguments[a];var l=Object.create(null);return f.forEach((function(d){d&&Object.keys(d).forEach((function(m){var y=d[m];y!==void 0&&(l[m]=y);}));})),l}var Td=Object.prototype,Gf=Td.toString,zy=Td.hasOwnProperty,jf=Function.prototype.toString,wd=new Map;function Nn(f,a){try{return Tl(f,a)}finally{wd.clear();}}function Tl(f,a){if(f===a)return true;var l,d,m,y=Gf.call(f);if(y!==Gf.call(a))return false;switch(y){case "[object Array]":if(f.length!==a.length)return false;case "[object Object]":if(Vf(f,a))return true;var b=Id(f),E=Id(a),w=b.length;if(w!==E.length)return false;for(var D=0;D<w;++D)if(!zy.call(a,b[D]))return false;for(D=0;D<w;++D){var _=b[D];if(!Tl(f[_],a[_]))return false}return true;case "[object Error]":return f.name===a.name&&f.message===a.message;case "[object Number]":if(f!=f)return a!=a;case "[object Boolean]":case "[object Date]":return +f==+a;case "[object RegExp]":case "[object String]":return f==""+a;case "[object Map]":case "[object Set]":if(f.size!==a.size)return false;if(Vf(f,a))return true;for(var M=f.entries(),B=y==="[object Map]";;){var H=M.next();if(H.done)break;var K=H.value,J=K[0],tt=K[1];if(!a.has(J)||B&&!Tl(tt,a.get(J)))return false}return true;case "[object Uint16Array]":case "[object Uint8Array]":case "[object Uint32Array]":case "[object Int32Array]":case "[object Int8Array]":case "[object Int16Array]":case "[object ArrayBuffer]":f=new Uint8Array(f),a=new Uint8Array(a);case "[object DataView]":var yt=f.byteLength;if(yt===a.byteLength)for(;yt--&&f[yt]===a[yt];);return yt===-1;case "[object AsyncFunction]":case "[object GeneratorFunction]":case "[object AsyncGeneratorFunction]":case "[object Function]":var Rt=jf.call(f);return Rt===jf.call(a)&&(d=qc,!((m=(l=Rt).length-d.length)>=0&&l.indexOf(d,m)===m))}return false}function Id(f){return Object.keys(f).filter(Wo,f)}function Wo(f){return this[f]!==void 0}var qc="{ [native code] }";function Vf(f,a){var l=wd.get(f);if(l){if(l.has(a))return true}else wd.set(f,l=new Set);return l.add(a),false}var qo,Qr,zf=function(){return Object.create(null)},Hf=Array.prototype,Yc=Hf.forEach,ht=Hf.slice,At=(function(){function f(a,l){a===void 0&&(a=true),l===void 0&&(l=zf),this.weakness=a,this.makeData=l;}return f.prototype.lookup=function(){for(var a=[],l=0;l<arguments.length;l++)a[l]=arguments[l];return this.lookupArray(a)},f.prototype.lookupArray=function(a){var l=this;return Yc.call(a,(function(d){return l=l.getChildTrie(d)})),l.data||(l.data=this.makeData(ht.call(a)))},f.prototype.getChildTrie=function(a){var l=this.weakness&&(function(m){switch(typeof m){case "object":if(m===null)break;case "function":return true}return false})(a)?this.weak||(this.weak=new WeakMap):this.strong||(this.strong=new Map),d=l.get(a);return d||l.set(a,d=new f(this.weakness,this.makeData)),d},f})(),Dt=typeof WeakMap=="function"&&!(typeof navigator=="object"&&navigator.product==="ReactNative"),Ht=typeof WeakSet=="function",xe=typeof Symbol=="function"&&typeof Symbol.for=="function",Ne=(function(){function f(){this.known=new(Ht?WeakSet:Set),this.pool=new At(Dt),this.passes=new WeakMap,this.keysByJSON=new Map,this.empty=this.admit({});}return f.prototype.isKnown=function(a){return vt(a)&&this.known.has(a)},f.prototype.pass=function(a){if(vt(a)){var l=(function(d){return vt(d)?Array.isArray(d)?d.slice(0):bt({__proto__:Object.getPrototypeOf(d)},d):d})(a);return this.passes.set(l,a),l}return a},f.prototype.admit=function(a){var l=this;if(vt(a)){var d=this.passes.get(a);if(d)return d;switch(Object.getPrototypeOf(a)){case Array.prototype:if(this.known.has(a))return a;var m=a.map(this.admit,this);return (w=this.pool.lookupArray(m)).array||(this.known.add(w.array=m),__DEV__&&Object.freeze(m)),w.array;case null:case Object.prototype:if(this.known.has(a))return a;var y=Object.getPrototypeOf(a),b=[y],E=this.sortedKeys(a);b.push(E.json);var w,D=b.length;if(E.sorted.forEach((function(M){b.push(l.admit(a[M]));})),!(w=this.pool.lookupArray(b)).object){var _=w.object=Object.create(y);this.known.add(_),E.sorted.forEach((function(M,B){_[M]=b[D+B];})),__DEV__&&Object.freeze(_);}return w.object}}return a},f.prototype.sortedKeys=function(a){var l=Object.keys(a),d=this.pool.lookupArray(l);if(!d.keys){l.sort();var m=JSON.stringify(l);(d.keys=this.keysByJSON.get(m))||this.keysByJSON.set(m,d.keys={sorted:l,json:m});}return d.keys},f})(),En=Object.assign((function(f){if(vt(f)){qo===void 0&&Oi();var a=qo.admit(f),l=Qr.get(a);return l===void 0&&Qr.set(a,l=JSON.stringify(a)),l}return JSON.stringify(f)}),{reset:Oi});function Oi(){qo=new Ne,Qr=new(Dt?WeakMap:Map);}function mn(f,a,l){return new Je((function(d){var m=d.next,y=d.error,b=d.complete,E=0,w=false,D={then:function(H){return new Promise((function(K){return K(H())}))}};function _(H,K){return H?function(J){++E;var tt=function(){return H(J)};D=D.then(tt,tt).then((function(yt){--E,m&&m.call(d,yt),w&&M.complete();}),(function(yt){throw --E,yt})).catch((function(yt){y&&y.call(d,yt);}));}:function(J){return K&&K.call(d,J)}}var M={next:_(a,m),error:_(l,y),complete:function(){w=true,E||b&&b.call(d);}},B=f.subscribe(M);return function(){return B.unsubscribe()}}))}function Cs(f){return f.errors&&f.errors.length>0||false}function Wf(f,a,l){var d=0;return f.forEach((function(m,y){a.call(this,m,y,f)&&(f[d++]=m);}),l),f.length=d,f}var Kr={kind:"Field",name:{kind:"Name",value:"__typename"}};function wl(f,a){return f.selectionSet.selections.every((function(l){return l.kind==="FragmentSpread"&&wl(a[l.name.value],a)}))}function kd(f){return wl(Kn(f)||(function(a){__DEV__?Vt(a.kind==="Document",'Expecting a parsed GraphQL document. Perhaps you need to wrap the query string in a "gql" tag? http://docs.apollostack.com/apollo-client/core.html#gql'):Vt(a.kind==="Document",50),__DEV__?Vt(a.definitions.length<=1,"Fragment must have exactly one definition."):Vt(a.definitions.length<=1,51);var l=a.definitions[0];return __DEV__?Vt(l.kind==="FragmentDefinition","Must be a fragment definition."):Vt(l.kind==="FragmentDefinition",52),l})(f),So(er(f)))?null:f}function wa(f){return function(a){return f.some((function(l){return l.name&&l.name===a.name.value||l.test&&l.test(a)}))}}function Il(f,a){var l=Object.create(null),d=[],m=Object.create(null),y=[],b=kd(We(a,{Variable:{enter:function(E,w,D){D.kind!=="VariableDefinition"&&(l[E.name.value]=true);}},Field:{enter:function(E){if(f&&E.directives&&f.some((function(w){return w.remove}))&&E.directives&&E.directives.some(wa(f)))return E.arguments&&E.arguments.forEach((function(w){w.value.kind==="Variable"&&d.push({name:w.value.name.value});})),E.selectionSet&&qf(E.selectionSet).forEach((function(w){y.push({name:w.name.value});})),null}},FragmentSpread:{enter:function(E){m[E.name.value]=true;}},Directive:{enter:function(E){if(wa(f)(E))return null}}}));return b&&Wf(d,(function(E){return !!E.name&&!l[E.name]})).length&&(b=(function(E,w){var D=(function(_){return function(M){return _.some((function(B){return M.value&&M.value.kind==="Variable"&&M.value.name&&(B.name===M.value.name.value||B.test&&B.test(M))}))}})(E);return kd(We(w,{OperationDefinition:{enter:function(_){return bt(bt({},_),{variableDefinitions:_.variableDefinitions?_.variableDefinitions.filter((function(M){return !E.some((function(B){return B.name===M.variable.name.value}))})):[]})}},Field:{enter:function(_){if(E.some((function(B){return B.remove}))){var M=0;if(_.arguments&&_.arguments.forEach((function(B){D(B)&&(M+=1);})),M===1)return null}}},Argument:{enter:function(_){if(D(_))return null}}}))})(d,b)),b&&Wf(y,(function(E){return !!E.name&&!m[E.name]})).length&&(b=(function(E,w){function D(_){if(E.some((function(M){return M.name===_.name.value})))return null}return kd(We(w,{FragmentSpread:{enter:D},FragmentDefinition:{enter:D}}))})(y,b)),b}var Ss=Object.assign((function(f){return We(ci(f),{SelectionSet:{enter:function(a,l,d){if(!d||d.kind!=="OperationDefinition"){var m=a.selections;if(m&&!m.some((function(b){return tr(b)&&(b.name.value==="__typename"||b.name.value.lastIndexOf("__",0)===0)}))){var y=d;if(!(tr(y)&&y.directives&&y.directives.some((function(b){return b.name.value==="export"}))))return bt(bt({},a),{selections:lr(lr([],m,true),[Kr],false)})}}}}})}),{added:function(f){return f===Kr}}),an={test:function(f){var a=f.name.value==="connection";return a&&(f.arguments&&f.arguments.some((function(l){return l.name.value==="key"}))||__DEV__&&Vt.warn("Removing an @connection directive even though it does not have a key. You may want to use the key parameter to specify a store key.")),a}};function qf(f){var a=[];return f.selections.forEach((function(l){(tr(l)||Ea(l))&&l.selectionSet?qf(l.selectionSet).forEach((function(d){return a.push(d)})):l.kind==="FragmentSpread"&&a.push(l);})),a}function Yf(f){if(_a(f).operation==="query")return f;var a=We(f,{OperationDefinition:{enter:function(l){return bt(bt({},l),{operation:"query"})}}});return a}function Ia(f,a){var l=f.directives;return !l||!l.length||(function(d){var m=[];return d&&d.length&&d.forEach((function(y){if((function(_){var M=_.name.value;return M==="skip"||M==="include"})(y)){var b=y.arguments,E=y.name.value;__DEV__?Vt(b&&b.length===1,"Incorrect number of arguments for the @"+E+" directive."):Vt(b&&b.length===1,40);var w=b[0];__DEV__?Vt(w.name&&w.name.value==="if","Invalid argument for the @"+E+" directive."):Vt(w.name&&w.name.value==="if",41);var D=w.value;__DEV__?Vt(D&&(D.kind==="Variable"||D.kind==="BooleanValue"),"Argument for the @"+E+" directive must be a variable or a boolean value."):Vt(D&&(D.kind==="Variable"||D.kind==="BooleanValue"),42),m.push({directive:y,ifArgument:w});}})),m})(l).every((function(d){var m=d.directive,y=d.ifArgument,b=false;return y.value.kind==="Variable"?(b=a&&a[y.value.name.value],__DEV__?Vt(b!==void 0,"Invalid variable referenced in @"+m.name.value+" directive."):Vt(b!==void 0,39)):b=y.value.value,m.name.value==="skip"?!b:b}))}function Dd(f,a){return (function(l){var d=[];return We(l,{Directive:function(m){d.push(m.name.value);}}),d})(a).some((function(l){return f.indexOf(l)>-1}))}function Hy(f){return f&&Dd(["client"],f)&&Dd(["export"],f)}var Qf=new Map;function Ps(f){var a=Qf.get(f)||1;return Qf.set(f,a+1),f+":"+a+":"+Math.random().toString(36).slice(2)}function di(f,a,l){var d=[];f.forEach((function(m){return m[a]&&d.push(m)})),d.forEach((function(m){return m[a](l)}));}function kl(f){function a(l){Object.defineProperty(f,l,{value:Je});}return xe&&Symbol.species&&a(Symbol.species),a("@@species"),f}function Ad(f){return f&&typeof f.then=="function"}var un,xs=(function(f){function a(l){var d=f.call(this,(function(m){return d.addObserver(m),function(){return d.removeObserver(m)}}))||this;return d.observers=new Set,d.addCount=0,d.promise=new Promise((function(m,y){d.resolve=m,d.reject=y;})),d.handlers={next:function(m){d.sub!==null&&(d.latest=["next",m],di(d.observers,"next",m));},error:function(m){var y=d.sub;y!==null&&(y&&setTimeout((function(){return y.unsubscribe()})),d.sub=null,d.latest=["error",m],d.reject(m),di(d.observers,"error",m));},complete:function(){if(d.sub!==null){var m=d.sources.shift();m?Ad(m)?m.then((function(y){return d.sub=y.subscribe(d.handlers)})):d.sub=m.subscribe(d.handlers):(d.sub=null,d.latest&&d.latest[0]==="next"?d.resolve(d.latest[1]):d.resolve(),di(d.observers,"complete"));}}},d.cancel=function(m){d.reject(m),d.sources=[],d.handlers.complete();},d.promise.catch((function(m){})),typeof l=="function"&&(l=[new Je(l)]),Ad(l)?l.then((function(m){return d.start(m)}),d.handlers.error):d.start(l),d}return Ve(a,f),a.prototype.start=function(l){this.sub===void 0&&(this.sources=Array.from(l),this.handlers.complete());},a.prototype.deliverLastMessage=function(l){if(this.latest){var d=this.latest[0],m=l[d];m&&m.call(l,this.latest[1]),this.sub===null&&d==="next"&&l.complete&&l.complete();}},a.prototype.addObserver=function(l){this.observers.has(l)||(this.deliverLastMessage(l),this.observers.add(l),++this.addCount);},a.prototype.removeObserver=function(l,d){this.observers.delete(l)&&--this.addCount<1&&!d&&this.handlers.error(new Error("Observable cancelled prematurely"));},a.prototype.cleanup=function(l){var d=this,m=false,y=function(){m||(m=true,d.observers.delete(b),l());},b={next:y,error:y,complete:y},E=this.addCount;this.addObserver(b),this.addCount=E;},a})(Je);function Es(f){return !!f&&f<7}kl(xs),(function(f){f[f.loading=1]="loading",f[f.setVariables=2]="setVariables",f[f.fetchMore=3]="fetchMore",f[f.refetch=4]="refetch",f[f.poll=6]="poll",f[f.ready=7]="ready",f[f.error=8]="error";})(un||(un={}));var Qc=Object.prototype.toString;function Od(f){return ka(f)}function ka(f,a){switch(Qc.call(f)){case "[object Array]":if((a=a||new Map).has(f))return a.get(f);var l=f.slice(0);return a.set(f,l),l.forEach((function(m,y){l[y]=ka(m,a);})),l;case "[object Object]":if((a=a||new Map).has(f))return a.get(f);var d=Object.create(Object.getPrototypeOf(f));return a.set(f,d),Object.keys(f).forEach((function(m){d[m]=ka(f[m],a);})),d;default:return f}}var Da=Object.assign,Kc=Object.hasOwnProperty,Kf=false,Rd=(function(f){function a(l){var d=l.queryManager,m=l.queryInfo,y=l.options,b=f.call(this,(function(w){try{var D=w._subscription._observer;D&&!D.error&&(D.error=Wy);}catch(B){}var _=!b.observers.size;b.observers.add(w);var M=b.last;return M&&M.error?w.error&&w.error(M.error):M&&M.result&&w.next&&w.next(M.result),_&&b.reobserve().catch((function(){})),function(){b.observers.delete(w)&&!b.observers.size&&b.tearDownQuery();}}))||this;b.observers=new Set,b.subscriptions=new Set,b.isTornDown=false,b.options=y,b.queryId=m.queryId||d.generateQueryId();var E=Kn(y.query);return b.queryName=E&&E.name&&E.name.value,b.initialFetchPolicy=y.fetchPolicy||"cache-first",b.queryManager=d,b.queryInfo=m,b}return Ve(a,f),Object.defineProperty(a.prototype,"variables",{get:function(){return this.options.variables},enumerable:false,configurable:true}),a.prototype.result=function(){var l=this;return new Promise((function(d,m){var y={next:function(E){d(E),l.observers.delete(y),l.observers.size||l.queryManager.removeQuery(l.queryId),setTimeout((function(){b.unsubscribe();}),0);},error:m},b=l.subscribe(y);}))},a.prototype.getCurrentResult=function(l){l===void 0&&(l=true);var d=this.getLastResult(true),m=this.queryInfo.networkStatus||d&&d.networkStatus||un.ready,y=bt(bt({},d),{loading:Es(m),networkStatus:m}),b=this.options.fetchPolicy,E=b===void 0?"cache-first":b;if((d||E!=="network-only"&&E!=="no-cache"&&E!=="standby")&&!this.queryManager.transform(this.options.query).hasForcedResolvers){var w=this.queryInfo.getDiff();(w.complete||this.options.returnPartialData)&&(y.data=w.result),Nn(y.data,{})&&(y.data=void 0),w.complete?(y.networkStatus!==un.loading||E!=="cache-first"&&E!=="cache-only"||(y.networkStatus=un.ready,y.loading=false),delete y.partial):E!=="no-cache"&&(y.partial=true),!__DEV__||w.complete||this.options.partialRefetch||y.loading||y.data||y.error||Dl(w.missing);}return l&&this.updateLastResult(y),y},a.prototype.isDifferentFromLastResult=function(l){return !this.last||!Nn(this.last.result,l)},a.prototype.getLast=function(l,d){var m=this.last;if(m&&m[l]&&(!d||Nn(m.variables,this.variables)))return m[l]},a.prototype.getLastResult=function(l){return this.getLast("result",l)},a.prototype.getLastError=function(l){return this.getLast("error",l)},a.prototype.resetLastResults=function(){delete this.last,this.isTornDown=false;},a.prototype.resetQueryStoreErrors=function(){this.queryManager.resetErrors(this.queryId);},a.prototype.refetch=function(l){var d,m={pollInterval:0},y=this.options.fetchPolicy;if(y==="no-cache"?m.fetchPolicy="no-cache":y!=="cache-and-network"&&(m.fetchPolicy="network-only"),__DEV__&&l&&Kc.call(l,"variables")){var b=ys(this.options.query),E=b.variableDefinitions;E&&E.some((function(w){return w.variable.name.value==="variables"}))||__DEV__&&Vt.warn("Called refetch("+JSON.stringify(l)+") for query "+(((d=b.name)===null||d===void 0?void 0:d.value)||JSON.stringify(b))+`, which does not declare a $variables variable.
2352
2352
  Did you mean to call refetch(variables) instead of refetch({ variables })?`);}return l&&!Nn(this.options.variables,l)&&(m.variables=this.options.variables=bt(bt({},this.options.variables),l)),this.queryInfo.resetLastWrite(),this.reobserve(m,un.refetch)},a.prototype.fetchMore=function(l){var d=this,m=bt(bt({},l.query?l:bt(bt(bt({},this.options),l),{variables:bt(bt({},this.options.variables),l.variables)})),{fetchPolicy:"no-cache"}),y=this.queryManager.generateQueryId();return m.notifyOnNetworkStatusChange&&(this.queryInfo.networkStatus=un.fetchMore,this.observe()),this.queryManager.fetchQuery(y,m,un.fetchMore).then((function(b){var E=b.data,w=l.updateQuery;return w?(__DEV__&&!Kf&&(__DEV__&&Vt.warn(`The updateQuery callback for fetchMore is deprecated, and will be removed
2353
2353
  in the next major version of Apollo Client.
2354
2354
 
@@ -2360,9 +2360,9 @@ concatPagination, offsetLimitPagination, or relayStylePagination) from
2360
2360
  The field policy system handles pagination more effectively than a
2361
2361
  hand-written updateQuery function, and you only need to define the policy
2362
2362
  once, rather than every time you call fetchMore.`),Kf=true),d.updateQuery((function(D){return w(D,{fetchMoreResult:E,variables:m.variables})}))):d.queryManager.cache.writeQuery({query:m.query,variables:m.variables,data:E}),b})).finally((function(){d.queryManager.stopQuery(y),d.reobserve();}))},a.prototype.subscribeToMore=function(l){var d=this,m=this.queryManager.startGraphQLSubscription({query:l.document,variables:l.variables,context:l.context}).subscribe({next:function(y){var b=l.updateQuery;b&&d.updateQuery((function(E,w){var D=w.variables;return b(E,{subscriptionData:y,variables:D})}));},error:function(y){l.onError?l.onError(y):__DEV__&&Vt.error("Unhandled GraphQL subscription error",y);}});return this.subscriptions.add(m),function(){d.subscriptions.delete(m)&&m.unsubscribe();}},a.prototype.setOptions=function(l){return this.reobserve(l)},a.prototype.setVariables=function(l){return Nn(this.variables,l)?this.observers.size?this.result():Promise.resolve():(this.options.variables=l,this.observers.size?this.reobserve({fetchPolicy:this.initialFetchPolicy,variables:l},un.setVariables):Promise.resolve())},a.prototype.updateQuery=function(l){var d=this.queryManager,m=l(d.cache.diff({query:this.options.query,variables:this.variables,returnPartialData:true,optimistic:false}).result,{variables:this.variables});m&&(d.cache.writeQuery({query:this.options.query,data:m,variables:this.variables}),d.broadcastQueries());},a.prototype.startPolling=function(l){this.options.pollInterval=l,this.updatePolling();},a.prototype.stopPolling=function(){this.options.pollInterval=0,this.updatePolling();},a.prototype.fetch=function(l,d){return this.queryManager.setObservableQuery(this),this.queryManager.fetchQueryObservable(this.queryId,l,d)},a.prototype.updatePolling=function(){var l=this;if(!this.queryManager.ssrMode){var d=this.pollingInfo,m=this.options.pollInterval;if(m){if(!d||d.interval!==m){__DEV__?Vt(m,"Attempted to start a polling query without a polling interval."):Vt(m,12),(d||(this.pollingInfo={})).interval=m;var y=function(){l.pollingInfo&&(Es(l.queryInfo.networkStatus)?b():l.reobserve({fetchPolicy:"network-only"},un.poll).then(b,b));},b=function(){var E=l.pollingInfo;E&&(clearTimeout(E.timeout),E.timeout=setTimeout(y,E.interval));};b();}}else d&&(clearTimeout(d.timeout),delete this.pollingInfo);}},a.prototype.updateLastResult=function(l,d){return d===void 0&&(d=this.variables),this.last=bt(bt({},this.last),{result:this.queryManager.assumeImmutableResults?l:Od(l),variables:d}),kn(l.errors)||delete this.last.error,this.last},a.prototype.reobserve=function(l,d){var m=this;this.isTornDown=false;var y=d===un.refetch||d===un.fetchMore||d===un.poll,b=this.options.variables,E=y?vs(this.options,l):Da(this.options,vs(l));y||(this.updatePolling(),l&&l.variables&&!l.fetchPolicy&&!Nn(l.variables,b)&&(E.fetchPolicy=this.initialFetchPolicy,d===void 0&&(d=un.setVariables)));var w=E.variables&&bt({},E.variables),D=this.fetch(E,d),_={next:function(M){m.reportResult(M,w);},error:function(M){m.reportError(M,w);}};return y||(this.concast&&this.observer&&this.concast.removeObserver(this.observer,true),this.concast=D,this.observer=_),D.addObserver(_),D.promise},a.prototype.observe=function(){this.reportResult(this.getCurrentResult(false),this.variables);},a.prototype.reportResult=function(l,d){(this.getLastError()||this.isDifferentFromLastResult(l))&&(this.updateLastResult(l,d),di(this.observers,"next",l));},a.prototype.reportError=function(l,d){var m=bt(bt({},this.getLastResult()),{error:l,errors:l.graphQLErrors,networkStatus:un.error,loading:false});this.updateLastResult(m,d),di(this.observers,"error",this.last.error=l);},a.prototype.hasObservers=function(){return this.observers.size>0},a.prototype.tearDownQuery=function(){this.isTornDown||(this.concast&&this.observer&&(this.concast.removeObserver(this.observer),delete this.concast,delete this.observer),this.stopPolling(),this.subscriptions.forEach((function(l){return l.unsubscribe()})),this.subscriptions.clear(),this.queryManager.stopQuery(this.queryId),this.observers.clear(),this.isTornDown=true);},a})(Je);function Wy(f){__DEV__&&Vt.error("Unhandled error",f.message,f.stack);}function Dl(f){__DEV__&&kn(f)&&__DEV__&&Vt.debug("Missing cache result fields: "+f.map((function(a){return a.path.join(".")})).join(", "),f);}kl(Rd);var Xc=Object.prototype.hasOwnProperty;function Zc(){for(var f=[],a=0;a<arguments.length;a++)f[a]=arguments[a];return Fd(f)}function Fd(f){var a=f[0]||{},l=f.length;if(l>1)for(var d=new Md,m=1;m<l;++m)a=d.merge(a,f[m]);return a}var Xf=function(f,a,l){return this.merge(f[l],a[l])},Md=(function(){function f(a){a===void 0&&(a=Xf),this.reconciler=a,this.isObject=vt,this.pastCopies=new Set;}return f.prototype.merge=function(a,l){for(var d=this,m=[],y=2;y<arguments.length;y++)m[y-2]=arguments[y];return vt(l)&&vt(a)?(Object.keys(l).forEach((function(b){if(Xc.call(a,b)){var E=a[b];if(l[b]!==E){var w=d.reconciler.apply(d,lr([a,l,b],m,false));w!==E&&((a=d.shallowCopyForMerge(a))[b]=w);}}else (a=d.shallowCopyForMerge(a))[b]=l[b];})),a):l},f.prototype.shallowCopyForMerge=function(a){return vt(a)&&!this.pastCopies.has(a)&&(a=Array.isArray(a)?a.slice(0):bt({__proto__:Object.getPrototypeOf(a)},a),this.pastCopies.add(a)),a},f})(),Sr=null,Xn={},Ar=1,Nd="@wry/context:Slot",Ld=Array,Al=Ld[Nd]||(function(){var f=(function(){function a(){this.id=["slot",Ar++,Date.now(),Math.random().toString(36).slice(2)].join(":");}return a.prototype.hasValue=function(){for(var l=Sr;l;l=l.parent)if(this.id in l.slots){var d=l.slots[this.id];if(d===Xn)break;return l!==Sr&&(Sr.slots[this.id]=d),true}return Sr&&(Sr.slots[this.id]=Xn),false},a.prototype.getValue=function(){if(this.hasValue())return Sr.slots[this.id]},a.prototype.withValue=function(l,d,m,y){var b,E=((b={__proto__:null})[this.id]=l,b),w=Sr;Sr={parent:w,slots:E};try{return d.apply(y,m)}finally{Sr=w;}},a.bind=function(l){var d=Sr;return function(){var m=Sr;try{return Sr=d,l.apply(this,arguments)}finally{Sr=m;}}},a.noContext=function(l,d,m){if(!Sr)return l.apply(m,d);var y=Sr;try{return Sr=null,l.apply(m,d)}finally{Sr=y;}},a})();try{Object.defineProperty(Ld,Nd,{value:Ld[Nd]=f,enumerable:!1,writable:!1,configurable:!1});}finally{return f}})();function qy(){}Al.bind,Al.noContext;var Jc,Ol=(function(){function f(a,l){a===void 0&&(a=1/0),l===void 0&&(l=qy),this.max=a,this.dispose=l,this.map=new Map,this.newest=null,this.oldest=null;}return f.prototype.has=function(a){return this.map.has(a)},f.prototype.get=function(a){var l=this.getNode(a);return l&&l.value},f.prototype.getNode=function(a){var l=this.map.get(a);if(l&&l!==this.newest){var d=l.older,m=l.newer;m&&(m.older=d),d&&(d.newer=m),l.older=this.newest,l.older.newer=l,l.newer=null,this.newest=l,l===this.oldest&&(this.oldest=m);}return l},f.prototype.set=function(a,l){var d=this.getNode(a);return d?d.value=l:(d={key:a,value:l,newer:null,older:this.newest},this.newest&&(this.newest.newer=d),this.newest=d,this.oldest=this.oldest||d,this.map.set(a,d),d.value)},f.prototype.clean=function(){for(;this.oldest&&this.map.size>this.max;)this.delete(this.oldest.key);},f.prototype.delete=function(a){var l=this.map.get(a);return !!l&&(l===this.newest&&(this.newest=l.older),l===this.oldest&&(this.oldest=l.newer),l.newer&&(l.newer.older=l.older),l.older&&(l.older.newer=l.newer),this.map.delete(a),this.dispose(l.value,a),true)},f})(),_s=new Al,Ts=Object.prototype.hasOwnProperty,Aa=(Jc=Array.from)===void 0?function(f){var a=[];return f.forEach((function(l){return a.push(l)})),a}:Jc;function Yo(f){var a=f.unsubscribe;typeof a=="function"&&(f.unsubscribe=void 0,a());}var Qo=[];function Ri(f,a){if(!f)throw new Error(a||"assertion failure")}function Zf(f){switch(f.length){case 0:throw new Error("unknown value");case 1:return f[0];case 2:throw f[1]}}var Yy=(function(){function f(a){this.fn=a,this.parents=new Set,this.childValues=new Map,this.dirtyChildren=null,this.dirty=true,this.recomputing=false,this.value=[],this.deps=null,++f.count;}return f.prototype.peek=function(){if(this.value.length===1&&!Ko(this))return Jf(this),this.value[0]},f.prototype.recompute=function(a){return Ri(!this.recomputing,"already recomputing"),Jf(this),Ko(this)?(function(l,d){return Xr(l),_s.withValue(l,Qy,[l,d]),(function(m,y){if(typeof m.subscribe=="function")try{Yo(m),m.unsubscribe=m.subscribe.apply(null,y);}catch(b){return m.setDirty(),false}return true})(l,d)&&(function(m){m.dirty=false,Ko(m)||ws(m);})(l),Zf(l.value)})(this,a):Zf(this.value)},f.prototype.setDirty=function(){this.dirty||(this.dirty=true,this.value.length=0,Rl(this),Yo(this));},f.prototype.dispose=function(){var a=this;this.setDirty(),Xr(this),tu(this,(function(l,d){l.setDirty(),Re(l,a);}));},f.prototype.forget=function(){this.dispose();},f.prototype.dependOn=function(a){a.add(this),this.deps||(this.deps=Qo.pop()||new Set),this.deps.add(a);},f.prototype.forgetDeps=function(){var a=this;this.deps&&(Aa(this.deps).forEach((function(l){return l.delete(a)})),this.deps.clear(),Qo.push(this.deps),this.deps=null);},f.count=0,f})();function Jf(f){var a=_s.getValue();if(a)return f.parents.add(a),a.childValues.has(f)||a.childValues.set(f,[]),Ko(f)?L(a,f):Oa(a,f),a}function Qy(f,a){f.recomputing=true,f.value.length=0;try{f.value[0]=f.fn.apply(null,a);}catch(l){f.value[1]=l;}f.recomputing=false;}function Ko(f){return f.dirty||!(!f.dirtyChildren||!f.dirtyChildren.size)}function Rl(f){tu(f,L);}function ws(f){tu(f,Oa);}function tu(f,a){var l=f.parents.size;if(l)for(var d=Aa(f.parents),m=0;m<l;++m)a(d[m],f);}function L(f,a){Ri(f.childValues.has(a)),Ri(Ko(a));var l=!Ko(f);if(f.dirtyChildren){if(f.dirtyChildren.has(a))return}else f.dirtyChildren=Qo.pop()||new Set;f.dirtyChildren.add(a),l&&Rl(f);}function Oa(f,a){Ri(f.childValues.has(a)),Ri(!Ko(a));var l,d,m,y=f.childValues.get(a);y.length===0?f.childValues.set(a,a.value.slice(0)):(l=y,d=a.value,(m=l.length)>0&&m===d.length&&l[m-1]===d[m-1]||f.setDirty()),Fl(f,a),Ko(f)||ws(f);}function Fl(f,a){var l=f.dirtyChildren;l&&(l.delete(a),l.size===0&&(Qo.length<100&&Qo.push(l),f.dirtyChildren=null));}function Xr(f){f.childValues.size>0&&f.childValues.forEach((function(a,l){Re(f,l);})),f.forgetDeps(),Ri(f.dirtyChildren===null);}function Re(f,a){a.parents.delete(f),f.childValues.delete(a),Fl(f,a);}var Ra={setDirty:true,dispose:true,forget:true};function Qi(f){var a=new Map;function d(m){var y=_s.getValue();if(y){var b=a.get(m);b||a.set(m,b=new Set),y.dependOn(b);}}return d.dirty=function(m,y){var b=a.get(m);if(b){var E=y&&Ts.call(Ra,y)?y:"setDirty";Aa(b).forEach((function(w){return w[E]()})),a.delete(m),Yo(b);}},d}function Ki(){var f=new At(typeof WeakMap=="function");return function(){return f.lookupArray(arguments)}}Ki();var Po=new Set;function Hr(f,a){a===void 0&&(a=Object.create(null));var l=new Ol(a.max||Math.pow(2,16),(function(D){return D.dispose()})),d=a.keyArgs,m=a.makeCacheKey||Ki(),y=function(){var D=m.apply(null,d?d.apply(null,arguments):arguments);if(D===void 0)return f.apply(null,arguments);var _=l.get(D);_||(l.set(D,_=new Yy(f)),_.subscribe=a.subscribe,_.forget=function(){return l.delete(D)});var M=_.recompute(Array.prototype.slice.call(arguments));return l.set(D,_),Po.add(l),_s.hasValue()||(Po.forEach((function(B){return B.clean()})),Po.clear()),M};function b(D){var _=l.get(D);_&&_.setDirty();}function E(D){var _=l.get(D);if(_)return _.peek()}function w(D){return l.delete(D)}return Object.defineProperty(y,"size",{get:function(){return l.map.size},configurable:false,enumerable:false}),y.dirtyKey=b,y.dirty=function(){b(m.apply(null,arguments));},y.peekKey=E,y.peek=function(){return E(m.apply(null,arguments))},y.forgetKey=w,y.forget=function(){return w(m.apply(null,arguments))},y.makeCacheKey=m,y.getKey=d?function(){return m.apply(null,d.apply(null,arguments))}:m,Object.freeze(y)}var eu=new Al,Bd=new WeakMap;function Ml(f){var a=Bd.get(f);return a||Bd.set(f,a={vars:new Set,dep:Qi()}),a}function th(f){Ml(f).vars.forEach((function(a){return a.forgetCache(f)}));}function Ud(f){var a=new Set,l=new Set,d=function(y){if(arguments.length>0){if(f!==y){f=y,a.forEach((function(w){Ml(w).dep.dirty(d),Nl(w);}));var b=Array.from(l);l.clear(),b.forEach((function(w){return w(f)}));}}else {var E=eu.getValue();E&&(m(E),Ml(E).dep(d));}return f};d.onNextChange=function(y){return l.add(y),function(){l.delete(y);}};var m=d.attachCache=function(y){return a.add(y),Ml(y).vars.add(d),d};return d.forgetCache=function(y){return a.delete(y)},d}function Nl(f){f.broadcastWatches&&f.broadcastWatches();}var Ll=(function(){function f(a){var l=a.cache,d=a.client,m=a.resolvers,y=a.fragmentMatcher;this.cache=l,d&&(this.client=d),m&&this.addResolvers(m),y&&this.setFragmentMatcher(y);}return f.prototype.addResolvers=function(a){var l=this;this.resolvers=this.resolvers||{},Array.isArray(a)?a.forEach((function(d){l.resolvers=Zc(l.resolvers,d);})):this.resolvers=Zc(this.resolvers,a);},f.prototype.setResolvers=function(a){this.resolvers={},this.addResolvers(a);},f.prototype.getResolvers=function(){return this.resolvers||{}},f.prototype.runResolvers=function(a){var l=a.document,d=a.remoteResult,m=a.context,y=a.variables,b=a.onlyRunForcedResolvers,E=b!==void 0&&b;return sr(this,void 0,void 0,(function(){return Jn(this,(function(w){return l?[2,this.resolveDocument(l,d.data,m,y,this.fragmentMatcher,E).then((function(D){return bt(bt({},d),{data:D.result})}))]:[2,d]}))}))},f.prototype.setFragmentMatcher=function(a){this.fragmentMatcher=a;},f.prototype.getFragmentMatcher=function(){return this.fragmentMatcher},f.prototype.clientQuery=function(a){return Dd(["client"],a)&&this.resolvers?a:null},f.prototype.serverQuery=function(a){return (function(l){ci(l);var d=Il([{test:function(m){return m.name.value==="client"},remove:true}],l);return d&&(d=We(d,{FragmentDefinition:{enter:function(m){if(m.selectionSet&&m.selectionSet.selections.every((function(y){return tr(y)&&y.name.value==="__typename"})))return null}}})),d})(a)},f.prototype.prepareContext=function(a){var l=this.cache;return bt(bt({},a),{cache:l,getCacheKey:function(d){return l.identify(d)}})},f.prototype.addExportedVariables=function(a,l,d){return l===void 0&&(l={}),d===void 0&&(d={}),sr(this,void 0,void 0,(function(){return Jn(this,(function(m){return a?[2,this.resolveDocument(a,this.buildRootValueFromCache(a,l)||{},this.prepareContext(d),l).then((function(y){return bt(bt({},l),y.exportedVariables)}))]:[2,bt({},l)]}))}))},f.prototype.shouldForceResolvers=function(a){var l=false;return We(a,{Directive:{enter:function(d){if(d.name.value==="client"&&d.arguments&&(l=d.arguments.some((function(m){return m.name.value==="always"&&m.value.kind==="BooleanValue"&&m.value.value===true}))))return Vc}}}),l},f.prototype.buildRootValueFromCache=function(a,l){return this.cache.diff({query:Yf(a),variables:l,returnPartialData:true,optimistic:false}).result},f.prototype.resolveDocument=function(a,l,d,m,y,b){return d===void 0&&(d={}),m===void 0&&(m={}),y===void 0&&(y=function(){return true}),b===void 0&&(b=false),sr(this,void 0,void 0,(function(){var E,w,D,_,M,B,H,K,J;return Jn(this,(function(tt){return E=_a(a),w=er(a),D=So(w),_=E.operation,M=_?_.charAt(0).toUpperCase()+_.slice(1):"Query",H=(B=this).cache,K=B.client,J={fragmentMap:D,context:bt(bt({},d),{cache:H,client:K}),variables:m,fragmentMatcher:y,defaultOperationType:M,exportedVariables:{},onlyRunForcedResolvers:b},[2,this.resolveSelectionSet(E.selectionSet,l,J).then((function(yt){return {result:yt,exportedVariables:J.exportedVariables}}))]}))}))},f.prototype.resolveSelectionSet=function(a,l,d){return sr(this,void 0,void 0,(function(){var m,y,b,E,w,D=this;return Jn(this,(function(_){return m=d.fragmentMap,y=d.context,b=d.variables,E=[l],w=function(M){return sr(D,void 0,void 0,(function(){var B,H;return Jn(this,(function(K){return Ia(M,b)?tr(M)?[2,this.resolveField(M,l,d).then((function(J){var tt;J!==void 0&&E.push(((tt={})[on(M)]=J,tt));}))]:(Ea(M)?B=M:(B=m[M.name.value],__DEV__?Vt(B,"No fragment named "+M.name.value):Vt(B,11)),B&&B.typeCondition&&(H=B.typeCondition.name.value,d.fragmentMatcher(l,H,y))?[2,this.resolveSelectionSet(B.selectionSet,l,d).then((function(J){E.push(J);}))]:[2]):[2]}))}))},[2,Promise.all(a.selections.map(w)).then((function(){return Fd(E)}))]}))}))},f.prototype.resolveField=function(a,l,d){return sr(this,void 0,void 0,(function(){var m,y,b,E,w,D,_,M,B,H=this;return Jn(this,(function(K){return m=d.variables,y=a.name.value,b=on(a),E=y!==b,w=l[b]||l[y],D=Promise.resolve(w),d.onlyRunForcedResolvers&&!this.shouldForceResolvers(a)||(_=l.__typename||d.defaultOperationType,(M=this.resolvers&&this.resolvers[_])&&(B=M[E?y:b])&&(D=Promise.resolve(eu.withValue(this.cache,B,[l,El(a,m),d.context,{field:a,fragmentMap:d.fragmentMap}])))),[2,D.then((function(J){return J===void 0&&(J=w),a.directives&&a.directives.forEach((function(tt){tt.name.value==="export"&&tt.arguments&&tt.arguments.forEach((function(yt){yt.name.value==="as"&&yt.value.kind==="StringValue"&&(d.exportedVariables[yt.value.value]=J);}));})),a.selectionSet?J==null?J:Array.isArray(J)?H.resolveSubSelectedArray(a,J,d):a.selectionSet?H.resolveSelectionSet(a.selectionSet,J,d):void 0:J}))]}))}))},f.prototype.resolveSubSelectedArray=function(a,l,d){var m=this;return Promise.all(l.map((function(y){return y===null?null:Array.isArray(y)?m.resolveSubSelectedArray(a,y,d):a.selectionSet?m.resolveSelectionSet(a.selectionSet,y,d):void 0})))},f})(),Is=new(Dt?WeakMap:Map);function nu(f,a){var l=f[a];typeof l=="function"&&(f[a]=function(){return Is.set(f,(Is.get(f)+1)%1e15),l.apply(this,arguments)});}function Xi(f){f.notifyTimeout&&(clearTimeout(f.notifyTimeout),f.notifyTimeout=void 0);}var Bl=(function(){function f(a,l){l===void 0&&(l=a.generateQueryId()),this.queryId=l,this.listeners=new Set,this.document=null,this.lastRequestId=1,this.subscriptions=new Set,this.stopped=false,this.dirty=false,this.observableQuery=null;var d=this.cache=a.cache;Is.has(d)||(Is.set(d,0),nu(d,"evict"),nu(d,"modify"),nu(d,"reset"));}return f.prototype.init=function(a){var l=a.networkStatus||un.loading;return this.variables&&this.networkStatus!==un.loading&&!Nn(this.variables,a.variables)&&(l=un.setVariables),Nn(a.variables,this.variables)||(this.lastDiff=void 0),Object.assign(this,{document:a.document,variables:a.variables,networkError:null,graphQLErrors:this.graphQLErrors||[],networkStatus:l}),a.observableQuery&&this.setObservableQuery(a.observableQuery),a.lastRequestId&&(this.lastRequestId=a.lastRequestId),this},f.prototype.reset=function(){Xi(this),this.lastDiff=void 0,this.dirty=false;},f.prototype.getDiff=function(a){a===void 0&&(a=this.variables);var l=this.getDiffOptions(a);if(this.lastDiff&&Nn(l,this.lastDiff.options))return this.lastDiff.diff;this.updateWatch(this.variables=a);var d=this.observableQuery;if(d&&d.options.fetchPolicy==="no-cache")return {complete:false};var m=this.cache.diff(l);return this.updateLastDiff(m,l),m},f.prototype.updateLastDiff=function(a,l){this.lastDiff=a?{diff:a,options:l||this.getDiffOptions()}:void 0;},f.prototype.getDiffOptions=function(a){var l;return a===void 0&&(a=this.variables),{query:this.document,variables:a,returnPartialData:true,optimistic:true,canonizeResults:(l=this.observableQuery)===null||l===void 0?void 0:l.options.canonizeResults}},f.prototype.setDiff=function(a){var l=this,d=this.lastDiff&&this.lastDiff.diff;this.updateLastDiff(a),this.dirty||Nn(d&&d.result,a&&a.result)||(this.dirty=true,this.notifyTimeout||(this.notifyTimeout=setTimeout((function(){return l.notify()}),0)));},f.prototype.setObservableQuery=function(a){var l=this;a!==this.observableQuery&&(this.oqListener&&this.listeners.delete(this.oqListener),this.observableQuery=a,a?(a.queryInfo=this,this.listeners.add(this.oqListener=function(){l.getDiff().fromOptimisticTransaction?a.observe():a.reobserve();})):delete this.oqListener);},f.prototype.notify=function(){var a=this;Xi(this),this.shouldNotify()&&this.listeners.forEach((function(l){return l(a)})),this.dirty=false;},f.prototype.shouldNotify=function(){if(!this.dirty||!this.listeners.size)return false;if(Es(this.networkStatus)&&this.observableQuery){var a=this.observableQuery.options.fetchPolicy;if(a!=="cache-only"&&a!=="cache-and-network")return false}return true},f.prototype.stop=function(){if(!this.stopped){this.stopped=true,this.reset(),this.cancel(),this.cancel=f.prototype.cancel,this.subscriptions.forEach((function(l){return l.unsubscribe()}));var a=this.observableQuery;a&&a.stopPolling();}},f.prototype.cancel=function(){},f.prototype.updateWatch=function(a){var l=this;a===void 0&&(a=this.variables);var d=this.observableQuery;if(!d||d.options.fetchPolicy!=="no-cache"){var m=bt(bt({},this.getDiffOptions(a)),{watcher:this,callback:function(y){return l.setDiff(y)}});this.lastWatch&&Nn(m,this.lastWatch)||(this.cancel(),this.cancel=this.cache.watch(this.lastWatch=m));}},f.prototype.resetLastWrite=function(){this.lastWrite=void 0;},f.prototype.shouldWrite=function(a,l){var d=this.lastWrite;return !(d&&d.dmCount===Is.get(this.cache)&&Nn(l,d.variables)&&Nn(a.data,d.result.data))},f.prototype.markResult=function(a,l,d){var m=this;this.graphQLErrors=kn(a.errors)?a.errors:[],this.reset(),l.fetchPolicy==="no-cache"?this.updateLastDiff({result:a.data,complete:true},this.getDiffOptions(l.variables)):d!==0&&(xo(a,l.errorPolicy)?this.cache.performTransaction((function(y){if(m.shouldWrite(a,l.variables))y.writeQuery({query:m.document,data:a.data,variables:l.variables,overwrite:d===1}),m.lastWrite={result:a,variables:l.variables,dmCount:Is.get(m.cache)};else if(m.lastDiff&&m.lastDiff.diff.complete)return void(a.data=m.lastDiff.diff.result);var b=m.getDiffOptions(l.variables),E=y.diff(b);m.stopped||m.updateWatch(l.variables),m.updateLastDiff(E,b),E.complete&&(a.data=E.result);})):this.lastWrite=void 0);},f.prototype.markReady=function(){return this.networkError=null,this.networkStatus=un.ready},f.prototype.markError=function(a){return this.networkStatus=un.error,this.lastWrite=void 0,this.reset(),a.graphQLErrors&&(this.graphQLErrors=a.graphQLErrors),a.networkError&&(this.networkError=a.networkError),a},f})();function xo(f,a){a===void 0&&(a="none");var l=a==="ignore"||a==="all",d=!Cs(f);return !d&&l&&f.data&&(d=true),d}var pi=Object.prototype.hasOwnProperty,eh=(function(){function f(a){var l=a.cache,d=a.link,m=a.queryDeduplication,y=m!==void 0&&m,b=a.onBroadcast,E=a.ssrMode,w=E!==void 0&&E,D=a.clientAwareness,_=D===void 0?{}:D,M=a.localState,B=a.assumeImmutableResults;this.clientAwareness={},this.queries=new Map,this.fetchCancelFns=new Map,this.transformCache=new(Dt?WeakMap:Map),this.queryIdCounter=1,this.requestIdCounter=1,this.mutationIdCounter=1,this.inFlightLinkObservables=new Map,this.cache=l,this.link=d,this.queryDeduplication=y,this.clientAwareness=_,this.localState=M||new Ll({cache:l}),this.ssrMode=w,this.assumeImmutableResults=!!B,(this.onBroadcast=b)&&(this.mutationStore=Object.create(null));}return f.prototype.stop=function(){var a=this;this.queries.forEach((function(l,d){a.stopQueryNoBroadcast(d);})),this.cancelPendingFetches(__DEV__?new Ce("QueryManager stopped while query was in flight"):new Ce(13));},f.prototype.cancelPendingFetches=function(a){this.fetchCancelFns.forEach((function(l){return l(a)})),this.fetchCancelFns.clear();},f.prototype.mutate=function(a){var l=a.mutation,d=a.variables,m=a.optimisticResponse,y=a.updateQueries,b=a.refetchQueries,E=b===void 0?[]:b,w=a.awaitRefetchQueries,D=w!==void 0&&w,_=a.update,M=a.onQueryUpdated,B=a.errorPolicy,H=B===void 0?"none":B,K=a.fetchPolicy,J=K===void 0?"network-only":K,tt=a.keepRootFields,yt=a.context;return sr(this,void 0,void 0,(function(){var Rt,Zt,zt;return Jn(this,(function(Bt){switch(Bt.label){case 0:return __DEV__?Vt(l,"mutation option is required. You must specify your GraphQL document in the mutation option."):Vt(l,14),__DEV__?Vt(J==="network-only"||J==="no-cache","Mutations support only 'network-only' or 'no-cache' fetchPolicy strings. The default `network-only` behavior automatically writes mutation results to the cache. Passing `no-cache` skips the cache write."):Vt(J==="network-only"||J==="no-cache",15),Rt=this.generateMutationId(),l=this.transform(l).document,d=this.getVariables(l,d),this.transform(l).hasClientExports?[4,this.localState.addExportedVariables(l,d,yt)]:[3,2];case 1:d=Bt.sent(),Bt.label=2;case 2:return Zt=this.mutationStore&&(this.mutationStore[Rt]={mutation:l,variables:d,loading:true,error:null}),m&&this.markMutationOptimistic(m,{mutationId:Rt,document:l,variables:d,fetchPolicy:J,errorPolicy:H,context:yt,updateQueries:y,update:_,keepRootFields:tt}),this.broadcastQueries(),zt=this,[2,new Promise((function(qt,$e){return mn(zt.getObservableFromLink(l,bt(bt({},yt),{optimisticResponse:m}),d,false),(function(fe){if(Cs(fe)&&H==="none")throw new Ae({graphQLErrors:fe.errors});Zt&&(Zt.loading=false,Zt.error=null);var Oe=bt({},fe);return typeof E=="function"&&(E=E(Oe)),H==="ignore"&&Cs(Oe)&&delete Oe.errors,zt.markMutationResult({mutationId:Rt,result:Oe,document:l,variables:d,fetchPolicy:J,errorPolicy:H,context:yt,update:_,updateQueries:y,awaitRefetchQueries:D,refetchQueries:E,removeOptimistic:m?Rt:void 0,onQueryUpdated:M,keepRootFields:tt})})).subscribe({next:function(fe){zt.broadcastQueries(),qt(fe);},error:function(fe){Zt&&(Zt.loading=false,Zt.error=fe),m&&zt.cache.removeOptimistic(Rt),zt.broadcastQueries(),$e(fe instanceof Ae?fe:new Ae({networkError:fe}));}})}))]}}))}))},f.prototype.markMutationResult=function(a,l){var d=this;l===void 0&&(l=this.cache);var m=a.result,y=[],b=a.fetchPolicy==="no-cache";if(!b&&xo(m,a.errorPolicy)){y.push({result:m.data,dataId:"ROOT_MUTATION",query:a.document,variables:a.variables});var E=a.updateQueries;E&&this.queries.forEach((function(D,_){var M=D.observableQuery,B=M&&M.queryName;if(B&&pi.call(E,B)){var H=E[B],K=d.queries.get(_),J=K.document,tt=K.variables,yt=l.diff({query:J,variables:tt,returnPartialData:true,optimistic:false}),Rt=yt.result;if(yt.complete&&Rt){var Zt=H(Rt,{mutationResult:m,queryName:J&&Ai(J)||void 0,queryVariables:tt});Zt&&y.push({result:Zt,dataId:"ROOT_QUERY",query:J,variables:tt});}}}));}if(y.length>0||a.refetchQueries||a.update||a.onQueryUpdated||a.removeOptimistic){var w=[];if(this.refetchQueries({updateCache:function(D){b||y.forEach((function(B){return D.write(B)}));var _=a.update;if(_){if(!b){var M=D.diff({id:"ROOT_MUTATION",query:d.transform(a.document).asQuery,variables:a.variables,optimistic:false,returnPartialData:true});M.complete&&(m=bt(bt({},m),{data:M.result}));}_(D,m,{context:a.context,variables:a.variables});}b||a.keepRootFields||D.modify({id:"ROOT_MUTATION",fields:function(B,H){var K=H.fieldName,J=H.DELETE;return K==="__typename"?B:J}});},include:a.refetchQueries,optimistic:false,removeOptimistic:a.removeOptimistic,onQueryUpdated:a.onQueryUpdated||null}).forEach((function(D){return w.push(D)})),a.awaitRefetchQueries||a.onQueryUpdated)return Promise.all(w).then((function(){return m}))}return Promise.resolve(m)},f.prototype.markMutationOptimistic=function(a,l){var d=this,m=typeof a=="function"?a(l.variables):a;return this.cache.recordOptimisticTransaction((function(y){try{d.markMutationResult(bt(bt({},l),{result:{data:m}}),y);}catch(b){__DEV__&&Vt.error(b);}}),l.mutationId)},f.prototype.fetchQuery=function(a,l,d){return this.fetchQueryObservable(a,l,d).promise},f.prototype.getQueryStore=function(){var a=Object.create(null);return this.queries.forEach((function(l,d){a[d]={variables:l.variables,networkStatus:l.networkStatus,networkError:l.networkError,graphQLErrors:l.graphQLErrors};})),a},f.prototype.resetErrors=function(a){var l=this.queries.get(a);l&&(l.networkError=void 0,l.graphQLErrors=[]);},f.prototype.transform=function(a){var l,d=this.transformCache;if(!d.has(a)){var m=this.cache.transformDocument(a),y=(l=this.cache.transformForLink(m),Il([an],ci(l))),b=this.localState.clientQuery(m),E=y&&this.localState.serverQuery(y),w={document:m,hasClientExports:Hy(m),hasForcedResolvers:this.localState.shouldForceResolvers(m),clientQuery:b,serverQuery:E,defaultVars:zo(Kn(m)),asQuery:bt(bt({},m),{definitions:m.definitions.map((function(_){return _.kind==="OperationDefinition"&&_.operation!=="query"?bt(bt({},_),{operation:"query"}):_}))})},D=function(_){_&&!d.has(_)&&d.set(_,w);};D(a),D(m),D(b),D(E);}return d.get(a)},f.prototype.getVariables=function(a,l){return bt(bt({},this.transform(a).defaultVars),l)},f.prototype.watchQuery=function(a){(a=bt(bt({},a),{variables:this.getVariables(a.query,a.variables)})).notifyOnNetworkStatusChange===void 0&&(a.notifyOnNetworkStatusChange=false);var l=new Bl(this),d=new Rd({queryManager:this,queryInfo:l,options:a});return this.queries.set(d.queryId,l),l.init({document:a.query,observableQuery:d,variables:a.variables}),d},f.prototype.query=function(a,l){var d=this;return l===void 0&&(l=this.generateQueryId()),__DEV__?Vt(a.query,"query option is required. You must specify your GraphQL document in the query option."):Vt(a.query,16),__DEV__?Vt(a.query.kind==="Document",'You must wrap the query string in a "gql" tag.'):Vt(a.query.kind==="Document",17),__DEV__?Vt(!a.returnPartialData,"returnPartialData option only supported on watchQuery."):Vt(!a.returnPartialData,18),__DEV__?Vt(!a.pollInterval,"pollInterval option only supported on watchQuery."):Vt(!a.pollInterval,19),this.fetchQuery(l,a).finally((function(){return d.stopQuery(l)}))},f.prototype.generateQueryId=function(){return String(this.queryIdCounter++)},f.prototype.generateRequestId=function(){return this.requestIdCounter++},f.prototype.generateMutationId=function(){return String(this.mutationIdCounter++)},f.prototype.stopQueryInStore=function(a){this.stopQueryInStoreNoBroadcast(a),this.broadcastQueries();},f.prototype.stopQueryInStoreNoBroadcast=function(a){var l=this.queries.get(a);l&&l.stop();},f.prototype.clearStore=function(a){return a===void 0&&(a={discardWatches:true}),this.cancelPendingFetches(__DEV__?new Ce("Store reset while query was in flight (not completed in link chain)"):new Ce(20)),this.queries.forEach((function(l){l.observableQuery?l.networkStatus=un.loading:l.stop();})),this.mutationStore&&(this.mutationStore=Object.create(null)),this.cache.reset(a)},f.prototype.getObservableQueries=function(a){var l=this;a===void 0&&(a="active");var d=new Map,m=new Map,y=new Set;return Array.isArray(a)&&a.forEach((function(b){var E;typeof b=="string"?m.set(b,false):vt(E=b)&&E.kind==="Document"&&Array.isArray(E.definitions)?m.set(l.transform(b).document,false):vt(b)&&b.query&&y.add(b);})),this.queries.forEach((function(b,E){var w=b.observableQuery,D=b.document;if(w){if(a==="all")return void d.set(E,w);var _=w.queryName;if(w.options.fetchPolicy==="standby"||a==="active"&&!w.hasObservers())return;(a==="active"||_&&m.has(_)||D&&m.has(D))&&(d.set(E,w),_&&m.set(_,true),D&&m.set(D,true));}})),y.size&&y.forEach((function(b){var E=Ps("legacyOneTimeQuery"),w=l.getQuery(E).init({document:b.query,variables:b.variables}),D=new Rd({queryManager:l,queryInfo:w,options:bt(bt({},b),{fetchPolicy:"network-only"})});Vt(D.queryId===E),w.setObservableQuery(D),d.set(E,D);})),__DEV__&&m.size&&m.forEach((function(b,E){b||__DEV__&&Vt.warn("Unknown query "+(typeof E=="string"?"named ":"")+JSON.stringify(E,null,2)+" requested in refetchQueries options.include array");})),d},f.prototype.reFetchObservableQueries=function(a){var l=this;a===void 0&&(a=false);var d=[];return this.getObservableQueries(a?"all":"active").forEach((function(m,y){var b=m.options.fetchPolicy;m.resetLastResults(),(a||b!=="standby"&&b!=="cache-only")&&d.push(m.refetch()),l.getQuery(y).setDiff(null);})),this.broadcastQueries(),Promise.all(d)},f.prototype.setObservableQuery=function(a){this.getQuery(a.queryId).setObservableQuery(a);},f.prototype.startGraphQLSubscription=function(a){var l=this,d=a.query,m=a.fetchPolicy,y=a.errorPolicy,b=a.variables,E=a.context,w=E===void 0?{}:E;d=this.transform(d).document,b=this.getVariables(d,b);var D=function(M){return l.getObservableFromLink(d,w,M).map((function(B){if(m!=="no-cache"&&(xo(B,y)&&l.cache.write({query:d,result:B.data,dataId:"ROOT_SUBSCRIPTION",variables:M}),l.broadcastQueries()),Cs(B))throw new Ae({graphQLErrors:B.errors});return B}))};if(this.transform(d).hasClientExports){var _=this.localState.addExportedVariables(d,b,w).then(D);return new Je((function(M){var B=null;return _.then((function(H){return B=H.subscribe(M)}),M.error),function(){return B&&B.unsubscribe()}}))}return D(b)},f.prototype.stopQuery=function(a){this.stopQueryNoBroadcast(a),this.broadcastQueries();},f.prototype.stopQueryNoBroadcast=function(a){this.stopQueryInStoreNoBroadcast(a),this.removeQuery(a);},f.prototype.removeQuery=function(a){this.fetchCancelFns.delete(a),this.getQuery(a).stop(),this.queries.delete(a);},f.prototype.broadcastQueries=function(){this.onBroadcast&&this.onBroadcast(),this.queries.forEach((function(a){return a.notify()}));},f.prototype.getLocalState=function(){return this.localState},f.prototype.getObservableFromLink=function(a,l,d,m){var y,b,E=this;m===void 0&&(m=(y=l==null?void 0:l.queryDeduplication)!==null&&y!==void 0?y:this.queryDeduplication);var w=this.transform(a).serverQuery;if(w){var D=this.inFlightLinkObservables,_=this.link,M={query:w,variables:d,operationName:Ai(w)||void 0,context:this.prepareContext(bt(bt({},l),{forceFetch:!m}))};if(l=M.context,m){var B=D.get(w)||new Map;D.set(w,B);var H=En(d);if(!(b=B.get(H))){var K=new xs([Ta(_,M)]);B.set(H,b=K),K.cleanup((function(){B.delete(H)&&B.size<1&&D.delete(w);}));}}else b=new xs([Ta(_,M)]);}else b=new xs([Je.of({data:{}})]),l=this.prepareContext(l);var J=this.transform(a).clientQuery;return J&&(b=mn(b,(function(tt){return E.localState.runResolvers({document:J,remoteResult:tt,context:l,variables:d})}))),b},f.prototype.getResultsFromLink=function(a,l,d){var m=a.lastRequestId=this.generateRequestId();return mn(this.getObservableFromLink(a.document,d.context,d.variables),(function(y){var b=kn(y.errors);if(m>=a.lastRequestId){if(b&&d.errorPolicy==="none")throw a.markError(new Ae({graphQLErrors:y.errors}));a.markResult(y,d,l),a.markReady();}var E={data:y.data,loading:false,networkStatus:a.networkStatus||un.ready};return b&&d.errorPolicy!=="ignore"&&(E.errors=y.errors),E}),(function(y){var b=y.hasOwnProperty("graphQLErrors")?y:new Ae({networkError:y});throw m>=a.lastRequestId&&a.markError(b),b}))},f.prototype.fetchQueryObservable=function(a,l,d){var m=this;d===void 0&&(d=un.loading);var y=this.transform(l.query).document,b=this.getVariables(y,l.variables),E=this.getQuery(a),w=l.fetchPolicy,D=w===void 0?"cache-first":w,_=l.errorPolicy,M=_===void 0?"none":_,B=l.returnPartialData,H=B!==void 0&&B,K=l.notifyOnNetworkStatusChange,J=K!==void 0&&K,tt=l.context,yt=tt===void 0?{}:tt,Rt=Object.assign({},l,{query:y,variables:b,fetchPolicy:D,errorPolicy:M,returnPartialData:H,notifyOnNetworkStatusChange:J,context:yt}),Zt=function(Bt){return Rt.variables=Bt,m.fetchQueryByPolicy(E,Rt,d)};this.fetchCancelFns.set(a,(function(Bt){setTimeout((function(){return zt.cancel(Bt)}));}));var zt=new xs(this.transform(Rt.query).hasClientExports?this.localState.addExportedVariables(Rt.query,Rt.variables,Rt.context).then(Zt):Zt(Rt.variables));return zt.cleanup((function(){m.fetchCancelFns.delete(a),(function(Bt){var qt=Bt.fetchPolicy,$e=qt===void 0?"cache-first":qt,fe=Bt.nextFetchPolicy;fe&&(Bt.fetchPolicy=typeof fe=="function"?fe.call(Bt,$e):fe);})(l);})),zt},f.prototype.refetchQueries=function(a){var l=this,d=a.updateCache,m=a.include,y=a.optimistic,b=y!==void 0&&y,E=a.removeOptimistic,w=E===void 0?b?Ps("refetchQueries"):void 0:E,D=a.onQueryUpdated,_=new Map;m&&this.getObservableQueries(m).forEach((function(B,H){_.set(H,{oq:B,lastDiff:l.getQuery(H).getDiff()});}));var M=new Map;return d&&this.cache.batch({update:d,optimistic:b&&w||false,removeOptimistic:w,onWatchUpdated:function(B,H,K){var J=B.watcher instanceof Bl&&B.watcher.observableQuery;if(J){if(D){_.delete(J.queryId);var tt=D(J,H,K);return tt===true&&(tt=J.refetch()),tt!==false&&M.set(J,tt),false}D!==null&&_.set(J.queryId,{oq:J,lastDiff:K,diff:H});}}}),_.size&&_.forEach((function(B,H){var K,J=B.oq,tt=B.lastDiff,yt=B.diff;if(D){if(!yt){var Rt=J.queryInfo;Rt.reset(),yt=Rt.getDiff();}K=D(J,yt,tt);}D&&K!==true||(K=J.refetch()),K!==false&&M.set(J,K),H.indexOf("legacyOneTimeQuery")>=0&&l.stopQueryNoBroadcast(H);})),w&&this.cache.removeOptimistic(w),M},f.prototype.fetchQueryByPolicy=function(a,l,d){var m=this,y=l.query,b=l.variables,E=l.fetchPolicy,w=l.refetchWritePolicy,D=l.errorPolicy,_=l.returnPartialData,M=l.context,B=l.notifyOnNetworkStatusChange,H=a.networkStatus;a.init({document:y,variables:b,networkStatus:d});var K=function(){return a.getDiff(b)},J=function(zt,Bt){Bt===void 0&&(Bt=a.networkStatus||un.loading);var qt=zt.result;!__DEV__||_||Nn(qt,{})||Dl(zt.missing);var $e=function(fe){return Je.of(bt({data:fe,loading:Es(Bt),networkStatus:Bt},zt.complete?null:{partial:true}))};return qt&&m.transform(y).hasForcedResolvers?m.localState.runResolvers({document:y,remoteResult:{data:qt},context:M,variables:b,onlyRunForcedResolvers:true}).then((function(fe){return $e(fe.data||void 0)})):$e(qt)},tt=E==="no-cache"?0:d===un.refetch&&w!=="merge"?1:2,yt=function(){return m.getResultsFromLink(a,tt,{variables:b,context:M,fetchPolicy:E,errorPolicy:D})},Rt=B&&typeof H=="number"&&H!==d&&Es(d);switch(E){default:case "cache-first":return (Zt=K()).complete?[J(Zt,a.markReady())]:_||Rt?[J(Zt),yt()]:[yt()];case "cache-and-network":var Zt;return (Zt=K()).complete||_||Rt?[J(Zt),yt()]:[yt()];case "cache-only":return [J(K(),a.markReady())];case "network-only":return Rt?[J(K()),yt()]:[yt()];case "no-cache":return Rt?[J(a.getDiff()),yt()]:[yt()];case "standby":return []}},f.prototype.getQuery=function(a){return a&&!this.queries.has(a)&&this.queries.set(a,new Bl(this,a)),this.queries.get(a)},f.prototype.prepareContext=function(a){a===void 0&&(a={});var l=this.localState.prepareContext(a);return bt(bt({},l),{clientAwareness:this.clientAwareness})},f})(),$d=false;function Fa(f,a){return vs(f,a,a.variables&&{variables:bt(bt({},f.variables),a.variables)})}var Xo=(function(){function f(a){var l=this;this.defaultOptions={},this.resetStoreCallbacks=[],this.clearStoreCallbacks=[];var d=a.uri,m=a.credentials,y=a.headers,b=a.cache,E=a.ssrMode,w=E!==void 0&&E,D=a.ssrForceFetchDelay,_=D===void 0?0:D,M=a.connectToDevTools,B=M===void 0?typeof window=="object"&&!window.__APOLLO_CLIENT__&&__DEV__:M,H=a.queryDeduplication,K=H===void 0||H,J=a.defaultOptions,tt=a.assumeImmutableResults,yt=tt!==void 0&&tt,Rt=a.resolvers,Zt=a.typeDefs,zt=a.fragmentMatcher,Bt=a.name,qt=a.version,$e=a.link;if($e||($e=d?new Wc({uri:d,credentials:m,headers:y}):Tt.empty()),!b)throw __DEV__?new Ce(`To initialize Apollo Client, you must specify a 'cache' property in the options object.
2363
- For more information, please visit: https://go.apollo.dev/c/docs`):new Ce(9);if(this.link=$e,this.cache=b,this.disableNetworkFetches=w||_>0,this.queryDeduplication=K,this.defaultOptions=J||{},this.typeDefs=Zt,_&&setTimeout((function(){return l.disableNetworkFetches=false}),_),this.watchQuery=this.watchQuery.bind(this),this.query=this.query.bind(this),this.mutate=this.mutate.bind(this),this.resetStore=this.resetStore.bind(this),this.reFetchObservableQueries=this.reFetchObservableQueries.bind(this),B&&typeof window=="object"&&(window.__APOLLO_CLIENT__=this),!$d&&__DEV__&&($d=true,typeof window!="undefined"&&window.document&&window.top===window.self&&!window.__APOLLO_DEVTOOLS_GLOBAL_HOOK__)){var fe=window.navigator,Oe=fe&&fe.userAgent,An=void 0;typeof Oe=="string"&&(Oe.indexOf("Chrome/")>-1?An="https://chrome.google.com/webstore/detail/apollo-client-developer-t/jdkknkkbebbapilgoeccciglkfbmbnfm":Oe.indexOf("Firefox/")>-1&&(An="https://addons.mozilla.org/en-US/firefox/addon/apollo-developer-tools/")),An&&__DEV__&&Vt.log("Download the Apollo DevTools for a better development experience: "+An);}this.version="3.4.17",this.localState=new Ll({cache:b,client:this,resolvers:Rt,fragmentMatcher:zt}),this.queryManager=new eh({cache:this.cache,link:this.link,queryDeduplication:K,ssrMode:w,clientAwareness:{name:Bt,version:qt},localState:this.localState,assumeImmutableResults:yt,onBroadcast:B?function(){l.devToolsHookCb&&l.devToolsHookCb({action:{},state:{queries:l.queryManager.getQueryStore(),mutations:l.queryManager.mutationStore||{}},dataWithOptimisticResults:l.cache.extract(true)});}:void 0});}return f.prototype.stop=function(){this.queryManager.stop();},f.prototype.watchQuery=function(a){return this.defaultOptions.watchQuery&&(a=Fa(this.defaultOptions.watchQuery,a)),!this.disableNetworkFetches||a.fetchPolicy!=="network-only"&&a.fetchPolicy!=="cache-and-network"||(a=bt(bt({},a),{fetchPolicy:"cache-first"})),this.queryManager.watchQuery(a)},f.prototype.query=function(a){return this.defaultOptions.query&&(a=Fa(this.defaultOptions.query,a)),__DEV__?Vt(a.fetchPolicy!=="cache-and-network","The cache-and-network fetchPolicy does not work with client.query, because client.query can only return a single result. Please use client.watchQuery to receive multiple results from the cache and the network, or consider using a different fetchPolicy, such as cache-first or network-only."):Vt(a.fetchPolicy!=="cache-and-network",10),this.disableNetworkFetches&&a.fetchPolicy==="network-only"&&(a=bt(bt({},a),{fetchPolicy:"cache-first"})),this.queryManager.query(a)},f.prototype.mutate=function(a){return this.defaultOptions.mutate&&(a=Fa(this.defaultOptions.mutate,a)),this.queryManager.mutate(a)},f.prototype.subscribe=function(a){return this.queryManager.startGraphQLSubscription(a)},f.prototype.readQuery=function(a,l){return l===void 0&&(l=false),this.cache.readQuery(a,l)},f.prototype.readFragment=function(a,l){return l===void 0&&(l=false),this.cache.readFragment(a,l)},f.prototype.writeQuery=function(a){this.cache.writeQuery(a),this.queryManager.broadcastQueries();},f.prototype.writeFragment=function(a){this.cache.writeFragment(a),this.queryManager.broadcastQueries();},f.prototype.__actionHookForDevTools=function(a){this.devToolsHookCb=a;},f.prototype.__requestRaw=function(a){return Ta(this.link,a)},f.prototype.resetStore=function(){var a=this;return Promise.resolve().then((function(){return a.queryManager.clearStore({discardWatches:false})})).then((function(){return Promise.all(a.resetStoreCallbacks.map((function(l){return l()})))})).then((function(){return a.reFetchObservableQueries()}))},f.prototype.clearStore=function(){var a=this;return Promise.resolve().then((function(){return a.queryManager.clearStore({discardWatches:true})})).then((function(){return Promise.all(a.clearStoreCallbacks.map((function(l){return l()})))}))},f.prototype.onResetStore=function(a){var l=this;return this.resetStoreCallbacks.push(a),function(){l.resetStoreCallbacks=l.resetStoreCallbacks.filter((function(d){return d!==a}));}},f.prototype.onClearStore=function(a){var l=this;return this.clearStoreCallbacks.push(a),function(){l.clearStoreCallbacks=l.clearStoreCallbacks.filter((function(d){return d!==a}));}},f.prototype.reFetchObservableQueries=function(a){return this.queryManager.reFetchObservableQueries(a)},f.prototype.refetchQueries=function(a){var l=this.queryManager.refetchQueries(a),d=[],m=[];l.forEach((function(b,E){d.push(E),m.push(b);}));var y=Promise.all(m);return y.queries=d,y.results=m,y.catch((function(b){__DEV__&&Vt.debug("In client.refetchQueries, Promise.all promise rejected with error "+b);})),y},f.prototype.getObservableQueries=function(a){return a===void 0&&(a="active"),this.queryManager.getObservableQueries(a)},f.prototype.extract=function(a){return this.cache.extract(a)},f.prototype.restore=function(a){return this.cache.restore(a)},f.prototype.addResolvers=function(a){this.localState.addResolvers(a);},f.prototype.setResolvers=function(a){this.localState.setResolvers(a);},f.prototype.getResolvers=function(){return this.localState.getResolvers()},f.prototype.setLocalStateFragmentMatcher=function(a){this.localState.setFragmentMatcher(a);},f.prototype.setLink=function(a){this.link=this.queryManager.link=a;},f})(),nh=(function(){function f(){this.getFragmentDoc=Hr(gs);}return f.prototype.batch=function(a){var l=typeof a.optimistic=="string"?a.optimistic:a.optimistic===false?null:void 0;this.performTransaction(a.update,l);},f.prototype.recordOptimisticTransaction=function(a,l){this.performTransaction(a,l);},f.prototype.transformDocument=function(a){return a},f.prototype.identify=function(a){},f.prototype.gc=function(){return []},f.prototype.modify=function(a){return false},f.prototype.transformForLink=function(a){return a},f.prototype.readQuery=function(a,l){return l===void 0&&(l=!!a.optimistic),this.read(bt(bt({},a),{rootId:a.id||"ROOT_QUERY",optimistic:l}))},f.prototype.readFragment=function(a,l){return l===void 0&&(l=!!a.optimistic),this.read(bt(bt({},a),{query:this.getFragmentDoc(a.fragment,a.fragmentName),rootId:a.id,optimistic:l}))},f.prototype.writeQuery=function(a){var l=a.id,d=a.data,m=ar(a,["id","data"]);return this.write(Object.assign(m,{dataId:l||"ROOT_QUERY",result:d}))},f.prototype.writeFragment=function(a){var l=a.id,d=a.data,m=a.fragment,y=a.fragmentName,b=ar(a,["id","data","fragment","fragmentName"]);return this.write(Object.assign(b,{query:this.getFragmentDoc(m,y),dataId:l,result:d}))},f})(),rh=(function(f){function a(l,d,m,y){var b=f.call(this,l)||this;return b.message=l,b.path=d,b.query=m,b.variables=y,b.__proto__=a.prototype,b}return Ve(a,f),a})(Error);function ks(f){return __DEV__&&(a=f,(l=new Set([a])).forEach((function(d){vt(d)&&(function(m){if(__DEV__&&!Object.isFrozen(m))try{Object.freeze(m);}catch(y){if(y instanceof TypeError)return null;throw y}return m})(d)===d&&Object.getOwnPropertyNames(d).forEach((function(m){vt(d[m])&&l.add(d[m]);}));}))),f;var a,l;}var fr=Object.prototype.hasOwnProperty;function hr(f,a){var l=f.__typename,d=f.id,m=f._id;if(typeof l=="string"&&(a&&(a.keyObject=d!==void 0?{id:d}:m!==void 0?{_id:m}:void 0),d===void 0&&(d=m),d!==void 0))return l+":"+(typeof d=="number"||typeof d=="string"?d:JSON.stringify(d))}var ru={dataIdFromObject:hr,addTypename:true,resultCaching:true,canonizeResults:false};function Gd(f){var a=f.canonizeResults;return a===void 0?ru.canonizeResults:a}var Fi=/^[_a-z][_0-9a-z]*/i;function Zi(f){var a=f.match(Fi);return a?a[0]:f}function Ds(f,a,l){return !!vt(a)&&(Array.isArray(a)?a.every((function(d){return Ds(f,d,l)})):f.selections.every((function(d){if(tr(d)&&Ia(d,l)){var m=on(d);return fr.call(a,m)&&(!d.selectionSet||Ds(d.selectionSet,a[m],l))}return true})))}function Mi(f){return vt(f)&&!ae(f)&&!Array.isArray(f)}var Ul=Object.create(null),Pr=function(){return Ul},iu=Object.create(null),$l=(function(){function f(a,l){var d=this;this.policies=a,this.group=l,this.data=Object.create(null),this.rootIds=Object.create(null),this.refs=Object.create(null),this.getFieldValue=function(m,y){return ks(ae(m)?d.get(m.__ref,y):m&&m[y])},this.canRead=function(m){return ae(m)?d.has(m.__ref):typeof m=="object"},this.toReference=function(m,y){if(typeof m=="string")return qi(m);if(ae(m))return m;var b=d.policies.identify(m)[0];if(b){var E=qi(b);return y&&d.merge(b,m),E}};}return f.prototype.toObject=function(){return bt({},this.data)},f.prototype.has=function(a){return this.lookup(a,true)!==void 0},f.prototype.get=function(a,l){if(this.group.depend(a,l),fr.call(this.data,a)){var d=this.data[a];if(d&&fr.call(d,l))return d[l]}return l==="__typename"&&fr.call(this.policies.rootTypenamesById,a)?this.policies.rootTypenamesById[a]:this instanceof Eo?this.parent.get(a,l):void 0},f.prototype.lookup=function(a,l){return l&&this.group.depend(a,"__exists"),fr.call(this.data,a)?this.data[a]:this instanceof Eo?this.parent.lookup(a,l):this.policies.rootTypenamesById[a]?Object.create(null):void 0},f.prototype.merge=function(a,l){var d,m=this;ae(a)&&(a=a.__ref),ae(l)&&(l=l.__ref);var y=typeof a=="string"?this.lookup(d=a):a,b=typeof l=="string"?this.lookup(d=l):l;if(b){__DEV__?Vt(typeof d=="string","store.merge expects a string ID"):Vt(typeof d=="string",1);var E=new Md(jd).merge(y,b);if(this.data[d]=E,E!==y&&(delete this.refs[d],this.group.caching)){var w=Object.create(null);y||(w.__exists=1),Object.keys(b).forEach((function(D){if(!y||y[D]!==E[D]){w[D]=1;var _=Zi(D);_===D||m.policies.hasKeyArgs(E.__typename,_)||(w[_]=1),E[D]!==void 0||m instanceof Eo||delete E[D];}})),!w.__typename||y&&y.__typename||this.policies.rootTypenamesById[d]!==E.__typename||delete w.__typename,Object.keys(w).forEach((function(D){return m.group.dirty(d,D)}));}}},f.prototype.modify=function(a,l){var d=this,m=this.lookup(a);if(m){var y=Object.create(null),b=false,E=true,w={DELETE:Ul,INVALIDATE:iu,isReference:ae,toReference:this.toReference,canRead:this.canRead,readField:function(D,_){return d.policies.readField(typeof D=="string"?{fieldName:D,from:_||qi(a)}:D,{store:d})}};if(Object.keys(m).forEach((function(D){var _=Zi(D),M=m[D];if(M!==void 0){var B=typeof l=="function"?l:l[D]||l[_];if(B){var H=B===Pr?Ul:B(ks(M),bt(bt({},w),{fieldName:_,storeFieldName:D,storage:d.getStorage(a,D)}));H===iu?d.group.dirty(a,D):(H===Ul&&(H=void 0),H!==M&&(y[D]=H,b=true,M=H));}M!==void 0&&(E=false);}})),b)return this.merge(a,y),E&&(this instanceof Eo?this.data[a]=void 0:delete this.data[a],this.group.dirty(a,"__exists")),true}return false},f.prototype.delete=function(a,l,d){var m,y=this.lookup(a);if(y){var b=this.getFieldValue(y,"__typename"),E=l&&d?this.policies.getStoreFieldName({typename:b,fieldName:l,args:d}):l;return this.modify(a,E?((m={})[E]=Pr,m):Pr)}return false},f.prototype.evict=function(a,l){var d=false;return a.id&&(fr.call(this.data,a.id)&&(d=this.delete(a.id,a.fieldName,a.args)),this instanceof Eo&&this!==l&&(d=this.parent.evict(a,l)||d),(a.fieldName||d)&&this.group.dirty(a.id,a.fieldName||"__exists")),d},f.prototype.clear=function(){this.replace(null);},f.prototype.extract=function(){var a=this,l=this.toObject(),d=[];return this.getRootIdSet().forEach((function(m){fr.call(a.policies.rootTypenamesById,m)||d.push(m);})),d.length&&(l.__META={extraRootIds:d.sort()}),l},f.prototype.replace=function(a){var l=this;if(Object.keys(this.data).forEach((function(y){a&&fr.call(a,y)||l.delete(y);})),a){var d=a.__META,m=ar(a,["__META"]);Object.keys(m).forEach((function(y){l.merge(y,m[y]);})),d&&d.extraRootIds.forEach(this.retain,this);}},f.prototype.retain=function(a){return this.rootIds[a]=(this.rootIds[a]||0)+1},f.prototype.release=function(a){if(this.rootIds[a]>0){var l=--this.rootIds[a];return l||delete this.rootIds[a],l}return 0},f.prototype.getRootIdSet=function(a){return a===void 0&&(a=new Set),Object.keys(this.rootIds).forEach(a.add,a),this instanceof Eo?this.parent.getRootIdSet(a):Object.keys(this.policies.rootTypenamesById).forEach(a.add,a),a},f.prototype.gc=function(){var a=this,l=this.getRootIdSet(),d=this.toObject();l.forEach((function(b){fr.call(d,b)&&(Object.keys(a.findChildRefIds(b)).forEach(l.add,l),delete d[b]);}));var m=Object.keys(d);if(m.length){for(var y=this;y instanceof Eo;)y=y.parent;m.forEach((function(b){return y.delete(b)}));}return m},f.prototype.findChildRefIds=function(a){if(!fr.call(this.refs,a)){var l=this.refs[a]=Object.create(null),d=this.data[a];if(!d)return l;var m=new Set([d]);m.forEach((function(y){ae(y)&&(l[y.__ref]=true),vt(y)&&Object.keys(y).forEach((function(b){var E=y[b];vt(E)&&m.add(E);}));}));}return this.refs[a]},f.prototype.makeCacheKey=function(){return this.group.keyMaker.lookupArray(arguments)},f})(),ih=(function(){function f(a,l){l===void 0&&(l=null),this.caching=a,this.parent=l,this.d=null,this.resetCaching();}return f.prototype.resetCaching=function(){this.d=this.caching?Qi():null,this.keyMaker=new At(Dt);},f.prototype.depend=function(a,l){if(this.d){this.d(Gl(a,l));var d=Zi(l);d!==l&&this.d(Gl(a,d)),this.parent&&this.parent.depend(a,l);}},f.prototype.dirty=function(a,l){this.d&&this.d.dirty(Gl(a,l),l==="__exists"?"forget":"setDirty");},f})();function Gl(f,a){return a+"#"+f}function As(f,a){Os(f)&&f.group.depend(a,"__exists");}(function(f){var a=(function(l){function d(m){var y=m.policies,b=m.resultCaching,E=b===void 0||b,w=m.seed,D=l.call(this,y,new ih(E))||this;return D.stump=new jl(D),D.storageTrie=new At(Dt),w&&D.replace(w),D}return Ve(d,l),d.prototype.addLayer=function(m,y){return this.stump.addLayer(m,y)},d.prototype.removeLayer=function(){return this},d.prototype.getStorage=function(){return this.storageTrie.lookupArray(arguments)},d})(f);f.Root=a;})($l||($l={}));var Eo=(function(f){function a(l,d,m,y){var b=f.call(this,d.policies,y)||this;return b.id=l,b.parent=d,b.replay=m,b.group=y,m(b),b}return Ve(a,f),a.prototype.addLayer=function(l,d){return new a(l,this,d,this.group)},a.prototype.removeLayer=function(l){var d=this,m=this.parent.removeLayer(l);return l===this.id?(this.group.caching&&Object.keys(this.data).forEach((function(y){var b=d.data[y],E=m.lookup(y);E?b?b!==E&&Object.keys(b).forEach((function(w){Nn(b[w],E[w])||d.group.dirty(y,w);})):(d.group.dirty(y,"__exists"),Object.keys(E).forEach((function(w){d.group.dirty(y,w);}))):d.delete(y);})),m):m===this.parent?this:m.addLayer(this.id,this.replay)},a.prototype.toObject=function(){return bt(bt({},this.parent.toObject()),this.data)},a.prototype.findChildRefIds=function(l){var d=this.parent.findChildRefIds(l);return fr.call(this.data,l)?bt(bt({},d),f.prototype.findChildRefIds.call(this,l)):d},a.prototype.getStorage=function(){for(var l=this.parent;l.parent;)l=l.parent;return l.getStorage.apply(l,arguments)},a})($l),jl=(function(f){function a(l){return f.call(this,"EntityStore.Stump",l,(function(){}),new ih(l.group.caching,l.group))||this}return Ve(a,f),a.prototype.removeLayer=function(){return this},a.prototype.merge=function(){return this.parent.merge.apply(this.parent,arguments)},a})(Eo);function jd(f,a,l){var d=f[l],m=a[l];return Nn(d,m)?d:m}function Os(f){return !!(f instanceof $l&&f.group.caching)}function Vd(f,a){return new rh(f.message,a.path.slice(),a.query,a.variables)}function ou(f){return [f.selectionSet,f.objectOrReference,f.context,f.context.canonizeResults]}var zd=(function(){function f(a){var l=this;this.knownResults=new(Dt?WeakMap:Map),this.config=vs(a,{addTypename:a.addTypename!==false,canonizeResults:Gd(a)}),this.canon=a.canon||new Ne,this.executeSelectionSet=Hr((function(d){var m,y=d.context.canonizeResults,b=ou(d);b[3]=!y;var E=(m=l.executeSelectionSet).peek.apply(m,b);return E?y?bt(bt({},E),{result:l.canon.admit(E.result)}):E:(As(d.context.store,d.enclosingRef.__ref),l.execSelectionSetImpl(d))}),{max:this.config.resultCacheMaxSize,keyArgs:ou,makeCacheKey:function(d,m,y,b){if(Os(y.store))return y.store.makeCacheKey(d,ae(m)?m.__ref:m,y.varString,b)}}),this.executeSubSelectedArray=Hr((function(d){return As(d.context.store,d.enclosingRef.__ref),l.execSubSelectedArrayImpl(d)}),{max:this.config.resultCacheMaxSize,makeCacheKey:function(d){var m=d.field,y=d.array,b=d.context;if(Os(b.store))return b.store.makeCacheKey(m,y,b.varString)}});}return f.prototype.resetCanon=function(){this.canon=new Ne;},f.prototype.diffQueryAgainstStore=function(a){var l=a.store,d=a.query,m=a.rootId,y=m===void 0?"ROOT_QUERY":m,b=a.variables,E=a.returnPartialData,w=E===void 0||E,D=a.canonizeResults,_=D===void 0?this.config.canonizeResults:D,M=this.config.cache.policies;b=bt(bt({},zo(ys(d))),b);var B=qi(y),H=this.executeSelectionSet({selectionSet:_a(d).selectionSet,objectOrReference:B,enclosingRef:B,context:{store:l,query:d,policies:M,variables:b,varString:En(b),canonizeResults:_,fragmentMap:So(er(d)),path:[]}}),K=H.missing&&H.missing.length>0;if(K&&!w)throw H.missing[0];return {result:H.result,missing:H.missing,complete:!K}},f.prototype.isFresh=function(a,l,d,m){if(Os(m.store)&&this.knownResults.get(a)===d){var y=this.executeSelectionSet.peek(d,l,m,this.canon.isKnown(a));if(y&&a===y.result)return true}return false},f.prototype.execSelectionSetImpl=function(a){var l=this,d=a.selectionSet,m=a.objectOrReference,y=a.enclosingRef,b=a.context;if(ae(m)&&!b.policies.rootTypenamesById[m.__ref]&&!b.store.has(m.__ref))return {result:this.canon.empty,missing:[Vd(__DEV__?new Ce("Dangling reference to missing "+m.__ref+" object"):new Ce(5),b)]};var E=b.variables,w=b.policies,D=b.store,_=[],M={result:null},B=D.getFieldValue(m,"__typename");function H(){return M.missing||(M.missing=[])}function K(yt){var Rt;return yt.missing&&(Rt=H()).push.apply(Rt,yt.missing),yt.result}this.config.addTypename&&typeof B=="string"&&!w.rootIdsByTypename[B]&&_.push({__typename:B});var J=new Set(d.selections);J.forEach((function(yt){var Rt;if(Ia(yt,E))if(tr(yt)){var Zt=w.readField({fieldName:yt.name.value,field:yt,variables:b.variables,from:m},b),zt=on(yt);b.path.push(zt),Zt===void 0?Ss.added(yt)||H().push(Vd(__DEV__?new Ce("Can't find field '"+yt.name.value+"' on "+(ae(m)?m.__ref+" object":"object "+JSON.stringify(m,null,2))):new Ce(6),b)):Array.isArray(Zt)?Zt=K(l.executeSubSelectedArray({field:yt,array:Zt,enclosingRef:y,context:b})):yt.selectionSet?Zt!=null&&(Zt=K(l.executeSelectionSet({selectionSet:yt.selectionSet,objectOrReference:Zt,enclosingRef:ae(Zt)?Zt:y,context:b}))):b.canonizeResults&&(Zt=l.canon.pass(Zt)),Zt!==void 0&&_.push(((Rt={})[zt]=Zt,Rt)),Vt(b.path.pop()===zt);}else {var Bt=Pa(yt,b.fragmentMap);Bt&&w.fragmentMatches(Bt,B)&&Bt.selectionSet.selections.forEach(J.add,J);}}));var tt=Fd(_);return M.result=b.canonizeResults?this.canon.admit(tt):ks(tt),this.knownResults.set(M.result,d),M},f.prototype.execSubSelectedArrayImpl=function(a){var l,d=this,m=a.field,y=a.array,b=a.enclosingRef,E=a.context;function w(D,_){return D.missing&&(l=l||[]).push.apply(l,D.missing),Vt(E.path.pop()===_),D.result}return m.selectionSet&&(y=y.filter(E.store.canRead)),y=y.map((function(D,_){return D===null?null:(E.path.push(_),Array.isArray(D)?w(d.executeSubSelectedArray({field:m,array:D,enclosingRef:b,context:E}),_):m.selectionSet?w(d.executeSelectionSet({selectionSet:m.selectionSet,objectOrReference:D,enclosingRef:ae(D)?D:b,context:E}),_):(__DEV__&&(function(M,B,H){if(!B.selectionSet){var K=new Set([H]);K.forEach((function(J){vt(J)&&(__DEV__?Vt(!ae(J),"Missing selection set for object of type "+(function(tt,yt){return ae(yt)?tt.get(yt.__ref,"__typename"):yt&&yt.__typename})(M,J)+" returned for query field "+B.name.value):Vt(!ae(J),7),Object.values(J).forEach(K.add,K));}));}})(E.store,m,D),Vt(E.path.pop()===_),D))})),{result:E.canonizeResults?this.canon.admit(y):y,missing:l}},f})(),oh=(function(){function f(a,l){this.cache=a,this.reader=l;}return f.prototype.writeToStore=function(a,l){var d=this,m=l.query,y=l.result,b=l.dataId,E=l.variables,w=l.overwrite,D=Kn(m),_=new Md;E=bt(bt({},zo(D)),E);var M={store:a,written:Object.create(null),merge:function(H,K){return _.merge(H,K)},variables:E,varString:En(E),fragmentMap:So(er(m)),overwrite:!!w,incomingById:new Map,clientOnly:false},B=this.processSelectionSet({result:y||Object.create(null),dataId:b,selectionSet:D.selectionSet,mergeTree:{map:new Map},context:M});if(!ae(B))throw __DEV__?new Ce("Could not identify object "+JSON.stringify(y)):new Ce(8);return M.incomingById.forEach((function(H,K){var J=H.fields,tt=H.mergeTree,yt=H.selections,Rt=qi(K);if(tt&&tt.map.size){var Zt=d.applyMerges(tt,Rt,J,M);if(ae(Zt))return;J=Zt;}if(__DEV__&&!M.overwrite){var zt=new Set;yt.forEach((function(Bt){tr(Bt)&&Bt.selectionSet&&zt.add(Bt.name.value);})),Object.keys(J).forEach((function(Bt){(function(qt){return zt.has(Zi(qt))})(Bt)&&!(function(qt){var $e=tt&&tt.map.get(qt);return !!($e&&$e.info&&$e.info.merge)})(Bt)&&(function(qt,$e,fe,Oe){var An=function($){var q=Oe.getFieldValue($,fe);return typeof q=="object"&&q},Mr=An(qt);if(Mr){var u=An($e);if(u&&!ae(Mr)&&!Nn(Mr,u)&&!Object.keys(Mr).every((function($){return Oe.getFieldValue(u,$)!==void 0}))){var g=Oe.getFieldValue(qt,"__typename")||Oe.getFieldValue($e,"__typename"),S=Zi(fe),k=g+"."+S;if(!Yd.has(k)){Yd.add(k);var R=[];Array.isArray(Mr)||Array.isArray(u)||[Mr,u].forEach((function($){var q=Oe.getFieldValue($,"__typename");typeof q!="string"||R.includes(q)||R.push(q);})),__DEV__&&Vt.warn("Cache data may be lost when replacing the "+S+" field of a "+g+` object.
2363
+ For more information, please visit: https://go.apollo.dev/c/docs`):new Ce(9);if(this.link=$e,this.cache=b,this.disableNetworkFetches=w||_>0,this.queryDeduplication=K,this.defaultOptions=J||{},this.typeDefs=Zt,_&&setTimeout((function(){return l.disableNetworkFetches=false}),_),this.watchQuery=this.watchQuery.bind(this),this.query=this.query.bind(this),this.mutate=this.mutate.bind(this),this.resetStore=this.resetStore.bind(this),this.reFetchObservableQueries=this.reFetchObservableQueries.bind(this),B&&typeof window=="object"&&(window.__APOLLO_CLIENT__=this),!$d&&__DEV__&&($d=true,typeof window!="undefined"&&window.document&&window.top===window.self&&!window.__APOLLO_DEVTOOLS_GLOBAL_HOOK__)){var fe=window.navigator,Oe=fe&&fe.userAgent,An=void 0;typeof Oe=="string"&&(Oe.indexOf("Chrome/")>-1?An="https://chrome.google.com/webstore/detail/apollo-client-developer-t/jdkknkkbebbapilgoeccciglkfbmbnfm":Oe.indexOf("Firefox/")>-1&&(An="https://addons.mozilla.org/en-US/firefox/addon/apollo-developer-tools/")),An&&__DEV__&&Vt.log("Download the Apollo DevTools for a better development experience: "+An);}this.version="3.4.17",this.localState=new Ll({cache:b,client:this,resolvers:Rt,fragmentMatcher:zt}),this.queryManager=new eh({cache:this.cache,link:this.link,queryDeduplication:K,ssrMode:w,clientAwareness:{name:Bt,version:qt},localState:this.localState,assumeImmutableResults:yt,onBroadcast:B?function(){l.devToolsHookCb&&l.devToolsHookCb({action:{},state:{queries:l.queryManager.getQueryStore(),mutations:l.queryManager.mutationStore||{}},dataWithOptimisticResults:l.cache.extract(true)});}:void 0});}return f.prototype.stop=function(){this.queryManager.stop();},f.prototype.watchQuery=function(a){return this.defaultOptions.watchQuery&&(a=Fa(this.defaultOptions.watchQuery,a)),!this.disableNetworkFetches||a.fetchPolicy!=="network-only"&&a.fetchPolicy!=="cache-and-network"||(a=bt(bt({},a),{fetchPolicy:"cache-first"})),this.queryManager.watchQuery(a)},f.prototype.query=function(a){return this.defaultOptions.query&&(a=Fa(this.defaultOptions.query,a)),__DEV__?Vt(a.fetchPolicy!=="cache-and-network","The cache-and-network fetchPolicy does not work with client.query, because client.query can only return a single result. Please use client.watchQuery to receive multiple results from the cache and the network, or consider using a different fetchPolicy, such as cache-first or network-only."):Vt(a.fetchPolicy!=="cache-and-network",10),this.disableNetworkFetches&&a.fetchPolicy==="network-only"&&(a=bt(bt({},a),{fetchPolicy:"cache-first"})),this.queryManager.query(a)},f.prototype.mutate=function(a){return this.defaultOptions.mutate&&(a=Fa(this.defaultOptions.mutate,a)),this.queryManager.mutate(a)},f.prototype.subscribe=function(a){return this.queryManager.startGraphQLSubscription(a)},f.prototype.readQuery=function(a,l){return l===void 0&&(l=false),this.cache.readQuery(a,l)},f.prototype.readFragment=function(a,l){return l===void 0&&(l=false),this.cache.readFragment(a,l)},f.prototype.writeQuery=function(a){this.cache.writeQuery(a),this.queryManager.broadcastQueries();},f.prototype.writeFragment=function(a){this.cache.writeFragment(a),this.queryManager.broadcastQueries();},f.prototype.__actionHookForDevTools=function(a){this.devToolsHookCb=a;},f.prototype.__requestRaw=function(a){return Ta(this.link,a)},f.prototype.resetStore=function(){var a=this;return Promise.resolve().then((function(){return a.queryManager.clearStore({discardWatches:false})})).then((function(){return Promise.all(a.resetStoreCallbacks.map((function(l){return l()})))})).then((function(){return a.reFetchObservableQueries()}))},f.prototype.clearStore=function(){var a=this;return Promise.resolve().then((function(){return a.queryManager.clearStore({discardWatches:true})})).then((function(){return Promise.all(a.clearStoreCallbacks.map((function(l){return l()})))}))},f.prototype.onResetStore=function(a){var l=this;return this.resetStoreCallbacks.push(a),function(){l.resetStoreCallbacks=l.resetStoreCallbacks.filter((function(d){return d!==a}));}},f.prototype.onClearStore=function(a){var l=this;return this.clearStoreCallbacks.push(a),function(){l.clearStoreCallbacks=l.clearStoreCallbacks.filter((function(d){return d!==a}));}},f.prototype.reFetchObservableQueries=function(a){return this.queryManager.reFetchObservableQueries(a)},f.prototype.refetchQueries=function(a){var l=this.queryManager.refetchQueries(a),d=[],m=[];l.forEach((function(b,E){d.push(E),m.push(b);}));var y=Promise.all(m);return y.queries=d,y.results=m,y.catch((function(b){__DEV__&&Vt.debug("In client.refetchQueries, Promise.all promise rejected with error "+b);})),y},f.prototype.getObservableQueries=function(a){return a===void 0&&(a="active"),this.queryManager.getObservableQueries(a)},f.prototype.extract=function(a){return this.cache.extract(a)},f.prototype.restore=function(a){return this.cache.restore(a)},f.prototype.addResolvers=function(a){this.localState.addResolvers(a);},f.prototype.setResolvers=function(a){this.localState.setResolvers(a);},f.prototype.getResolvers=function(){return this.localState.getResolvers()},f.prototype.setLocalStateFragmentMatcher=function(a){this.localState.setFragmentMatcher(a);},f.prototype.setLink=function(a){this.link=this.queryManager.link=a;},f})(),nh=(function(){function f(){this.getFragmentDoc=Hr(gs);}return f.prototype.batch=function(a){var l=typeof a.optimistic=="string"?a.optimistic:a.optimistic===false?null:void 0;this.performTransaction(a.update,l);},f.prototype.recordOptimisticTransaction=function(a,l){this.performTransaction(a,l);},f.prototype.transformDocument=function(a){return a},f.prototype.identify=function(a){},f.prototype.gc=function(){return []},f.prototype.modify=function(a){return false},f.prototype.transformForLink=function(a){return a},f.prototype.readQuery=function(a,l){return l===void 0&&(l=!!a.optimistic),this.read(bt(bt({},a),{rootId:a.id||"ROOT_QUERY",optimistic:l}))},f.prototype.readFragment=function(a,l){return l===void 0&&(l=!!a.optimistic),this.read(bt(bt({},a),{query:this.getFragmentDoc(a.fragment,a.fragmentName),rootId:a.id,optimistic:l}))},f.prototype.writeQuery=function(a){var l=a.id,d=a.data,m=ar(a,["id","data"]);return this.write(Object.assign(m,{dataId:l||"ROOT_QUERY",result:d}))},f.prototype.writeFragment=function(a){var l=a.id,d=a.data,m=a.fragment,y=a.fragmentName,b=ar(a,["id","data","fragment","fragmentName"]);return this.write(Object.assign(b,{query:this.getFragmentDoc(m,y),dataId:l,result:d}))},f})(),rh=(function(f){function a(l,d,m,y){var b=f.call(this,l)||this;return b.message=l,b.path=d,b.query=m,b.variables=y,b.__proto__=a.prototype,b}return Ve(a,f),a})(Error);function ks(f){return __DEV__&&(a=f,(l=new Set([a])).forEach((function(d){vt(d)&&(function(m){if(__DEV__&&!Object.isFrozen(m))try{Object.freeze(m);}catch(y){if(y instanceof TypeError)return null;throw y}return m})(d)===d&&Object.getOwnPropertyNames(d).forEach((function(m){vt(d[m])&&l.add(d[m]);}));}))),f;var a,l;}var fr=Object.prototype.hasOwnProperty;function hr(f,a){var l=f.__typename,d=f.id,m=f._id;if(typeof l=="string"&&(a&&(a.keyObject=d!==void 0?{id:d}:m!==void 0?{_id:m}:void 0),d===void 0&&(d=m),d!==void 0))return l+":"+(typeof d=="number"||typeof d=="string"?d:JSON.stringify(d))}var ru={dataIdFromObject:hr,addTypename:true,resultCaching:true,canonizeResults:false};function Gd(f){var a=f.canonizeResults;return a===void 0?ru.canonizeResults:a}var Fi=/^[_a-z][_0-9a-z]*/i;function Zi(f){var a=f.match(Fi);return a?a[0]:f}function Ds(f,a,l){return !!vt(a)&&(Array.isArray(a)?a.every((function(d){return Ds(f,d,l)})):f.selections.every((function(d){if(tr(d)&&Ia(d,l)){var m=on(d);return fr.call(a,m)&&(!d.selectionSet||Ds(d.selectionSet,a[m],l))}return true})))}function Mi(f){return vt(f)&&!ae(f)&&!Array.isArray(f)}var Ul=Object.create(null),Pr=function(){return Ul},iu=Object.create(null),$l=(function(){function f(a,l){var d=this;this.policies=a,this.group=l,this.data=Object.create(null),this.rootIds=Object.create(null),this.refs=Object.create(null),this.getFieldValue=function(m,y){return ks(ae(m)?d.get(m.__ref,y):m&&m[y])},this.canRead=function(m){return ae(m)?d.has(m.__ref):typeof m=="object"},this.toReference=function(m,y){if(typeof m=="string")return qi(m);if(ae(m))return m;var b=d.policies.identify(m)[0];if(b){var E=qi(b);return y&&d.merge(b,m),E}};}return f.prototype.toObject=function(){return bt({},this.data)},f.prototype.has=function(a){return this.lookup(a,true)!==void 0},f.prototype.get=function(a,l){if(this.group.depend(a,l),fr.call(this.data,a)){var d=this.data[a];if(d&&fr.call(d,l))return d[l]}return l==="__typename"&&fr.call(this.policies.rootTypenamesById,a)?this.policies.rootTypenamesById[a]:this instanceof Eo?this.parent.get(a,l):void 0},f.prototype.lookup=function(a,l){return l&&this.group.depend(a,"__exists"),fr.call(this.data,a)?this.data[a]:this instanceof Eo?this.parent.lookup(a,l):this.policies.rootTypenamesById[a]?Object.create(null):void 0},f.prototype.merge=function(a,l){var d,m=this;ae(a)&&(a=a.__ref),ae(l)&&(l=l.__ref);var y=typeof a=="string"?this.lookup(d=a):a,b=typeof l=="string"?this.lookup(d=l):l;if(b){__DEV__?Vt(typeof d=="string","store.merge expects a string ID"):Vt(typeof d=="string",1);var E=new Md(jd).merge(y,b);if(this.data[d]=E,E!==y&&(delete this.refs[d],this.group.caching)){var w=Object.create(null);y||(w.__exists=1),Object.keys(b).forEach((function(D){if(!y||y[D]!==E[D]){w[D]=1;var _=Zi(D);_===D||m.policies.hasKeyArgs(E.__typename,_)||(w[_]=1),E[D]!==void 0||m instanceof Eo||delete E[D];}})),!w.__typename||y&&y.__typename||this.policies.rootTypenamesById[d]!==E.__typename||delete w.__typename,Object.keys(w).forEach((function(D){return m.group.dirty(d,D)}));}}},f.prototype.modify=function(a,l){var d=this,m=this.lookup(a);if(m){var y=Object.create(null),b=false,E=true,w={DELETE:Ul,INVALIDATE:iu,isReference:ae,toReference:this.toReference,canRead:this.canRead,readField:function(D,_){return d.policies.readField(typeof D=="string"?{fieldName:D,from:_||qi(a)}:D,{store:d})}};if(Object.keys(m).forEach((function(D){var _=Zi(D),M=m[D];if(M!==void 0){var B=typeof l=="function"?l:l[D]||l[_];if(B){var H=B===Pr?Ul:B(ks(M),bt(bt({},w),{fieldName:_,storeFieldName:D,storage:d.getStorage(a,D)}));H===iu?d.group.dirty(a,D):(H===Ul&&(H=void 0),H!==M&&(y[D]=H,b=true,M=H));}M!==void 0&&(E=false);}})),b)return this.merge(a,y),E&&(this instanceof Eo?this.data[a]=void 0:delete this.data[a],this.group.dirty(a,"__exists")),true}return false},f.prototype.delete=function(a,l,d){var m,y=this.lookup(a);if(y){var b=this.getFieldValue(y,"__typename"),E=l&&d?this.policies.getStoreFieldName({typename:b,fieldName:l,args:d}):l;return this.modify(a,E?((m={})[E]=Pr,m):Pr)}return false},f.prototype.evict=function(a,l){var d=false;return a.id&&(fr.call(this.data,a.id)&&(d=this.delete(a.id,a.fieldName,a.args)),this instanceof Eo&&this!==l&&(d=this.parent.evict(a,l)||d),(a.fieldName||d)&&this.group.dirty(a.id,a.fieldName||"__exists")),d},f.prototype.clear=function(){this.replace(null);},f.prototype.extract=function(){var a=this,l=this.toObject(),d=[];return this.getRootIdSet().forEach((function(m){fr.call(a.policies.rootTypenamesById,m)||d.push(m);})),d.length&&(l.__META={extraRootIds:d.sort()}),l},f.prototype.replace=function(a){var l=this;if(Object.keys(this.data).forEach((function(y){a&&fr.call(a,y)||l.delete(y);})),a){var d=a.__META,m=ar(a,["__META"]);Object.keys(m).forEach((function(y){l.merge(y,m[y]);})),d&&d.extraRootIds.forEach(this.retain,this);}},f.prototype.retain=function(a){return this.rootIds[a]=(this.rootIds[a]||0)+1},f.prototype.release=function(a){if(this.rootIds[a]>0){var l=--this.rootIds[a];return l||delete this.rootIds[a],l}return 0},f.prototype.getRootIdSet=function(a){return a===void 0&&(a=new Set),Object.keys(this.rootIds).forEach(a.add,a),this instanceof Eo?this.parent.getRootIdSet(a):Object.keys(this.policies.rootTypenamesById).forEach(a.add,a),a},f.prototype.gc=function(){var a=this,l=this.getRootIdSet(),d=this.toObject();l.forEach((function(b){fr.call(d,b)&&(Object.keys(a.findChildRefIds(b)).forEach(l.add,l),delete d[b]);}));var m=Object.keys(d);if(m.length){for(var y=this;y instanceof Eo;)y=y.parent;m.forEach((function(b){return y.delete(b)}));}return m},f.prototype.findChildRefIds=function(a){if(!fr.call(this.refs,a)){var l=this.refs[a]=Object.create(null),d=this.data[a];if(!d)return l;var m=new Set([d]);m.forEach((function(y){ae(y)&&(l[y.__ref]=true),vt(y)&&Object.keys(y).forEach((function(b){var E=y[b];vt(E)&&m.add(E);}));}));}return this.refs[a]},f.prototype.makeCacheKey=function(){return this.group.keyMaker.lookupArray(arguments)},f})(),ih=(function(){function f(a,l){l===void 0&&(l=null),this.caching=a,this.parent=l,this.d=null,this.resetCaching();}return f.prototype.resetCaching=function(){this.d=this.caching?Qi():null,this.keyMaker=new At(Dt);},f.prototype.depend=function(a,l){if(this.d){this.d(Gl(a,l));var d=Zi(l);d!==l&&this.d(Gl(a,d)),this.parent&&this.parent.depend(a,l);}},f.prototype.dirty=function(a,l){this.d&&this.d.dirty(Gl(a,l),l==="__exists"?"forget":"setDirty");},f})();function Gl(f,a){return a+"#"+f}function As(f,a){Os(f)&&f.group.depend(a,"__exists");}(function(f){var a=(function(l){function d(m){var y=m.policies,b=m.resultCaching,E=b===void 0||b,w=m.seed,D=l.call(this,y,new ih(E))||this;return D.stump=new jl(D),D.storageTrie=new At(Dt),w&&D.replace(w),D}return Ve(d,l),d.prototype.addLayer=function(m,y){return this.stump.addLayer(m,y)},d.prototype.removeLayer=function(){return this},d.prototype.getStorage=function(){return this.storageTrie.lookupArray(arguments)},d})(f);f.Root=a;})($l||($l={}));var Eo=(function(f){function a(l,d,m,y){var b=f.call(this,d.policies,y)||this;return b.id=l,b.parent=d,b.replay=m,b.group=y,m(b),b}return Ve(a,f),a.prototype.addLayer=function(l,d){return new a(l,this,d,this.group)},a.prototype.removeLayer=function(l){var d=this,m=this.parent.removeLayer(l);return l===this.id?(this.group.caching&&Object.keys(this.data).forEach((function(y){var b=d.data[y],E=m.lookup(y);E?b?b!==E&&Object.keys(b).forEach((function(w){Nn(b[w],E[w])||d.group.dirty(y,w);})):(d.group.dirty(y,"__exists"),Object.keys(E).forEach((function(w){d.group.dirty(y,w);}))):d.delete(y);})),m):m===this.parent?this:m.addLayer(this.id,this.replay)},a.prototype.toObject=function(){return bt(bt({},this.parent.toObject()),this.data)},a.prototype.findChildRefIds=function(l){var d=this.parent.findChildRefIds(l);return fr.call(this.data,l)?bt(bt({},d),f.prototype.findChildRefIds.call(this,l)):d},a.prototype.getStorage=function(){for(var l=this.parent;l.parent;)l=l.parent;return l.getStorage.apply(l,arguments)},a})($l),jl=(function(f){function a(l){return f.call(this,"EntityStore.Stump",l,(function(){}),new ih(l.group.caching,l.group))||this}return Ve(a,f),a.prototype.removeLayer=function(){return this},a.prototype.merge=function(){return this.parent.merge.apply(this.parent,arguments)},a})(Eo);function jd(f,a,l){var d=f[l],m=a[l];return Nn(d,m)?d:m}function Os(f){return !!(f instanceof $l&&f.group.caching)}function Vd(f,a){return new rh(f.message,a.path.slice(),a.query,a.variables)}function ou(f){return [f.selectionSet,f.objectOrReference,f.context,f.context.canonizeResults]}var zd=(function(){function f(a){var l=this;this.knownResults=new(Dt?WeakMap:Map),this.config=vs(a,{addTypename:a.addTypename!==false,canonizeResults:Gd(a)}),this.canon=a.canon||new Ne,this.executeSelectionSet=Hr((function(d){var m,y=d.context.canonizeResults,b=ou(d);b[3]=!y;var E=(m=l.executeSelectionSet).peek.apply(m,b);return E?y?bt(bt({},E),{result:l.canon.admit(E.result)}):E:(As(d.context.store,d.enclosingRef.__ref),l.execSelectionSetImpl(d))}),{max:this.config.resultCacheMaxSize,keyArgs:ou,makeCacheKey:function(d,m,y,b){if(Os(y.store))return y.store.makeCacheKey(d,ae(m)?m.__ref:m,y.varString,b)}}),this.executeSubSelectedArray=Hr((function(d){return As(d.context.store,d.enclosingRef.__ref),l.execSubSelectedArrayImpl(d)}),{max:this.config.resultCacheMaxSize,makeCacheKey:function(d){var m=d.field,y=d.array,b=d.context;if(Os(b.store))return b.store.makeCacheKey(m,y,b.varString)}});}return f.prototype.resetCanon=function(){this.canon=new Ne;},f.prototype.diffQueryAgainstStore=function(a){var l=a.store,d=a.query,m=a.rootId,y=m===void 0?"ROOT_QUERY":m,b=a.variables,E=a.returnPartialData,w=E===void 0||E,D=a.canonizeResults,_=D===void 0?this.config.canonizeResults:D,M=this.config.cache.policies;b=bt(bt({},zo(ys(d))),b);var B=qi(y),H=this.executeSelectionSet({selectionSet:_a(d).selectionSet,objectOrReference:B,enclosingRef:B,context:{store:l,query:d,policies:M,variables:b,varString:En(b),canonizeResults:_,fragmentMap:So(er(d)),path:[]}}),K=H.missing&&H.missing.length>0;if(K&&!w)throw H.missing[0];return {result:H.result,missing:H.missing,complete:!K}},f.prototype.isFresh=function(a,l,d,m){if(Os(m.store)&&this.knownResults.get(a)===d){var y=this.executeSelectionSet.peek(d,l,m,this.canon.isKnown(a));if(y&&a===y.result)return true}return false},f.prototype.execSelectionSetImpl=function(a){var l=this,d=a.selectionSet,m=a.objectOrReference,y=a.enclosingRef,b=a.context;if(ae(m)&&!b.policies.rootTypenamesById[m.__ref]&&!b.store.has(m.__ref))return {result:this.canon.empty,missing:[Vd(__DEV__?new Ce("Dangling reference to missing "+m.__ref+" object"):new Ce(5),b)]};var E=b.variables,w=b.policies,D=b.store,_=[],M={result:null},B=D.getFieldValue(m,"__typename");function H(){return M.missing||(M.missing=[])}function K(yt){var Rt;return yt.missing&&(Rt=H()).push.apply(Rt,yt.missing),yt.result}this.config.addTypename&&typeof B=="string"&&!w.rootIdsByTypename[B]&&_.push({__typename:B});var J=new Set(d.selections);J.forEach((function(yt){var Rt;if(Ia(yt,E))if(tr(yt)){var Zt=w.readField({fieldName:yt.name.value,field:yt,variables:b.variables,from:m},b),zt=on(yt);b.path.push(zt),Zt===void 0?Ss.added(yt)||H().push(Vd(__DEV__?new Ce("Can't find field '"+yt.name.value+"' on "+(ae(m)?m.__ref+" object":"object "+JSON.stringify(m,null,2))):new Ce(6),b)):Array.isArray(Zt)?Zt=K(l.executeSubSelectedArray({field:yt,array:Zt,enclosingRef:y,context:b})):yt.selectionSet?Zt!=null&&(Zt=K(l.executeSelectionSet({selectionSet:yt.selectionSet,objectOrReference:Zt,enclosingRef:ae(Zt)?Zt:y,context:b}))):b.canonizeResults&&(Zt=l.canon.pass(Zt)),Zt!==void 0&&_.push(((Rt={})[zt]=Zt,Rt)),Vt(b.path.pop()===zt);}else {var Bt=Pa(yt,b.fragmentMap);Bt&&w.fragmentMatches(Bt,B)&&Bt.selectionSet.selections.forEach(J.add,J);}}));var tt=Fd(_);return M.result=b.canonizeResults?this.canon.admit(tt):ks(tt),this.knownResults.set(M.result,d),M},f.prototype.execSubSelectedArrayImpl=function(a){var l,d=this,m=a.field,y=a.array,b=a.enclosingRef,E=a.context;function w(D,_){return D.missing&&(l=l||[]).push.apply(l,D.missing),Vt(E.path.pop()===_),D.result}return m.selectionSet&&(y=y.filter(E.store.canRead)),y=y.map((function(D,_){return D===null?null:(E.path.push(_),Array.isArray(D)?w(d.executeSubSelectedArray({field:m,array:D,enclosingRef:b,context:E}),_):m.selectionSet?w(d.executeSelectionSet({selectionSet:m.selectionSet,objectOrReference:D,enclosingRef:ae(D)?D:b,context:E}),_):(__DEV__&&(function(M,B,H){if(!B.selectionSet){var K=new Set([H]);K.forEach((function(J){vt(J)&&(__DEV__?Vt(!ae(J),"Missing selection set for object of type "+(function(tt,yt){return ae(yt)?tt.get(yt.__ref,"__typename"):yt&&yt.__typename})(M,J)+" returned for query field "+B.name.value):Vt(!ae(J),7),Object.values(J).forEach(K.add,K));}));}})(E.store,m,D),Vt(E.path.pop()===_),D))})),{result:E.canonizeResults?this.canon.admit(y):y,missing:l}},f})(),oh=(function(){function f(a,l){this.cache=a,this.reader=l;}return f.prototype.writeToStore=function(a,l){var d=this,m=l.query,y=l.result,b=l.dataId,E=l.variables,w=l.overwrite,D=Kn(m),_=new Md;E=bt(bt({},zo(D)),E);var M={store:a,written:Object.create(null),merge:function(H,K){return _.merge(H,K)},variables:E,varString:En(E),fragmentMap:So(er(m)),overwrite:!!w,incomingById:new Map,clientOnly:false},B=this.processSelectionSet({result:y||Object.create(null),dataId:b,selectionSet:D.selectionSet,mergeTree:{map:new Map},context:M});if(!ae(B))throw __DEV__?new Ce("Could not identify object "+JSON.stringify(y)):new Ce(8);return M.incomingById.forEach((function(H,K){var J=H.fields,tt=H.mergeTree,yt=H.selections,Rt=qi(K);if(tt&&tt.map.size){var Zt=d.applyMerges(tt,Rt,J,M);if(ae(Zt))return;J=Zt;}if(__DEV__&&!M.overwrite){var zt=new Set;yt.forEach((function(Bt){tr(Bt)&&Bt.selectionSet&&zt.add(Bt.name.value);})),Object.keys(J).forEach((function(Bt){(function(qt){return zt.has(Zi(qt))})(Bt)&&!(function(qt){var $e=tt&&tt.map.get(qt);return !!($e&&$e.info&&$e.info.merge)})(Bt)&&(function(qt,$e,fe,Oe){var An=function($){var q=Oe.getFieldValue($,fe);return typeof q=="object"&&q},Mr=An(qt);if(Mr){var u=An($e);if(u&&!ae(Mr)&&!Nn(Mr,u)&&!Object.keys(Mr).every((function($){return Oe.getFieldValue(u,$)!==void 0}))){var g=Oe.getFieldValue(qt,"__typename")||Oe.getFieldValue($e,"__typename"),S=Zi(fe),k=g+"."+S;if(!Yd.has(k)){Yd.add(k);var F=[];Array.isArray(Mr)||Array.isArray(u)||[Mr,u].forEach((function($){var q=Oe.getFieldValue($,"__typename");typeof q!="string"||F.includes(q)||F.push(q);})),__DEV__&&Vt.warn("Cache data may be lost when replacing the "+S+" field of a "+g+` object.
2364
2364
 
2365
- To address this problem (which is not a bug in Apollo Client), `+(R.length?"either ensure all objects of type "+R.join(" and ")+" have an ID or a custom merge function, or ":"")+"define a custom merge function for the "+k+` field, so InMemoryCache can safely merge these objects:
2365
+ To address this problem (which is not a bug in Apollo Client), `+(F.length?"either ensure all objects of type "+F.join(" and ")+" have an ID or a custom merge function, or ":"")+"define a custom merge function for the "+k+` field, so InMemoryCache can safely merge these objects:
2366
2366
 
2367
2367
  existing: `+JSON.stringify(Mr).slice(0,1e3)+`
2368
2368
  incoming: `+JSON.stringify(u).slice(0,1e3)+`
@@ -2371,7 +2371,7 @@ For more information about these options, please refer to the documentation:
2371
2371
 
2372
2372
  * Ensuring entity objects have IDs: https://go.apollo.dev/c/generating-unique-identifiers
2373
2373
  * Defining custom merge functions: https://go.apollo.dev/c/merging-non-normalized-objects
2374
- `);}}}})(Rt,J,Bt,M.store);}));}a.merge(K,J);})),a.retain(B.__ref),B},f.prototype.processSelectionSet=function(a){var l=this,d=a.dataId,m=a.result,y=a.selectionSet,b=a.context,E=a.mergeTree,w=this.cache.policies,D=w.identify(m,y,b.fragmentMap),_=D[0],M=D[1];if(typeof(d=d||_)=="string"){var B=b.written[d]||(b.written[d]=[]),H=qi(d);if(B.indexOf(y)>=0||(B.push(y),this.reader&&this.reader.isFresh(m,H,y,b)))return H}var K=Object.create(null);M&&(K=b.merge(K,M));var J=d&&w.rootTypenamesById[d]||xa(m,y,b.fragmentMap)||d&&b.store.get(d,"__typename");typeof J=="string"&&(K.__typename=J);var tt=new Set(y.selections);if(tt.forEach((function(Rt){var Zt;if(Ia(Rt,b.variables))if(tr(Rt)){var zt=on(Rt),Bt=m[zt],qt=b.clientOnly;if(b.clientOnly=qt||!(!Rt.directives||!Rt.directives.some((function(S){return S.name.value==="client"}))),Bt!==void 0){var $e=w.getStoreFieldName({typename:J,fieldName:Rt.name.value,field:Rt,variables:b.variables}),fe=Wd(E,$e),Oe=l.processFieldValue(Bt,Rt,b,fe),An=void 0;if(Rt.selectionSet&&!(An=b.store.getFieldValue(Oe,"__typename"))&&ae(Oe)){var Mr=b.incomingById.get(Oe.__ref);An=Mr&&Mr.fields.__typename;}var u=w.getMergeFunction(J,Rt.name.value,An);u?fe.info={field:Rt,typename:J,merge:u}:qd(E,$e),K=b.merge(K,((Zt={})[$e]=Oe,Zt));}else b.clientOnly||Ss.added(Rt)||__DEV__&&Vt.error(("Missing field '"+on(Rt)+"' while writing result "+JSON.stringify(m,null,2)).substring(0,1e3));b.clientOnly=qt;}else {var g=Pa(Rt,b.fragmentMap);g&&w.fragmentMatches(g,J,m,b.variables)&&g.selectionSet.selections.forEach(tt.add,tt);}})),typeof d=="string"){var yt=b.incomingById.get(d);return yt?(yt.fields=b.merge(yt.fields,K),yt.mergeTree=Rs(yt.mergeTree,E),yt.selections.forEach(tt.add,tt),yt.selections=tt):b.incomingById.set(d,{fields:K,mergeTree:Vl(E)?void 0:E,selections:tt}),qi(d)}return K},f.prototype.processFieldValue=function(a,l,d,m){var y=this;return l.selectionSet&&a!==null?Array.isArray(a)?a.map((function(b,E){var w=y.processFieldValue(b,l,d,Wd(m,E));return qd(m,E),w})):this.processSelectionSet({result:a,selectionSet:l.selectionSet,context:d,mergeTree:m}):__DEV__?Od(a):a},f.prototype.applyMerges=function(a,l,d,m,y){var b,E=this;if(a.map.size&&!ae(d)){var w,D=Array.isArray(d)||!ae(l)&&!Mi(l)?void 0:l,_=d;D&&!y&&(y=[ae(D)?D.__ref:D]);var M=function(B,H){return Array.isArray(B)?typeof H=="number"?B[H]:void 0:m.store.getFieldValue(B,String(H))};a.map.forEach((function(B,H){var K=M(D,H),J=M(_,H);if(J!==void 0){y&&y.push(H);var tt=E.applyMerges(B,K,J,m,y);tt!==J&&(w=w||new Map).set(H,tt),y&&Vt(y.pop()===H);}})),w&&(d=Array.isArray(_)?_.slice(0):bt({},_),w.forEach((function(B,H){d[H]=B;})));}return a.info?this.cache.policies.runMergeFunction(l,d,a.info,m,y&&(b=m.store).getStorage.apply(b,y)):d},f})(),Hd=[];function Wd(f,a){var l=f.map;return l.has(a)||l.set(a,Hd.pop()||{map:new Map}),l.get(a)}function Rs(f,a){if(f===a||!a||Vl(a))return f;if(!f||Vl(f))return a;var l=f.info&&a.info?bt(bt({},f.info),a.info):f.info||a.info,d=f.map.size&&a.map.size,m={info:l,map:d?new Map:f.map.size?f.map:a.map};if(d){var y=new Set(a.map.keys());f.map.forEach((function(b,E){m.map.set(E,Rs(b,a.map.get(E))),y.delete(E);})),y.forEach((function(b){m.map.set(b,Rs(a.map.get(b),f.map.get(b)));}));}return m}function Vl(f){return !f||!(f.info||f.map.size)}function qd(f,a){var l=f.map,d=l.get(a);d&&Vl(d)&&(Hd.push(d),l.delete(a));}var Yd=new Set;function au(f){var a=Ps("stringifyForDisplay");return JSON.stringify(f,(function(l,d){return d===void 0?a:d})).split(JSON.stringify(a)).join("<undefined>")}function su(f){return f.args!==void 0?f.args:f.field?El(f.field,f.variables):null}li.setStringify(En);var Qd=function(){},lu=function(f,a){return a.fieldName},Ie=function(f,a,l){return (0, l.mergeObjects)(f,a)},ah=function(f,a){return a},Ky=(function(){function f(a){this.config=a,this.typePolicies=Object.create(null),this.toBeAdded=Object.create(null),this.supertypeMap=new Map,this.fuzzySubtypes=new Map,this.rootIdsByTypename=Object.create(null),this.rootTypenamesById=Object.create(null),this.usingPossibleTypes=false,this.config=bt({dataIdFromObject:hr},a),this.cache=this.config.cache,this.setRootTypename("Query"),this.setRootTypename("Mutation"),this.setRootTypename("Subscription"),a.possibleTypes&&this.addPossibleTypes(a.possibleTypes),a.typePolicies&&this.addTypePolicies(a.typePolicies);}return f.prototype.identify=function(a,l,d){var m=l&&d?xa(a,l,d):a.__typename;if(m===this.rootTypenamesById.ROOT_QUERY)return ["ROOT_QUERY"];for(var y,b={typename:m,selectionSet:l,fragmentMap:d},E=m&&this.getTypePolicy(m),w=E&&E.keyFn||this.config.dataIdFromObject;w;){var D=w(a,b);if(!Array.isArray(D)){y=D;break}w=lh(D);}return y=y?String(y):void 0,b.keyObject?[y,b.keyObject]:[y]},f.prototype.addTypePolicies=function(a){var l=this;Object.keys(a).forEach((function(d){var m=a[d],y=m.queryType,b=m.mutationType,E=m.subscriptionType,w=ar(m,["queryType","mutationType","subscriptionType"]);y&&l.setRootTypename("Query",d),b&&l.setRootTypename("Mutation",d),E&&l.setRootTypename("Subscription",d),fr.call(l.toBeAdded,d)?l.toBeAdded[d].push(w):l.toBeAdded[d]=[w];}));},f.prototype.updateTypePolicy=function(a,l){var d=this,m=this.getTypePolicy(a),y=l.keyFields,b=l.fields;function E(w,D){w.merge=typeof D=="function"?D:D===true?Ie:D===false?ah:w.merge;}E(m,l.merge),m.keyFn=y===false?Qd:Array.isArray(y)?lh(y):typeof y=="function"?y:m.keyFn,b&&Object.keys(b).forEach((function(w){var D=d.getFieldPolicy(a,w,true),_=b[w];if(typeof _=="function")D.read=_;else {var M=_.keyArgs,B=_.read,H=_.merge;D.keyFn=M===false?lu:Array.isArray(M)?sh(M):typeof M=="function"?M:D.keyFn,typeof B=="function"&&(D.read=B),E(D,H);}D.read&&D.merge&&(D.keyFn=D.keyFn||lu);}));},f.prototype.setRootTypename=function(a,l){l===void 0&&(l=a);var d="ROOT_"+a.toUpperCase(),m=this.rootTypenamesById[d];l!==m&&(__DEV__?Vt(!m||m===a,"Cannot change root "+a+" __typename more than once"):Vt(!m||m===a,2),m&&delete this.rootIdsByTypename[m],this.rootIdsByTypename[l]=d,this.rootTypenamesById[d]=l);},f.prototype.addPossibleTypes=function(a){var l=this;this.usingPossibleTypes=true,Object.keys(a).forEach((function(d){l.getSupertypeSet(d,true),a[d].forEach((function(m){l.getSupertypeSet(m,true).add(d);var y=m.match(Fi);y&&y[0]===m||l.fuzzySubtypes.set(m,new RegExp(m));}));}));},f.prototype.getTypePolicy=function(a){var l=this;if(!fr.call(this.typePolicies,a)){var d=this.typePolicies[a]=Object.create(null);d.fields=Object.create(null);var m=this.supertypeMap.get(a);m&&m.size&&m.forEach((function(b){var E=l.getTypePolicy(b),w=E.fields,D=ar(E,["fields"]);Object.assign(d,D),Object.assign(d.fields,w);}));}var y=this.toBeAdded[a];return y&&y.length&&y.splice(0).forEach((function(b){l.updateTypePolicy(a,b);})),this.typePolicies[a]},f.prototype.getFieldPolicy=function(a,l,d){if(a){var m=this.getTypePolicy(a).fields;return m[l]||d&&(m[l]=Object.create(null))}},f.prototype.getSupertypeSet=function(a,l){var d=this.supertypeMap.get(a);return !d&&l&&this.supertypeMap.set(a,d=new Set),d},f.prototype.fragmentMatches=function(a,l,d,m){var y=this;if(!a.typeCondition)return true;if(!l)return false;var b=a.typeCondition.name.value;if(l===b)return true;if(this.usingPossibleTypes&&this.supertypeMap.has(b))for(var E=this.getSupertypeSet(l,true),w=[E],D=function(K){var J=y.getSupertypeSet(K,false);J&&J.size&&w.indexOf(J)<0&&w.push(J);},_=!(!d||!this.fuzzySubtypes.size),M=false,B=0;B<w.length;++B){var H=w[B];if(H.has(b))return E.has(b)||(M&&__DEV__&&Vt.warn("Inferring subtype "+l+" of supertype "+b),E.add(b)),true;H.forEach(D),_&&B===w.length-1&&Ds(a.selectionSet,d,m)&&(_=false,M=true,this.fuzzySubtypes.forEach((function(K,J){var tt=l.match(K);tt&&tt[0]===l&&D(J);})));}return false},f.prototype.hasKeyArgs=function(a,l){var d=this.getFieldPolicy(a,l,false);return !(!d||!d.keyFn)},f.prototype.getStoreFieldName=function(a){var l,d=a.typename,m=a.fieldName,y=this.getFieldPolicy(d,m,false),b=y&&y.keyFn;if(b&&d)for(var E={typename:d,fieldName:m,field:a.field||null,variables:a.variables},w=su(a);b;){var D=b(w,E);if(!Array.isArray(D)){l=D||m;break}b=sh(D);}return l===void 0&&(l=a.field?(function(_,M){var B=null;_.directives&&(B={},_.directives.forEach((function(K){B[K.name.value]={},K.arguments&&K.arguments.forEach((function(J){var tt=J.name,yt=J.value;return Ue(B[K.name.value],tt,yt,M)}));})));var H=null;return _.arguments&&_.arguments.length&&(H={},_.arguments.forEach((function(K){var J=K.name,tt=K.value;return Ue(H,J,tt,M)}))),li(_.name.value,H,B)})(a.field,a.variables):li(m,su(a))),l===false?m:m===Zi(l)?l:m+":"+l},f.prototype.readField=function(a,l){var d=a.from;if(d&&(a.field||a.fieldName)){if(a.typename===void 0){var m=l.store.getFieldValue(d,"__typename");m&&(a.typename=m);}var y=this.getStoreFieldName(a),b=Zi(y),E=l.store.getFieldValue(d,y),w=this.getFieldPolicy(a.typename,b,false),D=w&&w.read;if(D){var _=Fs(this,d,a,l,l.store.getStorage(ae(d)?d.__ref:d,y));return eu.withValue(this.cache,D,[E,_])}return E}},f.prototype.getMergeFunction=function(a,l,d){var m=this.getFieldPolicy(a,l,false),y=m&&m.merge;return !y&&d&&(y=(m=this.getTypePolicy(d))&&m.merge),y},f.prototype.runMergeFunction=function(a,l,d,m,y){var b=d.field,E=d.typename,w=d.merge;return w===Ie?Kd(m.store)(a,l):w===ah?l:(m.overwrite&&(a=void 0),w(a,l,Fs(this,void 0,{typename:E,fieldName:b.name.value,field:b,variables:m.variables},m,y||Object.create(null))))},f})();function Fs(f,a,l,d,m){var y=f.getStoreFieldName(l),b=Zi(y),E=l.variables||d.variables,w=d.store,D=w.toReference,_=w.canRead;return {args:su(l),field:l.field||null,fieldName:b,storeFieldName:y,variables:E,isReference:ae,toReference:D,storage:m,cache:f.cache,canRead:_,readField:function(M,B){var H;if(typeof M=="string")H={fieldName:M,from:arguments.length>1?B:a};else {if(!vt(M))return void(__DEV__&&Vt.warn("Unexpected readField arguments: "+au(Array.from(arguments))));H=bt({},M),fr.call(M,"from")||(H.from=a);}return __DEV__&&H.from===void 0&&__DEV__&&Vt.warn("Undefined 'from' passed to readField with arguments "+au(Array.from(arguments))),H.variables===void 0&&(H.variables=E),f.readField(H,d)},mergeObjects:Kd(d.store)}}function Kd(f){return function(a,l){if(Array.isArray(a)||Array.isArray(l))throw __DEV__?new Ce("Cannot automatically merge arrays"):new Ce(3);if(vt(a)&&vt(l)){var d=f.getFieldValue(a,"__typename"),m=f.getFieldValue(l,"__typename");if(d&&m&&d!==m)return l;if(ae(a)&&Mi(l))return f.merge(a.__ref,l),a;if(Mi(a)&&ae(l))return f.merge(a,l.__ref),l;if(Mi(a)&&Mi(l))return bt(bt({},a),l)}return l}}function sh(f){return function(a,l){return a?l.fieldName+":"+JSON.stringify(Xd(a,f,false)):l.fieldName}}function lh(f){var a=new At(Dt);return function(l,d){var m;if(d.selectionSet&&d.fragmentMap){var y=a.lookupArray([d.selectionSet,d.fragmentMap]);m=y.aliasMap||(y.aliasMap=Zr(d.selectionSet,d.fragmentMap));}var b=d.keyObject=Xd(l,f,true,m);return d.typename+":"+JSON.stringify(b)}}function Zr(f,a){var l=Object.create(null),d=new Set([f]);return d.forEach((function(m){m.selections.forEach((function(y){if(tr(y)){if(y.alias){var b=y.alias.value,E=y.name.value;E!==b&&((l.aliases||(l.aliases=Object.create(null)))[E]=b);}y.selectionSet&&((l.subsets||(l.subsets=Object.create(null)))[y.name.value]=Zr(y.selectionSet,a));}else {var w=Pa(y,a);w&&d.add(w.selectionSet);}}));})),l}function Xd(f,a,l,d){var m,y,b=Object.create(null);return a.forEach((function(E){if(Array.isArray(E)){if(typeof y=="string"&&typeof m=="string"){var w=d&&d.subsets,D=w&&w[y];b[y]=Xd(f[m],E,l,D);}}else {var _=d&&d.aliases,M=_&&_[E]||E;fr.call(f,M)?b[y=E]=f[m=M]:(__DEV__?Vt(!l,"Missing field '"+M+"' while computing key fields"):Vt(!l,4),m=y=void 0);}})),b}var cu=(function(f){function a(l){l===void 0&&(l={});var d=f.call(this)||this;return d.watches=new Set,d.typenameDocumentCache=new Map,d.makeVar=Ud,d.txCount=0,d.config=(function(m){return vs(ru,m)})(l),d.addTypename=!!d.config.addTypename,d.policies=new Ky({cache:d,dataIdFromObject:d.config.dataIdFromObject,possibleTypes:d.config.possibleTypes,typePolicies:d.config.typePolicies}),d.init(),d}return Ve(a,f),a.prototype.init=function(){var l=this.data=new $l.Root({policies:this.policies,resultCaching:this.config.resultCaching});this.optimisticData=l.stump,this.resetResultCache();},a.prototype.resetResultCache=function(l){var d=this,m=this.storeReader;this.storeWriter=new oh(this,this.storeReader=new zd({cache:this,addTypename:this.addTypename,resultCacheMaxSize:this.config.resultCacheMaxSize,canonizeResults:Gd(this.config),canon:l?void 0:m&&m.canon})),this.maybeBroadcastWatch=Hr((function(y,b){return d.broadcastWatch(y,b)}),{max:this.config.resultCacheMaxSize,makeCacheKey:function(y){var b=y.optimistic?d.optimisticData:d.data;if(Os(b)){var E=y.optimistic,w=y.rootId,D=y.variables;return b.makeCacheKey(y.query,y.callback,En({optimistic:E,rootId:w,variables:D}))}}}),new Set([this.data.group,this.optimisticData.group]).forEach((function(y){return y.resetCaching()}));},a.prototype.restore=function(l){return this.init(),l&&this.data.replace(l),this},a.prototype.extract=function(l){return l===void 0&&(l=false),(l?this.optimisticData:this.data).extract()},a.prototype.read=function(l){var d=l.returnPartialData,m=d!==void 0&&d;try{return this.storeReader.diffQueryAgainstStore(bt(bt({},l),{store:l.optimistic?this.optimisticData:this.data,config:this.config,returnPartialData:m})).result||null}catch(y){if(y instanceof rh)return null;throw y}},a.prototype.write=function(l){try{return ++this.txCount,this.storeWriter.writeToStore(this.data,l)}finally{--this.txCount||l.broadcast===false||this.broadcastWatches();}},a.prototype.modify=function(l){if(fr.call(l,"id")&&!l.id)return false;var d=l.optimistic?this.optimisticData:this.data;try{return ++this.txCount,d.modify(l.id||"ROOT_QUERY",l.fields)}finally{--this.txCount||l.broadcast===false||this.broadcastWatches();}},a.prototype.diff=function(l){return this.storeReader.diffQueryAgainstStore(bt(bt({},l),{store:l.optimistic?this.optimisticData:this.data,rootId:l.id||"ROOT_QUERY",config:this.config}))},a.prototype.watch=function(l){var d,m=this;return this.watches.size||Ml(d=this).vars.forEach((function(y){return y.attachCache(d)})),this.watches.add(l),l.immediate&&this.maybeBroadcastWatch(l),function(){m.watches.delete(l)&&!m.watches.size&&th(m),m.maybeBroadcastWatch.forget(l);}},a.prototype.gc=function(l){En.reset();var d=this.optimisticData.gc();return l&&!this.txCount&&(l.resetResultCache?this.resetResultCache(l.resetResultIdentities):l.resetResultIdentities&&this.storeReader.resetCanon()),d},a.prototype.retain=function(l,d){return (d?this.optimisticData:this.data).retain(l)},a.prototype.release=function(l,d){return (d?this.optimisticData:this.data).release(l)},a.prototype.identify=function(l){return ae(l)?l.__ref:this.policies.identify(l)[0]},a.prototype.evict=function(l){if(!l.id){if(fr.call(l,"id"))return false;l=bt(bt({},l),{id:"ROOT_QUERY"});}try{return ++this.txCount,this.optimisticData.evict(l,this.data)}finally{--this.txCount||l.broadcast===false||this.broadcastWatches();}},a.prototype.reset=function(l){var d=this;return this.init(),En.reset(),l&&l.discardWatches?(this.watches.forEach((function(m){return d.maybeBroadcastWatch.forget(m)})),this.watches.clear(),th(this)):this.broadcastWatches(),Promise.resolve()},a.prototype.removeOptimistic=function(l){var d=this.optimisticData.removeLayer(l);d!==this.optimisticData&&(this.optimisticData=d,this.broadcastWatches());},a.prototype.batch=function(l){var d=this,m=l.update,y=l.optimistic,b=y===void 0||y,E=l.removeOptimistic,w=l.onWatchUpdated,D=function(M){var B=d,H=B.data,K=B.optimisticData;++d.txCount,M&&(d.data=d.optimisticData=M);try{m(d);}finally{--d.txCount,d.data=H,d.optimisticData=K;}},_=new Set;w&&!this.txCount&&this.broadcastWatches(bt(bt({},l),{onWatchUpdated:function(M){return _.add(M),false}})),typeof b=="string"?this.optimisticData=this.optimisticData.addLayer(b,D):b===false?D(this.data):D(),typeof E=="string"&&(this.optimisticData=this.optimisticData.removeLayer(E)),w&&_.size?(this.broadcastWatches(bt(bt({},l),{onWatchUpdated:function(M,B){var H=w.call(this,M,B);return H!==false&&_.delete(M),H}})),_.size&&_.forEach((function(M){return d.maybeBroadcastWatch.dirty(M)}))):this.broadcastWatches(l);},a.prototype.performTransaction=function(l,d){return this.batch({update:l,optimistic:d||d!==null})},a.prototype.transformDocument=function(l){if(this.addTypename){var d=this.typenameDocumentCache.get(l);return d||(d=Ss(l),this.typenameDocumentCache.set(l,d),this.typenameDocumentCache.set(d,d)),d}return l},a.prototype.broadcastWatches=function(l){var d=this;this.txCount||this.watches.forEach((function(m){return d.maybeBroadcastWatch(m,l)}));},a.prototype.broadcastWatch=function(l,d){var m=l.lastDiff,y=this.diff(l);d&&(l.optimistic&&typeof d.optimistic=="string"&&(y.fromOptimisticTransaction=true),d.onWatchUpdated&&d.onWatchUpdated.call(this,l,y,m)===false)||m&&Nn(m.result,y.result)||l.callback(l.lastDiff=y,m);},a})(nh);let Zd=JSON.parse('{"g":{"BillingCredentials":["StripeCheckoutCredentials","ZuoraCheckoutCredentials"],"Credentials":["Auth0Credentials","AwsMarketplaceCredentials","BigQueryCredentials","HubspotCredentials","OpenFGACredentials","SalesforceCredentials","SnowflakeCredentials","StripeCredentials","ZuoraCredentials"],"PaymentMethodForm":["StripePaymentMethodForm","ZuoraPaymentMethodForm"],"ResetPeriodConfiguration":["MonthlyResetPeriodConfig","WeeklyResetPeriodConfig","YearlyResetPeriodConfig"],"ScheduleVariables":["AddonChangeVariables","AddonPriceOverrideChangeVariables","BillingPeriodChangeVariables","CouponChangeVariables","DowngradeChangeVariables","PlanChangeVariables","PlanPriceOverrideChangeVariables","UnitAmountChangeVariables"],"SyncRevisionData":["SyncRevisionBillingData","SyncRevisionMarketplaceData","SyncRevisionPriceBillingData"]}}');var ch=(function(){function f(a,l,d,m){var y=this;this.operation=a,this.nextLink=l,this.delayFor=d,this.retryIf=m,this.retryCount=0,this.values=[],this.complete=false,this.canceled=false,this.observers=[],this.currentSubscription=null,this.onNext=function(b){y.values.push(b);for(var E=0,w=y.observers;E<w.length;E++){var D=w[E];D&&D.next(b);}},this.onComplete=function(){y.complete=true;for(var b=0,E=y.observers;b<E.length;b++){var w=E[b];w&&w.complete();}},this.onError=function(b){return sr(y,void 0,void 0,(function(){var E,w,D;return Jn(this,(function(_){switch(_.label){case 0:return this.retryCount+=1,[4,this.retryIf(this.retryCount,this.operation,b)];case 1:if(_.sent())return this.scheduleRetry(this.delayFor(this.retryCount,this.operation,b)),[2];for(this.error=b,E=0,w=this.observers;E<w.length;E++)(D=w[E])&&D.error(b);return [2]}}))}))};}return f.prototype.subscribe=function(a){if(this.canceled)throw new Error("Subscribing to a retryable link that was canceled is not supported");this.observers.push(a);for(var l=0,d=this.values;l<d.length;l++){var m=d[l];a.next(m);}this.complete?a.complete():this.error&&a.error(this.error);},f.prototype.unsubscribe=function(a){var l=this.observers.indexOf(a);if(l<0)throw new Error("RetryLink BUG! Attempting to unsubscribe unknown observer!");this.observers[l]=null,this.observers.every((function(d){return d===null}))&&this.cancel();},f.prototype.start=function(){this.currentSubscription||this.try();},f.prototype.cancel=function(){this.currentSubscription&&this.currentSubscription.unsubscribe(),clearTimeout(this.timerId),this.timerId=void 0,this.currentSubscription=null,this.canceled=true;},f.prototype.try=function(){this.currentSubscription=this.nextLink(this.operation).subscribe({next:this.onNext,error:this.onError,complete:this.onComplete});},f.prototype.scheduleRetry=function(a){var l=this;if(this.timerId)throw new Error("RetryLink BUG! Encountered overlapping retries");this.timerId=setTimeout((function(){l.timerId=void 0,l.try();}),a);},f})(),uh=(function(f){function a(l){var d=f.call(this)||this,m=l||{},y=m.attempts,b=m.delay;return d.delayFor=typeof b=="function"?b:(function(E){var w=E||{},D=w.initial,_=D===void 0?300:D,M=w.jitter,B=M===void 0||M,H=w.max,K=H===void 0?1/0:H,J=B?_:_/2;return function(tt){var yt=Math.min(K,J*Math.pow(2,tt));return B&&(yt=Math.random()*yt),yt}})(b),d.retryIf=typeof y=="function"?y:(function(E){var w=E||{},D=w.retryIf,_=w.max,M=_===void 0?5:_;return function(B,H,K){return !(B>=M)&&(D?D(K,H):!!K)}})(y),d}return Ve(a,f),a.prototype.request=function(l,d){var m=new ch(l,d,this.delayFor,this.retryIf);return m.start(),new Je((function(y){return m.subscribe(y),function(){m.unsubscribe(y);}}))},a})(Tt),Jr=n(4147),Zo=function(f){return !!f&&![500,400].includes(f.statusCode)};let Jd=(function(){function f(a,l){this.client=a,this.edgeApiClient=l;}return f.prototype.getEntitlements=function(a,l,d){return l===void 0&&(l=false),m=this,y=void 0,E=function(){return (function(w,D){var _,M,B,H,K={label:0,sent:function(){if(1&B[0])throw B[1];return B[1]},trys:[],ops:[]};return H={next:J(0),throw:J(1),return:J(2)},typeof Symbol=="function"&&(H[Symbol.iterator]=function(){return this}),H;function J(tt){return function(yt){return (function(Rt){if(_)throw new TypeError("Generator is already executing.");for(;K;)try{if(_=1,M&&(B=2&Rt[0]?M.return:Rt[0]?M.throw||((B=M.return)&&B.call(M),0):M.next)&&!(B=B.call(M,Rt[1])).done)return B;switch(M=0,B&&(Rt=[2&Rt[0],B.value]),Rt[0]){case 0:case 1:B=Rt;break;case 4:return K.label++,{value:Rt[1],done:!1};case 5:K.label++,M=Rt[1],Rt=[0];continue;case 7:Rt=K.ops.pop(),K.trys.pop();continue;default:if(!((B=(B=K.trys).length>0&&B[B.length-1])||Rt[0]!==6&&Rt[0]!==2)){K=0;continue}if(Rt[0]===3&&(!B||Rt[1]>B[0]&&Rt[1]<B[3])){K.label=Rt[1];break}if(Rt[0]===6&&K.label<B[1]){K.label=B[1],B=Rt;break}if(B&&K.label<B[2]){K.label=B[2],K.ops.push(Rt);break}B[2]&&K.ops.pop(),K.trys.pop();continue}Rt=D.call(w,K);}catch(Zt){Rt=[6,Zt],M=0;}finally{_=B=0;}if(5&Rt[0])throw Rt[1];return {value:Rt[0]?Rt[1]:void 0,done:true}})([tt,yt])}}})(this,(function(w){return this.edgeApiClient&&!l?[2,this.edgeApiClient.getEntitlements(a,d)]:[2,this.client.query({query:h.roX,variables:{query:{customerId:a,resourceId:d}},fetchPolicy:"no-cache"})]}))},new((b=void 0)||(b=Promise))((function(w,D){function _(H){try{B(E.next(H));}catch(K){D(K);}}function M(H){try{B(E.throw(H));}catch(K){D(K);}}function B(H){var K;H.done?w(H.value):(K=H.value,K instanceof b?K:new b((function(J){J(K);}))).then(_,M);}B((E=E.apply(m,y||[])).next());}));var m,y,b,E;},f})();var dh=n(5161),Ji=n.n(dh),ph=n(7557),uu=n.n(ph),fh=n(9704),tp=n.n(fh),zl=function(f){return f?new Date(f):void 0},Xe=function(){return Xe=Object.assign||function(f){for(var a,l=1,d=arguments.length;l<d;l++)for(var m in a=arguments[l])Object.prototype.hasOwnProperty.call(a,m)&&(f[m]=a[m]);return f},Xe.apply(this,arguments)},hh=(function(){function f(){var a=this;this.mapApplySubscriptionResults=function(l){var d=l.applySubscription.subscription;return {subscription:d?a.mapSubscription(d):void 0}},this.mapSlimCustomer=function(l){return {id:l.refId,name:l.name||void 0,email:l.email||void 0,billingId:l.billingId||void 0,createdAt:new Date(l.createdAt),updatedAt:new Date(l.updatedAt),metadata:l.additionalMetaData,awsMarketplaceCustomerId:l.awsMarketplaceCustomerId}};}return f.prototype.mapBooleanEntitlement=function(a,l){return {isFallback:false,hasAccess:l.hasAccess,accessDeniedReason:l.accessDeniedReason,feature:a.calculatedEntitlement.feature?Xe(Xe({},a.calculatedEntitlement.feature),{isMetered:false}):void 0}},f.prototype.mapNumericEntitlement=function(a,l){var d=a.calculatedEntitlement,m=d.hasUnlimitedUsage,y=d.usageLimit;return {isFallback:false,hasAccess:l.hasAccess,accessDeniedReason:l.accessDeniedReason,isUnlimited:m,value:y!=null?y:void 0,feature:a.calculatedEntitlement.feature?Xe(Xe({},a.calculatedEntitlement.feature),{isMetered:false}):void 0}},f.prototype.mapMeteredEntitlement=function(a,l,d){var m=a.calculatedEntitlement,y=m.hasUnlimitedUsage,b=m.usageLimit,E=m.feature,w=a.featureUsage,D=w.currentUsage,_=w.resetPeriod,M=w.usagePeriodAnchor,B=w.usagePeriodStart,H=w.usagePeriodEnd,K=null;return E&&E.featureType===h.Tex.Number&&E.meterType===h.puT.Incremental&&_&&H&&(K={nextResetDate:H,resetPeriod:_}),{isFallback:false,hasAccess:l.hasAccess,accessDeniedReason:l.accessDeniedReason,isUnlimited:y,usageLimit:b!=null?b:void 0,currentUsage:D,requestedUsage:d||0,resetPeriod:_!=null?_:void 0,usagePeriodAnchor:M,usagePeriodStart:B,usagePeriodEnd:H,resetSettings:K||void 0,feature:a.calculatedEntitlement.feature?Xe(Xe({},a.calculatedEntitlement.feature),{meterType:a.calculatedEntitlement.feature.meterType||void 0,isMetered:true}):void 0}},f.prototype.mapEnumEntitlement=function(a,l,d){return {isFallback:false,hasAccess:l.hasAccess,accessDeniedReason:l.accessDeniedReason,feature:a.calculatedEntitlement.feature?Xe(Xe({},a.calculatedEntitlement.feature),{isMetered:false}):void 0,enumValues:a.calculatedEntitlement.enumValues||[],requestedValues:d}},f.prototype.mapEntitlement=function(a,l,d){var m=a.calculatedEntitlement;if(!m.feature)return this.mapBooleanEntitlement(a,l);var y=m.feature,b=y.featureType,E=y.meterType,w=b===h.Tex.Number&&(E===h.puT.Incremental||E===h.puT.Fluctuating);switch(b){case h.Tex.Boolean:return this.mapBooleanEntitlement(a,l);case h.Tex.Enum:return this.mapEnumEntitlement(a,l);case h.Tex.Number:return w?this.mapMeteredEntitlement(a,l,d):this.mapNumericEntitlement(a,l)}},f.prototype.mapCachedEntitlement=function(a){var l;return a.feature&&(l={id:a.feature.refId,featureType:a.feature.featureType,meterType:a.feature.meterType||void 0,units:a.feature.featureUnits||void 0,unitsPlural:a.feature.featureUnitsPlural||void 0,displayName:a.feature.displayName,description:a.feature.description||""}),{calculatedEntitlement:{usageLimit:a.usageLimit,hasUnlimitedUsage:a.hasUnlimitedUsage,hasSoftLimit:!!a.hasSoftLimit,accessDeniedReason:a.accessDeniedReason||void 0,feature:l,enumValues:a.enumValues||[]},featureUsage:{resetPeriod:a.resetPeriod,resetPeriodConfiguration:a.resetPeriodConfiguration,currentUsage:a.currentUsage||0,usagePeriodAnchor:zl(a.usagePeriodAnchor),usagePeriodStart:zl(a.usagePeriodStart),usagePeriodEnd:zl(a.usagePeriodEnd)}}},f.prototype.mapCachedEntitlements=function(a){var l=this;return new Map(a.map((function(d){var m;return [((m=d.feature)===null||m===void 0?void 0:m.refId)||"",l.mapCachedEntitlement(d)]})))},f.prototype.mapPlans=function(a){var l=this;return ((a==null?void 0:a.paywall.plans)||[]).map((function(d,m){return l.mapPlan(d,m)}))},f.prototype.mapPaywall=function(a){var l=this.mapPlans(a),d=a==null?void 0:a.paywall.configuration,m=!(a!=null&&a.paywall.resource)&&(a==null?void 0:a.paywall.activeSubscriptions)||[];return {plans:l,configuration:d,customer:a!=null&&a.paywall.customer?this.mapCustomer(a==null?void 0:a.paywall.customer,m):null,resource:a!=null&&a.paywall.resource?this.mapResource(a==null?void 0:a.paywall.resource):null,activeSubscriptions:a!=null&&a.paywall.activeSubscriptions?this.mapSubscriptions(a==null?void 0:a.paywall.activeSubscriptions):null,currency:a.paywall.currency,paywallCalculatedPricePoints:a.paywall.paywallCalculatedPricePoints}},f.prototype.mapMockPlans=function(a){var l=this;return {plans:((a==null?void 0:a.mockPaywall.plans)||[]).map((function(d,m){return l.mapPlan(d,m)})),configuration:a.mockPaywall.configuration,customer:null,resource:null,activeSubscriptions:null,currency:{code:h.Fa6.Usd,symbol:"$"}}},f.prototype.mapCoupons=function(a){var l=this;return a.coupons.edges.map((function(d){return d.node})).map((function(d){return l.mapCoupon(d)}))},f.prototype.mapResource=function(a){return {id:a.resourceId}},f.prototype.mapCustomerPortal=function(a){var l=a.resource?this.mapResource(a.resource):null;return Xe(Xe({},a),{resource:l})},f.prototype.mapCheckoutState=function(a){var l=a.configuration,d=a.customer,m=a.plan,y=a.billingIntegration,b=a.resource,E=a.activeSubscription;return {setupSecret:a.setupSecret,configuration:l,customer:this.mapCustomer(d,E?[E]:[]),plan:this.mapPlan(m),resource:b?this.mapResource(b):null,billingIntegration:y,activeSubscription:E?this.mapSubscription(E):null}},f.prototype.mapCustomer=function(a,l){var d,m,y=this;return new I({id:a.refId,name:a.name||void 0,email:a.email||void 0,createdAt:new Date(a.createdAt),updatedAt:new Date(a.updatedAt),hasPaymentMethod:a.hasPaymentMethod,subscriptions:Ji()(l,(function(b){return y.mapSubscription(b)})),promotionalEntitlements:Ji()(a.promotionalEntitlements,(function(b){return y.mapPromotionalEntitlement(b)})),metadata:a.additionalMetaData,paymentMethodDetails:this.mapPaymentDetails(a),trialedPlans:((d=a.trialedPlans)===null||d===void 0?void 0:d.map((function(b){return {productId:b.productRefId,planId:b.planRefId}})))||void 0,eligibleForTrial:(m=a.eligibleForTrial)===null||m===void 0?void 0:m.map((function(b){return {productId:b.productRefId,eligible:b.eligible}})),experimentInfo:uu()(a.experimentInfo,"__typename")})},f.prototype.mapPaymentDetails=function(a){var l=a.defaultPaymentExpirationYear,d=a.defaultPaymentExpirationMonth,m=a.defaultPaymentMethodLast4Digits;if(tp()([m,d,l],(function(y){return y})))return {expirationMonth:d,expirationYear:l,last4Digits:m}},f.prototype.mapPriceWithTotalPrice=function(a,l,d){var m=a.feature,y=a.tiersMode,b=a.tiers,E=a.billingModel,w=a.billingPeriod,D=a.blockSize,_={pricingModel:E,billingPeriod:w,amount:l.total.amount,grossAmount:l.subTotal.amount,currency:this.getPriceCurrency(a),tiersMode:y,tiers:b,isTieredPrice:!!y,blockSize:D};return m&&(_.feature={featureId:m.refId,displayName:m.displayName,units:m.featureUnits,unitsPlural:m.featureUnitsPlural,unitQuantity:d}),_},f.prototype.mapPrice=function(a,l){var d=a.feature,m=a.price,y=a.tiers,b=a.tiersMode,E=a.billingId,w=a.billingModel,D=a.billingPeriod,_=a.minUnitQuantity,M=a.maxUnitQuantity,B=a.billingCountryCode,H=a.blockSize,K={pricingModel:w,billingPeriod:D,billingId:E,amount:m?m.amount:null,currency:this.getPriceCurrency(a),tiersMode:b,tiers:y,isTieredPrice:!!b,minUnitQuantity:_,maxUnitQuantity:M,billingCountryCode:B,blockSize:H,creditRate:a.creditRate?{amount:a.creditRate.amount}:null};return d&&(K.feature={featureId:d.refId,displayName:d.displayName,units:d.featureUnits,unitsPlural:d.featureUnitsPlural,unitQuantity:l}),K},f.prototype.mapPlan=function(a,l){var d=this;return l===void 0&&(l=0),{id:a.refId,order:l,displayName:a.displayName,description:a.description,billingId:a.billingId,basePlan:a.basePlan?{id:a.basePlan.refId,displayName:a.basePlan.displayName}:void 0,entitlements:Ji()(a.entitlements,(function(m){return d.mapPackageEntitlement(m)})),inheritedEntitlements:Ji()(a.inheritedEntitlements,(function(m){return d.mapPackageEntitlement(m)})),pricePoints:Ji()(a.prices,(function(m){return d.mapPrice(m)})),pricingType:a.pricingType,defaultTrialConfig:this.mapDefaultTrialConfig(a.defaultTrialConfig),compatibleAddons:this.mapCompatibleAddons(a),compatiblePackageGroups:this.mapCompatiblePackageGroups(a),product:{id:a.product.refId,displayName:a.product.displayName,description:a.product.description,metadata:a.product.additionalMetaData},metadata:a.additionalMetaData}},f.prototype.mapCompatibleAddons=function(a){var l=this;if(a.pricingType===h._HY.Free||!a.compatibleAddons)return [];var d=a.compatibleAddons;return (a.pricingType===h._HY.Paid?d.filter((function(m){return m.pricingType===h._HY.Paid})):d).map((function(m){return l.mapAddon(m)}))},f.prototype.mapDefaultTrialConfig=function(a){if(a)return {duration:a==null?void 0:a.duration,units:a==null?void 0:a.units,budget:a.budget?{limit:a.budget.limit}:void 0}},f.prototype.mapPackageEntitlement=function(a){var l=a.feature;return l?{usageLimit:a.usageLimit||0,feature:{id:l.refId,featureType:l.featureType,description:l.description||"",meterType:l.meterType||void 0,units:l.featureUnits||void 0,unitsPlural:l.featureUnitsPlural||void 0,displayName:l.displayName,isMetered:l.meterType===h.puT.Fluctuating||l.meterType===h.puT.Incremental,metadata:l.additionalMetaData},isCustom:a.isCustom||void 0,hasUnlimitedUsage:a.hasUnlimitedUsage,resetPeriod:a.resetPeriod,hiddenFromWidgets:a.hiddenFromWidgets,displayNameOverride:a.displayNameOverride,enumValues:a.enumValues,isGranted:a.isGranted}:{usageLimit:a.usageLimit||0,hasUnlimitedUsage:a.hasUnlimitedUsage,resetPeriod:a.resetPeriod,isGranted:a.isGranted}},f.prototype.mapPromotionalEntitlement=function(a){var l=a.feature;return {status:a.status,usageLimit:a.usageLimit||0,feature:{id:l.refId,displayName:l.displayName,description:l.description||"",featureType:l.featureType,meterType:l.meterType||void 0,units:l.featureUnits||void 0,unitsPlural:l.featureUnitsPlural||void 0,isMetered:l.meterType===h.puT.Fluctuating||l.meterType===h.puT.Incremental},hasUnlimitedUsage:a.hasUnlimitedUsage,expiresAt:a.endDate,hasExpirationDate:!!a.endDate,isVisible:a.isVisible}},f.prototype.mapSubscription=function(a){var l,d,m=this,y=a.totalPrice,b=(a.prices||[])[0];return {id:a.subscriptionId,billingId:a.billingId||void 0,resourceId:(l=a.resource)===null||l===void 0?void 0:l.resourceId,payingCustomer:a.payingCustomer?this.mapSlimCustomer(a.payingCustomer):null,status:a.status,currentBillingPeriodEnd:this.mapDate(a.currentBillingPeriodEnd),plan:this.mapPlan(a.plan),prices:a.prices?a.prices.filter((function(E){return E.price!==null})).map((function(E){return m.mapPrice(E.price,E.usageLimit)})):[],totalPrice:y,price:b&&y&&b.price?this.mapPriceWithTotalPrice(b.price,y,b.usageLimit):null,pricingType:a.pricingType,addons:((d=a.addons)===null||d===void 0?void 0:d.map((function(E){var w=E.quantity,D=E.addon;return {quantity:w,addon:m.mapAddon(D)}})))||[],startDate:a.startDate,endDate:this.mapDate(a.endDate),trialEndDate:this.mapDate(a.trialEndDate),cancellationDate:this.mapDate(a.cancellationDate),effectiveEndDate:this.mapDate(a.effectiveEndDate),metadata:a.additionalMetaData,experimentInfo:uu()(a.experimentInfo,"__typename"),scheduledUpdates:a.scheduledUpdates||[],futureUpdates:a.futureUpdates||[],latestInvoice:this.mapLatestInvoice(a.latestInvoice),paymentCollection:a.paymentCollection,paymentCollectionMethod:a.paymentCollectionMethod||void 0}},f.prototype.mapLatestInvoice=function(a){return a?Xe(Xe({},a),{createdAt:this.mapDate(a.createdAt),updatedAt:this.mapDate(a.updatedAt)}):void 0},f.prototype.mapDate=function(a){return a?new Date(a):void 0},f.prototype.mapAddon=function(a){var l,d=this;return {hiddenFromWidgets:a.hiddenFromWidgets,id:a.refId,displayName:a.displayName,description:a.description||"",billingId:a.billingId,entitlements:Ji()(a.entitlements,(function(m){return d.mapPackageEntitlement(m)})),pricePoints:Ji()(a.prices,(function(m){return d.mapPrice(m)})),pricingType:a.pricingType,dependencies:((l=a.dependencies)===null||l===void 0?void 0:l.map((function(m){return d.mapDependencyAddon(m)})))||[],metadata:a.additionalMetaData}},f.prototype.mapTaxFields=function(a){return a!=null&&a.tax&&(a!=null&&a.taxDetails)?{tax:this.mapMoney(a.tax),taxDetails:{displayName:a.taxDetails.displayName,percentage:a.taxDetails.percentage,inclusive:a.taxDetails.inclusive}}:{}},f.prototype.mapSubscriptionPreview=function(a){var l=a.subscription,d=a.proration,m=a.billingPeriodRange,y=a.credits;return Xe(Xe(Xe({total:this.mapMoney(a.total),totalExcludingTax:this.mapMoney(a.totalExcludingTax),subTotal:this.mapMoney(a.subTotal),discountAmount:a.discountAmount?this.mapMoney(a.discountAmount):void 0},this.mapTaxFields(a)),a.discount?{discount:this.mapDiscount(a.discount)}:{}),{billingPeriodRange:{start:m.start&&new Date(m.start),end:m.end&&new Date(m.end)},proration:d?{credit:this.mapMoney(d.credit),debit:this.mapMoney(d.debit),netAmount:this.mapMoney(d.netAmount),prorationDate:new Date(d.prorationDate)}:void 0,subscription:l?Xe(Xe({total:this.mapMoney(l.total),totalExcludingTax:this.mapMoney(l.totalExcludingTax),subTotal:this.mapMoney(l.subTotal),discountAmount:l.discountAmount?this.mapMoney(l.discountAmount):void 0},l.discount?{discount:this.mapDiscount(l.discount)}:{}),this.mapTaxFields(l)):void 0,isPlanDowngrade:!!a.isPlanDowngrade,hasScheduledUpdates:!!a.hasScheduledUpdates,credits:y?{initial:this.mapMoney(y.initial),used:this.mapMoney(y.used),remaining:this.mapMoney(y.remaining)}:void 0})},f.prototype.mapCredits=function(a){return {initial:this.mapMoney(a.initial),used:this.mapMoney(a.used),remaining:this.mapMoney(a.remaining)}},f.prototype.mapSubscriptionPreviewV2=function(a){var l=a.immediateInvoice,d=a.recurringInvoice,m=a.billingPeriodRange,y=a.hasScheduledUpdates,b=a.isPlanDowngrade;return {immediateInvoice:Xe(Xe({},this.mapSubscriptionPreviewInvoice(l)),{proration:l.proration?{credit:this.mapMoney(l.proration.credit),debit:this.mapMoney(l.proration.debit),netAmount:this.mapMoney(l.proration.netAmount),prorationDate:new Date(l.proration.prorationDate),hasProrations:l.proration.hasProrations||void 0}:void 0,credits:l.credits?this.mapCredits(l.credits):void 0}),recurringInvoice:d?Xe({},this.mapSubscriptionPreviewInvoice(d)):void 0,billingPeriodRange:{start:m.start&&new Date(m.start),end:m.end&&new Date(m.end)},isPlanDowngrade:!!b,hasScheduledUpdates:!!y}},f.prototype.mapSubscriptionPreviewInvoice=function(a){return Xe(Xe({total:this.mapMoney(a.total),subTotal:this.mapMoney(a.subTotal),totalExcludingTax:this.mapMoney(a.totalExcludingTax),discount:a.discount?this.mapMoney(a.discount):void 0},a.discountDetails?{discountDetails:this.mapDiscount(a.discountDetails)}:{}),this.mapTaxFields(a))},f.prototype.mapDiscount=function(a){var l=a.name,d=a.type,m=a.value,y=a.durationType,b=a.durationInMonths;return Xe({name:l,type:d,value:m,durationType:y},b?{durationInMonths:b}:{})},f.prototype.mapMoney=function(a){return {amount:a.amount,currency:a.currency}},f.prototype.mapCoupon=function(a){return {id:a.refId,name:a.name,description:a.description,metadata:a.additionalMetaData,discountValue:a.discountValue,percentOff:a.percentOff,amountsOff:a.amountsOff}},f.prototype.mapSubscriptions=function(a){var l=this;return a.map((function(d){return l.mapSubscription(d)}))},f.prototype.mapUsageHistory=function(a){return a.usageMeasurements.map((function(l){var d=l.date,m=l.value,y=l.isResetPoint;return {date:new Date(d),value:m,isResetPoint:!!y}}))},f.prototype.getPriceCurrency=function(a){var l,d,m=a.price,y=a.tiers;return (m==null?void 0:m.currency)||((l=y==null?void 0:y[0].unitPrice)===null||l===void 0?void 0:l.currency)||((d=y==null?void 0:y[0].flatPrice)===null||d===void 0?void 0:d.currency)||h.Fa6.Usd},f.prototype.mapCompatiblePackageGroups=function(a){var l=this;return a.pricingType!==h._HY.Free&&a.compatiblePackageGroups?a.compatiblePackageGroups.map((function(d){var m=d.packageGroupId,y=d.displayName,b=d.options,E=d.addons;return {packageGroupId:m,displayName:y,addons:(E==null?void 0:E.map((function(w){return l.mapAddon(w)})))||[],options:{minItems:(b==null?void 0:b.minItems)||void 0,freeItems:(b==null?void 0:b.freeItems)||void 0}}})):[]},f.prototype.mapDependencyAddon=function(a){return {refId:a.refId,displayName:a.displayName,description:a.description||void 0}},f})();let Jo=function(f,a){this.calculatedEntitlement=f,this.featureUsage=a;};var Ms=(function(){function f(){}return f.decideEntitlementPolicy=function(a,l,d){var m,y;if(l===void 0&&(l=0),d===void 0&&(d=[]),!a||!a.calculatedEntitlement.feature)return {hasAccess:false,accessDeniedReason:h.fEx.NoFeatureEntitlementInSubscription};if(a.calculatedEntitlement.accessDeniedReason)return {hasAccess:false,accessDeniedReason:a.calculatedEntitlement.accessDeniedReason};switch(a.calculatedEntitlement.feature.featureType){case h.Tex.Boolean:return {hasAccess:true};case h.Tex.Enum:var b=(0, F.difference)(d,a.calculatedEntitlement.enumValues||[]);return (0, F.isEmpty)(b)?{hasAccess:true}:{hasAccess:false,accessDeniedReason:h.fEx.RequestedValuesMismatch};case h.Tex.Number:if(((m=a.calculatedEntitlement.feature)===null||m===void 0?void 0:m.meterType)===h.puT.None)return {hasAccess:true};if(a.calculatedEntitlement.hasUnlimitedUsage||a.calculatedEntitlement.hasSoftLimit)return {hasAccess:true};var E=((y=a.calculatedEntitlement)===null||y===void 0?void 0:y.usageLimit)||0;return a.featureUsage.currentUsage+l<=E?{hasAccess:true}:{hasAccess:false,accessDeniedReason:h.fEx.RequestedUsageExceedingLimit}}},f})(),mh=n(7484),du=n.n(mh),ta,gh=[h.puT.Incremental,h.puT.Fluctuating],ti=function(){return ti=Object.assign||function(f){for(var a,l=1,d=arguments.length;l<d;l++)for(var m in a=arguments[l])Object.prototype.hasOwnProperty.call(a,m)&&(f[m]=a[m]);return f},ti.apply(this,arguments)},Ns=function(f,a,l,d){return new(l||(l=Promise))((function(m,y){function b(D){try{w(d.next(D));}catch(_){y(_);}}function E(D){try{w(d.throw(D));}catch(_){y(_);}}function w(D){var _;D.done?m(D.value):(_=D.value,_ instanceof l?_:new l((function(M){M(_);}))).then(b,E);}w((d=d.apply(f,[])).next());}))},mr=function(f,a){var l,d,m,y,b={label:0,sent:function(){if(1&m[0])throw m[1];return m[1]},trys:[],ops:[]};return y={next:E(0),throw:E(1),return:E(2)},typeof Symbol=="function"&&(y[Symbol.iterator]=function(){return this}),y;function E(w){return function(D){return (function(_){if(l)throw new TypeError("Generator is already executing.");for(;b;)try{if(l=1,d&&(m=2&_[0]?d.return:_[0]?d.throw||((m=d.return)&&m.call(d),0):d.next)&&!(m=m.call(d,_[1])).done)return m;switch(d=0,m&&(_=[2&_[0],m.value]),_[0]){case 0:case 1:m=_;break;case 4:return b.label++,{value:_[1],done:!1};case 5:b.label++,d=_[1],_=[0];continue;case 7:_=b.ops.pop(),b.trys.pop();continue;default:if(!((m=(m=b.trys).length>0&&m[m.length-1])||_[0]!==6&&_[0]!==2)){b=0;continue}if(_[0]===3&&(!m||_[1]>m[0]&&_[1]<m[3])){b.label=_[1];break}if(_[0]===6&&b.label<m[1]){b.label=m[1],m=_;break}if(m&&b.label<m[2]){b.label=m[2],b.ops.push(_);break}m[2]&&b.ops.pop(),b.trys.pop();continue}_=a.call(f,b);}catch(M){_=[6,M],d=0;}finally{l=m=0;}if(5&_[0])throw _[1];return {value:_[0]?_[1]:void 0,done:true}})([w,D])}}},fi=(function(){function f(a,l,d,m,y,b,E){this.customerId=a,this.resourceId=l,this.cacheService=d,this.loggerService=b,this.onEntitlementsUpdated=E,this.modelMapper=new hh,this.loadingEntitlements=null,this.entitlementsApi=new Jd(m,y);}return f.prototype.refresh=function(){return Ns(this,void 0,void 0,(function(){return mr(this,(function(a){switch(a.label){case 0:return [4,this.loadEntitlements(true)];case 1:return a.sent(),[2]}}))}))},Object.defineProperty(f.prototype,"isInitialized",{get:function(){return this.cacheService.isLoaded()},enumerable:false,configurable:true}),f.prototype.getBooleanEntitlement=function(a,l,d){var m=this.getEntitlement(a),y=Ms.decideEntitlementPolicy(m);return m!=null&&m.calculatedEntitlement.feature&&m.calculatedEntitlement.feature.featureType!==h.Tex.Boolean?l:m?this.modelMapper.mapBooleanEntitlement(m,y):ti(ti({},y),{isFallback:false})},f.prototype.getNumericEntitlement=function(a,l,d){var m,y=this.getEntitlement(a),b=Ms.decideEntitlementPolicy(y);return y!=null&&y.calculatedEntitlement.feature&&((m=y.calculatedEntitlement.feature)===null||m===void 0?void 0:m.featureType)!==h.Tex.Number?l:y?this.modelMapper.mapNumericEntitlement(y,b):ti(ti({},b),{isFallback:false,isUnlimited:false})},f.prototype.getMeteredEntitlement=function(a,l,d){var m,y,b=d==null?void 0:d.requestedUsage,E=this.getEntitlement(a),w=this.handleUsagePeriodOver(E),D=Ms.decideEntitlementPolicy(w,b);return w!=null&&w.calculatedEntitlement.feature&&((m=w.calculatedEntitlement.feature)===null||m===void 0?void 0:m.meterType)!==h.puT.Fluctuating&&((y=w.calculatedEntitlement.feature)===null||y===void 0?void 0:y.meterType)!==h.puT.Incremental?l:w?this.modelMapper.mapMeteredEntitlement(w,D,b):ti(ti({},D),{currentUsage:0,isFallback:false,isUnlimited:false,requestedUsage:b||0})},f.prototype.handleUsagePeriodOver=function(a){var l,d,m=new Date;if(!(a&&((d=a.calculatedEntitlement.feature)==null?void 0:d.featureType)===h.Tex.Number&&!(0, F.isNil)(d.meterType)&&gh.includes(d.meterType)&&a.featureUsage.usagePeriodEnd&&a.featureUsage.usagePeriodEnd.getTime()<m.getTime()))return a;var y,b,E=a.calculatedEntitlement,w=a.featureUsage,D=w.resetPeriod,_=w.usagePeriodAnchor;return _&&D&&(y=(l=(function(M,B,H){var K=du()(B),J=du()(M),tt=(function(zt){switch(zt){case h.XHu.Year:return "years";case h.XHu.Month:return "months";case h.XHu.Week:return "weeks";case h.XHu.Day:return "days";case h.XHu.Hour:return "hours";default:throw new Error("Unsupported reset period")}})(H),yt=Math.floor(K.diff(J,tt,true)),Rt=J.clone().add(yt,tt),Zt=J.clone().add(yt+1,tt);return {usagePeriodStart:Rt.toDate(),usagePeriodEnd:Zt.toDate()}})(new Date(_),m,D)).usagePeriodStart,b=l.usagePeriodEnd),new Jo(E,ti(ti({},w),{currentUsage:0,usagePeriodStart:y,usagePeriodEnd:b}))},f.prototype.getEnumEntitlement=function(a,l,d){var m,y=this.cacheService.getEntitlement(a),b=d==null?void 0:d.requestedValues,E=Ms.decideEntitlementPolicy(y,void 0,b);return y!=null&&y.calculatedEntitlement.feature&&((m=y.calculatedEntitlement.feature)===null||m===void 0?void 0:m.featureType)!==h.Tex.Enum?l:y?this.modelMapper.mapEnumEntitlement(y,E,b):ti(ti({},E),{isFallback:false,enumValues:[],requestedValues:b||[]})},f.prototype.loadEntitlements=function(a){return Ns(this,void 0,void 0,(function(){return mr(this,(function(l){switch(l.label){case 0:this.loadingEntitlements||(this.loadingEntitlements=this.loadEntitlementsFromRemote(a)),l.label=1;case 1:return l.trys.push([1,,3,4]),[4,this.loadingEntitlements];case 2:return [2,l.sent()];case 3:return this.loadingEntitlements=null,[7];case 4:return [2]}}))}))},f.prototype.loadEntitlementsFromRemote=function(a){return Ns(this,void 0,void 0,(function(){var l;return mr(this,(function(d){switch(d.label){case 0:return [4,this.entitlementsApi.getEntitlements(this.customerId,a,this.resourceId)];case 1:return l=d.sent(),this.storeFetchedEntitlementsInCache(l.data.entitlements),[2]}}))}))},f.prototype.storeFetchedEntitlementsInCache=function(a){this.cacheService.updateLastChecked();var l=this.cacheService.getLastUpdate(),d=this.getLastEntitlementsUpdate(a);if(!(l&&d.getTime()<l.getTime())){var m=this.modelMapper.mapCachedEntitlements(a);this.cacheService.setEntitlements(m,d),this.onEntitlementsUpdated(m);}},f.prototype.getLastEntitlementsUpdate=function(a){return (0, F.max)(a.flatMap((function(l){return [new Date(l.entitlementUpdatedAt),new Date(l.usageUpdatedAt)]})))||new Date},f.prototype.getEntitlement=function(a){var l=this.cacheService.getEntitlement(a);return this.renewOutdatedCacheInBackground(),l},f.prototype.getEntitlements=function(){return Ns(this,void 0,void 0,(function(){var a=this;return mr(this,(function(l){switch(l.label){case 0:return [4,this.renewOutdatedCache()];case 1:return l.sent(),[2,Array.from(this.cacheService.getEntitlements().values()).map((function(d){var m=Ms.decideEntitlementPolicy(d);return a.modelMapper.mapEntitlement(d,m)}))]}}))}))},f.prototype.renewOutdatedCache=function(){return Ns(this,void 0,void 0,(function(){return mr(this,(function(a){switch(a.label){case 0:return !this.cacheService.isLoaded()||this.cacheService.isOutdated()?[4,this.loadEntitlements()]:[3,2];case 1:a.sent(),a.label=2;case 2:return [2]}}))}))},f.prototype.renewOutdatedCacheInBackground=function(){var a=this;this.renewOutdatedCache().catch((function(l){a.loggerService.error("Failed to renew cache in background",l);}));},f})(),pu=n(2527),Ls=(function(){var f=function(a,l){return f=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(d,m){d.__proto__=m;}||function(d,m){for(var y in m)Object.prototype.hasOwnProperty.call(m,y)&&(d[y]=m[y]);},f(a,l)};return function(a,l){if(typeof l!="function"&&l!==null)throw new TypeError("Class extends value "+String(l)+" is not a constructor or null");function d(){this.constructor=a;}f(a,l),a.prototype=l===null?Object.create(l):(d.prototype=l.prototype,new d);}})(),yh=(function(f){function a(){return f.call(this)||this}return Ls(a,f),a})(pu.TypedEmitter),fu=(function(){function f(a){var l=this;a===void 0&&(a=3e4),this.ttlMs=a,this.setFeatures=function(d){return l.features=new Set(d)},this.ttlMs=a,this.entitlements=new Map,this.features=new Set,this.lastUpdate=null,this.lastChecked=null;}return f.prototype.getEntitlement=function(a){return this.entitlements.get(a)||null},f.prototype.validateFeature=function(a){return this.features.has(a)},f.prototype.updateLastChecked=function(){this.lastChecked=new Date;},f.prototype.setEntitlements=function(a,l){this.entitlements=a,this.lastUpdate=l;},f.prototype.getEntitlements=function(){return this.entitlements},f.prototype.getLastUpdate=function(){return this.lastUpdate},f.prototype.isLoaded=function(){return !!this.lastUpdate},f.prototype.isOutdated=function(){return this.lastChecked===null||new Date().getTime()-this.lastChecked.getTime()>this.ttlMs},f})();(function(f){f.IN_PROGRESS="IN_PROGRESS",f.SUCCESS="READY",f.FAILED="FAILED";})(ta||(ta={}));var bh=(function(){function f(a){this.eventEmitter=a,this.initializationPromise=null,this.initializationStatus=ta.IN_PROGRESS,this.initFailureError=null;}return f.prototype.getInitializationPromise=function(){var a=this;return this.initializationPromise?this.initializationPromise:this.initializationStatus===ta.SUCCESS?Promise.resolve():this.initializationStatus===ta.FAILED?Promise.reject(this.initFailureError):(this.initializationPromise=new Promise((function(l,d){a.eventEmitter.once("initializeSuccessfully",(function(){l();})),a.eventEmitter.once("initializeFailed",(function(m){d(m);}));})),this.initializationPromise)},f.prototype.signalSuccessInit=function(){this.initializationStatus=ta.SUCCESS,this.eventEmitter.emit("initializeSuccessfully");},f.prototype.signalFailedInit=function(a){this.initializationStatus=ta.FAILED,this.initFailureError=a,this.eventEmitter.emit("initializeFailed",a);},f})(),_n=n(2991),Bs=Object.prototype.toString;function ep(f){switch(Bs.call(f)){case "[object Error]":case "[object Exception]":case "[object DOMException]":return true;default:return wo(f,Error)}}function Ma(f,a){return Bs.call(f)===`[object ${a}]`}function Hl(f){return Ma(f,"ErrorEvent")}function np(f){return Ma(f,"DOMError")}function _o(f){return Ma(f,"String")}function hu(f){return f===null||typeof f!="object"&&typeof f!="function"}function To(f){return Ma(f,"Object")}function mu(f){return typeof Event!="undefined"&&wo(f,Event)}function Us(f){return !!(f&&f.then&&typeof f.then=="function")}function wo(f,a){try{return f instanceof a}catch(l){return false}}function Wl(f,a){try{let m=f;var l=[];let y=0,b=0;var d=3;let E;for(;m&&y++<5&&(E=Xy(m,a),!(E==="html"||y>1&&b+l.length*d+E.length>=80));)l.push(E),b+=E.length,m=m.parentNode;return l.reverse().join(" > ")}catch(m){return "<unknown>"}}function Xy(f,a){var l=f,d=[];let m,y,b,E,w;if(!l||!l.tagName)return "";d.push(l.tagName.toLowerCase());var D=a&&a.length?a.filter((M=>l.getAttribute(M))).map((M=>[M,l.getAttribute(M)])):null;if(D&&D.length)D.forEach((M=>{d.push(`[${M[0]}="${M[1]}"]`);}));else if(l.id&&d.push(`#${l.id}`),m=l.className,m&&_o(m))for(y=m.split(/\s+/),w=0;w<y.length;w++)d.push(`.${y[w]}`);var _=["type","name","title","alt"];for(w=0;w<_.length;w++)b=_[w],E=l.getAttribute(b),E&&d.push(`[${b}="${E}"]`);return d.join("")}function $s(f,a=0){return typeof f!="string"||a===0||f.length<=a?f:`${f.substr(0,a)}...`}function to(f,a){if(!Array.isArray(f))return "";var l=[];for(let m=0;m<f.length;m++){var d=f[m];try{l.push(String(d));}catch(y){l.push("[value cannot be serialized]");}}return l.join(a)}function gu(f,a){return !!_o(f)&&(Ma(a,"RegExp")?a.test(f):typeof a=="string"&&f.indexOf(a)!==-1)}function xr(f,a,l){if(a in f){var d=f[a],m=l(d);if(typeof m=="function")try{ip(m,d);}catch(y){}f[a]=m;}}function rp(f,a,l){Object.defineProperty(f,a,{value:l,writable:true,configurable:true});}function ip(f,a){var l=a.prototype||{};f.prototype=a.prototype=l,rp(f,"__sentry_original__",a);}function Ni(f){return f.__sentry_original__}function yu(f){if(ep(f))return W({message:f.message,name:f.name,stack:f.stack},vu(f));if(mu(f)){var a=W({type:f.type,target:bu(f.target),currentTarget:bu(f.currentTarget)},vu(f));return typeof CustomEvent!="undefined"&&wo(f,CustomEvent)&&(a.detail=f.detail),a}return f}function bu(f){try{return typeof Element!="undefined"&&wo(f,Element)?Wl(f):Object.prototype.toString.call(f)}catch(a){return "<unknown>"}}function vu(f){if(typeof f=="object"&&f!==null){var a={};for(var l in f)Object.prototype.hasOwnProperty.call(f,l)&&(a[l]=f[l]);return a}return {}}function Cu(f,a=40){var l=Object.keys(yu(f));if(l.sort(),!l.length)return "[object has no keys]";if(l[0].length>=a)return $s(l[0],a);for(let m=l.length;m>0;m--){var d=l.slice(0,m).join(", ");if(!(d.length>a))return m===l.length?d:$s(d,a)}return ""}function ea(f){return ue(f,new Map)}function ue(f,a){if(To(f)){if((m=a.get(f))!==void 0)return m;var l={};for(var d of(a.set(f,l),Object.keys(f)))f[d]!==void 0&&(l[d]=ue(f[d],a));return l}var m;return Array.isArray(f)?(m=a.get(f))!==void 0?m:(l=[],a.set(f,l),f.forEach((y=>{l.push(ue(y,a));})),l):f}let ql;class Na{constructor(){Na.prototype.__init.call(this);}static __initStatic(){this.id="FunctionToString";}__init(){this.name=Na.id;}setupOnce(){ql=Function.prototype.toString,Function.prototype.toString=function(...a){var l=Ni(this)||this;return ql.apply(l,a)};}}Na.__initStatic();var La=(0, _n.R)(),Gs=["debug","info","warn","error","log","assert","trace"];function op(f){var a=(0, _n.R)();if(!("console"in a))return f();var l=a.console,d={};Gs.forEach((m=>{var y=l[m]&&l[m].__sentry_original__;m in a.console&&y&&(d[m]=l[m],l[m]=y);}));try{return f()}finally{Object.keys(d).forEach((m=>{l[m]=d[m];}));}}function Er(){let f=false;var a={enable:()=>{f=true;},disable:()=>{f=false;}};return typeof __SENTRY_DEBUG__=="undefined"||__SENTRY_DEBUG__?Gs.forEach((l=>{a[l]=(...d)=>{f&&op((()=>{La.console[l](`Sentry Logger [${l}]:`,...d);}));};})):Gs.forEach((l=>{a[l]=()=>{};})),a}let Fe;function Ba(){var f=(0, _n.R)(),a=f.crypto||f.msCrypto;if(a&&a.randomUUID)return a.randomUUID().replace(/-/g,"");var l=a&&a.getRandomValues?()=>a.getRandomValues(new Uint8Array(1))[0]:()=>16*Math.random();return ("10000000100040008000"+1e11).replace(/[018]/g,(d=>(d^(15&l())>>d/4).toString(16)))}function vh(f){return f.exception&&f.exception.values?f.exception.values[0]:void 0}function Br(f){let{message:a,event_id:l}=f;if(a)return a;var d=vh(f);return d?d.type&&d.value?`${d.type}: ${d.value}`:d.type||d.value||l||"<unknown>":l||"<unknown>"}function _r(f,a,l){var d=f.exception=f.exception||{},m=d.values=d.values||[],y=m[0]=m[0]||{};y.value||(y.value=a||""),y.type||(y.type="Error");}function Ua(f,a){var l=vh(f);if(l){var d=l.mechanism;if(l.mechanism=W(W({type:"generic",handled:true},d),a),a&&"data"in a){var m=W(W({},d&&d.data),a.data);l.mechanism.data=m;}}}function Su(f){if(f&&f.__sentry_captured__)return true;try{rp(f,"__sentry_captured__",!0);}catch(a){}return false}Fe=typeof __SENTRY_DEBUG__=="undefined"||__SENTRY_DEBUG__?(0, _n.Y)("logger",Er):Er();var Zy=[/^Script error\.?$/,/^Javascript error: Script error\.? on line 0$/];class eo{static __initStatic(){this.id="InboundFilters";}__init(){this.name=eo.id;}constructor(a={}){this._options=a,eo.prototype.__init.call(this);}setupOnce(a,l){var d=m=>{var y=l();if(y){var b=y.getIntegration(eo);if(b){var E=y.getClient(),w=E?E.getOptions():{},D=(function(_={},M={}){return {allowUrls:[..._.allowUrls||[],...M.allowUrls||[]],denyUrls:[..._.denyUrls||[],...M.denyUrls||[]],ignoreErrors:[..._.ignoreErrors||[],...M.ignoreErrors||[],...Zy],ignoreInternal:_.ignoreInternal===void 0||_.ignoreInternal}})(b._options,w);return (function(_,M){return M.ignoreInternal&&(function(B){try{return B.exception.values[0].type==="SentryError"}catch(H){}return false})(_)?((typeof __SENTRY_DEBUG__=="undefined"||__SENTRY_DEBUG__)&&Fe.warn(`Event dropped due to being internal Sentry Error.
2374
+ `);}}}})(Rt,J,Bt,M.store);}));}a.merge(K,J);})),a.retain(B.__ref),B},f.prototype.processSelectionSet=function(a){var l=this,d=a.dataId,m=a.result,y=a.selectionSet,b=a.context,E=a.mergeTree,w=this.cache.policies,D=w.identify(m,y,b.fragmentMap),_=D[0],M=D[1];if(typeof(d=d||_)=="string"){var B=b.written[d]||(b.written[d]=[]),H=qi(d);if(B.indexOf(y)>=0||(B.push(y),this.reader&&this.reader.isFresh(m,H,y,b)))return H}var K=Object.create(null);M&&(K=b.merge(K,M));var J=d&&w.rootTypenamesById[d]||xa(m,y,b.fragmentMap)||d&&b.store.get(d,"__typename");typeof J=="string"&&(K.__typename=J);var tt=new Set(y.selections);if(tt.forEach((function(Rt){var Zt;if(Ia(Rt,b.variables))if(tr(Rt)){var zt=on(Rt),Bt=m[zt],qt=b.clientOnly;if(b.clientOnly=qt||!(!Rt.directives||!Rt.directives.some((function(S){return S.name.value==="client"}))),Bt!==void 0){var $e=w.getStoreFieldName({typename:J,fieldName:Rt.name.value,field:Rt,variables:b.variables}),fe=Wd(E,$e),Oe=l.processFieldValue(Bt,Rt,b,fe),An=void 0;if(Rt.selectionSet&&!(An=b.store.getFieldValue(Oe,"__typename"))&&ae(Oe)){var Mr=b.incomingById.get(Oe.__ref);An=Mr&&Mr.fields.__typename;}var u=w.getMergeFunction(J,Rt.name.value,An);u?fe.info={field:Rt,typename:J,merge:u}:qd(E,$e),K=b.merge(K,((Zt={})[$e]=Oe,Zt));}else b.clientOnly||Ss.added(Rt)||__DEV__&&Vt.error(("Missing field '"+on(Rt)+"' while writing result "+JSON.stringify(m,null,2)).substring(0,1e3));b.clientOnly=qt;}else {var g=Pa(Rt,b.fragmentMap);g&&w.fragmentMatches(g,J,m,b.variables)&&g.selectionSet.selections.forEach(tt.add,tt);}})),typeof d=="string"){var yt=b.incomingById.get(d);return yt?(yt.fields=b.merge(yt.fields,K),yt.mergeTree=Rs(yt.mergeTree,E),yt.selections.forEach(tt.add,tt),yt.selections=tt):b.incomingById.set(d,{fields:K,mergeTree:Vl(E)?void 0:E,selections:tt}),qi(d)}return K},f.prototype.processFieldValue=function(a,l,d,m){var y=this;return l.selectionSet&&a!==null?Array.isArray(a)?a.map((function(b,E){var w=y.processFieldValue(b,l,d,Wd(m,E));return qd(m,E),w})):this.processSelectionSet({result:a,selectionSet:l.selectionSet,context:d,mergeTree:m}):__DEV__?Od(a):a},f.prototype.applyMerges=function(a,l,d,m,y){var b,E=this;if(a.map.size&&!ae(d)){var w,D=Array.isArray(d)||!ae(l)&&!Mi(l)?void 0:l,_=d;D&&!y&&(y=[ae(D)?D.__ref:D]);var M=function(B,H){return Array.isArray(B)?typeof H=="number"?B[H]:void 0:m.store.getFieldValue(B,String(H))};a.map.forEach((function(B,H){var K=M(D,H),J=M(_,H);if(J!==void 0){y&&y.push(H);var tt=E.applyMerges(B,K,J,m,y);tt!==J&&(w=w||new Map).set(H,tt),y&&Vt(y.pop()===H);}})),w&&(d=Array.isArray(_)?_.slice(0):bt({},_),w.forEach((function(B,H){d[H]=B;})));}return a.info?this.cache.policies.runMergeFunction(l,d,a.info,m,y&&(b=m.store).getStorage.apply(b,y)):d},f})(),Hd=[];function Wd(f,a){var l=f.map;return l.has(a)||l.set(a,Hd.pop()||{map:new Map}),l.get(a)}function Rs(f,a){if(f===a||!a||Vl(a))return f;if(!f||Vl(f))return a;var l=f.info&&a.info?bt(bt({},f.info),a.info):f.info||a.info,d=f.map.size&&a.map.size,m={info:l,map:d?new Map:f.map.size?f.map:a.map};if(d){var y=new Set(a.map.keys());f.map.forEach((function(b,E){m.map.set(E,Rs(b,a.map.get(E))),y.delete(E);})),y.forEach((function(b){m.map.set(b,Rs(a.map.get(b),f.map.get(b)));}));}return m}function Vl(f){return !f||!(f.info||f.map.size)}function qd(f,a){var l=f.map,d=l.get(a);d&&Vl(d)&&(Hd.push(d),l.delete(a));}var Yd=new Set;function au(f){var a=Ps("stringifyForDisplay");return JSON.stringify(f,(function(l,d){return d===void 0?a:d})).split(JSON.stringify(a)).join("<undefined>")}function su(f){return f.args!==void 0?f.args:f.field?El(f.field,f.variables):null}li.setStringify(En);var Qd=function(){},lu=function(f,a){return a.fieldName},Ie=function(f,a,l){return (0, l.mergeObjects)(f,a)},ah=function(f,a){return a},Ky=(function(){function f(a){this.config=a,this.typePolicies=Object.create(null),this.toBeAdded=Object.create(null),this.supertypeMap=new Map,this.fuzzySubtypes=new Map,this.rootIdsByTypename=Object.create(null),this.rootTypenamesById=Object.create(null),this.usingPossibleTypes=false,this.config=bt({dataIdFromObject:hr},a),this.cache=this.config.cache,this.setRootTypename("Query"),this.setRootTypename("Mutation"),this.setRootTypename("Subscription"),a.possibleTypes&&this.addPossibleTypes(a.possibleTypes),a.typePolicies&&this.addTypePolicies(a.typePolicies);}return f.prototype.identify=function(a,l,d){var m=l&&d?xa(a,l,d):a.__typename;if(m===this.rootTypenamesById.ROOT_QUERY)return ["ROOT_QUERY"];for(var y,b={typename:m,selectionSet:l,fragmentMap:d},E=m&&this.getTypePolicy(m),w=E&&E.keyFn||this.config.dataIdFromObject;w;){var D=w(a,b);if(!Array.isArray(D)){y=D;break}w=lh(D);}return y=y?String(y):void 0,b.keyObject?[y,b.keyObject]:[y]},f.prototype.addTypePolicies=function(a){var l=this;Object.keys(a).forEach((function(d){var m=a[d],y=m.queryType,b=m.mutationType,E=m.subscriptionType,w=ar(m,["queryType","mutationType","subscriptionType"]);y&&l.setRootTypename("Query",d),b&&l.setRootTypename("Mutation",d),E&&l.setRootTypename("Subscription",d),fr.call(l.toBeAdded,d)?l.toBeAdded[d].push(w):l.toBeAdded[d]=[w];}));},f.prototype.updateTypePolicy=function(a,l){var d=this,m=this.getTypePolicy(a),y=l.keyFields,b=l.fields;function E(w,D){w.merge=typeof D=="function"?D:D===true?Ie:D===false?ah:w.merge;}E(m,l.merge),m.keyFn=y===false?Qd:Array.isArray(y)?lh(y):typeof y=="function"?y:m.keyFn,b&&Object.keys(b).forEach((function(w){var D=d.getFieldPolicy(a,w,true),_=b[w];if(typeof _=="function")D.read=_;else {var M=_.keyArgs,B=_.read,H=_.merge;D.keyFn=M===false?lu:Array.isArray(M)?sh(M):typeof M=="function"?M:D.keyFn,typeof B=="function"&&(D.read=B),E(D,H);}D.read&&D.merge&&(D.keyFn=D.keyFn||lu);}));},f.prototype.setRootTypename=function(a,l){l===void 0&&(l=a);var d="ROOT_"+a.toUpperCase(),m=this.rootTypenamesById[d];l!==m&&(__DEV__?Vt(!m||m===a,"Cannot change root "+a+" __typename more than once"):Vt(!m||m===a,2),m&&delete this.rootIdsByTypename[m],this.rootIdsByTypename[l]=d,this.rootTypenamesById[d]=l);},f.prototype.addPossibleTypes=function(a){var l=this;this.usingPossibleTypes=true,Object.keys(a).forEach((function(d){l.getSupertypeSet(d,true),a[d].forEach((function(m){l.getSupertypeSet(m,true).add(d);var y=m.match(Fi);y&&y[0]===m||l.fuzzySubtypes.set(m,new RegExp(m));}));}));},f.prototype.getTypePolicy=function(a){var l=this;if(!fr.call(this.typePolicies,a)){var d=this.typePolicies[a]=Object.create(null);d.fields=Object.create(null);var m=this.supertypeMap.get(a);m&&m.size&&m.forEach((function(b){var E=l.getTypePolicy(b),w=E.fields,D=ar(E,["fields"]);Object.assign(d,D),Object.assign(d.fields,w);}));}var y=this.toBeAdded[a];return y&&y.length&&y.splice(0).forEach((function(b){l.updateTypePolicy(a,b);})),this.typePolicies[a]},f.prototype.getFieldPolicy=function(a,l,d){if(a){var m=this.getTypePolicy(a).fields;return m[l]||d&&(m[l]=Object.create(null))}},f.prototype.getSupertypeSet=function(a,l){var d=this.supertypeMap.get(a);return !d&&l&&this.supertypeMap.set(a,d=new Set),d},f.prototype.fragmentMatches=function(a,l,d,m){var y=this;if(!a.typeCondition)return true;if(!l)return false;var b=a.typeCondition.name.value;if(l===b)return true;if(this.usingPossibleTypes&&this.supertypeMap.has(b))for(var E=this.getSupertypeSet(l,true),w=[E],D=function(K){var J=y.getSupertypeSet(K,false);J&&J.size&&w.indexOf(J)<0&&w.push(J);},_=!(!d||!this.fuzzySubtypes.size),M=false,B=0;B<w.length;++B){var H=w[B];if(H.has(b))return E.has(b)||(M&&__DEV__&&Vt.warn("Inferring subtype "+l+" of supertype "+b),E.add(b)),true;H.forEach(D),_&&B===w.length-1&&Ds(a.selectionSet,d,m)&&(_=false,M=true,this.fuzzySubtypes.forEach((function(K,J){var tt=l.match(K);tt&&tt[0]===l&&D(J);})));}return false},f.prototype.hasKeyArgs=function(a,l){var d=this.getFieldPolicy(a,l,false);return !(!d||!d.keyFn)},f.prototype.getStoreFieldName=function(a){var l,d=a.typename,m=a.fieldName,y=this.getFieldPolicy(d,m,false),b=y&&y.keyFn;if(b&&d)for(var E={typename:d,fieldName:m,field:a.field||null,variables:a.variables},w=su(a);b;){var D=b(w,E);if(!Array.isArray(D)){l=D||m;break}b=sh(D);}return l===void 0&&(l=a.field?(function(_,M){var B=null;_.directives&&(B={},_.directives.forEach((function(K){B[K.name.value]={},K.arguments&&K.arguments.forEach((function(J){var tt=J.name,yt=J.value;return Ue(B[K.name.value],tt,yt,M)}));})));var H=null;return _.arguments&&_.arguments.length&&(H={},_.arguments.forEach((function(K){var J=K.name,tt=K.value;return Ue(H,J,tt,M)}))),li(_.name.value,H,B)})(a.field,a.variables):li(m,su(a))),l===false?m:m===Zi(l)?l:m+":"+l},f.prototype.readField=function(a,l){var d=a.from;if(d&&(a.field||a.fieldName)){if(a.typename===void 0){var m=l.store.getFieldValue(d,"__typename");m&&(a.typename=m);}var y=this.getStoreFieldName(a),b=Zi(y),E=l.store.getFieldValue(d,y),w=this.getFieldPolicy(a.typename,b,false),D=w&&w.read;if(D){var _=Fs(this,d,a,l,l.store.getStorage(ae(d)?d.__ref:d,y));return eu.withValue(this.cache,D,[E,_])}return E}},f.prototype.getMergeFunction=function(a,l,d){var m=this.getFieldPolicy(a,l,false),y=m&&m.merge;return !y&&d&&(y=(m=this.getTypePolicy(d))&&m.merge),y},f.prototype.runMergeFunction=function(a,l,d,m,y){var b=d.field,E=d.typename,w=d.merge;return w===Ie?Kd(m.store)(a,l):w===ah?l:(m.overwrite&&(a=void 0),w(a,l,Fs(this,void 0,{typename:E,fieldName:b.name.value,field:b,variables:m.variables},m,y||Object.create(null))))},f})();function Fs(f,a,l,d,m){var y=f.getStoreFieldName(l),b=Zi(y),E=l.variables||d.variables,w=d.store,D=w.toReference,_=w.canRead;return {args:su(l),field:l.field||null,fieldName:b,storeFieldName:y,variables:E,isReference:ae,toReference:D,storage:m,cache:f.cache,canRead:_,readField:function(M,B){var H;if(typeof M=="string")H={fieldName:M,from:arguments.length>1?B:a};else {if(!vt(M))return void(__DEV__&&Vt.warn("Unexpected readField arguments: "+au(Array.from(arguments))));H=bt({},M),fr.call(M,"from")||(H.from=a);}return __DEV__&&H.from===void 0&&__DEV__&&Vt.warn("Undefined 'from' passed to readField with arguments "+au(Array.from(arguments))),H.variables===void 0&&(H.variables=E),f.readField(H,d)},mergeObjects:Kd(d.store)}}function Kd(f){return function(a,l){if(Array.isArray(a)||Array.isArray(l))throw __DEV__?new Ce("Cannot automatically merge arrays"):new Ce(3);if(vt(a)&&vt(l)){var d=f.getFieldValue(a,"__typename"),m=f.getFieldValue(l,"__typename");if(d&&m&&d!==m)return l;if(ae(a)&&Mi(l))return f.merge(a.__ref,l),a;if(Mi(a)&&ae(l))return f.merge(a,l.__ref),l;if(Mi(a)&&Mi(l))return bt(bt({},a),l)}return l}}function sh(f){return function(a,l){return a?l.fieldName+":"+JSON.stringify(Xd(a,f,false)):l.fieldName}}function lh(f){var a=new At(Dt);return function(l,d){var m;if(d.selectionSet&&d.fragmentMap){var y=a.lookupArray([d.selectionSet,d.fragmentMap]);m=y.aliasMap||(y.aliasMap=Zr(d.selectionSet,d.fragmentMap));}var b=d.keyObject=Xd(l,f,true,m);return d.typename+":"+JSON.stringify(b)}}function Zr(f,a){var l=Object.create(null),d=new Set([f]);return d.forEach((function(m){m.selections.forEach((function(y){if(tr(y)){if(y.alias){var b=y.alias.value,E=y.name.value;E!==b&&((l.aliases||(l.aliases=Object.create(null)))[E]=b);}y.selectionSet&&((l.subsets||(l.subsets=Object.create(null)))[y.name.value]=Zr(y.selectionSet,a));}else {var w=Pa(y,a);w&&d.add(w.selectionSet);}}));})),l}function Xd(f,a,l,d){var m,y,b=Object.create(null);return a.forEach((function(E){if(Array.isArray(E)){if(typeof y=="string"&&typeof m=="string"){var w=d&&d.subsets,D=w&&w[y];b[y]=Xd(f[m],E,l,D);}}else {var _=d&&d.aliases,M=_&&_[E]||E;fr.call(f,M)?b[y=E]=f[m=M]:(__DEV__?Vt(!l,"Missing field '"+M+"' while computing key fields"):Vt(!l,4),m=y=void 0);}})),b}var cu=(function(f){function a(l){l===void 0&&(l={});var d=f.call(this)||this;return d.watches=new Set,d.typenameDocumentCache=new Map,d.makeVar=Ud,d.txCount=0,d.config=(function(m){return vs(ru,m)})(l),d.addTypename=!!d.config.addTypename,d.policies=new Ky({cache:d,dataIdFromObject:d.config.dataIdFromObject,possibleTypes:d.config.possibleTypes,typePolicies:d.config.typePolicies}),d.init(),d}return Ve(a,f),a.prototype.init=function(){var l=this.data=new $l.Root({policies:this.policies,resultCaching:this.config.resultCaching});this.optimisticData=l.stump,this.resetResultCache();},a.prototype.resetResultCache=function(l){var d=this,m=this.storeReader;this.storeWriter=new oh(this,this.storeReader=new zd({cache:this,addTypename:this.addTypename,resultCacheMaxSize:this.config.resultCacheMaxSize,canonizeResults:Gd(this.config),canon:l?void 0:m&&m.canon})),this.maybeBroadcastWatch=Hr((function(y,b){return d.broadcastWatch(y,b)}),{max:this.config.resultCacheMaxSize,makeCacheKey:function(y){var b=y.optimistic?d.optimisticData:d.data;if(Os(b)){var E=y.optimistic,w=y.rootId,D=y.variables;return b.makeCacheKey(y.query,y.callback,En({optimistic:E,rootId:w,variables:D}))}}}),new Set([this.data.group,this.optimisticData.group]).forEach((function(y){return y.resetCaching()}));},a.prototype.restore=function(l){return this.init(),l&&this.data.replace(l),this},a.prototype.extract=function(l){return l===void 0&&(l=false),(l?this.optimisticData:this.data).extract()},a.prototype.read=function(l){var d=l.returnPartialData,m=d!==void 0&&d;try{return this.storeReader.diffQueryAgainstStore(bt(bt({},l),{store:l.optimistic?this.optimisticData:this.data,config:this.config,returnPartialData:m})).result||null}catch(y){if(y instanceof rh)return null;throw y}},a.prototype.write=function(l){try{return ++this.txCount,this.storeWriter.writeToStore(this.data,l)}finally{--this.txCount||l.broadcast===false||this.broadcastWatches();}},a.prototype.modify=function(l){if(fr.call(l,"id")&&!l.id)return false;var d=l.optimistic?this.optimisticData:this.data;try{return ++this.txCount,d.modify(l.id||"ROOT_QUERY",l.fields)}finally{--this.txCount||l.broadcast===false||this.broadcastWatches();}},a.prototype.diff=function(l){return this.storeReader.diffQueryAgainstStore(bt(bt({},l),{store:l.optimistic?this.optimisticData:this.data,rootId:l.id||"ROOT_QUERY",config:this.config}))},a.prototype.watch=function(l){var d,m=this;return this.watches.size||Ml(d=this).vars.forEach((function(y){return y.attachCache(d)})),this.watches.add(l),l.immediate&&this.maybeBroadcastWatch(l),function(){m.watches.delete(l)&&!m.watches.size&&th(m),m.maybeBroadcastWatch.forget(l);}},a.prototype.gc=function(l){En.reset();var d=this.optimisticData.gc();return l&&!this.txCount&&(l.resetResultCache?this.resetResultCache(l.resetResultIdentities):l.resetResultIdentities&&this.storeReader.resetCanon()),d},a.prototype.retain=function(l,d){return (d?this.optimisticData:this.data).retain(l)},a.prototype.release=function(l,d){return (d?this.optimisticData:this.data).release(l)},a.prototype.identify=function(l){return ae(l)?l.__ref:this.policies.identify(l)[0]},a.prototype.evict=function(l){if(!l.id){if(fr.call(l,"id"))return false;l=bt(bt({},l),{id:"ROOT_QUERY"});}try{return ++this.txCount,this.optimisticData.evict(l,this.data)}finally{--this.txCount||l.broadcast===false||this.broadcastWatches();}},a.prototype.reset=function(l){var d=this;return this.init(),En.reset(),l&&l.discardWatches?(this.watches.forEach((function(m){return d.maybeBroadcastWatch.forget(m)})),this.watches.clear(),th(this)):this.broadcastWatches(),Promise.resolve()},a.prototype.removeOptimistic=function(l){var d=this.optimisticData.removeLayer(l);d!==this.optimisticData&&(this.optimisticData=d,this.broadcastWatches());},a.prototype.batch=function(l){var d=this,m=l.update,y=l.optimistic,b=y===void 0||y,E=l.removeOptimistic,w=l.onWatchUpdated,D=function(M){var B=d,H=B.data,K=B.optimisticData;++d.txCount,M&&(d.data=d.optimisticData=M);try{m(d);}finally{--d.txCount,d.data=H,d.optimisticData=K;}},_=new Set;w&&!this.txCount&&this.broadcastWatches(bt(bt({},l),{onWatchUpdated:function(M){return _.add(M),false}})),typeof b=="string"?this.optimisticData=this.optimisticData.addLayer(b,D):b===false?D(this.data):D(),typeof E=="string"&&(this.optimisticData=this.optimisticData.removeLayer(E)),w&&_.size?(this.broadcastWatches(bt(bt({},l),{onWatchUpdated:function(M,B){var H=w.call(this,M,B);return H!==false&&_.delete(M),H}})),_.size&&_.forEach((function(M){return d.maybeBroadcastWatch.dirty(M)}))):this.broadcastWatches(l);},a.prototype.performTransaction=function(l,d){return this.batch({update:l,optimistic:d||d!==null})},a.prototype.transformDocument=function(l){if(this.addTypename){var d=this.typenameDocumentCache.get(l);return d||(d=Ss(l),this.typenameDocumentCache.set(l,d),this.typenameDocumentCache.set(d,d)),d}return l},a.prototype.broadcastWatches=function(l){var d=this;this.txCount||this.watches.forEach((function(m){return d.maybeBroadcastWatch(m,l)}));},a.prototype.broadcastWatch=function(l,d){var m=l.lastDiff,y=this.diff(l);d&&(l.optimistic&&typeof d.optimistic=="string"&&(y.fromOptimisticTransaction=true),d.onWatchUpdated&&d.onWatchUpdated.call(this,l,y,m)===false)||m&&Nn(m.result,y.result)||l.callback(l.lastDiff=y,m);},a})(nh);let Zd=JSON.parse('{"g":{"BillingCredentials":["StripeCheckoutCredentials","ZuoraCheckoutCredentials"],"Credentials":["Auth0Credentials","AwsMarketplaceCredentials","BigQueryCredentials","HubspotCredentials","OpenFGACredentials","SalesforceCredentials","SnowflakeCredentials","StripeCredentials","ZuoraCredentials"],"PaymentMethodForm":["StripePaymentMethodForm","ZuoraPaymentMethodForm"],"ResetPeriodConfiguration":["MonthlyResetPeriodConfig","WeeklyResetPeriodConfig","YearlyResetPeriodConfig"],"ScheduleVariables":["AddonChangeVariables","AddonPriceOverrideChangeVariables","BillingPeriodChangeVariables","CouponChangeVariables","DowngradeChangeVariables","PlanChangeVariables","PlanPriceOverrideChangeVariables","UnitAmountChangeVariables"],"SyncRevisionData":["SyncRevisionBillingData","SyncRevisionMarketplaceData","SyncRevisionPriceBillingData"]}}');var ch=(function(){function f(a,l,d,m){var y=this;this.operation=a,this.nextLink=l,this.delayFor=d,this.retryIf=m,this.retryCount=0,this.values=[],this.complete=false,this.canceled=false,this.observers=[],this.currentSubscription=null,this.onNext=function(b){y.values.push(b);for(var E=0,w=y.observers;E<w.length;E++){var D=w[E];D&&D.next(b);}},this.onComplete=function(){y.complete=true;for(var b=0,E=y.observers;b<E.length;b++){var w=E[b];w&&w.complete();}},this.onError=function(b){return sr(y,void 0,void 0,(function(){var E,w,D;return Jn(this,(function(_){switch(_.label){case 0:return this.retryCount+=1,[4,this.retryIf(this.retryCount,this.operation,b)];case 1:if(_.sent())return this.scheduleRetry(this.delayFor(this.retryCount,this.operation,b)),[2];for(this.error=b,E=0,w=this.observers;E<w.length;E++)(D=w[E])&&D.error(b);return [2]}}))}))};}return f.prototype.subscribe=function(a){if(this.canceled)throw new Error("Subscribing to a retryable link that was canceled is not supported");this.observers.push(a);for(var l=0,d=this.values;l<d.length;l++){var m=d[l];a.next(m);}this.complete?a.complete():this.error&&a.error(this.error);},f.prototype.unsubscribe=function(a){var l=this.observers.indexOf(a);if(l<0)throw new Error("RetryLink BUG! Attempting to unsubscribe unknown observer!");this.observers[l]=null,this.observers.every((function(d){return d===null}))&&this.cancel();},f.prototype.start=function(){this.currentSubscription||this.try();},f.prototype.cancel=function(){this.currentSubscription&&this.currentSubscription.unsubscribe(),clearTimeout(this.timerId),this.timerId=void 0,this.currentSubscription=null,this.canceled=true;},f.prototype.try=function(){this.currentSubscription=this.nextLink(this.operation).subscribe({next:this.onNext,error:this.onError,complete:this.onComplete});},f.prototype.scheduleRetry=function(a){var l=this;if(this.timerId)throw new Error("RetryLink BUG! Encountered overlapping retries");this.timerId=setTimeout((function(){l.timerId=void 0,l.try();}),a);},f})(),uh=(function(f){function a(l){var d=f.call(this)||this,m=l||{},y=m.attempts,b=m.delay;return d.delayFor=typeof b=="function"?b:(function(E){var w=E||{},D=w.initial,_=D===void 0?300:D,M=w.jitter,B=M===void 0||M,H=w.max,K=H===void 0?1/0:H,J=B?_:_/2;return function(tt){var yt=Math.min(K,J*Math.pow(2,tt));return B&&(yt=Math.random()*yt),yt}})(b),d.retryIf=typeof y=="function"?y:(function(E){var w=E||{},D=w.retryIf,_=w.max,M=_===void 0?5:_;return function(B,H,K){return !(B>=M)&&(D?D(K,H):!!K)}})(y),d}return Ve(a,f),a.prototype.request=function(l,d){var m=new ch(l,d,this.delayFor,this.retryIf);return m.start(),new Je((function(y){return m.subscribe(y),function(){m.unsubscribe(y);}}))},a})(Tt),Jr=n(4147),Zo=function(f){return !!f&&![500,400].includes(f.statusCode)};let Jd=(function(){function f(a,l){this.client=a,this.edgeApiClient=l;}return f.prototype.getEntitlements=function(a,l,d){return l===void 0&&(l=false),m=this,y=void 0,E=function(){return (function(w,D){var _,M,B,H,K={label:0,sent:function(){if(1&B[0])throw B[1];return B[1]},trys:[],ops:[]};return H={next:J(0),throw:J(1),return:J(2)},typeof Symbol=="function"&&(H[Symbol.iterator]=function(){return this}),H;function J(tt){return function(yt){return (function(Rt){if(_)throw new TypeError("Generator is already executing.");for(;K;)try{if(_=1,M&&(B=2&Rt[0]?M.return:Rt[0]?M.throw||((B=M.return)&&B.call(M),0):M.next)&&!(B=B.call(M,Rt[1])).done)return B;switch(M=0,B&&(Rt=[2&Rt[0],B.value]),Rt[0]){case 0:case 1:B=Rt;break;case 4:return K.label++,{value:Rt[1],done:!1};case 5:K.label++,M=Rt[1],Rt=[0];continue;case 7:Rt=K.ops.pop(),K.trys.pop();continue;default:if(!((B=(B=K.trys).length>0&&B[B.length-1])||Rt[0]!==6&&Rt[0]!==2)){K=0;continue}if(Rt[0]===3&&(!B||Rt[1]>B[0]&&Rt[1]<B[3])){K.label=Rt[1];break}if(Rt[0]===6&&K.label<B[1]){K.label=B[1],B=Rt;break}if(B&&K.label<B[2]){K.label=B[2],K.ops.push(Rt);break}B[2]&&K.ops.pop(),K.trys.pop();continue}Rt=D.call(w,K);}catch(Zt){Rt=[6,Zt],M=0;}finally{_=B=0;}if(5&Rt[0])throw Rt[1];return {value:Rt[0]?Rt[1]:void 0,done:true}})([tt,yt])}}})(this,(function(w){return this.edgeApiClient&&!l?[2,this.edgeApiClient.getEntitlements(a,d)]:[2,this.client.query({query:h.roX,variables:{query:{customerId:a,resourceId:d}},fetchPolicy:"no-cache"})]}))},new((b=void 0)||(b=Promise))((function(w,D){function _(H){try{B(E.next(H));}catch(K){D(K);}}function M(H){try{B(E.throw(H));}catch(K){D(K);}}function B(H){var K;H.done?w(H.value):(K=H.value,K instanceof b?K:new b((function(J){J(K);}))).then(_,M);}B((E=E.apply(m,y||[])).next());}));var m,y,b,E;},f})();var dh=n(5161),Ji=n.n(dh),ph=n(7557),uu=n.n(ph),fh=n(9704),tp=n.n(fh),zl=function(f){return f?new Date(f):void 0},Xe=function(){return Xe=Object.assign||function(f){for(var a,l=1,d=arguments.length;l<d;l++)for(var m in a=arguments[l])Object.prototype.hasOwnProperty.call(a,m)&&(f[m]=a[m]);return f},Xe.apply(this,arguments)},hh=(function(){function f(){var a=this;this.mapApplySubscriptionResults=function(l){var d=l.applySubscription.subscription;return {subscription:d?a.mapSubscription(d):void 0}},this.mapSlimCustomer=function(l){return {id:l.refId,name:l.name||void 0,email:l.email||void 0,billingId:l.billingId||void 0,createdAt:new Date(l.createdAt),updatedAt:new Date(l.updatedAt),metadata:l.additionalMetaData,awsMarketplaceCustomerId:l.awsMarketplaceCustomerId}};}return f.prototype.mapBooleanEntitlement=function(a,l){return {isFallback:false,hasAccess:l.hasAccess,accessDeniedReason:l.accessDeniedReason,feature:a.calculatedEntitlement.feature?Xe(Xe({},a.calculatedEntitlement.feature),{isMetered:false}):void 0}},f.prototype.mapNumericEntitlement=function(a,l){var d=a.calculatedEntitlement,m=d.hasUnlimitedUsage,y=d.usageLimit;return {isFallback:false,hasAccess:l.hasAccess,accessDeniedReason:l.accessDeniedReason,isUnlimited:m,value:y!=null?y:void 0,feature:a.calculatedEntitlement.feature?Xe(Xe({},a.calculatedEntitlement.feature),{isMetered:false}):void 0}},f.prototype.mapMeteredEntitlement=function(a,l,d){var m=a.calculatedEntitlement,y=m.hasUnlimitedUsage,b=m.usageLimit,E=m.feature,w=a.featureUsage,D=w.currentUsage,_=w.resetPeriod,M=w.usagePeriodAnchor,B=w.usagePeriodStart,H=w.usagePeriodEnd,K=null;return E&&E.featureType===h.Tex.Number&&E.meterType===h.puT.Incremental&&_&&H&&(K={nextResetDate:H,resetPeriod:_}),{isFallback:false,hasAccess:l.hasAccess,accessDeniedReason:l.accessDeniedReason,isUnlimited:y,usageLimit:b!=null?b:void 0,currentUsage:D,requestedUsage:d||0,resetPeriod:_!=null?_:void 0,usagePeriodAnchor:M,usagePeriodStart:B,usagePeriodEnd:H,resetSettings:K||void 0,feature:a.calculatedEntitlement.feature?Xe(Xe({},a.calculatedEntitlement.feature),{meterType:a.calculatedEntitlement.feature.meterType||void 0,isMetered:true}):void 0}},f.prototype.mapEnumEntitlement=function(a,l,d){return {isFallback:false,hasAccess:l.hasAccess,accessDeniedReason:l.accessDeniedReason,feature:a.calculatedEntitlement.feature?Xe(Xe({},a.calculatedEntitlement.feature),{isMetered:false}):void 0,enumValues:a.calculatedEntitlement.enumValues||[],requestedValues:d}},f.prototype.mapEntitlement=function(a,l,d){var m=a.calculatedEntitlement;if(!m.feature)return this.mapBooleanEntitlement(a,l);var y=m.feature,b=y.featureType,E=y.meterType,w=b===h.Tex.Number&&(E===h.puT.Incremental||E===h.puT.Fluctuating);switch(b){case h.Tex.Boolean:return this.mapBooleanEntitlement(a,l);case h.Tex.Enum:return this.mapEnumEntitlement(a,l);case h.Tex.Number:return w?this.mapMeteredEntitlement(a,l,d):this.mapNumericEntitlement(a,l)}},f.prototype.mapCachedEntitlement=function(a){var l;return a.feature&&(l={id:a.feature.refId,featureType:a.feature.featureType,meterType:a.feature.meterType||void 0,units:a.feature.featureUnits||void 0,unitsPlural:a.feature.featureUnitsPlural||void 0,displayName:a.feature.displayName,description:a.feature.description||""}),{calculatedEntitlement:{usageLimit:a.usageLimit,hasUnlimitedUsage:a.hasUnlimitedUsage,hasSoftLimit:!!a.hasSoftLimit,accessDeniedReason:a.accessDeniedReason||void 0,feature:l,enumValues:a.enumValues||[]},featureUsage:{resetPeriod:a.resetPeriod,resetPeriodConfiguration:a.resetPeriodConfiguration,currentUsage:a.currentUsage||0,usagePeriodAnchor:zl(a.usagePeriodAnchor),usagePeriodStart:zl(a.usagePeriodStart),usagePeriodEnd:zl(a.usagePeriodEnd)}}},f.prototype.mapCachedEntitlements=function(a){var l=this;return new Map(a.map((function(d){var m;return [((m=d.feature)===null||m===void 0?void 0:m.refId)||"",l.mapCachedEntitlement(d)]})))},f.prototype.mapPlans=function(a){var l=this;return ((a==null?void 0:a.paywall.plans)||[]).map((function(d,m){return l.mapPlan(d,m)}))},f.prototype.mapPaywall=function(a){var l=this.mapPlans(a),d=a==null?void 0:a.paywall.configuration,m=!(a!=null&&a.paywall.resource)&&(a==null?void 0:a.paywall.activeSubscriptions)||[];return {plans:l,configuration:d,customer:a!=null&&a.paywall.customer?this.mapCustomer(a==null?void 0:a.paywall.customer,m):null,resource:a!=null&&a.paywall.resource?this.mapResource(a==null?void 0:a.paywall.resource):null,activeSubscriptions:a!=null&&a.paywall.activeSubscriptions?this.mapSubscriptions(a==null?void 0:a.paywall.activeSubscriptions):null,currency:a.paywall.currency,paywallCalculatedPricePoints:a.paywall.paywallCalculatedPricePoints}},f.prototype.mapMockPlans=function(a){var l=this;return {plans:((a==null?void 0:a.mockPaywall.plans)||[]).map((function(d,m){return l.mapPlan(d,m)})),configuration:a.mockPaywall.configuration,customer:null,resource:null,activeSubscriptions:null,currency:{code:h.Fa6.Usd,symbol:"$"}}},f.prototype.mapCoupons=function(a){var l=this;return a.coupons.edges.map((function(d){return d.node})).map((function(d){return l.mapCoupon(d)}))},f.prototype.mapResource=function(a){return {id:a.resourceId}},f.prototype.mapCustomerPortal=function(a){var l=a.resource?this.mapResource(a.resource):null;return Xe(Xe({},a),{resource:l})},f.prototype.mapCheckoutState=function(a){var l=a.configuration,d=a.customer,m=a.plan,y=a.billingIntegration,b=a.resource,E=a.activeSubscription;return {setupSecret:a.setupSecret,configuration:l,customer:this.mapCustomer(d,E?[E]:[]),plan:this.mapPlan(m),resource:b?this.mapResource(b):null,billingIntegration:y,activeSubscription:E?this.mapSubscription(E):null}},f.prototype.mapCustomer=function(a,l){var d,m,y=this;return new I({id:a.refId,name:a.name||void 0,email:a.email||void 0,createdAt:new Date(a.createdAt),updatedAt:new Date(a.updatedAt),hasPaymentMethod:a.hasPaymentMethod,subscriptions:Ji()(l,(function(b){return y.mapSubscription(b)})),promotionalEntitlements:Ji()(a.promotionalEntitlements,(function(b){return y.mapPromotionalEntitlement(b)})),metadata:a.additionalMetaData,paymentMethodDetails:this.mapPaymentDetails(a),trialedPlans:((d=a.trialedPlans)===null||d===void 0?void 0:d.map((function(b){return {productId:b.productRefId,planId:b.planRefId}})))||void 0,eligibleForTrial:(m=a.eligibleForTrial)===null||m===void 0?void 0:m.map((function(b){return {productId:b.productRefId,eligible:b.eligible}})),experimentInfo:uu()(a.experimentInfo,"__typename")})},f.prototype.mapPaymentDetails=function(a){var l=a.defaultPaymentExpirationYear,d=a.defaultPaymentExpirationMonth,m=a.defaultPaymentMethodLast4Digits;if(tp()([m,d,l],(function(y){return y})))return {expirationMonth:d,expirationYear:l,last4Digits:m}},f.prototype.mapPriceWithTotalPrice=function(a,l,d){var m=a.feature,y=a.tiersMode,b=a.tiers,E=a.billingModel,w=a.billingPeriod,D=a.blockSize,_={pricingModel:E,billingPeriod:w,amount:l.total.amount,grossAmount:l.subTotal.amount,currency:this.getPriceCurrency(a),tiersMode:y,tiers:b,isTieredPrice:!!y,blockSize:D};return m&&(_.feature={featureId:m.refId,displayName:m.displayName,units:m.featureUnits,unitsPlural:m.featureUnitsPlural,unitQuantity:d}),_},f.prototype.mapPrice=function(a,l){var d=a.feature,m=a.price,y=a.tiers,b=a.tiersMode,E=a.billingId,w=a.billingModel,D=a.billingPeriod,_=a.minUnitQuantity,M=a.maxUnitQuantity,B=a.billingCountryCode,H=a.blockSize,K={pricingModel:w,billingPeriod:D,billingId:E,amount:m?m.amount:null,currency:this.getPriceCurrency(a),tiersMode:b,tiers:y,isTieredPrice:!!b,minUnitQuantity:_,maxUnitQuantity:M,billingCountryCode:B,blockSize:H,creditRate:a.creditRate?{amount:a.creditRate.amount}:null};return d&&(K.feature={featureId:d.refId,displayName:d.displayName,units:d.featureUnits,unitsPlural:d.featureUnitsPlural,unitQuantity:l}),K},f.prototype.mapPlan=function(a,l){var d=this;return l===void 0&&(l=0),{id:a.refId,order:l,displayName:a.displayName,description:a.description,billingId:a.billingId,basePlan:a.basePlan?{id:a.basePlan.refId,displayName:a.basePlan.displayName}:void 0,entitlements:Ji()(a.entitlements,(function(m){return d.mapPackageEntitlement(m)})),inheritedEntitlements:Ji()(a.inheritedEntitlements,(function(m){return d.mapPackageEntitlement(m)})),pricePoints:Ji()(a.prices,(function(m){return d.mapPrice(m)})),pricingType:a.pricingType,defaultTrialConfig:this.mapDefaultTrialConfig(a.defaultTrialConfig),compatibleAddons:this.mapCompatibleAddons(a),compatiblePackageGroups:this.mapCompatiblePackageGroups(a),product:{id:a.product.refId,displayName:a.product.displayName,description:a.product.description,metadata:a.product.additionalMetaData},metadata:a.additionalMetaData}},f.prototype.mapCompatibleAddons=function(a){var l=this;if(a.pricingType===h._HY.Free||!a.compatibleAddons)return [];var d=a.compatibleAddons;return (a.pricingType===h._HY.Paid?d.filter((function(m){return m.pricingType===h._HY.Paid})):d).map((function(m){return l.mapAddon(m)}))},f.prototype.mapDefaultTrialConfig=function(a){if(a)return {duration:a==null?void 0:a.duration,units:a==null?void 0:a.units,budget:a.budget?{limit:a.budget.limit}:void 0}},f.prototype.mapPackageEntitlement=function(a){var l=a.feature;return l?{usageLimit:a.usageLimit||0,feature:{id:l.refId,featureType:l.featureType,description:l.description||"",meterType:l.meterType||void 0,units:l.featureUnits||void 0,unitsPlural:l.featureUnitsPlural||void 0,displayName:l.displayName,isMetered:l.meterType===h.puT.Fluctuating||l.meterType===h.puT.Incremental,metadata:l.additionalMetaData},isCustom:a.isCustom||void 0,hasUnlimitedUsage:a.hasUnlimitedUsage,resetPeriod:a.resetPeriod,hiddenFromWidgets:a.hiddenFromWidgets,displayNameOverride:a.displayNameOverride,enumValues:a.enumValues,isGranted:a.isGranted}:{usageLimit:a.usageLimit||0,hasUnlimitedUsage:a.hasUnlimitedUsage,resetPeriod:a.resetPeriod,isGranted:a.isGranted}},f.prototype.mapPromotionalEntitlement=function(a){var l=a.feature;return {status:a.status,usageLimit:a.usageLimit||0,feature:{id:l.refId,displayName:l.displayName,description:l.description||"",featureType:l.featureType,meterType:l.meterType||void 0,units:l.featureUnits||void 0,unitsPlural:l.featureUnitsPlural||void 0,isMetered:l.meterType===h.puT.Fluctuating||l.meterType===h.puT.Incremental},hasUnlimitedUsage:a.hasUnlimitedUsage,expiresAt:a.endDate,hasExpirationDate:!!a.endDate,isVisible:a.isVisible}},f.prototype.mapSubscription=function(a){var l,d,m=this,y=a.totalPrice,b=(a.prices||[])[0];return {id:a.subscriptionId,billingId:a.billingId||void 0,resourceId:(l=a.resource)===null||l===void 0?void 0:l.resourceId,payingCustomer:a.payingCustomer?this.mapSlimCustomer(a.payingCustomer):null,status:a.status,currentBillingPeriodEnd:this.mapDate(a.currentBillingPeriodEnd),plan:this.mapPlan(a.plan),prices:a.prices?a.prices.filter((function(E){return E.price!==null})).map((function(E){return m.mapPrice(E.price,E.usageLimit)})):[],totalPrice:y,price:b&&y&&b.price?this.mapPriceWithTotalPrice(b.price,y,b.usageLimit):null,pricingType:a.pricingType,addons:((d=a.addons)===null||d===void 0?void 0:d.map((function(E){var w=E.quantity,D=E.addon;return {quantity:w,addon:m.mapAddon(D)}})))||[],startDate:a.startDate,endDate:this.mapDate(a.endDate),trialEndDate:this.mapDate(a.trialEndDate),cancellationDate:this.mapDate(a.cancellationDate),effectiveEndDate:this.mapDate(a.effectiveEndDate),metadata:a.additionalMetaData,experimentInfo:uu()(a.experimentInfo,"__typename"),scheduledUpdates:a.scheduledUpdates||[],futureUpdates:a.futureUpdates||[],latestInvoice:this.mapLatestInvoice(a.latestInvoice),paymentCollection:a.paymentCollection,paymentCollectionMethod:a.paymentCollectionMethod||void 0}},f.prototype.mapLatestInvoice=function(a){return a?Xe(Xe({},a),{createdAt:this.mapDate(a.createdAt),updatedAt:this.mapDate(a.updatedAt)}):void 0},f.prototype.mapDate=function(a){return a?new Date(a):void 0},f.prototype.mapAddon=function(a){var l,d,m=this;return {hiddenFromWidgets:a.hiddenFromWidgets,id:a.refId,displayName:a.displayName,description:a.description||"",billingId:a.billingId,entitlements:Ji()(a.entitlements,(function(y){return m.mapPackageEntitlement(y)})),pricePoints:Ji()(a.prices,(function(y){return m.mapPrice(y)})),pricingType:a.pricingType,dependencies:((l=a.dependencies)===null||l===void 0?void 0:l.map((function(y){return m.mapDependencyAddon(y)})))||[],metadata:a.additionalMetaData,maxQuantity:(d=a.maxQuantity)!==null&&d!==void 0?d:void 0}},f.prototype.mapTaxFields=function(a){return a!=null&&a.tax&&(a!=null&&a.taxDetails)?{tax:this.mapMoney(a.tax),taxDetails:{displayName:a.taxDetails.displayName,percentage:a.taxDetails.percentage,inclusive:a.taxDetails.inclusive}}:{}},f.prototype.mapSubscriptionPreview=function(a){var l=a.subscription,d=a.proration,m=a.billingPeriodRange,y=a.credits;return Xe(Xe(Xe({total:this.mapMoney(a.total),totalExcludingTax:this.mapMoney(a.totalExcludingTax),subTotal:this.mapMoney(a.subTotal),discountAmount:a.discountAmount?this.mapMoney(a.discountAmount):void 0},this.mapTaxFields(a)),a.discount?{discount:this.mapDiscount(a.discount)}:{}),{billingPeriodRange:{start:m.start&&new Date(m.start),end:m.end&&new Date(m.end)},proration:d?{credit:this.mapMoney(d.credit),debit:this.mapMoney(d.debit),netAmount:this.mapMoney(d.netAmount),prorationDate:new Date(d.prorationDate)}:void 0,subscription:l?Xe(Xe({total:this.mapMoney(l.total),totalExcludingTax:this.mapMoney(l.totalExcludingTax),subTotal:this.mapMoney(l.subTotal),discountAmount:l.discountAmount?this.mapMoney(l.discountAmount):void 0},l.discount?{discount:this.mapDiscount(l.discount)}:{}),this.mapTaxFields(l)):void 0,isPlanDowngrade:!!a.isPlanDowngrade,hasScheduledUpdates:!!a.hasScheduledUpdates,credits:y?{initial:this.mapMoney(y.initial),used:this.mapMoney(y.used),remaining:this.mapMoney(y.remaining)}:void 0})},f.prototype.mapCredits=function(a){return {initial:this.mapMoney(a.initial),used:this.mapMoney(a.used),remaining:this.mapMoney(a.remaining)}},f.prototype.mapSubscriptionPreviewV2=function(a){var l=a.immediateInvoice,d=a.recurringInvoice,m=a.billingPeriodRange,y=a.hasScheduledUpdates,b=a.isPlanDowngrade;return {immediateInvoice:Xe(Xe({},this.mapSubscriptionPreviewInvoice(l)),{proration:l.proration?{credit:this.mapMoney(l.proration.credit),debit:this.mapMoney(l.proration.debit),netAmount:this.mapMoney(l.proration.netAmount),prorationDate:new Date(l.proration.prorationDate),hasProrations:l.proration.hasProrations||void 0}:void 0,credits:l.credits?this.mapCredits(l.credits):void 0}),recurringInvoice:d?Xe({},this.mapSubscriptionPreviewInvoice(d)):void 0,billingPeriodRange:{start:m.start&&new Date(m.start),end:m.end&&new Date(m.end)},isPlanDowngrade:!!b,hasScheduledUpdates:!!y}},f.prototype.mapSubscriptionPreviewInvoice=function(a){return Xe(Xe({total:this.mapMoney(a.total),subTotal:this.mapMoney(a.subTotal),totalExcludingTax:this.mapMoney(a.totalExcludingTax),discount:a.discount?this.mapMoney(a.discount):void 0},a.discountDetails?{discountDetails:this.mapDiscount(a.discountDetails)}:{}),this.mapTaxFields(a))},f.prototype.mapDiscount=function(a){var l=a.name,d=a.type,m=a.value,y=a.durationType,b=a.durationInMonths;return Xe({name:l,type:d,value:m,durationType:y},b?{durationInMonths:b}:{})},f.prototype.mapMoney=function(a){return {amount:a.amount,currency:a.currency}},f.prototype.mapCoupon=function(a){return {id:a.refId,name:a.name,description:a.description,metadata:a.additionalMetaData,discountValue:a.discountValue,percentOff:a.percentOff,amountsOff:a.amountsOff}},f.prototype.mapSubscriptions=function(a){var l=this;return a.map((function(d){return l.mapSubscription(d)}))},f.prototype.mapUsageHistory=function(a){return a.usageMeasurements.map((function(l){var d=l.date,m=l.value,y=l.isResetPoint;return {date:new Date(d),value:m,isResetPoint:!!y}}))},f.prototype.getPriceCurrency=function(a){var l,d,m=a.price,y=a.tiers;return (m==null?void 0:m.currency)||((l=y==null?void 0:y[0].unitPrice)===null||l===void 0?void 0:l.currency)||((d=y==null?void 0:y[0].flatPrice)===null||d===void 0?void 0:d.currency)||h.Fa6.Usd},f.prototype.mapCompatiblePackageGroups=function(a){var l=this;return a.pricingType!==h._HY.Free&&a.compatiblePackageGroups?a.compatiblePackageGroups.map((function(d){var m=d.packageGroupId,y=d.displayName,b=d.options,E=d.addons;return {packageGroupId:m,displayName:y,addons:(E==null?void 0:E.map((function(w){return l.mapAddon(w)})))||[],options:{minItems:(b==null?void 0:b.minItems)||void 0,freeItems:(b==null?void 0:b.freeItems)||void 0}}})):[]},f.prototype.mapDependencyAddon=function(a){return {refId:a.refId,displayName:a.displayName,description:a.description||void 0}},f})();let Jo=function(f,a){this.calculatedEntitlement=f,this.featureUsage=a;};var Ms=(function(){function f(){}return f.decideEntitlementPolicy=function(a,l,d){var m,y;if(l===void 0&&(l=0),d===void 0&&(d=[]),!a||!a.calculatedEntitlement.feature)return {hasAccess:false,accessDeniedReason:h.fEx.NoFeatureEntitlementInSubscription};if(a.calculatedEntitlement.accessDeniedReason)return {hasAccess:false,accessDeniedReason:a.calculatedEntitlement.accessDeniedReason};switch(a.calculatedEntitlement.feature.featureType){case h.Tex.Boolean:return {hasAccess:true};case h.Tex.Enum:var b=(0, R.difference)(d,a.calculatedEntitlement.enumValues||[]);return (0, R.isEmpty)(b)?{hasAccess:true}:{hasAccess:false,accessDeniedReason:h.fEx.RequestedValuesMismatch};case h.Tex.Number:if(((m=a.calculatedEntitlement.feature)===null||m===void 0?void 0:m.meterType)===h.puT.None)return {hasAccess:true};if(a.calculatedEntitlement.hasUnlimitedUsage||a.calculatedEntitlement.hasSoftLimit)return {hasAccess:true};var E=((y=a.calculatedEntitlement)===null||y===void 0?void 0:y.usageLimit)||0;return a.featureUsage.currentUsage+l<=E?{hasAccess:true}:{hasAccess:false,accessDeniedReason:h.fEx.RequestedUsageExceedingLimit}}},f})(),mh=n(7484),du=n.n(mh),ta,gh=[h.puT.Incremental,h.puT.Fluctuating],ti=function(){return ti=Object.assign||function(f){for(var a,l=1,d=arguments.length;l<d;l++)for(var m in a=arguments[l])Object.prototype.hasOwnProperty.call(a,m)&&(f[m]=a[m]);return f},ti.apply(this,arguments)},Ns=function(f,a,l,d){return new(l||(l=Promise))((function(m,y){function b(D){try{w(d.next(D));}catch(_){y(_);}}function E(D){try{w(d.throw(D));}catch(_){y(_);}}function w(D){var _;D.done?m(D.value):(_=D.value,_ instanceof l?_:new l((function(M){M(_);}))).then(b,E);}w((d=d.apply(f,[])).next());}))},mr=function(f,a){var l,d,m,y,b={label:0,sent:function(){if(1&m[0])throw m[1];return m[1]},trys:[],ops:[]};return y={next:E(0),throw:E(1),return:E(2)},typeof Symbol=="function"&&(y[Symbol.iterator]=function(){return this}),y;function E(w){return function(D){return (function(_){if(l)throw new TypeError("Generator is already executing.");for(;b;)try{if(l=1,d&&(m=2&_[0]?d.return:_[0]?d.throw||((m=d.return)&&m.call(d),0):d.next)&&!(m=m.call(d,_[1])).done)return m;switch(d=0,m&&(_=[2&_[0],m.value]),_[0]){case 0:case 1:m=_;break;case 4:return b.label++,{value:_[1],done:!1};case 5:b.label++,d=_[1],_=[0];continue;case 7:_=b.ops.pop(),b.trys.pop();continue;default:if(!((m=(m=b.trys).length>0&&m[m.length-1])||_[0]!==6&&_[0]!==2)){b=0;continue}if(_[0]===3&&(!m||_[1]>m[0]&&_[1]<m[3])){b.label=_[1];break}if(_[0]===6&&b.label<m[1]){b.label=m[1],m=_;break}if(m&&b.label<m[2]){b.label=m[2],b.ops.push(_);break}m[2]&&b.ops.pop(),b.trys.pop();continue}_=a.call(f,b);}catch(M){_=[6,M],d=0;}finally{l=m=0;}if(5&_[0])throw _[1];return {value:_[0]?_[1]:void 0,done:true}})([w,D])}}},fi=(function(){function f(a,l,d,m,y,b,E){this.customerId=a,this.resourceId=l,this.cacheService=d,this.loggerService=b,this.onEntitlementsUpdated=E,this.modelMapper=new hh,this.loadingEntitlements=null,this.entitlementsApi=new Jd(m,y);}return f.prototype.refresh=function(){return Ns(this,void 0,void 0,(function(){return mr(this,(function(a){switch(a.label){case 0:return [4,this.loadEntitlements(true)];case 1:return a.sent(),[2]}}))}))},Object.defineProperty(f.prototype,"isInitialized",{get:function(){return this.cacheService.isLoaded()},enumerable:false,configurable:true}),f.prototype.getBooleanEntitlement=function(a,l,d){var m=this.getEntitlement(a),y=Ms.decideEntitlementPolicy(m);return m!=null&&m.calculatedEntitlement.feature&&m.calculatedEntitlement.feature.featureType!==h.Tex.Boolean?l:m?this.modelMapper.mapBooleanEntitlement(m,y):ti(ti({},y),{isFallback:false})},f.prototype.getNumericEntitlement=function(a,l,d){var m,y=this.getEntitlement(a),b=Ms.decideEntitlementPolicy(y);return y!=null&&y.calculatedEntitlement.feature&&((m=y.calculatedEntitlement.feature)===null||m===void 0?void 0:m.featureType)!==h.Tex.Number?l:y?this.modelMapper.mapNumericEntitlement(y,b):ti(ti({},b),{isFallback:false,isUnlimited:false})},f.prototype.getMeteredEntitlement=function(a,l,d){var m,y,b=d==null?void 0:d.requestedUsage,E=this.getEntitlement(a),w=this.handleUsagePeriodOver(E),D=Ms.decideEntitlementPolicy(w,b);return w!=null&&w.calculatedEntitlement.feature&&((m=w.calculatedEntitlement.feature)===null||m===void 0?void 0:m.meterType)!==h.puT.Fluctuating&&((y=w.calculatedEntitlement.feature)===null||y===void 0?void 0:y.meterType)!==h.puT.Incremental?l:w?this.modelMapper.mapMeteredEntitlement(w,D,b):ti(ti({},D),{currentUsage:0,isFallback:false,isUnlimited:false,requestedUsage:b||0})},f.prototype.handleUsagePeriodOver=function(a){var l,d,m=new Date;if(!(a&&((d=a.calculatedEntitlement.feature)==null?void 0:d.featureType)===h.Tex.Number&&!(0, R.isNil)(d.meterType)&&gh.includes(d.meterType)&&a.featureUsage.usagePeriodEnd&&a.featureUsage.usagePeriodEnd.getTime()<m.getTime()))return a;var y,b,E=a.calculatedEntitlement,w=a.featureUsage,D=w.resetPeriod,_=w.usagePeriodAnchor;return _&&D&&(y=(l=(function(M,B,H){var K=du()(B),J=du()(M),tt=(function(zt){switch(zt){case h.XHu.Year:return "years";case h.XHu.Month:return "months";case h.XHu.Week:return "weeks";case h.XHu.Day:return "days";case h.XHu.Hour:return "hours";default:throw new Error("Unsupported reset period")}})(H),yt=Math.floor(K.diff(J,tt,true)),Rt=J.clone().add(yt,tt),Zt=J.clone().add(yt+1,tt);return {usagePeriodStart:Rt.toDate(),usagePeriodEnd:Zt.toDate()}})(new Date(_),m,D)).usagePeriodStart,b=l.usagePeriodEnd),new Jo(E,ti(ti({},w),{currentUsage:0,usagePeriodStart:y,usagePeriodEnd:b}))},f.prototype.getEnumEntitlement=function(a,l,d){var m,y=this.cacheService.getEntitlement(a),b=d==null?void 0:d.requestedValues,E=Ms.decideEntitlementPolicy(y,void 0,b);return y!=null&&y.calculatedEntitlement.feature&&((m=y.calculatedEntitlement.feature)===null||m===void 0?void 0:m.featureType)!==h.Tex.Enum?l:y?this.modelMapper.mapEnumEntitlement(y,E,b):ti(ti({},E),{isFallback:false,enumValues:[],requestedValues:b||[]})},f.prototype.loadEntitlements=function(a){return Ns(this,void 0,void 0,(function(){return mr(this,(function(l){switch(l.label){case 0:this.loadingEntitlements||(this.loadingEntitlements=this.loadEntitlementsFromRemote(a)),l.label=1;case 1:return l.trys.push([1,,3,4]),[4,this.loadingEntitlements];case 2:return [2,l.sent()];case 3:return this.loadingEntitlements=null,[7];case 4:return [2]}}))}))},f.prototype.loadEntitlementsFromRemote=function(a){return Ns(this,void 0,void 0,(function(){var l;return mr(this,(function(d){switch(d.label){case 0:return [4,this.entitlementsApi.getEntitlements(this.customerId,a,this.resourceId)];case 1:return l=d.sent(),this.storeFetchedEntitlementsInCache(l.data.entitlements),[2]}}))}))},f.prototype.storeFetchedEntitlementsInCache=function(a){this.cacheService.updateLastChecked();var l=this.cacheService.getLastUpdate(),d=this.getLastEntitlementsUpdate(a);if(!(l&&d.getTime()<l.getTime())){var m=this.modelMapper.mapCachedEntitlements(a);this.cacheService.setEntitlements(m,d),this.onEntitlementsUpdated(m);}},f.prototype.getLastEntitlementsUpdate=function(a){return (0, R.max)(a.flatMap((function(l){return [new Date(l.entitlementUpdatedAt),new Date(l.usageUpdatedAt)]})))||new Date},f.prototype.getEntitlement=function(a){var l=this.cacheService.getEntitlement(a);return this.renewOutdatedCacheInBackground(),l},f.prototype.getEntitlements=function(){return Ns(this,void 0,void 0,(function(){var a=this;return mr(this,(function(l){switch(l.label){case 0:return [4,this.renewOutdatedCache()];case 1:return l.sent(),[2,Array.from(this.cacheService.getEntitlements().values()).map((function(d){var m=Ms.decideEntitlementPolicy(d);return a.modelMapper.mapEntitlement(d,m)}))]}}))}))},f.prototype.renewOutdatedCache=function(){return Ns(this,void 0,void 0,(function(){return mr(this,(function(a){switch(a.label){case 0:return !this.cacheService.isLoaded()||this.cacheService.isOutdated()?[4,this.loadEntitlements()]:[3,2];case 1:a.sent(),a.label=2;case 2:return [2]}}))}))},f.prototype.renewOutdatedCacheInBackground=function(){var a=this;this.renewOutdatedCache().catch((function(l){a.loggerService.error("Failed to renew cache in background",l);}));},f})(),pu=n(2527),Ls=(function(){var f=function(a,l){return f=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(d,m){d.__proto__=m;}||function(d,m){for(var y in m)Object.prototype.hasOwnProperty.call(m,y)&&(d[y]=m[y]);},f(a,l)};return function(a,l){if(typeof l!="function"&&l!==null)throw new TypeError("Class extends value "+String(l)+" is not a constructor or null");function d(){this.constructor=a;}f(a,l),a.prototype=l===null?Object.create(l):(d.prototype=l.prototype,new d);}})(),yh=(function(f){function a(){return f.call(this)||this}return Ls(a,f),a})(pu.TypedEmitter),fu=(function(){function f(a){var l=this;a===void 0&&(a=3e4),this.ttlMs=a,this.setFeatures=function(d){return l.features=new Set(d)},this.ttlMs=a,this.entitlements=new Map,this.features=new Set,this.lastUpdate=null,this.lastChecked=null;}return f.prototype.getEntitlement=function(a){return this.entitlements.get(a)||null},f.prototype.validateFeature=function(a){return this.features.has(a)},f.prototype.updateLastChecked=function(){this.lastChecked=new Date;},f.prototype.setEntitlements=function(a,l){this.entitlements=a,this.lastUpdate=l;},f.prototype.getEntitlements=function(){return this.entitlements},f.prototype.getLastUpdate=function(){return this.lastUpdate},f.prototype.isLoaded=function(){return !!this.lastUpdate},f.prototype.isOutdated=function(){return this.lastChecked===null||new Date().getTime()-this.lastChecked.getTime()>this.ttlMs},f})();(function(f){f.IN_PROGRESS="IN_PROGRESS",f.SUCCESS="READY",f.FAILED="FAILED";})(ta||(ta={}));var bh=(function(){function f(a){this.eventEmitter=a,this.initializationPromise=null,this.initializationStatus=ta.IN_PROGRESS,this.initFailureError=null;}return f.prototype.getInitializationPromise=function(){var a=this;return this.initializationPromise?this.initializationPromise:this.initializationStatus===ta.SUCCESS?Promise.resolve():this.initializationStatus===ta.FAILED?Promise.reject(this.initFailureError):(this.initializationPromise=new Promise((function(l,d){a.eventEmitter.once("initializeSuccessfully",(function(){l();})),a.eventEmitter.once("initializeFailed",(function(m){d(m);}));})),this.initializationPromise)},f.prototype.signalSuccessInit=function(){this.initializationStatus=ta.SUCCESS,this.eventEmitter.emit("initializeSuccessfully");},f.prototype.signalFailedInit=function(a){this.initializationStatus=ta.FAILED,this.initFailureError=a,this.eventEmitter.emit("initializeFailed",a);},f})(),_n=n(2991),Bs=Object.prototype.toString;function ep(f){switch(Bs.call(f)){case "[object Error]":case "[object Exception]":case "[object DOMException]":return true;default:return wo(f,Error)}}function Ma(f,a){return Bs.call(f)===`[object ${a}]`}function Hl(f){return Ma(f,"ErrorEvent")}function np(f){return Ma(f,"DOMError")}function _o(f){return Ma(f,"String")}function hu(f){return f===null||typeof f!="object"&&typeof f!="function"}function To(f){return Ma(f,"Object")}function mu(f){return typeof Event!="undefined"&&wo(f,Event)}function Us(f){return !!(f&&f.then&&typeof f.then=="function")}function wo(f,a){try{return f instanceof a}catch(l){return false}}function Wl(f,a){try{let m=f;var l=[];let y=0,b=0;var d=3;let E;for(;m&&y++<5&&(E=Xy(m,a),!(E==="html"||y>1&&b+l.length*d+E.length>=80));)l.push(E),b+=E.length,m=m.parentNode;return l.reverse().join(" > ")}catch(m){return "<unknown>"}}function Xy(f,a){var l=f,d=[];let m,y,b,E,w;if(!l||!l.tagName)return "";d.push(l.tagName.toLowerCase());var D=a&&a.length?a.filter((M=>l.getAttribute(M))).map((M=>[M,l.getAttribute(M)])):null;if(D&&D.length)D.forEach((M=>{d.push(`[${M[0]}="${M[1]}"]`);}));else if(l.id&&d.push(`#${l.id}`),m=l.className,m&&_o(m))for(y=m.split(/\s+/),w=0;w<y.length;w++)d.push(`.${y[w]}`);var _=["type","name","title","alt"];for(w=0;w<_.length;w++)b=_[w],E=l.getAttribute(b),E&&d.push(`[${b}="${E}"]`);return d.join("")}function $s(f,a=0){return typeof f!="string"||a===0||f.length<=a?f:`${f.substr(0,a)}...`}function to(f,a){if(!Array.isArray(f))return "";var l=[];for(let m=0;m<f.length;m++){var d=f[m];try{l.push(String(d));}catch(y){l.push("[value cannot be serialized]");}}return l.join(a)}function gu(f,a){return !!_o(f)&&(Ma(a,"RegExp")?a.test(f):typeof a=="string"&&f.indexOf(a)!==-1)}function xr(f,a,l){if(a in f){var d=f[a],m=l(d);if(typeof m=="function")try{ip(m,d);}catch(y){}f[a]=m;}}function rp(f,a,l){Object.defineProperty(f,a,{value:l,writable:true,configurable:true});}function ip(f,a){var l=a.prototype||{};f.prototype=a.prototype=l,rp(f,"__sentry_original__",a);}function Ni(f){return f.__sentry_original__}function yu(f){if(ep(f))return W({message:f.message,name:f.name,stack:f.stack},vu(f));if(mu(f)){var a=W({type:f.type,target:bu(f.target),currentTarget:bu(f.currentTarget)},vu(f));return typeof CustomEvent!="undefined"&&wo(f,CustomEvent)&&(a.detail=f.detail),a}return f}function bu(f){try{return typeof Element!="undefined"&&wo(f,Element)?Wl(f):Object.prototype.toString.call(f)}catch(a){return "<unknown>"}}function vu(f){if(typeof f=="object"&&f!==null){var a={};for(var l in f)Object.prototype.hasOwnProperty.call(f,l)&&(a[l]=f[l]);return a}return {}}function Cu(f,a=40){var l=Object.keys(yu(f));if(l.sort(),!l.length)return "[object has no keys]";if(l[0].length>=a)return $s(l[0],a);for(let m=l.length;m>0;m--){var d=l.slice(0,m).join(", ");if(!(d.length>a))return m===l.length?d:$s(d,a)}return ""}function ea(f){return ue(f,new Map)}function ue(f,a){if(To(f)){if((m=a.get(f))!==void 0)return m;var l={};for(var d of(a.set(f,l),Object.keys(f)))f[d]!==void 0&&(l[d]=ue(f[d],a));return l}var m;return Array.isArray(f)?(m=a.get(f))!==void 0?m:(l=[],a.set(f,l),f.forEach((y=>{l.push(ue(y,a));})),l):f}let ql;class Na{constructor(){Na.prototype.__init.call(this);}static __initStatic(){this.id="FunctionToString";}__init(){this.name=Na.id;}setupOnce(){ql=Function.prototype.toString,Function.prototype.toString=function(...a){var l=Ni(this)||this;return ql.apply(l,a)};}}Na.__initStatic();var La=(0, _n.R)(),Gs=["debug","info","warn","error","log","assert","trace"];function op(f){var a=(0, _n.R)();if(!("console"in a))return f();var l=a.console,d={};Gs.forEach((m=>{var y=l[m]&&l[m].__sentry_original__;m in a.console&&y&&(d[m]=l[m],l[m]=y);}));try{return f()}finally{Object.keys(d).forEach((m=>{l[m]=d[m];}));}}function Er(){let f=false;var a={enable:()=>{f=true;},disable:()=>{f=false;}};return typeof __SENTRY_DEBUG__=="undefined"||__SENTRY_DEBUG__?Gs.forEach((l=>{a[l]=(...d)=>{f&&op((()=>{La.console[l](`Sentry Logger [${l}]:`,...d);}));};})):Gs.forEach((l=>{a[l]=()=>{};})),a}let Fe;function Ba(){var f=(0, _n.R)(),a=f.crypto||f.msCrypto;if(a&&a.randomUUID)return a.randomUUID().replace(/-/g,"");var l=a&&a.getRandomValues?()=>a.getRandomValues(new Uint8Array(1))[0]:()=>16*Math.random();return ("10000000100040008000"+1e11).replace(/[018]/g,(d=>(d^(15&l())>>d/4).toString(16)))}function vh(f){return f.exception&&f.exception.values?f.exception.values[0]:void 0}function Br(f){let{message:a,event_id:l}=f;if(a)return a;var d=vh(f);return d?d.type&&d.value?`${d.type}: ${d.value}`:d.type||d.value||l||"<unknown>":l||"<unknown>"}function _r(f,a,l){var d=f.exception=f.exception||{},m=d.values=d.values||[],y=m[0]=m[0]||{};y.value||(y.value=a||""),y.type||(y.type="Error");}function Ua(f,a){var l=vh(f);if(l){var d=l.mechanism;if(l.mechanism=W(W({type:"generic",handled:true},d),a),a&&"data"in a){var m=W(W({},d&&d.data),a.data);l.mechanism.data=m;}}}function Su(f){if(f&&f.__sentry_captured__)return true;try{rp(f,"__sentry_captured__",!0);}catch(a){}return false}Fe=typeof __SENTRY_DEBUG__=="undefined"||__SENTRY_DEBUG__?(0, _n.Y)("logger",Er):Er();var Zy=[/^Script error\.?$/,/^Javascript error: Script error\.? on line 0$/];class eo{static __initStatic(){this.id="InboundFilters";}__init(){this.name=eo.id;}constructor(a={}){this._options=a,eo.prototype.__init.call(this);}setupOnce(a,l){var d=m=>{var y=l();if(y){var b=y.getIntegration(eo);if(b){var E=y.getClient(),w=E?E.getOptions():{},D=(function(_={},M={}){return {allowUrls:[..._.allowUrls||[],...M.allowUrls||[]],denyUrls:[..._.denyUrls||[],...M.denyUrls||[]],ignoreErrors:[..._.ignoreErrors||[],...M.ignoreErrors||[],...Zy],ignoreInternal:_.ignoreInternal===void 0||_.ignoreInternal}})(b._options,w);return (function(_,M){return M.ignoreInternal&&(function(B){try{return B.exception.values[0].type==="SentryError"}catch(H){}return false})(_)?((typeof __SENTRY_DEBUG__=="undefined"||__SENTRY_DEBUG__)&&Fe.warn(`Event dropped due to being internal Sentry Error.
2375
2375
  Event: ${Br(_)}`),true):(function(B,H){return !(!H||!H.length)&&(function(K){if(K.message)return [K.message];if(K.exception)try{let{type:J="",value:tt=""}=K.exception.values&&K.exception.values[0]||{};return [`${tt}`,`${J}: ${tt}`]}catch(J){return (typeof __SENTRY_DEBUG__=="undefined"||__SENTRY_DEBUG__)&&Fe.error(`Cannot extract message for event ${Br(K)}`),[]}return []})(B).some((K=>H.some((J=>gu(K,J)))))})(_,M.ignoreErrors)?((typeof __SENTRY_DEBUG__=="undefined"||__SENTRY_DEBUG__)&&Fe.warn(`Event dropped due to being matched by \`ignoreErrors\` option.
2376
2376
  Event: ${Br(_)}`),true):(function(B,H){if(!H||!H.length)return false;var K=Yl(B);return !!K&&H.some((J=>gu(K,J)))})(_,M.denyUrls)?((typeof __SENTRY_DEBUG__=="undefined"||__SENTRY_DEBUG__)&&Fe.warn(`Event dropped due to being matched by \`denyUrls\` option.
2377
2377
  Event: ${Br(_)}.
@@ -2384,7 +2384,7 @@ Error:`,d);}}function hi(f=[]){return "Request"in Tn&&wo(f[0],Request)&&f[0].met
2384
2384
  `).slice(d)){var b=y.replace(/\(error: (.*)\)/,"$1");for(var E of a){var w=E(b);if(w){m.push(w);break}}}return (function(D){if(!D.length)return [];let _=D;var M=_[0].function||"",B=_[_.length-1].function||"";return M.indexOf("captureMessage")===-1&&M.indexOf("captureException")===-1||(_=_.slice(1)),B.indexOf("sentryWrapped")!==-1&&(_=_.slice(0,-1)),_.slice(0,50).map((H=>St(W({},H),{filename:H.filename||_[0].filename,function:H.function||"?"}))).reverse()})(m)}})([30,f=>{var a=Bn.exec(f);if(a){if(a[2]&&a[2].indexOf("eval")===0){var l=zn.exec(a[2]);l&&(a[2]=l[1],a[3]=l[2],a[4]=l[3]);}let[d,m]=Sp(a[1]||ec,a[2]);return Ws(m,d,a[3]?+a[3]:void 0,a[4]?+a[4]:void 0)}}],[50,f=>{var a=Mh.exec(f);if(a){if(a[3]&&a[3].indexOf(" > eval")>-1){var l=Nh.exec(a[3]);l&&(a[1]=a[1]||"eval",a[3]=l[1],a[4]=l[2],a[5]="");}let d=a[3],m=a[1]||ec;return [m,d]=Sp(m,d),Ws(d,m,a[4]?+a[4]:void 0,a[5]?+a[5]:void 0)}}],[40,f=>{var a=nc.exec(f);return a?Ws(a[2],a[1]||ec,+a[3],a[4]?+a[4]:void 0):void 0}]),Sp=(f,a)=>{var l=f.indexOf("safari-extension")!==-1,d=f.indexOf("safari-web-extension")!==-1;return l||d?[f.indexOf("@")!==-1?f.split("@")[0]:ec,l?`safari-extension:${a}`:`safari-web-extension:${a}`]:[f,a]};class rr extends Error{constructor(a,l="warn"){super(a),this.message=a,this.name=new.target.prototype.constructor.name,Object.setPrototypeOf(this,new.target.prototype),this.logLevel=l;}}function Fr(f,a=[]){return [f,a]}function qs(f,a){let[l,d]=f;return [l,[...d,a]]}function Lh(f,a){f[1].forEach((l=>{var d=l[0].type;a(l,d);}));}function Pp(f,a){return (a||new TextEncoder).encode(f)}function xp(f,a){let[l,d]=f,m=JSON.stringify(l);function y(E){typeof m=="string"?m=typeof E=="string"?m+E:[Pp(m,a),E]:m.push(typeof E=="string"?Pp(E,a):E);}for(var b of d){let[E,w]=b;y(`
2385
2385
  ${JSON.stringify(E)}
2386
2386
  `),y(typeof w=="string"||w instanceof Uint8Array?w:JSON.stringify(w));}return typeof m=="string"?m:(function(E){var w=E.reduce(((B,H)=>B+H.length),0),D=new Uint8Array(w);let _=0;for(var M of E)D.set(M,_),_+=M.length;return D})(m)}function Ao(f,a){var l=typeof f.data=="string"?Pp(f.data,a):f.data;return [ea({type:"attachment",length:l.length,filename:f.filename,content_type:f.contentType,attachment_type:f.attachmentType}),l]}var we={session:"session",sessions:"session",attachment:"attachment",transaction:"transaction",event:"error",client_report:"internal",user_report:"default"};function Ep(f){return we[f]}function ei(f,a,l=(function(d){var m=[];function y(b){return m.splice(m.indexOf(b),1)[0]}return {$:m,add:function(b){if(!(d===void 0||m.length<d))return Ql(new rr("Not adding Promise due to buffer limit reached."));var E=b();return m.indexOf(E)===-1&&m.push(E),E.then((()=>y(E))).then(null,(()=>y(E).then(null,(()=>{})))),E},drain:function(b){return new Or(((E,w)=>{let D=m.length;if(!D)return E(true);var _=setTimeout((()=>{b&&b>0&&E(false);}),b);m.forEach((M=>{Ga(M).then((()=>{--D||(clearTimeout(_),E(true));}),w);}));}))}}})(f.bufferSize||30)){let d={};return {send:function(m){var y=[];if(Lh(m,((w,D)=>{var _=Ep(D);(function(M,B,H=Date.now()){return (function(K,J){return K[J]||K.all||0})(M,B)>H})(d,_)?f.recordDroppedEvent("ratelimit_backoff",_):y.push(w);})),y.length===0)return Ga();var b=Fr(m[0],y),E=w=>{Lh(b,((D,_)=>{f.recordDroppedEvent(w,Ep(_));}));};return l.add((()=>a({body:xp(b,f.textEncoder)}).then((w=>{w.statusCode!==void 0&&(w.statusCode<200||w.statusCode>=300)&&(typeof __SENTRY_DEBUG__=="undefined"||__SENTRY_DEBUG__)&&Fe.warn(`Sentry responded with status code ${w.statusCode} to sent event.`),d=(function(D,{statusCode:_,headers:M},B=Date.now()){var H=W({},D),K=M&&M["x-sentry-rate-limits"],J=M&&M["retry-after"];if(K)for(var tt of K.trim().split(",")){let[zt,Bt]=tt.split(":",2);var yt=parseInt(zt,10),Rt=1e3*(isNaN(yt)?60:yt);if(Bt)for(var Zt of Bt.split(";"))H[Zt]=B+Rt;else H.all=B+Rt;}else J?H.all=B+(function(zt,Bt=Date.now()){var qt=parseInt(`${zt}`,10);if(!isNaN(qt))return 1e3*qt;var $e=Date.parse(`${zt}`);return isNaN($e)?6e4:$e-Bt})(J,B):_===429&&(H.all=B+6e4);return H})(d,w);}),(w=>{(typeof __SENTRY_DEBUG__=="undefined"||__SENTRY_DEBUG__)&&Fe.error("Failed while sending event:",w),E("network_error");})))).then((w=>w),(w=>{if(w instanceof rr)return (typeof __SENTRY_DEBUG__=="undefined"||__SENTRY_DEBUG__)&&Fe.error("Skipped sending event due to full buffer"),E("queue_overflow"),Ga();throw w}))},flush:m=>l.drain(m)}}var gi=(0, _n.R)();let qe;function Bh(){if(qe)return qe;if(_u(gi.fetch))return qe=gi.fetch.bind(gi);var f=gi.document;let a=gi.fetch;if(f&&typeof f.createElement=="function")try{var l=f.createElement("iframe");l.hidden=!0,f.head.appendChild(l);var d=l.contentWindow;d&&d.fetch&&(a=d.fetch),f.head.removeChild(l);}catch(m){(typeof __SENTRY_DEBUG__=="undefined"||__SENTRY_DEBUG__)&&Fe.warn("Could not create sandbox iframe for pure fetch check, bailing to window.fetch: ",m);}return qe=a.bind(gi)}function Uh(f,a=Bh()){return ei(f,(function(l){var d=W({body:l.body,method:"POST",referrerPolicy:"origin",headers:f.headers},f.fetchOptions);return a(f.url,d).then((m=>({statusCode:m.status,headers:{"x-sentry-rate-limits":m.headers.get("X-Sentry-Rate-Limits"),"retry-after":m.headers.get("Retry-After")}})))}))}function ku(f){return ei(f,(function(a){return new Or(((l,d)=>{var m=new XMLHttpRequest;for(var y in m.onerror=d,m.onreadystatechange=()=>{m.readyState===4&&l({statusCode:m.status,headers:{"x-sentry-rate-limits":m.getResponseHeader("X-Sentry-Rate-Limits"),"retry-after":m.getResponseHeader("Retry-After")}});},m.open("POST",f.url),f.headers)Object.prototype.hasOwnProperty.call(f.headers,y)&&m.setRequestHeader(y,f.headers[y]);m.send(a.body);}))}))}var cb=/^(?:(\w+):)\/\/(?:(\w+)(?::(\w+))?@)([\w.-]+)(?::(\d+))?\/(.+)/;function _p(f,a=false){let{host:l,path:d,pass:m,port:y,projectId:b,protocol:E,publicKey:w}=f;return `${E}://${w}${a&&m?`:${m}`:""}@${l}${y?`:${y}`:""}/${d&&`${d}/`}${b}`}function $h(f){return {protocol:f.protocol,publicKey:f.publicKey||"",pass:f.pass||"",host:f.host,port:f.port||"",path:f.path||"",projectId:f.projectId}}function Gh(f,a={}){var l=typeof a=="string"?a:a.tunnel,d=typeof a!="string"&&a._metadata?a._metadata.sdk:void 0;return l||`${(function(m){return `${(function(y){var b=y.protocol?`${y.protocol}:`:"",E=y.port?`:${y.port}`:"";return `${b}//${y.host}${E}${y.path?`/${y.path}`:""}/api/`})(m)}${m.projectId}/envelope/`})(f)}?${(function(m,y){return b=W({sentry_key:m.publicKey,sentry_version:"7"},y&&{sentry_client:`${y.name}/${y.version}`}),Object.keys(b).map((E=>`${encodeURIComponent(E)}=${encodeURIComponent(b[E])}`)).join("&");var b;})(f,d)}`}function Du(f){if(!f||!f.sdk)return;let{name:a,version:l}=f.sdk;return {name:a,version:l}}var Au=[],jh="Not capturing exception because it's already been captured.";class Ys{__init(){this._integrations={};}__init2(){this._integrationsInitialized=false;}__init3(){this._numProcessing=0;}__init4(){this._outcomes={};}constructor(a){if(Ys.prototype.__init.call(this),Ys.prototype.__init2.call(this),Ys.prototype.__init3.call(this),Ys.prototype.__init4.call(this),this._options=a,a.dsn){this._dsn=(d=a.dsn,m=typeof d=="string"?(function(y){var b=cb.exec(y);if(!b)throw new rr(`Invalid Sentry Dsn: ${y}`);let[E,w,D="",_,M="",B]=b.slice(1),H="",K=B;var J=K.split("/");if(J.length>1&&(H=J.slice(0,-1).join("/"),K=J.pop()),K){var tt=K.match(/^\d+/);tt&&(K=tt[0]);}return $h({host:_,pass:D,path:H,projectId:K,port:M,protocol:E,publicKey:w})})(d):$h(d),(function(y){if(typeof __SENTRY_DEBUG__!="undefined"&&!__SENTRY_DEBUG__)return;let{port:b,projectId:E,protocol:w}=y;if(["protocol","publicKey","host","projectId"].forEach((D=>{if(!y[D])throw new rr(`Invalid Sentry Dsn: ${D} missing`)})),!E.match(/^\d+$/))throw new rr(`Invalid Sentry Dsn: Invalid projectId ${E}`);if(!(function(D){return D==="http"||D==="https"})(w))throw new rr(`Invalid Sentry Dsn: Invalid protocol ${w}`);if(b&&isNaN(parseInt(b,10)))throw new rr(`Invalid Sentry Dsn: Invalid port ${b}`)})(m),m);var l=Gh(this._dsn,a);this._transport=a.transport(St(W({recordDroppedEvent:this.recordDroppedEvent.bind(this)},a.transportOptions),{url:l}));}else (typeof __SENTRY_DEBUG__=="undefined"||__SENTRY_DEBUG__)&&Fe.warn("No DSN provided, client will not do anything.");var d,m;}captureException(a,l,d){if(Su(a))return void((typeof __SENTRY_DEBUG__=="undefined"||__SENTRY_DEBUG__)&&Fe.log(jh));let m=l&&l.event_id;return this._process(this.eventFromException(a,l).then((y=>this._captureEvent(y,l,d))).then((y=>{m=y;}))),m}captureMessage(a,l,d,m){let y=d&&d.event_id;var b=hu(a)?this.eventFromMessage(String(a),l,d):this.eventFromException(a,d);return this._process(b.then((E=>this._captureEvent(E,d,m))).then((E=>{y=E;}))),y}captureEvent(a,l,d){if(l&&l.originalException&&Su(l.originalException))return void((typeof __SENTRY_DEBUG__=="undefined"||__SENTRY_DEBUG__)&&Fe.log(jh));let m=l&&l.event_id;return this._process(this._captureEvent(a,l,d).then((y=>{m=y;}))),m}captureSession(a){this._isEnabled()?typeof a.release!="string"?(typeof __SENTRY_DEBUG__=="undefined"||__SENTRY_DEBUG__)&&Fe.warn("Discarded session because of missing or non-string release"):(this.sendSession(a),ro(a,{init:false})):(typeof __SENTRY_DEBUG__=="undefined"||__SENTRY_DEBUG__)&&Fe.warn("SDK not enabled, will not capture session.");}getDsn(){return this._dsn}getOptions(){return this._options}getTransport(){return this._transport}flush(a){var l=this._transport;return l?this._isClientDoneProcessing(a).then((d=>l.flush(a).then((m=>d&&m)))):Ga(true)}close(a){return this.flush(a).then((l=>(this.getOptions().enabled=false,l)))}setupIntegrations(){this._isEnabled()&&!this._integrationsInitialized&&(this._integrations=(function(a){var l={};return a.forEach((d=>{l[d.name]=d,Au.indexOf(d.name)===-1&&(d.setupOnce(Pu,Ln),Au.push(d.name),(typeof __SENTRY_DEBUG__=="undefined"||__SENTRY_DEBUG__)&&Fe.log(`Integration installed: ${d.name}`));})),l})(this._options.integrations),this._integrationsInitialized=true);}getIntegrationById(a){return this._integrations[a]}getIntegration(a){try{return this._integrations[a.id]||null}catch(l){return (typeof __SENTRY_DEBUG__=="undefined"||__SENTRY_DEBUG__)&&Fe.warn(`Cannot retrieve integration ${a.id} from the current Client`),null}}sendEvent(a,l={}){if(this._dsn){let m=(function(y,b,E,w){var D=Du(E),_=y.type||"event";let{transactionSampling:M}=y.sdkProcessingMetadata||{},{method:B,rate:H}=M||{};(function(J,tt){tt&&(J.sdk=J.sdk||{},J.sdk.name=J.sdk.name||tt.name,J.sdk.version=J.sdk.version||tt.version,J.sdk.integrations=[...J.sdk.integrations||[],...tt.integrations||[]],J.sdk.packages=[...J.sdk.packages||[],...tt.packages||[]]);})(y,E&&E.sdk);var K=(function(J,tt,yt,Rt){var Zt=J.sdkProcessingMetadata&&J.sdkProcessingMetadata.baggage,zt=Zt&&(function(Bt){return Bt[0]})(Zt);return W(W(W({event_id:J.event_id,sent_at:new Date().toISOString()},tt&&{sdk:tt}),!!yt&&{dsn:_p(Rt)}),J.type==="transaction"&&zt&&{trace:ea(W({},zt))})})(y,D,w,b);return delete y.sdkProcessingMetadata,Fr(K,[[{type:_,sample_rates:[{id:B,rate:H}]},y]])})(a,this._dsn,this._options._metadata,this._options.tunnel);for(var d of l.attachments||[])m=qs(m,Ao(d,this._options.transportOptions&&this._options.transportOptions.textEncoder));this._sendEnvelope(m);}}sendSession(a){if(this._dsn){var l=(function(d,m,y,b){var E=Du(y);return Fr(W(W({sent_at:new Date().toISOString()},E&&{sdk:E}),!!b&&{dsn:_p(m)}),["aggregates"in d?[{type:"sessions"},d]:[{type:"session"},d]])})(a,this._dsn,this._options._metadata,this._options.tunnel);this._sendEnvelope(l);}}recordDroppedEvent(a,l){if(this._options.sendClientReports){var d=`${a}:${l}`;(typeof __SENTRY_DEBUG__=="undefined"||__SENTRY_DEBUG__)&&Fe.log(`Adding outcome: "${d}"`),this._outcomes[d]=this._outcomes[d]+1||1;}}_updateSessionFromEvent(a,l){let d=false,m=false;var y=l.exception&&l.exception.values;if(y)for(var b of(m=true,y)){var E=b.mechanism;if(E&&E.handled===false){d=true;break}}var w=a.status==="ok";(w&&a.errors===0||w&&d)&&(ro(a,St(W({},d&&{status:"crashed"}),{errors:a.errors||Number(m||d)})),this.captureSession(a));}_isClientDoneProcessing(a){return new Or((l=>{let d=0;var m=setInterval((()=>{this._numProcessing==0?(clearInterval(m),l(true)):(d+=1,a&&d>=a&&(clearInterval(m),l(false)));}),1);}))}_isEnabled(){return this.getOptions().enabled!==false&&this._dsn!==void 0}_prepareEvent(a,l,d){let{normalizeDepth:m=3,normalizeMaxBreadth:y=1e3}=this.getOptions();var b=St(W({},a),{event_id:a.event_id||l.event_id||Ba(),timestamp:a.timestamp||(0, $a.yW)()});this._applyClientOptions(b),this._applyIntegrationsMetadata(b);let E=d;l.captureContext&&(E=io.clone(E).update(l.captureContext));let w=Ga(b);if(E){var D=[...l.attachments||[],...E.getAttachments()];D.length&&(l.attachments=D),w=E.applyToEvent(b,l);}return w.then((_=>typeof m=="number"&&m>0?this._normalizeEvent(_,m,y):_))}_normalizeEvent(a,l,d){if(!a)return null;var m=W(W(W(W(W({},a),a.breadcrumbs&&{breadcrumbs:a.breadcrumbs.map((y=>W(W({},y),y.data&&{data:ko(y.data,l,d)})))}),a.user&&{user:ko(a.user,l,d)}),a.contexts&&{contexts:ko(a.contexts,l,d)}),a.extra&&{extra:ko(a.extra,l,d)});return a.contexts&&a.contexts.trace&&m.contexts&&(m.contexts.trace=a.contexts.trace,a.contexts.trace.data&&(m.contexts.trace.data=ko(a.contexts.trace.data,l,d))),a.spans&&(m.spans=a.spans.map((y=>(y.data&&(y.data=ko(y.data,l,d)),y)))),m}_applyClientOptions(a){var l=this.getOptions();let{environment:d,release:m,dist:y,maxValueLength:b=250}=l;"environment"in a||(a.environment="environment"in l?d:"production"),a.release===void 0&&m!==void 0&&(a.release=m),a.dist===void 0&&y!==void 0&&(a.dist=y),a.message&&(a.message=$s(a.message,b));var E=a.exception&&a.exception.values&&a.exception.values[0];E&&E.value&&(E.value=$s(E.value,b));var w=a.request;w&&w.url&&(w.url=$s(w.url,b));}_applyIntegrationsMetadata(a){var l=Object.keys(this._integrations);l.length>0&&(a.sdk=a.sdk||{},a.sdk.integrations=[...a.sdk.integrations||[],...l]);}_captureEvent(a,l={},d){return this._processEvent(a,l,d).then((m=>m.event_id),(m=>{if(typeof __SENTRY_DEBUG__=="undefined"||__SENTRY_DEBUG__){var y=m;y.logLevel==="log"?Fe.log(y.message):Fe.warn(y);}}))}_processEvent(a,l,d){let{beforeSend:m,sampleRate:y}=this.getOptions();if(!this._isEnabled())return Ql(new rr("SDK not enabled, will not capture event.","log"));var b=a.type==="transaction";return !b&&typeof y=="number"&&Math.random()>y?(this.recordDroppedEvent("sample_rate","error"),Ql(new rr(`Discarding event because it's not included in the random sample (sampling rate = ${y})`,"log"))):this._prepareEvent(a,l,d).then((E=>{if(E===null)throw this.recordDroppedEvent("event_processor",a.type||"error"),new rr("An event processor returned null, will not send event.","log");return l.data&&l.data.__sentry__===true||b||!m?E:(function(w){var D="`beforeSend` method has to return `null` or a valid event.";if(Us(w))return w.then((_=>{if(!To(_)&&_!==null)throw new rr(D);return _}),(_=>{throw new rr(`beforeSend rejected with ${_}`)}));if(!To(w)&&w!==null)throw new rr(D);return w})(m(E,l))})).then((E=>{if(E===null)throw this.recordDroppedEvent("before_send",a.type||"error"),new rr("`beforeSend` returned `null`, will not send event.","log");var w=d&&d.getSession();return !b&&w&&this._updateSessionFromEvent(w,E),this.sendEvent(E,l),E})).then(null,(E=>{throw E instanceof rr?E:(this.captureException(E,{data:{__sentry__:true},originalException:E}),new rr(`Event processing pipeline threw an error, original event will not be sent. Details have been sent as a new event.
2387
- Reason: ${E}`))}))}_process(a){this._numProcessing+=1,a.then((l=>(this._numProcessing-=1,l)),(l=>(this._numProcessing-=1,l)));}_sendEnvelope(a){this._transport&&this._dsn?this._transport.send(a).then(null,(l=>{(typeof __SENTRY_DEBUG__=="undefined"||__SENTRY_DEBUG__)&&Fe.error("Error while sending event:",l);})):(typeof __SENTRY_DEBUG__=="undefined"||__SENTRY_DEBUG__)&&Fe.error("Transport disabled");}_clearOutcomes(){var a=this._outcomes;return this._outcomes={},Object.keys(a).map((l=>{let[d,m]=l.split(":");return {reason:d,category:m,quantity:a[l]}}))}}var Vh="7.11.1",Zn=(0, _n.R)();class Wr extends Ys{constructor(a){a._metadata=a._metadata||{},a._metadata.sdk=a._metadata.sdk||{name:"sentry.javascript.browser",packages:[{name:"npm:@sentry/browser",version:Vh}],version:Vh},super(a),a.sendClientReports&&Zn.document&&Zn.document.addEventListener("visibilitychange",(()=>{Zn.document.visibilityState==="hidden"&&this._flushOutcomes();}));}eventFromException(a,l){return (function(d,m,y,b){var E=wu(d,m,y&&y.syntheticException||void 0,b);return Ua(E),E.level="error",y&&y.event_id&&(E.event_id=y.event_id),Ga(E)})(this._options.stackParser,a,l,this._options.attachStacktrace)}eventFromMessage(a,l="info",d){return (function(m,y,b="info",E,w){var D=zs(m,y,E&&E.syntheticException||void 0,w);return D.level=b,E&&E.event_id&&(D.event_id=E.event_id),Ga(D)})(this._options.stackParser,a,l,d,this._options.attachStacktrace)}sendEvent(a,l){var d=this.getIntegrationById(Jl);d&&d.options&&d.options.sentry&&Ln().addBreadcrumb({category:"sentry."+(a.type==="transaction"?"transaction":"event"),event_id:a.event_id,level:a.level,message:Br(a)},{event:a}),super.sendEvent(a,l);}_prepareEvent(a,l,d){return a.platform=a.platform||"javascript",super._prepareEvent(a,l,d)}_flushOutcomes(){var a=this._clearOutcomes();if(a.length!==0)if(this._dsn){(typeof __SENTRY_DEBUG__=="undefined"||__SENTRY_DEBUG__)&&Fe.log("Sending outcomes:",a);var l,d,m=Gh(this._dsn,this._options),y=(l=a,Fr((d=this._options.tunnel&&_p(this._dsn))?{dsn:d}:{},[[{type:"client_report"},{timestamp:(0, $a.yW)(),discarded_events:l}]]));try{(function(b,E){Object.prototype.toString.call(gi&&gi.navigator)==="[object Navigator]"&&typeof gi.navigator.sendBeacon=="function"?gi.navigator.sendBeacon.bind(gi.navigator)(b,E):Eu()&&Bh()(b,{body:E,method:"POST",credentials:"omit",keepalive:!0}).then(null,(w=>{(typeof __SENTRY_DEBUG__=="undefined"||__SENTRY_DEBUG__)&&Fe.error(w);}));})(m,xp(y));}catch(b){(typeof __SENTRY_DEBUG__=="undefined"||__SENTRY_DEBUG__)&&Fe.error(b);}}else (typeof __SENTRY_DEBUG__=="undefined"||__SENTRY_DEBUG__)&&Fe.log("No dsn provided, will not send outcomes");else (typeof __SENTRY_DEBUG__=="undefined"||__SENTRY_DEBUG__)&&Fe.log("No outcomes to send");}}var ub=n(4147),zh=[new $r.InboundFilters,new $r.FunctionToString,new $r.TryCatch,new $r.Breadcrumbs,new $r.LinkedErrors,new $r.Dedupe,new $r.HttpContext],Ou=new na,Tp=function(){return Tp=Object.assign||function(f){for(var a,l=1,d=arguments.length;l<d;l++)for(var m in a=arguments[l])Object.prototype.hasOwnProperty.call(a,m)&&(f[m]=a[m]);return f},Tp.apply(this,arguments)};function wp(f){return f?Object.keys(f).map((function(a){return Tp({isFallback:true,accessDeniedReason:h.fEx.Unknown,feature:{id:a}},f[a])})):[]}var Ha=function(){return Ha=Object.assign||function(f){for(var a,l=1,d=arguments.length;l<d;l++)for(var m in a=arguments[l])Object.prototype.hasOwnProperty.call(a,m)&&(f[m]=a[m]);return f},Ha.apply(this,arguments)};function vn(f,a){return l=this,d=void 0,y=function(){return (function(b,E){var w,D,_,M,B={label:0,sent:function(){if(1&_[0])throw _[1];return _[1]},trys:[],ops:[]};return M={next:H(0),throw:H(1),return:H(2)},typeof Symbol=="function"&&(M[Symbol.iterator]=function(){return this}),M;function H(K){return function(J){return (function(tt){if(w)throw new TypeError("Generator is already executing.");for(;B;)try{if(w=1,D&&(_=2&tt[0]?D.return:tt[0]?D.throw||((_=D.return)&&_.call(D),0):D.next)&&!(_=_.call(D,tt[1])).done)return _;switch(D=0,_&&(tt=[2&tt[0],_.value]),tt[0]){case 0:case 1:_=tt;break;case 4:return B.label++,{value:tt[1],done:!1};case 5:B.label++,D=tt[1],tt=[0];continue;case 7:tt=B.ops.pop(),B.trys.pop();continue;default:if(!((_=(_=B.trys).length>0&&_[_.length-1])||tt[0]!==6&&tt[0]!==2)){B=0;continue}if(tt[0]===3&&(!_||tt[1]>_[0]&&tt[1]<_[3])){B.label=tt[1];break}if(tt[0]===6&&B.label<_[1]){B.label=_[1],_=tt;break}if(_&&B.label<_[2]){B.label=_[2],B.ops.push(tt);break}_[2]&&B.ops.pop(),B.trys.pop();continue}tt=E.call(b,B);}catch(yt){tt=[6,yt],D=0;}finally{w=_=0;}if(5&tt[0])throw tt[1];return {value:tt[0]?tt[1]:void 0,done:true}})([K,J])}}})(this,(function(b){switch(b.label){case 0:return b.trys.push([0,2,,3]),[4,f()];case 1:return [2,b.sent()];case 2:return [2,Hh(b.sent(),a)];case 3:return [2]}}))},new((m=void 0)||(m=Promise))((function(b,E){function w(M){try{_(y.next(M));}catch(B){E(B);}}function D(M){try{_(y.throw(M));}catch(B){E(B);}}function _(M){var B;M.done?b(M.value):(B=M.value,B instanceof m?B:new m((function(H){H(B);}))).then(w,D);}_((y=y.apply(l,d||[])).next());}));var l,d,m,y;}function Oo(f,a){try{return f()}catch(l){return Hh(l,a)}}function Hh(f,a){var l=a.loggerService,d=a.sdkConfiguration,m=a.errorMessage,y=a.rethrowError,b=a.errorReportMetadata,E=m?m(f):"Operation failed. Error: ".concat(f.message);if(l.error(E,f),(function(w,D){var _=D.sdkConfiguration,M=D.errorMessage,B=D.errorReportMetadata;Ou.withScope((function(H){var K={errorMessage:M};if(_){var J=_.customerId,tt=Ha(Ha({},_),{apiKey:void 0});J&&H.setTags({customerId:J}),K.sdkConfiguration=tt;}B&&(K=Ha(Ha({},K),B)),H.setExtras(K),Ou.captureException(w);}));})(f,{sdkConfiguration:d,errorMessage:E,errorReportMetadata:b}),y)throw new Error(E)}var Hn=function(){return Hn=Object.assign||function(f){for(var a,l=1,d=arguments.length;l<d;l++)for(var m in a=arguments[l])Object.prototype.hasOwnProperty.call(a,m)&&(f[m]=a[m]);return f},Hn.apply(this,arguments)},de=function(f,a,l,d){return new(l||(l=Promise))((function(m,y){function b(D){try{w(d.next(D));}catch(_){y(_);}}function E(D){try{w(d.throw(D));}catch(_){y(_);}}function w(D){var _;D.done?m(D.value):(_=D.value,_ instanceof l?_:new l((function(M){M(_);}))).then(b,E);}w((d=d.apply(f,[])).next());}))},pe=function(f,a){var l,d,m,y,b={label:0,sent:function(){if(1&m[0])throw m[1];return m[1]},trys:[],ops:[]};return y={next:E(0),throw:E(1),return:E(2)},typeof Symbol=="function"&&(y[Symbol.iterator]=function(){return this}),y;function E(w){return function(D){return (function(_){if(l)throw new TypeError("Generator is already executing.");for(;b;)try{if(l=1,d&&(m=2&_[0]?d.return:_[0]?d.throw||((m=d.return)&&m.call(d),0):d.next)&&!(m=m.call(d,_[1])).done)return m;switch(d=0,m&&(_=[2&_[0],m.value]),_[0]){case 0:case 1:m=_;break;case 4:return b.label++,{value:_[1],done:!1};case 5:b.label++,d=_[1],_=[0];continue;case 7:_=b.ops.pop(),b.trys.pop();continue;default:if(!((m=(m=b.trys).length>0&&m[m.length-1])||_[0]!==6&&_[0]!==2)){b=0;continue}if(_[0]===3&&(!m||_[1]>m[0]&&_[1]<m[3])){b.label=_[1];break}if(_[0]===6&&b.label<m[1]){b.label=m[1],m=_;break}if(m&&b.label<m[2]){b.label=m[2],b.ops.push(_);break}m[2]&&b.ops.pop(),b.trys.pop();continue}_=a.call(f,b);}catch(M){_=[6,M],d=0;}finally{l=m=0;}if(5&_[0])throw _[1];return {value:_[0]?_[1]:void 0,done:true}})([w,D])}}},Wh=(function(){function f(a,l){this.modelMapper=new hh,this.eventEmitter=new yh,this.showWatermark=false,this.isWidgetWatermarkEnabled=false,this.configuration=a,this.edgeApiClient=cr.create(a,a),this.graphClient=(function(d){var m=d.apiKey,y=d.baseUri,b=d.clientName,E=b===void 0?dn:b,w=d.clientVersion,D=w===void 0?Jr.version:w,_=(function(H,K){return new Tt((function(J,tt){var yt={"X-API-KEY":H,"x-graphql-operation-name":J.operationName,source:Ke},Rt=K.customerToken;return Rt&&(yt["X-CUSTOMER-KEY"]=Rt),J.setContext({headers:yt}),tt(J)}))})(m,d),M=(function(H){return new Wc({uri:"".concat(H,"/graphql"),fetch:pn})})(y),B=new uh({attempts:{max:5,retryIf:Zo},delay:{initial:500,max:2e3,jitter:true}});return new Xo({link:_.concat(B.concat(M)),cache:new cu({possibleTypes:Zd.g}),name:E,version:D})})(this.configuration),this.loggerService=l,this.apiGateway=new sn(this.graphClient,this.edgeApiClient),this.globalEntitlementsService=null,this.resourceEntitlementsService=null,this.initializationStateTracker=new bh(this.eventEmitter);}return f.initialize=function(a){var l=(function(b){var E={baseUri:"https://api.stigg.io",baseEdgeUri:_e("https://api.stigg.io"),logConfiguration:{logger:console,logLevel:o.ERROR},enableEdge:true,cacheTtlMs:3e4},w=b.baseEdgeUri?b.baseEdgeUri:b.baseUri?_e(b.baseUri):E.baseEdgeUri,D=b.cacheTtlMs||b.entitlementPollingInterval;return ln()(E,b,{baseEdgeUri:w,cacheTtlMs:D})})(a),d=new p(l.logConfiguration.logger,l.logConfiguration.logLevel);if(l.offline){d.log("Stigg SDK has been initialized in offline mode, only fallback entitlements are being used.");var m=new Ru(l,d);return m.initializationStateTracker.signalSuccessInit(),m}(function(b,E){if(Pn()(b.apiKey)&&!b.offline){var w="You must configure the client with an SDK key";throw E.error(w),new Error(w)}})(l,d);var y=new f(l,d);return this.initializeSdk(y).then((function(){l.customerId?l.lazyLoad||y.setCustomerId(l.customerId,l.customerToken,l.resourceId):y.initializationStateTracker.signalSuccessInit();})).catch((function(b){return y.initializationStateTracker.signalFailedInit(b)})),y},f.prototype.waitForInitialization=function(){return de(this,void 0,void 0,(function(){var a=this;return pe(this,(function(l){return [2,this.initializationStateTracker.getInitializationPromise().then((function(){return a}))]}))}))},f.initializeSdk=function(a){var l,d,m,y;return de(this,void 0,void 0,(function(){var b,E,w,D;return pe(this,(function(_){switch(_.label){case 0:return _.trys.push([0,2,,3]),[4,a.apiGateway.sdkConfiguration.getSdkConfiguration()];case 1:return b=_.sent(),E=(l=b.data)===null||l===void 0?void 0:l.sdkConfiguration,!Ou.getClient()&&(E!=null&&E.sentryDsn)&&(J=E.sentryDsn,M=void 0,B=void 0,K=function(){var tt,yt;return (function(Rt,Zt){var zt,Bt,qt,$e,fe={label:0,sent:function(){if(1&qt[0])throw qt[1];return qt[1]},trys:[],ops:[]};return $e={next:Oe(0),throw:Oe(1),return:Oe(2)},typeof Symbol=="function"&&($e[Symbol.iterator]=function(){return this}),$e;function Oe(An){return function(Mr){return (function(u){if(zt)throw new TypeError("Generator is already executing.");for(;fe;)try{if(zt=1,Bt&&(qt=2&u[0]?Bt.return:u[0]?Bt.throw||((qt=Bt.return)&&qt.call(Bt),0):Bt.next)&&!(qt=qt.call(Bt,u[1])).done)return qt;switch(Bt=0,qt&&(u=[2&u[0],qt.value]),u[0]){case 0:case 1:qt=u;break;case 4:return fe.label++,{value:u[1],done:!1};case 5:fe.label++,Bt=u[1],u=[0];continue;case 7:u=fe.ops.pop(),fe.trys.pop();continue;default:if(!((qt=(qt=fe.trys).length>0&&qt[qt.length-1])||u[0]!==6&&u[0]!==2)){fe=0;continue}if(u[0]===3&&(!qt||u[1]>qt[0]&&u[1]<qt[3])){fe.label=u[1];break}if(u[0]===6&&fe.label<qt[1]){fe.label=qt[1],qt=u;break}if(qt&&fe.label<qt[2]){fe.label=qt[2],fe.ops.push(u);break}qt[2]&&fe.ops.pop(),fe.trys.pop();continue}u=Zt.call(Rt,fe);}catch(g){u=[6,g],Bt=0;}finally{zt=qt=0;}if(5&u[0])throw u[1];return {value:u[0]?u[1]:void 0,done:true}})([An,Mr])}}})(this,(function(Rt){return tt={dsn:J,normalizeDepth:6,release:"".concat(dn,"@").concat(ub.version),integrations:zh,stackParser:Cp,transport:Eu()?Uh:ku},yt=new Wr(tt),Ou.bindClient(yt),[2]}))},new((H=void 0)||(H=Promise))((function(tt,yt){function Rt(Bt){try{zt(K.next(Bt));}catch(qt){yt(qt);}}function Zt(Bt){try{zt(K.throw(Bt));}catch(qt){yt(qt);}}function zt(Bt){var qt;Bt.done?tt(Bt.value):(qt=Bt.value,qt instanceof H?qt:new H((function($e){$e(qt);}))).then(Rt,Zt);}zt((K=K.apply(M,B||[])).next());}))),a.showWatermark=!!(E!=null&&E.showWatermark),[3,3];case 2:throw w=_.sent(),((d=w.response)===null||d===void 0?void 0:d.status)===401||w.graphQLErrors&&((y=(m=w.graphQLErrors[0])===null||m===void 0?void 0:m.extensions)===null||y===void 0?void 0:y.code)===h.jKp.Unauthenticated?(D="Authentication failed. Double check your SDK key.",a.loggerService.error(D),new Error(D)):(a.loggerService.error("Failed to load sdk configuration",w),w);case 3:return [2]}var M,B,H,K,J;}))}))},Object.defineProperty(f.prototype,"isCustomerLoaded",{get:function(){var a;return ((a=this.globalEntitlementsService)===null||a===void 0?void 0:a.isInitialized)||false},enumerable:false,configurable:true}),Object.defineProperty(f.prototype,"isResourceLoaded",{get:function(){var a;return ((a=this.resourceEntitlementsService)===null||a===void 0?void 0:a.isInitialized)||false},enumerable:false,configurable:true}),f.prototype.getShowWatermark=function(){return this.showWatermark},f.prototype.addListener=function(a,l){this.eventEmitter.on(a,l);},f.prototype.removeListener=function(a,l){this.eventEmitter.off(a,l);},f.prototype.setCustomerId=function(a,l,d){return l===void 0&&(l=null),d===void 0&&(d=null),de(this,void 0,void 0,(function(){var m,y,b,E,w,D=this;return pe(this,(function(_){switch(_.label){case 0:if(m=this.configuration,y=m.customerToken,b=m.customerId,E=m.resourceId,a===b&&l===y&&d===E)return [2];if(this.clearCustomer(),!a)return this.loggerService.log("`setCustomerId` was called without a customerId, did you mean to call `clearCustomer`?"),[2];if(!(0, F.isString)(a))throw new Error("customerId parameter must be a string");if(l&&!(0, F.isString)(l))throw new Error("customerToken parameter must be a string");if(d&&!(0, F.isString)(d))throw new Error("resourceId parameter must be a string");this.configuration.customerId=a,this.configuration.customerToken=l,this.configuration.resourceId=d,this.globalEntitlementsService=new fi(a,void 0,new fu(this.configuration.cacheTtlMs),this.graphClient,this.edgeApiClient,this.loggerService,(function(M){return D.eventEmitter.emit("entitlementsUpdated",M)})),d&&(this.resourceEntitlementsService=new fi(a,d,new fu(this.configuration.cacheTtlMs),this.graphClient,this.edgeApiClient,this.loggerService,(function(M){return D.eventEmitter.emit("entitlementsUpdated",M)}))),_.label=1;case 1:return _.trys.push([1,3,,4]),[4,vn((function(){return de(D,void 0,void 0,(function(){var M,B;return pe(this,(function(H){switch(H.label){case 0:return [4,Promise.all([(M=this.globalEntitlementsService)===null||M===void 0?void 0:M.loadEntitlements(),(B=this.resourceEntitlementsService)===null||B===void 0?void 0:B.loadEntitlements()])];case 1:return H.sent(),[2]}}))}))}),{loggerService:this.loggerService,sdkConfiguration:this.configuration,errorMessage:function(M){return "Failed to load initial entitlements for customer. Error: ".concat(M.message)},rethrowError:true})];case 2:return _.sent(),this.initializationStateTracker.signalSuccessInit(),[3,4];case 3:return w=_.sent(),this.initializationStateTracker.signalFailedInit(w),[3,4];case 4:return [2]}}))}))},f.prototype.clearCustomer=function(){this.globalEntitlementsService=null,this.resourceEntitlementsService=null,this.configuration.customerId=null,this.configuration.customerToken=null,this.configuration.resourceId=null;},f.prototype.setResource=function(a){return de(this,void 0,void 0,(function(){var l,d,m=this;return pe(this,(function(y){switch(y.label){case 0:if(!this.configuration.customerId)throw new Error("`setResource` must be called when customer was set, did you forget to call `setCustomerId`?");if(l=this.configuration.resourceId,a===l)return [2];if(this.clearResource(),!(0, F.isString)(a))throw new Error("resourceId parameter must be a string");this.configuration.resourceId=a,this.resourceEntitlementsService=new fi(this.configuration.customerId,a,new fu(this.configuration.cacheTtlMs),this.graphClient,this.edgeApiClient,this.loggerService,(function(b){return m.eventEmitter.emit("entitlementsUpdated",b)})),y.label=1;case 1:return y.trys.push([1,3,,4]),[4,vn((function(){return de(m,void 0,void 0,(function(){var b;return pe(this,(function(E){return (b=this.resourceEntitlementsService)===null||b===void 0||b.loadEntitlements(),[2]}))}))}),{loggerService:this.loggerService,sdkConfiguration:this.configuration,errorMessage:function(b){return "Failed to load initial entitlements for customer resource. Error: ".concat(b.message)},rethrowError:true})];case 2:return y.sent(),this.initializationStateTracker.signalSuccessInit(),[3,4];case 3:return d=y.sent(),this.initializationStateTracker.signalFailedInit(d),[3,4];case 4:return [2]}}))}))},f.prototype.clearResource=function(){if(!this.configuration.customerId)throw new Error("`clearResource` must be called when customer was set, did you forget to call `setCustomerId`?");this.resourceEntitlementsService=null,this.configuration.resourceId=null;},f.prototype.refresh=function(){return de(this,void 0,void 0,(function(){var a=this;return pe(this,(function(l){return [2,vn((function(){return de(a,void 0,void 0,(function(){var d,m;return pe(this,(function(y){switch(y.label){case 0:return [4,Promise.all([(d=this.globalEntitlementsService)===null||d===void 0?void 0:d.refresh(),(m=this.resourceEntitlementsService)===null||m===void 0?void 0:m.refresh()])];case 1:return y.sent(),[2]}}))}))}),{loggerService:this.loggerService,sdkConfiguration:this.configuration,errorMessage:function(d){return "Failed to refresh entitlements. Error: ".concat(d.message)},rethrowError:true})]}))}))},f.prototype.getBooleanEntitlement=function(a){var l,d=this,m=a.featureId,y=a.options,b=a.resourceId,E=(y==null?void 0:y.fallback)||((l=this.configuration.entitlementsFallback)===null||l===void 0?void 0:l[m])||{},w=Hn(Hn({},v),E);return Oo((function(){return d.globalEntitlementsService&&d.isCustomerLoaded?b?b!==d.configuration.resourceId?(d.loggerService.log("Resource ID ".concat(b," does not match the current resource ID ").concat(d.configuration.resourceId,".")),d.loggerService.log("Using fallback entitlements for customer: ".concat(d.configuration.customerId," with resourceId ").concat(b,"}")),w):d.isResourceLoaded&&d.resourceEntitlementsService?d.resourceEntitlementsService.getBooleanEntitlement(m,w,y):w:d.globalEntitlementsService.getBooleanEntitlement(m,w,y):(d.loggerService.log("Using fallback entitlements for customer: ".concat(d.configuration.customerId,". Reason: ").concat(d.globalEntitlementsService?"Customer not loaded":"Entitlements service not initialized "),{initializationStatus:d.initializationStateTracker.initializationStatus,customerId:d.configuration.customerId||""}),w)}),{loggerService:this.loggerService,sdkConfiguration:this.configuration,errorMessage:function(D){return "Failed to get boolean entitlement. Error: ".concat(D.message)},rethrowError:false,errorReportMetadata:{featureId:m,options:y}})||(this.loggerService.log("Using fallback entitlements for customer: ".concat(this.configuration.customerId,". Reason: Failed to get entitlement")),w)},f.prototype.getNumericEntitlement=function(a){var l,d=this,m=a.featureId,y=a.options,b=a.resourceId,E=(y==null?void 0:y.fallback)||((l=this.configuration.entitlementsFallback)===null||l===void 0?void 0:l[m])||{},w=Hn(Hn({},P),E);return Oo((function(){return d.globalEntitlementsService&&d.isCustomerLoaded?b?b!==d.configuration.resourceId?(d.loggerService.log("Resource ID ".concat(b," does not match the current resource ID ").concat(d.configuration.resourceId,".")),d.loggerService.log("Using fallback entitlements for customer: ".concat(d.configuration.customerId," with resourceId ").concat(b,"}")),w):d.isResourceLoaded&&d.resourceEntitlementsService?d.resourceEntitlementsService.getNumericEntitlement(m,w,y):w:d.globalEntitlementsService.getNumericEntitlement(m,w,y):(d.loggerService.log("Using fallback entitlements for customer: ".concat(d.configuration.customerId,". Reason: ").concat(d.globalEntitlementsService?"Customer not loaded":"Entitlements service not initialized "),{initializationStatus:d.initializationStateTracker.initializationStatus,customerId:d.configuration.customerId||""}),w)}),{loggerService:this.loggerService,sdkConfiguration:this.configuration,errorMessage:function(D){return "Failed to get numeric entitlement. Error: ".concat(D.message)},rethrowError:false,errorReportMetadata:{featureId:m,options:y}})||(this.loggerService.log("Using fallback entitlements for customer: ".concat(this.configuration.customerId,". Reason: Failed to get entitlement")),w)},f.prototype.getMeteredEntitlement=function(a){var l,d=this,m=a.featureId,y=a.options,b=a.resourceId,E=(y==null?void 0:y.fallback)||((l=this.configuration.entitlementsFallback)===null||l===void 0?void 0:l[m])||{},w=Hn(Hn({},x),E);return Oo((function(){return d.globalEntitlementsService&&d.isCustomerLoaded?b?b!==d.configuration.resourceId?(d.loggerService.log("Resource ID ".concat(b," does not match the current resource ID ").concat(d.configuration.resourceId,".")),d.loggerService.log("Using fallback entitlements for customer: ".concat(d.configuration.customerId," with resourceId ").concat(b,"}")),w):d.isResourceLoaded&&d.resourceEntitlementsService?d.resourceEntitlementsService.getMeteredEntitlement(m,w,y):w:d.globalEntitlementsService.getMeteredEntitlement(m,w,y):(d.loggerService.log("Using fallback entitlements for customer: ".concat(d.configuration.customerId,". Reason: ").concat(d.globalEntitlementsService?"Customer not loaded":"Entitlements service not initialized "),{initializationStatus:d.initializationStateTracker.initializationStatus,customerId:d.configuration.customerId||""}),w)}),{loggerService:this.loggerService,sdkConfiguration:this.configuration,errorMessage:function(D){return "Failed to get metered entitlement. Error: ".concat(D.message)},rethrowError:false,errorReportMetadata:{featureId:m,options:y}})||(this.loggerService.log("Using fallback entitlements for customer: ".concat(this.configuration.customerId,". Reason: Failed to get entitlement")),w)},f.prototype.getEnumEntitlement=function(a){var l,d=this,m=a.featureId,y=a.options,b=a.resourceId,E=(y==null?void 0:y.fallback)||((l=this.configuration.entitlementsFallback)===null||l===void 0?void 0:l[m])||{},w=Hn(Hn({},T),E);return Oo((function(){return d.globalEntitlementsService&&d.isCustomerLoaded?b?b!==d.configuration.resourceId?(d.loggerService.log("Resource ID ".concat(b," does not match the current resource ID ").concat(d.configuration.resourceId,".")),d.loggerService.log("Using fallback entitlements for customer: ".concat(d.configuration.customerId," with resourceId ").concat(b,"}")),w):d.isResourceLoaded&&d.resourceEntitlementsService?d.resourceEntitlementsService.getEnumEntitlement(m,w,y):w:d.globalEntitlementsService.getEnumEntitlement(m,w,y):(d.loggerService.log("Using fallback entitlements for customer: ".concat(d.configuration.customerId,". Reason: ").concat(d.globalEntitlementsService?"Customer not loaded":"Entitlements service not initialized "),{initializationStatus:d.initializationStateTracker.initializationStatus,customerId:d.configuration.customerId||""}),w)}),{loggerService:this.loggerService,sdkConfiguration:this.configuration,errorMessage:function(D){return "Failed to get enum entitlement. Error: ".concat(D.message)},rethrowError:false,errorReportMetadata:{featureId:m,options:y}})||(this.loggerService.log("Using fallback entitlements for customer: ".concat(this.configuration.customerId,". Reason: Failed to get entitlement")),w)},f.prototype.getPaywall=function(a){var l=a===void 0?{}:a,d=l.productId,m=l.resourceId,y=l.context,b=l.billingCountryCode,E=l.includeHiddenPlans;return de(this,void 0,void 0,(function(){var w,D=this;return pe(this,(function(_){return w={productId:d,customerId:this.configuration.customerId,resourceId:m,context:y,billingCountryCode:b,includeHiddenPlans:E},[2,vn((function(){return de(D,void 0,void 0,(function(){var M;return pe(this,(function(B){switch(B.label){case 0:return d!=null&&d.startsWith("stiggTestData")?[4,this.apiGateway.mockPaywall.getMockPaywall(w)]:[3,2];case 1:return M=B.sent(),[2,this.modelMapper.mapMockPlans(M.data)];case 2:return [4,this.apiGateway.paywall.getPaywall(w)];case 3:return M=B.sent(),[2,this.modelMapper.mapPaywall(M.data)]}}))}))}),{loggerService:this.loggerService,sdkConfiguration:this.configuration,errorMessage:function(M){return "Failed to get paywall. Error: ".concat(M.message)},rethrowError:true,errorReportMetadata:{productId:d}})]}))}))},f.prototype.getCoupons=function(){return de(this,void 0,void 0,(function(){var a=this;return pe(this,(function(l){return [2,vn((function(){return de(a,void 0,void 0,(function(){var d;return pe(this,(function(m){switch(m.label){case 0:return [4,this.apiGateway.coupons.getCoupons()];case 1:return d=m.sent(),[2,this.modelMapper.mapCoupons(d.data)]}}))}))}),{loggerService:this.loggerService,sdkConfiguration:this.configuration,errorMessage:function(d){return "Failed to get coupons. Error: ".concat(d.message)},rethrowError:true})]}))}))},f.prototype.getCustomer=function(){return de(this,void 0,void 0,(function(){var a=this;return pe(this,(function(l){return [2,vn((function(){return de(a,void 0,void 0,(function(){var d,m,y,b;return pe(this,(function(E){switch(E.label){case 0:return d=De(this.configuration),[4,this.apiGateway.customers.getCustomer(d)];case 1:if(m=E.sent(),!(y=m.data.getCustomerByRefId))throw new Error("Customer not found");return b=y.subscriptions||[],[2,this.modelMapper.mapCustomer(y,b)]}}))}))}),{loggerService:this.loggerService,sdkConfiguration:this.configuration,errorMessage:function(d){return "Failed to get customer. Error: ".concat(d.message)},rethrowError:true})]}))}))},f.prototype.getCustomerPortal=function(a){var l=a===void 0?{}:a,d=l.resourceId,m=l.productId;return de(this,void 0,void 0,(function(){var y=this;return pe(this,(function(b){return [2,vn((function(){return de(y,void 0,void 0,(function(){var E,w;return pe(this,(function(D){switch(D.label){case 0:return E=De(this.configuration),[4,this.apiGateway.customers.getCustomerPortal(E,d,m)];case 1:return w=D.sent(),[2,this.modelMapper.mapCustomerPortal(w.data.customerPortal)]}}))}))}),{loggerService:this.loggerService,sdkConfiguration:this.configuration,errorMessage:function(E){return "Failed to get customer portal details. Error: ".concat(E.message)},rethrowError:true})]}))}))},f.prototype.getCheckoutState=function(a){var l=a.planId,d=a.resourceId,m=d===void 0?this.configuration.resourceId:d,y=a.billingCountryCode;return de(this,void 0,void 0,(function(){var b=this;return pe(this,(function(E){return [2,vn((function(){return de(b,void 0,void 0,(function(){var w,D;return pe(this,(function(_){switch(_.label){case 0:return w=De(this.configuration),[4,this.apiGateway.subscriptions.checkoutState({customerId:w,resourceId:m,planId:l,billingCountryCode:y})];case 1:return D=_.sent(),[2,this.modelMapper.mapCheckoutState(D.data.checkoutState)]}}))}))}),{loggerService:this.loggerService,sdkConfiguration:this.configuration,errorMessage:function(w){return "Failed to get checkout details. Error: ".concat(w.message)},rethrowError:true})]}))}))},f.prototype.applySubscription=function(a){return de(this,void 0,void 0,(function(){var l=this;return pe(this,(function(d){return [2,vn((function(){return de(l,void 0,void 0,(function(){var m,y;return pe(this,(function(b){switch(b.label){case 0:return m=De(this.configuration),[4,this.apiGateway.subscriptions.applySubscription(Hn({customerId:m},a))];case 1:if(!(y=b.sent().data)||!y.applySubscription)throw new Error("Invalid response");return [2,this.modelMapper.mapApplySubscriptionResults(y)]}}))}))}),{loggerService:this.loggerService,sdkConfiguration:this.configuration,errorMessage:function(m){return "Failed to apply subscription to customer. Error: ".concat(m.message)},rethrowError:true})]}))}))},f.prototype.fetchUsageHistory=function(a){return de(this,void 0,void 0,(function(){var l=this;return pe(this,(function(d){return [2,vn((function(){return de(l,void 0,void 0,(function(){var m;return pe(this,(function(y){switch(y.label){case 0:return [4,this.apiGateway.customers.fetchUsageHistory(a)];case 1:if(!(m=y.sent().data)||!m.usageHistory)throw new Error("Invalid response");return [2,this.modelMapper.mapUsageHistory(m.usageHistory)]}}))}))}),{loggerService:this.loggerService,sdkConfiguration:this.configuration,errorMessage:function(m){return "Failed to fetch usage history. Error: ".concat(m.message)},rethrowError:false})]}))}))},f.prototype.getEntitlements=function(a){return de(this,void 0,void 0,(function(){var l,d,m=this;return pe(this,(function(y){switch(y.label){case 0:return l=wp(this.configuration.entitlementsFallback),[4,vn((function(){return de(m,void 0,void 0,(function(){var b;return pe(this,(function(E){return De(this.configuration),a?a!==this.configuration.resourceId?(this.loggerService.log("Resource ID ".concat(a," does not match the current resource ID ").concat(this.configuration.resourceId,".")),this.loggerService.log("Using fallback entitlements for customer: ".concat(this.configuration.customerId," with resourceId ").concat(a,"}")),[2,l]):this.isResourceLoaded&&this.resourceEntitlementsService?(this.loggerService.log("Using fallback entitlements for customer: ".concat(this.configuration.customerId)),[2,this.resourceEntitlementsService.getEntitlements()]):[2,l]:[2,(b=this.globalEntitlementsService)===null||b===void 0?void 0:b.getEntitlements()]}))}))}),{loggerService:this.loggerService,sdkConfiguration:this.configuration,errorMessage:function(b){return "Failed to get entitlements. Error: ".concat(b.message)},rethrowError:true})];case 1:return (d=y.sent())?[2,d]:(this.loggerService.log("Using fallback entitlements for customer: ".concat(this.configuration.customerId,". Reason: Failed to get entitlements.")),[2,l])}}))}))},f.prototype.estimateSubscription=function(a){return de(this,void 0,void 0,(function(){var l=this;return pe(this,(function(d){return [2,vn((function(){return de(l,void 0,void 0,(function(){var m;return pe(this,(function(y){switch(y.label){case 0:return [4,this.apiGateway.subscriptionEstimations.estimateSubscription(a)];case 1:if(!(m=y.sent().data))throw new Error("Invalid response");return [2,this.modelMapper.mapSubscriptionPreview(m.estimateSubscription)]}}))}))}),{loggerService:this.loggerService,sdkConfiguration:this.configuration,errorMessage:function(m){return "Failed to estimate subscription. Error: ".concat(m.message)},rethrowError:true})]}))}))},f.prototype.estimateSubscriptionUpdate=function(a){return de(this,void 0,void 0,(function(){var l=this;return pe(this,(function(d){return [2,vn((function(){return de(l,void 0,void 0,(function(){var m;return pe(this,(function(y){switch(y.label){case 0:return [4,this.apiGateway.subscriptionEstimations.estimateSubscriptionUpdate(a)];case 1:if(!(m=y.sent().data))throw new Error("Invalid response");return [2,this.modelMapper.mapSubscriptionPreview(m.estimateSubscriptionUpdate)]}}))}))}),{loggerService:this.loggerService,sdkConfiguration:this.configuration,errorMessage:function(m){return "Failed to estimate subscription update. Error: ".concat(m.message)},rethrowError:true})]}))}))},f.prototype.previewNextInvoice=function(a){return de(this,void 0,void 0,(function(){var l=this;return pe(this,(function(d){return [2,vn((function(){return de(l,void 0,void 0,(function(){var m;return pe(this,(function(y){switch(y.label){case 0:return [4,this.apiGateway.subscriptionEstimations.previewNextInvoice(a)];case 1:if(!(m=y.sent().data))throw new Error("Invalid response");return [2,m.previewNextInvoice]}}))}))}),{loggerService:this.loggerService,sdkConfiguration:this.configuration,errorMessage:function(m){return "Failed to preview subscription next invoice. Error: ".concat(m.message)},rethrowError:true})]}))}))},f.prototype.previewSubscription=function(a){return de(this,void 0,void 0,(function(){var l=this;return pe(this,(function(d){return [2,vn((function(){return de(l,void 0,void 0,(function(){var m;return pe(this,(function(y){switch(y.label){case 0:return [4,this.apiGateway.subscriptionEstimations.previewSubscription(a)];case 1:if(!(m=y.sent().data))throw new Error("Invalid response");return [2,this.modelMapper.mapSubscriptionPreviewV2(m.previewSubscription)]}}))}))}),{loggerService:this.loggerService,sdkConfiguration:this.configuration,errorMessage:function(m){return "Failed to estimate checkout. Error: ".concat(m.message)},rethrowError:true})]}))}))},f.prototype.getUsageHistoryV2=function(a){return de(this,void 0,void 0,(function(){var l=this;return pe(this,(function(d){return [2,vn((function(){return de(l,void 0,void 0,(function(){return pe(this,(function(m){switch(m.label){case 0:return [4,this.apiGateway.usageHistoryApi.getUsageHistoryV2(a)];case 1:return [2,m.sent().data.usageHistoryV2]}}))}))}),{loggerService:this.loggerService,sdkConfiguration:this.configuration,errorMessage:function(m){return "Failed to get usage history. Error: ".concat(m.message)},rethrowError:true})]}))}))},f.prototype.waitForCheckoutCompleted=function(a){var l=a===void 0?{}:a,d=l.timeoutMs,m=d===void 0?15e3:d,y=l.refreshOnComplete,b=y===void 0||y;return de(this,void 0,void 0,(function(){var E,w,D,_,M,B,H,K;return pe(this,(function(J){switch(J.label){case 0:if(typeof window=="undefined")throw new Error("`waitForCheckoutCompleted` was called, but `window` is not defined");if(E=new URLSearchParams(window.location.search),w=E.get("subscriptionId"),D=E.get("resourceId")||void 0,_=E.get("checkoutCompleted"),!w)return this.loggerService.log("`waitCheckoutCompleted` was called, but no `subscriptionId` found in query params"),[2,null];if(!_||_.toLowerCase()==="false")return this.loggerService.log("The checkout session was cancelled by the user"),[2,null];M=Date.now(),B=false,H=null,J.label=1;case 1:return B?[4,new Promise((function(tt){return setTimeout(tt,1e3)}))]:[3,3];case 2:J.sent(),J.label=3;case 3:return [4,this.getActiveSubscriptions({resourceId:D})];case 4:K=J.sent(),H=K.find((function(tt){return tt.id===w}))||null,B=true,J.label=5;case 5:if(!H&&Date.now()-M<m)return [3,1];J.label=6;case 6:if(!H)throw new Error("Timeout while waiting for checkout to complete, subscription ".concat(w," is not active"));return b?[4,this.refresh()]:[3,8];case 7:J.sent(),J.label=8;case 8:return [2,H]}}))}))},f.prototype.getSubscriptions=function(a){return a===void 0&&(a={}),de(this,void 0,void 0,(function(){var l,d,m,y,b,E=this;return pe(this,(function(w){return l=a.customerId,d=a.resourceId,m=a.status,y=a.productId,b=a.pagination,[2,vn((function(){return de(E,void 0,void 0,(function(){var D;return pe(this,(function(_){switch(_.label){case 0:return [4,this.apiGateway.subscriptions.getSubscriptions(l,d,m,y,b)];case 1:return [2,{data:(D=_.sent()).data.subscriptions.edges.map((function(M){return M.node})),pageInfo:D.data.subscriptions.pageInfo}]}}))}))}),{loggerService:this.loggerService,sdkConfiguration:this.configuration,errorMessage:function(D){return "Failed to get active subscriptions. Error: ".concat(D.message)},rethrowError:true})]}))}))},f.prototype.getActiveSubscriptions=function(a){var l=this,d=(a===void 0?{}:a).resourceId;return vn((function(){return de(l,void 0,void 0,(function(){var m,y,b;return pe(this,(function(E){switch(E.label){case 0:return m=De(this.configuration),[4,this.apiGateway.customers.getActiveSubscriptions(m,d)];case 1:if(y=E.sent(),!(b=y.data.getActiveSubscriptions))throw new Error("Customer ".concat(d?"or resource ":"","not found"));return [2,this.modelMapper.mapSubscriptions(b)]}}))}))}),{loggerService:this.loggerService,sdkConfiguration:this.configuration,errorMessage:function(m){return "Failed to get active subscriptions. Error: ".concat(m.message)},rethrowError:true})},f.prototype.getActiveSubscriptionsList=function(a){var l=(a===void 0?{}:a).resourceId;return de(this,void 0,void 0,(function(){var d=this;return pe(this,(function(m){return [2,vn((function(){return de(d,void 0,void 0,(function(){var y;return pe(this,(function(b){switch(b.label){case 0:return y=De(this.configuration),[4,this.apiGateway.customers.getActiveSubscriptionsList(y,l)];case 1:return [2,b.sent().data.getActiveSubscriptions]}}))}))}),{loggerService:this.loggerService,sdkConfiguration:this.configuration,errorMessage:function(y){return "Failed to get active subscriptions list. Error: ".concat(y.message)},rethrowError:true})]}))}))},f.prototype.getSubscription=function(a){var l=a.subscriptionId;return de(this,void 0,void 0,(function(){var d=this;return pe(this,(function(m){return [2,vn((function(){return de(d,void 0,void 0,(function(){var y,b;return pe(this,(function(E){switch(E.label){case 0:return [4,this.apiGateway.customers.getSubscription(l)];case 1:return y=E.sent(),b=y.data.getSubscription,[2,this.modelMapper.mapSubscription(b)]}}))}))}),{loggerService:this.loggerService,sdkConfiguration:this.configuration,errorMessage:function(y){return "Failed to get subscription. Error: ".concat(y.message)},rethrowError:true})]}))}))},f.prototype.getCreditUsage=function(a){return de(this,void 0,void 0,(function(){var l=this;return pe(this,(function(d){return [2,vn((function(){return de(l,void 0,void 0,(function(){var m,y,b;return pe(this,(function(E){switch(E.label){case 0:return m=De(this.configuration),y=(b=this.configuration.resourceId)!==null&&b!==void 0?b:void 0,[4,this.apiGateway.credits.getCreditUsage(Hn(Hn({},a),{customerId:m,resourceId:y}))];case 1:return [2,E.sent().data.creditUsage]}}))}))}),{loggerService:this.loggerService,sdkConfiguration:this.configuration,errorMessage:function(m){return "Failed to get credit usage. Error: ".concat(m.message)},rethrowError:true})]}))}))},f.prototype.getCreditBalance=function(a){return a===void 0&&(a={}),de(this,void 0,void 0,(function(){var l=this;return pe(this,(function(d){return [2,vn((function(){return de(l,void 0,void 0,(function(){var m,y,b;return pe(this,(function(E){switch(E.label){case 0:return m=De(this.configuration),y=(b=this.configuration.resourceId)!==null&&b!==void 0?b:void 0,[4,this.apiGateway.credits.getCreditBalance(Hn(Hn({},a),{customerId:m,resourceId:y}))];case 1:return [2,E.sent().data.creditBalanceSummary]}}))}))}),{loggerService:this.loggerService,sdkConfiguration:this.configuration,errorMessage:function(m){return m.message},rethrowError:true})]}))}))},f.prototype.getCreditGrants=function(a){return de(this,void 0,void 0,(function(){var l=this;return pe(this,(function(d){return [2,vn((function(){return de(l,void 0,void 0,(function(){var m,y,b,E;return pe(this,(function(w){switch(w.label){case 0:return m=De(this.configuration),y=(E=this.configuration.resourceId)!==null&&E!==void 0?E:void 0,[4,this.apiGateway.credits.getCreditGrants(Hn(Hn({},a),{customerId:m,resourceId:y}))];case 1:return [2,{data:(b=w.sent()).data.creditGrants.edges.map((function(D){return D.node})),pageInfo:b.data.creditGrants.pageInfo,totalCount:b.data.creditGrants.totalCount}]}}))}))}),{loggerService:this.loggerService,sdkConfiguration:this.configuration,errorMessage:function(m){return m.message},rethrowError:true})]}))}))},f.prototype.getCreditLedger=function(a){return a===void 0&&(a={}),de(this,void 0,void 0,(function(){var l=this;return pe(this,(function(d){return [2,vn((function(){return de(l,void 0,void 0,(function(){var m,y,b;return pe(this,(function(E){switch(E.label){case 0:return m=De(this.configuration),y=(b=this.configuration.resourceId)!==null&&b!==void 0?b:void 0,[4,this.apiGateway.credits.getCreditLedger(Hn(Hn({},a),{customerId:m,resourceId:y}))];case 1:return [2,E.sent().data.creditsLedger.events]}}))}))}),{loggerService:this.loggerService,sdkConfiguration:this.configuration,errorMessage:function(m){return m.message},rethrowError:true})]}))}))},f.prototype.createPaymentSession=function(a){return de(this,void 0,void 0,(function(){var l=this;return pe(this,(function(d){return [2,vn((function(){return de(l,void 0,void 0,(function(){var m,y;return pe(this,(function(b){switch(b.label){case 0:return m=De(this.configuration),[4,this.apiGateway.checkout.createPaymentSession(Hn(Hn({},a),{customerId:m}))];case 1:if(!(y=b.sent()).data||!y.data.createPaymentSession)throw new Error("Invalid response");return [2,y.data.createPaymentSession]}}))}))}),{loggerService:this.loggerService,sdkConfiguration:this.configuration,errorMessage:function(m){return "Failed to create payment session. Error: ".concat(m.message)},rethrowError:true})]}))}))},f})(),db=(function(){var f=function(a,l){return f=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(d,m){d.__proto__=m;}||function(d,m){for(var y in m)Object.prototype.hasOwnProperty.call(m,y)&&(d[y]=m[y]);},f(a,l)};return function(a,l){if(typeof l!="function"&&l!==null)throw new TypeError("Class extends value "+String(l)+" is not a constructor or null");function d(){this.constructor=a;}f(a,l),a.prototype=l===null?Object.create(l):(d.prototype=l.prototype,new d);}})(),oo=function(){return oo=Object.assign||function(f){for(var a,l=1,d=arguments.length;l<d;l++)for(var m in a=arguments[l])Object.prototype.hasOwnProperty.call(a,m)&&(f[m]=a[m]);return f},oo.apply(this,arguments)},gn=function(f,a,l,d){return new(l||(l=Promise))((function(m,y){function b(D){try{w(d.next(D));}catch(_){y(_);}}function E(D){try{w(d.throw(D));}catch(_){y(_);}}function w(D){var _;D.done?m(D.value):(_=D.value,_ instanceof l?_:new l((function(M){M(_);}))).then(b,E);}w((d=d.apply(f,[])).next());}))},yn=function(f,a){var l,d,m,y,b={label:0,sent:function(){if(1&m[0])throw m[1];return m[1]},trys:[],ops:[]};return y={next:E(0),throw:E(1),return:E(2)},typeof Symbol=="function"&&(y[Symbol.iterator]=function(){return this}),y;function E(w){return function(D){return (function(_){if(l)throw new TypeError("Generator is already executing.");for(;b;)try{if(l=1,d&&(m=2&_[0]?d.return:_[0]?d.throw||((m=d.return)&&m.call(d),0):d.next)&&!(m=m.call(d,_[1])).done)return m;switch(d=0,m&&(_=[2&_[0],m.value]),_[0]){case 0:case 1:m=_;break;case 4:return b.label++,{value:_[1],done:!1};case 5:b.label++,d=_[1],_=[0];continue;case 7:_=b.ops.pop(),b.trys.pop();continue;default:if(!((m=(m=b.trys).length>0&&m[m.length-1])||_[0]!==6&&_[0]!==2)){b=0;continue}if(_[0]===3&&(!m||_[1]>m[0]&&_[1]<m[3])){b.label=_[1];break}if(_[0]===6&&b.label<m[1]){b.label=m[1],m=_;break}if(m&&b.label<m[2]){b.label=m[2],b.ops.push(_);break}m[2]&&b.ops.pop(),b.trys.pop();continue}_=a.call(f,b);}catch(M){_=[6,M],d=0;}finally{l=m=0;}if(5&_[0])throw _[1];return {value:_[0]?_[1]:void 0,done:true}})([w,D])}}},Ru=(function(f){function a(){return f!==null&&f.apply(this,arguments)||this}return db(a,f),a.prototype.getBooleanEntitlement=function(l){var d,m=l.featureId,y=l.options,b=(y==null?void 0:y.fallback)||((d=this.configuration.entitlementsFallback)===null||d===void 0?void 0:d[m])||{};return oo(oo({},v),b)},a.prototype.getMeteredEntitlement=function(l){var d,m=l.featureId,y=l.options,b=(y==null?void 0:y.fallback)||((d=this.configuration.entitlementsFallback)===null||d===void 0?void 0:d[m])||{};return oo(oo({},x),b)},a.prototype.getNumericEntitlement=function(l){var d,m=l.featureId,y=l.options,b=(y==null?void 0:y.fallback)||((d=this.configuration.entitlementsFallback)===null||d===void 0?void 0:d[m])||{};return oo(oo({},P),b)},a.prototype.getEnumEntitlement=function(l){var d,m=l.featureId,y=l.options,b=(y==null?void 0:y.fallback)||((d=this.configuration.entitlementsFallback)===null||d===void 0?void 0:d[m])||{};return oo(oo({},T),b)},a.prototype.getEntitlements=function(){return gn(this,void 0,void 0,(function(){return yn(this,(function(l){return [2,wp(this.configuration.entitlementsFallback)]}))}))},a.prototype.addListener=function(){},a.prototype.clearCustomer=function(){},a.prototype.clearResource=function(){},a.prototype.getActiveSubscriptionsList=function(){return gn(this,void 0,void 0,(function(){return yn(this,(function(l){return [2,[]]}))}))},a.prototype.getCoupons=function(){return gn(this,void 0,void 0,(function(){return yn(this,(function(l){return [2,[]]}))}))},a.prototype.getSubscription=function(){return gn(this,void 0,void 0,(function(){return yn(this,(function(l){return [2,{id:"mock-subscription-id",addons:[],futureUpdates:[],paymentCollection:h.QdX.NotRequired,plan:{compatibleAddons:[],compatiblePackageGroups:[],displayName:"mock-plan",entitlements:[],id:"mock-plan-id",inheritedEntitlements:[],order:0,pricePoints:[],product:{id:"mock-product-id"}},price:null,prices:[],pricingType:h._HY.Paid,startDate:new Date,status:h.yhH.Active,totalPrice:{total:{amount:0,currency:h.Fa6.Usd},subTotal:{amount:0,currency:h.Fa6.Usd}}}]}))}))},Object.defineProperty(a.prototype,"isCustomerLoaded",{get:function(){return false},enumerable:false,configurable:true}),Object.defineProperty(a.prototype,"isResourceLoaded",{get:function(){return false},enumerable:false,configurable:true}),a.prototype.removeListener=function(){},a.prototype.waitForInitialization=function(){return gn(this,void 0,void 0,(function(){return yn(this,(function(l){return [2,this]}))}))},a.prototype.setResource=function(){return gn(this,void 0,void 0,(function(){return yn(this,(function(l){return [2]}))}))},a.prototype.getCheckoutState=function(){return gn(this,void 0,void 0,(function(){return yn(this,(function(l){return [2,{setupSecret:"mock-setup-secret",resource:null,plan:{compatibleAddons:[],compatiblePackageGroups:[],displayName:"mock-plan",entitlements:[],id:"mock-plan-id",inheritedEntitlements:[],order:0,pricePoints:[],product:{id:"mock-product-id"}},customer:{createdAt:new Date,updatedAt:new Date,hasPaymentMethod:false,id:"mock-customer-id",subscriptions:[],promotionalEntitlements:[],getActivePromotionalEntitlements:function(){return []},getActiveSubscriptions:function(){return []},getActiveTrials:function(){return []}},billingIntegration:{billingIdentifier:h.ugv.Stripe,billingCredentials:{setupSecret:"mock-setup-secret",accountId:"mock-account-id",publicKey:"mock-public-key"},credentials:{accountId:"mock-account-id",publicKey:"mock-public-key"}}}]}))}))},a.prototype.applySubscription=function(){return gn(this,void 0,void 0,(function(){return yn(this,(function(l){return [2,{subscription:void 0}]}))}))},a.prototype.estimateSubscription=function(){return gn(this,void 0,void 0,(function(){return yn(this,(function(l){return [2,{billingPeriodRange:{},total:{amount:0,currency:h.Fa6.Usd},subTotal:{amount:0,currency:h.Fa6.Usd},totalExcludingTax:{amount:0,currency:h.Fa6.Usd}}]}))}))},a.prototype.previewNextInvoice=function(){return gn(this,void 0,void 0,(function(){return yn(this,(function(l){return [2,{lastUpdatedAt:new Date,amountDue:{amount:0,currency:h.Fa6.Usd},minimumSpendAdjustment:{amount:0,currency:h.Fa6.Usd},total:{amount:0,currency:h.Fa6.Usd},subTotalExcludingTax:{amount:0,currency:h.Fa6.Usd},subTotal:{amount:0,currency:h.Fa6.Usd},totalExcludingTax:{amount:0,currency:h.Fa6.Usd},tax:{amount:0,currency:h.Fa6.Usd},lines:[]}]}))}))},a.prototype.previewSubscription=function(){return gn(this,void 0,void 0,(function(){return yn(this,(function(l){return [2,{billingPeriodRange:{},immediateInvoice:{total:{amount:0,currency:h.Fa6.Usd},subTotal:{amount:0,currency:h.Fa6.Usd},totalExcludingTax:{amount:0,currency:h.Fa6.Usd}}}]}))}))},a.prototype.estimateSubscriptionUpdate=function(){return gn(this,void 0,void 0,(function(){return yn(this,(function(l){return [2,{billingPeriodRange:{},total:{amount:0,currency:h.Fa6.Usd},subTotal:{amount:0,currency:h.Fa6.Usd},totalExcludingTax:{amount:0,currency:h.Fa6.Usd}}]}))}))},a.prototype.waitForCheckoutCompleted=function(){return gn(this,void 0,void 0,(function(){return yn(this,(function(l){return [2,null]}))}))},a.prototype.refresh=function(){return gn(this,void 0,void 0,(function(){return yn(this,(function(l){return [2]}))}))},a.prototype.fetchUsageHistory=function(){return gn(this,void 0,void 0,(function(){return yn(this,(function(l){return [2,[]]}))}))},a.prototype.getUsageHistoryV2=function(){return gn(this,void 0,void 0,(function(){return yn(this,(function(l){return [2,{markers:[],series:[]}]}))}))},a.prototype.setCustomerId=function(){return gn(this,void 0,void 0,(function(){return yn(this,(function(l){return [2]}))}))},a.prototype.getPaywall=function(){return gn(this,void 0,void 0,(function(){return yn(this,(function(l){return [2,{activeSubscriptions:[],currency:{code:h.Fa6.Usd,symbol:"$"},plans:[],customer:null,resource:null}]}))}))},a.prototype.getCustomerPortal=function(){return gn(this,void 0,void 0,(function(){return yn(this,(function(l){return [2,{subscriptions:[],entitlements:[],promotionalEntitlements:[],billingInformation:{},canUpgradeSubscription:false,resource:null,showWatermark:true}]}))}))},a.prototype.getActiveSubscriptions=function(){return gn(this,void 0,void 0,(function(){return yn(this,(function(l){return [2,[]]}))}))},a.prototype.getSubscriptions=function(){return gn(this,void 0,void 0,(function(){return yn(this,(function(l){return [2,{data:[],pageInfo:{}}]}))}))},a.prototype.getCustomer=function(){return gn(this,void 0,void 0,(function(){return yn(this,(function(l){return [2,{id:"offline-customer-id",createdAt:new Date,updatedAt:new Date,subscriptions:[],promotionalEntitlements:[],metadata:{},hasPaymentMethod:false,email:"offline-customer@example.com",getActivePromotionalEntitlements:function(){return []},getActiveSubscriptions:function(){return []},getActiveTrials:function(){return []}}]}))}))},a.prototype.getCreditBalance=function(){return gn(this,void 0,void 0,(function(){return yn(this,(function(l){return [2,{__typename:"CreditBalanceSummary",customerId:"offline-customer-id",balances:[]}]}))}))},a.prototype.getCreditGrants=function(){return gn(this,void 0,void 0,(function(){return yn(this,(function(l){return [2,{data:[],pageInfo:{},totalCount:0}]}))}))},a.prototype.getCreditLedger=function(){return gn(this,void 0,void 0,(function(){return yn(this,(function(l){return [2,[]]}))}))},a.prototype.getCreditUsage=function(){return gn(this,void 0,void 0,(function(){return yn(this,(function(l){return [2,{series:[]}]}))}))},a.prototype.createPaymentSession=function(){return gn(this,void 0,void 0,(function(){return yn(this,(function(l){return [2,{__typename:"PaymentSession",token:"mock-token"}]}))}))},a.prototype.getShowWatermark=function(){return false},a})(Wh);},890:(t,e,n)=>{Object.defineProperty(e,"X$v",{value:true}),e.iKc=e.GAT=e.sEr=e.i4m=e.bWm=e.o_I=e.i3Z=e.m72=e.g3t=e.Zr9=e.jKp=e.Qj0=e.$BG=e.IZr=e.Pr8=e.FT8=e.JrM=e.XHu=e.AVk=e.Lbh=e.C2e=e.yEZ=e.Pg9=e.rpU=e.pDu=e.Fa6=e.uMJ=e.Eq9=e.bSK=e.$i2=e.K79=e.fc5=e.i2A=e.uS8=e.u4I=e.ugv=e.tvV=e.FzK=e.yTz=e.PLi=e.bM9=e.E34=e.Mbo=e.v2N=e.Ijf=e.nwm=e.dpb=e.zu7=e.zVd=e.fEx=void 0,e.yBL=e.DWP=e.eSW=e.G6j=e.tV1=e.e1Q=e._oj=e.ird=e.abb=e.lS0=e.c06=e.w1y=e.ueJ=e.PO0=e.Xm9=e.SrV=e.nM6=e.Zam=e.u0j=e.QZw=e.$Vq=e.ku9=e.JkE=e.p_C=e._HY=e.YGW=e.qXR=e.Cc7=e.LtK=e.Kf7=e.QdX=e.TVs=e.OeJ=e.jCI=e.iI3=e.zv6=e.q5V=e.PVi=e.gpE=e.pSI=e.puT=e.XY6=e.Kyg=e.isD=e.Us3=e.B8X=e.qBr=e.uMn=e.U9t=e.Tex=void 0,e.zjf=e.fYe=e.GBW=e.Ugm=e.HsO=e.hvo=e.J5K=e.zWW=e.bOA=e.kd9=e.d4U=e.T0E=e.BoX=e.RzF=e.cMT=e.N9N=e.wEB=e.Chb=e.OoB=e.FL0=e.hk_=e.Ehw=e.zdd=e.bj8=e.cTO=e._q5=e.JU=e.zOd=e.EOH=e.l9N=e.rCU=e.O0T=e.FoD=e._yy=e.Buv=e.X3h=e.Dfv=e.p13=e.bk4=e.PNd=e.UAI=e.hYU=e.wRo=e.XqI=e.yhH=e.nOi=e.YVG=e.cUf=e.o88=e.SQC=void 0,e.r6R=e.oiL=e.Pzm=e.mKD=e.lj3=e.UK7=e.CjA=e.Y92=e.YlF=e.bGH=e.yaX=e.QNm=e.qw4=e.fvX=e.r4r=e.nN6=e.FcI=e.lgL=e.wn5=e.hVT=e.$Bh=e.VeJ=e.k8_=e.weZ=e.LkV=e.Yo2=e.bEP=e.g31=e.NSU=e.mGS=e.XsQ=e._d$=e.u9g=e.Eph=e.LBz=e.X$1=e.aqW=e.qYx=e.Q_D=e.ab2=e.cG4=e.l3m=e.bII=e.cUI=e.o5f=e.JyR=e.Dxn=e.URA=e.Eam=e.DFP=void 0,e.$Av=e.N9K=e.Fd7=e.pWb=e.RXg=e.roX=e.RVX=e.Q$1=e.do1=e.hH=e.bgy=e.OpC=e.TpL=e.ZeH=e.yyj=e.$QI=e.bd6=e._He=e.KeG=e.E7k=e.Dc_=e.vQb=e.$02=e._gQ=e.m06=e.bGN=e.WJn=e.JDz=e.ZSL=e.dO5=e.K5h=e.jAf=e.yGq=e.ZD9=e.wO5=e.m5b=e.x3v=e.EQD=e.N5j=e.Bkk=e.rDA=e.GHz=e.Mal=e.Wky=e.eKV=e.$jJ=e.m76=e.q6C=e._Yx=e.xrg=void 0,e.mKo=e.AQp=e.zBW=e.LpH=e.Bve=e.zHr=e.tIq=e.$Iz=e.Cmg=e.p7R=e.K0T=e._xu=e.jPD=void 0;let r=n(5185);var i,o,s,c,p,h,v,P,x,T,I,F,A,O,N,V,G,X,nt,st,U,j,ut,Y,at,pt,dt,mt,Ct,jt,Gt,Jt,ee,re,Ee,je,sn,Ze,Pn,Gn,ln,Ke,dn,or,_e,De,vr,Ve,bt,ar,sr,Jn,lr,wi,vo,jr,Co,Ce,Vt,gt,ot,Z,it,_t,ft,Lt,It,Nt,se,ne,kn,Ae,cn,pn,Ir,cr,en,ur,$t,Vr,xn,jn,ct,si,fn,dr,kr,Ii,Wi,ki,hs,Sa,ms,Di,hn,pr,Je,vt,gs,So,Pa,qi,ae,Ue,Yr,li,Yi,xl,El,on,xa,tr,Ea,ci,Kn,Ai,er,ys,_a,zo,Cr;(Cr=e.fEx||(e.fEx={})).BudgetExceeded="BudgetExceeded",Cr.CustomerIsArchived="CustomerIsArchived",Cr.CustomerNotFound="CustomerNotFound",Cr.CustomerResourceNotFound="CustomerResourceNotFound",Cr.FeatureNotFound="FeatureNotFound",Cr.FeatureTypeMismatch="FeatureTypeMismatch",Cr.InsufficientCredits="InsufficientCredits",Cr.NoActiveSubscription="NoActiveSubscription",Cr.NoFeatureEntitlementInSubscription="NoFeatureEntitlementInSubscription",Cr.RequestedUsageExceedingLimit="RequestedUsageExceedingLimit",Cr.RequestedValuesMismatch="RequestedValuesMismatch",Cr.Revoked="Revoked",Cr.Unknown="Unknown",(zo=e.zVd||(e.zVd={})).AuthorizedDomain="AUTHORIZED_DOMAIN",zo.InviteOnly="INVITE_ONLY",zo.Sso="SSO",(_a=e.zu7||(e.zu7={})).Member="MEMBER",_a.Owner="OWNER",(ys=e.dpb||(e.dpb={})).Active="ACTIVE",ys.Blocked="BLOCKED",(er=e.nwm||(e.nwm={})).BillingId="billingId",er.CreatedAt="createdAt",er.Description="description",er.DisplayName="displayName",er.EnvironmentId="environmentId",er.Id="id",er.IsLatest="isLatest",er.PricingType="pricingType",er.ProductId="productId",er.RefId="refId",er.Status="status",er.UpdatedAt="updatedAt",er.VersionNumber="versionNumber",(Ai=e.Ijf||(e.Ijf={})).Avg="AVG",Ai.Count="COUNT",Ai.Max="MAX",Ai.Min="MIN",Ai.Sum="SUM",Ai.Unique="UNIQUE",(Kn=e.v2N||(e.v2N={})).Center="CENTER",Kn.Left="LEFT",Kn.Right="RIGHT",(e.Mbo||(e.Mbo={})).Id="id",(ci=e.E34||(e.E34={})).Client="CLIENT",ci.Salesforce="SALESFORCE",ci.Server="SERVER",ci.Workflow="WORKFLOW",(Ea=e.bM9||(e.bM9={})).Both="BOTH",Ea.Individual="INDIVIDUAL",Ea.Organization="ORGANIZATION",(tr=e.PLi||(e.PLi={})).StartOfTheMonth="START_OF_THE_MONTH",tr.SubscriptionsConsolidateBilling="SUBSCRIPTIONS_CONSOLIDATE_BILLING",tr.SubscriptionStart="SUBSCRIPTION_START",(xa=e.yTz||(e.yTz={})).OneOff="ONE_OFF",xa.Recurring="RECURRING",(on=e.FzK||(e.FzK={})).CreditBased="CREDIT_BASED",on.FlatFee="FLAT_FEE",on.MinimumSpend="MINIMUM_SPEND",on.PerUnit="PER_UNIT",on.UsageBased="USAGE_BASED",(El=e.tvV||(e.tvV={})).Annually="ANNUALLY",El.Monthly="MONTHLY",(xl=e.ugv||(e.ugv={})).Stripe="STRIPE",xl.Zuora="ZUORA",(Yi=e.u4I||(e.u4I={})).Added="ADDED",Yi.Deleted="DELETED",Yi.Modified="MODIFIED",Yi.Reordered="REORDERED",(li=e.uS8||(e.uS8={})).Equals="EQUALS",li.GreaterThan="GREATER_THAN",li.GreaterThanOrEqual="GREATER_THAN_OR_EQUAL",li.IsNotNull="IS_NOT_NULL",li.IsNull="IS_NULL",li.LessThan="LESS_THAN",li.LessThanOrEqual="LESS_THAN_OR_EQUAL",li.NotEquals="NOT_EQUALS",(Yr=e.i2A||(e.i2A={})).BillingId="billingId",Yr.CreatedAt="createdAt",Yr.Description="description",Yr.EnvironmentId="environmentId",Yr.Id="id",Yr.Name="name",Yr.RefId="refId",Yr.Source="source",Yr.Status="status",Yr.Type="type",Yr.UpdatedAt="updatedAt",(Ue=e.fc5||(e.fc5={})).Stigg="STIGG",Ue.StiggAdhoc="STIGG_ADHOC",Ue.Stripe="STRIPE",(ae=e.K79||(e.K79={})).Active="ACTIVE",ae.Archived="ARCHIVED",(qi=e.$i2||(e.$i2={})).Fixed="FIXED",qi.Percentage="PERCENTAGE",(Pa=e.bSK||(e.bSK={})).Paid="PAID",Pa.Promotional="PROMOTIONAL",(So=e.Eq9||(e.Eq9={})).CreditsConsumed="CREDITS_CONSUMED",So.CreditsExpired="CREDITS_EXPIRED",So.CreditsGranted="CREDITS_GRANTED",So.CreditsVoided="CREDITS_VOIDED",(gs=e.uMJ||(e.uMJ={})).LastDay="LAST_DAY",gs.LastMonth="LAST_MONTH",gs.LastWeek="LAST_WEEK",gs.LastYear="LAST_YEAR",(vt=e.Fa6||(e.Fa6={})).Aed="AED",vt.All="ALL",vt.Amd="AMD",vt.Ang="ANG",vt.Aud="AUD",vt.Awg="AWG",vt.Azn="AZN",vt.Bam="BAM",vt.Bbd="BBD",vt.Bdt="BDT",vt.Bgn="BGN",vt.Bif="BIF",vt.Bmd="BMD",vt.Bnd="BND",vt.Brl="BRL",vt.Bsd="BSD",vt.Bwp="BWP",vt.Byn="BYN",vt.Bzd="BZD",vt.Cad="CAD",vt.Cdf="CDF",vt.Chf="CHF",vt.Clp="CLP",vt.Cny="CNY",vt.Czk="CZK",vt.Djf="DJF",vt.Dkk="DKK",vt.Dop="DOP",vt.Dzd="DZD",vt.Egp="EGP",vt.Etb="ETB",vt.Eur="EUR",vt.Fjd="FJD",vt.Gbp="GBP",vt.Gel="GEL",vt.Gip="GIP",vt.Gmd="GMD",vt.Gnf="GNF",vt.Gyd="GYD",vt.Hkd="HKD",vt.Hrk="HRK",vt.Htg="HTG",vt.Idr="IDR",vt.Ils="ILS",vt.Inr="INR",vt.Isk="ISK",vt.Jmd="JMD",vt.Jpy="JPY",vt.Kes="KES",vt.Kgs="KGS",vt.Khr="KHR",vt.Kmf="KMF",vt.Krw="KRW",vt.Kyd="KYD",vt.Kzt="KZT",vt.Lbp="LBP",vt.Lkr="LKR",vt.Lrd="LRD",vt.Lsl="LSL",vt.Mad="MAD",vt.Mdl="MDL",vt.Mga="MGA",vt.Mkd="MKD",vt.Mmk="MMK",vt.Mnt="MNT",vt.Mop="MOP",vt.Mro="MRO",vt.Mvr="MVR",vt.Mwk="MWK",vt.Mxn="MXN",vt.Myr="MYR",vt.Mzn="MZN",vt.Nad="NAD",vt.Ngn="NGN",vt.Nok="NOK",vt.Npr="NPR",vt.Nzd="NZD",vt.Pgk="PGK",vt.Php="PHP",vt.Pkr="PKR",vt.Pln="PLN",vt.Pyg="PYG",vt.Qar="QAR",vt.Ron="RON",vt.Rsd="RSD",vt.Rub="RUB",vt.Rwf="RWF",vt.Sar="SAR",vt.Sbd="SBD",vt.Scr="SCR",vt.Sek="SEK",vt.Sgd="SGD",vt.Sle="SLE",vt.Sll="SLL",vt.Sos="SOS",vt.Szl="SZL",vt.Thb="THB",vt.Tjs="TJS",vt.Top="TOP",vt.Try="TRY",vt.Ttd="TTD",vt.Tzs="TZS",vt.Uah="UAH",vt.Ugx="UGX",vt.Usd="USD",vt.Uzs="UZS",vt.Vnd="VND",vt.Vuv="VUV",vt.Wst="WST",vt.Xaf="XAF",vt.Xcd="XCD",vt.Xof="XOF",vt.Xpf="XPF",vt.Yer="YER",vt.Zar="ZAR",vt.Zmw="ZMW",(Je=e.pDu||(e.pDu={})).CreatedAt="createdAt",Je.EnvironmentId="environmentId",Je.ResourceId="resourceId",(pr=e.rpU||(e.rpU={})).AwsMarketplaceCustomerId="awsMarketplaceCustomerId",pr.BillingId="billingId",pr.CreatedAt="createdAt",pr.CrmHubspotCompanyId="crmHubspotCompanyId",pr.CrmHubspotCompanyUrl="crmHubspotCompanyUrl",pr.CrmId="crmId",pr.CustomerId="customerId",pr.DeletedAt="deletedAt",pr.Email="email",pr.EnvironmentId="environmentId",pr.Id="id",pr.Name="name",pr.RefId="refId",pr.SalesforceId="salesforceId",pr.SearchQuery="searchQuery",pr.UpdatedAt="updatedAt",(hn=e.Pg9||(e.Pg9={})).BillingCycleAnchor="billingCycleAnchor",hn.BillingId="billingId",hn.CancelReason="cancelReason",hn.CancellationDate="cancellationDate",hn.CreatedAt="createdAt",hn.CrmId="crmId",hn.CrmLinkUrl="crmLinkUrl",hn.CurrentBillingPeriodEnd="currentBillingPeriodEnd",hn.CurrentBillingPeriodStart="currentBillingPeriodStart",hn.CustomerId="customerId",hn.EffectiveEndDate="effectiveEndDate",hn.EndDate="endDate",hn.EnvironmentId="environmentId",hn.Id="id",hn.OldBillingId="oldBillingId",hn.PayingCustomerId="payingCustomerId",hn.PaymentCollection="paymentCollection",hn.PricingType="pricingType",hn.RefId="refId",hn.ResourceId="resourceId",hn.SalesforceId="salesforceId",hn.StartDate="startDate",hn.Status="status",hn.SubscriptionId="subscriptionId",hn.TrialEndDate="trialEndDate",(Di=e.yEZ||(e.yEZ={})).CeoOrFounder="CEO_OR_FOUNDER",Di.Engineering="ENGINEERING",Di.Growth="GROWTH",Di.Marketing="MARKETING",Di.Monetization="MONETIZATION",Di.Other="OTHER",Di.Product="PRODUCT",(ms=e.C2e||(e.C2e={})).Forever="FOREVER",ms.Once="ONCE",ms.Repeating="REPEATING",(Sa=e.Lbh||(e.Lbh={})).Fixed="FIXED",Sa.Percentage="PERCENTAGE",(hs=e.AVk||(e.AVk={})).Increment="Increment",hs.Override="Override",(ki=e.XHu||(e.XHu={})).Day="DAY",ki.Hour="HOUR",ki.Month="MONTH",ki.Week="WEEK",ki.Year="YEAR",(Wi=e.JrM||(e.JrM={})).CustomerNotFound="CustomerNotFound",Wi.NoActiveSubscription="NoActiveSubscription",(Ii=e.FT8||(e.FT8={})).BlackList="BLACK_LIST",Ii.WhiteList="WHITE_LIST",(kr=e.Pr8||(e.Pr8={})).Admin="ADMIN",kr.None="NONE",kr.Support="SUPPORT",kr.Viewer="VIEWER",(dr=e.IZr||(e.IZr={})).Done="DONE",dr.Failed="FAILED",dr.InProgress="IN_PROGRESS",dr.NotProvisioned="NOT_PROVISIONED",(fn=e.$BG||(e.$BG={})).CreatedAt="createdAt",fn.DisplayName="displayName",fn.Id="id",fn.PermanentDeletionDate="permanentDeletionDate",fn.Slug="slug",(si=e.Qj0||(e.Qj0={})).Development="DEVELOPMENT",si.Production="PRODUCTION",si.Sandbox="SANDBOX",(ct=e.jKp||(e.jKp={})).AccessDeniedError="AccessDeniedError",ct.AccountNotFoundError="AccountNotFoundError",ct.AddonDependencyMissingError="AddonDependencyMissingError",ct.AddonHasToHavePriceError="AddonHasToHavePriceError",ct.AddonIsCompatibleWithGroup="AddonIsCompatibleWithGroup",ct.AddonIsCompatibleWithPlan="AddonIsCompatibleWithPlan",ct.AddonNotFound="AddonNotFound",ct.AddonQuantityExceedsLimitError="AddonQuantityExceedsLimitError",ct.AddonWithDraftCannotBeDeletedError="AddonWithDraftCannotBeDeletedError",ct.AddonsNotFound="AddonsNotFound",ct.AmountTooLarge="AmountTooLarge",ct.ArchivedCouponCantBeApplied="ArchivedCouponCantBeApplied",ct.AuthCustomerMismatch="AuthCustomerMismatch",ct.AuthCustomerReadonly="AuthCustomerReadonly",ct.AwsMarketplaceIntegrationError="AwsMarketplaceIntegrationError",ct.AwsMarketplaceIntegrationValidationError="AwsMarketplaceIntegrationValidationError",ct.BadUserInput="BadUserInput",ct.BillingIntegrationAlreadyExistsError="BillingIntegrationAlreadyExistsError",ct.BillingIntegrationMissing="BillingIntegrationMissing",ct.BillingPeriodMissingError="BillingPeriodMissingError",ct.CanNotUpdateEntitlementsFeatureGroup="CanNotUpdateEntitlementsFeatureGroup",ct.CannotAddOverrideEntitlementToPlan="CannotAddOverrideEntitlementToPlan",ct.CannotArchiveFeatureError="CannotArchiveFeatureError",ct.CannotArchiveFeatureGroupError="CannotArchiveFeatureGroupError",ct.CannotChangeBillingIntegration="CannotChangeBillingIntegration",ct.CannotDeleteCustomerError="CannotDeleteCustomerError",ct.CannotDeleteDefaultIntegration="CannotDeleteDefaultIntegration",ct.CannotDeleteFeatureError="CannotDeleteFeatureError",ct.CannotDeleteProductError="CannotDeleteProductError",ct.CannotEditPackageInNonDraftMode="CannotEditPackageInNonDraftMode",ct.CannotRemovePaymentMethodFromCustomerError="CannotRemovePaymentMethodFromCustomerError",ct.CannotReportUsageForEntitlementWithMeterError="CannotReportUsageForEntitlementWithMeterError",ct.CannotUpdateExpireAtForExpiredCreditGrantError="CannotUpdateExpireAtForExpiredCreditGrantError",ct.CannotUpdateUnitTransformationError="CannotUpdateUnitTransformationError",ct.CannotUpsertToPackageThatHasDraft="CannotUpsertToPackageThatHasDraft",ct.ChangingPayingCustomerIsNotSupportedError="ChangingPayingCustomerIsNotSupportedError",ct.CheckoutIsNotSupported="CheckoutIsNotSupported",ct.CouponNotFound="CouponNotFound",ct.CreditGrantAlreadyVoided="CreditGrantAlreadyVoided",ct.CreditGrantNotFound="CreditGrantNotFound",ct.CustomCurrencyNotFound="CustomCurrencyNotFound",ct.CustomerAlreadyHaveCustomerCoupon="CustomerAlreadyHaveCustomerCoupon",ct.CustomerAlreadyUsesCoupon="CustomerAlreadyUsesCoupon",ct.CustomerHasNoEmailAddress="CustomerHasNoEmailAddress",ct.CustomerNoBillingId="CustomerNoBillingId",ct.CustomerNotFound="CustomerNotFound",ct.CustomerResourceNotFound="CustomerResourceNotFound",ct.DeprecatedEstimateSubscriptionError="DeprecatedEstimateSubscriptionError",ct.DowngradeBillingPeriodNotSupportedError="DowngradeBillingPeriodNotSupportedError",ct.DraftAddonCantBeArchived="DraftAddonCantBeArchived",ct.DraftAlreadyExists="DraftAlreadyExists",ct.DraftPlanCantBeArchived="DraftPlanCantBeArchived",ct.DuplicateAddonProvisionedError="DuplicateAddonProvisionedError",ct.DuplicateIntegrationNotAllowed="DuplicateIntegrationNotAllowed",ct.DuplicateProductValidationError="DuplicateProductValidationError",ct.DuplicatedEntityNotAllowed="DuplicatedEntityNotAllowed",ct.EditAllowedOnDraftPackageOnlyError="EditAllowedOnDraftPackageOnlyError",ct.EntitlementBelongsToFeatureGroupError="EntitlementBelongsToFeatureGroupError",ct.EntitlementLimitExceededError="EntitlementLimitExceededError",ct.EntitlementUsageOutOfRangeError="EntitlementUsageOutOfRangeError",ct.EntitlementsMustBelongToSamePackage="EntitlementsMustBelongToSamePackage",ct.EntityIdDifferentFromRefIdError="EntityIdDifferentFromRefIdError",ct.EntityIsArchivedError="EntityIsArchivedError",ct.EnvironmentMissing="EnvironmentMissing",ct.ExperimentAlreadyRunning="ExperimentAlreadyRunning",ct.ExperimentNotFoundError="ExperimentNotFoundError",ct.ExperimentStatusError="ExperimentStatusError",ct.ExpireAtMustBeLaterThanEffectiveAtError="ExpireAtMustBeLaterThanEffectiveAtError",ct.FailedToCreateCheckoutSessionError="FailedToCreateCheckoutSessionError",ct.FailedToImportCustomer="FailedToImportCustomer",ct.FailedToImportSubscriptions="FailedToImportSubscriptions",ct.FailedToResolveBillingIntegration="FailedToResolveBillingIntegration",ct.FeatureConfigurationExceededLimitError="FeatureConfigurationExceededLimitError",ct.FeatureGroupMissingFeaturesError="FeatureGroupMissingFeaturesError",ct.FeatureGroupNotFoundError="FeatureGroupNotFoundError",ct.FeatureNotBelongToFeatureGroupError="FeatureNotBelongToFeatureGroupError",ct.FeatureNotFound="FeatureNotFound",ct.FetchAllCountriesPricesNotAllowed="FetchAllCountriesPricesNotAllowed",ct.FreePlanCantHaveCompatiblePackageGroupError="FreePlanCantHaveCompatiblePackageGroupError",ct.GraphQlAliasesLimitExceeded="GraphQLAliasesLimitExceeded",ct.GraphQlBatchedOperationsLimitExceeded="GraphQLBatchedOperationsLimitExceeded",ct.GraphQlUnsupportedDirective="GraphQLUnsupportedDirective",ct.HubspotIntegrationError="HubspotIntegrationError",ct.IdentityForbidden="IdentityForbidden",ct.ImportAlreadyInProgress="ImportAlreadyInProgress",ct.ImportSubscriptionsBulkError="ImportSubscriptionsBulkError",ct.IncompatibleSubscriptionAddon="IncompatibleSubscriptionAddon",ct.InitStripePaymentMethodError="InitStripePaymentMethodError",ct.IntegrationNotFound="IntegrationNotFound",ct.IntegrationValidationError="IntegrationValidationError",ct.IntegrityViolation="IntegrityViolation",ct.InvalidAddressError="InvalidAddressError",ct.InvalidArgumentError="InvalidArgumentError",ct.InvalidCancellationDate="InvalidCancellationDate",ct.InvalidDoggoSignatureError="InvalidDoggoSignatureError",ct.InvalidEntitlementResetPeriod="InvalidEntitlementResetPeriod",ct.InvalidMemberDelete="InvalidMemberDelete",ct.InvalidMetadataError="InvalidMetadataError",ct.InvalidQuantity="InvalidQuantity",ct.InvalidSubscriptionStatus="InvalidSubscriptionStatus",ct.InvalidUpdatePriceUnitAmountError="InvalidUpdatePriceUnitAmountError",ct.MemberInvitationError="MemberInvitationError",ct.MemberNotFound="MemberNotFound",ct.MergeEnvironmentValidationError="MergeEnvironmentValidationError",ct.MeterMustBeAssociatedToMeteredFeature="MeterMustBeAssociatedToMeteredFeature",ct.MeteringNotAvailableForFeatureType="MeteringNotAvailableForFeatureType",ct.MissingEntityIdError="MissingEntityIdError",ct.MissingSubscriptionInvoiceError="MissingSubscriptionInvoiceError",ct.MultiSubscriptionCantBeAutoCancellationSourceError="MultiSubscriptionCantBeAutoCancellationSourceError",ct.NoActiveSubscriptionForCustomer="NoActiveSubscriptionForCustomer",ct.NoDraftOfferFound="NoDraftOfferFound",ct.NoFeatureEntitlementError="NoFeatureEntitlementError",ct.NoFeatureEntitlementInSubscription="NoFeatureEntitlementInSubscription",ct.NoProductsAvailable="NoProductsAvailable",ct.OfferAlreadyExists="OfferAlreadyExists",ct.OfferNotFound="OfferNotFound",ct.OperationNotAllowedDuringInProgressExperiment="OperationNotAllowedDuringInProgressExperiment",ct.PackageAlreadyPublished="PackageAlreadyPublished",ct.PackageGroupMinItemsError="PackageGroupMinItemsError",ct.PackageGroupNotFound="PackageGroupNotFound",ct.PackagePricingTypeNotSet="PackagePricingTypeNotSet",ct.PaymentMethodNotFoundError="PaymentMethodNotFoundError",ct.PlanCannotBePublishWhenBasePlanIsDraft="PlanCannotBePublishWhenBasePlanIsDraft",ct.PlanCannotBePublishWhenCompatibleAddonIsDraft="PlanCannotBePublishWhenCompatibleAddonIsDraft",ct.PlanIsUsedAsDefaultStartPlan="PlanIsUsedAsDefaultStartPlan",ct.PlanIsUsedAsDowngradePlan="PlanIsUsedAsDowngradePlan",ct.PlanNotFound="PlanNotFound",ct.PlanWithChildCantBeDeleted="PlanWithChildCantBeDeleted",ct.PlansCircularDependencyError="PlansCircularDependencyError",ct.PreparePaymentMethodFormError="PreparePaymentMethodFormError",ct.PriceNotFound="PriceNotFound",ct.ProductNotFoundError="ProductNotFoundError",ct.PromotionCodeCustomerNotFirstPurchase="PromotionCodeCustomerNotFirstPurchase",ct.PromotionCodeMaxRedemptionsReached="PromotionCodeMaxRedemptionsReached",ct.PromotionCodeMinimumAmountNotReached="PromotionCodeMinimumAmountNotReached",ct.PromotionCodeNotActive="PromotionCodeNotActive",ct.PromotionCodeNotForCustomer="PromotionCodeNotForCustomer",ct.PromotionCodeNotFound="PromotionCodeNotFound",ct.PromotionalEntitlementNotFoundError="PromotionalEntitlementNotFoundError",ct.RateLimitExceeded="RateLimitExceeded",ct.RecalculateEntitlementsError="RecalculateEntitlementsError",ct.RequiredSsoAuthenticationError="RequiredSsoAuthenticationError",ct.ResyncAlreadyInProgress="ResyncAlreadyInProgress",ct.ScheduledMigrationAlreadyExistsError="ScheduledMigrationAlreadyExistsError",ct.SelectedBillingModelDoesntMatchImportedItemError="SelectedBillingModelDoesntMatchImportedItemError",ct.SingleSubscriptionCantBeAutoCancellationTargetError="SingleSubscriptionCantBeAutoCancellationTargetError",ct.StripeCustomerIsDeleted="StripeCustomerIsDeleted",ct.StripeError="StripeError",ct.SubscriptionAlreadyCanceledOrExpired="SubscriptionAlreadyCanceledOrExpired",ct.SubscriptionAlreadyOnLatestPlanError="SubscriptionAlreadyOnLatestPlanError",ct.SubscriptionDoesNotHaveBillingPeriod="SubscriptionDoesNotHaveBillingPeriod",ct.SubscriptionInvoiceStatusError="SubscriptionInvoiceStatusError",ct.SubscriptionMustHaveSinglePlanError="SubscriptionMustHaveSinglePlanError",ct.SubscriptionNoBillingId="SubscriptionNoBillingId",ct.SubscriptionNotFound="SubscriptionNotFound",ct.TooManyCustomCurrencies="TooManyCustomCurrencies",ct.TooManySubscriptionsPerCustomer="TooManySubscriptionsPerCustomer",ct.TrialMustBeCancelledImmediately="TrialMustBeCancelledImmediately",ct.UnPublishedPackage="UnPublishedPackage",ct.Unauthenticated="Unauthenticated",ct.UnexpectedError="UnexpectedError",ct.UnsupportedFeatureType="UnsupportedFeatureType",ct.UnsupportedParameter="UnsupportedParameter",ct.UnsupportedSubscriptionScheduleType="UnsupportedSubscriptionScheduleType",ct.UnsupportedVendorIdentifier="UnsupportedVendorIdentifier",ct.UsageMeasurementDiffOutOfRangeError="UsageMeasurementDiffOutOfRangeError",ct.VersionExceedsMaxValueError="VersionExceedsMaxValueError",ct.WorkflowTriggerNotFound="WorkflowTriggerNotFound",(jn=e.Zr9||(e.Zr9={})).AppCustomer="APP_CUSTOMER",jn.AppPublic="APP_PUBLIC",jn.AppServer="APP_SERVER",jn.Aws="AWS",jn.Import="IMPORT",jn.Migration="MIGRATION",jn.Salesforce="SALESFORCE",jn.Scheduler="SCHEDULER",jn.Service="SERVICE",jn.Stripe="STRIPE",jn.Support="SUPPORT",jn.System="SYSTEM",jn.User="USER",jn.Workflow="WORKFLOW",(xn=e.g3t||(e.g3t={})).Addon="ADDON",xn.Coupon="COUPON",xn.Credit="CREDIT",xn.Customer="CUSTOMER",xn.Entitlement="ENTITLEMENT",xn.Feature="FEATURE",xn.FeatureGroup="FEATURE_GROUP",xn.Import="IMPORT",xn.Measurement="MEASUREMENT",xn.Package="PACKAGE",xn.PackageGroup="PACKAGE_GROUP",xn.Plan="PLAN",xn.Product="PRODUCT",xn.PromotionalEntitlement="PROMOTIONAL_ENTITLEMENT",xn.Subscription="SUBSCRIPTION",(Vr=e.m72||(e.m72={})).CreatedAt="createdAt",Vr.EntityId="entityId",Vr.EnvironmentId="environmentId",Vr.EventLogType="eventLogType",Vr.Id="id",Vr.ParentEntityId="parentEntityId",($t=e.i3Z||(e.i3Z={})).AddonCreated="ADDON_CREATED",$t.AddonDeleted="ADDON_DELETED",$t.AddonUpdated="ADDON_UPDATED",$t.CouponArchived="COUPON_ARCHIVED",$t.CouponCreated="COUPON_CREATED",$t.CouponUpdated="COUPON_UPDATED",$t.CreateSubscriptionFailed="CREATE_SUBSCRIPTION_FAILED",$t.CreditsBalanceDepletedOld="CREDITS_BALANCE_DEPLETED_OLD",$t.CreditsBalanceLowOld="CREDITS_BALANCE_LOW_OLD",$t.CreditsGrantBalanceLowOld="CREDITS_GRANT_BALANCE_LOW_OLD",$t.CreditsGrantDepletedOld="CREDITS_GRANT_DEPLETED_OLD",$t.CreditsGrantExpiredOld="CREDITS_GRANT_EXPIRED_OLD",$t.CreditsGrantGrantedOld="CREDITS_GRANT_GRANTED_OLD",$t.CreditsGrantUpdatedOld="CREDITS_GRANT_UPDATED_OLD",$t.CreditBalanceDepleted="CREDIT_BALANCE_DEPLETED",$t.CreditBalanceLow="CREDIT_BALANCE_LOW",$t.CreditGrantBalanceLow="CREDIT_GRANT_BALANCE_LOW",$t.CreditGrantCreated="CREDIT_GRANT_CREATED",$t.CreditGrantDepleted="CREDIT_GRANT_DEPLETED",$t.CreditGrantExpired="CREDIT_GRANT_EXPIRED",$t.CreditGrantUpdated="CREDIT_GRANT_UPDATED",$t.CreditGrantVoided="CREDIT_GRANT_VOIDED",$t.CustomerCreated="CUSTOMER_CREATED",$t.CustomerDeleted="CUSTOMER_DELETED",$t.CustomerEntitlementCalculationTriggered="CUSTOMER_ENTITLEMENT_CALCULATION_TRIGGERED",$t.CustomerPaymentFailed="CUSTOMER_PAYMENT_FAILED",$t.CustomerResourceEntitlementCalculationTriggered="CUSTOMER_RESOURCE_ENTITLEMENT_CALCULATION_TRIGGERED",$t.CustomerUpdated="CUSTOMER_UPDATED",$t.EdgeApiClientConfigurationDataResync="EDGE_API_CLIENT_CONFIGURATION_DATA_RESYNC",$t.EdgeApiCustomerDataResync="EDGE_API_CUSTOMER_DATA_RESYNC",$t.EdgeApiDataResync="EDGE_API_DATA_RESYNC",$t.EdgeApiDoggoResync="EDGE_API_DOGGO_RESYNC",$t.EdgeApiPackageEntitlementsDataResync="EDGE_API_PACKAGE_ENTITLEMENTS_DATA_RESYNC",$t.EdgeApiSubscriptionsDataResync="EDGE_API_SUBSCRIPTIONS_DATA_RESYNC",$t.EntitlementsUpdated="ENTITLEMENTS_UPDATED",$t.EntitlementDenied="ENTITLEMENT_DENIED",$t.EntitlementGranted="ENTITLEMENT_GRANTED",$t.EntitlementRequested="ENTITLEMENT_REQUESTED",$t.EntitlementUsageExceeded="ENTITLEMENT_USAGE_EXCEEDED",$t.EnvironmentDeleted="ENVIRONMENT_DELETED",$t.FeatureArchived="FEATURE_ARCHIVED",$t.FeatureCreated="FEATURE_CREATED",$t.FeatureDeleted="FEATURE_DELETED",$t.FeatureGroupArchived="FEATURE_GROUP_ARCHIVED",$t.FeatureGroupCreated="FEATURE_GROUP_CREATED",$t.FeatureGroupUnArchived="FEATURE_GROUP_UN_ARCHIVED",$t.FeatureGroupUpdated="FEATURE_GROUP_UPDATED",$t.FeatureUpdated="FEATURE_UPDATED",$t.ImportIntegrationCatalogTriggered="IMPORT_INTEGRATION_CATALOG_TRIGGERED",$t.ImportIntegrationCustomersTriggered="IMPORT_INTEGRATION_CUSTOMERS_TRIGGERED",$t.ImportSubscriptionsBulkTriggered="IMPORT_SUBSCRIPTIONS_BULK_TRIGGERED",$t.MeasurementReported="MEASUREMENT_REPORTED",$t.PackageGroupCreated="PACKAGE_GROUP_CREATED",$t.PackageGroupUpdated="PACKAGE_GROUP_UPDATED",$t.PackagePublished="PACKAGE_PUBLISHED",$t.PlanCreated="PLAN_CREATED",$t.PlanDeleted="PLAN_DELETED",$t.PlanUpdated="PLAN_UPDATED",$t.ProductCreated="PRODUCT_CREATED",$t.ProductDeleted="PRODUCT_DELETED",$t.ProductUpdated="PRODUCT_UPDATED",$t.PromotionalEntitlementEndsSoon="PROMOTIONAL_ENTITLEMENT_ENDS_SOON",$t.PromotionalEntitlementExpired="PROMOTIONAL_ENTITLEMENT_EXPIRED",$t.PromotionalEntitlementGranted="PROMOTIONAL_ENTITLEMENT_GRANTED",$t.PromotionalEntitlementRevoked="PROMOTIONAL_ENTITLEMENT_REVOKED",$t.PromotionalEntitlementUpdated="PROMOTIONAL_ENTITLEMENT_UPDATED",$t.RecalculateEntitlementsTriggered="RECALCULATE_ENTITLEMENTS_TRIGGERED",$t.ResyncIntegrationTriggered="RESYNC_INTEGRATION_TRIGGERED",$t.SubscriptionsMigrated="SUBSCRIPTIONS_MIGRATED",$t.SubscriptionsMigrationTriggered="SUBSCRIPTIONS_MIGRATION_TRIGGERED",$t.SubscriptionBillingMonthEndsSoon="SUBSCRIPTION_BILLING_MONTH_ENDS_SOON",$t.SubscriptionCanceled="SUBSCRIPTION_CANCELED",$t.SubscriptionCreated="SUBSCRIPTION_CREATED",$t.SubscriptionExpired="SUBSCRIPTION_EXPIRED",$t.SubscriptionSpentLimitExceeded="SUBSCRIPTION_SPENT_LIMIT_EXCEEDED",$t.SubscriptionTrialConverted="SUBSCRIPTION_TRIAL_CONVERTED",$t.SubscriptionTrialEndsSoon="SUBSCRIPTION_TRIAL_ENDS_SOON",$t.SubscriptionTrialExpired="SUBSCRIPTION_TRIAL_EXPIRED",$t.SubscriptionTrialStarted="SUBSCRIPTION_TRIAL_STARTED",$t.SubscriptionUpdated="SUBSCRIPTION_UPDATED",$t.SubscriptionUsageChargeTriggered="SUBSCRIPTION_USAGE_CHARGE_TRIGGERED",$t.SubscriptionUsageUpdated="SUBSCRIPTION_USAGE_UPDATED",$t.SyncFailed="SYNC_FAILED",$t.WidgetConfigurationUpdated="WIDGET_CONFIGURATION_UPDATED",(ur=e.o_I||(e.o_I={})).CreatedAt="createdAt",ur.EnvironmentId="environmentId",ur.Id="id",ur.Name="name",ur.ProductId="productId",ur.RefId="refId",ur.Status="status",(en=e.bWm||(e.bWm={})).Completed="COMPLETED",en.Draft="DRAFT",en.InProgress="IN_PROGRESS",(cr=e.i4m||(e.i4m={})).CreatedAt="createdAt",cr.DisplayName="displayName",cr.EnvironmentId="environmentId",cr.FeatureGroupId="featureGroupId",cr.Id="id",cr.IsLatest="isLatest",cr.Status="status",cr.UpdatedAt="updatedAt",cr.VersionNumber="versionNumber",(Ir=e.sEr||(e.sEr={})).Archived="ARCHIVED",Ir.Published="PUBLISHED",(pn=e.GAT||(e.GAT={})).CreatedAt="createdAt",pn.Description="description",pn.DisplayName="displayName",pn.EnvironmentId="environmentId",pn.FeatureStatus="featureStatus",pn.FeatureType="featureType",pn.Id="id",pn.MeterType="meterType",pn.RefId="refId",pn.UpdatedAt="updatedAt",(cn=e.iKc||(e.iKc={})).Active="ACTIVE",cn.New="NEW",cn.Suspended="SUSPENDED",(Ae=e.Tex||(e.Tex={})).Boolean="BOOLEAN",Ae.Enum="ENUM",Ae.Number="NUMBER",(kn=e.U9t||(e.U9t={})).Bold="BOLD",kn.Normal="NORMAL",(ne=e.uMn||(e.uMn={})).CreatedAt="createdAt",ne.Endpoint="endpoint",ne.EnvironmentId="environmentId",ne.Id="id",ne.Status="status",(se=e.qBr||(e.qBr={})).Active="ACTIVE",se.Inactive="INACTIVE",(Nt=e.B8X||(e.B8X={})).CreatedAt="createdAt",Nt.EnvironmentId="environmentId",Nt.Id="id",Nt.Status="status",Nt.TaskType="taskType",(It=e.Us3||(e.Us3={})).CreatedAt="createdAt",It.EnvironmentId="environmentId",It.Id="id",It.VendorIdentifier="vendorIdentifier",It.VendorType="vendorType",(Lt=e.isD||(e.isD={})).AddonCharge="AddonCharge",Lt.BaseCharge="BaseCharge",Lt.InAdvanceCommitmentCharge="InAdvanceCommitmentCharge",Lt.MinimumSpendAdjustmentCharge="MinimumSpendAdjustmentCharge",Lt.MinimumSpendCharge="MinimumSpendCharge",Lt.Other="Other",Lt.OverageCharge="OverageCharge",Lt.PayAsYouGoCharge="PayAsYouGoCharge",Lt.TierCharge="TierCharge",Lt.ZeroAmountBaseCharge="ZeroAmountBaseCharge",(ft=e.Kyg||(e.Kyg={})).CreatedAt="createdAt",ft.Email="email",ft.Id="id",(_t=e.XY6||(e.XY6={})).Invited="INVITED",_t.Registered="REGISTERED",(it=e.puT||(e.puT={})).Fluctuating="Fluctuating",it.Incremental="Incremental",it.None="None",(Z=e.pSI||(e.pSI={})).StartOfTheMonth="StartOfTheMonth",Z.SubscriptionStart="SubscriptionStart",(ot=e.gpE||(e.gpE={})).CreatedAt="createdAt",ot.EnvironmentId="environmentId",ot.Id="id",ot.IsDefault="isDefault",ot.IsLatest="isLatest",ot.OfferId="offerId",ot.Status="status",ot.Version="version",(gt=e.PVi||(e.PVi={})).Archived="ARCHIVED",gt.Draft="DRAFT",gt.Published="PUBLISHED",(Vt=e.q5V||(e.q5V={})).Monthly="MONTHLY",Vt.OnSubscriptionRenewal="ON_SUBSCRIPTION_RENEWAL",(Ce=e.zv6||(e.zv6={})).BillingId="billingId",Ce.CreatedAt="createdAt",Ce.Description="description",Ce.DisplayName="displayName",Ce.EnvironmentId="environmentId",Ce.Id="id",Ce.IsLatest="isLatest",Ce.PricingType="pricingType",Ce.ProductId="productId",Ce.RefId="refId",Ce.Status="status",Ce.UpdatedAt="updatedAt",Ce.VersionNumber="versionNumber",(Co=e.iI3||(e.iI3={})).CreatedAt="createdAt",Co.EnvironmentId="environmentId",Co.Id="id",Co.PackageId="packageId",Co.UpdatedAt="updatedAt",(jr=e.jCI||(e.jCI={})).CreatedAt="createdAt",jr.DisplayName="displayName",jr.EnvironmentId="environmentId",jr.IsLatest="isLatest",jr.PackageGroupId="packageGroupId",jr.ProductId="productId",jr.Status="status",jr.UpdatedAt="updatedAt",jr.VersionNumber="versionNumber",(vo=e.OeJ||(e.OeJ={})).Archived="ARCHIVED",vo.Draft="DRAFT",vo.Published="PUBLISHED",(wi=e.TVs||(e.TVs={})).Archived="ARCHIVED",wi.Draft="DRAFT",wi.Published="PUBLISHED",(lr=e.QdX||(e.QdX={})).ActionRequired="ACTION_REQUIRED",lr.Failed="FAILED",lr.NotRequired="NOT_REQUIRED",lr.Processing="PROCESSING",(Jn=e.Kf7||(e.Kf7={})).Charge="CHARGE",Jn.Invoice="INVOICE",Jn.None="NONE",(sr=e.LtK||(e.LtK={})).Bank="BANK",sr.Card="CARD",sr.CashApp="CASH_APP",(ar=e.Cc7||(e.Cc7={})).Downgrade="DOWNGRADE",ar.None="NONE",ar.Upgrade="UPGRADE",(bt=e.qXR||(e.qXR={})).BillingId="billingId",bt.CreatedAt="createdAt",bt.Description="description",bt.DisplayName="displayName",bt.EnvironmentId="environmentId",bt.Id="id",bt.IsLatest="isLatest",bt.PricingType="pricingType",bt.ProductId="productId",bt.RefId="refId",bt.Status="status",bt.UpdatedAt="updatedAt",bt.VersionNumber="versionNumber",(Ve=e.YGW||(e.YGW={})).BillingCadence="billingCadence",Ve.BillingId="billingId",Ve.BillingModel="billingModel",Ve.BillingPeriod="billingPeriod",Ve.CreatedAt="createdAt",Ve.Id="id",Ve.TiersMode="tiersMode",(vr=e._HY||(e._HY={})).Custom="CUSTOM",vr.Free="FREE",vr.Paid="PAID",(De=e.p_C||(e.p_C={})).AwsMarketplaceProductCode="awsMarketplaceProductCode",De.AwsMarketplaceProductId="awsMarketplaceProductId",De.CreatedAt="createdAt",De.Description="description",De.DisplayName="displayName",De.EnvironmentId="environmentId",De.Id="id",De.IsDefaultProduct="isDefaultProduct",De.MultipleSubscriptions="multipleSubscriptions",De.RefId="refId",De.UpdatedAt="updatedAt",(_e=e.JkE||(e.JkE={})).Custom="CUSTOM",_e.Lifetime="LIFETIME",_e.OneMonth="ONE_MONTH",_e.OneWeek="ONE_WEEK",_e.OneYear="ONE_YEAR",_e.SixMonth="SIX_MONTH",(or=e.ku9||(e.ku9={})).CreatedAt="createdAt",or.EnvironmentId="environmentId",or.Id="id",or.Status="status",or.UpdatedAt="updatedAt",(dn=e.$Vq||(e.$Vq={})).Active="Active",dn.Expired="Expired",dn.Paused="Paused",(Ke=e.QZw||(e.QZw={})).CreateProrations="CREATE_PRORATIONS",Ke.InvoiceImmediately="INVOICE_IMMEDIATELY",(ln=e.u0j||(e.u0j={})).PaymentRequired="PAYMENT_REQUIRED",ln.Success="SUCCESS",(Gn=e.Zam||(e.Zam={})).AllCustomers="ALL_CUSTOMERS",Gn.NewCustomers="NEW_CUSTOMERS",(Pn=e.nM6||(e.nM6={})).EndOfBillingMonth="END_OF_BILLING_MONTH",Pn.EndOfBillingPeriod="END_OF_BILLING_PERIOD",Pn.Immediate="IMMEDIATE",(Ze=e.SrV||(e.SrV={})).Asc="ASC",Ze.Desc="DESC",(sn=e.Xm9||(e.Xm9={})).NullsFirst="NULLS_FIRST",sn.NullsLast="NULLS_LAST",(je=e.PO0||(e.PO0={})).JsClientSdk="JS_CLIENT_SDK",je.NodeServerSdk="NODE_SERVER_SDK",je.PersistentCacheService="PERSISTENT_CACHE_SERVICE",(Ee=e.ueJ||(e.ueJ={})).CreatedAt="createdAt",Ee.Id="id",Ee.Quantity="quantity",Ee.UpdatedAt="updatedAt",(re=e.w1y||(e.w1y={})).AutoCancellationRule="AutoCancellationRule",re.CancelledByBilling="CancelledByBilling",re.CustomerArchived="CustomerArchived",re.DetachBilling="DetachBilling",re.Expired="Expired",re.Immediate="Immediate",re.PendingPaymentExpired="PendingPaymentExpired",re.ScheduledCancellation="ScheduledCancellation",re.TrialConverted="TrialConverted",re.TrialEnded="TrialEnded",re.UpgradeOrDowngrade="UpgradeOrDowngrade",(ee=e.c06||(e.c06={})).Default="DEFAULT",ee.RevokeEntitlements="REVOKE_ENTITLEMENTS",(Jt=e.lS0||(e.lS0={})).EndOfBillingPeriod="END_OF_BILLING_PERIOD",Jt.Immediate="IMMEDIATE",Jt.SpecificDate="SPECIFIC_DATE",(Gt=e.abb||(e.abb={})).Active="ACTIVE",Gt.Expired="EXPIRED",Gt.Removed="REMOVED",(jt=e.ird||(e.ird={})).PredefinedFreePlan="PREDEFINED_FREE_PLAN",jt.PredefinedTrialPlan="PREDEFINED_TRIAL_PLAN",jt.RequestedPlan="REQUESTED_PLAN",jt.SkippedSubscriptionCreation="SKIPPED_SUBSCRIPTION_CREATION",(Ct=e._oj||(e._oj={})).CancelSubscription="CANCEL_SUBSCRIPTION",Ct.DowngradeToFree="DOWNGRADE_TO_FREE",(mt=e.e1Q||(e.e1Q={})).CreatedAt="createdAt",mt.EnvironmentId="environmentId",mt.Id="id",mt.SubscriptionId="subscriptionId",mt.UpdatedAt="updatedAt",(dt=e.tV1||(e.tV1={})).BillingCycle="BILLING_CYCLE",dt.Manual="MANUAL",dt.MinimumInvoiceAmountExceeded="MINIMUM_INVOICE_AMOUNT_EXCEEDED",dt.Other="OTHER",dt.SubscriptionCreation="SUBSCRIPTION_CREATION",dt.SubscriptionUpdate="SUBSCRIPTION_UPDATE",(pt=e.G6j||(e.G6j={})).Canceled="CANCELED",pt.Open="OPEN",pt.Paid="PAID",(at=e.eSW||(e.eSW={})).CreatedAt="createdAt",at.EnvironmentId="environmentId",at.Id="id",at.Status="status",at.TaskType="taskType",(Y=e.DWP||(e.DWP={})).EndOfBillingPeriod="END_OF_BILLING_PERIOD",Y.Immediate="IMMEDIATE",(ut=e.yBL||(e.yBL={})).BillingModel="billingModel",ut.CreatedAt="createdAt",ut.FeatureId="featureId",ut.HasSoftLimit="hasSoftLimit",ut.Id="id",ut.UpdatedAt="updatedAt",ut.UsageLimit="usageLimit",(j=e.SQC||(e.SQC={})).CreateProrations="CREATE_PRORATIONS",j.InvoiceImmediately="INVOICE_IMMEDIATELY",j.None="NONE",(U=e.o88||(e.o88={})).BillingId="billingId",U.CreatedAt="createdAt",U.CustomerId="customerId",U.EnvironmentId="environmentId",U.ProductId="productId",U.ResourceId="resourceId",U.SalesforceId="salesforceId",U.StartDate="startDate",U.Status="status",U.SubscriptionId="subscriptionId",(st=e.cUf||(e.cUf={})).Canceled="Canceled",st.Done="Done",st.Failed="Failed",st.PendingPayment="PendingPayment",st.Scheduled="Scheduled",(nt=e.YVG||(e.YVG={})).AdditionalMetaData="AdditionalMetaData",nt.Addon="Addon",nt.BillingInfoMetadata="BillingInfoMetadata",nt.BillingPeriod="BillingPeriod",nt.Coupon="Coupon",nt.Downgrade="Downgrade",nt.MigrateToLatest="MigrateToLatest",nt.Plan="Plan",nt.PriceOverride="PriceOverride",nt.UnitAmount="UnitAmount",(X=e.nOi||(e.nOi={})).FreePlan="FREE_PLAN",X.PlanSelection="PLAN_SELECTION",X.TrialPeriod="TRIAL_PERIOD",(G=e.yhH||(e.yhH={})).Active="ACTIVE",G.Canceled="CANCELED",G.Expired="EXPIRED",G.InTrial="IN_TRIAL",G.NotStarted="NOT_STARTED",G.PaymentPending="PAYMENT_PENDING",(V=e.XqI||(e.XqI={})).AlwaysReset="ALWAYS_RESET",V.BillingPeriodChange="BILLING_PERIOD_CHANGE",V.NeverReset="NEVER_RESET",(N=e.wRo||(e.wRo={})).Error="ERROR",N.NoSyncRequired="NO_SYNC_REQUIRED",N.Pending="PENDING",N.Success="SUCCESS",(O=e.hYU||(e.hYU={})).Canceled="CANCELED",O.Completed="COMPLETED",O.Failed="FAILED",O.InProgress="IN_PROGRESS",O.PartiallyFailed="PARTIALLY_FAILED",O.Pending="PENDING",(A=e.UAI||(e.UAI={})).ImportIntegrationCatalog="IMPORT_INTEGRATION_CATALOG",A.ImportIntegrationCustomers="IMPORT_INTEGRATION_CUSTOMERS",A.ImportSubscriptionsBulk="IMPORT_SUBSCRIPTIONS_BULK",A.RecalculateBatchEntitlements="RECALCULATE_BATCH_ENTITLEMENTS",A.RecalculateEntitlements="RECALCULATE_ENTITLEMENTS",A.ResyncIntegration="RESYNC_INTEGRATION",A.SubscriptionMigration="SUBSCRIPTION_MIGRATION",A.SubscriptionMigrationV2="SUBSCRIPTION_MIGRATION_V2",(F=e.PNd||(e.PNd={})).Graduated="GRADUATED",F.Volume="VOLUME",(I=e.bk4||(e.bk4={})).CancelSubscription="CANCEL_SUBSCRIPTION",I.ConvertToPaid="CONVERT_TO_PAID",(T=e.p13||(e.p13={})).Day="DAY",T.Month="MONTH",(x=e.Dfv||(e.Dfv={})).Down="DOWN",x.Up="UP",(P=e.X3h||(e.X3h={})).PeriodicReset="PERIODIC_RESET",P.SubscriptionChangeReset="SUBSCRIPTION_CHANGE_RESET",(v=e.Buv||(e.Buv={})).CreatedAt="createdAt",v.EnvironmentId="environmentId",v.Id="id",(h=e._yy||(e._yy={})).Delta="DELTA",h.Set="SET",(p=e.FoD||(e.FoD={})).Auth0="AUTH0",p.AwsMarketplace="AWS_MARKETPLACE",p.BigQuery="BIG_QUERY",p.Hubspot="HUBSPOT",p.OpenFga="OPEN_FGA",p.Salesforce="SALESFORCE",p.Snowflake="SNOWFLAKE",p.Stripe="STRIPE",p.Zuora="ZUORA",(c=e.O0T||(e.O0T={})).Auth="AUTH",c.Billing="BILLING",c.Crm="CRM",c.DataExport="DATA_EXPORT",c.Marketplace="MARKETPLACE",(s=e.rCU||(e.rCU={})).EveryFriday="EveryFriday",s.EveryMonday="EveryMonday",s.EverySaturday="EverySaturday",s.EverySunday="EverySunday",s.EveryThursday="EveryThursday",s.EveryTuesday="EveryTuesday",s.EveryWednesday="EveryWednesday",s.SubscriptionStart="SubscriptionStart",(o=e.l9N||(e.l9N={})).Checkout="CHECKOUT",o.CustomerPortal="CUSTOMER_PORTAL",o.Paywall="PAYWALL",(e.EOH||(e.EOH={})).SubscriptionStart="SubscriptionStart",(i=e.zOd||(e.zOd={})).Control="CONTROL",i.Variant="VARIANT",e.JU=r.default`
2387
+ Reason: ${E}`))}))}_process(a){this._numProcessing+=1,a.then((l=>(this._numProcessing-=1,l)),(l=>(this._numProcessing-=1,l)));}_sendEnvelope(a){this._transport&&this._dsn?this._transport.send(a).then(null,(l=>{(typeof __SENTRY_DEBUG__=="undefined"||__SENTRY_DEBUG__)&&Fe.error("Error while sending event:",l);})):(typeof __SENTRY_DEBUG__=="undefined"||__SENTRY_DEBUG__)&&Fe.error("Transport disabled");}_clearOutcomes(){var a=this._outcomes;return this._outcomes={},Object.keys(a).map((l=>{let[d,m]=l.split(":");return {reason:d,category:m,quantity:a[l]}}))}}var Vh="7.11.1",Zn=(0, _n.R)();class Wr extends Ys{constructor(a){a._metadata=a._metadata||{},a._metadata.sdk=a._metadata.sdk||{name:"sentry.javascript.browser",packages:[{name:"npm:@sentry/browser",version:Vh}],version:Vh},super(a),a.sendClientReports&&Zn.document&&Zn.document.addEventListener("visibilitychange",(()=>{Zn.document.visibilityState==="hidden"&&this._flushOutcomes();}));}eventFromException(a,l){return (function(d,m,y,b){var E=wu(d,m,y&&y.syntheticException||void 0,b);return Ua(E),E.level="error",y&&y.event_id&&(E.event_id=y.event_id),Ga(E)})(this._options.stackParser,a,l,this._options.attachStacktrace)}eventFromMessage(a,l="info",d){return (function(m,y,b="info",E,w){var D=zs(m,y,E&&E.syntheticException||void 0,w);return D.level=b,E&&E.event_id&&(D.event_id=E.event_id),Ga(D)})(this._options.stackParser,a,l,d,this._options.attachStacktrace)}sendEvent(a,l){var d=this.getIntegrationById(Jl);d&&d.options&&d.options.sentry&&Ln().addBreadcrumb({category:"sentry."+(a.type==="transaction"?"transaction":"event"),event_id:a.event_id,level:a.level,message:Br(a)},{event:a}),super.sendEvent(a,l);}_prepareEvent(a,l,d){return a.platform=a.platform||"javascript",super._prepareEvent(a,l,d)}_flushOutcomes(){var a=this._clearOutcomes();if(a.length!==0)if(this._dsn){(typeof __SENTRY_DEBUG__=="undefined"||__SENTRY_DEBUG__)&&Fe.log("Sending outcomes:",a);var l,d,m=Gh(this._dsn,this._options),y=(l=a,Fr((d=this._options.tunnel&&_p(this._dsn))?{dsn:d}:{},[[{type:"client_report"},{timestamp:(0, $a.yW)(),discarded_events:l}]]));try{(function(b,E){Object.prototype.toString.call(gi&&gi.navigator)==="[object Navigator]"&&typeof gi.navigator.sendBeacon=="function"?gi.navigator.sendBeacon.bind(gi.navigator)(b,E):Eu()&&Bh()(b,{body:E,method:"POST",credentials:"omit",keepalive:!0}).then(null,(w=>{(typeof __SENTRY_DEBUG__=="undefined"||__SENTRY_DEBUG__)&&Fe.error(w);}));})(m,xp(y));}catch(b){(typeof __SENTRY_DEBUG__=="undefined"||__SENTRY_DEBUG__)&&Fe.error(b);}}else (typeof __SENTRY_DEBUG__=="undefined"||__SENTRY_DEBUG__)&&Fe.log("No dsn provided, will not send outcomes");else (typeof __SENTRY_DEBUG__=="undefined"||__SENTRY_DEBUG__)&&Fe.log("No outcomes to send");}}var ub=n(4147),zh=[new $r.InboundFilters,new $r.FunctionToString,new $r.TryCatch,new $r.Breadcrumbs,new $r.LinkedErrors,new $r.Dedupe,new $r.HttpContext],Ou=new na,Tp=function(){return Tp=Object.assign||function(f){for(var a,l=1,d=arguments.length;l<d;l++)for(var m in a=arguments[l])Object.prototype.hasOwnProperty.call(a,m)&&(f[m]=a[m]);return f},Tp.apply(this,arguments)};function wp(f){return f?Object.keys(f).map((function(a){return Tp({isFallback:true,accessDeniedReason:h.fEx.Unknown,feature:{id:a}},f[a])})):[]}var Ha=function(){return Ha=Object.assign||function(f){for(var a,l=1,d=arguments.length;l<d;l++)for(var m in a=arguments[l])Object.prototype.hasOwnProperty.call(a,m)&&(f[m]=a[m]);return f},Ha.apply(this,arguments)};function vn(f,a){return l=this,d=void 0,y=function(){return (function(b,E){var w,D,_,M,B={label:0,sent:function(){if(1&_[0])throw _[1];return _[1]},trys:[],ops:[]};return M={next:H(0),throw:H(1),return:H(2)},typeof Symbol=="function"&&(M[Symbol.iterator]=function(){return this}),M;function H(K){return function(J){return (function(tt){if(w)throw new TypeError("Generator is already executing.");for(;B;)try{if(w=1,D&&(_=2&tt[0]?D.return:tt[0]?D.throw||((_=D.return)&&_.call(D),0):D.next)&&!(_=_.call(D,tt[1])).done)return _;switch(D=0,_&&(tt=[2&tt[0],_.value]),tt[0]){case 0:case 1:_=tt;break;case 4:return B.label++,{value:tt[1],done:!1};case 5:B.label++,D=tt[1],tt=[0];continue;case 7:tt=B.ops.pop(),B.trys.pop();continue;default:if(!((_=(_=B.trys).length>0&&_[_.length-1])||tt[0]!==6&&tt[0]!==2)){B=0;continue}if(tt[0]===3&&(!_||tt[1]>_[0]&&tt[1]<_[3])){B.label=tt[1];break}if(tt[0]===6&&B.label<_[1]){B.label=_[1],_=tt;break}if(_&&B.label<_[2]){B.label=_[2],B.ops.push(tt);break}_[2]&&B.ops.pop(),B.trys.pop();continue}tt=E.call(b,B);}catch(yt){tt=[6,yt],D=0;}finally{w=_=0;}if(5&tt[0])throw tt[1];return {value:tt[0]?tt[1]:void 0,done:true}})([K,J])}}})(this,(function(b){switch(b.label){case 0:return b.trys.push([0,2,,3]),[4,f()];case 1:return [2,b.sent()];case 2:return [2,Hh(b.sent(),a)];case 3:return [2]}}))},new((m=void 0)||(m=Promise))((function(b,E){function w(M){try{_(y.next(M));}catch(B){E(B);}}function D(M){try{_(y.throw(M));}catch(B){E(B);}}function _(M){var B;M.done?b(M.value):(B=M.value,B instanceof m?B:new m((function(H){H(B);}))).then(w,D);}_((y=y.apply(l,d||[])).next());}));var l,d,m,y;}function Oo(f,a){try{return f()}catch(l){return Hh(l,a)}}function Hh(f,a){var l=a.loggerService,d=a.sdkConfiguration,m=a.errorMessage,y=a.rethrowError,b=a.errorReportMetadata,E=m?m(f):"Operation failed. Error: ".concat(f.message);if(l.error(E,f),(function(w,D){var _=D.sdkConfiguration,M=D.errorMessage,B=D.errorReportMetadata;Ou.withScope((function(H){var K={errorMessage:M};if(_){var J=_.customerId,tt=Ha(Ha({},_),{apiKey:void 0});J&&H.setTags({customerId:J}),K.sdkConfiguration=tt;}B&&(K=Ha(Ha({},K),B)),H.setExtras(K),Ou.captureException(w);}));})(f,{sdkConfiguration:d,errorMessage:E,errorReportMetadata:b}),y)throw new Error(E)}var Hn=function(){return Hn=Object.assign||function(f){for(var a,l=1,d=arguments.length;l<d;l++)for(var m in a=arguments[l])Object.prototype.hasOwnProperty.call(a,m)&&(f[m]=a[m]);return f},Hn.apply(this,arguments)},de=function(f,a,l,d){return new(l||(l=Promise))((function(m,y){function b(D){try{w(d.next(D));}catch(_){y(_);}}function E(D){try{w(d.throw(D));}catch(_){y(_);}}function w(D){var _;D.done?m(D.value):(_=D.value,_ instanceof l?_:new l((function(M){M(_);}))).then(b,E);}w((d=d.apply(f,[])).next());}))},pe=function(f,a){var l,d,m,y,b={label:0,sent:function(){if(1&m[0])throw m[1];return m[1]},trys:[],ops:[]};return y={next:E(0),throw:E(1),return:E(2)},typeof Symbol=="function"&&(y[Symbol.iterator]=function(){return this}),y;function E(w){return function(D){return (function(_){if(l)throw new TypeError("Generator is already executing.");for(;b;)try{if(l=1,d&&(m=2&_[0]?d.return:_[0]?d.throw||((m=d.return)&&m.call(d),0):d.next)&&!(m=m.call(d,_[1])).done)return m;switch(d=0,m&&(_=[2&_[0],m.value]),_[0]){case 0:case 1:m=_;break;case 4:return b.label++,{value:_[1],done:!1};case 5:b.label++,d=_[1],_=[0];continue;case 7:_=b.ops.pop(),b.trys.pop();continue;default:if(!((m=(m=b.trys).length>0&&m[m.length-1])||_[0]!==6&&_[0]!==2)){b=0;continue}if(_[0]===3&&(!m||_[1]>m[0]&&_[1]<m[3])){b.label=_[1];break}if(_[0]===6&&b.label<m[1]){b.label=m[1],m=_;break}if(m&&b.label<m[2]){b.label=m[2],b.ops.push(_);break}m[2]&&b.ops.pop(),b.trys.pop();continue}_=a.call(f,b);}catch(M){_=[6,M],d=0;}finally{l=m=0;}if(5&_[0])throw _[1];return {value:_[0]?_[1]:void 0,done:true}})([w,D])}}},Wh=(function(){function f(a,l){this.modelMapper=new hh,this.eventEmitter=new yh,this.showWatermark=false,this.isWidgetWatermarkEnabled=false,this.configuration=a,this.edgeApiClient=cr.create(a,a),this.graphClient=(function(d){var m=d.apiKey,y=d.baseUri,b=d.clientName,E=b===void 0?dn:b,w=d.clientVersion,D=w===void 0?Jr.version:w,_=(function(H,K){return new Tt((function(J,tt){var yt={"X-API-KEY":H,"x-graphql-operation-name":J.operationName,source:Ke},Rt=K.customerToken;return Rt&&(yt["X-CUSTOMER-KEY"]=Rt),J.setContext({headers:yt}),tt(J)}))})(m,d),M=(function(H){return new Wc({uri:"".concat(H,"/graphql"),fetch:pn})})(y),B=new uh({attempts:{max:5,retryIf:Zo},delay:{initial:500,max:2e3,jitter:true}});return new Xo({link:_.concat(B.concat(M)),cache:new cu({possibleTypes:Zd.g}),name:E,version:D})})(this.configuration),this.loggerService=l,this.apiGateway=new sn(this.graphClient,this.edgeApiClient),this.globalEntitlementsService=null,this.resourceEntitlementsService=null,this.initializationStateTracker=new bh(this.eventEmitter);}return f.initialize=function(a){var l=(function(b){var E={baseUri:"https://api.stigg.io",baseEdgeUri:_e("https://api.stigg.io"),logConfiguration:{logger:console,logLevel:o.ERROR},enableEdge:true,cacheTtlMs:3e4},w=b.baseEdgeUri?b.baseEdgeUri:b.baseUri?_e(b.baseUri):E.baseEdgeUri,D=b.cacheTtlMs||b.entitlementPollingInterval;return ln()(E,b,{baseEdgeUri:w,cacheTtlMs:D})})(a),d=new p(l.logConfiguration.logger,l.logConfiguration.logLevel);if(l.offline){d.log("Stigg SDK has been initialized in offline mode, only fallback entitlements are being used.");var m=new Ru(l,d);return m.initializationStateTracker.signalSuccessInit(),m}(function(b,E){if(Pn()(b.apiKey)&&!b.offline){var w="You must configure the client with an SDK key";throw E.error(w),new Error(w)}})(l,d);var y=new f(l,d);return this.initializeSdk(y).then((function(){l.customerId?l.lazyLoad||y.setCustomerId(l.customerId,l.customerToken,l.resourceId):y.initializationStateTracker.signalSuccessInit();})).catch((function(b){return y.initializationStateTracker.signalFailedInit(b)})),y},f.prototype.waitForInitialization=function(){return de(this,void 0,void 0,(function(){var a=this;return pe(this,(function(l){return [2,this.initializationStateTracker.getInitializationPromise().then((function(){return a}))]}))}))},f.initializeSdk=function(a){var l,d,m,y;return de(this,void 0,void 0,(function(){var b,E,w,D;return pe(this,(function(_){switch(_.label){case 0:return _.trys.push([0,2,,3]),[4,a.apiGateway.sdkConfiguration.getSdkConfiguration()];case 1:return b=_.sent(),E=(l=b.data)===null||l===void 0?void 0:l.sdkConfiguration,!Ou.getClient()&&(E!=null&&E.sentryDsn)&&(J=E.sentryDsn,M=void 0,B=void 0,K=function(){var tt,yt;return (function(Rt,Zt){var zt,Bt,qt,$e,fe={label:0,sent:function(){if(1&qt[0])throw qt[1];return qt[1]},trys:[],ops:[]};return $e={next:Oe(0),throw:Oe(1),return:Oe(2)},typeof Symbol=="function"&&($e[Symbol.iterator]=function(){return this}),$e;function Oe(An){return function(Mr){return (function(u){if(zt)throw new TypeError("Generator is already executing.");for(;fe;)try{if(zt=1,Bt&&(qt=2&u[0]?Bt.return:u[0]?Bt.throw||((qt=Bt.return)&&qt.call(Bt),0):Bt.next)&&!(qt=qt.call(Bt,u[1])).done)return qt;switch(Bt=0,qt&&(u=[2&u[0],qt.value]),u[0]){case 0:case 1:qt=u;break;case 4:return fe.label++,{value:u[1],done:!1};case 5:fe.label++,Bt=u[1],u=[0];continue;case 7:u=fe.ops.pop(),fe.trys.pop();continue;default:if(!((qt=(qt=fe.trys).length>0&&qt[qt.length-1])||u[0]!==6&&u[0]!==2)){fe=0;continue}if(u[0]===3&&(!qt||u[1]>qt[0]&&u[1]<qt[3])){fe.label=u[1];break}if(u[0]===6&&fe.label<qt[1]){fe.label=qt[1],qt=u;break}if(qt&&fe.label<qt[2]){fe.label=qt[2],fe.ops.push(u);break}qt[2]&&fe.ops.pop(),fe.trys.pop();continue}u=Zt.call(Rt,fe);}catch(g){u=[6,g],Bt=0;}finally{zt=qt=0;}if(5&u[0])throw u[1];return {value:u[0]?u[1]:void 0,done:true}})([An,Mr])}}})(this,(function(Rt){return tt={dsn:J,normalizeDepth:6,release:"".concat(dn,"@").concat(ub.version),integrations:zh,stackParser:Cp,transport:Eu()?Uh:ku},yt=new Wr(tt),Ou.bindClient(yt),[2]}))},new((H=void 0)||(H=Promise))((function(tt,yt){function Rt(Bt){try{zt(K.next(Bt));}catch(qt){yt(qt);}}function Zt(Bt){try{zt(K.throw(Bt));}catch(qt){yt(qt);}}function zt(Bt){var qt;Bt.done?tt(Bt.value):(qt=Bt.value,qt instanceof H?qt:new H((function($e){$e(qt);}))).then(Rt,Zt);}zt((K=K.apply(M,B||[])).next());}))),a.showWatermark=!!(E!=null&&E.showWatermark),[3,3];case 2:throw w=_.sent(),((d=w.response)===null||d===void 0?void 0:d.status)===401||w.graphQLErrors&&((y=(m=w.graphQLErrors[0])===null||m===void 0?void 0:m.extensions)===null||y===void 0?void 0:y.code)===h.jKp.Unauthenticated?(D="Authentication failed. Double check your SDK key.",a.loggerService.error(D),new Error(D)):(a.loggerService.error("Failed to load sdk configuration",w),w);case 3:return [2]}var M,B,H,K,J;}))}))},Object.defineProperty(f.prototype,"isCustomerLoaded",{get:function(){var a;return ((a=this.globalEntitlementsService)===null||a===void 0?void 0:a.isInitialized)||false},enumerable:false,configurable:true}),Object.defineProperty(f.prototype,"isResourceLoaded",{get:function(){var a;return ((a=this.resourceEntitlementsService)===null||a===void 0?void 0:a.isInitialized)||false},enumerable:false,configurable:true}),f.prototype.getShowWatermark=function(){return this.showWatermark},f.prototype.addListener=function(a,l){this.eventEmitter.on(a,l);},f.prototype.removeListener=function(a,l){this.eventEmitter.off(a,l);},f.prototype.setCustomerId=function(a,l,d){return l===void 0&&(l=null),d===void 0&&(d=null),de(this,void 0,void 0,(function(){var m,y,b,E,w,D=this;return pe(this,(function(_){switch(_.label){case 0:if(m=this.configuration,y=m.customerToken,b=m.customerId,E=m.resourceId,a===b&&l===y&&d===E)return [2];if(this.clearCustomer(),!a)return this.loggerService.log("`setCustomerId` was called without a customerId, did you mean to call `clearCustomer`?"),[2];if(!(0, R.isString)(a))throw new Error("customerId parameter must be a string");if(l&&!(0, R.isString)(l))throw new Error("customerToken parameter must be a string");if(d&&!(0, R.isString)(d))throw new Error("resourceId parameter must be a string");this.configuration.customerId=a,this.configuration.customerToken=l,this.configuration.resourceId=d,this.globalEntitlementsService=new fi(a,void 0,new fu(this.configuration.cacheTtlMs),this.graphClient,this.edgeApiClient,this.loggerService,(function(M){return D.eventEmitter.emit("entitlementsUpdated",M)})),d&&(this.resourceEntitlementsService=new fi(a,d,new fu(this.configuration.cacheTtlMs),this.graphClient,this.edgeApiClient,this.loggerService,(function(M){return D.eventEmitter.emit("entitlementsUpdated",M)}))),_.label=1;case 1:return _.trys.push([1,3,,4]),[4,vn((function(){return de(D,void 0,void 0,(function(){var M,B;return pe(this,(function(H){switch(H.label){case 0:return [4,Promise.all([(M=this.globalEntitlementsService)===null||M===void 0?void 0:M.loadEntitlements(),(B=this.resourceEntitlementsService)===null||B===void 0?void 0:B.loadEntitlements()])];case 1:return H.sent(),[2]}}))}))}),{loggerService:this.loggerService,sdkConfiguration:this.configuration,errorMessage:function(M){return "Failed to load initial entitlements for customer. Error: ".concat(M.message)},rethrowError:true})];case 2:return _.sent(),this.initializationStateTracker.signalSuccessInit(),[3,4];case 3:return w=_.sent(),this.initializationStateTracker.signalFailedInit(w),[3,4];case 4:return [2]}}))}))},f.prototype.clearCustomer=function(){this.globalEntitlementsService=null,this.resourceEntitlementsService=null,this.configuration.customerId=null,this.configuration.customerToken=null,this.configuration.resourceId=null;},f.prototype.setResource=function(a){return de(this,void 0,void 0,(function(){var l,d,m=this;return pe(this,(function(y){switch(y.label){case 0:if(!this.configuration.customerId)throw new Error("`setResource` must be called when customer was set, did you forget to call `setCustomerId`?");if(l=this.configuration.resourceId,a===l)return [2];if(this.clearResource(),!(0, R.isString)(a))throw new Error("resourceId parameter must be a string");this.configuration.resourceId=a,this.resourceEntitlementsService=new fi(this.configuration.customerId,a,new fu(this.configuration.cacheTtlMs),this.graphClient,this.edgeApiClient,this.loggerService,(function(b){return m.eventEmitter.emit("entitlementsUpdated",b)})),y.label=1;case 1:return y.trys.push([1,3,,4]),[4,vn((function(){return de(m,void 0,void 0,(function(){var b;return pe(this,(function(E){return (b=this.resourceEntitlementsService)===null||b===void 0||b.loadEntitlements(),[2]}))}))}),{loggerService:this.loggerService,sdkConfiguration:this.configuration,errorMessage:function(b){return "Failed to load initial entitlements for customer resource. Error: ".concat(b.message)},rethrowError:true})];case 2:return y.sent(),this.initializationStateTracker.signalSuccessInit(),[3,4];case 3:return d=y.sent(),this.initializationStateTracker.signalFailedInit(d),[3,4];case 4:return [2]}}))}))},f.prototype.clearResource=function(){if(!this.configuration.customerId)throw new Error("`clearResource` must be called when customer was set, did you forget to call `setCustomerId`?");this.resourceEntitlementsService=null,this.configuration.resourceId=null;},f.prototype.refresh=function(){return de(this,void 0,void 0,(function(){var a=this;return pe(this,(function(l){return [2,vn((function(){return de(a,void 0,void 0,(function(){var d,m;return pe(this,(function(y){switch(y.label){case 0:return [4,Promise.all([(d=this.globalEntitlementsService)===null||d===void 0?void 0:d.refresh(),(m=this.resourceEntitlementsService)===null||m===void 0?void 0:m.refresh()])];case 1:return y.sent(),[2]}}))}))}),{loggerService:this.loggerService,sdkConfiguration:this.configuration,errorMessage:function(d){return "Failed to refresh entitlements. Error: ".concat(d.message)},rethrowError:true})]}))}))},f.prototype.getBooleanEntitlement=function(a){var l,d=this,m=a.featureId,y=a.options,b=a.resourceId,E=(y==null?void 0:y.fallback)||((l=this.configuration.entitlementsFallback)===null||l===void 0?void 0:l[m])||{},w=Hn(Hn({},v),E);return Oo((function(){return d.globalEntitlementsService&&d.isCustomerLoaded?b?b!==d.configuration.resourceId?(d.loggerService.log("Resource ID ".concat(b," does not match the current resource ID ").concat(d.configuration.resourceId,".")),d.loggerService.log("Using fallback entitlements for customer: ".concat(d.configuration.customerId," with resourceId ").concat(b,"}")),w):d.isResourceLoaded&&d.resourceEntitlementsService?d.resourceEntitlementsService.getBooleanEntitlement(m,w,y):w:d.globalEntitlementsService.getBooleanEntitlement(m,w,y):(d.loggerService.log("Using fallback entitlements for customer: ".concat(d.configuration.customerId,". Reason: ").concat(d.globalEntitlementsService?"Customer not loaded":"Entitlements service not initialized "),{initializationStatus:d.initializationStateTracker.initializationStatus,customerId:d.configuration.customerId||""}),w)}),{loggerService:this.loggerService,sdkConfiguration:this.configuration,errorMessage:function(D){return "Failed to get boolean entitlement. Error: ".concat(D.message)},rethrowError:false,errorReportMetadata:{featureId:m,options:y}})||(this.loggerService.log("Using fallback entitlements for customer: ".concat(this.configuration.customerId,". Reason: Failed to get entitlement")),w)},f.prototype.getNumericEntitlement=function(a){var l,d=this,m=a.featureId,y=a.options,b=a.resourceId,E=(y==null?void 0:y.fallback)||((l=this.configuration.entitlementsFallback)===null||l===void 0?void 0:l[m])||{},w=Hn(Hn({},P),E);return Oo((function(){return d.globalEntitlementsService&&d.isCustomerLoaded?b?b!==d.configuration.resourceId?(d.loggerService.log("Resource ID ".concat(b," does not match the current resource ID ").concat(d.configuration.resourceId,".")),d.loggerService.log("Using fallback entitlements for customer: ".concat(d.configuration.customerId," with resourceId ").concat(b,"}")),w):d.isResourceLoaded&&d.resourceEntitlementsService?d.resourceEntitlementsService.getNumericEntitlement(m,w,y):w:d.globalEntitlementsService.getNumericEntitlement(m,w,y):(d.loggerService.log("Using fallback entitlements for customer: ".concat(d.configuration.customerId,". Reason: ").concat(d.globalEntitlementsService?"Customer not loaded":"Entitlements service not initialized "),{initializationStatus:d.initializationStateTracker.initializationStatus,customerId:d.configuration.customerId||""}),w)}),{loggerService:this.loggerService,sdkConfiguration:this.configuration,errorMessage:function(D){return "Failed to get numeric entitlement. Error: ".concat(D.message)},rethrowError:false,errorReportMetadata:{featureId:m,options:y}})||(this.loggerService.log("Using fallback entitlements for customer: ".concat(this.configuration.customerId,". Reason: Failed to get entitlement")),w)},f.prototype.getMeteredEntitlement=function(a){var l,d=this,m=a.featureId,y=a.options,b=a.resourceId,E=(y==null?void 0:y.fallback)||((l=this.configuration.entitlementsFallback)===null||l===void 0?void 0:l[m])||{},w=Hn(Hn({},x),E);return Oo((function(){return d.globalEntitlementsService&&d.isCustomerLoaded?b?b!==d.configuration.resourceId?(d.loggerService.log("Resource ID ".concat(b," does not match the current resource ID ").concat(d.configuration.resourceId,".")),d.loggerService.log("Using fallback entitlements for customer: ".concat(d.configuration.customerId," with resourceId ").concat(b,"}")),w):d.isResourceLoaded&&d.resourceEntitlementsService?d.resourceEntitlementsService.getMeteredEntitlement(m,w,y):w:d.globalEntitlementsService.getMeteredEntitlement(m,w,y):(d.loggerService.log("Using fallback entitlements for customer: ".concat(d.configuration.customerId,". Reason: ").concat(d.globalEntitlementsService?"Customer not loaded":"Entitlements service not initialized "),{initializationStatus:d.initializationStateTracker.initializationStatus,customerId:d.configuration.customerId||""}),w)}),{loggerService:this.loggerService,sdkConfiguration:this.configuration,errorMessage:function(D){return "Failed to get metered entitlement. Error: ".concat(D.message)},rethrowError:false,errorReportMetadata:{featureId:m,options:y}})||(this.loggerService.log("Using fallback entitlements for customer: ".concat(this.configuration.customerId,". Reason: Failed to get entitlement")),w)},f.prototype.getEnumEntitlement=function(a){var l,d=this,m=a.featureId,y=a.options,b=a.resourceId,E=(y==null?void 0:y.fallback)||((l=this.configuration.entitlementsFallback)===null||l===void 0?void 0:l[m])||{},w=Hn(Hn({},T),E);return Oo((function(){return d.globalEntitlementsService&&d.isCustomerLoaded?b?b!==d.configuration.resourceId?(d.loggerService.log("Resource ID ".concat(b," does not match the current resource ID ").concat(d.configuration.resourceId,".")),d.loggerService.log("Using fallback entitlements for customer: ".concat(d.configuration.customerId," with resourceId ").concat(b,"}")),w):d.isResourceLoaded&&d.resourceEntitlementsService?d.resourceEntitlementsService.getEnumEntitlement(m,w,y):w:d.globalEntitlementsService.getEnumEntitlement(m,w,y):(d.loggerService.log("Using fallback entitlements for customer: ".concat(d.configuration.customerId,". Reason: ").concat(d.globalEntitlementsService?"Customer not loaded":"Entitlements service not initialized "),{initializationStatus:d.initializationStateTracker.initializationStatus,customerId:d.configuration.customerId||""}),w)}),{loggerService:this.loggerService,sdkConfiguration:this.configuration,errorMessage:function(D){return "Failed to get enum entitlement. Error: ".concat(D.message)},rethrowError:false,errorReportMetadata:{featureId:m,options:y}})||(this.loggerService.log("Using fallback entitlements for customer: ".concat(this.configuration.customerId,". Reason: Failed to get entitlement")),w)},f.prototype.getPaywall=function(a){var l=a===void 0?{}:a,d=l.productId,m=l.resourceId,y=l.context,b=l.billingCountryCode,E=l.includeHiddenPlans;return de(this,void 0,void 0,(function(){var w,D=this;return pe(this,(function(_){return w={productId:d,customerId:this.configuration.customerId,resourceId:m,context:y,billingCountryCode:b,includeHiddenPlans:E},[2,vn((function(){return de(D,void 0,void 0,(function(){var M;return pe(this,(function(B){switch(B.label){case 0:return d!=null&&d.startsWith("stiggTestData")?[4,this.apiGateway.mockPaywall.getMockPaywall(w)]:[3,2];case 1:return M=B.sent(),[2,this.modelMapper.mapMockPlans(M.data)];case 2:return [4,this.apiGateway.paywall.getPaywall(w)];case 3:return M=B.sent(),[2,this.modelMapper.mapPaywall(M.data)]}}))}))}),{loggerService:this.loggerService,sdkConfiguration:this.configuration,errorMessage:function(M){return "Failed to get paywall. Error: ".concat(M.message)},rethrowError:true,errorReportMetadata:{productId:d}})]}))}))},f.prototype.getCoupons=function(){return de(this,void 0,void 0,(function(){var a=this;return pe(this,(function(l){return [2,vn((function(){return de(a,void 0,void 0,(function(){var d;return pe(this,(function(m){switch(m.label){case 0:return [4,this.apiGateway.coupons.getCoupons()];case 1:return d=m.sent(),[2,this.modelMapper.mapCoupons(d.data)]}}))}))}),{loggerService:this.loggerService,sdkConfiguration:this.configuration,errorMessage:function(d){return "Failed to get coupons. Error: ".concat(d.message)},rethrowError:true})]}))}))},f.prototype.getCustomer=function(){return de(this,void 0,void 0,(function(){var a=this;return pe(this,(function(l){return [2,vn((function(){return de(a,void 0,void 0,(function(){var d,m,y,b;return pe(this,(function(E){switch(E.label){case 0:return d=De(this.configuration),[4,this.apiGateway.customers.getCustomer(d)];case 1:if(m=E.sent(),!(y=m.data.getCustomerByRefId))throw new Error("Customer not found");return b=y.subscriptions||[],[2,this.modelMapper.mapCustomer(y,b)]}}))}))}),{loggerService:this.loggerService,sdkConfiguration:this.configuration,errorMessage:function(d){return "Failed to get customer. Error: ".concat(d.message)},rethrowError:true})]}))}))},f.prototype.getCustomerPortal=function(a){var l=a===void 0?{}:a,d=l.resourceId,m=l.productId;return de(this,void 0,void 0,(function(){var y=this;return pe(this,(function(b){return [2,vn((function(){return de(y,void 0,void 0,(function(){var E,w;return pe(this,(function(D){switch(D.label){case 0:return E=De(this.configuration),[4,this.apiGateway.customers.getCustomerPortal(E,d,m)];case 1:return w=D.sent(),[2,this.modelMapper.mapCustomerPortal(w.data.customerPortal)]}}))}))}),{loggerService:this.loggerService,sdkConfiguration:this.configuration,errorMessage:function(E){return "Failed to get customer portal details. Error: ".concat(E.message)},rethrowError:true})]}))}))},f.prototype.getCheckoutState=function(a){var l=a.planId,d=a.resourceId,m=d===void 0?this.configuration.resourceId:d,y=a.billingCountryCode;return de(this,void 0,void 0,(function(){var b=this;return pe(this,(function(E){return [2,vn((function(){return de(b,void 0,void 0,(function(){var w,D;return pe(this,(function(_){switch(_.label){case 0:return w=De(this.configuration),[4,this.apiGateway.subscriptions.checkoutState({customerId:w,resourceId:m,planId:l,billingCountryCode:y})];case 1:return D=_.sent(),[2,this.modelMapper.mapCheckoutState(D.data.checkoutState)]}}))}))}),{loggerService:this.loggerService,sdkConfiguration:this.configuration,errorMessage:function(w){return "Failed to get checkout details. Error: ".concat(w.message)},rethrowError:true})]}))}))},f.prototype.applySubscription=function(a){return de(this,void 0,void 0,(function(){var l=this;return pe(this,(function(d){return [2,vn((function(){return de(l,void 0,void 0,(function(){var m,y;return pe(this,(function(b){switch(b.label){case 0:return m=De(this.configuration),[4,this.apiGateway.subscriptions.applySubscription(Hn({customerId:m},a))];case 1:if(!(y=b.sent().data)||!y.applySubscription)throw new Error("Invalid response");return [2,this.modelMapper.mapApplySubscriptionResults(y)]}}))}))}),{loggerService:this.loggerService,sdkConfiguration:this.configuration,errorMessage:function(m){return "Failed to apply subscription to customer. Error: ".concat(m.message)},rethrowError:true})]}))}))},f.prototype.fetchUsageHistory=function(a){return de(this,void 0,void 0,(function(){var l=this;return pe(this,(function(d){return [2,vn((function(){return de(l,void 0,void 0,(function(){var m;return pe(this,(function(y){switch(y.label){case 0:return [4,this.apiGateway.customers.fetchUsageHistory(a)];case 1:if(!(m=y.sent().data)||!m.usageHistory)throw new Error("Invalid response");return [2,this.modelMapper.mapUsageHistory(m.usageHistory)]}}))}))}),{loggerService:this.loggerService,sdkConfiguration:this.configuration,errorMessage:function(m){return "Failed to fetch usage history. Error: ".concat(m.message)},rethrowError:false})]}))}))},f.prototype.getEntitlements=function(a){return de(this,void 0,void 0,(function(){var l,d,m=this;return pe(this,(function(y){switch(y.label){case 0:return l=wp(this.configuration.entitlementsFallback),[4,vn((function(){return de(m,void 0,void 0,(function(){var b;return pe(this,(function(E){return De(this.configuration),a?a!==this.configuration.resourceId?(this.loggerService.log("Resource ID ".concat(a," does not match the current resource ID ").concat(this.configuration.resourceId,".")),this.loggerService.log("Using fallback entitlements for customer: ".concat(this.configuration.customerId," with resourceId ").concat(a,"}")),[2,l]):this.isResourceLoaded&&this.resourceEntitlementsService?(this.loggerService.log("Using fallback entitlements for customer: ".concat(this.configuration.customerId)),[2,this.resourceEntitlementsService.getEntitlements()]):[2,l]:[2,(b=this.globalEntitlementsService)===null||b===void 0?void 0:b.getEntitlements()]}))}))}),{loggerService:this.loggerService,sdkConfiguration:this.configuration,errorMessage:function(b){return "Failed to get entitlements. Error: ".concat(b.message)},rethrowError:true})];case 1:return (d=y.sent())?[2,d]:(this.loggerService.log("Using fallback entitlements for customer: ".concat(this.configuration.customerId,". Reason: Failed to get entitlements.")),[2,l])}}))}))},f.prototype.estimateSubscription=function(a){return de(this,void 0,void 0,(function(){var l=this;return pe(this,(function(d){return [2,vn((function(){return de(l,void 0,void 0,(function(){var m;return pe(this,(function(y){switch(y.label){case 0:return [4,this.apiGateway.subscriptionEstimations.estimateSubscription(a)];case 1:if(!(m=y.sent().data))throw new Error("Invalid response");return [2,this.modelMapper.mapSubscriptionPreview(m.estimateSubscription)]}}))}))}),{loggerService:this.loggerService,sdkConfiguration:this.configuration,errorMessage:function(m){return "Failed to estimate subscription. Error: ".concat(m.message)},rethrowError:true})]}))}))},f.prototype.estimateSubscriptionUpdate=function(a){return de(this,void 0,void 0,(function(){var l=this;return pe(this,(function(d){return [2,vn((function(){return de(l,void 0,void 0,(function(){var m;return pe(this,(function(y){switch(y.label){case 0:return [4,this.apiGateway.subscriptionEstimations.estimateSubscriptionUpdate(a)];case 1:if(!(m=y.sent().data))throw new Error("Invalid response");return [2,this.modelMapper.mapSubscriptionPreview(m.estimateSubscriptionUpdate)]}}))}))}),{loggerService:this.loggerService,sdkConfiguration:this.configuration,errorMessage:function(m){return "Failed to estimate subscription update. Error: ".concat(m.message)},rethrowError:true})]}))}))},f.prototype.previewNextInvoice=function(a){return de(this,void 0,void 0,(function(){var l=this;return pe(this,(function(d){return [2,vn((function(){return de(l,void 0,void 0,(function(){var m;return pe(this,(function(y){switch(y.label){case 0:return [4,this.apiGateway.subscriptionEstimations.previewNextInvoice(a)];case 1:if(!(m=y.sent().data))throw new Error("Invalid response");return [2,m.previewNextInvoice]}}))}))}),{loggerService:this.loggerService,sdkConfiguration:this.configuration,errorMessage:function(m){return "Failed to preview subscription next invoice. Error: ".concat(m.message)},rethrowError:true})]}))}))},f.prototype.previewSubscription=function(a){return de(this,void 0,void 0,(function(){var l=this;return pe(this,(function(d){return [2,vn((function(){return de(l,void 0,void 0,(function(){var m;return pe(this,(function(y){switch(y.label){case 0:return [4,this.apiGateway.subscriptionEstimations.previewSubscription(a)];case 1:if(!(m=y.sent().data))throw new Error("Invalid response");return [2,this.modelMapper.mapSubscriptionPreviewV2(m.previewSubscription)]}}))}))}),{loggerService:this.loggerService,sdkConfiguration:this.configuration,errorMessage:function(m){return "Failed to estimate checkout. Error: ".concat(m.message)},rethrowError:true})]}))}))},f.prototype.getUsageHistoryV2=function(a){return de(this,void 0,void 0,(function(){var l=this;return pe(this,(function(d){return [2,vn((function(){return de(l,void 0,void 0,(function(){return pe(this,(function(m){switch(m.label){case 0:return [4,this.apiGateway.usageHistoryApi.getUsageHistoryV2(a)];case 1:return [2,m.sent().data.usageHistoryV2]}}))}))}),{loggerService:this.loggerService,sdkConfiguration:this.configuration,errorMessage:function(m){return "Failed to get usage history. Error: ".concat(m.message)},rethrowError:true})]}))}))},f.prototype.waitForCheckoutCompleted=function(a){var l=a===void 0?{}:a,d=l.timeoutMs,m=d===void 0?15e3:d,y=l.refreshOnComplete,b=y===void 0||y;return de(this,void 0,void 0,(function(){var E,w,D,_,M,B,H,K;return pe(this,(function(J){switch(J.label){case 0:if(typeof window=="undefined")throw new Error("`waitForCheckoutCompleted` was called, but `window` is not defined");if(E=new URLSearchParams(window.location.search),w=E.get("subscriptionId"),D=E.get("resourceId")||void 0,_=E.get("checkoutCompleted"),!w)return this.loggerService.log("`waitCheckoutCompleted` was called, but no `subscriptionId` found in query params"),[2,null];if(!_||_.toLowerCase()==="false")return this.loggerService.log("The checkout session was cancelled by the user"),[2,null];M=Date.now(),B=false,H=null,J.label=1;case 1:return B?[4,new Promise((function(tt){return setTimeout(tt,1e3)}))]:[3,3];case 2:J.sent(),J.label=3;case 3:return [4,this.getActiveSubscriptions({resourceId:D})];case 4:K=J.sent(),H=K.find((function(tt){return tt.id===w}))||null,B=true,J.label=5;case 5:if(!H&&Date.now()-M<m)return [3,1];J.label=6;case 6:if(!H)throw new Error("Timeout while waiting for checkout to complete, subscription ".concat(w," is not active"));return b?[4,this.refresh()]:[3,8];case 7:J.sent(),J.label=8;case 8:return [2,H]}}))}))},f.prototype.getSubscriptions=function(a){return a===void 0&&(a={}),de(this,void 0,void 0,(function(){var l,d,m,y,b,E=this;return pe(this,(function(w){return l=a.customerId,d=a.resourceId,m=a.status,y=a.productId,b=a.pagination,[2,vn((function(){return de(E,void 0,void 0,(function(){var D;return pe(this,(function(_){switch(_.label){case 0:return [4,this.apiGateway.subscriptions.getSubscriptions(l,d,m,y,b)];case 1:return [2,{data:(D=_.sent()).data.subscriptions.edges.map((function(M){return M.node})),pageInfo:D.data.subscriptions.pageInfo}]}}))}))}),{loggerService:this.loggerService,sdkConfiguration:this.configuration,errorMessage:function(D){return "Failed to get active subscriptions. Error: ".concat(D.message)},rethrowError:true})]}))}))},f.prototype.getActiveSubscriptions=function(a){var l=this,d=(a===void 0?{}:a).resourceId;return vn((function(){return de(l,void 0,void 0,(function(){var m,y,b;return pe(this,(function(E){switch(E.label){case 0:return m=De(this.configuration),[4,this.apiGateway.customers.getActiveSubscriptions(m,d)];case 1:if(y=E.sent(),!(b=y.data.getActiveSubscriptions))throw new Error("Customer ".concat(d?"or resource ":"","not found"));return [2,this.modelMapper.mapSubscriptions(b)]}}))}))}),{loggerService:this.loggerService,sdkConfiguration:this.configuration,errorMessage:function(m){return "Failed to get active subscriptions. Error: ".concat(m.message)},rethrowError:true})},f.prototype.getActiveSubscriptionsList=function(a){var l=(a===void 0?{}:a).resourceId;return de(this,void 0,void 0,(function(){var d=this;return pe(this,(function(m){return [2,vn((function(){return de(d,void 0,void 0,(function(){var y;return pe(this,(function(b){switch(b.label){case 0:return y=De(this.configuration),[4,this.apiGateway.customers.getActiveSubscriptionsList(y,l)];case 1:return [2,b.sent().data.getActiveSubscriptions]}}))}))}),{loggerService:this.loggerService,sdkConfiguration:this.configuration,errorMessage:function(y){return "Failed to get active subscriptions list. Error: ".concat(y.message)},rethrowError:true})]}))}))},f.prototype.getSubscription=function(a){var l=a.subscriptionId;return de(this,void 0,void 0,(function(){var d=this;return pe(this,(function(m){return [2,vn((function(){return de(d,void 0,void 0,(function(){var y,b;return pe(this,(function(E){switch(E.label){case 0:return [4,this.apiGateway.customers.getSubscription(l)];case 1:return y=E.sent(),b=y.data.getSubscription,[2,this.modelMapper.mapSubscription(b)]}}))}))}),{loggerService:this.loggerService,sdkConfiguration:this.configuration,errorMessage:function(y){return "Failed to get subscription. Error: ".concat(y.message)},rethrowError:true})]}))}))},f.prototype.getCreditUsage=function(a){return de(this,void 0,void 0,(function(){var l=this;return pe(this,(function(d){return [2,vn((function(){return de(l,void 0,void 0,(function(){var m,y,b;return pe(this,(function(E){switch(E.label){case 0:return m=De(this.configuration),y=(b=this.configuration.resourceId)!==null&&b!==void 0?b:void 0,[4,this.apiGateway.credits.getCreditUsage(Hn(Hn({},a),{customerId:m,resourceId:y}))];case 1:return [2,E.sent().data.creditUsage]}}))}))}),{loggerService:this.loggerService,sdkConfiguration:this.configuration,errorMessage:function(m){return "Failed to get credit usage. Error: ".concat(m.message)},rethrowError:true})]}))}))},f.prototype.getCreditBalance=function(a){return a===void 0&&(a={}),de(this,void 0,void 0,(function(){var l=this;return pe(this,(function(d){return [2,vn((function(){return de(l,void 0,void 0,(function(){var m,y,b;return pe(this,(function(E){switch(E.label){case 0:return m=De(this.configuration),y=(b=this.configuration.resourceId)!==null&&b!==void 0?b:void 0,[4,this.apiGateway.credits.getCreditBalance(Hn(Hn({},a),{customerId:m,resourceId:y}))];case 1:return [2,E.sent().data.creditBalanceSummary]}}))}))}),{loggerService:this.loggerService,sdkConfiguration:this.configuration,errorMessage:function(m){return m.message},rethrowError:true})]}))}))},f.prototype.getCreditGrants=function(a){return de(this,void 0,void 0,(function(){var l=this;return pe(this,(function(d){return [2,vn((function(){return de(l,void 0,void 0,(function(){var m,y,b,E;return pe(this,(function(w){switch(w.label){case 0:return m=De(this.configuration),y=(E=this.configuration.resourceId)!==null&&E!==void 0?E:void 0,[4,this.apiGateway.credits.getCreditGrants(Hn(Hn({},a),{customerId:m,resourceId:y}))];case 1:return [2,{data:(b=w.sent()).data.creditGrants.edges.map((function(D){return D.node})),pageInfo:b.data.creditGrants.pageInfo,totalCount:b.data.creditGrants.totalCount}]}}))}))}),{loggerService:this.loggerService,sdkConfiguration:this.configuration,errorMessage:function(m){return m.message},rethrowError:true})]}))}))},f.prototype.getCreditLedger=function(a){return a===void 0&&(a={}),de(this,void 0,void 0,(function(){var l=this;return pe(this,(function(d){return [2,vn((function(){return de(l,void 0,void 0,(function(){var m,y,b;return pe(this,(function(E){switch(E.label){case 0:return m=De(this.configuration),y=(b=this.configuration.resourceId)!==null&&b!==void 0?b:void 0,[4,this.apiGateway.credits.getCreditLedger(Hn(Hn({},a),{customerId:m,resourceId:y}))];case 1:return [2,E.sent().data.creditsLedger.events]}}))}))}),{loggerService:this.loggerService,sdkConfiguration:this.configuration,errorMessage:function(m){return m.message},rethrowError:true})]}))}))},f.prototype.createPaymentSession=function(a){return de(this,void 0,void 0,(function(){var l=this;return pe(this,(function(d){return [2,vn((function(){return de(l,void 0,void 0,(function(){var m,y;return pe(this,(function(b){switch(b.label){case 0:return m=De(this.configuration),[4,this.apiGateway.checkout.createPaymentSession(Hn(Hn({},a),{customerId:m}))];case 1:if(!(y=b.sent()).data||!y.data.createPaymentSession)throw new Error("Invalid response");return [2,y.data.createPaymentSession]}}))}))}),{loggerService:this.loggerService,sdkConfiguration:this.configuration,errorMessage:function(m){return "Failed to create payment session. Error: ".concat(m.message)},rethrowError:true})]}))}))},f})(),db=(function(){var f=function(a,l){return f=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(d,m){d.__proto__=m;}||function(d,m){for(var y in m)Object.prototype.hasOwnProperty.call(m,y)&&(d[y]=m[y]);},f(a,l)};return function(a,l){if(typeof l!="function"&&l!==null)throw new TypeError("Class extends value "+String(l)+" is not a constructor or null");function d(){this.constructor=a;}f(a,l),a.prototype=l===null?Object.create(l):(d.prototype=l.prototype,new d);}})(),oo=function(){return oo=Object.assign||function(f){for(var a,l=1,d=arguments.length;l<d;l++)for(var m in a=arguments[l])Object.prototype.hasOwnProperty.call(a,m)&&(f[m]=a[m]);return f},oo.apply(this,arguments)},gn=function(f,a,l,d){return new(l||(l=Promise))((function(m,y){function b(D){try{w(d.next(D));}catch(_){y(_);}}function E(D){try{w(d.throw(D));}catch(_){y(_);}}function w(D){var _;D.done?m(D.value):(_=D.value,_ instanceof l?_:new l((function(M){M(_);}))).then(b,E);}w((d=d.apply(f,[])).next());}))},yn=function(f,a){var l,d,m,y,b={label:0,sent:function(){if(1&m[0])throw m[1];return m[1]},trys:[],ops:[]};return y={next:E(0),throw:E(1),return:E(2)},typeof Symbol=="function"&&(y[Symbol.iterator]=function(){return this}),y;function E(w){return function(D){return (function(_){if(l)throw new TypeError("Generator is already executing.");for(;b;)try{if(l=1,d&&(m=2&_[0]?d.return:_[0]?d.throw||((m=d.return)&&m.call(d),0):d.next)&&!(m=m.call(d,_[1])).done)return m;switch(d=0,m&&(_=[2&_[0],m.value]),_[0]){case 0:case 1:m=_;break;case 4:return b.label++,{value:_[1],done:!1};case 5:b.label++,d=_[1],_=[0];continue;case 7:_=b.ops.pop(),b.trys.pop();continue;default:if(!((m=(m=b.trys).length>0&&m[m.length-1])||_[0]!==6&&_[0]!==2)){b=0;continue}if(_[0]===3&&(!m||_[1]>m[0]&&_[1]<m[3])){b.label=_[1];break}if(_[0]===6&&b.label<m[1]){b.label=m[1],m=_;break}if(m&&b.label<m[2]){b.label=m[2],b.ops.push(_);break}m[2]&&b.ops.pop(),b.trys.pop();continue}_=a.call(f,b);}catch(M){_=[6,M],d=0;}finally{l=m=0;}if(5&_[0])throw _[1];return {value:_[0]?_[1]:void 0,done:true}})([w,D])}}},Ru=(function(f){function a(){return f!==null&&f.apply(this,arguments)||this}return db(a,f),a.prototype.getBooleanEntitlement=function(l){var d,m=l.featureId,y=l.options,b=(y==null?void 0:y.fallback)||((d=this.configuration.entitlementsFallback)===null||d===void 0?void 0:d[m])||{};return oo(oo({},v),b)},a.prototype.getMeteredEntitlement=function(l){var d,m=l.featureId,y=l.options,b=(y==null?void 0:y.fallback)||((d=this.configuration.entitlementsFallback)===null||d===void 0?void 0:d[m])||{};return oo(oo({},x),b)},a.prototype.getNumericEntitlement=function(l){var d,m=l.featureId,y=l.options,b=(y==null?void 0:y.fallback)||((d=this.configuration.entitlementsFallback)===null||d===void 0?void 0:d[m])||{};return oo(oo({},P),b)},a.prototype.getEnumEntitlement=function(l){var d,m=l.featureId,y=l.options,b=(y==null?void 0:y.fallback)||((d=this.configuration.entitlementsFallback)===null||d===void 0?void 0:d[m])||{};return oo(oo({},T),b)},a.prototype.getEntitlements=function(){return gn(this,void 0,void 0,(function(){return yn(this,(function(l){return [2,wp(this.configuration.entitlementsFallback)]}))}))},a.prototype.addListener=function(){},a.prototype.clearCustomer=function(){},a.prototype.clearResource=function(){},a.prototype.getActiveSubscriptionsList=function(){return gn(this,void 0,void 0,(function(){return yn(this,(function(l){return [2,[]]}))}))},a.prototype.getCoupons=function(){return gn(this,void 0,void 0,(function(){return yn(this,(function(l){return [2,[]]}))}))},a.prototype.getSubscription=function(){return gn(this,void 0,void 0,(function(){return yn(this,(function(l){return [2,{id:"mock-subscription-id",addons:[],futureUpdates:[],paymentCollection:h.QdX.NotRequired,plan:{compatibleAddons:[],compatiblePackageGroups:[],displayName:"mock-plan",entitlements:[],id:"mock-plan-id",inheritedEntitlements:[],order:0,pricePoints:[],product:{id:"mock-product-id"}},price:null,prices:[],pricingType:h._HY.Paid,startDate:new Date,status:h.yhH.Active,totalPrice:{total:{amount:0,currency:h.Fa6.Usd},subTotal:{amount:0,currency:h.Fa6.Usd}}}]}))}))},Object.defineProperty(a.prototype,"isCustomerLoaded",{get:function(){return false},enumerable:false,configurable:true}),Object.defineProperty(a.prototype,"isResourceLoaded",{get:function(){return false},enumerable:false,configurable:true}),a.prototype.removeListener=function(){},a.prototype.waitForInitialization=function(){return gn(this,void 0,void 0,(function(){return yn(this,(function(l){return [2,this]}))}))},a.prototype.setResource=function(){return gn(this,void 0,void 0,(function(){return yn(this,(function(l){return [2]}))}))},a.prototype.getCheckoutState=function(){return gn(this,void 0,void 0,(function(){return yn(this,(function(l){return [2,{setupSecret:"mock-setup-secret",resource:null,plan:{compatibleAddons:[],compatiblePackageGroups:[],displayName:"mock-plan",entitlements:[],id:"mock-plan-id",inheritedEntitlements:[],order:0,pricePoints:[],product:{id:"mock-product-id"}},customer:{createdAt:new Date,updatedAt:new Date,hasPaymentMethod:false,id:"mock-customer-id",subscriptions:[],promotionalEntitlements:[],getActivePromotionalEntitlements:function(){return []},getActiveSubscriptions:function(){return []},getActiveTrials:function(){return []}},billingIntegration:{billingIdentifier:h.ugv.Stripe,billingCredentials:{setupSecret:"mock-setup-secret",accountId:"mock-account-id",publicKey:"mock-public-key"},credentials:{accountId:"mock-account-id",publicKey:"mock-public-key"}}}]}))}))},a.prototype.applySubscription=function(){return gn(this,void 0,void 0,(function(){return yn(this,(function(l){return [2,{subscription:void 0}]}))}))},a.prototype.estimateSubscription=function(){return gn(this,void 0,void 0,(function(){return yn(this,(function(l){return [2,{billingPeriodRange:{},total:{amount:0,currency:h.Fa6.Usd},subTotal:{amount:0,currency:h.Fa6.Usd},totalExcludingTax:{amount:0,currency:h.Fa6.Usd}}]}))}))},a.prototype.previewNextInvoice=function(){return gn(this,void 0,void 0,(function(){return yn(this,(function(l){return [2,{lastUpdatedAt:new Date,amountDue:{amount:0,currency:h.Fa6.Usd},minimumSpendAdjustment:{amount:0,currency:h.Fa6.Usd},total:{amount:0,currency:h.Fa6.Usd},subTotalExcludingTax:{amount:0,currency:h.Fa6.Usd},subTotal:{amount:0,currency:h.Fa6.Usd},totalExcludingTax:{amount:0,currency:h.Fa6.Usd},tax:{amount:0,currency:h.Fa6.Usd},lines:[]}]}))}))},a.prototype.previewSubscription=function(){return gn(this,void 0,void 0,(function(){return yn(this,(function(l){return [2,{billingPeriodRange:{},immediateInvoice:{total:{amount:0,currency:h.Fa6.Usd},subTotal:{amount:0,currency:h.Fa6.Usd},totalExcludingTax:{amount:0,currency:h.Fa6.Usd}}}]}))}))},a.prototype.estimateSubscriptionUpdate=function(){return gn(this,void 0,void 0,(function(){return yn(this,(function(l){return [2,{billingPeriodRange:{},total:{amount:0,currency:h.Fa6.Usd},subTotal:{amount:0,currency:h.Fa6.Usd},totalExcludingTax:{amount:0,currency:h.Fa6.Usd}}]}))}))},a.prototype.waitForCheckoutCompleted=function(){return gn(this,void 0,void 0,(function(){return yn(this,(function(l){return [2,null]}))}))},a.prototype.refresh=function(){return gn(this,void 0,void 0,(function(){return yn(this,(function(l){return [2]}))}))},a.prototype.fetchUsageHistory=function(){return gn(this,void 0,void 0,(function(){return yn(this,(function(l){return [2,[]]}))}))},a.prototype.getUsageHistoryV2=function(){return gn(this,void 0,void 0,(function(){return yn(this,(function(l){return [2,{markers:[],series:[]}]}))}))},a.prototype.setCustomerId=function(){return gn(this,void 0,void 0,(function(){return yn(this,(function(l){return [2]}))}))},a.prototype.getPaywall=function(){return gn(this,void 0,void 0,(function(){return yn(this,(function(l){return [2,{activeSubscriptions:[],currency:{code:h.Fa6.Usd,symbol:"$"},plans:[],customer:null,resource:null}]}))}))},a.prototype.getCustomerPortal=function(){return gn(this,void 0,void 0,(function(){return yn(this,(function(l){return [2,{subscriptions:[],entitlements:[],promotionalEntitlements:[],billingInformation:{},canUpgradeSubscription:false,resource:null,showWatermark:true}]}))}))},a.prototype.getActiveSubscriptions=function(){return gn(this,void 0,void 0,(function(){return yn(this,(function(l){return [2,[]]}))}))},a.prototype.getSubscriptions=function(){return gn(this,void 0,void 0,(function(){return yn(this,(function(l){return [2,{data:[],pageInfo:{}}]}))}))},a.prototype.getCustomer=function(){return gn(this,void 0,void 0,(function(){return yn(this,(function(l){return [2,{id:"offline-customer-id",createdAt:new Date,updatedAt:new Date,subscriptions:[],promotionalEntitlements:[],metadata:{},hasPaymentMethod:false,email:"offline-customer@example.com",getActivePromotionalEntitlements:function(){return []},getActiveSubscriptions:function(){return []},getActiveTrials:function(){return []}}]}))}))},a.prototype.getCreditBalance=function(){return gn(this,void 0,void 0,(function(){return yn(this,(function(l){return [2,{__typename:"CreditBalanceSummary",customerId:"offline-customer-id",balances:[]}]}))}))},a.prototype.getCreditGrants=function(){return gn(this,void 0,void 0,(function(){return yn(this,(function(l){return [2,{data:[],pageInfo:{},totalCount:0}]}))}))},a.prototype.getCreditLedger=function(){return gn(this,void 0,void 0,(function(){return yn(this,(function(l){return [2,[]]}))}))},a.prototype.getCreditUsage=function(){return gn(this,void 0,void 0,(function(){return yn(this,(function(l){return [2,{series:[]}]}))}))},a.prototype.createPaymentSession=function(){return gn(this,void 0,void 0,(function(){return yn(this,(function(l){return [2,{__typename:"PaymentSession",token:"mock-token"}]}))}))},a.prototype.getShowWatermark=function(){return false},a})(Wh);},890:(t,e,n)=>{Object.defineProperty(e,"X$v",{value:true}),e.iKc=e.GAT=e.sEr=e.i4m=e.bWm=e.o_I=e.i3Z=e.m72=e.g3t=e.Zr9=e.jKp=e.Qj0=e.$BG=e.IZr=e.Pr8=e.FT8=e.JrM=e.XHu=e.AVk=e.Lbh=e.C2e=e.yEZ=e.Pg9=e.rpU=e.pDu=e.Fa6=e.uMJ=e.Eq9=e.bSK=e.$i2=e.K79=e.fc5=e.i2A=e.uS8=e.u4I=e.ugv=e.tvV=e.FzK=e.yTz=e.PLi=e.bM9=e.E34=e.Mbo=e.v2N=e.Ijf=e.nwm=e.dpb=e.zu7=e.zVd=e.fEx=void 0,e.yBL=e.DWP=e.eSW=e.G6j=e.tV1=e.e1Q=e._oj=e.ird=e.abb=e.lS0=e.c06=e.w1y=e.ueJ=e.PO0=e.Xm9=e.SrV=e.nM6=e.Zam=e.u0j=e.QZw=e.$Vq=e.ku9=e.JkE=e.p_C=e._HY=e.YGW=e.qXR=e.Cc7=e.LtK=e.Kf7=e.QdX=e.TVs=e.OeJ=e.jCI=e.iI3=e.zv6=e.q5V=e.PVi=e.gpE=e.pSI=e.puT=e.XY6=e.Kyg=e.isD=e.Us3=e.B8X=e.qBr=e.uMn=e.U9t=e.Tex=void 0,e.zjf=e.fYe=e.GBW=e.Ugm=e.HsO=e.hvo=e.J5K=e.zWW=e.bOA=e.kd9=e.d4U=e.T0E=e.BoX=e.RzF=e.cMT=e.N9N=e.wEB=e.Chb=e.OoB=e.FL0=e.hk_=e.Ehw=e.zdd=e.bj8=e.cTO=e._q5=e.JU=e.zOd=e.EOH=e.l9N=e.rCU=e.O0T=e.FoD=e._yy=e.Buv=e.X3h=e.Dfv=e.p13=e.bk4=e.PNd=e.UAI=e.hYU=e.wRo=e.XqI=e.yhH=e.nOi=e.YVG=e.cUf=e.o88=e.SQC=void 0,e.r6R=e.oiL=e.Pzm=e.mKD=e.lj3=e.UK7=e.CjA=e.Y92=e.YlF=e.bGH=e.yaX=e.QNm=e.qw4=e.fvX=e.r4r=e.nN6=e.FcI=e.lgL=e.wn5=e.hVT=e.$Bh=e.VeJ=e.k8_=e.weZ=e.LkV=e.Yo2=e.bEP=e.g31=e.NSU=e.mGS=e.XsQ=e._d$=e.u9g=e.Eph=e.LBz=e.X$1=e.aqW=e.qYx=e.Q_D=e.ab2=e.cG4=e.l3m=e.bII=e.cUI=e.o5f=e.JyR=e.Dxn=e.URA=e.Eam=e.DFP=void 0,e.$Av=e.N9K=e.Fd7=e.pWb=e.RXg=e.roX=e.RVX=e.Q$1=e.do1=e.hH=e.bgy=e.OpC=e.TpL=e.ZeH=e.yyj=e.$QI=e.bd6=e._He=e.KeG=e.E7k=e.Dc_=e.vQb=e.$02=e._gQ=e.m06=e.bGN=e.WJn=e.JDz=e.ZSL=e.dO5=e.K5h=e.jAf=e.yGq=e.ZD9=e.wO5=e.m5b=e.x3v=e.EQD=e.N5j=e.Bkk=e.rDA=e.GHz=e.Mal=e.Wky=e.eKV=e.$jJ=e.m76=e.q6C=e._Yx=e.xrg=void 0,e.mKo=e.AQp=e.zBW=e.LpH=e.Bve=e.zHr=e.tIq=e.$Iz=e.Cmg=e.p7R=e.K0T=e._xu=e.jPD=void 0;let r=n(5185);var i,o,s,c,p,h,v,P,x,T,I,R,A,O,N,V,G,X,nt,st,U,j,ut,Y,at,pt,dt,mt,Ct,jt,Gt,Jt,ee,re,Ee,je,sn,Ze,Pn,Gn,ln,Ke,dn,or,_e,De,vr,Ve,bt,ar,sr,Jn,lr,wi,vo,jr,Co,Ce,Vt,gt,ot,Z,it,_t,ft,Lt,It,Nt,se,ne,kn,Ae,cn,pn,Ir,cr,en,ur,$t,Vr,xn,jn,ct,si,fn,dr,kr,Ii,Wi,ki,hs,Sa,ms,Di,hn,pr,Je,vt,gs,So,Pa,qi,ae,Ue,Yr,li,Yi,xl,El,on,xa,tr,Ea,ci,Kn,Ai,er,ys,_a,zo,Cr;(Cr=e.fEx||(e.fEx={})).BudgetExceeded="BudgetExceeded",Cr.CustomerIsArchived="CustomerIsArchived",Cr.CustomerNotFound="CustomerNotFound",Cr.CustomerResourceNotFound="CustomerResourceNotFound",Cr.FeatureNotFound="FeatureNotFound",Cr.FeatureTypeMismatch="FeatureTypeMismatch",Cr.InsufficientCredits="InsufficientCredits",Cr.NoActiveSubscription="NoActiveSubscription",Cr.NoFeatureEntitlementInSubscription="NoFeatureEntitlementInSubscription",Cr.RequestedUsageExceedingLimit="RequestedUsageExceedingLimit",Cr.RequestedValuesMismatch="RequestedValuesMismatch",Cr.Revoked="Revoked",Cr.Unknown="Unknown",(zo=e.zVd||(e.zVd={})).AuthorizedDomain="AUTHORIZED_DOMAIN",zo.InviteOnly="INVITE_ONLY",zo.Sso="SSO",(_a=e.zu7||(e.zu7={})).Member="MEMBER",_a.Owner="OWNER",(ys=e.dpb||(e.dpb={})).Active="ACTIVE",ys.Blocked="BLOCKED",(er=e.nwm||(e.nwm={})).BillingId="billingId",er.CreatedAt="createdAt",er.Description="description",er.DisplayName="displayName",er.EnvironmentId="environmentId",er.Id="id",er.IsLatest="isLatest",er.PricingType="pricingType",er.ProductId="productId",er.RefId="refId",er.Status="status",er.UpdatedAt="updatedAt",er.VersionNumber="versionNumber",(Ai=e.Ijf||(e.Ijf={})).Avg="AVG",Ai.Count="COUNT",Ai.Max="MAX",Ai.Min="MIN",Ai.Sum="SUM",Ai.Unique="UNIQUE",(Kn=e.v2N||(e.v2N={})).Center="CENTER",Kn.Left="LEFT",Kn.Right="RIGHT",(e.Mbo||(e.Mbo={})).Id="id",(ci=e.E34||(e.E34={})).Client="CLIENT",ci.Salesforce="SALESFORCE",ci.Server="SERVER",ci.Workflow="WORKFLOW",(Ea=e.bM9||(e.bM9={})).Both="BOTH",Ea.Individual="INDIVIDUAL",Ea.Organization="ORGANIZATION",(tr=e.PLi||(e.PLi={})).StartOfTheMonth="START_OF_THE_MONTH",tr.SubscriptionsConsolidateBilling="SUBSCRIPTIONS_CONSOLIDATE_BILLING",tr.SubscriptionStart="SUBSCRIPTION_START",(xa=e.yTz||(e.yTz={})).OneOff="ONE_OFF",xa.Recurring="RECURRING",(on=e.FzK||(e.FzK={})).CreditBased="CREDIT_BASED",on.FlatFee="FLAT_FEE",on.MinimumSpend="MINIMUM_SPEND",on.PerUnit="PER_UNIT",on.UsageBased="USAGE_BASED",(El=e.tvV||(e.tvV={})).Annually="ANNUALLY",El.Monthly="MONTHLY",(xl=e.ugv||(e.ugv={})).Stripe="STRIPE",xl.Zuora="ZUORA",(Yi=e.u4I||(e.u4I={})).Added="ADDED",Yi.Deleted="DELETED",Yi.Modified="MODIFIED",Yi.Reordered="REORDERED",(li=e.uS8||(e.uS8={})).Equals="EQUALS",li.GreaterThan="GREATER_THAN",li.GreaterThanOrEqual="GREATER_THAN_OR_EQUAL",li.IsNotNull="IS_NOT_NULL",li.IsNull="IS_NULL",li.LessThan="LESS_THAN",li.LessThanOrEqual="LESS_THAN_OR_EQUAL",li.NotEquals="NOT_EQUALS",(Yr=e.i2A||(e.i2A={})).BillingId="billingId",Yr.CreatedAt="createdAt",Yr.Description="description",Yr.EnvironmentId="environmentId",Yr.Id="id",Yr.Name="name",Yr.RefId="refId",Yr.Source="source",Yr.Status="status",Yr.Type="type",Yr.UpdatedAt="updatedAt",(Ue=e.fc5||(e.fc5={})).Stigg="STIGG",Ue.StiggAdhoc="STIGG_ADHOC",Ue.Stripe="STRIPE",(ae=e.K79||(e.K79={})).Active="ACTIVE",ae.Archived="ARCHIVED",(qi=e.$i2||(e.$i2={})).Fixed="FIXED",qi.Percentage="PERCENTAGE",(Pa=e.bSK||(e.bSK={})).Paid="PAID",Pa.Promotional="PROMOTIONAL",(So=e.Eq9||(e.Eq9={})).CreditsConsumed="CREDITS_CONSUMED",So.CreditsExpired="CREDITS_EXPIRED",So.CreditsGranted="CREDITS_GRANTED",So.CreditsVoided="CREDITS_VOIDED",(gs=e.uMJ||(e.uMJ={})).LastDay="LAST_DAY",gs.LastMonth="LAST_MONTH",gs.LastWeek="LAST_WEEK",gs.LastYear="LAST_YEAR",(vt=e.Fa6||(e.Fa6={})).Aed="AED",vt.All="ALL",vt.Amd="AMD",vt.Ang="ANG",vt.Aud="AUD",vt.Awg="AWG",vt.Azn="AZN",vt.Bam="BAM",vt.Bbd="BBD",vt.Bdt="BDT",vt.Bgn="BGN",vt.Bif="BIF",vt.Bmd="BMD",vt.Bnd="BND",vt.Brl="BRL",vt.Bsd="BSD",vt.Bwp="BWP",vt.Byn="BYN",vt.Bzd="BZD",vt.Cad="CAD",vt.Cdf="CDF",vt.Chf="CHF",vt.Clp="CLP",vt.Cny="CNY",vt.Czk="CZK",vt.Djf="DJF",vt.Dkk="DKK",vt.Dop="DOP",vt.Dzd="DZD",vt.Egp="EGP",vt.Etb="ETB",vt.Eur="EUR",vt.Fjd="FJD",vt.Gbp="GBP",vt.Gel="GEL",vt.Gip="GIP",vt.Gmd="GMD",vt.Gnf="GNF",vt.Gyd="GYD",vt.Hkd="HKD",vt.Hrk="HRK",vt.Htg="HTG",vt.Idr="IDR",vt.Ils="ILS",vt.Inr="INR",vt.Isk="ISK",vt.Jmd="JMD",vt.Jpy="JPY",vt.Kes="KES",vt.Kgs="KGS",vt.Khr="KHR",vt.Kmf="KMF",vt.Krw="KRW",vt.Kyd="KYD",vt.Kzt="KZT",vt.Lbp="LBP",vt.Lkr="LKR",vt.Lrd="LRD",vt.Lsl="LSL",vt.Mad="MAD",vt.Mdl="MDL",vt.Mga="MGA",vt.Mkd="MKD",vt.Mmk="MMK",vt.Mnt="MNT",vt.Mop="MOP",vt.Mro="MRO",vt.Mvr="MVR",vt.Mwk="MWK",vt.Mxn="MXN",vt.Myr="MYR",vt.Mzn="MZN",vt.Nad="NAD",vt.Ngn="NGN",vt.Nok="NOK",vt.Npr="NPR",vt.Nzd="NZD",vt.Pgk="PGK",vt.Php="PHP",vt.Pkr="PKR",vt.Pln="PLN",vt.Pyg="PYG",vt.Qar="QAR",vt.Ron="RON",vt.Rsd="RSD",vt.Rub="RUB",vt.Rwf="RWF",vt.Sar="SAR",vt.Sbd="SBD",vt.Scr="SCR",vt.Sek="SEK",vt.Sgd="SGD",vt.Sle="SLE",vt.Sll="SLL",vt.Sos="SOS",vt.Szl="SZL",vt.Thb="THB",vt.Tjs="TJS",vt.Top="TOP",vt.Try="TRY",vt.Ttd="TTD",vt.Tzs="TZS",vt.Uah="UAH",vt.Ugx="UGX",vt.Usd="USD",vt.Uzs="UZS",vt.Vnd="VND",vt.Vuv="VUV",vt.Wst="WST",vt.Xaf="XAF",vt.Xcd="XCD",vt.Xof="XOF",vt.Xpf="XPF",vt.Yer="YER",vt.Zar="ZAR",vt.Zmw="ZMW",(Je=e.pDu||(e.pDu={})).CreatedAt="createdAt",Je.EnvironmentId="environmentId",Je.ResourceId="resourceId",(pr=e.rpU||(e.rpU={})).AwsMarketplaceCustomerId="awsMarketplaceCustomerId",pr.BillingId="billingId",pr.CreatedAt="createdAt",pr.CrmHubspotCompanyId="crmHubspotCompanyId",pr.CrmHubspotCompanyUrl="crmHubspotCompanyUrl",pr.CrmId="crmId",pr.CustomerId="customerId",pr.DeletedAt="deletedAt",pr.Email="email",pr.EnvironmentId="environmentId",pr.Id="id",pr.Name="name",pr.RefId="refId",pr.SalesforceId="salesforceId",pr.SearchQuery="searchQuery",pr.UpdatedAt="updatedAt",(hn=e.Pg9||(e.Pg9={})).BillingCycleAnchor="billingCycleAnchor",hn.BillingId="billingId",hn.CancelReason="cancelReason",hn.CancellationDate="cancellationDate",hn.CreatedAt="createdAt",hn.CrmId="crmId",hn.CrmLinkUrl="crmLinkUrl",hn.CurrentBillingPeriodEnd="currentBillingPeriodEnd",hn.CurrentBillingPeriodStart="currentBillingPeriodStart",hn.CustomerId="customerId",hn.EffectiveEndDate="effectiveEndDate",hn.EndDate="endDate",hn.EnvironmentId="environmentId",hn.Id="id",hn.OldBillingId="oldBillingId",hn.PayingCustomerId="payingCustomerId",hn.PaymentCollection="paymentCollection",hn.PricingType="pricingType",hn.RefId="refId",hn.ResourceId="resourceId",hn.SalesforceId="salesforceId",hn.StartDate="startDate",hn.Status="status",hn.SubscriptionId="subscriptionId",hn.TrialEndDate="trialEndDate",(Di=e.yEZ||(e.yEZ={})).CeoOrFounder="CEO_OR_FOUNDER",Di.Engineering="ENGINEERING",Di.Growth="GROWTH",Di.Marketing="MARKETING",Di.Monetization="MONETIZATION",Di.Other="OTHER",Di.Product="PRODUCT",(ms=e.C2e||(e.C2e={})).Forever="FOREVER",ms.Once="ONCE",ms.Repeating="REPEATING",(Sa=e.Lbh||(e.Lbh={})).Fixed="FIXED",Sa.Percentage="PERCENTAGE",(hs=e.AVk||(e.AVk={})).Increment="Increment",hs.Override="Override",(ki=e.XHu||(e.XHu={})).Day="DAY",ki.Hour="HOUR",ki.Month="MONTH",ki.Week="WEEK",ki.Year="YEAR",(Wi=e.JrM||(e.JrM={})).CustomerNotFound="CustomerNotFound",Wi.NoActiveSubscription="NoActiveSubscription",(Ii=e.FT8||(e.FT8={})).BlackList="BLACK_LIST",Ii.WhiteList="WHITE_LIST",(kr=e.Pr8||(e.Pr8={})).Admin="ADMIN",kr.None="NONE",kr.Support="SUPPORT",kr.Viewer="VIEWER",(dr=e.IZr||(e.IZr={})).Done="DONE",dr.Failed="FAILED",dr.InProgress="IN_PROGRESS",dr.NotProvisioned="NOT_PROVISIONED",(fn=e.$BG||(e.$BG={})).CreatedAt="createdAt",fn.DisplayName="displayName",fn.Id="id",fn.PermanentDeletionDate="permanentDeletionDate",fn.Slug="slug",(si=e.Qj0||(e.Qj0={})).Development="DEVELOPMENT",si.Production="PRODUCTION",si.Sandbox="SANDBOX",(ct=e.jKp||(e.jKp={})).AccessDeniedError="AccessDeniedError",ct.AccountNotFoundError="AccountNotFoundError",ct.AddonDependencyMissingError="AddonDependencyMissingError",ct.AddonHasToHavePriceError="AddonHasToHavePriceError",ct.AddonIsCompatibleWithGroup="AddonIsCompatibleWithGroup",ct.AddonIsCompatibleWithPlan="AddonIsCompatibleWithPlan",ct.AddonNotFound="AddonNotFound",ct.AddonQuantityExceedsLimitError="AddonQuantityExceedsLimitError",ct.AddonWithDraftCannotBeDeletedError="AddonWithDraftCannotBeDeletedError",ct.AddonsNotFound="AddonsNotFound",ct.AmountTooLarge="AmountTooLarge",ct.ArchivedCouponCantBeApplied="ArchivedCouponCantBeApplied",ct.AuthCustomerMismatch="AuthCustomerMismatch",ct.AuthCustomerReadonly="AuthCustomerReadonly",ct.AwsMarketplaceIntegrationError="AwsMarketplaceIntegrationError",ct.AwsMarketplaceIntegrationValidationError="AwsMarketplaceIntegrationValidationError",ct.BadUserInput="BadUserInput",ct.BillingIntegrationAlreadyExistsError="BillingIntegrationAlreadyExistsError",ct.BillingIntegrationMissing="BillingIntegrationMissing",ct.BillingPeriodMissingError="BillingPeriodMissingError",ct.CanNotUpdateEntitlementsFeatureGroup="CanNotUpdateEntitlementsFeatureGroup",ct.CannotAddOverrideEntitlementToPlan="CannotAddOverrideEntitlementToPlan",ct.CannotArchiveFeatureError="CannotArchiveFeatureError",ct.CannotArchiveFeatureGroupError="CannotArchiveFeatureGroupError",ct.CannotChangeBillingIntegration="CannotChangeBillingIntegration",ct.CannotDeleteCustomerError="CannotDeleteCustomerError",ct.CannotDeleteDefaultIntegration="CannotDeleteDefaultIntegration",ct.CannotDeleteFeatureError="CannotDeleteFeatureError",ct.CannotDeleteProductError="CannotDeleteProductError",ct.CannotEditPackageInNonDraftMode="CannotEditPackageInNonDraftMode",ct.CannotRemovePaymentMethodFromCustomerError="CannotRemovePaymentMethodFromCustomerError",ct.CannotReportUsageForEntitlementWithMeterError="CannotReportUsageForEntitlementWithMeterError",ct.CannotUpdateExpireAtForExpiredCreditGrantError="CannotUpdateExpireAtForExpiredCreditGrantError",ct.CannotUpdateUnitTransformationError="CannotUpdateUnitTransformationError",ct.CannotUpsertToPackageThatHasDraft="CannotUpsertToPackageThatHasDraft",ct.ChangingPayingCustomerIsNotSupportedError="ChangingPayingCustomerIsNotSupportedError",ct.CheckoutIsNotSupported="CheckoutIsNotSupported",ct.CouponNotFound="CouponNotFound",ct.CreditGrantAlreadyVoided="CreditGrantAlreadyVoided",ct.CreditGrantNotFound="CreditGrantNotFound",ct.CustomCurrencyNotFound="CustomCurrencyNotFound",ct.CustomerAlreadyHaveCustomerCoupon="CustomerAlreadyHaveCustomerCoupon",ct.CustomerAlreadyUsesCoupon="CustomerAlreadyUsesCoupon",ct.CustomerHasNoEmailAddress="CustomerHasNoEmailAddress",ct.CustomerNoBillingId="CustomerNoBillingId",ct.CustomerNotFound="CustomerNotFound",ct.CustomerResourceNotFound="CustomerResourceNotFound",ct.DeprecatedEstimateSubscriptionError="DeprecatedEstimateSubscriptionError",ct.DowngradeBillingPeriodNotSupportedError="DowngradeBillingPeriodNotSupportedError",ct.DraftAddonCantBeArchived="DraftAddonCantBeArchived",ct.DraftAlreadyExists="DraftAlreadyExists",ct.DraftPlanCantBeArchived="DraftPlanCantBeArchived",ct.DuplicateAddonProvisionedError="DuplicateAddonProvisionedError",ct.DuplicateIntegrationNotAllowed="DuplicateIntegrationNotAllowed",ct.DuplicateProductValidationError="DuplicateProductValidationError",ct.DuplicatedEntityNotAllowed="DuplicatedEntityNotAllowed",ct.EditAllowedOnDraftPackageOnlyError="EditAllowedOnDraftPackageOnlyError",ct.EntitlementBelongsToFeatureGroupError="EntitlementBelongsToFeatureGroupError",ct.EntitlementLimitExceededError="EntitlementLimitExceededError",ct.EntitlementUsageOutOfRangeError="EntitlementUsageOutOfRangeError",ct.EntitlementsMustBelongToSamePackage="EntitlementsMustBelongToSamePackage",ct.EntityIdDifferentFromRefIdError="EntityIdDifferentFromRefIdError",ct.EntityIsArchivedError="EntityIsArchivedError",ct.EnvironmentMissing="EnvironmentMissing",ct.ExperimentAlreadyRunning="ExperimentAlreadyRunning",ct.ExperimentNotFoundError="ExperimentNotFoundError",ct.ExperimentStatusError="ExperimentStatusError",ct.ExpireAtMustBeLaterThanEffectiveAtError="ExpireAtMustBeLaterThanEffectiveAtError",ct.FailedToCreateCheckoutSessionError="FailedToCreateCheckoutSessionError",ct.FailedToImportCustomer="FailedToImportCustomer",ct.FailedToImportSubscriptions="FailedToImportSubscriptions",ct.FailedToResolveBillingIntegration="FailedToResolveBillingIntegration",ct.FeatureConfigurationExceededLimitError="FeatureConfigurationExceededLimitError",ct.FeatureGroupMissingFeaturesError="FeatureGroupMissingFeaturesError",ct.FeatureGroupNotFoundError="FeatureGroupNotFoundError",ct.FeatureNotBelongToFeatureGroupError="FeatureNotBelongToFeatureGroupError",ct.FeatureNotFound="FeatureNotFound",ct.FetchAllCountriesPricesNotAllowed="FetchAllCountriesPricesNotAllowed",ct.FreePlanCantHaveCompatiblePackageGroupError="FreePlanCantHaveCompatiblePackageGroupError",ct.GraphQlAliasesLimitExceeded="GraphQLAliasesLimitExceeded",ct.GraphQlBatchedOperationsLimitExceeded="GraphQLBatchedOperationsLimitExceeded",ct.GraphQlUnsupportedDirective="GraphQLUnsupportedDirective",ct.HubspotIntegrationError="HubspotIntegrationError",ct.IdentityForbidden="IdentityForbidden",ct.ImportAlreadyInProgress="ImportAlreadyInProgress",ct.ImportSubscriptionsBulkError="ImportSubscriptionsBulkError",ct.IncompatibleSubscriptionAddon="IncompatibleSubscriptionAddon",ct.InitStripePaymentMethodError="InitStripePaymentMethodError",ct.IntegrationNotFound="IntegrationNotFound",ct.IntegrationValidationError="IntegrationValidationError",ct.IntegrityViolation="IntegrityViolation",ct.InvalidAddressError="InvalidAddressError",ct.InvalidArgumentError="InvalidArgumentError",ct.InvalidCancellationDate="InvalidCancellationDate",ct.InvalidDoggoSignatureError="InvalidDoggoSignatureError",ct.InvalidEntitlementResetPeriod="InvalidEntitlementResetPeriod",ct.InvalidMemberDelete="InvalidMemberDelete",ct.InvalidMetadataError="InvalidMetadataError",ct.InvalidQuantity="InvalidQuantity",ct.InvalidSubscriptionStatus="InvalidSubscriptionStatus",ct.InvalidUpdatePriceUnitAmountError="InvalidUpdatePriceUnitAmountError",ct.MemberInvitationError="MemberInvitationError",ct.MemberNotFound="MemberNotFound",ct.MergeEnvironmentValidationError="MergeEnvironmentValidationError",ct.MeterMustBeAssociatedToMeteredFeature="MeterMustBeAssociatedToMeteredFeature",ct.MeteringNotAvailableForFeatureType="MeteringNotAvailableForFeatureType",ct.MissingEntityIdError="MissingEntityIdError",ct.MissingSubscriptionInvoiceError="MissingSubscriptionInvoiceError",ct.MultiSubscriptionCantBeAutoCancellationSourceError="MultiSubscriptionCantBeAutoCancellationSourceError",ct.NoActiveSubscriptionForCustomer="NoActiveSubscriptionForCustomer",ct.NoDraftOfferFound="NoDraftOfferFound",ct.NoFeatureEntitlementError="NoFeatureEntitlementError",ct.NoFeatureEntitlementInSubscription="NoFeatureEntitlementInSubscription",ct.NoProductsAvailable="NoProductsAvailable",ct.OfferAlreadyExists="OfferAlreadyExists",ct.OfferNotFound="OfferNotFound",ct.OperationNotAllowedDuringInProgressExperiment="OperationNotAllowedDuringInProgressExperiment",ct.PackageAlreadyPublished="PackageAlreadyPublished",ct.PackageGroupMinItemsError="PackageGroupMinItemsError",ct.PackageGroupNotFound="PackageGroupNotFound",ct.PackagePricingTypeNotSet="PackagePricingTypeNotSet",ct.PaymentMethodNotFoundError="PaymentMethodNotFoundError",ct.PlanCannotBePublishWhenBasePlanIsDraft="PlanCannotBePublishWhenBasePlanIsDraft",ct.PlanCannotBePublishWhenCompatibleAddonIsDraft="PlanCannotBePublishWhenCompatibleAddonIsDraft",ct.PlanIsUsedAsDefaultStartPlan="PlanIsUsedAsDefaultStartPlan",ct.PlanIsUsedAsDowngradePlan="PlanIsUsedAsDowngradePlan",ct.PlanNotFound="PlanNotFound",ct.PlanWithChildCantBeDeleted="PlanWithChildCantBeDeleted",ct.PlansCircularDependencyError="PlansCircularDependencyError",ct.PreparePaymentMethodFormError="PreparePaymentMethodFormError",ct.PriceNotFound="PriceNotFound",ct.ProductNotFoundError="ProductNotFoundError",ct.PromotionCodeCustomerNotFirstPurchase="PromotionCodeCustomerNotFirstPurchase",ct.PromotionCodeMaxRedemptionsReached="PromotionCodeMaxRedemptionsReached",ct.PromotionCodeMinimumAmountNotReached="PromotionCodeMinimumAmountNotReached",ct.PromotionCodeNotActive="PromotionCodeNotActive",ct.PromotionCodeNotForCustomer="PromotionCodeNotForCustomer",ct.PromotionCodeNotFound="PromotionCodeNotFound",ct.PromotionalEntitlementNotFoundError="PromotionalEntitlementNotFoundError",ct.RateLimitExceeded="RateLimitExceeded",ct.RecalculateEntitlementsError="RecalculateEntitlementsError",ct.RequiredSsoAuthenticationError="RequiredSsoAuthenticationError",ct.ResyncAlreadyInProgress="ResyncAlreadyInProgress",ct.ScheduledMigrationAlreadyExistsError="ScheduledMigrationAlreadyExistsError",ct.SelectedBillingModelDoesntMatchImportedItemError="SelectedBillingModelDoesntMatchImportedItemError",ct.SingleSubscriptionCantBeAutoCancellationTargetError="SingleSubscriptionCantBeAutoCancellationTargetError",ct.StripeCustomerIsDeleted="StripeCustomerIsDeleted",ct.StripeError="StripeError",ct.SubscriptionAlreadyCanceledOrExpired="SubscriptionAlreadyCanceledOrExpired",ct.SubscriptionAlreadyOnLatestPlanError="SubscriptionAlreadyOnLatestPlanError",ct.SubscriptionDoesNotHaveBillingPeriod="SubscriptionDoesNotHaveBillingPeriod",ct.SubscriptionInvoiceStatusError="SubscriptionInvoiceStatusError",ct.SubscriptionMustHaveSinglePlanError="SubscriptionMustHaveSinglePlanError",ct.SubscriptionNoBillingId="SubscriptionNoBillingId",ct.SubscriptionNotFound="SubscriptionNotFound",ct.TooManyCustomCurrencies="TooManyCustomCurrencies",ct.TooManySubscriptionsPerCustomer="TooManySubscriptionsPerCustomer",ct.TrialMustBeCancelledImmediately="TrialMustBeCancelledImmediately",ct.UnPublishedPackage="UnPublishedPackage",ct.Unauthenticated="Unauthenticated",ct.UnexpectedError="UnexpectedError",ct.UnsupportedFeatureType="UnsupportedFeatureType",ct.UnsupportedParameter="UnsupportedParameter",ct.UnsupportedSubscriptionScheduleType="UnsupportedSubscriptionScheduleType",ct.UnsupportedVendorIdentifier="UnsupportedVendorIdentifier",ct.UsageMeasurementDiffOutOfRangeError="UsageMeasurementDiffOutOfRangeError",ct.VersionExceedsMaxValueError="VersionExceedsMaxValueError",ct.WorkflowTriggerNotFound="WorkflowTriggerNotFound",(jn=e.Zr9||(e.Zr9={})).AppCustomer="APP_CUSTOMER",jn.AppPublic="APP_PUBLIC",jn.AppServer="APP_SERVER",jn.Aws="AWS",jn.Import="IMPORT",jn.Migration="MIGRATION",jn.Salesforce="SALESFORCE",jn.Scheduler="SCHEDULER",jn.Service="SERVICE",jn.Stripe="STRIPE",jn.Support="SUPPORT",jn.System="SYSTEM",jn.User="USER",jn.Workflow="WORKFLOW",(xn=e.g3t||(e.g3t={})).Addon="ADDON",xn.Coupon="COUPON",xn.Credit="CREDIT",xn.Customer="CUSTOMER",xn.Entitlement="ENTITLEMENT",xn.Feature="FEATURE",xn.FeatureGroup="FEATURE_GROUP",xn.Import="IMPORT",xn.Measurement="MEASUREMENT",xn.Package="PACKAGE",xn.PackageGroup="PACKAGE_GROUP",xn.Plan="PLAN",xn.Product="PRODUCT",xn.PromotionalEntitlement="PROMOTIONAL_ENTITLEMENT",xn.Subscription="SUBSCRIPTION",(Vr=e.m72||(e.m72={})).CreatedAt="createdAt",Vr.EntityId="entityId",Vr.EnvironmentId="environmentId",Vr.EventLogType="eventLogType",Vr.Id="id",Vr.ParentEntityId="parentEntityId",($t=e.i3Z||(e.i3Z={})).AddonCreated="ADDON_CREATED",$t.AddonDeleted="ADDON_DELETED",$t.AddonUpdated="ADDON_UPDATED",$t.CouponArchived="COUPON_ARCHIVED",$t.CouponCreated="COUPON_CREATED",$t.CouponUpdated="COUPON_UPDATED",$t.CreateSubscriptionFailed="CREATE_SUBSCRIPTION_FAILED",$t.CreditsBalanceDepletedOld="CREDITS_BALANCE_DEPLETED_OLD",$t.CreditsBalanceLowOld="CREDITS_BALANCE_LOW_OLD",$t.CreditsGrantBalanceLowOld="CREDITS_GRANT_BALANCE_LOW_OLD",$t.CreditsGrantDepletedOld="CREDITS_GRANT_DEPLETED_OLD",$t.CreditsGrantExpiredOld="CREDITS_GRANT_EXPIRED_OLD",$t.CreditsGrantGrantedOld="CREDITS_GRANT_GRANTED_OLD",$t.CreditsGrantUpdatedOld="CREDITS_GRANT_UPDATED_OLD",$t.CreditBalanceDepleted="CREDIT_BALANCE_DEPLETED",$t.CreditBalanceLow="CREDIT_BALANCE_LOW",$t.CreditGrantBalanceLow="CREDIT_GRANT_BALANCE_LOW",$t.CreditGrantCreated="CREDIT_GRANT_CREATED",$t.CreditGrantDepleted="CREDIT_GRANT_DEPLETED",$t.CreditGrantExpired="CREDIT_GRANT_EXPIRED",$t.CreditGrantUpdated="CREDIT_GRANT_UPDATED",$t.CreditGrantVoided="CREDIT_GRANT_VOIDED",$t.CustomerCreated="CUSTOMER_CREATED",$t.CustomerDeleted="CUSTOMER_DELETED",$t.CustomerEntitlementCalculationTriggered="CUSTOMER_ENTITLEMENT_CALCULATION_TRIGGERED",$t.CustomerPaymentFailed="CUSTOMER_PAYMENT_FAILED",$t.CustomerResourceEntitlementCalculationTriggered="CUSTOMER_RESOURCE_ENTITLEMENT_CALCULATION_TRIGGERED",$t.CustomerUpdated="CUSTOMER_UPDATED",$t.EdgeApiClientConfigurationDataResync="EDGE_API_CLIENT_CONFIGURATION_DATA_RESYNC",$t.EdgeApiCustomerDataResync="EDGE_API_CUSTOMER_DATA_RESYNC",$t.EdgeApiDataResync="EDGE_API_DATA_RESYNC",$t.EdgeApiDoggoResync="EDGE_API_DOGGO_RESYNC",$t.EdgeApiPackageEntitlementsDataResync="EDGE_API_PACKAGE_ENTITLEMENTS_DATA_RESYNC",$t.EdgeApiSubscriptionsDataResync="EDGE_API_SUBSCRIPTIONS_DATA_RESYNC",$t.EntitlementsUpdated="ENTITLEMENTS_UPDATED",$t.EntitlementDenied="ENTITLEMENT_DENIED",$t.EntitlementGranted="ENTITLEMENT_GRANTED",$t.EntitlementRequested="ENTITLEMENT_REQUESTED",$t.EntitlementUsageExceeded="ENTITLEMENT_USAGE_EXCEEDED",$t.EnvironmentDeleted="ENVIRONMENT_DELETED",$t.FeatureArchived="FEATURE_ARCHIVED",$t.FeatureCreated="FEATURE_CREATED",$t.FeatureDeleted="FEATURE_DELETED",$t.FeatureGroupArchived="FEATURE_GROUP_ARCHIVED",$t.FeatureGroupCreated="FEATURE_GROUP_CREATED",$t.FeatureGroupUnArchived="FEATURE_GROUP_UN_ARCHIVED",$t.FeatureGroupUpdated="FEATURE_GROUP_UPDATED",$t.FeatureUpdated="FEATURE_UPDATED",$t.ImportIntegrationCatalogTriggered="IMPORT_INTEGRATION_CATALOG_TRIGGERED",$t.ImportIntegrationCustomersTriggered="IMPORT_INTEGRATION_CUSTOMERS_TRIGGERED",$t.ImportSubscriptionsBulkTriggered="IMPORT_SUBSCRIPTIONS_BULK_TRIGGERED",$t.MeasurementReported="MEASUREMENT_REPORTED",$t.PackageGroupCreated="PACKAGE_GROUP_CREATED",$t.PackageGroupUpdated="PACKAGE_GROUP_UPDATED",$t.PackagePublished="PACKAGE_PUBLISHED",$t.PlanCreated="PLAN_CREATED",$t.PlanDeleted="PLAN_DELETED",$t.PlanUpdated="PLAN_UPDATED",$t.ProductCreated="PRODUCT_CREATED",$t.ProductDeleted="PRODUCT_DELETED",$t.ProductUpdated="PRODUCT_UPDATED",$t.PromotionalEntitlementEndsSoon="PROMOTIONAL_ENTITLEMENT_ENDS_SOON",$t.PromotionalEntitlementExpired="PROMOTIONAL_ENTITLEMENT_EXPIRED",$t.PromotionalEntitlementGranted="PROMOTIONAL_ENTITLEMENT_GRANTED",$t.PromotionalEntitlementRevoked="PROMOTIONAL_ENTITLEMENT_REVOKED",$t.PromotionalEntitlementUpdated="PROMOTIONAL_ENTITLEMENT_UPDATED",$t.RecalculateEntitlementsTriggered="RECALCULATE_ENTITLEMENTS_TRIGGERED",$t.ResyncIntegrationTriggered="RESYNC_INTEGRATION_TRIGGERED",$t.SubscriptionsMigrated="SUBSCRIPTIONS_MIGRATED",$t.SubscriptionsMigrationTriggered="SUBSCRIPTIONS_MIGRATION_TRIGGERED",$t.SubscriptionBillingMonthEndsSoon="SUBSCRIPTION_BILLING_MONTH_ENDS_SOON",$t.SubscriptionCanceled="SUBSCRIPTION_CANCELED",$t.SubscriptionCreated="SUBSCRIPTION_CREATED",$t.SubscriptionExpired="SUBSCRIPTION_EXPIRED",$t.SubscriptionSpentLimitExceeded="SUBSCRIPTION_SPENT_LIMIT_EXCEEDED",$t.SubscriptionTrialConverted="SUBSCRIPTION_TRIAL_CONVERTED",$t.SubscriptionTrialEndsSoon="SUBSCRIPTION_TRIAL_ENDS_SOON",$t.SubscriptionTrialExpired="SUBSCRIPTION_TRIAL_EXPIRED",$t.SubscriptionTrialStarted="SUBSCRIPTION_TRIAL_STARTED",$t.SubscriptionUpdated="SUBSCRIPTION_UPDATED",$t.SubscriptionUsageChargeTriggered="SUBSCRIPTION_USAGE_CHARGE_TRIGGERED",$t.SubscriptionUsageUpdated="SUBSCRIPTION_USAGE_UPDATED",$t.SyncFailed="SYNC_FAILED",$t.WidgetConfigurationUpdated="WIDGET_CONFIGURATION_UPDATED",(ur=e.o_I||(e.o_I={})).CreatedAt="createdAt",ur.EnvironmentId="environmentId",ur.Id="id",ur.Name="name",ur.ProductId="productId",ur.RefId="refId",ur.Status="status",(en=e.bWm||(e.bWm={})).Completed="COMPLETED",en.Draft="DRAFT",en.InProgress="IN_PROGRESS",(cr=e.i4m||(e.i4m={})).CreatedAt="createdAt",cr.DisplayName="displayName",cr.EnvironmentId="environmentId",cr.FeatureGroupId="featureGroupId",cr.Id="id",cr.IsLatest="isLatest",cr.Status="status",cr.UpdatedAt="updatedAt",cr.VersionNumber="versionNumber",(Ir=e.sEr||(e.sEr={})).Archived="ARCHIVED",Ir.Published="PUBLISHED",(pn=e.GAT||(e.GAT={})).CreatedAt="createdAt",pn.Description="description",pn.DisplayName="displayName",pn.EnvironmentId="environmentId",pn.FeatureStatus="featureStatus",pn.FeatureType="featureType",pn.Id="id",pn.MeterType="meterType",pn.RefId="refId",pn.UpdatedAt="updatedAt",(cn=e.iKc||(e.iKc={})).Active="ACTIVE",cn.New="NEW",cn.Suspended="SUSPENDED",(Ae=e.Tex||(e.Tex={})).Boolean="BOOLEAN",Ae.Enum="ENUM",Ae.Number="NUMBER",(kn=e.U9t||(e.U9t={})).Bold="BOLD",kn.Normal="NORMAL",(ne=e.uMn||(e.uMn={})).CreatedAt="createdAt",ne.Endpoint="endpoint",ne.EnvironmentId="environmentId",ne.Id="id",ne.Status="status",(se=e.qBr||(e.qBr={})).Active="ACTIVE",se.Inactive="INACTIVE",(Nt=e.B8X||(e.B8X={})).CreatedAt="createdAt",Nt.EnvironmentId="environmentId",Nt.Id="id",Nt.Status="status",Nt.TaskType="taskType",(It=e.Us3||(e.Us3={})).CreatedAt="createdAt",It.EnvironmentId="environmentId",It.Id="id",It.VendorIdentifier="vendorIdentifier",It.VendorType="vendorType",(Lt=e.isD||(e.isD={})).AddonCharge="AddonCharge",Lt.BaseCharge="BaseCharge",Lt.InAdvanceCommitmentCharge="InAdvanceCommitmentCharge",Lt.MinimumSpendAdjustmentCharge="MinimumSpendAdjustmentCharge",Lt.MinimumSpendCharge="MinimumSpendCharge",Lt.Other="Other",Lt.OverageCharge="OverageCharge",Lt.PayAsYouGoCharge="PayAsYouGoCharge",Lt.TierCharge="TierCharge",Lt.ZeroAmountBaseCharge="ZeroAmountBaseCharge",(ft=e.Kyg||(e.Kyg={})).CreatedAt="createdAt",ft.Email="email",ft.Id="id",(_t=e.XY6||(e.XY6={})).Invited="INVITED",_t.Registered="REGISTERED",(it=e.puT||(e.puT={})).Fluctuating="Fluctuating",it.Incremental="Incremental",it.None="None",(Z=e.pSI||(e.pSI={})).StartOfTheMonth="StartOfTheMonth",Z.SubscriptionStart="SubscriptionStart",(ot=e.gpE||(e.gpE={})).CreatedAt="createdAt",ot.EnvironmentId="environmentId",ot.Id="id",ot.IsDefault="isDefault",ot.IsLatest="isLatest",ot.OfferId="offerId",ot.Status="status",ot.Version="version",(gt=e.PVi||(e.PVi={})).Archived="ARCHIVED",gt.Draft="DRAFT",gt.Published="PUBLISHED",(Vt=e.q5V||(e.q5V={})).Monthly="MONTHLY",Vt.OnSubscriptionRenewal="ON_SUBSCRIPTION_RENEWAL",(Ce=e.zv6||(e.zv6={})).BillingId="billingId",Ce.CreatedAt="createdAt",Ce.Description="description",Ce.DisplayName="displayName",Ce.EnvironmentId="environmentId",Ce.Id="id",Ce.IsLatest="isLatest",Ce.PricingType="pricingType",Ce.ProductId="productId",Ce.RefId="refId",Ce.Status="status",Ce.UpdatedAt="updatedAt",Ce.VersionNumber="versionNumber",(Co=e.iI3||(e.iI3={})).CreatedAt="createdAt",Co.EnvironmentId="environmentId",Co.Id="id",Co.PackageId="packageId",Co.UpdatedAt="updatedAt",(jr=e.jCI||(e.jCI={})).CreatedAt="createdAt",jr.DisplayName="displayName",jr.EnvironmentId="environmentId",jr.IsLatest="isLatest",jr.PackageGroupId="packageGroupId",jr.ProductId="productId",jr.Status="status",jr.UpdatedAt="updatedAt",jr.VersionNumber="versionNumber",(vo=e.OeJ||(e.OeJ={})).Archived="ARCHIVED",vo.Draft="DRAFT",vo.Published="PUBLISHED",(wi=e.TVs||(e.TVs={})).Archived="ARCHIVED",wi.Draft="DRAFT",wi.Published="PUBLISHED",(lr=e.QdX||(e.QdX={})).ActionRequired="ACTION_REQUIRED",lr.Failed="FAILED",lr.NotRequired="NOT_REQUIRED",lr.Processing="PROCESSING",(Jn=e.Kf7||(e.Kf7={})).Charge="CHARGE",Jn.Invoice="INVOICE",Jn.None="NONE",(sr=e.LtK||(e.LtK={})).Bank="BANK",sr.Card="CARD",sr.CashApp="CASH_APP",(ar=e.Cc7||(e.Cc7={})).Downgrade="DOWNGRADE",ar.None="NONE",ar.Upgrade="UPGRADE",(bt=e.qXR||(e.qXR={})).BillingId="billingId",bt.CreatedAt="createdAt",bt.Description="description",bt.DisplayName="displayName",bt.EnvironmentId="environmentId",bt.Id="id",bt.IsLatest="isLatest",bt.PricingType="pricingType",bt.ProductId="productId",bt.RefId="refId",bt.Status="status",bt.UpdatedAt="updatedAt",bt.VersionNumber="versionNumber",(Ve=e.YGW||(e.YGW={})).BillingCadence="billingCadence",Ve.BillingId="billingId",Ve.BillingModel="billingModel",Ve.BillingPeriod="billingPeriod",Ve.CreatedAt="createdAt",Ve.Id="id",Ve.TiersMode="tiersMode",(vr=e._HY||(e._HY={})).Custom="CUSTOM",vr.Free="FREE",vr.Paid="PAID",(De=e.p_C||(e.p_C={})).AwsMarketplaceProductCode="awsMarketplaceProductCode",De.AwsMarketplaceProductId="awsMarketplaceProductId",De.CreatedAt="createdAt",De.Description="description",De.DisplayName="displayName",De.EnvironmentId="environmentId",De.Id="id",De.IsDefaultProduct="isDefaultProduct",De.MultipleSubscriptions="multipleSubscriptions",De.RefId="refId",De.UpdatedAt="updatedAt",(_e=e.JkE||(e.JkE={})).Custom="CUSTOM",_e.Lifetime="LIFETIME",_e.OneMonth="ONE_MONTH",_e.OneWeek="ONE_WEEK",_e.OneYear="ONE_YEAR",_e.SixMonth="SIX_MONTH",(or=e.ku9||(e.ku9={})).CreatedAt="createdAt",or.EnvironmentId="environmentId",or.Id="id",or.Status="status",or.UpdatedAt="updatedAt",(dn=e.$Vq||(e.$Vq={})).Active="Active",dn.Expired="Expired",dn.Paused="Paused",(Ke=e.QZw||(e.QZw={})).CreateProrations="CREATE_PRORATIONS",Ke.InvoiceImmediately="INVOICE_IMMEDIATELY",(ln=e.u0j||(e.u0j={})).PaymentRequired="PAYMENT_REQUIRED",ln.Success="SUCCESS",(Gn=e.Zam||(e.Zam={})).AllCustomers="ALL_CUSTOMERS",Gn.NewCustomers="NEW_CUSTOMERS",(Pn=e.nM6||(e.nM6={})).EndOfBillingMonth="END_OF_BILLING_MONTH",Pn.EndOfBillingPeriod="END_OF_BILLING_PERIOD",Pn.Immediate="IMMEDIATE",(Ze=e.SrV||(e.SrV={})).Asc="ASC",Ze.Desc="DESC",(sn=e.Xm9||(e.Xm9={})).NullsFirst="NULLS_FIRST",sn.NullsLast="NULLS_LAST",(je=e.PO0||(e.PO0={})).JsClientSdk="JS_CLIENT_SDK",je.NodeServerSdk="NODE_SERVER_SDK",je.PersistentCacheService="PERSISTENT_CACHE_SERVICE",(Ee=e.ueJ||(e.ueJ={})).CreatedAt="createdAt",Ee.Id="id",Ee.Quantity="quantity",Ee.UpdatedAt="updatedAt",(re=e.w1y||(e.w1y={})).AutoCancellationRule="AutoCancellationRule",re.CancelledByBilling="CancelledByBilling",re.CustomerArchived="CustomerArchived",re.DetachBilling="DetachBilling",re.Expired="Expired",re.Immediate="Immediate",re.PendingPaymentExpired="PendingPaymentExpired",re.ScheduledCancellation="ScheduledCancellation",re.TrialConverted="TrialConverted",re.TrialEnded="TrialEnded",re.UpgradeOrDowngrade="UpgradeOrDowngrade",(ee=e.c06||(e.c06={})).Default="DEFAULT",ee.RevokeEntitlements="REVOKE_ENTITLEMENTS",(Jt=e.lS0||(e.lS0={})).EndOfBillingPeriod="END_OF_BILLING_PERIOD",Jt.Immediate="IMMEDIATE",Jt.SpecificDate="SPECIFIC_DATE",(Gt=e.abb||(e.abb={})).Active="ACTIVE",Gt.Expired="EXPIRED",Gt.Removed="REMOVED",(jt=e.ird||(e.ird={})).PredefinedFreePlan="PREDEFINED_FREE_PLAN",jt.PredefinedTrialPlan="PREDEFINED_TRIAL_PLAN",jt.RequestedPlan="REQUESTED_PLAN",jt.SkippedSubscriptionCreation="SKIPPED_SUBSCRIPTION_CREATION",(Ct=e._oj||(e._oj={})).CancelSubscription="CANCEL_SUBSCRIPTION",Ct.DowngradeToFree="DOWNGRADE_TO_FREE",(mt=e.e1Q||(e.e1Q={})).CreatedAt="createdAt",mt.EnvironmentId="environmentId",mt.Id="id",mt.SubscriptionId="subscriptionId",mt.UpdatedAt="updatedAt",(dt=e.tV1||(e.tV1={})).BillingCycle="BILLING_CYCLE",dt.Manual="MANUAL",dt.MinimumInvoiceAmountExceeded="MINIMUM_INVOICE_AMOUNT_EXCEEDED",dt.Other="OTHER",dt.SubscriptionCreation="SUBSCRIPTION_CREATION",dt.SubscriptionUpdate="SUBSCRIPTION_UPDATE",(pt=e.G6j||(e.G6j={})).Canceled="CANCELED",pt.Open="OPEN",pt.Paid="PAID",(at=e.eSW||(e.eSW={})).CreatedAt="createdAt",at.EnvironmentId="environmentId",at.Id="id",at.Status="status",at.TaskType="taskType",(Y=e.DWP||(e.DWP={})).EndOfBillingPeriod="END_OF_BILLING_PERIOD",Y.Immediate="IMMEDIATE",(ut=e.yBL||(e.yBL={})).BillingModel="billingModel",ut.CreatedAt="createdAt",ut.FeatureId="featureId",ut.HasSoftLimit="hasSoftLimit",ut.Id="id",ut.UpdatedAt="updatedAt",ut.UsageLimit="usageLimit",(j=e.SQC||(e.SQC={})).CreateProrations="CREATE_PRORATIONS",j.InvoiceImmediately="INVOICE_IMMEDIATELY",j.None="NONE",(U=e.o88||(e.o88={})).BillingId="billingId",U.CreatedAt="createdAt",U.CustomerId="customerId",U.EnvironmentId="environmentId",U.ProductId="productId",U.ResourceId="resourceId",U.SalesforceId="salesforceId",U.StartDate="startDate",U.Status="status",U.SubscriptionId="subscriptionId",(st=e.cUf||(e.cUf={})).Canceled="Canceled",st.Done="Done",st.Failed="Failed",st.PendingPayment="PendingPayment",st.Scheduled="Scheduled",(nt=e.YVG||(e.YVG={})).AdditionalMetaData="AdditionalMetaData",nt.Addon="Addon",nt.BillingInfoMetadata="BillingInfoMetadata",nt.BillingPeriod="BillingPeriod",nt.Coupon="Coupon",nt.Downgrade="Downgrade",nt.MigrateToLatest="MigrateToLatest",nt.Plan="Plan",nt.PriceOverride="PriceOverride",nt.UnitAmount="UnitAmount",(X=e.nOi||(e.nOi={})).FreePlan="FREE_PLAN",X.PlanSelection="PLAN_SELECTION",X.TrialPeriod="TRIAL_PERIOD",(G=e.yhH||(e.yhH={})).Active="ACTIVE",G.Canceled="CANCELED",G.Expired="EXPIRED",G.InTrial="IN_TRIAL",G.NotStarted="NOT_STARTED",G.PaymentPending="PAYMENT_PENDING",(V=e.XqI||(e.XqI={})).AlwaysReset="ALWAYS_RESET",V.BillingPeriodChange="BILLING_PERIOD_CHANGE",V.NeverReset="NEVER_RESET",(N=e.wRo||(e.wRo={})).Error="ERROR",N.NoSyncRequired="NO_SYNC_REQUIRED",N.Pending="PENDING",N.Success="SUCCESS",(O=e.hYU||(e.hYU={})).Canceled="CANCELED",O.Completed="COMPLETED",O.Failed="FAILED",O.InProgress="IN_PROGRESS",O.PartiallyFailed="PARTIALLY_FAILED",O.Pending="PENDING",(A=e.UAI||(e.UAI={})).ImportIntegrationCatalog="IMPORT_INTEGRATION_CATALOG",A.ImportIntegrationCustomers="IMPORT_INTEGRATION_CUSTOMERS",A.ImportSubscriptionsBulk="IMPORT_SUBSCRIPTIONS_BULK",A.RecalculateBatchEntitlements="RECALCULATE_BATCH_ENTITLEMENTS",A.RecalculateEntitlements="RECALCULATE_ENTITLEMENTS",A.ResyncIntegration="RESYNC_INTEGRATION",A.SubscriptionMigration="SUBSCRIPTION_MIGRATION",A.SubscriptionMigrationV2="SUBSCRIPTION_MIGRATION_V2",(R=e.PNd||(e.PNd={})).Graduated="GRADUATED",R.Volume="VOLUME",(I=e.bk4||(e.bk4={})).CancelSubscription="CANCEL_SUBSCRIPTION",I.ConvertToPaid="CONVERT_TO_PAID",(T=e.p13||(e.p13={})).Day="DAY",T.Month="MONTH",(x=e.Dfv||(e.Dfv={})).Down="DOWN",x.Up="UP",(P=e.X3h||(e.X3h={})).PeriodicReset="PERIODIC_RESET",P.SubscriptionChangeReset="SUBSCRIPTION_CHANGE_RESET",(v=e.Buv||(e.Buv={})).CreatedAt="createdAt",v.EnvironmentId="environmentId",v.Id="id",(h=e._yy||(e._yy={})).Delta="DELTA",h.Set="SET",(p=e.FoD||(e.FoD={})).Auth0="AUTH0",p.AwsMarketplace="AWS_MARKETPLACE",p.BigQuery="BIG_QUERY",p.Hubspot="HUBSPOT",p.OpenFga="OPEN_FGA",p.Salesforce="SALESFORCE",p.Snowflake="SNOWFLAKE",p.Stripe="STRIPE",p.Zuora="ZUORA",(c=e.O0T||(e.O0T={})).Auth="AUTH",c.Billing="BILLING",c.Crm="CRM",c.DataExport="DATA_EXPORT",c.Marketplace="MARKETPLACE",(s=e.rCU||(e.rCU={})).EveryFriday="EveryFriday",s.EveryMonday="EveryMonday",s.EverySaturday="EverySaturday",s.EverySunday="EverySunday",s.EveryThursday="EveryThursday",s.EveryTuesday="EveryTuesday",s.EveryWednesday="EveryWednesday",s.SubscriptionStart="SubscriptionStart",(o=e.l9N||(e.l9N={})).Checkout="CHECKOUT",o.CustomerPortal="CUSTOMER_PORTAL",o.Paywall="PAYWALL",(e.EOH||(e.EOH={})).SubscriptionStart="SubscriptionStart",(i=e.zOd||(e.zOd={})).Control="CONTROL",i.Variant="VARIANT",e.JU=r.default`
2388
2388
  fragment PageInfoFragment on PageInfo {
2389
2389
  startCursor
2390
2390
  endCursor
@@ -4667,12 +4667,12 @@ ${e.o5f}`,e.zBW=r.default`
4667
4667
  ...CreditBalanceUpdatedPayload
4668
4668
  }
4669
4669
  }
4670
- ${e.Q_D}`;let nr=(Kt,Wt,Tt)=>Kt();e.mKo=function(Kt,Wt=nr){return {ProvisionCustomer:(Tt,kt)=>Wt((xt=>Kt.request(e.q6C,Tt,Object.assign(Object.assign({},kt),xt))),"ProvisionCustomer","mutation"),ImportCustomerBulk:(Tt,kt)=>Wt((xt=>Kt.request(e.m76,Tt,Object.assign(Object.assign({},kt),xt))),"ImportCustomerBulk","mutation"),ImportCustomer:(Tt,kt)=>Wt((xt=>Kt.request(e.$jJ,Tt,Object.assign(Object.assign({},kt),xt))),"ImportCustomer","mutation"),UpdateCustomer:(Tt,kt)=>Wt((xt=>Kt.request(e.eKV,Tt,Object.assign(Object.assign({},kt),xt))),"UpdateCustomer","mutation"),DetachCustomerPaymentMethod:(Tt,kt)=>Wt((xt=>Kt.request(e.Wky,Tt,Object.assign(Object.assign({},kt),xt))),"DetachCustomerPaymentMethod","mutation"),GrantPromotionalEntitlements:(Tt,kt)=>Wt((xt=>Kt.request(e.Mal,Tt,Object.assign(Object.assign({},kt),xt))),"GrantPromotionalEntitlements","mutation"),RevokePromotionalEntitlement:(Tt,kt)=>Wt((xt=>Kt.request(e.GHz,Tt,Object.assign(Object.assign({},kt),xt))),"RevokePromotionalEntitlement","mutation"),ProvisionSubscription:(Tt,kt)=>Wt((xt=>Kt.request(e.rDA,Tt,Object.assign(Object.assign({},kt),xt))),"ProvisionSubscription","mutation"),ApplySubscription:(Tt,kt)=>Wt((xt=>Kt.request(e.Bkk,Tt,Object.assign(Object.assign({},kt),xt))),"ApplySubscription","mutation"),ImportSubscriptionsBulk:(Tt,kt)=>Wt((xt=>Kt.request(e.N5j,Tt,Object.assign(Object.assign({},kt),xt))),"ImportSubscriptionsBulk","mutation"),UpdateSubscription:(Tt,kt)=>Wt((xt=>Kt.request(e.EQD,Tt,Object.assign(Object.assign({},kt),xt))),"UpdateSubscription","mutation"),CancelSubscription:(Tt,kt)=>Wt((xt=>Kt.request(e.x3v,Tt,Object.assign(Object.assign({},kt),xt))),"CancelSubscription","mutation"),EstimateSubscription:(Tt,kt)=>Wt((xt=>Kt.request(e.m5b,Tt,Object.assign(Object.assign({},kt),xt))),"EstimateSubscription","mutation"),EstimateSubscriptionUpdate:(Tt,kt)=>Wt((xt=>Kt.request(e.wO5,Tt,Object.assign(Object.assign({},kt),xt))),"EstimateSubscriptionUpdate","mutation"),PreviewSubscription:(Tt,kt)=>Wt((xt=>Kt.request(e.ZD9,Tt,Object.assign(Object.assign({},kt),xt))),"PreviewSubscription","mutation"),PreviewNextInvoice:(Tt,kt)=>Wt((xt=>Kt.request(e.yGq,Tt,Object.assign(Object.assign({},kt),xt))),"PreviewNextInvoice","mutation"),CancelSubscriptionUpdates:(Tt,kt)=>Wt((xt=>Kt.request(e.jAf,Tt,Object.assign(Object.assign({},kt),xt))),"CancelSubscriptionUpdates","mutation"),ReportUsage:(Tt,kt)=>Wt((xt=>Kt.request(e.K5h,Tt,Object.assign(Object.assign({},kt),xt))),"ReportUsage","mutation"),ReportUsageBulk:(Tt,kt)=>Wt((xt=>Kt.request(e.dO5,Tt,Object.assign(Object.assign({},kt),xt))),"ReportUsageBulk","mutation"),ReportEvent:(Tt,kt)=>Wt((xt=>Kt.request(e.ZSL,Tt,Object.assign(Object.assign({},kt),xt))),"ReportEvent","mutation"),ReportEntitlementCheckRequested:(Tt,kt)=>Wt((xt=>Kt.request(e.JDz,Tt,Object.assign(Object.assign({},kt),xt))),"ReportEntitlementCheckRequested","mutation"),CreateSubscription:(Tt,kt)=>Wt((xt=>Kt.request(e.WJn,Tt,Object.assign(Object.assign({},kt),xt))),"CreateSubscription","mutation"),MigrateSubscriptionToLatest:(Tt,kt)=>Wt((xt=>Kt.request(e.bGN,Tt,Object.assign(Object.assign({},kt),xt))),"MigrateSubscriptionToLatest","mutation"),ArchiveCustomer:(Tt,kt)=>Wt((xt=>Kt.request(e.m06,Tt,Object.assign(Object.assign({},kt),xt))),"ArchiveCustomer","mutation"),UnarchiveCustomer:(Tt,kt)=>Wt((xt=>Kt.request(e._gQ,Tt,Object.assign(Object.assign({},kt),xt))),"UnarchiveCustomer","mutation"),TransferSubscription:(Tt,kt)=>Wt((xt=>Kt.request(e.$02,Tt,Object.assign(Object.assign({},kt),xt))),"TransferSubscription","mutation"),DelegateSubscriptionToCustomer:(Tt,kt)=>Wt((xt=>Kt.request(e.vQb,Tt,Object.assign(Object.assign({},kt),xt))),"DelegateSubscriptionToCustomer","mutation"),TransferSubscriptionToResource:(Tt,kt)=>Wt((xt=>Kt.request(e.Dc_,Tt,Object.assign(Object.assign({},kt),xt))),"TransferSubscriptionToResource","mutation"),GrantCredits:(Tt,kt)=>Wt((xt=>Kt.request(e.E7k,Tt,Object.assign(Object.assign({},kt),xt))),"GrantCredits","mutation"),GrantPromotionalEntitlementsGroup:(Tt,kt)=>Wt((xt=>Kt.request(e.KeG,Tt,Object.assign(Object.assign({},kt),xt))),"GrantPromotionalEntitlementsGroup","mutation"),RevokePromotionalEntitlementsGroup:(Tt,kt)=>Wt((xt=>Kt.request(e._He,Tt,Object.assign(Object.assign({},kt),xt))),"RevokePromotionalEntitlementsGroup","mutation"),UnlinkPromotionalEntitlementsGroup:(Tt,kt)=>Wt((xt=>Kt.request(e.bd6,Tt,Object.assign(Object.assign({},kt),xt))),"UnlinkPromotionalEntitlementsGroup","mutation"),CreatePaymentSession:(Tt,kt)=>Wt((xt=>Kt.request(e.$QI,Tt,Object.assign(Object.assign({},kt),xt))),"CreatePaymentSession","mutation"),VoidCreditGrant:(Tt,kt)=>Wt((xt=>Kt.request(e.yyj,Tt,Object.assign(Object.assign({},kt),xt))),"VoidCreditGrant","mutation"),GetCustomerById:(Tt,kt)=>Wt((xt=>Kt.request(e.ZeH,Tt,Object.assign(Object.assign({},kt),xt))),"GetCustomerById","query"),GetCustomerStatistics:(Tt,kt)=>Wt((xt=>Kt.request(e.TpL,Tt,Object.assign(Object.assign({},kt),xt))),"GetCustomerStatistics","query"),GetActiveSubscriptions:(Tt,kt)=>Wt((xt=>Kt.request(e.OpC,Tt,Object.assign(Object.assign({},kt),xt))),"GetActiveSubscriptions","query"),GetActiveSubscriptionsList:(Tt,kt)=>Wt((xt=>Kt.request(e.bgy,Tt,Object.assign(Object.assign({},kt),xt))),"GetActiveSubscriptionsList","query"),GetSubscriptions:(Tt,kt)=>Wt((xt=>Kt.request(e.hH,Tt,Object.assign(Object.assign({},kt),xt))),"GetSubscriptions","query"),GetSubscription:(Tt,kt)=>Wt((xt=>Kt.request(e.do1,Tt,Object.assign(Object.assign({},kt),xt))),"GetSubscription","query"),GetCoupons:(Tt,kt)=>Wt((xt=>Kt.request(e.Q$1,Tt,Object.assign(Object.assign({},kt),xt))),"GetCoupons","query"),GetPaywall:(Tt,kt)=>Wt((xt=>Kt.request(e.RVX,Tt,Object.assign(Object.assign({},kt),xt))),"GetPaywall","query"),GetEntitlements:(Tt,kt)=>Wt((xt=>Kt.request(e.roX,Tt,Object.assign(Object.assign({},kt),xt))),"GetEntitlements","query"),GetEntitlementsState:(Tt,kt)=>Wt((xt=>Kt.request(e.RXg,Tt,Object.assign(Object.assign({},kt),xt))),"GetEntitlementsState","query"),GetEntitlement:(Tt,kt)=>Wt((xt=>Kt.request(e.pWb,Tt,Object.assign(Object.assign({},kt),xt))),"GetEntitlement","query"),GetProducts:(Tt,kt)=>Wt((xt=>Kt.request(e.Fd7,Tt,Object.assign(Object.assign({},kt),xt))),"GetProducts","query"),GetSdkConfiguration:(Tt,kt)=>Wt((xt=>Kt.request(e.N9K,Tt,Object.assign(Object.assign({},kt),xt))),"GetSdkConfiguration","query"),GetCustomerPortalByRefId:(Tt,kt)=>Wt((xt=>Kt.request(e.$Av,Tt,Object.assign(Object.assign({},kt),xt))),"GetCustomerPortalByRefId","query"),GetCheckoutState:(Tt,kt)=>Wt((xt=>Kt.request(e.jPD,Tt,Object.assign(Object.assign({},kt),xt))),"GetCheckoutState","query"),GetMockPaywall:(Tt,kt)=>Wt((xt=>Kt.request(e._xu,Tt,Object.assign(Object.assign({},kt),xt))),"GetMockPaywall","query"),GetUsageHistory:(Tt,kt)=>Wt((xt=>Kt.request(e.K0T,Tt,Object.assign(Object.assign({},kt),xt))),"GetUsageHistory","query"),GetUsageHistoryV2:(Tt,kt)=>Wt((xt=>Kt.request(e.p7R,Tt,Object.assign(Object.assign({},kt),xt))),"GetUsageHistoryV2","query"),GetCreditBalance:(Tt,kt)=>Wt((xt=>Kt.request(e.Cmg,Tt,Object.assign(Object.assign({},kt),xt))),"GetCreditBalance","query"),GetCreditGrants:(Tt,kt)=>Wt((xt=>Kt.request(e.$Iz,Tt,Object.assign(Object.assign({},kt),xt))),"GetCreditGrants","query"),GetCreditLedger:(Tt,kt)=>Wt((xt=>Kt.request(e.tIq,Tt,Object.assign(Object.assign({},kt),xt))),"GetCreditLedger","query"),GetCreditUsage:(Tt,kt)=>Wt((xt=>Kt.request(e.zHr,Tt,Object.assign(Object.assign({},kt),xt))),"GetCreditUsage","query"),OnEntitlementsUpdated:(Tt,kt)=>Wt((xt=>Kt.request(e.Bve,Tt,Object.assign(Object.assign({},kt),xt))),"OnEntitlementsUpdated","subscription"),OnUsageUpdated:(Tt,kt)=>Wt((xt=>Kt.request(e.LpH,Tt,Object.assign(Object.assign({},kt),xt))),"OnUsageUpdated","subscription"),OnPackagePublished:(Tt,kt)=>Wt((xt=>Kt.request(e.zBW,Tt,Object.assign(Object.assign({},kt),xt))),"OnPackagePublished","subscription"),OnCreditBalanceUpdated:(Tt,kt)=>Wt((xt=>Kt.request(e.AQp,Tt,Object.assign(Object.assign({},kt),xt))),"OnCreditBalanceUpdated","subscription")}};},5821:(t,e,n)=>{n.d(e,{Z:()=>o});var r=n(5695);function i(c){return i=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(p){return typeof p}:function(p){return p&&typeof Symbol=="function"&&p.constructor===Symbol&&p!==Symbol.prototype?"symbol":typeof p},i(c)}function o(c){return s(c,[])}function s(c,p){switch(i(c)){case "string":return JSON.stringify(c);case "function":return c.name?"[function ".concat(c.name,"]"):"[function]";case "object":return c===null?"null":(function(h,v){if(v.indexOf(h)!==-1)return "[Circular]";var P=[].concat(v,[h]),x=(function(I){var F=I[String(r.Z)];return typeof F=="function"?F:typeof I.inspect=="function"?I.inspect:void 0})(h);if(x!==void 0){var T=x.call(h);if(T!==h)return typeof T=="string"?T:s(T,P)}else if(Array.isArray(h))return (function(I,F){if(I.length===0)return "[]";if(F.length>2)return "[Array]";for(var A=Math.min(10,I.length),O=I.length-A,N=[],V=0;V<A;++V)N.push(s(I[V],F));return O===1?N.push("... 1 more item"):O>1&&N.push("... ".concat(O," more items")),"["+N.join(", ")+"]"})(h,P);return (function(I,F){var A=Object.keys(I);return A.length===0?"{}":F.length>2?"["+(function(O){var N=Object.prototype.toString.call(O).replace(/^\[object /,"").replace(/]$/,"");if(N==="Object"&&typeof O.constructor=="function"){var V=O.constructor.name;if(typeof V=="string"&&V!=="")return V}return N})(I)+"]":"{ "+A.map((function(O){return O+": "+s(I[O],F)})).join(", ")+" }"})(h,P)})(c,p);default:return String(c)}}},5695:(t,e,n)=>{n.d(e,{Z:()=>r});let r=typeof Symbol=="function"&&typeof Symbol.for=="function"?Symbol.for("nodejs.util.inspect.custom"):void 0;},5217:(t,e,n)=>{n.d(e,{Ye:()=>o,WU:()=>s,UG:()=>c});var r=n(5695);function i(p){var h=p.prototype.toJSON;typeof h=="function"||(function(v,P){throw new Error("Unexpected invariant triggered.")})(),p.prototype.inspect=h,r.Z&&(p.prototype[r.Z]=h);}var o=(function(){function p(h,v,P){this.start=h.start,this.end=v.end,this.startToken=h,this.endToken=v,this.source=P;}return p.prototype.toJSON=function(){return {start:this.start,end:this.end}},p})();i(o);var s=(function(){function p(h,v,P,x,T,I,F){this.kind=h,this.start=v,this.end=P,this.line=x,this.column=T,this.value=F,this.prev=I,this.next=null;}return p.prototype.toJSON=function(){return {kind:this.kind,value:this.value,line:this.line,column:this.column}},p})();function c(p){return p!=null&&typeof p.kind=="string"}i(s);},7392:(t,e,n)=>{function r(s){var c=s.split(/\r\n|[\n\r]/g),p=(function(x){for(var T,I=true,F=true,A=0,O=null,N=0;N<x.length;++N)switch(x.charCodeAt(N)){case 13:x.charCodeAt(N+1)===10&&++N;case 10:I=false,F=true,A=0;break;case 9:case 32:++A;break;default:F&&!I&&(O===null||A<O)&&(O=A),F=false;}return (T=O)!==null&&T!==void 0?T:0})(s);if(p!==0)for(var h=1;h<c.length;h++)c[h]=c[h].slice(p);for(var v=0;v<c.length&&i(c[v]);)++v;for(var P=c.length;P>v&&i(c[P-1]);)--P;return c.slice(v,P).join(`
4670
+ ${e.Q_D}`;let nr=(Kt,Wt,Tt)=>Kt();e.mKo=function(Kt,Wt=nr){return {ProvisionCustomer:(Tt,kt)=>Wt((xt=>Kt.request(e.q6C,Tt,Object.assign(Object.assign({},kt),xt))),"ProvisionCustomer","mutation"),ImportCustomerBulk:(Tt,kt)=>Wt((xt=>Kt.request(e.m76,Tt,Object.assign(Object.assign({},kt),xt))),"ImportCustomerBulk","mutation"),ImportCustomer:(Tt,kt)=>Wt((xt=>Kt.request(e.$jJ,Tt,Object.assign(Object.assign({},kt),xt))),"ImportCustomer","mutation"),UpdateCustomer:(Tt,kt)=>Wt((xt=>Kt.request(e.eKV,Tt,Object.assign(Object.assign({},kt),xt))),"UpdateCustomer","mutation"),DetachCustomerPaymentMethod:(Tt,kt)=>Wt((xt=>Kt.request(e.Wky,Tt,Object.assign(Object.assign({},kt),xt))),"DetachCustomerPaymentMethod","mutation"),GrantPromotionalEntitlements:(Tt,kt)=>Wt((xt=>Kt.request(e.Mal,Tt,Object.assign(Object.assign({},kt),xt))),"GrantPromotionalEntitlements","mutation"),RevokePromotionalEntitlement:(Tt,kt)=>Wt((xt=>Kt.request(e.GHz,Tt,Object.assign(Object.assign({},kt),xt))),"RevokePromotionalEntitlement","mutation"),ProvisionSubscription:(Tt,kt)=>Wt((xt=>Kt.request(e.rDA,Tt,Object.assign(Object.assign({},kt),xt))),"ProvisionSubscription","mutation"),ApplySubscription:(Tt,kt)=>Wt((xt=>Kt.request(e.Bkk,Tt,Object.assign(Object.assign({},kt),xt))),"ApplySubscription","mutation"),ImportSubscriptionsBulk:(Tt,kt)=>Wt((xt=>Kt.request(e.N5j,Tt,Object.assign(Object.assign({},kt),xt))),"ImportSubscriptionsBulk","mutation"),UpdateSubscription:(Tt,kt)=>Wt((xt=>Kt.request(e.EQD,Tt,Object.assign(Object.assign({},kt),xt))),"UpdateSubscription","mutation"),CancelSubscription:(Tt,kt)=>Wt((xt=>Kt.request(e.x3v,Tt,Object.assign(Object.assign({},kt),xt))),"CancelSubscription","mutation"),EstimateSubscription:(Tt,kt)=>Wt((xt=>Kt.request(e.m5b,Tt,Object.assign(Object.assign({},kt),xt))),"EstimateSubscription","mutation"),EstimateSubscriptionUpdate:(Tt,kt)=>Wt((xt=>Kt.request(e.wO5,Tt,Object.assign(Object.assign({},kt),xt))),"EstimateSubscriptionUpdate","mutation"),PreviewSubscription:(Tt,kt)=>Wt((xt=>Kt.request(e.ZD9,Tt,Object.assign(Object.assign({},kt),xt))),"PreviewSubscription","mutation"),PreviewNextInvoice:(Tt,kt)=>Wt((xt=>Kt.request(e.yGq,Tt,Object.assign(Object.assign({},kt),xt))),"PreviewNextInvoice","mutation"),CancelSubscriptionUpdates:(Tt,kt)=>Wt((xt=>Kt.request(e.jAf,Tt,Object.assign(Object.assign({},kt),xt))),"CancelSubscriptionUpdates","mutation"),ReportUsage:(Tt,kt)=>Wt((xt=>Kt.request(e.K5h,Tt,Object.assign(Object.assign({},kt),xt))),"ReportUsage","mutation"),ReportUsageBulk:(Tt,kt)=>Wt((xt=>Kt.request(e.dO5,Tt,Object.assign(Object.assign({},kt),xt))),"ReportUsageBulk","mutation"),ReportEvent:(Tt,kt)=>Wt((xt=>Kt.request(e.ZSL,Tt,Object.assign(Object.assign({},kt),xt))),"ReportEvent","mutation"),ReportEntitlementCheckRequested:(Tt,kt)=>Wt((xt=>Kt.request(e.JDz,Tt,Object.assign(Object.assign({},kt),xt))),"ReportEntitlementCheckRequested","mutation"),CreateSubscription:(Tt,kt)=>Wt((xt=>Kt.request(e.WJn,Tt,Object.assign(Object.assign({},kt),xt))),"CreateSubscription","mutation"),MigrateSubscriptionToLatest:(Tt,kt)=>Wt((xt=>Kt.request(e.bGN,Tt,Object.assign(Object.assign({},kt),xt))),"MigrateSubscriptionToLatest","mutation"),ArchiveCustomer:(Tt,kt)=>Wt((xt=>Kt.request(e.m06,Tt,Object.assign(Object.assign({},kt),xt))),"ArchiveCustomer","mutation"),UnarchiveCustomer:(Tt,kt)=>Wt((xt=>Kt.request(e._gQ,Tt,Object.assign(Object.assign({},kt),xt))),"UnarchiveCustomer","mutation"),TransferSubscription:(Tt,kt)=>Wt((xt=>Kt.request(e.$02,Tt,Object.assign(Object.assign({},kt),xt))),"TransferSubscription","mutation"),DelegateSubscriptionToCustomer:(Tt,kt)=>Wt((xt=>Kt.request(e.vQb,Tt,Object.assign(Object.assign({},kt),xt))),"DelegateSubscriptionToCustomer","mutation"),TransferSubscriptionToResource:(Tt,kt)=>Wt((xt=>Kt.request(e.Dc_,Tt,Object.assign(Object.assign({},kt),xt))),"TransferSubscriptionToResource","mutation"),GrantCredits:(Tt,kt)=>Wt((xt=>Kt.request(e.E7k,Tt,Object.assign(Object.assign({},kt),xt))),"GrantCredits","mutation"),GrantPromotionalEntitlementsGroup:(Tt,kt)=>Wt((xt=>Kt.request(e.KeG,Tt,Object.assign(Object.assign({},kt),xt))),"GrantPromotionalEntitlementsGroup","mutation"),RevokePromotionalEntitlementsGroup:(Tt,kt)=>Wt((xt=>Kt.request(e._He,Tt,Object.assign(Object.assign({},kt),xt))),"RevokePromotionalEntitlementsGroup","mutation"),UnlinkPromotionalEntitlementsGroup:(Tt,kt)=>Wt((xt=>Kt.request(e.bd6,Tt,Object.assign(Object.assign({},kt),xt))),"UnlinkPromotionalEntitlementsGroup","mutation"),CreatePaymentSession:(Tt,kt)=>Wt((xt=>Kt.request(e.$QI,Tt,Object.assign(Object.assign({},kt),xt))),"CreatePaymentSession","mutation"),VoidCreditGrant:(Tt,kt)=>Wt((xt=>Kt.request(e.yyj,Tt,Object.assign(Object.assign({},kt),xt))),"VoidCreditGrant","mutation"),GetCustomerById:(Tt,kt)=>Wt((xt=>Kt.request(e.ZeH,Tt,Object.assign(Object.assign({},kt),xt))),"GetCustomerById","query"),GetCustomerStatistics:(Tt,kt)=>Wt((xt=>Kt.request(e.TpL,Tt,Object.assign(Object.assign({},kt),xt))),"GetCustomerStatistics","query"),GetActiveSubscriptions:(Tt,kt)=>Wt((xt=>Kt.request(e.OpC,Tt,Object.assign(Object.assign({},kt),xt))),"GetActiveSubscriptions","query"),GetActiveSubscriptionsList:(Tt,kt)=>Wt((xt=>Kt.request(e.bgy,Tt,Object.assign(Object.assign({},kt),xt))),"GetActiveSubscriptionsList","query"),GetSubscriptions:(Tt,kt)=>Wt((xt=>Kt.request(e.hH,Tt,Object.assign(Object.assign({},kt),xt))),"GetSubscriptions","query"),GetSubscription:(Tt,kt)=>Wt((xt=>Kt.request(e.do1,Tt,Object.assign(Object.assign({},kt),xt))),"GetSubscription","query"),GetCoupons:(Tt,kt)=>Wt((xt=>Kt.request(e.Q$1,Tt,Object.assign(Object.assign({},kt),xt))),"GetCoupons","query"),GetPaywall:(Tt,kt)=>Wt((xt=>Kt.request(e.RVX,Tt,Object.assign(Object.assign({},kt),xt))),"GetPaywall","query"),GetEntitlements:(Tt,kt)=>Wt((xt=>Kt.request(e.roX,Tt,Object.assign(Object.assign({},kt),xt))),"GetEntitlements","query"),GetEntitlementsState:(Tt,kt)=>Wt((xt=>Kt.request(e.RXg,Tt,Object.assign(Object.assign({},kt),xt))),"GetEntitlementsState","query"),GetEntitlement:(Tt,kt)=>Wt((xt=>Kt.request(e.pWb,Tt,Object.assign(Object.assign({},kt),xt))),"GetEntitlement","query"),GetProducts:(Tt,kt)=>Wt((xt=>Kt.request(e.Fd7,Tt,Object.assign(Object.assign({},kt),xt))),"GetProducts","query"),GetSdkConfiguration:(Tt,kt)=>Wt((xt=>Kt.request(e.N9K,Tt,Object.assign(Object.assign({},kt),xt))),"GetSdkConfiguration","query"),GetCustomerPortalByRefId:(Tt,kt)=>Wt((xt=>Kt.request(e.$Av,Tt,Object.assign(Object.assign({},kt),xt))),"GetCustomerPortalByRefId","query"),GetCheckoutState:(Tt,kt)=>Wt((xt=>Kt.request(e.jPD,Tt,Object.assign(Object.assign({},kt),xt))),"GetCheckoutState","query"),GetMockPaywall:(Tt,kt)=>Wt((xt=>Kt.request(e._xu,Tt,Object.assign(Object.assign({},kt),xt))),"GetMockPaywall","query"),GetUsageHistory:(Tt,kt)=>Wt((xt=>Kt.request(e.K0T,Tt,Object.assign(Object.assign({},kt),xt))),"GetUsageHistory","query"),GetUsageHistoryV2:(Tt,kt)=>Wt((xt=>Kt.request(e.p7R,Tt,Object.assign(Object.assign({},kt),xt))),"GetUsageHistoryV2","query"),GetCreditBalance:(Tt,kt)=>Wt((xt=>Kt.request(e.Cmg,Tt,Object.assign(Object.assign({},kt),xt))),"GetCreditBalance","query"),GetCreditGrants:(Tt,kt)=>Wt((xt=>Kt.request(e.$Iz,Tt,Object.assign(Object.assign({},kt),xt))),"GetCreditGrants","query"),GetCreditLedger:(Tt,kt)=>Wt((xt=>Kt.request(e.tIq,Tt,Object.assign(Object.assign({},kt),xt))),"GetCreditLedger","query"),GetCreditUsage:(Tt,kt)=>Wt((xt=>Kt.request(e.zHr,Tt,Object.assign(Object.assign({},kt),xt))),"GetCreditUsage","query"),OnEntitlementsUpdated:(Tt,kt)=>Wt((xt=>Kt.request(e.Bve,Tt,Object.assign(Object.assign({},kt),xt))),"OnEntitlementsUpdated","subscription"),OnUsageUpdated:(Tt,kt)=>Wt((xt=>Kt.request(e.LpH,Tt,Object.assign(Object.assign({},kt),xt))),"OnUsageUpdated","subscription"),OnPackagePublished:(Tt,kt)=>Wt((xt=>Kt.request(e.zBW,Tt,Object.assign(Object.assign({},kt),xt))),"OnPackagePublished","subscription"),OnCreditBalanceUpdated:(Tt,kt)=>Wt((xt=>Kt.request(e.AQp,Tt,Object.assign(Object.assign({},kt),xt))),"OnCreditBalanceUpdated","subscription")}};},5821:(t,e,n)=>{n.d(e,{Z:()=>o});var r=n(5695);function i(c){return i=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(p){return typeof p}:function(p){return p&&typeof Symbol=="function"&&p.constructor===Symbol&&p!==Symbol.prototype?"symbol":typeof p},i(c)}function o(c){return s(c,[])}function s(c,p){switch(i(c)){case "string":return JSON.stringify(c);case "function":return c.name?"[function ".concat(c.name,"]"):"[function]";case "object":return c===null?"null":(function(h,v){if(v.indexOf(h)!==-1)return "[Circular]";var P=[].concat(v,[h]),x=(function(I){var R=I[String(r.Z)];return typeof R=="function"?R:typeof I.inspect=="function"?I.inspect:void 0})(h);if(x!==void 0){var T=x.call(h);if(T!==h)return typeof T=="string"?T:s(T,P)}else if(Array.isArray(h))return (function(I,R){if(I.length===0)return "[]";if(R.length>2)return "[Array]";for(var A=Math.min(10,I.length),O=I.length-A,N=[],V=0;V<A;++V)N.push(s(I[V],R));return O===1?N.push("... 1 more item"):O>1&&N.push("... ".concat(O," more items")),"["+N.join(", ")+"]"})(h,P);return (function(I,R){var A=Object.keys(I);return A.length===0?"{}":R.length>2?"["+(function(O){var N=Object.prototype.toString.call(O).replace(/^\[object /,"").replace(/]$/,"");if(N==="Object"&&typeof O.constructor=="function"){var V=O.constructor.name;if(typeof V=="string"&&V!=="")return V}return N})(I)+"]":"{ "+A.map((function(O){return O+": "+s(I[O],R)})).join(", ")+" }"})(h,P)})(c,p);default:return String(c)}}},5695:(t,e,n)=>{n.d(e,{Z:()=>r});let r=typeof Symbol=="function"&&typeof Symbol.for=="function"?Symbol.for("nodejs.util.inspect.custom"):void 0;},5217:(t,e,n)=>{n.d(e,{Ye:()=>o,WU:()=>s,UG:()=>c});var r=n(5695);function i(p){var h=p.prototype.toJSON;typeof h=="function"||(function(v,P){throw new Error("Unexpected invariant triggered.")})(),p.prototype.inspect=h,r.Z&&(p.prototype[r.Z]=h);}var o=(function(){function p(h,v,P){this.start=h.start,this.end=v.end,this.startToken=h,this.endToken=v,this.source=P;}return p.prototype.toJSON=function(){return {start:this.start,end:this.end}},p})();i(o);var s=(function(){function p(h,v,P,x,T,I,R){this.kind=h,this.start=v,this.end=P,this.line=x,this.column=T,this.value=R,this.prev=I,this.next=null;}return p.prototype.toJSON=function(){return {kind:this.kind,value:this.value,line:this.line,column:this.column}},p})();function c(p){return p!=null&&typeof p.kind=="string"}i(s);},7392:(t,e,n)=>{function r(s){var c=s.split(/\r\n|[\n\r]/g),p=(function(x){for(var T,I=true,R=true,A=0,O=null,N=0;N<x.length;++N)switch(x.charCodeAt(N)){case 13:x.charCodeAt(N+1)===10&&++N;case 10:I=false,R=true,A=0;break;case 9:case 32:++A;break;default:R&&!I&&(O===null||A<O)&&(O=A),R=false;}return (T=O)!==null&&T!==void 0?T:0})(s);if(p!==0)for(var h=1;h<c.length;h++)c[h]=c[h].slice(p);for(var v=0;v<c.length&&i(c[v]);)++v;for(var P=c.length;P>v&&i(c[P-1]);)--P;return c.slice(v,P).join(`
4671
4671
  `)}function i(s){for(var c=0;c<s.length;++c)if(s[c]!==" "&&s[c]!==" ")return false;return true}function o(s){var c=arguments.length>1&&arguments[1]!==void 0?arguments[1]:"",p=arguments.length>2&&arguments[2]!==void 0&&arguments[2],h=s.indexOf(`
4672
4672
  `)===-1,v=s[0]===" "||s[0]===" ",P=s[s.length-1]==='"',x=s[s.length-1]==="\\",T=!h||P||x||p,I="";return !T||h&&v||(I+=`
4673
4673
  `+c),I+=c?s.replace(/\n/g,`
4674
4674
  `+c):s,T&&(I+=`
4675
- `),'"""'+I.replace(/"""/g,'\\"""')+'"""'}n.d(e,{W7:()=>r,LZ:()=>o});},143:(t,e,n)=>{n.d(e,{H:()=>c,T:()=>p});var r=n(9763),i=n(5821);function o(h,v){throw new Error(v)}function s(h,v){for(var P=0;P<v.length;P++){var x=v[P];x.enumerable=x.enumerable||false,x.configurable=true,"value"in x&&(x.writable=true),Object.defineProperty(h,x.key,x);}}var c=(function(){function h(x){var T=arguments.length>1&&arguments[1]!==void 0?arguments[1]:"GraphQL request",I=arguments.length>2&&arguments[2]!==void 0?arguments[2]:{line:1,column:1};typeof x=="string"||o(0,"Body must be a string. Received: ".concat((0, i.Z)(x),".")),this.body=x,this.name=T,this.locationOffset=I,this.locationOffset.line>0||o(0,"line in locationOffset is 1-indexed and must be positive."),this.locationOffset.column>0||o(0,"column in locationOffset is 1-indexed and must be positive.");}var v,P;return v=h,(P=[{key:r.YF,get:function(){return "Source"}}])&&s(v.prototype,P),h})();function p(h){return h instanceof c}},9763:(t,e,n)=>{n.d(e,{YF:()=>r});var r=typeof Symbol=="function"&&Symbol.toStringTag!=null?Symbol.toStringTag:"@@toStringTag";},4147:t=>{t.exports=JSON.parse(`{"name":"@stigg/js-client-sdk","version":"3.67.0","description":"Stigg client-side SDK for Browser","main":"dist/index.js","module":"dist/index.esm.js","typings":"dist/index.d.ts","exports":{".":{"types":"./dist/index.d.ts","import":"./dist/index.esm.js","require":"./dist/index.js"}},"repository":"https://github.com/stiggio/js-client-sdk.git","license":"MIT","scripts":{"start":"webpack serve","build:types":"tsc --emitDeclarationOnly","build":"yarn build:types && webpack","build:watch":"webpack --watch","build:prod":"yarn build:types && webpack --env production","fix":"run-s fix:*","fix:prettier":"prettier \\"src/**/*.ts\\" --write","fix:lint":"eslint src --ext .ts --fix","pretty-quick":"pretty-quick --staged --pattern '**/*.*(js|jsx|ts|tsx)'","test":"jest --silent","test:watch":"jest --watch","test:cov":"jest --coverage","prepare":"husky install","docs":"typedoc"},"files":["dist/**/*"],"dependencies":{"@apollo/client":"^3.4.17","@sentry/browser":"^7.11.1","@stigg/api-client-js":"3.123.0","cross-fetch":"^3.1.6","dayjs":"^1.11.13","fetch-retry":"^5.0.6","husky":"^7.0.4","lodash":"^4.17.21","tiny-typed-emitter":"^2.1.0"},"devDependencies":{"@commitlint/cli":"^14.1.0","@commitlint/config-conventional":"^14.1.0","@mswjs/interceptors":"^0.19.2","@types/jest":"^27.0.2","@types/lodash":"^4.14.177","@typescript-eslint/eslint-plugin":"^5.4.0","@typescript-eslint/parser":"^5.4.0","eslint":"^8.2.0","eslint-config-prettier":"^8.3.0","eslint-plugin-prettier":"^4.0.0","jest":"^27.3.1","jest-fetch-mock":"^3.0.3","lint-staged":"^12.0.2","msw":"^0.35.0","npm-run-all":"^4.1.5","prettier":"^2.4.1","pretty-quick":"^3.1.3","ts-jest":"^27.0.7","ts-loader":"^9.2.6","typedoc":"^0.22.13","typedoc-plugin-rename-defaults":"^0.4.0","typescript":"^4.5.3","webpack":"^5.64.1","webpack-cli":"^4.9.1","webpack-dev-server":"^4.5.0"},"publishConfig":{"access":"public"},"lint-staged":{"*.{js,jsx,ts,tsx}":["prettier --check","eslint --cache"]}}`);}},J1={};function ao(t){var e=J1[t];if(e!==void 0)return e.exports;var n=J1[t]={id:t,loaded:false,exports:{}};return Qk[t].call(n.exports,n,n.exports,ao),n.loaded=true,n.exports}ao.n=t=>{var e=t&&t.__esModule?()=>t.default:()=>t;return ao.d(e,{a:e}),e},ao.d=(t,e)=>{for(var n in e)ao.o(e,n)&&!ao.o(t,n)&&Object.defineProperty(t,n,{enumerable:true,get:e[n]});},ao.g=(function(){if(typeof globalThis=="object")return globalThis;try{return this||new Function("return this")()}catch(t){if(typeof window=="object")return window}})(),ao.hmd=t=>((t=Object.create(t)).children||(t.children=[]),Object.defineProperty(t,"exports",{enumerable:true,set:()=>{throw new Error("ES Modules may not assign module.exports or exports.*, Use ESM export syntax, instead: "+t.id)}}),t),ao.o=(t,e)=>Object.prototype.hasOwnProperty.call(t,e),ao.r=t=>{typeof Symbol!="undefined"&&Symbol.toStringTag&&Object.defineProperty(t,Symbol.toStringTag,{value:"Module"}),Object.defineProperty(t,"__esModule",{value:true});},ao.nmd=t=>(t.paths=[],t.children||(t.children=[]),t);var z=ao(5078),I$=z.fEx,k$=z.zVd,D$=z.zu7,A$=z.dpb,O$=z.T0E,R$=z.d4U,F$=z.nwm,M$=z.Ijf,Jh=z.v2N,N$=z.Mbo,L$=z.E34,B$=z.Bkk,U$=z.Y92,$$=z.m06,G$=z.bM9,tC=z.sZY,j$=z.PLi,V$=z.yTz,nn=z.FzK,be=z.tvV,Dp=z.ugv,z$=z.x3v,H$=z.jAf,W$=z.u4I,q$=z.bEP,Y$=z.weZ,Q$=z.uS8,K$=z.zdd,X$=z.i2A,Z$=z.fc5,J$=z.K79,tG=z.$i2,eG=z.$QI,nG=z.WJn,rG=z.Pzm,iG=z.Q_D,oG=z.lj3,hb=z.bSK,aG=z.Eq9,sG=z.mKD,lG=z._Yx,yi=z.uMJ,cG=z.oiL,Fu=z.Fa6,uG=z.hk_,dG=z.vjn,pG=z._d$,fG=z.NSU,hG=z.Eph,mG=z.g31,gG=z.u9g,yG=z.aqW,bG=z.LBz,vG=z.qYx,CG=z.X$1,SG=z.OoB,PG=z.pDu,xG=z.rpU,EG=z.fYe,_G=z.Pg9,TG=z.GBW,wG=z.vQb,IG=z.yEZ,kG=z.Wky,tm=z.C2e,mb=z.Lbh,eC=z.RCf,DG=z.AVk,AG=z.cUI,Ro=z.XHu,OG=z.cG4,RG=z.JrM,FG=z.bII,MG=z.FT8,NG=z.Pr8,LG=z.IZr,BG=z.$BG,UG=z.Qj0,$G=z.jKp,GG=z.m5b,jG=z.wO5,VG=z.Zr9,zG=z.g3t,HG=z.m72,WG=z.i3Z,qG=z.zOd,YG=z.o_I,QG=z.bWm,KG=z.o5f,XG=z.i4m,ZG=z.sEr,JG=z.GAT,tj=z.iKc,ej=z.Tex,nj=z.XsQ,gb=z.U9t,rj=z.OpC,ij=z.bgy,oj=z.jPD,aj=z.Q$1,sj=z.Cmg,lj=z.$Iz,cj=z.tIq,uj=z.zHr,dj=z.ZeH,pj=z.$Av,fj=z.TpL,hj=z.pWb,mj=z.roX,gj=z.RXg,yj=z._xu,bj=z.RVX,vj=z.Fd7,Cj=z.N9K,Sj=z.do1,Pj=z.hH,xj=z.K0T,Ej=z.p7R,_j=z.E7k,Tj=z.Mal,wj=z.KeG,Ij=z.uMn,kj=z.qBr,Dj=z.DFP,Aj=z.m76,Oj=z.$jJ,Rj=z.B8X,Fj=z.N5j,Mj=z.Us3,Nj=z.isD,Lj=z.nN6,Bj=z.ini,nC=z.VsH,Uj=z.Kyg,$j=z.XY6,yb=z.puT,Gj=z.bGN,jj=z.$Bh,Vj=z.hVT,zj=z.k8_,Hj=z.wn5,Wj=z.lgL,qj=z.VeJ,Yj=z.pSI,rC=z.ctk,Qj=z.gpE,Kj=z.PVi,Xj=z.opi,Zj=z.AQp,Jj=z.Bve,tV=z.zBW,eV=z.LpH,nV=z.q5V,rV=z.BoX,iV=z.zv6,oV=z.RzF,aV=z.iI3,sV=z.jCI,lV=z.OeJ,cV=z.ab2,uV=z.TVs,dV=z.JU,em=z.QdX,pV=z.Kf7,fV=z.LtK,hV=z.r6R,mV=z.fvX,gV=z.r4r,yV=z.FcI,bV=z.qw4,vV=z.Cc7,CV=z.kd9,SV=z.bOA,PV=z.qXR,xV=z.yGq,EV=z.ZD9,_V=z.wEB,TV=z.YGW,wV=z.Chb,Rn=z._HY,IV=z.cMT,kV=z.p_C,DV=z.Ehw,AV=z.JkE,OV=z.ku9,RV=z.$Vq,FV=z.QZw,MV=z.q6C,NV=z.YlF,LV=z.rDA,BV=z.CjA,UV=z.u0j,$V=z.Zam,GV=z.JDz,jV=z.ZSL,VV=z.dO5,zV=z.K5h,HV=z.UK7,WV=z.JyR,qV=z.GHz,YV=z._He,QV=z.nM6,KV=z.zWW,XV=z.xrg,ZV=z.bj8,JV=z.bGH,tz=z.cTO,ez=z.SrV,nz=z.Xm9,rz=z.PO0,iz=z.Yo2,oz=z.ueJ,az=z.w1y,sz=z.c06,lz=z.lS0,cz=z.abb,uz=z.ird,dz=z._oj,pz=z.e1Q,fz=z.Ugm,hz=z.hvo,mz=z.tV1,gz=z.FL0,yz=z.Dxn,bz=z.G6j,vz=z.eSW,Cz=z.DWP,Sz=z.zjf,Pz=z.Eam,xz=z.URA,Ez=z.yBL,_z=z.SQC,Tz=z._q5,wz=z.o88,Iz=z.cUf,Ui=z.YVG,kz=z.J5K,Dz=z.nOi,bi=z.yhH,Az=z.HsO,Oz=z.XqI,Rz=z.wRo,Fz=z.hYU,Mz=z.UAI,ic=z.PNd,Nz=z.N9N,Lz=z.$02,Bz=z.Dc_,Uz=z.bk4,$z=z.p13,Gz=z.mGS,jz=z._gQ,Vz=z.Dfv,zz=z.bd6,Hz=z.eKV,Wz=z.EQD,qz=z.QNm,Yz=z.yaX,Qz=z.X3h,Kz=z.Buv,Xz=z._yy,Zz=z.l3m,Jz=z.FoD,tH=z.O0T,eH=z.yyj,nH=z.rCU,Mu=z.l9N,rH=z.EOH,iH=z.LkV,oH=z.X$v,bb=z.ZPm,aH=z.mKo;var oC={shouldForwardProp:t=>!t.startsWith("$")},aC=t=>iC__default.default(t,oC),Kk=["div","span","button","input","form","p","h1","h2","h3","h4","h5","h6","a","img","ul","ol","li","table","thead","tbody","tr","td","th"];Kk.forEach(t=>{aC[t]=iC__default.default(t,oC);});var Q=aC;function nm(t,e,n){let r=n?` ${n}`:"";return (!t||t===1)&&e?`Up to ${e}${r}`:t&&t>1&&e?`${t}-${e}${r}`:t&&t>1?`Minimum ${t}${r}`:""}function Ya(t){return t==null?void 0:t.toLocaleString("en-US",{maximumFractionDigits:0})}function Jk(t,e){let n=t.stigg.palette;switch(e){case "white":return "white";case "primary.main":return n.primary;case "primary.main.light":return n.primaryLight;case "warning":return n.warning;case "error":return n.error;default:return n.text[e]||n.text.primary}}function vb(t,e="body1"){let n=t.stigg.typography,r={h1:n.h1,h3:n.h2,h6:n.h3,body1:n.body,caption:n.caption};return r[e]||r.body1}var tD=Q.div`
4675
+ `),'"""'+I.replace(/"""/g,'\\"""')+'"""'}n.d(e,{W7:()=>r,LZ:()=>o});},143:(t,e,n)=>{n.d(e,{H:()=>c,T:()=>p});var r=n(9763),i=n(5821);function o(h,v){throw new Error(v)}function s(h,v){for(var P=0;P<v.length;P++){var x=v[P];x.enumerable=x.enumerable||false,x.configurable=true,"value"in x&&(x.writable=true),Object.defineProperty(h,x.key,x);}}var c=(function(){function h(x){var T=arguments.length>1&&arguments[1]!==void 0?arguments[1]:"GraphQL request",I=arguments.length>2&&arguments[2]!==void 0?arguments[2]:{line:1,column:1};typeof x=="string"||o(0,"Body must be a string. Received: ".concat((0, i.Z)(x),".")),this.body=x,this.name=T,this.locationOffset=I,this.locationOffset.line>0||o(0,"line in locationOffset is 1-indexed and must be positive."),this.locationOffset.column>0||o(0,"column in locationOffset is 1-indexed and must be positive.");}var v,P;return v=h,(P=[{key:r.YF,get:function(){return "Source"}}])&&s(v.prototype,P),h})();function p(h){return h instanceof c}},9763:(t,e,n)=>{n.d(e,{YF:()=>r});var r=typeof Symbol=="function"&&Symbol.toStringTag!=null?Symbol.toStringTag:"@@toStringTag";},4147:t=>{t.exports=JSON.parse(`{"name":"@stigg/js-client-sdk","version":"3.68.0","description":"Stigg client-side SDK for Browser","main":"dist/index.js","module":"dist/index.esm.js","typings":"dist/index.d.ts","exports":{".":{"types":"./dist/index.d.ts","import":"./dist/index.esm.js","require":"./dist/index.js"}},"repository":"https://github.com/stiggio/js-client-sdk.git","license":"MIT","scripts":{"start":"webpack serve","build:types":"tsc --emitDeclarationOnly","build":"yarn build:types && webpack","build:watch":"webpack --watch","build:prod":"yarn build:types && webpack --env production","link-sdk":"yarn build && yarn link","fix":"run-s fix:*","fix:prettier":"prettier \\"src/**/*.ts\\" --write","fix:lint":"eslint src --ext .ts --fix","pretty-quick":"pretty-quick --staged --pattern '**/*.*(js|jsx|ts|tsx)'","test":"jest --silent","test:watch":"jest --watch","test:cov":"jest --coverage","prepare":"husky install","docs":"typedoc"},"files":["dist/**/*"],"dependencies":{"@apollo/client":"^3.4.17","@sentry/browser":"^7.11.1","@stigg/api-client-js":"3.123.0","cross-fetch":"^3.1.6","dayjs":"^1.11.13","fetch-retry":"^5.0.6","husky":"^7.0.4","lodash":"^4.17.21","tiny-typed-emitter":"^2.1.0"},"devDependencies":{"@commitlint/cli":"^14.1.0","@commitlint/config-conventional":"^14.1.0","@mswjs/interceptors":"^0.19.2","@types/jest":"^27.0.2","@types/lodash":"^4.14.177","@typescript-eslint/eslint-plugin":"^5.4.0","@typescript-eslint/parser":"^5.4.0","eslint":"^8.2.0","eslint-config-prettier":"^8.3.0","eslint-plugin-prettier":"^4.0.0","jest":"^27.3.1","jest-fetch-mock":"^3.0.3","lint-staged":"^12.0.2","msw":"^0.35.0","npm-run-all":"^4.1.5","prettier":"^2.4.1","pretty-quick":"^3.1.3","ts-jest":"^27.0.7","ts-loader":"^9.2.6","typedoc":"^0.22.13","typedoc-plugin-rename-defaults":"^0.4.0","typescript":"^4.5.3","webpack":"^5.64.1","webpack-cli":"^4.9.1","webpack-dev-server":"^4.5.0"},"publishConfig":{"access":"public"},"lint-staged":{"*.{js,jsx,ts,tsx}":["prettier --check","eslint --cache"]}}`);}},J1={};function ao(t){var e=J1[t];if(e!==void 0)return e.exports;var n=J1[t]={id:t,loaded:false,exports:{}};return Qk[t].call(n.exports,n,n.exports,ao),n.loaded=true,n.exports}ao.n=t=>{var e=t&&t.__esModule?()=>t.default:()=>t;return ao.d(e,{a:e}),e},ao.d=(t,e)=>{for(var n in e)ao.o(e,n)&&!ao.o(t,n)&&Object.defineProperty(t,n,{enumerable:true,get:e[n]});},ao.g=(function(){if(typeof globalThis=="object")return globalThis;try{return this||new Function("return this")()}catch(t){if(typeof window=="object")return window}})(),ao.hmd=t=>((t=Object.create(t)).children||(t.children=[]),Object.defineProperty(t,"exports",{enumerable:true,set:()=>{throw new Error("ES Modules may not assign module.exports or exports.*, Use ESM export syntax, instead: "+t.id)}}),t),ao.o=(t,e)=>Object.prototype.hasOwnProperty.call(t,e),ao.r=t=>{typeof Symbol!="undefined"&&Symbol.toStringTag&&Object.defineProperty(t,Symbol.toStringTag,{value:"Module"}),Object.defineProperty(t,"__esModule",{value:true});},ao.nmd=t=>(t.paths=[],t.children||(t.children=[]),t);var z=ao(5078),I$=z.fEx,k$=z.zVd,D$=z.zu7,A$=z.dpb,O$=z.T0E,R$=z.d4U,F$=z.nwm,M$=z.Ijf,Jh=z.v2N,N$=z.Mbo,L$=z.E34,B$=z.Bkk,U$=z.Y92,$$=z.m06,G$=z.bM9,tC=z.sZY,j$=z.PLi,V$=z.yTz,nn=z.FzK,be=z.tvV,Dp=z.ugv,z$=z.x3v,H$=z.jAf,W$=z.u4I,q$=z.bEP,Y$=z.weZ,Q$=z.uS8,K$=z.zdd,X$=z.i2A,Z$=z.fc5,J$=z.K79,tG=z.$i2,eG=z.$QI,nG=z.WJn,rG=z.Pzm,iG=z.Q_D,oG=z.lj3,hb=z.bSK,aG=z.Eq9,sG=z.mKD,lG=z._Yx,yi=z.uMJ,cG=z.oiL,Fu=z.Fa6,uG=z.hk_,dG=z.vjn,pG=z._d$,fG=z.NSU,hG=z.Eph,mG=z.g31,gG=z.u9g,yG=z.aqW,bG=z.LBz,vG=z.qYx,CG=z.X$1,SG=z.OoB,PG=z.pDu,xG=z.rpU,EG=z.fYe,_G=z.Pg9,TG=z.GBW,wG=z.vQb,IG=z.yEZ,kG=z.Wky,tm=z.C2e,mb=z.Lbh,eC=z.RCf,DG=z.AVk,AG=z.cUI,Ro=z.XHu,OG=z.cG4,RG=z.JrM,FG=z.bII,MG=z.FT8,NG=z.Pr8,LG=z.IZr,BG=z.$BG,UG=z.Qj0,$G=z.jKp,GG=z.m5b,jG=z.wO5,VG=z.Zr9,zG=z.g3t,HG=z.m72,WG=z.i3Z,qG=z.zOd,YG=z.o_I,QG=z.bWm,KG=z.o5f,XG=z.i4m,ZG=z.sEr,JG=z.GAT,tj=z.iKc,ej=z.Tex,nj=z.XsQ,gb=z.U9t,rj=z.OpC,ij=z.bgy,oj=z.jPD,aj=z.Q$1,sj=z.Cmg,lj=z.$Iz,cj=z.tIq,uj=z.zHr,dj=z.ZeH,pj=z.$Av,fj=z.TpL,hj=z.pWb,mj=z.roX,gj=z.RXg,yj=z._xu,bj=z.RVX,vj=z.Fd7,Cj=z.N9K,Sj=z.do1,Pj=z.hH,xj=z.K0T,Ej=z.p7R,_j=z.E7k,Tj=z.Mal,wj=z.KeG,Ij=z.uMn,kj=z.qBr,Dj=z.DFP,Aj=z.m76,Oj=z.$jJ,Rj=z.B8X,Fj=z.N5j,Mj=z.Us3,Nj=z.isD,Lj=z.nN6,Bj=z.ini,nC=z.VsH,Uj=z.Kyg,$j=z.XY6,yb=z.puT,Gj=z.bGN,jj=z.$Bh,Vj=z.hVT,zj=z.k8_,Hj=z.wn5,Wj=z.lgL,qj=z.VeJ,Yj=z.pSI,rC=z.ctk,Qj=z.gpE,Kj=z.PVi,Xj=z.opi,Zj=z.AQp,Jj=z.Bve,tV=z.zBW,eV=z.LpH,nV=z.q5V,rV=z.BoX,iV=z.zv6,oV=z.RzF,aV=z.iI3,sV=z.jCI,lV=z.OeJ,cV=z.ab2,uV=z.TVs,dV=z.JU,em=z.QdX,pV=z.Kf7,fV=z.LtK,hV=z.r6R,mV=z.fvX,gV=z.r4r,yV=z.FcI,bV=z.qw4,vV=z.Cc7,CV=z.kd9,SV=z.bOA,PV=z.qXR,xV=z.yGq,EV=z.ZD9,_V=z.wEB,TV=z.YGW,wV=z.Chb,Rn=z._HY,IV=z.cMT,kV=z.p_C,DV=z.Ehw,AV=z.JkE,OV=z.ku9,RV=z.$Vq,FV=z.QZw,MV=z.q6C,NV=z.YlF,LV=z.rDA,BV=z.CjA,UV=z.u0j,$V=z.Zam,GV=z.JDz,jV=z.ZSL,VV=z.dO5,zV=z.K5h,HV=z.UK7,WV=z.JyR,qV=z.GHz,YV=z._He,QV=z.nM6,KV=z.zWW,XV=z.xrg,ZV=z.bj8,JV=z.bGH,tz=z.cTO,ez=z.SrV,nz=z.Xm9,rz=z.PO0,iz=z.Yo2,oz=z.ueJ,az=z.w1y,sz=z.c06,lz=z.lS0,cz=z.abb,uz=z.ird,dz=z._oj,pz=z.e1Q,fz=z.Ugm,hz=z.hvo,mz=z.tV1,gz=z.FL0,yz=z.Dxn,bz=z.G6j,vz=z.eSW,Cz=z.DWP,Sz=z.zjf,Pz=z.Eam,xz=z.URA,Ez=z.yBL,_z=z.SQC,Tz=z._q5,wz=z.o88,Iz=z.cUf,Ui=z.YVG,kz=z.J5K,Dz=z.nOi,bi=z.yhH,Az=z.HsO,Oz=z.XqI,Rz=z.wRo,Fz=z.hYU,Mz=z.UAI,ic=z.PNd,Nz=z.N9N,Lz=z.$02,Bz=z.Dc_,Uz=z.bk4,$z=z.p13,Gz=z.mGS,jz=z._gQ,Vz=z.Dfv,zz=z.bd6,Hz=z.eKV,Wz=z.EQD,qz=z.QNm,Yz=z.yaX,Qz=z.X3h,Kz=z.Buv,Xz=z._yy,Zz=z.l3m,Jz=z.FoD,tH=z.O0T,eH=z.yyj,nH=z.rCU,Mu=z.l9N,rH=z.EOH,iH=z.LkV,oH=z.X$v,bb=z.ZPm,aH=z.mKo;var oC={shouldForwardProp:t=>!t.startsWith("$")},aC=t=>iC__default.default(t,oC),Kk=["div","span","button","input","form","p","h1","h2","h3","h4","h5","h6","a","img","ul","ol","li","table","thead","tbody","tr","td","th"];Kk.forEach(t=>{aC[t]=iC__default.default(t,oC);});var Q=aC;function nm(t,e,n){let r=n?` ${n}`:"";return (!t||t===1)&&e?`Up to ${e}${r}`:t&&t>1&&e?`${t}-${e}${r}`:t&&t>1?`Minimum ${t}${r}`:""}function Ya(t){return t==null?void 0:t.toLocaleString("en-US",{maximumFractionDigits:0})}function Jk(t,e){let n=t.stigg.palette;switch(e){case "white":return "white";case "primary.main":return n.primary;case "primary.main.light":return n.primaryLight;case "warning":return n.warning;case "error":return n.error;default:return n.text[e]||n.text.primary}}function vb(t,e="body1"){let n=t.stigg.typography,r={h1:n.h1,h3:n.h2,h6:n.h3,body1:n.body,caption:n.caption};return r[e]||r.body1}var tD=Q.div`
4676
4676
  margin: 0;
4677
4677
  ${({$isInline:t})=>t&&"display: inline"};
4678
4678
 
@@ -4682,7 +4682,7 @@ ${e.o5f}`,e.zBW=r.default`
4682
4682
  font-weight: ${({$bold:t,theme:e,$variant:n})=>t?"bold":vb(e,n).fontWeight};
4683
4683
  font-size: ${({theme:t,$variant:e})=>vb(t,e).fontSize};
4684
4684
  ${({$lineHeight:t})=>t&&`line-height: ${t};`}
4685
- `,rt=Uv.forwardRef((t,e)=>{let A=t,{children:n,style:r,variant:i="body1",color:o="primary",overrideColor:s,bold:c=false,as:p,className:h,lineHeight:v}=A,P=On(A,["children","style","variant","color","overrideColor","bold","as","className","lineHeight"]),x=react.useTheme(),T=vb(x,i),I=p||T.semanticElement,F=s||Jk(x,o);return jsxRuntime.jsx(tD,St(W({as:I,ref:e},P),{className:h,style:r,$variant:i,$bold:c,$color:F,$lineHeight:v,$isInline:I==="span",children:n}))});rt.displayName="Typography";var rm=(t,e)=>{switch(t){case "primary":return e.stigg.palette.text.primary;case "secondary":return e.stigg.palette.text.secondary;default:return t}};var Eb={};K1(Eb,{Add:()=>jC,Addons:()=>lC,ArrowForward:()=>FC,BillingInfoCustomer:()=>uC,Check:()=>LC,Close:()=>NC,ContactSupport:()=>pC,Coupon:()=>$C,CreditCard:()=>hC,DollarCoin:()=>gC,EntitlementCheck:()=>WC,MiniSchedule:()=>im,OutlinedCheckedCircle:()=>AC,OutlinedCheckedCircleDisabled:()=>OC,OutlinedCircle:()=>DC,PayAsYouGoCharge:()=>UC,PaymentMethod:()=>IC,Promotions:()=>vC,Remove:()=>zC,RenewSubscription:()=>_C,Restore:()=>om,ScheduleBox:()=>SC,ScheduleClock:()=>xC,Trash:()=>TC});var nD=t=>jsxRuntime.jsxs("svg",St(W({width:24,height:24,viewBox:"0 0 24 24",fill:"none",xmlns:"http://www.w3.org/2000/svg"},t),{children:[jsxRuntime.jsxs("g",{clipPath:"url(#clip0_834_118930)",children:[jsxRuntime.jsx("path",{d:"M12 6.85712V17.1428",stroke:"#7586B0",strokeWidth:1.71429,strokeLinecap:"round",strokeLinejoin:"round"}),jsxRuntime.jsx("path",{d:"M6.85712 12H17.1428",stroke:"#7586B0",strokeWidth:1.71429,strokeLinecap:"round",strokeLinejoin:"round"}),jsxRuntime.jsx("path",{d:"M18 0.857117H5.99997C3.15966 0.857117 0.857117 3.15966 0.857117 5.99997V18C0.857117 20.8404 3.15966 23.1428 5.99997 23.1428H18C20.8404 23.1428 23.1428 20.8404 23.1428 18V5.99997C23.1428 3.15966 20.8404 0.857117 18 0.857117Z",stroke:"#7586B0",strokeWidth:1.71429,strokeLinecap:"round",strokeLinejoin:"round"})]}),jsxRuntime.jsx("defs",{children:jsxRuntime.jsx("clipPath",{id:"clip0_834_118930",children:jsxRuntime.jsx("rect",{width:24,height:24,fill:"white"})})})]})),lC=nD;var rD=t=>jsxRuntime.jsxs("svg",St(W({width:36,height:36,viewBox:"0 0 36 36",fill:"none",xmlns:"http://www.w3.org/2000/svg"},t),{children:[jsxRuntime.jsx("rect",{width:36,height:36,rx:10,fill:"#F5F6F9"}),jsxRuntime.jsx("path",{d:"M26 27V25C26 22.7909 24.2091 21 22 21H14C11.7909 21 10 22.7909 10 25V27",stroke:"#7586B0",strokeWidth:2,strokeLinecap:"round",strokeLinejoin:"round"}),jsxRuntime.jsx("path",{fillRule:"evenodd",clipRule:"evenodd",d:"M18 17C20.2091 17 22 15.2091 22 13C22 10.7909 20.2091 9 18 9C15.7909 9 14 10.7909 14 13C14 15.2091 15.7909 17 18 17Z",stroke:"#7586B0",strokeWidth:2,strokeLinecap:"round",strokeLinejoin:"round"}),jsxRuntime.jsx("defs",{children:jsxRuntime.jsxs("linearGradient",{id:"paint0_linear_67_8545",x1:35.0204,y1:1.22449,x2:0,y2:36,gradientUnits:"userSpaceOnUse",children:[jsxRuntime.jsx("stop",{stopColor:"#56ACF6"}),jsxRuntime.jsx("stop",{offset:1,stopColor:"#1559E6"})]})})]})),uC=rD;var iD=t=>jsxRuntime.jsxs("svg",St(W({width:36,height:36,viewBox:"0 0 36 36",fill:"none",xmlns:"http://www.w3.org/2000/svg"},t),{children:[jsxRuntime.jsx("rect",{width:36,height:36,rx:10,fill:"#F5F6F9"}),jsxRuntime.jsx("path",{d:"M27 18.22C27 12.73 22.74 9 18 9C13.31 9 9 12.65 9 18.28C8.4 18.62 8 19.26 8 20V22C8 23.1 8.9 24 10 24H11V17.9C11 14.03 14.13 10.9 18 10.9C21.87 10.9 25 14.03 25 17.9V25H17V27H25C26.1 27 27 26.1 27 25V23.78C27.59 23.47 28 22.86 28 22.14V19.84C28 19.14 27.59 18.53 27 18.22Z",fill:"#7586B0"}),jsxRuntime.jsx("path",{d:"M15 20C15.5523 20 16 19.5523 16 19C16 18.4477 15.5523 18 15 18C14.4477 18 14 18.4477 14 19C14 19.5523 14.4477 20 15 20Z",fill:"#7586B0"}),jsxRuntime.jsx("path",{d:"M21 20C21.5523 20 22 19.5523 22 19C22 18.4477 21.5523 18 21 18C20.4477 18 20 18.4477 20 19C20 19.5523 20.4477 20 21 20Z",fill:"#7586B0"}),jsxRuntime.jsx("path",{d:"M24 17.03C23.52 14.18 21.04 12 18.05 12C15.02 12 11.76 14.51 12.02 18.45C14.49 17.44 16.35 15.24 16.88 12.56C18.19 15.19 20.88 17 24 17.03Z",fill:"#7586B0"}),jsxRuntime.jsx("defs",{children:jsxRuntime.jsxs("linearGradient",{id:"paint0_linear_267_19310",x1:35.0204,y1:1.22449,x2:0,y2:36,gradientUnits:"userSpaceOnUse",children:[jsxRuntime.jsx("stop",{stopColor:"#56ACF6"}),jsxRuntime.jsx("stop",{offset:1,stopColor:"#1559E6"})]})})]})),pC=iD;var oD=t=>jsxRuntime.jsxs("svg",St(W({width:36,height:36,viewBox:"0 0 36 36",fill:"none",xmlns:"http://www.w3.org/2000/svg"},t),{children:[jsxRuntime.jsx("rect",{width:36,height:36,rx:10,fill:"#F5F6F9"}),jsxRuntime.jsx("path",{d:"M26 10H10C8.89 10 8.01 10.89 8.01 12L8 24C8 25.11 8.89 26 10 26H26C27.11 26 28 25.11 28 24V12C28 10.89 27.11 10 26 10ZM26 24H10V18H26V24ZM26 14H10V12H26V14Z",fill:"#7586B0"}),jsxRuntime.jsx("defs",{children:jsxRuntime.jsxs("linearGradient",{id:"paint0_linear_67_8556",x1:35.0204,y1:1.22449,x2:0,y2:36,gradientUnits:"userSpaceOnUse",children:[jsxRuntime.jsx("stop",{stopColor:"#56ACF6"}),jsxRuntime.jsx("stop",{offset:1,stopColor:"#1559E6"})]})})]})),hC=oD;var aD=t=>jsxRuntime.jsxs("svg",St(W({width:21,height:20,viewBox:"0 0 21 20",fill:"none",xmlns:"http://www.w3.org/2000/svg"},t),{children:[jsxRuntime.jsxs("g",{clipPath:"url(#clip0_834_120339)",children:[jsxRuntime.jsx("path",{d:"M10.3336 19.2858C15.462 19.2858 19.6193 15.1285 19.6193 10.0001C19.6193 4.87171 15.462 0.714355 10.3336 0.714355C5.20521 0.714355 1.04785 4.87171 1.04785 10.0001C1.04785 15.1285 5.20521 19.2858 10.3336 19.2858Z",stroke:"#7586B0",strokeWidth:1.71429,strokeLinecap:"round",strokeLinejoin:"round"}),jsxRuntime.jsx("path",{d:"M12.7649 7.46052C12.6813 7.22393 12.5523 7.0088 12.3883 6.8256C12.0395 6.43592 11.5327 6.19067 10.9685 6.19067H9.4942C8.55517 6.19067 7.79395 6.9519 7.79395 7.89093C7.79395 8.68995 8.3503 9.38116 9.13086 9.5519L11.3756 10.0429C12.25 10.2342 12.8733 11.0091 12.8733 11.9043C12.8733 12.9562 12.0205 13.8097 10.9685 13.8097H9.6987C8.86936 13.8097 8.16382 13.2797 7.90233 12.5399",stroke:"#7586B0",strokeWidth:1.71429,strokeLinecap:"round",strokeLinejoin:"round"}),jsxRuntime.jsx("path",{d:"M10.3335 6.19065V4.28589",stroke:"#7586B0",strokeWidth:1.71429,strokeLinecap:"round",strokeLinejoin:"round"}),jsxRuntime.jsx("path",{d:"M10.3335 15.7144V13.8096",stroke:"#7586B0",strokeWidth:1.71429,strokeLinecap:"round",strokeLinejoin:"round"})]}),jsxRuntime.jsx("defs",{children:jsxRuntime.jsx("clipPath",{id:"clip0_834_120339",children:jsxRuntime.jsx("rect",{width:20,height:20,fill:"white",transform:"translate(0.333496)"})})})]})),gC=aD;var sD=t=>jsxRuntime.jsx("svg",St(W({width:16,height:16,viewBox:"0 0 16 16",fill:"none",xmlns:"http://www.w3.org/2000/svg"},t),{children:jsxRuntime.jsx("path",{fillRule:"evenodd",clipRule:"evenodd",d:"M6.95392 1.03353C7.1196 1.56038 6.82682 2.12178 6.29997 2.28746C5.79034 2.44773 5.30237 2.68036 4.85175 2.98146C3.76168 3.70982 2.95789 4.79361 2.57732 6.04817C2.19675 7.30273 2.26296 8.65044 2.76466 9.86166C3.26637 11.0729 4.17252 12.0727 5.32873 12.6907C6.48494 13.3087 7.81967 13.5067 9.10549 13.2509C10.3913 12.9951 11.5487 12.3014 12.3804 11.288C13.2121 10.2746 13.6666 9.00413 13.6666 7.69312C13.6666 7.14083 14.1144 6.69312 14.6666 6.69312C15.2189 6.69312 15.6666 7.14083 15.6666 7.69312C15.6666 7.92228 15.6564 8.15052 15.6361 8.37721C15.6465 8.44937 15.6492 8.52379 15.6432 8.59952L15.6392 8.64883C15.6298 8.75932 15.6028 8.86407 15.5612 8.96057C15.3409 10.2743 14.7807 11.5158 13.9264 12.5568C12.8012 13.9279 11.2353 14.8664 9.49568 15.2125C7.75603 15.5585 5.95022 15.2906 4.38594 14.4545C2.82166 13.6184 1.59568 12.2657 0.916905 10.627C0.238131 8.98832 0.148554 7.16495 0.663439 5.4676C1.17832 3.77025 2.26581 2.30394 3.74061 1.31852C4.35023 0.911179 5.01049 0.596408 5.69999 0.379577C6.22684 0.213898 6.78824 0.506683 6.95392 1.03353ZM7.56761 1.27284C7.61434 0.722538 8.09832 0.314306 8.64863 0.361031L8.69791 0.365373C9.24791 0.415584 9.65307 0.902149 9.60286 1.45215C9.55265 2.00214 9.06608 2.4073 8.51608 2.35709L8.47942 2.35386C7.92912 2.30714 7.52089 1.82315 7.56761 1.27284ZM12.4186 2.90891C12.8384 2.55014 13.4697 2.59967 13.8284 3.01954C13.8498 3.04454 13.871 3.06967 13.892 3.09494C14.2454 3.51937 14.1878 4.14991 13.7634 4.50329C13.339 4.85667 12.7084 4.79906 12.355 4.37463C12.3395 4.35592 12.3238 4.33731 12.3079 4.31879C11.9492 3.89892 11.9987 3.26769 12.4186 2.90891ZM8.99998 5.33352C8.99998 4.78124 8.55226 4.33352 7.99998 4.33352C7.44769 4.33352 6.99998 4.78124 6.99998 5.33352V8.00019C6.99998 8.55247 7.44769 9.00019 7.99998 9.00019H10.6666C11.2189 9.00019 11.6666 8.55247 11.6666 8.00019C11.6666 7.4479 11.2189 7.00019 10.6666 7.00019H8.99998V5.33352Z",fill:"#7586B0"})})),im=sD;var lD=t=>jsxRuntime.jsxs("svg",St(W({width:24,height:25,viewBox:"0 0 24 25",fill:"none",xmlns:"http://www.w3.org/2000/svg"},t),{children:[jsxRuntime.jsxs("g",{clipPath:"url(#clip0_834_116282)",children:[jsxRuntime.jsx("path",{d:"M21.4286 5.32483H2.57146C1.62469 5.32483 0.857178 6.09235 0.857178 7.03911V10.4677C0.857178 11.4145 1.62469 12.182 2.57146 12.182H21.4286C22.3754 12.182 23.1429 11.4145 23.1429 10.4677V7.03911C23.1429 6.09235 22.3754 5.32483 21.4286 5.32483Z",stroke:"#7586B0",strokeWidth:1.71429,strokeLinecap:"round",strokeLinejoin:"round"}),jsxRuntime.jsx("path",{d:"M21.4287 12.182V21.6106C21.4287 22.0652 21.248 22.5013 20.9266 22.8227C20.6051 23.1442 20.169 23.3249 19.7144 23.3249H4.28582C3.83116 23.3249 3.39513 23.1442 3.07363 22.8227C2.75215 22.5013 2.57153 22.0652 2.57153 21.6106V12.182",stroke:"#7586B0",strokeWidth:1.71429,strokeLinecap:"round",strokeLinejoin:"round"}),jsxRuntime.jsx("path",{d:"M12 5.32483V23.3248",stroke:"#7586B0",strokeWidth:1.71429,strokeLinecap:"round",strokeLinejoin:"round"}),jsxRuntime.jsx("path",{d:"M17.1429 1.03912L12 5.32484L6.85718 1.03912",stroke:"#7586B0",strokeWidth:1.71429,strokeLinecap:"round",strokeLinejoin:"round"})]}),jsxRuntime.jsx("defs",{children:jsxRuntime.jsx("clipPath",{id:"clip0_834_116282",children:jsxRuntime.jsx("rect",{width:24,height:24,fill:"white",transform:"translate(0 0.182007)"})})})]})),vC=lD;var cD=t=>jsxRuntime.jsx("svg",St(W({width:20,height:20,viewBox:"0 0 20 20",fill:"none",xmlns:"http://www.w3.org/2000/svg"},t),{children:jsxRuntime.jsx("path",{d:"M10.8333 2.5C6.69168 2.5 3.33334 5.85833 3.33334 10H0.833344L4.07501 13.2417L4.13334 13.3583L7.50001 10H5.00001C5.00001 6.775 7.60834 4.16667 10.8333 4.16667C14.0583 4.16667 16.6667 6.775 16.6667 10C16.6667 13.225 14.0583 15.8333 10.8333 15.8333C9.22501 15.8333 7.76668 15.175 6.71668 14.1167L5.53334 15.3C6.89168 16.6583 8.75834 17.5 10.8333 17.5C14.975 17.5 18.3333 14.1417 18.3333 10C18.3333 5.85833 14.975 2.5 10.8333 2.5ZM10 6.66667V10.8333L13.5667 12.95L14.1667 11.9417L11.25 10.2083V6.66667H10Z",fill:"#6678A7"})})),om=cD;var uD=t=>jsxRuntime.jsxs("svg",St(W({width:36,height:36,viewBox:"0 0 36 36",fill:"none",xmlns:"http://www.w3.org/2000/svg"},t),{children:[jsxRuntime.jsx("rect",{width:36,height:36,rx:10,fill:"url(#paint0_linear_834_118583)"}),jsxRuntime.jsx("rect",{width:36,height:36,rx:10,fill:"#F5F6F9"}),jsxRuntime.jsx("path",{fillRule:"evenodd",clipRule:"evenodd",d:"M15.9539 7.70028C16.1196 8.22713 15.8268 8.78853 15.3 8.95421C14.4906 9.20875 13.7155 9.57824 12.9999 10.0564C11.2686 11.2132 9.99197 12.9346 9.38754 14.9271C8.78311 16.9196 8.88826 19.0601 9.68509 20.9838C10.4819 22.9075 11.9211 24.4954 13.7574 25.477C15.5938 26.4585 17.7136 26.7729 19.7558 26.3667C21.798 25.9605 23.6362 24.8588 24.9571 23.2492C26.278 21.6396 27 19.6219 27 17.5397C27 16.9874 27.4477 16.5397 28 16.5397C28.5523 16.5397 29 16.9874 29 17.5397C29 17.8969 28.9826 18.2526 28.9483 18.6056C28.9662 18.6949 28.9722 18.7883 28.9645 18.8837L28.9606 18.9309C28.9496 19.0607 28.9143 19.1825 28.8595 19.2924C28.5513 21.2017 27.7432 23.007 26.5031 24.518C24.8886 26.4852 22.642 27.8318 20.146 28.3283C17.65 28.8248 15.059 28.4405 12.8146 27.2408C10.5702 26.0411 8.81122 24.1004 7.83733 21.7492C6.86343 19.398 6.73491 16.7819 7.47366 14.3465C8.21241 11.9112 9.77272 9.80737 11.8887 8.3935C12.7634 7.80905 13.7107 7.35743 14.7 7.04633C15.2269 6.88065 15.7883 7.17343 15.9539 7.70028ZM17.8497 7.95155C17.8964 7.40125 18.3804 6.99302 18.9307 7.03974L18.9779 7.04385C19.528 7.0929 19.9342 7.57861 19.8851 8.12871C19.8361 8.67881 19.3503 9.085 18.8002 9.03595L18.7615 9.03257C18.2112 8.98585 17.8029 8.50186 17.8497 7.95155ZM22.8579 9.19953C23.172 8.74525 23.7949 8.63161 24.2492 8.9457C24.2751 8.96361 24.3009 8.98162 24.3266 8.99974C24.7782 9.31772 24.8865 9.94155 24.5685 10.3931C24.2505 10.8447 23.6267 10.953 23.1751 10.635C23.1541 10.6202 23.1329 10.6054 23.1118 10.5908C22.6575 10.2767 22.5438 9.6538 22.8579 9.19953ZM26.6058 12.8085C27.1045 12.5712 27.7011 12.7831 27.9384 13.2818C27.9519 13.3102 27.9653 13.3387 27.9786 13.3672C28.2116 13.868 27.9946 14.4628 27.4939 14.6958C26.9931 14.9288 26.3983 14.7117 26.1653 14.211L26.1506 14.1796L26.1324 14.1411C25.8951 13.6424 26.1071 13.0458 26.6058 12.8085ZM19 14.0003C19 13.448 18.5523 13.0003 18 13.0003C17.4477 13.0003 17 13.448 17 14.0003V18.0003C17 18.5526 17.4477 19.0003 18 19.0003H22C22.5523 19.0003 23 18.5526 23 18.0003C23 17.448 22.5523 17.0003 22 17.0003H19V14.0003Z",fill:"#7586B0"}),jsxRuntime.jsx("defs",{children:jsxRuntime.jsx("linearGradient",{id:"paint0_linear_834_118583",x1:35.0204,y1:1.22449,x2:0,y2:36,gradientUnits:"userSpaceOnUse"})})]})),SC=uD;var pD=t=>jsxRuntime.jsx("svg",St(W({width:24,height:24,viewBox:"0 0 24 24",fill:"none",xmlns:"http://www.w3.org/2000/svg"},t),{children:jsxRuntime.jsx("path",{fillRule:"evenodd",clipRule:"evenodd",d:"M9.95394 1.70028C10.1196 2.22713 9.82684 2.78853 9.29999 2.95421C8.49057 3.20875 7.71555 3.57824 6.99987 4.05644C5.26859 5.21324 3.99197 6.93456 3.38754 8.9271C2.78311 10.9196 2.88826 13.0601 3.68509 14.9838C4.48191 16.9075 5.9211 18.4954 7.75743 19.477C9.59377 20.4585 11.7136 20.7729 13.7558 20.3667C15.798 19.9605 17.6362 18.8588 18.9571 17.2492C20.278 15.6396 21 13.6219 21 11.5397C21 10.9874 21.4477 10.5397 22 10.5397C22.5523 10.5397 23 10.9874 23 11.5397C23 11.8969 22.9826 12.2526 22.9483 12.6056C22.9662 12.6949 22.9722 12.7883 22.9645 12.8837L22.9606 12.9309C22.9496 13.0607 22.9143 13.1825 22.8595 13.2924C22.5513 15.2017 21.7432 17.007 20.5031 18.518C18.8886 20.4852 16.642 21.8318 14.146 22.3283C11.65 22.8248 9.05905 22.4405 6.81464 21.2408C4.57023 20.0411 2.81122 18.1004 1.83733 15.7492C0.863434 13.398 0.734911 10.7819 1.47366 8.34653C2.21241 5.91121 3.77272 3.80737 5.88873 2.3935C6.76341 1.80905 7.71072 1.35743 8.70001 1.04633C9.22686 0.880646 9.78826 1.17343 9.95394 1.70028ZM11.8497 1.95155C11.8964 1.40125 12.3804 0.993017 12.9307 1.03974L12.9779 1.04385C13.528 1.0929 13.9342 1.57861 13.8851 2.12871C13.8361 2.67881 13.3503 3.085 12.8002 3.03595L12.7615 3.03257C12.2112 2.98585 11.8029 2.50186 11.8497 1.95155ZM16.8579 3.19953C17.172 2.74525 17.7949 2.63161 18.2492 2.9457C18.2751 2.96361 18.3009 2.98162 18.3266 2.99974C18.7782 3.31772 18.8865 3.94155 18.5685 4.39311C18.2505 4.84467 17.6267 4.95296 17.1751 4.63498C17.1541 4.62016 17.1329 4.60542 17.1118 4.59078C16.6575 4.27669 16.5438 3.6538 16.8579 3.19953ZM20.6058 6.80846C21.1045 6.57117 21.7011 6.78308 21.9384 7.28179C21.9519 7.3102 21.9653 7.33869 21.9786 7.36723C22.2116 7.86796 21.9946 8.46276 21.4939 8.69577C20.9931 8.92877 20.3983 8.71174 20.1653 8.21101L20.1506 8.17957L20.1324 8.14112C19.8951 7.64241 20.1071 7.04576 20.6058 6.80846ZM13 8.00027C13 7.44798 12.5523 7.00027 12 7.00027C11.4477 7.00027 11 7.44798 11 8.00027V12.0003C11 12.5526 11.4477 13.0003 12 13.0003H16C16.5523 13.0003 17 12.5526 17 12.0003C17 11.448 16.5523 11.0003 16 11.0003H13V8.00027Z",fill:"#7586B0"})})),xC=pD;var fD=t=>jsxRuntime.jsxs("svg",St(W({width:36,height:36,viewBox:"0 0 36 36",fill:"none",xmlns:"http://www.w3.org/2000/svg"},t),{children:[jsxRuntime.jsx("rect",{width:36,height:36,rx:10,fill:"#F5F6F9"}),jsxRuntime.jsx("path",{fillRule:"evenodd",clipRule:"evenodd",d:"M9 12C9 10.8954 9.89543 10 11 10H25C26.1046 10 27 10.8954 27 12V26C27 27.1046 26.1046 28 25 28H11C9.89543 28 9 27.1046 9 26V12Z",stroke:"#7586B0",strokeWidth:2,strokeLinecap:"round",strokeLinejoin:"round"}),jsxRuntime.jsx("path",{d:"M22 8V12",stroke:"#7586B0",strokeWidth:2,strokeLinecap:"round",strokeLinejoin:"round"}),jsxRuntime.jsx("path",{d:"M14 8V12",stroke:"#7586B0",strokeWidth:2,strokeLinecap:"round",strokeLinejoin:"round"}),jsxRuntime.jsx("path",{d:"M9 16H27",stroke:"#7586B0",strokeWidth:2,strokeLinecap:"round",strokeLinejoin:"round"}),jsxRuntime.jsx("defs",{children:jsxRuntime.jsxs("linearGradient",{id:"paint0_linear_45_8861",x1:35.0204,y1:1.22449,x2:0,y2:36,gradientUnits:"userSpaceOnUse",children:[jsxRuntime.jsx("stop",{stopColor:"#56ACF6"}),jsxRuntime.jsx("stop",{offset:1,stopColor:"#1559E6"})]})})]})),_C=fD;var hD=t=>jsxRuntime.jsx("svg",St(W({width:24,height:24,viewBox:"0 0 24 24",fill:"none",xmlns:"http://www.w3.org/2000/svg"},t),{children:jsxRuntime.jsxs("g",{id:"trash-2",children:[jsxRuntime.jsx("path",{id:"Shape",d:"M3 6H5H21",stroke:"#F88078",strokeWidth:2,strokeLinecap:"round",strokeLinejoin:"round"}),jsxRuntime.jsx("path",{id:"Shape_2",d:"M20 6C20 5.44772 19.5523 5 19 5C18.4477 5 18 5.44772 18 6H20ZM6 6C6 5.44772 5.55228 5 5 5C4.44772 5 4 5.44772 4 6H6ZM7 6C7 6.55228 7.44772 7 8 7C8.55228 7 9 6.55228 9 6H7ZM15 6C15 6.55228 15.4477 7 16 7C16.5523 7 17 6.55228 17 6H15ZM18 6V20H20V6H18ZM18 20C18 20.5523 17.5523 21 17 21V23C18.6569 23 20 21.6569 20 20H18ZM17 21H7V23H17V21ZM7 21C6.44772 21 6 20.5523 6 20H4C4 21.6569 5.34315 23 7 23V21ZM6 20V6H4V20H6ZM9 6V4H7V6H9ZM9 4C9 3.44772 9.44772 3 10 3V1C8.34315 1 7 2.34315 7 4H9ZM10 3H14V1H10V3ZM14 3C14.5523 3 15 3.44772 15 4H17C17 2.34315 15.6569 1 14 1V3ZM15 4V6H17V4H15Z",fill:"#F88078"}),jsxRuntime.jsx("path",{id:"Shape_3",d:"M10 11V17",stroke:"#F88078",strokeWidth:2,strokeLinecap:"round",strokeLinejoin:"round"}),jsxRuntime.jsx("path",{id:"Shape_4",d:"M14 11V17",stroke:"#F88078",strokeWidth:2,strokeLinecap:"round",strokeLinejoin:"round"})]})})),TC=hD;var gD=t=>jsxRuntime.jsxs("svg",St(W({width:24,height:24,viewBox:"0 0 24 24",fill:"none",xmlns:"http://www.w3.org/2000/svg"},t),{children:[jsxRuntime.jsx("path",{d:"M21.1667 4H2.83333C1.82081 4 1 4.89543 1 6V18C1 19.1046 1.82081 20 2.83333 20H21.1667C22.1792 20 23 19.1046 23 18V6C23 4.89543 22.1792 4 21.1667 4Z",fill:"#C6C6C7"}),jsxRuntime.jsx("path",{opacity:.3,d:"M19.75 16.4286H17.5C17.0125 16.4286 16.75 16.2 16.75 15.6667C16.75 15.1334 17.0125 14.9048 17.5 14.9048H19.75C20.2375 14.9048 20.5 15.1334 20.5 15.6667C20.5 16.2 20.2375 16.4286 19.75 16.4286ZM15.25 16.4286H13C12.5125 16.4286 12.25 16.2 12.25 15.6667C12.25 15.1334 12.5125 14.9048 13 14.9048H15.25C15.7375 14.9048 16 15.1334 16 15.6667C16 16.2 15.7375 16.4286 15.25 16.4286ZM10.75 16.4286H8.5C8.0125 16.4286 7.75 16.2 7.75 15.6667C7.75 15.1334 8.0125 14.9048 8.5 14.9048H10.75C11.2375 14.9048 11.5 15.1334 11.5 15.6667C11.5 16.2 11.2375 16.4286 10.75 16.4286ZM6.25 16.4286H4C3.5125 16.4286 3.25 16.2 3.25 15.6667C3.25 15.1334 3.5125 14.9048 4 14.9048H6.25C6.7375 14.9048 7 15.1334 7 15.6667C7 16.2 6.7375 16.4286 6.25 16.4286Z",fill:"black"})]})),IC=gD;var bD=t=>jsxRuntime.jsx("svg",St(W({width:21,height:20,viewBox:"0 0 21 20",fill:"none",xmlns:"http://www.w3.org/2000/svg"},t),{children:jsxRuntime.jsx("circle",{cx:10.333,cy:10,r:9,fill:"white",stroke:"#327EEE",strokeWidth:2})})),DC=bD;var vD=t=>jsxRuntime.jsx("svg",St(W({width:20,height:20,viewBox:"0 0 20 20",fill:"none",xmlns:"http://www.w3.org/2000/svg"},t),{children:jsxRuntime.jsxs("g",{id:"Group 16159",children:[jsxRuntime.jsx("circle",{id:"Ellipse 5",cx:10,cy:10,r:9.25,fill:"#327EEE",stroke:"#327EEE",strokeWidth:1.5}),jsxRuntime.jsx("path",{id:"Shape",d:"M5 10.3636L8.63667 14L12.637 10L14.6372 8",stroke:"white",strokeWidth:2,strokeLinecap:"round",strokeLinejoin:"round"})]})})),AC=vD;var SD=t=>jsxRuntime.jsx("svg",St(W({width:21,height:20,viewBox:"0 0 21 20",fill:"none",xmlns:"http://www.w3.org/2000/svg"},t),{children:jsxRuntime.jsxs("g",{id:"Stepper indicators",children:[jsxRuntime.jsx("circle",{id:"Ellipse 5",cx:10.667,cy:10,r:9.25,fill:"#B3BCD3",stroke:"#B3BCD3",strokeWidth:1.5}),jsxRuntime.jsx("path",{id:"Shape",d:"M5.66699 10.3636L9.30366 14L13.304 10L15.3042 8",stroke:"white",strokeWidth:2,strokeLinecap:"round",strokeLinejoin:"round"})]})})),OC=SD;var xD=t=>jsxRuntime.jsx("svg",St(W({width:18,height:18,viewBox:"0 0 18 18",fill:"none",xmlns:"http://www.w3.org/2000/svg"},t),{children:jsxRuntime.jsx("path",{d:"M9 3L7.9425 4.0575L12.1275 8.25H3V9.75H12.1275L7.9425 13.9425L9 15L15 9L9 3Z",fill:"white"})})),FC=xD;var ED=t=>jsxRuntime.jsx("svg",St(W({width:20,height:20,viewBox:"0 0 20 20",fill:"none",xmlns:"http://www.w3.org/2000/svg"},t),{children:jsxRuntime.jsx("path",{d:"M15.8337 5.34199L14.6587 4.16699L10.0003 8.82533L5.34199 4.16699L4.16699 5.34199L8.82533 10.0003L4.16699 14.6587L5.34199 15.8337L10.0003 11.1753L14.6587 15.8337L15.8337 14.6587L11.1753 10.0003L15.8337 5.34199Z",fill:"#327EEE"})})),NC=ED;var _D=t=>jsxRuntime.jsx("svg",St(W({width:24,height:24,viewBox:"0 0 24 24",fill:"none",xmlns:"http://www.w3.org/2000/svg"},t),{children:jsxRuntime.jsx("g",{id:"check",children:jsxRuntime.jsx("path",{id:"Shape",d:"M20 7L9 18L4 13",stroke:"#F5F6F9",strokeWidth:2,strokeLinecap:"round",strokeLinejoin:"round"})})})),LC=_D;var TD=t=>jsxRuntime.jsxs("svg",St(W({width:16,height:16,viewBox:"0 0 16 16",fill:"none",xmlns:"http://www.w3.org/2000/svg"},t),{children:[jsxRuntime.jsxs("g",{clipPath:"url(#clip0_1889_12169)",children:[jsxRuntime.jsx("path",{d:"M11.4286 7.42578L8 13.1401",stroke:"#7586B0",strokeWidth:1.71429,strokeLinecap:"round",strokeLinejoin:"round"}),jsxRuntime.jsx("path",{d:"M14.857 13.1412C15.3274 12.0123 15.5118 10.7848 15.3938 9.56751C15.2758 8.35027 14.8592 7.18097 14.1808 6.16341C13.5024 5.14585 12.5833 4.31152 11.5051 3.73446C10.4268 3.1574 9.22281 2.85547 7.99986 2.85547C6.77691 2.85547 5.57288 3.1574 4.49463 3.73446C3.41639 4.31152 2.49729 5.14585 1.81892 6.16341C1.14055 7.18097 0.723889 8.35027 0.605928 9.56751C0.487968 10.7848 0.672354 12.0123 1.14272 13.1412H14.857Z",stroke:"#7586B0",strokeWidth:1.71429,strokeLinecap:"round",strokeLinejoin:"round"})]}),jsxRuntime.jsx("defs",{children:jsxRuntime.jsx("clipPath",{id:"clip0_1889_12169",children:jsxRuntime.jsx("rect",{width:16,height:16,fill:"white"})})})]})),UC=TD;var wD=t=>jsxRuntime.jsx("svg",St(W({width:16,height:16,viewBox:"0 0 18 18",fill:"none",xmlns:"http://www.w3.org/2000/svg"},t),{children:jsxRuntime.jsxs("g",{id:"tag--tags-bookmark-favorite",children:[jsxRuntime.jsx("path",{id:"Vector",d:"M1.26995 11.9426L6.05743 16.7301C6.2305 16.903 6.4651 17.0001 6.7097 17.0001C6.95431 17.0001 7.18891 16.903 7.36198 16.7301L16.8631 7.22895C16.9108 7.18332 16.9478 7.12758 16.9712 7.06583C16.9946 7.00408 17.0039 6.93787 16.9985 6.87205L16.2724 2.15839C16.2664 2.04607 16.2192 1.93992 16.1396 1.86038C16.0601 1.78085 15.9539 1.73357 15.8416 1.72764L11.128 1.00152C11.0622 0.996055 10.9959 1.00538 10.9342 1.0288C10.8724 1.05222 10.8167 1.08916 10.7711 1.1369L1.26995 10.638C1.09709 10.8111 1 11.0457 1 11.2903C1 11.5349 1.09709 11.7695 1.26995 11.9426Z",stroke:"#327EEE",strokeWidth:1.5,strokeLinecap:"round",strokeLinejoin:"round"}),jsxRuntime.jsx("path",{id:"Vector_2",d:"M12.5548 6.05884C12.3916 6.05884 12.2351 5.99401 12.1197 5.87861C12.0043 5.76321 11.9395 5.60669 11.9395 5.44348C11.9395 5.28028 12.0043 5.12376 12.1197 5.00836C12.2351 4.89296 12.3916 4.82812 12.5548 4.82812C12.718 4.82812 12.8745 4.89296 12.9899 5.00836C13.1053 5.12376 13.1702 5.28028 13.1702 5.44348C13.1702 5.60669 13.1053 5.76321 12.9899 5.87861C12.8745 5.99401 12.718 6.05884 12.5548 6.05884Z",stroke:"#327EEE",strokeWidth:1.5,strokeLinecap:"round",strokeLinejoin:"round"})]})})),$C=wD;var kD=t=>jsxRuntime.jsx("svg",St(W({width:24,height:24,viewBox:"0 0 24 24",fill:"none",xmlns:"http://www.w3.org/2000/svg"},t),{children:jsxRuntime.jsx("path",{d:"M12 3V21.0001M3 11.9446H21",stroke:"currentColor",strokeWidth:2,strokeLinecap:"round",strokeLinejoin:"round"})})),jC=kD;var DD=t=>jsxRuntime.jsx("svg",St(W({width:24,height:24,viewBox:"0 0 24 24",fill:"none",xmlns:"http://www.w3.org/2000/svg"},t),{children:jsxRuntime.jsx("path",{d:"M3 12H21",stroke:"currentColor",strokeWidth:2,strokeLinecap:"round",strokeLinejoin:"round"})})),zC=DD;var AD=t=>jsxRuntime.jsx("svg",St(W({width:24,height:24,viewBox:"0 0 24 24",fill:"none",xmlns:"http://www.w3.org/2000/svg"},t),{children:jsxRuntime.jsx("path",{d:"M3 11.1429L9.71572 17.8586C9.79383 17.9367 9.92046 17.9367 9.99856 17.8586L21.8571 6",stroke:"currentColor",strokeWidth:2,strokeLinecap:"round"})})),WC=AD;var RD=Q.div`
4685
+ `,rt=Uv.forwardRef((t,e)=>{let A=t,{children:n,style:r,variant:i="body1",color:o="primary",overrideColor:s,bold:c=false,as:p,className:h,lineHeight:v}=A,P=On(A,["children","style","variant","color","overrideColor","bold","as","className","lineHeight"]),x=react.useTheme(),T=vb(x,i),I=p||T.semanticElement,R=s||Jk(x,o);return jsxRuntime.jsx(tD,St(W({as:I,ref:e},P),{className:h,style:r,$variant:i,$bold:c,$color:R,$lineHeight:v,$isInline:I==="span",children:n}))});rt.displayName="Typography";var rm=(t,e)=>{switch(t){case "primary":return e.stigg.palette.text.primary;case "secondary":return e.stigg.palette.text.secondary;default:return t}};var Eb={};K1(Eb,{Add:()=>jC,Addons:()=>lC,ArrowForward:()=>FC,BillingInfoCustomer:()=>uC,Check:()=>LC,Close:()=>NC,ContactSupport:()=>pC,Coupon:()=>$C,CreditCard:()=>hC,DollarCoin:()=>gC,EntitlementCheck:()=>WC,MiniSchedule:()=>im,OutlinedCheckedCircle:()=>AC,OutlinedCheckedCircleDisabled:()=>OC,OutlinedCircle:()=>DC,PayAsYouGoCharge:()=>UC,PaymentMethod:()=>IC,Promotions:()=>vC,Remove:()=>zC,RenewSubscription:()=>_C,Restore:()=>om,ScheduleBox:()=>SC,ScheduleClock:()=>xC,Trash:()=>TC});var nD=t=>jsxRuntime.jsxs("svg",St(W({width:24,height:24,viewBox:"0 0 24 24",fill:"none",xmlns:"http://www.w3.org/2000/svg"},t),{children:[jsxRuntime.jsxs("g",{clipPath:"url(#clip0_834_118930)",children:[jsxRuntime.jsx("path",{d:"M12 6.85712V17.1428",stroke:"#7586B0",strokeWidth:1.71429,strokeLinecap:"round",strokeLinejoin:"round"}),jsxRuntime.jsx("path",{d:"M6.85712 12H17.1428",stroke:"#7586B0",strokeWidth:1.71429,strokeLinecap:"round",strokeLinejoin:"round"}),jsxRuntime.jsx("path",{d:"M18 0.857117H5.99997C3.15966 0.857117 0.857117 3.15966 0.857117 5.99997V18C0.857117 20.8404 3.15966 23.1428 5.99997 23.1428H18C20.8404 23.1428 23.1428 20.8404 23.1428 18V5.99997C23.1428 3.15966 20.8404 0.857117 18 0.857117Z",stroke:"#7586B0",strokeWidth:1.71429,strokeLinecap:"round",strokeLinejoin:"round"})]}),jsxRuntime.jsx("defs",{children:jsxRuntime.jsx("clipPath",{id:"clip0_834_118930",children:jsxRuntime.jsx("rect",{width:24,height:24,fill:"white"})})})]})),lC=nD;var rD=t=>jsxRuntime.jsxs("svg",St(W({width:36,height:36,viewBox:"0 0 36 36",fill:"none",xmlns:"http://www.w3.org/2000/svg"},t),{children:[jsxRuntime.jsx("rect",{width:36,height:36,rx:10,fill:"#F5F6F9"}),jsxRuntime.jsx("path",{d:"M26 27V25C26 22.7909 24.2091 21 22 21H14C11.7909 21 10 22.7909 10 25V27",stroke:"#7586B0",strokeWidth:2,strokeLinecap:"round",strokeLinejoin:"round"}),jsxRuntime.jsx("path",{fillRule:"evenodd",clipRule:"evenodd",d:"M18 17C20.2091 17 22 15.2091 22 13C22 10.7909 20.2091 9 18 9C15.7909 9 14 10.7909 14 13C14 15.2091 15.7909 17 18 17Z",stroke:"#7586B0",strokeWidth:2,strokeLinecap:"round",strokeLinejoin:"round"}),jsxRuntime.jsx("defs",{children:jsxRuntime.jsxs("linearGradient",{id:"paint0_linear_67_8545",x1:35.0204,y1:1.22449,x2:0,y2:36,gradientUnits:"userSpaceOnUse",children:[jsxRuntime.jsx("stop",{stopColor:"#56ACF6"}),jsxRuntime.jsx("stop",{offset:1,stopColor:"#1559E6"})]})})]})),uC=rD;var iD=t=>jsxRuntime.jsxs("svg",St(W({width:36,height:36,viewBox:"0 0 36 36",fill:"none",xmlns:"http://www.w3.org/2000/svg"},t),{children:[jsxRuntime.jsx("rect",{width:36,height:36,rx:10,fill:"#F5F6F9"}),jsxRuntime.jsx("path",{d:"M27 18.22C27 12.73 22.74 9 18 9C13.31 9 9 12.65 9 18.28C8.4 18.62 8 19.26 8 20V22C8 23.1 8.9 24 10 24H11V17.9C11 14.03 14.13 10.9 18 10.9C21.87 10.9 25 14.03 25 17.9V25H17V27H25C26.1 27 27 26.1 27 25V23.78C27.59 23.47 28 22.86 28 22.14V19.84C28 19.14 27.59 18.53 27 18.22Z",fill:"#7586B0"}),jsxRuntime.jsx("path",{d:"M15 20C15.5523 20 16 19.5523 16 19C16 18.4477 15.5523 18 15 18C14.4477 18 14 18.4477 14 19C14 19.5523 14.4477 20 15 20Z",fill:"#7586B0"}),jsxRuntime.jsx("path",{d:"M21 20C21.5523 20 22 19.5523 22 19C22 18.4477 21.5523 18 21 18C20.4477 18 20 18.4477 20 19C20 19.5523 20.4477 20 21 20Z",fill:"#7586B0"}),jsxRuntime.jsx("path",{d:"M24 17.03C23.52 14.18 21.04 12 18.05 12C15.02 12 11.76 14.51 12.02 18.45C14.49 17.44 16.35 15.24 16.88 12.56C18.19 15.19 20.88 17 24 17.03Z",fill:"#7586B0"}),jsxRuntime.jsx("defs",{children:jsxRuntime.jsxs("linearGradient",{id:"paint0_linear_267_19310",x1:35.0204,y1:1.22449,x2:0,y2:36,gradientUnits:"userSpaceOnUse",children:[jsxRuntime.jsx("stop",{stopColor:"#56ACF6"}),jsxRuntime.jsx("stop",{offset:1,stopColor:"#1559E6"})]})})]})),pC=iD;var oD=t=>jsxRuntime.jsxs("svg",St(W({width:36,height:36,viewBox:"0 0 36 36",fill:"none",xmlns:"http://www.w3.org/2000/svg"},t),{children:[jsxRuntime.jsx("rect",{width:36,height:36,rx:10,fill:"#F5F6F9"}),jsxRuntime.jsx("path",{d:"M26 10H10C8.89 10 8.01 10.89 8.01 12L8 24C8 25.11 8.89 26 10 26H26C27.11 26 28 25.11 28 24V12C28 10.89 27.11 10 26 10ZM26 24H10V18H26V24ZM26 14H10V12H26V14Z",fill:"#7586B0"}),jsxRuntime.jsx("defs",{children:jsxRuntime.jsxs("linearGradient",{id:"paint0_linear_67_8556",x1:35.0204,y1:1.22449,x2:0,y2:36,gradientUnits:"userSpaceOnUse",children:[jsxRuntime.jsx("stop",{stopColor:"#56ACF6"}),jsxRuntime.jsx("stop",{offset:1,stopColor:"#1559E6"})]})})]})),hC=oD;var aD=t=>jsxRuntime.jsxs("svg",St(W({width:21,height:20,viewBox:"0 0 21 20",fill:"none",xmlns:"http://www.w3.org/2000/svg"},t),{children:[jsxRuntime.jsxs("g",{clipPath:"url(#clip0_834_120339)",children:[jsxRuntime.jsx("path",{d:"M10.3336 19.2858C15.462 19.2858 19.6193 15.1285 19.6193 10.0001C19.6193 4.87171 15.462 0.714355 10.3336 0.714355C5.20521 0.714355 1.04785 4.87171 1.04785 10.0001C1.04785 15.1285 5.20521 19.2858 10.3336 19.2858Z",stroke:"#7586B0",strokeWidth:1.71429,strokeLinecap:"round",strokeLinejoin:"round"}),jsxRuntime.jsx("path",{d:"M12.7649 7.46052C12.6813 7.22393 12.5523 7.0088 12.3883 6.8256C12.0395 6.43592 11.5327 6.19067 10.9685 6.19067H9.4942C8.55517 6.19067 7.79395 6.9519 7.79395 7.89093C7.79395 8.68995 8.3503 9.38116 9.13086 9.5519L11.3756 10.0429C12.25 10.2342 12.8733 11.0091 12.8733 11.9043C12.8733 12.9562 12.0205 13.8097 10.9685 13.8097H9.6987C8.86936 13.8097 8.16382 13.2797 7.90233 12.5399",stroke:"#7586B0",strokeWidth:1.71429,strokeLinecap:"round",strokeLinejoin:"round"}),jsxRuntime.jsx("path",{d:"M10.3335 6.19065V4.28589",stroke:"#7586B0",strokeWidth:1.71429,strokeLinecap:"round",strokeLinejoin:"round"}),jsxRuntime.jsx("path",{d:"M10.3335 15.7144V13.8096",stroke:"#7586B0",strokeWidth:1.71429,strokeLinecap:"round",strokeLinejoin:"round"})]}),jsxRuntime.jsx("defs",{children:jsxRuntime.jsx("clipPath",{id:"clip0_834_120339",children:jsxRuntime.jsx("rect",{width:20,height:20,fill:"white",transform:"translate(0.333496)"})})})]})),gC=aD;var sD=t=>jsxRuntime.jsx("svg",St(W({width:16,height:16,viewBox:"0 0 16 16",fill:"none",xmlns:"http://www.w3.org/2000/svg"},t),{children:jsxRuntime.jsx("path",{fillRule:"evenodd",clipRule:"evenodd",d:"M6.95392 1.03353C7.1196 1.56038 6.82682 2.12178 6.29997 2.28746C5.79034 2.44773 5.30237 2.68036 4.85175 2.98146C3.76168 3.70982 2.95789 4.79361 2.57732 6.04817C2.19675 7.30273 2.26296 8.65044 2.76466 9.86166C3.26637 11.0729 4.17252 12.0727 5.32873 12.6907C6.48494 13.3087 7.81967 13.5067 9.10549 13.2509C10.3913 12.9951 11.5487 12.3014 12.3804 11.288C13.2121 10.2746 13.6666 9.00413 13.6666 7.69312C13.6666 7.14083 14.1144 6.69312 14.6666 6.69312C15.2189 6.69312 15.6666 7.14083 15.6666 7.69312C15.6666 7.92228 15.6564 8.15052 15.6361 8.37721C15.6465 8.44937 15.6492 8.52379 15.6432 8.59952L15.6392 8.64883C15.6298 8.75932 15.6028 8.86407 15.5612 8.96057C15.3409 10.2743 14.7807 11.5158 13.9264 12.5568C12.8012 13.9279 11.2353 14.8664 9.49568 15.2125C7.75603 15.5585 5.95022 15.2906 4.38594 14.4545C2.82166 13.6184 1.59568 12.2657 0.916905 10.627C0.238131 8.98832 0.148554 7.16495 0.663439 5.4676C1.17832 3.77025 2.26581 2.30394 3.74061 1.31852C4.35023 0.911179 5.01049 0.596408 5.69999 0.379577C6.22684 0.213898 6.78824 0.506683 6.95392 1.03353ZM7.56761 1.27284C7.61434 0.722538 8.09832 0.314306 8.64863 0.361031L8.69791 0.365373C9.24791 0.415584 9.65307 0.902149 9.60286 1.45215C9.55265 2.00214 9.06608 2.4073 8.51608 2.35709L8.47942 2.35386C7.92912 2.30714 7.52089 1.82315 7.56761 1.27284ZM12.4186 2.90891C12.8384 2.55014 13.4697 2.59967 13.8284 3.01954C13.8498 3.04454 13.871 3.06967 13.892 3.09494C14.2454 3.51937 14.1878 4.14991 13.7634 4.50329C13.339 4.85667 12.7084 4.79906 12.355 4.37463C12.3395 4.35592 12.3238 4.33731 12.3079 4.31879C11.9492 3.89892 11.9987 3.26769 12.4186 2.90891ZM8.99998 5.33352C8.99998 4.78124 8.55226 4.33352 7.99998 4.33352C7.44769 4.33352 6.99998 4.78124 6.99998 5.33352V8.00019C6.99998 8.55247 7.44769 9.00019 7.99998 9.00019H10.6666C11.2189 9.00019 11.6666 8.55247 11.6666 8.00019C11.6666 7.4479 11.2189 7.00019 10.6666 7.00019H8.99998V5.33352Z",fill:"#7586B0"})})),im=sD;var lD=t=>jsxRuntime.jsxs("svg",St(W({width:24,height:25,viewBox:"0 0 24 25",fill:"none",xmlns:"http://www.w3.org/2000/svg"},t),{children:[jsxRuntime.jsxs("g",{clipPath:"url(#clip0_834_116282)",children:[jsxRuntime.jsx("path",{d:"M21.4286 5.32483H2.57146C1.62469 5.32483 0.857178 6.09235 0.857178 7.03911V10.4677C0.857178 11.4145 1.62469 12.182 2.57146 12.182H21.4286C22.3754 12.182 23.1429 11.4145 23.1429 10.4677V7.03911C23.1429 6.09235 22.3754 5.32483 21.4286 5.32483Z",stroke:"#7586B0",strokeWidth:1.71429,strokeLinecap:"round",strokeLinejoin:"round"}),jsxRuntime.jsx("path",{d:"M21.4287 12.182V21.6106C21.4287 22.0652 21.248 22.5013 20.9266 22.8227C20.6051 23.1442 20.169 23.3249 19.7144 23.3249H4.28582C3.83116 23.3249 3.39513 23.1442 3.07363 22.8227C2.75215 22.5013 2.57153 22.0652 2.57153 21.6106V12.182",stroke:"#7586B0",strokeWidth:1.71429,strokeLinecap:"round",strokeLinejoin:"round"}),jsxRuntime.jsx("path",{d:"M12 5.32483V23.3248",stroke:"#7586B0",strokeWidth:1.71429,strokeLinecap:"round",strokeLinejoin:"round"}),jsxRuntime.jsx("path",{d:"M17.1429 1.03912L12 5.32484L6.85718 1.03912",stroke:"#7586B0",strokeWidth:1.71429,strokeLinecap:"round",strokeLinejoin:"round"})]}),jsxRuntime.jsx("defs",{children:jsxRuntime.jsx("clipPath",{id:"clip0_834_116282",children:jsxRuntime.jsx("rect",{width:24,height:24,fill:"white",transform:"translate(0 0.182007)"})})})]})),vC=lD;var cD=t=>jsxRuntime.jsx("svg",St(W({width:20,height:20,viewBox:"0 0 20 20",fill:"none",xmlns:"http://www.w3.org/2000/svg"},t),{children:jsxRuntime.jsx("path",{d:"M10.8333 2.5C6.69168 2.5 3.33334 5.85833 3.33334 10H0.833344L4.07501 13.2417L4.13334 13.3583L7.50001 10H5.00001C5.00001 6.775 7.60834 4.16667 10.8333 4.16667C14.0583 4.16667 16.6667 6.775 16.6667 10C16.6667 13.225 14.0583 15.8333 10.8333 15.8333C9.22501 15.8333 7.76668 15.175 6.71668 14.1167L5.53334 15.3C6.89168 16.6583 8.75834 17.5 10.8333 17.5C14.975 17.5 18.3333 14.1417 18.3333 10C18.3333 5.85833 14.975 2.5 10.8333 2.5ZM10 6.66667V10.8333L13.5667 12.95L14.1667 11.9417L11.25 10.2083V6.66667H10Z",fill:"#6678A7"})})),om=cD;var uD=t=>jsxRuntime.jsxs("svg",St(W({width:36,height:36,viewBox:"0 0 36 36",fill:"none",xmlns:"http://www.w3.org/2000/svg"},t),{children:[jsxRuntime.jsx("rect",{width:36,height:36,rx:10,fill:"url(#paint0_linear_834_118583)"}),jsxRuntime.jsx("rect",{width:36,height:36,rx:10,fill:"#F5F6F9"}),jsxRuntime.jsx("path",{fillRule:"evenodd",clipRule:"evenodd",d:"M15.9539 7.70028C16.1196 8.22713 15.8268 8.78853 15.3 8.95421C14.4906 9.20875 13.7155 9.57824 12.9999 10.0564C11.2686 11.2132 9.99197 12.9346 9.38754 14.9271C8.78311 16.9196 8.88826 19.0601 9.68509 20.9838C10.4819 22.9075 11.9211 24.4954 13.7574 25.477C15.5938 26.4585 17.7136 26.7729 19.7558 26.3667C21.798 25.9605 23.6362 24.8588 24.9571 23.2492C26.278 21.6396 27 19.6219 27 17.5397C27 16.9874 27.4477 16.5397 28 16.5397C28.5523 16.5397 29 16.9874 29 17.5397C29 17.8969 28.9826 18.2526 28.9483 18.6056C28.9662 18.6949 28.9722 18.7883 28.9645 18.8837L28.9606 18.9309C28.9496 19.0607 28.9143 19.1825 28.8595 19.2924C28.5513 21.2017 27.7432 23.007 26.5031 24.518C24.8886 26.4852 22.642 27.8318 20.146 28.3283C17.65 28.8248 15.059 28.4405 12.8146 27.2408C10.5702 26.0411 8.81122 24.1004 7.83733 21.7492C6.86343 19.398 6.73491 16.7819 7.47366 14.3465C8.21241 11.9112 9.77272 9.80737 11.8887 8.3935C12.7634 7.80905 13.7107 7.35743 14.7 7.04633C15.2269 6.88065 15.7883 7.17343 15.9539 7.70028ZM17.8497 7.95155C17.8964 7.40125 18.3804 6.99302 18.9307 7.03974L18.9779 7.04385C19.528 7.0929 19.9342 7.57861 19.8851 8.12871C19.8361 8.67881 19.3503 9.085 18.8002 9.03595L18.7615 9.03257C18.2112 8.98585 17.8029 8.50186 17.8497 7.95155ZM22.8579 9.19953C23.172 8.74525 23.7949 8.63161 24.2492 8.9457C24.2751 8.96361 24.3009 8.98162 24.3266 8.99974C24.7782 9.31772 24.8865 9.94155 24.5685 10.3931C24.2505 10.8447 23.6267 10.953 23.1751 10.635C23.1541 10.6202 23.1329 10.6054 23.1118 10.5908C22.6575 10.2767 22.5438 9.6538 22.8579 9.19953ZM26.6058 12.8085C27.1045 12.5712 27.7011 12.7831 27.9384 13.2818C27.9519 13.3102 27.9653 13.3387 27.9786 13.3672C28.2116 13.868 27.9946 14.4628 27.4939 14.6958C26.9931 14.9288 26.3983 14.7117 26.1653 14.211L26.1506 14.1796L26.1324 14.1411C25.8951 13.6424 26.1071 13.0458 26.6058 12.8085ZM19 14.0003C19 13.448 18.5523 13.0003 18 13.0003C17.4477 13.0003 17 13.448 17 14.0003V18.0003C17 18.5526 17.4477 19.0003 18 19.0003H22C22.5523 19.0003 23 18.5526 23 18.0003C23 17.448 22.5523 17.0003 22 17.0003H19V14.0003Z",fill:"#7586B0"}),jsxRuntime.jsx("defs",{children:jsxRuntime.jsx("linearGradient",{id:"paint0_linear_834_118583",x1:35.0204,y1:1.22449,x2:0,y2:36,gradientUnits:"userSpaceOnUse"})})]})),SC=uD;var pD=t=>jsxRuntime.jsx("svg",St(W({width:24,height:24,viewBox:"0 0 24 24",fill:"none",xmlns:"http://www.w3.org/2000/svg"},t),{children:jsxRuntime.jsx("path",{fillRule:"evenodd",clipRule:"evenodd",d:"M9.95394 1.70028C10.1196 2.22713 9.82684 2.78853 9.29999 2.95421C8.49057 3.20875 7.71555 3.57824 6.99987 4.05644C5.26859 5.21324 3.99197 6.93456 3.38754 8.9271C2.78311 10.9196 2.88826 13.0601 3.68509 14.9838C4.48191 16.9075 5.9211 18.4954 7.75743 19.477C9.59377 20.4585 11.7136 20.7729 13.7558 20.3667C15.798 19.9605 17.6362 18.8588 18.9571 17.2492C20.278 15.6396 21 13.6219 21 11.5397C21 10.9874 21.4477 10.5397 22 10.5397C22.5523 10.5397 23 10.9874 23 11.5397C23 11.8969 22.9826 12.2526 22.9483 12.6056C22.9662 12.6949 22.9722 12.7883 22.9645 12.8837L22.9606 12.9309C22.9496 13.0607 22.9143 13.1825 22.8595 13.2924C22.5513 15.2017 21.7432 17.007 20.5031 18.518C18.8886 20.4852 16.642 21.8318 14.146 22.3283C11.65 22.8248 9.05905 22.4405 6.81464 21.2408C4.57023 20.0411 2.81122 18.1004 1.83733 15.7492C0.863434 13.398 0.734911 10.7819 1.47366 8.34653C2.21241 5.91121 3.77272 3.80737 5.88873 2.3935C6.76341 1.80905 7.71072 1.35743 8.70001 1.04633C9.22686 0.880646 9.78826 1.17343 9.95394 1.70028ZM11.8497 1.95155C11.8964 1.40125 12.3804 0.993017 12.9307 1.03974L12.9779 1.04385C13.528 1.0929 13.9342 1.57861 13.8851 2.12871C13.8361 2.67881 13.3503 3.085 12.8002 3.03595L12.7615 3.03257C12.2112 2.98585 11.8029 2.50186 11.8497 1.95155ZM16.8579 3.19953C17.172 2.74525 17.7949 2.63161 18.2492 2.9457C18.2751 2.96361 18.3009 2.98162 18.3266 2.99974C18.7782 3.31772 18.8865 3.94155 18.5685 4.39311C18.2505 4.84467 17.6267 4.95296 17.1751 4.63498C17.1541 4.62016 17.1329 4.60542 17.1118 4.59078C16.6575 4.27669 16.5438 3.6538 16.8579 3.19953ZM20.6058 6.80846C21.1045 6.57117 21.7011 6.78308 21.9384 7.28179C21.9519 7.3102 21.9653 7.33869 21.9786 7.36723C22.2116 7.86796 21.9946 8.46276 21.4939 8.69577C20.9931 8.92877 20.3983 8.71174 20.1653 8.21101L20.1506 8.17957L20.1324 8.14112C19.8951 7.64241 20.1071 7.04576 20.6058 6.80846ZM13 8.00027C13 7.44798 12.5523 7.00027 12 7.00027C11.4477 7.00027 11 7.44798 11 8.00027V12.0003C11 12.5526 11.4477 13.0003 12 13.0003H16C16.5523 13.0003 17 12.5526 17 12.0003C17 11.448 16.5523 11.0003 16 11.0003H13V8.00027Z",fill:"#7586B0"})})),xC=pD;var fD=t=>jsxRuntime.jsxs("svg",St(W({width:36,height:36,viewBox:"0 0 36 36",fill:"none",xmlns:"http://www.w3.org/2000/svg"},t),{children:[jsxRuntime.jsx("rect",{width:36,height:36,rx:10,fill:"#F5F6F9"}),jsxRuntime.jsx("path",{fillRule:"evenodd",clipRule:"evenodd",d:"M9 12C9 10.8954 9.89543 10 11 10H25C26.1046 10 27 10.8954 27 12V26C27 27.1046 26.1046 28 25 28H11C9.89543 28 9 27.1046 9 26V12Z",stroke:"#7586B0",strokeWidth:2,strokeLinecap:"round",strokeLinejoin:"round"}),jsxRuntime.jsx("path",{d:"M22 8V12",stroke:"#7586B0",strokeWidth:2,strokeLinecap:"round",strokeLinejoin:"round"}),jsxRuntime.jsx("path",{d:"M14 8V12",stroke:"#7586B0",strokeWidth:2,strokeLinecap:"round",strokeLinejoin:"round"}),jsxRuntime.jsx("path",{d:"M9 16H27",stroke:"#7586B0",strokeWidth:2,strokeLinecap:"round",strokeLinejoin:"round"}),jsxRuntime.jsx("defs",{children:jsxRuntime.jsxs("linearGradient",{id:"paint0_linear_45_8861",x1:35.0204,y1:1.22449,x2:0,y2:36,gradientUnits:"userSpaceOnUse",children:[jsxRuntime.jsx("stop",{stopColor:"#56ACF6"}),jsxRuntime.jsx("stop",{offset:1,stopColor:"#1559E6"})]})})]})),_C=fD;var hD=t=>jsxRuntime.jsx("svg",St(W({width:24,height:24,viewBox:"0 0 24 24",fill:"none",xmlns:"http://www.w3.org/2000/svg"},t),{children:jsxRuntime.jsxs("g",{id:"trash-2",children:[jsxRuntime.jsx("path",{id:"Shape",d:"M3 6H5H21",stroke:"#F88078",strokeWidth:2,strokeLinecap:"round",strokeLinejoin:"round"}),jsxRuntime.jsx("path",{id:"Shape_2",d:"M20 6C20 5.44772 19.5523 5 19 5C18.4477 5 18 5.44772 18 6H20ZM6 6C6 5.44772 5.55228 5 5 5C4.44772 5 4 5.44772 4 6H6ZM7 6C7 6.55228 7.44772 7 8 7C8.55228 7 9 6.55228 9 6H7ZM15 6C15 6.55228 15.4477 7 16 7C16.5523 7 17 6.55228 17 6H15ZM18 6V20H20V6H18ZM18 20C18 20.5523 17.5523 21 17 21V23C18.6569 23 20 21.6569 20 20H18ZM17 21H7V23H17V21ZM7 21C6.44772 21 6 20.5523 6 20H4C4 21.6569 5.34315 23 7 23V21ZM6 20V6H4V20H6ZM9 6V4H7V6H9ZM9 4C9 3.44772 9.44772 3 10 3V1C8.34315 1 7 2.34315 7 4H9ZM10 3H14V1H10V3ZM14 3C14.5523 3 15 3.44772 15 4H17C17 2.34315 15.6569 1 14 1V3ZM15 4V6H17V4H15Z",fill:"#F88078"}),jsxRuntime.jsx("path",{id:"Shape_3",d:"M10 11V17",stroke:"#F88078",strokeWidth:2,strokeLinecap:"round",strokeLinejoin:"round"}),jsxRuntime.jsx("path",{id:"Shape_4",d:"M14 11V17",stroke:"#F88078",strokeWidth:2,strokeLinecap:"round",strokeLinejoin:"round"})]})})),TC=hD;var gD=t=>jsxRuntime.jsxs("svg",St(W({width:24,height:24,viewBox:"0 0 24 24",fill:"none",xmlns:"http://www.w3.org/2000/svg"},t),{children:[jsxRuntime.jsx("path",{d:"M21.1667 4H2.83333C1.82081 4 1 4.89543 1 6V18C1 19.1046 1.82081 20 2.83333 20H21.1667C22.1792 20 23 19.1046 23 18V6C23 4.89543 22.1792 4 21.1667 4Z",fill:"#C6C6C7"}),jsxRuntime.jsx("path",{opacity:.3,d:"M19.75 16.4286H17.5C17.0125 16.4286 16.75 16.2 16.75 15.6667C16.75 15.1334 17.0125 14.9048 17.5 14.9048H19.75C20.2375 14.9048 20.5 15.1334 20.5 15.6667C20.5 16.2 20.2375 16.4286 19.75 16.4286ZM15.25 16.4286H13C12.5125 16.4286 12.25 16.2 12.25 15.6667C12.25 15.1334 12.5125 14.9048 13 14.9048H15.25C15.7375 14.9048 16 15.1334 16 15.6667C16 16.2 15.7375 16.4286 15.25 16.4286ZM10.75 16.4286H8.5C8.0125 16.4286 7.75 16.2 7.75 15.6667C7.75 15.1334 8.0125 14.9048 8.5 14.9048H10.75C11.2375 14.9048 11.5 15.1334 11.5 15.6667C11.5 16.2 11.2375 16.4286 10.75 16.4286ZM6.25 16.4286H4C3.5125 16.4286 3.25 16.2 3.25 15.6667C3.25 15.1334 3.5125 14.9048 4 14.9048H6.25C6.7375 14.9048 7 15.1334 7 15.6667C7 16.2 6.7375 16.4286 6.25 16.4286Z",fill:"black"})]})),IC=gD;var bD=t=>jsxRuntime.jsx("svg",St(W({width:21,height:20,viewBox:"0 0 21 20",fill:"none",xmlns:"http://www.w3.org/2000/svg"},t),{children:jsxRuntime.jsx("circle",{cx:10.333,cy:10,r:9,fill:"white",stroke:"#327EEE",strokeWidth:2})})),DC=bD;var vD=t=>jsxRuntime.jsx("svg",St(W({width:20,height:20,viewBox:"0 0 20 20",fill:"none",xmlns:"http://www.w3.org/2000/svg"},t),{children:jsxRuntime.jsxs("g",{id:"Group 16159",children:[jsxRuntime.jsx("circle",{id:"Ellipse 5",cx:10,cy:10,r:9.25,fill:"#327EEE",stroke:"#327EEE",strokeWidth:1.5}),jsxRuntime.jsx("path",{id:"Shape",d:"M5 10.3636L8.63667 14L12.637 10L14.6372 8",stroke:"white",strokeWidth:2,strokeLinecap:"round",strokeLinejoin:"round"})]})})),AC=vD;var SD=t=>jsxRuntime.jsx("svg",St(W({width:21,height:20,viewBox:"0 0 21 20",fill:"none",xmlns:"http://www.w3.org/2000/svg"},t),{children:jsxRuntime.jsxs("g",{id:"Stepper indicators",children:[jsxRuntime.jsx("circle",{id:"Ellipse 5",cx:10.667,cy:10,r:9.25,fill:"#B3BCD3",stroke:"#B3BCD3",strokeWidth:1.5}),jsxRuntime.jsx("path",{id:"Shape",d:"M5.66699 10.3636L9.30366 14L13.304 10L15.3042 8",stroke:"white",strokeWidth:2,strokeLinecap:"round",strokeLinejoin:"round"})]})})),OC=SD;var xD=t=>jsxRuntime.jsx("svg",St(W({width:18,height:18,viewBox:"0 0 18 18",fill:"none",xmlns:"http://www.w3.org/2000/svg"},t),{children:jsxRuntime.jsx("path",{d:"M9 3L7.9425 4.0575L12.1275 8.25H3V9.75H12.1275L7.9425 13.9425L9 15L15 9L9 3Z",fill:"white"})})),FC=xD;var ED=t=>jsxRuntime.jsx("svg",St(W({width:20,height:20,viewBox:"0 0 20 20",fill:"none",xmlns:"http://www.w3.org/2000/svg"},t),{children:jsxRuntime.jsx("path",{d:"M15.8337 5.34199L14.6587 4.16699L10.0003 8.82533L5.34199 4.16699L4.16699 5.34199L8.82533 10.0003L4.16699 14.6587L5.34199 15.8337L10.0003 11.1753L14.6587 15.8337L15.8337 14.6587L11.1753 10.0003L15.8337 5.34199Z",fill:"#327EEE"})})),NC=ED;var _D=t=>jsxRuntime.jsx("svg",St(W({width:24,height:24,viewBox:"0 0 24 24",fill:"none",xmlns:"http://www.w3.org/2000/svg"},t),{children:jsxRuntime.jsx("g",{id:"check",children:jsxRuntime.jsx("path",{id:"Shape",d:"M20 7L9 18L4 13",stroke:"#F5F6F9",strokeWidth:2,strokeLinecap:"round",strokeLinejoin:"round"})})})),LC=_D;var TD=t=>jsxRuntime.jsxs("svg",St(W({width:16,height:16,viewBox:"0 0 16 16",fill:"none",xmlns:"http://www.w3.org/2000/svg"},t),{children:[jsxRuntime.jsxs("g",{clipPath:"url(#clip0_1889_12169)",children:[jsxRuntime.jsx("path",{d:"M11.4286 7.42578L8 13.1401",stroke:"#7586B0",strokeWidth:1.71429,strokeLinecap:"round",strokeLinejoin:"round"}),jsxRuntime.jsx("path",{d:"M14.857 13.1412C15.3274 12.0123 15.5118 10.7848 15.3938 9.56751C15.2758 8.35027 14.8592 7.18097 14.1808 6.16341C13.5024 5.14585 12.5833 4.31152 11.5051 3.73446C10.4268 3.1574 9.22281 2.85547 7.99986 2.85547C6.77691 2.85547 5.57288 3.1574 4.49463 3.73446C3.41639 4.31152 2.49729 5.14585 1.81892 6.16341C1.14055 7.18097 0.723889 8.35027 0.605928 9.56751C0.487968 10.7848 0.672354 12.0123 1.14272 13.1412H14.857Z",stroke:"#7586B0",strokeWidth:1.71429,strokeLinecap:"round",strokeLinejoin:"round"})]}),jsxRuntime.jsx("defs",{children:jsxRuntime.jsx("clipPath",{id:"clip0_1889_12169",children:jsxRuntime.jsx("rect",{width:16,height:16,fill:"white"})})})]})),UC=TD;var wD=t=>jsxRuntime.jsx("svg",St(W({width:16,height:16,viewBox:"0 0 18 18",fill:"none",xmlns:"http://www.w3.org/2000/svg"},t),{children:jsxRuntime.jsxs("g",{id:"tag--tags-bookmark-favorite",children:[jsxRuntime.jsx("path",{id:"Vector",d:"M1.26995 11.9426L6.05743 16.7301C6.2305 16.903 6.4651 17.0001 6.7097 17.0001C6.95431 17.0001 7.18891 16.903 7.36198 16.7301L16.8631 7.22895C16.9108 7.18332 16.9478 7.12758 16.9712 7.06583C16.9946 7.00408 17.0039 6.93787 16.9985 6.87205L16.2724 2.15839C16.2664 2.04607 16.2192 1.93992 16.1396 1.86038C16.0601 1.78085 15.9539 1.73357 15.8416 1.72764L11.128 1.00152C11.0622 0.996055 10.9959 1.00538 10.9342 1.0288C10.8724 1.05222 10.8167 1.08916 10.7711 1.1369L1.26995 10.638C1.09709 10.8111 1 11.0457 1 11.2903C1 11.5349 1.09709 11.7695 1.26995 11.9426Z",stroke:"#327EEE",strokeWidth:1.5,strokeLinecap:"round",strokeLinejoin:"round"}),jsxRuntime.jsx("path",{id:"Vector_2",d:"M12.5548 6.05884C12.3916 6.05884 12.2351 5.99401 12.1197 5.87861C12.0043 5.76321 11.9395 5.60669 11.9395 5.44348C11.9395 5.28028 12.0043 5.12376 12.1197 5.00836C12.2351 4.89296 12.3916 4.82812 12.5548 4.82812C12.718 4.82812 12.8745 4.89296 12.9899 5.00836C13.1053 5.12376 13.1702 5.28028 13.1702 5.44348C13.1702 5.60669 13.1053 5.76321 12.9899 5.87861C12.8745 5.99401 12.718 6.05884 12.5548 6.05884Z",stroke:"#327EEE",strokeWidth:1.5,strokeLinecap:"round",strokeLinejoin:"round"})]})})),$C=wD;var kD=t=>jsxRuntime.jsx("svg",St(W({width:24,height:24,viewBox:"0 0 24 24",fill:"none",xmlns:"http://www.w3.org/2000/svg"},t),{children:jsxRuntime.jsx("path",{d:"M12 3V21.0001M3 11.9446H21",stroke:"currentColor",strokeWidth:2,strokeLinecap:"round",strokeLinejoin:"round"})})),jC=kD;var DD=t=>jsxRuntime.jsx("svg",St(W({width:24,height:24,viewBox:"0 0 24 24",fill:"none",xmlns:"http://www.w3.org/2000/svg"},t),{children:jsxRuntime.jsx("path",{d:"M3 12H21",stroke:"currentColor",strokeWidth:2,strokeLinecap:"round",strokeLinejoin:"round"})})),zC=DD;var AD=t=>jsxRuntime.jsx("svg",St(W({width:24,height:24,viewBox:"0 0 24 24",fill:"none",xmlns:"http://www.w3.org/2000/svg"},t),{children:jsxRuntime.jsx("path",{d:"M3 11.1429L9.71572 17.8586C9.79383 17.9367 9.92046 17.9367 9.99856 17.8586L21.8571 6",stroke:"currentColor",strokeWidth:2,strokeLinecap:"round"})})),WC=AD;var RD=Q.div`
4686
4686
  ${({$pathColor:t})=>t&&react.css`
4687
4687
  path {
4688
4688
  fill: ${t};
@@ -4719,7 +4719,7 @@ ${e.o5f}`,e.zBW=r.default`
4719
4719
  display: flex;
4720
4720
  flex-direction: column;
4721
4721
  gap: 16px;
4722
- `;function jD(t,e,n){if(e.entitlementsTitle)return e.entitlementsTitle(t);let r=n?"Includes:":"";return t.basePlan&&(r=`Everything in ${t.basePlan.displayName}${n?", plus:":""}`),r}function YC({plan:t,billingPeriod:e,paywallLocale:n}){var c;let i=(((c=t.pricePoints)==null?void 0:c.filter(p=>p.billingPeriod===e))||[]).filter(p=>(p==null?void 0:p.minUnitQuantity)&&(p==null?void 0:p.minUnitQuantity)>1||(p==null?void 0:p.maxUnitQuantity)).map(p=>{var h;return jsxRuntime.jsx(wb,{feature:p!=null&&p.feature?St(W({},p.feature),{id:p.feature.featureId}):null,minUnitQuantity:p==null?void 0:p.minUnitQuantity,maxUnitQuantity:p==null?void 0:p.maxUnitQuantity},`priceUnitEntitlement-${(h=p==null?void 0:p.feature)==null?void 0:h.displayName}`)}),o=t.entitlements.filter(({isGranted:p})=>p).filter(p=>!(p.hiddenFromWidgets||[]).includes(Mu.Paywall)),s=i.length>0||o.length>0;return jsxRuntime.jsxs(GD,{className:"stigg-plan-entitlements-container",children:[jsxRuntime.jsx(rt,{className:"stigg-plan-entitlements-title",color:"secondary",variant:"h6",bold:true,children:jD(t,n,s)}),i,o.map(p=>{var h;return jsxRuntime.jsx(wb,{displayNameOverride:p.displayNameOverride,feature:p.feature,resetPeriod:p.resetPeriod,hasUnlimitedUsage:p.hasUnlimitedUsage,usageLimit:p.usageLimit,enumValues:p.enumValues,isCustom:p.isCustom},(h=p.feature)==null?void 0:h.id)})]})}var kb=(p=>(p.START_TRIAL="START_TRIAL",p.UPGRADE_TRIAL_TO_PAID="UPGRADE_TRIAL_TO_PAID",p.REQUEST_CUSTOM_PLAN_ACCESS="REQUEST_CUSTOM_PLAN_ACCESS",p.CHANGE_BILLING_PERIOD="CHANGE_BILLING_PERIOD",p.CHANGE_UNIT_QUANTITY="CHANGE_UNIT_QUANTITY",p.UPGRADE_PLAN="UPGRADE_PLAN",p.DOWNGRADE_PLAN="DOWNGRADE_PLAN",p.CANCEL_SCHEDULED_UPDATES="CANCEL_SCHEDULED_UPDATES",p))(kb||{});var am=t=>({left:"flex-start",center:"center",right:"flex-end"})[t],QC=t=>{var h,v,P;let e=sc__default.default(((h=t==null?void 0:t.palette)==null?void 0:h.primary)||"#327EEE"),n=sc__default.default(((P=(v=t==null?void 0:t.palette)==null?void 0:v.text)==null?void 0:P.primary)||"#001E6C"),r=sc__default.default("#4CAF50"),i=sc__default.default("#f44336"),o=sc__default.default("#ff9800"),s=sc__default.default("#2196f3"),c=sc__default.default("#9e9e9e"),p={palette:{primary:e.hex(),primaryDark:e.darken(.3).hex(),primaryLight:e.alpha(.5).toString(),backgroundPaper:"#FFFFFF",backgroundHighlight:"#F5F6F9",backgroundSection:e.alpha(.1).toString(),backgroundButton:e.alpha(.08).toString(),outlinedBorder:"#C4CBDD",outlinedRestingBorder:e.alpha(.5).toString(),outlinedHoverBackground:e.lightness(95).hex(),switchBorder:e.lighten(.1).hex(),switchFill:e.lighten(.5).hex(),switchHandle:e.hex(),warning:"#ed6c02",error:i.hex(),errorDark:i.darken(.3).hex(),success:r.hex(),successDark:r.darken(.3).hex(),white:"#FFFFFF",text:{primary:n.hex(),secondary:n.alpha(.75).toString(),tertiary:n.alpha(.5).toString(),disabled:n.alpha(.35).toString()},statusChips:{success:{background:r.alpha(.15).toString(),text:r.darken(.2).hex(),border:"transparent"},warning:{background:o.alpha(.15).toString(),text:o.darken(.2).hex(),border:"transparent"},error:{background:i.alpha(.15).toString(),text:i.darken(.1).hex(),border:"transparent"},info:{background:s.alpha(.15).toString(),text:s.darken(.2).hex(),border:"transparent"},neutral:{background:c.alpha(.15).toString(),text:c.darken(.2).hex(),border:"transparent"}},progress:{background:"#e0e0e0",low:"#4caf50",medium:"#ff9800",high:"#f44336"}},layout:{planMinWidth:"330px",planMaxWidth:"330px",planMargin:"20px",planPadding:"40px",ctaAlignment:"left",headerAlignment:"left",descriptionAlignment:"left",descriptionMinHeight:"80px",switchBottomSpacing:"40px"},shadows:{light:"0px 2px 1px -1px rgba(0, 0, 0, 0.2), 0px 1px 1px rgba(0, 0, 0, 0.14), 0px 1px 3px rgba(0, 0, 0, 0.12)",popover:"0px 4px 5px -2px rgba(0, 30, 108, 0.2), 0px 7px 10px 1px rgba(0, 30, 108, 0.14), 0px 2px 16px 1px rgba(0, 30, 108, 0.12)"},border:{radius:"10px"},typography:{fontFamily:"custom-font, DM Sans, sans-serif",h1:{fontSize:"32px",fontWeight:"bold",semanticElement:"h1"},h2:{fontSize:"24px",fontWeight:"normal",semanticElement:"h2"},h3:{fontSize:"16px",fontWeight:"normal",semanticElement:"h3"},body:{fontSize:"14px",fontWeight:"normal",semanticElement:"p"},caption:{fontSize:"12px",fontWeight:"normal",semanticElement:"span"}},customCss:""};return zD__default.default(p,t)};var Db=t=>G1__default.default.utc(t).format("MMMM Do, yyyy");function sm({scheduledUpdate:t,subscriptionPrices:e,billingPeriodRange:n,options:r={}}){var s,c;if(!t)return {};let{withDate:i,postfix:o=""}=r;switch(t.subscriptionScheduleType){case Ui.Downgrade:{let p=i;return lodash.isNil(p)&&(n!=null&&n.end)&&(p=!G1__default.default(t.scheduledExecutionTime).isSame(n==null?void 0:n.end,"day")),{line1:jsxRuntime.jsxs(jsxRuntime.Fragment,{children:["Your subscription will be downgraded to the ",jsxRuntime.jsxs("b",{children:[(s=t.targetPackage)==null?void 0:s.displayName," plan"]})," ",p?jsxRuntime.jsxs(jsxRuntime.Fragment,{children:["on ",Db(t.scheduledExecutionTime)]}):o,"."]}),line2:"Until then you still have access to your current plan."}}case Ui.BillingPeriod:{let p=t.scheduleVariables;return {line1:jsxRuntime.jsxs(jsxRuntime.Fragment,{children:["Your billing cycle will change to ",jsxRuntime.jsx("b",{children:(c=p.billingPeriod)==null?void 0:c.toLocaleLowerCase()})," ",i?jsxRuntime.jsxs(jsxRuntime.Fragment,{children:["on ",Db(t.scheduledExecutionTime)]}):o,"."]})}}case Ui.UnitAmount:{let p=t.scheduleVariables,v=lodash.compact(e==null?void 0:e.map(({feature:A})=>A)).find(({id:A})=>A===p.featureId),{featureUnits:P,featureUnitsPlural:x}=v||{},T=p.newUnitAmount===1?P:x,I=jsxRuntime.jsxs(jsxRuntime.Fragment,{children:["Your subscription will be updated to ",jsxRuntime.jsx("b",{children:p.newUnitAmount})," ",T," ",i?jsxRuntime.jsxs(jsxRuntime.Fragment,{children:["on ",Db(t.scheduledExecutionTime)]}):o,"."]}),F=`Until then you still have access to your current ${P} count.`;return {line1:I,line2:F}}default:return {}}}function JC(t){return t.feature&&(t.feature.unitQuantity!==1?t.feature.unitsPlural:t.feature.units)||""}function Ob(t,e){let n=[...t];n.sort((r,i)=>r.upTo?i.upTo?r.upTo-i.upTo:-1:1);for(let r of n)if(r.upTo&&e<=r.upTo)return r;return n[n.length-1]}function ZC(t,e,n){return e===be.Annually&&n?t/12:t}function Ab(t,e,n,r){let i=0;if(t.unitPrice){let o=ZC(t.unitPrice.amount,n,r);i+=o*e;}return t.flatPrice&&(i+=ZC(t.flatPrice.amount,n,r)),i}function Rb(t,e,n,r){let i=e,o=0,s=0,c=[];for(;i>0&&s<t.length;){let h=t[s],{upTo:v}=h;if(lm__default.default(v))c.push({unitQuantity:i,amount:Ab(h,i,n,r)}),i=0;else {let P=v-o,x=Math.min(i,P);c.push({unitQuantity:x,amount:Ab(h,x,n,r)}),i-=x,o=v;}s+=1;}let p=lodash.sum(c.map(({amount:h})=>h));return {breakdown:c,total:p}}function Uu(t,e,n,r){if(!t.tiers)return 0;switch(t.tiersMode){case ic.Volume:{let i=Ob(t.tiers,e);return Ab(i,e,n,r)}case ic.Graduated:return Rb(t.tiers,e,n,r).total;default:return 0}}function Mp(t){return t==null?void 0:t.some(({unitPrice:e,upTo:n})=>e&&!lm__default.default(n))}function tS(t){return t==null?void 0:t.every(({unitPrice:e,upTo:n})=>!e||lm__default.default(n))}function eS(t,e){return (t==null?void 0:t[0].upTo)&&e<=t[0].upTo}function cm({plan:t,billingPeriod:e,currentSubscription:n,currentSubscriptionOverride:r,selectDefaultTierIndex:i}){let o=t.pricePoints.filter(s=>s.billingPeriod===e&&s.isTieredPrice);if(o.length===1){let[s]=o,{featureId:c}=s.feature,p=i?i({plan:t}):0,h=s.tiers[p],v=Mp(s.tiers)?1:h.upTo||1;if(n&&n.plan.id===t.id){let x=n.prices.find(T=>{var I;return T.pricingModel===nn.PerUnit&&T.tiersMode&&((I=T.feature)==null?void 0:I.featureId)===c});x&&(v=x.feature.unitQuantity||1);}if((r==null?void 0:r.planId)===t.id){let x=r.billableFeatures.find(T=>T.featureId===c);x&&(v=x.quantity);}let P={};return P[c]=v,P}return {}}function nS({perUnitQuantityByFeature:t,plan:e,currentSubscription:n,currentSubscriptionOverride:r}){var v,P;if(!n)return 0;let i=n.prices.find(x=>x.pricingModel===nn.PerUnit&&x.tiersMode),o=e.id===(r==null?void 0:r.planId);if(o&&(i=(v=e.pricePoints.find(x=>x.pricingModel===nn.PerUnit&&x.tiersMode))!=null?v:i),!i)return 0;let{featureId:s,unitQuantity:c}=i.feature,p=c;if(o){let x=(P=r==null?void 0:r.billableFeatures)==null?void 0:P.find(T=>T.featureId===s);x&&(p=x.quantity);}if(lm__default.default(p))return 0;let h=t[s];return h<p?-1:h>p?1:0}var ZD=Q(QD__default.default)`
4722
+ `;function jD(t,e,n){if(e.entitlementsTitle)return e.entitlementsTitle(t);let r=n?"Includes:":"";return t.basePlan&&(r=`Everything in ${t.basePlan.displayName}${n?", plus:":""}`),r}function YC({plan:t,billingPeriod:e,paywallLocale:n}){var c;let i=(((c=t.pricePoints)==null?void 0:c.filter(p=>p.billingPeriod===e))||[]).filter(p=>(p==null?void 0:p.minUnitQuantity)&&(p==null?void 0:p.minUnitQuantity)>1||(p==null?void 0:p.maxUnitQuantity)).map(p=>{var h;return jsxRuntime.jsx(wb,{feature:p!=null&&p.feature?St(W({},p.feature),{id:p.feature.featureId}):null,minUnitQuantity:p==null?void 0:p.minUnitQuantity,maxUnitQuantity:p==null?void 0:p.maxUnitQuantity},`priceUnitEntitlement-${(h=p==null?void 0:p.feature)==null?void 0:h.displayName}`)}),o=t.entitlements.filter(({isGranted:p})=>p).filter(p=>!(p.hiddenFromWidgets||[]).includes(Mu.Paywall)),s=i.length>0||o.length>0;return jsxRuntime.jsxs(GD,{className:"stigg-plan-entitlements-container",children:[jsxRuntime.jsx(rt,{className:"stigg-plan-entitlements-title",color:"secondary",variant:"h6",bold:true,children:jD(t,n,s)}),i,o.map(p=>{var h;return jsxRuntime.jsx(wb,{displayNameOverride:p.displayNameOverride,feature:p.feature,resetPeriod:p.resetPeriod,hasUnlimitedUsage:p.hasUnlimitedUsage,usageLimit:p.usageLimit,enumValues:p.enumValues,isCustom:p.isCustom},(h=p.feature)==null?void 0:h.id)})]})}var kb=(p=>(p.START_TRIAL="START_TRIAL",p.UPGRADE_TRIAL_TO_PAID="UPGRADE_TRIAL_TO_PAID",p.REQUEST_CUSTOM_PLAN_ACCESS="REQUEST_CUSTOM_PLAN_ACCESS",p.CHANGE_BILLING_PERIOD="CHANGE_BILLING_PERIOD",p.CHANGE_UNIT_QUANTITY="CHANGE_UNIT_QUANTITY",p.UPGRADE_PLAN="UPGRADE_PLAN",p.DOWNGRADE_PLAN="DOWNGRADE_PLAN",p.CANCEL_SCHEDULED_UPDATES="CANCEL_SCHEDULED_UPDATES",p))(kb||{});var am=t=>({left:"flex-start",center:"center",right:"flex-end"})[t],QC=t=>{var h,v,P;let e=sc__default.default(((h=t==null?void 0:t.palette)==null?void 0:h.primary)||"#327EEE"),n=sc__default.default(((P=(v=t==null?void 0:t.palette)==null?void 0:v.text)==null?void 0:P.primary)||"#001E6C"),r=sc__default.default("#4CAF50"),i=sc__default.default("#f44336"),o=sc__default.default("#ff9800"),s=sc__default.default("#2196f3"),c=sc__default.default("#9e9e9e"),p={palette:{primary:e.hex(),primaryDark:e.darken(.3).hex(),primaryLight:e.alpha(.5).toString(),backgroundPaper:"#FFFFFF",backgroundHighlight:"#F5F6F9",backgroundSection:e.alpha(.1).toString(),backgroundButton:e.alpha(.08).toString(),outlinedBorder:"#C4CBDD",outlinedRestingBorder:e.alpha(.5).toString(),outlinedHoverBackground:e.lightness(95).hex(),switchBorder:e.lighten(.1).hex(),switchFill:e.lighten(.5).hex(),switchHandle:e.hex(),warning:"#ed6c02",error:i.hex(),errorDark:i.darken(.3).hex(),success:r.hex(),successDark:r.darken(.3).hex(),white:"#FFFFFF",text:{primary:n.hex(),secondary:n.alpha(.75).toString(),tertiary:n.alpha(.5).toString(),disabled:n.alpha(.35).toString()},statusChips:{success:{background:r.alpha(.15).toString(),text:r.darken(.2).hex(),border:"transparent"},warning:{background:o.alpha(.15).toString(),text:o.darken(.2).hex(),border:"transparent"},error:{background:i.alpha(.15).toString(),text:i.darken(.1).hex(),border:"transparent"},info:{background:s.alpha(.15).toString(),text:s.darken(.2).hex(),border:"transparent"},neutral:{background:c.alpha(.15).toString(),text:c.darken(.2).hex(),border:"transparent"}},progress:{background:"#e0e0e0",low:"#4caf50",medium:"#ff9800",high:"#f44336"}},layout:{planMinWidth:"330px",planMaxWidth:"330px",planMargin:"20px",planPadding:"40px",ctaAlignment:"left",headerAlignment:"left",descriptionAlignment:"left",descriptionMinHeight:"80px",switchBottomSpacing:"40px"},shadows:{light:"0px 2px 1px -1px rgba(0, 0, 0, 0.2), 0px 1px 1px rgba(0, 0, 0, 0.14), 0px 1px 3px rgba(0, 0, 0, 0.12)",popover:"0px 4px 5px -2px rgba(0, 30, 108, 0.2), 0px 7px 10px 1px rgba(0, 30, 108, 0.14), 0px 2px 16px 1px rgba(0, 30, 108, 0.12)"},border:{radius:"10px"},typography:{fontFamily:"custom-font, DM Sans, sans-serif",h1:{fontSize:"32px",fontWeight:"bold",semanticElement:"h1"},h2:{fontSize:"24px",fontWeight:"normal",semanticElement:"h2"},h3:{fontSize:"16px",fontWeight:"normal",semanticElement:"h3"},body:{fontSize:"14px",fontWeight:"normal",semanticElement:"p"},caption:{fontSize:"12px",fontWeight:"normal",semanticElement:"span"}},customCss:""};return zD__default.default(p,t)};var Db=t=>G1__default.default.utc(t).format("MMMM Do, yyyy");function sm({scheduledUpdate:t,subscriptionPrices:e,billingPeriodRange:n,options:r={}}){var s,c;if(!t)return {};let{withDate:i,postfix:o=""}=r;switch(t.subscriptionScheduleType){case Ui.Downgrade:{let p=i;return lodash.isNil(p)&&(n!=null&&n.end)&&(p=!G1__default.default(t.scheduledExecutionTime).isSame(n==null?void 0:n.end,"day")),{line1:jsxRuntime.jsxs(jsxRuntime.Fragment,{children:["Your subscription will be downgraded to the ",jsxRuntime.jsxs("b",{children:[(s=t.targetPackage)==null?void 0:s.displayName," plan"]})," ",p?jsxRuntime.jsxs(jsxRuntime.Fragment,{children:["on ",Db(t.scheduledExecutionTime)]}):o,"."]}),line2:"Until then you still have access to your current plan."}}case Ui.BillingPeriod:{let p=t.scheduleVariables;return {line1:jsxRuntime.jsxs(jsxRuntime.Fragment,{children:["Your billing cycle will change to ",jsxRuntime.jsx("b",{children:(c=p.billingPeriod)==null?void 0:c.toLocaleLowerCase()})," ",i?jsxRuntime.jsxs(jsxRuntime.Fragment,{children:["on ",Db(t.scheduledExecutionTime)]}):o,"."]})}}case Ui.UnitAmount:{let p=t.scheduleVariables,v=lodash.compact(e==null?void 0:e.map(({feature:A})=>A)).find(({id:A})=>A===p.featureId),{featureUnits:P,featureUnitsPlural:x}=v||{},T=p.newUnitAmount===1?P:x,I=jsxRuntime.jsxs(jsxRuntime.Fragment,{children:["Your subscription will be updated to ",jsxRuntime.jsx("b",{children:p.newUnitAmount})," ",T," ",i?jsxRuntime.jsxs(jsxRuntime.Fragment,{children:["on ",Db(t.scheduledExecutionTime)]}):o,"."]}),R=`Until then you still have access to your current ${P} count.`;return {line1:I,line2:R}}default:return {}}}function JC(t){return t.feature&&(t.feature.unitQuantity!==1?t.feature.unitsPlural:t.feature.units)||""}function Ob(t,e){let n=[...t];n.sort((r,i)=>r.upTo?i.upTo?r.upTo-i.upTo:-1:1);for(let r of n)if(r.upTo&&e<=r.upTo)return r;return n[n.length-1]}function ZC(t,e,n){return e===be.Annually&&n?t/12:t}function Ab(t,e,n,r){let i=0;if(t.unitPrice){let o=ZC(t.unitPrice.amount,n,r);i+=o*e;}return t.flatPrice&&(i+=ZC(t.flatPrice.amount,n,r)),i}function Rb(t,e,n,r){let i=e,o=0,s=0,c=[];for(;i>0&&s<t.length;){let h=t[s],{upTo:v}=h;if(lm__default.default(v))c.push({unitQuantity:i,amount:Ab(h,i,n,r)}),i=0;else {let P=v-o,x=Math.min(i,P);c.push({unitQuantity:x,amount:Ab(h,x,n,r)}),i-=x,o=v;}s+=1;}let p=lodash.sum(c.map(({amount:h})=>h));return {breakdown:c,total:p}}function Uu(t,e,n,r){if(!t.tiers)return 0;switch(t.tiersMode){case ic.Volume:{let i=Ob(t.tiers,e);return Ab(i,e,n,r)}case ic.Graduated:return Rb(t.tiers,e,n,r).total;default:return 0}}function Mp(t){return t==null?void 0:t.some(({unitPrice:e,upTo:n})=>e&&!lm__default.default(n))}function tS(t){return t==null?void 0:t.every(({unitPrice:e,upTo:n})=>!e||lm__default.default(n))}function eS(t,e){return (t==null?void 0:t[0].upTo)&&e<=t[0].upTo}function cm({plan:t,billingPeriod:e,currentSubscription:n,currentSubscriptionOverride:r,selectDefaultTierIndex:i}){let o=t.pricePoints.filter(s=>s.billingPeriod===e&&s.isTieredPrice);if(o.length===1){let[s]=o,{featureId:c}=s.feature,p=i?i({plan:t}):0,h=s.tiers[p],v=Mp(s.tiers)?1:h.upTo||1;if(n&&n.plan.id===t.id){let x=n.prices.find(T=>{var I;return T.pricingModel===nn.PerUnit&&T.tiersMode&&((I=T.feature)==null?void 0:I.featureId)===c});x&&(v=x.feature.unitQuantity||1);}if((r==null?void 0:r.planId)===t.id){let x=r.billableFeatures.find(T=>T.featureId===c);x&&(v=x.quantity);}let P={};return P[c]=v,P}return {}}function nS({perUnitQuantityByFeature:t,plan:e,currentSubscription:n,currentSubscriptionOverride:r}){var v,P;if(!n)return 0;let i=n.prices.find(x=>x.pricingModel===nn.PerUnit&&x.tiersMode),o=e.id===(r==null?void 0:r.planId);if(o&&(i=(v=e.pricePoints.find(x=>x.pricingModel===nn.PerUnit&&x.tiersMode))!=null?v:i),!i)return 0;let{featureId:s,unitQuantity:c}=i.feature,p=c;if(o){let x=(P=r==null?void 0:r.billableFeatures)==null?void 0:P.find(T=>T.featureId===s);x&&(p=x.quantity);}if(lm__default.default(p))return 0;let h=t[s];return h<p?-1:h>p?1:0}var ZD=Q(QD__default.default)`
4723
4723
  margin-left: 10px;
4724
4724
  `,JD=Q.button`
4725
4725
  cursor: ${({$disabled:t})=>t?"default":"pointer"};
@@ -4763,7 +4763,7 @@ ${e.o5f}`,e.zBW=r.default`
4763
4763
  margin-top: 4px;
4764
4764
  align-self: ${({theme:t})=>am(t.stigg.layout.ctaAlignment)};
4765
4765
  width: 100%;
4766
- `;function iS({isNextPlan:t,customer:e,plan:n,billingPeriod:r,isCustomerOnTrial:i,onPlanSelected:o,paywallLocale:s,withTrialLeftRow:c,currentSubscription:p,currentSubscriptionOverride:h,perUnitQuantityByFeature:v}){let P=react.useTheme(),[x,T]=Uv.useState(false),{currentPlan:I,custom:F,downgrade:A,startTrial:O,upgrade:N,startNew:V,switchToBillingPeriod:G,cancelScheduledUpdate:X}=s.planCTAButton,nt=lodash.isFunction(A)?A(n):A,st=lodash.isFunction(N)?N(n):N,U={title:e?n.isLowerThanCurrentPlan?nt:st:V,disabled:false,intentionType:n.isLowerThanCurrentPlan?"DOWNGRADE_PLAN":i?"UPGRADE_TRIAL_TO_PAID":"UPGRADE_PLAN"},j=n.pricingType===Rn.Custom,{line1:ut}=sm({scheduledUpdate:n.scheduledUpdate,options:{withDate:true}});if(n.isTriable&&!n.isCurrentCustomerPlan&&!i)U.title=O(n),U.intentionType="START_TRIAL";else if(n.isCurrentCustomerPlan&&!i)if(r===n.currentCustomerPlanBillingPeriod||n.pricingType&&[Rn.Free,Rn.Custom].includes(n.pricingType))switch(nS({perUnitQuantityByFeature:v,plan:n,currentSubscription:p,currentSubscriptionOverride:h})){case -1:U.intentionType="CHANGE_UNIT_QUANTITY",U.title=nt;break;case 1:U.intentionType="CHANGE_UNIT_QUANTITY",U.title=st;break;default:U.title=I,U.disabled=true;break}else U.title=G(r),U.intentionType="CHANGE_BILLING_PERIOD";else j&&(U.title=typeof F=="function"?F({plan:n,selectedBillingPeriod:r}):F,U.intentionType="REQUEST_CUSTOM_PLAN_ACCESS");t&&n.scheduledUpdate&&(U.disabled=false,U.title=X,U.intentionType="CANCEL_SCHEDULED_UPDATES");let Y=x||U.disabled;return jsxRuntime.jsx(jsxRuntime.Fragment,{children:jsxRuntime.jsx(i2,{className:"stigg-paywall-plan-button-layout",children:t&&ut?jsxRuntime.jsxs(e2,{color:"secondary",variant:"body1",className:"stigg-paywall-schedule-update-text",children:[ut," ",jsxRuntime.jsx(n2,{color:"secondary",onClick:()=>{T(true),Promise.resolve(o(U.intentionType)).finally(()=>T(false));},children:U.title})]}):jsxRuntime.jsxs(jsxRuntime.Fragment,{children:[jsxRuntime.jsxs(JD,{className:"stigg-paywall-plan-button","data-testid":`paywall-card-cta-${n.displayName}`,disabled:Y,$disabled:Y,onClick:()=>{T(true),Promise.resolve(o(U.intentionType)).finally(()=>T(false));},children:[jsxRuntime.jsx(t2,{className:"stigg-paywall-plan-button-text",variant:"h6",color:"primary.main",children:U.title}),x&&jsxRuntime.jsx(ZD,{color:P.stigg.palette.text.disabled,loading:true,size:16})]}),c?jsxRuntime.jsx(r2,{className:"stigg-trial-days-left-text",variant:"h6",color:"secondary",children:n.isCurrentCustomerPlan&&n.trialDaysLeft&&jsxRuntime.jsxs(jsxRuntime.Fragment,{children:[jsxRuntime.jsxs("b",{children:[n.trialDaysLeft," days"]})," left on your free trial"]})}):jsxRuntime.jsx("div",{style:{height:"20px"}})]})})})}var wn=({amount:t,currency:e=Fu.Usd,locale:n,maximumFractionDigits:r=5,minimumFractionDigits:i=0,removeTrailingZero:o})=>{let s=e.toString(),c=o2__default.default(s),p=new Intl.NumberFormat(n,W({maximumFractionDigits:r,minimumFractionDigits:i,style:"currency",currency:s,trailingZeroDisplay:o?"stripIfInteger":"auto"},c?{currencyDisplay:"code"}:{})).format(t||0);return c&&(p=p.replace(s,c)),p=p.replace(/\s/g,""),p};function gr(t,{locale:e,maximumFractionDigits:n}={}){return new Intl.NumberFormat(e,{maximumFractionDigits:n}).format(t)}function oS({planPrices:t,paywallCalculatedPrice:e,selectedBillingPeriod:n,locale:r,shouldShowMonthlyPriceAmount:i,paywallLocale:o,perUnitQuantityByFeature:s}){var A,O,N;let{amount:c,currency:p}=e||t[0],h=c||0,v=t.length===1,P=n===be.Annually&&i?h/12:h,x,T,I=o.price.pricePeriod(i?be.Monthly:be.Annually),F=I;for(let V of t)if(V.isTieredPrice&&V.tiers){let G=(s==null?void 0:s[V.feature.featureId])||1;x=V.tiers,T=JC(V),P+=Uu(V,G,n,i);}if(v){let V=t[0],G=V.blockSize&&V.blockSize>1?`for ${gr(V.blockSize)} ${((A=V.feature)==null?void 0:A.unitsPlural)||((O=V.feature)==null?void 0:O.units)||""}`:`per ${((N=V.feature)==null?void 0:N.units)||""}`;V.pricingModel===nn.PerUnit&&!V.isTieredPrice?F=`${G} ${I}`:V.pricingModel===nn.UsageBased&&(F=`${G}`);}return {price:wn({amount:P,currency:p,locale:r,minimumFractionDigits:2,removeTrailingZero:true}),unit:F,tiers:x,tierUnits:T}}function um(t,e,n,r,i,o){var s;switch(t.pricingType){case Rn.Free:return typeof n.price.free=="function"?n.price.free(t.paywallCurrency):n.price.free;case Rn.Custom:return {price:typeof n.price.custom=="function"?n.price.custom({plan:t,selectedBillingPeriod:e}):n.price.custom};case Rn.Paid:{let c=t.pricePoints.filter(v=>v.billingPeriod===e),p=(s=t.paywallCalculatedPricePoints)==null?void 0:s.find(v=>v.billingPeriod===e);if(!(c!=null&&c.length)&&!p)return {price:n.price.priceNotSet};let h={planPrices:c,paywallCalculatedPrice:p,selectedBillingPeriod:e,perUnitQuantityByFeature:o||{}};return n.price.paid?n.price.paid(St(W({},h),{plan:t})):oS(St(W({},h),{locale:r,shouldShowMonthlyPriceAmount:i,paywallLocale:n}))}default:return {price:""}}}var s2=Q(a2__default.default)`
4766
+ `;function iS({isNextPlan:t,customer:e,plan:n,billingPeriod:r,isCustomerOnTrial:i,onPlanSelected:o,paywallLocale:s,withTrialLeftRow:c,currentSubscription:p,currentSubscriptionOverride:h,perUnitQuantityByFeature:v}){let P=react.useTheme(),[x,T]=Uv.useState(false),{currentPlan:I,custom:R,downgrade:A,startTrial:O,upgrade:N,startNew:V,switchToBillingPeriod:G,cancelScheduledUpdate:X}=s.planCTAButton,nt=lodash.isFunction(A)?A(n):A,st=lodash.isFunction(N)?N(n):N,U={title:e?n.isLowerThanCurrentPlan?nt:st:V,disabled:false,intentionType:n.isLowerThanCurrentPlan?"DOWNGRADE_PLAN":i?"UPGRADE_TRIAL_TO_PAID":"UPGRADE_PLAN"},j=n.pricingType===Rn.Custom,{line1:ut}=sm({scheduledUpdate:n.scheduledUpdate,options:{withDate:true}});if(n.isTriable&&!n.isCurrentCustomerPlan&&!i)U.title=O(n),U.intentionType="START_TRIAL";else if(n.isCurrentCustomerPlan&&!i)if(r===n.currentCustomerPlanBillingPeriod||n.pricingType&&[Rn.Free,Rn.Custom].includes(n.pricingType))switch(nS({perUnitQuantityByFeature:v,plan:n,currentSubscription:p,currentSubscriptionOverride:h})){case -1:U.intentionType="CHANGE_UNIT_QUANTITY",U.title=nt;break;case 1:U.intentionType="CHANGE_UNIT_QUANTITY",U.title=st;break;default:U.title=I,U.disabled=true;break}else U.title=G(r),U.intentionType="CHANGE_BILLING_PERIOD";else j&&(U.title=typeof R=="function"?R({plan:n,selectedBillingPeriod:r}):R,U.intentionType="REQUEST_CUSTOM_PLAN_ACCESS");t&&n.scheduledUpdate&&(U.disabled=false,U.title=X,U.intentionType="CANCEL_SCHEDULED_UPDATES");let Y=x||U.disabled;return jsxRuntime.jsx(jsxRuntime.Fragment,{children:jsxRuntime.jsx(i2,{className:"stigg-paywall-plan-button-layout",children:t&&ut?jsxRuntime.jsxs(e2,{color:"secondary",variant:"body1",className:"stigg-paywall-schedule-update-text",children:[ut," ",jsxRuntime.jsx(n2,{color:"secondary",onClick:()=>{T(true),Promise.resolve(o(U.intentionType)).finally(()=>T(false));},children:U.title})]}):jsxRuntime.jsxs(jsxRuntime.Fragment,{children:[jsxRuntime.jsxs(JD,{className:"stigg-paywall-plan-button","data-testid":`paywall-card-cta-${n.displayName}`,disabled:Y,$disabled:Y,onClick:()=>{T(true),Promise.resolve(o(U.intentionType)).finally(()=>T(false));},children:[jsxRuntime.jsx(t2,{className:"stigg-paywall-plan-button-text",variant:"h6",color:"primary.main",children:U.title}),x&&jsxRuntime.jsx(ZD,{color:P.stigg.palette.text.disabled,loading:true,size:16})]}),c?jsxRuntime.jsx(r2,{className:"stigg-trial-days-left-text",variant:"h6",color:"secondary",children:n.isCurrentCustomerPlan&&n.trialDaysLeft&&jsxRuntime.jsxs(jsxRuntime.Fragment,{children:[jsxRuntime.jsxs("b",{children:[n.trialDaysLeft," days"]})," left on your free trial"]})}):jsxRuntime.jsx("div",{style:{height:"20px"}})]})})})}var wn=({amount:t,currency:e=Fu.Usd,locale:n,maximumFractionDigits:r=5,minimumFractionDigits:i=0,removeTrailingZero:o})=>{let s=e.toString(),c=o2__default.default(s),p=new Intl.NumberFormat(n,W({maximumFractionDigits:r,minimumFractionDigits:i,style:"currency",currency:s,trailingZeroDisplay:o?"stripIfInteger":"auto"},c?{currencyDisplay:"code"}:{})).format(t||0);return c&&(p=p.replace(s,c)),p=p.replace(/\s/g,""),p};function gr(t,{locale:e,maximumFractionDigits:n}={}){return new Intl.NumberFormat(e,{maximumFractionDigits:n}).format(t)}function oS({planPrices:t,paywallCalculatedPrice:e,selectedBillingPeriod:n,locale:r,shouldShowMonthlyPriceAmount:i,paywallLocale:o,perUnitQuantityByFeature:s}){var A,O,N;let{amount:c,currency:p}=e||t[0],h=c||0,v=t.length===1,P=n===be.Annually&&i?h/12:h,x,T,I=o.price.pricePeriod(i?be.Monthly:be.Annually),R=I;for(let V of t)if(V.isTieredPrice&&V.tiers){let G=(s==null?void 0:s[V.feature.featureId])||1;x=V.tiers,T=JC(V),P+=Uu(V,G,n,i);}if(v){let V=t[0],G=V.blockSize&&V.blockSize>1?`for ${gr(V.blockSize)} ${((A=V.feature)==null?void 0:A.unitsPlural)||((O=V.feature)==null?void 0:O.units)||""}`:`per ${((N=V.feature)==null?void 0:N.units)||""}`;V.pricingModel===nn.PerUnit&&!V.isTieredPrice?R=`${G} ${I}`:V.pricingModel===nn.UsageBased&&(R=`${G}`);}return {price:wn({amount:P,currency:p,locale:r,minimumFractionDigits:2,removeTrailingZero:true}),unit:R,tiers:x,tierUnits:T}}function um(t,e,n,r,i,o){var s;switch(t.pricingType){case Rn.Free:return typeof n.price.free=="function"?n.price.free(t.paywallCurrency):n.price.free;case Rn.Custom:return {price:typeof n.price.custom=="function"?n.price.custom({plan:t,selectedBillingPeriod:e}):n.price.custom};case Rn.Paid:{let c=t.pricePoints.filter(v=>v.billingPeriod===e),p=(s=t.paywallCalculatedPricePoints)==null?void 0:s.find(v=>v.billingPeriod===e);if(!(c!=null&&c.length)&&!p)return {price:n.price.priceNotSet};let h={planPrices:c,paywallCalculatedPrice:p,selectedBillingPeriod:e,perUnitQuantityByFeature:o||{}};return n.price.paid?n.price.paid(St(W({},h),{plan:t})):oS(St(W({},h),{locale:r,shouldShowMonthlyPriceAmount:i,paywallLocale:n}))}default:return {price:""}}}var s2=Q(a2__default.default)`
4767
4767
  border-radius: 10px;
4768
4768
  text-transform: none;
4769
4769
 
@@ -4817,7 +4817,7 @@ ${e.o5f}`,e.zBW=r.default`
4817
4817
  `,w2=Q(rt)`
4818
4818
  white-space: normal;
4819
4819
  min-height: 39px;
4820
- `;function I2({plan:t,billingPeriod:e,hasMonthlyPrice:n,hasAnnuallyPrice:r,paywallLocale:i}){var c,p;let o=t.pricePoints.find(h=>h.billingPeriod===e),s=fS;return o&&n&&r&&(s=((p=(c=i.price).billingPeriod)==null?void 0:p.call(c,e))||`, billed ${e.toLowerCase()}`),jsxRuntime.jsx(rt,{as:"span",className:"stigg-price-billing-period-text",variant:"h6",color:"secondary",children:s})}var hS=({showStartingAt:t,withUnitPriceRow:e,withStartingAtRow:n,withTiersRow:r,plan:i,billingPeriod:o,paywallLocale:s,locale:c,hasMonthlyPrice:p,hasAnnuallyPrice:h,perUnitQuantityByFeature:v,setPerUnitQuantityByFeature:P})=>{var G;let{price:x,unit:T,tiers:I,tierUnits:F}=um(i,o,s,c,p,v),A=i.pricePoints.find(X=>X.billingPeriod===o&&X.isTieredPrice),O=A?A.feature.featureId:void 0,N=(G=v[O||""])!=null?G:1,V=X=>{O&&P(nt=>St(W({},nt),{[O]:X}));};return jsxRuntime.jsx(_2,{as:"div",className:"stigg-price-text",children:jsxRuntime.jsxs(jsxRuntime.Fragment,{children:[n&&jsxRuntime.jsx(rt,{style:{minHeight:"20px"},className:"stigg-starting-at-text",variant:"body1",color:"secondary",children:t?s.price.startingAtCaption:fS}),jsxRuntime.jsx(w2,{className:"stigg-price-point",variant:"h1",children:x}),e&&jsxRuntime.jsxs(rt,{as:"div",className:"stigg-price-unit-and-billing-period-text",style:{minHeight:"48px"},children:[jsxRuntime.jsx(T2,{className:"stigg-price-unit-text",as:"span",variant:"h6",color:"secondary",children:T}),jsxRuntime.jsx(I2,{plan:i,billingPeriod:o,hasAnnuallyPrice:h,hasMonthlyPrice:p,paywallLocale:s})]}),r?jsxRuntime.jsx(dm,{componentId:`${i.id}_${O}_tier`,tiers:I,tierUnits:F,tiersMode:A==null?void 0:A.tiersMode,handleChange:V,value:N}):null]})})};var R2=Q(a2__default.default)`
4820
+ `;function I2({plan:t,billingPeriod:e,hasMonthlyPrice:n,hasAnnuallyPrice:r,paywallLocale:i}){var c,p;let o=t.pricePoints.find(h=>h.billingPeriod===e),s=fS;return o&&n&&r&&(s=((p=(c=i.price).billingPeriod)==null?void 0:p.call(c,e))||`, billed ${e.toLowerCase()}`),jsxRuntime.jsx(rt,{as:"span",className:"stigg-price-billing-period-text",variant:"h6",color:"secondary",children:s})}var hS=({showStartingAt:t,withUnitPriceRow:e,withStartingAtRow:n,withTiersRow:r,plan:i,billingPeriod:o,paywallLocale:s,locale:c,hasMonthlyPrice:p,hasAnnuallyPrice:h,perUnitQuantityByFeature:v,setPerUnitQuantityByFeature:P})=>{var G;let{price:x,unit:T,tiers:I,tierUnits:R}=um(i,o,s,c,p,v),A=i.pricePoints.find(X=>X.billingPeriod===o&&X.isTieredPrice),O=A?A.feature.featureId:void 0,N=(G=v[O||""])!=null?G:1,V=X=>{O&&P(nt=>St(W({},nt),{[O]:X}));};return jsxRuntime.jsx(_2,{as:"div",className:"stigg-price-text",children:jsxRuntime.jsxs(jsxRuntime.Fragment,{children:[n&&jsxRuntime.jsx(rt,{style:{minHeight:"20px"},className:"stigg-starting-at-text",variant:"body1",color:"secondary",children:t?s.price.startingAtCaption:fS}),jsxRuntime.jsx(w2,{className:"stigg-price-point",variant:"h1",children:x}),e&&jsxRuntime.jsxs(rt,{as:"div",className:"stigg-price-unit-and-billing-period-text",style:{minHeight:"48px"},children:[jsxRuntime.jsx(T2,{className:"stigg-price-unit-text",as:"span",variant:"h6",color:"secondary",children:T}),jsxRuntime.jsx(I2,{plan:i,billingPeriod:o,hasAnnuallyPrice:h,hasMonthlyPrice:p,paywallLocale:s})]}),r?jsxRuntime.jsx(dm,{componentId:`${i.id}_${O}_tier`,tiers:I,tierUnits:R,tiersMode:A==null?void 0:A.tiersMode,handleChange:V,value:N}):null]})})};var R2=Q(a2__default.default)`
4821
4821
  padding: 0px;
4822
4822
  text-transform: none;
4823
4823
  margin-left: 0px;
@@ -4914,7 +4914,7 @@ ${e.o5f}`,e.zBW=r.default`
4914
4914
  path {
4915
4915
  fill: ${({theme:t})=>t.stigg.palette.text.primary};
4916
4916
  }
4917
- `;function nA({text:t="Next",iconsColor:e}){return jsxRuntime.jsx(tA,{children:jsxRuntime.jsxs(da__default.default,{display:"flex",alignItems:"center",gap:1,children:[jsxRuntime.jsx(eA,{$iconsColor:e}),jsxRuntime.jsx(rt,{color:"primary",variant:"body1",children:t})]})})}function gS({withUnitPriceRow:t,withTiersRow:e,withTrialLeftRow:n,customer:r,plan:i,billingPeriod:o,isHighlighted:s,currentSubscription:c,currentSubscriptionOverride:p,shouldShowDescriptionSection:h,hasMonthlyPrice:v,hasAnnuallyPrice:P,isCustomerOnTrial:x,onPlanSelected:T,paywallLocale:I,locale:F,withStartingAtRow:A,isCustomerInCustomPlan:O,selectDefaultTierIndex:N,hideCompatibleAddons:V}){var pt;let G=i.isNextPlan&&i.isNextPlan(o),X=i.pricePoints.filter(dt=>dt.billingPeriod===o),nt=(pt=i.paywallCalculatedPricePoints)==null?void 0:pt.find(dt=>dt.billingPeriod===o),st=X.length>1&&!!(nt!=null&&nt.additionalChargesMayApply),U=!O||i.pricingType===Rn.Custom,j=null;G?j=jsxRuntime.jsx(nA,{text:"Next plan"}):s&&I.highlightChip&&(j=jsxRuntime.jsx(X2,{className:"stigg-highlight-badge",children:jsxRuntime.jsx(Z2,{className:"stigg-highlight-badge-text",color:"white",bold:true,children:I.highlightChip})}));let[ut,Y]=Uv.useState(cm({plan:i,billingPeriod:o,currentSubscription:c,currentSubscriptionOverride:p,selectDefaultTierIndex:N})),at=dt=>{let mt=Object.keys(ut).map(Ct=>({featureId:Ct,quantity:ut[Ct]}));return T(dt,mt)};return jsxRuntime.jsxs(W2,{className:O2__default.default(`stigg-${i.id}`,"stigg-plan-offering-container",{"stigg-current-plan":i.isCurrentCustomerPlan}),$isHighlighted:s,$isCurrentPlan:i.isCurrentCustomerPlan,children:[j,jsxRuntime.jsxs(J2,{className:"stigg-header-wrapper",children:[jsxRuntime.jsx(Y2,{className:"stigg-plan-header",variant:"h3",children:i.displayName}),h&&jsxRuntime.jsx(K2,{className:"stigg-plan-description",variant:"h6",color:"secondary",children:i.description}),jsxRuntime.jsx(hS,{showStartingAt:st,withUnitPriceRow:t,withStartingAtRow:A,withTiersRow:e,plan:i,billingPeriod:o,paywallLocale:I,locale:F,hasAnnuallyPrice:P,hasMonthlyPrice:v,setPerUnitQuantityByFeature:Y,perUnitQuantityByFeature:ut}),U?jsxRuntime.jsx(iS,{isNextPlan:G,customer:r,plan:i,currentSubscription:c,currentSubscriptionOverride:p,billingPeriod:o,isCustomerOnTrial:x,onPlanSelected:at,paywallLocale:I,withTrialLeftRow:n,perUnitQuantityByFeature:ut}):jsxRuntime.jsx("div",{style:{height:H2}}),jsxRuntime.jsx(Q2,{className:"stigg-plan-header-divider"})]}),jsxRuntime.jsx(YC,{plan:i,billingPeriod:o,paywallLocale:I}),jsxRuntime.jsx(q2,{$planHasEntitlements:i.entitlements.length>0,className:"stigg-addons-container",children:!V&&i.compatibleAddons&&i.compatibleAddons.length>0&&jsxRuntime.jsx(Bb,{addons:i.compatibleAddons,paywallLocale:I})})]})}var iA=Q.div`
4917
+ `;function nA({text:t="Next",iconsColor:e}){return jsxRuntime.jsx(tA,{children:jsxRuntime.jsxs(da__default.default,{display:"flex",alignItems:"center",gap:1,children:[jsxRuntime.jsx(eA,{$iconsColor:e}),jsxRuntime.jsx(rt,{color:"primary",variant:"body1",children:t})]})})}function gS({withUnitPriceRow:t,withTiersRow:e,withTrialLeftRow:n,customer:r,plan:i,billingPeriod:o,isHighlighted:s,currentSubscription:c,currentSubscriptionOverride:p,shouldShowDescriptionSection:h,hasMonthlyPrice:v,hasAnnuallyPrice:P,isCustomerOnTrial:x,onPlanSelected:T,paywallLocale:I,locale:R,withStartingAtRow:A,isCustomerInCustomPlan:O,selectDefaultTierIndex:N,hideCompatibleAddons:V}){var pt;let G=i.isNextPlan&&i.isNextPlan(o),X=i.pricePoints.filter(dt=>dt.billingPeriod===o),nt=(pt=i.paywallCalculatedPricePoints)==null?void 0:pt.find(dt=>dt.billingPeriod===o),st=X.length>1&&!!(nt!=null&&nt.additionalChargesMayApply),U=!O||i.pricingType===Rn.Custom,j=null;G?j=jsxRuntime.jsx(nA,{text:"Next plan"}):s&&I.highlightChip&&(j=jsxRuntime.jsx(X2,{className:"stigg-highlight-badge",children:jsxRuntime.jsx(Z2,{className:"stigg-highlight-badge-text",color:"white",bold:true,children:I.highlightChip})}));let[ut,Y]=Uv.useState(cm({plan:i,billingPeriod:o,currentSubscription:c,currentSubscriptionOverride:p,selectDefaultTierIndex:N})),at=dt=>{let mt=Object.keys(ut).map(Ct=>({featureId:Ct,quantity:ut[Ct]}));return T(dt,mt)};return jsxRuntime.jsxs(W2,{className:O2__default.default(`stigg-${i.id}`,"stigg-plan-offering-container",{"stigg-current-plan":i.isCurrentCustomerPlan}),$isHighlighted:s,$isCurrentPlan:i.isCurrentCustomerPlan,children:[j,jsxRuntime.jsxs(J2,{className:"stigg-header-wrapper",children:[jsxRuntime.jsx(Y2,{className:"stigg-plan-header",variant:"h3",children:i.displayName}),h&&jsxRuntime.jsx(K2,{className:"stigg-plan-description",variant:"h6",color:"secondary",children:i.description}),jsxRuntime.jsx(hS,{showStartingAt:st,withUnitPriceRow:t,withStartingAtRow:A,withTiersRow:e,plan:i,billingPeriod:o,paywallLocale:I,locale:R,hasAnnuallyPrice:P,hasMonthlyPrice:v,setPerUnitQuantityByFeature:Y,perUnitQuantityByFeature:ut}),U?jsxRuntime.jsx(iS,{isNextPlan:G,customer:r,plan:i,currentSubscription:c,currentSubscriptionOverride:p,billingPeriod:o,isCustomerOnTrial:x,onPlanSelected:at,paywallLocale:I,withTrialLeftRow:n,perUnitQuantityByFeature:ut}):jsxRuntime.jsx("div",{style:{height:H2}}),jsxRuntime.jsx(Q2,{className:"stigg-plan-header-divider"})]}),jsxRuntime.jsx(YC,{plan:i,billingPeriod:o,paywallLocale:I}),jsxRuntime.jsx(q2,{$planHasEntitlements:i.entitlements.length>0,className:"stigg-addons-container",children:!V&&i.compatibleAddons&&i.compatibleAddons.length>0&&jsxRuntime.jsx(Bb,{addons:i.compatibleAddons,paywallLocale:I})})]})}var iA=Q.div`
4918
4918
  height: 40px;
4919
4919
  padding: 0 20px;
4920
4920
  margin-bottom: ${({theme:t})=>t.stigg.layout.switchBottomSpacing};
@@ -4967,7 +4967,7 @@ ${e.o5f}`,e.zBW=r.default`
4967
4967
  display: flex;
4968
4968
  flex-direction: column;
4969
4969
  align-items: center;
4970
- `,TS=({plans:t,customer:e,currentSubscription:n,highlightedPlanId:r,selectedBillingPeriod:i,onBillingPeriodChanged:o,availableBillingPeriods:s,isCustomerOnTrial:c,onPlanSelected:p,paywallLocale:h,locale:v,shouldHidePlan:P,selectDefaultTierIndex:x,currentSubscriptionOverride:T,hideCompatibleAddons:I,showWatermark:F})=>{let A=PS(t),O=t.some(Y=>!!Y.description),N=jb(t,be.Monthly),V=jb(t,be.Annually),G=_S(t,i,P),X=Uv.useCallback((Y,at,pt)=>p({plan:Y,customer:e,subscription:n,intentionType:at,selectedBillingPeriod:i,billableFeatures:pt}),[e,i,n,p]),nt=!!n&&n.plan.pricingType===Rn.Custom,st=Uv.useMemo(()=>G.some(Y=>{var dt;let at=Y.pricePoints.filter(mt=>mt.billingPeriod===i),pt=(dt=Y.paywallCalculatedPricePoints)==null?void 0:dt.find(mt=>mt.billingPeriod===i);return at.length>1&&!!(pt!=null&&pt.additionalChargesMayApply)}),[i,G]),U=Uv.useMemo(()=>G.some(Y=>!!um(Y,i,h,v,N).unit),[i,N,v,h,G]),j=Uv.useMemo(()=>!nt&&G.some(Y=>{let at=cm({plan:Y,billingPeriod:i,currentSubscription:n,currentSubscriptionOverride:T});return Object.values(at).length>0}),[i,n,T,nt,G]),ut=G.some(Y=>Y.isCurrentCustomerPlan&&Y.trialDaysLeft);return jsxRuntime.jsx(hA,{className:"stigg-paywall-container",children:jsxRuntime.jsxs(mA,{className:"stigg-paywall-layout",children:[jsxRuntime.jsx(bS,{onBillingPeriodChanged:o,selectedBillingPeriod:i,availableBillingPeriods:s,discountRate:A}),jsxRuntime.jsx(fA,{className:"stigg-paywall-plans-layout",children:G.map(Y=>jsxRuntime.jsx(gS,{withUnitPriceRow:U,withTiersRow:j,withTrialLeftRow:ut,shouldShowDescriptionSection:O,hasMonthlyPrice:N,hasAnnuallyPrice:V,plan:Y,withStartingAtRow:st,currentSubscription:n,currentSubscriptionOverride:T,billingPeriod:i,isHighlighted:Y.id===r,isCustomerOnTrial:c,onPlanSelected:(at,pt)=>X(Y,at,pt),paywallLocale:h,locale:v,customer:e,isCustomerInCustomPlan:nt,selectDefaultTierIndex:x,hideCompatibleAddons:I},Y.id))}),jsxRuntime.jsx(so,{source:"paywall",align:"end",style:{marginTop:16},showWatermark:F})]})})};var zb=class{error(e,n,...r){console.error(e,n||{},r);}log(e,n){console.log(e,n||{});}debug(e,n){console.debug(e,n||{});}},tl=new zb;function wS(t,e,n){let r=t.flatMap(c=>c.pricePoints).map(c=>c.billingPeriod),i=lodash.countBy(r),o=lodash.uniq(r),s;if(n&&o.includes(n))s=n;else if(e){let c=e.find(p=>p.status===bi.Active);c&&c.prices.length>0&&(s=c==null?void 0:c.prices[0].billingPeriod);}return s||(s=(i[be.Monthly]||0)>(i[be.Annually]||0)?be.Monthly:be.Annually),{defaultBillingPeriod:s,availableBillingPeriods:o}}function kS(t){return G1__default.default.utc(t).diff(G1__default.default.utc(),"days",false)+1}var fm={h1:{fontSize:"24px",fontWeight:"bold",semanticElement:"h1"},h2:{fontSize:"16px",fontWeight:"normal",semanticElement:"h2"},h3:{fontSize:"16px",fontWeight:"normal",semanticElement:"h3"},body:{fontSize:"14px",fontWeight:"normal",semanticElement:"p"}};function el(t,e="px"){if(t)return `${t}${e}`}function hm(t){if(!t)return "normal";switch(t){case gb.Normal:return "normal";case gb.Bold:return "bold";default:return "normal"}}function Gp(t,e){var r,i,o,s,c,p,h,v;let n=e||{h1:{fontSize:"32px",fontWeight:"bold",semanticElement:"h1"},h2:{fontSize:"24px",fontWeight:"normal",semanticElement:"h2"},h3:{fontSize:"16px",fontWeight:"normal",semanticElement:"h3"},body:{fontSize:"14px",fontWeight:"normal",semanticElement:"p"}};return {fontFamilyUrl:(t==null?void 0:t.fontFamily)||void 0,h1:{fontSize:el((r=t==null?void 0:t.h1)==null?void 0:r.fontSize)||n.h1.fontSize,fontWeight:hm((i=t==null?void 0:t.h1)==null?void 0:i.fontWeight)||n.h1.fontWeight,semanticElement:n.h1.semanticElement},h2:{fontSize:el((o=t==null?void 0:t.h2)==null?void 0:o.fontSize)||n.h2.fontSize,fontWeight:hm((s=t==null?void 0:t.h2)==null?void 0:s.fontWeight)||n.h2.fontWeight,semanticElement:n.h2.semanticElement},h3:{fontSize:el((c=t==null?void 0:t.h3)==null?void 0:c.fontSize)||n.h3.fontSize,fontWeight:hm((p=t==null?void 0:t.h3)==null?void 0:p.fontWeight)||n.h3.fontWeight,semanticElement:n.h3.semanticElement},body:{fontSize:el((h=t==null?void 0:t.body)==null?void 0:h.fontSize)||n.body.fontSize,fontWeight:hm((v=t==null?void 0:t.body)==null?void 0:v.fontWeight)||n.body.fontWeight,semanticElement:n.body.semanticElement}}}function Hb(t){if(t)switch(t){case Jh.Left:return "left";case Jh.Center:return "center";case Jh.Right:return "right";default:return}}function DS(t){let{palette:e,customCss:n,typography:r}=t;return {palette:{primary:(e==null?void 0:e.primary)||void 0,backgroundPaper:(e==null?void 0:e.paywallBackgroundColor)||void 0,outlinedBorder:(e==null?void 0:e.borderColor)||void 0,backgroundHighlight:(e==null?void 0:e.currentPlanBackground)||void 0,text:{primary:(e==null?void 0:e.textColor)||void 0}},typography:Gp(r),customCss:n||void 0}}function AS(t){let{palette:e,layout:n,customCss:r,typography:i}=t;return {customCss:r||void 0,palette:{primary:(e==null?void 0:e.primary)||void 0,backgroundPaper:(e==null?void 0:e.backgroundColor)||void 0,outlinedBorder:(e==null?void 0:e.borderColor)||void 0,backgroundHighlight:(e==null?void 0:e.currentPlanBackground)||void 0,text:{primary:(e==null?void 0:e.textColor)||void 0}},typography:Gp(i),layout:{ctaAlignment:Hb(n==null?void 0:n.alignment),headerAlignment:Hb(n==null?void 0:n.alignment),descriptionAlignment:Hb(n==null?void 0:n.alignment),planMaxWidth:el(n==null?void 0:n.planWidth),planMinWidth:el(n==null?void 0:n.planWidth),planMargin:el(n==null?void 0:n.planMargin),planPadding:el(n==null?void 0:n.planPadding)}}}function OS(t){let{palette:e,typography:n,customCss:r}=t;return {palette:{primary:(e==null?void 0:e.primary)||void 0,backgroundPaper:(e==null?void 0:e.backgroundColor)||void 0,outlinedBorder:(e==null?void 0:e.borderColor)||void 0,text:{primary:(e==null?void 0:e.textColor)||void 0},backgroundHighlight:(e==null?void 0:e.summaryBackgroundColor)||void 0},typography:Gp(n,fm),customCss:r||void 0}}function CA(t){let e=true,n=(t==null?void 0:t.find(o=>o.status===bi.InTrial))||null,r=n==null?void 0:n.plan,i=n!=null&&n.trialEndDate?kS(n.trialEndDate):void 0;return r||(e=false,n=(t==null?void 0:t.find(o=>o.status===bi.Active))||null,r=n==null?void 0:n.plan),{currentSubscription:n,currentPlan:r,isCustomerOnTrial:e,trialDaysLeft:i}}function FS(t,e,n){var G,X;let{plans:r,currency:i,configuration:o,customer:s,activeSubscriptions:c,paywallCalculatedPricePoints:p}=t||{},{currentSubscription:h,currentPlan:v,isCustomerOnTrial:P,trialDaysLeft:x}=CA(c),T=n==null?void 0:n({currentSubscription:h}),I=(h==null?void 0:h.scheduledUpdates)||[],F=(G=h==null?void 0:h.price)==null?void 0:G.billingPeriod,A=I.find(({subscriptionScheduleType:nt})=>nt===Ui.Downgrade),O=I.find(({subscriptionScheduleType:nt})=>nt===Ui.BillingPeriod),N=fx__default.default(r,nt=>nt.order).map(nt=>{var ut;let st=(ut=s==null?void 0:s.eligibleForTrial)==null?void 0:ut.find(Y=>Y.productId===nt.product.id),U=T!=null&&T.planId?(T==null?void 0:T.planId)===nt.id:nt.id===(v==null?void 0:v.id),j=Y=>{var mt;let at=A==null?void 0:A.scheduleVariables,pt=O==null?void 0:O.scheduleVariables,dt=nt.pricePoints.some(Ct=>Ct.billingPeriod===Y);return A?((mt=A.targetPackage)==null?void 0:mt.refId)===nt.id&&(!dt||at.billingPeriod===Y):O&&U?pt.billingPeriod===Y:false};return St(W({},nt),{paywallCalculatedPricePoints:p==null?void 0:p.filter(Y=>Y.planId===nt.id),isTriable:!lm__default.default(nt.defaultTrialConfig)&&(!st||st.eligible),isCurrentCustomerPlan:U,currentCustomerPlanBillingPeriod:F,isUpcomingPlan:false,trialDaysLeft:x,isNextPlan:j,paywallCurrency:i,scheduledUpdate:A||O})});if(r&&v){let nt=v&&((X=r==null?void 0:r.find(st=>st.id===(v==null?void 0:v.id)))==null?void 0:X.order);lm__default.default(nt)||(N=N.map(st=>St(W({},st),{isLowerThanCurrentPlan:nt>st.order})),e&&(N=N.filter(st=>st.order>=nt)));}let V=o?AS(o):void 0;return {currentPlan:v,currentSubscription:h,currentSubscriptionOverride:T,isCustomerOnTrial:P,plans:N,paywallConfiguration:V}}var NS="7.10.0";var LS="@stigg/react-sdk";var jp=Uv__default.default.createContext(null);jp.displayName="StiggContext";var _A="en-US",TA=({apiKey:t,baseUri:e,baseEdgeUri:n,enableEdge:r,customerId:i,customerToken:o,resourceId:s,theme:c,locale:p,cacheTtlMs:h,useEntitlementPolling:v,entitlementPollingInterval:P,entitlementsFallback:x,stiggClient:T,children:I,offline:F,clientName:A=LS,clientVersion:O=NS})=>{let N=Uv.useRef(t),V={apiKey:t,customerId:i,customerToken:o,resourceId:s,baseUri:e,baseEdgeUri:n,enableEdge:r,entitlementsFallback:x,cacheTtlMs:h,useEntitlementPolling:v,entitlementPollingInterval:P,clientName:A,clientVersion:O,offline:F},[G,X]=Uv.useState(()=>({stigg:T!=null?T:bb.initialize(St(W({},V),{lazyLoad:true})),locale:p||_A,isInitialized:false,theme:c,refreshData:()=>ce(null,null,function*(){X(nt=>St(W({},nt),{customerPortalUpdatedAt:new Date})),yield G.stigg.refresh();})}));return Uv.useEffect(()=>{let nt=true,st=Y=>{nt&&X(Y);},U=()=>st(Y=>St(W({},Y),{updatedAt:new Date})),j=Y=>st(at=>(at.stigg&&at.stigg.removeListener("entitlementsUpdated",U),Y.addListener("entitlementsUpdated",U),St(W({},at),{stigg:Y,isInitialized:true,updatedAt:new Date})));return ce(null,null,function*(){let Y=G.stigg;t!==N.current&&(tl.log("Updating stigg client",{apiKey:t}),N.current=t,Y=bb.initialize(W({},V)),st(at=>St(W({},at),{isInitialized:false,updatedAt:new Date}))),yield Y.waitForInitialization(),j(Y);}),()=>{nt=false,G.stigg.removeListener("entitlementsUpdated",U),G.stigg.clearCustomer();}},[t]),Uv.useEffect(()=>{let nt=G.stigg;i?nt.setCustomerId(i,o,s):nt.clearCustomer();},[i,o,s]),Uv.useEffect(()=>{X(nt=>St(W({},nt),{theme:c}));},[c]),jsxRuntime.jsx(jp.Provider,{value:G,children:jsxRuntime.jsx(nl.SkeletonTheme,{baseColor:"#F5F6F9",highlightColor:"#e5e6ea",children:I})})};function ve(t){let{optional:e}=t||{},n=Uv.useContext(jp);if(!n&&!e)throw new Error("Could not find Stigg context; You need to wrap your app in an <StiggProvider> component.");return n}function US({productId:t,resourceId:e,showOnlyEligiblePlans:n,billingCountryCode:r,preferredBillingPeriod:i,currentSubscriptionOverrideFn:o}){let{stigg:s,locale:c}=ve(),[p,h]=Uv.useState(be.Annually),[v,P]=Uv.useState([]),[x,T]=Uv.useState(null),[I,F]=Uv.useState(true);Uv.useEffect(()=>{ce(null,null,function*(){try{F(!0),yield s.waitForInitialization();let N=yield s.getPaywall({productId:t,resourceId:e,billingCountryCode:r}),{availableBillingPeriods:V,defaultBillingPeriod:G}=wS(N.plans,N.activeSubscriptions,i);T(N),P(V),h(G);}catch(N){tl.error(`Failed to load paywall ${N==null?void 0:N.message}`,N);}finally{F(false);}});},[s,t,s.isCustomerLoaded,r,e,i]);let A=FS(x,n,o);return W({customer:(x==null?void 0:x.customer)||null,isLoading:I,selectedBillingPeriod:p,setSelectedBillingPeriod:h,availableBillingPeriods:v,locale:c,configuration:A.paywallConfiguration,showWatermark:s.getShowWatermark()},A)}function $S(t){return zD__default.default({highlightChip:"Recommended",addonsTitle:"Available add-ons:",planCTAButton:{upgrade:"Upgrade",downgrade:"Downgrade",startTrial:n=>{var r;return `Start ${(r=n.defaultTrialConfig)==null?void 0:r.duration} day trial`},custom:"Contact us",currentPlan:"Current plan",startNew:"Get started",switchToBillingPeriod:n=>n===be.Monthly?"Switch to monthly billing":"Switch to annual billing",cancelScheduledUpdate:"Cancel"},price:{startingAtCaption:"Starts at",pricePeriod:n=>n===be.Monthly?"/ month":"/ year",free:n=>({price:`${n==null?void 0:n.symbol}0`}),custom:"Custom",priceNotSet:"Price not set"}},t)}var DA=t=>jsxRuntime.jsx("svg",St(W({width:15,height:11,viewBox:"0 0 15 11",fill:"none",xmlns:"http://www.w3.org/2000/svg"},t),{children:jsxRuntime.jsx("path",{d:"M5.59 7.9899L2.125 4.5249C1.73524 4.13514 1.10365 4.13402 0.712509 4.52241V4.52241C0.319409 4.91274 0.318286 5.54819 0.710005 5.9399L5.59 10.8199L14.2948 2.11513C14.6843 1.72565 14.6843 1.09417 14.2948 0.704691V0.704691C13.9055 0.315381 13.2743 0.315184 12.8848 0.70425L5.59 7.9899Z",fill:"#B2BBD3"})})),jS=DA;var AA=Q.div`
4970
+ `,TS=({plans:t,customer:e,currentSubscription:n,highlightedPlanId:r,selectedBillingPeriod:i,onBillingPeriodChanged:o,availableBillingPeriods:s,isCustomerOnTrial:c,onPlanSelected:p,paywallLocale:h,locale:v,shouldHidePlan:P,selectDefaultTierIndex:x,currentSubscriptionOverride:T,hideCompatibleAddons:I,showWatermark:R})=>{let A=PS(t),O=t.some(Y=>!!Y.description),N=jb(t,be.Monthly),V=jb(t,be.Annually),G=_S(t,i,P),X=Uv.useCallback((Y,at,pt)=>p({plan:Y,customer:e,subscription:n,intentionType:at,selectedBillingPeriod:i,billableFeatures:pt}),[e,i,n,p]),nt=!!n&&n.plan.pricingType===Rn.Custom,st=Uv.useMemo(()=>G.some(Y=>{var dt;let at=Y.pricePoints.filter(mt=>mt.billingPeriod===i),pt=(dt=Y.paywallCalculatedPricePoints)==null?void 0:dt.find(mt=>mt.billingPeriod===i);return at.length>1&&!!(pt!=null&&pt.additionalChargesMayApply)}),[i,G]),U=Uv.useMemo(()=>G.some(Y=>!!um(Y,i,h,v,N).unit),[i,N,v,h,G]),j=Uv.useMemo(()=>!nt&&G.some(Y=>{let at=cm({plan:Y,billingPeriod:i,currentSubscription:n,currentSubscriptionOverride:T});return Object.values(at).length>0}),[i,n,T,nt,G]),ut=G.some(Y=>Y.isCurrentCustomerPlan&&Y.trialDaysLeft);return jsxRuntime.jsx(hA,{className:"stigg-paywall-container",children:jsxRuntime.jsxs(mA,{className:"stigg-paywall-layout",children:[jsxRuntime.jsx(bS,{onBillingPeriodChanged:o,selectedBillingPeriod:i,availableBillingPeriods:s,discountRate:A}),jsxRuntime.jsx(fA,{className:"stigg-paywall-plans-layout",children:G.map(Y=>jsxRuntime.jsx(gS,{withUnitPriceRow:U,withTiersRow:j,withTrialLeftRow:ut,shouldShowDescriptionSection:O,hasMonthlyPrice:N,hasAnnuallyPrice:V,plan:Y,withStartingAtRow:st,currentSubscription:n,currentSubscriptionOverride:T,billingPeriod:i,isHighlighted:Y.id===r,isCustomerOnTrial:c,onPlanSelected:(at,pt)=>X(Y,at,pt),paywallLocale:h,locale:v,customer:e,isCustomerInCustomPlan:nt,selectDefaultTierIndex:x,hideCompatibleAddons:I},Y.id))}),jsxRuntime.jsx(so,{source:"paywall",align:"end",style:{marginTop:16},showWatermark:R})]})})};var zb=class{error(e,n,...r){console.error(e,n||{},r);}log(e,n){console.log(e,n||{});}debug(e,n){console.debug(e,n||{});}},tl=new zb;function wS(t,e,n){let r=t.flatMap(c=>c.pricePoints).map(c=>c.billingPeriod),i=lodash.countBy(r),o=lodash.uniq(r),s;if(n&&o.includes(n))s=n;else if(e){let c=e.find(p=>p.status===bi.Active);c&&c.prices.length>0&&(s=c==null?void 0:c.prices[0].billingPeriod);}return s||(s=(i[be.Monthly]||0)>(i[be.Annually]||0)?be.Monthly:be.Annually),{defaultBillingPeriod:s,availableBillingPeriods:o}}function kS(t){return G1__default.default.utc(t).diff(G1__default.default.utc(),"days",false)+1}var fm={h1:{fontSize:"24px",fontWeight:"bold",semanticElement:"h1"},h2:{fontSize:"16px",fontWeight:"normal",semanticElement:"h2"},h3:{fontSize:"16px",fontWeight:"normal",semanticElement:"h3"},body:{fontSize:"14px",fontWeight:"normal",semanticElement:"p"}};function el(t,e="px"){if(t)return `${t}${e}`}function hm(t){if(!t)return "normal";switch(t){case gb.Normal:return "normal";case gb.Bold:return "bold";default:return "normal"}}function Gp(t,e){var r,i,o,s,c,p,h,v;let n=e||{h1:{fontSize:"32px",fontWeight:"bold",semanticElement:"h1"},h2:{fontSize:"24px",fontWeight:"normal",semanticElement:"h2"},h3:{fontSize:"16px",fontWeight:"normal",semanticElement:"h3"},body:{fontSize:"14px",fontWeight:"normal",semanticElement:"p"}};return {fontFamilyUrl:(t==null?void 0:t.fontFamily)||void 0,h1:{fontSize:el((r=t==null?void 0:t.h1)==null?void 0:r.fontSize)||n.h1.fontSize,fontWeight:hm((i=t==null?void 0:t.h1)==null?void 0:i.fontWeight)||n.h1.fontWeight,semanticElement:n.h1.semanticElement},h2:{fontSize:el((o=t==null?void 0:t.h2)==null?void 0:o.fontSize)||n.h2.fontSize,fontWeight:hm((s=t==null?void 0:t.h2)==null?void 0:s.fontWeight)||n.h2.fontWeight,semanticElement:n.h2.semanticElement},h3:{fontSize:el((c=t==null?void 0:t.h3)==null?void 0:c.fontSize)||n.h3.fontSize,fontWeight:hm((p=t==null?void 0:t.h3)==null?void 0:p.fontWeight)||n.h3.fontWeight,semanticElement:n.h3.semanticElement},body:{fontSize:el((h=t==null?void 0:t.body)==null?void 0:h.fontSize)||n.body.fontSize,fontWeight:hm((v=t==null?void 0:t.body)==null?void 0:v.fontWeight)||n.body.fontWeight,semanticElement:n.body.semanticElement}}}function Hb(t){if(t)switch(t){case Jh.Left:return "left";case Jh.Center:return "center";case Jh.Right:return "right";default:return}}function DS(t){let{palette:e,customCss:n,typography:r}=t;return {palette:{primary:(e==null?void 0:e.primary)||void 0,backgroundPaper:(e==null?void 0:e.paywallBackgroundColor)||void 0,outlinedBorder:(e==null?void 0:e.borderColor)||void 0,backgroundHighlight:(e==null?void 0:e.currentPlanBackground)||void 0,text:{primary:(e==null?void 0:e.textColor)||void 0}},typography:Gp(r),customCss:n||void 0}}function AS(t){let{palette:e,layout:n,customCss:r,typography:i}=t;return {customCss:r||void 0,palette:{primary:(e==null?void 0:e.primary)||void 0,backgroundPaper:(e==null?void 0:e.backgroundColor)||void 0,outlinedBorder:(e==null?void 0:e.borderColor)||void 0,backgroundHighlight:(e==null?void 0:e.currentPlanBackground)||void 0,text:{primary:(e==null?void 0:e.textColor)||void 0}},typography:Gp(i),layout:{ctaAlignment:Hb(n==null?void 0:n.alignment),headerAlignment:Hb(n==null?void 0:n.alignment),descriptionAlignment:Hb(n==null?void 0:n.alignment),planMaxWidth:el(n==null?void 0:n.planWidth),planMinWidth:el(n==null?void 0:n.planWidth),planMargin:el(n==null?void 0:n.planMargin),planPadding:el(n==null?void 0:n.planPadding)}}}function OS(t){let{palette:e,typography:n,customCss:r}=t;return {palette:{primary:(e==null?void 0:e.primary)||void 0,backgroundPaper:(e==null?void 0:e.backgroundColor)||void 0,outlinedBorder:(e==null?void 0:e.borderColor)||void 0,text:{primary:(e==null?void 0:e.textColor)||void 0},backgroundHighlight:(e==null?void 0:e.summaryBackgroundColor)||void 0},typography:Gp(n,fm),customCss:r||void 0}}function CA(t){let e=true,n=(t==null?void 0:t.find(o=>o.status===bi.InTrial))||null,r=n==null?void 0:n.plan,i=n!=null&&n.trialEndDate?kS(n.trialEndDate):void 0;return r||(e=false,n=(t==null?void 0:t.find(o=>o.status===bi.Active))||null,r=n==null?void 0:n.plan),{currentSubscription:n,currentPlan:r,isCustomerOnTrial:e,trialDaysLeft:i}}function FS(t,e,n){var G,X;let{plans:r,currency:i,configuration:o,customer:s,activeSubscriptions:c,paywallCalculatedPricePoints:p}=t||{},{currentSubscription:h,currentPlan:v,isCustomerOnTrial:P,trialDaysLeft:x}=CA(c),T=n==null?void 0:n({currentSubscription:h}),I=(h==null?void 0:h.scheduledUpdates)||[],R=(G=h==null?void 0:h.price)==null?void 0:G.billingPeriod,A=I.find(({subscriptionScheduleType:nt})=>nt===Ui.Downgrade),O=I.find(({subscriptionScheduleType:nt})=>nt===Ui.BillingPeriod),N=fx__default.default(r,nt=>nt.order).map(nt=>{var ut;let st=(ut=s==null?void 0:s.eligibleForTrial)==null?void 0:ut.find(Y=>Y.productId===nt.product.id),U=T!=null&&T.planId?(T==null?void 0:T.planId)===nt.id:nt.id===(v==null?void 0:v.id),j=Y=>{var mt;let at=A==null?void 0:A.scheduleVariables,pt=O==null?void 0:O.scheduleVariables,dt=nt.pricePoints.some(Ct=>Ct.billingPeriod===Y);return A?((mt=A.targetPackage)==null?void 0:mt.refId)===nt.id&&(!dt||at.billingPeriod===Y):O&&U?pt.billingPeriod===Y:false};return St(W({},nt),{paywallCalculatedPricePoints:p==null?void 0:p.filter(Y=>Y.planId===nt.id),isTriable:!lm__default.default(nt.defaultTrialConfig)&&(!st||st.eligible),isCurrentCustomerPlan:U,currentCustomerPlanBillingPeriod:R,isUpcomingPlan:false,trialDaysLeft:x,isNextPlan:j,paywallCurrency:i,scheduledUpdate:A||O})});if(r&&v){let nt=v&&((X=r==null?void 0:r.find(st=>st.id===(v==null?void 0:v.id)))==null?void 0:X.order);lm__default.default(nt)||(N=N.map(st=>St(W({},st),{isLowerThanCurrentPlan:nt>st.order})),e&&(N=N.filter(st=>st.order>=nt)));}let V=o?AS(o):void 0;return {currentPlan:v,currentSubscription:h,currentSubscriptionOverride:T,isCustomerOnTrial:P,plans:N,paywallConfiguration:V}}var NS="7.11.0";var LS="@stigg/react-sdk";var jp=Uv__default.default.createContext(null);jp.displayName="StiggContext";var _A="en-US",TA=({apiKey:t,baseUri:e,baseEdgeUri:n,enableEdge:r,customerId:i,customerToken:o,resourceId:s,theme:c,locale:p,cacheTtlMs:h,useEntitlementPolling:v,entitlementPollingInterval:P,entitlementsFallback:x,stiggClient:T,children:I,offline:R,clientName:A=LS,clientVersion:O=NS})=>{let N=Uv.useRef(t),V={apiKey:t,customerId:i,customerToken:o,resourceId:s,baseUri:e,baseEdgeUri:n,enableEdge:r,entitlementsFallback:x,cacheTtlMs:h,useEntitlementPolling:v,entitlementPollingInterval:P,clientName:A,clientVersion:O,offline:R},[G,X]=Uv.useState(()=>({stigg:T!=null?T:bb.initialize(St(W({},V),{lazyLoad:true})),locale:p||_A,isInitialized:false,theme:c,refreshData:()=>ce(null,null,function*(){X(nt=>St(W({},nt),{customerPortalUpdatedAt:new Date})),yield G.stigg.refresh();})}));return Uv.useEffect(()=>{let nt=true,st=Y=>{nt&&X(Y);},U=()=>st(Y=>St(W({},Y),{updatedAt:new Date})),j=Y=>st(at=>(at.stigg&&at.stigg.removeListener("entitlementsUpdated",U),Y.addListener("entitlementsUpdated",U),St(W({},at),{stigg:Y,isInitialized:true,updatedAt:new Date})));return ce(null,null,function*(){let Y=G.stigg;t!==N.current&&(tl.log("Updating stigg client",{apiKey:t}),N.current=t,Y=bb.initialize(W({},V)),st(at=>St(W({},at),{isInitialized:false,updatedAt:new Date}))),yield Y.waitForInitialization(),j(Y);}),()=>{nt=false,G.stigg.removeListener("entitlementsUpdated",U),G.stigg.clearCustomer();}},[t]),Uv.useEffect(()=>{let nt=G.stigg;i?nt.setCustomerId(i,o,s):nt.clearCustomer();},[i,o,s]),Uv.useEffect(()=>{X(nt=>St(W({},nt),{theme:c}));},[c]),jsxRuntime.jsx(jp.Provider,{value:G,children:jsxRuntime.jsx(nl.SkeletonTheme,{baseColor:"#F5F6F9",highlightColor:"#e5e6ea",children:I})})};function ve(t){let{optional:e}=t||{},n=Uv.useContext(jp);if(!n&&!e)throw new Error("Could not find Stigg context; You need to wrap your app in an <StiggProvider> component.");return n}function US({productId:t,resourceId:e,showOnlyEligiblePlans:n,billingCountryCode:r,preferredBillingPeriod:i,currentSubscriptionOverrideFn:o}){let{stigg:s,locale:c}=ve(),[p,h]=Uv.useState(be.Annually),[v,P]=Uv.useState([]),[x,T]=Uv.useState(null),[I,R]=Uv.useState(true);Uv.useEffect(()=>{ce(null,null,function*(){try{R(!0),yield s.waitForInitialization();let N=yield s.getPaywall({productId:t,resourceId:e,billingCountryCode:r}),{availableBillingPeriods:V,defaultBillingPeriod:G}=wS(N.plans,N.activeSubscriptions,i);T(N),P(V),h(G);}catch(N){tl.error(`Failed to load paywall ${N==null?void 0:N.message}`,N);}finally{R(false);}});},[s,t,s.isCustomerLoaded,r,e,i]);let A=FS(x,n,o);return W({customer:(x==null?void 0:x.customer)||null,isLoading:I,selectedBillingPeriod:p,setSelectedBillingPeriod:h,availableBillingPeriods:v,locale:c,configuration:A.paywallConfiguration,showWatermark:s.getShowWatermark()},A)}function $S(t){return zD__default.default({highlightChip:"Recommended",addonsTitle:"Available add-ons:",planCTAButton:{upgrade:"Upgrade",downgrade:"Downgrade",startTrial:n=>{var r;return `Start ${(r=n.defaultTrialConfig)==null?void 0:r.duration} day trial`},custom:"Contact us",currentPlan:"Current plan",startNew:"Get started",switchToBillingPeriod:n=>n===be.Monthly?"Switch to monthly billing":"Switch to annual billing",cancelScheduledUpdate:"Cancel"},price:{startingAtCaption:"Starts at",pricePeriod:n=>n===be.Monthly?"/ month":"/ year",free:n=>({price:`${n==null?void 0:n.symbol}0`}),custom:"Custom",priceNotSet:"Price not set"}},t)}var DA=t=>jsxRuntime.jsx("svg",St(W({width:15,height:11,viewBox:"0 0 15 11",fill:"none",xmlns:"http://www.w3.org/2000/svg"},t),{children:jsxRuntime.jsx("path",{d:"M5.59 7.9899L2.125 4.5249C1.73524 4.13514 1.10365 4.13402 0.712509 4.52241V4.52241C0.319409 4.91274 0.318286 5.54819 0.710005 5.9399L5.59 10.8199L14.2948 2.11513C14.6843 1.72565 14.6843 1.09417 14.2948 0.704691V0.704691C13.9055 0.315381 13.2743 0.315184 12.8848 0.70425L5.59 7.9899Z",fill:"#B2BBD3"})})),jS=DA;var AA=Q.div`
4971
4971
  display: flex;
4972
4972
  flex-direction: column;
4973
4973
  align-items: center;
@@ -5077,7 +5077,7 @@ ${e.o5f}`,e.zBW=r.default`
5077
5077
  ${({$customCss:t})=>t&&react.css`
5078
5078
  ${t}
5079
5079
  `}
5080
- `;function pc(t){let{theme:e}=ve(),n=zD__default.default(t,e);return QC(n)}var qA=t=>({primary:{main:t.palette.primary}}),vi=({children:t,componentTheme:e})=>{let n=pc(e),r=qA(n),i=styles.createTheme({palette:r,stigg:n});return jsxRuntime.jsx(styles.ThemeProvider,{theme:{[styles.THEME_ID]:i},children:jsxRuntime.jsx(react.ThemeProvider,{theme:{stigg:n},children:jsxRuntime.jsxs(WA,{$customCss:n.customCss,children:[jsxRuntime.jsx(zS,{externalFontUrl:n.typography.fontFamilyUrl}),t]})})})};var Mo=Uv__default.default.createContext(null);Mo.displayName="CustomerPortalContext";var ir=()=>{let t=Uv.useContext(Mo);if(!t)throw new Error("Could not find Customer portal context; You need to wrap your customer portal components in an <CustomerPortalProvider> component.");return t};function fc(t){return !!Uv.useContext(t)}var WS=({productId:t,resourceId:e,highlightedPlanId:n,showOnlyEligiblePlans:r,textOverrides:i,onPlanSelected:o,preferredBillingPeriod:s,onBillingPeriodChange:c,billingCountryCode:p,shouldHidePlan:h,selectDefaultTierIndex:v,currentSubscriptionOverride:P,hideCompatibleAddons:x,skeletonPlanCount:T=3})=>{let I=fc(Mo),F=false;if(I){let{isLoading:mt,resourceId:Ct}=ir();F=mt,e=Ct;}let{plans:A,customer:O,currentSubscription:N,currentSubscriptionOverride:V,isCustomerOnTrial:G,isLoading:X,selectedBillingPeriod:nt,setSelectedBillingPeriod:st,availableBillingPeriods:U,locale:j,configuration:ut,showWatermark:Y}=US({productId:t,resourceId:e,showOnlyEligiblePlans:r,billingCountryCode:p,preferredBillingPeriod:s,currentSubscriptionOverrideFn:P}),at=$S(i),dt=!A||X||F?jsxRuntime.jsx(VS,{skeletonPlanCount:T}):jsxRuntime.jsx(TS,{plans:A,customer:O,currentSubscription:N,currentSubscriptionOverride:V,selectedBillingPeriod:nt,onBillingPeriodChanged:mt=>{st(mt),c&&c(mt);},availableBillingPeriods:U,highlightedPlanId:n,isCustomerOnTrial:G,onPlanSelected:o,paywallLocale:at,locale:j,shouldHidePlan:h,selectDefaultTierIndex:v,hideCompatibleAddons:x,showWatermark:Y});return I?dt:jsxRuntime.jsx(vi,{componentTheme:ut,children:dt})};function YS({resourceId:t,productId:e}){let{stigg:n,customerPortalUpdatedAt:r}=ve(),[i,o]=Uv.useState(false),[s,c]=Uv.useState();return Uv.useEffect(()=>{ce(null,null,function*(){if(n.isCustomerLoaded)try{o(!0);let h=yield n.getCustomerPortal({resourceId:t,productId:e});c(h);}catch(h){tl.error(`Failed to load customer portal ${h==null?void 0:h.message}`,h);}finally{o(false);}});},[n,n.isCustomerLoaded,r,t,e]),{customerPortal:s,showWatermark:n.getShowWatermark(),isLoading:i}}function QS(t){return zD__default.default({manageSubscription:"Manage",usageTabTitle:"Usage",addonsTabTitle:"Add-ons",promotionsTabTitle:"Promotions",promotionsSubtitle:"You were granted access to additional functionality at no additional cost.",contactSupportTitle:"Have questions about your subscription?",contactSupportLink:"Contact support",editBilling:"Edit billing details",invoicesTitle:"Invoices",viewInvoiceHistory:"View invoice history",editPaymentDetails:"Edit",paywallSectionTitle:"Plans",cancelScheduledUpdatesButtonTitle:"Cancel"},t)}function KS(t,e,n){var i,o,s,c;return {sectionTitleColor:(e==null?void 0:e.sectionTitleColor)||t.palette.text.secondary,planNameColor:(e==null?void 0:e.planNameColor)||t.palette.text.primary,backgroundColor:(e==null?void 0:e.backgroundColor)||((i=n==null?void 0:n.palette)==null?void 0:i.backgroundColor)||"white",borderColor:(e==null?void 0:e.borderColor)||((o=n==null?void 0:n.palette)==null?void 0:o.borderColor)||"rgba(0, 30, 108, 0.15)",listItemBackgroundColor:(e==null?void 0:e.backgroundColor)||((s=n==null?void 0:n.palette)==null?void 0:s.backgroundColor)||"white",tabMaxHeight:(e==null?void 0:e.tabMaxHeight)||"380px",iconsColor:(e==null?void 0:e.iconsColor)||((c=n==null?void 0:n.palette)==null?void 0:c.iconsColor)||void 0,iconsBackgroundColor:e==null?void 0:e.iconsBackgroundColor}}function gm({children:t,textOverrides:e,theme:n,resourceId:r,productId:i}){let{customerPortalUpdatedAt:o}=ve(),{customerPortal:s,isLoading:c,showWatermark:p}=YS({resourceId:r,productId:i}),h=s!=null&&s.configuration?DS(s.configuration):void 0,v=pc(h),P=KS(v,n,s==null?void 0:s.configuration),x=QS(e);return jsxRuntime.jsx(vi,{componentTheme:h,children:jsxRuntime.jsx(Mo.Provider,{value:{customerPortal:s,isLoading:c,showWatermark:p,textOverrides:x,theme:P,resourceId:r},children:t},o==null?void 0:o.toString())})}var rl=Q(a2__default.default)`
5080
+ `;function pc(t){let{theme:e}=ve(),n=zD__default.default(t,e);return QC(n)}var qA=t=>({primary:{main:t.palette.primary}}),vi=({children:t,componentTheme:e})=>{let n=pc(e),r=qA(n),i=styles.createTheme({palette:r,stigg:n});return jsxRuntime.jsx(styles.ThemeProvider,{theme:{[styles.THEME_ID]:i},children:jsxRuntime.jsx(react.ThemeProvider,{theme:{stigg:n},children:jsxRuntime.jsxs(WA,{$customCss:n.customCss,children:[jsxRuntime.jsx(zS,{externalFontUrl:n.typography.fontFamilyUrl}),t]})})})};var Mo=Uv__default.default.createContext(null);Mo.displayName="CustomerPortalContext";var ir=()=>{let t=Uv.useContext(Mo);if(!t)throw new Error("Could not find Customer portal context; You need to wrap your customer portal components in an <CustomerPortalProvider> component.");return t};function fc(t){return !!Uv.useContext(t)}var WS=({productId:t,resourceId:e,highlightedPlanId:n,showOnlyEligiblePlans:r,textOverrides:i,onPlanSelected:o,preferredBillingPeriod:s,onBillingPeriodChange:c,billingCountryCode:p,shouldHidePlan:h,selectDefaultTierIndex:v,currentSubscriptionOverride:P,hideCompatibleAddons:x,skeletonPlanCount:T=3})=>{let I=fc(Mo),R=false;if(I){let{isLoading:mt,resourceId:Ct}=ir();R=mt,e=Ct;}let{plans:A,customer:O,currentSubscription:N,currentSubscriptionOverride:V,isCustomerOnTrial:G,isLoading:X,selectedBillingPeriod:nt,setSelectedBillingPeriod:st,availableBillingPeriods:U,locale:j,configuration:ut,showWatermark:Y}=US({productId:t,resourceId:e,showOnlyEligiblePlans:r,billingCountryCode:p,preferredBillingPeriod:s,currentSubscriptionOverrideFn:P}),at=$S(i),dt=!A||X||R?jsxRuntime.jsx(VS,{skeletonPlanCount:T}):jsxRuntime.jsx(TS,{plans:A,customer:O,currentSubscription:N,currentSubscriptionOverride:V,selectedBillingPeriod:nt,onBillingPeriodChanged:mt=>{st(mt),c&&c(mt);},availableBillingPeriods:U,highlightedPlanId:n,isCustomerOnTrial:G,onPlanSelected:o,paywallLocale:at,locale:j,shouldHidePlan:h,selectDefaultTierIndex:v,hideCompatibleAddons:x,showWatermark:Y});return I?dt:jsxRuntime.jsx(vi,{componentTheme:ut,children:dt})};function YS({resourceId:t,productId:e}){let{stigg:n,customerPortalUpdatedAt:r}=ve(),[i,o]=Uv.useState(false),[s,c]=Uv.useState();return Uv.useEffect(()=>{ce(null,null,function*(){if(n.isCustomerLoaded)try{o(!0);let h=yield n.getCustomerPortal({resourceId:t,productId:e});c(h);}catch(h){tl.error(`Failed to load customer portal ${h==null?void 0:h.message}`,h);}finally{o(false);}});},[n,n.isCustomerLoaded,r,t,e]),{customerPortal:s,showWatermark:n.getShowWatermark(),isLoading:i}}function QS(t){return zD__default.default({manageSubscription:"Manage",usageTabTitle:"Usage",addonsTabTitle:"Add-ons",promotionsTabTitle:"Promotions",promotionsSubtitle:"You were granted access to additional functionality at no additional cost.",contactSupportTitle:"Have questions about your subscription?",contactSupportLink:"Contact support",editBilling:"Edit billing details",invoicesTitle:"Invoices",viewInvoiceHistory:"View invoice history",editPaymentDetails:"Edit",paywallSectionTitle:"Plans",cancelScheduledUpdatesButtonTitle:"Cancel"},t)}function KS(t,e,n){var i,o,s,c;return {sectionTitleColor:(e==null?void 0:e.sectionTitleColor)||t.palette.text.secondary,planNameColor:(e==null?void 0:e.planNameColor)||t.palette.text.primary,backgroundColor:(e==null?void 0:e.backgroundColor)||((i=n==null?void 0:n.palette)==null?void 0:i.backgroundColor)||"white",borderColor:(e==null?void 0:e.borderColor)||((o=n==null?void 0:n.palette)==null?void 0:o.borderColor)||"rgba(0, 30, 108, 0.15)",listItemBackgroundColor:(e==null?void 0:e.backgroundColor)||((s=n==null?void 0:n.palette)==null?void 0:s.backgroundColor)||"white",tabMaxHeight:(e==null?void 0:e.tabMaxHeight)||"380px",iconsColor:(e==null?void 0:e.iconsColor)||((c=n==null?void 0:n.palette)==null?void 0:c.iconsColor)||void 0,iconsBackgroundColor:e==null?void 0:e.iconsBackgroundColor}}function gm({children:t,textOverrides:e,theme:n,resourceId:r,productId:i}){let{customerPortalUpdatedAt:o}=ve(),{customerPortal:s,isLoading:c,showWatermark:p}=YS({resourceId:r,productId:i}),h=s!=null&&s.configuration?DS(s.configuration):void 0,v=pc(h),P=KS(v,n,s==null?void 0:s.configuration),x=QS(e);return jsxRuntime.jsx(vi,{componentTheme:h,children:jsxRuntime.jsx(Mo.Provider,{value:{customerPortal:s,isLoading:c,showWatermark:p,textOverrides:x,theme:P,resourceId:r},children:t},o==null?void 0:o.toString())})}var rl=Q(a2__default.default)`
5081
5081
  border-radius: 10px;
5082
5082
  padding: 8px 16px;
5083
5083
  text-transform: none;
@@ -5193,7 +5193,7 @@ ${e.o5f}`,e.zBW=r.default`
5193
5193
  border: ${({$borderColor:t})=>`1px solid ${t}`};
5194
5194
  padding: 32px;
5195
5195
  gap: 16px;
5196
- `;function PP({subscription:t,theme:e,textOverrides:n,onContactSupport:r}){var p,h,v,P,x,T,I;let{pricingType:i}=t,o,s=(h=(p=t.prices)==null?void 0:p.every(F=>F.billingModel!==nn.UsageBased))!=null?h:true,c=(v=t.scheduledUpdates)==null?void 0:v.find(({subscriptionScheduleType:F,targetPackage:A})=>F===Ui.Downgrade&&(A==null?void 0:A.pricingType)===Rn.Free);if(i===Rn.Free)o=jsxRuntime.jsx(Pm,{description:"You're on a free plan, so you don\u2019t have any upcoming charges"});else if(i===Rn.Paid)if(c&&s)o=jsxRuntime.jsx(Pm,{description:"Your plan will be downgraded to a free plan, so you don\u2019t have any upcoming charges"});else if(t.status===bi.InTrial)o=jsxRuntime.jsx(Pm,{description:`You\u2019re on a free trial of the ${t.planName} plan, so you don\u2019t have any upcoming charges`});else {let F=(x=(P=t.prices)==null?void 0:P[0])==null?void 0:x.billingPeriod,A=(T=t.billingPeriodRange)==null?void 0:T.end,O=(I=t.totalPrice)==null?void 0:I.total;F&&A&&O&&(o=jsxRuntime.jsx(vP,{billingPeriod:F,rangeEnd:A,amount:O.amount,currency:O.currency}));}else i===Rn.Custom&&(o=jsxRuntime.jsx(SP,{onContactSupport:r,label:n.contactSupportTitle,linkLabel:n.contactSupportLink}));return jsxRuntime.jsx(LO,{className:"stigg-subscription-total-price-layout",$borderColor:e.borderColor,children:o})}var BO=t=>jsxRuntime.jsxs("svg",St(W({width:16,height:16,viewBox:"0 0 16 16",fill:"none",xmlns:"http://www.w3.org/2000/svg"},t),{children:[jsxRuntime.jsx("path",{d:"M12.9469 13.5999H11.9344L11.935 10.7756C11.935 10.6288 11.87 10.4819 11.7557 10.3838L8.62061 7.91816L11.755 5.4532C11.8694 5.35507 11.9344 5.22444 11.9344 5.06132L11.935 2.40004H12.9475C13.225 2.40004 13.4375 2.18755 13.4375 1.91004C13.4375 1.63254 13.225 1.42004 12.9475 1.42004L3.05311 1.42067C2.77561 1.42067 2.56311 1.63316 2.56311 1.91067C2.56311 2.18817 2.77561 2.40067 3.05311 2.40067H4.06561L4.06498 5.06131C4.06498 5.20818 4.12998 5.35505 4.24436 5.45318L7.36244 7.91814L4.245 10.3837C4.13062 10.4819 4.06562 10.6125 4.06562 10.7756V13.5999H3.05313C2.77562 13.5999 2.56313 13.8124 2.56313 14.0899C2.56313 14.3674 2.77562 14.5799 3.05313 14.5799H12.9469C13.2244 14.5799 13.4369 14.3674 13.4369 14.0899C13.4369 13.8124 13.2244 13.5999 12.9469 13.5999ZM5.04498 2.39995H10.9551V4.81627L8.00002 7.16747L5.04498 4.81627V2.39995ZM5.04498 11.0206L8.00002 8.66939L10.9551 11.0044V13.5838H5.04498V11.0206Z",fill:"white"}),jsxRuntime.jsx("path",{fillRule:"evenodd",clipRule:"evenodd",d:"M3.05303 1.25404L12.9474 1.25342C13.317 1.25342 13.6041 1.54053 13.6041 1.91008C13.6041 2.27964 13.317 2.56675 12.9474 2.56675H12.1016L12.101 5.06136V5.06136C12.101 5.2747 12.0135 5.45101 11.8635 5.57973L11.8581 5.58436L8.89014 7.9182L11.8642 10.2572C12.0164 10.3878 12.1016 10.5814 12.1016 10.7757L12.101 13.4333H12.9468C13.3164 13.4333 13.6035 13.7204 13.6035 14.09C13.6035 14.4595 13.3164 14.7466 12.9468 14.7466H3.05304C2.68349 14.7466 2.39638 14.4595 2.39638 14.09C2.39638 13.7204 2.68349 13.4333 3.05304 13.4333H3.89887V10.7757C3.89887 10.5623 3.98635 10.386 4.13639 10.2573L4.14144 10.253L7.09365 7.91821L4.13566 5.57982C3.98346 5.44923 3.89823 5.25562 3.89823 5.06135L3.89882 2.56738H3.05303C2.68348 2.56738 2.39636 2.28026 2.39636 1.91071C2.39636 1.54116 2.68348 1.25405 3.05303 1.25404V1.25404ZM12.9474 1.58675L3.05304 1.58738C2.86758 1.58738 2.7297 1.72525 2.7297 1.91071C2.7297 2.09617 2.86757 2.23404 3.05303 2.23404H4.23223L4.23157 5.06135V5.06135C4.23158 5.15983 4.27538 5.25908 4.35053 5.32476L7.63107 7.91815L4.35113 10.5123C4.2739 10.5795 4.23221 10.6639 4.23221 10.7757V13.7666H3.05304C2.86759 13.7666 2.72971 13.9045 2.72971 14.09C2.72971 14.2754 2.86759 14.4133 3.05304 14.4133H12.9468C13.1323 14.4133 13.2701 14.2754 13.2701 14.09C13.2701 13.9045 13.1323 13.7667 12.9468 13.7667H11.7676L11.7683 10.7757V10.7757C11.7683 10.6772 11.7245 10.5781 11.6495 10.5124L8.35092 7.91819L11.6489 5.32461C11.726 5.25743 11.7676 5.17306 11.7676 5.06136L11.7683 2.23342H12.9474C13.1329 2.23342 13.2708 2.09554 13.2708 1.91008C13.2708 1.72463 13.1329 1.58676 12.9474 1.58675V1.58675ZM4.87823 2.23332H11.1216V4.89669L7.99994 7.3805L4.87823 4.89669V2.23332ZM5.21157 2.56666V4.73593L7.99994 6.95452L10.7883 4.73593V2.56666H5.21157ZM7.99958 8.45673L11.1216 10.9237V13.7505H4.87823V10.9403L7.99958 8.45673ZM8.0003 8.88213L5.21157 11.101V13.4172H10.7883V11.0852L8.0003 8.88213Z",fill:"white"})]})),EP=BO;var Vu=Q(i=>{var o=i,{children:t,className:e,placement:n="top"}=o,r=On(o,["children","className","placement"]);return jsxRuntime.jsx($O__default.default,St(W({arrow:true,placement:n},r),{classes:{popper:e,tooltip:"stigg-tooltip",arrow:"stigg-tooltip-arrow"},children:jsxRuntime.jsx("div",{children:t})}))})(({theme:t,$padding:e=8,$maxWidth:n=300})=>({[`& .${$O.tooltipClasses.tooltip}`]:{backgroundColor:t.stigg.palette.white,maxWidth:n,boxShadow:t.stigg.shadows.popover,padding:e,borderRadius:t.stigg.border.radius,color:t.stigg.palette.text.primary},[`& .${$O.tooltipClasses.arrow}`]:{color:t.stigg.palette.white}}));var zO=Q(rt)`
5196
+ `;function PP({subscription:t,theme:e,textOverrides:n,onContactSupport:r}){var p,h,v,P,x,T,I;let{pricingType:i}=t,o,s=(h=(p=t.prices)==null?void 0:p.every(R=>R.billingModel!==nn.UsageBased))!=null?h:true,c=(v=t.scheduledUpdates)==null?void 0:v.find(({subscriptionScheduleType:R,targetPackage:A})=>R===Ui.Downgrade&&(A==null?void 0:A.pricingType)===Rn.Free);if(i===Rn.Free)o=jsxRuntime.jsx(Pm,{description:"You're on a free plan, so you don\u2019t have any upcoming charges"});else if(i===Rn.Paid)if(c&&s)o=jsxRuntime.jsx(Pm,{description:"Your plan will be downgraded to a free plan, so you don\u2019t have any upcoming charges"});else if(t.status===bi.InTrial)o=jsxRuntime.jsx(Pm,{description:`You\u2019re on a free trial of the ${t.planName} plan, so you don\u2019t have any upcoming charges`});else {let R=(x=(P=t.prices)==null?void 0:P[0])==null?void 0:x.billingPeriod,A=(T=t.billingPeriodRange)==null?void 0:T.end,O=(I=t.totalPrice)==null?void 0:I.total;R&&A&&O&&(o=jsxRuntime.jsx(vP,{billingPeriod:R,rangeEnd:A,amount:O.amount,currency:O.currency}));}else i===Rn.Custom&&(o=jsxRuntime.jsx(SP,{onContactSupport:r,label:n.contactSupportTitle,linkLabel:n.contactSupportLink}));return jsxRuntime.jsx(LO,{className:"stigg-subscription-total-price-layout",$borderColor:e.borderColor,children:o})}var BO=t=>jsxRuntime.jsxs("svg",St(W({width:16,height:16,viewBox:"0 0 16 16",fill:"none",xmlns:"http://www.w3.org/2000/svg"},t),{children:[jsxRuntime.jsx("path",{d:"M12.9469 13.5999H11.9344L11.935 10.7756C11.935 10.6288 11.87 10.4819 11.7557 10.3838L8.62061 7.91816L11.755 5.4532C11.8694 5.35507 11.9344 5.22444 11.9344 5.06132L11.935 2.40004H12.9475C13.225 2.40004 13.4375 2.18755 13.4375 1.91004C13.4375 1.63254 13.225 1.42004 12.9475 1.42004L3.05311 1.42067C2.77561 1.42067 2.56311 1.63316 2.56311 1.91067C2.56311 2.18817 2.77561 2.40067 3.05311 2.40067H4.06561L4.06498 5.06131C4.06498 5.20818 4.12998 5.35505 4.24436 5.45318L7.36244 7.91814L4.245 10.3837C4.13062 10.4819 4.06562 10.6125 4.06562 10.7756V13.5999H3.05313C2.77562 13.5999 2.56313 13.8124 2.56313 14.0899C2.56313 14.3674 2.77562 14.5799 3.05313 14.5799H12.9469C13.2244 14.5799 13.4369 14.3674 13.4369 14.0899C13.4369 13.8124 13.2244 13.5999 12.9469 13.5999ZM5.04498 2.39995H10.9551V4.81627L8.00002 7.16747L5.04498 4.81627V2.39995ZM5.04498 11.0206L8.00002 8.66939L10.9551 11.0044V13.5838H5.04498V11.0206Z",fill:"white"}),jsxRuntime.jsx("path",{fillRule:"evenodd",clipRule:"evenodd",d:"M3.05303 1.25404L12.9474 1.25342C13.317 1.25342 13.6041 1.54053 13.6041 1.91008C13.6041 2.27964 13.317 2.56675 12.9474 2.56675H12.1016L12.101 5.06136V5.06136C12.101 5.2747 12.0135 5.45101 11.8635 5.57973L11.8581 5.58436L8.89014 7.9182L11.8642 10.2572C12.0164 10.3878 12.1016 10.5814 12.1016 10.7757L12.101 13.4333H12.9468C13.3164 13.4333 13.6035 13.7204 13.6035 14.09C13.6035 14.4595 13.3164 14.7466 12.9468 14.7466H3.05304C2.68349 14.7466 2.39638 14.4595 2.39638 14.09C2.39638 13.7204 2.68349 13.4333 3.05304 13.4333H3.89887V10.7757C3.89887 10.5623 3.98635 10.386 4.13639 10.2573L4.14144 10.253L7.09365 7.91821L4.13566 5.57982C3.98346 5.44923 3.89823 5.25562 3.89823 5.06135L3.89882 2.56738H3.05303C2.68348 2.56738 2.39636 2.28026 2.39636 1.91071C2.39636 1.54116 2.68348 1.25405 3.05303 1.25404V1.25404ZM12.9474 1.58675L3.05304 1.58738C2.86758 1.58738 2.7297 1.72525 2.7297 1.91071C2.7297 2.09617 2.86757 2.23404 3.05303 2.23404H4.23223L4.23157 5.06135V5.06135C4.23158 5.15983 4.27538 5.25908 4.35053 5.32476L7.63107 7.91815L4.35113 10.5123C4.2739 10.5795 4.23221 10.6639 4.23221 10.7757V13.7666H3.05304C2.86759 13.7666 2.72971 13.9045 2.72971 14.09C2.72971 14.2754 2.86759 14.4133 3.05304 14.4133H12.9468C13.1323 14.4133 13.2701 14.2754 13.2701 14.09C13.2701 13.9045 13.1323 13.7667 12.9468 13.7667H11.7676L11.7683 10.7757V10.7757C11.7683 10.6772 11.7245 10.5781 11.6495 10.5124L8.35092 7.91819L11.6489 5.32461C11.726 5.25743 11.7676 5.17306 11.7676 5.06136L11.7683 2.23342H12.9474C13.1329 2.23342 13.2708 2.09554 13.2708 1.91008C13.2708 1.72463 13.1329 1.58676 12.9474 1.58675V1.58675ZM4.87823 2.23332H11.1216V4.89669L7.99994 7.3805L4.87823 4.89669V2.23332ZM5.21157 2.56666V4.73593L7.99994 6.95452L10.7883 4.73593V2.56666H5.21157ZM7.99958 8.45673L11.1216 10.9237V13.7505H4.87823V10.9403L7.99958 8.45673ZM8.0003 8.88213L5.21157 11.101V13.4172H10.7883V11.0852L8.0003 8.88213Z",fill:"white"})]})),EP=BO;var Vu=Q(i=>{var o=i,{children:t,className:e,placement:n="top"}=o,r=On(o,["children","className","placement"]);return jsxRuntime.jsx($O__default.default,St(W({arrow:true,placement:n},r),{classes:{popper:e,tooltip:"stigg-tooltip",arrow:"stigg-tooltip-arrow"},children:jsxRuntime.jsx("div",{children:t})}))})(({theme:t,$padding:e=8,$maxWidth:n=300})=>({[`& .${$O.tooltipClasses.tooltip}`]:{backgroundColor:t.stigg.palette.white,maxWidth:n,boxShadow:t.stigg.shadows.popover,padding:e,borderRadius:t.stigg.border.radius,color:t.stigg.palette.text.primary},[`& .${$O.tooltipClasses.arrow}`]:{color:t.stigg.palette.white}}));var zO=Q(rt)`
5197
5197
  display: ${({$display:t})=>t};
5198
5198
  -webkit-line-clamp: ${({$maxLines:t})=>t};
5199
5199
  -webkit-box-orient: vertical;
@@ -5207,7 +5207,7 @@ ${e.o5f}`,e.zBW=r.default`
5207
5207
  ${({$bold:t})=>t&&react.css`
5208
5208
  font-weight: bold;
5209
5209
  `}
5210
- `;function IP(t){return t&&(t.clientHeight<t.scrollHeight||t.offsetWidth<t.scrollWidth)}var il=({leaveDelay:t,children:e,variant:n,color:r,maxLines:i=1,wordBreak:o,bold:s,tooltipPlacement:c="top",className:p,display:h="-webkit-box",style:v,"data-testid":P})=>{let[x,T]=Uv.useState(false),I=Uv.useRef(null),F=jsxRuntime.jsx(zO,{ref:I,variant:n,color:r,$maxLines:i,$wordBreak:o,$bold:s,className:p,$display:h,style:v,"data-testid":P,children:e});Uv.useEffect(()=>{if(I!=null&&I.current){let O=IP(I.current);T(O);}},[I]);let A=(I==null?void 0:I.current)&&IP(I.current);return jsxRuntime.jsx("span",{children:x||A?jsxRuntime.jsx(Vu,{placement:c,leaveDelay:t,title:jsxRuntime.jsx(rt,{variant:"body1",children:e}),children:F}):F})};var WO=Q.div`
5210
+ `;function IP(t){return t&&(t.clientHeight<t.scrollHeight||t.offsetWidth<t.scrollWidth)}var il=({leaveDelay:t,children:e,variant:n,color:r,maxLines:i=1,wordBreak:o,bold:s,tooltipPlacement:c="top",className:p,display:h="-webkit-box",style:v,"data-testid":P})=>{let[x,T]=Uv.useState(false),I=Uv.useRef(null),R=jsxRuntime.jsx(zO,{ref:I,variant:n,color:r,$maxLines:i,$wordBreak:o,$bold:s,className:p,$display:h,style:v,"data-testid":P,children:e});Uv.useEffect(()=>{if(I!=null&&I.current){let O=IP(I.current);T(O);}},[I]);let A=(I==null?void 0:I.current)&&IP(I.current);return jsxRuntime.jsx("span",{children:x||A?jsxRuntime.jsx(Vu,{placement:c,leaveDelay:t,title:jsxRuntime.jsx(rt,{variant:"body1",children:e}),children:R}):R})};var WO=Q.div`
5211
5211
  width: 100%;
5212
5212
  display: flex;
5213
5213
  align-items: center;
@@ -5235,7 +5235,7 @@ ${e.o5f}`,e.zBW=r.default`
5235
5235
  text-transform: none;
5236
5236
  padding: 0;
5237
5237
  white-space: nowrap;
5238
- `;function wm({entitlement:t,feature:e,onManageSubscription:n,onBuyMore:r,canBuyMore:i,canUpgradeSubscription:o,hasCustomSubscription:s}){return s||t.hasUnlimitedUsage||zu(t.currentUsage||0,t.usageLimit)<iv?null:i?r?jsxRuntime.jsx(BP,{variant:"text",onClick:()=>r(e,t),children:jsxRuntime.jsx(rt,{color:"primary.main",children:"Buy more"})}):null:o&&n?jsxRuntime.jsx(BP,{variant:"text",onClick:()=>n({intentionType:"UPGRADE_PLAN"}),children:jsxRuntime.jsx(rt,{color:"primary.main",children:"Upgrade"})}):null}function UP({amount:t,currency:e,blockSize:n,entitlement:r,feature:i,hideChargePrice:o,onBuyMore:s,onManageSubscription:c,canUpgradeSubscription:p,hasCustomSubscription:h}){var v,P,x;return jsxRuntime.jsxs("div",{className:`stigg-charge-list-item stigg-charge-list-item-${r.feature.refId}`,style:{display:"flex",flexDirection:"column",gap:12},children:[jsxRuntime.jsxs("div",{style:{display:"flex",justifyContent:"space-between",gap:12},children:[jsxRuntime.jsxs("div",{style:{display:"flex",gap:12},children:[jsxRuntime.jsx(il,{variant:"body1",color:"primary",children:i.displayName}),!o&&jsxRuntime.jsxs(il,{variant:"body1",color:"secondary",children:[wn({amount:t,currency:e})," per ",n?`${n} `:"",n?i.featureUnitsPlural:i.featureUnits]})]}),jsxRuntime.jsxs("div",{style:{display:"flex",gap:12},children:[jsxRuntime.jsx(wm,{entitlement:r,feature:i,canBuyMore:true,onBuyMore:s,onManageSubscription:c,canUpgradeSubscription:p,hasCustomSubscription:h}),jsxRuntime.jsx(rt,{variant:"body1",color:"primary",style:{whiteSpace:"nowrap"},children:r.hasUnlimitedUsage?(v=r.currentUsage)==null?void 0:v.toLocaleString():`${(P=r.currentUsage)==null?void 0:P.toLocaleString()} of ${(x=r.usageLimit)==null?void 0:x.toLocaleString()}`})]})]}),jsxRuntime.jsx(_m,{entitlement:r})]})}function GP({subscription:t,entitlements:e,onBuyMore:n,onManageSubscription:r,hasCustomSubscription:i,canUpgradeSubscription:o}){let s=lodash.keyBy(e,"feature.refId"),c=t.prices.filter(({feature:p,price:h})=>!!p&&s[p.refId]&&!!h);return c.length?jsxRuntime.jsx("div",{className:"stigg-charge-list",style:{display:"flex",flexDirection:"column",gap:16,marginTop:32},children:c.map(({feature:p,price:h,blockSize:v,billingModel:P})=>{if(!p||!h)return null;let x=s[p.refId];return !x||!x.feature?null:jsxRuntime.jsx(UP,{entitlement:x,feature:x.feature,amount:h.amount,blockSize:v,currency:h.currency,hideChargePrice:P===nn.PerUnit,onBuyMore:n,onManageSubscription:r,canUpgradeSubscription:o,hasCustomSubscription:i},p.refId)})}):null}function km({onManageSubscription:t,onBuyMore:e,onCancelScheduledUpdates:n,onContactSupport:r,hiddenSections:i,cancelScheduledUpdatesButtonTitle:o}){let{customerPortal:s,isLoading:c,textOverrides:p,theme:h}=ir(),v=c||!s,{subscriptions:P,entitlements:x,canUpgradeSubscription:T}=s||{},I=P==null?void 0:P.find(({status:N})=>N===bi.Active),F=P==null?void 0:P.find(({status:N})=>N===bi.InTrial),A=(I==null?void 0:I.pricingType)===Rn.Custom,O=I||F;return jsxRuntime.jsxs(pa,{className:"stigg-customer-portal-subscriptions-overview",$backgroundColor:h.backgroundColor,$borderColor:h.borderColor,children:[!v&&I&&I.scheduledUpdates&&jsxRuntime.jsx(gP,{theme:h,subscription:I,onCancelScheduledUpdates:n,cancelScheduledUpdatesButtonTitle:o}),v||!O?jsxRuntime.jsx(hP,{}):jsxRuntime.jsxs("div",{className:"stigg-overview-layout",style:{display:"flex",alignItems:"flex-start",gap:64,flexWrap:"wrap"},children:[jsxRuntime.jsxs("div",{style:{display:"flex",flexDirection:"column",flex:1},children:[jsxRuntime.jsx(rP,{onManageSubscription:t,hideManageButton:A,textOverrides:p}),jsxRuntime.jsx(OP,{mainSubscription:O,trialSubscription:F,theme:h,onManageSubscription:t}),I&&x&&jsxRuntime.jsx(GP,{subscription:I,entitlements:x,onBuyMore:e,onManageSubscription:t,canUpgradeSubscription:!!T,hasCustomSubscription:A}),jsxRuntime.jsx(dP,{customerPortal:s,hiddenSections:i,textOverrides:p,theme:h})]}),jsxRuntime.jsx("div",{style:{display:"flex",flexDirection:"column",width:319,gap:24},children:jsxRuntime.jsx(PP,{subscription:O,theme:h,onContactSupport:r,textOverrides:p})})]})]})}var eR=Q.div`
5238
+ `;function wm({entitlement:t,feature:e,onManageSubscription:n,onBuyMore:r,canBuyMore:i,canUpgradeSubscription:o,hasCustomSubscription:s}){return s||t.hasUnlimitedUsage||zu(t.currentUsage||0,t.usageLimit)<iv?null:i?r?jsxRuntime.jsx(BP,{variant:"text",onClick:()=>r(e,t),children:jsxRuntime.jsx(rt,{color:"primary.main",children:"Buy more"})}):null:o&&n?jsxRuntime.jsx(BP,{variant:"text",onClick:()=>n({intentionType:"UPGRADE_PLAN"}),children:jsxRuntime.jsx(rt,{color:"primary.main",children:"Upgrade"})}):null}function UP({amount:t,currency:e,blockSize:n,entitlement:r,feature:i,hideChargePrice:o,onBuyMore:s,onManageSubscription:c,canUpgradeSubscription:p,hasCustomSubscription:h}){var v,P,x;return jsxRuntime.jsxs("div",{className:`stigg-charge-list-item stigg-charge-list-item-${r.feature.refId}`,style:{display:"flex",flexDirection:"column",gap:12},children:[jsxRuntime.jsxs("div",{style:{display:"flex",justifyContent:"space-between",gap:12},children:[jsxRuntime.jsxs("div",{style:{display:"flex",gap:12},children:[jsxRuntime.jsx(il,{variant:"body1",color:"primary",children:i.displayName}),!o&&jsxRuntime.jsxs(il,{variant:"body1",color:"secondary",children:[wn({amount:t,currency:e})," per ",n?`${n} `:"",n?i.featureUnitsPlural:i.featureUnits]})]}),jsxRuntime.jsxs("div",{style:{display:"flex",gap:12},children:[jsxRuntime.jsx(wm,{entitlement:r,feature:i,canBuyMore:true,onBuyMore:s,onManageSubscription:c,canUpgradeSubscription:p,hasCustomSubscription:h}),jsxRuntime.jsx(rt,{variant:"body1",color:"primary",style:{whiteSpace:"nowrap"},children:r.hasUnlimitedUsage?(v=r.currentUsage)==null?void 0:v.toLocaleString():`${(P=r.currentUsage)==null?void 0:P.toLocaleString()} of ${(x=r.usageLimit)==null?void 0:x.toLocaleString()}`})]})]}),jsxRuntime.jsx(_m,{entitlement:r})]})}function GP({subscription:t,entitlements:e,onBuyMore:n,onManageSubscription:r,hasCustomSubscription:i,canUpgradeSubscription:o}){let s=lodash.keyBy(e,"feature.refId"),c=t.prices.filter(({feature:p,price:h})=>!!p&&s[p.refId]&&!!h);return c.length?jsxRuntime.jsx("div",{className:"stigg-charge-list",style:{display:"flex",flexDirection:"column",gap:16,marginTop:32},children:c.map(({feature:p,price:h,blockSize:v,billingModel:P})=>{if(!p||!h)return null;let x=s[p.refId];return !x||!x.feature?null:jsxRuntime.jsx(UP,{entitlement:x,feature:x.feature,amount:h.amount,blockSize:v,currency:h.currency,hideChargePrice:P===nn.PerUnit,onBuyMore:n,onManageSubscription:r,canUpgradeSubscription:o,hasCustomSubscription:i},p.refId)})}):null}function km({onManageSubscription:t,onBuyMore:e,onCancelScheduledUpdates:n,onContactSupport:r,hiddenSections:i,cancelScheduledUpdatesButtonTitle:o}){let{customerPortal:s,isLoading:c,textOverrides:p,theme:h}=ir(),v=c||!s,{subscriptions:P,entitlements:x,canUpgradeSubscription:T}=s||{},I=P==null?void 0:P.find(({status:N})=>N===bi.Active),R=P==null?void 0:P.find(({status:N})=>N===bi.InTrial),A=(I==null?void 0:I.pricingType)===Rn.Custom,O=I||R;return jsxRuntime.jsxs(pa,{className:"stigg-customer-portal-subscriptions-overview",$backgroundColor:h.backgroundColor,$borderColor:h.borderColor,children:[!v&&I&&I.scheduledUpdates&&jsxRuntime.jsx(gP,{theme:h,subscription:I,onCancelScheduledUpdates:n,cancelScheduledUpdatesButtonTitle:o}),v||!O?jsxRuntime.jsx(hP,{}):jsxRuntime.jsxs("div",{className:"stigg-overview-layout",style:{display:"flex",alignItems:"flex-start",gap:64,flexWrap:"wrap"},children:[jsxRuntime.jsxs("div",{style:{display:"flex",flexDirection:"column",flex:1},children:[jsxRuntime.jsx(rP,{onManageSubscription:t,hideManageButton:A,textOverrides:p}),jsxRuntime.jsx(OP,{mainSubscription:O,trialSubscription:R,theme:h,onManageSubscription:t}),I&&x&&jsxRuntime.jsx(GP,{subscription:I,entitlements:x,onBuyMore:e,onManageSubscription:t,canUpgradeSubscription:!!T,hasCustomSubscription:A}),jsxRuntime.jsx(dP,{customerPortal:s,hiddenSections:i,textOverrides:p,theme:h})]}),jsxRuntime.jsx("div",{style:{display:"flex",flexDirection:"column",width:319,gap:24},children:jsxRuntime.jsx(PP,{subscription:O,theme:h,onContactSupport:r,textOverrides:p})})]})]})}var eR=Q.div`
5239
5239
  display: flex;
5240
5240
  width: 100%;
5241
5241
  align-items: flex-end;
@@ -5309,7 +5309,7 @@ ${e.o5f}`,e.zBW=r.default`
5309
5309
  ${({theme:t,$highlight:e})=>e&&`background-color: ${t.stigg.palette.backgroundSection}`};
5310
5310
  `;function tx({entitlement:t,subscriptionPrice:e,onManageSubscription:n,onBuyMore:r,hasCustomSubscription:i,canUpgradeSubscription:o}){var p,h,v;let{theme:s}=ir(),c=!t.hasUnlimitedUsage&&t.currentUsage>t.usageLimit;return t.feature?jsxRuntime.jsxs(ZP,{$highlight:!!e,$borderColor:s.borderColor,children:[jsxRuntime.jsxs("div",{style:{display:"flex",alignItems:"center",justifyContent:"space-between",gap:16},children:[jsxRuntime.jsx(il,{variant:"body1",children:t.feature&&XP(t.feature)}),e&&jsxRuntime.jsx(Vu,{title:jsxRuntime.jsx(rt,{variant:"body1",children:e.billingModel===nn.PerUnit?"Billed for committed usage":"Billed for actual usage"}),children:jsxRuntime.jsx(qn,{icon:"DollarCoin",svgStrokeColor:s.iconsColor})})]}),jsxRuntime.jsxs("div",{style:{display:"flex",justifyContent:"space-between",alignItems:"center",gap:8},children:[jsxRuntime.jsxs(il,{variant:"body1",color:c?"error":"primary","data-testid":`usage-data-${(p=t.feature)==null?void 0:p.refId}`,children:[(h=t.currentUsage)==null?void 0:h.toLocaleString(),!t.hasUnlimitedUsage&&` / ${(v=t.usageLimit)==null?void 0:v.toLocaleString()} (${zu(t.currentUsage||0,t.usageLimit)}%)`]}),jsxRuntime.jsx(wm,{entitlement:t,feature:t.feature,onBuyMore:r,canBuyMore:!!e,onManageSubscription:n,canUpgradeSubscription:o,hasCustomSubscription:i})]}),jsxRuntime.jsx(_m,{entitlement:t}),!t.hasUnlimitedUsage&&!JP__default.default(t.usageLimit)&&!JP__default.default(t.currentUsage)&&t.resetPeriod&&t.usagePeriodEnd?jsxRuntime.jsx(rt,{color:"secondary",children:MP(t)}):null,t.hasUnlimitedUsage&&jsxRuntime.jsx(rt,{color:"secondary",children:"In current billing period"})]}):null}var nx=Q.div`
5311
5311
  margin-top: 32px;
5312
- `;function rx(){let t=Ci("md");return jsxRuntime.jsx(da__default.default,{container:true,spacing:4,className:"stigg-subscription-usage-skeleton-layout",sx:{flexWrap:"wrap"},children:lodash.range(6).map(e=>jsxRuntime.jsx(da__default.default,{item:true,xs:t?4:12,children:jsxRuntime.jsx(nl__default.default,{width:280,height:120})},e))})}var sx=6;function Nm({onManageSubscription:t,onBuyMore:e,filterEntitlements:n}){var ut,Y;let[r,i]=Uv.useState(false),o=Ci("md"),{customerPortal:s,isLoading:c,textOverrides:p,theme:h}=ir(),v=c||!s,{entitlements:P,subscriptions:x}=s||{},T=P==null?void 0:P.filter(at=>{var pt,dt;return ((pt=at.feature)==null?void 0:pt.meterType)===yb.Fluctuating||((dt=at.feature)==null?void 0:dt.meterType)===yb.Incremental}),I=x==null?void 0:x.find(({status:at})=>at===bi.Active),F=(I==null?void 0:I.pricingType)===Rn.Custom,A=!!(s!=null&&s.canUpgradeSubscription),O=lodash.keyBy((ut=I==null?void 0:I.prices)!=null?ut:[],"feature.refId"),N=lodash.keyBy(T!=null?T:[],"feature.refId"),V=lodash.compact(((Y=I==null?void 0:I.prices)!=null?Y:[]).map(at=>at.feature&&N[at.feature.refId]||void 0)),G=lodash.compact((T!=null?T:[]).filter(at=>!O[at.feature.refId])),X=[...V,...G].filter(at=>at.usageLimit!==0),nt=n?n(X):X,st=o?nt.length>2?4:6:12,U=r?nt:nt.slice(0,sx),j=()=>i(at=>!at);return !v&&!(T!=null&&T.length)?null:jsxRuntime.jsxs(pa,{className:"stigg-subscription-usage-layout",$backgroundColor:h.backgroundColor,$borderColor:h.borderColor,children:[jsxRuntime.jsx(ca,{children:jsxRuntime.jsx(ua,{title:p.usageTabTitle,className:"stigg-customer-portal-usage-section-title",isLoading:v})}),v?jsxRuntime.jsx(rx,{}):jsxRuntime.jsxs(jsxRuntime.Fragment,{children:[jsxRuntime.jsx(da__default.default,{container:true,spacing:4,children:U.map(at=>jsxRuntime.jsx(da__default.default,{className:`stigg-entitlement-usage-${at.feature.refId}`,item:true,xs:st,children:jsxRuntime.jsx(tx,{subscriptionPrice:O[at.feature.refId],entitlement:at,onManageSubscription:t,onBuyMore:e,hasCustomSubscription:F,canUpgradeSubscription:A},at.feature.refId)},at.feature.refId))}),nt.length>sx&&jsxRuntime.jsx(nx,{children:jsxRuntime.jsx(rl,{className:"stigg-usage-toggle-many-button",variant:"text",startIcon:r?jsxRuntime.jsx(reactFeather.Minus,{}):jsxRuntime.jsx(reactFeather.Plus,{}),onClick:j,children:r?"Show less":"Show more"})})]})]})}function ux({onManageSubscription:t,onBuyMore:e,onCancelScheduledUpdates:n,onContactSupport:r,paywallComponent:i,hiddenSections:o,filterEntitlements:s}){let{customerPortal:c,textOverrides:p,theme:h,isLoading:v,showWatermark:P}=ir(),x=Uv.useRef(null),T=({intentionType:O})=>{var N,V;t?t({intentionType:O,customerSubscriptions:(N=c==null?void 0:c.subscriptions)!=null?N:[]}):(V=x==null?void 0:x.current)==null||V.scrollIntoView({behavior:"smooth"});},I=!(o!=null&&o.some(O=>O==="usage")),F=!(o!=null&&o.some(O=>O==="paymentDetails"||O==="billingInformation")),A=!(o!=null&&o.some(O=>O==="invoices"||O==="billingInformation"));return jsxRuntime.jsxs(QP,{className:"stigg-customer-portal-layout",children:[jsxRuntime.jsx(VP,{showWatermark:P}),jsxRuntime.jsxs(KP,{className:"stigg-customer-portal-sections",children:[jsxRuntime.jsx(km,{onCancelScheduledUpdates:n,onBuyMore:e,onManageSubscription:T,onContactSupport:r,hiddenSections:o,cancelScheduledUpdatesButtonTitle:p.cancelScheduledUpdatesButtonTitle}),I&&jsxRuntime.jsx(Nm,{onManageSubscription:T,onBuyMore:e,filterEntitlements:s}),jsxRuntime.jsx(cv,{ref:x,paywallComponent:i,theme:h,title:p.paywallSectionTitle,isLoading:!c||v}),F&&jsxRuntime.jsx(Fm,{}),A&&jsxRuntime.jsx(Lm,{})]})]})}function px(o){var s=o,{textOverrides:t,theme:e,resourceId:n,productId:r}=s,i=On(s,["textOverrides","theme","resourceId","productId"]);return jsxRuntime.jsx(gm,{textOverrides:t,theme:e,resourceId:n,productId:r,children:jsxRuntime.jsx(ux,W({},i))})}function Lm(){let{customerPortal:t,isLoading:e,textOverrides:n,theme:r}=ir(),i=!t||e,o=i?jsxRuntime.jsx(Om,{}):t!=null&&t.billingPortalUrl?jsxRuntime.jsx(Dm,{url:t.billingPortalUrl,text:n.viewInvoiceHistory,className:"stigg-view-invoice-history-button"}):null;return !i&&!(t!=null&&t.billingPortalUrl)?null:jsxRuntime.jsx(pa,{className:"stigg-invoices-section-layout",$backgroundColor:r.backgroundColor,$borderColor:r.borderColor,children:jsxRuntime.jsxs(ca,{className:"stigg-invoices-section-header",children:[jsxRuntime.jsx(ua,{isLoading:i,className:"stigg-invoices-section-title",title:n.invoicesTitle}),o]})})}var hx=t=>fx__default.default(t,"displayName"),pv=t=>fx__default.default(t,"addon.displayName");function vR(t,e){return t.pricePoints.some(n=>n.billingPeriod===e)}function mx({addon:t,currency:e,billingCountryCode:n}){return St(W({},t),{pricePoints:t.pricePoints.filter(r=>r.currency===e&&(n?r.billingCountryCode===n:true))})}function gx({addons:t,billingCountryCode:e,currency:n}){var r;return ((r=t==null?void 0:t.filter(i=>{var o;return !((o=i.hiddenFromWidgets)!=null&&o.includes(Mu.Checkout))}))==null?void 0:r.map(i=>mx({addon:i,currency:n,billingCountryCode:e})))||[]}function yx({addons:t,billingPeriod:e,billingCountryCode:n,currency:r}){var i;return ((i=t==null?void 0:t.filter(o=>vR(o.addon,e)))==null?void 0:i.map(o=>St(W({},o),{addon:mx({addon:o.addon,currency:r,billingCountryCode:n})})))||[]}function bx({activeSubscription:t,plan:e,billingCountryCode:n}){var c,p;let r=[],i=((p=(c=e==null?void 0:e.pricePoints)==null?void 0:c[0])==null?void 0:p.currency)||Fu.Usd,o=hx(gx({addons:e==null?void 0:e.compatibleAddons,billingCountryCode:n,currency:i})),s=yx({addons:t==null?void 0:t.addons,billingCountryCode:n,currency:i});return s!=null&&s.length&&(o!=null&&o.length)&&(r=pv(s.filter(h=>o.some(v=>v.id===h.addon.id)))),{addons:r,initialAddons:CR__default.default(r),availableAddons:o}}function PR(){let[,t]=Ye();return (e,n)=>t(r=>{let i=r.addonsStep.addons.find(o=>o.addon.id===e.id);i?i.quantity=n:(r.addonsStep.addons.push({addon:e,quantity:n}),r.addonsStep.addons=pv(r.addonsStep.addons));})}function xR(){let[,t]=Ye();return e=>t(n=>{SR__default.default(n.addonsStep.addons,r=>r.addon.id===e);})}function ER(){let[{addonsStep:t}]=Ye();return t}function vx(){let t=ER();return St(W({},t),{setAddon:PR(),removeAddon:xR()})}function _R(){let[{checkout:t,widgetState:e,checkoutLocalization:n,checkoutSuccess:r}]=Ye();return {checkoutState:t,widgetState:e,checkoutLocalization:n,checkoutSuccess:r}}function TR(){let[,t]=Ye();return e=>t(n=>{n.widgetState.readOnly=e;})}function wR(){let[,t]=Ye();return e=>t(n=>{n.widgetState.isValid=e;})}function IR(){let[,t]=Ye();return e=>t(n=>{n.checkoutSuccess=e;})}function ze(){let{checkoutState:t,widgetState:e,checkoutLocalization:n,checkoutSuccess:r}=_R();return {checkoutState:t,widgetState:e,checkoutLocalization:n,checkoutSuccess:r,setWidgetReadOnly:TR(),setIsValid:wR(),setCheckoutSuccess:IR()}}function Sx({planId:t,resourceId:e,billingCountryCode:n,onMockCheckoutState:r}){let{stigg:i}=ve(),[o,s]=Uv.useState(true),[c,p]=Uv.useState();return Uv.useEffect(()=>{let h=()=>ce(null,null,function*(){try{let v=yield i.getCheckoutState({planId:t,resourceId:e,billingCountryCode:n});p(v);}catch(v){tl.error(`Failed to load checkout ${v==null?void 0:v.message}`,v);}finally{s(false);}});if(r){s(false),p(r({planId:t,resourceId:e,billingCountryCode:n}));return}i.isCustomerLoaded&&(s(true),h());},[i,i.isCustomerLoaded,e,t,n,r]),{checkout:c,isLoading:o,showWatermark:i.getShowWatermark()}}var Yu=Z1(Dv());var tg=(t,e)=>t.minUnitQuantity&&e<t.minUnitQuantity?t.minUnitQuantity:t.maxUnitQuantity&&e>t.maxUnitQuantity?t.maxUnitQuantity:e;var Av=Z1(Dv()),Ov=t=>!!(t!=null&&t.pricePoints.some(e=>e.billingPeriod===Av.BillingPeriod.Monthly)),Rv=t=>!!(t!=null&&t.pricePoints.some(e=>e.billingPeriod===Av.BillingPeriod.Annually)),sE=t=>Ov(t)&&Rv(t);var uE=(t,e,n)=>t===Yu.BillingPeriod.Monthly&&e||t===Yu.BillingPeriod.Annually&&n?t:null,dE=({pricingModel:t})=>t===nn.PerUnit;function kN(t,e,n){var o;if(!e)return [];let r=lE__default.default(t,"featureId"),i=lE__default.default(cE__default.default((o=n==null?void 0:n.prices)==null?void 0:o.map(s=>{let{feature:c}=s;return !c||!dE(s)?null:{featureId:c.featureId,quantity:c.unitQuantity||null}})),"featureId");return cE__default.default(e==null?void 0:e.map(s=>{var v,P,x;let c=(v=s.feature)==null?void 0:v.featureId;if(!c||!dE(s))return null;let p,h=((P=r[c])==null?void 0:P.quantity)||((x=i[c])==null?void 0:x.quantity);return p=tg(s,h||1),s.isTieredPrice&&!Mp(s.tiers)&&(p=Ob(s.tiers,p).upTo),{featureId:c,quantity:p}}))}function DN({plan:t,activeSubscription:e,preferredBillingPeriod:n}){var s,c;let r=Ov(t),i=Rv(t);if(n){let p=uE(n,r,i);if(p)return p}if(((s=e==null?void 0:e.plan)==null?void 0:s.id)===(t==null?void 0:t.id))return ((c=e==null?void 0:e.price)==null?void 0:c.billingPeriod)||Yu.BillingPeriod.Monthly;if(e!=null&&e.prices&&(e==null?void 0:e.prices.length)>0){let p=uE(e==null?void 0:e.prices[0].billingPeriod,r,i);if(p)return p}return i?Yu.BillingPeriod.Annually:Yu.BillingPeriod.Monthly}function pE({preferredBillingPeriod:t,plan:e,activeSubscription:n,billingCountryCode:r,preconfiguredBillableFeatures:i}){let o=DN({plan:e,activeSubscription:n,preferredBillingPeriod:t}),s=e==null?void 0:e.pricePoints.filter(p=>p.billingPeriod===o),c=kN(i,s,n);return {billingPeriod:o,billableFeatures:c,billingCountryCode:r}}function AN(){let[{planStep:t}]=Ye();return t}function ON(){let[,t]=Ye();return (e,n)=>t(r=>{let i=r.planStep.billableFeatures.find(o=>o.featureId===e);i?i.quantity=n:r.planStep.billableFeatures.push({featureId:e,quantity:n});})}function RN(){let[,t]=Ye();return e=>t(n=>{n.planStep.billingPeriod=e,n.addonsStep.addons=n.addonsStep.addons.filter(r=>r.addon.pricePoints.some(i=>i.billingPeriod===e));})}function lo(){let t=AN();return St(W({},t),{setBillingPeriod:RN(),setBillableFeature:ON()})}var hE=[{key:"PLAN",label:"Plan"},{key:"ADDONS",label:"Add-ons"},{key:"PAYMENT",label:"Payment details"}],fE={activeStep:0,completedSteps:[],steps:hE,isDisabled:false},MN=(t,e,n,r)=>{if(sE(t)&&!r)return false;let i=e.map(s=>s.featureId),o=n.map(s=>s.featureId);return !(i.length!==o.length||!i.every(s=>o.includes(s)))};function mE({isLoading:t,skipCheckoutSteps:e,plan:n,availableAddons:r,availableCharges:i,preferredBillingPeriod:o,preconfiguredBillableFeatures:s}){if(t||!n)return fE;let c=[];return e.includes("PLAN")&&MN(n,i,s,o)&&c.push("PLAN"),((r==null?void 0:r.length)===0||e.includes("ADDONS"))&&c.push("ADDONS"),St(W({},fE),{steps:hE.filter(p=>!c.includes(p.key))})}function NN(){let[{progressBar:t}]=Ye();return t}function LN(){let[t,e]=Ye();return n=>ce(null,null,function*(){let{progressBar:r,planStep:i,addonsStep:o,paymentStep:s,onBeforeStepChange:c}=t;if(n!==r.activeStep&&c){let p=r.steps[r.activeStep],h=r.steps[n];if(p&&h){let v={planStep:i,addonsStep:o,paymentStep:s};if(!(yield c({from:p.key,to:h.key,state:v})))return}}e(({progressBar:p})=>{p.activeStep=n;});})}function BN(){let[,t]=Ye();return e=>t(({progressBar:n})=>{n.completedSteps.push(e);})}function UN(t){return t.completedSteps.length>=t.steps.length-1}function $N(){let[t,e]=Ye();return ()=>ce(null,null,function*(){let{progressBar:n,planStep:r,addonsStep:i,paymentStep:o,onBeforeStepChange:s}=t;if(n.isDisabled)return;let c=n.steps[n.activeStep],p=n.steps[n.activeStep+1];if(p&&s){let h={planStep:r,addonsStep:i,paymentStep:o};if(!(yield s({from:c.key,to:p.key,state:h})))return}e(({progressBar:h})=>{h.completedSteps.includes(h.activeStep)||h.completedSteps.push(h.activeStep),h.activeStep<h.steps.length-1&&(h.activeStep+=1);});})}function GN(){let[,t]=Ye();return e=>t(({progressBar:n})=>{n.isDisabled=!!e;})}function ha(){let t=NN();return {currentStep:t.steps[t.activeStep],progressBarState:t,isLastStep:t.activeStep===t.steps.length-1,isCheckoutComplete:UN(t),setActiveStep:LN(),markStepAsCompleted:BN(),goNext:$N(),setIsDisabled:GN()}}function Qu(){let[{planStep:t,addonsStep:e,promotionCode:n,paymentStep:r}]=Ye();return St(W({},t),{addons:e.addons,promotionCode:n,billingAddress:r.billingAddress,taxPercentage:r.taxPercentage})}function HN({billingAddress:t,taxPercentage:e}){return !t&&!e?{}:{billingInformation:W(W({},t?{billingAddress:t}:{}),e?{taxPercentage:e}:{})}}var WN=x=>ce(null,[x],function*({stigg:t,customerId:e,planId:n,resourceId:r,promotionCode:i,addons:o,billableFeatures:s,billingCountryCode:c,billingPeriod:p,billingAddress:h,taxPercentage:v,onMockCheckoutPreview:P}){var A;let T=o.map(({addon:O,quantity:N})=>({addonId:O.id,quantity:N})),I=null,F=null;try{if(e&&n){let O=W({customerId:e,planId:n,resourceId:r,billingCountryCode:c,addons:T,billingPeriod:p,promotionCode:i,billableFeatures:rO__default.default(s)?void 0:s},HN({billingAddress:h,taxPercentage:v}));I=P?P(O):yield t.previewSubscription(O);}}catch(O){let[,N]=((A=O==null?void 0:O.message)==null?void 0:A.split("Error:"))||[];F=N==null?void 0:N.trim();}return {subscriptionPreview:I,errorMessage:F}}),Fv=({onMockCheckoutPreview:t}={})=>{let{stigg:e}=ve(),n=Qu(),[{resourceId:r}]=Ye(),{checkoutState:i,widgetState:o}=ze(),{plan:s,customer:c}=i||{};return {previewSubscriptionAction:Uv.useCallback((...v)=>ce(null,[...v],function*({promotionCode:h}={}){return o.isValid?WN({stigg:e,customerId:c==null?void 0:c.id,planId:s==null?void 0:s.id,resourceId:r,addons:n.addons,billableFeatures:n.billableFeatures,billingCountryCode:n.billingCountryCode,billingPeriod:n.billingPeriod,billingAddress:n.billingAddress,taxPercentage:n.taxPercentage,promotionCode:h!=null?h:n.promotionCode,onMockCheckoutPreview:t}):{subscriptionPreview:null,errorMessage:null}}),[e,c==null?void 0:c.id,s==null?void 0:s.id,r,n.addons,n.billableFeatures,n.billingCountryCode,n.billingPeriod,n.billingAddress,n.taxPercentage,n.promotionCode,o.isValid,t])}},qN=500,yE=({onMockCheckoutPreview:t}={})=>{let[e,n]=Uv.useState(null),[r,i]=Uv.useState(false),{previewSubscriptionAction:o}=Fv({onMockCheckoutPreview:t});return Uv.useEffect(()=>{let s=()=>ce(null,null,function*(){let{subscriptionPreview:p}=yield o();p&&n(p),i(false);});i(true);let c=setTimeout(()=>{i(true),s();},qN);return ()=>{clearTimeout(c);}},[o]),{subscriptionPreview:e,isFetchingSubscriptionPreview:r}};function bE({customer:t,taxPercentage:e}){return {useNewPaymentMethod:!(t!=null&&t.paymentMethodDetails),taxPercentage:e}}function YN(){let[,t]=Ye();return e=>t(n=>{n.paymentStep.useNewPaymentMethod=e;})}function QN(){let[,t]=Ye();return e=>t(n=>{n.paymentStep.errorMessage=e;})}function KN(){let[,t]=Ye();return e=>t(n=>{n.paymentStep.billingAddress=e;})}function XN(){let[{paymentStep:t}]=Ye();return t}function Pi(){let t=XN();return St(W({},t),{setUseNewPaymentMethod:YN(),setErrorMessage:QN(),setBillingAddress:KN()})}function vE(t){return zD__default.default({changePlan:"Change",billingPeriodsTitle:"Billing cycle",addAddonText:"Add",addonBillingPeriodNotAvailableText:({planBillingPeriod:n})=>n===be.Monthly?"Exclusively available on annual plans":"Exclusively available on monthly plans",newPaymentMethodText:"New payment method",newPaymentMethodBillingAddressTitle:"Billing address",newPaymentMethodCardTitle:"Payment method",summary:{title:"Order summary",planName:({plan:n})=>`${n.displayName} plan`,addCouponCodeText:"Add promotion code",couponCodeTitle:"Promotion code",addonsSectionTitle:"Add-ons",discountsSectionTitle:"Discounts",onlyPayAsYouGoText:"Varies by usage",startsAtText:"Starts at ",proratedTotalDueText:"Prorated charge today",baseChargeText:()=>"Base charge",totalText:"Total",totalDueText:"Total due today",totalBillingPeriodText:({billingPeriod:n})=>`Billed ${n.toLowerCase()}`,appliedCreditsTitle:"Applied credits",creditsForUnusedTimeText:({credits:n})=>`Your account will be granted credits worth ${n} for unused time, which will be automatically applied to future payments.`,discountText:({discountDetails:n,currency:r})=>{let i="";n.type===mb.Percentage?i=`${n.value}% off`:i=`${wn({amount:n.value,currency:r})}`;let o="";switch(n.durationType){case tm.Once:{o=" once";break}case tm.Repeating:{o=`${n.type===mb.Fixed?" per month":""} for ${n.durationInMonths} months`;break}case tm.Forever:default:o="";}return `${i}${o}`},taxTitle:({taxDetails:n})=>`Tax (${n==null?void 0:n.percentage}%)`,changesWillApplyAtEndOfBillingPeriod:({billingPeriodEnd:n})=>`Your changes will take effect at the end of your current billing cycle on ${G1__default.default(n).format("MMMM D, YYYY")}.`,checkoutSuccessText:"Changes applied",payAsYouGoTooltipText:"Billed according to actual usage"},checkoutButton:{nextText:"Next",noChangesText:"No changes",updateText:"Update subscription",downgradeToFreeText:"Cancel subscription",upgradeText:"Subscribe"},downgradeToFree:{alertText:()=>"We\u2019re sorry to see you cancel your paid subscription \u{1F62D}",freePlanHeader:()=>"New plan",freePlanName:({plan:n})=>`${n.displayName}`,freePlanPriceText:()=>"Free",paidPlanHeader:()=>"Current plan",paidPlanName:({plan:n})=>`${n.displayName}`,paidPlanPriceText:({billingPeriod:n})=>`Paid plan${n?`, billed ${n.toLowerCase()}`:""}`}},t)}var Jp={primary:"rgb(50, 126, 238)",textColor:"rgb(0, 30, 108)",backgroundColor:"rgb(255, 255, 255)",borderColor:"rgb(235, 237, 243)",summaryBackgroundColor:"rgb(109, 121, 144)"};function CE(t,e,n){let{palette:r}=t||{};return {primary:(e==null?void 0:e.primary)||(r==null?void 0:r.primary)||Jp.primary,textColor:(e==null?void 0:e.textColor)||(r==null?void 0:r.text.primary)||Jp.textColor,backgroundColor:(e==null?void 0:e.backgroundColor)||(r==null?void 0:r.backgroundPaper)||Jp.backgroundColor,borderColor:(e==null?void 0:e.borderColor)||(r==null?void 0:r.outlinedBorder)||Jp.borderColor,summaryBackgroundColor:(e==null?void 0:e.summaryBackgroundColor)||(r==null?void 0:r.backgroundHighlight)||Jp.summaryBackgroundColor,paymentInputBackgroundColor:e==null?void 0:e.paymentInputBackgroundColor,paymentInputBorderColor:e==null?void 0:e.paymentInputBorderColor,paymentInputBorderRadius:e==null?void 0:e.paymentInputBorderRadius}}var Nv=Uv__default.default.createContext(null);Nv.displayName="CheckoutContext";var Ye=()=>{let t=Uv.useContext(Nv);if(!t)throw new Error("Could not find Checkout context; You need to wrap your checkout components in an <CheckoutProvider> component.");return t},a3=({children:t,initialState:e})=>{let[n,r]=Uv.useState(e);Uv.useEffect(()=>{r(e);},[e]);let i=Uv.useCallback(c=>r(p=>immer.produce(p,h=>c(h))),[r]),[o,s]=Uv.useMemo(()=>[n,i],[i,n]);return jsxRuntime.jsx(Nv.Provider,{value:[o,s],children:t})};function PE({children:t,textOverrides:e,theme:n,preferredBillingPeriod:r,billableFeatures:i,resourceId:o,planId:s,billingCountryCode:c,billingInformation:p,onMockCheckoutState:h,skipCheckoutSteps:v,onBeforeStepChange:P}){var N;let{checkout:x,isLoading:T,showWatermark:I}=Sx({resourceId:o,planId:s,billingCountryCode:c,onMockCheckoutState:h}),F=x!=null&&x.configuration?OS(x.configuration):{typography:Gp(null,fm)},A=pc(F),O=Uv.useMemo(()=>{var ut,Y;let V=CE(A,n,x==null?void 0:x.configuration),G=vE(e),X=pE({preferredBillingPeriod:r,plan:x==null?void 0:x.plan,activeSubscription:x==null?void 0:x.activeSubscription,billingCountryCode:c,preconfiguredBillableFeatures:i!=null?i:[]}),nt=bx({plan:x==null?void 0:x.plan,activeSubscription:x==null?void 0:x.activeSubscription}),st=bE({customer:x==null?void 0:x.customer,taxPercentage:(ut=p==null?void 0:p.taxDetails)==null?void 0:ut.taxPercentage}),U=mE({isLoading:T,skipCheckoutSteps:v!=null?v:[],plan:x==null?void 0:x.plan,availableAddons:nt.availableAddons,availableCharges:X.billableFeatures,preferredBillingPeriod:r,preconfiguredBillableFeatures:i!=null?i:[]});return {checkout:x,checkoutLocalization:G,stiggTheme:A,theme:V,progressBar:U,planStep:X,addonsStep:nt,paymentStep:st,resourceId:(Y=x==null?void 0:x.resource)==null?void 0:Y.id,widgetState:{readOnly:false,isValid:true,isLoadingCheckoutData:T},showWatermark:I,checkoutSuccess:false,onBeforeStepChange:P}},[r,c,x,T,v,(N=p==null?void 0:p.taxDetails)==null?void 0:N.taxPercentage,P]);return jsxRuntime.jsx(vi,{componentTheme:F,children:jsxRuntime.jsx(a3,{initialState:O,children:t})},x==null?void 0:x.plan.id)}var EE=Q.div`
5312
+ `;function rx(){let t=Ci("md");return jsxRuntime.jsx(da__default.default,{container:true,spacing:4,className:"stigg-subscription-usage-skeleton-layout",sx:{flexWrap:"wrap"},children:lodash.range(6).map(e=>jsxRuntime.jsx(da__default.default,{item:true,xs:t?4:12,children:jsxRuntime.jsx(nl__default.default,{width:280,height:120})},e))})}var sx=6;function Nm({onManageSubscription:t,onBuyMore:e,filterEntitlements:n}){var ut,Y;let[r,i]=Uv.useState(false),o=Ci("md"),{customerPortal:s,isLoading:c,textOverrides:p,theme:h}=ir(),v=c||!s,{entitlements:P,subscriptions:x}=s||{},T=P==null?void 0:P.filter(at=>{var pt,dt;return ((pt=at.feature)==null?void 0:pt.meterType)===yb.Fluctuating||((dt=at.feature)==null?void 0:dt.meterType)===yb.Incremental}),I=x==null?void 0:x.find(({status:at})=>at===bi.Active),R=(I==null?void 0:I.pricingType)===Rn.Custom,A=!!(s!=null&&s.canUpgradeSubscription),O=lodash.keyBy((ut=I==null?void 0:I.prices)!=null?ut:[],"feature.refId"),N=lodash.keyBy(T!=null?T:[],"feature.refId"),V=lodash.compact(((Y=I==null?void 0:I.prices)!=null?Y:[]).map(at=>at.feature&&N[at.feature.refId]||void 0)),G=lodash.compact((T!=null?T:[]).filter(at=>!O[at.feature.refId])),X=[...V,...G].filter(at=>at.usageLimit!==0),nt=n?n(X):X,st=o?nt.length>2?4:6:12,U=r?nt:nt.slice(0,sx),j=()=>i(at=>!at);return !v&&!(T!=null&&T.length)?null:jsxRuntime.jsxs(pa,{className:"stigg-subscription-usage-layout",$backgroundColor:h.backgroundColor,$borderColor:h.borderColor,children:[jsxRuntime.jsx(ca,{children:jsxRuntime.jsx(ua,{title:p.usageTabTitle,className:"stigg-customer-portal-usage-section-title",isLoading:v})}),v?jsxRuntime.jsx(rx,{}):jsxRuntime.jsxs(jsxRuntime.Fragment,{children:[jsxRuntime.jsx(da__default.default,{container:true,spacing:4,children:U.map(at=>jsxRuntime.jsx(da__default.default,{className:`stigg-entitlement-usage-${at.feature.refId}`,item:true,xs:st,children:jsxRuntime.jsx(tx,{subscriptionPrice:O[at.feature.refId],entitlement:at,onManageSubscription:t,onBuyMore:e,hasCustomSubscription:R,canUpgradeSubscription:A},at.feature.refId)},at.feature.refId))}),nt.length>sx&&jsxRuntime.jsx(nx,{children:jsxRuntime.jsx(rl,{className:"stigg-usage-toggle-many-button",variant:"text",startIcon:r?jsxRuntime.jsx(reactFeather.Minus,{}):jsxRuntime.jsx(reactFeather.Plus,{}),onClick:j,children:r?"Show less":"Show more"})})]})]})}function ux({onManageSubscription:t,onBuyMore:e,onCancelScheduledUpdates:n,onContactSupport:r,paywallComponent:i,hiddenSections:o,filterEntitlements:s}){let{customerPortal:c,textOverrides:p,theme:h,isLoading:v,showWatermark:P}=ir(),x=Uv.useRef(null),T=({intentionType:O})=>{var N,V;t?t({intentionType:O,customerSubscriptions:(N=c==null?void 0:c.subscriptions)!=null?N:[]}):(V=x==null?void 0:x.current)==null||V.scrollIntoView({behavior:"smooth"});},I=!(o!=null&&o.some(O=>O==="usage")),R=!(o!=null&&o.some(O=>O==="paymentDetails"||O==="billingInformation")),A=!(o!=null&&o.some(O=>O==="invoices"||O==="billingInformation"));return jsxRuntime.jsxs(QP,{className:"stigg-customer-portal-layout",children:[jsxRuntime.jsx(VP,{showWatermark:P}),jsxRuntime.jsxs(KP,{className:"stigg-customer-portal-sections",children:[jsxRuntime.jsx(km,{onCancelScheduledUpdates:n,onBuyMore:e,onManageSubscription:T,onContactSupport:r,hiddenSections:o,cancelScheduledUpdatesButtonTitle:p.cancelScheduledUpdatesButtonTitle}),I&&jsxRuntime.jsx(Nm,{onManageSubscription:T,onBuyMore:e,filterEntitlements:s}),jsxRuntime.jsx(cv,{ref:x,paywallComponent:i,theme:h,title:p.paywallSectionTitle,isLoading:!c||v}),R&&jsxRuntime.jsx(Fm,{}),A&&jsxRuntime.jsx(Lm,{})]})]})}function px(o){var s=o,{textOverrides:t,theme:e,resourceId:n,productId:r}=s,i=On(s,["textOverrides","theme","resourceId","productId"]);return jsxRuntime.jsx(gm,{textOverrides:t,theme:e,resourceId:n,productId:r,children:jsxRuntime.jsx(ux,W({},i))})}function Lm(){let{customerPortal:t,isLoading:e,textOverrides:n,theme:r}=ir(),i=!t||e,o=i?jsxRuntime.jsx(Om,{}):t!=null&&t.billingPortalUrl?jsxRuntime.jsx(Dm,{url:t.billingPortalUrl,text:n.viewInvoiceHistory,className:"stigg-view-invoice-history-button"}):null;return !i&&!(t!=null&&t.billingPortalUrl)?null:jsxRuntime.jsx(pa,{className:"stigg-invoices-section-layout",$backgroundColor:r.backgroundColor,$borderColor:r.borderColor,children:jsxRuntime.jsxs(ca,{className:"stigg-invoices-section-header",children:[jsxRuntime.jsx(ua,{isLoading:i,className:"stigg-invoices-section-title",title:n.invoicesTitle}),o]})})}var hx=t=>fx__default.default(t,"displayName"),pv=t=>fx__default.default(t,"addon.displayName");function vR(t,e){return t.pricePoints.some(n=>n.billingPeriod===e)}function mx({addon:t,currency:e,billingCountryCode:n}){return St(W({},t),{pricePoints:t.pricePoints.filter(r=>r.currency===e&&(n?r.billingCountryCode===n:true))})}function gx({addons:t,billingCountryCode:e,currency:n}){var r;return ((r=t==null?void 0:t.filter(i=>{var o;return !((o=i.hiddenFromWidgets)!=null&&o.includes(Mu.Checkout))}))==null?void 0:r.map(i=>mx({addon:i,currency:n,billingCountryCode:e})))||[]}function yx({addons:t,billingPeriod:e,billingCountryCode:n,currency:r}){var i;return ((i=t==null?void 0:t.filter(o=>vR(o.addon,e)))==null?void 0:i.map(o=>St(W({},o),{addon:mx({addon:o.addon,currency:r,billingCountryCode:n})})))||[]}function bx({activeSubscription:t,plan:e,billingCountryCode:n}){var c,p;let r=[],i=((p=(c=e==null?void 0:e.pricePoints)==null?void 0:c[0])==null?void 0:p.currency)||Fu.Usd,o=hx(gx({addons:e==null?void 0:e.compatibleAddons,billingCountryCode:n,currency:i})),s=yx({addons:t==null?void 0:t.addons,billingCountryCode:n,currency:i});return s!=null&&s.length&&(o!=null&&o.length)&&(r=pv(s.filter(h=>o.some(v=>v.id===h.addon.id)))),{addons:r,initialAddons:CR__default.default(r),availableAddons:o}}function PR(){let[,t]=Ye();return (e,n)=>t(r=>{let i=r.addonsStep.addons.find(o=>o.addon.id===e.id);i?i.quantity=n:(r.addonsStep.addons.push({addon:e,quantity:n}),r.addonsStep.addons=pv(r.addonsStep.addons));})}function xR(){let[,t]=Ye();return e=>t(n=>{SR__default.default(n.addonsStep.addons,r=>r.addon.id===e);})}function ER(){let[{addonsStep:t}]=Ye();return t}function vx(){let t=ER();return St(W({},t),{setAddon:PR(),removeAddon:xR()})}function _R(){let[{checkout:t,widgetState:e,checkoutLocalization:n,checkoutSuccess:r}]=Ye();return {checkoutState:t,widgetState:e,checkoutLocalization:n,checkoutSuccess:r}}function TR(){let[,t]=Ye();return e=>t(n=>{n.widgetState.readOnly=e;})}function wR(){let[,t]=Ye();return e=>t(n=>{n.widgetState.isValid=e;})}function IR(){let[,t]=Ye();return e=>t(n=>{n.checkoutSuccess=e;})}function ze(){let{checkoutState:t,widgetState:e,checkoutLocalization:n,checkoutSuccess:r}=_R();return {checkoutState:t,widgetState:e,checkoutLocalization:n,checkoutSuccess:r,setWidgetReadOnly:TR(),setIsValid:wR(),setCheckoutSuccess:IR()}}function Sx({planId:t,resourceId:e,billingCountryCode:n,onMockCheckoutState:r}){let{stigg:i}=ve(),[o,s]=Uv.useState(true),[c,p]=Uv.useState();return Uv.useEffect(()=>{let h=()=>ce(null,null,function*(){try{let v=yield i.getCheckoutState({planId:t,resourceId:e,billingCountryCode:n});p(v);}catch(v){tl.error(`Failed to load checkout ${v==null?void 0:v.message}`,v);}finally{s(false);}});if(r){s(false),p(r({planId:t,resourceId:e,billingCountryCode:n}));return}i.isCustomerLoaded&&(s(true),h());},[i,i.isCustomerLoaded,e,t,n,r]),{checkout:c,isLoading:o,showWatermark:i.getShowWatermark()}}var Yu=Z1(Dv());var tg=(t,e)=>t.minUnitQuantity&&e<t.minUnitQuantity?t.minUnitQuantity:t.maxUnitQuantity&&e>t.maxUnitQuantity?t.maxUnitQuantity:e;var Av=Z1(Dv()),Ov=t=>!!(t!=null&&t.pricePoints.some(e=>e.billingPeriod===Av.BillingPeriod.Monthly)),Rv=t=>!!(t!=null&&t.pricePoints.some(e=>e.billingPeriod===Av.BillingPeriod.Annually)),sE=t=>Ov(t)&&Rv(t);var uE=(t,e,n)=>t===Yu.BillingPeriod.Monthly&&e||t===Yu.BillingPeriod.Annually&&n?t:null,dE=({pricingModel:t})=>t===nn.PerUnit;function kN(t,e,n){var o;if(!e)return [];let r=lE__default.default(t,"featureId"),i=lE__default.default(cE__default.default((o=n==null?void 0:n.prices)==null?void 0:o.map(s=>{let{feature:c}=s;return !c||!dE(s)?null:{featureId:c.featureId,quantity:c.unitQuantity||null}})),"featureId");return cE__default.default(e==null?void 0:e.map(s=>{var v,P,x;let c=(v=s.feature)==null?void 0:v.featureId;if(!c||!dE(s))return null;let p,h=((P=r[c])==null?void 0:P.quantity)||((x=i[c])==null?void 0:x.quantity);return p=tg(s,h||1),s.isTieredPrice&&!Mp(s.tiers)&&(p=Ob(s.tiers,p).upTo),{featureId:c,quantity:p}}))}function DN({plan:t,activeSubscription:e,preferredBillingPeriod:n}){var s,c;let r=Ov(t),i=Rv(t);if(n){let p=uE(n,r,i);if(p)return p}if(((s=e==null?void 0:e.plan)==null?void 0:s.id)===(t==null?void 0:t.id))return ((c=e==null?void 0:e.price)==null?void 0:c.billingPeriod)||Yu.BillingPeriod.Monthly;if(e!=null&&e.prices&&(e==null?void 0:e.prices.length)>0){let p=uE(e==null?void 0:e.prices[0].billingPeriod,r,i);if(p)return p}return i?Yu.BillingPeriod.Annually:Yu.BillingPeriod.Monthly}function pE({preferredBillingPeriod:t,plan:e,activeSubscription:n,billingCountryCode:r,preconfiguredBillableFeatures:i}){let o=DN({plan:e,activeSubscription:n,preferredBillingPeriod:t}),s=e==null?void 0:e.pricePoints.filter(p=>p.billingPeriod===o),c=kN(i,s,n);return {billingPeriod:o,billableFeatures:c,billingCountryCode:r}}function AN(){let[{planStep:t}]=Ye();return t}function ON(){let[,t]=Ye();return (e,n)=>t(r=>{let i=r.planStep.billableFeatures.find(o=>o.featureId===e);i?i.quantity=n:r.planStep.billableFeatures.push({featureId:e,quantity:n});})}function RN(){let[,t]=Ye();return e=>t(n=>{n.planStep.billingPeriod=e,n.addonsStep.addons=n.addonsStep.addons.filter(r=>r.addon.pricePoints.some(i=>i.billingPeriod===e));})}function lo(){let t=AN();return St(W({},t),{setBillingPeriod:RN(),setBillableFeature:ON()})}var hE=[{key:"PLAN",label:"Plan"},{key:"ADDONS",label:"Add-ons"},{key:"PAYMENT",label:"Payment details"}],fE={activeStep:0,completedSteps:[],steps:hE,isDisabled:false},MN=(t,e,n,r)=>{if(sE(t)&&!r)return false;let i=e.map(s=>s.featureId),o=n.map(s=>s.featureId);return !(i.length!==o.length||!i.every(s=>o.includes(s)))};function mE({isLoading:t,skipCheckoutSteps:e,plan:n,availableAddons:r,availableCharges:i,preferredBillingPeriod:o,preconfiguredBillableFeatures:s}){if(t||!n)return fE;let c=[];return e.includes("PLAN")&&MN(n,i,s,o)&&c.push("PLAN"),((r==null?void 0:r.length)===0||e.includes("ADDONS"))&&c.push("ADDONS"),St(W({},fE),{steps:hE.filter(p=>!c.includes(p.key))})}function NN(){let[{progressBar:t}]=Ye();return t}function LN(){let[t,e]=Ye();return n=>ce(null,null,function*(){let{progressBar:r,planStep:i,addonsStep:o,paymentStep:s,onBeforeStepChange:c}=t;if(n!==r.activeStep&&c){let p=r.steps[r.activeStep],h=r.steps[n];if(p&&h){let v={planStep:i,addonsStep:o,paymentStep:s};if(!(yield c({from:p.key,to:h.key,state:v})))return}}e(({progressBar:p})=>{p.activeStep=n;});})}function BN(){let[,t]=Ye();return e=>t(({progressBar:n})=>{n.completedSteps.push(e);})}function UN(t){return t.completedSteps.length>=t.steps.length-1}function $N(){let[t,e]=Ye();return ()=>ce(null,null,function*(){let{progressBar:n,planStep:r,addonsStep:i,paymentStep:o,onBeforeStepChange:s}=t;if(n.isDisabled)return;let c=n.steps[n.activeStep],p=n.steps[n.activeStep+1];if(p&&s){let h={planStep:r,addonsStep:i,paymentStep:o};if(!(yield s({from:c.key,to:p.key,state:h})))return}e(({progressBar:h})=>{h.completedSteps.includes(h.activeStep)||h.completedSteps.push(h.activeStep),h.activeStep<h.steps.length-1&&(h.activeStep+=1);});})}function GN(){let[,t]=Ye();return e=>t(({progressBar:n})=>{n.isDisabled=!!e;})}function ha(){let t=NN();return {currentStep:t.steps[t.activeStep],progressBarState:t,isLastStep:t.activeStep===t.steps.length-1,isCheckoutComplete:UN(t),setActiveStep:LN(),markStepAsCompleted:BN(),goNext:$N(),setIsDisabled:GN()}}function Qu(){let[{planStep:t,addonsStep:e,promotionCode:n,paymentStep:r}]=Ye();return St(W({},t),{addons:e.addons,promotionCode:n,billingAddress:r.billingAddress,taxPercentage:r.taxPercentage})}function HN({billingAddress:t,taxPercentage:e}){return !t&&!e?{}:{billingInformation:W(W({},t?{billingAddress:t}:{}),e?{taxPercentage:e}:{})}}var WN=x=>ce(null,[x],function*({stigg:t,customerId:e,planId:n,resourceId:r,promotionCode:i,addons:o,billableFeatures:s,billingCountryCode:c,billingPeriod:p,billingAddress:h,taxPercentage:v,onMockCheckoutPreview:P}){var A;let T=o.map(({addon:O,quantity:N})=>({addonId:O.id,quantity:N})),I=null,R=null;try{if(e&&n){let O=W({customerId:e,planId:n,resourceId:r,billingCountryCode:c,addons:T,billingPeriod:p,promotionCode:i,billableFeatures:rO__default.default(s)?void 0:s},HN({billingAddress:h,taxPercentage:v}));I=P?P(O):yield t.previewSubscription(O);}}catch(O){let[,N]=((A=O==null?void 0:O.message)==null?void 0:A.split("Error:"))||[];R=N==null?void 0:N.trim();}return {subscriptionPreview:I,errorMessage:R}}),Fv=({onMockCheckoutPreview:t}={})=>{let{stigg:e}=ve(),n=Qu(),[{resourceId:r}]=Ye(),{checkoutState:i,widgetState:o}=ze(),{plan:s,customer:c}=i||{};return {previewSubscriptionAction:Uv.useCallback((...v)=>ce(null,[...v],function*({promotionCode:h}={}){return o.isValid?WN({stigg:e,customerId:c==null?void 0:c.id,planId:s==null?void 0:s.id,resourceId:r,addons:n.addons,billableFeatures:n.billableFeatures,billingCountryCode:n.billingCountryCode,billingPeriod:n.billingPeriod,billingAddress:n.billingAddress,taxPercentage:n.taxPercentage,promotionCode:h!=null?h:n.promotionCode,onMockCheckoutPreview:t}):{subscriptionPreview:null,errorMessage:null}}),[e,c==null?void 0:c.id,s==null?void 0:s.id,r,n.addons,n.billableFeatures,n.billingCountryCode,n.billingPeriod,n.billingAddress,n.taxPercentage,n.promotionCode,o.isValid,t])}},qN=500,yE=({onMockCheckoutPreview:t}={})=>{let[e,n]=Uv.useState(null),[r,i]=Uv.useState(false),{previewSubscriptionAction:o}=Fv({onMockCheckoutPreview:t});return Uv.useEffect(()=>{let s=()=>ce(null,null,function*(){let{subscriptionPreview:p}=yield o();p&&n(p),i(false);});i(true);let c=setTimeout(()=>{i(true),s();},qN);return ()=>{clearTimeout(c);}},[o]),{subscriptionPreview:e,isFetchingSubscriptionPreview:r}};function bE({customer:t,taxPercentage:e}){return {useNewPaymentMethod:!(t!=null&&t.paymentMethodDetails),taxPercentage:e}}function YN(){let[,t]=Ye();return e=>t(n=>{n.paymentStep.useNewPaymentMethod=e;})}function QN(){let[,t]=Ye();return e=>t(n=>{n.paymentStep.errorMessage=e;})}function KN(){let[,t]=Ye();return e=>t(n=>{n.paymentStep.billingAddress=e;})}function XN(){let[{paymentStep:t}]=Ye();return t}function Pi(){let t=XN();return St(W({},t),{setUseNewPaymentMethod:YN(),setErrorMessage:QN(),setBillingAddress:KN()})}function vE(t){return zD__default.default({changePlan:"Change",billingPeriodsTitle:"Billing cycle",addAddonText:"Add",addonBillingPeriodNotAvailableText:({planBillingPeriod:n})=>n===be.Monthly?"Exclusively available on annual plans":"Exclusively available on monthly plans",newPaymentMethodText:"New payment method",newPaymentMethodBillingAddressTitle:"Billing address",newPaymentMethodCardTitle:"Payment method",summary:{title:"Order summary",planName:({plan:n})=>`${n.displayName} plan`,addCouponCodeText:"Add promotion code",couponCodeTitle:"Promotion code",addonsSectionTitle:"Add-ons",discountsSectionTitle:"Discounts",onlyPayAsYouGoText:"Varies by usage",startsAtText:"Starts at ",proratedTotalDueText:"Prorated charge today",baseChargeText:()=>"Base charge",totalText:"Total",totalDueText:"Total due today",totalBillingPeriodText:({billingPeriod:n})=>`Billed ${n.toLowerCase()}`,appliedCreditsTitle:"Applied credits",creditsForUnusedTimeText:({credits:n})=>`Your account will be granted credits worth ${n} for unused time, which will be automatically applied to future payments.`,discountText:({discountDetails:n,currency:r})=>{let i="";n.type===mb.Percentage?i=`${n.value}% off`:i=`${wn({amount:n.value,currency:r})}`;let o="";switch(n.durationType){case tm.Once:{o=" once";break}case tm.Repeating:{o=`${n.type===mb.Fixed?" per month":""} for ${n.durationInMonths} months`;break}case tm.Forever:default:o="";}return `${i}${o}`},taxTitle:({taxDetails:n})=>`Tax (${n==null?void 0:n.percentage}%)`,changesWillApplyAtEndOfBillingPeriod:({billingPeriodEnd:n})=>`Your changes will take effect at the end of your current billing cycle on ${G1__default.default(n).format("MMMM D, YYYY")}.`,checkoutSuccessText:"Changes applied",payAsYouGoTooltipText:"Billed according to actual usage"},checkoutButton:{nextText:"Next",noChangesText:"No changes",updateText:"Update subscription",downgradeToFreeText:"Cancel subscription",upgradeText:"Subscribe"},downgradeToFree:{alertText:()=>"We\u2019re sorry to see you cancel your paid subscription \u{1F62D}",freePlanHeader:()=>"New plan",freePlanName:({plan:n})=>`${n.displayName}`,freePlanPriceText:()=>"Free",paidPlanHeader:()=>"Current plan",paidPlanName:({plan:n})=>`${n.displayName}`,paidPlanPriceText:({billingPeriod:n})=>`Paid plan${n?`, billed ${n.toLowerCase()}`:""}`}},t)}var Jp={primary:"rgb(50, 126, 238)",textColor:"rgb(0, 30, 108)",backgroundColor:"rgb(255, 255, 255)",borderColor:"rgb(235, 237, 243)",summaryBackgroundColor:"rgb(109, 121, 144)"};function CE(t,e,n){let{palette:r}=t||{};return {primary:(e==null?void 0:e.primary)||(r==null?void 0:r.primary)||Jp.primary,textColor:(e==null?void 0:e.textColor)||(r==null?void 0:r.text.primary)||Jp.textColor,backgroundColor:(e==null?void 0:e.backgroundColor)||(r==null?void 0:r.backgroundPaper)||Jp.backgroundColor,borderColor:(e==null?void 0:e.borderColor)||(r==null?void 0:r.outlinedBorder)||Jp.borderColor,summaryBackgroundColor:(e==null?void 0:e.summaryBackgroundColor)||(r==null?void 0:r.backgroundHighlight)||Jp.summaryBackgroundColor,paymentInputBackgroundColor:e==null?void 0:e.paymentInputBackgroundColor,paymentInputBorderColor:e==null?void 0:e.paymentInputBorderColor,paymentInputBorderRadius:e==null?void 0:e.paymentInputBorderRadius}}var Nv=Uv__default.default.createContext(null);Nv.displayName="CheckoutContext";var Ye=()=>{let t=Uv.useContext(Nv);if(!t)throw new Error("Could not find Checkout context; You need to wrap your checkout components in an <CheckoutProvider> component.");return t},a3=({children:t,initialState:e})=>{let[n,r]=Uv.useState(e);Uv.useEffect(()=>{r(e);},[e]);let i=Uv.useCallback(c=>r(p=>immer.produce(p,h=>c(h))),[r]),[o,s]=Uv.useMemo(()=>[n,i],[i,n]);return jsxRuntime.jsx(Nv.Provider,{value:[o,s],children:t})};function PE({children:t,textOverrides:e,theme:n,preferredBillingPeriod:r,billableFeatures:i,resourceId:o,planId:s,billingCountryCode:c,billingInformation:p,onMockCheckoutState:h,skipCheckoutSteps:v,onBeforeStepChange:P}){var N;let{checkout:x,isLoading:T,showWatermark:I}=Sx({resourceId:o,planId:s,billingCountryCode:c,onMockCheckoutState:h}),R=x!=null&&x.configuration?OS(x.configuration):{typography:Gp(null,fm)},A=pc(R),O=Uv.useMemo(()=>{var ut,Y;let V=CE(A,n,x==null?void 0:x.configuration),G=vE(e),X=pE({preferredBillingPeriod:r,plan:x==null?void 0:x.plan,activeSubscription:x==null?void 0:x.activeSubscription,billingCountryCode:c,preconfiguredBillableFeatures:i!=null?i:[]}),nt=bx({plan:x==null?void 0:x.plan,activeSubscription:x==null?void 0:x.activeSubscription}),st=bE({customer:x==null?void 0:x.customer,taxPercentage:(ut=p==null?void 0:p.taxDetails)==null?void 0:ut.taxPercentage}),U=mE({isLoading:T,skipCheckoutSteps:v!=null?v:[],plan:x==null?void 0:x.plan,availableAddons:nt.availableAddons,availableCharges:X.billableFeatures,preferredBillingPeriod:r,preconfiguredBillableFeatures:i!=null?i:[]});return {checkout:x,checkoutLocalization:G,stiggTheme:A,theme:V,progressBar:U,planStep:X,addonsStep:nt,paymentStep:st,resourceId:(Y=x==null?void 0:x.resource)==null?void 0:Y.id,widgetState:{readOnly:false,isValid:true,isLoadingCheckoutData:T},showWatermark:I,checkoutSuccess:false,onBeforeStepChange:P}},[r,c,x,T,v,(N=p==null?void 0:p.taxDetails)==null?void 0:N.taxPercentage,P]);return jsxRuntime.jsx(vi,{componentTheme:R,children:jsxRuntime.jsx(a3,{initialState:O,children:t})},x==null?void 0:x.plan.id)}var EE=Q.div`
5313
5313
  margin: auto;
5314
5314
  min-height: 760px;
5315
5315
  max-width: 920px;
@@ -5352,7 +5352,7 @@ ${e.o5f}`,e.zBW=r.default`
5352
5352
  ${qr.md} {
5353
5353
  width: auto;
5354
5354
  }
5355
- `;var IE=Q(QO__default.default)(({theme:t,$disabled:e})=>({[`&.${QO.linearProgressClasses.root}`]:{borderRadius:t.stigg.border.radius,backgroundColor:t.stigg.palette.outlinedBorder},[`& .${QO.linearProgressClasses.bar}`]:{backgroundColor:e?t.stigg.palette.primaryLight:t.stigg.palette.primary}})),kE=Q(a2__default.default)({[`&.${a2.buttonClasses.root}`]:{textTransform:"none",lineHeight:"inherit",justifyContent:"flex-start",padding:"8px 4px"}}),DE=Q(qn)(({theme:t,$disabled:e,$shouldFill:n})=>({circle:{stroke:e?t.stigg.palette.primaryLight:t.stigg.palette.primary,fill:n?e?t.stigg.palette.primaryLight:t.stigg.palette.primary:void 0}}));var OE=()=>{let{progressBarState:t,setActiveStep:e,currentStep:n}=ha(),{widgetState:r}=ze(),i=Ci("md"),o=Uv.useRef(),{readOnly:s,isLoadingCheckoutData:c}=r,{activeStep:p,completedSteps:h,steps:v}=t||{},P=(p+1)*100/v.length,[x,T]=Uv__default.default.useState(n);return Uv.useEffect(()=>{i||o.current&&n!==x&&o.current.scrollIntoView({behavior:"smooth"}),T(n);},[n,i,x,T]),t.steps.length===1?null:jsxRuntime.jsxs(bg__default.default,{className:"stigg-checkout-progress-container",sx:{width:"100%",mb:3},ref:o,children:[jsxRuntime.jsx(IE,{variant:"determinate",value:P,$disabled:s}),jsxRuntime.jsx(da__default.default,{container:true,display:"flex",children:v.map(({key:I,label:F},A)=>{let O=h.includes(A),N=s||A>p&&!O&&!h.includes(A-1)||p!==A&&t.isDisabled;return jsxRuntime.jsx(da__default.default,{item:true,display:"flex",flexDirection:"row",flex:i?1:"auto",justifyContent:"flex-start",children:c?jsxRuntime.jsx(Un,{width:120,height:20,style:{marginTop:8}}):jsxRuntime.jsx(kE,{onClick:()=>e(A),fullWidth:true,disabled:N,children:jsxRuntime.jsxs(da__default.default,{item:true,display:"flex",flexDirection:"row",alignItems:"center",gap:1,children:[jsxRuntime.jsx(h3__default.default,{icon:jsxRuntime.jsx(DE,{icon:O?N?"OutlinedCheckedCircleDisabled":"OutlinedCheckedCircle":"OutlinedCircle",$disabled:N,$shouldFill:O})}),jsxRuntime.jsx(rt,{variant:"h6",color:N?"primary.main.light":"primary.main",children:F})]})})},I)})})]})};var y3=[nn.FlatFee,nn.PerUnit,nn.UsageBased],b3=t=>fx__default.default(t,[e=>y3.indexOf(e.pricingModel),e=>{var n;return (n=e.feature)==null?void 0:n.displayName}]),eg=t=>Uv.useMemo(()=>b3(t),[t]);function v3(){let[{promotionCode:t}]=Ye();return t}function C3(){let[,t]=Ye();return e=>t(n=>{n.promotionCode=e;})}function ng(){return {promotionCode:v3(),setPromotionCode:C3()}}var S3=t=>jsxRuntime.jsx("svg",St(W({width:20,height:20,viewBox:"0 0 20 20",fill:"none",xmlns:"http://www.w3.org/2000/svg"},t),{children:jsxRuntime.jsxs("g",{id:"plus",children:[jsxRuntime.jsx("path",{id:"Shape",d:"M10 4.16666V15.8333",stroke:"#327EEE",strokeWidth:2,strokeLinecap:"round",strokeLinejoin:"round"}),jsxRuntime.jsx("path",{id:"Shape_2",d:"M4.16699 10H15.8337",stroke:"#327EEE",strokeWidth:2,strokeLinecap:"round",strokeLinejoin:"round"})]})})),RE=S3;var x3=Q(RE)`
5355
+ `;var IE=Q(QO__default.default)(({theme:t,$disabled:e})=>({[`&.${QO.linearProgressClasses.root}`]:{borderRadius:t.stigg.border.radius,backgroundColor:t.stigg.palette.outlinedBorder},[`& .${QO.linearProgressClasses.bar}`]:{backgroundColor:e?t.stigg.palette.primaryLight:t.stigg.palette.primary}})),kE=Q(a2__default.default)({[`&.${a2.buttonClasses.root}`]:{textTransform:"none",lineHeight:"inherit",justifyContent:"flex-start",padding:"8px 4px"}}),DE=Q(qn)(({theme:t,$disabled:e,$shouldFill:n})=>({circle:{stroke:e?t.stigg.palette.primaryLight:t.stigg.palette.primary,fill:n?e?t.stigg.palette.primaryLight:t.stigg.palette.primary:void 0}}));var OE=()=>{let{progressBarState:t,setActiveStep:e,currentStep:n}=ha(),{widgetState:r}=ze(),i=Ci("md"),o=Uv.useRef(),{readOnly:s,isLoadingCheckoutData:c}=r,{activeStep:p,completedSteps:h,steps:v}=t||{},P=(p+1)*100/v.length,[x,T]=Uv__default.default.useState(n);return Uv.useEffect(()=>{i||o.current&&n!==x&&o.current.scrollIntoView({behavior:"smooth"}),T(n);},[n,i,x,T]),t.steps.length===1?null:jsxRuntime.jsxs(bg__default.default,{className:"stigg-checkout-progress-container",sx:{width:"100%",mb:3},ref:o,children:[jsxRuntime.jsx(IE,{variant:"determinate",value:P,$disabled:s}),jsxRuntime.jsx(da__default.default,{container:true,display:"flex",children:v.map(({key:I,label:R},A)=>{let O=h.includes(A),N=s||A>p&&!O&&!h.includes(A-1)||p!==A&&t.isDisabled;return jsxRuntime.jsx(da__default.default,{item:true,display:"flex",flexDirection:"row",flex:i?1:"auto",justifyContent:"flex-start",children:c?jsxRuntime.jsx(Un,{width:120,height:20,style:{marginTop:8}}):jsxRuntime.jsx(kE,{onClick:()=>e(A),fullWidth:true,disabled:N,children:jsxRuntime.jsxs(da__default.default,{item:true,display:"flex",flexDirection:"row",alignItems:"center",gap:1,children:[jsxRuntime.jsx(h3__default.default,{icon:jsxRuntime.jsx(DE,{icon:O?N?"OutlinedCheckedCircleDisabled":"OutlinedCheckedCircle":"OutlinedCircle",$disabled:N,$shouldFill:O})}),jsxRuntime.jsx(rt,{variant:"h6",color:N?"primary.main.light":"primary.main",children:R})]})})},I)})})]})};var y3=[nn.FlatFee,nn.PerUnit,nn.UsageBased],b3=t=>fx__default.default(t,[e=>y3.indexOf(e.pricingModel),e=>{var n;return (n=e.feature)==null?void 0:n.displayName}]),eg=t=>Uv.useMemo(()=>b3(t),[t]);function v3(){let[{promotionCode:t}]=Ye();return t}function C3(){let[,t]=Ye();return e=>t(n=>{n.promotionCode=e;})}function ng(){return {promotionCode:v3(),setPromotionCode:C3()}}var S3=t=>jsxRuntime.jsx("svg",St(W({width:20,height:20,viewBox:"0 0 20 20",fill:"none",xmlns:"http://www.w3.org/2000/svg"},t),{children:jsxRuntime.jsxs("g",{id:"plus",children:[jsxRuntime.jsx("path",{id:"Shape",d:"M10 4.16666V15.8333",stroke:"#327EEE",strokeWidth:2,strokeLinecap:"round",strokeLinejoin:"round"}),jsxRuntime.jsx("path",{id:"Shape_2",d:"M4.16699 10H15.8337",stroke:"#327EEE",strokeWidth:2,strokeLinecap:"round",strokeLinejoin:"round"})]})})),RE=S3;var x3=Q(RE)`
5356
5356
  margin-right: 8px;
5357
5357
  path {
5358
5358
  stroke: ${({theme:t,$disabled:e})=>e?t.stigg.palette.text.disabled:t.stigg.palette.primary};
@@ -5363,7 +5363,7 @@ ${e.o5f}`,e.zBW=r.default`
5363
5363
  border-radius: ${({theme:t})=>t.stigg.border.radius};
5364
5364
  display: flex;
5365
5365
  align-items: center;
5366
- `,NE=({disabled:t,checkoutLocalization:e,onMockCheckoutPreview:n})=>{let{setPromotionCode:r}=ng(),[i,o]=Uv.useState(false),[s,c]=Uv__default.default.useState(""),[p,h]=Uv__default.default.useState(false),[v,P]=Uv__default.default.useState(""),{previewSubscriptionAction:x}=Fv({onMockCheckoutPreview:n}),T=()=>ce(null,null,function*(){var A;h(true),P("");let{subscriptionPreview:I,errorMessage:F}=yield x({promotionCode:s});!F&&((A=I==null?void 0:I.immediateInvoice)!=null&&A.discountDetails)?(r(s.toUpperCase()),o(false)):F&&P(F),h(false);});return i?jsxRuntime.jsxs(da__default.default,{children:[jsxRuntime.jsx(rt,{variant:"body1",color:v?"error":t?"disabled":"primary.main",children:e.summary.couponCodeTitle}),jsxRuntime.jsx(Zs,{disabled:t,autoFocus:true,variant:"outlined",fullWidth:true,error:!!v,value:s,onChange:I=>{c(I.target.value);},inputProps:{maxLength:20},onKeyDown:I=>{I.key==="Enter"&&(T(),I.preventDefault());},InputProps:{endAdornment:jsxRuntime.jsx(I3,{variant:"contained",disabled:t,onClick:()=>{T();},children:p?jsxRuntime.jsx(T3__default.default,{size:18,sx:{color:"white"}}):jsxRuntime.jsx(qn,{style:{display:"flex"},icon:"ArrowForward"})})}}),!!v&&jsxRuntime.jsx(rt,{variant:"body1",color:"error",children:v})]}):jsxRuntime.jsx(ME,{disabled:t,onAddClick:()=>o(true),checkoutLocalization:e})};var D3=Q(da__default.default)`
5366
+ `,NE=({disabled:t,checkoutLocalization:e,onMockCheckoutPreview:n})=>{let{setPromotionCode:r}=ng(),[i,o]=Uv.useState(false),[s,c]=Uv__default.default.useState(""),[p,h]=Uv__default.default.useState(false),[v,P]=Uv__default.default.useState(""),{previewSubscriptionAction:x}=Fv({onMockCheckoutPreview:n}),T=()=>ce(null,null,function*(){var A;h(true),P("");let{subscriptionPreview:I,errorMessage:R}=yield x({promotionCode:s});!R&&((A=I==null?void 0:I.immediateInvoice)!=null&&A.discountDetails)?(r(s.toUpperCase()),o(false)):R&&P(R),h(false);});return i?jsxRuntime.jsxs(da__default.default,{children:[jsxRuntime.jsx(rt,{variant:"body1",color:v?"error":t?"disabled":"primary.main",children:e.summary.couponCodeTitle}),jsxRuntime.jsx(Zs,{disabled:t,autoFocus:true,variant:"outlined",fullWidth:true,error:!!v,value:s,onChange:I=>{c(I.target.value);},inputProps:{maxLength:20},onKeyDown:I=>{I.key==="Enter"&&(T(),I.preventDefault());},InputProps:{endAdornment:jsxRuntime.jsx(I3,{variant:"contained",disabled:t,onClick:()=>{T();},children:p?jsxRuntime.jsx(T3__default.default,{size:18,sx:{color:"white"}}):jsxRuntime.jsx(qn,{style:{display:"flex"},icon:"ArrowForward"})})}}),!!v&&jsxRuntime.jsx(rt,{variant:"body1",color:"error",children:v})]}):jsxRuntime.jsx(ME,{disabled:t,onAddClick:()=>o(true),checkoutLocalization:e})};var D3=Q(da__default.default)`
5367
5367
  width: auto;
5368
5368
  display: inline-flex;
5369
5369
  align-items: center;
@@ -5384,7 +5384,7 @@ ${e.o5f}`,e.zBW=r.default`
5384
5384
  }
5385
5385
  `,UE=({promotionCode:t,onClearPromotionCode:e})=>jsxRuntime.jsxs(D3,{container:true,children:[jsxRuntime.jsxs(da__default.default,{item:true,display:"flex",gap:1,alignItems:"center",children:[jsxRuntime.jsx(LE,{icon:"Coupon"}),jsxRuntime.jsx(rt,{variant:"body1",color:"primary.main",lineHeight:"auto",children:t})]}),jsxRuntime.jsx(da__default.default,{item:true,children:jsxRuntime.jsx($i,{variant:"text",sx:{minWidth:"unset",padding:0},onClick:e,children:jsxRuntime.jsx(LE,{icon:"Close",$shouldFill:true})})})]});var A3=Q.div`
5386
5386
  margin: 16px 0;
5387
- `,$E=({disabled:t,checkoutLocalization:e,onMockCheckoutPreview:n})=>{let{promotionCode:r,setPromotionCode:i}=ng();return jsxRuntime.jsx(A3,{children:r?jsxRuntime.jsx(UE,{promotionCode:r,onClearPromotionCode:()=>{i("");}}):jsxRuntime.jsx(NE,{disabled:t,checkoutLocalization:e,onMockCheckoutPreview:n})})};function GE({onBillingAddressChange:t,collectPhoneNumber:e}){var x;let{checkoutState:n,checkoutLocalization:r,widgetState:i,setWidgetReadOnly:o}=ze(),{setBillingAddress:s}=Pi(),{customer:c,configuration:p}=n||{},{readOnly:h}=i,v=!!(e!=null?e:(x=p==null?void 0:p.content)!=null&&x.collectPhoneNumber),P=T=>{if(!T.complete)return;let O=T.value.address,{postal_code:I}=O,F=On(O,["postal_code"]),A=W({postalCode:I},F);o(true),s(A),t?ce(null,null,function*(){yield t({billingAddress:A}),o(false);}):o(false);};return jsxRuntime.jsxs(da__default.default,{flexDirection:"column",container:true,gap:3,padding:"16px",sx:{pointerEvents:h?"none":void 0},children:[jsxRuntime.jsxs(da__default.default,{flexDirection:"column",container:true,gap:2,children:[jsxRuntime.jsx(rt,{variant:"h6",children:r.newPaymentMethodBillingAddressTitle}),jsxRuntime.jsx(reactStripeJs.AddressElement,{onChange:P,options:{mode:"billing",fields:{phone:v?"always":"auto"},defaultValues:W({},(c==null?void 0:c.name)&&{name:c.name})}})]}),jsxRuntime.jsxs(da__default.default,{flexDirection:"column",container:true,gap:2,children:[jsxRuntime.jsx(rt,{variant:"h6",children:r.newPaymentMethodCardTitle}),jsxRuntime.jsx(reactStripeJs.PaymentElement,{onChange:()=>{},onReady:()=>{},options:{readOnly:h,terms:{card:"never"},defaultValues:{billingDetails:W(W({},(c==null?void 0:c.name)&&{name:c.name}),(c==null?void 0:c.email)&&{email:c.email})}}})]})]})}function jE(){let[t,e]=Uv.useState(null),{checkoutState:n}=ze(),{billingIntegration:r,setupSecret:i}=n||{};return Uv.useEffect(()=>{if(r){let{billingIdentifier:o,credentials:s}=r;if(o!==Dp.Stripe)return;let{accountId:c,publicKey:p}=s;if(!c||!p){console.error("Stripe account ID or public key is missing");return}import('@stripe/stripe-js').then(({loadStripe:h})=>{e(h(p,{stripeAccount:c}));});}},[r]),{stripePromise:t,setupIntentClientSecret:i}}function ig(t){var r;let e=ve({optional:true}),n=e==null?void 0:e.stigg;return n?n.getBooleanEntitlement(t):W(W({},tC),(r=t.options)==null?void 0:r.fallback)}function og(t){var r;let e=ve({optional:true}),n=e==null?void 0:e.stigg;return n?n.getNumericEntitlement(t):W(W({},rC),(r=t.options)==null?void 0:r.fallback)}function ag(t){var r;let e=ve({optional:true}),n=e==null?void 0:e.stigg;return n?n.getMeteredEntitlement(t):W(W({},nC),(r=t.options)==null?void 0:r.fallback)}function sg(t){var r;let e=ve({optional:true}),n=e==null?void 0:e.stigg;return n?n.getEnumEntitlement(t):W(W({},eC),(r=t.options)==null?void 0:r.fallback)}function co({func:t}){let[e,n]=Uv.useState(true),[r,i]=Uv.useState(null),[o,s]=Uv.useState(null);return Uv.useEffect(()=>{ce(null,null,function*(){n(true);try{let p=yield t();s(p),i(null);}catch(p){i(p);}finally{n(false);}});},[t]),{isLoading:e,error:r,data:o}}function VE(t){let e=ve({optional:true}),n=e==null?void 0:e.stigg,r=Uv.useCallback(()=>n?n.getActiveSubscriptions(t):Promise.resolve([]),[t,n]),{data:i,error:o,isLoading:s}=co({func:r});return Uv.useMemo(()=>({activeSubscriptions:i,isLoading:s,error:o}),[i,o,s])}function zE(t){let e=ve({optional:true}),n=e==null?void 0:e.stigg,r=Uv.useCallback(()=>n?n.getPaywall(t):Promise.resolve(null),[t,n]),{data:i,error:o,isLoading:s}=co({func:r});return Uv.useMemo(()=>({paywall:i,isLoading:s,error:o}),[i,o,s])}function HE(t){let e=ve({optional:true}),n=e==null?void 0:e.stigg,r=Uv.useCallback(()=>n?n.getCustomerPortal(t):Promise.resolve(null),[t,n]),{data:i,error:o,isLoading:s}=co({func:r});return Uv.useMemo(()=>({customerPortal:i,isLoading:s,error:o}),[i,o,s])}function lg(){let t=Qu(),[{resourceId:e}]=Ye(),{checkoutState:n}=ze(),{plan:r}=n||{},i=t.addons.map(({addon:o,quantity:s})=>({addonId:o.id,quantity:s}));if(r!=null&&r.id)return {resourceId:e,planId:r.id,billingPeriod:t.billingPeriod,billableFeatures:t.billableFeatures,addons:i,promotionCode:t.promotionCode,billingCountryCode:t.billingCountryCode}}var V3=[em.Failed,em.Processing];function z3(e){return ce(this,arguments,function*({elements:t}){if(!t){let r="Stripe elements not initialized";return console.error(r),{success:false,errorMessage:r}}let{error:n}=yield t.submit();return n?(console.log(n.message),{success:false,errorMessage:n.message||""}):{success:true}})}function Hv(n){return ce(this,arguments,function*({applySubscriptionResults:t,stripe:e}){var s,c;let r=t==null?void 0:t.subscription,i=(s=r==null?void 0:r.latestInvoice)==null?void 0:s.paymentSecret,o=r==null?void 0:r.paymentCollection;if(e&&i&&o===em.ActionRequired){let{error:p}=yield e.handleNextAction({clientSecret:i});if(p)return {errorMessage:p.message||""}}else if(o&&V3.includes(o))return {errorMessage:((c=r==null?void 0:r.latestInvoice)==null?void 0:c.errorMessage)||"An error occurred - try again later"};return {subscription:r}})}function H3(r){return ce(this,arguments,function*({stripe:t,elements:e,clientSecret:n}){let i,o,{error:s}=yield t.confirmSetup({elements:e,confirmParams:{return_url:window.location.href},redirect:"if_required"});if(s)s.type==="card_error"||s.type==="validation_error"?s.type==="card_error"&&(o=s.message||""):o="An unexpected error occurred.";else try{let{setupIntent:c}=yield t.retrieveSetupIntent(n);c!=null&&c.payment_method&&(i=c.payment_method);}catch(c){o="An unexpected error occurred.",console.error(c);}return {newPaymentMethodId:i,setupErrorMessage:o}})}function WE(r){return ce(this,arguments,function*({stripe:t,elements:e,setupIntentClientSecret:n}){if(!t||!e||!n)return {success:false};let i=yield z3({elements:e});if(!i.success)return {success:false,errorMessage:i.errorMessage};let{newPaymentMethodId:o,setupErrorMessage:s}=yield H3({stripe:t,elements:e,clientSecret:n});return s||!o?{success:false,errorMessage:s}:{success:true,paymentMethodId:o}})}var qE={v:"5.12.1",fr:30,ip:0,op:201,w:700,h:700,nm:"Check",ddd:0,assets:[],layers:[{ddd:0,ind:1,ty:4,nm:"Shape Layer 8",sr:1,ks:{o:{a:0,k:100,ix:11},r:{a:0,k:315,ix:10},p:{a:0,k:[350,350,0],ix:2,l:2},a:{a:0,k:[-304,91,0],ix:1,l:2},s:{a:0,k:[100,100,100],ix:6,l:2}},ao:0,shapes:[{ty:"gr",it:[{ind:0,ty:"sh",ix:1,ks:{a:0,k:{i:[[0,0],[0,0]],o:[[0,0],[0,0]],v:[[-304,-241],[-304,-161]],c:false},ix:2},nm:"Path 1",mn:"ADBE Vector Shape - Group",hd:false},{ty:"st",c:{a:0,k:[1,1,1,1],ix:3},o:{a:0,k:100,ix:4},w:{a:0,k:9,ix:5},lc:2,lj:1,ml:4,bm:0,nm:"Stroke 1",mn:"ADBE Vector Graphic - Stroke",hd:false},{ty:"tr",p:{a:0,k:[0,0],ix:2},a:{a:0,k:[0,0],ix:1},s:{a:0,k:[100,100],ix:3},r:{a:0,k:0,ix:6},o:{a:0,k:100,ix:7},sk:{a:0,k:0,ix:4},sa:{a:0,k:0,ix:5},nm:"Transform"}],nm:"Shape 1",np:3,cix:2,bm:0,ix:1,mn:"ADBE Vector Group",hd:false},{ty:"tm",s:{a:1,k:[{i:{x:[.667],y:[1]},o:{x:[.333],y:[0]},t:135,s:[100]},{t:145.5,s:[0]}],ix:1},e:{a:1,k:[{i:{x:[.667],y:[1]},o:{x:[.333],y:[0]},t:130,s:[100]},{t:139.6005859375,s:[0]}],ix:2},o:{a:0,k:0,ix:3},m:1,ix:2,nm:"Trim Paths 1",mn:"ADBE Vector Filter - Trim",hd:false}],ip:130,op:204,st:-2,ct:1,bm:0},{ddd:0,ind:2,ty:4,nm:"Shape Layer 7",sr:1,ks:{o:{a:0,k:100,ix:11},r:{a:0,k:270,ix:10},p:{a:0,k:[350,350,0],ix:2,l:2},a:{a:0,k:[-304,91,0],ix:1,l:2},s:{a:0,k:[100,100,100],ix:6,l:2}},ao:0,shapes:[{ty:"gr",it:[{ind:0,ty:"sh",ix:1,ks:{a:0,k:{i:[[0,0],[0,0]],o:[[0,0],[0,0]],v:[[-304,-241],[-304,-161]],c:false},ix:2},nm:"Path 1",mn:"ADBE Vector Shape - Group",hd:false},{ty:"st",c:{a:0,k:[1,1,1,1],ix:3},o:{a:0,k:100,ix:4},w:{a:0,k:9,ix:5},lc:2,lj:1,ml:4,bm:0,nm:"Stroke 1",mn:"ADBE Vector Graphic - Stroke",hd:false},{ty:"tr",p:{a:0,k:[0,0],ix:2},a:{a:0,k:[0,0],ix:1},s:{a:0,k:[100,100],ix:3},r:{a:0,k:0,ix:6},o:{a:0,k:100,ix:7},sk:{a:0,k:0,ix:4},sa:{a:0,k:0,ix:5},nm:"Transform"}],nm:"Shape 1",np:3,cix:2,bm:0,ix:1,mn:"ADBE Vector Group",hd:false},{ty:"tm",s:{a:1,k:[{i:{x:[.667],y:[1]},o:{x:[.333],y:[0]},t:135,s:[100]},{t:145.5,s:[0]}],ix:1},e:{a:1,k:[{i:{x:[.667],y:[1]},o:{x:[.333],y:[0]},t:130,s:[100]},{t:139.6005859375,s:[0]}],ix:2},o:{a:0,k:0,ix:3},m:1,ix:2,nm:"Trim Paths 1",mn:"ADBE Vector Filter - Trim",hd:false}],ip:130,op:204,st:-2,ct:1,bm:0},{ddd:0,ind:3,ty:4,nm:"Shape Layer 6",sr:1,ks:{o:{a:0,k:100,ix:11},r:{a:0,k:225,ix:10},p:{a:0,k:[350,350,0],ix:2,l:2},a:{a:0,k:[-304,91,0],ix:1,l:2},s:{a:0,k:[100,100,100],ix:6,l:2}},ao:0,shapes:[{ty:"gr",it:[{ind:0,ty:"sh",ix:1,ks:{a:0,k:{i:[[0,0],[0,0]],o:[[0,0],[0,0]],v:[[-304,-241],[-304,-161]],c:false},ix:2},nm:"Path 1",mn:"ADBE Vector Shape - Group",hd:false},{ty:"st",c:{a:0,k:[1,1,1,1],ix:3},o:{a:0,k:100,ix:4},w:{a:0,k:9,ix:5},lc:2,lj:1,ml:4,bm:0,nm:"Stroke 1",mn:"ADBE Vector Graphic - Stroke",hd:false},{ty:"tr",p:{a:0,k:[0,0],ix:2},a:{a:0,k:[0,0],ix:1},s:{a:0,k:[100,100],ix:3},r:{a:0,k:0,ix:6},o:{a:0,k:100,ix:7},sk:{a:0,k:0,ix:4},sa:{a:0,k:0,ix:5},nm:"Transform"}],nm:"Shape 1",np:3,cix:2,bm:0,ix:1,mn:"ADBE Vector Group",hd:false},{ty:"tm",s:{a:1,k:[{i:{x:[.667],y:[1]},o:{x:[.333],y:[0]},t:135,s:[100]},{t:145.5,s:[0]}],ix:1},e:{a:1,k:[{i:{x:[.667],y:[1]},o:{x:[.333],y:[0]},t:130,s:[100]},{t:139.6005859375,s:[0]}],ix:2},o:{a:0,k:0,ix:3},m:1,ix:2,nm:"Trim Paths 1",mn:"ADBE Vector Filter - Trim",hd:false}],ip:130,op:204,st:-2,ct:1,bm:0},{ddd:0,ind:4,ty:4,nm:"Shape Layer 5",sr:1,ks:{o:{a:0,k:100,ix:11},r:{a:0,k:180,ix:10},p:{a:0,k:[350,350,0],ix:2,l:2},a:{a:0,k:[-304,91,0],ix:1,l:2},s:{a:0,k:[100,100,100],ix:6,l:2}},ao:0,shapes:[{ty:"gr",it:[{ind:0,ty:"sh",ix:1,ks:{a:0,k:{i:[[0,0],[0,0]],o:[[0,0],[0,0]],v:[[-304,-241],[-304,-161]],c:false},ix:2},nm:"Path 1",mn:"ADBE Vector Shape - Group",hd:false},{ty:"st",c:{a:0,k:[1,1,1,1],ix:3},o:{a:0,k:100,ix:4},w:{a:0,k:9,ix:5},lc:2,lj:1,ml:4,bm:0,nm:"Stroke 1",mn:"ADBE Vector Graphic - Stroke",hd:false},{ty:"tr",p:{a:0,k:[0,0],ix:2},a:{a:0,k:[0,0],ix:1},s:{a:0,k:[100,100],ix:3},r:{a:0,k:0,ix:6},o:{a:0,k:100,ix:7},sk:{a:0,k:0,ix:4},sa:{a:0,k:0,ix:5},nm:"Transform"}],nm:"Shape 1",np:3,cix:2,bm:0,ix:1,mn:"ADBE Vector Group",hd:false},{ty:"tm",s:{a:1,k:[{i:{x:[.667],y:[1]},o:{x:[.333],y:[0]},t:135,s:[100]},{t:145.5,s:[0]}],ix:1},e:{a:1,k:[{i:{x:[.667],y:[1]},o:{x:[.333],y:[0]},t:130,s:[100]},{t:139.6005859375,s:[0]}],ix:2},o:{a:0,k:0,ix:3},m:1,ix:2,nm:"Trim Paths 1",mn:"ADBE Vector Filter - Trim",hd:false}],ip:130,op:204,st:-2,ct:1,bm:0},{ddd:0,ind:5,ty:4,nm:"Shape Layer 4",sr:1,ks:{o:{a:0,k:100,ix:11},r:{a:0,k:135,ix:10},p:{a:0,k:[350,350,0],ix:2,l:2},a:{a:0,k:[-304,91,0],ix:1,l:2},s:{a:0,k:[100,100,100],ix:6,l:2}},ao:0,shapes:[{ty:"gr",it:[{ind:0,ty:"sh",ix:1,ks:{a:0,k:{i:[[0,0],[0,0]],o:[[0,0],[0,0]],v:[[-304,-241],[-304,-161]],c:false},ix:2},nm:"Path 1",mn:"ADBE Vector Shape - Group",hd:false},{ty:"st",c:{a:0,k:[1,1,1,1],ix:3},o:{a:0,k:100,ix:4},w:{a:0,k:9,ix:5},lc:2,lj:1,ml:4,bm:0,nm:"Stroke 1",mn:"ADBE Vector Graphic - Stroke",hd:false},{ty:"tr",p:{a:0,k:[0,0],ix:2},a:{a:0,k:[0,0],ix:1},s:{a:0,k:[100,100],ix:3},r:{a:0,k:0,ix:6},o:{a:0,k:100,ix:7},sk:{a:0,k:0,ix:4},sa:{a:0,k:0,ix:5},nm:"Transform"}],nm:"Shape 1",np:3,cix:2,bm:0,ix:1,mn:"ADBE Vector Group",hd:false},{ty:"tm",s:{a:1,k:[{i:{x:[.667],y:[1]},o:{x:[.333],y:[0]},t:135,s:[100]},{t:145.5,s:[0]}],ix:1},e:{a:1,k:[{i:{x:[.667],y:[1]},o:{x:[.333],y:[0]},t:130,s:[100]},{t:139.6005859375,s:[0]}],ix:2},o:{a:0,k:0,ix:3},m:1,ix:2,nm:"Trim Paths 1",mn:"ADBE Vector Filter - Trim",hd:false}],ip:130,op:204,st:-2,ct:1,bm:0},{ddd:0,ind:6,ty:4,nm:"Shape Layer 3",sr:1,ks:{o:{a:0,k:100,ix:11},r:{a:0,k:90,ix:10},p:{a:0,k:[350,350,0],ix:2,l:2},a:{a:0,k:[-304,91,0],ix:1,l:2},s:{a:0,k:[100,100,100],ix:6,l:2}},ao:0,shapes:[{ty:"gr",it:[{ind:0,ty:"sh",ix:1,ks:{a:0,k:{i:[[0,0],[0,0]],o:[[0,0],[0,0]],v:[[-304,-241],[-304,-161]],c:false},ix:2},nm:"Path 1",mn:"ADBE Vector Shape - Group",hd:false},{ty:"st",c:{a:0,k:[1,1,1,1],ix:3},o:{a:0,k:100,ix:4},w:{a:0,k:9,ix:5},lc:2,lj:1,ml:4,bm:0,nm:"Stroke 1",mn:"ADBE Vector Graphic - Stroke",hd:false},{ty:"tr",p:{a:0,k:[0,0],ix:2},a:{a:0,k:[0,0],ix:1},s:{a:0,k:[100,100],ix:3},r:{a:0,k:0,ix:6},o:{a:0,k:100,ix:7},sk:{a:0,k:0,ix:4},sa:{a:0,k:0,ix:5},nm:"Transform"}],nm:"Shape 1",np:3,cix:2,bm:0,ix:1,mn:"ADBE Vector Group",hd:false},{ty:"tm",s:{a:1,k:[{i:{x:[.667],y:[1]},o:{x:[.333],y:[0]},t:135,s:[100]},{t:145.5,s:[0]}],ix:1},e:{a:1,k:[{i:{x:[.667],y:[1]},o:{x:[.333],y:[0]},t:130,s:[100]},{t:139.6005859375,s:[0]}],ix:2},o:{a:0,k:0,ix:3},m:1,ix:2,nm:"Trim Paths 1",mn:"ADBE Vector Filter - Trim",hd:false}],ip:130,op:204,st:-2,ct:1,bm:0},{ddd:0,ind:7,ty:4,nm:"Shape Layer 2",sr:1,ks:{o:{a:0,k:100,ix:11},r:{a:0,k:45,ix:10},p:{a:0,k:[350,350,0],ix:2,l:2},a:{a:0,k:[-304,91,0],ix:1,l:2},s:{a:0,k:[100,100,100],ix:6,l:2}},ao:0,shapes:[{ty:"gr",it:[{ind:0,ty:"sh",ix:1,ks:{a:0,k:{i:[[0,0],[0,0]],o:[[0,0],[0,0]],v:[[-304,-241],[-304,-161]],c:false},ix:2},nm:"Path 1",mn:"ADBE Vector Shape - Group",hd:false},{ty:"st",c:{a:0,k:[1,1,1,1],ix:3},o:{a:0,k:100,ix:4},w:{a:0,k:9,ix:5},lc:2,lj:1,ml:4,bm:0,nm:"Stroke 1",mn:"ADBE Vector Graphic - Stroke",hd:false},{ty:"tr",p:{a:0,k:[0,0],ix:2},a:{a:0,k:[0,0],ix:1},s:{a:0,k:[100,100],ix:3},r:{a:0,k:0,ix:6},o:{a:0,k:100,ix:7},sk:{a:0,k:0,ix:4},sa:{a:0,k:0,ix:5},nm:"Transform"}],nm:"Shape 1",np:3,cix:2,bm:0,ix:1,mn:"ADBE Vector Group",hd:false},{ty:"tm",s:{a:1,k:[{i:{x:[.667],y:[1]},o:{x:[.333],y:[0]},t:135,s:[100]},{t:145.5,s:[0]}],ix:1},e:{a:1,k:[{i:{x:[.667],y:[1]},o:{x:[.333],y:[0]},t:130,s:[100]},{t:139.6005859375,s:[0]}],ix:2},o:{a:0,k:0,ix:3},m:1,ix:2,nm:"Trim Paths 1",mn:"ADBE Vector Filter - Trim",hd:false}],ip:130,op:204,st:-2,ct:1,bm:0},{ddd:0,ind:8,ty:4,nm:"Shape Layer 1",sr:1,ks:{o:{a:0,k:100,ix:11},r:{a:0,k:0,ix:10},p:{a:0,k:[350,350,0],ix:2,l:2},a:{a:0,k:[-304,91,0],ix:1,l:2},s:{a:0,k:[100,100,100],ix:6,l:2}},ao:0,shapes:[{ty:"gr",it:[{ind:0,ty:"sh",ix:1,ks:{a:0,k:{i:[[0,0],[0,0]],o:[[0,0],[0,0]],v:[[-304,-241],[-304,-161]],c:false},ix:2},nm:"Path 1",mn:"ADBE Vector Shape - Group",hd:false},{ty:"st",c:{a:0,k:[1,1,1,1],ix:3},o:{a:0,k:100,ix:4},w:{a:0,k:9,ix:5},lc:2,lj:1,ml:4,bm:0,nm:"Stroke 1",mn:"ADBE Vector Graphic - Stroke",hd:false},{ty:"tr",p:{a:0,k:[0,0],ix:2},a:{a:0,k:[0,0],ix:1},s:{a:0,k:[100,100],ix:3},r:{a:0,k:0,ix:6},o:{a:0,k:100,ix:7},sk:{a:0,k:0,ix:4},sa:{a:0,k:0,ix:5},nm:"Transform"}],nm:"Shape 1",np:3,cix:2,bm:0,ix:1,mn:"ADBE Vector Group",hd:false},{ty:"tm",s:{a:1,k:[{i:{x:[.667],y:[1]},o:{x:[.333],y:[0]},t:135,s:[100]},{t:145.5,s:[0]}],ix:1},e:{a:1,k:[{i:{x:[.667],y:[1]},o:{x:[.333],y:[0]},t:130,s:[100]},{t:139.6005859375,s:[0]}],ix:2},o:{a:0,k:0,ix:3},m:1,ix:2,nm:"Trim Paths 1",mn:"ADBE Vector Filter - Trim",hd:false}],ip:130,op:204,st:-2,ct:1,bm:0},{ddd:0,ind:9,ty:4,nm:"Check v",sr:1,ks:{o:{a:0,k:100,ix:11},r:{a:0,k:-1.9,ix:10},p:{a:0,k:[352,360,0],ix:2,l:2},a:{a:0,k:[-120.265,116.765,0],ix:1,l:2},s:{a:0,k:[278,278,100],ix:6,l:2}},ao:0,shapes:[{ty:"gr",it:[{ind:0,ty:"sh",ix:1,ks:{a:0,k:{i:[[0,0],[0,0],[0,0]],o:[[0,0],[0,0],[0,0]],v:[[-161,123],[-137,148],[-79.531,85.531]],c:false},ix:2},nm:"Path 1",mn:"ADBE Vector Shape - Group",hd:false},{ty:"st",c:{a:0,k:[1,1,1,1],ix:3},o:{a:0,k:100,ix:4},w:{a:0,k:5.5,ix:5},lc:2,lj:2,bm:0,nm:"Stroke 1",mn:"ADBE Vector Graphic - Stroke",hd:false},{ty:"tr",p:{a:0,k:[0,0],ix:2},a:{a:0,k:[0,0],ix:1},s:{a:0,k:[100,100],ix:3},r:{a:0,k:0,ix:6},o:{a:0,k:100,ix:7},sk:{a:0,k:0,ix:4},sa:{a:0,k:0,ix:5},nm:"Transform"}],nm:"Shape 1",np:3,cix:2,bm:0,ix:1,mn:"ADBE Vector Group",hd:false},{ty:"tm",s:{a:1,k:[{i:{x:[0],y:[1]},o:{x:[.333],y:[0]},t:135,s:[0]},{t:148,s:[100]}],ix:1},e:{a:0,k:0,ix:2},o:{a:0,k:0,ix:3},m:1,ix:2,nm:"Trim Paths 1",mn:"ADBE Vector Filter - Trim",hd:false}],ip:135,op:201,st:-35,ct:1,bm:0},{ddd:0,ind:11,ty:4,nm:"Circle Stroke",sr:1,ks:{o:{a:1,k:[{i:{x:[.833],y:[.833]},o:{x:[.167],y:[.167]},t:0,s:[0]},{t:7,s:[100]}],ix:11},r:{a:0,k:0,ix:10},p:{a:0,k:[350,350,0],ix:2,l:2},a:{a:0,k:[4,-6,0],ix:1,l:2},s:{a:0,k:[132,132,100],ix:6,l:2}},ao:0,shapes:[{ty:"gr",it:[{d:1,ty:"el",s:{a:0,k:[306,306],ix:2},p:{a:0,k:[0,0],ix:3},nm:"Ellipse Path 1",mn:"ADBE Vector Shape - Ellipse",hd:false},{ty:"st",c:{a:1,k:[{i:{x:[.833],y:[.833]},o:{x:[.167],y:[.167]},t:0,s:[1,1,1,1]},{i:{x:[.833],y:[.833]},o:{x:[.167],y:[.167]},t:30,s:[1,1,1,1]},{i:{x:[.833],y:[.833]},o:{x:[.167],y:[.167]},t:61,s:[1,1,1,1]},{i:{x:[.833],y:[.833]},o:{x:[.167],y:[.167]},t:87,s:[1,1,1,1]},{t:136,s:[1,1,1,1]}],ix:3},o:{a:0,k:100,ix:4},w:{a:0,k:8,ix:5},lc:2,lj:1,ml:4,bm:0,nm:"Stroke 1",mn:"ADBE Vector Graphic - Stroke",hd:false},{ty:"tr",p:{a:0,k:[4,-6],ix:2},a:{a:0,k:[0,0],ix:1},s:{a:0,k:[100,100],ix:3},r:{a:0,k:0,ix:6},o:{a:0,k:100,ix:7},sk:{a:0,k:0,ix:4},sa:{a:0,k:0,ix:5},nm:"Transform"}],nm:"Ellipse 1",np:3,cix:2,bm:0,ix:1,mn:"ADBE Vector Group",hd:false},{ty:"tm",s:{a:1,k:[{i:{x:[.338],y:[1]},o:{x:[.333],y:[0]},t:87,s:[50]},{t:122,s:[100]}],ix:1},e:{a:1,k:[{i:{x:[.338],y:[1]},o:{x:[.333],y:[0]},t:87,s:[45]},{t:122,s:[0]}],ix:2},o:{a:1,k:[{i:{x:[.474],y:[1]},o:{x:[.43],y:[0]},t:0,s:[-170.4]},{t:111,s:[-1250.4]}],ix:3},m:1,ix:2,nm:"Trim Paths 1",mn:"ADBE Vector Filter - Trim",hd:false}],ip:0,op:201,st:0,ct:1,bm:0},{ddd:0,ind:13,ty:1,nm:"Dark Gray Solid 1",sr:1,ks:{o:{a:0,k:100,ix:11},r:{a:0,k:0,ix:10},p:{a:0,k:[350,350,0],ix:2,l:2},a:{a:0,k:[350,350,0],ix:1,l:2},s:{a:0,k:[100,100,100],ix:6,l:2}},ao:0,sw:700,sh:700,sc:"#2d2d2d",ip:0,op:201,st:0,bm:0}],markers:[],props:{}};var cg=5e3,X3=Q(bg__default.default)`
5387
+ `,$E=({disabled:t,checkoutLocalization:e,onMockCheckoutPreview:n})=>{let{promotionCode:r,setPromotionCode:i}=ng();return jsxRuntime.jsx(A3,{children:r?jsxRuntime.jsx(UE,{promotionCode:r,onClearPromotionCode:()=>{i("");}}):jsxRuntime.jsx(NE,{disabled:t,checkoutLocalization:e,onMockCheckoutPreview:n})})};function GE({onBillingAddressChange:t,collectPhoneNumber:e}){var x;let{checkoutState:n,checkoutLocalization:r,widgetState:i,setWidgetReadOnly:o}=ze(),{setBillingAddress:s}=Pi(),{customer:c,configuration:p}=n||{},{readOnly:h}=i,v=!!(e!=null?e:(x=p==null?void 0:p.content)!=null&&x.collectPhoneNumber),P=T=>{if(!T.complete)return;let O=T.value.address,{postal_code:I}=O,R=On(O,["postal_code"]),A=W({postalCode:I},R);o(true),s(A),t?ce(null,null,function*(){yield t({billingAddress:A}),o(false);}):o(false);};return jsxRuntime.jsxs(da__default.default,{flexDirection:"column",container:true,gap:3,padding:"16px",sx:{pointerEvents:h?"none":void 0},children:[jsxRuntime.jsxs(da__default.default,{flexDirection:"column",container:true,gap:2,children:[jsxRuntime.jsx(rt,{variant:"h6",children:r.newPaymentMethodBillingAddressTitle}),jsxRuntime.jsx(reactStripeJs.AddressElement,{onChange:P,options:{mode:"billing",fields:{phone:v?"always":"auto"},defaultValues:W({},(c==null?void 0:c.name)&&{name:c.name})}})]}),jsxRuntime.jsxs(da__default.default,{flexDirection:"column",container:true,gap:2,children:[jsxRuntime.jsx(rt,{variant:"h6",children:r.newPaymentMethodCardTitle}),jsxRuntime.jsx(reactStripeJs.PaymentElement,{onChange:()=>{},onReady:()=>{},options:{readOnly:h,terms:{card:"never"},defaultValues:{billingDetails:W(W({},(c==null?void 0:c.name)&&{name:c.name}),(c==null?void 0:c.email)&&{email:c.email})}}})]})]})}function jE(){let[t,e]=Uv.useState(null),{checkoutState:n}=ze(),{billingIntegration:r,setupSecret:i}=n||{};return Uv.useEffect(()=>{if(r){let{billingIdentifier:o,credentials:s}=r;if(o!==Dp.Stripe)return;let{accountId:c,publicKey:p}=s;if(!c||!p){console.error("Stripe account ID or public key is missing");return}import('@stripe/stripe-js').then(({loadStripe:h})=>{e(h(p,{stripeAccount:c}));});}},[r]),{stripePromise:t,setupIntentClientSecret:i}}function ig(t){var r;let e=ve({optional:true}),n=e==null?void 0:e.stigg;return n?n.getBooleanEntitlement(t):W(W({},tC),(r=t.options)==null?void 0:r.fallback)}function og(t){var r;let e=ve({optional:true}),n=e==null?void 0:e.stigg;return n?n.getNumericEntitlement(t):W(W({},rC),(r=t.options)==null?void 0:r.fallback)}function ag(t){var r;let e=ve({optional:true}),n=e==null?void 0:e.stigg;return n?n.getMeteredEntitlement(t):W(W({},nC),(r=t.options)==null?void 0:r.fallback)}function sg(t){var r;let e=ve({optional:true}),n=e==null?void 0:e.stigg;return n?n.getEnumEntitlement(t):W(W({},eC),(r=t.options)==null?void 0:r.fallback)}function co({func:t}){let[e,n]=Uv.useState(true),[r,i]=Uv.useState(null),[o,s]=Uv.useState(null);return Uv.useEffect(()=>{ce(null,null,function*(){n(true);try{let p=yield t();s(p),i(null);}catch(p){i(p);}finally{n(false);}});},[t]),{isLoading:e,error:r,data:o}}function VE(t){let e=ve({optional:true}),n=e==null?void 0:e.stigg,r=Uv.useCallback(()=>n?n.getActiveSubscriptions(t):Promise.resolve([]),[t,n]),{data:i,error:o,isLoading:s}=co({func:r});return Uv.useMemo(()=>({activeSubscriptions:i,isLoading:s,error:o}),[i,o,s])}function zE(t){let e=ve({optional:true}),n=e==null?void 0:e.stigg,r=Uv.useCallback(()=>n?n.getPaywall(t):Promise.resolve(null),[t,n]),{data:i,error:o,isLoading:s}=co({func:r});return Uv.useMemo(()=>({paywall:i,isLoading:s,error:o}),[i,o,s])}function HE(t){let e=ve({optional:true}),n=e==null?void 0:e.stigg,r=Uv.useCallback(()=>n?n.getCustomerPortal(t):Promise.resolve(null),[t,n]),{data:i,error:o,isLoading:s}=co({func:r});return Uv.useMemo(()=>({customerPortal:i,isLoading:s,error:o}),[i,o,s])}function lg(){let t=Qu(),[{resourceId:e}]=Ye(),{checkoutState:n}=ze(),{plan:r}=n||{},i=t.addons.map(({addon:o,quantity:s})=>({addonId:o.id,quantity:s}));if(r!=null&&r.id)return {resourceId:e,planId:r.id,billingPeriod:t.billingPeriod,billableFeatures:t.billableFeatures,addons:i,promotionCode:t.promotionCode,billingCountryCode:t.billingCountryCode}}var V3=[em.Failed,em.Processing];function z3(e){return ce(this,arguments,function*({elements:t}){if(!t){let r="Stripe elements not initialized";return console.error(r),{success:false,errorMessage:r}}let{error:n}=yield t.submit();return n?(console.log(n.message),{success:false,errorMessage:n.message||""}):{success:true}})}function Hv(n){return ce(this,arguments,function*({applySubscriptionResults:t,stripe:e}){var s,c;let r=t==null?void 0:t.subscription,i=(s=r==null?void 0:r.latestInvoice)==null?void 0:s.paymentSecret,o=r==null?void 0:r.paymentCollection;if(e&&i&&o===em.ActionRequired){let{error:p}=yield e.handleNextAction({clientSecret:i});if(p)return {errorMessage:p.message||""}}else if(o&&V3.includes(o))return {errorMessage:((c=r==null?void 0:r.latestInvoice)==null?void 0:c.errorMessage)||"An error occurred - try again later"};return {subscription:r}})}function H3(r){return ce(this,arguments,function*({stripe:t,elements:e,clientSecret:n}){let i,o,{error:s}=yield t.confirmSetup({elements:e,confirmParams:{return_url:window.location.href},redirect:"if_required"});if(s)s.type==="card_error"||s.type==="validation_error"?s.type==="card_error"&&(o=s.message||""):o="An unexpected error occurred.";else try{let{setupIntent:c}=yield t.retrieveSetupIntent(n);c!=null&&c.payment_method&&(i=c.payment_method);}catch(c){o="An unexpected error occurred.",console.error(c);}return {newPaymentMethodId:i,setupErrorMessage:o}})}function WE(r){return ce(this,arguments,function*({stripe:t,elements:e,setupIntentClientSecret:n}){if(!t||!e||!n)return {success:false};let i=yield z3({elements:e});if(!i.success)return {success:false,errorMessage:i.errorMessage};let{newPaymentMethodId:o,setupErrorMessage:s}=yield H3({stripe:t,elements:e,clientSecret:n});return s||!o?{success:false,errorMessage:s}:{success:true,paymentMethodId:o}})}var qE={v:"5.12.1",fr:30,ip:0,op:201,w:700,h:700,nm:"Check",ddd:0,assets:[],layers:[{ddd:0,ind:1,ty:4,nm:"Shape Layer 8",sr:1,ks:{o:{a:0,k:100,ix:11},r:{a:0,k:315,ix:10},p:{a:0,k:[350,350,0],ix:2,l:2},a:{a:0,k:[-304,91,0],ix:1,l:2},s:{a:0,k:[100,100,100],ix:6,l:2}},ao:0,shapes:[{ty:"gr",it:[{ind:0,ty:"sh",ix:1,ks:{a:0,k:{i:[[0,0],[0,0]],o:[[0,0],[0,0]],v:[[-304,-241],[-304,-161]],c:false},ix:2},nm:"Path 1",mn:"ADBE Vector Shape - Group",hd:false},{ty:"st",c:{a:0,k:[1,1,1,1],ix:3},o:{a:0,k:100,ix:4},w:{a:0,k:9,ix:5},lc:2,lj:1,ml:4,bm:0,nm:"Stroke 1",mn:"ADBE Vector Graphic - Stroke",hd:false},{ty:"tr",p:{a:0,k:[0,0],ix:2},a:{a:0,k:[0,0],ix:1},s:{a:0,k:[100,100],ix:3},r:{a:0,k:0,ix:6},o:{a:0,k:100,ix:7},sk:{a:0,k:0,ix:4},sa:{a:0,k:0,ix:5},nm:"Transform"}],nm:"Shape 1",np:3,cix:2,bm:0,ix:1,mn:"ADBE Vector Group",hd:false},{ty:"tm",s:{a:1,k:[{i:{x:[.667],y:[1]},o:{x:[.333],y:[0]},t:135,s:[100]},{t:145.5,s:[0]}],ix:1},e:{a:1,k:[{i:{x:[.667],y:[1]},o:{x:[.333],y:[0]},t:130,s:[100]},{t:139.6005859375,s:[0]}],ix:2},o:{a:0,k:0,ix:3},m:1,ix:2,nm:"Trim Paths 1",mn:"ADBE Vector Filter - Trim",hd:false}],ip:130,op:204,st:-2,ct:1,bm:0},{ddd:0,ind:2,ty:4,nm:"Shape Layer 7",sr:1,ks:{o:{a:0,k:100,ix:11},r:{a:0,k:270,ix:10},p:{a:0,k:[350,350,0],ix:2,l:2},a:{a:0,k:[-304,91,0],ix:1,l:2},s:{a:0,k:[100,100,100],ix:6,l:2}},ao:0,shapes:[{ty:"gr",it:[{ind:0,ty:"sh",ix:1,ks:{a:0,k:{i:[[0,0],[0,0]],o:[[0,0],[0,0]],v:[[-304,-241],[-304,-161]],c:false},ix:2},nm:"Path 1",mn:"ADBE Vector Shape - Group",hd:false},{ty:"st",c:{a:0,k:[1,1,1,1],ix:3},o:{a:0,k:100,ix:4},w:{a:0,k:9,ix:5},lc:2,lj:1,ml:4,bm:0,nm:"Stroke 1",mn:"ADBE Vector Graphic - Stroke",hd:false},{ty:"tr",p:{a:0,k:[0,0],ix:2},a:{a:0,k:[0,0],ix:1},s:{a:0,k:[100,100],ix:3},r:{a:0,k:0,ix:6},o:{a:0,k:100,ix:7},sk:{a:0,k:0,ix:4},sa:{a:0,k:0,ix:5},nm:"Transform"}],nm:"Shape 1",np:3,cix:2,bm:0,ix:1,mn:"ADBE Vector Group",hd:false},{ty:"tm",s:{a:1,k:[{i:{x:[.667],y:[1]},o:{x:[.333],y:[0]},t:135,s:[100]},{t:145.5,s:[0]}],ix:1},e:{a:1,k:[{i:{x:[.667],y:[1]},o:{x:[.333],y:[0]},t:130,s:[100]},{t:139.6005859375,s:[0]}],ix:2},o:{a:0,k:0,ix:3},m:1,ix:2,nm:"Trim Paths 1",mn:"ADBE Vector Filter - Trim",hd:false}],ip:130,op:204,st:-2,ct:1,bm:0},{ddd:0,ind:3,ty:4,nm:"Shape Layer 6",sr:1,ks:{o:{a:0,k:100,ix:11},r:{a:0,k:225,ix:10},p:{a:0,k:[350,350,0],ix:2,l:2},a:{a:0,k:[-304,91,0],ix:1,l:2},s:{a:0,k:[100,100,100],ix:6,l:2}},ao:0,shapes:[{ty:"gr",it:[{ind:0,ty:"sh",ix:1,ks:{a:0,k:{i:[[0,0],[0,0]],o:[[0,0],[0,0]],v:[[-304,-241],[-304,-161]],c:false},ix:2},nm:"Path 1",mn:"ADBE Vector Shape - Group",hd:false},{ty:"st",c:{a:0,k:[1,1,1,1],ix:3},o:{a:0,k:100,ix:4},w:{a:0,k:9,ix:5},lc:2,lj:1,ml:4,bm:0,nm:"Stroke 1",mn:"ADBE Vector Graphic - Stroke",hd:false},{ty:"tr",p:{a:0,k:[0,0],ix:2},a:{a:0,k:[0,0],ix:1},s:{a:0,k:[100,100],ix:3},r:{a:0,k:0,ix:6},o:{a:0,k:100,ix:7},sk:{a:0,k:0,ix:4},sa:{a:0,k:0,ix:5},nm:"Transform"}],nm:"Shape 1",np:3,cix:2,bm:0,ix:1,mn:"ADBE Vector Group",hd:false},{ty:"tm",s:{a:1,k:[{i:{x:[.667],y:[1]},o:{x:[.333],y:[0]},t:135,s:[100]},{t:145.5,s:[0]}],ix:1},e:{a:1,k:[{i:{x:[.667],y:[1]},o:{x:[.333],y:[0]},t:130,s:[100]},{t:139.6005859375,s:[0]}],ix:2},o:{a:0,k:0,ix:3},m:1,ix:2,nm:"Trim Paths 1",mn:"ADBE Vector Filter - Trim",hd:false}],ip:130,op:204,st:-2,ct:1,bm:0},{ddd:0,ind:4,ty:4,nm:"Shape Layer 5",sr:1,ks:{o:{a:0,k:100,ix:11},r:{a:0,k:180,ix:10},p:{a:0,k:[350,350,0],ix:2,l:2},a:{a:0,k:[-304,91,0],ix:1,l:2},s:{a:0,k:[100,100,100],ix:6,l:2}},ao:0,shapes:[{ty:"gr",it:[{ind:0,ty:"sh",ix:1,ks:{a:0,k:{i:[[0,0],[0,0]],o:[[0,0],[0,0]],v:[[-304,-241],[-304,-161]],c:false},ix:2},nm:"Path 1",mn:"ADBE Vector Shape - Group",hd:false},{ty:"st",c:{a:0,k:[1,1,1,1],ix:3},o:{a:0,k:100,ix:4},w:{a:0,k:9,ix:5},lc:2,lj:1,ml:4,bm:0,nm:"Stroke 1",mn:"ADBE Vector Graphic - Stroke",hd:false},{ty:"tr",p:{a:0,k:[0,0],ix:2},a:{a:0,k:[0,0],ix:1},s:{a:0,k:[100,100],ix:3},r:{a:0,k:0,ix:6},o:{a:0,k:100,ix:7},sk:{a:0,k:0,ix:4},sa:{a:0,k:0,ix:5},nm:"Transform"}],nm:"Shape 1",np:3,cix:2,bm:0,ix:1,mn:"ADBE Vector Group",hd:false},{ty:"tm",s:{a:1,k:[{i:{x:[.667],y:[1]},o:{x:[.333],y:[0]},t:135,s:[100]},{t:145.5,s:[0]}],ix:1},e:{a:1,k:[{i:{x:[.667],y:[1]},o:{x:[.333],y:[0]},t:130,s:[100]},{t:139.6005859375,s:[0]}],ix:2},o:{a:0,k:0,ix:3},m:1,ix:2,nm:"Trim Paths 1",mn:"ADBE Vector Filter - Trim",hd:false}],ip:130,op:204,st:-2,ct:1,bm:0},{ddd:0,ind:5,ty:4,nm:"Shape Layer 4",sr:1,ks:{o:{a:0,k:100,ix:11},r:{a:0,k:135,ix:10},p:{a:0,k:[350,350,0],ix:2,l:2},a:{a:0,k:[-304,91,0],ix:1,l:2},s:{a:0,k:[100,100,100],ix:6,l:2}},ao:0,shapes:[{ty:"gr",it:[{ind:0,ty:"sh",ix:1,ks:{a:0,k:{i:[[0,0],[0,0]],o:[[0,0],[0,0]],v:[[-304,-241],[-304,-161]],c:false},ix:2},nm:"Path 1",mn:"ADBE Vector Shape - Group",hd:false},{ty:"st",c:{a:0,k:[1,1,1,1],ix:3},o:{a:0,k:100,ix:4},w:{a:0,k:9,ix:5},lc:2,lj:1,ml:4,bm:0,nm:"Stroke 1",mn:"ADBE Vector Graphic - Stroke",hd:false},{ty:"tr",p:{a:0,k:[0,0],ix:2},a:{a:0,k:[0,0],ix:1},s:{a:0,k:[100,100],ix:3},r:{a:0,k:0,ix:6},o:{a:0,k:100,ix:7},sk:{a:0,k:0,ix:4},sa:{a:0,k:0,ix:5},nm:"Transform"}],nm:"Shape 1",np:3,cix:2,bm:0,ix:1,mn:"ADBE Vector Group",hd:false},{ty:"tm",s:{a:1,k:[{i:{x:[.667],y:[1]},o:{x:[.333],y:[0]},t:135,s:[100]},{t:145.5,s:[0]}],ix:1},e:{a:1,k:[{i:{x:[.667],y:[1]},o:{x:[.333],y:[0]},t:130,s:[100]},{t:139.6005859375,s:[0]}],ix:2},o:{a:0,k:0,ix:3},m:1,ix:2,nm:"Trim Paths 1",mn:"ADBE Vector Filter - Trim",hd:false}],ip:130,op:204,st:-2,ct:1,bm:0},{ddd:0,ind:6,ty:4,nm:"Shape Layer 3",sr:1,ks:{o:{a:0,k:100,ix:11},r:{a:0,k:90,ix:10},p:{a:0,k:[350,350,0],ix:2,l:2},a:{a:0,k:[-304,91,0],ix:1,l:2},s:{a:0,k:[100,100,100],ix:6,l:2}},ao:0,shapes:[{ty:"gr",it:[{ind:0,ty:"sh",ix:1,ks:{a:0,k:{i:[[0,0],[0,0]],o:[[0,0],[0,0]],v:[[-304,-241],[-304,-161]],c:false},ix:2},nm:"Path 1",mn:"ADBE Vector Shape - Group",hd:false},{ty:"st",c:{a:0,k:[1,1,1,1],ix:3},o:{a:0,k:100,ix:4},w:{a:0,k:9,ix:5},lc:2,lj:1,ml:4,bm:0,nm:"Stroke 1",mn:"ADBE Vector Graphic - Stroke",hd:false},{ty:"tr",p:{a:0,k:[0,0],ix:2},a:{a:0,k:[0,0],ix:1},s:{a:0,k:[100,100],ix:3},r:{a:0,k:0,ix:6},o:{a:0,k:100,ix:7},sk:{a:0,k:0,ix:4},sa:{a:0,k:0,ix:5},nm:"Transform"}],nm:"Shape 1",np:3,cix:2,bm:0,ix:1,mn:"ADBE Vector Group",hd:false},{ty:"tm",s:{a:1,k:[{i:{x:[.667],y:[1]},o:{x:[.333],y:[0]},t:135,s:[100]},{t:145.5,s:[0]}],ix:1},e:{a:1,k:[{i:{x:[.667],y:[1]},o:{x:[.333],y:[0]},t:130,s:[100]},{t:139.6005859375,s:[0]}],ix:2},o:{a:0,k:0,ix:3},m:1,ix:2,nm:"Trim Paths 1",mn:"ADBE Vector Filter - Trim",hd:false}],ip:130,op:204,st:-2,ct:1,bm:0},{ddd:0,ind:7,ty:4,nm:"Shape Layer 2",sr:1,ks:{o:{a:0,k:100,ix:11},r:{a:0,k:45,ix:10},p:{a:0,k:[350,350,0],ix:2,l:2},a:{a:0,k:[-304,91,0],ix:1,l:2},s:{a:0,k:[100,100,100],ix:6,l:2}},ao:0,shapes:[{ty:"gr",it:[{ind:0,ty:"sh",ix:1,ks:{a:0,k:{i:[[0,0],[0,0]],o:[[0,0],[0,0]],v:[[-304,-241],[-304,-161]],c:false},ix:2},nm:"Path 1",mn:"ADBE Vector Shape - Group",hd:false},{ty:"st",c:{a:0,k:[1,1,1,1],ix:3},o:{a:0,k:100,ix:4},w:{a:0,k:9,ix:5},lc:2,lj:1,ml:4,bm:0,nm:"Stroke 1",mn:"ADBE Vector Graphic - Stroke",hd:false},{ty:"tr",p:{a:0,k:[0,0],ix:2},a:{a:0,k:[0,0],ix:1},s:{a:0,k:[100,100],ix:3},r:{a:0,k:0,ix:6},o:{a:0,k:100,ix:7},sk:{a:0,k:0,ix:4},sa:{a:0,k:0,ix:5},nm:"Transform"}],nm:"Shape 1",np:3,cix:2,bm:0,ix:1,mn:"ADBE Vector Group",hd:false},{ty:"tm",s:{a:1,k:[{i:{x:[.667],y:[1]},o:{x:[.333],y:[0]},t:135,s:[100]},{t:145.5,s:[0]}],ix:1},e:{a:1,k:[{i:{x:[.667],y:[1]},o:{x:[.333],y:[0]},t:130,s:[100]},{t:139.6005859375,s:[0]}],ix:2},o:{a:0,k:0,ix:3},m:1,ix:2,nm:"Trim Paths 1",mn:"ADBE Vector Filter - Trim",hd:false}],ip:130,op:204,st:-2,ct:1,bm:0},{ddd:0,ind:8,ty:4,nm:"Shape Layer 1",sr:1,ks:{o:{a:0,k:100,ix:11},r:{a:0,k:0,ix:10},p:{a:0,k:[350,350,0],ix:2,l:2},a:{a:0,k:[-304,91,0],ix:1,l:2},s:{a:0,k:[100,100,100],ix:6,l:2}},ao:0,shapes:[{ty:"gr",it:[{ind:0,ty:"sh",ix:1,ks:{a:0,k:{i:[[0,0],[0,0]],o:[[0,0],[0,0]],v:[[-304,-241],[-304,-161]],c:false},ix:2},nm:"Path 1",mn:"ADBE Vector Shape - Group",hd:false},{ty:"st",c:{a:0,k:[1,1,1,1],ix:3},o:{a:0,k:100,ix:4},w:{a:0,k:9,ix:5},lc:2,lj:1,ml:4,bm:0,nm:"Stroke 1",mn:"ADBE Vector Graphic - Stroke",hd:false},{ty:"tr",p:{a:0,k:[0,0],ix:2},a:{a:0,k:[0,0],ix:1},s:{a:0,k:[100,100],ix:3},r:{a:0,k:0,ix:6},o:{a:0,k:100,ix:7},sk:{a:0,k:0,ix:4},sa:{a:0,k:0,ix:5},nm:"Transform"}],nm:"Shape 1",np:3,cix:2,bm:0,ix:1,mn:"ADBE Vector Group",hd:false},{ty:"tm",s:{a:1,k:[{i:{x:[.667],y:[1]},o:{x:[.333],y:[0]},t:135,s:[100]},{t:145.5,s:[0]}],ix:1},e:{a:1,k:[{i:{x:[.667],y:[1]},o:{x:[.333],y:[0]},t:130,s:[100]},{t:139.6005859375,s:[0]}],ix:2},o:{a:0,k:0,ix:3},m:1,ix:2,nm:"Trim Paths 1",mn:"ADBE Vector Filter - Trim",hd:false}],ip:130,op:204,st:-2,ct:1,bm:0},{ddd:0,ind:9,ty:4,nm:"Check v",sr:1,ks:{o:{a:0,k:100,ix:11},r:{a:0,k:-1.9,ix:10},p:{a:0,k:[352,360,0],ix:2,l:2},a:{a:0,k:[-120.265,116.765,0],ix:1,l:2},s:{a:0,k:[278,278,100],ix:6,l:2}},ao:0,shapes:[{ty:"gr",it:[{ind:0,ty:"sh",ix:1,ks:{a:0,k:{i:[[0,0],[0,0],[0,0]],o:[[0,0],[0,0],[0,0]],v:[[-161,123],[-137,148],[-79.531,85.531]],c:false},ix:2},nm:"Path 1",mn:"ADBE Vector Shape - Group",hd:false},{ty:"st",c:{a:0,k:[1,1,1,1],ix:3},o:{a:0,k:100,ix:4},w:{a:0,k:5.5,ix:5},lc:2,lj:2,bm:0,nm:"Stroke 1",mn:"ADBE Vector Graphic - Stroke",hd:false},{ty:"tr",p:{a:0,k:[0,0],ix:2},a:{a:0,k:[0,0],ix:1},s:{a:0,k:[100,100],ix:3},r:{a:0,k:0,ix:6},o:{a:0,k:100,ix:7},sk:{a:0,k:0,ix:4},sa:{a:0,k:0,ix:5},nm:"Transform"}],nm:"Shape 1",np:3,cix:2,bm:0,ix:1,mn:"ADBE Vector Group",hd:false},{ty:"tm",s:{a:1,k:[{i:{x:[0],y:[1]},o:{x:[.333],y:[0]},t:135,s:[0]},{t:148,s:[100]}],ix:1},e:{a:0,k:0,ix:2},o:{a:0,k:0,ix:3},m:1,ix:2,nm:"Trim Paths 1",mn:"ADBE Vector Filter - Trim",hd:false}],ip:135,op:201,st:-35,ct:1,bm:0},{ddd:0,ind:11,ty:4,nm:"Circle Stroke",sr:1,ks:{o:{a:1,k:[{i:{x:[.833],y:[.833]},o:{x:[.167],y:[.167]},t:0,s:[0]},{t:7,s:[100]}],ix:11},r:{a:0,k:0,ix:10},p:{a:0,k:[350,350,0],ix:2,l:2},a:{a:0,k:[4,-6,0],ix:1,l:2},s:{a:0,k:[132,132,100],ix:6,l:2}},ao:0,shapes:[{ty:"gr",it:[{d:1,ty:"el",s:{a:0,k:[306,306],ix:2},p:{a:0,k:[0,0],ix:3},nm:"Ellipse Path 1",mn:"ADBE Vector Shape - Ellipse",hd:false},{ty:"st",c:{a:1,k:[{i:{x:[.833],y:[.833]},o:{x:[.167],y:[.167]},t:0,s:[1,1,1,1]},{i:{x:[.833],y:[.833]},o:{x:[.167],y:[.167]},t:30,s:[1,1,1,1]},{i:{x:[.833],y:[.833]},o:{x:[.167],y:[.167]},t:61,s:[1,1,1,1]},{i:{x:[.833],y:[.833]},o:{x:[.167],y:[.167]},t:87,s:[1,1,1,1]},{t:136,s:[1,1,1,1]}],ix:3},o:{a:0,k:100,ix:4},w:{a:0,k:8,ix:5},lc:2,lj:1,ml:4,bm:0,nm:"Stroke 1",mn:"ADBE Vector Graphic - Stroke",hd:false},{ty:"tr",p:{a:0,k:[4,-6],ix:2},a:{a:0,k:[0,0],ix:1},s:{a:0,k:[100,100],ix:3},r:{a:0,k:0,ix:6},o:{a:0,k:100,ix:7},sk:{a:0,k:0,ix:4},sa:{a:0,k:0,ix:5},nm:"Transform"}],nm:"Ellipse 1",np:3,cix:2,bm:0,ix:1,mn:"ADBE Vector Group",hd:false},{ty:"tm",s:{a:1,k:[{i:{x:[.338],y:[1]},o:{x:[.333],y:[0]},t:87,s:[50]},{t:122,s:[100]}],ix:1},e:{a:1,k:[{i:{x:[.338],y:[1]},o:{x:[.333],y:[0]},t:87,s:[45]},{t:122,s:[0]}],ix:2},o:{a:1,k:[{i:{x:[.474],y:[1]},o:{x:[.43],y:[0]},t:0,s:[-170.4]},{t:111,s:[-1250.4]}],ix:3},m:1,ix:2,nm:"Trim Paths 1",mn:"ADBE Vector Filter - Trim",hd:false}],ip:0,op:201,st:0,ct:1,bm:0},{ddd:0,ind:13,ty:1,nm:"Dark Gray Solid 1",sr:1,ks:{o:{a:0,k:100,ix:11},r:{a:0,k:0,ix:10},p:{a:0,k:[350,350,0],ix:2,l:2},a:{a:0,k:[350,350,0],ix:1,l:2},s:{a:0,k:[100,100,100],ix:6,l:2}},ao:0,sw:700,sh:700,sc:"#2d2d2d",ip:0,op:201,st:0,bm:0}],markers:[],props:{}};var cg=5e3,X3=Q(bg__default.default)`
5388
5388
  @keyframes blurFade {
5389
5389
  0% {
5390
5390
  background-color: ${({theme:t})=>sc__default.default(t.stigg.palette.backgroundPaper).alpha(0).toString()};
@@ -5430,7 +5430,7 @@ ${e.o5f}`,e.zBW=r.default`
5430
5430
 
5431
5431
  align-self: center;
5432
5432
  animation: fadeIn 5s ease-in forwards;
5433
- `;function QE({checkoutLocalization:t}){let e=Uv.useRef();return Uv.useEffect(()=>{e.current&&e.current.scrollIntoView({behavior:"smooth",block:"center",inline:"center"});},[]),jsxRuntime.jsxs(X3,{className:"stigg-checkout-success-container",ref:e,children:[jsxRuntime.jsx(K3__default.default,{options:{animationData:qE,loop:false,autoplay:true},width:350,height:"auto",style:{display:"flex",justifyContent:"center"}}),jsxRuntime.jsx(Z3,{variant:"h1",color:"primary.main",children:t.summary.checkoutSuccessText})]})}var nL=t=>new Promise(e=>setTimeout(e,t));function KE({isMocked:t=false,onCheckout:e,onCheckoutCompleted:n,onSuccess:r,disableSuccessAnimation:i}){let{stigg:o}=ve(),{useNewPaymentMethod:s}=Pi(),c=lg(),{checkoutState:p,widgetState:h,setWidgetReadOnly:v}=ze(),{setupSecret:P,customer:x}=p||{},T=reactStripeJs.useStripe(),I=reactStripeJs.useElements();return {handleSubmit:A=>ce(null,null,function*(){if(A.preventDefault(),!c)return {success:false,errorMessage:"Unexpected error, please contact support."};let O=true,N,V=false,G;if(v(true),!t&&s){let U=yield WE({elements:I,stripe:T,setupIntentClientSecret:P});U.success?G=U.paymentMethodId:(N=U.errorMessage,O=false);}let X=St(W({},c),{paymentMethodId:G}),nt=U=>ce(null,null,function*(){V=true;try{let j=yield o.applySubscription(U),ut=yield Hv({applySubscriptionResults:j,stripe:T});return {success:!ut.errorMessage,errorMessage:ut.errorMessage,results:j}}catch(j){return console.error(j),N=j==null?void 0:j.message,{success:false,errorMessage:N}}}),st;if(O)if(e){let U=yield e({customerId:x.id,checkoutParams:X,checkoutAction:nt});if(U.errorMessage&&(N=U.errorMessage),!V&&U.results&&U.success){let j=yield Hv({applySubscriptionResults:U.results,stripe:T});j.errorMessage&&(N=j.errorMessage,O=false);}O=O&&U.success&&!N,st=U.results;}else {let U=yield nt(X);!U.success&&U.errorMessage&&(N=U.errorMessage),O=U.success&&!N,st=U.results;}return v(false),O&&r&&(r(),i||(yield nL(cg))),yield n({success:O,error:N}),{results:st,success:!N,errorMessage:N}}),isLoading:!!(h!=null&&h.readOnly)}}function XE(){return !!window.Zuora}function ZE(){let t=document.createElement("script");t.type="text/javascript",t.src="https://js.zuora.com/payment/v3/zuora.js",t.async=true,t.onerror=()=>{throw new Error("Failed to load Zuora library")},document.head.appendChild(t);}function JE(t,e,n,r){return {locale:r||"en",region:(r==null?void 0:r.toUpperCase())||"US",currency:n,amount:"1",createPaymentSession:t,onComplete:e}}function Ku(){let{stigg:t}=ve(),{setErrorMessage:e}=Pi(),{billingCountryCode:n}=lo(),[r,i]=Uv.useState(false),{checkoutState:o}=ze(),{billingIntegration:s}=o||{},c=Uv.useCallback(()=>ce(null,null,function*(){if(!(o!=null&&o.customer.id)||!(o!=null&&o.plan.id))throw new Error("Customer and plan are required");let{token:v}=yield t.createPaymentSession({planId:o.plan.id,billingCountryCode:n});return v}),[o,t,n]),p=Uv.useCallback(()=>{try{XE()||ZE(),i(!0);}catch(v){e("Failed to initialize Zuora");}},[i,e]);return Uv.useEffect(()=>{if(s){let{billingIdentifier:v}=s;v===Dp.Zuora&&p();}},[s,p]),{isZuoraIntegration:(s==null?void 0:s.billingIdentifier)===Dp.Zuora,isInitialized:r,createPaymentSession:c}}var aL=t=>new Promise(e=>setTimeout(e,t));function ug({onCheckout:t,onCheckoutCompleted:e,onSuccess:n,disableSuccessAnimation:r}){let{stigg:i}=ve(),o=lg(),{checkoutState:s,setWidgetReadOnly:c,setCheckoutSuccess:p}=ze(),{setErrorMessage:h}=Pi();return {handleZuoraSubmit:Uv.useCallback(P=>ce(null,null,function*(){c(true);let x=true,T,I=o;if(!I)x=false,T="Unexpected error, please contact support.";else {let F=St(W({},I),{paymentMethodId:P}),A=O=>ce(null,null,function*(){try{return {success:!0,results:yield i.applySubscription(O)}}catch(N){return console.error(N),{success:false,errorMessage:(N==null?void 0:N.message)||"Failed to apply subscription"}}});try{if(t){let O=yield t({customerId:s.customer.id,checkoutParams:F,checkoutAction:A});O.errorMessage&&(T=O.errorMessage),x=x&&O.success&&!T;}else {let O=yield A(F);!O.success&&O.errorMessage&&(T=O.errorMessage),x=O.success&&!T;}}catch(O){x=false,T=O.message||"Failed to process checkout";}}return x?(p(true),n&&(n(),r||(yield aL(cg)))):h(T),c(false),yield e({success:x,error:T}),{success:x,errorMessage:T}}),[i,o,s,t,e,n,r,c,p,h])}}var No=({isLoading:t,width:e=50,height:n=16,children:r})=>t?jsxRuntime.jsx(Un,{width:e,height:n}):jsxRuntime.jsx(jsxRuntime.Fragment,{children:r});var cL=({subscriptionPreview:t,isFetchingSubscriptionPreview:e,checkoutLocalization:n})=>{var s,c,p,h;let{immediateInvoice:r}=t||{};if(!((c=(s=r==null?void 0:r.proration)==null?void 0:s.netAmount)!=null&&c.amount)||((h=(p=r==null?void 0:r.proration)==null?void 0:p.netAmount)==null?void 0:h.amount)>=0)return null;let i=r.proration.netAmount.amount*-1,o=wn({amount:i,currency:r.proration.netAmount.currency,minimumFractionDigits:2});return jsxRuntime.jsx(rt,{variant:"body1",style:{marginTop:14},className:"stigg-checkout-summary-captions-remaining-credits",children:jsxRuntime.jsx(No,{isLoading:e,width:"100%",children:n.summary.creditsForUnusedTimeText({credits:o})})})},uL=({subscriptionPreview:t,activeSubscription:e,isFetchingSubscriptionPreview:n,checkoutLocalization:r})=>{if(!(t!=null&&t.hasScheduledUpdates)||!(e!=null&&e.currentBillingPeriodEnd))return null;let{currentBillingPeriodEnd:i}=e,o=typeof r.summary.changesWillApplyAtEndOfBillingPeriod=="function"?r.summary.changesWillApplyAtEndOfBillingPeriod({billingPeriodEnd:i}):r.summary.changesWillApplyAtEndOfBillingPeriod;return jsxRuntime.jsx(rt,{variant:"body1",style:{marginTop:14},className:"stigg-checkout-summary-captions-scheduled-updates",children:jsxRuntime.jsx(No,{isLoading:n,width:"100%",children:o})})},dL=({subscriptionPreview:t,activeSubscription:e,plan:n,isFetchingSubscriptionPreview:r,billingPeriod:i})=>{let{recurringInvoice:o}=t||{};if(!t||!(o!=null&&o.total.amount))return null;let s=t.hasScheduledUpdates?e==null?void 0:e.currentBillingPeriodEnd:t==null?void 0:t.billingPeriodRange.end,c=wn(St(W({},o.total),{minimumFractionDigits:2})),p=n==null?void 0:n.pricePoints.some(I=>I.pricingModel===nn.UsageBased),h=n==null?void 0:n.pricePoints.some(I=>I.pricingModel!==nn.UsageBased),v="We will bill you ",P=`${c} `;p&&(h?P+="+":P="for",P+=" applicable usage-based charges for this subscription ");let x,T;switch(i){case be.Monthly:T="month",x=`the ${G1__default.default(s).format("Do")}`;break;case be.Annually:T="year",x=G1__default.default(s).format("MMMM Do");break;}return v+=`${P}for this subscription every ${T} on ${x}, unless you cancel.`,jsxRuntime.jsx(rt,{variant:"body1",style:{marginTop:14},className:"stigg-checkout-summary-captions-next-billing",children:jsxRuntime.jsx(No,{isLoading:r,width:"100%",children:v})})};function r_(t){return jsxRuntime.jsxs(material.Box,{className:"stigg-checkout-summary-captions",children:[jsxRuntime.jsx(cL,W({},t)),jsxRuntime.jsx(uL,W({},t)),jsxRuntime.jsx(dL,W({},t))]})}function qv({quantity:t,totalAmount:e,pricingModel:n,billingPeriod:r,currency:i,blockSize:o,priceAmount:s,availableBillingPeriods:c}){let p=c==null?void 0:c.has(be.Monthly),h=n===nn.PerUnit,v=o||1,P=r===be.Annually&&p,x=t&&(h||t>1)?`${gr(t)} ${v>1?"for":"x"} `:"",T=P?" x 12 months":"",I=(s||e/t)/(P?12:1),F=wn({amount:I,currency:i,minimumFractionDigits:2}),A=wn({amount:e,currency:i,minimumFractionDigits:2});return `${x}${F}${T} ${T||x?` = ${A}`:""}`}function i_(t){let{totalAmount:e,quantity:n,tiersMode:r,tiers:i,currency:o}=t;if(tS(i)||r===ic.Graduated&&!eS(i,n)){let s=wn({amount:e,currency:o,minimumFractionDigits:2});return `${gr(n)} for ${s}`}return qv(t)}function hL(t,e){let{unitPrice:n,upTo:r}=t[e];if(!n)return "";if(e===0)return `First ${r}`;let o=(t[e-1].upTo||0)+1;return lm__default.default(r)?`${gr(o)} and above`:`Next ${gr(o)} to ${gr(r)}`}function o_({price:t,unitQuantity:e}){let n=t.tiers||[],{checkoutState:r}=ze(),i=r==null?void 0:r.plan,{breakdown:o}=Rb(n,e);return o.length===1?null:jsxRuntime.jsx(jsxRuntime.Fragment,{children:o.map(({unitQuantity:s,amount:c},p)=>jsxRuntime.jsx(ma,{children:jsxRuntime.jsxs(Lo,{style:{alignItems:"flex-start"},children:[jsxRuntime.jsx(rt,{variant:"body1",color:"tertiary",style:{whiteSpace:"nowrap"},children:hL(n,p)}),jsxRuntime.jsx(rt,{variant:"body1",color:"tertiary",style:{whiteSpace:"nowrap"},children:qv({quantity:s,totalAmount:c,currency:t.currency,pricingModel:t.pricingModel,billingPeriod:t.billingPeriod,tiers:t.tiers,tiersMode:t.tiersMode,blockSize:t.blockSize,priceAmount:t.amount,availableBillingPeriods:new Set(i==null?void 0:i.pricePoints.map(h=>h.billingPeriod))})})]})},p))})}var a_=Q(reactFeather.ChevronRight)`
5433
+ `;function QE({checkoutLocalization:t}){let e=Uv.useRef();return Uv.useEffect(()=>{e.current&&e.current.scrollIntoView({behavior:"smooth",block:"center",inline:"center"});},[]),jsxRuntime.jsxs(X3,{className:"stigg-checkout-success-container",ref:e,children:[jsxRuntime.jsx(K3__default.default,{options:{animationData:qE,loop:false,autoplay:true},width:350,height:"auto",style:{display:"flex",justifyContent:"center"}}),jsxRuntime.jsx(Z3,{variant:"h1",color:"primary.main",children:t.summary.checkoutSuccessText})]})}var nL=t=>new Promise(e=>setTimeout(e,t));function KE({isMocked:t=false,onCheckout:e,onCheckoutCompleted:n,onSuccess:r,disableSuccessAnimation:i}){let{stigg:o}=ve(),{useNewPaymentMethod:s}=Pi(),c=lg(),{checkoutState:p,widgetState:h,setWidgetReadOnly:v}=ze(),{setupSecret:P,customer:x}=p||{},T=reactStripeJs.useStripe(),I=reactStripeJs.useElements();return {handleSubmit:A=>ce(null,null,function*(){if(A.preventDefault(),!c)return {success:false,errorMessage:"Unexpected error, please contact support."};let O=true,N,V=false,G;if(v(true),!t&&s){let U=yield WE({elements:I,stripe:T,setupIntentClientSecret:P});U.success?G=U.paymentMethodId:(N=U.errorMessage,O=false);}let X=St(W({},c),{paymentMethodId:G}),nt=U=>ce(null,null,function*(){V=true;try{let j=yield o.applySubscription(U),ut=yield Hv({applySubscriptionResults:j,stripe:T});return {success:!ut.errorMessage,errorMessage:ut.errorMessage,results:j}}catch(j){return console.error(j),N=j==null?void 0:j.message,{success:false,errorMessage:N}}}),st;if(O)if(e){let U=yield e({customerId:x.id,checkoutParams:X,checkoutAction:nt});if(U.errorMessage&&(N=U.errorMessage),!V&&U.results&&U.success){let j=yield Hv({applySubscriptionResults:U.results,stripe:T});j.errorMessage&&(N=j.errorMessage,O=false);}O=O&&U.success&&!N,st=U.results;}else {let U=yield nt(X);!U.success&&U.errorMessage&&(N=U.errorMessage),O=U.success&&!N,st=U.results;}return v(false),O&&r&&(r(),i||(yield nL(cg))),yield n({success:O,error:N}),{results:st,success:!N,errorMessage:N}}),isLoading:!!(h!=null&&h.readOnly)}}function XE(){return !!window.Zuora}function ZE(){let t=document.createElement("script");t.type="text/javascript",t.src="https://js.zuora.com/payment/v3/zuora.js",t.async=true,t.onerror=()=>{throw new Error("Failed to load Zuora library")},document.head.appendChild(t);}function JE(t,e,n,r){return {locale:r||"en",region:(r==null?void 0:r.toUpperCase())||"US",currency:n,amount:"1",createPaymentSession:t,onComplete:e}}function Ku(){let{stigg:t}=ve(),{setErrorMessage:e}=Pi(),{billingCountryCode:n}=lo(),[r,i]=Uv.useState(false),{checkoutState:o}=ze(),{billingIntegration:s}=o||{},c=Uv.useCallback(()=>ce(null,null,function*(){if(!(o!=null&&o.customer.id)||!(o!=null&&o.plan.id))throw new Error("Customer and plan are required");let{token:v}=yield t.createPaymentSession({planId:o.plan.id,billingCountryCode:n});return v}),[o,t,n]),p=Uv.useCallback(()=>{try{XE()||ZE(),i(!0);}catch(v){e("Failed to initialize Zuora");}},[i,e]);return Uv.useEffect(()=>{if(s){let{billingIdentifier:v}=s;v===Dp.Zuora&&p();}},[s,p]),{isZuoraIntegration:(s==null?void 0:s.billingIdentifier)===Dp.Zuora,isInitialized:r,createPaymentSession:c}}var aL=t=>new Promise(e=>setTimeout(e,t));function ug({onCheckout:t,onCheckoutCompleted:e,onSuccess:n,disableSuccessAnimation:r}){let{stigg:i}=ve(),o=lg(),{checkoutState:s,setWidgetReadOnly:c,setCheckoutSuccess:p}=ze(),{setErrorMessage:h}=Pi();return {handleZuoraSubmit:Uv.useCallback(P=>ce(null,null,function*(){c(true);let x=true,T,I=o;if(!I)x=false,T="Unexpected error, please contact support.";else {let R=St(W({},I),{paymentMethodId:P}),A=O=>ce(null,null,function*(){try{return {success:!0,results:yield i.applySubscription(O)}}catch(N){return console.error(N),{success:false,errorMessage:(N==null?void 0:N.message)||"Failed to apply subscription"}}});try{if(t){let O=yield t({customerId:s.customer.id,checkoutParams:R,checkoutAction:A});O.errorMessage&&(T=O.errorMessage),x=x&&O.success&&!T;}else {let O=yield A(R);!O.success&&O.errorMessage&&(T=O.errorMessage),x=O.success&&!T;}}catch(O){x=false,T=O.message||"Failed to process checkout";}}return x?(p(true),n&&(n(),r||(yield aL(cg)))):h(T),c(false),yield e({success:x,error:T}),{success:x,errorMessage:T}}),[i,o,s,t,e,n,r,c,p,h])}}var No=({isLoading:t,width:e=50,height:n=16,children:r})=>t?jsxRuntime.jsx(Un,{width:e,height:n}):jsxRuntime.jsx(jsxRuntime.Fragment,{children:r});var cL=({subscriptionPreview:t,isFetchingSubscriptionPreview:e,checkoutLocalization:n})=>{var s,c,p,h;let{immediateInvoice:r}=t||{};if(!((c=(s=r==null?void 0:r.proration)==null?void 0:s.netAmount)!=null&&c.amount)||((h=(p=r==null?void 0:r.proration)==null?void 0:p.netAmount)==null?void 0:h.amount)>=0)return null;let i=r.proration.netAmount.amount*-1,o=wn({amount:i,currency:r.proration.netAmount.currency,minimumFractionDigits:2});return jsxRuntime.jsx(rt,{variant:"body1",style:{marginTop:14},className:"stigg-checkout-summary-captions-remaining-credits",children:jsxRuntime.jsx(No,{isLoading:e,width:"100%",children:n.summary.creditsForUnusedTimeText({credits:o})})})},uL=({subscriptionPreview:t,activeSubscription:e,isFetchingSubscriptionPreview:n,checkoutLocalization:r})=>{if(!(t!=null&&t.hasScheduledUpdates)||!(e!=null&&e.currentBillingPeriodEnd))return null;let{currentBillingPeriodEnd:i}=e,o=typeof r.summary.changesWillApplyAtEndOfBillingPeriod=="function"?r.summary.changesWillApplyAtEndOfBillingPeriod({billingPeriodEnd:i}):r.summary.changesWillApplyAtEndOfBillingPeriod;return jsxRuntime.jsx(rt,{variant:"body1",style:{marginTop:14},className:"stigg-checkout-summary-captions-scheduled-updates",children:jsxRuntime.jsx(No,{isLoading:n,width:"100%",children:o})})},dL=({subscriptionPreview:t,activeSubscription:e,plan:n,isFetchingSubscriptionPreview:r,billingPeriod:i})=>{let{recurringInvoice:o}=t||{};if(!t||!(o!=null&&o.total.amount))return null;let s=t.hasScheduledUpdates?e==null?void 0:e.currentBillingPeriodEnd:t==null?void 0:t.billingPeriodRange.end,c=wn(St(W({},o.total),{minimumFractionDigits:2})),p=n==null?void 0:n.pricePoints.some(I=>I.pricingModel===nn.UsageBased),h=n==null?void 0:n.pricePoints.some(I=>I.pricingModel!==nn.UsageBased),v="We will bill you ",P=`${c} `;p&&(h?P+="+":P="for",P+=" applicable usage-based charges for this subscription ");let x,T;switch(i){case be.Monthly:T="month",x=`the ${G1__default.default(s).format("Do")}`;break;case be.Annually:T="year",x=G1__default.default(s).format("MMMM Do");break;}return v+=`${P}for this subscription every ${T} on ${x}, unless you cancel.`,jsxRuntime.jsx(rt,{variant:"body1",style:{marginTop:14},className:"stigg-checkout-summary-captions-next-billing",children:jsxRuntime.jsx(No,{isLoading:r,width:"100%",children:v})})};function r_(t){return jsxRuntime.jsxs(material.Box,{className:"stigg-checkout-summary-captions",children:[jsxRuntime.jsx(cL,W({},t)),jsxRuntime.jsx(uL,W({},t)),jsxRuntime.jsx(dL,W({},t))]})}function qv({quantity:t,totalAmount:e,pricingModel:n,billingPeriod:r,currency:i,blockSize:o,priceAmount:s,availableBillingPeriods:c}){let p=c==null?void 0:c.has(be.Monthly),h=n===nn.PerUnit,v=o||1,P=r===be.Annually&&p,x=t&&(h||t>1)?`${gr(t)} ${v>1?"for":"x"} `:"",T=P?" x 12 months":"",I=(s||e/t)/(P?12:1),R=wn({amount:I,currency:i,minimumFractionDigits:2}),A=wn({amount:e,currency:i,minimumFractionDigits:2});return `${x}${R}${T} ${T||x?` = ${A}`:""}`}function i_(t){let{totalAmount:e,quantity:n,tiersMode:r,tiers:i,currency:o}=t;if(tS(i)||r===ic.Graduated&&!eS(i,n)){let s=wn({amount:e,currency:o,minimumFractionDigits:2});return `${gr(n)} for ${s}`}return qv(t)}function hL(t,e){let{unitPrice:n,upTo:r}=t[e];if(!n)return "";if(e===0)return `First ${r}`;let o=(t[e-1].upTo||0)+1;return lm__default.default(r)?`${gr(o)} and above`:`Next ${gr(o)} to ${gr(r)}`}function o_({price:t,unitQuantity:e}){let n=t.tiers||[],{checkoutState:r}=ze(),i=r==null?void 0:r.plan,{breakdown:o}=Rb(n,e);return o.length===1?null:jsxRuntime.jsx(jsxRuntime.Fragment,{children:o.map(({unitQuantity:s,amount:c},p)=>jsxRuntime.jsx(ma,{children:jsxRuntime.jsxs(Lo,{style:{alignItems:"flex-start"},children:[jsxRuntime.jsx(rt,{variant:"body1",color:"tertiary",style:{whiteSpace:"nowrap"},children:hL(n,p)}),jsxRuntime.jsx(rt,{variant:"body1",color:"tertiary",style:{whiteSpace:"nowrap"},children:qv({quantity:s,totalAmount:c,currency:t.currency,pricingModel:t.pricingModel,billingPeriod:t.billingPeriod,tiers:t.tiers,tiersMode:t.tiersMode,blockSize:t.blockSize,priceAmount:t.amount,availableBillingPeriods:new Set(i==null?void 0:i.pricePoints.map(h=>h.billingPeriod))})})]})},p))})}var a_=Q(reactFeather.ChevronRight)`
5434
5434
  height: ${({$size:t=24})=>`${t}px`};
5435
5435
  width: ${({$size:t=24})=>`${t}px`};
5436
5436
  transition: all 0.2s ease-in;
@@ -5452,7 +5452,7 @@ ${e.o5f}`,e.zBW=r.default`
5452
5452
  align-items: center;
5453
5453
  justify-content: space-between;
5454
5454
  }
5455
- `,_L=({checkoutLocalization:t})=>{let e=jsxRuntime.jsx(rt,{variant:"body1",children:t.summary.payAsYouGoTooltipText});return jsxRuntime.jsx(Vu,{placement:"left",title:e,children:jsxRuntime.jsx(qn,{icon:"PayAsYouGoCharge",style:{display:"flex"}})})},fg=({checkoutLocalization:t,label:e,quantity:n,price:r})=>{let{checkoutState:i}=ze(),o=i==null?void 0:i.plan,s=Ci("lg"),[c,p]=Uv.useState(false),h=()=>p(F=>!F),v=r.pricingModel===nn.UsageBased,P=r.isTieredPrice?Uu(r,n):(r.amount||0)*Math.ceil(n/(r.blockSize||1)),x;r.tiersMode===ic.Graduated&&!!r.tiers&&!rO__default.default(r.tiers)&&!lm__default.default(r.tiers[0].upTo)&&n>r.tiers[0].upTo&&(x=jsxRuntime.jsx(o_,{price:r,unitQuantity:n}));let I=jsxRuntime.jsx(rt,{variant:"body1",color:"secondary",children:e});return x&&(I=jsxRuntime.jsx(HO__default.default,{onClick:h,underline:"none",style:{cursor:"pointer"},children:I})),jsxRuntime.jsxs(ma,{className:"stigg-checkout-summary-base-charges-container",children:[jsxRuntime.jsxs(Lo,{style:{alignItems:"flex-start"},children:[jsxRuntime.jsxs(da__default.default,{item:true,display:"flex",gap:.5,style:{whiteSpace:s?"nowrap":"break-spaces"},children:[I,x&&jsxRuntime.jsx(material.IconButton,{onClick:h,sx:{padding:0},children:jsxRuntime.jsx(a_,{$isOpen:c,$size:16})})]}),jsxRuntime.jsxs(da__default.default,{item:true,display:"flex",gap:1,alignItems:"center",children:[v&&jsxRuntime.jsx(_L,{checkoutLocalization:t}),jsxRuntime.jsxs(rt,{variant:"body1",color:"secondary",style:{whiteSpace:s?"nowrap":"break-spaces"},children:[i_({totalAmount:P,quantity:n,currency:r.currency,pricingModel:r.pricingModel,billingPeriod:r.billingPeriod,tiers:r.tiers,tiersMode:r.tiersMode,blockSize:r.blockSize,priceAmount:r.amount,availableBillingPeriods:new Set(o==null?void 0:o.pricePoints.map(F=>F.billingPeriod))}),v&&" / unit"]})]})]}),x&&jsxRuntime.jsx(xL__default.default,{in:c,children:jsxRuntime.jsx(EL,{children:x})})]})},s_=({label:t})=>jsxRuntime.jsx(ma,{children:jsxRuntime.jsxs(Lo,{style:{alignItems:"flex-end"},children:[jsxRuntime.jsx(da__default.default,{item:true,children:jsxRuntime.jsx(rt,{variant:"body1",color:"secondary",children:t})}),jsxRuntime.jsx(da__default.default,{item:true,display:"flex",gap:1,alignItems:"center",children:jsxRuntime.jsx(rt,{variant:"body1",color:"secondary",style:{wordBreak:"break-word"},children:"Free"})})]})}),l_=({subscriptionPreview:t,isFetchingSubscriptionPreview:e,checkoutLocalization:n})=>{let{immediateInvoice:r,recurringInvoice:i}=t,{discount:o,discountDetails:s}=i||{};return !o||!s?null:jsxRuntime.jsx(ma,{children:jsxRuntime.jsxs(Lo,{children:[jsxRuntime.jsx(rt,{variant:"body1",color:"secondary",children:n.summary.discountText({discountDetails:s,currency:r.total.currency})}),jsxRuntime.jsx(rt,{variant:"body1",color:"secondary",children:e?jsxRuntime.jsx(Un,{width:50,height:16}):wn({amount:o.amount,currency:o.currency,minimumFractionDigits:2})})]})})},c_=({subscriptionPreview:t,isFetchingSubscriptionPreview:e,checkoutLocalization:n})=>{let{immediateInvoice:r}=t||{},{credits:i}=r||{};return !i||!i.used||i.used.amount<=0?null:jsxRuntime.jsx(ma,{children:jsxRuntime.jsxs(Lo,{children:[jsxRuntime.jsx(rt,{variant:"body1",color:"secondary",children:n.summary.appliedCreditsTitle}),jsxRuntime.jsx(rt,{variant:"body1",color:"secondary",children:jsxRuntime.jsx(No,{isLoading:e,children:wn({amount:-1*i.used.amount,currency:i.used.currency,minimumFractionDigits:2})})})]})})},u_=({tax:t,taxDetails:e,isFetchingSubscriptionPreview:n,checkoutLocalization:r})=>!e||!t||(t==null?void 0:t.amount)<=0?null:jsxRuntime.jsx(ma,{children:jsxRuntime.jsxs(Lo,{children:[jsxRuntime.jsx(rt,{variant:"body1",color:"secondary",children:r.summary.taxTitle({taxDetails:e})}),jsxRuntime.jsx(rt,{variant:"body1",color:"secondary",children:jsxRuntime.jsx(No,{isLoading:n,children:wn({amount:t==null?void 0:t.amount,currency:t==null?void 0:t.currency,minimumFractionDigits:2})})})]})});var Yv=Q(bg__default.default)`
5455
+ `,_L=({checkoutLocalization:t})=>{let e=jsxRuntime.jsx(rt,{variant:"body1",children:t.summary.payAsYouGoTooltipText});return jsxRuntime.jsx(Vu,{placement:"left",title:e,children:jsxRuntime.jsx(qn,{icon:"PayAsYouGoCharge",style:{display:"flex"}})})},fg=({checkoutLocalization:t,label:e,quantity:n,price:r})=>{let{checkoutState:i}=ze(),o=i==null?void 0:i.plan,s=Ci("lg"),[c,p]=Uv.useState(false),h=()=>p(R=>!R),v=r.pricingModel===nn.UsageBased,P=r.isTieredPrice?Uu(r,n):(r.amount||0)*Math.ceil(n/(r.blockSize||1)),x;r.tiersMode===ic.Graduated&&!!r.tiers&&!rO__default.default(r.tiers)&&!lm__default.default(r.tiers[0].upTo)&&n>r.tiers[0].upTo&&(x=jsxRuntime.jsx(o_,{price:r,unitQuantity:n}));let I=jsxRuntime.jsx(rt,{variant:"body1",color:"secondary",children:e});return x&&(I=jsxRuntime.jsx(HO__default.default,{onClick:h,underline:"none",style:{cursor:"pointer"},children:I})),jsxRuntime.jsxs(ma,{className:"stigg-checkout-summary-base-charges-container",children:[jsxRuntime.jsxs(Lo,{style:{alignItems:"flex-start"},children:[jsxRuntime.jsxs(da__default.default,{item:true,display:"flex",gap:.5,style:{whiteSpace:s?"nowrap":"break-spaces"},children:[I,x&&jsxRuntime.jsx(material.IconButton,{onClick:h,sx:{padding:0},children:jsxRuntime.jsx(a_,{$isOpen:c,$size:16})})]}),jsxRuntime.jsxs(da__default.default,{item:true,display:"flex",gap:1,alignItems:"center",children:[v&&jsxRuntime.jsx(_L,{checkoutLocalization:t}),jsxRuntime.jsxs(rt,{variant:"body1",color:"secondary",style:{whiteSpace:s?"nowrap":"break-spaces"},children:[i_({totalAmount:P,quantity:n,currency:r.currency,pricingModel:r.pricingModel,billingPeriod:r.billingPeriod,tiers:r.tiers,tiersMode:r.tiersMode,blockSize:r.blockSize,priceAmount:r.amount,availableBillingPeriods:new Set(o==null?void 0:o.pricePoints.map(R=>R.billingPeriod))}),v&&" / unit"]})]})]}),x&&jsxRuntime.jsx(xL__default.default,{in:c,children:jsxRuntime.jsx(EL,{children:x})})]})},s_=({label:t})=>jsxRuntime.jsx(ma,{children:jsxRuntime.jsxs(Lo,{style:{alignItems:"flex-end"},children:[jsxRuntime.jsx(da__default.default,{item:true,children:jsxRuntime.jsx(rt,{variant:"body1",color:"secondary",children:t})}),jsxRuntime.jsx(da__default.default,{item:true,display:"flex",gap:1,alignItems:"center",children:jsxRuntime.jsx(rt,{variant:"body1",color:"secondary",style:{wordBreak:"break-word"},children:"Free"})})]})}),l_=({subscriptionPreview:t,isFetchingSubscriptionPreview:e,checkoutLocalization:n})=>{let{immediateInvoice:r,recurringInvoice:i}=t,{discount:o,discountDetails:s}=i||{};return !o||!s?null:jsxRuntime.jsx(ma,{children:jsxRuntime.jsxs(Lo,{children:[jsxRuntime.jsx(rt,{variant:"body1",color:"secondary",children:n.summary.discountText({discountDetails:s,currency:r.total.currency})}),jsxRuntime.jsx(rt,{variant:"body1",color:"secondary",children:e?jsxRuntime.jsx(Un,{width:50,height:16}):wn({amount:o.amount,currency:o.currency,minimumFractionDigits:2})})]})})},c_=({subscriptionPreview:t,isFetchingSubscriptionPreview:e,checkoutLocalization:n})=>{let{immediateInvoice:r}=t||{},{credits:i}=r||{};return !i||!i.used||i.used.amount<=0?null:jsxRuntime.jsx(ma,{children:jsxRuntime.jsxs(Lo,{children:[jsxRuntime.jsx(rt,{variant:"body1",color:"secondary",children:n.summary.appliedCreditsTitle}),jsxRuntime.jsx(rt,{variant:"body1",color:"secondary",children:jsxRuntime.jsx(No,{isLoading:e,children:wn({amount:-1*i.used.amount,currency:i.used.currency,minimumFractionDigits:2})})})]})})},u_=({tax:t,taxDetails:e,isFetchingSubscriptionPreview:n,checkoutLocalization:r})=>!e||!t||(t==null?void 0:t.amount)<=0?null:jsxRuntime.jsx(ma,{children:jsxRuntime.jsxs(Lo,{children:[jsxRuntime.jsx(rt,{variant:"body1",color:"secondary",children:r.summary.taxTitle({taxDetails:e})}),jsxRuntime.jsx(rt,{variant:"body1",color:"secondary",children:jsxRuntime.jsx(No,{isLoading:n,children:wn({amount:t==null?void 0:t.amount,currency:t==null?void 0:t.currency,minimumFractionDigits:2})})})]})});var Yv=Q(bg__default.default)`
5456
5456
  width: 100%;
5457
5457
  max-width: 470px;
5458
5458
  flex: 1.5;
@@ -5470,7 +5470,7 @@ ${e.o5f}`,e.zBW=r.default`
5470
5470
  margin: 16px 0;
5471
5471
  `,d_=Q(rt)`
5472
5472
  margin-bottom: 8px;
5473
- `;function RL({isLastStep:t,checkoutHasChanges:e,isFreeDowngrade:n,checkoutLocalization:r,isPlanUpdate:i}){return t?e?i?r.checkoutButton.updateText:n?r.checkoutButton.downgradeToFreeText:r.checkoutButton.upgradeText:r.checkoutButton.noChangesText:r.checkoutButton.nextText}var f_=({onCheckout:t,onCheckoutCompleted:e,disablePromotionCode:n,disableSuccessAnimation:r,isFreeDowngrade:i,onMockCheckoutPreview:o,showWatermark:s})=>{var Gn,ln,Ke,dn,or;let[c,p]=Uv.useState(false),{setErrorMessage:h,useNewPaymentMethod:v}=Pi(),P=ha(),x=Qu(),{checkoutState:T,checkoutLocalization:I,checkoutSuccess:F,widgetState:A}=ze(),{plan:O,activeSubscription:N}=T||{},V=eg(((Gn=O==null?void 0:O.pricePoints)==null?void 0:Gn.filter(_e=>_e.billingPeriod===x.billingPeriod))||[]),[G,X]=wL__default.default(V,_e=>_e.pricingModel===nn.FlatFee),nt=G[0],st=i||P.isCheckoutComplete&&P.isLastStep,{isZuoraIntegration:U}=Ku(),j=c||F,{subscriptionPreview:ut,isFetchingSubscriptionPreview:Y}=yE({onMockCheckoutPreview:o}),{handleSubmit:at,isLoading:pt}=KE({isMocked:!!o,disableSuccessAnimation:r,onCheckout:t,onCheckoutCompleted:e,onSuccess:()=>{p(true),P.markStepAsCompleted(P.progressBarState.activeStep);}}),{handleZuoraSubmit:dt}=ug({onCheckout:t,onCheckoutCompleted:e,disableSuccessAnimation:r,onSuccess:()=>{P.markStepAsCompleted(P.progressBarState.activeStep);}}),mt=_e=>ce(null,null,function*(){if(j)return;let De;U&&!v?De=yield dt():De=yield at(_e);let{errorMessage:vr}=De||{};vr?(h(vr),p(false)):h(void 0);}),Ct=U&&!v?A.readOnly:pt,jt=_e=>ce(null,null,function*(){Ct||(st?yield mt(_e):P.goNext());}),{immediateInvoice:Gt,recurringInvoice:Jt}=ut||{},ee=!!ut&&(!!(Gt!=null&&Gt.proration)||!!ut.hasScheduledUpdates),re=!n&&!i&&!U,Ee=!!(Jt!=null&&Jt.discountDetails)&&!i,je=re||Ee,sn=X.some(_e=>_e.pricingModel===nn.UsageBased),Ze=sn&&!nt&&X.every(_e=>_e.pricingModel===nn.UsageBased),Pn=typeof I.summary.baseChargeText=="function"?I.summary.baseChargeText({billingPeriod:x.billingPeriod}):I.summary.baseChargeText;return jsxRuntime.jsxs(Yv,{children:[jsxRuntime.jsxs(hg,{children:[jsxRuntime.jsx(OL,{variant:"h3",children:I.summary.title}),jsxRuntime.jsxs(da__default.default,{className:"stigg-checkout-summary-plan-title-container",display:"flex",flexDirection:"row",alignItems:"center",marginY:2,children:[jsxRuntime.jsx(rt,{variant:"h6",color:"primary",style:{paddingRight:"8px"},children:I.summary.planName({plan:O})}),jsxRuntime.jsx(Xu,{className:"stigg-checkout-summary-divider",sx:{flex:1,margin:"0 !important"}})]}),nt&&jsxRuntime.jsx(fg,{checkoutLocalization:I,label:Pn,quantity:1,price:nt}),!nt&&i?jsxRuntime.jsx(s_,{label:Pn}):null,jsxRuntime.jsx(da__default.default,{item:true,className:"stigg-checkout-summary-usage-charges-container",children:X.map(_e=>{var vr,Ve,bt,ar,sr;let De=(vr=x.billableFeatures)==null?void 0:vr.find(Jn=>{var lr;return Jn.featureId===((lr=_e.feature)==null?void 0:lr.featureId)});return jsxRuntime.jsx(fg,{checkoutLocalization:I,label:Wp(((bt=_e.feature)==null?void 0:bt.displayName)||"",(ar=_e.feature)==null?void 0:ar.units,(sr=_e.feature)==null?void 0:sr.unitsPlural),quantity:(De==null?void 0:De.quantity)||1,price:_e},(Ve=_e.feature)==null?void 0:Ve.featureId)})}),!!((ln=x.addons)!=null&&ln.length)&&jsxRuntime.jsxs(jsxRuntime.Fragment,{children:[jsxRuntime.jsxs(da__default.default,{display:"flex",flexDirection:"row",alignItems:"center",marginY:2,children:[jsxRuntime.jsx(rt,{variant:"h6",color:"primary",style:{paddingRight:"8px"},children:I.summary.addonsSectionTitle}),jsxRuntime.jsx(Xu,{className:"stigg-checkout-summary-divider",sx:{flex:1,margin:"0 !important"}})]}),x.addons.map(_e=>{var Ve,bt;let De=(Ve=_e.addon.pricePoints)==null?void 0:Ve.find(ar=>ar.billingPeriod===x.billingPeriod);if(!De)return null;let vr=_e.quantity&&_e.quantity>0?_e.quantity:1;return jsxRuntime.jsx(fg,{checkoutLocalization:I,label:_e.addon.displayName,quantity:vr,price:De},(bt=_e==null?void 0:_e.addon)==null?void 0:bt.id)})]}),!je&&jsxRuntime.jsx(Xu,{className:"stigg-checkout-summary-divider"}),je&&jsxRuntime.jsxs(da__default.default,{display:"flex",flexDirection:"row",alignItems:"center",marginY:2,children:[jsxRuntime.jsx(rt,{variant:"h6",color:"primary",style:{paddingRight:"8px"},children:I.summary.discountsSectionTitle}),jsxRuntime.jsx(Xu,{className:"stigg-checkout-summary-divider",sx:{flex:1,margin:"0 !important"}})]}),re&&jsxRuntime.jsx($E,{disabled:Ct||Y,checkoutLocalization:I,onMockCheckoutPreview:o}),Ee&&ut&&jsxRuntime.jsx(l_,{subscriptionPreview:ut,isFetchingSubscriptionPreview:Y,checkoutLocalization:I}),je&&jsxRuntime.jsx(Xu,{className:"stigg-checkout-summary-divider"}),jsxRuntime.jsx(u_,{tax:Jt==null?void 0:Jt.tax,taxDetails:Jt==null?void 0:Jt.taxDetails,isFetchingSubscriptionPreview:Y,checkoutLocalization:I}),i?null:jsxRuntime.jsxs(jsxRuntime.Fragment,{children:[jsxRuntime.jsx(Lo,{style:{marginTop:16},children:jsxRuntime.jsxs(da__default.default,{display:"flex",flexDirection:"column",container:true,children:[jsxRuntime.jsxs(da__default.default,{item:true,display:"flex",justifyContent:"space-between",children:[jsxRuntime.jsx(rt,{variant:"h6",children:I.summary.totalText}),jsxRuntime.jsx(rt,{variant:"h6",children:jsxRuntime.jsxs(No,{isLoading:Y,children:[Ze?I.summary.onlyPayAsYouGoText:null,!Ze&&sn?I.summary.startsAtText:null,Ze?null:wn(St(W({amount:0},Jt==null?void 0:Jt.total),{minimumFractionDigits:2}))]})})]}),jsxRuntime.jsx(da__default.default,{item:true,children:jsxRuntime.jsx(rt,{variant:"body1",color:"secondary",children:I.summary.totalBillingPeriodText({billingPeriod:x.billingPeriod})})})]})}),jsxRuntime.jsx(Xu,{className:"stigg-checkout-summary-divider"})]}),(Ke=Gt==null?void 0:Gt.proration)!=null&&Ke.hasProrations&&(Gt!=null&&Gt.subTotal)&&(Gt==null?void 0:Gt.subTotal.amount)>0?jsxRuntime.jsx(ma,{children:jsxRuntime.jsxs(Lo,{children:[jsxRuntime.jsx(rt,{variant:"body1",color:"secondary",children:I.summary.proratedTotalDueText}),jsxRuntime.jsx(rt,{variant:"body1",color:"secondary",children:jsxRuntime.jsx(No,{isLoading:Y,children:wn({amount:Number(((dn=Gt==null?void 0:Gt.subTotal)==null?void 0:dn.amount)||0)+Number(((or=Gt==null?void 0:Gt.tax)==null?void 0:or.amount)||0),currency:Gt==null?void 0:Gt.subTotal.currency,minimumFractionDigits:2})})})]})}):null,jsxRuntime.jsx(c_,{subscriptionPreview:ut,isFetchingSubscriptionPreview:Y,checkoutLocalization:I}),jsxRuntime.jsx(ma,{children:jsxRuntime.jsxs(Lo,{children:[jsxRuntime.jsx(d_,{variant:"h6",children:I.summary.totalDueText}),jsxRuntime.jsx(d_,{variant:"h6",children:jsxRuntime.jsx(No,{isLoading:Y,children:wn(St(W({amount:0},Gt==null?void 0:Gt.total),{minimumFractionDigits:2}))})})]})}),jsxRuntime.jsx(r_,{plan:O,activeSubscription:N,subscriptionPreview:ut,isFetchingSubscriptionPreview:Y,checkoutLocalization:I,billingPeriod:x.billingPeriod}),(!st||!U||U&&!v)&&jsxRuntime.jsx($i,{$success:j,$error:st&&i,disabled:Ct||Y||P.progressBarState.isDisabled||st&&!ee,className:"stigg-checkout-summary-cta-button",sx:{textTransform:"none",borderRadius:"10px",marginTop:"24px",height:"36px"},variant:"contained",size:"medium",onClick:_e=>{jt(_e);},fullWidth:true,children:jsxRuntime.jsx(rt,{className:"stigg-checkout-summary-cta-button-text",variant:"h3",color:"white",style:{display:"flex"},children:j?jsxRuntime.jsx(qn,{icon:"Check",style:{display:"contents"}}):Ct||Y?jsxRuntime.jsx(T3__default.default,{size:20,sx:{color:"white"}}):RL({isLastStep:st,checkoutHasChanges:ee,isFreeDowngrade:i,checkoutLocalization:I,isPlanUpdate:!!N&&(N==null?void 0:N.plan.id)===(O==null?void 0:O.id)})})})]}),jsxRuntime.jsx(so,{source:"checkout",showWatermark:s,style:{marginTop:8,display:"flex",justifyContent:"center"}}),!r&&j&&jsxRuntime.jsx(QE,{checkoutLocalization:I})]})};var h_=({showWatermark:t})=>jsxRuntime.jsxs(Yv,{children:[jsxRuntime.jsxs(hg,{children:[jsxRuntime.jsxs(uc,{$flexDirection:"column",$gap:24,children:[jsxRuntime.jsx(Un,{width:120,height:20}),jsxRuntime.jsx(Un,{width:120,height:20}),jsxRuntime.jsx(Un,{width:120,height:20}),jsxRuntime.jsx(Un,{width:120,height:20})]}),jsxRuntime.jsxs(uc,{$flexDirection:"column",$gap:24,marginTop:5,children:[jsxRuntime.jsx(Un,{height:20}),jsxRuntime.jsx(Un,{height:20}),jsxRuntime.jsx(Un,{height:20})]}),jsxRuntime.jsx(Lp,{flex:1,marginTop:5,children:jsxRuntime.jsx(Un,{height:34})})]}),jsxRuntime.jsx(so,{source:"checkout",showWatermark:t,style:{marginTop:8,display:"flex",justifyContent:"center"}})]});var g_=Q(da__default.default)`
5473
+ `;function RL({isLastStep:t,checkoutHasChanges:e,isFreeDowngrade:n,checkoutLocalization:r,isPlanUpdate:i}){return t?e?i?r.checkoutButton.updateText:n?r.checkoutButton.downgradeToFreeText:r.checkoutButton.upgradeText:r.checkoutButton.noChangesText:r.checkoutButton.nextText}var f_=({onCheckout:t,onCheckoutCompleted:e,disablePromotionCode:n,disableSuccessAnimation:r,isFreeDowngrade:i,onMockCheckoutPreview:o,showWatermark:s})=>{var Gn,ln,Ke,dn,or;let[c,p]=Uv.useState(false),{setErrorMessage:h,useNewPaymentMethod:v}=Pi(),P=ha(),x=Qu(),{checkoutState:T,checkoutLocalization:I,checkoutSuccess:R,widgetState:A}=ze(),{plan:O,activeSubscription:N}=T||{},V=eg(((Gn=O==null?void 0:O.pricePoints)==null?void 0:Gn.filter(_e=>_e.billingPeriod===x.billingPeriod))||[]),[G,X]=wL__default.default(V,_e=>_e.pricingModel===nn.FlatFee),nt=G[0],st=i||P.isCheckoutComplete&&P.isLastStep,{isZuoraIntegration:U}=Ku(),j=c||R,{subscriptionPreview:ut,isFetchingSubscriptionPreview:Y}=yE({onMockCheckoutPreview:o}),{handleSubmit:at,isLoading:pt}=KE({isMocked:!!o,disableSuccessAnimation:r,onCheckout:t,onCheckoutCompleted:e,onSuccess:()=>{p(true),P.markStepAsCompleted(P.progressBarState.activeStep);}}),{handleZuoraSubmit:dt}=ug({onCheckout:t,onCheckoutCompleted:e,disableSuccessAnimation:r,onSuccess:()=>{P.markStepAsCompleted(P.progressBarState.activeStep);}}),mt=_e=>ce(null,null,function*(){if(j)return;let De;U&&!v?De=yield dt():De=yield at(_e);let{errorMessage:vr}=De||{};vr?(h(vr),p(false)):h(void 0);}),Ct=U&&!v?A.readOnly:pt,jt=_e=>ce(null,null,function*(){Ct||(st?yield mt(_e):P.goNext());}),{immediateInvoice:Gt,recurringInvoice:Jt}=ut||{},ee=!!ut&&(!!(Gt!=null&&Gt.proration)||!!ut.hasScheduledUpdates),re=!n&&!i&&!U,Ee=!!(Jt!=null&&Jt.discountDetails)&&!i,je=re||Ee,sn=X.some(_e=>_e.pricingModel===nn.UsageBased),Ze=sn&&!nt&&X.every(_e=>_e.pricingModel===nn.UsageBased),Pn=typeof I.summary.baseChargeText=="function"?I.summary.baseChargeText({billingPeriod:x.billingPeriod}):I.summary.baseChargeText;return jsxRuntime.jsxs(Yv,{children:[jsxRuntime.jsxs(hg,{children:[jsxRuntime.jsx(OL,{variant:"h3",children:I.summary.title}),jsxRuntime.jsxs(da__default.default,{className:"stigg-checkout-summary-plan-title-container",display:"flex",flexDirection:"row",alignItems:"center",marginY:2,children:[jsxRuntime.jsx(rt,{variant:"h6",color:"primary",style:{paddingRight:"8px"},children:I.summary.planName({plan:O})}),jsxRuntime.jsx(Xu,{className:"stigg-checkout-summary-divider",sx:{flex:1,margin:"0 !important"}})]}),nt&&jsxRuntime.jsx(fg,{checkoutLocalization:I,label:Pn,quantity:1,price:nt}),!nt&&i?jsxRuntime.jsx(s_,{label:Pn}):null,jsxRuntime.jsx(da__default.default,{item:true,className:"stigg-checkout-summary-usage-charges-container",children:X.map(_e=>{var vr,Ve,bt,ar,sr;let De=(vr=x.billableFeatures)==null?void 0:vr.find(Jn=>{var lr;return Jn.featureId===((lr=_e.feature)==null?void 0:lr.featureId)});return jsxRuntime.jsx(fg,{checkoutLocalization:I,label:Wp(((bt=_e.feature)==null?void 0:bt.displayName)||"",(ar=_e.feature)==null?void 0:ar.units,(sr=_e.feature)==null?void 0:sr.unitsPlural),quantity:(De==null?void 0:De.quantity)||1,price:_e},(Ve=_e.feature)==null?void 0:Ve.featureId)})}),!!((ln=x.addons)!=null&&ln.length)&&jsxRuntime.jsxs(jsxRuntime.Fragment,{children:[jsxRuntime.jsxs(da__default.default,{display:"flex",flexDirection:"row",alignItems:"center",marginY:2,children:[jsxRuntime.jsx(rt,{variant:"h6",color:"primary",style:{paddingRight:"8px"},children:I.summary.addonsSectionTitle}),jsxRuntime.jsx(Xu,{className:"stigg-checkout-summary-divider",sx:{flex:1,margin:"0 !important"}})]}),x.addons.map(_e=>{var Ve,bt;let De=(Ve=_e.addon.pricePoints)==null?void 0:Ve.find(ar=>ar.billingPeriod===x.billingPeriod);if(!De)return null;let vr=_e.quantity&&_e.quantity>0?_e.quantity:1;return jsxRuntime.jsx(fg,{checkoutLocalization:I,label:_e.addon.displayName,quantity:vr,price:De},(bt=_e==null?void 0:_e.addon)==null?void 0:bt.id)})]}),!je&&jsxRuntime.jsx(Xu,{className:"stigg-checkout-summary-divider"}),je&&jsxRuntime.jsxs(da__default.default,{display:"flex",flexDirection:"row",alignItems:"center",marginY:2,children:[jsxRuntime.jsx(rt,{variant:"h6",color:"primary",style:{paddingRight:"8px"},children:I.summary.discountsSectionTitle}),jsxRuntime.jsx(Xu,{className:"stigg-checkout-summary-divider",sx:{flex:1,margin:"0 !important"}})]}),re&&jsxRuntime.jsx($E,{disabled:Ct||Y,checkoutLocalization:I,onMockCheckoutPreview:o}),Ee&&ut&&jsxRuntime.jsx(l_,{subscriptionPreview:ut,isFetchingSubscriptionPreview:Y,checkoutLocalization:I}),je&&jsxRuntime.jsx(Xu,{className:"stigg-checkout-summary-divider"}),jsxRuntime.jsx(u_,{tax:Jt==null?void 0:Jt.tax,taxDetails:Jt==null?void 0:Jt.taxDetails,isFetchingSubscriptionPreview:Y,checkoutLocalization:I}),i?null:jsxRuntime.jsxs(jsxRuntime.Fragment,{children:[jsxRuntime.jsx(Lo,{style:{marginTop:16},children:jsxRuntime.jsxs(da__default.default,{display:"flex",flexDirection:"column",container:true,children:[jsxRuntime.jsxs(da__default.default,{item:true,display:"flex",justifyContent:"space-between",children:[jsxRuntime.jsx(rt,{variant:"h6",children:I.summary.totalText}),jsxRuntime.jsx(rt,{variant:"h6",children:jsxRuntime.jsxs(No,{isLoading:Y,children:[Ze?I.summary.onlyPayAsYouGoText:null,!Ze&&sn?I.summary.startsAtText:null,Ze?null:wn(St(W({amount:0},Jt==null?void 0:Jt.total),{minimumFractionDigits:2}))]})})]}),jsxRuntime.jsx(da__default.default,{item:true,children:jsxRuntime.jsx(rt,{variant:"body1",color:"secondary",children:I.summary.totalBillingPeriodText({billingPeriod:x.billingPeriod})})})]})}),jsxRuntime.jsx(Xu,{className:"stigg-checkout-summary-divider"})]}),(Ke=Gt==null?void 0:Gt.proration)!=null&&Ke.hasProrations&&(Gt!=null&&Gt.subTotal)&&(Gt==null?void 0:Gt.subTotal.amount)>0?jsxRuntime.jsx(ma,{children:jsxRuntime.jsxs(Lo,{children:[jsxRuntime.jsx(rt,{variant:"body1",color:"secondary",children:I.summary.proratedTotalDueText}),jsxRuntime.jsx(rt,{variant:"body1",color:"secondary",children:jsxRuntime.jsx(No,{isLoading:Y,children:wn({amount:Number(((dn=Gt==null?void 0:Gt.subTotal)==null?void 0:dn.amount)||0)+Number(((or=Gt==null?void 0:Gt.tax)==null?void 0:or.amount)||0),currency:Gt==null?void 0:Gt.subTotal.currency,minimumFractionDigits:2})})})]})}):null,jsxRuntime.jsx(c_,{subscriptionPreview:ut,isFetchingSubscriptionPreview:Y,checkoutLocalization:I}),jsxRuntime.jsx(ma,{children:jsxRuntime.jsxs(Lo,{children:[jsxRuntime.jsx(d_,{variant:"h6",children:I.summary.totalDueText}),jsxRuntime.jsx(d_,{variant:"h6",children:jsxRuntime.jsx(No,{isLoading:Y,children:wn(St(W({amount:0},Gt==null?void 0:Gt.total),{minimumFractionDigits:2}))})})]})}),jsxRuntime.jsx(r_,{plan:O,activeSubscription:N,subscriptionPreview:ut,isFetchingSubscriptionPreview:Y,checkoutLocalization:I,billingPeriod:x.billingPeriod}),(!st||!U||U&&!v)&&jsxRuntime.jsx($i,{$success:j,$error:st&&i,disabled:Ct||Y||P.progressBarState.isDisabled||st&&!ee,className:"stigg-checkout-summary-cta-button",sx:{textTransform:"none",borderRadius:"10px",marginTop:"24px",height:"36px"},variant:"contained",size:"medium",onClick:_e=>{jt(_e);},fullWidth:true,children:jsxRuntime.jsx(rt,{className:"stigg-checkout-summary-cta-button-text",variant:"h3",color:"white",style:{display:"flex"},children:j?jsxRuntime.jsx(qn,{icon:"Check",style:{display:"contents"}}):Ct||Y?jsxRuntime.jsx(T3__default.default,{size:20,sx:{color:"white"}}):RL({isLastStep:st,checkoutHasChanges:ee,isFreeDowngrade:i,checkoutLocalization:I,isPlanUpdate:!!N&&(N==null?void 0:N.plan.id)===(O==null?void 0:O.id)})})})]}),jsxRuntime.jsx(so,{source:"checkout",showWatermark:s,style:{marginTop:8,display:"flex",justifyContent:"center"}}),!r&&j&&jsxRuntime.jsx(QE,{checkoutLocalization:I})]})};var h_=({showWatermark:t})=>jsxRuntime.jsxs(Yv,{children:[jsxRuntime.jsxs(hg,{children:[jsxRuntime.jsxs(uc,{$flexDirection:"column",$gap:24,children:[jsxRuntime.jsx(Un,{width:120,height:20}),jsxRuntime.jsx(Un,{width:120,height:20}),jsxRuntime.jsx(Un,{width:120,height:20}),jsxRuntime.jsx(Un,{width:120,height:20})]}),jsxRuntime.jsxs(uc,{$flexDirection:"column",$gap:24,marginTop:5,children:[jsxRuntime.jsx(Un,{height:20}),jsxRuntime.jsx(Un,{height:20}),jsxRuntime.jsx(Un,{height:20})]}),jsxRuntime.jsx(Lp,{flex:1,marginTop:5,children:jsxRuntime.jsx(Un,{height:34})})]}),jsxRuntime.jsx(so,{source:"checkout",showWatermark:t,style:{marginTop:8,display:"flex",justifyContent:"center"}})]});var g_=Q(da__default.default)`
5474
5474
  width: 100%;
5475
5475
  gap: 8px;
5476
5476
  `,y_=Q(da__default.default)`
@@ -5499,13 +5499,13 @@ ${e.o5f}`,e.zBW=r.default`
5499
5499
  align-items: center;
5500
5500
  width: 100%;
5501
5501
  justify-content: flex-end;
5502
- `;function S_({addon:t,addonState:e,hasChanges:n,errorMessage:r,isPriceForBillingPeriodAvailable:i,checkoutLocalization:o,handleQuantityChange:s,handleUndo:c,handleRemoveAddon:p}){var P;let h=Ci("lg"),v=!!e;return jsxRuntime.jsxs(ML,{item:true,sx:{gap:"16px"},container:!h,children:[n&&jsxRuntime.jsx($i,{variant:"text",size:"small",sx:{padding:"8px",minWidth:"unset"},onClick:c,children:jsxRuntime.jsx(rt,{color:"primary.main",variant:"body1",children:"Undo"})}),v&&jsxRuntime.jsxs(material.Grid,{sx:{display:"flex",width:"100%"},children:[jsxRuntime.jsx(Zs,{id:`${t.id}-input`,type:"number",onWheel:$u,sx:h?{marginX:2,width:"100%"}:{flex:1},value:(P=e==null?void 0:e.quantity)!=null?P:"",error:!!r,helperText:r,FormHelperTextProps:{sx:{margin:"4px"}},onChange:x=>{var T,I;return s((T=x==null?void 0:x.target)!=null&&T.value?Number((I=x==null?void 0:x.target)==null?void 0:I.value):null)}}),jsxRuntime.jsx(b_,{color:"error",onClick:p,children:jsxRuntime.jsx(qn,{icon:"Trash",style:{display:"flex",padding:"8px"}})})]}),!v&&jsxRuntime.jsx($i,{sx:{paddingX:"22px",paddingY:"8px"},onClick:()=>s(1),disabled:!i,children:jsxRuntime.jsx(rt,{color:i?"primary.main":"disabled",variant:"body1",children:o.addAddonText})})]})}var LL=Q(material.Grid)`
5502
+ `;function S_({addon:t,addonState:e,hasChanges:n,errorMessage:r,isPriceForBillingPeriodAvailable:i,checkoutLocalization:o,handleQuantityChange:s,handleUndo:c,handleRemoveAddon:p}){var x;let h=Ci("lg"),v=!!e,P=t.maxQuantity!==1;return jsxRuntime.jsxs(ML,{item:true,sx:{gap:"16px"},container:!h,children:[n&&jsxRuntime.jsx($i,{variant:"text",size:"small",sx:{padding:"8px",minWidth:"unset"},onClick:c,children:jsxRuntime.jsx(rt,{color:"primary.main",variant:"body1",children:"Undo"})}),v&&jsxRuntime.jsxs(material.Grid,{sx:{display:"flex",width:"100%",justifyContent:"flex-end"},children:[P&&jsxRuntime.jsx(Zs,{id:`${t.id}-input`,type:"number",onWheel:$u,sx:h?{marginX:2,width:"100%"}:{flex:1},value:(x=e==null?void 0:e.quantity)!=null?x:"",error:!!r,helperText:r,FormHelperTextProps:{sx:{margin:"4px"}},onChange:T=>{var I,R;return s((I=T==null?void 0:T.target)!=null&&I.value?Number((R=T==null?void 0:T.target)==null?void 0:R.value):null)},onFocus:T=>T.target.select()}),jsxRuntime.jsx(b_,{color:"error",onClick:p,children:jsxRuntime.jsx(qn,{icon:"Trash",style:{display:"flex",padding:"8px"}})})]}),!v&&jsxRuntime.jsx($i,{sx:{paddingX:"22px",paddingY:"8px"},onClick:()=>s(1),disabled:!i,children:jsxRuntime.jsx(rt,{color:i?"primary.main":"disabled",variant:"body1",children:o.addAddonText})})]})}var LL=Q(material.Grid)`
5503
5503
  display: flex;
5504
5504
  flex-direction: column;
5505
5505
  justify-content: center;
5506
5506
  width: 100%;
5507
5507
  height: 42px;
5508
- `;function P_({addon:t,billingPeriod:e,checkoutLocalization:n}){let r=t.pricePoints.find(i=>i.billingPeriod===e);return jsxRuntime.jsxs(LL,{item:true,children:[jsxRuntime.jsx(rt,{variant:"h6",lineHeight:"24px",children:t.displayName}),r?jsxRuntime.jsx(rt,{variant:"body1",lineHeight:"20px",color:"secondary",children:`${wn({amount:r.amount,currency:r.currency,minimumFractionDigits:2})}/${e===be.Annually?"year":"month"}`}):jsxRuntime.jsx(rt,{variant:"body1",lineHeight:"20px",color:"secondary",children:n.addonBillingPeriodNotAvailableText({planBillingPeriod:e})})]})}function $L({addon:t,billingPeriod:e,addonState:n,initialAddonState:r,setAddon:i,removeAddon:o,checkoutLocalization:s,onAddonsValidationChange:c,onAddonChange:p}){let[h,v]=Uv.useState(void 0),P=!!n&&!!r&&n.quantity!==r.quantity||!!r&&!n,x=t.pricePoints.some(A=>A.billingPeriod===e),T=A=>ce(null,null,function*(){if(!A||A<=0){c({addonId:t.id,isValid:false}),v("Minimum 1"),i(t,A!=null?A:null);return}let O=yield p==null?void 0:p({addon:t,quantity:A});v(O==null?void 0:O.errorMessage),c({addonId:t.id,isValid:!(O!=null&&O.disableNextStep)}),i(t,A);}),I=()=>ce(null,null,function*(){yield p==null?void 0:p({addon:t,quantity:0}),o(t.id),c({addonId:t.id,isValid:true});});return jsxRuntime.jsxs(y_,{children:[jsxRuntime.jsx(P_,{addon:t,billingPeriod:e,checkoutLocalization:s}),jsxRuntime.jsx(S_,{addon:t,addonState:n,hasChanges:P,handleUndo:()=>ce(null,null,function*(){if(r){let A=yield p==null?void 0:p({addon:t,quantity:r.quantity});c({addonId:t.id,isValid:!(A!=null&&A.disableNextStep)}),i(t,r.quantity);}else yield I();c({addonId:t.id,isValid:true});}),errorMessage:h,handleQuantityChange:T,isPriceForBillingPeriodAvailable:x,checkoutLocalization:s,handleRemoveAddon:I})]})}function E_({onAddonChange:t}){let{checkoutLocalization:e,setIsValid:n}=ze(),{billingPeriod:r}=lo(),{setIsDisabled:i}=ha(),{initialAddons:o,addons:s,availableAddons:c,setAddon:p,removeAddon:h}=vx(),[v,P]=Uv.useState((c==null?void 0:c.reduce((x,T)=>(x[T.id]=true,x),{}))||{});return Uv.useEffect(()=>{let x=Object.values(v).some(T=>!T);i(x),n(!x);},[v,i,n]),jsxRuntime.jsx(g_,{container:true,children:c==null?void 0:c.map(x=>{let T=s.find(F=>F.addon.id===x.id),I=o==null?void 0:o.find(F=>F.addon.id===x.id);return jsxRuntime.jsx($L,{addon:x,billingPeriod:r,addonState:T,initialAddonState:I,setAddon:p,removeAddon:h,checkoutLocalization:e,onAddonsValidationChange:({addonId:F,isValid:A})=>P(St(W({},v),{[F]:A})),onAddonChange:t},x.id)})})}var Xv=Q(da__default.default)`
5508
+ `;function P_({addon:t,billingPeriod:e,checkoutLocalization:n}){let r=t.pricePoints.find(i=>i.billingPeriod===e);return jsxRuntime.jsxs(LL,{item:true,children:[jsxRuntime.jsx(rt,{variant:"h6",lineHeight:"24px",children:t.displayName}),r?jsxRuntime.jsx(rt,{variant:"body1",lineHeight:"20px",color:"secondary",children:`${wn({amount:r.amount,currency:r.currency,minimumFractionDigits:2})}/${e===be.Annually?"year":"month"}`}):jsxRuntime.jsx(rt,{variant:"body1",lineHeight:"20px",color:"secondary",children:n.addonBillingPeriodNotAvailableText({planBillingPeriod:e})})]})}function $L({addon:t,billingPeriod:e,addonState:n,initialAddonState:r,setAddon:i,removeAddon:o,checkoutLocalization:s,onAddonsValidationChange:c,onAddonChange:p}){let[h,v]=Uv.useState(void 0),P=!!n&&!!r&&n.quantity!==r.quantity||!!r&&!n,x=t.pricePoints.some(A=>A.billingPeriod===e),T=A=>ce(null,null,function*(){if(!A||A<=0){c({addonId:t.id,isValid:false}),v("Minimum 1"),i(t,A!=null?A:null);return}let O=yield p==null?void 0:p({addon:t,quantity:A});v(O==null?void 0:O.errorMessage),c({addonId:t.id,isValid:!(O!=null&&O.disableNextStep)}),i(t,A);}),I=()=>ce(null,null,function*(){yield p==null?void 0:p({addon:t,quantity:0}),o(t.id),c({addonId:t.id,isValid:true});});return jsxRuntime.jsxs(y_,{children:[jsxRuntime.jsx(P_,{addon:t,billingPeriod:e,checkoutLocalization:s}),jsxRuntime.jsx(S_,{addon:t,addonState:n,hasChanges:P,handleUndo:()=>ce(null,null,function*(){if(r){let A=yield p==null?void 0:p({addon:t,quantity:r.quantity});c({addonId:t.id,isValid:!(A!=null&&A.disableNextStep)}),i(t,r.quantity);}else yield I();c({addonId:t.id,isValid:true});}),errorMessage:h,handleQuantityChange:T,isPriceForBillingPeriodAvailable:x,checkoutLocalization:s,handleRemoveAddon:I})]})}function E_({onAddonChange:t}){let{checkoutLocalization:e,setIsValid:n}=ze(),{billingPeriod:r}=lo(),{setIsDisabled:i}=ha(),{initialAddons:o,addons:s,availableAddons:c,setAddon:p,removeAddon:h}=vx(),[v,P]=Uv.useState((c==null?void 0:c.reduce((x,T)=>(x[T.id]=true,x),{}))||{});return Uv.useEffect(()=>{let x=Object.values(v).some(T=>!T);i(x),n(!x);},[v,i,n]),jsxRuntime.jsx(g_,{container:true,children:c==null?void 0:c.map(x=>{let T=s.find(R=>R.addon.id===x.id),I=o==null?void 0:o.find(R=>R.addon.id===x.id);return jsxRuntime.jsx($L,{addon:x,billingPeriod:r,addonState:T,initialAddonState:I,setAddon:p,removeAddon:h,checkoutLocalization:e,onAddonsValidationChange:({addonId:R,isValid:A})=>P(St(W({},v),{[R]:A})),onAddonChange:t},x.id)})})}var Xv=Q(da__default.default)`
5509
5509
  padding: 8px;
5510
5510
  border-radius: 10px;
5511
5511
  border: 1px solid ${({theme:t})=>t.stigg.palette.outlinedBorder};
@@ -5549,7 +5549,7 @@ ${e.o5f}`,e.zBW=r.default`
5549
5549
  flex-direction: column;
5550
5550
  align-items: center;
5551
5551
  gap: 12px;
5552
- `;function I_({onCheckout:t,onCheckoutCompleted:e}){var A,O,N;let{isZuoraIntegration:n,isInitialized:r,createPaymentSession:i}=Ku(),{setErrorMessage:o}=Pi(),{billingCountryCode:s}=lo(),{checkoutState:c,widgetState:p}=ze(),{handleZuoraSubmit:h}=ug({onCheckout:t,onCheckoutCompleted:e}),v=Uv.useRef(false),[P,x]=Uv__default.default.useState(false),T=((N=(O=(A=c==null?void 0:c.plan)==null?void 0:A.pricePoints)==null?void 0:O[0])==null?void 0:N.currency)||Fu.Usd,{publishableKey:I}=c==null?void 0:c.billingIntegration.billingCredentials,F=Uv.useCallback(V=>ce(null,null,function*(){var G;if(!V.success||!V.paymentMethodId){let X=((G=V.error)==null?void 0:G.message)||"Payment failed";o(X),yield e({success:false,error:X});return}yield h(V.paymentMethodId);}),[h,o,e]);return Uv.useEffect(()=>(ce(null,null,function*(){if(!(!r||v.current)){x(true),o(void 0);try{v.current=!0;let G=window.Zuora(I),X=JE(i,F,T,s);(yield G.createPaymentForm(X)).mount("#zuora_payment");}catch(G){v.current=false,o("Failed to render Zuora payment form");}finally{x(false);}}}),()=>{v.current=false;}),[r]),n?jsxRuntime.jsxs(YL,{children:[jsxRuntime.jsx(QL,{id:"zuora_payment",$showLoading:p.readOnly||P}),(p.readOnly||P)&&jsxRuntime.jsx(KL,{children:jsxRuntime.jsx(XL,{children:jsxRuntime.jsx(T3__default.default,{size:28})})})]}):null}function D_({checked:t,text:e,subtitle:n,readOnly:r}){return jsxRuntime.jsxs(T_,{children:[jsxRuntime.jsx(t5__default.default,{checked:t,disabled:r}),jsxRuntime.jsxs(w_,{container:true,children:[jsxRuntime.jsx(da__default.default,{item:true,children:e}),n&&jsxRuntime.jsx(da__default.default,{item:true,children:n})]})]})}function A_({checked:t,paymentMethodDetails:e,readOnly:n,onSelect:r}){if(!e)return null;let{last4Digits:i,expirationMonth:o,expirationYear:s}=e;return jsxRuntime.jsx(Xv,{item:true,onClick:r,$disabled:n,children:jsxRuntime.jsx(D_,{checked:t,readOnly:n,text:jsxRuntime.jsx(rt,{variant:"h6",children:`Card ending in ${i}`}),subtitle:!!o&&!!s&&jsxRuntime.jsx(rt,{variant:"body1",children:`Expires ${o.toString().padStart(2,"0")}/${s}`})})})}function O_({hasExistingPaymentMethod:t,checked:e,onSelect:n,readOnly:r,checkoutLocalization:i,onBillingAddressChange:o,collectPhoneNumber:s,onCheckout:c,onCheckoutCompleted:p}){let{isZuoraIntegration:h}=Ku();return jsxRuntime.jsxs(__,{item:true,$hideBorders:!t,onClick:n,$disabled:r,children:[t&&jsxRuntime.jsx(D_,{checked:e,readOnly:r,text:jsxRuntime.jsx(rt,{variant:"h6",children:i.newPaymentMethodText})}),jsxRuntime.jsx(xL__default.default,{in:e,children:h?jsxRuntime.jsx(I_,{onCheckout:c,onCheckoutCompleted:p}):jsxRuntime.jsx(GE,{onBillingAddressChange:o,collectPhoneNumber:s})})]})}var r5=Q(da__default.default)`
5552
+ `;function I_({onCheckout:t,onCheckoutCompleted:e}){var A,O,N;let{isZuoraIntegration:n,isInitialized:r,createPaymentSession:i}=Ku(),{setErrorMessage:o}=Pi(),{billingCountryCode:s}=lo(),{checkoutState:c,widgetState:p}=ze(),{handleZuoraSubmit:h}=ug({onCheckout:t,onCheckoutCompleted:e}),v=Uv.useRef(false),[P,x]=Uv__default.default.useState(false),T=((N=(O=(A=c==null?void 0:c.plan)==null?void 0:A.pricePoints)==null?void 0:O[0])==null?void 0:N.currency)||Fu.Usd,{publishableKey:I}=c==null?void 0:c.billingIntegration.billingCredentials,R=Uv.useCallback(V=>ce(null,null,function*(){var G;if(!V.success||!V.paymentMethodId){let X=((G=V.error)==null?void 0:G.message)||"Payment failed";o(X),yield e({success:false,error:X});return}yield h(V.paymentMethodId);}),[h,o,e]);return Uv.useEffect(()=>(ce(null,null,function*(){if(!(!r||v.current)){x(true),o(void 0);try{v.current=!0;let G=window.Zuora(I),X=JE(i,R,T,s);(yield G.createPaymentForm(X)).mount("#zuora_payment");}catch(G){v.current=false,o("Failed to render Zuora payment form");}finally{x(false);}}}),()=>{v.current=false;}),[r]),n?jsxRuntime.jsxs(YL,{children:[jsxRuntime.jsx(QL,{id:"zuora_payment",$showLoading:p.readOnly||P}),(p.readOnly||P)&&jsxRuntime.jsx(KL,{children:jsxRuntime.jsx(XL,{children:jsxRuntime.jsx(T3__default.default,{size:28})})})]}):null}function D_({checked:t,text:e,subtitle:n,readOnly:r}){return jsxRuntime.jsxs(T_,{children:[jsxRuntime.jsx(t5__default.default,{checked:t,disabled:r}),jsxRuntime.jsxs(w_,{container:true,children:[jsxRuntime.jsx(da__default.default,{item:true,children:e}),n&&jsxRuntime.jsx(da__default.default,{item:true,children:n})]})]})}function A_({checked:t,paymentMethodDetails:e,readOnly:n,onSelect:r}){if(!e)return null;let{last4Digits:i,expirationMonth:o,expirationYear:s}=e;return jsxRuntime.jsx(Xv,{item:true,onClick:r,$disabled:n,children:jsxRuntime.jsx(D_,{checked:t,readOnly:n,text:jsxRuntime.jsx(rt,{variant:"h6",children:`Card ending in ${i}`}),subtitle:!!o&&!!s&&jsxRuntime.jsx(rt,{variant:"body1",children:`Expires ${o.toString().padStart(2,"0")}/${s}`})})})}function O_({hasExistingPaymentMethod:t,checked:e,onSelect:n,readOnly:r,checkoutLocalization:i,onBillingAddressChange:o,collectPhoneNumber:s,onCheckout:c,onCheckoutCompleted:p}){let{isZuoraIntegration:h}=Ku();return jsxRuntime.jsxs(__,{item:true,$hideBorders:!t,onClick:n,$disabled:r,children:[t&&jsxRuntime.jsx(D_,{checked:e,readOnly:r,text:jsxRuntime.jsx(rt,{variant:"h6",children:i.newPaymentMethodText})}),jsxRuntime.jsx(xL__default.default,{in:e,children:h?jsxRuntime.jsx(I_,{onCheckout:c,onCheckoutCompleted:p}):jsxRuntime.jsx(GE,{onBillingAddressChange:o,collectPhoneNumber:s})})]})}var r5=Q(da__default.default)`
5553
5553
  display: flex;
5554
5554
  flex-direction: column;
5555
5555
  gap: 24px;
@@ -5610,7 +5610,7 @@ ${e.o5f}`,e.zBW=r.default`
5610
5610
  justify-content: flex-end;
5611
5611
  width: 100%;
5612
5612
  min-height: 42px;
5613
- `,b5=(t,e)=>{let{minUnitQuantity:n,maxUnitQuantity:r}=t;return !e||e<(n||1)?`Minimum ${n||1}`:r&&e>r?`Maximum ${r}`:""};function v5({charge:t,setBillableFeature:e,billableFeature:n,onValidationChange:r,onBillableFeatureChange:i}){var I,F,A,O,N,V;let[o,s]=Uv.useState(void 0),c=(I=t.feature)==null?void 0:I.featureId,p=!c,h=t.pricingModel===nn.UsageBased,v=p?"Base charge":Wp(((F=t.feature)==null?void 0:F.displayName)||"",(A=t.feature)==null?void 0:A.units,(O=t.feature)==null?void 0:O.unitsPlural),P=!!(t!=null&&t.minUnitQuantity||t!=null&&t.maxUnitQuantity),x=G=>ce(null,null,function*(){var ut,Y;if(p||!c)return;let{minUnitQuantity:X,maxUnitQuantity:nt}=t,st=(ut=G==null?void 0:G.target)!=null&&ut.value?Number((Y=G==null?void 0:G.target)==null?void 0:Y.value):null;if(!st||st<=0||X&&st<X||nt&&st>nt){r({featureId:c,isValid:false}),s(b5(t,st!=null?st:void 0)),e(c,st!=null?st:null);return}let U=tg(t,st),j=yield i==null?void 0:i({feature:t.feature,quantity:U});s(j==null?void 0:j.errorMessage),r({featureId:c,isValid:!(j!=null&&j.disableNextStep)}),e(c,U);}),T;if(p||h)T=`${wn({amount:t.amount,currency:t.currency,locale:"en-us",minimumFractionDigits:2})}`,h&&(T+=" / unit");else if(t.isTieredPrice&&t.tiersMode&&c){let G=(n==null?void 0:n.quantity)||1;T=jsxRuntime.jsx(dm,{componentId:`${c}-tiers`,tiers:t.tiers,tiersMode:t.tiersMode,value:G,errorMessage:o,handleChange:X=>ce(null,null,function*(){let nt=yield i==null?void 0:i({feature:t.feature,quantity:X});s(nt==null?void 0:nt.errorMessage),r({featureId:c,isValid:!(nt!=null&&nt.disableNextStep)}),e(c,X);}),width:"100%"});}else T=jsxRuntime.jsx(Zs,{sx:{width:"100%"},id:`${c}-input`,type:"number",onWheel:$u,error:!!o,helperText:o,FormHelperTextProps:{sx:{margin:"4px"}},value:(N=n==null?void 0:n.quantity)!=null?N:"",onChange:x});return jsxRuntime.jsxs(m5,{children:[jsxRuntime.jsxs(g5,{children:[jsxRuntime.jsx(rt,{variant:"h6",color:"primary",lineHeight:"24px",children:v}),P&&jsxRuntime.jsx(rt,{variant:"body1",color:"secondary",lineHeight:"20px",children:nm(t.minUnitQuantity,t.maxUnitQuantity,(V=t.feature)==null?void 0:V.unitsPlural)})]}),jsxRuntime.jsx(y5,{variant:"h6",color:"primary",children:T})]})}function H_({plan:t,billingPeriod:e,onBillableFeatureChange:n}){var v;let{billableFeatures:r,setBillableFeature:i}=lo(),{setIsDisabled:o}=ha(),{setIsValid:s}=ze(),c=eg(((v=t==null?void 0:t.pricePoints)==null?void 0:v.filter(P=>P.billingPeriod===e))||[]),[p,h]=Uv.useState(c==null?void 0:c.reduce((P,x)=>{var T;return P[((T=x.feature)==null?void 0:T.featureId)||"base-charge"]=true,P},{}));return Uv.useEffect(()=>{let P=Object.values(p).some(x=>!x);o(P),s(!P);},[p,o,s]),jsxRuntime.jsx(jsxRuntime.Fragment,{children:c==null?void 0:c.map(P=>{var T;let x=r.find(I=>{var F;return I.featureId===((F=P.feature)==null?void 0:F.featureId)});return jsxRuntime.jsx(v5,{charge:P,setBillableFeature:i,billableFeature:x,onValidationChange:({featureId:I,isValid:F})=>h(A=>St(W({},A),{[I]:F})),onBillableFeatureChange:n},((T=P.feature)==null?void 0:T.featureId)||"base-charge")})})}var W_=Q(bg__default.default)`
5613
+ `,b5=(t,e)=>{let{minUnitQuantity:n,maxUnitQuantity:r}=t;return !e||e<(n||1)?`Minimum ${n||1}`:r&&e>r?`Maximum ${r}`:""};function v5({charge:t,setBillableFeature:e,billableFeature:n,onValidationChange:r,onBillableFeatureChange:i}){var I,R,A,O,N,V;let[o,s]=Uv.useState(void 0),c=(I=t.feature)==null?void 0:I.featureId,p=!c,h=t.pricingModel===nn.UsageBased,v=p?"Base charge":Wp(((R=t.feature)==null?void 0:R.displayName)||"",(A=t.feature)==null?void 0:A.units,(O=t.feature)==null?void 0:O.unitsPlural),P=!!(t!=null&&t.minUnitQuantity||t!=null&&t.maxUnitQuantity),x=G=>ce(null,null,function*(){var ut,Y;if(p||!c)return;let{minUnitQuantity:X,maxUnitQuantity:nt}=t,st=(ut=G==null?void 0:G.target)!=null&&ut.value?Number((Y=G==null?void 0:G.target)==null?void 0:Y.value):null;if(!st||st<=0||X&&st<X||nt&&st>nt){r({featureId:c,isValid:false}),s(b5(t,st!=null?st:void 0)),e(c,st!=null?st:null);return}let U=tg(t,st),j=yield i==null?void 0:i({feature:t.feature,quantity:U});s(j==null?void 0:j.errorMessage),r({featureId:c,isValid:!(j!=null&&j.disableNextStep)}),e(c,U);}),T;if(p||h)T=`${wn({amount:t.amount,currency:t.currency,locale:"en-us",minimumFractionDigits:2})}`,h&&(T+=" / unit");else if(t.isTieredPrice&&t.tiersMode&&c){let G=(n==null?void 0:n.quantity)||1;T=jsxRuntime.jsx(dm,{componentId:`${c}-tiers`,tiers:t.tiers,tiersMode:t.tiersMode,value:G,errorMessage:o,handleChange:X=>ce(null,null,function*(){let nt=yield i==null?void 0:i({feature:t.feature,quantity:X});s(nt==null?void 0:nt.errorMessage),r({featureId:c,isValid:!(nt!=null&&nt.disableNextStep)}),e(c,X);}),width:"100%"});}else T=jsxRuntime.jsx(Zs,{sx:{width:"100%"},id:`${c}-input`,type:"number",onWheel:$u,error:!!o,helperText:o,FormHelperTextProps:{sx:{margin:"4px"}},value:(N=n==null?void 0:n.quantity)!=null?N:"",onChange:x});return jsxRuntime.jsxs(m5,{children:[jsxRuntime.jsxs(g5,{children:[jsxRuntime.jsx(rt,{variant:"h6",color:"primary",lineHeight:"24px",children:v}),P&&jsxRuntime.jsx(rt,{variant:"body1",color:"secondary",lineHeight:"20px",children:nm(t.minUnitQuantity,t.maxUnitQuantity,(V=t.feature)==null?void 0:V.unitsPlural)})]}),jsxRuntime.jsx(y5,{variant:"h6",color:"primary",children:T})]})}function H_({plan:t,billingPeriod:e,onBillableFeatureChange:n}){var v;let{billableFeatures:r,setBillableFeature:i}=lo(),{setIsDisabled:o}=ha(),{setIsValid:s}=ze(),c=eg(((v=t==null?void 0:t.pricePoints)==null?void 0:v.filter(P=>P.billingPeriod===e))||[]),[p,h]=Uv.useState(c==null?void 0:c.reduce((P,x)=>{var T;return P[((T=x.feature)==null?void 0:T.featureId)||"base-charge"]=true,P},{}));return Uv.useEffect(()=>{let P=Object.values(p).some(x=>!x);o(P),s(!P);},[p,o,s]),jsxRuntime.jsx(jsxRuntime.Fragment,{children:c==null?void 0:c.map(P=>{var T;let x=r.find(I=>{var R;return I.featureId===((R=P.feature)==null?void 0:R.featureId)});return jsxRuntime.jsx(v5,{charge:P,setBillableFeature:i,billableFeature:x,onValidationChange:({featureId:I,isValid:R})=>h(A=>St(W({},A),{[I]:R})),onBillableFeatureChange:n},((T=P.feature)==null?void 0:T.featureId)||"base-charge")})})}var W_=Q(bg__default.default)`
5614
5614
  width: 100%;
5615
5615
  `;var Y_=({onChangePlan:t,onBillableFeatureChange:e})=>{let{checkoutState:n,checkoutLocalization:r}=ze(),{plan:i}=n||{},{billingPeriod:o}=lo();return jsxRuntime.jsxs(jsxRuntime.Fragment,{children:[jsxRuntime.jsx(N_,{allowChangePlan:true,onChangePlan:t}),jsxRuntime.jsxs(W_,{children:[jsxRuntime.jsx(j_,{plan:i,checkoutLocalization:r}),jsxRuntime.jsx(H_,{plan:i,billingPeriod:o,onBillableFeatureChange:e})]})]})};var x5=t=>jsxRuntime.jsx("svg",St(W({width:16,height:16,viewBox:"0 0 16 16",fill:"none",xmlns:"http://www.w3.org/2000/svg"},t),{children:jsxRuntime.jsxs("g",{id:"arrow-right",children:[jsxRuntime.jsx("path",{id:"Shape",d:"M2.66699 8H13.3337",stroke:"#7586B0",strokeWidth:1.33333,strokeLinecap:"round",strokeLinejoin:"round"}),jsxRuntime.jsx("path",{id:"Shape_2",d:"M9.33301 4L13.333 8L9.33301 12",stroke:"#7586B0",strokeWidth:1.33333,strokeLinecap:"round",strokeLinejoin:"round"})]})})),Q_=x5;var K_=Q(Q_)`
5616
5616
  path {
@@ -5625,7 +5625,7 @@ ${e.o5f}`,e.zBW=r.default`
5625
5625
  border-radius: 10px;
5626
5626
  width: 100%;
5627
5627
  border: ${({theme:t})=>`1px solid ${t.stigg.palette.outlinedBorder}`};
5628
- `,X_=({headerText:t,planName:e,priceText:n})=>jsxRuntime.jsxs(I5,{className:"stigg-checkout-downgrade-to-free-container",children:[jsxRuntime.jsx(rt,{className:"stigg-checkout-downgrade-to-free-text-header",style:{opacity:.8},variant:"caption",color:"disabled",children:t}),jsxRuntime.jsx(rt,{className:"stigg-checkout-downgrade-to-free-plan-name",bold:true,variant:"h3",color:"primary",children:e}),jsxRuntime.jsx(rt,{className:"stigg-checkout-downgrade-to-free-price-text",color:"secondary",children:n})]}),J_=({checkoutLocalization:t,activeSubscription:e,freePlan:n,allowChangePlan:r=false,onChangePlan:i})=>{let o;r&&i&&(o=jsxRuntime.jsx(Cg,{onClick:()=>{i({currentPlan:n});},checkoutLocalization:t,size:"small"}));let s=e.prices.length>0?e.prices[0].billingPeriod:void 0;return jsxRuntime.jsxs(jsxRuntime.Fragment,{children:[jsxRuntime.jsx(w5,{action:o,className:"stigg-checkout-downgrade-to-free-alert",severity:"info",children:jsxRuntime.jsx(rt,{as:"span",color:"secondary",children:t.downgradeToFree.alertText({plan:e.plan})})}),jsxRuntime.jsxs(T5,{className:"stigg-checkout-downgrade-to-free-plans-container",children:[jsxRuntime.jsx(X_,{headerText:t.downgradeToFree.paidPlanHeader({plan:e.plan}),planName:t.downgradeToFree.paidPlanName({plan:e.plan}),priceText:t.downgradeToFree.paidPlanPriceText({plan:e.plan,billingPeriod:s})}),jsxRuntime.jsx(K_,{className:"stigg-checkout-downgrade-to-free-arrow",style:{margin:"auto 16px",minWidth:"16px"}}),jsxRuntime.jsx(X_,{headerText:t.downgradeToFree.freePlanHeader({plan:n}),planName:t.downgradeToFree.freePlanName({plan:n}),priceText:t.downgradeToFree.freePlanPriceText({plan:n})})]})]})};var O5=(t,{onBillingAddressChange:e,onChangePlan:n,onBillableFeatureChange:r,onAddonChange:i,collectPhoneNumber:o,onCheckout:s,onCheckoutCompleted:c})=>{switch(t.key){case "PLAN":return {content:jsxRuntime.jsx(Y_,{onChangePlan:n,onBillableFeatureChange:r})};case "ADDONS":return {content:jsxRuntime.jsx(E_,{onAddonChange:i})};case "PAYMENT":return {content:jsxRuntime.jsx(R_,{onBillingAddressChange:e,collectPhoneNumber:o,onCheckout:s,onCheckoutCompleted:c})};default:return {content:null}}};function nT({onCheckout:t,onCheckoutCompleted:e,onChangePlan:n,onBillingAddressChange:r,onBillableFeatureChange:i,onAddonChange:o,collectPhoneNumber:s,disablePromotionCode:c,disableSuccessAnimation:p,onMockCheckoutPreview:h}){let{stripePromise:v,setupIntentClientSecret:P}=jE(),[{stiggTheme:x,widgetState:T,theme:I,showWatermark:F}]=Ye(),{currentStep:A}=ha(),{isLoadingCheckoutData:O}=T,{checkoutState:N,checkoutLocalization:V}=ze(),{plan:G,activeSubscription:X}=N||{},nt=!!G&&G.pricingType===Rn.Free&&!!X&&X.pricingType!==Rn.Free,{content:st}=O5(A,{onBillingAddressChange:r,onChangePlan:n,onBillableFeatureChange:i,onAddonChange:o,collectPhoneNumber:s,onCheckout:t,onCheckoutCompleted:e}),U=jsxRuntime.jsx(jsxRuntime.Fragment,{children:nt?jsxRuntime.jsx(J_,{freePlan:G,activeSubscription:X,allowChangePlan:true,checkoutLocalization:V,onChangePlan:n}):jsxRuntime.jsx(jsxRuntime.Fragment,{children:st})}),j=Uv.useMemo(()=>P?{clientSecret:P}:{mode:"setup",currency:"usd"},[P]);return jsxRuntime.jsx(reactStripeJs.Elements,{stripe:v,options:St(W({},j),{appearance:{theme:"stripe",variables:{colorText:x.palette.text.primary,colorPrimaryText:x.palette.text.primary,colorTextPlaceholder:x.palette.text.disabled,fontFamily:x.typography.fontFamily,colorBackground:I==null?void 0:I.paymentInputBackgroundColor,borderRadius:I==null?void 0:I.paymentInputBorderRadius},rules:I!=null&&I.paymentInputBorderColor?{".Input":{borderColor:I==null?void 0:I.paymentInputBorderColor}}:void 0}}),children:jsxRuntime.jsxs(EE,{className:"stigg-checkout-layout",children:[!nt&&jsxRuntime.jsx(OE,{}),jsxRuntime.jsxs(_E,{children:[jsxRuntime.jsx(TE,{children:O?jsxRuntime.jsx(cS,{}):U}),O?jsxRuntime.jsx(h_,{showWatermark:F}):jsxRuntime.jsx(f_,{disablePromotionCode:c,disableSuccessAnimation:p,onCheckout:t,onCheckoutCompleted:e,isFreeDowngrade:nt,onMockCheckoutPreview:h,showWatermark:F})]})]})},P)}var iT=x=>{var T=x,{textOverrides:t,theme:e,resourceId:n,planId:r,preferredBillingPeriod:i,billingCountryCode:o,billableFeatures:s,billingInformation:c,onMockCheckoutState:p,skipCheckoutSteps:h,onBeforeStepChange:v}=T,P=On(T,["textOverrides","theme","resourceId","planId","preferredBillingPeriod","billingCountryCode","billableFeatures","billingInformation","onMockCheckoutState","skipCheckoutSteps","onBeforeStepChange"]);return jsxRuntime.jsx(PE,{textOverrides:t,theme:e,resourceId:n,planId:r,preferredBillingPeriod:i,billingCountryCode:o,billableFeatures:s,billingInformation:c,onMockCheckoutState:p,skipCheckoutSteps:h,onBeforeStepChange:v,children:jsxRuntime.jsx(nT,W({},P))})};function M5(t){return Uv.useMemo(()=>{let e=new URLSearchParams(window.location.search);return e.get(t)},[t,window.location.search])}var o0=(r=>(r.IN_PROGRESS="IN_PROGRESS",r.SUCCEEDED="SUCCEEDED",r.FAILED="FAILED",r))(o0||{}),aT=({onProvisionStart:t,onProvisionSucceeded:e,onProvisionFailed:n}={})=>{let{stigg:r}=ve(),[i,o]=Uv.useState("IN_PROGRESS"),[s,c]=Uv.useState(false),p=M5("checkoutCompleted");return Uv.useEffect(()=>{ce(null,null,function*(){if(!(!p||p.toLowerCase()==="false"||s)){c(true),t&&t();try{let v=yield r.waitForCheckoutCompleted();o("SUCCEEDED"),e&&e(v);}catch(v){console.error("Failed to wait for checkout to complete",v),o("FAILED"),n&&n(v);}finally{c(false);}}});},[r,p]),{isAwaitingCheckout:s,provisionStatus:i}};function N5(r){var i=r,{noAccessComponent:t,children:e}=i,n=On(i,["noAccessComponent","children"]);let{hasAccess:o}=ig(n);return o?e:jsxRuntime.jsx(jsxRuntime.Fragment,{children:t!=null?t:null})}function U5(r){var i=r,{noAccessComponent:t,children:e}=i,n=On(i,["noAccessComponent","children"]);let{hasAccess:o}=og(n);return o?e:jsxRuntime.jsx(jsxRuntime.Fragment,{children:t!=null?t:null})}function j5(r){var i=r,{noAccessComponent:t,children:e}=i,n=On(i,["noAccessComponent","children"]);let{hasAccess:o}=ag(n);return o?e:jsxRuntime.jsx(jsxRuntime.Fragment,{children:t!=null?t:null})}function H5(r){var i=r,{noAccessComponent:t,children:e}=i,n=On(i,["noAccessComponent","children"]);let{hasAccess:o}=sg(n);return o?e:jsxRuntime.jsx(jsxRuntime.Fragment,{children:t!=null?t:null})}function Ju(t){let e=ve(),n=e==null?void 0:e.stigg,r=e==null?void 0:e.updatedAt,i=Uv.useCallback(()=>ce(null,null,function*(){if(!n||!n.isCustomerLoaded)return null;try{let p={currencyId:t.currencyId},h=yield n.getCreditBalance(p);if(h.balances&&h.balances.length>0){let{currentBalance:v,totalConsumed:P,totalGranted:x,currency:{currencyId:T,displayName:I,units:F,symbol:A}}=h.balances[0];return {currentBalance:v,totalConsumed:P,totalGranted:x,currencyId:T,displayName:I,units:F,symbol:A}}return {currencyId:t.currencyId,currentBalance:0,totalConsumed:0,totalGranted:0}}catch(p){throw console.error(p),p}}),[n,t.currencyId,r]),{data:o,error:s,isLoading:c}=co({func:i});return Uv.useMemo(()=>({balance:o,isLoading:c,error:s}),[o,s,c])}var ll=(t,e)=>t?gr(t,{maximumFractionDigits:e!=null?e:void 0}):0,Pg=(t,e=true,n=false)=>{let{currentBalance:r,displayName:i,units:o,symbol:s}=t,c=n&&s,p=o?r===1?o.singular:o.plural:i;return [c,e?p:""].filter(Boolean).join(" ")},sT=(t,e)=>e===0?0:Math.min(t/e*100,100);var X5=Q.div`
5628
+ `,X_=({headerText:t,planName:e,priceText:n})=>jsxRuntime.jsxs(I5,{className:"stigg-checkout-downgrade-to-free-container",children:[jsxRuntime.jsx(rt,{className:"stigg-checkout-downgrade-to-free-text-header",style:{opacity:.8},variant:"caption",color:"disabled",children:t}),jsxRuntime.jsx(rt,{className:"stigg-checkout-downgrade-to-free-plan-name",bold:true,variant:"h3",color:"primary",children:e}),jsxRuntime.jsx(rt,{className:"stigg-checkout-downgrade-to-free-price-text",color:"secondary",children:n})]}),J_=({checkoutLocalization:t,activeSubscription:e,freePlan:n,allowChangePlan:r=false,onChangePlan:i})=>{let o;r&&i&&(o=jsxRuntime.jsx(Cg,{onClick:()=>{i({currentPlan:n});},checkoutLocalization:t,size:"small"}));let s=e.prices.length>0?e.prices[0].billingPeriod:void 0;return jsxRuntime.jsxs(jsxRuntime.Fragment,{children:[jsxRuntime.jsx(w5,{action:o,className:"stigg-checkout-downgrade-to-free-alert",severity:"info",children:jsxRuntime.jsx(rt,{as:"span",color:"secondary",children:t.downgradeToFree.alertText({plan:e.plan})})}),jsxRuntime.jsxs(T5,{className:"stigg-checkout-downgrade-to-free-plans-container",children:[jsxRuntime.jsx(X_,{headerText:t.downgradeToFree.paidPlanHeader({plan:e.plan}),planName:t.downgradeToFree.paidPlanName({plan:e.plan}),priceText:t.downgradeToFree.paidPlanPriceText({plan:e.plan,billingPeriod:s})}),jsxRuntime.jsx(K_,{className:"stigg-checkout-downgrade-to-free-arrow",style:{margin:"auto 16px",minWidth:"16px"}}),jsxRuntime.jsx(X_,{headerText:t.downgradeToFree.freePlanHeader({plan:n}),planName:t.downgradeToFree.freePlanName({plan:n}),priceText:t.downgradeToFree.freePlanPriceText({plan:n})})]})]})};var O5=(t,{onBillingAddressChange:e,onChangePlan:n,onBillableFeatureChange:r,onAddonChange:i,collectPhoneNumber:o,onCheckout:s,onCheckoutCompleted:c})=>{switch(t.key){case "PLAN":return {content:jsxRuntime.jsx(Y_,{onChangePlan:n,onBillableFeatureChange:r})};case "ADDONS":return {content:jsxRuntime.jsx(E_,{onAddonChange:i})};case "PAYMENT":return {content:jsxRuntime.jsx(R_,{onBillingAddressChange:e,collectPhoneNumber:o,onCheckout:s,onCheckoutCompleted:c})};default:return {content:null}}};function nT({onCheckout:t,onCheckoutCompleted:e,onChangePlan:n,onBillingAddressChange:r,onBillableFeatureChange:i,onAddonChange:o,collectPhoneNumber:s,disablePromotionCode:c,disableSuccessAnimation:p,onMockCheckoutPreview:h}){let{stripePromise:v,setupIntentClientSecret:P}=jE(),[{stiggTheme:x,widgetState:T,theme:I,showWatermark:R}]=Ye(),{currentStep:A}=ha(),{isLoadingCheckoutData:O}=T,{checkoutState:N,checkoutLocalization:V}=ze(),{plan:G,activeSubscription:X}=N||{},nt=!!G&&G.pricingType===Rn.Free&&!!X&&X.pricingType!==Rn.Free,{content:st}=O5(A,{onBillingAddressChange:r,onChangePlan:n,onBillableFeatureChange:i,onAddonChange:o,collectPhoneNumber:s,onCheckout:t,onCheckoutCompleted:e}),U=jsxRuntime.jsx(jsxRuntime.Fragment,{children:nt?jsxRuntime.jsx(J_,{freePlan:G,activeSubscription:X,allowChangePlan:true,checkoutLocalization:V,onChangePlan:n}):jsxRuntime.jsx(jsxRuntime.Fragment,{children:st})}),j=Uv.useMemo(()=>P?{clientSecret:P}:{mode:"setup",currency:"usd"},[P]);return jsxRuntime.jsx(reactStripeJs.Elements,{stripe:v,options:St(W({},j),{appearance:{theme:"stripe",variables:{colorText:x.palette.text.primary,colorPrimaryText:x.palette.text.primary,colorTextPlaceholder:x.palette.text.disabled,fontFamily:x.typography.fontFamily,colorBackground:I==null?void 0:I.paymentInputBackgroundColor,borderRadius:I==null?void 0:I.paymentInputBorderRadius},rules:I!=null&&I.paymentInputBorderColor?{".Input":{borderColor:I==null?void 0:I.paymentInputBorderColor}}:void 0}}),children:jsxRuntime.jsxs(EE,{className:"stigg-checkout-layout",children:[!nt&&jsxRuntime.jsx(OE,{}),jsxRuntime.jsxs(_E,{children:[jsxRuntime.jsx(TE,{children:O?jsxRuntime.jsx(cS,{}):U}),O?jsxRuntime.jsx(h_,{showWatermark:R}):jsxRuntime.jsx(f_,{disablePromotionCode:c,disableSuccessAnimation:p,onCheckout:t,onCheckoutCompleted:e,isFreeDowngrade:nt,onMockCheckoutPreview:h,showWatermark:R})]})]})},P)}var iT=x=>{var T=x,{textOverrides:t,theme:e,resourceId:n,planId:r,preferredBillingPeriod:i,billingCountryCode:o,billableFeatures:s,billingInformation:c,onMockCheckoutState:p,skipCheckoutSteps:h,onBeforeStepChange:v}=T,P=On(T,["textOverrides","theme","resourceId","planId","preferredBillingPeriod","billingCountryCode","billableFeatures","billingInformation","onMockCheckoutState","skipCheckoutSteps","onBeforeStepChange"]);return jsxRuntime.jsx(PE,{textOverrides:t,theme:e,resourceId:n,planId:r,preferredBillingPeriod:i,billingCountryCode:o,billableFeatures:s,billingInformation:c,onMockCheckoutState:p,skipCheckoutSteps:h,onBeforeStepChange:v,children:jsxRuntime.jsx(nT,W({},P))})};function M5(t){return Uv.useMemo(()=>{let e=new URLSearchParams(window.location.search);return e.get(t)},[t,window.location.search])}var o0=(r=>(r.IN_PROGRESS="IN_PROGRESS",r.SUCCEEDED="SUCCEEDED",r.FAILED="FAILED",r))(o0||{}),aT=({onProvisionStart:t,onProvisionSucceeded:e,onProvisionFailed:n}={})=>{let{stigg:r}=ve(),[i,o]=Uv.useState("IN_PROGRESS"),[s,c]=Uv.useState(false),p=M5("checkoutCompleted");return Uv.useEffect(()=>{ce(null,null,function*(){if(!(!p||p.toLowerCase()==="false"||s)){c(true),t&&t();try{let v=yield r.waitForCheckoutCompleted();o("SUCCEEDED"),e&&e(v);}catch(v){console.error("Failed to wait for checkout to complete",v),o("FAILED"),n&&n(v);}finally{c(false);}}});},[r,p]),{isAwaitingCheckout:s,provisionStatus:i}};function N5(r){var i=r,{noAccessComponent:t,children:e}=i,n=On(i,["noAccessComponent","children"]);let{hasAccess:o}=ig(n);return o?e:jsxRuntime.jsx(jsxRuntime.Fragment,{children:t!=null?t:null})}function U5(r){var i=r,{noAccessComponent:t,children:e}=i,n=On(i,["noAccessComponent","children"]);let{hasAccess:o}=og(n);return o?e:jsxRuntime.jsx(jsxRuntime.Fragment,{children:t!=null?t:null})}function j5(r){var i=r,{noAccessComponent:t,children:e}=i,n=On(i,["noAccessComponent","children"]);let{hasAccess:o}=ag(n);return o?e:jsxRuntime.jsx(jsxRuntime.Fragment,{children:t!=null?t:null})}function H5(r){var i=r,{noAccessComponent:t,children:e}=i,n=On(i,["noAccessComponent","children"]);let{hasAccess:o}=sg(n);return o?e:jsxRuntime.jsx(jsxRuntime.Fragment,{children:t!=null?t:null})}function Ju(t){let e=ve(),n=e==null?void 0:e.stigg,r=e==null?void 0:e.updatedAt,i=Uv.useCallback(()=>ce(null,null,function*(){if(!n||!n.isCustomerLoaded)return null;try{let p={currencyId:t.currencyId},h=yield n.getCreditBalance(p);if(h.balances&&h.balances.length>0){let{currentBalance:v,totalConsumed:P,totalGranted:x,currency:{currencyId:T,displayName:I,units:R,symbol:A}}=h.balances[0];return {currentBalance:v,totalConsumed:P,totalGranted:x,currencyId:T,displayName:I,units:R,symbol:A}}return {currencyId:t.currencyId,currentBalance:0,totalConsumed:0,totalGranted:0}}catch(p){throw console.error(p),p}}),[n,t.currencyId,r]),{data:o,error:s,isLoading:c}=co({func:i});return Uv.useMemo(()=>({balance:o,isLoading:c,error:s}),[o,s,c])}var ll=(t,e)=>t?gr(t,{maximumFractionDigits:e!=null?e:void 0}):0,Pg=(t,e=true,n=false)=>{let{currentBalance:r,displayName:i,units:o,symbol:s}=t,c=n&&s,p=o?r===1?o.singular:o.plural:i;return [c,e?p:""].filter(Boolean).join(" ")},sT=(t,e)=>e===0?0:Math.min(t/e*100,100);var X5=Q.div`
5629
5629
  display: flex;
5630
5630
  flex-direction: row;
5631
5631
  gap: 4px;
@@ -5643,10 +5643,10 @@ ${e.o5f}`,e.zBW=r.default`
5643
5643
  border-radius: 8px;
5644
5644
  border: 1px solid ${({theme:t})=>{var e,n;return (n=(e=t.stigg)==null?void 0:e.palette)==null?void 0:n.outlinedBorder}};
5645
5645
  background-color: ${({theme:t})=>{var e,n;return (n=(e=t==null?void 0:t.stigg)==null?void 0:e.palette)==null?void 0:n.backgroundPaper}};
5646
- `;function pT({currencyId:t,localization:e,decimalPlaces:n,showUnits:r=true,showSymbol:i=false}){var v;let o=fc(Mo),s=ve({optional:true}),c=s==null?void 0:s.theme,p=(v=e==null?void 0:e.title)!=null?v:cT.title,h=jsxRuntime.jsx(J5,{className:"stigg-credit-balance-container",children:jsxRuntime.jsxs(tB,{className:"stigg-credit-balance-card",children:[jsxRuntime.jsx(rt,{variant:"h6",color:"primary",className:"stigg-credit-balance-title",children:p}),jsxRuntime.jsx(lT,{currencyId:t,decimalPlaces:n,showUnits:r,showSymbol:i})]})});return o?h:jsxRuntime.jsx(vi,{componentTheme:c,children:h})}function Bo(){}var p0=(function(){let t=0;return function(){return t++}})();function Le(t){return t===null||typeof t=="undefined"}function He(t){if(Array.isArray&&Array.isArray(t))return true;let e=Object.prototype.toString.call(t);return e.slice(0,7)==="[object"&&e.slice(-6)==="Array]"}function Te(t){return t!==null&&Object.prototype.toString.call(t)==="[object Object]"}var Mn=t=>(typeof t=="number"||t instanceof Number)&&isFinite(+t);function xi(t,e){return Mn(t)?t:e}function me(t,e){return typeof t=="undefined"?e:t}var f0=(t,e)=>typeof t=="string"&&t.endsWith("%")?parseFloat(t)/100:t/e,Og=(t,e)=>typeof t=="string"&&t.endsWith("%")?parseFloat(t)/100*e:+t;function Qe(t,e,n){if(t&&typeof t.call=="function")return t.apply(n,e)}function tn(t,e,n,r){let i,o,s;if(He(t))if(o=t.length,r);else for(i=0;i<o;i++)e.call(n,t[i],i);else if(Te(t))for(s=Object.keys(t),o=s.length,i=0;i<o;i++)e.call(n,t[s[i]],s[i]);}function id(t,e){let n,r,i,o;if(!t||!e||t.length!==e.length)return false;for(n=0,r=t.length;n<r;++n)if(i=t[n],o=e[n],i.datasetIndex!==o.datasetIndex||i.index!==o.index)return false;return true}function of(t){if(He(t))return t.map(of);if(Te(t)){let e=Object.create(null),n=Object.keys(t),r=n.length,i=0;for(;i<r;++i)e[n[i]]=of(t[n[i]]);return e}return t}function TT(t){return ["__proto__","prototype","constructor"].indexOf(t)===-1}function wT(t,e,n,r){if(!TT(t))return;let i=e[t],o=n[t];Te(i)&&Te(o)?ji(i,o,r):e[t]=of(o);}function ji(t,e,n){let r=He(e)?e:[e],i=r.length;if(!Te(t))return t;n=n||{};let o=n.merger||wT;for(let s=0;s<i;++s){if(e=r[s],!Te(e))continue;let c=Object.keys(e);for(let p=0,h=c.length;p<h;++p)o(c[p],t,e,n);}return t}function Ec(t,e){return ji(t,e,{merger:IT})}function IT(t,e,n){if(!TT(t))return;let r=e[t],i=n[t];Te(r)&&Te(i)?Ec(r,i):Object.prototype.hasOwnProperty.call(e,t)||(e[t]=of(i));}var fT={"":t=>t,x:t=>t.x,y:t=>t.y};function ya(t,e){return (fT[e]||(fT[e]=nB(e)))(t)}function nB(t){let e=kT(t);return n=>{for(let r of e){if(r==="")break;n=n&&n[r];}return n}}function kT(t){let e=t.split("."),n=[],r="";for(let i of e)r+=i,r.endsWith("\\")?r=r.slice(0,-1)+".":(n.push(r),r="");return n}function sf(t){return t.charAt(0).toUpperCase()+t.slice(1)}var Fn=t=>typeof t!="undefined",Gr=t=>typeof t=="function",Rg=(t,e)=>{if(t.size!==e.size)return false;for(let n of t)if(!e.has(n))return false;return true};function h0(t){return t.type==="mouseup"||t.type==="click"||t.type==="contextmenu"}var Be=Math.PI,rn=2*Be,DT=rn+Be,af=Number.POSITIVE_INFINITY,lf=Be/180,bn=Be/2,mo=Be/4,ed=Be*2/3,Ei=Math.log10,go=Math.sign;function Fg(t){let e=Math.round(t);t=_c(t,e,t/1e3)?e:t;let n=Math.pow(10,Math.floor(Ei(t))),r=t/n;return (r<=1?1:r<=2?2:r<=5?5:10)*n}function m0(t){let e=[],n=Math.sqrt(t),r;for(r=1;r<n;r++)t%r===0&&(e.push(r),e.push(t/r));return n===(n|0)&&e.push(n),e.sort((i,o)=>i-o).pop(),e}function Vi(t){return !isNaN(parseFloat(t))&&isFinite(t)}function _c(t,e,n){return Math.abs(t-e)<n}function g0(t,e){let n=Math.round(t);return n-e<=t&&n+e>=t}function Mg(t,e,n){let r,i,o;for(r=0,i=t.length;r<i;r++)o=t[r][n],isNaN(o)||(e.min=Math.min(e.min,o),e.max=Math.max(e.max,o));}function Qn(t){return t*(Be/180)}function Tc(t){return t*(180/Be)}function Ng(t){if(!Mn(t))return;let e=1,n=0;for(;Math.round(t*e)/e!==t;)e*=10,n++;return n}function Lg(t,e){let n=e.x-t.x,r=e.y-t.y,i=Math.sqrt(n*n+r*r),o=Math.atan2(r,n);return o<-0.5*Be&&(o+=rn),{angle:o,distance:i}}function ns(t,e){return Math.sqrt(Math.pow(e.x-t.x,2)+Math.pow(e.y-t.y,2))}function AT(t,e){return (t-e+DT)%rn-Be}function ai(t){return (t%rn+rn)%rn}function wc(t,e,n,r){let i=ai(t),o=ai(e),s=ai(n),c=ai(o-i),p=ai(s-i),h=ai(i-o),v=ai(i-s);return i===o||i===s||r&&o===s||c>p&&h<v}function Nr(t,e,n){return Math.max(e,Math.min(n,t))}function y0(t){return Nr(t,-32768,32767)}function Uo(t,e,n,r=1e-6){return t>=Math.min(e,n)-r&&t<=Math.max(e,n)+r}function cf(t,e,n){n=n||(s=>t[s]<e);let r=t.length-1,i=0,o;for(;r-i>1;)o=i+r>>1,n(o)?i=o:r=o;return {lo:i,hi:r}}var es=(t,e,n,r)=>cf(t,n,r?i=>t[i][e]<=n:i=>t[i][e]<n),b0=(t,e,n)=>cf(t,n,r=>t[r][e]>=n);function v0(t,e,n){let r=0,i=t.length;for(;r<i&&t[r]<e;)r++;for(;i>r&&t[i-1]>n;)i--;return r>0||i<t.length?t.slice(r,i):t}var OT=["push","pop","shift","splice","unshift"];function C0(t,e){if(t._chartjs){t._chartjs.listeners.push(e);return}Object.defineProperty(t,"_chartjs",{configurable:true,enumerable:false,value:{listeners:[e]}}),OT.forEach(n=>{let r="_onData"+sf(n),i=t[n];Object.defineProperty(t,n,{configurable:true,enumerable:false,value(...o){let s=i.apply(this,o);return t._chartjs.listeners.forEach(c=>{typeof c[r]=="function"&&c[r](...o);}),s}});});}function Bg(t,e){let n=t._chartjs;if(!n)return;let r=n.listeners,i=r.indexOf(e);i!==-1&&r.splice(i,1),!(r.length>0)&&(OT.forEach(o=>{delete t[o];}),delete t._chartjs);}function Ug(t){let e=new Set,n,r;for(n=0,r=t.length;n<r;++n)e.add(t[n]);return e.size===r?t:Array.from(e)}var $g=(function(){return typeof window=="undefined"?function(t){return t()}:window.requestAnimationFrame})();function Gg(t,e,n){let r=n||(s=>Array.prototype.slice.call(s)),i=false,o=[];return function(...s){o=r(s),i||(i=true,$g.call(window,()=>{i=false,t.apply(e,o);}));}}function S0(t,e){let n;return function(...r){return e?(clearTimeout(n),n=setTimeout(t,e,r)):t.apply(this,r),e}}var uf=t=>t==="start"?"left":t==="end"?"right":"center",Lr=(t,e,n)=>t==="start"?e:t==="end"?n:(e+n)/2,P0=(t,e,n,r)=>t===(r?"left":"right")?n:t==="center"?(e+n)/2:e;function jg(t,e,n){let r=e.length,i=0,o=r;if(t._sorted){let{iScale:s,_parsed:c}=t,p=s.axis,{min:h,max:v,minDefined:P,maxDefined:x}=s.getUserBounds();P&&(i=Nr(Math.min(es(c,s.axis,h).lo,n?r:es(e,p,s.getPixelForValue(h)).lo),0,r-1)),x?o=Nr(Math.max(es(c,s.axis,v,true).hi+1,n?0:es(e,p,s.getPixelForValue(v),true).hi+1),i,r)-i:o=r-i;}return {start:i,count:o}}function Vg(t){let{xScale:e,yScale:n,_scaleRanges:r}=t,i={xmin:e.min,xmax:e.max,ymin:n.min,ymax:n.max};if(!r)return t._scaleRanges=i,true;let o=r.xmin!==e.min||r.xmax!==e.max||r.ymin!==n.min||r.ymax!==n.max;return Object.assign(r,i),o}var _g=t=>t===0||t===1,hT=(t,e,n)=>-(Math.pow(2,10*(t-=1))*Math.sin((t-e)*rn/n)),mT=(t,e,n)=>Math.pow(2,-10*t)*Math.sin((t-e)*rn/n)+1,Sc={linear:t=>t,easeInQuad:t=>t*t,easeOutQuad:t=>-t*(t-2),easeInOutQuad:t=>(t/=.5)<1?.5*t*t:-0.5*(--t*(t-2)-1),easeInCubic:t=>t*t*t,easeOutCubic:t=>(t-=1)*t*t+1,easeInOutCubic:t=>(t/=.5)<1?.5*t*t*t:.5*((t-=2)*t*t+2),easeInQuart:t=>t*t*t*t,easeOutQuart:t=>-((t-=1)*t*t*t-1),easeInOutQuart:t=>(t/=.5)<1?.5*t*t*t*t:-0.5*((t-=2)*t*t*t-2),easeInQuint:t=>t*t*t*t*t,easeOutQuint:t=>(t-=1)*t*t*t*t+1,easeInOutQuint:t=>(t/=.5)<1?.5*t*t*t*t*t:.5*((t-=2)*t*t*t*t+2),easeInSine:t=>-Math.cos(t*bn)+1,easeOutSine:t=>Math.sin(t*bn),easeInOutSine:t=>-0.5*(Math.cos(Be*t)-1),easeInExpo:t=>t===0?0:Math.pow(2,10*(t-1)),easeOutExpo:t=>t===1?1:-Math.pow(2,-10*t)+1,easeInOutExpo:t=>_g(t)?t:t<.5?.5*Math.pow(2,10*(t*2-1)):.5*(-Math.pow(2,-10*(t*2-1))+2),easeInCirc:t=>t>=1?t:-(Math.sqrt(1-t*t)-1),easeOutCirc:t=>Math.sqrt(1-(t-=1)*t),easeInOutCirc:t=>(t/=.5)<1?-0.5*(Math.sqrt(1-t*t)-1):.5*(Math.sqrt(1-(t-=2)*t)+1),easeInElastic:t=>_g(t)?t:hT(t,.075,.3),easeOutElastic:t=>_g(t)?t:mT(t,.075,.3),easeInOutElastic(t){return _g(t)?t:t<.5?.5*hT(t*2,.1125,.45):.5+.5*mT(t*2-1,.1125,.45)},easeInBack(t){return t*t*((1.70158+1)*t-1.70158)},easeOutBack(t){return (t-=1)*t*((1.70158+1)*t+1.70158)+1},easeInOutBack(t){let e=1.70158;return (t/=.5)<1?.5*(t*t*(((e*=1.525)+1)*t-e)):.5*((t-=2)*t*(((e*=1.525)+1)*t+e)+2)},easeInBounce:t=>1-Sc.easeOutBounce(1-t),easeOutBounce(t){return t<1/2.75?7.5625*t*t:t<2/2.75?7.5625*(t-=1.5/2.75)*t+.75:t<2.5/2.75?7.5625*(t-=2.25/2.75)*t+.9375:7.5625*(t-=2.625/2.75)*t+.984375},easeInOutBounce:t=>t<.5?Sc.easeInBounce(t*2)*.5:Sc.easeOutBounce(t*2-1)*.5+.5};function df(t){return t+.5|0}var cl=(t,e,n)=>Math.max(Math.min(t,n),e);function nf(t){return cl(df(t*2.55),0,255)}function ul(t){return cl(df(t*255),0,255)}function Ja(t){return cl(df(t/2.55)/100,0,1)}function gT(t){return cl(df(t*100),0,100)}var ho={0:0,1:1,2:2,3:3,4:4,5:5,6:6,7:7,8:8,9:9,A:10,B:11,C:12,D:13,E:14,F:15,a:10,b:11,c:12,d:13,e:14,f:15},c0=[..."0123456789ABCDEF"],rB=t=>c0[t&15],iB=t=>c0[(t&240)>>4]+c0[t&15],Tg=t=>(t&240)>>4===(t&15),oB=t=>Tg(t.r)&&Tg(t.g)&&Tg(t.b)&&Tg(t.a);function aB(t){var e=t.length,n;return t[0]==="#"&&(e===4||e===5?n={r:255&ho[t[1]]*17,g:255&ho[t[2]]*17,b:255&ho[t[3]]*17,a:e===5?ho[t[4]]*17:255}:(e===7||e===9)&&(n={r:ho[t[1]]<<4|ho[t[2]],g:ho[t[3]]<<4|ho[t[4]],b:ho[t[5]]<<4|ho[t[6]],a:e===9?ho[t[7]]<<4|ho[t[8]]:255})),n}var sB=(t,e)=>t<255?e(t):"";function lB(t){var e=oB(t)?rB:iB;return t?"#"+e(t.r)+e(t.g)+e(t.b)+sB(t.a,e):void 0}var cB=/^(hsla?|hwb|hsv)\(\s*([-+.e\d]+)(?:deg)?[\s,]+([-+.e\d]+)%[\s,]+([-+.e\d]+)%(?:[\s,]+([-+.e\d]+)(%)?)?\s*\)$/;function RT(t,e,n){let r=e*Math.min(n,1-n),i=(o,s=(o+t/30)%12)=>n-r*Math.max(Math.min(s-3,9-s,1),-1);return [i(0),i(8),i(4)]}function uB(t,e,n){let r=(i,o=(i+t/60)%6)=>n-n*e*Math.max(Math.min(o,4-o,1),0);return [r(5),r(3),r(1)]}function dB(t,e,n){let r=RT(t,1,.5),i;for(e+n>1&&(i=1/(e+n),e*=i,n*=i),i=0;i<3;i++)r[i]*=1-e-n,r[i]+=e;return r}function pB(t,e,n,r,i){return t===i?(e-n)/r+(e<n?6:0):e===i?(n-t)/r+2:(t-e)/r+4}function x0(t){let n=t.r/255,r=t.g/255,i=t.b/255,o=Math.max(n,r,i),s=Math.min(n,r,i),c=(o+s)/2,p,h,v;return o!==s&&(v=o-s,h=c>.5?v/(2-o-s):v/(o+s),p=pB(n,r,i,v,o),p=p*60+.5),[p|0,h||0,c]}function E0(t,e,n,r){return (Array.isArray(e)?t(e[0],e[1],e[2]):t(e,n,r)).map(ul)}function _0(t,e,n){return E0(RT,t,e,n)}function fB(t,e,n){return E0(dB,t,e,n)}function hB(t,e,n){return E0(uB,t,e,n)}function FT(t){return (t%360+360)%360}function mB(t){let e=cB.exec(t),n=255,r;if(!e)return;e[5]!==r&&(n=e[6]?nf(+e[5]):ul(+e[5]));let i=FT(+e[2]),o=+e[3]/100,s=+e[4]/100;return e[1]==="hwb"?r=fB(i,o,s):e[1]==="hsv"?r=hB(i,o,s):r=_0(i,o,s),{r:r[0],g:r[1],b:r[2],a:n}}function gB(t,e){var n=x0(t);n[0]=FT(n[0]+e),n=_0(n),t.r=n[0],t.g=n[1],t.b=n[2];}function yB(t){if(!t)return;let e=x0(t),n=e[0],r=gT(e[1]),i=gT(e[2]);return t.a<255?`hsla(${n}, ${r}%, ${i}%, ${Ja(t.a)})`:`hsl(${n}, ${r}%, ${i}%)`}var yT={x:"dark",Z:"light",Y:"re",X:"blu",W:"gr",V:"medium",U:"slate",A:"ee",T:"ol",S:"or",B:"ra",C:"lateg",D:"ights",R:"in",Q:"turquois",E:"hi",P:"ro",O:"al",N:"le",M:"de",L:"yello",F:"en",K:"ch",G:"arks",H:"ea",I:"ightg",J:"wh"},bT={OiceXe:"f0f8ff",antiquewEte:"faebd7",aqua:"ffff",aquamarRe:"7fffd4",azuY:"f0ffff",beige:"f5f5dc",bisque:"ffe4c4",black:"0",blanKedOmond:"ffebcd",Xe:"ff",XeviTet:"8a2be2",bPwn:"a52a2a",burlywood:"deb887",caMtXe:"5f9ea0",KartYuse:"7fff00",KocTate:"d2691e",cSO:"ff7f50",cSnflowerXe:"6495ed",cSnsilk:"fff8dc",crimson:"dc143c",cyan:"ffff",xXe:"8b",xcyan:"8b8b",xgTMnPd:"b8860b",xWay:"a9a9a9",xgYF:"6400",xgYy:"a9a9a9",xkhaki:"bdb76b",xmagFta:"8b008b",xTivegYF:"556b2f",xSange:"ff8c00",xScEd:"9932cc",xYd:"8b0000",xsOmon:"e9967a",xsHgYF:"8fbc8f",xUXe:"483d8b",xUWay:"2f4f4f",xUgYy:"2f4f4f",xQe:"ced1",xviTet:"9400d3",dAppRk:"ff1493",dApskyXe:"bfff",dimWay:"696969",dimgYy:"696969",dodgerXe:"1e90ff",fiYbrick:"b22222",flSOwEte:"fffaf0",foYstWAn:"228b22",fuKsia:"ff00ff",gaRsbSo:"dcdcdc",ghostwEte:"f8f8ff",gTd:"ffd700",gTMnPd:"daa520",Way:"808080",gYF:"8000",gYFLw:"adff2f",gYy:"808080",honeyMw:"f0fff0",hotpRk:"ff69b4",RdianYd:"cd5c5c",Rdigo:"4b0082",ivSy:"fffff0",khaki:"f0e68c",lavFMr:"e6e6fa",lavFMrXsh:"fff0f5",lawngYF:"7cfc00",NmoncEffon:"fffacd",ZXe:"add8e6",ZcSO:"f08080",Zcyan:"e0ffff",ZgTMnPdLw:"fafad2",ZWay:"d3d3d3",ZgYF:"90ee90",ZgYy:"d3d3d3",ZpRk:"ffb6c1",ZsOmon:"ffa07a",ZsHgYF:"20b2aa",ZskyXe:"87cefa",ZUWay:"778899",ZUgYy:"778899",ZstAlXe:"b0c4de",ZLw:"ffffe0",lime:"ff00",limegYF:"32cd32",lRF:"faf0e6",magFta:"ff00ff",maPon:"800000",VaquamarRe:"66cdaa",VXe:"cd",VScEd:"ba55d3",VpurpN:"9370db",VsHgYF:"3cb371",VUXe:"7b68ee",VsprRggYF:"fa9a",VQe:"48d1cc",VviTetYd:"c71585",midnightXe:"191970",mRtcYam:"f5fffa",mistyPse:"ffe4e1",moccasR:"ffe4b5",navajowEte:"ffdead",navy:"80",Tdlace:"fdf5e6",Tive:"808000",TivedBb:"6b8e23",Sange:"ffa500",SangeYd:"ff4500",ScEd:"da70d6",pOegTMnPd:"eee8aa",pOegYF:"98fb98",pOeQe:"afeeee",pOeviTetYd:"db7093",papayawEp:"ffefd5",pHKpuff:"ffdab9",peru:"cd853f",pRk:"ffc0cb",plum:"dda0dd",powMrXe:"b0e0e6",purpN:"800080",YbeccapurpN:"663399",Yd:"ff0000",Psybrown:"bc8f8f",PyOXe:"4169e1",saddNbPwn:"8b4513",sOmon:"fa8072",sandybPwn:"f4a460",sHgYF:"2e8b57",sHshell:"fff5ee",siFna:"a0522d",silver:"c0c0c0",skyXe:"87ceeb",UXe:"6a5acd",UWay:"708090",UgYy:"708090",snow:"fffafa",sprRggYF:"ff7f",stAlXe:"4682b4",tan:"d2b48c",teO:"8080",tEstN:"d8bfd8",tomato:"ff6347",Qe:"40e0d0",viTet:"ee82ee",JHt:"f5deb3",wEte:"ffffff",wEtesmoke:"f5f5f5",Lw:"ffff00",LwgYF:"9acd32"};function bB(){let t={},e=Object.keys(bT),n=Object.keys(yT),r,i,o,s,c;for(r=0;r<e.length;r++){for(s=c=e[r],i=0;i<n.length;i++)o=n[i],c=c.replace(o,yT[o]);o=parseInt(bT[s],16),t[c]=[o>>16&255,o>>8&255,o&255];}return t}var wg;function vB(t){wg||(wg=bB(),wg.transparent=[0,0,0,0]);let e=wg[t.toLowerCase()];return e&&{r:e[0],g:e[1],b:e[2],a:e.length===4?e[3]:255}}var CB=/^rgba?\(\s*([-+.\d]+)(%)?[\s,]+([-+.e\d]+)(%)?[\s,]+([-+.e\d]+)(%)?(?:[\s,/]+([-+.e\d]+)(%)?)?\s*\)$/;function SB(t){let e=CB.exec(t),n=255,r,i,o;if(e){if(e[7]!==r){let s=+e[7];n=e[8]?nf(s):cl(s*255,0,255);}return r=+e[1],i=+e[3],o=+e[5],r=255&(e[2]?nf(r):cl(r,0,255)),i=255&(e[4]?nf(i):cl(i,0,255)),o=255&(e[6]?nf(o):cl(o,0,255)),{r,g:i,b:o,a:n}}}function PB(t){return t&&(t.a<255?`rgba(${t.r}, ${t.g}, ${t.b}, ${Ja(t.a)})`:`rgb(${t.r}, ${t.g}, ${t.b})`)}var a0=t=>t<=.0031308?t*12.92:Math.pow(t,1/2.4)*1.055-.055,td=t=>t<=.04045?t/12.92:Math.pow((t+.055)/1.055,2.4);function xB(t,e,n){let r=td(Ja(t.r)),i=td(Ja(t.g)),o=td(Ja(t.b));return {r:ul(a0(r+n*(td(Ja(e.r))-r))),g:ul(a0(i+n*(td(Ja(e.g))-i))),b:ul(a0(o+n*(td(Ja(e.b))-o))),a:t.a+n*(e.a-t.a)}}function Ig(t,e,n){if(t){let r=x0(t);r[e]=Math.max(0,Math.min(r[e]+r[e]*n,e===0?360:1)),r=_0(r),t.r=r[0],t.g=r[1],t.b=r[2];}}function MT(t,e){return t&&Object.assign(e||{},t)}function vT(t){var e={r:0,g:0,b:0,a:255};return Array.isArray(t)?t.length>=3&&(e={r:t[0],g:t[1],b:t[2],a:255},t.length>3&&(e.a=ul(t[3]))):(e=MT(t,{r:0,g:0,b:0,a:1}),e.a=ul(e.a)),e}function EB(t){return t.charAt(0)==="r"?SB(t):mB(t)}var u0=class t{constructor(e){if(e instanceof t)return e;let n=typeof e,r;n==="object"?r=vT(e):n==="string"&&(r=aB(e)||vB(e)||EB(e)),this._rgb=r,this._valid=!!r;}get valid(){return this._valid}get rgb(){var e=MT(this._rgb);return e&&(e.a=Ja(e.a)),e}set rgb(e){this._rgb=vT(e);}rgbString(){return this._valid?PB(this._rgb):void 0}hexString(){return this._valid?lB(this._rgb):void 0}hslString(){return this._valid?yB(this._rgb):void 0}mix(e,n){if(e){let r=this.rgb,i=e.rgb,o,s=n===o?.5:n,c=2*s-1,p=r.a-i.a,h=((c*p===-1?c:(c+p)/(1+c*p))+1)/2;o=1-h,r.r=255&h*r.r+o*i.r+.5,r.g=255&h*r.g+o*i.g+.5,r.b=255&h*r.b+o*i.b+.5,r.a=s*r.a+(1-s)*i.a,this.rgb=r;}return this}interpolate(e,n){return e&&(this._rgb=xB(this._rgb,e._rgb,n)),this}clone(){return new t(this.rgb)}alpha(e){return this._rgb.a=ul(e),this}clearer(e){let n=this._rgb;return n.a*=1-e,this}greyscale(){let e=this._rgb,n=df(e.r*.3+e.g*.59+e.b*.11);return e.r=e.g=e.b=n,this}opaquer(e){let n=this._rgb;return n.a*=1+e,this}negate(){let e=this._rgb;return e.r=255-e.r,e.g=255-e.g,e.b=255-e.b,this}lighten(e){return Ig(this._rgb,2,e),this}darken(e){return Ig(this._rgb,2,-e),this}saturate(e){return Ig(this._rgb,1,e),this}desaturate(e){return Ig(this._rgb,1,-e),this}rotate(e){return gB(this._rgb,e),this}};function NT(t){return new u0(t)}function T0(t){if(t&&typeof t=="object"){let e=t.toString();return e==="[object CanvasPattern]"||e==="[object CanvasGradient]"}return false}function Ic(t){return T0(t)?t:NT(t)}function Dg(t){return T0(t)?t:NT(t).saturate(.5).darken(.1).hexString()}var pl=Object.create(null),zg=Object.create(null);function rf(t,e){if(!e)return t;let n=e.split(".");for(let r=0,i=n.length;r<i;++r){let o=n[r];t=t[o]||(t[o]=Object.create(null));}return t}function s0(t,e,n){return typeof e=="string"?ji(rf(t,e),n):ji(rf(t,""),e)}var d0=class{constructor(e){this.animation=void 0,this.backgroundColor="rgba(0,0,0,0.1)",this.borderColor="rgba(0,0,0,0.1)",this.color="#666",this.datasets={},this.devicePixelRatio=n=>n.chart.platform.getDevicePixelRatio(),this.elements={},this.events=["mousemove","mouseout","click","touchstart","touchmove"],this.font={family:"'Helvetica Neue', 'Helvetica', 'Arial', sans-serif",size:12,style:"normal",lineHeight:1.2,weight:null},this.hover={},this.hoverBackgroundColor=(n,r)=>Dg(r.backgroundColor),this.hoverBorderColor=(n,r)=>Dg(r.borderColor),this.hoverColor=(n,r)=>Dg(r.color),this.indexAxis="x",this.interaction={mode:"nearest",intersect:true,includeInvisible:false},this.maintainAspectRatio=true,this.onHover=null,this.onClick=null,this.parsing=true,this.plugins={},this.responsive=true,this.scale=void 0,this.scales={},this.showLine=true,this.drawActiveElementsOnTop=true,this.describe(e);}set(e,n){return s0(this,e,n)}get(e){return rf(this,e)}describe(e,n){return s0(zg,e,n)}override(e,n){return s0(pl,e,n)}route(e,n,r,i){let o=rf(this,e),s=rf(this,r),c="_"+n;Object.defineProperties(o,{[c]:{value:o[n],writable:true},[n]:{enumerable:true,get(){let p=this[c],h=s[i];return Te(p)?Object.assign({},h,p):me(p,h)},set(p){this[c]=p;}}});}},ke=new d0({_scriptable:t=>!t.startsWith("on"),_indexable:t=>t!=="events",hover:{_fallback:"interaction"},interaction:{_scriptable:false,_indexable:false}});function LT(t){return !t||Le(t.size)||Le(t.family)?null:(t.style?t.style+" ":"")+(t.weight?t.weight+" ":"")+t.size+"px "+t.family}function nd(t,e,n,r,i){let o=e[i];return o||(o=e[i]=t.measureText(i).width,n.push(i)),o>r&&(r=o),r}function w0(t,e,n,r){r=r||{};let i=r.data=r.data||{},o=r.garbageCollect=r.garbageCollect||[];r.font!==e&&(i=r.data={},o=r.garbageCollect=[],r.font=e),t.save(),t.font=e;let s=0,c=n.length,p,h,v,P,x;for(p=0;p<c;p++)if(P=n[p],P!=null&&He(P)!==true)s=nd(t,i,o,s,P);else if(He(P))for(h=0,v=P.length;h<v;h++)x=P[h],x!=null&&!He(x)&&(s=nd(t,i,o,s,x));t.restore();let T=o.length/2;if(T>n.length){for(p=0;p<T;p++)delete i[o[p]];o.splice(0,T);}return s}function rs(t,e,n){let r=t.currentDevicePixelRatio,i=n!==0?Math.max(n/2,.5):0;return Math.round((e-i)*r)/r+i}function Hg(t,e){e=e||t.getContext("2d"),e.save(),e.resetTransform(),e.clearRect(0,0,t.width,t.height),e.restore();}function pf(t,e,n,r){Wg(t,e,n,r,null);}function Wg(t,e,n,r,i){let o,s,c,p,h,v,P=e.pointStyle,x=e.rotation,T=e.radius,I=(x||0)*lf;if(P&&typeof P=="object"&&(o=P.toString(),o==="[object HTMLImageElement]"||o==="[object HTMLCanvasElement]")){t.save(),t.translate(n,r),t.rotate(I),t.drawImage(P,-P.width/2,-P.height/2,P.width,P.height),t.restore();return}if(!(isNaN(T)||T<=0)){switch(t.beginPath(),P){default:i?t.ellipse(n,r,i/2,T,0,0,rn):t.arc(n,r,T,0,rn),t.closePath();break;case "triangle":t.moveTo(n+Math.sin(I)*T,r-Math.cos(I)*T),I+=ed,t.lineTo(n+Math.sin(I)*T,r-Math.cos(I)*T),I+=ed,t.lineTo(n+Math.sin(I)*T,r-Math.cos(I)*T),t.closePath();break;case "rectRounded":h=T*.516,p=T-h,s=Math.cos(I+mo)*p,c=Math.sin(I+mo)*p,t.arc(n-s,r-c,h,I-Be,I-bn),t.arc(n+c,r-s,h,I-bn,I),t.arc(n+s,r+c,h,I,I+bn),t.arc(n-c,r+s,h,I+bn,I+Be),t.closePath();break;case "rect":if(!x){p=Math.SQRT1_2*T,v=i?i/2:p,t.rect(n-v,r-p,2*v,2*p);break}I+=mo;case "rectRot":s=Math.cos(I)*T,c=Math.sin(I)*T,t.moveTo(n-s,r-c),t.lineTo(n+c,r-s),t.lineTo(n+s,r+c),t.lineTo(n-c,r+s),t.closePath();break;case "crossRot":I+=mo;case "cross":s=Math.cos(I)*T,c=Math.sin(I)*T,t.moveTo(n-s,r-c),t.lineTo(n+s,r+c),t.moveTo(n+c,r-s),t.lineTo(n-c,r+s);break;case "star":s=Math.cos(I)*T,c=Math.sin(I)*T,t.moveTo(n-s,r-c),t.lineTo(n+s,r+c),t.moveTo(n+c,r-s),t.lineTo(n-c,r+s),I+=mo,s=Math.cos(I)*T,c=Math.sin(I)*T,t.moveTo(n-s,r-c),t.lineTo(n+s,r+c),t.moveTo(n+c,r-s),t.lineTo(n-c,r+s);break;case "line":s=i?i/2:Math.cos(I)*T,c=Math.sin(I)*T,t.moveTo(n-s,r-c),t.lineTo(n+s,r+c);break;case "dash":t.moveTo(n,r),t.lineTo(n+Math.cos(I)*T,r+Math.sin(I)*T);break}t.fill(),e.borderWidth>0&&t.stroke();}}function xc(t,e,n){return n=n||.5,!e||t&&t.x>e.left-n&&t.x<e.right+n&&t.y>e.top-n&&t.y<e.bottom+n}function fl(t,e){t.save(),t.beginPath(),t.rect(e.left,e.top,e.right-e.left,e.bottom-e.top),t.clip();}function hl(t){t.restore();}function I0(t,e,n,r,i){if(!e)return t.lineTo(n.x,n.y);if(i==="middle"){let o=(e.x+n.x)/2;t.lineTo(o,e.y),t.lineTo(o,n.y);}else i==="after"!=!!r?t.lineTo(e.x,n.y):t.lineTo(n.x,e.y);t.lineTo(n.x,n.y);}function k0(t,e,n,r){if(!e)return t.lineTo(n.x,n.y);t.bezierCurveTo(r?e.cp1x:e.cp2x,r?e.cp1y:e.cp2y,r?n.cp2x:n.cp1x,r?n.cp2y:n.cp1y,n.x,n.y);}function is(t,e,n,r,i,o={}){let s=He(e)?e:[e],c=o.strokeWidth>0&&o.strokeColor!=="",p,h;for(t.save(),t.font=i.string,_B(t,o),p=0;p<s.length;++p)h=s[p],c&&(o.strokeColor&&(t.strokeStyle=o.strokeColor),Le(o.strokeWidth)||(t.lineWidth=o.strokeWidth),t.strokeText(h,n,r,o.maxWidth)),t.fillText(h,n,r,o.maxWidth),TB(t,n,r,h,o),r+=i.lineHeight;t.restore();}function _B(t,e){e.translation&&t.translate(e.translation[0],e.translation[1]),Le(e.rotation)||t.rotate(e.rotation),e.color&&(t.fillStyle=e.color),e.textAlign&&(t.textAlign=e.textAlign),e.textBaseline&&(t.textBaseline=e.textBaseline);}function TB(t,e,n,r,i){if(i.strikethrough||i.underline){let o=t.measureText(r),s=e-o.actualBoundingBoxLeft,c=e+o.actualBoundingBoxRight,p=n-o.actualBoundingBoxAscent,h=n+o.actualBoundingBoxDescent,v=i.strikethrough?(p+h)/2:h;t.strokeStyle=t.fillStyle,t.beginPath(),t.lineWidth=i.decorationWidth||2,t.moveTo(s,v),t.lineTo(c,v),t.stroke();}}function os(t,e){let{x:n,y:r,w:i,h:o,radius:s}=e;t.arc(n+s.topLeft,r+s.topLeft,s.topLeft,-bn,Be,true),t.lineTo(n,r+o-s.bottomLeft),t.arc(n+s.bottomLeft,r+o-s.bottomLeft,s.bottomLeft,Be,bn,true),t.lineTo(n+i-s.bottomRight,r+o),t.arc(n+i-s.bottomRight,r+o-s.bottomRight,s.bottomRight,bn,0,true),t.lineTo(n+i,r+s.topRight),t.arc(n+i-s.topRight,r+s.topRight,s.topRight,0,-bn,true),t.lineTo(n+s.topLeft,r);}var wB=new RegExp(/^(normal|(\d+(?:\.\d+)?)(px|em|%)?)$/),IB=new RegExp(/^(normal|italic|initial|inherit|unset|(oblique( -?[0-9]?[0-9]deg)?))$/);function BT(t,e){let n=(""+t).match(wB);if(!n||n[1]==="normal")return e*1.2;switch(t=+n[2],n[3]){case "px":return t;case "%":t/=100;break}return e*t}var kB=t=>+t||0;function ff(t,e){let n={},r=Te(e),i=r?Object.keys(e):e,o=Te(t)?r?s=>me(t[s],t[e[s]]):s=>t[s]:()=>t;for(let s of i)n[s]=kB(o(s));return n}function qg(t){return ff(t,{top:"y",right:"x",bottom:"y",left:"x"})}function $o(t){return ff(t,["topLeft","topRight","bottomLeft","bottomRight"])}function $n(t){let e=qg(t);return e.width=e.left+e.right,e.height=e.top+e.bottom,e}function Sn(t,e){t=t||{},e=e||ke.font;let n=me(t.size,e.size);typeof n=="string"&&(n=parseInt(n,10));let r=me(t.style,e.style);r&&!(""+r).match(IB)&&(console.warn('Invalid font style specified: "'+r+'"'),r="");let i={family:me(t.family,e.family),lineHeight:BT(me(t.lineHeight,e.lineHeight),n),size:n,style:r,weight:me(t.weight,e.weight),string:""};return i.string=LT(i),i}function In(t,e,n,r){let o,s,c;for(o=0,s=t.length;o<s;++o)if(c=t[o],c!==void 0&&(e!==void 0&&typeof c=="function"&&(c=c(e),false),n!==void 0&&He(c)&&(c=c[n%c.length],false),c!==void 0))return c}function D0(t,e,n){let{min:r,max:i}=t,o=Og(e,(i-r)/2),s=(c,p)=>n&&c===0?0:c+p;return {min:s(r,-Math.abs(o)),max:s(i,o)}}function ba(t,e){return Object.assign(Object.create(t),e)}function hf(t,e=[""],n=t,r,i=()=>t[0]){Fn(r)||(r=GT("_fallback",t));let o={[Symbol.toStringTag]:"Object",_cacheable:true,_scopes:t,_rootScopes:n,_fallback:r,_getTarget:i,override:s=>hf([s,...t],e,n,r)};return new Proxy(o,{deleteProperty(s,c){return delete s[c],delete s._keys,delete t[0][c],true},get(s,c){return UT(s,c,()=>LB(c,e,t,s))},getOwnPropertyDescriptor(s,c){return Reflect.getOwnPropertyDescriptor(s._scopes[0],c)},getPrototypeOf(){return Reflect.getPrototypeOf(t[0])},has(s,c){return ST(s).includes(c)},ownKeys(s){return ST(s)},set(s,c,p){let h=s._storage||(s._storage=i());return s[c]=h[c]=p,delete s._keys,true}})}function dl(t,e,n,r){let i={_cacheable:false,_proxy:t,_context:e,_subProxy:n,_stack:new Set,_descriptors:Yg(t,r),setContext:o=>dl(t,o,n,r),override:o=>dl(t.override(o),e,n,r)};return new Proxy(i,{deleteProperty(o,s){return delete o[s],delete t[s],true},get(o,s,c){return UT(o,s,()=>AB(o,s,c))},getOwnPropertyDescriptor(o,s){return o._descriptors.allKeys?Reflect.has(t,s)?{enumerable:true,configurable:true}:void 0:Reflect.getOwnPropertyDescriptor(t,s)},getPrototypeOf(){return Reflect.getPrototypeOf(t)},has(o,s){return Reflect.has(t,s)},ownKeys(){return Reflect.ownKeys(t)},set(o,s,c){return t[s]=c,delete o[s],true}})}function Yg(t,e={scriptable:true,indexable:true}){let{_scriptable:n=e.scriptable,_indexable:r=e.indexable,_allKeys:i=e.allKeys}=t;return {allKeys:i,scriptable:n,indexable:r,isScriptable:Gr(n)?n:()=>n,isIndexable:Gr(r)?r:()=>r}}var DB=(t,e)=>t?t+sf(e):e,A0=(t,e)=>Te(e)&&t!=="adapters"&&(Object.getPrototypeOf(e)===null||e.constructor===Object);function UT(t,e,n){if(Object.prototype.hasOwnProperty.call(t,e))return t[e];let r=n();return t[e]=r,r}function AB(t,e,n){let{_proxy:r,_context:i,_subProxy:o,_descriptors:s}=t,c=r[e];return Gr(c)&&s.isScriptable(e)&&(c=OB(e,c,t,n)),He(c)&&c.length&&(c=RB(e,c,t,s.isIndexable)),A0(e,c)&&(c=dl(c,i,o&&o[e],s)),c}function OB(t,e,n,r){let{_proxy:i,_context:o,_subProxy:s,_stack:c}=n;if(c.has(t))throw new Error("Recursion detected: "+Array.from(c).join("->")+"->"+t);return c.add(t),e=e(o,s||r),c.delete(t),A0(t,e)&&(e=O0(i._scopes,i,t,e)),e}function RB(t,e,n,r){let{_proxy:i,_context:o,_subProxy:s,_descriptors:c}=n;if(Fn(o.index)&&r(t))e=e[o.index%e.length];else if(Te(e[0])){let p=e,h=i._scopes.filter(v=>v!==p);e=[];for(let v of p){let P=O0(h,i,t,v);e.push(dl(P,o,s&&s[t],c));}}return e}function $T(t,e,n){return Gr(t)?t(e,n):t}var FB=(t,e)=>t===true?e:typeof t=="string"?ya(e,t):void 0;function MB(t,e,n,r,i){for(let o of e){let s=FB(n,o);if(s){t.add(s);let c=$T(s._fallback,n,i);if(Fn(c)&&c!==n&&c!==r)return c}else if(s===false&&Fn(r)&&n!==r)return null}return false}function O0(t,e,n,r){let i=e._rootScopes,o=$T(e._fallback,n,r),s=[...t,...i],c=new Set;c.add(r);let p=CT(c,s,n,o||n,r);return p===null||Fn(o)&&o!==n&&(p=CT(c,s,o,p,r),p===null)?false:hf(Array.from(c),[""],i,o,()=>NB(e,n,r))}function CT(t,e,n,r,i){for(;n;)n=MB(t,e,n,r,i);return n}function NB(t,e,n){let r=t._getTarget();e in r||(r[e]={});let i=r[e];return He(i)&&Te(n)?n:i}function LB(t,e,n,r){let i;for(let o of e)if(i=GT(DB(o,t),n),Fn(i))return A0(t,i)?O0(n,r,t,i):i}function GT(t,e){for(let n of e){if(!n)continue;let r=n[t];if(Fn(r))return r}}function ST(t){let e=t._keys;return e||(e=t._keys=BB(t._scopes)),e}function BB(t){let e=new Set;for(let n of t)for(let r of Object.keys(n).filter(i=>!i.startsWith("_")))e.add(r);return Array.from(e)}function Qg(t,e,n,r){let{iScale:i}=t,{key:o="r"}=this._parsing,s=new Array(r),c,p,h,v;for(c=0,p=r;c<p;++c)h=c+n,v=e[h],s[c]={r:i.parse(ya(v,o),h)};return s}var UB=Number.EPSILON||1e-14,rd=(t,e)=>e<t.length&&!t[e].skip&&t[e],jT=t=>t==="x"?"y":"x";function VT(t,e,n,r){let i=t.skip?e:t,o=e,s=n.skip?e:n,c=ns(o,i),p=ns(s,o),h=c/(c+p),v=p/(c+p);h=isNaN(h)?0:h,v=isNaN(v)?0:v;let P=r*h,x=r*v;return {previous:{x:o.x-P*(s.x-i.x),y:o.y-P*(s.y-i.y)},next:{x:o.x+x*(s.x-i.x),y:o.y+x*(s.y-i.y)}}}function $B(t,e,n){let r=t.length,i,o,s,c,p,h=rd(t,0);for(let v=0;v<r-1;++v)if(p=h,h=rd(t,v+1),!(!p||!h)){if(_c(e[v],0,UB)){n[v]=n[v+1]=0;continue}i=n[v]/e[v],o=n[v+1]/e[v],c=Math.pow(i,2)+Math.pow(o,2),!(c<=9)&&(s=3/Math.sqrt(c),n[v]=i*s*e[v],n[v+1]=o*s*e[v]);}}function GB(t,e,n="x"){let r=jT(n),i=t.length,o,s,c,p=rd(t,0);for(let h=0;h<i;++h){if(s=c,c=p,p=rd(t,h+1),!c)continue;let v=c[n],P=c[r];s&&(o=(v-s[n])/3,c[`cp1${n}`]=v-o,c[`cp1${r}`]=P-o*e[h]),p&&(o=(p[n]-v)/3,c[`cp2${n}`]=v+o,c[`cp2${r}`]=P+o*e[h]);}}function zT(t,e="x"){let n=jT(e),r=t.length,i=Array(r).fill(0),o=Array(r),s,c,p,h=rd(t,0);for(s=0;s<r;++s)if(c=p,p=h,h=rd(t,s+1),!!p){if(h){let v=h[e]-p[e];i[s]=v!==0?(h[n]-p[n])/v:0;}o[s]=c?h?go(i[s-1])!==go(i[s])?0:(i[s-1]+i[s])/2:i[s-1]:i[s];}$B(t,i,o),GB(t,o,e);}function kg(t,e,n){return Math.max(Math.min(t,n),e)}function jB(t,e){let n,r,i,o,s,c=xc(t[0],e);for(n=0,r=t.length;n<r;++n)s=o,o=c,c=n<r-1&&xc(t[n+1],e),o&&(i=t[n],s&&(i.cp1x=kg(i.cp1x,e.left,e.right),i.cp1y=kg(i.cp1y,e.top,e.bottom)),c&&(i.cp2x=kg(i.cp2x,e.left,e.right),i.cp2y=kg(i.cp2y,e.top,e.bottom)));}function R0(t,e,n,r,i){let o,s,c,p;if(e.spanGaps&&(t=t.filter(h=>!h.skip)),e.cubicInterpolationMode==="monotone")zT(t,i);else {let h=r?t[t.length-1]:t[0];for(o=0,s=t.length;o<s;++o)c=t[o],p=VT(h,c,t[Math.min(o+1,s-(r?0:1))%s],e.tension),c.cp1x=p.previous.x,c.cp1y=p.previous.y,c.cp2x=p.next.x,c.cp2y=p.next.y,h=c;}e.capBezierPoints&&jB(t,n);}function Kg(){return typeof window!="undefined"&&typeof document!="undefined"}function mf(t){let e=t.parentNode;return e&&e.toString()==="[object ShadowRoot]"&&(e=e.host),e}function Ag(t,e,n){let r;return typeof t=="string"?(r=parseInt(t,10),t.indexOf("%")!==-1&&(r=r/100*e.parentNode[n])):r=t,r}var Xg=t=>window.getComputedStyle(t,null);function HT(t,e){return Xg(t).getPropertyValue(e)}var VB=["top","right","bottom","left"];function Pc(t,e,n){let r={};n=n?"-"+n:"";for(let i=0;i<4;i++){let o=VB[i];r[o]=parseFloat(t[e+"-"+o+n])||0;}return r.width=r.left+r.right,r.height=r.top+r.bottom,r}var zB=(t,e,n)=>(t>0||e>0)&&(!n||!n.shadowRoot);function HB(t,e){let n=t.touches,r=n&&n.length?n[0]:t,{offsetX:i,offsetY:o}=r,s=false,c,p;if(zB(i,o,t.target))c=i,p=o;else {let h=e.getBoundingClientRect();c=r.clientX-h.left,p=r.clientY-h.top,s=true;}return {x:c,y:p,box:s}}function as(t,e){if("native"in t)return t;let{canvas:n,currentDevicePixelRatio:r}=e,i=Xg(n),o=i.boxSizing==="border-box",s=Pc(i,"padding"),c=Pc(i,"border","width"),{x:p,y:h,box:v}=HB(t,n),P=s.left+(v&&c.left),x=s.top+(v&&c.top),{width:T,height:I}=e;return o&&(T-=s.width+c.width,I-=s.height+c.height),{x:Math.round((p-P)/T*n.width/r),y:Math.round((h-x)/I*n.height/r)}}function WB(t,e,n){let r,i;if(e===void 0||n===void 0){let o=mf(t);if(!o)e=t.clientWidth,n=t.clientHeight;else {let s=o.getBoundingClientRect(),c=Xg(o),p=Pc(c,"border","width"),h=Pc(c,"padding");e=s.width-h.width-p.width,n=s.height-h.height-p.height,r=Ag(c.maxWidth,o,"clientWidth"),i=Ag(c.maxHeight,o,"clientHeight");}}return {width:e,height:n,maxWidth:r||af,maxHeight:i||af}}var l0=t=>Math.round(t*10)/10;function F0(t,e,n,r){let i=Xg(t),o=Pc(i,"margin"),s=Ag(i.maxWidth,t,"clientWidth")||af,c=Ag(i.maxHeight,t,"clientHeight")||af,p=WB(t,e,n),{width:h,height:v}=p;if(i.boxSizing==="content-box"){let P=Pc(i,"border","width"),x=Pc(i,"padding");h-=x.width+P.width,v-=x.height+P.height;}return h=Math.max(0,h-o.width),v=Math.max(0,r?Math.floor(h/r):v-o.height),h=l0(Math.min(h,s,p.maxWidth)),v=l0(Math.min(v,c,p.maxHeight)),h&&!v&&(v=l0(h/2)),{width:h,height:v}}function Zg(t,e,n){let r=e||1,i=Math.floor(t.height*r),o=Math.floor(t.width*r);t.height=i/r,t.width=o/r;let s=t.canvas;return s.style&&(n||!s.style.height&&!s.style.width)&&(s.style.height=`${t.height}px`,s.style.width=`${t.width}px`),t.currentDevicePixelRatio!==r||s.height!==i||s.width!==o?(t.currentDevicePixelRatio=r,s.height=i,s.width=o,t.ctx.setTransform(r,0,0,r,0,0),true):false}var M0=(function(){let t=false;try{let e={get passive(){return t=!0,!1}};window.addEventListener("test",null,e),window.removeEventListener("test",null,e);}catch(e){}return t})();function Jg(t,e){let n=HT(t,e),r=n&&n.match(/^(\d+)(\.\d+)?px$/);return r?+r[1]:void 0}function ts(t,e,n,r){return {x:t.x+n*(e.x-t.x),y:t.y+n*(e.y-t.y)}}function N0(t,e,n,r){return {x:t.x+n*(e.x-t.x),y:r==="middle"?n<.5?t.y:e.y:r==="after"?n<1?t.y:e.y:n>0?e.y:t.y}}function L0(t,e,n,r){let i={x:t.cp2x,y:t.cp2y},o={x:e.cp1x,y:e.cp1y},s=ts(t,i,n),c=ts(i,o,n),p=ts(o,e,n),h=ts(s,c,n),v=ts(c,p,n);return ts(h,v,n)}var PT=new Map;function qB(t,e){e=e||{};let n=t+JSON.stringify(e),r=PT.get(n);return r||(r=new Intl.NumberFormat(t,e),PT.set(n,r)),r}function kc(t,e,n){return qB(e,n).format(t)}var YB=function(t,e){return {x(n){return t+t+e-n},setWidth(n){e=n;},textAlign(n){return n==="center"?n:n==="right"?"left":"right"},xPlus(n,r){return n-r},leftForLtr(n,r){return n-r}}},QB=function(){return {x(t){return t},setWidth(t){},textAlign(t){return t},xPlus(t,e){return t+e},leftForLtr(t,e){return t}}};function ml(t,e,n){return t?YB(e,n):QB()}function ty(t,e){let n,r;(e==="ltr"||e==="rtl")&&(n=t.canvas.style,r=[n.getPropertyValue("direction"),n.getPropertyPriority("direction")],n.setProperty("direction",e,"important"),t.prevTextDirection=r);}function ey(t,e){e!==void 0&&(delete t.prevTextDirection,t.canvas.style.setProperty("direction",e[0],e[1]));}function WT(t){return t==="angle"?{between:wc,compare:AT,normalize:ai}:{between:Uo,compare:(e,n)=>e-n,normalize:e=>e}}function xT({start:t,end:e,count:n,loop:r,style:i}){return {start:t%n,end:e%n,loop:r&&(e-t+1)%n===0,style:i}}function KB(t,e,n){let{property:r,start:i,end:o}=n,{between:s,normalize:c}=WT(r),p=e.length,{start:h,end:v,loop:P}=t,x,T;if(P){for(h+=p,v+=p,x=0,T=p;x<T&&s(c(e[h%p][r]),i,o);++x)h--,v--;h%=p,v%=p;}return v<h&&(v+=p),{start:h,end:v,loop:P,style:t.style}}function ny(t,e,n){if(!n)return [t];let{property:r,start:i,end:o}=n,s=e.length,{compare:c,between:p,normalize:h}=WT(r),{start:v,end:P,loop:x,style:T}=KB(t,e,n),I=[],F=false,A=null,O,N,V,G=()=>p(i,V,O)&&c(i,V)!==0,X=()=>c(o,O)===0||p(o,V,O),nt=()=>F||G(),st=()=>!F||X();for(let U=v,j=v;U<=P;++U)N=e[U%s],!N.skip&&(O=h(N[r]),O!==V&&(F=p(O,i,o),A===null&&nt()&&(A=c(O,i)===0?U:j),A!==null&&st()&&(I.push(xT({start:A,end:U,loop:x,count:s,style:T})),A=null),j=U,V=O));return A!==null&&I.push(xT({start:A,end:P,loop:x,count:s,style:T})),I}function ry(t,e){let n=[],r=t.segments;for(let i=0;i<r.length;i++){let o=ny(r[i],t.points,e);o.length&&n.push(...o);}return n}function XB(t,e,n,r){let i=0,o=e-1;if(n&&!r)for(;i<e&&!t[i].skip;)i++;for(;i<e&&t[i].skip;)i++;for(i%=e,n&&(o+=i);o>i&&t[o%e].skip;)o--;return o%=e,{start:i,end:o}}function ZB(t,e,n,r){let i=t.length,o=[],s=e,c=t[e],p;for(p=e+1;p<=n;++p){let h=t[p%i];h.skip||h.stop?c.skip||(r=false,o.push({start:e%i,end:(p-1)%i,loop:r}),e=s=h.stop?p:null):(s=p,c.skip&&(e=p)),c=h;}return s!==null&&o.push({start:e%i,end:s%i,loop:r}),o}function B0(t,e){let n=t.points,r=t.options.spanGaps,i=n.length;if(!i)return [];let o=!!t._loop,{start:s,end:c}=XB(n,i,o,r);if(r===true)return ET(t,[{start:s,end:c,loop:o}],n,e);let p=c<s?c+i:c,h=!!t._fullLoop&&s===0&&c===i-1;return ET(t,ZB(n,s,p,h),n,e)}function ET(t,e,n,r){return !r||!r.setContext||!n?e:JB(t,e,n,r)}function JB(t,e,n,r){let i=t._chart.getContext(),o=_T(t.options),{_datasetIndex:s,options:{spanGaps:c}}=t,p=n.length,h=[],v=o,P=e[0].start,x=P;function T(I,F,A,O){let N=c?-1:1;if(I!==F){for(I+=p;n[I%p].skip;)I-=N;for(;n[F%p].skip;)F+=N;I%p!==F%p&&(h.push({start:I%p,end:F%p,loop:A,style:O}),v=O,P=F%p);}}for(let I of e){P=c?P:I.start;let F=n[P%p],A;for(x=P+1;x<=I.end;x++){let O=n[x%p];A=_T(r.setContext(ba(i,{type:"segment",p0:F,p1:O,p0DataIndex:(x-1)%p,p1DataIndex:x%p,datasetIndex:s}))),t6(A,v)&&T(P,x-1,I.loop,v),F=O,v=A;}P<x-1&&T(P,x-1,I.loop,v);}return h}function _T(t){return {backgroundColor:t.backgroundColor,borderCapStyle:t.borderCapStyle,borderDash:t.borderDash,borderDashOffset:t.borderDashOffset,borderJoinStyle:t.borderJoinStyle,borderWidth:t.borderWidth,borderColor:t.borderColor}}function t6(t,e){return e&&JSON.stringify(t)!==JSON.stringify(e)}var Y0=class{constructor(){this._request=null,this._charts=new Map,this._running=false,this._lastDate=void 0;}_notify(e,n,r,i){let o=n.listeners[i],s=n.duration;o.forEach(c=>c({chart:e,initial:n.initial,numSteps:s,currentStep:Math.min(r-n.start,s)}));}_refresh(){this._request||(this._running=true,this._request=$g.call(window,()=>{this._update(),this._request=null,this._running&&this._refresh();}));}_update(e=Date.now()){let n=0;this._charts.forEach((r,i)=>{if(!r.running||!r.items.length)return;let o=r.items,s=o.length-1,c=false,p;for(;s>=0;--s)p=o[s],p._active?(p._total>r.duration&&(r.duration=p._total),p.tick(e),c=true):(o[s]=o[o.length-1],o.pop());c&&(i.draw(),this._notify(i,r,e,"progress")),o.length||(r.running=false,this._notify(i,r,e,"complete"),r.initial=false),n+=o.length;}),this._lastDate=e,n===0&&(this._running=false);}_getAnims(e){let n=this._charts,r=n.get(e);return r||(r={running:false,initial:true,items:[],listeners:{complete:[],progress:[]}},n.set(e,r)),r}listen(e,n,r){this._getAnims(e).listeners[n].push(r);}add(e,n){!n||!n.length||this._getAnims(e).items.push(...n);}has(e){return this._getAnims(e).items.length>0}start(e){let n=this._charts.get(e);n&&(n.running=true,n.start=Date.now(),n.duration=n.items.reduce((r,i)=>Math.max(r,i._duration),0),this._refresh());}running(e){if(!this._running)return false;let n=this._charts.get(e);return !(!n||!n.running||!n.items.length)}stop(e){let n=this._charts.get(e);if(!n||!n.items.length)return;let r=n.items,i=r.length-1;for(;i>=0;--i)r[i].cancel();n.items=[],this._notify(e,n,Date.now(),"complete");}remove(e){return this._charts.delete(e)}},ss=new Y0,qT="transparent",e6={boolean(t,e,n){return n>.5?e:t},color(t,e,n){let r=Ic(t||qT),i=r.valid&&Ic(e||qT);return i&&i.valid?i.mix(r,n).hexString():e},number(t,e,n){return t+(e-t)*n}},Q0=class{constructor(e,n,r,i){let o=n[r];i=In([e.to,i,o,e.from]);let s=In([e.from,o,i]);this._active=true,this._fn=e.fn||e6[e.type||typeof s],this._easing=Sc[e.easing]||Sc.linear,this._start=Math.floor(Date.now()+(e.delay||0)),this._duration=this._total=Math.floor(e.duration),this._loop=!!e.loop,this._target=n,this._prop=r,this._from=s,this._to=i,this._promises=void 0;}active(){return this._active}update(e,n,r){if(this._active){this._notify(false);let i=this._target[this._prop],o=r-this._start,s=this._duration-o;this._start=r,this._duration=Math.floor(Math.max(s,e.duration)),this._total+=o,this._loop=!!e.loop,this._to=In([e.to,n,i,e.from]),this._from=In([e.from,i,n]);}}cancel(){this._active&&(this.tick(Date.now()),this._active=false,this._notify(false));}tick(e){let n=e-this._start,r=this._duration,i=this._prop,o=this._from,s=this._loop,c=this._to,p;if(this._active=o!==c&&(s||n<r),!this._active){this._target[i]=c,this._notify(true);return}if(n<0){this._target[i]=o;return}p=n/r%2,p=s&&p>1?2-p:p,p=this._easing(Math.min(1,Math.max(0,p))),this._target[i]=this._fn(o,c,p);}wait(){let e=this._promises||(this._promises=[]);return new Promise((n,r)=>{e.push({res:n,rej:r});})}_notify(e){let n=e?"res":"rej",r=this._promises||[];for(let i=0;i<r.length;i++)r[i][n]();}},n6=["x","y","borderWidth","radius","tension"],r6=["color","borderColor","backgroundColor"];ke.set("animation",{delay:void 0,duration:1e3,easing:"easeOutQuart",fn:void 0,from:void 0,loop:void 0,to:void 0,type:void 0});var i6=Object.keys(ke.animation);ke.describe("animation",{_fallback:false,_indexable:false,_scriptable:t=>t!=="onProgress"&&t!=="onComplete"&&t!=="fn"});ke.set("animations",{colors:{type:"color",properties:r6},numbers:{type:"number",properties:n6}});ke.describe("animations",{_fallback:"animation"});ke.set("transitions",{active:{animation:{duration:400}},resize:{animation:{duration:0}},show:{animations:{colors:{from:"transparent"},visible:{type:"boolean",duration:0}}},hide:{animations:{colors:{to:"transparent"},visible:{type:"boolean",easing:"linear",fn:t=>t|0}}}});var sd=class{constructor(e,n){this._chart=e,this._properties=new Map,this.configure(n);}configure(e){if(!Te(e))return;let n=this._properties;Object.getOwnPropertyNames(e).forEach(r=>{let i=e[r];if(!Te(i))return;let o={};for(let s of i6)o[s]=i[s];(He(i.properties)&&i.properties||[r]).forEach(s=>{(s===r||!n.has(s))&&n.set(s,o);});});}_animateOptions(e,n){let r=n.options,i=a6(e,r);if(!i)return [];let o=this._createAnimations(i,r);return r.$shared&&o6(e.options.$animations,r).then(()=>{e.options=r;},()=>{}),o}_createAnimations(e,n){let r=this._properties,i=[],o=e.$animations||(e.$animations={}),s=Object.keys(n),c=Date.now(),p;for(p=s.length-1;p>=0;--p){let h=s[p];if(h.charAt(0)==="$")continue;if(h==="options"){i.push(...this._animateOptions(e,n));continue}let v=n[h],P=o[h],x=r.get(h);if(P)if(x&&P.active()){P.update(x,v,c);continue}else P.cancel();if(!x||!x.duration){e[h]=v;continue}o[h]=P=new Q0(x,e,h,v),i.push(P);}return i}update(e,n){if(this._properties.size===0){Object.assign(e,n);return}let r=this._createAnimations(e,n);if(r.length)return ss.add(this._chart,r),true}};function o6(t,e){let n=[],r=Object.keys(e);for(let i=0;i<r.length;i++){let o=t[r[i]];o&&o.active()&&n.push(o.wait());}return Promise.all(n)}function a6(t,e){if(!e)return;let n=t.options;if(!n){t.options=e;return}return n.$shared&&(t.options=n=Object.assign({},n,{$shared:false,$animations:{}})),n}function YT(t,e){let n=t&&t.options||{},r=n.reverse,i=n.min===void 0?e:0,o=n.max===void 0?e:0;return {start:r?o:i,end:r?i:o}}function s6(t,e,n){if(n===false)return false;let r=YT(t,n),i=YT(e,n);return {top:i.end,right:r.end,bottom:i.start,left:r.start}}function l6(t){let e,n,r,i;return Te(t)?(e=t.top,n=t.right,r=t.bottom,i=t.left):e=n=r=i=t,{top:e,right:n,bottom:r,left:i,disabled:t===false}}function Lw(t,e){let n=[],r=t._getSortedDatasetMetas(e),i,o;for(i=0,o=r.length;i<o;++i)n.push(r[i].index);return n}function QT(t,e,n,r={}){let i=t.keys,o=r.mode==="single",s,c,p,h;if(e!==null){for(s=0,c=i.length;s<c;++s){if(p=+i[s],p===n){if(r.all)continue;break}h=t.values[p],Mn(h)&&(o||e===0||go(e)===go(h))&&(e+=h);}return e}}function c6(t){let e=Object.keys(t),n=new Array(e.length),r,i,o;for(r=0,i=e.length;r<i;++r)o=e[r],n[r]={x:o,y:t[o]};return n}function KT(t,e){let n=t&&t.options.stacked;return n||n===void 0&&e.stack!==void 0}function u6(t,e,n){return `${t.id}.${e.id}.${n.stack||n.type}`}function d6(t){let{min:e,max:n,minDefined:r,maxDefined:i}=t.getUserBounds();return {min:r?e:Number.NEGATIVE_INFINITY,max:i?n:Number.POSITIVE_INFINITY}}function p6(t,e,n){let r=t[e]||(t[e]={});return r[n]||(r[n]={})}function XT(t,e,n,r){for(let i of e.getMatchingVisibleMetas(r).reverse()){let o=t[i.index];if(n&&o>0||!n&&o<0)return i.index}return null}function ZT(t,e){let{chart:n,_cachedMeta:r}=t,i=n._stacks||(n._stacks={}),{iScale:o,vScale:s,index:c}=r,p=o.axis,h=s.axis,v=u6(o,s,r),P=e.length,x;for(let T=0;T<P;++T){let I=e[T],{[p]:F,[h]:A}=I,O=I._stacks||(I._stacks={});x=O[h]=p6(i,v,F),x[c]=A,x._top=XT(x,s,true,r.type),x._bottom=XT(x,s,false,r.type);}}function U0(t,e){let n=t.scales;return Object.keys(n).filter(r=>n[r].axis===e).shift()}function f6(t,e){return ba(t,{active:false,dataset:void 0,datasetIndex:e,index:e,mode:"default",type:"dataset"})}function h6(t,e,n){return ba(t,{active:false,dataIndex:e,parsed:void 0,raw:void 0,element:n,index:e,mode:"default",type:"data"})}function gf(t,e){let n=t.controller.index,r=t.vScale&&t.vScale.axis;if(r){e=e||t._parsed;for(let i of e){let o=i._stacks;if(!o||o[r]===void 0||o[r][n]===void 0)return;delete o[r][n];}}}var $0=t=>t==="reset"||t==="none",JT=(t,e)=>e?t:Object.assign({},t),m6=(t,e,n)=>t&&!e.hidden&&e._stacked&&{keys:Lw(n,true),values:null},zi=class{constructor(e,n){this.chart=e,this._ctx=e.ctx,this.index=n,this._cachedDataOpts={},this._cachedMeta=this.getMeta(),this._type=this._cachedMeta.type,this.options=void 0,this._parsing=false,this._data=void 0,this._objectData=void 0,this._sharedOptions=void 0,this._drawStart=void 0,this._drawCount=void 0,this.enableOptionSharing=false,this.supportsDecimation=false,this.$context=void 0,this._syncList=[],this.initialize();}initialize(){let e=this._cachedMeta;this.configure(),this.linkScales(),e._stacked=KT(e.vScale,e),this.addElements();}updateIndex(e){this.index!==e&&gf(this._cachedMeta),this.index=e;}linkScales(){let e=this.chart,n=this._cachedMeta,r=this.getDataset(),i=(P,x,T,I)=>P==="x"?x:P==="r"?I:T,o=n.xAxisID=me(r.xAxisID,U0(e,"x")),s=n.yAxisID=me(r.yAxisID,U0(e,"y")),c=n.rAxisID=me(r.rAxisID,U0(e,"r")),p=n.indexAxis,h=n.iAxisID=i(p,o,s,c),v=n.vAxisID=i(p,s,o,c);n.xScale=this.getScaleForId(o),n.yScale=this.getScaleForId(s),n.rScale=this.getScaleForId(c),n.iScale=this.getScaleForId(h),n.vScale=this.getScaleForId(v);}getDataset(){return this.chart.data.datasets[this.index]}getMeta(){return this.chart.getDatasetMeta(this.index)}getScaleForId(e){return this.chart.scales[e]}_getOtherScale(e){let n=this._cachedMeta;return e===n.iScale?n.vScale:n.iScale}reset(){this._update("reset");}_destroy(){let e=this._cachedMeta;this._data&&Bg(this._data,this),e._stacked&&gf(e);}_dataCheck(){let e=this.getDataset(),n=e.data||(e.data=[]),r=this._data;if(Te(n))this._data=c6(n);else if(r!==n){if(r){Bg(r,this);let i=this._cachedMeta;gf(i),i._parsed=[];}n&&Object.isExtensible(n)&&C0(n,this),this._syncList=[],this._data=n;}}addElements(){let e=this._cachedMeta;this._dataCheck(),this.datasetElementType&&(e.dataset=new this.datasetElementType);}buildOrUpdateElements(e){let n=this._cachedMeta,r=this.getDataset(),i=false;this._dataCheck();let o=n._stacked;n._stacked=KT(n.vScale,n),n.stack!==r.stack&&(i=true,gf(n),n.stack=r.stack),this._resyncElements(e),(i||o!==n._stacked)&&ZT(this,n._parsed);}configure(){let e=this.chart.config,n=e.datasetScopeKeys(this._type),r=e.getOptionScopes(this.getDataset(),n,true);this.options=e.createResolver(r,this.getContext()),this._parsing=this.options.parsing,this._cachedDataOpts={};}parse(e,n){let{_cachedMeta:r,_data:i}=this,{iScale:o,_stacked:s}=r,c=o.axis,p=e===0&&n===i.length?true:r._sorted,h=e>0&&r._parsed[e-1],v,P,x;if(this._parsing===false)r._parsed=i,r._sorted=true,x=i;else {He(i[e])?x=this.parseArrayData(r,i,e,n):Te(i[e])?x=this.parseObjectData(r,i,e,n):x=this.parsePrimitiveData(r,i,e,n);let T=()=>P[c]===null||h&&P[c]<h[c];for(v=0;v<n;++v)r._parsed[v+e]=P=x[v],p&&(T()&&(p=false),h=P);r._sorted=p;}s&&ZT(this,x);}parsePrimitiveData(e,n,r,i){let{iScale:o,vScale:s}=e,c=o.axis,p=s.axis,h=o.getLabels(),v=o===s,P=new Array(i),x,T,I;for(x=0,T=i;x<T;++x)I=x+r,P[x]={[c]:v||o.parse(h[I],I),[p]:s.parse(n[I],I)};return P}parseArrayData(e,n,r,i){let{xScale:o,yScale:s}=e,c=new Array(i),p,h,v,P;for(p=0,h=i;p<h;++p)v=p+r,P=n[v],c[p]={x:o.parse(P[0],v),y:s.parse(P[1],v)};return c}parseObjectData(e,n,r,i){let{xScale:o,yScale:s}=e,{xAxisKey:c="x",yAxisKey:p="y"}=this._parsing,h=new Array(i),v,P,x,T;for(v=0,P=i;v<P;++v)x=v+r,T=n[x],h[v]={x:o.parse(ya(T,c),x),y:s.parse(ya(T,p),x)};return h}getParsed(e){return this._cachedMeta._parsed[e]}getDataElement(e){return this._cachedMeta.data[e]}applyStack(e,n,r){let i=this.chart,o=this._cachedMeta,s=n[e.axis],c={keys:Lw(i,true),values:n._stacks[e.axis]};return QT(c,s,o.index,{mode:r})}updateRangeFromParsed(e,n,r,i){let o=r[n.axis],s=o===null?NaN:o,c=i&&r._stacks[n.axis];i&&c&&(i.values=c,s=QT(i,o,this._cachedMeta.index)),e.min=Math.min(e.min,s),e.max=Math.max(e.max,s);}getMinMax(e,n){let r=this._cachedMeta,i=r._parsed,o=r._sorted&&e===r.iScale,s=i.length,c=this._getOtherScale(e),p=m6(n,r,this.chart),h={min:Number.POSITIVE_INFINITY,max:Number.NEGATIVE_INFINITY},{min:v,max:P}=d6(c),x,T;function I(){T=i[x];let F=T[c.axis];return !Mn(T[e.axis])||v>F||P<F}for(x=0;x<s&&!(!I()&&(this.updateRangeFromParsed(h,e,T,p),o));++x);if(o){for(x=s-1;x>=0;--x)if(!I()){this.updateRangeFromParsed(h,e,T,p);break}}return h}getAllParsedValues(e){let n=this._cachedMeta._parsed,r=[],i,o,s;for(i=0,o=n.length;i<o;++i)s=n[i][e.axis],Mn(s)&&r.push(s);return r}getMaxOverflow(){return false}getLabelAndValue(e){let n=this._cachedMeta,r=n.iScale,i=n.vScale,o=this.getParsed(e);return {label:r?""+r.getLabelForValue(o[r.axis]):"",value:i?""+i.getLabelForValue(o[i.axis]):""}}_update(e){let n=this._cachedMeta;this.update(e||"default"),n._clip=l6(me(this.options.clip,s6(n.xScale,n.yScale,this.getMaxOverflow())));}update(e){}draw(){let e=this._ctx,n=this.chart,r=this._cachedMeta,i=r.data||[],o=n.chartArea,s=[],c=this._drawStart||0,p=this._drawCount||i.length-c,h=this.options.drawActiveElementsOnTop,v;for(r.dataset&&r.dataset.draw(e,o,c,p),v=c;v<c+p;++v){let P=i[v];P.hidden||(P.active&&h?s.push(P):P.draw(e,o));}for(v=0;v<s.length;++v)s[v].draw(e,o);}getStyle(e,n){let r=n?"active":"default";return e===void 0&&this._cachedMeta.dataset?this.resolveDatasetElementOptions(r):this.resolveDataElementOptions(e||0,r)}getContext(e,n,r){let i=this.getDataset(),o;if(e>=0&&e<this._cachedMeta.data.length){let s=this._cachedMeta.data[e];o=s.$context||(s.$context=h6(this.getContext(),e,s)),o.parsed=this.getParsed(e),o.raw=i.data[e],o.index=o.dataIndex=e;}else o=this.$context||(this.$context=f6(this.chart.getContext(),this.index)),o.dataset=i,o.index=o.datasetIndex=this.index;return o.active=!!n,o.mode=r,o}resolveDatasetElementOptions(e){return this._resolveElementOptions(this.datasetElementType.id,e)}resolveDataElementOptions(e,n){return this._resolveElementOptions(this.dataElementType.id,n,e)}_resolveElementOptions(e,n="default",r){let i=n==="active",o=this._cachedDataOpts,s=e+"-"+n,c=o[s],p=this.enableOptionSharing&&Fn(r);if(c)return JT(c,p);let h=this.chart.config,v=h.datasetElementScopeKeys(this._type,e),P=i?[`${e}Hover`,"hover",e,""]:[e,""],x=h.getOptionScopes(this.getDataset(),v),T=Object.keys(ke.elements[e]),I=()=>this.getContext(r,i),F=h.resolveNamedOptions(x,T,I,P);return F.$shared&&(F.$shared=p,o[s]=Object.freeze(JT(F,p))),F}_resolveAnimations(e,n,r){let i=this.chart,o=this._cachedDataOpts,s=`animation-${n}`,c=o[s];if(c)return c;let p;if(i.options.animation!==false){let v=this.chart.config,P=v.datasetAnimationScopeKeys(this._type,n),x=v.getOptionScopes(this.getDataset(),P);p=v.createResolver(x,this.getContext(e,r,n));}let h=new sd(i,p&&p.animations);return p&&p._cacheable&&(o[s]=Object.freeze(h)),h}getSharedOptions(e){if(e.$shared)return this._sharedOptions||(this._sharedOptions=Object.assign({},e))}includeOptions(e,n){return !n||$0(e)||this.chart._animationsDisabled}_getSharedOptions(e,n){let r=this.resolveDataElementOptions(e,n),i=this._sharedOptions,o=this.getSharedOptions(r),s=this.includeOptions(n,o)||o!==i;return this.updateSharedOptions(o,n,r),{sharedOptions:o,includeOptions:s}}updateElement(e,n,r,i){$0(i)?Object.assign(e,r):this._resolveAnimations(n,i).update(e,r);}updateSharedOptions(e,n,r){e&&!$0(n)&&this._resolveAnimations(void 0,n).update(e,r);}_setStyle(e,n,r,i){e.active=i;let o=this.getStyle(n,i);this._resolveAnimations(n,r,i).update(e,{options:!i&&this.getSharedOptions(o)||o});}removeHoverStyle(e,n,r){this._setStyle(e,r,"active",false);}setHoverStyle(e,n,r){this._setStyle(e,r,"active",true);}_removeDatasetHoverStyle(){let e=this._cachedMeta.dataset;e&&this._setStyle(e,void 0,"active",false);}_setDatasetHoverStyle(){let e=this._cachedMeta.dataset;e&&this._setStyle(e,void 0,"active",true);}_resyncElements(e){let n=this._data,r=this._cachedMeta.data;for(let[c,p,h]of this._syncList)this[c](p,h);this._syncList=[];let i=r.length,o=n.length,s=Math.min(o,i);s&&this.parse(0,s),o>i?this._insertElements(i,o-i,e):o<i&&this._removeElements(o,i-o);}_insertElements(e,n,r=true){let i=this._cachedMeta,o=i.data,s=e+n,c,p=h=>{for(h.length+=n,c=h.length-1;c>=s;c--)h[c]=h[c-n];};for(p(o),c=e;c<s;++c)o[c]=new this.dataElementType;this._parsing&&p(i._parsed),this.parse(e,n),r&&this.updateElements(o,e,n,"reset");}updateElements(e,n,r,i){}_removeElements(e,n){let r=this._cachedMeta;if(this._parsing){let i=r._parsed.splice(e,n);r._stacked&&gf(r,i);}r.data.splice(e,n);}_sync(e){if(this._parsing)this._syncList.push(e);else {let[n,r,i]=e;this[n](r,i);}this.chart._dataChanges.push([this.index,...e]);}_onDataPush(){let e=arguments.length;this._sync(["_insertElements",this.getDataset().data.length-e,e]);}_onDataPop(){this._sync(["_removeElements",this._cachedMeta.data.length-1,1]);}_onDataShift(){this._sync(["_removeElements",0,1]);}_onDataSplice(e,n){n&&this._sync(["_removeElements",e,n]);let r=arguments.length-2;r&&this._sync(["_insertElements",e,r]);}_onDataUnshift(){this._sync(["_insertElements",0,arguments.length]);}};zi.defaults={};zi.prototype.datasetElementType=null;zi.prototype.dataElementType=null;function g6(t,e){if(!t._cache.$bar){let n=t.getMatchingVisibleMetas(e),r=[];for(let i=0,o=n.length;i<o;i++)r=r.concat(n[i].controller.getAllParsedValues(t));t._cache.$bar=Ug(r.sort((i,o)=>i-o));}return t._cache.$bar}function y6(t){let e=t.iScale,n=g6(e,t.type),r=e._length,i,o,s,c,p=()=>{s===32767||s===-32768||(Fn(c)&&(r=Math.min(r,Math.abs(s-c)||r)),c=s);};for(i=0,o=n.length;i<o;++i)s=e.getPixelForValue(n[i]),p();for(c=void 0,i=0,o=e.ticks.length;i<o;++i)s=e.getPixelForTick(i),p();return r}function b6(t,e,n,r){let i=n.barThickness,o,s;return Le(i)?(o=e.min*n.categoryPercentage,s=n.barPercentage):(o=i*r,s=1),{chunk:o/r,ratio:s,start:e.pixels[t]-o/2}}function v6(t,e,n,r){let i=e.pixels,o=i[t],s=t>0?i[t-1]:null,c=t<i.length-1?i[t+1]:null,p=n.categoryPercentage;s===null&&(s=o-(c===null?e.end-e.start:c-o)),c===null&&(c=o+o-s);let h=o-(o-Math.min(s,c))/2*p;return {chunk:Math.abs(c-s)/2*p/r,ratio:n.barPercentage,start:h}}function C6(t,e,n,r){let i=n.parse(t[0],r),o=n.parse(t[1],r),s=Math.min(i,o),c=Math.max(i,o),p=s,h=c;Math.abs(s)>Math.abs(c)&&(p=c,h=s),e[n.axis]=h,e._custom={barStart:p,barEnd:h,start:i,end:o,min:s,max:c};}function Bw(t,e,n,r){return He(t)?C6(t,e,n,r):e[n.axis]=n.parse(t,r),e}function tw(t,e,n,r){let i=t.iScale,o=t.vScale,s=i.getLabels(),c=i===o,p=[],h,v,P,x;for(h=n,v=n+r;h<v;++h)x=e[h],P={},P[i.axis]=c||i.parse(s[h],h),p.push(Bw(x,P,o,h));return p}function G0(t){return t&&t.barStart!==void 0&&t.barEnd!==void 0}function S6(t,e,n){return t!==0?go(t):(e.isHorizontal()?1:-1)*(e.min>=n?1:-1)}function P6(t){let e,n,r,i,o;return t.horizontal?(e=t.base>t.x,n="left",r="right"):(e=t.base<t.y,n="bottom",r="top"),e?(i="end",o="start"):(i="start",o="end"),{start:n,end:r,reverse:e,top:i,bottom:o}}function x6(t,e,n,r){let i=e.borderSkipped,o={};if(!i){t.borderSkipped=o;return}if(i===true){t.borderSkipped={top:true,right:true,bottom:true,left:true};return}let{start:s,end:c,reverse:p,top:h,bottom:v}=P6(t);i==="middle"&&n&&(t.enableBorderRadius=true,(n._top||0)===r?i=h:(n._bottom||0)===r?i=v:(o[ew(v,s,c,p)]=true,i=h)),o[ew(i,s,c,p)]=true,t.borderSkipped=o;}function ew(t,e,n,r){return r?(t=E6(t,e,n),t=nw(t,n,e)):t=nw(t,e,n),t}function E6(t,e,n){return t===e?n:t===n?e:t}function nw(t,e,n){return t==="start"?e:t==="end"?n:t}function _6(t,{inflateAmount:e},n){t.inflateAmount=e==="auto"?n===1?.33:0:e;}var xf=class extends zi{parsePrimitiveData(e,n,r,i){return tw(e,n,r,i)}parseArrayData(e,n,r,i){return tw(e,n,r,i)}parseObjectData(e,n,r,i){let{iScale:o,vScale:s}=e,{xAxisKey:c="x",yAxisKey:p="y"}=this._parsing,h=o.axis==="x"?c:p,v=s.axis==="x"?c:p,P=[],x,T,I,F;for(x=r,T=r+i;x<T;++x)F=n[x],I={},I[o.axis]=o.parse(ya(F,h),x),P.push(Bw(ya(F,v),I,s,x));return P}updateRangeFromParsed(e,n,r,i){super.updateRangeFromParsed(e,n,r,i);let o=r._custom;o&&n===this._cachedMeta.vScale&&(e.min=Math.min(e.min,o.min),e.max=Math.max(e.max,o.max));}getMaxOverflow(){return 0}getLabelAndValue(e){let n=this._cachedMeta,{iScale:r,vScale:i}=n,o=this.getParsed(e),s=o._custom,c=G0(s)?"["+s.start+", "+s.end+"]":""+i.getLabelForValue(o[i.axis]);return {label:""+r.getLabelForValue(o[r.axis]),value:c}}initialize(){this.enableOptionSharing=true,super.initialize();let e=this._cachedMeta;e.stack=this.getDataset().stack;}update(e){let n=this._cachedMeta;this.updateElements(n.data,0,n.data.length,e);}updateElements(e,n,r,i){let o=i==="reset",{index:s,_cachedMeta:{vScale:c}}=this,p=c.getBasePixel(),h=c.isHorizontal(),v=this._getRuler(),{sharedOptions:P,includeOptions:x}=this._getSharedOptions(n,i);for(let T=n;T<n+r;T++){let I=this.getParsed(T),F=o||Le(I[c.axis])?{base:p,head:p}:this._calculateBarValuePixels(T),A=this._calculateBarIndexPixels(T,v),O=(I._stacks||{})[c.axis],N={horizontal:h,base:F.base,enableBorderRadius:!O||G0(I._custom)||s===O._top||s===O._bottom,x:h?F.head:A.center,y:h?A.center:F.head,height:h?A.size:Math.abs(F.size),width:h?Math.abs(F.size):A.size};x&&(N.options=P||this.resolveDataElementOptions(T,e[T].active?"active":i));let V=N.options||e[T].options;x6(N,V,O,s),_6(N,V,v.ratio),this.updateElement(e[T],T,N,i);}}_getStacks(e,n){let{iScale:r}=this._cachedMeta,i=r.getMatchingVisibleMetas(this._type).filter(p=>p.controller.options.grouped),o=r.options.stacked,s=[],c=p=>{let h=p.controller.getParsed(n),v=h&&h[p.vScale.axis];if(Le(v)||isNaN(v))return true};for(let p of i)if(!(n!==void 0&&c(p))&&((o===false||s.indexOf(p.stack)===-1||o===void 0&&p.stack===void 0)&&s.push(p.stack),p.index===e))break;return s.length||s.push(void 0),s}_getStackCount(e){return this._getStacks(void 0,e).length}_getStackIndex(e,n,r){let i=this._getStacks(e,r),o=n!==void 0?i.indexOf(n):-1;return o===-1?i.length-1:o}_getRuler(){let e=this.options,n=this._cachedMeta,r=n.iScale,i=[],o,s;for(o=0,s=n.data.length;o<s;++o)i.push(r.getPixelForValue(this.getParsed(o)[r.axis],o));let c=e.barThickness;return {min:c||y6(n),pixels:i,start:r._startPixel,end:r._endPixel,stackCount:this._getStackCount(),scale:r,grouped:e.grouped,ratio:c?1:e.categoryPercentage*e.barPercentage}}_calculateBarValuePixels(e){let{_cachedMeta:{vScale:n,_stacked:r},options:{base:i,minBarLength:o}}=this,s=i||0,c=this.getParsed(e),p=c._custom,h=G0(p),v=c[n.axis],P=0,x=r?this.applyStack(n,c,r):v,T,I;x!==v&&(P=x-v,x=v),h&&(v=p.barStart,x=p.barEnd-p.barStart,v!==0&&go(v)!==go(p.barEnd)&&(P=0),P+=v);let F=!Le(i)&&!h?i:P,A=n.getPixelForValue(F);if(this.chart.getDataVisibility(e)?T=n.getPixelForValue(P+x):T=A,I=T-A,Math.abs(I)<o){I=S6(I,n,s)*o,v===s&&(A-=I/2);let O=n.getPixelForDecimal(0),N=n.getPixelForDecimal(1),V=Math.min(O,N),G=Math.max(O,N);A=Math.max(Math.min(A,G),V),T=A+I;}if(A===n.getPixelForValue(s)){let O=go(I)*n.getLineWidthForValue(s)/2;A+=O,I-=O;}return {size:I,base:A,head:T,center:T+I/2}}_calculateBarIndexPixels(e,n){let r=n.scale,i=this.options,o=i.skipNull,s=me(i.maxBarThickness,1/0),c,p;if(n.grouped){let h=o?this._getStackCount(e):n.stackCount,v=i.barThickness==="flex"?v6(e,n,i,h):b6(e,n,i,h),P=this._getStackIndex(this.index,this._cachedMeta.stack,o?e:void 0);c=v.start+v.chunk*P+v.chunk/2,p=Math.min(s,v.chunk*v.ratio);}else c=r.getPixelForValue(this.getParsed(e)[r.axis],e),p=Math.min(s,n.min*n.ratio);return {base:c-p/2,head:c+p/2,center:c,size:p}}draw(){let e=this._cachedMeta,n=e.vScale,r=e.data,i=r.length,o=0;for(;o<i;++o)this.getParsed(o)[n.axis]!==null&&r[o].draw(this._ctx);}};xf.id="bar";xf.defaults={datasetElementType:false,dataElementType:"bar",categoryPercentage:.8,barPercentage:.9,grouped:true,animations:{numbers:{type:"number",properties:["x","y","base","width","height"]}}};xf.overrides={scales:{_index_:{type:"category",offset:true,grid:{offset:true}},_value_:{type:"linear",beginAtZero:true}}};var Ef=class extends zi{initialize(){this.enableOptionSharing=true,super.initialize();}parsePrimitiveData(e,n,r,i){let o=super.parsePrimitiveData(e,n,r,i);for(let s=0;s<o.length;s++)o[s]._custom=this.resolveDataElementOptions(s+r).radius;return o}parseArrayData(e,n,r,i){let o=super.parseArrayData(e,n,r,i);for(let s=0;s<o.length;s++){let c=n[r+s];o[s]._custom=me(c[2],this.resolveDataElementOptions(s+r).radius);}return o}parseObjectData(e,n,r,i){let o=super.parseObjectData(e,n,r,i);for(let s=0;s<o.length;s++){let c=n[r+s];o[s]._custom=me(c&&c.r&&+c.r,this.resolveDataElementOptions(s+r).radius);}return o}getMaxOverflow(){let e=this._cachedMeta.data,n=0;for(let r=e.length-1;r>=0;--r)n=Math.max(n,e[r].size(this.resolveDataElementOptions(r))/2);return n>0&&n}getLabelAndValue(e){let n=this._cachedMeta,{xScale:r,yScale:i}=n,o=this.getParsed(e),s=r.getLabelForValue(o.x),c=i.getLabelForValue(o.y),p=o._custom;return {label:n.label,value:"("+s+", "+c+(p?", "+p:"")+")"}}update(e){let n=this._cachedMeta.data;this.updateElements(n,0,n.length,e);}updateElements(e,n,r,i){let o=i==="reset",{iScale:s,vScale:c}=this._cachedMeta,{sharedOptions:p,includeOptions:h}=this._getSharedOptions(n,i),v=s.axis,P=c.axis;for(let x=n;x<n+r;x++){let T=e[x],I=!o&&this.getParsed(x),F={},A=F[v]=o?s.getPixelForDecimal(.5):s.getPixelForValue(I[v]),O=F[P]=o?c.getBasePixel():c.getPixelForValue(I[P]);F.skip=isNaN(A)||isNaN(O),h&&(F.options=p||this.resolveDataElementOptions(x,T.active?"active":i),o&&(F.options.radius=0)),this.updateElement(T,x,F,i);}}resolveDataElementOptions(e,n){let r=this.getParsed(e),i=super.resolveDataElementOptions(e,n);i.$shared&&(i=Object.assign({},i,{$shared:false}));let o=i.radius;return n!=="active"&&(i.radius=0),i.radius+=me(r&&r._custom,o),i}};Ef.id="bubble";Ef.defaults={datasetElementType:false,dataElementType:"point",animations:{numbers:{type:"number",properties:["x","y","borderWidth","radius"]}}};Ef.overrides={scales:{x:{type:"linear"},y:{type:"linear"}},plugins:{tooltip:{callbacks:{title(){return ""}}}}};function T6(t,e,n){let r=1,i=1,o=0,s=0;if(e<rn){let c=t,p=c+e,h=Math.cos(c),v=Math.sin(c),P=Math.cos(p),x=Math.sin(p),T=(V,G,X)=>wc(V,c,p,true)?1:Math.max(G,G*n,X,X*n),I=(V,G,X)=>wc(V,c,p,true)?-1:Math.min(G,G*n,X,X*n),F=T(0,h,P),A=T(bn,v,x),O=I(Be,h,P),N=I(Be+bn,v,x);r=(F-O)/2,i=(A-N)/2,o=-(F+O)/2,s=-(A+N)/2;}return {ratioX:r,ratioY:i,offsetX:o,offsetY:s}}var Ac=class extends zi{constructor(e,n){super(e,n),this.enableOptionSharing=true,this.innerRadius=void 0,this.outerRadius=void 0,this.offsetX=void 0,this.offsetY=void 0;}linkScales(){}parse(e,n){let r=this.getDataset().data,i=this._cachedMeta;if(this._parsing===false)i._parsed=r;else {let o=p=>+r[p];if(Te(r[e])){let{key:p="value"}=this._parsing;o=h=>+ya(r[h],p);}let s,c;for(s=e,c=e+n;s<c;++s)i._parsed[s]=o(s);}}_getRotation(){return Qn(this.options.rotation-90)}_getCircumference(){return Qn(this.options.circumference)}_getRotationExtents(){let e=rn,n=-rn;for(let r=0;r<this.chart.data.datasets.length;++r)if(this.chart.isDatasetVisible(r)){let i=this.chart.getDatasetMeta(r).controller,o=i._getRotation(),s=i._getCircumference();e=Math.min(e,o),n=Math.max(n,o+s);}return {rotation:e,circumference:n-e}}update(e){let n=this.chart,{chartArea:r}=n,i=this._cachedMeta,o=i.data,s=this.getMaxBorderWidth()+this.getMaxOffset(o)+this.options.spacing,c=Math.max((Math.min(r.width,r.height)-s)/2,0),p=Math.min(f0(this.options.cutout,c),1),h=this._getRingWeight(this.index),{circumference:v,rotation:P}=this._getRotationExtents(),{ratioX:x,ratioY:T,offsetX:I,offsetY:F}=T6(P,v,p),A=(r.width-s)/x,O=(r.height-s)/T,N=Math.max(Math.min(A,O)/2,0),V=Og(this.options.radius,N),G=Math.max(V*p,0),X=(V-G)/this._getVisibleDatasetWeightTotal();this.offsetX=I*V,this.offsetY=F*V,i.total=this.calculateTotal(),this.outerRadius=V-X*this._getRingWeightOffset(this.index),this.innerRadius=Math.max(this.outerRadius-X*h,0),this.updateElements(o,0,o.length,e);}_circumference(e,n){let r=this.options,i=this._cachedMeta,o=this._getCircumference();return n&&r.animation.animateRotate||!this.chart.getDataVisibility(e)||i._parsed[e]===null||i.data[e].hidden?0:this.calculateCircumference(i._parsed[e]*o/rn)}updateElements(e,n,r,i){let o=i==="reset",s=this.chart,c=s.chartArea,h=s.options.animation,v=(c.left+c.right)/2,P=(c.top+c.bottom)/2,x=o&&h.animateScale,T=x?0:this.innerRadius,I=x?0:this.outerRadius,{sharedOptions:F,includeOptions:A}=this._getSharedOptions(n,i),O=this._getRotation(),N;for(N=0;N<n;++N)O+=this._circumference(N,o);for(N=n;N<n+r;++N){let V=this._circumference(N,o),G=e[N],X={x:v+this.offsetX,y:P+this.offsetY,startAngle:O,endAngle:O+V,circumference:V,outerRadius:I,innerRadius:T};A&&(X.options=F||this.resolveDataElementOptions(N,G.active?"active":i)),O+=V,this.updateElement(G,N,X,i);}}calculateTotal(){let e=this._cachedMeta,n=e.data,r=0,i;for(i=0;i<n.length;i++){let o=e._parsed[i];o!==null&&!isNaN(o)&&this.chart.getDataVisibility(i)&&!n[i].hidden&&(r+=Math.abs(o));}return r}calculateCircumference(e){let n=this._cachedMeta.total;return n>0&&!isNaN(e)?rn*(Math.abs(e)/n):0}getLabelAndValue(e){let n=this._cachedMeta,r=this.chart,i=r.data.labels||[],o=kc(n._parsed[e],r.options.locale);return {label:i[e]||"",value:o}}getMaxBorderWidth(e){let n=0,r=this.chart,i,o,s,c,p;if(!e){for(i=0,o=r.data.datasets.length;i<o;++i)if(r.isDatasetVisible(i)){s=r.getDatasetMeta(i),e=s.data,c=s.controller;break}}if(!e)return 0;for(i=0,o=e.length;i<o;++i)p=c.resolveDataElementOptions(i),p.borderAlign!=="inner"&&(n=Math.max(n,p.borderWidth||0,p.hoverBorderWidth||0));return n}getMaxOffset(e){let n=0;for(let r=0,i=e.length;r<i;++r){let o=this.resolveDataElementOptions(r);n=Math.max(n,o.offset||0,o.hoverOffset||0);}return n}_getRingWeightOffset(e){let n=0;for(let r=0;r<e;++r)this.chart.isDatasetVisible(r)&&(n+=this._getRingWeight(r));return n}_getRingWeight(e){return Math.max(me(this.chart.data.datasets[e].weight,1),0)}_getVisibleDatasetWeightTotal(){return this._getRingWeightOffset(this.chart.data.datasets.length)||1}};Ac.id="doughnut";Ac.defaults={datasetElementType:false,dataElementType:"arc",animation:{animateRotate:true,animateScale:false},animations:{numbers:{type:"number",properties:["circumference","endAngle","innerRadius","outerRadius","startAngle","x","y","offset","borderWidth","spacing"]}},cutout:"50%",rotation:0,circumference:360,radius:"100%",spacing:0,indexAxis:"r"};Ac.descriptors={_scriptable:t=>t!=="spacing",_indexable:t=>t!=="spacing"};Ac.overrides={aspectRatio:1,plugins:{legend:{labels:{generateLabels(t){let e=t.data;if(e.labels.length&&e.datasets.length){let{labels:{pointStyle:n}}=t.legend.options;return e.labels.map((r,i)=>{let s=t.getDatasetMeta(0).controller.getStyle(i);return {text:r,fillStyle:s.backgroundColor,strokeStyle:s.borderColor,lineWidth:s.borderWidth,pointStyle:n,hidden:!t.getDataVisibility(i),index:i}})}return []}},onClick(t,e,n){n.chart.toggleDataVisibility(e.index),n.chart.update();}},tooltip:{callbacks:{title(){return ""},label(t){let e=t.label,n=": "+t.formattedValue;return He(e)?(e=e.slice(),e[0]+=n):e+=n,e}}}}};var _f=class extends zi{initialize(){this.enableOptionSharing=true,this.supportsDecimation=true,super.initialize();}update(e){let n=this._cachedMeta,{dataset:r,data:i=[],_dataset:o}=n,s=this.chart._animationsDisabled,{start:c,count:p}=jg(n,i,s);this._drawStart=c,this._drawCount=p,Vg(n)&&(c=0,p=i.length),r._chart=this.chart,r._datasetIndex=this.index,r._decimated=!!o._decimated,r.points=i;let h=this.resolveDatasetElementOptions(e);this.options.showLine||(h.borderWidth=0),h.segment=this.options.segment,this.updateElement(r,void 0,{animated:!s,options:h},e),this.updateElements(i,c,p,e);}updateElements(e,n,r,i){let o=i==="reset",{iScale:s,vScale:c,_stacked:p,_dataset:h}=this._cachedMeta,{sharedOptions:v,includeOptions:P}=this._getSharedOptions(n,i),x=s.axis,T=c.axis,{spanGaps:I,segment:F}=this.options,A=Vi(I)?I:Number.POSITIVE_INFINITY,O=this.chart._animationsDisabled||o||i==="none",N=n>0&&this.getParsed(n-1);for(let V=n;V<n+r;++V){let G=e[V],X=this.getParsed(V),nt=O?G:{},st=Le(X[T]),U=nt[x]=s.getPixelForValue(X[x],V),j=nt[T]=o||st?c.getBasePixel():c.getPixelForValue(p?this.applyStack(c,X,p):X[T],V);nt.skip=isNaN(U)||isNaN(j)||st,nt.stop=V>0&&Math.abs(X[x]-N[x])>A,F&&(nt.parsed=X,nt.raw=h.data[V]),P&&(nt.options=v||this.resolveDataElementOptions(V,G.active?"active":i)),O||this.updateElement(G,V,nt,i),N=X;}}getMaxOverflow(){let e=this._cachedMeta,n=e.dataset,r=n.options&&n.options.borderWidth||0,i=e.data||[];if(!i.length)return r;let o=i[0].size(this.resolveDataElementOptions(0)),s=i[i.length-1].size(this.resolveDataElementOptions(i.length-1));return Math.max(r,o,s)/2}draw(){let e=this._cachedMeta;e.dataset.updateControlPoints(this.chart.chartArea,e.iScale.axis),super.draw();}};_f.id="line";_f.defaults={datasetElementType:"line",dataElementType:"point",showLine:true,spanGaps:false};_f.overrides={scales:{_index_:{type:"category"},_value_:{type:"linear"}}};var Tf=class extends zi{constructor(e,n){super(e,n),this.innerRadius=void 0,this.outerRadius=void 0;}getLabelAndValue(e){let n=this._cachedMeta,r=this.chart,i=r.data.labels||[],o=kc(n._parsed[e].r,r.options.locale);return {label:i[e]||"",value:o}}parseObjectData(e,n,r,i){return Qg.bind(this)(e,n,r,i)}update(e){let n=this._cachedMeta.data;this._updateRadius(),this.updateElements(n,0,n.length,e);}getMinMax(){let e=this._cachedMeta,n={min:Number.POSITIVE_INFINITY,max:Number.NEGATIVE_INFINITY};return e.data.forEach((r,i)=>{let o=this.getParsed(i).r;!isNaN(o)&&this.chart.getDataVisibility(i)&&(o<n.min&&(n.min=o),o>n.max&&(n.max=o));}),n}_updateRadius(){let e=this.chart,n=e.chartArea,r=e.options,i=Math.min(n.right-n.left,n.bottom-n.top),o=Math.max(i/2,0),s=Math.max(r.cutoutPercentage?o/100*r.cutoutPercentage:1,0),c=(o-s)/e.getVisibleDatasetCount();this.outerRadius=o-c*this.index,this.innerRadius=this.outerRadius-c;}updateElements(e,n,r,i){let o=i==="reset",s=this.chart,p=s.options.animation,h=this._cachedMeta.rScale,v=h.xCenter,P=h.yCenter,x=h.getIndexAngle(0)-.5*Be,T=x,I,F=360/this.countVisibleElements();for(I=0;I<n;++I)T+=this._computeAngle(I,i,F);for(I=n;I<n+r;I++){let A=e[I],O=T,N=T+this._computeAngle(I,i,F),V=s.getDataVisibility(I)?h.getDistanceFromCenterForValue(this.getParsed(I).r):0;T=N,o&&(p.animateScale&&(V=0),p.animateRotate&&(O=N=x));let G={x:v,y:P,innerRadius:0,outerRadius:V,startAngle:O,endAngle:N,options:this.resolveDataElementOptions(I,A.active?"active":i)};this.updateElement(A,I,G,i);}}countVisibleElements(){let e=this._cachedMeta,n=0;return e.data.forEach((r,i)=>{!isNaN(this.getParsed(i).r)&&this.chart.getDataVisibility(i)&&n++;}),n}_computeAngle(e,n,r){return this.chart.getDataVisibility(e)?Qn(this.resolveDataElementOptions(e,n).angle||r):0}};Tf.id="polarArea";Tf.defaults={dataElementType:"arc",animation:{animateRotate:true,animateScale:true},animations:{numbers:{type:"number",properties:["x","y","startAngle","endAngle","innerRadius","outerRadius"]}},indexAxis:"r",startAngle:0};Tf.overrides={aspectRatio:1,plugins:{legend:{labels:{generateLabels(t){let e=t.data;if(e.labels.length&&e.datasets.length){let{labels:{pointStyle:n}}=t.legend.options;return e.labels.map((r,i)=>{let s=t.getDatasetMeta(0).controller.getStyle(i);return {text:r,fillStyle:s.backgroundColor,strokeStyle:s.borderColor,lineWidth:s.borderWidth,pointStyle:n,hidden:!t.getDataVisibility(i),index:i}})}return []}},onClick(t,e,n){n.chart.toggleDataVisibility(e.index),n.chart.update();}},tooltip:{callbacks:{title(){return ""},label(t){return t.chart.data.labels[t.dataIndex]+": "+t.formattedValue}}}},scales:{r:{type:"radialLinear",angleLines:{display:false},beginAtZero:true,grid:{circular:true},pointLabels:{display:false},startAngle:0}}};var uy=class extends Ac{};uy.id="pie";uy.defaults={cutout:0,rotation:0,circumference:360,radius:"100%"};var wf=class extends zi{getLabelAndValue(e){let n=this._cachedMeta.vScale,r=this.getParsed(e);return {label:n.getLabels()[e],value:""+n.getLabelForValue(r[n.axis])}}parseObjectData(e,n,r,i){return Qg.bind(this)(e,n,r,i)}update(e){let n=this._cachedMeta,r=n.dataset,i=n.data||[],o=n.iScale.getLabels();if(r.points=i,e!=="resize"){let s=this.resolveDatasetElementOptions(e);this.options.showLine||(s.borderWidth=0);let c={_loop:true,_fullLoop:o.length===i.length,options:s};this.updateElement(r,void 0,c,e);}this.updateElements(i,0,i.length,e);}updateElements(e,n,r,i){let o=this._cachedMeta.rScale,s=i==="reset";for(let c=n;c<n+r;c++){let p=e[c],h=this.resolveDataElementOptions(c,p.active?"active":i),v=o.getPointPositionForValue(c,this.getParsed(c).r),P=s?o.xCenter:v.x,x=s?o.yCenter:v.y,T={x:P,y:x,angle:v.angle,skip:isNaN(P)||isNaN(x),options:h};this.updateElement(p,c,T,i);}}};wf.id="radar";wf.defaults={datasetElementType:"line",dataElementType:"point",indexAxis:"r",showLine:true,elements:{line:{fill:"start"}}};wf.overrides={aspectRatio:1,scales:{r:{type:"radialLinear"}}};var br=class{constructor(){this.x=void 0,this.y=void 0,this.active=false,this.options=void 0,this.$animations=void 0;}tooltipPosition(e){let{x:n,y:r}=this.getProps(["x","y"],e);return {x:n,y:r}}hasValue(){return Vi(this.x)&&Vi(this.y)}getProps(e,n){let r=this.$animations;if(!n||!r)return this;let i={};return e.forEach(o=>{i[o]=r[o]&&r[o].active()?r[o]._to:this[o];}),i}};br.defaults={};br.defaultRoutes=void 0;var Uw={values(t){return He(t)?t:""+t},numeric(t,e,n){if(t===0)return "0";let r=this.chart.options.locale,i,o=t;if(n.length>1){let h=Math.max(Math.abs(n[0].value),Math.abs(n[n.length-1].value));(h<1e-4||h>1e15)&&(i="scientific"),o=w6(t,n);}let s=Ei(Math.abs(o)),c=Math.max(Math.min(-1*Math.floor(s),20),0),p={notation:i,minimumFractionDigits:c,maximumFractionDigits:c};return Object.assign(p,this.options.ticks.format),kc(t,r,p)},logarithmic(t,e,n){if(t===0)return "0";let r=t/Math.pow(10,Math.floor(Ei(t)));return r===1||r===2||r===5?Uw.numeric.call(this,t,e,n):""}};function w6(t,e){let n=e.length>3?e[2].value-e[1].value:e[1].value-e[0].value;return Math.abs(n)>=1&&t!==Math.floor(t)&&(n=t-Math.floor(t)),n}var vy={formatters:Uw};ke.set("scale",{display:true,offset:false,reverse:false,beginAtZero:false,bounds:"ticks",grace:0,grid:{display:true,lineWidth:1,drawBorder:true,drawOnChartArea:true,drawTicks:true,tickLength:8,tickWidth:(t,e)=>e.lineWidth,tickColor:(t,e)=>e.color,offset:false,borderDash:[],borderDashOffset:0,borderWidth:1},title:{display:false,text:"",padding:{top:4,bottom:4}},ticks:{minRotation:0,maxRotation:50,mirror:false,textStrokeWidth:0,textStrokeColor:"",padding:3,display:true,autoSkip:true,autoSkipPadding:3,labelOffset:0,callback:vy.formatters.values,minor:{},major:{},align:"center",crossAlign:"near",showLabelBackdrop:false,backdropColor:"rgba(255, 255, 255, 0.75)",backdropPadding:2}});ke.route("scale.ticks","color","","color");ke.route("scale.grid","color","","borderColor");ke.route("scale.grid","borderColor","","borderColor");ke.route("scale.title","color","","color");ke.describe("scale",{_fallback:false,_scriptable:t=>!t.startsWith("before")&&!t.startsWith("after")&&t!=="callback"&&t!=="parser",_indexable:t=>t!=="borderDash"&&t!=="tickBorderDash"});ke.describe("scales",{_fallback:"scale"});ke.describe("scale.ticks",{_scriptable:t=>t!=="backdropPadding"&&t!=="callback",_indexable:t=>t!=="backdropPadding"});function I6(t,e){let n=t.options.ticks,r=n.maxTicksLimit||k6(t),i=n.major.enabled?A6(e):[],o=i.length,s=i[0],c=i[o-1],p=[];if(o>r)return O6(e,p,i,o/r),p;let h=D6(i,e,r);if(o>0){let v,P,x=o>1?Math.round((c-s)/(o-1)):null;for(iy(e,p,h,Le(x)?0:s-x,s),v=0,P=o-1;v<P;v++)iy(e,p,h,i[v],i[v+1]);return iy(e,p,h,c,Le(x)?e.length:c+x),p}return iy(e,p,h),p}function k6(t){let e=t.options.offset,n=t._tickSize(),r=t._length/n+(e?0:1),i=t._maxLength/n;return Math.floor(Math.min(r,i))}function D6(t,e,n){let r=R6(t),i=e.length/n;if(!r)return Math.max(i,1);let o=m0(r);for(let s=0,c=o.length-1;s<c;s++){let p=o[s];if(p>i)return p}return Math.max(i,1)}function A6(t){let e=[],n,r;for(n=0,r=t.length;n<r;n++)t[n].major&&e.push(n);return e}function O6(t,e,n,r){let i=0,o=n[0],s;for(r=Math.ceil(r),s=0;s<t.length;s++)s===o&&(e.push(t[s]),i++,o=n[i*r]);}function iy(t,e,n,r,i){let o=me(r,0),s=Math.min(me(i,t.length),t.length),c=0,p,h,v;for(n=Math.ceil(n),i&&(p=i-r,n=p/Math.floor(p/n)),v=o;v<0;)c++,v=Math.round(o+c*n);for(h=Math.max(o,0);h<s;h++)h===v&&(e.push(t[h]),c++,v=Math.round(o+c*n));}function R6(t){let e=t.length,n,r;if(e<2)return false;for(r=t[0],n=1;n<e;++n)if(t[n]-t[n-1]!==r)return false;return r}var F6=t=>t==="left"?"right":t==="right"?"left":t,rw=(t,e,n)=>e==="top"||e==="left"?t[e]+n:t[e]-n;function iw(t,e){let n=[],r=t.length/e,i=t.length,o=0;for(;o<i;o+=r)n.push(t[Math.floor(o)]);return n}function M6(t,e,n){let r=t.ticks.length,i=Math.min(e,r-1),o=t._startPixel,s=t._endPixel,c=1e-6,p=t.getPixelForTick(i),h;if(!(n&&(r===1?h=Math.max(p-o,s-p):e===0?h=(t.getPixelForTick(1)-p)/2:h=(p-t.getPixelForTick(i-1))/2,p+=i<e?h:-h,p<o-c||p>s+c)))return p}function N6(t,e){tn(t,n=>{let r=n.gc,i=r.length/2,o;if(i>e){for(o=0;o<i;++o)delete n.data[r[o]];r.splice(0,i);}});}function yf(t){return t.drawTicks?t.tickLength:0}function ow(t,e){if(!t.display)return 0;let n=Sn(t.font,e),r=$n(t.padding);return (He(t.text)?t.text.length:1)*n.lineHeight+r.height}function L6(t,e){return ba(t,{scale:e,type:"scale"})}function B6(t,e,n){return ba(t,{tick:n,index:e,type:"tick"})}function U6(t,e,n){let r=uf(t);return (n&&e!=="right"||!n&&e==="right")&&(r=F6(r)),r}function $6(t,e,n,r){let{top:i,left:o,bottom:s,right:c,chart:p}=t,{chartArea:h,scales:v}=p,P=0,x,T,I,F=s-i,A=c-o;if(t.isHorizontal()){if(T=Lr(r,o,c),Te(n)){let O=Object.keys(n)[0],N=n[O];I=v[O].getPixelForValue(N)+F-e;}else n==="center"?I=(h.bottom+h.top)/2+F-e:I=rw(t,n,e);x=c-o;}else {if(Te(n)){let O=Object.keys(n)[0],N=n[O];T=v[O].getPixelForValue(N)-A+e;}else n==="center"?T=(h.left+h.right)/2-A+e:T=rw(t,n,e);I=Lr(r,s,i),P=n==="left"?-bn:bn;}return {titleX:T,titleY:I,maxWidth:x,rotation:P}}var Oc=class t extends br{constructor(e){super(),this.id=e.id,this.type=e.type,this.options=void 0,this.ctx=e.ctx,this.chart=e.chart,this.top=void 0,this.bottom=void 0,this.left=void 0,this.right=void 0,this.width=void 0,this.height=void 0,this._margins={left:0,right:0,top:0,bottom:0},this.maxWidth=void 0,this.maxHeight=void 0,this.paddingTop=void 0,this.paddingBottom=void 0,this.paddingLeft=void 0,this.paddingRight=void 0,this.axis=void 0,this.labelRotation=void 0,this.min=void 0,this.max=void 0,this._range=void 0,this.ticks=[],this._gridLineItems=null,this._labelItems=null,this._labelSizes=null,this._length=0,this._maxLength=0,this._longestTextCache={},this._startPixel=void 0,this._endPixel=void 0,this._reversePixels=false,this._userMax=void 0,this._userMin=void 0,this._suggestedMax=void 0,this._suggestedMin=void 0,this._ticksLength=0,this._borderValue=0,this._cache={},this._dataLimitsCached=false,this.$context=void 0;}init(e){this.options=e.setContext(this.getContext()),this.axis=e.axis,this._userMin=this.parse(e.min),this._userMax=this.parse(e.max),this._suggestedMin=this.parse(e.suggestedMin),this._suggestedMax=this.parse(e.suggestedMax);}parse(e,n){return e}getUserBounds(){let{_userMin:e,_userMax:n,_suggestedMin:r,_suggestedMax:i}=this;return e=xi(e,Number.POSITIVE_INFINITY),n=xi(n,Number.NEGATIVE_INFINITY),r=xi(r,Number.POSITIVE_INFINITY),i=xi(i,Number.NEGATIVE_INFINITY),{min:xi(e,r),max:xi(n,i),minDefined:Mn(e),maxDefined:Mn(n)}}getMinMax(e){let{min:n,max:r,minDefined:i,maxDefined:o}=this.getUserBounds(),s;if(i&&o)return {min:n,max:r};let c=this.getMatchingVisibleMetas();for(let p=0,h=c.length;p<h;++p)s=c[p].controller.getMinMax(this,e),i||(n=Math.min(n,s.min)),o||(r=Math.max(r,s.max));return n=o&&n>r?r:n,r=i&&n>r?n:r,{min:xi(n,xi(r,n)),max:xi(r,xi(n,r))}}getPadding(){return {left:this.paddingLeft||0,top:this.paddingTop||0,right:this.paddingRight||0,bottom:this.paddingBottom||0}}getTicks(){return this.ticks}getLabels(){let e=this.chart.data;return this.options.labels||(this.isHorizontal()?e.xLabels:e.yLabels)||e.labels||[]}beforeLayout(){this._cache={},this._dataLimitsCached=false;}beforeUpdate(){Qe(this.options.beforeUpdate,[this]);}update(e,n,r){let{beginAtZero:i,grace:o,ticks:s}=this.options,c=s.sampleSize;this.beforeUpdate(),this.maxWidth=e,this.maxHeight=n,this._margins=r=Object.assign({left:0,right:0,top:0,bottom:0},r),this.ticks=null,this._labelSizes=null,this._gridLineItems=null,this._labelItems=null,this.beforeSetDimensions(),this.setDimensions(),this.afterSetDimensions(),this._maxLength=this.isHorizontal()?this.width+r.left+r.right:this.height+r.top+r.bottom,this._dataLimitsCached||(this.beforeDataLimits(),this.determineDataLimits(),this.afterDataLimits(),this._range=D0(this,o,i),this._dataLimitsCached=true),this.beforeBuildTicks(),this.ticks=this.buildTicks()||[],this.afterBuildTicks();let p=c<this.ticks.length;this._convertTicksToLabels(p?iw(this.ticks,c):this.ticks),this.configure(),this.beforeCalculateLabelRotation(),this.calculateLabelRotation(),this.afterCalculateLabelRotation(),s.display&&(s.autoSkip||s.source==="auto")&&(this.ticks=I6(this,this.ticks),this._labelSizes=null,this.afterAutoSkip()),p&&this._convertTicksToLabels(this.ticks),this.beforeFit(),this.fit(),this.afterFit(),this.afterUpdate();}configure(){let e=this.options.reverse,n,r;this.isHorizontal()?(n=this.left,r=this.right):(n=this.top,r=this.bottom,e=!e),this._startPixel=n,this._endPixel=r,this._reversePixels=e,this._length=r-n,this._alignToPixels=this.options.alignToPixels;}afterUpdate(){Qe(this.options.afterUpdate,[this]);}beforeSetDimensions(){Qe(this.options.beforeSetDimensions,[this]);}setDimensions(){this.isHorizontal()?(this.width=this.maxWidth,this.left=0,this.right=this.width):(this.height=this.maxHeight,this.top=0,this.bottom=this.height),this.paddingLeft=0,this.paddingTop=0,this.paddingRight=0,this.paddingBottom=0;}afterSetDimensions(){Qe(this.options.afterSetDimensions,[this]);}_callHooks(e){this.chart.notifyPlugins(e,this.getContext()),Qe(this.options[e],[this]);}beforeDataLimits(){this._callHooks("beforeDataLimits");}determineDataLimits(){}afterDataLimits(){this._callHooks("afterDataLimits");}beforeBuildTicks(){this._callHooks("beforeBuildTicks");}buildTicks(){return []}afterBuildTicks(){this._callHooks("afterBuildTicks");}beforeTickToLabelConversion(){Qe(this.options.beforeTickToLabelConversion,[this]);}generateTickLabels(e){let n=this.options.ticks,r,i,o;for(r=0,i=e.length;r<i;r++)o=e[r],o.label=Qe(n.callback,[o.value,r,e],this);}afterTickToLabelConversion(){Qe(this.options.afterTickToLabelConversion,[this]);}beforeCalculateLabelRotation(){Qe(this.options.beforeCalculateLabelRotation,[this]);}calculateLabelRotation(){let e=this.options,n=e.ticks,r=this.ticks.length,i=n.minRotation||0,o=n.maxRotation,s=i,c,p,h;if(!this._isVisible()||!n.display||i>=o||r<=1||!this.isHorizontal()){this.labelRotation=i;return}let v=this._getLabelSizes(),P=v.widest.width,x=v.highest.height,T=Nr(this.chart.width-P,0,this.maxWidth);c=e.offset?this.maxWidth/r:T/(r-1),P+6>c&&(c=T/(r-(e.offset?.5:1)),p=this.maxHeight-yf(e.grid)-n.padding-ow(e.title,this.chart.options.font),h=Math.sqrt(P*P+x*x),s=Tc(Math.min(Math.asin(Nr((v.highest.height+6)/c,-1,1)),Math.asin(Nr(p/h,-1,1))-Math.asin(Nr(x/h,-1,1)))),s=Math.max(i,Math.min(o,s))),this.labelRotation=s;}afterCalculateLabelRotation(){Qe(this.options.afterCalculateLabelRotation,[this]);}afterAutoSkip(){}beforeFit(){Qe(this.options.beforeFit,[this]);}fit(){let e={width:0,height:0},{chart:n,options:{ticks:r,title:i,grid:o}}=this,s=this._isVisible(),c=this.isHorizontal();if(s){let p=ow(i,n.options.font);if(c?(e.width=this.maxWidth,e.height=yf(o)+p):(e.height=this.maxHeight,e.width=yf(o)+p),r.display&&this.ticks.length){let{first:h,last:v,widest:P,highest:x}=this._getLabelSizes(),T=r.padding*2,I=Qn(this.labelRotation),F=Math.cos(I),A=Math.sin(I);if(c){let O=r.mirror?0:A*P.width+F*x.height;e.height=Math.min(this.maxHeight,e.height+O+T);}else {let O=r.mirror?0:F*P.width+A*x.height;e.width=Math.min(this.maxWidth,e.width+O+T);}this._calculatePadding(h,v,A,F);}}this._handleMargins(),c?(this.width=this._length=n.width-this._margins.left-this._margins.right,this.height=e.height):(this.width=e.width,this.height=this._length=n.height-this._margins.top-this._margins.bottom);}_calculatePadding(e,n,r,i){let{ticks:{align:o,padding:s},position:c}=this.options,p=this.labelRotation!==0,h=c!=="top"&&this.axis==="x";if(this.isHorizontal()){let v=this.getPixelForTick(0)-this.left,P=this.right-this.getPixelForTick(this.ticks.length-1),x=0,T=0;p?h?(x=i*e.width,T=r*n.height):(x=r*e.height,T=i*n.width):o==="start"?T=n.width:o==="end"?x=e.width:o!=="inner"&&(x=e.width/2,T=n.width/2),this.paddingLeft=Math.max((x-v+s)*this.width/(this.width-v),0),this.paddingRight=Math.max((T-P+s)*this.width/(this.width-P),0);}else {let v=n.height/2,P=e.height/2;o==="start"?(v=0,P=e.height):o==="end"&&(v=n.height,P=0),this.paddingTop=v+s,this.paddingBottom=P+s;}}_handleMargins(){this._margins&&(this._margins.left=Math.max(this.paddingLeft,this._margins.left),this._margins.top=Math.max(this.paddingTop,this._margins.top),this._margins.right=Math.max(this.paddingRight,this._margins.right),this._margins.bottom=Math.max(this.paddingBottom,this._margins.bottom));}afterFit(){Qe(this.options.afterFit,[this]);}isHorizontal(){let{axis:e,position:n}=this.options;return n==="top"||n==="bottom"||e==="x"}isFullSize(){return this.options.fullSize}_convertTicksToLabels(e){this.beforeTickToLabelConversion(),this.generateTickLabels(e);let n,r;for(n=0,r=e.length;n<r;n++)Le(e[n].label)&&(e.splice(n,1),r--,n--);this.afterTickToLabelConversion();}_getLabelSizes(){let e=this._labelSizes;if(!e){let n=this.options.ticks.sampleSize,r=this.ticks;n<r.length&&(r=iw(r,n)),this._labelSizes=e=this._computeLabelSizes(r,r.length);}return e}_computeLabelSizes(e,n){let{ctx:r,_longestTextCache:i}=this,o=[],s=[],c=0,p=0,h,v,P,x,T,I,F,A,O,N,V;for(h=0;h<n;++h){if(x=e[h].label,T=this._resolveTickFontOptions(h),r.font=I=T.string,F=i[I]=i[I]||{data:{},gc:[]},A=T.lineHeight,O=N=0,!Le(x)&&!He(x))O=nd(r,F.data,F.gc,O,x),N=A;else if(He(x))for(v=0,P=x.length;v<P;++v)V=x[v],!Le(V)&&!He(V)&&(O=nd(r,F.data,F.gc,O,V),N+=A);o.push(O),s.push(N),c=Math.max(O,c),p=Math.max(N,p);}N6(i,n);let G=o.indexOf(c),X=s.indexOf(p),nt=st=>({width:o[st]||0,height:s[st]||0});return {first:nt(0),last:nt(n-1),widest:nt(G),highest:nt(X),widths:o,heights:s}}getLabelForValue(e){return e}getPixelForValue(e,n){return NaN}getValueForPixel(e){}getPixelForTick(e){let n=this.ticks;return e<0||e>n.length-1?null:this.getPixelForValue(n[e].value)}getPixelForDecimal(e){this._reversePixels&&(e=1-e);let n=this._startPixel+e*this._length;return y0(this._alignToPixels?rs(this.chart,n,0):n)}getDecimalForPixel(e){let n=(e-this._startPixel)/this._length;return this._reversePixels?1-n:n}getBasePixel(){return this.getPixelForValue(this.getBaseValue())}getBaseValue(){let{min:e,max:n}=this;return e<0&&n<0?n:e>0&&n>0?e:0}getContext(e){let n=this.ticks||[];if(e>=0&&e<n.length){let r=n[e];return r.$context||(r.$context=B6(this.getContext(),e,r))}return this.$context||(this.$context=L6(this.chart.getContext(),this))}_tickSize(){let e=this.options.ticks,n=Qn(this.labelRotation),r=Math.abs(Math.cos(n)),i=Math.abs(Math.sin(n)),o=this._getLabelSizes(),s=e.autoSkipPadding||0,c=o?o.widest.width+s:0,p=o?o.highest.height+s:0;return this.isHorizontal()?p*r>c*i?c/r:p/i:p*i<c*r?p/r:c/i}_isVisible(){let e=this.options.display;return e!=="auto"?!!e:this.getMatchingVisibleMetas().length>0}_computeGridLineItems(e){let n=this.axis,r=this.chart,i=this.options,{grid:o,position:s}=i,c=o.offset,p=this.isHorizontal(),v=this.ticks.length+(c?1:0),P=yf(o),x=[],T=o.setContext(this.getContext()),I=T.drawBorder?T.borderWidth:0,F=I/2,A=function(mt){return rs(r,mt,I)},O,N,V,G,X,nt,st,U,j,ut,Y,at;if(s==="top")O=A(this.bottom),nt=this.bottom-P,U=O-F,ut=A(e.top)+F,at=e.bottom;else if(s==="bottom")O=A(this.top),ut=e.top,at=A(e.bottom)-F,nt=O+F,U=this.top+P;else if(s==="left")O=A(this.right),X=this.right-P,st=O-F,j=A(e.left)+F,Y=e.right;else if(s==="right")O=A(this.left),j=e.left,Y=A(e.right)-F,X=O+F,st=this.left+P;else if(n==="x"){if(s==="center")O=A((e.top+e.bottom)/2+.5);else if(Te(s)){let mt=Object.keys(s)[0],Ct=s[mt];O=A(this.chart.scales[mt].getPixelForValue(Ct));}ut=e.top,at=e.bottom,nt=O+F,U=nt+P;}else if(n==="y"){if(s==="center")O=A((e.left+e.right)/2);else if(Te(s)){let mt=Object.keys(s)[0],Ct=s[mt];O=A(this.chart.scales[mt].getPixelForValue(Ct));}X=O-F,st=X-P,j=e.left,Y=e.right;}let pt=me(i.ticks.maxTicksLimit,v),dt=Math.max(1,Math.ceil(v/pt));for(N=0;N<v;N+=dt){let mt=o.setContext(this.getContext(N)),Ct=mt.lineWidth,jt=mt.color,Gt=mt.borderDash||[],Jt=mt.borderDashOffset,ee=mt.tickWidth,re=mt.tickColor,Ee=mt.tickBorderDash||[],je=mt.tickBorderDashOffset;V=M6(this,N,c),V!==void 0&&(G=rs(r,V,Ct),p?X=st=j=Y=G:nt=U=ut=at=G,x.push({tx1:X,ty1:nt,tx2:st,ty2:U,x1:j,y1:ut,x2:Y,y2:at,width:Ct,color:jt,borderDash:Gt,borderDashOffset:Jt,tickWidth:ee,tickColor:re,tickBorderDash:Ee,tickBorderDashOffset:je}));}return this._ticksLength=v,this._borderValue=O,x}_computeLabelItems(e){let n=this.axis,r=this.options,{position:i,ticks:o}=r,s=this.isHorizontal(),c=this.ticks,{align:p,crossAlign:h,padding:v,mirror:P}=o,x=yf(r.grid),T=x+v,I=P?-v:T,F=-Qn(this.labelRotation),A=[],O,N,V,G,X,nt,st,U,j,ut,Y,at,pt="middle";if(i==="top")nt=this.bottom-I,st=this._getXAxisLabelAlignment();else if(i==="bottom")nt=this.top+I,st=this._getXAxisLabelAlignment();else if(i==="left"){let mt=this._getYAxisLabelAlignment(x);st=mt.textAlign,X=mt.x;}else if(i==="right"){let mt=this._getYAxisLabelAlignment(x);st=mt.textAlign,X=mt.x;}else if(n==="x"){if(i==="center")nt=(e.top+e.bottom)/2+T;else if(Te(i)){let mt=Object.keys(i)[0],Ct=i[mt];nt=this.chart.scales[mt].getPixelForValue(Ct)+T;}st=this._getXAxisLabelAlignment();}else if(n==="y"){if(i==="center")X=(e.left+e.right)/2-T;else if(Te(i)){let mt=Object.keys(i)[0],Ct=i[mt];X=this.chart.scales[mt].getPixelForValue(Ct);}st=this._getYAxisLabelAlignment(x).textAlign;}n==="y"&&(p==="start"?pt="top":p==="end"&&(pt="bottom"));let dt=this._getLabelSizes();for(O=0,N=c.length;O<N;++O){V=c[O],G=V.label;let mt=o.setContext(this.getContext(O));U=this.getPixelForTick(O)+o.labelOffset,j=this._resolveTickFontOptions(O),ut=j.lineHeight,Y=He(G)?G.length:1;let Ct=Y/2,jt=mt.color,Gt=mt.textStrokeColor,Jt=mt.textStrokeWidth,ee=st;s?(X=U,st==="inner"&&(O===N-1?ee=this.options.reverse?"left":"right":O===0?ee=this.options.reverse?"right":"left":ee="center"),i==="top"?h==="near"||F!==0?at=-Y*ut+ut/2:h==="center"?at=-dt.highest.height/2-Ct*ut+ut:at=-dt.highest.height+ut/2:h==="near"||F!==0?at=ut/2:h==="center"?at=dt.highest.height/2-Ct*ut:at=dt.highest.height-Y*ut,P&&(at*=-1)):(nt=U,at=(1-Y)*ut/2);let re;if(mt.showLabelBackdrop){let Ee=$n(mt.backdropPadding),je=dt.heights[O],sn=dt.widths[O],Ze=nt+at-Ee.top,Pn=X-Ee.left;switch(pt){case "middle":Ze-=je/2;break;case "bottom":Ze-=je;break}switch(st){case "center":Pn-=sn/2;break;case "right":Pn-=sn;break}re={left:Pn,top:Ze,width:sn+Ee.width,height:je+Ee.height,color:mt.backdropColor};}A.push({rotation:F,label:G,font:j,color:jt,strokeColor:Gt,strokeWidth:Jt,textOffset:at,textAlign:ee,textBaseline:pt,translation:[X,nt],backdrop:re});}return A}_getXAxisLabelAlignment(){let{position:e,ticks:n}=this.options;if(-Qn(this.labelRotation))return e==="top"?"left":"right";let i="center";return n.align==="start"?i="left":n.align==="end"?i="right":n.align==="inner"&&(i="inner"),i}_getYAxisLabelAlignment(e){let{position:n,ticks:{crossAlign:r,mirror:i,padding:o}}=this.options,s=this._getLabelSizes(),c=e+o,p=s.widest.width,h,v;return n==="left"?i?(v=this.right+o,r==="near"?h="left":r==="center"?(h="center",v+=p/2):(h="right",v+=p)):(v=this.right-c,r==="near"?h="right":r==="center"?(h="center",v-=p/2):(h="left",v=this.left)):n==="right"?i?(v=this.left+o,r==="near"?h="right":r==="center"?(h="center",v-=p/2):(h="left",v-=p)):(v=this.left+c,r==="near"?h="left":r==="center"?(h="center",v+=p/2):(h="right",v=this.right)):h="right",{textAlign:h,x:v}}_computeLabelArea(){if(this.options.ticks.mirror)return;let e=this.chart,n=this.options.position;if(n==="left"||n==="right")return {top:0,left:this.left,bottom:e.height,right:this.right};if(n==="top"||n==="bottom")return {top:this.top,left:0,bottom:this.bottom,right:e.width}}drawBackground(){let{ctx:e,options:{backgroundColor:n},left:r,top:i,width:o,height:s}=this;n&&(e.save(),e.fillStyle=n,e.fillRect(r,i,o,s),e.restore());}getLineWidthForValue(e){let n=this.options.grid;if(!this._isVisible()||!n.display)return 0;let i=this.ticks.findIndex(o=>o.value===e);return i>=0?n.setContext(this.getContext(i)).lineWidth:0}drawGrid(e){let n=this.options.grid,r=this.ctx,i=this._gridLineItems||(this._gridLineItems=this._computeGridLineItems(e)),o,s,c=(p,h,v)=>{!v.width||!v.color||(r.save(),r.lineWidth=v.width,r.strokeStyle=v.color,r.setLineDash(v.borderDash||[]),r.lineDashOffset=v.borderDashOffset,r.beginPath(),r.moveTo(p.x,p.y),r.lineTo(h.x,h.y),r.stroke(),r.restore());};if(n.display)for(o=0,s=i.length;o<s;++o){let p=i[o];n.drawOnChartArea&&c({x:p.x1,y:p.y1},{x:p.x2,y:p.y2},p),n.drawTicks&&c({x:p.tx1,y:p.ty1},{x:p.tx2,y:p.ty2},{color:p.tickColor,width:p.tickWidth,borderDash:p.tickBorderDash,borderDashOffset:p.tickBorderDashOffset});}}drawBorder(){let{chart:e,ctx:n,options:{grid:r}}=this,i=r.setContext(this.getContext()),o=r.drawBorder?i.borderWidth:0;if(!o)return;let s=r.setContext(this.getContext(0)).lineWidth,c=this._borderValue,p,h,v,P;this.isHorizontal()?(p=rs(e,this.left,o)-o/2,h=rs(e,this.right,s)+s/2,v=P=c):(v=rs(e,this.top,o)-o/2,P=rs(e,this.bottom,s)+s/2,p=h=c),n.save(),n.lineWidth=i.borderWidth,n.strokeStyle=i.borderColor,n.beginPath(),n.moveTo(p,v),n.lineTo(h,P),n.stroke(),n.restore();}drawLabels(e){if(!this.options.ticks.display)return;let r=this.ctx,i=this._computeLabelArea();i&&fl(r,i);let o=this._labelItems||(this._labelItems=this._computeLabelItems(e)),s,c;for(s=0,c=o.length;s<c;++s){let p=o[s],h=p.font,v=p.label;p.backdrop&&(r.fillStyle=p.backdrop.color,r.fillRect(p.backdrop.left,p.backdrop.top,p.backdrop.width,p.backdrop.height));let P=p.textOffset;is(r,v,0,P,h,p);}i&&hl(r);}drawTitle(){let{ctx:e,options:{position:n,title:r,reverse:i}}=this;if(!r.display)return;let o=Sn(r.font),s=$n(r.padding),c=r.align,p=o.lineHeight/2;n==="bottom"||n==="center"||Te(n)?(p+=s.bottom,He(r.text)&&(p+=o.lineHeight*(r.text.length-1))):p+=s.top;let{titleX:h,titleY:v,maxWidth:P,rotation:x}=$6(this,p,n,c);is(e,r.text,0,0,o,{color:r.color,maxWidth:P,rotation:x,textAlign:U6(c,n,i),textBaseline:"middle",translation:[h,v]});}draw(e){this._isVisible()&&(this.drawBackground(),this.drawGrid(e),this.drawBorder(),this.drawTitle(),this.drawLabels(e));}_layers(){let e=this.options,n=e.ticks&&e.ticks.z||0,r=me(e.grid&&e.grid.z,-1);return !this._isVisible()||this.draw!==t.prototype.draw?[{z:n,draw:i=>{this.draw(i);}}]:[{z:r,draw:i=>{this.drawBackground(),this.drawGrid(i),this.drawTitle();}},{z:r+1,draw:()=>{this.drawBorder();}},{z:n,draw:i=>{this.drawLabels(i);}}]}getMatchingVisibleMetas(e){let n=this.chart.getSortedVisibleDatasetMetas(),r=this.axis+"AxisID",i=[],o,s;for(o=0,s=n.length;o<s;++o){let c=n[o];c[r]===this.id&&(!e||c.type===e)&&i.push(c);}return i}_resolveTickFontOptions(e){let n=this.options.ticks.setContext(this.getContext(e));return Sn(n.font)}_maxDigits(){let e=this._resolveTickFontOptions(0).lineHeight;return (this.isHorizontal()?this.width:this.height)/e}},ad=class{constructor(e,n,r){this.type=e,this.scope=n,this.override=r,this.items=Object.create(null);}isForType(e){return Object.prototype.isPrototypeOf.call(this.type.prototype,e.prototype)}register(e){let n=Object.getPrototypeOf(e),r;V6(n)&&(r=this.register(n));let i=this.items,o=e.id,s=this.scope+"."+o;if(!o)throw new Error("class does not have id: "+e);return o in i||(i[o]=e,G6(e,s,r),this.override&&ke.override(e.id,e.overrides)),s}get(e){return this.items[e]}unregister(e){let n=this.items,r=e.id,i=this.scope;r in n&&delete n[r],i&&r in ke[i]&&(delete ke[i][r],this.override&&delete pl[r]);}};function G6(t,e,n){let r=ji(Object.create(null),[n?ke.get(n):{},ke.get(e),t.defaults]);ke.set(e,r),t.defaultRoutes&&j6(e,t.defaultRoutes),t.descriptors&&ke.describe(e,t.descriptors);}function j6(t,e){Object.keys(e).forEach(n=>{let r=n.split("."),i=r.pop(),o=[t].concat(r).join("."),s=e[n].split("."),c=s.pop(),p=s.join(".");ke.route(o,i,p,c);});}function V6(t){return "id"in t&&"defaults"in t}var K0=class{constructor(){this.controllers=new ad(zi,"datasets",true),this.elements=new ad(br,"elements"),this.plugins=new ad(Object,"plugins"),this.scales=new ad(Oc,"scales"),this._typedRegistries=[this.controllers,this.scales,this.elements];}add(...e){this._each("register",e);}remove(...e){this._each("unregister",e);}addControllers(...e){this._each("register",e,this.controllers);}addElements(...e){this._each("register",e,this.elements);}addPlugins(...e){this._each("register",e,this.plugins);}addScales(...e){this._each("register",e,this.scales);}getController(e){return this._get(e,this.controllers,"controller")}getElement(e){return this._get(e,this.elements,"element")}getPlugin(e){return this._get(e,this.plugins,"plugin")}getScale(e){return this._get(e,this.scales,"scale")}removeControllers(...e){this._each("unregister",e,this.controllers);}removeElements(...e){this._each("unregister",e,this.elements);}removePlugins(...e){this._each("unregister",e,this.plugins);}removeScales(...e){this._each("unregister",e,this.scales);}_each(e,n,r){[...n].forEach(i=>{let o=r||this._getRegistryForType(i);r||o.isForType(i)||o===this.plugins&&i.id?this._exec(e,o,i):tn(i,s=>{let c=r||this._getRegistryForType(s);this._exec(e,c,s);});});}_exec(e,n,r){let i=sf(e);Qe(r["before"+i],[],r),n[e](r),Qe(r["after"+i],[],r);}_getRegistryForType(e){for(let n=0;n<this._typedRegistries.length;n++){let r=this._typedRegistries[n];if(r.isForType(e))return r}return this.plugins}_get(e,n,r){let i=n.get(e);if(i===void 0)throw new Error('"'+e+'" is not a registered '+r+".");return i}},Ca=new K0,If=class extends zi{update(e){let n=this._cachedMeta,{data:r=[]}=n,i=this.chart._animationsDisabled,{start:o,count:s}=jg(n,r,i);if(this._drawStart=o,this._drawCount=s,Vg(n)&&(o=0,s=r.length),this.options.showLine){let{dataset:c,_dataset:p}=n;c._chart=this.chart,c._datasetIndex=this.index,c._decimated=!!p._decimated,c.points=r;let h=this.resolveDatasetElementOptions(e);h.segment=this.options.segment,this.updateElement(c,void 0,{animated:!i,options:h},e);}this.updateElements(r,o,s,e);}addElements(){let{showLine:e}=this.options;!this.datasetElementType&&e&&(this.datasetElementType=Ca.getElement("line")),super.addElements();}updateElements(e,n,r,i){let o=i==="reset",{iScale:s,vScale:c,_stacked:p,_dataset:h}=this._cachedMeta,v=this.resolveDataElementOptions(n,i),P=this.getSharedOptions(v),x=this.includeOptions(i,P),T=s.axis,I=c.axis,{spanGaps:F,segment:A}=this.options,O=Vi(F)?F:Number.POSITIVE_INFINITY,N=this.chart._animationsDisabled||o||i==="none",V=n>0&&this.getParsed(n-1);for(let G=n;G<n+r;++G){let X=e[G],nt=this.getParsed(G),st=N?X:{},U=Le(nt[I]),j=st[T]=s.getPixelForValue(nt[T],G),ut=st[I]=o||U?c.getBasePixel():c.getPixelForValue(p?this.applyStack(c,nt,p):nt[I],G);st.skip=isNaN(j)||isNaN(ut)||U,st.stop=G>0&&Math.abs(nt[T]-V[T])>O,A&&(st.parsed=nt,st.raw=h.data[G]),x&&(st.options=P||this.resolveDataElementOptions(G,X.active?"active":i)),N||this.updateElement(X,G,st,i),V=nt;}this.updateSharedOptions(P,i,v);}getMaxOverflow(){let e=this._cachedMeta,n=e.data||[];if(!this.options.showLine){let c=0;for(let p=n.length-1;p>=0;--p)c=Math.max(c,n[p].size(this.resolveDataElementOptions(p))/2);return c>0&&c}let r=e.dataset,i=r.options&&r.options.borderWidth||0;if(!n.length)return i;let o=n[0].size(this.resolveDataElementOptions(0)),s=n[n.length-1].size(this.resolveDataElementOptions(n.length-1));return Math.max(i,o,s)/2}};If.id="scatter";If.defaults={datasetElementType:false,dataElementType:"point",showLine:false,fill:false};If.overrides={interaction:{mode:"point"},plugins:{tooltip:{callbacks:{title(){return ""},label(t){return "("+t.label+", "+t.formattedValue+")"}}}},scales:{x:{type:"linear"},y:{type:"linear"}}};function Dc(){throw new Error("This method is not implemented: Check that a complete date adapter is provided.")}var kf=class{constructor(e){this.options=e||{};}init(e){}formats(){return Dc()}parse(e,n){return Dc()}format(e,n){return Dc()}add(e,n,r){return Dc()}diff(e,n,r){return Dc()}startOf(e,n,r){return Dc()}endOf(e,n){return Dc()}};kf.override=function(t){Object.assign(kf.prototype,t);};var z6={_date:kf};function H6(t,e,n,r){let{controller:i,data:o,_sorted:s}=t,c=i._cachedMeta.iScale;if(c&&e===c.axis&&e!=="r"&&s&&o.length){let p=c._reversePixels?b0:es;if(r){if(i._sharedOptions){let h=o[0],v=typeof h.getRange=="function"&&h.getRange(e);if(v){let P=p(o,e,n-v),x=p(o,e,n+v);return {lo:P.lo,hi:x.hi}}}}else return p(o,e,n)}return {lo:0,hi:o.length-1}}function Of(t,e,n,r,i){let o=t.getSortedVisibleDatasetMetas(),s=n[e];for(let c=0,p=o.length;c<p;++c){let{index:h,data:v}=o[c],{lo:P,hi:x}=H6(o[c],e,s,i);for(let T=P;T<=x;++T){let I=v[T];I.skip||r(I,h,T);}}}function W6(t){let e=t.indexOf("x")!==-1,n=t.indexOf("y")!==-1;return function(r,i){let o=e?Math.abs(r.x-i.x):0,s=n?Math.abs(r.y-i.y):0;return Math.sqrt(Math.pow(o,2)+Math.pow(s,2))}}function j0(t,e,n,r,i){let o=[];return !i&&!t.isPointInArea(e)||Of(t,n,e,function(c,p,h){!i&&!xc(c,t.chartArea,0)||c.inRange(e.x,e.y,r)&&o.push({element:c,datasetIndex:p,index:h});},true),o}function q6(t,e,n,r){let i=[];function o(s,c,p){let{startAngle:h,endAngle:v}=s.getProps(["startAngle","endAngle"],r),{angle:P}=Lg(s,{x:e.x,y:e.y});wc(P,h,v)&&i.push({element:s,datasetIndex:c,index:p});}return Of(t,n,e,o),i}function Y6(t,e,n,r,i,o){let s=[],c=W6(n),p=Number.POSITIVE_INFINITY;function h(v,P,x){let T=v.inRange(e.x,e.y,i);if(r&&!T)return;let I=v.getCenterPoint(i);if(!(!!o||t.isPointInArea(I))&&!T)return;let A=c(e,I);A<p?(s=[{element:v,datasetIndex:P,index:x}],p=A):A===p&&s.push({element:v,datasetIndex:P,index:x});}return Of(t,n,e,h),s}function V0(t,e,n,r,i,o){return !o&&!t.isPointInArea(e)?[]:n==="r"&&!r?q6(t,e,n,i):Y6(t,e,n,r,i,o)}function aw(t,e,n,r,i){let o=[],s=n==="x"?"inXRange":"inYRange",c=false;return Of(t,n,e,(p,h,v)=>{p[s](e[n],i)&&(o.push({element:p,datasetIndex:h,index:v}),c=c||p.inRange(e.x,e.y,i));}),r&&!c?[]:o}var Q6={modes:{index(t,e,n,r){let i=as(e,t),o=n.axis||"x",s=n.includeInvisible||false,c=n.intersect?j0(t,i,o,r,s):V0(t,i,o,false,r,s),p=[];return c.length?(t.getSortedVisibleDatasetMetas().forEach(h=>{let v=c[0].index,P=h.data[v];P&&!P.skip&&p.push({element:P,datasetIndex:h.index,index:v});}),p):[]},dataset(t,e,n,r){let i=as(e,t),o=n.axis||"xy",s=n.includeInvisible||false,c=n.intersect?j0(t,i,o,r,s):V0(t,i,o,false,r,s);if(c.length>0){let p=c[0].datasetIndex,h=t.getDatasetMeta(p).data;c=[];for(let v=0;v<h.length;++v)c.push({element:h[v],datasetIndex:p,index:v});}return c},point(t,e,n,r){let i=as(e,t),o=n.axis||"xy",s=n.includeInvisible||false;return j0(t,i,o,r,s)},nearest(t,e,n,r){let i=as(e,t),o=n.axis||"xy",s=n.includeInvisible||false;return V0(t,i,o,n.intersect,r,s)},x(t,e,n,r){let i=as(e,t);return aw(t,i,"x",n.intersect,r)},y(t,e,n,r){let i=as(e,t);return aw(t,i,"y",n.intersect,r)}}},$w=["left","top","right","bottom"];function bf(t,e){return t.filter(n=>n.pos===e)}function sw(t,e){return t.filter(n=>$w.indexOf(n.pos)===-1&&n.box.axis===e)}function vf(t,e){return t.sort((n,r)=>{let i=e?r:n,o=e?n:r;return i.weight===o.weight?i.index-o.index:i.weight-o.weight})}function K6(t){let e=[],n,r,i,o,s,c;for(n=0,r=(t||[]).length;n<r;++n)i=t[n],{position:o,options:{stack:s,stackWeight:c=1}}=i,e.push({index:n,box:i,pos:o,horizontal:i.isHorizontal(),weight:i.weight,stack:s&&o+s,stackWeight:c});return e}function X6(t){let e={};for(let n of t){let{stack:r,pos:i,stackWeight:o}=n;if(!r||!$w.includes(i))continue;let s=e[r]||(e[r]={count:0,placed:0,weight:0,size:0});s.count++,s.weight+=o;}return e}function Z6(t,e){let n=X6(t),{vBoxMaxWidth:r,hBoxMaxHeight:i}=e,o,s,c;for(o=0,s=t.length;o<s;++o){c=t[o];let{fullSize:p}=c.box,h=n[c.stack],v=h&&c.stackWeight/h.weight;c.horizontal?(c.width=v?v*r:p&&e.availableWidth,c.height=i):(c.width=r,c.height=v?v*i:p&&e.availableHeight);}return n}function J6(t){let e=K6(t),n=vf(e.filter(h=>h.box.fullSize),true),r=vf(bf(e,"left"),true),i=vf(bf(e,"right")),o=vf(bf(e,"top"),true),s=vf(bf(e,"bottom")),c=sw(e,"x"),p=sw(e,"y");return {fullSize:n,leftAndTop:r.concat(o),rightAndBottom:i.concat(p).concat(s).concat(c),chartArea:bf(e,"chartArea"),vertical:r.concat(i).concat(p),horizontal:o.concat(s).concat(c)}}function lw(t,e,n,r){return Math.max(t[n],e[n])+Math.max(t[r],e[r])}function Gw(t,e){t.top=Math.max(t.top,e.top),t.left=Math.max(t.left,e.left),t.bottom=Math.max(t.bottom,e.bottom),t.right=Math.max(t.right,e.right);}function t4(t,e,n,r){let{pos:i,box:o}=n,s=t.maxPadding;if(!Te(i)){n.size&&(t[i]-=n.size);let P=r[n.stack]||{size:0,count:1};P.size=Math.max(P.size,n.horizontal?o.height:o.width),n.size=P.size/P.count,t[i]+=n.size;}o.getPadding&&Gw(s,o.getPadding());let c=Math.max(0,e.outerWidth-lw(s,t,"left","right")),p=Math.max(0,e.outerHeight-lw(s,t,"top","bottom")),h=c!==t.w,v=p!==t.h;return t.w=c,t.h=p,n.horizontal?{same:h,other:v}:{same:v,other:h}}function e4(t){let e=t.maxPadding;function n(r){let i=Math.max(e[r]-t[r],0);return t[r]+=i,i}t.y+=n("top"),t.x+=n("left"),n("right"),n("bottom");}function n4(t,e){let n=e.maxPadding;function r(i){let o={left:0,top:0,right:0,bottom:0};return i.forEach(s=>{o[s]=Math.max(e[s],n[s]);}),o}return r(t?["left","right"]:["top","bottom"])}function Sf(t,e,n,r){let i=[],o,s,c,p,h,v;for(o=0,s=t.length,h=0;o<s;++o){c=t[o],p=c.box,p.update(c.width||e.w,c.height||e.h,n4(c.horizontal,e));let{same:P,other:x}=t4(e,n,c,r);h|=P&&i.length,v=v||x,p.fullSize||i.push(c);}return h&&Sf(i,e,n,r)||v}function oy(t,e,n,r,i){t.top=n,t.left=e,t.right=e+r,t.bottom=n+i,t.width=r,t.height=i;}function cw(t,e,n,r){let i=n.padding,{x:o,y:s}=e;for(let c of t){let p=c.box,h=r[c.stack]||{placed:0,weight:1},v=c.stackWeight/h.weight||1;if(c.horizontal){let P=e.w*v,x=h.size||p.height;Fn(h.start)&&(s=h.start),p.fullSize?oy(p,i.left,s,n.outerWidth-i.right-i.left,x):oy(p,e.left+h.placed,s,P,x),h.start=s,h.placed+=P,s=p.bottom;}else {let P=e.h*v,x=h.size||p.width;Fn(h.start)&&(o=h.start),p.fullSize?oy(p,o,i.top,x,n.outerHeight-i.bottom-i.top):oy(p,o,e.top+h.placed,x,P),h.start=o,h.placed+=P,o=p.right;}}e.x=o,e.y=s;}ke.set("layout",{autoPadding:true,padding:{top:0,right:0,bottom:0,left:0}});var yo={addBox(t,e){t.boxes||(t.boxes=[]),e.fullSize=e.fullSize||false,e.position=e.position||"top",e.weight=e.weight||0,e._layers=e._layers||function(){return [{z:0,draw(n){e.draw(n);}}]},t.boxes.push(e);},removeBox(t,e){let n=t.boxes?t.boxes.indexOf(e):-1;n!==-1&&t.boxes.splice(n,1);},configure(t,e,n){e.fullSize=n.fullSize,e.position=n.position,e.weight=n.weight;},update(t,e,n,r){if(!t)return;let i=$n(t.options.layout.padding),o=Math.max(e-i.width,0),s=Math.max(n-i.height,0),c=J6(t.boxes),p=c.vertical,h=c.horizontal;tn(t.boxes,F=>{typeof F.beforeLayout=="function"&&F.beforeLayout();});let v=p.reduce((F,A)=>A.box.options&&A.box.options.display===false?F:F+1,0)||1,P=Object.freeze({outerWidth:e,outerHeight:n,padding:i,availableWidth:o,availableHeight:s,vBoxMaxWidth:o/2/v,hBoxMaxHeight:s/2}),x=Object.assign({},i);Gw(x,$n(r));let T=Object.assign({maxPadding:x,w:o,h:s,x:i.left,y:i.top},i),I=Z6(p.concat(h),P);Sf(c.fullSize,T,P,I),Sf(p,T,P,I),Sf(h,T,P,I)&&Sf(p,T,P,I),e4(T),cw(c.leftAndTop,T,P,I),T.x+=T.w,T.y+=T.h,cw(c.rightAndBottom,T,P,I),t.chartArea={left:T.left,top:T.top,right:T.left+T.w,bottom:T.top+T.h,height:T.h,width:T.w},tn(c.chartArea,F=>{let A=F.box;Object.assign(A,t.chartArea),A.update(T.w,T.h,{left:0,top:0,right:0,bottom:0});});}},dy=class{acquireContext(e,n){}releaseContext(e){return false}addEventListener(e,n,r){}removeEventListener(e,n,r){}getDevicePixelRatio(){return 1}getMaximumSize(e,n,r,i){return n=Math.max(0,n||e.width),r=r||e.height,{width:n,height:Math.max(0,i?Math.floor(n/i):r)}}isAttached(e){return true}updateConfig(e){}},X0=class extends dy{acquireContext(e){return e&&e.getContext&&e.getContext("2d")||null}updateConfig(e){e.options.animation=false;}},cy="$chartjs",r4={touchstart:"mousedown",touchmove:"mousemove",touchend:"mouseup",pointerenter:"mouseenter",pointerdown:"mousedown",pointermove:"mousemove",pointerup:"mouseup",pointerleave:"mouseout",pointerout:"mouseout"},uw=t=>t===null||t==="";function i4(t,e){let n=t.style,r=t.getAttribute("height"),i=t.getAttribute("width");if(t[cy]={initial:{height:r,width:i,style:{display:n.display,height:n.height,width:n.width}}},n.display=n.display||"block",n.boxSizing=n.boxSizing||"border-box",uw(i)){let o=Jg(t,"width");o!==void 0&&(t.width=o);}if(uw(r))if(t.style.height==="")t.height=t.width/(e||2);else {let o=Jg(t,"height");o!==void 0&&(t.height=o);}return t}var jw=M0?{passive:true}:false;function o4(t,e,n){t.addEventListener(e,n,jw);}function a4(t,e,n){t.canvas.removeEventListener(e,n,jw);}function s4(t,e){let n=r4[t.type]||t.type,{x:r,y:i}=as(t,e);return {type:n,chart:e,native:t,x:r!==void 0?r:null,y:i!==void 0?i:null}}function py(t,e){for(let n of t)if(n===e||n.contains(e))return true}function l4(t,e,n){let r=t.canvas,i=new MutationObserver(o=>{let s=false;for(let c of o)s=s||py(c.addedNodes,r),s=s&&!py(c.removedNodes,r);s&&n();});return i.observe(document,{childList:true,subtree:true}),i}function c4(t,e,n){let r=t.canvas,i=new MutationObserver(o=>{let s=false;for(let c of o)s=s||py(c.removedNodes,r),s=s&&!py(c.addedNodes,r);s&&n();});return i.observe(document,{childList:true,subtree:true}),i}var Df=new Map,dw=0;function Vw(){let t=window.devicePixelRatio;t!==dw&&(dw=t,Df.forEach((e,n)=>{n.currentDevicePixelRatio!==t&&e();}));}function u4(t,e){Df.size||window.addEventListener("resize",Vw),Df.set(t,e);}function d4(t){Df.delete(t),Df.size||window.removeEventListener("resize",Vw);}function p4(t,e,n){let r=t.canvas,i=r&&mf(r);if(!i)return;let o=Gg((c,p)=>{let h=i.clientWidth;n(c,p),h<i.clientWidth&&n();},window),s=new ResizeObserver(c=>{let p=c[0],h=p.contentRect.width,v=p.contentRect.height;h===0&&v===0||o(h,v);});return s.observe(i),u4(t,o),s}function z0(t,e,n){n&&n.disconnect(),e==="resize"&&d4(t);}function f4(t,e,n){let r=t.canvas,i=Gg(o=>{t.ctx!==null&&n(s4(o,t));},t,o=>{let s=o[0];return [s,s.offsetX,s.offsetY]});return o4(r,e,i),i}var Z0=class extends dy{acquireContext(e,n){let r=e&&e.getContext&&e.getContext("2d");return r&&r.canvas===e?(i4(e,n),r):null}releaseContext(e){let n=e.canvas;if(!n[cy])return false;let r=n[cy].initial;["height","width"].forEach(o=>{let s=r[o];Le(s)?n.removeAttribute(o):n.setAttribute(o,s);});let i=r.style||{};return Object.keys(i).forEach(o=>{n.style[o]=i[o];}),n.width=n.width,delete n[cy],true}addEventListener(e,n,r){this.removeEventListener(e,n);let i=e.$proxies||(e.$proxies={}),s={attach:l4,detach:c4,resize:p4}[n]||f4;i[n]=s(e,n,r);}removeEventListener(e,n){let r=e.$proxies||(e.$proxies={}),i=r[n];if(!i)return;(({attach:z0,detach:z0,resize:z0})[n]||a4)(e,n,i),r[n]=void 0;}getDevicePixelRatio(){return window.devicePixelRatio}getMaximumSize(e,n,r,i){return F0(e,n,r,i)}isAttached(e){let n=mf(e);return !!(n&&n.isConnected)}};function h4(t){return !Kg()||typeof OffscreenCanvas!="undefined"&&t instanceof OffscreenCanvas?X0:Z0}var J0=class{constructor(){this._init=[];}notify(e,n,r,i){n==="beforeInit"&&(this._init=this._createDescriptors(e,true),this._notify(this._init,e,"install"));let o=i?this._descriptors(e).filter(i):this._descriptors(e),s=this._notify(o,e,n,r);return n==="afterDestroy"&&(this._notify(o,e,"stop"),this._notify(this._init,e,"uninstall")),s}_notify(e,n,r,i){i=i||{};for(let o of e){let s=o.plugin,c=s[r],p=[n,i,o.options];if(Qe(c,p,s)===false&&i.cancelable)return false}return true}invalidate(){Le(this._cache)||(this._oldCache=this._cache,this._cache=void 0);}_descriptors(e){if(this._cache)return this._cache;let n=this._cache=this._createDescriptors(e);return this._notifyStateChanges(e),n}_createDescriptors(e,n){let r=e&&e.config,i=me(r.options&&r.options.plugins,{}),o=m4(r);return i===false&&!n?[]:y4(e,o,i,n)}_notifyStateChanges(e){let n=this._oldCache||[],r=this._cache,i=(o,s)=>o.filter(c=>!s.some(p=>c.plugin.id===p.plugin.id));this._notify(i(n,r),e,"stop"),this._notify(i(r,n),e,"start");}};function m4(t){let e={},n=[],r=Object.keys(Ca.plugins.items);for(let o=0;o<r.length;o++)n.push(Ca.getPlugin(r[o]));let i=t.plugins||[];for(let o=0;o<i.length;o++){let s=i[o];n.indexOf(s)===-1&&(n.push(s),e[s.id]=true);}return {plugins:n,localIds:e}}function g4(t,e){return !e&&t===false?null:t===true?{}:t}function y4(t,{plugins:e,localIds:n},r,i){let o=[],s=t.getContext();for(let c of e){let p=c.id,h=g4(r[p],i);h!==null&&o.push({plugin:c,options:b4(t.config,{plugin:c,local:n[p]},h,s)});}return o}function b4(t,{plugin:e,local:n},r,i){let o=t.pluginScopeKeys(e),s=t.getOptionScopes(r,o);return n&&e.defaults&&s.push(e.defaults),t.createResolver(s,i,[""],{scriptable:false,indexable:false,allKeys:true})}function t1(t,e){let n=ke.datasets[t]||{};return ((e.datasets||{})[t]||{}).indexAxis||e.indexAxis||n.indexAxis||"x"}function v4(t,e){let n=t;return t==="_index_"?n=e:t==="_value_"&&(n=e==="x"?"y":"x"),n}function C4(t,e){return t===e?"_index_":"_value_"}function S4(t){if(t==="top"||t==="bottom")return "x";if(t==="left"||t==="right")return "y"}function e1(t,e){return t==="x"||t==="y"?t:e.axis||S4(e.position)||t.charAt(0).toLowerCase()}function P4(t,e){let n=pl[t.type]||{scales:{}},r=e.scales||{},i=t1(t.type,e),o=Object.create(null),s=Object.create(null);return Object.keys(r).forEach(c=>{let p=r[c];if(!Te(p))return console.error(`Invalid scale configuration for scale: ${c}`);if(p._proxy)return console.warn(`Ignoring resolver passed as options for scale: ${c}`);let h=e1(c,p),v=C4(h,i),P=n.scales||{};o[h]=o[h]||c,s[c]=Ec(Object.create(null),[{axis:h},p,P[h],P[v]]);}),t.data.datasets.forEach(c=>{let p=c.type||t.type,h=c.indexAxis||t1(p,e),P=(pl[p]||{}).scales||{};Object.keys(P).forEach(x=>{let T=v4(x,h),I=c[T+"AxisID"]||o[T]||T;s[I]=s[I]||Object.create(null),Ec(s[I],[{axis:T},r[I],P[x]]);});}),Object.keys(s).forEach(c=>{let p=s[c];Ec(p,[ke.scales[p.type],ke.scale]);}),s}function zw(t){let e=t.options||(t.options={});e.plugins=me(e.plugins,{}),e.scales=P4(t,e);}function Hw(t){return t=t||{},t.datasets=t.datasets||[],t.labels=t.labels||[],t}function x4(t){return t=t||{},t.data=Hw(t.data),zw(t),t}var pw=new Map,Ww=new Set;function ay(t,e){let n=pw.get(t);return n||(n=e(),pw.set(t,n),Ww.add(n)),n}var Cf=(t,e,n)=>{let r=ya(e,n);r!==void 0&&t.add(r);},n1=class{constructor(e){this._config=x4(e),this._scopeCache=new Map,this._resolverCache=new Map;}get platform(){return this._config.platform}get type(){return this._config.type}set type(e){this._config.type=e;}get data(){return this._config.data}set data(e){this._config.data=Hw(e);}get options(){return this._config.options}set options(e){this._config.options=e;}get plugins(){return this._config.plugins}update(){let e=this._config;this.clearCache(),zw(e);}clearCache(){this._scopeCache.clear(),this._resolverCache.clear();}datasetScopeKeys(e){return ay(e,()=>[[`datasets.${e}`,""]])}datasetAnimationScopeKeys(e,n){return ay(`${e}.transition.${n}`,()=>[[`datasets.${e}.transitions.${n}`,`transitions.${n}`],[`datasets.${e}`,""]])}datasetElementScopeKeys(e,n){return ay(`${e}-${n}`,()=>[[`datasets.${e}.elements.${n}`,`datasets.${e}`,`elements.${n}`,""]])}pluginScopeKeys(e){let n=e.id,r=this.type;return ay(`${r}-plugin-${n}`,()=>[[`plugins.${n}`,...e.additionalOptionScopes||[]]])}_cachedScopes(e,n){let r=this._scopeCache,i=r.get(e);return (!i||n)&&(i=new Map,r.set(e,i)),i}getOptionScopes(e,n,r){let{options:i,type:o}=this,s=this._cachedScopes(e,r),c=s.get(n);if(c)return c;let p=new Set;n.forEach(v=>{e&&(p.add(e),v.forEach(P=>Cf(p,e,P))),v.forEach(P=>Cf(p,i,P)),v.forEach(P=>Cf(p,pl[o]||{},P)),v.forEach(P=>Cf(p,ke,P)),v.forEach(P=>Cf(p,zg,P));});let h=Array.from(p);return h.length===0&&h.push(Object.create(null)),Ww.has(n)&&s.set(n,h),h}chartOptionScopes(){let{options:e,type:n}=this;return [e,pl[n]||{},ke.datasets[n]||{},{type:n},ke,zg]}resolveNamedOptions(e,n,r,i=[""]){let o={$shared:true},{resolver:s,subPrefixes:c}=fw(this._resolverCache,e,i),p=s;if(_4(s,n)){o.$shared=false,r=Gr(r)?r():r;let h=this.createResolver(e,r,c);p=dl(s,r,h);}for(let h of n)o[h]=p[h];return o}createResolver(e,n,r=[""],i){let{resolver:o}=fw(this._resolverCache,e,r);return Te(n)?dl(o,n,void 0,i):o}};function fw(t,e,n){let r=t.get(e);r||(r=new Map,t.set(e,r));let i=n.join(),o=r.get(i);return o||(o={resolver:hf(e,n),subPrefixes:n.filter(c=>!c.toLowerCase().includes("hover"))},r.set(i,o)),o}var E4=t=>Te(t)&&Object.getOwnPropertyNames(t).reduce((e,n)=>e||Gr(t[n]),false);function _4(t,e){let{isScriptable:n,isIndexable:r}=Yg(t);for(let i of e){let o=n(i),s=r(i),c=(s||o)&&t[i];if(o&&(Gr(c)||E4(c))||s&&He(c))return true}return false}var T4="3.9.1",w4=["top","bottom","left","right","chartArea"];function hw(t,e){return t==="top"||t==="bottom"||w4.indexOf(t)===-1&&e==="x"}function mw(t,e){return function(n,r){return n[t]===r[t]?n[e]-r[e]:n[t]-r[t]}}function gw(t){let e=t.chart,n=e.options.animation;e.notifyPlugins("afterRender"),Qe(n&&n.onComplete,[t],e);}function I4(t){let e=t.chart,n=e.options.animation;Qe(n&&n.onProgress,[t],e);}function qw(t){return Kg()&&typeof t=="string"?t=document.getElementById(t):t&&t.length&&(t=t[0]),t&&t.canvas&&(t=t.canvas),t}var fy={},Yw=t=>{let e=qw(t);return Object.values(fy).filter(n=>n.canvas===e).pop()};function k4(t,e,n){let r=Object.keys(t);for(let i of r){let o=+i;if(o>=e){let s=t[i];delete t[i],(n>0||o>e)&&(t[o+n]=s);}}}function D4(t,e,n,r){return !n||t.type==="mouseout"?null:r?e:t}var bo=class{constructor(e,n){let r=this.config=new n1(n),i=qw(e),o=Yw(i);if(o)throw new Error("Canvas is already in use. Chart with ID '"+o.id+"' must be destroyed before the canvas with ID '"+o.canvas.id+"' can be reused.");let s=r.createResolver(r.chartOptionScopes(),this.getContext());this.platform=new(r.platform||h4(i)),this.platform.updateConfig(r);let c=this.platform.acquireContext(i,s.aspectRatio),p=c&&c.canvas,h=p&&p.height,v=p&&p.width;if(this.id=p0(),this.ctx=c,this.canvas=p,this.width=v,this.height=h,this._options=s,this._aspectRatio=this.aspectRatio,this._layers=[],this._metasets=[],this._stacks=void 0,this.boxes=[],this.currentDevicePixelRatio=void 0,this.chartArea=void 0,this._active=[],this._lastEvent=void 0,this._listeners={},this._responsiveListeners=void 0,this._sortedMetasets=[],this.scales={},this._plugins=new J0,this.$proxies={},this._hiddenIndices={},this.attached=false,this._animationsDisabled=void 0,this.$context=void 0,this._doResize=S0(P=>this.update(P),s.resizeDelay||0),this._dataChanges=[],fy[this.id]=this,!c||!p){console.error("Failed to create chart: can't acquire context from the given item");return}ss.listen(this,"complete",gw),ss.listen(this,"progress",I4),this._initialize(),this.attached&&this.update();}get aspectRatio(){let{options:{aspectRatio:e,maintainAspectRatio:n},width:r,height:i,_aspectRatio:o}=this;return Le(e)?n&&o?o:i?r/i:null:e}get data(){return this.config.data}set data(e){this.config.data=e;}get options(){return this._options}set options(e){this.config.options=e;}_initialize(){return this.notifyPlugins("beforeInit"),this.options.responsive?this.resize():Zg(this,this.options.devicePixelRatio),this.bindEvents(),this.notifyPlugins("afterInit"),this}clear(){return Hg(this.canvas,this.ctx),this}stop(){return ss.stop(this),this}resize(e,n){ss.running(this)?this._resizeBeforeDraw={width:e,height:n}:this._resize(e,n);}_resize(e,n){let r=this.options,i=this.canvas,o=r.maintainAspectRatio&&this.aspectRatio,s=this.platform.getMaximumSize(i,e,n,o),c=r.devicePixelRatio||this.platform.getDevicePixelRatio(),p=this.width?"resize":"attach";this.width=s.width,this.height=s.height,this._aspectRatio=this.aspectRatio,Zg(this,c,true)&&(this.notifyPlugins("resize",{size:s}),Qe(r.onResize,[this,s],this),this.attached&&this._doResize(p)&&this.render());}ensureScalesHaveIDs(){let n=this.options.scales||{};tn(n,(r,i)=>{r.id=i;});}buildOrUpdateScales(){let e=this.options,n=e.scales,r=this.scales,i=Object.keys(r).reduce((s,c)=>(s[c]=false,s),{}),o=[];n&&(o=o.concat(Object.keys(n).map(s=>{let c=n[s],p=e1(s,c),h=p==="r",v=p==="x";return {options:c,dposition:h?"chartArea":v?"bottom":"left",dtype:h?"radialLinear":v?"category":"linear"}}))),tn(o,s=>{let c=s.options,p=c.id,h=e1(p,c),v=me(c.type,s.dtype);(c.position===void 0||hw(c.position,h)!==hw(s.dposition))&&(c.position=s.dposition),i[p]=true;let P=null;if(p in r&&r[p].type===v)P=r[p];else {let x=Ca.getScale(v);P=new x({id:p,type:v,ctx:this.ctx,chart:this}),r[P.id]=P;}P.init(c,e);}),tn(i,(s,c)=>{s||delete r[c];}),tn(r,s=>{yo.configure(this,s,s.options),yo.addBox(this,s);});}_updateMetasets(){let e=this._metasets,n=this.data.datasets.length,r=e.length;if(e.sort((i,o)=>i.index-o.index),r>n){for(let i=n;i<r;++i)this._destroyDatasetMeta(i);e.splice(n,r-n);}this._sortedMetasets=e.slice(0).sort(mw("order","index"));}_removeUnreferencedMetasets(){let{_metasets:e,data:{datasets:n}}=this;e.length>n.length&&delete this._stacks,e.forEach((r,i)=>{n.filter(o=>o===r._dataset).length===0&&this._destroyDatasetMeta(i);});}buildOrUpdateControllers(){let e=[],n=this.data.datasets,r,i;for(this._removeUnreferencedMetasets(),r=0,i=n.length;r<i;r++){let o=n[r],s=this.getDatasetMeta(r),c=o.type||this.config.type;if(s.type&&s.type!==c&&(this._destroyDatasetMeta(r),s=this.getDatasetMeta(r)),s.type=c,s.indexAxis=o.indexAxis||t1(c,this.options),s.order=o.order||0,s.index=r,s.label=""+o.label,s.visible=this.isDatasetVisible(r),s.controller)s.controller.updateIndex(r),s.controller.linkScales();else {let p=Ca.getController(c),{datasetElementType:h,dataElementType:v}=ke.datasets[c];Object.assign(p.prototype,{dataElementType:Ca.getElement(v),datasetElementType:h&&Ca.getElement(h)}),s.controller=new p(this,r),e.push(s.controller);}}return this._updateMetasets(),e}_resetElements(){tn(this.data.datasets,(e,n)=>{this.getDatasetMeta(n).controller.reset();},this);}reset(){this._resetElements(),this.notifyPlugins("reset");}update(e){let n=this.config;n.update();let r=this._options=n.createResolver(n.chartOptionScopes(),this.getContext()),i=this._animationsDisabled=!r.animation;if(this._updateScales(),this._checkEventBindings(),this._updateHiddenIndices(),this._plugins.invalidate(),this.notifyPlugins("beforeUpdate",{mode:e,cancelable:true})===false)return;let o=this.buildOrUpdateControllers();this.notifyPlugins("beforeElementsUpdate");let s=0;for(let h=0,v=this.data.datasets.length;h<v;h++){let{controller:P}=this.getDatasetMeta(h),x=!i&&o.indexOf(P)===-1;P.buildOrUpdateElements(x),s=Math.max(+P.getMaxOverflow(),s);}s=this._minPadding=r.layout.autoPadding?s:0,this._updateLayout(s),i||tn(o,h=>{h.reset();}),this._updateDatasets(e),this.notifyPlugins("afterUpdate",{mode:e}),this._layers.sort(mw("z","_idx"));let{_active:c,_lastEvent:p}=this;p?this._eventHandler(p,true):c.length&&this._updateHoverStyles(c,c,true),this.render();}_updateScales(){tn(this.scales,e=>{yo.removeBox(this,e);}),this.ensureScalesHaveIDs(),this.buildOrUpdateScales();}_checkEventBindings(){let e=this.options,n=new Set(Object.keys(this._listeners)),r=new Set(e.events);(!Rg(n,r)||!!this._responsiveListeners!==e.responsive)&&(this.unbindEvents(),this.bindEvents());}_updateHiddenIndices(){let{_hiddenIndices:e}=this,n=this._getUniformDataChanges()||[];for(let{method:r,start:i,count:o}of n){let s=r==="_removeElements"?-o:o;k4(e,i,s);}}_getUniformDataChanges(){let e=this._dataChanges;if(!e||!e.length)return;this._dataChanges=[];let n=this.data.datasets.length,r=o=>new Set(e.filter(s=>s[0]===o).map((s,c)=>c+","+s.splice(1).join(","))),i=r(0);for(let o=1;o<n;o++)if(!Rg(i,r(o)))return;return Array.from(i).map(o=>o.split(",")).map(o=>({method:o[1],start:+o[2],count:+o[3]}))}_updateLayout(e){if(this.notifyPlugins("beforeLayout",{cancelable:true})===false)return;yo.update(this,this.width,this.height,e);let n=this.chartArea,r=n.width<=0||n.height<=0;this._layers=[],tn(this.boxes,i=>{r&&i.position==="chartArea"||(i.configure&&i.configure(),this._layers.push(...i._layers()));},this),this._layers.forEach((i,o)=>{i._idx=o;}),this.notifyPlugins("afterLayout");}_updateDatasets(e){if(this.notifyPlugins("beforeDatasetsUpdate",{mode:e,cancelable:true})!==false){for(let n=0,r=this.data.datasets.length;n<r;++n)this.getDatasetMeta(n).controller.configure();for(let n=0,r=this.data.datasets.length;n<r;++n)this._updateDataset(n,Gr(e)?e({datasetIndex:n}):e);this.notifyPlugins("afterDatasetsUpdate",{mode:e});}}_updateDataset(e,n){let r=this.getDatasetMeta(e),i={meta:r,index:e,mode:n,cancelable:true};this.notifyPlugins("beforeDatasetUpdate",i)!==false&&(r.controller._update(n),i.cancelable=false,this.notifyPlugins("afterDatasetUpdate",i));}render(){this.notifyPlugins("beforeRender",{cancelable:true})!==false&&(ss.has(this)?this.attached&&!ss.running(this)&&ss.start(this):(this.draw(),gw({chart:this})));}draw(){let e;if(this._resizeBeforeDraw){let{width:r,height:i}=this._resizeBeforeDraw;this._resize(r,i),this._resizeBeforeDraw=null;}if(this.clear(),this.width<=0||this.height<=0||this.notifyPlugins("beforeDraw",{cancelable:true})===false)return;let n=this._layers;for(e=0;e<n.length&&n[e].z<=0;++e)n[e].draw(this.chartArea);for(this._drawDatasets();e<n.length;++e)n[e].draw(this.chartArea);this.notifyPlugins("afterDraw");}_getSortedDatasetMetas(e){let n=this._sortedMetasets,r=[],i,o;for(i=0,o=n.length;i<o;++i){let s=n[i];(!e||s.visible)&&r.push(s);}return r}getSortedVisibleDatasetMetas(){return this._getSortedDatasetMetas(true)}_drawDatasets(){if(this.notifyPlugins("beforeDatasetsDraw",{cancelable:true})===false)return;let e=this.getSortedVisibleDatasetMetas();for(let n=e.length-1;n>=0;--n)this._drawDataset(e[n]);this.notifyPlugins("afterDatasetsDraw");}_drawDataset(e){let n=this.ctx,r=e._clip,i=!r.disabled,o=this.chartArea,s={meta:e,index:e.index,cancelable:true};this.notifyPlugins("beforeDatasetDraw",s)!==false&&(i&&fl(n,{left:r.left===false?0:o.left-r.left,right:r.right===false?this.width:o.right+r.right,top:r.top===false?0:o.top-r.top,bottom:r.bottom===false?this.height:o.bottom+r.bottom}),e.controller.draw(),i&&hl(n),s.cancelable=false,this.notifyPlugins("afterDatasetDraw",s));}isPointInArea(e){return xc(e,this.chartArea,this._minPadding)}getElementsAtEventForMode(e,n,r,i){let o=Q6.modes[n];return typeof o=="function"?o(this,e,r,i):[]}getDatasetMeta(e){let n=this.data.datasets[e],r=this._metasets,i=r.filter(o=>o&&o._dataset===n).pop();return i||(i={type:null,data:[],dataset:null,controller:null,hidden:null,xAxisID:null,yAxisID:null,order:n&&n.order||0,index:e,_dataset:n,_parsed:[],_sorted:false},r.push(i)),i}getContext(){return this.$context||(this.$context=ba(null,{chart:this,type:"chart"}))}getVisibleDatasetCount(){return this.getSortedVisibleDatasetMetas().length}isDatasetVisible(e){let n=this.data.datasets[e];if(!n)return false;let r=this.getDatasetMeta(e);return typeof r.hidden=="boolean"?!r.hidden:!n.hidden}setDatasetVisibility(e,n){let r=this.getDatasetMeta(e);r.hidden=!n;}toggleDataVisibility(e){this._hiddenIndices[e]=!this._hiddenIndices[e];}getDataVisibility(e){return !this._hiddenIndices[e]}_updateVisibility(e,n,r){let i=r?"show":"hide",o=this.getDatasetMeta(e),s=o.controller._resolveAnimations(void 0,i);Fn(n)?(o.data[n].hidden=!r,this.update()):(this.setDatasetVisibility(e,r),s.update(o,{visible:r}),this.update(c=>c.datasetIndex===e?i:void 0));}hide(e,n){this._updateVisibility(e,n,false);}show(e,n){this._updateVisibility(e,n,true);}_destroyDatasetMeta(e){let n=this._metasets[e];n&&n.controller&&n.controller._destroy(),delete this._metasets[e];}_stop(){let e,n;for(this.stop(),ss.remove(this),e=0,n=this.data.datasets.length;e<n;++e)this._destroyDatasetMeta(e);}destroy(){this.notifyPlugins("beforeDestroy");let{canvas:e,ctx:n}=this;this._stop(),this.config.clearCache(),e&&(this.unbindEvents(),Hg(e,n),this.platform.releaseContext(n),this.canvas=null,this.ctx=null),this.notifyPlugins("destroy"),delete fy[this.id],this.notifyPlugins("afterDestroy");}toBase64Image(...e){return this.canvas.toDataURL(...e)}bindEvents(){this.bindUserEvents(),this.options.responsive?this.bindResponsiveEvents():this.attached=true;}bindUserEvents(){let e=this._listeners,n=this.platform,r=(o,s)=>{n.addEventListener(this,o,s),e[o]=s;},i=(o,s,c)=>{o.offsetX=s,o.offsetY=c,this._eventHandler(o);};tn(this.options.events,o=>r(o,i));}bindResponsiveEvents(){this._responsiveListeners||(this._responsiveListeners={});let e=this._responsiveListeners,n=this.platform,r=(p,h)=>{n.addEventListener(this,p,h),e[p]=h;},i=(p,h)=>{e[p]&&(n.removeEventListener(this,p,h),delete e[p]);},o=(p,h)=>{this.canvas&&this.resize(p,h);},s,c=()=>{i("attach",c),this.attached=true,this.resize(),r("resize",o),r("detach",s);};s=()=>{this.attached=false,i("resize",o),this._stop(),this._resize(0,0),r("attach",c);},n.isAttached(this.canvas)?c():s();}unbindEvents(){tn(this._listeners,(e,n)=>{this.platform.removeEventListener(this,n,e);}),this._listeners={},tn(this._responsiveListeners,(e,n)=>{this.platform.removeEventListener(this,n,e);}),this._responsiveListeners=void 0;}updateHoverStyle(e,n,r){let i=r?"set":"remove",o,s,c,p;for(n==="dataset"&&(o=this.getDatasetMeta(e[0].datasetIndex),o.controller["_"+i+"DatasetHoverStyle"]()),c=0,p=e.length;c<p;++c){s=e[c];let h=s&&this.getDatasetMeta(s.datasetIndex).controller;h&&h[i+"HoverStyle"](s.element,s.datasetIndex,s.index);}}getActiveElements(){return this._active||[]}setActiveElements(e){let n=this._active||[],r=e.map(({datasetIndex:o,index:s})=>{let c=this.getDatasetMeta(o);if(!c)throw new Error("No dataset found at index "+o);return {datasetIndex:o,element:c.data[s],index:s}});!id(r,n)&&(this._active=r,this._lastEvent=null,this._updateHoverStyles(r,n));}notifyPlugins(e,n,r){return this._plugins.notify(this,e,n,r)}_updateHoverStyles(e,n,r){let i=this.options.hover,o=(p,h)=>p.filter(v=>!h.some(P=>v.datasetIndex===P.datasetIndex&&v.index===P.index)),s=o(n,e),c=r?e:o(e,n);s.length&&this.updateHoverStyle(s,i.mode,false),c.length&&i.mode&&this.updateHoverStyle(c,i.mode,true);}_eventHandler(e,n){let r={event:e,replay:n,cancelable:true,inChartArea:this.isPointInArea(e)},i=s=>(s.options.events||this.options.events).includes(e.native.type);if(this.notifyPlugins("beforeEvent",r,i)===false)return;let o=this._handleEvent(e,n,r.inChartArea);return r.cancelable=false,this.notifyPlugins("afterEvent",r,i),(o||r.changed)&&this.render(),this}_handleEvent(e,n,r){let{_active:i=[],options:o}=this,s=n,c=this._getActiveElements(e,i,r,s),p=h0(e),h=D4(e,this._lastEvent,r,p);r&&(this._lastEvent=null,Qe(o.onHover,[e,c,this],this),p&&Qe(o.onClick,[e,c,this],this));let v=!id(c,i);return (v||n)&&(this._active=c,this._updateHoverStyles(c,i,n)),this._lastEvent=h,v}_getActiveElements(e,n,r,i){if(e.type==="mouseout")return [];if(!r)return n;let o=this.options.hover;return this.getElementsAtEventForMode(e,o.mode,o,i)}},yw=()=>tn(bo.instances,t=>t._plugins.invalidate()),gl=true;Object.defineProperties(bo,{defaults:{enumerable:gl,value:ke},instances:{enumerable:gl,value:fy},overrides:{enumerable:gl,value:pl},registry:{enumerable:gl,value:Ca},version:{enumerable:gl,value:T4},getChart:{enumerable:gl,value:Yw},register:{enumerable:gl,value:(...t)=>{Ca.add(...t),yw();}},unregister:{enumerable:gl,value:(...t)=>{Ca.remove(...t),yw();}}});function Qw(t,e,n){let{startAngle:r,pixelMargin:i,x:o,y:s,outerRadius:c,innerRadius:p}=e,h=i/c;t.beginPath(),t.arc(o,s,c,r-h,n+h),p>i?(h=i/p,t.arc(o,s,p,n+h,r-h,true)):t.arc(o,s,i,n+bn,r-bn),t.closePath(),t.clip();}function A4(t){return ff(t,["outerStart","outerEnd","innerStart","innerEnd"])}function O4(t,e,n,r){let i=A4(t.options.borderRadius),o=(n-e)/2,s=Math.min(o,r*e/2),c=p=>{let h=(n-Math.min(o,p))*r/2;return Nr(p,0,Math.min(o,h))};return {outerStart:c(i.outerStart),outerEnd:c(i.outerEnd),innerStart:Nr(i.innerStart,0,s),innerEnd:Nr(i.innerEnd,0,s)}}function od(t,e,n,r){return {x:n+t*Math.cos(e),y:r+t*Math.sin(e)}}function r1(t,e,n,r,i,o){let{x:s,y:c,startAngle:p,pixelMargin:h,innerRadius:v}=e,P=Math.max(e.outerRadius+r+n-h,0),x=v>0?v+r+n+h:0,T=0,I=i-p;if(r){let mt=v>0?v-r:0,Ct=P>0?P-r:0,jt=(mt+Ct)/2,Gt=jt!==0?I*jt/(jt+r):I;T=(I-Gt)/2;}let F=Math.max(.001,I*P-n/Be)/P,A=(I-F)/2,O=p+A+T,N=i-A-T,{outerStart:V,outerEnd:G,innerStart:X,innerEnd:nt}=O4(e,x,P,N-O),st=P-V,U=P-G,j=O+V/st,ut=N-G/U,Y=x+X,at=x+nt,pt=O+X/Y,dt=N-nt/at;if(t.beginPath(),o){if(t.arc(s,c,P,j,ut),G>0){let jt=od(U,ut,s,c);t.arc(jt.x,jt.y,G,ut,N+bn);}let mt=od(at,N,s,c);if(t.lineTo(mt.x,mt.y),nt>0){let jt=od(at,dt,s,c);t.arc(jt.x,jt.y,nt,N+bn,dt+Math.PI);}if(t.arc(s,c,x,N-nt/x,O+X/x,true),X>0){let jt=od(Y,pt,s,c);t.arc(jt.x,jt.y,X,pt+Math.PI,O-bn);}let Ct=od(st,O,s,c);if(t.lineTo(Ct.x,Ct.y),V>0){let jt=od(st,j,s,c);t.arc(jt.x,jt.y,V,O-bn,j);}}else {t.moveTo(s,c);let mt=Math.cos(j)*P+s,Ct=Math.sin(j)*P+c;t.lineTo(mt,Ct);let jt=Math.cos(ut)*P+s,Gt=Math.sin(ut)*P+c;t.lineTo(jt,Gt);}t.closePath();}function R4(t,e,n,r,i){let{fullCircles:o,startAngle:s,circumference:c}=e,p=e.endAngle;if(o){r1(t,e,n,r,s+rn,i);for(let h=0;h<o;++h)t.fill();isNaN(c)||(p=s+c%rn,c%rn===0&&(p+=rn));}return r1(t,e,n,r,p,i),t.fill(),p}function F4(t,e,n){let{x:r,y:i,startAngle:o,pixelMargin:s,fullCircles:c}=e,p=Math.max(e.outerRadius-s,0),h=e.innerRadius+s,v;for(n&&Qw(t,e,o+rn),t.beginPath(),t.arc(r,i,h,o+rn,o,true),v=0;v<c;++v)t.stroke();for(t.beginPath(),t.arc(r,i,p,o,o+rn),v=0;v<c;++v)t.stroke();}function M4(t,e,n,r,i,o){let{options:s}=e,{borderWidth:c,borderJoinStyle:p}=s,h=s.borderAlign==="inner";c&&(h?(t.lineWidth=c*2,t.lineJoin=p||"round"):(t.lineWidth=c,t.lineJoin=p||"bevel"),e.fullCircles&&F4(t,e,h),h&&Qw(t,e,i),r1(t,e,n,r,i,o),t.stroke());}var cs=class extends br{constructor(e){super(),this.options=void 0,this.circumference=void 0,this.startAngle=void 0,this.endAngle=void 0,this.innerRadius=void 0,this.outerRadius=void 0,this.pixelMargin=0,this.fullCircles=0,e&&Object.assign(this,e);}inRange(e,n,r){let i=this.getProps(["x","y"],r),{angle:o,distance:s}=Lg(i,{x:e,y:n}),{startAngle:c,endAngle:p,innerRadius:h,outerRadius:v,circumference:P}=this.getProps(["startAngle","endAngle","innerRadius","outerRadius","circumference"],r),x=this.options.spacing/2,I=me(P,p-c)>=rn||wc(o,c,p),F=Uo(s,h+x,v+x);return I&&F}getCenterPoint(e){let{x:n,y:r,startAngle:i,endAngle:o,innerRadius:s,outerRadius:c}=this.getProps(["x","y","startAngle","endAngle","innerRadius","outerRadius","circumference"],e),{offset:p,spacing:h}=this.options,v=(i+o)/2,P=(s+c+h+p)/2;return {x:n+Math.cos(v)*P,y:r+Math.sin(v)*P}}tooltipPosition(e){return this.getCenterPoint(e)}draw(e){let{options:n,circumference:r}=this,i=(n.offset||0)/2,o=(n.spacing||0)/2,s=n.circular;if(this.pixelMargin=n.borderAlign==="inner"?.33:0,this.fullCircles=r>rn?Math.floor(r/rn):0,r===0||this.innerRadius<0||this.outerRadius<0)return;e.save();let c=0;if(i){c=i/2;let h=(this.startAngle+this.endAngle)/2;e.translate(Math.cos(h)*c,Math.sin(h)*c),this.circumference>=Be&&(c=i);}e.fillStyle=n.backgroundColor,e.strokeStyle=n.borderColor;let p=R4(e,this,c,o,s);M4(e,this,c,o,p,s),e.restore();}};cs.id="arc";cs.defaults={borderAlign:"center",borderColor:"#fff",borderJoinStyle:void 0,borderRadius:0,borderWidth:2,offset:0,spacing:0,angle:void 0,circular:true};cs.defaultRoutes={backgroundColor:"backgroundColor"};function Kw(t,e,n=e){t.lineCap=me(n.borderCapStyle,e.borderCapStyle),t.setLineDash(me(n.borderDash,e.borderDash)),t.lineDashOffset=me(n.borderDashOffset,e.borderDashOffset),t.lineJoin=me(n.borderJoinStyle,e.borderJoinStyle),t.lineWidth=me(n.borderWidth,e.borderWidth),t.strokeStyle=me(n.borderColor,e.borderColor);}function N4(t,e,n){t.lineTo(n.x,n.y);}function L4(t){return t.stepped?I0:t.tension||t.cubicInterpolationMode==="monotone"?k0:N4}function Xw(t,e,n={}){let r=t.length,{start:i=0,end:o=r-1}=n,{start:s,end:c}=e,p=Math.max(i,s),h=Math.min(o,c),v=i<s&&o<s||i>c&&o>c;return {count:r,start:p,loop:e.loop,ilen:h<p&&!v?r+h-p:h-p}}function B4(t,e,n,r){let{points:i,options:o}=e,{count:s,start:c,loop:p,ilen:h}=Xw(i,n,r),v=L4(o),{move:P=true,reverse:x}=r||{},T,I,F;for(T=0;T<=h;++T)I=i[(c+(x?h-T:T))%s],!I.skip&&(P?(t.moveTo(I.x,I.y),P=false):v(t,F,I,x,o.stepped),F=I);return p&&(I=i[(c+(x?h:0))%s],v(t,F,I,x,o.stepped)),!!p}function U4(t,e,n,r){let i=e.points,{count:o,start:s,ilen:c}=Xw(i,n,r),{move:p=true,reverse:h}=r||{},v=0,P=0,x,T,I,F,A,O,N=G=>(s+(h?c-G:G))%o,V=()=>{F!==A&&(t.lineTo(v,A),t.lineTo(v,F),t.lineTo(v,O));};for(p&&(T=i[N(0)],t.moveTo(T.x,T.y)),x=0;x<=c;++x){if(T=i[N(x)],T.skip)continue;let G=T.x,X=T.y,nt=G|0;nt===I?(X<F?F=X:X>A&&(A=X),v=(P*v+G)/++P):(V(),t.lineTo(G,X),I=nt,P=0,F=A=X),O=X;}V();}function i1(t){let e=t.options,n=e.borderDash&&e.borderDash.length;return !t._decimated&&!t._loop&&!e.tension&&e.cubicInterpolationMode!=="monotone"&&!e.stepped&&!n?U4:B4}function $4(t){return t.stepped?N0:t.tension||t.cubicInterpolationMode==="monotone"?L0:ts}function G4(t,e,n,r){let i=e._path;i||(i=e._path=new Path2D,e.path(i,n,r)&&i.closePath()),Kw(t,e.options),t.stroke(i);}function j4(t,e,n,r){let{segments:i,options:o}=e,s=i1(e);for(let c of i)Kw(t,o,c.style),t.beginPath(),s(t,e,c,{start:n,end:n+r-1})&&t.closePath(),t.stroke();}var V4=typeof Path2D=="function";function z4(t,e,n,r){V4&&!e.options.segment?G4(t,e,n,r):j4(t,e,n,r);}var Go=class extends br{constructor(e){super(),this.animated=true,this.options=void 0,this._chart=void 0,this._loop=void 0,this._fullLoop=void 0,this._path=void 0,this._points=void 0,this._segments=void 0,this._decimated=false,this._pointsUpdated=false,this._datasetIndex=void 0,e&&Object.assign(this,e);}updateControlPoints(e,n){let r=this.options;if((r.tension||r.cubicInterpolationMode==="monotone")&&!r.stepped&&!this._pointsUpdated){let i=r.spanGaps?this._loop:this._fullLoop;R0(this._points,r,e,i,n),this._pointsUpdated=true;}}set points(e){this._points=e,delete this._segments,delete this._path,this._pointsUpdated=false;}get points(){return this._points}get segments(){return this._segments||(this._segments=B0(this,this.options.segment))}first(){let e=this.segments,n=this.points;return e.length&&n[e[0].start]}last(){let e=this.segments,n=this.points,r=e.length;return r&&n[e[r-1].end]}interpolate(e,n){let r=this.options,i=e[n],o=this.points,s=ry(this,{property:n,start:i,end:i});if(!s.length)return;let c=[],p=$4(r),h,v;for(h=0,v=s.length;h<v;++h){let{start:P,end:x}=s[h],T=o[P],I=o[x];if(T===I){c.push(T);continue}let F=Math.abs((i-T[n])/(I[n]-T[n])),A=p(T,I,F,r.stepped);A[n]=e[n],c.push(A);}return c.length===1?c[0]:c}pathSegment(e,n,r){return i1(this)(e,this,n,r)}path(e,n,r){let i=this.segments,o=i1(this),s=this._loop;n=n||0,r=r||this.points.length-n;for(let c of i)s&=o(e,this,c,{start:n,end:n+r-1});return !!s}draw(e,n,r,i){let o=this.options||{};(this.points||[]).length&&o.borderWidth&&(e.save(),z4(e,this,r,i),e.restore()),this.animated&&(this._pointsUpdated=false,this._path=void 0);}};Go.id="line";Go.defaults={borderCapStyle:"butt",borderDash:[],borderDashOffset:0,borderJoinStyle:"miter",borderWidth:3,capBezierPoints:true,cubicInterpolationMode:"default",fill:false,spanGaps:false,stepped:false,tension:0};Go.defaultRoutes={backgroundColor:"backgroundColor",borderColor:"borderColor"};Go.descriptors={_scriptable:true,_indexable:t=>t!=="borderDash"&&t!=="fill"};function bw(t,e,n,r){let i=t.options,{[n]:o}=t.getProps([n],r);return Math.abs(e-o)<i.radius+i.hitRadius}var us=class extends br{constructor(e){super(),this.options=void 0,this.parsed=void 0,this.skip=void 0,this.stop=void 0,e&&Object.assign(this,e);}inRange(e,n,r){let i=this.options,{x:o,y:s}=this.getProps(["x","y"],r);return Math.pow(e-o,2)+Math.pow(n-s,2)<Math.pow(i.hitRadius+i.radius,2)}inXRange(e,n){return bw(this,e,"x",n)}inYRange(e,n){return bw(this,e,"y",n)}getCenterPoint(e){let{x:n,y:r}=this.getProps(["x","y"],e);return {x:n,y:r}}size(e){e=e||this.options||{};let n=e.radius||0;n=Math.max(n,n&&e.hoverRadius||0);let r=n&&e.borderWidth||0;return (n+r)*2}draw(e,n){let r=this.options;this.skip||r.radius<.1||!xc(this,n,this.size(r)/2)||(e.strokeStyle=r.borderColor,e.lineWidth=r.borderWidth,e.fillStyle=r.backgroundColor,pf(e,r,this.x,this.y));}getRange(){let e=this.options||{};return e.radius+e.hitRadius}};us.id="point";us.defaults={borderWidth:1,hitRadius:1,hoverBorderWidth:1,hoverRadius:4,pointStyle:"circle",radius:3,rotation:0};us.defaultRoutes={backgroundColor:"backgroundColor",borderColor:"borderColor"};function Zw(t,e){let{x:n,y:r,base:i,width:o,height:s}=t.getProps(["x","y","base","width","height"],e),c,p,h,v,P;return t.horizontal?(P=s/2,c=Math.min(n,i),p=Math.max(n,i),h=r-P,v=r+P):(P=o/2,c=n-P,p=n+P,h=Math.min(r,i),v=Math.max(r,i)),{left:c,top:h,right:p,bottom:v}}function yl(t,e,n,r){return t?0:Nr(e,n,r)}function H4(t,e,n){let r=t.options.borderWidth,i=t.borderSkipped,o=qg(r);return {t:yl(i.top,o.top,0,n),r:yl(i.right,o.right,0,e),b:yl(i.bottom,o.bottom,0,n),l:yl(i.left,o.left,0,e)}}function W4(t,e,n){let{enableBorderRadius:r}=t.getProps(["enableBorderRadius"]),i=t.options.borderRadius,o=$o(i),s=Math.min(e,n),c=t.borderSkipped,p=r||Te(i);return {topLeft:yl(!p||c.top||c.left,o.topLeft,0,s),topRight:yl(!p||c.top||c.right,o.topRight,0,s),bottomLeft:yl(!p||c.bottom||c.left,o.bottomLeft,0,s),bottomRight:yl(!p||c.bottom||c.right,o.bottomRight,0,s)}}function q4(t){let e=Zw(t),n=e.right-e.left,r=e.bottom-e.top,i=H4(t,n/2,r/2),o=W4(t,n/2,r/2);return {outer:{x:e.left,y:e.top,w:n,h:r,radius:o},inner:{x:e.left+i.l,y:e.top+i.t,w:n-i.l-i.r,h:r-i.t-i.b,radius:{topLeft:Math.max(0,o.topLeft-Math.max(i.t,i.l)),topRight:Math.max(0,o.topRight-Math.max(i.t,i.r)),bottomLeft:Math.max(0,o.bottomLeft-Math.max(i.b,i.l)),bottomRight:Math.max(0,o.bottomRight-Math.max(i.b,i.r))}}}}function H0(t,e,n,r){let i=e===null,o=n===null,c=t&&!(i&&o)&&Zw(t,r);return c&&(i||Uo(e,c.left,c.right))&&(o||Uo(n,c.top,c.bottom))}function Y4(t){return t.topLeft||t.topRight||t.bottomLeft||t.bottomRight}function Q4(t,e){t.rect(e.x,e.y,e.w,e.h);}function W0(t,e,n={}){let r=t.x!==n.x?-e:0,i=t.y!==n.y?-e:0,o=(t.x+t.w!==n.x+n.w?e:0)-r,s=(t.y+t.h!==n.y+n.h?e:0)-i;return {x:t.x+r,y:t.y+i,w:t.w+o,h:t.h+s,radius:t.radius}}var ds=class extends br{constructor(e){super(),this.options=void 0,this.horizontal=void 0,this.base=void 0,this.width=void 0,this.height=void 0,this.inflateAmount=void 0,e&&Object.assign(this,e);}draw(e){let{inflateAmount:n,options:{borderColor:r,backgroundColor:i}}=this,{inner:o,outer:s}=q4(this),c=Y4(s.radius)?os:Q4;e.save(),(s.w!==o.w||s.h!==o.h)&&(e.beginPath(),c(e,W0(s,n,o)),e.clip(),c(e,W0(o,-n,s)),e.fillStyle=r,e.fill("evenodd")),e.beginPath(),c(e,W0(o,n)),e.fillStyle=i,e.fill(),e.restore();}inRange(e,n,r){return H0(this,e,n,r)}inXRange(e,n){return H0(this,e,null,n)}inYRange(e,n){return H0(this,null,e,n)}getCenterPoint(e){let{x:n,y:r,base:i,horizontal:o}=this.getProps(["x","y","base","horizontal"],e);return {x:o?(n+i)/2:n,y:o?r:(r+i)/2}}getRange(e){return e==="x"?this.width/2:this.height/2}};ds.id="bar";ds.defaults={borderSkipped:"start",borderWidth:0,borderRadius:0,inflateAmount:"auto",pointStyle:void 0};ds.defaultRoutes={backgroundColor:"backgroundColor",borderColor:"borderColor"};function K4(t,e,n){let r=t.segments,i=t.points,o=e.points,s=[];for(let c of r){let{start:p,end:h}=c;h=s1(p,h,i);let v=o1(n,i[p],i[h],c.loop);if(!e.segments){s.push({source:c,target:v,start:i[p],end:i[h]});continue}let P=ry(e,v);for(let x of P){let T=o1(n,o[x.start],o[x.end],x.loop),I=ny(c,i,T);for(let F of I)s.push({source:F,target:x,start:{[n]:vw(v,T,"start",Math.max)},end:{[n]:vw(v,T,"end",Math.min)}});}}return s}function o1(t,e,n,r){if(r)return;let i=e[t],o=n[t];return t==="angle"&&(i=ai(i),o=ai(o)),{property:t,start:i,end:o}}function X4(t,e){let{x:n=null,y:r=null}=t||{},i=e.points,o=[];return e.segments.forEach(({start:s,end:c})=>{c=s1(s,c,i);let p=i[s],h=i[c];r!==null?(o.push({x:p.x,y:r}),o.push({x:h.x,y:r})):n!==null&&(o.push({x:n,y:p.y}),o.push({x:n,y:h.y}));}),o}function s1(t,e,n){for(;e>t;e--){let r=n[e];if(!isNaN(r.x)&&!isNaN(r.y))break}return e}function vw(t,e,n,r){return t&&e?r(t[n],e[n]):t?t[n]:e?e[n]:0}function Jw(t,e){let n=[],r=false;return He(t)?(r=true,n=t):n=X4(t,e),n.length?new Go({points:n,options:{tension:0},_loop:r,_fullLoop:r}):null}function Cw(t){return t&&t.fill!==false}function Z4(t,e,n){let i=t[e].fill,o=[e],s;if(!n)return i;for(;i!==false&&o.indexOf(i)===-1;){if(!Mn(i))return i;if(s=t[i],!s)return false;if(s.visible)return i;o.push(i),i=s.fill;}return false}function J4(t,e,n){let r=rU(t);if(Te(r))return isNaN(r.value)?false:r;let i=parseFloat(r);return Mn(i)&&Math.floor(i)===i?tU(r[0],e,i,n):["origin","start","end","stack","shape"].indexOf(r)>=0&&r}function tU(t,e,n,r){return (t==="-"||t==="+")&&(n=e+n),n===e||n<0||n>=r?false:n}function eU(t,e){let n=null;return t==="start"?n=e.bottom:t==="end"?n=e.top:Te(t)?n=e.getPixelForValue(t.value):e.getBasePixel&&(n=e.getBasePixel()),n}function nU(t,e,n){let r;return t==="start"?r=n:t==="end"?r=e.options.reverse?e.min:e.max:Te(t)?r=t.value:r=e.getBaseValue(),r}function rU(t){let e=t.options,n=e.fill,r=me(n&&n.target,n);return r===void 0&&(r=!!e.backgroundColor),r===false||r===null?false:r===true?"origin":r}function iU(t){let{scale:e,index:n,line:r}=t,i=[],o=r.segments,s=r.points,c=oU(e,n);c.push(Jw({x:null,y:e.bottom},r));for(let p=0;p<o.length;p++){let h=o[p];for(let v=h.start;v<=h.end;v++)aU(i,s[v],c);}return new Go({points:i,options:{}})}function oU(t,e){let n=[],r=t.getMatchingVisibleMetas("line");for(let i=0;i<r.length;i++){let o=r[i];if(o.index===e)break;o.hidden||n.unshift(o.dataset);}return n}function aU(t,e,n){let r=[];for(let i=0;i<n.length;i++){let o=n[i],{first:s,last:c,point:p}=sU(o,e,"x");if(!(!p||s&&c)){if(s)r.unshift(p);else if(t.push(p),!c)break}}t.push(...r);}function sU(t,e,n){let r=t.interpolate(e,n);if(!r)return {};let i=r[n],o=t.segments,s=t.points,c=false,p=false;for(let h=0;h<o.length;h++){let v=o[h],P=s[v.start][n],x=s[v.end][n];if(Uo(i,P,x)){c=i===P,p=i===x;break}}return {first:c,last:p,point:r}}var hy=class{constructor(e){this.x=e.x,this.y=e.y,this.radius=e.radius;}pathSegment(e,n,r){let{x:i,y:o,radius:s}=this;return n=n||{start:0,end:rn},e.arc(i,o,s,n.end,n.start,true),!r.bounds}interpolate(e){let{x:n,y:r,radius:i}=this,o=e.angle;return {x:n+Math.cos(o)*i,y:r+Math.sin(o)*i,angle:o}}};function lU(t){let{chart:e,fill:n,line:r}=t;if(Mn(n))return cU(e,n);if(n==="stack")return iU(t);if(n==="shape")return true;let i=uU(t);return i instanceof hy?i:Jw(i,r)}function cU(t,e){let n=t.getDatasetMeta(e);return n&&t.isDatasetVisible(e)?n.dataset:null}function uU(t){return (t.scale||{}).getPointPositionForValue?pU(t):dU(t)}function dU(t){let{scale:e={},fill:n}=t,r=eU(n,e);if(Mn(r)){let i=e.isHorizontal();return {x:i?r:null,y:i?null:r}}return null}function pU(t){let{scale:e,fill:n}=t,r=e.options,i=e.getLabels().length,o=r.reverse?e.max:e.min,s=nU(n,e,o),c=[];if(r.grid.circular){let p=e.getPointPositionForValue(0,o);return new hy({x:p.x,y:p.y,radius:e.getDistanceFromCenterForValue(s)})}for(let p=0;p<i;++p)c.push(e.getPointPositionForValue(p,s));return c}function q0(t,e,n){let r=lU(e),{line:i,scale:o,axis:s}=e,c=i.options,p=c.fill,h=c.backgroundColor,{above:v=h,below:P=h}=p||{};r&&i.points.length&&(fl(t,n),fU(t,{line:i,target:r,above:v,below:P,area:n,scale:o,axis:s}),hl(t));}function fU(t,e){let{line:n,target:r,above:i,below:o,area:s,scale:c}=e,p=n._loop?"angle":e.axis;t.save(),p==="x"&&o!==i&&(Sw(t,r,s.top),Pw(t,{line:n,target:r,color:i,scale:c,property:p}),t.restore(),t.save(),Sw(t,r,s.bottom)),Pw(t,{line:n,target:r,color:o,scale:c,property:p}),t.restore();}function Sw(t,e,n){let{segments:r,points:i}=e,o=true,s=false;t.beginPath();for(let c of r){let{start:p,end:h}=c,v=i[p],P=i[s1(p,h,i)];o?(t.moveTo(v.x,v.y),o=false):(t.lineTo(v.x,n),t.lineTo(v.x,v.y)),s=!!e.pathSegment(t,c,{move:s}),s?t.closePath():t.lineTo(P.x,n);}t.lineTo(e.first().x,n),t.closePath(),t.clip();}function Pw(t,e){let{line:n,target:r,property:i,color:o,scale:s}=e,c=K4(n,r,i);for(let{source:p,target:h,start:v,end:P}of c){let{style:{backgroundColor:x=o}={}}=p,T=r!==true;t.save(),t.fillStyle=x,hU(t,s,T&&o1(i,v,P)),t.beginPath();let I=!!n.pathSegment(t,p),F;if(T){I?t.closePath():xw(t,r,P,i);let A=!!r.pathSegment(t,h,{move:I,reverse:true});F=I&&A,F||xw(t,r,v,i);}t.closePath(),t.fill(F?"evenodd":"nonzero"),t.restore();}}function hU(t,e,n){let{top:r,bottom:i}=e.chart.chartArea,{property:o,start:s,end:c}=n||{};o==="x"&&(t.beginPath(),t.rect(s,r,c-s,i-r),t.clip());}function xw(t,e,n,r){let i=e.interpolate(n,r);i&&t.lineTo(i.x,i.y);}var tI={id:"filler",afterDatasetsUpdate(t,e,n){let r=(t.data.datasets||[]).length,i=[],o,s,c,p;for(s=0;s<r;++s)o=t.getDatasetMeta(s),c=o.dataset,p=null,c&&c.options&&c instanceof Go&&(p={visible:t.isDatasetVisible(s),index:s,fill:J4(c,s,r),chart:t,axis:o.controller.options.indexAxis,scale:o.vScale,line:c}),o.$filler=p,i.push(p);for(s=0;s<r;++s)p=i[s],!(!p||p.fill===false)&&(p.fill=Z4(i,s,n.propagate));},beforeDraw(t,e,n){let r=n.drawTime==="beforeDraw",i=t.getSortedVisibleDatasetMetas(),o=t.chartArea;for(let s=i.length-1;s>=0;--s){let c=i[s].$filler;c&&(c.line.updateControlPoints(o,c.axis),r&&c.fill&&q0(t.ctx,c,o));}},beforeDatasetsDraw(t,e,n){if(n.drawTime!=="beforeDatasetsDraw")return;let r=t.getSortedVisibleDatasetMetas();for(let i=r.length-1;i>=0;--i){let o=r[i].$filler;Cw(o)&&q0(t.ctx,o,t.chartArea);}},beforeDatasetDraw(t,e,n){let r=e.meta.$filler;!Cw(r)||n.drawTime!=="beforeDatasetDraw"||q0(t.ctx,r,t.chartArea);},defaults:{propagate:true,drawTime:"beforeDatasetDraw"}},Ew=(t,e)=>{let{boxHeight:n=e,boxWidth:r=e}=t;return t.usePointStyle&&(n=Math.min(n,e),r=t.pointStyleWidth||Math.min(r,e)),{boxWidth:r,boxHeight:n,itemHeight:Math.max(e,n)}},mU=(t,e)=>t!==null&&e!==null&&t.datasetIndex===e.datasetIndex&&t.index===e.index,my=class extends br{constructor(e){super(),this._added=false,this.legendHitBoxes=[],this._hoveredItem=null,this.doughnutMode=false,this.chart=e.chart,this.options=e.options,this.ctx=e.ctx,this.legendItems=void 0,this.columnSizes=void 0,this.lineWidths=void 0,this.maxHeight=void 0,this.maxWidth=void 0,this.top=void 0,this.bottom=void 0,this.left=void 0,this.right=void 0,this.height=void 0,this.width=void 0,this._margins=void 0,this.position=void 0,this.weight=void 0,this.fullSize=void 0;}update(e,n,r){this.maxWidth=e,this.maxHeight=n,this._margins=r,this.setDimensions(),this.buildLabels(),this.fit();}setDimensions(){this.isHorizontal()?(this.width=this.maxWidth,this.left=this._margins.left,this.right=this.width):(this.height=this.maxHeight,this.top=this._margins.top,this.bottom=this.height);}buildLabels(){let e=this.options.labels||{},n=Qe(e.generateLabels,[this.chart],this)||[];e.filter&&(n=n.filter(r=>e.filter(r,this.chart.data))),e.sort&&(n=n.sort((r,i)=>e.sort(r,i,this.chart.data))),this.options.reverse&&n.reverse(),this.legendItems=n;}fit(){let{options:e,ctx:n}=this;if(!e.display){this.width=this.height=0;return}let r=e.labels,i=Sn(r.font),o=i.size,s=this._computeTitleHeight(),{boxWidth:c,itemHeight:p}=Ew(r,o),h,v;n.font=i.string,this.isHorizontal()?(h=this.maxWidth,v=this._fitRows(s,o,c,p)+10):(v=this.maxHeight,h=this._fitCols(s,o,c,p)+10),this.width=Math.min(h,e.maxWidth||this.maxWidth),this.height=Math.min(v,e.maxHeight||this.maxHeight);}_fitRows(e,n,r,i){let{ctx:o,maxWidth:s,options:{labels:{padding:c}}}=this,p=this.legendHitBoxes=[],h=this.lineWidths=[0],v=i+c,P=e;o.textAlign="left",o.textBaseline="middle";let x=-1,T=-v;return this.legendItems.forEach((I,F)=>{let A=r+n/2+o.measureText(I.text).width;(F===0||h[h.length-1]+A+2*c>s)&&(P+=v,h[h.length-(F>0?0:1)]=0,T+=v,x++),p[F]={left:0,top:T,row:x,width:A,height:i},h[h.length-1]+=A+c;}),P}_fitCols(e,n,r,i){let{ctx:o,maxHeight:s,options:{labels:{padding:c}}}=this,p=this.legendHitBoxes=[],h=this.columnSizes=[],v=s-e,P=c,x=0,T=0,I=0,F=0;return this.legendItems.forEach((A,O)=>{let N=r+n/2+o.measureText(A.text).width;O>0&&T+i+2*c>v&&(P+=x+c,h.push({width:x,height:T}),I+=x+c,F++,x=T=0),p[O]={left:I,top:T,col:F,width:N,height:i},x=Math.max(x,N),T+=i+c;}),P+=x,h.push({width:x,height:T}),P}adjustHitBoxes(){if(!this.options.display)return;let e=this._computeTitleHeight(),{legendHitBoxes:n,options:{align:r,labels:{padding:i},rtl:o}}=this,s=ml(o,this.left,this.width);if(this.isHorizontal()){let c=0,p=Lr(r,this.left+i,this.right-this.lineWidths[c]);for(let h of n)c!==h.row&&(c=h.row,p=Lr(r,this.left+i,this.right-this.lineWidths[c])),h.top+=this.top+e+i,h.left=s.leftForLtr(s.x(p),h.width),p+=h.width+i;}else {let c=0,p=Lr(r,this.top+e+i,this.bottom-this.columnSizes[c].height);for(let h of n)h.col!==c&&(c=h.col,p=Lr(r,this.top+e+i,this.bottom-this.columnSizes[c].height)),h.top=p,h.left+=this.left+i,h.left=s.leftForLtr(s.x(h.left),h.width),p+=h.height+i;}}isHorizontal(){return this.options.position==="top"||this.options.position==="bottom"}draw(){if(this.options.display){let e=this.ctx;fl(e,this),this._draw(),hl(e);}}_draw(){let{options:e,columnSizes:n,lineWidths:r,ctx:i}=this,{align:o,labels:s}=e,c=ke.color,p=ml(e.rtl,this.left,this.width),h=Sn(s.font),{color:v,padding:P}=s,x=h.size,T=x/2,I;this.drawTitle(),i.textAlign=p.textAlign("left"),i.textBaseline="middle",i.lineWidth=.5,i.font=h.string;let{boxWidth:F,boxHeight:A,itemHeight:O}=Ew(s,x),N=function(st,U,j){if(isNaN(F)||F<=0||isNaN(A)||A<0)return;i.save();let ut=me(j.lineWidth,1);if(i.fillStyle=me(j.fillStyle,c),i.lineCap=me(j.lineCap,"butt"),i.lineDashOffset=me(j.lineDashOffset,0),i.lineJoin=me(j.lineJoin,"miter"),i.lineWidth=ut,i.strokeStyle=me(j.strokeStyle,c),i.setLineDash(me(j.lineDash,[])),s.usePointStyle){let Y={radius:A*Math.SQRT2/2,pointStyle:j.pointStyle,rotation:j.rotation,borderWidth:ut},at=p.xPlus(st,F/2),pt=U+T;Wg(i,Y,at,pt,s.pointStyleWidth&&F);}else {let Y=U+Math.max((x-A)/2,0),at=p.leftForLtr(st,F),pt=$o(j.borderRadius);i.beginPath(),Object.values(pt).some(dt=>dt!==0)?os(i,{x:at,y:Y,w:F,h:A,radius:pt}):i.rect(at,Y,F,A),i.fill(),ut!==0&&i.stroke();}i.restore();},V=function(st,U,j){is(i,j.text,st,U+O/2,h,{strikethrough:j.hidden,textAlign:p.textAlign(j.textAlign)});},G=this.isHorizontal(),X=this._computeTitleHeight();G?I={x:Lr(o,this.left+P,this.right-r[0]),y:this.top+P+X,line:0}:I={x:this.left+P,y:Lr(o,this.top+X+P,this.bottom-n[0].height),line:0},ty(this.ctx,e.textDirection);let nt=O+P;this.legendItems.forEach((st,U)=>{i.strokeStyle=st.fontColor||v,i.fillStyle=st.fontColor||v;let j=i.measureText(st.text).width,ut=p.textAlign(st.textAlign||(st.textAlign=s.textAlign)),Y=F+T+j,at=I.x,pt=I.y;p.setWidth(this.width),G?U>0&&at+Y+P>this.right&&(pt=I.y+=nt,I.line++,at=I.x=Lr(o,this.left+P,this.right-r[I.line])):U>0&&pt+nt>this.bottom&&(at=I.x=at+n[I.line].width+P,I.line++,pt=I.y=Lr(o,this.top+X+P,this.bottom-n[I.line].height));let dt=p.x(at);N(dt,pt,st),at=P0(ut,at+F+T,G?at+Y:this.right,e.rtl),V(p.x(at),pt,st),G?I.x+=Y+P:I.y+=nt;}),ey(this.ctx,e.textDirection);}drawTitle(){let e=this.options,n=e.title,r=Sn(n.font),i=$n(n.padding);if(!n.display)return;let o=ml(e.rtl,this.left,this.width),s=this.ctx,c=n.position,p=r.size/2,h=i.top+p,v,P=this.left,x=this.width;if(this.isHorizontal())x=Math.max(...this.lineWidths),v=this.top+h,P=Lr(e.align,P,this.right-x);else {let I=this.columnSizes.reduce((F,A)=>Math.max(F,A.height),0);v=h+Lr(e.align,this.top,this.bottom-I-e.labels.padding-this._computeTitleHeight());}let T=Lr(c,P,P+x);s.textAlign=o.textAlign(uf(c)),s.textBaseline="middle",s.strokeStyle=n.color,s.fillStyle=n.color,s.font=r.string,is(s,n.text,T,v,r);}_computeTitleHeight(){let e=this.options.title,n=Sn(e.font),r=$n(e.padding);return e.display?n.lineHeight+r.height:0}_getLegendItemAt(e,n){let r,i,o;if(Uo(e,this.left,this.right)&&Uo(n,this.top,this.bottom)){for(o=this.legendHitBoxes,r=0;r<o.length;++r)if(i=o[r],Uo(e,i.left,i.left+i.width)&&Uo(n,i.top,i.top+i.height))return this.legendItems[r]}return null}handleEvent(e){let n=this.options;if(!gU(e.type,n))return;let r=this._getLegendItemAt(e.x,e.y);if(e.type==="mousemove"||e.type==="mouseout"){let i=this._hoveredItem,o=mU(i,r);i&&!o&&Qe(n.onLeave,[e,i,this],this),this._hoveredItem=r,r&&!o&&Qe(n.onHover,[e,r,this],this);}else r&&Qe(n.onClick,[e,r,this],this);}};function gU(t,e){return !!((t==="mousemove"||t==="mouseout")&&(e.onHover||e.onLeave)||e.onClick&&(t==="click"||t==="mouseup"))}var eI={id:"legend",_element:my,start(t,e,n){let r=t.legend=new my({ctx:t.ctx,options:n,chart:t});yo.configure(t,r,n),yo.addBox(t,r);},stop(t){yo.removeBox(t,t.legend),delete t.legend;},beforeUpdate(t,e,n){let r=t.legend;yo.configure(t,r,n),r.options=n;},afterUpdate(t){let e=t.legend;e.buildLabels(),e.adjustHitBoxes();},afterEvent(t,e){e.replay||t.legend.handleEvent(e.event);},defaults:{display:true,position:"top",align:"center",fullSize:true,reverse:false,weight:1e3,onClick(t,e,n){let r=e.datasetIndex,i=n.chart;i.isDatasetVisible(r)?(i.hide(r),e.hidden=true):(i.show(r),e.hidden=false);},onHover:null,onLeave:null,labels:{color:t=>t.chart.options.color,boxWidth:40,padding:10,generateLabels(t){let e=t.data.datasets,{labels:{usePointStyle:n,pointStyle:r,textAlign:i,color:o}}=t.legend.options;return t._getSortedDatasetMetas().map(s=>{let c=s.controller.getStyle(n?0:void 0),p=$n(c.borderWidth);return {text:e[s.index].label,fillStyle:c.backgroundColor,fontColor:o,hidden:!s.visible,lineCap:c.borderCapStyle,lineDash:c.borderDash,lineDashOffset:c.borderDashOffset,lineJoin:c.borderJoinStyle,lineWidth:(p.width+p.height)/4,strokeStyle:c.borderColor,pointStyle:r||c.pointStyle,rotation:c.rotation,textAlign:i||c.textAlign,borderRadius:0,datasetIndex:s.index}},this)}},title:{color:t=>t.chart.options.color,display:false,position:"center",text:""}},descriptors:{_scriptable:t=>!t.startsWith("on"),labels:{_scriptable:t=>!["generateLabels","filter","sort"].includes(t)}}},gy=class extends br{constructor(e){super(),this.chart=e.chart,this.options=e.options,this.ctx=e.ctx,this._padding=void 0,this.top=void 0,this.bottom=void 0,this.left=void 0,this.right=void 0,this.width=void 0,this.height=void 0,this.position=void 0,this.weight=void 0,this.fullSize=void 0;}update(e,n){let r=this.options;if(this.left=0,this.top=0,!r.display){this.width=this.height=this.right=this.bottom=0;return}this.width=this.right=e,this.height=this.bottom=n;let i=He(r.text)?r.text.length:1;this._padding=$n(r.padding);let o=i*Sn(r.font).lineHeight+this._padding.height;this.isHorizontal()?this.height=o:this.width=o;}isHorizontal(){let e=this.options.position;return e==="top"||e==="bottom"}_drawArgs(e){let{top:n,left:r,bottom:i,right:o,options:s}=this,c=s.align,p=0,h,v,P;return this.isHorizontal()?(v=Lr(c,r,o),P=n+e,h=o-r):(s.position==="left"?(v=r+e,P=Lr(c,i,n),p=Be*-0.5):(v=o-e,P=Lr(c,n,i),p=Be*.5),h=i-n),{titleX:v,titleY:P,maxWidth:h,rotation:p}}draw(){let e=this.ctx,n=this.options;if(!n.display)return;let r=Sn(n.font),o=r.lineHeight/2+this._padding.top,{titleX:s,titleY:c,maxWidth:p,rotation:h}=this._drawArgs(o);is(e,n.text,0,0,r,{color:n.color,maxWidth:p,rotation:h,textAlign:uf(n.align),textBaseline:"middle",translation:[s,c]});}};function yU(t,e){let n=new gy({ctx:t.ctx,options:e,chart:t});yo.configure(t,n,e),yo.addBox(t,n),t.titleBlock=n;}var nI={id:"title",_element:gy,start(t,e,n){yU(t,n);},stop(t){let e=t.titleBlock;yo.removeBox(t,e),delete t.titleBlock;},beforeUpdate(t,e,n){let r=t.titleBlock;yo.configure(t,r,n),r.options=n;},defaults:{align:"center",display:false,font:{weight:"bold"},fullSize:true,padding:10,position:"top",text:"",weight:2e3},defaultRoutes:{color:"color"},descriptors:{_scriptable:true,_indexable:false}};var Pf={average(t){if(!t.length)return false;let e,n,r=0,i=0,o=0;for(e=0,n=t.length;e<n;++e){let s=t[e].element;if(s&&s.hasValue()){let c=s.tooltipPosition();r+=c.x,i+=c.y,++o;}}return {x:r/o,y:i/o}},nearest(t,e){if(!t.length)return false;let n=e.x,r=e.y,i=Number.POSITIVE_INFINITY,o,s,c;for(o=0,s=t.length;o<s;++o){let p=t[o].element;if(p&&p.hasValue()){let h=p.getCenterPoint(),v=ns(e,h);v<i&&(i=v,c=p);}}if(c){let p=c.tooltipPosition();n=p.x,r=p.y;}return {x:n,y:r}}};function va(t,e){return e&&(He(e)?Array.prototype.push.apply(t,e):t.push(e)),t}function ls(t){return (typeof t=="string"||t instanceof String)&&t.indexOf(`
5646
+ `;function pT({currencyId:t,localization:e,decimalPlaces:n,showUnits:r=true,showSymbol:i=false}){var v;let o=fc(Mo),s=ve({optional:true}),c=s==null?void 0:s.theme,p=(v=e==null?void 0:e.title)!=null?v:cT.title,h=jsxRuntime.jsx(J5,{className:"stigg-credit-balance-container",children:jsxRuntime.jsxs(tB,{className:"stigg-credit-balance-card",children:[jsxRuntime.jsx(rt,{variant:"h6",color:"primary",className:"stigg-credit-balance-title",children:p}),jsxRuntime.jsx(lT,{currencyId:t,decimalPlaces:n,showUnits:r,showSymbol:i})]})});return o?h:jsxRuntime.jsx(vi,{componentTheme:c,children:h})}function Bo(){}var p0=(function(){let t=0;return function(){return t++}})();function Le(t){return t===null||typeof t=="undefined"}function He(t){if(Array.isArray&&Array.isArray(t))return true;let e=Object.prototype.toString.call(t);return e.slice(0,7)==="[object"&&e.slice(-6)==="Array]"}function Te(t){return t!==null&&Object.prototype.toString.call(t)==="[object Object]"}var Mn=t=>(typeof t=="number"||t instanceof Number)&&isFinite(+t);function xi(t,e){return Mn(t)?t:e}function me(t,e){return typeof t=="undefined"?e:t}var f0=(t,e)=>typeof t=="string"&&t.endsWith("%")?parseFloat(t)/100:t/e,Og=(t,e)=>typeof t=="string"&&t.endsWith("%")?parseFloat(t)/100*e:+t;function Qe(t,e,n){if(t&&typeof t.call=="function")return t.apply(n,e)}function tn(t,e,n,r){let i,o,s;if(He(t))if(o=t.length,r);else for(i=0;i<o;i++)e.call(n,t[i],i);else if(Te(t))for(s=Object.keys(t),o=s.length,i=0;i<o;i++)e.call(n,t[s[i]],s[i]);}function id(t,e){let n,r,i,o;if(!t||!e||t.length!==e.length)return false;for(n=0,r=t.length;n<r;++n)if(i=t[n],o=e[n],i.datasetIndex!==o.datasetIndex||i.index!==o.index)return false;return true}function of(t){if(He(t))return t.map(of);if(Te(t)){let e=Object.create(null),n=Object.keys(t),r=n.length,i=0;for(;i<r;++i)e[n[i]]=of(t[n[i]]);return e}return t}function TT(t){return ["__proto__","prototype","constructor"].indexOf(t)===-1}function wT(t,e,n,r){if(!TT(t))return;let i=e[t],o=n[t];Te(i)&&Te(o)?ji(i,o,r):e[t]=of(o);}function ji(t,e,n){let r=He(e)?e:[e],i=r.length;if(!Te(t))return t;n=n||{};let o=n.merger||wT;for(let s=0;s<i;++s){if(e=r[s],!Te(e))continue;let c=Object.keys(e);for(let p=0,h=c.length;p<h;++p)o(c[p],t,e,n);}return t}function Ec(t,e){return ji(t,e,{merger:IT})}function IT(t,e,n){if(!TT(t))return;let r=e[t],i=n[t];Te(r)&&Te(i)?Ec(r,i):Object.prototype.hasOwnProperty.call(e,t)||(e[t]=of(i));}var fT={"":t=>t,x:t=>t.x,y:t=>t.y};function ya(t,e){return (fT[e]||(fT[e]=nB(e)))(t)}function nB(t){let e=kT(t);return n=>{for(let r of e){if(r==="")break;n=n&&n[r];}return n}}function kT(t){let e=t.split("."),n=[],r="";for(let i of e)r+=i,r.endsWith("\\")?r=r.slice(0,-1)+".":(n.push(r),r="");return n}function sf(t){return t.charAt(0).toUpperCase()+t.slice(1)}var Fn=t=>typeof t!="undefined",Gr=t=>typeof t=="function",Rg=(t,e)=>{if(t.size!==e.size)return false;for(let n of t)if(!e.has(n))return false;return true};function h0(t){return t.type==="mouseup"||t.type==="click"||t.type==="contextmenu"}var Be=Math.PI,rn=2*Be,DT=rn+Be,af=Number.POSITIVE_INFINITY,lf=Be/180,bn=Be/2,mo=Be/4,ed=Be*2/3,Ei=Math.log10,go=Math.sign;function Fg(t){let e=Math.round(t);t=_c(t,e,t/1e3)?e:t;let n=Math.pow(10,Math.floor(Ei(t))),r=t/n;return (r<=1?1:r<=2?2:r<=5?5:10)*n}function m0(t){let e=[],n=Math.sqrt(t),r;for(r=1;r<n;r++)t%r===0&&(e.push(r),e.push(t/r));return n===(n|0)&&e.push(n),e.sort((i,o)=>i-o).pop(),e}function Vi(t){return !isNaN(parseFloat(t))&&isFinite(t)}function _c(t,e,n){return Math.abs(t-e)<n}function g0(t,e){let n=Math.round(t);return n-e<=t&&n+e>=t}function Mg(t,e,n){let r,i,o;for(r=0,i=t.length;r<i;r++)o=t[r][n],isNaN(o)||(e.min=Math.min(e.min,o),e.max=Math.max(e.max,o));}function Qn(t){return t*(Be/180)}function Tc(t){return t*(180/Be)}function Ng(t){if(!Mn(t))return;let e=1,n=0;for(;Math.round(t*e)/e!==t;)e*=10,n++;return n}function Lg(t,e){let n=e.x-t.x,r=e.y-t.y,i=Math.sqrt(n*n+r*r),o=Math.atan2(r,n);return o<-0.5*Be&&(o+=rn),{angle:o,distance:i}}function ns(t,e){return Math.sqrt(Math.pow(e.x-t.x,2)+Math.pow(e.y-t.y,2))}function AT(t,e){return (t-e+DT)%rn-Be}function ai(t){return (t%rn+rn)%rn}function wc(t,e,n,r){let i=ai(t),o=ai(e),s=ai(n),c=ai(o-i),p=ai(s-i),h=ai(i-o),v=ai(i-s);return i===o||i===s||r&&o===s||c>p&&h<v}function Nr(t,e,n){return Math.max(e,Math.min(n,t))}function y0(t){return Nr(t,-32768,32767)}function Uo(t,e,n,r=1e-6){return t>=Math.min(e,n)-r&&t<=Math.max(e,n)+r}function cf(t,e,n){n=n||(s=>t[s]<e);let r=t.length-1,i=0,o;for(;r-i>1;)o=i+r>>1,n(o)?i=o:r=o;return {lo:i,hi:r}}var es=(t,e,n,r)=>cf(t,n,r?i=>t[i][e]<=n:i=>t[i][e]<n),b0=(t,e,n)=>cf(t,n,r=>t[r][e]>=n);function v0(t,e,n){let r=0,i=t.length;for(;r<i&&t[r]<e;)r++;for(;i>r&&t[i-1]>n;)i--;return r>0||i<t.length?t.slice(r,i):t}var OT=["push","pop","shift","splice","unshift"];function C0(t,e){if(t._chartjs){t._chartjs.listeners.push(e);return}Object.defineProperty(t,"_chartjs",{configurable:true,enumerable:false,value:{listeners:[e]}}),OT.forEach(n=>{let r="_onData"+sf(n),i=t[n];Object.defineProperty(t,n,{configurable:true,enumerable:false,value(...o){let s=i.apply(this,o);return t._chartjs.listeners.forEach(c=>{typeof c[r]=="function"&&c[r](...o);}),s}});});}function Bg(t,e){let n=t._chartjs;if(!n)return;let r=n.listeners,i=r.indexOf(e);i!==-1&&r.splice(i,1),!(r.length>0)&&(OT.forEach(o=>{delete t[o];}),delete t._chartjs);}function Ug(t){let e=new Set,n,r;for(n=0,r=t.length;n<r;++n)e.add(t[n]);return e.size===r?t:Array.from(e)}var $g=(function(){return typeof window=="undefined"?function(t){return t()}:window.requestAnimationFrame})();function Gg(t,e,n){let r=n||(s=>Array.prototype.slice.call(s)),i=false,o=[];return function(...s){o=r(s),i||(i=true,$g.call(window,()=>{i=false,t.apply(e,o);}));}}function S0(t,e){let n;return function(...r){return e?(clearTimeout(n),n=setTimeout(t,e,r)):t.apply(this,r),e}}var uf=t=>t==="start"?"left":t==="end"?"right":"center",Lr=(t,e,n)=>t==="start"?e:t==="end"?n:(e+n)/2,P0=(t,e,n,r)=>t===(r?"left":"right")?n:t==="center"?(e+n)/2:e;function jg(t,e,n){let r=e.length,i=0,o=r;if(t._sorted){let{iScale:s,_parsed:c}=t,p=s.axis,{min:h,max:v,minDefined:P,maxDefined:x}=s.getUserBounds();P&&(i=Nr(Math.min(es(c,s.axis,h).lo,n?r:es(e,p,s.getPixelForValue(h)).lo),0,r-1)),x?o=Nr(Math.max(es(c,s.axis,v,true).hi+1,n?0:es(e,p,s.getPixelForValue(v),true).hi+1),i,r)-i:o=r-i;}return {start:i,count:o}}function Vg(t){let{xScale:e,yScale:n,_scaleRanges:r}=t,i={xmin:e.min,xmax:e.max,ymin:n.min,ymax:n.max};if(!r)return t._scaleRanges=i,true;let o=r.xmin!==e.min||r.xmax!==e.max||r.ymin!==n.min||r.ymax!==n.max;return Object.assign(r,i),o}var _g=t=>t===0||t===1,hT=(t,e,n)=>-(Math.pow(2,10*(t-=1))*Math.sin((t-e)*rn/n)),mT=(t,e,n)=>Math.pow(2,-10*t)*Math.sin((t-e)*rn/n)+1,Sc={linear:t=>t,easeInQuad:t=>t*t,easeOutQuad:t=>-t*(t-2),easeInOutQuad:t=>(t/=.5)<1?.5*t*t:-0.5*(--t*(t-2)-1),easeInCubic:t=>t*t*t,easeOutCubic:t=>(t-=1)*t*t+1,easeInOutCubic:t=>(t/=.5)<1?.5*t*t*t:.5*((t-=2)*t*t+2),easeInQuart:t=>t*t*t*t,easeOutQuart:t=>-((t-=1)*t*t*t-1),easeInOutQuart:t=>(t/=.5)<1?.5*t*t*t*t:-0.5*((t-=2)*t*t*t-2),easeInQuint:t=>t*t*t*t*t,easeOutQuint:t=>(t-=1)*t*t*t*t+1,easeInOutQuint:t=>(t/=.5)<1?.5*t*t*t*t*t:.5*((t-=2)*t*t*t*t+2),easeInSine:t=>-Math.cos(t*bn)+1,easeOutSine:t=>Math.sin(t*bn),easeInOutSine:t=>-0.5*(Math.cos(Be*t)-1),easeInExpo:t=>t===0?0:Math.pow(2,10*(t-1)),easeOutExpo:t=>t===1?1:-Math.pow(2,-10*t)+1,easeInOutExpo:t=>_g(t)?t:t<.5?.5*Math.pow(2,10*(t*2-1)):.5*(-Math.pow(2,-10*(t*2-1))+2),easeInCirc:t=>t>=1?t:-(Math.sqrt(1-t*t)-1),easeOutCirc:t=>Math.sqrt(1-(t-=1)*t),easeInOutCirc:t=>(t/=.5)<1?-0.5*(Math.sqrt(1-t*t)-1):.5*(Math.sqrt(1-(t-=2)*t)+1),easeInElastic:t=>_g(t)?t:hT(t,.075,.3),easeOutElastic:t=>_g(t)?t:mT(t,.075,.3),easeInOutElastic(t){return _g(t)?t:t<.5?.5*hT(t*2,.1125,.45):.5+.5*mT(t*2-1,.1125,.45)},easeInBack(t){return t*t*((1.70158+1)*t-1.70158)},easeOutBack(t){return (t-=1)*t*((1.70158+1)*t+1.70158)+1},easeInOutBack(t){let e=1.70158;return (t/=.5)<1?.5*(t*t*(((e*=1.525)+1)*t-e)):.5*((t-=2)*t*(((e*=1.525)+1)*t+e)+2)},easeInBounce:t=>1-Sc.easeOutBounce(1-t),easeOutBounce(t){return t<1/2.75?7.5625*t*t:t<2/2.75?7.5625*(t-=1.5/2.75)*t+.75:t<2.5/2.75?7.5625*(t-=2.25/2.75)*t+.9375:7.5625*(t-=2.625/2.75)*t+.984375},easeInOutBounce:t=>t<.5?Sc.easeInBounce(t*2)*.5:Sc.easeOutBounce(t*2-1)*.5+.5};function df(t){return t+.5|0}var cl=(t,e,n)=>Math.max(Math.min(t,n),e);function nf(t){return cl(df(t*2.55),0,255)}function ul(t){return cl(df(t*255),0,255)}function Ja(t){return cl(df(t/2.55)/100,0,1)}function gT(t){return cl(df(t*100),0,100)}var ho={0:0,1:1,2:2,3:3,4:4,5:5,6:6,7:7,8:8,9:9,A:10,B:11,C:12,D:13,E:14,F:15,a:10,b:11,c:12,d:13,e:14,f:15},c0=[..."0123456789ABCDEF"],rB=t=>c0[t&15],iB=t=>c0[(t&240)>>4]+c0[t&15],Tg=t=>(t&240)>>4===(t&15),oB=t=>Tg(t.r)&&Tg(t.g)&&Tg(t.b)&&Tg(t.a);function aB(t){var e=t.length,n;return t[0]==="#"&&(e===4||e===5?n={r:255&ho[t[1]]*17,g:255&ho[t[2]]*17,b:255&ho[t[3]]*17,a:e===5?ho[t[4]]*17:255}:(e===7||e===9)&&(n={r:ho[t[1]]<<4|ho[t[2]],g:ho[t[3]]<<4|ho[t[4]],b:ho[t[5]]<<4|ho[t[6]],a:e===9?ho[t[7]]<<4|ho[t[8]]:255})),n}var sB=(t,e)=>t<255?e(t):"";function lB(t){var e=oB(t)?rB:iB;return t?"#"+e(t.r)+e(t.g)+e(t.b)+sB(t.a,e):void 0}var cB=/^(hsla?|hwb|hsv)\(\s*([-+.e\d]+)(?:deg)?[\s,]+([-+.e\d]+)%[\s,]+([-+.e\d]+)%(?:[\s,]+([-+.e\d]+)(%)?)?\s*\)$/;function RT(t,e,n){let r=e*Math.min(n,1-n),i=(o,s=(o+t/30)%12)=>n-r*Math.max(Math.min(s-3,9-s,1),-1);return [i(0),i(8),i(4)]}function uB(t,e,n){let r=(i,o=(i+t/60)%6)=>n-n*e*Math.max(Math.min(o,4-o,1),0);return [r(5),r(3),r(1)]}function dB(t,e,n){let r=RT(t,1,.5),i;for(e+n>1&&(i=1/(e+n),e*=i,n*=i),i=0;i<3;i++)r[i]*=1-e-n,r[i]+=e;return r}function pB(t,e,n,r,i){return t===i?(e-n)/r+(e<n?6:0):e===i?(n-t)/r+2:(t-e)/r+4}function x0(t){let n=t.r/255,r=t.g/255,i=t.b/255,o=Math.max(n,r,i),s=Math.min(n,r,i),c=(o+s)/2,p,h,v;return o!==s&&(v=o-s,h=c>.5?v/(2-o-s):v/(o+s),p=pB(n,r,i,v,o),p=p*60+.5),[p|0,h||0,c]}function E0(t,e,n,r){return (Array.isArray(e)?t(e[0],e[1],e[2]):t(e,n,r)).map(ul)}function _0(t,e,n){return E0(RT,t,e,n)}function fB(t,e,n){return E0(dB,t,e,n)}function hB(t,e,n){return E0(uB,t,e,n)}function FT(t){return (t%360+360)%360}function mB(t){let e=cB.exec(t),n=255,r;if(!e)return;e[5]!==r&&(n=e[6]?nf(+e[5]):ul(+e[5]));let i=FT(+e[2]),o=+e[3]/100,s=+e[4]/100;return e[1]==="hwb"?r=fB(i,o,s):e[1]==="hsv"?r=hB(i,o,s):r=_0(i,o,s),{r:r[0],g:r[1],b:r[2],a:n}}function gB(t,e){var n=x0(t);n[0]=FT(n[0]+e),n=_0(n),t.r=n[0],t.g=n[1],t.b=n[2];}function yB(t){if(!t)return;let e=x0(t),n=e[0],r=gT(e[1]),i=gT(e[2]);return t.a<255?`hsla(${n}, ${r}%, ${i}%, ${Ja(t.a)})`:`hsl(${n}, ${r}%, ${i}%)`}var yT={x:"dark",Z:"light",Y:"re",X:"blu",W:"gr",V:"medium",U:"slate",A:"ee",T:"ol",S:"or",B:"ra",C:"lateg",D:"ights",R:"in",Q:"turquois",E:"hi",P:"ro",O:"al",N:"le",M:"de",L:"yello",F:"en",K:"ch",G:"arks",H:"ea",I:"ightg",J:"wh"},bT={OiceXe:"f0f8ff",antiquewEte:"faebd7",aqua:"ffff",aquamarRe:"7fffd4",azuY:"f0ffff",beige:"f5f5dc",bisque:"ffe4c4",black:"0",blanKedOmond:"ffebcd",Xe:"ff",XeviTet:"8a2be2",bPwn:"a52a2a",burlywood:"deb887",caMtXe:"5f9ea0",KartYuse:"7fff00",KocTate:"d2691e",cSO:"ff7f50",cSnflowerXe:"6495ed",cSnsilk:"fff8dc",crimson:"dc143c",cyan:"ffff",xXe:"8b",xcyan:"8b8b",xgTMnPd:"b8860b",xWay:"a9a9a9",xgYF:"6400",xgYy:"a9a9a9",xkhaki:"bdb76b",xmagFta:"8b008b",xTivegYF:"556b2f",xSange:"ff8c00",xScEd:"9932cc",xYd:"8b0000",xsOmon:"e9967a",xsHgYF:"8fbc8f",xUXe:"483d8b",xUWay:"2f4f4f",xUgYy:"2f4f4f",xQe:"ced1",xviTet:"9400d3",dAppRk:"ff1493",dApskyXe:"bfff",dimWay:"696969",dimgYy:"696969",dodgerXe:"1e90ff",fiYbrick:"b22222",flSOwEte:"fffaf0",foYstWAn:"228b22",fuKsia:"ff00ff",gaRsbSo:"dcdcdc",ghostwEte:"f8f8ff",gTd:"ffd700",gTMnPd:"daa520",Way:"808080",gYF:"8000",gYFLw:"adff2f",gYy:"808080",honeyMw:"f0fff0",hotpRk:"ff69b4",RdianYd:"cd5c5c",Rdigo:"4b0082",ivSy:"fffff0",khaki:"f0e68c",lavFMr:"e6e6fa",lavFMrXsh:"fff0f5",lawngYF:"7cfc00",NmoncEffon:"fffacd",ZXe:"add8e6",ZcSO:"f08080",Zcyan:"e0ffff",ZgTMnPdLw:"fafad2",ZWay:"d3d3d3",ZgYF:"90ee90",ZgYy:"d3d3d3",ZpRk:"ffb6c1",ZsOmon:"ffa07a",ZsHgYF:"20b2aa",ZskyXe:"87cefa",ZUWay:"778899",ZUgYy:"778899",ZstAlXe:"b0c4de",ZLw:"ffffe0",lime:"ff00",limegYF:"32cd32",lRF:"faf0e6",magFta:"ff00ff",maPon:"800000",VaquamarRe:"66cdaa",VXe:"cd",VScEd:"ba55d3",VpurpN:"9370db",VsHgYF:"3cb371",VUXe:"7b68ee",VsprRggYF:"fa9a",VQe:"48d1cc",VviTetYd:"c71585",midnightXe:"191970",mRtcYam:"f5fffa",mistyPse:"ffe4e1",moccasR:"ffe4b5",navajowEte:"ffdead",navy:"80",Tdlace:"fdf5e6",Tive:"808000",TivedBb:"6b8e23",Sange:"ffa500",SangeYd:"ff4500",ScEd:"da70d6",pOegTMnPd:"eee8aa",pOegYF:"98fb98",pOeQe:"afeeee",pOeviTetYd:"db7093",papayawEp:"ffefd5",pHKpuff:"ffdab9",peru:"cd853f",pRk:"ffc0cb",plum:"dda0dd",powMrXe:"b0e0e6",purpN:"800080",YbeccapurpN:"663399",Yd:"ff0000",Psybrown:"bc8f8f",PyOXe:"4169e1",saddNbPwn:"8b4513",sOmon:"fa8072",sandybPwn:"f4a460",sHgYF:"2e8b57",sHshell:"fff5ee",siFna:"a0522d",silver:"c0c0c0",skyXe:"87ceeb",UXe:"6a5acd",UWay:"708090",UgYy:"708090",snow:"fffafa",sprRggYF:"ff7f",stAlXe:"4682b4",tan:"d2b48c",teO:"8080",tEstN:"d8bfd8",tomato:"ff6347",Qe:"40e0d0",viTet:"ee82ee",JHt:"f5deb3",wEte:"ffffff",wEtesmoke:"f5f5f5",Lw:"ffff00",LwgYF:"9acd32"};function bB(){let t={},e=Object.keys(bT),n=Object.keys(yT),r,i,o,s,c;for(r=0;r<e.length;r++){for(s=c=e[r],i=0;i<n.length;i++)o=n[i],c=c.replace(o,yT[o]);o=parseInt(bT[s],16),t[c]=[o>>16&255,o>>8&255,o&255];}return t}var wg;function vB(t){wg||(wg=bB(),wg.transparent=[0,0,0,0]);let e=wg[t.toLowerCase()];return e&&{r:e[0],g:e[1],b:e[2],a:e.length===4?e[3]:255}}var CB=/^rgba?\(\s*([-+.\d]+)(%)?[\s,]+([-+.e\d]+)(%)?[\s,]+([-+.e\d]+)(%)?(?:[\s,/]+([-+.e\d]+)(%)?)?\s*\)$/;function SB(t){let e=CB.exec(t),n=255,r,i,o;if(e){if(e[7]!==r){let s=+e[7];n=e[8]?nf(s):cl(s*255,0,255);}return r=+e[1],i=+e[3],o=+e[5],r=255&(e[2]?nf(r):cl(r,0,255)),i=255&(e[4]?nf(i):cl(i,0,255)),o=255&(e[6]?nf(o):cl(o,0,255)),{r,g:i,b:o,a:n}}}function PB(t){return t&&(t.a<255?`rgba(${t.r}, ${t.g}, ${t.b}, ${Ja(t.a)})`:`rgb(${t.r}, ${t.g}, ${t.b})`)}var a0=t=>t<=.0031308?t*12.92:Math.pow(t,1/2.4)*1.055-.055,td=t=>t<=.04045?t/12.92:Math.pow((t+.055)/1.055,2.4);function xB(t,e,n){let r=td(Ja(t.r)),i=td(Ja(t.g)),o=td(Ja(t.b));return {r:ul(a0(r+n*(td(Ja(e.r))-r))),g:ul(a0(i+n*(td(Ja(e.g))-i))),b:ul(a0(o+n*(td(Ja(e.b))-o))),a:t.a+n*(e.a-t.a)}}function Ig(t,e,n){if(t){let r=x0(t);r[e]=Math.max(0,Math.min(r[e]+r[e]*n,e===0?360:1)),r=_0(r),t.r=r[0],t.g=r[1],t.b=r[2];}}function MT(t,e){return t&&Object.assign(e||{},t)}function vT(t){var e={r:0,g:0,b:0,a:255};return Array.isArray(t)?t.length>=3&&(e={r:t[0],g:t[1],b:t[2],a:255},t.length>3&&(e.a=ul(t[3]))):(e=MT(t,{r:0,g:0,b:0,a:1}),e.a=ul(e.a)),e}function EB(t){return t.charAt(0)==="r"?SB(t):mB(t)}var u0=class t{constructor(e){if(e instanceof t)return e;let n=typeof e,r;n==="object"?r=vT(e):n==="string"&&(r=aB(e)||vB(e)||EB(e)),this._rgb=r,this._valid=!!r;}get valid(){return this._valid}get rgb(){var e=MT(this._rgb);return e&&(e.a=Ja(e.a)),e}set rgb(e){this._rgb=vT(e);}rgbString(){return this._valid?PB(this._rgb):void 0}hexString(){return this._valid?lB(this._rgb):void 0}hslString(){return this._valid?yB(this._rgb):void 0}mix(e,n){if(e){let r=this.rgb,i=e.rgb,o,s=n===o?.5:n,c=2*s-1,p=r.a-i.a,h=((c*p===-1?c:(c+p)/(1+c*p))+1)/2;o=1-h,r.r=255&h*r.r+o*i.r+.5,r.g=255&h*r.g+o*i.g+.5,r.b=255&h*r.b+o*i.b+.5,r.a=s*r.a+(1-s)*i.a,this.rgb=r;}return this}interpolate(e,n){return e&&(this._rgb=xB(this._rgb,e._rgb,n)),this}clone(){return new t(this.rgb)}alpha(e){return this._rgb.a=ul(e),this}clearer(e){let n=this._rgb;return n.a*=1-e,this}greyscale(){let e=this._rgb,n=df(e.r*.3+e.g*.59+e.b*.11);return e.r=e.g=e.b=n,this}opaquer(e){let n=this._rgb;return n.a*=1+e,this}negate(){let e=this._rgb;return e.r=255-e.r,e.g=255-e.g,e.b=255-e.b,this}lighten(e){return Ig(this._rgb,2,e),this}darken(e){return Ig(this._rgb,2,-e),this}saturate(e){return Ig(this._rgb,1,e),this}desaturate(e){return Ig(this._rgb,1,-e),this}rotate(e){return gB(this._rgb,e),this}};function NT(t){return new u0(t)}function T0(t){if(t&&typeof t=="object"){let e=t.toString();return e==="[object CanvasPattern]"||e==="[object CanvasGradient]"}return false}function Ic(t){return T0(t)?t:NT(t)}function Dg(t){return T0(t)?t:NT(t).saturate(.5).darken(.1).hexString()}var pl=Object.create(null),zg=Object.create(null);function rf(t,e){if(!e)return t;let n=e.split(".");for(let r=0,i=n.length;r<i;++r){let o=n[r];t=t[o]||(t[o]=Object.create(null));}return t}function s0(t,e,n){return typeof e=="string"?ji(rf(t,e),n):ji(rf(t,""),e)}var d0=class{constructor(e){this.animation=void 0,this.backgroundColor="rgba(0,0,0,0.1)",this.borderColor="rgba(0,0,0,0.1)",this.color="#666",this.datasets={},this.devicePixelRatio=n=>n.chart.platform.getDevicePixelRatio(),this.elements={},this.events=["mousemove","mouseout","click","touchstart","touchmove"],this.font={family:"'Helvetica Neue', 'Helvetica', 'Arial', sans-serif",size:12,style:"normal",lineHeight:1.2,weight:null},this.hover={},this.hoverBackgroundColor=(n,r)=>Dg(r.backgroundColor),this.hoverBorderColor=(n,r)=>Dg(r.borderColor),this.hoverColor=(n,r)=>Dg(r.color),this.indexAxis="x",this.interaction={mode:"nearest",intersect:true,includeInvisible:false},this.maintainAspectRatio=true,this.onHover=null,this.onClick=null,this.parsing=true,this.plugins={},this.responsive=true,this.scale=void 0,this.scales={},this.showLine=true,this.drawActiveElementsOnTop=true,this.describe(e);}set(e,n){return s0(this,e,n)}get(e){return rf(this,e)}describe(e,n){return s0(zg,e,n)}override(e,n){return s0(pl,e,n)}route(e,n,r,i){let o=rf(this,e),s=rf(this,r),c="_"+n;Object.defineProperties(o,{[c]:{value:o[n],writable:true},[n]:{enumerable:true,get(){let p=this[c],h=s[i];return Te(p)?Object.assign({},h,p):me(p,h)},set(p){this[c]=p;}}});}},ke=new d0({_scriptable:t=>!t.startsWith("on"),_indexable:t=>t!=="events",hover:{_fallback:"interaction"},interaction:{_scriptable:false,_indexable:false}});function LT(t){return !t||Le(t.size)||Le(t.family)?null:(t.style?t.style+" ":"")+(t.weight?t.weight+" ":"")+t.size+"px "+t.family}function nd(t,e,n,r,i){let o=e[i];return o||(o=e[i]=t.measureText(i).width,n.push(i)),o>r&&(r=o),r}function w0(t,e,n,r){r=r||{};let i=r.data=r.data||{},o=r.garbageCollect=r.garbageCollect||[];r.font!==e&&(i=r.data={},o=r.garbageCollect=[],r.font=e),t.save(),t.font=e;let s=0,c=n.length,p,h,v,P,x;for(p=0;p<c;p++)if(P=n[p],P!=null&&He(P)!==true)s=nd(t,i,o,s,P);else if(He(P))for(h=0,v=P.length;h<v;h++)x=P[h],x!=null&&!He(x)&&(s=nd(t,i,o,s,x));t.restore();let T=o.length/2;if(T>n.length){for(p=0;p<T;p++)delete i[o[p]];o.splice(0,T);}return s}function rs(t,e,n){let r=t.currentDevicePixelRatio,i=n!==0?Math.max(n/2,.5):0;return Math.round((e-i)*r)/r+i}function Hg(t,e){e=e||t.getContext("2d"),e.save(),e.resetTransform(),e.clearRect(0,0,t.width,t.height),e.restore();}function pf(t,e,n,r){Wg(t,e,n,r,null);}function Wg(t,e,n,r,i){let o,s,c,p,h,v,P=e.pointStyle,x=e.rotation,T=e.radius,I=(x||0)*lf;if(P&&typeof P=="object"&&(o=P.toString(),o==="[object HTMLImageElement]"||o==="[object HTMLCanvasElement]")){t.save(),t.translate(n,r),t.rotate(I),t.drawImage(P,-P.width/2,-P.height/2,P.width,P.height),t.restore();return}if(!(isNaN(T)||T<=0)){switch(t.beginPath(),P){default:i?t.ellipse(n,r,i/2,T,0,0,rn):t.arc(n,r,T,0,rn),t.closePath();break;case "triangle":t.moveTo(n+Math.sin(I)*T,r-Math.cos(I)*T),I+=ed,t.lineTo(n+Math.sin(I)*T,r-Math.cos(I)*T),I+=ed,t.lineTo(n+Math.sin(I)*T,r-Math.cos(I)*T),t.closePath();break;case "rectRounded":h=T*.516,p=T-h,s=Math.cos(I+mo)*p,c=Math.sin(I+mo)*p,t.arc(n-s,r-c,h,I-Be,I-bn),t.arc(n+c,r-s,h,I-bn,I),t.arc(n+s,r+c,h,I,I+bn),t.arc(n-c,r+s,h,I+bn,I+Be),t.closePath();break;case "rect":if(!x){p=Math.SQRT1_2*T,v=i?i/2:p,t.rect(n-v,r-p,2*v,2*p);break}I+=mo;case "rectRot":s=Math.cos(I)*T,c=Math.sin(I)*T,t.moveTo(n-s,r-c),t.lineTo(n+c,r-s),t.lineTo(n+s,r+c),t.lineTo(n-c,r+s),t.closePath();break;case "crossRot":I+=mo;case "cross":s=Math.cos(I)*T,c=Math.sin(I)*T,t.moveTo(n-s,r-c),t.lineTo(n+s,r+c),t.moveTo(n+c,r-s),t.lineTo(n-c,r+s);break;case "star":s=Math.cos(I)*T,c=Math.sin(I)*T,t.moveTo(n-s,r-c),t.lineTo(n+s,r+c),t.moveTo(n+c,r-s),t.lineTo(n-c,r+s),I+=mo,s=Math.cos(I)*T,c=Math.sin(I)*T,t.moveTo(n-s,r-c),t.lineTo(n+s,r+c),t.moveTo(n+c,r-s),t.lineTo(n-c,r+s);break;case "line":s=i?i/2:Math.cos(I)*T,c=Math.sin(I)*T,t.moveTo(n-s,r-c),t.lineTo(n+s,r+c);break;case "dash":t.moveTo(n,r),t.lineTo(n+Math.cos(I)*T,r+Math.sin(I)*T);break}t.fill(),e.borderWidth>0&&t.stroke();}}function xc(t,e,n){return n=n||.5,!e||t&&t.x>e.left-n&&t.x<e.right+n&&t.y>e.top-n&&t.y<e.bottom+n}function fl(t,e){t.save(),t.beginPath(),t.rect(e.left,e.top,e.right-e.left,e.bottom-e.top),t.clip();}function hl(t){t.restore();}function I0(t,e,n,r,i){if(!e)return t.lineTo(n.x,n.y);if(i==="middle"){let o=(e.x+n.x)/2;t.lineTo(o,e.y),t.lineTo(o,n.y);}else i==="after"!=!!r?t.lineTo(e.x,n.y):t.lineTo(n.x,e.y);t.lineTo(n.x,n.y);}function k0(t,e,n,r){if(!e)return t.lineTo(n.x,n.y);t.bezierCurveTo(r?e.cp1x:e.cp2x,r?e.cp1y:e.cp2y,r?n.cp2x:n.cp1x,r?n.cp2y:n.cp1y,n.x,n.y);}function is(t,e,n,r,i,o={}){let s=He(e)?e:[e],c=o.strokeWidth>0&&o.strokeColor!=="",p,h;for(t.save(),t.font=i.string,_B(t,o),p=0;p<s.length;++p)h=s[p],c&&(o.strokeColor&&(t.strokeStyle=o.strokeColor),Le(o.strokeWidth)||(t.lineWidth=o.strokeWidth),t.strokeText(h,n,r,o.maxWidth)),t.fillText(h,n,r,o.maxWidth),TB(t,n,r,h,o),r+=i.lineHeight;t.restore();}function _B(t,e){e.translation&&t.translate(e.translation[0],e.translation[1]),Le(e.rotation)||t.rotate(e.rotation),e.color&&(t.fillStyle=e.color),e.textAlign&&(t.textAlign=e.textAlign),e.textBaseline&&(t.textBaseline=e.textBaseline);}function TB(t,e,n,r,i){if(i.strikethrough||i.underline){let o=t.measureText(r),s=e-o.actualBoundingBoxLeft,c=e+o.actualBoundingBoxRight,p=n-o.actualBoundingBoxAscent,h=n+o.actualBoundingBoxDescent,v=i.strikethrough?(p+h)/2:h;t.strokeStyle=t.fillStyle,t.beginPath(),t.lineWidth=i.decorationWidth||2,t.moveTo(s,v),t.lineTo(c,v),t.stroke();}}function os(t,e){let{x:n,y:r,w:i,h:o,radius:s}=e;t.arc(n+s.topLeft,r+s.topLeft,s.topLeft,-bn,Be,true),t.lineTo(n,r+o-s.bottomLeft),t.arc(n+s.bottomLeft,r+o-s.bottomLeft,s.bottomLeft,Be,bn,true),t.lineTo(n+i-s.bottomRight,r+o),t.arc(n+i-s.bottomRight,r+o-s.bottomRight,s.bottomRight,bn,0,true),t.lineTo(n+i,r+s.topRight),t.arc(n+i-s.topRight,r+s.topRight,s.topRight,0,-bn,true),t.lineTo(n+s.topLeft,r);}var wB=new RegExp(/^(normal|(\d+(?:\.\d+)?)(px|em|%)?)$/),IB=new RegExp(/^(normal|italic|initial|inherit|unset|(oblique( -?[0-9]?[0-9]deg)?))$/);function BT(t,e){let n=(""+t).match(wB);if(!n||n[1]==="normal")return e*1.2;switch(t=+n[2],n[3]){case "px":return t;case "%":t/=100;break}return e*t}var kB=t=>+t||0;function ff(t,e){let n={},r=Te(e),i=r?Object.keys(e):e,o=Te(t)?r?s=>me(t[s],t[e[s]]):s=>t[s]:()=>t;for(let s of i)n[s]=kB(o(s));return n}function qg(t){return ff(t,{top:"y",right:"x",bottom:"y",left:"x"})}function $o(t){return ff(t,["topLeft","topRight","bottomLeft","bottomRight"])}function $n(t){let e=qg(t);return e.width=e.left+e.right,e.height=e.top+e.bottom,e}function Sn(t,e){t=t||{},e=e||ke.font;let n=me(t.size,e.size);typeof n=="string"&&(n=parseInt(n,10));let r=me(t.style,e.style);r&&!(""+r).match(IB)&&(console.warn('Invalid font style specified: "'+r+'"'),r="");let i={family:me(t.family,e.family),lineHeight:BT(me(t.lineHeight,e.lineHeight),n),size:n,style:r,weight:me(t.weight,e.weight),string:""};return i.string=LT(i),i}function In(t,e,n,r){let o,s,c;for(o=0,s=t.length;o<s;++o)if(c=t[o],c!==void 0&&(e!==void 0&&typeof c=="function"&&(c=c(e),false),n!==void 0&&He(c)&&(c=c[n%c.length],false),c!==void 0))return c}function D0(t,e,n){let{min:r,max:i}=t,o=Og(e,(i-r)/2),s=(c,p)=>n&&c===0?0:c+p;return {min:s(r,-Math.abs(o)),max:s(i,o)}}function ba(t,e){return Object.assign(Object.create(t),e)}function hf(t,e=[""],n=t,r,i=()=>t[0]){Fn(r)||(r=GT("_fallback",t));let o={[Symbol.toStringTag]:"Object",_cacheable:true,_scopes:t,_rootScopes:n,_fallback:r,_getTarget:i,override:s=>hf([s,...t],e,n,r)};return new Proxy(o,{deleteProperty(s,c){return delete s[c],delete s._keys,delete t[0][c],true},get(s,c){return UT(s,c,()=>LB(c,e,t,s))},getOwnPropertyDescriptor(s,c){return Reflect.getOwnPropertyDescriptor(s._scopes[0],c)},getPrototypeOf(){return Reflect.getPrototypeOf(t[0])},has(s,c){return ST(s).includes(c)},ownKeys(s){return ST(s)},set(s,c,p){let h=s._storage||(s._storage=i());return s[c]=h[c]=p,delete s._keys,true}})}function dl(t,e,n,r){let i={_cacheable:false,_proxy:t,_context:e,_subProxy:n,_stack:new Set,_descriptors:Yg(t,r),setContext:o=>dl(t,o,n,r),override:o=>dl(t.override(o),e,n,r)};return new Proxy(i,{deleteProperty(o,s){return delete o[s],delete t[s],true},get(o,s,c){return UT(o,s,()=>AB(o,s,c))},getOwnPropertyDescriptor(o,s){return o._descriptors.allKeys?Reflect.has(t,s)?{enumerable:true,configurable:true}:void 0:Reflect.getOwnPropertyDescriptor(t,s)},getPrototypeOf(){return Reflect.getPrototypeOf(t)},has(o,s){return Reflect.has(t,s)},ownKeys(){return Reflect.ownKeys(t)},set(o,s,c){return t[s]=c,delete o[s],true}})}function Yg(t,e={scriptable:true,indexable:true}){let{_scriptable:n=e.scriptable,_indexable:r=e.indexable,_allKeys:i=e.allKeys}=t;return {allKeys:i,scriptable:n,indexable:r,isScriptable:Gr(n)?n:()=>n,isIndexable:Gr(r)?r:()=>r}}var DB=(t,e)=>t?t+sf(e):e,A0=(t,e)=>Te(e)&&t!=="adapters"&&(Object.getPrototypeOf(e)===null||e.constructor===Object);function UT(t,e,n){if(Object.prototype.hasOwnProperty.call(t,e))return t[e];let r=n();return t[e]=r,r}function AB(t,e,n){let{_proxy:r,_context:i,_subProxy:o,_descriptors:s}=t,c=r[e];return Gr(c)&&s.isScriptable(e)&&(c=OB(e,c,t,n)),He(c)&&c.length&&(c=RB(e,c,t,s.isIndexable)),A0(e,c)&&(c=dl(c,i,o&&o[e],s)),c}function OB(t,e,n,r){let{_proxy:i,_context:o,_subProxy:s,_stack:c}=n;if(c.has(t))throw new Error("Recursion detected: "+Array.from(c).join("->")+"->"+t);return c.add(t),e=e(o,s||r),c.delete(t),A0(t,e)&&(e=O0(i._scopes,i,t,e)),e}function RB(t,e,n,r){let{_proxy:i,_context:o,_subProxy:s,_descriptors:c}=n;if(Fn(o.index)&&r(t))e=e[o.index%e.length];else if(Te(e[0])){let p=e,h=i._scopes.filter(v=>v!==p);e=[];for(let v of p){let P=O0(h,i,t,v);e.push(dl(P,o,s&&s[t],c));}}return e}function $T(t,e,n){return Gr(t)?t(e,n):t}var FB=(t,e)=>t===true?e:typeof t=="string"?ya(e,t):void 0;function MB(t,e,n,r,i){for(let o of e){let s=FB(n,o);if(s){t.add(s);let c=$T(s._fallback,n,i);if(Fn(c)&&c!==n&&c!==r)return c}else if(s===false&&Fn(r)&&n!==r)return null}return false}function O0(t,e,n,r){let i=e._rootScopes,o=$T(e._fallback,n,r),s=[...t,...i],c=new Set;c.add(r);let p=CT(c,s,n,o||n,r);return p===null||Fn(o)&&o!==n&&(p=CT(c,s,o,p,r),p===null)?false:hf(Array.from(c),[""],i,o,()=>NB(e,n,r))}function CT(t,e,n,r,i){for(;n;)n=MB(t,e,n,r,i);return n}function NB(t,e,n){let r=t._getTarget();e in r||(r[e]={});let i=r[e];return He(i)&&Te(n)?n:i}function LB(t,e,n,r){let i;for(let o of e)if(i=GT(DB(o,t),n),Fn(i))return A0(t,i)?O0(n,r,t,i):i}function GT(t,e){for(let n of e){if(!n)continue;let r=n[t];if(Fn(r))return r}}function ST(t){let e=t._keys;return e||(e=t._keys=BB(t._scopes)),e}function BB(t){let e=new Set;for(let n of t)for(let r of Object.keys(n).filter(i=>!i.startsWith("_")))e.add(r);return Array.from(e)}function Qg(t,e,n,r){let{iScale:i}=t,{key:o="r"}=this._parsing,s=new Array(r),c,p,h,v;for(c=0,p=r;c<p;++c)h=c+n,v=e[h],s[c]={r:i.parse(ya(v,o),h)};return s}var UB=Number.EPSILON||1e-14,rd=(t,e)=>e<t.length&&!t[e].skip&&t[e],jT=t=>t==="x"?"y":"x";function VT(t,e,n,r){let i=t.skip?e:t,o=e,s=n.skip?e:n,c=ns(o,i),p=ns(s,o),h=c/(c+p),v=p/(c+p);h=isNaN(h)?0:h,v=isNaN(v)?0:v;let P=r*h,x=r*v;return {previous:{x:o.x-P*(s.x-i.x),y:o.y-P*(s.y-i.y)},next:{x:o.x+x*(s.x-i.x),y:o.y+x*(s.y-i.y)}}}function $B(t,e,n){let r=t.length,i,o,s,c,p,h=rd(t,0);for(let v=0;v<r-1;++v)if(p=h,h=rd(t,v+1),!(!p||!h)){if(_c(e[v],0,UB)){n[v]=n[v+1]=0;continue}i=n[v]/e[v],o=n[v+1]/e[v],c=Math.pow(i,2)+Math.pow(o,2),!(c<=9)&&(s=3/Math.sqrt(c),n[v]=i*s*e[v],n[v+1]=o*s*e[v]);}}function GB(t,e,n="x"){let r=jT(n),i=t.length,o,s,c,p=rd(t,0);for(let h=0;h<i;++h){if(s=c,c=p,p=rd(t,h+1),!c)continue;let v=c[n],P=c[r];s&&(o=(v-s[n])/3,c[`cp1${n}`]=v-o,c[`cp1${r}`]=P-o*e[h]),p&&(o=(p[n]-v)/3,c[`cp2${n}`]=v+o,c[`cp2${r}`]=P+o*e[h]);}}function zT(t,e="x"){let n=jT(e),r=t.length,i=Array(r).fill(0),o=Array(r),s,c,p,h=rd(t,0);for(s=0;s<r;++s)if(c=p,p=h,h=rd(t,s+1),!!p){if(h){let v=h[e]-p[e];i[s]=v!==0?(h[n]-p[n])/v:0;}o[s]=c?h?go(i[s-1])!==go(i[s])?0:(i[s-1]+i[s])/2:i[s-1]:i[s];}$B(t,i,o),GB(t,o,e);}function kg(t,e,n){return Math.max(Math.min(t,n),e)}function jB(t,e){let n,r,i,o,s,c=xc(t[0],e);for(n=0,r=t.length;n<r;++n)s=o,o=c,c=n<r-1&&xc(t[n+1],e),o&&(i=t[n],s&&(i.cp1x=kg(i.cp1x,e.left,e.right),i.cp1y=kg(i.cp1y,e.top,e.bottom)),c&&(i.cp2x=kg(i.cp2x,e.left,e.right),i.cp2y=kg(i.cp2y,e.top,e.bottom)));}function R0(t,e,n,r,i){let o,s,c,p;if(e.spanGaps&&(t=t.filter(h=>!h.skip)),e.cubicInterpolationMode==="monotone")zT(t,i);else {let h=r?t[t.length-1]:t[0];for(o=0,s=t.length;o<s;++o)c=t[o],p=VT(h,c,t[Math.min(o+1,s-(r?0:1))%s],e.tension),c.cp1x=p.previous.x,c.cp1y=p.previous.y,c.cp2x=p.next.x,c.cp2y=p.next.y,h=c;}e.capBezierPoints&&jB(t,n);}function Kg(){return typeof window!="undefined"&&typeof document!="undefined"}function mf(t){let e=t.parentNode;return e&&e.toString()==="[object ShadowRoot]"&&(e=e.host),e}function Ag(t,e,n){let r;return typeof t=="string"?(r=parseInt(t,10),t.indexOf("%")!==-1&&(r=r/100*e.parentNode[n])):r=t,r}var Xg=t=>window.getComputedStyle(t,null);function HT(t,e){return Xg(t).getPropertyValue(e)}var VB=["top","right","bottom","left"];function Pc(t,e,n){let r={};n=n?"-"+n:"";for(let i=0;i<4;i++){let o=VB[i];r[o]=parseFloat(t[e+"-"+o+n])||0;}return r.width=r.left+r.right,r.height=r.top+r.bottom,r}var zB=(t,e,n)=>(t>0||e>0)&&(!n||!n.shadowRoot);function HB(t,e){let n=t.touches,r=n&&n.length?n[0]:t,{offsetX:i,offsetY:o}=r,s=false,c,p;if(zB(i,o,t.target))c=i,p=o;else {let h=e.getBoundingClientRect();c=r.clientX-h.left,p=r.clientY-h.top,s=true;}return {x:c,y:p,box:s}}function as(t,e){if("native"in t)return t;let{canvas:n,currentDevicePixelRatio:r}=e,i=Xg(n),o=i.boxSizing==="border-box",s=Pc(i,"padding"),c=Pc(i,"border","width"),{x:p,y:h,box:v}=HB(t,n),P=s.left+(v&&c.left),x=s.top+(v&&c.top),{width:T,height:I}=e;return o&&(T-=s.width+c.width,I-=s.height+c.height),{x:Math.round((p-P)/T*n.width/r),y:Math.round((h-x)/I*n.height/r)}}function WB(t,e,n){let r,i;if(e===void 0||n===void 0){let o=mf(t);if(!o)e=t.clientWidth,n=t.clientHeight;else {let s=o.getBoundingClientRect(),c=Xg(o),p=Pc(c,"border","width"),h=Pc(c,"padding");e=s.width-h.width-p.width,n=s.height-h.height-p.height,r=Ag(c.maxWidth,o,"clientWidth"),i=Ag(c.maxHeight,o,"clientHeight");}}return {width:e,height:n,maxWidth:r||af,maxHeight:i||af}}var l0=t=>Math.round(t*10)/10;function F0(t,e,n,r){let i=Xg(t),o=Pc(i,"margin"),s=Ag(i.maxWidth,t,"clientWidth")||af,c=Ag(i.maxHeight,t,"clientHeight")||af,p=WB(t,e,n),{width:h,height:v}=p;if(i.boxSizing==="content-box"){let P=Pc(i,"border","width"),x=Pc(i,"padding");h-=x.width+P.width,v-=x.height+P.height;}return h=Math.max(0,h-o.width),v=Math.max(0,r?Math.floor(h/r):v-o.height),h=l0(Math.min(h,s,p.maxWidth)),v=l0(Math.min(v,c,p.maxHeight)),h&&!v&&(v=l0(h/2)),{width:h,height:v}}function Zg(t,e,n){let r=e||1,i=Math.floor(t.height*r),o=Math.floor(t.width*r);t.height=i/r,t.width=o/r;let s=t.canvas;return s.style&&(n||!s.style.height&&!s.style.width)&&(s.style.height=`${t.height}px`,s.style.width=`${t.width}px`),t.currentDevicePixelRatio!==r||s.height!==i||s.width!==o?(t.currentDevicePixelRatio=r,s.height=i,s.width=o,t.ctx.setTransform(r,0,0,r,0,0),true):false}var M0=(function(){let t=false;try{let e={get passive(){return t=!0,!1}};window.addEventListener("test",null,e),window.removeEventListener("test",null,e);}catch(e){}return t})();function Jg(t,e){let n=HT(t,e),r=n&&n.match(/^(\d+)(\.\d+)?px$/);return r?+r[1]:void 0}function ts(t,e,n,r){return {x:t.x+n*(e.x-t.x),y:t.y+n*(e.y-t.y)}}function N0(t,e,n,r){return {x:t.x+n*(e.x-t.x),y:r==="middle"?n<.5?t.y:e.y:r==="after"?n<1?t.y:e.y:n>0?e.y:t.y}}function L0(t,e,n,r){let i={x:t.cp2x,y:t.cp2y},o={x:e.cp1x,y:e.cp1y},s=ts(t,i,n),c=ts(i,o,n),p=ts(o,e,n),h=ts(s,c,n),v=ts(c,p,n);return ts(h,v,n)}var PT=new Map;function qB(t,e){e=e||{};let n=t+JSON.stringify(e),r=PT.get(n);return r||(r=new Intl.NumberFormat(t,e),PT.set(n,r)),r}function kc(t,e,n){return qB(e,n).format(t)}var YB=function(t,e){return {x(n){return t+t+e-n},setWidth(n){e=n;},textAlign(n){return n==="center"?n:n==="right"?"left":"right"},xPlus(n,r){return n-r},leftForLtr(n,r){return n-r}}},QB=function(){return {x(t){return t},setWidth(t){},textAlign(t){return t},xPlus(t,e){return t+e},leftForLtr(t,e){return t}}};function ml(t,e,n){return t?YB(e,n):QB()}function ty(t,e){let n,r;(e==="ltr"||e==="rtl")&&(n=t.canvas.style,r=[n.getPropertyValue("direction"),n.getPropertyPriority("direction")],n.setProperty("direction",e,"important"),t.prevTextDirection=r);}function ey(t,e){e!==void 0&&(delete t.prevTextDirection,t.canvas.style.setProperty("direction",e[0],e[1]));}function WT(t){return t==="angle"?{between:wc,compare:AT,normalize:ai}:{between:Uo,compare:(e,n)=>e-n,normalize:e=>e}}function xT({start:t,end:e,count:n,loop:r,style:i}){return {start:t%n,end:e%n,loop:r&&(e-t+1)%n===0,style:i}}function KB(t,e,n){let{property:r,start:i,end:o}=n,{between:s,normalize:c}=WT(r),p=e.length,{start:h,end:v,loop:P}=t,x,T;if(P){for(h+=p,v+=p,x=0,T=p;x<T&&s(c(e[h%p][r]),i,o);++x)h--,v--;h%=p,v%=p;}return v<h&&(v+=p),{start:h,end:v,loop:P,style:t.style}}function ny(t,e,n){if(!n)return [t];let{property:r,start:i,end:o}=n,s=e.length,{compare:c,between:p,normalize:h}=WT(r),{start:v,end:P,loop:x,style:T}=KB(t,e,n),I=[],R=false,A=null,O,N,V,G=()=>p(i,V,O)&&c(i,V)!==0,X=()=>c(o,O)===0||p(o,V,O),nt=()=>R||G(),st=()=>!R||X();for(let U=v,j=v;U<=P;++U)N=e[U%s],!N.skip&&(O=h(N[r]),O!==V&&(R=p(O,i,o),A===null&&nt()&&(A=c(O,i)===0?U:j),A!==null&&st()&&(I.push(xT({start:A,end:U,loop:x,count:s,style:T})),A=null),j=U,V=O));return A!==null&&I.push(xT({start:A,end:P,loop:x,count:s,style:T})),I}function ry(t,e){let n=[],r=t.segments;for(let i=0;i<r.length;i++){let o=ny(r[i],t.points,e);o.length&&n.push(...o);}return n}function XB(t,e,n,r){let i=0,o=e-1;if(n&&!r)for(;i<e&&!t[i].skip;)i++;for(;i<e&&t[i].skip;)i++;for(i%=e,n&&(o+=i);o>i&&t[o%e].skip;)o--;return o%=e,{start:i,end:o}}function ZB(t,e,n,r){let i=t.length,o=[],s=e,c=t[e],p;for(p=e+1;p<=n;++p){let h=t[p%i];h.skip||h.stop?c.skip||(r=false,o.push({start:e%i,end:(p-1)%i,loop:r}),e=s=h.stop?p:null):(s=p,c.skip&&(e=p)),c=h;}return s!==null&&o.push({start:e%i,end:s%i,loop:r}),o}function B0(t,e){let n=t.points,r=t.options.spanGaps,i=n.length;if(!i)return [];let o=!!t._loop,{start:s,end:c}=XB(n,i,o,r);if(r===true)return ET(t,[{start:s,end:c,loop:o}],n,e);let p=c<s?c+i:c,h=!!t._fullLoop&&s===0&&c===i-1;return ET(t,ZB(n,s,p,h),n,e)}function ET(t,e,n,r){return !r||!r.setContext||!n?e:JB(t,e,n,r)}function JB(t,e,n,r){let i=t._chart.getContext(),o=_T(t.options),{_datasetIndex:s,options:{spanGaps:c}}=t,p=n.length,h=[],v=o,P=e[0].start,x=P;function T(I,R,A,O){let N=c?-1:1;if(I!==R){for(I+=p;n[I%p].skip;)I-=N;for(;n[R%p].skip;)R+=N;I%p!==R%p&&(h.push({start:I%p,end:R%p,loop:A,style:O}),v=O,P=R%p);}}for(let I of e){P=c?P:I.start;let R=n[P%p],A;for(x=P+1;x<=I.end;x++){let O=n[x%p];A=_T(r.setContext(ba(i,{type:"segment",p0:R,p1:O,p0DataIndex:(x-1)%p,p1DataIndex:x%p,datasetIndex:s}))),t6(A,v)&&T(P,x-1,I.loop,v),R=O,v=A;}P<x-1&&T(P,x-1,I.loop,v);}return h}function _T(t){return {backgroundColor:t.backgroundColor,borderCapStyle:t.borderCapStyle,borderDash:t.borderDash,borderDashOffset:t.borderDashOffset,borderJoinStyle:t.borderJoinStyle,borderWidth:t.borderWidth,borderColor:t.borderColor}}function t6(t,e){return e&&JSON.stringify(t)!==JSON.stringify(e)}var Y0=class{constructor(){this._request=null,this._charts=new Map,this._running=false,this._lastDate=void 0;}_notify(e,n,r,i){let o=n.listeners[i],s=n.duration;o.forEach(c=>c({chart:e,initial:n.initial,numSteps:s,currentStep:Math.min(r-n.start,s)}));}_refresh(){this._request||(this._running=true,this._request=$g.call(window,()=>{this._update(),this._request=null,this._running&&this._refresh();}));}_update(e=Date.now()){let n=0;this._charts.forEach((r,i)=>{if(!r.running||!r.items.length)return;let o=r.items,s=o.length-1,c=false,p;for(;s>=0;--s)p=o[s],p._active?(p._total>r.duration&&(r.duration=p._total),p.tick(e),c=true):(o[s]=o[o.length-1],o.pop());c&&(i.draw(),this._notify(i,r,e,"progress")),o.length||(r.running=false,this._notify(i,r,e,"complete"),r.initial=false),n+=o.length;}),this._lastDate=e,n===0&&(this._running=false);}_getAnims(e){let n=this._charts,r=n.get(e);return r||(r={running:false,initial:true,items:[],listeners:{complete:[],progress:[]}},n.set(e,r)),r}listen(e,n,r){this._getAnims(e).listeners[n].push(r);}add(e,n){!n||!n.length||this._getAnims(e).items.push(...n);}has(e){return this._getAnims(e).items.length>0}start(e){let n=this._charts.get(e);n&&(n.running=true,n.start=Date.now(),n.duration=n.items.reduce((r,i)=>Math.max(r,i._duration),0),this._refresh());}running(e){if(!this._running)return false;let n=this._charts.get(e);return !(!n||!n.running||!n.items.length)}stop(e){let n=this._charts.get(e);if(!n||!n.items.length)return;let r=n.items,i=r.length-1;for(;i>=0;--i)r[i].cancel();n.items=[],this._notify(e,n,Date.now(),"complete");}remove(e){return this._charts.delete(e)}},ss=new Y0,qT="transparent",e6={boolean(t,e,n){return n>.5?e:t},color(t,e,n){let r=Ic(t||qT),i=r.valid&&Ic(e||qT);return i&&i.valid?i.mix(r,n).hexString():e},number(t,e,n){return t+(e-t)*n}},Q0=class{constructor(e,n,r,i){let o=n[r];i=In([e.to,i,o,e.from]);let s=In([e.from,o,i]);this._active=true,this._fn=e.fn||e6[e.type||typeof s],this._easing=Sc[e.easing]||Sc.linear,this._start=Math.floor(Date.now()+(e.delay||0)),this._duration=this._total=Math.floor(e.duration),this._loop=!!e.loop,this._target=n,this._prop=r,this._from=s,this._to=i,this._promises=void 0;}active(){return this._active}update(e,n,r){if(this._active){this._notify(false);let i=this._target[this._prop],o=r-this._start,s=this._duration-o;this._start=r,this._duration=Math.floor(Math.max(s,e.duration)),this._total+=o,this._loop=!!e.loop,this._to=In([e.to,n,i,e.from]),this._from=In([e.from,i,n]);}}cancel(){this._active&&(this.tick(Date.now()),this._active=false,this._notify(false));}tick(e){let n=e-this._start,r=this._duration,i=this._prop,o=this._from,s=this._loop,c=this._to,p;if(this._active=o!==c&&(s||n<r),!this._active){this._target[i]=c,this._notify(true);return}if(n<0){this._target[i]=o;return}p=n/r%2,p=s&&p>1?2-p:p,p=this._easing(Math.min(1,Math.max(0,p))),this._target[i]=this._fn(o,c,p);}wait(){let e=this._promises||(this._promises=[]);return new Promise((n,r)=>{e.push({res:n,rej:r});})}_notify(e){let n=e?"res":"rej",r=this._promises||[];for(let i=0;i<r.length;i++)r[i][n]();}},n6=["x","y","borderWidth","radius","tension"],r6=["color","borderColor","backgroundColor"];ke.set("animation",{delay:void 0,duration:1e3,easing:"easeOutQuart",fn:void 0,from:void 0,loop:void 0,to:void 0,type:void 0});var i6=Object.keys(ke.animation);ke.describe("animation",{_fallback:false,_indexable:false,_scriptable:t=>t!=="onProgress"&&t!=="onComplete"&&t!=="fn"});ke.set("animations",{colors:{type:"color",properties:r6},numbers:{type:"number",properties:n6}});ke.describe("animations",{_fallback:"animation"});ke.set("transitions",{active:{animation:{duration:400}},resize:{animation:{duration:0}},show:{animations:{colors:{from:"transparent"},visible:{type:"boolean",duration:0}}},hide:{animations:{colors:{to:"transparent"},visible:{type:"boolean",easing:"linear",fn:t=>t|0}}}});var sd=class{constructor(e,n){this._chart=e,this._properties=new Map,this.configure(n);}configure(e){if(!Te(e))return;let n=this._properties;Object.getOwnPropertyNames(e).forEach(r=>{let i=e[r];if(!Te(i))return;let o={};for(let s of i6)o[s]=i[s];(He(i.properties)&&i.properties||[r]).forEach(s=>{(s===r||!n.has(s))&&n.set(s,o);});});}_animateOptions(e,n){let r=n.options,i=a6(e,r);if(!i)return [];let o=this._createAnimations(i,r);return r.$shared&&o6(e.options.$animations,r).then(()=>{e.options=r;},()=>{}),o}_createAnimations(e,n){let r=this._properties,i=[],o=e.$animations||(e.$animations={}),s=Object.keys(n),c=Date.now(),p;for(p=s.length-1;p>=0;--p){let h=s[p];if(h.charAt(0)==="$")continue;if(h==="options"){i.push(...this._animateOptions(e,n));continue}let v=n[h],P=o[h],x=r.get(h);if(P)if(x&&P.active()){P.update(x,v,c);continue}else P.cancel();if(!x||!x.duration){e[h]=v;continue}o[h]=P=new Q0(x,e,h,v),i.push(P);}return i}update(e,n){if(this._properties.size===0){Object.assign(e,n);return}let r=this._createAnimations(e,n);if(r.length)return ss.add(this._chart,r),true}};function o6(t,e){let n=[],r=Object.keys(e);for(let i=0;i<r.length;i++){let o=t[r[i]];o&&o.active()&&n.push(o.wait());}return Promise.all(n)}function a6(t,e){if(!e)return;let n=t.options;if(!n){t.options=e;return}return n.$shared&&(t.options=n=Object.assign({},n,{$shared:false,$animations:{}})),n}function YT(t,e){let n=t&&t.options||{},r=n.reverse,i=n.min===void 0?e:0,o=n.max===void 0?e:0;return {start:r?o:i,end:r?i:o}}function s6(t,e,n){if(n===false)return false;let r=YT(t,n),i=YT(e,n);return {top:i.end,right:r.end,bottom:i.start,left:r.start}}function l6(t){let e,n,r,i;return Te(t)?(e=t.top,n=t.right,r=t.bottom,i=t.left):e=n=r=i=t,{top:e,right:n,bottom:r,left:i,disabled:t===false}}function Lw(t,e){let n=[],r=t._getSortedDatasetMetas(e),i,o;for(i=0,o=r.length;i<o;++i)n.push(r[i].index);return n}function QT(t,e,n,r={}){let i=t.keys,o=r.mode==="single",s,c,p,h;if(e!==null){for(s=0,c=i.length;s<c;++s){if(p=+i[s],p===n){if(r.all)continue;break}h=t.values[p],Mn(h)&&(o||e===0||go(e)===go(h))&&(e+=h);}return e}}function c6(t){let e=Object.keys(t),n=new Array(e.length),r,i,o;for(r=0,i=e.length;r<i;++r)o=e[r],n[r]={x:o,y:t[o]};return n}function KT(t,e){let n=t&&t.options.stacked;return n||n===void 0&&e.stack!==void 0}function u6(t,e,n){return `${t.id}.${e.id}.${n.stack||n.type}`}function d6(t){let{min:e,max:n,minDefined:r,maxDefined:i}=t.getUserBounds();return {min:r?e:Number.NEGATIVE_INFINITY,max:i?n:Number.POSITIVE_INFINITY}}function p6(t,e,n){let r=t[e]||(t[e]={});return r[n]||(r[n]={})}function XT(t,e,n,r){for(let i of e.getMatchingVisibleMetas(r).reverse()){let o=t[i.index];if(n&&o>0||!n&&o<0)return i.index}return null}function ZT(t,e){let{chart:n,_cachedMeta:r}=t,i=n._stacks||(n._stacks={}),{iScale:o,vScale:s,index:c}=r,p=o.axis,h=s.axis,v=u6(o,s,r),P=e.length,x;for(let T=0;T<P;++T){let I=e[T],{[p]:R,[h]:A}=I,O=I._stacks||(I._stacks={});x=O[h]=p6(i,v,R),x[c]=A,x._top=XT(x,s,true,r.type),x._bottom=XT(x,s,false,r.type);}}function U0(t,e){let n=t.scales;return Object.keys(n).filter(r=>n[r].axis===e).shift()}function f6(t,e){return ba(t,{active:false,dataset:void 0,datasetIndex:e,index:e,mode:"default",type:"dataset"})}function h6(t,e,n){return ba(t,{active:false,dataIndex:e,parsed:void 0,raw:void 0,element:n,index:e,mode:"default",type:"data"})}function gf(t,e){let n=t.controller.index,r=t.vScale&&t.vScale.axis;if(r){e=e||t._parsed;for(let i of e){let o=i._stacks;if(!o||o[r]===void 0||o[r][n]===void 0)return;delete o[r][n];}}}var $0=t=>t==="reset"||t==="none",JT=(t,e)=>e?t:Object.assign({},t),m6=(t,e,n)=>t&&!e.hidden&&e._stacked&&{keys:Lw(n,true),values:null},zi=class{constructor(e,n){this.chart=e,this._ctx=e.ctx,this.index=n,this._cachedDataOpts={},this._cachedMeta=this.getMeta(),this._type=this._cachedMeta.type,this.options=void 0,this._parsing=false,this._data=void 0,this._objectData=void 0,this._sharedOptions=void 0,this._drawStart=void 0,this._drawCount=void 0,this.enableOptionSharing=false,this.supportsDecimation=false,this.$context=void 0,this._syncList=[],this.initialize();}initialize(){let e=this._cachedMeta;this.configure(),this.linkScales(),e._stacked=KT(e.vScale,e),this.addElements();}updateIndex(e){this.index!==e&&gf(this._cachedMeta),this.index=e;}linkScales(){let e=this.chart,n=this._cachedMeta,r=this.getDataset(),i=(P,x,T,I)=>P==="x"?x:P==="r"?I:T,o=n.xAxisID=me(r.xAxisID,U0(e,"x")),s=n.yAxisID=me(r.yAxisID,U0(e,"y")),c=n.rAxisID=me(r.rAxisID,U0(e,"r")),p=n.indexAxis,h=n.iAxisID=i(p,o,s,c),v=n.vAxisID=i(p,s,o,c);n.xScale=this.getScaleForId(o),n.yScale=this.getScaleForId(s),n.rScale=this.getScaleForId(c),n.iScale=this.getScaleForId(h),n.vScale=this.getScaleForId(v);}getDataset(){return this.chart.data.datasets[this.index]}getMeta(){return this.chart.getDatasetMeta(this.index)}getScaleForId(e){return this.chart.scales[e]}_getOtherScale(e){let n=this._cachedMeta;return e===n.iScale?n.vScale:n.iScale}reset(){this._update("reset");}_destroy(){let e=this._cachedMeta;this._data&&Bg(this._data,this),e._stacked&&gf(e);}_dataCheck(){let e=this.getDataset(),n=e.data||(e.data=[]),r=this._data;if(Te(n))this._data=c6(n);else if(r!==n){if(r){Bg(r,this);let i=this._cachedMeta;gf(i),i._parsed=[];}n&&Object.isExtensible(n)&&C0(n,this),this._syncList=[],this._data=n;}}addElements(){let e=this._cachedMeta;this._dataCheck(),this.datasetElementType&&(e.dataset=new this.datasetElementType);}buildOrUpdateElements(e){let n=this._cachedMeta,r=this.getDataset(),i=false;this._dataCheck();let o=n._stacked;n._stacked=KT(n.vScale,n),n.stack!==r.stack&&(i=true,gf(n),n.stack=r.stack),this._resyncElements(e),(i||o!==n._stacked)&&ZT(this,n._parsed);}configure(){let e=this.chart.config,n=e.datasetScopeKeys(this._type),r=e.getOptionScopes(this.getDataset(),n,true);this.options=e.createResolver(r,this.getContext()),this._parsing=this.options.parsing,this._cachedDataOpts={};}parse(e,n){let{_cachedMeta:r,_data:i}=this,{iScale:o,_stacked:s}=r,c=o.axis,p=e===0&&n===i.length?true:r._sorted,h=e>0&&r._parsed[e-1],v,P,x;if(this._parsing===false)r._parsed=i,r._sorted=true,x=i;else {He(i[e])?x=this.parseArrayData(r,i,e,n):Te(i[e])?x=this.parseObjectData(r,i,e,n):x=this.parsePrimitiveData(r,i,e,n);let T=()=>P[c]===null||h&&P[c]<h[c];for(v=0;v<n;++v)r._parsed[v+e]=P=x[v],p&&(T()&&(p=false),h=P);r._sorted=p;}s&&ZT(this,x);}parsePrimitiveData(e,n,r,i){let{iScale:o,vScale:s}=e,c=o.axis,p=s.axis,h=o.getLabels(),v=o===s,P=new Array(i),x,T,I;for(x=0,T=i;x<T;++x)I=x+r,P[x]={[c]:v||o.parse(h[I],I),[p]:s.parse(n[I],I)};return P}parseArrayData(e,n,r,i){let{xScale:o,yScale:s}=e,c=new Array(i),p,h,v,P;for(p=0,h=i;p<h;++p)v=p+r,P=n[v],c[p]={x:o.parse(P[0],v),y:s.parse(P[1],v)};return c}parseObjectData(e,n,r,i){let{xScale:o,yScale:s}=e,{xAxisKey:c="x",yAxisKey:p="y"}=this._parsing,h=new Array(i),v,P,x,T;for(v=0,P=i;v<P;++v)x=v+r,T=n[x],h[v]={x:o.parse(ya(T,c),x),y:s.parse(ya(T,p),x)};return h}getParsed(e){return this._cachedMeta._parsed[e]}getDataElement(e){return this._cachedMeta.data[e]}applyStack(e,n,r){let i=this.chart,o=this._cachedMeta,s=n[e.axis],c={keys:Lw(i,true),values:n._stacks[e.axis]};return QT(c,s,o.index,{mode:r})}updateRangeFromParsed(e,n,r,i){let o=r[n.axis],s=o===null?NaN:o,c=i&&r._stacks[n.axis];i&&c&&(i.values=c,s=QT(i,o,this._cachedMeta.index)),e.min=Math.min(e.min,s),e.max=Math.max(e.max,s);}getMinMax(e,n){let r=this._cachedMeta,i=r._parsed,o=r._sorted&&e===r.iScale,s=i.length,c=this._getOtherScale(e),p=m6(n,r,this.chart),h={min:Number.POSITIVE_INFINITY,max:Number.NEGATIVE_INFINITY},{min:v,max:P}=d6(c),x,T;function I(){T=i[x];let R=T[c.axis];return !Mn(T[e.axis])||v>R||P<R}for(x=0;x<s&&!(!I()&&(this.updateRangeFromParsed(h,e,T,p),o));++x);if(o){for(x=s-1;x>=0;--x)if(!I()){this.updateRangeFromParsed(h,e,T,p);break}}return h}getAllParsedValues(e){let n=this._cachedMeta._parsed,r=[],i,o,s;for(i=0,o=n.length;i<o;++i)s=n[i][e.axis],Mn(s)&&r.push(s);return r}getMaxOverflow(){return false}getLabelAndValue(e){let n=this._cachedMeta,r=n.iScale,i=n.vScale,o=this.getParsed(e);return {label:r?""+r.getLabelForValue(o[r.axis]):"",value:i?""+i.getLabelForValue(o[i.axis]):""}}_update(e){let n=this._cachedMeta;this.update(e||"default"),n._clip=l6(me(this.options.clip,s6(n.xScale,n.yScale,this.getMaxOverflow())));}update(e){}draw(){let e=this._ctx,n=this.chart,r=this._cachedMeta,i=r.data||[],o=n.chartArea,s=[],c=this._drawStart||0,p=this._drawCount||i.length-c,h=this.options.drawActiveElementsOnTop,v;for(r.dataset&&r.dataset.draw(e,o,c,p),v=c;v<c+p;++v){let P=i[v];P.hidden||(P.active&&h?s.push(P):P.draw(e,o));}for(v=0;v<s.length;++v)s[v].draw(e,o);}getStyle(e,n){let r=n?"active":"default";return e===void 0&&this._cachedMeta.dataset?this.resolveDatasetElementOptions(r):this.resolveDataElementOptions(e||0,r)}getContext(e,n,r){let i=this.getDataset(),o;if(e>=0&&e<this._cachedMeta.data.length){let s=this._cachedMeta.data[e];o=s.$context||(s.$context=h6(this.getContext(),e,s)),o.parsed=this.getParsed(e),o.raw=i.data[e],o.index=o.dataIndex=e;}else o=this.$context||(this.$context=f6(this.chart.getContext(),this.index)),o.dataset=i,o.index=o.datasetIndex=this.index;return o.active=!!n,o.mode=r,o}resolveDatasetElementOptions(e){return this._resolveElementOptions(this.datasetElementType.id,e)}resolveDataElementOptions(e,n){return this._resolveElementOptions(this.dataElementType.id,n,e)}_resolveElementOptions(e,n="default",r){let i=n==="active",o=this._cachedDataOpts,s=e+"-"+n,c=o[s],p=this.enableOptionSharing&&Fn(r);if(c)return JT(c,p);let h=this.chart.config,v=h.datasetElementScopeKeys(this._type,e),P=i?[`${e}Hover`,"hover",e,""]:[e,""],x=h.getOptionScopes(this.getDataset(),v),T=Object.keys(ke.elements[e]),I=()=>this.getContext(r,i),R=h.resolveNamedOptions(x,T,I,P);return R.$shared&&(R.$shared=p,o[s]=Object.freeze(JT(R,p))),R}_resolveAnimations(e,n,r){let i=this.chart,o=this._cachedDataOpts,s=`animation-${n}`,c=o[s];if(c)return c;let p;if(i.options.animation!==false){let v=this.chart.config,P=v.datasetAnimationScopeKeys(this._type,n),x=v.getOptionScopes(this.getDataset(),P);p=v.createResolver(x,this.getContext(e,r,n));}let h=new sd(i,p&&p.animations);return p&&p._cacheable&&(o[s]=Object.freeze(h)),h}getSharedOptions(e){if(e.$shared)return this._sharedOptions||(this._sharedOptions=Object.assign({},e))}includeOptions(e,n){return !n||$0(e)||this.chart._animationsDisabled}_getSharedOptions(e,n){let r=this.resolveDataElementOptions(e,n),i=this._sharedOptions,o=this.getSharedOptions(r),s=this.includeOptions(n,o)||o!==i;return this.updateSharedOptions(o,n,r),{sharedOptions:o,includeOptions:s}}updateElement(e,n,r,i){$0(i)?Object.assign(e,r):this._resolveAnimations(n,i).update(e,r);}updateSharedOptions(e,n,r){e&&!$0(n)&&this._resolveAnimations(void 0,n).update(e,r);}_setStyle(e,n,r,i){e.active=i;let o=this.getStyle(n,i);this._resolveAnimations(n,r,i).update(e,{options:!i&&this.getSharedOptions(o)||o});}removeHoverStyle(e,n,r){this._setStyle(e,r,"active",false);}setHoverStyle(e,n,r){this._setStyle(e,r,"active",true);}_removeDatasetHoverStyle(){let e=this._cachedMeta.dataset;e&&this._setStyle(e,void 0,"active",false);}_setDatasetHoverStyle(){let e=this._cachedMeta.dataset;e&&this._setStyle(e,void 0,"active",true);}_resyncElements(e){let n=this._data,r=this._cachedMeta.data;for(let[c,p,h]of this._syncList)this[c](p,h);this._syncList=[];let i=r.length,o=n.length,s=Math.min(o,i);s&&this.parse(0,s),o>i?this._insertElements(i,o-i,e):o<i&&this._removeElements(o,i-o);}_insertElements(e,n,r=true){let i=this._cachedMeta,o=i.data,s=e+n,c,p=h=>{for(h.length+=n,c=h.length-1;c>=s;c--)h[c]=h[c-n];};for(p(o),c=e;c<s;++c)o[c]=new this.dataElementType;this._parsing&&p(i._parsed),this.parse(e,n),r&&this.updateElements(o,e,n,"reset");}updateElements(e,n,r,i){}_removeElements(e,n){let r=this._cachedMeta;if(this._parsing){let i=r._parsed.splice(e,n);r._stacked&&gf(r,i);}r.data.splice(e,n);}_sync(e){if(this._parsing)this._syncList.push(e);else {let[n,r,i]=e;this[n](r,i);}this.chart._dataChanges.push([this.index,...e]);}_onDataPush(){let e=arguments.length;this._sync(["_insertElements",this.getDataset().data.length-e,e]);}_onDataPop(){this._sync(["_removeElements",this._cachedMeta.data.length-1,1]);}_onDataShift(){this._sync(["_removeElements",0,1]);}_onDataSplice(e,n){n&&this._sync(["_removeElements",e,n]);let r=arguments.length-2;r&&this._sync(["_insertElements",e,r]);}_onDataUnshift(){this._sync(["_insertElements",0,arguments.length]);}};zi.defaults={};zi.prototype.datasetElementType=null;zi.prototype.dataElementType=null;function g6(t,e){if(!t._cache.$bar){let n=t.getMatchingVisibleMetas(e),r=[];for(let i=0,o=n.length;i<o;i++)r=r.concat(n[i].controller.getAllParsedValues(t));t._cache.$bar=Ug(r.sort((i,o)=>i-o));}return t._cache.$bar}function y6(t){let e=t.iScale,n=g6(e,t.type),r=e._length,i,o,s,c,p=()=>{s===32767||s===-32768||(Fn(c)&&(r=Math.min(r,Math.abs(s-c)||r)),c=s);};for(i=0,o=n.length;i<o;++i)s=e.getPixelForValue(n[i]),p();for(c=void 0,i=0,o=e.ticks.length;i<o;++i)s=e.getPixelForTick(i),p();return r}function b6(t,e,n,r){let i=n.barThickness,o,s;return Le(i)?(o=e.min*n.categoryPercentage,s=n.barPercentage):(o=i*r,s=1),{chunk:o/r,ratio:s,start:e.pixels[t]-o/2}}function v6(t,e,n,r){let i=e.pixels,o=i[t],s=t>0?i[t-1]:null,c=t<i.length-1?i[t+1]:null,p=n.categoryPercentage;s===null&&(s=o-(c===null?e.end-e.start:c-o)),c===null&&(c=o+o-s);let h=o-(o-Math.min(s,c))/2*p;return {chunk:Math.abs(c-s)/2*p/r,ratio:n.barPercentage,start:h}}function C6(t,e,n,r){let i=n.parse(t[0],r),o=n.parse(t[1],r),s=Math.min(i,o),c=Math.max(i,o),p=s,h=c;Math.abs(s)>Math.abs(c)&&(p=c,h=s),e[n.axis]=h,e._custom={barStart:p,barEnd:h,start:i,end:o,min:s,max:c};}function Bw(t,e,n,r){return He(t)?C6(t,e,n,r):e[n.axis]=n.parse(t,r),e}function tw(t,e,n,r){let i=t.iScale,o=t.vScale,s=i.getLabels(),c=i===o,p=[],h,v,P,x;for(h=n,v=n+r;h<v;++h)x=e[h],P={},P[i.axis]=c||i.parse(s[h],h),p.push(Bw(x,P,o,h));return p}function G0(t){return t&&t.barStart!==void 0&&t.barEnd!==void 0}function S6(t,e,n){return t!==0?go(t):(e.isHorizontal()?1:-1)*(e.min>=n?1:-1)}function P6(t){let e,n,r,i,o;return t.horizontal?(e=t.base>t.x,n="left",r="right"):(e=t.base<t.y,n="bottom",r="top"),e?(i="end",o="start"):(i="start",o="end"),{start:n,end:r,reverse:e,top:i,bottom:o}}function x6(t,e,n,r){let i=e.borderSkipped,o={};if(!i){t.borderSkipped=o;return}if(i===true){t.borderSkipped={top:true,right:true,bottom:true,left:true};return}let{start:s,end:c,reverse:p,top:h,bottom:v}=P6(t);i==="middle"&&n&&(t.enableBorderRadius=true,(n._top||0)===r?i=h:(n._bottom||0)===r?i=v:(o[ew(v,s,c,p)]=true,i=h)),o[ew(i,s,c,p)]=true,t.borderSkipped=o;}function ew(t,e,n,r){return r?(t=E6(t,e,n),t=nw(t,n,e)):t=nw(t,e,n),t}function E6(t,e,n){return t===e?n:t===n?e:t}function nw(t,e,n){return t==="start"?e:t==="end"?n:t}function _6(t,{inflateAmount:e},n){t.inflateAmount=e==="auto"?n===1?.33:0:e;}var xf=class extends zi{parsePrimitiveData(e,n,r,i){return tw(e,n,r,i)}parseArrayData(e,n,r,i){return tw(e,n,r,i)}parseObjectData(e,n,r,i){let{iScale:o,vScale:s}=e,{xAxisKey:c="x",yAxisKey:p="y"}=this._parsing,h=o.axis==="x"?c:p,v=s.axis==="x"?c:p,P=[],x,T,I,R;for(x=r,T=r+i;x<T;++x)R=n[x],I={},I[o.axis]=o.parse(ya(R,h),x),P.push(Bw(ya(R,v),I,s,x));return P}updateRangeFromParsed(e,n,r,i){super.updateRangeFromParsed(e,n,r,i);let o=r._custom;o&&n===this._cachedMeta.vScale&&(e.min=Math.min(e.min,o.min),e.max=Math.max(e.max,o.max));}getMaxOverflow(){return 0}getLabelAndValue(e){let n=this._cachedMeta,{iScale:r,vScale:i}=n,o=this.getParsed(e),s=o._custom,c=G0(s)?"["+s.start+", "+s.end+"]":""+i.getLabelForValue(o[i.axis]);return {label:""+r.getLabelForValue(o[r.axis]),value:c}}initialize(){this.enableOptionSharing=true,super.initialize();let e=this._cachedMeta;e.stack=this.getDataset().stack;}update(e){let n=this._cachedMeta;this.updateElements(n.data,0,n.data.length,e);}updateElements(e,n,r,i){let o=i==="reset",{index:s,_cachedMeta:{vScale:c}}=this,p=c.getBasePixel(),h=c.isHorizontal(),v=this._getRuler(),{sharedOptions:P,includeOptions:x}=this._getSharedOptions(n,i);for(let T=n;T<n+r;T++){let I=this.getParsed(T),R=o||Le(I[c.axis])?{base:p,head:p}:this._calculateBarValuePixels(T),A=this._calculateBarIndexPixels(T,v),O=(I._stacks||{})[c.axis],N={horizontal:h,base:R.base,enableBorderRadius:!O||G0(I._custom)||s===O._top||s===O._bottom,x:h?R.head:A.center,y:h?A.center:R.head,height:h?A.size:Math.abs(R.size),width:h?Math.abs(R.size):A.size};x&&(N.options=P||this.resolveDataElementOptions(T,e[T].active?"active":i));let V=N.options||e[T].options;x6(N,V,O,s),_6(N,V,v.ratio),this.updateElement(e[T],T,N,i);}}_getStacks(e,n){let{iScale:r}=this._cachedMeta,i=r.getMatchingVisibleMetas(this._type).filter(p=>p.controller.options.grouped),o=r.options.stacked,s=[],c=p=>{let h=p.controller.getParsed(n),v=h&&h[p.vScale.axis];if(Le(v)||isNaN(v))return true};for(let p of i)if(!(n!==void 0&&c(p))&&((o===false||s.indexOf(p.stack)===-1||o===void 0&&p.stack===void 0)&&s.push(p.stack),p.index===e))break;return s.length||s.push(void 0),s}_getStackCount(e){return this._getStacks(void 0,e).length}_getStackIndex(e,n,r){let i=this._getStacks(e,r),o=n!==void 0?i.indexOf(n):-1;return o===-1?i.length-1:o}_getRuler(){let e=this.options,n=this._cachedMeta,r=n.iScale,i=[],o,s;for(o=0,s=n.data.length;o<s;++o)i.push(r.getPixelForValue(this.getParsed(o)[r.axis],o));let c=e.barThickness;return {min:c||y6(n),pixels:i,start:r._startPixel,end:r._endPixel,stackCount:this._getStackCount(),scale:r,grouped:e.grouped,ratio:c?1:e.categoryPercentage*e.barPercentage}}_calculateBarValuePixels(e){let{_cachedMeta:{vScale:n,_stacked:r},options:{base:i,minBarLength:o}}=this,s=i||0,c=this.getParsed(e),p=c._custom,h=G0(p),v=c[n.axis],P=0,x=r?this.applyStack(n,c,r):v,T,I;x!==v&&(P=x-v,x=v),h&&(v=p.barStart,x=p.barEnd-p.barStart,v!==0&&go(v)!==go(p.barEnd)&&(P=0),P+=v);let R=!Le(i)&&!h?i:P,A=n.getPixelForValue(R);if(this.chart.getDataVisibility(e)?T=n.getPixelForValue(P+x):T=A,I=T-A,Math.abs(I)<o){I=S6(I,n,s)*o,v===s&&(A-=I/2);let O=n.getPixelForDecimal(0),N=n.getPixelForDecimal(1),V=Math.min(O,N),G=Math.max(O,N);A=Math.max(Math.min(A,G),V),T=A+I;}if(A===n.getPixelForValue(s)){let O=go(I)*n.getLineWidthForValue(s)/2;A+=O,I-=O;}return {size:I,base:A,head:T,center:T+I/2}}_calculateBarIndexPixels(e,n){let r=n.scale,i=this.options,o=i.skipNull,s=me(i.maxBarThickness,1/0),c,p;if(n.grouped){let h=o?this._getStackCount(e):n.stackCount,v=i.barThickness==="flex"?v6(e,n,i,h):b6(e,n,i,h),P=this._getStackIndex(this.index,this._cachedMeta.stack,o?e:void 0);c=v.start+v.chunk*P+v.chunk/2,p=Math.min(s,v.chunk*v.ratio);}else c=r.getPixelForValue(this.getParsed(e)[r.axis],e),p=Math.min(s,n.min*n.ratio);return {base:c-p/2,head:c+p/2,center:c,size:p}}draw(){let e=this._cachedMeta,n=e.vScale,r=e.data,i=r.length,o=0;for(;o<i;++o)this.getParsed(o)[n.axis]!==null&&r[o].draw(this._ctx);}};xf.id="bar";xf.defaults={datasetElementType:false,dataElementType:"bar",categoryPercentage:.8,barPercentage:.9,grouped:true,animations:{numbers:{type:"number",properties:["x","y","base","width","height"]}}};xf.overrides={scales:{_index_:{type:"category",offset:true,grid:{offset:true}},_value_:{type:"linear",beginAtZero:true}}};var Ef=class extends zi{initialize(){this.enableOptionSharing=true,super.initialize();}parsePrimitiveData(e,n,r,i){let o=super.parsePrimitiveData(e,n,r,i);for(let s=0;s<o.length;s++)o[s]._custom=this.resolveDataElementOptions(s+r).radius;return o}parseArrayData(e,n,r,i){let o=super.parseArrayData(e,n,r,i);for(let s=0;s<o.length;s++){let c=n[r+s];o[s]._custom=me(c[2],this.resolveDataElementOptions(s+r).radius);}return o}parseObjectData(e,n,r,i){let o=super.parseObjectData(e,n,r,i);for(let s=0;s<o.length;s++){let c=n[r+s];o[s]._custom=me(c&&c.r&&+c.r,this.resolveDataElementOptions(s+r).radius);}return o}getMaxOverflow(){let e=this._cachedMeta.data,n=0;for(let r=e.length-1;r>=0;--r)n=Math.max(n,e[r].size(this.resolveDataElementOptions(r))/2);return n>0&&n}getLabelAndValue(e){let n=this._cachedMeta,{xScale:r,yScale:i}=n,o=this.getParsed(e),s=r.getLabelForValue(o.x),c=i.getLabelForValue(o.y),p=o._custom;return {label:n.label,value:"("+s+", "+c+(p?", "+p:"")+")"}}update(e){let n=this._cachedMeta.data;this.updateElements(n,0,n.length,e);}updateElements(e,n,r,i){let o=i==="reset",{iScale:s,vScale:c}=this._cachedMeta,{sharedOptions:p,includeOptions:h}=this._getSharedOptions(n,i),v=s.axis,P=c.axis;for(let x=n;x<n+r;x++){let T=e[x],I=!o&&this.getParsed(x),R={},A=R[v]=o?s.getPixelForDecimal(.5):s.getPixelForValue(I[v]),O=R[P]=o?c.getBasePixel():c.getPixelForValue(I[P]);R.skip=isNaN(A)||isNaN(O),h&&(R.options=p||this.resolveDataElementOptions(x,T.active?"active":i),o&&(R.options.radius=0)),this.updateElement(T,x,R,i);}}resolveDataElementOptions(e,n){let r=this.getParsed(e),i=super.resolveDataElementOptions(e,n);i.$shared&&(i=Object.assign({},i,{$shared:false}));let o=i.radius;return n!=="active"&&(i.radius=0),i.radius+=me(r&&r._custom,o),i}};Ef.id="bubble";Ef.defaults={datasetElementType:false,dataElementType:"point",animations:{numbers:{type:"number",properties:["x","y","borderWidth","radius"]}}};Ef.overrides={scales:{x:{type:"linear"},y:{type:"linear"}},plugins:{tooltip:{callbacks:{title(){return ""}}}}};function T6(t,e,n){let r=1,i=1,o=0,s=0;if(e<rn){let c=t,p=c+e,h=Math.cos(c),v=Math.sin(c),P=Math.cos(p),x=Math.sin(p),T=(V,G,X)=>wc(V,c,p,true)?1:Math.max(G,G*n,X,X*n),I=(V,G,X)=>wc(V,c,p,true)?-1:Math.min(G,G*n,X,X*n),R=T(0,h,P),A=T(bn,v,x),O=I(Be,h,P),N=I(Be+bn,v,x);r=(R-O)/2,i=(A-N)/2,o=-(R+O)/2,s=-(A+N)/2;}return {ratioX:r,ratioY:i,offsetX:o,offsetY:s}}var Ac=class extends zi{constructor(e,n){super(e,n),this.enableOptionSharing=true,this.innerRadius=void 0,this.outerRadius=void 0,this.offsetX=void 0,this.offsetY=void 0;}linkScales(){}parse(e,n){let r=this.getDataset().data,i=this._cachedMeta;if(this._parsing===false)i._parsed=r;else {let o=p=>+r[p];if(Te(r[e])){let{key:p="value"}=this._parsing;o=h=>+ya(r[h],p);}let s,c;for(s=e,c=e+n;s<c;++s)i._parsed[s]=o(s);}}_getRotation(){return Qn(this.options.rotation-90)}_getCircumference(){return Qn(this.options.circumference)}_getRotationExtents(){let e=rn,n=-rn;for(let r=0;r<this.chart.data.datasets.length;++r)if(this.chart.isDatasetVisible(r)){let i=this.chart.getDatasetMeta(r).controller,o=i._getRotation(),s=i._getCircumference();e=Math.min(e,o),n=Math.max(n,o+s);}return {rotation:e,circumference:n-e}}update(e){let n=this.chart,{chartArea:r}=n,i=this._cachedMeta,o=i.data,s=this.getMaxBorderWidth()+this.getMaxOffset(o)+this.options.spacing,c=Math.max((Math.min(r.width,r.height)-s)/2,0),p=Math.min(f0(this.options.cutout,c),1),h=this._getRingWeight(this.index),{circumference:v,rotation:P}=this._getRotationExtents(),{ratioX:x,ratioY:T,offsetX:I,offsetY:R}=T6(P,v,p),A=(r.width-s)/x,O=(r.height-s)/T,N=Math.max(Math.min(A,O)/2,0),V=Og(this.options.radius,N),G=Math.max(V*p,0),X=(V-G)/this._getVisibleDatasetWeightTotal();this.offsetX=I*V,this.offsetY=R*V,i.total=this.calculateTotal(),this.outerRadius=V-X*this._getRingWeightOffset(this.index),this.innerRadius=Math.max(this.outerRadius-X*h,0),this.updateElements(o,0,o.length,e);}_circumference(e,n){let r=this.options,i=this._cachedMeta,o=this._getCircumference();return n&&r.animation.animateRotate||!this.chart.getDataVisibility(e)||i._parsed[e]===null||i.data[e].hidden?0:this.calculateCircumference(i._parsed[e]*o/rn)}updateElements(e,n,r,i){let o=i==="reset",s=this.chart,c=s.chartArea,h=s.options.animation,v=(c.left+c.right)/2,P=(c.top+c.bottom)/2,x=o&&h.animateScale,T=x?0:this.innerRadius,I=x?0:this.outerRadius,{sharedOptions:R,includeOptions:A}=this._getSharedOptions(n,i),O=this._getRotation(),N;for(N=0;N<n;++N)O+=this._circumference(N,o);for(N=n;N<n+r;++N){let V=this._circumference(N,o),G=e[N],X={x:v+this.offsetX,y:P+this.offsetY,startAngle:O,endAngle:O+V,circumference:V,outerRadius:I,innerRadius:T};A&&(X.options=R||this.resolveDataElementOptions(N,G.active?"active":i)),O+=V,this.updateElement(G,N,X,i);}}calculateTotal(){let e=this._cachedMeta,n=e.data,r=0,i;for(i=0;i<n.length;i++){let o=e._parsed[i];o!==null&&!isNaN(o)&&this.chart.getDataVisibility(i)&&!n[i].hidden&&(r+=Math.abs(o));}return r}calculateCircumference(e){let n=this._cachedMeta.total;return n>0&&!isNaN(e)?rn*(Math.abs(e)/n):0}getLabelAndValue(e){let n=this._cachedMeta,r=this.chart,i=r.data.labels||[],o=kc(n._parsed[e],r.options.locale);return {label:i[e]||"",value:o}}getMaxBorderWidth(e){let n=0,r=this.chart,i,o,s,c,p;if(!e){for(i=0,o=r.data.datasets.length;i<o;++i)if(r.isDatasetVisible(i)){s=r.getDatasetMeta(i),e=s.data,c=s.controller;break}}if(!e)return 0;for(i=0,o=e.length;i<o;++i)p=c.resolveDataElementOptions(i),p.borderAlign!=="inner"&&(n=Math.max(n,p.borderWidth||0,p.hoverBorderWidth||0));return n}getMaxOffset(e){let n=0;for(let r=0,i=e.length;r<i;++r){let o=this.resolveDataElementOptions(r);n=Math.max(n,o.offset||0,o.hoverOffset||0);}return n}_getRingWeightOffset(e){let n=0;for(let r=0;r<e;++r)this.chart.isDatasetVisible(r)&&(n+=this._getRingWeight(r));return n}_getRingWeight(e){return Math.max(me(this.chart.data.datasets[e].weight,1),0)}_getVisibleDatasetWeightTotal(){return this._getRingWeightOffset(this.chart.data.datasets.length)||1}};Ac.id="doughnut";Ac.defaults={datasetElementType:false,dataElementType:"arc",animation:{animateRotate:true,animateScale:false},animations:{numbers:{type:"number",properties:["circumference","endAngle","innerRadius","outerRadius","startAngle","x","y","offset","borderWidth","spacing"]}},cutout:"50%",rotation:0,circumference:360,radius:"100%",spacing:0,indexAxis:"r"};Ac.descriptors={_scriptable:t=>t!=="spacing",_indexable:t=>t!=="spacing"};Ac.overrides={aspectRatio:1,plugins:{legend:{labels:{generateLabels(t){let e=t.data;if(e.labels.length&&e.datasets.length){let{labels:{pointStyle:n}}=t.legend.options;return e.labels.map((r,i)=>{let s=t.getDatasetMeta(0).controller.getStyle(i);return {text:r,fillStyle:s.backgroundColor,strokeStyle:s.borderColor,lineWidth:s.borderWidth,pointStyle:n,hidden:!t.getDataVisibility(i),index:i}})}return []}},onClick(t,e,n){n.chart.toggleDataVisibility(e.index),n.chart.update();}},tooltip:{callbacks:{title(){return ""},label(t){let e=t.label,n=": "+t.formattedValue;return He(e)?(e=e.slice(),e[0]+=n):e+=n,e}}}}};var _f=class extends zi{initialize(){this.enableOptionSharing=true,this.supportsDecimation=true,super.initialize();}update(e){let n=this._cachedMeta,{dataset:r,data:i=[],_dataset:o}=n,s=this.chart._animationsDisabled,{start:c,count:p}=jg(n,i,s);this._drawStart=c,this._drawCount=p,Vg(n)&&(c=0,p=i.length),r._chart=this.chart,r._datasetIndex=this.index,r._decimated=!!o._decimated,r.points=i;let h=this.resolveDatasetElementOptions(e);this.options.showLine||(h.borderWidth=0),h.segment=this.options.segment,this.updateElement(r,void 0,{animated:!s,options:h},e),this.updateElements(i,c,p,e);}updateElements(e,n,r,i){let o=i==="reset",{iScale:s,vScale:c,_stacked:p,_dataset:h}=this._cachedMeta,{sharedOptions:v,includeOptions:P}=this._getSharedOptions(n,i),x=s.axis,T=c.axis,{spanGaps:I,segment:R}=this.options,A=Vi(I)?I:Number.POSITIVE_INFINITY,O=this.chart._animationsDisabled||o||i==="none",N=n>0&&this.getParsed(n-1);for(let V=n;V<n+r;++V){let G=e[V],X=this.getParsed(V),nt=O?G:{},st=Le(X[T]),U=nt[x]=s.getPixelForValue(X[x],V),j=nt[T]=o||st?c.getBasePixel():c.getPixelForValue(p?this.applyStack(c,X,p):X[T],V);nt.skip=isNaN(U)||isNaN(j)||st,nt.stop=V>0&&Math.abs(X[x]-N[x])>A,R&&(nt.parsed=X,nt.raw=h.data[V]),P&&(nt.options=v||this.resolveDataElementOptions(V,G.active?"active":i)),O||this.updateElement(G,V,nt,i),N=X;}}getMaxOverflow(){let e=this._cachedMeta,n=e.dataset,r=n.options&&n.options.borderWidth||0,i=e.data||[];if(!i.length)return r;let o=i[0].size(this.resolveDataElementOptions(0)),s=i[i.length-1].size(this.resolveDataElementOptions(i.length-1));return Math.max(r,o,s)/2}draw(){let e=this._cachedMeta;e.dataset.updateControlPoints(this.chart.chartArea,e.iScale.axis),super.draw();}};_f.id="line";_f.defaults={datasetElementType:"line",dataElementType:"point",showLine:true,spanGaps:false};_f.overrides={scales:{_index_:{type:"category"},_value_:{type:"linear"}}};var Tf=class extends zi{constructor(e,n){super(e,n),this.innerRadius=void 0,this.outerRadius=void 0;}getLabelAndValue(e){let n=this._cachedMeta,r=this.chart,i=r.data.labels||[],o=kc(n._parsed[e].r,r.options.locale);return {label:i[e]||"",value:o}}parseObjectData(e,n,r,i){return Qg.bind(this)(e,n,r,i)}update(e){let n=this._cachedMeta.data;this._updateRadius(),this.updateElements(n,0,n.length,e);}getMinMax(){let e=this._cachedMeta,n={min:Number.POSITIVE_INFINITY,max:Number.NEGATIVE_INFINITY};return e.data.forEach((r,i)=>{let o=this.getParsed(i).r;!isNaN(o)&&this.chart.getDataVisibility(i)&&(o<n.min&&(n.min=o),o>n.max&&(n.max=o));}),n}_updateRadius(){let e=this.chart,n=e.chartArea,r=e.options,i=Math.min(n.right-n.left,n.bottom-n.top),o=Math.max(i/2,0),s=Math.max(r.cutoutPercentage?o/100*r.cutoutPercentage:1,0),c=(o-s)/e.getVisibleDatasetCount();this.outerRadius=o-c*this.index,this.innerRadius=this.outerRadius-c;}updateElements(e,n,r,i){let o=i==="reset",s=this.chart,p=s.options.animation,h=this._cachedMeta.rScale,v=h.xCenter,P=h.yCenter,x=h.getIndexAngle(0)-.5*Be,T=x,I,R=360/this.countVisibleElements();for(I=0;I<n;++I)T+=this._computeAngle(I,i,R);for(I=n;I<n+r;I++){let A=e[I],O=T,N=T+this._computeAngle(I,i,R),V=s.getDataVisibility(I)?h.getDistanceFromCenterForValue(this.getParsed(I).r):0;T=N,o&&(p.animateScale&&(V=0),p.animateRotate&&(O=N=x));let G={x:v,y:P,innerRadius:0,outerRadius:V,startAngle:O,endAngle:N,options:this.resolveDataElementOptions(I,A.active?"active":i)};this.updateElement(A,I,G,i);}}countVisibleElements(){let e=this._cachedMeta,n=0;return e.data.forEach((r,i)=>{!isNaN(this.getParsed(i).r)&&this.chart.getDataVisibility(i)&&n++;}),n}_computeAngle(e,n,r){return this.chart.getDataVisibility(e)?Qn(this.resolveDataElementOptions(e,n).angle||r):0}};Tf.id="polarArea";Tf.defaults={dataElementType:"arc",animation:{animateRotate:true,animateScale:true},animations:{numbers:{type:"number",properties:["x","y","startAngle","endAngle","innerRadius","outerRadius"]}},indexAxis:"r",startAngle:0};Tf.overrides={aspectRatio:1,plugins:{legend:{labels:{generateLabels(t){let e=t.data;if(e.labels.length&&e.datasets.length){let{labels:{pointStyle:n}}=t.legend.options;return e.labels.map((r,i)=>{let s=t.getDatasetMeta(0).controller.getStyle(i);return {text:r,fillStyle:s.backgroundColor,strokeStyle:s.borderColor,lineWidth:s.borderWidth,pointStyle:n,hidden:!t.getDataVisibility(i),index:i}})}return []}},onClick(t,e,n){n.chart.toggleDataVisibility(e.index),n.chart.update();}},tooltip:{callbacks:{title(){return ""},label(t){return t.chart.data.labels[t.dataIndex]+": "+t.formattedValue}}}},scales:{r:{type:"radialLinear",angleLines:{display:false},beginAtZero:true,grid:{circular:true},pointLabels:{display:false},startAngle:0}}};var uy=class extends Ac{};uy.id="pie";uy.defaults={cutout:0,rotation:0,circumference:360,radius:"100%"};var wf=class extends zi{getLabelAndValue(e){let n=this._cachedMeta.vScale,r=this.getParsed(e);return {label:n.getLabels()[e],value:""+n.getLabelForValue(r[n.axis])}}parseObjectData(e,n,r,i){return Qg.bind(this)(e,n,r,i)}update(e){let n=this._cachedMeta,r=n.dataset,i=n.data||[],o=n.iScale.getLabels();if(r.points=i,e!=="resize"){let s=this.resolveDatasetElementOptions(e);this.options.showLine||(s.borderWidth=0);let c={_loop:true,_fullLoop:o.length===i.length,options:s};this.updateElement(r,void 0,c,e);}this.updateElements(i,0,i.length,e);}updateElements(e,n,r,i){let o=this._cachedMeta.rScale,s=i==="reset";for(let c=n;c<n+r;c++){let p=e[c],h=this.resolveDataElementOptions(c,p.active?"active":i),v=o.getPointPositionForValue(c,this.getParsed(c).r),P=s?o.xCenter:v.x,x=s?o.yCenter:v.y,T={x:P,y:x,angle:v.angle,skip:isNaN(P)||isNaN(x),options:h};this.updateElement(p,c,T,i);}}};wf.id="radar";wf.defaults={datasetElementType:"line",dataElementType:"point",indexAxis:"r",showLine:true,elements:{line:{fill:"start"}}};wf.overrides={aspectRatio:1,scales:{r:{type:"radialLinear"}}};var br=class{constructor(){this.x=void 0,this.y=void 0,this.active=false,this.options=void 0,this.$animations=void 0;}tooltipPosition(e){let{x:n,y:r}=this.getProps(["x","y"],e);return {x:n,y:r}}hasValue(){return Vi(this.x)&&Vi(this.y)}getProps(e,n){let r=this.$animations;if(!n||!r)return this;let i={};return e.forEach(o=>{i[o]=r[o]&&r[o].active()?r[o]._to:this[o];}),i}};br.defaults={};br.defaultRoutes=void 0;var Uw={values(t){return He(t)?t:""+t},numeric(t,e,n){if(t===0)return "0";let r=this.chart.options.locale,i,o=t;if(n.length>1){let h=Math.max(Math.abs(n[0].value),Math.abs(n[n.length-1].value));(h<1e-4||h>1e15)&&(i="scientific"),o=w6(t,n);}let s=Ei(Math.abs(o)),c=Math.max(Math.min(-1*Math.floor(s),20),0),p={notation:i,minimumFractionDigits:c,maximumFractionDigits:c};return Object.assign(p,this.options.ticks.format),kc(t,r,p)},logarithmic(t,e,n){if(t===0)return "0";let r=t/Math.pow(10,Math.floor(Ei(t)));return r===1||r===2||r===5?Uw.numeric.call(this,t,e,n):""}};function w6(t,e){let n=e.length>3?e[2].value-e[1].value:e[1].value-e[0].value;return Math.abs(n)>=1&&t!==Math.floor(t)&&(n=t-Math.floor(t)),n}var vy={formatters:Uw};ke.set("scale",{display:true,offset:false,reverse:false,beginAtZero:false,bounds:"ticks",grace:0,grid:{display:true,lineWidth:1,drawBorder:true,drawOnChartArea:true,drawTicks:true,tickLength:8,tickWidth:(t,e)=>e.lineWidth,tickColor:(t,e)=>e.color,offset:false,borderDash:[],borderDashOffset:0,borderWidth:1},title:{display:false,text:"",padding:{top:4,bottom:4}},ticks:{minRotation:0,maxRotation:50,mirror:false,textStrokeWidth:0,textStrokeColor:"",padding:3,display:true,autoSkip:true,autoSkipPadding:3,labelOffset:0,callback:vy.formatters.values,minor:{},major:{},align:"center",crossAlign:"near",showLabelBackdrop:false,backdropColor:"rgba(255, 255, 255, 0.75)",backdropPadding:2}});ke.route("scale.ticks","color","","color");ke.route("scale.grid","color","","borderColor");ke.route("scale.grid","borderColor","","borderColor");ke.route("scale.title","color","","color");ke.describe("scale",{_fallback:false,_scriptable:t=>!t.startsWith("before")&&!t.startsWith("after")&&t!=="callback"&&t!=="parser",_indexable:t=>t!=="borderDash"&&t!=="tickBorderDash"});ke.describe("scales",{_fallback:"scale"});ke.describe("scale.ticks",{_scriptable:t=>t!=="backdropPadding"&&t!=="callback",_indexable:t=>t!=="backdropPadding"});function I6(t,e){let n=t.options.ticks,r=n.maxTicksLimit||k6(t),i=n.major.enabled?A6(e):[],o=i.length,s=i[0],c=i[o-1],p=[];if(o>r)return O6(e,p,i,o/r),p;let h=D6(i,e,r);if(o>0){let v,P,x=o>1?Math.round((c-s)/(o-1)):null;for(iy(e,p,h,Le(x)?0:s-x,s),v=0,P=o-1;v<P;v++)iy(e,p,h,i[v],i[v+1]);return iy(e,p,h,c,Le(x)?e.length:c+x),p}return iy(e,p,h),p}function k6(t){let e=t.options.offset,n=t._tickSize(),r=t._length/n+(e?0:1),i=t._maxLength/n;return Math.floor(Math.min(r,i))}function D6(t,e,n){let r=R6(t),i=e.length/n;if(!r)return Math.max(i,1);let o=m0(r);for(let s=0,c=o.length-1;s<c;s++){let p=o[s];if(p>i)return p}return Math.max(i,1)}function A6(t){let e=[],n,r;for(n=0,r=t.length;n<r;n++)t[n].major&&e.push(n);return e}function O6(t,e,n,r){let i=0,o=n[0],s;for(r=Math.ceil(r),s=0;s<t.length;s++)s===o&&(e.push(t[s]),i++,o=n[i*r]);}function iy(t,e,n,r,i){let o=me(r,0),s=Math.min(me(i,t.length),t.length),c=0,p,h,v;for(n=Math.ceil(n),i&&(p=i-r,n=p/Math.floor(p/n)),v=o;v<0;)c++,v=Math.round(o+c*n);for(h=Math.max(o,0);h<s;h++)h===v&&(e.push(t[h]),c++,v=Math.round(o+c*n));}function R6(t){let e=t.length,n,r;if(e<2)return false;for(r=t[0],n=1;n<e;++n)if(t[n]-t[n-1]!==r)return false;return r}var F6=t=>t==="left"?"right":t==="right"?"left":t,rw=(t,e,n)=>e==="top"||e==="left"?t[e]+n:t[e]-n;function iw(t,e){let n=[],r=t.length/e,i=t.length,o=0;for(;o<i;o+=r)n.push(t[Math.floor(o)]);return n}function M6(t,e,n){let r=t.ticks.length,i=Math.min(e,r-1),o=t._startPixel,s=t._endPixel,c=1e-6,p=t.getPixelForTick(i),h;if(!(n&&(r===1?h=Math.max(p-o,s-p):e===0?h=(t.getPixelForTick(1)-p)/2:h=(p-t.getPixelForTick(i-1))/2,p+=i<e?h:-h,p<o-c||p>s+c)))return p}function N6(t,e){tn(t,n=>{let r=n.gc,i=r.length/2,o;if(i>e){for(o=0;o<i;++o)delete n.data[r[o]];r.splice(0,i);}});}function yf(t){return t.drawTicks?t.tickLength:0}function ow(t,e){if(!t.display)return 0;let n=Sn(t.font,e),r=$n(t.padding);return (He(t.text)?t.text.length:1)*n.lineHeight+r.height}function L6(t,e){return ba(t,{scale:e,type:"scale"})}function B6(t,e,n){return ba(t,{tick:n,index:e,type:"tick"})}function U6(t,e,n){let r=uf(t);return (n&&e!=="right"||!n&&e==="right")&&(r=F6(r)),r}function $6(t,e,n,r){let{top:i,left:o,bottom:s,right:c,chart:p}=t,{chartArea:h,scales:v}=p,P=0,x,T,I,R=s-i,A=c-o;if(t.isHorizontal()){if(T=Lr(r,o,c),Te(n)){let O=Object.keys(n)[0],N=n[O];I=v[O].getPixelForValue(N)+R-e;}else n==="center"?I=(h.bottom+h.top)/2+R-e:I=rw(t,n,e);x=c-o;}else {if(Te(n)){let O=Object.keys(n)[0],N=n[O];T=v[O].getPixelForValue(N)-A+e;}else n==="center"?T=(h.left+h.right)/2-A+e:T=rw(t,n,e);I=Lr(r,s,i),P=n==="left"?-bn:bn;}return {titleX:T,titleY:I,maxWidth:x,rotation:P}}var Oc=class t extends br{constructor(e){super(),this.id=e.id,this.type=e.type,this.options=void 0,this.ctx=e.ctx,this.chart=e.chart,this.top=void 0,this.bottom=void 0,this.left=void 0,this.right=void 0,this.width=void 0,this.height=void 0,this._margins={left:0,right:0,top:0,bottom:0},this.maxWidth=void 0,this.maxHeight=void 0,this.paddingTop=void 0,this.paddingBottom=void 0,this.paddingLeft=void 0,this.paddingRight=void 0,this.axis=void 0,this.labelRotation=void 0,this.min=void 0,this.max=void 0,this._range=void 0,this.ticks=[],this._gridLineItems=null,this._labelItems=null,this._labelSizes=null,this._length=0,this._maxLength=0,this._longestTextCache={},this._startPixel=void 0,this._endPixel=void 0,this._reversePixels=false,this._userMax=void 0,this._userMin=void 0,this._suggestedMax=void 0,this._suggestedMin=void 0,this._ticksLength=0,this._borderValue=0,this._cache={},this._dataLimitsCached=false,this.$context=void 0;}init(e){this.options=e.setContext(this.getContext()),this.axis=e.axis,this._userMin=this.parse(e.min),this._userMax=this.parse(e.max),this._suggestedMin=this.parse(e.suggestedMin),this._suggestedMax=this.parse(e.suggestedMax);}parse(e,n){return e}getUserBounds(){let{_userMin:e,_userMax:n,_suggestedMin:r,_suggestedMax:i}=this;return e=xi(e,Number.POSITIVE_INFINITY),n=xi(n,Number.NEGATIVE_INFINITY),r=xi(r,Number.POSITIVE_INFINITY),i=xi(i,Number.NEGATIVE_INFINITY),{min:xi(e,r),max:xi(n,i),minDefined:Mn(e),maxDefined:Mn(n)}}getMinMax(e){let{min:n,max:r,minDefined:i,maxDefined:o}=this.getUserBounds(),s;if(i&&o)return {min:n,max:r};let c=this.getMatchingVisibleMetas();for(let p=0,h=c.length;p<h;++p)s=c[p].controller.getMinMax(this,e),i||(n=Math.min(n,s.min)),o||(r=Math.max(r,s.max));return n=o&&n>r?r:n,r=i&&n>r?n:r,{min:xi(n,xi(r,n)),max:xi(r,xi(n,r))}}getPadding(){return {left:this.paddingLeft||0,top:this.paddingTop||0,right:this.paddingRight||0,bottom:this.paddingBottom||0}}getTicks(){return this.ticks}getLabels(){let e=this.chart.data;return this.options.labels||(this.isHorizontal()?e.xLabels:e.yLabels)||e.labels||[]}beforeLayout(){this._cache={},this._dataLimitsCached=false;}beforeUpdate(){Qe(this.options.beforeUpdate,[this]);}update(e,n,r){let{beginAtZero:i,grace:o,ticks:s}=this.options,c=s.sampleSize;this.beforeUpdate(),this.maxWidth=e,this.maxHeight=n,this._margins=r=Object.assign({left:0,right:0,top:0,bottom:0},r),this.ticks=null,this._labelSizes=null,this._gridLineItems=null,this._labelItems=null,this.beforeSetDimensions(),this.setDimensions(),this.afterSetDimensions(),this._maxLength=this.isHorizontal()?this.width+r.left+r.right:this.height+r.top+r.bottom,this._dataLimitsCached||(this.beforeDataLimits(),this.determineDataLimits(),this.afterDataLimits(),this._range=D0(this,o,i),this._dataLimitsCached=true),this.beforeBuildTicks(),this.ticks=this.buildTicks()||[],this.afterBuildTicks();let p=c<this.ticks.length;this._convertTicksToLabels(p?iw(this.ticks,c):this.ticks),this.configure(),this.beforeCalculateLabelRotation(),this.calculateLabelRotation(),this.afterCalculateLabelRotation(),s.display&&(s.autoSkip||s.source==="auto")&&(this.ticks=I6(this,this.ticks),this._labelSizes=null,this.afterAutoSkip()),p&&this._convertTicksToLabels(this.ticks),this.beforeFit(),this.fit(),this.afterFit(),this.afterUpdate();}configure(){let e=this.options.reverse,n,r;this.isHorizontal()?(n=this.left,r=this.right):(n=this.top,r=this.bottom,e=!e),this._startPixel=n,this._endPixel=r,this._reversePixels=e,this._length=r-n,this._alignToPixels=this.options.alignToPixels;}afterUpdate(){Qe(this.options.afterUpdate,[this]);}beforeSetDimensions(){Qe(this.options.beforeSetDimensions,[this]);}setDimensions(){this.isHorizontal()?(this.width=this.maxWidth,this.left=0,this.right=this.width):(this.height=this.maxHeight,this.top=0,this.bottom=this.height),this.paddingLeft=0,this.paddingTop=0,this.paddingRight=0,this.paddingBottom=0;}afterSetDimensions(){Qe(this.options.afterSetDimensions,[this]);}_callHooks(e){this.chart.notifyPlugins(e,this.getContext()),Qe(this.options[e],[this]);}beforeDataLimits(){this._callHooks("beforeDataLimits");}determineDataLimits(){}afterDataLimits(){this._callHooks("afterDataLimits");}beforeBuildTicks(){this._callHooks("beforeBuildTicks");}buildTicks(){return []}afterBuildTicks(){this._callHooks("afterBuildTicks");}beforeTickToLabelConversion(){Qe(this.options.beforeTickToLabelConversion,[this]);}generateTickLabels(e){let n=this.options.ticks,r,i,o;for(r=0,i=e.length;r<i;r++)o=e[r],o.label=Qe(n.callback,[o.value,r,e],this);}afterTickToLabelConversion(){Qe(this.options.afterTickToLabelConversion,[this]);}beforeCalculateLabelRotation(){Qe(this.options.beforeCalculateLabelRotation,[this]);}calculateLabelRotation(){let e=this.options,n=e.ticks,r=this.ticks.length,i=n.minRotation||0,o=n.maxRotation,s=i,c,p,h;if(!this._isVisible()||!n.display||i>=o||r<=1||!this.isHorizontal()){this.labelRotation=i;return}let v=this._getLabelSizes(),P=v.widest.width,x=v.highest.height,T=Nr(this.chart.width-P,0,this.maxWidth);c=e.offset?this.maxWidth/r:T/(r-1),P+6>c&&(c=T/(r-(e.offset?.5:1)),p=this.maxHeight-yf(e.grid)-n.padding-ow(e.title,this.chart.options.font),h=Math.sqrt(P*P+x*x),s=Tc(Math.min(Math.asin(Nr((v.highest.height+6)/c,-1,1)),Math.asin(Nr(p/h,-1,1))-Math.asin(Nr(x/h,-1,1)))),s=Math.max(i,Math.min(o,s))),this.labelRotation=s;}afterCalculateLabelRotation(){Qe(this.options.afterCalculateLabelRotation,[this]);}afterAutoSkip(){}beforeFit(){Qe(this.options.beforeFit,[this]);}fit(){let e={width:0,height:0},{chart:n,options:{ticks:r,title:i,grid:o}}=this,s=this._isVisible(),c=this.isHorizontal();if(s){let p=ow(i,n.options.font);if(c?(e.width=this.maxWidth,e.height=yf(o)+p):(e.height=this.maxHeight,e.width=yf(o)+p),r.display&&this.ticks.length){let{first:h,last:v,widest:P,highest:x}=this._getLabelSizes(),T=r.padding*2,I=Qn(this.labelRotation),R=Math.cos(I),A=Math.sin(I);if(c){let O=r.mirror?0:A*P.width+R*x.height;e.height=Math.min(this.maxHeight,e.height+O+T);}else {let O=r.mirror?0:R*P.width+A*x.height;e.width=Math.min(this.maxWidth,e.width+O+T);}this._calculatePadding(h,v,A,R);}}this._handleMargins(),c?(this.width=this._length=n.width-this._margins.left-this._margins.right,this.height=e.height):(this.width=e.width,this.height=this._length=n.height-this._margins.top-this._margins.bottom);}_calculatePadding(e,n,r,i){let{ticks:{align:o,padding:s},position:c}=this.options,p=this.labelRotation!==0,h=c!=="top"&&this.axis==="x";if(this.isHorizontal()){let v=this.getPixelForTick(0)-this.left,P=this.right-this.getPixelForTick(this.ticks.length-1),x=0,T=0;p?h?(x=i*e.width,T=r*n.height):(x=r*e.height,T=i*n.width):o==="start"?T=n.width:o==="end"?x=e.width:o!=="inner"&&(x=e.width/2,T=n.width/2),this.paddingLeft=Math.max((x-v+s)*this.width/(this.width-v),0),this.paddingRight=Math.max((T-P+s)*this.width/(this.width-P),0);}else {let v=n.height/2,P=e.height/2;o==="start"?(v=0,P=e.height):o==="end"&&(v=n.height,P=0),this.paddingTop=v+s,this.paddingBottom=P+s;}}_handleMargins(){this._margins&&(this._margins.left=Math.max(this.paddingLeft,this._margins.left),this._margins.top=Math.max(this.paddingTop,this._margins.top),this._margins.right=Math.max(this.paddingRight,this._margins.right),this._margins.bottom=Math.max(this.paddingBottom,this._margins.bottom));}afterFit(){Qe(this.options.afterFit,[this]);}isHorizontal(){let{axis:e,position:n}=this.options;return n==="top"||n==="bottom"||e==="x"}isFullSize(){return this.options.fullSize}_convertTicksToLabels(e){this.beforeTickToLabelConversion(),this.generateTickLabels(e);let n,r;for(n=0,r=e.length;n<r;n++)Le(e[n].label)&&(e.splice(n,1),r--,n--);this.afterTickToLabelConversion();}_getLabelSizes(){let e=this._labelSizes;if(!e){let n=this.options.ticks.sampleSize,r=this.ticks;n<r.length&&(r=iw(r,n)),this._labelSizes=e=this._computeLabelSizes(r,r.length);}return e}_computeLabelSizes(e,n){let{ctx:r,_longestTextCache:i}=this,o=[],s=[],c=0,p=0,h,v,P,x,T,I,R,A,O,N,V;for(h=0;h<n;++h){if(x=e[h].label,T=this._resolveTickFontOptions(h),r.font=I=T.string,R=i[I]=i[I]||{data:{},gc:[]},A=T.lineHeight,O=N=0,!Le(x)&&!He(x))O=nd(r,R.data,R.gc,O,x),N=A;else if(He(x))for(v=0,P=x.length;v<P;++v)V=x[v],!Le(V)&&!He(V)&&(O=nd(r,R.data,R.gc,O,V),N+=A);o.push(O),s.push(N),c=Math.max(O,c),p=Math.max(N,p);}N6(i,n);let G=o.indexOf(c),X=s.indexOf(p),nt=st=>({width:o[st]||0,height:s[st]||0});return {first:nt(0),last:nt(n-1),widest:nt(G),highest:nt(X),widths:o,heights:s}}getLabelForValue(e){return e}getPixelForValue(e,n){return NaN}getValueForPixel(e){}getPixelForTick(e){let n=this.ticks;return e<0||e>n.length-1?null:this.getPixelForValue(n[e].value)}getPixelForDecimal(e){this._reversePixels&&(e=1-e);let n=this._startPixel+e*this._length;return y0(this._alignToPixels?rs(this.chart,n,0):n)}getDecimalForPixel(e){let n=(e-this._startPixel)/this._length;return this._reversePixels?1-n:n}getBasePixel(){return this.getPixelForValue(this.getBaseValue())}getBaseValue(){let{min:e,max:n}=this;return e<0&&n<0?n:e>0&&n>0?e:0}getContext(e){let n=this.ticks||[];if(e>=0&&e<n.length){let r=n[e];return r.$context||(r.$context=B6(this.getContext(),e,r))}return this.$context||(this.$context=L6(this.chart.getContext(),this))}_tickSize(){let e=this.options.ticks,n=Qn(this.labelRotation),r=Math.abs(Math.cos(n)),i=Math.abs(Math.sin(n)),o=this._getLabelSizes(),s=e.autoSkipPadding||0,c=o?o.widest.width+s:0,p=o?o.highest.height+s:0;return this.isHorizontal()?p*r>c*i?c/r:p/i:p*i<c*r?p/r:c/i}_isVisible(){let e=this.options.display;return e!=="auto"?!!e:this.getMatchingVisibleMetas().length>0}_computeGridLineItems(e){let n=this.axis,r=this.chart,i=this.options,{grid:o,position:s}=i,c=o.offset,p=this.isHorizontal(),v=this.ticks.length+(c?1:0),P=yf(o),x=[],T=o.setContext(this.getContext()),I=T.drawBorder?T.borderWidth:0,R=I/2,A=function(mt){return rs(r,mt,I)},O,N,V,G,X,nt,st,U,j,ut,Y,at;if(s==="top")O=A(this.bottom),nt=this.bottom-P,U=O-R,ut=A(e.top)+R,at=e.bottom;else if(s==="bottom")O=A(this.top),ut=e.top,at=A(e.bottom)-R,nt=O+R,U=this.top+P;else if(s==="left")O=A(this.right),X=this.right-P,st=O-R,j=A(e.left)+R,Y=e.right;else if(s==="right")O=A(this.left),j=e.left,Y=A(e.right)-R,X=O+R,st=this.left+P;else if(n==="x"){if(s==="center")O=A((e.top+e.bottom)/2+.5);else if(Te(s)){let mt=Object.keys(s)[0],Ct=s[mt];O=A(this.chart.scales[mt].getPixelForValue(Ct));}ut=e.top,at=e.bottom,nt=O+R,U=nt+P;}else if(n==="y"){if(s==="center")O=A((e.left+e.right)/2);else if(Te(s)){let mt=Object.keys(s)[0],Ct=s[mt];O=A(this.chart.scales[mt].getPixelForValue(Ct));}X=O-R,st=X-P,j=e.left,Y=e.right;}let pt=me(i.ticks.maxTicksLimit,v),dt=Math.max(1,Math.ceil(v/pt));for(N=0;N<v;N+=dt){let mt=o.setContext(this.getContext(N)),Ct=mt.lineWidth,jt=mt.color,Gt=mt.borderDash||[],Jt=mt.borderDashOffset,ee=mt.tickWidth,re=mt.tickColor,Ee=mt.tickBorderDash||[],je=mt.tickBorderDashOffset;V=M6(this,N,c),V!==void 0&&(G=rs(r,V,Ct),p?X=st=j=Y=G:nt=U=ut=at=G,x.push({tx1:X,ty1:nt,tx2:st,ty2:U,x1:j,y1:ut,x2:Y,y2:at,width:Ct,color:jt,borderDash:Gt,borderDashOffset:Jt,tickWidth:ee,tickColor:re,tickBorderDash:Ee,tickBorderDashOffset:je}));}return this._ticksLength=v,this._borderValue=O,x}_computeLabelItems(e){let n=this.axis,r=this.options,{position:i,ticks:o}=r,s=this.isHorizontal(),c=this.ticks,{align:p,crossAlign:h,padding:v,mirror:P}=o,x=yf(r.grid),T=x+v,I=P?-v:T,R=-Qn(this.labelRotation),A=[],O,N,V,G,X,nt,st,U,j,ut,Y,at,pt="middle";if(i==="top")nt=this.bottom-I,st=this._getXAxisLabelAlignment();else if(i==="bottom")nt=this.top+I,st=this._getXAxisLabelAlignment();else if(i==="left"){let mt=this._getYAxisLabelAlignment(x);st=mt.textAlign,X=mt.x;}else if(i==="right"){let mt=this._getYAxisLabelAlignment(x);st=mt.textAlign,X=mt.x;}else if(n==="x"){if(i==="center")nt=(e.top+e.bottom)/2+T;else if(Te(i)){let mt=Object.keys(i)[0],Ct=i[mt];nt=this.chart.scales[mt].getPixelForValue(Ct)+T;}st=this._getXAxisLabelAlignment();}else if(n==="y"){if(i==="center")X=(e.left+e.right)/2-T;else if(Te(i)){let mt=Object.keys(i)[0],Ct=i[mt];X=this.chart.scales[mt].getPixelForValue(Ct);}st=this._getYAxisLabelAlignment(x).textAlign;}n==="y"&&(p==="start"?pt="top":p==="end"&&(pt="bottom"));let dt=this._getLabelSizes();for(O=0,N=c.length;O<N;++O){V=c[O],G=V.label;let mt=o.setContext(this.getContext(O));U=this.getPixelForTick(O)+o.labelOffset,j=this._resolveTickFontOptions(O),ut=j.lineHeight,Y=He(G)?G.length:1;let Ct=Y/2,jt=mt.color,Gt=mt.textStrokeColor,Jt=mt.textStrokeWidth,ee=st;s?(X=U,st==="inner"&&(O===N-1?ee=this.options.reverse?"left":"right":O===0?ee=this.options.reverse?"right":"left":ee="center"),i==="top"?h==="near"||R!==0?at=-Y*ut+ut/2:h==="center"?at=-dt.highest.height/2-Ct*ut+ut:at=-dt.highest.height+ut/2:h==="near"||R!==0?at=ut/2:h==="center"?at=dt.highest.height/2-Ct*ut:at=dt.highest.height-Y*ut,P&&(at*=-1)):(nt=U,at=(1-Y)*ut/2);let re;if(mt.showLabelBackdrop){let Ee=$n(mt.backdropPadding),je=dt.heights[O],sn=dt.widths[O],Ze=nt+at-Ee.top,Pn=X-Ee.left;switch(pt){case "middle":Ze-=je/2;break;case "bottom":Ze-=je;break}switch(st){case "center":Pn-=sn/2;break;case "right":Pn-=sn;break}re={left:Pn,top:Ze,width:sn+Ee.width,height:je+Ee.height,color:mt.backdropColor};}A.push({rotation:R,label:G,font:j,color:jt,strokeColor:Gt,strokeWidth:Jt,textOffset:at,textAlign:ee,textBaseline:pt,translation:[X,nt],backdrop:re});}return A}_getXAxisLabelAlignment(){let{position:e,ticks:n}=this.options;if(-Qn(this.labelRotation))return e==="top"?"left":"right";let i="center";return n.align==="start"?i="left":n.align==="end"?i="right":n.align==="inner"&&(i="inner"),i}_getYAxisLabelAlignment(e){let{position:n,ticks:{crossAlign:r,mirror:i,padding:o}}=this.options,s=this._getLabelSizes(),c=e+o,p=s.widest.width,h,v;return n==="left"?i?(v=this.right+o,r==="near"?h="left":r==="center"?(h="center",v+=p/2):(h="right",v+=p)):(v=this.right-c,r==="near"?h="right":r==="center"?(h="center",v-=p/2):(h="left",v=this.left)):n==="right"?i?(v=this.left+o,r==="near"?h="right":r==="center"?(h="center",v-=p/2):(h="left",v-=p)):(v=this.left+c,r==="near"?h="left":r==="center"?(h="center",v+=p/2):(h="right",v=this.right)):h="right",{textAlign:h,x:v}}_computeLabelArea(){if(this.options.ticks.mirror)return;let e=this.chart,n=this.options.position;if(n==="left"||n==="right")return {top:0,left:this.left,bottom:e.height,right:this.right};if(n==="top"||n==="bottom")return {top:this.top,left:0,bottom:this.bottom,right:e.width}}drawBackground(){let{ctx:e,options:{backgroundColor:n},left:r,top:i,width:o,height:s}=this;n&&(e.save(),e.fillStyle=n,e.fillRect(r,i,o,s),e.restore());}getLineWidthForValue(e){let n=this.options.grid;if(!this._isVisible()||!n.display)return 0;let i=this.ticks.findIndex(o=>o.value===e);return i>=0?n.setContext(this.getContext(i)).lineWidth:0}drawGrid(e){let n=this.options.grid,r=this.ctx,i=this._gridLineItems||(this._gridLineItems=this._computeGridLineItems(e)),o,s,c=(p,h,v)=>{!v.width||!v.color||(r.save(),r.lineWidth=v.width,r.strokeStyle=v.color,r.setLineDash(v.borderDash||[]),r.lineDashOffset=v.borderDashOffset,r.beginPath(),r.moveTo(p.x,p.y),r.lineTo(h.x,h.y),r.stroke(),r.restore());};if(n.display)for(o=0,s=i.length;o<s;++o){let p=i[o];n.drawOnChartArea&&c({x:p.x1,y:p.y1},{x:p.x2,y:p.y2},p),n.drawTicks&&c({x:p.tx1,y:p.ty1},{x:p.tx2,y:p.ty2},{color:p.tickColor,width:p.tickWidth,borderDash:p.tickBorderDash,borderDashOffset:p.tickBorderDashOffset});}}drawBorder(){let{chart:e,ctx:n,options:{grid:r}}=this,i=r.setContext(this.getContext()),o=r.drawBorder?i.borderWidth:0;if(!o)return;let s=r.setContext(this.getContext(0)).lineWidth,c=this._borderValue,p,h,v,P;this.isHorizontal()?(p=rs(e,this.left,o)-o/2,h=rs(e,this.right,s)+s/2,v=P=c):(v=rs(e,this.top,o)-o/2,P=rs(e,this.bottom,s)+s/2,p=h=c),n.save(),n.lineWidth=i.borderWidth,n.strokeStyle=i.borderColor,n.beginPath(),n.moveTo(p,v),n.lineTo(h,P),n.stroke(),n.restore();}drawLabels(e){if(!this.options.ticks.display)return;let r=this.ctx,i=this._computeLabelArea();i&&fl(r,i);let o=this._labelItems||(this._labelItems=this._computeLabelItems(e)),s,c;for(s=0,c=o.length;s<c;++s){let p=o[s],h=p.font,v=p.label;p.backdrop&&(r.fillStyle=p.backdrop.color,r.fillRect(p.backdrop.left,p.backdrop.top,p.backdrop.width,p.backdrop.height));let P=p.textOffset;is(r,v,0,P,h,p);}i&&hl(r);}drawTitle(){let{ctx:e,options:{position:n,title:r,reverse:i}}=this;if(!r.display)return;let o=Sn(r.font),s=$n(r.padding),c=r.align,p=o.lineHeight/2;n==="bottom"||n==="center"||Te(n)?(p+=s.bottom,He(r.text)&&(p+=o.lineHeight*(r.text.length-1))):p+=s.top;let{titleX:h,titleY:v,maxWidth:P,rotation:x}=$6(this,p,n,c);is(e,r.text,0,0,o,{color:r.color,maxWidth:P,rotation:x,textAlign:U6(c,n,i),textBaseline:"middle",translation:[h,v]});}draw(e){this._isVisible()&&(this.drawBackground(),this.drawGrid(e),this.drawBorder(),this.drawTitle(),this.drawLabels(e));}_layers(){let e=this.options,n=e.ticks&&e.ticks.z||0,r=me(e.grid&&e.grid.z,-1);return !this._isVisible()||this.draw!==t.prototype.draw?[{z:n,draw:i=>{this.draw(i);}}]:[{z:r,draw:i=>{this.drawBackground(),this.drawGrid(i),this.drawTitle();}},{z:r+1,draw:()=>{this.drawBorder();}},{z:n,draw:i=>{this.drawLabels(i);}}]}getMatchingVisibleMetas(e){let n=this.chart.getSortedVisibleDatasetMetas(),r=this.axis+"AxisID",i=[],o,s;for(o=0,s=n.length;o<s;++o){let c=n[o];c[r]===this.id&&(!e||c.type===e)&&i.push(c);}return i}_resolveTickFontOptions(e){let n=this.options.ticks.setContext(this.getContext(e));return Sn(n.font)}_maxDigits(){let e=this._resolveTickFontOptions(0).lineHeight;return (this.isHorizontal()?this.width:this.height)/e}},ad=class{constructor(e,n,r){this.type=e,this.scope=n,this.override=r,this.items=Object.create(null);}isForType(e){return Object.prototype.isPrototypeOf.call(this.type.prototype,e.prototype)}register(e){let n=Object.getPrototypeOf(e),r;V6(n)&&(r=this.register(n));let i=this.items,o=e.id,s=this.scope+"."+o;if(!o)throw new Error("class does not have id: "+e);return o in i||(i[o]=e,G6(e,s,r),this.override&&ke.override(e.id,e.overrides)),s}get(e){return this.items[e]}unregister(e){let n=this.items,r=e.id,i=this.scope;r in n&&delete n[r],i&&r in ke[i]&&(delete ke[i][r],this.override&&delete pl[r]);}};function G6(t,e,n){let r=ji(Object.create(null),[n?ke.get(n):{},ke.get(e),t.defaults]);ke.set(e,r),t.defaultRoutes&&j6(e,t.defaultRoutes),t.descriptors&&ke.describe(e,t.descriptors);}function j6(t,e){Object.keys(e).forEach(n=>{let r=n.split("."),i=r.pop(),o=[t].concat(r).join("."),s=e[n].split("."),c=s.pop(),p=s.join(".");ke.route(o,i,p,c);});}function V6(t){return "id"in t&&"defaults"in t}var K0=class{constructor(){this.controllers=new ad(zi,"datasets",true),this.elements=new ad(br,"elements"),this.plugins=new ad(Object,"plugins"),this.scales=new ad(Oc,"scales"),this._typedRegistries=[this.controllers,this.scales,this.elements];}add(...e){this._each("register",e);}remove(...e){this._each("unregister",e);}addControllers(...e){this._each("register",e,this.controllers);}addElements(...e){this._each("register",e,this.elements);}addPlugins(...e){this._each("register",e,this.plugins);}addScales(...e){this._each("register",e,this.scales);}getController(e){return this._get(e,this.controllers,"controller")}getElement(e){return this._get(e,this.elements,"element")}getPlugin(e){return this._get(e,this.plugins,"plugin")}getScale(e){return this._get(e,this.scales,"scale")}removeControllers(...e){this._each("unregister",e,this.controllers);}removeElements(...e){this._each("unregister",e,this.elements);}removePlugins(...e){this._each("unregister",e,this.plugins);}removeScales(...e){this._each("unregister",e,this.scales);}_each(e,n,r){[...n].forEach(i=>{let o=r||this._getRegistryForType(i);r||o.isForType(i)||o===this.plugins&&i.id?this._exec(e,o,i):tn(i,s=>{let c=r||this._getRegistryForType(s);this._exec(e,c,s);});});}_exec(e,n,r){let i=sf(e);Qe(r["before"+i],[],r),n[e](r),Qe(r["after"+i],[],r);}_getRegistryForType(e){for(let n=0;n<this._typedRegistries.length;n++){let r=this._typedRegistries[n];if(r.isForType(e))return r}return this.plugins}_get(e,n,r){let i=n.get(e);if(i===void 0)throw new Error('"'+e+'" is not a registered '+r+".");return i}},Ca=new K0,If=class extends zi{update(e){let n=this._cachedMeta,{data:r=[]}=n,i=this.chart._animationsDisabled,{start:o,count:s}=jg(n,r,i);if(this._drawStart=o,this._drawCount=s,Vg(n)&&(o=0,s=r.length),this.options.showLine){let{dataset:c,_dataset:p}=n;c._chart=this.chart,c._datasetIndex=this.index,c._decimated=!!p._decimated,c.points=r;let h=this.resolveDatasetElementOptions(e);h.segment=this.options.segment,this.updateElement(c,void 0,{animated:!i,options:h},e);}this.updateElements(r,o,s,e);}addElements(){let{showLine:e}=this.options;!this.datasetElementType&&e&&(this.datasetElementType=Ca.getElement("line")),super.addElements();}updateElements(e,n,r,i){let o=i==="reset",{iScale:s,vScale:c,_stacked:p,_dataset:h}=this._cachedMeta,v=this.resolveDataElementOptions(n,i),P=this.getSharedOptions(v),x=this.includeOptions(i,P),T=s.axis,I=c.axis,{spanGaps:R,segment:A}=this.options,O=Vi(R)?R:Number.POSITIVE_INFINITY,N=this.chart._animationsDisabled||o||i==="none",V=n>0&&this.getParsed(n-1);for(let G=n;G<n+r;++G){let X=e[G],nt=this.getParsed(G),st=N?X:{},U=Le(nt[I]),j=st[T]=s.getPixelForValue(nt[T],G),ut=st[I]=o||U?c.getBasePixel():c.getPixelForValue(p?this.applyStack(c,nt,p):nt[I],G);st.skip=isNaN(j)||isNaN(ut)||U,st.stop=G>0&&Math.abs(nt[T]-V[T])>O,A&&(st.parsed=nt,st.raw=h.data[G]),x&&(st.options=P||this.resolveDataElementOptions(G,X.active?"active":i)),N||this.updateElement(X,G,st,i),V=nt;}this.updateSharedOptions(P,i,v);}getMaxOverflow(){let e=this._cachedMeta,n=e.data||[];if(!this.options.showLine){let c=0;for(let p=n.length-1;p>=0;--p)c=Math.max(c,n[p].size(this.resolveDataElementOptions(p))/2);return c>0&&c}let r=e.dataset,i=r.options&&r.options.borderWidth||0;if(!n.length)return i;let o=n[0].size(this.resolveDataElementOptions(0)),s=n[n.length-1].size(this.resolveDataElementOptions(n.length-1));return Math.max(i,o,s)/2}};If.id="scatter";If.defaults={datasetElementType:false,dataElementType:"point",showLine:false,fill:false};If.overrides={interaction:{mode:"point"},plugins:{tooltip:{callbacks:{title(){return ""},label(t){return "("+t.label+", "+t.formattedValue+")"}}}},scales:{x:{type:"linear"},y:{type:"linear"}}};function Dc(){throw new Error("This method is not implemented: Check that a complete date adapter is provided.")}var kf=class{constructor(e){this.options=e||{};}init(e){}formats(){return Dc()}parse(e,n){return Dc()}format(e,n){return Dc()}add(e,n,r){return Dc()}diff(e,n,r){return Dc()}startOf(e,n,r){return Dc()}endOf(e,n){return Dc()}};kf.override=function(t){Object.assign(kf.prototype,t);};var z6={_date:kf};function H6(t,e,n,r){let{controller:i,data:o,_sorted:s}=t,c=i._cachedMeta.iScale;if(c&&e===c.axis&&e!=="r"&&s&&o.length){let p=c._reversePixels?b0:es;if(r){if(i._sharedOptions){let h=o[0],v=typeof h.getRange=="function"&&h.getRange(e);if(v){let P=p(o,e,n-v),x=p(o,e,n+v);return {lo:P.lo,hi:x.hi}}}}else return p(o,e,n)}return {lo:0,hi:o.length-1}}function Of(t,e,n,r,i){let o=t.getSortedVisibleDatasetMetas(),s=n[e];for(let c=0,p=o.length;c<p;++c){let{index:h,data:v}=o[c],{lo:P,hi:x}=H6(o[c],e,s,i);for(let T=P;T<=x;++T){let I=v[T];I.skip||r(I,h,T);}}}function W6(t){let e=t.indexOf("x")!==-1,n=t.indexOf("y")!==-1;return function(r,i){let o=e?Math.abs(r.x-i.x):0,s=n?Math.abs(r.y-i.y):0;return Math.sqrt(Math.pow(o,2)+Math.pow(s,2))}}function j0(t,e,n,r,i){let o=[];return !i&&!t.isPointInArea(e)||Of(t,n,e,function(c,p,h){!i&&!xc(c,t.chartArea,0)||c.inRange(e.x,e.y,r)&&o.push({element:c,datasetIndex:p,index:h});},true),o}function q6(t,e,n,r){let i=[];function o(s,c,p){let{startAngle:h,endAngle:v}=s.getProps(["startAngle","endAngle"],r),{angle:P}=Lg(s,{x:e.x,y:e.y});wc(P,h,v)&&i.push({element:s,datasetIndex:c,index:p});}return Of(t,n,e,o),i}function Y6(t,e,n,r,i,o){let s=[],c=W6(n),p=Number.POSITIVE_INFINITY;function h(v,P,x){let T=v.inRange(e.x,e.y,i);if(r&&!T)return;let I=v.getCenterPoint(i);if(!(!!o||t.isPointInArea(I))&&!T)return;let A=c(e,I);A<p?(s=[{element:v,datasetIndex:P,index:x}],p=A):A===p&&s.push({element:v,datasetIndex:P,index:x});}return Of(t,n,e,h),s}function V0(t,e,n,r,i,o){return !o&&!t.isPointInArea(e)?[]:n==="r"&&!r?q6(t,e,n,i):Y6(t,e,n,r,i,o)}function aw(t,e,n,r,i){let o=[],s=n==="x"?"inXRange":"inYRange",c=false;return Of(t,n,e,(p,h,v)=>{p[s](e[n],i)&&(o.push({element:p,datasetIndex:h,index:v}),c=c||p.inRange(e.x,e.y,i));}),r&&!c?[]:o}var Q6={modes:{index(t,e,n,r){let i=as(e,t),o=n.axis||"x",s=n.includeInvisible||false,c=n.intersect?j0(t,i,o,r,s):V0(t,i,o,false,r,s),p=[];return c.length?(t.getSortedVisibleDatasetMetas().forEach(h=>{let v=c[0].index,P=h.data[v];P&&!P.skip&&p.push({element:P,datasetIndex:h.index,index:v});}),p):[]},dataset(t,e,n,r){let i=as(e,t),o=n.axis||"xy",s=n.includeInvisible||false,c=n.intersect?j0(t,i,o,r,s):V0(t,i,o,false,r,s);if(c.length>0){let p=c[0].datasetIndex,h=t.getDatasetMeta(p).data;c=[];for(let v=0;v<h.length;++v)c.push({element:h[v],datasetIndex:p,index:v});}return c},point(t,e,n,r){let i=as(e,t),o=n.axis||"xy",s=n.includeInvisible||false;return j0(t,i,o,r,s)},nearest(t,e,n,r){let i=as(e,t),o=n.axis||"xy",s=n.includeInvisible||false;return V0(t,i,o,n.intersect,r,s)},x(t,e,n,r){let i=as(e,t);return aw(t,i,"x",n.intersect,r)},y(t,e,n,r){let i=as(e,t);return aw(t,i,"y",n.intersect,r)}}},$w=["left","top","right","bottom"];function bf(t,e){return t.filter(n=>n.pos===e)}function sw(t,e){return t.filter(n=>$w.indexOf(n.pos)===-1&&n.box.axis===e)}function vf(t,e){return t.sort((n,r)=>{let i=e?r:n,o=e?n:r;return i.weight===o.weight?i.index-o.index:i.weight-o.weight})}function K6(t){let e=[],n,r,i,o,s,c;for(n=0,r=(t||[]).length;n<r;++n)i=t[n],{position:o,options:{stack:s,stackWeight:c=1}}=i,e.push({index:n,box:i,pos:o,horizontal:i.isHorizontal(),weight:i.weight,stack:s&&o+s,stackWeight:c});return e}function X6(t){let e={};for(let n of t){let{stack:r,pos:i,stackWeight:o}=n;if(!r||!$w.includes(i))continue;let s=e[r]||(e[r]={count:0,placed:0,weight:0,size:0});s.count++,s.weight+=o;}return e}function Z6(t,e){let n=X6(t),{vBoxMaxWidth:r,hBoxMaxHeight:i}=e,o,s,c;for(o=0,s=t.length;o<s;++o){c=t[o];let{fullSize:p}=c.box,h=n[c.stack],v=h&&c.stackWeight/h.weight;c.horizontal?(c.width=v?v*r:p&&e.availableWidth,c.height=i):(c.width=r,c.height=v?v*i:p&&e.availableHeight);}return n}function J6(t){let e=K6(t),n=vf(e.filter(h=>h.box.fullSize),true),r=vf(bf(e,"left"),true),i=vf(bf(e,"right")),o=vf(bf(e,"top"),true),s=vf(bf(e,"bottom")),c=sw(e,"x"),p=sw(e,"y");return {fullSize:n,leftAndTop:r.concat(o),rightAndBottom:i.concat(p).concat(s).concat(c),chartArea:bf(e,"chartArea"),vertical:r.concat(i).concat(p),horizontal:o.concat(s).concat(c)}}function lw(t,e,n,r){return Math.max(t[n],e[n])+Math.max(t[r],e[r])}function Gw(t,e){t.top=Math.max(t.top,e.top),t.left=Math.max(t.left,e.left),t.bottom=Math.max(t.bottom,e.bottom),t.right=Math.max(t.right,e.right);}function t4(t,e,n,r){let{pos:i,box:o}=n,s=t.maxPadding;if(!Te(i)){n.size&&(t[i]-=n.size);let P=r[n.stack]||{size:0,count:1};P.size=Math.max(P.size,n.horizontal?o.height:o.width),n.size=P.size/P.count,t[i]+=n.size;}o.getPadding&&Gw(s,o.getPadding());let c=Math.max(0,e.outerWidth-lw(s,t,"left","right")),p=Math.max(0,e.outerHeight-lw(s,t,"top","bottom")),h=c!==t.w,v=p!==t.h;return t.w=c,t.h=p,n.horizontal?{same:h,other:v}:{same:v,other:h}}function e4(t){let e=t.maxPadding;function n(r){let i=Math.max(e[r]-t[r],0);return t[r]+=i,i}t.y+=n("top"),t.x+=n("left"),n("right"),n("bottom");}function n4(t,e){let n=e.maxPadding;function r(i){let o={left:0,top:0,right:0,bottom:0};return i.forEach(s=>{o[s]=Math.max(e[s],n[s]);}),o}return r(t?["left","right"]:["top","bottom"])}function Sf(t,e,n,r){let i=[],o,s,c,p,h,v;for(o=0,s=t.length,h=0;o<s;++o){c=t[o],p=c.box,p.update(c.width||e.w,c.height||e.h,n4(c.horizontal,e));let{same:P,other:x}=t4(e,n,c,r);h|=P&&i.length,v=v||x,p.fullSize||i.push(c);}return h&&Sf(i,e,n,r)||v}function oy(t,e,n,r,i){t.top=n,t.left=e,t.right=e+r,t.bottom=n+i,t.width=r,t.height=i;}function cw(t,e,n,r){let i=n.padding,{x:o,y:s}=e;for(let c of t){let p=c.box,h=r[c.stack]||{placed:0,weight:1},v=c.stackWeight/h.weight||1;if(c.horizontal){let P=e.w*v,x=h.size||p.height;Fn(h.start)&&(s=h.start),p.fullSize?oy(p,i.left,s,n.outerWidth-i.right-i.left,x):oy(p,e.left+h.placed,s,P,x),h.start=s,h.placed+=P,s=p.bottom;}else {let P=e.h*v,x=h.size||p.width;Fn(h.start)&&(o=h.start),p.fullSize?oy(p,o,i.top,x,n.outerHeight-i.bottom-i.top):oy(p,o,e.top+h.placed,x,P),h.start=o,h.placed+=P,o=p.right;}}e.x=o,e.y=s;}ke.set("layout",{autoPadding:true,padding:{top:0,right:0,bottom:0,left:0}});var yo={addBox(t,e){t.boxes||(t.boxes=[]),e.fullSize=e.fullSize||false,e.position=e.position||"top",e.weight=e.weight||0,e._layers=e._layers||function(){return [{z:0,draw(n){e.draw(n);}}]},t.boxes.push(e);},removeBox(t,e){let n=t.boxes?t.boxes.indexOf(e):-1;n!==-1&&t.boxes.splice(n,1);},configure(t,e,n){e.fullSize=n.fullSize,e.position=n.position,e.weight=n.weight;},update(t,e,n,r){if(!t)return;let i=$n(t.options.layout.padding),o=Math.max(e-i.width,0),s=Math.max(n-i.height,0),c=J6(t.boxes),p=c.vertical,h=c.horizontal;tn(t.boxes,R=>{typeof R.beforeLayout=="function"&&R.beforeLayout();});let v=p.reduce((R,A)=>A.box.options&&A.box.options.display===false?R:R+1,0)||1,P=Object.freeze({outerWidth:e,outerHeight:n,padding:i,availableWidth:o,availableHeight:s,vBoxMaxWidth:o/2/v,hBoxMaxHeight:s/2}),x=Object.assign({},i);Gw(x,$n(r));let T=Object.assign({maxPadding:x,w:o,h:s,x:i.left,y:i.top},i),I=Z6(p.concat(h),P);Sf(c.fullSize,T,P,I),Sf(p,T,P,I),Sf(h,T,P,I)&&Sf(p,T,P,I),e4(T),cw(c.leftAndTop,T,P,I),T.x+=T.w,T.y+=T.h,cw(c.rightAndBottom,T,P,I),t.chartArea={left:T.left,top:T.top,right:T.left+T.w,bottom:T.top+T.h,height:T.h,width:T.w},tn(c.chartArea,R=>{let A=R.box;Object.assign(A,t.chartArea),A.update(T.w,T.h,{left:0,top:0,right:0,bottom:0});});}},dy=class{acquireContext(e,n){}releaseContext(e){return false}addEventListener(e,n,r){}removeEventListener(e,n,r){}getDevicePixelRatio(){return 1}getMaximumSize(e,n,r,i){return n=Math.max(0,n||e.width),r=r||e.height,{width:n,height:Math.max(0,i?Math.floor(n/i):r)}}isAttached(e){return true}updateConfig(e){}},X0=class extends dy{acquireContext(e){return e&&e.getContext&&e.getContext("2d")||null}updateConfig(e){e.options.animation=false;}},cy="$chartjs",r4={touchstart:"mousedown",touchmove:"mousemove",touchend:"mouseup",pointerenter:"mouseenter",pointerdown:"mousedown",pointermove:"mousemove",pointerup:"mouseup",pointerleave:"mouseout",pointerout:"mouseout"},uw=t=>t===null||t==="";function i4(t,e){let n=t.style,r=t.getAttribute("height"),i=t.getAttribute("width");if(t[cy]={initial:{height:r,width:i,style:{display:n.display,height:n.height,width:n.width}}},n.display=n.display||"block",n.boxSizing=n.boxSizing||"border-box",uw(i)){let o=Jg(t,"width");o!==void 0&&(t.width=o);}if(uw(r))if(t.style.height==="")t.height=t.width/(e||2);else {let o=Jg(t,"height");o!==void 0&&(t.height=o);}return t}var jw=M0?{passive:true}:false;function o4(t,e,n){t.addEventListener(e,n,jw);}function a4(t,e,n){t.canvas.removeEventListener(e,n,jw);}function s4(t,e){let n=r4[t.type]||t.type,{x:r,y:i}=as(t,e);return {type:n,chart:e,native:t,x:r!==void 0?r:null,y:i!==void 0?i:null}}function py(t,e){for(let n of t)if(n===e||n.contains(e))return true}function l4(t,e,n){let r=t.canvas,i=new MutationObserver(o=>{let s=false;for(let c of o)s=s||py(c.addedNodes,r),s=s&&!py(c.removedNodes,r);s&&n();});return i.observe(document,{childList:true,subtree:true}),i}function c4(t,e,n){let r=t.canvas,i=new MutationObserver(o=>{let s=false;for(let c of o)s=s||py(c.removedNodes,r),s=s&&!py(c.addedNodes,r);s&&n();});return i.observe(document,{childList:true,subtree:true}),i}var Df=new Map,dw=0;function Vw(){let t=window.devicePixelRatio;t!==dw&&(dw=t,Df.forEach((e,n)=>{n.currentDevicePixelRatio!==t&&e();}));}function u4(t,e){Df.size||window.addEventListener("resize",Vw),Df.set(t,e);}function d4(t){Df.delete(t),Df.size||window.removeEventListener("resize",Vw);}function p4(t,e,n){let r=t.canvas,i=r&&mf(r);if(!i)return;let o=Gg((c,p)=>{let h=i.clientWidth;n(c,p),h<i.clientWidth&&n();},window),s=new ResizeObserver(c=>{let p=c[0],h=p.contentRect.width,v=p.contentRect.height;h===0&&v===0||o(h,v);});return s.observe(i),u4(t,o),s}function z0(t,e,n){n&&n.disconnect(),e==="resize"&&d4(t);}function f4(t,e,n){let r=t.canvas,i=Gg(o=>{t.ctx!==null&&n(s4(o,t));},t,o=>{let s=o[0];return [s,s.offsetX,s.offsetY]});return o4(r,e,i),i}var Z0=class extends dy{acquireContext(e,n){let r=e&&e.getContext&&e.getContext("2d");return r&&r.canvas===e?(i4(e,n),r):null}releaseContext(e){let n=e.canvas;if(!n[cy])return false;let r=n[cy].initial;["height","width"].forEach(o=>{let s=r[o];Le(s)?n.removeAttribute(o):n.setAttribute(o,s);});let i=r.style||{};return Object.keys(i).forEach(o=>{n.style[o]=i[o];}),n.width=n.width,delete n[cy],true}addEventListener(e,n,r){this.removeEventListener(e,n);let i=e.$proxies||(e.$proxies={}),s={attach:l4,detach:c4,resize:p4}[n]||f4;i[n]=s(e,n,r);}removeEventListener(e,n){let r=e.$proxies||(e.$proxies={}),i=r[n];if(!i)return;(({attach:z0,detach:z0,resize:z0})[n]||a4)(e,n,i),r[n]=void 0;}getDevicePixelRatio(){return window.devicePixelRatio}getMaximumSize(e,n,r,i){return F0(e,n,r,i)}isAttached(e){let n=mf(e);return !!(n&&n.isConnected)}};function h4(t){return !Kg()||typeof OffscreenCanvas!="undefined"&&t instanceof OffscreenCanvas?X0:Z0}var J0=class{constructor(){this._init=[];}notify(e,n,r,i){n==="beforeInit"&&(this._init=this._createDescriptors(e,true),this._notify(this._init,e,"install"));let o=i?this._descriptors(e).filter(i):this._descriptors(e),s=this._notify(o,e,n,r);return n==="afterDestroy"&&(this._notify(o,e,"stop"),this._notify(this._init,e,"uninstall")),s}_notify(e,n,r,i){i=i||{};for(let o of e){let s=o.plugin,c=s[r],p=[n,i,o.options];if(Qe(c,p,s)===false&&i.cancelable)return false}return true}invalidate(){Le(this._cache)||(this._oldCache=this._cache,this._cache=void 0);}_descriptors(e){if(this._cache)return this._cache;let n=this._cache=this._createDescriptors(e);return this._notifyStateChanges(e),n}_createDescriptors(e,n){let r=e&&e.config,i=me(r.options&&r.options.plugins,{}),o=m4(r);return i===false&&!n?[]:y4(e,o,i,n)}_notifyStateChanges(e){let n=this._oldCache||[],r=this._cache,i=(o,s)=>o.filter(c=>!s.some(p=>c.plugin.id===p.plugin.id));this._notify(i(n,r),e,"stop"),this._notify(i(r,n),e,"start");}};function m4(t){let e={},n=[],r=Object.keys(Ca.plugins.items);for(let o=0;o<r.length;o++)n.push(Ca.getPlugin(r[o]));let i=t.plugins||[];for(let o=0;o<i.length;o++){let s=i[o];n.indexOf(s)===-1&&(n.push(s),e[s.id]=true);}return {plugins:n,localIds:e}}function g4(t,e){return !e&&t===false?null:t===true?{}:t}function y4(t,{plugins:e,localIds:n},r,i){let o=[],s=t.getContext();for(let c of e){let p=c.id,h=g4(r[p],i);h!==null&&o.push({plugin:c,options:b4(t.config,{plugin:c,local:n[p]},h,s)});}return o}function b4(t,{plugin:e,local:n},r,i){let o=t.pluginScopeKeys(e),s=t.getOptionScopes(r,o);return n&&e.defaults&&s.push(e.defaults),t.createResolver(s,i,[""],{scriptable:false,indexable:false,allKeys:true})}function t1(t,e){let n=ke.datasets[t]||{};return ((e.datasets||{})[t]||{}).indexAxis||e.indexAxis||n.indexAxis||"x"}function v4(t,e){let n=t;return t==="_index_"?n=e:t==="_value_"&&(n=e==="x"?"y":"x"),n}function C4(t,e){return t===e?"_index_":"_value_"}function S4(t){if(t==="top"||t==="bottom")return "x";if(t==="left"||t==="right")return "y"}function e1(t,e){return t==="x"||t==="y"?t:e.axis||S4(e.position)||t.charAt(0).toLowerCase()}function P4(t,e){let n=pl[t.type]||{scales:{}},r=e.scales||{},i=t1(t.type,e),o=Object.create(null),s=Object.create(null);return Object.keys(r).forEach(c=>{let p=r[c];if(!Te(p))return console.error(`Invalid scale configuration for scale: ${c}`);if(p._proxy)return console.warn(`Ignoring resolver passed as options for scale: ${c}`);let h=e1(c,p),v=C4(h,i),P=n.scales||{};o[h]=o[h]||c,s[c]=Ec(Object.create(null),[{axis:h},p,P[h],P[v]]);}),t.data.datasets.forEach(c=>{let p=c.type||t.type,h=c.indexAxis||t1(p,e),P=(pl[p]||{}).scales||{};Object.keys(P).forEach(x=>{let T=v4(x,h),I=c[T+"AxisID"]||o[T]||T;s[I]=s[I]||Object.create(null),Ec(s[I],[{axis:T},r[I],P[x]]);});}),Object.keys(s).forEach(c=>{let p=s[c];Ec(p,[ke.scales[p.type],ke.scale]);}),s}function zw(t){let e=t.options||(t.options={});e.plugins=me(e.plugins,{}),e.scales=P4(t,e);}function Hw(t){return t=t||{},t.datasets=t.datasets||[],t.labels=t.labels||[],t}function x4(t){return t=t||{},t.data=Hw(t.data),zw(t),t}var pw=new Map,Ww=new Set;function ay(t,e){let n=pw.get(t);return n||(n=e(),pw.set(t,n),Ww.add(n)),n}var Cf=(t,e,n)=>{let r=ya(e,n);r!==void 0&&t.add(r);},n1=class{constructor(e){this._config=x4(e),this._scopeCache=new Map,this._resolverCache=new Map;}get platform(){return this._config.platform}get type(){return this._config.type}set type(e){this._config.type=e;}get data(){return this._config.data}set data(e){this._config.data=Hw(e);}get options(){return this._config.options}set options(e){this._config.options=e;}get plugins(){return this._config.plugins}update(){let e=this._config;this.clearCache(),zw(e);}clearCache(){this._scopeCache.clear(),this._resolverCache.clear();}datasetScopeKeys(e){return ay(e,()=>[[`datasets.${e}`,""]])}datasetAnimationScopeKeys(e,n){return ay(`${e}.transition.${n}`,()=>[[`datasets.${e}.transitions.${n}`,`transitions.${n}`],[`datasets.${e}`,""]])}datasetElementScopeKeys(e,n){return ay(`${e}-${n}`,()=>[[`datasets.${e}.elements.${n}`,`datasets.${e}`,`elements.${n}`,""]])}pluginScopeKeys(e){let n=e.id,r=this.type;return ay(`${r}-plugin-${n}`,()=>[[`plugins.${n}`,...e.additionalOptionScopes||[]]])}_cachedScopes(e,n){let r=this._scopeCache,i=r.get(e);return (!i||n)&&(i=new Map,r.set(e,i)),i}getOptionScopes(e,n,r){let{options:i,type:o}=this,s=this._cachedScopes(e,r),c=s.get(n);if(c)return c;let p=new Set;n.forEach(v=>{e&&(p.add(e),v.forEach(P=>Cf(p,e,P))),v.forEach(P=>Cf(p,i,P)),v.forEach(P=>Cf(p,pl[o]||{},P)),v.forEach(P=>Cf(p,ke,P)),v.forEach(P=>Cf(p,zg,P));});let h=Array.from(p);return h.length===0&&h.push(Object.create(null)),Ww.has(n)&&s.set(n,h),h}chartOptionScopes(){let{options:e,type:n}=this;return [e,pl[n]||{},ke.datasets[n]||{},{type:n},ke,zg]}resolveNamedOptions(e,n,r,i=[""]){let o={$shared:true},{resolver:s,subPrefixes:c}=fw(this._resolverCache,e,i),p=s;if(_4(s,n)){o.$shared=false,r=Gr(r)?r():r;let h=this.createResolver(e,r,c);p=dl(s,r,h);}for(let h of n)o[h]=p[h];return o}createResolver(e,n,r=[""],i){let{resolver:o}=fw(this._resolverCache,e,r);return Te(n)?dl(o,n,void 0,i):o}};function fw(t,e,n){let r=t.get(e);r||(r=new Map,t.set(e,r));let i=n.join(),o=r.get(i);return o||(o={resolver:hf(e,n),subPrefixes:n.filter(c=>!c.toLowerCase().includes("hover"))},r.set(i,o)),o}var E4=t=>Te(t)&&Object.getOwnPropertyNames(t).reduce((e,n)=>e||Gr(t[n]),false);function _4(t,e){let{isScriptable:n,isIndexable:r}=Yg(t);for(let i of e){let o=n(i),s=r(i),c=(s||o)&&t[i];if(o&&(Gr(c)||E4(c))||s&&He(c))return true}return false}var T4="3.9.1",w4=["top","bottom","left","right","chartArea"];function hw(t,e){return t==="top"||t==="bottom"||w4.indexOf(t)===-1&&e==="x"}function mw(t,e){return function(n,r){return n[t]===r[t]?n[e]-r[e]:n[t]-r[t]}}function gw(t){let e=t.chart,n=e.options.animation;e.notifyPlugins("afterRender"),Qe(n&&n.onComplete,[t],e);}function I4(t){let e=t.chart,n=e.options.animation;Qe(n&&n.onProgress,[t],e);}function qw(t){return Kg()&&typeof t=="string"?t=document.getElementById(t):t&&t.length&&(t=t[0]),t&&t.canvas&&(t=t.canvas),t}var fy={},Yw=t=>{let e=qw(t);return Object.values(fy).filter(n=>n.canvas===e).pop()};function k4(t,e,n){let r=Object.keys(t);for(let i of r){let o=+i;if(o>=e){let s=t[i];delete t[i],(n>0||o>e)&&(t[o+n]=s);}}}function D4(t,e,n,r){return !n||t.type==="mouseout"?null:r?e:t}var bo=class{constructor(e,n){let r=this.config=new n1(n),i=qw(e),o=Yw(i);if(o)throw new Error("Canvas is already in use. Chart with ID '"+o.id+"' must be destroyed before the canvas with ID '"+o.canvas.id+"' can be reused.");let s=r.createResolver(r.chartOptionScopes(),this.getContext());this.platform=new(r.platform||h4(i)),this.platform.updateConfig(r);let c=this.platform.acquireContext(i,s.aspectRatio),p=c&&c.canvas,h=p&&p.height,v=p&&p.width;if(this.id=p0(),this.ctx=c,this.canvas=p,this.width=v,this.height=h,this._options=s,this._aspectRatio=this.aspectRatio,this._layers=[],this._metasets=[],this._stacks=void 0,this.boxes=[],this.currentDevicePixelRatio=void 0,this.chartArea=void 0,this._active=[],this._lastEvent=void 0,this._listeners={},this._responsiveListeners=void 0,this._sortedMetasets=[],this.scales={},this._plugins=new J0,this.$proxies={},this._hiddenIndices={},this.attached=false,this._animationsDisabled=void 0,this.$context=void 0,this._doResize=S0(P=>this.update(P),s.resizeDelay||0),this._dataChanges=[],fy[this.id]=this,!c||!p){console.error("Failed to create chart: can't acquire context from the given item");return}ss.listen(this,"complete",gw),ss.listen(this,"progress",I4),this._initialize(),this.attached&&this.update();}get aspectRatio(){let{options:{aspectRatio:e,maintainAspectRatio:n},width:r,height:i,_aspectRatio:o}=this;return Le(e)?n&&o?o:i?r/i:null:e}get data(){return this.config.data}set data(e){this.config.data=e;}get options(){return this._options}set options(e){this.config.options=e;}_initialize(){return this.notifyPlugins("beforeInit"),this.options.responsive?this.resize():Zg(this,this.options.devicePixelRatio),this.bindEvents(),this.notifyPlugins("afterInit"),this}clear(){return Hg(this.canvas,this.ctx),this}stop(){return ss.stop(this),this}resize(e,n){ss.running(this)?this._resizeBeforeDraw={width:e,height:n}:this._resize(e,n);}_resize(e,n){let r=this.options,i=this.canvas,o=r.maintainAspectRatio&&this.aspectRatio,s=this.platform.getMaximumSize(i,e,n,o),c=r.devicePixelRatio||this.platform.getDevicePixelRatio(),p=this.width?"resize":"attach";this.width=s.width,this.height=s.height,this._aspectRatio=this.aspectRatio,Zg(this,c,true)&&(this.notifyPlugins("resize",{size:s}),Qe(r.onResize,[this,s],this),this.attached&&this._doResize(p)&&this.render());}ensureScalesHaveIDs(){let n=this.options.scales||{};tn(n,(r,i)=>{r.id=i;});}buildOrUpdateScales(){let e=this.options,n=e.scales,r=this.scales,i=Object.keys(r).reduce((s,c)=>(s[c]=false,s),{}),o=[];n&&(o=o.concat(Object.keys(n).map(s=>{let c=n[s],p=e1(s,c),h=p==="r",v=p==="x";return {options:c,dposition:h?"chartArea":v?"bottom":"left",dtype:h?"radialLinear":v?"category":"linear"}}))),tn(o,s=>{let c=s.options,p=c.id,h=e1(p,c),v=me(c.type,s.dtype);(c.position===void 0||hw(c.position,h)!==hw(s.dposition))&&(c.position=s.dposition),i[p]=true;let P=null;if(p in r&&r[p].type===v)P=r[p];else {let x=Ca.getScale(v);P=new x({id:p,type:v,ctx:this.ctx,chart:this}),r[P.id]=P;}P.init(c,e);}),tn(i,(s,c)=>{s||delete r[c];}),tn(r,s=>{yo.configure(this,s,s.options),yo.addBox(this,s);});}_updateMetasets(){let e=this._metasets,n=this.data.datasets.length,r=e.length;if(e.sort((i,o)=>i.index-o.index),r>n){for(let i=n;i<r;++i)this._destroyDatasetMeta(i);e.splice(n,r-n);}this._sortedMetasets=e.slice(0).sort(mw("order","index"));}_removeUnreferencedMetasets(){let{_metasets:e,data:{datasets:n}}=this;e.length>n.length&&delete this._stacks,e.forEach((r,i)=>{n.filter(o=>o===r._dataset).length===0&&this._destroyDatasetMeta(i);});}buildOrUpdateControllers(){let e=[],n=this.data.datasets,r,i;for(this._removeUnreferencedMetasets(),r=0,i=n.length;r<i;r++){let o=n[r],s=this.getDatasetMeta(r),c=o.type||this.config.type;if(s.type&&s.type!==c&&(this._destroyDatasetMeta(r),s=this.getDatasetMeta(r)),s.type=c,s.indexAxis=o.indexAxis||t1(c,this.options),s.order=o.order||0,s.index=r,s.label=""+o.label,s.visible=this.isDatasetVisible(r),s.controller)s.controller.updateIndex(r),s.controller.linkScales();else {let p=Ca.getController(c),{datasetElementType:h,dataElementType:v}=ke.datasets[c];Object.assign(p.prototype,{dataElementType:Ca.getElement(v),datasetElementType:h&&Ca.getElement(h)}),s.controller=new p(this,r),e.push(s.controller);}}return this._updateMetasets(),e}_resetElements(){tn(this.data.datasets,(e,n)=>{this.getDatasetMeta(n).controller.reset();},this);}reset(){this._resetElements(),this.notifyPlugins("reset");}update(e){let n=this.config;n.update();let r=this._options=n.createResolver(n.chartOptionScopes(),this.getContext()),i=this._animationsDisabled=!r.animation;if(this._updateScales(),this._checkEventBindings(),this._updateHiddenIndices(),this._plugins.invalidate(),this.notifyPlugins("beforeUpdate",{mode:e,cancelable:true})===false)return;let o=this.buildOrUpdateControllers();this.notifyPlugins("beforeElementsUpdate");let s=0;for(let h=0,v=this.data.datasets.length;h<v;h++){let{controller:P}=this.getDatasetMeta(h),x=!i&&o.indexOf(P)===-1;P.buildOrUpdateElements(x),s=Math.max(+P.getMaxOverflow(),s);}s=this._minPadding=r.layout.autoPadding?s:0,this._updateLayout(s),i||tn(o,h=>{h.reset();}),this._updateDatasets(e),this.notifyPlugins("afterUpdate",{mode:e}),this._layers.sort(mw("z","_idx"));let{_active:c,_lastEvent:p}=this;p?this._eventHandler(p,true):c.length&&this._updateHoverStyles(c,c,true),this.render();}_updateScales(){tn(this.scales,e=>{yo.removeBox(this,e);}),this.ensureScalesHaveIDs(),this.buildOrUpdateScales();}_checkEventBindings(){let e=this.options,n=new Set(Object.keys(this._listeners)),r=new Set(e.events);(!Rg(n,r)||!!this._responsiveListeners!==e.responsive)&&(this.unbindEvents(),this.bindEvents());}_updateHiddenIndices(){let{_hiddenIndices:e}=this,n=this._getUniformDataChanges()||[];for(let{method:r,start:i,count:o}of n){let s=r==="_removeElements"?-o:o;k4(e,i,s);}}_getUniformDataChanges(){let e=this._dataChanges;if(!e||!e.length)return;this._dataChanges=[];let n=this.data.datasets.length,r=o=>new Set(e.filter(s=>s[0]===o).map((s,c)=>c+","+s.splice(1).join(","))),i=r(0);for(let o=1;o<n;o++)if(!Rg(i,r(o)))return;return Array.from(i).map(o=>o.split(",")).map(o=>({method:o[1],start:+o[2],count:+o[3]}))}_updateLayout(e){if(this.notifyPlugins("beforeLayout",{cancelable:true})===false)return;yo.update(this,this.width,this.height,e);let n=this.chartArea,r=n.width<=0||n.height<=0;this._layers=[],tn(this.boxes,i=>{r&&i.position==="chartArea"||(i.configure&&i.configure(),this._layers.push(...i._layers()));},this),this._layers.forEach((i,o)=>{i._idx=o;}),this.notifyPlugins("afterLayout");}_updateDatasets(e){if(this.notifyPlugins("beforeDatasetsUpdate",{mode:e,cancelable:true})!==false){for(let n=0,r=this.data.datasets.length;n<r;++n)this.getDatasetMeta(n).controller.configure();for(let n=0,r=this.data.datasets.length;n<r;++n)this._updateDataset(n,Gr(e)?e({datasetIndex:n}):e);this.notifyPlugins("afterDatasetsUpdate",{mode:e});}}_updateDataset(e,n){let r=this.getDatasetMeta(e),i={meta:r,index:e,mode:n,cancelable:true};this.notifyPlugins("beforeDatasetUpdate",i)!==false&&(r.controller._update(n),i.cancelable=false,this.notifyPlugins("afterDatasetUpdate",i));}render(){this.notifyPlugins("beforeRender",{cancelable:true})!==false&&(ss.has(this)?this.attached&&!ss.running(this)&&ss.start(this):(this.draw(),gw({chart:this})));}draw(){let e;if(this._resizeBeforeDraw){let{width:r,height:i}=this._resizeBeforeDraw;this._resize(r,i),this._resizeBeforeDraw=null;}if(this.clear(),this.width<=0||this.height<=0||this.notifyPlugins("beforeDraw",{cancelable:true})===false)return;let n=this._layers;for(e=0;e<n.length&&n[e].z<=0;++e)n[e].draw(this.chartArea);for(this._drawDatasets();e<n.length;++e)n[e].draw(this.chartArea);this.notifyPlugins("afterDraw");}_getSortedDatasetMetas(e){let n=this._sortedMetasets,r=[],i,o;for(i=0,o=n.length;i<o;++i){let s=n[i];(!e||s.visible)&&r.push(s);}return r}getSortedVisibleDatasetMetas(){return this._getSortedDatasetMetas(true)}_drawDatasets(){if(this.notifyPlugins("beforeDatasetsDraw",{cancelable:true})===false)return;let e=this.getSortedVisibleDatasetMetas();for(let n=e.length-1;n>=0;--n)this._drawDataset(e[n]);this.notifyPlugins("afterDatasetsDraw");}_drawDataset(e){let n=this.ctx,r=e._clip,i=!r.disabled,o=this.chartArea,s={meta:e,index:e.index,cancelable:true};this.notifyPlugins("beforeDatasetDraw",s)!==false&&(i&&fl(n,{left:r.left===false?0:o.left-r.left,right:r.right===false?this.width:o.right+r.right,top:r.top===false?0:o.top-r.top,bottom:r.bottom===false?this.height:o.bottom+r.bottom}),e.controller.draw(),i&&hl(n),s.cancelable=false,this.notifyPlugins("afterDatasetDraw",s));}isPointInArea(e){return xc(e,this.chartArea,this._minPadding)}getElementsAtEventForMode(e,n,r,i){let o=Q6.modes[n];return typeof o=="function"?o(this,e,r,i):[]}getDatasetMeta(e){let n=this.data.datasets[e],r=this._metasets,i=r.filter(o=>o&&o._dataset===n).pop();return i||(i={type:null,data:[],dataset:null,controller:null,hidden:null,xAxisID:null,yAxisID:null,order:n&&n.order||0,index:e,_dataset:n,_parsed:[],_sorted:false},r.push(i)),i}getContext(){return this.$context||(this.$context=ba(null,{chart:this,type:"chart"}))}getVisibleDatasetCount(){return this.getSortedVisibleDatasetMetas().length}isDatasetVisible(e){let n=this.data.datasets[e];if(!n)return false;let r=this.getDatasetMeta(e);return typeof r.hidden=="boolean"?!r.hidden:!n.hidden}setDatasetVisibility(e,n){let r=this.getDatasetMeta(e);r.hidden=!n;}toggleDataVisibility(e){this._hiddenIndices[e]=!this._hiddenIndices[e];}getDataVisibility(e){return !this._hiddenIndices[e]}_updateVisibility(e,n,r){let i=r?"show":"hide",o=this.getDatasetMeta(e),s=o.controller._resolveAnimations(void 0,i);Fn(n)?(o.data[n].hidden=!r,this.update()):(this.setDatasetVisibility(e,r),s.update(o,{visible:r}),this.update(c=>c.datasetIndex===e?i:void 0));}hide(e,n){this._updateVisibility(e,n,false);}show(e,n){this._updateVisibility(e,n,true);}_destroyDatasetMeta(e){let n=this._metasets[e];n&&n.controller&&n.controller._destroy(),delete this._metasets[e];}_stop(){let e,n;for(this.stop(),ss.remove(this),e=0,n=this.data.datasets.length;e<n;++e)this._destroyDatasetMeta(e);}destroy(){this.notifyPlugins("beforeDestroy");let{canvas:e,ctx:n}=this;this._stop(),this.config.clearCache(),e&&(this.unbindEvents(),Hg(e,n),this.platform.releaseContext(n),this.canvas=null,this.ctx=null),this.notifyPlugins("destroy"),delete fy[this.id],this.notifyPlugins("afterDestroy");}toBase64Image(...e){return this.canvas.toDataURL(...e)}bindEvents(){this.bindUserEvents(),this.options.responsive?this.bindResponsiveEvents():this.attached=true;}bindUserEvents(){let e=this._listeners,n=this.platform,r=(o,s)=>{n.addEventListener(this,o,s),e[o]=s;},i=(o,s,c)=>{o.offsetX=s,o.offsetY=c,this._eventHandler(o);};tn(this.options.events,o=>r(o,i));}bindResponsiveEvents(){this._responsiveListeners||(this._responsiveListeners={});let e=this._responsiveListeners,n=this.platform,r=(p,h)=>{n.addEventListener(this,p,h),e[p]=h;},i=(p,h)=>{e[p]&&(n.removeEventListener(this,p,h),delete e[p]);},o=(p,h)=>{this.canvas&&this.resize(p,h);},s,c=()=>{i("attach",c),this.attached=true,this.resize(),r("resize",o),r("detach",s);};s=()=>{this.attached=false,i("resize",o),this._stop(),this._resize(0,0),r("attach",c);},n.isAttached(this.canvas)?c():s();}unbindEvents(){tn(this._listeners,(e,n)=>{this.platform.removeEventListener(this,n,e);}),this._listeners={},tn(this._responsiveListeners,(e,n)=>{this.platform.removeEventListener(this,n,e);}),this._responsiveListeners=void 0;}updateHoverStyle(e,n,r){let i=r?"set":"remove",o,s,c,p;for(n==="dataset"&&(o=this.getDatasetMeta(e[0].datasetIndex),o.controller["_"+i+"DatasetHoverStyle"]()),c=0,p=e.length;c<p;++c){s=e[c];let h=s&&this.getDatasetMeta(s.datasetIndex).controller;h&&h[i+"HoverStyle"](s.element,s.datasetIndex,s.index);}}getActiveElements(){return this._active||[]}setActiveElements(e){let n=this._active||[],r=e.map(({datasetIndex:o,index:s})=>{let c=this.getDatasetMeta(o);if(!c)throw new Error("No dataset found at index "+o);return {datasetIndex:o,element:c.data[s],index:s}});!id(r,n)&&(this._active=r,this._lastEvent=null,this._updateHoverStyles(r,n));}notifyPlugins(e,n,r){return this._plugins.notify(this,e,n,r)}_updateHoverStyles(e,n,r){let i=this.options.hover,o=(p,h)=>p.filter(v=>!h.some(P=>v.datasetIndex===P.datasetIndex&&v.index===P.index)),s=o(n,e),c=r?e:o(e,n);s.length&&this.updateHoverStyle(s,i.mode,false),c.length&&i.mode&&this.updateHoverStyle(c,i.mode,true);}_eventHandler(e,n){let r={event:e,replay:n,cancelable:true,inChartArea:this.isPointInArea(e)},i=s=>(s.options.events||this.options.events).includes(e.native.type);if(this.notifyPlugins("beforeEvent",r,i)===false)return;let o=this._handleEvent(e,n,r.inChartArea);return r.cancelable=false,this.notifyPlugins("afterEvent",r,i),(o||r.changed)&&this.render(),this}_handleEvent(e,n,r){let{_active:i=[],options:o}=this,s=n,c=this._getActiveElements(e,i,r,s),p=h0(e),h=D4(e,this._lastEvent,r,p);r&&(this._lastEvent=null,Qe(o.onHover,[e,c,this],this),p&&Qe(o.onClick,[e,c,this],this));let v=!id(c,i);return (v||n)&&(this._active=c,this._updateHoverStyles(c,i,n)),this._lastEvent=h,v}_getActiveElements(e,n,r,i){if(e.type==="mouseout")return [];if(!r)return n;let o=this.options.hover;return this.getElementsAtEventForMode(e,o.mode,o,i)}},yw=()=>tn(bo.instances,t=>t._plugins.invalidate()),gl=true;Object.defineProperties(bo,{defaults:{enumerable:gl,value:ke},instances:{enumerable:gl,value:fy},overrides:{enumerable:gl,value:pl},registry:{enumerable:gl,value:Ca},version:{enumerable:gl,value:T4},getChart:{enumerable:gl,value:Yw},register:{enumerable:gl,value:(...t)=>{Ca.add(...t),yw();}},unregister:{enumerable:gl,value:(...t)=>{Ca.remove(...t),yw();}}});function Qw(t,e,n){let{startAngle:r,pixelMargin:i,x:o,y:s,outerRadius:c,innerRadius:p}=e,h=i/c;t.beginPath(),t.arc(o,s,c,r-h,n+h),p>i?(h=i/p,t.arc(o,s,p,n+h,r-h,true)):t.arc(o,s,i,n+bn,r-bn),t.closePath(),t.clip();}function A4(t){return ff(t,["outerStart","outerEnd","innerStart","innerEnd"])}function O4(t,e,n,r){let i=A4(t.options.borderRadius),o=(n-e)/2,s=Math.min(o,r*e/2),c=p=>{let h=(n-Math.min(o,p))*r/2;return Nr(p,0,Math.min(o,h))};return {outerStart:c(i.outerStart),outerEnd:c(i.outerEnd),innerStart:Nr(i.innerStart,0,s),innerEnd:Nr(i.innerEnd,0,s)}}function od(t,e,n,r){return {x:n+t*Math.cos(e),y:r+t*Math.sin(e)}}function r1(t,e,n,r,i,o){let{x:s,y:c,startAngle:p,pixelMargin:h,innerRadius:v}=e,P=Math.max(e.outerRadius+r+n-h,0),x=v>0?v+r+n+h:0,T=0,I=i-p;if(r){let mt=v>0?v-r:0,Ct=P>0?P-r:0,jt=(mt+Ct)/2,Gt=jt!==0?I*jt/(jt+r):I;T=(I-Gt)/2;}let R=Math.max(.001,I*P-n/Be)/P,A=(I-R)/2,O=p+A+T,N=i-A-T,{outerStart:V,outerEnd:G,innerStart:X,innerEnd:nt}=O4(e,x,P,N-O),st=P-V,U=P-G,j=O+V/st,ut=N-G/U,Y=x+X,at=x+nt,pt=O+X/Y,dt=N-nt/at;if(t.beginPath(),o){if(t.arc(s,c,P,j,ut),G>0){let jt=od(U,ut,s,c);t.arc(jt.x,jt.y,G,ut,N+bn);}let mt=od(at,N,s,c);if(t.lineTo(mt.x,mt.y),nt>0){let jt=od(at,dt,s,c);t.arc(jt.x,jt.y,nt,N+bn,dt+Math.PI);}if(t.arc(s,c,x,N-nt/x,O+X/x,true),X>0){let jt=od(Y,pt,s,c);t.arc(jt.x,jt.y,X,pt+Math.PI,O-bn);}let Ct=od(st,O,s,c);if(t.lineTo(Ct.x,Ct.y),V>0){let jt=od(st,j,s,c);t.arc(jt.x,jt.y,V,O-bn,j);}}else {t.moveTo(s,c);let mt=Math.cos(j)*P+s,Ct=Math.sin(j)*P+c;t.lineTo(mt,Ct);let jt=Math.cos(ut)*P+s,Gt=Math.sin(ut)*P+c;t.lineTo(jt,Gt);}t.closePath();}function R4(t,e,n,r,i){let{fullCircles:o,startAngle:s,circumference:c}=e,p=e.endAngle;if(o){r1(t,e,n,r,s+rn,i);for(let h=0;h<o;++h)t.fill();isNaN(c)||(p=s+c%rn,c%rn===0&&(p+=rn));}return r1(t,e,n,r,p,i),t.fill(),p}function F4(t,e,n){let{x:r,y:i,startAngle:o,pixelMargin:s,fullCircles:c}=e,p=Math.max(e.outerRadius-s,0),h=e.innerRadius+s,v;for(n&&Qw(t,e,o+rn),t.beginPath(),t.arc(r,i,h,o+rn,o,true),v=0;v<c;++v)t.stroke();for(t.beginPath(),t.arc(r,i,p,o,o+rn),v=0;v<c;++v)t.stroke();}function M4(t,e,n,r,i,o){let{options:s}=e,{borderWidth:c,borderJoinStyle:p}=s,h=s.borderAlign==="inner";c&&(h?(t.lineWidth=c*2,t.lineJoin=p||"round"):(t.lineWidth=c,t.lineJoin=p||"bevel"),e.fullCircles&&F4(t,e,h),h&&Qw(t,e,i),r1(t,e,n,r,i,o),t.stroke());}var cs=class extends br{constructor(e){super(),this.options=void 0,this.circumference=void 0,this.startAngle=void 0,this.endAngle=void 0,this.innerRadius=void 0,this.outerRadius=void 0,this.pixelMargin=0,this.fullCircles=0,e&&Object.assign(this,e);}inRange(e,n,r){let i=this.getProps(["x","y"],r),{angle:o,distance:s}=Lg(i,{x:e,y:n}),{startAngle:c,endAngle:p,innerRadius:h,outerRadius:v,circumference:P}=this.getProps(["startAngle","endAngle","innerRadius","outerRadius","circumference"],r),x=this.options.spacing/2,I=me(P,p-c)>=rn||wc(o,c,p),R=Uo(s,h+x,v+x);return I&&R}getCenterPoint(e){let{x:n,y:r,startAngle:i,endAngle:o,innerRadius:s,outerRadius:c}=this.getProps(["x","y","startAngle","endAngle","innerRadius","outerRadius","circumference"],e),{offset:p,spacing:h}=this.options,v=(i+o)/2,P=(s+c+h+p)/2;return {x:n+Math.cos(v)*P,y:r+Math.sin(v)*P}}tooltipPosition(e){return this.getCenterPoint(e)}draw(e){let{options:n,circumference:r}=this,i=(n.offset||0)/2,o=(n.spacing||0)/2,s=n.circular;if(this.pixelMargin=n.borderAlign==="inner"?.33:0,this.fullCircles=r>rn?Math.floor(r/rn):0,r===0||this.innerRadius<0||this.outerRadius<0)return;e.save();let c=0;if(i){c=i/2;let h=(this.startAngle+this.endAngle)/2;e.translate(Math.cos(h)*c,Math.sin(h)*c),this.circumference>=Be&&(c=i);}e.fillStyle=n.backgroundColor,e.strokeStyle=n.borderColor;let p=R4(e,this,c,o,s);M4(e,this,c,o,p,s),e.restore();}};cs.id="arc";cs.defaults={borderAlign:"center",borderColor:"#fff",borderJoinStyle:void 0,borderRadius:0,borderWidth:2,offset:0,spacing:0,angle:void 0,circular:true};cs.defaultRoutes={backgroundColor:"backgroundColor"};function Kw(t,e,n=e){t.lineCap=me(n.borderCapStyle,e.borderCapStyle),t.setLineDash(me(n.borderDash,e.borderDash)),t.lineDashOffset=me(n.borderDashOffset,e.borderDashOffset),t.lineJoin=me(n.borderJoinStyle,e.borderJoinStyle),t.lineWidth=me(n.borderWidth,e.borderWidth),t.strokeStyle=me(n.borderColor,e.borderColor);}function N4(t,e,n){t.lineTo(n.x,n.y);}function L4(t){return t.stepped?I0:t.tension||t.cubicInterpolationMode==="monotone"?k0:N4}function Xw(t,e,n={}){let r=t.length,{start:i=0,end:o=r-1}=n,{start:s,end:c}=e,p=Math.max(i,s),h=Math.min(o,c),v=i<s&&o<s||i>c&&o>c;return {count:r,start:p,loop:e.loop,ilen:h<p&&!v?r+h-p:h-p}}function B4(t,e,n,r){let{points:i,options:o}=e,{count:s,start:c,loop:p,ilen:h}=Xw(i,n,r),v=L4(o),{move:P=true,reverse:x}=r||{},T,I,R;for(T=0;T<=h;++T)I=i[(c+(x?h-T:T))%s],!I.skip&&(P?(t.moveTo(I.x,I.y),P=false):v(t,R,I,x,o.stepped),R=I);return p&&(I=i[(c+(x?h:0))%s],v(t,R,I,x,o.stepped)),!!p}function U4(t,e,n,r){let i=e.points,{count:o,start:s,ilen:c}=Xw(i,n,r),{move:p=true,reverse:h}=r||{},v=0,P=0,x,T,I,R,A,O,N=G=>(s+(h?c-G:G))%o,V=()=>{R!==A&&(t.lineTo(v,A),t.lineTo(v,R),t.lineTo(v,O));};for(p&&(T=i[N(0)],t.moveTo(T.x,T.y)),x=0;x<=c;++x){if(T=i[N(x)],T.skip)continue;let G=T.x,X=T.y,nt=G|0;nt===I?(X<R?R=X:X>A&&(A=X),v=(P*v+G)/++P):(V(),t.lineTo(G,X),I=nt,P=0,R=A=X),O=X;}V();}function i1(t){let e=t.options,n=e.borderDash&&e.borderDash.length;return !t._decimated&&!t._loop&&!e.tension&&e.cubicInterpolationMode!=="monotone"&&!e.stepped&&!n?U4:B4}function $4(t){return t.stepped?N0:t.tension||t.cubicInterpolationMode==="monotone"?L0:ts}function G4(t,e,n,r){let i=e._path;i||(i=e._path=new Path2D,e.path(i,n,r)&&i.closePath()),Kw(t,e.options),t.stroke(i);}function j4(t,e,n,r){let{segments:i,options:o}=e,s=i1(e);for(let c of i)Kw(t,o,c.style),t.beginPath(),s(t,e,c,{start:n,end:n+r-1})&&t.closePath(),t.stroke();}var V4=typeof Path2D=="function";function z4(t,e,n,r){V4&&!e.options.segment?G4(t,e,n,r):j4(t,e,n,r);}var Go=class extends br{constructor(e){super(),this.animated=true,this.options=void 0,this._chart=void 0,this._loop=void 0,this._fullLoop=void 0,this._path=void 0,this._points=void 0,this._segments=void 0,this._decimated=false,this._pointsUpdated=false,this._datasetIndex=void 0,e&&Object.assign(this,e);}updateControlPoints(e,n){let r=this.options;if((r.tension||r.cubicInterpolationMode==="monotone")&&!r.stepped&&!this._pointsUpdated){let i=r.spanGaps?this._loop:this._fullLoop;R0(this._points,r,e,i,n),this._pointsUpdated=true;}}set points(e){this._points=e,delete this._segments,delete this._path,this._pointsUpdated=false;}get points(){return this._points}get segments(){return this._segments||(this._segments=B0(this,this.options.segment))}first(){let e=this.segments,n=this.points;return e.length&&n[e[0].start]}last(){let e=this.segments,n=this.points,r=e.length;return r&&n[e[r-1].end]}interpolate(e,n){let r=this.options,i=e[n],o=this.points,s=ry(this,{property:n,start:i,end:i});if(!s.length)return;let c=[],p=$4(r),h,v;for(h=0,v=s.length;h<v;++h){let{start:P,end:x}=s[h],T=o[P],I=o[x];if(T===I){c.push(T);continue}let R=Math.abs((i-T[n])/(I[n]-T[n])),A=p(T,I,R,r.stepped);A[n]=e[n],c.push(A);}return c.length===1?c[0]:c}pathSegment(e,n,r){return i1(this)(e,this,n,r)}path(e,n,r){let i=this.segments,o=i1(this),s=this._loop;n=n||0,r=r||this.points.length-n;for(let c of i)s&=o(e,this,c,{start:n,end:n+r-1});return !!s}draw(e,n,r,i){let o=this.options||{};(this.points||[]).length&&o.borderWidth&&(e.save(),z4(e,this,r,i),e.restore()),this.animated&&(this._pointsUpdated=false,this._path=void 0);}};Go.id="line";Go.defaults={borderCapStyle:"butt",borderDash:[],borderDashOffset:0,borderJoinStyle:"miter",borderWidth:3,capBezierPoints:true,cubicInterpolationMode:"default",fill:false,spanGaps:false,stepped:false,tension:0};Go.defaultRoutes={backgroundColor:"backgroundColor",borderColor:"borderColor"};Go.descriptors={_scriptable:true,_indexable:t=>t!=="borderDash"&&t!=="fill"};function bw(t,e,n,r){let i=t.options,{[n]:o}=t.getProps([n],r);return Math.abs(e-o)<i.radius+i.hitRadius}var us=class extends br{constructor(e){super(),this.options=void 0,this.parsed=void 0,this.skip=void 0,this.stop=void 0,e&&Object.assign(this,e);}inRange(e,n,r){let i=this.options,{x:o,y:s}=this.getProps(["x","y"],r);return Math.pow(e-o,2)+Math.pow(n-s,2)<Math.pow(i.hitRadius+i.radius,2)}inXRange(e,n){return bw(this,e,"x",n)}inYRange(e,n){return bw(this,e,"y",n)}getCenterPoint(e){let{x:n,y:r}=this.getProps(["x","y"],e);return {x:n,y:r}}size(e){e=e||this.options||{};let n=e.radius||0;n=Math.max(n,n&&e.hoverRadius||0);let r=n&&e.borderWidth||0;return (n+r)*2}draw(e,n){let r=this.options;this.skip||r.radius<.1||!xc(this,n,this.size(r)/2)||(e.strokeStyle=r.borderColor,e.lineWidth=r.borderWidth,e.fillStyle=r.backgroundColor,pf(e,r,this.x,this.y));}getRange(){let e=this.options||{};return e.radius+e.hitRadius}};us.id="point";us.defaults={borderWidth:1,hitRadius:1,hoverBorderWidth:1,hoverRadius:4,pointStyle:"circle",radius:3,rotation:0};us.defaultRoutes={backgroundColor:"backgroundColor",borderColor:"borderColor"};function Zw(t,e){let{x:n,y:r,base:i,width:o,height:s}=t.getProps(["x","y","base","width","height"],e),c,p,h,v,P;return t.horizontal?(P=s/2,c=Math.min(n,i),p=Math.max(n,i),h=r-P,v=r+P):(P=o/2,c=n-P,p=n+P,h=Math.min(r,i),v=Math.max(r,i)),{left:c,top:h,right:p,bottom:v}}function yl(t,e,n,r){return t?0:Nr(e,n,r)}function H4(t,e,n){let r=t.options.borderWidth,i=t.borderSkipped,o=qg(r);return {t:yl(i.top,o.top,0,n),r:yl(i.right,o.right,0,e),b:yl(i.bottom,o.bottom,0,n),l:yl(i.left,o.left,0,e)}}function W4(t,e,n){let{enableBorderRadius:r}=t.getProps(["enableBorderRadius"]),i=t.options.borderRadius,o=$o(i),s=Math.min(e,n),c=t.borderSkipped,p=r||Te(i);return {topLeft:yl(!p||c.top||c.left,o.topLeft,0,s),topRight:yl(!p||c.top||c.right,o.topRight,0,s),bottomLeft:yl(!p||c.bottom||c.left,o.bottomLeft,0,s),bottomRight:yl(!p||c.bottom||c.right,o.bottomRight,0,s)}}function q4(t){let e=Zw(t),n=e.right-e.left,r=e.bottom-e.top,i=H4(t,n/2,r/2),o=W4(t,n/2,r/2);return {outer:{x:e.left,y:e.top,w:n,h:r,radius:o},inner:{x:e.left+i.l,y:e.top+i.t,w:n-i.l-i.r,h:r-i.t-i.b,radius:{topLeft:Math.max(0,o.topLeft-Math.max(i.t,i.l)),topRight:Math.max(0,o.topRight-Math.max(i.t,i.r)),bottomLeft:Math.max(0,o.bottomLeft-Math.max(i.b,i.l)),bottomRight:Math.max(0,o.bottomRight-Math.max(i.b,i.r))}}}}function H0(t,e,n,r){let i=e===null,o=n===null,c=t&&!(i&&o)&&Zw(t,r);return c&&(i||Uo(e,c.left,c.right))&&(o||Uo(n,c.top,c.bottom))}function Y4(t){return t.topLeft||t.topRight||t.bottomLeft||t.bottomRight}function Q4(t,e){t.rect(e.x,e.y,e.w,e.h);}function W0(t,e,n={}){let r=t.x!==n.x?-e:0,i=t.y!==n.y?-e:0,o=(t.x+t.w!==n.x+n.w?e:0)-r,s=(t.y+t.h!==n.y+n.h?e:0)-i;return {x:t.x+r,y:t.y+i,w:t.w+o,h:t.h+s,radius:t.radius}}var ds=class extends br{constructor(e){super(),this.options=void 0,this.horizontal=void 0,this.base=void 0,this.width=void 0,this.height=void 0,this.inflateAmount=void 0,e&&Object.assign(this,e);}draw(e){let{inflateAmount:n,options:{borderColor:r,backgroundColor:i}}=this,{inner:o,outer:s}=q4(this),c=Y4(s.radius)?os:Q4;e.save(),(s.w!==o.w||s.h!==o.h)&&(e.beginPath(),c(e,W0(s,n,o)),e.clip(),c(e,W0(o,-n,s)),e.fillStyle=r,e.fill("evenodd")),e.beginPath(),c(e,W0(o,n)),e.fillStyle=i,e.fill(),e.restore();}inRange(e,n,r){return H0(this,e,n,r)}inXRange(e,n){return H0(this,e,null,n)}inYRange(e,n){return H0(this,null,e,n)}getCenterPoint(e){let{x:n,y:r,base:i,horizontal:o}=this.getProps(["x","y","base","horizontal"],e);return {x:o?(n+i)/2:n,y:o?r:(r+i)/2}}getRange(e){return e==="x"?this.width/2:this.height/2}};ds.id="bar";ds.defaults={borderSkipped:"start",borderWidth:0,borderRadius:0,inflateAmount:"auto",pointStyle:void 0};ds.defaultRoutes={backgroundColor:"backgroundColor",borderColor:"borderColor"};function K4(t,e,n){let r=t.segments,i=t.points,o=e.points,s=[];for(let c of r){let{start:p,end:h}=c;h=s1(p,h,i);let v=o1(n,i[p],i[h],c.loop);if(!e.segments){s.push({source:c,target:v,start:i[p],end:i[h]});continue}let P=ry(e,v);for(let x of P){let T=o1(n,o[x.start],o[x.end],x.loop),I=ny(c,i,T);for(let R of I)s.push({source:R,target:x,start:{[n]:vw(v,T,"start",Math.max)},end:{[n]:vw(v,T,"end",Math.min)}});}}return s}function o1(t,e,n,r){if(r)return;let i=e[t],o=n[t];return t==="angle"&&(i=ai(i),o=ai(o)),{property:t,start:i,end:o}}function X4(t,e){let{x:n=null,y:r=null}=t||{},i=e.points,o=[];return e.segments.forEach(({start:s,end:c})=>{c=s1(s,c,i);let p=i[s],h=i[c];r!==null?(o.push({x:p.x,y:r}),o.push({x:h.x,y:r})):n!==null&&(o.push({x:n,y:p.y}),o.push({x:n,y:h.y}));}),o}function s1(t,e,n){for(;e>t;e--){let r=n[e];if(!isNaN(r.x)&&!isNaN(r.y))break}return e}function vw(t,e,n,r){return t&&e?r(t[n],e[n]):t?t[n]:e?e[n]:0}function Jw(t,e){let n=[],r=false;return He(t)?(r=true,n=t):n=X4(t,e),n.length?new Go({points:n,options:{tension:0},_loop:r,_fullLoop:r}):null}function Cw(t){return t&&t.fill!==false}function Z4(t,e,n){let i=t[e].fill,o=[e],s;if(!n)return i;for(;i!==false&&o.indexOf(i)===-1;){if(!Mn(i))return i;if(s=t[i],!s)return false;if(s.visible)return i;o.push(i),i=s.fill;}return false}function J4(t,e,n){let r=rU(t);if(Te(r))return isNaN(r.value)?false:r;let i=parseFloat(r);return Mn(i)&&Math.floor(i)===i?tU(r[0],e,i,n):["origin","start","end","stack","shape"].indexOf(r)>=0&&r}function tU(t,e,n,r){return (t==="-"||t==="+")&&(n=e+n),n===e||n<0||n>=r?false:n}function eU(t,e){let n=null;return t==="start"?n=e.bottom:t==="end"?n=e.top:Te(t)?n=e.getPixelForValue(t.value):e.getBasePixel&&(n=e.getBasePixel()),n}function nU(t,e,n){let r;return t==="start"?r=n:t==="end"?r=e.options.reverse?e.min:e.max:Te(t)?r=t.value:r=e.getBaseValue(),r}function rU(t){let e=t.options,n=e.fill,r=me(n&&n.target,n);return r===void 0&&(r=!!e.backgroundColor),r===false||r===null?false:r===true?"origin":r}function iU(t){let{scale:e,index:n,line:r}=t,i=[],o=r.segments,s=r.points,c=oU(e,n);c.push(Jw({x:null,y:e.bottom},r));for(let p=0;p<o.length;p++){let h=o[p];for(let v=h.start;v<=h.end;v++)aU(i,s[v],c);}return new Go({points:i,options:{}})}function oU(t,e){let n=[],r=t.getMatchingVisibleMetas("line");for(let i=0;i<r.length;i++){let o=r[i];if(o.index===e)break;o.hidden||n.unshift(o.dataset);}return n}function aU(t,e,n){let r=[];for(let i=0;i<n.length;i++){let o=n[i],{first:s,last:c,point:p}=sU(o,e,"x");if(!(!p||s&&c)){if(s)r.unshift(p);else if(t.push(p),!c)break}}t.push(...r);}function sU(t,e,n){let r=t.interpolate(e,n);if(!r)return {};let i=r[n],o=t.segments,s=t.points,c=false,p=false;for(let h=0;h<o.length;h++){let v=o[h],P=s[v.start][n],x=s[v.end][n];if(Uo(i,P,x)){c=i===P,p=i===x;break}}return {first:c,last:p,point:r}}var hy=class{constructor(e){this.x=e.x,this.y=e.y,this.radius=e.radius;}pathSegment(e,n,r){let{x:i,y:o,radius:s}=this;return n=n||{start:0,end:rn},e.arc(i,o,s,n.end,n.start,true),!r.bounds}interpolate(e){let{x:n,y:r,radius:i}=this,o=e.angle;return {x:n+Math.cos(o)*i,y:r+Math.sin(o)*i,angle:o}}};function lU(t){let{chart:e,fill:n,line:r}=t;if(Mn(n))return cU(e,n);if(n==="stack")return iU(t);if(n==="shape")return true;let i=uU(t);return i instanceof hy?i:Jw(i,r)}function cU(t,e){let n=t.getDatasetMeta(e);return n&&t.isDatasetVisible(e)?n.dataset:null}function uU(t){return (t.scale||{}).getPointPositionForValue?pU(t):dU(t)}function dU(t){let{scale:e={},fill:n}=t,r=eU(n,e);if(Mn(r)){let i=e.isHorizontal();return {x:i?r:null,y:i?null:r}}return null}function pU(t){let{scale:e,fill:n}=t,r=e.options,i=e.getLabels().length,o=r.reverse?e.max:e.min,s=nU(n,e,o),c=[];if(r.grid.circular){let p=e.getPointPositionForValue(0,o);return new hy({x:p.x,y:p.y,radius:e.getDistanceFromCenterForValue(s)})}for(let p=0;p<i;++p)c.push(e.getPointPositionForValue(p,s));return c}function q0(t,e,n){let r=lU(e),{line:i,scale:o,axis:s}=e,c=i.options,p=c.fill,h=c.backgroundColor,{above:v=h,below:P=h}=p||{};r&&i.points.length&&(fl(t,n),fU(t,{line:i,target:r,above:v,below:P,area:n,scale:o,axis:s}),hl(t));}function fU(t,e){let{line:n,target:r,above:i,below:o,area:s,scale:c}=e,p=n._loop?"angle":e.axis;t.save(),p==="x"&&o!==i&&(Sw(t,r,s.top),Pw(t,{line:n,target:r,color:i,scale:c,property:p}),t.restore(),t.save(),Sw(t,r,s.bottom)),Pw(t,{line:n,target:r,color:o,scale:c,property:p}),t.restore();}function Sw(t,e,n){let{segments:r,points:i}=e,o=true,s=false;t.beginPath();for(let c of r){let{start:p,end:h}=c,v=i[p],P=i[s1(p,h,i)];o?(t.moveTo(v.x,v.y),o=false):(t.lineTo(v.x,n),t.lineTo(v.x,v.y)),s=!!e.pathSegment(t,c,{move:s}),s?t.closePath():t.lineTo(P.x,n);}t.lineTo(e.first().x,n),t.closePath(),t.clip();}function Pw(t,e){let{line:n,target:r,property:i,color:o,scale:s}=e,c=K4(n,r,i);for(let{source:p,target:h,start:v,end:P}of c){let{style:{backgroundColor:x=o}={}}=p,T=r!==true;t.save(),t.fillStyle=x,hU(t,s,T&&o1(i,v,P)),t.beginPath();let I=!!n.pathSegment(t,p),R;if(T){I?t.closePath():xw(t,r,P,i);let A=!!r.pathSegment(t,h,{move:I,reverse:true});R=I&&A,R||xw(t,r,v,i);}t.closePath(),t.fill(R?"evenodd":"nonzero"),t.restore();}}function hU(t,e,n){let{top:r,bottom:i}=e.chart.chartArea,{property:o,start:s,end:c}=n||{};o==="x"&&(t.beginPath(),t.rect(s,r,c-s,i-r),t.clip());}function xw(t,e,n,r){let i=e.interpolate(n,r);i&&t.lineTo(i.x,i.y);}var tI={id:"filler",afterDatasetsUpdate(t,e,n){let r=(t.data.datasets||[]).length,i=[],o,s,c,p;for(s=0;s<r;++s)o=t.getDatasetMeta(s),c=o.dataset,p=null,c&&c.options&&c instanceof Go&&(p={visible:t.isDatasetVisible(s),index:s,fill:J4(c,s,r),chart:t,axis:o.controller.options.indexAxis,scale:o.vScale,line:c}),o.$filler=p,i.push(p);for(s=0;s<r;++s)p=i[s],!(!p||p.fill===false)&&(p.fill=Z4(i,s,n.propagate));},beforeDraw(t,e,n){let r=n.drawTime==="beforeDraw",i=t.getSortedVisibleDatasetMetas(),o=t.chartArea;for(let s=i.length-1;s>=0;--s){let c=i[s].$filler;c&&(c.line.updateControlPoints(o,c.axis),r&&c.fill&&q0(t.ctx,c,o));}},beforeDatasetsDraw(t,e,n){if(n.drawTime!=="beforeDatasetsDraw")return;let r=t.getSortedVisibleDatasetMetas();for(let i=r.length-1;i>=0;--i){let o=r[i].$filler;Cw(o)&&q0(t.ctx,o,t.chartArea);}},beforeDatasetDraw(t,e,n){let r=e.meta.$filler;!Cw(r)||n.drawTime!=="beforeDatasetDraw"||q0(t.ctx,r,t.chartArea);},defaults:{propagate:true,drawTime:"beforeDatasetDraw"}},Ew=(t,e)=>{let{boxHeight:n=e,boxWidth:r=e}=t;return t.usePointStyle&&(n=Math.min(n,e),r=t.pointStyleWidth||Math.min(r,e)),{boxWidth:r,boxHeight:n,itemHeight:Math.max(e,n)}},mU=(t,e)=>t!==null&&e!==null&&t.datasetIndex===e.datasetIndex&&t.index===e.index,my=class extends br{constructor(e){super(),this._added=false,this.legendHitBoxes=[],this._hoveredItem=null,this.doughnutMode=false,this.chart=e.chart,this.options=e.options,this.ctx=e.ctx,this.legendItems=void 0,this.columnSizes=void 0,this.lineWidths=void 0,this.maxHeight=void 0,this.maxWidth=void 0,this.top=void 0,this.bottom=void 0,this.left=void 0,this.right=void 0,this.height=void 0,this.width=void 0,this._margins=void 0,this.position=void 0,this.weight=void 0,this.fullSize=void 0;}update(e,n,r){this.maxWidth=e,this.maxHeight=n,this._margins=r,this.setDimensions(),this.buildLabels(),this.fit();}setDimensions(){this.isHorizontal()?(this.width=this.maxWidth,this.left=this._margins.left,this.right=this.width):(this.height=this.maxHeight,this.top=this._margins.top,this.bottom=this.height);}buildLabels(){let e=this.options.labels||{},n=Qe(e.generateLabels,[this.chart],this)||[];e.filter&&(n=n.filter(r=>e.filter(r,this.chart.data))),e.sort&&(n=n.sort((r,i)=>e.sort(r,i,this.chart.data))),this.options.reverse&&n.reverse(),this.legendItems=n;}fit(){let{options:e,ctx:n}=this;if(!e.display){this.width=this.height=0;return}let r=e.labels,i=Sn(r.font),o=i.size,s=this._computeTitleHeight(),{boxWidth:c,itemHeight:p}=Ew(r,o),h,v;n.font=i.string,this.isHorizontal()?(h=this.maxWidth,v=this._fitRows(s,o,c,p)+10):(v=this.maxHeight,h=this._fitCols(s,o,c,p)+10),this.width=Math.min(h,e.maxWidth||this.maxWidth),this.height=Math.min(v,e.maxHeight||this.maxHeight);}_fitRows(e,n,r,i){let{ctx:o,maxWidth:s,options:{labels:{padding:c}}}=this,p=this.legendHitBoxes=[],h=this.lineWidths=[0],v=i+c,P=e;o.textAlign="left",o.textBaseline="middle";let x=-1,T=-v;return this.legendItems.forEach((I,R)=>{let A=r+n/2+o.measureText(I.text).width;(R===0||h[h.length-1]+A+2*c>s)&&(P+=v,h[h.length-(R>0?0:1)]=0,T+=v,x++),p[R]={left:0,top:T,row:x,width:A,height:i},h[h.length-1]+=A+c;}),P}_fitCols(e,n,r,i){let{ctx:o,maxHeight:s,options:{labels:{padding:c}}}=this,p=this.legendHitBoxes=[],h=this.columnSizes=[],v=s-e,P=c,x=0,T=0,I=0,R=0;return this.legendItems.forEach((A,O)=>{let N=r+n/2+o.measureText(A.text).width;O>0&&T+i+2*c>v&&(P+=x+c,h.push({width:x,height:T}),I+=x+c,R++,x=T=0),p[O]={left:I,top:T,col:R,width:N,height:i},x=Math.max(x,N),T+=i+c;}),P+=x,h.push({width:x,height:T}),P}adjustHitBoxes(){if(!this.options.display)return;let e=this._computeTitleHeight(),{legendHitBoxes:n,options:{align:r,labels:{padding:i},rtl:o}}=this,s=ml(o,this.left,this.width);if(this.isHorizontal()){let c=0,p=Lr(r,this.left+i,this.right-this.lineWidths[c]);for(let h of n)c!==h.row&&(c=h.row,p=Lr(r,this.left+i,this.right-this.lineWidths[c])),h.top+=this.top+e+i,h.left=s.leftForLtr(s.x(p),h.width),p+=h.width+i;}else {let c=0,p=Lr(r,this.top+e+i,this.bottom-this.columnSizes[c].height);for(let h of n)h.col!==c&&(c=h.col,p=Lr(r,this.top+e+i,this.bottom-this.columnSizes[c].height)),h.top=p,h.left+=this.left+i,h.left=s.leftForLtr(s.x(h.left),h.width),p+=h.height+i;}}isHorizontal(){return this.options.position==="top"||this.options.position==="bottom"}draw(){if(this.options.display){let e=this.ctx;fl(e,this),this._draw(),hl(e);}}_draw(){let{options:e,columnSizes:n,lineWidths:r,ctx:i}=this,{align:o,labels:s}=e,c=ke.color,p=ml(e.rtl,this.left,this.width),h=Sn(s.font),{color:v,padding:P}=s,x=h.size,T=x/2,I;this.drawTitle(),i.textAlign=p.textAlign("left"),i.textBaseline="middle",i.lineWidth=.5,i.font=h.string;let{boxWidth:R,boxHeight:A,itemHeight:O}=Ew(s,x),N=function(st,U,j){if(isNaN(R)||R<=0||isNaN(A)||A<0)return;i.save();let ut=me(j.lineWidth,1);if(i.fillStyle=me(j.fillStyle,c),i.lineCap=me(j.lineCap,"butt"),i.lineDashOffset=me(j.lineDashOffset,0),i.lineJoin=me(j.lineJoin,"miter"),i.lineWidth=ut,i.strokeStyle=me(j.strokeStyle,c),i.setLineDash(me(j.lineDash,[])),s.usePointStyle){let Y={radius:A*Math.SQRT2/2,pointStyle:j.pointStyle,rotation:j.rotation,borderWidth:ut},at=p.xPlus(st,R/2),pt=U+T;Wg(i,Y,at,pt,s.pointStyleWidth&&R);}else {let Y=U+Math.max((x-A)/2,0),at=p.leftForLtr(st,R),pt=$o(j.borderRadius);i.beginPath(),Object.values(pt).some(dt=>dt!==0)?os(i,{x:at,y:Y,w:R,h:A,radius:pt}):i.rect(at,Y,R,A),i.fill(),ut!==0&&i.stroke();}i.restore();},V=function(st,U,j){is(i,j.text,st,U+O/2,h,{strikethrough:j.hidden,textAlign:p.textAlign(j.textAlign)});},G=this.isHorizontal(),X=this._computeTitleHeight();G?I={x:Lr(o,this.left+P,this.right-r[0]),y:this.top+P+X,line:0}:I={x:this.left+P,y:Lr(o,this.top+X+P,this.bottom-n[0].height),line:0},ty(this.ctx,e.textDirection);let nt=O+P;this.legendItems.forEach((st,U)=>{i.strokeStyle=st.fontColor||v,i.fillStyle=st.fontColor||v;let j=i.measureText(st.text).width,ut=p.textAlign(st.textAlign||(st.textAlign=s.textAlign)),Y=R+T+j,at=I.x,pt=I.y;p.setWidth(this.width),G?U>0&&at+Y+P>this.right&&(pt=I.y+=nt,I.line++,at=I.x=Lr(o,this.left+P,this.right-r[I.line])):U>0&&pt+nt>this.bottom&&(at=I.x=at+n[I.line].width+P,I.line++,pt=I.y=Lr(o,this.top+X+P,this.bottom-n[I.line].height));let dt=p.x(at);N(dt,pt,st),at=P0(ut,at+R+T,G?at+Y:this.right,e.rtl),V(p.x(at),pt,st),G?I.x+=Y+P:I.y+=nt;}),ey(this.ctx,e.textDirection);}drawTitle(){let e=this.options,n=e.title,r=Sn(n.font),i=$n(n.padding);if(!n.display)return;let o=ml(e.rtl,this.left,this.width),s=this.ctx,c=n.position,p=r.size/2,h=i.top+p,v,P=this.left,x=this.width;if(this.isHorizontal())x=Math.max(...this.lineWidths),v=this.top+h,P=Lr(e.align,P,this.right-x);else {let I=this.columnSizes.reduce((R,A)=>Math.max(R,A.height),0);v=h+Lr(e.align,this.top,this.bottom-I-e.labels.padding-this._computeTitleHeight());}let T=Lr(c,P,P+x);s.textAlign=o.textAlign(uf(c)),s.textBaseline="middle",s.strokeStyle=n.color,s.fillStyle=n.color,s.font=r.string,is(s,n.text,T,v,r);}_computeTitleHeight(){let e=this.options.title,n=Sn(e.font),r=$n(e.padding);return e.display?n.lineHeight+r.height:0}_getLegendItemAt(e,n){let r,i,o;if(Uo(e,this.left,this.right)&&Uo(n,this.top,this.bottom)){for(o=this.legendHitBoxes,r=0;r<o.length;++r)if(i=o[r],Uo(e,i.left,i.left+i.width)&&Uo(n,i.top,i.top+i.height))return this.legendItems[r]}return null}handleEvent(e){let n=this.options;if(!gU(e.type,n))return;let r=this._getLegendItemAt(e.x,e.y);if(e.type==="mousemove"||e.type==="mouseout"){let i=this._hoveredItem,o=mU(i,r);i&&!o&&Qe(n.onLeave,[e,i,this],this),this._hoveredItem=r,r&&!o&&Qe(n.onHover,[e,r,this],this);}else r&&Qe(n.onClick,[e,r,this],this);}};function gU(t,e){return !!((t==="mousemove"||t==="mouseout")&&(e.onHover||e.onLeave)||e.onClick&&(t==="click"||t==="mouseup"))}var eI={id:"legend",_element:my,start(t,e,n){let r=t.legend=new my({ctx:t.ctx,options:n,chart:t});yo.configure(t,r,n),yo.addBox(t,r);},stop(t){yo.removeBox(t,t.legend),delete t.legend;},beforeUpdate(t,e,n){let r=t.legend;yo.configure(t,r,n),r.options=n;},afterUpdate(t){let e=t.legend;e.buildLabels(),e.adjustHitBoxes();},afterEvent(t,e){e.replay||t.legend.handleEvent(e.event);},defaults:{display:true,position:"top",align:"center",fullSize:true,reverse:false,weight:1e3,onClick(t,e,n){let r=e.datasetIndex,i=n.chart;i.isDatasetVisible(r)?(i.hide(r),e.hidden=true):(i.show(r),e.hidden=false);},onHover:null,onLeave:null,labels:{color:t=>t.chart.options.color,boxWidth:40,padding:10,generateLabels(t){let e=t.data.datasets,{labels:{usePointStyle:n,pointStyle:r,textAlign:i,color:o}}=t.legend.options;return t._getSortedDatasetMetas().map(s=>{let c=s.controller.getStyle(n?0:void 0),p=$n(c.borderWidth);return {text:e[s.index].label,fillStyle:c.backgroundColor,fontColor:o,hidden:!s.visible,lineCap:c.borderCapStyle,lineDash:c.borderDash,lineDashOffset:c.borderDashOffset,lineJoin:c.borderJoinStyle,lineWidth:(p.width+p.height)/4,strokeStyle:c.borderColor,pointStyle:r||c.pointStyle,rotation:c.rotation,textAlign:i||c.textAlign,borderRadius:0,datasetIndex:s.index}},this)}},title:{color:t=>t.chart.options.color,display:false,position:"center",text:""}},descriptors:{_scriptable:t=>!t.startsWith("on"),labels:{_scriptable:t=>!["generateLabels","filter","sort"].includes(t)}}},gy=class extends br{constructor(e){super(),this.chart=e.chart,this.options=e.options,this.ctx=e.ctx,this._padding=void 0,this.top=void 0,this.bottom=void 0,this.left=void 0,this.right=void 0,this.width=void 0,this.height=void 0,this.position=void 0,this.weight=void 0,this.fullSize=void 0;}update(e,n){let r=this.options;if(this.left=0,this.top=0,!r.display){this.width=this.height=this.right=this.bottom=0;return}this.width=this.right=e,this.height=this.bottom=n;let i=He(r.text)?r.text.length:1;this._padding=$n(r.padding);let o=i*Sn(r.font).lineHeight+this._padding.height;this.isHorizontal()?this.height=o:this.width=o;}isHorizontal(){let e=this.options.position;return e==="top"||e==="bottom"}_drawArgs(e){let{top:n,left:r,bottom:i,right:o,options:s}=this,c=s.align,p=0,h,v,P;return this.isHorizontal()?(v=Lr(c,r,o),P=n+e,h=o-r):(s.position==="left"?(v=r+e,P=Lr(c,i,n),p=Be*-0.5):(v=o-e,P=Lr(c,n,i),p=Be*.5),h=i-n),{titleX:v,titleY:P,maxWidth:h,rotation:p}}draw(){let e=this.ctx,n=this.options;if(!n.display)return;let r=Sn(n.font),o=r.lineHeight/2+this._padding.top,{titleX:s,titleY:c,maxWidth:p,rotation:h}=this._drawArgs(o);is(e,n.text,0,0,r,{color:n.color,maxWidth:p,rotation:h,textAlign:uf(n.align),textBaseline:"middle",translation:[s,c]});}};function yU(t,e){let n=new gy({ctx:t.ctx,options:e,chart:t});yo.configure(t,n,e),yo.addBox(t,n),t.titleBlock=n;}var nI={id:"title",_element:gy,start(t,e,n){yU(t,n);},stop(t){let e=t.titleBlock;yo.removeBox(t,e),delete t.titleBlock;},beforeUpdate(t,e,n){let r=t.titleBlock;yo.configure(t,r,n),r.options=n;},defaults:{align:"center",display:false,font:{weight:"bold"},fullSize:true,padding:10,position:"top",text:"",weight:2e3},defaultRoutes:{color:"color"},descriptors:{_scriptable:true,_indexable:false}};var Pf={average(t){if(!t.length)return false;let e,n,r=0,i=0,o=0;for(e=0,n=t.length;e<n;++e){let s=t[e].element;if(s&&s.hasValue()){let c=s.tooltipPosition();r+=c.x,i+=c.y,++o;}}return {x:r/o,y:i/o}},nearest(t,e){if(!t.length)return false;let n=e.x,r=e.y,i=Number.POSITIVE_INFINITY,o,s,c;for(o=0,s=t.length;o<s;++o){let p=t[o].element;if(p&&p.hasValue()){let h=p.getCenterPoint(),v=ns(e,h);v<i&&(i=v,c=p);}}if(c){let p=c.tooltipPosition();n=p.x,r=p.y;}return {x:n,y:r}}};function va(t,e){return e&&(He(e)?Array.prototype.push.apply(t,e):t.push(e)),t}function ls(t){return (typeof t=="string"||t instanceof String)&&t.indexOf(`
5647
5647
  `)>-1?t.split(`
5648
- `):t}function bU(t,e){let{element:n,datasetIndex:r,index:i}=e,o=t.getDatasetMeta(r).controller,{label:s,value:c}=o.getLabelAndValue(i);return {chart:t,label:s,parsed:o.getParsed(i),raw:t.data.datasets[r].data[i],formattedValue:c,dataset:o.getDataset(),dataIndex:i,datasetIndex:r,element:n}}function _w(t,e){let n=t.chart.ctx,{body:r,footer:i,title:o}=t,{boxWidth:s,boxHeight:c}=e,p=Sn(e.bodyFont),h=Sn(e.titleFont),v=Sn(e.footerFont),P=o.length,x=i.length,T=r.length,I=$n(e.padding),F=I.height,A=0,O=r.reduce((G,X)=>G+X.before.length+X.lines.length+X.after.length,0);if(O+=t.beforeBody.length+t.afterBody.length,P&&(F+=P*h.lineHeight+(P-1)*e.titleSpacing+e.titleMarginBottom),O){let G=e.displayColors?Math.max(c,p.lineHeight):p.lineHeight;F+=T*G+(O-T)*p.lineHeight+(O-1)*e.bodySpacing;}x&&(F+=e.footerMarginTop+x*v.lineHeight+(x-1)*e.footerSpacing);let N=0,V=function(G){A=Math.max(A,n.measureText(G).width+N);};return n.save(),n.font=h.string,tn(t.title,V),n.font=p.string,tn(t.beforeBody.concat(t.afterBody),V),N=e.displayColors?s+2+e.boxPadding:0,tn(r,G=>{tn(G.before,V),tn(G.lines,V),tn(G.after,V);}),N=0,n.font=v.string,tn(t.footer,V),n.restore(),A+=I.width,{width:A,height:F}}function vU(t,e){let{y:n,height:r}=e;return n<r/2?"top":n>t.height-r/2?"bottom":"center"}function CU(t,e,n,r){let{x:i,width:o}=r,s=n.caretSize+n.caretPadding;if(t==="left"&&i+o+s>e.width||t==="right"&&i-o-s<0)return true}function SU(t,e,n,r){let{x:i,width:o}=n,{width:s,chartArea:{left:c,right:p}}=t,h="center";return r==="center"?h=i<=(c+p)/2?"left":"right":i<=o/2?h="left":i>=s-o/2&&(h="right"),CU(h,t,e,n)&&(h="center"),h}function Tw(t,e,n){let r=n.yAlign||e.yAlign||vU(t,n);return {xAlign:n.xAlign||e.xAlign||SU(t,e,n,r),yAlign:r}}function PU(t,e){let{x:n,width:r}=t;return e==="right"?n-=r:e==="center"&&(n-=r/2),n}function xU(t,e,n){let{y:r,height:i}=t;return e==="top"?r+=n:e==="bottom"?r-=i+n:r-=i/2,r}function ww(t,e,n,r){let{caretSize:i,caretPadding:o,cornerRadius:s}=t,{xAlign:c,yAlign:p}=n,h=i+o,{topLeft:v,topRight:P,bottomLeft:x,bottomRight:T}=$o(s),I=PU(e,c),F=xU(e,p,h);return p==="center"?c==="left"?I+=h:c==="right"&&(I-=h):c==="left"?I-=Math.max(v,x)+i:c==="right"&&(I+=Math.max(P,T)+i),{x:Nr(I,0,r.width-e.width),y:Nr(F,0,r.height-e.height)}}function sy(t,e,n){let r=$n(n.padding);return e==="center"?t.x+t.width/2:e==="right"?t.x+t.width-r.right:t.x+r.left}function Iw(t){return va([],ls(t))}function EU(t,e,n){return ba(t,{tooltip:e,tooltipItems:n,type:"tooltip"})}function kw(t,e){let n=e&&e.dataset&&e.dataset.tooltip&&e.dataset.tooltip.callbacks;return n?t.override(n):t}var Af=class extends br{constructor(e){super(),this.opacity=0,this._active=[],this._eventPosition=void 0,this._size=void 0,this._cachedAnimations=void 0,this._tooltipItems=[],this.$animations=void 0,this.$context=void 0,this.chart=e.chart||e._chart,this._chart=this.chart,this.options=e.options,this.dataPoints=void 0,this.title=void 0,this.beforeBody=void 0,this.body=void 0,this.afterBody=void 0,this.footer=void 0,this.xAlign=void 0,this.yAlign=void 0,this.x=void 0,this.y=void 0,this.height=void 0,this.width=void 0,this.caretX=void 0,this.caretY=void 0,this.labelColors=void 0,this.labelPointStyles=void 0,this.labelTextColors=void 0;}initialize(e){this.options=e,this._cachedAnimations=void 0,this.$context=void 0;}_resolveAnimations(){let e=this._cachedAnimations;if(e)return e;let n=this.chart,r=this.options.setContext(this.getContext()),i=r.enabled&&n.options.animation&&r.animations,o=new sd(this.chart,i);return i._cacheable&&(this._cachedAnimations=Object.freeze(o)),o}getContext(){return this.$context||(this.$context=EU(this.chart.getContext(),this,this._tooltipItems))}getTitle(e,n){let{callbacks:r}=n,i=r.beforeTitle.apply(this,[e]),o=r.title.apply(this,[e]),s=r.afterTitle.apply(this,[e]),c=[];return c=va(c,ls(i)),c=va(c,ls(o)),c=va(c,ls(s)),c}getBeforeBody(e,n){return Iw(n.callbacks.beforeBody.apply(this,[e]))}getBody(e,n){let{callbacks:r}=n,i=[];return tn(e,o=>{let s={before:[],lines:[],after:[]},c=kw(r,o);va(s.before,ls(c.beforeLabel.call(this,o))),va(s.lines,c.label.call(this,o)),va(s.after,ls(c.afterLabel.call(this,o))),i.push(s);}),i}getAfterBody(e,n){return Iw(n.callbacks.afterBody.apply(this,[e]))}getFooter(e,n){let{callbacks:r}=n,i=r.beforeFooter.apply(this,[e]),o=r.footer.apply(this,[e]),s=r.afterFooter.apply(this,[e]),c=[];return c=va(c,ls(i)),c=va(c,ls(o)),c=va(c,ls(s)),c}_createItems(e){let n=this._active,r=this.chart.data,i=[],o=[],s=[],c=[],p,h;for(p=0,h=n.length;p<h;++p)c.push(bU(this.chart,n[p]));return e.filter&&(c=c.filter((v,P,x)=>e.filter(v,P,x,r))),e.itemSort&&(c=c.sort((v,P)=>e.itemSort(v,P,r))),tn(c,v=>{let P=kw(e.callbacks,v);i.push(P.labelColor.call(this,v)),o.push(P.labelPointStyle.call(this,v)),s.push(P.labelTextColor.call(this,v));}),this.labelColors=i,this.labelPointStyles=o,this.labelTextColors=s,this.dataPoints=c,c}update(e,n){let r=this.options.setContext(this.getContext()),i=this._active,o,s=[];if(!i.length)this.opacity!==0&&(o={opacity:0});else {let c=Pf[r.position].call(this,i,this._eventPosition);s=this._createItems(r),this.title=this.getTitle(s,r),this.beforeBody=this.getBeforeBody(s,r),this.body=this.getBody(s,r),this.afterBody=this.getAfterBody(s,r),this.footer=this.getFooter(s,r);let p=this._size=_w(this,r),h=Object.assign({},c,p),v=Tw(this.chart,r,h),P=ww(r,h,v,this.chart);this.xAlign=v.xAlign,this.yAlign=v.yAlign,o={opacity:1,x:P.x,y:P.y,width:p.width,height:p.height,caretX:c.x,caretY:c.y};}this._tooltipItems=s,this.$context=void 0,o&&this._resolveAnimations().update(this,o),e&&r.external&&r.external.call(this,{chart:this.chart,tooltip:this,replay:n});}drawCaret(e,n,r,i){let o=this.getCaretPosition(e,r,i);n.lineTo(o.x1,o.y1),n.lineTo(o.x2,o.y2),n.lineTo(o.x3,o.y3);}getCaretPosition(e,n,r){let{xAlign:i,yAlign:o}=this,{caretSize:s,cornerRadius:c}=r,{topLeft:p,topRight:h,bottomLeft:v,bottomRight:P}=$o(c),{x,y:T}=e,{width:I,height:F}=n,A,O,N,V,G,X;return o==="center"?(G=T+F/2,i==="left"?(A=x,O=A-s,V=G+s,X=G-s):(A=x+I,O=A+s,V=G-s,X=G+s),N=A):(i==="left"?O=x+Math.max(p,v)+s:i==="right"?O=x+I-Math.max(h,P)-s:O=this.caretX,o==="top"?(V=T,G=V-s,A=O-s,N=O+s):(V=T+F,G=V+s,A=O+s,N=O-s),X=V),{x1:A,x2:O,x3:N,y1:V,y2:G,y3:X}}drawTitle(e,n,r){let i=this.title,o=i.length,s,c,p;if(o){let h=ml(r.rtl,this.x,this.width);for(e.x=sy(this,r.titleAlign,r),n.textAlign=h.textAlign(r.titleAlign),n.textBaseline="middle",s=Sn(r.titleFont),c=r.titleSpacing,n.fillStyle=r.titleColor,n.font=s.string,p=0;p<o;++p)n.fillText(i[p],h.x(e.x),e.y+s.lineHeight/2),e.y+=s.lineHeight+c,p+1===o&&(e.y+=r.titleMarginBottom-c);}}_drawColorBox(e,n,r,i,o){let s=this.labelColors[r],c=this.labelPointStyles[r],{boxHeight:p,boxWidth:h,boxPadding:v}=o,P=Sn(o.bodyFont),x=sy(this,"left",o),T=i.x(x),I=p<P.lineHeight?(P.lineHeight-p)/2:0,F=n.y+I;if(o.usePointStyle){let A={radius:Math.min(h,p)/2,pointStyle:c.pointStyle,rotation:c.rotation,borderWidth:1},O=i.leftForLtr(T,h)+h/2,N=F+p/2;e.strokeStyle=o.multiKeyBackground,e.fillStyle=o.multiKeyBackground,pf(e,A,O,N),e.strokeStyle=s.borderColor,e.fillStyle=s.backgroundColor,pf(e,A,O,N);}else {e.lineWidth=Te(s.borderWidth)?Math.max(...Object.values(s.borderWidth)):s.borderWidth||1,e.strokeStyle=s.borderColor,e.setLineDash(s.borderDash||[]),e.lineDashOffset=s.borderDashOffset||0;let A=i.leftForLtr(T,h-v),O=i.leftForLtr(i.xPlus(T,1),h-v-2),N=$o(s.borderRadius);Object.values(N).some(V=>V!==0)?(e.beginPath(),e.fillStyle=o.multiKeyBackground,os(e,{x:A,y:F,w:h,h:p,radius:N}),e.fill(),e.stroke(),e.fillStyle=s.backgroundColor,e.beginPath(),os(e,{x:O,y:F+1,w:h-2,h:p-2,radius:N}),e.fill()):(e.fillStyle=o.multiKeyBackground,e.fillRect(A,F,h,p),e.strokeRect(A,F,h,p),e.fillStyle=s.backgroundColor,e.fillRect(O,F+1,h-2,p-2));}e.fillStyle=this.labelTextColors[r];}drawBody(e,n,r){let{body:i}=this,{bodySpacing:o,bodyAlign:s,displayColors:c,boxHeight:p,boxWidth:h,boxPadding:v}=r,P=Sn(r.bodyFont),x=P.lineHeight,T=0,I=ml(r.rtl,this.x,this.width),F=function(U){n.fillText(U,I.x(e.x+T),e.y+x/2),e.y+=x+o;},A=I.textAlign(s),O,N,V,G,X,nt,st;for(n.textAlign=s,n.textBaseline="middle",n.font=P.string,e.x=sy(this,A,r),n.fillStyle=r.bodyColor,tn(this.beforeBody,F),T=c&&A!=="right"?s==="center"?h/2+v:h+2+v:0,G=0,nt=i.length;G<nt;++G){for(O=i[G],N=this.labelTextColors[G],n.fillStyle=N,tn(O.before,F),V=O.lines,c&&V.length&&(this._drawColorBox(n,e,G,I,r),x=Math.max(P.lineHeight,p)),X=0,st=V.length;X<st;++X)F(V[X]),x=P.lineHeight;tn(O.after,F);}T=0,x=P.lineHeight,tn(this.afterBody,F),e.y-=o;}drawFooter(e,n,r){let i=this.footer,o=i.length,s,c;if(o){let p=ml(r.rtl,this.x,this.width);for(e.x=sy(this,r.footerAlign,r),e.y+=r.footerMarginTop,n.textAlign=p.textAlign(r.footerAlign),n.textBaseline="middle",s=Sn(r.footerFont),n.fillStyle=r.footerColor,n.font=s.string,c=0;c<o;++c)n.fillText(i[c],p.x(e.x),e.y+s.lineHeight/2),e.y+=s.lineHeight+r.footerSpacing;}}drawBackground(e,n,r,i){let{xAlign:o,yAlign:s}=this,{x:c,y:p}=e,{width:h,height:v}=r,{topLeft:P,topRight:x,bottomLeft:T,bottomRight:I}=$o(i.cornerRadius);n.fillStyle=i.backgroundColor,n.strokeStyle=i.borderColor,n.lineWidth=i.borderWidth,n.beginPath(),n.moveTo(c+P,p),s==="top"&&this.drawCaret(e,n,r,i),n.lineTo(c+h-x,p),n.quadraticCurveTo(c+h,p,c+h,p+x),s==="center"&&o==="right"&&this.drawCaret(e,n,r,i),n.lineTo(c+h,p+v-I),n.quadraticCurveTo(c+h,p+v,c+h-I,p+v),s==="bottom"&&this.drawCaret(e,n,r,i),n.lineTo(c+T,p+v),n.quadraticCurveTo(c,p+v,c,p+v-T),s==="center"&&o==="left"&&this.drawCaret(e,n,r,i),n.lineTo(c,p+P),n.quadraticCurveTo(c,p,c+P,p),n.closePath(),n.fill(),i.borderWidth>0&&n.stroke();}_updateAnimationTarget(e){let n=this.chart,r=this.$animations,i=r&&r.x,o=r&&r.y;if(i||o){let s=Pf[e.position].call(this,this._active,this._eventPosition);if(!s)return;let c=this._size=_w(this,e),p=Object.assign({},s,this._size),h=Tw(n,e,p),v=ww(e,p,h,n);(i._to!==v.x||o._to!==v.y)&&(this.xAlign=h.xAlign,this.yAlign=h.yAlign,this.width=c.width,this.height=c.height,this.caretX=s.x,this.caretY=s.y,this._resolveAnimations().update(this,v));}}_willRender(){return !!this.opacity}draw(e){let n=this.options.setContext(this.getContext()),r=this.opacity;if(!r)return;this._updateAnimationTarget(n);let i={width:this.width,height:this.height},o={x:this.x,y:this.y};r=Math.abs(r)<.001?0:r;let s=$n(n.padding),c=this.title.length||this.beforeBody.length||this.body.length||this.afterBody.length||this.footer.length;n.enabled&&c&&(e.save(),e.globalAlpha=r,this.drawBackground(o,e,i,n),ty(e,n.textDirection),o.y+=s.top,this.drawTitle(o,e,n),this.drawBody(o,e,n),this.drawFooter(o,e,n),ey(e,n.textDirection),e.restore());}getActiveElements(){return this._active||[]}setActiveElements(e,n){let r=this._active,i=e.map(({datasetIndex:c,index:p})=>{let h=this.chart.getDatasetMeta(c);if(!h)throw new Error("Cannot find a dataset at index "+c);return {datasetIndex:c,element:h.data[p],index:p}}),o=!id(r,i),s=this._positionChanged(i,n);(o||s)&&(this._active=i,this._eventPosition=n,this._ignoreReplayEvents=true,this.update(true));}handleEvent(e,n,r=true){if(n&&this._ignoreReplayEvents)return false;this._ignoreReplayEvents=false;let i=this.options,o=this._active||[],s=this._getActiveElements(e,o,n,r),c=this._positionChanged(s,e),p=n||!id(s,o)||c;return p&&(this._active=s,(i.enabled||i.external)&&(this._eventPosition={x:e.x,y:e.y},this.update(true,n))),p}_getActiveElements(e,n,r,i){let o=this.options;if(e.type==="mouseout")return [];if(!i)return n;let s=this.chart.getElementsAtEventForMode(e,o.mode,o,r);return o.reverse&&s.reverse(),s}_positionChanged(e,n){let{caretX:r,caretY:i,options:o}=this,s=Pf[o.position].call(this,e,n);return s!==false&&(r!==s.x||i!==s.y)}};Af.positioners=Pf;var rI={id:"tooltip",_element:Af,positioners:Pf,afterInit(t,e,n){n&&(t.tooltip=new Af({chart:t,options:n}));},beforeUpdate(t,e,n){t.tooltip&&t.tooltip.initialize(n);},reset(t,e,n){t.tooltip&&t.tooltip.initialize(n);},afterDraw(t){let e=t.tooltip;if(e&&e._willRender()){let n={tooltip:e};if(t.notifyPlugins("beforeTooltipDraw",n)===false)return;e.draw(t.ctx),t.notifyPlugins("afterTooltipDraw",n);}},afterEvent(t,e){if(t.tooltip){let n=e.replay;t.tooltip.handleEvent(e.event,n,e.inChartArea)&&(e.changed=true);}},defaults:{enabled:true,external:null,position:"average",backgroundColor:"rgba(0,0,0,0.8)",titleColor:"#fff",titleFont:{weight:"bold"},titleSpacing:2,titleMarginBottom:6,titleAlign:"left",bodyColor:"#fff",bodySpacing:2,bodyFont:{},bodyAlign:"left",footerColor:"#fff",footerSpacing:2,footerMarginTop:6,footerFont:{weight:"bold"},footerAlign:"left",padding:6,caretPadding:2,caretSize:5,cornerRadius:6,boxHeight:(t,e)=>e.bodyFont.size,boxWidth:(t,e)=>e.bodyFont.size,multiKeyBackground:"#fff",displayColors:true,boxPadding:0,borderColor:"rgba(0,0,0,0)",borderWidth:0,animation:{duration:400,easing:"easeOutQuart"},animations:{numbers:{type:"number",properties:["x","y","width","height","caretX","caretY"]},opacity:{easing:"linear",duration:200}},callbacks:{beforeTitle:Bo,title(t){if(t.length>0){let e=t[0],n=e.chart.data.labels,r=n?n.length:0;if(this&&this.options&&this.options.mode==="dataset")return e.dataset.label||"";if(e.label)return e.label;if(r>0&&e.dataIndex<r)return n[e.dataIndex]}return ""},afterTitle:Bo,beforeBody:Bo,beforeLabel:Bo,label(t){if(this&&this.options&&this.options.mode==="dataset")return t.label+": "+t.formattedValue||t.formattedValue;let e=t.dataset.label||"";e&&(e+=": ");let n=t.formattedValue;return Le(n)||(e+=n),e},labelColor(t){let n=t.chart.getDatasetMeta(t.datasetIndex).controller.getStyle(t.dataIndex);return {borderColor:n.borderColor,backgroundColor:n.backgroundColor,borderWidth:n.borderWidth,borderDash:n.borderDash,borderDashOffset:n.borderDashOffset,borderRadius:0}},labelTextColor(){return this.options.bodyColor},labelPointStyle(t){let n=t.chart.getDatasetMeta(t.datasetIndex).controller.getStyle(t.dataIndex);return {pointStyle:n.pointStyle,rotation:n.rotation}},afterLabel:Bo,afterBody:Bo,beforeFooter:Bo,footer:Bo,afterFooter:Bo}},defaultRoutes:{bodyFont:"font",footerFont:"font",titleFont:"font"},descriptors:{_scriptable:t=>t!=="filter"&&t!=="itemSort"&&t!=="external",_indexable:false,callbacks:{_scriptable:false,_indexable:false},animation:{_fallback:false},animations:{_fallback:"animation"}},additionalOptionScopes:["interaction"]};var _U=(t,e,n,r)=>(typeof e=="string"?(n=t.push(e)-1,r.unshift({index:n,label:e})):isNaN(e)&&(n=null),n);function TU(t,e,n,r){let i=t.indexOf(e);if(i===-1)return _U(t,e,n,r);let o=t.lastIndexOf(e);return i!==o?n:i}var wU=(t,e)=>t===null?null:Nr(Math.round(t),0,e),Rc=class extends Oc{constructor(e){super(e),this._startValue=void 0,this._valueRange=0,this._addedLabels=[];}init(e){let n=this._addedLabels;if(n.length){let r=this.getLabels();for(let{index:i,label:o}of n)r[i]===o&&r.splice(i,1);this._addedLabels=[];}super.init(e);}parse(e,n){if(Le(e))return null;let r=this.getLabels();return n=isFinite(n)&&r[n]===e?n:TU(r,e,me(n,e),this._addedLabels),wU(n,r.length-1)}determineDataLimits(){let{minDefined:e,maxDefined:n}=this.getUserBounds(),{min:r,max:i}=this.getMinMax(true);this.options.bounds==="ticks"&&(e||(r=0),n||(i=this.getLabels().length-1)),this.min=r,this.max=i;}buildTicks(){let e=this.min,n=this.max,r=this.options.offset,i=[],o=this.getLabels();o=e===0&&n===o.length-1?o:o.slice(e,n+1),this._valueRange=Math.max(o.length-(r?0:1),1),this._startValue=this.min-(r?.5:0);for(let s=e;s<=n;s++)i.push({value:s});return i}getLabelForValue(e){let n=this.getLabels();return e>=0&&e<n.length?n[e]:e}configure(){super.configure(),this.isHorizontal()||(this._reversePixels=!this._reversePixels);}getPixelForValue(e){return typeof e!="number"&&(e=this.parse(e)),e===null?NaN:this.getPixelForDecimal((e-this._startValue)/this._valueRange)}getPixelForTick(e){let n=this.ticks;return e<0||e>n.length-1?null:this.getPixelForValue(n[e].value)}getValueForPixel(e){return Math.round(this._startValue+this.getDecimalForPixel(e)*this._valueRange)}getBasePixel(){return this.bottom}};Rc.id="category";Rc.defaults={ticks:{callback:Rc.prototype.getLabelForValue}};function IU(t,e){let n=[],{bounds:i,step:o,min:s,max:c,precision:p,count:h,maxTicks:v,maxDigits:P,includeBounds:x}=t,T=o||1,I=v-1,{min:F,max:A}=e,O=!Le(s),N=!Le(c),V=!Le(h),G=(A-F)/(P+1),X=Fg((A-F)/I/T)*T,nt,st,U,j;if(X<1e-14&&!O&&!N)return [{value:F},{value:A}];j=Math.ceil(A/X)-Math.floor(F/X),j>I&&(X=Fg(j*X/I/T)*T),Le(p)||(nt=Math.pow(10,p),X=Math.ceil(X*nt)/nt),i==="ticks"?(st=Math.floor(F/X)*X,U=Math.ceil(A/X)*X):(st=F,U=A),O&&N&&o&&g0((c-s)/o,X/1e3)?(j=Math.round(Math.min((c-s)/X,v)),X=(c-s)/j,st=s,U=c):V?(st=O?s:st,U=N?c:U,j=h-1,X=(U-st)/j):(j=(U-st)/X,_c(j,Math.round(j),X/1e3)?j=Math.round(j):j=Math.ceil(j));let ut=Math.max(Ng(X),Ng(st));nt=Math.pow(10,Le(p)?ut:p),st=Math.round(st*nt)/nt,U=Math.round(U*nt)/nt;let Y=0;for(O&&(x&&st!==s?(n.push({value:s}),st<s&&Y++,_c(Math.round((st+Y*X)*nt)/nt,s,Dw(s,G,t))&&Y++):st<s&&Y++);Y<j;++Y)n.push({value:Math.round((st+Y*X)*nt)/nt});return N&&x&&U!==c?n.length&&_c(n[n.length-1].value,c,Dw(c,G,t))?n[n.length-1].value=c:n.push({value:c}):(!N||U===c)&&n.push({value:U}),n}function Dw(t,e,{horizontal:n,minRotation:r}){let i=Qn(r),o=(n?Math.sin(i):Math.cos(i))||.001,s=.75*e*(""+t).length;return Math.min(e/o,s)}var ld=class extends Oc{constructor(e){super(e),this.start=void 0,this.end=void 0,this._startValue=void 0,this._endValue=void 0,this._valueRange=0;}parse(e,n){return Le(e)||(typeof e=="number"||e instanceof Number)&&!isFinite(+e)?null:+e}handleTickRangeOptions(){let{beginAtZero:e}=this.options,{minDefined:n,maxDefined:r}=this.getUserBounds(),{min:i,max:o}=this,s=p=>i=n?i:p,c=p=>o=r?o:p;if(e){let p=go(i),h=go(o);p<0&&h<0?c(0):p>0&&h>0&&s(0);}if(i===o){let p=1;(o>=Number.MAX_SAFE_INTEGER||i<=Number.MIN_SAFE_INTEGER)&&(p=Math.abs(o*.05)),c(o+p),e||s(i-p);}this.min=i,this.max=o;}getTickLimit(){let e=this.options.ticks,{maxTicksLimit:n,stepSize:r}=e,i;return r?(i=Math.ceil(this.max/r)-Math.floor(this.min/r)+1,i>1e3&&(console.warn(`scales.${this.id}.ticks.stepSize: ${r} would result generating up to ${i} ticks. Limiting to 1000.`),i=1e3)):(i=this.computeTickLimit(),n=n||11),n&&(i=Math.min(n,i)),i}computeTickLimit(){return Number.POSITIVE_INFINITY}buildTicks(){let e=this.options,n=e.ticks,r=this.getTickLimit();r=Math.max(2,r);let i={maxTicks:r,bounds:e.bounds,min:e.min,max:e.max,precision:n.precision,step:n.stepSize,count:n.count,maxDigits:this._maxDigits(),horizontal:this.isHorizontal(),minRotation:n.minRotation||0,includeBounds:n.includeBounds!==false},o=this._range||this,s=IU(i,o);return e.bounds==="ticks"&&Mg(s,this,"value"),e.reverse?(s.reverse(),this.start=this.max,this.end=this.min):(this.start=this.min,this.end=this.max),s}configure(){let e=this.ticks,n=this.min,r=this.max;if(super.configure(),this.options.offset&&e.length){let i=(r-n)/Math.max(e.length-1,1)/2;n-=i,r+=i;}this._startValue=n,this._endValue=r,this._valueRange=r-n;}getLabelForValue(e){return kc(e,this.chart.options.locale,this.options.ticks.format)}},cd=class extends ld{determineDataLimits(){let{min:e,max:n}=this.getMinMax(true);this.min=Mn(e)?e:0,this.max=Mn(n)?n:1,this.handleTickRangeOptions();}computeTickLimit(){let e=this.isHorizontal(),n=e?this.width:this.height,r=Qn(this.options.ticks.minRotation),i=(e?Math.sin(r):Math.cos(r))||.001,o=this._resolveTickFontOptions(0);return Math.ceil(n/Math.min(40,o.lineHeight/i))}getPixelForValue(e){return e===null?NaN:this.getPixelForDecimal((e-this._startValue)/this._valueRange)}getValueForPixel(e){return this._startValue+this.getDecimalForPixel(e)*this._valueRange}};cd.id="linear";cd.defaults={ticks:{callback:vy.formatters.numeric}};function Aw(t){return t/Math.pow(10,Math.floor(Ei(t)))===1}function kU(t,e){let n=Math.floor(Ei(e.max)),r=Math.ceil(e.max/Math.pow(10,n)),i=[],o=xi(t.min,Math.pow(10,Math.floor(Ei(e.min)))),s=Math.floor(Ei(o)),c=Math.floor(o/Math.pow(10,s)),p=s<0?Math.pow(10,Math.abs(s)):1;do i.push({value:o,major:Aw(o)}),++c,c===10&&(c=1,++s,p=s>=0?1:p),o=Math.round(c*Math.pow(10,s)*p)/p;while(s<n||s===n&&c<r);let h=xi(t.max,o);return i.push({value:h,major:Aw(o)}),i}var yy=class extends Oc{constructor(e){super(e),this.start=void 0,this.end=void 0,this._startValue=void 0,this._valueRange=0;}parse(e,n){let r=ld.prototype.parse.apply(this,[e,n]);if(r===0){this._zero=true;return}return Mn(r)&&r>0?r:null}determineDataLimits(){let{min:e,max:n}=this.getMinMax(true);this.min=Mn(e)?Math.max(0,e):null,this.max=Mn(n)?Math.max(0,n):null,this.options.beginAtZero&&(this._zero=true),this.handleTickRangeOptions();}handleTickRangeOptions(){let{minDefined:e,maxDefined:n}=this.getUserBounds(),r=this.min,i=this.max,o=p=>r=e?r:p,s=p=>i=n?i:p,c=(p,h)=>Math.pow(10,Math.floor(Ei(p))+h);r===i&&(r<=0?(o(1),s(10)):(o(c(r,-1)),s(c(i,1)))),r<=0&&o(c(i,-1)),i<=0&&s(c(r,1)),this._zero&&this.min!==this._suggestedMin&&r===c(this.min,0)&&o(c(r,-1)),this.min=r,this.max=i;}buildTicks(){let e=this.options,n={min:this._userMin,max:this._userMax},r=kU(n,this);return e.bounds==="ticks"&&Mg(r,this,"value"),e.reverse?(r.reverse(),this.start=this.max,this.end=this.min):(this.start=this.min,this.end=this.max),r}getLabelForValue(e){return e===void 0?"0":kc(e,this.chart.options.locale,this.options.ticks.format)}configure(){let e=this.min;super.configure(),this._startValue=Ei(e),this._valueRange=Ei(this.max)-Ei(e);}getPixelForValue(e){return (e===void 0||e===0)&&(e=this.min),e===null||isNaN(e)?NaN:this.getPixelForDecimal(e===this.min?0:(Ei(e)-this._startValue)/this._valueRange)}getValueForPixel(e){let n=this.getDecimalForPixel(e);return Math.pow(10,this._startValue+n*this._valueRange)}};yy.id="logarithmic";yy.defaults={ticks:{callback:vy.formatters.logarithmic,major:{enabled:true}}};function a1(t){let e=t.ticks;if(e.display&&t.display){let n=$n(e.backdropPadding);return me(e.font&&e.font.size,ke.font.size)+n.height}return 0}function DU(t,e,n){return n=He(n)?n:[n],{w:w0(t,e.string,n),h:n.length*e.lineHeight}}function Ow(t,e,n,r,i){return t===r||t===i?{start:e-n/2,end:e+n/2}:t<r||t>i?{start:e-n,end:e}:{start:e,end:e+n}}function AU(t){let e={l:t.left+t._padding.left,r:t.right-t._padding.right,t:t.top+t._padding.top,b:t.bottom-t._padding.bottom},n=Object.assign({},e),r=[],i=[],o=t._pointLabels.length,s=t.options.pointLabels,c=s.centerPointLabels?Be/o:0;for(let p=0;p<o;p++){let h=s.setContext(t.getPointLabelContext(p));i[p]=h.padding;let v=t.getPointPosition(p,t.drawingArea+i[p],c),P=Sn(h.font),x=DU(t.ctx,P,t._pointLabels[p]);r[p]=x;let T=ai(t.getIndexAngle(p)+c),I=Math.round(Tc(T)),F=Ow(I,v.x,x.w,0,180),A=Ow(I,v.y,x.h,90,270);OU(n,e,T,F,A);}t.setCenterPoint(e.l-n.l,n.r-e.r,e.t-n.t,n.b-e.b),t._pointLabelItems=RU(t,r,i);}function OU(t,e,n,r,i){let o=Math.abs(Math.sin(n)),s=Math.abs(Math.cos(n)),c=0,p=0;r.start<e.l?(c=(e.l-r.start)/o,t.l=Math.min(t.l,e.l-c)):r.end>e.r&&(c=(r.end-e.r)/o,t.r=Math.max(t.r,e.r+c)),i.start<e.t?(p=(e.t-i.start)/s,t.t=Math.min(t.t,e.t-p)):i.end>e.b&&(p=(i.end-e.b)/s,t.b=Math.max(t.b,e.b+p));}function RU(t,e,n){let r=[],i=t._pointLabels.length,o=t.options,s=a1(o)/2,c=t.drawingArea,p=o.pointLabels.centerPointLabels?Be/i:0;for(let h=0;h<i;h++){let v=t.getPointPosition(h,c+s+n[h],p),P=Math.round(Tc(ai(v.angle+bn))),x=e[h],T=NU(v.y,x.h,P),I=FU(P),F=MU(v.x,x.w,I);r.push({x:v.x,y:T,textAlign:I,left:F,top:T,right:F+x.w,bottom:T+x.h});}return r}function FU(t){return t===0||t===180?"center":t<180?"left":"right"}function MU(t,e,n){return n==="right"?t-=e:n==="center"&&(t-=e/2),t}function NU(t,e,n){return n===90||n===270?t-=e/2:(n>270||n<90)&&(t-=e),t}function LU(t,e){let{ctx:n,options:{pointLabels:r}}=t;for(let i=e-1;i>=0;i--){let o=r.setContext(t.getPointLabelContext(i)),s=Sn(o.font),{x:c,y:p,textAlign:h,left:v,top:P,right:x,bottom:T}=t._pointLabelItems[i],{backdropColor:I}=o;if(!Le(I)){let F=$o(o.borderRadius),A=$n(o.backdropPadding);n.fillStyle=I;let O=v-A.left,N=P-A.top,V=x-v+A.width,G=T-P+A.height;Object.values(F).some(X=>X!==0)?(n.beginPath(),os(n,{x:O,y:N,w:V,h:G,radius:F}),n.fill()):n.fillRect(O,N,V,G);}is(n,t._pointLabels[i],c,p+s.lineHeight/2,s,{color:o.color,textAlign:h,textBaseline:"middle"});}}function iI(t,e,n,r){let{ctx:i}=t;if(n)i.arc(t.xCenter,t.yCenter,e,0,rn);else {let o=t.getPointPosition(0,e);i.moveTo(o.x,o.y);for(let s=1;s<r;s++)o=t.getPointPosition(s,e),i.lineTo(o.x,o.y);}}function BU(t,e,n,r){let i=t.ctx,o=e.circular,{color:s,lineWidth:c}=e;!o&&!r||!s||!c||n<0||(i.save(),i.strokeStyle=s,i.lineWidth=c,i.setLineDash(e.borderDash),i.lineDashOffset=e.borderDashOffset,i.beginPath(),iI(t,n,o,r),i.closePath(),i.stroke(),i.restore());}function UU(t,e,n){return ba(t,{label:n,index:e,type:"pointLabel"})}var ud=class extends ld{constructor(e){super(e),this.xCenter=void 0,this.yCenter=void 0,this.drawingArea=void 0,this._pointLabels=[],this._pointLabelItems=[];}setDimensions(){let e=this._padding=$n(a1(this.options)/2),n=this.width=this.maxWidth-e.width,r=this.height=this.maxHeight-e.height;this.xCenter=Math.floor(this.left+n/2+e.left),this.yCenter=Math.floor(this.top+r/2+e.top),this.drawingArea=Math.floor(Math.min(n,r)/2);}determineDataLimits(){let{min:e,max:n}=this.getMinMax(false);this.min=Mn(e)&&!isNaN(e)?e:0,this.max=Mn(n)&&!isNaN(n)?n:0,this.handleTickRangeOptions();}computeTickLimit(){return Math.ceil(this.drawingArea/a1(this.options))}generateTickLabels(e){ld.prototype.generateTickLabels.call(this,e),this._pointLabels=this.getLabels().map((n,r)=>{let i=Qe(this.options.pointLabels.callback,[n,r],this);return i||i===0?i:""}).filter((n,r)=>this.chart.getDataVisibility(r));}fit(){let e=this.options;e.display&&e.pointLabels.display?AU(this):this.setCenterPoint(0,0,0,0);}setCenterPoint(e,n,r,i){this.xCenter+=Math.floor((e-n)/2),this.yCenter+=Math.floor((r-i)/2),this.drawingArea-=Math.min(this.drawingArea/2,Math.max(e,n,r,i));}getIndexAngle(e){let n=rn/(this._pointLabels.length||1),r=this.options.startAngle||0;return ai(e*n+Qn(r))}getDistanceFromCenterForValue(e){if(Le(e))return NaN;let n=this.drawingArea/(this.max-this.min);return this.options.reverse?(this.max-e)*n:(e-this.min)*n}getValueForDistanceFromCenter(e){if(Le(e))return NaN;let n=e/(this.drawingArea/(this.max-this.min));return this.options.reverse?this.max-n:this.min+n}getPointLabelContext(e){let n=this._pointLabels||[];if(e>=0&&e<n.length){let r=n[e];return UU(this.getContext(),e,r)}}getPointPosition(e,n,r=0){let i=this.getIndexAngle(e)-bn+r;return {x:Math.cos(i)*n+this.xCenter,y:Math.sin(i)*n+this.yCenter,angle:i}}getPointPositionForValue(e,n){return this.getPointPosition(e,this.getDistanceFromCenterForValue(n))}getBasePosition(e){return this.getPointPositionForValue(e||0,this.getBaseValue())}getPointLabelPosition(e){let{left:n,top:r,right:i,bottom:o}=this._pointLabelItems[e];return {left:n,top:r,right:i,bottom:o}}drawBackground(){let{backgroundColor:e,grid:{circular:n}}=this.options;if(e){let r=this.ctx;r.save(),r.beginPath(),iI(this,this.getDistanceFromCenterForValue(this._endValue),n,this._pointLabels.length),r.closePath(),r.fillStyle=e,r.fill(),r.restore();}}drawGrid(){let e=this.ctx,n=this.options,{angleLines:r,grid:i}=n,o=this._pointLabels.length,s,c,p;if(n.pointLabels.display&&LU(this,o),i.display&&this.ticks.forEach((h,v)=>{if(v!==0){c=this.getDistanceFromCenterForValue(h.value);let P=i.setContext(this.getContext(v-1));BU(this,P,c,o);}}),r.display){for(e.save(),s=o-1;s>=0;s--){let h=r.setContext(this.getPointLabelContext(s)),{color:v,lineWidth:P}=h;!P||!v||(e.lineWidth=P,e.strokeStyle=v,e.setLineDash(h.borderDash),e.lineDashOffset=h.borderDashOffset,c=this.getDistanceFromCenterForValue(n.ticks.reverse?this.min:this.max),p=this.getPointPosition(s,c),e.beginPath(),e.moveTo(this.xCenter,this.yCenter),e.lineTo(p.x,p.y),e.stroke());}e.restore();}}drawBorder(){}drawLabels(){let e=this.ctx,n=this.options,r=n.ticks;if(!r.display)return;let i=this.getIndexAngle(0),o,s;e.save(),e.translate(this.xCenter,this.yCenter),e.rotate(i),e.textAlign="center",e.textBaseline="middle",this.ticks.forEach((c,p)=>{if(p===0&&!n.reverse)return;let h=r.setContext(this.getContext(p)),v=Sn(h.font);if(o=this.getDistanceFromCenterForValue(this.ticks[p].value),h.showLabelBackdrop){e.font=v.string,s=e.measureText(c.label).width,e.fillStyle=h.backdropColor;let P=$n(h.backdropPadding);e.fillRect(-s/2-P.left,-o-v.size/2-P.top,s+P.width,v.size+P.height);}is(e,c.label,0,-o,v,{color:h.color});}),e.restore();}drawTitle(){}};ud.id="radialLinear";ud.defaults={display:true,animate:true,position:"chartArea",angleLines:{display:true,lineWidth:1,borderDash:[],borderDashOffset:0},grid:{circular:false},startAngle:0,ticks:{showLabelBackdrop:true,callback:vy.formatters.numeric},pointLabels:{backdropColor:void 0,backdropPadding:2,display:true,font:{size:10},callback(t){return t},padding:5,centerPointLabels:false}};ud.defaultRoutes={"angleLines.color":"borderColor","pointLabels.color":"color","ticks.color":"color"};ud.descriptors={angleLines:{_fallback:"grid"}};var Cy={millisecond:{common:true,size:1,steps:1e3},second:{common:true,size:1e3,steps:60},minute:{common:true,size:6e4,steps:60},hour:{common:true,size:36e5,steps:24},day:{common:true,size:864e5,steps:30},week:{common:false,size:6048e5,steps:4},month:{common:true,size:2628e6,steps:12},quarter:{common:false,size:7884e6,steps:4},year:{common:true,size:3154e7}},_i=Object.keys(Cy);function $U(t,e){return t-e}function Rw(t,e){if(Le(e))return null;let n=t._adapter,{parser:r,round:i,isoWeekday:o}=t._parseOpts,s=e;return typeof r=="function"&&(s=r(s)),Mn(s)||(s=typeof r=="string"?n.parse(s,r):n.parse(s)),s===null?null:(i&&(s=i==="week"&&(Vi(o)||o===true)?n.startOf(s,"isoWeek",o):n.startOf(s,i)),+s)}function Fw(t,e,n,r){let i=_i.length;for(let o=_i.indexOf(t);o<i-1;++o){let s=Cy[_i[o]],c=s.steps?s.steps:Number.MAX_SAFE_INTEGER;if(s.common&&Math.ceil((n-e)/(c*s.size))<=r)return _i[o]}return _i[i-1]}function GU(t,e,n,r,i){for(let o=_i.length-1;o>=_i.indexOf(n);o--){let s=_i[o];if(Cy[s].common&&t._adapter.diff(i,r,s)>=e-1)return s}return _i[n?_i.indexOf(n):0]}function jU(t){for(let e=_i.indexOf(t)+1,n=_i.length;e<n;++e)if(Cy[_i[e]].common)return _i[e]}function Mw(t,e,n){if(!n)t[e]=true;else if(n.length){let{lo:r,hi:i}=cf(n,e),o=n[r]>=e?n[r]:n[i];t[o]=true;}}function VU(t,e,n,r){let i=t._adapter,o=+i.startOf(e[0].value,r),s=e[e.length-1].value,c,p;for(c=o;c<=s;c=+i.add(c,1,r))p=n[c],p>=0&&(e[p].major=true);return e}function Nw(t,e,n){let r=[],i={},o=e.length,s,c;for(s=0;s<o;++s)c=e[s],i[c]=s,r.push({value:c,major:false});return o===0||!n?r:VU(t,r,i,n)}var dd=class extends Oc{constructor(e){super(e),this._cache={data:[],labels:[],all:[]},this._unit="day",this._majorUnit=void 0,this._offsets={},this._normalized=false,this._parseOpts=void 0;}init(e,n){let r=e.time||(e.time={}),i=this._adapter=new z6._date(e.adapters.date);i.init(n),Ec(r.displayFormats,i.formats()),this._parseOpts={parser:r.parser,round:r.round,isoWeekday:r.isoWeekday},super.init(e),this._normalized=n.normalized;}parse(e,n){return e===void 0?null:Rw(this,e)}beforeLayout(){super.beforeLayout(),this._cache={data:[],labels:[],all:[]};}determineDataLimits(){let e=this.options,n=this._adapter,r=e.time.unit||"day",{min:i,max:o,minDefined:s,maxDefined:c}=this.getUserBounds();function p(h){!s&&!isNaN(h.min)&&(i=Math.min(i,h.min)),!c&&!isNaN(h.max)&&(o=Math.max(o,h.max));}(!s||!c)&&(p(this._getLabelBounds()),(e.bounds!=="ticks"||e.ticks.source!=="labels")&&p(this.getMinMax(false))),i=Mn(i)&&!isNaN(i)?i:+n.startOf(Date.now(),r),o=Mn(o)&&!isNaN(o)?o:+n.endOf(Date.now(),r)+1,this.min=Math.min(i,o-1),this.max=Math.max(i+1,o);}_getLabelBounds(){let e=this.getLabelTimestamps(),n=Number.POSITIVE_INFINITY,r=Number.NEGATIVE_INFINITY;return e.length&&(n=e[0],r=e[e.length-1]),{min:n,max:r}}buildTicks(){let e=this.options,n=e.time,r=e.ticks,i=r.source==="labels"?this.getLabelTimestamps():this._generate();e.bounds==="ticks"&&i.length&&(this.min=this._userMin||i[0],this.max=this._userMax||i[i.length-1]);let o=this.min,s=this.max,c=v0(i,o,s);return this._unit=n.unit||(r.autoSkip?Fw(n.minUnit,this.min,this.max,this._getLabelCapacity(o)):GU(this,c.length,n.minUnit,this.min,this.max)),this._majorUnit=!r.major.enabled||this._unit==="year"?void 0:jU(this._unit),this.initOffsets(i),e.reverse&&c.reverse(),Nw(this,c,this._majorUnit)}afterAutoSkip(){this.options.offsetAfterAutoskip&&this.initOffsets(this.ticks.map(e=>+e.value));}initOffsets(e){let n=0,r=0,i,o;this.options.offset&&e.length&&(i=this.getDecimalForValue(e[0]),e.length===1?n=1-i:n=(this.getDecimalForValue(e[1])-i)/2,o=this.getDecimalForValue(e[e.length-1]),e.length===1?r=o:r=(o-this.getDecimalForValue(e[e.length-2]))/2);let s=e.length<3?.5:.25;n=Nr(n,0,s),r=Nr(r,0,s),this._offsets={start:n,end:r,factor:1/(n+1+r)};}_generate(){let e=this._adapter,n=this.min,r=this.max,i=this.options,o=i.time,s=o.unit||Fw(o.minUnit,n,r,this._getLabelCapacity(n)),c=me(o.stepSize,1),p=s==="week"?o.isoWeekday:false,h=Vi(p)||p===true,v={},P=n,x,T;if(h&&(P=+e.startOf(P,"isoWeek",p)),P=+e.startOf(P,h?"day":s),e.diff(r,n,s)>1e5*c)throw new Error(n+" and "+r+" are too far apart with stepSize of "+c+" "+s);let I=i.ticks.source==="data"&&this.getDataTimestamps();for(x=P,T=0;x<r;x=+e.add(x,c,s),T++)Mw(v,x,I);return (x===r||i.bounds==="ticks"||T===1)&&Mw(v,x,I),Object.keys(v).sort((F,A)=>F-A).map(F=>+F)}getLabelForValue(e){let n=this._adapter,r=this.options.time;return r.tooltipFormat?n.format(e,r.tooltipFormat):n.format(e,r.displayFormats.datetime)}_tickFormatFunction(e,n,r,i){let o=this.options,s=o.time.displayFormats,c=this._unit,p=this._majorUnit,h=c&&s[c],v=p&&s[p],P=r[n],x=p&&v&&P&&P.major,T=this._adapter.format(e,i||(x?v:h)),I=o.ticks.callback;return I?Qe(I,[T,n,r],this):T}generateTickLabels(e){let n,r,i;for(n=0,r=e.length;n<r;++n)i=e[n],i.label=this._tickFormatFunction(i.value,n,e);}getDecimalForValue(e){return e===null?NaN:(e-this.min)/(this.max-this.min)}getPixelForValue(e){let n=this._offsets,r=this.getDecimalForValue(e);return this.getPixelForDecimal((n.start+r)*n.factor)}getValueForPixel(e){let n=this._offsets,r=this.getDecimalForPixel(e)/n.factor-n.end;return this.min+r*(this.max-this.min)}_getLabelSize(e){let n=this.options.ticks,r=this.ctx.measureText(e).width,i=Qn(this.isHorizontal()?n.maxRotation:n.minRotation),o=Math.cos(i),s=Math.sin(i),c=this._resolveTickFontOptions(0).size;return {w:r*o+c*s,h:r*s+c*o}}_getLabelCapacity(e){let n=this.options.time,r=n.displayFormats,i=r[n.unit]||r.millisecond,o=this._tickFormatFunction(e,0,Nw(this,[e],this._majorUnit),i),s=this._getLabelSize(o),c=Math.floor(this.isHorizontal()?this.width/s.w:this.height/s.h)-1;return c>0?c:1}getDataTimestamps(){let e=this._cache.data||[],n,r;if(e.length)return e;let i=this.getMatchingVisibleMetas();if(this._normalized&&i.length)return this._cache.data=i[0].controller.getAllParsedValues(this);for(n=0,r=i.length;n<r;++n)e=e.concat(i[n].controller.getAllParsedValues(this));return this._cache.data=this.normalize(e)}getLabelTimestamps(){let e=this._cache.labels||[],n,r;if(e.length)return e;let i=this.getLabels();for(n=0,r=i.length;n<r;++n)e.push(Rw(this,i[n]));return this._cache.labels=this._normalized?e:this.normalize(e)}normalize(e){return Ug(e.sort($U))}};dd.id="time";dd.defaults={bounds:"data",adapters:{},time:{parser:false,unit:false,round:false,isoWeekday:false,minUnit:"millisecond",displayFormats:{}},ticks:{source:"auto",major:{enabled:false}}};function ly(t,e,n){let r=0,i=t.length-1,o,s,c,p;n?(e>=t[r].pos&&e<=t[i].pos&&({lo:r,hi:i}=es(t,"pos",e)),{pos:o,time:c}=t[r],{pos:s,time:p}=t[i]):(e>=t[r].time&&e<=t[i].time&&({lo:r,hi:i}=es(t,"time",e)),{time:o,pos:c}=t[r],{time:s,pos:p}=t[i]);let h=s-o;return h?c+(p-c)*(e-o)/h:c}var by=class extends dd{constructor(e){super(e),this._table=[],this._minPos=void 0,this._tableRange=void 0;}initOffsets(){let e=this._getTimestampsForTable(),n=this._table=this.buildLookupTable(e);this._minPos=ly(n,this.min),this._tableRange=ly(n,this.max)-this._minPos,super.initOffsets(e);}buildLookupTable(e){let{min:n,max:r}=this,i=[],o=[],s,c,p,h,v;for(s=0,c=e.length;s<c;++s)h=e[s],h>=n&&h<=r&&i.push(h);if(i.length<2)return [{time:n,pos:0},{time:r,pos:1}];for(s=0,c=i.length;s<c;++s)v=i[s+1],p=i[s-1],h=i[s],Math.round((v+p)/2)!==h&&o.push({time:h,pos:s/(c-1)});return o}_getTimestampsForTable(){let e=this._cache.all||[];if(e.length)return e;let n=this.getDataTimestamps(),r=this.getLabelTimestamps();return n.length&&r.length?e=this.normalize(n.concat(r)):e=n.length?n:r,e=this._cache.all=e,e}getDecimalForValue(e){return (ly(this._table,e)-this._minPos)/this._tableRange}getValueForPixel(e){let n=this._offsets,r=this.getDecimalForPixel(e)/n.factor-n.end;return ly(this._table,r*this._tableRange+this._minPos,true)}};by.id="timeseries";by.defaults=dd.defaults;var oI=(function(){if(typeof window!="undefined"){if(window.devicePixelRatio)return window.devicePixelRatio;var t=window.screen;if(t)return (t.deviceXDPI||1)/(t.logicalXDPI||1)}return 1})(),Ff={toTextLines:function(t){var e=[],n;for(t=[].concat(t);t.length;)n=t.pop(),typeof n=="string"?e.unshift.apply(e,n.split(`
5649
- `)):Array.isArray(n)?t.push.apply(t,n):Le(t)||e.unshift(""+n);return e},textSize:function(t,e,n){var r=[].concat(e),i=r.length,o=t.font,s=0,c;for(t.font=n.string,c=0;c<i;++c)s=Math.max(t.measureText(r[c]).width,s);return t.font=o,{height:i*n.lineHeight,width:s}},bound:function(t,e,n){return Math.max(t,Math.min(e,n))},arrayDiff:function(t,e){var n=t.slice(),r=[],i,o,s,c;for(i=0,s=e.length;i<s;++i)c=e[i],o=n.indexOf(c),o===-1?r.push([c,1]):n.splice(o,1);for(i=0,s=n.length;i<s;++i)r.push([n[i],-1]);return r},rasterize:function(t){return Math.round(t*oI)/oI}};function l1(t,e){var n=e.x,r=e.y;if(n===null)return {x:0,y:-1};if(r===null)return {x:1,y:0};var i=t.x-n,o=t.y-r,s=Math.sqrt(i*i+o*o);return {x:s?i/s:0,y:s?o/s:-1}}function zU(t,e,n,r,i){switch(i){case "center":n=r=0;break;case "bottom":n=0,r=1;break;case "right":n=1,r=0;break;case "left":n=-1,r=0;break;case "top":n=0,r=-1;break;case "start":n=-n,r=-r;break;case "end":break;default:i*=Math.PI/180,n=Math.cos(i),r=Math.sin(i);break}return {x:t,y:e,vx:n,vy:r}}var HU=0,sI=1,lI=2,cI=4,uI=8;function Sy(t,e,n){var r=HU;return t<n.left?r|=sI:t>n.right&&(r|=lI),e<n.top?r|=uI:e>n.bottom&&(r|=cI),r}function WU(t,e){for(var n=t.x0,r=t.y0,i=t.x1,o=t.y1,s=Sy(n,r,e),c=Sy(i,o,e),p,h,v;!(!(s|c)||s&c);)p=s||c,p&uI?(h=n+(i-n)*(e.top-r)/(o-r),v=e.top):p&cI?(h=n+(i-n)*(e.bottom-r)/(o-r),v=e.bottom):p&lI?(v=r+(o-r)*(e.right-n)/(i-n),h=e.right):p&sI&&(v=r+(o-r)*(e.left-n)/(i-n),h=e.left),p===s?(n=h,r=v,s=Sy(n,r,e)):(i=h,o=v,c=Sy(i,o,e));return {x0:n,x1:i,y0:r,y1:o}}function Py(t,e){var n=e.anchor,r=t,i,o;return e.clamp&&(r=WU(r,e.area)),n==="start"?(i=r.x0,o=r.y0):n==="end"?(i=r.x1,o=r.y1):(i=(r.x0+r.x1)/2,o=(r.y0+r.y1)/2),zU(i,o,t.vx,t.vy,e.align)}var xy={arc:function(t,e){var n=(t.startAngle+t.endAngle)/2,r=Math.cos(n),i=Math.sin(n),o=t.innerRadius,s=t.outerRadius;return Py({x0:t.x+r*o,y0:t.y+i*o,x1:t.x+r*s,y1:t.y+i*s,vx:r,vy:i},e)},point:function(t,e){var n=l1(t,e.origin),r=n.x*t.options.radius,i=n.y*t.options.radius;return Py({x0:t.x-r,y0:t.y-i,x1:t.x+r,y1:t.y+i,vx:n.x,vy:n.y},e)},bar:function(t,e){var n=l1(t,e.origin),r=t.x,i=t.y,o=0,s=0;return t.horizontal?(r=Math.min(t.x,t.base),o=Math.abs(t.base-t.x)):(i=Math.min(t.y,t.base),s=Math.abs(t.base-t.y)),Py({x0:r,y0:i+s,x1:r+o,y1:i,vx:n.x,vy:n.y},e)},fallback:function(t,e){var n=l1(t,e.origin);return Py({x0:t.x,y0:t.y,x1:t.x+(t.width||0),y1:t.y+(t.height||0),vx:n.x,vy:n.y},e)}},ps=Ff.rasterize;function qU(t){var e=t.borderWidth||0,n=t.padding,r=t.size.height,i=t.size.width,o=-i/2,s=-r/2;return {frame:{x:o-n.left-e,y:s-n.top-e,w:i+n.width+e*2,h:r+n.height+e*2},text:{x:o,y:s,w:i,h:r}}}function YU(t,e){var n=e.chart.getDatasetMeta(e.datasetIndex).vScale;if(!n)return null;if(n.xCenter!==void 0&&n.yCenter!==void 0)return {x:n.xCenter,y:n.yCenter};var r=n.getBasePixel();return t.horizontal?{x:r,y:null}:{x:null,y:r}}function QU(t){return t instanceof cs?xy.arc:t instanceof us?xy.point:t instanceof ds?xy.bar:xy.fallback}function KU(t,e,n,r,i,o){var s=Math.PI/2;if(o){var c=Math.min(o,i/2,r/2),p=e+c,h=n+c,v=e+r-c,P=n+i-c;t.moveTo(e,h),p<v&&h<P?(t.arc(p,h,c,-Math.PI,-s),t.arc(v,h,c,-s,0),t.arc(v,P,c,0,s),t.arc(p,P,c,s,Math.PI)):p<v?(t.moveTo(p,n),t.arc(v,h,c,-s,s),t.arc(p,h,c,s,Math.PI+s)):h<P?(t.arc(p,h,c,-Math.PI,0),t.arc(p,P,c,0,Math.PI)):t.arc(p,h,c,-Math.PI,Math.PI),t.closePath(),t.moveTo(e,n);}else t.rect(e,n,r,i);}function XU(t,e,n){var r=n.backgroundColor,i=n.borderColor,o=n.borderWidth;!r&&(!i||!o)||(t.beginPath(),KU(t,ps(e.x)+o/2,ps(e.y)+o/2,ps(e.w)-o,ps(e.h)-o,n.borderRadius),t.closePath(),r&&(t.fillStyle=r,t.fill()),i&&o&&(t.strokeStyle=i,t.lineWidth=o,t.lineJoin="miter",t.stroke()));}function ZU(t,e,n){var r=n.lineHeight,i=t.w,o=t.x,s=t.y+r/2;return e==="center"?o+=i/2:(e==="end"||e==="right")&&(o+=i),{h:r,w:i,x:o,y:s}}function JU(t,e,n){var r=t.shadowBlur,i=n.stroked,o=ps(n.x),s=ps(n.y),c=ps(n.w);i&&t.strokeText(e,o,s,c),n.filled&&(r&&i&&(t.shadowBlur=0),t.fillText(e,o,s,c),r&&i&&(t.shadowBlur=r));}function t8(t,e,n,r){var i=r.textAlign,o=r.color,s=!!o,c=r.font,p=e.length,h=r.textStrokeColor,v=r.textStrokeWidth,P=h&&v,x;if(!(!p||!s&&!P))for(n=ZU(n,i,c),t.font=c.string,t.textAlign=i,t.textBaseline="middle",t.shadowBlur=r.textShadowBlur,t.shadowColor=r.textShadowColor,s&&(t.fillStyle=o),P&&(t.lineJoin="round",t.lineWidth=v,t.strokeStyle=h),x=0,p=e.length;x<p;++x)JU(t,e[x],{stroked:P,filled:s,w:n.w,x:n.x,y:n.y+n.h*x});}var dI=function(t,e,n,r){var i=this;i._config=t,i._index=r,i._model=null,i._rects=null,i._ctx=e,i._el=n;};ji(dI.prototype,{_modelize:function(t,e,n,r){var i=this,o=i._index,s=Sn(In([n.font,{}],r,o)),c=In([n.color,ke.color],r,o);return {align:In([n.align,"center"],r,o),anchor:In([n.anchor,"center"],r,o),area:r.chart.chartArea,backgroundColor:In([n.backgroundColor,null],r,o),borderColor:In([n.borderColor,null],r,o),borderRadius:In([n.borderRadius,0],r,o),borderWidth:In([n.borderWidth,0],r,o),clamp:In([n.clamp,false],r,o),clip:In([n.clip,false],r,o),color:c,display:t,font:s,lines:e,offset:In([n.offset,4],r,o),opacity:In([n.opacity,1],r,o),origin:YU(i._el,r),padding:$n(In([n.padding,4],r,o)),positioner:QU(i._el),rotation:In([n.rotation,0],r,o)*(Math.PI/180),size:Ff.textSize(i._ctx,e,s),textAlign:In([n.textAlign,"start"],r,o),textShadowBlur:In([n.textShadowBlur,0],r,o),textShadowColor:In([n.textShadowColor,c],r,o),textStrokeColor:In([n.textStrokeColor,c],r,o),textStrokeWidth:In([n.textStrokeWidth,0],r,o)}},update:function(t){var e=this,n=null,r=null,i=e._index,o=e._config,s,c,p,h=In([o.display,true],t,i);h&&(s=t.dataset.data[i],c=me(Qe(o.formatter,[s,t]),s),p=Le(c)?[]:Ff.toTextLines(c),p.length&&(n=e._modelize(h,p,o,t),r=qU(n))),e._model=n,e._rects=r;},geometry:function(){return this._rects?this._rects.frame:{}},rotation:function(){return this._model?this._model.rotation:0},visible:function(){return this._model&&this._model.opacity},model:function(){return this._model},draw:function(t,e){var n=this,r=t.ctx,i=n._model,o=n._rects,s;this.visible()&&(r.save(),i.clip&&(s=i.area,r.beginPath(),r.rect(s.left,s.top,s.right-s.left,s.bottom-s.top),r.clip()),r.globalAlpha=Ff.bound(0,i.opacity,1),r.translate(ps(e.x),ps(e.y)),r.rotate(i.rotation),XU(r,o.frame,i),t8(r,i.lines,o.text,i),r.restore());}});var e8=Number.MIN_SAFE_INTEGER||-9007199254740991,n8=Number.MAX_SAFE_INTEGER||9007199254740991;function Rf(t,e,n){var r=Math.cos(n),i=Math.sin(n),o=e.x,s=e.y;return {x:o+r*(t.x-o)-i*(t.y-s),y:s+i*(t.x-o)+r*(t.y-s)}}function aI(t,e){var n=n8,r=e8,i=e.origin,o,s,c,p,h;for(o=0;o<t.length;++o)s=t[o],c=s.x-i.x,p=s.y-i.y,h=e.vx*c+e.vy*p,n=Math.min(n,h),r=Math.max(r,h);return {min:n,max:r}}function Ey(t,e){var n=e.x-t.x,r=e.y-t.y,i=Math.sqrt(n*n+r*r);return {vx:(e.x-t.x)/i,vy:(e.y-t.y)/i,origin:t,ln:i}}var pI=function(){this._rotation=0,this._rect={x:0,y:0,w:0,h:0};};ji(pI.prototype,{center:function(){var t=this._rect;return {x:t.x+t.w/2,y:t.y+t.h/2}},update:function(t,e,n){this._rotation=n,this._rect={x:e.x+t.x,y:e.y+t.y,w:e.w,h:e.h};},contains:function(t){var e=this,n=1,r=e._rect;return t=Rf(t,e.center(),-e._rotation),!(t.x<r.x-n||t.y<r.y-n||t.x>r.x+r.w+n*2||t.y>r.y+r.h+n*2)},intersects:function(t){var e=this._points(),n=t._points(),r=[Ey(e[0],e[1]),Ey(e[0],e[3])],i,o,s;for(this._rotation!==t._rotation&&r.push(Ey(n[0],n[1]),Ey(n[0],n[3])),i=0;i<r.length;++i)if(o=aI(e,r[i]),s=aI(n,r[i]),o.max<s.min||s.max<o.min)return false;return true},_points:function(){var t=this,e=t._rect,n=t._rotation,r=t.center();return [Rf({x:e.x,y:e.y},r,n),Rf({x:e.x+e.w,y:e.y},r,n),Rf({x:e.x+e.w,y:e.y+e.h},r,n),Rf({x:e.x,y:e.y+e.h},r,n)]}});function fI(t,e,n){var r=e.positioner(t,e),i=r.vx,o=r.vy;if(!i&&!o)return {x:r.x,y:r.y};var s=n.w,c=n.h,p=e.rotation,h=Math.abs(s/2*Math.cos(p))+Math.abs(c/2*Math.sin(p)),v=Math.abs(s/2*Math.sin(p))+Math.abs(c/2*Math.cos(p)),P=1/Math.max(Math.abs(i),Math.abs(o));return h*=i*P,v*=o*P,h+=e.offset*i,v+=e.offset*o,{x:r.x+h,y:r.y+v}}function r8(t,e){var n,r,i,o;for(n=t.length-1;n>=0;--n)for(i=t[n].$layout,r=n-1;r>=0&&i._visible;--r)o=t[r].$layout,o._visible&&i._box.intersects(o._box)&&e(i,o);return t}function i8(t){var e,n,r,i,o,s,c;for(e=0,n=t.length;e<n;++e)r=t[e],i=r.$layout,i._visible&&(c=new Proxy(r._el,{get:(p,h)=>p.getProps([h],true)[h]}),o=r.geometry(),s=fI(c,r.model(),o),i._box.update(s,o,r.rotation()));return r8(t,function(p,h){var v=p._hidable,P=h._hidable;v&&P||P?h._visible=false:v&&(p._visible=false);})}var Mf={prepare:function(t){var e=[],n,r,i,o,s;for(n=0,i=t.length;n<i;++n)for(r=0,o=t[n].length;r<o;++r)s=t[n][r],e.push(s),s.$layout={_box:new pI,_hidable:false,_visible:true,_set:n,_idx:s._index};return e.sort(function(c,p){var h=c.$layout,v=p.$layout;return h._idx===v._idx?v._set-h._set:v._idx-h._idx}),this.update(e),e},update:function(t){var e=false,n,r,i,o,s;for(n=0,r=t.length;n<r;++n)i=t[n],o=i.model(),s=i.$layout,s._hidable=o&&o.display==="auto",s._visible=i.visible(),e|=s._hidable;e&&i8(t);},lookup:function(t,e){var n,r;for(n=t.length-1;n>=0;--n)if(r=t[n].$layout,r&&r._visible&&r._box.contains(e))return t[n];return null},draw:function(t,e){var n,r,i,o,s,c;for(n=0,r=e.length;n<r;++n)i=e[n],o=i.$layout,o._visible&&(s=i.geometry(),c=fI(i._el,i.model(),s),o._box.update(c,s,i.rotation()),i.draw(t,c));}},o8=function(t){if(Le(t))return null;var e=t,n,r,i;if(Te(t))if(!Le(t.label))e=t.label;else if(!Le(t.r))e=t.r;else for(e="",n=Object.keys(t),i=0,r=n.length;i<r;++i)e+=(i!==0?", ":"")+n[i]+": "+t[n[i]];return ""+e},a8={align:"center",anchor:"center",backgroundColor:null,borderColor:null,borderRadius:0,borderWidth:0,clamp:false,clip:false,color:void 0,display:true,font:{family:void 0,lineHeight:1.2,size:void 0,style:void 0,weight:null},formatter:o8,labels:void 0,listeners:{},offset:4,opacity:1,padding:{top:4,right:4,bottom:4,left:4},rotation:0,textAlign:"start",textStrokeColor:void 0,textStrokeWidth:0,textShadowBlur:0,textShadowColor:void 0},Ti="$datalabels",hI="$default";function s8(t,e){var n=t.datalabels,r={},i=[],o,s;return n===false?null:(n===true&&(n={}),e=ji({},[e,n]),o=e.labels||{},s=Object.keys(o),delete e.labels,s.length?s.forEach(function(c){o[c]&&i.push(ji({},[e,o[c],{_key:c}]));}):i.push(e),r=i.reduce(function(c,p){return tn(p.listeners||{},function(h,v){c[v]=c[v]||{},c[v][p._key||hI]=h;}),delete p.listeners,c},{}),{labels:i,listeners:r})}function c1(t,e,n,r){if(e){var i=n.$context,o=n.$groups,s;e[o._set]&&(s=e[o._set][o._key],s&&Qe(s,[i,r])===true&&(t[Ti]._dirty=true,n.update(i)));}}function l8(t,e,n,r,i){var o,s;!n&&!r||(n?r?n!==r&&(s=o=true):s=true:o=true,s&&c1(t,e.leave,n,i),o&&c1(t,e.enter,r,i));}function c8(t,e){var n=t[Ti],r=n._listeners,i,o;if(!(!r.enter&&!r.leave)){if(e.type==="mousemove")o=Mf.lookup(n._labels,e);else if(e.type!=="mouseout")return;i=n._hovered,n._hovered=o,l8(t,r,i,o,e);}}function u8(t,e){var n=t[Ti],r=n._listeners.click,i=r&&Mf.lookup(n._labels,e);i&&c1(t,r,i,e);}var mI={id:"datalabels",defaults:a8,beforeInit:function(t){t[Ti]={_actives:[]};},beforeUpdate:function(t){var e=t[Ti];e._listened=false,e._listeners={},e._datasets=[],e._labels=[];},afterDatasetUpdate:function(t,e,n){var r=e.index,i=t[Ti],o=i._datasets[r]=[],s=t.isDatasetVisible(r),c=t.data.datasets[r],p=s8(c,n),h=e.meta.data||[],v=t.ctx,P,x,T,I,F,A,O,N;for(v.save(),P=0,T=h.length;P<T;++P)if(O=h[P],O[Ti]=[],s&&O&&t.getDataVisibility(P)&&!O.skip)for(x=0,I=p.labels.length;x<I;++x)F=p.labels[x],A=F._key,N=new dI(F,v,O,P),N.$groups={_set:r,_key:A||hI},N.$context={active:false,chart:t,dataIndex:P,dataset:c,datasetIndex:r},N.update(N.$context),O[Ti].push(N),o.push(N);v.restore(),ji(i._listeners,p.listeners,{merger:function(V,G,X){G[V]=G[V]||{},G[V][e.index]=X[V],i._listened=true;}});},afterUpdate:function(t){t[Ti]._labels=Mf.prepare(t[Ti]._datasets);},afterDatasetsDraw:function(t){Mf.draw(t,t[Ti]._labels);},beforeEvent:function(t,e){if(t[Ti]._listened){var n=e.event;switch(n.type){case "mousemove":case "mouseout":c8(t,n);break;case "click":u8(t,n);break}}},afterEvent:function(t){var e=t[Ti],n=e._actives,r=e._actives=t.getActiveElements(),i=Ff.arrayDiff(n,r),o,s,c,p,h,v,P;for(o=0,s=i.length;o<s;++o)if(h=i[o],h[1])for(P=h[0].element[Ti]||[],c=0,p=P.length;c<p;++c)v=P[c],v.$context.active=h[1]===1,v.update(v.$context);(e._dirty||i.length)&&(Mf.update(e._labels),t.render()),delete e._dirty;}};var gI={modes:{point(t,e){return Ty(t,e,{intersect:true})},nearest(t,e,n){return f8(t,e,n)},x(t,e,n){return Ty(t,e,{intersect:n.intersect,axis:"x"})},y(t,e,n){return Ty(t,e,{intersect:n.intersect,axis:"y"})}}};function b1(t,e,n){return (gI.modes[n.mode]||gI.modes.nearest)(t,e,n)}function d8(t,e,n){return n!=="x"&&n!=="y"?t.inRange(e.x,e.y,"x",true)||t.inRange(e.x,e.y,"y",true):t.inRange(e.x,e.y,n,true)}function p8(t,e,n){return n==="x"?{x:t.x,y:e.y}:n==="y"?{x:e.x,y:t.y}:e}function Ty(t,e,n){return t.visibleElements.filter(r=>n.intersect?r.inRange(e.x,e.y):d8(r,e,n.axis))}function f8(t,e,n){let r=Number.POSITIVE_INFINITY;return Ty(t,e,n).reduce((i,o)=>{let s=o.getCenterPoint(),c=p8(e,s,n.axis),p=ns(e,c);return p<r?(i=[o],r=p):p===r&&i.push(o),i},[]).sort((i,o)=>i._index-o._index).slice(0,1)}var h8=(t,e)=>e>t||t.length>e.length&&t.slice(0,e.length)===e,Fc=.001,Iy=(t,e,n)=>Math.min(n,Math.max(e,t));function m8(t,e,n){for(let r of Object.keys(t))t[r]=Iy(t[r],e,n);return t}function g8(t,e,n,r){if(!t||!e||n<=0)return false;let i=r/2;return Math.pow(t.x-e.x,2)+Math.pow(t.y-e.y,2)<=Math.pow(n+i,2)}function MI(t,{x:e,y:n,x2:r,y2:i},o,s){let c=s/2,p=t.x>=e-c-Fc&&t.x<=r+c+Fc,h=t.y>=n-c-Fc&&t.y<=i+c+Fc;return o==="x"?p:(o==="y"||p)&&h}function md(t,e){let{centerX:n,centerY:r}=t.getProps(["centerX","centerY"],e);return {x:n,y:r}}function y8(t,e,n,r=true){let i=n.split("."),o=0;for(let s of e.split(".")){let c=i[o++];if(parseInt(s,10)<parseInt(c,10))break;if(h8(c,s)){if(r)throw new Error(`${t} v${n} is not supported. v${e} or newer is required.`);return false}}return true}var NI=t=>typeof t=="string"&&t.endsWith("%"),LI=t=>parseFloat(t)/100,BI=t=>Iy(LI(t),0,1);function v1(t,e){return e==="start"?0:e==="end"?t:NI(e)?BI(e)*t:t/2}function Cl(t,e,n=true){return typeof e=="number"?e:NI(e)?(n?BI(e):LI(e))*t:t}function b8(t,e){let{x:n,width:r}=t,i=e.textAlign;return i==="center"?n+r/2:i==="end"||i==="right"?n+r:n}function C1(t,e="center"){return Te(t)?{x:me(t.x,e),y:me(t.y,e)}:(t=me(t,e),{x:t,y:t})}function UI(t){return t&&(Fn(t.xValue)||Fn(t.yValue))}function Lf(t,e,n,r=false){let i=n.init;if(i){if(i===true)return GI(e,r)}else return;return v8(e,r,Qe(i,[{chart:t,properties:e,options:n}]))}function $I(t,e,n){let r=false;return e.forEach(i=>{Gr(t[i])?(r=true,n[i]=t[i]):Fn(n[i])&&delete n[i];}),r}function GI({centerX:t,centerY:e},n){return n?{centerX:t,centerY:e,radius:0,width:0,height:0}:{x:t,y:e,x2:t,y2:e,width:0,height:0}}function v8(t,e,n){if(n===true)return GI(t,e);if(Te(n))return n}var u1=new Map,C8=t=>isNaN(t)||t<=0,S8=t=>t.reduce(function(e,n){return e+=n.string,e},"");function ky(t){if(t&&typeof t=="object"){let e=t.toString();return e==="[object HTMLImageElement]"||e==="[object HTMLCanvasElement]"}}function S1(t,{x:e,y:n},r){r&&(t.translate(e,n),t.rotate(Qn(r)),t.translate(-e,-n));}function Sl(t,e){if(e&&e.borderWidth)return t.lineCap=e.borderCapStyle,t.setLineDash(e.borderDash),t.lineDashOffset=e.borderDashOffset,t.lineJoin=e.borderJoinStyle,t.lineWidth=e.borderWidth,t.strokeStyle=e.borderColor,true}function gd(t,e){t.shadowColor=e.backgroundShadowColor,t.shadowBlur=e.shadowBlur,t.shadowOffsetX=e.shadowOffsetX,t.shadowOffsetY=e.shadowOffsetY;}function P1(t,e){let n=e.content;if(ky(n))return {width:Cl(n.width,e.width),height:Cl(n.height,e.height)};let r=e.font,i=He(r)?r.map(p=>Sn(p)):[Sn(r)],o=e.textStrokeWidth,s=He(n)?n:[n],c=s.join()+S8(i)+o+(t._measureText?"-spriting":"");return u1.has(c)||u1.set(c,T8(t,s,i,o)),u1.get(c)}function jI(t,e,n){let{x:r,y:i,width:o,height:s}=e;t.save(),gd(t,n);let c=Sl(t,n);t.fillStyle=n.backgroundColor,t.beginPath(),os(t,{x:r,y:i,w:o,h:s,radius:m8($o(n.borderRadius),0,Math.min(o,s)/2)}),t.closePath(),t.fill(),c&&(t.shadowColor=n.borderShadowColor,t.stroke()),t.restore();}function P8(t,e,n){let r=n.content;if(ky(r)){t.save(),t.globalAlpha=k8(n.opacity,r.style.opacity),t.drawImage(r,e.x,e.y,e.width,e.height),t.restore();return}let i=He(r)?r:[r],o=n.font,s=He(o)?o.map(P=>Sn(P)):[Sn(o)],c=n.color,p=He(c)?c:[c],h=b8(e,n),v=e.y+n.textStrokeWidth/2;t.save(),t.textBaseline="middle",t.textAlign=n.textAlign,x8(t,n)&&w8(t,{x:h,y:v},i,s),I8(t,{x:h,y:v},i,{fonts:s,colors:p}),t.restore();}function x8(t,e){if(e.textStrokeWidth>0)return t.lineJoin="round",t.miterLimit=2,t.lineWidth=e.textStrokeWidth,t.strokeStyle=e.textStrokeColor,true}function E8(t,e,n,r){let{radius:i,options:o}=e,s=o.pointStyle,c=o.rotation,p=(c||0)*lf;if(ky(s)){t.save(),t.translate(n,r),t.rotate(p),t.drawImage(s,-s.width/2,-s.height/2,s.width,s.height),t.restore();return}C8(i)||_8(t,{x:n,y:r,radius:i,rotation:c,style:s,rad:p});}function _8(t,{x:e,y:n,radius:r,rotation:i,style:o,rad:s}){let c,p,h,v;switch(t.beginPath(),o){default:t.arc(e,n,r,0,rn),t.closePath();break;case "triangle":t.moveTo(e+Math.sin(s)*r,n-Math.cos(s)*r),s+=ed,t.lineTo(e+Math.sin(s)*r,n-Math.cos(s)*r),s+=ed,t.lineTo(e+Math.sin(s)*r,n-Math.cos(s)*r),t.closePath();break;case "rectRounded":v=r*.516,h=r-v,c=Math.cos(s+mo)*h,p=Math.sin(s+mo)*h,t.arc(e-c,n-p,v,s-Be,s-bn),t.arc(e+p,n-c,v,s-bn,s),t.arc(e+c,n+p,v,s,s+bn),t.arc(e-p,n+c,v,s+bn,s+Be),t.closePath();break;case "rect":if(!i){h=Math.SQRT1_2*r,t.rect(e-h,n-h,2*h,2*h);break}s+=mo;case "rectRot":c=Math.cos(s)*r,p=Math.sin(s)*r,t.moveTo(e-c,n-p),t.lineTo(e+p,n-c),t.lineTo(e+c,n+p),t.lineTo(e-p,n+c),t.closePath();break;case "crossRot":s+=mo;case "cross":c=Math.cos(s)*r,p=Math.sin(s)*r,t.moveTo(e-c,n-p),t.lineTo(e+c,n+p),t.moveTo(e+p,n-c),t.lineTo(e-p,n+c);break;case "star":c=Math.cos(s)*r,p=Math.sin(s)*r,t.moveTo(e-c,n-p),t.lineTo(e+c,n+p),t.moveTo(e+p,n-c),t.lineTo(e-p,n+c),s+=mo,c=Math.cos(s)*r,p=Math.sin(s)*r,t.moveTo(e-c,n-p),t.lineTo(e+c,n+p),t.moveTo(e+p,n-c),t.lineTo(e-p,n+c);break;case "line":c=Math.cos(s)*r,p=Math.sin(s)*r,t.moveTo(e-c,n-p),t.lineTo(e+c,n+p);break;case "dash":t.moveTo(e,n),t.lineTo(e+Math.cos(s)*r,n+Math.sin(s)*r);break}t.fill();}function T8(t,e,n,r){t.save();let i=e.length,o=0,s=r;for(let c=0;c<i;c++){let p=n[Math.min(c,n.length-1)];t.font=p.string;let h=e[c];o=Math.max(o,t.measureText(h).width+r),s+=p.lineHeight;}return t.restore(),{width:o,height:s}}function w8(t,{x:e,y:n},r,i){t.beginPath();let o=0;r.forEach(function(s,c){let p=i[Math.min(c,i.length-1)],h=p.lineHeight;t.font=p.string,t.strokeText(s,e,n+h/2+o),o+=h;}),t.stroke();}function I8(t,{x:e,y:n},r,{fonts:i,colors:o}){let s=0;r.forEach(function(c,p){let h=o[Math.min(p,o.length-1)],v=i[Math.min(p,i.length-1)],P=v.lineHeight;t.beginPath(),t.font=v.string,t.fillStyle=h,t.fillText(c,e,n+P/2+s),s+=P,t.fill();});}function k8(t,e){let n=Vi(t)?t:e;return Vi(n)?Iy(n,0,1):1}var yI={xScaleID:{min:"xMin",max:"xMax",start:"left",end:"right",startProp:"x",endProp:"x2"},yScaleID:{min:"yMin",max:"yMax",start:"bottom",end:"top",startProp:"y",endProp:"y2"}};function pd(t,e,n){return e=typeof e=="number"?e:t.parse(e),Mn(e)?t.getPixelForValue(e):n}function Mc(t,e,n){let r=e[n];if(r||n==="scaleID")return r;let i=n.charAt(0),o=Object.values(t).filter(s=>s.axis&&s.axis===i);return o.length?o[0].id:i}function VI(t,e){if(t){let n=t.options.reverse,r=pd(t,e.min,n?e.end:e.start),i=pd(t,e.max,n?e.start:e.end);return {start:r,end:i}}}function zI(t,e){let{chartArea:n,scales:r}=t,i=r[Mc(r,e,"xScaleID")],o=r[Mc(r,e,"yScaleID")],s=n.width/2,c=n.height/2;return i&&(s=pd(i,e.xValue,i.left+i.width/2)),o&&(c=pd(o,e.yValue,o.top+o.height/2)),{x:s,y:c}}function x1(t,e){let n=t.scales,r=n[Mc(n,e,"xScaleID")],i=n[Mc(n,e,"yScaleID")];if(!r&&!i)return {};let{left:o,right:s}=r||t.chartArea,{top:c,bottom:p}=i||t.chartArea,h=bI(r,{min:e.xMin,max:e.xMax,start:o,end:s});o=h.start,s=h.end;let v=bI(i,{min:e.yMin,max:e.yMax,start:p,end:c});return c=v.start,p=v.end,{x:o,y:c,x2:s,y2:p,width:s-o,height:p-c,centerX:o+(s-o)/2,centerY:c+(p-c)/2}}function HI(t,e){if(!UI(e)){let n=x1(t,e),r=e.radius;(!r||isNaN(r))&&(r=Math.min(n.width,n.height)/2,e.radius=r);let i=r*2,o=n.centerX+e.xAdjust,s=n.centerY+e.yAdjust;return {x:o-r,y:s-r,x2:o+r,y2:s+r,centerX:o,centerY:s,width:i,height:i,radius:r}}return A8(t,e)}function D8(t,e){let{scales:n,chartArea:r}=t,i=n[e.scaleID],o={x:r.left,y:r.top,x2:r.right,y2:r.bottom};return i?O8(i,o,e):R8(n,o,e),o}function WI(t,e,n){let r=x1(t,e);return r.initProperties=Lf(t,r,e,n),r.elements=[{type:"label",optionScope:"label",properties:N8(t,r,e),initProperties:r.initProperties}],r}function A8(t,e){let n=zI(t,e),r=e.radius*2;return {x:n.x-e.radius+e.xAdjust,y:n.y-e.radius+e.yAdjust,x2:n.x+e.radius+e.xAdjust,y2:n.y+e.radius+e.yAdjust,centerX:n.x+e.xAdjust,centerY:n.y+e.yAdjust,radius:e.radius,width:r,height:r}}function bI(t,e){let n=VI(t,e)||e;return {start:Math.min(n.start,n.end),end:Math.max(n.start,n.end)}}function O8(t,e,n){let r=pd(t,n.value,NaN),i=pd(t,n.endValue,r);t.isHorizontal()?(e.x=r,e.x2=i):(e.y=r,e.y2=i);}function R8(t,e,n){for(let r of Object.keys(yI)){let i=t[Mc(t,n,r)];if(i){let{min:o,max:s,start:c,end:p,startProp:h,endProp:v}=yI[r],P=VI(i,{min:n[o],max:n[s],start:i[c],end:i[p]});e[h]=P.start,e[v]=P.end;}}}function F8({properties:t,options:e},n,r,i){let{x:o,x2:s,width:c}=t;return qI({start:o,end:s,borderWidth:e.borderWidth},{position:r.x,padding:{start:i.left,end:i.right},adjust:e.label.xAdjust,size:n.width})}function M8({properties:t,options:e},n,r,i){let{y:o,y2:s,height:c}=t;return qI({start:o,end:s,borderWidth:e.borderWidth},{position:r.y,padding:{start:i.top,end:i.bottom},adjust:e.label.yAdjust,size:n.height})}function qI(t,e){let{start:n,end:r,borderWidth:i}=t,{position:o,padding:{start:s,end:c},adjust:p}=e,h=r-i-n-s-c-e.size;return n+i/2+p+v1(h,o)}function N8(t,e,n){let r=n.label;r.backgroundColor="transparent",r.callout.display=false;let i=C1(r.position),o=$n(r.padding),s=P1(t.ctx,r),c=F8({properties:e,options:n},s,i,o),p=M8({properties:e,options:n},s,i,o),h=s.width+o.width,v=s.height+o.height;return {x:c,y:p,x2:c+h,y2:p+v,width:h,height:v,centerX:c+h/2,centerY:p+v/2,rotation:r.rotation}}function Uc(t,e,n){let r=Math.cos(n),i=Math.sin(n),o=e.x,s=e.y;return {x:o+r*(t.x-o)-i*(t.y-s),y:s+i*(t.x-o)+r*(t.y-s)}}var d1=["enter","leave"],E1=d1.concat("click");function L8(t,e,n){e.listened=$I(n,E1,e.listeners),e.moveListened=false,e._getElements=b1,d1.forEach(r=>{Gr(n[r])&&(e.moveListened=true);}),(!e.listened||!e.moveListened)&&e.annotations.forEach(r=>{!e.listened&&Gr(r.click)&&(e.listened=true),e.moveListened||d1.forEach(i=>{Gr(r[i])&&(e.listened=true,e.moveListened=true);});});}function B8(t,e,n){if(t.listened)switch(e.type){case "mousemove":case "mouseout":return U8(t,e,n);case "click":return $8(t,e,n)}}function U8(t,e,n){if(!t.moveListened)return;let r;e.type==="mousemove"?r=b1(t,e,n.interaction):r=[];let i=t.hovered;t.hovered=r;let o={state:t,event:e},s=vI(o,"leave",i,r);return vI(o,"enter",r,i)||s}function vI({state:t,event:e},n,r,i){let o;for(let s of r)i.indexOf(s)<0&&(o=YI(s.options[n]||t.listeners[n],s,e)||o);return o}function $8(t,e,n){let r=t.listeners,i=b1(t,e,n.interaction),o;for(let s of i)o=YI(s.options.click||r.click,s,e)||o;return o}function YI(t,e,n){return Qe(t,[e.$context,n])===true}var wy=["afterDraw","beforeDraw"];function G8(t,e,n){let r=e.visibleElements;e.hooked=$I(n,wy,e.hooks),e.hooked||r.forEach(i=>{e.hooked||wy.forEach(o=>{Gr(i.options[o])&&(e.hooked=true);});});}function CI(t,e,n){if(t.hooked){let r=e.options[n]||t.hooks[n];return Qe(r,[e.$context])}}function j8(t,e,n){let r=q8(t.scales,e,n),i=SI(e,r,"min","suggestedMin");i=SI(e,r,"max","suggestedMax")||i,i&&Gr(e.handleTickRangeOptions)&&e.handleTickRangeOptions();}function V8(t,e){for(let n of t)H8(n,e);}function SI(t,e,n,r){if(Mn(e[n])&&!z8(t.options,n,r)){let i=t[n]!==e[n];return t[n]=e[n],i}}function z8(t,e,n){return Fn(t[e])||Fn(t[n])}function H8(t,e){for(let n of ["scaleID","xScaleID","yScaleID"]){let r=Mc(e,t,n);r&&!e[r]&&W8(t,n)&&console.warn(`No scale found with id '${r}' for annotation '${t.id}'`);}}function W8(t,e){if(e==="scaleID")return true;let n=e.charAt(0);for(let r of ["Min","Max","Value"])if(Fn(t[n+r]))return true;return false}function q8(t,e,n){let r=e.axis,i=e.id,o=r+"ScaleID",s={min:me(e.min,Number.NEGATIVE_INFINITY),max:me(e.max,Number.POSITIVE_INFINITY)};for(let c of n)c.scaleID===i?PI(c,e,["value","endValue"],s):Mc(t,c,o)===i&&PI(c,e,[r+"Min",r+"Max",r+"Value"],s);return s}function PI(t,e,n,r){for(let i of n){let o=t[i];if(Fn(o)){let s=e.parse(o);r.min=Math.min(r.min,s),r.max=Math.max(r.max,s);}}}var Pl=class extends br{inRange(e,n,r,i){let{x:o,y:s}=Uc({x:e,y:n},this.getCenterPoint(i),Qn(-this.options.rotation));return MI({x:o,y:s},this.getProps(["x","y","x2","y2"],i),r,this.options.borderWidth)}getCenterPoint(e){return md(this,e)}draw(e){e.save(),S1(e,this.getCenterPoint(),this.options.rotation),jI(e,this,this.options),e.restore();}get label(){return this.elements&&this.elements[0]}resolveElementProperties(e,n){return WI(e,n)}};Pl.id="boxAnnotation";Pl.defaults={adjustScaleRange:true,backgroundShadowColor:"transparent",borderCapStyle:"butt",borderDash:[],borderDashOffset:0,borderJoinStyle:"miter",borderRadius:0,borderShadowColor:"transparent",borderWidth:1,display:true,init:void 0,label:{backgroundColor:"transparent",borderWidth:0,callout:{display:false},color:"black",content:null,display:false,drawTime:void 0,font:{family:void 0,lineHeight:void 0,size:void 0,style:void 0,weight:"bold"},height:void 0,opacity:void 0,padding:6,position:"center",rotation:void 0,textAlign:"start",textStrokeColor:void 0,textStrokeWidth:0,width:void 0,xAdjust:0,yAdjust:0,z:void 0},rotation:0,shadowBlur:0,shadowOffsetX:0,shadowOffsetY:0,xMax:void 0,xMin:void 0,xScaleID:void 0,yMax:void 0,yMin:void 0,yScaleID:void 0,z:0};Pl.defaultRoutes={borderColor:"color",backgroundColor:"color"};Pl.descriptors={label:{_fallback:true}};var QI=["left","bottom","top","right"],Nc=class extends br{inRange(e,n,r,i){let{x:o,y:s}=Uc({x:e,y:n},this.getCenterPoint(i),Qn(-this.rotation));return MI({x:o,y:s},this.getProps(["x","y","x2","y2"],i),r,this.options.borderWidth)}getCenterPoint(e){return md(this,e)}draw(e){let n=this.options,r=!Fn(this._visible)||this._visible;!n.display||!n.content||!r||(e.save(),S1(e,this.getCenterPoint(),this.rotation),Q8(e,this),jI(e,this,n),P8(e,n7(this),n),e.restore());}resolveElementProperties(e,n){let r;if(UI(n))r=zI(e,n);else {let{centerX:c,centerY:p}=x1(e,n);r={x:c,y:p};}let i=$n(n.padding),o=P1(e.ctx,n),s=Y8(r,o,n,i);return St(W({initProperties:Lf(e,s,n),pointX:r.x,pointY:r.y},s),{rotation:n.rotation})}};Nc.id="labelAnnotation";Nc.defaults={adjustScaleRange:true,backgroundColor:"transparent",backgroundShadowColor:"transparent",borderCapStyle:"butt",borderDash:[],borderDashOffset:0,borderJoinStyle:"miter",borderRadius:0,borderShadowColor:"transparent",borderWidth:0,callout:{borderCapStyle:"butt",borderColor:void 0,borderDash:[],borderDashOffset:0,borderJoinStyle:"miter",borderWidth:1,display:false,margin:5,position:"auto",side:5,start:"50%"},color:"black",content:null,display:true,font:{family:void 0,lineHeight:void 0,size:void 0,style:void 0,weight:void 0},height:void 0,init:void 0,opacity:void 0,padding:6,position:"center",rotation:0,shadowBlur:0,shadowOffsetX:0,shadowOffsetY:0,textAlign:"center",textStrokeColor:void 0,textStrokeWidth:0,width:void 0,xAdjust:0,xMax:void 0,xMin:void 0,xScaleID:void 0,xValue:void 0,yAdjust:0,yMax:void 0,yMin:void 0,yScaleID:void 0,yValue:void 0,z:0};Nc.defaultRoutes={borderColor:"color"};function Y8(t,e,n,r){let i=e.width+r.width+n.borderWidth,o=e.height+r.height+n.borderWidth,s=C1(n.position,"center"),c=xI(t.x,i,n.xAdjust,s.x),p=xI(t.y,o,n.yAdjust,s.y);return {x:c,y:p,x2:c+i,y2:p+o,width:i,height:o,centerX:c+i/2,centerY:p+o/2}}function xI(t,e,n=0,r){return t-v1(e,r)+n}function Q8(t,e){let{pointX:n,pointY:r,options:i}=e,o=i.callout,s=o&&o.display&&t7(e,o);if(!s||r7(e,o,s))return;if(t.save(),t.beginPath(),!Sl(t,o))return t.restore();let{separatorStart:p,separatorEnd:h}=K8(e,s),{sideStart:v,sideEnd:P}=Z8(e,s,p);(o.margin>0||i.borderWidth===0)&&(t.moveTo(p.x,p.y),t.lineTo(h.x,h.y)),t.moveTo(v.x,v.y),t.lineTo(P.x,P.y);let x=Uc({x:n,y:r},e.getCenterPoint(),Qn(-e.rotation));t.lineTo(x.x,x.y),t.stroke(),t.restore();}function K8(t,e){let{x:n,y:r,x2:i,y2:o}=t,s=X8(t,e),c,p;return e==="left"||e==="right"?(c={x:n+s,y:r},p={x:c.x,y:o}):(c={x:n,y:r+s},p={x:i,y:c.y}),{separatorStart:c,separatorEnd:p}}function X8(t,e){let{width:n,height:r,options:i}=t,o=i.callout.margin+i.borderWidth/2;return e==="right"?n+o:e==="bottom"?r+o:-o}function Z8(t,e,n){let{y:r,width:i,height:o,options:s}=t,c=s.callout.start,p=J8(e,s.callout),h,v;return e==="left"||e==="right"?(h={x:n.x,y:r+Cl(o,c)},v={x:h.x+p,y:h.y}):(h={x:n.x+Cl(i,c),y:n.y},v={x:h.x,y:h.y+p}),{sideStart:h,sideEnd:v}}function J8(t,e){let n=e.side;return t==="left"||t==="top"?-n:n}function t7(t,e){let n=e.position;return QI.includes(n)?n:e7(t,e)}function e7(t,e){let{x:n,y:r,x2:i,y2:o,width:s,height:c,pointX:p,pointY:h,centerX:v,centerY:P,rotation:x}=t,T={x:v,y:P},I=e.start,F=Cl(s,I),A=Cl(c,I),O=[n,n+F,n+F,i],N=[r+A,o,r,o],V=[];for(let G=0;G<4;G++){let X=Uc({x:O[G],y:N[G]},T,Qn(x));V.push({position:QI[G],distance:ns(X,{x:p,y:h})});}return V.sort((G,X)=>G.distance-X.distance)[0].position}function n7({x:t,y:e,width:n,height:r,options:i}){let o=i.borderWidth/2,s=$n(i.padding);return {x:t+s.left+o,y:e+s.top+o,width:n-s.left-s.right-i.borderWidth,height:r-s.top-s.bottom-i.borderWidth}}function r7(t,e,n){let{pointX:r,pointY:i}=t,o=e.margin,s=r,c=i;return n==="left"?s+=o:n==="right"?s-=o:n==="top"?c+=o:n==="bottom"&&(c-=o),t.inRange(s,c)}var _1=(t,e,n)=>({x:t.x+n*(e.x-t.x),y:t.y+n*(e.y-t.y)}),p1=(t,e,n)=>_1(e,n,Math.abs((t-e.y)/(n.y-e.y))).x,EI=(t,e,n)=>_1(e,n,Math.abs((t-e.x)/(n.x-e.x))).y,Nf=t=>t*t,i7=(t,e,{x:n,y:r,x2:i,y2:o},s)=>s==="y"?{start:Math.min(r,o),end:Math.max(r,o),value:e}:{start:Math.min(n,i),end:Math.max(n,i),value:t},_I=(t,e,n,r)=>(1-r)*(1-r)*t+2*(1-r)*r*e+r*r*n,f1=(t,e,n,r)=>({x:_I(t.x,e.x,n.x,r),y:_I(t.y,e.y,n.y,r)}),TI=(t,e,n,r)=>2*(1-r)*(e-t)+2*r*(n-e),wI=(t,e,n,r)=>-Math.atan2(TI(t.x,e.x,n.x,r),TI(t.y,e.y,n.y,r))+.5*Be,Lc=class extends br{inRange(e,n,r,i){let o=this.options.borderWidth/2;if(r!=="x"&&r!=="y"){let s={mouseX:e,mouseY:n},{path:c,ctx:p}=this;if(c){Sl(p,this.options);let{chart:v}=this.$context,P=e*v.currentDevicePixelRatio,x=n*v.currentDevicePixelRatio,T=p.isPointInStroke(c,P,x)||h1(this,s,i);return p.restore(),T}let h=Nf(o);return l7(this,s,h,i)||h1(this,s,i)}return o7(this,{mouseX:e,mouseY:n},r,{hBorderWidth:o,useFinalPosition:i})}getCenterPoint(e){return md(this,e)}draw(e){let{x:n,y:r,x2:i,y2:o,cp:s,options:c}=this;if(e.save(),!Sl(e,c))return e.restore();gd(e,c);let p=Math.sqrt(Math.pow(i-n,2)+Math.pow(o-r,2));if(c.curve&&s)return g7(e,this,s,p),e.restore();let{startOpts:h,endOpts:v,startAdjust:P,endAdjust:x}=KI(this),T=Math.atan2(o-r,i-n);e.translate(n,r),e.rotate(T),e.beginPath(),e.moveTo(0+P,0),e.lineTo(p-x,0),e.shadowColor=c.borderShadowColor,e.stroke(),m1(e,0,P,h),m1(e,p,-x,v),e.restore();}get label(){return this.elements&&this.elements[0]}resolveElementProperties(e,n){let r=D8(e,n),{x:i,y:o,x2:s,y2:c}=r,p=a7(r,e.chartArea),h=p?s7({x:i,y:o},{x:s,y:c},e.chartArea):{x:i,y:o,x2:s,y2:c,width:Math.abs(s-i),height:Math.abs(c-o)};if(h.centerX=(s+i)/2,h.centerY=(c+o)/2,h.initProperties=Lf(e,h,n),n.curve){let P={x:h.x,y:h.y},x={x:h.x2,y:h.y2};h.cp=m7(h,n,ns(P,x));}let v=c7(e,h,n.label);return v._visible=p,h.elements=[{type:"label",optionScope:"label",properties:v,initProperties:h.initProperties}],h}};Lc.id="lineAnnotation";var II={backgroundColor:void 0,backgroundShadowColor:void 0,borderColor:void 0,borderDash:void 0,borderDashOffset:void 0,borderShadowColor:void 0,borderWidth:void 0,display:void 0,fill:void 0,length:void 0,shadowBlur:void 0,shadowOffsetX:void 0,shadowOffsetY:void 0,width:void 0};Lc.defaults={adjustScaleRange:true,arrowHeads:{display:false,end:Object.assign({},II),fill:false,length:12,start:Object.assign({},II),width:6},borderDash:[],borderDashOffset:0,borderShadowColor:"transparent",borderWidth:2,curve:false,controlPoint:{y:"-50%"},display:true,endValue:void 0,init:void 0,label:{backgroundColor:"rgba(0,0,0,0.8)",backgroundShadowColor:"transparent",borderCapStyle:"butt",borderColor:"black",borderDash:[],borderDashOffset:0,borderJoinStyle:"miter",borderRadius:6,borderShadowColor:"transparent",borderWidth:0,callout:Object.assign({},Nc.defaults.callout),color:"#fff",content:null,display:false,drawTime:void 0,font:{family:void 0,lineHeight:void 0,size:void 0,style:void 0,weight:"bold"},height:void 0,opacity:void 0,padding:6,position:"center",rotation:0,shadowBlur:0,shadowOffsetX:0,shadowOffsetY:0,textAlign:"center",textStrokeColor:void 0,textStrokeWidth:0,width:void 0,xAdjust:0,yAdjust:0,z:void 0},scaleID:void 0,shadowBlur:0,shadowOffsetX:0,shadowOffsetY:0,value:void 0,xMax:void 0,xMin:void 0,xScaleID:void 0,yMax:void 0,yMin:void 0,yScaleID:void 0,z:0};Lc.descriptors={arrowHeads:{start:{_fallback:true},end:{_fallback:true},_fallback:true}};Lc.defaultRoutes={borderColor:"color"};function o7(t,{mouseX:e,mouseY:n},r,{hBorderWidth:i,useFinalPosition:o}){let s=i7(e,n,t.getProps(["x","y","x2","y2"],o),r);return s.value>=s.start-i&&s.value<=s.end+i||h1(t,{mouseX:e,mouseY:n},o,r)}function a7({x:t,y:e,x2:n,y2:r},{top:i,right:o,bottom:s,left:c}){return !(t<c&&n<c||t>o&&n>o||e<i&&r<i||e>s&&r>s)}function kI({x:t,y:e},n,{top:r,right:i,bottom:o,left:s}){return t<s&&(e=EI(s,{x:t,y:e},n),t=s),t>i&&(e=EI(i,{x:t,y:e},n),t=i),e<r&&(t=p1(r,{x:t,y:e},n),e=r),e>o&&(t=p1(o,{x:t,y:e},n),e=o),{x:t,y:e}}function s7(t,e,n){let{x:r,y:i}=kI(t,e,n),{x:o,y:s}=kI(e,t,n);return {x:r,y:i,x2:o,y2:s,width:Math.abs(o-r),height:Math.abs(s-i)}}function l7(t,{mouseX:e,mouseY:n},r=Fc,i){let{x:o,y:s,x2:c,y2:p}=t.getProps(["x","y","x2","y2"],i),h=c-o,v=p-s,P=Nf(h)+Nf(v),x=P===0?-1:((e-o)*h+(n-s)*v)/P,T,I;return x<0?(T=o,I=s):x>1?(T=c,I=p):(T=o+x*h,I=s+x*v),Nf(e-T)+Nf(n-I)<=r}function h1(t,{mouseX:e,mouseY:n},r,i){let o=t.label;return o.options.display&&o.inRange(e,n,i,r)}function c7(t,e,n){let r=n.borderWidth,i=$n(n.padding),o=P1(t.ctx,n),s=o.width+i.width+r,c=o.height+i.height+r;return d7(e,n,{width:s,height:c,padding:i},t.chartArea)}function u7(t){let{x:e,y:n,x2:r,y2:i}=t,o=Math.atan2(i-n,r-e);return o>Be/2?o-Be:o<Be/-2?o+Be:o}function d7(t,e,n,r){let{width:i,height:o,padding:s}=n,{xAdjust:c,yAdjust:p}=e,h={x:t.x,y:t.y},v={x:t.x2,y:t.y2},P=e.rotation==="auto"?u7(t):Qn(e.rotation),x=p7(i,o,P),T=f7(t,e,{labelSize:x,padding:s},r),I=t.cp?f1(h,t.cp,v,T):_1(h,v,T),F={size:x.w,min:r.left,max:r.right,padding:s.left},A={size:x.h,min:r.top,max:r.bottom,padding:s.top},O=AI(I.x,F)+c,N=AI(I.y,A)+p;return {x:O-i/2,y:N-o/2,x2:O+i/2,y2:N+o/2,centerX:O,centerY:N,pointX:I.x,pointY:I.y,width:i,height:o,rotation:Tc(P)}}function p7(t,e,n){let r=Math.cos(n),i=Math.sin(n);return {w:Math.abs(t*r)+Math.abs(e*i),h:Math.abs(t*i)+Math.abs(e*r)}}function f7(t,e,n,r){let i,o=h7(t,r);return e.position==="start"?i=DI({w:t.x2-t.x,h:t.y2-t.y},n,e,o):e.position==="end"?i=1-DI({w:t.x-t.x2,h:t.y-t.y2},n,e,o):i=v1(1,e.position),i}function DI(t,e,n,r){let{labelSize:i,padding:o}=e,s=t.w*r.dx,c=t.h*r.dy,p=s>0&&(i.w/2+o.left-r.x)/s,h=c>0&&(i.h/2+o.top-r.y)/c;return Iy(Math.max(p,h),0,.25)}function h7(t,e){let{x:n,x2:r,y:i,y2:o}=t,s=Math.min(i,o)-e.top,c=Math.min(n,r)-e.left,p=e.bottom-Math.max(i,o),h=e.right-Math.max(n,r);return {x:Math.min(c,h),y:Math.min(s,p),dx:c<=h?1:-1,dy:s<=p?1:-1}}function AI(t,e){let{size:n,min:r,max:i,padding:o}=e,s=n/2;return n>i-r?(i+r)/2:(r>=t-o-s&&(t=r+o+s),i<=t+o+s&&(t=i-o-s),t)}function KI(t){let e=t.options,n=e.arrowHeads&&e.arrowHeads.start,r=e.arrowHeads&&e.arrowHeads.end;return {startOpts:n,endOpts:r,startAdjust:OI(t,n),endAdjust:OI(t,r)}}function OI(t,e){if(!e||!e.display)return 0;let{length:n,width:r}=e,i=t.options.borderWidth/2,o={x:n,y:r+i};return Math.abs(p1(0,o,{x:0,y:i}))}function m1(t,e,n,r){if(!r||!r.display)return;let{length:i,width:o,fill:s,backgroundColor:c,borderColor:p}=r,h=Math.abs(e-i)+n;t.beginPath(),gd(t,r),Sl(t,r),t.moveTo(h,-o),t.lineTo(e+n,0),t.lineTo(h,o),s===true?(t.fillStyle=c||p,t.closePath(),t.fill(),t.shadowColor="transparent"):t.shadowColor=r.borderShadowColor,t.stroke();}function m7(t,e,n){let{x:r,y:i,x2:o,y2:s,centerX:c,centerY:p}=t,h=Math.atan2(s-i,o-r),v=C1(e.controlPoint,0),P={x:c+Cl(n,v.x,false),y:p+Cl(n,v.y,false)};return Uc(P,{x:c,y:p},h)}function RI(t,{x:e,y:n},{angle:r,adjust:i},o){!o||!o.display||(t.save(),t.translate(e,n),t.rotate(r),m1(t,0,-i,o),t.restore());}function g7(t,e,n,r){let{x:i,y:o,x2:s,y2:c,options:p}=e,{startOpts:h,endOpts:v,startAdjust:P,endAdjust:x}=KI(e),T={x:i,y:o},I={x:s,y:c},F=wI(T,n,I,0),A=wI(T,n,I,1)-Be,O=f1(T,n,I,P/r),N=f1(T,n,I,1-x/r),V=new Path2D;t.beginPath(),V.moveTo(O.x,O.y),V.quadraticCurveTo(n.x,n.y,N.x,N.y),t.shadowColor=p.borderShadowColor,t.stroke(V),e.path=V,e.ctx=t,RI(t,O,{angle:F,adjust:P},h),RI(t,N,{angle:A,adjust:x},v);}var Bc=class extends br{inRange(e,n,r,i){let o=this.options.rotation,s=this.options.borderWidth;if(r!=="x"&&r!=="y")return y7({x:e,y:n},this.getProps(["width","height","centerX","centerY"],i),o,s);let{x:c,y:p,x2:h,y2:v}=this.getProps(["x","y","x2","y2"],i),P=s/2,x=r==="y"?{start:p,end:v}:{start:c,end:h},T=Uc({x:e,y:n},this.getCenterPoint(i),Qn(-o));return T[r]>=x.start-P-Fc&&T[r]<=x.end+P+Fc}getCenterPoint(e){return md(this,e)}draw(e){let{width:n,height:r,centerX:i,centerY:o,options:s}=this;e.save(),S1(e,this.getCenterPoint(),s.rotation),gd(e,this.options),e.beginPath(),e.fillStyle=s.backgroundColor;let c=Sl(e,s);e.ellipse(i,o,r/2,n/2,Be/2,0,2*Be),e.fill(),c&&(e.shadowColor=s.borderShadowColor,e.stroke()),e.restore();}get label(){return this.elements&&this.elements[0]}resolveElementProperties(e,n){return WI(e,n,true)}};Bc.id="ellipseAnnotation";Bc.defaults={adjustScaleRange:true,backgroundShadowColor:"transparent",borderDash:[],borderDashOffset:0,borderShadowColor:"transparent",borderWidth:1,display:true,init:void 0,label:Object.assign({},Pl.defaults.label),rotation:0,shadowBlur:0,shadowOffsetX:0,shadowOffsetY:0,xMax:void 0,xMin:void 0,xScaleID:void 0,yMax:void 0,yMin:void 0,yScaleID:void 0,z:0};Bc.defaultRoutes={borderColor:"color",backgroundColor:"color"};Bc.descriptors={label:{_fallback:true}};function y7(t,e,n,r){let{width:i,height:o,centerX:s,centerY:c}=e,p=i/2,h=o/2;if(p<=0||h<=0)return false;let v=Qn(n||0),P=r/2||0,x=Math.cos(v),T=Math.sin(v),I=Math.pow(x*(t.x-s)+T*(t.y-c),2),F=Math.pow(T*(t.x-s)-x*(t.y-c),2);return I/Math.pow(p+P,2)+F/Math.pow(h+P,2)<=1.0001}var fd=class extends br{inRange(e,n,r,i){let{x:o,y:s,x2:c,y2:p,width:h}=this.getProps(["x","y","x2","y2","width"],i),v=this.options.borderWidth;if(r!=="x"&&r!=="y")return g8({x:e,y:n},this.getCenterPoint(i),h/2,v);let P=v/2,x=r==="y"?{start:s,end:p,value:n}:{start:o,end:c,value:e};return x.value>=x.start-P&&x.value<=x.end+P}getCenterPoint(e){return md(this,e)}draw(e){let n=this.options,r=n.borderWidth;if(n.radius<.1)return;e.save(),e.fillStyle=n.backgroundColor,gd(e,n);let i=Sl(e,n);E8(e,this,this.centerX,this.centerY),i&&!ky(n.pointStyle)&&(e.shadowColor=n.borderShadowColor,e.stroke()),e.restore(),n.borderWidth=r;}resolveElementProperties(e,n){let r=HI(e,n);return r.initProperties=Lf(e,r,n,true),r}};fd.id="pointAnnotation";fd.defaults={adjustScaleRange:true,backgroundShadowColor:"transparent",borderDash:[],borderDashOffset:0,borderShadowColor:"transparent",borderWidth:1,display:true,init:void 0,pointStyle:"circle",radius:10,rotation:0,shadowBlur:0,shadowOffsetX:0,shadowOffsetY:0,xAdjust:0,xMax:void 0,xMin:void 0,xScaleID:void 0,xValue:void 0,yAdjust:0,yMax:void 0,yMin:void 0,yScaleID:void 0,yValue:void 0,z:0};fd.defaultRoutes={borderColor:"color",backgroundColor:"color"};var hd=class extends br{inRange(e,n,r,i){if(r!=="x"&&r!=="y")return this.options.radius>=.1&&this.elements.length>1&&v7(this.elements,e,n,i);let o=Uc({x:e,y:n},this.getCenterPoint(i),Qn(-this.options.rotation)),s=this.elements.map(h=>r==="y"?h.bY:h.bX),c=Math.min(...s),p=Math.max(...s);return o[r]>=c&&o[r]<=p}getCenterPoint(e){return md(this,e)}draw(e){let{elements:n,options:r}=this;e.save(),e.beginPath(),e.fillStyle=r.backgroundColor,gd(e,r);let i=Sl(e,r),o=true;for(let s of n)o?(e.moveTo(s.x,s.y),o=false):e.lineTo(s.x,s.y);e.closePath(),e.fill(),i&&(e.shadowColor=r.borderShadowColor,e.stroke()),e.restore();}resolveElementProperties(e,n){let r=HI(e,n),{sides:i,rotation:o}=n,s=[],c=2*Be/i,p=o*lf;for(let h=0;h<i;h++,p+=c){let v=b7(r,n,p);v.initProperties=Lf(e,r,n),s.push(v);}return r.elements=s,r}};hd.id="polygonAnnotation";hd.defaults={adjustScaleRange:true,backgroundShadowColor:"transparent",borderCapStyle:"butt",borderDash:[],borderDashOffset:0,borderJoinStyle:"miter",borderShadowColor:"transparent",borderWidth:1,display:true,init:void 0,point:{radius:0},radius:10,rotation:0,shadowBlur:0,shadowOffsetX:0,shadowOffsetY:0,sides:3,xAdjust:0,xMax:void 0,xMin:void 0,xScaleID:void 0,xValue:void 0,yAdjust:0,yMax:void 0,yMin:void 0,yScaleID:void 0,yValue:void 0,z:0};hd.defaultRoutes={borderColor:"color",backgroundColor:"color"};function b7({centerX:t,centerY:e},{radius:n,borderWidth:r},i){let o=r/2,s=Math.sin(i),c=Math.cos(i),p={x:t+s*n,y:e-c*n};return {type:"point",optionScope:"point",properties:{x:p.x,y:p.y,centerX:p.x,centerY:p.y,bX:t+s*(n+o),bY:e-c*(n+o)}}}function v7(t,e,n,r){let i=false,o=t[t.length-1].getProps(["bX","bY"],r);for(let s of t){let c=s.getProps(["bX","bY"],r);c.bY>n!=o.bY>n&&e<(o.bX-c.bX)*(n-c.bY)/(o.bY-c.bY)+c.bX&&(i=!i),o=c;}return i}var vl={box:Pl,ellipse:Bc,label:Nc,line:Lc,point:fd,polygon:hd};Object.keys(vl).forEach(t=>{ke.describe(`elements.${vl[t].id}`,{_fallback:"plugins.annotation.common"});});var C7={update:Object.assign},S7=E1.concat(wy),FI=(t,e)=>Te(e)?y1(t,e):t,g1=t=>t==="color"||t==="font";function T1(t="line"){return vl[t]?t:(console.warn(`Unknown annotation type: '${t}', defaulting to 'line'`),"line")}function P7(t,e,n,r){let i=E7(t,n.animations,r),o=e.annotations,s=w7(e.elements,o);for(let c=0;c<o.length;c++){let p=o[c],h=XI(s,c,p.type),v=p.setContext(T7(t,h,p)),P=h.resolveElementProperties(t,v);P.skip=x7(P),"elements"in P&&(_7(h,P.elements,v,i),delete P.elements),Fn(h.x)||Object.assign(h,P),Object.assign(h,P.initProperties),P.options=ZI(v),i.update(h,P);}}function x7(t){return isNaN(t.x)||isNaN(t.y)}function E7(t,e,n){return n==="reset"||n==="none"||n==="resize"?C7:new sd(t,e)}function _7(t,e,n,r){let i=t.elements||(t.elements=[]);i.length=e.length;for(let o=0;o<e.length;o++){let s=e[o],c=s.properties,p=XI(i,o,s.type,s.initProperties),h=n[s.optionScope].override(s);c.options=ZI(h),r.update(p,c);}}function XI(t,e,n,r){let i=vl[T1(n)],o=t[e];return (!o||!(o instanceof i))&&(o=t[e]=new i,Object.assign(o,r)),o}function ZI(t){let e=vl[T1(t.type)],n={};n.id=t.id,n.type=t.type,n.drawTime=t.drawTime,Object.assign(n,y1(t,e.defaults),y1(t,e.defaultRoutes));for(let r of S7)n[r]=t[r];return n}function y1(t,e){let n={};for(let r of Object.keys(e)){let i=e[r],o=t[r];g1(r)&&He(o)?n[r]=o.map(s=>FI(s,i)):n[r]=FI(o,i);}return n}function T7(t,e,n){return e.$context||(e.$context=Object.assign(Object.create(t.getContext()),{element:e,id:n.id,type:"annotation"}))}function w7(t,e){let n=e.length,r=t.length;if(r<n){let i=n-r;t.splice(r,0,...new Array(i));}else r>n&&t.splice(n,r-n);return t}var I7="2.2.1",bl=new Map,k7=E1.concat(wy),JI={id:"annotation",version:I7,beforeRegister(){y8("chart.js","3.7",bo.version);},afterRegister(){bo.register(vl);},afterUnregister(){bo.unregister(vl);},beforeInit(t){bl.set(t,{annotations:[],elements:[],visibleElements:[],listeners:{},listened:false,moveListened:false,hooks:{},hooked:false,hovered:[]});},beforeUpdate(t,e,n){let r=bl.get(t),i=r.annotations=[],o=n.annotations;Te(o)?Object.keys(o).forEach(s=>{let c=o[s];Te(c)&&(c.id=s,i.push(c));}):He(o)&&i.push(...o),V8(i,t.scales);},afterDataLimits(t,e){let n=bl.get(t);j8(t,e.scale,n.annotations.filter(r=>r.display&&r.adjustScaleRange));},afterUpdate(t,e,n){let r=bl.get(t);L8(t,r,n),P7(t,r,n,e.mode),r.visibleElements=r.elements.filter(i=>!i.skip&&i.options.display),G8(t,r,n);},beforeDatasetsDraw(t,e,n){_y(t,"beforeDatasetsDraw",n.clip);},afterDatasetsDraw(t,e,n){_y(t,"afterDatasetsDraw",n.clip);},beforeDraw(t,e,n){_y(t,"beforeDraw",n.clip);},afterDraw(t,e,n){_y(t,"afterDraw",n.clip);},beforeEvent(t,e,n){let r=bl.get(t);B8(r,e.event,n)&&(e.changed=true);},afterDestroy(t){bl.delete(t);},_getState(t){return bl.get(t)},defaults:{animations:{numbers:{properties:["x","y","x2","y2","width","height","centerX","centerY","pointX","pointY","radius"],type:"number"}},clip:true,interaction:{mode:void 0,axis:void 0,intersect:void 0},common:{drawTime:"afterDatasetsDraw",init:false,label:{}}},descriptors:{_indexable:false,_scriptable:t=>!k7.includes(t)&&t!=="init",annotations:{_allKeys:false,_fallback:(t,e)=>`elements.${vl[T1(e.type)].id}`},interaction:{_fallback:true},common:{label:{_indexable:g1,_fallback:true},_indexable:g1}},additionalOptionScopes:[""]};function _y(t,e,n){let{ctx:r,chartArea:i}=t,o=bl.get(t);n&&fl(r,i);let s=D7(o.visibleElements,e).sort((c,p)=>c.element.options.z-p.element.options.z);for(let c of s)A7(r,i,o,c);n&&hl(r);}function D7(t,e){let n=[];for(let r of t)if(r.options.drawTime===e&&n.push({element:r,main:true}),r.elements&&r.elements.length)for(let i of r.elements)i.options.display&&i.options.drawTime===e&&n.push({element:i});return n}function A7(t,e,n,r){let i=r.element;r.main?(CI(n,i,"beforeDraw"),i.draw(t,e),CI(n,i,"afterDraw")):i.draw(t,e);}var I1=bo.version,O7=I1?(t,e)=>t.parse(e):(t,e)=>e;function R7(t,e){let n=Vi(e)?parseFloat(e):O7(t,e);return t.getPixelForValue(n)}var tk=t=>t&&t.right>t.left&&t.bottom>t.top;function ek(t,e,n){return e==="r"?t.createRadialGradient(n.xCenter,n.yCenter,0,n.xCenter,n.yCenter,n.drawingArea):e==="y"?t.createLinearGradient(0,n.bottom,0,n.top):t.createLinearGradient(n.left,0,n.right,0)}function nk(t,e){e.forEach(function(n){t.addColorStop(n.stop,n.color.rgbString());});}function rk(t,e,n){if(t.options.has(e.key)){let i=t.options.get(e.key).filter(o=>o.datasetIndex===n);if(i.length)return i[0]}}function ik(t,e){if(t.type==="radialLinear"){let o=t.getDistanceFromCenterForValue(e);return {pixel:o,stop:o/t.drawingArea}}let n=t.options.reverse,r=R7(t,e),i=t.getDecimalForPixel(r);return {pixel:r,stop:n?1-i:i}}var w1=t=>t<=.0031308?t*12.92:Math.pow(t,1/2.4)*1.055-.055,yd=t=>t<=.04045?t/12.92:Math.pow((t+.055)/1.055,2.4);function F7(t,e,n){let r=e.color.rgb,i=yd(r.r/255),o=yd(r.g/255),s=yd(r.b/255),c=n.color.rgb,p=yd(c.r/255),h=yd(c.g/255),v=yd(c.b/255);return Ic({r:Math.round(w1(i+t*(p-i))*255),g:Math.round(w1(o+t*(h-o))*255),b:Math.round(w1(s+t*(v-s))*255),a:r.a+t*Math.abs(c.a-r.a)})}function M7(t,e,n,r){let i=rk(t,e,n);if(!i||!i.stopColors.length)return;let{stop:o}=ik(i.scale,r),s,c;for(let p of i.stopColors){if(p.stop===o)return p.color;p.stop<o?s=p:p.stop>o&&!c&&(c=p);}return c?F7(o,s,c):s}var ok=[{key:"backgroundColor",legendItemKey:"fillStyle"},{key:"borderColor",legendItemKey:"strokeStyle"}],N7=(t,e)=>e.labels&&e.labels.font&&Fn(e.labels.font.size)?e.labels.font.size:t.options.font.size;function L7(t,e,n,r,i){let o=rk(t,n,r.datasetIndex);if(!o||!o.stopColors.length)return;let s=ek(e,o.axis,i);nk(s,o.stopColors),r[n.legendItemKey]=s;}function B7(t,{boxWidth:e,boxHeight:n}){return {top:t.top,left:t.left,bottom:t.top+n,right:t.left+e,xCenter:t.left+e/2,yCenter:t.top+n/2,drawingArea:Math.max(e,n)/2}}function U7(t,e,n,r){let i=t.legend.legendHitBoxes[n.datasetIndex],o=B7(i,r);tk(o)&&ok.forEach(function(s){L7(e,t.ctx,s,n,o);});}function $7(t,e,n,r){for(let i of t.legend.legendItems)ok.forEach(function(o){let s=n.data[i.index],c=M7(e,o,r,s);c&&c.valid&&(i[o.legendItemKey]=c.rgbString());});}function G7(t,e){let n=t.legend,r=n.options,i=r.labels.boxHeight?r.labels.boxHeight:N7(t,r),o=r.labels.boxWidth,s=t.data.datasets;for(let c=0;c<s.length;c++){let p=n.legendItems[c];p.datasetIndex===c?U7(t,e,p,{boxWidth:o,boxHeight:i}):$7(t,e,s[c],c);}}var Dy=new Map,j7=I1?(t,e)=>t[e+"Scale"]:(t,e)=>t.controller["_"+e+"Scale"];function V7(t,e,n){for(let r of Object.keys(e)){let{pixel:i,stop:o}=ik(t,r);if(isFinite(i)&&isFinite(o)){let s=Ic(e[r]);s&&s.valid&&n.push({stop:Math.max(0,Math.min(1,o)),color:s});}}n.sort((r,i)=>r.stop-i.stop);}function z7(t,e,n,r){e[n]=r,t.dataset&&(t.dataset.options?t.dataset.options[n]=r:t.dataset[n]=r);}function H7(t,e,n,r){let i=t.options.get(n);return i?e.hidden||(i=i.filter(o=>o.datasetIndex!==r),t.options.set(n,i)):(i=[],t.options.set(n,i)),i}function W7(t,e,n,r,i){let o=t.ctx,s=t.getDatasetMeta(i);if(!s.hidden)for(let[c,p]of Object.entries(n)){let{axis:h,colors:v}=p;if(!v)continue;let P=j7(s,h);if(!P){console.warn(`Scale not found for '${h}'-axis in datasets[${i}] of chart id ${t.id}, skipping.`);continue}let x=H7(e,s,c,i),T={datasetIndex:i,axis:h,scale:P,stopColors:[]};x.push(T);let I=ek(o,h,P);V7(P,v,T.stopColors),T.stopColors.length&&(nk(I,T.stopColors),z7(s,r,c,I));}}var ak={id:"gradient",beforeInit(t){let e={};e.options=new Map,Dy.set(t,e);},beforeDatasetsUpdate(t){let e=t.chartArea;if(!tk(e))return;let n=Dy.get(t),r=t.data.datasets;for(let i=0;i<r.length;i++){let o=r[i],s=o.gradient;s&&W7(t,n,s,o,i);}},afterUpdate(t){let e=Dy.get(t);t.legend&&t.legend.options.display!==false&&I1&&G7(t,e);},destroy(t){Dy.delete(t);}};var q7=[Rc,cd,ds,nI,rI,eI,mI,us,Go,tI,cs,JI,ak];bo.register(...q7);function Ay(t){let e=ve(),n=e==null?void 0:e.stigg,r=e==null?void 0:e.updatedAt,i=Uv.useCallback(()=>ce(null,null,function*(){if(!n||!n.isCustomerLoaded)return null;try{let p={currencyId:t.currencyId,timeRange:t.timeRange};return yield n.getCreditUsage(p)}catch(p){throw console.error(p),p}}),[n,t.currencyId,t.timeRange,r]),{data:o,error:s,isLoading:c}=co({func:i});return Uv.useMemo(()=>({creditUsage:o,isLoading:c,error:s}),[o,s,c])}var sk={id:"redrawBeforeFirstDrawPlugin",beforeDraw(t){t.$rendered||(t.$rendered=true,t.update("none"));}};var k1=(t,e=1)=>{let n=Math.round(e*255).toString(16).padStart(2,"0");return `${t}${n}`};var D1=t=>t.palette.text.secondary,A1=t=>t.palette.outlinedBorder,O1=t=>({family:t.typography.fontFamily,size:parseInt(t.typography.body.fontSize)});function R1(t){let e=["#4caf50","#2196f3","#ff5722","#ff9800","#e91e63","#3f51b5","#00bcd4","#81c784","#64b5f6","#ff8a65","#ffb74d","#f06292","#7986cb","#4dd0e1","#a5d6a7","#90caf9","#ffab91","#ffcc80","#f48fb1","#9fa8da","#80deea"];return e[t%e.length]}function K7(t){let e=[],n=new Date;switch(t){case yi.LastDay:{let r=new Date(n);r.setHours(r.getHours()-23),r.setMinutes(0,0,0);for(let i=0;i<24;i++){let o=new Date(r);o.setHours(o.getHours()+i),e.push(o.toLocaleTimeString("en-US",{hour:"2-digit",minute:"2-digit"}));}break}case yi.LastWeek:{for(let r=6;r>=0;r--){let i=new Date(n);i.setDate(i.getDate()-r),e.push(i.toLocaleDateString("en-US",{month:"short",day:"2-digit"}));}break}case yi.LastYear:{for(let r=11;r>=0;r--){let i=new Date(n);i.setMonth(i.getMonth()-r),e.push(i.toLocaleDateString("en-US",{month:"short",year:"2-digit"}));}break}case yi.LastMonth:default:{for(let r=29;r>=0;r--){let i=new Date(n);i.setDate(i.getDate()-r),e.push(i.toLocaleDateString("en-US",{month:"short",day:"2-digit"}));}break}}return e}function X7(t,e){let n=new Date(t);switch(n.setMinutes(0,0,0),e){case yi.LastDay:return n.toLocaleTimeString("en-US",{hour:"2-digit",minute:"2-digit"});case yi.LastYear:return t.toLocaleDateString("en-US",{month:"short",year:"2-digit"});case yi.LastWeek:case yi.LastMonth:default:return t.toLocaleDateString("en-US",{month:"short",day:"2-digit"})}}function Z7(t,e){return {responsive:true,maintainAspectRatio:false,interaction:{mode:"point",intersect:true},elements:{bar:{borderRadius:4,borderSkipped:"bottom"}},plugins:{legend:{display:false},tooltip:{enabled:false,external:e},datalabels:{display:false}},scales:{x:{type:"category",stacked:true,ticks:{color:D1(t),font:O1(t),maxRotation:45,maxTicksLimit:15},grid:{color:A1(t),drawOnChartArea:false,drawTicks:false}},y:{type:"linear",stacked:true,beginAtZero:true,ticks:{color:D1(t),font:O1(t),callback:n=>gr(Number(n))},grid:{color:k1(A1(t),.5),drawOnChartArea:true,drawTicks:false,borderDash:[5,5]}}}}}function lk(t,e,n,r){let i=K7(r);if(!t||!t.series||t.series.length===0)return {data:null,options:null};let o=t.series.map((p,h)=>{let v=p.featureName,P=new Map;p.points.forEach(I=>{let F=X7(new Date(I.timestamp),r),A=P.get(F)||0;P.set(F,A+I.value);});let x=i.map(I=>P.get(I)||0),T=R1(h);return {label:v,data:x,backgroundColor:k1(T,.8),borderColor:T,borderWidth:1}}).reverse(),s={labels:i,datasets:o},c=Z7(e,n);return {data:s,options:c}}var i9=300;function uk(t,e){let n=e.dataPoints[0],r=n.parsed.y,i=t.scales.y,o=r/i.max*(i.bottom-i.top),s=e.caretY+o/2,c=t.getDatasetMeta(n.datasetIndex).data[n.dataIndex],p=c.x-c.width/2,h=t.canvas.offsetTop+s,v=t.canvas.offsetLeft+p;return {top:h,left:v}}function o9(t,e){let n=t.canvas.offsetTop+e.caretY,r=t.canvas.offsetLeft+e.caretX;return {top:n,left:r}}function dk(t,e=o9){let[n,r]=Uv.useState(0),[i,o]=Uv.useState(0),[s,c]=Uv.useState(false),[p,h]=Uv.useState(),v=Uv.useCallback(x=>{let{chart:T,tooltip:I}=x;if(I.opacity===0){c(false);return}let{top:F,left:A}=e(T,I);o(A),r(F),h(t(I)),c(true);},[t,e]);return {tooltipInfo:{positionTop:n,positionLeft:i,isOpen:s,payload:p},tooltipHandler:v}}var a9=Q(material.Box)`
5648
+ `):t}function bU(t,e){let{element:n,datasetIndex:r,index:i}=e,o=t.getDatasetMeta(r).controller,{label:s,value:c}=o.getLabelAndValue(i);return {chart:t,label:s,parsed:o.getParsed(i),raw:t.data.datasets[r].data[i],formattedValue:c,dataset:o.getDataset(),dataIndex:i,datasetIndex:r,element:n}}function _w(t,e){let n=t.chart.ctx,{body:r,footer:i,title:o}=t,{boxWidth:s,boxHeight:c}=e,p=Sn(e.bodyFont),h=Sn(e.titleFont),v=Sn(e.footerFont),P=o.length,x=i.length,T=r.length,I=$n(e.padding),R=I.height,A=0,O=r.reduce((G,X)=>G+X.before.length+X.lines.length+X.after.length,0);if(O+=t.beforeBody.length+t.afterBody.length,P&&(R+=P*h.lineHeight+(P-1)*e.titleSpacing+e.titleMarginBottom),O){let G=e.displayColors?Math.max(c,p.lineHeight):p.lineHeight;R+=T*G+(O-T)*p.lineHeight+(O-1)*e.bodySpacing;}x&&(R+=e.footerMarginTop+x*v.lineHeight+(x-1)*e.footerSpacing);let N=0,V=function(G){A=Math.max(A,n.measureText(G).width+N);};return n.save(),n.font=h.string,tn(t.title,V),n.font=p.string,tn(t.beforeBody.concat(t.afterBody),V),N=e.displayColors?s+2+e.boxPadding:0,tn(r,G=>{tn(G.before,V),tn(G.lines,V),tn(G.after,V);}),N=0,n.font=v.string,tn(t.footer,V),n.restore(),A+=I.width,{width:A,height:R}}function vU(t,e){let{y:n,height:r}=e;return n<r/2?"top":n>t.height-r/2?"bottom":"center"}function CU(t,e,n,r){let{x:i,width:o}=r,s=n.caretSize+n.caretPadding;if(t==="left"&&i+o+s>e.width||t==="right"&&i-o-s<0)return true}function SU(t,e,n,r){let{x:i,width:o}=n,{width:s,chartArea:{left:c,right:p}}=t,h="center";return r==="center"?h=i<=(c+p)/2?"left":"right":i<=o/2?h="left":i>=s-o/2&&(h="right"),CU(h,t,e,n)&&(h="center"),h}function Tw(t,e,n){let r=n.yAlign||e.yAlign||vU(t,n);return {xAlign:n.xAlign||e.xAlign||SU(t,e,n,r),yAlign:r}}function PU(t,e){let{x:n,width:r}=t;return e==="right"?n-=r:e==="center"&&(n-=r/2),n}function xU(t,e,n){let{y:r,height:i}=t;return e==="top"?r+=n:e==="bottom"?r-=i+n:r-=i/2,r}function ww(t,e,n,r){let{caretSize:i,caretPadding:o,cornerRadius:s}=t,{xAlign:c,yAlign:p}=n,h=i+o,{topLeft:v,topRight:P,bottomLeft:x,bottomRight:T}=$o(s),I=PU(e,c),R=xU(e,p,h);return p==="center"?c==="left"?I+=h:c==="right"&&(I-=h):c==="left"?I-=Math.max(v,x)+i:c==="right"&&(I+=Math.max(P,T)+i),{x:Nr(I,0,r.width-e.width),y:Nr(R,0,r.height-e.height)}}function sy(t,e,n){let r=$n(n.padding);return e==="center"?t.x+t.width/2:e==="right"?t.x+t.width-r.right:t.x+r.left}function Iw(t){return va([],ls(t))}function EU(t,e,n){return ba(t,{tooltip:e,tooltipItems:n,type:"tooltip"})}function kw(t,e){let n=e&&e.dataset&&e.dataset.tooltip&&e.dataset.tooltip.callbacks;return n?t.override(n):t}var Af=class extends br{constructor(e){super(),this.opacity=0,this._active=[],this._eventPosition=void 0,this._size=void 0,this._cachedAnimations=void 0,this._tooltipItems=[],this.$animations=void 0,this.$context=void 0,this.chart=e.chart||e._chart,this._chart=this.chart,this.options=e.options,this.dataPoints=void 0,this.title=void 0,this.beforeBody=void 0,this.body=void 0,this.afterBody=void 0,this.footer=void 0,this.xAlign=void 0,this.yAlign=void 0,this.x=void 0,this.y=void 0,this.height=void 0,this.width=void 0,this.caretX=void 0,this.caretY=void 0,this.labelColors=void 0,this.labelPointStyles=void 0,this.labelTextColors=void 0;}initialize(e){this.options=e,this._cachedAnimations=void 0,this.$context=void 0;}_resolveAnimations(){let e=this._cachedAnimations;if(e)return e;let n=this.chart,r=this.options.setContext(this.getContext()),i=r.enabled&&n.options.animation&&r.animations,o=new sd(this.chart,i);return i._cacheable&&(this._cachedAnimations=Object.freeze(o)),o}getContext(){return this.$context||(this.$context=EU(this.chart.getContext(),this,this._tooltipItems))}getTitle(e,n){let{callbacks:r}=n,i=r.beforeTitle.apply(this,[e]),o=r.title.apply(this,[e]),s=r.afterTitle.apply(this,[e]),c=[];return c=va(c,ls(i)),c=va(c,ls(o)),c=va(c,ls(s)),c}getBeforeBody(e,n){return Iw(n.callbacks.beforeBody.apply(this,[e]))}getBody(e,n){let{callbacks:r}=n,i=[];return tn(e,o=>{let s={before:[],lines:[],after:[]},c=kw(r,o);va(s.before,ls(c.beforeLabel.call(this,o))),va(s.lines,c.label.call(this,o)),va(s.after,ls(c.afterLabel.call(this,o))),i.push(s);}),i}getAfterBody(e,n){return Iw(n.callbacks.afterBody.apply(this,[e]))}getFooter(e,n){let{callbacks:r}=n,i=r.beforeFooter.apply(this,[e]),o=r.footer.apply(this,[e]),s=r.afterFooter.apply(this,[e]),c=[];return c=va(c,ls(i)),c=va(c,ls(o)),c=va(c,ls(s)),c}_createItems(e){let n=this._active,r=this.chart.data,i=[],o=[],s=[],c=[],p,h;for(p=0,h=n.length;p<h;++p)c.push(bU(this.chart,n[p]));return e.filter&&(c=c.filter((v,P,x)=>e.filter(v,P,x,r))),e.itemSort&&(c=c.sort((v,P)=>e.itemSort(v,P,r))),tn(c,v=>{let P=kw(e.callbacks,v);i.push(P.labelColor.call(this,v)),o.push(P.labelPointStyle.call(this,v)),s.push(P.labelTextColor.call(this,v));}),this.labelColors=i,this.labelPointStyles=o,this.labelTextColors=s,this.dataPoints=c,c}update(e,n){let r=this.options.setContext(this.getContext()),i=this._active,o,s=[];if(!i.length)this.opacity!==0&&(o={opacity:0});else {let c=Pf[r.position].call(this,i,this._eventPosition);s=this._createItems(r),this.title=this.getTitle(s,r),this.beforeBody=this.getBeforeBody(s,r),this.body=this.getBody(s,r),this.afterBody=this.getAfterBody(s,r),this.footer=this.getFooter(s,r);let p=this._size=_w(this,r),h=Object.assign({},c,p),v=Tw(this.chart,r,h),P=ww(r,h,v,this.chart);this.xAlign=v.xAlign,this.yAlign=v.yAlign,o={opacity:1,x:P.x,y:P.y,width:p.width,height:p.height,caretX:c.x,caretY:c.y};}this._tooltipItems=s,this.$context=void 0,o&&this._resolveAnimations().update(this,o),e&&r.external&&r.external.call(this,{chart:this.chart,tooltip:this,replay:n});}drawCaret(e,n,r,i){let o=this.getCaretPosition(e,r,i);n.lineTo(o.x1,o.y1),n.lineTo(o.x2,o.y2),n.lineTo(o.x3,o.y3);}getCaretPosition(e,n,r){let{xAlign:i,yAlign:o}=this,{caretSize:s,cornerRadius:c}=r,{topLeft:p,topRight:h,bottomLeft:v,bottomRight:P}=$o(c),{x,y:T}=e,{width:I,height:R}=n,A,O,N,V,G,X;return o==="center"?(G=T+R/2,i==="left"?(A=x,O=A-s,V=G+s,X=G-s):(A=x+I,O=A+s,V=G-s,X=G+s),N=A):(i==="left"?O=x+Math.max(p,v)+s:i==="right"?O=x+I-Math.max(h,P)-s:O=this.caretX,o==="top"?(V=T,G=V-s,A=O-s,N=O+s):(V=T+R,G=V+s,A=O+s,N=O-s),X=V),{x1:A,x2:O,x3:N,y1:V,y2:G,y3:X}}drawTitle(e,n,r){let i=this.title,o=i.length,s,c,p;if(o){let h=ml(r.rtl,this.x,this.width);for(e.x=sy(this,r.titleAlign,r),n.textAlign=h.textAlign(r.titleAlign),n.textBaseline="middle",s=Sn(r.titleFont),c=r.titleSpacing,n.fillStyle=r.titleColor,n.font=s.string,p=0;p<o;++p)n.fillText(i[p],h.x(e.x),e.y+s.lineHeight/2),e.y+=s.lineHeight+c,p+1===o&&(e.y+=r.titleMarginBottom-c);}}_drawColorBox(e,n,r,i,o){let s=this.labelColors[r],c=this.labelPointStyles[r],{boxHeight:p,boxWidth:h,boxPadding:v}=o,P=Sn(o.bodyFont),x=sy(this,"left",o),T=i.x(x),I=p<P.lineHeight?(P.lineHeight-p)/2:0,R=n.y+I;if(o.usePointStyle){let A={radius:Math.min(h,p)/2,pointStyle:c.pointStyle,rotation:c.rotation,borderWidth:1},O=i.leftForLtr(T,h)+h/2,N=R+p/2;e.strokeStyle=o.multiKeyBackground,e.fillStyle=o.multiKeyBackground,pf(e,A,O,N),e.strokeStyle=s.borderColor,e.fillStyle=s.backgroundColor,pf(e,A,O,N);}else {e.lineWidth=Te(s.borderWidth)?Math.max(...Object.values(s.borderWidth)):s.borderWidth||1,e.strokeStyle=s.borderColor,e.setLineDash(s.borderDash||[]),e.lineDashOffset=s.borderDashOffset||0;let A=i.leftForLtr(T,h-v),O=i.leftForLtr(i.xPlus(T,1),h-v-2),N=$o(s.borderRadius);Object.values(N).some(V=>V!==0)?(e.beginPath(),e.fillStyle=o.multiKeyBackground,os(e,{x:A,y:R,w:h,h:p,radius:N}),e.fill(),e.stroke(),e.fillStyle=s.backgroundColor,e.beginPath(),os(e,{x:O,y:R+1,w:h-2,h:p-2,radius:N}),e.fill()):(e.fillStyle=o.multiKeyBackground,e.fillRect(A,R,h,p),e.strokeRect(A,R,h,p),e.fillStyle=s.backgroundColor,e.fillRect(O,R+1,h-2,p-2));}e.fillStyle=this.labelTextColors[r];}drawBody(e,n,r){let{body:i}=this,{bodySpacing:o,bodyAlign:s,displayColors:c,boxHeight:p,boxWidth:h,boxPadding:v}=r,P=Sn(r.bodyFont),x=P.lineHeight,T=0,I=ml(r.rtl,this.x,this.width),R=function(U){n.fillText(U,I.x(e.x+T),e.y+x/2),e.y+=x+o;},A=I.textAlign(s),O,N,V,G,X,nt,st;for(n.textAlign=s,n.textBaseline="middle",n.font=P.string,e.x=sy(this,A,r),n.fillStyle=r.bodyColor,tn(this.beforeBody,R),T=c&&A!=="right"?s==="center"?h/2+v:h+2+v:0,G=0,nt=i.length;G<nt;++G){for(O=i[G],N=this.labelTextColors[G],n.fillStyle=N,tn(O.before,R),V=O.lines,c&&V.length&&(this._drawColorBox(n,e,G,I,r),x=Math.max(P.lineHeight,p)),X=0,st=V.length;X<st;++X)R(V[X]),x=P.lineHeight;tn(O.after,R);}T=0,x=P.lineHeight,tn(this.afterBody,R),e.y-=o;}drawFooter(e,n,r){let i=this.footer,o=i.length,s,c;if(o){let p=ml(r.rtl,this.x,this.width);for(e.x=sy(this,r.footerAlign,r),e.y+=r.footerMarginTop,n.textAlign=p.textAlign(r.footerAlign),n.textBaseline="middle",s=Sn(r.footerFont),n.fillStyle=r.footerColor,n.font=s.string,c=0;c<o;++c)n.fillText(i[c],p.x(e.x),e.y+s.lineHeight/2),e.y+=s.lineHeight+r.footerSpacing;}}drawBackground(e,n,r,i){let{xAlign:o,yAlign:s}=this,{x:c,y:p}=e,{width:h,height:v}=r,{topLeft:P,topRight:x,bottomLeft:T,bottomRight:I}=$o(i.cornerRadius);n.fillStyle=i.backgroundColor,n.strokeStyle=i.borderColor,n.lineWidth=i.borderWidth,n.beginPath(),n.moveTo(c+P,p),s==="top"&&this.drawCaret(e,n,r,i),n.lineTo(c+h-x,p),n.quadraticCurveTo(c+h,p,c+h,p+x),s==="center"&&o==="right"&&this.drawCaret(e,n,r,i),n.lineTo(c+h,p+v-I),n.quadraticCurveTo(c+h,p+v,c+h-I,p+v),s==="bottom"&&this.drawCaret(e,n,r,i),n.lineTo(c+T,p+v),n.quadraticCurveTo(c,p+v,c,p+v-T),s==="center"&&o==="left"&&this.drawCaret(e,n,r,i),n.lineTo(c,p+P),n.quadraticCurveTo(c,p,c+P,p),n.closePath(),n.fill(),i.borderWidth>0&&n.stroke();}_updateAnimationTarget(e){let n=this.chart,r=this.$animations,i=r&&r.x,o=r&&r.y;if(i||o){let s=Pf[e.position].call(this,this._active,this._eventPosition);if(!s)return;let c=this._size=_w(this,e),p=Object.assign({},s,this._size),h=Tw(n,e,p),v=ww(e,p,h,n);(i._to!==v.x||o._to!==v.y)&&(this.xAlign=h.xAlign,this.yAlign=h.yAlign,this.width=c.width,this.height=c.height,this.caretX=s.x,this.caretY=s.y,this._resolveAnimations().update(this,v));}}_willRender(){return !!this.opacity}draw(e){let n=this.options.setContext(this.getContext()),r=this.opacity;if(!r)return;this._updateAnimationTarget(n);let i={width:this.width,height:this.height},o={x:this.x,y:this.y};r=Math.abs(r)<.001?0:r;let s=$n(n.padding),c=this.title.length||this.beforeBody.length||this.body.length||this.afterBody.length||this.footer.length;n.enabled&&c&&(e.save(),e.globalAlpha=r,this.drawBackground(o,e,i,n),ty(e,n.textDirection),o.y+=s.top,this.drawTitle(o,e,n),this.drawBody(o,e,n),this.drawFooter(o,e,n),ey(e,n.textDirection),e.restore());}getActiveElements(){return this._active||[]}setActiveElements(e,n){let r=this._active,i=e.map(({datasetIndex:c,index:p})=>{let h=this.chart.getDatasetMeta(c);if(!h)throw new Error("Cannot find a dataset at index "+c);return {datasetIndex:c,element:h.data[p],index:p}}),o=!id(r,i),s=this._positionChanged(i,n);(o||s)&&(this._active=i,this._eventPosition=n,this._ignoreReplayEvents=true,this.update(true));}handleEvent(e,n,r=true){if(n&&this._ignoreReplayEvents)return false;this._ignoreReplayEvents=false;let i=this.options,o=this._active||[],s=this._getActiveElements(e,o,n,r),c=this._positionChanged(s,e),p=n||!id(s,o)||c;return p&&(this._active=s,(i.enabled||i.external)&&(this._eventPosition={x:e.x,y:e.y},this.update(true,n))),p}_getActiveElements(e,n,r,i){let o=this.options;if(e.type==="mouseout")return [];if(!i)return n;let s=this.chart.getElementsAtEventForMode(e,o.mode,o,r);return o.reverse&&s.reverse(),s}_positionChanged(e,n){let{caretX:r,caretY:i,options:o}=this,s=Pf[o.position].call(this,e,n);return s!==false&&(r!==s.x||i!==s.y)}};Af.positioners=Pf;var rI={id:"tooltip",_element:Af,positioners:Pf,afterInit(t,e,n){n&&(t.tooltip=new Af({chart:t,options:n}));},beforeUpdate(t,e,n){t.tooltip&&t.tooltip.initialize(n);},reset(t,e,n){t.tooltip&&t.tooltip.initialize(n);},afterDraw(t){let e=t.tooltip;if(e&&e._willRender()){let n={tooltip:e};if(t.notifyPlugins("beforeTooltipDraw",n)===false)return;e.draw(t.ctx),t.notifyPlugins("afterTooltipDraw",n);}},afterEvent(t,e){if(t.tooltip){let n=e.replay;t.tooltip.handleEvent(e.event,n,e.inChartArea)&&(e.changed=true);}},defaults:{enabled:true,external:null,position:"average",backgroundColor:"rgba(0,0,0,0.8)",titleColor:"#fff",titleFont:{weight:"bold"},titleSpacing:2,titleMarginBottom:6,titleAlign:"left",bodyColor:"#fff",bodySpacing:2,bodyFont:{},bodyAlign:"left",footerColor:"#fff",footerSpacing:2,footerMarginTop:6,footerFont:{weight:"bold"},footerAlign:"left",padding:6,caretPadding:2,caretSize:5,cornerRadius:6,boxHeight:(t,e)=>e.bodyFont.size,boxWidth:(t,e)=>e.bodyFont.size,multiKeyBackground:"#fff",displayColors:true,boxPadding:0,borderColor:"rgba(0,0,0,0)",borderWidth:0,animation:{duration:400,easing:"easeOutQuart"},animations:{numbers:{type:"number",properties:["x","y","width","height","caretX","caretY"]},opacity:{easing:"linear",duration:200}},callbacks:{beforeTitle:Bo,title(t){if(t.length>0){let e=t[0],n=e.chart.data.labels,r=n?n.length:0;if(this&&this.options&&this.options.mode==="dataset")return e.dataset.label||"";if(e.label)return e.label;if(r>0&&e.dataIndex<r)return n[e.dataIndex]}return ""},afterTitle:Bo,beforeBody:Bo,beforeLabel:Bo,label(t){if(this&&this.options&&this.options.mode==="dataset")return t.label+": "+t.formattedValue||t.formattedValue;let e=t.dataset.label||"";e&&(e+=": ");let n=t.formattedValue;return Le(n)||(e+=n),e},labelColor(t){let n=t.chart.getDatasetMeta(t.datasetIndex).controller.getStyle(t.dataIndex);return {borderColor:n.borderColor,backgroundColor:n.backgroundColor,borderWidth:n.borderWidth,borderDash:n.borderDash,borderDashOffset:n.borderDashOffset,borderRadius:0}},labelTextColor(){return this.options.bodyColor},labelPointStyle(t){let n=t.chart.getDatasetMeta(t.datasetIndex).controller.getStyle(t.dataIndex);return {pointStyle:n.pointStyle,rotation:n.rotation}},afterLabel:Bo,afterBody:Bo,beforeFooter:Bo,footer:Bo,afterFooter:Bo}},defaultRoutes:{bodyFont:"font",footerFont:"font",titleFont:"font"},descriptors:{_scriptable:t=>t!=="filter"&&t!=="itemSort"&&t!=="external",_indexable:false,callbacks:{_scriptable:false,_indexable:false},animation:{_fallback:false},animations:{_fallback:"animation"}},additionalOptionScopes:["interaction"]};var _U=(t,e,n,r)=>(typeof e=="string"?(n=t.push(e)-1,r.unshift({index:n,label:e})):isNaN(e)&&(n=null),n);function TU(t,e,n,r){let i=t.indexOf(e);if(i===-1)return _U(t,e,n,r);let o=t.lastIndexOf(e);return i!==o?n:i}var wU=(t,e)=>t===null?null:Nr(Math.round(t),0,e),Rc=class extends Oc{constructor(e){super(e),this._startValue=void 0,this._valueRange=0,this._addedLabels=[];}init(e){let n=this._addedLabels;if(n.length){let r=this.getLabels();for(let{index:i,label:o}of n)r[i]===o&&r.splice(i,1);this._addedLabels=[];}super.init(e);}parse(e,n){if(Le(e))return null;let r=this.getLabels();return n=isFinite(n)&&r[n]===e?n:TU(r,e,me(n,e),this._addedLabels),wU(n,r.length-1)}determineDataLimits(){let{minDefined:e,maxDefined:n}=this.getUserBounds(),{min:r,max:i}=this.getMinMax(true);this.options.bounds==="ticks"&&(e||(r=0),n||(i=this.getLabels().length-1)),this.min=r,this.max=i;}buildTicks(){let e=this.min,n=this.max,r=this.options.offset,i=[],o=this.getLabels();o=e===0&&n===o.length-1?o:o.slice(e,n+1),this._valueRange=Math.max(o.length-(r?0:1),1),this._startValue=this.min-(r?.5:0);for(let s=e;s<=n;s++)i.push({value:s});return i}getLabelForValue(e){let n=this.getLabels();return e>=0&&e<n.length?n[e]:e}configure(){super.configure(),this.isHorizontal()||(this._reversePixels=!this._reversePixels);}getPixelForValue(e){return typeof e!="number"&&(e=this.parse(e)),e===null?NaN:this.getPixelForDecimal((e-this._startValue)/this._valueRange)}getPixelForTick(e){let n=this.ticks;return e<0||e>n.length-1?null:this.getPixelForValue(n[e].value)}getValueForPixel(e){return Math.round(this._startValue+this.getDecimalForPixel(e)*this._valueRange)}getBasePixel(){return this.bottom}};Rc.id="category";Rc.defaults={ticks:{callback:Rc.prototype.getLabelForValue}};function IU(t,e){let n=[],{bounds:i,step:o,min:s,max:c,precision:p,count:h,maxTicks:v,maxDigits:P,includeBounds:x}=t,T=o||1,I=v-1,{min:R,max:A}=e,O=!Le(s),N=!Le(c),V=!Le(h),G=(A-R)/(P+1),X=Fg((A-R)/I/T)*T,nt,st,U,j;if(X<1e-14&&!O&&!N)return [{value:R},{value:A}];j=Math.ceil(A/X)-Math.floor(R/X),j>I&&(X=Fg(j*X/I/T)*T),Le(p)||(nt=Math.pow(10,p),X=Math.ceil(X*nt)/nt),i==="ticks"?(st=Math.floor(R/X)*X,U=Math.ceil(A/X)*X):(st=R,U=A),O&&N&&o&&g0((c-s)/o,X/1e3)?(j=Math.round(Math.min((c-s)/X,v)),X=(c-s)/j,st=s,U=c):V?(st=O?s:st,U=N?c:U,j=h-1,X=(U-st)/j):(j=(U-st)/X,_c(j,Math.round(j),X/1e3)?j=Math.round(j):j=Math.ceil(j));let ut=Math.max(Ng(X),Ng(st));nt=Math.pow(10,Le(p)?ut:p),st=Math.round(st*nt)/nt,U=Math.round(U*nt)/nt;let Y=0;for(O&&(x&&st!==s?(n.push({value:s}),st<s&&Y++,_c(Math.round((st+Y*X)*nt)/nt,s,Dw(s,G,t))&&Y++):st<s&&Y++);Y<j;++Y)n.push({value:Math.round((st+Y*X)*nt)/nt});return N&&x&&U!==c?n.length&&_c(n[n.length-1].value,c,Dw(c,G,t))?n[n.length-1].value=c:n.push({value:c}):(!N||U===c)&&n.push({value:U}),n}function Dw(t,e,{horizontal:n,minRotation:r}){let i=Qn(r),o=(n?Math.sin(i):Math.cos(i))||.001,s=.75*e*(""+t).length;return Math.min(e/o,s)}var ld=class extends Oc{constructor(e){super(e),this.start=void 0,this.end=void 0,this._startValue=void 0,this._endValue=void 0,this._valueRange=0;}parse(e,n){return Le(e)||(typeof e=="number"||e instanceof Number)&&!isFinite(+e)?null:+e}handleTickRangeOptions(){let{beginAtZero:e}=this.options,{minDefined:n,maxDefined:r}=this.getUserBounds(),{min:i,max:o}=this,s=p=>i=n?i:p,c=p=>o=r?o:p;if(e){let p=go(i),h=go(o);p<0&&h<0?c(0):p>0&&h>0&&s(0);}if(i===o){let p=1;(o>=Number.MAX_SAFE_INTEGER||i<=Number.MIN_SAFE_INTEGER)&&(p=Math.abs(o*.05)),c(o+p),e||s(i-p);}this.min=i,this.max=o;}getTickLimit(){let e=this.options.ticks,{maxTicksLimit:n,stepSize:r}=e,i;return r?(i=Math.ceil(this.max/r)-Math.floor(this.min/r)+1,i>1e3&&(console.warn(`scales.${this.id}.ticks.stepSize: ${r} would result generating up to ${i} ticks. Limiting to 1000.`),i=1e3)):(i=this.computeTickLimit(),n=n||11),n&&(i=Math.min(n,i)),i}computeTickLimit(){return Number.POSITIVE_INFINITY}buildTicks(){let e=this.options,n=e.ticks,r=this.getTickLimit();r=Math.max(2,r);let i={maxTicks:r,bounds:e.bounds,min:e.min,max:e.max,precision:n.precision,step:n.stepSize,count:n.count,maxDigits:this._maxDigits(),horizontal:this.isHorizontal(),minRotation:n.minRotation||0,includeBounds:n.includeBounds!==false},o=this._range||this,s=IU(i,o);return e.bounds==="ticks"&&Mg(s,this,"value"),e.reverse?(s.reverse(),this.start=this.max,this.end=this.min):(this.start=this.min,this.end=this.max),s}configure(){let e=this.ticks,n=this.min,r=this.max;if(super.configure(),this.options.offset&&e.length){let i=(r-n)/Math.max(e.length-1,1)/2;n-=i,r+=i;}this._startValue=n,this._endValue=r,this._valueRange=r-n;}getLabelForValue(e){return kc(e,this.chart.options.locale,this.options.ticks.format)}},cd=class extends ld{determineDataLimits(){let{min:e,max:n}=this.getMinMax(true);this.min=Mn(e)?e:0,this.max=Mn(n)?n:1,this.handleTickRangeOptions();}computeTickLimit(){let e=this.isHorizontal(),n=e?this.width:this.height,r=Qn(this.options.ticks.minRotation),i=(e?Math.sin(r):Math.cos(r))||.001,o=this._resolveTickFontOptions(0);return Math.ceil(n/Math.min(40,o.lineHeight/i))}getPixelForValue(e){return e===null?NaN:this.getPixelForDecimal((e-this._startValue)/this._valueRange)}getValueForPixel(e){return this._startValue+this.getDecimalForPixel(e)*this._valueRange}};cd.id="linear";cd.defaults={ticks:{callback:vy.formatters.numeric}};function Aw(t){return t/Math.pow(10,Math.floor(Ei(t)))===1}function kU(t,e){let n=Math.floor(Ei(e.max)),r=Math.ceil(e.max/Math.pow(10,n)),i=[],o=xi(t.min,Math.pow(10,Math.floor(Ei(e.min)))),s=Math.floor(Ei(o)),c=Math.floor(o/Math.pow(10,s)),p=s<0?Math.pow(10,Math.abs(s)):1;do i.push({value:o,major:Aw(o)}),++c,c===10&&(c=1,++s,p=s>=0?1:p),o=Math.round(c*Math.pow(10,s)*p)/p;while(s<n||s===n&&c<r);let h=xi(t.max,o);return i.push({value:h,major:Aw(o)}),i}var yy=class extends Oc{constructor(e){super(e),this.start=void 0,this.end=void 0,this._startValue=void 0,this._valueRange=0;}parse(e,n){let r=ld.prototype.parse.apply(this,[e,n]);if(r===0){this._zero=true;return}return Mn(r)&&r>0?r:null}determineDataLimits(){let{min:e,max:n}=this.getMinMax(true);this.min=Mn(e)?Math.max(0,e):null,this.max=Mn(n)?Math.max(0,n):null,this.options.beginAtZero&&(this._zero=true),this.handleTickRangeOptions();}handleTickRangeOptions(){let{minDefined:e,maxDefined:n}=this.getUserBounds(),r=this.min,i=this.max,o=p=>r=e?r:p,s=p=>i=n?i:p,c=(p,h)=>Math.pow(10,Math.floor(Ei(p))+h);r===i&&(r<=0?(o(1),s(10)):(o(c(r,-1)),s(c(i,1)))),r<=0&&o(c(i,-1)),i<=0&&s(c(r,1)),this._zero&&this.min!==this._suggestedMin&&r===c(this.min,0)&&o(c(r,-1)),this.min=r,this.max=i;}buildTicks(){let e=this.options,n={min:this._userMin,max:this._userMax},r=kU(n,this);return e.bounds==="ticks"&&Mg(r,this,"value"),e.reverse?(r.reverse(),this.start=this.max,this.end=this.min):(this.start=this.min,this.end=this.max),r}getLabelForValue(e){return e===void 0?"0":kc(e,this.chart.options.locale,this.options.ticks.format)}configure(){let e=this.min;super.configure(),this._startValue=Ei(e),this._valueRange=Ei(this.max)-Ei(e);}getPixelForValue(e){return (e===void 0||e===0)&&(e=this.min),e===null||isNaN(e)?NaN:this.getPixelForDecimal(e===this.min?0:(Ei(e)-this._startValue)/this._valueRange)}getValueForPixel(e){let n=this.getDecimalForPixel(e);return Math.pow(10,this._startValue+n*this._valueRange)}};yy.id="logarithmic";yy.defaults={ticks:{callback:vy.formatters.logarithmic,major:{enabled:true}}};function a1(t){let e=t.ticks;if(e.display&&t.display){let n=$n(e.backdropPadding);return me(e.font&&e.font.size,ke.font.size)+n.height}return 0}function DU(t,e,n){return n=He(n)?n:[n],{w:w0(t,e.string,n),h:n.length*e.lineHeight}}function Ow(t,e,n,r,i){return t===r||t===i?{start:e-n/2,end:e+n/2}:t<r||t>i?{start:e-n,end:e}:{start:e,end:e+n}}function AU(t){let e={l:t.left+t._padding.left,r:t.right-t._padding.right,t:t.top+t._padding.top,b:t.bottom-t._padding.bottom},n=Object.assign({},e),r=[],i=[],o=t._pointLabels.length,s=t.options.pointLabels,c=s.centerPointLabels?Be/o:0;for(let p=0;p<o;p++){let h=s.setContext(t.getPointLabelContext(p));i[p]=h.padding;let v=t.getPointPosition(p,t.drawingArea+i[p],c),P=Sn(h.font),x=DU(t.ctx,P,t._pointLabels[p]);r[p]=x;let T=ai(t.getIndexAngle(p)+c),I=Math.round(Tc(T)),R=Ow(I,v.x,x.w,0,180),A=Ow(I,v.y,x.h,90,270);OU(n,e,T,R,A);}t.setCenterPoint(e.l-n.l,n.r-e.r,e.t-n.t,n.b-e.b),t._pointLabelItems=RU(t,r,i);}function OU(t,e,n,r,i){let o=Math.abs(Math.sin(n)),s=Math.abs(Math.cos(n)),c=0,p=0;r.start<e.l?(c=(e.l-r.start)/o,t.l=Math.min(t.l,e.l-c)):r.end>e.r&&(c=(r.end-e.r)/o,t.r=Math.max(t.r,e.r+c)),i.start<e.t?(p=(e.t-i.start)/s,t.t=Math.min(t.t,e.t-p)):i.end>e.b&&(p=(i.end-e.b)/s,t.b=Math.max(t.b,e.b+p));}function RU(t,e,n){let r=[],i=t._pointLabels.length,o=t.options,s=a1(o)/2,c=t.drawingArea,p=o.pointLabels.centerPointLabels?Be/i:0;for(let h=0;h<i;h++){let v=t.getPointPosition(h,c+s+n[h],p),P=Math.round(Tc(ai(v.angle+bn))),x=e[h],T=NU(v.y,x.h,P),I=FU(P),R=MU(v.x,x.w,I);r.push({x:v.x,y:T,textAlign:I,left:R,top:T,right:R+x.w,bottom:T+x.h});}return r}function FU(t){return t===0||t===180?"center":t<180?"left":"right"}function MU(t,e,n){return n==="right"?t-=e:n==="center"&&(t-=e/2),t}function NU(t,e,n){return n===90||n===270?t-=e/2:(n>270||n<90)&&(t-=e),t}function LU(t,e){let{ctx:n,options:{pointLabels:r}}=t;for(let i=e-1;i>=0;i--){let o=r.setContext(t.getPointLabelContext(i)),s=Sn(o.font),{x:c,y:p,textAlign:h,left:v,top:P,right:x,bottom:T}=t._pointLabelItems[i],{backdropColor:I}=o;if(!Le(I)){let R=$o(o.borderRadius),A=$n(o.backdropPadding);n.fillStyle=I;let O=v-A.left,N=P-A.top,V=x-v+A.width,G=T-P+A.height;Object.values(R).some(X=>X!==0)?(n.beginPath(),os(n,{x:O,y:N,w:V,h:G,radius:R}),n.fill()):n.fillRect(O,N,V,G);}is(n,t._pointLabels[i],c,p+s.lineHeight/2,s,{color:o.color,textAlign:h,textBaseline:"middle"});}}function iI(t,e,n,r){let{ctx:i}=t;if(n)i.arc(t.xCenter,t.yCenter,e,0,rn);else {let o=t.getPointPosition(0,e);i.moveTo(o.x,o.y);for(let s=1;s<r;s++)o=t.getPointPosition(s,e),i.lineTo(o.x,o.y);}}function BU(t,e,n,r){let i=t.ctx,o=e.circular,{color:s,lineWidth:c}=e;!o&&!r||!s||!c||n<0||(i.save(),i.strokeStyle=s,i.lineWidth=c,i.setLineDash(e.borderDash),i.lineDashOffset=e.borderDashOffset,i.beginPath(),iI(t,n,o,r),i.closePath(),i.stroke(),i.restore());}function UU(t,e,n){return ba(t,{label:n,index:e,type:"pointLabel"})}var ud=class extends ld{constructor(e){super(e),this.xCenter=void 0,this.yCenter=void 0,this.drawingArea=void 0,this._pointLabels=[],this._pointLabelItems=[];}setDimensions(){let e=this._padding=$n(a1(this.options)/2),n=this.width=this.maxWidth-e.width,r=this.height=this.maxHeight-e.height;this.xCenter=Math.floor(this.left+n/2+e.left),this.yCenter=Math.floor(this.top+r/2+e.top),this.drawingArea=Math.floor(Math.min(n,r)/2);}determineDataLimits(){let{min:e,max:n}=this.getMinMax(false);this.min=Mn(e)&&!isNaN(e)?e:0,this.max=Mn(n)&&!isNaN(n)?n:0,this.handleTickRangeOptions();}computeTickLimit(){return Math.ceil(this.drawingArea/a1(this.options))}generateTickLabels(e){ld.prototype.generateTickLabels.call(this,e),this._pointLabels=this.getLabels().map((n,r)=>{let i=Qe(this.options.pointLabels.callback,[n,r],this);return i||i===0?i:""}).filter((n,r)=>this.chart.getDataVisibility(r));}fit(){let e=this.options;e.display&&e.pointLabels.display?AU(this):this.setCenterPoint(0,0,0,0);}setCenterPoint(e,n,r,i){this.xCenter+=Math.floor((e-n)/2),this.yCenter+=Math.floor((r-i)/2),this.drawingArea-=Math.min(this.drawingArea/2,Math.max(e,n,r,i));}getIndexAngle(e){let n=rn/(this._pointLabels.length||1),r=this.options.startAngle||0;return ai(e*n+Qn(r))}getDistanceFromCenterForValue(e){if(Le(e))return NaN;let n=this.drawingArea/(this.max-this.min);return this.options.reverse?(this.max-e)*n:(e-this.min)*n}getValueForDistanceFromCenter(e){if(Le(e))return NaN;let n=e/(this.drawingArea/(this.max-this.min));return this.options.reverse?this.max-n:this.min+n}getPointLabelContext(e){let n=this._pointLabels||[];if(e>=0&&e<n.length){let r=n[e];return UU(this.getContext(),e,r)}}getPointPosition(e,n,r=0){let i=this.getIndexAngle(e)-bn+r;return {x:Math.cos(i)*n+this.xCenter,y:Math.sin(i)*n+this.yCenter,angle:i}}getPointPositionForValue(e,n){return this.getPointPosition(e,this.getDistanceFromCenterForValue(n))}getBasePosition(e){return this.getPointPositionForValue(e||0,this.getBaseValue())}getPointLabelPosition(e){let{left:n,top:r,right:i,bottom:o}=this._pointLabelItems[e];return {left:n,top:r,right:i,bottom:o}}drawBackground(){let{backgroundColor:e,grid:{circular:n}}=this.options;if(e){let r=this.ctx;r.save(),r.beginPath(),iI(this,this.getDistanceFromCenterForValue(this._endValue),n,this._pointLabels.length),r.closePath(),r.fillStyle=e,r.fill(),r.restore();}}drawGrid(){let e=this.ctx,n=this.options,{angleLines:r,grid:i}=n,o=this._pointLabels.length,s,c,p;if(n.pointLabels.display&&LU(this,o),i.display&&this.ticks.forEach((h,v)=>{if(v!==0){c=this.getDistanceFromCenterForValue(h.value);let P=i.setContext(this.getContext(v-1));BU(this,P,c,o);}}),r.display){for(e.save(),s=o-1;s>=0;s--){let h=r.setContext(this.getPointLabelContext(s)),{color:v,lineWidth:P}=h;!P||!v||(e.lineWidth=P,e.strokeStyle=v,e.setLineDash(h.borderDash),e.lineDashOffset=h.borderDashOffset,c=this.getDistanceFromCenterForValue(n.ticks.reverse?this.min:this.max),p=this.getPointPosition(s,c),e.beginPath(),e.moveTo(this.xCenter,this.yCenter),e.lineTo(p.x,p.y),e.stroke());}e.restore();}}drawBorder(){}drawLabels(){let e=this.ctx,n=this.options,r=n.ticks;if(!r.display)return;let i=this.getIndexAngle(0),o,s;e.save(),e.translate(this.xCenter,this.yCenter),e.rotate(i),e.textAlign="center",e.textBaseline="middle",this.ticks.forEach((c,p)=>{if(p===0&&!n.reverse)return;let h=r.setContext(this.getContext(p)),v=Sn(h.font);if(o=this.getDistanceFromCenterForValue(this.ticks[p].value),h.showLabelBackdrop){e.font=v.string,s=e.measureText(c.label).width,e.fillStyle=h.backdropColor;let P=$n(h.backdropPadding);e.fillRect(-s/2-P.left,-o-v.size/2-P.top,s+P.width,v.size+P.height);}is(e,c.label,0,-o,v,{color:h.color});}),e.restore();}drawTitle(){}};ud.id="radialLinear";ud.defaults={display:true,animate:true,position:"chartArea",angleLines:{display:true,lineWidth:1,borderDash:[],borderDashOffset:0},grid:{circular:false},startAngle:0,ticks:{showLabelBackdrop:true,callback:vy.formatters.numeric},pointLabels:{backdropColor:void 0,backdropPadding:2,display:true,font:{size:10},callback(t){return t},padding:5,centerPointLabels:false}};ud.defaultRoutes={"angleLines.color":"borderColor","pointLabels.color":"color","ticks.color":"color"};ud.descriptors={angleLines:{_fallback:"grid"}};var Cy={millisecond:{common:true,size:1,steps:1e3},second:{common:true,size:1e3,steps:60},minute:{common:true,size:6e4,steps:60},hour:{common:true,size:36e5,steps:24},day:{common:true,size:864e5,steps:30},week:{common:false,size:6048e5,steps:4},month:{common:true,size:2628e6,steps:12},quarter:{common:false,size:7884e6,steps:4},year:{common:true,size:3154e7}},_i=Object.keys(Cy);function $U(t,e){return t-e}function Rw(t,e){if(Le(e))return null;let n=t._adapter,{parser:r,round:i,isoWeekday:o}=t._parseOpts,s=e;return typeof r=="function"&&(s=r(s)),Mn(s)||(s=typeof r=="string"?n.parse(s,r):n.parse(s)),s===null?null:(i&&(s=i==="week"&&(Vi(o)||o===true)?n.startOf(s,"isoWeek",o):n.startOf(s,i)),+s)}function Fw(t,e,n,r){let i=_i.length;for(let o=_i.indexOf(t);o<i-1;++o){let s=Cy[_i[o]],c=s.steps?s.steps:Number.MAX_SAFE_INTEGER;if(s.common&&Math.ceil((n-e)/(c*s.size))<=r)return _i[o]}return _i[i-1]}function GU(t,e,n,r,i){for(let o=_i.length-1;o>=_i.indexOf(n);o--){let s=_i[o];if(Cy[s].common&&t._adapter.diff(i,r,s)>=e-1)return s}return _i[n?_i.indexOf(n):0]}function jU(t){for(let e=_i.indexOf(t)+1,n=_i.length;e<n;++e)if(Cy[_i[e]].common)return _i[e]}function Mw(t,e,n){if(!n)t[e]=true;else if(n.length){let{lo:r,hi:i}=cf(n,e),o=n[r]>=e?n[r]:n[i];t[o]=true;}}function VU(t,e,n,r){let i=t._adapter,o=+i.startOf(e[0].value,r),s=e[e.length-1].value,c,p;for(c=o;c<=s;c=+i.add(c,1,r))p=n[c],p>=0&&(e[p].major=true);return e}function Nw(t,e,n){let r=[],i={},o=e.length,s,c;for(s=0;s<o;++s)c=e[s],i[c]=s,r.push({value:c,major:false});return o===0||!n?r:VU(t,r,i,n)}var dd=class extends Oc{constructor(e){super(e),this._cache={data:[],labels:[],all:[]},this._unit="day",this._majorUnit=void 0,this._offsets={},this._normalized=false,this._parseOpts=void 0;}init(e,n){let r=e.time||(e.time={}),i=this._adapter=new z6._date(e.adapters.date);i.init(n),Ec(r.displayFormats,i.formats()),this._parseOpts={parser:r.parser,round:r.round,isoWeekday:r.isoWeekday},super.init(e),this._normalized=n.normalized;}parse(e,n){return e===void 0?null:Rw(this,e)}beforeLayout(){super.beforeLayout(),this._cache={data:[],labels:[],all:[]};}determineDataLimits(){let e=this.options,n=this._adapter,r=e.time.unit||"day",{min:i,max:o,minDefined:s,maxDefined:c}=this.getUserBounds();function p(h){!s&&!isNaN(h.min)&&(i=Math.min(i,h.min)),!c&&!isNaN(h.max)&&(o=Math.max(o,h.max));}(!s||!c)&&(p(this._getLabelBounds()),(e.bounds!=="ticks"||e.ticks.source!=="labels")&&p(this.getMinMax(false))),i=Mn(i)&&!isNaN(i)?i:+n.startOf(Date.now(),r),o=Mn(o)&&!isNaN(o)?o:+n.endOf(Date.now(),r)+1,this.min=Math.min(i,o-1),this.max=Math.max(i+1,o);}_getLabelBounds(){let e=this.getLabelTimestamps(),n=Number.POSITIVE_INFINITY,r=Number.NEGATIVE_INFINITY;return e.length&&(n=e[0],r=e[e.length-1]),{min:n,max:r}}buildTicks(){let e=this.options,n=e.time,r=e.ticks,i=r.source==="labels"?this.getLabelTimestamps():this._generate();e.bounds==="ticks"&&i.length&&(this.min=this._userMin||i[0],this.max=this._userMax||i[i.length-1]);let o=this.min,s=this.max,c=v0(i,o,s);return this._unit=n.unit||(r.autoSkip?Fw(n.minUnit,this.min,this.max,this._getLabelCapacity(o)):GU(this,c.length,n.minUnit,this.min,this.max)),this._majorUnit=!r.major.enabled||this._unit==="year"?void 0:jU(this._unit),this.initOffsets(i),e.reverse&&c.reverse(),Nw(this,c,this._majorUnit)}afterAutoSkip(){this.options.offsetAfterAutoskip&&this.initOffsets(this.ticks.map(e=>+e.value));}initOffsets(e){let n=0,r=0,i,o;this.options.offset&&e.length&&(i=this.getDecimalForValue(e[0]),e.length===1?n=1-i:n=(this.getDecimalForValue(e[1])-i)/2,o=this.getDecimalForValue(e[e.length-1]),e.length===1?r=o:r=(o-this.getDecimalForValue(e[e.length-2]))/2);let s=e.length<3?.5:.25;n=Nr(n,0,s),r=Nr(r,0,s),this._offsets={start:n,end:r,factor:1/(n+1+r)};}_generate(){let e=this._adapter,n=this.min,r=this.max,i=this.options,o=i.time,s=o.unit||Fw(o.minUnit,n,r,this._getLabelCapacity(n)),c=me(o.stepSize,1),p=s==="week"?o.isoWeekday:false,h=Vi(p)||p===true,v={},P=n,x,T;if(h&&(P=+e.startOf(P,"isoWeek",p)),P=+e.startOf(P,h?"day":s),e.diff(r,n,s)>1e5*c)throw new Error(n+" and "+r+" are too far apart with stepSize of "+c+" "+s);let I=i.ticks.source==="data"&&this.getDataTimestamps();for(x=P,T=0;x<r;x=+e.add(x,c,s),T++)Mw(v,x,I);return (x===r||i.bounds==="ticks"||T===1)&&Mw(v,x,I),Object.keys(v).sort((R,A)=>R-A).map(R=>+R)}getLabelForValue(e){let n=this._adapter,r=this.options.time;return r.tooltipFormat?n.format(e,r.tooltipFormat):n.format(e,r.displayFormats.datetime)}_tickFormatFunction(e,n,r,i){let o=this.options,s=o.time.displayFormats,c=this._unit,p=this._majorUnit,h=c&&s[c],v=p&&s[p],P=r[n],x=p&&v&&P&&P.major,T=this._adapter.format(e,i||(x?v:h)),I=o.ticks.callback;return I?Qe(I,[T,n,r],this):T}generateTickLabels(e){let n,r,i;for(n=0,r=e.length;n<r;++n)i=e[n],i.label=this._tickFormatFunction(i.value,n,e);}getDecimalForValue(e){return e===null?NaN:(e-this.min)/(this.max-this.min)}getPixelForValue(e){let n=this._offsets,r=this.getDecimalForValue(e);return this.getPixelForDecimal((n.start+r)*n.factor)}getValueForPixel(e){let n=this._offsets,r=this.getDecimalForPixel(e)/n.factor-n.end;return this.min+r*(this.max-this.min)}_getLabelSize(e){let n=this.options.ticks,r=this.ctx.measureText(e).width,i=Qn(this.isHorizontal()?n.maxRotation:n.minRotation),o=Math.cos(i),s=Math.sin(i),c=this._resolveTickFontOptions(0).size;return {w:r*o+c*s,h:r*s+c*o}}_getLabelCapacity(e){let n=this.options.time,r=n.displayFormats,i=r[n.unit]||r.millisecond,o=this._tickFormatFunction(e,0,Nw(this,[e],this._majorUnit),i),s=this._getLabelSize(o),c=Math.floor(this.isHorizontal()?this.width/s.w:this.height/s.h)-1;return c>0?c:1}getDataTimestamps(){let e=this._cache.data||[],n,r;if(e.length)return e;let i=this.getMatchingVisibleMetas();if(this._normalized&&i.length)return this._cache.data=i[0].controller.getAllParsedValues(this);for(n=0,r=i.length;n<r;++n)e=e.concat(i[n].controller.getAllParsedValues(this));return this._cache.data=this.normalize(e)}getLabelTimestamps(){let e=this._cache.labels||[],n,r;if(e.length)return e;let i=this.getLabels();for(n=0,r=i.length;n<r;++n)e.push(Rw(this,i[n]));return this._cache.labels=this._normalized?e:this.normalize(e)}normalize(e){return Ug(e.sort($U))}};dd.id="time";dd.defaults={bounds:"data",adapters:{},time:{parser:false,unit:false,round:false,isoWeekday:false,minUnit:"millisecond",displayFormats:{}},ticks:{source:"auto",major:{enabled:false}}};function ly(t,e,n){let r=0,i=t.length-1,o,s,c,p;n?(e>=t[r].pos&&e<=t[i].pos&&({lo:r,hi:i}=es(t,"pos",e)),{pos:o,time:c}=t[r],{pos:s,time:p}=t[i]):(e>=t[r].time&&e<=t[i].time&&({lo:r,hi:i}=es(t,"time",e)),{time:o,pos:c}=t[r],{time:s,pos:p}=t[i]);let h=s-o;return h?c+(p-c)*(e-o)/h:c}var by=class extends dd{constructor(e){super(e),this._table=[],this._minPos=void 0,this._tableRange=void 0;}initOffsets(){let e=this._getTimestampsForTable(),n=this._table=this.buildLookupTable(e);this._minPos=ly(n,this.min),this._tableRange=ly(n,this.max)-this._minPos,super.initOffsets(e);}buildLookupTable(e){let{min:n,max:r}=this,i=[],o=[],s,c,p,h,v;for(s=0,c=e.length;s<c;++s)h=e[s],h>=n&&h<=r&&i.push(h);if(i.length<2)return [{time:n,pos:0},{time:r,pos:1}];for(s=0,c=i.length;s<c;++s)v=i[s+1],p=i[s-1],h=i[s],Math.round((v+p)/2)!==h&&o.push({time:h,pos:s/(c-1)});return o}_getTimestampsForTable(){let e=this._cache.all||[];if(e.length)return e;let n=this.getDataTimestamps(),r=this.getLabelTimestamps();return n.length&&r.length?e=this.normalize(n.concat(r)):e=n.length?n:r,e=this._cache.all=e,e}getDecimalForValue(e){return (ly(this._table,e)-this._minPos)/this._tableRange}getValueForPixel(e){let n=this._offsets,r=this.getDecimalForPixel(e)/n.factor-n.end;return ly(this._table,r*this._tableRange+this._minPos,true)}};by.id="timeseries";by.defaults=dd.defaults;var oI=(function(){if(typeof window!="undefined"){if(window.devicePixelRatio)return window.devicePixelRatio;var t=window.screen;if(t)return (t.deviceXDPI||1)/(t.logicalXDPI||1)}return 1})(),Ff={toTextLines:function(t){var e=[],n;for(t=[].concat(t);t.length;)n=t.pop(),typeof n=="string"?e.unshift.apply(e,n.split(`
5649
+ `)):Array.isArray(n)?t.push.apply(t,n):Le(t)||e.unshift(""+n);return e},textSize:function(t,e,n){var r=[].concat(e),i=r.length,o=t.font,s=0,c;for(t.font=n.string,c=0;c<i;++c)s=Math.max(t.measureText(r[c]).width,s);return t.font=o,{height:i*n.lineHeight,width:s}},bound:function(t,e,n){return Math.max(t,Math.min(e,n))},arrayDiff:function(t,e){var n=t.slice(),r=[],i,o,s,c;for(i=0,s=e.length;i<s;++i)c=e[i],o=n.indexOf(c),o===-1?r.push([c,1]):n.splice(o,1);for(i=0,s=n.length;i<s;++i)r.push([n[i],-1]);return r},rasterize:function(t){return Math.round(t*oI)/oI}};function l1(t,e){var n=e.x,r=e.y;if(n===null)return {x:0,y:-1};if(r===null)return {x:1,y:0};var i=t.x-n,o=t.y-r,s=Math.sqrt(i*i+o*o);return {x:s?i/s:0,y:s?o/s:-1}}function zU(t,e,n,r,i){switch(i){case "center":n=r=0;break;case "bottom":n=0,r=1;break;case "right":n=1,r=0;break;case "left":n=-1,r=0;break;case "top":n=0,r=-1;break;case "start":n=-n,r=-r;break;case "end":break;default:i*=Math.PI/180,n=Math.cos(i),r=Math.sin(i);break}return {x:t,y:e,vx:n,vy:r}}var HU=0,sI=1,lI=2,cI=4,uI=8;function Sy(t,e,n){var r=HU;return t<n.left?r|=sI:t>n.right&&(r|=lI),e<n.top?r|=uI:e>n.bottom&&(r|=cI),r}function WU(t,e){for(var n=t.x0,r=t.y0,i=t.x1,o=t.y1,s=Sy(n,r,e),c=Sy(i,o,e),p,h,v;!(!(s|c)||s&c);)p=s||c,p&uI?(h=n+(i-n)*(e.top-r)/(o-r),v=e.top):p&cI?(h=n+(i-n)*(e.bottom-r)/(o-r),v=e.bottom):p&lI?(v=r+(o-r)*(e.right-n)/(i-n),h=e.right):p&sI&&(v=r+(o-r)*(e.left-n)/(i-n),h=e.left),p===s?(n=h,r=v,s=Sy(n,r,e)):(i=h,o=v,c=Sy(i,o,e));return {x0:n,x1:i,y0:r,y1:o}}function Py(t,e){var n=e.anchor,r=t,i,o;return e.clamp&&(r=WU(r,e.area)),n==="start"?(i=r.x0,o=r.y0):n==="end"?(i=r.x1,o=r.y1):(i=(r.x0+r.x1)/2,o=(r.y0+r.y1)/2),zU(i,o,t.vx,t.vy,e.align)}var xy={arc:function(t,e){var n=(t.startAngle+t.endAngle)/2,r=Math.cos(n),i=Math.sin(n),o=t.innerRadius,s=t.outerRadius;return Py({x0:t.x+r*o,y0:t.y+i*o,x1:t.x+r*s,y1:t.y+i*s,vx:r,vy:i},e)},point:function(t,e){var n=l1(t,e.origin),r=n.x*t.options.radius,i=n.y*t.options.radius;return Py({x0:t.x-r,y0:t.y-i,x1:t.x+r,y1:t.y+i,vx:n.x,vy:n.y},e)},bar:function(t,e){var n=l1(t,e.origin),r=t.x,i=t.y,o=0,s=0;return t.horizontal?(r=Math.min(t.x,t.base),o=Math.abs(t.base-t.x)):(i=Math.min(t.y,t.base),s=Math.abs(t.base-t.y)),Py({x0:r,y0:i+s,x1:r+o,y1:i,vx:n.x,vy:n.y},e)},fallback:function(t,e){var n=l1(t,e.origin);return Py({x0:t.x,y0:t.y,x1:t.x+(t.width||0),y1:t.y+(t.height||0),vx:n.x,vy:n.y},e)}},ps=Ff.rasterize;function qU(t){var e=t.borderWidth||0,n=t.padding,r=t.size.height,i=t.size.width,o=-i/2,s=-r/2;return {frame:{x:o-n.left-e,y:s-n.top-e,w:i+n.width+e*2,h:r+n.height+e*2},text:{x:o,y:s,w:i,h:r}}}function YU(t,e){var n=e.chart.getDatasetMeta(e.datasetIndex).vScale;if(!n)return null;if(n.xCenter!==void 0&&n.yCenter!==void 0)return {x:n.xCenter,y:n.yCenter};var r=n.getBasePixel();return t.horizontal?{x:r,y:null}:{x:null,y:r}}function QU(t){return t instanceof cs?xy.arc:t instanceof us?xy.point:t instanceof ds?xy.bar:xy.fallback}function KU(t,e,n,r,i,o){var s=Math.PI/2;if(o){var c=Math.min(o,i/2,r/2),p=e+c,h=n+c,v=e+r-c,P=n+i-c;t.moveTo(e,h),p<v&&h<P?(t.arc(p,h,c,-Math.PI,-s),t.arc(v,h,c,-s,0),t.arc(v,P,c,0,s),t.arc(p,P,c,s,Math.PI)):p<v?(t.moveTo(p,n),t.arc(v,h,c,-s,s),t.arc(p,h,c,s,Math.PI+s)):h<P?(t.arc(p,h,c,-Math.PI,0),t.arc(p,P,c,0,Math.PI)):t.arc(p,h,c,-Math.PI,Math.PI),t.closePath(),t.moveTo(e,n);}else t.rect(e,n,r,i);}function XU(t,e,n){var r=n.backgroundColor,i=n.borderColor,o=n.borderWidth;!r&&(!i||!o)||(t.beginPath(),KU(t,ps(e.x)+o/2,ps(e.y)+o/2,ps(e.w)-o,ps(e.h)-o,n.borderRadius),t.closePath(),r&&(t.fillStyle=r,t.fill()),i&&o&&(t.strokeStyle=i,t.lineWidth=o,t.lineJoin="miter",t.stroke()));}function ZU(t,e,n){var r=n.lineHeight,i=t.w,o=t.x,s=t.y+r/2;return e==="center"?o+=i/2:(e==="end"||e==="right")&&(o+=i),{h:r,w:i,x:o,y:s}}function JU(t,e,n){var r=t.shadowBlur,i=n.stroked,o=ps(n.x),s=ps(n.y),c=ps(n.w);i&&t.strokeText(e,o,s,c),n.filled&&(r&&i&&(t.shadowBlur=0),t.fillText(e,o,s,c),r&&i&&(t.shadowBlur=r));}function t8(t,e,n,r){var i=r.textAlign,o=r.color,s=!!o,c=r.font,p=e.length,h=r.textStrokeColor,v=r.textStrokeWidth,P=h&&v,x;if(!(!p||!s&&!P))for(n=ZU(n,i,c),t.font=c.string,t.textAlign=i,t.textBaseline="middle",t.shadowBlur=r.textShadowBlur,t.shadowColor=r.textShadowColor,s&&(t.fillStyle=o),P&&(t.lineJoin="round",t.lineWidth=v,t.strokeStyle=h),x=0,p=e.length;x<p;++x)JU(t,e[x],{stroked:P,filled:s,w:n.w,x:n.x,y:n.y+n.h*x});}var dI=function(t,e,n,r){var i=this;i._config=t,i._index=r,i._model=null,i._rects=null,i._ctx=e,i._el=n;};ji(dI.prototype,{_modelize:function(t,e,n,r){var i=this,o=i._index,s=Sn(In([n.font,{}],r,o)),c=In([n.color,ke.color],r,o);return {align:In([n.align,"center"],r,o),anchor:In([n.anchor,"center"],r,o),area:r.chart.chartArea,backgroundColor:In([n.backgroundColor,null],r,o),borderColor:In([n.borderColor,null],r,o),borderRadius:In([n.borderRadius,0],r,o),borderWidth:In([n.borderWidth,0],r,o),clamp:In([n.clamp,false],r,o),clip:In([n.clip,false],r,o),color:c,display:t,font:s,lines:e,offset:In([n.offset,4],r,o),opacity:In([n.opacity,1],r,o),origin:YU(i._el,r),padding:$n(In([n.padding,4],r,o)),positioner:QU(i._el),rotation:In([n.rotation,0],r,o)*(Math.PI/180),size:Ff.textSize(i._ctx,e,s),textAlign:In([n.textAlign,"start"],r,o),textShadowBlur:In([n.textShadowBlur,0],r,o),textShadowColor:In([n.textShadowColor,c],r,o),textStrokeColor:In([n.textStrokeColor,c],r,o),textStrokeWidth:In([n.textStrokeWidth,0],r,o)}},update:function(t){var e=this,n=null,r=null,i=e._index,o=e._config,s,c,p,h=In([o.display,true],t,i);h&&(s=t.dataset.data[i],c=me(Qe(o.formatter,[s,t]),s),p=Le(c)?[]:Ff.toTextLines(c),p.length&&(n=e._modelize(h,p,o,t),r=qU(n))),e._model=n,e._rects=r;},geometry:function(){return this._rects?this._rects.frame:{}},rotation:function(){return this._model?this._model.rotation:0},visible:function(){return this._model&&this._model.opacity},model:function(){return this._model},draw:function(t,e){var n=this,r=t.ctx,i=n._model,o=n._rects,s;this.visible()&&(r.save(),i.clip&&(s=i.area,r.beginPath(),r.rect(s.left,s.top,s.right-s.left,s.bottom-s.top),r.clip()),r.globalAlpha=Ff.bound(0,i.opacity,1),r.translate(ps(e.x),ps(e.y)),r.rotate(i.rotation),XU(r,o.frame,i),t8(r,i.lines,o.text,i),r.restore());}});var e8=Number.MIN_SAFE_INTEGER||-9007199254740991,n8=Number.MAX_SAFE_INTEGER||9007199254740991;function Rf(t,e,n){var r=Math.cos(n),i=Math.sin(n),o=e.x,s=e.y;return {x:o+r*(t.x-o)-i*(t.y-s),y:s+i*(t.x-o)+r*(t.y-s)}}function aI(t,e){var n=n8,r=e8,i=e.origin,o,s,c,p,h;for(o=0;o<t.length;++o)s=t[o],c=s.x-i.x,p=s.y-i.y,h=e.vx*c+e.vy*p,n=Math.min(n,h),r=Math.max(r,h);return {min:n,max:r}}function Ey(t,e){var n=e.x-t.x,r=e.y-t.y,i=Math.sqrt(n*n+r*r);return {vx:(e.x-t.x)/i,vy:(e.y-t.y)/i,origin:t,ln:i}}var pI=function(){this._rotation=0,this._rect={x:0,y:0,w:0,h:0};};ji(pI.prototype,{center:function(){var t=this._rect;return {x:t.x+t.w/2,y:t.y+t.h/2}},update:function(t,e,n){this._rotation=n,this._rect={x:e.x+t.x,y:e.y+t.y,w:e.w,h:e.h};},contains:function(t){var e=this,n=1,r=e._rect;return t=Rf(t,e.center(),-e._rotation),!(t.x<r.x-n||t.y<r.y-n||t.x>r.x+r.w+n*2||t.y>r.y+r.h+n*2)},intersects:function(t){var e=this._points(),n=t._points(),r=[Ey(e[0],e[1]),Ey(e[0],e[3])],i,o,s;for(this._rotation!==t._rotation&&r.push(Ey(n[0],n[1]),Ey(n[0],n[3])),i=0;i<r.length;++i)if(o=aI(e,r[i]),s=aI(n,r[i]),o.max<s.min||s.max<o.min)return false;return true},_points:function(){var t=this,e=t._rect,n=t._rotation,r=t.center();return [Rf({x:e.x,y:e.y},r,n),Rf({x:e.x+e.w,y:e.y},r,n),Rf({x:e.x+e.w,y:e.y+e.h},r,n),Rf({x:e.x,y:e.y+e.h},r,n)]}});function fI(t,e,n){var r=e.positioner(t,e),i=r.vx,o=r.vy;if(!i&&!o)return {x:r.x,y:r.y};var s=n.w,c=n.h,p=e.rotation,h=Math.abs(s/2*Math.cos(p))+Math.abs(c/2*Math.sin(p)),v=Math.abs(s/2*Math.sin(p))+Math.abs(c/2*Math.cos(p)),P=1/Math.max(Math.abs(i),Math.abs(o));return h*=i*P,v*=o*P,h+=e.offset*i,v+=e.offset*o,{x:r.x+h,y:r.y+v}}function r8(t,e){var n,r,i,o;for(n=t.length-1;n>=0;--n)for(i=t[n].$layout,r=n-1;r>=0&&i._visible;--r)o=t[r].$layout,o._visible&&i._box.intersects(o._box)&&e(i,o);return t}function i8(t){var e,n,r,i,o,s,c;for(e=0,n=t.length;e<n;++e)r=t[e],i=r.$layout,i._visible&&(c=new Proxy(r._el,{get:(p,h)=>p.getProps([h],true)[h]}),o=r.geometry(),s=fI(c,r.model(),o),i._box.update(s,o,r.rotation()));return r8(t,function(p,h){var v=p._hidable,P=h._hidable;v&&P||P?h._visible=false:v&&(p._visible=false);})}var Mf={prepare:function(t){var e=[],n,r,i,o,s;for(n=0,i=t.length;n<i;++n)for(r=0,o=t[n].length;r<o;++r)s=t[n][r],e.push(s),s.$layout={_box:new pI,_hidable:false,_visible:true,_set:n,_idx:s._index};return e.sort(function(c,p){var h=c.$layout,v=p.$layout;return h._idx===v._idx?v._set-h._set:v._idx-h._idx}),this.update(e),e},update:function(t){var e=false,n,r,i,o,s;for(n=0,r=t.length;n<r;++n)i=t[n],o=i.model(),s=i.$layout,s._hidable=o&&o.display==="auto",s._visible=i.visible(),e|=s._hidable;e&&i8(t);},lookup:function(t,e){var n,r;for(n=t.length-1;n>=0;--n)if(r=t[n].$layout,r&&r._visible&&r._box.contains(e))return t[n];return null},draw:function(t,e){var n,r,i,o,s,c;for(n=0,r=e.length;n<r;++n)i=e[n],o=i.$layout,o._visible&&(s=i.geometry(),c=fI(i._el,i.model(),s),o._box.update(c,s,i.rotation()),i.draw(t,c));}},o8=function(t){if(Le(t))return null;var e=t,n,r,i;if(Te(t))if(!Le(t.label))e=t.label;else if(!Le(t.r))e=t.r;else for(e="",n=Object.keys(t),i=0,r=n.length;i<r;++i)e+=(i!==0?", ":"")+n[i]+": "+t[n[i]];return ""+e},a8={align:"center",anchor:"center",backgroundColor:null,borderColor:null,borderRadius:0,borderWidth:0,clamp:false,clip:false,color:void 0,display:true,font:{family:void 0,lineHeight:1.2,size:void 0,style:void 0,weight:null},formatter:o8,labels:void 0,listeners:{},offset:4,opacity:1,padding:{top:4,right:4,bottom:4,left:4},rotation:0,textAlign:"start",textStrokeColor:void 0,textStrokeWidth:0,textShadowBlur:0,textShadowColor:void 0},Ti="$datalabels",hI="$default";function s8(t,e){var n=t.datalabels,r={},i=[],o,s;return n===false?null:(n===true&&(n={}),e=ji({},[e,n]),o=e.labels||{},s=Object.keys(o),delete e.labels,s.length?s.forEach(function(c){o[c]&&i.push(ji({},[e,o[c],{_key:c}]));}):i.push(e),r=i.reduce(function(c,p){return tn(p.listeners||{},function(h,v){c[v]=c[v]||{},c[v][p._key||hI]=h;}),delete p.listeners,c},{}),{labels:i,listeners:r})}function c1(t,e,n,r){if(e){var i=n.$context,o=n.$groups,s;e[o._set]&&(s=e[o._set][o._key],s&&Qe(s,[i,r])===true&&(t[Ti]._dirty=true,n.update(i)));}}function l8(t,e,n,r,i){var o,s;!n&&!r||(n?r?n!==r&&(s=o=true):s=true:o=true,s&&c1(t,e.leave,n,i),o&&c1(t,e.enter,r,i));}function c8(t,e){var n=t[Ti],r=n._listeners,i,o;if(!(!r.enter&&!r.leave)){if(e.type==="mousemove")o=Mf.lookup(n._labels,e);else if(e.type!=="mouseout")return;i=n._hovered,n._hovered=o,l8(t,r,i,o,e);}}function u8(t,e){var n=t[Ti],r=n._listeners.click,i=r&&Mf.lookup(n._labels,e);i&&c1(t,r,i,e);}var mI={id:"datalabels",defaults:a8,beforeInit:function(t){t[Ti]={_actives:[]};},beforeUpdate:function(t){var e=t[Ti];e._listened=false,e._listeners={},e._datasets=[],e._labels=[];},afterDatasetUpdate:function(t,e,n){var r=e.index,i=t[Ti],o=i._datasets[r]=[],s=t.isDatasetVisible(r),c=t.data.datasets[r],p=s8(c,n),h=e.meta.data||[],v=t.ctx,P,x,T,I,R,A,O,N;for(v.save(),P=0,T=h.length;P<T;++P)if(O=h[P],O[Ti]=[],s&&O&&t.getDataVisibility(P)&&!O.skip)for(x=0,I=p.labels.length;x<I;++x)R=p.labels[x],A=R._key,N=new dI(R,v,O,P),N.$groups={_set:r,_key:A||hI},N.$context={active:false,chart:t,dataIndex:P,dataset:c,datasetIndex:r},N.update(N.$context),O[Ti].push(N),o.push(N);v.restore(),ji(i._listeners,p.listeners,{merger:function(V,G,X){G[V]=G[V]||{},G[V][e.index]=X[V],i._listened=true;}});},afterUpdate:function(t){t[Ti]._labels=Mf.prepare(t[Ti]._datasets);},afterDatasetsDraw:function(t){Mf.draw(t,t[Ti]._labels);},beforeEvent:function(t,e){if(t[Ti]._listened){var n=e.event;switch(n.type){case "mousemove":case "mouseout":c8(t,n);break;case "click":u8(t,n);break}}},afterEvent:function(t){var e=t[Ti],n=e._actives,r=e._actives=t.getActiveElements(),i=Ff.arrayDiff(n,r),o,s,c,p,h,v,P;for(o=0,s=i.length;o<s;++o)if(h=i[o],h[1])for(P=h[0].element[Ti]||[],c=0,p=P.length;c<p;++c)v=P[c],v.$context.active=h[1]===1,v.update(v.$context);(e._dirty||i.length)&&(Mf.update(e._labels),t.render()),delete e._dirty;}};var gI={modes:{point(t,e){return Ty(t,e,{intersect:true})},nearest(t,e,n){return f8(t,e,n)},x(t,e,n){return Ty(t,e,{intersect:n.intersect,axis:"x"})},y(t,e,n){return Ty(t,e,{intersect:n.intersect,axis:"y"})}}};function b1(t,e,n){return (gI.modes[n.mode]||gI.modes.nearest)(t,e,n)}function d8(t,e,n){return n!=="x"&&n!=="y"?t.inRange(e.x,e.y,"x",true)||t.inRange(e.x,e.y,"y",true):t.inRange(e.x,e.y,n,true)}function p8(t,e,n){return n==="x"?{x:t.x,y:e.y}:n==="y"?{x:e.x,y:t.y}:e}function Ty(t,e,n){return t.visibleElements.filter(r=>n.intersect?r.inRange(e.x,e.y):d8(r,e,n.axis))}function f8(t,e,n){let r=Number.POSITIVE_INFINITY;return Ty(t,e,n).reduce((i,o)=>{let s=o.getCenterPoint(),c=p8(e,s,n.axis),p=ns(e,c);return p<r?(i=[o],r=p):p===r&&i.push(o),i},[]).sort((i,o)=>i._index-o._index).slice(0,1)}var h8=(t,e)=>e>t||t.length>e.length&&t.slice(0,e.length)===e,Fc=.001,Iy=(t,e,n)=>Math.min(n,Math.max(e,t));function m8(t,e,n){for(let r of Object.keys(t))t[r]=Iy(t[r],e,n);return t}function g8(t,e,n,r){if(!t||!e||n<=0)return false;let i=r/2;return Math.pow(t.x-e.x,2)+Math.pow(t.y-e.y,2)<=Math.pow(n+i,2)}function MI(t,{x:e,y:n,x2:r,y2:i},o,s){let c=s/2,p=t.x>=e-c-Fc&&t.x<=r+c+Fc,h=t.y>=n-c-Fc&&t.y<=i+c+Fc;return o==="x"?p:(o==="y"||p)&&h}function md(t,e){let{centerX:n,centerY:r}=t.getProps(["centerX","centerY"],e);return {x:n,y:r}}function y8(t,e,n,r=true){let i=n.split("."),o=0;for(let s of e.split(".")){let c=i[o++];if(parseInt(s,10)<parseInt(c,10))break;if(h8(c,s)){if(r)throw new Error(`${t} v${n} is not supported. v${e} or newer is required.`);return false}}return true}var NI=t=>typeof t=="string"&&t.endsWith("%"),LI=t=>parseFloat(t)/100,BI=t=>Iy(LI(t),0,1);function v1(t,e){return e==="start"?0:e==="end"?t:NI(e)?BI(e)*t:t/2}function Cl(t,e,n=true){return typeof e=="number"?e:NI(e)?(n?BI(e):LI(e))*t:t}function b8(t,e){let{x:n,width:r}=t,i=e.textAlign;return i==="center"?n+r/2:i==="end"||i==="right"?n+r:n}function C1(t,e="center"){return Te(t)?{x:me(t.x,e),y:me(t.y,e)}:(t=me(t,e),{x:t,y:t})}function UI(t){return t&&(Fn(t.xValue)||Fn(t.yValue))}function Lf(t,e,n,r=false){let i=n.init;if(i){if(i===true)return GI(e,r)}else return;return v8(e,r,Qe(i,[{chart:t,properties:e,options:n}]))}function $I(t,e,n){let r=false;return e.forEach(i=>{Gr(t[i])?(r=true,n[i]=t[i]):Fn(n[i])&&delete n[i];}),r}function GI({centerX:t,centerY:e},n){return n?{centerX:t,centerY:e,radius:0,width:0,height:0}:{x:t,y:e,x2:t,y2:e,width:0,height:0}}function v8(t,e,n){if(n===true)return GI(t,e);if(Te(n))return n}var u1=new Map,C8=t=>isNaN(t)||t<=0,S8=t=>t.reduce(function(e,n){return e+=n.string,e},"");function ky(t){if(t&&typeof t=="object"){let e=t.toString();return e==="[object HTMLImageElement]"||e==="[object HTMLCanvasElement]"}}function S1(t,{x:e,y:n},r){r&&(t.translate(e,n),t.rotate(Qn(r)),t.translate(-e,-n));}function Sl(t,e){if(e&&e.borderWidth)return t.lineCap=e.borderCapStyle,t.setLineDash(e.borderDash),t.lineDashOffset=e.borderDashOffset,t.lineJoin=e.borderJoinStyle,t.lineWidth=e.borderWidth,t.strokeStyle=e.borderColor,true}function gd(t,e){t.shadowColor=e.backgroundShadowColor,t.shadowBlur=e.shadowBlur,t.shadowOffsetX=e.shadowOffsetX,t.shadowOffsetY=e.shadowOffsetY;}function P1(t,e){let n=e.content;if(ky(n))return {width:Cl(n.width,e.width),height:Cl(n.height,e.height)};let r=e.font,i=He(r)?r.map(p=>Sn(p)):[Sn(r)],o=e.textStrokeWidth,s=He(n)?n:[n],c=s.join()+S8(i)+o+(t._measureText?"-spriting":"");return u1.has(c)||u1.set(c,T8(t,s,i,o)),u1.get(c)}function jI(t,e,n){let{x:r,y:i,width:o,height:s}=e;t.save(),gd(t,n);let c=Sl(t,n);t.fillStyle=n.backgroundColor,t.beginPath(),os(t,{x:r,y:i,w:o,h:s,radius:m8($o(n.borderRadius),0,Math.min(o,s)/2)}),t.closePath(),t.fill(),c&&(t.shadowColor=n.borderShadowColor,t.stroke()),t.restore();}function P8(t,e,n){let r=n.content;if(ky(r)){t.save(),t.globalAlpha=k8(n.opacity,r.style.opacity),t.drawImage(r,e.x,e.y,e.width,e.height),t.restore();return}let i=He(r)?r:[r],o=n.font,s=He(o)?o.map(P=>Sn(P)):[Sn(o)],c=n.color,p=He(c)?c:[c],h=b8(e,n),v=e.y+n.textStrokeWidth/2;t.save(),t.textBaseline="middle",t.textAlign=n.textAlign,x8(t,n)&&w8(t,{x:h,y:v},i,s),I8(t,{x:h,y:v},i,{fonts:s,colors:p}),t.restore();}function x8(t,e){if(e.textStrokeWidth>0)return t.lineJoin="round",t.miterLimit=2,t.lineWidth=e.textStrokeWidth,t.strokeStyle=e.textStrokeColor,true}function E8(t,e,n,r){let{radius:i,options:o}=e,s=o.pointStyle,c=o.rotation,p=(c||0)*lf;if(ky(s)){t.save(),t.translate(n,r),t.rotate(p),t.drawImage(s,-s.width/2,-s.height/2,s.width,s.height),t.restore();return}C8(i)||_8(t,{x:n,y:r,radius:i,rotation:c,style:s,rad:p});}function _8(t,{x:e,y:n,radius:r,rotation:i,style:o,rad:s}){let c,p,h,v;switch(t.beginPath(),o){default:t.arc(e,n,r,0,rn),t.closePath();break;case "triangle":t.moveTo(e+Math.sin(s)*r,n-Math.cos(s)*r),s+=ed,t.lineTo(e+Math.sin(s)*r,n-Math.cos(s)*r),s+=ed,t.lineTo(e+Math.sin(s)*r,n-Math.cos(s)*r),t.closePath();break;case "rectRounded":v=r*.516,h=r-v,c=Math.cos(s+mo)*h,p=Math.sin(s+mo)*h,t.arc(e-c,n-p,v,s-Be,s-bn),t.arc(e+p,n-c,v,s-bn,s),t.arc(e+c,n+p,v,s,s+bn),t.arc(e-p,n+c,v,s+bn,s+Be),t.closePath();break;case "rect":if(!i){h=Math.SQRT1_2*r,t.rect(e-h,n-h,2*h,2*h);break}s+=mo;case "rectRot":c=Math.cos(s)*r,p=Math.sin(s)*r,t.moveTo(e-c,n-p),t.lineTo(e+p,n-c),t.lineTo(e+c,n+p),t.lineTo(e-p,n+c),t.closePath();break;case "crossRot":s+=mo;case "cross":c=Math.cos(s)*r,p=Math.sin(s)*r,t.moveTo(e-c,n-p),t.lineTo(e+c,n+p),t.moveTo(e+p,n-c),t.lineTo(e-p,n+c);break;case "star":c=Math.cos(s)*r,p=Math.sin(s)*r,t.moveTo(e-c,n-p),t.lineTo(e+c,n+p),t.moveTo(e+p,n-c),t.lineTo(e-p,n+c),s+=mo,c=Math.cos(s)*r,p=Math.sin(s)*r,t.moveTo(e-c,n-p),t.lineTo(e+c,n+p),t.moveTo(e+p,n-c),t.lineTo(e-p,n+c);break;case "line":c=Math.cos(s)*r,p=Math.sin(s)*r,t.moveTo(e-c,n-p),t.lineTo(e+c,n+p);break;case "dash":t.moveTo(e,n),t.lineTo(e+Math.cos(s)*r,n+Math.sin(s)*r);break}t.fill();}function T8(t,e,n,r){t.save();let i=e.length,o=0,s=r;for(let c=0;c<i;c++){let p=n[Math.min(c,n.length-1)];t.font=p.string;let h=e[c];o=Math.max(o,t.measureText(h).width+r),s+=p.lineHeight;}return t.restore(),{width:o,height:s}}function w8(t,{x:e,y:n},r,i){t.beginPath();let o=0;r.forEach(function(s,c){let p=i[Math.min(c,i.length-1)],h=p.lineHeight;t.font=p.string,t.strokeText(s,e,n+h/2+o),o+=h;}),t.stroke();}function I8(t,{x:e,y:n},r,{fonts:i,colors:o}){let s=0;r.forEach(function(c,p){let h=o[Math.min(p,o.length-1)],v=i[Math.min(p,i.length-1)],P=v.lineHeight;t.beginPath(),t.font=v.string,t.fillStyle=h,t.fillText(c,e,n+P/2+s),s+=P,t.fill();});}function k8(t,e){let n=Vi(t)?t:e;return Vi(n)?Iy(n,0,1):1}var yI={xScaleID:{min:"xMin",max:"xMax",start:"left",end:"right",startProp:"x",endProp:"x2"},yScaleID:{min:"yMin",max:"yMax",start:"bottom",end:"top",startProp:"y",endProp:"y2"}};function pd(t,e,n){return e=typeof e=="number"?e:t.parse(e),Mn(e)?t.getPixelForValue(e):n}function Mc(t,e,n){let r=e[n];if(r||n==="scaleID")return r;let i=n.charAt(0),o=Object.values(t).filter(s=>s.axis&&s.axis===i);return o.length?o[0].id:i}function VI(t,e){if(t){let n=t.options.reverse,r=pd(t,e.min,n?e.end:e.start),i=pd(t,e.max,n?e.start:e.end);return {start:r,end:i}}}function zI(t,e){let{chartArea:n,scales:r}=t,i=r[Mc(r,e,"xScaleID")],o=r[Mc(r,e,"yScaleID")],s=n.width/2,c=n.height/2;return i&&(s=pd(i,e.xValue,i.left+i.width/2)),o&&(c=pd(o,e.yValue,o.top+o.height/2)),{x:s,y:c}}function x1(t,e){let n=t.scales,r=n[Mc(n,e,"xScaleID")],i=n[Mc(n,e,"yScaleID")];if(!r&&!i)return {};let{left:o,right:s}=r||t.chartArea,{top:c,bottom:p}=i||t.chartArea,h=bI(r,{min:e.xMin,max:e.xMax,start:o,end:s});o=h.start,s=h.end;let v=bI(i,{min:e.yMin,max:e.yMax,start:p,end:c});return c=v.start,p=v.end,{x:o,y:c,x2:s,y2:p,width:s-o,height:p-c,centerX:o+(s-o)/2,centerY:c+(p-c)/2}}function HI(t,e){if(!UI(e)){let n=x1(t,e),r=e.radius;(!r||isNaN(r))&&(r=Math.min(n.width,n.height)/2,e.radius=r);let i=r*2,o=n.centerX+e.xAdjust,s=n.centerY+e.yAdjust;return {x:o-r,y:s-r,x2:o+r,y2:s+r,centerX:o,centerY:s,width:i,height:i,radius:r}}return A8(t,e)}function D8(t,e){let{scales:n,chartArea:r}=t,i=n[e.scaleID],o={x:r.left,y:r.top,x2:r.right,y2:r.bottom};return i?O8(i,o,e):R8(n,o,e),o}function WI(t,e,n){let r=x1(t,e);return r.initProperties=Lf(t,r,e,n),r.elements=[{type:"label",optionScope:"label",properties:N8(t,r,e),initProperties:r.initProperties}],r}function A8(t,e){let n=zI(t,e),r=e.radius*2;return {x:n.x-e.radius+e.xAdjust,y:n.y-e.radius+e.yAdjust,x2:n.x+e.radius+e.xAdjust,y2:n.y+e.radius+e.yAdjust,centerX:n.x+e.xAdjust,centerY:n.y+e.yAdjust,radius:e.radius,width:r,height:r}}function bI(t,e){let n=VI(t,e)||e;return {start:Math.min(n.start,n.end),end:Math.max(n.start,n.end)}}function O8(t,e,n){let r=pd(t,n.value,NaN),i=pd(t,n.endValue,r);t.isHorizontal()?(e.x=r,e.x2=i):(e.y=r,e.y2=i);}function R8(t,e,n){for(let r of Object.keys(yI)){let i=t[Mc(t,n,r)];if(i){let{min:o,max:s,start:c,end:p,startProp:h,endProp:v}=yI[r],P=VI(i,{min:n[o],max:n[s],start:i[c],end:i[p]});e[h]=P.start,e[v]=P.end;}}}function F8({properties:t,options:e},n,r,i){let{x:o,x2:s,width:c}=t;return qI({start:o,end:s,borderWidth:e.borderWidth},{position:r.x,padding:{start:i.left,end:i.right},adjust:e.label.xAdjust,size:n.width})}function M8({properties:t,options:e},n,r,i){let{y:o,y2:s,height:c}=t;return qI({start:o,end:s,borderWidth:e.borderWidth},{position:r.y,padding:{start:i.top,end:i.bottom},adjust:e.label.yAdjust,size:n.height})}function qI(t,e){let{start:n,end:r,borderWidth:i}=t,{position:o,padding:{start:s,end:c},adjust:p}=e,h=r-i-n-s-c-e.size;return n+i/2+p+v1(h,o)}function N8(t,e,n){let r=n.label;r.backgroundColor="transparent",r.callout.display=false;let i=C1(r.position),o=$n(r.padding),s=P1(t.ctx,r),c=F8({properties:e,options:n},s,i,o),p=M8({properties:e,options:n},s,i,o),h=s.width+o.width,v=s.height+o.height;return {x:c,y:p,x2:c+h,y2:p+v,width:h,height:v,centerX:c+h/2,centerY:p+v/2,rotation:r.rotation}}function Uc(t,e,n){let r=Math.cos(n),i=Math.sin(n),o=e.x,s=e.y;return {x:o+r*(t.x-o)-i*(t.y-s),y:s+i*(t.x-o)+r*(t.y-s)}}var d1=["enter","leave"],E1=d1.concat("click");function L8(t,e,n){e.listened=$I(n,E1,e.listeners),e.moveListened=false,e._getElements=b1,d1.forEach(r=>{Gr(n[r])&&(e.moveListened=true);}),(!e.listened||!e.moveListened)&&e.annotations.forEach(r=>{!e.listened&&Gr(r.click)&&(e.listened=true),e.moveListened||d1.forEach(i=>{Gr(r[i])&&(e.listened=true,e.moveListened=true);});});}function B8(t,e,n){if(t.listened)switch(e.type){case "mousemove":case "mouseout":return U8(t,e,n);case "click":return $8(t,e,n)}}function U8(t,e,n){if(!t.moveListened)return;let r;e.type==="mousemove"?r=b1(t,e,n.interaction):r=[];let i=t.hovered;t.hovered=r;let o={state:t,event:e},s=vI(o,"leave",i,r);return vI(o,"enter",r,i)||s}function vI({state:t,event:e},n,r,i){let o;for(let s of r)i.indexOf(s)<0&&(o=YI(s.options[n]||t.listeners[n],s,e)||o);return o}function $8(t,e,n){let r=t.listeners,i=b1(t,e,n.interaction),o;for(let s of i)o=YI(s.options.click||r.click,s,e)||o;return o}function YI(t,e,n){return Qe(t,[e.$context,n])===true}var wy=["afterDraw","beforeDraw"];function G8(t,e,n){let r=e.visibleElements;e.hooked=$I(n,wy,e.hooks),e.hooked||r.forEach(i=>{e.hooked||wy.forEach(o=>{Gr(i.options[o])&&(e.hooked=true);});});}function CI(t,e,n){if(t.hooked){let r=e.options[n]||t.hooks[n];return Qe(r,[e.$context])}}function j8(t,e,n){let r=q8(t.scales,e,n),i=SI(e,r,"min","suggestedMin");i=SI(e,r,"max","suggestedMax")||i,i&&Gr(e.handleTickRangeOptions)&&e.handleTickRangeOptions();}function V8(t,e){for(let n of t)H8(n,e);}function SI(t,e,n,r){if(Mn(e[n])&&!z8(t.options,n,r)){let i=t[n]!==e[n];return t[n]=e[n],i}}function z8(t,e,n){return Fn(t[e])||Fn(t[n])}function H8(t,e){for(let n of ["scaleID","xScaleID","yScaleID"]){let r=Mc(e,t,n);r&&!e[r]&&W8(t,n)&&console.warn(`No scale found with id '${r}' for annotation '${t.id}'`);}}function W8(t,e){if(e==="scaleID")return true;let n=e.charAt(0);for(let r of ["Min","Max","Value"])if(Fn(t[n+r]))return true;return false}function q8(t,e,n){let r=e.axis,i=e.id,o=r+"ScaleID",s={min:me(e.min,Number.NEGATIVE_INFINITY),max:me(e.max,Number.POSITIVE_INFINITY)};for(let c of n)c.scaleID===i?PI(c,e,["value","endValue"],s):Mc(t,c,o)===i&&PI(c,e,[r+"Min",r+"Max",r+"Value"],s);return s}function PI(t,e,n,r){for(let i of n){let o=t[i];if(Fn(o)){let s=e.parse(o);r.min=Math.min(r.min,s),r.max=Math.max(r.max,s);}}}var Pl=class extends br{inRange(e,n,r,i){let{x:o,y:s}=Uc({x:e,y:n},this.getCenterPoint(i),Qn(-this.options.rotation));return MI({x:o,y:s},this.getProps(["x","y","x2","y2"],i),r,this.options.borderWidth)}getCenterPoint(e){return md(this,e)}draw(e){e.save(),S1(e,this.getCenterPoint(),this.options.rotation),jI(e,this,this.options),e.restore();}get label(){return this.elements&&this.elements[0]}resolveElementProperties(e,n){return WI(e,n)}};Pl.id="boxAnnotation";Pl.defaults={adjustScaleRange:true,backgroundShadowColor:"transparent",borderCapStyle:"butt",borderDash:[],borderDashOffset:0,borderJoinStyle:"miter",borderRadius:0,borderShadowColor:"transparent",borderWidth:1,display:true,init:void 0,label:{backgroundColor:"transparent",borderWidth:0,callout:{display:false},color:"black",content:null,display:false,drawTime:void 0,font:{family:void 0,lineHeight:void 0,size:void 0,style:void 0,weight:"bold"},height:void 0,opacity:void 0,padding:6,position:"center",rotation:void 0,textAlign:"start",textStrokeColor:void 0,textStrokeWidth:0,width:void 0,xAdjust:0,yAdjust:0,z:void 0},rotation:0,shadowBlur:0,shadowOffsetX:0,shadowOffsetY:0,xMax:void 0,xMin:void 0,xScaleID:void 0,yMax:void 0,yMin:void 0,yScaleID:void 0,z:0};Pl.defaultRoutes={borderColor:"color",backgroundColor:"color"};Pl.descriptors={label:{_fallback:true}};var QI=["left","bottom","top","right"],Nc=class extends br{inRange(e,n,r,i){let{x:o,y:s}=Uc({x:e,y:n},this.getCenterPoint(i),Qn(-this.rotation));return MI({x:o,y:s},this.getProps(["x","y","x2","y2"],i),r,this.options.borderWidth)}getCenterPoint(e){return md(this,e)}draw(e){let n=this.options,r=!Fn(this._visible)||this._visible;!n.display||!n.content||!r||(e.save(),S1(e,this.getCenterPoint(),this.rotation),Q8(e,this),jI(e,this,n),P8(e,n7(this),n),e.restore());}resolveElementProperties(e,n){let r;if(UI(n))r=zI(e,n);else {let{centerX:c,centerY:p}=x1(e,n);r={x:c,y:p};}let i=$n(n.padding),o=P1(e.ctx,n),s=Y8(r,o,n,i);return St(W({initProperties:Lf(e,s,n),pointX:r.x,pointY:r.y},s),{rotation:n.rotation})}};Nc.id="labelAnnotation";Nc.defaults={adjustScaleRange:true,backgroundColor:"transparent",backgroundShadowColor:"transparent",borderCapStyle:"butt",borderDash:[],borderDashOffset:0,borderJoinStyle:"miter",borderRadius:0,borderShadowColor:"transparent",borderWidth:0,callout:{borderCapStyle:"butt",borderColor:void 0,borderDash:[],borderDashOffset:0,borderJoinStyle:"miter",borderWidth:1,display:false,margin:5,position:"auto",side:5,start:"50%"},color:"black",content:null,display:true,font:{family:void 0,lineHeight:void 0,size:void 0,style:void 0,weight:void 0},height:void 0,init:void 0,opacity:void 0,padding:6,position:"center",rotation:0,shadowBlur:0,shadowOffsetX:0,shadowOffsetY:0,textAlign:"center",textStrokeColor:void 0,textStrokeWidth:0,width:void 0,xAdjust:0,xMax:void 0,xMin:void 0,xScaleID:void 0,xValue:void 0,yAdjust:0,yMax:void 0,yMin:void 0,yScaleID:void 0,yValue:void 0,z:0};Nc.defaultRoutes={borderColor:"color"};function Y8(t,e,n,r){let i=e.width+r.width+n.borderWidth,o=e.height+r.height+n.borderWidth,s=C1(n.position,"center"),c=xI(t.x,i,n.xAdjust,s.x),p=xI(t.y,o,n.yAdjust,s.y);return {x:c,y:p,x2:c+i,y2:p+o,width:i,height:o,centerX:c+i/2,centerY:p+o/2}}function xI(t,e,n=0,r){return t-v1(e,r)+n}function Q8(t,e){let{pointX:n,pointY:r,options:i}=e,o=i.callout,s=o&&o.display&&t7(e,o);if(!s||r7(e,o,s))return;if(t.save(),t.beginPath(),!Sl(t,o))return t.restore();let{separatorStart:p,separatorEnd:h}=K8(e,s),{sideStart:v,sideEnd:P}=Z8(e,s,p);(o.margin>0||i.borderWidth===0)&&(t.moveTo(p.x,p.y),t.lineTo(h.x,h.y)),t.moveTo(v.x,v.y),t.lineTo(P.x,P.y);let x=Uc({x:n,y:r},e.getCenterPoint(),Qn(-e.rotation));t.lineTo(x.x,x.y),t.stroke(),t.restore();}function K8(t,e){let{x:n,y:r,x2:i,y2:o}=t,s=X8(t,e),c,p;return e==="left"||e==="right"?(c={x:n+s,y:r},p={x:c.x,y:o}):(c={x:n,y:r+s},p={x:i,y:c.y}),{separatorStart:c,separatorEnd:p}}function X8(t,e){let{width:n,height:r,options:i}=t,o=i.callout.margin+i.borderWidth/2;return e==="right"?n+o:e==="bottom"?r+o:-o}function Z8(t,e,n){let{y:r,width:i,height:o,options:s}=t,c=s.callout.start,p=J8(e,s.callout),h,v;return e==="left"||e==="right"?(h={x:n.x,y:r+Cl(o,c)},v={x:h.x+p,y:h.y}):(h={x:n.x+Cl(i,c),y:n.y},v={x:h.x,y:h.y+p}),{sideStart:h,sideEnd:v}}function J8(t,e){let n=e.side;return t==="left"||t==="top"?-n:n}function t7(t,e){let n=e.position;return QI.includes(n)?n:e7(t,e)}function e7(t,e){let{x:n,y:r,x2:i,y2:o,width:s,height:c,pointX:p,pointY:h,centerX:v,centerY:P,rotation:x}=t,T={x:v,y:P},I=e.start,R=Cl(s,I),A=Cl(c,I),O=[n,n+R,n+R,i],N=[r+A,o,r,o],V=[];for(let G=0;G<4;G++){let X=Uc({x:O[G],y:N[G]},T,Qn(x));V.push({position:QI[G],distance:ns(X,{x:p,y:h})});}return V.sort((G,X)=>G.distance-X.distance)[0].position}function n7({x:t,y:e,width:n,height:r,options:i}){let o=i.borderWidth/2,s=$n(i.padding);return {x:t+s.left+o,y:e+s.top+o,width:n-s.left-s.right-i.borderWidth,height:r-s.top-s.bottom-i.borderWidth}}function r7(t,e,n){let{pointX:r,pointY:i}=t,o=e.margin,s=r,c=i;return n==="left"?s+=o:n==="right"?s-=o:n==="top"?c+=o:n==="bottom"&&(c-=o),t.inRange(s,c)}var _1=(t,e,n)=>({x:t.x+n*(e.x-t.x),y:t.y+n*(e.y-t.y)}),p1=(t,e,n)=>_1(e,n,Math.abs((t-e.y)/(n.y-e.y))).x,EI=(t,e,n)=>_1(e,n,Math.abs((t-e.x)/(n.x-e.x))).y,Nf=t=>t*t,i7=(t,e,{x:n,y:r,x2:i,y2:o},s)=>s==="y"?{start:Math.min(r,o),end:Math.max(r,o),value:e}:{start:Math.min(n,i),end:Math.max(n,i),value:t},_I=(t,e,n,r)=>(1-r)*(1-r)*t+2*(1-r)*r*e+r*r*n,f1=(t,e,n,r)=>({x:_I(t.x,e.x,n.x,r),y:_I(t.y,e.y,n.y,r)}),TI=(t,e,n,r)=>2*(1-r)*(e-t)+2*r*(n-e),wI=(t,e,n,r)=>-Math.atan2(TI(t.x,e.x,n.x,r),TI(t.y,e.y,n.y,r))+.5*Be,Lc=class extends br{inRange(e,n,r,i){let o=this.options.borderWidth/2;if(r!=="x"&&r!=="y"){let s={mouseX:e,mouseY:n},{path:c,ctx:p}=this;if(c){Sl(p,this.options);let{chart:v}=this.$context,P=e*v.currentDevicePixelRatio,x=n*v.currentDevicePixelRatio,T=p.isPointInStroke(c,P,x)||h1(this,s,i);return p.restore(),T}let h=Nf(o);return l7(this,s,h,i)||h1(this,s,i)}return o7(this,{mouseX:e,mouseY:n},r,{hBorderWidth:o,useFinalPosition:i})}getCenterPoint(e){return md(this,e)}draw(e){let{x:n,y:r,x2:i,y2:o,cp:s,options:c}=this;if(e.save(),!Sl(e,c))return e.restore();gd(e,c);let p=Math.sqrt(Math.pow(i-n,2)+Math.pow(o-r,2));if(c.curve&&s)return g7(e,this,s,p),e.restore();let{startOpts:h,endOpts:v,startAdjust:P,endAdjust:x}=KI(this),T=Math.atan2(o-r,i-n);e.translate(n,r),e.rotate(T),e.beginPath(),e.moveTo(0+P,0),e.lineTo(p-x,0),e.shadowColor=c.borderShadowColor,e.stroke(),m1(e,0,P,h),m1(e,p,-x,v),e.restore();}get label(){return this.elements&&this.elements[0]}resolveElementProperties(e,n){let r=D8(e,n),{x:i,y:o,x2:s,y2:c}=r,p=a7(r,e.chartArea),h=p?s7({x:i,y:o},{x:s,y:c},e.chartArea):{x:i,y:o,x2:s,y2:c,width:Math.abs(s-i),height:Math.abs(c-o)};if(h.centerX=(s+i)/2,h.centerY=(c+o)/2,h.initProperties=Lf(e,h,n),n.curve){let P={x:h.x,y:h.y},x={x:h.x2,y:h.y2};h.cp=m7(h,n,ns(P,x));}let v=c7(e,h,n.label);return v._visible=p,h.elements=[{type:"label",optionScope:"label",properties:v,initProperties:h.initProperties}],h}};Lc.id="lineAnnotation";var II={backgroundColor:void 0,backgroundShadowColor:void 0,borderColor:void 0,borderDash:void 0,borderDashOffset:void 0,borderShadowColor:void 0,borderWidth:void 0,display:void 0,fill:void 0,length:void 0,shadowBlur:void 0,shadowOffsetX:void 0,shadowOffsetY:void 0,width:void 0};Lc.defaults={adjustScaleRange:true,arrowHeads:{display:false,end:Object.assign({},II),fill:false,length:12,start:Object.assign({},II),width:6},borderDash:[],borderDashOffset:0,borderShadowColor:"transparent",borderWidth:2,curve:false,controlPoint:{y:"-50%"},display:true,endValue:void 0,init:void 0,label:{backgroundColor:"rgba(0,0,0,0.8)",backgroundShadowColor:"transparent",borderCapStyle:"butt",borderColor:"black",borderDash:[],borderDashOffset:0,borderJoinStyle:"miter",borderRadius:6,borderShadowColor:"transparent",borderWidth:0,callout:Object.assign({},Nc.defaults.callout),color:"#fff",content:null,display:false,drawTime:void 0,font:{family:void 0,lineHeight:void 0,size:void 0,style:void 0,weight:"bold"},height:void 0,opacity:void 0,padding:6,position:"center",rotation:0,shadowBlur:0,shadowOffsetX:0,shadowOffsetY:0,textAlign:"center",textStrokeColor:void 0,textStrokeWidth:0,width:void 0,xAdjust:0,yAdjust:0,z:void 0},scaleID:void 0,shadowBlur:0,shadowOffsetX:0,shadowOffsetY:0,value:void 0,xMax:void 0,xMin:void 0,xScaleID:void 0,yMax:void 0,yMin:void 0,yScaleID:void 0,z:0};Lc.descriptors={arrowHeads:{start:{_fallback:true},end:{_fallback:true},_fallback:true}};Lc.defaultRoutes={borderColor:"color"};function o7(t,{mouseX:e,mouseY:n},r,{hBorderWidth:i,useFinalPosition:o}){let s=i7(e,n,t.getProps(["x","y","x2","y2"],o),r);return s.value>=s.start-i&&s.value<=s.end+i||h1(t,{mouseX:e,mouseY:n},o,r)}function a7({x:t,y:e,x2:n,y2:r},{top:i,right:o,bottom:s,left:c}){return !(t<c&&n<c||t>o&&n>o||e<i&&r<i||e>s&&r>s)}function kI({x:t,y:e},n,{top:r,right:i,bottom:o,left:s}){return t<s&&(e=EI(s,{x:t,y:e},n),t=s),t>i&&(e=EI(i,{x:t,y:e},n),t=i),e<r&&(t=p1(r,{x:t,y:e},n),e=r),e>o&&(t=p1(o,{x:t,y:e},n),e=o),{x:t,y:e}}function s7(t,e,n){let{x:r,y:i}=kI(t,e,n),{x:o,y:s}=kI(e,t,n);return {x:r,y:i,x2:o,y2:s,width:Math.abs(o-r),height:Math.abs(s-i)}}function l7(t,{mouseX:e,mouseY:n},r=Fc,i){let{x:o,y:s,x2:c,y2:p}=t.getProps(["x","y","x2","y2"],i),h=c-o,v=p-s,P=Nf(h)+Nf(v),x=P===0?-1:((e-o)*h+(n-s)*v)/P,T,I;return x<0?(T=o,I=s):x>1?(T=c,I=p):(T=o+x*h,I=s+x*v),Nf(e-T)+Nf(n-I)<=r}function h1(t,{mouseX:e,mouseY:n},r,i){let o=t.label;return o.options.display&&o.inRange(e,n,i,r)}function c7(t,e,n){let r=n.borderWidth,i=$n(n.padding),o=P1(t.ctx,n),s=o.width+i.width+r,c=o.height+i.height+r;return d7(e,n,{width:s,height:c,padding:i},t.chartArea)}function u7(t){let{x:e,y:n,x2:r,y2:i}=t,o=Math.atan2(i-n,r-e);return o>Be/2?o-Be:o<Be/-2?o+Be:o}function d7(t,e,n,r){let{width:i,height:o,padding:s}=n,{xAdjust:c,yAdjust:p}=e,h={x:t.x,y:t.y},v={x:t.x2,y:t.y2},P=e.rotation==="auto"?u7(t):Qn(e.rotation),x=p7(i,o,P),T=f7(t,e,{labelSize:x,padding:s},r),I=t.cp?f1(h,t.cp,v,T):_1(h,v,T),R={size:x.w,min:r.left,max:r.right,padding:s.left},A={size:x.h,min:r.top,max:r.bottom,padding:s.top},O=AI(I.x,R)+c,N=AI(I.y,A)+p;return {x:O-i/2,y:N-o/2,x2:O+i/2,y2:N+o/2,centerX:O,centerY:N,pointX:I.x,pointY:I.y,width:i,height:o,rotation:Tc(P)}}function p7(t,e,n){let r=Math.cos(n),i=Math.sin(n);return {w:Math.abs(t*r)+Math.abs(e*i),h:Math.abs(t*i)+Math.abs(e*r)}}function f7(t,e,n,r){let i,o=h7(t,r);return e.position==="start"?i=DI({w:t.x2-t.x,h:t.y2-t.y},n,e,o):e.position==="end"?i=1-DI({w:t.x-t.x2,h:t.y-t.y2},n,e,o):i=v1(1,e.position),i}function DI(t,e,n,r){let{labelSize:i,padding:o}=e,s=t.w*r.dx,c=t.h*r.dy,p=s>0&&(i.w/2+o.left-r.x)/s,h=c>0&&(i.h/2+o.top-r.y)/c;return Iy(Math.max(p,h),0,.25)}function h7(t,e){let{x:n,x2:r,y:i,y2:o}=t,s=Math.min(i,o)-e.top,c=Math.min(n,r)-e.left,p=e.bottom-Math.max(i,o),h=e.right-Math.max(n,r);return {x:Math.min(c,h),y:Math.min(s,p),dx:c<=h?1:-1,dy:s<=p?1:-1}}function AI(t,e){let{size:n,min:r,max:i,padding:o}=e,s=n/2;return n>i-r?(i+r)/2:(r>=t-o-s&&(t=r+o+s),i<=t+o+s&&(t=i-o-s),t)}function KI(t){let e=t.options,n=e.arrowHeads&&e.arrowHeads.start,r=e.arrowHeads&&e.arrowHeads.end;return {startOpts:n,endOpts:r,startAdjust:OI(t,n),endAdjust:OI(t,r)}}function OI(t,e){if(!e||!e.display)return 0;let{length:n,width:r}=e,i=t.options.borderWidth/2,o={x:n,y:r+i};return Math.abs(p1(0,o,{x:0,y:i}))}function m1(t,e,n,r){if(!r||!r.display)return;let{length:i,width:o,fill:s,backgroundColor:c,borderColor:p}=r,h=Math.abs(e-i)+n;t.beginPath(),gd(t,r),Sl(t,r),t.moveTo(h,-o),t.lineTo(e+n,0),t.lineTo(h,o),s===true?(t.fillStyle=c||p,t.closePath(),t.fill(),t.shadowColor="transparent"):t.shadowColor=r.borderShadowColor,t.stroke();}function m7(t,e,n){let{x:r,y:i,x2:o,y2:s,centerX:c,centerY:p}=t,h=Math.atan2(s-i,o-r),v=C1(e.controlPoint,0),P={x:c+Cl(n,v.x,false),y:p+Cl(n,v.y,false)};return Uc(P,{x:c,y:p},h)}function RI(t,{x:e,y:n},{angle:r,adjust:i},o){!o||!o.display||(t.save(),t.translate(e,n),t.rotate(r),m1(t,0,-i,o),t.restore());}function g7(t,e,n,r){let{x:i,y:o,x2:s,y2:c,options:p}=e,{startOpts:h,endOpts:v,startAdjust:P,endAdjust:x}=KI(e),T={x:i,y:o},I={x:s,y:c},R=wI(T,n,I,0),A=wI(T,n,I,1)-Be,O=f1(T,n,I,P/r),N=f1(T,n,I,1-x/r),V=new Path2D;t.beginPath(),V.moveTo(O.x,O.y),V.quadraticCurveTo(n.x,n.y,N.x,N.y),t.shadowColor=p.borderShadowColor,t.stroke(V),e.path=V,e.ctx=t,RI(t,O,{angle:R,adjust:P},h),RI(t,N,{angle:A,adjust:x},v);}var Bc=class extends br{inRange(e,n,r,i){let o=this.options.rotation,s=this.options.borderWidth;if(r!=="x"&&r!=="y")return y7({x:e,y:n},this.getProps(["width","height","centerX","centerY"],i),o,s);let{x:c,y:p,x2:h,y2:v}=this.getProps(["x","y","x2","y2"],i),P=s/2,x=r==="y"?{start:p,end:v}:{start:c,end:h},T=Uc({x:e,y:n},this.getCenterPoint(i),Qn(-o));return T[r]>=x.start-P-Fc&&T[r]<=x.end+P+Fc}getCenterPoint(e){return md(this,e)}draw(e){let{width:n,height:r,centerX:i,centerY:o,options:s}=this;e.save(),S1(e,this.getCenterPoint(),s.rotation),gd(e,this.options),e.beginPath(),e.fillStyle=s.backgroundColor;let c=Sl(e,s);e.ellipse(i,o,r/2,n/2,Be/2,0,2*Be),e.fill(),c&&(e.shadowColor=s.borderShadowColor,e.stroke()),e.restore();}get label(){return this.elements&&this.elements[0]}resolveElementProperties(e,n){return WI(e,n,true)}};Bc.id="ellipseAnnotation";Bc.defaults={adjustScaleRange:true,backgroundShadowColor:"transparent",borderDash:[],borderDashOffset:0,borderShadowColor:"transparent",borderWidth:1,display:true,init:void 0,label:Object.assign({},Pl.defaults.label),rotation:0,shadowBlur:0,shadowOffsetX:0,shadowOffsetY:0,xMax:void 0,xMin:void 0,xScaleID:void 0,yMax:void 0,yMin:void 0,yScaleID:void 0,z:0};Bc.defaultRoutes={borderColor:"color",backgroundColor:"color"};Bc.descriptors={label:{_fallback:true}};function y7(t,e,n,r){let{width:i,height:o,centerX:s,centerY:c}=e,p=i/2,h=o/2;if(p<=0||h<=0)return false;let v=Qn(n||0),P=r/2||0,x=Math.cos(v),T=Math.sin(v),I=Math.pow(x*(t.x-s)+T*(t.y-c),2),R=Math.pow(T*(t.x-s)-x*(t.y-c),2);return I/Math.pow(p+P,2)+R/Math.pow(h+P,2)<=1.0001}var fd=class extends br{inRange(e,n,r,i){let{x:o,y:s,x2:c,y2:p,width:h}=this.getProps(["x","y","x2","y2","width"],i),v=this.options.borderWidth;if(r!=="x"&&r!=="y")return g8({x:e,y:n},this.getCenterPoint(i),h/2,v);let P=v/2,x=r==="y"?{start:s,end:p,value:n}:{start:o,end:c,value:e};return x.value>=x.start-P&&x.value<=x.end+P}getCenterPoint(e){return md(this,e)}draw(e){let n=this.options,r=n.borderWidth;if(n.radius<.1)return;e.save(),e.fillStyle=n.backgroundColor,gd(e,n);let i=Sl(e,n);E8(e,this,this.centerX,this.centerY),i&&!ky(n.pointStyle)&&(e.shadowColor=n.borderShadowColor,e.stroke()),e.restore(),n.borderWidth=r;}resolveElementProperties(e,n){let r=HI(e,n);return r.initProperties=Lf(e,r,n,true),r}};fd.id="pointAnnotation";fd.defaults={adjustScaleRange:true,backgroundShadowColor:"transparent",borderDash:[],borderDashOffset:0,borderShadowColor:"transparent",borderWidth:1,display:true,init:void 0,pointStyle:"circle",radius:10,rotation:0,shadowBlur:0,shadowOffsetX:0,shadowOffsetY:0,xAdjust:0,xMax:void 0,xMin:void 0,xScaleID:void 0,xValue:void 0,yAdjust:0,yMax:void 0,yMin:void 0,yScaleID:void 0,yValue:void 0,z:0};fd.defaultRoutes={borderColor:"color",backgroundColor:"color"};var hd=class extends br{inRange(e,n,r,i){if(r!=="x"&&r!=="y")return this.options.radius>=.1&&this.elements.length>1&&v7(this.elements,e,n,i);let o=Uc({x:e,y:n},this.getCenterPoint(i),Qn(-this.options.rotation)),s=this.elements.map(h=>r==="y"?h.bY:h.bX),c=Math.min(...s),p=Math.max(...s);return o[r]>=c&&o[r]<=p}getCenterPoint(e){return md(this,e)}draw(e){let{elements:n,options:r}=this;e.save(),e.beginPath(),e.fillStyle=r.backgroundColor,gd(e,r);let i=Sl(e,r),o=true;for(let s of n)o?(e.moveTo(s.x,s.y),o=false):e.lineTo(s.x,s.y);e.closePath(),e.fill(),i&&(e.shadowColor=r.borderShadowColor,e.stroke()),e.restore();}resolveElementProperties(e,n){let r=HI(e,n),{sides:i,rotation:o}=n,s=[],c=2*Be/i,p=o*lf;for(let h=0;h<i;h++,p+=c){let v=b7(r,n,p);v.initProperties=Lf(e,r,n),s.push(v);}return r.elements=s,r}};hd.id="polygonAnnotation";hd.defaults={adjustScaleRange:true,backgroundShadowColor:"transparent",borderCapStyle:"butt",borderDash:[],borderDashOffset:0,borderJoinStyle:"miter",borderShadowColor:"transparent",borderWidth:1,display:true,init:void 0,point:{radius:0},radius:10,rotation:0,shadowBlur:0,shadowOffsetX:0,shadowOffsetY:0,sides:3,xAdjust:0,xMax:void 0,xMin:void 0,xScaleID:void 0,xValue:void 0,yAdjust:0,yMax:void 0,yMin:void 0,yScaleID:void 0,yValue:void 0,z:0};hd.defaultRoutes={borderColor:"color",backgroundColor:"color"};function b7({centerX:t,centerY:e},{radius:n,borderWidth:r},i){let o=r/2,s=Math.sin(i),c=Math.cos(i),p={x:t+s*n,y:e-c*n};return {type:"point",optionScope:"point",properties:{x:p.x,y:p.y,centerX:p.x,centerY:p.y,bX:t+s*(n+o),bY:e-c*(n+o)}}}function v7(t,e,n,r){let i=false,o=t[t.length-1].getProps(["bX","bY"],r);for(let s of t){let c=s.getProps(["bX","bY"],r);c.bY>n!=o.bY>n&&e<(o.bX-c.bX)*(n-c.bY)/(o.bY-c.bY)+c.bX&&(i=!i),o=c;}return i}var vl={box:Pl,ellipse:Bc,label:Nc,line:Lc,point:fd,polygon:hd};Object.keys(vl).forEach(t=>{ke.describe(`elements.${vl[t].id}`,{_fallback:"plugins.annotation.common"});});var C7={update:Object.assign},S7=E1.concat(wy),FI=(t,e)=>Te(e)?y1(t,e):t,g1=t=>t==="color"||t==="font";function T1(t="line"){return vl[t]?t:(console.warn(`Unknown annotation type: '${t}', defaulting to 'line'`),"line")}function P7(t,e,n,r){let i=E7(t,n.animations,r),o=e.annotations,s=w7(e.elements,o);for(let c=0;c<o.length;c++){let p=o[c],h=XI(s,c,p.type),v=p.setContext(T7(t,h,p)),P=h.resolveElementProperties(t,v);P.skip=x7(P),"elements"in P&&(_7(h,P.elements,v,i),delete P.elements),Fn(h.x)||Object.assign(h,P),Object.assign(h,P.initProperties),P.options=ZI(v),i.update(h,P);}}function x7(t){return isNaN(t.x)||isNaN(t.y)}function E7(t,e,n){return n==="reset"||n==="none"||n==="resize"?C7:new sd(t,e)}function _7(t,e,n,r){let i=t.elements||(t.elements=[]);i.length=e.length;for(let o=0;o<e.length;o++){let s=e[o],c=s.properties,p=XI(i,o,s.type,s.initProperties),h=n[s.optionScope].override(s);c.options=ZI(h),r.update(p,c);}}function XI(t,e,n,r){let i=vl[T1(n)],o=t[e];return (!o||!(o instanceof i))&&(o=t[e]=new i,Object.assign(o,r)),o}function ZI(t){let e=vl[T1(t.type)],n={};n.id=t.id,n.type=t.type,n.drawTime=t.drawTime,Object.assign(n,y1(t,e.defaults),y1(t,e.defaultRoutes));for(let r of S7)n[r]=t[r];return n}function y1(t,e){let n={};for(let r of Object.keys(e)){let i=e[r],o=t[r];g1(r)&&He(o)?n[r]=o.map(s=>FI(s,i)):n[r]=FI(o,i);}return n}function T7(t,e,n){return e.$context||(e.$context=Object.assign(Object.create(t.getContext()),{element:e,id:n.id,type:"annotation"}))}function w7(t,e){let n=e.length,r=t.length;if(r<n){let i=n-r;t.splice(r,0,...new Array(i));}else r>n&&t.splice(n,r-n);return t}var I7="2.2.1",bl=new Map,k7=E1.concat(wy),JI={id:"annotation",version:I7,beforeRegister(){y8("chart.js","3.7",bo.version);},afterRegister(){bo.register(vl);},afterUnregister(){bo.unregister(vl);},beforeInit(t){bl.set(t,{annotations:[],elements:[],visibleElements:[],listeners:{},listened:false,moveListened:false,hooks:{},hooked:false,hovered:[]});},beforeUpdate(t,e,n){let r=bl.get(t),i=r.annotations=[],o=n.annotations;Te(o)?Object.keys(o).forEach(s=>{let c=o[s];Te(c)&&(c.id=s,i.push(c));}):He(o)&&i.push(...o),V8(i,t.scales);},afterDataLimits(t,e){let n=bl.get(t);j8(t,e.scale,n.annotations.filter(r=>r.display&&r.adjustScaleRange));},afterUpdate(t,e,n){let r=bl.get(t);L8(t,r,n),P7(t,r,n,e.mode),r.visibleElements=r.elements.filter(i=>!i.skip&&i.options.display),G8(t,r,n);},beforeDatasetsDraw(t,e,n){_y(t,"beforeDatasetsDraw",n.clip);},afterDatasetsDraw(t,e,n){_y(t,"afterDatasetsDraw",n.clip);},beforeDraw(t,e,n){_y(t,"beforeDraw",n.clip);},afterDraw(t,e,n){_y(t,"afterDraw",n.clip);},beforeEvent(t,e,n){let r=bl.get(t);B8(r,e.event,n)&&(e.changed=true);},afterDestroy(t){bl.delete(t);},_getState(t){return bl.get(t)},defaults:{animations:{numbers:{properties:["x","y","x2","y2","width","height","centerX","centerY","pointX","pointY","radius"],type:"number"}},clip:true,interaction:{mode:void 0,axis:void 0,intersect:void 0},common:{drawTime:"afterDatasetsDraw",init:false,label:{}}},descriptors:{_indexable:false,_scriptable:t=>!k7.includes(t)&&t!=="init",annotations:{_allKeys:false,_fallback:(t,e)=>`elements.${vl[T1(e.type)].id}`},interaction:{_fallback:true},common:{label:{_indexable:g1,_fallback:true},_indexable:g1}},additionalOptionScopes:[""]};function _y(t,e,n){let{ctx:r,chartArea:i}=t,o=bl.get(t);n&&fl(r,i);let s=D7(o.visibleElements,e).sort((c,p)=>c.element.options.z-p.element.options.z);for(let c of s)A7(r,i,o,c);n&&hl(r);}function D7(t,e){let n=[];for(let r of t)if(r.options.drawTime===e&&n.push({element:r,main:true}),r.elements&&r.elements.length)for(let i of r.elements)i.options.display&&i.options.drawTime===e&&n.push({element:i});return n}function A7(t,e,n,r){let i=r.element;r.main?(CI(n,i,"beforeDraw"),i.draw(t,e),CI(n,i,"afterDraw")):i.draw(t,e);}var I1=bo.version,O7=I1?(t,e)=>t.parse(e):(t,e)=>e;function R7(t,e){let n=Vi(e)?parseFloat(e):O7(t,e);return t.getPixelForValue(n)}var tk=t=>t&&t.right>t.left&&t.bottom>t.top;function ek(t,e,n){return e==="r"?t.createRadialGradient(n.xCenter,n.yCenter,0,n.xCenter,n.yCenter,n.drawingArea):e==="y"?t.createLinearGradient(0,n.bottom,0,n.top):t.createLinearGradient(n.left,0,n.right,0)}function nk(t,e){e.forEach(function(n){t.addColorStop(n.stop,n.color.rgbString());});}function rk(t,e,n){if(t.options.has(e.key)){let i=t.options.get(e.key).filter(o=>o.datasetIndex===n);if(i.length)return i[0]}}function ik(t,e){if(t.type==="radialLinear"){let o=t.getDistanceFromCenterForValue(e);return {pixel:o,stop:o/t.drawingArea}}let n=t.options.reverse,r=R7(t,e),i=t.getDecimalForPixel(r);return {pixel:r,stop:n?1-i:i}}var w1=t=>t<=.0031308?t*12.92:Math.pow(t,1/2.4)*1.055-.055,yd=t=>t<=.04045?t/12.92:Math.pow((t+.055)/1.055,2.4);function F7(t,e,n){let r=e.color.rgb,i=yd(r.r/255),o=yd(r.g/255),s=yd(r.b/255),c=n.color.rgb,p=yd(c.r/255),h=yd(c.g/255),v=yd(c.b/255);return Ic({r:Math.round(w1(i+t*(p-i))*255),g:Math.round(w1(o+t*(h-o))*255),b:Math.round(w1(s+t*(v-s))*255),a:r.a+t*Math.abs(c.a-r.a)})}function M7(t,e,n,r){let i=rk(t,e,n);if(!i||!i.stopColors.length)return;let{stop:o}=ik(i.scale,r),s,c;for(let p of i.stopColors){if(p.stop===o)return p.color;p.stop<o?s=p:p.stop>o&&!c&&(c=p);}return c?F7(o,s,c):s}var ok=[{key:"backgroundColor",legendItemKey:"fillStyle"},{key:"borderColor",legendItemKey:"strokeStyle"}],N7=(t,e)=>e.labels&&e.labels.font&&Fn(e.labels.font.size)?e.labels.font.size:t.options.font.size;function L7(t,e,n,r,i){let o=rk(t,n,r.datasetIndex);if(!o||!o.stopColors.length)return;let s=ek(e,o.axis,i);nk(s,o.stopColors),r[n.legendItemKey]=s;}function B7(t,{boxWidth:e,boxHeight:n}){return {top:t.top,left:t.left,bottom:t.top+n,right:t.left+e,xCenter:t.left+e/2,yCenter:t.top+n/2,drawingArea:Math.max(e,n)/2}}function U7(t,e,n,r){let i=t.legend.legendHitBoxes[n.datasetIndex],o=B7(i,r);tk(o)&&ok.forEach(function(s){L7(e,t.ctx,s,n,o);});}function $7(t,e,n,r){for(let i of t.legend.legendItems)ok.forEach(function(o){let s=n.data[i.index],c=M7(e,o,r,s);c&&c.valid&&(i[o.legendItemKey]=c.rgbString());});}function G7(t,e){let n=t.legend,r=n.options,i=r.labels.boxHeight?r.labels.boxHeight:N7(t,r),o=r.labels.boxWidth,s=t.data.datasets;for(let c=0;c<s.length;c++){let p=n.legendItems[c];p.datasetIndex===c?U7(t,e,p,{boxWidth:o,boxHeight:i}):$7(t,e,s[c],c);}}var Dy=new Map,j7=I1?(t,e)=>t[e+"Scale"]:(t,e)=>t.controller["_"+e+"Scale"];function V7(t,e,n){for(let r of Object.keys(e)){let{pixel:i,stop:o}=ik(t,r);if(isFinite(i)&&isFinite(o)){let s=Ic(e[r]);s&&s.valid&&n.push({stop:Math.max(0,Math.min(1,o)),color:s});}}n.sort((r,i)=>r.stop-i.stop);}function z7(t,e,n,r){e[n]=r,t.dataset&&(t.dataset.options?t.dataset.options[n]=r:t.dataset[n]=r);}function H7(t,e,n,r){let i=t.options.get(n);return i?e.hidden||(i=i.filter(o=>o.datasetIndex!==r),t.options.set(n,i)):(i=[],t.options.set(n,i)),i}function W7(t,e,n,r,i){let o=t.ctx,s=t.getDatasetMeta(i);if(!s.hidden)for(let[c,p]of Object.entries(n)){let{axis:h,colors:v}=p;if(!v)continue;let P=j7(s,h);if(!P){console.warn(`Scale not found for '${h}'-axis in datasets[${i}] of chart id ${t.id}, skipping.`);continue}let x=H7(e,s,c,i),T={datasetIndex:i,axis:h,scale:P,stopColors:[]};x.push(T);let I=ek(o,h,P);V7(P,v,T.stopColors),T.stopColors.length&&(nk(I,T.stopColors),z7(s,r,c,I));}}var ak={id:"gradient",beforeInit(t){let e={};e.options=new Map,Dy.set(t,e);},beforeDatasetsUpdate(t){let e=t.chartArea;if(!tk(e))return;let n=Dy.get(t),r=t.data.datasets;for(let i=0;i<r.length;i++){let o=r[i],s=o.gradient;s&&W7(t,n,s,o,i);}},afterUpdate(t){let e=Dy.get(t);t.legend&&t.legend.options.display!==false&&I1&&G7(t,e);},destroy(t){Dy.delete(t);}};var q7=[Rc,cd,ds,nI,rI,eI,mI,us,Go,tI,cs,JI,ak];bo.register(...q7);function Ay(t){let e=ve(),n=e==null?void 0:e.stigg,r=e==null?void 0:e.updatedAt,i=Uv.useCallback(()=>ce(null,null,function*(){if(!n||!n.isCustomerLoaded)return null;try{let p={currencyId:t.currencyId,timeRange:t.timeRange};return yield n.getCreditUsage(p)}catch(p){throw console.error(p),p}}),[n,t.currencyId,t.timeRange,r]),{data:o,error:s,isLoading:c}=co({func:i});return Uv.useMemo(()=>({creditUsage:o,isLoading:c,error:s}),[o,s,c])}var sk={id:"redrawBeforeFirstDrawPlugin",beforeDraw(t){t.$rendered||(t.$rendered=true,t.update("none"));}};var k1=(t,e=1)=>{let n=Math.round(e*255).toString(16).padStart(2,"0");return `${t}${n}`};var D1=t=>t.palette.text.secondary,A1=t=>t.palette.outlinedBorder,O1=t=>({family:t.typography.fontFamily,size:parseInt(t.typography.body.fontSize)});function R1(t){let e=["#4caf50","#2196f3","#ff5722","#ff9800","#e91e63","#3f51b5","#00bcd4","#81c784","#64b5f6","#ff8a65","#ffb74d","#f06292","#7986cb","#4dd0e1","#a5d6a7","#90caf9","#ffab91","#ffcc80","#f48fb1","#9fa8da","#80deea"];return e[t%e.length]}function K7(t){let e=[],n=new Date;switch(t){case yi.LastDay:{let r=new Date(n);r.setHours(r.getHours()-23),r.setMinutes(0,0,0);for(let i=0;i<24;i++){let o=new Date(r);o.setHours(o.getHours()+i),e.push(o.toLocaleTimeString("en-US",{hour:"2-digit",minute:"2-digit"}));}break}case yi.LastWeek:{for(let r=6;r>=0;r--){let i=new Date(n);i.setDate(i.getDate()-r),e.push(i.toLocaleDateString("en-US",{month:"short",day:"2-digit"}));}break}case yi.LastYear:{for(let r=11;r>=0;r--){let i=new Date(n);i.setMonth(i.getMonth()-r),e.push(i.toLocaleDateString("en-US",{month:"short",year:"2-digit"}));}break}case yi.LastMonth:default:{for(let r=29;r>=0;r--){let i=new Date(n);i.setDate(i.getDate()-r),e.push(i.toLocaleDateString("en-US",{month:"short",day:"2-digit"}));}break}}return e}function X7(t,e){let n=new Date(t);switch(n.setMinutes(0,0,0),e){case yi.LastDay:return n.toLocaleTimeString("en-US",{hour:"2-digit",minute:"2-digit"});case yi.LastYear:return t.toLocaleDateString("en-US",{month:"short",year:"2-digit"});case yi.LastWeek:case yi.LastMonth:default:return t.toLocaleDateString("en-US",{month:"short",day:"2-digit"})}}function Z7(t,e){return {responsive:true,maintainAspectRatio:false,interaction:{mode:"point",intersect:true},elements:{bar:{borderRadius:4,borderSkipped:"bottom"}},plugins:{legend:{display:false},tooltip:{enabled:false,external:e},datalabels:{display:false}},scales:{x:{type:"category",stacked:true,ticks:{color:D1(t),font:O1(t),maxRotation:45,maxTicksLimit:15},grid:{color:A1(t),drawOnChartArea:false,drawTicks:false}},y:{type:"linear",stacked:true,beginAtZero:true,ticks:{color:D1(t),font:O1(t),callback:n=>gr(Number(n))},grid:{color:k1(A1(t),.5),drawOnChartArea:true,drawTicks:false,borderDash:[5,5]}}}}}function lk(t,e,n,r){let i=K7(r);if(!t||!t.series||t.series.length===0)return {data:null,options:null};let o=t.series.map((p,h)=>{let v=p.featureName,P=new Map;p.points.forEach(I=>{let R=X7(new Date(I.timestamp),r),A=P.get(R)||0;P.set(R,A+I.value);});let x=i.map(I=>P.get(I)||0),T=R1(h);return {label:v,data:x,backgroundColor:k1(T,.8),borderColor:T,borderWidth:1}}).reverse(),s={labels:i,datasets:o},c=Z7(e,n);return {data:s,options:c}}var i9=300;function uk(t,e){let n=e.dataPoints[0],r=n.parsed.y,i=t.scales.y,o=r/i.max*(i.bottom-i.top),s=e.caretY+o/2,c=t.getDatasetMeta(n.datasetIndex).data[n.dataIndex],p=c.x-c.width/2,h=t.canvas.offsetTop+s,v=t.canvas.offsetLeft+p;return {top:h,left:v}}function o9(t,e){let n=t.canvas.offsetTop+e.caretY,r=t.canvas.offsetLeft+e.caretX;return {top:n,left:r}}function dk(t,e=o9){let[n,r]=Uv.useState(0),[i,o]=Uv.useState(0),[s,c]=Uv.useState(false),[p,h]=Uv.useState(),v=Uv.useCallback(x=>{let{chart:T,tooltip:I}=x;if(I.opacity===0){c(false);return}let{top:R,left:A}=e(T,I);o(A),r(R),h(t(I)),c(true);},[t,e]);return {tooltipInfo:{positionTop:n,positionLeft:i,isOpen:s,payload:p},tooltipHandler:v}}var a9=Q(material.Box)`
5650
5650
  position: absolute;
5651
5651
  `,s9=Q.div`
5652
5652
  position: absolute;
@@ -5761,7 +5761,7 @@ ${e.o5f}`,e.zBW=r.default`
5761
5761
  border-radius: 4px;
5762
5762
  height: 400px;
5763
5763
  width: 100%;
5764
- `;function Ek({currencyId:t,timeRange:e,localization:n}){var N,V;let r=pc(),i=ve({optional:true}),o=i==null?void 0:i.stigg,s=W(W({},dT),n),[c,p]=Uv.useState(e),{creditUsage:h,isLoading:v,error:P}=Ay({currencyId:t,timeRange:c}),{tooltipInfo:x,tooltipHandler:T}=mk(),{data:I,options:F}=Uv.useMemo(()=>lk(h||null,r,T,c),[h,r,T,c]),A=Uv.useMemo(()=>(h==null?void 0:h.series.reduce((G,X)=>G+X.totalCredits,0))||0,[h]),O=(V=(N=h==null?void 0:h.currency)==null?void 0:N.units)==null?void 0:V.plural;return jsxRuntime.jsx(vi,{componentTheme:r,children:jsxRuntime.jsxs(O9,{className:"stigg-credit-usage-chart-container",children:[jsxRuntime.jsx(R9,{className:"stigg-credit-usage-chart-card",children:jsxRuntime.jsxs("div",{style:{width:"100%"},children:[jsxRuntime.jsx(Pk,{isLoading:v,totalCredits:A,selectedTimeRange:c,setSelectedTimeRange:p,error:P,localization:s,currencyUnit:O}),jsxRuntime.jsxs("div",{style:{display:"flex",flexDirection:"column",gap:4},children:[jsxRuntime.jsx("div",{style:{height:"400px",position:"relative"},children:v?jsxRuntime.jsx(F9,{className:"stigg-credit-usage-chart-skeleton"}):P?jsxRuntime.jsx(Ck,{}):(h==null?void 0:h.series.length)===0?jsxRuntime.jsx(bk,{}):jsxRuntime.jsxs(jsxRuntime.Fragment,{children:[jsxRuntime.jsx(hk,{tooltipInfo:x}),jsxRuntime.jsx(reactChartjs2.Bar,{className:"stigg-credit-usage-chart-bar",data:I!=null?I:{labels:[],datasets:[]},options:F!=null?F:{},plugins:[sk]})]})}),!v&&jsxRuntime.jsx(gk,{creditUsageData:h})]})]})}),jsxRuntime.jsx(so,{source:"credit_usage_chart",align:"end",smallScreenAlign:"end",style:{marginTop:0},showWatermark:o==null?void 0:o.getShowWatermark()})]})})}var N9=(t,e)=>t>=100?e.palette.progress.high:t>=75?e.palette.progress.medium:e.palette.progress.low,L9=Q.div`
5764
+ `;function Ek({currencyId:t,timeRange:e,localization:n}){var N,V;let r=pc(),i=ve({optional:true}),o=i==null?void 0:i.stigg,s=W(W({},dT),n),[c,p]=Uv.useState(e),{creditUsage:h,isLoading:v,error:P}=Ay({currencyId:t,timeRange:c}),{tooltipInfo:x,tooltipHandler:T}=mk(),{data:I,options:R}=Uv.useMemo(()=>lk(h||null,r,T,c),[h,r,T,c]),A=Uv.useMemo(()=>(h==null?void 0:h.series.reduce((G,X)=>G+X.totalCredits,0))||0,[h]),O=(V=(N=h==null?void 0:h.currency)==null?void 0:N.units)==null?void 0:V.plural;return jsxRuntime.jsx(vi,{componentTheme:r,children:jsxRuntime.jsxs(O9,{className:"stigg-credit-usage-chart-container",children:[jsxRuntime.jsx(R9,{className:"stigg-credit-usage-chart-card",children:jsxRuntime.jsxs("div",{style:{width:"100%"},children:[jsxRuntime.jsx(Pk,{isLoading:v,totalCredits:A,selectedTimeRange:c,setSelectedTimeRange:p,error:P,localization:s,currencyUnit:O}),jsxRuntime.jsxs("div",{style:{display:"flex",flexDirection:"column",gap:4},children:[jsxRuntime.jsx("div",{style:{height:"400px",position:"relative"},children:v?jsxRuntime.jsx(F9,{className:"stigg-credit-usage-chart-skeleton"}):P?jsxRuntime.jsx(Ck,{}):(h==null?void 0:h.series.length)===0?jsxRuntime.jsx(bk,{}):jsxRuntime.jsxs(jsxRuntime.Fragment,{children:[jsxRuntime.jsx(hk,{tooltipInfo:x}),jsxRuntime.jsx(reactChartjs2.Bar,{className:"stigg-credit-usage-chart-bar",data:I!=null?I:{labels:[],datasets:[]},options:R!=null?R:{},plugins:[sk]})]})}),!v&&jsxRuntime.jsx(gk,{creditUsageData:h})]})]})}),jsxRuntime.jsx(so,{source:"credit_usage_chart",align:"end",smallScreenAlign:"end",style:{marginTop:0},showWatermark:o==null?void 0:o.getShowWatermark()})]})})}var N9=(t,e)=>t>=100?e.palette.progress.high:t>=75?e.palette.progress.medium:e.palette.progress.low,L9=Q.div`
5765
5765
  width: 100%;
5766
5766
  height: 8px;
5767
5767
  background-color: ${({theme:t})=>t.stigg.palette.progress.background};
@@ -5851,7 +5851,7 @@ ${e.o5f}`,e.zBW=r.default`
5851
5851
  width: 100%;
5852
5852
  `,f$=Q(material.TablePagination)`
5853
5853
  color: ${({theme:t})=>t.stigg.palette.text.secondary};
5854
- `;function h$({visibleHeadCells:t}){return jsxRuntime.jsx(material.TableHead,{children:jsxRuntime.jsx(material.TableRow,{children:t.map(e=>jsxRuntime.jsx(p$,{$alignment:e.alignment,$width:e.width,$maxWidth:e.maxWidth,$minWidth:e.minWidth,children:jsxRuntime.jsx(rt,{variant:"caption",children:e.label})},String(e.id)))})})}function Gy({data:t,headCells:e,isLoading:n=false,error:r=null,emptyMessage:i,errorMessage:o,onRowClick:s,className:c,skeletonRows:p=3,hideLastRowBorder:h=true,pageSize:v,pageNum:P,totalCount:x,onPageChange:T}){let I=e.filter(A=>A.visible!==false),F=!!r||!n&&t.length===0;return jsxRuntime.jsx(c$,{className:c,$hasMinHeight:F,children:r?jsxRuntime.jsx(Uy,{errorMessage:o,className:`${c}-error`}):!n&&t.length===0?jsxRuntime.jsx($y,{message:i,className:`${c}-empty`}):jsxRuntime.jsxs(jsxRuntime.Fragment,{children:[jsxRuntime.jsxs(u$,{children:[jsxRuntime.jsx(h$,{visibleHeadCells:I}),jsxRuntime.jsx(material.TableBody,{children:n?jsxRuntime.jsx(M1,{skeletonRows:p,visibleHeadCells:I,hideLastRowBorder:h}):jsxRuntime.jsx(N1,{data:t,visibleHeadCells:I,onRowClick:s,hideLastRowBorder:h})})]}),!!(t!=null&&t.length)&&T&&jsxRuntime.jsxs(jsxRuntime.Fragment,{children:[jsxRuntime.jsx(d$,{}),jsxRuntime.jsx(f$,{component:"div",rowsPerPage:v!=null?v:t.length,rowsPerPageOptions:[v!=null?v:t.length],count:x!=null?x:t.length,page:P!=null?P:1,onPageChange:T,labelDisplayedRows:({from:A,to:O,count:N})=>`${Ya(A)}-${Ya(O)} of ${N!==-1?Ya(N):`more than ${Ya(O)}`}`})]})]})})}var g$=Q(material.Chip)`
5854
+ `;function h$({visibleHeadCells:t}){return jsxRuntime.jsx(material.TableHead,{children:jsxRuntime.jsx(material.TableRow,{children:t.map(e=>jsxRuntime.jsx(p$,{$alignment:e.alignment,$width:e.width,$maxWidth:e.maxWidth,$minWidth:e.minWidth,children:jsxRuntime.jsx(rt,{variant:"caption",children:e.label})},String(e.id)))})})}function Gy({data:t,headCells:e,isLoading:n=false,error:r=null,emptyMessage:i,errorMessage:o,onRowClick:s,className:c,skeletonRows:p=3,hideLastRowBorder:h=true,pageSize:v,pageNum:P,totalCount:x,onPageChange:T}){let I=e.filter(A=>A.visible!==false),R=!!r||!n&&t.length===0;return jsxRuntime.jsx(c$,{className:c,$hasMinHeight:R,children:r?jsxRuntime.jsx(Uy,{errorMessage:o,className:`${c}-error`}):!n&&t.length===0?jsxRuntime.jsx($y,{message:i,className:`${c}-empty`}):jsxRuntime.jsxs(jsxRuntime.Fragment,{children:[jsxRuntime.jsxs(u$,{children:[jsxRuntime.jsx(h$,{visibleHeadCells:I}),jsxRuntime.jsx(material.TableBody,{children:n?jsxRuntime.jsx(M1,{skeletonRows:p,visibleHeadCells:I,hideLastRowBorder:h}):jsxRuntime.jsx(N1,{data:t,visibleHeadCells:I,onRowClick:s,hideLastRowBorder:h})})]}),!!(t!=null&&t.length)&&T&&jsxRuntime.jsxs(jsxRuntime.Fragment,{children:[jsxRuntime.jsx(d$,{}),jsxRuntime.jsx(f$,{component:"div",rowsPerPage:v!=null?v:t.length,rowsPerPageOptions:[v!=null?v:t.length],count:x!=null?x:t.length,page:P!=null?P:1,onPageChange:T,labelDisplayedRows:({from:A,to:O,count:N})=>`${Ya(A)}-${Ya(O)} of ${N!==-1?Ya(N):`more than ${Ya(O)}`}`})]})]})})}var g$=Q(material.Chip)`
5855
5855
  font-size: 0.75rem;
5856
5856
  height: 24px;
5857
5857
  border-radius: 4px;
@@ -5866,7 +5866,7 @@ ${e.o5f}`,e.zBW=r.default`
5866
5866
  display: flex;
5867
5867
  flex-direction: column;
5868
5868
  gap: 16px;
5869
- `;function $k({currencyId:t,localization:e,decimalPlaces:n,pageSize:r=S$}){let i=ve({optional:true}),o=i==null?void 0:i.stigg,s=i==null?void 0:i.theme,c=W(W({},uT),e),[p,h]=Uv.useState({first:r}),{creditGrants:v,isLoading:P,error:x,paging:T,totalCount:I}=Ny({currencyId:t,pageSize:r,paging:p}),{pageNumber:F,pageChangeFunc:A}=Uk(T,h,r);return jsxRuntime.jsx(vi,{componentTheme:s,children:jsxRuntime.jsxs(P$,{className:"stigg-credit-grants-container",children:[jsxRuntime.jsx(x$,{className:"stigg-credit-grants-card",children:jsxRuntime.jsx(Lk,{creditGrants:v,isLoading:P,error:x,localization:c,decimalPlaces:n,pageSize:r,pageNum:F,totalCount:I,onPageChange:A})}),jsxRuntime.jsx(so,{source:"grant_list",align:"end",smallScreenAlign:"end",style:{marginTop:0},showWatermark:o==null?void 0:o.getShowWatermark()})]})})}/*! Bundled license information:
5869
+ `;function $k({currencyId:t,localization:e,decimalPlaces:n,pageSize:r=S$}){let i=ve({optional:true}),o=i==null?void 0:i.stigg,s=i==null?void 0:i.theme,c=W(W({},uT),e),[p,h]=Uv.useState({first:r}),{creditGrants:v,isLoading:P,error:x,paging:T,totalCount:I}=Ny({currencyId:t,pageSize:r,paging:p}),{pageNumber:R,pageChangeFunc:A}=Uk(T,h,r);return jsxRuntime.jsx(vi,{componentTheme:s,children:jsxRuntime.jsxs(P$,{className:"stigg-credit-grants-container",children:[jsxRuntime.jsx(x$,{className:"stigg-credit-grants-card",children:jsxRuntime.jsx(Lk,{creditGrants:v,isLoading:P,error:x,localization:c,decimalPlaces:n,pageSize:r,pageNum:R,totalCount:I,onPageChange:A})}),jsxRuntime.jsx(so,{source:"grant_list",align:"end",smallScreenAlign:"end",style:{marginTop:0},showWatermark:o==null?void 0:o.getShowWatermark()})]})})}/*! Bundled license information:
5870
5870
 
5871
5871
  @stigg/js-client-sdk/dist/index.esm.js:
5872
5872
  (*! For license information please see index.esm.js.LICENSE.txt *)