1(globalThis.TURBOPACK||(globalThis.TURBOPACK=[])).push(["object"==typeof document?document.currentScript:void 0,710273,(e,t,r)=>{"use strict";t.exports={ACTOR_CHANGE:"ActorChange",CATCH_FIELD:"CatchField",CONDITION:"Condition",CLIENT_COMPONENT:"ClientComponent",CLIENT_EDGE_TO_SERVER_OBJECT:"ClientEdgeToServerObject",CLIENT_EDGE_TO_CLIENT_OBJECT:"ClientEdgeToClientObject",CLIENT_EXTENSION:"ClientExtension",DEFER:"Defer",CONNECTION:"Connection",FRAGMENT:"Fragment",FRAGMENT_SPREAD:"FragmentSpread",INLINE_DATA_FRAGMENT_SPREAD:"InlineDataFragmentSpread",INLINE_DATA_FRAGMENT:"InlineDataFragment",INLINE_FRAGMENT:"InlineFragment",LINKED_FIELD:"LinkedField",LINKED_HANDLE:"LinkedHandle",LITERAL:"Literal",LIST_VALUE:"ListValue",LOCAL_ARGUMENT:"LocalArgument",MODULE_IMPORT:"ModuleImport",ALIASED_FRAGMENT_SPREAD:"AliasedFragmentSpread",ALIASED_INLINE_FRAGMENT_SPREAD:"AliasedInlineFragmentSpread",RELAY_RESOLVER:"RelayResolver",RELAY_LIVE_RESOLVER:"RelayLiveResolver",REQUIRED_FIELD:"RequiredField",OBJECT_VALUE:"ObjectValue",OPERATION:"Operation",REQUEST:"Request",ROOT_ARGUMENT:"RootArgument",SCALAR_FIELD:"ScalarField",SCALAR_HANDLE:"ScalarHandle",SPLIT_OPERATION:"SplitOperation",STREAM:"Stream",TYPE_DISCRIMINATOR:"TypeDiscriminator",UPDATABLE_QUERY:"UpdatableQuery",VARIABLE:"Variable"}},638743,(e,t,r)=>{"use strict";t.exports=function(e,t,r,i,n,s,a,o){if(!e){var l;if(void 0===t)l=Error("Minified exception occurred; use the non-minified dev environment for the full error message and additional helpful warnings.");else{var u=[r,i,n,s,a,o],c=0;(l=Error(t.replace(/%s/g,function(){return u[c++]}))).name="Invariant Violation"}throw l.framesToPop=1,l}}},852896,(e,t,r)=>{"use strict";function i(e){return function(){return e}}var n=function(){};n.thatReturns=i,n.thatReturnsFalse=i(!1),n.thatReturnsTrue=i(!0),n.thatReturnsNull=i(null),n.thatReturnsThis=function(){return this},n.thatReturnsArgument=function(e){return e},t.exports=n},603158,(e,t,r)=>{"use strict";t.exports=e.r(852896)},930649,(e,t,r)=>{"use strict";var i=e.r(710273),n=e.r(638743);function s(e){var t=e;return"function"==typeof t?t=t():t.default&&(t=t.default),t}function a(e){var t=s(e);return"object"==typeof t&&null!==t&&t.kind===i.FRAGMENT}function o(e){var t=s(e);return"object"==typeof t&&null!==t&&t.kind===i.REQUEST}function l(e){var t=s(e);return"object"==typeof t&&null!==t&&t.kind===i.UPDATABLE_QUERY}function u(e){var t=s(e);return"object"==typeof t&&null!==t&&t.kind===i.INLINE_DATA_FRAGMENT}function c(e){var t=s(e);return a(t)||n(!1),t}e.r(603158),t.exports={getFragment:c,getNode:s,getPaginationFragment:function(e){var t,r=c(e),i=null==(t=r.metadata)?void 0:t.refetch,n=null==i?void 0:i.connection;return null===i||"object"!=typeof i||null===n||"object"!=typeof n?null:r},getRefetchableFragment:function(e){var t,r=c(e),i=null==(t=r.metadata)?void 0:t.refetch;return null===i||"object"!=typeof i?null:r},getRequest:function(e){var t=s(e);return o(t)||n(!1),t},getUpdatableQuery:function(e){var t=s(e);return l(t)||n(!1),t},getInlineDataFragment:function(e){var t=s(e);return u(t)||n(!1),t},graphql:function(e){n(!1)},isFragment:a,isRequest:o,isUpdatableQuery:l,isInlineDataFragment:u}},13451,(e,t,r)=>{t.exports=function(e){return e&&e.__esModule?e:{default:e}},t.exports.__esModule=!0,t.exports.default=t.exports},935045,(e,t,r)=>{function i(e){return t.exports=i="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},t.exports.__esModule=!0,t.exports.default=t.exports,i(e)}t.exports=i,t.exports.__esModule=!0,t.exports.default=t.exports},226252,(e,t,r)=>{var i=e.r(935045).default;t.exports=function(e,t){if("object"!=i(e)||!e)return e;var r=e[Symbol.toPrimitive];if(void 0!==r){var n=r.call(e,t||"default");if("object"!=i(n))return n;throw TypeError("@@toPrimitive must return a primitive value.")}return("string"===t?String:Number)(e)},t.exports.__esModule=!0,t.exports.default=t.exports},863974,(e,t,r)=>{var i=e.r(935045).default,n=e.r(226252);t.exports=function(e){var t=n(e,"string");return"symbol"==i(t)?t:t+""}
1,t.exports.__esModule=!0,t.exports.default=t.exports},514414,(e,t,r)=>{var i=e.r(863974);t.exports=function(e,t,r){return(t=i(t))in e?Object.defineProperty(e,t,{value:r,enumerable:!0,configurable:!0,writable:!0}):e[t]=r,e},t.exports.__esModule=!0,t.exports.default=t.exports},802953,(e,t,r)=>{var i=e.r(514414);function n(e,t){var r=Object.keys(e);if(Object.getOwnPropertySymbols){var i=Object.getOwnPropertySymbols(e);t&&(i=i.filter(function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable})),r.push.apply(r,i)}return r}t.exports=function(e){for(var t=1;t<arguments.length;t++){var r=null!=arguments[t]?arguments[t]:{};t%2?n(Object(r),!0).forEach(function(t){i(e,t,r[t])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(r)):n(Object(r)).forEach(function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(r,t))})}return e},t.exports.__esModule=!0,t.exports.default=t.exports},427500,(e,t,r)=>{t.exports=function(e,t){(null==t||t>e.length)&&(t=e.length);for(var r=0,i=Array(t);r<t;r++)i[r]=e[r];return i},t.exports.__esModule=!0,t.exports.default=t.exports},737906,(e,t,r)=>{var i=e.r(427500);t.exports=function(e,t){if(e){if("string"==typeof e)return i(e,t);var r=({}).toString.call(e).slice(8,-1);return"Object"===r&&e.constructor&&(r=e.constructor.name),"Map"===r||"Set"===r?Array.from(e):"Arguments"===r||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(r)?i(e,t):void 0}},t.exports.__esModule=!0,t.exports.default=t.exports},877913,(e,t,r)=>{var i=e.r(737906);t.exports=function(e,t){var r="u">typeof Symbol&&e[Symbol.iterator]||e["@@iterator"];if(!r){if(Array.isArray(e)||(r=i(e))||t&&e&&"number"==typeof e.length){r&&(e=r);var n=0,s=function(){};return{s:s,n:function(){return n>=e.length?{done:!0}:{done:!1,value:e[n++]}},e:function(e){throw e},f:s}}throw TypeError("Invalid attempt to iterate non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}var a,o=!0,l=!1;return{s:function(){r=r.call(e)},n:function(){var e=r.next();return o=e.done,e},e:function(e){l=!0,a=e},f:function(){try{o||null==r.return||r.return()}finally{if(l)throw a}}}},t.exports.__esModule=!0,t.exports.default=t.exports},345490,(e,t,r)=>{"use strict";var i=e.r(13451).default,n=i(e.r(802953)),s=i(e.r(877913)),a=e.r(638743);function o(e){switch(e.kind){case"relay_resolver.error":case"relay_field_payload.error":return e.shouldThrow&&!e.handled;case"missing_expected_data.throw":case"missing_required_field.throw":return!e.handled;case"missing_required_field.log":case"missing_expected_data.log":return!1;default:throw e.kind,Error("Relay: Unexpected event kind")}}t.exports={handlePotentialSnapshotErrors:function(e,t,r){null!=t&&function(e,t,r){var i,l=(0,s.default)(t);try{for(l.s();!(i=l.n()).done;){var u=i.value;e.relayFieldLogger((0,n.default)((0,n.default)({},u),{},{uiContext:r}))}}catch(e){l.e(e)}finally{l.f()}var c,d=(0,s.default)(t);try{for(d.s();!(c=d.n()).done;){var h=c.value;if(o(h))switch(h.kind){case"relay_resolver.error":throw Error("Relay: Resolver error at path '".concat(h.fieldPath,"' in '").concat(h.owner,"'. Message: ").concat(h.error.message));case"relay_field_payload.error":throw Error("Relay: Unexpected response payload - check server logs for details.");case"missing_expected_data.throw":throw Error("Relay: Missing expected data at path '".concat(h.fieldPath,"' in '").concat(h.owner,"'."));case"missing_required_field.throw":throw Error("Relay: Missing @required value at path '".concat(h.fieldPath,"' in '").concat(h.owner,"'."));case"missing_required_field.log":case"missing_expected_data.log":break;default:h.kind,a(!1)}}}catch(e){d.e(e)}finally{d.f()}}(e,t,r)},eventShouldThrow:o}},177785,(e,t,r)=>{var i=e.r(427500);t.exports=function(e){if(Array.isArray(e))return i(e)},t.exports.__esModule=!0,t.exports.default=t.exports},85465,(e,t,r)=>{t.exports=function(e){if("u">typeof Symbol&&null!=e[Symbol.iterator]||null!=e["@@iterator"])return Array.from(e)},t.exports.__esModule=!0,t.exports.default=t.exports},666333,(e,t,r)=>{t.exports=function(){throw TypeError("Invalid attempt to spread non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}
1,t.exports.__esModule=!0,t.exports.default=t.exports},117675,(e,t,r)=>{var i=e.r(177785),n=e.r(85465),s=e.r(737906),a=e.r(666333);t.exports=function(e){return i(e)||n(e)||s(e)||a()},t.exports.__esModule=!0,t.exports.default=t.exports},900336,(e,t,r)=>{"use strict";t.exports={DEFAULT_HANDLE_KEY:""}},880432,(e,t,r)=>{"use strict";var i=e.r(900336).DEFAULT_HANDLE_KEY,n=e.r(638743);t.exports=function(e,t,r){return t&&t!==i?"__".concat(t,"_").concat(e):(null==r&&n(!1),"__".concat(r,"_").concat(e))}},100975,(e,t,r)=>{"use strict";t.exports={ENABLE_VARIABLE_CONNECTION_KEY:!1,ENABLE_RELAY_RESOLVERS:!1,ENABLE_GETFRAGMENTIDENTIFIER_OPTIMIZATION:!1,ENABLE_FRIENDLY_QUERY_NAME_GQL_URL:!1,ENABLE_DO_NOT_WRAP_LIVE_QUERY:!1,ENABLE_NOTIFY_SUBSCRIPTION:!1,BATCH_ASYNC_MODULE_UPDATES_FN:null,ENABLE_CONTAINERS_SUBSCRIBE_ON_COMMIT:!1,MAX_DATA_ID_LENGTH:null,STRING_INTERN_LEVEL:0,LOG_MISSING_RECORDS_IN_PROD:!1,ENABLE_STORE_ID_COLLISION_LOGGING:!1,ENABLE_NONCOMPLIANT_ERROR_HANDLING_ON_LISTS:!1,ENABLE_LOOSE_SUBSCRIPTION_ATTRIBUTION:!1,ENABLE_OPERATION_TRACKER_OPTIMISTIC_UPDATES:!1,ENABLE_RELAY_OPERATION_TRACKER_SUSPENSE:!1,PROCESS_OPTIMISTIC_UPDATE_BEFORE_SUBSCRIPTION:!1,MARK_RESOLVER_VALUES_AS_CLEAN_AFTER_FRAGMENT_REREAD:!1,ENABLE_CYLE_DETECTION_IN_VARIABLES:!1,ENABLE_ACTIVITY_COMPATIBILITY:!1,ENABLE_READ_TIME_RESOLVER_STORAGE_KEY_PREFIX:!0,ENABLE_USE_PAGINATION_IS_LOADING_FIX:!1,DISALLOW_NESTED_UPDATES:!1,ENABLE_TYPENAME_PREFIXED_DATA_ID:!1,ENABLE_UI_CONTEXT_ON_RELAY_LOGGER:!1,CHECK_ALL_FRAGMENTS_FOR_MISSING_CLIENT_EDGES:!1}},652230,(e,t,r)=>{"use strict";t.exports={stableCopy:function e(t){if(!t||"object"!=typeof t)return t;if(Array.isArray(t))return t.map(e);for(var r=Object.keys(t).sort(),i={},n=0;n<r.length;n++)i[r[n]]=e(t[r[n]]);return i},hasCycle:function e(t){var r=arguments.length>1&&void 0!==arguments[1]?arguments[1]:new Set;if(!t||"object"!=typeof t)return!1;if(r.has(t))return!0;var i=new Set(r);return i.add(t),(Array.isArray(t)?t:Object.values(t)).some(function(t){return e(t,i)})}}},765754,(e,t,r)=>{"use strict";var i=(0,e.r(13451).default)(e.r(117675)),n=e.r(880432),s=e.r(710273),a=e.r(100975),o=e.r(652230).stableCopy,l=e.r(638743),u=s.VARIABLE,c=s.LITERAL,d=s.OBJECT_VALUE,h=s.LIST_VALUE;function f(e,t){if(e.kind===u){var r,i;return r=e.variableName,(i=t).hasOwnProperty(r)||l(!1),o(i[r])}if(e.kind===c)return e.value;if(e.kind===d){var n={};return e.fields.forEach(function(e){n[e.name]=f(e,t)}),n}if(e.kind===h){var s=[];return e.items.forEach(function(e){null!=e&&s.push(f(e,t))}),s}}function p(e,t,r){var i={};return r&&(i[y.FRAGMENT_POINTER_IS_WITHIN_UNMATCHED_TYPE_REFINEMENT]=!0),e&&e.forEach(function(e){i[e.name]=f(e,t)}),i}function g(e,t){if(e.storageKey)return e.storageKey;var r=function(e){if("RelayResolver"===e.kind||"RelayLiveResolver"===e.kind){var t,r;return null==e.args?null==(r=e.fragment)?void 0:r.args:(null==(t=e.fragment)?void 0:t.args)==null?e.args:e.args.concat(e.fragment.args)}return void 0===e.args?void 0:e.args}(e),i=e.name;return r&&0!==r.length?m(i,p(r,t)):i}function m(e,t){if(!t)return e;var r=[];for(var i in t)if(t.hasOwnProperty(i)){var n,s=t[i];null!=s&&r.push(i+":"+(null!=(n=JSON.stringify(s))?n:"undefined"))}return 0===r.length?e:e+"(".concat(r.join(","),")")}var y={ACTOR_IDENTIFIER_KEY:"__actorIdentifier",CLIENT_EDGE_TRAVERSAL_PATH:"__clientEdgeTraversalPath",FRAGMENTS_KEY:"__fragments",FRAGMENT_OWNER_KEY:"__fragmentOwner",FRAGMENT_POINTER_IS_WITHIN_UNMATCHED_TYPE_REFINEMENT:"$isWithinUnmatchedTypeRefinement",FRAGMENT_PROP_NAME_KEY:"__fragmentPropName",MODULE_COMPONENT_KEY:"__module_component",ERRORS_KEY:"__errors",ID_KEY:"__id",REF_KEY:"__ref",REFS_KEY:"__refs",ROOT_ID:"client:root",ROOT_TYPE:"__Root",TYPENAME_KEY:"__typename",INVA
1LIDATED_AT_KEY:"__invalidated_at",RELAY_RESOLVER_VALUE_KEY:"__resolverValue",RELAY_RESOLVER_INVALIDATION_KEY:"__resolverValueMayBeInvalid",RELAY_RESOLVER_SNAPSHOT_KEY:"__resolverSnapshot",RELAY_RESOLVER_ERROR_KEY:"__resolverError",RELAY_RESOLVER_OUTPUT_TYPE_RECORD_IDS:"__resolverOutputTypeRecordIDs",RELAY_READ_TIME_RESOLVER_KEY_PREFIX:"$r:",formatStorageKey:m,getArgumentValue:f,getArgumentValues:p,getHandleStorageKey:function(e,t){var r=e.dynamicKey,s=e.handle,a=e.key,o=e.name,l=e.args,u=e.filters,c=n(s,a,o),d=null;return(l&&u&&0!==l.length&&0!==u.length&&(d=l.filter(function(e){return u.indexOf(e.name)>-1})),r&&(d=null!=d?[r].concat((0,i.default)(d)):[r]),null===d)?c:m(c,p(d,t))},getStorageKey:g,getReadTimeResolverStorageKey:function(e,t){var r=g(e,t);return a.ENABLE_READ_TIME_RESOLVER_STORAGE_KEY_PREFIX?"$r:"+r:r},getStableStorageKey:function(e,t){return m(e,o(t))},getModuleComponentKey:function(e){return"".concat("__module_component_").concat(e)},getModuleOperationKey:function(e){return"".concat("__module_operation_").concat(e)}};t.exports=y},698042,(e,t,r)=>{"use strict";var i=(0,e.r(13451).default)(e.r(802953)),n=e.r(765754).getArgumentValues,s=e.r(638743);t.exports={getLocalVariables:function(e,t,r){if(null==t)return e;var s=(0,i.default)({},e),a=r?n(r,e):{};return t.forEach(function(e){var t,r=null!=(t=a[e.name])?t:e.defaultValue;s[e.name]=r}),s},getFragmentVariables:function(e,t,r){var n;return null==e.argumentDefinitions?r:(e.argumentDefinitions.forEach(function(e){if(!r.hasOwnProperty(e.name))switch(n=n||(0,i.default)({},r),e.kind){case"LocalArgument":n[e.name]=e.defaultValue;break;case"RootArgument":if(!t.hasOwnProperty(e.name)){n[e.name]=void 0;break}n[e.name]=t[e.name];break;default:s(!1)}}),n||r)},getOperationVariables:function(e,t,r){var i={};return e.argumentDefinitions.forEach(function(e){var t=e.defaultValue;null!=r[e.name]&&(t=r[e.name]),i[e.name]=t}),null!=t&&Object.keys(t).forEach(function(e){i[e]=t[e].get()}),i}}},832780,(e,t,r)=>{"use strict";var i=[],n=[];t.exports=function(e,t){var r=i.length?i.pop():[],s=n.length?n.pop():[],a=function e(t,r,i,n){if(t===r)return 0!==t||1/t==1/r;if(null==t||null==r||"object"!=typeof t||"object"!=typeof r)return!1;var s=Object.prototype.toString,a=s.call(t);if(a!=s.call(r))return!1;switch(a){case"[object String]":return t==String(r);case"[object Number]":return!(isNaN(t)||isNaN(r))&&t==Number(r);case"[object Date]":case"[object Boolean]":return+t==+r;case"[object RegExp]":return t.source==r.source&&t.global==r.global&&t.multiline==r.multiline&&t.ignoreCase==r.ignoreCase}for(var o=i.length;o--;)if(i[o]==t)return n[o]==r;i.push(t),n.push(r);var l=0;if("[object Array]"===a){if((l=t.length)!==r.length)return!1;for(;l--;)if(!e(t[l],r[l],i,n))return!1}else{if(t.constructor!==r.constructor)return!1;if(t.hasOwnProperty("valueOf")&&r.hasOwnProperty("valueOf"))return t.valueOf()==r.valueOf();var u=Object.keys(t);if(u.length!=Object.keys(r).length)return!1;for(var c=0;c<u.length;c++)if(!e(t[u[c]],r[u[c]],i,n))return!1}return i.pop(),n.pop(),!0}(e,t,r,s);return r.length=0,s.length=0,i.push(r),n.push(s),a}},461055,(e,t,r)=>{"use strict";var i=e.r(698042).getFragmentVariables,n=e.r(765754),s=n.CLIENT_EDGE_TRAVERSAL_PATH,a=n.FRAGMENT_OWNER_KEY,o=n.FRAGMENT_POINTER_IS_WITHIN_UNMATCHED_TYPE_REFINEMENT,l=n.FRAGMENTS_KEY,u=n.ID_KEY,c=e.r(832780),d=e.r(638743);function h(e,t){("object"!=typeof t||null===t||Array.isArray(t))&&d(!1);var r=t[u],n=t[l],c=t[a],h=t[s];if("string"==typeof r&&"object"==typeof n&&null!==n&&"object"==typeof n[e.name]&&null!==n[e.name]&&"object"==typeof c&&null!==c&&(null==h||Array.isArray(h))){var f=n[e.name],p=i(e,c.variables,f);return E(e,r,p,c,!0===f[o],h)}return null}function f(e,t){var r=null;return(t.forEach(function(t,i){var n=null!=t?h(e,t):null;null!=n&&(r=r||[]).push(n)}),null==r)?null:{kind:"PluralReaderSelector",selectors:r}}function p(e,t){return null==t?t:e.metadata&&!0===e.metadata.plural?(Array.isArray(t)||d(!1),f(e,t)):(Array.isArray(t)&&d(!1),h(e,t))}function g(e,t){var r,i;return null==t?t:e.metadata&&!0===e.metadata.plural?(Array.isArray(t)||d(!1),r=e,i=null,t.forEach(function(e){var t=null!=e?m(r,e):null;null!=t&&(i=i||[]).push(t)}),i):(Array.isArray(t)&&d(!1),m(e,t))}function m(e,t){("object"!=typeof t||null===t||Array.isArray(t))&&d(!1);var r=t[u];return"string"==typeof r?r:null}function y(e,t){var r;return null==t?{}:(null==(r=e.metadata)?void 0:r.plural)===!0?(Array.isArray(t)||d(!1),b(e,t)):(Array.isArray(t)&&d(!1),v(e,t)||{})}function v(e,t){var r=h(e,t);return r?r.variables:null}function b(e,t){var r={};return t.forEach(function(t,i){if(null!=t){var n=v(e,t);null!=n&&Object.assign(r,n)}}),r}function _(e,t){var r,i;return e.dataID===t.dataID&&e.node===t.node&&c(e.variables,t.variables)&&(r=e.owner,r===(i=t.owner)||r.identifier===i.identifier&&c(r.cacheConfig,i.cacheConfig))&&e.isWithinUnmatchedTypeRefinement===t.isWithinUnmatchedTypeRefinement&&function(e,t){if(e===t)return!0;
1if(null==e||null==t||e.length!==t.length)return!1;for(var r=e.length;r--;){var i=e[r],n=t[r];if(i!==n&&(null==i||null==n||i.clientEdgeDestinationID!==n.clientEdgeDestinationID||i.readerClientEdge!==n.readerClientEdge))return!1}return!0}(e.clientEdgeTraversalPath,t.clientEdgeTraversalPath)}function E(e,t,r,i){var n=arguments.length>4&&void 0!==arguments[4]&&arguments[4],s=arguments.length>5?arguments[5]:void 0;return{kind:"SingularReaderSelector",dataID:t,isWithinUnmatchedTypeRefinement:n,clientEdgeTraversalPath:null!=s?s:null,node:e,variables:r,owner:i}}e.r(603158),t.exports={areEqualSelectors:function(e,t){if(e===t)return!0;if(null==e)return null==t;if(null==t)return null==e;if("SingularReaderSelector"===e.kind&&"SingularReaderSelector"===t.kind)return _(e,t);if("PluralReaderSelector"===e.kind&&"PluralReaderSelector"===t.kind)return e.selectors.length===t.selectors.length&&e.selectors.every(function(e,r){return _(e,t.selectors[r])});else return!1},createReaderSelector:E,createNormalizationSelector:function(e,t,r){return{dataID:t,node:e,variables:r}},getDataIDsFromFragment:g,getDataIDsFromObject:function(e,t){var r={};for(var i in e)if(e.hasOwnProperty(i)){var n=e[i],s=t[i];r[i]=g(n,s)}return r},getSingularSelector:h,getPluralSelector:f,getSelector:p,getSelectorsFromObject:function(e,t){var r={};for(var i in e)if(e.hasOwnProperty(i)){var n=e[i],s=t[i];r[i]=p(n,s)}return r},getVariablesFromSingularFragment:v,getVariablesFromPluralFragment:b,getVariablesFromFragment:y,getVariablesFromObject:function(e,t){var r={};for(var i in e)e.hasOwnProperty(i)&&Object.assign(r,y(e[i],t[i]));return r}}},50219,(e,t,r)=>{"use strict";var i=e.r(930649).getFragment,n=e.r(345490).eventShouldThrow,s=e.r(461055).getSelector,a=e.r(638743),o=[],l={};t.exports={readFragment:function(e,t){if(!o.length)throw Error("readFragment should be called only from within a Relay Resolver function.");var r=o[o.length-1],u=s(i(e),t);null==u&&a(!1),"SingularReaderSelector"!==u.kind&&a(!1);var c=r.getDataForResolverFragment(u,t),d=c.data,h=c.isMissingData,f=c.fieldErrors;if(h||null!=f&&f.some(n))throw l;return d},withResolverContext:function(e,t){o.push(e);try{return t()}finally{o.pop()}},RESOLVER_FRAGMENT_ERRORED_SENTINEL:l}},281129,(e,t,r)=>{"use strict";var i=e.r(50219).readFragment,n=e.r(638743);t.exports=function(e,t,r,s){return function(a,o,l){var u=i(e,a);if(null==r)return t(null,o,l);if(null==u)if(!0!==s)return t(null,o,l);else n(!1);if(r in u)return!0===s&&null==u[r]&&n(!1),t(u[r],o,l);n(!1)}}},145940,(e,t,r)=>{function i(e,t,r,i,n,s,a){try{var o=e[s](a),l=o.value}catch(e){return void r(e)}o.done?t(l):Promise.resolve(l).then(i,n)}t.exports=function(e){return function(){var t=this,r=arguments;return new Promise(function(n,s){var a=e.apply(t,r);function o(e){i(a,n,s,o,l,"next",e)}function l(e){i(a,n,s,o,l,"throw",e)}o(void 0)})}},t.exports.__esModule=!0,t.exports.default=t.exports},680223,(e,t,r)=>{"use strict";t.exports=function(e){return null!=e&&"object"==typeof e&&"function"==typeof e.then}},152076,(e,t,r)=>{"use strict";var i=e.r(680223),n=function(e,t){},s=function(){function e(e){this._source=e}e.create=function(t){return new e(t)},e.onUnhandledError=function(e){n=e},e.from=function(e){var t,r,n,a;return"object"==typeof(t=e)&&null!==t&&"function"==typeof t.subscribe?(r=e)instanceof s?r:s.create(function(e){return r.subscribe(e)}):i(e)?(n=e,s.create(function(e){n.then(function(t){e.next(t),e.complete()},e.error)})):(a=e,s.create(function(e){e.next(a),e.complete()}))};var t=e.prototype;return t.catch=function(t){var r=this;return e.create(function(e){var i;return r.subscribe({start:function(e){i=e},next:e.next,complete:e.complete,error:function(r){try{t(r).subscribe({start:function(e){i=e},next:e.next,complete:e.complete,error:e.error})}catch(t){e.error(t,!0)}}}),function(){return i.unsubscribe()}})},t.concat=function(t){var r=this;return e.create(function(e){var i;return r.subscribe({start:function(e){i=e},next:e.next,error:e.error,complete:function(){i=t.subscribe(e)}}),function(){i&&i.unsubscribe()}})},t.do=function(t){var r=this;return e.create(function(e){var i=function(r){return function(){try{t[r]&&t[r].apply(t,arguments)}catch(e){n(e,!0)}e[r]&&e[r].apply(e,arguments)}};return r.subscribe({start:i("start"),next:i("next"),error:i("error"),complete:i("complete"),unsubscribe:i("unsubscribe")})})},t.finally=function(t){var r=this;return e.create(function(e){var i=r.subscribe(e);return function(){i.unsubscribe(),t()}})},t.ifEmpty=function(t){var r=this;return e.create(function(e){var i,n=!1;return i=r.subscribe({next:function(t){n=!0,e.next(t)},error:e.error,complete:function(){n?e.complete():i=t.subscribe(e)}}),function(){i&&i.unsubscribe()}})},t.subscribe=function(e){return function(e,t){var r,i=!1,s=function(e){return Object.defineProperty(e,"closed",{get:function(){return i}})};function a(){if(r){if(r.unsubscribe)r.unsubscribe();else try{r()}catch(e){n(e,!0)}r=void 0}}var o=s({unsubscribe:function(){if(!i){i=!0;try{t.unsubscribe&&t.unsubscribe(o)}catch(e){n(e,!0)}finally{a()}}}});try{t.start&&t.start(o)}catch(e){n(e,!0)}if(i)return o;var l=s({next:function(e){if(!i&&t.next)try{t.next(e)}catch(e){n(e,!0)}},error:function(e,r){if(i||!t.error)i=!0,n(e,r||!1),a();else{i=!0;try{t.error(e)}catch(e){n(e,!0)}finally{a()}}},complete:function(){if(!i){i=!0;try{t.complete&&t.complete()}catch(e){n(e,!0)}finally{a()}}}});try{r=e(l)}catch(e){l.error(e,!0)}return i&&a(),o}(this._source,e)},t.map=function(t){var r=this;return e.create(function(e){var i=r.subscribe({complete:e.complete,error:e.error,next:function(r){try{var i=t(r);e.next(i)}catch(t){e.error(t,!0)}}});return function(){i.unsubscribe()}})},t.mergeMap=function(t){var r=this;return e.create(function(i){var n=[];function s(e){this._sub=e,n.push(e)}function a(){n.splice(n.indexOf(this._sub),1),0===n.length&&i.complete()}return r.subscribe({start:s,next:function(r){try{i.closed||e.from(t(r)).subscribe({start:s,next:i.next,error:i.error,complete:a})}catch(e){i.error(e,!0)}},error:i.error,complete:a}
1),function(){n.forEach(function(e){return e.unsubscribe()}),n.length=0}})},t.poll=function(t){var r=this;return e.create(function(e){var i,n;return!function s(){i=r.subscribe({next:e.next,error:e.error,complete:function(){n=setTimeout(s,t)}})}(),function(){clearTimeout(n),i.unsubscribe()}})},t.toPromise=function(){var e=this;return new Promise(function(t,r){var i=!1;e.subscribe({next:function(e){i||(i=!0,t(e))},error:r,complete:t})})},e}();t.exports=s},968259,(e,t,r)=>{"use strict";var i=e.r(13451).default,n=i(e.r(877913)),s=i(e.r(514414)),a=e.r(152076),o=e.r(638743);t.exports=function(){function e(){var e=this;(0,s.default)(this,"_complete",!1),(0,s.default)(this,"_events",[]),(0,s.default)(this,"_sinks",new Set),(0,s.default)(this,"_subscription",[]),this._observable=a.create(function(t){e._sinks.add(t);for(var r=e._events,i=0;i<r.length&&!t.closed;i++){var n=r[i];switch(n.kind){case"complete":t.complete();break;case"error":t.error(n.error);break;case"next":t.next(n.data);break;default:n.kind,o(!1)}}return function(){e._sinks.delete(t)}})}var t=e.prototype;return t.complete=function(){!0!==this._complete&&(this._complete=!0,this._events.push({kind:"complete"}),this._sinks.forEach(function(e){return e.complete()}))},t.error=function(e){!0!==this._complete&&(this._complete=!0,this._events.push({kind:"error",error:e}),this._sinks.forEach(function(t){return t.error(e)}))},t.next=function(e){!0!==this._complete&&(this._events.push({kind:"next",data:e}),this._sinks.forEach(function(t){return t.next(e)}))},t.subscribe=function(e){var t=this._observable.subscribe(e);return this._subscription.push(t),t},t.unsubscribe=function(){var e,t=(0,n.default)(this._subscription);try{for(t.s();!(e=t.n()).done;)e.value.unsubscribe()}catch(e){t.e(e)}finally{t.f()}this._subscription=[]},t.getObserverCount=function(){return this._sinks.size},e}()},558392,(e,t,r)=>{"use strict";var i=e.r(152076),n=e.r(968259),s=e.r(638743),a="function"==typeof WeakMap?new WeakMap:new Map;function o(e,t,r){return i.create(function(a){var o,l,d=u(e),h=d.get(t);return h||r().finally(function(){return d.delete(t)}).subscribe({start:function(e){h={identifier:t,subject:new n,subjectForInFlightStatus:new n,subscription:e,promise:null},d.set(t,h)},next:function(e){var r=c(d,t);r.subject.next(e),r.subjectForInFlightStatus.next(e)},error:function(e){var r=c(d,t);r.subject.error(e),r.subjectForInFlightStatus.error(e)},complete:function(){var e=c(d,t);e.subject.complete(),e.subjectForInFlightStatus.complete()},unsubscribe:function(e){var r=c(d,t);r.subject.unsubscribe(),r.subjectForInFlightStatus.unsubscribe()}}),null==h&&s(!1),(o=d,l=h,i.create(function(e){var t=l.subject.subscribe(e);return function(){t.unsubscribe();var e=o.get(l.identifier);if(e){var r=e.subscription;null!=r&&0===e.subject.getObserverCount()&&(r.unsubscribe(),o.delete(l.identifier))}}})).subscribe(a)})}function l(e,t,r){return i.create(function(t){var i=r.subjectForInFlightStatus.subscribe({error:t.error,next:function(i){e.isRequestActive(r.identifier)?t.next():t.complete()},complete:t.complete,unsubscribe:t.complete});return function(){i.unsubscribe()}})}function u(e){var t=a.get(e);if(null!=t)return t;var r=new Map;return a.set(e,r),r}function c(e,t){var r=e.get(t);return null==r&&s(!1),r}t.exports={fetchQuery:function(e,t){return o(e,t.request.identifier,function(){return e.execute({operation:t})})},fetchQueryDeduped:o,getPromiseForActiveRequest:function(e,t){var r=u(e),i=r.get(t.identifier);return i&&e.isRequestActive(i.identifier)?new Promise(function(t,n){var s=!1;l(e,r,i).subscribe({complete:t,error:n,next:function(e){s&&t(e)}}),s=!0}):null},getObservableForActiveRequest:function(e,t){var r=u(e),i=r.get(t.identifier);return i&&e.isRequestActive(i.identifier)?l(e,r,i):null}}},167815,(e,t,r)=>{"use strict";var i=e.r(13451).default,n=e.r(145940).default,s=i(e.r(877913)),a=e.r(152076),o=e.r(558392).getObservableForActiveRequest,l=e.r(930649).getFragment,u=e.r(345490).handlePotentialSnapshotErrors,c=e.r(461055).getSelector,d=e.r(638743);function h(){return(h=n(function*(e,t,r){try{var i,n,s,a=yield new Promise(function(i,s){n=f(e,t,r).subscribe({next:function(e){"ok"===e.state?i(e.value):"error"===e.state&&s(e.error)}})});return null==(s=n)||s.unsubscribe(),a}catch(e){throw null==(i=n)||i.unsubscribe(),e}}
1)).apply(this,arguments)}function f(e,t,r){var i,n,s,o,u,h,f,m,y,v=l(t),b=c(v,r);switch((null==(y=v.metadata)?void 0:y.hasClientEdges)!=null&&d(!1),null==b&&d(!1),b.kind){case"SingularReaderSelector":return i=e,n=t,s=b,o=i.lookup(s),a.create(function(e){e.next(p(i,n,s.owner,o));var t=i.subscribe(o,function(t){e.next(p(i,n,s.owner,t))});return function(){return t.dispose()}});case"PluralReaderSelector":return u=e,h=t,m=(f=b).selectors.map(function(e){return u.lookup(e)}),a.create(function(e){var t=m.map(function(e,t){return p(u,h,f.selectors[t].owner,e)});e.next(g(t));var r=m.map(function(r,i){return u.subscribe(r,function(r){t[i]=p(u,h,f.selectors[i].owner,r),e.next(g(t))})});return function(){return r.forEach(function(e){return e.dispose()})}})}d(!1)}function p(e,t,r,i){var n=null!=i.missingLiveResolverFields&&i.missingLiveResolverFields.length>0,s=null!=i.missingClientEdges&&i.missingClientEdges.length>0;if(n||s||i.isMissingData&&(null!=o(e,r)||null!=e.getOperationTracker().getPendingOperationsAffectingOwner(r)))return{state:"loading"};try{u(e,i.fieldErrors)}catch(e){return{error:e,state:"error"}}return null==i.data&&d(!1),{state:"ok",value:i.data}}function g(e){var t,r=[],i=(0,s.default)(e);try{for(i.s();!(t=i.n()).done;){var n=t.value;if("ok"!==n.state)return n;r.push(n.value)}}catch(e){i.e(e)}finally{i.f()}return{state:"ok",value:r}}t.exports={observeFragment:f,waitForFragmentData:function(e,t,r){return h.apply(this,arguments)}}},215090,(e,t,r)=>{"use strict";t.exports=function e(t){var r;return null!=(r=t)&&(Array.isArray(r)||"object"==typeof r&&r.constructor===Object)&&(Object.freeze(t),Object.getOwnPropertyNames(t).forEach(function(r){var i=t[r];i&&"object"==typeof i&&!Object.isFrozen(i)&&e(i)})),t}},596916,(e,t,r)=>{"use strict";var i=e.r(652230).stableCopy,n=e.r(638743);t.exports=function(e,t){var r=null!=e.cacheID?e.cacheID:e.id;return null==r&&n(!1),r+JSON.stringify(i(t))}},525999,(e,t,r)=>{"use strict";e.r(215090);var i=e.r(596916),n=e.r(100975),s=e.r(652230).hasCycle,a=e.r(698042).getOperationVariables,o=e.r(461055),l=o.createNormalizationSelector,u=o.createReaderSelector,c=e.r(765754).ROOT_ID,d=e.r(638743);function h(e,t,r){return{identifier:i(e.params,t),node:e,variables:t,cacheConfig:r}}t.exports={createOperationDescriptor:function(e,t,r){var i=arguments.length>3&&void 0!==arguments[3]?arguments[3]:c,o=e.operation,f=a(o,e.params.providedVariables,t);n.ENABLE_CYLE_DETECTION_IN_VARIABLES&&s(f)&&d(!1);var p=h(e,f,r);return{fragment:u(e.fragment,i,f,p),request:p,root:l(o,i,f)}},createRequestDescriptor:h}},327192,(e,t,r)=>{"use strict";var i=(0,e.r(13451).default)(e.r(514414)),n=e.r(167815).observeFragment,s=e.r(525999).createOperationDescriptor;t.exports={observeQuery:function(e,t,r){var a=s(t,r),o={__id:a.fragment.dataID,__fragments:(0,i.default)({},a.fragment.node.name,a.request.variables),__fragmentOwner:a.request};return n(e,a.request.node.fragment,o)}}},154880,(e,t,r)=>{"use strict";var i=e.r(145940).default,n=e.r(167815).observeFragment;function s(){return(s=i(function*(e,t,r){try{var i,s,a,o=yield new Promise(function(i,a){s=n(e,t,r).subscribe({next:function(e){"ok"===e.state?i(e.value):"error"===e.state&&a(e.error)}})});return null==(a=s)||a.unsubscribe(),o}catch(e){throw null==(i=s)||i.unsubscribe(),e}})).apply(this,arguments)}t.exports={waitForFragmentData:function(e,t,r){return s.apply(this,arguments)}}},385323,(e,t,r)=>{"use strict";var i=e.r(281129),n=e.r(167815).observeFragment;t.exports={resolverDataInjector:i,isValueResult:function(e){return!0===e.ok},isErrorResult:function(e){return!1===e.ok},observeQuery:e.r(327192).observeQuery,observeFragment:n,waitForFragmentData:e.r(154880).waitForFragmentData}},875053,(e,t,r)=>{"use strict";var i=new Map,n=1,s=function(){for(var e=new Set,t=0;t<10;++t)e.add(t.toString());return e}();t.exports={intern:function(e,t){if(null==t||e.length<t)return" "===e[0]&&s.has(e[1])||"\v"===e[0]?"\v"+e:e;var r=i.get(e);return null!=r||(r=" "+n++,i.set(e,r)),r}}},883316,(e,t,r)=>{"use strict";var i=e.r(100975),n=e.r(875053).intern,s="client:",a=0;t.exports={generateClientID:function(e,t,r){var a=(i.STRING_INTERN_LEVEL<=0?e:n(e,i.MAX_DATA_ID_LENGTH))+":"+t;return null!=r&&(a+=":"+r),0!==a.indexOf(s)&&(a=s+a),a},generateClientObjectClientID:function(e,t,r){var i="".concat(s).concat(e,":").concat(t);return null!=r&&(i+=":"+r),i},generateUniqueClientID:function(){return"".concat(s,"local:").concat(a++)},isClientID:function(e){return 0===e.indexOf(s)}}},277620,(e,t,r)=>{"use strict";var i={after:!0,before:!0,find:!0,first:!0,last:!0,surrounds:!0},n={CURSOR:"cursor",EDGES:"edges",END_CURSOR:"endCursor",HAS_NEXT_PAGE:"hasNextPage",HAS_PREV_PAGE:"hasPreviousPage",NODE:"node",PAGE_INFO_TYPE:"PageInfo",PAGE_INFO:"pageInfo",START_CURSOR:"startCursor"};t.exports={inject:function(e){n=e},get:function(){return n},isConnectionCall:function(e){return i.hasOwnProperty(e.name)}}},347440,(e,t,r)=>{"use strict";var i=e.r(883316).generateClientID,n=e.r(765754).getStableStorageKey,s=e.r(880432),a=e.r(277620),o=e.r(638743);e.r(603158);var l="connection",u="__connection_next_edge_index";function c(e,t,r){if(null==r)return r;var n=a.get().EDGES,s=t.getValue(u);
1"number"!=typeof s&&o(!1);var l=i(t.getDataID(),n,s),c=e.create(l,r.getType());return c.copyFieldsFrom(r),null==c.getValue("cursor")&&c.setValue(null,"cursor"),t.setValue(s+1,u),c}function d(e,t,r){for(var i=a.get().NODE,n=0;n<e.length;n++){var s=e[n];if(s){var o=s.getLinkedRecord(i),l=o&&o.getDataID();if(l){if(r.has(l))continue;r.add(l)}t.push(s)}}}t.exports={buildConnectionEdge:c,createEdge:function(e,t,r,n){var s=a.get().NODE,o=i(t.getDataID(),r.getDataID()),l=e.get(o);return l||(l=e.create(o,n)),l.setLinkedRecord(r,s),null==l.getValue("cursor")&&l.setValue(null,"cursor"),l},deleteNode:function(e,t){var r,i=a.get(),n=i.EDGES,s=i.NODE,o=e.getLinkedRecords(n);if(o){for(var l=0;l<o.length;l++){var u=o[l],c=u&&u.getLinkedRecord(s);null!=c&&c.getDataID()===t?void 0===r&&(r=o.slice(0,l)):void 0!==r&&r.push(u)}void 0!==r&&e.setLinkedRecords(r,n)}},getConnection:function(e,t,r){var i=s(l,t,null);return e.getLinkedRecord(i,r)},getConnectionID:function(e,t,r){return i(e,n(s(l,t,null),r))},insertEdgeAfter:function(e,t,r){var i,n=a.get(),s=n.CURSOR,o=n.EDGES,l=e.getLinkedRecords(o);if(!l)return void e.setLinkedRecords([t],o);if(null==r)i=l.concat(t);else{i=[];for(var u=!1,c=0;c<l.length;c++){var d=l[c];i.push(d),null!=d&&r===d.getValue(s)&&(i.push(t),u=!0)}u||i.push(t)}e.setLinkedRecords(i,o)},insertEdgeBefore:function(e,t,r){var i,n=a.get(),s=n.CURSOR,o=n.EDGES,l=e.getLinkedRecords(o);if(!l)return void e.setLinkedRecords([t],o);if(null==r)i=[t].concat(l);else{i=[];for(var u=!1,c=0;c<l.length;c++){var d=l[c];null!=d&&r===d.getValue(s)&&(i.push(t),u=!0),i.push(d)}u||i.unshift(t)}e.setLinkedRecords(i,o)},update:function(e,t){var r=e.get(t.dataID);if(r){var n=a.get(),s=n.EDGES,o=n.END_CURSOR,l=n.HAS_NEXT_PAGE,h=n.HAS_PREV_PAGE,f=n.PAGE_INFO,p=n.PAGE_INFO_TYPE,g=n.START_CURSOR,m=r.getLinkedRecord(t.fieldKey),y=m&&m.getLinkedRecord(f);if(!m)return void r.setValue(null,t.handleKey,void 0,r.getErrors(t.fieldKey));var v=i(r.getDataID(),t.handleKey),b=r.getLinkedRecord(t.handleKey),_=null!=b?b:e.get(v),E=_&&_.getLinkedRecord(f);if(_){null==b&&r.setLinkedRecord(_,t.handleKey);var S=m.getLinkedRecords(s);S&&(S=S.map(function(t){return c(e,_,t)}));var x=_.getLinkedRecords(s),T=_.getLinkedRecord(f);_.copyFieldsFrom(m),x&&_.setLinkedRecords(x,s),T&&_.setLinkedRecord(T,f);var w=[],A=t.args;if(x&&S)if(null!=A.after){var R,I=null==(R=E)?void 0:R.getValue(o),k=null==y?void 0:y.getValue(o),C=E&&A.after===I,D=E&&I===k;if(!C&&!D)return;var L=new Set;d(x,w,L),d(S,w,L)}else if(null!=A.before)if(!E||A.before!==E.getValue(g))return;else{var O=new Set;d(S,w,O),d(x,w,O)}else w=S;else w=S||x;if(null!=w&&w!==x&&_.setLinkedRecords(w,s),E&&y){if(null==A.after&&null==A.before)E.copyFieldsFrom(y);else if(null!=A.before||null==A.after&&A.last){E.setValue(!!y.getValue(h),h);var P=y.getValue(g);"string"==typeof P&&E.setValue(P,g)}else if(null!=A.after||null==A.before&&A.first){E.setValue(!!y.getValue(l),l);var F=y.getValue(o);"string"==typeof F&&E.setValue(F,o)}}}else{var N=e.create(v,m.getType());N.setValue(0,u),N.copyFieldsFrom(m);var M=m.getLinkedRecords(s);M&&(M=M.map(function(t){return c(e,N,t)}),N.setLinkedRecords(M,s)),r.setLinkedRecord(N,t.handleKey),(E=e.create(i(N.getDataID(),f),p)).setValue(!1,l),E.setValue(!1,h),E.setValue(null,o),E.setValue(null,g),y&&E.copyFieldsFrom(y),N.setLinkedRecord(E,f)}}}}},306867,(e,t,r)=>{"use strict";var i=(0,e.r(13451).default)(e.r(877913)),n=e.r(347440),s=e.r(277620),a=e.r(638743);function o(e){return function(t,r){var o=t.get(r.dataID);if(null!=o){var l=r.handleArgs.connections;null==l&&a(!1);try{c=o.getLinkedRecord(r.fieldKey)}catch(e){}if(!c)try{d=o.getLinkedRecords(r.fieldKey)}catch(e){}if(null!=c||null!=d){var u,c,d,h,f=s.get(),p=f.NODE,g=f.EDGES,m=null!=(u=d)?u:[c],y=(0,i.default)(m);try{for(y.s();!(h=y.n()).done;){var v,b=function(){var r=h.value;if(null==r)return"continue";var s=r.getLinkedRecord("node");if(!s)return"continue";var o,u=s.getDataID(),c=(0,i.default)(l);try{for(c.s();!(o=c.n()).done;){var d=o.value,f=t.get(d);if(null!=f&&!(null==(v=f.getLinkedRecords(g))?void 0:v.some(function(e){var t;return(null==e||null==(t=e.getLinkedRecord(p))?void 0:t.getDataID())===u}))){var m=n.buildConnectionEdge(t,f,r);null==m&&a(!1),e(f,m)}}}catch(e){c.e(e)}finally{c.f()}}();if("continue"===b)continue}}catch(e){y.e(e)}finally{y.f()}}}}}function l(e){return function(t,r){var o=t.get(r.dataID);if(null!=o){var l=r.handleArgs,u=l.connections,c=l.edgeTypeName;null==u&&a(!1),null==c&&a(!1);try{h=o.getLinkedRecord(r.fieldKey)}catch(e){}
1if(!h)try{f=o.getLinkedRecords(r.fieldKey)}catch(e){}if(null!=h||null!=f){var d,h,f,p,g=s.get(),m=g.NODE,y=g.EDGES,v=null!=(d=f)?d:[h],b=(0,i.default)(v);try{for(b.s();!(p=b.n()).done;){var _,E=function(){var r=p.value;if(null==r)return"continue";var s,o=r.getDataID(),l=(0,i.default)(u);try{for(l.s();!(s=l.n()).done;){var d=s.value,h=t.get(d);if(null!=h&&!(null==(_=h.getLinkedRecords(y))?void 0:_.some(function(e){var t;return(null==e||null==(t=e.getLinkedRecord(m))?void 0:t.getDataID())===o}))){var f=n.createEdge(t,h,r,c);null==f&&a(!1),e(h,f)}}}catch(e){l.e(e)}finally{l.f()}}();if("continue"===E)continue}}catch(e){b.e(e)}finally{b.f()}}}}}e.r(603158),t.exports={AppendEdgeHandler:{update:o(n.insertEdgeAfter)},DeleteRecordHandler:{update:function(e,t){var r=e.get(t.dataID);if(null!=r){var i=r.getValue(t.fieldKey);"string"==typeof i?e.delete(i):Array.isArray(i)&&i.forEach(function(t){"string"==typeof t&&e.delete(t)})}}},PrependEdgeHandler:{update:o(n.insertEdgeBefore)},AppendNodeHandler:{update:l(n.insertEdgeAfter)},PrependNodeHandler:{update:l(n.insertEdgeBefore)},DeleteEdgeHandler:{update:function(e,t){var r=e.get(t.dataID);if(null!=r){var s=t.handleArgs.connections;null==s&&a(!1);var o=r.getValue(t.fieldKey);(Array.isArray(o)?o:[o]).forEach(function(t){if("string"==typeof t){var r,a=(0,i.default)(s);try{for(a.s();!(r=a.n()).done;){var o=r.value,l=e.get(o);null!=l&&n.deleteNode(l,t)}}catch(e){a.e(e)}finally{a.f()}}})}}}}},844195,(e,t,r)=>{"use strict";var i=e.r(347440),n=e.r(306867),s=e.r(638743);t.exports=function(e){switch(e){case"connection":return i;case"deleteRecord":return n.DeleteRecordHandler;case"deleteEdge":return n.DeleteEdgeHandler;case"appendEdge":return n.AppendEdgeHandler;case"prependEdge":return n.PrependEdgeHandler;case"appendNode":return n.AppendNodeHandler;case"prependNode":return n.PrependNodeHandler}s(!1)}},661691,(e,t,r)=>{"use strict";t.exports=function(e){return!!(e&&e["@@RelayModernEnvironment"])}},265876,(e,t,r)=>{"use strict";var i=(0,e.r(13451).default)(e.r(877913)),n=e.r(347440);function s(e){return e.fragment.selections&&e.fragment.selections.length>0&&"LinkedField"===e.fragment.selections[0].kind?e.fragment.selections[0].name:null}e.r(603158),t.exports={MutationTypes:Object.freeze({RANGE_ADD:"RANGE_ADD",RANGE_DELETE:"RANGE_DELETE",NODE_DELETE:"NODE_DELETE"}),RangeOperations:Object.freeze({APPEND:"append",PREPEND:"prepend"}),convert:function(e,t,r,a){var o=r?[r]:[],l=a?[a]:[];return e.forEach(function(e){switch(e.type){case"NODE_DELETE":var r,a,u,c,d=(r=e,a=t,u=r.deletedIDFieldName,(c=s(a))?function(e,t){var r=e.getRootField(c);if(r){var i=r.getValue(u);(Array.isArray(i)?i:[i]).forEach(function(t){t&&"string"==typeof t&&e.delete(t)})}}:null);d&&(o.push(d),l.push(d));break;case"RANGE_ADD":var h=function(e,t){var r=e.parentID,a=e.connectionInfo,o=e.edgeName;if(!r)return null;var l=s(t);return a&&l?function(e,t){var s=e.get(r);if(s){var u=e.getRootField(l);if(u){var c,d=u.getLinkedRecord(o),h=(0,i.default)(a);try{for(h.s();!(c=h.n()).done;){var f=c.value;if(d){var p=n.getConnection(s,f.key,f.filters);if(p){var g=n.buildConnectionEdge(e,p,d);if(g)switch(f.rangeBehavior){case"append":n.insertEdgeAfter(p,g);break;case"prepend":n.insertEdgeBefore(p,g)}}}}}catch(e){h.e(e)}finally{h.f()}}}}:null}(e,t);h&&(o.push(h),l.push(h));break;case"RANGE_DELETE":var f=function(e,t){var r=e.parentID,a=e.connectionKeys,o=e.pathToConnection,l=e.deletedIDFieldName;if(!r)return null;var u=s(t);return u?function(e,t){if(t){var s=[],c=t[u];if(c&&Array.isArray(l)){var d,h=(0,i.default)(l);try{for(h.s();!(d=h.n()).done;){var f=d.value;c&&"object"==typeof c&&(c=c[f])}}catch(e){h.e(e)}finally{h.f()}Array.isArray(c)?c.forEach(function(e){e&&e.id&&"object"==typeof e&&"string"==typeof e.id&&s.push(e.id)}):c&&c.id&&"string"==typeof c.id&&s.push(c.id)}else c&&"string"==typeof l&&"object"==typeof c&&("string"==typeof(c=c[l])?s.push(c):Array.isArray(c)&&c.forEach(function(e){"string"==typeof e&&s.push(e)}));!function(e,t,r,s,a){var o=s.get(e);if(o&&!(r.length<2)){for(var l=o,u=1;u<r.length-1;u++)l&&(l=l.getLinkedRecord(r[u]));if(t&&l){var c,d=(0,i.default)(t);try{for(d.s();!(c=d.n()).done;)!function(){var e=c.value,t=n.getConnection(l,e.key,e.filters);t&&a.forEach(function(e){n.deleteNode(t,e)})}()}catch(e){d.e(e)}finally{d.f()}}}}(r,a,o,e,s)}}:null}(e,t);f&&(o.push(f),l.push(f))}}),{optimisticUpdater:function(e,t){o.forEach(function(r){r(e,t)})},updater:function(e,t){l.forEach(function(r){r(e,t)})}}}}},295870,(e,t,r)=>{"use strict";var i=e.r(930649).getRequest,n=e.r(661691),s=e.r(525999).createOperationDescriptor,a=e.r(265876),o=e.r(638743);t.exports=function(e,t){n(e)||o(!1);var r=i(t.mutation);if("mutation"!==r.params.operationKind)throw Error("commitMutation: Expected mutation operation");var l=t.optimisticUpdater,u=t.configs,c=t.optimisticResponse,d=s(r,t.variables);return u&&(l=a.convert(u,r,l).optimisticUpdater),e.applyMutation({operation:d,response:c,updater:l})}},213576,(e,t,r)=>{"use strict";
1t.exports=function(e,t){e.commitUpdate(t)}},704983,(e,t,r)=>{"use strict";(0,e.r(13451).default)(e.r(802953)),e.r(603158),Object.prototype.hasOwnProperty,t.exports=function(){}},726516,(e,t,r)=>{"use strict";var i=(0,e.r(13451).default)(e.r(117675)),n=e.r(930649).getRequest,s=e.r(883316).generateUniqueClientID,a=e.r(661691),o=e.r(525999).createOperationDescriptor,l=e.r(265876);e.r(704983);var u=e.r(638743);e.r(603158),t.exports=function(e,t){a(e)||u(!1);var r=n(t.mutation);if("mutation"!==r.params.operationKind)throw Error("commitMutation: Expected mutation operation");if("Request"!==r.kind)throw Error("commitMutation: Expected mutation to be of type request");var c=t.optimisticResponse,d=t.optimisticUpdater,h=t.updater,f=t.configs,p=t.cacheConfig,g=t.onError,m=t.onUnsubscribe,y=t.variables,v=t.uploadables,b=o(r,y,p,s());if("function"==typeof c&&(c=c()),f){var _=l.convert(f,r,d,h);d=_.optimisticUpdater,h=_.updater}var E=[];return{dispose:e.executeMutation({operation:b,optimisticResponse:c,optimisticUpdater:d,updater:h,uploadables:v}).subscribe({next:function(e){var r;Array.isArray(e)?e.forEach(function(e){e.errors&&E.push.apply(E,(0,i.default)(e.errors))}):e.errors&&E.push.apply(E,(0,i.default)(e.errors)),null==(r=t.onNext)||r.call(t)},complete:function(){var r=t.onCompleted;r&&r(e.lookup(b.fragment).data,0!==E.length?E:null)},error:g,unsubscribe:m}).unsubscribe}}},760262,(e,t,r)=>{"use strict";e.r(832780),e.r(603158);var i="function"==typeof WeakMap?new WeakMap:new Map;function n(e,t){if(null==t)return e;var r={};return Object.assign(r,e),Object.keys(t).forEach(function(e){var n=t[e].get,s=n();if(i.has(n)){var a=i.get(n);r[e]=a}else i.set(n,s),r[e]=s}),r}n.tests_only_resetDebugCache=void 0,t.exports=n},969262,(e,t,r)=>{"use strict";var i=e.r(152076);t.exports={convertFetch:function(e){return function(t,r,n,s,a){var o=e(t,r,n,s,a);return o instanceof Error?i.create(function(e){return e.error(o)}):i.from(o)}}}},879580,(e,t,r)=>{"use strict";var i=e.r(760262),n=e.r(969262).convertFetch,s=e.r(638743);t.exports={create:function(e,t){var r=n(e);return{execute:function(e,n,a,o,l){var u=i(n,e.providedVariables);if("subscription"===e.operationKind)return t||s(!1),o&&s(!1),t(e,u,a);var c=a.poll;return null!=c?(o&&s(!1),r(e,u,{force:!0}).poll(c)):r(e,u,a,o,l)}}}}},356030,(e,t,r)=>{"use strict";var i=(0,e.r(13451).default)(e.r(802953)),n=e.r(652230).stableCopy,s=e.r(638743);function a(e,t){return JSON.stringify(n({queryID:e,variables:t}))}t.exports=function(){function e(e){var t=e.size,r=e.ttl;t>0||s(!1),r>0||s(!1),this._responses=new Map,this._size=t,this._ttl=r}var t=e.prototype;return t.clear=function(){this._responses.clear()},t.get=function(e,t){var r=this,n=a(e,t);this._responses.forEach(function(e,t){var i;i=e.fetchTime,i+r._ttl>=Date.now()||r._responses.delete(t)});var s=this._responses.get(n);return null==s?null:Array.isArray(s.payload)?s.payload.map(function(e){return(0,i.default)((0,i.default)({},e),{},{extensions:(0,i.default)((0,i.default)({},e.extensions),{},{cacheTimestamp:s.fetchTime})})}):(0,i.default)((0,i.default)({},s.payload),{},{extensions:(0,i.default)((0,i.default)({},s.payload.extensions),{},{cacheTimestamp:s.fetchTime})})},t.set=function(e,t,r){var i=Date.now(),n=a(e,t);if(this._responses.delete(n),this._responses.set(n,{fetchTime:i,payload:r}),this._responses.size>this._size){var s=this._responses.keys().next();s.done||this._responses.delete(s.value)}},e}()},172850,(e,t,r)=>{"use strict";var i=(0,e.r(13451).default)(e.r(802953)),n=e.r(152076),s=e.r(525999).createOperationDescriptor,a=e.r(345490).handlePotentialSnapshotErrors,o=e.r(558392),l=e.r(930649).getRequest,u=e.r(638743);function c(e,t){return o.fetchQuery(e,t).map(function(){return e.lookup(t.fragment)})}t.exports=function(e,t,r,o){var d,h=l(t);"query"!==h.params.operationKind&&u(!1);var f=s(h,r,(0,i.default)({force:!0},null==o?void 0:o.networkCacheConfig)),p=null!=(d=null==o?void 0:o.fetchPolicy)?d:"network-only";function g(t){return a(e,t.fieldErrors),t.data}switch(p){case"network-only":return c(e,f).map(g);case"store-or-network":if("available"===e.check(f).status)return n.from(e.lookup(f.fragment)).map(g);return c(e,f).map(g);default:throw Error("fetchQuery: Invalid fetchPolicy "+p)}}},950298,(e,t,r)=>{"use strict";var i=e.r(525999).createOperationDescriptor,n=e.r(930649).getRequest;t.exports=function(e,t,r,s){var a=n(t);
1if("query"!==a.params.operationKind)throw Error("fetchQuery: Expected query operation");var o=i(a,r,s);return e.execute({operation:o}).map(function(){return e.lookup(o.fragment).data}).toPromise()}},279767,(e,t,r)=>{"use strict";t.exports=new(function(){function e(){this._preloadableQueries=new Map,this._callbacks=new Map}var t=e.prototype;return t.set=function(e,t){this._preloadableQueries.set(e,t);var r=this._callbacks.get(e);null!=r&&r.forEach(function(e){try{e(t)}catch(e){setTimeout(function(){throw e},0)}})},t.get=function(e){return this._preloadableQueries.get(e)},t.onLoad=function(e,t){var r,i=null!=(r=this._callbacks.get(e))?r:new Set;return i.add(t),this._callbacks.set(e,i),{dispose:function(){i.delete(t)}}},t.clear=function(){this._preloadableQueries.clear()},e}())},295556,(e,t,r)=>{"use strict";var i=e.r(558392).getPromiseForActiveRequest;t.exports=function(e,t,r){var n=[],s=i(e,r);if(null!=s)n=[r];else{var a,o,l,u,c=e.getOperationTracker().getPendingOperationsAffectingOwner(r);n=null!=(l=null==c?void 0:c.pendingOperations)?l:[],s=null!=(u=null==c?void 0:c.promise)?u:null}if(!s)return null;var d=null!=(a=null==(o=n)?void 0:o.map(function(e){return e.node.params.name}).join(","))?a:null;(null==d||0===d.length)&&(d="Unknown pending operation");var h=t.name,f=d===h?"Relay(".concat(d,")"):"Relay(".concat(d,":").concat(h,")");return s.displayName=f,e.__log({name:"pendingoperation.found",fragment:t,fragmentOwner:r,pendingOperations:n}),{promise:s,pendingOperations:n}}},986480,(e,t,r)=>{"use strict";t.exports=function(e,t){return e===t&&(null===e||"object"!=typeof e)}},667256,(e,t,r)=>{"use strict";t.exports=function(e,t){return function e(t,r,i){if(t===r||"object"!=typeof t||!t||t.constructor!==Object&&!Array.isArray(t)||"object"!=typeof r||!r||r.constructor!==Object&&!Array.isArray(r))return r;var n=!1,s=Array.isArray(t)?t:null,a=Array.isArray(r)?r:null;if(s&&a){var o=i&&!Object.isFrozen(a);n=a.reduce(function(t,r,i){var n=e(s[i],r,o);return n!==a[i]&&o&&(a[i]=n),t&&n===s[i]},!0)&&s.length===a.length}else if(!s&&!a){var l=Object.keys(t),u=Object.keys(r),c=i&&!Object.isFrozen(r);n=u.reduce(function(i,n){var s=e(t[n],r[n],c);return s!==r[n]&&c&&(r[n]=s),i&&s===t[n]},!0)&&l.length===u.length}return n?t:r}(e,t,!0)}},761387,(e,t,r)=>{"use strict";var i=e.r(13451).default,n=i(e.r(802953)),s=i(e.r(514414)),a=e.r(295556),o=e.r(345490).handlePotentialSnapshotErrors,l=e.r(986480),u=e.r(667256),c=e.r(100975),d=e.r(525999).createRequestDescriptor,h=e.r(461055),f=h.areEqualSelectors,p=h.createReaderSelector,g=h.getSelectorsFromObject,m=e.r(832780),y=e.r(638743);e.r(603158);var v=function(){function e(e,t,r,i,n){var a=this;(0,s.default)(this,"_onChange",function(){a._stale=!0,"function"==typeof a._callback&&a._callback()}),this._callback=i,this._context=e,this._data={},this._fragments=t,this._props={},this._resolvers={},this._stale=!1,this._rootIsQueryRenderer=n,this.setProps(r)}var t=e.prototype;return t.dispose=function(){for(var e in this._resolvers)this._resolvers.hasOwnProperty(e)&&E(this._resolvers[e])},t.resolve=function(){if(this._stale){var e,t=this._data;for(var r in this._resolvers)if(this._resolvers.hasOwnProperty(r)){var i=this._resolvers[r],s=t[r];
1if(i){var a=i.resolve();(e||a!==s)&&((e=e||(0,n.default)({},t))[r]=a)}else{var o=this._props[r],u=void 0!==o?o:null;(e||!l(u,s))&&((e=e||(0,n.default)({},t))[r]=u)}}this._data=e||t,this._stale=!1}return this._data},t.setCallback=function(e,t){this._callback=t,!0===c.ENABLE_CONTAINERS_SUBSCRIBE_ON_COMMIT&&this.setProps(e)},t.setProps=function(e){this._props={};var t=g(this._fragments,e);for(var r in t)if(t.hasOwnProperty(r)){var i=t[r],n=this._resolvers[r];null==i?(null!=n&&n.dispose(),n=null):"PluralReaderSelector"===i.kind?null==n?n=new _(this._context.environment,this._rootIsQueryRenderer,i,null!=this._callback,this._onChange):(n instanceof _||y(!1),n.setSelector(i)):null==n?n=new b(this._context.environment,this._rootIsQueryRenderer,i,null!=this._callback,this._onChange):(n instanceof b||y(!1),n.setSelector(i)),this._props[r]=e[r],this._resolvers[r]=n}this._stale=!0},t.setVariables=function(e,t){for(var r in this._resolvers)if(this._resolvers.hasOwnProperty(r)){var i=this._resolvers[r];i&&i.setVariables(e,t)}this._stale=!0},e}(),b=function(){function e(e,t,r,i,n){var a=this;(0,s.default)(this,"_onChange",function(e){a._data=e.data,a._isMissingData=e.isMissingData,a._fieldErrors=e.fieldErrors,a._callback()});var o=e.lookup(r);this._callback=n,this._data=o.data,this._isMissingData=o.isMissingData,this._fieldErrors=o.fieldErrors,this._environment=e,this._rootIsQueryRenderer=t,this._selector=r,!0===c.ENABLE_CONTAINERS_SUBSCRIBE_ON_COMMIT?i&&(this._subscription=e.subscribe(o,this._onChange)):this._subscription=e.subscribe(o,this._onChange)}var t=e.prototype;return t.dispose=function(){this._subscription&&(this._subscription.dispose(),this._subscription=null)},t.resolve=function(){if(!0===this._isMissingData){var e=a(this._environment,this._selector.node,this._selector.owner),t=null==e?void 0:e.promise;if(null!=t)if(this._rootIsQueryRenderer);else{var r,i=null!=(r=null==e?void 0:e.pendingOperations)?r:[];throw this._environment.__log({name:"suspense.fragment",data:this._data,fragment:this._selector.node,isRelayHooks:!1,isMissingData:this._isMissingData,isPromiseCached:!1,pendingOperations:i}),t}}return o(this._environment,this._fieldErrors),this._data},t.setSelector=function(e){if(!(null!=this._subscription&&f(e,this._selector))){this.dispose();var t=this._environment.lookup(e);this._data=u(this._data,t.data),this._isMissingData=t.isMissingData,this._fieldErrors=t.fieldErrors,this._selector=e,this._subscription=this._environment.subscribe(t,this._onChange)}},t.setVariables=function(e,t){if(!m(e,this._selector.variables)){var r=d(t,e),i=p(this._selector.node,this._selector.dataID,e,r);this.setSelector(i)}},e}(),_=function(){function e(e,t,r,i,n){var a=this;(0,s.default)(this,"_onChange",function(e){a._stale=!0,a._callback()}),this._callback=n,this._data=[],this._environment=e,this._resolvers=[],this._stale=!0,this._rootIsQueryRenderer=t,this._subscribeOnConstruction=i,this.setSelector(r)}var t=e.prototype;return t.dispose=function(){this._resolvers.forEach(E)},t.resolve=function(){if(this._stale){for(var e,t=this._data,r=0;r<this._resolvers.length;r++){var i=t[r],n=this._resolvers[r].resolve();(e||n!==i)&&(e=e||t.slice(0,r)).push(n)}e||this._resolvers.length===t.length||(e=t.slice(0,this._resolvers.length)),this._data=e||t,this._stale=!1}return this._data},t.setSelector=function(e){for(var t=e.selectors;this._resolvers.length>t.length;)this._resolvers.pop().dispose();for(var r=0;r<t.length;r++)r<this._resolvers.length?this._resolvers[r].setSelector(t[r]):this._resolvers[r]=new b(this._environment,this._rootIsQueryRenderer,t[r],this._subscribeOnConstruction,this._onChange);this._stale=!0},t.setVariables=function(e,t){this._resolvers.forEach(function(r){return r.setVariables(e,t)}),this._stale=!0},e}();function E(e){e&&e.dispose()}t.exports=v},267199,(e,t,r)=>{"use strict";var i=e.r(761387);e.r(603158),t.exports=function(e,t,r,n,s,a){return new i(e,r,n,a,s)}},702108,(e,t,r)=>{"use strict";var i,n,s=e.r(638743);t.exports=function(e){return i||(i=e.createContext(null),n=e),e!==n&&s(!1),i}},181758,(e,t,r)=>{"use strict";var i,n,s=e.r(638743);
1t.exports=function(e){return i||(i=e.createContext(null),n=e),e!==n&&s(!1),i}},824461,(e,t,r)=>{"use strict";var i=Object.freeze({__LIVE_RESOLVER_SUSPENSE_SENTINEL:!0});t.exports={isSuspenseSentinel:function(e){return e===i},suspenseSentinel:function(){return i}}},800419,(e,t,r)=>{t.exports=function(e,t){if(null==e)return{};var r={};for(var i in e)if(({}).hasOwnProperty.call(e,i)){if(-1!==t.indexOf(i))continue;r[i]=e[i]}return r},t.exports.__esModule=!0,t.exports.default=t.exports},789197,(e,t,r)=>{"use strict";var i=e.r(13451).default,n=i(e.r(514414)),s=i(e.r(800419)),a=i(e.r(863974)),o=i(e.r(802953)),l=e.r(215090),u=e.r(883316),c=u.generateClientObjectClientID;u.isClientID;var d=e.r(824461).isSuspenseSentinel,h=e.r(765754),f=h.ACTOR_IDENTIFIER_KEY,p=h.ERRORS_KEY,g=h.ID_KEY,m=h.INVALIDATED_AT_KEY,y=h.REF_KEY,v=h.REFS_KEY,b=h.RELAY_RESOLVER_VALUE_KEY,_=(h.ROOT_ID,h.TYPENAME_KEY),E=e.r(832780),S=e.r(638743);function x(e,t){var r=e[t];return r&&"object"==typeof r&&(r.hasOwnProperty(y)||r.hasOwnProperty(v))&&S(!1),r}function T(e,t,r){var i=e[p];if(null!=r&&r.length>0)null==i?e[p]=(0,n.default)({},t,r):i[t]=r;else if(null!=i&&delete i[t]){for(var s in i)if(i.hasOwnProperty(s))return;delete e[p]}}e.r(603158);t.exports={clone:function(e){return(0,o.default)({},e)},copyFields:function(e,t){for(var r in e)e.hasOwnProperty(r)&&r!==g&&r!==_&&(t[r]=e[r])},create:function(e,t){var r={};return r[g]=e,r[_]=t,r},freeze:function(e){l(e)},fromObject:function(e){return e},getDataID:function(e){return e[g]},getErrors:function(e,t){var r;return null==(r=e[p])?void 0:r[t]},getFields:function(e){return p in e?Object.keys(e).filter(function(e){return e!==p}):Object.keys(e)},getInvalidationEpoch:function(e){if(null==e)return null;var t=e[m];return"number"!=typeof t?null:t},getLinkedRecordID:function(e,t){var r=e[t];return null==r?r:("object"==typeof r&&r&&"string"==typeof r[y]||S(!1),r[y])},getLinkedRecordIDs:function(e,t){var r=e[t];return null==r?r:("object"==typeof r&&Array.isArray(r[v])||S(!1),r[v])},getType:function(e){return e[_]},getValue:x,hasValue:function(e,t){return t in e},hasLinkedRecordID:function(e,t){var r=e[t];return null!=r&&"object"==typeof r&&r&&"string"==typeof r[y]},hasLinkedRecordIDs:function(e,t){var r=e[t];return null!=r&&"object"==typeof r&&Array.isArray(r[v])&&r[v].every(function(e){return"string"==typeof e})},merge:function(e,t){if(!(p in e)&&!(p in t))return(0,o.default)((0,o.default)({},e),t);var r=e[p],i=(0,s.default)(e,[p].map(a.default)),n=t[p],l=(0,s.default)(t,[p].map(a.default)),u=(0,o.default)((0,o.default)({},i),l);if(null==r&&null==n)return u;var c={};for(var d in r)l.hasOwnProperty(d)||(c[d]=r[d]);for(var h in n)c[h]=n[h];for(var f in c){u[p]=c;break}return u},setErrors:T,setValue:function(e,t,r){e[t]=r},setLinkedRecordID:function(e,t,r){var i={};i[y]=r,e[t]=i},setLinkedRecordIDs:function(e,t,r){var i={};i[v]=r,e[t]=i},update:function(e,t){var r,i,n=e[p],s=t[p],a=null;if(null==n&&null==s){for(var l in t)(a||!E(e[l],t[l]))&&((a=null!==a?a:(0,o.default)({},e))[l]=t[l]);return null!=(i=a)?i:e}for(var u in t)if(u!==p){var c,d,h,f=t[u],g=null==s?void 0:s[u];if(null==a){var m=e[u],y=null==n?void 0:n[u];if(E(m,f)&&E(y,g))continue;a=(0,o.default)({},e),null!=n&&(a[p]=(0,o.default)({},n))}c=a,d=u,h=f,c[d]=h,T(a,u,g)}return null!=(r=a)?r:e},getActorLinkedRecordID:function(e,t){var r=e[t];return null==r?r:(("object"!=typeof r||"string"!=typeof r[y]||null==r[f])&&S(!1),[r[f],r[y]])},setActorLinkedRecordID:function(e,t,r,i){var n={};n[y]=i,n[f]=r,e[t]=n},getResolverLinkedRecordID:function(e,t){var r=x(e,b);return null==r||d(r)?null:("object"==typeof r&&(r=r.id),"string"!=typeof r&&S(!1),c(t,r))},getResolverLinkedRecordIDs:function(e,t){var r=x(e,b);return null==r||d(r)?null:(Array.isArray(r)||S(!1),r.map(function(e){return null==e?null:("object"==typeof e&&(e=e.id),"string"!=typeof e&&S(!1),c(t,e))}))},toJSON:function(e){return e}}},886050,(e,t,r)=>{"use strict";t.exports={EXISTENT:"EXISTENT",NONEXISTENT:"NONEXISTENT",UNKNOWN:"UNKNOWN"}},244209,(e,t,r)=>{"use strict";var i=(0,e.r(13451).default)(e.r(877913)),n=e.r(789197),s=e.r(886050),a=s.EXISTENT,o=s.NONEXISTENT,l=s.UNKNOWN;t.exports=function(){function e(e){var t=this;this._records=new Map,null!=e&&Object.keys(e).forEach(function(r){var i=e[r],s=n.fromObject(i);t._records.set(r,s)})}e.create=function(t){return new e(t)};var t=e.prototype;return t.clear=function(){this._records=new Map},t.delete=function(e){this._records.set(e,null)},t.get=function(e){return this._records.get(e)},t.getRecordIDs=function(){return Array.from(this._records.keys())},t.getStatus=function(e){return this._records.has(e)?null==this._records.get(e)?o:a:l},t.has=function(e){return this._records.has(e)},t.remove=function(e){this._records.delete(e)},t.set=function(e,t){this._records.set(e,t)},t.size=function(){return this._records.size},t.toJSON=function(){var e,t={},r=(0,i.default)(this._records);try{for(r.s();!(e=r.n()).done;){var s=e.value,a=s[0],o=s[1];t[a]=n.toJSON(o)}}catch(e){r.e(e)}finally{r.f()}return t},e}()},385555,(e,t,r)=>{"use strict";var i=e.r(638743),n="INTERNAL_ACTOR_IDENTIFIER_DO_NOT_USE";t.exports={assertInternalActorIdentifier:function(e){e!==n&&i(!1)},getActorIdentifier:function(e){return e},getDefaultActorIdentifier:function(){throw Error("Not Implemented")},INTERNAL_ACTOR_IDENTIFIER_DO_NOT_USE:n}},487508,(e,t,r)=>{"use strict";var i="actor_key",n=e.r(385555).getActorIdentifier;
1t.exports={ACTOR_IDENTIFIER_FIELD_NAME:i,getActorIdentifierFromPayload:function(e){if(null!=e&&"object"==typeof e&&"string"==typeof e[i])return n(e[i])}}},251265,(e,t,r)=>{"use strict";var i=e.r(13451).default,n=i(e.r(802953)),s=i(e.r(800419)),a=i(e.r(877913)),o=i(e.r(117675)),l=["path","locations"],u=Symbol("$SELF");t.exports={SELF:u,buildErrorTrie:function(e){if(null==e)return null;var t,r=new Map,i=(0,a.default)(e);try{for(i.s();!(t=i.n()).done;){var n=t.value,o=n.path,c=(n.locations,(0,s.default)(n,l));if(null!=o){var d=o.length;if(0!==d){for(var h=d-1,f=r,p=0;p<h;p++){var g=o[p],m=f.get(g);if(m instanceof Map){f=m;continue}var y=new Map;Array.isArray(m)&&y.set(u,m),f.set(g,y),f=y}var v=o[h],b=f.get(v);b instanceof Map&&(b=(f=b).get(v),v=u),Array.isArray(b)?b.push(c):f.set(v,[c])}}}}catch(e){i.e(e)}finally{i.f()}return r},getNestedErrorTrieByKey:function(e,t){var r=e.get(t);return r instanceof Map?r:null},getErrorsByKey:function(e,t){var r=e.get(t);if(null==r)return null;if(Array.isArray(r))return r;var i=[];return function e(t,r){var i,s=(0,a.default)(t);try{for(s.s();!(i=s.n()).done;){var l=i.value,c=l[0],d=l[1],h=r.length;if(Array.isArray(d)?r.push.apply(r,(0,o.default)(d)):e(d,r),c!==u)for(var f=r.length,p=h;p<f;p++){var g=r[p];null==g.path?r[p]=(0,n.default)((0,n.default)({},g),{},{path:[c]}):g.path.unshift(c)}}}catch(e){s.e(e)}finally{s.f()}}(r,i),i}}},638867,(e,t,r)=>{"use strict";var i="client:__type:";t.exports={generateTypeID:function(e){return i+e},isTypeID:function(e){return 0===e.indexOf(i)},TYPE_SCHEMA_TYPE:"__TypeSchema"}},678359,(e,t,r)=>{"use strict";var i=e.r(13451).default,n=i(e.r(877913)),s=i(e.r(117675)),a=e.r(487508),o=(a.ACTOR_IDENTIFIER_FIELD_NAME,a.getActorIdentifierFromPayload),l=e.r(100975),u=e.r(883316),c=u.generateClientID,d=u.isClientID,h=e.r(698042).getLocalVariables,f=e.r(251265),p=f.buildErrorTrie,g=f.getErrorsByKey,m=f.getNestedErrorTrieByKey,y=e.r(789197),v=e.r(461055).createNormalizationSelector,b=e.r(765754),_=b.ROOT_ID,E=b.TYPENAME_KEY,S=b.getArgumentValues,x=b.getHandleStorageKey,T=b.getModuleComponentKey,w=b.getModuleOperationKey,A=b.getStorageKey,R=e.r(638867),I=R.TYPE_SCHEMA_TYPE,k=R.generateTypeID;e.r(832780);var C=e.r(638743);e.r(603158);var D=function(){function e(e,t,r,i){this._actorIdentifier=r.actorIdentifier,this._getDataId=r.getDataID,this._handleFieldPayloads=[],this._treatMissingFieldsAsNull=r.treatMissingFieldsAsNull,this._incrementalPlaceholders=[],this._isCl
1ientExtension=!1,this._isUnmatchedAbstractType=!1,this._useExecTimeResolvers=i,this._followupPayloads=[],this._path=r.path?(0,s.default)(r.path):[],this._recordSource=e,this._variables=t,this._shouldProcessClientComponents=r.shouldProcessClientComponents,this._log=r.log}var t=e.prototype;return t.normalizeResponse=function(e,t,r,i){var n=this._recordSource.get(t);return n||C(!1),this._assignClientAbstractTypes(e),this._errorTrie=p(i),this._traverseSelections(e,n,r),{errors:i,fieldPayloads:this._handleFieldPayloads,incrementalPlaceholders:this._incrementalPlaceholders,followupPayloads:this._followupPayloads,source:this._recordSource,isFinal:!1}},t._assignClientAbstractTypes=function(e){var t=e.clientAbstractTypes;if(null!=t)for(var r=0,i=Object.keys(t);r<i.length;r++){var s,a=i[r],o=(0,n.default)(t[a]);try{for(o.s();!(s=o.n()).done;){var l=s.value,u=k(l),c=this._recordSource.get(u);null==c&&(c=y.create(u,I),this._recordSource.set(u,c)),y.setValue(c,a,!0)}}catch(e){o.e(e)}finally{o.f()}}},t._getVariableValue=function(e){return this._variables.hasOwnProperty(e)||C(!1),this._variables[e]},t._getRecordType=function(e){var t=e[E];return null==t&&C(!1),t},t._traverseSelections=function(e,t,r){for(var i=0;i<e.selections.length;i++){var n=e.selections[i];switch(n.kind){case"ScalarField":case"LinkedField":this._normalizeField(n,t,r);break;case"Condition":!!this._getVariableValue(n.condition)===n.passingValue&&this._traverseSelections(n,t,r);break;case"FragmentSpread":var s=this._variables;this._variables=h(this._variables,n.fragment.argumentDefinitions,n.args),this._traverseSelections(n.fragment,t,r),this._variables=s;break;case"InlineFragment":var a=n.abstractKey;if(null==a)y.getType(t)===n.type&&this._traverseSelections(n,t,r);else{var o=Object.prototype.hasOwnProperty.call(r,a),l=k(y.getType(t)),u=this._recordSource.get(l);null==u&&(u=y.create(l,I),this._recordSource.set(l,u)),y.setValue(u,a,o),o&&this._traverseSelections(n,t,r)}break;case"TypeDiscriminator":var c=n.abstractKey,d=Object.prototype.hasOwnProperty.call(r,c),f=k(y.getType(t)),p=this._recordSource.get(f);null==p&&(p=y.create(f,I),this._recordSource.set(f,p)),y.setValue(p,c,d);break;case"LinkedHandle":case"ScalarHandle":var g=n.args?S(n.args,this._variables):{},m=A(n,this._variables),v=x(n,this._variables);this._handleFieldPayloads.push({args:g,dataID:y.getDataID(t),fieldKey:m,handle:n.handle,handleKey:v,handleArgs:n.handleArgs?S(n.handleArgs,this._variables):{}});break;case"ModuleImport":this._normalizeModuleImport(n,t,r);break;case"Defer":this._normalizeDefer(n,t,r);break;case"Stream":this._normalizeStream(n,t,r);break;case"ClientExtension":var b=this._isClientExtension;this._isClientExtension=!0,this._traverseSelections(n,t,r),this._isCl
1ientExtension=b;break;case"ClientComponent":if(!1===this._shouldProcessClientComponents)break;this._traverseSelections(n.fragment,t,r);break;case"ActorChange":this._normalizeActorChange(n,t,r);break;case"RelayResolver":case"RelayLiveResolver":this._useExecTimeResolvers||this._normalizeResolver(n,t,r);break;case"ClientEdgeToClientObject":this._useExecTimeResolvers||this._normalizeResolver(n.backingField,t,r);break;default:C(!1)}}},t._normalizeResolver=function(e,t,r){null!=e.fragment&&this._traverseSelections(e.fragment,t,r)},t._normalizeDefer=function(e,t,r){!1===(null===e.if||this._getVariableValue(e.if))?this._traverseSelections(e,t,r):this._incrementalPlaceholders.push({kind:"defer",data:r,label:e.label,path:(0,s.default)(this._path),selector:v(e,y.getDataID(t),this._variables),typeName:y.getType(t),actorIdentifier:this._actorIdentifier})},t._normalizeStream=function(e,t,r){this._traverseSelections(e,t,r),!0===(null===e.if||this._getVariableValue(e.if))&&this._incrementalPlaceholders.push({kind:"stream",label:e.label,path:(0,s.default)(this._path),parentID:y.getDataID(t),node:e,variables:this._variables,actorIdentifier:this._actorIdentifier})},t._normalizeModuleImport=function(e,t,r){"object"==typeof r&&r||C(!1);var i=y.getType(t),n=T(e.documentName),a=e.componentModuleProvider||r[n];y.setValue(t,n,null!=a?a:null);var o=w(e.documentName),l=e.operationModuleProvider||r[o];y.setValue(t,o,null!=l?l:null),null!=l&&this._followupPayloads.push({kind:"ModuleImportPayload",args:e.args,data:r,dataID:y.getDataID(t),operationReference:l,path:(0,s.default)(this._path),typeName:i,variables:this._variables,actorIdentifier:this._actorIdentifier})},t._normalizeField=function(e,t,r){"object"==typeof r&&r||C(!1);var i=e.alias||e.name,n=A(e,this._variables),s=r[i],a=l.ENABLE_NONCOMPLIANT_ERROR_HANDLING_ON_LISTS&&Array.isArray(s)&&0===s.length;if(null==s||a){if(void 0===s&&(this._isClientExtension||this._isUnmatchedAbstractType||!this._treatMissingFieldsAsNull))return;"ScalarField"===e.kind&&this._validateConflictingFieldsWithIdenticalId(t,n,null),a?"LinkedField"===e.kind?y.setLinkedRecordIDs(t,n,[]):y.setValue(t,n,[]):y.setValue(t,n,null);var o=this._errorTrie;if(null!=o){var u=g(o,i);null!=u&&y.setErrors(t,n,u)}return}if("ScalarField"===e.kind)this._validateConflictingFieldsWithIdenticalId(t,n,s),y.setValue(t,n,s);else if("LinkedField"===e.kind){this._path.push(i);var c=this._errorTrie;this._errorTrie=null==c?null:m(c,i),e.plural?this._normalizePluralLink(e,t,n,s):this._normalizeLink(e,t,n,s),this._errorTrie=c,this._path.pop()}else C(!1)},t._normalizeActorChange=function(e,t,r){var i,n=e.linkedField;"object"==typeof r&&r||C(!1);var a=n.alias||n.name,l=A(n,this._variables),u=r[a];if(null==u){if(void 0===u&&(this._isClientExtension||this._isUnmatchedAbstractType||!this._treatMissingFieldsAsNull))return;y.setValue(t,l,null);return}var d=o(u);if(null==d)return void y.setValue(t,l,null);var h=null!=(i=n.concreteType)?i:this._getRecordType(u),f=this._getDataId(u,h)||y.getLinkedRecordID(t,l)||c(y.getDataID(t),l);"string"!=typeof f&&C(!1),y.setActorLinkedRecordID(t,l,d,f),this._followupPayloads.push({kind:"ActorPayload",data:u,dataID:f,path:[].concat((0,s.default)(this._path),[a]),typeName:h,variables:this._variables,node:n,actorIdentifier:d})},t._normalizeLink=function(e,t,r,i){"object"==typeof i&&i||C(!1);var n,s=this._getDataId(i,null!=(n=e.concreteType)?n:this._getRecordType(i))||y.getLinkedRecordID(t,r)||c(y.getDataID(t),r);"string"!=typeof s&&C(!1),this._validateConflictingLinkedFieldsWithIdenticalId(y.getLinkedRecordID(t,r),s,r),y.setLinkedRecordID(t,r,s);var a=this._recordSource.get(s);if(a)this._validateRecordType(a,e,i);else{var o=e.concreteType||this._getRecordType(i);a=y.create(s,o),this._recordSource.set(s,a)}this._traverseSelections(e,a,i)},t._normalizePluralLink=function(e,t,r,i){var n=this;Array.isArray(i)||C(!1);var s=y.getLinkedRecordIDs(t,r),a=[];i.forEach(function(i,o){if(null==i)return void a.push(i);n._path.push(String(o));var l,u=n._errorTrie;n._errorTrie=null==u?null:m(u,o),"object"!=typeof i&&C(!1);var d=n._getDataId(i,null!=(l=e.concreteType)?l:n._getRecordType(i))||s&&s[o]||c(y.getDataID(t),r,o);"string"!=typeof d&&C(!1),a.push(d);var h=n._recordSource.get(d);if(h)n._validateRecordType(h,e,i);else{var f=e.concreteType||n._getRecordType(i);h=y.create(d,f),n._recordSource.set(d,h)}s&&n._validateConflictingLinkedFieldsWithIdenticalId(s[o],d,r),n._traverseSelections(e,h,i),n._errorTrie=u,n._path.pop()}),y.setLinkedRecordIDs(t,r,a)},t._validateRecordType=function(e,t,r){if(l.ENABLE_STORE_ID_COLLISION_LOGGING){var i,n=null!=(i=t.concreteType)?i:this._getRecordType(r),s=y.getDataID(e);if(!(d(s)&&s!==_||y.getType(e)===n)){var a={name:"idCollision.typename",previous_typename:y.getType(e),new_typename:n};null!=this._log&&this._log(a)}}},t._validateConflictingFieldsWithIdenticalId=function(e,t,r){},t._validateConflictingLinkedFieldsWithIdenticalId=function(e,t,r){},e}();t.exports={normalize:function(e,t,r,i,n,s){var a=t.dataID,o=t.node;return new D(e,t.variables,i,null!=s&&s).normalizeResponse(o,a,r,n)}}},193576,(e,t,r)=>{"use strict";var i=e.r(13451).default,n=i(e.r(802953)),s=i(e.r(789197)),a=i(e.r(244209)),o=i(e.r(678359));t.exports=function(e,t,r,i,l){var u,c=e.data,d=e.errors,h=a.default.create(),f=s.default.create(t.dataID,r);h.set(t.dataID,f);var p=o.default.normalize(h,t,c,i,d,l);return(0,n.default)((0,n.default)({},p),{},{isFinal:(null==(u=e.extensions)?void 0:u.is_final)===!0})}},963805,(e,t,r)=>{"use strict";var i=e.r(930649).getInlineDataFragment,n=e.r(765754).FRAGMENTS_KEY,s=e.r(638743);t.exports=function(e,t){var r,a=i(e);if(null==t)return t;"object"!=typeof t&&s(!1);var o=null==(r=t[n])?void 0:r[a.name];return null==o&&s(!1),o}},738574,(e,t,r)=>{"use strict";var i=1e5;t.exports=function(){return i++}},273273,(e,t,r)=>{"use strict";var i=e.r(738574);t.exports=function(e,t){return{execute:function(r,n,s,a,o,l,u,c){var d=i();return t.execute(r,n,s,a,function(t){e.__log({name:"network.info",networkRequestId:d,info:t})},l,u,c).do({start:function(t){e.__log({name:"network.start",networkRequestId:d,params:r,variables:n,cacheConfig:s})},next:function(t){e.__log({name:"network.next",networkRequestId:d,response:t})},error:function(t){e.__log({name:"network.error",networkRequestId:d,error:t})},complete:function(){e.__log({name:"network.complete",networkRequestId:d})},unsubscribe:function(){e.__log({name:"network.unsubscribe",networkRequestId:d})}})}}}},297501,(e,t,r)=>{"use strict";var i=(0,e.r(13451).default)(e.r(877913)),n=e.r(638743);t.exports=function(){function e(){this._ownersToPendingOperations=new Map,this._pendingOperationsToOwners=new Map,this._ownersToPendingPromise=new Map}var t=e.prototype;return t.update=function(e,t){if(0!==t.size){var r,n=e.identifier,s=new Set,a=(0,i.default)(t);try{for(a.s();!(r=a.n()).done;){var o=r.value.identifier,l=this._ownersToPendingOperations.get(o);null!=l?l.has(n)||(l.set(n,e),s.add(o)):(this._ownersToPendingOperations.set(o,new Map([[n,e]])),s.add(o))}}catch(e){a.e(e)}finally{a.f()}
1if(0!==s.size){var u,c=this._pendingOperationsToOwners.get(n)||new Set,d=(0,i.default)(s);try{for(d.s();!(u=d.n()).done;){var h=u.value;this._resolveOwnerResolvers(h),c.add(h)}}catch(e){d.e(e)}finally{d.f()}this._pendingOperationsToOwners.set(n,c)}}},t.complete=function(e){var t=e.identifier,r=this._pendingOperationsToOwners.get(t);if(null!=r){var n,s=new Set,a=new Set,o=(0,i.default)(r);try{for(o.s();!(n=o.n()).done;){var l=n.value,u=this._ownersToPendingOperations.get(l);u&&(u.delete(t),u.size>0?a.add(l):s.add(l))}}catch(e){o.e(e)}finally{o.f()}var c,d=(0,i.default)(s);try{for(d.s();!(c=d.n()).done;){var h=c.value;this._resolveOwnerResolvers(h),this._ownersToPendingOperations.delete(h)}}catch(e){d.e(e)}finally{d.f()}var f,p=(0,i.default)(a);try{for(p.s();!(f=p.n()).done;){var g=f.value;this._resolveOwnerResolvers(g)}}catch(e){p.e(e)}finally{p.f()}this._pendingOperationsToOwners.delete(t)}},t._resolveOwnerResolvers=function(e){var t=this._ownersToPendingPromise.get(e);null!=t&&t.resolve(),this._ownersToPendingPromise.delete(e)},t.getPendingOperationsAffectingOwner=function(e){var t,r=e.identifier,i=this._ownersToPendingOperations.get(r);if(null==i||0===i.size)return null;var s=this._ownersToPendingPromise.get(r);if(null!=s)return{promise:s.promise,pendingOperations:s.pendingOperations};var a=new Promise(function(e){t=e});null==t&&n(!1);var o=Array.from(i.values());return this._ownersToPendingPromise.set(r,{promise:a,resolve:t,pendingOperations:o}),{promise:a,pendingOperations:o}},e}()},181968,(e,t,r)=>{"use strict";t.exports=function(t){var r=e.g,i=r&&r.__RELAY_DEVTOOLS_HOOK__;i&&i.registerEnvironment(t)}},416199,(e,t,r)=>{"use strict";t.exports={VIEWER_ID:(0,e.r(883316).generateClientID)(e.r(765754).ROOT_ID,"viewer"),VIEWER_TYPE:"Viewer"}},320766,(e,t,r)=>{"use strict";var i=e.r(416199),n=i.VIEWER_ID,s=i.VIEWER_TYPE;t.exports=function(e,t){return t===s&&null==e.id?n:e.id}},736260,(e,t,r)=>{"use strict";t.exports=function(e){}},89478,(e,t,r)=>{"use strict";var i=e.r(710273),n=i.REQUEST;i.SPLIT_OPERATION,t.exports=function(e){return e.kind===n?e.operation:e}},265025,(e,t,r)=>{"use strict";function i(e,t,r){for(var i=arguments.length,n=Array(i>3?i-3:0),s=3;s<i;s++)n[s-3]=arguments[s];var a=0,o=Object.assign(Error(r.replace(/%s/g,function(){return String(n[a++])})),{name:t,messageFormat:r,messageParams:n,type:e,taalOpcodes:[2,2]});if(void 0===o.stack)try{throw o}catch(e){}return o}t.exports={create:function(e,t){for(var r=arguments.length,n=Array(r>2?r-2:0),s=2;s<r;s++)n[s-2]=arguments[s];return i.apply(void 0,["error",e,t].concat(n))},createWarning:function(e,t){for(var r=arguments.length,n=Array(r>2?r-2:0),s=2;s<r;s++)n[s-2]=arguments[s];return i.apply(void 0,["warn",e,t].concat(n))}}},483923,(e,t,r)=>{"use strict";var i,n,s="u">typeof window&&"function"==typeof(null==(i=window)||null==(n=i.performance)?void 0:n.now);function a(){return s?window.performance.now():Date.now()}t.exports=function(e){var t=a(),r=e();return[t,a()-t,r]}},939908,(e,t,r)=>{"use strict";var i=e.r(13451).default,n=i(e.r(877913)),s=i(e.r(117675)),a=e.r(152076),o=e.r(738574),l=e.r(89478),u=e.r(265025),c=e.r(100975),d=e.r(652230).stableCopy,h=e.r(483923),f=e.r(883316),p=f.generateClientID,g=f.generateUniqueClientID,m=e.r(698042).getLocalVariables,y=e.r(789197),v=e.r(461055),b=v.createNormalizationSelector,_=v.createReaderSelector,E=e.r(244209),S=e.r(765754),x=S.ROOT_TYPE,T=S.TYPENAME_KEY,w=S.getStorageKey,A=e.r(638743);e.r(603158);var R=function(){function e(e){var t,r,i,n=this,s=e.actorIdentifier,a=e.getDataID,l=e.getPublishQueue,u=e.getStore,d=e.isClientPayload,h=e.operation,f=e.operationExecutions,p=e.operationLoader,g=e.operationTracker,m=e.optimisticConfig,y=e.scheduler,v=e.shouldProcessClientComponents,b=e.sink,_=e.source,E=e.treatMissingFieldsAsNull,S=e.updater,x=e.log,T=e.normalizeResponse;this._actorIdentifier=s,this._getDataID=a,this._treatMissingFieldsAsNull=E,this._incrementalPayloadsPending=!1,this._incrementalResults=new Map,this._log=x,this._executeId=o(),this._nextSubscriptionId=0,this._operation=h,this._operationExecutions=f,this._operationLoader=p,this._operationTracker=g,this._operationUpdateEpochs=new Map,this._optimisticUpdates=null,this._useExecTimeResolvers=null!=(t=null!=(r=this._operation.request.node.operation.use_exec_time_resolvers)?r:(null==(i=this._operation.request.node.operation.exec_time_resolvers_enabled_provider)?void 0:i.get())===!0)&&t,this._execTimeResolverResponseComplete=!1,this._pendingModulePayloadsCount=0,this._getPublishQueue=l,this._scheduler
1=y,this._sink=b,this._source=new Map,this._state="started",this._getStore=u,this._subscriptions=new Map,this._updater=S,this._isClientPayload=!0===d,this._isSubscriptionOperation="subscription"===this._operation.request.node.params.operationKind,this._shouldProcessClientComponents=v,this._retainDisposables=new Map,this._seenActors=new Set,this._completeFns=[],this._normalizeResponse=T;var w=this._nextSubscriptionId++;c.PROCESS_OPTIMISTIC_UPDATE_BEFORE_SUBSCRIPTION&&null!=m&&this._processOptimisticResponse(null!=m.response?{data:m.response}:null,m.updater,!1),_.subscribe({complete:function(){return n._complete(w)},error:function(e){return n._error(e)},next:function(e){try{n._next(w,e)}catch(e){b.error(e)}},start:function(e){var t;n._start(w,e),n._log({name:"execute.start",executeId:n._executeId,params:n._operation.request.node.params,variables:n._operation.request.variables,cacheConfig:null!=(t=n._operation.request.cacheConfig)?t:{}})},unsubscribe:function(){n._log({name:"execute.unsubscribe",executeId:n._executeId})}}),c.PROCESS_OPTIMISTIC_UPDATE_BEFORE_SUBSCRIPTION||null==m||this._processOptimisticResponse(null!=m.response?{data:m.response}:null,m.updater,!1)}var t=e.prototype;return t.cancel=function(){var e=this;if("completed"!==this._state){this._state="completed",this._operationExecutions.delete(this._operation.request.identifier),0!==this._subscriptions.size&&(this._subscriptions.forEach(function(e){return e.unsubscribe()}),this._subscriptions.clear());var t=this._optimisticUpdates;null!==t&&(this._optimisticUpdates=null,t.forEach(function(t){return e._getPublishQueueAndSaveActor().revertUpdate(t)}),this._runPublishQueue()),this._incrementalResults.clear(),null!=this._asyncStoreUpdateDisposable&&(this._asyncStoreUpdateDisposable.dispose(),this._asyncStoreUpdateDisposable=null),this._completeFns=[],this._completeOperationTracker(),this._disposeRetainedData()}},t._updateActiveState=function(){var e;switch(this._state){case"started":case"loading_incremental":e="active";break;case"completed":e="inactive";break;case"loading_final":e=this._pendingModulePayloadsCount>0||this._useExecTimeResolvers&&!this._execTimeResolverResponseComplete?"active":"inactive";break;default:this._state,A(!1)}this._operationExecutions.set(this._operation.request.identifier,e)},t._schedule=function(e,t){var r=this,i=this._scheduler;if(null!=i){var n=this._nextSubscriptionId++;a.create(function(r){var n=i.schedule(function(){try{e(),r.complete()}catch(e){r.error(e)}},t);return function(){return i.cancel(n)}}).subscribe({complete:function(){return r._complete(n)},error:function(e){return r._error(e)},start:function(e){return r._start(n,e)}})}else e()},t._complete=function(e){this._subscriptions.delete(e),0===this._subscriptions.size&&(this.cancel(),this._sink.complete(),this._log({name:"execute.complete",executeId:this._executeId}))},t._error=function(e){this.cancel(),this._sink.error(e),this._log({name:"execute.error",executeId:this._executeId,error:e})},t._start=function(e,t){this._subscriptions.set(e,t),this._updateActiveState()},t._next=function(e,t){var r=this,i="loading_incremental"===this._state?"low":"default";this._schedule(function(){r._log({name:"execute.next.start",executeId:r._executeId,response:t,operation:r._operation}),r._handleNext(t),r._maybeCompleteSubscriptionOperationTracking(),r._log({name:"execute.next.end",executeId:r._executeId,response:t,operation:r._operation})},i)},t._handleErrorResponse=function(e){var t=this,r=[];return e.forEach(function(e){if(null!==e.data||null==e.extensions||e.hasOwnProperty("errors")){if(null==e.data){var i=e.hasOwnProperty("errors")&&null!=e.errors?e.errors:null,n=i?i.map(function(e){return e.message}).join("\n"):"(No errors)",s=u.create("RelayNetwork","No data returned for operation `"+t._operation.request.node.params.name+"`, got error(s):\n"+n+"\n\nSee the error `source` property for more information.");throw s.source={errors:i,operation:t._operation.request.node,variables:t._operation.request.variables},s.stack,s}r.push(e)}}),r},t._handleOptimisticResponses=function(e){if(e.length>1)return e.some(function(e){var t;return(null==(t=e.extensions)?void 0:t.isOptimistic)===!0})&&A(!1),!1;var t,r=e[0],i=(null==(t=r.extensions)?void 0:t.isOptimistic)===!0;return i&&"started"!==this._state&&A(!1),!!i&&(this._processOptimisticResponse(r,null,this._treatMissingFieldsAsNull),this._sink.next(r),!0)},t._handleNext=function(e){if("completed"!==this._state){this._seenActors.clear();var t=Array.isArray(e)?e:[e],r=this._handleErrorResponse(t);if(0===r.length){var i=t.some(function(e){var t;return(null==(t=e.extensions)?void 0:t.is_final)===!0});i&&(this._state="loading_final",this._updateActiveState(),this._incrementalPayloadsPending=!1),this._sink.next(e);return}if(!this._handleOptimisticResponses(r)){var n=(p=[],m=[],y=[],r.forEach(function(e){var t;if(null!=e.path||null!=e.label){var r=e.label,i=e.path;(null==r||null==i)&&A(!1),m.push({label:r,path:i,response:e})}else(null==(t=e.extensions)?void 0:t.is_normalized)===!0?y.push(e):p.push(e)}),[p,m,y]),s=n[0],a=n[1],o=n[2],l=s.length>0,u=o.length>0;if(l){if(this._isSubscriptionOperation){var c=g();this._operation={request:this._operation.request,fragment:_(this._operation.fragment.node,c,this._operation.fragment.variables,this._operation.fragment.owner),root:b(this._operation.root.
1node,c,this._operation.root.variables)}}var d=this._processResponses(s);this._processPayloadFollowups(d)}if(u)for(var h=[],f=0;f<o.length;f++){var p,m,y,v,S=o[f],x=new E(S.data),i=(null==(v=S.extensions)?void 0:v.is_final)===!0,T={errors:[],fieldPayloads:[],followupPayloads:[],incrementalPlaceholders:[],isFinal:i,source:x};this._getPublishQueueAndSaveActor().commitPayload(this._operation,T,this._updater),h.push(T),this._execTimeResolverResponseComplete=i,i&&this._updateActiveState()}if(a.length>0){var w=this._processIncrementalResponses(a);this._processPayloadFollowups(w)}this._isSubscriptionOperation&&(null==r[0].extensions?r[0].extensions={__relay_subscription_root_id:this._operation.fragment.dataID}:r[0].extensions.__relay_subscription_root_id=this._operation.fragment.dataID);var R=this._runPublishQueue(l||u?this._operation:void 0);l&&this._incrementalPayloadsPending&&this._retainData(),this._updateOperationTracker(R),this._sink.next(e)}}},t._processOptimisticResponse=function(e,t,r){var i=this;if(null!==this._optimisticUpdates&&A(!1),null!=e||null!=t){var n=[];if(e){var s=this._normalizeResponse(e,this._operation.root,x,{actorIdentifier:this._actorIdentifier,getDataID:this._getDataID,log:this._log,path:[],shouldProcessClientComponents:this._shouldProcessClientComponents,treatMissingFieldsAsNull:r},this._useExecTimeResolvers);I(s),n.push({operation:this._operation,payload:s,updater:t}),this._processOptimisticFollowups(s,n)}else t&&n.push({operation:this._operation,payload:{errors:null,fieldPayloads:null,incrementalPlaceholders:null,followupPayloads:null,source:E.create(),isFinal:!1},updater:t});this._optimisticUpdates=n,n.forEach(function(e){return i._getPublishQueueAndSaveActor().applyUpdate(e)});var a=this._runPublishQueue();c.ENABLE_OPERATION_TRACKER_OPTIMISTIC_UPDATES&&this._updateOperationTracker(a)}},t._processOptimisticFollowups=function(e,t){if(e.followupPayloads&&e.followupPayloads.length){var r,i=e.followupPayloads,a=(0,n.default)(i);try{for(a.s();!(r=a.n()).done;){var o=r.value;switch(o.kind){case"ModuleImportPayload":var l=this._expectOperationLoader().get(o.operationReference);if(null==l)this._processAsyncOptimisticModuleImport(o);else{var u=this._processOptimisticModuleImport(l,o);t.push.apply(t,(0,s.default)(u))}break;case"ActorPayload":break;default:A(!1)}}}catch(e){a.e(e)}finally{a.f()}}},t._normalizeFollowupPayload=function(e,t){var r="SplitOperation"===t.kind&&"ModuleImportPayload"===e.kind?m(e.variables,t.argumentDefinitions,e.args):e.variables,i=b(t,e.dataID,r),n={data:e.data,extensions:"loading_final"===this._state?{is_final:!0}:void 0};return this._normalizeResponse(n,i,e.typeName,{actorIdentifier:this._actorIdentifier,getDataID:this._getDataID,log:this._log,path:e.path,treatMissingFieldsAsNull:this._treatMissingFieldsAsNull,shouldProcessClientComponents:this._shouldProcessClientComponents},this._useExecTimeResolvers)},t._processOptimisticModuleImport=function(e,t){var r=l(e),i=[],n=this._normalizeFollowupPayload(t,r);return I(n),i.push({operation:this._operation,payload:n,updater:null}),this._processOptimisticFollowups(n,i),i},t._processAsyncOptimisticModuleImport=function(e){var t=this;this._expectOperationLoader().load(e.operationReference).then(function(r){if(null!=r&&"started"===t._state){var i,n=t._processOptimisticModuleImport(r,e);n.forEach(function(e){return t._getPublishQueueAndSaveActor().applyUpdate(e)}),null==t._optimisticUpdates||((i=t._optimisticUpdates).push.apply(i,(0,s.default)(n)),t._runPublishQueue())}})},t._processResponses=function(e){var t=this;return this._log({name:"execute.normalize.start",operation:this._operation}),null!==this._optimisticUpdates&&(this._optimisticUpdates.forEach(function(e){t._getPublishQueueAndSaveActor().revertUpdate(e)}),this._optimisticUpdates=null),this._incrementalPayloadsPending=!1,this._incrementalResults.clear(),this._source.clear(),e.map(function(e){var r=t._normalizeResponse(e,t._operation.root,x,{actorIdentifier:t._actorIdentifier,getDataID:t._getDataID,log:t._log,path:[],treatMissingFieldsAsNull:t._treatMissingFieldsAsNull,shouldProcessClientComponents:t._shouldProcessClientComponents},t._useExecTimeResolvers);return t._getPublishQueueAndSaveActor().commitPayload(t._operation,r,t._updater),t._log({name:"execute.normalize.end",operation:t._operation}),r})},t._processPayloadFollowups=function(e){var t=this;"completed"!==this._state&&e.forEach(function(e){var r=e.incrementalPlaceholders,i=e.followupPayloads,n=e.isFinal;if(t._state=n?"loading_final":"loading_incremental",t._updateActiveState(),n&&(t._incrementalPayloadsPending=!1),i&&0!==i.length&&i.forEac
1h(function(e){var r,i=t._actorIdentifier;t._actorIdentifier=null!=(r=e.actorIdentifier)?r:t._actorIdentifier,t._processFollowupPayload(e),t._actorIdentifier=i}),r&&0!==r.length&&(t._incrementalPayloadsPending="loading_final"!==t._state,r.forEach(function(r){var i,n=t._actorIdentifier;t._actorIdentifier=null!=(i=r.actorIdentifier)?i:t._actorIdentifier,t._processIncrementalPlaceholder(e,r),t._actorIdentifier=n}),t._isClientPayload||"loading_final"===t._state)){var s=[];r.forEach(function(e){"defer"===e.kind&&s.push(t._processDeferResponse(e.label,e.path,e,{data:e.data,extensions:{is_final:!0}}))}),s.length>0&&t._processPayloadFollowups(s)}})},t._maybeCompleteSubscriptionOperationTracking=function(){(this._isSubscriptionOperation||this._useExecTimeResolvers&&this._execTimeResolverResponseComplete&&"loading_final"===this._state)&&0===this._pendingModulePayloadsCount&&!1===this._incrementalPayloadsPending&&this._completeOperationTracker()},t._processFollowupPayload=function(e){var t=this;switch(e.kind){case"ModuleImportPayload":var r=this._expectOperationLoader(),i=r.get(e.operationReference);if(null!=i)this._processFollowupPayloadWithNormalizationNode(e,l(i));else{var n=this._nextSubscriptionId++;this._pendingModulePayloadsCount++;var s=function(){t._pendingModulePayloadsCount--,t._maybeCompleteSubscriptionOperationTracking()},o=a.from(new Promise(function(t,i){r.load(e.operationReference).then(t,i)}));a.create(function(r){var i,n=o.subscribe({next:function(n){if(null!=n){var s=function(){try{var i=l(n),s=c.BATCH_ASYNC_MODULE_UPDATES_FN,a=null!=s&&t._pendingModulePayloadsCount>1,o=h(function(){if(t._handleFollowupPayload(e,i),a)t._scheduleAsyncStoreUpdate(s,r.complete);else{var n=t._runPublishQueue();t._updateOperationTracker(n)}}),u=(o[0],o[1]);t._log({name:"execute.async.module",executeId:t._executeId,operationName:i.name,duration:u}),a||r.complete()}catch(e){r.error(e)}},a=t._scheduler;null==a?s():i=a.schedule(s)}else r.complete()},error:r.error});return function(){n.unsubscribe(),null!=t._scheduler&&null!=i&&t._scheduler.cancel(i)}}).subscribe({complete:function(){t._complete(n),s()},error:function(e){t._error(e),s()},start:function(e){return t._start(n,e)}})}break;case"ActorPayload":this._processFollowupPayloadWithNormalizationNode(e,e.node);break;default:A(!1)}},t._processFollowupPayloadWithNormalizationNode=function(e,t){this._handleFollowupPayload(e,t),this._maybeCompleteSubscriptionOperationTracking()},t._handleFollowupPayload=function(e,t){var r=this._normalizeFollowupPayload(e,t);this._getPublishQueueAndSaveActor().commitPayload(this._operation,r),this._processPayloadFollowups([r])},t._processIncrementalPlaceholder=function(e,t){var r,i,n,s,a=t.label,o=t.path.map(String).join("."),l=this._incrementalResults.get(a);null==l&&(l=new Map,this._incrementalResults.set(a,l));var u=l.get(o),c=null!=u&&"response"===u.kind?u.responses:null;l.set(o,{kind:"placeholder",placeholder:t}),"stream"===t.kind?i=t.parentID:"defer"===t.kind?i=t.selector.dataID:A(!1);var h=e.source.get(i),f=(null!=(r=e.fieldPayloads)?r:[]).filter(function(e){var t=p(e.dataID,e.fieldKey);return e.dataID===i||t===i});null==h&&A(!1);var g=this._source.get(i);if(null!=g){n=y.update(g.record,h);var m=new Map,v=function(e){var t,r=null!=(t=JSON.stringify(d(e)))?t:"";m.set(r,e)};g.fieldPayloads.forEach(v),f.forEach(v),s=Array.from(m.values())}else n=h,s=f;if(this._source.set(i,{record:n,fieldPayloads:s}),null!=c){var b=this._processIncrementalResponses(c);this._processPayloadFollowups(b)}},t._processIncrementalResponses=function(e){var t=this,r=[];return e.forEach(function(e){var i=e.label,n=e.path,s=e.response,a=t._incrementalResults.get(i);if(null==a&&(a=new Map,t._incrementalResults.set(i,a)),-1!==i.indexOf("$defer$")){var o=n.map(String).join("."),l=a.get(o);if(null==l){l={kind:"response",responses:[e]},a.set(o,l);return}if("response"===l.kind)return void l.responses.push(e);var u=l.placeholder;"defer"!==u.kind&&A(!1),r.push(t._processDeferResponse(i,n,u,s))}else{var c=n.slice(0,-2).map(String).join("."),d=a.get(c);if(null==d){d={kind:"response",responses:[e]},a.set(c,d);return}if("response"===d.kind)return void d.responses.push(e);var h=d.placeholder;"stream"!==h.kind&&A(!1),r.push(t._processStreamResponse(i,n,h,s))}}),r},t._processDeferResponse=function(e,t,r,i){var n=r.selector.dataID,s=this._actorIdentifier;this._actorIdentifier=null!=(u=r.actorIdentifier)?u:this._actorIdentifier;var a=this._normalizeResponse(i,r.selector,r.typeName,{actorIdentifier:this._actorIdentifier,getDataID:this._getDataID,log:this._log,path:r.path,treatMissingFieldsAsNull:this._treatMissingFieldsAsNull,shouldProcessClientComponents:this._shouldProcessClientComponents},this._useExecTimeResolvers);this._getPublishQueueAndSaveActor().commitPayload(this._operation,a);var o=this._source.get(n);null==o&&A(!1);var l=o.fieldPayloads;if(0!==l.length){var u,c,d={errors:null,fieldPayloads:l,incrementalPlaceholders:null,followupPayloads:null,source:E.create(),isFinal:(null==(c=i.extensions)?void 0:c.is_final)===!0};this._getPublishQueueAndSaveActor().commitPayload(this._operation,d)}return this._actorIdentifier=s,a},t._processStreamResponse=function(e,t,r,i){var n=r.parentID,a=r.node,o=r.variables,l=r.actorIdentifier,u=this._actorIdentifier;this._actorIdentifier=null!=l?l:this._actorIdentifier;var c=a.selections[0];(null==c||"LinkedField"!==c.kind||!0!==c.plural)&&A(!1);var d=this._normalizeStreamItem(i,n,c,o,t,r.path),h=d.fieldPayloads,f=d.itemID,p=d.itemIndex,g=d.prevIDs,m=d.relayPayload,y=d.storageKey;if(this._getPublishQueueAndSaveActor().commitPayload(this._operation,m,function(e){var t=e.get(n);if(null!=t){var r=t.getLinkedRecords(y);if(null!=r&&!(r.length!==g.length||r.some(function(e,t){return g[t]!==(e&&e.getDataID())}))){var i=(0,s.default)(r);i[p]=e.get(f),t.setLinkedRecords(i,y)}}}),0!==h.length){var v={errors:null,fieldPayloads:h,incrementalPlaceholders:null,followupPayloads:null,source:E.create(),isFinal:!1};this._getPublishQueueAndSaveActor().commitPayload(this._operation,v)}return this._actorIdentifier=u,m},t._normalizeStreamItem=function(e,t,r,i,n,a){var o,l,u,c,d=e.data;"object"!=typeof d&&A(!1);var h=null!=(o=r.alias)?o:r.name,f=w(r,i),g=this._source.get(t);null==g&&A(!1);
1var m=g.record,v=g.fieldPayloads,_=y.getLinkedRecordIDs(m,f);null==_&&A(!1);var E=n[n.length-1],S=parseInt(E,10);S===E&&S>=0||A(!1);var x=null!=(l=r.concreteType)?l:d[T];"string"!=typeof x&&A(!1);var R=null!=(u=null!=(c=this._getDataID(d,x))?c:null==_?void 0:_[S])?u:p(t,f,S);"string"!=typeof R&&A(!1);var I=b(r,R,i),k=y.clone(m),C=(0,s.default)(_);C[S]=R,y.setLinkedRecordIDs(k,f,C),this._source.set(t,{record:k,fieldPayloads:v});var D=this._normalizeResponse(e,I,x,{actorIdentifier:this._actorIdentifier,getDataID:this._getDataID,log:this._log,path:[].concat((0,s.default)(a),[h,String(S)]),treatMissingFieldsAsNull:this._treatMissingFieldsAsNull,shouldProcessClientComponents:this._shouldProcessClientComponents},this._useExecTimeResolvers);return{fieldPayloads:v,itemID:R,itemIndex:S,prevIDs:_,relayPayload:D,storageKey:f}},t._scheduleAsyncStoreUpdate=function(e,t){var r=this;this._completeFns.push(t),null==this._asyncStoreUpdateDisposable&&(this._asyncStoreUpdateDisposable=e(function(){r._asyncStoreUpdateDisposable=null;var e=r._runPublishQueue();r._updateOperationTracker(e);var t,i=(0,n.default)(r._completeFns);try{for(i.s();!(t=i.n()).done;)(0,t.value)()}catch(e){i.e(e)}finally{i.f()}r._completeFns=[]}))},t._updateOperationTracker=function(e){null!=e&&e.length>0&&this._operationTracker.update(this._operation.request,new Set(e))},t._completeOperationTracker=function(){this._operationTracker.complete(this._operation.request)},t._getPublishQueueAndSaveActor=function(){return this._seenActors.add(this._actorIdentifier),this._getPublishQueue(this._actorIdentifier)},t._getActorsToVisit=function(){return 0===this._seenActors.size?new Set([this._actorIdentifier]):this._seenActors},t._runPublishQueue=function(e){var t,r=new Set,i=(0,n.default)(this._getActorsToVisit());try{for(i.s();!(t=i.n()).done;){var s=t.value;this._getPublishQueue(s).run(e).forEach(function(e){return r.add(e)})}}catch(e){i.e(e)}finally{i.f()}return Array.from(r)},t._retainData=function(){var e,t=(0,n.default)(this._getActorsToVisit());try{for(t.s();!(e=t.n()).done;){var r=e.value;this._retainDisposables.has(r)||this._retainDisposables.set(r,this._getStore(r).retain(this._operation))}}catch(e){t.e(e)}finally{t.f()}},t._disposeRetainedData=function(){var e,t=(0,n.default)(this._retainDisposables.values());try{for(t.s();!(e=t.n()).done;)e.value.dispose()}catch(e){t.e(e)}finally{t.f()}this._retainDisposables.clear()},t._expectOperationLoader=function(){var e=this._operationLoader;return e||A(!1),e},e}();function I(e){var t=e.incrementalPlaceholders;null!=t&&0!==t.length&&A(!1)}t.exports={execute:function(e){return new R(e)}}},285489,(e,t,r)=>{"use strict";var i=Promise.resolve();function n(e){setTimeout(function(){throw e},0)}t.exports=function(e){i.then(e).catch(n)}},269770,(e,t,r)=>{"use strict";var i=e.r(789197),n=e.r(886050).EXISTENT,s=e.r(638743);t.exports=function(){function e(e,t){this.__sources=[t,e],this._base=e,this._sink=t}var t=e.prototype;return t.unstable_getRawRecordWithChanges=function(e){var t=this._base.get(e),r=this._sink.get(e);if(void 0===r)return null==t?t:i.clone(t);return null===r?null:null!=t?i.update(t,r):i.clone(r)},t._getSinkRecord=function(e){var t=this._sink.get(e);if(!t){var r=this._base.get(e);r||s(!1),t=i.create(e,i.getType(r)),this._sink.set(e,t)}return t},t.copyFields=function(e,t){var r=this._sink.get(e),n=this._base.get(e);r||n||s(!1);var a=this._getSinkRecord(t);n&&i.copyFields(n,a),r&&i.copyFields(r,a)},t.copyFieldsFromRecord=function(e,t){var r=this._getSinkRecord(t);i.copyFields(e,r)},t.create=function(e,t){(this._base.getStatus(e)===n||this._sink.getStatus(e)===n)&&s(!1);var r=i.create(e,t);this._sink.set(e,r)},t.delete=function(e){this._sink.delete(e)},t.getStatus=function(e){return this._sink.has(e)?this._sink.getStatus(e):this._base.getStatus(e)},t.getType=function(e){for(var t=0;t<this.__sources.length;t++){var r=this.__sources[t].get(e);if(r)return i.getType(r);if(null===r)return null}},t.getValue=function(e,t){for(var r=0;r<this.__sources.length;r++){var n=this.__sources[r].get(e);if(n){var s=i.getValue(n,t);if(void 0!==s)return s}else if(null===n)return null}},t.setValue=function(e,t,r){var n=this._getSinkRecord(e);i.setValue(n,t,r)},t.getErrors=function(e,t){for(var r=0;r<this.__sources.length;r++){var n=this.__sources[r].get(e);if(n){var s=i.getErrors(n,t);if(void 0!==s)return s}else if(null===n)return null}},t.setErrors=function(e,t,r){var n=this._getSinkRecord(e);i.setErrors(n,t,r)},t.getLinkedRecordID=function(e,t){for(var r=0;r<this.__sources.length;r++){var n=this.__sources[r].get(e);if(n){var s=i.getLinkedRecordID(n,t);if(void 0!==s)return s}else if(null===n)return null}},t.setLinkedRecordID=function(e,t,r){var n=this._getSinkRecord(e);i.setLinkedRecordID(n,t,r)},t.getLinkedRecordIDs=function(e,t){for(var r=0;r<this.__sources.length;r++){var n=this.__sources[r].get(e);if(n){var s=i.getLinkedRecordIDs(n,t);if(void 0!==s)return s}else if(null===n)return null}},t.setLinkedRecordIDs=function(e,t,r){var n=this._getSinkRecord(e);i.setLinkedRecordIDs(n,t,r)},e}()},609777,(e,t,r)=>{"use strict";var i=(0,e.r(13451).default)(e.r(877913)),n=e.r(765754).getArgumentValues,s=["id","__id","__typename","js"];t.exports={createUpdatableProxy:function(e,t,r,a,o){var l={};return function e(t,r,a,o,l,u){var c,d,h,f,p=(0,i.default)(o);try{for(p.s();!(f=p.n()).done;)!function(){var o=f.value;switch(o.kind){case"LinkedField":o.plural?Object.defineProperty(t,null!=(c=o.alias)?c:o.name,{get:function(t,r,s,a,o){return function(){var l,u=n(null!=(l=t.args)?l:[],r),c=s.getLinkedRecords(t.name,u);return(void 0===c&&(c=function(e,t,r,n,s){var a,o=(0,i.default)(s);try{for(o.s();!(a=o.n()).done;){var l=a.value;if("pluralLinked"===l.kind){var u=l.handle(e,r,t,n);if(null!=u)return u.map(function(e){if(null!=e)return n.get(e)})}}}catch(e){o.e(e)}finally{o.f()}}(t,u,s,a,o)),null!=c)?c.map(function(i){if(null==i)return i;var n={};return e(n,i,r,t.selections,a,o),n}):c}}(o,a,r,l,u),set:function(e,t,r,i){return function(s){var a,o=n(null!=(a=e.args)?a:[],t);if(null==s)throw Error("Do not assign null to plural linked fields; assign an empty array instead.");var l=s.map(function(e){if(null==e)throw Error("When assigning an array of items, none of the items should be null or undefined.");var t=e.__id;if(null==t)throw Error("The __id field must be present on each item passed to the setter. This indicates a bug in Relay.");var r=i.get(t);
1if(null==r)throw Error("Did not find item with data id ".concat(t," in the store."));return r});r.setLinkedRecords(l,e.name,o)}}(o,a,r,l)}):Object.defineProperty(t,null!=(d=o.alias)?d:o.name,{get:function(t,r,s,a,o){return function(){var l,u=n(null!=(l=t.args)?l:[],r),c=s.getLinkedRecord(t.name,u);if(void 0===c&&(c=function(e,t,r,n,s){var a,o=(0,i.default)(s);try{for(o.s();!(a=o.n()).done;){var l=a.value;if("linked"===l.kind){var u=l.handle(e,r,t,n);if(null!=u)return n.get(u)}}}catch(e){o.e(e)}finally{o.f()}}(t,u,s,a,o)),null==c)return c;var d={};return e(d,c,r,t.selections,a,o),d}}(o,a,r,l,u),set:function(e,t,r,i){return function(s){var a,o=n(null!=(a=e.args)?a:[],t);if(null==s)r.setValue(s,e.name,o);else{var l=s.__id;if(null==l)throw Error("The __id field must be present on the argument. This indicates a bug in Relay.");var u=i.get(l);if(null==u)throw Error("Did not find item with data id ".concat(l," in the store."));r.setLinkedRecord(u,e.name,o)}}}(o,a,r,l)});break;case"ScalarField":var p=null!=(h=o.alias)?h:o.name;Object.defineProperty(t,p,{get:function(){var e,t=n(null!=(e=o.args)?e:[],a),s=r.getValue(o.name,t);return null==s&&(s=function(e,t,r,n,s){var a,o=(0,i.default)(s);try{for(o.s();!(a=o.n()).done;){var l=a.value;if("scalar"===l.kind){var u=l.handle(e,r,t,n);if(void 0!==u)return u}}}catch(e){o.e(e)}finally{o.f()}}(o,t,r,l,u)),s},set:s.includes(o.name)?void 0:function(e){var t,i=n(null!=(t=o.args)?t:[],a);r.setValue__UNSAFE(e,o.name,i)}});break;case"InlineFragment":r.getType()===o.type&&e(t,r,a,o.selections,l,u);break;case"ClientExtension":e(t,r,a,o.selections,l,u);break;case"FragmentSpread":break;case"Condition":case"ActorChange":case"InlineDataFragmentSpread":case"AliasedInlineFragmentSpread":case"ClientEdgeToClientObject":case"ClientEdgeToServerObject":case"Defer":case"ModuleImport":case"RequiredField":case"CatchField":case"Stream":case"RelayResolver":case"RelayLiveResolver":throw Error("Encountered an unexpected ReaderSelection variant in RelayRecordSourceProxy. This indicates a bug in Relay.");default:throw o.kind,Error("Encountered an unexpected ReaderSelection variant in RelayRecordSourceProxy. This indicates a bug in Relay.")}}()}catch(e){p.e(e)}finally{p.f()}}(l,e,t,r,a,o),l}}},331104,(e,t,r)=>{"use strict";var i=e.r(930649).getFragment,n=e.r(461055).getVariablesFromFragment,s=e.r(765754).ID_KEY,a=e.r(609777).createUpdatableProxy,o=e.r(638743);t.exports={readUpdatableFragment:function(e,t,r,l){var u=i(e),c=n(u,t),d=t[s],h=r.get(d);return null==h&&o(!1),{updatableData:a(h,c,u.selections,r,l)}}}},842996,(e,t,r)=>{"use strict";var i=e.r(930649).getUpdatableQuery,n=e.r(609777).createUpdatableProxy;t.exports={readUpdatableQuery:function(e,t,r,s){var a=i(e);return{updatableData:n(r.getRoot(),t,a.fragment.selections,r,s)}}}},740209,(e,t,r)=>{"use strict";var i=e.r(883316).generateClientID,n=e.r(765754).getStableStorageKey,s=e.r(638743);t.exports=function(){function e(e,t,r){this._dataID=r,this._mutator=t,this._source=e}var t=e.prototype;return t.copyFieldsFrom=function(e){this._mutator.copyFields(e.getDataID(),this._dataID)},t.getDataID=function(){return this._dataID},t.getType=function(){var e=this._mutator.getType(this._dataID);return null==e&&s(!1),e},t.getValue=function(e,t){var r=n(e,t);return this._mutator.getValue(this._dataID,r)},t.setValue=function(e,t,r,i){return function e(t){return null==t||"object"!=typeof t||Array.isArray(t)&&t.every(e)}(e)||s(!1),this.setValue__UNSAFE(e,t,r,i)},t.getErrors=function(e,t){var r=n(e,t);return this._mutator.getErrors(this._dataID,r)},t.setValue__UNSAFE=function(e,t,r,i){var s=n(t,r);return this._mutator.setValue(this._dataID,s,e),null!=i&&(0===i.length?this._mutator.setErrors(this._dataID,s):this._mutator.setErrors(this._dataID,s,i)),this},t.getLinkedRecord=function(e,t){var r=n(e,t),i=this._mutator.getLinkedRecordID(this._dataID,r);return null!=i?this._source.get(i):i},t.setLinkedRecord=function(t,r,i){t instanceof e||s(!1);var a=n(r,i),o=t.getDataID();return this._mutator.setLinkedRecordID(this._dataID,a,o),this},t.getOrCreateLinkedRecord=function(e,t,r){var s=this.getLinkedRecord(e,r);if(!s){var a,o=n(e,r),l=i(this.getDataID(),o);s=null!=(a=this._source.get(l))?a:this._source.create(l,t),this.setLinkedRecord(s,e,r)}return s},t.getLinkedRecords=function(e,t){var r=this,i=n(e,t),s=this._mutator.getLinkedRecordIDs(this._dataID,i);return null==s?s:s.map(function(e){return null!=e?r._source.get(e):e})},t.setLinkedRecords=function(e,t,r){Array.isArray(e)||s(!1);var i=n(t,r),a=e.map(function(e){return e&&e.getDataID()});return this._mutator.setLinkedRecordIDs(this._dataID,i,a),this},t.invalidateRecord=function(){this._source.markIDForInvalidation(this._dataID)},e}()},479576,(e,t,r)=>{"use strict";var i=e.r(789197),n=e.r(886050),s=n.EXISTENT,a=n.NONEXISTENT,o=e.r(765754),l=o.ROOT_ID,u=o.ROOT_TYPE,c=e.r(331104).readUpdatableFragment,d=e.r(84299
16).readUpdatableQuery,h=e.r(740209),f=e.r(638743);t.exports=function(){function e(e,t,r,i,n){this.__mutator=e,this._handlerProvider=r||null,this._proxies={},this._getDataID=t,this._invalidatedStore=!1,this._idsMarkedForInvalidation=new Set,this._missingFieldHandlers=i,this._log=null!=n?n:function(e){}}var t=e.prototype;return t.publishSource=function(e,t){var r=this;e.getRecordIDs().forEach(function(t){var n=e.getStatus(t);if(n===s){var o=e.get(t);o&&(r.__mutator.getStatus(t)!==s&&r.create(t,i.getType(o)),r.__mutator.copyFieldsFromRecord(o,t))}else n===a&&r.delete(t)}),t&&t.length&&t.forEach(function(e){var t=r._handlerProvider&&r._handlerProvider(e.handle);t||f(!1),t.update(r,e)})},t.create=function(e,t){this.__mutator.create(e,t),delete this._proxies[e];var r=this.get(e);return r||f(!1),r},t.delete=function(e){e===l&&f(!1),delete this._proxies[e],this.__mutator.delete(e)},t.get=function(e){if(!this._proxies.hasOwnProperty(e)){var t=this.__mutator.getStatus(e);t===s?this._proxies[e]=new h(this,this.__mutator,e):this._proxies[e]=t===a?null:void 0}return this._proxies[e]},t.getRoot=function(){var e=this.get(l);return e||(e=this.create(l,u)),e&&e.getType()===u||f(!1),e},t.invalidateStore=function(){this._invalidatedStore=!0},t.isStoreMarkedForInvalidation=function(){return this._invalidatedStore},t.markIDForInvalidation=function(e){this._idsMarkedForInvalidation.add(e)},t.getIDsMarkedForInvalidation=function(){return this._idsMarkedForInvalidation},t.readUpdatableQuery=function(e,t){return d(e,t,this,this._missingFieldHandlers)},t.readUpdatableFragment=function(e,t){return c(e,t,this,this._missingFieldHandlers)},e}()},923040,(e,t,r)=>{"use strict";var i=e.r(710273).LINKED_FIELD,n=e.r(765754).getHandleStorageKey,s=e.r(832780),a=e.r(638743);t.exports=function(e,t,r){var o=t.find(function(t){return t.kind===i&&t.name===e.name&&t.alias===e.alias&&s(t.args,e.args)});o&&o.kind===i||a(!1);var l=n(e,r);return{kind:"LinkedField",alias:o.alias,name:l,storageKey:l,args:null,concreteType:o.concreteType,plural:o.plural,selections:o.selections}}},617907,(e,t,r)=>{"use strict";var i=e.r(710273).SCALAR_FIELD,n=e.r(765754).getHandleStorageKey,s=e.r(832780),a=e.r(638743);t.exports=function(e,t,r){var o=t.find(function(t){return t.kind===i&&t.name===e.name&&t.alias===e.alias&&s(t.args,e.args)});o&&o.kind===i||a(!1);var l=n(e,r);return{kind:"ScalarField",alias:o.alias,name:l,storageKey:l,args:null}}},690636,(e,t,r)=>{"use strict";var i=(0,e.r(13451).default)(e.r(877913)),n=e.r(269770),s=e.r(479576),a=e.r(89478),o=e.r(883316).isClientID,l=e.r(923040),u=e.r(617907),c=e.r(698042).getLocalVariables,d=e.r(789197),h=e.r(886050),f=h.EXISTENT,p=h.UNKNOWN,g=e.r(765754),m=e.r(638867),y=m.TYPE_SCHEMA_TYPE,v=m.generateTypeID,b=e.r(638743),_=g.getModuleOperationKey,E=g.getStorageKey,S=g.getArgumentValues,x=function(){function e(e,t,r,i,n,s,a,o,l,u){this._getSourceForActor=e,this._getTargetForActor=t,this._getDataID=a,this._source=e(r),this._mutatorRecordSourceProxyCache=new Map;var c=this._getMutatorAndRecordProxyForActor(r),d=c[0],h=c[1];this._useExecTimeResolvers=null!=u&&u,this._mostRecentlyInvalidatedAt=null,this._handlers=n,this._mutator=d,this._operationLoader=null!=s?s:null,this._recordSourceProxy=h,this._recordWasMissing=!1,this._variables=i,this._shouldProcessClientComponents=o,this._log=l}var t=e.prototype;return t._getMutatorAndRecordProxyForActor=function(e){var t=this._mutatorRecordSourceProxyCache.get(e);if(null==t){var r=this._getTargetForActor(e),i=new n(this._getSourceForActor(e),r),a=new s(i,this._getDataID,void 0,this._handlers,this._log);t=[i,a],this._mutatorRecordSourceProxyCache.set(e,t)}return t},t.check=function(e,t){return this._assignClientAbstractTypes(e),this._traverse(e,t),
1!0===this._recordWasMissing?{status:"missing",mostRecentlyInvalidatedAt:this._mostRecentlyInvalidatedAt}:{status:"available",mostRecentlyInvalidatedAt:this._mostRecentlyInvalidatedAt}},t._getVariableValue=function(e){return this._variables.hasOwnProperty(e)||b(!1),this._variables[e]},t._handleMissing=function(){this._recordWasMissing=!0},t._handleMissingScalarField=function(e,t){if(!("id"===e.name&&null==e.alias&&o(t))){var r,n=void 0!=e.args?S(e.args,this._variables):{},s=(0,i.default)(this._handlers);try{for(s.s();!(r=s.n()).done;){var a=r.value;if("scalar"===a.kind){var l=a.handle(e,this._recordSourceProxy.get(t),n,this._recordSourceProxy);if(void 0!==l)return l}}}catch(e){s.e(e)}finally{s.f()}this._handleMissing()}},t._handleMissingLinkField=function(e,t){var r,n=void 0!=e.args?S(e.args,this._variables):{},s=(0,i.default)(this._handlers);try{for(s.s();!(r=s.n()).done;){var a=r.value;if("linked"===a.kind){var o=a.handle(e,this._recordSourceProxy.get(t),n,this._recordSourceProxy);if(void 0!==o&&(null===o||this._mutator.getStatus(o)===f))return o}}}catch(e){s.e(e)}finally{s.f()}this._handleMissing()},t._handleMissingPluralLinkField=function(e,t){var r,n=this,s=void 0!=e.args?S(e.args,this._variables):{},a=(0,i.default)(this._handlers);try{for(a.s();!(r=a.n()).done;){var o=r.value;if("pluralLinked"===o.kind){var l=o.handle(e,this._recordSourceProxy.get(t),s,this._recordSourceProxy);if(null!=l){if(l.every(function(e){return null!=e&&n._mutator.getStatus(e)===f}))return l}else if(null===l)return null}}}catch(e){a.e(e)}finally{a.f()}this._handleMissing()},t._traverse=function(e,t){var r=this._mutator.getStatus(t);if(r===p&&this._handleMissing(),r===f){var i=this._source.get(t),n=d.getInvalidationEpoch(i);null!=n&&(this._mostRecentlyInvalidatedAt=null!=this._mostRecentlyInvalidatedAt?Math.max(this._mostRecentlyInvalidatedAt,n):n),this._traverseSelections(e.selections,t)}},t._traverseSelections=function(e,t){var r=this;e.forEach(function(i){switch(i.kind){case"ScalarField":r._checkScalar(i,t);break;case"LinkedField":i.plural?r._checkPluralLink(i,t):r._checkLink(i,t);break;case"ActorChange":r._checkActorChange(i.linkedField,t);break;case"Condition":!!r._getVariableValue(i.condition)===i.passingValue&&r._traverseSelections(i.selections,t);break;case"InlineFragment":var n=i.abstractKey;if(null==n)r._mutator.getType(t)===i.type&&r._traverseSelections(i.selections,t);else{var s=r._mutator.getType(t);null==s&&b(!1);var a=v(s),o=r._mutator.getValue(a,n);!0===o?r._traverseSelections(i.selections,t):null==o&&r._handleMissing()}break;case"LinkedHandle":var d=l(i,e,r._variables);d.plural?r._checkPluralLink(d,t):r._checkLink(d,t);break;case"ScalarHandle":var h=u(i,e,r._variables);r._checkScalar(h,t);break;case"ModuleImport":r._checkModuleImport(i,t);break;case"Defer":case"Stream":r._traverseSelections(i.selections,t);break;case"FragmentSpread":var f=r._variables;r._variables=c(r._variables,i.fragment.argumentDefinitions,i.args),r._traverseSelections(i.fragment.selections,t),r._variables=f;break;case"ClientExtension":var p=r._recordWasMissing;r._traverseSelections(i.selections,t),r._recordWasMissing=p;break;case"TypeDiscriminator":var g=i.abstractKey,m=r._mutator.getType(t);null==m&&b(!1);var y=v(m);null==r._mutator.getValue(y,g)&&r._handleMissing();break;case"ClientComponent":if(!1===r._shouldProcessClientComponents)break;r._traverseSelections(i.fragment.selections,t);break;case"RelayResolver":case"RelayLiveResolver":r._useExecTimeResolvers||r._checkResolver(i,t);break;case"ClientEdgeToClientObject":r._useExecTimeResolvers||r._checkResolver(i.backingField,t);break;default:b(!1)}})},t._checkResolver=function(e,t){e.fragment&&this._traverseSelections([e.fragment],t)},t._checkModuleImport=function(e,t){var r=this._operationLoader;null===r&&b(!1);var i=_(e.documentName),n=this._mutator.getValue(t,i);if(null==n){void 0===n&&this._handleMissing();return}var s=r.get(n);if(null!=s){var o=a(s),l=this._variables;this._variables=c(this._variables,o.argumentDefinitions,e.args),this._traverse(o,t),this._variables=l}else this._handleMissing()},t._checkScalar=function(e,t){var r=E(e,this._variables),i=this._mutator.getValue(t,r);void 0===i&&void 0!==(i=this._handleMissingScalarField(e,t))&&this._mutator.setValue(t,r,i)},t._checkLink=function(e,t){var r=E(e,this._variables),i=this._mutator.getLinkedRecordID(t,r);void 0===i&&(null!=(i=this._handleMissingLinkField(e,t))?this._mutator.setLinkedRecordID(t,r,i):null===i&&this._mutator.setValue(t,r,null)),null!=i&&this._traverse(e,i)}
1,t._checkPluralLink=function(e,t){var r=this,i=E(e,this._variables),n=this._mutator.getLinkedRecordIDs(t,i);void 0===n&&(null!=(n=this._handleMissingPluralLinkField(e,t))?this._mutator.setLinkedRecordIDs(t,i,n):null===n&&this._mutator.setValue(t,i,null)),n&&n.forEach(function(t){null!=t&&r._traverse(e,t)})},t._checkActorChange=function(e,t){var r=E(e,this._variables),i=this._source.get(t),n=null!=i?d.getActorLinkedRecordID(i,r):i;if(null==n)void 0===n&&this._handleMissing();else{var s=n[0],a=n[1],o=this._source,l=this._mutator,u=this._recordSourceProxy,c=this._getMutatorAndRecordProxyForActor(s),h=c[0],f=c[1];this._source=this._getSourceForActor(s),this._mutator=h,this._recordSourceProxy=f,this._assignClientAbstractTypes(e),this._traverse(e,a),this._source=o,this._mutator=l,this._recordSourceProxy=u}},t._assignClientAbstractTypes=function(e){var t=e.clientAbstractTypes;if(null!=t)for(var r=0,n=Object.keys(t);r<n.length;r++){var s,a=n[r],o=(0,i.default)(t[a]);try{for(o.s();!(s=o.n()).done;){var l=s.value,u=v(l);null==this._source.get(u)&&this._mutator.create(u,y),null==this._mutator.getValue(u,a)&&this._mutator.setValue(u,a,!0)}}catch(e){o.e(e)}finally{o.f()}}},e}();t.exports={check:function(e,t,r,i,n,s,a,o,l,u){null!=l&&l({name:"store.datachecker.start",selector:i});var c=i.dataID,d=i.node,h=new x(e,t,r,i.variables,n,s,a,o,l,u).check(d,c
1);return null!=l&&l({name:"store.datachecker.end",selector:i}),h}}},108487,(e,t,r)=>{"use strict";t.exports=function(e){"object"==typeof e&&null!=e&&(Array.isArray(e)||e.constructor===Object)&&Object.freeze(e)}},385343,(e,t,r)=>{"use strict";var i=e.r(789197),n=e.r(765754).RELAY_RESOLVER_OUTPUT_TYPE_RECORD_IDS,s=e.r(638743);t.exports=function(e){var t=i.getValue(e,n);return null==t?null:(t instanceof Set||s(!1),t)}},155218,(e,t,r)=>{"use strict";t.exports=function(e){return null!=e&&"object"==typeof e&&"function"==typeof e.read&&"function"==typeof e.subscribe}},404062,(e,t,r)=>{"use strict";var i=(0,e.r(13451).default)(e.r(877913)),n=e.r(667256),s=e.r(710273).RELAY_LIVE_RESOLVER,a=e.r(100975),o=e.r(108487),l=e.r(883316),u=l.generateClientID,c=l.generateClientObjectClientID,d=e.r(789197),h=e.r(461055).createNormalizationSelector,f=e.r(244209),p=e.r(678359).normalize,g=e.r(765754),m=g.RELAY_RESOLVER_ERROR_KEY,y=g.RELAY_RESOLVER_INVALIDATION_KEY,v=g.RELAY_RESOLVER_OUTPUT_TYPE_RECORD_IDS,b=g.RELAY_RESOLVER_SNAPSHOT_KEY,_=g.RELAY_RESOLVER_VALUE_KEY,E=g.getReadTimeResolverStorageKey,S=g.getStorageKey,x=e.r(385343),T=e.r(155218),w=e.r(824461).isSuspenseSentinel,A=e.r(638743);e.r(603158);var R="__resolverLiveStateSubscription",I="__resolverLiveStateValue",k="__resolverLiveStateDirty",C="__RELAY_RESOLVER__";function D(e,t,r){var i=e.get(t);i||(i=new Set,e.set(t,i)),i.add(r)}function L(e,t,r){var n=new Set;if(null!=r){var s,a=(0,i.default)(r);try{for(a.s();!(s=a.n()).done;){var o=s.value;t.has(o)||(n.add(o),e.remove(o))}}catch(e){a.e(e)}finally{a.f()}}var l,u=(0,i.default)(t.getRecordIDs());try{for(u.s();!(l=u.n()).done;){var c=l.value,h=N(t,c);if(e.has(c)){var f=N(e,c),p=d.update(f,h);p!==f&&(n.add(c),e.set(c,p),function(e,t){var r,n,s=(r=new Set,d.getFields(e).forEach(function(t){if(d.hasLinkedRecordID(e,t)){var i,n=d.getLinkedRecordID(e,t);null!=n&&r.add(n)}else d.hasLinkedRecordIDs(e,t)&&(null==(i=d.getLinkedRecordIDs(e,t))||i.forEach(function(e){null!=e&&r.add(e)}))}),r),a=(0,i.default)(s);try{for(a.s();!(n=a.n()).done;){var o=n.value,l=t.get(o);null!=l&&P(l)&&O(o,t)}}catch(e){a.e(e)}finally{a.f()}}(f,e))}else e.set(c,h)}}catch(e){u.e(e)}finally{u.f()}return n}function O(e,t){var r=t.get(e);if(r){var i=d.clone(r);d.setValue(i,y,!0),t.set(e,i)}}function P(e){return d.getType(e)===C}function F(e){var t=d.getValue(e,R);null!=t&&t()}function N(e,t){var r=e.get(t);return null==r&&A(!1),r}function M(e,t){var r,i=null!=(r=e.concreteType)?r:t.__typename;return null==i&&A(!1),i}t.exports={LiveResolverCache:function(){function e(e,t){this._resolverIDToRecordIDs=new Map,this._recordIDToResolverIDs=new Map,this._getRecordSource=e,this._store=t,this._handlingBatch=!1,this._liveResolverBatchRecordSource=null}var t=e.prototype;return t.readFromCacheOrEvaluate=function(e,t,r,n,a){var o,l=this._getRecordSource(),c=N(l,e),h=E(t,r),f=d.getLinkedRecordID(c,h),p=null==f?null:l.get(f);if(null==p||this._isInvalid(p,a)){null!=p&&F(p),f=null!=(O=f)?O:u(e,h),p=d.create(f,C);var g=n();if(d.setValue(p,b,g.snapshot),d.setValue(p,m,g.error),t.kind===s){if(null!=g.resolverResult){null!=g.error&&A(!1);var y=g.resolverResult;L=this._setLiveStateValue(p,f,y,t,r)}}else L=this._setResolverValue(p,g.resolverResult,t,r);l.set(f,p);var v=N(l,e),_=d.clone(v);if(d.setLinkedRecordID(_,h,f),l.set(e,_),null!=t.fragment){var x=u(e,S(t.fragment,r));D(this._resolverIDToRecordIDs,x,f),D(this._recordIDToResolverIDs,e,x);var R=null==(P=g.snapshot)?void 0:P.seenRecords;if(null!=R){var L,O,P,M,j=(0,i.default)(R);try{for(j.s();!(M=j.n()).done;){var $=M.value;D(this._recordIDToResolverIDs,$,x)}}catch(e){j.e(e)}finally{j.f()}}}}else if(t.kind===s&&d.getValue(p,k)){f=null!=(U=f)?U:u(e,h),p=d.clone(p);var U,B=d.getValue(p,I);T(B)||A(!1),L=this._setLiveResolverValue(p,B,t,r),d.setValue(p,k,!1),l.set(f,p)}var V=this._getResolverValue(p),G=d.getValue(p,b),q=d.getValue(p,m),H=null;return w(V)&&(H=null!=(o=f)?o:u(e,h)),[V,f,q,G,H,L]},t.getLiveResolverPromise=function(e){var t=this._getRecordSource().get(e);null==t&&A(!1);var r=d.getValue(t,I);return new Promise(function(e){var t=r.subscribe(function(){t(),e()})})},t._setLiveStateValue=function(e,t,r,i,n){var s=this._makeLiveStateHandler(t),a=r.subscribe(s);d.setValue(e,I,r);var o=this._setLiveResolverValue(e,r,i,n);return d.setValue(e,k,!1),d.setValue(e,R,a),o},t._makeLiveStateHandler=function(e){var t=this;return function(){var r=t._getRecordSource().get(e);if(r&&d.hasValue(r,I)){var i=d.clone(r);d.setValue(i,k,!0),t._setLiveResolverUpdate(e,i)}}},t._setLiveResolverUpdate=function(e,t){if(this._handlingBatch)null==this._liveResolverBatchRecordSource&&(this._liveResolverBatchRecordSource=f.create()),this._liveResolverBatchRecordSource.set(e,t);else{var r=f.create();r.set(e,t),this._store.publish(r),this._store.notify()}},t.batchLiveStateUpdates=function(e){this._handlingBatch&&A(!1),this._handlingBatch=!0;try{e()}finally{null!=this._liveResolverBatchRecordSource&&(this._store.publish(this._liveResolverBatchRecordSource),this._store.notify()),this._liveResolverBatchRecordSource=null,this._handlingBatch=!1}},t._setLiveResolverValue=function(e,t,r,i){var n=null,s=null;try{n=t.read()}catch(e){s=e}return d.setValue(e,m,s),this._setResolverValue(e,n,r,i)},t._setResolverValue=function(e,t,r,n){var s=r.normalizationInfo,a=null;if(null==t||null==s||w(t))o(t),d.setValue(e,_,t);else{var l=x(e),u=new Set,h=this._getRecordSource();if(s.plural){Array.isArray(t)||A(!1),y=[];for(var p=f.create(),g=0;g<t.length;g++){var m=t[g];if(null!=m){"object"!=typeof m&&A(!1);var y,b,E=M(s,m),S=c(E,d.getDataID(e),g),T=this._normalizeOutputTypeValue(S,m,n,s,[r.path,String(g)],E),R=(0,i.default)(T.getRecordIDs());try{for(R.s();!(b=R.n()).done;){var I=b.value;p.set(I,N(T,I)),u.add(I)}}catch(e){R.e(e)}finally{R.f()}y.push(S)}}a=L(h,p,l)}else{"object"!=typeof t&&A(!1);var k,C=M(s,t),D=c(C,d.getDataID(e)),O=this._normalizeOutputTypeValue(D,t,n,s,[r.path],C),P=(0,i.default)(O.getRecordIDs());try{for(P.s();!(k=P.n()).done;){var F=k.value;u.add(F)}}catch(e){P.e(e)}finally{P.f()}y=D,a=L(h,O,l)}d.setValue(e,v,u),o(y),d.setValue(e,_,y)}return a},t.notifyUpdatedSubscribers=function(e){this._store.__notifyUpdatedSubscribers(e)},t._getResolverValue=function(e){return d.getValue(e,_)},t.invalidateDataIDs=function(e){for(var t=this._getRecordSource(),r
1=new Set,n=Array.from(e);n.length;){var s=n.pop();r.add(s),e.add(s);var a=this._recordIDToResolverIDs.get(s);if(null!=a){var o,l=(0,i.default)(a);try{for(l.s();!(o=l.n()).done;){var u=o.value;if(!r.has(u)){r.add(u);var c=this._resolverIDToRecordIDs.get(u);if(null==c)continue;var d,h=(0,i.default)(c);try{for(h.s();!(d=h.n()).done;){var f=d.value;O(f,t),r.has(f)||(r.add(f),n.push(f))}}catch(e){h.e(e)}finally{h.f()}}}}catch(e){l.e(e)}finally{l.f()}}}},t._isInvalid=function(e,t){if(!d.getValue(e,y))return!1;var r=d.getValue(e,b),i=null==r?void 0:r.data,s=null==r?void 0:r.selector;if(null==i||null==s||n(i,t(s).data)!==i)return!0;if(a.MARK_RESOLVER_VALUES_AS_CLEAN_AFTER_FRAGMENT_REREAD){var o=d.clone(e);d.setValue(o,y,!1),this._getRecordSource().set(d.getDataID(e),o)}return!1},t._normalizeOutputTypeValue=function(e,t,r,i,n,s){var a=f.create();switch(i.kind){case"OutputType":var o=d.create(e,s);return a.set(e,o),p(a,h(i.normalizationNode,e,r),t,this._store.__getNormalizationOptions(n),void 0,!1).source;case"WeakModel":var l=d.create(e,s);return d.setValue(l,"__relay_model_instance",t),a.set(e,l),a;default:i.kind,A(!1)}},t.ensureClientRecord=function(e,t){var r=c(t,e),i=this._getRecordSource();if(!i.has(r)){var n=d.create(r,t);d.setValue(n,"id",e),i.set(r,n)}return r},t.unsubscribeFromLiveResolverRecords=function(e){return function(e,t){if(0!==t.size){var r,n=(0,i.default)(t);try{for(n.s();!(r=n.n()).done;){var s=r.value,a=e.get(s);null!=a&&P(a)&&F(a)}}catch(e){n.e(e)}finally{n.f()}}}(this._getRecordSource(),e)},t.invalidateResolverRecords=function(e){if(0!==e.size){var t,r=(0,i.default)(e);try{for(r.s();!(t=r.n()).done;){var n=t.value,s=this._getRecordSource().get(n);null!=s&&P(s)&&this._getRecordSource().delete(n)}}catch(e){r.e(e)}finally{r.f()}}},e}(),getUpdatedDataIDs:function(e){return e},RELAY_RESOLVER_LIVE_STATE_SUBSCRIPTION_KEY:R}},960708,(e,t,r)=>{"use strict";var i=(0,e.r(13451).default)(e.r(802953)),n=e.r(789197),s=e.r(244209),a=e.r(638743),o=n.fromObject(Object.freeze({__UNPUBLISH_RECORD_SENTINEL:!0})),l=function(){function e(e){this._base=e,this._sink=s.create()}var t=e.prototype;return t.has=function(e){return this._sink.has(e)?this._sink.get(e)!==o:this._base.has(e)},t.get=function(e){if(!this._sink.has(e))return this._base.get(e);var t=this._sink.get(e);if(t!==o)return t},t.getStatus=function(e){var t=this.get(e);return void 0===t?"UNKNOWN":null===t?"NONEXISTENT":"EXISTENT"},t.clear=function(){this._base=s.create(),this._sink.clear()},t.delete=function(e){this._sink.delete(e)},t.remove=function(e){this._sink.set(e,o)},t.set=function(e,t){this._sink.set(e,t)},t.getRecordIDs=function(){return Object.keys(this.toJSON())},t.size=function(){return Object.keys(this.toJSON()).length},t.toJSON=function(){var e=this,t=(0,i.default)({},this._base.toJSON());return this._sink.getRecordIDs().forEach(function(r){var i=e.get(r);void 0===i?delete t[r]:t[r]=n.toJSON(i)}),t},t.getOptimisticRecordIDs=function(){return new Set(this._sink.getRecordIDs())},e}();t.exports={create:function(e){return new l(e)},getOptimisticRecordIDs:function(e){return e instanceof l||a(!1),e.getOptimisticRecordIDs()}}},363247,(e,t,r)=>{"use strict";var i=e.r(710273).RELAY_LIVE_RESOLVER,n=e.r(638743);t.exports={NoopResolverCache:function(){function e(){}var t=e.prototype;return t.readFromCacheOrEvaluate=function(e,t,r,s,a){t.kind===i&&n(!1);var o=s(),l=o.resolverResult,u=o.snapshot;return[l,void 0,o.error,u,void 0,void 0]},t.invalidateDataIDs=function(e){},t.ensureClientRecord=function(e,t){n(!1)},t.notifyUpdatedSubscribers=function(e){},e}()}},280075,(e,t,r)=>{"use strict";var i=e.r(13451).default,n=i(e.r(802953)),s=i(e.r(514414)),a=i(e.r(800419)),o=i(e.r(117675)),l=["message"],u=e.r(100975),c=e.r(824461).isSuspenseSentinel,d=e.r(698042),h=e.r(789197),f=e.r(765754),p=f.CLIENT_EDGE_TRAVERSAL_PATH,g=f.FRAGMENT_OWNER_KEY,m=f.FRAGMENT_PROP_NAME_KEY,y=f.FRAGMENTS_KEY,v=f.ID_KEY,b=f.MODULE_COMPONENT_KEY,_=f.ROOT_ID,E=f.getArgumentValues,S=f.getModuleComponentKey,x=f.getStorageKey,T=e.r(363247).NoopResolverCache,w=e.r(50219),A=w.RESOLVER_FRAGMENT_ERRORED_SENTINEL,R=w.withResolverContext,I=e.r(638867).generateTypeID,k=e.r(638743);function C(e,t,r,i){return new D(e,t,null!=r?r:new T,i).read()}
1var D=function(){function e(e,t,r,i){var n,s,a,l;this._clientEdgeTraversalPath=null!=(n=t.clientEdgeTraversalPath)&&n.length?(0,o.default)(t.clientEdgeTraversalPath):[],this._missingClientEdges=[],this._missingLiveResolverFields=[],this._isMissingData=!1,this._isWithinUnmatchedTypeRefinement=!1,this._fieldErrors=null,this._owner=t.owner,this._useExecTimeResolvers=null!=(s=null!=(a=this._owner.node.operation.use_exec_time_resolvers)?a:(null==(l=this._owner.node.operation.exec_time_resolvers_enabled_provider)?void 0:l.get())===!0)&&s,this._recordSource=e,this._seenRecords=new Set,this._selector=t,this._variables=t.variables,this._resolverCache=r,this._fragmentName=t.node.name,this._updatedDataIDs=new Set,this._resolverContext=i}var t=e.prototype;return t.read=function(){var e,t=this._selector,r=t.node,i=t.dataID,n=t.isWithinUnmatchedTypeRefinement,s=r.abstractKey,a=this._recordSource.get(i),o=!n;o&&null==s&&null!=a&&!this._recordMatchesTypeCondition(a,r.type)&&(o=!1),o&&null!=s&&null!=a&&!1===this._implementsInterface(a,s)&&(o=!1),this._isWithinUnmatchedTypeRefinement=!o;var l=this._traverse(r,i,null),u=null==(e=this._selector.node.metadata)?void 0:e.catchTo;return null!=u&&(l=this._catchErrors(l,u,null)),this._updatedDataIDs.size>0&&(this._resolverCache.notifyUpdatedSubscribers(this._updatedDataIDs),this._updatedDataIDs.clear()),{data:l,isMissingData:this._isMissingData&&o,missingClientEdges:this._missingClientEdges.length?this._missingClientEdges:null,missingLiveResolverFields:this._missingLiveResolverFields,seenRecords:this._seenRecords,selector:this._selector,fieldErrors:this._fieldErrors}},t._maybeAddFieldErrors=function(e,t){var r=h.getErrors(e,t);if(null!=r){var i=this._fragmentName;null==this._fieldErrors&&(this._fieldErrors=[]);for(var n=0;n<r.length;n++){var s,a,o,l=r[n];this._fieldErrors.push({kind:"relay_field_payload.error",owner:i,fieldPath:(null!=(s=l.path)?s:[]).join("."),error:l,shouldThrow:null!=(a=null==(o=this._selector.node.metadata)?void 0:o.throwOnFieldError)&&a,handled:!1,uiContext:void 0})}}},t._markDataAsMissing=function(e){if(!this._isWithinUnmatchedTypeRefinement){null==this._fieldErrors&&(this._fieldErrors=[]);var t,r,i=this._fragmentName;if(this._fieldErrors.push(null!=(t=null==(r=this._selector.node.metadata)?void 0:r.throwOnFieldError)&&t?{kind:"missing_expected_data.throw",owner:i,fieldPath:e,handled:!1,uiContext:void 0}:{kind:"missing_expected_data.log",owner:i,fieldPath:e,uiContext:void 0}),this._isMissingData=!0,this._clientEdgeTraversalPath.length){var n=this._clientEdgeTraversalPath[this._clientEdgeTraversalPath.length-1];null!==n&&this._missingClientEdges.push({request:n.readerClientEdge.operation,clientEdgeDestinationID:n.clientEdgeDestinationID})}}},t._traverse=function(e,t,r){var i=this._recordSource.get(t);if(this._seenRecords.add(t),null==i)return void 0===i&&this._markDataAsMissing("<record>"),i;var n=r||{};return this._traverseSelections(e.selections,i,n)?n:null},t._getVariableValue=function(e){return this._variables.hasOwnProperty(e)||k(!1),this._variables[e]},t._maybeReportUnexpectedNull=function(e){if("NONE"!==e.action){var t,r,i,n=this._fragmentName;switch(null==this._fieldErrors&&(this._fieldErrors=[]),t=null!=e.f
1ield.linkedField?null!=(r=e.field.linkedField.alias)?r:e.field.linkedField.name:null!=(i=e.field.alias)?i:e.field.name,e.action){case"THROW":this._fieldErrors.push({kind:"missing_required_field.throw",fieldPath:t,owner:n,handled:!1,uiContext:void 0});return;case"LOG":this._fieldErrors.push({kind:"missing_required_field.log",fieldPath:t,owner:n,uiContext:void 0});return;default:e.action}}},t._handleRequiredFieldValue=function(e,t){return null!=t||(this._maybeReportUnexpectedNull(e),!1)},t._catchErrors=function(e,t,r){var i=e;switch(t){case"RESULT":i=this._asResult(e);break;case"NULL":null!=this._fieldErrors&&this._fieldErrors.length>0&&(i=null)}var n=this._fieldErrors;if(this._fieldErrors=r,null!=n){null==this._fieldErrors&&(this._fieldErrors=[]);for(var s=0;s<n.length;s++)this._fieldErrors.push(L(n[s]))}return i},t._asResult=function(e){return null==this._fieldErrors||0===this._fieldErrors.length?{ok:!0,value:e}:{ok:!1,errors:this._fieldErrors.map(function(e){switch(e.kind){case"relay_field_payload.error":var t=e.error;return t.message,(0,a.default)(t,l);case"missing_expected_data.throw":case"missing_expected_data.log":return{path:e.fieldPath.split(".")};case"relay_resolver.error":return{message:"Relay: Error in resolver for field at ".concat(e.fieldPath," in ").concat(e.owner)};case"missing_required_field.throw":return{message:"Relay: Missing @required value at path '".concat(e.fieldPath,"' in '").concat(e.owner,"'.")};case"missing_required_field.log":return null;default:e.kind,k(!1)}}).filter(Boolean)}},t._traverseSelections=function(e,t,r){for(var i=0;i<e.length;i++){var n=e[i];switch(n.kind){case"RequiredField":var s=this._readClientSideDirectiveField(n,t,r);if(!this._handleRequiredFieldValue(n,s))return!1;break;case"CatchField":var a,o,l,u=this._fieldErrors;this._fieldErrors=null;var c=this._readClientSideDirectiveField(n,t,r),d=null!=(a=null==(o=n.field)?void 0:o.backingField)?a:n.field,h=null!=(l=null==d?void 0:d.alias)?l:null==d?void 0:d.name;null==h&&k(!1),r[h]=this._catchErrors(c,n.to,u);break;case"ScalarField":this._readScalar(n,t,r);break;case"LinkedField":n.plural?this._readPluralLink(n,t,r):this._readLink(n,t,r);break;case"Condition":if(!!this._getVariableValue(n.condition)===n.passingValue&&!this._traverseSelections(n.selections,t,r))return!1;break;case"InlineFragment":if(!1===this._readInlineFragment(n,t,r,!1))return!1;break;case"RelayLiveResolver":case"RelayResolver":this._useExecTimeResolvers?this._readScalar(n,t,r):this._readResolverField(n,t,r);break;case"FragmentSpread":this._createFragmentPointer(n,t,r);break;case"AliasedInlineFragmentSpread":this._readAliasedInlineFragment(n,t,r);break;case"ModuleImport":this._readModuleImport(n,t,r);break;case"InlineDataFragmentSpread":this._createInlineDataOrResolverFragmentPointer(n,t,r);break;case"Defer":case"ClientExtension":var f=this._isMissingData,p=this._missingClientEdges.length;this._clientEdgeTraversalPath.push(null);var g=this._traverseSelections(n.selections,t,r);if(this._isMissingData=f||this._missingClientEdges.length>p||this._missingLiveResolverFields.length>0,this._clientEdgeTraversalPath.pop(),!g)return!1;break;case"Stream":if(!this._traverseSelections(n.selections,t,r))return!1;break;case"ActorChange":this._readActorChange(n,t,r);break;case"ClientEdgeToClientObject":case"ClientEdgeToServerObject":if(this._useExecTimeResolvers&&("RelayResolver"===n.backingField.kind||"RelayLiveResolver"===n.backingField.kind)){var m=n.linkedField;m.plural?this._readPluralLink(m,t,r):this._readLink(m,t,r)}else this._readClientEdge(n,t,r);break;default:k(!1)}}return!0},t._readClientSideDirectiveField=function(e,t,r){switch(e.field.kind){case"ScalarField":return this._readScalar(e.field,t,r);case"LinkedField":if(e.field.plural)return this._readPluralLink(e.field,t,r);return this._readLink(e.field,t,r);case"RelayResolver":case"RelayLiveResolver":if(this._useExecTimeResolvers)return this._readScalar(e.field,t,r);return this._readResolverField(e.field,t,r);case"ClientEdgeToClientObject":case"ClientEdgeToServerObject":if(!this._useExecTimeResolvers||"RelayResolver"!==e.field.backingField.kind&&"RelayLiveResolver"!==e.field.backingField.kind)return this._readClientEdge(e.field,t,r);var i=e.field;if(i.linkedField.plural)return this._readPluralLink(i.linkedField,t,r);return this._readLink(i.linkedField,t,r);case"AliasedInlineFragmentSpread":return this._readAliasedInlineFragment(e.field,t,r);default:e.field.kind,k(!1)}},t._readResolverField=function(e,t,r){var i,n=h.getDataID(t),s=this._fieldErrors;this._fieldErrors=null;var a=this._readResolverFieldImpl(e,n),o=null!=(i=e.alias)?i:e.name;return this._prependPreviousErrors(s,o),r[o]=a,a},t._readResolverFieldImpl=function(e,t){var r,i=this,n=e.fragment,a=function(e){return null!=r?{data:r.data,isMissingData:r.isMissingData,fieldErrors:r.fieldErrors}:{data:(r=C(i._recordSource,e,i._resolverCache)).data,isMissingData:r.isMissingData,fieldErrors:r.fieldErrors}},l=this._resolverCache.readFromCacheOrEvaluate(t,e,this._variables,function(){if(null!=n){var l={__id:t,__fragmentOwner:i._owner,__fragments:(0,s.default)({},n.name,n.args?E(n.args,i._variables):{})};return i._clientEdgeTraversalPath.length>0&&null!==i._clientEdgeTraversalPath[i._clientEdgeTraversalPath.length-1]&&(l[p]=(0,o.default)(i._clientEdgeTraversalPath)),R({getDataForResolverFragment:a},function(){var t=O(e,i._variables,l,i._resolverContext),n=t[0],s=t[1];return{resolverResult:n,snapshot:r,error:s}})}var u=O(e,i._variables,null,i._resolverContext);return{resolverResult:u[0],snapshot:void 0,error:u[1]}},a),u=l[0],c=l[1],d=l[2],h=l[3],f=l[4],g=l[5];return this._propagateResolverMetadata(e.path,h,d,c,f,g),u},t._propagateResolverMetadata=function(e,t,r,i,n,s){var a=this;if(null!=t){if(null!=t.missingClientEdges)for(var o=0;o<t.missingClientEdges.length;o++){var l=t.missingClientEdges[o];this._missingClientEdges.push(l)}if(null!=t.missingLiveResolverFields){this._isMissingData=this._isMissingData||t.missingLiveResolverFields.length>0;for(var u=0;u<t.missingLiveResolverFields.length;u++){var c=t.missingLiveResolverFields[u];this._missingLiveResolverFields.push(c)}}if(null!=t.fieldErrors){null==this._fieldErrors&&(this._fieldErrors=[]);for(var d=0;d<t.fieldErrors.length;d++){var h,f=t.fieldErrors[d];(null==(h=this._selector.node.metadata)?void 0:h.throwOnFieldError)===!0?this._fieldErrors.push(f):this._fieldErrors.push(L(f))}}this._isMissingData=this._isMissingData||t.isMissingData}if(r){var p,g,m={kind:"relay_resolver.error",fieldPath:e,owner:this._fragmentName,error:r,shouldThrow:null!=(p=null==(g=this._selector.node.metadata)?void 0:g.throwOnFieldError)&&p,handled:!1,uiContext:void 0};null==this._fieldErrors?this._fieldErrors=[m]:this._fieldErrors.push(m)}null!=i&&this._seenRecords.add(i),null!=n&&(this._isMissingData=!0,this._missingLiveResolverFields.push(n)),null!=s&&s.forEac
1h(function(e){a._updatedDataIDs.add(e)})},t._readClientEdge=function(e,t,r){var i=this,n=e.backingField;"ClientExtension"===n.kind&&k(!1);var s=null!=(l=n.alias)?l:n.name,a={};this._traverseSelections([n],t,a);var o=a[s];if(null==o||c(o))return r[s]=o,o;if(e.linkedField.plural){Array.isArray(o)||k(!1),"ClientEdgeToClientObject"!==e.kind&&k(!1),u=null==e.backingField.normalizationInfo?o.map(function(t){var r,s=null!=(r=e.concreteType)?r:t.__typename;"string"!=typeof s&&k(!1);var a=P(t,n.path,i._owner.identifier),o=i._resolverCache.ensureClientRecord(a,s),l=e.modelResolvers;if(null!=l){var u=l[s];return void 0===u&&k(!1),null!=i._readResolverFieldImpl(u,o)?o:null}return o}):o.map(function(e){return P(e,n.path,i._owner.identifier)}),this._clientEdgeTraversalPath.push(null);var l,u,d=this._readLinkedIds(e.linkedField,u,t,r);return this._clientEdgeTraversalPath.pop(),r[s]=d,d}var h,f,p,g=P(o,n.path,this._owner.identifier),m=null!=(h=e.concreteType)?h:o.__typename;"ClientEdgeToClientObject"===e.kind?(null==e.backingField.normalizationInfo?("string"!=typeof m&&k(!1),f=this._resolverCache.ensureClientRecord(g,m)):f=g,p=null):(f=g,p={readerClientEdge:e,clientEdgeDestinationID:g});var y=e.modelResolvers;if(null!=y){"string"!=typeof m&&k(!1);var v=y[m];if(void 0===v&&k(!1),null==this._readResolverFieldImpl(v,f))return r[s]=null,null}this._clientEdgeTraversalPath.push(p);var b=r[s];null!=b&&"object"!=typeof b&&k(!1);var _=this._fieldErrors;this._fieldErrors=null;var E=this._traverse(e.linkedField,f,b);return this._prependPreviousErrors(_,s),this._clientEdgeTraversalPath.pop(),r[s]=E,E},t._readScalar=function(e,t,r){var i,n=null!=(i=e.alias)?i:e.name,s=x(e,this._variables),a=h.getValue(t,s);return null===a||u.ENABLE_NONCOMPLIANT_ERROR_HANDLING_ON_LISTS&&Array.isArray(a)&&0===a.length?this._maybeAddFieldErrors(t,s):void 0===a&&this._markDataAsMissing(n),r[n]=a,a},t._readLink=function(e,t,r){var i,n=null!=(i=e.alias)?i:e.name,s=x(e,this._variables),a=h.getLinkedRecordID(t,s);if(null==a)return r[n]=a,null===a?this._maybeAddFieldErrors(t,s):void 0===a&&this._markDataAsMissing(n),a;var o=r[n];null!=o&&"object"!=typeof o&&k(!1);var l=this._fieldErrors;this._fieldErrors=null;var u=this._traverse(e,a,o);return this._prependPreviousErrors(l,n),r[n]=u,u},t._prependPreviousErrors=function(e,t){if(null!=this._fieldErrors){for(var r=0;r<this._fieldErrors.length;r++){var i=this._fieldErrors[r];i.owner===this._fragmentName&&("missing_expected_data.throw"===i.kind||"missing_expected_data.log"===i.kind||"missing_required_field.throw"===i.kind||"missing_required_field.log"===i.kind)&&(i.fieldPath="".concat(t,".").concat(i.fieldPath))}if(null!=e){for(var n=this._fieldErrors.length-1;n>=0;n--)e.push(this._fieldErrors[n]);this._fieldErrors=e}}else this._fieldErrors=e},t._readActorChange=function(e,t,r){var i,n=null!=(i=e.alias)?i:e.name,s=x(e,this._variables),a=h.getActorLinkedRecordID(t,s);if(null==a)return r[n]=a,void 0===a?this._markDataAsMissing(n):null===a&&this._maybeAddFieldErrors(t,s),r[n];var o=a[0],l=a[1],u={};return this._createFragmentPointer(e.fragmentSpread,h.fromObject({__id:l}),u),r[n]={__fragmentRef:u,__viewer:o},r[n]},t._readPluralLink=function(e,t,r){var i=x(e,this._variables),n=h.getLinkedRecordIDs(t,i);return(null===n||u.ENABLE_NONCOMPLIANT_ERROR_HANDLING_ON_LISTS&&Array.isArray(n)&&0===n.length)&&this._maybeAddFieldErrors(t,i),this._readLinkedIds(e,n,t,r)},t._readLinkedIds=function(e,t,r,i){var n,s=this,a=null!=(n=e.alias)?n:e.name;if(null==t)return i[a]=t,void 0===t&&this._markDataAsMissing(a),t;var o=i[a];null==o||Array.isArray(o)||k(!1);var l=this._fieldErrors;this._fieldErrors=null;var u=o||[];return t.forEach(function(t,r){if(null==t){void 0===t&&s._markDataAsMissing(String(r)),u[r]=t;return}var i=u[r];null!=i&&"object"!=typeof i&&k(!1);var n=s._fieldErrors;s._fieldErrors=null,u[r]=s._traverse(e,t,i),s._prependPreviousErrors(n,r)}),this._prependPreviousErrors(l,a),i[a]=u,u},t._readModuleImport=function(e,t,r){var i=S(e.documentName),n=h.getValue(t,i),s=void 0!==n?n:e.componentModuleProvider;if(null==s){void 0===s&&this._markDataAsMissing("<module-import>");return}this._createFragmentPointer({kind:"FragmentSpread",name:e.fragmentName,args:e.args},t,r),r[m]=e.fragmentPropName,r[b]=s},t._readAliasedInlineFragment=function(e,t,r){var i=this._fieldErrors;this._fieldErrors=null;var n=this._readInlineFragment(e.fragment,t,{},!0);this._prependPreviousErrors(i,e.name),!1===n&&(n=null),r[e.name]=n},t._readInlineFragment=function(e,t,r,i){if(null==e.type){var n=this._traverseSelections(e.selections,t,r);return!1!==n&&r}var s=e.abstractKey;if(null==s)if(!this._recordMatchesTypeCondition(t,e.type))return null;else{var n=this._traverseSelections(e.selections,t,r);if(!n)return!1}else{var a=this._implementsInterface(t,s);if(!1===a&&i)return null;var o=this._isMissingData,l=this._isWithinUnmatchedTypeRefinement;this._isWithinUnmatchedTypeRefinement=l||!1===a;var u=this._traverseSelections(e.selections,t,r);if(this._isWithinUnmatchedTypeRefinement=l,!1===a)return this._isMissingData=o,null;if(null==a)return;if(!1===u)return!1}return r},t._recordMatchesTypeCondition=function(e,t){var r=h.getType(e);return null!=r&&r===t||h.getDataID(e)===_},t._createFragmentPointer=function(e,t,r){var i=r[y];null==i&&(i=r[y]={}),("object"!=typeof i||null==i)&&k(!1),null==r[v]&&(r[v]=h.getDataID(t)),i[e.name]=E(e.args,this._variables,this._isWithinUnmatchedTypeRefinement),r[g]=this._owner,this._clientEdgeTraversalPath.length>0&&null!==this._clientEdgeTraversalPath[this._clientEdgeTraversalPath.length-1]&&(r[p]=(0,o.default)(this._clientEdgeTraversalPath))},t._createInlineDataOrResolverFragmentPointer=function(e,t,r){var i=r[y];null==i&&(i=r[y]={}),("object"!=typeof i||null==i)&&k(!1),null==r[v]&&(r[v]=h.getDataID(t));var n={},s=this._fragmentName;this._fragmentName=e.name;var a=this._variables,o=e.args?E(e.args,this._variables):{};this._variables=d.getFragmentVariables(e,this._owner.variables,o),this._traverseSelections(e.selections,t,n),this._variables=a,this._fragmentName=s,i[e.name]=n},t._implementsInterface=function(e,t){var r=h.getType(e),i=this._recordSource.get(I(r)),n=null!=i?h.getValue(i,t):null;return null==n&&this._markDataAsMissing("<abstract-type-hint>"),n},e}();function L(e){switch(e.kind){case"missing_expected_data.throw":case"missing_required_field.throw":case"relay_field_payload.error":case"relay_resolver.error":return(0,n.default)((0,n.default)({},e),{},{handled:!0});case"missing_expected_data.log":case"missing_required_field.log":return e;default:e.kind,k(!1)}}
1function O(e,t,r,i){var n="function"==typeof e.resolverModule?e.resolverModule:e.resolverModule.default,s=null,a=null;try{var o=[];null!=e.fragment&&o.push(r);var l=e.args?E(e.args,t):void 0;o.push(l),o.push(i),s=n.apply(null,o)}catch(e){s=null,e!==A&&(a=e)}return[s,a]}function P(e,t,r){return"string"==typeof e?e:"object"==typeof e&&null!=e&&"string"==typeof e.id?e.id:void k(!1)}t.exports={read:C}},101187,(e,t,r)=>{"use strict";var i=(0,e.r(13451).default)(e.r(877913)),n=e.r(89478),s=e.r(923040),a=e.r(385343),o=e.r(698042).getLocalVariables,l=e.r(789197),u=e.r(765754),c=e.r(638867).generateTypeID,d=e.r(638743),h=u.getReadTimeResolverStorageKey,f=u.getStorageKey,p=u.getModuleOperationKey,g=function(){function e(e,t,r,i,n,s){this._operationLoader=null!=i?i:null,this._operationName=null,this._useExecTimeResolvers=null!=s&&s,this._recordSource=e,this._references=r,this._variables=t,this._shouldProcessClientComponents=n}var t=e.prototype;return t.mark=function(e,t){("Operation"===e.kind||"SplitOperation"===e.kind)&&(this._operationName=e.name),this._traverse(e,t)},t._traverse=function(e,t){this._references.add(t);var r=this._recordSource.get(t);null!=r&&this._traverseSelections(e.selections,r)},t._getVariableValue=function(e){return this._variables.hasOwnProperty(e)||d(!1),this._variables[e]},t._traverseSelections=function(e,t){var r=this;e.forEach(function(i){switch(i.kind){case"ActorChange":r._traverseLink(i.linkedField,t);break;case"LinkedField":i.plural?r._traversePluralLink(i,t):r._traverseLink(i,t);break;case"Condition":!!r._getVariableValue(i.condition)===i.passingValue&&r._traverseSelections(i.selections,t);break;case"InlineFragment":if(null==i.abstractKey){var n=l.getType(t);(null!=n&&n===i.type||n===u.ROOT_TYPE)&&r._traverseSelections(i.selections,t)}else{var a=c(l.getType(t));r._references.add(a),r._traverseSelections(i.selections,t)}break;case"FragmentSpread":var h=r._variables;r._variables=o(r._variables,i.fragment.argumentDefinitions,i.args),r._traverseSelections(i.fragment.selections,t),r._variables=h;break;case"LinkedHandle":var f=s(i,e,r._variables);f.plural?r._traversePluralLink(f,t):r._traverseLink(f,t);break;case"Defer":case"Stream":case"ClientExtension":r._traverseSelections(i.selections,t);break;case"ScalarField":case"ScalarHandle":break;case"TypeDiscriminator":var p=c(l.getType(t));r._references.add(p);break;case"ModuleImport":r._traverseModuleImport(i,t);break;case"ClientComponent":if(!1===r._shouldProcessClientComponents)break;r._traverseSelections(i.fragment.selections,t);break;case"RelayResolver":case"RelayLiveResolver":r._traverseResolverField(i,t);break;case"ClientEdgeToClientObject":r._traverseClientEdgeToClientObject(i,t);break;default:d(!1)}})},t._traverseClientEdgeToClientObject=function(e,t){if(this._useExecTimeResolvers)return void this._traverseLink(e.linkedField,t);var r=this._traverseResolverField(e.backingField,t);if(null!=r){var n=this._recordSource.get(r);if(null!=n)if(e.backingField.isOutputType){var s=a(n);if(null!=s){var o,u=(0,i.default)(s);try{for(u.s();!(o=u.n()).done;){var c=o.value;this._references.add(c)}}catch(e){u.e(e)}finally{u.f()}}}else{var d=e.linkedField,h=d.concreteType;if(null==h)return;if(d.plural){var f=l.getResolverLinkedRecordIDs(n,h);if(null!=f){var p,g=(0,i.default)(f);try{for(g.s();!(p=g.n()).done;){var m=p.value;null!=m&&this._traverse(d,m)}}catch(e){g.e(e)}finally{g.f()}}}else{var y=l.getResolverLinkedRecordID(n,h);null!=y&&this._traverse(d,y)}}}},t._traverseResolverField=function(e,t){if(!this._useExecTimeResolvers){var r=h(e,this._variables),i=l.getLinkedRecordID(t,r);null!=i&&this._references.add(i);var n=e.fragment;return null!=n&&this._traverseSelections([n],t),i}},t._traverseModuleImport=function(e,t){var r=this._operationLoader;null===r&&d(!1);var i=p(e.documentName),s=l.getValue(t,i);if(null!=s){var a=r.get(s);if(null!=a){var u=n(a),c=this._variables;this._variables=o(this._variables,u.argumentDefinitions,e.args),this._traverseSelections(u.selections,t),this._variables=c}}},t._traverseLink=function(e,t){var r=f(e,this._variables),i=l.getLinkedRecordID(t,r);null!=i&&this._traverse(e,i)},t._traversePluralLink=function(e,t){var r=this,i=f(e,this._variables),n=l.getLinkedRecordIDs(t,i);
1null!=n&&n.forEach(function(t){null!=t&&r._traverse(e,t)})},e}();t.exports={mark:function(e,t,r,i,n,s){var a=t.dataID,o=t.node;new g(e,t.variables,r,i,n,s).mark(o,a)}}},705382,(e,t,r)=>{"use strict";var i=Symbol.iterator;t.exports=function(e,t){for(var r=e[i](),n=r.next();!n.done;){var s=n.value;if(t.has(s))return!0;n=r.next()}return!1}},838206,(e,t,r)=>{"use strict";var i=e.r(765754).ROOT_ID,n=e.r(416199).VIEWER_ID,s=Symbol.iterator;t.exports=function(e,t){for(var r=e[s](),a=r.next();!a.done;){var o=a.value;if(t.has(o)&&o!==i&&o!==n)return!0;a=r.next()}return!1}},98390,(e,t,r)=>{"use strict";e.r(215090);var i=e.r(667256),n=e.r(100975),s=e.r(705382),a=e.r(838206),o=e.r(280075);t.exports=function(){function e(e,t,r){this._subscriptions=new Set,this.__log=e,this._resolverCache=t,this._resolverContext=r}var t=e.prototype;return t.subscribe=function(e,t){var r=this,i={backup:null,callback:t,snapshot:e,stale:!1};return this._subscriptions.add(i),{dispose:function(){r._subscriptions.delete(i)}}},t.snapshotSubscriptions=function(e){var t=this;this._subscriptions.forEach(function(r){if(!r.stale){r.backup=r.snapshot;return}var n=r.snapshot,s=o.read(e,n.selector,t._resolverCache,t._resolverContext),a=i(n.data,s.data);s.data=a,r.backup=s})},t.restoreSubscriptions=function(){this._subscriptions.forEach(function(e){var t=e.backup;e.backup=null,t?(t.data!==e.snapshot.data&&(e.stale=!0),e.snapshot={data:e.snapshot.data,isMissingData:t.isMissingData,missingClientEdges:t.missingClientEdges,missingLiveResolverFields:t.missingLiveResolverFields,seenRecords:t.seenRecords,selector:t.selector,fieldErrors:t.fieldErrors}):e.stale=!0})},t.updateSubscriptions=function(e,t,r,i){var n=this,s=0!==t.size;this._subscriptions.forEach(function(a){var o=n._updateSubscription(e,a,t,s,i);null!=o&&r.push(o)})},t._updateSubscription=function(e,t,r,l,u){var c=t.backup,d=t.callback,h=t.snapshot,f=t.stale,p=l&&s(h.seenRecords,r);if(f||p){var g=p||!c?o.read(e,h.selector,this._resolverCache,this._resolverContext):c;if(t.snapshot=g={data:i(h.data,g.data),isMissingData:g.isMissingData,missingClientEdges:g.missingClientEdges,missingLiveResolverFields:g.missingLiveResolverFields,seenRecords:g.seenRecords,selector:g.selector,fieldErrors:g.fieldErrors},t.stale=!1,g.data!==h.data)return this.__log&&n.ENABLE_NOTIFY_SUBSCRIPTION&&this.__log({name:"store.notify.subscription",sourceOperation:u,snapshot:h,nextSnapshot:g}),d(g),h.selector.owner;if(n.ENABLE_LOOSE_SUBSCRIPTION_ATTRIBUTION&&(f||a(h.seenRecords,r)))return h.selector.owner}},t.size=function(){return this._subscriptions.size},e}()},331999,(e,t,r)=>{"use strict";var i=e.r(13451).default,n=i(e.r(877913)),s=i(e.r(514414)),a=e.r(385555),o=a.INTERNAL_ACTOR_IDENTIFIER_DO_NOT_USE,l=a.assertInternalActorIdentifier;e.r(215090);var u=e.r(285489),c=e.r(690636),d=e.r(320766),h=e.r(404062),f=h.LiveResolverCache,p=h.RELAY_RESOLVER_LIVE_STATE_SUBSCRIPTION_KEY,g=h.getUpdatedDataIDs,m=e.r(789197),y=e.r(960708),v=e.r(280075),b=e.r(101187),_=e.r(98390),E=e.r(765754),S=e.r(765754),x=S.ROOT_ID,T=S.ROOT_TYPE,w=e.r(638743);t.exports=function(){function e(e,t){var r,i,n,a,o,l,c,h,p=this;(0,s.default)(this,"_gcStep",function(){p._gcRun&&(p._gcRun.next().done?p._gcRun=null:p._gcScheduler(p._gcStep))}),this._currentWriteEpoch=0,this._gcHoldCounter=0,this._gcReleaseBufferSize=null!=(r=null==t?void 0:t.gcReleaseBufferSize)?r:10,this._shouldRetainWithinTTL_EXPERIMENTAL=null!=(i=null==t?void 0:t.shouldRetainWithinTTL_EXPERIMENTAL)&&i,this._gcRun=null,this._gcScheduler=null!=(n=null==t?void 0:t.gcScheduler)?n:u,this._getDataID=null!=(a=null==t?void 0:t.getDataID)?a:d,this._globalInvalidationEpoch=null,this._invalidationSubscriptions=new Set,this._invalidatedRecordIDs=new Set,this.__log=null!=(o=null==t?void 0:t.log)?o:null,this._queryCacheExpirationTime=null==t?void 0:t.queryCacheExpirationTime,this._operationLoader=null!=(l=null==t?void 0:t.operationLoader)?l:null,this._optimisticSource=null,this._recordSource=e,this._releaseBuffer=[],this._roots=new Map,this._shouldScheduleGC=!1,this._resolverCache=new f(function(){return p._getMutableRecordSource()},this),this._resolverContext=null==t?void 0:t.resolverContext,this._storeSubscriptions=new _(null==t?void 0:t.log,this._resolverCache,this._resolverContext),this._updatedRecordIDs=new Set,this._shouldProcessClientComponents=null!=(c=null==t?void 0:t.shouldProcessClientComponents)&&c,this._treatMissingFieldsAsNull=null!=(h=null==t?void 0:t.treatMissingFieldsAsNull)&&h,this._actorIdentifier=null==t?void 0:t.actorIdentifier,function(e){if(!e.has(x)){var t=m.create(x,T);
1e.set(x,t)}}(this._recordSource)}var t=e.prototype;return t.getSource=function(){var e;return null!=(e=this._optimisticSource)?e:this._recordSource},t.getOperationLoader=function(){return this._operationLoader},t._getMutableRecordSource=function(){var e;return null!=(e=this._optimisticSource)?e:this._recordSource},t.getLiveResolverPromise=function(e){return this._resolverCache.getLiveResolverPromise(e)},t.batchLiveStateUpdates=function(e){null!=this.__log&&this.__log({name:"liveresolver.batch.start"});try{this._resolverCache.batchLiveStateUpdates(e)}finally{null!=this.__log&&this.__log({name:"liveresolver.batch.end"})}},t.check=function(e,t){var r,i,n,s,a,u,d,h,f,p,g,m,y,v=e.root,b=this._getMutableRecordSource(),_=this._globalInvalidationEpoch,E=null!=(d=null!=(h=e.request.node.operation.use_exec_time_resolvers)?h:(null==(f=e.request.node.operation.exec_time_resolvers_enabled_provider)?void 0:f.get())===!0)&&d,S=this._roots.get(e.request.identifier),x=null!=S?S.epoch:null;if(null!=_&&(null==x||x<=_))return{status:"stale"};var T=null!=(p=null==t?void 0:t.handlers)?p:[],w=null!=(g=null==t?void 0:t.getSourceForActor)?g:function(e){return l(e),b},A=null!=(m=null==t?void 0:t.getTargetForActor)?m:function(e){return l(e),b};return r=c.check(w,A,null!=(y=null==t?void 0:t.defaultActorIdentifier)?y:o,v,T,this._operationLoader,this._getDataID,this._shouldProcessClientComponents,this.__log,E),i=x,n=null==S?void 0:S.fetchTime,s=this._queryCacheExpirationTime,a=r.mostRecentlyInvalidatedAt,u=r.status,"number"==typeof a&&(null==i||a>i)?{status:"stale"}:"missing"===u?{status:"missing"}:null!=n&&null!=s&&n<=Date.now()-s?{status:"stale"}:{status:"available",fetchTime:null!=n?n:null}},t.retain=function(e){var t=this,r=e.request.identifier,i=!1,n=this._roots.get(r);return null!=n?(0===n.refCount&&(this._releaseBuffer=this._releaseBuffer.filter(function(e){return e!==r})),n.refCount+=1):this._roots.set(r,{operation:e,refCount:1,epoch:null,fetchTime:null}),{dispose:function(){if(!i){i=!0;var e=t._roots.get(r);if(null!=e&&(e.refCount--,0===e.refCount)){var n=t._queryCacheExpirationTime;if(null!=e.fetchTime&&null!=n&&e.fetchTime<=Date.now()-n)t._shouldRetainWithinTTL_EXPERIMENTAL||t._roots.delete(r),t.scheduleGC();else if(t._releaseBuffer.push(r),t._releaseBuffer.length>t._gcReleaseBufferSize){var s=t._releaseBuffer.shift();t._shouldRetainWithinTTL_EXPERIMENTAL||t._roots.delete(s),t.scheduleGC()}}}}}},t.lookup=function(e){var t=this.__log;null!=t&&t({name:"store.lookup.start",selector:e});var r=this.getSource(),i=v.read(r,e,this._resolverCache,this._resolverContext);return null!=t&&t({name:"store.lookup.end",selector:e}),i},t.notify=function(e,t){var r=this,i=this.__log;null!=i&&i({name:"store.notify.start",sourceOperation:e}),this._currentWriteEpoch++,!0===t&&(this._globalInvalidationEpoch=this._currentWriteEpoch),this._resolverCache.invalidateDataIDs(this._updatedRecordIDs);var n=this.getSource(),s=[];if(this._storeSubscriptions.updateSubscriptions(n,this._updatedRecordIDs,s,e),this._invalidationSubscriptions.forEach(function(e){r._updateInvalidationSubscription(e,!0===t)}),null!=e){var a=e.request.identifier,o=this._roots.get(a);if(null!=o)o.epoch=this._currentWriteEpoch,o.fetchTime=Date.now();else if("query"===e.request.node.params.operationKind&&this._gcReleaseBufferSize>0&&this._releaseBuffer.length<this._gcReleaseBufferSize){var l={operation:e,refCount:0,epoch:this._currentWriteEpoch,fetchTime:Date.now()};this._releaseBuffer.push(a),this._roots.set(a,l)}}return null!=i&&i({name:"store.notify.complete",sourceOperation:e,updatedRecordIDs:this._updatedRecordIDs,invalidatedRecordIDs:this._invalidatedRecordIDs,subscriptionsSize:this._storeSubscriptions.size(),updatedOwners:s}),this._updatedRecordIDs.clear(),this._invalidatedRecordIDs.clear(),s},t.publish=function(e,t){var r=this._getMutableRecordSource();!function(e,t,r,i,n,s){i&&i.forEach(function(i){var n,a=e.get(i),o=t.get(i);null===o||(n=null!=a?m.clone(a):null!=o?m.clone(o):null)&&(m.setValue(n,E.INVALIDATED_AT_KEY,r),s.add(i),e.set(i,n))});for(var a=t.getRecordIDs(),o=0;o<a.length;o++){var l=a[o],u=t.get(l),c=e.get(l);if(u&&c){var d=m.update(c,u);d!==c&&(n.add(l),e.set(l,d))}else null===u?(e.delete(l),null!==c&&n.add(l)):u&&(e.set(l,u),n.add(l))}}(r,e,this._currentWriteEpoch+1,t,this._updatedRecordIDs,this._invalidatedRecordIDs);var i=this.__log;null!=i&&i({name:"store.publish",source:e,optimistic:r===this._optimisticSource})},t.subscribe=function(e,t){return this._storeSubscriptions.subscribe(e,t)},t.holdGC=function(){var e=this;return this._gcRun&&(this._gcRun=null,this._shouldScheduleGC=!0),this._gcHoldCounter++,{dispose:function(){e._gcHoldCounter>0&&(e._gcHoldCounter--,0===e._gcHoldCounter&&e._shouldScheduleGC&&(e.scheduleGC(),e._shouldScheduleGC=!1))}}},t.toJSON=function(){return"RelayModernStore()"},t.getEpoch=function(){return this._currentWriteEpoch}
1,t.__getUpdatedRecordIDs=function(){return this._updatedRecordIDs},t.lookupInvalidationState=function(e){var t=this,r=new Map;return e.forEach(function(e){var i,n=t.getSource().get(e);r.set(e,null!=(i=m.getInvalidationEpoch(n))?i:null)}),r.set("global",this._globalInvalidationEpoch),{dataIDs:e,invalidations:r}},t.checkInvalidationState=function(e){var t=this.lookupInvalidationState(e.dataIDs).invalidations,r=e.invalidations;if(t.get("global")!==r.get("global"))return!0;var i,s=(0,n.default)(e.dataIDs);try{for(s.s();!(i=s.n()).done;){var a=i.value;if(t.get(a)!==r.get(a))return!0}}catch(e){s.e(e)}finally{s.f()}return!1},t.subscribeToInvalidationState=function(e,t){var r=this,i={callback:t,invalidationState:e};return this._invalidationSubscriptions.add(i),{dispose:function(){r._invalidationSubscriptions.delete(i)}}},t._updateInvalidationSubscription=function(e,t){var r=this,i=e.callback,n=e.invalidationState.dataIDs;(t||n.some(function(e){return r._invalidatedRecordIDs.has(e)}))&&i()},t.snapshot=function(){null!=this._optimisticSource&&w(!1);var e=this.__log;null!=e&&e({name:"store.snapshot"}),this._storeSubscriptions.snapshotSubscriptions(this.getSource()),this._gcRun&&(this._gcRun=null,this._shouldScheduleGC=!0),this._optimisticSource=y.create(this.getSource())},t.restore=function(){var e=this._optimisticSource;e||w(!1);var t=this.__log;null!=t&&t({name:"store.restore"});var r=y.getOptimisticRecordIDs(e);this._resolverCache.unsubscribeFromLiveResolverRecords(r),this._optimisticSource=null,this._shouldScheduleGC&&this.scheduleGC(),this._storeSubscriptions.restoreSubscriptions(),this._resolverCache.invalidateResolverRecords(r)},t.scheduleGC=function(){if(this._gcHoldCounter>0){this._shouldScheduleGC=!0;return}this._gcRun||(this._gcRun=this._collect(),this._gcScheduler(this._gcStep))},t.__gc=function(){if(null==this._optimisticSource)for(var e=this._collect();!e.next().done;);},t._collect=function*(){if(!this._shouldRetainWithinTTL_EXPERIMENTAL||null!=this._queryCacheExpirationTime){var e=this.__log;e:for(;;){null!=e&&e({name:"store.gc.start"});var t,r=this._currentWriteEpoch,i=new Set,s=(0,n.default)(this._roots.entries());try{for(s.s();!(t=s.n()).done;){var a,o,l,u=t.value,c=u[0],d=u[1],h=d.operation,f=d.refCount,g=d.fetchTime;if(this._shouldRetainWithinTTL_EXPERIMENTAL){var y=this._queryCacheExpirationTime;if(null==y&&w(!1),(null==g||g<=Date.now()-y)&&0===f&&!this._releaseBuffer.includes(c))continue}var v=h.root,_=null!=(a=null!=(o=h.request.node.operation.use_exec_time_resolvers)?o:(null==(l=h.request.node.operation.exec_time_resolvers_enabled_provider)?void 0:l.get())===!0)&&a;if(b.mark(this._recordSource,v,i,this._operationLoader,this._shouldProcessClientComponents,_),yield,r!==this._currentWriteEpoch){null!=e&&e({name:"store.gc.interrupted"});continue e}}}catch(e){s.e(e)}finally{s.f()}for(var E=this._recordSource.getRecordIDs(),S=0;S<E.length;S++){var x=E[S];if(!i.has(x)){var T=this._recordSource.get(x);if(null!=T){var A=m.getValue(T,p);null!=A&&A()}this._recordSource.remove(x),this._shouldRetainWithinTTL_EXPERIMENTAL&&this._roots.delete(x)}}null!=e&&e({name:"store.gc.end",references:i});return}}},t.__getNormalizationOptions=function(e){return{path:e,getDataID:this._getDataID,log:this.__log,treatMissingFieldsAsNull:this._treatMissingFieldsAsNull,shouldProcessClientComponents:this._shouldProcessClientComponents,actorIdentifier:this._actorIdentifier}},t.__notifyUpdatedSubscribers=function(e){var t=g(e),r=this._updatedRecordIDs;this._updatedRecordIDs=t,this.notify(),this._updatedRecordIDs=r},e}()},937759,(e,t,r)=>{"use strict";var i=e.r(765754),n=i.ROOT_TYPE,s=i.getStorageKey,a=e.r(331104).readUpdatableFragment,o=e.r(842996).readUpdatableQuery,l=e.r(638743);t.exports=function(){function e(e,t,r,i){this.__mutator=e,this.__recordSource=t,this._readSelector=r,this._missingFieldHandlers=i}var t=e.prototype;return t.create=function(e,t){return this.__recordSource.create(e,t)},t.delete=function(e){this.__recordSource.delete(e)},t.get=function(e){return this.__recordSource.get(e)},t.getRoot=function(){return this.__recordSource.getRoot()},t.getOperationRoot=function(){var e=this.__recordSource.get(this._readSelector.dataID);return e||(e=this.__recordSource.create(this._readSelector.dataID,n)),e},t._getRootField=function(e,t,r){var i=e.node.selections.find(function(e){return"LinkedField"===e.kind&&e.name===t||"RequiredField"===e.kind&&e.field.name===t});return i&&"RequiredField"===i.kind&&(i=i.field),i&&"LinkedField"===i.kind||l(!1),i.plural!==r&&l(!1),i},t.getRootField=function(e){var t=s(this._getRootField(this._readSelector,e,!1),this._readSelector.variables);return this.getOperationRoot().getLinkedRecord(t)},t.getPluralRootField=function(e){var t=s(this._getRootField(this._readSelector,e,!0),this._readSelector.variables);return this.getOperationRoot().getLinkedRecords(t)},t.invalidateStore=function(){this.__recordSource.invalidateStore(
1)},t.readUpdatableQuery=function(e,t){return o(e,t,this,this._missingFieldHandlers)},t.readUpdatableFragment=function(e,t){return a(e,t,this,this._missingFieldHandlers)},e}()},719963,(e,t,r)=>{"use strict";var i,n,s=e.r(269770),a=e.r(479576),o=e.r(937759),l=e.r(100975),u=e.r(280075),c=e.r(244209),d=e.r(638743);e.r(603158);var h=e.g,f=null!=(i=null==h||null==(n=h.ErrorUtils)?void 0:n.applyWithGuard)?i:function(e,t,r,i,n){return e.apply(t,r)};function p(e,t){return u.read(e,t).data}t.exports=function(){function e(e,t,r,i,n){this._hasStoreSnapshot=!1,this._handlerProvider=t||null,this._pendingBackupRebase=!1,this._pendingData=new Set,this._pendingOptimisticUpdates=new Set,this._store=e,this._appliedOptimisticUpdates=new Set,this._gcHold=null,this._getDataID=r,this._missingFieldHandlers=i,this._log=n}var t=e.prototype;return t.applyUpdate=function(e){(this._appliedOptimisticUpdates.has(e)||this._pendingOptimisticUpdates.has(e))&&d(!1),this._pendingOptimisticUpdates.add(e)},t.revertUpdate=function(e){this._pendingOptimisticUpdates.has(e)?this._pendingOptimisticUpdates.delete(e):this._appliedOptimisticUpdates.has(e)&&(this._pendingBackupRebase=!0,this._appliedOptimisticUpdates.delete(e))},t.revertAll=function(){this._pendingBackupRebase=!0,this._pendingOptimisticUpdates.clear(),this._appliedOptimisticUpdates.clear()},t.commitPayload=function(e,t,r){this._pendingBackupRebase=!0,this._pendingData.add({kind:"payload",operation:e,payload:t,updater:r})},t.commitUpdate=function(e){this._pendingBackupRebase=!0,this._pendingData.add({kind:"updater",updater:e})},t.commitSource=function(e){this._pendingBackupRebase=!0,this._pendingData.add({kind:"source",source:e})},t.run=function(e){var t=0===this._appliedOptimisticUpdates&&!!this._gcHold,r=!this._pendingBackupRebase&&0===this._pendingOptimisticUpdates.size&&!t;if(l.DISALLOW_NESTED_UPDATES&&!0===this._isRunning&&d(!1),this._isRunning=!0,r)return this._isRunning=!1,[];this._pendingBackupRebase&&this._hasStoreSnapshot&&(this._store.restore(),this._hasStoreSnapshot=!1);var i=this._commitData();return(this._pendingOptimisticUpdates.size||this._pendingBackupRebase&&this._appliedOptimisticUpdates.size)&&(this._hasStoreSnapshot||(this._store.snapshot(),this._hasStoreSnapshot=!0),this._applyUpdates()),this._pendingBackupRebase=!1,this._appliedOptimisticUpdates.size>0?this._gcHold||(this._gcHold=this._store.holdGC()):this._gcHold&&(this._gcHold.dispose(),this._gcHold=null),this._isRunning=!1,this._store.notify(e,i)},t._publishSourceFromPayload=function(e){var t=this,r=e.payload,i=e.operation,n=e.updater,l=r.source,u=r.fieldPayloads,c=new s(this._store.getSource(),l),h=new a(c,this._getDataID,this._handlerProvider,this._missingFieldHandlers,this._log);if(u&&u.length&&u.forEach(function(e){var r=t._handlerProvider&&t._handlerProvider(e.handle);r||d(!1),r.update(h,e)}),n){var f=i.fragment;null==f&&d(!1),n(new o(c,h,f,this._missingFieldHandlers),p(l,f))}var g=h.getIDsMarkedForInvalidation();return this._store.publish(l,g),h.isStoreMarkedForInvalidation()},t._commitData=function(){var e=this;if(!this._pendingData.size)return!1;var t=!1;return this._pendingData.forEach(function(r){if("payload"===r.kind){var i=e._publishSourceFromPayload(r);t=t||i}else if("source"===r.kind){var n=r.source;e._store.publish(n)}else{var o=r.updater,l=c.create(),u=new a(new s(e._store.getSource(),l),e._getDataID,e._handlerProvider,e._missingFieldHandlers,e._log);f(o,null,[u],null,"RelayPublishQueue:commitData"),t=t||u.isStoreMarkedForInvalidation();var d=u.getIDsMarkedForInvalidation();e._store.publish(l,d)}}),this._pendingData.clear(),t},t._applyUpdates=function(){var e=this,t=c.create(),r=new s(this._store.getSource(),t),i=new a(r,this._getDataID,this._handlerProvider,this._missingFieldHandlers,this._log),n=function(t){if(t.storeUpdater)f(t.storeUpdater,null,[i],null,"RelayPublishQueue:applyUpdates");else{var n,s=t.operation,a=t.payload,l=t.updater,u=a.source,c=a.fieldPayloads;u&&i.publishSource(u,c),l&&(u&&(n=p(u,s.fragment)),f(l,null,[new o(r,i,s.fragment,e._missingFieldHandlers),n],null,"RelayPublishQueue:applyUpdates"))}};this._pendingBackupRebase&&this._appliedOptimisticUpdates.size&&this._appliedOptimisticUpdates.forEac
1h(n),this._pendingOptimisticUpdates.size&&(this._pendingOptimisticUpdates.forEach(function(t){n(t),e._appliedOptimisticUpdates.add(t)}),this._pendingOptimisticUpdates.clear()),this._store.publish(t)},e}()},565658,(e,t,r)=>{"use strict";var i=(0,e.r(13451).default)(e.r(802953)),n=e.r(844195),s=e.r(385555),a=s.INTERNAL_ACTOR_IDENTIFIER_DO_NOT_USE,o=s.assertInternalActorIdentifier,l=e.r(152076),u=e.r(273273),c=e.r(297501),d=e.r(181968),h=e.r(320766),f=e.r(736260),p=e.r(193576),g=e.r(939908),m=e.r(331999),y=e.r(719963),v=e.r(244209);e.r(638743);var b=function(){function e(e){var t,r,i,s,a,o,l,g,b,E,S,x=this;this.configName=e.configName,this._treatMissingFieldsAsNull=!0===e.treatMissingFieldsAsNull;var T=e.operationLoader,w=null!=(t=e.store)?t:new m(new v,{log:e.log,operationLoader:e.operationLoader,getDataID:e.getDataID,shouldProcessClientComponents:e.shouldProcessClientComponents});this.__log=null!=(r=e.log)?r:_,this.relayFieldLogger=null!=(i=e.relayFieldLogger)?i:f,this._defaultRenderPolicy=null!=(s=e.UNSTABLE_defaultRenderPolicy)?s:"partial",this._operationLoader=T,this._operationExecutions=new Map,this._network=u(this,e.network),this._getDataID=null!=(a=e.getDataID)?a:h,this._missingFieldHandlers=null!=(o=e.missingFieldHandlers)?o:[],this._publishQueue=new y(w,null!=(l=e.handlerProvider)?l:n,this._getDataID,this._missingFieldHandlers,this.__log),this._scheduler=null!=(g=e.scheduler)?g:null,this._store=w,this.options=e.options,this._isServer=null!=(b=e.isServer)&&b,this._normalizeResponse=null!=(E=e.normalizeResponse)?E:p,this.__setNet=function(e){return x._network=u(x,e)},this._operationTracker=null!=(S=e.operationTracker)?S:new c,this._shouldProcessClientComponents=e.shouldProcessClientComponents,d(this)}var t=e.prototype;return t.getStore=function(){return this._store},t.getNetwork=function(){return this._network},t.getOperationTracker=function(){return this._operationTracker},t.getScheduler=function(){return this._scheduler},t.isRequestActive=function(e){return"active"===this._operationExecutions.get(e)},t.UNSTABLE_getDefaultRenderPolicy=function(){return this._defaultRenderPolicy},t.applyUpdate=function(e){var t=this;return this._scheduleUpdates(function(){t._publishQueue.applyUpdate(e),t._publishQueue.run()}),{dispose:function(){t._scheduleUpdates(function(){t._publishQueue.revertUpdate(e),t._publishQueue.run()})}}},t.revertUpdate=function(e){var t=this;this._scheduleUpdates(function(){t._publishQueue.revertUpdate(e),t._publishQueue.run()})},t.replaceUpdate=function(e,t){var r=this;this._scheduleUpdates(function(){r._publishQueue.revertUpdate(e),r._publishQueue.applyUpdate(t),r._publishQueue.run()})},t.applyMutation=function(e){var t=this._execute({createSource:function(){return l.create(function(e){})},isClientPayload:!1,operation:e.operation,optimisticConfig:e,updater:null}).subscribe({});return{dispose:function(){return t.unsubscribe()}}},t.check=function(e){var t;return 0===this._missingFieldHandlers.length&&("Operation"!==(t=e).root.node.kind||null==t.root.node.clientAbstractTypes)?this._store.check(e):this._checkSelectorAndHandleMissingFields(e,this._missingFieldHandlers)},t.commitPayload=function(e,t){this._execute({createSource:function(){return l.from({data:t})},isClientPayload:!0,operation:e,optimisticConfig:null,updater:null}).subscribe({})},t.commitUpdate=function(e){var t=this;this._scheduleUpdates(function(){t._publishQueue.commitUpdate(e),t._publishQueue.run()})},t.lookup=function(e){return this._store.lookup(e)},t.subscribe=function(e,t){return this._store.subscribe(e,t)},t.retain=function(e){return this._store.retain(e)},t.isServer=function(){return this._isServer},t._checkSelectorAndHandleMissingFields=function(e,t){var r=this,i=v.create(),n=this._store.getSource(),s=this._store.check(e,{handlers:t,defaultActorIdentifier:a,getSourceForActor:function(e){return o(e),n},getTargetForActor:function(e){return o(e),i}});return i.size()>0&&this._scheduleUpdates(function(){r._publishQueue.commitSource(i),r._publishQueue.run()}),s},t._scheduleUpdates=function(e){var t=this._scheduler;null!=t?t.schedule(e):e()},t.execute=function(e){var t=this,r=e.operation;return this._execute({createSource:function(){return t.getNetwork().execute(r.request.node.params,r.request.variables,r.request.cacheConfig||{},null,void 0,void 0,void 0,function(){return t.check(r)})},isClientPayload:!1,operation:r,optimisticConfig:null,updater:null})},t.executeSubscription=function(e){var t=this,r=e.operation,i=e.updater;return this._execute({createSource:function(){return t.getNetwork().execute(r.request.node.params,r.request.variables,r.request.cacheConfig||{},null)}
1,isClientPayload:!1,operation:r,optimisticConfig:null,updater:i})},t.executeMutation=function(e){var t,r=this,n=e.operation,s=e.optimisticResponse,a=e.optimisticUpdater,o=e.updater,l=e.uploadables;return(s||a)&&(t={operation:n,response:s,updater:a}),this._execute({createSource:function(){return r.getNetwork().execute(n.request.node.params,n.request.variables,(0,i.default)((0,i.default)({},n.request.cacheConfig),{},{force:!0}),l)},isClientPayload:!1,operation:n,optimisticConfig:t,updater:o})},t.executeWithSource=function(e){var t=e.operation,r=e.source;return this._execute({createSource:function(){return r},isClientPayload:!1,operation:t,optimisticConfig:null,updater:null})},t.toJSON=function(){var e;return"RelayModernEnvironment(".concat(null!=(e=this.configName)?e:"",")")},t._execute=function(e){var t=this,r=e.createSource,i=e.isClientPayload,n=e.operation,s=e.optimisticConfig,u=e.updater,c=this._publishQueue,d=this._store;return l.create(function(e){var l=g.execute({actorIdentifier:a,getDataID:t._getDataID,isClientPayload:i,log:t.__log,operation:n,operationExecutions:t._operationExecutions,operationLoader:t._operationLoader,operationTracker:t._operationTracker,optimisticConfig:s,getPublishQueue:function(e){return o(e),c},scheduler:t._scheduler,shouldProcessClientComponents:t._shouldProcessClientComponents,sink:e,source:r(),getStore:function(e){return o(e),d},treatMissingFieldsAsNull:t._treatMissingFieldsAsNull,updater:u,normalizeResponse:t._normalizeResponse});return function(){return l.cancel()}})},e}();function _(){}b.prototype["@@RelayModernEnvironment"]=!0,t.exports=b},766960,(e,t,r)=>{"use strict";var i=e.r(265876),n=e.r(930649).getRequest,s=e.r(525999).createOperationDescriptor,a=e.r(461055).createReaderSelector;e.r(603158),t.exports=function(e,t){var r=n(t.subscription);if("subscription"!==r.params.operationKind)throw Error("requestSubscription: Must use Subscription operation");var o=t.configs,l=t.onCompleted,u=t.onError,c=t.onNext,d=s(r,t.variables,t.cacheConfig),h=(o?i.convert(o,r,null,t.updater):t).updater;return{dispose:e.executeSubscription({operation:d,updater:h}).subscribe({next:function(t){if(null!=c){var r,i,n,s,o=d.fragment;"string"==typeof(r=Array.isArray(t)?null==(i=t[0])||null==(n=i.extensions)?void 0:n.__relay_subscription_root_id:null==(s=t.extensions)?void 0:s.__relay_subscription_root_id)&&(o=a(o.node,r,o.variables,o.owner)),c(e.lookup(o).data)}},error:u,complete:l}).unsubscribe}}},319581,(e,t,r)=>{"use strict";var i=(0,e.r(13451).default)(e.r(802953)),n=e.r(765754),s=n.getModuleComponentKey,a=n.getModuleOperationKey;t.exports=function(e,t,r,n){var o=(0,i.default)({},n);return o[s(e)]=r,o[a(e)]=t,o}},61022,(e,t,r)=>{"use strict";var i=Object.prototype.hasOwnProperty;t.exports=function(e){for(var t in e)if(i.call(e,t))return!1;return!0}},479154,(e,t,r)=>{"use strict";var i=e.r(461055),n=i.getDataIDsFromFragment,s=i.getSelector,a=i.getVariablesFromFragment,o=e.r(61022),l=e.r(100975),u=e.r(652230).stableCopy,c=e.r(875053).intern;t.exports=function(e,t){var r=s(e,t),i=null==r?"null":"SingularReaderSelector"===r.kind?r.owner.identifier:"["+r.selectors.map(function(e){return e.owner.identifier}).join(",")+"]",d=a(e,t),h=n(e,t);if(l.ENABLE_GETFRAGMENTIDENTIFIER_OPTIMIZATION){var f=void 0===h?"missing":null==h?"null":Array.isArray(h)?"["+h.join(",")+"]":h;return f=l.STRING_INTERN_LEVEL<=1?f:c(f,l.MAX_DATA_ID_LENGTH),i+"/"+e.name+"/"+(null==d||o(d)?"{}":JSON.stringify(u(d)))+"/"+f}var p,g=null!=(p=JSON.stringify(h))?p:"missing";return g=l.STRING_INTERN_LEVEL<=1?g:c(g,l.MAX_DATA_ID_LENGTH),i+"/"+e.name+"/"+JSON.stringify(u(d))+"/"+g}},127896,(e,t,r)=>{"use strict";var i=e.r(638743);t.exports=function(e,t){(null==(r=e.metadata)?void 0:r.plural)===!0&&i(!1);var r,n,s=null==(n=e.metadata)?void 0:n.refetch;null==s&&i(!1);var a=s.operation.default?s.operation.default:s.operation,o=s.fragmentPathInResult;"string"==typeof a&&i(!1);var l=s.identifierInfo;return null!=l&&(null!=l.identifierField&&"string"!=typeof l.identifierField&&i(!1),null!=l.identifierQueryVariableName&&"string"!=typeof l.identifierQueryVariableName&&i(!1)),{fragmentRefPathInResponse:o,identifierInfo:l,refetchableRequest:a,refetchMetadata:s}}},216805,(e,t,r)=>{"use strict";var i=e.r(127896),n=e.r(638743);t.exports=function(e,t){var r,s,a=i(e,t),o=a.refetchableRequest,l=a.refetchMetadata,u=l.connection;null==u&&n(!1);var c=u.path,d=(null!=(r=null==(s=e.metadata)?void 0:s.connection)?r:[])[0];null==d&&n(!1);var h=l.identifierInfo;return(null==h?void 0:h.identifierField)!=null&&"string"!=typeof h.identifierField&&n(!1),{connectionPathInFragmentData:c,identifierField:null==h?void 0:h.identifierField,paginationRequest:o,paginationMetadata:u,stream:!0===d.stream}}},235550,(e,t,r)=>{"use strict";var i=e.r(13451).default,n=i(e.r(514414)),s=i(e.r(802953)),a=e.r(638743);e.r(603158),t.exports=function(e,t,r,i,o,l){var u=l.backward,c=l.forward;
1if("backward"===e){(null==u||null==u.count||null==u.cursor)&&a(!1);var d,h,f=(0,s.default)((0,s.default)((0,s.default)({},i),o),{},(h={},(0,n.default)(h,u.cursor,r),(0,n.default)(h,u.count,t),h));return c&&c.cursor&&(f[c.cursor]=null),c&&c.count&&(f[c.count]=null),f}(null==c||null==c.count||null==c.cursor)&&a(!1);var p=(0,s.default)((0,s.default)((0,s.default)({},i),o),{},(d={},(0,n.default)(d,c.cursor,r),(0,n.default)(d,c.count,t),d));return u&&u.cursor&&(p[u.cursor]=null),u&&u.count&&(p[u.count]=null),p}},691738,(e,t,r)=>{"use strict";var i=(0,e.r(13451).default)(e.r(877913)),n=e.r(638743);t.exports=function(e,t){var r,s=e,a=(0,i.default)(t);try{for(a.s();!(r=a.n()).done;){var o=r.value;if(null==s)return null;"number"==typeof o?Array.isArray(s)||n(!1):("object"!=typeof s||Array.isArray(s))&&n(!1),s=s[o]}}catch(e){a.e(e)}finally{a.f()}return s}},318071,(e,t,r)=>{"use strict";var i={},n={stop:function(){}};t.exports={profile:function(e,t){var r=i[e];if(r&&r.length>0){for(var s=[],a=r.length-1;a>=0;a--){var o=r[a](e,t);s.unshift(o)}return{stop:function(e){s.forEach(function(t){return t(e)})}}}return n},attachProfileHandler:function(e,t){i.hasOwnProperty(e)||(i[e]=[]),i[e].push(t)},detachProfileHandler:function(e,t){var r,n,s;i.hasOwnProperty(e)&&(r=i[e],n=t,-1!==(s=r.indexOf(n))&&r.splice(s,1))}}},100545,(e,t,r)=>{"use strict";var i=e.r(385323),n=i.isErrorResult,s=i.isValueResult,a=e.r(347440),o=e.r(277620),l=e.r(306867),u=e.r(844195),c=e.r(295870),d=e.r(213576),h=e.r(726516),f=e.r(265876),p=e.r(879580),g=e.r(152076),m=e.r(356030),y=e.r(172850),v=e.r(950298),b=e.r(558392),_=e.r(930649),E=e.r(279767),S=e.r(883316),x=S.generateClientID,T=S.generateUniqueClientID,w=S.isClientID,A=e.r(267199),R=e.r(702108),I=e.r(181758),k=e.r(661691),C=e.r(824461),D=C.isSuspenseSentinel,L=C.suspenseSentinel,O=e.r(193576),P=e.r(963805),F=e.r(698042),N=e.r(565658),M=e.r(525999),j=e.r(789197),$=e.r(461055),U=e.r(331999),B=e.r(297501),V=e.r(244209),G=e.r(765754),q=e.r(50219),H=e.r(416199),z=e.r(766960),K=e.r(319581),W=e.r(215090),Y=e.r(479154),Q=e.r(216805),X=e.r(235550),J=e.r(295556),Z=e.r(127896),ee=e.r(880432),et=e.r(596916),er=e.r(691738),ei=e.r(345490).handlePotentialSnapshotErrors,en=e.r(680223),es=e.r(986480),ea=e.r(667256),eo=e.r(710273),el=e.r(900336),eu=e.r(265025),ec=e.r(100975),ed=e.r(318071),eh=e.r(968259),ef=e.r(652230),ep=ef.hasCycle,eg=ef.stableCopy,em=e.r(760262);t.exports={Environment:N,Network:p,Observable:g,QueryResponseCache:m,RecordSource:V,Record:j,ReplaySubject:eh,Store:U,areEqualSelectors:$.areEqualSelectors,createFragmentSpecResolver:A,createNormalizationSelector:$.createNormalizationSelector,createOperationDescriptor:M.createOperationDescriptor,createReaderSelector:$.createReaderSelector,createRequestDescriptor:M.createRequestDescriptor,getArgumentValues:G.getArgumentValues,getDataIDsFromFragment:$.getDataIDsFromFragment,getDataIDsFromObject:$.getDataIDsFromObject,getNode:_.getNode,getFragment:_.getFragment,getInlineDataFragment:_.getInlineDataFragment,getModuleComponentKey:G.getModuleComponentKey,getModuleOperationKey:G.getModuleOperationKey,getPaginationFragment:_.getPaginationFragment,getPluralSelector:$.getPluralSelector,getRefetchableFragment:_.getRefetchableFragment,getRequest:_.getRequest,getRequestIdentifier:et,getSelector:$.getSelector,getSelectorsFromObject:$.getSelectorsFromObject,getSingularSelector:$.getSingularSelector,getStorageKey:G.getStorageKey,getVariablesFromFragment:$.getVariablesFromFragment,getVariablesFromObject:$.getVariablesFromObject,getVariablesFromPluralFragment:$.getVariablesFromPluralFragment,getVariablesFromSingularFragment:$.getVariablesFromSingularFragment,handlePotentialSnapshotErrors:ei,graphql:_.graphql,isErrorResult:n,isValueResult:s,isFragment:_.isFragment,isInlineDataFragment:_.isInlineDataFragment,isSuspenseSentinel:D,suspenseSentinel:L,isRequest:_.isRequest,readInlineData:P,readFragment:q.readFragment,MutationTypes:f.MutationTypes,RangeOperations:f.RangeOperations,DefaultHandlerProvider:u,ConnectionHandler:a,MutationHandlers:l,VIEWER_ID:H.VIEWER_ID,VIEWER_TYPE:H.VIEWER_TYPE,applyOptimisticMutation:c,commitLocalUpd
1ate:d,commitMutation:h,fetchQuery:y,fetchQuery_DEPRECATED:v,isRelayModernEnvironment:k,requestSubscription:z,ConnectionInterface:o,PreloadableQueryRegistry:E,RelayProfiler:ed,createPayloadFor3DField:K,RelayConcreteNode:eo,RelayError:eu,RelayFeatureFlags:ec,DEFAULT_HANDLE_KEY:el.DEFAULT_HANDLE_KEY,FRAGMENTS_KEY:G.FRAGMENTS_KEY,FRAGMENT_OWNER_KEY:G.FRAGMENT_OWNER_KEY,ID_KEY:G.ID_KEY,REF_KEY:G.REF_KEY,REFS_KEY:G.REFS_KEY,ROOT_ID:G.ROOT_ID,ROOT_TYPE:G.ROOT_TYPE,TYPENAME_KEY:G.TYPENAME_KEY,deepFreeze:W,generateClientID:x,generateUniqueClientID:T,getRelayHandleKey:ee,isClientID:w,isPromise:en,isScalarAndEqual:es,recycleNodesInto:ea,stableCopy:eg,hasCycle:ep,getFragmentIdentifier:Y,getRefetchMetadata:Z,getPaginationMetadata:Q,getPaginationVariables:X,getPendingOperationsForFragment:J,getValueAtPath:er,__internal:{ResolverFragments:q,OperationTracker:B,createRelayContext:R,createRelayLoggingContext:I,getOperationVariables:F.getOperationVariables,getLocalVariables:F.getLocalVariables,fetchQuery:b.fetchQuery,fetchQueryDeduped:b.fetchQueryDeduped,getPromiseForActiveRequest:b.getPromiseForActiveRequest,getObservableForActiveRequest:b.getObservableForActiveRequest,normalizeResponse:O,withProvidedVariables:em}}},145003,(e,t,r)=>{t.exports=e.r(100545)},66155,(e,t,r)=>{"use strict";var i=e.r(271645);t.exports=(0,e.r(145003).__internal.createRelayContext)(i)},343676,(e,t,r)=>{function i(){return t.exports=i=Object.assign.bind(),t.exports.__esModule=!0,t.exports.default=t.exports,i.apply(null,arguments)}t.exports=i,t.exports.__esModule=!0,t.exports.default=t.exports},332164,(e,t,r)=>{t.exports=function(e){if(void 0===e)throw ReferenceError("this hasn't been initialised - super() hasn't been called");return e},t.exports.__esModule=!0,t.exports.default=t.exports},410885,(e,t,r)=>{function i(e,r){return t.exports=i=Object.setPrototypeOf?Object.setPrototypeOf.bind():function(e,t){return e.__proto__=t,e},t.exports.__esModule=!0,t.exports.default=t.exports,i(e,r)}t.exports=i,t.exports.__esModule=!0,t.exports.default=t.exports},787232,(e,t,r)=>{var i=e.r(410885);t.exports=function(e,t){e.prototype=Object.create(t.prototype),e.prototype.constructor=e,i(e,t)},t.exports.__esModule=!0,t.exports.default=t.exports},461328,(e,t,r)=>{"use strict";var i=e.r(638743);t.exports=function(e,t){for(var r in t&&"object"==typeof t||i(!1),t)if(t.hasOwnProperty(r)){var n=t[r];n&&("object"==typeof n||"function"==typeof n)||i(!1)}}},725848,(e,t,r)=>{"use strict";function i(e){return e.displayName||e.name||"Component"}t.exports={getComponentName:i,getContainerName:function(e){return"Relay("+i(e)+")"}}},377649,(e,t,r)=>{"use strict";t.exports=e.r(271645).createContext({rootIsQueryRenderer:!1})},628301,(e,t,r)=>{"use strict";var i=(0,e.r(13451).default)(e.r(343676)),n=e.r(461328),s=e.r(725848),a=s.getComponentName,o=s.getContainerName,l=e.r(66155),u=e.r(377649),c=e.r(638743),d=e.r(271645),h=e.r(145003).getFragment,f=d.useContext;t.exports=function(e,t,r){var s=o(e);n(a(e),t);var p={};for(var g in t)p[g]=h(t[g]);var m=r(e,p);function y(e,t){var r,n=f(l);null==n&&c(!1);var s=f(u);return d.createElement(m,(0,i.default)({},e,{__relayContext:n,__rootIsQueryRenderer:null!=(r=null==s?void 0:s.rootIsQueryRenderer)&&r,componentRef:e.componentRef||t}))}return m.displayName=s,y.displayName=s,d.forwardRef(y)}},873077,(e,t,r)=>{"use strict";t.exports=function(e){return"object"==typeof e&&null!==e&&"function"==typeof e.check&&"function"==typeof e.lookup&&"function"==typeof e.retain&&"function"==typeof e.execute&&"function"==typeof e.subscribe}},22403,(e,t,r)=>{"use strict";var i=e.r(873077),n=e.r(638743);function s(e){return"object"==typeof e&&null!==e&&!Array.isArray(e)&&i(e.environment)}t.exports={assertRelayContext:function(e){return s(e)||n(!1),e},isRelayContext:s}},92310,(e,t,r)=>{"use strict";var i=e.r(13451).default,n=i(e.r(343676)),s=i(e.r(800419)),a=i(e.r(332164)),o=i(e.r(787232)),l=i(e.r(514414)),u=["componentRef","__relayContext","__rootIsQueryRenderer"],c=e.r(628301),d=e.r(725848).getContainerName,h=e.r(22403).assertRelayContext,f=e.r(832780),p=e.r(271645),g=e.r(145003),m=g.createFragmentSpecResolver,y=g.getDataIDsFromObject,v=g.isScalarAndEqual;function b(e,t){var r,i=d(e);return r=function(r){function c(e){s=r.call(this,e)||this,(0,l.default)((0,a.default)(s),"_handleFragmentDataUpdate",function(){var e=s.state.resolver;s.setState(function(t){return e===t.resolver?{data:t.resolver.resolve(),relayProp:_(t.relayProp.environment)}:null})});var n,s,o=h(e.__relayContext),u=null!=(n=e.__rootIsQueryRenderer)&&n,c=m(o,i,t,e,u);return s.state={data:c.resolve(),prevProps:e,prevPropsContext:o,relayProp:_(o.environment),resolver:c},s}(0,o.default)(c,r),c.getDerivedStateFromProps=function(e,r){var n,s=r.prevProps,a=h(e.__relayContext),o=null!=(n=e.__rootIsQueryRenderer)&&n,l=y(t,s),u=y(t,e),c=r.resolver;if(r.prevPropsContext.environment!==a.environment||!f(l,u))return{data:(c=m(a,i,t,e,o)).resolve(),prevPropsContext:a,prevProps:e,relayProp:_(a.environment),resolver:c};c.setProps(e);var d=c.resolve();return d!==r.data?{data:d,prevProps:e,prevPropsContext:a,relayProp:_(a.environment)}:null};var d=c.prototype;
1return d.componentDidMount=function(){this._subscribeToNewResolverAndRerenderIfStoreHasChanged()},d.componentDidUpdate=function(e,t){this.state.resolver!==t.resolver?(t.resolver.dispose(),this._subscribeToNewResolverAndRerenderIfStoreHasChanged()):this._rerenderIfStoreHasChanged()},d.componentWillUnmount=function(){this.state.resolver.dispose()},d.shouldComponentUpdate=function(e,r){if(r.data!==this.state.data)return!0;for(var i=Object.keys(e),n=0;n<i.length;n++){var s=i[n];if("__relayContext"===s){if(r.prevPropsContext.environment!==this.state.prevPropsContext.environment)return!0}else if(!t.hasOwnProperty(s)&&!v(e[s],this.props[s]))return!0}return!1},d._rerenderIfStoreHasChanged=function(){var e=this.state,t=e.data,r=e.resolver.resolve();t!==r&&this.setState({data:r})},d._subscribeToNewResolverAndRerenderIfStoreHasChanged=function(){var e=this.state,t=e.data,r=e.resolver,i=r.resolve();r.setCallback(this.props,this._handleFragmentDataUpdate),t!==i&&this.setState({data:i})},d.render=function(){var t=this.props,r=t.componentRef,i=(t.__relayContext,t.__rootIsQueryRenderer,(0,s.default)(t,u));return p.createElement(e,(0,n.default)({},i,this.state.data,{ref:r,relay:this.state.relayProp}))},c}(p.Component),(0,l.default)(r,"displayName",i),r}function _(e){return{environment:e}}t.exports={createContainer:function(e,t){return c(e,t,b)}}},423210,(e,t,r)=>{"use strict";var i=e.r(66155),n=e.r(377649),s=e.r(832780),a=e.r(271645),o=e.r(145003),l=o.createOperationDescriptor,u=(o.deepFreeze,o.getRequest),c=a.useLayoutEffect,d=a.useState,h=a.useRef,f=a.useMemo,p={rootIsQueryRenderer:!0};t.exports=function(e){var t,r=e.environment,o=e.query,g=e.variables,m=e.render,y=(s((t=a.useRef(g)).current,g)||(t.current=g),t.current),v=f(function(){return l(u(o),y)},[o,y]),b=f(function(){return{environment:r}},[r]),_=h(null),E=d(null)[1],S=h(null);return c(function(){var e=S.current;return function(){e&&e()}},[f(function(){r.check(v);var e=r.lookup(v.fragment);_.current=e.data;var t=r.retain(v),i=r.subscribe(e,function(e){_.current=e.data,E(_.current)}),n=!1;return S.current&&S.current(),S.current=function(){n||(n=!0,S.current=null,t.dispose(),i.dispose())},e},[r,v])]),a.createElement(i.Provider,{value:b},a.createElement(n.Provider,{value:p},m({props:_.current})))}},367372,(e,t,r)=>{"use strict";var i=(0,e.r(13451).default)(e.r(802953)),n=e.r(145003).getSelector;t.exports=function(e,t){var r={};return Object.keys(e).forEach(function(s){var a,o,l,u=n(e[s],t[s]),c=null!=u&&"PluralReaderSelector"===u.kind?null!=(a=null==(o=u.selectors[0])?void 0:o.owner.variables)?a:{}:null!=(l=null==u?void 0:u.owner.variables)?l:{};r=(0,i.default)((0,i.default)({},r),c)}),r}},333462,(e,t,r)=>{"use strict";var i=(0,e.r(13451).default)(e.r(514414)),n=e.r(638743),s=e.r(145003),a=s.__internal.fetchQuery,o=s.createOperationDescriptor,l=s.isRelayModernEnvironment;t.exports=function(){function e(e){(0,i.default)(this,"_selectionReferences",[]),(0,i.default)(this,"_didFetchFinish",!1),null!=e&&(this._cacheSelectionReference=e.cacheSelectionReference,this._selectionReferences=e.selectionReferences)}var t=e.prototype;return t.getSelectionReferences=function(){return{cacheSelectionReference:this._cacheSelectionReference,selectionReferences:this._selectionReferences}},t.lookupInStore=function(e,t,r){return("store-and-network"===r||"store-or-network"===r)&&"available"===e.check(t).status?(this._retainCachedOperation(e,t),e.lookup(t.fragment)):null},t.getFetchResult=function(){return this._didFetchFinish?null!=this._error?{error:this._error}:null!=this._snapshot?{snapshot:this._snapshot}:void 0:null},t.execute=function(e){var t=this,r=e.environment,i=e.operation,n=e.preservePreviousReferences,s=void 0!==n&&n,o=r.retain(i),u=function(){t._selectionReferences=t._selectionReferences.concat(o)},c=function(){s||t.disposeSelectionReferences(),t._selectionReferences=t._selectionReferences.concat(o)},d=function(){t._selectionReferences=t._selectionReferences.concat(o)};return l(r)?a(r,i).do({error:u,complete:c,unsubscribe:d}):r.execute({operation:i}).do({error:u,complete:c,unsubscribe:d})},t.setOnDataChange=function(e){this._fetchOptions||n(!1),"function"==typeof e&&(this._fetchOptions.onDataChangeCallbacks=this._fetchOptions.onDataChangeCallbacks||[],this._fetchOptions.onDataChangeCallbacks.push(e),this._didFetchFinish&&(null!=this._error?e({error:this._error}):null!=this._snapshot&&e({snapshot:this._snapshot})))},t.fetch=function(e,t){var r,i=this,n=e.environment,s=e.operation,a=e.onDataChange,l=!1;
1this.disposeRequest();var u=this._fetchOptions&&this._fetchOptions.onDataChangeCallbacks;this._fetchOptions={environment:n,onDataChangeCallbacks:u||[],operation:s},a&&-1===this._fetchOptions.onDataChangeCallbacks.indexOf(a)&&this._fetchOptions.onDataChangeCallbacks.push(a);var c=t?o(s.request.node,s.request.variables,t):s,d=this.execute({environment:n,operation:c}).finally(function(){i._pendingRequest=null}).subscribe({next:function(){i._didFetchFinish=!0,i._error=null,i._onQueryDataAvailable({notifyFirstResult:l})},error:function(e){i._didFetchFinish=!0,i._error=e,i._snapshot=null;var t=i._fetchOptions&&i._fetchOptions.onDataChangeCallbacks;l?t&&t.forEach(function(t){t({error:e})}):r=e}});if(this._pendingRequest={dispose:function(){d.unsubscribe()}},l=!0,r)throw r;return this._snapshot},t.retry=function(e){return this._fetchOptions||n(!1),this.fetch({environment:this._fetchOptions.environment,operation:this._fetchOptions.operation,onDataChange:null},e)},t.dispose=function(){this.disposeRequest(),this.disposeSelectionReferences()},t.disposeRequest=function(){this._error=null,this._snapshot=null,this._pendingRequest&&this._pendingRequest.dispose(),this._rootSubscription&&(this._rootSubscription.dispose(),this._rootSubscription=null)},t._retainCachedOperation=function(e,t){this._disposeCacheSelectionReference(),this._cacheSelectionReference=e.retain(t)},t._disposeCacheSelectionReference=function(){this._cacheSelectionReference&&this._cacheSelectionReference.dispose(),this._cacheSelectionReference=null},t.disposeSelectionReferences=function(){this._disposeCacheSelectionReference(),this._selectionReferences.forEach(function(e){return e.dispose()}),this._selectionReferences=[]},t._onQueryDataAvailable=function(e){var t=this,r=e.notifyFirstResult;this._fetchOptions||n(!1);var i=this._fetchOptions,s=i.environment,a=i.onDataChangeCallbacks,o=i.operation;if(!this._snapshot&&(this._snapshot=s.lookup(o.fragment),this._rootSubscription=s.subscribe(this._snapshot,function(e){if(null!=t._fetchOptions){var r=t._fetchOptions.onDataChangeCallbacks;Array.isArray(r)&&r.forEach(function(t){return t({snapshot:e})})}}),this._snapshot&&r&&Array.isArray(a))){var l=this._snapshot;a.forEach(function(e){return e({snapshot:l})})}},e}()},969467,(e,t,r)=>{"use strict";var i=e.r(13451).default,n=i(e.r(343676)),s=i(e.r(800419)),a=i(e.r(332164)),o=i(e.r(787232)),l=i(e.r(514414)),u=i(e.r(802953)),c=["componentRef"],d=["componentRef","__relayContext","__rootIsQueryRenderer"],h=["componentRef","__relayContext","__rootIsQueryRenderer"],f=e.r(628301),p=e.r(367372),g=e.r(725848),m=g.getComponentName,y=g.getContainerName,v=e.r(66155),b=e.r(333462),_=e.r(22403).assertRelayContext,E=e.r(832780),S=e.r(638743),x=e.r(271645),T=e.r(145003),w=T.ConnectionInterface,A=T.Observable,R=T.RelayFeatureFlags,I=T.createFragmentSpecResolver,k=T.createOperationDescriptor,C=T.getDataIDsFromObject,D=T.getRequest,L=T.getVariablesFromObject,O=T.isScalarAndEqual;e.r(603158);var P="forward";function F(e){return"function"==typeof e?{error:e,complete:e,unsubscribe:function(t){"function"==typeof e&&e()}}:e||{}}t.exports={createContainer:function(e,t,r){return f(e,t,function(e,t){return function(e,t,r){m(e);var i,f,g,T=y(e),N=function(e){var t=null,r=!1;for(var i in e){var n=e[i],s=n.metadata&&n.metadata.connection;void 0!==n.metadata&&(r=!0),s&&(1!==s.length&&S(!1),t&&S(!1),t=(0,u.default)((0,u.default)({},s[0]),{},{fragmentName:i}))}return r&&null===t&&S(!1),t||{}}(t),M=r.getConnectionFromProps||((i=N.path)||S(!1),function(e){for(var t=e[N.fragmentName],r=0;r<i.length;r++){if(!t||"object"!=typeof t)return null;t=t[i[r]]}return t}),j=r.direction||N.direction;j||S(!1);var $=r.getFragmentVariables||((f=N.count)||S(!1),function(e,t){return(0,u.default)((0,u.default)({},e),{},(0,l.default)({},f,t))});return g=function(i){function f(e){n=i.call(this,e)||this,(0,l.default)((0,a.default)(n),"_handleFragmentDataUpdate",function(){n.setState({data:n._resolver.resolve()})}),(0,l.default)((0,a.default)(n),"_hasMore",function(){var e=n._getConnectionData();return!!(e&&e.hasMore&&e.cursor)}),(0,l.default)((0,a.default)(n),"_isLoading",function(){return!!n._refetchSub
1scription}),(0,l.default)((0,a.default)(n),"_refetchConnection",function(e,t,r){return n._canFetchPage("refetchConnection")?(n._refetchVariables=r,{dispose:n._fetchPage({count:e,cursor:null,totalCount:e},F(t),{force:!0}).unsubscribe}):{dispose:function(){}}}),(0,l.default)((0,a.default)(n),"_loadMore",function(e,t,r){if(!n._canFetchPage("loadMore"))return{dispose:function(){}};var i=F(t),s=n._getConnectionData();if(!s)return A.create(function(e){return e.complete()}).subscribe(i),null;var a=s.edgeCount+e;if(r&&r.force)return n._refetchConnection(a,t);var o=w.get();o.END_CURSOR,o.START_CURSOR;var l=s.cursor;return{dispose:n._fetchPage({count:e,cursor:l,totalCount:a},i,r).unsubscribe}});var r,n,s=_(e.__relayContext),o=null!=(r=e.__rootIsQueryRenderer)&&r;return n._isARequestInFlight=!1,n._refetchSubscription=null,n._refetchVariables=null,!0===R.ENABLE_CONTAINERS_SUBSCRIBE_ON_COMMIT?n._resolver=I(s,T,t,e,o):n._resolver=I(s,T,t,e,o,n._handleFragmentDataUpdate),n.state={data:n._resolver.resolve(),prevContext:s,contextForChildren:s,relayProp:n._buildRelayProp(s),resolverGeneration:0},n._isUnmounted=!1,n._hasFetched=!1,n}(0,o.default)(f,i);var g=f.prototype;return g.componentDidMount=function(){this._isUnmounted=!1,!0===R.ENABLE_CONTAINERS_SUBSCRIBE_ON_COMMIT&&this._subscribeToNewResolverAndRerenderIfStoreHasChanged()},g.componentDidUpdate=function(e,t){!0===R.ENABLE_CONTAINERS_SUBSCRIBE_ON_COMMIT&&(t.resolverGeneration!==this.state.resolverGeneration?this._subscribeToNewResolverAndRerenderIfStoreHasChanged():this._rerenderIfStoreHasChanged())},g.UNSAFE_componentWillReceiveProps=function(e){var r,i=this,n=_(e.__relayContext),s=null!=(r=e.__rootIsQueryRenderer)&&r,a=C(t,this.props),o=C(t,e),l=p(t,this.props),u=p(t,e);n.environment===this.state.prevContext.environment&&E(l,u)&&E(a,o)?this._hasFetched||this._resolver.setProps(e):(this._cleanup(),!0===R.ENABLE_CONTAINERS_SUBSCRIBE_ON_COMMIT?this._resolver=I(n,T,t,e,s):this._resolver=I(n,T,t,e,s,this._handleFragmentDataUpdate),this.setState(function(e){return{prevContext:n,contextForChildren:n,relayProp:i._buildRelayProp(n),resolverGeneration:e.resolverGeneration+1}}));var c=this._resolver.resolve();c!==this.state.data&&this.setState({data:c})},g.componentWillUnmount=function(){this._isUnmounted=!0,this._cleanup()},g.shouldComponentUpdate=function(e,r){if(r.data!==this.state.data||r.relayProp!==this.state.relayProp||r.resolverGeneration!==this.state.resolverGeneration)return!0;for(var i=Object.keys(e),n=0;n<i.length;n++){var s=i[n];if("__relayContext"===s){if(r.prevContext.environment!==this.state.prevContext.environment)return!0}else if(!t.hasOwnProperty(s)&&!O(e[s],this.props[s]))return!0}return!1},g._buildRelayProp=function(e){return{hasMore:this._hasMore,isLoading:this._isLoading,loadMore:this._loadMore,refetchConnection:this._refetchConnection,environment:e.environment}},g._rerenderIfStoreHasChanged=function(){var e=this.state.data,t=this._resolver.resolve();e!==t&&this.setState({data:t})},g._subscribeToNewResolverAndRerenderIfStoreHasChanged=function(){var e=this.state.data,t=this._resolver.resolve();this._resolver.setCallback(this.props,this._handleFragmentDataUpdate),e!==t&&this.setState({data:t})},g._getConnectionData=function(){var e=this.props,t=(e.componentRef,(0,s.default)(e,c)),r=M((0,u.default)((0,u.default)({},t),this.state.data));if(null==r)return null;var i=w.get(),n=i.EDGES,a=i.PAGE_INFO,o=i.HAS_NEXT_PAGE,l=i.HAS_PREV_PAGE,d=i.END_CURSOR,h=i.START_CURSOR;"object"!=typeof r&&S(!1);var f=r[n],p=r[a];if(null==f||null==p)return null;Array.isArray(f)||S(!1),"object"!=typeof p&&S(!1);var g=j===P?p[o]:p[l],m=j===P?p[d]:p[h];return"boolean"!=typeof g||0!==f.length&&void 0===m?null:{cursor:m,edgeCount:f.length,hasMore:g}},g._getQueryFetcher=function(){return this._queryFetcher||(this._queryFetcher=new b),this._queryFetcher},g._canFetchPage=function(e){return!this._isUnmounted},g._fetchPage=function(e,i,n){var a,o=this,l=_(this.props.__relayContext).environment,c=this.props,h=(c.componentRef,c.__relayContext,c.__rootIsQueryRenderer,(0,s.default)(c,d)),f=(0,u.default)((0,u.default)({},h),this.state.data),g=p(t,h);a=L(t,h),a=(0,u.default)((0,u.default)((0,u.default)({},g),a),this._refetchVariables);var m=r.getVariables(f,{count:e.count,cursor:e.cursor},a);("object"!=typeof m||null===m)&&S(!1),m=(0,u.default)((0,u.default)({},m),this._refetchVariables),a=(0,u.default)((0,u.default)({},m),a);var y=n?{force:!!n.force}:void 0;null!=y&&(null==n?void 0:n.metadata)!=null&&(y.metadata=null==n?void 0:n.metadata);var v=k(D(r.query),m,y),b=null;
1this._refetchSubscription&&this._refetchSubscription.unsubscribe(),this._hasFetched=!0;var x=function(t,r){var i=o._resolver.resolve();o._resolver.setVariables($(a,e.totalCount),v.request.node);var n=o._resolver.resolve();E(i,n)?r():o.setState({data:n,contextForChildren:{environment:o.props.__relayContext.environment}},r)},T=function(){o._refetchSubscription===b&&(o._refetchSubscription=null,o._isARequestInFlight=!1)};return this._isARequestInFlight=!0,b=this._getQueryFetcher().execute({environment:l,operation:v,preservePreviousReferences:!0}).mergeMap(function(e){return A.create(function(t){x(e,function(){t.next(),t.complete()})})}).do({error:T,complete:T,unsubscribe:T}).subscribe(i||{}),this._refetchSubscription=this._isARequestInFlight?b:null,b},g._cleanup=function(){this._resolver.dispose(),this._refetchVariables=null,this._hasFetched=!1,this._refetchSubscription&&(this._refetchSubscription.unsubscribe(),this._refetchSubscription=null,this._isARequestInFlight=!1),this._queryFetcher&&this._queryFetcher.dispose()},g.render=function(){var t=this.props,r=t.componentRef,i=(t.__relayContext,t.__rootIsQueryRenderer,(0,s.default)(t,h));return x.createElement(v.Provider,{value:this.state.contextForChildren},x.createElement(e,(0,n.default)({},i,this.state.data,{ref:r,relay:this.state.relayProp})))},f}(x.Component),(0,l.default)(g,"displayName",T),g}(e,t,r)})}}},778218,(e,t,r)=>{"use strict";var i=e.r(13451).default,n=i(e.r(802953)),s=i(e.r(332164)),a=i(e.r(787232)),o=i(e.r(514414)),l=e.r(66155),u=e.r(333462),c=e.r(377649),d=e.r(832780),h=e.r(271645),f=e.r(145003),p=f.createOperationDescriptor,g=(f.deepFreeze,f.getRequest),m={},y={rootIsQueryRenderer:!0};function v(){return{error:null,props:null,retry:null}}function b(e,t,r,i){return{error:e||null,props:t?t.data:null,retry:function(t){var n=r.retry(t);n&&"function"==typeof i.handleDataChange?i.handleDataChange({snapshot:n}):e&&"function"==typeof i.handleRetryAfterError&&i.handleRetryAfterError(e)}}}function _(e,t){return JSON.stringify({id:e.cacheID?e.cacheID:e.id,variables:t})}function E(e,t){var r,i=e.query,s=t.queryFetcher.getSelectionReferences();
1if(t.queryFetcher.disposeRequest(),i){var a=_(g(i).params,e.variables);r=m[a]?m[a].queryFetcher:new u(s)}else r=new u(s);return(0,n.default)({prevQuery:e.query,prevPropsEnvironment:e.environment,prevPropsVariables:e.variables,queryFetcher:r},S(e,r,t.retryCallbacks))}function S(e,t,r,i){var n=e.environment,s=e.query,a=e.variables,o=e.cacheConfig;if(s){var l=g(s),u=p(l,a,o),c={environment:n};if("string"==typeof i&&m[i]){var d=m[i].snapshot;return d?{error:null,relayContext:c,renderProps:b(null,d,t,r),snapshot:d,requestCacheKey:i}:{error:null,relayContext:c,renderProps:v(),snapshot:null,requestCacheKey:i}}try{var h=t.lookupInStore(n,u,e.fetchPolicy),f=t.fetch({environment:n,onDataChange:null,operation:u})||h;if(m[i=i||_(l.params,e.variables)]={queryFetcher:t,snapshot:f},!f)return{error:null,relayContext:c,renderProps:v(),snapshot:null,requestCacheKey:i};return{error:null,relayContext:c,renderProps:b(null,f,t,r),snapshot:f,requestCacheKey:i}}catch(e){return{error:e,relayContext:c,renderProps:b(e,null,t,r),snapshot:null,requestCacheKey:i}}}return t.dispose(),{error:null,relayContext:{environment:n},renderProps:{error:null,props:{},retry:null},requestCacheKey:null}}t.exports=function(e){function t(t){r=e.call(this,t)||this,(0,o.default)((0,s.default)(r),"_handleDataChange",function(e){var t=null==e.error?null:e.error,i=null==e.snapshot?null:e.snapshot;r.setState(function(e){var r=e.requestCacheKey;return(r&&delete m[r],i===e.snapshot&&t===e.error)?null:{renderProps:b(t,i,e.queryFetcher,e.retryCallbacks),snapshot:i,requestCacheKey:null}})});var r,i,a,l={handleDataChange:null,handleRetryAfterError:null};return i=t.query&&m[a=_(g(t.query).params,t.variables)]?m[a].queryFetcher:new u,r._maybeHiddenOrFastRefresh=!1,r.state=(0,n.default)({prevPropsEnvironment:t.environment,prevPropsVariables:t.variables,prevQuery:t.query,queryFetcher:i,retryCallbacks:l},S(t,i,l,a)),r}(0,a.default)(t,e),t.getDerivedStateFromProps=function(e,t){return t.prevQuery===e.query&&t.prevPropsEnvironment===e.environment&&d(t.prevPropsVariables,e.variables)?null:E(e,t)};var r=t.prototype;return r.componentDidMount=function(){var e=this;if(!0===this._maybeHiddenOrFastRefresh){this._maybeHiddenOrFastRefresh=!1,this.setState(function(t){var r=E(e.props,t),i=r.requestCacheKey,n=r.queryFetcher;return null!=i&&null!=m[i]&&n.setOnDataChange(e._handleDataChange),r});return}var t=this.state,r=t.retryCallbacks,i=t.queryFetcher,n=t.requestCacheKey;n&&delete m[n],r.handleDataChange=this._handleDataChange,r.handleRetryAfterError=function(t){return e.setState(function(e){var t=e.requestCacheKey;return t&&delete m[t],{renderProps:v(),requestCacheKey:null}})},this.props.query&&i.setOnDataChange(this._handleDataChange)},r.componentDidUpdate=function(e,t){var r=this.state,i=r.queryFetcher,n=r.requestCacheKey;n&&(delete m[n],delete this.state.requestCacheKey),this.props.query&&i!==t.queryFetcher&&i.setOnDataChange(this._handleDataChange)},r.componentWillUnmount=function(){this.state.queryFetcher.dispose(),this._maybeHiddenOrFastRefresh=!0},r.shouldComponentUpdate=function(e,t){return e.render!==this.props.render||t.renderProps!==this.state.renderProps},r.render=function(){var e=this.state,t=e.renderProps,r=e.relayContext;return h.createElement(l.Provider,{value:r},h.createElement(c.Provider,{value:y},this.props.render(t)))},t}(h.Component)},784701,(e,t,r)=>{"use strict";var i=e.r(13451).default,n=i(e.r(343676)),s=i(e.r(800419)),a=i(e.r(802953)),o=i(e.r(332164)),l=i(e.r(787232)),u=i(e.r(514414)),c=["componentRef","__relayContext","__rootIsQueryRenderer"],d=e.r(628301),h=e.r(367372),f=e.r(725848).getContainerName,p=e.r(66155),g=e.r(333462),m=e.r(22403).assertRelayContext,y=e.r(832780),v=e.r(271645),b=e.r(145003),_=b.Observable,E=b.createFragmentSpecResolver,S=b.createOperationDescriptor,x=b.getDataIDsFromObject,T=b.getRequest,w=b.getVariablesFromObject,A=b.isScalarAndEqual;function R(e,t){return{environment:e,refetch:t}}e.r(603158),t.exports={createContainer:function(e,t,r){return d(e,t,function(e,t){var i,d;return d=f(e),i=function(i){function f(e){s=i.call(this,e)||this,(0,u.default)((0,o.default)(s),"_handleFragmentDataUpdate",function(){var e=s.state.resolver;s.setState(function(t){return e===t.resolver?{data:t.resolver.resolve()}:null})}),(0,u.default)((0,o.default)(s),"_refetch",function(e,i,n,o){if(s._isUnmounted)return{dispose:function(){}};var l,u=m(s.props.__relayContext).environment,c=h(t,s.props),d="function"==typeof e?e(s._getFragmentVariables()):e;d=(0,a.default)((0,a.default)({},c),d);var f=i?(0,a.default)((0,a.default)({},d),i):d,p=o?{force:!!o.force}:void 0;null!=p&&(null==o?void 0:o.metadata)!=null&&(p.metadata=null==o?void 0:o.metadata);var g="function"==typeof n?{next:n,error:n}:n||{},y=S(T(r),d,p);
1return(s.state.localVariables=d,s._refetchSubscription&&s._refetchSubscription.unsubscribe(),null!=s._getQueryFetcher().lookupInStore(u,y,null==o?void 0:o.fetchPolicy))?(s.state.resolver.setVariables(f,y.request.node),s.setState(function(e){return{data:e.resolver.resolve(),contextForChildren:{environment:s.props.__relayContext.environment}}},function(){g.next&&g.next(),g.complete&&g.complete()}),{dispose:function(){}}):(s._getQueryFetcher().execute({environment:u,operation:y,preservePreviousReferences:!0}).mergeMap(function(e){return s.state.resolver.setVariables(f,y.request.node),_.create(function(e){return s.setState(function(e){return{data:e.resolver.resolve(),contextForChildren:{environment:s.props.__relayContext.environment}}},function(){e.next(),e.complete()})})}).finally(function(){s._refetchSubscription===l&&(s._refetchSubscription=null)}).subscribe((0,a.default)((0,a.default)({},g),{},{start:function(e){s._refetchSubscription=l=e,g.start&&g.start(e)}})),{dispose:function(){l&&l.unsubscribe()}})});var n,s,l=m(e.__relayContext),c=null!=(n=e.__rootIsQueryRenderer)&&n;s._refetchSubscription=null;var f=E(l,d,t,e,c);return s.state={data:f.resolve(),localVariables:null,prevProps:e,prevPropsContext:l,contextForChildren:l,relayProp:R(l.environment,s._refetch),resolver:f},s._isUnmounted=!1,s}(0,l.default)(f,i);var b=f.prototype;return b.componentDidMount=function(){this._isUnmounted=!1,this._subscribeToNewResolverAndRerenderIfStoreHasChanged()},b.componentDidUpdate=function(e,t){this.state.resolver!==t.resolver?(t.resolver.dispose(),this._queryFetcher&&this._queryFetcher.dispose(),this._refetchSubscription&&this._refetchSubscription.unsubscribe(),this._subscribeToNewResolverAndRerenderIfStoreHasChanged()):this._rerenderIfStoreHasChanged()},f.getDerivedStateFromProps=function(e,r){var i,n=r.prevProps,s=m(e.__relayContext),a=null!=(i=e.__rootIsQueryRenderer)&&i,o=x(t,n),l=x(t,e),u=h(t,n),c=h(t,e),f=r.resolver;if(r.prevPropsContext.environment!==s.environment||!y(u,c)||!y(o,l))return{data:(f=E(s,d,t,e,a)).resolve(),localVariables:null,prevProps:e,prevPropsContext:s,contextForChildren:s,relayProp:R(s.environment,r.relayProp.refetch),resolver:f};r.localVariables||f.setProps(e);var p=f.resolve();return p!==r.data?{data:p,prevProps:e}:null},b.componentWillUnmount=function(){this._isUnmounted=!0,this.state.resolver.dispose(),this._queryFetcher&&this._queryFetcher.dispose(),this._refetchSubscription&&this._refetchSubscription.unsubscribe()},b.shouldComponentUpdate=function(e,r){if(r.data!==this.state.data||r.relayProp!==this.state.relayProp)return!0;for(var i=Object.keys(e),n=0;n<i.length;n++){var s=i[n];if("__relayContext"===s){if(this.state.prevPropsContext.environment!==r.prevPropsContext.environment)return!0}else if(!t.hasOwnProperty(s)&&!A(e[s],this.props[s]))return!0}return!1},b._rerenderIfStoreHasChanged=function(){var e=this.state,t=e.data,r=e.resolver.resolve();t!==r&&this.setState({data:r})},b._subscribeToNewResolverAndRerenderIfStoreHasChanged=function(){var e=this.state,t=e.data,r=e.resolver,i=r.resolve();r.setCallback(this.props,this._handleFragmentDataUpdate),t!==i&&this.setState({data:i})},b._getFragmentVariables=function(){return w(t,this.props)},b._getQueryFetcher=function(){return this._queryFetcher||(this._queryFetcher=new g),this._queryFetcher},b.render=function(){var t=this.props,r=t.componentRef,i=(t.__relayContext,t.__rootIsQueryRenderer,(0,s.default)(t,c)),a=this.state,o=a.relayProp,l=a.contextForChildren;return v.createElement(p.Provider,{value:l},v.createElement(e,(0,n.default)({},i,this.state.data,{ref:r,relay:o})))},f}(v.Component),(0,u.default)(i,"displayName",d),i})}}},609700,(e,t,r)=>{"use strict";t.exports=e.r(271645).createContext({wrapPrepareQueryResource:function(e){return e()}})},795715,(e,t,r)=>{"use strict";var i=e.r(66155),n=e.r(638743),s=e.r(271645).useContext;t.exports=function(){var e=s(i);return null==e&&n(!1),e.environment}},775130,(e,t,r)=>{"use strict";var i=e.r(609700),n=e.r(795715),s=e.r(271645),a=e.r(271645),o=a.useContext,l=a.useEffect;e.r(603158),t.exports=function(e){var t=e.entryPointReference,r=e.props,a=t.getComponent,u=t.queries,c=t.entryPoints,d=t.extraProps,h=t.rootModuleID,f=a(),p=o(i),g=n();return l(function(){g.__log({name:"entrypoint.root.consume",profilerContext:p,rootModuleID:h})},[g,p,h]),s.createElement(f,{entryPoints:c,extraProps:d,props:r,queries:u})}},335630,(e,t,r)=>{"use strict";var i=(0,e.r(13451).default)(e.r(802953)),n=e.r(638743),s=e.r(145003),a=s.__internal.fetchQueryDeduped,o=s.Observable,l=s.PreloadableQueryRegistry,u=s.ReplaySubject,c=s.createOperationDescriptor,d=s.getRequest,h=s.getRequestIdentifier,f=100001;t.exports={loadQuery:function(e,t,r,s,p){f++;var g,m,y,v,b,_,E,S=null!=(g=null==s?void 0:s.fetchPolicy)?g:"store-or-network",x=(0,i.default)((0,i.default)({},null==s?void 0:s.networkCacheConfig),{},{force:!0}),T=!1,w=function(t,r){return T=!0,e.executeWithSource({operation:t,source:r})}
1,A=new u,R=o.create(function(e){return A.subscribe(e)}),I=null,k=!1,C=function(t,i){k=!0;var n=new u;return y=a(e,"raw-network-request-"+h(t,r),function(){return e.getNetwork().execute(t,r,x,void 0,void 0,void 0,void 0,i)}).subscribe({error:function(e){I=e,n.error(e)},next:function(e){n.next(e)},complete:function(){n.complete()}}).unsubscribe,o.create(function(e){var t=n.subscribe(e);return function(){t.unsubscribe(),y()}})},D=function(t,r){k=!0,v=a(e,t.request.identifier,r).subscribe({error:function(e){A.error(e)},next:function(e){A.next(e)},complete:function(){A.complete()}}).unsubscribe},L=function(t){var i=c(t,r,x);m=e.retain(i),"store-only"!==S&&("store-or-network"!==S||"available"!==e.check(i).status)&&D(i,function(){var r=C(t.params,function(){return e.check(i)});return w(i,r)})};if("PreloadableConcreteRequest"===t.kind){null===(E=(b=t.params).id)&&n(!1);var O=l.get(E);if(null!=O)L(O);else{var P="store-only"===S?null:C(b);_=l.onLoad(E,function(t){_();var i=c(t,r,x);m=e.retain(i),null!=P&&D(i,function(){return w(i,P)})}).dispose}}else{var F=d(t);E=null!=(b=F.params).cacheID?b.cacheID:b.id,L(F)}var N=!1,M=!1,j=!1,$=function(){M||(m&&m.dispose(),M=!0)},U=function(){j||(T?v&&v():y&&y(),_&&_(),j=!0)};return{kind:"PreloadedQuery",environment:e,environmentProviderOptions:p,dispose:function(){N||($(),U(),N=!0)},releaseQuery:$,cancelNetworkRequest:U,fetchKey:f,id:E,get isDisposed(){return N||M},get networkError(){return I},name:b.name,networkCacheConfig:x,fetchPolicy:S,source:k?R:void 0,variables:r}}}},5670,(e,t,r)=>{"use strict";var i=e.r(335630).loadQuery;t.exports=function e(t,r,n){var s=null;null==r.root.getModuleIfRequired()&&(s=r.root.load());var a=r.getPreloadProps(n),o=a.queries,l=a.entryPoints,u=a.extraProps,c={},d={};null!=o&&Object.keys(o).forEach(function(e){var r=o[e];if(null!=r){var n=r.environmentProviderOptions,s=r.options,a=r.parameters,l=r.variables;if((null==s?void 0:s.includeIf)!==!1){var u=t.getEnvironment(n);c[e]=i(u,a,l,{fetchPolicy:null==s?void 0:s.fetchPolicy,networkCacheConfig:null==s?void 0:s.networkCacheConfig,__nameForWarning:"loadEntryPoint"},n)}}}),null!=l&&Object.keys(l).forEach(function(r){var i=l[r];if(null!=i){var n=i.entryPoint,s=i.entryPointParams;d[r]=e(t,n,s)}});var h=!1;return{dispose:function(){h||(null!=c&&Object.values(c).forEach(function(e){(0,e.dispose)()}),null!=d&&Object.values(d).forEach(function(e){(0,e.dispose)()}),h=!0)},entryPoints:d,extraProps:null!=u?u:null,getComponent:function(){var e,t=r.root.getModuleIfRequired();if(null==t)throw s=null!=(e=s)?e:r.root.load();return null!=t.default?t.default:t},get isDisposed(){return h},queries:c,rootModuleID:r.root.getModuleId()}}},794657,(e,t,r)=>{"use strict";var i=e.r(66155),n=e.r(271645),s=n.useMemo;t.exports=function(e){var t=e.children,r=e.environment,a=e.getEnvironmentForActor,o=s(function(){return{environment:r,getEnvironmentForActor:a}},[r,a]);return n.createElement(i.Provider,{value:o},t)}},4759,(e,t,r)=>{"use strict";var i=e.r(638743),n=function(){function e(e){this._capacity=e,this._capacity>0||i(!1),this._map=new Map}var t=e.prototype;return t.set=function(e,t){if(this._map.delete(e),this._map.set(e,t),this._map.size>this._capacity){var r=this._map.keys().next();r.done||this._map.delete(r.value)}},t.get=function(e){var t=this._map.get(e);return null!=t&&(this._map.delete(e),this._map.set(e,t)),t},t.has=function(e){return this._map.has(e)},t.delete=function(e){this._map.delete(e)},t.size=function(){return this._map.size},t.capacity=function(){return this._capacity-this._map.size},t.clear=function(){this._map.clear()},e}();t.exports={create:function(e){return new n(e)}}},485341,(e,t,r)=>{"use strict";var i=(0,e.r(13451).default)(e.r(514414));e.r(603158),t.exports=function(){function e(e){var t=this;(0,i.default)(this,"_retainCount",0),(0,i.default)(this,"_retainDisposable",null),(0,i.default)(this,"_releaseTemporaryRetain",null),this._retain=function(r){return t._retainCount++,1===t._retainCount&&(t._retainDisposable=e(r)),{dispose:function(){t._retainCount=Math.max(0,t._retainCount-1),0===t._retainCount&&null!=t._retainDisposable&&(t._retainDisposable.dispose(),t._retainDisposable=null)}}}}var t=e.prototype;return t.temporaryRetain=function(e){var t,r=this;if(e.isServer())return{dispose:function(){}};var i=this._retain(e),n=null,s=function(){clearTimeout(n),n=null,r._releaseTemporaryRetain=null,i.dispose()};return n=setTimeout(s,3e5),null==(t=this._releaseTemporaryRetain)||t.call(this),this._releaseTemporaryRetain=s,{dispose:function(){var e;null==(e=r._releaseTemporaryRetain)||e.call(r)}}},t.permanentRetain=function(e){var t=this._retain(e);return this.releaseTemporaryRetain(),t},t.releaseTemporaryRetain=function(){var e;null==(e=this._releaseTemporaryRetain)||e.call(this),this._releaseTemporaryRetain=null},t.getRetainCount=function(){return this._retainCount},e}()},916426,(e,t,r)=>{"use strict";var i=e.r(13451).default,n=i(e.r(802953)),s=i(e.r(514414)),a=e.r(4759),o=e.r(485341),l=e.r(638743),u=e.r(145003).isPromise;e.r(603158);var c="store-or-network",d="store-and-network",h="function"==typeof WeakMap;function f(e){return void 0!==e.request.node.params.metadata.live}function p(e,t,r,i,n){var s=null!=r?r:f(t)?d:c,a=null!=i?i:e.UNSTABLE_getDefaultRenderPolicy(),o="".concat(s,"-").concat(a,"-").concat(t.request.identifier);return null!=n?"".concat(o,"-").concat(n):o}function g(e,t){var r={__id:e.fragment.dataID,__fragments:(0,s.default)({},e.fragment.node.name,e.request.variables),__fragmentOwner:e.request};return{cacheIdentifier:t,fragmentNode:e.request.node.fragment,fragmentRef:r,operation:e}}var m=2e5;function y(e,t,r,i,n,s){var a=f(t),l=i,u=n,c=new o(function(e){var r=e.retain(t);return{dispose:function(){a&&null!=u&&u.unsubscribe(),r.dispose(),s(d)}}}),d={cacheIdentifier:e,id:m++,processedPayloadsCount:0,operationAvailability:r,getValue:function(){return l},setValue:function(e){l=e},setNetworkSubscription:function(e){a&&null!=u&&u.unsubscribe(),u=e},temporaryRetain:function(e){return c.temporaryRetain(e)},permanentRetain:function(e){return c.permanentRetain(e)},releaseTemporaryRetain:function(){c.releaseTemporaryRetain()}};return d}var v=function(){function e(e){var t=this;(0,s.default)(this,"_clearCacheEntry",function(e){t._cache.delete(e.cac
1heIdentifier)}),this._environment=e,this._cache=a.create(1e3)}var t=e.prototype;return t.prepare=function(e,t,r,i,n,s,a){var o=p(this._environment,e,r,i,s);return this.prepareWithIdentifier(o,e,t,r,i,n,a)},t.prepareWithIdentifier=function(e,t,r,i,s,a,o){var l=this._environment,h=null!=i?i:f(t)?d:c,p=null!=s?s:l.UNSTABLE_getDefaultRenderPolicy(),g=this._cache.get(e),m=null,y=null!=g;null==g&&(g=this._fetchAndSaveQuery(e,t,r,h,p,o,(0,n.default)((0,n.default)({},a),{},{unsubscribe:function(e){null!=m&&m.dispose();var t=null==a?void 0:a.unsubscribe;t&&t(e)}}))),m=g.temporaryRetain(l);var v=g.getValue();if(u(v))throw l.__log({name:"suspense.query",fetchPolicy:h,isPromiseCached:y,operation:t,queryAvailability:g.operationAvailability,renderPolicy:p}),v;if(v instanceof Error)throw v;return v},t.retain=function(e,t){var r=this._environment,i=e.cacheIdentifier,n=e.operation,s=this._getOrCreateCacheEntry(i,n,null,e,null),a=s.permanentRetain(r);return r.__log({name:"queryresource.retain",profilerContext:t,resourceID:s.id}),{dispose:function(){a.dispose()}}},t.releaseTemporaryRetain=function(e){var t=this._cache.get(e.cacheIdentifier);null!=t&&t.releaseTemporaryRetain()},t.TESTS_ONLY__getCacheEntry=function(e,t,r,i){var n=p(this._environment,e,t,r,i);return this._cache.get(n)},t._getOrCreateCacheEntry=function(e,t,r,i,n){var s=this._cache.get(e);return null==s&&(s=y(e,t,r,i,n,this._clearCacheEntry),this._cache.set(e,s)),s},t._fetchAndSaveQuery=function(e,t,r,i,s,a,o){var u=this,c=this._environment,d=c.check(t),h=d.status,p="available"===h,m=p||"partial"===s&&"stale"!==h,v=function(){};switch(i){case"store-only":E=!1,S=!0;break;case"store-or-network":E=!p,S=m;break;case"store-and-network":E=!0,S=m;break;default:E=!0,S=!1}if(S){var b=g(t,e),_=y(e,t,d,b,null,this._clearCacheEntry);this._cache.set(e,_)}if(E){var E,S,x,T=g(t,e);r.subscribe({start:function(r){x=r;var i=u._cache.get(e);i&&i.setNetworkSubscription(x);var s=null==o?void 0:o.start;s&&s((0,n.default)((0,n.default)({},r),{},{unsubscribe:function(){f(t)&&r.unsubscribe()}}))},next:function(){var r=u._getOrCreateCacheEntry(e,t,d,T,x);r.processedPayloadsCount+=1,r.setValue(T),v();var i=null==o?void 0:o.next;null!=i&&i(c.lookup(t.fragment))},error:function(r){var i=u._getOrCreateCacheEntry(e,t,d,r,x);0===i.processedPayloadsCount&&i.setValue(r),v(),x=null,i.setNetworkSubscription(null);var n=null==o?void 0:o.error;n&&n(r)},complete:function(){v(),x=null;var t=u._cache.get(e);t&&t.setNetworkSubscription(null);var r=null==o?void 0:o.complete;r&&r()},unsubscribe:null==o?void 0:o.unsubscribe});var w=this._cache.get(e);if(!w){var A=new Promise(function(e){v=e});A.displayName="Relay("+t.fragment.node.name+")",w=y(e,t,d,A,x,this._clearCacheEntry),this._cache.set(e,w)}}else{var R=null==o?void 0:o.complete;R&&R()}var I=this._cache.get(e);return null==I&&l(!1),c.__log({name:"queryresource.fetch",resourceID:I.id,operation:t,profilerContext:a,fetchPolicy:i,renderPolicy:s,queryAvailability:d,shouldFetch:E}),I},e}();function b(e){return new v(e)}var _=h?new WeakMap:new Map;t.exports={createQueryResource:b,getQueryResourceForEnvironment:function(e){var t=_.get(e);if(t)return t;var r=b(e);return _.set(e,r),r},getQueryCacheIdentifier:p}},551261,(e,t,r)=>{"use strict";var i=e.r(271645).useMemo;t.exports=function(e){return i(function(){return{current:e}},[])}},735699,(e,t,r)=>{"use strict";var i=e.r(551261),n=e.r(271645),s=n.useCallback,a=n.useEffect;t.exports=function(){var e=i(null),t=i(!1),r=s(function(){null!=e.current&&(e.current.unsubscribe(),e.current=null),t.current=!1},[]),n=s(function(r){e.current=r,t.current=!0},[]),o=s(function(){e.current=null,t.current=!1},[]);return a(function(){return r},[r]),{isFetchingRef:t,startFetch:n,disposeFetch:r,completeFetch:o}}},581723,(e,t,r)=>{"use strict";var i=e.r(271645);t.exports=(0,e.r(145003).__internal.createRelayLoggingContext)(i)},290487,(e,t,r)=>{"use strict";var i=e.r(581723),n=e.r(271645).useContext;t.exports=function(){return n(i)}},465718,(e,t,r)=>{"use strict";var i=e.r(13451).default,n=i(e.r(802953)),s=i(e.r(877913)),a=i(e.r(117675)),o=e.r(916426).getQueryResourceForEnvironment,l=e.r(795715),u=e.r(290487),c=e.r(638743),d=e.r(271645),h=(d.useDebugValue,d.useEffect),f=d.useMemo,p=d.useRef,g=d.useState,m=e.r(145003),y=m.__internal,v=y.fetchQuery,b=y.getPromiseForActiveRequest,_=m.RelayFeatureFlags,E=m.areEqualSelectors,S=m.createOperationDescriptor,x=m.getPendingOperationsForFragment,T=m.getSelector,w=m.getVariablesFromFragment,A=m.handlePotentialSnapshotErrors,R=m.recycleNodesInto;function I(e,t){if("bailout"===t.kind)return null;var r=e.getStore().getEpoch();if(r===t.epoch)return null;if("singular"===t.kind){var i=e.lookup(t.snapshot.selector),n=R(t.snapshot.data,i.data),s={data:n,isMissingData:i.isMissingData,missingClientEdges:i.missingClientEdges,missingLiveResolverFields:i.missingLiveResolverFields,seenRecords:i.seenRecords,selector:i.selector,fieldErrors:i.fieldErrors};return[n!==t.snapshot.data,{kind:"singular",snapshot:s,epoch:r}]}for(var a=!1,o=[],l=0;l<t.snapshots.length;l++){var u=t.snapshots[l],d=e.lookup(u.selector),h=R(u.data,d.data),f={data:h,isMissingData:d.isMissingData,missingClientEdges:d.missingClientEdges,missingLiveResolverFields:d.missingLiveResolverFields,seenRecords:d.seenRecords,selector:d.selector,fieldErrors:d.fieldErrors};h!==u.data&&(a=!0),o.push(f)}return o.length!==t.snapshots.length&&c(!1),[a,{kind:"plural",snapshots:o,epoch:r}]}function k(e,t){return null==t?{kind:"bailout"}:"PluralReaderSelector"===t.kind?{kind:"plural",snapshots:t.selectors.map(function(t){return e.lookup(t)}),epoch:e.getStore().getEpoch()}:{kind:"singular",snapshot:e.lookup(t),epoch:e.getStore().getEpoch()}}e.r(603158),t.exports=function(e,t,r,i){var d,m,y,R,C=f(function(){return T(e,t)},[e,t]),D=(null==e||null==(d=e.metadata)?void 0:d.plural)===!0;D?null==t||Array.isArray(t)||c(!1):Array.isArray(t)&&c(!1),null==t||D&&Array.isArray(t)&&0===t.length||null!=C||c(!1);var L=l();
1_.ENABLE_UI_CONTEXT_ON_RELAY_LOGGER&&(y=u());var O=g(function(){return k(L,C)}),P=O[0],F=O[1],N=P,M=g(N),j=M[0],$=M[1],U=j,B=g(C),V=B[0],G=B[1],q=g(L),H=q[0],z=q[1];if(!E(C,V)||L!==H){G(C),z(L);var K=k(L,C);F(K),$(K),N=K,U=K}var W=p(!1);if(h(function(){W.current=C},[C]),(null==(m=e.metadata)?void 0:m.hasClientEdges)===!0||_.CHECK_ALL_FRAGMENTS_FOR_MISSING_CLIENT_EDGES){var Y=f(function(){var r=function(e){if("bailout"===e.kind)return null;if("singular"===e.kind)return null!=(t=e.snapshot.missingClientEdges)?t:null;var t,r,i=null,n=(0,s.default)(e.snapshots);try{for(n.s();!(r=n.n()).done;){var a=r.value;if(a.missingClientEdges){i=null!=(o=i)?o:[];var o,l,u=(0,s.default)(a.missingClientEdges);try{for(u.s();!(l=u.n()).done;){var c=l.value;i.push(c)}}catch(e){u.e(e)}finally{u.f()}}}}catch(e){n.e(e)}finally{n.f()}return i}(N),a=[];if(null!=r&&r.length){var l,u=[],c=(0,s.default)(r);try{for(c.s();!(l=c.n()).done;){var d=l.value,h=function(e,t,r,i,s){var a=w(t,r),l=(0,n.default)((0,n.default)({},a),{},{id:i.clientEdgeDestinationID}),u=S(i.request,l,null==s?void 0:s.networkCacheConfig);return[o(e).prepare(u,v(e,u),null==s?void 0:s.fetchPolicy),b(e,u.request)]}(L,e,t,d,i),f=h[0],p=h[1];u.push(f),null!=p&&a.push(p)}}catch(e){c.e(e)}finally{c.f()}}return[u,a]},[N,L,e,t,i]),Q=Y[0],X=Y[1];if(X.length)throw Promise.all(X);h(function(){var e=o(L);if(null!=Q&&Q.length){var t,r=[],i=(0,s.default)(Q);try{for(i.s();!(t=i.n()).done;){var n=t.value;r.push(e.retain(n))}}catch(e){i.e(e)}finally{i.f()}return function(){for(var e=0;e<r.length;e++)r[e].dispose()}}},[L,Q])}if("bailout"!==(er=N).kind&&("singular"===er.kind?er.snapshot.isMissingData:er.snapshots.some(function(e){return e.isMissingData}))){var J=function(e){if("bailout"===e.kind)return null;if("singular"===e.kind)return null!=(t=e.snapshot.missingLiveResolverFields)?t:null;var t,r,i=null,n=(0,s.default)(e.snapshots);try{for(n.s();!(r=n.n()).done;){var a=r.value;if(a.missingLiveResolverFields){i=null!=(o=i)?o:[];var o,l,u=(0,s.default)(a.missingLiveResolverFields);try{for(u.s();!(l=u.n()).done;){var c=l.value;i.push(c)}}catch(e){u.e(e)}finally{u.f()}}}}catch(e){n.e(e)}finally{n.f()}return i}(N);if(null!=J&&J.length>0)throw Promise.all(J.map(function(e){return L.getStore().getLiveResolverPromise(e)}));if(_.ENABLE_RELAY_OPERATION_TRACKER_SUSPENSE||L!==H||!W.current||!E(W.current,C)){null==C&&c(!1);var Z=x(L,e,"PluralReaderSelector"===C.kind?C.selectors[0].owner:C.owner);if(Z)throw Z.promise}}var ee=N,et=y;if("singular"===ee.kind)A(L,ee.snapshot.fieldErrors,et);else if("plural"===ee.kind){var er,ei,en=(0,s.default)(ee.snapshots);try{for(en.s();!(ei=en.n()).done;){var es=ei.value;A(L,es.fieldErrors,et)}}catch(e){en.e(e)}finally{en.f()}}var ea=p(!1);if(h(function(){var e=U,t=I(L,U);if(null!==t){var r=t[0],i=t[1];r&&F(i),e=i}var n=e;if("bailout"===n.kind)return function(){};if("singular"===n.kind){var o=L.subscribe(n.snapshot,function(e){F(function(t){if("singular"!==t.kind||t.snapshot.selector!==e.selector){var r=I(L,t);if(null==r)return t;var i=r[0],n=r[1];return L.__log({name:"useFragment.subscription.missedUpdates",hasDataChanges:i}),ea.current=i,i?n:t}return ea.current=!0,{kind:"singular",snapshot:e,epoch:L.getStore().getEpoch()}})});return function(){o.dispose()}}var l=n.snapshots.map(function(e,t){return L.subscribe(e,function(e){F(function(r){if("plural"!==r.kind||(null==(i=r.snapshots[t])?void 0:i.selector)!==e.selector){var i,n=I(L,r);if(null==n)return r;var s=n[0],o=n[1];return L.__log({name:"useFragment.subscription.missedUpdates",hasDataChanges:s}),ea.current=ea.current||s,s?o:r}var l=(0,a.default)(r.snapshots);return l[t]=e,ea.current=!0,{kind:"plural",snapshots:l,epoch:L.getStore().getEpoch()}})})});return function(){var e,t=(0,s.default)(l);try{for(t.s();!(e=t.n()).done;)e.value.dispose()}catch(e){t.e(e)}finally{t.f()}}},[L,U]),ea.current){var eo=I(L,N);if(null!=eo){var el=eo[0],eu=eo[1];el&&(F(eu),N=eu)}ea.current=!1}if(D){var ec=null==t;R=f(function(){return"bailout"===N.kind?ec?null:[]:("plural"!==N.kind&&c(!1),N.snapshots.map(function(e){return e.data}))},[N,ec])}else"bailout"===N.kind?R=null:("singular"!==N.kind&&c(!1),R=N.snapshot.data);return _.LOG_MISSING_RECORDS_IN_PROD&&null!=t&&(void 0===R||Array.isArray(R)&&R.length>0&&R.every(function(e){return void 0===e})),R}},855595,(e,t,r)=>{"use strict";var i=e.r(13451).default,n=i(e.r(802953)),s=i(e.r(877913)),a=i(e.r(117675)),o=e.r(916426).getQueryResourceForEnvironment,l=e.r(795715),u=e.r(290487),c=e.r(638743),d=e.r(271645),h=(d.useDebugValue,d.useEffect),f=d.useMemo,p=d.useRef,g=d.useState,m=e.r(145003),y=m.__internal,v=y.fetchQuery,b=y.getPromiseForActiveRequest,_=m.RelayFeatureFlags,E=m.areEqualSelectors,S=m.createOperationDescriptor,x=m.getPendingOperationsForFragment,T=m.getSelector,w=m.getVariablesFromFragment,A=m.handlePotentialSnapshotErrors,R=m.recycleNodesInto;function I(e,t){if("bailout"===t.kind)return null;var r=e.getStore().getEpoch();if(r===t.epoch)return null;if("singular"===t.kind){var i=e.lookup(t.snapshot.selector),n=R(t.snapshot.data,i.data),s={data:n,isMissingData:i.isMissingData,missingClientEdges:i.missingClientEdges,missingLiveResolverFields:i.missingLiveResolverFields,seenRecords:i.seenRecords,selector:i.selector,fieldErrors:i.fieldErrors};return[n!==t.snapshot.data,{kind:"singular",snapshot:s,epoch:r,selector:t.selector,environment:t.environment}]}for(var a=!1,o=[],l=0;l<t.snapshots.length;l++){var u=t.snapshots[l],d=e.lookup(u.selector),h=R(u.data,d.data),f={data:h,isMissingData:d.isMissingData,missingClientEdges:d.missingClientEdges,missingLiveResolverFields:d.missingLiveResolverFields,seenRecords:d.seenRecords,selector:d.selector,fieldErrors:d.fieldErrors};h!==u.data&&(a=!0),o.push(f)}return o.length!==t.snapshots.length&&c(!1),[a,{kind:"plural",snapshots:o,epoch:r,selector:t.selector,environment:t.environment}]}function k(e,t,r){if("bailout"===t.kind)return function(){};if("singular"===t.kind){var i=e.subscribe(t.snapshot,function(i){r(function(r){var n=null;if("singular"!==r.kind||r.snapshot.selector!==i.selector||r.environment!==e){var s=I(r.environment,r);
1if(null!=s){var a=s[0],o=s[1];e.__log({name:"useFragment.subscription.missedUpdates",hasDataChanges:a}),n=a?o:r}else n=r}else n={kind:"singular",snapshot:i,epoch:e.getStore().getEpoch(),selector:t.selector,environment:t.environment};return n})});return function(){i.dispose()}}var n=t.snapshots.map(function(i,n){return e.subscribe(i,function(i){r(function(r){var s,o=null;if("plural"!==r.kind||(null==(s=r.snapshots[n])?void 0:s.selector)!==i.selector||r.environment!==e){var l=I(r.environment,r);if(null!=l){var u=l[0],c=l[1];e.__log({name:"useFragment.subscription.missedUpdates",hasDataChanges:u}),o=u?c:r}else o=r}else{var d=(0,a.default)(r.snapshots);d[n]=i,o={kind:"plural",snapshots:d,epoch:e.getStore().getEpoch(),selector:t.selector,environment:t.environment}}return o})})});return function(){var e,t=(0,s.default)(n);try{for(t.s();!(e=t.n()).done;)e.value.dispose()}catch(e){t.e(e)}finally{t.f()}}}function C(e,t){return null==t?{kind:"bailout",environment:e}:"PluralReaderSelector"===t.kind?{kind:"plural",snapshots:t.selectors.map(function(t){return e.lookup(t)}),epoch:e.getStore().getEpoch(),selector:t,environment:e}:{kind:"singular",snapshot:e.lookup(t),epoch:e.getStore().getEpoch(),selector:t,environment:e}}e.r(603158),t.exports=function(e,t,r,i){var a,d,m,y,R=f(function(){return T(e,t)},[e,t]),D=(null==e||null==(a=e.metadata)?void 0:a.plural)===!0;D?null==t||Array.isArray(t)||c(!1):Array.isArray(t)&&c(!1),null==t||D&&Array.isArray(t)&&0===t.length||null!=R||c(!1);var L=l();_.ENABLE_UI_CONTEXT_ON_RELAY_LOGGER&&(m=u());var O=g(function(){return C(L,R)}),P=O[0],F=O[1],N=P,M=N.environment;if(!E(R,N.selector)||L!==N.environment){var j=C(L,R);F(j),N=j}var $=p(!1);if(h(function(){$.current=R},[R]),(null==(d=e.metadata)?void 0:d.hasClientEdges)===!0||_.CHECK_ALL_FRAGMENTS_FOR_MISSING_CLIENT_EDGES){var U=f(function(){var r=function(e){if("bailout"===e.kind)return null;if("singular"===e.kind)return null!=(t=e.snapshot.missingClientEdges)?t:null;var t,r,i=null,n=(0,s.default)(e.snapshots);try{for(n.s();!(r=n.n()).done;){var a=r.value;if(a.missingClientEdges){i=null!=(o=i)?o:[];var o,l,u=(0,s.default)(a.missingClientEdges);try{for(u.s();!(l=u.n()).done;){var c=l.value;i.push(c)}}catch(e){u.e(e)}finally{u.f()}}}}catch(e){n.e(e)}finally{n.f()}return i}(N),a=[];if(null!=r&&r.length){var l,u=[],c=(0,s.default)(r);try{for(c.s();!(l=c.n()).done;){var d=l.value,h=function(e,t,r,i,s){var a=w(t,r),l=(0,n.default)((0,n.default)({},a),{},{id:i.clientEdgeDestinationID}),u=S(i.request,l,null==s?void 0:s.networkCacheConfig),c=o(e).prepare(u,v(e,u),null==s?void 0:s.fetchPolicy),d=b(e,u.request);return null!=d&&null==d.displayName&&(d.displayName=i.request.params.name),[c,d]}(L,e,t,d,i),f=h[0],p=h[1];u.push(f),null!=p&&a.push(p)}}catch(e){c.e(e)}finally{c.f()}}return[u,a]},[N,L,e,t,i]),B=U[0],V=U[1];if(V.length){var G=Promise.all(V);throw G.displayName="RelayClientEdge(".concat(V.map(function(e){return e.displayName}).join(","),")"),G}h(function(){var e=o(L);if(null!=B&&B.length){var t,r=[],i=(0,s.default)(B);try{for(i.s();!(t=i.n()).done;){var n=t.value;r.push(e.retain(n))}}catch(e){i.e(e)}finally{i.f()}return function(){for(var e=0;e<r.length;e++)r[e].dispose()}}},[L,B])}if("bailout"!==(Y=N).kind&&("singular"===Y.kind?Y.snapshot.isMissingData:Y.snapshots.some(function(e){return e.isMissingData}))){var q=function(e){if("bailout"===e.kind)return null;if("singular"===e.kind)return null!=(t=e.snapshot.missingLiveResolverFields)?t:null;var t,r,i=null,n=(0,s.default)(e.snapshots);try{for(n.s();!(r=n.n()).done;){var a=r.value;if(a.missingLiveResolverFields){i=null!=(o=i)?o:[];var o,l,u=(0,s.default)(a.missingLiveResolverFields);try{for(u.s();!(l=u.n()).done;){var c=l.value;i.push(c)}}catch(e){u.e(e)}finally{u.f()}}}}catch(e){n.e(e)}finally{n.f()}return i}(N);if(null!=q&&q.length>0){var H=Promise.all(q.map(function(e){return L.getStore().getLiveResolverPromise(e)}));throw H.displayName="RelayLiveResolver("+e.name+")",H}if(_.ENABLE_RELAY_OPERATION_TRACKER_SUSPENSE||L!==M||!$.current||!E($.current,R)){null==R&&c(!1);var z=x(L,e,"PluralReaderSelector"===R.kind?R.selectors[0].owner:R.owner);if(z)throw z.promise}}var K=N,W=m;if("singular"===K.kind)A(L,K.snapshot.fieldErrors,W);else if("plural"===K.kind){var Y,Q,X=(0,s.default)(K.snapshots);try{for(X.s();!(Q=X.n()).done;){var J=Q.value;A(L,J.fieldErrors,W)}}catch(e){X.e(e)}finally{X.f()}}var Z=p(null);if(h(function(){var e=Z.current;if(null!=e)if(N.environment===e.environment&&N.selector===e.selector)return;else e.dispose();if("bailout"!==N.kind){var t=N,r=I(N.environment,N);if(null!==r){var i=r[0],n=r[1];if(i)return void F(n);t=n}Z.current={dispose:k(N.environment,t,F),selector:N.selector,environment:N.environment}}},[N]),h(function(){return null==Z.current&&"bailout"!==N.kind&&(Z.current={dispose:k(N.environment,N,F),selector:N.selector,environment:N.environment}),function(){var e;null==(e=Z.current)||e.dispose(),Z.current=null}},[]),D){var ee=null==t;y=f(function(){return"bailout"===N.kind?ee?null:[]:("plural"!==N.kind&&c(!1),N.snapshots.map(function(e){return e.data}))}
1,[N,ee])}else"bailout"===N.kind?y=null:("singular"!==N.kind&&c(!1),y=N.snapshot.data);return _.LOG_MISSING_RECORDS_IN_PROD&&null!=t&&(void 0===y||Array.isArray(y)&&y.length>0&&y.every(function(e){return void 0===e})),y}},164945,(e,t,r)=>{"use strict";var i=e.r(13451).default,n=i(e.r(465718)),s=i(e.r(855595)),a=e.r(145003);t.exports=function(e,t,r,i){return a.RelayFeatureFlags.ENABLE_ACTIVITY_COMPATIBILITY?(0,s.default)(e,t,r,i):(0,n.default)(e,t,r,i)}},466985,(e,t,r)=>{"use strict";var i=e.r(609700),n=e.r(916426),s=n.getQueryCacheIdentifier,a=n.getQueryResourceForEnvironment,o=e.r(735699),l=e.r(164945),u=e.r(795715),c=e.r(271645),d=c.useContext,h=c.useEffect,f=c.useState,p=c.useRef;t.exports=function(e){var t=e.query,r=e.componentDisplayName,n=e.fetchObservable,c=e.fetchPolicy,g=e.fetchKey,m=e.renderPolicy,y=u(),v=d(i),b=a(y),_=f(0),E=_[0],S=_[1],x=o(),T=x.startFetch,w=x.completeFetch,A=s(y,t,c,m,"".concat(E,"-").concat(null!=g?g:"")),R=v.wrapPrepareQueryResource(function(){return b.prepareWithIdentifier(A,t,n,c,m,{start:T,complete:w,error:w},v)}),I=p(!1);return h(function(){return function(){I.current=!0}},[]),h(function(){if(!0===I.current){I.current=!1,S(function(e){return e+1});return}var e=b.retain(R,v);return function(){e.dispose()}},[y,A]),h(function(){b.releaseTemporaryRetain(R)}),l(R.fragmentNode,R.fragmentRef,r)}},759533,(e,t,r)=>{"use strict";var i=e.r(832780),n=e.r(271645).useState;t.exports=function(e){var t=n(e),r=t[0],s=t[1];return i(e,r)?r:(s(e),e)}},399437,(e,t,r)=>{"use strict";var i=e.r(759533),n=e.r(271645),s=e.r(145003),a=s.createOperationDescriptor,o=s.getRequest,l=n.useMemo;t.exports=function(e,t,r){var n=i(t),s=i(r||{});return l(function(){return a(o(e),n,s)},[e,n,s])}},302096,(e,t,r)=>{"use strict";var i=e.r(466985),n=e.r(399437),s=e.r(795715),a=e.r(145003).__internal.fetchQuery;t.exports=function(e,t,r){var o=s(),l=n(e,t,r&&r.networkCacheConfig?r.networkCacheConfig:{force:!0});return i({componentDisplayName:"useLazyLoadQuery()",fetchKey:null==r?void 0:r.fetchKey,fetchObservable:a(o,l),fetchPolicy:null==r?void 0:r.fetchPolicy,query:l,renderPolicy:null==r?void 0:r.UNSTABLE_renderPolicy})}},181591,(e,t,r)=>{"use strict";var i=(0,e.r(13451).default)(e.r(802953)),n=e.r(302096);t.exports=function(e,t,r){return n(e,t,(0,i.default)((0,i.default)({},r),{},{fetchPolicy:"store-only"}))}},37546,(e,t,r)=>{"use strict";var i=e.r(271645),n=i.useEffect,s=i.useRef;t.exports=function(){var e=s(!0);return n(function(){return e.current=!0,function(){e.current=!1}},[]),e}},836204,(e,t,r)=>{"use strict";var i=(0,e.r(13451).default)(e.r(877913)),n=e.r(5670),s=e.r(37546),a=e.r(271645),o=a.useCallback,l=a.useEffect,u=a.useRef,c=a.useState,d={kind:"NullEntryPointReference"};t.exports=function(e,t,r){var a,h,f,p,g=null!=(a=null==r||null==(h=r.TEST_ONLY__initialEntryPointData)?void 0:h.entryPointReference)?a:d,m=null!=(f=null==r||null==(p=r.TEST_ONLY__initialEntryPointData)?void 0:p.entryPointParams)?f:null,y=s(),v=u(new Set([g])),b=c(g),_=b[0],E=b[1],S=c(m),x=S[0],T=S[1],w=o(function(){if(y.current){var e={kind:"NullEntryPointReference"};v.current.add(e),E(e)}},[E,y]),A=o(function(r){if(y.current){var i=n(e,t,r);v.current.add(i),E(i),T(r)}},[e,t,E,y]),R=u(!1);return l(function(){return function(){R.current=!0}},[]),l(function(){if(!0===R.current){R.current=!1,"NullEntryPointReference"!==_.kind&&null!=x&&A(x);return}var e=v.current;if(y.current){var t,r=(0,i.default)(e);try{for(r.s();!(t=r.n()).done;){var n=t.value;if(n===_)break;e.delete(n),"NullEntryPointReference"!==n.kind&&n.dispose()}}catch(e){r.e(e)}finally{r.f()}}},[_,x,A,y]),l(function(){return function(){var e,t=(0,i.default)(v.current);try{for(t.s();!(e=t.n()).done;){var r=e.value;"NullEntryPointReference"!==r.kind&&r.dispose()}}catch(e){t.e(e)}finally{t.f()}}},[]),["NullEntryPointReference"===_.kind?null:_,A,w]}},266343,(e,t,r)=>{"use strict";e.r(551261),e.r(603158),t.exports=function(e,t){}},444966,(e,t,r)=>{"use strict";var i=e.r(164945),n=e.r(266343);e.r(271645).useDebugValue;var s=e.r(145003).getFragment;t.exports=function(e,t){var r=s(e);return n(r,"first argument of useFragment()"),i(r,t,"useFragment()")}},662283,(e,t,r)=>{"use strict";var i=(0,e.r(13451).default)(e.r(802953)),n=e.r(37546),s=e.r(795715),a=e.r(271645),o=e.r(145003).commitMutation,l=a.useState,u=a.useEffect,c=a.useRef,d=a.useCallback;t.exports=function(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:o,r=s(),a=n(),h=c(r),f=c(e),p=c(new Set),g=l(!1),m=g[0],y=g[1],v=d(function(t){h.current===r&&f.current===e&&(p.current.delete(t),a.current&&y(p.current.size>0))},[r,a,e]);return u(function(){(h.current!==r||f.current!==e)&&(p.current=ne
1w Set,a.current&&y(!1),h.current=r,f.current=e)},[r,a,e]),[d(function(n){a.current&&y(!0);var s=t(r,(0,i.default)((0,i.default)({},n),{},{mutation:e,onCompleted:function(e,t){var r;v(s),null==(r=n.onCompleted)||r.call(n,e,t)},onError:function(e){var t;v(s),null==(t=n.onError)||t.call(n,e)},onUnsubscribe:function(){var e;v(s),null==(e=n.onUnsubscribe)||e.call(n)},onNext:function(){var e;null==(e=n.onNext)||e.call(n)}}));return p.current.add(s),s},[v,t,r,a,e]),m]}},851634,(e,t,r)=>{"use strict";var i=e.r(638743),n=e.r(145003),s=n.ConnectionInterface,a=n.getValueAtPath;t.exports=function(e,t,r,n){var o,l,u,c=s.get(),d=c.EDGES,h=c.PAGE_INFO,f=c.HAS_NEXT_PAGE,p=c.HAS_PREV_PAGE,g=c.END_CURSOR,m=c.START_CURSOR,y=a(r,n);if(null==y)return{cursor:null,hasMore:!1};"object"!=typeof y&&i(!1);var v=y[d],b=y[h];if(null==v||null==b)return{cursor:null,hasMore:!1};Array.isArray(v)||i(!1),"object"!=typeof b&&i(!1);var _="forward"===e?null!=(o=b[g])?o:null:null!=(l=b[m])?l:null;return null!==_&&"string"!=typeof _&&i(!1),u="forward"===e?null!=_&&!0===b[f]:null!=_&&!0===b[p],{cursor:_,hasMore:u}}},739235,(e,t,r)=>{"use strict";var i=e.r(795715),n=e.r(638743),s=e.r(271645),a=e.r(145003),o=a.__internal.getObservableForActiveRequest,l=a.getSelector,u=s.useEffect,c=s.useState,d=s.useMemo;t.exports=function(e,t){var r=i(),s=d(function(){var i=l(e,t);return null==i?null:("SingularReaderSelector"!==i.kind&&n(!1),o(r,i.owner))},[r,e,t]),a=c(null!=s),h=a[0],f=a[1];return u(function(){var e;if(f(null!=s),null!=s){var t=function(){f(!1)};e=s.subscribe({complete:t,error:t})}return function(){e&&e.unsubscribe()}},[s]),h}},289821,(e,t,r)=>{"use strict";var i=(0,e.r(13451).default)(e.r(802953)),n=e.r(851634),s=e.r(37546),a=e.r(739235),o=e.r(795715),l=e.r(638743),u=e.r(271645),c=u.useCallback,d=u.useRef,h=u.useState,f=e.r(145003),p=f.__internal.fetchQuery,g=f.createOperationDescriptor,m=f.getPaginationVariables,y=f.getRefetchMetadata,v=f.getSelector;e.r(603158),t.exports=function(e){var t=e.direction,r=e.fragmentNode,u=e.fragmentRef,f=e.fragmentIdentifier,b=e.fragmentData,_=e.connectionPathInFragmentData,E=e.paginationRequest,S=e.paginationMetadata,x=e.componentDisplayName,T=e.observer,w=e.onReset,A=o(),R=y(r,x).identifierInfo,I=(null==R?void 0:R.identifierField)!=null&&null!=b&&"object"==typeof b?b[R.identifierField]:null,k=d({kind:"none"}),C=h(A),D=C[0],L=C[1],O=h(f),P=O[0],F=O[1],N=a(r,u),M=c(function(){"fetching"===k.current.kind&&k.current.subscription.unsubscribe(),k.current={kind:"none"}},[]);(A!==D||f!==P)&&(M(),w(),L(A),F(f));var j=n(t,r,b,_),$=j.cursor,U=j.hasMore,B=null==b||N,V=s();return[c(function(e,n){var s=null==n?void 0:n.onComplete;if(!0!==V.current)return{dispose:function(){}};var a=v(r,u);if("fetching"===k.current.kind||B)return s&&s(null),{dispose:function(){}};(null==a||"PluralReaderSelector"===a.kind)&&l(!1);var o=a.owner.variables,c=a.variables,d=null==n?void 0:n.UNSTABLE_extraVariables,h=m(t,e,$,(0,i.default)((0,i.default)({},o),c),(0,i.default)({},d),S);return null!=R&&(h[R.identifierQueryVariableName]=I),p(A,g(E,h,{force:!0})).subscribe((0,i.default)((0,i.default)({},T),{},{start:function(e){k.current={kind:"fetching",subscription:e},T.start&&T.start(e)},complete:function(){k.current={kind:"none"},T.complete&&T.complete(),s&&s(null)},error:function(e){k.current={kind:"none"},T.complete&&T.complete(),s&&s(e)}})),{dispose:function(){}}},[A,I,t,$,B,r.name,u,x]),U,M]}},437156,(e,t,r)=>{"use strict";var i=(0,e.r(13451).default)(e.r(802953)),n=e.r(851634),s=e.r(735699),a=e.r(37546),o=e.r(739235),l=e.r(289821),u=e.r(795715),c=e.r(638743),d=e.r(271645),h=d.useCallback,f=d.useEffect,p=d.useState,g=e.r(145003),m=g.__internal.fetchQuery,y=g.RelayFeatureFlags,v=g.createOperationDescriptor,b=g.getPaginationVariables,_=g.getRefetchMetadata,E=g.getSelector;e.r(603158),t.exports=function(e){var t,r,d,g,S,x,T,w,A,R,I,k,C,D,L,O,P,F,N,M,j,$,U,B,V,G,q,H,z,K,W,Y;return y.ENABLE_ACTIVITY_COMPATIBILITY?l(e):(r=(t=e).direction,d=t.fragmentNode,g=t.fragmentRef,S=t.fragmentIdentifier,x=t.fragmentData,T=t.connectionPathInFragmentData,w=t.paginationRequest,A=t.paginationMetadata,R=t.componentDisplayName,I=t.observer,k=t.onReset,C=u(),L=(D=s()).isFetchingRef,O=D.startFetch,P=D.disposeFetch,F=D.completeFetch,M=(null==(N=_(d,R).identifierInfo)?void 0:N.identifierField)!=null&&null!=x&&"object"==typeof x?x[N.identifierField]:null,j=a(),U=($=p(C))[0],B=$[1],G=(V=p(S))[0],q=V[1],H=o(d,g),
1(C!==U||S!==G)&&(P(),k(),B(C),q(S)),K=(z=n(r,d,x,T)).cursor,W=z.hasMore,f(function(){return function(){P()}},[P]),[h(function(e,t){var n=null==t?void 0:t.onComplete;if(!0!==j.current)return{dispose:function(){}};var s=E(d,g);if(!0===L.current||Y)return n&&n(null),{dispose:function(){}};(null==s||"PluralReaderSelector"===s.kind)&&c(!1);var a=s.owner.variables,o=s.variables,l=null==t?void 0:t.UNSTABLE_extraVariables,u=b(r,e,K,(0,i.default)((0,i.default)({},a),o),(0,i.default)({},l),A);return null!=N&&(u[N.identifierQueryVariableName]=M),m(C,v(w,u,{force:!0})).subscribe((0,i.default)((0,i.default)({},I),{},{start:function(e){O(e),I.start&&I.start(e)},complete:function(){F(),I.complete&&I.complete(),n&&n(null)},error:function(e){F(),I.error&&I.error(e),n&&n(e)}})),{dispose:P}},[C,M,r,K,O,P,F,L,Y=null==x||H,d.name,g,R]),W,P])}},942460,(e,t,r)=>{"use strict";var i=e.r(13451).default,n=i(e.r(802953)),s=i(e.r(877913)),a=e.r(916426).getQueryResourceForEnvironment,o=e.r(638743),l=e.r(145003),u=l.__internal.fetchQuery,c=l.RelayFeatureFlags,d=l.createOperationDescriptor,h=l.getPendingOperationsForFragment,f=l.getSelector,p=l.getVariablesFromFragment,g=l.handlePotentialSnapshotErrors;e.r(603158),t.exports=function(e,t,r,i,l,m){var y,v=f(t,r),b=(null==t||null==(w=t.metadata)?void 0:w.plural)===!0;b?null==r||Array.isArray(r)||o(!1):Array.isArray(r)&&o(!1),null==r||b&&Array.isArray(r)&&0===r.length||null!=v||o(!1);var _=(x=e,null==(T=v)?{kind:"bailout"}:"PluralReaderSelector"!==T.kind?{kind:"singular",snapshot:x.lookup(T),epoch:x.getStore().getEpoch()}:0===T.selectors.length?{kind:"bailout"}:{kind:"plural",snapshots:T.selectors.map(function(e){return x.lookup(e)}),epoch:x.getStore().getEpoch()}),E=null;if((null==(A=t.metadata)?void 0:A.hasClientEdges)===!0||c.CHECK_ALL_FRAGMENTS_FOR_MISSING_CLIENT_EDGES){var S=function(e){if("bailout"===e.kind)return null;if("singular"===e.kind)return null!=(t=e.snapshot.missingClientEdges)?t:null;var t,r,i=null,n=(0,s.default)(e.snapshots);try{for(n.s();!(r=n.n()).done;){var a=r.value;if(a.missingClientEdges){i=null!=(o=i)?o:[];var o,l,u=(0,s.default)(a.missingClientEdges);try{for(u.s();!(l=u.n()).done;){var c=l.value;i.push(c)}}catch(e){u.e(e)}finally{u.f()}}}}catch(e){n.e(e)}finally{n.f()}return i}(_);if(null!=S&&S.length){E=[];var x,T,w,A,R,I=(0,s.default)(S);try{for(I.s();!(R=I.n()).done;){var k=R.value;E.push(function(e,t,r,i,s){var o=p(t,r),l=(0,n.default)((0,n.default)({},o),{},{id:i.clientEdgeDestinationID}),c=d(i.request,l,null==s?void 0:s.networkCacheConfig);return a(e).prepare(c,u(e,c),null==s?void 0:s.fetchPolicy)}(e,t,r,k,l))}}catch(e){I.e(e)}finally{I.f()}}}if("bailout"!==_.kind&&("singular"===_.kind?_.snapshot.isMissingData:_.snapshots.some(function(e){return e.isMissingData}))){null==v&&o(!1);var C=h(e,t,"PluralReaderSelector"===v.kind?v.selectors[0].owner:v.owner);if(C)throw C.promise;if("singular"===_.kind)g(e,_.snapshot.fieldErrors);else if("plural"===_.kind){var D,L=(0,s.default)(_.snapshots);try{for(L.s();!(D=L.n()).done;){var O=D.value;g(e,O.fieldErrors)}}catch(e){L.e(e)}finally{L.f()}}}return y="bailout"===_.kind?b?[]:null:"singular"===_.kind?_.snapshot.data:_.snapshots.map(function(e){return e.data}),c.LOG_MISSING_RECORDS_IN_PROD&&null!=r&&(void 0===y||Array.isArray(y)&&y.length>0&&y.every(function(e){return void 0===e})),{data:y,clientEdgeQueries:E}}},718210,(e,t,r)=>{"use strict";var i=(0,e.r(13451).default)(e.r(877913)),n=e.r(335630).loadQuery,s=e.r(37546),a=e.r(795715),o=e.r(271645),l=o.useCallback,u=o.useEffect,c=o.useInsertionEffect,d=o.useRef,h=o.useState,f=e.r(145003).getRequest,p={kind:"NullQueryReference"};t.exports=function(e,t){var r,o=null!=t?t:p,g=a(),m=s(),y=d(null);null==y.current&&(y.current=new Set([o]));var v=h(function(){return o}),b=v[0],_=v[1],E=h(function(){return o}),S=E[0],x=E[1];o!==S&&(null==(r=y.current)||r.add(o),x(o),_(o));var T=l(function(){if(m.current){var e;null==(e=y.current)||e.add(p),_(p)}},[m]),w=l(function(t,r){if(m.current){var i,s,a=null!=r&&r.hasOwnProperty("__environment")?{fetchPolicy:r.fetchPolicy,networkCacheConfig:r.networkCacheConfig,__nameForWarning:r.__nameForWarning}:r,o=n(null!=(i=null==r?void 0:r.__environment)?i:g,e,t,a);null==(s=y.current)||s.add(o),_(o)}},[g,e,_,m]),A=l(function(e,t){var r,n,s=null!=(r=y.current)?r:new Set,a=(0,i.default)(s);try{for(a.s();!(n=a.n()).done;){var o=n.value;o!==t&&"NullQueryReference"!==o.kind&&(("PreloadableConcreteRequest"===e.kind?void 0!==e.params.metadata.live:void 0!==f(e).params.metadata.live)?o.dispose&&o.dispose():o.releaseQuery&&o.releaseQuery())}}catch(e){a.e(e)}finally{a.f()}},[]),R=d(null);return u(function(){return A(e,b),null!=R.current&&(clearTimeout(R.current),R.current=null),function(){R.current=setTimeout(function(){A(e,null)},3e5)}},[e,b]),c(function(){return function(){R.current&&clearTimeout(R.current),R.current=null,A(e,null)}},[e]),["NullQueryReference"===b.kind?null:b,w,T]}},38150,(e,t,r)=>{"use strict";var i=(0,e.r(13451).default)(e.r(877913)),n=e.r(335630).loadQuery,s=e.r(37546),a=e.r(718210),o=e.r(795715),l=e.r(271645),u=l.useCallback,c=l.useEffect,d=l.useRef,h=l.useState,f=e.r(145003),p=f.RelayFeatureFlags,g=f.getRequest,m={kind:"NullQueryReference"};function y(e){return"PreloadableConcreteRequest"===e.kind?void 0!==e.params.metadata.live:void 0!==g(e).params.metadata.live}t.exports=function(e,t){var r,l,f,g,v,b,_,E,S,x,T,w,A,R,I;return p.ENABLE_ACTIVITY_COMPATIBILITY?a(e,t):(r=e,f=null!=(l=t)?l:m,g=o(),v=s(),b=d(new Set([f])),E=(_=h(function(){return f}))[0],S=_[1],T=(x=h(function(){return f}))[0],w=x[1],f!==T&&(b.current.add(f),w(f),S(f)),A=u(function(){v.current&&(b.current.add(m),S(m))},[v]),R=u(function(e,t){var i=null!=t&&t.hasOwnProperty("__environment")?{fetchPolicy:t.fetchPolicy,networkCacheConfig:t.networkCacheConfig,__nameForWarning:t.__nameForWarning}:t;if(v.current){var s,a=n(null!=(s=null==t?void 0:t.__environment)?s:g,r,e,i);b.current.add(a),S(a)}},[g,r,S,v]),I=d(!1),c(function(){return function(){I.current=!0}},[]),c(function(){if(!0===I.current){I.current=!1,"NullQueryReference"!==E.kind&&R(E.variables,{fetchPolicy:E.fetchPolicy,networkCacheConfig:E.networkCacheConfig});return}var e=b.current;if(v.current){var t,n=(0,i.default)(e);try{for(n.s();!(t=n.n()).done;){var s=t.value;if(s===E)break;e.delete(s),"NullQueryReference"!==s.kind&&(y(r)?s.dispose&&s.dispose():s.releaseQuery&&s.releaseQuery())}}catch(e){n.e(e)}finally{n.f()}}},[E,v,R,r]),c(function(){return function(){var e,t=(0,i.default)(b.current);try{for(t.s();!(e=t.n()).done;){var n=e.value;"NullQueryReference"!==n.kind&&(y(r)?n.dispose&&n.dispose():n.releaseQuery&&n.releaseQuery())}}catch(e){t.e(e)}finally{t.f()}}},[r]),["NullQueryReference"===E.kind?null:E,R,A])}},798409,(e,t,r)=>{"use strict";var i=(0,e.r(13451).default)(e.r(802953)),n=e.r(609700),s=e.r(916426).getQueryResourceForEnvironment,a=e.r(942460),o=e.r(164945),l=e.r(37546),u=e.r(38150),c=e.r(795715),d=e.r(638743),h=e.r(271645),f=h.useCallback,p=h.useContext,g=h.useReducer,m=e.r(145003),y=m.__internal.fetchQuery,v=m.createOperationDescriptor,b=m.getFragmentIdentifier,_=m.getRefetchMetadata,E=m.getSelector,S=m.getValueAtPath;function x(e,t){switch(t.type){case"refetch":var r;return(0,i.default)((0,i.default)({},e),{},{fetchPolicy:t.fetchPolicy,mirroredEnvironment:null!=(r=t.refetchEnvironment)?r:e.mirroredEnvironment,onComplete:t.onComplete,refetchEnvironment:t.refetchEnvironment,refetchQuery:t.refetchQuery,renderPolicy:t.renderPolicy});case"reset":return{fetchPolicy:void 0,mirroredEnvironment:t.environment,mirroredFragmentIdentifier:t.fragmentIdentifier,onComplete:void 0,refetchQuery:null,renderPolicy:void 0};default:throw t.type,Error("useRefetchableFragmentNode: Unexpected action type")}}e.r(603158),t.exports=function(e,t,r){var h,m,T,w,A,R,I,k,C,D,L,O=c(),P=_(e,r),F=P.refetchableRequest,N=P.fragmentRefPathInResponse,M=P.identifierInfo,j=b(e,t),$=g(x,{fetchPolicy:void 0,mirroredEnvironment:O,mirroredFragmentIdentifier:j,onComplete:void 0,refetchEnvironment:null,refetchQuery:null,renderPolicy:void 0}),U=$[0],B=$[1],V=U.fetchPolicy,G=U.mirroredEnvironment,q=U.mirroredFragmentIdentifier,H=U.onComplete,z=U.refetchEnvironment,K=U.refetchQuery,W=U.renderPolicy,Y=null!=z?z:O,Q=s(Y),X=p(n),J=Y!==G||j!==q,Z=u(F),ee=Z[0],et=Z[1],er=Z[2],ei=t;if(J)B({type:"reset",environment:Y,fragmentIdentifier:j}),er();else if(null!=K&&null!=ee){var en=function(e){H&&H(null!=e?e:null)},es=null!=ee.source?ee.source:y(Y,K),ea=X.wrapPrepareQueryResource(function(){return Q.prepare(K,es,V,W,{error:en,complete:function(){en()}},ee.fetchKey,X)}),eo=a(Y,ea.fragmentNode,ea.fragmentRef,r).data;null==eo&&d(!1),ei=S(eo,N)}var el=o(e,ei,r),eu=(h=B,m=er,T=el,w=j,A=e,R=M,I=et,k=t,C=F,D=l(),f(function(e,t){if(!0!==D.current)return{dispose:function(){}};var r,n,s,a,o,l,u=null==t?void 0:t.__environment,c=null==t?void 0:t.fetchPolicy,d=null==t?void 0:t.UNSTABLE_renderPolicy,f=null==t?void 0:t.onComplete,p=E(A,k);null==p?(r={},n={}):"PluralReaderSelector"===p.kind?(r=null!=(s=null==(a=p.selectors[0])?void 0:a.owner.variables)?s:{},n=null!=(o=null==(l=p.selectors[0])?void 0:l.variables)?o:{}):(r=p.owner.variables,n=p.variables);var g=(0,i.default)((0,i.default)((0,i.default)({},r),n),e);null==R||e.hasOwnProperty(R.identifierQueryVariableName)||(g[R.identifierQueryVariableName]=L);var y=v(C,g,{force:!0});return I(y.request.variables,{fetchPolicy:c,__environment:u,__nameForWarning:"refetch"}),h({type:"refetch",fetchPolicy:c,onComplete:f,refetchEnvironment:u,refetchQuery:y,renderPolicy:d}),{dispose:m}},[w,h,m,L=(null==R?void 0:R.identifierField)!=null&&null!=T&&"object"==typeof T?T[R.identifierField]:null,I]));return{fragmentData:el,fragmentRef:ei,refetch:eu}}},280380,(e,t,r)=>{"use strict";var i=(0,e.r(13451).default)(e.r(802953)),n=e.r(437156),s=e.r(798409),a=e.r(795715),o=e.r(266343),l=e.r(271645),u=l.useCallback,c=(l.useDebugValue,l.useState),d=e.r(145003),h=d.RelayFeatureFlags,f=d.getFragment,p=d.getFragmentIdentifier,g=d.getPaginationMetadata;function m(e){var t=a(),r=c(!1),s=r[0],o=r[1],l=function(e){var r,i=null==(r=t.getScheduler())?void 0:r.schedule;i?i(function(){o(e)}):o(e)},u={start:function(){return l(!0)},complete:function(){return l(!1)},error:function(){return l(!1)},unsubscribe:h.ENABLE_USE_PAGINATION_IS_LOADING_FIX?function(){return l(!1)}:void 0},d=n((0,i.default)((0,i.default)({},e),{},{observer:u,onReset:function(){return l(!1)}}));return[d[0],d[1],s,d[2]]}t.exports=function(e,t){var r=f(e);o(r,"first argument of usePaginationFragment()");var n="usePaginationFragment()",a=g(r,n),l=a.connectionPathInFragmentData,c=a.paginationRequest,d=a.paginationMetadata,h=s(r,t,n),y=h.fragmentData,v=h.fragmentRef,b=h.refetch,_=p(r,v),E=m({componentDisplayName:n,connectionPathInFragmentData:l,direction:"backward",fragmentData:y,fragmentIdentifier:_,fragmentNode:r,fragmentRef:v,paginationMetadata:d,paginationRequest:c}),S=E[0],x=E[1],T=E[2],w=E[3],A=m({componentDisplayName:n,connectionPathInFragmentData:l,direction:"forward",fragmentData:y,fragmentIdentifier:_,fragmentNode:r,fragmentRef:v,paginationMetadata:d,paginationRequest:c}),R=A[0],I=A[1],k=A[2],C=A[3];return{data:y,loadNext:R,loadPrevious:S,hasNext:I,hasPrevious:x,isLoadingNext:k,isLoadingPrevious:T,refetch:u(function(e,t){return C(),w(),b(e,(0,i.default)((0,i.default)({},t),{},{__environment:void 0}))},[C,w,b])}}},942268,(e,t,r)=>{"use strict";var i=(0,e.r(13451).default)(e.r(802953)),n=e.r(444966),s=e.r(437156),a=e.r(798409),o=e.r(795715),l=e.r(266343),u=e.r(638743),
1c=e.r(271645),d=c.useCallback,h=(c.useDebugValue,c.useEffect),f=c.useLayoutEffect,p=c.useMemo,g=c.useRef,m=c.useState,y=e.r(145003),v=y.getFragment,b=y.getFragmentIdentifier,_=y.getPaginationMetadata,E=e.r(145003),S=E.ConnectionInterface,x=E.RelayFeatureFlags,T=E.getSelector,w=E.getValueAtPath;t.exports=function(e,t,r,c,y){var E,A,R=arguments.length>5&&void 0!==arguments[5]?arguments[5]:1,I=arguments.length>6&&void 0!==arguments[6]&&arguments[6],k=v(e);l(k,"first argument of usePrefetchableForwardPaginationFragment()");var C="usePrefetchableForwardPaginationFragment()",D=_(k,C),L=D.connectionPathInFragmentData,O=D.paginationRequest,P=D.paginationMetadata,F=a(k,t,C),N=F.fragmentData,M=F.fragmentRef,j=F.refetch,$=b(k,M),U=p(function(){var e=w(N,L);return null==e?null:e[S.get().EDGES]},[L,N]),B=null==U?-1:U.length,V=m(null!=c?c:B),G=V[0],q=V[1],H=G;-1===G&&-1!==B&&q(H=null!=c?c:B);var z=o(),K=m(!1),W=K[0],Y=K[1],Q=m(!1),X=Q[0],J=Q[1],Z=g(0),ee=d(function(e){var t,r=null==(t=z.getScheduler())?void 0:t.schedule;r?r(function(){Y(e)}):Y(e)},[z]),et=g(!1),er=s({componentDisplayName:C,connectionPathInFragmentData:L,direction:"forward",fragmentData:N,fragmentIdentifier:$,fragmentNode:k,fragmentRef:M,paginationMetadata:P,paginationRequest:O,observer:p(function(){function e(){et.current=!1,ee(!1)}return{start:function(){et.current=!0,Y(!0)},complete:e,error:e,unsubscribe:x.ENABLE_USE_PAGINATION_IS_LOADING_FIX?e:void 0}},[ee]),onReset:d(function(){if(!X){var e,t=null==(e=z.getScheduler())?void 0:e.schedule;t?t(function(){q(-1)}):q(-1)}et.current=!1,ee(!1)},[z,X,ee])}),ei=er[0],en=er[1],es=er[2];f(function(){Z.current=B-H},[H,B]);var ea=null==y?void 0:y.UNSTABLE_extraVariables,eo=null==y?void 0:y.onComplete,el=d(function(e,t){(!et.current||Z.current>=0)&&(Z.current-=e,q(function(t){return t+e}),!et.current&&Z.current<0&&ei(Math.max(R,Math.min(e,r-Z.current)),null!=t?t:{onComplete:eo,UNSTABLE_extraVariables:"function"==typeof ea?ea({hasNext:en,data:N,getServerEdges:function(){var e=T(eu,U);return null==e?[]:("PluralReaderSelector"!==e.kind&&u(!1),e.selectors.map(function(e){return z.lookup(e).data}))}}):ea}))},[r,ei,R,U,N,ea,eo]),eu=null==(E=e.metadata)||null==(A=E.refetch)?void 0:A.edgesFragment;null==eu&&u(!1),h(function(){et.current||W||X||I||!en||!(B-H<r)&&!(H>B)||ei(Math.max(r-Math.max(B-H,0),H-B,R),{onComplete:eo,UNSTABLE_extraVariables:"function"==typeof ea?ea({hasNext:en,data:N,getServerEdges:function(){var e=T(eu,U);return null==e?[]:("PluralReaderSelector"!==e.kind&&u(!1),e.selectors.map(function(e){return z.lookup(e).data}))}}):ea})},[en,r,X,ei,H,ea,eo,B,U,W,R,z,eu]);var ec=Math.min(H,B),ed=n(eu,p(function(){var e;return null!=(e=null==U?void 0:U.slice(0,ec))?e:[]},[U,ec])),eh=d(function(e,t){return es(),J(!0),j(e,(0,i.default)((0,i.default)({},t),{},{onComplete:function(e){var r,i,n=null==(r=z.getScheduler())?void 0:r.schedule;n?n(function(){J(!1),q(-1)}):(J(!1),q(-1)),null==t||null==(i=t.onComplete)||i.call(t,e)},__environment:void 0}))},[es,z,j]);return{edges:ed,data:N,loadNext:el,hasNext:en||B>H,isLoadingNext:W&&H>B,refetch:eh}}},121937,(e,t,r)=>{"use strict";var i=e.r(466985),n=e.r(399437),s=e.r(795715),a=e.r(638743);e.r(271645).useDebugValue;var o=e.r(145003).__internal,l=o.fetchQueryDeduped,u=o.fetchQuery;e.r(603158),t.exports=function(e,t,r){var o=s(),c=t.fetchKey,d=t.fetchPolicy,h=t.source,f=n(e,t.variables,t.networkCacheConfig);if("PreloadedQuery_DEPRECATED"===t.kind)f.request.node.params.name!==t.name&&a(!1),p={componentDisplayName:"usePreloadedQuery()",fetchKey:c,fetchObservable:l(o,f.request.identifier,function(){return o===t.environment&&null!=h?o.executeWithSource({operation:f,source:h}):o.execute({operation:f})}),fetchPolicy:d,query:f,renderPolicy:null==r?void 0:r.UNSTABLE_renderPolicy};else{var p,g,m=u(o,f);null!=h&&o===t.environment?g=h.ifEmpty(m):(t.environment,g=m),p={componentDisplayName:"usePreloadedQuery()",fetchObservable:g,fetchKey:c,fetchPolicy:d,query:f,renderPolicy:null==r?void 0:r.UNSTABLE_renderPolicy}}return i(p)}},774736,(e,t,r)=>{"use strict";var i=e.r(798409),n=e.r(266343);e.r(271645).useDebugValue;var s=e.r(145003).getFragment;t.exports=function(e,t){var r=s(e);n(r,"first argument of useRefetchableFragment()");var a=i(r,t,"useRefetchableFragment()");return[a.fragmentData,a.refetch]}},741938,(e,t,r)=>{"use strict";var i=e.r(795715),n=e.r(271645),s=n.useEffect,a=n.useRef;t.exports=function(e,t){var r=i(),n=a(null);return s(function(){var i=r.getStore(),s=i.lookupInvalidationState(e),a=i.subscribeToInvalidationState(s,t);return n.current=a,function(){return a.dispose()}},[Array.from(e).sort().join(""),t,r]),{dispose:function(){null!=n.current&&n.current.dispose()}}}},988933,(e,t,r)=>{"use strict";var i=e.r(795715),n=e.r(271645).useEffect,s=e.r(145003).requestSubscription;t.exports=function(e,t){var r=null!=t?t:s,a=i();n(function(){return r(a,e).dispose},[a,e,r])}},981788,(e,t,r)=>{"use strict";var i=e.r(66155),n=e.r(92310),s=e.r(423210),a=e.r(969467),o=e.r(778218),l=e.r(784701),u=e.r(775130),c=e.r(5670),d=e.r(335630).loadQuery,h=e.r(609700),f=e.r(794657),p=e.r(181591),g=e.r(836204),m=e.r(444966),y=e.r(302096),v=e.r(662283),b=e.r(280380),_=e.r(942268),E=e.r(121937),S=e.r(38150),x=e.r(774736),T=e.r(795715),w=e.r(741938),A=e.r(988933),R=e.r(145003);t.exports={ConnectionHandler:R.ConnectionHandler,QueryRenderer:o,LocalQueryRenderer:s,MutationTypes:R.MutationTypes,RangeOperations:R.RangeOperations,ReactRelayContext:i,applyOptimisticMutation:R.applyOptimisticMutation,commitLocalUpd
1ate:R.commitLocalUpdate,commitMutation:R.commitMutation,createFragmentContainer:n.createContainer,createPaginationContainer:a.createContainer,createRefetchContainer:l.createContainer,fetchQuery_DEPRECATED:R.fetchQuery_DEPRECATED,graphql:R.graphql,readInlineData:R.readInlineData,requestSubscription:R.requestSubscription,EntryPointContainer:u,RelayEnvironmentProvider:f,ProfilerContext:h,fetchQuery:R.fetchQuery,loadQuery:d,loadEntryPoint:c,useClientQuery:p,useFragment:m,useLazyLoadQuery:y,useEntryPointLoader:g,useQueryLoader:S,useMutation:v,usePaginationFragment:b,usePreloadedQuery:E,useRefetchableFragment:x,usePrefetchableForwardPaginationFragment:_,useRelayEnvironment:T,useSubscribeToInvalidationState:w,useSubscription:A}},419408,(e,t,r)=>{t.exports=e.r(981788)},384843,e=>{"use strict";let t=e.i(271645).default.createContext("cs");e.s(["LocaleContext",0,t])},910573,e=>{"use strict";let t=(0,e.i(271645).createContext)({slug2:"",changeSlug:e=>{}});e.s(["SlugContext",0,t])},873017,e=>{"use strict";var t=e.i(247167),r=e.i(145003);function i(){return"true"===t.default.env.CACHE_DIAGNOSTICS}e.i(822315);let n=e=>!!e?.match(/^\s*query\b/);async function s({apiToken:e,cachePolicy:t,endpoint:r,errorLabel:a="Error",fetchImpl:o,logOperation:l=!1,logger:u=console,onTags:c,operationText:d,referer:h,rejectErrors:f,requestCdaTags:p=!1,variables:g}){if(!r)throw Error("No GraphQL endpoint defined!");if(!e)throw Error("No API token!");try{let s,a,m=d?.match(/^(query|mutation|subscription)\s+(\w+)/)?.[2];l&&m&&!i()&&u.log(`API CALL: ${m} with variables: ${JSON.stringify(g)}`);let y="public"===t.mode&&n(d)?t:void 0,v=!!y||p&&n(d),b=y||!h?(s=d?.match(/^(query|mutation|subscription)\s+(\w+)/)?.[2],`https://www.narodni-divadlo.cz/queries/${s??"unknownOperation"}`):h,_=await o(r,{body:JSON.stringify({query:d,variables:g}),headers:{"Content-Type":"application/json",Referer:b,Authorization:e,...v&&{"X-Cache-Tags":"true"}},method:"POST",...y?{cache:"force-cache",next:{tags:[...y.tags]}}:{cache:"no-store"}}),E=await _.json();if(f&&E.errors)return Promise.reject(E.errors);let S=v?(a=_.headers?.get("X-Cache-Tags"),Array.from(new Set((a??"").split(/[\s,]+/).map(e=>e.trim()).filter(Boolean))).sort()):[];return S.length>0&&c?.(S),E}catch(e){i()||(u.log(a),u.log(d?.substr(0,200),g),u.error(e));return}}e.s(["createRelayEnvironment",0,(e,t)=>new r.Environment({network:r.Network.create(async(e,r)=>s({apiToken:"a6f056272e34fc913cba734e6144c9",cachePolicy:{mode:"no-store"},endpoint:"https://graphql.datocms.com/",fetchImpl:(e,t)=>fetch(e,t),operationText:e.text,rejectErrors:t,variables:r})),store:new r.Store(new r.RecordSource(e))})],873017)},456780,e=>{"use strict";let t={cs:{load_more:"NaÄÃst vÃce",close_menu:"ZavÅÃt menu",open_menu:"OtevÅÃt menu",search:"VyhledávánÃ",disability_info:"Informace pro handicapované",parking:"Parkovánà v ND",shopping_cart:"KoÅ¡Ãk",user_account:"Zákaznický úÄet",log_in:"PÅihlásit se",language_switch_cs:"ÄeÅ¡tina",language_switch_en:"AngliÄtina",prev_page:"PÅedchozà stránka",next_page:"Dalšà stránka",prev:"PÅedchozÃ",next:"DalÅ¡Ã",close:"ZavÅÃt",zoom_in:"PÅiblÞit",zoom_out:"Oddálit",play:"PÅehrát",pause:"Pozastavit",announcement_bar:"InformaÄnà liÅ¡ta",close_announcement_bar:"ZavÅÃt informaÄnà liÅ¡tu",home:"Domů",open_filter:"OtevÅÃt filtr",share_facebook:"SdÃlet na Facebooku",share_linkedin:"SdÃlet na LinkedIn",share_x:"SdÃlet na X",social_facebook:"Facebook",social_instagram:"Instagram",social_youtube:"YouTube",social_x:"X",social_linkedin:"LinkedIn",social_spotify:"Spotify",social_link:"Odkaz na sociálnà sÃÅ¥",newsletter_link:"PÅejÃt na stránku newsletteru",symbio_link:"NavÅ¡tivte web Symbio agency",slide_n:"SnÃmek {n}",jump_to_section:"PÅejÃt na sekci {name}",loading:"NaÄÃtánÃ",open_photo:"Fotografie {n}, otevÅÃt v plném zobrazenÃ",video:"Video",hide_password:"Skrýt heslo",show_password:"Zobrazit heslo",pagination:"StránkovánÃ",menu:"NavigaÄnà menu",close_filter:"ZavÅÃt filtr",close_list:"ZavÅÃt seznam",datocms_edit_page:"OtevÅÃt stránku v DatoCMS"},en:{load_more:"Load more",close_menu:"Close menu",open_menu:"Open menu",search:"Search",disability_info:"Information for disabled people",parking:"Parking in ND",shopping_cart:"Shopping cart",user_account:"User account",log_in:"Log in",language_switch_cs:"Czech",language_switch_en:"English",prev_page:"Previous page",next_page:"Next page",prev:"Previous",next:"Next",close:"Close",zoom_in:"Zoom in",zoom_out:"Zoom out",play:"Play",pause:"Pause",announcement_bar:"Announcement bar",close_announcement_bar:"Close announcement bar",home:"Home",open_filter:"Open filter",share_facebook:"Share on Facebook",share_linkedin:"Share on LinkedIn",share_x:"Share on X",social_facebook:"Facebook",social_instagram:"Instagram",social_youtube:"YouTube",social_x:"X",social_linkedin:"LinkedIn",social_spotify:"Spotify",social_link:"Social link",
1newsletter_link:"Go to newsletter page",symbio_link:"Visit Symbio agency website",slide_n:"Slide {n}",jump_to_section:"Jump to section {name}",loading:"Loading",open_photo:"Photo {n}, open full view",video:"Video",hide_password:"Hide password",show_password:"Show password",pagination:"Pagination",menu:"Navigation menu",close_filter:"Close filter",close_list:"Close list",datocms_edit_page:"Open this page in DatoCMS"}};e.s(["getAccessibilityLabel",0,(e,r,i)=>{let n=t[r]?.[e]??"";if(i)for(let[e,t]of Object.entries(i))n=n.replace(RegExp(`\\{${e}\\}`,"g"),String(t));return n}])},570791,(e,t,r)=>{"use strict";var i={};t.exports={getItem:function(e){return e in i?i[e]:null},setItem:function(e,t){return i[e]=t,!0},removeItem:function(e){return e in i&&delete i[e]},clear:function(){return i={},!0}}},135835,(e,t,r)=>{"use strict";t.exports=function(e){let t=function(e){try{return JSON.parse(e)}catch(t){return e}}(e);return void 0===t?null:t}},801736,(e,t,r)=>{"use strict";var i=e.r(135835),n={};function s(t){t||(t=e.g.event);var r=n[t.key];r&&r.forEach(function(e){e(i(t.newValue),i(t.oldValue),t.url||t.uri)})}t.exports={on:function(t,r){n[t]?n[t].push(r):n[t]=[r],e.g.addEventListener?e.g.addEventListener("storage",s,!1):e.g.attachEvent?e.g.attachEvent("onstorage",s):e.g.onstorage=s},off:function(e,t){var r=n[e];r.length>1?r.splice(r.indexOf(t),1):n[e]=[]}}},412675,(e,t,r)=>{"use strict";var i=e.r(570791),n=e.r(135835),s=e.r(801736),a="localStorage"in e.g&&e.g.localStorage?e.g.localStorage:i;function o(e,t){return 1==arguments.length?l(e):u(e,t)}function l(e){return n(a.getItem(e))}function u(e,t){try{return a.setItem(e,JSON.stringify(t)),!0}catch(e){return!1}}o.set=u,o.get=l,o.remove=function(e){return a.removeItem(e)},o.clear=function(){return a.clear()},o.backend=function(e){return e&&(a=e),a},o.on=s.on,o.off=s.off,t.exports=o},467034,(e,t,r)=>{var i={675:function(e,t){"use strict";t.byteLength=function(e){var t=l(e),r=t[0],i=t[1];return(r+i)*3/4-i},t.toByteArray=function(e){var t,r,s=l(e),a=s[0],o=s[1],u=new n((a+o)*3/4-o),c=0,d=o>0?a-4:a;for(r=0;r<d;r+=4)t=i[e.charCodeAt(r)]<<18|i[e.charCodeAt(r+1)]<<12|i[e.charCodeAt(r+2)]<<6|i[e.charCodeAt(r+3)],u[c++]=t>>16&255,u[c++]=t>>8&255,u[c++]=255&t;return 2===o&&(t=i[e.charCodeAt(r)]<<2|i[e.charCodeAt(r+1)]>>4,u[c++]=255&t),1===o&&(t=i[e.charCodeAt(r)]<<10|i[e.charCodeAt(r+1)]<<4|i[e.charCodeAt(r+2)]>>2,u[c++]=t>>8&255,u[c++]=255&t),u},t.fromByteArray=function(e){for(var t,i=e.length,n=i%3,s=[],a=0,o=i-n;a<o;a+=16383)s.push(function(e,t,i){for(var n,s=[],a=t;a<i;a+=3)n=(e[a]<<16&0xff0000)+(e[a+1]<<8&65280)+(255&e[a+2]),s.push(r[n>>18&63]+r[n>>12&63]+r[n>>6&63]+r[63&n]);return s.join("")}(e,a,a+16383>o?o:a+16383));return 1===n?s.push(r[(t=e[i-1])>>2]+r[t<<4&63]+"=="):2===n&&s.push(r[(t=(e[i-2]<<8)+e[i-1])>>10]+r[t>>4&63]+r[t<<2&63]+"="),s.join("")};for(var r=[],i=[],n="u">typeof Uint8Array?Uint8Array:Array,s="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/",a=0,o=s.length;a<o;++a)r[a]=s[a],i[s.charCodeAt(a)]=a;function l(e){var t=e.length;if(t%4>0)throw Error("Invalid string. Length must be a multiple of 4");var r=e.indexOf("=");-1===r&&(r=t);var i=r===t?0:4-r%4;return[r,i]}i[45]=62,i[95]=63},72:function(e,t,r){"use strict";var i=r(675),n=r(783),s="function"==typeof Symbol&&"function"==typeof Symbol.for?Symbol.for("nodejs.util.inspect.custom"):null;function a(e){if(e>0x7fffffff)throw RangeError('The value "'+e+'" is invalid for option "size"');var t=new Uint8Array(e);return Object.setPrototypeOf(t,o.prototype),t}function o(e,t,r){if("number"==typeof e){if("string"==typeof t)throw TypeError('The "string" argument must be of type string. Received type number');return c(e)}return l(e,t,r)}function l(e,t,r){if("string"==typeof e){var i=e,n=t;if(("string"!=typeof n||""===n)&&(n="utf8"),!o.isEncoding(n))throw TypeError("Unknown encoding: "+n);var s=0|f(i,n),l=a(s),u=l.write(i,n);return u!==s&&(l=l.slice(0,u)),l}if(ArrayBuffer.isView(e))return d(e);if(null==e)throw TypeError("The first argument must be one of type string, Buffer, ArrayBuffer, Array, or Array-like Object. Received type "+typeof e);if(k(e,ArrayBuffer)||e&&k(e.buffer,ArrayBuffer)||"u">typeof SharedArrayBuffer&&(k(e,SharedArrayBuffer)||e&&k(e.buffer,SharedArrayBuffer)))return function(e,t,r){var i;if(t<0||e.byteLength<t)throw RangeError('"offset" is outside of buffer bounds');if(e.byteLength<t+(r||0))throw RangeError('"length" is outside of buffer bounds');return Object.setPrototypeOf(i=void 0===t&&void 0===r?new Uint8Array(e):void 0===r?new Uint8Array(e,t):new Uint8Array(e,t,r),o.prototype),i}(e,t,r);if("number"==typeof e)throw TypeError('The "value" argument must not be of type number. Received type number');var c=e.valueOf&&e.valueOf();if(null!=c&&c!==e)return o.from(c,t,r);var p=function(e){if(o.isBuffer(e)){var t=0|h(e.length),r=a(t);return 0===r.length||e.copy(r,0,0,t),r}return void 0!==e.length?"number"!=typeof e.length||function(e){return e!=e}(e.length)?a(0):d(e):"Buffer"===e.type&&Array.isArray(e.data)?d(e.data):void 0}(e);if(p)return p;if("u">typeof Symbol&&null!=Symbol.toPrimitive&&"function"==typeof e[Symbol.toPrimitive])return o.from(e[Symbol.toPrimitive]("string"),t,r);throw TypeError("The first argument must be one of type string, Buffer, ArrayBuffer, Array, or Array-like Object. Received type "+typeof e)}function u(e){if("number"!=typeof e)throw TypeError('"size" argument must be of type number');
vendor: 16,459 bytes, line 1
1if(e<0)throw RangeError('The value "'+e+'" is invalid for option "size"')}function c(e){return u(e),a(e<0?0:0|h(e))}function d(e){for(var t=e.length<0?0:0|h(e.length),r=a(t),i=0;i<t;i+=1)r[i]=255&e[i];return r}t.Buffer=o,t.SlowBuffer=function(e){return+e!=e&&(e=0),o.alloc(+e)},t.INSPECT_MAX_BYTES=50,t.kMaxLength=0x7fffffff,o.TYPED_ARRAY_SUPPORT=function(){try{var e=new Uint8Array(1),t={foo:function(){return 42}};return Object.setPrototypeOf(t,Uint8Array.prototype),Object.setPrototypeOf(e,t),42===e.foo()}catch(e){return!1}}(),!o.TYPED_ARRAY_SUPPORT&&"u">typeof console&&"function"==typeof console.error&&console.error("This browser lacks typed array (Uint8Array) support which is required by `buffer` v5.x. Use `buffer` v4.x if you require old browser support."),Object.defineProperty(o.prototype,"parent",{enumerable:!0,get:function(){if(o.isBuffer(this))return this.buffer}}),Object.defineProperty(o.prototype,"offset",{enumerable:!0,get:function(){if(o.isBuffer(this))return this.byteOffset}}),o.poolSize=8192,o.from=function(e,t,r){return l(e,t,r)},Object.setPrototypeOf(o.prototype,Uint8Array.prototype),Object.setPrototypeOf(o,Uint8Array),o.alloc=function(e,t,r){return(u(e),e<=0)?a(e):void 0!==t?"string"==typeof r?a(e).fill(t,r):a(e).fill(t):a(e)},o.allocUnsafe=function(e){return c(e)},o.allocUnsafeSlow=function(e){return c(e)};function h(e){if(e>=0x7fffffff)throw RangeError("Attempt to allocate Buffer larger than maximum size: 0x7fffffff bytes");return 0|e}function f(e,t){if(o.isBuffer(e))return e.length;if(ArrayBuffer.isView(e)||k(e,ArrayBuffer))return e.byteLength;if("string"!=typeof e)throw TypeError('The "string" argument must be one of type string, Buffer, or ArrayBuffer. Received type '+typeof e);var r=e.length,i=arguments.length>2&&!0===arguments[2];if(!i&&0===r)return 0;for(var n=!1;;)switch(t){case"ascii":case"latin1":case"binary":return r;case"utf8":case"utf-8":return w(e).length;case"ucs2":case"ucs-2":case"utf16le":case"utf-16le":return 2*r;case"hex":return r>>>1;case"base64":return R(e).length;default:if(n)return i?-1:w(e).length;t=(""+t).toLowerCase(),n=!0}}function p(e,t,r){var n,s,a,o=!1;if((void 0===t||t<0)&&(t=0),t>this.length||((void 0===r||r>this.length)&&(r=this.length),r<=0||(r>>>=0)<=(t>>>=0)))return"";for(e||(e="utf8");;)switch(e){case"hex":return function(e,t,r){var i=e.length;(!t||t<0)&&(t=0),(!r||r<0||r>i)&&(r=i);for(var n="",s=t;s<r;++s)n+=C[e[s]];return n}(this,t,r);case"utf8":case"utf-8":return v(this,t,r);case"ascii":return function(e,t,r){var i="";r=Math.min(e.length,r);for(var n=t;n<r;++n)i+=String.fromCharCode(127&e[n]);return i}(this,t,r);case"latin1":case"binary":return function(e,t,r){var i="";r=Math.min(e.length,r);for(var n=t;n<r;++n)i+=String.fromCharCode(e[n]);return i}(this,t,r);case"base64":return n=this,s=t,a=r,0===s&&a===n.length?i.fromByteArray(n):i.fromByteArray(n.slice(s,a));case"ucs2":case"ucs-2":case"utf16le":case"utf-16le":return function(e,t,r){for(var i=e.slice(t,r),n="",s=0;s<i.length;s+=2)n+=String.fromCharCode(i[s]+256*i[s+1]);return n}(this,t,r);default:if(o)throw TypeError("Unknown encoding: "+e);e=(e+"").toLowerCase(),o=!0}}function g(e,t,r){var i=e[t];e[t]=e[r],e[r]=i}function m(e,t,r,i,n){var s;if(0===e.length)return -1;if("string"==typeof r?(i=r,r=0):r>0x7fffffff?r=0x7fffffff:r<-0x80000000&&(r=-0x80000000),(s=r*=1)!=s&&(r=n?0:e.length-1),r<0&&(r=e.length+r),r>=e.length)if(n)return -1;else r=e.length-1;else if(r<0)if(!n)return -1;else r=0;if("string"==typeof t&&(t=o.from(t,i)),o.isBuffer(t))return 0===t.length?-1:y(e,t,r,i,n);if("number"==typeof t){if(t&=255,"function"==typeof Uint8Array.prototype.indexOf)if(n)return Uint8Array.prototype.indexOf.call(e,t,r);else return Uint8Array.prototype.lastIndexOf.call(e,t,r);return y(e,[t],r,i,n)}throw TypeError("val must be string, number or Buffer")}function y(e,t,r,i,n){var s,a=1,o=e.length,l=t.length;if(void 0!==i&&("ucs2"===(i=String(i).toLowerCase())||"ucs-2"===i||"utf16le"===i||"utf-16le"===i)){if(e.length<2||t.length<2)return -1;a=2,o/=2,l/=2,r/=2}function u(e,t){return 1===a?e[t]:e.readUInt16BE(t*a)}if(n){var c=-1;for(s=r;s<o;s++)if(u(e,s)===u(t,-1===c?0:s-c)){if(-1===c&&(c=s),s-c+1===l)return c*a}else -1!==c&&(s-=s-c),c=-1}else for(r+l>o&&(r=o-l),s=r;s>=0;s--){for(var d=!0,h=0;h<l;h++)if(u(e,s+h)!==u(t,h)){d=!1;break}if(d)return s}return -1}o.isBuffer=function(e){return null!=e&&!0===e._isBuffer&&e!==o.prototype},o.compare=function(e,t){if(k(e,Uint8Array)&&(e=o.from(e,e.offset,e.byteLength)),k(t,Uint8Array)&&(t=o.from(t,t.offset,t.byteLength)),!o.isBuffer(e)||!o.isBuffer(t))throw TypeError('The "buf1", "buf2" arguments must be one of type Buffer or Uint8Array');if(e===t)return 0;for(var r=e.length,i=t.length,n=0,s=Math.min(r,i);n<s;++n)if(e[n]!==t[n]){r=e[n],i=t[n];break}return r<i?-1:+(i<r)},o.isEncoding=function(e){switch(String(e).toLowerCase()){case"hex":case"utf8":case"utf-8":case"ascii":case"latin1":case"binary":case"base64":case"ucs2":case"ucs-2":case"utf16le":case"utf-16le":return!0;default:return!1}},o.concat=function(e,t){if(!Array.isArray(e))throw TypeError('"list" argument must be an Array of Buffers');if(0===e.length)return o.alloc(0);if(void 0===t)for(r=0,t=0;r<e.length;++r)t+=e[r].length;var r,i=o.allocUnsafe(t),n=0;for(r=0;r<e.length;++r){var s=e[r];if(k(s,Uint8Array)&&(s=o.from(s)),!o.isBuffer(s))throw TypeError('"list" argument must be an Array of Buffers');s.copy(i,n),n+=s.length}return i},o.byteLength=f,o.prototype._isBuffer=!0,o.prototype.swap16=function(){var e=this.length;if(e%2!=0)throw RangeError("Buffer size must be a multiple of 16-bits");for(var t=0;t<e;t+=2)g(this,t,t+1);return this},o.prototype.swap32=function(){var e=this.length;if(e%4!=0)throw RangeError("Buffer size must be a multiple of 32-bits");for(var t=0;t<e;t+=4)g(this,t,t+3),g(this,t+1,t+2);return this},o.prototype.swap64=function(){var e=this.length;if(e%8!=0)throw RangeError("Buffer size must be a multiple of 64-bits");for(var t=0;t<e;t+=8)g(this,t,t+7),g(this,t+1,t+6),g(this,t+2,t+5),g(this,t+3,t+4);return this},o.prototype.toString=function(){var e=this.length;return 0===e?"":0==arguments.length?v(this,0,e):p.apply(this,arguments)},o.prototype.toLocaleString=o.prototype.toString,o.prototype.equals=function(e){if(!o.isBuffer(e))throw TypeError("Argument must be a Buffer");return this===e||0===o.compare(this,e)},o.prototype.inspect=function(){var e="",r=t.INSPECT_MAX_BYTES;return e=this.toString("hex",0,r).replace(/(.{2})/g,"$1 ").trim(),this.length>r&&(e+=" ... "),"<Buffer "+e+">"},s&&(o.prototype[s]=o.prototype.inspect),o.prototype.compare=function(e,t,r,i,n){if(k(e,Uint8Array)&&(e=o.from(e,e.offset,e.byteLength)),!o.isBuffer(e))throw TypeError('The "target" argument must be one of type Buffer or Uint8Array. Received type '+typeof e);if(void 0===t&&(t=0),void 0===r&&(r=e?e.length:0),void 0===i&&(i=0),void 0===n&&(n=this.length),t<0||r>e.length||i<0||n>this.length)throw RangeError("out of range index");if(i>=n&&t>=r)return 0;if(i>=n)return -1;if(t>=r)return 1;if(t>>>=0,r>>>=0,i>>>=0,n>>>=0,this===e)return 0;for(var s=n-i,a=r-t,l=Math.min(s,a),u=this.slice(i,n),c=e.slice(t,r),d=0;d<l;++d)if(u[d]!==c[d]){s=u[d],a=c[d];break}return s<a?-1:+(a<s)},o.prototype.includes=function(e,t,r){return -1!==this.indexOf(e,t,r)},o.prototype.indexOf=function(e,t,r){return m(this,e,t,r,!0)},o.prototype.lastIndexOf=function(e,t,r){return m(this,e,t,r,!1)};function v(e,t,r){r=Math.min(e.length,r);for(var i=[],n=t;n<r;){var s,a,o,l,u=e[n],c=null,d=u>239?4:u>223?3:u>191?2:1;if(n+d<=r)switch(d){case 1:u<128&&(c=u);break;case 2:(192&(s=e[n+1]))==128&&(l=(31&u)<<6|63&s)>127&&(c=l);break;case 3:s=e[n+1],a=e[n+2],(192&s)==128&&(192&a)==128&&(l=(15&u)<<12|(63&s)<<6|63&a)>2047&&(l<55296||l>57343)&&(c=l);break;case 4:s=e[n+1],a=e[n+2],o=e[n+3],(192&s)==128&&(192&a)==128&&(192&o)==128&&(l=(15&u)<<18|(63&s)<<12|(63&a)<<6|63&o)>65535&&l<1114112&&(c=l)}null===c?(c=65533,d=1):c>65535&&(c-=65536,i.push(c>>>10&1023|55296),c=56320|1023&c),i.push(c),n+=d}var h=i,f=h.length;if(f<=4096)return String.fromCharCode.apply(String,h);for(var p="",g=0;g<f;)p+=String.fromCharCode.apply(String,h.slice(g,g+=4096));return p}function b(e,t,r){if(e%1!=0||e<0)throw RangeError("offset is not uint");if(e+t>r)throw RangeError("Trying to access beyond buffer length")}function _(e,t,r,i,n,s){if(!o.isBuffer(e))throw TypeError('"buffer" argument must be a Buffer instance');if(t>n||t<s)throw RangeError('"value" argument is out of bounds');if(r+i>e.length)throw RangeError("Index out of range")}function E(e,t,r,i,n,s){if(r+i>e.length||r<0)throw RangeError("Index out of range")}function S(e,t,r,i,s){return t*=1,r>>>=0,s||E(e,t,r,4,34028234663852886e22,-34028234663852886e22),n.write(e,t,r,i,23,4),r+4}function x(e,t,r,i,s){return t*=1,r>>>=0,s||E(e,t,r,8,17976931348623157e292,-17976931348623157e292),n.write(e,t,r,i,52,8),r+8}o.prototype.write=function(e,t,r,i){if(void 0===t)i="utf8",r=this.length,t=0;else if(void 0===r&&"string"==typeof t)i=t,r=this.length,t=0;else if(isFinite(t))t>>>=0,isFinite(r)?(r>>>=0,void 0===i&&(i="utf8")):(i=r,r=void 0);else throw Error("Buffer.write(string, encoding, offset[, length]) is no longer supported");var n,s,a,o,l,u,c,d,h=this.length-t;if((void 0===r||r>h)&&(r=h),e.length>0&&(r<0||t<0)||t>this.length)throw RangeError("Attempt to write outside buffer bounds");i||(i="utf8");for(var f=!1;;)switch(i){case"hex":return function(e,t,r,i){r=Number(r)||0;var n=e.length-r;i?(i=Number(i))>n&&(i=n):i=n;var s=t.length;i>s/2&&(i=s/2);for(var a=0;a<i;++a){var o,l=parseInt(t.substr(2*a,2),16);if((o=l)!=o)break;e[r+a]=l}return a}(this,e,t,r);case"utf8":case"utf-8":return n=t,s=r,I(w(e,this.length-n),this,n,s);case"ascii":return a=t,o=r,I(A(e),this,a,o);case"latin1":case"binary":return function(e,t,r,i){return I(A(t),e,r,i)}(this,e,t,r);case"base64":return l=t,u=r,I(R(e),this,l,u);case"ucs2":case"ucs-2":case"utf16le":case"utf-16le":return c=t,d=r,I(function(e,t){for(var r,i,n=[],s=0;s<e.length&&!((t-=2)<0);++s)i=(r=e.charCodeAt(s))>>8,n.push(r%256),n.push(i);return n}(e,this.length-c),this,c,d);default:if(f)throw TypeError("Unknown encoding: "+i);i=(""+i).toLowerCase(),f=!0}},o.prototype.toJSON=function(){return{type:"Buffer",data:Array.prototype.slice.call(this._arr||this,0)}},o.prototype.slice=function(e,t){var r=this.length;e=~~e,t=void 0===t?r:~~t,e<0?(e+=r)<0&&(e=0):e>r&&(e=r),t<0?(t+=r)<0&&(t=0):t>r&&(t=r),t<e&&(t=e);var i=this.subarray(e,t);return Object.setPrototypeOf(i,o.prototype),i},o.prototype.readUIntLE=function(e,t,r){e>>>=0,t>>>=0,r||b(e,t,this.length);for(var i=this[e],n=1,s=0;++s<t&&(n*=256);)i+=this[e+s]*n;return i},o.prototype.readUIntBE=function(e,t,r){e>>>=0,t>>>=0,r||b(e,t,this.length);for(var i=this[e+--t],n=1;t>0&&(n*=256);)i+=this[e+--t]*n;return i},o.prototype.readUInt8=function(e,t){return e>>>=0,t||b(e,1,this.length),this[e]},o.prototype.readUInt16LE=function(e,t){return e>>>=0,t||b(e,2,this.length),this[e]|this[e+1]<<8},o.prototype.readUInt16BE=function(e,t){return e>>>=0,t||b(e,2,this.length),this[e]<<8|this[e+1]},o.prototype.readUInt32LE=function(e,t){return e>>>=0,t||b(e,4,this.length),(this[e]|this[e+1]<<8|this[e+2]<<16)+0x1000000*this[e+3]},o.prototype.readUInt32BE=function(e,t){return e>>>=0,t||b(e,4,this.length),0x1000000*this[e]+(this[e+1]<<16|this[e+2]<<8|this[e+3])},o.prototype.readIntLE=function(e,t,r){e>>>=0,t>>>=0,r||b(e,t,this.length);for(var i=this[e],n=1,s=0;++s<t&&(n*=256);)i+=this[e+s]*n;return i>=(n*=128)&&(i-=Math.pow(2,8*t)),i},o.prototype.readIntBE=function(e,t,r){e>>>=0,t>>>=0,r||b(e,t,this.length);for(var i=t,n=1,s=this[e+--i];i>0&&(n*=256);)s+=this[e+--i]*n;return s>=(n*=128)&&(s-=Math.pow(2,8*t)),s},o.prototype.readInt8=function(e,t){return(e>>>=0,t||b(e,1,this.length),128&this[e])?-((255-this[e]+1)*1):this[e]},o.prototype.readInt16LE=function(e,t){e>>>=0,t||b(e,2,this.length);var r=this[e]|this[e+1]<<8;return 32768&r?0xffff0000|r:r},o.prototype.readInt16BE=function(e,t){e>>>=0,t||b(e,2,this.length);var r=this[e+1]|this[e]<<8;return 32768&r?0xffff0000|r:r},o.prototype.readInt32LE=function(e,t){return e>>>=0,t||b(e,4,this.length),this[e]|this[e+1]<<8|this[e+2]<<16|this[e+3]<<24},o.prototype.readInt32BE=function(e,t){return e>>>=0,t||b(e,4,this.length),this[e]<<24|this[e+1]<<16|this[e+2]<<8|this[e+3]},o.prototype.readFloatLE=function(e,t){return e>>>=0,t||b(e,4,this.length),n.read(this,e,!0,23,4)},o.prototype.readFloatBE=function(e,t){return e>>>=0,t||b(e,4,this.length),n.read(this,e,!1,23,4)},o.prototype.readDoubleLE=function(e,t){return e>>>=0,t||b(e,8,this.length),n.read(this,e,!0,52,8)},o.prototype.readDoubleBE=function(e,t){return e>>>=0,t||b(e,8,this.length),n.read(this,e,!1,52,8)},o.prototype.writeUIntLE=function(e,t,r,i){if(e*=1,t>>>=0,r>>>=0,!i){var n=Math.pow(2,8*r)-1;_(this,e,t,r,n,0)}var s=1,a=0;for(this[t]=255&e;++a<r&&(s*=256);)this[t+a]=e/s&255;return t+r},o.prototype.writeUIntBE=function(e,t,r,i){if(e*=1,t>>>=0,r>>>=0,!i){var n=Math.pow(2,8*r)-1;_(this,e,t,r,n,0)}var s=r-1,a=1;for(this[t+s]=255&e;--s>=0&&(a*=256);)this[t+s]=e/a&255;return t+r},o.prototype.writeUInt8=function(e,t,r){return e*=1,t>>>=0,r||_(this,e,t,1,255,0),this[t]=255&e,t+1},o.prototype.writeUInt16LE=function(e,t,r){return e*=1,t>>>=0,r||_(this,e,t,2,65535,0),this[t]=255&e,this[t+1]=e>>>8,t+2},o.prototype.writeUInt16BE=function(e,t,r){return e*=1,t>>>=0,r||_(this,e,t,2,65535,0),this[t]=e>>>8,this[t+1]=255&e,t+2},o.prototype.writeUInt32LE=function(e,t,r){return e*=1,t>>>=0,r||_(this,e,t,4,0xffffffff,0),this[t+3]=e>>>24,this[t+2]=e>>>16,this[t+1]=e>>>8,this[t]=255&e,t+4},o.prototype.writeUInt32BE=function(e,t,r){return e*=1,t>>>=0,r||_(this,e,t,4,0xffffffff,0),this[t]=e>>>24,this[t+1]=e>>>16,this[t+2]=e>>>8,this[t+3]=255&e,t+4},o.prototype.writeIntLE=function(e,t,r,i){if(e*=1,t>>>=0,!i){var n=Math.pow(2,8*r-1);_(this,e,t,r,n-1,-n)}var s=0,a=1,o=0;for(this[t]=255&e;++s<r&&(a*=256);)e<0&&0===o&&0!==this[t+s-1]&&(o=1),this[t+s]=(e/a|0)-o&255;return t+r},o.prototype.writeIntBE=function(e,t,r,i){if(e*=1,t>>>=0,!i){var n=Math.pow(2,8*r-1);_(this,e,t,r,n-1,-n)}var s=r-1,a=1,o=0;for(this[t+s]=255&e;--s>=0&&(a*=256);)e<0&&0===o&&0!==this[t+s+1]&&(o=1),this[t+s]=(e/a|0)-o&255;return t+r},o.prototype.writeInt8=function(e,t,r){return e*=1,t>>>=0,r||_(this,e,t,1,127,-128),e<0&&(e=255+e+1),this[t]=255&e,t+1},o.prototype.writeInt16LE=function(e,t,r){return e*=1,t>>>=0,r||_(this,e,t,2,32767,-32768),this[t]=255&e,this[t+1]=e>>>8,t+2},o.prototype.writeInt16BE=function(e,t,r){return e*=1,t>>>=0,r||_(this,e,t,2,32767,-32768),this[t]=e>>>8,this[t+1]=255&e,t+2},o.prototype.writeInt32LE=function(e,t,r){return e*=1,t>>>=0,r||_(this,e,t,4,0x7fffffff,-0x80000000),this[t]=255&e,this[t+1]=e>>>8,this[t+2]=e>>>16,this[t+3]=e>>>24,t+4},o.prototype.writeInt32BE=function(e,t,r){return e*=1,t>>>=0,r||_(this,e,t,4,0x7fffffff,-0x80000000),e<0&&(e=0xffffffff+e+1),this[t]=e>>>24,this[t+1]=e>>>16,this[t+2]=e>>>8,this[t+3]=255&e,t+4},o.prototype.writeFloatLE=function(e,t,r){return S(this,e,t,!0,r)},o.prototype.writeFloatBE=function(e,t,r){return S(this,e,t,!1,r)},o.prototype.writeDoubleLE=function(e,t,r){return x(this,e,t,!0,r)},o.prototype.writeDoubleBE=function(e,t,r){return x(this,e,t,!1,r)},o.prototype.copy=function(e,t,r,i){if(!o.isBuffer(e))throw TypeError("argument should be a Buffer");if(r||(r=0),i||0===i||(i=this.length),t>=e.length&&(t=e.length),t||(t=0),i>0&&i<r&&(i=r),i===r||0===e.length||0===this.length)return 0;if(t<0)throw RangeError("targetStart out of bounds");if(r<0||r>=this.length)throw RangeError("Index out of range");if(i<0)throw RangeError("sourceEnd out of bounds");i>this.length&&(i=this.length),e.length-t<i-r&&(i=e.length-t+r);var n=i-r;if(this===e&&"function"==typeof Uint8Array.prototype.copyWithin)this.copyWithin(t,r,i);else if(this===e&&r<t&&t<i)for(var s=n-1;s>=0;--s)e[s+t]=this[s+r];else Uint8Array.prototype.set.call(e,this.subarray(r,i),t);return n},o.prototype.fill=function(e,t,r,i){if("string"==typeof e){if("string"==typeof t?(i=t,t=0,r=this.length):"string"==typeof r&&(i=r,r=this.length),void 0!==i&&"string"!=typeof i)throw TypeError("encoding must be a string");if("string"==typeof i&&!o.isEncoding(i))throw TypeError("Unknown encoding: "+i);if(1===e.length){var n,s=e.charCodeAt(0);("utf8"===i&&s<128||"latin1"===i)&&(e=s)}}else"number"==typeof e?e&=255:"boolean"==typeof e&&(e=Number(e));if(t<0||this.length<t||this.length<r)throw RangeError("Out of range index");if(r<=t)return this;if(t>>>=0,r=void 0===r?this.length:r>>>0,e||(e=0),"number"==typeof e)for(n=t;n<r;++n)this[n]=e;
1else{var a=o.isBuffer(e)?e:o.from(e,i),l=a.length;if(0===l)throw TypeError('The value "'+e+'" is invalid for argument "value"');for(n=0;n<r-t;++n)this[n+t]=a[n%l]}return this};var T=/[^+/0-9A-Za-z-_]/g;function w(e,t){t=t||1/0;for(var r,i=e.length,n=null,s=[],a=0;a<i;++a){if((r=e.charCodeAt(a))>55295&&r<57344){if(!n){if(r>56319||a+1===i){(t-=3)>-1&&s.push(239,191,189);continue}n=r;continue}if(r<56320){(t-=3)>-1&&s.push(239,191,189),n=r;continue}r=(n-55296<<10|r-56320)+65536}else n&&(t-=3)>-1&&s.push(239,191,189);if(n=null,r<128){if((t-=1)<0)break;s.push(r)}else if(r<2048){if((t-=2)<0)break;s.push(r>>6|192,63&r|128)}else if(r<65536){if((t-=3)<0)break;s.push(r>>12|224,r>>6&63|128,63&r|128)}else if(r<1114112){if((t-=4)<0)break;s.push(r>>18|240,r>>12&63|128,r>>6&63|128,63&r|128)}else throw Error("Invalid code point")}return s}function A(e){for(var t=[],r=0;r<e.length;++r)t.push(255&e.charCodeAt(r));return t}function R(e){return i.toByteArray(function(e){if((e=(e=e.split("=")[0]).trim().replace(T,"")).length<2)return"";for(;e.length%4!=0;)e+="=";return e}(e))}function I(e,t,r,i){for(var n=0;n<i&&!(n+r>=t.length)&&!(n>=e.length);++n)t[n+r]=e[n];return n}function k(e,t){return e instanceof t||null!=e&&null!=e.constructor&&null!=e.constructor.name&&e.constructor.name===t.name}var C=function(){for(var e="0123456789abcdef",t=Array(256),r=0;r<16;++r)for(var i=16*r,n=0;n<16;++n)t[i+n]=e[r]+e[n];return t}()},783:function(e,t){t.read=function(e,t,r,i,n){var s,a,o=8*n-i-1,l=(1<<o)-1,u=l>>1,c=-7,d=r?n-1:0,h=r?-1:1,f=e[t+d];for(d+=h,s=f&(1<<-c)-1,f>>=-c,c+=o;c>0;s=256*s+e[t+d],d+=h,c-=8);for(a=s&(1<<-c)-1,s>>=-c,c+=i;c>0;a=256*a+e[t+d],d+=h,c-=8);if(0===s)s=1-u;else{if(s===l)return a?NaN:1/0*(f?-1:1);a+=Math.pow(2,i),s-=u}return(f?-1:1)*a*Math.pow(2,s-i)},t.write=function(e,t,r,i,n,s){var a,o,l,u=8*s-n-1,c=(1<<u)-1,d=c>>1,h=5960464477539062e-23*(23===n),f=i?0:s-1,p=i?1:-1,g=+(t<0||0===t&&1/t<0);for(isNaN(t=Math.abs(t))||t===1/0?(o=+!!isNaN(t),a=c):(a=Math.floor(Math.log(t)/Math.LN2),t*(l=Math.pow(2,-a))<1&&(a--,l*=2),a+d>=1?t+=h/l:t+=h*Math.pow(2,1-d),t*l>=2&&(a++,l/=2),a+d>=c?(o=0,a=c):a+d>=1?(o=(t*l-1)*Math.pow(2,n),a+=d):(o=t*Math.pow(2,d-1)*Math.pow(2,n),a=0));n>=8;e[r+f]=255&o,f+=p,o/=256,n-=8);for(a=a<<n|o,u+=n;u>0;e[r+f]=255&a,f+=p,a/=256,u-=8);e[r+f-p]|=128*g}}},n={};function s(e){var t=n[e];if(void 0!==t)return t.exports;var r=n[e]={exports:{}},a=!0;try{i[e](r,r.exports,s),a=!1}finally{a&&delete n[e]}return r.exports}s.ab="/ROOT/node_modules/next/dist/compiled/buffer/",t.exports=s(72)},581949,e=>{"use strict";let t,r,i,n;var s,a,o,l,u=e.i(247167);function c(e,t){return function(){return e.apply(t,arguments)}}let{toString:d}=Object.prototype,{getPrototypeOf:h}=Object,{iterator:f,toStringTag:p}=Symbol,g=(t=Object.create(null),e=>{let r=d.call(e);return t[r]||(t[r]=r.slice(8,-1).toLowerCase())}),m=e=>(e=e.toLowerCase(),t=>g(t)===e),y=e=>t=>typeof t===e,{isArray:v}=Array,b=y("undefined");function _(e){return null!==e&&!b(e)&&null!==e.constructor&&!b(e.constructor)&&x(e.constructor.isBuffer)&&e.constructor.isBuffer(e)}let E=m("ArrayBuffer"),S=y("string"),x=y("function"),T=y("number"),w=e=>null!==e&&"object"==typeof e,A=e=>{if("object"!==g(e))return!1;let t=h(e);return(null===t||t===Object.prototype||null===Object.getPrototypeOf(t))&&!(p in e)&&!(f in e)},R=m("Date"),I=m("File"),k=m("Blob"),C=m("FileList"),D="u">typeof globalThis?globalThis:"u">typeof self?self:"u">typeof window?window:e.g,L=void 0!==D.FormData?D.FormData:void 0,O=m("URLSearchParams"),[P,F,N,M]=["ReadableStream","Request","Response","Headers"].map(m);function j(e,t,{allOwnKeys:r=!1}={}){let i,n;if(null!=e)if("object"!=typeof e&&(e=[e]),v(e))for(i=0,n=e.length;i<n;i++)t.call(null,e[i],i,e);else{let n;if(_(e))return;let s=r?Object.getOwnPropertyNames(e):Object.keys(e),a=s.length;for(i=0;i<a;i++)n=s[i],t.call(null,e[n],n,e)}}function $(e,t){let r;if(_(e))return null;t=t.toLowerCase();let i=Object.keys(e),n=i.length;for(;n-- >0;)if(t===(r=i[n]).toLowerCase())return r;return null}let U="u">typeof globalThis?globalThis:"u">typeof self?self:"u">typeof window?window:e.g,B=e=>!b(e)&&e!==U,V=(r="u">typeof Uint8Array&&h(Uint8Array),e=>r&&e instanceof r),G=m("HTMLFormElement"),q=(({hasOwnProperty:e})=>(t,r)=>e.call(t,r))(Object.prototype),H=m("RegExp"),z=(e,t)=>{let r=Object.getOwnPropertyDescriptors(e),i={};j(r,(r,n)=>{let s;!1!==(s=t(r,n,e))&&(i[n]=s||r)}),Object.defineProperties(e,i)},K=m("AsyncFunction"),W=(s="function"==typeof setImmediate,a=x(U.postMessage),s?setImmediate:a?(o=`axios@${Math.random()}`,l=[],U.addEventListener("message",({source:e,data:t})=>{e===U&&t===o&&l.length&&l.shift()()},!1),e=>{l.push(e),U.postMessage(o,"*")}):e=>setTimeout(e)),Y="u">typeof queueMicrotask?queueMicrotask.bind(U):void 0!==u.default&&u.default.nextTick||W,Q={isArray:v,isArrayBuffer:E,isBuffer:_,isFormData:e=>{if(!e)return!1;if(L&&e instanceof L)return!0;let t=h(e);if(!t||t===Object.prototype||!x(e.append))return!1;let r=g(e);return"formdata"===r||"object"===r&&x(e.toString)&&"[object FormData]"===e.toString()},isArrayBufferView:function(e){return"u">typeof ArrayBuffer&&ArrayBuffer.isView?ArrayBuffer.isView(e):e&&e.buffer&&E(e.buffer)},isString:S,isNumber:T,isBoolean:e=>!0===e||!1===e,isObject:w,isPlainObject:A,isEmptyObject:e=>{if(!w(e)||_(e))return!1;try{return 0===Object.keys(e).length&&Object.getPrototypeOf(e)===Object.prototype}catch(e){return!1}},isReadableStream:P,isRequest:F,isResponse:N,isHeaders:M,isUndefined:b,isDate:R,isFile:I,isReactNativeBlob:e=>!!(e&&void 0!==e.uri),isReactNative:e=>e&&void 0!==e.getParts,isBlob:k,isRegExp:H,isFunction:x,isStream:e=>w(e)&&x(e.pipe),isURLSearchParams:O,isTypedArray:V,isFileList:C,forEach:j,merge:function e(...t){let{caseless:r,skipUndefined:i}=B(this)&&this||{},n={},s=(t,s)=>{if("__proto__"===s||"constructor"===s||"prototype"===s)return;let a=r&&$(n,s)||s,o=q(n,a)?n[a]:void 0;A(o)&&A(t)?n[a]=e(o,t):A(t)?n[a]=e({},t):v(t)?n[a]=t.slice():i&&b(t)||(n[a]=t)};for(let e=0,r=t.length;e<r;e++)t[e]&&j(t[e],s);return n},extend:(e,t,r,{allOwnKeys:i}={})=>(j(t,(t,i)=>{r&&x(t)?Object.defineProperty(e,i,{__proto__:null,value:c(t,r),writable:!0,enumerable:!0,configurable:!0}):Object.defineProperty(e,i,{__proto__:null,value:t,writable:!0,enumerable:!0,configurable:!0})},{allOwnKeys:i}),e),trim:e=>e.trim?e.trim():e.replace(/^[\s\uFEFF\xA0]+|[\s\uFEFF\xA0]+$/g,""),stripBOM:e=>(65279===e.charCodeAt(0)&&(e=e.slice(1)),e),inherits:(e,t,r,i)=>
1{e.prototype=Object.create(t.prototype,i),Object.defineProperty(e.prototype,"constructor",{__proto__:null,value:e,writable:!0,enumerable:!1,configurable:!0}),Object.defineProperty(e,"super",{__proto__:null,value:t.prototype}),r&&Object.assign(e.prototype,r)},toFlatObject:(e,t,r,i)=>{let n,s,a,o={};if(t=t||{},null==e)return t;do{for(s=(n=Object.getOwnPropertyNames(e)).length;s-- >0;)a=n[s],(!i||i(a,e,t))&&!o[a]&&(t[a]=e[a],o[a]=!0);e=!1!==r&&h(e)}while(e&&(!r||r(e,t))&&e!==Object.prototype)return t},kindOf:g,kindOfTest:m,endsWith:(e,t,r)=>{e=String(e),(void 0===r||r>e.length)&&(r=e.length),r-=t.length;let i=e.indexOf(t,r);return -1!==i&&i===r},toArray:e=>{if(!e)return null;if(v(e))return e;let t=e.length;if(!T(t))return null;let r=Array(t);for(;t-- >0;)r[t]=e[t];return r},forEachEntry:(e,t)=>{let r,i=(e&&e[f]).call(e);for(;(r=i.next())&&!r.done;){let i=r.value;t.call(e,i[0],i[1])}},matchAll:(e,t)=>{let r,i=[];for(;null!==(r=e.exec(t));)i.push(r);return i},isHTMLForm:G,hasOwnProperty:q,hasOwnProp:q,reduceDescriptors:z,freezeMethods:e=>{z(e,(t,r)=>{if(x(e)&&["arguments","caller","callee"].includes(r))return!1;if(x(e[r])){if(t.enumerable=!1,"writable"in t){t.writable=!1;return}t.set||(t.set=()=>{throw Error("Can not rewrite read-only method '"+r+"'")})}})},toObjectSet:(e,t)=>{let r={};return(v(e)?e:String(e).split(t)).forEach(e=>{r[e]=!0}),r},toCamelCase:e=>e.toLowerCase().replace(/[-_\s]([a-z\d])(\w*)/g,function(e,t,r){return t.toUpperCase()+r}),noop:()=>{},toFiniteNumber:(e,t)=>null!=e&&Number.isFinite(e*=1)?e:t,findKey:$,global:U,isContextDefined:B,isSpecCompliantForm:function(e){return!!(e&&x(e.append)&&"FormData"===e[p]&&e[f])},toJSONObject:e=>{let t=new WeakSet,r=e=>{if(w(e)){if(t.has(e))return;if(_(e))return e;if(!("toJSON"in e)){t.add(e);let i=v(e)?[]:{};return j(e,(e,t)=>{let n=r(e);b(n)||(i[t]=n)}),t.delete(e),i}}return e};return r(e)},isAsyncFn:K,isThenable:e=>e&&(w(e)||x(e))&&x(e.then)&&x(e.catch),setImmediate:W,asap:Y,isIterable:e=>null!=e&&x(e[f])};var X=e.i(467034);let J=Q.toObjectSet(["age","authorization","content-length","content-type","etag","expires","from","host","if-modified-since","if-unmodified-since","last-modified","location","max-forwards","proxy-authorization","referer","retry-after","user-agent"]),Z=RegExp("[\\u0000-\\u0008\\u000a-\\u001f\\u007f]+","g"),ee=RegExp("[^\\u0009\\u0020-\\u007e\\u0080-\\u00ff]+","g");function et(e,t){return Q.isArray(e)?e.map(e=>et(e,t)):function(e){let t=0,r=e.length;for(;t<r;){let r=e.charCodeAt(t);if(9!==r&&32!==r)break;t+=1}for(;r>t;){let t=e.charCodeAt(r-1);if(9!==t&&32!==t)break;r-=1}return 0===t&&r===e.length?e:e.slice(t,r)}(String(e).replace(t,""))}function er(e){let t=Object.create(null);return Q.forEach(e.toJSON(),(e,r)=>{t[r]=et(e,ee)}),t}let ei=Symbol("internals");function en(e){return e&&String(e).trim().toLowerCase()}function es(e){return!1===e||null==e?e:Q.isArray(e)?e.map(es):et(String(e),Z)}function ea(e,t,r,i,n){if(Q.isFunction(i))return i.call(this,t,r);if(n&&(t=r),Q.isString(t)){if(Q.isString(i))return -1!==t.indexOf(i);if(Q.isRegExp(i))return i.test(t)}}class eo{constructor(e){e&&this.set(e)}set(e,t,r){let i=this;function n(e,t,r){let n=en(t);if(!n)throw Error("header name must be a non-empty string");let s=Q.findKey(i,n);s&&void 0!==i[s]&&!0!==r&&(void 0!==r||!1===i[s])||(i[s||t]=es(e))}let s=(e,t)=>
1Q.forEach(e,(e,r)=>n(e,r,t));if(Q.isPlainObject(e)||e instanceof this.constructor)s(e,t);else{let i;if(Q.isString(e)&&(e=e.trim())&&(i=e,!/^[-_a-zA-Z0-9^`|~,!#$%&'*+.]+$/.test(i.trim()))){var a;let r,i,n,o;s((o={},(a=e)&&a.split("\n").forEach(function(e){n=e.indexOf(":"),r=e.substring(0,n).trim().toLowerCase(),i=e.substring(n+1).trim(),!r||o[r]&&J[r]||("set-cookie"===r?o[r]?o[r].push(i):o[r]=[i]:o[r]=o[r]?o[r]+", "+i:i)}),o),t)}else if(Q.isObject(e)&&Q.isIterable(e)){let r={},i,n;for(let t of e){if(!Q.isArray(t))throw TypeError("Object iterator must return a key-value pair");r[n=t[0]]=(i=r[n])?Q.isArray(i)?[...i,t[1]]:[i,t[1]]:t[1]}s(r,t)}else null!=e&&n(t,e,r)}return this}get(e,t){if(e=en(e)){let r=Q.findKey(this,e);if(r){let e=this[r];if(!t)return e;if(!0===t){let t,r=Object.create(null),i=/([^\s,;=]+)\s*(?:=\s*([^,;]+))?/g;for(;t=i.exec(e);)r[t[1]]=t[2];return r}if(Q.isFunction(t))return t.call(this,e,r);if(Q.isRegExp(t))return t.exec(e);throw TypeError("parser must be boolean|regexp|function")}}}has(e,t){if(e=en(e)){let r=Q.findKey(this,e);return!!(r&&void 0!==this[r]&&(!t||ea(this,this[r],r,t)))}return!1}delete(e,t){let r=this,i=!1;function n(e){if(e=en(e)){let n=Q.findKey(r,e);n&&(!t||ea(r,r[n],n,t))&&(delete r[n],i=!0)}}return Q.isArray(e)?e.forEach(n):n(e),i}clear(e){let t=Object.keys(this),r=t.length,i=!1;for(;r--;){let n=t[r];(!e||ea(this,this[n],n,e,!0))&&(delete this[n],i=!0)}return i}normalize(e){let t=this,r={};return Q.forEach(this,(i,n)=>{let s=Q.findKey(r,n);if(s){t[s]=es(i),delete t[n];return}let a=e?n.trim().toLowerCase().replace(/([a-z\d])(\w*)/g,(e,t,r)=>t.toUpperCase()+r):String(n).trim();a!==n&&delete t[n],t[a]=es(i),r[a]=!0}),this}concat(...e){return this.constructor.concat(this,...e)}toJSON(e){let t=Object.create(null);return Q.forEach(this,(r,i)=>{null!=r&&!1!==r&&(t[i]=e&&Q.isArray(r)?r.join(", "):r)}),t}[Symbol.iterator](){return Object.entries(this.toJSON())[Symbol.iterator]()}toString(){return Object.entries(this.toJSON()).map(([e,t])=>e+": "+t).join("\n")}getSetCookie(){return this.get("set-cookie")||[]}get[Symbol.toStringTag](){return"AxiosHeaders"}static from(e){return e instanceof this?e:new this(e)}static concat(e,...t){let r=new this(e);return t.forEach(e=>r.set(e)),r}static accessor(e){let t=(this[ei]=this[ei]={accessors:{}}).accessors,r=this.prototype;function i(e){let i=en(e);if(!t[i]){let n;n=Q.toCamelCase(" "+e),["get","set","has"].forEach(t=>{Object.defineProperty(r,t+n,{__proto__:null,value:function(r,i,n){return this[t].call(this,e,r,i,n)},configurable:!0})}),t[i]=!0}}return Q.isArray(e)?e.forEach(i):i(e),this}}eo.accessor(["Content-Type","Content-Length","Accept","Accept-Encoding","User-Agent","Authorization"]),Q.reduceDescriptors(eo.prototype,({value:e},t)=>{let r=t[0].toUpperCase()+t.slice(1);return{get:()=>e,set(e){this[r]=e}}}),Q.freezeMethods(eo);class el extends Error{static from(e,t,r,i,n,s){let a=new el(e.message,t||e.code,r,i,n);return a.cause=e,a.name=e.name,null!=e.status&&null==a.status&&(a.status=e.status),s&&Object.assign(a,s),a}constructor(e,t,r,i,n){super(e),Object.defineProperty(this,"message",{__proto__:null,value:e,enumerable:!0,writable:!0,configurable:!0}),this.name="AxiosError",this.isAxiosError=!0,t&&(this.code=t),r&&(this.config=r),i&&(this.request=i),n&&(this.response=n,this.status=n.status)}toJSON(){let e,t,r,i=this.config,n=i&&Q.hasOwnProp(i,"redact")?i.redact:void 0,s=Q.isArray(n)&&n.length>0?(e=new Set(n.map(e=>String(e).toLowerCase())),t=[],(r=i=>{let n;if(null===i||"object"!=typeof i||Q.isBuffer(i))return i;if(-1===t.indexOf(i)){if(i instanceof eo&&(i=i.toJSON()),t.push(i),Q.isArray(i))n=[],i.forEach((e,t)=>{let i=r(e);Q.isUndefined(i)||(n[t]=i)});else{if(!Q.isPlainObject(i)&&function(e){if(Q.hasOwnProp(e,"toJSON"))return!0;let t=Object.getPrototypeOf(e);for(;t&&t!==Object.prototype;){if(Q.hasOwnProp(t,"toJSON"))return!0;t=Object.getPrototypeOf(t)}return!1}(i))return t.pop(),i;for(let[t,s]of(n=Object.create(null),Object.entries(i))){let i=e.has(t.toLowerCase())?"[REDACTED ****]":r(s);Q.isUndefined(i)||(n[t]=i)}}return t.pop(),n}})(i)):Q.toJSONObject(i);return{message:this.message,name:this.name,description:this.description,number:this.number,fileName:this.fileName,lineNumber:this.lineNumber,columnNumber:this.columnNumber,stack:this.stack,config:s,code:this.code,status:this.status}}}el.ERR_BAD_OPTION_VALUE="ERR_BAD_OPTION_VALUE",el.ERR_BAD_OPTION="ERR_BAD_OPTION",el.ECONNABORTED="ECONNABORTED",el.ETIMEDOUT="ETIMEDOUT",el.ECONNREFUSED="ECONNREFUSED",el.ERR_NETWORK="ERR_NETWORK",el.ERR_FR_TOO_MANY_REDIRECTS="ERR_FR_TOO_MANY_REDIRECTS",el.ERR_DEPRECATED="ERR_DEPRECATED",el.ERR_BAD_RESPONSE="ERR_BAD_RESPONSE",el.ERR_BAD_REQUEST="ERR_BAD_REQUEST",el.ERR_CANCELED="ERR_CANCELED",el.ERR_NOT_SUPPORT="ERR_NOT_SUPPORT",el.ERR_INVALID_URL="ERR_INVALID_URL",el.ERR_FORM_DATA_DEPTH_EXCEEDED="ERR_FORM_DATA_DEPTH_EXCEEDED";let eu=el;function ec(e){return Q.isPlainObject(e)||Q.isArray(e)}function ed(e){return Q.endsWith(e,"[]")?e.slice(0,-2):e}function eh(e,t,r){return e?e.concat(t).map(function(e,t){return e=ed(e),!r&&t?"["+e+"]":e}).join(r?".":""):t}let ef=Q.toFlatObject(Q,{},null,function(e){return/^is[A-Z]/.test(e)}),ep=function(e,t,r){if(!Q.isObject(e))throw TypeError("target must be an object");t=t||new FormData;let i=(r=Q.toFlatObject(r,{metaTokens:!0,dots:!1,indexes:!1},!1,function(e,t){return!Q.isUndefined(t[e])})).metaTokens,n=r.visitor||d,s=r.dots,a=r.indexes,o=r.Blob||"u">typeof Blob&&Blob,l=void 0===r.maxDepth?100:r.maxDepth,u=o&&Q.isSpecCompliantForm(t);if(!Q.isFunction(n))throw TypeError("visitor must be a function");function c(e){if(null===e)return"";if(Q.isDate(e))return e.toISOString();if(Q.isBoolean(e))return e.toString();if(!u&&Q.isBlob(e))throw new eu("Blob is not supported. Use a Buffer instead.");return Q.isArrayBuffer(e)||Q.isTypedArray(e)?u&&"function"==typeof Blob?new Blob([e]):X.Buffer.from(e):e}function d(e,r,n){let o=e;if(Q.isReactNative(t)&&Q.isReactNativeBlob(e))return t.append(eh(n,r,s),c(e)),!1;if(e&&!n&&"object"==typeof e)if(Q.endsWith(r,"{}"))r=i?r:r.slice(0,-2),e=JSON.stringify(e);else{var l;if(Q.isArray(e)&&(l=e,Q.isArray(l)&&!l.some(ec))||(Q.isFileList(e)||Q.endsWith(r,"[]"))&&(o=Q.toArray(e)))return r=ed(r),o.forEach(function(e,i){Q.isUndefined(e)||null===e||t.append(!0===a?eh([r],i,s):null===a?r:r+"[]",c(e))}),!1}return!!ec(e)||(t.append(eh(n,r,s),c(e)),!1)}let h=[],f=Object.assign(ef,{defaultVisitor:d,convertValue:c,isVisitable:ec});if(!Q.isObject(e))throw TypeError("data must be an object");return!function e(r,i,s=0){if(!Q.isUndefined(r)){if(s>l)throw new eu("Object is too deeply nested ("+s+" levels). Max depth: "+l,eu.ERR_FORM_DATA_DEPTH_EXCEEDED);if(-1!==h.indexOf(r))throw Error("Circular reference detected in "+i.join("."));h.push(r),Q.forEach(r,function(r,a){!0===(!(Q.isUndefined(r)||null===r)&&n.call(t,r,Q.isString(a)?a.trim():a,i,f))&&e(r,i?i.concat(a):[a],s+1)}),h.pop()}}(e),t};
1function eg(e){let t={"!":"%21","'":"%27","(":"%28",")":"%29","~":"%7E","%20":"+"};return encodeURIComponent(e).replace(/[!'()~]|%20/g,function(e){return t[e]})}function em(e,t){this._pairs=[],e&&ep(e,this,t)}let ey=em.prototype;function ev(e){return encodeURIComponent(e).replace(/%3A/gi,":").replace(/%24/g,"$").replace(/%2C/gi,",").replace(/%20/g,"+")}function eb(e,t,r){let i;if(!t)return e;let n=r&&r.encode||ev,s=Q.isFunction(r)?{serialize:r}:r,a=s&&s.serialize;if(i=a?a(t,s):Q.isURLSearchParams(t)?t.toString():new em(t,s).toString(n)){let t=e.indexOf("#");-1!==t&&(e=e.slice(0,t)),e+=(-1===e.indexOf("?")?"?":"&")+i}return e}ey.append=function(e,t){this._pairs.push([e,t])},ey.toString=function(e){let t=e?function(t){return e.call(this,t,eg)}:eg;return this._pairs.map(function(e){return t(e[0])+"="+t(e[1])},"").join("&")};let e_=class{constructor(){this.handlers=[]}use(e,t,r){return this.handlers.push({fulfilled:e,rejected:t,synchronous:!!r&&r.synchronous,runWhen:r?r.runWhen:null}),this.handlers.length-1}eject(e){this.handlers[e]&&(this.handlers[e]=null)}clear(){this.handlers&&(this.handlers=[])}forEach(e){Q.forEach(this.handlers,function(t){null!==t&&e(t)})}},eE={silentJSONParsing:!0,forcedJSONParsing:!0,clarifyTimeoutError:!1,legacyInterceptorReqResOrdering:!0},eS="u">typeof URLSearchParams?URLSearchParams:em,ex="u">typeof FormData?FormData:null,eT="u">typeof Blob?Blob:null,ew="u">typeof window&&"u">typeof document,eA="object"==typeof navigator&&navigator||void 0,eR=ew&&(!eA||0>["ReactNative","NativeScript","NS"].indexOf(eA.product)),eI="u">typeof WorkerGlobalScope&&self instanceof WorkerGlobalScope&&"function"==typeof self.importScripts,ek=ew&&window.location.href||"http://localhost";e.s(["hasBrowserEnv",0,ew,"hasStandardBrowserEnv",0,eR,"hasStandardBrowserWebWorkerEnv",0,eI,"navigator",0,eA,"origin",0,ek],557536);let eC={...e.i(557536),isBrowser:!0,classes:{URLSearchParams:eS,FormData:ex,Blob:eT},protocols:["http","https","file","blob","url","data"]},eD=function(e){if(Q.isFormData(e)&&Q.isFunction(e.entries)){let t={};return Q.forEachEntry(e,(e,r)=>{!function e(t,r,i,n){let s=t[n++];if("__proto__"===s)return!0;let a=Number.isFinite(+s),o=n>=t.length;return(s=!s&&Q.isArray(i)?i.length:s,o)?Q.hasOwnProp(i,s)?i[s]=Q.isArray(i[s])?i[s].concat(r):[i[s],r]:i[s]=r:(Q.hasOwnProp(i,s)&&Q.isObject(i[s])||(i[s]=[]),e(t,r,i[s],n)&&Q.isArray(i[s])&&(i[s]=function(e){let t,r,i={},n=Object.keys(e),s=n.length;for(t=0;t<s;t++)i[r=n[t]]=e[r];return i}(i[s]))),!a}(Q.matchAll(/\w+|\[(\w*)]/g,e).map(e=>"[]"===e[0]?"":e[1]||e[0]),r,t,0)}),t}return null},eL=(e,t)=>null!=e&&Q.hasOwnProp(e,t)?e[t]:void 0,eO={transitional:eE,adapter:["xhr","http","fetch"],transformRequest:[function(e,t){let r,i=t.getContentType()||"",n=i.indexOf("application/json")>-1,s=Q.isObject(e);if(s&&Q.isHTMLForm(e)&&(e=new FormData(e)),Q.isFormData(e))return n?JSON.stringify(eD(e)):e;if(Q.isArrayBuffer(e)||Q.isBuffer(e)||Q.isStream(e)||Q.isFile(e)||Q.isBlob(e)||Q.isReadableStream(e))return e;if(Q.isArrayBufferView(e))return e.buffer;if(Q.isURLSearchParams(e))return t.setContentType("application/x-www-form-urlencoded;charset=utf-8",!1),e.toString();
1if(s){let t=eL(this,"formSerializer");if(i.indexOf("application/x-www-form-urlencoded")>-1)return ep(e,new eC.classes.URLSearchParams,{visitor:function(e,t,r,i){return eC.isNode&&Q.isBuffer(e)?(this.append(t,e.toString("base64")),!1):i.defaultVisitor.apply(this,arguments)},...t}).toString();if((r=Q.isFileList(e))||i.indexOf("multipart/form-data")>-1){let i=eL(this,"env"),n=i&&i.FormData;return ep(r?{"files[]":e}:e,n&&new n,t)}}if(s||n){t.setContentType("application/json",!1);var a=e;if(Q.isString(a))try{return(0,JSON.parse)(a),Q.trim(a)}catch(e){if("SyntaxError"!==e.name)throw e}return(0,JSON.stringify)(a)}return e}],transformResponse:[function(e){let t=eL(this,"transitional")||eO.transitional,r=t&&t.forcedJSONParsing,i=eL(this,"responseType"),n="json"===i;if(Q.isResponse(e)||Q.isReadableStream(e))return e;if(e&&Q.isString(e)&&(r&&!i||n)){let r=t&&t.silentJSONParsing;try{return JSON.parse(e,eL(this,"parseReviver"))}catch(e){if(!r&&n){if("SyntaxError"===e.name)throw eu.from(e,eu.ERR_BAD_RESPONSE,this,null,eL(this,"response"));throw e}}}return e}],timeout:0,xsrfCookieName:"XSRF-TOKEN",xsrfHeaderName:"X-XSRF-TOKEN",maxContentLength:-1,maxBodyLength:-1,env:{FormData:eC.classes.FormData,Blob:eC.classes.Blob},validateStatus:function(e){return e>=200&&e<300},headers:{common:{Accept:"application/json, text/plain, */*","Content-Type":void 0}}};function eP(e,t){let r=this||eO,i=t||r,n=eo.from(i.headers),s=i.data;return Q.forEach(e,function(e){s=e.call(r,s,n.normalize(),t?t.status:void 0)}),n.normalize(),s}function eF(e){return!!(e&&e.__CANCEL__)}
1Q.forEach(["delete","get","head","post","put","patch","query"],e=>{eO.headers[e]={}});let eN=class extends eu{constructor(e,t,r){super(null==e?"canceled":e,eu.ERR_CANCELED,t,r),this.name="CanceledError",this.__CANCEL__=!0}};function eM(e,t,r){let i=r.config.validateStatus;!r.status||!i||i(r.status)?e(r):t(new eu("Request failed with status code "+r.status,r.status>=400&&r.status<500?eu.ERR_BAD_REQUEST:eu.ERR_BAD_RESPONSE,r.config,r.request,r))}let ej=function(e,t){let r,i=Array(e=e||10),n=Array(e),s=0,a=0;return t=void 0!==t?t:1e3,function(o){let l=Date.now(),u=n[a];r||(r=l),i[s]=o,n[s]=l;let c=a,d=0;for(;c!==s;)d+=i[c++],c%=e;if((s=(s+1)%e)===a&&(a=(a+1)%e),l-r<t)return;let h=u&&l-u;return h?Math.round(1e3*d/h):void 0}},e$=function(e,t){let r,i,n=0,s=1e3/t,a=(t,s=Date.now())=>{n=s,r=null,i&&(clearTimeout(i),i=null),e(...t)};return[(...e)=>{let t=Date.now(),o=t-n;o>=s?a(e,t):(r=e,i||(i=setTimeout(()=>{i=null,a(r)},s-o)))},()=>r&&a(r)]},eU=(e,t,r=3)=>{let i=0,n=ej(50,250);return e$(r=>{if(!r||"number"!=typeof r.loaded)return;let s=r.loaded,a=r.lengthComputable?r.total:void 0,o=null!=a?Math.min(s,a):s,l=Math.max(0,o-i),u=n(l);i=Math.max(i,o),e({loaded:o,total:a,progress:a?o/a:void 0,bytes:l,rate:u||void 0,estimated:u&&a?(a-o)/u:void 0,event:r,lengthComputable:null!=a,[t?"download":"upload"]:!0})},r)},eB=(e,t)=>{let r=null!=e;return[i=>t[0]({lengthComputable:r,total:e,loaded:i}),t[1]]},eV=e=>(...t)=>Q.asap(()=>e(...t)),eG=eC.hasStandardBrowserEnv?(i=new URL(eC.origin),n=eC.navigator&&/(msie|trident)/i.test(eC.navigator.userAgent),e=>(e=new URL(e,eC.origin),i.protocol===e.protocol&&i.host===e.host&&(n||i.port===e.port))):()=>!0,eq=eC.hasStandardBrowserEnv?{write(e,t,r,i,n,s,a){if("u"<typeof document)return;let o=[`${e}=${encodeURIComponent(t)}`];Q.isNumber(r)&&o.push(`expires=${new Date(r).toUTCString()}`),Q.isString(i)&&o.push(`path=${i}`),Q.isString(n)&&o.push(`domain=${n}`),!0===s&&o.push("secure"),Q.isString(a)&&o.push(`SameSite=${a}`),document.cookie=o.join("; ")},read(e){if("u"<typeof document)return null;let t=document.cookie.split(";");for(let r=0;r<t.length;r++){let i=t[r].replace(/^\s+/,""),n=i.indexOf("=");if(-1!==n&&i.slice(0,n)===e)return decodeURIComponent(i.slice(n+1))}return null},remove(e){this.write(e,"",Date.now()-864e5,"/")}}:{write(){},read:()=>null,remove(){}};function eH(e,t,r){let i=!("string"==typeof t&&/^([a-z][a-z\d+\-.]*:)?\/\//i.test(t));return e&&(i||!1===r)?t?e.replace(/\/?\/$/,"")+"/"+t.replace(/^\/+/,""):e:t}let ez=e=>e instanceof eo?{...e}:e;function eK(e,t){t=t||{};let r=Object.create(null);function i(e,t,r,i){return Q.isPlainObject(e)&&Q.isPlainObject(t)?Q.merge.call({caseless:i},e,t):Q.isPlainObject(t)?Q.merge({},t):Q.isArray(t)?t.slice():t}function n(e,t,r,n){return Q.isUndefined(t)?Q.isUndefined(e)?void 0:i(void 0,e,r,n):i(e,t,r,n)}function s(e,t){if(!Q.isUndefined(t))return i(void 0,t)}function a(e,t){return Q.isUndefined(t)?Q.isUndefined(e)?void 0:i(void 0,e):i(void 0,t)}function o(r,n,s){return Q.hasOwnProp(t,s)?i(r,n):Q.hasOwnProp(e,s)?i(void 0,r):void 0}Object.defineProperty(r,"hasOwnProperty",{__proto__:null,value:Object.prototype.hasOwnProperty,enumerable:!1,writable:!0,configurable:!0});let l={url:s,method:s,data:s,baseURL:a,transformRequest:a,transformResponse:a,paramsSerializer:a,timeout:a,timeoutMessage:a,withCredentials:a,withXSRFToken:a,adapter:a,responseType:a,xsrfCookieName:a,xsrfHeaderName:a,onUploadProgress:a,onDownloadProgress:a,decompress:a,maxContentLength:a,maxBodyLength:a,beforeRedirect:a,transport:a,httpAgent:a,httpsAgent:a,cancelToken:a,socketPath:a,allowedSocketPaths:a,responseEncoding:a,validateStatus:o,headers:(e,t,r)=>n(ez(e),ez(t),r,!0)};return Q.forEach(Object.keys({...e,...t}),function(i){if("__proto__"===i||"constructor"===i||"prototype"===i)return;let s=Q.hasOwnProp(l,i)?l[i]:n,a=s(Q.hasOwnProp(e,i)?e[i]:void 0,Q.hasOwnProp(t,i)?t[i]:void 0,i);Q.isUndefined(a)&&s!==o||(r[i]=a)}),r}let eW=["content-type","content-length"],eY=e=>{let t=eK({},e),r=e=>Q.hasOwnProp(t,e)?t[e]:void 0,i=r("data"),n=r("withXSRFToken"),s=r("xsrfHeaderName"),a=r("xsrfCookieName"),o=r("headers"),l=r("auth"),u=r("baseURL"),c=r("allowAbsoluteUrls"),d=r("url");
1if(t.headers=o=eo.from(o),t.url=eb(eH(u,d,c),e.params,e.paramsSerializer),l&&o.set("Authorization","Basic "+btoa((l.username||"")+":"+(l.password?encodeURIComponent(l.password).replace(/%([0-9A-F]{2})/gi,(e,t)=>String.fromCharCode(parseInt(t,16))):""))),Q.isFormData(i))if(eC.hasStandardBrowserEnv||eC.hasStandardBrowserWebWorkerEnv)o.setContentType(void 0);else{var h,f;Q.isFunction(i.getHeaders)&&(h=o,f=i.getHeaders(),"content-only"!==r("formDataHeaderPolicy")?h.set(f):Object.entries(f).forEach(([e,t])=>{eW.includes(e.toLowerCase())&&h.set(e,t)}))}if(eC.hasStandardBrowserEnv&&(Q.isFunction(n)&&(n=n(t)),!0===n||null==n&&eG(t.url))){let e=s&&a&&eq.read(a);e&&o.set(s,e)}return t},eQ="u">typeof XMLHttpRequest&&function(e){return new Promise(function(t,r){var i;let n,s,a,o,l,u,c=eY(e),d=c.data,h=eo.from(c.headers).normalize(),{responseType:f,onUploadProgress:p,onDownloadProgress:g}=c;function m(){o&&o(),l&&l(),c.cancelToken&&c.cancelToken.unsubscribe(n),c.signal&&c.signal.removeEventListener("abort",n)}let y=new XMLHttpRequest;function v(){if(!y)return;let i=eo.from("getAllResponseHeaders"in y&&y.getAllResponseHeaders());eM(function(e){t(e),m()},function(e){r(e),m()},{data:f&&"text"!==f&&"json"!==f?y.response:y.responseText,status:y.status,statusText:y.statusText,headers:i,config:e,request:y}),y=null}y.open(c.method.toUpperCase(),c.url,!0),y.timeout=c.timeout,"onloadend"in y?y.onloadend=v:y.onreadystatechange=function(){!y||4!==y.readyState||(0!==y.status||y.responseURL&&y.responseURL.startsWith("file:"))&&setTimeout(v)},y.onabort=function(){y&&(r(new eu("Request aborted",eu.ECONNABORTED,e,y)),m(),y=null)},y.onerror=function(t){let i=new eu(t&&t.message?t.message:"Network Error",eu.ERR_NETWORK,e,y);i.event=t||null,r(i),m(),y=null},y.ontimeout=function(){let t=c.timeout?"timeout of "+c.timeout+"ms exceeded":"timeout exceeded",i=c.transitional||eE;c.timeoutErrorMessage&&(t=c.timeoutErrorMessage),r(new eu(t,i.clarifyTimeoutError?eu.ETIMEDOUT:eu.ECONNABORTED,e,y)),m(),y=null},void 0===d&&h.setContentType(null),"setRequestHeader"in y&&Q.forEach(er(h),function(e,t){y.setRequestHeader(t,e)}),Q.isUndefined(c.withCredentials)||(y.withCredentials=!!c.withCredentials),f&&"json"!==f&&(y.responseType=c.responseType),g&&([a,l]=eU(g,!0),y.addEventListener("progress",a)),p&&y.upload&&([s,o]=eU(p),y.upload.addEventListener("progress",s),y.upload.addEventListener("loadend",o)),(c.cancelToken||c.signal)&&(n=t=>{y&&(r(!t||t.type?new eN(null,e,y):t),y.abort(),m(),y=null)},c.cancelToken&&c.cancelToken.subscribe(n),c.signal&&(c.signal.aborted?n():c.signal.addEventListener("abort",n)));let b=(i=c.url,(u=/^([-+\w]{1,25}):(?:\/\/)?/.exec(i))&&u[1]||"");b&&!eC.protocols.includes(b)?r(new eu("Unsupported protocol "+b+":",eu.ERR_BAD_REQUEST,e)):y.send(d||null)})},eX=function*(e,t){let r,i=e.byteLength;if(!t||i<t)return void(yield e);let n=0;for(;n<i;)r=n+t,yield e.slice(n,r),n=r},eJ=async function*(e,t){for await(let r of eZ(e))yield*eX(r,t)},eZ=async function*(e){if(e[Symbol.asyncIterator])return void(yield*e);let t=e.getReader();try{for(;;){let{done:e,value:r}=await t.read();if(e)break;yield r}}finally{await t.cancel()}},e0=(e,t,r,i)=>{let n,s=eJ(e,t),a=0,o=e=>{!n&&(n=!0,i&&i(e))};return new ReadableStream({async pull(e){try{let{done:t,value:i}=await s.next();if(t){o(),e.close();return}let n=i.byteLength;if(r){let e=a+=n;r(e)}e.enqueue(new Uint8Array(i))}catch(e){throw o(e),e}},cancel:e=>(o(e),s.return())},{highWaterMark:2})},e1="1.16.1",{isFunction:e2}=Q,e3=(e,...t)=>{try{return!!e(...t)}catch(e){return!1}},e4=e=>{let t,r=void 0!==Q.global&&null!==Q.global?Q.global:globalThis,{ReadableStream:i,TextEncoder:n}=r,{fetch:s,Request:a,Response:o}=e=Q.merge.call({skipUndefined:!0},{Request:r.Request,Response:r.Response},e),l=s?e2(s):"function"==typeof fetch,u=e2(a),c=e2(o);if(!l)return!1;let d=l&&e2(i),h=l&&("function"==typeof n?(t=new n,e=>t.encode(e)):async e=>new Uint8Array(await new a(e).arrayBuffer())),f=u&&d&&e3(()=>{let e=!1,t=new a(eC.origin,{body:new i,method:"POST",get duplex(){return e=!0,"half"}}),r=t.headers.has("Content-Type");return null!=t.body&&t.body.cancel(),e&&!r}),p=c&&d&&e3(()=>
1Q.isReadableStream(new o("").body)),g={stream:p&&(e=>e.body)};l&&["text","arrayBuffer","blob","formData","stream"].forEach(e=>{g[e]||(g[e]=(t,r)=>{let i=t&&t[e];if(i)return i.call(t);throw new eu(`Response type '${e}' is not supported`,eu.ERR_NOT_SUPPORT,r)})});let m=async e=>{if(null==e)return 0;if(Q.isBlob(e))return e.size;if(Q.isSpecCompliantForm(e)){let t=new a(eC.origin,{method:"POST",body:e});return(await t.arrayBuffer()).byteLength}return Q.isArrayBufferView(e)||Q.isArrayBuffer(e)?e.byteLength:(Q.isURLSearchParams(e)&&(e+=""),Q.isString(e))?(await h(e)).byteLength:void 0},y=async(e,t)=>{let r=Q.toFiniteNumber(e.getContentLength());return null==r?m(t):r};return async e=>{let t,{url:r,method:i,data:l,signal:c,cancelToken:d,timeout:h,onDownloadProgress:m,onUploadProgress:v,responseType:b,headers:_,withCredentials:E="same-origin",fetchOptions:S,maxContentLength:x,maxBodyLength:T}=eY(e),w=Q.isNumber(x)&&x>-1,A=Q.isNumber(T)&&T>-1,R=s||fetch;b=b?(b+"").toLowerCase():"text";let I=((e,t)=>{if(e=e?e.filter(Boolean):[],!t&&!e.length)return;let r=new AbortController,i=!1,n=function(e){if(!i){i=!0,a();let t=e instanceof Error?e:this.reason;r.abort(t instanceof eu?t:new eN(t instanceof Error?t.message:t))}},s=t&&setTimeout(()=>{s=null,n(new eu(`timeout of ${t}ms exceeded`,eu.ETIMEDOUT))},t),a=()=>{e&&(s&&clearTimeout(s),s=null,e.forEach(e=>{e.unsubscribe?e.unsubscribe(n):e.removeEventListener("abort",n)}),e=null)};e.forEach(e=>e.addEventListener("abort",n));let{signal:o}=r;return o.unsubscribe=()=>Q.asap(a),o}
1)([c,d&&d.toAbortSignal()],h),k=null,C=I&&I.unsubscribe&&(()=>{I.unsubscribe()});try{if(w&&"string"==typeof r&&r.startsWith("data:")&&function(e){if(!e||"string"!=typeof e||!e.startsWith("data:"))return 0;let t=e.indexOf(",");if(t<0)return 0;let r=e.slice(5,t),i=e.slice(t+1);if(/;base64/i.test(r)){let e=i.length,t=i.length;for(let r=0;r<t;r++)if(37===i.charCodeAt(r)&&r+2<t){let t=i.charCodeAt(r+1),n=i.charCodeAt(r+2);(t>=48&&t<=57||t>=65&&t<=70||t>=97&&t<=102)&&(n>=48&&n<=57||n>=65&&n<=70||n>=97&&n<=102)&&(e-=2,r+=2)}let r=0,n=t-1,s=e=>e>=2&&37===i.charCodeAt(e-2)&&51===i.charCodeAt(e-1)&&(68===i.charCodeAt(e)||100===i.charCodeAt(e));n>=0&&(61===i.charCodeAt(n)?(r++,n--):s(n)&&(r++,n-=3)),1===r&&n>=0&&(61===i.charCodeAt(n)?r++:s(n)&&r++);let a=3*Math.floor(e/4)-(r||0);return a>0?a:0}if(void 0!==X.Buffer&&"function"==typeof X.Buffer.byteLength)return X.Buffer.byteLength(i,"utf8");let n=0;for(let e=0,t=i.length;e<t;e++){let r=i.charCodeAt(e);if(r<128)n+=1;else if(r<2048)n+=2;else if(r>=55296&&r<=56319&&e+1<t){let t=i.charCodeAt(e+1);t>=56320&&t<=57343?(n+=4,e++):n+=3}else n+=3}return n}(r)>x)throw new eu("maxContentLength size of "+x+" exceeded",eu.ERR_BAD_RESPONSE,e,k);if(A&&"get"!==i&&"head"!==i){let t=await y(_,l);if("number"==typeof t&&isFinite(t)&&t>T)throw new eu("Request body larger than maxBodyLength limit",eu.ERR_BAD_REQUEST,e,k)}if(v&&f&&"get"!==i&&"head"!==i&&0!==(t=await y(_,l))){let e,i=new a(r,{method:"POST",body:l,duplex:"half"});if(Q.isFormData(l)&&(e=i.headers.get("content-type"))&&_.setContentType(e),i.body){let[e,r]=eB(t,eU(eV(v)));l=e0(i.body,65536,e,r)}}Q.isString(E)||(E=E?"include":"omit");let s=u&&"credentials"in a.prototype;if(Q.isFormData(l)){let e=_.getContentType();e&&/^multipart\/form-data/i.test(e)&&!/boundary=/i.test(e)&&_.delete("content-type")}_.set("User-Agent","axios/"+e1,!1);let c={...S,signal:I,method:i.toUpperCase(),headers:er(_.normalize()),body:l,duplex:"half",credentials:s?E:void 0};k=u&&new a(r,c);let d=await (u?R(k,S):R(r,c));if(w){let t=Q.toFiniteNumber(d.headers.get("content-length"));if(null!=t&&t>x)throw new eu("maxContentLength size of "+x+" exceeded",eu.ERR_BAD_RESPONSE,e,k)}let h=p&&("stream"===b||"response"===b);if(p&&d.body&&(m||w||h&&C)){let t={};["status","statusText","headers"].forEach(e=>{t[e]=d[e]});let r=Q.toFiniteNumber(d.headers.get("content-length")),[i,n]=m&&eB(r,eU(eV(m),!0))||[];d=new o(e0(d.body,65536,t=>{if(w&&t>x)throw new eu("maxContentLength size of "+x+" exceeded",eu.ERR_BAD_RESPONSE,e,k);i&&i(t)},()=>{n&&n(),C&&C()}),t)}b=b||"text";let D=await g[Q.findKey(g,b)||"text"](d,e);if(w&&!p&&!h){let t;if(null!=D&&("number"==typeof D.byteLength?t=D.byteLength:"number"==typeof D.size?t=D.size:"string"==typeof D&&(t="function"==typeof n?new n().encode(D).byteLength:D.length)),"number"==typeof t&&t>x)throw new eu("maxContentLength size of "+x+" exceeded",eu.ERR_BAD_RESPONSE,e,k)}return!h&&C&&C(),await new Promise((t,r)=>{eM(t,r,{data:D,headers:eo.from(d.headers),status:d.status,statusText:d.statusText,config:e,request:k})})}catch(t){if(C&&C(),I&&I.aborted&&I.reason instanceof eu){let r=I.reason;throw r.config=e,k&&(r.request=k),t!==r&&(r.cause=t),r}if(t&&"TypeError"===t.name&&/Load failed|fetch/i.test(t.message))throw Object.assign(new eu("Network Error",eu.ERR_NETWORK,e,k,t&&t.response),{cause:t.cause||t});throw eu.from(t,t&&t.code,e,k,t&&t.response)}}},e5=new Map,e8=e=>{let t=e&&e.env||{},{fetch:r,Request:i,Response:n}=t,s=[i,n,r],a=s.length,o,l,u=e5;for(;a--;)o=s[a],void 0===(l=u.get(o))&&u.set(o,l=a?new Map:e4(t)),u=l;return l};e8();let e6={http:null,xhr:eQ,fetch:{get:e8}};Q.forEach(e6,(e,t)=>{if(e){try{Object.defineProperty(e,"name",{__proto__:null,value:t})}catch(e){}Object.defineProperty(e,"adapterName",{__proto__:null,value:t})}});let e7=e=>`- ${e}`,e9=e=>Q.isFunction(e)||null===e||!1===e,te=function(e,t){let r,i,{length:n}=e=Q.isArray(e)?e:[e],s={};for(let a=0;a<n;a++){let n;if(i=r=e[a],!e9(r)&&void 0===(i=e6[(n=String(r)).toLowerCase()]))throw new eu(`Unknown adapter '${n}'`);if(i&&(Q.isFunction(i)||(i=i.get(t))))break;s[n||"#"+a]=i}if(!i){let e=Object.entries(s).map(([e,t])=>`adapter ${e} `+(!1===t?"is not supported by the environment":"is not available in the build"));throw new eu("There is no suitable adapter to dispatch the request "+(n?e.length>
11?"since :\n"+e.map(e7).join("\n"):" "+e7(e[0]):"as no adapter specified"),"ERR_NOT_SUPPORT")}return i};function tt(e){if(e.cancelToken&&e.cancelToken.throwIfRequested(),e.signal&&e.signal.aborted)throw new eN(null,e)}function tr(e){return tt(e),e.headers=eo.from(e.headers),e.data=eP.call(e,e.transformRequest),-1!==["post","put","patch"].indexOf(e.method)&&e.headers.setContentType("application/x-www-form-urlencoded",!1),te(e.adapter||eO.adapter,e)(e).then(function(t){tt(e),e.response=t;try{t.data=eP.call(e,e.transformResponse,t)}finally{delete e.response}return t.headers=eo.from(t.headers),t},function(t){if(!eF(t)&&(tt(e),t&&t.response)){e.response=t.response;try{t.response.data=eP.call(e,e.transformResponse,t.response)}finally{delete e.response}t.response.headers=eo.from(t.response.headers)}return Promise.reject(t)})}let ti={};["object","boolean","number","function","string","symbol"].forEach((e,t)=>{ti[e]=function(r){return typeof r===e||"a"+(t<1?"n ":" ")+e}});let tn={};ti.transitional=function(e,t,r){function i(e,t){return"[Axios v"+e1+"] Transitional option '"+e+"'"+t+(r?". "+r:"")}return(r,n,s)=>{if(!1===e)throw new eu(i(n," has been removed"+(t?" in "+t:"")),eu.ERR_DEPRECATED);return t&&!tn[n]&&(tn[n]=!0,console.warn(i(n," has been deprecated since v"+t+" and will be removed in the near future"))),!e||e(r,n,s)}},ti.spelling=function(e){return(t,r)=>(console.warn(`${r} is likely a misspelling of ${e}`),!0)};let ts=function(e,t,r){if("object"!=typeof e)throw new eu("options must be an object",eu.ERR_BAD_OPTION_VALUE);let i=Object.keys(e),n=i.length;for(;n-- >0;){let s=i[n],a=Object.prototype.hasOwnProperty.call(t,s)?t[s]:void 0;if(a){let t=e[s],r=void 0===t||a(t,s,e);if(!0!==r)throw new eu("option "+s+" must be "+r,eu.ERR_BAD_OPTION_VALUE);continue}if(!0!==r)throw new eu("Unknown option "+s,eu.ERR_BAD_OPTION)}};class ta{constructor(e){this.defaults=e||{},this.interceptors={request:new e_,response:new e_}}async request(e,t){try{return await this._request(e,t)}catch(e){if(e instanceof Error){let t={};Error.captureStackTrace?Error.captureStackTrace(t):t=Error();let r=(()=>{if(!t.stack)return"";let e=t.stack.indexOf("\n");return -1===e?"":t.stack.slice(e+1)})();try{if(e.stack){if(r){let t=r.indexOf("\n"),i=-1===t?-1:r.indexOf("\n",t+1),n=-1===i?"":r.slice(i+1);String(e.stack).endsWith(n)||(e.stack+="\n"+r)}}else e.stack=r}catch(e){}}throw e}}_request(e,t){let r,i;"string"==typeof e?(t=t||{}).url=e:t=e||{};let{transitional:n,paramsSerializer:s,headers:a}=t=eK(this.defaults,t);void 0!==n&&ts(n,{silentJSONParsing:ti.transitional(ti.boolean),forcedJSONParsing:ti.transitional(ti.boolean),clarifyTimeoutError:ti.transitional(ti.boolean),legacyInterceptorReqResOrdering:ti.transitional(ti.boolean)},!1),null!=s&&(Q.isFunction(s)?t.paramsSerializer={serialize:s}:ts(s,{encode:ti.function,serialize:ti.function},!0)),void 0!==t.allowAbsoluteUrls||(void 0!==this.defaults.allowAbsoluteUrls?t.allowAbsoluteUrls=this.defaults.allowAbsoluteUrls:t.allowAbsoluteUrls=!0),ts(t,{baseUrl:ti.spelling("baseURL"),withXsrfToken:ti.spelling("withXSRFToken")},!0),t.method=(t.method||this.defaults.method||"get").toLowerCase();let o=a&&Q.merge(a.common,a[t.method]);a&&Q.forEach(["delete","get","head","post","put","patch","query","common"],e=>{delete a[e]}),t.headers=eo.concat(o,a);let l=[],u=!0;this.interceptors.request.forEach(function(e){if("function"==typeof e.runWhen&&!1===e.runWhen(t))return;u=u&&e.synchronous;let r=t.transitional||eE;r&&r.legacyInterceptorReqResOrdering?l.unshift(e.fulfilled,e.rejected):l.push(e.fulfilled,e.rejected)});let c=[];this.interceptors.response.forEach(function(e){c.push(e.fulfilled,e.rejected)});let d=0;if(!u){let e=[tr.bind(this),void 0];for(e.unshift(...l),e.push(...c),i=e.length,r=Promise.resolve(t);d<i;)r=r.then(e[d++],e[d++]);return r}i=l.length;let h=t;for(;d<i;){let e=l[d++],t=l[d++];try{h=e(h)}catch(e){t.call(this,e);break}}try{r=tr.call(this,h)}catch(e){return Promise.reject(e)}for(d=0,i=c.length;d<i;)r=r.then(c[d++],c[d++]);return r}getUri(e){return eb(eH((e=eK(this.defaults,e)).baseURL,e.url,e.allowAbsoluteUrls),e.params,e.paramsSerializer)}}
1Q.forEach(["delete","get","head","options"],function(e){ta.prototype[e]=function(t,r){return this.request(eK(r||{},{method:e,url:t,data:(r||{}).data}))}}),Q.forEach(["post","put","patch","query"],function(e){function t(t){return function(r,i,n){return this.request(eK(n||{},{method:e,headers:t?{"Content-Type":"multipart/form-data"}:{},url:r,data:i}))}}ta.prototype[e]=t(),"query"!==e&&(ta.prototype[e+"Form"]=t(!0))});class to{constructor(e){let t;if("function"!=typeof e)throw TypeError("executor must be a function.");this.promise=new Promise(function(e){t=e});const r=this;this.promise.then(e=>{if(!r._listeners)return;let t=r._listeners.length;for(;t-- >0;)r._listeners[t](e);r._listeners=null}),this.promise.then=e=>{let t,i=new Promise(e=>{r.subscribe(e),t=e}).then(e);return i.cancel=function(){r.unsubscribe(t)},i},e(function(e,i,n){r.reason||(r.reason=new eN(e,i,n),t(r.reason))})}throwIfRequested(){if(this.reason)throw this.reason}subscribe(e){this.reason?e(this.reason):this._listeners?this._listeners.push(e):this._listeners=[e]}unsubscribe(e){if(!this._listeners)return;let t=this._listeners.indexOf(e);-1!==t&&this._listeners.splice(t,1)}toAbortSignal(){let e=new AbortController,t=t=>{e.abort(t)};return this.subscribe(t),e.signal.unsubscribe=()=>this.unsubscribe(t),e.signal}static source(){let e;return{token:new to(function(t){e=t}),cancel:e}}}let tl={Continue:100,SwitchingProtocols:101,Processing:102,EarlyHints:103,Ok:200,Created:201,Accepted:202,NonAuthoritativeInformation:203,NoContent:204,ResetContent:205,Parti
1alContent:206,MultiStatus:207,AlreadyReported:208,ImUsed:226,MultipleChoices:300,MovedPermanently:301,Found:302,SeeOther:303,NotModified:304,UseProxy:305,Unused:306,TemporaryRedirect:307,PermanentRedirect:308,BadRequest:400,Unauthorized:401,PaymentRequired:402,Forbidden:403,NotFound:404,MethodNotAllowed:405,NotAcceptable:406,ProxyAuthenticationRequired:407,RequestTimeout:408,Conflict:409,Gone:410,LengthRequired:411,PreconditionFailed:412,PayloadTooLarge:413,UriTooLong:414,UnsupportedMediaType:415,RangeNotSatisfiable:416,ExpectationFailed:417,ImATeapot:418,MisdirectedRequest:421,UnprocessableEntity:422,Locked:423,FailedDependency:424,TooEarly:425,UpgradeRequired:426,PreconditionRequired:428,TooManyRequests:429,RequestHeaderFieldsTooLarge:431,UnavailableForLegalReasons:451,InternalServerError:500,NotImplemented:501,BadGateway:502,ServiceUnavailable:503,GatewayTimeout:504,HttpVersionNotSupported:505,VariantAlsoNegotiates:506,InsufficientStorage:507,LoopDetected:508,NotExtended:510,NetworkAuthenticationRequired:511,WebServerIsDown:521,ConnectionTimedOut:522,OriginIsUnreachable:523,TimeoutOccurred:524,SslHandshakeFailed:525,InvalidSslCertificate:526};Object.entries(tl).forEach(([e,t])=>{tl[t]=e});let tu=function e(t){let r=new ta(t),i=c(ta.prototype.request,r);return Q.extend(i,ta.prototype,r,{allOwnKeys:!0}),Q.extend(i,r,null,{allOwnKeys:!0}),i.create=function(r){return e(eK(t,r))},i}(eO);tu.Axios=ta,tu.CanceledError=eN,tu.CancelToken=to,tu.isCancel=eF,tu.VERSION=e1,tu.toFormData=ep,tu.AxiosError=eu,tu.Cancel=tu.CanceledError,tu.all=function(e){return Promise.all(e)},tu.spread=function(e){return function(t){return e.apply(null,t)}},tu.isAxiosError=function(e){return Q.isObject(e)&&!0===e.isAxiosError},tu.mergeConfig=eK,tu.AxiosHeaders=eo,tu.formToJSON=e=>eD(Q.isHTMLForm(e)?new FormData(e):e),tu.getAdapter=te,tu.HttpStatusCode=tl,tu.default=tu,e.s(["default",0,tu],581949)},927271,(e,t,r)=>{(function(){r.defaults={"0.1":{explicitCharkey:!1,trim:!0,normalize:!0,normalizeTags:!1,attrkey:"@",charkey:"#",explicitArray:!1,ignoreAttrs:!1,mergeAttrs:!1,explicitRoot:!1,validator:null,xmlns:!1,explicitChildren:!1,childkey:"@@",charsAsChildren:!1,includeWhiteChars:!1,async:!1,strict:!0,attrNameProcessors:null,attrValueProcessors:null,tagNameProcessors:null,valueProcessors:null,emptyTag:""},"0.2":{explicitCharkey:!1,trim:!1,normalize:!1,normalizeTags:!1,attrkey:"$",charkey:"_",explicitArray:!0,ignoreAttrs:!1,mergeAttrs:!1,explicitRoot:!0,validator:null,xmlns:!1,explicitChildren:!1,preserveChildrenOrder:!1,childkey:"$$",charsAsChildren:!1,includeWhiteChars:!1,async:!1,strict:!0,attrNameProcessors:null,attrValueProcessors:null,tagNameProcessors:null,valueProcessors:null,rootName:"root",xmldec:{version:"1.0",encoding:"UTF-8",standalone:!0},doctype:null,renderOpts:{pretty:!0,indent:" ",newline:"\n"},headless:!1,chunkSize:1e4,emptyTag:"",cdata:!1}}}).call(e.e)},12834,(e,t,r)=>{(function(){var e,r,i,n=[].slice,s={}.hasOwnProperty;r=function(e){return!!e&&"[object Function]"===Object.prototype.toString.call(e)},i=function(e){var t;return!!e&&("function"==(t=typeof e)||"object"===t)},e=function(e){return r(Array.isArray)?Array.isArray(e):"[object Array]"===Object.prototype.toString.call(e)},t.exports.assign=function(){var e,t,i,a,o,l;if(l=arguments[0],o=2<=arguments.length?n.call(arguments,1):[],r(Object.assign))Object.assign.apply(null,arguments);else for(e=0,i=o.length;e<i;e++)if(null!=(a=o[e]))for(t in a)s.call(a,t)&&(l[t]=a[t]);return l},t.exports.isFunction=r,t.exports.isObject=i,t.exports.isArray=e,t.exports.isEmpty=function(t){var r;if(e(t))return!t.length;for(r in t)if(s.call(t,r))return!1;return!0},t.exports.isPlainObject=function(e){var t,r;return i(e)&&(r=Object.getPrototypeOf(e))&&(t=r.constructor)&&"function"==typeof t&&t instanceof t&&Function.prototype.toString.call(t)===Function.prototype.toString.call(Object)},t.exports.getValue=function(e){return r(e.valueOf)?e.valueOf():e}}).call(e.e)},132109,(e,t,r)=>{(function(){t.exports=function(){function e(){}return e.prototype.hasFeature=function(e,t){return!0},e.prototype.createDocumentType=function(e,t,r){throw Error("This DOM method is not implemented.")},e.prototype.createDocument=function(e,t,r){throw Error("This DOM method is not implemented.")},e.prototype.createHTMLDocument=function(e){throw Error("This DOM method is not implemented.")},e.prototype.getFeature=function(e,t){throw Error("This DOM method is not implemented.")},e}()}).call(e.e)},788531,(e,t,r)=>{(function(){t.exports=function(){function e(){}return e.prototype.handleError=function(e){throw Error(e)},e}()}).call(e.e)},524912,(e,t,r)=>{(function(){t.exports=function(){function e(e){this.arr=e||[]}return Object.defineProperty(e.prototype,"length",{get:function(){return this.arr.length}}),e.prototype.item=function(e){return this.arr[e]||null},e.prototype.contains=function(e){return -1!==this.arr.indexOf(e)},e}()}).call(e.e)},760712,(e,t,r)=>{(function(){var r,i;
1r=e.r(788531),i=e.r(524912),t.exports=function(){function e(){this.defaultParams={"canonical-form":!1,"cdata-sections":!1,comments:!1,"datatype-normalization":!1,"element-content-whitespace":!0,entities:!0,"error-handler":new r,infoset:!0,"validate-if-schema":!1,namespaces:!0,"namespace-declarations":!0,"normalize-characters":!1,"schema-location":"","schema-type":"","split-cdata-sections":!0,validate:!1,"well-formed":!0},this.params=Object.create(this.defaultParams)}return Object.defineProperty(e.prototype,"parameterNames",{get:function(){return new i(Object.keys(this.defaultParams))}}),e.prototype.getParameter=function(e){return this.params.hasOwnProperty(e)?this.params[e]:null},e.prototype.canSetParameter=function(e,t){return!0},e.prototype.setParameter=function(e,t){return null!=t?this.params[e]=t:delete this.params[e]},e}()}).call(e.e)},146267,(e,t,r)=>{(function(){t.exports={Element:1,Attribute:2,Text:3,CData:4,EntityReference:5,EntityDeclaration:6,ProcessingInstruction:7,Comment:8,Document:9,DocType:10,DocumentFragment:11,NotationDeclaration:12,Declaration:201,Raw:202,AttributeDeclaration:203,ElementDeclaration:204,Dummy:205}}).call(e.e)},732799,(e,t,r)=>{(function(){var r;r=e.r(146267),e.r(331571),t.exports=function(){function e(e,t,i){if(this.parent=e,this.parent&&(this.options=this.parent.options,this.stringify=this.parent.stringify),null==t)throw Error("Missing attribute name. "+this.debugInfo(t));this.name=this.stringify.name(t),this.value=this.stringify.attValue(i),this.type=r.Attribute,this.isId=!1,this.schemaTypeInfo=null}return Object.defineProperty(e.prototype,"nodeType",{get:function(){return this.type}}),Object.defineProperty(e.prototype,"ownerElement",{get:function(){return this.parent}}),Object.defineProperty(e.prototype,"textContent",{get:function(){return this.value},set:function(e){return this.value=e||""}}),Object.defineProperty(e.prototype,"namespaceURI",{get:function(){return""}}),Object.defineProperty(e.prototype,"prefix",{get:function(){return""}}),Object.defineProperty(e.prototype,"localName",{get:function(){return this.name}}),Object.defineProperty(e.prototype,"specified",{get:function(){return!0}}),e.prototype.clone=function(){return Object.create(this)},e.prototype.toString=function(e){return this.options.writer.attribute(this,this.options.writer.filterOptions(e))},e.prototype.debugInfo=function(e){return null==(e=e||this.name)?"parent: <"+this.parent.name+">":"attribute: {"+e+"}, parent: <"+this.parent.name+">"},e.prototype.isEqualNode=function(e){return e.namespaceURI===this.namespaceURI&&e.prefix===this.prefix&&e.localName===this.localName&&e.value===this.value},e}()}).call(e.e)},59741,(e,t,r)=>{(function(){t.exports=function(){function e(e){this.nodes=e}return Object.defineProperty(e.prototype,"length",{get:function(){return Object.keys(this.nodes).length||0}}),e.prototype.clone=function(){return this.nodes=null},e.prototype.getNamedItem=function(e){return this.nodes[e]},e.prototype.setNamedItem=function(e){var t;return t=this.nodes[e.nodeName],this.nodes[e.nodeName]=e,t||null},e.prototype.removeNamedItem=function(e){var t;return t=this.nodes[e],delete this.nodes[e],t||null},e.prototype.item=function(e){return this.nodes[Object.keys(this.nodes)[e]]||null},e.prototype.getNamedItemNS=function(e,t){throw Error("This DOM method is not implemented.")},e.prototype.setNamedItemNS=function(e){throw Error("This DOM method is not implemented.")},e.prototype.removeNamedItemNS=function(e,t){throw Error("This DOM method is not implemented.")},e}()}).call(e.e)},367935,(e,t,r)=>{(function(){var r,i,n,s,a,o,l,u,c=function(e,t){for(var r in t)d.call(t,r)&&(e[r]=t[r]);function i(){this.constructor=e}return i.prototype=t.prototype,e.prototype=new i,e.__super__=t.prototype,e},d={}.hasOwnProperty;l=(u=e.r(12834)).isObject,o=u.isFunction,a=u.getValue,s=e.r(331571),r=e.r(146267),i=e.r(732799),n=e.r(59741),t.exports=function(e){function t(e,i,n){var s,a,o,l;if(t.__super__.constructor.call(this,e),null==i)throw Error("Missing element name. "+this.debugInfo());if(this.name=this.stringify.name(i),this.type=r.Element,this.attribs={},this.schemaTypeInfo=null,null!=n&&this.attribute(n),e.type===r.Document&&(this.isRoot=!0,this.documentObject=e,e.rootObject=this,e.children)){for(a=0,o=(l=e.children).length;a<o;a++)if((s=l[a]).type===r.DocType){s.name=this.name;break}}}return c(t,e),Object.defineProperty(t.prototype,"tagName",{get:function(){return this.name}}),Object.defineProperty(t.prototype,"namespaceURI",{get:function(){return""}}),Object.defineProperty(t.prototype,"prefix",{get:function(){return""}}),Object.defineProperty(t.prototype,"localName",{get:function(){return this.name}}),Object.defineProperty(t.prototype,"id",{get:function(){throw Error("This DOM method is not implemented."+this.debugInfo())}}),Object.defineProperty(t.prototype,"className",{get:function(){throw Error("This DOM method is not implemented."+this.debugInfo())}}),Object.defineProperty(t.prototype,"classList",{get:function(){throw Error("This DOM method is not implemented."+this.debugInfo())}}),Object.defineProperty(t.prototype,"attributes",{get:function(){return this.attributeMap&&this.attributeMap.nodes||(this.attributeMap=new n(this.attribs)),this.attributeMap}}),t.prototype.clone=function(){var e,t,r,i;for(t in(r=Object.create(this)).isRoot&&(r.documentObject=null),r.attribs={},i=this.attribs)d.call(i,t)&&(e=i[t],r.attribs[t]=e.clone());
1return r.children=[],this.children.forEach(function(e){var t;return(t=e.clone()).parent=r,r.children.push(t)}),r},t.prototype.attribute=function(e,t){var r,n;if(null!=e&&(e=a(e)),l(e))for(r in e)d.call(e,r)&&(n=e[r],this.attribute(r,n));else o(t)&&(t=t.apply()),this.options.keepNullAttributes&&null==t?this.attribs[e]=new i(this,e,""):null!=t&&(this.attribs[e]=new i(this,e,t));return this},t.prototype.removeAttribute=function(e){var t,r,i;if(null==e)throw Error("Missing attribute name. "+this.debugInfo());if(Array.isArray(e=a(e)))for(r=0,i=e.length;r<i;r++)t=e[r],delete this.attribs[t];else delete this.attribs[e];return this},t.prototype.toString=function(e){return this.options.writer.element(this,this.options.writer.filterOptions(e))},t.prototype.att=function(e,t){return this.attribute(e,t)},t.prototype.a=function(e,t){return this.attribute(e,t)},t.prototype.getAttribute=function(e){return this.attribs.hasOwnProperty(e)?this.attribs[e].value:null},t.prototype.setAttribute=function(e,t){throw Error("This DOM method is not implemented."+this.debugInfo())},t.prototype.getAttributeNode=function(e){return this.attribs.hasOwnProperty(e)?this.attribs[e]:null},t.prototype.setAttributeNode=function(e){throw Error("This DOM method is not implemented."+this.debugInfo())},t.prototype.removeAttributeNode=function(e){throw Error("This DOM method is not implemented."+this.debugInfo())},t.prototype.getElementsByTagName=function(e){throw Error("This DOM method is not implemented."+this.debugInfo())},t.prototype.getAttributeNS=function(e,t){throw Error("This DOM method is not implemented."+this.debugInfo())},t.prototype.setAttributeNS=function(e,t,r){throw Error("This DOM method is not implemented."+this.debugInfo())},t.prototype.removeAttributeNS=function(e,t){throw Error("This DOM method is not implemented."+this.debugInfo())},t.prototype.getAttributeNodeNS=function(e,t){throw Error("This DOM method is not implemented."+this.debugInfo())},t.prototype.setAttributeNodeNS=function(e){throw Error("This DOM method is not implemented."+this.debugInfo())},t.prototype.getElementsByTagNameNS=function(e,t){throw Error("This DOM method is not implemented."+this.debugInfo())},t.prototype.hasAttribute=function(e){return this.attribs.hasOwnProperty(e)},t.prototype.hasAttributeNS=function(e,t){throw Error("This DOM method is not implemented."+this.debugInfo())},t.prototype.setIdAttribute=function(e,t){return this.attribs.hasOwnProperty(e)?this.attribs[e].isId:t},t.prototype.setIdAttributeNS=function(e,t,r){throw Error("This DOM method is not implemented."+this.debugInfo())},t.prototype.setIdAttributeNode=function(e,t){throw Error("This DOM method is not implemented."+this.debugInfo())},t.prototype.getElementsByTagName=function(e){throw Error("This DOM method is not implemented."+this.debugInfo())},t.prototype.getElementsByTagNameNS=function(e,t){throw Error("This DOM method is not implemented."+this.debugInfo())},t.prototype.getElementsByClassName=function(e){throw Error("This DOM method is not implemented."+this.debugInfo())},t.prototype.isEqualNode=function(e){var r,i,n;if(!t.__super__.isEqualNode.apply(this,arguments).isEqualNode(e)||e.namespaceURI!==this.namespaceURI||e.prefix!==this.prefix||e.localName!==this.localName||e.attribs.length!==this.attribs.length)return!1;for(r=i=0,n=this.attribs.length-1;0<=n?i<=n:i>=n;r=0<=n?++i:--i)if(!this.attribs[r].isEqualNode(e.attribs[r]))return!1;return!0},t}(s)}).call(e.e)},842603,(e,t,r)=>{(function(){var r=function(e,t){for(var r in t)i.call(t,r)&&(e[r]=t[r]);function n(){this.constructor=e}return n.prototype=t.prototype,e.prototype=new n,e.__super__=t.prototype,e},i={}.hasOwnProperty;t.exports=function(e){function t(e){t.__super__.constructor.call(this,e),this.value=""}return r(t,e),Object.defineProperty(t.prototype,"data",{get:function(){return this.value},set:function(e){return this.value=e||""}}),Object.defineProperty(t.prototype,"length",{get:function(){return this.value.length}}),Object.defineProperty(t.prototype,"textContent",{get:function(){return this.value},set:function(e){return this.value=e||""}}),t.prototype.clone=function(){return Object.create(this)},t.prototype.substringData=function(e,t){throw Error("This DOM method is not implemented."+this.debugInfo())},t.prototype.appendData=function(e){throw Error("This DOM method is not implemented."+this.debugInfo())},t.prototype.insertData=function(e,t){throw Error("This DOM method is not implemented."+this.debugInfo())},t.prototype.deleteData=function(e,t){throw Error("This DOM method is not implemented."+this.debugInfo())},t.prototype.replaceData=function(e,t,r){throw Error("This DOM method is not implemented."+this.debugInfo())},t.prototype.isEqualNode=function(e){return!!t.__super__.isEqualNode.apply(this,arguments).isEqualNode(e)&&e.data===this.data},t}(e.r(331571))}).call(e.e)},33299,(e,t,r)=>{(function(){var r,i=function(e,t){for(var r in t)n.call(t,r)&&(e[r]=t[r]);function i(){this.constructor=e}return i.prototype=t.prototype,e.prototype=new i,e.__super__=t.prototype,e},n={}.hasOwnProperty;r=e.r(146267),t.exports=function(e){function t(e,i){if(t.__super__.constructor.call(this,e),null==i)throw Error("Missing CDATA text. "+this.debugInfo());this.name="#cdata-section",this.type=r.CData,this.value=this.stringify.cdata(i)}return i(t,e),t.prototype.clone=function(){return Object.create(this)}
1,t.prototype.toString=function(e){return this.options.writer.cdata(this,this.options.writer.filterOptions(e))},t}(e.r(842603))}).call(e.e)},7151,(e,t,r)=>{(function(){var r,i=function(e,t){for(var r in t)n.call(t,r)&&(e[r]=t[r]);function i(){this.constructor=e}return i.prototype=t.prototype,e.prototype=new i,e.__super__=t.prototype,e},n={}.hasOwnProperty;r=e.r(146267),t.exports=function(e){function t(e,i){if(t.__super__.constructor.call(this,e),null==i)throw Error("Missing comment text. "+this.debugInfo());this.name="#comment",this.type=r.Comment,this.value=this.stringify.comment(i)}return i(t,e),t.prototype.clone=function(){return Object.create(this)},t.prototype.toString=function(e){return this.options.writer.comment(this,this.options.writer.filterOptions(e))},t}(e.r(842603))}).call(e.e)},176337,(e,t,r)=>{(function(){var r,i,n,s=function(e,t){for(var r in t)a.call(t,r)&&(e[r]=t[r]);function i(){this.constructor=e}return i.prototype=t.prototype,e.prototype=new i,e.__super__=t.prototype,e},a={}.hasOwnProperty;n=e.r(12834).isObject,i=e.r(331571),r=e.r(146267),t.exports=function(e){function t(e,i,s,a){var o;t.__super__.constructor.call(this,e),n(i)&&(i=(o=i).version,s=o.encoding,a=o.standalone),i||(i="1.0"),this.type=r.Declaration,this.version=this.stringify.xmlVersion(i),null!=s&&(this.encoding=this.stringify.xmlEncoding(s)),null!=a&&(this.standalone=this.stringify.xmlStandalone(a))}return s(t,e),t.prototype.toString=function(e){return this.options.writer.declaration(this,this.options.writer.filterOptions(e))},t}(i)}).call(e.e)},190021,(e,t,r)=>{(function(){var r,i,n=function(e,t){for(var r in t)s.call(t,r)&&(e[r]=t[r]);function i(){this.constructor=e}return i.prototype=t.prototype,e.prototype=new i,e.__super__=t.prototype,e},s={}.hasOwnProperty;i=e.r(331571),r=e.r(146267),t.exports=function(e){function t(e,i,n,s,a,o){if(t.__super__.constructor.call(this,e),null==i)throw Error("Missing DTD element name. "+this.debugInfo());if(null==n)throw Error("Missing DTD attribute name. "+this.debugInfo(i));if(!s)throw Error("Missing DTD attribute type. "+this.debugInfo(i));if(!a)throw Error("Missing DTD attribute default. "+this.debugInfo(i));if(0!==a.indexOf("#")&&(a="#"+a),!a.match(/^(#REQUIRED|#IMPLIED|#FIXED|#DEFAULT)$/))throw Error("Invalid default value type; expected: #REQUIRED, #IMPLIED, #FIXED or #DEFAULT. "+this.debugInfo(i));if(o&&!a.match(/^(#FIXED|#DEFAULT)$/))throw Error("Default value only applies to #FIXED or #DEFAULT. "+this.debugInfo(i));this.elementName=this.stringify.name(i),this.type=r.AttributeDeclaration,this.attributeName=this.stringify.name(n),this.attributeType=this.stringify.dtdAttType(s),o&&(this.defaultValue=this.stringify.dtdAttDefault(o)),this.defaultValueType=a}return n(t,e),t.prototype.toString=function(e){return this.options.writer.dtdAttList(this,this.options.writer.filterOptions(e))},t}(i)}).call(e.e)},51651,(e,t,r)=>{(function(){var r,i,n,s=function(e,t){for(var r in t)a.call(t,r)&&(e[r]=t[r]);function i(){this.constructor=e}return i.prototype=t.prototype,e.prototype=new i,e.__super__=t.prototype,e},a={}.hasOwnProperty;n=e.r(12834).isObject,i=e.r(331571),r=e.r(146267),t.exports=function(e){function t(e,i,s,a){if(t.__super__.constructor.call(this,e),null==s)throw Error("Missing DTD entity name. "+this.debugInfo(s));if(null==a)throw Error("Missing DTD entity value. "+this.debugInfo(s));if(this.pe=!!i,this.name=this.stringify.name(s),this.type=r.EntityDeclaration,n(a)){if(!a.pubID&&!a.sysID)throw Error("Public and/or system identifiers are required for an external entity. "+this.debugInfo(s));if(a.pubID&&!a.sysID)throw Error("System identifier is required for a public external entity. "+this.debugInfo(s));if(this.internal=!1,null!=a.pubID&&(this.pubID=this.stringify.dtdPubID(a.pubID)),null!=a.sysID&&(this.sysID=this.stringify.dtdSysID(a.sysID)),null!=a.nData&&(this.nData=this.stringify.dtdNData(a.nData)),this.pe&&this.nData)throw Error("Notation declaration is not allowed in a parameter entity. "+this.debugInfo(s))}else this.value=this.stringify.dtdEntityValue(a),this.internal=!0}return s(t,e),Object.defineProperty(t.prototype,"publicId",{get:function(){return this.pubID}}),Object.defineProperty(t.prototype,"systemId",{get:function(){return this.sysID}}),Object.defineProperty(t.prototype,"notationName",{get:function(){return this.nData||null}}),Object.defineProperty(t.prototype,"inputEncoding",{get:function(){return null}}),Object.defineProperty(t.prototype,"xmlEncoding",{get:function(){return null}}),Object.defineProperty(t.prototype,"xmlVersion",{get:function(){return null}}),t.prototype.toString=function(e){return this.options.writer.dtdEntity(this,this.options.writer.filterOptions(e))},t}(i)}).call(e.e)},867079,(e,t,r)=>{(function(){var r,i,n=function(e,t){for(var r in t)s.call(t,r)&&(e[r]=t[r]);function i(){this.constructor=e}return i.prototype=t.prototype,e.prototype=new i,e.__super__=t.prototype,e},s={}.hasOwnProperty;i=e.r(331571),r=e.r(146267),t.exports=function(e){function t(e,i,n){if(t.__super__.constructor.call(this,e),null==i)throw Error("Missing DTD element name. "+this.debugInfo());n||(n="(#PCDATA)"),Array.isArray(n)&&(n="("+n.join(",")+")"),this.name=this.stringify.name(i),this.type=r.ElementDeclaration,this.value=this.stringify.dtdElementValue(n)}return n(t,e),t.prototype.toString=function(e){return this.options.writer.dtdElement(this,this.options.writer.filterOptions(e))},t}(i)}).call(e.e)},515548,(e,t,r)=>{(function(){var r,i,n=function(e,t){for(var r in t)s.call(t,r)&&(e[r]=t[r]);function i(){this.constructor=e}return i.prototype=t.prototype,e.prototype=new i,e.__super__=t.prototype,e},s={}.hasOwnProperty;i=e.r(331571),r=e.r(146267),t.exports=function(e){function t(e,i,n){if(t.__super__.constructor.call(this,e),null==i)throw Error("Missing DTD notation name. "+this.debugInfo(i));if(!n.pubID&&!n.sysID)throw Error("Public or system identifiers are required for an external entity. "+this.debugInfo(i));this.name=this.stringify.name(i),this.type=r.NotationDeclaration,null!=n.pubID&&(this.pubID=this.stringify.dtdPubID(n.pubID)),null!=n.sysID&&(this.sysID=this.stringify.dtdSysID(n.sysID))}return n(t,e),Object.defineProperty(t.prototype,"publicId",{get:function(){return this.pubID}}),Object.defineProperty(t.prototype,"systemId",{get:function(){return this.sysID}}),t.prototype.toString=function(e){return this.options.writer.dtdNotation(this,this.options.writer.filterOptions(e))},t}(i)}).call(e.e)},294877,(e,t,r)=>{(function(){var r,i,n,s,a,o,l,u,c=function(e,t){for(var r in t)d.call(t,r)&&(e[r]=t[r]);function i(){this.constructor=e}return i.prototype=t.prototype,e.prototype=new i,e.__super__=t.prototype,e},d={}.hasOwnProperty;u=e.r(12834).isObject,l=e.r(331571),r=e.r(146267),i=e.r(190021),s=e.r(51651),n=e.r(867079),a=e.r(515548),o=e.r(59741),t.exports=function(e){function t(e,i,n){var s,a,o,l,c,d;if(t.__super__.constructor.call(this,e),this.type=r.DocType,e.children){for(a=0,o=(l=e.children).length;a<o;a++)if((s=l[a]).type===r.Element){this.name=s.name;break}}this.documentObject=e,u(i)&&(i=(c=i).pubID,n=c.sysID),null==n&&(n=(d=[i,n])[0],i=d[1]),null!=i&&(this.pubID=this.stringify.dtdPubID(i)),null!=n&&(this.sysID=this.stringify.dtdSysID(n))}return c(t,e),Object.defineProperty(t.prototype,"entities",{get:function(){var e,t,i,n,s;for(t=0,n={},i=(s=this.children).length;t<i;t++)(e=s[t]).type!==r.EntityDeclaration||e.pe||(n[e.name]=e);return new o(n)}}),Object.defineProperty(t.prototype,"notations",{get:function(){var e,t,i,n,s;for(t=0,n={},i=(s=this.children).length;t<i;t++)(e=s[t]).type===r.NotationDeclaration&&(n[e.name]=e);return new o(n)}}),Object.defineProperty(t.prototype,"publicId",{get:function(){return this.pubID}}),Object.defineProperty(t.prototype,"systemId",{get:function(){return this.sysID}}),Object.defineProperty(t.prototype,"internalSubset",{get:function(){throw Error("This DOM method is not implemented."+this.debugInfo())}}),t.prototype.element=function(e,t){var r;return r=new n(this,e,t),this.children.push(r),this},t.prototype.attList=function(e,t,r,n,s){var a;return a=new i(this,e,t,r,n,s),this.children.push(a),this},t.prototype.entity=function(e,t){var r;return r=new s(this,!1,e,t),this.children.push(r),this},t.prototype.pEntity=function(e,t){var r;return r=new s(this,!0,e,t),this.children.push(r),this},t.prototype.notation=function(e,t){var r;return r=new a(this,e,t),this.children.push(r),this},t.prototype.toString=function(e){return this.options.writer.docType(this,this.options.writer.filterOptions(e))}
1,t.prototype.ele=function(e,t){return this.element(e,t)},t.prototype.att=function(e,t,r,i,n){return this.attList(e,t,r,i,n)},t.prototype.ent=function(e,t){return this.entity(e,t)},t.prototype.pent=function(e,t){return this.pEntity(e,t)},t.prototype.not=function(e,t){return this.notation(e,t)},t.prototype.up=function(){return this.root()||this.documentObject},t.prototype.isEqualNode=function(e){return!!t.__super__.isEqualNode.apply(this,arguments).isEqualNode(e)&&e.name===this.name&&e.publicId===this.publicId&&e.systemId===this.systemId},t}(l)}).call(e.e)},547950,(e,t,r)=>{(function(){var r,i=function(e,t){for(var r in t)n.call(t,r)&&(e[r]=t[r]);function i(){this.constructor=e}return i.prototype=t.prototype,e.prototype=new i,e.__super__=t.prototype,e},n={}.hasOwnProperty;r=e.r(146267),t.exports=function(e){function t(e,i){if(t.__super__.constructor.call(this,e),null==i)throw Error("Missing raw text. "+this.debugInfo());this.type=r.Raw,this.value=this.stringify.raw(i)}return i(t,e),t.prototype.clone=function(){return Object.create(this)},t.prototype.toString=function(e){return this.options.writer.raw(this,this.options.writer.filterOptions(e))},t}(e.r(331571))}).call(e.e)},283730,(e,t,r)=>{(function(){var r,i=function(e,t){for(var r in t)n.call(t,r)&&(e[r]=t[r]);function i(){this.constructor=e}return i.prototype=t.prototype,e.prototype=new i,e.__super__=t.prototype,e},n={}.hasOwnProperty;r=e.r(146267),t.exports=function(e){function t(e,i){if(t.__super__.constructor.call(this,e),null==i)throw Error("Missing element text. "+this.debugInfo());this.name="#text",this.type=r.Text,this.value=this.stringify.text(i)}return i(t,e),Object.defineProperty(t.prototype,"isElementContentWhitespace",{get:function(){throw Error("This DOM method is not implemented."+this.debugInfo())}}),Object.defineProperty(t.prototype,"wholeText",{get:function(){var e,t,r;for(r="",t=this.previousSibling;t;)r=t.data+r,t=t.previousSibling;for(r+=this.data,e=this.nextSibling;e;)r+=e.data,e=e.nextSibling;return r}}),t.prototype.clone=function(){return Object.create(this)},t.prototype.toString=function(e){return this.options.writer.text(this,this.options.writer.filterOptions(e))},t.prototype.splitText=function(e){throw Error("This DOM method is not implemented."+this.debugInfo())},t.prototype.replaceWholeText=function(e){throw Error("This DOM method is not implemented."+this.debugInfo())},t}(e.r(842603))}).call(e.e)},777721,(e,t,r)=>{(function(){var r,i=function(e,t){for(var r in t)n.call(t,r)&&(e[r]=t[r]);function i(){this.constructor=e}return i.prototype=t.prototype,e.prototype=new i,e.__super__=t.prototype,e},n={}.hasOwnProperty;r=e.r(146267),t.exports=function(e){function t(e,i,n){if(t.__super__.constructor.call(this,e),null==i)throw Error("Missing instruction target. "+this.debugInfo());this.type=r.ProcessingInstruction,this.target=this.stringify.insTarget(i),this.name=this.target,n&&(this.value=this.stringify.insValue(n))}return i(t,e),t.prototype.clone=function(){return Object.create(this)},t.prototype.toString=function(e){return this.options.writer.processingInstruction(this,this.options.writer.filterOptions(e))},t.prototype.isEqualNode=function(e){return!!t.__super__.isEqualNode.apply(this,arguments).isEqualNode(e)&&e.target===this.target},t}(e.r(842603))}).call(e.e)},175548,(e,t,r)=>{(function(){var r,i,n=function(e,t){for(var r in t)s.call(t,r)&&(e[r]=t[r]);function i(){this.constructor=e}return i.prototype=t.prototype,e.prototype=new i,e.__super__=t.prototype,e},s={}.hasOwnProperty;i=e.r(331571),r=e.r(146267),t.exports=function(e){function t(e){t.__super__.constructor.call(this,e),this.type=r.Dummy}return n(t,e),t.prototype.clone=function(){return Object.create(this)},t.prototype.toString=function(e){return""},t}(i)}).call(e.e)},609799,(e,t,r)=>{(function(){t.exports=function(){function e(e){this.nodes=e}return Object.defineProperty(e.prototype,"length",{get:function(){return this.nodes.length||0}}),e.prototype.clone=function(){return this.nodes=null},e.prototype.item=function(e){return this.nodes[e]||null},e}()}).call(e.e)},546427,(e,t,r)=>{(function(){t.exports={Disconnected:1,Preceding:2,Following:4,Contains:8,ContainedBy:16,ImplementationSpecific:32}}).call(e.e)},331571,(e,t,r)=>{(function(){var r,i,n,s,a,o,l,u,c,d,h,f,p,g,m,y,v,b={}.hasOwnProperty;y=(v=e.r(12834)).isObject,m=v.isFunction,g=v.isEmpty,p=v.getValue,u=null,n=null,
1s=null,a=null,o=null,h=null,f=null,d=null,l=null,i=null,c=null,r=null,t.exports=function(){function t(t){this.parent=t,this.parent&&(this.options=this.parent.options,this.stringify=this.parent.stringify),this.value=null,this.children=[],this.baseURI=null,u||(u=e.r(367935),n=e.r(33299),s=e.r(7151),a=e.r(176337),o=e.r(294877),h=e.r(547950),f=e.r(283730),d=e.r(777721),l=e.r(175548),i=e.r(146267),c=e.r(609799),e.r(59741),r=e.r(546427))}return Object.defineProperty(t.prototype,"nodeName",{get:function(){return this.name}}),Object.defineProperty(t.prototype,"nodeType",{get:function(){return this.type}}),Object.defineProperty(t.prototype,"nodeValue",{get:function(){return this.value}}),Object.defineProperty(t.prototype,"parentNode",{get:function(){return this.parent}}),Object.defineProperty(t.prototype,"childNodes",{get:function(){return this.childNodeList&&this.childNodeList.nodes||(this.childNodeList=new c(this.children)),this.childNodeList}}),Object.defineProperty(t.prototype,"firstChild",{get:function(){return this.children[0]||null}}),Object.defineProperty(t.prototype,"lastChild",{get:function(){return this.children[this.children.length-1]||null}}),Object.defineProperty(t.prototype,"previousSibling",{get:function(){var e;return e=this.parent.children.indexOf(this),this.parent.children[e-1]||null}}),Object.defineProperty(t.prototype,"nextSibling",{get:function(){var e;return e=this.parent.children.indexOf(this),this.parent.children[e+1]||null}}),Object.defineProperty(t.prototype,"ownerDocument",{get:function(){return this.document()||null}}),Object.defineProperty(t.prototype,"textContent",{get:function(){var e,t,r,n,s;if(this.nodeType!==i.Element&&this.nodeType!==i.DocumentFragment)return null;for(t=0,s="",r=(n=this.children).length;t<r;t++)(e=n[t]).textContent&&(s+=e.textContent);return s},set:function(e){throw Error("This DOM method is not implemented."+this.debugInfo())}}),t.prototype.setParent=function(e){var t,r,i,n,s;for(this.parent=e,e&&(this.options=e.options,this.stringify=e.stringify),n=this.children,s=[],r=0,i=n.length;r<i;r++)t=n[r],s.push(t.setParent(this));return s},t.prototype.element=function(e,t,r){var i,n,s,a,o,l,u,c,d,h,f;if(l=null,null===t&&null==r&&(t=(d=[{},null])[0],r=d[1]),null==t&&(t={}),y(t=p(t))||(r=(h=[t,r])[0],t=h[1]),null!=e&&(e=p(e)),Array.isArray(e))for(s=0,u=e.length;s<u;s++)n=e[s],l=this.element(n);else if(m(e))l=this.element(e.apply());else if(y(e)){for(o in e)if(b.call(e,o))if(m(f=e[o])&&(f=f.apply()),!this.options.ignoreDecorators&&this.stringify.convertAttKey&&0===o.indexOf(this.stringify.convertAttKey))l=this.attribute(o.substr(this.stringify.convertAttKey.length),f);else if(!this.options.separateArrayItems&&Array.isArray(f)&&g(f))l=this.dummy();else if(y(f)&&g(f))l=this.element(o);else if(this.options.keepNullNodes||null!=f)if(!this.options.separateArrayItems&&Array.isArray(f))for(a=0,c=f.length;a<c;a++)n=f[a],(i={})[o]=n,l=this.element(i);else y(f)?!this.options.ignoreDecorators&&this.stringify.convertTextKey&&0===o.indexOf(this.stringify.convertTextKey)?l=this.element(f):(l=this.element(o)).element(f):l=this.element(o,f);else l=this.dummy()}else l=this.options.keepNullNodes||null!==r?!this.options.ignoreDecorators&&this.stringify.convertTextKey&&0===e.indexOf(this.stringify.convertTextKey)?this.text(r):!this.options.ignoreDecorators&&this.stringify.convertCDataKey&&0===e.indexOf(this.stringify.convertCDataKey)?this.cdata(r):!this.options.ignoreDecorators&&this.stringify.convertCommentKey&&0===e.indexOf(this.stringify.convertCommentKey)?this.comment(r):!this.options.ignoreDecorators&&this.stringify.convertRawKey&&0===e.indexOf(this.stringify.convertRawKey)?this.raw(r):!this.options.ignoreDecorators&&this.stringify.convertPIKey&&0===e.indexOf(this.stringify.convertPIKey)?this.instruction(e.substr(this.stringify.convertPIKey.length),r):this.node(e,t,r):this.dummy();if(null==l)throw Error("Could not create any elements with: "+e+". "+this.debugInfo());return l},t.prototype.insertBefore=function(e,t,r){var i,n,s;if(null!=e?e.type:void 0)return e.setParent(this),t?(n=children.indexOf(t),s=children.splice(n),children.push(e),Array.prototype.push.apply(children,s)):children.push(e),e;if(this.isRoot)throw Error("Cannot insert elements at root level. "+this.debugInfo(e));return n=this.parent.children.indexOf(this),s=this.parent.children.splice(n),i=this.parent.element(e,t,r),Array.prototype.push.apply(this.parent.children,s),i},t.prototype.insertAfter=function(e,t,r){var i,n,s;if(this.isRoot)throw Error("Cannot insert elements at root level. "+this.debugInfo(e));return n=this.parent.children.indexOf(this),s=this.parent.children.splice(n+1),i=this.parent.element(e,t,r),Array.prototype.push.apply(this.parent.children,s),i},t.prototype.remove=function(){var e;if(this.isRoot)throw Error("Cannot remove the root element. "+this.debugInfo());return e=this.parent.children.indexOf(this),[].splice.apply(this.parent.children,[e,e-e+1].concat([])),this.parent},t.prototype.node=function(e,t,r){var i,n;return null!=e&&(e=p(e)),t||(t={}),y(t=p(t))||(r=(n=[t,r])[0],t=n[1]),i=new u(this,e,t),null!=r&&i.text(r),this.children.push(i),i},t.prototype.text=function(e){var t;
1return y(e)&&this.element(e),t=new f(this,e),this.children.push(t),this},t.prototype.cdata=function(e){var t;return t=new n(this,e),this.children.push(t),this},t.prototype.comment=function(e){var t;return t=new s(this,e),this.children.push(t),this},t.prototype.commentBefore=function(e){var t,r;return t=this.parent.children.indexOf(this),r=this.parent.children.splice(t),this.parent.comment(e),Array.prototype.push.apply(this.parent.children,r),this},t.prototype.commentAfter=function(e){var t,r;return t=this.parent.children.indexOf(this),r=this.parent.children.splice(t+1),this.parent.comment(e),Array.prototype.push.apply(this.parent.children,r),this},t.prototype.raw=function(e){var t;return t=new h(this,e),this.children.push(t),this},t.prototype.dummy=function(){return new l(this)},t.prototype.instruction=function(e,t){var r,i,n,s,a;if(null!=e&&(e=p(e)),null!=t&&(t=p(t)),Array.isArray(e))for(s=0,a=e.length;s<a;s++)r=e[s],this.instruction(r);else if(y(e))for(r in e)b.call(e,r)&&(i=e[r],this.instruction(r,i));else m(t)&&(t=t.apply()),n=new d(this,e,t),this.children.push(n);return this},t.prototype.instructionBefore=function(e,t){var r,i;return r=this.parent.children.indexOf(this),i=this.parent.children.splice(r),this.parent.instruction(e,t),Array.prototype.push.apply(this.parent.children,i),this},t.prototype.instructionAfter=function(e,t){var r,i;return r=this.parent.children.indexOf(this),i=this.parent.children.splice(r+1),this.parent.instruction(e,t),Array.prototype.push.apply(this.parent.children,i),this},t.prototype.declaration=function(e,t,r){var n,s;return n=this.document(),s=new a(n,e,t,r),0===n.children.length?n.children.unshift(s):n.children[0].type===i.Declaration?n.children[0]=s:n.children.unshift(s),n.root()||n},t.prototype.dtd=function(e,t){var r,n,s,a,l,u,c,d,h;for(r=this.document(),n=new o(r,e,t),d=r.children,s=a=0,u=d.length;a<u;s=++a)if(d[s].type===i.DocType)return r.children[s]=n,n;for(h=r.children,s=l=0,c=h.length;l<c;s=++l)if(h[s].isRoot)return r.children.splice(s,0,n),n;return r.children.push(n),n},t.prototype.up=function(){if(this.isRoot)throw Error("The root node has no parent. Use doc() if you need to get the document object.");return this.parent},t.prototype.root=function(){var e;for(e=this;e;)if(e.type===i.Document)return e.rootObject;else{if(e.isRoot)return e;e=e.parent}},t.prototype.document=function(){var e;for(e=this;e;)if(e.type===i.Document)return e;else e=e.parent},t.prototype.end=function(e){return this.document().end(e)},t.prototype.prev=function(){var e;if((e=this.parent.children.indexOf(this))<1)throw Error("Already at the first node. "+this.debugInfo());return this.parent.children[e-1]},t.prototype.next=function(){var e;if(-1===(e=this.parent.children.indexOf(this))||e===this.parent.children.length-1)throw Error("Already at the last node. "+this.debugInfo());return this.parent.children[e+1]},t.prototype.importDocument=function(e){var t;return(t=e.root().clone()).parent=this,t.isRoot=!1,this.children.push(t),this},t.prototype.debugInfo=function(e){var t,r;return null!=(e=e||this.name)||(null!=(t=this.parent)?t.name:void 0)?null==e?"parent: <"+this.parent.name+">":(null!=(r=this.parent)?r.name:void 0)?"node: <"+e+">, parent: <"+this.parent.name+">":"node: <"+e+">":""},t.prototype.ele=function(e,t,r){return this.element(e,t,r)},t.prototype.nod=function(e,t,r){return this.node(e,t,r)},t.prototype.txt=function(e){return this.text(e)},t.prototype.dat=function(e){return this.cdata(e)},t.prototype.com=function(e){return this.comment(e)},t.prototype.ins=function(e,t){return this.instruction(e,t)},t.prototype.doc=function(){return this.document()},t.prototype.dec=function(e,t,r){return this.declaration(e,t,r)},t.prototype.e=function(e,t,r){return this.element(e,t,r)},t.prototype.n=function(e,t,r){return this.node(e,t,r)},t.prototype.t=function(e){return this.text(e)},t.prototype.d=function(e){return this.cdata(e)},t.prototype.c=function(e){return this.comment(e)},t.prototype.r=function(e){return this.raw(e)},t.prototype.i=function(e,t){return this.instruction(e,t)},t.prototype.u=function(){return this.up()},t.prototype.importXMLBuilder=function(e){return this.importDocument(e)},t.prototype.replaceChild=function(e,t){throw Error("This DOM method is not implemented."+this.debugInfo())},t.prototype.removeChild=function(e){throw Error("This DOM method is not implemented."+this.debugInfo())},t.prototype.appendChild=function(e){throw Error("This DOM method is not implemented."+this.debugInfo())},t.prototype.hasChildNodes=function(){return 0!==this.children.length},t.prototype.cloneNode=function(e){throw Error("This DOM method is not implemented."+this.debugInfo())},t.prototype.normalize=function(){throw Error("This DOM method is not implemented."+this.debugInfo())},t.prototype.isSupported=function(e,t){return!0},t.prototype.hasAttributes=function(){return 0!==this.attribs.length},t.prototype.compareDocumentPosition=function(e){var t;if(this===e)return 0;if(this.document()!==e.document())return t=r.Disconnected|r.ImplementationSpecific,.5>Math.random()?t|=r.Preceding:t|=r.Following,t;if(this.isAncestor(e))return r.Contains|r.Preceding;if(this.isDescendant(e))return r.Contains|r.Following;if(this.isPreceding(e))return r.Preceding;else return r.Following},t.prototype.isSameNode=function(e){throw Error("This DOM method is not implemented."+this.debugInfo())},t.prototype.lookupPrefix=function(e){throw Error("This DOM method is not implemented."+this.debugInfo())},t.prototype.isDefaultNamespace=function(e){throw Error("This DOM method is not implemented."+this.debugInfo())},t.prototype.lookupNamespaceURI=function(e){throw Error("This DOM method is not implemented."+this.debugInfo())},t.prototype.isEqualNode=function(e){var t,r,i;if(e.nodeType!==this.nodeType||e.children.length!==this.children.length)return!1;for(t=r=0,i=this.children.length-1;0<=i?r<=i:r>=i;t=0<=i?++r:--r)if(!this.children[t].isEqualNode(e.children[t]))return!1;return!0},t.prototype.getFeature=function(e,t){throw Error("This DOM method is not implemented."+this.debugInfo())},t.prototype.setUserData=function(e,t,r){throw Error("This DOM method is not implemented."+this.debugInfo())},t.prototype.getUserData=function(e){throw Error("This DOM method is not implemented."+this.debugInfo())},t.prototype.contains=function(e){return!!e&&(e===this||this.isDescendant(e))},t.prototype.isDescendant=function(e){var t,r,i,n;for(r=0,i=(n=this.children).length;r<i;r++)if(e===(t=n[r])||t.isDescendant(e))return!0;return!1},t.prototype.isAncestor=function(e){return e.isDescendant(this)},t.prototype.isPreceding=function(e){var t,r;return t=this.treePosition(e),r=this.treePosition(this),-1!==t&&-1!==r&&t<r},t.prototype.isFollowing=function(e){var t,r;return t=this.treePosition(e),r=this.treePosition(this),-1!==t&&-1!==r&&t>r},t.prototype.treePosition=function(e){var t,r;return(r=0,t=!1,this.foreachTreeNode(this.document(),function(i){if(r++,!t&&i===e)return t=!0}),t)?r:-1},t.prototype.foreachTreeNode=function(e,t){var r,i,n,s,a;for(e||(e=this.document()),i=0,n=(s=e.children).length;i<n;i++)if((a=t(r=s[i]))||(a=this.foreachTreeNode(r,t)))return a},t}()}).call(e.e)},593964,(e,t,r)=>{(function(){var e=function(e,t){return function(){return e.apply(t,arguments)}},r={}.hasOwnProperty;t.exports=function(){function t(t){var i,n,s;for(i in this.assertLegalName=e(this.assertLegalName,this),this.assertLegalChar=e(this.assertLegalChar,this),t||(t={}),this.options=t,this.options.version||(this.options.version="1.0"),n=t.stringify||{})r.call(n,i)&&(s=n[i],this[i]=s)}return t.prototype.name=function(e){return this.options.noValidation?e:this.assertLegalName(""+e||"")},t.prototype.text=function(e){return this.options.noValidation?e:this.assertLegalChar(this.textEscape(""+e||""))},t.prototype.cdata=function(e){return this.options.noValidation?e:(e=(e=""+e||"").replace("]]>","]]]]><![CDATA[>"),this.assertLegalChar(e))},t.prototype.comment=function(e){if(this.options.noValidation)return e;if((e=""+e||"").match(/--/))throw Error("Comment text cannot contain double-hypen: "+e);return this.assertLegalChar(e)},t.prototype.raw=function(e){return this.options.noValidation?e:""+e||""},t.prototype.attValue=function(e){return this.options.noValidation?e:this.assertLegalChar(this.attEscape(e=""+e||""))},t.prototype.insTarget=function(e){return this.options.noValidation?e:this.assertLegalChar(""+e||"")},t.prototype.insValue=function(e){if(this.options.noValidation)return e;if((e=""+e||"").match(/\?>/))throw Error("Invalid processing instruction value: "+e);return this.assertLegalChar(e)},t.prototype.xmlVersion=function(e){if(this.options.noValidation)return e;if(!(e=""+e||"").match(/1\.[0-9]+/))throw Error("Invalid version number: "+e);return e},t.prototype.xmlEncoding=function(e){if(this.options.noValidation)return e;if(!(e=""+e||"").match(/^[A-Za-z](?:[A-Za-z0-9._-])*$/))throw Error("Invalid encoding: "+e);return this.assertLegalChar(e)},t.prototype.xmlStandalone=function(e){return this.options.noValidation?e:e?"yes":"no"},t.prototype.dtdPubID=function(e){return this.options.noValidation?e:this.assertLegalChar(""+e||"")},t.prototype.dtdSysID=function(e){return this.options.noValidation?e:this.assertLegalChar(""+e||"")},t.prototype.dtdElementValue=function(e){return this.options.noValidation?e:this.assertLegalChar(""+e||"")},t.prototype.dtdAttType=function(e){return this.options.noValidation?e:this.assertLegalChar(""+e||"")},t.prototype.dtdAttDefault=function(e){return this.options.noValidation?e:this.assertLegalChar(""+e||"")},t.prototype.dtdEntityValue=function(e){return this.options.noValidation?e:this.assertLegalChar(""+e||"")},t.prototype.dtdNData=function(e){return this.options.noValidation?e:this.assertLegalChar(""+e||"")},t.prototype.convertAttKey="@",t.prototype.convertPIKey="?",t.prototype.convertTextKey="#text",t.prototype.convertCDataKey="#cdata",t.prototype.convertCommentKey="#comment",t.prototype.convertRawKey="#raw",t.prototype.assertLegalChar=function(e){var t,r;if(this.options.noValidation)return e;if(t="","1.0"===this.options.version){if(t=/[\0-\x08\x0B\f\x0E-\x1F\uFFFE\uFFFF]|[\uD800-\uDBFF](?![\uDC00-\uDFFF])|(?:[^\uD800-\uDBFF]|^)[\uDC00-\uDFFF]/,r=e.match(t))throw Error("Invalid character in string: "+e+" at index "+r.index)}else if("1.1"===this.options.version&&(t=/[\0\uFFFE\uFFFF]|[\uD800-\uDBFF](?![\uDC00-\uDFFF])|(?:[^\uD800-\uDBFF]|^)[\uDC00-\uDFFF]/,r=e.match(t)))throw Error("Invalid character in string: "+e+" at index "+r.index);return e},t.prototype.assertLegalName=function(e){if(this.options.noValidation)return e;if(this.assertLegalChar(e),!e.match(/^([:A-Z_a-z\xC0-\xD6\xD8-\xF6\xF8-\u02FF\u0370-\u037D\u037F-\u1FFF\u200C\u200D\u2070-\u218F\u2C00-\u2FEF\u3001-\uD7FF\uF900-\uFDCF\uFDF0-\uFFFD]|[\uD800-\uDB7F][\uDC00-\uDFFF])([\x2D\.0-:A-Z_a-z\xB7\xC0-\xD6\xD8-\xF6\xF8-\u037D\u037F-\u1FFF\u200C\u200D\u203F\u2040\u2070-\u218F\u2C00-\u2FEF\u3001-\uD7FF\uF900-\uFDCF\uFDF0-\uFFFD]|[\uD800-\uDB7F][\uDC00-\uDFFF])*$/))throw Error("Invalid character in name");return e},t.prototype.textEscape=function(e){var t;return this.options.noValidation?e:(t=this.options.noDoubleEncoding?/(?!&\S+;)&/g:/&/g,e.replace(t,"&").replace(/</g,"<").replace(/>/g,">").replace(/\r/g,"
"))},t.prototype.attEscape=function(e){var t;return this.options.noValidation?e:(t=this.options.noDoubleEncoding?/(?!&\S+;)&/g:/&/g,e.replace(t,"&").replace(/</g,"<").replace(/"/g,""").replace(/\t/g,"	").replace(/\n/g,"
").replace(/\r/g,"
"))},t}()}).call(e.e)},411034,(e,t,r)=>{(function(){t.exports={None:0,OpenTag:1,InsideTag:2,CloseTag:3}}).call(e.e)},906800,(e,t,r)=>{(function(){var r,i,n,s={}.hasOwnProperty;n=e.r(12834).assign,r=e.r(146267),e.r(176337),e.r(294877),e.r(33299),e.r(7151),e.r(367935),e.r(547950),e.r(283730),e.r(777721),e.r(175548),e.r(190021),e.r(867079),e.r(51651),e.r(515548),i=e.r(411034),t.exports=function(){function e(e){var t,r,i;for(t in e||(e={}),this.options=e,r=e.writer||{})s.call(r,t)&&(i=r[t],this["_"+t]=this[t],this[t]=i)}return e.prototype.filterOptions=function(e){var t,r,s,a,o,l,u,c;return e||(e={}),e=n({},this.options,e),(t={writer:this}).pretty=e.pretty||!1,t.allowEmpty=e.allowEmpty||!1,t.indent=null!=(r=e.indent)?r:" ",t.newline=null!=(s=e.newline)?s:"\n",t.offset=null!=(a=e.offset)?a:0,t.dontPrettyTextNodes=null!=(o=null!=(l=e.dontPrettyTextNodes)?l:e.dontprettytextnodes)?o:0,t.spaceBeforeSlash=null!=(u=null!=(c=e.spaceBeforeSlash)?c:e.spacebeforeslash)?u:"",!0===t.spaceBeforeSlash&&(t.spaceBeforeSlash=" "),t.suppressPrettyCount=0,t.user={},t.state=i.None,t},e.prototype.indent=function(e,t,r){var i;if(!t.pretty||t.suppressPrettyCount);else if(t.pretty&&(i=(r||0)+t.offset+1)>0)return Array(i).join(t.indent);return""},e.prototype.endline=function(e,t,r){return!t.pretty||t.suppressPrettyCount?"":t.newline},e.prototype.attribute=function(e,t,r){var i;return this.openAttribute(e,t,r),i=" "+e.name+'="'+e.value+'"',this.closeAttribute(e,t,r),i},e.prototype.cdata=function(e,t,r){var n;return this.openNode(e,t,r),t.state=i.OpenTag,n=this.indent(e,t,r)+"<![CDATA[",t.state=i.InsideTag,n+=e.value,t.state=i.CloseTag,n+="]]>"+this.endline(e,t,r),t.state=i.None,this.closeNode(e,t,r),n},e.prototype.comment=function(e,t,r){var n;return this.openNode(e,t,r),t.state=i.OpenTag,n=this.indent(e,t,r)+"<!-- ",t.state=i.InsideTag,n+=e.value,t.state=i.CloseTag,n+=" -->"+this.endline(e,t,r),t.state=i.None,this.closeNode(e,t,r),n},e.prototype.declaration=function(e,t,r){var n;return this.openNode(e,t,r),t.state=i.OpenTag,n=this.indent(e,t,r)+"<?xml",t.state=i.InsideTag,n+=' version="'+e.version+'"',null!=e.encoding&&(n+=' encoding="'+e.encoding+'"'),null!=e.standalone&&(n+=' standalone="'+e.standalone+'"'),t.state=i.CloseTag,n+=t.spaceBeforeSlash+"?>",n+=this.endline(e,t,r),t.state=i.None,this.closeNode(e,t,r),n},e.prototype.docType=function(e,t,r){var n,s,a,o,l;if(r||(r=0),this.openNode(e,t,r),t.state=i.OpenTag,o=this.indent(e,t,r)+"<!DOCTYPE "+e.root().name,e.pubID&&e.sysID?o+=' PUBLIC "'+e.pubID+'" "'+e.sysID+'"':e.sysID&&(o+=' SYSTEM "'+e.sysID+'"'),e.children.length>0){for(o+=" [",o+=this.endline(e,t,r),t.state=i.InsideTag,s=0,a=(l=e.children).length;s<a;s++)n=l[s],o+=this.writeChildNode(n,t,r+1);t.state=i.CloseTag,o+="]"}return t.state=i.CloseTag,o+=t.spaceBeforeSlash+">",o+=this.endline(e,t,r),t.state=i.None,this.closeNode(e,t,r),o},e.prototype.element=function(e,t,n){var a,o,l,u,c,d,h,f,p,g,m,y,v,b;for(p in n||(n=0),g=!1,m="",this.openNode(e,t,n),t.state=i.OpenTag,m+=this.indent(e,t,n)+"<"+e.name,y=e.attribs)s.call(y,p)&&(a=y[p],m+=this.attribute(a,t,n));if(u=0===(l=e.children.length)?null:e.children[0],0===l||e.children.every(function(e){return(e.type===r.Text||e.type===r.Raw)&&""===e.value}))t.allowEmpty?(m+=">",t.state=i.CloseTag,m+="</"+e.name+">"+this.endline(e,t,n)):(t.state=i.CloseTag,m+=t.spaceBeforeSlash+"/>"+this.endline(e,t,n));else if(t.pretty&&1===l&&(u.type===r.Text||u.type===r.Raw)&&null!=u.value)m+=">",t.state=i.InsideTag,t.suppressPrettyCount++,g=!0,m+=this.writeChildNode(u,t,n+1),t.suppressPrettyCount--,g=!1,t.state=i.CloseTag,m+="</"+e.name+">"+this.endline(e,t,n);else{if(t.dontPrettyTextNodes){for(c=0,h=(v=e.children).length;c<h;c++)if(((o=v[c]).type===r.Text||o.type===r.Raw)&&null!=o.value){t.suppressPrettyCount++,g=!0;break}}for(m+=">"+this.endline(e,t,n),t.state=i.InsideTag,d=0,f=(b=e.children).length;d<f;d++)o=b[d],m+=this.writeChildNode(o,t,n+1);t.state=i.CloseTag,m+=this.indent(e,t,n)+"</"+e.name+">",g&&t.suppressPrettyCount--,m+=this.endline(e,t,n),t.state=i.None}return this.closeNode(e,t,n),m},e.prototype.writeChildNode=function(e,t,i){switch(e.type){case r.CData:return this.cdata(e,t,i);case r.Comment:return this.comment(e,t,i);
1case r.Element:return this.element(e,t,i);case r.Raw:return this.raw(e,t,i);case r.Text:return this.text(e,t,i);case r.ProcessingInstruction:return this.processingInstruction(e,t,i);case r.Dummy:return"";case r.Declaration:return this.declaration(e,t,i);case r.DocType:return this.docType(e,t,i);case r.AttributeDeclaration:return this.dtdAttList(e,t,i);case r.ElementDeclaration:return this.dtdElement(e,t,i);case r.EntityDeclaration:return this.dtdEntity(e,t,i);case r.NotationDeclaration:return this.dtdNotation(e,t,i);default:throw Error("Unknown XML node type: "+e.constructor.name)}},e.prototype.processingInstruction=function(e,t,r){var n;return this.openNode(e,t,r),t.state=i.OpenTag,n=this.indent(e,t,r)+"<?",t.state=i.InsideTag,n+=e.target,e.value&&(n+=" "+e.value),t.state=i.CloseTag,n+=t.spaceBeforeSlash+"?>",n+=this.endline(e,t,r),t.state=i.None,this.closeNode(e,t,r),n},e.prototype.raw=function(e,t,r){var n;return this.openNode(e,t,r),t.state=i.OpenTag,n=this.indent(e,t,r),t.state=i.InsideTag,n+=e.value,t.state=i.CloseTag,n+=this.endline(e,t,r),t.state=i.None,this.closeNode(e,t,r),n},e.prototype.text=function(e,t,r){var n;return this.openNode(e,t,r),t.state=i.OpenTag,n=this.indent(e,t,r),t.state=i.InsideTag,n+=e.value,t.state=i.CloseTag,n+=this.endline(e,t,r),t.state=i.None,this.closeNode(e,t,r),n},e.prototype.dtdAttList=function(e,t,r){var n;return this.openNode(e,t,r),t.state=i.OpenTag,n=this.indent(e,t,r)+"<!ATTLIST",t.state=i.InsideTag,n+=" "+e.elementName+" "+e.attributeName+" "+e.attributeType,"#DEFAULT"!==e.defaultValueType&&(n+=" "+e.defaultValueType),e.defaultValue&&(n+=' "'+e.defaultValue+'"'),t.state=i.CloseTag,n+=t.spaceBeforeSlash+">"+this.endline(e,t,r),t.state=i.None,this.closeNode(e,t,r),n},e.prototype.dtdElement=function(e,t,r){var n;return this.openNode(e,t,r),t.state=i.OpenTag,n=this.indent(e,t,r)+"<!ELEMENT",t.state=i.InsideTag,n+=" "+e.name+" "+e.value,t.state=i.CloseTag,n+=t.spaceBeforeSlash+">"+this.endline(e,t,r),t.state=i.None,this.closeNode(e,t,r),n},e.prototype.dtdEntity=function(e,t,r){var n;return this.openNode(e,t,r),t.state=i.OpenTag,n=this.indent(e,t,r)+"<!ENTITY",t.state=i.InsideTag,e.pe&&(n+=" %"),n+=" "+e.name,e.value?n+=' "'+e.value+'"':(e.pubID&&e.sysID?n+=' PUBLIC "'+e.pubID+'" "'+e.sysID+'"':e.sysID&&(n+=' SYSTEM "'+e.sysID+'"'),e.nData&&(n+=" N
1DATA "+e.nData)),t.state=i.CloseTag,n+=t.spaceBeforeSlash+">"+this.endline(e,t,r),t.state=i.None,this.closeNode(e,t,r),n},e.prototype.dtdNotation=function(e,t,r){var n;return this.openNode(e,t,r),t.state=i.OpenTag,n=this.indent(e,t,r)+"<!NOTATION",t.state=i.InsideTag,n+=" "+e.name,e.pubID&&e.sysID?n+=' PUBLIC "'+e.pubID+'" "'+e.sysID+'"':e.pubID?n+=' PUBLIC "'+e.pubID+'"':e.sysID&&(n+=' SYSTEM "'+e.sysID+'"'),t.state=i.CloseTag,n+=t.spaceBeforeSlash+">"+this.endline(e,t,r),t.state=i.None,this.closeNode(e,t,r),n},e.prototype.openNode=function(e,t,r){},e.prototype.closeNode=function(e,t,r){},e.prototype.openAttribute=function(e,t,r){},e.prototype.closeAttribute=function(e,t,r){},e}()}).call(e.e)},743883,(e,t,r)=>{(function(){var r=function(e,t){for(var r in t)i.call(t,r)&&(e[r]=t[r]);function n(){this.constructor=e}return n.prototype=t.prototype,e.prototype=new n,e.__super__=t.prototype,e},i={}.hasOwnProperty;t.exports=function(e){function t(e){t.__super__.constructor.call(this,e)}return r(t,e),t.prototype.document=function(e,t){var r,i,n,s,a;for(i=0,t=this.filterOptions(t),s="",n=(a=e.children).length;i<n;i++)r=a[i],s+=this.writeChildNode(r,t,0);return t.pretty&&s.slice(-t.newline.length)===t.newline&&(s=s.slice(0,-t.newline.length)),s},t}(e.r(906800))}).call(e.e)},852095,(e,t,r)=>{(function(){var r,i,n,s,a,o,l,u=function(e,t){for(var r in t)c.call(t,r)&&(e[r]=t[r]);function i(){this.constructor=e}return i.prototype=t.prototype,e.prototype=new i,e.__super__=t.prototype,e},c={}.hasOwnProperty;l=e.r(12834).isPlainObject,n=e.r(132109),i=e.r(760712),s=e.r(331571),r=e.r(146267),o=e.r(593964),a=e.r(743883),t.exports=function(e){function t(e){t.__super__.constructor.call(this,null),this.name="#document",this.type=r.Document,this.documentURI=null,this.domConfig=new i,e||(e={}),e.writer||(e.writer=new a),this.options=e,this.stringify=new o(e)}return u(t,e),Object.defineProperty(t.prototype,"implementation",{value:new n}),Object.defineProperty(t.prototype,"doctype",{get:function(){var e,t,i,n;for(t=0,i=(n=this.children).length;t<i;t++)if((e=n[t]).type===r.DocType)return e;return null}}),Object.defineProperty(t.prototype,"documentElement",{get:function(){return this.rootObject||null}}),Object.defineProperty(t.prototype,"inputEncoding",{get:function(){return null}}),Object.defineProperty(t.prototype,"strictErrorChecking",{get:function(){return!1}}),Object.defineProperty(t.prototype,"xmlEncoding",{get:function(){return 0!==this.children.length&&this.children[0].type===r.Declaration?this.children[0].encoding:null}}),Object.defineProperty(t.prototype,"xmlStandalone",{get:function(){return 0!==this.children.length&&this.children[0].type===r.Declaration&&"yes"===this.children[0].standalone}}),Object.defineProperty(t.prototype,"xmlVersion",{get:function(){return 0!==this.children.length&&this.children[0].type===r.Declaration?this.children[0].version:"1.0"}}),Object.defineProperty(t.prototype,"URL",{get:function(){return this.documentURI}}),Object.defineProperty(t.prototype,"origin",{get:function(){return null}}),Object.defineProperty(t.prototype,"compatMode",{get:function(){return null}}),Object.defineProperty(t.prototype,"characterSet",{get:function(){return null}}),Object.defineProperty(t.prototype,"contentType",{get:function(){return null}}),t.prototype.end=function(e){var t;return t={},e?l(e)&&(t=e,e=this.options.writer):e=this.options.writer,e.document(this,e.filterOptions(t))},t.prototype.toString=function(e){return this.options.writer.document(this,this.options.writer.filterOptions(e))},t.prototype.createElement=function(e){throw Error("This DOM method is not implemented."+this.debugInfo())},t.prototype.createDocumentFragment=function(){throw Error("This DOM method is not implemented."+this.debugInfo())},t.prototype.createTextNode=function(e){throw Error("This DOM method is not implemented."+this.debugInfo())},t.prototype.createComment=function(e){throw Error("This DOM method is not implemented."+this.debugInfo())},t.prototype.createCDATASection=function(e){throw Error("This DOM method is not implemented."+this.debugInfo())},t.prototype.createProcessingInstruction=function(e,t){throw Error("This DOM method is not implemented."+this.debugInfo())},t.prototype.createAttribute=function(e){throw Error("This DOM method is not implemented."+this.debugInfo())},t.prototype.createEntityReference=function(e){throw Error("This DOM method is not implemented."+this.debugInfo())},t.prototype.getElementsByTagName=function(e){throw Error("This DOM method is not implemented."+this.debugInfo())},t.prototype.importNode=function(e,t){throw Error("This DOM method is not implemented."+this.debugInfo())},t.prototype.createElementNS=function(e,t){throw Error("This DOM method is not implemented."+this.debugInfo())},t.prototype.createAttributeNS=function(e,t){throw Error("This DOM method is not implemented."+this.debugInfo())},t.prototype.getElementsByTagNameNS=function(e,t){throw Error("This DOM method is not implemented."+this.debugInfo())},t.prototype.getElementById=function(e){throw Error("This DOM method is not implemented."+this.debugInfo())},t.prototype.adoptNode=function(e){throw Error("This DOM method is not implemented."+this.debugInfo())},t.prototype.normalizeDocument=function(){throw Error("This DOM method is not implemented."+this.debugInfo())},t.prototype.renameNode=function(e,t,r){throw Error("This DOM method is not implemented."+this.debugInfo())},t.prototype.getElementsByClassName=function(e){throw Error("This DOM method is not implemented."+this.debugInfo())},t.prototype.createEvent=function(e){throw Error("This DOM method is not implemented."+this.debugInfo())},t.prototype.createRange=function(){throw Error("This DOM method is not implemented."+this.debugInfo())},t.prototype.createNodeIterator=function(e,t,r){throw Error("This DOM method is not implemented."+this.debugInfo())},t.prototype.createTreeWalker=function(e,t,r){throw Error("This DOM method is not implemented."+this.debugInfo())},t}(s)}).call(e.e)},895830,(e,t,r)=>{(function(){var r,i,n,s,a,o,l,u,c,d,h,f,p,g,m,y,v,b,_,E,S,x,T,w={}.hasOwnProperty;S=(T=e.r(12834)).isObject,E=T.isFunction,x=T.isPlainObject,_=T.getValue,r=e.r(146267),f=e.r(852095),p=e.r(367935),s=e.r(33299),a=e.r(7151),m=e.r(547950),b=e.r(283730),g=e.r(777721),d=e.r(176337),h=e.r(294877),o=e.r(190021),u=e.r(51651),l=e.r(867079),c=e.r(515548),n=e.r(732799),v=e.r(593964),y=e.r(743883),i=e.r(411034),t.exports=function(){function e(e,t,i){var n;this.name="?xml",this.type=r.Document,e||(e={}),n={},e.writer?x(e.writer)&&(n=e.writer,e.writer=new y):e.writer=new y,this.options=e,this.writer=e.writer,this.writerOptions=this.writer.filterOptions(n),this.stringify=new v(e),this.onDataCallback=t||function(){},this.onEndCallback=i||function(){},this.currentNode=null,this.currentLevel=-1,this.openTags={},this.documentStarted=!1,this.documentCompleted=!1,this.root=null}return e.prototype.createChildNode=function(e){var t,i,n,s,a,o,l,u;switch(e.type){case r.CData:this.cdata(e.value);break;case r.Comment:this.comment(e.value);break;case r.Element:for(i in n={},l=e.attribs)w.call(l,i)&&(t=l[i],n[i]=t.value);this.node(e.name,n);break;case r.Dummy:this.dummy();break;case r.Raw:this.raw(e.value);break;case r.Text:this.text(e.value);break;case r.ProcessingInstruction:this.instruction(e.target,e.value);break;default:throw Error("This XML node type is not supported in a JS object: "+e.constructor.name)}for(a=0,o=(u=e.children).length;a<o;a++)s=u[a],this.createChildNode(s),s.type===r.Element&&this.up();return this},e.prototype.dummy=function(){return this},e.prototype.node=function(e,t,r){var i;if(null==e)throw Error("Missing node name.");if(this.root&&-1===this.currentLevel)throw Error("Document can only have one root node. "+this.debugInfo(e));return this.openCurrent(),e=_(e),null==t&&(t={}),S(t=_(t))||(r=(i=[t,r])[0],t=i[1]),this.currentNode=new p(this,e,t),this.currentNode.children=!1,this.currentLevel++,this.openTags[this.currentLevel]=this.currentNode,null!=r&&this.text(r),this},e.prototype.element=function(e,t,i){var n,s,a,o,l,u;if(this.currentNode&&this.currentNode.type===r.DocType)this.dtdElement.apply(this,arguments);else if(Array.isArray(e)||S(e)||E(e))for(o=this.options.noValidation,this.options.noValidation=!0,(u=new f(this.options).element
1("TEMP_ROOT")).element(e),this.options.noValidation=o,s=0,a=(l=u.children).length;s<a;s++)n=l[s],this.createChildNode(n),n.type===r.Element&&this.up();else this.node(e,t,i);return this},e.prototype.attribute=function(e,t){var r,i;if(!this.currentNode||this.currentNode.children)throw Error("att() can only be used immediately after an ele() call in callback mode. "+this.debugInfo(e));if(null!=e&&(e=_(e)),S(e))for(r in e)w.call(e,r)&&(i=e[r],this.attribute(r,i));else E(t)&&(t=t.apply()),this.options.keepNullAttributes&&null==t?this.currentNode.attribs[e]=new n(this,e,""):null!=t&&(this.currentNode.attribs[e]=new n(this,e,t));return this},e.prototype.text=function(e){var t;return this.openCurrent(),t=new b(this,e),this.onData(this.writer.text(t,this.writerOptions,this.currentLevel+1),this.currentLevel+1),this},e.prototype.cdata=function(e){var t;return this.openCurrent(),t=new s(this,e),this.onData(this.writer.cdata(t,this.writerOptions,this.currentLevel+1),this.currentLevel+1),this},e.prototype.comment=function(e){var t;return this.openCurrent(),t=new a(this,e),this.onData(this.writer.comment(t,this.writerOptions,this.currentLevel+1),this.currentLevel+1),this},e.prototype.raw=function(e){var t;return this.openCurrent(),t=new m(this,e),this.onData(this.writer.raw(t,this.writerOptions,this.currentLevel+1),this.currentLevel+1),this},e.prototype.instruction=function(e,t){var r,i,n,s,a;if(this.openCurrent(),null!=e&&(e=_(e)),null!=t&&(t=_(t)),Array.isArray(e))for(r=0,s=e.length;r<s;r++)i=e[r],this.instruction(i);else if(S(e))for(i in e)w.call(e,i)&&(n=e[i],this.instruction(i,n));else E(t)&&(t=t.apply()),a=new g(this,e,t),this.onData(this.writer.processingInstruction(a,this.writerOptions,this.currentLevel+1),this.currentLevel+1);return this},e.prototype.declaration=function(e,t,r){var i;if(this.openCurrent(),this.documentStarted)throw Error("declaration() must be the first node.");return i=new d(this,e,t,r),this.onData(this.writer.declaration(i,this.writerOptions,this.currentLevel+1),this.currentLevel+1),this},e.prototype.doctype=function(e,t,r){if(this.openCurrent(),null==e)throw Error("Missing root node name.");if(this.root)throw Error("dtd() must come before the root node.");return this.currentNode=new h(this,t,r),this.currentNode.rootNodeName=e,this.currentNode.children=!1,this.currentLevel++,this.openTags[this.currentLevel]=this.currentNode,this},e.prototype.dtdElement=function(e,t){var r;return this.openCurrent(),r=new l(this,e,t),this.onData(this.writer.dtdElement(r,this.writerOptions,this.currentLevel+1),this.currentLevel+1),this},e.prototype.attList=function(e,t,r,i,n){var s;return this.openCurrent(),s=new o(this,e,t,r,i,n),this.onData(this.writer.dtdAttList(s,this.writerOptions,this.currentLevel+1),this.currentLevel+1),this},e.prototype.entity=function(e,t){var r;return this.openCurrent(),r=new u(this,!1,e,t),this.onData(this.writer.dtdEntity(r,this.writerOptions,this.currentLevel+1),this.currentLevel+1),this},e.prototype.pEntity=function(e,t){var r;return this.openCurrent(),r=new u(this,!0,e,t),this.onData(this.writer.dtdEntity(r,this.writerOptions,this.currentLevel+1),this.currentLevel+1),this},e.prototype.notation=function(e,t){var r;return this.openCurrent(),r=new c(this,e,t),this.onData(this.writer.dtdNotation(r,this.writerOptions,this.currentLevel+1),this.currentLevel+1),this},e.prototype.up=function(){if(this.currentLevel<0)throw Error("The document node has no parent.");return this.currentNode?(this.currentNode.children?this.closeNode(this.currentNode):this.openNode(this.currentNode),this.currentNode=null):this.closeNode(this.openTags[this.currentLevel]),delete this.openTags[this.currentLevel],this.currentLevel--,this},e.prototype.end=function(){for(;this.currentLevel>=0;)this.up();return this.onEnd()},e.prototype.openCurrent=function(){if(this.currentNode)return this.currentNode.children=!0,this.openNode(this.currentNode)},e.prototype.openNode=function(e){var t,n,s,a;if(!e.isOpen){if(this.root||0!==this.currentLevel||e.type!==r.Element||(this.root=e),n="",e.type===r.Element){for(s in this.writerOptions.state=i.OpenTag,n=this.writer.indent(e,this.writerOptions,this.currentLevel)+"<"+e.name,a=e.attribs)w.call(a,s)&&(t=a[s],n+=this.writer.attribute(t,this.writerOptions,this.currentLevel));n+=(e.children?">":"/>")+this.writer.endline(e,this.writerOptions,this.currentLevel),this.writerOptions.state=i.InsideTag}else this.writerOptions.state=i.OpenTag,n=this.writer.indent(e,this.writerOptions,this.currentLevel)+"<!DOCTYPE "+e.rootNodeName,e.pubID&&e.sysID?n+=' PUBLIC "'+e.pubID+'" "'+e.sysID+'"':e.sysID&&(n+=' SYSTEM "'+e.sysID+'"'),e.children?(n+=" [",this.writerOptions.state=i.InsideTag):(this.writerOptions.state=i.CloseTag,n+=">"),n+=this.writer.endline(e,this.writerOptions,this.currentLevel);return this.onData(n,this.currentLevel),e.isOpen=!0}},e.prototype.closeNode=function(e){var t;if(!e.isClosed)return t="",this.writerOptions.state=i.CloseTag,t=e.type===r.Element?this.writer.indent(e,this.writerOptions,this.currentLevel)+"</"+e.name+">"+this.writer.endline(e,this.writerOptions,this.currentLevel):this.writer.indent(e,this.writerOptions,this.currentLevel)+"]>"+this.writer.endline(e,this.writerOptions,this.currentLevel),this.writerOptions.state=i.None,this.onData(t,this.currentLevel),e.isClosed=!0},e.prototype.onData=function(e,t){return this.documentStarted=!0,this.onDataCallback(e,t+1)},e.prototype.onEnd=function(){return this.documentCompleted=!0,this.onEndCallback()},e.prototype.debugInfo=function(e){return null==e?"":"node: <"+e+">"},e.prototype.ele=function(){return this.element.apply(this,arguments)},e.prototype.nod=function(e,t,r){return this.node(e,t,r)},e.prototype.txt=function(e){return this.text(e)},e.prototype.dat=function(e){return this.cdata(e)},e.prototype.com=function(e){return this.comment(e)},e.prototype.ins=function(e,t){return this.instruction(e,t)},e.prototype.dec=function(e,t,r){return this.declaration(e,t,r)},e.prototype.dtd=function(e,t,r){return this.doctype(e,t,r)}
1,e.prototype.e=function(e,t,r){return this.element(e,t,r)},e.prototype.n=function(e,t,r){return this.node(e,t,r)},e.prototype.t=function(e){return this.text(e)},e.prototype.d=function(e){return this.cdata(e)},e.prototype.c=function(e){return this.comment(e)},e.prototype.r=function(e){return this.raw(e)},e.prototype.i=function(e,t){return this.instruction(e,t)},e.prototype.att=function(){return this.currentNode&&this.currentNode.type===r.DocType?this.attList.apply(this,arguments):this.attribute.apply(this,arguments)},e.prototype.a=function(){return this.currentNode&&this.currentNode.type===r.DocType?this.attList.apply(this,arguments):this.attribute.apply(this,arguments)},e.prototype.ent=function(e,t){return this.entity(e,t)},e.prototype.pent=function(e,t){return this.pEntity(e,t)},e.prototype.not=function(e,t){return this.notation(e,t)},e}()}).call(e.e)},257601,(e,t,r)=>{(function(){var r,i,n,s=function(e,t){for(var r in t)a.call(t,r)&&(e[r]=t[r]);function i(){this.constructor=e}return i.prototype=t.prototype,e.prototype=new i,e.__super__=t.prototype,e},a={}.hasOwnProperty;r=e.r(146267),n=e.r(906800),i=e.r(411034),t.exports=function(e){function t(e,r){this.stream=e,t.__super__.constructor.call(this,r)}return s(t,e),t.prototype.endline=function(e,r,n){return e.isLastRootNode&&r.state===i.CloseTag?"":t.__super__.endline.call(this,e,r,n)},t.prototype.document=function(e,t){var r,i,n,s,a,o,l,u,c;for(l=e.children,i=n=0,a=l.length;n<a;i=++n)(r=l[i]).isLastRootNode=i===e.children.length-1;for(s=0,t=this.filterOptions(t),u=e.children,c=[],o=u.length;s<o;s++)r=u[s],c.push(this.writeChildNode(r,t,0));return c},t.prototype.attribute=function(e,r,i){return this.stream.write(t.__super__.attribute.call(this,e,r,i))},t.prototype.cdata=function(e,r,i){return this.stream.write(t.__super__.cdata.call(this,e,r,i))},t.prototype.comment=function(e,r,i){return this.stream.write(t.__super__.comment.call(this,e,r,i))},t.prototype.declaration=function(e,r,i){return this.stream.write(t.__super__.declaration.call(this,e,r,i))},t.prototype.docType=function(e,t,r){var n,s,a,o;if(r||(r=0),this.openNode(e,t,r),t.state=i.OpenTag,this.stream.write(this.indent(e,t,r)),this.stream.write("<!DOCTYPE "+e.root().name),e.pubID&&e.sysID?this.stream.write(' PUBLIC "'+e.pubID+'" "'+e.sysID+'"'):e.sysID&&this.stream.write(' SYSTEM "'+e.sysID+'"'),e.children.length>0){for(this.stream.write(" ["),this.stream.write(this.endline(e,t,r)),t.state=i.InsideTag,s=0,a=(o=e.children).length;s<a;s++)n=o[s],this.writeChildNode(n,t,r+1);t.state=i.CloseTag,this.stream.write("]")}return t.state=i.CloseTag,this.stream.write(t.spaceBeforeSlash+">"),this.stream.write(this.endline(e,t,r)),t.state=i.None,this.closeNode(e,t,r)},t.prototype.element=function(e,t,n){var s,o,l,u,c,d,h,f,p;for(h in n||(n=0),this.openNode(e,t,n),t.state=i.OpenTag,this.stream.write(this.indent(e,t,n)+"<"+e.name),f=e.attribs)a.call(f,h)&&(s=f[h],this.attribute(s,t,n));if(u=0===(l=e.children.length)?null:e.children[0],0===l||e.children.every(function(e){return(e.type===r.Text||e.type===r.Raw)&&""===e.value}))t.allowEmpty?(this.stream.write(">"),t.state=i.CloseTag,this.stream.write("</"+e.name+">")):(t.state=i.CloseTag,this.stream.write(t.spaceBeforeSlash+"/>"));else if(t.pretty&&1===l&&(u.type===r.Text||u.type===r.Raw)&&null!=u.value)this.stream.write(">"),t.state=i.InsideTag,t.suppressPrettyCount++,this.writeChildNode(u,t,n+1),t.suppressPrettyCount--,t.state=i.CloseTag,this.stream.write("</"+e.name+">");else{for(this.stream.write(">"+this.endline(e,t,n)),t.state=i.InsideTag,c=0,d=(p=e.children).length;c<d;c++)o=p[c],this.writeChildNode(o,t,n+1);t.state=i.CloseTag,this.stream.write(this.indent(e,t,n)+"</"+e.name+">")}return this.stream.write(this.endline(e,t,n)),t.state=i.None,this.closeNode(e,t,n)},t.prototype.processingInstruction=function(e,r,i){return this.stream.write(t.__super__.processingInstruction.call(this,e,r,i))},t.prototype.raw=function(e,r,i){return this.stream.write(t.__super__.raw.call(this,e,r,i))},t.prototype.text=function(e,r,i){return this.stream.write(t.__super__.text.call(this,e,r,i))},t.prototype.dtdAttList=function(e,r,i){return this.stream.write(t.__super__.dtdAttList.call(this,e,r,i))},t.prototype.dtdElement=function(e,r,i){return this.stream.write(t.__super__.dtdElement.call(this,e,r,i))},t.prototype.dtdEntity=function(e,r,i){return this.stream.write(t.__super__.dtdEntity.call(this,e,r,i))},t.prototype.dtdNotation=function(e,r,i){return this.stream.write(t.__super__.dtdNotation.call(this,e,r,i))},t}(n)}).call(e.e)},2155,(e,t,r)=>{(function(){var r,i,n,s,a,o,l,u,c,d;u=(d=e.r(12834)).assign,c=d.isFunction,n=e.r(132109),s=e.r(852095),a=e.r(895830),l=e.r(743883),o=e.r(257601),r=e.r(146267),i=e.r(411034),t.exports.create=function(e,t,r,i){var n,a;if(null==e)throw Error("Root element needs a name.");return a=(n=new s(i=u({}
1,t,r,i))).element(e),i.headless||(n.declaration(i),(null!=i.pubID||null!=i.sysID)&&n.dtd(i)),a},t.exports.begin=function(e,t,r){var i;return(c(e)&&(t=(i=[e,t])[0],r=i[1],e={}),t)?new a(e,t,r):new s(e)},t.exports.stringWriter=function(e){return new l(e)},t.exports.streamWriter=function(e,t){return new o(e,t)},t.exports.implementation=new n,t.exports.nodeType=r,t.exports.writerState=i}).call(e.e)},163811,(e,t,r)=>{(function(){"use strict";var t,i,n,s,a,o={}.hasOwnProperty;t=e.r(2155),i=e.r(927271).defaults,s=function(e){return"string"==typeof e&&(e.indexOf("&")>=0||e.indexOf(">")>=0||e.indexOf("<")>=0)},a=function(e){return"<![CDATA["+n(e)+"]]>"},n=function(e){return e.replace("]]>","]]]]><![CDATA[>")},r.Builder=function(){function e(e){var t,r,n;for(t in this.options={},r=i["0.2"])o.call(r,t)&&(n=r[t],this.options[t]=n);for(t in e)o.call(e,t)&&(n=e[t],this.options[t]=n)}return e.prototype.buildObject=function(e){var r,n,l,u,c,d;return r=this.options.attrkey,n=this.options.charkey,1===Object.keys(e).length&&this.options.rootName===i["0.2"].rootName?(c=Object.keys(e)[0],e=e[c]):c=this.options.rootName,d=this,l=function(e,t){var i,u,c,h,f,p;if("object"!=typeof t)d.options.cdata&&s(t)?e.raw(a(t)):e.txt(t);else if(Array.isArray(t)){for(h in t)if(o.call(t,h))for(f in u=t[h])c=u[f],e=l(e.ele(f),c).up()}else for(f in t)if(o.call(t,f))if(u=t[f],f===r){if("object"==typeof u)for(i in u)p=u[i],e=e.att(i,p)}else if(f===n)e=d.options.cdata&&s(u)?e.raw(a(u)):e.txt(u);else if(Array.isArray(u))for(h in u)o.call(u,h)&&(e="string"==typeof(c=u[h])?d.options.cdata&&s(c)?e.ele(f).raw(a(c)).up():e.ele(f,c).up():l(e.ele(f),c).up());else"object"==typeof u?e=l(e.ele(f),u).up():"string"==typeof u&&d.options.cdata&&s(u)?e=e.ele(f).raw(a(u)).up():(null==u&&(u=""),e=e.ele(f,u.toString()).up());return e},u=t.create(c,this.options.xmldec,this.options.doctype,{headless:this.options.headless,allowSurrogateChars:this.options.allowSurrogateChars}),l(u,e).end(this.options.renderOpts)},e}()}).call(e.e)},430662,(e,t,r)=>{!function(){"use strict";var e={864:function(e){var t,r="object"==typeof Reflect?Reflect:null,i=r&&"function"==typeof r.apply?r.apply:function(e,t,r){return Function.prototype.apply.call(e,t,r)};t=r&&"function"==typeof r.ownKeys?r.ownKeys:Object.getOwnPropertySymbols?function(e){return Object.getOwnPropertyNames(e).concat(Object.getOwnPropertySymbols(e))}:function(e){return Object.getOwnPropertyNames(e)};var n=Number.isNaN||function(e){return e!=e};function s(){s.init.call(this)}e.exports=s,e.exports.once=function(e,t){return new Promise(function(r,i){var n,s,a;function o(r){e.removeListener(t,l),i(r)}function l(){"function"==typeof e.removeListener&&e.removeListener("error",o),r([].slice.call(arguments))}g(e,t,l,{once:!0}),"error"!==t&&(n=e,s=o,a={once:!0},"function"==typeof n.on&&g(n,"error",s,a))})},s.EventEmitter=s,s.prototype._events=void 0,s.prototype._eventsCount=0,s.prototype._maxListeners=void 0;var a=10;function o(e){if("function"!=typeof e)throw TypeError('The "listener" argument must be of type Function. Received type '+typeof e)}function l(e){return void 0===e._maxListeners?s.defaultMaxListeners:e._maxListeners}
1function u(e,t,r,i){if(o(r),void 0===(s=e._events)?(s=e._events=Object.create(null),e._eventsCount=0):(void 0!==s.newListener&&(e.emit("newListener",t,r.listener?r.listener:r),s=e._events),a=s[t]),void 0===a)a=s[t]=r,++e._eventsCount;else if("function"==typeof a?a=s[t]=i?[r,a]:[a,r]:i?a.unshift(r):a.push(r),(n=l(e))>0&&a.length>n&&!a.warned){a.warned=!0;var n,s,a,u=Error("Possible EventEmitter memory leak detected. "+a.length+" "+String(t)+" listeners added. Use emitter.setMaxListeners() to increase limit");u.name="MaxListenersExceededWarning",u.emitter=e,u.type=t,u.count=a.length,console&&console.warn&&console.warn(u)}return e}function c(){if(!this.fired)return(this.target.removeListener(this.type,this.wrapFn),this.fired=!0,0==arguments.length)?this.listener.call(this.target):this.listener.apply(this.target,arguments)}function d(e,t,r){var i={fired:!1,wrapFn:void 0,target:e,type:t,listener:r},n=c.bind(i);return n.listener=r,i.wrapFn=n,n}function h(e,t,r){var i=e._events;if(void 0===i)return[];var n=i[t];return void 0===n?[]:"function"==typeof n?r?[n.listener||n]:[n]:r?function(e){for(var t=Array(e.length),r=0;r<t.length;++r)t[r]=e[r].listener||e[r];return t}(n):p(n,n.length)}function f(e){var t=this._events;if(void 0!==t){var r=t[e];if("function"==typeof r)return 1;if(void 0!==r)return r.length}return 0}function p(e,t){for(var r=Array(t),i=0;i<t;++i)r[i]=e[i];return r}function g(e,t,r,i){if("function"==typeof e.on)i.once?e.once(t,r):e.on(t,r);else if("function"==typeof e.addEventListener)e.addEventListener(t,function n(s){i.once&&e.removeEventListener(t,n),r(s)});else throw TypeError('The "emitter" argument must be of type EventEmitter. Received type '+typeof e)}Object.defineProperty(s,"defaultMaxListeners",{enumerable:!0,get:function(){return a}
1,set:function(e){if("number"!=typeof e||e<0||n(e))throw RangeError('The value of "defaultMaxListeners" is out of range. It must be a non-negative number. Received '+e+".");a=e}}),s.init=function(){(void 0===this._events||this._events===Object.getPrototypeOf(this)._events)&&(this._events=Object.create(null),this._eventsCount=0),this._maxListeners=this._maxListeners||void 0},s.prototype.setMaxListeners=function(e){if("number"!=typeof e||e<0||n(e))throw RangeError('The value of "n" is out of range. It must be a non-negative number. Received '+e+".");return this._maxListeners=e,this},s.prototype.getMaxListeners=function(){return l(this)},s.prototype.emit=function(e){for(var t=[],r=1;r<arguments.length;r++)t.push(arguments[r]);var n="error"===e,s=this._events;if(void 0!==s)n=n&&void 0===s.error;else if(!n)return!1;if(n){if(t.length>0&&(a=t[0]),a instanceof Error)throw a;var a,o=Error("Unhandled error."+(a?" ("+a.message+")":""));throw o.context=a,o}var l=s[e];if(void 0===l)return!1;if("function"==typeof l)i(l,this,t);else for(var u=l.length,c=p(l,u),r=0;r<u;++r)i(c[r],this,t);return!0},s.prototype.addListener=function(e,t){return u(this,e,t,!1)},s.prototype.on=s.prototype.addListener,s.prototype.prependListener=function(e,t){return u(this,e,t,!0)},s.prototype.once=function(e,t){return o(t),this.on(e,d(this,e,t)),this},s.prototype.prependOnceListener=function(e,t){return o(t),this.prependListener(e,d(this,e,t)),this},s.prototype.removeListener=function(e,t){var r,i,n,s,a;if(o(t),void 0===(i=this._events)||void 0===(r=i[e]))return this;if(r===t||r.listener===t)0==--this._eventsCount?this._events=Object.create(null):(delete i[e],i.removeListener&&this.emit("removeListener",e,r.listener||t));else if("function"!=typeof r){for(n=-1,s=r.length-1;s>=0;s--)if(r[s]===t||r[s].listener===t){a=r[s].listener,n=s;break}if(n<0)return this;0===n?r.shift():function(e,t){for(;t+1<e.length;t++)e[t]=e[t+1];e.pop()}(r,n),1===r.length&&(i[e]=r[0]),void 0!==i.removeListener&&this.emit("removeListener",e,a||t)}return this},s.prototype.off=s.prototype.removeListener,s.prototype.removeAllListeners=function(e){var t,r,i;if(void 0===(r=this._events))return this;if(void 0===r.removeListener)return 0==arguments.length?(this._events=Object.create(null),this._eventsCount=0):void 0!==r[e]&&(0==--this._eventsCount?this._events=Object.create(null):delete r[e]),this;if(0==arguments.length){var n,s=Object.keys(r);for(i=0;i<s.length;++i)"removeListener"!==(n=s[i])&&this.removeAllListeners(n);return this.removeAllListeners("removeListener"),this._events=Object.create(null),this._eventsCount=0,this}if("function"==typeof(t=r[e]))this.removeListener(e,t);else if(void 0!==t)for(i=t.length-1;i>=0;i--)this.removeListener(e,t[i]);return this},s.prototype.listeners=function(e){return h(this,e,!0)},s.prototype.rawListeners=function(e){return h(this,e,!1)},s.listenerCount=function(e,t){return"function"==typeof e.listenerCount?e.listenerCount(t):f.call(e,t)},s.prototype.listenerCount=f,s.prototype.eventNames=function(){return this._eventsCount>0?t(this._events):[]}}},r={};function i(t){var n=r[t];if(void 0!==n)return n.exports;var s=r[t]={exports:{}},a=!0;try{e[t](s,s.exports,i),a=!1}finally{a&&delete r[t]}return s.exports}i.ab="/ROOT/node_modules/next/dist/compiled/events/",t.exports=i(864)}()},477398,(e,t,r)=>{var i=e.i(467034),n=e.i(247167),s={8992:function(e){e.exports=function(e,r,i){if(e.filter)return e.filter(r,i);if(null==e||"function"!=typeof r)throw TypeError();for(var n=[],s=0;s<e.length;s++)if(t.call(e,s)){var a=e[s];r.call(i,a,s,e)&&n.push(a)}return n};var t=Object.prototype.hasOwnProperty},5555:function(e,t,r){"use strict";var i=r(1212),n=r(1909),s=r(8737);e.exports=r(8772)||i.call(s,n)},9905:function(e,t,r){"use strict";var i=r(1212),n=r(1909),s=r(5555);e.exports=function(){return s(i,n,arguments)}},1909:function(e){"use strict";e.exports=Function.prototype.apply},8737:function(e){"use strict";e.exports=Function.prototype.call},7152:function(e,t,r){"use strict";var i=r(1212),n=r(8202),s=r(8737),a=r(5555);e.exports=function(e){if(e.length<1||"function"!=typeof e[0])throw new n("a function is required");return a(i,s,e)}},8772:function(e){"use strict";e.exports="u">typeof Reflect&&Reflect&&Reflect.apply},516:function(e,t,r){"use strict";var i=r(3197),n=r(9042),s=n(i("String.prototype.indexOf"));e.exports=function(e,t){var r=i(e,!!t);return"function"==typeof r&&s(e,".prototype.")>-1?n(r):r}},9042:function(e,t,r){"use strict";
1var i=r(3143),n=r(446),s=r(7152),a=r(9905);e.exports=function(e){var t=s(arguments),r=e.length-(arguments.length-1);return i(t,1+(r>0?r:0),!0)},n?n(e.exports,"apply",{value:a}):e.exports.apply=a},819:function(e,t,r){"use strict";var i=r(446),n=r(5182),s=r(8202),a=r(3990);e.exports=function(e,t,r){if(!e||"object"!=typeof e&&"function"!=typeof e)throw new s("`obj` must be an object or a function`");if("string"!=typeof t&&"symbol"!=typeof t)throw new s("`property` must be a string or a symbol`");if(arguments.length>3&&"boolean"!=typeof arguments[3]&&null!==arguments[3])throw new s("`nonEnumerable`, if provided, must be a boolean or null");if(arguments.length>4&&"boolean"!=typeof arguments[4]&&null!==arguments[4])throw new s("`nonWritable`, if provided, must be a boolean or null");if(arguments.length>5&&"boolean"!=typeof arguments[5]&&null!==arguments[5])throw new s("`nonConfigurable`, if provided, must be a boolean or null");if(arguments.length>6&&"boolean"!=typeof arguments[6])throw new s("`loose`, if provided, must be a boolean");var o=arguments.length>3?arguments[3]:null,l=arguments.length>4?arguments[4]:null,u=arguments.length>5?arguments[5]:null,c=arguments.length>6&&arguments[6],d=!!a&&a(e,t);if(i)i(e,t,{configurable:null===u&&d?d.configurable:!u,enumerable:null===o&&d?d.enumerable:!o,value:r,writable:null===l&&d?d.writable:!l});else if(!c&&(o||l||u))throw new n("This environment does not support defining a property as non-configurable, non-writable, or non-enumerable.");else e[t]=r}},6211:function(e,t,r){"use strict";var i,n=r(7152),s=r(3990);try{i=[].__proto__===Array.prototype}catch(e){if(!e||"object"!=typeof e||!("code"in e)||"ERR_PROTO_ACCESS"!==e.code)throw e}var a=!!i&&s&&s(Object.prototype,"__proto__"),o=Object,l=o.getPrototypeOf;e.exports=a&&"function"==typeof a.get?n([a.get]):"function"==typeof l&&function(e){return l(null==e?e:o(e))}},446:function(e){"use strict";var t=Object.defineProperty||!1;if(t)try{t({},"a",{value:1})}catch(e){t=!1}e.exports=t},7181:function(e){"use strict";e.exports=EvalError},1545:function(e){"use strict";e.exports=Error},22:function(e){"use strict";e.exports=RangeError},2803:function(e){"use strict";e.exports=ReferenceError},5182:function(e){"use strict";e.exports=SyntaxError},8202:function(e){"use strict";e.exports=TypeError},3284:function(e){"use strict";e.exports=URIError},2811:function(e){"use strict";e.exports=Object},6144:function(e){var t=Object.prototype.hasOwnProperty,r=Object.prototype.toString;e.exports=function(e,i,n){if("[object Function]"!==r.call(i))throw TypeError("iterator must be a function");var s=e.length;if(s===+s)for(var a=0;a<s;a++)i.call(n,e[a],a,e);else for(var o in e)t.call(e,o)&&i.call(n,e[o],o,e)}},3136:function(e){"use strict";var t=Object.prototype.toString,r=Math.max,i=function(e,t){for(var r=[],i=0;i<e.length;i+=1)r[i]=e[i];for(var n=0;n<t.length;n+=1)r[n+e.length]=t[n];return r},n=function(e,t){for(var r=[],i=t||0,n=0;i<e.length;i+=1,n+=1)r[n]=e[i];return r},s=function(e,t){for(var r="",i=0;i<e.length;i+=1)r+=e[i],i+1<e.length&&(r+=t);return r};e.exports=function(e){var a,o=this;if("function"!=typeof o||"[object Function]"!==t.apply(o))throw TypeError("Function.prototype.bind called on incompatible "+o);for(var l=n(arguments,1),u=r(0,o.length-l.length),c=[],d=0;d<u;d++)c[d]="$"+d;if(a=Function("binder","return function ("+s(c,",")+"){ return binder.apply(this,arguments); }")(function(){if(this instanceof a){var t=o.apply(this,i(l,arguments));return Object(t)===t?t:this}return o.apply(e,i(l,arguments))}),o.prototype){var h=function(){};h.prototype=o.prototype,a.prototype=new h,h.prototype=null}return a}},1212:function(e,t,r){"use strict";var i=r(3136);e.exports=Function.prototype.bind||i},3197:function(e,t,r){"use strict";var i,n=r(2811),s=r(1545),a=r(7181),o=r(22),l=r(2803),u=r(5182),c=r(8202),d=r(3284),h=r(7173),f=r(847),p=r(2916),g=r(9882),m=r(3291),y=r(553),v=r(8629),b=Function,_=function(e){try{return b('"use strict"; return ('+e+").constructor;")()}catch(e){}},E=r(3990),S=r(446),x=function(){throw new c},T=E?function(){try{return arguments.callee,x}catch(e){try{return E(arguments,"callee").get}catch(e){return x}}}():x,w=r(4871)(),A=r(699),R=r(7823),I=r(7904),k=r(1909),C=r(8737),D={},L="u">typeof Uint8Array&&A?A(Uint8Array):i,O={__proto__:null,"%AggregateError%":"u"<typeof AggregateError?i:AggregateError,"%Array%":Array,"%ArrayBuffer%":"u"<typeof ArrayBuffer?i:ArrayBuffer,"%ArrayIteratorPrototype%":w&&A?A([][Symbol.iterator]()):i,"%AsyncFromSyncIteratorPrototype%":i,"%AsyncFunction%":D,"%AsyncGenerator%":D,"%AsyncGeneratorFunction%":D,"%AsyncIteratorPrototype%":D,"%Atomics%":"u"<typeof Atomics?i:Atomics,"%BigInt%":"u"<typeof BigInt?i:BigInt,"%BigInt64Array%":"u"<typeof BigInt64Array?i:BigInt64Array,"%BigUint64Array%":"u"<typeof BigUint64Array?i:BigUint64Array,"%Boolean%":Boolean,"%DataView%":"u"<typeof DataView?i:DataView,"%Date%":Date,"%decodeURI%":decodeURI,"%decodeURIComponent%":decodeURIComponent,"%encodeURI%":encodeURI,"%encodeURIComponent%":encodeURIComponent,"%Error%":s,"%eval%":eval,"%EvalError%":a,"%Float16Array%":"u"<typeof Float16Array?i:Float16Array,"%Float32Array%":"u"<typeof Float32Array?i:Float32Array,"%Float64Array%":"u"<typeof Float64Array?i:Float64Array,"%FinalizationRegistry%":"u"<typeof FinalizationRegistry?i:FinalizationRegistry,"%Function%":b,"%GeneratorFunction%":D,"%Int8Array%":"u"<typeof Int8Array?i:Int8Array,"%Int16Array%":"u"<typeof Int16Array?i:Int16Array,"%Int32Array%":"u"<typeof Int32Array?i:Int32Array,"%isFinite%":isFinite,"%isNaN%":isNaN,"%
1IteratorPrototype%":w&&A?A(A([][Symbol.iterator]())):i,"%JSON%":"object"==typeof JSON?JSON:i,"%Map%":"u"<typeof Map?i:Map,"%MapIteratorPrototype%":"u">typeof Map&&w&&A?A((new Map)[Symbol.iterator]()):i,"%Math%":Math,"%Number%":Number,"%Object%":n,"%Object.getOwnPropertyDescriptor%":E,"%parseFloat%":parseFloat,"%parseInt%":parseInt,"%Promise%":"u"<typeof Promise?i:Promise,"%Proxy%":"u"<typeof Proxy?i:Proxy,"%RangeError%":o,"%ReferenceError%":l,"%Reflect%":"u"<typeof Reflect?i:Reflect,"%RegExp%":RegExp,"%Set%":"u"<typeof Set?i:Set,"%SetIteratorPrototype%":"u">typeof Set&&w&&A?A((new Set)[Symbol.iterator]()):i,"%SharedArrayBuffer%":"u"<typeof SharedArrayBuffer?i:SharedArrayBuffer,"%String%":String,"%StringIteratorPrototype%":w&&A?A(""[Symbol.iterator]()):i,"%Symbol%":w?Symbol:i,"%SyntaxError%":u,"%ThrowTypeError%":T,"%TypedArray%":L,"%TypeError%":c,"%Uint8Array%":"u"<typeof Uint8Array?i:Uint8Array,"%Uint8ClampedArray%":"u"<typeof Uint8ClampedArray?i:Uint8ClampedArray,"%Uint16Array%":"u"<typeof Uint16Array?i:Uint16Array,"%Uint32Array%":"u"<typeof Uint32Array?i:Uint32Array,"%URIError%":d,"%WeakMap%":"u"<typeof WeakMap?i:WeakMap,"%WeakRef%":"u"<typeof WeakRef?i:WeakRef,"%WeakSet%":"u"<typeof WeakSet?i:WeakSet,"%Function.prototype.call%":C,"%Function.prototype.apply%":k,"%Object.defineProperty%":S,"%Object.getPrototypeOf%":R,"%Math.abs%":h,"%Math.floor%":f,"%Math.max%":p,"%Math.min%":g,"%Math.pow%":m,"%Math.round%":y,"%Math.sign%":v,"%Reflect.getPrototypeOf%":I};if(A)try{null.error}catch(e){var P=A(A(e));O["%Error.prototype%"]=P}var F=function e(t){var r;if("%AsyncFunction%"===t)r=_("async function () {}");else if("%GeneratorFunction%"===t)r=_("function* () {}");else if("%AsyncGeneratorFunction%"===t)r=_("async function* () {}");else if("%AsyncGenerator%"===t){var i=e("%AsyncGeneratorFunction%");i&&(r=i.prototype)}else if("%AsyncIteratorPrototype%"===t){var n=e("%AsyncGenerator%");n&&A&&(r=A(n.prototype))}return O[t]=r,r},N={__proto__:null,"%ArrayBufferPrototype%":["ArrayBuffer","prototype"],"%ArrayPrototype%":["Array","prototype"],"%ArrayProto_entries%":["Array","prototype","entries"],"%ArrayProto_forEach%":["Array","prototype","forEach"],"%ArrayProto_keys%":["Array","prototype","keys"],"%ArrayProto_values%":["Array","prototype","values"],"%AsyncFunctionPrototype%":["AsyncFunction","prototype"],"%AsyncGenerator%":["AsyncGeneratorFunction","prototype"],"%AsyncGeneratorPrototype%":["AsyncGeneratorFunction","prototype","prototype"],"%BooleanPrototype%":["Boolean","prototype"],"%DataViewPrototype%":["DataView","prototype"],"%DatePrototype%":["Date","prototype"],"%ErrorPrototype%":["Error","prototype"],"%EvalErrorPrototype%":["EvalError","prototype"],"%Float32ArrayPrototype%":["Float32Array","prototype"],"%Float64ArrayPrototype%":["Float64Array","prototype"],"%FunctionPrototype%":["Function","prototype"],"%Generator%":["GeneratorFunction","prototype"],"%GeneratorPrototype%":["GeneratorFunction","prototype","prototype"],"%Int8ArrayPrototype%":["Int8Array","prototype"],"%Int16ArrayPrototype%":["Int16Array","prototype"],"%Int32ArrayPrototype%":["Int32Array","prototype"],"%JSONParse%":["JSON","parse"],"%JSONStringify%":["JSON","stringify"],"%MapPrototype%":["Map","prototype"],"%NumberPrototype%":["Number","prototype"],"%ObjectPrototype%":["Object","prototype"],"%ObjProto_toString%":["Object","prototype","toString"],"%ObjProto_valueOf%":["Object","prototype","valueOf"],"%PromisePrototype%":["Promise","prototype"],"%PromiseProto_then%":["Promise","prototype","then"],"%Promise_all%":["Promise","all"],"%Promise_reject%":["Promise","reject"],"%Promise_resolve%":["Promise","resolve"],"%RangeErrorPrototype%":["RangeError","prototype"],"%ReferenceErrorPrototype%":["ReferenceError","prototype"],"%RegExpPrototype%":["RegExp","prototype"],"%SetPrototype%":["Set","prototype"],"%SharedArrayBufferPrototype%":["SharedArrayBuffer","prototype"],"%StringPrototype%":["String","prototype"],"%SymbolPrototype%":["Symbol","prototype"],"%SyntaxErrorPrototype%":["SyntaxError","prototype"],"%TypedArrayPrototype%":["TypedArray","prototype"],"%TypeErrorPrototype%":["TypeError","prototype"],"%Uint8ArrayPrototype%":["Uint8Array","prototype"],"%Uint8ClampedArrayPrototype%":["Uint8ClampedArray","prototype"],"%Uint16ArrayPrototype%":["Uint16Array","prototype"],"%Uint32ArrayPrototype%":["Uint32Array","prototype"],"%URIErrorPrototype%":["URIError","prototype"],"%WeakMapPrototype%":["WeakMap","prototype"],"%WeakSetPrototype%":["WeakSet","prototype"]},M=r(1212),j=r(3270),$=M.call(C,Array.prototype.concat),U=M.call(k,Array.prototype.splice),B=M.call(C,String.prototype.replace),V=M.call(C,String.prototype.slice),G=M.call(C,RegExp.prototype.exec),q=/[^%.[\]]+|\[(?:(-?\d+(?:\.\d+)?)|(["'])((?:(?!\2)[^\\]|\\.)*?)\2)\]|(?=(?:\.|\[\])(?:\.|\[\]|%$))/g,H=/\\(\\)?/g,z=function(e){var t=V(e,0,1),r=V(e,-1);if("%"===t&&"%"!==r)throw new u("invalid intrinsic syntax, expected closing `%`");if("%"===r&&"%"!==t)throw new u("invalid intrinsic syntax, expected opening `%`");var i=[];return B(e,q,function(e,t,r,n){i[i.length]=r?B(n,H,"$1"):t||e}),i},K=function(e,t){var r,i=e;if(j(N,i)&&(i="%"+(r=N[i])[0]+"%"),j(O,i)){var n=O[i];if(n===D&&(n=F(i)),void 0===n&&!t)throw new c("intrinsic "+e+" exists, but is not available. Please file an issue!");return{alias:r,name:i,value:n}}throw new u("intrinsic "+e+" does not exist!")};e.exports=function(e,t){if("string"!=typeof e||0===e.length)throw new c("intrinsic name must be a non-empty string");if(arguments.length>1&&"boolean"!=typeof t)throw new c('"allowMissing" argument must be a boolean');if(null===G(/^%?[^%]*%?$/,e))throw new u("`%` may not be present anywhere but at the beginning and end of the intrinsic name");var r=z(e),i=r.length>0?r[0]:"",n=K("%"+i+"%",t),s=n.name,a=n.value,o=!1,l=n.alias;l&&(i=l[0],U(r,$([0,1],l)));for(var d=1,h=!0;d<r.length;d+=1){var f=r[d],p=V(f,0,1),g=V(f,-1);if(('"'===p||"'"===p||"`"===p||'"'===g||"'"===g||"`"===g)&&p!==g)throw new u("property names with quotes must have matching quotes");if("constructor"!==f&&h||(o=!0),i+="."+f,j(O,s="%"+i+"%"))a=O[s];
1else if(null!=a){if(!(f in a)){if(!t)throw new c("base intrinsic for "+e+" exists, but the property is not available.");return}if(E&&d+1>=r.length){var m=E(a,f);a=(h=!!m)&&"get"in m&&!("originalValue"in m.get)?m.get:a[f]}else h=j(a,f),a=a[f];h&&!o&&(O[s]=a)}}return a}},7823:function(e,t,r){"use strict";e.exports=r(2811).getPrototypeOf||null},7904:function(e){"use strict";e.exports="u">typeof Reflect&&Reflect.getPrototypeOf||null},699:function(e,t,r){"use strict";var i=r(7904),n=r(7823),s=r(6211);e.exports=i?function(e){return i(e)}:n?function(e){if(!e||"object"!=typeof e&&"function"!=typeof e)throw TypeError("getProto: not an object");return n(e)}:s?function(e){return s(e)}:null},4596:function(e){"use strict";e.exports=Object.getOwnPropertyDescriptor},3990:function(e,t,r){"use strict";var i=r(4596);if(i)try{i([],"length")}catch(e){i=null}e.exports=i},7122:function(e,t,r){"use strict";var i=r(446),n=function(){return!!i};n.hasArrayLengthDefineBug=function(){if(!i)return null;try{return 1!==i([],"length",{value:1}).length}catch(e){return!0}},e.exports=n},9942:function(e,t,r){"use strict";var i="u">typeof Symbol&&Symbol,n=r(3773);e.exports=function(){return"function"==typeof i&&"function"==typeof Symbol&&"symbol"==typeof i("foo")&&"symbol"==typeof Symbol("bar")&&n()}},3773:function(e){"use strict";e.exports=function(){if("function"!=typeof Symbol||"function"!=typeof Object.getOwnPropertySymbols)return!1;if("symbol"==typeof Symbol.iterator)return!0;var e={},t=Symbol("test"),r=Object(t);if("string"==typeof t||"[object Symbol]"!==Object.prototype.toString.call(t)||"[object Symbol]"!==Object.prototype.toString.call(r))return!1;for(t in e[t]=42,e)return!1;if("function"==typeof Object.keys&&0!==Object.keys(e).length||"function"==typeof Object.getOwnPropertyNames&&0!==Object.getOwnPropertyNames(e).length)return!1;var i=Object.getOwnPropertySymbols(e);if(1!==i.length||i[0]!==t||!Object.prototype.propertyIsEnumerable.call(e,t))return!1;if("function"==typeof Object.getOwnPropertyDescriptor){var n=Object.getOwnPropertyDescriptor(e,t);if(42!==n.value||!0!==n.enumerable)return!1}return!0}},4871:function(e,t,r){"use strict";var i="u">typeof Symbol&&Symbol,n=r(5960);e.exports=function(){return"function"==typeof i&&"function"==typeof Symbol&&"symbol"==typeof i("foo")&&"symbol"==typeof Symbol("bar")&&n()}},5960:function(e){"use strict";e.exports=function(){if("function"!=typeof Symbol||"function"!=typeof Object.getOwnPropertySymbols)return!1;if("symbol"==typeof Symbol.iterator)return!0;var e={},t=Symbol("test"),r=Object(t);if("string"==typeof t||"[object Symbol]"!==Object.prototype.toString.call(t)||"[object Symbol]"!==Object.prototype.toString.call(r))return!1;for(var i in e[t]=42,e)return!1;if("function"==typeof Object.keys&&0!==Object.keys(e).length||"function"==typeof Object.getOwnPropertyNames&&0!==Object.getOwnPropertyNames(e).length)return!1;var n=Object.getOwnPropertySymbols(e);if(1!==n.length||n[0]!==t||!Object.prototype.propertyIsEnumerable.call(e,t))return!1;if("function"==typeof Object.getOwnPropertyDescriptor){var s=Object.getOwnPropertyDescriptor(e,t);if(42!==s.value||!0!==s.enumerable)return!1}return!0}},3270:function(e,t,r){"use strict";var i=Function.prototype.call,n=Object.prototype.hasOwnProperty;e.exports=r(1212).call(i,n)},3782:function(e){"function"==typeof Object.create?e.exports=function(e,t){t&&(e.super_=t,e.prototype=Object.create(t.prototype,{constructor:{value:e,enumerable:!1,writable:!0,configurable:!0}}))}:e.exports=function(e,t){if(t){e.super_=t;var r=function(){};r.prototype=t.prototype,e.prototype=new r,e.prototype.constructor=e}}},5157:function(e){"use strict";var t="function"==typeof Symbol&&"symbol"==typeof Symbol.toStringTag,r=Object.prototype.toString,i=function(e){return(!t||!e||"object"!=typeof e||!(Symbol.toStringTag in e))&&"[object Arguments]"===r.call(e)},n=function(e){return!!i(e)||null!==e&&"object"==typeof e&&"number"==typeof e.length&&e.length>=0&&"[object Array]"!==r.call(e)&&"[object Function]"===r.call(e.callee)},s=function(){return i(arguments)}();i.isLegacyArguments=n,e.exports=s?i:n},3391:function(e){"use strict";var t=Object.prototype.toString,r=Function.prototype.toString,i=/^\s*(?:function)?\*/,n="function"==typeof Symbol&&"symbol"==typeof Symbol.toStringTag,s=Object.getPrototypeOf,a=function(){if(!n)return!1;try{return Function("return function*() {}")()}catch(e){}}(),o=a?s(a):{};e.exports=function(e){return"function"==typeof e&&(!!i.test(r.call(e))||(n?s(e)===o:"[object GeneratorFunction]"===t.call(e)))}},994:function(t,r,i){"use strict";var n=i(6144),s=i(1349),a=i(516),o=a("Object.prototype.toString"),l=i(9942)()&&"symbol"==typeof Symbol.toStringTag,u=s(),c=a("Array.prototype.indexOf",!0)||function(e,t){for(var r=0;r<e.length;r+=1)if(e[r]===t)return r;return -1},d=a("String.prototype.slice"),h={},f=i(2154),p=Object.getPrototypeOf;l&&f&&p&&n(u,function(t){var r=new e.g[t];if(!(Symbol.toStringTag in r))throw EvalError("this engine has support for Symbol.toStringTag, but "+t+" does not have the property! Please report this.");var i=p(r),n=f(i,Symbol.toStringTag);n||(n=f(p(i),Symbol.toStringTag)),h[t]=n.get});var g=function(e){var t=!1;return n(h,function(r,i){if(!t)try{t=r.call(e)===i}catch(e){}}),t};t.exports=function(e){return!!e&&"object"==typeof e&&(l?!!f&&g(e):c(u,d(o(e),8,-1))>-1)}},7173:function(e){"use strict";e.exports=Math.abs},847:function(e){"use strict";e.exports=Math.floor},219:function(e){"use strict";e.exports=Number.isNaN||function(e){return e!=e}},2916:function(e){"use strict";e.exports=Math.max},9882:function(e){"use strict";e.exports=Math.min},3291:function(e){"use strict";e.exports=Math.pow},553:function(e){"use strict";e.exports=Math.round},8629:function(e,t,r){"use strict";var i=r(219);e.exports=function(e){return i(e)||0===e?e:e<0?-1:1}},3143:function(e,t,r){"use strict";var i=r(3197),n=r(819),s=r(7122)(),a=r(3990),o=r(8202),l=i("%Math.floor%");e.exports=function(e,t){if("function"!=typeof e)throw new o("`fn` is not a function");if("number"!=typeof t||t<0||t>0xffffffff||l(t)!==t)throw new o("`length` must be a positive 32-bit integer");var r=arguments.length>2&&!!arguments[2],i=!0,u=!0;if("length"in e&&a){var c=a(e,"length");c&&!c.configurable&&(i=!1),c&&!c.writable&&(u=!1)}return(i||u||!r)&&(s?n(e,"length",t,!0,!0):n(e,"length",t)),e}},2369:function(e){e.exports=function(e){return e instanceof i.Buffer}},5584:function(e,t,r){"use strict";
1var i=r(5157),n=r(3391),s=r(1490),a=r(994);function o(e){return e.call.bind(e)}var l="u">typeof BigInt,u="u">typeof Symbol,c=o(Object.prototype.toString),d=o(Number.prototype.valueOf),h=o(String.prototype.valueOf),f=o(Boolean.prototype.valueOf);if(l)var p=o(BigInt.prototype.valueOf);if(u)var g=o(Symbol.prototype.valueOf);function m(e,t){if("object"!=typeof e)return!1;try{return t(e),!0}catch(e){return!1}}function y(e){return"[object Map]"===c(e)}function v(e){return"[object Set]"===c(e)}function b(e){return"[object WeakMap]"===c(e)}function _(e){return"[object WeakSet]"===c(e)}function E(e){return"[object ArrayBuffer]"===c(e)}function S(e){return!("u"<typeof ArrayBuffer)&&(E.working?E(e):e instanceof ArrayBuffer)}function x(e){return"[object DataView]"===c(e)}function T(e){return!("u"<typeof DataView)&&(x.working?x(e):e instanceof DataView)}t.isArgumentsObject=i,t.isGeneratorFunction=n,t.isTypedArray=a,t.isPromise=function(e){return"u">typeof Promise&&e instanceof Promise||null!==e&&"object"==typeof e&&"function"==typeof e.then&&"function"==typeof e.catch},t.isArrayBufferView=function(e){return"u">typeof ArrayBuffer&&ArrayBuffer.isView?ArrayBuffer.isView(e):a(e)||T(e)},t.isUint8Array=function(e){return"Uint8Array"===s(e)},t.isUint8ClampedArray=function(e){return"Uint8ClampedArray"===s(e)},t.isUint16Array=function(e){return"Uint16Array"===s(e)},t.isUint32Array=function(e){return"Uint32Array"===s(e)},t.isInt8Array=function(e){return"Int8Array"===s(e)},t.isInt16Array=function(e){return"Int16Array"===s(e)},t.isInt32Array=function(e){return"Int32Array"===s(e)},t.isFloat32Array=function(e){return"Float32Array"===s(e)},t.isFloat64Array=function(e){return"Float64Array"===s(e)},t.isBigInt64Array=function(e){return"BigInt64Array"===s(e)},t.isBigUint64Array=function(e){return"BigUint64Array"===s(e)},y.working="u">typeof Map&&y(new Map),t.isMap=function(e){return!("u"<typeof Map)&&(y.working?y(e):e instanceof Map)},v.working="u">typeof Set&&v(new Set),t.isSet=function(e){return!("u"<typeof Set)&&(v.working?v(e):e instanceof Set)},b.working="u">typeof WeakMap&&b(new WeakMap),t.isWeakMap=function(e){return!("u"<typeof WeakMap)&&(b.working?b(e):e instanceof WeakMap)},_.working="u">typeof WeakSet&&_(new WeakSet),t.isWeakSet=function(e){return _(e)},E.working="u">typeof ArrayBuffer&&E(new ArrayBuffer),t.isArrayBuffer=S,x.working="u">typeof ArrayBuffer&&"u">typeof DataView&&x(new DataView(new ArrayBuffer(1),0,1)),t.isDataView=T;var w="u">typeof SharedArrayBuffer?SharedArrayBuffer:void 0;function A(e){return"[object SharedArrayBuffer]"===c(e)}function R(e){return void 0!==w&&(void 0===A.working&&(A.working=A(new w)),A.working?A(e):e instanceof w)}function I(e){return m(e,d)}function k(e){return m(e,h)}function C(e){return m(e,f)}function D(e){return l&&m(e,p)}function L(e){return u&&m(e,g)}t.isSharedArrayBuffer=R,t.isAsyncFunction=function(e){return"[object AsyncFunction]"===c(e)},t.isMapIterator=function(e){return"[object Map Iterator]"===c(e)},t.isSetIterator=function(e){return"[object Set Iterator]"===c(e)},t.isGeneratorObject=function(e){return"[object Generator]"===c(e)},t.isWebAssemblyCompiledModule=function(e){return"[object WebAssembly.Module]"===c(e)},t.isNumberObject=I,t.isStringObject=k,t.isBooleanObject=C,t.isBigIntObject=D,t.isSymbolObject=L,t.isBoxedPrimitive=function(e){return I(e)||k(e)||C(e)||D(e)||L(e)},t.isAnyArrayBuffer=function(e){return"u">typeof Uint8Array&&(S(e)||R(e))},["isProxy","isExternal","isModuleNamespaceObject"].forEach(function(e){Object.defineProperty(t,e,{enumerable:!1,value:function(){throw Error(e+" is not supported in userland")}})})},8177:function(e,t,r){var i=Object.getOwnPropertyDescriptors||function(e){for(var t=Object.keys(e),r={},i=0;i<t.length;i++)r[t[i]]=Object.getOwnPropertyDescriptor(e,t[i]);return r},s=/%[sdj%]/g;t.format=function(e){if(!b(e)){for(var t=[],r=0;r<arguments.length;r++)t.push(u(arguments[r]));return t.join(" ")}for(var r=1,i=arguments,n=i.length,a=String(e).replace(s,function(e){if("%%"===e)return"%";if(r>=n)return e;switch(e){case"%s":return String(i[r++]);case"%d":return Number(i[r++]);case"%j":try{return JSON.stringify(i[r++])}catch(e){return"[Circular]"}default:return e}}),o=i[r];r<n;o=i[++r])y(o)||!S(o)?a+=" "+o:a+=" "+u(o);return a},t.deprecate=function(e,r){if(void 0!==n.default&&!0===n.default.noDeprecation)return e;if(void 0===n.default)return function(){return t.deprecate(e,r).apply(this,arguments)};var i=!1;return function(){if(!i){if(n.default.throwDeprecation)throw Error(r);n.default.traceDeprecation?console.trace(r):console.error(r),i=!0}return e.apply(this,arguments)}};var a={},o=/^$/;if(n.default.env.NODE_DEBUG){var l=n.default.env.NODE_DEBUG;o=RegExp("^"+(l=l.replace(/[|\\{}()[\]^$+?.]/g,"\\$&").replace(/\*/g,".*").replace(/,/g,"$|^").toUpperCase())+"$","i")}function u(e,r){var i={seen:[],stylize:d};return arguments.length>=3&&(i.depth=arguments[2]),arguments.length>=4&&(i.colors=arguments[3]),m(r)?i.showHidden=r:r&&t._extend(i,r),_(i.showHidden)&&(i.showHidden=!1),_(i.depth)&&(i.depth=2),_(i.colors)&&(i.colors=!1),_(i.customInspect)&&(i.customInspect=!0),i.colors&&(i.stylize=c),h(i,e,i.depth)}function c(e,t){var r=u.styles[t];return r?"\x1b["+u.colors[r][0]+"m"+e+"\x1b["+u.colors[r][1]+"m":e}function d(e,t){return e}function h(e,r,i){if(e.customInspect&&r&&w(r.inspect)&&r.inspect!==t.inspect&&!(r.constructor&&r.constructor.prototype===r)){var n,s,a,o,l,u,c=r.inspect(i,e);
1return b(c)||(c=h(e,c,i)),c}var d=function(e,t){if(_(t))return e.stylize("undefined","undefined");if(b(t)){var r="'"+JSON.stringify(t).replace(/^"|"$/g,"").replace(/'/g,"\\'").replace(/\\"/g,'"')+"'";return e.stylize(r,"string")}return v(t)?e.stylize(""+t,"number"):m(t)?e.stylize(""+t,"boolean"):y(t)?e.stylize("null","null"):void 0}(e,r);if(d)return d;var S=Object.keys(r),A=(l={},S.forEach(function(e,t){l[e]=!0}),l);if(e.showHidden&&(S=Object.getOwnPropertyNames(r)),T(r)&&(S.indexOf("message")>=0||S.indexOf("description")>=0))return f(r);if(0===S.length){if(w(r)){var R=r.name?": "+r.name:"";return e.stylize("[Function"+R+"]","special")}if(E(r))return e.stylize(RegExp.prototype.toString.call(r),"regexp");if(x(r))return e.stylize(Date.prototype.toString.call(r),"date");if(T(r))return f(r)}var I="",C=!1,D=["{","}"];if(g(r)&&(C=!0,D=["[","]"]),w(r)&&(I=" [Function"+(r.name?": "+r.name:"")+"]"),E(r)&&(I=" "+RegExp.prototype.toString.call(r)),x(r)&&(I=" "+Date.prototype.toUTCString.call(r)),T(r)&&(I=" "+f(r)),0===S.length&&(!C||0==r.length))return D[0]+I+D[1];if(i<0)if(E(r))return e.stylize(RegExp.prototype.toString.call(r),"regexp");else return e.stylize("[Object]","special");return e.seen.push(r),u=C?function(e,t,r,i,n){for(var s=[],a=0,o=t.length;a<o;++a)k(t,String(a))?s.push(p(e,t,r,i,String(a),!0)):s.push("");return n.forEach(function(n){n.match(/^\d+$/)||s.push(p(e,t,r,i,n,!0))}),s}(e,r,i,A,S):S.map(function(t){return p(e,r,i,A,t,C)}),e.seen.pop(),n=u,s=I,a=D,o=0,n.reduce(function(e,t){return o++,t.indexOf("\n")>=0&&o++,e+t.replace(/\u001b\[\d\d?m/g,"").length+1},0)>60?a[0]+(""===s?"":s+"\n ")+" "+n.join(",\n ")+" "+a[1]:a[0]+s+" "+n.join(", ")+" "+a[1]}function f(e){return"["+Error.prototype.toString.call(e)+"]"}function p(e,t,r,i,n,s){var a,o,l;if((l=Object.getOwnPropertyDescriptor(t,n)||{value:t[n]}).get?o=l.set?e.stylize("[Getter/Setter]","special"):e.stylize("[Getter]","special"):l.set&&(o=e.stylize("[Setter]","special")),k(i,n)||(a="["+n+"]"),!o&&(0>e.seen.indexOf(l.value)?(o=y(r)?h(e,l.value,null):h(e,l.value,r-1)).indexOf("\n")>-1&&(o=s?o.split("\n").map(function(e){return" "+e}).join("\n").substr(2):"\n"+o.split("\n").map(function(e){return" "+e}).join("\n")):o=e.stylize("[Circular]","special")),_(a)){if(s&&n.match(/^\d+$/))return o;(a=JSON.stringify(""+n)).match(/^"([a-zA-Z_][a-zA-Z_0-9]*)"$/)?(a=a.substr(1,a.length-2),a=e.stylize(a,"name")):(a=a.replace(/'/g,"\\'").replace(/\\"/g,'"').replace(/(^"|"$)/g,"'"),a=e.stylize(a,"string"))}return a+": "+o}function g(e){return Array.isArray(e)}function m(e){return"boolean"==typeof e}function y(e){return null===e}function v(e){return"number"==typeof e}function b(e){return"string"==typeof e}function _(e){return void 0===e}function E(e){return S(e)&&"[object RegExp]"===A(e)}function S(e){return"object"==typeof e&&null!==e}function x(e){return S(e)&&"[object Date]"===A(e)}function T(e){return S(e)&&("[object Error]"===A(e)||e instanceof Error)}function w(e){return"function"==typeof e}function A(e){return Object.prototype.toString.call(e)}function R(e){return e<10?"0"+e.toString(10):e.toString(10)}t.debuglog=function(e){if(!a[e=e.toUpperCase()])if(o.test(e)){var r=n.default.pid;a[e]=function(){var i=t.format.apply(t,arguments);console.error("%s %d: %s",e,r,i)}}else a[e]=function(){};return a[e]},t.inspect=u,u.colors={bold:[1,22],italic:[3,23],underline:[4,24],inverse:[7,27],white:[37,39],grey:[90,39],black:[30,39],blue:[34,39],cyan:[36,39],green:[32,39],magenta:[35,39],red:[31,39],yellow:[33,39]},u.styles={special:"cyan",number:"yellow",boolean:"yellow",undefined:"grey",null:"bold",string:"green",date:"magenta",regexp:"red"},t.types=r(5584),t.isArray=g,t.isBoolean=m,t.isNull=y,t.isNullOrUndefined=function(e){return null==e},t.isNumber=v,t.isString=b,t.isSymbol=function(e){return"symbol"==typeof e},t.isUndefined=_,t.isRegExp=E,t.types.isRegExp=E,t.isObject=S,t.isDate=x,t.types.isDate=x,t.isError=T,t.types.isNativeError=T,t.isFunction=w,t.isPrimitive=function(e){return null===e||"boolean"==typeof e||"number"==typeof e||"string"==typeof e||"symbol"==typeof e||void 0===e},t.isBuffer=r(2369);var I=["Jan","Feb","Mar","Apr","May","Jun","Jul","Aug","Sep","Oct","Nov","Dec"];function k(e,t){return Object.prototype.hasOwnProperty.call(e,t)}t.log=function(){var e,r;console.log("%s - %s",(r=[R((e=new Date).getHours()),R(e.getMinutes()),R(e.getSeconds())].join(":"),[e.getDate(),I[e.getMonth()],r].join(" ")),t.format.apply(t,arguments))},t.inherits=r(3782),t._extend=function(e,t){if(!t||!S(t))return e;for(var r=Object.keys(t),i=r.length;i--;)e[r[i]]=t[r[i]];return e};var C="u">typeof Symbol?Symbol("util.promisify.custom"):void 0;function D(e,t){if(!e){var r=Error("Promise was rejected with a falsy value");r.reason=e,e=r}return t(e)}t.promisify=function(e){if("function"!=typeof e)throw TypeError('The "original" argument must be of type Function');if(C&&e[C]){var t=e[C];if("function"!=typeof t)throw TypeError('The "util.promisify.custom" argument must be of type Function');return Object.defineProperty(t,C,{value:t,enumerable:!1,writable:!1,
1configurable:!0}),t}function t(){for(var t,r,i=new Promise(function(e,i){t=e,r=i}),n=[],s=0;s<arguments.length;s++)n.push(arguments[s]);n.push(function(e,i){e?r(e):t(i)});try{e.apply(this,n)}catch(e){r(e)}return i}return Object.setPrototypeOf(t,Object.getPrototypeOf(e)),C&&Object.defineProperty(t,C,{value:t,enumerable:!1,writable:!1,configurable:!0}),Object.defineProperties(t,i(e))},t.promisify.custom=C,t.callbackify=function(e){if("function"!=typeof e)throw TypeError('The "original" argument must be of type Function');function t(){for(var t=[],r=0;r<arguments.length;r++)t.push(arguments[r]);var i=t.pop();if("function"!=typeof i)throw TypeError("The last argument must be of type Function");var s=this,a=function(){return i.apply(s,arguments)};e.apply(this,t).then(function(e){n.default.nextTick(a.bind(null,null,e))},function(e){n.default.nextTick(D.bind(null,e,a))})}return Object.setPrototypeOf(t,Object.getPrototypeOf(e)),Object.defineProperties(t,i(e)),t}},1490:function(t,r,i){"use strict";var n=i(6144),s=i(1349),a=i(516),o=a("Object.prototype.toString"),l=i(9942)()&&"symbol"==typeof Symbol.toStringTag,u=s(),c=a("String.prototype.slice"),d={},h=i(2154),f=Object.getPrototypeOf;l&&h&&f&&n(u,function(t){if("function"==typeof e.g[t]){var r=new e.g[t];if(!(Symbol.toStringTag in r))throw EvalError("this engine has support for Symbol.toStringTag, but "+t+" does not have the property! Please report this.");var i=f(r),n=h(i,Symbol.toStringTag);n||(n=h(f(i),Symbol.toStringTag)),d[t]=n.get}});var p=function(e){var t=!1;return n(d,function(r,i){if(!t)try{var n=r.call(e);n===i&&(t=n)}catch(e){}}),t},g=i(994);t.exports=function(e){return!!g(e)&&(l?p(e):c(o(e),8,-1))}},1349:function(t,r,i){"use strict";var n=i(8992);t.exports=function(){return n(["BigInt64Array","BigUint64Array","Float32Array","Float64Array","Int16Array","Int32Array","Int8Array","Uint16Array","Uint32Array","Uint8Array","Uint8ClampedArray"],function(t){return"function"==typeof e.g[t]})}},2154:function(e,t,r){"use strict";e.exports=r(3990)}},a={};function o(e){var t=a[e];if(void 0!==t)return t.exports;var r=a[e]={exports:{}},i=!0;try{s[e](r,r.exports,o),i=!1}finally{i&&delete a[e]}return r.exports}o.ab="/ROOT/node_modules/next/dist/compiled/util/",t.exports=o(8177)},612569,(e,t,r)=>{var i=e.i(247167),n={782:function(e){"function"==typeof Object.create?e.exports=function(e,t){t&&(e.super_=t,e.prototype=Object.create(t.prototype,{constructor:{value:e,enumerable:!1,writable:!0,configurable:!0}}))}:e.exports=function(e,t){if(t){e.super_=t;var r=function(){};r.prototype=t.prototype,e.prototype=new r,e.prototype.constructor=e}}},646:function(e){"use strict";let t={};function r(e,r,i){i||(i=Error);class n extends i{constructor(e,t,i){super(function(e,t,i){return"string"==typeof r?r:r(e,t,i)}(e,t,i))}}n.prototype.name=i.name,n.prototype.code=e,t[e]=n}function i(e,t){if(!Array.isArray(e))return`of ${t} ${String(e)}`;{let r=e.length;return(e=e.map(e=>String(e)),r>2)?`one of ${t} ${e.slice(0,r-1).join(", ")}, or `+e[r-1]:2===r?`one of ${t} ${e[0]} or ${e[1]}`:`of ${t} ${e[0]}`}}r("ERR_INVALID_OPT_VALUE",function(e,t){return'The value "'+t+'" is invalid for option "'+e+'"'},TypeError),r("ERR_INVALID_ARG_TYPE",function(e,t,r){var n,s,a,o;let l,u;if("string"==typeof t&&(n="not ",t.substr(0,n.length)===n)?(l="must not be",t=t.replace(/^not /,"")):l="must be",s=" argument",(void 0===a||a>e.length)&&(a=e.length),e.substring(a-s.length,a)===s)u=`The ${e} ${l} ${i(t,"type")}`;else{let r=("number"!=typeof o&&(o=0),o+1>e.length||-1===e.indexOf(".",o))?"argument":"property";u=`The "${e}" ${r} ${l} ${i(t,"type")}`}return u+`. Received type ${typeof r}`},TypeError),r("ERR_STREAM_PUSH_AFTER_EOF","stream.push() after EOF"),r("ERR_METHOD_NOT_IMPLEMENTED",function(e){return"The "+e+" method is not implemented"}),r("ERR_STREAM_PREMATURE_CLOSE","Premature close"),r("ERR_STREAM_DESTROYED",function(e){return"Cannot call "+e+" after a stream was destroyed"}),r("ERR_MULTIPLE_CALLBACK","Callback called multiple times"),r("ERR_STREAM_CANNOT_PIPE","Cannot pipe, not readable"),r("ERR_STREAM_WRITE_AFTER_END","write after end"),r("ERR_STREAM_NULL_VALUES","May not write null values to stream",TypeError),r("ERR_UNKNOWN_ENCODING",function(e){return"Unknown encoding: "+e},TypeError),r("ERR_STREAM_UNSHIFT_AFTER_END_EVENT","stream.unshift() after end event"),e.exports.q=t},403:function(e,t,r){"use strict";var n=Object.keys||function(e){var t=[];for(var r in e)t.push(r);return t};e.exports=c;var s=r(709),a=r(337);r(782)(c,s);for(var o=n(a.prototype),l=0;l<o.length;l++){var u=o[l];c.prototype[u]||(c.prototype[u]=a.prototype[u])}function c(e){if(!(this instanceof c))return new c(e);s.call(this,e),a.call(this,e),this.allowHalfOpen=!0,e&&(!1===e.readable&&(this.readable=!1),!1===e.writable&&(this.writable=!1),!1===e.allowHalfOpen&&(this.allowHalfOpen=!1,this.once("end",d)))}function d(){this._writableState.ended||i.default.nextTick(h,this)}function h(e){e.end()}Object.defineProperty(c.prototype,"writableHighWaterMark",{enumerable:!1,get:function(){return this._writableState.highWaterMark}}),Object.defineProperty(c.prototype,"writableBuffer",{enumerable:!1,get:function(){return this._writableState&&this._writableState.getBuffer()}}),Object.defineProperty(c.prototype,"writableLength",{enumerable:!1,get:function(){return this._writableState.length}}),Object.defineProperty(c.prototype,"destroyed",{enumerable:!1,get:function(){return void 0!==this._readableState&&void 0!==this._writableState&&this._readableState.destroyed&&this._writableState.destroyed},set:function(e){void 0!==this._readableState&&void 0!==this._writableState&&(this._readableState.destroyed=e,this._writableState.destroyed=e)}})},889:function(e,t,r){"use strict";e.exports=n;var i=r(170);function n(e){if(!(this instanceof n))return new n(e);
vendor: 5,745 bytes, line 1
1i.call(this,e)}r(782)(n,i),n.prototype._transform=function(e,t,r){r(null,e)}},709:function(t,r,n){"use strict";t.exports=A,A.ReadableState=w,n(361).EventEmitter;var s,a,o,l,u,c=function(e,t){return e.listeners(t).length},d=n(678),h=n(300).Buffer,f=e.g.Uint8Array||function(){},p=n(837);a=p&&p.debuglog?p.debuglog("stream"):function(){};var g=n(379),m=n(25),y=n(776).getHighWaterMark,v=n(646).q,b=v.ERR_INVALID_ARG_TYPE,_=v.ERR_STREAM_PUSH_AFTER_EOF,E=v.ERR_METHOD_NOT_IMPLEMENTED,S=v.ERR_STREAM_UNSHIFT_AFTER_END_EVENT;n(782)(A,d);var x=m.errorOrDestroy,T=["error","close","destroy","pause","resume"];function w(e,t,r){s=s||n(403),e=e||{},"boolean"!=typeof r&&(r=t instanceof s),this.objectMode=!!e.objectMode,r&&(this.objectMode=this.objectMode||!!e.readableObjectMode),this.highWaterMark=y(this,e,"readableHighWaterMark",r),this.buffer=new g,this.length=0,this.pipes=null,this.pipesCount=0,this.flowing=null,this.ended=!1,this.endEmitted=!1,this.reading=!1,this.sync=!0,this.needReadable=!1,this.emittedReadable=!1,this.readableListening=!1,this.resumeScheduled=!1,this.paused=!0,this.emitClose=!1!==e.emitClose,this.autoDestroy=!!e.autoDestroy,this.destroyed=!1,this.defaultEncoding=e.defaultEncoding||"utf8",this.awaitDrain=0,this.readingMore=!1,this.decoder=null,this.encoding=null,e.encoding&&(o||(o=n(704).s),this.decoder=new o(e.encoding),this.encoding=e.encoding)}function A(e){if(s=s||n(403),!(this instanceof A))return new A(e);var t=this instanceof s;this._readableState=new w(e,this,t),this.readable=!0,e&&("function"==typeof e.read&&(this._read=e.read),"function"==typeof e.destroy&&(this._destroy=e.destroy)),d.call(this)}function R(e,t,r,i,n){a("readableAddChunk",t);var s,o,l=e._readableState;if(null===t)l.reading=!1,function(e,t){if(a("onEofChunk"),!t.ended){if(t.decoder){var r=t.decoder.end();r&&r.length&&(t.buffer.push(r),t.length+=t.objectMode?1:r.length)}t.ended=!0,t.sync?C(e):(t.needReadable=!1,t.emittedReadable||(t.emittedReadable=!0,D(e)))}}(e,l);else if(n||(o=function(e,t){var r;return h.isBuffer(t)||t instanceof f||"string"==typeof t||void 0===t||e.objectMode||(r=new b("chunk",["string","Buffer","Uint8Array"],t)),r}(l,t)),o)x(e,o);else if(l.objectMode||t&&t.length>0)if("string"==typeof t||l.objectMode||Object.getPrototypeOf(t)===h.prototype||(s=t,t=h.from(s)),i)l.endEmitted?x(e,new S):I(e,l,t,!0);else if(l.ended)x(e,new _);else{if(l.destroyed)return!1;l.reading=!1,l.decoder&&!r?(t=l.decoder.write(t),l.objectMode||0!==t.length?I(e,l,t,!1):L(e,l)):I(e,l,t,!1)}else i||(l.reading=!1,L(e,l));return!l.ended&&(l.length<l.highWaterMark||0===l.length)}function I(e,t,r,i){t.flowing&&0===t.length&&!t.sync?(t.awaitDrain=0,e.emit("data",r)):(t.length+=t.objectMode?1:r.length,i?t.buffer.unshift(r):t.buffer.push(r),t.needReadable&&C(e)),L(e,t)}function k(e,t){var r;if(e<=0||0===t.length&&t.ended)return 0;if(t.objectMode)return 1;if(e!=e)if(t.flowing&&t.length)return t.buffer.head.data.length;else return t.length;return(e>t.highWaterMark&&((r=e)>=0x40000000?r=0x40000000:(r--,r|=r>>>1,r|=r>>>2,r|=r>>>4,r|=r>>>8,r|=r>>>16,r++),t.highWaterMark=r),e<=t.length)?e:t.ended?t.length:(t.needReadable=!0,0)}function C(e){var t=e._readableState;a("emitReadable",t.needReadable,t.emittedReadable),t.needReadable=!1,t.emittedReadable||(a("emitReadable",t.flowing),t.emittedReadable=!0,i.default.nextTick(D,e))}function D(e){var t=e._readableState;a("emitReadable_",t.destroyed,t.length,t.ended),!t.destroyed&&(t.length||t.ended)&&(e.emit("readable"),t.emittedReadable=!1),t.needReadable=!t.flowing&&!t.ended&&t.length<=t.highWaterMark,M(e)}function L(e,t){t.readingMore||(t.readingMore=!0,i.default.nextTick(O,e,t))}function O(e,t){for(;!t.reading&&!t.ended&&(t.length<t.highWaterMark||t.flowing&&0===t.length);){var r=t.length;if(a("maybeReadMore read 0"),e.read(0),r===t.length)break}t.readingMore=!1}function P(e){var t=e._readableState;t.readableListening=e.listenerCount("readable")>0,t.resumeScheduled&&!t.paused?t.flowing=!0:e.listenerCount("data")>0&&e.resume()}function F(e){a("readable nexttick read 0"),e.read(0)}function N(e,t){a("resume",t.reading),t.reading||e.read(0),t.resumeScheduled=!1,e.emit("resume"),M(e),t.flowing&&!t.reading&&e.read(0)}function M(e){var t=e._readableState;for(a("flow",t.flowing);t.flowing&&null!==e.read(););}function j(e,t){var r;return 0===t.length?null:(t.objectMode?r=t.buffer.shift():!e||e>=t.length?(r=t.decoder?t.buffer.join(""):1===t.buffer.length?t.buffer.first():t.buffer.concat(t.length),t.buffer.clear()):r=t.buffer.consume(e,t.decoder),r)}function $(e){var t=e._readableState;a("endReadable",t.endEmitted),t.endEmitted||(t.ended=!0,i.default.nextTick(U,t,e))}function U(e,t){if(a("endReadableNT",e.endEmitted,e.length),!e.endEmitted&&0===e.length&&(e.endEmitted=!0,t.readable=!1,t.emit("end"),e.autoDestroy)){var r=t._writableState;(!r||r.autoDestroy&&r.finished)&&t.destroy()}}function B(e,t){for(var r=0,i=e.length;r<i;r++)if(e[r]===t)return r;return -1}Object.defineProperty(A.prototype,"destroyed",{enumerable:!1,get:function(){return void 0!==this._readableState&&this._readableState.destroyed},set:function(e){this._readableState&&(this._readableState.destroyed=e)}}),A.prototype.destroy=m.destroy,A.prototype._undestroy=m.undestroy,A.prototype._destroy=function(e,t){t(e)},A.prototype.push=function(e,t){var r,i=this._readableState;return i.objectMode?r=!0:"string"==typeof e&&((t=t||i.defaultEncoding)!==i.encoding&&(e=h.from(e,t),t=""),r=!0),R(this,e,t,!1,r)},A.prototype.unshift=function(e){return R(this,e,null,!0,!1)},A.prototype.isPaused=function(){return!1===this._readableState.flowing},A.prototype.setEncoding=function(e){o||(o=n(704).s);var t=new o(e);this._readableState.decoder=t,this._readableState.encoding=this._readableState.decoder.encoding;
vendor: 2,646 bytes, line 1
1for(var r=this._readableState.buffer.head,i="";null!==r;)i+=t.write(r.data),r=r.next;return this._readableState.buffer.clear(),""!==i&&this._readableState.buffer.push(i),this._readableState.length=i.length,this},A.prototype.read=function(e){a("read",e),e=parseInt(e,10);var t,r=this._readableState,i=e;if(0!==e&&(r.emittedReadable=!1),0===e&&r.needReadable&&((0!==r.highWaterMark?r.length>=r.highWaterMark:r.length>0)||r.ended))return a("read: emitReadable",r.length,r.ended),0===r.length&&r.ended?$(this):C(this),null;if(0===(e=k(e,r))&&r.ended)return 0===r.length&&$(this),null;var n=r.needReadable;return a("need readable",n),(0===r.length||r.length-e<r.highWaterMark)&&a("length less than watermark",n=!0),r.ended||r.reading?a("reading or ended",n=!1):n&&(a("do read"),r.reading=!0,r.sync=!0,0===r.length&&(r.needReadable=!0),this._read(r.highWaterMark),r.sync=!1,r.reading||(e=k(i,r))),null===(t=e>0?j(e,r):null)?(r.needReadable=r.length<=r.highWaterMark,e=0):(r.length-=e,r.awaitDrain=0),0===r.length&&(r.ended||(r.needReadable=!0),i!==e&&r.ended&&$(this)),null!==t&&this.emit("data",t),t},A.prototype._read=function(e){x(this,new E("_read()"))},A.prototype.pipe=function(e,t){var r,n=this,s=this._readableState;switch(s.pipesCount){case 0:s.pipes=e;break;case 1:s.pipes=[s.pipes,e];break;default:s.pipes.push(e)}s.pipesCount+=1,a("pipe count=%d opts=%j",s.pipesCount,t);var o=t&&!1===t.end||e===i.default.stdout||e===i.default.stderr?m:l;function l(){a("onend"),e.end()}s.endEmitted?i.default.nextTick(o):n.once("end",o),e.on("unpipe",function t(r,i){a("onunpipe"),r===n&&i&&!1===i.hasUnpiped&&(i.hasUnpiped=!0,a("cleanup"),e.removeListener("close",p),e.removeListener("finish",g),e.removeListener("drain",u),e.removeListener("error",f),e.removeListener("unpipe",t),n.removeListener("end",l),n.removeListener("end",m),n.removeListener("data",h),d=!0,s.awaitDrain&&(!e._writableState||e._writableState.needDrain)&&u())});var u=(r=n,function(){var e=r._readableState;a("pipeOnDrain",e.awaitDrain),e.awaitDrain&&e.awaitDrain--,0===e.awaitDrain&&c(r,"data")&&(e.flowing=!0,M(r))});e.on("drain",u);var d=!1;function h(t){a("ondata");var r=e.write(t);a("dest.write",r),!1===r&&((1===s.pipesCount&&s.pipes===e||s.pipesCount>1&&-1!==B(s.pipes,e))&&!d&&(a("false write response, pause",s.awaitDrain),s.awaitDrain++),n.pause())}function f(t){a("onerror",t),m(),e.removeListener("error",f),0===c(e,"error")&&x(e,t)}function p(){e.removeListener("finish",g),m()}function g(){a("onfinish"),e.removeListener("close",p),m()}function m(){a("unpipe"),n.unpipe(e)}return n.on("data",h),!function(e,t,r){if("function"==typeof e.prependListener)return e.prepe
vendor: 4,540 bytes, line 1
1ndListener(t,r);e._events&&e._events[t]?Array.isArray(e._events[t])?e._events[t].unshift(r):e._events[t]=[r,e._events[t]]:e.on(t,r)}(e,"error",f),e.once("close",p),e.once("finish",g),e.emit("pipe",n),s.flowing||(a("pipe resume"),n.resume()),e},A.prototype.unpipe=function(e){var t=this._readableState,r={hasUnpiped:!1};if(0===t.pipesCount)return this;if(1===t.pipesCount)return e&&e!==t.pipes||(e||(e=t.pipes),t.pipes=null,t.pipesCount=0,t.flowing=!1,e&&e.emit("unpipe",this,r)),this;if(!e){var i=t.pipes,n=t.pipesCount;t.pipes=null,t.pipesCount=0,t.flowing=!1;for(var s=0;s<n;s++)i[s].emit("unpipe",this,{hasUnpiped:!1});return this}var a=B(t.pipes,e);return -1===a||(t.pipes.splice(a,1),t.pipesCount-=1,1===t.pipesCount&&(t.pipes=t.pipes[0]),e.emit("unpipe",this,r)),this},A.prototype.on=function(e,t){var r=d.prototype.on.call(this,e,t),n=this._readableState;return"data"===e?(n.readableListening=this.listenerCount("readable")>0,!1!==n.flowing&&this.resume()):"readable"!==e||n.endEmitted||n.readableListening||(n.readableListening=n.needReadable=!0,n.flowing=!1,n.emittedReadable=!1,a("on readable",n.length,n.reading),n.length?C(this):n.reading||i.default.nextTick(F,this)),r},A.prototype.addListener=A.prototype.on,A.prototype.removeListener=function(e,t){var r=d.prototype.removeListener.call(this,e,t);return"readable"===e&&i.default.nextTick(P,this),r},A.prototype.removeAllListeners=function(e){var t=d.prototype.removeAllListeners.apply(this,arguments);return("readable"===e||void 0===e)&&i.default.nextTick(P,this),t},A.prototype.resume=function(){var e,t,r=this._readableState;return r.flowing||(a("resume"),r.flowing=!r.readableListening,e=this,(t=r).resumeScheduled||(t.resumeScheduled=!0,i.default.nextTick(N,e,t))),r.paused=!1,this},A.prototype.pause=function(){return a("call pause flowing=%j",this._readableState.flowing),!1!==this._readableState.flowing&&(a("pause"),this._readableState.flowing=!1,this.emit("pause")),this._readableState.paused=!0,this},A.prototype.wrap=function(e){var t=this,r=this._readableState,i=!1;for(var n in e.on("end",function(){if(a("wrapped end"),r.decoder&&!r.ended){var e=r.decoder.end();e&&e.length&&t.push(e)}t.push(null)}),e.on("data",function(n){a("wrapped data"),r.decoder&&(n=r.decoder.write(n)),r.objectMode&&null==n||(r.objectMode||n&&n.length)&&(t.push(n)||(i=!0,e.pause()))}),e)void 0===this[n]&&"function"==typeof e[n]&&(this[n]=function(t){return function(){return e[t].apply(e,arguments)}}(n));for(var s=0;s<T.length;s++)e.on(T[s],this.emit.bind(this,T[s]));return this._read=function(t){a("wrapped _read",t),i&&(i=!1,e.resume())},this},"function"==typeof Symbol&&(A.prototype[Symbol.asyncIterator]=function(){return void 0===l&&(l=n(871)),l(this)}),Object.defineProperty(A.prototype,"readableHighWaterMark",{enumerable:!1,get:function(){return this._readableState.highWaterMark}}),Object.defineProperty(A.prototype,"readableBuffer",{enumerable:!1,get:function(){return this._readableState&&this._readableState.buffer}}),Object.defineProperty(A.prototype,"readableFlowing",{enumerable:!1,get:function(){return this._readableState.flowing},set:function(e){this._readableState&&(this._readableState.flowing=e)}}),A._fromList=j,Object.defineProperty(A.prototype,"readableLength",{enumerable:!1,get:function(){return this._readableState.length}}),"function"==typeof Symbol&&(A.from=function(e,t){return void 0===u&&(u=n(727)),u(A,e,t)})},170:function(e,t,r){"use strict";e.exports=c;var i=r(646).q,n=i.ERR_METHOD_NOT_IMPLEMENTED,s=i.ERR_MULTIPLE_CALLBACK,a=i.ERR_TRANSFORM_ALREADY_TRANSFORMING,o=i.ERR_TRANSFORM_WITH_LENGTH_0,l=r(403);function u(e,t){var r=this._transformState;r.transforming=!1;var i=r.writecb;if(null===i)return this.emit("error",new s);r.writechunk=null,r.writecb=null,null!=t&&this.push(t),i(e);var n=this._readableState;n.reading=!1,(n.needReadable||n.length<n.highWaterMark)&&this._read(n.highWaterMark)}function c(e){if(!(this instanceof c))return new c(e);l.call(this,e),this._transformState={afterTransform:u.bind(this),needTransform:!1,transforming:!1,writecb:null,writechunk:null,writeencoding:null},this._readableState.needReadable=!0,this._readableState.sync=!1,e&&("function"==typeof e.transform&&(this._transform=e.transform),"function"==typeof e.flush&&(this._flush=e.flush)),this.on("prefinish",d)}function d(){var e=this;"function"!=typeof this._flush||this._readableState.destroyed?h(this,null,null):this._flush(function(t,r){h(e,t,r)})}function h(e,t,r){if(t)return e.emit("error",t);if(null!=r&&e.push(r),e._writableState.length)throw new o;
vendor: 8,742 bytes, line 1
1if(e._transformState.transforming)throw new a;return e.push(null)}r(782)(c,l),c.prototype.push=function(e,t){return this._transformState.needTransform=!1,l.prototype.push.call(this,e,t)},c.prototype._transform=function(e,t,r){r(new n("_transform()"))},c.prototype._write=function(e,t,r){var i=this._transformState;if(i.writecb=r,i.writechunk=e,i.writeencoding=t,!i.transforming){var n=this._readableState;(i.needTransform||n.needReadable||n.length<n.highWaterMark)&&this._read(n.highWaterMark)}},c.prototype._read=function(e){var t=this._transformState;null===t.writechunk||t.transforming?t.needTransform=!0:(t.transforming=!0,this._transform(t.writechunk,t.writeencoding,t.afterTransform))},c.prototype._destroy=function(e,t){l.prototype._destroy.call(this,e,function(e){t(e)})}},337:function(t,r,n){"use strict";function s(e){var t=this;this.next=null,this.entry=null,this.finish=function(){var r=t,i=e,n=r.entry;for(r.entry=null;n;){var s=n.callback;i.pendingcb--,s(void 0),n=n.next}i.corkedRequestsFree.next=r}}t.exports=A,A.WritableState=w;var a,o,l={deprecate:n(769)},u=n(678),c=n(300).Buffer,d=e.g.Uint8Array||function(){},h=n(25),f=n(776).getHighWaterMark,p=n(646).q,g=p.ERR_INVALID_ARG_TYPE,m=p.ERR_METHOD_NOT_IMPLEMENTED,y=p.ERR_MULTIPLE_CALLBACK,v=p.ERR_STREAM_CANNOT_PIPE,b=p.ERR_STREAM_DESTROYED,_=p.ERR_STREAM_NULL_VALUES,E=p.ERR_STREAM_WRITE_AFTER_END,S=p.ERR_UNKNOWN_ENCODING,x=h.errorOrDestroy;function T(){}function w(e,t,r){a=a||n(403),e=e||{},"boolean"!=typeof r&&(r=t instanceof a),this.objectMode=!!e.objectMode,r&&(this.objectMode=this.objectMode||!!e.writableObjectMode),this.highWaterMark=f(this,e,"writableHighWaterMark",r),this.finalCalled=!1,this.needDrain=!1,this.ending=!1,this.ended=!1,this.finished=!1,this.destroyed=!1;var o=!1===e.decodeStrings;this.decodeStrings=!o,this.defaultEncoding=e.defaultEncoding||"utf8",this.length=0,this.writing=!1,this.corked=0,this.sync=!0,this.bufferProcessing=!1,this.onwrite=function(e){!function(e,t){var r=e._writableState,n=r.sync,s=r.writecb;if("function"!=typeof s)throw new y;if(r.writing=!1,r.writecb=null,r.length-=r.writelen,r.writelen=0,t)--r.pendingcb,n?(i.default.nextTick(s,t),i.default.nextTick(L,e,r),e._writableState.errorEmitted=!0,x(e,t)):(s(t),e._writableState.errorEmitted=!0,x(e,t),L(e,r));else{var a=C(r)||e.destroyed;a||r.corked||r.bufferProcessing||!r.bufferedRequest||k(e,r),n?i.default.nextTick(I,e,r,a,s):I(e,r,a,s)}}(t,e)},this.writecb=null,this.writelen=0,this.bufferedRequest=null,this.lastBufferedRequest=null,this.pendingcb=0,this.prefinished=!1,this.errorEmitted=!1,this.emitClose=!1!==e.emitClose,this.autoDestroy=!!e.autoDestroy,this.bufferedRequestCount=0,this.corkedRequestsFree=new s(this)}n(782)(A,u),w.prototype.getBuffer=function(){for(var e=this.bufferedRequest,t=[];e;)t.push(e),e=e.next;return t};try{Object.defineProperty(w.prototype,"buffer",{get:l.deprecate(function(){return this.getBuffer()},"_writableState.buffer is deprecated. Use _writableState.getBuffer instead.","DEP0003")})}catch(e){}function A(e){var t=this instanceof(a=a||n(403));if(!t&&!o.call(A,this))return new A(e);this._writableState=new w(e,this,t),this.writable=!0,e&&("function"==typeof e.write&&(this._write=e.write),"function"==typeof e.writev&&(this._writev=e.writev),"function"==typeof e.destroy&&(this._destroy=e.destroy),"function"==typeof e.final&&(this._final=e.final)),u.call(this)}function R(e,t,r,i,n,s,a){t.writelen=i,t.writecb=a,t.writing=!0,t.sync=!0,t.destroyed?t.onwrite(new b("write")):r?e._writev(n,t.onwrite):e._write(n,s,t.onwrite),t.sync=!1}function I(e,t,r,i){var n,s;r||(n=e,0===(s=t).length&&s.needDrain&&(s.needDrain=!1,n.emit("drain"))),t.pendingcb--,i(),L(e,t)}function k(e,t){t.bufferProcessing=!0;var r=t.bufferedRequest;if(e._writev&&r&&r.next){var i=Array(t.bufferedRequestCount),n=t.corkedRequestsFree;n.entry=r;for(var a=0,o=!0;r;)i[a]=r,r.isBuf||(o=!1),r=r.next,a+=1;i.allBuffers=o,R(e,t,!0,t.length,i,"",n.finish),t.pendingcb++,t.lastBufferedRequest=null,n.next?(t.corkedRequestsFree=n.next,n.next=null):t.corkedRequestsFree=new s(t),t.bufferedRequestCount=0}else{for(;r;){var l=r.chunk,u=r.encoding,c=r.callback,d=t.objectMode?1:l.length;if(R(e,t,!1,d,l,u,c),r=r.next,t.bufferedRequestCount--,t.writing)break}null===r&&(t.lastBufferedRequest=null)}t.bufferedRequest=r,t.bufferProcessing=!1}function C(e){return e.ending&&0===e.length&&null===e.bufferedRequest&&!e.finished&&!e.writing}function D(e,t){e._final(function(r){t.pendingcb--,r&&x(e,r),t.prefinished=!0,e.emit("prefinish"),L(e,t)})}function L(e,t){var r=C(t);if(r&&(t.prefinished||t.finalCalled||("function"!=typeof e._final||t.destroyed?(t.prefinished=!0,e.emit("prefinish")):(t.pendingcb++,t.finalCalled=!0,i.default.nextTick(D,e,t))),0===t.pendingcb&&(t.finished=!0,e.emit("finish"),t.autoDestroy))){var n=e._readableState;(!n||n.autoDestroy&&n.endEmitted)&&e.destroy()}return r}"function"==typeof Symbol&&Symbol.hasInstance&&"function"==typeof Function.prototype[Symbol.hasInstance]?(o=Function.prototype[Symbol.hasInstance],Object.defineProperty(A,Symbol.hasInstance,{value:function(e){return!!o.call(this,e)||this===A&&e&&e._writableState instanceof w}})):o=function(e){return e instanceof this},A.prototype.pipe=function(){x(this,new v)},A.prototype.write=function(e,t,r){var n,s,a,o,l,u,h,f=this._writableState,p=!1,m=!f.objectMode&&(n=e,c.isBuffer(n)||n instanceof d);return(m&&!c.isBuffer(e)&&(s=e,e=c.from(s)),"function"==typeof t&&(r=t,t=null),m?t="buffer":t||(t=f.defaultEncoding),"function"!=typeof r&&(r=T),f.ending)?(a=r,x(this,o=new E),i.default.nextTick(a,o)):(m||(l=e,u=r,null===l?h=new _:"string"==typeof l||f.objectMode||(h=new g("chunk",["string","Buffer"],l)),!h||(x(this,h),i.default.nextTick(u,h),0)))&&(f.pendingcb++,p=function(e,t,r,i,n,s){if(!r){var a,o,l=(a=i,o=n,t.objectMode||!1===t.decodeStrings||"string"!=typeof a||(a=c.from(a,o)),a);i!==l&&(r=!0,n="buffer",i=l)}var u=t.objectMode?1:i.length;t.length+=u;var d=t.length<t.highWaterMark;if(d||(t.needDrain=!0),t.writing||t.corked){var h=t.lastBufferedRequest;t.lastBufferedRequest={chunk:i,encoding:n,isBuf:r,callback:s,next:null},h?h.next=t.lastBufferedRequest:t.bufferedRequest=t.lastBufferedRequest,t.bufferedRequestCount+=1}else R(e,t,!1,u,i,n,s);return d}(this,f,m,e,t,r)),p},A.prototype.cork=function(){this._writableState.corked++},A.prototype.uncork=function(){var e=this._writableState;e.corked&&(e.corked--,e.writing||e.corked||e.bufferProcessing||!e.bufferedRequest||k(this,e))},A.prototype.setDefaultEncoding=function(e){if("string"==typeof e&&(e=e.toLowerCase()),!(["hex","utf8","utf-8","ascii","binary","base64","ucs2","ucs-2","utf16le","utf-16le","raw"].indexOf((e+"").toLowerCase())>-1))throw new S(e);return this._writableState.defaultEncoding=e,this},Object.defineProperty(A.prototype,"writableBuffer",{enumerable:!1,get:function(){return this._writableState&&this._writableState.getBuffer()}}),Object.defineProperty(A.prototype,"writableHighWaterMark",{enumerable:!1,get:function(){return this._writableState.highWaterMark}}),A.prototype._write=function(e,t,r){r(new m("_write()"))},A.prototype._writev=null,A.prototype.end=function(e,t,r){var n,s,a,o=this._writableState;return"function"==typeof e?(r=e,e=null,t=null):"function"==typeof t&&(r=t,t=null),null!=e&&this.write(e,t),o.corked&&(o.corked=1,this.uncork()),o.ending||(n=this,s=o,a=r,s.ending=!0,L(n,s),a&&(s.finished?i.default.nextTick(a):n.once("finish",a)),s.ended=!0,n.writable=!1),this},Object.defineProperty(A.prototype,"writableLength",{enumerable:!1,get:function(){return this._writableState.length}}),Object.defineProperty(A.prototype,"destroyed",{enumerable:!1,get:function(){return void 0!==this._writableState&&this._writableState.destroyed},set:function(e){this._writableState&&(this._writableState.destroyed=e)}}),A.prototype.destroy=h.destroy,A.prototype._undestroy=h.undestroy,A.prototype._destroy=function(e,t){t(e)}},871:function(e,t,r){"use strict";function n(e,t,r){return t in e?Object.defineProperty(e,t,{value:r,enumerable:!0,configurable:!0,writable:!0}):e[t]=r,e}var s,a=r(698),o=Symbol("lastResolve"),l=Symbol("lastReject"),u=Symbol("error"),c=Symbol("ended"),d=Symbol("lastPromise"),h=Symbol("handlePromise"),f=Symbol("stream");function p(e,t){return{value:e,done:t}}function g(e){var t=e[o];if(null!==t){var r=e[f].read();null!==r&&(e[d]=null,e[o]=null,e[l]=null,t(p(r,!1)))}}function m(e){i.default.nextTick(g,e)}var y=Object.getPrototypeOf(function(){}),v=Object.setPrototypeOf((n(s={get stream(){return this[f]},next:function(){var e,t,r=this,n=this[u];if(null!==n)return Promise.reject(n);if(this[c])return Promise.resolve(p(void 0,!0));if(this[f].destroyed)return new Promise(function(e,t){i.default.nextTick(function(){r[u]?t(r[u]):e(p(void 0,!0))})});var s=this[d];
1if(s)t=new Promise((e=this,function(t,r){s.then(function(){e[c]?t(p(void 0,!0)):e[h](t,r)},r)}));else{var a=this[f].read();if(null!==a)return Promise.resolve(p(a,!1));t=new Promise(this[h])}return this[d]=t,t}},Symbol.asyncIterator,function(){return this}),n(s,"return",function(){var e=this;return new Promise(function(t,r){e[f].destroy(null,function(e){e?r(e):t(p(void 0,!0))})})}),s),y);e.exports=function(e){var t,r=Object.create(v,(n(t={},f,{value:e,writable:!0}),n(t,o,{value:null,writable:!0}),n(t,l,{value:null,writable:!0}),n(t,u,{value:null,writable:!0}),n(t,c,{value:e._readableState.endEmitted,writable:!0}),n(t,h,{value:function(e,t){var i=r[f].read();i?(r[d]=null,r[o]=null,r[l]=null,e(p(i,!1))):(r[o]=e,r[l]=t)},writable:!0}),t));return r[d]=null,a(e,function(e){if(e&&"ERR_STREAM_PREMATURE_CLOSE"!==e.code){var t=r[l];null!==t&&(r[d]=null,r[o]=null,r[l]=null,t(e)),r[u]=e;return}var i=r[o];null!==i&&(r[d]=null,r[o]=null,r[l]=null,i(p(void 0,!0))),r[c]=!0}),e.on("readable",m.bind(null,r)),r}},379:function(e,t,r){"use strict";function i(e,t){var r=Object.keys(e);if(Object.getOwnPropertySymbols){var i=Object.getOwnPropertySymbols(e);t&&(i=i.filter(function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable})),r.push.apply(r,i)}return r}var n=r(300).Buffer,s=r(837).inspect,a=s&&s.custom||"inspect";e.exports=function(){var e;function t(){if(!(this instanceof t))throw TypeError("Cannot call a class as a function");this.head=null,this.tail=null,this.length=0}return e=[{key:"push",value:function(e){var t={data:e,next:null};this.length>0?this.tail.next=t:this.head=t,this.tail=t,++this.length}},{key:"unshift",value:function(e){var t={data:e,next:this.head};0===this.length&&(this.tail=t),this.head=t,++this.length}},{key:"shift",value:function(){if(0!==this.length){var e=this.head.data;return 1===this.length?this.head=this.tail=null:this.head=this.head.next,--this.length,e}}},{key:"clear",value:function(){this.head=this.tail=null,this.length=0}},{key:"join",value:function(e){if(0===this.length)return"";for(var t=this.head,r=""+t.data;t=t.next;)r+=e+t.data;return r}},{key:"concat",value:function(e){if(0===this.length)return n.alloc(0);for(var t,r,i=n.allocUnsafe(e>>>0),s=this.head,a=0;s;)t=s.data,r=a,n.prototype.copy.call(t,i,r),a+=s.data.length,s=s.next;return i}},{key:"consume",value:function(e,t){var r;return e<this.head.data.length?(r=this.head.data.slice(0,e),this.head.data=this.head.data.slice(e)):r=e===this.head.data.length?this.shift():t?this._getString(e):this._getBuffer(e),r}},{key:"first",value:function(){return this.head.data}},{key:"_getString",value:function(e){var t=this.head,r=1,i=t.data;for(e-=i.length;t=t.next;){var n=t.data,s=e>n.length?n.length:e;if(s===n.length?i+=n:i+=n.slice(0,e),0==(e-=s)){s===n.length?(++r,t.next?this.head=t.next:this.head=this.tail=null):(this.head=t,t.data=n.slice(s));break}++r}return this.length-=r,i}},{key:"_getBuffer",value:function(e){var t=n.allocUnsafe(e),r=this.head,i=1;for(r.data.copy(t),e-=r.data.length;r=r.next;){var s=r.data,a=e>s.length?s.length:e;if(s.copy(t,t.length-e,0,a),0==(e-=a)){a===s.length?(++i,r.next?this.head=r.next:this.head=this.tail=null):(this.head=r,r.data=s.slice(a));break}++i}return this.length-=i,t}},{key:a,value:function(e,t){return s(this,function(e){for(var t=1;t<arguments.length;t++){var r=null!=arguments[t]?arguments[t]:{};t%2?i(Object(r),!0).forEach(function(t){var i,n,s;i=e,n=t,s=r[t],n in i?Object.defineProperty(i,n,{value:s,enumerable:!0,configurable:!0,writable:!0}):i[n]=s}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(r)):i(Object(r)).forEach(function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(r,t))})}return e}({},t,{depth:0,customInspect:!1}))}}],function(e,t){for(var r=0;r<t.length;r++){var i=t[r];i.enumerable=i.enumerable||!1,i.configurable=!0,"value"in i&&(i.writable=!0),Object.defineProperty(e,i.key,i)}}(t.prototype,e),t}()},25:function(e){"use strict";function t(e,t){n(e,t),r(e)}function r(e){e._writableState&&!e._writableState.emitClose||(!e._readableState||e._readableState.emitClose)&&e.emit("close")}function n(e,t){e.emit("error",t)}e.exports={destroy:function(e,s){var a=this,o=this._readableState&&this._readableState.destroyed,l=this._writableState&&this._writableState.destroyed;return o||l?s?s(e):e&&(this._writableState?this._writableState.errorEmitted||(this._writableState.errorEmitted=!0,i.default.nextTick(n,this,e)):i.default.nextTick(n,this,e)):(this._readableState&&(this._readableState.destroyed=!0),this._writableState&&(this._writableState.destroyed=!0),this._destroy(e||null,function(e){!s&&e?a._writableState?a._writableState.errorEmitted?i.default.nextTick(r,a):(a._writableState.errorEmitted=!0,i.default.nextTick(t,a,e)):i.default.nextTick(t,a,e):s?(i.default.nextTick(r,a),s(e)):i.default.nextTick(r,a)})),this},undestroy:function(){this._readableState&&(this._readableState.destroyed=!1,this._readableState.reading=!1,this._readableState.ended=!1,this._readableState.endEmitted=!1),this._writableState&&(this._writableState.destroyed=!1,this._writableState.ended=!1,this._writableState.ending=!1,this._writableState.finalCalled=!1,this._writableState.prefinished=!1,this._writableState.finished=!1,this._writableState.errorEmitted=!1)},errorOrDestroy:function(e,t){var r=e._readableState,i=e._writableState;r&&r.autoDestroy||i&&i.autoDestroy?e.destroy(t):e.emit("error",t)}}},698:function(e,t,r){"use strict";
1var i=r(646).q.ERR_STREAM_PREMATURE_CLOSE;function n(){}e.exports=function e(t,r,s){if("function"==typeof r)return e(t,null,r);r||(r={}),a=s||n,o=!1,s=function(){if(!o){o=!0;for(var e=arguments.length,t=Array(e),r=0;r<e;r++)t[r]=arguments[r];a.apply(this,t)}};var a,o,l=r.readable||!1!==r.readable&&t.readable,u=r.writable||!1!==r.writable&&t.writable,c=function(){t.writable||h()},d=t._writableState&&t._writableState.finished,h=function(){u=!1,d=!0,l||s.call(t)},f=t._readableState&&t._readableState.endEmitted,p=function(){l=!1,f=!0,u||s.call(t)},g=function(e){s.call(t,e)},m=function(){var e;return l&&!f?(t._readableState&&t._readableState.ended||(e=new i),s.call(t,e)):u&&!d?(t._writableState&&t._writableState.ended||(e=new i),s.call(t,e)):void 0},y=function(){t.req.on("finish",h)};return t.setHeader&&"function"==typeof t.abort?(t.on("complete",h),t.on("abort",m),t.req?y():t.on("request",y)):u&&!t._writableState&&(t.on("end",c),t.on("close",c)),t.on("end",p),t.on("finish",h),!1!==r.error&&t.on("error",g),t.on("close",m),function(){t.removeListener("complete",h),t.removeListener("abort",m),t.removeListener("request",y),t.req&&t.req.removeListener("finish",h),t.removeListener("end",c),t.removeListener("close",c),t.removeListener("finish",h),t.removeListener("end",p),t.removeListener("error",g),t.removeListener("close",m)}}},727:function(e,t,r){"use strict";function i(e,t,r,i,n,s,a){try{var o=e[s](a),l=o.value}catch(e){r(e);return}o.done?t(l):Promise.resolve(l).then(i,n)}function n(e,t){var r=Object.keys(e);if(Object.getOwnPropertySymbols){var i=Object.getOwnPropertySymbols(e);t&&(i=i.filter(function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable})),r.push.apply(r,i)}return r}var s=r(646).q.ERR_INVALID_ARG_TYPE;e.exports=function(e,t,r){if(t&&"function"==typeof t.next)a=t;else if(t&&t[Symbol.asyncIterator])a=t[Symbol.asyncIterator]();else if(t&&t[Symbol.iterator])a=t[Symbol.iterator]();else throw new s("iterable",["Iterable"],t);var a,o=new e(function(e){for(var t=1;t<arguments.length;t++){var r=null!=arguments[t]?arguments[t]:{};t%2?n(Object(r),!0).forEach(function(t){var i,n,s;i=e,n=t,s=r[t],n in i?Object.defineProperty(i,n,{value:s,enumerable:!0,configurable:!0,writable:!0}):i[n]=s}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(r)):n(Object(r)).forEach(function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(r,t))})}return e}({objectMode:!0},r)),l=!1;function u(){return c.apply(this,arguments)}function c(){var e;return e=function*(){try{var e=yield a.next(),t=e.value;e.done?o.push(null):o.push((yield t))?u():l=!1}catch(e){o.destroy(e)}},(c=function(){var t=this,r=arguments;return new Promise(function(n,s){var a=e.apply(t,r);function o(e){i(a,n,s,o,l,"next",e)}function l(e){i(a,n,s,o,l,"throw",e)}o(void 0)})}).apply(this,arguments)}return o._read=function(){l||(l=!0,u())},o}},442:function(e,t,r){"use strict";var i,n=r(646).q,s=n.ERR_MISSING_ARGS,a=n.ERR_STREAM_DESTROYED;function o(e){if(e)throw e}function l(e){e()}function u(e,t){return e.pipe(t)}e.exports=function(){for(var e,t,n=arguments.length,c=Array(n),d=0;d<n;d++)c[d]=arguments[d];var h=(e=c).length&&"function"==typeof e[e.length-1]?e.pop():o;if(Array.isArray(c[0])&&(c=c[0]),c.length<2)throw new s("streams");var f=c.map(function(e,n){var s,o,u,d,p,g,m=n<c.length-1;return s=n>0,u=o=function(e){t||(t=e),e&&f.forEach(l),m||(f.forEach(l),h(t))},d=!1,o=function(){d||(d=!0,u.apply(void 0,arguments))},p=!1,e.on("close",function(){p=!0}),void 0===i&&(i=r(698)),i(e,{readable:m,writable:s},function(e){if(e)return o(e);p=!0,o()}),g=!1,function(t){if(!p&&!g){if(g=!0,e.setHeader&&"function"==typeof e.abort)return e.abort();if("function"==typeof e.destroy)return e.destroy();o(t||new a("pipe"))}}});return c.reduce(u)}},776:function(e,t,r){"use strict";var i=r(646).q.ERR_INVALID_OPT_VALUE;e.exports={getHighWaterMark:function(e,t,r,n){var s=null!=t.highWaterMark?t.highWaterMark:n?t[r]:null;if(null!=s){if(!(isFinite(s)&&Math.floor(s)===s)||s<0)throw new i(n?r:"highWaterMark",s);return Math.floor(s)}return e.objectMode?16:16384}}},678:function(e,t,r){e.exports=r(781)},55:function(e,t,r){var i=r(300),n=i.Buffer;function s(e,t){for(var r in e)t[r]=e[r]}function a(e,t,r){return n(e,t,r)}n.from&&n.alloc&&n.allocUnsafe&&n.allocUnsafeSlow?e.exports=i:(s(i,t),t.Buffer=a),a.prototype=Object.create(n.prototype),s(n,a),a.from=function(e,t,r){if("number"==typeof e)throw TypeError("Argument must not be a number");return n(e,t,r)},a.alloc=function(e,t,r){if("number"!=typeof e)throw TypeError("Argument must be a number");var i=n(e);return void 0!==t?"string"==typeof r?i.fill(t,r):i.fill(t):i.fill(0),i},a.allocUnsafe=function(e){if("number"!=typeof e)throw TypeError("Argument must be a number");return n(e)},a.allocUnsafeSlow=function(e){if("number"!=typeof e)throw TypeError("Argument must be a number");return i.SlowBuffer(e)}},173:function(e,t,r){e.exports=n;var i=r(361).EventEmitter;function n(){i.call(this)}r(782)(n,i),n.Readable=r(709),n.Writable=r(337),n.Duplex=r(403),n.Transform=r(170),n.PassThrough=r(889),n.finished=r(698),n.pipeline=r(442),n.Stream=n,n.prototype.pipe=function(e,t){var r=this;function n(t){e.writable&&!1===e.write(t)&&r.pause&&r.pause()}function s(){r.readable&&r.resume&&r.resume()}r.on("data",n),e.on("drain",s),e._isStdio||t&&!1===t.end||(r.on("end",o),r.on("close",l));var a=!1;function o(){a||(a=!0,e.end())}function l(){a||(a=!0,"function"==typeof e.destroy&&e.destroy())}function u(e){if(c(),0===i.listenerCount(this,"error"))throw e}function c(){r.removeListener("data",n),e.removeListener("drain",s),r.removeListener("end",o),r.removeListener("close",l),r.removeListener("error",u),e.removeListener("error",u),r.removeListener("end",c),r.removeListener("close",c),e.removeListener("close",c)}return r.on("error",u),e.on("error",u),r.on("end",c),r.on("close",c),e.on("close",c),e.emit("pipe",r),e}},704:function(e,t,r){"use strict";var i=r(55).Buffer,n=i.isEncoding||function(e){switch((e=""+e)&&e.toLowerCase()){case"hex":case"utf8":case"utf-8":case"ascii":case"binary":case"base64":case"ucs2":case"ucs-2":case"utf16le":case"utf-16le":case"raw":return!0;default:return!1}};function s(e){var t;switch(this.encoding=function(e){var t=function(e){var t;if(!e)return"utf8";for(;;)switch(e){case"utf8":case"utf-8":return"utf8";case"ucs2":case"ucs-2":case"utf16le":case"utf-16le":return"utf16le";
1case"latin1":case"binary":return"latin1";case"base64":case"ascii":case"hex":return e;default:if(t)return;e=(""+e).toLowerCase(),t=!0}}(e);if("string"!=typeof t&&(i.isEncoding===n||!n(e)))throw Error("Unknown encoding: "+e);return t||e}(e),this.encoding){case"utf16le":this.text=l,this.end=u,t=4;break;case"utf8":this.fillLast=o,t=4;break;case"base64":this.text=c,this.end=d,t=3;break;default:this.write=h,this.end=f;return}this.lastNeed=0,this.lastTotal=0,this.lastChar=i.allocUnsafe(t)}function a(e){return e<=127?0:e>>5==6?2:e>>4==14?3:e>>3==30?4:e>>6==2?-1:-2}function o(e){var t=this.lastTotal-this.lastNeed,r=function(e,t){if((192&t[0])!=128)return e.lastNeed=0,"�";if(e.lastNeed>1&&t.length>1){if((192&t[1])!=128)return e.lastNeed=1,"�";if(e.lastNeed>2&&t.length>2&&(192&t[2])!=128)return e.lastNeed=2,"�"}}(this,e);return void 0!==r?r:this.lastNeed<=e.length?(e.copy(this.lastChar,t,0,this.lastNeed),this.lastChar.toString(this.encoding,0,this.lastTotal)):void(e.copy(this.lastChar,t,0,e.length),this.lastNeed-=e.length)}function l(e,t){if((e.length-t)%2==0){var r=e.toString("utf16le",t);if(r){var i=r.charCodeAt(r.length-1);if(i>=55296&&i<=56319)return this.lastNeed=2,this.lastTotal=4,this.lastChar[0]=e[e.length-2],this.lastChar[1]=e[e.length-1],r.slice(0,-1)}return r}return this.lastNeed=1,this.lastTotal=2,this.lastChar[0]=e[e.length-1],e.toString("utf16le",t,e.length-1)}function u(e){var t=e&&e.length?this.write(e):"";if(this.lastNeed){var r=this.lastTotal-this.lastNeed;return t+this.lastChar.toString("utf16le",0,r)}return t}function c(e,t){var r=(e.length-t)%3;return 0===r?e.toString("base64",t):(this.lastNeed=3-r,this.lastTotal=3,1===r?this.lastChar[0]=e[e.length-1]:(this.lastChar[0]=e[e.length-2],this.lastChar[1]=e[e.length-1]),e.toString("base64",t,e.length-r))}function d(e){var t=e&&e.length?this.write(e):"";return this.lastNeed?t+this.lastChar.toString("base64",0,3-this.lastNeed):t}function h(e){return e.toString(this.encoding)}function f(e){return e&&e.length?this.write(e):""}t.s=s,s.prototype.write=function(e){var t,r;if(0===e.length)return"";if(this.lastNeed){if(void 0===(t=this.fillLast(e)))return"";r=this.lastNeed,this.lastNeed=0}else r=0;return r<e.length?t?t+this.text(e,r):this.text(e,r):t||""},s.prototype.end=function(e){var t=e&&e.length?this.write(e):"";return this.lastNeed?t+"�":t},s.prototype.text=function(e,t){var r=function(e,t,r){var i=t.length-1;if(i<r)return 0;var n=a(t[i]);return n>=0?(n>0&&(e.lastNeed=n-1),n):--i<r||-2===n?0:(n=a(t[i]))>=0?(n>0&&(e.lastNeed=n-2),n):--i<r||-2===n?0:(n=a(t[i]))>=0?(n>0&&(2===n?n=0:e.lastNeed=n-3),n):0}(this,e,t);if(!this.lastNeed)return e.toString("utf8",t);this.lastTotal=r;var i=e.length-(r-this.lastNeed);return e.copy(this.lastChar,0,i),e.toString("utf8",t,i)},s.prototype.fillLast=function(e){if(this.lastNeed<=e.length)return e.copy(this.lastChar,this.lastTotal-this.lastNeed,0,this.lastNeed),this.lastChar.toString(this.encoding,0,this.lastTotal);e.copy(this.lastChar,this.lastTotal-this.lastNeed,0,e.length),this.lastNeed-=e.length}},769:function(t){t.exports=function(e,t){if(r("noDeprecation"))return e;var i=!1;return function(){if(!i){if(r("throwDeprecation"))throw Error(t);r("traceDeprecation")?console.trace(t):console.warn(t),i=!0}return e.apply(this,arguments)}};function r(t){try{if(!e.g.localStorage)return!1}catch(e){return!1}var r=e.g.localStorage[t];return null!=r&&"true"===String(r).toLowerCase()}},300:function(t){"use strict";t.exports=e.r(467034)},361:function(t){"use strict";t.exports=e.r(430662)},781:function(t){"use strict";t.exports=e.r(430662).EventEmitter},837:function(t){"use strict";t.exports=e.r(477398)}},s={};function a(e){var t=s[e];if(void 0!==t)return t.exports;var r=s[e]={exports:{}},i=!0;try{n[e](r,r.exports,a),i=!1}finally{i&&delete s[e]}return r.exports}a.ab="/ROOT/node_modules/next/dist/compiled/stream-browserify/",t.exports=a(173)},427323,(e,t,r)=>{var i=e.i(467034);!function(t){t.parser=function(e,t){return new l(e,t)},t.SAXParser=l,t.SAXStream=c,t.createStream=function(e,t){return new c(e,t)},t.MAX_BUFFER_LENGTH=65536;var r,n,s,a,o=["comment","sgmlDecl","textNode","tagName","doctype","procInstName","procInstBody","entity","attribName","attribValue","cdata","script"];function l(e,r){if(!(this instanceof l))return new l(e,r);(function(e){for(var t=0,r=o.length;t<r;t++)e[o[t]]=""})(this),this.q=this.c="",this.bufferCheckPosition=t.MAX_BUFFER_LENGTH,this.encoding=null,this.opt=r||{},this.opt.lowercase=this.opt.lowercase||this.opt.lowercasetags,this.looseCase=this.opt.lowercase?"toLowerCase":"toUpperCase",this.opt.maxEntityCount=this.opt.maxEntityCount||512,this.opt.maxEntityDepth=this.opt.maxEntityDepth||4,this.entityCount=this.entityDepth=0,this.tags=[],this.closed=this.closedRoot=this.sawRoot=!1,this.tag=this.error=null,this.strict=!!e,this.noscript=!!(e||this.opt.noscript),this.state=E.BEGIN,this.strictEntities=this.opt.strictEntities,this.ENTITIES=this.strictEntities?Object.create(t.XML_ENTITIES):Object.create(t.ENTITIES),this.attribList=[],this.opt.xmlns&&(this.ns=Object.create(f)),void 0===this.opt.unquotedAttributeValues&&(this.opt.unquotedAttributeValues=!e),this.trackPosition=!1!==this.opt.position,this.trackPosition&&(this.position=this.line=this.column=0),x(this,"onready")}t.EVENTS=["text","processinginstruction","sgmldeclaration","doctype","comment","opentagstart","attribute","opentag","closetag","opencdata","cdata","closecdata","error","end","ready","script","opennamespace","closenamespace"],Object.create||(Object.create=function(e){function t(){}return t.prototype=e,new t}),Object.keys||(Object.keys=function(e){var t=[];for(var r in e)e.hasOwnProperty(r)&&t.push(r);return t}),l.prototype={end:function(){k(this)},write:function(e){if(this.error)throw this.error;if(this.closed)return I(this,"Cannot write after close. Assign an onready handler.");if(null===e)return k(this);"object"==typeof e&&(e=e.toString());for(var r=0,i="";i=N(e,r++),this.c=i,i;)switch(this.trackPosition&&(this.position++,"\n"===i?(this.line++,this.column=0):this.column++),this.state){case E.BEGIN:if(this.state=E.BEGIN_WHITESPACE,"\uFEFF"===i)continue;F(this,i);continue;case E.BEGIN_WHITESPACE:F(this,i);continue;case E.TEXT:if(this.sawRoot&&!this.closedRoot){for(var n=r-1;i&&"<"!==i&&"&"!==i;)(i=N(e,r++))&&this.trackPosition&&(this.position++,"\n"===i?(this.line++,this.column=0):this.column++);this.textNode+=e.substring(n,r-1)}"<"!==i||this.sawRoot&&this.closedRoot&&!this.strict?(v(i)||this.sawRoot&&!this.closedRoot||C(this,"Text data outside of root node."),"&"===i?this.state=E.TEXT_ENTITY:this.textNode+=i):(this.state=E.OPEN_WAKA,this.startTagPosition=this.position);continue;case E.SCRIPT:"<"===i?this.state=E.SCRIPT_ENDING:this.script+=i;continue;case E.SCRIPT_ENDING:"/"===i?this.state=E.CLOSE_TAG:(this.script+="<"+i,this.state=E.SCRIPT);continue;case E.OPEN_WAKA:"!"===i?(this.state=E.SGML_DECL,this.sgmlDecl=""):v(i)||(_(p,i)?(this.state=E.OPEN_TAG,this.tagName=i):"/"===i?(this.state=E.CLOSE_TAG,this.tagName=""):"?"===i?(this.state=E.PROC_INST,this.procInstName=this.procInstBody=""):(C(this,"Unencoded <"),this.startTagPosition+1<this.position&&(i=Array(this.position-this.startTagPosition).join(" ")+i),this.textNode+="<"+i,this.state=E.TEXT));continue;case E.SGML_DECL:if(this.sgmlDecl+i==="--"){this.state=E.COMMENT,this.comment="",this.sgmlDecl="";continue}this.doctype&&!0!==this.doctype&&this.sgmlDecl?(this.state=E.DOCTYPE_DTD,this.doctype+="<!"+this.sgmlDecl+i,this.sgmlDecl=""):"[CDATA["===(this.sgmlDecl+i).toUpperCase()?(w(this,"onopencdata"),this.state=E.CDATA,this.sgmlDecl="",this.cdata=""):"DOCTYPE"===(this.sgmlDecl+i).toUpperCase()?(this.state=E.DOCTYPE,(this.doctype||this.sawRoot)&&C(this,"Inappropriately located doctype declaration"),this.doctype="",this.sgmlDecl=""):">"===i?(w(this,"onsgmldeclaration",this.sgmlDecl),this.sgmlDecl="",this.state=E.TEXT):(b(i)&&(this.state=E.SGML_DECL_QUOTED),this.sgmlDecl+=i);continue;case E.SGML_DECL_QUOTED:i===this.q&&(this.state=E.SGML_DECL,this.q=""),this.sgmlDecl+=i;continue;case E.DOCTYPE:">"===i?(this.state=E.TEXT,w(this,"ondoctype",this.doctype),this.doctype=!0):(this.doctype+=i,"["===i?this.state=E.DOCTYPE_DTD:b(i)&&(this.state=E.DOCTYPE_QUOTED,this.q=i));continue;case E.DOCTYPE_QUOTED:this.doctype+=i,i===this.q&&(this.q="",this.state=E.DOCTYPE);continue;case E.DOCTYPE_DTD:"]"===i?(this.doctype+=i,this.state=E.DOCTYPE):"<"===i?(this.state=E.OPEN_WAKA,this.startTagPosition=this.position):b(i)?(this.doctype+=i,this.state=E.DOCTYPE_DTD_QUOTED,this.q=i):this.doctype+=i;continue;case E.DOCTYPE_DTD_QUOTED:this.doctype+=i,i===this.q&&(this.state=E.DOCTYPE_DTD,this.q="");continue;case E.COMMENT:"-"===i?this.state=E.COMMENT_ENDING:this.comment+=i;continue;case E.COMMENT_ENDING:"-"===i?(this.state=E.COMMENT_ENDED,this.comment=R(this.opt,this.comment),this.comment&&w(this,"oncomment",this.comment),this.comment=""):(this.comment+="-"+i,this.state=E.COMMENT);continue;case E.COMMENT_ENDED:">"!==i?(C(this,"Malformed comment"),this.comment+="--"+i,this.state=E.COMMENT):this.doctype&&!0!==this.doctype?this.state=E.DOCTYPE_DTD:this.state=E.TEXT;continue;case E.CDATA:for(var n=r-1;i&&"]"!==i;)(i=N(e,r++))&&this.trackPosition&&(this.position++,"\n"===i?(this.line++,this.column=0):this.column++);this.cdata+=e.substring(n,r-1),"]"===i&&(this.state=E.CDATA_ENDING);continue;case E.CDATA_ENDING:"]"===i?this.state=E.CDATA_ENDING_2:(this.cdata+="]"
1+i,this.state=E.CDATA);continue;case E.CDATA_ENDING_2:">"===i?(this.cdata&&w(this,"oncdata",this.cdata),w(this,"onclosecdata"),this.cdata="",this.state=E.TEXT):"]"===i?this.cdata+="]":(this.cdata+="]]"+i,this.state=E.CDATA);continue;case E.PROC_INST:"?"===i?this.state=E.PROC_INST_ENDING:v(i)?this.state=E.PROC_INST_BODY:this.procInstName+=i;continue;case E.PROC_INST_BODY:!this.procInstBody&&v(i)||("?"===i?this.state=E.PROC_INST_ENDING:this.procInstBody+=i);continue;case E.PROC_INST_ENDING:if(">"===i){let e={name:this.procInstName,body:this.procInstBody};!function(e,t){if(e.strict&&e.encoding&&t&&"xml"===t.name){let a,o;var r,i,n,s=(i=(r=t.body)&&r.match(/(?:^|\s)encoding\s*=\s*(['"])([^'"]+)\1/i))?i[2]:null;s&&(n=e.encoding,a=T(n),o=T(s),a&&o&&("utf16"===o?"utf16le"!==a&&"utf16be"!==a:a!==o))&&C(e,"XML declaration encoding "+s+" does not match detected stream encoding "+e.encoding.toUpperCase())}}(this,e),w(this,"onprocessinginstruction",e),this.procInstName=this.procInstBody="",this.state=E.TEXT}else this.procInstBody+="?"+i,this.state=E.PROC_INST_BODY;continue;case E.OPEN_TAG:_(g,i)?this.tagName+=i:(!function(e){e.strict||(e.tagName=e.tagName[e.looseCase]());var t=e.tags[e.tags.length-1]||e,r=e.tag={name:e.tagName,attributes:{}};e.opt.xmlns&&(r.ns=t.ns),e.attribList.length=0,w(e,"onopentagstart",r)}(this),">"===i?O(this):"/"===i?this.state=E.OPEN_TAG_SLASH:(v(i)||C(this,"Invalid character in tag name"),this.state=E.ATTRIB));continue;case E.OPEN_TAG_SLASH:">"===i?(O(this,!0),P(this)):(C(this,"Forward-slash in opening tag not followed by >"),this.state=E.ATTRIB);continue;case E.ATTRIB:v(i)||(">"===i?O(this):"/"===i?this.state=E.OPEN_TAG_SLASH:_(p,i)?(this.attribName=i,this.attribValue="",this.state=E.ATTRIB_NAME):C(this,"Invalid attribute name"));continue;case E.ATTRIB_NAME:"="===i?this.state=E.ATTRIB_VALUE:">"===i?(C(this,"Attribute without value"),this.attribValue=this.attribName,L(this),O(this)):v(i)?this.state=E.ATTRIB_NAME_SAW_WHITE:_(g,i)?this.attribName+=i:C(this,"Invalid attribute name");continue;case E.ATTRIB_NAME_SAW_WHITE:if("="===i)this.state=E.ATTRIB_VALUE;else{if(v(i))continue;C(this,"Attribute without value"),this.tag.attributes[this.attribName]="",this.attribValue="",w(this,"onattribute",{name:this.attribName,value:""}),this.attribName="",">"===i?O(this):_(p,i)?(this.attribName=i,this.state=E.ATTRIB_NAME):(C(this,"Invalid attribute name"),this.state=E.ATTRIB)}continue;case E.ATTRIB_VALUE:v(i)||(b(i)?(this.q=i,this.state=E.ATTRIB_VALUE_QUOTED):(this.opt.unquotedAttributeValues||I(this,"Unquoted attribute value"),this.state=E.ATTRIB_VALUE_UNQUOTED,this.attribValue=i));continue;case E.ATTRIB_VALUE_QUOTED:if(i!==this.q){"&"===i?this.state=E.ATTRIB_VALUE_ENTITY_Q:this.attribValue+=i;continue}L(this),this.q="",this.state=E.ATTRIB_VALUE_CLOSED;continue;case E.ATTRIB_VALUE_CLOSED:v(i)?this.state=E.ATTRIB:">"===i?O(this):"/"===i?this.state=E.OPEN_TAG_SLASH:_(p,i)?(C(this,"No whitespace between attributes"),this.attribName=i,this.attribValue="",this.state=E.ATTRIB_NAME):C(this,"Invalid attribute name");continue;case E.ATTRIB_VALUE_UNQUOTED:if(!(">"===(s=i)||v(s))){"&"===i?this.state=E.ATTRIB_VALUE_ENTITY_U:this.attribValue+=i;continue}L(this),">"===i?O(this):this.state=E.ATTRIB;continue;case E.CLOSE_TAG:this.tagName?">"===i?P(this):_(g,i)?this.tagName+=i:this.script?(this.script+="</"+this.tagName+i,this.tagName="",this.state=E.SCRIPT):(v(i)||C(this,"Invalid tagname in closing tag"),this.state=E.CLOSE_TAG_SAW_WHITE):v(i)||(_(p,i)?this.tagName=i:this.script?(this.script+="</"+i,this.state=E.SCRIPT):C(this,"Invalid tagname in closing tag."));continue;case E.CLOSE_TAG_SAW_WHITE:if(v(i))continue;">"===i?P(this):C(this,"Invalid characters in closing tag");continue;case E.TEXT_ENTITY:case E.ATTRIB_VALUE_ENTITY_Q:case E.ATTRIB_VALUE_ENTITY_U:switch(this.state){case E.TEXT_ENTITY:a=E.TEXT,l="textNode";break;case E.ATTRIB_VALUE_ENTITY_Q:a=E.ATTRIB_VALUE_QUOTED,l="attribValue";break;case E.ATTRIB_VALUE_ENTITY_U:a=E.ATTRIB_VALUE_UNQUOTED,l="attribValue"}if(";"===i){var s,a,l,u=function(e){var t,r=e.entity,i=r.toLowerCase(),n="";return e.ENTITIES[r]?e.ENTITIES[r]:e.ENTITIES[i]?e.ENTITIES[i]:("#"===(r=i).charAt(0)&&(n="x"===r.charAt(1)?(t=parseInt(r=r.slice(2),16)).toString(16):(t=parseInt(r=r.slice(1),10)).toString(10)),r=r.replace(/^0+/,""),isNaN(t)||n.toLowerCase()!==r||t<0||t>1114111)?(C(e,"Invalid character entity"),"&"+e.entity+";"):String.fromCodePoint(t)}(this);this.opt.unparsedEntities&&!Object.values(t.XML_ENTITIES).includes(u)?((this.entityCount+=1)>this.opt.maxEntityCount&&I(this,"Parsed entity count exceeds max entity count"),(this.entityDepth+=1)>this.opt.maxEntityDepth&&I(this,"Parsed entity depth exceeds max entity depth"),this.entity="",this.state=a,this.write(u),this.entityDepth-=1):(this[l]+=u,this.entity="",this.state=a)}else _(this.entity.length?y:m,i)?this.entity+=i:(C(this,"Invalid character in entity name"),this[l]+="&"+this.entity+i,this.entity="",this.state=a);continue;default:throw Error(this,"Unknown state: "+this.state)}return this.position>=this.bufferCheckPosition&&function(e){for(var r=Math.max(t.MAX_BUFFER_LENGTH,10),i=0,n=0,s=o.length;n<s;n++){var a=e[o[n]].length;if(a>r)switch(o[n]){case"textNode":A(e);break;case"cdata":w(e,"oncdata",e.cdata),e.cdata="";break;case"script":w(e,"onscript",e.script),e.script="";break;default:I(e,"Max buffer length exceeded: "+o[n])}i=Math.max(i,a)}e.bufferCheckPosition=t.MAX_BUFFER_LENGTH-i+e.position}(this),this},resume:function(){return this.error=null,this},close:function(){return this.write(null)},flush:function(){A(this),""!==this.cdata&&(w(this,"oncdata",this.cdata),this.cdata=""),""!==this.script&&(w(this,"onscript",this.script),this.script="")}};try{a=e.r(612569).Stream}catch(e){a=function(){}}a||(a=function(){});var u=t.EVENTS.filter(function(e){return"error"!==e&&"end"!==e});function c(e,t){if(!(this instanceof c))return new c(e,t);a.apply(this),this._parser=new l(e,t),this.writable=!0,this.readable=!0;var r=this;this._parser.onend=function(){r.emit("end")},this._parser.onerror=function(e){r.emit("error",e),r._parser.error=null},this._decoder=null,this._decoderBuffer=null,u.forEach(function(e){Object.defineProperty(r,"on"+e,{get:function(){return r._parser["on"+e]},set:function(t){if(!t)return r.removeAllListeners(e),r._parser["on"+e]=t,t;r.on(e,t)},enumerable:!0,configurable:!1})})}c.prototype=Object.create(a.prototype,{constructor:{value:c}}),c.prototype._decodeBuffer=function(e,t){if(this._decoderBuffer&&(e=i.Buffer.concat([this._decoderBuffer,e]),this._decoderBuffer=null),!this._decoder){var r=function(e,t){if(e.length>=2){if(255===e[0]&&254===e[1])return"utf-16le";if(254===e[0]&&255===e[1])return"utf-16be"}return e.length>=3&&239===e[0]&&187===e[1]&&191===e[2]?"utf8":e.length>=4?60===e[0]&&0===e[1]&&63===e[2]&&0===e[3]?"utf-16le":0===e[0]&&60===e[1]&&0===e[2]&&63===e[3]?"utf-16be":"utf8":t?"utf8":null}(e,t);if(!r)return this._decoderBuffer=e,"";this._parser.encoding=r,this._decoder=new TextDecoder(r)}return this._decoder.decode(e,{stream:!t})},c.prototype.write=function(e){if("function"==typeof i.Buffer&&"function"==typeof i.Buffer.isBuffer&&i.Buffer.isBuffer(e))e=this._decodeBuffer(e,!1);else if(this._decoderBuffer){var t=this._decodeBuffer(i.Buffer.alloc(0),!0);
vendor: 7,354 bytes, line 1
1t&&(this._parser.write(t),this.emit("data",t))}return this._parser.write(e.toString()),this.emit("data",e),!0},c.prototype.end=function(e){if(e&&e.length&&this.write(e),this._decoderBuffer){var t=this._decodeBuffer(i.Buffer.alloc(0),!0);t&&(this._parser.write(t),this.emit("data",t))}else if(this._decoder){var r=this._decoder.decode();r&&(this._parser.write(r),this.emit("data",r))}return this._parser.end(),!0},c.prototype.on=function(e,t){var r=this;return r._parser["on"+e]||-1===u.indexOf(e)||(r._parser["on"+e]=function(){var t=1==arguments.length?[arguments[0]]:Array.apply(null,arguments);t.splice(0,0,e),r.emit.apply(r,t)}),a.prototype.on.call(r,e,t)};var d="http://www.w3.org/XML/1998/namespace",h="http://www.w3.org/2000/xmlns/",f={xml:d,xmlns:h},p=/[:_A-Za-z\u00C0-\u00D6\u00D8-\u00F6\u00F8-\u02FF\u0370-\u037D\u037F-\u1FFF\u200C-\u200D\u2070-\u218F\u2C00-\u2FEF\u3001-\uD7FF\uF900-\uFDCF\uFDF0-\uFFFD]/,g=/[:_A-Za-z\u00C0-\u00D6\u00D8-\u00F6\u00F8-\u02FF\u0370-\u037D\u037F-\u1FFF\u200C-\u200D\u2070-\u218F\u2C00-\u2FEF\u3001-\uD7FF\uF900-\uFDCF\uFDF0-\uFFFD\u00B7\u0300-\u036F\u203F-\u2040.\d-]/,m=/[#:_A-Za-z\u00C0-\u00D6\u00D8-\u00F6\u00F8-\u02FF\u0370-\u037D\u037F-\u1FFF\u200C-\u200D\u2070-\u218F\u2C00-\u2FEF\u3001-\uD7FF\uF900-\uFDCF\uFDF0-\uFFFD]/,y=/[#:_A-Za-z\u00C0-\u00D6\u00D8-\u00F6\u00F8-\u02FF\u0370-\u037D\u037F-\u1FFF\u200C-\u200D\u2070-\u218F\u2C00-\u2FEF\u3001-\uD7FF\uF900-\uFDCF\uFDF0-\uFFFD\u00B7\u0300-\u036F\u203F-\u2040.\d-]/;function v(e){return" "===e||"\n"===e||"\r"===e||" "===e}function b(e){return'"'===e||"'"===e}function _(e,t){return e.test(t)}var E=0;for(var S in t.STATE={BEGIN:E++,BEGIN_WHITESPACE:E++,TEXT:E++,TEXT_ENTITY:E++,OPEN_WAKA:E++,SGML_DECL:E++,SGML_DECL_QUOTED:E++,DOCTYPE:E++,DOCTYPE_QUOTED:E++,DOCTYPE_DTD:E++,DOCTYPE_DTD_QUOTED:E++,COMMENT_STARTING:E++,COMMENT:E++,COMMENT_ENDING:E++,COMMENT_ENDED:E++,CDATA:E++,CDATA_ENDING:E++,CDATA_ENDING_2:E++,PROC_INST:E++,PROC_INST_BODY:E++,PROC_INST_ENDING:E++,OPEN_TAG:E++,OPEN_TAG_SLASH:E++,ATTRIB:E++,ATTRIB_NAME:E++,ATTRIB_NAME_SAW_WHITE:E++,ATTRIB_VALUE:E++,ATTRIB_VALUE_QUOTED:E++,ATTRIB_VALUE_CLOSED:E++,ATTRIB_VALUE_UNQUOTED:E++,ATTRIB_VALUE_ENTITY_Q:E++,ATTRIB_VALUE_ENTITY_U:E++,CLOSE_TAG:E++,CLOSE_TAG_SAW_WHITE:E++,SCRIPT:E++,SCRIPT_ENDING:E++},t.XML_ENTITIES={amp:"&",gt:">",lt:"<",quot:'"',apos:"'"},t.ENTITIES={amp:"&",gt:">",lt:"<",quot:'"',apos:"'",AElig:198,Aacute:193,Acirc:194,Agrave:192,Aring:197,Atilde:195,Auml:196,Ccedil:199,ETH:208,Eacute:201,Ecirc:202,Egrave:200,Euml:203,Iacute:205,Icirc:206,Igrave:204,Iuml:207,Ntilde:209,Oacute:211,Ocirc:212,Ograve:210,Oslash:216,Otilde:213,Ouml:214,THORN:222,Uacute:218,Ucirc:219,Ugrave:217,Uuml:220,Yacute:221,aacute:225,acirc:226,aelig:230,agrave:224,aring:229,atilde:227,auml:228,ccedil:231,eacute:233,ecirc:234,egrave:232,eth:240,euml:235,iacute:237,icirc:238,igrave:236,iuml:239,ntilde:241,oacute:243,ocirc:244,ograve:242,oslash:248,otilde:245,ouml:246,szlig:223,thorn:254,uacute:250,ucirc:251,ugrave:249,uuml:252,yacute:253,yuml:255,copy:169,reg:174,nbsp:160,iexcl:161,cent:162,pound:163,curren:164,yen:165,brvbar:166,sect:167,uml:168,ordf:170,laquo:171,not:172,shy:173,macr:175,deg:176,plusmn:177,sup1:185,sup2:178,sup3:179,acute:180,micro:181,para:182,middot:183,cedil:184,ordm:186,raquo:187,frac14:188,frac12:189,frac34:190,iquest:191,times:215,divide:247,OElig:338,oelig:339,Scaron:352,scaron:353,Yuml:376,fnof:402,circ:710,tilde:732,Alpha:913,Beta:914,Gamma:915,Delta:916,Epsilon:917,Zeta:918,Eta:919,Theta:920,Iota:921,Kappa:922,Lambda:923,Mu:924,Nu:925,Xi:926,Omicron:927,Pi:928,Rho:929,Sigma:931,Tau:932,Upsilon:933,Phi:934,Chi:935,Psi:936,Omega:937,alpha:945,beta:946,gamma:947,delta:948,epsilon:949,zeta:950,eta:951,theta:952,iota:953,kappa:954,lambda:955,mu:956,nu:957,xi:958,omicron:959,pi:960,rho:961,sigmaf:962,sigma:963,tau:964,upsilon:965,phi:966,chi:967,psi:968,omega:969,thetasym:977,upsih:978,piv:982,ensp:8194,emsp:8195,thinsp:8201,zwnj:8204,zwj:8205,lrm:8206,rlm:8207,ndash:8211,mdash:8212,lsquo:8216,rsquo:8217,sbquo:8218,ldquo:8220,rdquo:8221,bdquo:8222,dagger:8224,Dagger:8225,bull:8226,hellip:8230,permil:8240,prime:8242,Prime:8243,lsaquo:8249,rsaquo:8250,oline:8254,frasl:8260,euro:8364,image:8465,weierp:8472,real:8476,trade:8482,alefsym:8501,larr:8592,uarr:8593,rarr:8594,darr:8595,harr:8596,crarr:8629,lArr:8656,uArr:8657,rArr:8658,dArr:8659,hArr:8660,forall:8704,part:8706,exist:8707,empty:8709,nabla:8711,isin:8712,notin:8713,ni:8715,prod:8719,sum:8721,minus:8722,lowast:8727,radic:8730,prop:8733,infin:8734,ang:8736,and:8743,or:8744,cap:8745,cup:8746,int:8747,there4:8756,sim:8764,cong:8773,asymp:8776,ne:8800,equiv:8801,le:8804,ge:8805,sub:8834,sup:8835,nsub:8836,sube:8838,supe:8839,oplus:8853,otimes:8855,perp:8869,sdot:8901,lceil:8968,rceil:8969,lfloor:8970,rfloor:8971,lang:9001,rang:9002,loz:9674,spades:9824,clubs:9827,hearts:9829,diams:9830},Object.keys(t.ENTITIES).forEach(function(e){var r=t.ENTITIES[e],i="number"==typeof r?String.fromCharCode(r):r;t.ENTITIES[e]=i}),t.STATE)t.STATE[t.STATE[S]]=S;function x(e,t,r){e[t]&&e[t](r)}function T(e){return e?e.toLowerCase().replace(/[^a-z0-9]/g,""):null}function w(e,t,r){e.textNode&&A(e),x(e,t,r)}function A(e){e.textNode=R(e.opt,e.textNode),e.textNode&&x(e,"ontext",e.textNode),e.textNode=""}function R(e,t){return e.trim&&(t=t.trim()),e.normalize&&(t=t.replace(/\s+/g," ")),t}function I(e,t){return A(e),e.trackPosition&&(t+="\nLine: "+e.line+"\nColumn: "+e.column+"\nChar: "+e.c),e.error=t=Error(t),x(e,"onerror",t),e}function k(e){return e.sawRoot&&!e.closedRoot&&C(e,"Unclosed root tag"),e.state!==E.BEGIN&&e.state!==E.BEGIN_WHITESPACE&&e.state!==E.TEXT&&I(e,"Unexpected end"),A(e),e.c="",e.closed=!0,x(e,"onend"),l.call(e,e.strict,e.opt),e}function C(e,t){if("object"!=typeof e||!(e instanceof l))throw Error("bad call to strictFail");e.strict&&I(e,t)}function D(e,t){var r=0>e.indexOf(":")?["",e]:e.split(":"),i=r[0],n=r[1];return t&&"xmlns"===e&&(i="xmlns",n=""),{prefix:i,local:n}}function L(e){if(e.strict||(e.attribName=e.attribName[e.looseCase]()),-1!==e.attribList.indexOf(e.attribName)||e.tag.attributes.hasOwnProperty(e.attribName)){e.attribName=e.attribValue="";return}if(e.opt.xmlns){var t=D(e.attribName,!0),r=t.prefix,i=t.local;if("xmlns"===r)if("xml"===i&&e.attribValue!==d)C(e,"xml: prefix must be bound to "+d+"\nActual: "+e.attribValue);else if("xmlns"===i&&e.attribValue!==h)C(e,"xmlns: prefix must be bound to "+h+"\nActual: "+e.attribValue);else{var n=e.tag,s=e.tags[e.tags.length-1]||e;n.ns===s.ns&&(n.ns=Object.create(s.ns)),n.ns[i]=e.attribValue}e.attribList.push([e.attribName,e.attribValue])}else e.tag.attributes[e.attribName]=e.attribValue,w(e,"onattribute",{name:e.attribName,value:e.attribValue});e.attribName=e.attribValue=""}function O(e,t){if(e.opt.xmlns){var r=e.tag,i=D(e.tagName);r.prefix=i.prefix,r.local=i.local,r.uri=r.ns[i.prefix]||"",r.prefix&&!r.uri&&(C(e,"Unbound namespace prefix: "+JSON.stringify(e.tagName)),r.uri=i.prefix);var n=e.tags[e.tags.length-1]||e;r.ns&&n.ns!==r.ns&&Object.keys(r.ns).forEach(function(t){w(e,"onopennamespace",{prefix:t,uri:r.ns[t]})});for(var s=0,a=e.attribList.length;s<a;s++){var o=e.attribList[s],l=o[0],u=o[1],c=D(l,!0),d=c.prefix,h=c.local,f=""===d?"":r.ns[d]||"",p={name:l,value:u,prefix:d,local:h,uri:f};d&&"xmlns"!==d&&!f&&(C(e,"Unbound namespace prefix: "+JSON.stringify(d)),p.uri=d),e.tag.attributes[l]=
1p,w(e,"onattribute",p)}e.attribList.length=0}e.tag.isSelfClosing=!!t,e.sawRoot=!0,e.tags.push(e.tag),w(e,"onopentag",e.tag),t||(e.noscript||"script"!==e.tagName.toLowerCase()?e.state=E.TEXT:e.state=E.SCRIPT,e.tag=null,e.tagName=""),e.attribName=e.attribValue="",e.attribList.length=0}function P(e){if(!e.tagName){C(e,"Weird empty close tag."),e.textNode+="</>",e.state=E.TEXT;return}if(e.script){if("script"!==e.tagName){e.script+="</"+e.tagName+">",e.tagName="",e.state=E.SCRIPT;return}w(e,"onscript",e.script),e.script=""}var t=e.tags.length,r=e.tagName;e.strict||(r=r[e.looseCase]());for(var i=r;t--;)if(e.tags[t].name!==i)C(e,"Unexpected close tag");else break;if(t<0){C(e,"Unmatched closing tag: "+e.tagName),e.textNode+="</"+e.tagName+">",e.state=E.TEXT;return}e.tagName=r;for(var n=e.tags.length;n-- >t;){var s=e.tag=e.tags.pop();e.tagName=e.tag.name,w(e,"onclosetag",e.tagName);var a={};for(var o in s.ns)a[o]=s.ns[o];var l=e.tags[e.tags.length-1]||e;e.opt.xmlns&&s.ns!==l.ns&&Object.keys(s.ns).forEach(function(t){var r=s.ns[t];w(e,"onclosenamespace",{prefix:t,uri:r})})}0===t&&(e.closedRoot=!0),e.tagName=e.attribValue=e.attribName="",e.attribList.length=0,e.state=E.TEXT}function F(e,t){"<"===t?(e.state=E.OPEN_WAKA,e.startTagPosition=e.position):v(t)||(C(e,"Non-whitespace before first tag."),e.textNode=t,e.state=E.TEXT)}function N(e,t){var r="";return t<e.length&&(r=e.charAt(t)),r}E=t.STATE,String.fromCodePoint||(r=String.fromCharCode,n=Math.floor,s=function(){var e,t,i=[],s=-1,a=arguments.length;if(!a)return"";for(var o="";++s<a;){var l=Number(arguments[s]);if(!isFinite(l)||l<0||l>1114111||n(l)!==l)throw RangeError("Invalid code point: "+l);l<=65535?i.push(l):(l-=65536,e=(l>>10)+55296,t=l%1024+56320,i.push(e,t)),(s+1===a||i.length>16384)&&(o+=r.apply(null,i),i.length=0)}return o},Object.defineProperty?Object.defineProperty(String,"fromCodePoint",{value:s,configurable:!0,writable:!0}):String.fromCodePoint=s)}(r)},853065,(e,t,r)=>{(function(){"use strict";r.stripBOM=function(e){return"\uFEFF"===e[0]?e.substring(1):e}}).call(e.e)},175165,(e,t,r)=>{(function(){"use strict";var e;e=new RegExp(/(?!xmlns)^.*:/),r.normalize=function(e){return e.toLowerCase()},r.firstCharLowerCase=function(e){return e.charAt(0).toLowerCase()+e.slice(1)},r.stripPrefix=function(t){return t.replace(e,"")},r.parseNumbers=function(e){return isNaN(e)||(e=e%1==0?parseInt(e,10):parseFloat(e)),e},r.parseBooleans=function(e){return/^(?:true|false)$/i.test(e)&&(e="true"===e.toLowerCase()),e}}).call(e.e)},483986,(e,t,r)=>{var i=e.i(247167);"u">typeof __nccwpck_require__&&(__nccwpck_require__.ab="/ROOT/node_modules/next/dist/compiled/setimmediate/"),({189:function(){!function(e,t){"use strict";if(!e.setImmediate){var r,n,s,a,o,l=1,u={},c=!1,d=e.document,h=Object.getPrototypeOf&&Object.getPrototypeOf(e);h=h&&h.setTimeout?h:e,"[object process]"===({}).toString.call(e.process)?o=function(e){i.default.nextTick(function(){p(e)})}:function(){if(e.postMessage&&!e.importScripts){var t=!0,r=e.onmessage;return e.onmessage=function(){t=!1},e.postMessage("","*"),e.onmessage=r,t}}()?(r="setImmediate$"+Math.random()+"$",n=function(t){t.source===e&&"string"==typeof t.data&&0===t.data.indexOf(r)&&p(+t.data.slice(r.length))},e.addEventListener?e.addEventListener("message",n,!1):e.attachEvent("onmessage",n),o=function(t){e.postMessage(r+t,"*")}):e.MessageChannel?((s=new MessageChannel).port1.onmessage=function(e){p(e.data)},o=function(e){s.port2.postMessage(e)}):d&&"onreadystatechange"in d.createElement("script")?(a=d.documentElement,o=function(e){var t=d.createElement("script");t.onreadystatechange=function(){p(e),t.onreadystatechange=null,a.removeChild(t),t=null},a.appendChild(t)}):o=function(e){setTimeout(p,0,e)},h.setImmediate=function(e){"function"!=typeof e&&(e=Function(""+e));for(var t=Array(arguments.length-1),r=0;r<t.length;r++)t[r]=arguments[r+1];var i={callback:e,args:t};return u[l]=i,o(l),l++},h.clearImmediate=f}function f(e){delete u[e]}function p(e){if(c)setTimeout(p,0,e);else{var r=u[e];if(r){c=!0;try{var i=r.callback,n=r.args;switch(n.length){case 0:i();break;case 1:i(n[0]);break;case 2:i(n[0],n[1]);break;case 3:i(n[0],n[1],n[2]);break;default:i.apply(t,n)}}finally{f(e),c=!1}}}}}("u"<typeof self?e.g:self)}})[189](),t.exports={}},281574,(e,t,r)=>{var i={845:function(t,r,i){var n=e.g||"u">typeof self&&self||window,s=Function.prototype.apply;function a(e,t){this._id=e,this._clearFn=t}r.setTimeout=function(){return new a(s.call(setTimeout,n,arguments),clearTimeout)},r.setInterval=function(){return new a(s.call(setInterval,n,arguments),clearInterval)},r.clearTimeout=r.clearInterval=function(e){e&&e.close()},a.prototype.unref=a.prototype.ref=function(){},a.prototype.close=function(){this._clearFn.call(n,this._id)},r.enroll=function(e,t){clearTimeout(e._idleTimeoutId),e._idleTimeout=t},r.unenroll=function(e){clearTimeout(e._idleTimeoutId),e._idleTimeout=-1},r._unrefActive=r.active=function(e){clearTimeout(e._idleTimeoutId);var t=e._idleTimeout;t>=0&&(e._idleTimeoutId=setTimeout(function(){e._onTimeout&&e._onTimeout()},t))},i(505),r.setImmediate="u">typeof self&&self.setImmediate||e.g.setImmediate||this&&this.setImmediate,r.clearImmediate="u">typeof self&&self.clearImmediate||e.g.clearImmediate||this&&this.clearImmediate},505:function(t){"use strict";
1t.exports=e.r(483986)}},n={};function s(e){var t=n[e];if(void 0!==t)return t.exports;var r=n[e]={exports:{}},a=!0;try{i[e].call(r.exports,r,r.exports,s),a=!1}finally{a&&delete n[e]}return r.exports}s.ab="/ROOT/node_modules/next/dist/compiled/timers-browserify/",t.exports=s(845)},14607,(e,t,r)=>{(function(){"use strict";var t,i,n,s,a,o,l,u,c=function(e,t){return function(){return e.apply(t,arguments)}},d=function(e,t){for(var r in t)h.call(t,r)&&(e[r]=t[r]);function i(){this.constructor=e}return i.prototype=t.prototype,e.prototype=new i,e.__super__=t.prototype,e},h={}.hasOwnProperty;l=e.r(427323),s=e.r(430662),t=e.r(853065),o=e.r(175165),u=e.r(281574).setImmediate,i=e.r(927271).defaults,a=function(e,t,r){var i,n;for(i=0,n=e.length;i<n;i++)t=(0,e[i])(t,r);return t},n=function(e,t,r){var i;return(i=Object.create(null)).value=r,i.writable=!0,i.enumerable=!0,i.configurable=!0,Object.defineProperty(e,t,i)},r.Parser=function(e){function s(e){var t,n,s;if(this.parseStringPromise=c(this.parseStringPromise,this),this.parseString=c(this.parseString,this),this.reset=c(this.reset,this),this.assignOrPush=c(this.assignOrPush,this),this.processAsync=c(this.processAsync,this),!(this instanceof r.Parser))return new r.Parser(e);for(t in this.options={},n=i["0.2"])h.call(n,t)&&(s=n[t],this.options[t]=s);for(t in e)h.call(e,t)&&(s=e[t],this.options[t]=s);this.options.xmlns&&(this.options.xmlnskey=this.options.attrkey+"ns"),this.options.normalizeTags&&(this.options.tagNameProcessors||(this.options.tagNameProcessors=[]),this.options.tagNameProcessors.unshift(o.normalize)),this.reset()}return d(s,e),s.prototype.processAsync=function(){var e;try{if(this.remaining.length<=this.options.chunkSize)return e=this.remaining,this.remaining="",this.saxParser=this.saxParser.write(e),this.saxParser.close();return e=this.remaining.substr(0,this.options.chunkSize),this.remaining=this.remaining.substr(this.options.chunkSize,this.remaining.length),this.saxParser=this.saxParser.write(e),u(this.processAsync)}catch(e){if(!this.saxParser.errThrown)return this.saxParser.errThrown=!0,this.emit(e)}},s.prototype.assignOrPush=function(e,t,r){return t in e?(e[t]instanceof Array||n(e,t,[e[t]]),e[t].push(r)):this.options.explicitArray?n(e,t,[r]):n(e,t,r)},s.prototype.reset=function(){var e,t,r,i,s,o,u,c,d;return this.removeAllListeners(),this.saxParser=l.parser(this.options.strict,{trim:!1,normalize:!1,xmlns:this.options.xmlns}),this.saxParser.errThrown=!1,this.saxParser.onerror=(s=this,function(e){if(s.saxParser.resume(),!s.saxParser.errThrown)return s.saxParser.errThrown=!0,s.emit("error",e)}),this.saxParser.onend=(o=this,function(){if(!o.saxParser.ended)return o.saxParser.ended=!0,o.emit("end",o.resultObject)}),this.saxParser.ended=!1,this.EXPLICIT_CHARKEY=this.options.explicitCharkey,this.resultObject=null,i=[],e=this.options.attrkey,t=this.options.charkey,this.saxParser.onopentag=(u=this,function(r){var s,o,l,c,d;if((l={})[t]="",!u.options.ignoreAttrs)for(s in d=r.attributes)h.call(d,s)&&(e in l||u.options.mergeAttrs||(l[e]={}),o=u.options.attrValueProcessors?a(u.options.attrValueProcessors,r.attributes[s],s):r.attributes[s],c=u.options.attrNameProcessors?a(u.options.attrNameProcessors,s):s,u.options.mergeAttrs?u.assignOrPush(l,c,o):n(l[e],c,o));return l["#name"]=u.options.tagNameProcessors?a(u.options.tagNameProcessors,r.name):r.name,u.options.xmlns&&(l[u.options.xmlnskey]={uri:r.uri,local:r.local}),i.push(l)}),this.saxParser.onclosetag=(c=this,function(){var e,r,s,o,l,u,d,f,p,g,m;if(l=(u=i.pop())["#name"],c.options.explicitChildren&&c.options.preserveChildrenOrder||delete u["#name"],!0===u.cdata&&(e=u.cdata,delete u.cdata),p=i[i.length-1],u[t].match(/^\s*$/)&&!e?(r=u[t],delete u[t]):(c.options.trim&&(u[t]=u[t].trim()),c.options.normalize&&(u[t]=u[t].replace(/\s{2,}/g," ").trim()),u[t]=c.options.valueProcessors?a(c.options.valueProcessors,u[t],l):u[t],1===Object.keys(u).length&&t in u&&!c.EXPLICIT_CHARKEY&&(u=u[t])),"object"==typeof(m=u)&&null!=m&&0===Object.keys(m).length&&(u="function"==typeof c.options.emptyTag?c.options.emptyTag():""!==c.options.emptyTag?c.options.emptyTag:r),null!=c.options.validator&&(g="/"+(function(){var e,t,r;for(e=0,r=[],t=i.length;e<t;e++)o=i[e],r.push(o["#name"]);return r})().concat(l).join("/"),!function(){try{u=c.options.validator(g,p&&p[l],u)}catch(e){return c.emit("error",e)}}()),c.options.explicitChildren&&!c.options.mergeAttrs&&"object"==typeof u)if(c.options.preserveChildrenOrder){if(p){for(s in p[c.options.childkey]=p[c.options.childkey]||[],d={},u)h.call(u,s)&&n(d,s,u[s]);p[c.options.childkey].push(d),delete u["#name"],1===Object.keys(u).length&&t in u&&!c.EXPLICIT_CHARKEY&&(u=u[t])}}else o={},c.options.attrkey in u&&(o[c.options.attrkey]=u[c.options.attrkey],delete u[c.options.attrkey]),!c.options.charsAsChildren&&c.options.charkey in u&&(o[c.options.charkey]=u[c.options.charkey],delete u[c.options.charkey]),Object.getOwnPropertyNames(u).length>0&&(o[c.options.childkey]=u),u=o;return i.length>0?c.assignOrPush(p,l,u):(c.options.explicitRoot&&(f=u,n(u={},l,f)),c.resultObject=u,c.saxParser.ended=!0,c.emit("end",c.resultObject))}),d=this,r=function(e){var r,n;if(n=i[i.length-1])return n[t]+=e,d.options.explicitChildren&&d.options.preserveChildrenOrder&&d.options.charsAsChildren&&(d.options.includeWhiteChars||""!==e.replace(/\\n
1/g,"").trim())&&(n[d.options.childkey]=n[d.options.childkey]||[],(r={"#name":"__text__"})[t]=e,d.options.normalize&&(r[t]=r[t].replace(/\s{2,}/g," ").trim()),n[d.options.childkey].push(r)),n},this.saxParser.ontext=r,this.saxParser.oncdata=function(e){var t;if(t=r(e))return t.cdata=!0}},s.prototype.parseString=function(e,r){null!=r&&"function"==typeof r&&(this.on("end",function(e){return this.reset(),r(null,e)}),this.on("error",function(e){return this.reset(),r(e)}));try{if(e=e.toString(),""===e.trim())return this.emit("end",null),!0;if(e=t.stripBOM(e),this.options.async)return this.remaining=e,u(this.processAsync),this.saxParser;return this.saxParser.write(e).close()}catch(e){if(!(this.saxParser.errThrown||this.saxParser.ended))return this.emit("error",e),this.saxParser.errThrown=!0;if(this.saxParser.ended)throw e}},s.prototype.parseStringPromise=function(e){var t;return new Promise((t=this,function(r,i){return t.parseString(e,function(e,t){return e?i(e):r(t)})}))},s}(s),r.parseString=function(e,t,i){var n,s;return null!=i?("function"==typeof i&&(n=i),"object"==typeof t&&(s=t)):("function"==typeof t&&(n=t),s={}),new r.Parser(s).parseString(e,n)},r.parseStringPromise=function(e,t){var i;return"object"==typeof t&&(i=t),new r.Parser(i).parseStringPromise(e)}}).call(e.e)},398476,(e,t,r)=>{(function(){"use strict";var t,i,n,s,a=function(e,t){for(var r in t)o.call(t,r)&&(e[r]=t[r]);function i(){this.constructor=e}return i.prototype=t.prototype,e.prototype=new i,e.__super__=t.prototype,e},o={}.hasOwnProperty;i=e.r(927271),t=e.r(163811),n=e.r(14607),s=e.r(175165),r.defaults=i.defaults,r.processors=s,r.ValidationError=function(e){function t(e){this.message=e}return a(t,e),t}(Error),r.Builder=t.Builder,r.Parser=n.Parser,r.parseString=n.parseString,r.parseStringPromise=n.parseStringPromise}).call(e.e)},725652,(e,t,r)=>{"use strict";r.permuteDomain=function(e){return[e]}},400076,(e,t,r)=>{"use strict";var i="(?:25[0-5]|2[0-4][0-9]|1[0-9][0-9]|[1-9][0-9]|[0-9])(?:\\.(?:25[0-5]|2[0-4][0-9]|1[0-9][0-9]|[1-9][0-9]|[0-9])){3}",n="(?:(?:[0-9a-fA-F:]){1,4}(?:(?::(?:[0-9a-fA-F]){1,4}|:)){2,7})+",s=t.exports=function(e){return(e=e||{}).exact?RegExp("(?:^"+i+"$)|(?:^"+n+"$)"):RegExp("(?:"+i+")|(?:"+n+")","g")};s.v4=function(e){return(e=e||{}).exact?RegExp("^"+i+"$"):RegExp(i,"g")},s.v6=function(e){return(e=e||{}).exact?RegExp("^"+n+"$"):RegExp(n,"g")}},453960,(e,t,r)=>{"use strict";var i=e.r(400076),n=t.exports=function(e){return i({exact:!0}).test(e)};n.v4=function(e){return i.v4({exact:!0}).test(e)},n.v6=function(e){return i.v6({exact:!0}).test(e)}},343954,(e,t,r)=>{!function(){"use strict";var e={815:function(e){e.exports=function(e,r,i,n){r=r||"&",i=i||"=";var s={};if("string"!=typeof e||0===e.length)return s;var a=/\+/g;e=e.split(r);var o=1e3;n&&"number"==typeof n.maxKeys&&(o=n.maxKeys);var l=e.length;o>0&&l>o&&(l=o);for(var u=0;u<l;++u){var c,d,h,f,p=e[u].replace(a,"%20"),g=p.indexOf(i);(g>=0?(c=p.substr(0,g),d=p.substr(g+1)):(c=p,d=""),h=decodeURIComponent(c),f=decodeURIComponent(d),Object.prototype.hasOwnProperty.call(s,h))?t(s[h])?s[h].push(f):s[h]=[s[h],f]:s[h]=f}return s};var t=Array.isArray||function(e){return"[object Array]"===Object.prototype.toString.call(e)}},577:function(e){var t=function(e){switch(typeof e){case"string":return e;case"boolean":return e?"true":"false";case"number":return isFinite(e)?e:"";default:return""}};e.exports=function(e,s,a,o){return(s=s||"&",a=a||"=",null===e&&(e=void 0),"object"==typeof e)?i(n(e),function(n){var o=encodeURIComponent(t(n))+a;return r(e[n])?i(e[n],function(e){return o+encodeURIComponent(t(e))}).join(s):o+encodeURIComponent(t(e[n]))}).join(s):o?encodeURIComponent(t(o))+a+encodeURIComponent(t(e)):""};var r=Array.isArray||function(e){return"[object Array]"===Object.prototype.toString.call(e)};function i(e,t){if(e.map)return e.map(t);for(var r=[],i=0;i<e.length;i++)r.push(t(e[i],i));return r}var n=Object.keys||function(e){var t=[];for(var r in e)Object.prototype.hasOwnProperty.call(e,r)&&t.push(r);return t}}},r={};function i(t){var n=r[t];if(void 0!==n)return n.exports;var s=r[t]={exports:{}},a=!0;try{e[t](s,s.exports,i),a=!1}finally{a&&delete r[t]}return s.exports}i.ab="/ROOT/node_modules/next/dist/compiled/querystring-es3/";var n={};n.decode=n.parse=i(815),n.encode=n.stringify=i(577),t.exports=n}()},421342,(e,t,r)=>{var i={452:function(t){"use strict";
1t.exports=e.r(343954)}},n={};function s(e){var t=n[e];if(void 0!==t)return t.exports;var r=n[e]={exports:{}},a=!0;try{i[e](r,r.exports,s),a=!1}finally{a&&delete n[e]}return r.exports}s.ab="/ROOT/node_modules/next/dist/compiled/native-url/";var a={};!function(){var e,t=(e=s(452))&&"object"==typeof e&&"default"in e?e.default:e,r=/https?|ftp|gopher|file/;function i(e){"string"==typeof e&&(e=y(e));var i,n,s,a,o,l,u,c,d,h=(n=(i=e).auth,s=i.hostname,a=i.protocol||"",o=i.pathname||"",l=i.hash||"",u=i.query||"",c=!1,n=n?encodeURIComponent(n).replace(/%3A/i,":")+"@":"",i.host?c=n+i.host:s&&(c=n+(~s.indexOf(":")?"["+s+"]":s),i.port&&(c+=":"+i.port)),u&&"object"==typeof u&&(u=t.encode(u)),d=i.search||u&&"?"+u||"",a&&":"!==a.substr(-1)&&(a+=":"),i.slashes||(!a||r.test(a))&&!1!==c?(c="//"+(c||""),o&&"/"!==o[0]&&(o="/"+o)):c||(c=""),l&&"#"!==l[0]&&(l="#"+l),d&&"?"!==d[0]&&(d="?"+d),{protocol:a,host:c,pathname:o=o.replace(/[?#]/g,encodeURIComponent),search:d=d.replace("#","%23"),hash:l});return""+h.protocol+h.host+h.pathname+h.search+h.hash}var n="http://",o=n+"w.w",l=/^([a-z0-9.+-]*:\/\/\/)([a-z0-9.+-]:\/*)?/i,u=/https?|ftp|gopher|file/;function c(e,t){var r="string"==typeof e?y(e):e;e="object"==typeof e?i(e):e;var s=y(t),a="";r.protocol&&!r.slashes&&(a=r.protocol,e=e.replace(r.protocol,""),a+="/"===t[0]||"/"===e[0]?"/":""),a&&s.protocol&&(a="",s.slashes||(a=s.protocol,t=t.replace(s.protocol,"")));var c=e.match(l);c&&!s.protocol&&(e=e.substr((a=c[1]+(c[2]||"")).length),/^\/\/[^/]/.test(t)&&(a=a.slice(0,-1)));var d=new URL(e,o+"/"),h=new URL(t,d).toString().replace(o,""),f=s.protocol||r.protocol;return f+=r.slashes||s.slashes?"//":"",!a&&f?h=h.replace(n,f):a&&(h=h.replace(n,"")),u.test(h)||~t.indexOf(".")||"/"===e.slice(-1)||"/"===t.slice(-1)||"/"!==h.slice(-1)||(h=h.slice(0,-1)),a&&(h=a+("/"===h[0]?h.substr(1):h)),h}function d(){}d.prototype.parse=y,d.prototype.format=i,d.prototype.resolve=c,d.prototype.resolveObject=c;var h=/^https?|ftp|gopher|file/,f=/^(.*?)([#?].*)/,p=/^([a-z0-9.+-]*:)(\/{0,3})(.*)/i,g=/^([a-z0-9.+-]*:)?\/\/\/*/i,m=/^([a-z0-9.+-]*:)(\/{0,2})\[(.*)\]$/i;function y(e,r,n){if(void 0===r&&(r=!1),void 0===n&&(n=!1),e&&"object"==typeof e&&e instanceof d)return e;var s=(e=e.trim()).match(f);e=s?s[1].replace(/\\/g,"/")+s[2]:e.replace(/\\/g,"/"),m.test(e)&&"/"!==e.slice(-1)&&(e+="/");var a=!/(^javascript)/.test(e)&&e.match(p),l=g.test(e),u="";a&&(h.test(a[1])||(u=a[1].toLowerCase(),e=""+a[2]+a[3]),a[2]||(l=!1,h.test(a[1])?(u=a[1],e=""+a[3]):e="//"+a[3]),3!==a[2].length&&1!==a[2].length||(u=a[1],e="/"+a[3]));var c,y=(s?s[1]:e).match(/^https?:\/\/[^/]+(:[0-9]+)(?=\/|$)/),v=y&&y[1],b=new d,_="",E="";try{c=new URL(e)}catch(t){_=t,u||n||!/^\/\//.test(e)||/^\/\/.+[@.]/.test(e)||(E="/",e=e.substr(1));try{c=new URL(e,o)}catch(e){return b.protocol=u,b.href=u,b}}b.slashes=l&&!E,b.host="w.w"===c.host?"":c.host,b.hostname="w.w"===c.hostname?"":c.hostname.replace(/(\[|\])/g,""),b.protocol=_?u||null:c.protocol,b.search=c.search.replace(/\\/g,"%5C"),b.hash=c.hash.replace(/\\/g,"%5C");var S=e.split("#");!b.search&&~S[0].indexOf("?")&&(b.search="?"),b.hash||""!==S[1]||(b.hash="#"),b.query=r?t.decode(c.search.substr(1)):b.search.substr(1),b.pathname=E+(a?c.pathname.replace(/['^|`]/g,function(e){return"%"+e.charCodeAt().toString(16).toUpperCase()}).replace(/((?:%[0-9A-F]{2})+)/g,function(e,t){try{return decodeURIComponent(t).split("").map(function(e){var t=e.charCodeAt();return t>256||/^[a-z0-9]$/i.test(e)?e:"%"+t.toString(16).toUpperCase()}).join("")}catch(e){return t}}):c.pathname),"about:"===b.protocol&&"blank"===b.pathname&&(b.protocol="",b.pathname=""),_&&"/"!==e[0]&&(b.pathname=b.pathname.substr(1)),u&&!h.test(u)&&"/"!==e.slice(-1)&&"/"===b.pathname&&(b.pathname=""),b.path=b.pathname+b.search,b.auth=[c.username,c.password].map(decodeURIComponent).filter(Boolean).join(":"),b.port=c.port,v&&!b.host.endsWith(v)&&(b.host+=v,b.port=v.slice(1)),b.href=E?""+b.pathname+b.search+b.hash:i(b);var x=/^(file)/.test(b.href)?["host","hostname"]:[];return Object.keys(b).forEach(function(e){~x.indexOf(e)||(b[e]=b[e]||null)}),b}a.parse=y,a.format=i,a.resolve=c,a.resolveObject=function(e,t){return y(c(e,t))},a.Url=d}(),t.exports=a},397945,(e,t,r)=>{"use strict";function i(){}r.Store=i,i.prototype.synchronous=!1,i.prototype.findCookie=function(e,t,r,i){throw Error("findCookie is not implemented")}
1,i.prototype.findCookies=function(e,t,r){throw Error("findCookies is not implemented")},i.prototype.putCookie=function(e,t){throw Error("putCookie is not implemented")},i.prototype.updateCookie=function(e,t,r){throw Error("updateCookie is not implemented")},i.prototype.removeCookie=function(e,t,r,i){throw Error("removeCookie is not implemented")},i.prototype.removeCookies=function(e,t,r){throw Error("removeCookies is not implemented")},i.prototype.getAllCookies=function(e){throw Error("getAllCookies is not implemented (therefore jar cannot be serialized)")}},71625,(e,t,r)=>{"use strict";r.pathMatch=function(e,t){return t===e||0===e.indexOf(t)&&("/"===t.substr(-1)||"/"===e.substr(t.length,1))||!1}},451482,(e,t,r)=>{"use strict";var i=e.r(397945).Store,n=e.r(725652).permuteDomain,s=e.r(71625).pathMatch,a=e.r(477398);function o(){i.call(this),this.idx={}}a.inherits(o,i),r.MemoryCookieStore=o,o.prototype.idx=null,o.prototype.synchronous=!0,o.prototype.inspect=function(){return"{ idx: "+a.inspect(this.idx,!1,2)+" }"},o.prototype.findCookie=function(e,t,r,i){return i(null,this.idx[e]&&this.idx[e][t]?this.idx[e][t][r]||null:void 0)},o.prototype.findCookies=function(e,t,r){var i,a=[];if(!e)return r(null,[]);i=t?function(e){Object.keys(e).forEach(function(r){if(s(t,r)){var i=e[r];for(var n in i)a.push(i[n])}})}:function(e){for(var t in e){var r=e[t];for(var i in r)a.push(r[i])}};var o=n(e)||[e],l=this.idx;o.forEach(function(e){var t=l[e];t&&i(t)}),r(null,a)},o.prototype.putCookie=function(e,t){this.idx[e.domain]||(this.idx[e.domain]={}),this.idx[e.domain][e.path]||(this.idx[e.domain][e.path]={}),this.idx[e.domain][e.path][e.key]=e,t(null)},o.prototype.updateCookie=function(e,t,r){this.putCookie(t,r)},o.prototype.removeCookie=function(e,t,r,i){this.idx[e]&&this.idx[e][t]&&this.idx[e][t][r]&&delete this.idx[e][t][r],i(null)},o.prototype.removeCookies=function(e,t,r){return this.idx[e]&&(t?delete this.idx[e][t]:delete this.idx[e]),r(null)},o.prototype.getAllCookies=function(e){var t=[],r=this.idx;Object.keys(r).forEach(function(e){Object.keys(r[e]).forEach(function(i){Object.keys(r[e][i]).forEach(function(n){null!==n&&t.push(r[e][i][n])})})}),t.sort(function(e,t){return(e.creationIndex||0)-(t.creationIndex||0)}),e(null,t)}},898481,(e,t,r)=>{t.exports={author:{name:"Jonny Burger",email:"[email protected]",website:"http://jonny.io"},contributors:[],license:"BSD-3-Clause",name:"tough-cookie-no-native",description:"'tough-cookie' with no native dependencies",keywords:["HTTP","cookie","cookies","set-cookie","cookiejar","jar","RFC6265","RFC2965"],version:"2.4.1",homepage:"https://github.com/JonnyBurger/tough-cookie-no-native",repository:{type:"git",url:"git://github.com/JonnyBurger/tough-cookie-no-native.git"},bugs:{url:"https://github.com/JonnyBurger/tough-cookie-no-native/issues"},main:"./lib/cookie",files:["lib"],scripts:{suffixup:"curl -o public_suffix_list.dat https://publicsuffix.org/list/public_suffix_list.dat && ./generate-pubsuffix.js",test:"vows test/*_test.js"},engines:{node:">=0.10.0"},devDependencies:{async:"^1.4.2",vows:"^0.8.1"},dependencies:{"is-ip":"^1.0.0",url:"^0.11.0"}}},676027,e=>{"use strict";let t=/^xn--/,r=/[^\0-\x7F]/,i=/[\x2E\u3002\uFF0E\uFF61]/g,n={overflow:"Overflow: input needs wider integers to process","not-basic":"Illegal input >= 0x80 (not a basic code point)","invalid-input":"Invalid input"},s=Math.floor,a=String.fromCharCode;function o(e){throw RangeError(n[e])}function l(e,t){let r=e.split("@"),n="";return r.length>1&&(n=r[0]+"@",e=r[1]),n+(function(e,t){let r=[],i=e.length;for(;i--;)r[i]=t(e[i]);return r})((e=e.replace(i,".")).split("."),t).join(".")}function u(e){let t=[],r=0,i=e.length;for(;r<i;){let n=e.charCodeAt(r++);if(n>=55296&&n<=56319&&r<i){let i=e.charCodeAt(r++);(64512&i)==56320?t.push(((1023&n)<<10)+(1023&i)+65536):(t.push(n),r--)}else t.push(n)}return t}let c=e=>String.fromCodePoint(...e),d=function(e,t){return e+22+75*(e<26)-((0!=t)<<5)},h=function(e,t,r){let i=0;for(e=r?s(e/700):e>>1,e+=s(e/t);e>455;i+=36)e=s(e/35);return s(i+36*e/(e+38))},f=function(e){let t=[],r=e.length,i=0,n=128,a=72,l=e.lastIndexOf("-");l<0&&(l=0);for(let r=0;r<l;++r)e.charCodeAt(r)>=128&&o("not-basic"),t.push(e.charCodeAt(r));for(let c=l>0?l+1:0;c<r;){let l=i;for(let t=1,n=36;;n+=36){var u;c>=r&&o("invalid-input");let l=(u=e.charCodeAt(c++))>=48&&u<58?26+(u-48):u>=65&&u<91?u-65:u>=97&&u<123?u-97:36;l>=36&&o("invalid-input"),l>s((0x7fffffff-i)/t)&&o("overflow"),i+=l*t;let d=n<=a?1:n>=a+26?26:n-a;if(l<d)break;let h=36-d;t>s(0x7fffffff/h)&&o("overflow"),t*=h}let d=t.length+1;a=h(i-l,d,0==l),s(i/d)>0x7fffffff-n&&o("overflow"),n+=s(i/d),i%=d,t.splice(i++,0,n)}return String.fromCodePoint(...t)}
1,p=function(e){let t=[],r=(e=u(e)).length,i=128,n=0,l=72;for(let r of e)r<128&&t.push(a(r));let c=t.length,f=c;for(c&&t.push("-");f<r;){let r=0x7fffffff;for(let t of e)t>=i&&t<r&&(r=t);let u=f+1;for(let p of(r-i>s((0x7fffffff-n)/u)&&o("overflow"),n+=(r-i)*u,i=r,e))if(p<i&&++n>0x7fffffff&&o("overflow"),p===i){let e=n;for(let r=36;;r+=36){let i=r<=l?1:r>=l+26?26:r-l;if(e<i)break;let n=e-i,o=36-i;t.push(a(d(i+n%o,0))),e=s(n/o)}t.push(a(d(e,0))),l=h(n,u,f===c),n=0,++f}++n,++i}return t.join("")},g=function(e){return l(e,function(e){return t.test(e)?f(e.slice(4).toLowerCase()):e})},m=function(e){return l(e,function(e){return r.test(e)?"xn--"+p(e):e})};e.s(["decode",0,f,"default",0,{version:"2.3.1",ucs2:{decode:u,encode:c},decode:f,encode:p,toASCII:m,toUnicode:g},"encode",0,p,"toASCII",0,m,"toUnicode",0,g,"ucs2decode",0,u,"ucs2encode",0,c])},844877,(e,t,r)=>{"use strict";var i,n=e.r(453960),s=e.r(421342).parse,a=e.r(397945).Store,o=e.r(451482).MemoryCookieStore,l=e.r(71625).pathMatch,u=e.r(898481).version;try{i=e.r(676027)}catch(e){console.warn("cookie: can't load punycode; won't use punycode for domain normalization")}var c=/[\x09\x20-\x2F\x3B-\x40\x5B-\x60\x7B-\x7E]/,d=RegExp("^"+/[\x21\x23-\x2B\x2D-\x3A\x3C-\x5B\x5D-\x7E]/.source+"+$"),h=/[\x00-\x1F]/,f=/^(([^=;]+))\s*=\s*([^\n\r\0]*)/,p=/^((?:=)?([^=;]*)\s*=\s*)?([^\n\r\0]*)/,g=/[\x20-\x3A\x3C-\x7E]+/,m=/;+$/,y=/^(\d{1,2})[^\d]*$/,v=/^(\d{1,2})[^\d]*:(\d{1,2})[^\d]*:(\d{1,2})[^\d]*$/,b=/^(Jan|Feb|Mar|Apr|May|Jun|Jul|Aug|Sep|Oct|Nov|Dec)/i,_={jan:0,feb:1,mar:2,apr:3,may:4,jun:5,jul:6,aug:7,sep:8,oct:9,nov:10,dec:11},E=["Jan","Feb","Mar","Apr","May","Jun","Jul","Aug","Sep","Oct","Nov","Dec"],S=["Sun","Mon","Tue","Wed","Thu","Fri","Sat"],x=/^(\d{2}|\d{4})$/;function T(e){if(e){var t=e.split(c);if(t){for(var r=null,i=null,n=null,s=null,a=null,o=null,l=0;l<t.length;l++){var u,d=t[l].trim();if(d.length){if(null===n&&(u=v.exec(d))){if(r=parseInt(u[1],10),i=parseInt(u[2],10),n=parseInt(u[3],10),r>23||i>59||n>59)return;continue}if(null===s&&(u=y.exec(d))){if((s=parseInt(u,10))<1||s>31)return;continue}if(null===a&&(u=b.exec(d))){a=_[u[1].toLowerCase()];continue}if(null===o&&(u=x.exec(d))&&(70<=(o=parseInt(u[0],10))&&o<=99?o+=1900:0<=o&&o<=69&&(o+=2e3),o<1601))return}}if(null!==n&&null!==s&&null!==a&&null!==o)return new Date(Date.UTC(o,a,s,r,i,n))}}}function w(e){var t=e.getUTCDate();t=t>=10?t:"0"+t;var r=e.getUTCHours();r=r>=10?r:"0"+r;var i=e.getUTCMinutes();i=i>=10?i:"0"+i;var n=e.getUTCSeconds();return n=n>=10?n:"0"+n,S[e.getUTCDay()]+", "+t+" "+E[e.getUTCMonth()]+" "+e.getUTCFullYear()+" "+r+":"+i+":"+n+" GMT"}function A(e){return null==e?null:(e=e.trim().replace(/^\./,""),i&&/[^\u0001-\u007f]/.test(e)&&(e=i.toASCII(e)),e.toLowerCase())}function R(e,t,r){if(null==e||null==t)return null;if(!1!==r&&(e=A(e),t=A(t)),e==t)return!0;if(n(e))return!1;var i=e.indexOf(t);return!(i<=0)&&e.length===t.length+i&&"."===e.substr(i-1,1)}function I(e){if(!e||"/"!==e.substr(0,1))return"/";if("/"===e)return e;var t=e.lastIndexOf("/");return 0===t?"/":e.slice(0,t)}function k(e,t){t&&"object"==typeof t||(t={}),e=e.trim();var r=m.exec(e);r&&(e=e.slice(0,r.index));var i=e.indexOf(";"),n=(t.loose?p:f).exec(-1===i?e:e.substr(0,i));if(n){var s=new P;if(n[1]?s.key=n[2].trim():s.key="",s.value=n[3].trim(),!(h.test(s.key)||h.test(s.value))){if(-1===i)return s;var a=e.slice(i).replace(/^\s*;\s*/,"").trim();if(0===a.length)return s;for(var o=a.split(/\s*;\s*/);o.length;){var l,u,c=o.shift(),d=c.indexOf("=");switch(-1===d?(l=c,u=null):(l=c.substr(0,d),u=c.substr(d+1)),l=l.trim().toLowerCase(),u&&(u=u.trim()),l){case"expires":if(u){var g=T(u);g&&(s.expires=g)}break;case"max-age":if(u&&/^-?[0-9]+$/.test(u)){var y=parseInt(u,10);s.setMaxAge(y)}break;case"domain":if(u){var v=u.trim().replace(/^\./,"");v&&(s.domain=v.toLowerCase())}break;case"path":s.path=u&&"/"===u[0]?u:null;break;case"secure":s.secure=!0;break;case"httponly":s.httpOnly=!0;break;default:s.extensions=s.extensions||[],s.extensions.push(c)}}return s}}}function C(e){var t;try{t=JSON.parse(e)}catch(e){return e}return t}function D(e){if(!e)return null;if("string"==typeof e){if((t=C(e))instanceof Error)return null}else t=e;for(var t,r=new P,i=0;i<P.serializableProperties.length;i++){var n=P.serializableProperties[i];void 0!==t[n]&&t[n]!==P.prototype[n]&&("expires"===n||"creation"===n||"lastAccessed"===n?null===t[n]?r[n]=null:r[n]="Infinity"==t[n]?"Infinity":new Date(t[n]):r[n]=t[n])}return r}function L(e,t){var r=0,i=e.path?e.path.length:0;return 0!=(r=(t.path?t.path.length:0)-i)?r:0!=(r=(e.creation?e.creation.getTime():2147483647e3)-(t.creation?t.creation.getTime():2147483647e3))?r:r=e.creationIndex-t.creationIndex}function O(e){if(e instanceof Object)return e;try{e=decodeURI(e)}catch(e){}return s(e)}function P(e){Object.keys(e=e||{}
1).forEach(function(t){P.prototype.hasOwnProperty(t)&&P.prototype[t]!==e[t]&&"_"!==t.substr(0,1)&&(this[t]=e[t])},this),this.creation=this.creation||new Date,Object.defineProperty(this,"creationIndex",{configurable:!1,enumerable:!1,writable:!0,value:++P.cookiesCreated})}function F(e,t){"boolean"==typeof t?t={rejectPublicSuffixes:t}:null==t&&(t={}),null!=t.rejectPublicSuffixes&&(this.rejectPublicSuffixes=t.rejectPublicSuffixes),null!=t.looseMode&&(this.enableLooseMode=t.looseMode),e||(e=new o),this.store=e}P.cookiesCreated=0,P.parse=k,P.fromJSON=D,P.prototype.key="",P.prototype.value="",P.prototype.expires="Infinity",P.prototype.maxAge=null,P.prototype.domain=null,P.prototype.path=null,P.prototype.secure=!1,P.prototype.httpOnly=!1,P.prototype.extensions=null,P.prototype.hostOnly=null,P.prototype.pathIsDefault=null,P.prototype.creation=null,P.prototype.lastAccessed=null,Object.defineProperty(P.prototype,"creationIndex",{configurable:!0,enumerable:!1,writable:!0,value:0}),P.serializableProperties=Object.keys(P.prototype).filter(function(e){return!(P.prototype[e]instanceof Function||"creationIndex"===e||"_"===e.substr(0,1))}),P.prototype.inspect=function(){var e=Date.now();return'Cookie="'+this.toString()+"; hostOnly="+(null!=this.hostOnly?this.hostOnly:"?")+"; aAge="+(this.lastAccessed?e-this.lastAccessed.getTime()+"ms":"?")+"; cAge="+(this.creation?e-this.creation.getTime()+"ms":"?")+'"'},P.prototype.toJSON=function(){for(var e={},t=P.serializableProperties,r=0;r<t.length;r++){var i=t[r];this[i]!==P.prototype[i]&&("expires"===i||"creation"===i||"lastAccessed"===i?null===this[i]?e[i]=null:e[i]="Infinity"==this[i]?"Infinity":this[i].toISOString():"maxAge"===i?null!==this[i]&&(e[i]=this[i]==1/0||this[i]==-1/0?this[i].toString():this[i]):this[i]!==P.prototype[i]&&(e[i]=this[i]))}return e},P.prototype.clone=function(){return D(this.toJSON())},P.prototype.validate=function(){if(!d.test(this.value)||this.expires!=1/0&&!(this.expires instanceof Date)&&!T(this.expires)||null!=this.maxAge&&this.maxAge<=0||null!=this.path&&!g.test(this.path))return!1;var e=this.cdomain();return!(e&&e.match(/\.$/))},P.prototype.setExpires=function(e){e instanceof Date?this.expires=e:this.expires=T(e)||"Infinity"},P.prototype.setMaxAge=function(e){e===1/0||e===-1/0?this.maxAge=e.toString():this.maxAge=e},P.prototype.cookieString=function(){var e=this.value;return(null==e&&(e=""),""===this.key)?e:this.key+"="+e},P.prototype.toString=function(){var e=this.cookieString();return this.expires!=1/0&&(this.expires instanceof Date?e+="; Expires="+w(this.expires):e+="; Expires="+this.expires),null!=this.maxAge&&this.maxAge!=1/0&&(e+="; Max-Age="+this.maxAge),this.domain&&!this.hostOnly&&(e+="; Domain="+this.domain),this.path&&(e+="; Path="+this.path),this.secure&&(e+="; Secure"),this.httpOnly&&(e+="; HttpOnly"),this.extensions&&this.extensions.forEach(function(t){e+="; "+t}),e},P.prototype.TTL=function(e){if(null!=this.maxAge)return this.maxAge<=0?0:1e3*this.maxAge;var t=this.expires;return t!=1/0?(t instanceof Date||(t=T(t)||1/0),t==1/0)?1/0:t.getTime()-(e||Date.now()):1/0},P.prototype.expiryTime=function(e){if(null!=this.maxAge){var t=e||this.creation||new Date,r=this.maxAge<=0?-1/0:1e3*this.maxAge;return t.getTime()+r}return this.expires==1/0?1/0:this.expires.getTime()},P.prototype.expiryDate=function(e){var t=this.expiryTime(e);return new Date(t==1/0?2147483647e3:t==-1/0?0:t)},P.prototype.isPersistent=function(){return null!=this.maxAge||this.expires!=1/0},P.prototype.cdomain=P.prototype.canonicalizedDomain=function(){return null==this.domain?null:A(this.domain)},F.prototype.store=null,F.prototype.rejectPublicSuffixes=!0,F.prototype.enableLooseMode=!1;var N=[];N.push("setCookie"),F.prototype.setCookie=function(e,t,r,i){var n,s=O(t);r instanceof Function&&(i=r,r={});var a=A(s.hostname),o=this.enableLooseMode;if(null!=r.loose&&(o=r.loose),e instanceof P||(e=P.parse(e,{loose:o})),!e)return n=Error("Cookie failed to parse"),i(r.ignoreError?null:n);var l=r.now||new Date;if(e.domain){if(!R(a,e.cdomain(),!1))return n=Error("Cookie not in this host's domain. Cookie:"+e.cdomain()+" Request:"+a),i(r.ignoreError?null:n);null==e.hostOnly&&(e.hostOnly=!1)}else e.hostOnly=!0,e.domain=a;if(e.path&&"/"===e.path[0]||(e.path=I(s.pathname),e.pathIsDefault=!0),!1===r.http&&e.httpOnly)return n=Error("Cookie is HttpOnly and this isn't an HTTP API"),i(r.ignoreError?null:n);var u=this.store;u.updateCookie||(u.updateCookie=function(e,t,r){this.putCookie(t,r)}),u.findCookie(e.domain,e.path,e.key,function(t,n){if(t)return i(t);var s=function(t){if(t)return i(t);i(null,e)};
1if(n){if(!1===r.http&&n.httpOnly)return t=Error("old Cookie is HttpOnly and this isn't an HTTP API"),i(r.ignoreError?null:t);e.creation=n.creation,e.creationIndex=n.creationIndex,e.lastAccessed=l,u.updateCookie(n,e,s)}else e.creation=e.lastAccessed=l,u.putCookie(e,s)})},N.push("getCookies"),F.prototype.getCookies=function(e,t,r){var i=O(e);t instanceof Function&&(r=t,t={});var n=A(i.hostname),s=i.pathname||"/",a=t.secure;null==a&&i.protocol&&("https:"==i.protocol||"wss:"==i.protocol)&&(a=!0);var o=t.http;null==o&&(o=!0);var u=t.now||Date.now(),c=!1!==t.expire,d=!!t.allPaths,h=this.store;function f(e){if(e.hostOnly){if(e.domain!=n)return!1}else if(!R(n,e.domain,!1))return!1;return(!!d||!!l(s,e.path))&&(!e.secure||!!a)&&(!e.httpOnly||!!o)&&(!(c&&e.expiryTime()<=u)||(h.removeCookie(e.domain,e.path,e.key,function(){}),!1))}h.findCookies(n,d?null:s,function(e,i){if(e)return r(e);i=i.filter(f),!1!==t.sort&&(i=i.sort(L));var n=new Date;i.forEach(function(e){e.lastAccessed=n}),r(null,i)})},N.push("getCookieString"),F.prototype.getCookieString=function(){var e=Array.prototype.slice.call(arguments,0),t=e.pop();e.push(function(e,r){e?t(e):t(null,r.sort(L).map(function(e){return e.cookieString()}).join("; "))}),this.getCookies.apply(this,e)},N.push("getSetCookieStrings"),F.prototype.getSetCookieStrings=function(){var e=Array.prototype.slice.call(arguments,0),t=e.pop();e.push(function(e,r){e?t(e):t(null,r.map(function(e){return e.toString()}))}),this.getCookies.apply(this,e)},N.push("serialize"),F.prototype.serialize=function(e){var t=this.store.constructor.name;"Object"===t&&(t=null);var r={version:"tough-cookie@"+u,storeType:t,rejectPublicSuffixes:!!this.rejectPublicSuffixes,cookies:[]};if(!(this.store.getAllCookies&&"function"==typeof this.store.getAllCookies))return e(Error("store does not support getAllCookies and cannot be serialized"));this.store.getAllCookies(function(t,i){return t?e(t):(r.cookies=i.map(function(e){return e=e instanceof P?e.toJSON():e,delete e.creationIndex,e}),e(null,r))})},F.prototype.toJSON=function(){return this.serializeSync()},N.push("_importCookies"),F.prototype._importCookies=function(e,t){var r=this,i=e.cookies;if(!i||!Array.isArray(i))return t(Error("serialized jar has no cookies array"));!function e(n){var s;if(n)return t(n);if(!i.length)return t(n,r);try{s=D(i.shift())}catch(e){return t(e)}if(null===s)return e(null);r.store.putCookie(s,e)}()},F.deserialize=function(e,t,r){if(3!=arguments.length&&(r=t,t=null),"string"==typeof e){if((i=C(e))instanceof Error)return r(i)}else i=e;var i,n=new F(t,i.rejectPublicSuffixes);n._importCookies(i,function(e){if(e)return r(e);r(null,n)})},F.deserializeSync=function(e,t){var r="string"==typeof e?JSON.parse(e):e,i=new F(t,r.rejectPublicSuffixes);if(!i.store.synchronous)throw Error("CookieJar store is not synchronous; use async API instead.");return i._importCookiesSync(r),i},F.fromJSON=F.deserializeSync,N.push("clone"),F.prototype.clone=function(e,t){1==arguments.length&&(t=e,e=null),this.serialize(function(r,i){if(r)return t(r);F.deserialize(e,i,t)})},N.forEach(function(e){F.prototype[e+"Sync"]=function(){if(!this.store.synchronous)throw Error("CookieJar store is not synchronous; use async API instead.");var t,r,i=Array.prototype.slice.call(arguments);if(i.push(function(e,i){t=e,r=i}),this[e].apply(this,i),t)throw t;return r}}),t.exports={CookieJar:F,Cookie:P,Store:a,MemoryCookieStore:o,parseDate:T,formatDate:w,parse:k,fromJSON:D,domainMatch:R,defaultPath:I,pathMatch:l,cookieCompare:L,permuteDomain:e.r(725652).permuteDomain,permutePath:function(e){if("/"===e)return["/"];e.lastIndexOf("/")===e.length-1&&(e=e.substr(0,e.length-1));for(var t=[e];e.length>1;){var r=e.lastIndexOf("/");if(0===r)break;e=e.substr(0,r),t.push(e)}return t.push("/"),t},canonicalDomain:A}},408717,e=>{"use strict";var t=e.i(412675),r=e.i(581949),i=e.i(372907),n=e.i(398476),s=e.i(844877),a=e.i(822315);let o="globalInfo",l="loginEmail",u=new n.Parser({strict:!1,trim:!0});function c(){let e=t.get(o);return"undefined"!==e?e:void 0}function d(){let e=c();return e?.ACCOUNTINFO[0].AUTHORIZED[0]==="true"}async function h(){try{let e=await r.default.get(i.COLOSSEUM_GLOBALINFO_BASEURL+"globalinfo?full=1&mrsid="+i.COLOSSEUM_MRSID,{withCredentials:!0});return new Promise(r=>{u.parseString(e.data,(e,i)=>{var n;let s=t.get(o);i&&(!s||JSON.stringify(s)!==JSON.stringify(i.GLOBALINFO))?(n=i.GLOBALINFO,t.set(o,n),d()||function(){"u">typeof document&&(t.remove(l),document.cookie=l+"=; expires=Thu, 01 Jan 1970 00:00:01 GMT;")}(),r(i.GLOBALINFO)):r(void 0)})})}catch(e){console.error("Cannot get login information")}}e.s(["getAccountUrl",0,function(){let e=c();return e?.URLINFO[0].ORDERLIST[0]||""},"getCartItemCount",0,function(){let e=c();return Number(e?.CARTINFO[0].COUNT[0])},"getCartPrice",0,function(){let e=c();return Number(e?.CARTINFO[0].PRICE[0])},"getCartUrl",0,function(){let e=c();return e?.URLINFO[0].CART[0]||""},"getGlobalInfo",0,c,"getPrioritySaleShift",0,function(){let e=c(),t=e?.ACCOUNTINFO[0].LOYALTYPROGRAM;if(t){let e=t.reduce((e,t)=>
1{let r=t.ITEMS;if(r){let t=r.reduce((t,r)=>{let i=r.ITEM;if(i){let t=i[0].SHARINGSHIFT;if(t){let r=parseInt(t[0]||"0");if(r>e)return r}}return t},0);if(t>e)return t}return e},0);return e>365?Math.floor(e/1440):e}return 0},"getUserFullName",0,function(){let e=c();return e?.ACCOUNTINFO[0].NAME[0]||""},"isUserAuthorized",0,d,"loadGlobalInfo",0,h,"setUserEmail",0,function(e){if("u"<typeof document)return;t.set(l,e);let r=new s.Cookie({key:l,value:e,expires:(0,a.default)().add(30,"days").toDate(),httpOnly:!1,secure:"https"===window.location.protocol,path:"/"});document.cookie=r.toString()}])},915874,954402,e=>{"use strict";function t(e,r){return(t=Object.setPrototypeOf?Object.setPrototypeOf.bind():function(e,t){return e.__proto__=t,e})(e,r)}e.s(["default",0,function(e,t){if(null==e)return{};var r={};for(var i in e)if(({}).hasOwnProperty.call(e,i)){if(-1!==t.indexOf(i))continue;r[i]=e[i]}return r}],915874),e.s(["default",0,function(e,r){e.prototype=Object.create(r.prototype),e.prototype.constructor=e,t(e,r)}],954402)},585642,151480,e=>{"use strict";e.i(247167);var t=e.i(915874),r=e.i(954402),i=e.i(271645),n=e.i(174080);let s=i.default.createContext(null);var a=function(e){return e.scrollTop};e.s(["forceReflow",0,a],151480);var o="unmounted",l="exited",u="entering",c="entered",d="exiting",h=function(e){function h(t,r){var i,n=e.call(this,t,r)||this,s=r&&!r.isMounting?t.enter:t.appear;return n.appearStatus=null,t.in?s?(i=l,n.appearStatus=u):i=c:i=t.unmountOnExit||t.mountOnEnter?o:l,n.state={status:i},n.nextCallback=null,n}(0,r.default)(h,e),h.getDerivedStateFromProps=function(e,t){return e.in&&t.status===o?{status:l}:null};var f=h.prototype;return f.componentDidMount=function(){this.updateStatus(!0,this.appearStatus)},f.componentDidUpdate=function(e){var t=null;if(e!==this.props){var r=this.state.status;this.props.in?r!==u&&r!==c&&(t=u):(r===u||r===c)&&(t=d)}this.updateStatus(!1,t)},f.componentWillUnmount=function(){this.cancelNextCallback()},f.getTimeouts=function(){var e,t,r,i=this.props.timeout;return e=t=r=i,null!=i&&"number"!=typeof i&&(e=i.exit,t=i.enter,r=void 0!==i.appear?i.appear:t),{exit:e,enter:t,appear:r}},f.updateStatus=function(e,t){if(void 0===e&&(e=!1),null!==t)if(this.cancelNextCallback(),t===u){if(this.props.unmountOnExit||this.props.mountOnEnter){var r=this.props.nodeRef?this.props.nodeRef.current:n.default.findDOMNode(this);r&&a(r)}this.performEnter(e)}else this.performExit();else this.props.unmountOnExit&&this.state.status===l&&this.setState({status:o})},f.performEnter=function(e){var t=this,r=this.props.enter,i=this.context?this.context.isMounting:e,s=this.props.nodeRef?[i]:[n.default.findDOMNode(this),i],a=s[0],o=s[1],l=this.getTimeouts(),d=i?l.appear:l.enter;(e||r)&&1?(this.props.onEnter(a,o),this.safeSetState({status:u},function(){t.props.onEntering(a,o),t.onTransitionEnd(d,function(){t.safeSetState({status:c},function(){t.props.onEntered(a,o)})})})):this.safeSetState({status:c},function(){t.props.onEntered(a)})},f.performExit=function(){var e=this,t=this.props.exit,r=this.getTimeouts(),i=this.props.nodeRef?void 0:n.default.findDOMNode(this);t?(this.props.onExit(i),this.safeSetState({status:d},function(){e.props.onExiting(i),e.onTransitionEnd(r.exit,function(){e.safeSetState({status:l},function(){e.props.onExited(i)})})})):this.safeSetState({status:l},function(){e.props.onExited(i)})},f.cancelNextCallback=function(){null!==this.nextCallback&&(this.nextCallback.cancel(),this.nextCallback=null)},f.safeSetState=function(e,t){t=this.setNextCallback(t),this.setState(e,t)},f.setNextCallback=function(e){var t=this,r=!0;return this.nextCallback=function(i){r&&(r=!1,t.nextCallback=null,e(i))},this.nextCallback.cancel=function(){r=!1},this.nextCallback},f.onTransitionEnd=function(e,t){this.setNextCallback(t);var r=this.props.nodeRef?this.props.nodeRef.current:n.default.findDOMNode(this),i=null==e&&!this.props.addEndListener;if(!r||i)return void setTimeout(this.nextCallback,0);if(this.props.addEndListener){var s=this.props.nodeRef?[this.nextCallback]:[r,this.nextCallback],a=s[0],o=s[1];this.props.addEndListener(a,o)}null!=e&&setTimeout(this.nextCallback,e)},f.render=function(){var e=this.state.status;if(e===o)return null;var r=this.props,n=r.children,a=(r.in,r.mountOnEnter,r.unmountOnExit,r.appear,r.enter,r.exit,r.timeout,r.addEndListener,r.onEnter,r.onEntering,r.onEntered,r.onExit,r.onExiting,r.onExited,r.nodeRef,(0,t.default)(r,["children","in","mountOnEnter","unmountOnExit","appear","enter","exit","timeout","addEndListener","onEnter","onEntering","onEntered","onExit","onExiting","onExited","nodeRef"]));return i.default.createElement(s.Provider,{value:null},"function"==typeof n?n(e,a):i.default.cloneElement(i.default.Children.only(n),a))},h}(i.default.Component);function f(){}h.contextType=s,h.propTypes={},h.defaultProps={in:!1,mountOnEnter:!1,unmountOnExit:!1,appear:!1,enter
1:!0,exit:!0,onEnter:f,onEntering:f,onEntered:f,onExit:f,onExiting:f,onExited:f},h.UNMOUNTED=o,h.EXITED=l,h.ENTERING=u,h.ENTERED=c,h.EXITING=d,e.s(["default",0,h],585642)},185005,(e,t,r)=>{e.e,function(t,r,i,n){"use strict";var s=r&&"object"==typeof r&&"default"in r?r:{default:r},a=function(){return(a=Object.assign||function(e){for(var t,r=1,i=arguments.length;r<i;r++)for(var n in t=arguments[r])Object.prototype.hasOwnProperty.call(t,n)&&(e[n]=t[n]);return e}).apply(this,arguments)};function o(e,t){return Object.defineProperty?Object.defineProperty(e,"raw",{value:t}):e.raw=t,e}"function"==typeof SuppressedError&&SuppressedError;var l,u,c,d=/^((children|dangerouslySetInnerHTML|key|ref|autoFocus|defaultValue|defaultChecked|innerHTML|suppressContentEditableWarning|suppressHydrationWarning|valueLink|abbr|accept|acceptCharset|accessKey|action|allow|allowUserMedia|allowPaymentRequest|allowFullScreen|allowTransparency|alt|async|autoComplete|autoPlay|capture|cellPadding|cellSpacing|challenge|charSet|checked|cite|classID|className|cols|colSpan|content|contentEditable|contextMenu|controls|controlsList|coords|crossOrigin|data|dateTime|decoding|default|defer|dir|disabled|disablePictureInPicture|disableRemotePlayback|download|draggable|encType|enterKeyHint|form|formAction|formEncType|formMethod|formNoValidate|formTarget|frameBorder|headers|height|hidden|high|href|hrefLang|htmlFor|httpEquiv|id|inputMode|integrity|is|keyParams|keyType|kind|label|lang|list|loading|loop|low|marginHeight|marginWidth|max|maxLength|media|mediaGroup|method|min|minLength|multiple|muted|name|nonce|noValidate|open|optimum|pattern|placeholder|playsInline|poster|preload|profile|radioGroup|readOnly|referrerPolicy|rel|required|reversed|role|rows|rowSpan|sandbox|scope|scoped|scrolling|seamless|selected|shape|size|sizes|slot|span|spellCheck|src|srcDoc|srcLang|srcSet|start|step|style|summary|tabIndex|target|title|translate|type|useMap|value|width|wmode|wrap|about|datatype|inlist|prefix|property|resource|typeof|vocab|autoCapitalize|autoCorrect|autoSave|color|incremental|fallback|inert|itemProp|itemScope|itemType|itemID|itemRef|on|option|results|security|unselectable|accentHeight|accumulate|additive|alignmentBaseline|allowReorder|alphabetic|amplitude|arabicForm|ascent|attributeName|attributeType|autoReverse|azimuth|baseFrequency|baselineShift|baseProfile|bbox|begin|bias|by|calcMode|capHeight|clip|clipPathUnits|clipPath|clipRule|colorInterpolation|colorInterpolationFilters|colorProfile|colorRendering|contentScriptType|contentStyleType|cursor|cx|cy|d|decelerate|descent|diffuseConstant|direction|display|divisor|dominantBaseline|dur|dx|dy|edgeMode|elevation|enableBackground|end|exponent|externalResourcesRequired|fill|fillOpacity|fillRule|filter|filterRes|filterUnits|floodColor|floodOpacity|focusable|fontFamily|fontSize|fontSizeAdjust|fontStretch|fontStyle|fontVariant|fontWeight|format|from|fr|fx|fy|g1|g2|glyphName|glyphOrientationHorizontal|glyphOrientationVertical|glyphRef|gradientTransform|gradientUnits|hanging|horizAdvX|horizOriginX|ideographic|imageRendering|in|in2|intercept|k|k1|k2|k3|k4|kernelMatrix|kernelUnitLength|kerning|keyPoints|keySplines|keyTimes|lengthAdjust|letterSpacing|lightingColor|limitingConeAngle|local|markerEnd|markerMid|markerStart|markerHeight|markerUnits|markerWidth|mask|maskContentUnits|maskUnits|mathematical|mode|numOctaves|offset|opacity|operator|order|orient|orientation|origin|overflow|overlinePosition|overlineThickness|panose1|paintOrder|pathLength|patternContentUnits|patternTransform|patternUnits|pointerEvents|points|pointsAtX|pointsAtY|pointsAtZ|preserveAlpha|preserveAspectRatio|primitiveUnits|r|radius|refX|refY|renderingIntent|repeatCount|repeatDur|requiredExtensions|requiredFeatures|restart|result|rotate|rx|ry|scale|seed|shapeRendering|slope|spacing|specularConstant|specularExponent|speed|spreadMethod|startOffset|stdDeviation|stemh|stemv|stitchTiles|stopColor|stopOpacity|strikethroughPosition|strikethroughThickness|string|stroke|strokeDasharray|strokeDashoffset|strokeLinecap|strokeLinejoin|strokeMiterlimit|strokeOpacity|strokeWidth|surfaceScale|systemLanguage|tableValues|targetX|targetY|textAnchor|textDecoration|textRendering|textLength|to|transform|u1|u2|underlinePosition|underlineThickness|unicode|unicodeBidi|unicodeRange|unitsPerEm|vAlphabetic|vHanging|vIdeographic|vMathematical|values|vectorEffect|version|vertAdvY|vertOriginX|vertOriginY|viewBox|viewTarget|visibility|widths|wordSpacing|writingMode|x|xHeight|x1|x2|xChannelSelector|xlinkActuate|xlinkArcrole|xlinkHref|xlinkRole|xlinkShow|xlinkTitle|xlinkType|xmlBase|xmlns|xmlnsXlink|xmlLang|xmlSpace|y|y1|y2|yChannelSelector|z|zoomAndPan|for|class|autofocus)|(([Dd][Aa][Tt][Aa]|[Aa][Rr][Ii][Aa]|x)-.*))$/,h=(l=function(e){return d.test(e)||111===e.charCodeAt(0)&&110===e.charCodeAt(1)&&91>e.charCodeAt(2)},u=Object.create(null),function(e){return void 0===u[e]&&(u[e]=l(e)),u[e]}),f="awesomegrid",p=["xs","sm","md","lg","xl"],g={media:null,mediaQuery:"only screen",columns:{xs:4,sm:8,md:8,lg:12,xl:12},gutterWidth:{xs:1,sm:1,md:1.5,lg:1.5,xl:1.5},paddingWidth:{xs:1,sm:1,md:1.5,lg:1.5,xl:1.5},container:{xs:"full",sm:"full",md:"full",lg:90,xl:90},breakpoints:{xs:1,sm:48,md:64,lg:90,xl:120}},m=[],y=function(e){var t={};(null==e?void 0:e.theme)&&(t=e.theme[f]||{});var i=a(a({},g),t);return i.media=Object.keys(i.breakpoints).reduce(function(e,t){var n,s=i.breakpoints[t];return e[t]=(n=[i.mediaQuery,s>
1=0&&"(min-width: ".concat(s,"rem)")].filter(Boolean).join(" and "),function(){for(var e=[],t=0;t<arguments.length;t++)e[t]=arguments[t];return r.css(c||(c=o(["\n @media "," {\n ","\n }\n "],["\n @media "," {\n ","\n }\n "])),n,r.css.apply(null,function(e,t){for(var r,i=0,n=t.length;i<n;i++)!r&&i in t||(r||(r=Array.prototype.slice.call(t,0,i)),r[i]=t[i]);return e.concat(r||Array.prototype.slice.call(t))}([],e)))}),e},{}),i};function v(e){var t=(null==e?void 0:e.theme)?JSON.stringify(e.theme[f]||{}):{};if(m[0]===t)return m[1];var r=y(e);return m[0]=t,m[1]=r,r}var b,_,E,S,x,T,w,A,R,I,k,C,D,L,O,P,F,N,M,j,$,U,B,V,G,q,H,z,K,W,Y,Q,X=s.default("div").withConfig({shouldForwardProp:function(e){return h(e)}})(T||(T=o(["\n margin-right: auto;\n margin-left: auto;\n max-width: 100%;\n width: 100%;\n box-sizing: border-box;\n\n ","\n\n ","\n\n ","\n"],["\n margin-right: auto;\n margin-left: auto;\n max-width: 100%;\n width: 100%;\n box-sizing: border-box;\n\n ","\n\n ","\n\n ","\n"])),function(e){return r.css(_||(_=o(["\n ","\n "],["\n ","\n "])),p.map(function(t){return v(e).container[t]&&v(e).media[t](b||(b=o(["\n padding-left: ","rem;\n padding-right: ","rem;\n "],["\n padding-left: ","rem;\n padding-right: ","rem;\n "])),v(e).paddingWidth[t],v(e).paddingWidth[t])}))},function(e){return!e.fluid&&r.css(S||(S=o(["\n ","\n "],["\n ","\n "])),p.map(function(t){return v(e).container[t]&&v(e).media[t](E||(E=o(["\n ","\n "],["\n ","\n "])),"number"==typeof v(e).container[t]?"max-width: ".concat(v(e).container[t],"rem;"):"width: 100%;")}))},function(e){return e.debug&&r.css(x||(x=o(["\n background-color: #5901ad40;\n outline: #fff solid 1px;\n "],["\n background-color: #5901ad40;\n outline: #fff solid 1px;\n "])))}),J=s.default.div.withConfig({shouldForwardProp:function(e){return h(e)}})(P||(P=o(["\n box-sizing: border-box;\n display: flex;\n flex: 1 1 auto;\n flex-wrap: wrap;\n\n ","\n\n ","\n\n ","\n \n ","\n\n ","\n"],["\n box-sizing: border-box;\n display: flex;\n flex: 1 1 auto;\n flex-wrap: wrap;\n\n ","\n\n ","\n\n ","\n \n ","\n\n ","\n"])),function(e){return r.css(A||(A=o(["\n ","\n "],["\n ","\n "])),p.map(function(t){return v(e).container[t]&&v(e).media[t](w||(w=o(["\n margin-left: -","rem;\n margin-right: -","rem;\n "],["\n margin-left: -","rem;\n margin-right: -","rem;\n "])),v(e).gutterWidth[t]/2,v(e).gutterWidth[t]/2)}))},function(e){return e.reverse&&r.css(I||(I=o(["\n ","\n "],["\n ","\n "])),Array.isArray(e.reverse)?p.map(function(t){return v(e).breakpoints[t]&&v(e).media[t](R||(R=o(["\n ",";\n \n "],["\n ",";\n \n "])),Array.isArray(e.reverse)&&-1!==e.reverse.indexOf(t)?"\n flex-direction: row-reverse;\n flex-wrap: wrap-reverse;\n ":"\n flex-direction: row;\n flex-wrap: wrap;\n ")}):"\n flex-direction: row-reverse;\n flex-wrap: wrap-reverse;\n ")},function(e){return e.align&&r.css(C||(C=o(["\n ","\n "],["\n ","\n "])),"object"==typeof e.align?p.map(function(t){return v(e).breakpoints[t]&&v(e).media[t](k||(k=o(["",""],["",""])),e.align[t]&&"align-items: ".concat(e.align[t]))}):"align-items: ".concat(e.align,";"))},function(e){return e.justify&&r.css(L||(L=o(["\n ","\n "],["\n ","\n "])),"object"==typeof e.justify?p.map(function(t){return v(e).breakpoints[t]&&v(e).media[t](D||(D=o(["",""],["",""])),e.justify[t]&&"justify-content: ".concat(e.justify[t]))}):"justify-content: ".concat(e.justify,";"))},function(e){return e.debug&&r.css(O||(O=o(["\n background-color: #5901ad40;\n outline: #fff solid 1px;\n "],["\n background-color: #5901ad40;\n outline: #fff solid 1px;\n "])))}),Z=s.default.div.withConfig({shouldForwardProp:function(e){return h(e)}})(Q||(Q=o(["\n box-sizing: border-box;\n flex: 1 0 auto;\n max-width: 100%;\n display: flex;\n flex-direction: column;\n\n ","\n\n ","\n\n ","\n\n ","\n\n ","\n\n ","\n \n ","\n \n ","\n"],["\n box-sizing: border-box;\n flex: 1 0 auto;\n max-width: 100%;\n display: flex;\n flex-direction: column;\n\n ","\n\n ","\n\n ","\n\n ","\n\n ","\n\n ","\n \n ","\n \n ","\n"])),function(e){return!e.noGutter&&r.css(N||(N=o(["\n ","\n "],["\n ","\n "])),p.map(function(t){return v(e).breakpoints[t]&&v(e).media[t](F||(F=o(["\n padding-right: ","rem;\n padding-left: ","rem;\n "],["\n padding-right: ","rem;\n padding-left: ","rem;\n "])),v(e).gutterWidth[t]/2,v(e).gutterWidth[t]/2)}))},function(e){return r.css(j||(j=o(["\n ","\n "],["\n ","\n "])),p.map(function(t){return e[t]&&v(e).breakpoints[t]&&v(e).media[t](M||(M=o(["\n flex: 1 1 ","%;\n max-width: ","%;\n "],["\n flex: 1 1 ","%;\n max-width: ","%;\n "])),e[t]/v(e).columns[t]*100,e[t]/v(e).columns[t]*100)}))},function(e){return e.offset&&r.css(U||(U=o(["\n ","\n "],["\n ","\n "])),p.map(function(t){return v(e).breakpoints[t]&&v(e).media[t]($||($=o(["\n ",";\n "],["\n ",";\n "])),"object"==typeof e.offset?void 0!==e.offset[t]&&"margin-left: ".concat(e.offset[t]>0?e.offset[t]/v(e).columns[t]*100:0,"%"):"margin-left: ".concat(e.offset/v(e).columns.xs*100,"%"))}))},function(e){return void 0!==e.order&&r.css(V||(V=o(["\n ","\n "],["\n ","\n "])),p.map(function(t){return v(e).breakpoints[t]&&v(e).media[t](B||(B=o(["\n ",";\n "],["\n ",";\n "])),"object"==typeof e.order?void 0!==e.order[t]&&"order: ".concat(e.order[t]):"order: ".concat(e.order))}))},function(e){return e.reverse&&r.css(q||(q=o(["\n ","\n "],["\n ","\n "])),Array.isArray(e.reverse)?p.map(function(t){return v(e).breakpoints[t]&&v(e).media[t](G||(G=o(["\n flex-direction: ",";\n "],["\n flex-direction: ",";\n "])),Array.isArray(e.reverse)&&-1!==e.reverse.indexOf(t)?"column-reverse":"column")}):"flex-direction: column-reverse;")},function(e){return e.align&&r.css(z||(z=o(["\n ","\n "],["\n ","\n "])),"object"==typeof e.align?p.map(function(t){return v(e).breakpoints[t]&&v(e).media[t](H||(H=o(["",""],["",""])),e.align[t]&&"align-items: ".concat(e.align[t]))}):"align-items: ".concat(e.align,";"))},function(e){return e.justify&&r.css(W||(W=o(["\n ","\n "],["\n ","\n "])),"object"==typeof e.justify?p.map(function(t){return v(e).breakpoints[t]&&v(e).media[t](K||(K=o(["",""],["",""])),e.justify[t]&&"justify-content: ".concat(e.justify[t]))}):"justify-content: ".concat(e.justify,";"))},function(e){return e.debug&&r.css(Y||(Y=o(["\n background-color: #5901ad40;\n outline: #fff solid 1px;\n "],["\n background-color: #5901ad40;\n outline: #fff solid 1px;\n "])))});function ee(t,r,i,s){void 0===i&&(i=e.g),void 0===s&&(s={});var a=n.useRef(),o=s.capture,l=s.passive,u=s.once;n.useEffect(function(){a.current=r},[r]),n.useEffect(function(){if(i&&i.addEventListener){var e=function(e){return a.current(e)},r={capture:o,passive:l,once:u};return i.addEventListener(t,e,r),function(){i.removeEventListener(t,e,r)}}},[t,i,o,l,u])}function et(){return"u">typeof window&&window.innerWidth?window.innerWidth:null}function er(e){var t,r=v(e).breakpoints,i="u">typeof window&&+window.getComputedStyle(document.querySelector("html")).getPropertyValue("font-size").replace("px","")||16,n=Object.values(r).map(function(e){return e*i}),s=et();return s&&(t=p[0],n[1]&&s>=n[1]&&(t=p[1]),n[2]&&s>=n[2]&&(t=p[2]),n[3]&&s>=n[3]&&(t=p[3]),n[4]&&s>=n[4]&&(t=p[4])),t}var ei,en,es,ea=s.default.div.withConfig({shouldForwardProp:function(e){return h(e)}})(es||(es=o(["\n z-index: 10;\n position: fixed;\n font-size: 1.5rem;\n font-weight: bold;\n right: 10px;\n bottom: 10px;\n width: 50px;\n height: 30px;\n background-color: #5901ad40;\n display: flex;\n border-radius: 5px;\n justify-content: center;\n align-items: center;\n ","\n"],["\n z-index: 10;\n position: fixed;\n font-size: 1.5rem;\n font-weight: bold;\n right: 10px;\n bottom: 10px;\n width: 50px;\n height: 30px;\n background-color: #5901ad40;\n display: flex;\n border-radius: 5px;\n justify-content: center;\n align-items: center;\n ","\n"])),function(e){return r.css(en||(en=o(["\n ","\n "],["\n ","\n "])),p.map(function(t){return v(e).breakpoints[t]&&v(e).media[t](ei||(ei=o(["\n &::before {\n content: '","'\n }\n "],["\n &::before {\n content: '","'\n }\n "])),t)}))});t.Col=Z,t.Container=X,t.Hidden=function(e){var t=e.xs,r=e.sm,s=e.md,a=e.lg,o=e.xl,l=e.children,u=e.theme,c=n.useState("xs"),d=c[0],h=c[1],f=function(){var e=er({theme:u});d!==e&&h(e)};return n.useEffect(function(){f()},[]),ee("orientationchange",f),ee("resize",f),!function(){switch(d){case"xs":return t;case"sm":return r;case"md":return s;case"lg":return a;case"xl":return o}}()&&i.jsx(n.Fragment,{children:l})},t.Row=J,t.ScreenBadge=ea,t.ScreenClass=function(e){var t=n.useState(p[0]),r=t[0],s=t[1],a=n.useCallback(function(){var t=er(e);r!==t&&s(t)},[r]);return n.useEffect(function(){a()},[]),n.useEffect(function(){return"u">typeof window&&(window.addEventListener("orientationchange",a,!1),window.addEventListener("resize",a,!1)),function(){"u">typeof window&&(window.removeEventListener("orientationchange",a),window.removeEventListener("resize",a))}},[r]),i.jsx(n.Fragment,{children:null==e?void 0:e.render(r)})},t.Visible=function(e){var t=e.xs,r=e.sm,s=e.md,a=e.lg,o=e.xl,l=e.children,u=e.theme,c=n.useState("xs"),d=c[0],h=c[1],f=function(){var e=er({theme:u});d!==e&&h(e)};return n.useEffect(function(){f()},[]),ee("orientationchange",f),ee("resize",f),!!function(){switch(d){case"xs":return t;case"sm":return r;case"md":return s;case"lg":return a;case"xl":return o}}()&&i.jsx(n.Fragment,{children:l})},t.config=v,t.util={getScreenClass:er,getViewPort:et}}(r,e.r(997053),e.r(843476),e.r(271645))},971883,(e,t,r)=>{"use strict";
1Object.defineProperty(r,"__esModule",{value:!0}),(p=g||(g={})).Root="root",p.Text="text",p.Directive="directive",p.Comment="comment",p.Script="script",p.Style="style",p.Tag="tag",p.CDATA="cdata",p.Doctype="doctype",g.Root,g.Text,g.Directive,g.Comment,g.Script,g.Style,g.Tag,g.CDATA,g.Doctype;class i{parent=null;prev=null;next=null;startIndex=null;endIndex=null;get parentNode(){return this.parent}set parentNode(e){this.parent=e}get previousSibling(){return this.prev}set previousSibling(e){this.prev=e}get nextSibling(){return this.next}set nextSibling(e){this.next=e}cloneNode(e=!1){return h(this,e)}}class n extends i{data;constructor(e){super(),this.data=e}get nodeValue(){return this.data}set nodeValue(e){this.data=e}}class s extends n{type=g.Text;get nodeType(){return 3}}class a extends n{type=g.Comment;get nodeType(){return 8}}class o extends n{type=g.Directive;name;constructor(e,t){super(t),this.name=e}get nodeType(){return 1}"x-name";"x-publicId";"x-systemId"}class l extends i{children;constructor(e){super(),this.children=e}get firstChild(){return this.children[0]??null}get lastChild(){return this.children.length>0?this.children[this.children.length-1]:null}get childNodes(){return this.children}set childNodes(e){this.children=e}}class u extends l{type=g.CDATA;get nodeType(){return 4}}class c extends l{type=g.Root;get nodeType(){return 9}}class d extends l{name;attribs;type;constructor(e,t,r=[],i="script"===e?g.Script:"style"===e?g.Style:g.Tag){super(r),this.name=e,this.attribs=t,this.type=i}get nodeType(){return 1}get tagName(){return this.name}set tagName(e){this.name=e}get attributes(){return Object.keys(this.attribs).map(e=>({name:e,value:this.attribs[e],namespace:this["x-attribsNamespace"]?.[e],prefix:this["x-attribsPrefix"]?.[e]}))}namespace;"x-attribsNamespace";"x-attribsPrefix"}function h(e,t=!1){let r;if(e.type===g.Text)r=new s(e.data);else if(e.type===g.Comment)r=new a(e.data);else if(e.type===g.Tag||e.type===g.Script||e.type===g.Style){let i=t?f(e.children):[],n=new d(e.name,{...e.attribs},i);for(let e of i)e.parent=n;null!=e.namespace&&(n.namespace=e.namespace),e["x-attribsNamespace"]&&(n["x-attribsNamespace"]={...e["x-attribsNamespace"]}),e["x-attribsPrefix"]&&(n["x-attribsPrefix"]={...e["x-attribsPrefix"]}),r=n}else if(e.type===g.CDATA){let i=t?f(e.children):[],n=new u(i);for(let e of i)e.parent=n;r=n}else if(e.type===g.Root){let i=t?f(e.children):[],n=new c(i);for(let e of i)e.parent=n;e["x-mode"]&&(n["x-mode"]=e["x-mode"]),r=n}else if(e.type===g.Directive){let t=new o(e.name,e.data);null!=e["x-name"]&&(t["x-name"]=e["x-name"],t["x-publicId"]=e["x-publicId"],t["x-systemId"]=e["x-systemId"]),r=t}else throw Error(`Not implemented yet: ${e.type}`);return r.startIndex=e.startIndex,r.endIndex=e.endIndex,null!=e.sourceCodeLocation&&(r.sourceCodeLocation=e.sourceCodeLocation),r}function f(e){let t=e.map(e=>h(e,!0));for(let e=1;e<t.length;e++)t[e].prev=t[e-1],t[e-1].next=t[e];return t}var p,g,m,y=["animateMotion","animateTransform","clipPath","feBlend","feColorMatrix","feComponentTransfer","feComposite","feConvolveMatrix","feDiffuseLighting","feDisplacementMap","feDropShadow","feFlood","feFuncA","feFuncB","feFuncG","feFuncR","feGaussianBlur","feImage","feMerge","feMergeNode","feMorphology","feOffset","fePointLight","feSpecularLighting","feSpotLight","feTile","feTurbulence","foreignObject","linearGradient","radialGradient","textPath"].reduce(function(e,t){return e[t.toLowerCase()]=t,e},{}),v=RegExp("\r","g"),b="__HTML_DOM_PARSER_CARRIAGE_RETURN_PLACEHOLDER_".concat(Date.now().toString(),"__"),_=RegExp(b,"g");function E(e,t){var r="<"+t,i=e.toLowerCase().indexOf(r);if(-1===i)return!1;var n=e[i+r.length];return">"===n||" "===n||" "===n||"\n"===n||"\r"===n||"/"===n}var S="html",x="head",T="body",w=/<([a-zA-Z]+[0-9]?)/;function A(e,t){return t?t.createHTML(e):e}var R=function(e,t,r){throw Error("This browser does not support `document.implementation.createHTMLDocument`")},I=function(e,t,r){throw Error("This browser does not support `DOMParser.prototype.parseFromString`")},k="object"==typeof window&&window.DOMParser;if("function"==typeof k){var C=new k;R=I=function(e,t,r){return t&&(e="<".concat(t,">").concat(e,"</").concat(t,">")),C.parseFromString(e,"text/html")}}if("object"==typeof document&&document.implementation){var D=document.implementation.createHTMLDocument();R=function(e,t,r){if(t){var i=D.documentElement.querySelector(t);return i&&(i.innerHTML=A(e,r)),D}return D.documentElement.innerHTML=A(e,r),D}}var L="object"==typeof document&&document.createElement("template");L&&L.content&&(m=function(e,t){return L.innerHTML=A(e,t),L.content.childNodes});var O=function(){return document.createDocumentFragment().childNodes},P=/<(![a-zA-Z\s]+)>/;r.default=function(e,t){if("string"!=typeof e)throw TypeError("First argument must be a string");if(!e)return[];var r=P.exec(e),i=r?r[1]:void 0;return function e(t,r,i){void 0===r&&(r=null);for(var n,l,u,c,h,f=[],p=0,g=t.length;p<g;p++){var m=t[p];switch(m.nodeType){case 1:var v=function(e){var t=y[e=e.toLowerCase()];return t||e}
1(m.nodeName);(h=new d(v,function(e){for(var t={},r=0,i=e.length;r<i;r++){var n=e[r];t[n.name]=n.value}return t}(m.attributes))).children=e("template"===v?m.content.childNodes:m.childNodes,h);break;case 3:h=new s((null!=(n=m.nodeValue)?n:"").replace(_,"\r"));break;case 8:h=new a(null!=(l=m.nodeValue)?l:"");break;default:continue}var b=null!=(u=f[p-1])?u:null;b&&(b.next=h),h.parent=r,h.prev=b,h.next=null,f.push(h)}return i&&((h=new o(i.substring(0,i.indexOf(" ")).toLowerCase(),i)).next=null!=(c=f[0])?c:null,h.parent=r,f.unshift(h),f[1]&&(f[1].prev=f[0])),f}(function(e,t){e=e.replace(v,b);var r,i,n,s,a,o,l=w.exec(e),u=null==(r=null==l?void 0:l[1])?void 0:r.toLowerCase();switch(u){case S:var c=I(e);if(!E(e,x)){var d=c.querySelector(x);null==(i=null==d?void 0:d.parentNode)||i.removeChild(d)}if(!E(e,T)){var d=c.querySelector(T);null==(n=null==d?void 0:d.parentNode)||n.removeChild(d)}return c.querySelectorAll(S);case x:case T:var h=R(e,void 0,t).querySelectorAll(u);if(E(e,T)&&E(e,x))return null!=(a=null==(s=h[0].parentNode)?void 0:s.childNodes)?a:O();return h;default:if(m)return m(e,t);var d=R(e,T,t).querySelector(T);return null!=(o=null==d?void 0:d.childNodes)?o:O()}}(e,null==t?void 0:t.trustedTypePolicy),null,i)}},559878,(e,t,r)=>{r.SAME=0,r.CAMELCASE=1,r.possibleStandardNames={accept:0,acceptCharset:1,"accept-charset":"acceptCharset",accessKey:1,action:0,allowFullScreen:1,alt:0,as:0,async:0,autoCapitalize:1,autoComplete:1,autoCorrect:1,autoFocus:1,autoPlay:1,autoSave:1,capture:0,cellPadding:1,cellSpacing:1,challenge:0,charSet:1,checked:0,children:0,cite:0,class:"className",classID:1,className:1,cols:0,colSpan:1,content:0,contentEditable:1,contextMenu:1,controls:0,controlsList:1,coords:0,crossOrigin:1,dangerouslySetInnerHTML:1,data:0,dateTime:1,default:0,defaultChecked:1,defaultValue:1,defer:0,dir:0,disabled:0,disablePictureInPicture:1,disableRemotePlayback:1,download:0,draggable:0,encType:1,enterKeyHint:1,for:"htmlFor",form:0,formMethod:1,formAction:1,formEncType:1,formNoValidate:1,formTarget:1,frameBorder:1,headers:0,height:0,hidden:0,high:0,href:0,hrefLang:1,htmlFor:1,httpEquiv:1,"http-equiv":"httpEquiv",icon:0,id:0,innerHTML:1,inputMode:1,integrity:0,is:0,itemID:1,itemProp:1,itemRef:1,itemScope:1,itemType:1,keyParams:1,keyType:1,kind:0,label:0,lang:0,list:0,loop:0,low:0,manifest:0,marginWidth:1,marginHeight:1,max:0,maxLength:1,media:0,mediaGroup:1,method:0,min:0,minLength:1,multiple:0,muted:0,name:0,noModule:1,nonce:0,noValidate:1,open:0,optimum:0,pattern:0,placeholder:0,playsInline:1,poster:0,preload:0,profile:0,radioGroup:1,readOnly:1,referrerPolicy:1,rel:0,required:0,reversed:0,role:0,rows:0,rowSpan:1,sandbox:0,scope:0,scoped:0,scrolling:0,seamless:0,selected:0,shape:0,size:0,sizes:0,span:0,spellCheck:1,src:0,srcDoc:1,srcLang:1,srcSet:1,start:0,step:0,style:0,summary:0,tabIndex:1,target:0,title:0,type:0,useMap:1,value:0,width:0,wmode:0,wrap:0,about:0,accentHeight:1,"accent-height":"accentHeight",accumulate:0,additive:0,alignmentBaseline:1,"alignment-baseline":"alignmentBaseline",allowReorder:1,alphabetic:0,amplitude:0,arabicForm:1,"arabic-form":"arabicForm",ascent:0,attributeName:1,attributeType:1,autoReverse:1,azimuth:0,baseFrequency:1,baselineShift:1,"baseline-shift":"baselineShift",baseProfile:1,bbox:0,begin:0,bias:0,by:0,calcMode:1,capHeight:1,"cap-height":"capHeight",clip:0,clipPath:1,"clip-path":"clipPath",clipPathUnits:1,clipRule:1,"clip-rule":"clipRule",color:0,colorInterpolation:1,"color-interpolation":"colorInterpolation",colorInterpolationFilters:1,"color-interpolation-filters":"colorInterpolationFilters",colorProfile:1,"color-profile":"colorProfile",colorRendering:1,"color-rendering":"colorRendering",contentScriptType:1,contentStyleType:1,cursor:0,cx:0,cy:0,d:0,datatype:0,decelerate:0,descent:0,diffuseConstant:1,direction:0,display:0,divisor:0,dominantBaseline:1,"dominant-baseline":"dominantBaseline",dur:0,dx:0,dy:0,edgeMode:1,elevation:0,enableBackground:1,"enable-background":"enableBackground",end:0,exponent:0,externalResourcesRequired:1,fill:0,fillOpacity:1,"fill-opacity":"fillOpacity",fillRule:1,"fill-rule":"fillRule",filter:0,filterRes:1,filterUnits:1,floodOpacity:1,"flood-opacity":"floodOpacity",floodColor:1,"flood-color":"floodColor",focusable:0,fontFamily:1,"font-family":"fontFamily",fontSize:1,"font-size":"fontSize",fontSizeAdjust:1,"font-size-adjust":"fontSizeAdjust",fontStretch:1,"font-stretch":"fontStretch",fontStyle:1,"font-style":"fontStyle",fontVariant:1,"font-variant":"fontVariant",fontWeight:1,"font-weight":"fontWeight",format:0,from:0,fx:0,fy:0,g1:0,g2:0,glyphName:1,"glyph-name":"glyphName",glyphOrientationHorizontal:1,"glyph-orientation-horizontal":"glyphOrientationHorizontal",glyphOrientationVertical:1,"glyph-orientation-vertical":"glyphOrientationVertical",glyphRef:1,gradientTransform:1,gradientUnits:1,hanging:0,horizAdvX:1,"horiz-adv-x":"horizAdvX",horizOriginX:1,"horiz-origin-x":"horizOriginX",ideographic:0,imageRendering:1,"image-rendering":"imageRendering",in2:0,in:0,inlist:0,intercept:0,k1:0,k2:0,k3:0,k4:0,k:0,kernelMatrix:1,kernelUnitLength:1,kerning:0,keyPoints:1,keySplines:1,keyTimes:1,lengthAdjust:1,letterSpacing:1,"letter-spacing":"letterSpacing",lightingColor:1,"lighting-color":"lightingColor",limitingConeAngle:1,local:0,markerEnd:1,"marker-end":"markerEnd",markerHeight:1,markerMid:1,"marker-mid":"markerMid",markerStart:1,"marker-start":"markerStart",markerUnits:1,markerWidth:1,mask:0,maskContentUnits:1,maskUnits:1,mathematical:0,mode:0,numOctaves:1,offset:0,opacity:0,operator:0,order:0,orient:0,orientation:0,origin:0,overflow:0,overlinePosition:1,"overline-position":"overlinePosition",overlineThickness:1,"overline-thickness":"overlineThickness",paintOrder:1,"paint-order":"paintOrder",panose1:0,"panose-1":"panose1",pathLength:1,patternContentUnits:1,patternTransform:1,patternUnits:1,pointerEvents:1,"pointer-events":"pointerEvents",points:0,pointsAtX:1,pointsAtY:1,pointsAtZ:1,prefix:0,preserveAlpha:1,preserveAspectRatio:1,primitiveUnits:1,property:0,r:0,radius:0,refX:1,refY:1,renderingIntent:1,"rendering-intent":"renderingIntent",repeatCount:1,repeatDur:1,requiredExtensions:1,requiredFeatures:1,resource:0,restart:0,result:0,results:0,rotate:0,rx:0,ry:0,scale:0,security:0,seed:0,shapeRendering:1,"shape-rendering":"shapeRendering",slope:0,spacing:0,specularConstant:1,specularExponent:1,speed:0,spreadMethod:1,startOffset:1,stdDeviation:1,stemh:0,stemv:0,stitchTiles:1,stopColor:1,"stop-color":"stopColor",stopOpacity:1,"stop-opacity":"stopOpacity",strikethroughPosition:1,"strikethrough-position":"strikethroughPosition",strikethroughThickness:1,"strikethrough-thickness":"strikethroughThickness",string:0,stroke:0,strokeDasharray:1,"stroke-dasharray":"strokeDasharray",strokeDashoffset:1,"stroke-dashoffset":"strokeDashoffset",strokeLinecap:1,"stroke-linecap":"strokeLinecap",strokeLinejoin:1,"stroke-linejoin":"strokeLinejoin",strokeMiterlimit:1,"stroke-miterlimit":"strokeMiterlimit",strokeWidth:1,"stroke-width":"strokeWidth",strokeOpacity:1,"stroke-opacity":"strokeOpacity",suppressContentEditableWarning:1,suppressHydrationWarning:1,surfaceScale:1,systemLanguage:1,tableValues:1,targetX:1,targetY:1,textAnchor:1,"text-anchor":"textAnchor",textDecoration:1,"text-decoration":"textDecoration",textLength:1,textRendering:1,"text-rendering":"textRendering",to:0,transform:0,typeof:0,u1:0,u2:0,underlinePosition:1,"underline-position":"underlinePosition",underlineThickness:1,"underline-thickness":"underlineThickness",unicode:0,unicodeBidi:1,"unicode
1-bidi":"unicodeBidi",unicodeRange:1,"unicode-range":"unicodeRange",unitsPerEm:1,"units-per-em":"unitsPerEm",unselectable:0,vAlphabetic:1,"v-alphabetic":"vAlphabetic",values:0,vectorEffect:1,"vector-effect":"vectorEffect",version:0,vertAdvY:1,"vert-adv-y":"vertAdvY",vertOriginX:1,"vert-origin-x":"vertOriginX",vertOriginY:1,"vert-origin-y":"vertOriginY",vHanging:1,"v-hanging":"vHanging",vIdeographic:1,"v-ideographic":"vIdeographic",viewBox:1,viewTarget:1,visibility:0,vMathematical:1,"v-mathematical":"vMathematical",vocab:0,widths:0,wordSpacing:1,"word-spacing":"wordSpacing",writingMode:1,"writing-mode":"writingMode",x1:0,x2:0,x:0,xChannelSelector:1,xHeight:1,"x-height":"xHeight",xlinkActuate:1,"xlink:actuate":"xlinkActuate",xlinkArcrole:1,"xlink:arcrole":"xlinkArcrole",xlinkHref:1,"xlink:href":"xlinkHref",xlinkRole:1,"xlink:role":"xlinkRole",xlinkShow:1,"xlink:show":"xlinkShow",xlinkTitle:1,"xlink:title":"xlinkTitle",xlinkType:1,"xlink:type":"xlinkType",xmlBase:1,"xml:base":"xmlBase",xmlLang:1,"xml:lang":"xmlLang",xmlns:0,"xml:space":"xmlSpace",xmlnsXlink:1,"xmlns:xlink":"xmlnsXlink",xmlSpace:1,y1:0,y2:0,y:0,yChannelSelector:1,z:0,zoomAndPan:1}},594555,(e,t,r)=>{"use strict";function i(e,t,r,i,n,s,a){this.acceptsBooleans=2===t||3===t||4===t,this.attributeName=i,this.attributeNamespace=n,this.mustUseProperty=r,this.propertyName=e,this.type=t,this.sanitizeURL=s,this.removeEmptyString=a}let n={};["children","dangerouslySetInnerHTML","defaultValue","defaultChecked","innerHTML","suppressContentEditableWarning","suppressHydrationWarning","style"].forEach(e=>{n[e]=new i(e,0,!1,e,null,!1,!1)}),[["acceptCharset","accept-charset"],["className","class"],["htmlFor","for"],["httpEquiv","http-equiv"]].forEach(([e,t])=>{n[e]=new i(e,1,!1,t,null,!1,!1)}),["contentEditable","draggable","spellCheck","value"].forEach(e=>{n[e]=new i(e,2,!1,e.toLowerCase(),null,!1,!1)}),["autoReverse","externalResourcesRequired","focusable","preserveAlpha"].forEach(e=>{n[e]=new i(e,2,!1,e,null,!1,!1)}),["allowFullScreen","async","autoFocus","autoPlay","controls","default","defer","disabled","disablePictureInPicture","disableRemotePlayback","formNoValidate","hidden","loop","noModule","noValidate","open","playsInline","readOnly","required","reversed","scoped","seamless","itemScope"].forEach(e=>{n[e]=new i(e,3,!1,e.toLowerCase(),null,!1,!1)}),["checked","multiple","muted","selected"].forEach(e=>{n[e]=new i(e,3,!0,e,null,!1,!1)}),["capture","download"].forEach(e=>{n[e]=new i(e,4,!1,e,null,!1,!1)}),["cols","rows","size","span"].forEach(e=>{n[e]=new i(e,6,!1,e,null,!1,!1)}),["rowSpan","start"].forEach(e=>{n[e]=new i(e,5,!1,e.toLowerCase(),null,!1,!1)});let s=/[\-\:]([a-z])/g,a=e=>e[1].toUpperCase();["accent-height","alignment-baseline","arabic-form","baseline-shift","cap-height","clip-path","clip-rule","color-interpolation","color-interpolation-filters","color-profile","color-rendering","dominant-baseline","enable-background","fill-opacity","fill-rule","flood-color","flood-opacity","font-family","font-size","font-size-adjust","font-stretch","font-style","font-variant","font-weight","glyph-name","glyph-orientation-horizontal","glyph-orientation-vertical","horiz-adv-x","horiz-origin-x","image-rendering","letter-spacing","lighting-color","marker-end","marker-mid","marker-start","overline-position","overline-thickness","paint-order","panose-1","pointer-events","rendering-intent","shape-rendering","stop-color","stop-opacity","strikethrough-position","strikethrough-thickness","stroke-dasharray","stroke-dashoffset","stroke-linecap","stroke-linejoin","stroke-miterlimit","stroke-opacity","stroke-width","text-anchor","text-decoration","text-rendering","underline-position","underline-thickness","unicode-bidi","unicode-range","units-per-em","v-alphabetic","v-hanging","v-ideographic","v-mathematical","vector-effect","vert-adv-y","vert-origin-x","vert-origin-y","word-spacing","writing-mode","xmlns:xlink","x-height"].forEach(e=>{let t=e.replace(s,a);n[t]=new i(t,1,!1,e,null,!1,!1)}),["xlink:actuate","xlink:arcrole","xlink:role","xlink:show","xlink:title","xlink:type"].forEach(e=>{let t=e.replace(s,a);n[t]=new i(t,1,!1,e,"http://www.w3.org/1999/xlink",!1,!1)}
1),["xml:base","xml:lang","xml:space"].forEach(e=>{let t=e.replace(s,a);n[t]=new i(t,1,!1,e,"http://www.w3.org/XML/1998/namespace",!1,!1)}),["tabIndex","crossOrigin"].forEach(e=>{n[e]=new i(e,1,!1,e.toLowerCase(),null,!1,!1)}),n.xlinkHref=new i("xlinkHref",1,!1,"xlink:href","http://www.w3.org/1999/xlink",!0,!1),["src","href","action","formAction"].forEach(e=>{n[e]=new i(e,1,!1,e.toLowerCase(),null,!0,!0)});let{CAMELCASE:o,SAME:l,possibleStandardNames:u}=e.r(559878),c=RegExp.prototype.test.bind(RegExp("^(data|aria)-[:A-Z_a-z\\u00C0-\\u00D6\\u00D8-\\u00F6\\u00F8-\\u02FF\\u0370-\\u037D\\u037F-\\u1FFF\\u200C-\\u200D\\u2070-\\u218F\\u2C00-\\u2FEF\\u3001-\\uD7FF\\uF900-\\uFDCF\\uFDF0-\\uFFFD\\-.0-9\\u00B7\\u0300-\\u036F\\u203F-\\u2040]*$")),d=Object.keys(u).reduce((e,t)=>{let r=u[t];return r===l?e[t]=t:r===o?e[t.toLowerCase()]=t:e[t]=r,e},{});r.BOOLEAN=3,r.BOOLEANISH_STRING=2,r.NUMERIC=5,r.OVERLOADED_BOOLEAN=4,r.POSITIVE_NUMERIC=6,r.RESERVED=0,r.STRING=1,r.getPropertyInfo=function(e){return n.hasOwnProperty(e)?n[e]:null},r.isCustomAttribute=c,r.possibleStandardNames=d},126568,(e,t,r)=>{"use strict";var i=/\/\*[^*]*\*+([^/*][^*]*\*+)*\//g,n=/\n/g,s=/^\s*/,a=/^(\*?[-#/*\\\w]+(\[[0-9a-z_-]+\])?)\s*/,o=/^:\s*/,l=/^((?:'(?:\\'|.)*?'|"(?:\\"|.)*?"|\([^)]*?\)|[^};])+)/,u=/^[;\s]*/,c=/^\s+|\s+$/g;function d(e){return e?e.replace(c,""):""}t.exports=function(e,t){if("string"!=typeof e)throw TypeError("First argument must be a string");if(!e)return[];t=t||{};var r=1,c=1;function h(e){var t=e.match(n);t&&(r+=t.length);var i=e.lastIndexOf("\n");c=~i?e.length-i:c+e.length}function f(){var e={line:r,column:c};return function(t){return t.position=new p(e),m(s),t}}function p(e){this.start=e,this.end={line:r,column:c},this.source=t.source}function g(i){var n=Error(t.source+":"+r+":"+c+": "+i);if(n.reason=i,n.filename=t.source,n.line=r,n.column=c,n.source=e,t.silent);else throw n}function m(t){var r=t.exec(e);if(r){var i=r[0];return h(i),e=e.slice(i.length),r}}function y(e){var t;for(e=e||[];t=v();)!1!==t&&e.push(t);return e}function v(){var t=f();if("/"==e.charAt(0)&&"*"==e.charAt(1)){for(var r=2;""!=e.charAt(r)&&("*"!=e.charAt(r)||"/"!=e.charAt(r+1));)++r;if(r+=2,""===e.charAt(r-1))return g("End of comment missing");var i=e.slice(2,r-2);return c+=2,h(i),e=e.slice(r),c+=2,t({type:"comment",comment:i})}}p.prototype.content=e,m(s);var b,_=[];for(y(_);b=function(){var e=f(),t=m(a);if(t){if(v(),!m(o))return g("property missing ':'");var r=m(l),n=e({type:"declaration",property:d(t[0].replace(i,"")),value:r?d(r[0].replace(i,"")):""});return m(u),n}}();)!1!==b&&(_.push(b),y(_));return _}},270454,(e,t,r)=>{"use strict";var i=e.e&&e.e.__importDefault||function(e){return e&&e.__esModule?e:{default:e}};Object.defineProperty(r,"__esModule",{value:!0}),r.default=function(e,t){let r=null;if(!e||"string"!=typeof e)return r;let i=(0,n.default)(e),s="function"==typeof t;return i.forEach(e=>{if("declaration"!==e.type)return;let{property:i,value:n}=e;s?t(i,n,e):n&&((r=r||{})[i]=n)}),r};let n=i(e.r(126568))},965185,(e,t,r)=>{"use strict";Object.defineProperty(r,"__esModule",{value:!0}),r.camelCase=void 0;var i=/^--[a-zA-Z0-9_-]+$/,n=/-([a-z])/g,s=/^[^-]+$/,a=/^-(webkit|moz|ms|o|khtml)-/,o=/^-(ms)-/,l=function(e,t){return t.toUpperCase()},u=function(e,t){return"".concat(t,"-")};r.camelCase=function(e,t){var r;return(void 0===t&&(t={}),!(r=e)||s.test(r)||i.test(r))?e:(e=e.toLowerCase(),(e=t.reactCompat?e.replace(o,u):e.replace(a,u)).replace(n,l))}},515511,(e,t,r)=>{"use strict";var i=(e.e&&e.e.__importDefault||function(e){return e&&e.__esModule?e:{default:e}})(e.r(270454)),n=e.r(965185);function s(e,t){var r={};return e&&"string"==typeof e&&(0,i.default)(e,function(e,i){e&&i&&(r[(0,n.camelCase)(e,t)]=i)}),r}s.default=s,t.exports=s},846335,(e,t,r)=>{"use strict";var i=e.e&&e.e.__importDefault||function(e){return e&&e.__esModule?e:{default:e}};Object.defineProperty(r,"__esModule",{value:!0}),r.returnFirstArg=r.canTextBeChildOfNode=r.ELEMENTS_WITH_NO_TEXT_CHILDREN=r.PRESERVE_CUSTOM_ATTRIBUTES=void 0,r.isCustomComponent=function(e,t){return e.includes("-")?!a.has(e):!!(t&&"string"==typeof t.is)},r.setStyleProp=function(e,t){if("string"==typeof e){if(!e.trim()){t.style={};return}try{t.style=(0,s.default)(e,o)}catch(e){t.style={}}}};let n=e.r(271645),s=i(e.r(515511)),a=new Set(["annotation-xml","color-profile","font-face","font-face-src","font-face-uri","font-face-format","font-face-name","missing-glyph"]),o={reactCompat:!0};r.PRESERVE_CUSTOM_ATTRIBUTES=Number(n.version.split(".")[0])>=16,r.ELEMENTS_WITH_NO_TEXT_CHILDREN=new Set(["tr","tbody","thead","tfoot","colgroup","table","head","html","frameset"]),r.canTextBeChildOfNode=e=>!r.ELEMENTS_WITH_NO_TEXT_CHILDREN.has(e.name),r.returnFirstArg=e=>e},312467,(e,t,r)=>{"use strict";
1Object.defineProperty(r,"__esModule",{value:!0}),r.default=function(e={},t){let r={},u=!!(e.type&&o[e.type]);for(let o in e){let c=e[o];if((0,i.isCustomAttribute)(o)){r[o]=c;continue}let d=o.toLowerCase(),h=l(d);if(h){let e=(0,i.getPropertyInfo)(h);switch(s.includes(h)&&a.includes(t)&&!u&&(h=l("default"+d)),r[h]=c,null==e?void 0:e.type){case i.BOOLEAN:r[h]=!0;break;case i.OVERLOADED_BOOLEAN:""===c&&(r[h]=!0)}continue}n.PRESERVE_CUSTOM_ATTRIBUTES&&(r[o]=c)}return(0,n.setStyleProp)(e.style,r),r};let i=e.r(594555),n=e.r(846335),s=["checked","value"],a=["input","select","textarea"],o={reset:!0,submit:!0};function l(e){return i.possibleStandardNames[e]}},492024,e=>{"use strict";var t,r;(r=t||(t={})).Root="root",r.Text="text",r.Directive="directive",r.Comment="comment",r.Script="script",r.Style="style",r.Tag="tag",r.CDATA="cdata",r.Doctype="doctype",t.Root,t.Text,t.Directive,t.Comment,t.Script,t.Style,t.Tag,t.CDATA,t.Doctype;class i{parent=null;prev=null;next=null;startIndex=null;endIndex=null;get parentNode(){return this.parent}set parentNode(e){this.parent=e}get previousSibling(){return this.prev}set previousSibling(e){this.prev=e}get nextSibling(){return this.next}set nextSibling(e){this.next=e}cloneNode(e=!1){return b(this,e)}}class n extends i{data;constructor(e){super(),this.data=e}get nodeValue(){return this.data}set nodeValue(e){this.data=e}}class s extends n{type=t.Text;get nodeType(){return 3}}class a extends n{type=t.Comment;get nodeType(){return 8}}class o extends n{type=t.Directive;name;constructor(e,t){super(t),this.name=e}get nodeType(){return 1}"x-name";"x-publicId";"x-systemId"}class l extends i{children;constructor(e){super(),this.children=e}get firstChild(){return this.children[0]??null}get lastChild(){return this.children.length>0?this.children[this.children.length-1]:null}get childNodes(){return this.children}set childNodes(e){this.children=e}}class u extends l{type=t.CDATA;get nodeType(){return 4}}class c extends l{type=t.Root;get nodeType(){return 9}}class d extends l{name;attribs;type;constructor(e,r,i=[],n="script"===e?t.Script:"style"===e?t.Style:t.Tag){super(i),this.name=e,this.attribs=r,this.type=n}get nodeType(){return 1}get tagName(){return this.name}set tagName(e){this.name=e}get attributes(){return Object.keys(this.attribs).map(e=>({name:e,value:this.attribs[e],namespace:this["x-attribsNamespace"]?.[e],prefix:this["x-attribsPrefix"]?.[e]}))}namespace;"x-attribsNamespace";"x-attribsPrefix"}function h(e){return e.type===t.Tag||e.type===t.Script||e.type===t.Style}function f(e){return e.type===t.CDATA}function p(e){return e.type===t.Text}function g(e){return e.type===t.Comment}function m(e){return e.type===t.Directive}function y(e){return e.type===t.Root}function v(e){return Object.hasOwn(e,"children")}function b(e,t=!1){let r;if(p(e))r=new s(e.data);else if(g(e))r=new a(e.data);else if(h(e)){let i=t?_(e.children):[],n=new d(e.name,{...e.attribs},i);for(let e of i)e.parent=n;null!=e.namespace&&(n.namespace=e.namespace),e["x-attribsNamespace"]&&(n["x-attribsNamespace"]={...e["x-attribsNamespace"]}),e["x-attribsPrefix"]&&(n["x-attribsPrefix"]={...e["x-attribsPrefix"]}),r=n}else if(f(e)){let i=t?_(e.children):[],n=new u(i);for(let e of i)e.parent=n;r=n}else if(y(e)){let i=t?_(e.children):[],n=new c(i);for(let e of i)e.parent=n;e["x-mode"]&&(n["x-mode"]=e["x-mode"]),r=n}else if(m(e)){let t=new o(e.name,e.data);null!=e["x-name"]&&(t["x-name"]=e["x-name"],t["x-publicId"]=e["x-publicId"],t["x-systemId"]=e["x-systemId"]),r=t}else throw Error(`Not implemented yet: ${e.type}`);return r.startIndex=e.startIndex,r.endIndex=e.endIndex,null!=e.sourceCodeLocation&&(r.sourceCodeLocation=e.sourceCodeLocation),r}function _(e){let t=e.map(e=>b(e,!0));for(let e=1;e<t.length;e++)t[e].prev=t[e-1],t[e-1].next=t[e];return t}e.s(["CDATA",0,u,"Comment",0,a,"DataNode",0,n,"Document",0,c,"Element",0,d,"Node",0,i,"NodeWithChildren",0,l,"ProcessingInstruction",0,o,"Text",0,s,"cloneNode",0,b,"hasChildren",0,v,"isCDATA",0,f,"isComment",0,g,"isDirective",0,m,"isDocument",0,y,"isTag",0,h,"isText",0,p],119844);let E={withStartIndices:!1,withEndIndices:!1,xmlMode:!1};class S{dom=[];root=new c(this.dom);callback;options;elementCB;done=!1;tagStack=[this.root];lastNode=null;parser=null;constructor(e,t,r){"function"==typeof t&&(r=t,t=E),"object"==typeof e&&(t=e,e=void 0),this.callback=e??null,this.options=t??E,this.elementCB=r??null}onparserinit(e){this.parser=e}onreset(){this.dom=[],this.root=new c(this.dom),this.done=!1,this.tagStack=[this.root],this.lastNode=null,this.parser=null}onend(){this.done||(this.done=!0,this.parser=null,this.handleCallback(null))}onerror(e){this.handleCallback(e)}onclosetag(){this.lastNode=null;let e=this.tagStack.pop();this.options.withEndIndices&&this.parser&&(e.endIndex=this.parser.endIndex),this.elementCB&&this.elementCB(e)}onopentag(e,r){let i=new d(e,r,void 0,this.options.xmlMode?t.Tag:void 0);this.addNode(i),this.tagStack.push(i)}ontext(e){let{lastNode:r}=this;if(r&&r.type===t.Text)r.data+=e,this.options.withEndIndices&&this.parser&&(r.endIndex=this.parser.endIndex);else{let t=new s(e);this.addNode(t),this.lastNode=t}}oncomment(e){if(this.lastNode&&this.lastNode.type===t.Comment){this.lastNode.data+=e;return}let r=new a(e);this.addNode(r),this.lastNode=r}oncommentend(){this.lastNode=null}oncdatastart(){let e=new s(""),t=new u([e]);this.addNode(t),e.parent=t,this.lastNode=e}
1oncdataend(){this.lastNode=null}onprocessinginstruction(e,t){let r=new o(e,t);this.addNode(r)}handleCallback(e){if("function"==typeof this.callback)this.callback(e,this.dom);else if(e)throw e}addNode(e){let t=this.tagStack[this.tagStack.length-1],r=t.children[t.children.length-1];this.options.withStartIndices&&this.parser&&(e.startIndex=this.parser.startIndex),this.options.withEndIndices&&this.parser&&(e.endIndex=this.parser.endIndex),t.children.push(e),r&&(e.prev=r,r.next=e),e.parent=t,this.lastNode=null}}e.s(["DomHandler",0,S,"default",0,S],195754),e.i(195754),e.i(119844),e.s(["CDATA",0,u,"Comment",0,a,"DataNode",0,n,"Document",0,c,"DomHandler",0,S,"Element",0,d,"Node",0,i,"NodeWithChildren",0,l,"ProcessingInstruction",0,o,"Text",0,s,"cloneNode",0,b,"default",0,S,"hasChildren",0,v,"isCDATA",0,f,"isComment",0,g,"isDirective",0,m,"isDocument",0,y,"isTag",0,h,"isText",0,p],492024)},454465,(e,t,r)=>{"use strict";var i=e.e&&e.e.__importDefault||function(e){return e&&e.__esModule?e:{default:e}};Object.defineProperty(r,"__esModule",{value:!0}),r.default=function e(t,r={}){var i,s,u,c,d,h;let f=[],p="function"==typeof r.replace,g=null!=(i=r.transform)?i:o.returnFirstArg,{cloneElement:m,createElement:y,isValidElement:v}=null!=(s=r.library)?s:l,b=t.length;!function e(t){for(let r of t)("tag"===r.type||"script"===r.type||"style"===r.type)&&(Object.setPrototypeOf(r,n.Element.prototype),e(r.children))}(t);for(let i=0;i<b;i++){let n,s=t[i];if(p){let e=null==(u=r.replace)?void 0:u.call(r,s,i);if(v(e)){b>1&&(e=m(e,{key:null!=(c=e.key)?c:i})),f.push(g(e,s,i));continue}}if("text"===s.type){let e=!s.data.trim().length;if(e&&s.parent&&!(0,o.canTextBeChildOfNode)(s.parent)||r.trim&&e)continue;f.push(g(s.data,s,i));continue}let l={};switch((h=s,o.PRESERVE_CUSTOM_ATTRIBUTES&&"tag"===h.type&&(0,o.isCustomComponent)(h.name,h.attribs))?((0,o.setStyleProp)(s.attribs.style,s.attribs),l=s.attribs):s.attribs&&(l=(0,a.default)(s.attribs,s.name)),s.type){case"script":case"style":s.children[0]&&(l.dangerouslySetInnerHTML={__html:s.children[0].data});break;case"tag":"textarea"===s.name&&s.children[0]?l.defaultValue=s.children[0].data:(null==(d=s.children)?void 0:d.length)&&(n=e(s.children,r));break;default:continue}b>1&&(l.key=i),f.push(g(y(s.name,l,n),s,i))}return 1===f.length?f[0]:f};let n=e.r(492024),s=e.r(271645),a=i(e.r(312467)),o=e.r(846335),l={cloneElement:s.cloneElement,createElement:s.createElement,isValidElement:s.isValidElement}},617870,(e,t,r)=>{"use strict";var i=e.e&&e.e.__importDefault||function(e){return e&&e.__esModule?e:{default:e}};Object.defineProperty(r,"__esModule",{value:!0}),r.htmlToDOM=r.domToReact=r.attributesToProps=r.Text=r.ProcessingInstruction=r.Element=r.Comment=void 0,r.default=function(e,t){var r;if("string"!=typeof e)throw TypeError("First argument must be a string");if(!e)return[];let i=Object.assign(Object.assign({},null!=(r=null==t?void 0:t.htmlparser2)?r:o),{trustedTypePolicy:null==t?void 0:t.trustedTypePolicy});return(0,s.default)((0,n.default)(e,i),t)};let n=i(e.r(971883));r.htmlToDOM=n.default,r.attributesToProps=i(e.r(312467)).default;let s=i(e.r(454465));r.domToReact=s.default;var a=e.r(492024);Object.defineProperty(r,"Comment",{enumerable:!0,get:function(){return a.Comment}}),Object.defineProperty(r,"Element",{enumerable:!0,get:function(){return a.Element}}),Object.defineProperty(r,"ProcessingInstruction",{enumerable:!0,get:function(){return a.ProcessingInstruction}}),Object.defineProperty(r,"Text",{enumerable:!0,get:function(){return a.Text}});let o={lowerCaseAttributeNames:!1}},259087,e=>{"use strict";var t=e.i(617870);let r=t.default.default||t.default;e.s(["default",0,r])},63280,e=>{"use strict";var t=e.i(843476),r=e.i(997053),i=e.i(94332),n=e.i(728016);let s=r.default.div.withConfig({displayName:"Label__Wrapper",componentId:"sc-b0298b3b-0"})` 2 margin-bottom: 8px; 3 ${e=>e.inline&&"display: inline-block"}; 4 ${e=>e.serif&&"font-family: var(--font-din-serif)"}; 5 color: ${e=>e.theme.color.gold}; 6 font-size: 14px; 7 ${i.mq.sm} { 8 font-size: 16px; 9 } 10`;e.s(["Label",0,({children:e,inline:r,className:i,serif:a,htmlFor:o,...l})=>{let u="string"==typeof e?(0,n.nbsp)(e):e;return(0,t.jsx)(s,{className:i,inline:r,serif:a,...l,children:o?(0,t.jsx)("label",{htmlFor:o,children:u}):u})}])},422233,e=>{"use strict";let t,r="u">typeof crypto&&crypto.randomUUID&&crypto.randomUUID.bind(crypto),i=new Uint8Array(16),n=[];for(let e=0;e<256;++e)n.push((e+256).toString(16).slice(1));e.s(["v4",0,function(e,s,a){if(r&&!s&&!e)return r();let o=(e=e||{}).random??e.rng?.()??function(){if(!t){if("u"<typeof crypto||!crypto.getRandomValues)throw Error("crypto.getRandomValues() not supported. See https://github.com/uuidjs/uuid#getrandomvalues-not-supported");t=crypto.getRandomValues.bind(crypto)}return t(i)}();if(o.length<16)throw Error("Random bytes length must be >= 16");if(o[6]=15&o[6]|64,o[8]=63&o[8]|128,s){if((a=a||0)<0||a+16>s.length)throw RangeError(`UUID byte range ${a}:${a+15} is out of buffer bounds`);for(let e=0;e<16;++e)s[a+e]=o[e];return s}return function(e,t=0){return(n[e[t+0]]+n[e[t+1]]+n[e[t+2]]+n[e[t+3]]+"-"+n[e[t+4]]+n[e[t+5]]+"-"+n[e[t+6]]+n[e[t+7]]+"-"+n[e[t+8]]+n[e[t+9]]+"-"+n[e[t+10]]+n[e[t+11]]+n[e[t+12]]+n[e[t+13]]+n[e[t+14]]+n[e[t+15]]).toLowerCase()}(o)}],422233)},821619,e=>{"use strict";var t=e.i(843476),r=e.i(271645),i=e.i(997053);let n=i.default.table.attrs({role:"presentation"}).withConfig({displayName:"Table__Container",componentId:"sc-a7c96b90-0"})` 11 width: 100%; 12 margin-bottom: 48px; 13 14 th, 15 td { 16 padding: 16px 24px; 17 } 18 19 th { 20 color: #fff; 21 font-family: var(--font-din-serif, serif); 22 line-height: 1.5; 23 background: ${e=>e.theme.color.gold}; 24 text-align: left; 25 } 26 27 td { 28 border-bottom: 1px solid ${e=>e.theme.color.gold}; 29 } 30`,s=i.default.div.withConfig({displayName:"Table__OverflowWrapper",componentId:"sc-a7c96b90-1"})` 31 overflow-x: auto; 32 overflow-y: hidden; 33 width: 100%; 34`;e.s(["Table",0,({children:e})=>{let i=function e(t){return r.default.Children.toArray(t).map(t=>"string"==typeof t?t.trim()?t:null:r.default.isValidElement(t)&&t.props.children?r.default.cloneElement(t,void 0,e(t.props.children)):t).filter(
34Boolean)}(e);return(0,t.jsx)(s,{children:(0,t.jsx)(n,{children:i})})}])},607135,577728,e=>{"use strict";var t=e.i(843476),r=e.i(271645);e.i(259087);var i=e.i(617870),n=e.i(422233),s=e.i(877253),a=e.i(705665),o=e.i(535289),l=e.i(312207),u=e.i(997053);let c=u.default.div.withConfig({displayName:"List__Wrapper",componentId:"sc-f71997d9-0"})` 35 counter-reset: list; 36 37 &:not(:last-child) { 38 margin-bottom: 48px; 39 } 40 41 li { 42 margin-bottom: 16px; 43 padding-left: 32px; 44 position: relative; 45 46 &:last-child { 47 margin-bottom: 0; 48 } 49 50 ${e=>"ul"===e.tag?u.css` 51 &:before { 52 width: 16px; 53 height: 1px; 54 position: absolute; 55 left: 0; 56 top: 10px; 57 background: ${e=>e.theme.color.gold}; 58 content: ''; 59 } 60 `:u.css` 61 &:before { 62 position: absolute; 63 left: 0; 64 top: 1px; 65 color: ${e=>e.theme.color.gold}; 66 counter-increment: list; 67 content: counter(list) '.'; 68 } 69 `} 70 } 71`,d=({tag:e,children:r})=>(0,t.jsx)(c,{as:e,tag:e,children:r});e.s(["List",0,d],577728);var h=e.i(821619),f=e.i(971936),p=e.i(728016);let g=u.default.blockquote.withConfig({displayName:"Blockquote__Wrapper",componentId:"sc-c9d7de28-0"})` 72 display: flex; 73 flex-direction: row; 74 margin-bottom: 48px; 75 padding-left: 65px; 76 font-family: var(--font-din-serif); 77 color: ${e=>e.theme.color.gold}; 78 position: relative; 79 line-height: 1.5 !important; 80 font-style: italic; 81 82 &:before { 83 width: 0; 84 height: 0; 85 position: absolute; 86 left: -12px; 87 top: 6px; 88 font-size: 80px; 89 content: 'â'; 90 line-height: 1; 91 } 92 93 p { 94 line-height: 1.5; 95 margin-bottom: 0; 96 } 97 98 p + p { 99 margin-top: 16px; 100 } 101`,m=({children:e})=>(0,t.jsx)(g,{children:"string"==typeof e?(0,p.nbsp)(e):e}),y=(e,t)=>(0,i.domToReact)(e||[],t),v={h1:{size:"lg",serif:!0,color:"gold",marginBottom:"lg"},h2:{size:"md",marginBottom:"md"},h3:{size:"sm",marginBottom:"sm"},h4:{size:"xs",marginBottom:"xs"},h5:{size:"xs",marginBottom:"xs"},h6:{size:"xs",marginBottom:"xs"}};function b(e){return!!e&&"http"!==e.substring(0,4)&&"mailto:"!==e.substring(0,7)&&"tel:"!==e.substring(0,4)}let _=new class{headingLevelQueue=[];replace(e){if("tag"===e.type)switch(e.name){case"a":{let i=e.attribs;if(!i||!e.children)return(0,t.jsx)(r.Fragment,{},(0,n.v4)());{delete i.style;let a=i.class;
101if(a&&(i.className=a,delete i.class),void 0!==i["data-button"]||"button"===i.rel||"string"==typeof a&&/(\bbtn\b|\bbutton\b)/i.test(String(a))){let r=i.href||"",o=b(r),l=String(i["data-button"]||"").toLowerCase(),u="string"==typeof a&&/\b(gold|transparent|black|white|darkGold)\b/.exec(a||"")||void 0,c=l||u&&u[1]||"gold",d=i["data-icon"]?String(i["data-icon"]):void 0,h=i["data-params"]?String(i["data-params"]):"",f=r;return h&&(f=r+(r&&-1!==r.indexOf("?")?"&":"?")+h),delete i["data-button"],delete i["data-icon"],delete i["data-params"],(0,t.jsx)(s.Button,{type:c,icon:d||null,iconOnLeft:!0,href:f,external:!o,paddingX:32,paddingY:12,children:y(e.children,_)},(0,n.v4)())}if(b(i.href))return(0,r.createElement)(l.Link,{...i,key:(0,n.v4)(),inverseHover:!0,color:"gold"},e.children?(0,t.jsx)(t.Fragment,{children:y(e.children,_)}):(0,t.jsx)(t.Fragment,{}));return(0,t.jsx)(l.Link,{...i,inverseHover:!0,color:"gold",children:y(e.children,_)},(0,n.v4)())}}case"h1":case"h2":case"h3":case"h4":case"h5":case"h6":{if(!e.children)return(0,t.jsx)(r.Fragment,{},(0,n.v4)());let i=e.name,s=v[i],o=parseInt(i[1],10),l=this.headingLevelQueue.length>0?this.headingLevelQueue.shift():o;return(0,t.jsx)(a.Heading,{tag:`h${l}`,size:s.size,serif:s.serif,color:s.color,marginBottom:s.marginBottom,children:y(e.children,_)},(0,n.v4)())}case"table":if(e.children)return(0,t.jsx)(h.Table,{children:y(e.children,_)},(0,n.v4)());return(0,t.jsx)(r.Fragment,{},(0,n.v4)());case"p":if(e.children&&e.children.length>0)return(0,t.jsx)(f.Paragraph,{bigLh:!0,children:y(e.children,_)},(0,n.v4)());return(0,t.jsx)(r.Fragment,{},(0,n.v4)());case"ul":if(e.children&&e.children.length>0)return(0,t.jsx)(d,{tag:"ul",children:y(e.children,_)},(0,n.v4)());return(0,t.jsx)(r.Fragment,{},(0,n.v4)());case"ol":if(e.children&&e.children.length>0)return(0,t.jsx)(d,{tag:"ol",children:y(e.children,_)},(0,n.v4)());return(0,t.jsx)(r.Fragment,{},(0,n.v4)());case"blockquote":if(e.children&&e.children.length>0)return(0,t.jsx)(m,{children:y(e.children,_)},(0,n.v4)());return(0,t.jsx)(r.Fragment,{},(0,n.v4)());case"iframe":return(0,t.jsx)("iframe",{...(0,i.attributesToProps)(e.attribs)});case"img":{let r=e.attribs;if(r){let{src:e,alt:s,...a}=(0,i.attributesToProps)(r);return(0,t.jsx)("span",{style:{padding:"16px",display:"inline-block"},children:(0,t.jsx)(o.Image,{src:"string"==typeof e?e:"",alt:"string"==typeof s?s:"",...a})},(0,n.v4)())}break}case"b":return(0,t.jsx)("strong",{children:y(e.children,_)},(0,n.v4)());case"i":return(0,t.jsx)("em",{children:y(e.children,_)},(0,n.v4)())}if("text"===e.type){let r=String(e.data||""),i=r.trim(),a=/^\{button\|([a-z0-9-]+)\|([^}]+)\}$/i.exec(i);if(a){let e=a[1].toLowerCase(),r=a[2]&&a[2].trim();return(0,t.jsx)(s.Button,{type:"transparent",iconOnLeft:!0,page:{url:{"prehled-ceduli":"mecenassky-klub-nd/zachranujeme-historicke-cedule/prehled-ceduli"}[e]||e},paddingX:32,paddingY:12,children:r},(0,n.v4)())}let o=/^\{button-([a-z0-9-]+)(?:\|([^}]+))?\}$/i.exec(i);if(o){let e=o[1].toLowerCase(),r=o[2]&&o[2].trim();return(0,t.jsx)(s.Button,{type:"gold",iconOnLeft:!0,page:{url:"mecenassky-klub-nd/zachranujeme-historicke-cedule/podporit-projekt-formular"},params:{categorySlug:e},paddingX:32,paddingY:12,children:r},(0,n.v4)())}return(0,t.jsx)(t.Fragment,{children:(0,p.nbsp)(r)})}}};e.s(["extractHeadingLevels",0,function(e){let t,r=[],i=/<h([1-6])[\s>]/gi;for(;null!==(t=i.exec(e));)r.push(parseInt(t[1],10));return r},"parserOptions",0,_,"precomputeRichTextHeadingLevels",0,function(e,t){return e.map(e=>{let r,i=(r=t.hasH1?2:1,null===t.lastLevel?r:Math.max(r,Math.min(6,Math.min(e,t.lastLevel+1))));return t.lastLevel=i,1===i&&(t.hasH1=!0),i})}],607135)},432892,(e,t,r)=>{"use strict";var i=Array.isArray,n=Object.keys,s=Object.prototype.hasOwnProperty,a="u">typeof Element;t.exports=function(e,t){try{return function e(t,r){if(t===r)return!0;if(t&&r&&"object"==typeof t&&"object"==typeof r){var o,l,u,c=i(t),d=i(r);if(c&&d){if((l=t.length)!=r.length)return!1;for(o=l;0!=o--;)if(!e(t[o],r[o]))return!1;return!0}if(c!=d)return!1;var h=t instanceof Date,f=r instanceof Date;if(h!=f)return!1;if(h&&f)return t.getTime()==r.getTime();var p=t instanceof RegExp,g=r instanceof RegExp;if(p!=g)return!1;if(p&&g)return t.toString()==r.toString();var m=n(t);if((l=m.length)!==n(r).length)return!1;for(o=l;0!=o--;)if(!s.call(r,m[o]))return!1;if(a&&t instanceof Element&&r instanceof Element)return t===r;for(o=l;0!=o--;)if(("_owner"!==(u=m[o])||!t.$$typeof)&&!e(t[u],r[u]))return!1;return!0}return t!=t&&r!=r}(e,t)}catch(e){if(e.message&&e.message.match(/stack|recursion/i)||-0x7ff5ffe4===e.number)return console.warn("Warning: react-fast-compare does not handle circular references.",e.name,e.message),!1;throw e}}},552210,(e,t,r)=>{"use strict";var i="function"==typeof Symbol&&Symbol.for,n=i?Symbol.for("react.element"):60103,s=i?Symbol.for("react.portal"):60106,a=i?Symbol.for("react.fragment"):60107,o=i?Symbol.for("react.strict_mode"):60108,l=i?Symbol.for("react.profiler"):60114,u=i?Symbol.for("react.provider"):60109,c=i?Symbol.for("react.context"):60110,d=i?Symbol.for("react.async_mode"):60111,h=i?Symbol.for("react.concurrent_mode"):60111,f=i?Symbol.for("react.forward_ref"):60112,p=i?Symbol.for("react.suspense"):60113,g=i?Symbol.for("react.suspense_list"):60120,m=i?Symbol.for("react.memo"):60115,y=i?Symbol.for("react.lazy"):60116,v=i?Symbol.for("react.block"):60121,b=i?Symbol.for("react.fundamental"):60117,_=i?Symbol.for("react.responder"):60118,E=i?Symbol.for("react.scope"):60119;function S(e){if("object"==typeof e&&null!==e){var t=e.$$typeof;switch(t){case n:switch(e=e.type){case d:case h:case a:case l:case o:case p:return e;default:switch(e=e&&e.$$typeof){case c:case f:case y:case m:case u:return e;default:return t}}case s:return t}}}function x(e){return S(e)===h}r.AsyncMode=d,r.ConcurrentMode=h,r.ContextConsumer=c,r.ContextProvider=u,r.Element=n,r.ForwardRef=f,r.Fragment=a,r.Lazy=y,r.Memo=m,r.Portal=s,r.Profiler=l,r.StrictMode=o,r.
101Suspense=p,r.isAsyncMode=function(e){return x(e)||S(e)===d},r.isConcurrentMode=x,r.isContextConsumer=function(e){return S(e)===c},r.isContextProvider=function(e){return S(e)===u},r.isElement=function(e){return"object"==typeof e&&null!==e&&e.$$typeof===n},r.isForwardRef=function(e){return S(e)===f},r.isFragment=function(e){return S(e)===a},r.isLazy=function(e){return S(e)===y},r.isMemo=function(e){return S(e)===m},r.isPortal=function(e){return S(e)===s},r.isProfiler=function(e){return S(e)===l},r.isStrictMode=function(e){return S(e)===o},r.isSuspense=function(e){return S(e)===p},r.isValidElementType=function(e){return"string"==typeof e||"function"==typeof e||e===a||e===h||e===l||e===o||e===p||e===g||"object"==typeof e&&null!==e&&(e.$$typeof===y||e.$$typeof===m||e.$$typeof===u||e.$$typeof===c||e.$$typeof===f||e.$$typeof===b||e.$$typeof===_||e.$$typeof===E||e.$$typeof===v)},r.typeOf=S},179684,(e,t,r)=>{"use strict";t.exports=e.r(552210)},398437,(e,t,r)=>{"use strict";var i=e.r(179684),n={childContextTypes:!0,contextType:!0,contextTypes:!0,defaultProps:!0,displayName:!0,getDefaultProps:!0,getDerivedStateFromError:!0,getDerivedStateFromProps:!0,mixins:!0,propTypes:!0,type:!0},s={name:!0,length:!0,prototype:!0,caller:!0,callee:!0,arguments:!0,arity:!0},a={$$typeof:!0,compare:!0,defaultProps:!0,displayName:!0,propTypes:!0,type:!0},o={};function l(e){return i.isMemo(e)?a:o[e.$$typeof]||n}o[i.ForwardRef]={$$typeof:!0,render:!0,defaultProps:!0,displayName:!0,propTypes:!0},o[i.Memo]=a;var u=Object.defineProperty,c=Object.getOwnPropertyNames,d=Object.getOwnPropertySymbols,h=Object.getOwnPropertyDescriptor,f=Object.getPrototypeOf,p=Object.prototype;t.exports=function e(t,r,i){if("string"!=typeof r){if(p){var n=f(r);n&&n!==p&&e(t,n,i)}var a=c(r);d&&(a=a.concat(d(r)));for(var o=l(t),g=l(r),m=0;m<a.length;++m){var y=a[m];if(!s[y]&&!(i&&i[y])&&!(g&&g[y])&&!(o&&o[y])){var v=h(r,y);try{u(t,y,v)}catch(e){}}}}return t}},812497,e=>{"use strict";e.i(247167);var t,r,i,n=function(e){var t,r,i;return!!(t=e)&&"object"==typeof t&&(r=e,"[object RegExp]"!==(i=Object.prototype.toString.call(r))&&"[object Date]"!==i&&r.$$typeof!==s)},s="function"==typeof Symbol&&Symbol.for?Symbol.for("react.element"):60103;function a(e,t){return!1!==t.clone&&t.isMergeableObject(e)?l(Array.isArray(e)?[]:{},e,t):e}function o(e,t,r){return e.concat(t).map(function(e){return a(e,r)})}function l(e,t,r){(r=r||{}).arrayMerge=r.arrayMerge||o,r.isMergeableObject=r.isMergeableObject||n;var i,s,u=Array.isArray(t);return u!==Array.isArray(e)?a(t,r):u?r.arrayMerge(e,t,r):(s={},(i=r).isMergeableObject(e)&&Object.keys(e).forEach(function(t){s[t]=a(e[t],i)}),Object.keys(t).forEach(function(r){i.isMergeableObject(t[r])&&e[r]?s[r]=l(e[r],t[r],i):s[r]=a(t[r],i)}),s)}l.all=function(e,t){if(!Array.isArray(e))throw Error("first argument should be an array");return e.reduce(function(e,r){return l(e,r,t)},{})};let u=l;var c=e.g&&e.g.Object===Object&&e.g,d="object"==typeof self&&self&&self.Object===Object&&self,h=c||d||Function("return this")(),f=h.Symbol,p=Object.prototype,g=p.hasOwnProperty,m=p.toString,y=f?f.toStringTag:void 0;let v=function(e){var t=g.call(e,y),r=e[y];try{e[y]=void 0;var i=!0}catch(e){}var n=m.call(e);return i&&(t?e[y]=r:delete e[y]),n};var b=Object.prototype.toString,_=f?f.toStringTag:void 0;let E=function(e){return null==e?void 0===e?"[object Undefined]":"[object Null]":_&&_ in Object(e)?v(e):b.call(e)},S=function(e,t){return function(r){return e(t(r))}};var x=S(Object.getPrototypeOf,Object);let T=function(e){return null!=e&&"object"==typeof e};var w=Object.prototype,A=Function.prototype.toString,R=w.hasOwnProperty,I=A.call(Object);let k=function(e){if(!T(e)||"[object Object]"!=E(e))return!1;var t=x(e);if(null===t)return!0;var r=R.call(t,"constructor")&&t.constructor;return"function"==typeof r&&r instanceof r&&A.call(r)==I},C=function(e,t){return e===t||e!=e&&t!=t},D=function(e,t){for(var r=e.length;r--;)if(C(e[r][0],t))return r;return -1};var L=Array.prototype.splice;function O(e){var t=-1,r=null==e?0:e.length;for(this.clear();++t<r;){var i=e[t];this.set(i[0],i[1])}}O.prototype.clear=function(){this.__data__=[],this.size=0},O.prototype.delete=function(e){var t=this.__data__,r=D(t,e);return!(r<0)&&(r==t.length-1?t.pop():L.call(t,r,1),--this.size,!0)},O.prototype.get=function(e){var t=this.__data__,r=D(t,e);return r<0?void 0:t[r][1]},O.prototype.has=function(e){return D(this.__data__,e)>-1},O.prototype.set=function(e,t){var r=this.__data__,i=D(r,e);return i<0?(++this.size,r.push([e,t])):r[i][1]=t,this};let P=function(e){var t=typeof e;return null!=e&&("object"==t||"function"==t)},F=function(e){if(!P(e))return!1;var t=E(e);return"[object Function]"==t||"[object GeneratorFunction]"==t||"[object AsyncFunction]"==t||"[object Proxy]"==t};var N=h["__core-js_shared__"],M=(t=/[^.]+$/.exec(N&&N.keys&&N.keys.IE_PROTO||""))?"Symbol(sr
101c)_1."+t:"",j=Function.prototype.toString;let $=function(e){if(null!=e){try{return j.call(e)}catch(e){}try{return e+""}catch(e){}}return""};var U=/^\[object .+?Constructor\]$/,B=Object.prototype,V=Function.prototype.toString,G=B.hasOwnProperty,q=RegExp("^"+V.call(G).replace(/[\\^$.*+?()[\]{}|]/g,"\\$&").replace(/hasOwnProperty|(function).*?(?=\\\()| for .+?(?=\\\])/g,"$1.*?")+"$");let H=function(e){return!!P(e)&&(!M||!(M in e))&&(F(e)?q:U).test($(e))},z=function(e,t){var r=null==e?void 0:e[t];return H(r)?r:void 0};var K=z(h,"Map"),W=z(Object,"create"),Y=Object.prototype.hasOwnProperty,Q=Object.prototype.hasOwnProperty;function X(e){var t=-1,r=null==e?0:e.length;for(this.clear();++t<r;){var i=e[t];this.set(i[0],i[1])}}X.prototype.clear=function(){this.__data__=W?W(null):{},this.size=0},X.prototype.delete=function(e){var t=this.has(e)&&delete this.__data__[e];return this.size-=!!t,t},X.prototype.get=function(e){var t=this.__data__;if(W){var r=t[e];return"__lodash_hash_undefined__"===r?void 0:r}return Y.call(t,e)?t[e]:void 0},X.prototype.has=function(e){var t=this.__data__;return W?void 0!==t[e]:Q.call(t,e)},X.prototype.set=function(e,t){var r=this.__data__;return this.size+=+!this.has(e),r[e]=W&&void 0===t?"__lodash_hash_undefined__":t,this};let J=function(e){var t=typeof e;return"string"==t||"number"==t||"symbol"==t||"boolean"==t?"__proto__"!==e:null===e},Z=function(e,t){var r=e.__data__;return J(t)?r["string"==typeof t?"string":"hash"]:r.map};function ee(e){var t=-1,r=null==e?0:e.length;for(this.clear();++t<r;){var i=e[t];this.set(i[0],i[1])}}function et(e){var t=this.__data__=new O(e);this.size=t.size}ee.prototype.clear=function(){this.size=0,this.__data__={hash:new X,map:new(K||O),string:new X}},ee.prototype.delete=function(e){var t=Z(this,e).delete(e);return this.size-=!!t,t},ee.prototype.get=function(e){return Z(this,e).get(e)},ee.prototype.has=function(e){return Z(this,e).has(e)},ee.prototype.set=function(e,t){var r=Z(this,e),i=r.size;return r.set(e,t),this.size+=+(r.size!=i),this},et.prototype.clear=function(){this.__data__=new O,this.size=0},et.prototype.delete=function(e){var t=this.__data__,r=t.delete(e);return this.size=t.size,r},et.prototype.get=function(e){return this.__data__.get(e)},et.prototype.has=function(e){return this.__data__.has(e)},et.prototype.set=function(e,t){var r=this.__data__;if(r instanceof O){var i=r.__data__;if(!K||i.length<199)return i.push([e,t]),this.size=++r.size,this;r=this.__data__=new ee(i)}return r.set(e,t),this.size=r.size,this};let er=function(e,t){for(var r=-1,i=null==e?0:e.length;++r<i&&!1!==t(e[r],r,e););return e};var ei=function(){try{var e=z(Object,"defineProperty");return e({},"",{}),e}catch(e){}}();let en=function(e,t,r){"__proto__"==t&&ei?ei(e,t,{configurable:!0,enumerable:!0,value:r,writable:!0}):e[t]=r};var es=Object.prototype.hasOwnProperty;let ea=function(e,t,r){var i=e[t];es.call(e,t)&&C(i,r)&&(void 0!==r||t in e)||en(e,t,r)},eo=function(e,t,r,i){var n=!r;r||(r={});for(var s=-1,a=t.length;++s<a;){var o=t[s],l=i?i(r[o],e[o],o,r,e):void 0;void 0===l&&(l=e[o]),n?en(r,o,l):ea(r,o,l)}return r},el=function(e,t){for(var r=-1,i=Array(e);++r<e;)i[r]=t(r);return i},eu=function(e){return T(e)&&"[object Arguments]"==E(e)};var ec=Object.prototype,ed=ec.hasOwnProperty,eh=ec.propertyIsEnumerable,ef=eu(function(){return arguments}())?eu:function(e){return T(e)&&ed.call(e,"callee")&&!eh.call(e,"callee")},ep=Array.isArray;let eg=function(){return!1};var em=/^(?:0|[1-9]\d*)$/;let ey=function(e,t){var r=typeof e;return!!(t=null==t?0x1fffffffffffff:t)&&("number"==r||"symbol"!=r&&em.test(e))&&e>-1&&e%1==0&&e<t},ev=function(e){return"number"==typeof e&&e>-1&&e%1==0&&e<=0x1fffffffffffff};var eb={};eb["[object Float32Array]"]=eb["[object Float64Array]"]=eb["[object Int8Array]"]=eb["[object Int16Array]"]=eb["[object Int32Array]"]=eb["[object Uint8Array]"]=eb["[object Uint8ClampedArray]"]=eb["[object Uint16Array]"]=eb["[object Uint32Array]"]=!0,eb["[object Arguments]"]=eb["[object Array]"]=eb["[object ArrayBuffer]"]=eb["[object Boolean]"]=eb["[object DataView]"]=eb["[object Date]"]=eb["[object Error]"]=eb["[object Function]"]=eb["[object Map]"]=eb["[object Number]"]=eb["[object Object]"]=eb["[object RegExp]"]=eb["[object Set]"]=eb["[object String]"]=eb["[object WeakMap]"]=!1;let e_=function(e){return function(t){return e(t)}};var eE=function(){try{return!1}catch(e){}}(),eS=eE&&eE.isTypedArray,ex=eS?e_(eS):function(e){return T(e)&&ev(e.length)&&!!eb[E(e)]},eT=Object.prototype.hasOwnProperty;let ew=function(e,t){var r=ep(e),i=!r&&ef(e),n=!r&&!i&&eg(e),s=!r&&!i&&!n&&ex(e),a=r||i||n||s,o=a?el(e.length,String):[],l=o.length;for(var u in e)(t||eT.call(e,u))&&!(a&&("length"==u||n&&("offset"==u||"parent"==u)||s&&("buffer"==u||"byteLength"==u||"byteOffset"==u)||ey(u,l)))&&o.push(u);return o};var eA=Object.prototype;let eR=function(e){var t=e&&e.constructor;return e===("function"==typeof t&&t.prototype||eA)};var eI=S(Object.keys,Object),ek=Object.prototype.hasOwnProperty;let eC=function(e){if(!eR(e))return eI(e);var t=[];for(var r in Object(e))ek.call(e,r)&&"constructor"!=r&&t.push(r);return t},eD=function(e){return null!=e&&ev(e.length)&&!F(e)},eL=function(e){return eD(e)?ew(e):eC(e)},eO=function(e){var t=[];if(null!=e)for(var r in Object(e))t.push(r);return t};var eP=Object.prototype.hasOwnProperty;let eF=function(e){if(!P(e))return eO(e);var t=eR(e),r=[];for(var i in e)"constructor"==i&&(t||!eP.call(e,i))||r.push(i);return r},eN=function(e){return eD(e)?ew(e,!0):eF(e)},eM=function(e,t){if(t)return e.slice();var r=e.length,i=new e.constructor(r);return e.copy(i),i},ej=function(e,t){var r=-1,i=e.length;for(t||(t=Array(i));++r<i;)t[r]=e[r];return t},e$=function(e,t){for(var r=-1,i=null==e?0:e.length,n=0,s=[];++r<i;){var a=e[r];t(a,r,e)&&(s[n++]=a)}return s},eU=function(){return[]};var eB=Object.prototype.propertyIsEnumerable,eV=Object.getOwnPropertySymbols,eG=eV?function(e){return null==e?[]:e$(eV(e=Object(e)),function(t){return eB.call(e,t)})}:eU;let eq=function(e,t){for(var r=-1,i=t.length,n=e.length;++r<i;)e[n+r]=t[r];return e};var eH=Object.getOwnPropertySymbols?function(e){for(var t=[];e;)eq(t,eG(e)),e=x(e);return t}:eU;let ez=function(e,t,r){var i=t(e);return ep(e)?i:eq(i,r(e))},eK=function(e){return ez(e,eL,eG)},eW=function(e){return ez(e,eN,eH)};var eY=z(h,"DataView"),eQ=z(h,"Promise"),eX=z(h,"Set"),eJ=z(h,"WeakMap"),eZ="[object Map]",e0="[object Promise]",e1="[object Set]",e2="[object WeakMap]",e3="[object DataView]",e4=$(eY),e5=$(K),e8=$(eQ),e6=$(eX),e7=$(eJ),e9=E;(eY&&e9(new eY(new ArrayBuffer(1)))!=e3||K&&e9(new K)!=eZ||eQ&&e9(eQ.resolve())!=e0||eX&&e9(new eX)!=e1||eJ&&e9(new eJ)!=e2)&&(e9=function(e){var t=E(e),r="[object Object]"==t?e.constructor:void 0,i=r?$(r):"";if(i)switch(i){case e4:return e3;case e5:return eZ;case e8:return e0;case e6:return e1;case e7:return e2}return t});let te=e9;var tt=Object.prototype.hasOwnProperty;let tr=function(e){var t=e.length,r=new e.constructor(t);return t&&"string"==typeof e[0]&&tt.call(e,"index")&&(r.index=e.index,r.input
101=e.input),r};var ti=h.Uint8Array;let tn=function(e){var t=new e.constructor(e.byteLength);return new ti(t).set(new ti(e)),t},ts=function(e,t){var r=t?tn(e.buffer):e.buffer;return new e.constructor(r,e.byteOffset,e.byteLength)};var ta=/\w*$/;let to=function(e){var t=new e.constructor(e.source,ta.exec(e));return t.lastIndex=e.lastIndex,t};var tl=f?f.prototype:void 0,tu=tl?tl.valueOf:void 0;let tc=function(e,t){var r=t?tn(e.buffer):e.buffer;return new e.constructor(r,e.byteOffset,e.length)},td=function(e,t,r){var i=e.constructor;switch(t){case"[object ArrayBuffer]":return tn(e);case"[object Boolean]":case"[object Date]":return new i(+e);case"[object DataView]":return ts(e,r);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 tc(e,r);case"[object Map]":case"[object Set]":return new i;case"[object Number]":case"[object String]":return new i(e);case"[object RegExp]":return to(e);case"[object Symbol]":return tu?Object(tu.call(e)):{}}};var th=Object.create,tf=function(){function e(){}return function(t){if(!P(t))return{};if(th)return th(t);e.prototype=t;var r=new e;return e.prototype=void 0,r}}(),tp=eE&&eE.isMap,tg=tp?e_(tp):function(e){return T(e)&&"[object Map]"==te(e)},tm=eE&&eE.isSet,ty=tm?e_(tm):function(e){return T(e)&&"[object Set]"==te(e)},tv="[object Arguments]",tb="[object Function]",t_="[object Object]",tE={};tE[tv]=tE["[object Array]"]=tE["[object ArrayBuffer]"]=tE["[object DataView]"]=tE["[object Boolean]"]=tE["[object Date]"]=tE["[object Float32Array]"]=tE["[object Float64Array]"]=tE["[object Int8Array]"]=tE["[object Int16Array]"]=tE["[object Int32Array]"]=tE["[object Map]"]=tE["[object Number]"]=tE[t_]=tE["[object RegExp]"]=tE["[object Set]"]=tE["[object String]"]=tE["[object Symbol]"]=tE["[object Uint8Array]"]=tE["[object Uint8ClampedArray]"]=tE["[object Uint16Array]"]=tE["[object Uint32Array]"]=!0,tE["[object Error]"]=tE[tb]=tE["[object WeakMap]"]=!1;let tS=function e(t,r,i,n,s,a){var o,l=1&r,u=2&r,c=4&r;if(i&&(o=s?i(t,n,s,a):i(t)),void 0!==o)return o;if(!P(t))return t;var d=ep(t);if(d){if(o=tr(t),!l)return ej(t,o)}else{var h,f,p,g,m,y=te(t),v=y==tb||"[object GeneratorFunction]"==y;if(eg(t))return eM(t,l);if(y==t_||y==tv||v&&!s){if(o=u||v||"function"!=typeof(h=t).constructor||eR(h)?{}:tf(x(h)),!l)return u?(p=(f=o)&&eo(t,eN(t),f),eo(t,eH(t),p)):(m=(g=o)&&eo(t,eL(t),g),eo(t,eG(t),m))}else{if(!tE[y])return s?t:{};o=td(t,y,l)}}a||(a=new et);var b=a.get(t);if(b)return b;a.set(t,o),ty(t)?t.forEach(function(n){o.add(e(n,r,i,n,t,a))}):tg(t)&&t.forEach(function(n,s){o.set(s,e(n,r,i,s,t,a))});var _=c?u?eW:eK:u?eN:eL,E=d?void 0:_(t);return er(E||t,function(n,s){E&&(n=t[s=n]),ea(o,s,e(n,r,i,s,t,a))}),o},tx=function(e){return tS(e,5)};var tT=e.i(271645),tw=e.i(432892);let tA=function(e,t){},tR=function(e){return tS(e,4)},tI=function(e,t){for(var r=-1,i=null==e?0:e.length,n=Array(i);++r<i;)n[r]=t(e[r],r,e);return n},tk=function(e){return"symbol"==typeof e||T(e)&&"[object Symbol]"==E(e)};function tC(e,t){if("function"!=typeof e||null!=t&&"function"!=typeof t)throw TypeError("Expected a function");var r=function(){var i=arguments,n=t?t.apply(this,i):i[0],s=r.cache;if(s.has(n))return s.get(n);var a=e.apply(this,i);return r.cache=s.set(n,a)||s,a};return r.cache=new(tC.Cache||ee),r}tC.Cache=ee;var tD=/[^.[\]]+|\[(?:(-?\d+(?:\.\d+)?)|(["'])((?:(?!\2)[^\\]|\\.)*?)\2)\]|(?=(?:\.|\[\])(?:\.|\[\]|$))/g,tL=/\\(\\)?/g,tO=(i=(r=tC(function(e){var t=[];return 46===e.charCodeAt(0)&&t.push(""),e.replace(tD,function(e,r,i,n){t.push(i?n.replace(tL,"$1"):r||e)}),t},function(e){return 500===i.size&&i.clear(),e})).cache,r),tP=1/0;let tF=function(e){if("string"==typeof e||tk(e))return e;var t=e+"";return"0"==t&&1/e==-tP?"-0":t};var tN=1/0,tM=f?f.prototype:void 0,tj=tM?tM.toString:void 0;let t$=function e(t){if("string"==typeof t)return t;if(ep(t))return tI(t,e)+"";if(tk(t))return tj?tj.call(t):"";var r=t+"";return"0"==r&&1/t==-tN?"-0":r}
101,tU=function(e){return ep(e)?tI(e,tF):tk(e)?[e]:ej(tO(null==e?"":t$(e)))};function tB(){return(tB=Object.assign||function(e){for(var t=1;t<arguments.length;t++){var r=arguments[t];for(var i in r)Object.prototype.hasOwnProperty.call(r,i)&&(e[i]=r[i])}return e}).apply(this,arguments)}e.i(398437);function tV(e,t){if(null==e)return{};var r,i,n={},s=Object.keys(e);for(i=0;i<s.length;i++)r=s[i],t.indexOf(r)>=0||(n[r]=e[r]);return n}function tG(e){if(void 0===e)throw ReferenceError("this hasn't been initialised - super() hasn't been called");return e}var tq=(0,tT.createContext)(void 0);tq.displayName="FormikContext";var tH=tq.Provider;function tz(){var e=(0,tT.useContext)(tq);return e||tA(!1),e}tq.Consumer;var tK=function(e){return Array.isArray(e)&&0===e.length},tW=function(e){return"function"==typeof e},tY=function(e){return null!==e&&"object"==typeof e},tQ=function(e){return"[object String]"===Object.prototype.toString.call(e)},tX=function(e){return 0===tT.Children.count(e)},tJ=function(e){return tY(e)&&tW(e.then)};function tZ(e,t,r,i){void 0===i&&(i=0);for(var n=tU(t);e&&i<n.length;)e=e[n[i++]];return i===n.length||e?void 0===e?r:e:r}function t0(e,t,r){for(var i=tR(e),n=i,s=0,a=tU(t);s<a.length-1;s++){var o=a[s],l=tZ(e,a.slice(0,s+1));if(l&&(tY(l)||Array.isArray(l)))n=n[o]=tR(l);else{var u=a[s+1];n=n[o]=String(Math.floor(Number(u)))===u&&Number(u)>=0?[]:{}}}return(0===s?e:n)[a[s]]===r?e:(void 0===r?delete n[a[s]]:n[a[s]]=r,0===s&&void 0===r&&delete i[a[s]],i)}var t1={},t2={};function t3(e,t,r){var i=e.slice();return t.forEach(function(t,n){if(void 0===i[n]){var s=!1!==r.clone&&r.isMergeableObject(t);i[n]=s?u(Array.isArray(t)?[]:{},t,r):t}else r.isMergeableObject(t)?i[n]=u(e[n],t,r):-1===e.indexOf(t)&&i.push(t)}),i}var t4="u">typeof window&&void 0!==window.document&&void 0!==window.document.createElement?tT.useLayoutEffect:tT.useEffect;function t5(e){var t=(0,tT.useRef)(e);return t4(function(){t.current=e}),(0,tT.useCallback)(function(){for(var e=arguments.length,r=Array(e),i=0;i<e;i++)r[i]=arguments[i];return t.current.apply(void 0,r)},[])}(0,tT.forwardRef)(function(e,t){var r=e.action,i=tV(e,["action"]),n=tz(),s=n.handleReset,a=n.handleSubmit;return(0,tT.createElement)("form",tB({onSubmit:a,ref:t,onReset:s,action:null!=r?r:"#"},i))}).displayName="Form";var t8=function(e,t,r){var i=re(e),n=i[t];return i.splice(t,1),i.splice(r,0,n),i},t6=function(e,t,r){var i=re(e),n=i[t];return i[t]=i[r],i[r]=n,i},t7=function(e,t,r){var i=re(e);return i.splice(t,0,r),i},t9=function(e,t,r){var i=re(e);return i[t]=r,i},re=function(e){if(!e)return[];if(Array.isArray(e))return[].concat(e);var t=Object.keys(e).map(function(e){return parseInt(e)}).reduce(function(e,t){return t>e?t:e},0);return Array.from(tB({},e,{length:t+1}))},rt=function(e,t){var r="function"==typeof e?e:t;return function(e){return Array.isArray(e)||tY(e)?r(re(e)):e}};(function(e){function t(t){var r;return(r=e.call(this,t)||this).updateArrayField=function(e,t,i){var n=r.props,s=n.name;(0,n.formik.setFormikState)(function(r){var n=rt(i,e),a=rt(t,e),o=t0(r.values,s,e(tZ(r.values,s))),l=i?n(tZ(r.errors,s)):void 0,u=t?a(tZ(r.touched,s)):void 0;return tK(l)&&(l=void 0),tK(u)&&(u=void 0),tB({},r,{values:o,errors:i?t0(r.errors,s,l):r.errors,touched:t?t0(r.touched,s,u):r.touched})})},r.push=function(e){return r.updateArrayField(function(t){return[].concat(re(t),[tx(e)])},!1,!1)},r.handlePush=function(e){return function(){return r.push(e)}},r.swap=function(e,t){return r.updateArrayField(function(r){return t6(r,e,t)},!0,!0)},r.handleSwap=function(e,t){return function(){return r.swap(e,t)}},r.move=function(e,t){return r.updateArrayField(function(r){return t8(r,e,t)},!0,!0)},r.handleMove=function(e,t){return function(){return r.move(e,t)}},r.insert=function(e,t){return r.updateArrayField(function(r){return t7(r,e,t)},function(t){return t7(t,e,null)},function(t){return t7(t,e,null)})},r.handleInsert=function(e,t){return function(){return r.insert(e,t)}},r.replace=function(e,t){return r.updateArrayField(function(r){return t9(r,e,t)},!1,!1)},r.handleReplace=function(e,t){return function(){return r.replace(e,t)}},r.unshift=function(e){var t=-1;return r.updateArrayField(function(r){var i=r?[e].concat(r):[e];return t=i.length,i},function(e){return e?[null].concat(e):[null]},function(e){return e?[null].concat(e):[null]}),t},r.handleUnshift=function(e){return function(){return r.unshift(e)}},r.handleRemove=function(e){return function(){return r.remove(e)}},r.handlePop=function(){return function(){return r.pop()}},r.remove=r.remove.bind(tG(r)),r.pop=r.pop.bind(tG(r)),r}(r=t).prototype=Object.create((i=e).prototype),r.prototype.constructor=r,r.__proto__=i;var r,i,n=t.prototype;return n.componentDidUpdate=function(e){this.props.validateOnChange&&this.props.formik.validateOnChange&&!(0,tw.default)(tZ(e.formik.values,e.name),tZ(this.props.formik.values,this.props.name))&&this.props.formik.validateForm(this.props.formik.values)},n.remove=function(e){var t;return this.updateArrayField(function(r){var i=r?re(r):[];return t||(t=i[e]),tW(i.splice)&&i.splice(e,1),tW(i.every)&&i.every(function(e){return void 0===e})?[]:i},!0,!0),t},n.pop=function(){var e;return this.updateArrayField(function(t){var r=t.slice();return e||(e=r&&r.pop&&r.pop()),r},!0,!0),e},n.render=function(){var e={push:this.push,pop:this.pop,swap:this.swap,move:this.move,insert:this.insert,replace:this.replace,unshift:this.unshift,remove:this.remove,handlePush:this.handlePush,handlePop:this.handlePop,handleSwap:this.handleSwap,handleMove:this.handleMove,handleInsert:this.handleInsert,handleReplace:this.handleReplace,handleUnshift:this.handleUnshift,handleRemove:this.handleRemove},t=this.props,r=t.component,i=t.render,n=t.children,s=t.name,a=tV(t.formik,["validate","validationSchema"]),o=tB({},e,{form:a,name:s});return r?(0,tT.createElement)(r,o):i?i(o):n?"function"==typeof n?n(o):tX(n)?null:tT.Children.only(n):null},t})(tT.Component).defaultProps={validateOnChange:!0},tT.Component,tT.Component,e.s(["Field",0,function(e){var t=e.validate,r=e.name,i=e.render,n=e.children,s=e.as,a=e.component,o=e.className,l=tV(e,["validate","name","render","children","as","component","className"]),u=t
101V(tz(),["validate","validationSchema"]),c=u.registerField,d=u.unregisterField;(0,tT.useEffect)(function(){return c(r,{validate:t}),function(){d(r)}},[c,d,r,t]);var h=u.getFieldProps(tB({name:r},l)),f=u.getFieldMeta(r),p={field:h,form:u};if(i)return i(tB({},p,{meta:f}));if(tW(n))return n(tB({},p,{meta:f}));if(a){if("string"==typeof a){var g=l.innerRef,m=tV(l,["innerRef"]);return(0,tT.createElement)(a,tB({ref:g},h,m,{className:o}),n)}return(0,tT.createElement)(a,tB({field:h,form:u},l,{className:o}),n)}var y=s||"input";if("string"==typeof y){var v=l.innerRef,b=tV(l,["innerRef"]);return(0,tT.createElement)(y,tB({ref:v},h,b,{className:o}),n)}return(0,tT.createElement)(y,tB({},h,l,{className:o}),n)},"Formik",0,function(e){var t,r,i,n,s,a,o,l,c,d,h,f,p,g,m,y,v,b,_,E,S,x,T,w,A,R,I,C,D,L,O,P,F,N,M,j,$,U,B,V,G,q,H,z,K,W,Y,Q,X,J,Z,ee,et,er,ei,en=(r=void 0===(t=e.validateOnChange)||t,n=void 0===(i=e.validateOnBlur)||i,a=void 0!==(s=e.validateOnMount)&&s,o=e.isInitialValid,c=void 0!==(l=e.enableReinitialize)&&l,d=e.onSubmit,h=tV(e,["validateOnChange","validateOnBlur","validateOnMount","isInitialValid","enableReinitialize","onSubmit"]),f=tB({validateOnChange:r,validateOnBlur:n,validateOnMount:a,onSubmit:d},h),p=(0,tT.useRef)(f.initialValues),g=(0,tT.useRef)(f.initialErrors||t1),m=(0,tT.useRef)(f.initialTouched||t2),y=(0,tT.useRef)(f.initialStatus),v=(0,tT.useRef)(!1),b=(0,tT.useRef)({}),(0,tT.useEffect)(function(){return v.current=!0,function(){v.current=!1}},[]),_=(0,tT.useState)(0)[1],S=(E=(0,tT.useRef)({values:tx(f.initialValues),errors:tx(f.initialErrors)||t1,touched:tx(f.initialTouched)||t2,status:tx(f.initialStatus),isSubmitting:!1,isValidating:!1,submitCount:0})).current,x=(0,tT.useCallback)(function(e){var t=E.current;E.current=function(e,t){switch(t.type){case"SET_VALUES":return tB({},e,{values:t.payload});case"SET_TOUCHED":return tB({},e,{touched:t.payload});case"SET_ERRORS":if((0,tw.default)(e.errors,t.payload))return e;return tB({},e,{errors:t.payload});case"SET_STATUS":return tB({},e,{status:t.payload});case"SET_ISSUBMITTING":return tB({},e,{isSubmitting:t.payload});case"SET_ISVALIDATING":return tB({},e,{isValidating:t.payload});case"SET_FIELD_VALUE":return tB({},e,{values:t0(e.values,t.payload.field,t.payload.value)});case"SET_FIELD_TOUCHED":return tB({},e,{touched:t0(e.touched,t.payload.field,t.payload.value)});case"SET_FIELD_ERROR":return tB({},e,{errors:t0(e.errors,t.payload.field,t.payload.value)});case"RESET_FORM":return tB({},e,t.payload);case"SET_FORMIK_STATE":return t.payload(e);case"SUBMIT_ATTEMPT":return tB({},e,{touched:function e(t,r,i,n){void 0===i&&(i=new WeakMap),void 0===n&&(n={});for(var s=0,a=Object.keys(t);s<a.length;s++){var o=a[s],l=t[o];tY(l)?i.get(l)||(i.set(l,!0),n[o]=Array.isArray(l)?[]:{},e(l,r,i,n[o])):n[o]=r}return n}(e.values,!0),isSubmitting:!0,submitCount:e.submitCount+1});case"SUBMIT_FAILURE":case"SUBMIT_SUCCESS":return tB({},e,{isSubmitting:!1});default:return e}}(t,e),t!==E.current&&_(function(e){return e+1})},[]),T=(0,tT.useCallback)(function(e,t){return new Promise(function(r,i){var n=f.validate(e,t);null==n?r(t1):tJ(n)?n.then(function(e){r(e||t1)},function(e){i(e)}):r(n)})},[f.validate]),w=(0,tT.useCallback)(function(e,t){var r,i,n,s,a=f.validationSchema,o=tW(a)?a(t):a,l=t&&o.validateAt?o.validateAt(t,e):(r=e,i=o,void 0===n&&(n=!1),s=function e(t){var r=Array.isArray(t)?[]:{};for(var i in t)if(Object.prototype.hasOwnProperty.call(t,i)){var n=String(i);!0===Array.isArray(t[n])?r[n]=t[n].map(function(t){return!0===Array.isArray(t)||k(t)?e(t):""!==t?t:void 0}):k(t[n])?r[n]=e(t[n]):r[n]=""!==t[n]?t[n]:void 0}return r}(r),i[n?"validateSync":"validate"](s,{abortEarly:!1,context:s}));return new Promise(function(e,t){l.then(function(){e(t1)},function(r){"ValidationError"===r.name?e(function(e){var t={};if(e.inner){if(0===e.inner.length)return t0(t,e.path,e.message);for(var r=e.inner,i=Array.isArray(r),n=0,r=i?r:r[Symbol.iterator]();;){if(i){if(n>=r.length)break;s=r[n++]}else{if((n=r.next()).done)break;s=n.value}var s,a=s;tZ(t,a.path)||(t=t0(t,a.path,a.message))}}return t}(r)):t(r)})})},[f.validationSchema]),A=(0,tT.useCallback)(function(e,t){return new Promise(function(r){return r(b.current[e].validate(t))})},[]),R=(0,tT.useCallback)(function(e){var t=Object.keys(b.current).filter(function(e){return tW(b.current[e].validate)});return Promise.all(t.length>0?t.map(function(t){return A(t,tZ(e,t))}):[Promise.resolve("DO_NOT_DELETE_YOU_WILL_BE_FIRED")]).then(function(e){return e.reduce(function(e,r,i){return"DO_NOT_DELETE_YOU_WILL_BE_FIRED"===r||r&&(e=t0(e,t[i],r)),e},{})})},[A]),I=(0,tT.useCallback)(function(e){return Promise.all([R(e),f.validationSchema?w(e):{},f.validate?T(e):{}]).then(function(e){var t=e[0],r=e[1],i=e[2];return u.all([t,r,i],{arrayMerge:t3})})},[f.validate,f.validationSchema,R,T,w]),C=t5(function(e){return void 0===e&&(e=S.values),x({type:"SET_ISVALIDATING",payload:!0}),I(e).then(function(e){return v.current&&(x({type:"SET_ISVALIDATING",payload:!1}),x({type:"SET_ERRORS",payload:e})),e})}),(0,tT.useEffect)(function(){a&&!0===v.current&&(0,tw.default)(p.current,f.initialValues)&&C(p.current)},[a,C]),D=(0,tT.useCallback)(function(e){var t=e&&e.values?e.values:p.current,r=e&&e.errors?e.errors:g.current?g.current:f.initialErrors||{},i=e&&e.touched?e.touched:m.current?m.current:f.initialTouched||{},n=e&&e.status?e.status:y.current?y.current:f.initialStatus;p.current=t,g.current=r,m.current=i,y.current=n;var s=function(){x({type:"RESET_FORM",payload:{isSubmitting:!!e&&!!e.isSubmitting,errors:r,touched:i,status:n,values:t,isValidating:!!e&&!!e.isValidating,submitCount:e&&e.submitCount&&"number"==typeof e.submitCount?e.submitCount:0}})};if(f.onReset){var a=f.onReset(S.values,Q);tJ(a)?a.then(s):s()}else s()},[f.initialErrors,f.initialStatus,f.initialTouched,f.onReset]),(0,tT.useEffect)(function(){!0===v.current&&!(0,tw.default)(p.current,f.initialValues)&&c&&(p.current=f.initialValues,D(),a&&C(p.current))},[c,f.initialValues,D,a,C]),(0,tT.useEffect)(function(){c&&!0===v.current&&!(0,tw.default)(g.current,f.initialErrors)&&(g.current=f.initialErrors||t1,x({type:"SET_ERRORS",payload:f.initialErrors||t1}))},[c,f.initialErrors]),(0,tT.useEffect)(function(){c&&!0===v.current&&!(0,tw.default)(m.current,f.initialTouched)&&(m.current=f.initialTouched||t2,x({type:"SET_TOUCHED",payload:f.initialTouched||t2}))},[c,f.initialTouched]),(0,tT.useEffect)(function(){c&&!0===v.current&&!(0,tw.default)(y.current,f.initialStatus)&&(y.current=f.initialStatus,x({type:"SET_STATUS",payload:f.initialStatus}))},[c,f.initialStatus,f.initialTouched]),L=t5(function(e){if(b.current[e]&&tW(b.current[e].validate)){var t=tZ(S.values,e),r=b.current[e].validate(t);return tJ(r)?(x({type:"SET_ISVALIDATING",payload:!0}),r.then(function(e){return e}).then(function(t){x({type:"SET_FIELD_ERROR",payload:{field:e,value:t}}),x({type:"SET_ISVALIDATING",payload:!1})})):(x({type:"SET_FIELD_ERROR",payload:{field:e,value:r}}),Promise.resolve(r))}return f.validationSchema?(x({type:"SET_ISVALIDATING",payload:!0}),w(S.values,e).then(function(e){return e}).then(function(t){x({type:"SET_FIELD_ERROR",payload:{field:e,value:tZ(t,e)}}),x({type:"SET_ISVALIDATING",payload:!1})})):Promise.resolve()}),O=(0,tT.useCallback)(function(e,t){var r=t.validate;b.current[e]={validate:r}},[]),P=(0,tT.useCallback)(function(e){delete b.current[e]},[]),F=t5(function(e,t){return x({type:"SET_TOUCHED",payload:e}),(void 0===t?n:t)?C(S.values):Promise.resolve()}),N=(0,tT.useCallback)(function(e){x({type:"SET_ERRORS",payload:e})},[]),M=t5(function(e,t){var i=tW(e)?e(S.values):e;return x({type:"SET_VALUES",payload:i}),(void 0===t?r:t)?C(i):Promise.resolve()}),j=(0,tT.useCallback)(function(e,t){x({type:"SET_FIELD_ERROR",payload:{field:e,value:t}})},[]),$=t5(function(e,t,i){var n=tW(t)?t(tZ(S.values,e)):t;return x({type:"SET_FIELD_VALUE",payload:{field:e,value:n}}),(void 0===i?r:i)?C(t0(S.values,e,n)):Promise.resolve()}),U=(0,tT.useCallback)(function(e,t){var r,i=t,n=e;if(!tQ(e)){e.persist&&e.persist();var s=e.target?e.target:e.currentTarget,a=s.type,o=s.name,l=s.id,u=s.value,c=s.checked,d=(s.outerHTML,s.options),h=s.multiple;
101i=t||o||l,n=/number|range/.test(a)?isNaN(r=parseFloat(u))?"":r:/checkbox/.test(a)?function(e,t,r){if("boolean"==typeof e)return!!t;var i=[],n=!1,s=-1;if(Array.isArray(e))i=e,n=(s=e.indexOf(r))>=0;else if(!r||"true"==r||"false"==r)return!!t;return t&&r&&!n?i.concat(r):n?i.slice(0,s).concat(i.slice(s+1)):i}(tZ(S.values,i),c,u):d&&h?Array.from(d).filter(function(e){return e.selected}).map(function(e){return e.value}):u}i&&$(i,n)},[$,S.values]),B=t5(function(e){if(tQ(e))return function(t){return U(t,e)};U(e)}),V=t5(function(e,t,r){return void 0===t&&(t=!0),x({type:"SET_FIELD_TOUCHED",payload:{field:e,value:t}}),(void 0===r?n:r)?C(S.values):Promise.resolve()}),G=(0,tT.useCallback)(function(e,t){e.persist&&e.persist();var r=e.target,i=r.name,n=r.id;r.outerHTML,V(t||i||n,!0)},[V]),q=t5(function(e){if(tQ(e))return function(t){return G(t,e)};G(e)}),H=(0,tT.useCallback)(function(e){tW(e)?x({type:"SET_FORMIK_STATE",payload:e}):x({type:"SET_FORMIK_STATE",payload:function(){return e}})},[]),z=(0,tT.useCallback)(function(e){x({type:"SET_STATUS",payload:e})},[]),K=(0,tT.useCallback)(function(e){x({type:"SET_ISSUBMITTING",payload:e})},[]),W=t5(function(){return x({type:"SUBMIT_ATTEMPT"}),C().then(function(e){var t,r=e instanceof Error;if(!r&&0===Object.keys(e).length){try{if(t=X(),void 0===t)return}catch(e){throw e}return Promise.resolve(t).then(function(e){return v.current&&x({type:"SUBMIT_SUCCESS"}),e}).catch(function(e){if(v.current)throw x({type:"SUBMIT_FAILURE"}),e})}if(v.current&&(x({type:"SUBMIT_FAILURE"}),r))throw e})}),Y=t5(function(e){e&&e.preventDefault&&tW(e.preventDefault)&&e.preventDefault(),e&&e.stopPropagation&&tW(e.stopPropagation)&&e.stopPropagation(),W().catch(function(e){console.warn("Warning: An unhandled error was caught from submitForm()",e)})}),Q={resetForm:D,validateForm:C,validateField:L,setErrors:N,setFieldError:j,setFieldTouched:V,setFieldValue:$,setStatus:z,setSubmitting:K,setTouched:F,setValues:M,setFormikState:H,submitForm:W},X=t5(function(){return d(S.values,Q)}),J=t5(function(e){e&&e.preventDefault&&tW(e.preventDefault)&&e.preventDefault(),e&&e.stopPropagation&&tW(e.stopPropagation)&&e.stopPropagation(),D()}),Z=(0,tT.useCallback)(function(e){return{value:tZ(S.values,e),error:tZ(S.errors,e),touched:!!tZ(S.touched,e),initialValue:tZ(p.current,e),initialTouched:!!tZ(m.current,e),initialError:tZ(g.current,e)}},[S.errors,S.touched,S.values]),ee=(0,tT.useCallback)(function(e){return{setValue:function(t,r){return $(e,t,r)},setTouched:function(t,r){return V(e,t,r)},setError:function(t){return j(e,t)}}},[$,V,j]),et=(0,tT.useCallback)(function(e){var t=tY(e),r=t?e.name:e,i=tZ(S.values,r),n={name:r,value:i,onChange:B,onBlur:q};if(t){var s=e.type,a=e.value,o=e.as,l=e.multiple;"checkbox"===s?void 0===a?n.checked=!!i:(n.checked=!!(Array.isArray(i)&&~i.indexOf(a)),n.value=a):"radio"===s?(n.checked=i===a,n.value=a):"select"===o&&l&&(n.value=n.value||[],n.multiple=!0)}return n},[q,B,S.values]),er=(0,tT.useMemo)(function(){return!(0,tw.default)(p.current,S.values)},[p.current,S.values]),ei=(0,tT.useMemo)(function(){return void 0!==o?er?S.errors&&0===Object.keys(S.errors).length:!1!==o&&tW(o)?o(f):o:S.errors&&0===Object.keys(S.errors).length},[o,er,S.errors,f]),tB({},S,{initialValues:p.current,initialErrors:g.current,initialTouched:m.current,initialStatus:y.current,handleBlur:q,handleChange:B,handleReset:J,handleSubmit:Y,resetForm:D,setErrors:N,setFormikState:H,setFieldTouched:V,setFieldValue:$,setFieldError:j,setStatus:z,setSubmitting:K,setTouched:F,setValues:M,submitForm:W,validateForm:C,validateField:L,isValid:ei,dirty:er,unregisterField:P,registerField:O,getFieldProps:et,getFieldMeta:Z,getFieldHelpers:ee,validateOnBlur:n,validateOnChange:r,validateOnMount:a})),es=e.component,ea=e.children,eo=e.render,el=e.innerRef;return(0,tT.useImperativeHandle)(el,function(){return en}),(0,tT.createElement)(tH,{value:en},es?(0,tT.createElement)(es,en):eo?eo(en):ea?tW(ea)?ea(en):tX(ea)?null:tT.Children.only(ea):null)}],812497)},336760,(e,t,r)=>{var i=Object.prototype.hasOwnProperty;t.exports=function(e,t){return null!=e&&i.call(e,t)}},45350,(e,t,r)=>{t.exports=Array.isArray},100236,(e,t,r)=>{t.exports=e.g&&e.g.Object===Object&&e.g},139088,(e,t,r)=>{var i=e.r(100236),n="object"==typeof self&&self&&self.Object===Object&&self;
101t.exports=i||n||Function("return this")()},630353,(e,t,r)=>{t.exports=e.r(139088).Symbol},243436,(e,t,r)=>{var i=e.r(630353),n=Object.prototype,s=n.hasOwnProperty,a=n.toString,o=i?i.toStringTag:void 0;t.exports=function(e){var t=s.call(e,o),r=e[o];try{e[o]=void 0;var i=!0}catch(e){}var n=a.call(e);return i&&(t?e[o]=r:delete e[o]),n}},223243,(e,t,r)=>{var i=Object.prototype.toString;t.exports=function(e){return i.call(e)}},377684,(e,t,r)=>{var i=e.r(630353),n=e.r(243436),s=e.r(223243),a=i?i.toStringTag:void 0;t.exports=function(e){return null==e?void 0===e?"[object Undefined]":"[object Null]":a&&a in Object(e)?n(e):s(e)}},877289,(e,t,r)=>{t.exports=function(e){return null!=e&&"object"==typeof e}},361884,(e,t,r)=>{var i=e.r(377684),n=e.r(877289);t.exports=function(e){return"symbol"==typeof e||n(e)&&"[object Symbol]"==i(e)}},9903,(e,t,r)=>{var i=e.r(45350),n=e.r(361884),s=/\.|\[(?:[^[\]]*|(["'])(?:(?!\1)[^\\]|\\.)*?\1)\]/,a=/^\w*$/;t.exports=function(e,t){if(i(e))return!1;var r=typeof e;return!!("number"==r||"symbol"==r||"boolean"==r||null==e||n(e))||a.test(e)||!s.test(e)||null!=t&&e in Object(t)}},12447,(e,t,r)=>{t.exports=function(e){var t=typeof e;return null!=e&&("object"==t||"function"==t)}},771223,(e,t,r)=>{var i=e.r(377684),n=e.r(12447);t.exports=function(e){if(!n(e))return!1;var t=i(e);return"[object Function]"==t||"[object GeneratorFunction]"==t||"[object AsyncFunction]"==t||"[object Proxy]"==t}},853789,(e,t,r)=>{t.exports=e.r(139088)["__core-js_shared__"]},269553,(e,t,r)=>{var i,n=e.r(853789),s=(i=/[^.]+$/.exec(n&&n.keys&&n.keys.IE_PROTO||""))?"Symbol(src)_1."+i:"";t.exports=function(e){return!!s&&s in e}},776366,(e,t,r)=>{var i=Function.prototype.toString;t.exports=function(e){if(null!=e){try{return i.call(e)}catch(e){}try{return e+""}catch(e){}}return""}},54368,(e,t,r)=>{var i=e.r(771223),n=e.r(269553),s=e.r(12447),a=e.r(776366),o=/^\[object .+?Constructor\]$/,l=Object.prototype,u=Function.prototype.toString,c=l.hasOwnProperty,d=RegExp("^"+u.call(c).replace(/[\\^$.*+?()[\]{}|]/g,"\\$&").replace(/hasOwnProperty|(function).*?(?=\\\()| for .+?(?=\\\])/g,"$1.*?")+"$");t.exports=function(e){return!(!s(e)||n(e))&&(i(e)?d:o).test(a(e))}},263958,(e,t,r)=>{t.exports=function(e,t){return null==e?void 0:e[t]}},841920,(e,t,r)=>{var i=e.r(54368),n=e.r(263958);t.exports=function(e,t){var r=n(e,t);return i(r)?r:void 0}},932760,(e,t,r)=>{t.exports=e.r(841920)(Object,"create")},150514,(e,t,r)=>{var i=e.r(932760);t.exports=function(){this.__data__=i?i(null):{},this.size=0}},197617,(e,t,r)=>{t.exports=function(e){var t=this.has(e)&&delete this.__data__[e];return this.size-=!!t,t}},757412,(e,t,r)=>{var i=e.r(932760),n=Object.prototype.hasOwnProperty;t.exports=function(e){var t=this.__data__;if(i){var r=t[e];return"__lodash_hash_undefined__"===r?void 0:r}return n.call(t,e)?t[e]:void 0}},623592,(e,t,r)=>{var i=e.r(932760),n=Object.prototype.hasOwnProperty;t.exports=function(e){var t=this.__data__;return i?void 0!==t[e]:n.call(t,e)}},239004,(e,t,r)=>{var i=e.r(932760);t.exports=function(e,t){var r=this.__data__;return this.size+=+!this.has(e),r[e]=i&&void 0===t?"__lodash_hash_undefined__":t,this}},734421,(e,t,r)=>{var i=e.r(150514),n=e.r(197617),s=e.r(757412),a=e.r(623592),o=e.r(239004);function l(e){var t=-1,r=null==e?0:e.length;for(this.clear();++t<r;){var i=e[t];this.set(i[0],i[1])}}l.prototype.clear=i,l.prototype.delete=n,l.prototype.get=s,l.prototype.has=a,l.prototype.set=o,t.exports=l},665742,(e,t,r)=>{t.exports=function(){this.__data__=[],this.size=0}},25172,(e,t,r)=>{t.exports=function(e,t){return e===t||e!=e&&t!=t}},134314,(e,t,r)=>{var i=e.r(25172);t.exports=function(e,t){for(var r=e.length;r--;)if(i(e[r][0],t))return r;return -1}},419206,(e,t,r)=>{var i=e.r(134314),n=Array.prototype.splice;t.exports=function(e){var t=this.__data__,r=i(t,e);return!(r<0)&&(r==t.length-1?t.pop():n.call(t,r,1),--this.size,!0)}},467763,(e,t,r)=>{var i=e.r(134314);t.exports=function(e){var t=this.__data__,r=i(t,e);return r<0?void 0:t[r][1]}},523407,(e,t,r)=>{var i=e.r(134314);t.exports=function(e){return i(this.__data__,e)>-1}},553833,(e,t,r)=>{var i=e.r(134314);t.exports=function(e,t){var r=this.__data__,n=i(r,e);return n<0?(++this.size,r.push([e,t])):r[n][1]=t,this}},729039,(e,t,r)=>{var i=e.r(665742),n=e.r(419206),s=e.r(467763),a=e.r(523407),o=e.r(553833);function l(e){var t=-1,r=null==e?0:e.length;for(this.clear();++t<r;){var i=e[t];this.set(i[0],i[1])}}l.prototype.clear=i,l.prototype.delete=n,l.prototype.get=s,l.prototype.has=a,l.prototype.set=o,t.exports=l},687362,(e,t,r)=>{t.exports=e.r(841920)(e.r(139088),"Map")}
101,848994,(e,t,r)=>{var i=e.r(734421),n=e.r(729039),s=e.r(687362);t.exports=function(){this.size=0,this.__data__={hash:new i,map:new(s||n),string:new i}}},224053,(e,t,r)=>{t.exports=function(e){var t=typeof e;return"string"==t||"number"==t||"symbol"==t||"boolean"==t?"__proto__"!==e:null===e}},487994,(e,t,r)=>{var i=e.r(224053);t.exports=function(e,t){var r=e.__data__;return i(t)?r["string"==typeof t?"string":"hash"]:r.map}},996768,(e,t,r)=>{var i=e.r(487994);t.exports=function(e){var t=i(this,e).delete(e);return this.size-=!!t,t}},929932,(e,t,r)=>{var i=e.r(487994);t.exports=function(e){return i(this,e).get(e)}},892647,(e,t,r)=>{var i=e.r(487994);t.exports=function(e){return i(this,e).has(e)}},446644,(e,t,r)=>{var i=e.r(487994);t.exports=function(e,t){var r=i(this,e),n=r.size;return r.set(e,t),this.size+=+(r.size!=n),this}},587547,(e,t,r)=>{var i=e.r(848994),n=e.r(996768),s=e.r(929932),a=e.r(892647),o=e.r(446644);function l(e){var t=-1,r=null==e?0:e.length;for(this.clear();++t<r;){var i=e[t];this.set(i[0],i[1])}}l.prototype.clear=i,l.prototype.delete=n,l.prototype.get=s,l.prototype.has=a,l.prototype.set=o,t.exports=l},657588,(e,t,r)=>{var i=e.r(587547);function n(e,t){if("function"!=typeof e||null!=t&&"function"!=typeof t)throw TypeError("Expected a function");var r=function(){var i=arguments,n=t?t.apply(this,i):i[0],s=r.cache;if(s.has(n))return s.get(n);var a=e.apply(this,i);return r.cache=s.set(n,a)||s,a};return r.cache=new(n.Cache||i),r}n.Cache=i,t.exports=n},688832,(e,t,r)=>{var i=e.r(657588);t.exports=function(e){var t=i(e,function(e){return 500===r.size&&r.clear(),e}),r=t.cache;return t}},902677,(e,t,r)=>{var i=e.r(688832),n=/[^.[\]]+|\[(?:(-?\d+(?:\.\d+)?)|(["'])((?:(?!\2)[^\\]|\\.)*?)\2)\]|(?=(?:\.|\[\])(?:\.|\[\]|$))/g,s=/\\(\\)?/g;t.exports=i(function(e){var t=[];return 46===e.charCodeAt(0)&&t.push(""),e.replace(n,function(e,r,i,n){t.push(i?n.replace(s,"$1"):r||e)}),t})},892708,(e,t,r)=>{t.exports=function(e,t){for(var r=-1,i=null==e?0:e.length,n=Array(i);++r<i;)n[r]=t(e[r],r,e);return n}},372537,(e,t,r)=>{var i=e.r(630353),n=e.r(892708),s=e.r(45350),a=e.r(361884),o=1/0,l=i?i.prototype:void 0,u=l?l.toString:void 0;t.exports=function e(t){if("string"==typeof t)return t;if(s(t))return n(t,e)+"";if(a(t))return u?u.call(t):"";var r=t+"";return"0"==r&&1/t==-o?"-0":r}},702922,(e,t,r)=>{var i=e.r(372537);t.exports=function(e){return null==e?"":i(e)}},186287,(e,t,r)=>{var i=e.r(45350),n=e.r(9903),s=e.r(902677),a=e.r(702922);t.exports=function(e,t){return i(e)?e:n(e,t)?[e]:s(a(e))}},566645,(e,t,r)=>{var i=e.r(377684),n=e.r(877289);t.exports=function(e){return n(e)&&"[object Arguments]"==i(e)}},473250,(e,t,r)=>{var i=e.r(566645),n=e.r(877289),s=Object.prototype,a=s.hasOwnProperty,o=s.propertyIsEnumerable;t.exports=i(function(){return arguments}())?i:function(e){return n(e)&&a.call(e,"callee")&&!o.call(e,"callee")}},66397,(e,t,r)=>{var i=/^(?:0|[1-9]\d*)$/;t.exports=function(e,t){var r=typeof e;return!!(t=null==t?0x1fffffffffffff:t)&&("number"==r||"symbol"!=r&&i.test(e))&&e>-1&&e%1==0&&e<t}},98376,(e,t,r)=>{t.exports=function(e){return"number"==typeof e&&e>-1&&e%1==0&&e<=0x1fffffffffffff}},2054,(e,t,r)=>{var i=e.r(361884),n=1/0;t.exports=function(e){if("string"==typeof e||i(e))return e;var t=e+"";return"0"==t&&1/e==-n?"-0":t}},215359,(e,t,r)=>{var i=e.r(186287),n=e.r(473250),s=e.r(45350),a=e.r(66397),o=e.r(98376),l=e.r(2054);t.exports=function(e,t,r){t=i(t,e);for(var u=-1,c=t.length,d=!1;++u<c;){var h=l(t[u]);if(!(d=null!=e&&r(e,h)))break;e=e[h]}return d||++u!=c?d:!!(c=null==e?0:e.length)&&o(c)&&a(h,c)&&(s(e)||n(e))}},344708,(e,t,r)=>{var i=e.r(336760),n=e.r(215359);t.exports=function(e,t){return null!=e&&n(e,t,i)}},524251,(e,t,r)=>{var i=e.r(841920);t.exports=function(){try{var e=i(Object,"defineProperty");return e({},"",{}),e}catch(e){}}()},674548,(e,t,r)=>{var i=e.r(524251);t.exports=function(e,t,r){"__proto__"==t&&i?i(e,t,{configurable:!0,enumerable:!0,value:r,writable:!0}):e[t]=r}},536755,(e,t,r)=>{t.exports=function(e){return function(t,r,i){for(var n=-1,s=Object(t),a=i(t),o=a.length;o--;){var l=a[e?o:++n];
101if(!1===r(s[l],l,s))break}return t}}},98728,(e,t,r)=>{t.exports=e.r(536755)()},855803,(e,t,r)=>{t.exports=function(e,t){for(var r=-1,i=Array(e);++r<e;)i[r]=t(r);return i}},24013,(e,t,r)=>{t.exports=function(){return!1}},356956,(e,t,r)=>{var i=e.r(139088),n=e.r(24013),s=r&&!r.nodeType&&r,a=s&&t&&!t.nodeType&&t,o=a&&a.exports===s?i.Buffer:void 0;t.exports=(o?o.isBuffer:void 0)||n},476602,(e,t,r)=>{var i=e.r(377684),n=e.r(98376),s=e.r(877289),a={};a["[object Float32Array]"]=a["[object Float64Array]"]=a["[object Int8Array]"]=a["[object Int16Array]"]=a["[object Int32Array]"]=a["[object Uint8Array]"]=a["[object Uint8ClampedArray]"]=a["[object Uint16Array]"]=a["[object Uint32Array]"]=!0,a["[object Arguments]"]=a["[object Array]"]=a["[object ArrayBuffer]"]=a["[object Boolean]"]=a["[object DataView]"]=a["[object Date]"]=a["[object Error]"]=a["[object Function]"]=a["[object Map]"]=a["[object Number]"]=a["[object Object]"]=a["[object RegExp]"]=a["[object Set]"]=a["[object String]"]=a["[object WeakMap]"]=!1,t.exports=function(e){return s(e)&&n(e.length)&&!!a[i(e)]}},233999,(e,t,r)=>{t.exports=function(e){return function(t){return e(t)}}},180156,(e,t,r)=>{var i=e.r(100236),n=r&&!r.nodeType&&r,s=n&&t&&!t.nodeType&&t,a=s&&s.exports===n&&i.process;t.exports=function(){try{var e=s&&s.require&&s.require("util").types;if(e)return e;return a&&a.binding&&a.binding("util")}catch(e){}}()},3023,(e,t,r)=>{var i=e.r(476602),n=e.r(233999),s=e.r(180156),a=s&&s.isTypedArray;t.exports=a?n(a):i},458877,(e,t,r)=>{var i=e.r(855803),n=e.r(473250),s=e.r(45350),a=e.r(356956),o=e.r(66397),l=e.r(3023),u=Object.prototype.hasOwnProperty;t.exports=function(e,t){var r=s(e),c=!r&&n(e),d=!r&&!c&&a(e),h=!r&&!c&&!d&&l(e),f=r||c||d||h,p=f?i(e.length,String):[],g=p.length;for(var m in e)(t||u.call(e,m))&&!(f&&("length"==m||d&&("offset"==m||"parent"==m)||h&&("buffer"==m||"byteLength"==m||"byteOffset"==m)||o(m,g)))&&p.push(m);return p}},763996,(e,t,r)=>{var i=Object.prototype;t.exports=function(e){var t=e&&e.constructor;return e===("function"==typeof t&&t.prototype||i)}},825717,(e,t,r)=>{t.exports=function(e,t){return function(r){return e(t(r))}}},942369,(e,t,r)=>{t.exports=e.r(825717)(Object.keys,Object)},848477,(e,t,r)=>{var i=e.r(763996),n=e.r(942369),s=Object.prototype.hasOwnProperty;t.exports=function(e){if(!i(e))return n(e);var t=[];for(var r in Object(e))s.call(e,r)&&"constructor"!=r&&t.push(r);return t}},351095,(e,t,r)=>{var i=e.r(771223),n=e.r(98376);t.exports=function(e){return null!=e&&n(e.length)&&!i(e)}},33679,(e,t,r)=>{var i=e.r(458877),n=e.r(848477),s=e.r(351095);t.exports=function(e){return s(e)?i(e):n(e)}},163799,(e,t,r)=>{var i=e.r(98728),n=e.r(33679);t.exports=function(e,t){return e&&i(e,t,n)}},405400,(e,t,r)=>{var i=e.r(729039);t.exports=function(){this.__data__=new i,this.size=0}},986238,(e,t,r)=>{t.exports=function(e){var t=this.__data__,r=t.delete(e);return this.size=t.size,r}},957831,(e,t,r)=>{t.exports=function(e){return this.__data__.get(e)}},977802,(e,t,r)=>{t.exports=function(e){return this.__data__.has(e)}},320517,(e,t,r)=>{var i=e.r(729039),n=e.r(687362),s=e.r(587547);t.exports=function(e,t){var r=this.__data__;if(r instanceof i){var a=r.__data__;if(!n||a.length<199)return a.push([e,t]),this.size=++r.size,this;r=this.__data__=new s(a)}return r.set(e,t),this.size=r.size,this}},901551,(e,t,r)=>{var i=e.r(729039),n=e.r(405400),s=e.r(986238),a=e.r(957831),o=e.r(977802),l=e.r(320517);function u(e){var t=this.__data__=new i(e);this.size=t.size}u.prototype.clear=n,u.prototype.delete=s,u.prototype.get=a,u.prototype.has=o,u.prototype.set=l,t.exports=u},221274,(e,t,r)=>{t.exports=function(e){return this.__data__.set(e,"__lodash_hash_undefined__"),this}},439805,(e,t,r)=>{t.exports=function(e){return this.__data__.has(e)}},27493,(e,t,r)=>{var i=e.r(587547),n=e.r(221274),s=e.r(439805);function a(e){var t=-1,r=null==e?0:e.length;for(this.__data__=new i;++t<r;)this.add(e[t])}a.prototype.add=a.prototype.push=n,a.prototype.has=s,t.exports=a},851477,(e,t,r)=>{t.exports=function(e,t){for(var r=-1,i=null==e?0:e.length;++r<i;)if(t(e[r],r,e))return!0;return!1}},315262,(e,t,r)=>{t.exports=function(e,t){return e.has(t)}},206856,(e,t,r)=>{var i=e.r(27493),n=e.r(851477),s=e.r(315262);t.exports=function(e,t,r,a,o,l){var u=1&r,c=e.length,d=t.length;if(c!=d&&!(u&&d>c))return!1;var h=l.get(e),f=l.get(t);if(h&&f)return h==t&&f==e;var p=-1,g=!0,m=2&r?new i:void 0;for(l.set(e,t),l.set(t,e);++p<c;){var y=e[p],v=t[p];if(a)var b=u?a(v,y,p,t,e,l):a(y,v,p,e,t,l);if(void 0!==b){if(b)continue;g=!1;break}if(m){if(!n(t,function(e,t){if(!s(m,t)&&(y===e||o(y,e,r,a,l)))return m.push(t)})){g=!1;break}}else if(!(y===v||o(y,v,r,a,l))){g=!1;break}}return l.delete(e),l.delete(t),g}},263750,(e,t,r)=>{t.exports=e.r(139088).Uint8Array},75331,(e,t,r)=>{t.exports=function(e){var t=-1,r=Array(e.size);return e.forEach(function(e,i){r[++t]=[i,e]}),r}},899850,(e,t,r)=>{t.exports=function(e){var t=-1,r=Array(e.size);return e.forEach(function(e){r[++t]=e}),r}},678012,(e,t,r)=>{var i=e.r(630353),n=e.r(263750),s=e.r(25172),a=e.r(206856),o=e.r(75331),l=e.r(899850),u=i?i.prototype:void 0,c=u?u.valueOf:void 0;t.exports=function(e,t,r,i,u,d,h){switch(r){case"[object DataView]":if(e.byteLength!=t.byteLength||e.byteOffset!=t.byteOffset)break;e=e.buffer,t=t.buffer;case"[object ArrayBuffer]":if(e.byteLength!=t.byteLength||!d(new n(e),new n(t)))break;return!0;case"[object Boolean]":case"[object Date]":case"[object Number]":return s(+e,+t);case"[object Error]":return e.name==t.name&&e.message==t.message;case"[object RegExp]":case"[object String]":return e==t+"";case"[object Map]":var f=o;case"[object Set]":var p=1&i;if(f||(f=l),e.size!=t.size&&!p)break;var g=h.get(e);if(g)return g==t;i|=2,h.set(e,t);var m=a(f(e),f(t),i,u,d,h);return h.delete(e),m;case"[object Symbol]":if(c)return c.call(e)==c.call(t)}return!1}},169102,(e,t,r)=>{t.exports=function(e,t){for(var r=-1,i=t.length,n=e.length;++r<i;)e[n+r]=t[r];return e}},823403,(e,t,r)=>{var i=e.r(169102),n=e.r(45350);t.exports=function(e,t,r){var s=t(e);return n(e)?s:i(s,r(e))}},536100,(e,t,r)=>{t.exports=function(e,t){for(var r=-1,i=null==e?0:e.length,n=0,s=[];++r<i;){var a=e[r];t(a,r,e)&&(s[n++]=a)}return s}},45159,(e,t,r)=>{t.exports=function(){return[]}},717332,(e,t,r)=>{var i=e.r(536100),n=e.r(45159),s=Object.prototype.propertyIsEnumerable,a=Object.getOwnPropertySymbols;t.exports=a?function(e){return null==e?[]:i(a(e=Object(e)),function(t){return s.call(e,t)})}:n},413370,(e,t,r)=>{var i=e.r(823403),n=e.r(717332),s=e.r(33679);t.exports=function(e){return i(e,s,n)}},330698,(e,t,r)=>{var i=e.r(413370),n=Object.prototype.hasOwnProperty;t.exports=function(e,t,r,s,a,o){var l=1&r,u=i(e),c=u.length;if(c!=i(t).length&&!l)return!1;for(var d=c;d--;){var h=u[d];if(!(l?h in t:n.call(t,h)))return!1}var f=o.get(e),p=o.get(t);if(f&&p)return f==t&&p==e;var g=!0;o.set(e,t),o.set(t,e);for(var m=l;++d<c;){var y=e[h=u[d]],v=t[h];if(s)var b=l?s(v,y,h,t,e,o):s(y,v,h,e,t,o);if(!(void 0===b?y===v||a(y,v,r,s,o):b)){g=!1;break}
101m||(m="constructor"==h)}if(g&&!m){var _=e.constructor,E=t.constructor;_!=E&&"constructor"in e&&"constructor"in t&&!("function"==typeof _&&_ instanceof _&&"function"==typeof E&&E instanceof E)&&(g=!1)}return o.delete(e),o.delete(t),g}},801419,(e,t,r)=>{t.exports=e.r(841920)(e.r(139088),"DataView")},717074,(e,t,r)=>{t.exports=e.r(841920)(e.r(139088),"Promise")},106966,(e,t,r)=>{t.exports=e.r(841920)(e.r(139088),"Set")},573895,(e,t,r)=>{t.exports=e.r(841920)(e.r(139088),"WeakMap")},367426,(e,t,r)=>{var i=e.r(801419),n=e.r(687362),s=e.r(717074),a=e.r(106966),o=e.r(573895),l=e.r(377684),u=e.r(776366),c="[object Map]",d="[object Promise]",h="[object Set]",f="[object WeakMap]",p="[object DataView]",g=u(i),m=u(n),y=u(s),v=u(a),b=u(o),_=l;(i&&_(new i(new ArrayBuffer(1)))!=p||n&&_(new n)!=c||s&&_(s.resolve())!=d||a&&_(new a)!=h||o&&_(new o)!=f)&&(_=function(e){var t=l(e),r="[object Object]"==t?e.constructor:void 0,i=r?u(r):"";if(i)switch(i){case g:return p;case m:return c;case y:return d;case v:return h;case b:return f}return t}),t.exports=_},178353,(e,t,r)=>{var i=e.r(901551),n=e.r(206856),s=e.r(678012),a=e.r(330698),o=e.r(367426),l=e.r(45350),u=e.r(356956),c=e.r(3023),d="[object Arguments]",h="[object Array]",f="[object Object]",p=Object.prototype.hasOwnProperty;t.exports=function(e,t,r,g,m,y){var v=l(e),b=l(t),_=v?h:o(e),E=b?h:o(t);_=_==d?f:_,E=E==d?f:E;var S=_==f,x=E==f,T=_==E;if(T&&u(e)){if(!u(t))return!1;v=!0,S=!1}if(T&&!S)return y||(y=new i),v||c(e)?n(e,t,r,g,m,y):s(e,t,_,r,g,m,y);if(!(1&r)){var w=S&&p.call(e,"__wrapped__"),A=x&&p.call(t,"__wrapped__");
101if(w||A){var R=w?e.value():e,I=A?t.value():t;return y||(y=new i),m(R,I,r,g,y)}}return!!T&&(y||(y=new i),a(e,t,r,g,m,y))}},421885,(e,t,r)=>{var i=e.r(178353),n=e.r(877289);t.exports=function e(t,r,s,a,o){return t===r||(null!=t&&null!=r&&(n(t)||n(r))?i(t,r,s,a,e,o):t!=t&&r!=r)}},748299,(e,t,r)=>{var i=e.r(901551),n=e.r(421885);t.exports=function(e,t,r,s){var a=r.length,o=a,l=!s;if(null==e)return!o;for(e=Object(e);a--;){var u=r[a];if(l&&u[2]?u[1]!==e[u[0]]:!(u[0]in e))return!1}for(;++a<o;){var c=(u=r[a])[0],d=e[c],h=u[1];if(l&&u[2]){if(void 0===d&&!(c in e))return!1}else{var f=new i;if(s)var p=s(d,h,c,e,t,f);if(!(void 0===p?n(h,d,3,s,f):p))return!1}}return!0}},715782,(e,t,r)=>{var i=e.r(12447);t.exports=function(e){return e==e&&!i(e)}},741903,(e,t,r)=>{var i=e.r(715782),n=e.r(33679);t.exports=function(e){for(var t=n(e),r=t.length;r--;){var s=t[r],a=e[s];t[r]=[s,a,i(a)]}return t}},165570,(e,t,r)=>{t.exports=function(e,t){return function(r){return null!=r&&r[e]===t&&(void 0!==t||e in Object(r))}}},623426,(e,t,r)=>{var i=e.r(748299),n=e.r(741903),s=e.r(165570);t.exports=function(e){var t=n(e);return 1==t.length&&t[0][2]?s(t[0][0],t[0][1]):function(r){return r===e||i(r,e,t)}}},333141,(e,t,r)=>{var i=e.r(186287),n=e.r(2054);t.exports=function(e,t){t=i(t,e);for(var r=0,s=t.length;null!=e&&r<s;)e=e[n(t[r++])];return r&&r==s?e:void 0}},482820,(e,t,r)=>{var i=e.r(333141);t.exports=function(e,t,r){var n=null==e?void 0:i(e,t);return void 0===n?r:n}},240688,(e,t,r)=>{t.exports=function(e,t){return null!=e&&t in Object(e)}},76590,(e,t,r)=>{var i=e.r(240688),n=e.r(215359);t.exports=function(e,t){return null!=e&&n(e,t,i)}},772298,(e,t,r)=>{var i=e.r(421885),n=e.r(482820),s=e.r(76590),a=e.r(9903),o=e.r(715782),l=e.r(165570),u=e.r(2054);t.exports=function(e,t){return a(e)&&o(t)?l(u(e),t):function(r){var a=n(r,e);return void 0===a&&a===t?s(r,e):i(t,a,3)}}},653336,(e,t,r)=>{t.exports=function(e){return e}},601079,(e,t,r)=>{t.exports=function(e){return function(t){return null==t?void 0:t[e]}}},430970,(e,t,r)=>{var i=e.r(333141);t.exports=function(e){return function(t){return i(t,e)}}},433906,(e,t,r)=>{var i=e.r(601079),n=e.r(430970),s=e.r(9903),a=e.r(2054);t.exports=function(e){return s(e)?i(a(e)):n(e)}},666305,(e,t,r)=>{var i=e.r(623426),n=e.r(772298),s=e.r(653336),a=e.r(45350),o=e.r(433906);t.exports=function(e){return"function"==typeof e?e:null==e?s:"object"==typeof e?a(e)?n(e[0],e[1]):i(e):o(e)}},460793,(e,t,r)=>{var i=e.r(674548),n=e.r(163799),s=e.r(666305);t.exports=function(e,t){var r={};return t=s(t,3),n(e,function(e,n,s){i(r,n,t(e,n,s))}),r}},437472,(e,t,r)=>{"use strict";function i(e){this._maxSize=e,this.clear()}i.prototype.clear=function(){this._size=0,this._values=Object.create(null)},i.prototype.get=function(e){return this._values[e]},i.prototype.set=function(e,t){return this._size>=this._maxSize&&this.clear(),!(e in this._values)&&this._size++,this._values[e]=t};var n=/[^.^\]^[]+|(?=\[\]|\.\.)/g,s=/^\d+$/,a=/^\d/,o=/[~`!#$%\^&*+=\-\[\]\\';,/{}|\\":<>\?]/g,l=/^\s*(['"]?)(.*?)(\1)\s*$/,u=new i(512),c=new i(512),d=new i(512);function h(e){return u.get(e)||u.set(e,f(e).map(function(e){return e.replace(l,"$2")}))}function f(e){return e.match(n)||[""]}function p(e){return"string"==typeof e&&e&&-1!==["'",'"'].indexOf(e.charAt(0))}t.exports={Cache:i,split:f,normalizePath:h,setter:function(e){var t=h(e);return c.get(e)||c.set(e,function(e,r){for(var i=0,n=t.length,s=e;i<n-1;){var a=t[i];if("__proto__"===a||"constructor"===a||"prototype"===a)return e;s=s[t[i++]]}s[t[i]]=r})},getter:function(e,t){var r=h(e);return d.get(e)||d.set(e,function(e){for(var i=0,n=r.length;i<n;)if(null==e&&t)return;else e=e[r[i++]];return e})},join:function(e){return e.reduce(function(e,t){return e+(p(t)||s.test(t)?"["+t+"]":(e?".":"")+t)},"")},forEach:function(e,t,r){!function(e,t,r){var i,n,l,u,c=e.length;for(n=0;n<c;n++)(i=e[n])&&(function(e){return!p(e)&&(e.match(a)&&!e.match(s)||o.test(e))}(i)&&(i='"'+i+'"'),l=!(u=p(i))&&/^\d+$/.test(i),t.call(r,i,u,l,n,e))}(Array.isArray(e)?e:f(e),t,r)}}},992427,(e,t,r)=>{t.exports=function(e,t,r,i){var n=-1,s=null==e?0:e.length;for(i&&s&&(r=e[++n]);++n<s;)r=t(r,e[n],n,e);return r}},231081,(e,t,r)=>{t.exports=function(e){return function(t){return null==e?void 0:e[t]}}},968252,(e,t,r)=>{t.exports=e.r(231081)({Ã:"A",Ã:"A",Ã:"A",Ã:"A",Ã:"A",Ã
:"A",à :"a",á:"a",â:"a",ã:"a",ä:"a",Ã¥:"a",Ã:"C",ç:"c",Ã:"D",ð:"d",Ã:"E",Ã:"E",Ã:"E",Ã:"E",è:"e",é:"e",ê:"e",ë:"e",Ã:"I",Ã:"I",Ã:"I",Ã:"I",ì:"i",Ã:"i",î:"i",ï:"i",Ã:"N",ñ:"n",Ã:"O",Ã:"O",Ã:"O",Ã:"O",Ã:"O",Ã:"O",ò:"o",ó:"o",ô:"o",õ:"o",ö:"o",ø:"o",Ã:"U",Ã:"U",Ã:"U",Ã:"U",ù:"u",ú:"u",û:"u",ü:"u",Ã:"Y",ý:"y",ÿ:"y",Ã:"Ae",æ:"ae",Ã:"Th",þ:"th",Ã:"ss",Ä:"A",Ä:"A",Ä:"A",Ä:"a",Ä:"a",Ä
:"a",Ä:"C",Ä:"C",Ä:"C",Ä:"C",Ä:"c",Ä:"c",Ä:"c",Ä:"c",Ä:"D",Ä:"D",Ä:"d",Ä:"d",Ä:"E",Ä:"E",Ä:"E",Ä:"E",Ä:"E",Ä:"e",Ä:"e",Ä:"e",Ä:"e",Ä:"e",Ä:"G",Ä:"G",Ä :"G",Ä¢:"G",Ä:"g",Ä:"g",Ä¡:"g",Ä£:"g",Ĥ:"H",Ħ:"H",Ä¥:"h",ħ:"h",Ĩ:"I",Ī:"I",Ĭ:"I",Ä®:"I",İ:"I",Ä©:"i",Ä«:"i",Ä:"i",į:"i",ı:"i",Ä´:"J",ĵ:"j",Ķ:"K",Ä·:"k",ĸ:"k",Ĺ:"L",Ä»:"L",Ľ:"L",Ä¿:"L",Å:"L",ĺ:"l",ļ:"l",ľ:"l",Å:"l",Å:"l",Å:"N",Å
:"N",Å:"N",Å:"N",Å:"n",Å:"n",Å:"n",Å:"n",Å:"O",Å:"O",Å:"O",Å:"o",Å:"o",Å:"o",Å:"R",Å:"R",Å:"R",Å:"r",Å:"r",Å:"r",Å:"S",Å:"S",Å:"S",Å :"S",Å:"s",Å:"s",Å:"s",Å¡:"s",Å¢:"T",Ť:"T",Ŧ:"T",Å£:"t",Å¥:"t",ŧ:"t",Ũ:"U",Ū:"U",Ŭ:"U",Å®:"U",Ű:"U",Ų:"U",Å©:"u",Å«:"u",Å:"u",ů:"u",ű:"u",ų:"u",Å´:"W",ŵ:"w",Ŷ:"Y",Å·:"y",Ÿ:"Y",Ź:"Z",Å»:"Z",Ž:"Z",ź:"z",ż:"z",ž:"z",IJ:"IJ",ij:"ij",Å:"Oe",Å:"oe",Å:"'n",Å¿:"s"})},573086,(e,t,r)=>{var i=e.r(968252),n=e.r(702922),s=/[\xc0-\xd6\xd8-\xf6\xf8-\xff\u0100-\u01
1017f]/g,a=RegExp("[\\u0300-\\u036f\\ufe20-\\ufe2f\\u20d0-\\u20ff]","g");t.exports=function(e){return(e=n(e))&&e.replace(s,i).replace(a,"")}},540253,(e,t,r)=>{var i=/[^\x00-\x2f\x3a-\x40\x5b-\x60\x7b-\x7f]+/g;t.exports=function(e){return e.match(i)||[]}},174828,(e,t,r)=>{var i=/[a-z][A-Z]|[A-Z]{2}[a-z]|[0-9][a-zA-Z]|[a-zA-Z][0-9]|[^a-zA-Z0-9 ]/;t.exports=function(e){return i.test(e)}},81144,(e,t,r)=>{var i="\\ud800-\\udfff",n="\\u2700-\\u27bf",s="a-z\\xdf-\\xf6\\xf8-\\xff",a="A-Z\\xc0-\\xd6\\xd8-\\xde",o="\\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",l="['â]",u="["+o+"]",c="["+s+"]",d="[^"+i+o+"\\d+"+n+s+a+"]",h="(?:\\ud83c[\\udde6-\\uddff]){2}",f="[\\ud800-\\udbff][\\udc00-\\udfff]",p="["+a+"]",g="(?:"+c+"|"+d+")",m="(?:"+p+"|"+d+")",y="(?:"+l+"(?:d|ll|m|re|s|t|ve))?",v="(?:"+l+"(?:D|LL|M|RE|S|T|VE))?",b="(?:[\\u0300-\\u036f\\ufe20-\\ufe2f\\u20d0-\\u20ff]|\\ud83c[\\udffb-\\udfff])?",_="[\\ufe0e\\ufe0f]?",E="(?:\\u200d(?:"+["[^"+i+"]",h,f].join("|")+")"+_+b+")*",S="(?:"+["["+n+"]",h,f].join("|")+")"+(_+b+E),x=RegExp([p+"?"+c+"+"+y+"(?="+[u,p,"$"].join("|")+")",m+"+"+v+"(?="+[u,p+g,"$"].join("|")+")",p+"?"+g+"+"+y,p+"+"+v,"\\d*(?:1ST|2ND|3RD|(?![123])\\dTH)(?=\\b|[a-z_])|\\d*(?:1st|2nd|3rd|(?![123])\\dth)(?=\\b|[A-Z_])|\\d+",S].join("|"),"g");t.exports=function(e){return e.match(x)||[]}},129548,(e,t,r)=>{var i=e.r(540253),n=e.r(174828),s=e.r(702922),a=e.r(81144);t.exports=function(e,t,r){return(e=s(e),void 0===(t=r?void 0:t))?n(e)?a(e):i(e):e.match(t)||[]}},876168,(e,t,r)=>{var i=e.r(992427),n=e.r(573086),s=e.r(129548),a=RegExp("['â]","g");t.exports=function(e){return function(t){return i(s(n(t).replace(a,"")),e,"")}}},369640,(e,t,r)=>{t.exports=e.r(876168)(function(e,t,r){return e+(r?"_":"")+t.toLowerCase()})},795014,(e,t,r)=>{t.exports=function(e,t,r){var i=-1,n=e.length;t<0&&(t=-t>n?0:n+t),(r=r>n?n:r)<0&&(r+=n),n=t>r?0:r-t>>>0,t>>>=0;for(var s=Array(n);++i<n;)s[i]=e[i+t];return s}},284357,(e,t,r)=>{var i=e.r(795014);t.exports=function(e,t,r){var n=e.length;return r=void 0===r?n:r,!t&&r>=n?e:i(e,t,r)}},979589,(e,t,r)=>{var i=RegExp("[\\u200d\\ud800-\\udfff\\u0300-\\u036f\\ufe20-\\ufe2f\\u20d0-\\u20ff\\ufe0e\\ufe0f]");t.exports=function(e){return i.test(e)}},758672,(e,t,r)=>{t.exports=function(e){return e.split("")}},695365,(e,t,r)=>{var i="\\ud800-\\udfff",n="[\\u0300-\\u036f\\ufe20-\\ufe2f\\u20d0-\\u20ff]",s="\\ud83c[\\udffb-\\udfff]",a="[^"+i+"]",o="(?:\\ud83c[\\udde6-\\uddff]){2}",l="[\\ud800-\\udbff][\\udc00-\\udfff]",u="(?:"+n+"|"+s+")?",c="[\\ufe0e\\ufe0f]?",d="(?:\\u200d(?:"+[a,o,l].join("|")+")"+c+u+")*",h=RegExp(s+"(?="+s+")|"+("(?:"+[a+n+"?",n,o,l,"["+i+"]"].join("|"))+")"+(c+u+d),"g");t.exports=function(e){return e.match(h)||[]}},34170,(e,t,r)=>{var i=e.r(758672),n=e.r(979589),s=e.r(695365);t.exports=function(e){return n(e)?s(e):i(e)}},229821,(e,t,r)=>{var i=e.r(284357),n=e.r(979589),s=e.r(34170),a=e.r(702922);t.exports=function(e){return function(t){var r=n(t=a(t))?s(t):void 0,o=r?r[0]:t.charAt(0),l=r?i(r,1).join(""):t.slice(1);return o[e]()+l}}},232241,(e,t,r)=>{t.exports=e.r(229821)("toUpperCase")},220250,(e,t,r)=>{var i=e.r(702922),n=e.r(232241);t.exports=function(e){return n(i(e).toLowerCase())}},459823,(e,t,r)=>{var i=e.r(220250);t.exports=e.r(876168)(function(e,t,r){return t=t.toLowerCase(),e+(r?i(t):t)})},861757,(e,t,r)=>{var i=e.r(674548),n=e.r(163799),s=e.r(666305);t.exports=function(e,t){var r={};return t=s(t,3),n(e,function(e,n,s){i(r,t(e,n,s),e)}),r}},301439,(e,t,r)=>{function i(e,t){var r=e.length,i=Array(r),n={},s=r,a=function(e){for(var t=new Map,r=0,i=e.length;r<i;r++){var n=e[r];t.has(n[0])||t.set(n[0],new Set),t.has(n[1])||t.set(n[1],new Set),t.get(n[0]).add(n[1])}return t}(t),o=function(e){for(var t=new Map,r=0,i=e.length;r<i;r++)t.set(e[r],r);return t}(e);for(t.forEach(function(e){if(!o.has(e[0])||!o.has(e[1]))throw Error("Unknown node. There is an unknown node in the supplied edges.")});s--;)n[s]||function e(t,s,l){if(l.has(t)){var u;try{u=", node was:"+JSON.stringify(t)}catch(e){u=""}throw Error("Cyclic dependency"+u)}if(!o.has(t))throw Error("Found unknown node. Make sure to provided all involved nodes. Unknown node: "+JSON.stringify(t));if(!n[s]){n[s]=!0;var c=a.get(t)||new Set;if(s=(c=Array.from(c)).length){l.add(t);do{var d=c[--s];e(d,o.get(d),l)}while(s)l.delete(t)}i[--r]=t}}(e[s],s,new Set);return i}t.exports=function(e){return i(function(e){for(var t=new Set,r=0,i=e.length;r<i;r++){var n=e[r];t.add(n[0]),t.add(n[1])}return Array.from(t)}(e),e)},t.exports.array=i},1691,190121,822199,736118,521534,e=>{"use strict";try{y=Map}catch(e){}try{v=Set}catch(e){}function t(e){return function e(r,i,n){if(!r||"object"!=typeof r||"function"==typeof r)return r;if(r.nodeType&&"cloneNode"in r)return r.cloneNode(!0);if(r instanceof Date)return new Date(r.getTime());if(r instanceof RegExp)return new RegExp(r);if(Array.isArray(r))return r.map(t);if(y&&r instanceof y)return new Map(Array.from(r.entries()));
101if(v&&r instanceof v)return new Set(Array.from(r.values()));if(r instanceof Object){i.push(r);var s=Object.create(r);for(var a in n.push(s),r){var o=i.findIndex(function(e){return e===r[a]});s[a]=o>-1?n[o]:e(r[a],i,n)}return s}return r}(e,[],[])}let r=Object.prototype.toString,i=Error.prototype.toString,n=RegExp.prototype.toString,s="u">typeof Symbol?Symbol.prototype.toString:()=>"",a=/^Symbol\((.*)\)(.*)$/;function o(e,t=!1){if(null==e||!0===e||!1===e)return""+e;let l=typeof e;if("number"===l)return e!=+e?"NaN":0===e&&1/e<0?"-0":""+e;if("string"===l)return t?`"${e}"`:e;if("function"===l)return"[Function "+(e.name||"anonymous")+"]";if("symbol"===l)return s.call(e).replace(a,"Symbol($1)");let u=r.call(e).slice(8,-1);return"Date"===u?isNaN(e.getTime())?""+e:e.toISOString(e):"Error"===u||e instanceof Error?"["+i.call(e)+"]":"RegExp"===u?n.call(e):null}function l(e,t){let r=o(e,t);return null!==r?r:JSON.stringify(e,function(e,r){let i=o(this[e],t);return null!==i?i:r},2)}let u={default:"${path} is invalid",required:"${path} is a required field",oneOf:"${path} must be one of the following values: ${values}",notOneOf:"${path} must not be one of the following values: ${values}",notType:({path:e,type:t,value:r,originalValue:i})=>{let n=null!=i&&i!==r,s=`${e} must be a \`${t}\` type, but the final value was: \`${l(r,!0)}\``+(n?` (cast from the value \`${l(i,!0)}\`).`:".");return null===r&&(s+='\n If "null" is intended as an empty value be sure to mark the schema as `.nullable()`'),s},defined:"${path} must be defined"},c={length:"${path} must be exactly ${length} characters",min:"${path} must be at least ${min} characters",max:"${path} must be at most ${max} characters",matches:'${path} must match the following: "${regex}"',email:"${path} must be a valid email",url:"${path} must be a valid URL",uuid:"${path} must be a valid UUID",trim:"${path} must be a trimmed string",lowercase:"${path} must be a lowercase string",uppercase:"${path} must be a upper case string"},d={min:"${path} must be greater than or equal to ${min}",max:"${path} must be less than or equal to ${max}",lessThan:"${path} must be less than ${less}",moreThan:"${path} must be greater than ${more}",positive:"${path} must be a positive number",negative:"${path} must be a negative number",integer:"${path} must be an integer"},h={min:"${path} field must be later than ${min}",max:"${path} field must be at earlier than ${max}"},f={isValue:"${path} field must be ${value}"},p={noUnknown:"${path} field has unspecified keys: ${unknown}"},g={min:"${path} field must have at least ${min} items",max:"${path} field must have less than or equal to ${max} items",length:"${path} must have ${length} items"};Object.assign(Object.create(null),{mixed:u,string:c,number:d,date:h,object:p,array:g,boolean:f});var m,y,v,b=e.i(344708);let _=e=>e&&e.__isYupSchema__,E=class{constructor(e,t){if(this.fn=void 0,this.refs=e,this.refs=e,"function"==typeof t){this.fn=t;return}if(!(0,b.default)(t,"is"))throw TypeError("`is:` is required for `when()` conditions");if(!t.then&&!t.otherwise)throw TypeError("either `then:` or `otherwise:` is required for `when()` conditions");let{is:r,then:i,otherwise:n}=t,s="function"==typeof r?r:(...e)=>e.every(e=>e===r);this.fn=function(...e){let t=e.pop(),r=e.pop(),a=s(...e)?i:n;if(a)return"function"==typeof a?a(r):r.concat(a.resolve(t))}}resolve(e,t){let r=this.refs.map(e=>e.getValue(null==t?void 0:t.value,null==t?void 0:t.parent,null==t?void 0:t.context)),i=this.fn.apply(e,r.concat(e,t));if(void 0===i||i===e)return e;if(!_(i))throw TypeError("conditions must return a schema object");return i.resolve(t)}};function S(e){return null==e?[]:[].concat(e)}function x(){return(x=Object.assign||function(e){for(var t=1;t<arguments.length;t++){var r=arguments[t];for(var i in r)Object.prototype.hasOwnProperty.call(r,i)&&(e[i]=r[i])}return e}).apply(this,arguments)}let T=/\$\{\s*(\w+)\s*\}/g;class w extends Error{static formatError(e,t){let r=t.label||t.path||"this";return(r!==t.path&&(t=x({},t,{path:r})),"string"==typeof e)?e.replace(T,(e,r)=>l(t[r])):"function"==typeof e?e(t):e}static isError(e){return e&&"ValidationError"===e.name}
101constructor(e,t,r,i){super(),this.value=void 0,this.path=void 0,this.type=void 0,this.errors=void 0,this.params=void 0,this.inner=void 0,this.name="ValidationError",this.value=t,this.path=r,this.type=i,this.errors=[],this.inner=[],S(e).forEach(e=>{w.isError(e)?(this.errors.push(...e.errors),this.inner=this.inner.concat(e.inner.length?e.inner:e)):this.errors.push(e)}),this.message=this.errors.length>1?`${this.errors.length} errors occurred`:this.errors[0],Error.captureStackTrace&&Error.captureStackTrace(this,w)}}function A(e,t){let r,{endEarly:i,tests:n,args:s,value:a,errors:o,sort:l,path:u}=e,c=(r=!1,(...e)=>{r||(r=!0,t(...e))}),d=n.length,h=[];if(o=o||[],!d)return o.length?c(new w(o,a,u)):c(null,a);for(let e=0;e<n.length;e++)(0,n[e])(s,function(e){if(e){if(!w.isError(e))return c(e,a);if(i)return e.value=a,c(e,a);h.push(e)}if(--d<=0){if(h.length&&(l&&h.sort(l),o.length&&h.push(...o),o=h),o.length)return void c(new w(o,a,u),a);c(null,a)}})}var R=e.i(460793),I=e.i(437472);class k{constructor(e,t={}){if(this.key=void 0,this.isContext=void 0,this.isValue=void 0,this.isSibling=void 0,this.path=void 0,this.getter=void 0,this.map=void 0,"string"!=typeof e)throw TypeError("ref must be a string, got: "+e);if(this.key=e.trim(),""===e)throw TypeError("ref must be a non-empty string");this.isContext="$"===this.key[0],this.isValue="."===this.key[0],this.isSibling=!this.isContext&&!this.isValue;let r=this.isContext?"$":this.isValue?".":"";this.path=this.key.slice(r.length),this.getter=this.path&&(0,I.getter)(this.path,!0),this.map=t.map}getValue(e,t,r){let i=this.isContext?r:this.isValue?e:t;return this.getter&&(i=this.getter(i||{})),this.map&&(i=this.map(i)),i}cast(e,t){return this.getValue(e,null==t?void 0:t.parent,null==t?void 0:t.context)}resolve(){return this}describe(){return{type:"ref",key:this.key}}toString(){return`Ref(${this.key})`}static isRef(e){return e&&e.__isYupRef}}function C(){return(C=Object.assign||function(e){for(var t=1;t<arguments.length;t++){var r=arguments[t];for(var i in r)Object.prototype.hasOwnProperty.call(r,i)&&(e[i]=r[i])}return e}).apply(this,arguments)}function D(e){function t(t,r){let i,{value:n,path:s="",label:a,options:o,originalValue:l,sync:u}=t,c=function(e,t){if(null==e)return{};var r,i,n={},s=Object.keys(e);for(i=0;i<s.length;i++)t.indexOf(r=s[i])>=0||(n[r]=e[r]);return n}(t,["value","path","label","options","originalValue","sync"]),{name:d,test:h,params:f,message:p}=e,{parent:g,context:m}=o;function y(e){return k.isRef(e)?e.getValue(n,g,m):e}function v(e={}){let t=(0,R.default)(C({value:n,originalValue:l,label:a,path:e.path||s},f,e.params),y),r=new w(w.formatError(e.message||p,t),n,t.path,e.type||d);return r.params=t,r}let b=C({path:s,parent:g,type:d,createError:v,resolve:y,options:o,originalValue:l},c);if(!u){try{Promise.resolve(h.call(b,n,b)).then(e=>{w.isError(e)?r(e):e?r(null,e):r(v())}).catch(r)}catch(e){r(e)}return}try{var _;if(i=h.call(b,n,b),"function"==typeof(null==(_=i)?void 0:_.then))throw Error(`Validation test of type: "${b.type}" returned a Promise during a synchronous validate. This test will finish after the validate call has returned`)}catch(e){r(e);return}w.isError(i)?r(i):i?r(null,i):r(v())}return t.OPTIONS=e,t}k.prototype.__isYupRef=!0;class L{constructor(){this.list=void 0,this.refs=void 0,this.list=new Set,this.refs=new Map}get size(){return this.list.size+this.refs.size}describe(){let e=[];for(let t of this.list)e.push(t);for(let[,t]of this.refs)e.push(t.describe());return e}toArray(){return Array.from(this.list).concat(Array.from(this.refs.values()))}resolveAll(e){return this.toArray().reduce((t,r)=>t.concat(k.isRef(r)?e(r):r),[])}add(e){k.isRef(e)?this.refs.set(e.key,e):this.list.add(e)}delete(e){k.isRef(e)?this.refs.delete(e.key):this.list.delete(e)}clone(){let e=new L;return e.list=new Set(this.list),e.refs=new Map(this.refs),e}merge(e,t){let r=this.clone();return e.list.forEach(e=>r.add(e)),e.refs.forEach(e=>r.add(e)),t.list.forEach(e=>r.delete(e)),t.refs.forEach(e=>r.delete(e)),r}}function O(){return(O=Object.assign||function(e){for(var t=1;t<arguments.length;t++){var r=arguments[t];for(var i in r)Object.prototype.hasOwnProperty.call(r,i)&&(e[i]=r[i])}return e}).apply(this,arguments)}class P{constructor(e){this.deps=[],this.tests=void 0,this.transforms=void 0,this.conditions=[],this._mutate=void 0,this._typeError=void 0,this._whitelist=new L,this._blacklist=new L,this.exclusiveTests=Object.create(null),this.spec=void 0,this.tests=[],this.transforms=[],this.withMutation(()=>{this.typeError(u.notType)}),this.type=(null==e?void 0:e.type)||"mixed",this.spec=O({strip:!1,strict:!1,abortEarly:!0,recursive:!0,nullable:!1,presence:"optional"},null==e?void 0:e.spec)}get _type(){return this.type}_typeCheck(e){return!0}clone(e){if(this._mutate)return e&&Object.assign(this.spec,e),this;let r=Object.create(Object.getPrototypeOf(this));
101return r.type=this.type,r._typeError=this._typeError,r._whitelistError=this._whitelistError,r._blacklistError=this._blacklistError,r._whitelist=this._whitelist.clone(),r._blacklist=this._blacklist.clone(),r.exclusiveTests=O({},this.exclusiveTests),r.deps=[...this.deps],r.conditions=[...this.conditions],r.tests=[...this.tests],r.transforms=[...this.transforms],r.spec=t(O({},this.spec,e)),r}label(e){let t=this.clone();return t.spec.label=e,t}meta(...e){if(0===e.length)return this.spec.meta;let t=this.clone();return t.spec.meta=Object.assign(t.spec.meta||{},e[0]),t}withMutation(e){let t=this._mutate;this._mutate=!0;let r=e(this);return this._mutate=t,r}concat(e){if(!e||e===this)return this;if(e.type!==this.type&&"mixed"!==this.type)throw TypeError(`You cannot \`concat()\` schema's of different types: ${this.type} and ${e.type}`);let t=e.clone(),r=O({},this.spec,t.spec);return t.spec=r,t._typeError||(t._typeError=this._typeError),t._whitelistError||(t._whitelistError=this._whitelistError),t._blacklistError||(t._blacklistError=this._blacklistError),t._whitelist=this._whitelist.merge(e._whitelist,e._blacklist),t._blacklist=this._blacklist.merge(e._blacklist,e._whitelist),t.tests=this.tests,t.exclusiveTests=this.exclusiveTests,t.withMutation(t=>{e.tests.forEach(e=>{t.test(e.OPTIONS)})}),t.transforms=[...this.transforms,...t.transforms],t}isType(e){return!!this.spec.nullable&&null===e||this._typeCheck(e)}resolve(e){let t=this;if(t.conditions.length){let r=t.conditions;(t=t.clone()).conditions=[],t=(t=r.reduce((t,r)=>r.resolve(t,e),t)).resolve(e)}return t}cast(e,t={}){let r=this.resolve(O({value:e},t)),i=r._cast(e,t);if(void 0!==e&&!1!==t.assert&&!0!==r.isType(i)){let n=l(e),s=l(i);throw TypeError(`The value of ${t.path||"field"} could not be cast to a value that satisfies the schema type: "${r._type}". 102 103attempted value: ${n} 104`+(s!==n?`result of cast: ${s}`:""))}return i}_cast(e,t){let r=void 0===e?e:this.transforms.reduce((t,r)=>r.call(this,t,e,this),e);return void 0===r&&(r=this.getDefault()),r}_validate(e,t={},r){let{sync:i,path:n,from:s=[],originalValue:a=e,strict:o=this.spec.strict,abortEarly:l=this.spec.abortEarly}=t,u=e;o||(u=this._cast(u,O({assert:!1},t)));let c={value:u,path:n,options:t,originalValue:a,schema:this,label:this.spec.label,sync:i,from:s},d=[];this._typeError&&d.push(this._typeError);let h=[];this._whitelistError&&h.push(this._whitelistError),this._blacklistError&&h.push(this._blacklistError),A({args:c,value:u,path:n,sync:i,tests:d,endEarly:l},e=>{e?r(e,u):A({tests:this.tests.concat(h),args:c,path:n,sync:i,value:u,endEarly:l},r)})}validate(e,t,r){let i=this.resolve(O({},t,{value:e}));return"function"==typeof r?i._validate(e,t,r):new Promise((r,n)=>i._validate(e,t,(e,t)=>{e?n(e):r(t)}))}validateSync(e,t){let r;return this.resolve(O({},t,{value:e}))._validate(e,O({},t,{sync:!0}),(e,t)=>{if(e)throw e;r=t}),r}isValid(e,t){return this.validate(e,t).then(()=>!0,e=>{if(w.isError(e))return!1;throw e})}isValidSync(e,t){try{return this.validateSync(e,t),!0}catch(e){if(w.isError(e))return!1;throw e}}_getDefault(){let e=this.spec.default;return null==e?e:"function"==typeof e?e.call(this):t(e)}getDefault(e){return this.resolve(e||{})._getDefault()}default(e){return 0==arguments.length?this._getDefault():this.clone({default:e})}strict(e=!0){let t=this.clone();return t.spec.strict=e,t}_isPresent(e){return null!=e}defined(e=u.defined){return this.test({message:e,name:"defined",exclusive:!0,test:e=>void 0!==e})}required(e=u.required){return this.clone({presence:"required"}).withMutation(t=>t.test({message:e,name:"required",exclusive:!0,test(e){return this.schema._isPresent(e)}}))}notRequired(){let e=this.clone({presence:"optional"});return e.tests=e.tests.filter(e=>"required"!==e.OPTIONS.name),e}nullable(e=!0){return this.clone({nullable:!1!==e})}transform(e){let t=this.clone();return t.transforms.push(e),t}test(...e){let t;if(void 0===(t=1===e.length?"function"==typeof e[0]?{test:e[0]}:e[0]:2===e.length?{name:e[0],test:e[1]}:{name:e[0],message:e[1],test:e[2]}).message&&(t.message=u.default),"function"!=typeof t.test)throw TypeError("`test` is a required parameters");let r=this.clone(),i=D(t),n=t.exclusive||t.name&&!0===r.exclusiveTests[t.name];if(t.exclusive&&!t.name)throw TypeError("Exclusive tests must provide a unique `name` identifying the test");return t.name&&(r.exclusiveTests[t.name]=!!t.exclusive),r.tests=r.tests.filter(e=>(e.OPTIONS.name!==t.name||!n&&e.OPTIONS.test!==i.OPTIONS.test)&&!0),r.tests.push(i),r}when(e,t){Array.isArray(e)||"string"==typeof e||(t=e,e=".");let r=this.clone(),i=S(e).map(e=>new k(e));
104return i.forEach(e=>{e.isSibling&&r.deps.push(e.key)}),r.conditions.push(new E(i,t)),r}typeError(e){let t=this.clone();return t._typeError=D({message:e,name:"typeError",test(e){return void 0===e||!!this.schema.isType(e)||this.createError({params:{type:this.schema._type}})}}),t}oneOf(e,t=u.oneOf){let r=this.clone();return e.forEach(e=>{r._whitelist.add(e),r._blacklist.delete(e)}),r._whitelistError=D({message:t,name:"oneOf",test(e){if(void 0===e)return!0;let t=this.schema._whitelist,r=t.resolveAll(this.resolve);return!!r.includes(e)||this.createError({params:{values:t.toArray().join(", "),resolved:r}})}}),r}notOneOf(e,t=u.notOneOf){let r=this.clone();return e.forEach(e=>{r._blacklist.add(e),r._whitelist.delete(e)}),r._blacklistError=D({message:t,name:"notOneOf",test(e){let t=this.schema._blacklist,r=t.resolveAll(this.resolve);return!r.includes(e)||this.createError({params:{values:t.toArray().join(", "),resolved:r}})}}),r}strip(e=!0){let t=this.clone();return t.spec.strip=e,t}describe(){let e=this.clone(),{label:t,meta:r}=e.spec;return{meta:r,label:t,type:e.type,oneOf:e._whitelist.describe(),notOneOf:e._blacklist.describe(),tests:e.tests.map(e=>({name:e.OPTIONS.name,params:e.OPTIONS.params})).filter((e,t,r)=>r.findIndex(t=>t.name===e.name)===t)}}}for(let e of(P.prototype.__isYupSchema__=!0,["validate","validateSync"]))P.prototype[`${e}At`]=function(t,r,i={}){let{parent:n,parentPath:s,schema:a}=function(e,t,r,i=r){let n,s,a;return t?((0,I.forEach)(t,(o,l,u)=>{let c=l?o.substr(0,o.length-1).substr(1):o;if((e=e.resolve({context:i,parent:n,value:r})).innerType){let i=u?parseInt(c,10):0;if(r&&i>=r.length)throw Error(`Yup.reach cannot resolve an array item at index: ${o}, in the path: ${t}. because there is no value at that index. `);n=r,r=r&&r[i],e=e.innerType}if(!u){if(!e.fields||!e.fields[c])throw Error(`The schema does not contain the path: ${t}. (failed at: ${a} which is a type: "${e._type}")`);n=r,r=r&&r[c],e=e.fields[c]}s=c,a=l?"["+o+"]":"."+o}),{schema:e,parent:n,parentPath:s}):{parent:n,parentPath:t,schema:e}}(this,t,r,i.context);return a[e](n&&n[s],O({},i,{parent:n,path:t}))};for(let e of["equals","is"])P.prototype[e]=P.prototype.oneOf;for(let e of["not","nope"])P.prototype[e]=P.prototype.notOneOf;P.prototype.optional=P.prototype.notRequired,P.prototype;let F=/^((([a-z]|\d|[!#\$%&'\*\+\-\/=\?\^_`{\|}~]|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])+(\.([a-z]|\d|[!#\$%&'\*\+\-\/=\?\^_`{\|}~]|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])+)*)|((\x22)((((\x20|\x09)*(\x0d\x0a))?(\x20|\x09)+)?(([\x01-\x08\x0b\x0c\x0e-\x1f\x7f]|\x21|[\x23-\x5b]|[\x5d-\x7e]|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])|(\\([\x01-\x09\x0b\x0c\x0d-\x7f]|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF]))))*(((\x20|\x09)*(\x0d\x0a))?(\x20|\x09)+)?(\x22)))@((([a-z]|\d|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])|(([a-z]|\d|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])([a-z]|\d|-|\.|_|~|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])*([a-z]|\d|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])))\.)+(([a-z]|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])|(([a-z]|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])([a-z]|\d|-|\.|_|~|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])*([a-z]|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])))$/i,N=/^((https?|ftp):)?\/\/(((([a-z]|\d|-|\.|_|~|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])|(%[\da-f]{2})|[!\$&'\(\)\*\+,;=]|:)*@)?(((\d|[1-9]\d|1\d\d|2[0-4]\d|25[0-5])\.(\d|[1-9]\d|1\d\d|2[0-4]\d|25[0-5])\.(\d|[1-9]\d|1\d\d|2[0-4]\d|25[0-5])\.(\d|[1-9]\d|1\d\d|2[0-4]\d|25[0-5]))|((([a-z]|\d|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])|(([a-z]|\d|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])([a-z]|\d|-|\.|_|~|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])*([a-z]|\d|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])))\.)+(([a-z]|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])|(([a-z]|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])([a-z]|\d|-|\.|_|~|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])*([a-z]|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])))\.?)(:\d*)?)(\/((([a-z]|\d|-|\.|_|~|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])|(%[\da-f]{2})|[!\$&'\(\)\*\+,;=]|:|@)+(\/(([a-z]|\d|-|\.|_|~|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])|(%[\da-f]{2})|[!\$&'\(\)\*\+,;=]|:|@)*)*)?)?(\?((([a-z]|\d|-|\.|_|~|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])|(%[\da-f]{2})|[!\$&'\(\)\*\+,;=]|:|@)|[\uE000-\uF8FF]|\/|\?)*)?(\#((([a-z]|\d|-|\.|_|~|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])|(%[\da-f]{2})|[!\$&'\(\)\*\+,;=]|:|@)|\/|\?)*)?$/i,M=/^(?:[0-9a-f]{8}-[0-9a-f]{4}-[1-5][0-9a-f]{3}-[89ab][0-9a-f]{3}-[0-9a-f]{12}|00000000-0000-0000-0000-000000000000)$/i,j=e=>null==e||e===e.trim(),$=({}).toString();function U(){return new B}class B extends P{constructor(){super({type:"string"}),this.withMutation(()=>{this.transform(function(e){if(this.isType(e)||Array.isArray(e))return e;let t=null!=e&&e.toString?e.toString():e;return t===$?e:t})})}_typeCheck(e){return e instanceof String&&(e=e.valueOf()),"string"==typeof e}_isPresent(e){return super._isPresent(e)&&!!e.length}length(e,t=c.length){return this.test({message:t,name:"length",exclusive:!0,params:{length:e},test(t){return null==t||t.length===this.resolve(e)}})}min(e,t=c.min){return this.test({message:t,name:"min",exclusive:!0,params:{min:e},test(t){return null==t||t.length>=this.resolve(e)}})}max(e,t=c.max){return this.test({name:"max",exclusive:!0,message:t,params:{max:e},test(t){return null==t||t.length<=this.resolve(e)}})}matches(e,t){let r,i,n=!1;return t&&("object"==typeof t?{excludeEmptyString:n=!1,message:r,name:i}=t:r=t),this.test({name:i||"matches",message:r||c.matches,params:{regex:e},test:t=>null==t||""===t&&n||-1!==t.search(e)})}email(e=c.email){return this.matches(F,{name:"email",message:e,excludeEmptyString:!0})}url(e=c.url){return this.matches(N,{name:"url",message:e,excludeEmptyString:!0})}uuid(e=c.uuid){return this.matches(M,{name:"uuid",message:e,excludeEmptyString:!1})}ensure(){return this.default("").transform(e=>null===e?"":e)}trim(e=c.trim){return this.transform(e=>null!=e?e.trim():e).test({message:e,name:"trim",test:j})}lowercase(e=c.lowercase){return this.transform(e=>null==e?e:e.toLowerCase()).test({message:e,name:"string_case",exclusive:!0,test:e=>null==e||e===e.toLowerCase()})}uppercase(e=c.uppercase){return this.transform(e=>null==e?e:e.toUpperCase()).test({message:e,name:"string_case",exclusive:!0,test:e=>null==e||e===e.toUpperCase()})}}U.prototype=B.prototype;var V=/^(\d{4}|[+\-]\d{6})(?:-?(\d{2})(?:-?(\d{2}))?)?(?:[ T]?(\d{2}):?(\d{2})(?::?(\d{2})(?:[,\.](\d{1,}))?)?(?:(Z)|([+\-])(\d{2})(?::?(\d{2}))?)?)?$/;let G=new Date("");function q(){return new H}class H extends P{constructor(){super({type:"date"}),this.withMutation(()=>{this.transform(function(e){return this.isType(e)?e:isNaN(e=function(e){var t,r,i=[1,4,5,6,7,10,11],n=0;if(r=V.exec(e)){for(var s,a=0;s=i[a];++a)r[s]=+r[s]||0;r[2]=(+r[2]||1)-1,r[3]=+r[3]||1,r[7]=r[7]?String(r[7]).substr(0,3):0,(void 0===r[8]||""===r[8])&&(void 0===r[9]||""===r[9])?t=+new Date(r[1],r[2],r[3],r[4],r[5],r[6],r[7]):("Z"!==r[8]&&void 0!==r[9]&&(n=60*r[10]+r[11
104],"+"===r[9]&&(n=0-n)),t=Date.UTC(r[1],r[2],r[3],r[4],r[5]+n,r[6],r[7]))}else t=Date.parse?Date.parse(e):NaN;return t}(e))?G:new Date(e)})})}_typeCheck(e){return"[object Date]"===Object.prototype.toString.call(e)&&!isNaN(e.getTime())}prepareParam(e,t){let r;if(k.isRef(e))r=e;else{let i=this.cast(e);if(!this._typeCheck(i))throw TypeError(`\`${t}\` must be a Date or a value that can be \`cast()\` to a Date`);r=i}return r}min(e,t=h.min){let r=this.prepareParam(e,"min");return this.test({message:t,name:"min",exclusive:!0,params:{min:e},test(e){return null==e||e>=this.resolve(r)}})}max(e,t=h.max){let r=this.prepareParam(e,"max");return this.test({message:t,name:"max",exclusive:!0,params:{max:e},test(e){return null==e||e<=this.resolve(r)}})}}H.INVALID_DATE=G,q.prototype=H.prototype,q.INVALID_DATE=G;var z=e.i(369640),K=e.i(459823),W=e.i(861757),Y=e.i(301439);function Q(e,t){let r=1/0;return e.some((e,i)=>{var n;if((null==(n=t.path)?void 0:n.indexOf(e))!==-1)return r=i,!0}),r}function X(e){return(t,r)=>Q(e,t)-Q(e,r)}function J(){return(J=Object.assign||function(e){for(var t=1;t<arguments.length;t++){var r=arguments[t];for(var i in r)Object.prototype.hasOwnProperty.call(r,i)&&(e[i]=r[i])}return e}).apply(this,arguments)}let Z=e=>"[object Object]"===Object.prototype.toString.call(e),ee=X([]);class et extends P{constructor(e){super({type:"object"}),this.fields=Object.create(null),this._sortErrors=ee,this._nodes=[],this._excludedEdges=[],this.withMutation(()=>{this.transform(function(e){if("string"==typeof e)try{e=JSON.parse(e)}catch(t){e=null}return this.isType(e)?e:null}),e&&this.shape(e)})}_typeCheck(e){return Z(e)||"function"==typeof e}_cast(e,t={}){var r;let i=super._cast(e,t);if(void 0===i)return this.getDefault();if(!this._typeCheck(i))return i;let n=this.fields,s=null!=(r=t.stripUnknown)?r:this.spec.noUnknown,a=this._nodes.concat(Object.keys(i).filter(e=>-1===this._nodes.indexOf(e))),o={},l=J({},t,{parent:o,__validating:t.__validating||!1}),u=!1;for(let e of a){let r=n[e],a=(0,b.default)(i,e);if(r){let n,s=i[e];l.path=(t.path?`${t.path}.`:"")+e;let a="spec"in(r=r.resolve({value:s,context:t.context,parent:o}))?r.spec:void 0,c=null==a?void 0:a.strict;if(null==a?void 0:a.strip){u=u||e in i;continue}void 0!==(n=t.__validating&&c?i[e]:r.cast(i[e],l))&&(o[e]=n)}else a&&!s&&(o[e]=i[e]);o[e]!==i[e]&&(u=!0)}return u?o:i}_validate(e,t={},r){let i=[],{sync:n,from:s=[],originalValue:a=e,abortEarly:o=this.spec.abortEarly,recursive:l=this.spec.recursive}=t;s=[{schema:this,value:a},...s],t.__validating=!0,t.originalValue=a,t.from=s,super._validate(e,t,(e,u)=>{if(e){if(!w.isError(e)||o)return void r(e,u);i.push(e)}l&&Z(u)?(a=a||u,A({sync:n,tests:this._nodes.map(e=>(r,i)=>{let n=-1===e.indexOf(".")?(t.path?`${t.path}.`:"")+e:`${t.path||""}["${e}"]`,o=this.fields[e];o&&"validate"in o?o.validate(u[e],J({},t,{path:n,from:s,strict:!0,parent:u,originalValue:a[e]}),i):i(null)}),value:u,errors:i,endEarly:o,sort:this._sortErrors,path:t.path},r)):r(i[0]||null,u)})}clone(e){let t=super.clone(e);return t.fields=J({},this.fields),t._nodes=this._nodes,t._excludedEdges=this._excludedEdges,t._sortErrors=this._sortErrors,t}concat(e){let t=super.concat(e),r=t.fields;for(let[e,t]of Object.entries(this.fields)){let i=r[e];void 0===i?r[e]=t:i instanceof P&&t instanceof P&&(r[e]=t.concat(i))}return t.withMutation(()=>t.shape(r,this._excludedEdges))}getDefaultFromShape(){let e={};return this._nodes.forEach(t=>{let r=this.fields[t];e[t]="default"in r?r.getDefault():void 0}),e}_getDefault(){return"default"in this.spec?super._getDefault():this._nodes.length?this.getDefaultFromShape():void 0}shape(e,t=[]){let r=this.clone(),i=Object.assign(r.fields,e);return r.fields=i,r._sortErrors=X(Object.keys(i)),t.length&&(Array.isArray(t[0])||(t=[t]),r._excludedEdges=[...r._excludedEdges,...t]),r._nodes=function(e,t=[]){let r=[],i=new Set,n=new Set(t.map(([e,t])=>`${e}-${t}`));function s(e,t){let s=(0,I.split)(e)[0];i.add(s),n.has(`${t}-${s}`)||r.push([t,s])}for(let t in e)if((0,b.default)(e,t)){let r=e[t];i.add(t),k.isRef(r)&&r.isSibling?s(r.path,t):_(r)&&"deps"in r&&r.deps.forEach(e
104=>s(e,t))}return Y.default.array(Array.from(i),r).reverse()}(i,r._excludedEdges),r}pick(e){let t={};for(let r of e)this.fields[r]&&(t[r]=this.fields[r]);return this.clone().withMutation(e=>(e.fields={},e.shape(t)))}omit(e){let t=this.clone(),r=t.fields;for(let i of(t.fields={},e))delete r[i];return t.withMutation(()=>t.shape(r))}from(e,t,r){let i=(0,I.getter)(e,!0);return this.transform(n=>{if(null==n)return n;let s=n;return(0,b.default)(n,e)&&(s=J({},n),r||delete s[e],s[t]=i(n)),s})}noUnknown(e=!0,t=p.noUnknown){"string"==typeof e&&(t=e,e=!0);let r=this.test({name:"noUnknown",exclusive:!0,message:t,test(t){var r;let i;if(null==t)return!0;let n=(r=this.schema,i=Object.keys(r.fields),Object.keys(t).filter(e=>-1===i.indexOf(e)));return!e||0===n.length||this.createError({params:{unknown:n.join(", ")}})}});return r.spec.noUnknown=e,r}unknown(e=!0,t=p.noUnknown){return this.noUnknown(!e,t)}transformKeys(e){return this.transform(t=>t&&(0,W.default)(t,(t,r)=>e(r)))}camelCase(){return this.transformKeys(K.default)}snakeCase(){return this.transformKeys(z.default)}constantCase(){return this.transformKeys(e=>(0,z.default)(e).toUpperCase())}describe(){let e=super.describe();return e.fields=(0,R.default)(this.fields,e=>e.describe()),e}}function er(e){return new et(e)}function ei(){return(ei=Object.assign||function(e){for(var t=1;t<arguments.length;t++){var r=arguments[t];for(var i in r)Object.prototype.hasOwnProperty.call(r,i)&&(e[i]=r[i])}return e}).apply(this,arguments)}er.prototype=et.prototype;(class e extends P{constructor(e){super({type:"array"}),this.innerType=void 0,this.innerType=e,this.withMutation(()=>{this.transform(function(e){if("string"==typeof e)try{e=JSON.parse(e)}catch(t){e=null}return this.isType(e)?e:null})})}_typeCheck(e){return Array.isArray(e)}get _subType(){return this.innerType}_cast(e,t){let r=super._cast(e,t);if(!this._typeCheck(r)||!this.innerType)return r;let i=!1,n=r.map((e,r)=>{let n=this.innerType.cast(e,ei({},t,{path:`${t.path||""}[${r}]`}));return n!==e&&(i=!0),n});return i?n:r}_validate(e,t={},r){var i,n;let s=[],a=t.sync,o=t.path,l=this.innerType,u=null!=(i=t.abortEarly)?i:this.spec.abortEarly,c=null!=(n=t.recursive)?n:this.spec.recursive,d=null!=t.originalValue?t.originalValue:e;super._validate(e,t,(e,i)=>{if(e){if(!w.isError(e)||u)return void r(e,i);s.push(e)}if(!c||!l||!this._typeCheck(i))return void r(s[0]||null,i);d=d||i;let n=Array(i.length);for(let e=0;e<i.length;e++){let r=i[e],s=`${t.path||""}[${e}]`,a=ei({},t,{path:s,strict:!0,parent:i,index:e,originalValue:d[e]});n[e]=(e,t)=>l.validate(r,a,t)}A({sync:a,path:o,value:i,errors:s,endEarly:u,tests:n},r)})}clone(e){let t=super.clone(e);return t.innerType=this.innerType,t}concat(e){let t=super.concat(e);return t.innerType=this.innerType,e.innerType&&(t.innerType=t.innerType?t.innerType.concat(e.innerType):e.innerType),t}of(e){let t=this.clone();if(!_(e))throw TypeError("`array.of()` sub-schema must be a valid yup schema not: "+l(e));return t.innerType=e,t}length(e,t=g.length){return this.test({message:t,name:"length",exclusive:!0,params:{length:e},test(t){return null==t||t.length===this.resolve(e)}})}min(e,t){return t=t||g.min,this.test({message:t,name:"min",exclusive:!0,params:{min:e},test(t){return null==t||t.length>=this.resolve(e)}})}max(e,t){return t=t||g.max,this.test({message:t,name:"max",exclusive:!0,params:{max:e},test(t){return null==t||t.length<=this.resolve(e)}})}ensure(){return this.default(()=>[]).transform((e,t)=>this._typeCheck(e)?e:null==t?[]:[].concat(t))}compact(e){let t=e?(t,r,i)=>!e(t,r,i):e=>!!e;return this.transform(e=>null!=e?e.filter(t):e)}describe(){let e=super.describe();return this.innerType&&(e.innerType=this.innerType.describe()),e}nullable(e=!0){return super.nullable(e)}defined(){return super.defined()}required(e){return super.required(e)}}).prototype,e.s([],1691),e.s(["object",0,er],190121),e.s(["string",0,U],822199);var en=((m={}).REQUIRED="required",m.EMAIL_FORMAT="typeEmail",m);e.s(["FormErrorsTypes",()=>en],736118),e.s(["formErrorsExists",0,(e,t)=>{if(!e)return"";switch(t){case en.EMAIL_FORMAT:return e.typeEmail||void 0;case en.REQUIRED:return e.required||void 0;default:return""}}],521534)},931067,e=>{"use strict";function t(){return(t=Object.assign.bind()).apply(null,arguments)}e.s(["default",()=>t])},919448,386623,e=>{"use strict";
104function t(e,t){return e.replace(RegExp("(^|\\s)"+t+"(?:\\s|$)","g"),"$1").replace(/\s+/g," ").replace(/^\s*|\s*$/g,"")}e.s(["default",0,function(e,t){if(e.classList)e.classList.add(t);else(e.classList?t&&e.classList.contains(t):-1!==(" "+(e.className.baseVal||e.className)+" ").indexOf(" "+t+" "))||("string"==typeof e.className?e.className=e.className+" "+t:e.setAttribute("class",(e.className&&e.className.baseVal||"")+" "+t))}],919448),e.s(["default",0,function(e,r){e.classList?e.classList.remove(r):"string"==typeof e.className?e.className=t(e.className,r):e.setAttribute("class",t(e.className&&e.className.baseVal||"",r))}],386623)},135581,e=>{"use strict";e.i(247167);var t=e.i(931067),r=e.i(915874),i=e.i(954402),n=e.i(919448),s=e.i(386623),a=e.i(271645),o=e.i(585642),l=e.i(151480),u=function(e,t){return e&&t&&t.split(" ").forEach(function(t){return(0,s.default)(e,t)})},c=function(e){function s(){for(var t,r=arguments.length,i=Array(r),n=0;n<r;n++)i[n]=arguments[n];return(t=e.call.apply(e,[this].concat(i))||this).appliedClasses={appear:{},enter:{},exit:{}},t.onEnter=function(e,r){var i=t.resolveArguments(e,r),n=i[0],s=i[1];t.removeClasses(n,"exit"),t.addClass(n,s?"appear":"enter","base"),t.props.onEnter&&t.props.onEnter(e,r)},t.onEntering=function(e,r){var i=t.resolveArguments(e,r),n=i[0],s=i[1];t.addClass(n,s?"appear":"enter","active"),t.props.onEntering&&t.props.onEntering(e,r)},t.onEntered=function(e,r){var i=t.resolveArguments(e,r),n=i[0],s=i[1]?"appear":"enter";t.removeClasses(n,s),t.addClass(n,s,"done"),t.props.onEntered&&t.props.onEntered(e,r)},t.onExit=function(e){var r=t.resolveArguments(e)[0];t.removeClasses(r,"appear"),t.removeClasses(r,"enter"),t.addClass(r,"exit","base"),t.props.onExit&&t.props.onExit(e)},t.onExiting=function(e){var r=t.resolveArguments(e)[0];t.addClass(r,"exit","active"),t.props.onExiting&&t.props.onExiting(e)},t.onExited=function(e){var r=t.resolveArguments(e)[0];t.removeClasses(r,"exit"),t.addClass(r,"exit","done"),t.props.onExited&&t.props.onExited(e)},t.resolveArguments=function(e,r){return t.props.nodeRef?[t.props.nodeRef.current,e]:[e,r]},t.getClassNames=function(e){var r=t.props.classNames,i="string"==typeof r,n=i&&r?r+"-":"",s=i?""+n+e:r[e],a=i?s+"-active":r[e+"Active"],o=i?s+"-done":r[e+"Done"];return{baseClassName:s,activeClassName:a,doneClassName:o}},t}(0,i.default)(s,e);var c=s.prototype;return c.addClass=function(e,t,r){var i,s=this.getClassNames(t)[r+"ClassName"],a=this.getClassNames("enter").doneClassName;"appear"===t&&"done"===r&&a&&(s+=" "+a),"active"===r&&e&&(0,l.forceReflow)(e),s&&(this.appliedClasses[t][r]=s,i=s,e&&i&&i.split(" ").forEach(function(t){return(0,n.default)(e,t)}))},c.removeClasses=function(e,t){var r=this.appliedClasses[t],i=r.base,n=r.active,s=r.done;this.appliedClasses[t]={},i&&u(e,i),n&&u(e,n),s&&u(e,s)},c.render=function(){var e=this.props,i=(e.classNames,(0,r.default)(e,["classNames"]));return a.default.createElement(o.default,(0,t.default)({},i,{onEnter:this.onEnter,onEntered:this.onEntered,onEntering:this.onEntering,onExit:this.onExit,onExiting:this.onExiting,onExited:this.onExited}))},s}(a.default.Component);c.defaultProps={classNames:""},c.propTypes={},e.s(["CSSTransition",0,c],135581)},535414,e=>{"use strict";function t(e,t,r,i){var n,s=!1,a=0;function o(){n&&clearTimeout(n)}function l(){for(var l=arguments.length,u=Array(l),c=0;c<l;c++)u[c]=arguments[c];var d=this,h=Date.now()-a;function f(){a=Date.now(),r.apply(d,u)}s||(i&&!n&&f(),o(),void 0===i&&h>e?f():!0!==t&&(n=setTimeout(i?function(){n=void 0}:f,void 0===i?e-h:e)))}return"boolean"!=typeof t&&(i=r,r=t,t=void 0),l.cancel=function(){o(),s=!0},l}e.s(["debounce",0,function(e,r,i){return void 0===i?t(e,r,!1):t(e,i,!1!==r)},"throttle",0,t])},442217,e=>{"use strict";var t=e.i(843476),r=e.i(271645),i=e.i(997053),n=e.i(581949),s=e.i(417734),a=e.i(456780),o=e.i(94332);let l=i.default.div.withConfig({displayName:"SearchInput__Wrapper",componentId:"sc-a908cc2b-0"})` 105 display: flex; 106 flex-direction: row; 107 width: 100%; 108 /* max-width: 980px; */ 109 position: relative; 110`,u=i.default.input.withConfig({displayName:"SearchInput__InputStyled",componentId:"sc-a908cc2b-1"})` 111 flex-grow: 1; 112 border-bottom: 1px solid ${e=>e.theme.color.gold}; 113 border-right: 1px solid ${e=>e.theme.color.gold}; 114 padding: 8px 32px; 115 position: relative; 116 font-size: ${e=>e.theme.fz.md}; 117 font-weight: 700; 118 /* color: ${e=>e.theme.color.gold}; */ 119 outline: none; 120 line-height: 1; 121 width: 100%; 122 123 ${o.mq.sm} { 124 font-size: ${e=>e.theme.fz.xl}; 125 padding: 24px 32px; 126 } 127 128 &::placeholder { 129 color: #6d7487; 130 } 131`;e.s(["SearchInput",0,({innerRef:e,setResults:i,setAllEvents:o,setLoa
131ding:c,setHasText:d})=>{let[h,f]=(0,r.useState)(""),p=(0,r.useContext)(s.AppContext),g=!1;return(0,r.useEffect)(()=>{async function e(){d(h.length>0);try{if(h.length>0){c(!0);let e=await n.default.post("/api/search",{data:{locale:p.locale||"cs",text:h?.toLowerCase()||""}});c(!1),i(e.data.res.results),o(e.data.res.allEvents)}else i([]),o([])}catch(e){console.log(e)}}clearTimeout(g),g=setTimeout(()=>e(),300)},[h]),(0,t.jsx)(l,{children:(0,t.jsx)(u,{type:"text",value:h,placeholder:p.mainMenu?.searchText||"","aria-label":p.mainMenu?.searchText||(0,a.getAccessibilityLabel)("search",p.locale||"cs"),onKeyPress:()=>{clearTimeout(g)},onChange:e=>f(e.target.value),ref:e})})},"Wrapper",0,l])},388835,985254,237414,e=>{"use strict";var t=e.i(843476),r=e.i(271645),i=e.i(997053),n=e.i(4154),s=e.i(94332),a=e.i(456780);let o=i.default.div.withConfig({displayName:"Input__Container",componentId:"sc-406ee276-0"})` 132 position: relative; 133 z-index: 1; 134 margin-bottom: ${e=>e.isRadio||e.isCheckbox?"0":"55px"}; 135 margin-top: 20px; 136 ${e=>e.maxWidth&&`max-width: ${e.maxWidth};`} 137 138 ${s.mq.lg} { 139 margin-bottom: ${e=>e.isRadio||e.isCheckbox?"0":"55px"}; 140 } 141`,l=(0,i.default)(n.Icon).withConfig({displayName:"Input__StyledCheckIcon",componentId:"sc-406ee276-1"})` 142 width: 16px; 143`,u=i.default.span.withConfig({displayName:"Input__RequiredText",componentId:"sc-406ee276-2"})` 144 position: absolute; 145 top: 0; 146 right: 0; 147 z-index: 1; 148 pointer-events: none; 149 color: #000; 150 text-align: right; 151 font-family: var(--font-din); 152 font-size: ${e=>e.theme.fz.xxs}; 153 font-style: normal; 154 font-weight: 400; 155 line-height: 16px; 156 transform: translateY(-18px); 157`,c=i.default.label.withConfig({displayName:"Input__Label",componentId:"sc-406ee276-3"})` 158 font-size: ${e=>e.theme.fz.xs}; 159 line-height: 1.5; 160 color: ${e=>e.error?e.theme.color.error:e.theme.color.black}; 161 position: absolute; 162 left: 0; 163 top: 0; 164 z-index: 1; 165 display: flex; 166 transform: translateY(5px); 167 transition: all 0.25s ease; 168 ${({icon:e})=>e&&i.css` 169 left: 32px; 170 `} 171 ${({isEmpty:e})=>!e&&i.css` 172 color: ${e=>e.theme.color.gold}; 173 font-size: ${e=>e.theme.fz.xs}; 174 line-height: 1.3; 175 transform: translateY(-18px); 176 left: 0; 177 `} 178 ${e=>e.isRadio&&i.css` 179 position: relative; 180 padding-left: ${e.theme.gap.lg}; 181 font-size: ${e.theme.fz.xs}; 182 color: #000; 183 cursor: pointer; 184 185 &:before { 186 content: ''; 187 display: block; 188 width: 24px; 189 height: 24px; 190 border: 1px solid; 191 border-color: ${e.theme.color.gold}; 192 ${e.isActive&&`background-color: ${e.theme.color.gold}`}; 193 border-radius: 50%; 194 position: absolute; 195 top: 50%; 196 left: 0; 197 transform: translateY(calc(-50% - 2px)); 198 } 199 200 &:after { 201 content: ''; 202 display: block; 203 width: 8px; 204 height: 8px; 205 border: 1px solid ${e.theme.color.white}; 206 border-radius: 50%; 207 position: absolute; 208 top: 50%; 209 transform: translateY(calc(-50% - 2px)); 210 left: 8px; 211 opacity: ${e.isActive?"1":"0"}; 212 transition: opacity 0.2s; 213 } 214 `}; 215 216 ${e=>e.isCheckbox&&i.css` 217 position: relative; 218 padding-left: ${e.theme.gap.lg}; 219 font-size: ${e.theme.fz.xs}; 220 color: #000; 221 cursor: pointer; 222 223 ${l} { 224 position: absolute; 225 top: 9px; 226 left: 7px; 227 width: 12px; 228 color: ${e.theme.color.gold}; 229 ${e.isActive?"opacity: 1; color: #fff;":"opacity: 0;"}; 230 } 231 232 &:before { 233 content: ''; 234 display: block; 235 width: 24px; 236 height: 24px; 237 border: 1px solid; 238 border-color: ${e.theme.color.gold}; 239 ${e.isActive&&`background-color: ${e.theme.color.gold}`}; 240 border-radius: 50%; 241 position: absolute; 242 top: 14px; 243 left: 0; 244 transform: translateY(calc(-50% - 2px)); 245 transition: color 0.2s; 246 } 247 `}; 248`,d=i.default.input.withConfig({displayName:"Input__InputStyled",componentId:"sc-406ee276-4"})` 249 background: transparent; 250 line-height: 32px; 251 border-bottom: 1px solid ${e=>e.error?e.theme.color.error:e.theme.color.gold}; 252 display: block; 253 width: 100%; 254 outline: none; 255 256 html[data-keyboard-focus='true'] &:focus { 257 outline: 1px dashed ${({theme:e})=>e.color.gold}; 258 outline-offset: 2px; 259 } 260 ${({icon:e})=>e&&"padding-left: 32px"}; 261 ${({type:e})=>"radio"===e&&i.css` 262 position: absolute; 263 width: 0; 264 height: 0; 265 visibility: hidden; 266 `}; 267 ${({type:e})=>"checkbox"===e&&i.css` 268 position: absolute; 269 width: 0; 270 height: 0; 271 visibility: hidden; 272 `}; 273 274 ${({checked:e})=>e&&i.css` 275 position: absolute; 276 width: 0; 277 height: 0; 278 visibility: hidden; 279 `}; 280`,h=i.default.p.withConfig({displayName:"Input__Error",componentId:"sc-406ee276-5"})` 281 color: ${e=>e.theme.color.error}; 282 font-size: ${e=>e.theme.fz.xs}; 283 line-height: 1.3; 284 position: absolute; 285 bottom: -7px; 286 left: 0; 287 transform: translateY(100%); 288`,f=i.css` 289 color: ${e=>e.theme.color.gold}; 290 width: 16px; 291 height: 16px; 292`,p=(0,i.default)(n.Icon).withConfig({displayName:"Input__IconStyled",componentId:"sc-406ee276-6"})` 293 ${f}; 294 position: absolute !important; 295 top: 6px; 296 left: 0; 297 z-index: -1; 298`,g=(0,i.default)(n.Icon).withConfig({displayName:"Input__ViewIcon",componentId:"sc-406ee276-7"})` 299 ${f}; 300`,m=i.default.button.withConfig({displayName:"Input__ShowPasswordIcon",componentId:"sc-406ee276-8"})` 301 position: absolute; 302 top: 6px; 303 right: 0; 304 width: 16px; 305 height: 16px; 306 padding: 0; 307 background: transparent; 308 outline: none; 309 310 &:focus-visible { 311 outline: 1px dashed ${({theme:e})=>e.color.gold}; 312 outline-offset: 2px; 313 } 314`;e.s(["Input",0,({field:e,form:{errors:i,touched:n},label:s,icon:f,type:y,id:v,checked:b,maxWidth:_,onClick:E,...S})=>{let[x,T]=(0,r.useState)(!1),w=(0,r.useId)(),A=!!f&&f.length>0,R=!!i[e.name]&&!!n[e.name],I="password"===y,k=v||e?.name||w,C=`${k}-error`,D=S.ariaLabel||("string"==typeof s?s:void 0)||k,L=String(S.locale||"cs").toLowerCase(),O=S.requiredLabel??(L.startsWith("en")?"Required":"Povinné");return(0,t.jsxs)(o,{isRadio:"radio"===y,isCheckbox:"checkbox"===y,maxWidth:_,onClick:E,children:[s&&(0,t.jsxs)(c,{isEmpty:e.value&&0===e.value.length,icon:A,error:R,htmlFor:k,isRadio:"radio"===y,isCheckbox:"checkbox"===y,isActive:b,children:["checkbox"===y&&(0,t.jsx)(l,{name:"check"}),s]}),S.required&&"radio"!==y&&"checkbox"!==y&&(0,t.jsx)(u,{children:O}),f&&(0,t.jsx)(p,{name:f}),I&&(0,t.jsx)(m,{onClick:()=>T(!x),type:"button","aria-label":x?(0,a.getAccessibilityLabel)("hide_password",L):(0,a.getAccessibilityLabel)("show_password",L),"aria-pressed":x,children:(0,t.jsx)(g,{name:x?"hide":"view"})}),(0,t.jsx)(d,{...e,...S,type:I&&x?"text":y,icon:A,error:R,checked:b,id:k,"aria-label":D,"aria-describedby":R?C:void 0,"aria-invalid":R||void 0}),R&&(0,t.jsx)(h,{id:C,children:String(i[e.name])})]})}],985254);let y=i.default.div.withConfig({displayName:"Textarea__Container",componentId:"sc-60adb9
314c3-0"})` 315 position: relative; 316 z-index: 1; 317 margin-bottom: 55px; 318 margin-top: 20px; 319`,v=i.default.label.withConfig({displayName:"Textarea__Label",componentId:"sc-60adb9c3-1"})` 320 font-size: ${e=>e.theme.fz.xs}; 321 line-height: 1.5; 322 color: ${e=>e.error?e.theme.color.error:e.theme.color.black}; 323 position: absolute; 324 left: 0; 325 top: 0; 326 z-index: 1; 327 transform: translateY(5px); 328 transition: all 0.25s ease; 329 ${({icon:e})=>e&&i.css` 330 left: 32px; 331 `} 332 ${({isEmpty:e})=>!e&&i.css` 333 color: ${e=>e.theme.color.gold}; 334 font-size: ${e=>e.theme.fz.xs}; 335 line-height: 1.3; 336 transform: translateY(-15px); 337 left: 0; 338 `} 339`,b=i.default.textarea.withConfig({displayName:"Textarea__TextareaStyled",componentId:"sc-60adb9c3-2"})` 340 background: transparent; 341 line-height: 1.3; 342 border: none; 343 border-bottom: 1px solid ${e=>e.error?e.theme.color.error:e.theme.color.gold}; 344 display: block; 345 width: 100%; 346 outline: none; 347 padding: ${e=>e.theme.gap.xs} 0; 348 ${({icon:e})=>e&&"padding-left: 32px"}; 349 height: 53px; 350`,_=i.default.p.withConfig({displayName:"Textarea__Error",componentId:"sc-60adb9c3-3"})` 351 color: ${e=>e.theme.color.error}; 352 font-size: ${e=>e.theme.fz.xxs}; 353 line-height: 1.3; 354 position: absolute; 355 bottom: -7px; 356 left: 0; 357 transform: translateY(100%); 358`,E=i.css` 359 color: ${e=>e.theme.color.gold}; 360 width: 16px; 361 height: 16px; 362`,S=(0,i.default)(n.Icon).withConfig({displayName:"Textarea__IconStyled",componentId:"sc-60adb9c3-4"})` 363 ${E}; 364 position: absolute !important; 365 top: 6px; 366 left: 0; 367 z-index: -1; 368`;e.s(["Textarea",0,({field:e,form:{errors:i,touched:n},label:s,icon:a,id:o,...l})=>{let u=!!a&&a.length>0,c=!!i[e.name]&&!!n[e.name],d=r.default.useRef(null);return(0,t.jsxs)(y,{children:[s&&(0,t.jsx)(v,{isEmpty:e.value&&0===e.value.length,icon:u,error:c,htmlFor:o,children:s}),a&&(0,t.jsx)(S,{name:a}),(0,t.jsx)(b,{ref:d,...e,...l,icon:u,error:c,id:o,onChange:function(t){d&&d.current&&(d.current.style.height=d.current.scrollHeight+1+"px"),e.onChange(t)}}),c&&(0,t.jsx)(_,{children:String(i[e.name])})]})}],237414),e.i(442217),e.s([],388835)},775268,e=>{"use strict";var t=e.i(843476),r=e.i(997053),i=e.i(728016);let n=r.css` 369 color: #fff; 370 background: #000; 371`,s=r.css` 372 color: #000; 373 background: #fff; 374`,a=r.default.div.withConfig({displayName:"Tag__Wrapper",componentId:"sc-b1d4d6fa-0"})` 375 display: inline-block; 376 flex-grow: 0; 377 ${e=>!e.noSelfAlign&&"align-self: flex-start"}; 378 padding: 4px 12px; 379 border: ${e=>"black"===e.color?0:"1px solid #000"}; 380 font-size: ${e=>e.theme.fz.xxs}; 381 line-height: 1; 382 ${({color:e})=>"black"===e?n:s}; 383 ${e=>e.marginBottom&&"margin-bottom: 16px;"} 384 ${e=>e.marginBottomSmall&&"margin-bottom: 8px;"} 385`;e.s(["Tag",0,({children:e,className:r,...n})=>(0,t.jsx)(a,{className:r,...n,children:"string"==typeof e?(0,i.nbsp)(e):e})])},816889,e=>{"use strict";var t=e.i(843476),r=e.i(271645),i=e.i(997053),n=e.i(4154),s=e.i(417734),a=e.i(456780);let o=i.default.button.withConfig({displayName:"Arrow__Wrapper",componentId:"sc-6e3cd173-0"})` 386 display: inline-flex; 387 justify-content: center; 388 align-items: center; 389 bottom: 30px; 390 cursor: pointer; 391 color: ${e=>e.theme.color.gold}; 392 background: transparent; 393 border: 0; 394 padding: 0; 395 396 ${({direction:e})=>"right"===e&&"right: 0"}; 397 ${({direction:e})=>"left"===e&&"left: 0"}; 398 399 &:disabled { 400 cursor: not-allowed; 401 } 402`;e.s(["Arrow",0,({direction:e,className:i,onClick:l,disabled:u,ariaLabel:c})=>{let{locale:d}=(0,r.useContext)(s.AppContext),h=(0,a.getAccessibilityLabel)("left"===e?"prev":"next",d);return(0,t.jsx)(o,{type:"button",className:i,onClick:l,direction:e,disabled:u,"aria-label":c||h,children:"left"===e&&(0,t.jsx)(n.Icon,{width:"24",name:"arrow-left"})||"right"===e&&(0,t.jsx)(n.Icon,{width:"24",name:"arrow-right"})})}])},595842,e=>{"use strict";var t=e.i(843476),r=e.i(271645),i=e.i(997053),n=e.i(816889),s=e.i(94332),a=e.i(417734),o=e.i(456780);let l=(0,i.default)(n.Arrow).withConfig({displayName:"SlickArrow__Wrapper",componentId:"sc-77a32fa9-0"})` 403 display: flex; 404 width: 112px; 405 height: 48px; 406 color: #fff; 407 background: ${e=>e.theme.color.gold}; 408 cursor: ${e=>e.disabled?"not-allowed":"pointer"}; 409 pointer-events: ${e=>e.disabled?"none":"all"}; 410 opacity: ${e=>e.disabled?.15:1}; 411 transition: opacity 300ms; 412 413 ${s.mq.sm} { 414 bottom: 0; 415 transform: translateY(0); 416 } 417`,u=({direction:e,className:i,onClick:n,disabled:s,ariaLabel:u})=>{let{locale:c}=(0,r.useContext)(a.AppContext),d=(0,o.getAccessibilityLabel)("left"===e?"prev":"next",c);return(0,t.jsx)(l,{direction:e,className:i,disabled:s,onClick:n,ariaLabel:u||d})},c=i.default.div.withConfig({displayName:"SliderButtons__Wrapper",componentId:"sc-12ea6c04-0"})` 418 display: flex; 419 justify-content: space-between; 420 flex-grow: 1; 421`,d=({prevClick:e,nextClick:r,prevDisabled:i,nextDisabled:n})=>(0,t.jsxs)(c,{children:[(0,t.jsx)(u,{direction:"left",disabled:i,onClick:e}),(0,t.jsx)(u,{direction:"right",disabled:n,onClick:r})]}),h=i.default.div.withConfig({displayName:"Slider__Wrapper",componentId:"sc-c56d199-0"})` 422 width: calc(100% + calc(100vw * 0.0625) + 16px); 423 overflow-x: scroll; 424 -ms-overflow-style: none; 425 overflow: -moz-scrollbars-none; 426 margin-bottom: ${({marginToButtons:e,theme:t})=>e?t.gap.sm:0}; 427 428 ${s.mq.sm} { 429 width: calc(100% + calc(100vw * 0.0625) + 24px); 430 margin-bottom: ${({marginToButtons:e,theme:t})=>e?t.gap.lg:0}; 431 } 432 433 ${s.mq.lg} { 434 width: calc(100% + calc(100vw * 0.0625) + 24px); 435 margin-bottom: ${({marginToButtons:e,marginToButtonsSmall:t,theme:r})=>t?r.gap.lg:e?r.gap.xl:0}; 436 } 437 438 &::-webkit-scrollbar {
439 width: 0 !important; 440 } 441 scrollbar-width: none; 442`,f=i.default.div.withConfig({displayName:"Slider__Content",componentId:"sc-c56d199-1"})` 443 display: flex; 444 445 & > *:last-child { 446 min-width: calc(100% - 1px); 447 } 448`,p=r.default.forwardRef((e,i)=>{let{children:n,prevCallback:s,nextCallback:a,className:o}=e,[l,u]=(0,r.useState)(!1),[c,p]=(0,r.useState)(!0),g=(0,r.useRef)(null),m=()=>{i&&i.current&&(p(0===i.current.scrollLeft),u(i.current.scrollLeft+i.current.offsetWidth===i.current.scrollWidth))};return(0,r.useEffect)(()=>{if(i&&i.current)return i?.current.addEventListener("scroll",m),window.addEventListener("resize",m),()=>{i?.current&&i?.current.removeEventListener("scroll",m),window.addEventListener("resize",m)}},[]),(0,r.useEffect)(()=>{m()}),(0,t.jsxs)(t.Fragment,{children:[(0,t.jsx)(h,{ref:i,className:o,marginToButtons:e.marginToButtons,marginToButtonsSmall:e.marginToButtonsSmall,children:(0,t.jsx)(f,{ref:g,children:n})}),!(l&&c&&i&&i.current)&&(0,t.jsx)(d,{prevClick:()=>{s&&s(),i.current.scrollBy({top:0,left:i.current?-(.9*i.current?.getBoundingClientRect().width):0,behavior:"smooth"})},prevDisabled:c,nextClick:()=>{a&&a(),i.current.scrollBy({top:0,left:i.current?i.current?.getBoundingClientRect().width*.9:0,behavior:"smooth"})},nextDisabled:l})]})});e.s(["Slider",0,p],595842)},568549,808592,491709,e=>{"use strict";e.i(247167);var t=e.i(843476),r=e.i(271645),i=e.i(997053),n=e.i(417734),s=e.i(408717),a=e.i(822315);function o(e,t=!1){if(e.saleSuspended||e.isFree||e.isFreeWithTicket||e.isCanceled||e.isEntered||"string"==typeof e.startAt&&(0,a.default)(e.startAt).isBefore((0,a.default)()))return!1;if("string"==typeof e.sellFrom){let t=(0,a.default)(e.sellFrom),r=(0,s.getPrioritySaleShift)();if((!0===e.prioritySaleInclusion?t.subtract(r,"days"):t).isAfter((0,a.default)()))return!1}return!!e.ticketsUrl||(t?!!e.colosseumPrdid&&0===Number(e.ticketsAvailable):!!e.colosseumPrdid&&Number(e.ticketsAvailable)>0)}e.s(["isSellable",0,o],808592);var l=e.i(877253),u=e.i(372907),c=e.i(4154),d=e.i(542185);let h=(0,i.default)(l.Button).withConfig({displayName:"BuyButton__StyledButton",componentId:"sc-708c3a29-0"})` 449 width: 100%; 450 margin-top: 24px; 451 white-space: nowrap; 452`,f=i.default.div.withConfig({displayName:"BuyButton__WatchDog",componentId:"sc-708c3a29-1"})` 453 display: flex; 454 justify-items: baseline; 455 span { 456 margin-left: 10px; 457 } 458`,p=(0,i.default)(l.Button).withConfig({displayName:"BuyButton__IconLink",componentId:"sc-708c3a29-2"})` 459 border: none; 460 margin-top: 4px; 461 button, 462 a { 463 display: flex; 464 justify-content: flex-start !important; 465 padding: 0 !important; 466 width: 100%; 467 align-items: center; 468 height: 100%; 469 } 470 display: flex; 471 justify-items: baseline; 472 color: ${e=>e.theme.color.gold}; 473 span { 474 margin-left: 10px; 475 } 476`,g=(0,i.default)(p).withConfig({displayName:"BuyButton__WatchDogIconLink",componentId:"sc-708c3a29-3"})` 477 margin-top: 24px; 478`,m=(0,i.default)(c.Icon).withConfig({displayName:"BuyButton__StyledIcon",componentId:"sc-708c3a29-4"})` 479 margin-right: 16px; 480 height: 100%; 481`;e.s(["BuyButton",0,({event:e,className:i,showChooseButton:s=!0,showWatchDog:l=!0,withTime:y=!1,secureId:v,quickBuy:b=!1,quickBuyText:_,totalTicketsAvailable:E})=>{let{locale:S,currentUri:x,productionPage:T,textBuyTickets:w,textWatchDog:A,textWatchFor:R,textBookTickets:I,textChooseDifferentTime:k}=(0,r.useContext)(n.AppContext),C=r.default.createRef(),D="en"===S?"en-GB":"cs-CZ",L=l&&!e.production?.groupbook&&!e.production?.showInNdplusCalendar&&!e.production?.showInTourCalendar,O=(0,r.useMemo)(()=>e.production?.groupbook?"https://groupbook.colosseum.eu/cart/ScheduledTourSingle":`${u.COLOSSEUM_BASEURL}${!e.startAt&&e.production?.colosseumTourTprid?"ticketsnonnumberedadd":"hall"}`,[e]),P=e=>{if(!e)return"00:00";try{return(0,d.formatDate)(e).format("HH:mm")}catch(r){let t=String(e).match(/T(\d{2}:\d{2}):\d{2}/);return t?t[1]:"00:00"}};if(e?.startAt&&(0,d.formatDate)(e.startAt),(o(e)||b)&&w&&I&&R)if(e.ticketsUrl)return(0,t.jsx)(h,{href:e.ticketsUrl,type:"gold",className:i,children:e.isFree?I:w});else{let r,n;if(e.production?.groupbook){let r,n,s;return(0,t.jsxs)("form",{ref:C,method:"post",action:O,onSubmit:(r=String(e.colosseumPrdid),async e=>{let t=e.target;fetch(`/api/groupbook/${r}`).then(e=>e.text()).then(e=>{"OK"===e?fetch(`/api/groupbook/reservation/${r}`).finally(()=>{t.submit()}):alert("en"===S?"Someone else is booking this event at the moment, please try again in 10 minutes.":"Na této akci právÄ provádà rezervaci nÄkdo jiný, zkuste to prosÃm za 10 minut.")}).catch(()=>{alert("en"===S?"Failed to verify booking availability.":"NepodaÅilo se ovÄÅit dostupnost rezervace.")}),e.preventDefault()}),children:[(0,t.jsx)("input",{type:"hidden",name:"mrsid",value:u.COLOSSEUM_MRSID}),!e.startAt&&e.production?.colosseumTourTprid?(0,t.jsx)("input",{type:"hidden",name:"titleid",value:e.production.colosseumTourTprid}):(0,t.jsx)("input",{type:"hidden",name:"eventid",value:String(e.colosseumPrdid)}),(0,t.jsx)("input",{type:"hidden",name:"successredirect",value:x}),(0,t.jsx)("input",{type:"hidden",name:"failedredirect",value:x}),(0,t.jsx)("input",{type:"hidden",name:"redirectaddtickets",value:x}),(0,t.jsx)("input",{type:"hidden",name:"pricecatid",value:""}),(0,t.jsx)("input",{type:"hidden",name:"language",value:D}
481),(0,t.jsx)(h,{type:"gold",className:i,submit:!0,children:b?_||R:e.isFree?I:w+(y&&e?.startAt?("en"===S?" for ":" na ")+(n=(0,d.formatDate)(e.startAt),s=P(e.startAt),a.default.tz(n,"Europe/Prague"),"en"===S?`${n.format("D/M/YYYY")}, ${s}`:`${n.format("D. M. YYYY")}, ${s}`):"")})]})}return(0,t.jsxs)("form",{ref:C,method:"post",action:O,onSubmit:b&&v?async e=>{let t=e.target,r=(()=>{let{userAgent:e,language:t,languages:r,platform:i,hardwareConcurrency:n,deviceMemory:s}=window.navigator,a=Object.entries(window.navigator.plugins).map(([,e])=>e.name),{colorDepth:o,availWidth:l,availHeight:u}=window.screen,c=new Date().getTimezoneOffset();return(e=>{let t=3&e.length,r=e.length-t,i=0,n,s;for(let t=0;t<r;t++)s=255&e.charCodeAt(t)|(255&e.charCodeAt(++t))<<8|(255&e.charCodeAt(++t))<<16|(255&e.charCodeAt(++t))<<24,++t,i^=s=(65535&(s=(s=(65535&s)*0xcc9e2d51+(((s>>>16)*0xcc9e2d51&65535)<<16)|0)<<15|s>>>17))*0x1b873593+(((s>>>16)*0x1b873593&65535)<<16)|0,i=(65535&(n=(65535&(i=i<<13|i>>>19))*5+(((i>>>16)*5&65535)<<16)|0))+27492+(((n>>>16)+58964&65535)<<16);let a=r-1;switch(s=0,t){case 3:s^=(255&e.charCodeAt(a+2))<<16;break;case 2:s^=(255&e.charCodeAt(a+1))<<8;break;case 1:s^=255&e.charCodeAt(a)}return i^=s=(65535&(s=(s=(65535&s)*0xcc9e2d51+(((s>>>16)*0xcc9e2d51&65535)<<16)|0)<<15|s>>>17))*0x1b873593+(((s>>>16)*0x1b873593&65535)<<16)|0,i^=e.length,i^=i>>>16,i=(65535&i)*0x85ebca6b+(((i>>>16)*0x85ebca6b&65535)<<16)|0,i^=i>>>13,i=(65535&i)*0xc2b2ae35+(((i>>>16)*0xc2b2ae35&65535)<<16)|0,(i^=i>>>16)>>>0})(JSON.stringify({userAgent:e,language:t,languages:r,platform:i,hardwareConcurrency:n,deviceMemory:s,plugins:a,colorDepth:o,availWidth:l,availHeight:u,timezoneOffset:c,timezone:new Intl.DateTimeFormat().resolvedOptions().timeZone,touchSupport:"ontouchstart"in window,canvas:(()=>{try{let e=document.createElement("canvas"),t=e.getContext("2d");return t&&(t.textBaseline="top",t.font="14px 'Arial'",t.textBaseline="alphabetic",t.fillStyle="#f60",t.fillRect(125,1,62,20),t.fillStyle="#069",t.fillText("abcdefghijklmnopqrstuvwxyzABCDEFGHIJKLMNOPQRSTUVWXYZ`~1!2@3#4$5%6^7&8*9(0)-_=+[{]}|;:',<.>/?",2,15),t.fillStyle="rgba(102, 204, 0, 0.7)",t.fillText("abcdefghijklmnopqrstuvwxyzABCDEFGHIJKLMNOPQRSTUVWXYZ`~1!2@3#4$5%6^7&8*9(0)-_=+[{]}|;:',<.>/?",4,17)),e.toDataURL()}catch(e){return""}})()}))})(),i=new URL(x||"");i.protocol,fetch("/api/security/request?fp="+r+"&id="+v).then(e=>e.json()).then(e=>{if("OK"===e.status&&e.token){let r=t.querySelector("[name=successredirect]");r?r.value=`${i.protocol}//${i.hostname}/api/security/confirm?token=${e.token}&locale=${S}`:alert("rychly nakup nebude fungovat")}else alert("rychly nakup nebude fungovat");t.submit()}),e.preventDefault()}:()=>!0,children:[(0,t.jsx)("input",{type:"hidden",name:"mrsid",value:b?u.COLOSSEUM_QUICKBUY_MRSID:u.COLOSSEUM_MRSID}),!e.startAt&&e.production?.colosseumTourTprid?(0,t.jsx)("input",{type:"hidden",name:"titleid",value:e.production.colosseumTourTprid}):(0,t.jsx)("input",{type:"hidden",name:"eventid",value:String(e.colosseumPrdid)}),(0,t.jsx)("input",{type:"hidden",name:"successredirect",value:x}),(0,t.jsx)("input",{type:"hidden",name:"failedredirect",value:x}),(0,t.jsx)("input",{type:"hidden",name:"redirectaddtickets",value:x}),(0,t.jsx)("input",{type:"hidden",name:"language",value:D}),(0,t.jsx)(h,{type:"gold",className:i,submit:!0,children:b?_||R:e.isFree?I:w+(y&&e?.startAt?("en"===S?" for ":" na ")+(r=(0,d.formatDate)(e.startAt),n=P(e.startAt),a.default.tz(r,"Europe/Prague"),"en"===S?`${r.format("D/M/YYYY")}, ${n}`:`${r.format("D. M. YYYY")}, ${n}`):"")})]})}return e.production&&k&&s&&!e.isFree&&!e.isFreeWithTicket?(0,t.jsxs)(t.Fragment,{children:[!E||E>0&&(0,t.jsx)(t.Fragment,{children:e?.production?.groupbook?(0,t.jsx)(h,{page:T,params:{slug:e.production.slug+"-"+e.production.id},hash:"tickets",className:i,children:k}):(0,t.jsxs)(p,{className:i,page:T,params:{slug:e.production.slug+"-"+e.production.id},hash:"tickets",simple:!0,children:[(0,t.jsx)(m,{name:"calendar",width:"16",height:"16"}),(0,t.jsx)("span",{children:k})]})}),(0===E&&"string"==typeof e.startAt&&(0,a.default)(e.startAt).isSameOrAfter((0,a.default)())||o(e,!0))&&A&&L&&(0,t.jsxs)("form",{ref:C,method:"post",action:O,onSubmit:()=>!0,children:[(0,t.jsx)("input",{type:"hidden",name:"mrsid",value:u.COLOSSEUM_MRSID}),!e.startAt&&e.production?.colosseumTourTprid?(0,t.jsx)("input",{type:"hidden",name:"titleid",value:e.production.colosseumTourTprid}):(0,t.jsx)("input",{type:"hidden",name:"eventid",value:String(e.colosseumPrdid)}),(0,t.jsx)("input",{type:"hidden",name:"successredirect",value:x}),(0,t.jsx)("input",{type:"hidden",name:"failedredirect",value:x}),(0,t.jsx)("input",{type:"hidden",name:"redirectaddtickets",value:x}),(0,t.jsx)("input",{type:"hidden",name:"language",value:D}
481),(0,t.jsxs)(g,{submit:!0,className:i,simple:!0,children:[(0,t.jsx)(m,{name:"paw",width:"16",height:"16"}),(0,t.jsx)("span",{children:A})]})]})]}):o(e,!0)&&A&&L?(0,t.jsxs)("form",{ref:C,method:"post",action:O,onSubmit:()=>!0,children:[(0,t.jsx)("input",{type:"hidden",name:"mrsid",value:u.COLOSSEUM_MRSID}),!e.startAt&&e.production?.colosseumTourTprid?(0,t.jsx)("input",{type:"hidden",name:"titleid",value:e.production.colosseumTourTprid}):(0,t.jsx)("input",{type:"hidden",name:"eventid",value:String(e.colosseumPrdid)}),(0,t.jsx)("input",{type:"hidden",name:"successredirect",value:x}),(0,t.jsx)("input",{type:"hidden",name:"failedredirect",value:x}),(0,t.jsx)("input",{type:"hidden",name:"redirectaddtickets",value:x}),(0,t.jsx)("input",{type:"hidden",name:"language",value:D}),(0,t.jsx)(h,{type:"transparent",className:i,submit:!0,children:(0,t.jsxs)(f,{children:[(0,t.jsx)(c.Icon,{name:"paw",width:"20",height:"20"}),(0,t.jsx)("span",{children:A})]})})]}):null}],568549),e.s(["resolveTicketsAmount",0,(e,t,r=!1)=>{if(0===e)return t.textSoldOut;if(e>0&&e<=15&&!r){let r=t.textLastAmount?.replace("{amount}",String(e))||"";return 1===e&&(r=(r=(r=r.replace("PoslednÃch","PoslednÃ")).replace("vstupenek","vstupenka")).replace("tickets","ticket")),e>=2&&e<=4&&(r=(r=r.replace("PoslednÃch","PoslednÃ")).replace("vstupenek","vstupenky")),r}return(!!(e>=16)||!!r)&&t.textTicketsAvailable}],491709)},257545,562640,501440,372438,e=>{"use strict";var t=e.i(997053),r=e.i(877253),i=e.i(94332),n=e.i(775268),s=e.i(4154);let a=t.default.div.withConfig({displayName:"styled__Wrapper",componentId:"sc-58d0cd9-0"})` 482 width: 100%; 483 position: relative; 484 485 ${e=>"extended"===e.type&&!e.homepage&&t.css` 486 margin-bottom: 72px; 487 `} 488 /* 489 ${e=>"simple"===e.type&&t.css` 490 .slick-slider { 491 padding-bottom: 72px !important; 492 } 493 `} */ 494 495 .searchProgrammeCarousel { 496 width: 100%; 497 } 498`;t.default.div.withConfig({displayName:"styled__ProgrammeItemWrapper",componentId:"sc-58d0cd9-1"})` 499 max-width: 216px; 500 padding: 40px; 501 position: relative; 502 outline: none; 503 border: 1px solid transparent; 504 ${e=>e.withDivider&&"padding-left: 51px"}; 505 ${e=>e.highlighted&&`border-color: ${e.theme.color.gold}`}; 506`,t.default.div.withConfig({displayName:"styled__Type",componentId:"sc-58d0cd9-2"})` 507 display: flex; 508 font-size: ${e=>e.theme.fz.xs}; 509`,t.default.div.withConfig({displayName:"styled__Venue",componentId:"sc-58d0cd9-3"})` 510 margin-left: 8px; 511 font-family: var(--font-din-serif); 512 color: ${e=>e.theme.color.gold}; 513`,t.default.div.withConfig({displayName:"styled__Location",componentId:"sc-58d0cd9-4"})` 514 display: flex; 515 margin: 16px 0; 516`;let o=(0,t.default)(n.Tag).withConfig({displayName:"styled__StyledTag",componentId:"sc-58d0cd9-5"})``;t.default.div.withConfig({displayName:"styled__Tags",componentId:"sc-58d0cd9-6"})` 517 display: flex; 518 margin-bottom: 32px; 519 520 ${o} + ${o} { 521 margin-left: 8px; 522 } 523`,t.default.p.withConfig({displayName:"styled__Tickets",componentId:"sc-58d0cd9-7"})` 524 margin-top: 8px; 525 font-size: ${e=>e.theme.fz.xxs}; 526`,(0,t.default)(s.Icon).withConfig({displayName:"styled__StyledIcon",componentId:"sc-58d0cd9-8"})` 527 width: 16px; 528 margin-right: 8px; 529`,t.default.div.withConfig({displayName:"styled__DateTags",componentId:"sc-58d0cd9-9"})` 530 display: flex; 531 flex-direction: column; 532`,(0,t.default)(n.Tag).withConfig({displayName:"styled__StyledDateTag",componentId:"sc-58d0cd9-10"})` 533 & + & { 534 margin-top: 8px; 535 } 536`,t.default.div.withConfig({displayName:"styled__SliderWrapper",componentId:"sc-58d0cd9-11"})` 537 width: calc(100% + 6.25% + 0px); 538 overflow-x: scroll; 539`,t.default.div.withConfig({displayName:"styled__Slider",componentId:"sc-58d0cd9-12"})` 540 display: flex; 541`;let l=t.default.div.withConfig({displayName:"styled__DayEvents",componentId:"sc-58d0cd9-13"})` 542 display: flex; 543 flex-shrink: 0; 544 position: relative; 545`,u=t.default.div.withConfig({displayName:"styled__DayDivider",componentId:"sc-58d0cd9-14"})` 546 width: 1px; 547 height: 112px; 548 border-left: 1px solid ${e=>e.theme.color.gold}; 549 padding-left: 15px; 550 position: absolute; 551 position: sticky; 552 left: 0; 553 top: 0; 554 font-family: var(--font-din-serif, serif); 555 color: ${e=>e.theme.color.gold}; 556 ${e=>!e.noCapitalize&&"text-transform: capitalize;"} 557 white-space: nowrap; 558 background: #fff; 559 560 span { 561 background: #fff; 562 } 563`,c=t.default.div.withConfig({displayName:"styled__ResultsGroup",componentId:"sc-58d0cd9-15"})` 564 display: flex; 565 flex-shrink: 0; 566 position: relative; 567`,d=t.default.div.withConfig({displayName:"styled__GoldenTileWrapper",componentId:"sc-58d0cd9-16"})` 568 padding: 1px; 569 margin-right: 2rem; 570`,h=(0,t.default)(r.Button).withConfig({displayName:"styled__GoldenTile",componentId:"sc-58d0cd9-17"})` 571 justify-content: center;
572 align-items: center; 573 width: 10rem; 574 height: calc(100% - 8.5rem); 575 margin-bottom: 1.3rem; 576 font-size: 1.75rem; 577 text-align: center; 578 line-height: 1; 579 580 ${i.mq.sm} { 581 width: 11.2rem; 582 } 583 584 span { 585 margin-top: 1rem; 586 font-size: 1rem; 587 } 588 589 a { 590 height: 100%; 591 display: flex; 592 flex-direction: column; 593 justify-content: center; 594 } 595`,f=(0,t.default)(r.Button).withConfig({displayName:"styled__TicketButton",componentId:"sc-58d0cd9-18"})` 596 font-size: 0.85rem; 597 598 ${i.mq.sm} { 599 font-size: 1rem; 600 } 601`;e.s(["DayDivider",0,u,"DayEvents",0,l,"GoldenTile",0,h,"GoldenTileWrapper",0,d,"ResultsGroup",0,c,"TicketButton",0,f,"Wrapper",0,a],257545);var p=e.i(843476),g=e.i(271645);t.default.div.withConfig({displayName:"styled__Wrapper",componentId:"sc-e3d61d74-0"})` 602 position: relative; 603 604 ${e=>"hero"===e.type&&t.css` 605 height: 608px; 606 607 .slick-slide { 608 padding-right: 300px; 609 box-sizing: border-box; 610 } 611 612 .slick-slider { 613 height: 100%; 614 position: relative; 615 } 616 617 .slick-dots { 618 display: flex !important; 619 flex-direction: column; 620 justify-content: space-between; 621 width: 300px; 622 height: 100%; 623 position: absolute; 624 top: 0; 625 right: 0; 626 } 627 `}; 628`,t.default.div.withConfig({displayName:"styled__HeroItem",componentId:"sc-e3d61d74-1"})` 629 display: block; 630 position: relative; 631 height: 600px; 632 outline: none; 633 634 img { 635 width: 100%; 636 height: auto; 637 } 638`,t.default.div.withConfig({displayName:"styled__HeroDescription",componentId:"sc-e3d61d74-2"})` 639 transition: all 500ms; 640 641 ${e=>e.isActive&&t.css` 642 width: 400px; 643 padding: 50px; 644 transform: translateX(-100px); 645 background: #fff; 646 `} 647`,t.default.span.withConfig({displayName:"styled__HeroText",componentId:"sc-e3d61d74-3"})` 648 display: block; 649 font-size: ${e=>e.theme.fz.xs}; 650 font-family: var(--font-din-serif); 651 line-height: 1.5; 652 text-align: right; 653`,t.default.div.withConfig({displayName:"styled__ProgrammeItemWrapper",componentId:"sc-e3d61d74-4"})` 654 max-width: 216px; 655 padding: 40px; 656 position: relative; 657 outline: none; 658 border: 1px solid transparent; 659 ${e=>e.withDivider&&"padding-left: 51px"}; 660 ${e=>e.highlighted&&`border-color: ${e.theme.color.gold}`}; 661`;let m=t.default.div.withConfig({displayName:"styled__FilterWrapper",componentId:"sc-e3d61d74-5"})` 662 display: flex; 663 flex-direction: column; 664 margin-bottom: 48px; 665`;t.default.div.withConfig({displayName:"styled__FilterMain",componentId:"sc-e3d61d74-6"})` 666 display: flex; 667 justify-content: space-between; 668 align-items: center; 669 margin-bottom: 60px; 670`;let y=t.default.ul.withConfig({displayName:"styled__FilterList",componentId:"sc-e3d61d74-7"})` 671 display: flex; 672 673 &[data-title]:before { 674 margin-right: 40px; 675 color: ${e=>e.theme.color.gold}; 676 font-family: var(--font-din-serif); 677 content: attr(data-title); 678 } 679`,v=t.default.li.withConfig({displayName:"styled__FilterItem",componentId:"sc-e3d61d74-8"})` 680 & + & { 681 margin-left: 40px; 682 } 683`,b=t.default.button.withConfig({displayName:"styled__FilterItemButton",componentId:"sc-e3d61d74-9"})` 684 border: none; 685 background: none; 686 padding: 0; 687 margin: 0; 688 font: inherit; 689 color: inherit; 690 cursor: pointer; 691 line-height: 1.5; 692 position: relative; 693 padding-bottom: 10px; 694 ${({disableCapitalize:e})=>!e&&"text-transform: capitalize;"} 695 font-family: var(--font-din-serif); 696 white-space: nowrap; 697 698 ${e=>e.isActive&&t.css` 699 color: ${e=>e.theme.color.gold}; 700 &:after { 701 display: block; 702 width: 100%; 703 height: 1px; 704 position: absolute; 705 left: 0; 706 bottom: 0; 707 background: ${e=>e.theme.color.gold}; 708 content: ''; 709 } 710 `} 711 712 @media not all and (pointer: coarse) { 713 &:hover { 714 color: ${e=>e.theme.color.gold}; 715 } 716 } 717 718 &:focus { 719 outline: none; 720 } 721 722 &:focus-visible { 723 font-weight: bold; 724 } 725`;t.default.div.withConfig({displayName:"styled__Type",componentId:"sc-e3d61d74-10"})` 726 display: flex; 727 font-size: ${e=>e.theme.fz.xs}; 728`,t.default.div.withConfig({displayName:"styled__Venue",componentId:"sc-e3d61d74-11"})` 729 margin-left: 8px; 730 font-family: var(--font-din-serif); 731 color: ${e=>e.theme.color.gold}; 732`,t.default.div.withConfig({displayName:"styled__Location",componentId:"sc-e3d61d74-12"})` 733 display: flex; 734 margin: 16px 0; 735`;let _=(0,t.default)(n.Tag).withConfig({displayName:"styled__StyledTag",componentId:"sc-e3d61d74-13"})``;t.default.div.withConfig({displayName:"styled__Tags",componentId:"sc-e3d61d74-14"})` 736 display: flex; 737 margin-bottom: 32px; 738 739 ${_} + ${_} { 740 margin-left: 8px; 741 } 742`,t.default.p.withConfig({displayName:"styled__Tickets",componentId:"sc-e3d61d74-15"})` 743 margin-top: 8px; 744 font-size: ${e=>e.theme.fz.xxs};
745`,t.default.div.withConfig({displayName:"styled__DayDivider",componentId:"sc-e3d61d74-16"})` 746 width: 1px; 747 height: 112px; 748 border-left: 1px solid ${e=>e.theme.color.gold}; 749 padding-left: 15px; 750 position: sticky; 751 left: 0; 752 top: -32px; 753 font-family: var(--font-din-serif); 754 color: ${e=>e.theme.color.gold}; 755`,(0,t.default)(s.Icon).withConfig({displayName:"styled__StyledIcon",componentId:"sc-e3d61d74-17"})` 756 width: 16px; 757 margin-right: 8px; 758`,t.default.div.withConfig({displayName:"styled__DateTags",componentId:"sc-e3d61d74-18"})` 759 display: flex; 760 flex-direction: column; 761`,(0,t.default)(n.Tag).withConfig({displayName:"styled__StyledDateTag",componentId:"sc-e3d61d74-19"})` 762 & + & { 763 margin-top: 8px; 764 } 765`;let E=t.default.div.withConfig({displayName:"styled__FilterHolder",componentId:"sc-e3d61d74-20"})` 766 display: flex; 767 flex-direction: row; 768 justify-content: space-between; 769 width: 100%; 770 overflow-x: auto; 771`;e.s(["FilterHolder",0,E,"FilterItem",0,v,"FilterItemButton",0,b,"FilterList",0,y,"FilterWrapper",0,m],562640);var S=e.i(705665),x=e.i(384843),T=e.i(728016),w=e.i(822315),A=e.i(4824),R=e.i(895751),I=e.i(372907),k=e.i(542185);w.default.extend(R.default),w.default.extend(A.default);let C=t.default.div.withConfig({displayName:"Filter__Top",componentId:"sc-a975433e-0"})` 772 width: 100%; 773 display: flex; 774 align-items: start; 775 flex-wrap: wrap; 776 justify-content: space-between; 777 778 ${({theme:e})=>t.css` 779 margin-bottom: ${e.gap.md}; 780 gap: ${e.gap.xs}; 781 `}; 782`;e.s(["Filter",0,({heading:e,data:t,sliderRef:r,seasons:i,groupBy:n="month",currentSlide:s,targetRefs:a,rightComponent:o,updateCurrent:l})=>{let[u,c]=(0,g.useState)(0),d=Array.from(t.keys()),h=(0,g.useContext)(x.LocaleContext),f=i&&i.length>1&&(0,w.default)().isSameOrAfter((0,w.default)(i[0].dateTo).subtract(30,"days"));return(0,p.jsxs)(m,{children:[(e||o)&&(0,p.jsxs)(C,{children:[e&&(0,p.jsx)(S.Heading,{tag:"h2",size:"xl",children:(0,T.nbsp)(e)}),o&&o]}),(0,p.jsxs)(E,{children:[d&&d.length>1&&(0,p.jsx)(y,{children:d.map((e,i)=>{let o,u,c;return(0,p.jsx)(v,{children:(0,p.jsx)(b,{type:"button","aria-pressed":s===i,isActive:s===i,onClick:()=>(e=>{if(l?.(e),r&&a?.[e]){let t=r.current.getBoundingClientRect(),i=a[e].getBoundingClientRect();r.current.scrollBy({top:0,left:i.left-t.left,behavior:"smooth"})}})(i),children:"day"===n?w.default.tz(e,"YYYY-MM-DD","Europe/Prague").calendar((0,w.default)().tz("Europe/Prague"),{...I.CALENDAR_FORMATS[h],sameElse:"en"===h?"MM/DD":"D. M."}):(c=(u=(o=t.get(e))&&o.length>0?(0,k.formatDate)(String(o[0].startAt)):"string"==typeof e?e.includes("-")?(0,k.formatDate)(e+"-01"):(0,k.formatDate)(e,"YYYY-MM-DD"):(0,k.formatDate)(String((0,w.default)(Number(e)).format("YYYY-MM-DD")))).isSame((0,k.formatDate)((0,w.default)().format("YYYY-MM-DD")),"year")?"MMMM":"MMMM YYYY",u.format(c))})},i)})}),f&&(0,p.jsx)(y,{children:i.map((e,t)=>(0,p.jsx)(v,{children:(0,p.jsx)(b,{type:"button","aria-pressed":u===t,isActive:u===t,onClick:()=>c(t),children:`${(0,w.default)(e.dateFrom).format("YYYY")} - ${(0,w.default)(e.dateTo).format("YYYY")}`})},t))})]})]})}],501440);var D=e.i(568549),L=e.i(719631),O=e.i(491709),P=e.i(417734),F=e.i(838478),N=e.i(312207);let M=t.default.li.withConfig({displayName:"NDPlusEvent__Item",componentId:"sc-299b34ce-0"})` 783 display: flex; 784 flex-direction: row; 785 margin-bottom: 8px; 786 font-weight: 700; 787`,j=t.default.div.withConfig({displayName:"NDPlusEvent__Time",componentId:"sc-299b34ce-1"})` 788 margin-right: 8px; 789`,$=({ndPlusEvent:e})=>(0,p.jsxs)(M,{children:[(0,p.jsx)(j,{children:(0,k.formatDate)(String(e.startAt)).format("HH:mm")}),(0,p.jsx)("div",{children:(0,T.nbsp)(e.production?.title)})]}),U=t.default.div.withConfig({displayName:"NDPlusEvents__Wrapper",componentId:"sc-7134683a-0"})` 790 align-self: flex-start; 791 margin-bottom: 16px; 792 padding-top: 16px; 793 padding-left: 16px; 794 display: flex; 795 flex-direction: column; 796 align-items: flex-start; 797 798 ${e=>!e.programmePage&&t.css` 799 margin-left: 16px; 800 margin-top: 40px; 801 padding: 16px 0 0 16px; 802 `} 803`,B=t.default.div.withConfig({displayName:"NDPlusEvents__Head",componentId:"sc-7134683a-1"})` 804 display: flex; 805 flex-direction: row; 806 flex-wrap: nowrap; 807 margin-bottom: 16px; 808 padding-bottom: 16px; 809 align-items: flex-start; 810 position: relative; 811 &:after { 812 position: absolute; 813 content: ''; 814 background: ${e=>e.theme.color.gold}; 815 bottom: 0; 816 left: -16px; 817 width: calc(100% + 16px); 818 height: 1px; 819 } 820`,V=t.default.ul.withConfig({displayName:"NDPlusEvents__List",componentId:"sc-7134683a-2"})``,G=t.default.div.withConfig({displayName:"NDPlusEvents__Title",componentId:"sc-7134683a-3"})` 821 margin-left: 16px; 822 font-size: 12px; 823 line-height: 1.16; 824`,q=({ndPlusEvents:e,title:t,textFeaturedProgramme:r,programmePage:i,...n})=>e&&0!==e.length?(0,p.jsxs)(U,{programmePage:i,...n,children:[(0,p.jsxs)(B,{children:[(0,p.jsx)(s.Icon,{name:"ndplus",width:"32"}),(0,p.jsxs)(G,{children:[(0,T.nbsp)(t),(0,p.jsx)("br",{}),(0,T.nbsp)(r)]})]}),e&&e.length>0&&(0,p.jsx)(V,{children:e.map((e,t)=>e&&(0,p.jsx)($,{ndPlusEvent:e},`NDPlusEvent_${t}`))})]}):null;var H=e.i(408717);w.default.extend(R.default),w.default.extend(A.default);let z=(0,t.default)(S.Heading).withConfig({displayName:"ProgrammeItem__StyledHeading",componentId:"sc-7eabc155-0"})` 825 letter-spacing: -0.5px; 826 827 ${e=>e.ndPlus&&t.css` 828 font-size: 16px; 829 `}; 830 831 ${e=>e.disabled&&"opacity: 0.3"}; 832 833 span { 834 text-decoration: none; 835 line-height: 1.5; 836 padding-bottom: 3px; 837 ${e=>`background-image: linear-gradient(${e.theme.color.gold}, ${e.theme.color.gold})`}; 838 background-position: 0 100%; 839 background-repeat: no-repeat; 840 background-size: 0 2px; 841 transition: background-size 0.3s; 842 } 843`,K=t.default.div.withConfig({displayName:"ProgrammeItem__Wrapper",componentId:"sc-7eabc155-1"})` 844 display: flex; 845 flex-direction: row; 846 flex-shrink: 0; 847 width: ${e=>e.extended?"448px":"248px"}; 848 padding: ${e=>e.noPadding?"0 !important":"40px"}; 849 border: 1px solid transparent; 850 position: relative; 851 outline: none; 852 cursor: pointer; 853 ${e=>e.withDetails&&"padding: 56px 24px 40px 24px"}; 854 ${e=>e.highlighted&&`border-color: ${e.theme.color.gold}`}; 855 856 ${e=>e.hasNDPlus&&t.css` 857 ${i.mq.md} { 858 width: auto; 859 max-width: 486px; 860 } 861 `}; 862 863 ${e=>!e.disabled&&t.css` 864 &:hover ${z} span { 865 background-size: 100% 2px; 866 } 867 `}; 868`,W=t.default.div.withConfig({displayName:"ProgrammeItem__DateTags",componentId:"sc-7eabc155-2"})` 869 display: flex; 870 flex-direction: column; 871 margin-top: ${e=>e.theme.gap.xs}; 872`,Y=(0,t.default)(n.Tag).withConfig({displayName:"ProgrammeItem__StyledDateTag",componentId:"sc-7eabc155-3"})` 873 & + & { 874 margin-top: 8px; 875 } 876`;t.default.div.withConfig({displayName:"ProgrammeItem__DayDivider",componentId:"sc-7eabc155-4"})` 877 width: 1px; 878 height: 112px; 879 border-left: 1px solid ${e=>e.theme.color.gold}; 880 padding-left: 15px; 881 position: sticky; 882 left: 0; 883 top: 0; 884 font-family: var(--font-din-serif, serif); 885 color: ${e=>e.theme.color.gold}; 886 text-transform: capitalize; 887 white-space: nowrap; 888`;let Q=t.default.div.withConfig({displayName:"ProgrammeItem__Genre",componentId:"sc-7eabc155-5"})` 889 display: flex; 890 align-items: center; 891 line-height: 1; 892 height: 16px; 893 margin-bottom: ${e=>e.theme.gap.sm}; 894 ${e=>e.disabled&&"opacity: 0.3"}; 895 896 > span { 897 position: relative; 898 top: 2px; 899 } 900`,X=t.default.div.withConfig({displayName:"ProgrammeItem__TimePlace",componentId:"sc-7eabc155-6"})` 901 display: flex; 902 flex-direction: row; 903 ${e=>e.disabled&&"opacity: 0.3"}; 904`,J=t.default.span.withConfig({displayName:"ProgrammeItem__Time",componentId:"sc-7eabc155-7"})` 905 font-weight: bold; 906 margin-right: ${e=>e.theme.gap.xxs}; 907`,Z=t.default.span.withConfig({displayName:"ProgrammeItem__Place",componentId:"sc-7eabc155-8"})` 908 color: ${e=>e.theme.color.gold}; 909 font-family: var(--font-din-serif, serif); 910`,ee=t.default.div.withConfig({displayName:"ProgrammeItem__TicketsInfo",componentId:"sc-7eabc155-9"})` 911 margin-top: 8px; 912 line-height: 16px; 913 font-size: 12px; 914 order: 1; 915 color: ${e=>e.isSoldOut?e.theme.color.red:"inherit"}; 916`,et=(0,t.default)(s.Icon).withConfig({displayName:"ProgrammeItem__StyledIcon",componentId:"sc-7eabc155-10"})` 917 width: 16px; 918 margin-right: 8px; 919`,er=t.css` 920 width: 100%; 921 max-width: 184px; 922 margin-top: auto; 923 z-index: 2; 924 order: 0; 925 926 ${e=>!e.hasTextBelow&&"margin-bottom: 24px"}; 927`,ei=(0,t.default)(D.BuyButton).withConfig({displayName:"ProgrammeItem__StyledBuyButton",componentId:"sc-7eabc155-11"})` 928 ${er} 929`,en=(0,t.default)(r.Button).withConfig({displayName:"ProgrammeItem__StyledButton",componentId:"sc-7eabc155-12"})` 930 ${er} 931`,es=t.default.div.withConfig({displayName:"ProgrammeItem__Inner",componentId:"sc-7eabc155-13"})` 932 display: flex; 933 flex-direction: column; 934 flex-shrink: 0; 935 max-width: 100%; 936 937 @media (max-width: 480px) { 938 padding-right: 40px; 939 } 940 941 ${e=>e.hasNDPlus&&` 942 ${i.mq.md} { 943 flex-direction: row; 944 flex-wrap: nowrap; 945 align-items: center; 946 justify-content: space-between; 947 } 948 `}; 949`,ea=(0,t.default)(N.Link).withConfig({displayName:"ProgrammeItem__AbsoluteLink",componentId:"sc-7eabc155-14"})` 950 position: absolute; 951 top: 0; 952 right: ${e=>(e.isHalf,"0")}; 953 bottom: 0; 954 left: 0; 955 z-index: 1; 956 opacity: 0; 957 user-select: none; 958 height: 100%; 959`,eo=t.default.div.withConfig({displayName:"ProgrammeItem__Event",componentId:"sc-7eabc155-15"})` 960 display: flex; 961 flex-direction: column; 962 height: 100%; 963 ${e=>e.hasNDPlus&&` 964 ${i.mq.mdmax} { 965 margin-bottom: 24px; 966 } 967 ${i.mq.md} { 968 max-width: 190px; 969 margin-right: 16px; 970 flex-shrink: 0; 971 } 972 `}; 973`,el=t.default.div.withConfig({displayName:"ProgrammeItem__Content",componentId:"sc-7eabc155-16"})` 974 ${e=>e.programmePage&&t.css` 975 flex-grow: 1; 976 padding-left: 16px; 977 border-left: 1px solid ${e=>e.theme.color.gold}; 978 `}; 979 margin-bottom: 24px; 980`,eu=t.default.span.withConfig({displayName:"ProgrammeItem__GenreTitle",componentId:"sc-7eabc155-17"})` 981 ${e=>e.ndPlus&&t.css` 982 display: inline-block; 983 padding: 5px 11px; 984 border: 1px solid #000; 985 font-size: 12px; 986 `}; 987`,ec=t.default.div.withConfig({displayName:"ProgrammeItem__ItemBottom",componentId:"sc-7eabc155-18"})` 988 margin-top: auto; 989 display: flex; 990 flex-direction: column; 991`,ed=t.default.div.withConfig({displayName:"ProgrammeItem__NdPlusProduction",componentId:"sc-7eabc155-19"})` 992 margin-left: 16px; 993 font-size: 12px; 994 line-height: 1.16; 995 margin-top: 5px; 996`,eh=t.default.div.withConfig({displayName:"ProgrammeItem__OtherTimes",componentId:"sc-7eabc155-20"})` 997 display: flex; 998 flex-direction: column; 999 align-self: flex-start; 1000 ${e=>e.disabled&&"opacity: 0.3"}; 1001 border-left: solid 1px ${e=>e.theme.color.gold}; 1002 1003 ${i.mq.md} { 1004 margin-top: ${e=>e.theme.gap.lg}; 1005 width: 50%; 1006 } 1007 1008 ul { 1009 columns: 4.5rem 2; 1010 max-height: 12rem; 1011 } 1012`,ef=t.default.li.withConfig({displayName:"ProgrammeItem__OtherTime",componentId:"sc-7eabc155-21"})` 1013 font-size: 1rem; 1014 line-height: 1.5; 1015 font-weight: bold; 1016 cursor: pointer; 1017 padding: 0.25rem 1rem; 1018 1019 ${e=>e.disabled&&` 1020 color: rgba(0, 0, 0, 0.4); 1021 `} 1022 1023 ${e=>!e.disabled&&`&:hover { 1024 color: ${e.theme.color.white}; 1025 background-color: ${e.theme.color.gold}; 1026 } 1027 `} 1028`,ep=t.default.p.withConfig({displayName:"ProgrammeItem__TimesTitle",componentId:"sc-7eabc155-22"})` 1029 margin-bottom: ${e=>e.theme.gap.xs}; 1030 margin-left: ${e=>e.theme.gap.xs}; 1031 font-size: ${e=>e.theme.fz.xxs}; 1032 line-height: ${e=>e.theme.fz.xs}; 1033 color: ${e=>e.theme.color.black}; 1034 position: relative; 1035`,eg=(0,t.default)(N.Link).withConfig({displayName:"ProgrammeItem__CustomLink",componentId:"sc-7eabc155-23"})` 1036 position: relative; 1037 z-index: 50; 1038 1039 & > * { 1040 padding-bottom: 6px; 1041 } 1042`,em=({onClick:e,highlighted:r,withDetails:i,noPadding:n,className:a,sameHeight:o,programmePage:l,textFeaturedProgramme:u,ndPlusCalendar:c,showOtherGenre:d=!1,...h})=>{let f,m,y=(0,g.useContext)(P.AppContext),v=(0,g.useContext)(t.ThemeContext)??F.theme,{textFreeEntry:b,textCanceled:_,textProgramChange:E,textBooked:S,textSaleSuspended:x,textBookingNotStartedYet:A,textSubscriptionSale:R,textSubscriptionSaleLabel:C,textSubscriptionSaleUrl:D,textFree:M,textChooseTime:j,textOtherTimes:$,textChooseDifferentTime:U,textPriorityBookingStarted:B}=y,V=(0,g.useContext)(P.AppContext).productionPage,G="hp"===h.type||h.isSingle?h.item:h.items.find(e=>e.isFreeWithTicket||e.isFree||!e.isCanceled&&Number(e.ticketsAvailable)>0)||h.items[0];if(!G)return(0,p.jsx)(p.Fragment,{});let er=(0,w.default)(),em=G.production?.genre,ey=G.production?.ensemble,ev="program"===h.type?(h.isSingle?h.item:h.items[0]).production?.genre?.icon?.codename:h.item.production?.ensemble?.genre?.codename,eb=ey?.statute==="VlastnÃ"&&ev&&(0,L.resolveEnsembleStyle)(ev,v.color),e_=!!G.isCanceled,eE="program"===h.type&&(h.isSingle&&h.item.ndplusEvents&&h.item.ndplusEvents.length>0||!h.isSingle),eS=Array.isArray(G.startAt)?G.startAt[0]:G.startAt,ex=(0,k.formatDate)(eS),eT=(0,w.default)(String(G.sellFrom||"2100-01-01")),ew=(0,H.getPri
1042oritySaleShift)(),eA=ew&&G.prioritySaleInclusion?eT.subtract(ew,"days"):eT,eR=ew>0&&G.prioritySaleInclusion&&er.isSameOrAfter(eA)&&er.isBefore(eT),eI="program"===h.type&&(h.isSingle?(0,w.default)(String(h.item.internetFrom||"1970-01-01")):h.items.map(e=>(0,w.default)(String(e.internetFrom||"1970-01-01")))),ek="program"===h.type&&(h.isSingle?(0,w.default)(String(h.item.internetTo||"2100-01-01")):h.items.map(e=>(0,w.default)(String(e.internetTo||"2100-01-01")))),eC=!0;"program"===h.type&&(h.isSingle?h.item.production?.groupbook:h.items[0].production?.groupbook)&&(!eI||(Array.isArray(eI)?eI.some(e=>e.isBefore(er)):eI.isBefore(er))||(eC=!1),!ek||(Array.isArray(ek)?ek.some(e=>e.isAfter(er)):ek.isAfter(er))||(eC=!1));let eD="hp"===h.type||h.isSingle?Number(h.item.ticketsAvailable):h.items.map(e=>Number(e.ticketsAvailable)).reduce((e,t)=>e+t,0),eL=ex&&ex.isAfter(er)&&("hp"===h.type||h.isSingle?!h.item.isFree&&!h.item.isCanceled&&!h.item.isEntered&&!h.item.isFreeWithTicket:h.items.map(e=>!e.isFree&&!e.isCanceled&&!e.isEntered&&!e.isFreeWithTicket).filter(Boolean).length>0),eO="hp"===h.type||h.isSingle?h.item.saleSuspended:0===h.items.map(e=>!e.saleSuspended).filter(Boolean).length,eP=e=>{if(!e)return"00:00";try{return(0,k.formatDate)(e).format("HH:mm")}catch(r){let t=String(e).match(/T(\d{2}:\d{2}):\d{2}/);return t?t[1]:"00:00"}};return(0,p.jsxs)(K,{withDivider:!1,onClick:()=>{e&&e(G)},highlighted:r,withDetails:i,noPadding:n,className:a,extended:"program"===h.type&&(h.isSingle?h.item:h.items[0]).ndplusEvents&&(h.isSingle?h.item:h.items[0]).ndplusEvents.length>0&&!l,sameHeight:o,disabled:e_,hasNDPlus:eE,itemType:"http://schema.org/Event",children:[(0,p.jsx)(ea,{page:V,params:{slug:G.production?.slug+"-"+G.production?.id,..."hp"===h.type||h.isSingle?{t:(()=>{let e=String(eS).match(/^(\d{4}-\d{2}-\d{2})T(\d{2}:\d{2}):\d{2}/);if(e){let[,t,r]=e;return`${t}-${r.replace(":","-")}`}return ex.format("YYYY-MM-DD-HH-mm")})()}:{}},isHalf:"program"===h.type&&!h.isSingle,noHover:!0}),(0,p.jsxs)(es,{hasNDPlus:eE,children:[(0,p.jsxs)(eo,{children:[(0,p.jsxs)(el,{programmePage:l,children:[(0,p.jsxs)(Q,{disabled:e_,children:[eb&&(em?.id!==I.GENRE_OTHER||d)&&(0,p.jsx)(et,{name:eb.icon,color:eb.color}),!em&&G?.production?.showInNdplusCalendar&&!c&&(0,p.jsx)(s.Icon,{name:"ndplus",width:"28"}),em&&(0,p.jsxs)(eu,{children:[(em.id!==I.GENRE_OTHER||d)&&em.title,ey?.statute!=="VlastnÃ"&&(0,p.jsxs)(p.Fragment,{children:[(em.id!==I.GENRE_OTHER||d)&&(0,p.jsx)("br",{}),ey?.title]})]}),"hp"===h.type&&G?.production?.showInNdplusCalendar&&h.item.featuredProgrammeForProduction&&(0,p.jsxs)(ed,{children:[h.item.featuredProgrammeForProduction.title," ",(0,p.jsx)("br",{})," ",y.featuredProgramme]})]}),(0,p.jsx)(z,{tag:"h3",size:"sm",marginBottom:"xs",ndPlus:G.production?.showInNdplusCalendar||!1,disabled:e_,children:(0,p.jsx)("span",{itemProp:"name",children:(0,T.nbsp)(String(G?.production?.title))})}),(0,p.jsxs)(X,{disabled:e_,children:[("hp"===h.type||h.isSingle)&&(0,p.jsx)(J,{itemProp:"startDate",content:ex.format(),children:eP(eS)}),(0,p.jsx)(Z,{itemProp:"location",itemType:"http://schema.org/Place",content:(G?.venue?.scene?.id!==I.SCENE_OTHER_STAGES&&G?.venue?.scene?.title?G?.venue?.scene?.title:G?.venue?.colosseumTitle||G?.venue?.title)||void 0,children:G?.venue?.scene?.id!==I.SCENE_OTHER_STAGES&&G?.venue?.scene?.title?G?.venue?.scene?.title:G?.venue?.colosseumTitle||G?.venue?.title})]}),(0,p.jsx)(W,{children:(f=[],m=[],G.eventType&&String(G.eventType.id)!==I.EVENT_TYPE_REPEAT&&!m.includes(String(G.eventType?.title))&&(f.push((0,p.jsx)(Y,{color:"black",children:String(G.eventType?.title)},"tag_event_type")),m.push(G.eventType?.title??"")),_&&G.isCanceled&&!m.includes(_)&&(f.push((0,p.jsx)(Y,{color:"black",children:_},"tag_canceled")),m.push(_)),E&&G.isChanged&&!m.includes(E)&&(f.push((0,p.jsx)(Y,{color:"white",children:E},"tag_changed")),m.push(E)),M&&G.isFree&&!m.includes(String((0,T.nbsp)(M)))&&(f.push((0,p.jsx)(Y,{color:"white",children:(0,T.nbsp)(M)},"tag_free")),m.push(String((0,T.nbsp)(M)))),b&&G.isFreeWithTicket&&!m.includes(String((0,T.nbsp)(b)))&&(f.push((0,p.jsx)(Y,{color:"white",children:(0,T.nbsp)(b)},"tag_free_entry")),m.push(String((0,T.nbsp)(b)))),S&&G.isEntered&&!m.includes(String((0,T.nbsp)(S)))&&(f.push((0,p.jsx)(Y,{color:"white",children:(0,T.nbsp)(S)},"tag_is_entered")),m.push(String((0,T.nbsp)(S)))),G.tags?.slice(0,3).forEach(e
1042=>{m.includes(String((0,T.nbsp)(e?.title)))||f.push((0,p.jsx)(Y,{color:"white",children:String((0,T.nbsp)(e?.title))},`programme_carousel_${G.id}_tag_${e?.id}`)),m.push(String((0,T.nbsp)(e?.title)))}),0===G.tags.length&&G.production?.tags?.slice(0,3).map(e=>{m.includes(String((0,T.nbsp)(e?.title)))||f.push((0,p.jsx)(Y,{color:"white",children:String((0,T.nbsp)(e?.title))},`programme_carousel_${G.id}_tag_${e?.id}`)),m.push(String((0,T.nbsp)(e?.title)))}),f.splice(0,3))})]}),ex.isAfter(er)&&eC&&(0,p.jsxs)(ec,{children:["program"===h.type&&!h.isSingle&&j&&(0,p.jsx)(en,{hasTextBelow:eL,page:V,params:{slug:G.production?.slug+"-"+G.production?.id},hash:"tickets",children:eD>0?j:U||""}),eL&&(!G.saleSuspended&&eA?.isSameOrBefore(er)?(0,p.jsx)(ee,{isSoldOut:0===eD,children:eR?B:(0,O.resolveTicketsAmount)(Number(eD),y,G?.production?.groupbook||!1)}):(0,p.jsx)(ee,{children:eO?x:G.subscriptionSale?(0,p.jsxs)(p.Fragment,{children:[(0,p.jsx)(p.Fragment,{children:R}),D&&(0,p.jsxs)(p.Fragment,{children:[" ",(0,p.jsx)(eg,{href:D,inverseHover:!0,children:C||D})]})]}):A})),("hp"===h.type||h.isSingle)&&(0,p.jsx)(ei,{event:{...G,startAt:eS},showChooseButton:!G.eventType||String(G.eventType.id)!==I.EVENT_TYPE_ONLY,hasTextBelow:!G.isFree&&!G.isCanceled&&!G.isEntered&&!G.isFreeWithTicket})]})]}),"program"===h.type&&h.isSingle&&(0,p.jsx)(q,{title:h.item.production?.title||null,ndPlusEvents:h.item.ndplusEvents,textFeaturedProgramme:u,programmePage:!0}),"program"===h.type&&!h.isSingle&&$&&(0,p.jsxs)(eh,{disabled:e_,children:[(0,p.jsx)(ep,{children:$}),(0,p.jsx)("ul",{children:h.items.filter(e=>{let t=(0,w.default)(String(e.internetFrom||"1970-01-01")),r=(0,w.default)(String(e.internetTo||"2100-01-01"));return t.isBefore(er)&&r.isAfter(er)}).map((e,t)=>{let r=!e.isFreeWithTicket&&!e.isFree&&(!!e.isCanceled||0===Number(e.ticketsAvailable)),i=(0,k.formatDate)(e?.startAt||"");return(0,p.jsx)(ef,{disabled:r,itemProp:"startDate",content:i.format(),children:(0,p.jsx)(N.Link,{page:V,params:{slug:e.production?.slug+"-"+e.production?.id,t:i.format("YYYY-MM-DD-HH-mm")},hash:"tickets",noHover:!0,children:eP(e?.startAt||"")})},`time_${t}`)})})]})]})]})};e.s(["ExtendedProgrammeCarouselItemComponent",0,({item:e,textFeaturedProgramme:t})=>(0,p.jsx)(em,{withDetails:!0,sameHeight:!0,item:e,type:"hp",textFeaturedProgramme:t})],372438)},373814,e=>{"use strict";var t,r,i=e.i(843476),n=e.i(271645),s=e.i(997053);function a(){return(a=Object.assign.bind()).apply(null,arguments)}var o=e.i(417734),l=e.i(456780);let u=(0,s.default)(function(e){return n.createElement("svg",a({xmlns:"http://www.w3.org/2000/svg",className:"loader_svg__loader",viewBox:"0 0 203 203"},e),t||(t=n.createElement("path",{fill:"none",stroke:"currentColor",strokeLinecap:"round",strokeLinejoin:"round",strokeWidth:3,d:"M201.5 101.5a100 100 0 1 0-100 100 100 100 0 0 0 100-100",className:"loader_svg__loader__border"})),r||(r=n.createElement("g",{fill:"none",stroke:"currentColor",strokeLinecap:"round",strokeLinejoin:"round",className:"loader_svg__loader__lion"},n.createElement("path",{d:"M111.37 154.41a4 4 0 0 1-2.38.86c-4.1 0-8-5.61-12.73-5.61a7.9 7.9 0 0 0-5.18 2.34"}),n.createElement("path",{d:"M97.72 152a2.7 2.7 0 0 0-1.72 2.62c0 2.16 3.45 4.11 7.12 4.11M82.61 150.73a19.88 19.88 0 0 0-9.07-8.85 73 73 0 0 1 8-5.82c-1.94-2-3.67-7.35-3.67-11 0-5.4 17.77-8.42 22.29-8.42M53 152.46c.21 2.38 1.34 3.67 4.34 3.67 6.9 0 6.69-12.73 11.87-12.73 2.37 0 1.94 7.33 6.69 7.33a2.61 2.61 0 0 0 2.57-2.6M47 140.81a3.38 3.38 0 0 0-1.08 2.81c0 1.94 1.72 3.24 4.1 3.24 2.8 0 9.71-4.1 12.08-4.1.65 0 1.08.21 1.08.86 0 1.73-13.82 6-14.47 12.09"}),n.createElement("path",{d:"M97.07 108.42a82 82 0 0 0-9.93-.64c-15.11 0-24.83 4.53-24.83 9.93 0 6 8.43 12.3 8.43 16 0 3.46-4.32 5-8.64 5-3.89 0-8-.21-11.44-.21-4.53 0-8.21.43-9.71 2.6M105.05 115.77c0 2 .22 2.81 1.3 2.81 1.5 0 3.24-1.08 3.24-3.67M94.7 103l.21 1.08c1.73 4.31 9.28 5.83 9.28 8.42 0 1.29-1.94 1.73-1.94 3.45 0 1.08.43 1.3 1.08 1.3"}),n.createElement("path",{d:"M63 138c-7.82-.37-1.3-14.9-12.53-16.19"}),n.createElement("path",{d:"M54.76 125.91a3.43 3.43 0 0 0-3.67 3.16v.06c0 1.94 1.51 4.75 3.88 6.69M49.15 90.43a3.32 3.32 0 0 1-2-3c0-2.59 2-5.61 2-8.85a6.54 6.54 0 0 0-3-5.61"}),n.createElement("path",{d:"M47.63 78.56c-.21-.43-.65-.65-1.72-.65-2.38 0-3.24 2.38-3.24 4.32M76.37 46c0-1.94-.87-3-2.37-3-1.3 0-3 1.29-3.68 4.1M69.66 56c0-7.12 10.57-8 10.57-13.6M58.65 74.32c2.38-.65 6.48-4.75 8.2-8.63 3 2.16 9.92 17 13.16 18.56M56.71 47.77c-1.52.43-3.24 1.08-3.24 3.67 0 7.56 12.09 5.83 12.09 10.36 0 2.38-6.9 2-6.9 6 0 1.94 1.94 2.58 3 2.58M67.71 40a6.9 6.9 0 0 1-.43 2.37 2.18 2.18 0 0 0-2.37-1.25c-1.52 0-3 1.51-3 3.89 0 2.81 3.89 8 3.89 10.15 0 .43-.22 1.07-.65 1.07-1.73 0-5.83-11.22-11.44-12.3"}),n.createElement("path",{d:"M81.74 75c-2.37-1.73-5.83-8.2-7.77-10.14-2.16-2.16-5.18-5.4-5.18-10.8 0-3 .22-6.47.22-9.49 0-3.67-.22-6.69-2-8M106.78 54.9a10.4 10.4 0 0 0-4.63-1.27 31 31 0 0 0-3.34.37c.21-1.06.42-1.7.64-2.56M100.52 57.69a14 14 0 0 1-1.26-2.29 17.8 17.8 0 0 1 3.85-.51M97.72 51a4.62 4.62 0 0 0 1.06 3c-4.3.53-8.55 2-11.21 2-4.09 0-5.57-2.58-5.57-5.82h-.87c0 5.83 1.52 8.42 5.83 8.42 3.14 0 7.92-2.15 12.3-3.16v2.69M119.08 43.45c1.51-2.59 6.48-7.34 9.94-9.28l-.43-.86c-2.59 2.15-9.07 1.51-9.07 4.31a2.33 2.33 0 0 0 .43 1.51 2.11 2.11 0 0 1-2 .87c-1.94 0-4.31-1.52-4.31-3.25a2.52 2.52 0 0 0 2.21-2.62c0-1.72-1.73-4.53-.86-7.77l-1.08-.21c-.43 3.45-4.54 5.4-4.54 8a4.07 4.07 0 0 0 1.08 2.17c0 .85-1.52 1.29-3.25 1.29-1.51 0-3.24-.43-3.45-1.72 1.08-.87 1.51-1.51 1.51-2.16 0-1.95-4.1-3.23-5-6l-.63.44a28.35 28.35 0 0 1 2.38 11M110.29 82.9c.89 3.67 4.56 6.22 4.56 8.12 0 .44-.22.65-.44 1.08 2.59-.86 3.24-2.16 3.24-3.24 0-2.81-6.25-6-6.25-11.87M115.09 76.82c1.45 3.09 4.73 5.1 4.73 8.29 2.37-1.29 2.81-2.59 2.81-3.67 0-3-7.13-5.4-7.13-11.43M119.88 68.13c1.47 4.92 4.68 5.79 4.68 10.12 1.44-1.31 2.38-1.81 2.38-3.89 0-3.24-6.26-4.75-7.78-11.87M158.59 119.43c6.7 5.4 5 12.52 10.15 12.52 2.38 0 3.46-1.3 3.46-3.24-.01-3.66-4.76-9.28-13.61-9.28M108.51 46.47a1.08 1.08 0 1 0-1.08-1.08h0a1 1 0 0 0 .92 1.07Z"}),n.createElement("path",{d:"M108.51 47.56a3.23 3.23 0 0 1-3-3c1.51 0 1.72-.86 4.11-.86a1.58 1.58 0 0 1 1.72 1.45 1.3 1.3 0 0 1 0 .28c.03 1.04-1.34 2.13-2.83 2.13M117.15 55.13c.86 0 1.94-2.15 1.94-4.11 0-2.37-1.08-3.89-2.15-3.89-.65 0-1.3.65-1.3 1.73a4.85 4.85 0 0 0 .65 2.16M100.09 48c-1.07-.24-.12-3.43-1.16-3.43a1.4 1.4 0 0 0-1.08.43M150.17 120c-6.47.43-8.85 3-8.85 5.19a2.55 2.55 0 0 0 2.51 2.59h.29c4.54-.01.88-4.32 6.05-7.78M151.47 80.13c-11.23-9-15.1-17-15.1-22.65 0-5 3-8 6.47-8a7.9 7.9 0 0 1 5.4 2.59l.65-.65c-2.37-6.91-6.25-9.07-10.14-9.07-4.75 0-9.29 4.1-9.29 11.22 0 7.77 5 17.92 19.43 27.84-8.64 4.11-14.68 9.72-14.68 19 0 10.36 7.13 16.62 17.06 17.69"}),n.createElement("path",{d:"M153.37 110.37a11.79 11.79 0 0 1-12-11.57v-.52c0-5.4 4.1-10.57 10.36-15.11 7.56 5.82 11.44 11 11.44 17.7a9.77 9.77 0 0 1-9.8 9.5"}),n.createElement("path",{d:"M156 118.13c8.68 0 13.81-5.94 13.81-13 0-8.85-4.53-16.61-15.32-23.53 7-3.41 11-9.33 11-15.54 0-3.84-2.86-9.28-7.34-9.28-2.59 0-5.19 1.5-6.91 5.17l.43.86a6.72 6.72 0 0 1 4.1-1.72c2.47 0 4.53 1.42 4.53 5.61 0 3.89-1.3 9.07-8.85 13.38M142.37 135.41c3 3.23 5.83 3.67 7.77 3.67 5.18 0 8.2-5 8.2-11a20.9 20.9 0 0 0-2.37-9.93M124.05 110.8c9.5 25.47 20.29 27 20.29 39.51a32.8 32.8 0 0 1-1.51 9.28c3.46-2.6 5.62-6.05 5.62-10.15 0-3.21-1.2-6.69-3.89-10.33"}),n.createElement("path",{d:"M151.25 118.13a16.34 16.34 0 0 1 2.15 7.56c0 4.11-2.15 6.7-6.26 6.7-11.43 0-13.38-15.11-25-28.28-4.54-5-13.59-7.56-13.59-18.13M59.94 108a20.4 20.4 0 0 0-3.68-11.23c9.29-3.45 38-2.58 40.15-6M119.52 176.85v-4.72a3.12 3.12 0 0 0 2.81-3.39s0-.05 0-.07c0-3.88-3.45-9.92-3.45-13.38 0-1.73.65-2.6 1.94-2.6 1.73 0 4.1 1.74 6.47 1.74a3 3 0 0 0 3.24-2.74v-.07c0-1.08-.42-1.94-1.
104208-2.15"}),n.createElement("path",{d:"M134.42 147.93a10.6 10.6 0 0 0-3.9-.65 29.1 29.1 0 0 0-8.63 1.51 51.8 51.8 0 0 1 1.3-10.15c-4.1-1.29-9.93-2.81-9.93-5.61 0-6 10.79-8.42 10.79-22.24M102.46 167.36c0 2.37 1.3 3.46 3 3.46a4.8 4.8 0 0 0 3.67-1.51c2.16-2.37 3.45-11.65 5.83-11.65 1.94 0-.43 7.11-.43 10.57 0 2.38.65 4.1 3 4.1"}),n.createElement("path",{d:"M85.19 94.18c8.21 9.06 25.69 13 25.69 20.72 0 6-16.62 11.23-16.62 20.94 0 8.86 14.47 4.54 19.86 9.94a2.75 2.75 0 0 1 1.08 2.36c0 2.17-1.73 5-3.46 6.92-5.82 6.26-13 11.43-13 17M35.55 97a3.1 3.1 0 0 0-.43 1.51c0 2.59 1.73 3.89 4.75 3.89 4.75 0 8.41-6.91 11.44-6.91 1.51 0 1.51 1.3 1.51 2.16 0 1.08-.21 2.38-.21 3.67 0 2.16 1.29 3.67 3 3.67a2.7 2.7 0 0 0 1.94-1.08M35.76 84.9a2.91 2.91 0 0 0-2.15 3 3.19 3.19 0 0 0 1.94 2.81c3 1.51 11.87.21 11.87 3 0 1.51-12.74-.22-16.62 3.46M81.31 85.76c-5.61.87-14.89 2.16-17.92 2.6-2.37.42-8.63 1.93-13 1.93a6.5 6.5 0 0 1-3.24-.65c-6-3.46-11.17-7.51-14.63-7.51a4.1 4.1 0 0 0-1.72.43M99.44 72.13c-1.5-2.15-4.53-2.81-7.12-2.81-8 0-11.24 8-11.24 12.08a37 37 0 0 0 .22 4.32M108.51 86c0-9.07 13-19 13-34.32 0-5.18-4.32-11.65-15.76-11.65C99.49 40 96 41.73 96 46c0 4.11 2.16 5 3.89 5s3-2.37 5-2.37c2.37 0 2.6 1.94 2.6 5.39 0 3 1.72 4.32 1.72 6.26 0 2.16-1.3 3.89-3.45 3.89a5.31 5.31 0 0 1-4.53-2.6 1.77 1.77 0 0 0 1.08-1.73 1.7 1.7 0 0 0-1.68-1.72h-.14A2.81 2.81 0 0 0 98 60.94c0 3.46 2.58 5 5.17 6-.65 2.81-1.94 4.54-3.67 5.18"}))))}).withConfig({displayName:"Loader__StyledLoaderIcon",componentId:"sc-281c1584-0"})` 1043 width: 203px; 1044 height: 203px; 1045 1046 .loader__border { 1047 stroke: ${e=>e.theme.color.gold}; 1048 stroke-dasharray: 650; 1049 stroke-dashoffset: 650; 1050 transform-origin: 50% 50%; 1051 animation: 1052 draw-border 4s infinite 0.5s, 1053 rotate-border 4s linear infinite 0.5s; 1054 } 1055 1056 .loader__lion { 1057 stroke: ${e=>e.theme.color.secondalmostblack}; 1058 1059 > path { 1060 stroke-dasharray: 170; 1061 stroke-dashoffset: 170; 1062 animation: draw-lion 4s infinite 0.5s; 1063 } 1064 } 1065 1066 @keyframes rotate-border { 1067 0% { 1068 transform: rotate(0); 1069 } 1070 100% { 1071 transform: rotate(360deg); 1072 } 1073 } 1074 1075 @keyframes draw-border { 1076 0% { 1077 stroke-dashoffset: -650; 1078 } 1079 33% { 1080 stroke-dashoffset: -50; 1081 } 1082 66% { 1083 stroke-dashoffset: -50; 1084 } 1085 100% { 1086 stroke-dashoffset: 650; 1087 } 1088 } 1089 1090 @keyframes draw-lion { 1091 0% { 1092 stroke-dashoffset: 170; 1093 opacity: 1; 1094 } 1095 50% { 1096 stroke-dashoffset: 0; 1097 opacity: 1; 1098 } 1099 70% { 1100 stroke-dashoffset: 0; 1101 opacity: 1; 1102 } 1103 80% { 1104 opacity: 1; 1105 } 1106 90% { 1107 stroke-dashoffset: 170; 1108 opacity: 0; 1109 } 1110 100% { 1111 stroke-dashoffset: 170; 1112 opacity: 0; 1113 } 1114 } 1115`,c=s.default.div.withConfig({displayName:"Loader__LoaderWrapper",componentId:"sc-281c1584-1"})` 1116 position: fixed; 1117 top: 0; 1118 right: 0; 1119 left: 0; 1120 bottom: 0; 1121 display: flex; 1122 align-items: center; 1123 justify-content: center; 1124 background: rgba(255, 255, 255, 0.6); 1125 z-index: 9999; 1126`;e.s(["Loader",0,({className:e})=>{let{locale:t}=(0,n.useContext)(o.AppContext);return(0,i.jsx)(c,{className:e,role:"status","aria-live":"polite","aria-label":(0,l.getAccessibilityLabel)("loading",t||"cs"),children:(0,i.jsx)(u,{"aria-hidden":"true"})})}],373814)},403437,e=>{"use strict";let t=()=>{let e=window;return e.dataLayer||(e.dataLayer=[]),e.dataLayer};e.s(["pushPromotionEvent",0,function(e,r){let i=t();i.push({ecommerce:null}),i.push({event:e,ecommerce:{items:[r]}})},"trackPage",0,function(e){let r=e?.split("/")||[];t().push({event:"ga.page",pagePath:e,pageCategory1:r[2]||"",pageCategory2:r[3]||"",pageCategory3:r[4]||"",pageCategory4:r[5]||"",pageCategory5:r[6]||""})},"trackPodcast",0,function(e,r){t().push({event:"ga.podcast",name:e,position:r})}])},690586,e=>{"use strict";let t="--header-layout-offset",r="--header-visible-offset",i=e=>"number"==typeof e?e>=640?88:64:window.innerWidth>=640?88:64,n=(e,t)=>{let r=Number.parseFloat(window.getComputedStyle(document.documentElement).getPropertyValue(e).trim());return Number.isFinite(r)?r:t};e.s(["ANNOUNCEMENT_BAR_DEFAULT_DESKTOP_HEIGHT",0,46,"ANNOUNCEMENT_BAR_HEIGHT_VAR",0,"--announcement-bar-height","ANNOUNCEMENT_BAR_MARKER_ATTR",0,"data-announcement-bar","ANNOUNCEMENT_BAR_TRANSITION",0,"360ms cubic-bezier(0.22, 1, 0.36, 1)","FLOATING_SUBNAV_HEIGHT_VAR",0,"--floating-subnav-height","HEADER_LAYOUT_OFFSET_VAR",0,t,"HEADER_NAVIGATION_HIDDEN_VAR",0,"--header-navigation-hidden","HEADER_VISIBLE_OFFSET_VAR",0,r,"getAnnouncementBarMobileHeight",0,({hasLabel:e,hasLink:t,text:r})=>(r?.trim()||"").length>(e||t?64:86)?104:e&&t?72:56,"getDefaultNavigationHeight",0,i,"getVisibleHeaderOffset",0,()=>{let e=n(t,i(window.innerWidth));return n(r,e)}])},808341,(e,t,r)=>{"use strict";
1126Object.defineProperty(r,"__esModule",{value:!0});var i={cancelIdleCallback:function(){return a},requestIdleCallback:function(){return s}};for(var n in i)Object.defineProperty(r,n,{enumerable:!0,get:i[n]});let s="u">typeof self&&self.requestIdleCallback&&self.requestIdleCallback.bind(window)||function(e){let t=Date.now();return self.setTimeout(function(){e({didTimeout:!1,timeRemaining:function(){return Math.max(0,50-(Date.now()-t))}})},1)},a="u">typeof self&&self.cancelIdleCallback&&self.cancelIdleCallback.bind(window)||function(e){return clearTimeout(e)};("function"==typeof r.default||"object"==typeof r.default&&null!==r.default)&&void 0===r.default.__esModule&&(Object.defineProperty(r.default,"__esModule",{value:!0}),Object.assign(r.default,r),t.exports=r.default)},519083,(e,t,r)=>{"use strict";Object.defineProperty(r,"__esModule",{value:!0});var i={ESCAPE_REGEX:function(){return a},htmlEscapeAttributeString:function(){return c},htmlEscapeJsonString:function(){return u}};for(var n in i)Object.defineProperty(r,n,{enumerable:!0,get:i[n]});let s={"&":"\\u0026",">":"\\u003e","<":"\\u003c","\u2028":"\\u2028","\u2029":"\\u2029"},a=/[&><\u2028\u2029]/g,o={"&":"&",'"':""","'":"'","<":"<",">":">"},l=/[&"'<>]/g;function u(e){return e.replace(a,e=>s[e])}function c(e){return e.replace(l,e=>o[e])}},479520,(e,t,r)=>{"use strict";Object.defineProperty(r,"__esModule",{value:!0});var i={default:function(){return _},handleClientScriptLoad:function(){return y},initScriptLoader:function(){return v}};for(var n in i)Object.defineProperty(r,n,{enumerable:!0,get:i[n]});let s=e.r(555682),a=e.r(190809),o=e.r(843476),l=s._(e.r(174080)),u=a._(e.r(271645)),c=e.r(742732),d=e.r(922737),h=e.r(808341),f=e.r(519083),p=new Map,g=new Set,m=e=>{let{src:t,id:r,onLoad:i=()=>{},onReady:n=null,dangerouslySetInnerHTML:s,children:a="",strategy:o="afterInteractive",onError:u,stylesheets:c}=e,h=r||t;if(h&&g.has(h))return;if(p.has(t)){g.add(h),p.get(t).then(i,u);return}let f=()=>{n&&n(),g.add(h)},m=document.createElement("script"),y=new Promise((e,t)=>{m.addEventListener("load",function(t){e(),i&&i.call(this,t),f()}),m.addEventListener("error",function(e){t(e)})}).catch(function(e){u&&u(e)});s?(m.innerHTML=s.__html||"",f()):a?(m.textContent="string"==typeof a?a:Array.isArray(a)?a.join(""):"",f()):t&&(m.src=t,p.set(t,y)),(0,d.setAttributesFromProps)(m,e),"worker"===o&&m.setAttribute("type","text/partytown"),m.setAttribute("data-nscript",o),c&&(e=>{if(l.default.preinit)return e.forEach(e=>{l.default.preinit(e,{as:"style"})});if("u">typeof window){let t=document.head;e.forEach(e=>{let r=document.createElement("link");r.type="text/css",r.rel="stylesheet",r.href=e,t.appendChild(r)})}})(c),document.body.appendChild(m)};function y(e){let{strategy:t="afterInteractive"}=e;"lazyOnload"===t?window.addEventListener("load",()=>{(0,h.requestIdleCallback)(()=>m(e))}):m(e)}function v(e){e.forEach(y),[...document.querySelectorAll('[data-nscript="beforeInteractive"]'),...document.querySelectorAll('[data-nscript="beforePageRender"]')].forEach(e=>{let t=e.id||e.getAttribute("src");g.add(t)})}function b(e){let{id:t,src:r="",onLoad:i=()=>{},onReady:n=null,strategy:s="afterInteractive",onError:a,stylesheets:d,...p}=e,{updateScripts:y,scripts:v,getIsSsr:b,appDir:_,nonce:E}=(0,u.useContext)(c.HeadManagerContext);E=p.nonce||E;let S=(0,u.useRef)(!1);(0,u.useEffect)(()=>{let e=t||r;S.current||(n&&e&&g.has(e)&&n(),S.current=!0)},[n,t,r]);let x=(0,u.useRef)(!1);if((0,u.useEffect)(()=>{if(!x.current){if("afterInteractive"===s)m(e);else"lazyOnload"===s&&("complete"===document.readyState?(0,h.requestIdleCallback)(()=>m(e)):window.addEventListener("load",()=>{(0,h.requestIdleCallback)(()=>m(e))}));x.current=!0}},[e,s]),("beforeInteractive"===s||"worker"===s)&&(y?(v[s]=(v[s]||[]).concat([{id:t,src:r,onLoad:i,onReady:n,onError:a,...p,nonce:E}]),y(v)):b&&b()?g.add(t||r):b&&!b()&&m({...e,nonce:E})),_){if(d&&d.forEach(e=>{l.default.preinit(e,{as:"style"})}),"beforeInteractive"===s)if(!r)return p.dangerouslySetInnerHTML&&(p.children=p.dangerouslySetInnerHTML.__html,delete p.dangerouslySetInnerHTML),(0,o.jsx)("script",{nonce:E,dangerouslySetInnerHTML:{__html:`(self.__next_s=self.__next_s||[]).push(${(0,f.htmlEscapeJsonString)(JSON.stringify([0,{...p,id:t}]))})`}});else return l.default.preload(r,p.integrity?{as:"script",integrity:p.integrity,nonce:E,crossOrigin:p.crossOrigin}:{as:"script",nonce:E,crossOrigin:p.crossOrigin}),(0,o.jsx)("script",{nonce:E,dangerouslySetInnerHTML:{__html:`(self.__next_s=self.__next_s||[]).push(${(0,f.htmlEscapeJsonString)(JSON.stringify([r,{...p,id:t}]))})`}});"afterInteractive"===s&&r&&l.default.preload(r,p.integrity?{as:"script",integrity:p.integrity,nonce:E,crossOrigin:p.crossOrigin}:{as:"script",nonce:E,crossOrigin:p.crossOrigin})}return null}Object.defineProperty(b,"__nextScript",{value:!0});let _=b;("function"==typeof r.default||"object"==typeof r.default&&null!==r.default)&&void 0===r.default.__esModule&&(Object.defineProperty(r.default,"__esMo
1126dule",{value:!0}),Object.assign(r.default,r),t.exports=r.default)},3303,(e,t,r)=>{t.exports=e.r(479520)},315902,(e,t,r)=>{e.e,t.exports=function(e,t){t.prototype.isSameOrAfter=function(e,t){return this.isSame(e,t)||this.isAfter(e,t)}}},178117,(e,t,r)=>{e.e,t.exports=function(e,t){t.prototype.isSameOrBefore=function(e,t){return this.isSame(e,t)||this.isBefore(e,t)}}},618876,(e,t,r)=>{e.e,t.exports=function(e,t,r){t.prototype.isBetween=function(e,t,i,n){var s=r(e),a=r(t),o="("===(n=n||"()")[0],l=")"===n[1];return(o?this.isAfter(s,i):!this.isBefore(s,i))&&(l?this.isBefore(a,i):!this.isAfter(a,i))||(o?this.isBefore(s,i):!this.isAfter(s,i))&&(l?this.isAfter(a,i):!this.isBefore(a,i))}}},685712,(e,t,r)=>{e.e,t.exports=function(e,t,r){var i="h:mm A",n={lastDay:"[Yesterday at] "+i,sameDay:"[Today at] "+i,nextDay:"[Tomorrow at] "+i,nextWeek:"dddd [at] "+i,lastWeek:"[Last] dddd [at] "+i,sameElse:"MM/DD/YYYY"};t.prototype.calendar=function(e,t){var i=t||this.$locale().calendar||n,s=r(e||void 0).startOf("d"),a=this.diff(s,"d",!0),o="sameElse",l=a<-6?o:a<-1?"lastWeek":a<0?"lastDay":a<1?"sameDay":a<2?"nextDay":a<7?"nextWeek":o,u=i[l]||n[l];return"function"==typeof u?u.call(this,r()):this.format(u)}}},235971,(e,t,r)=>{e.e,t.exports=function(e,t,r){var i=t.prototype,n=function(e){return e&&(e.indexOf?e:e.s)},s=function(e,t,r,i,s){var a=e.name?e:e.$locale(),o=n(a[t]),l=n(a[r]),u=o||l.map(function(e){return e.slice(0,i)});if(!s)return u;var c=a.weekStart;return u.map(function(e,t){return u[(t+(c||0))%7]})},a=function(){return r.Ls[r.locale()]},o=function(e,t){return e.formats[t]||e.formats[t.toUpperCase()].replace(/(\[[^\]]+])|(MMMM|MM|DD|dddd)/g,function(e,t,r){return t||r.slice(1)})},l=function(){var e=this;return{months:function(t){return t?t.format("MMMM"):s(e,"months")},monthsShort:function(t){return t?t.format("MMM"):s(e,"monthsShort","months",3)},firstDayOfWeek:function(){return e.$locale().weekStart||0},weekdays:function(t){return t?t.format("dddd"):s(e,"weekdays")},weekdaysMin:function(t){return t?t.format("dd"):s(e,"weekdaysMin","weekdays",2)},weekdaysShort:function(t){return t?t.format("ddd"):s(e,"weekdaysShort","weekdays",3)},longDateFormat:function(t){return o(e.$locale(),t)},meridiem:this.$locale().meridiem,ordinal:this.$locale().ordinal}};i.localeData=function(){return l.bind(this)()},r.localeData=function(){var e=a();return{firstDayOfWeek:function(){return e.weekStart||0},weekdays:function(){return r.weekdays()},weekdaysShort:function(){return r.weekdaysShort()},weekdaysMin:function(){return r.weekdaysMin()},months:function(){return r.months()},monthsShort:function(){return r.monthsShort()},longDateFormat:function(t){return o(e,t)},meridiem:e.meridiem,ordinal:e.ordinal}},r.months=function(){return s(a(),"months")},r.monthsShort=function(){return s(a(),"monthsShort","months",3)},r.weekdays=function(e){return s(a(),"weekdays",null,null,e)},r.weekdaysShort=function(e){return s(a(),"weekdaysShort","weekdays",3,e)},r.weekdaysMin=function(e){return s(a(),"weekdaysMin","weekdays",2,e)}}},74170,(e,t,r)=>{e.e,t.exports=function(e,t,r){var i=function(e,t){if(!t||!t.length||1===t.length&&!t[0]||1===t.length&&Array.isArray(t[0])&&!t[0].length)return null;1===t.length&&t[0].length>0&&(t=t[0]),r=(t=t.filter(function(e){return e}))[0];for(var r,i=1;i<t.length;i+=1)t[i].isValid()&&!t[i][e](r)||(r=t[i]);return r};r.max=function(){var e=[].slice.call(arguments,0);return i("isAfter",e)},r.min=function(){var e=[].slice.call(arguments,0);return i("isBefore",e)}}},346628,(e,t,r)=>{e.e,t.exports=function(){"use strict";var e={LTS:"h:mm:ss A",LT:"h:mm A",L:"MM/DD/YYYY",LL:"MMMM D, YYYY",LLL:"MMMM D, YYYY h:mm A",LLLL:"dddd, MMMM D, YYYY h:mm A"},t=/(\[[^[]*\])|([-_:/.,()\s]+)|(A|a|Q|YYYY|YY?|ww?|MM?M?M?|Do|DD?|hh?|HH?|mm?|ss?|S{1,3}|z|ZZ?)/g,r=/\d/,i=/\d\d/,n=/\d\d?/,s=/\d*[^-_:/,()\s\d]+/,a={},o=function(e){return(e*=1)+(e>68?1900:2e3)},l=function(e){return function(t){this[e]=+t}},u=[/[+-]\d\d:?(\d\d)?|Z/,function(e){(this.zone||(this.zone={})).offset=function(e){if(!e||"Z"===e)return 0;var t=e.match(/([+-]|\d\d)/g),r=60*t[1]+(+t[2]||0);return 0===r?0:"+"===t[0]?-r:r}(e)}],c=function(e){var t=a[e];return t&&(t.indexOf?t:t.s.concat(t.f))},d=function(e,t){var r,i=a.meridiem;if(i){for(var n=1;n<=24;n+=1)if(e.indexOf(i(n,0,t))>-1){r=n>12;break}}else r=e===(t?"pm":"PM");return r},h={A:[s,function(e){this.afternoon=d(e,!1)}],a:[s,function(e){this.afternoon=d(e,!0)}],Q:[r,function(e){this.month=3*(e-1)+1}],S:[r,function(e){this.milliseconds=100*e}],SS:[i,function(e){this.milliseconds=10*e}],SSS:[/\d{3}/,function(e){this.milliseconds=+e}],s:[n,l("seconds")],ss:[n,l("seconds")],m:[n,l("minutes")],mm:[n,l("minutes")],H:[n,l("hours")],h:[n,l("hours")],HH:[n,l("hours")],hh:[n,l("hours")],D:[n,l("day")],DD:[i,l("day")],Do:[s,function(e){var t=a.ordinal,r=e.match(/\d+/);if(this.day=r[0],t)for(var i=1;i<=31;i+=1)t(i).replace(/\[|\]/g,"")===e&&(this.day=i)}],w:[n,l("week")],ww:[i,l("week")],M:[n,l("month")],MM:[i,l("month")],MM
vendor: 2,118 bytes, line 1126
1126M:[s,function(e){var t=c("months"),r=(c("monthsShort")||t.map(function(e){return e.slice(0,3)})).indexOf(e)+1;if(r<1)throw Error();this.month=r%12||r}],MMMM:[s,function(e){var t=c("months").indexOf(e)+1;if(t<1)throw Error();this.month=t%12||t}],Y:[/[+-]?\d+/,l("year")],YY:[i,function(e){this.year=o(e)}],YYYY:[/\d{4}/,l("year")],Z:u,ZZ:u};return function(r,i,n){n.p.customParseFormat=!0,r&&r.parseTwoDigitYear&&(o=r.parseTwoDigitYear);var s=i.prototype,l=s.parse;s.parse=function(r){var i=r.date,s=r.utc,o=r.args;this.$u=s;var u=o[1];if("string"==typeof u){var c=!0===o[2],d=!0===o[3],f=o[2];d&&(f=o[2]),a=this.$locale(),!c&&f&&(a=n.Ls[f]),this.$d=function(r,i,n,s){try{if(["x","X"].indexOf(i)>-1)return new Date(("X"===i?1e3:1)*r);var o=(function(r){var i,n;i=r,n=a&&a.formats;for(var s=(r=i.replace(/(\[[^\]]+])|(LTS?|l{1,4}|L{1,4})/g,function(t,r,i){var s=i&&i.toUpperCase();return r||n[i]||e[i]||n[s].replace(/(\[[^\]]+])|(MMMM|MM|DD|dddd)/g,function(e,t,r){return t||r.slice(1)})})).match(t),o=s.length,l=0;l<o;l+=1){var u=s[l],c=h[u],d=c&&c[0],f=c&&c[1];s[l]=f?{regex:d,parser:f}:u.replace(/^\[|\]$/g,"")}return function(e){for(var t={},r=0,i=0;r<o;r+=1){var n=s[r];if("string"==typeof n)i+=n.length;else{var a=n.regex,l=n.parser,u=e.slice(i),c=a.exec(u)[0];l.call(t,c),e=e.replace(c,"")}}return function(e){var t=e.afternoon;if(void 0!==t){var r=e.hours;t?r<12&&(e.hours+=12):12===r&&(e.hours=0),delete e.afternoon}}(t),t}})(i)(r),l=o.year,u=o.month,c=o.day,d=o.hours,f=o.minutes,p=o.seconds,g=o.milliseconds,m=o.zone,y=o.week,v=new Date,b=c||(l||u?1:v.getDate()),_=l||v.getFullYear(),E=0;l&&!u||(E=u>0?u-1:v.getMonth());var S,x=d||0,T=f||0,w=p||0,A=g||0;return m?new Date(Date.UTC(_,E,b,x,T,w,A+60*m.offset*1e3)):n?new Date(Date.UTC(_,E,b,x,T,w,A)):(S=new Date(_,E,b,x,T,w,A),y&&(S=s(S).week(y).toDate()),S)}catch(e){return new Date("")}}(i,u,s,n),this.init(),f&&!0!==f&&(this.$L=this.locale(f).$L),(c||d)&&i!=this.format(u)&&(this.$d=new Date("")),a={}}else if(u instanceof Array)for(var p=u.length,g=1;g<=p;g+=1){o[1]=u[g-1];var m=n.apply(this,o);if(m.isValid()){this.$d=m.$d,this.$L=m.$L,this.init();break}
1126g===p&&(this.$d=new Date(""))}else l.call(this,r)}}}()},564928,e=>{"use strict";var t,r,i,n,s,a,o,l,u,c=e.i(843476),d=e.i(271645),h=e.i(419408),f=e.i(384843),p=e.i(910573);let g=(0,d.createContext)({isSubnav:!1,setHeight:e=>{},height:0}),m=e.r(873017).createRelayEnvironment;var y=e.i(997053),v=e.i(312207),b=e.i(4154);let _=y.css` 1127 display: flex; 1128 flex-direction: column; 1129 justify-content: space-between; 1130 width: 18px; 1131 height: 14px; 1132 padding: 0; 1133`,E=y.default.button.withConfig({displayName:"Hamburger__Wrapper",componentId:"sc-17277da1-0"})` 1134 ${_}; 1135 cursor: pointer; 1136 background: transparent; 1137 border: 0; 1138`,S=y.default.span.withConfig({displayName:"Hamburger__IconWrapper",componentId:"sc-17277da1-1"})` 1139 ${_}; 1140`,x=y.default.span.withConfig({displayName:"Hamburger__Line",componentId:"sc-17277da1-2"})` 1141 width: 100%; 1142 height: 1px; 1143 background: currentColor; 1144 transition: transform 300ms; 1145 1146 &:nth-child(1) { 1147 ${e=>e.animate&&y.css` 1148 transform: rotate(45deg); 1149 transform-origin: left; 1150 `} 1151 } 1152 1153 &:nth-child(2) { 1154 ${e=>e.animate&&y.css` 1155 transform: translateX(100%); 1156 opacity: 0; 1157 transition: 1158 transform 300ms, 1159 opacity 150ms; 1160 `} 1161 } 1162 1163 &:nth-child(3) { 1164 ${e=>e.animate&&y.css` 1165 transform: rotate(-45deg); 1166 transform-origin: left; 1167 `} 1168 } 1169`;var T=e.i(417734),w=e.i(94332),A=e.i(838478),R=e.i(456780),I=e.i(408717);let k=y.default.ul.withConfig({displayName:"UserMenu__Wrapper",componentId:"sc-1c076da0-0"})` 1170 display: flex; 1171 justify-self: flex-end; 1172 flex-direction: column-reverse; 1173 align-items: center; 1174 padding: 0 24px; 1175 border-left: 1px solid ${e=>e.theme.color.gold}; 1176 1177 ${w.mq.mdmax} { 1178 & > li:first-child { 1179 margin-bottom: 0; 1180 } 1181 } 1182 1183 ${w.mq.md} { 1184 flex-direction: row; 1185 width: auto; 1186 margin-left: auto; 1187 border: none; 1188 padding: 0; 1189 } 1190 1191 ${w.mq.lg} { 1192 margin-left: auto; 1193 } 1194`,C=(0,y.default)(b.Icon).withConfig({displayName:"UserMenu__StyledIcon",componentId:"sc-1c076da0-1"})` 1195 width: 24px; 1196 height: 24px; 1197 1198 ${w.mq.md} { 1199 width: 18px; 1200 height: 18px; 1201 } 1202`,D=y.default.div.withConfig({displayName:"UserMenu__UserLink",componentId:"sc-1c076da0-2"})` 1203 display: flex; 1204 flex-direction: column; 1205 align-items: center; 1206 ${w.mq.md} { 1207 flex-direction: row; 1208 } 1209`,L=e=>{let t={...e};return delete t.locale,delete t.slug,t},O=({mainMenu:e,searchBtnRef:t,setSearchOpened:r,locale:i,router:n})=>{let s=(0,d.useContext)(y.ThemeContext)??A.theme,{page:a,locale2:o,currentUrl:l}=(0,d.useContext)(T.AppContext),{slug2:u}=(0,d.useContext)(p.SlugContext),[h,f]=(0,d.useState)(),[g,m]=(0,d.useState)(()=>L(n.query));return(0,d.useEffect)(()=>{let e=(0,I.getGlobalInfo)();e&&f(e),(0,I.loadGlobalInfo)().then(e=>e&&f(e))},[]),(0,d.useEffect)(()=>{m(L(window.location.search.slice(1).split("&").reduce((e,t)=>{let[r,i]=t.split("=");return r&&(e[r]=i?decodeURIComponent(i.replace(/\+/g," ")):""),e},{})))},[n.asPath]),(0,c.jsxs)(k,{children:[(0,c.jsx)(U,{noMargin:!0,children:(0,c.jsx)("button",{onClick:()=>{r(!0)},ref:t,title:(0,R.getAccessibilityLabel)("search",i),"aria-label":(0,R.getAccessibilityLabel)("search",i),children:(0,c.jsx)(C,{name:"search",color:s.color.gold})})}),e&&(0,c.jsx)(U,{user:!0,children:(0,c.jsx)(v.Link,{page:e.handicappedPeople,title:(0,R.getAccessibilityLabel)("disability_info",i),ariaLabel:(0,R.getAccessibilityLabel)("disability_info",i),children:(0,c.jsx)(C,{name:"handicap",color:s.color.gold})})}),e&&(0,c.jsx)(U,{user:!0,children:(0,c.jsx)(v.Link,{page:e.parking,title:(0,R.getAccessibilityLabel)("parking",i),ariaLabel:(0,R.getAccessibilityLabel)("parking",i),children:(0,c.jsx)(C,{name:"parking-simple",color:s.color.gold})})}),(0,c.jsx)(U,{user:!0,children:h?(0,c.jsx)(v.Link,{href:(0,I.getCartUrl)(),title:(0,R.getAccessibilityLabel)("shopping_cart",i),ariaLabel:(0,R.getAccessibilityLabel)("shopping_cart",i),onClick:e=>{h&&(e.preventDefault(),window.location.href=(0,I.getAccountUrl)())},children:(0,c.jsxs)(D,{children:[(0,c.jsx)(C,{name:"basket",color:s.color.gold}),(0,I.getCartItemCount)()>0&&(0,c.jsx)(z,{children:`${(0,I.getCartPrice)()}KÄ (${(0,I.getCartItemCount)()}\u00A0ks)`})]})}):null}),(0,c.jsx)(U,{user:!0,children:h&&(0,I.getUserFullName)().length>0?(0,c.jsx)("a",{href:h?(0,I.getAccountUrl)():void 0,title:(0,R.getAccessibilityLabel)("user_account",i),"aria-label":(0,R.getAccessibilityLabel)("user_account",i),onClick:e=>{h&&(e.preventDefault(),window.location.href=(0,I.getAccountUrl)())},children:(0,c.jsxs)(D,{children:[(0,c.jsx)(C,{name:"user",color:s.color.gold}),(0,c.jsx)(z,{children:(0,I.getUserFullName)()})]})}):e&&(0,c.jsx)(v.Link,{page:e.logIn,params:g.target?{target:String(g.target)}:l?{target:l}:{},title:(0,R.getAccessibilityLabel)("log_in",i),ariaLabel:(0,R.getAccessibilityLabel)("log_in",i),plain:!0,children:(0,c.jsx)(D,{children:(0,c.jsx)(C,{name:"user",color:s.color.gold})})})}),o&&(0,c.jsx)(U,{user:!0,children:(0,c.jsx)(v.Link,{hoverFull:!0,page:{url:a?.url2||a?.parent?.url||a?.parent?.parent?.url||""},locale:o,params:a?.url2?.includes("slug")?{slug:u}:g,ariaLabel:(0,R.getAccessibilityLabel)("en"===o?"language_switch_en":"language_switch_cs",o),children:o.toUpperCase()})},"LanguageSwitcher")]})},P=y.default.div.withConfig({displayName:"Mq__Wrapper",componentId:"sc-c3b144b3-0"})` 1210 width: 100%; 1211 ${e=>e.sm&&y.css` 1212 display: none; 1213 ${w.mq.sm} { 1214 display: flex; 1215 } 1216 `} 1217 1218 ${e=>e.smmax&&y.css` 1219 display: flex; 1220 ${w.mq.smmax} { 1221 display: none; 1222 } 1223 `} 1224 1225 ${e=>e.md&&y.css` 1226 display: none; 1227 ${w.mq.md} { 1228 display: flex; 1229 } 1230 `} 1231 1232 ${e=>e.mdmax&&y.css` 1233 display: flex; 1234 ${w.mq.md} { 1235 display: none; 1236 } 1237 `} 1238 1239 ${e=>e.lg&&y.css` 1240 display: none; 1241 ${w.mq.lg} { 1242 display: flex; 1243 } 1244 `} 1245 1246 ${e=>e.lgmax&&y.css` 1247 display: flex; 1248 ${w.mq.lgmax} { 1249 display: none; 1250 } 1251 `} 1252`,F=({children:e})=>(0,c.jsx)(P,{md:!0,children:e}),N=({children:e})=>(0,c.jsx)(P,{mdmax:!0,children:e}),M=(0,y.default)(({className:e,active:t})=>(0,c.jsxs)(S,{className:e,"aria-hidden":"true",children:[(0,c.jsx)(x,{animate:t}),(0,c.jsx)(x,{animate:t}),(0,c.jsx)(x,{animate:t})]})).withConfig({displayName:"NavBar__StyledHamburger",componentId:"sc-38721c97-0"})` 1253 color: currentColor; 1254`,j=y.default.div.withConfig({displayName:"NavBar__Wrapper",componentId:"sc-38721c97-1"})` 1255 display: flex; 1256 align-items: center; 1257 margin-left: auto; 1258 1259 ${w.mq.md} { 1260 width: 100%; 1261 justify-content: space-between; 1262 } 1263`,$=y.default.div.withConfig({displayName:"NavBar__MenuWrapper",componentId:"sc-38721c97-2"})` 1264 display: flex; 1265 justify-content: flex-start; 1266`,U=y.default.li.withConfig({displayName:"NavBar__MenuItem",componentId:"sc-38721c97-3"})` 1267 margin-bottom: 24px; 1268 list-style: none; 1269 position: relative; 1270 & > a, 1271 & > button, 1272 & > div { 1273 display: flex; 1274 font-size: 14px; 1275 text-transform: uppercase; 1276 padding: 0; 1277 } 1278 1279 &::after { 1280 ${e=>e.highlighted&&y.css` 1281 content: ''; 1282 display: block; 1283 width: 8px; 1284 height: 8px; 1285 border-radius: 100%; 1286 background: ${e.theme.color.gold}; 1287 position: absolute; 1288 right: -8px; 1289 top: -2px; 1290 `} 1291 } 1292 1293 ${e=>e.isActive?y.css` 1294 color: ${e.theme.color.gold}; 1295 `:""} 1296 1297 ${w.mq.md} { 1298 margin-bottom: 0; 1299 transform: translateY(1px); 1300 margin-left: 16px; 1301 1302 & > a, 1303 & > button, 1304 & > div { 1305 font-size: 14px; 1306 } 1307 } 1308 1309 @media (min-width: 1100px) { 1310 margin-left: 24px; 1311 1312 &::after { 1313 right: -10px; 1314 } 1315 } 1316 1317 ${w.mq.lg} { 1318 margin-left: 2vw; 1319 1320 &::after { 1321 right: -13px; 1322 } 1323 } 1324`,B=y.default.ul.withConfig({displayName:"NavBar__Menu",componentId:"sc-38721c97-4"})` 1325 display: flex; 1326 flex-direction: column; 1327 white-space: nowrap; 1328 1329 ${w.mq.mdmax} { 1330 align-items: flex-start; 1331 1332 ${U}::after { 1333 right: -13px; 1334 } 1335 } 1336 1337 ${w.mq.md} { 1338 flex-direction: row; 1339 align-items: center; 1340 } 1341`,V=y.default.span.withConfig({displayName:"NavBar__Label",componentId:"sc-38721c97-5"})` 1342 display: inline-block; 1343 min-width: 44px; 1344 margin-right: 14px; 1345 transform: translateY(1px); 1346 color: inherit; 1347`,G=(0,y.default)(b.Icon).withConfig({displayName:"NavBar__StyledIcon",componentId:"sc-38721c97-6"})` 1348 width: 16px; 1349 color: ${e=>e.theme.color.gold}; 1350`,q=y.default.button.withConfig({displayName:"NavBar__MenuButton",componentId:"sc-38721c97-7"})` 1351 display: none;
1352 align-items: center; 1353 height: 100%; 1354 margin-left: 14px; 1355 padding: 18px; 1356 text-transform: uppercase; 1357 font-size: 14px; 1358 color: ${({theme:e,$dark:t})=>t?e.color.white:e.color.black}; 1359 cursor: pointer; 1360 transition: all 300ms; 1361 background: transparent; 1362 border: 0; 1363 1364 ${w.mq.md} { 1365 display: flex; 1366 } 1367 1368 ${w.mq.lg} { 1369 margin-left: 32px; 1370 } 1371 @media not all and (pointer: coarse) { 1372 &:hover { 1373 color: #fff; 1374 background: ${e=>e.theme.color.gold}; 1375 1376 ${M} { 1377 color: #fff; 1378 } 1379 } 1380 } 1381 1382 ${e=>e.menuOpened&&y.css` 1383 color: #fff; 1384 background: ${e=>e.theme.color.gold}; 1385 1386 ${G} { 1387 color: #fff; 1388 } 1389 1390 ${M} { 1391 color: #fff; 1392 } 1393 `}; 1394`,H=(0,y.default)(({className:e,active:t,onClick:r,ariaLabel:i,ariaExpanded:n})=>(0,c.jsxs)(E,{className:e,onClick:r,type:"button","aria-label":i,"aria-expanded":n,children:[(0,c.jsx)(x,{animate:t}),(0,c.jsx)(x,{animate:t}),(0,c.jsx)(x,{animate:t})]})).withConfig({displayName:"NavBar__MobileHamburger",componentId:"sc-38721c97-8"})` 1395 width: 50px; 1396 height: 50px; 1397 padding: 18px 16px; 1398 /* transform: translateX(16px); */ 1399`,z=y.default.div.withConfig({displayName:"NavBar__IconText",componentId:"sc-38721c97-9"})` 1400 max-width: 100px; 1401 text-align: center; 1402 ${w.mq.md} { 1403 padding-left: 10px; 1404 text-align: left; 1405 } 1406`,K=({mainMenu:e,setOpened:t,opened:r,router:i,locale:n,dark:s})=>(0,c.jsxs)($,{children:[(0,c.jsx)(B,{id:"main-menu",children:e?.links.map((e,t)=>"%other"===e.__typename?(0,c.jsx)(c.Fragment,{}):(0,c.jsx)(U,{gray:!0,isActive:i.asPath.startsWith(`/${n}/${e.url}`),highlighted:e.highlighted,children:(0,c.jsx)(v.Link,{thickLine:!0,hoverFull:!0,page:e})},`MenuItem_${t}`))}),(0,c.jsxs)(q,{menuOpened:r,$dark:s,onClick:()=>{t(!r)},className:"js-desktop-hamburger",type:"button","aria-label":r?e?.searchClose??(0,R.getAccessibilityLabel)("close_menu",n):e?.popupButtonLabel??(0,R.getAccessibilityLabel)("open_menu",n),"aria-expanded":r,"aria-controls":"main-menu",children:[e&&(0,c.jsx)(V,{children:r?e.searchClose:e.popupButtonLabel}),(0,c.jsx)(M,{active:r})]})]}),W=({mainMenu:e,setOpened:t,opened:r,searchBtnRef:i,setSearchOpened:n,router:s,locale:a,dark:o})=>(0,c.jsxs)(j,{children:[(0,c.jsxs)(F,{children:[K({mainMenu:e,setOpened:t,opened:r,router:s,locale:a,dark:o}),(0,c.jsx)(O,{mainMenu:e,searchBtnRef:i,setSearchOpened:n,router:s,locale:a})]}),(0,c.jsx)(N,{children:(0,c.jsx)(H,{active:r,className:"js-mobile-hamburger",onClick:()=>t(!r),ariaLabel:r?(0,R.getAccessibilityLabel)("close_menu",a):(0,R.getAccessibilityLabel)("open_menu",a),ariaExpanded:r})})]});var Y=e.i(585642),Y=Y,Q=e.i(185005),X=function(){return(X=Object.assign||function(e){for(var t,r=1,i=arguments.length;r<i;r++)for(var n in t=arguments[r])Object.prototype.hasOwnProperty.call(t,n)&&(e[n]=t[n]);return e}).apply(this,arguments)};function J(e,t){var r={};for(var i in e)Object.prototype.hasOwnProperty.call(e,i)&&0>t.indexOf(i)&&(r[i]=e[i]);if(null!=e&&"function"==typeof Object.getOwnPropertySymbols)for(var n=0,i=Object.getOwnPropertySymbols(e);n<i.length;n++)0>t.indexOf(i[n])&&Object.prototype.propertyIsEnumerable.call(e,i[n])&&(r[i[n]]=e[i[n]]);return r}var Z=("function"==typeof SuppressedError&&SuppressedError,"right-scroll-bar-position"),ee="width-before-scroll-bar";function et(e,t){return"function"==typeof e?e(t):e&&(e.current=t),e}var er="u">typeof window?d.useLayoutEffect:d.useEffect,ei=new WeakMap,en=(void 0===t&&(t={}),(void 0===r&&(r=function(e){return e}),i=[],n=!1,s={read:function(){if(n)throw Error("Sidecar: could not `read` from an `assigned` medium. `read` could be used only with `useMedium`.");return i.length?i[i.length-1]:null},useMedium:function(e){var t=r(e,n);return i.push(t),function(){i=i.filter(function(e){return e!==t})}},assignSyncMedium:function(e){for(n=!0;i.length;){var t=i;i=[],t.forEach(e)}i={push:function(t){return e(t)},filter:function(){return i}}},assignMedium:function(e){n=!0;var t=[];if(i.length){var r=i;i=[],r.forEach(e),t=i}var s=function(){var r=t;t=[],r.forEach(e)},a=function(){return Promise.resolve().then(s)};a(),i={push:function(e){t.push(e),a()},filter:function(e){return t=t.filter(e),i}}}}).options=X({async:!0,ssr:!1},t),s),es=function(){},ea=d.forwardRef(function(e,t){var r,i,n,s,a=d.useRef(null),o=d.useState({onScrollCapture:es,onWheelCapture:es,onTouchMoveCapture:es}),l=o[0],u=o[1],c=e.forwardProps,h=e.children,f=e.className,p=e.removeScrollBar,g=e.enabled,m=e.shards,y=e.sideCar,v=e.noRelative,b=e.noIsolation,_=e.inert,E=e.allowPinchZoom,S=e.as,x=e.gapMode,T=J(e,["forwardProps","children","className","removeScrollBar","enabled","shards","sideCar","noRelative","noIsolation","inert","allowPinchZoom","as","gapMode"]),w=(r=[a,t],i=function(e){return r.forEach(function(t){return et(t,e)})},(n=(0,d.useState)(function(){return{value:null,callback:i,facade:{get current(){return n.value},set current(value){var e=n.value;e!==value&&(n.value=value,n.callback(value,e))}}}})[0]).callback=i,s=n.facade,er(function(){var e=ei.get(s);if(e){var t=new Set(e),i=new Set(r),n=s.current;t.forEach(function(e){i.has(e)||et(e,null)}
1406),i.forEach(function(e){t.has(e)||et(e,n)})}ei.set(s,r)},[r]),s),A=X(X({},T),l);return d.createElement(d.Fragment,null,g&&d.createElement(y,{sideCar:en,removeScrollBar:p,shards:m,noRelative:v,noIsolation:b,inert:_,setCallbacks:u,allowPinchZoom:!!E,lockRef:a,gapMode:x}),c?d.cloneElement(d.Children.only(h),X(X({},A),{ref:w})):d.createElement(void 0===S?"div":S,X({},A,{className:f,ref:w}),h))});ea.defaultProps={enabled:!0,removeScrollBar:!0,inert:!1},ea.classNames={fullWidth:ee,zeroRight:Z};var eo=function(e){var t=e.sideCar,r=J(e,["sideCar"]);if(!t)throw Error("Sidecar: please provide `sideCar` property to import the right car");var i=t.read();if(!i)throw Error("Sidecar medium not found");return d.createElement(i,X({},r))};eo.isSideCarExport=!0;var el=function(){var e=0,t=null;return{add:function(r){if(0==e&&(t=function(){if(!document)return null;var e=document.createElement("style");e.type="text/css";var t=o||("u">typeof __webpack_nonce__?__webpack_nonce__:void 0);return t&&e.setAttribute("nonce",t),e}())){var i,n;(i=t).styleSheet?i.styleSheet.cssText=r:i.appendChild(document.createTextNode(r)),n=t,(document.head||document.getElementsByTagName("head")[0]).appendChild(n)}e++},remove:function(){--e||!t||(t.parentNode&&t.parentNode.removeChild(t),t=null)}}},eu=function(){var e=el();return function(t,r){d.useEffect(function(){return e.add(t),function(){e.remove()}},[t&&r])}},ec=function(){var e=eu();return function(t){return e(t.styles,t.dynamic),null}},ed={left:0,top:0,right:0,gap:0},eh=function(e){return parseInt(e||"",10)||0},ef=function(e){var t=window.getComputedStyle(document.body),r=t["padding"===e?"paddingLeft":"marginLeft"],i=t["padding"===e?"paddingTop":"marginTop"],n=t["padding"===e?"paddingRight":"marginRight"];return[eh(r),eh(i),eh(n)]},ep=function(e){if(void 0===e&&(e="margin"),"u"<typeof window)return ed;var t=ef(e),r=document.documentElement.clientWidth,i=window.innerWidth;return{left:t[0],top:t[1],right:t[2],gap:Math.max(0,i-r+t[2]-t[0])}},eg=ec(),em="data-scroll-locked",ey=function(e,t,r,i){var n=e.left,s=e.top,a=e.right,o=e.gap;return void 0===r&&(r="margin"),"\n .".concat("with-scroll-bars-hidden"," {\n overflow: hidden ").concat(i,";\n padding-right: ").concat(o,"px ").concat(i,";\n }\n body[").concat(em,"] {\n overflow: hidden ").concat(i,";\n overscroll-behavior: contain;\n ").concat([t&&"position: relative ".concat(i,";"),"margin"===r&&"\n padding-left: ".concat(n,"px;\n padding-top: ").concat(s,"px;\n padding-right: ").concat(a,"px;\n margin-left:0;\n margin-top:0;\n margin-right: ").concat(o,"px ").concat(i,";\n "),"padding"===r&&"padding-right: ".concat(o,"px ").concat(i,";")].filter(Boolean).join(""),"\n }\n \n .").concat(Z," {\n right: ").concat(o,"px ").concat(i,";\n }\n \n .").concat(ee," {\n margin-right: ").concat(o,"px ").concat(i,";\n }\n \n .").concat(Z," .").concat(Z," {\n right: 0 ").concat(i,";\n }\n \n .").concat(ee," .").concat(ee," {\n margin-right: 0 ").concat(i,";\n }\n \n body[").concat(em,"] {\n ").concat("--removed-body-scroll-bar-size",": ").concat(o,"px;\n }\n")},ev=function(){var e=parseInt(document.body.getAttribute(em)||"0",10);return isFinite(e)?e:0},eb=function(){d.useEffect(function(){return document.body.setAttribute(em,(ev()+1).toString()),function(){var e=ev()-1;e<=0?document.body.removeAttribute(em):document.body.setAttribute(em,e.toString())}},[])},e_=function(e){var t=e.noRelative,r=e.noImportant,i=e.gapMode,n=void 0===i?"margin":i;eb();var s=d.useMemo(function(){return ep(n)},[n]);return d.createElement(eg,{styles:ey(s,!t,n,r?"":"!important")})},eE=!1;if("u">typeof window)try{var eS=Object.defineProperty({},"passive",{get:function(){return eE=!0,!0}});window.addEventListener("test",eS,eS),window.removeEventListener("test",eS,eS)}catch(e){eE=!1}var ex=!!eE&&{passive:!1},eT=function(e,t){if(!(e instanceof Element))return!1;var r=window.getComputedStyle(e);return"hidden"!==r[t]&&(r.overflowY!==r.overflowX||"TEXTAREA"===e.tagName||"visible"!==r[t])},ew=function(e,t){var r=t.ownerDocument,i=t;do{if("u">typeof ShadowRoot&&i instanceof ShadowRoot&&(i=i.host),eA(e,i)){var n=eR(e,i);if(n[1]>n[2])return!0}i=i.parentNode}while(i&&i!==r.body)return!1},eA=function(e,t){return"v"===e?eT(t,"overflowY"):eT(t,"overflowX")},eR=function(e,t){return"v"===e?[t.scrollTop,t.scrollHeight,t.clientHeight]:[t.scrollLeft,t.scrollWidth,t.clientWidth]},eI=function(e,t,r,i,n){var s,a=(s=window.getComputedStyle(t).direction,"h"===e&&"rtl"===s?-1:1),o=a*i,l=r.target,u=t.contains(l),c=!1,d=o>0,h=0,f=0;do{if(!l)break;var p=eR(e,l),g=p[0],m=p[1]-p[2]-a*g;(g||m)&&eA(e,l)&&(h+=m,f+=g);var y=l.parentNode;l=y&&y.nodeType===Node.DOCUMENT_FRAGMENT_NODE?y.host:y}while(!u&&l!==document.body||u&&(t.contains(l)||t===l))return d&&(n&&1>Math.abs(h)||!n&&o>h)?c=!0:!d&&(n&&1>Math.abs(f)||!n&&-o>f)&&(c=!0),c},ek=function(e){return"changedTouches"in e?[e.changedTouches[0].clientX,e.changedTouches[0].clientY]:[0,0]},eC=function(e){return[e.deltaX,e.deltaY]},eD=function(e){return e&&"current"in e?e.current:e},eL=0,eO=[];let eP=(a=function(e){var t=d.useRef([]),r=d.useRef([0,0]),i=d.useRef(),n=d.use
1406State(eL++)[0],s=d.useState(ec)[0],a=d.useRef(e);d.useEffect(function(){a.current=e},[e]),d.useEffect(function(){if(e.inert){document.body.classList.add("block-interactivity-".concat(n));var t=(function(e,t,r){if(r||2==arguments.length)for(var i,n=0,s=t.length;n<s;n++)!i&&n in t||(i||(i=Array.prototype.slice.call(t,0,n)),i[n]=t[n]);return e.concat(i||Array.prototype.slice.call(t))})([e.lockRef.current],(e.shards||[]).map(eD),!0).filter(Boolean);return t.forEach(function(e){return e.classList.add("allow-interactivity-".concat(n))}),function(){document.body.classList.remove("block-interactivity-".concat(n)),t.forEach(function(e){return e.classList.remove("allow-interactivity-".concat(n))})}}},[e.inert,e.lockRef.current,e.shards]);var o=d.useCallback(function(e,t){if("touches"in e&&2===e.touches.length||"wheel"===e.type&&e.ctrlKey)return!a.current.allowPinchZoom;var n,s=ek(e),o=r.current,l="deltaX"in e?e.deltaX:o[0]-s[0],u="deltaY"in e?e.deltaY:o[1]-s[1],c=e.target,d=Math.abs(l)>Math.abs(u)?"h":"v";if("touches"in e&&"h"===d&&"range"===c.type)return!1;var h=window.getSelection(),f=h&&h.anchorNode;if(f&&(f===c||f.contains(c)))return!1;var p=ew(d,c);if(!p)return!0;if(p?n=d:(n="v"===d?"h":"v",p=ew(d,c)),!p)return!1;if(!i.current&&"changedTouches"in e&&(l||u)&&(i.current=n),!n)return!0;var g=i.current||n;return eI(g,t,e,"h"===g?l:u,!0)},[]),l=d.useCallback(function(e){if(eO.length&&eO[eO.length-1]===s){var r="deltaY"in e?eC(e):ek(e),i=t.current.filter(function(t){var i;return t.name===e.type&&(t.target===e.target||e.target===t.shadowParent)&&(i=t.delta,i[0]===r[0]&&i[1]===r[1])})[0];if(i&&i.should){e.cancelable&&e.preventDefault();return}if(!i){var n=(a.current.shards||[]).map(eD).filter(Boolean).filter(function(t){return t.contains(e.target)});(n.length>0?o(e,n[0]):!a.current.noIsolation)&&e.cancelable&&e.preventDefault()}}},[]),u=d.useCallback(function(e,r,i,n){var s={name:e,delta:r,target:i,should:n,shadowParent:function(e){for(var t=null;null!==e;)e instanceof ShadowRoot&&(t=e.host,e=e.host),e=e.parentNode;return t}(i)};t.current.push(s),setTimeout(function(){t.current=t.current.filter(function(e){return e!==s})},1)},[]),c=d.useCallback(function(e){r.current=ek(e),i.current=void 0},[]),h=d.useCallback(function(t){u(t.type,eC(t),t.target,o(t,e.lockRef.current))},[]),f=d.useCallback(function(t){u(t.type,ek(t),t.target,o(t,e.lockRef.current))},[]);d.useEffect(function(){return eO.push(s),e.setCallbacks({onScrollCapture:h,onWheelCapture:h,onTouchMoveCapture:f}),document.addEventListener("wheel",l,ex),document.addEventListener("touchmove",l,ex),document.addEventListener("touchstart",c,ex),function(){eO=eO.filter(function(e){return e!==s}),document.removeEventListener("wheel",l,ex),document.removeEventListener("touchmove",l,ex),document.removeEventListener("touchstart",c,ex)}},[]);var p=e.removeScrollBar,g=e.inert;return d.createElement(d.Fragment,null,g?d.createElement(s,{styles:"\n .block-interactivity-".concat(n," {pointer-events: none;}\n .allow-interactivity-").concat(n," {pointer-events: all;}\n")}):null,p?d.createElement(e_,{noRelative:e.noRelative,gapMode:e.gapMode}):null)},en.useMedium(a),eo);var eF=d.forwardRef(function(e,t){return d.createElement(ea,X({},e,{ref:t,sideCar:eP}))});eF.classNames=ea.classNames;var eN=e.i(259087),eM=e.i(63280),ej=e.i(719631),e$=e.i(607135);let eU=y.default.div.withConfig({displayName:"Section__Wrapper",componentId:"sc-fdeab76e-0"})` 1407 margin-bottom: 32px; 1408 1409 ${w.mq.sm} { 1410 margin-bottom: 80px; 1411 } 1412`,eB=y.default.ul.withConfig({displayName:"Section__List",componentId:"sc-fdeab76e-1"})` 1413 display: flex; 1414 flex-direction: row; 1415 margin-top: 20px; 1416 padding-left: 16px; 1417 border-left: 1px solid ${e=>e.theme.color.gold}; 1418 font-weight: 700; 1419 font-size: 16px; 1420 line-height: 1; 1421 1422 ${w.mq.sm} { 1423 padding-left: 24px; 1424 font-size: 24px; 1425 } 1426 1427 ${w.mq.md} { 1428 font-size: 16px; 1429 } 1430 1431 ${w.mq.lg} { 1432 padding-left: 48px; 1433 font-size: 32px; 1434 } 1435 1436 li { 1437 display: flex; 1438 flex-direction: column; 1439 width: 25%; 1440 } 1441`,eV=(0,y.default)(b.Icon).withConfig({displayName:"Section__VenueIcon",componentId:"sc-fdeab76e-2"})` 1442 width: 48px !important; 1443 height: 48px !important; 1444 margin-bottom: 24px; 1445`,eG=(0,y.default)(b.Icon).withConfig({displayName:"Section__GenreIcon",componentId:"sc-fdeab76e-3"})` 1446 width: 24px !important; 1447 height: 24px !important; 1448 margin-bottom: 24px; 1449`,eq=(0,y.default)(v.Link).withConfig({displayName:"Section__StyledLink",componentId:"sc-fdeab76e-4"})` 1450 display: inline; 1451 1452 & > span { 1453 display: inline; 1454 flex-direction: column; 1455 } 1456`,eH=[{name:"Národnà divadlo",code:"nd"},{name:"Stavovské divadlo",code:"sd"},{name:"Státnà opera",code:"so"}
1456,{name:"Nová scéna",code:"ns"},{name:"Externà scény",code:"others-lighter"},{name:"The National Theatre",code:"nd"},{name:"The Estates Theatre",code:"sd"},{name:"The State Opera",code:"so"},{name:"The New Stage",code:"ns"},{name:"External stages",code:"others-lighter"}],ez=({popup:e,className:t,currentPath:r})=>{let{locale:i}=(0,d.useContext)(T.AppContext),n=(0,d.useContext)(y.ThemeContext)??A.theme;return(0,c.jsxs)(eU,{className:t,children:[e.title&&(0,c.jsx)(eM.Label,{children:e.title}),e.links&&(0,c.jsx)(eB,{children:e.links.map((t,s)=>{if(t.title&&("Scény"===e.title||"Stages"===e.title)){let e=eH.find(e=>e.name===t.title);return(0,c.jsxs)("li",{children:[(0,c.jsx)(eq,{noHover:!0,page:t,children:e&&(0,c.jsx)(eV,{name:e.code})}),(0,c.jsx)(eq,{thickLine:!0,page:t,color:r.startsWith(`/${i}/${t.url}`)?"gold":"black",children:(0,eN.default)(t.title.replace(" ","<br />"),e$.parserOptions)})]},`scenes_${s}`)}if(t.title&&("Soubory"===e.title||"Ensembles"===e.title)){let e=(0,ej.resolveEnsembleStyle)(t.title,n.color);return(0,c.jsxs)("li",{children:[(0,c.jsx)(eq,{noHover:!0,page:t,children:e&&(0,c.jsx)(eG,{name:e.icon,color:e.color})}),(0,c.jsx)(eq,{thickLine:!0,page:t,color:r.startsWith(`/${i}/${t.url}`)?"gold":"black",children:t.title})]},`ensembles_${s}`)}})})]})};var eK=e.i(812497);e.i(1691);var eW=e.i(190121),eY=e.i(822199),eQ=e.i(618566),eX=e.i(521534),eJ=e.i(736118);let eZ=y.default.div.withConfig({displayName:"NewsletterForm__Wrapper",componentId:"sc-a7741f59-0"})` 1457 display: flex; 1458 flex-direction: ${e=>e.inline?"row":"column"}; 1459 line-height: 1.5; 1460 max-width: 380px; 1461 1462 input[type='email'] { 1463 padding: 16px 0; 1464 height: 48px; 1465 border-bottom: 1px solid ${e=>e.theme.color.gold}; 1466 font-size: ${e=>e.theme.fz.xs}; 1467 background: transparent; 1468 color: #fff; 1469 outline: none; 1470 1471 &::placeholder { 1472 color: #fff; 1473 } 1474 } 1475 1476 input[type='submit'] { 1477 align-self: flex-end; 1478 display: block; 1479 padding: 11px 32px; 1480 border: 1px solid ${e=>e.theme.color.gold}; 1481 ${e=>!e.inline&&"border-top-width: 0"}; 1482 font-size: ${e=>e.theme.fz.xs}; 1483 color: #fff; 1484 background: transparent; 1485 -webkit-appearance: none; 1486 1487 @media not all and (pointer: coarse) { 1488 &:hover { 1489 background: ${e=>e.theme.color.gold}; 1490 } 1491 } 1492 } 1493`,e0=(0,y.default)(eF).withConfig({displayName:"Submenu__Wrapper",componentId:"sc-cc55ff33-0"})` 1494 width: 100%; 1495 height: calc(100svh - var(--header-layout-offset, 64px)); 1496 padding: 0 16px 48px; 1497 position: fixed; 1498 z-index: 0; 1499 left: 0; 1500 top: var(--header-layout-offset, 64px); 1501 background: #fff; 1502 color: #000; 1503 /* box-shadow: 0 10px 10px #9c9c9c33; */ 1504 overflow: auto; 1505 transform: translateY(-100%); 1506 visibility: hidden; 1507 pointer-events: none; 1508 1509 &.submenu-slide-entering, 1510 &.submenu-slide-entered, 1511 &.submenu-slide-exiting { 1512 visibility: visible; 1513 } 1514 1515 &.submenu-slide-entering, 1516 &.submenu-slide-entered { 1517 transform: translateY(0); 1518 pointer-events: auto; 1519 } 1520 1521 &.submenu-slide-entering, 1522 &.submenu-slide-exiting { 1523 transition: transform 300ms; 1524 } 1525 1526 &.submenu-slide-exiting { 1527 transform: translateY(-100%); 1528 pointer-events: none; 1529 } 1530 1531 ${w.mq.sm} { 1532 top: var(--header-layout-offset, 88px); 1533 height: calc(100svh - var(--header-layout-offset, 88px)); 1534 padding: 0; 1535 } 1536`,e1=y.default.div.withConfig({displayName:"Submenu__Main",componentId:"sc-cc55ff33-1"})` 1537 width: 100%; 1538`,e2=y.default.div.withConfig({displayName:"Submenu__Links",componentId:"sc-cc55ff33-2"})` 1539 display: flex; 1540 flex-direction: row; 1541 flex-wrap: wrap; 1542 width: 100%; 1543 1544 ul { 1545 margin-bottom: 24px; 1546 padding-left: 24px; 1547 border-left: 1px solid ${e=>e.theme.color.gold}; 1548 } 1549 1550 li { 1551 margin-bottom: 16px; 1552 1553 &:last-child { 1554 margin-bottom: 0; 1555 } 1556 } 1557`,e3=y.default.div.withConfig({displayName:"Submenu__LinksSection",componentId:"sc-cc55ff33-3"})` 1558 width: 50%; 1559 padding-right: 16px; 1560 1561 ${w.mq.md} { 1562 padding-right: 0; 1563 } 1564 1565 /* &:nth-child(odd) { 1566 padding-right: 68px; 1567 } */ 1568`,e4=(0,y.default)(eM.Label).withConfig({displayName:"Submenu__StyledLabel",componentId:"sc-cc55ff33-4"})` 1569 margin-bottom: 16px; 1570`,e5=y.default.div.withConfig({displayName:"Submenu__Bottom",componentId:"sc-cc55ff33-5"})` 1571 display: flex; 1572 justify-content: space-between; 1573 flex-direction: column; 1574 align-self: flex-end; 1575 width: 100vw; 1576 padding: 32px 16px; 1577 color: #fff; 1578 background: ${e=>e.theme.color.almostblack}; 1579 transform: translateX(16px); 1580 1581 ${w.mq.md} { 1582 flex-direction: row; 1583 width: 100%; 1584 padding: 48px 80px; 1585 transform: none; 1586 } 1587`,e8=y.default.div.withConfig({displayName:"Submenu__BottomSection",componentId:"sc-cc55ff33-6"})` 1588 margin-bottom: 32px; 1589 1590 ${w.mq.md} { 1591 margin-bottom: 0; 1592 padding-right: 40px; 1593 } 1594`,e6=y.default.div.withConfig({displayName:"Submenu__Inner",componentId:"sc-cc55ff33-7"})` 1595 display: flex; 1596 flex-direction: column; 1597 justify-content: space-between; 1598 width: 100%; 1599 height: auto; 1600 min-height: 100%; 1601 margin: 0 auto; 1602 padding-top: 16px; 1603 1604 ${w.mq.sm} { 1605 padding-top: 48px; 1606 } 1607 1608 ${w.mq.md} { 1609 flex-direction: row; 1610 flex-wrap: wrap; 1611 } 1612`,e7=y.default.div.withConfig({displayName:"Submenu__BottomNewsletter",componentId:"sc-cc55ff33-8"})` 1613 display: flex; 1614 flex-direction: column; 1615 1616 ${w.mq.md} { 1617 flex-direction: row; 1618 align-items: flex-end; 1619 } 1620`,e9=(0,y.default)(({inline:e,className:t,emailInput:r,buttonText:i,id:n})=>{let{locale:s,formErrors:a}=(0,d.useContext)(T.AppContext),[o,l]=(0,d.useState)(null),[u,h]=(0,d.useState)(!1),[f,p]=(0,d.useState)(0),g=d.default.createRef(),m=(0,eQ.useRouter)();if(u)return(0,c.jsxs)(eZ,{ref:g,inline:e,className:t,style:{maxWidth:f+"px"},children:["en"!==s&&"Na zadanou e-mailovou adresu jsme odeslali e-mail. V nÄm naleznete odkaz pro potvrzenà odbÄru novinek.","en"===s&&"We have sent an email to the email address you entered. There you will find a link to confirm the news subscription."]});async function y(e,t){t.setSubmitting(!0);try{let t=new URLSearchParams({email:e.email});m.push(`/${e.locale}/newsletter?${t.toString()}`)}catch(e){console.log(e),l("FormuláŠse nepodaÅilo odeslat")}finally{t.setSubmitting(!1)}}let v=eW.object().shape({email:eY.string().email((0,eX.formErrorsExists)(a,eJ.FormErrorsTypes.EMAIL_FORMAT)).required((0,eX.formErrorsExists)(a,eJ.FormErrorsTypes.REQUIRED))});return(0,c.jsx)(eK.Formik,{initialValues:{email:"",locale:s??"cs"},onSubmit:y,validationSchema:v,children:({submitForm:s,isSubmitting:a,errors:o})=>(0,c.jsx)("form",{action:"/api/newsletter/save",method:"post",onSubmit:e=>{e.preventDefault(),a||s()},children:(0,c.jsxs)(eZ,{ref:g,inline:e,className:t,children:[(0,c.jsx)(eK.Field,{type:"email",name:"email",placeholder:r,id:n}),(0,c.jsx)("input",{type:"submit",value:i})]})})})}).withConfig({displayName:"Submenu__StyledNewsletterForm",componentId:"sc-cc55ff33-9"})` 1621 margin-top: 16px; 1622 1623 input[type='email'] { 1624 width: 100%; 1625 } 1626 1627 ${w.mq.md} { 1628 margin-left: 40px; 1629 margin-top: 0; 1630 1631 input[type='email'] { 1632 width: auto; 1633 } 1634 } 1635`,te=(0,y.default)(Q.Row).withConfig({displayName:"Submenu__StyledRow",componentId:"sc-cc55ff33-10"})` 1636 width: 100%; 1637`,tt={entered:"submenu-slide-entered",entering:"submenu-slide-entering",exited:"submenu-slide-exited",exiting:"submenu-slide-exiting",unmounted:"submenu-slide-exited"},tr=(0,y.default)(Q.Row).withConfig({displayName:"Submenu__FirstRow",componentId:"sc-cc55ff33-11"})` 1638 display: flex; 1639 justify-content: space-between; 1640 width: 100%; 1641 1642 ${w.mq.md} { 1643 display: none; 1644 } 1645`,ti=({opened:e,setOpened:t,mainMenu:r,searchBtnRef:i,setSearchOpened:n,router:s,locale:a})=>{let o=(0,d.useRef)(null),l=r?.popup?.find(e=>"ScenesMatrixRecord"===e.__typename),u=r?.popup?.find(e=>"EnsemblesMatrixRecord"===e.__typename),h=r?.popup?.filter(e=>"LinksMatrixRecord"===e.__typename),f=r?.footer?.filter(e=>"OurContactRecord"===e.__typename),p=r?.footer?.find(e=>"NewsletterRecord"===e.__typename);return(0,c.jsx)(Q.Container,{children:(0,c.jsx)(Y.default,{nodeRef:o,in:e,timeout:300,children:d=>(0,c.jsx)(e0,{ref:o,className:tt[d],enabled:e,removeScrollBar:!1,"aria-hidden":!e,"aria-modal":"true","aria-label":(0,R.getAccessibilityLabel)("submenu",a),children:(0,c.jsxs)(e6,{children:[(0,c.jsxs)(tr,{children:[K({mainMenu:r,setOpened:t,opened:e,router:s,locale:a}),(0,c.jsx)(O,{mainMenu:r,searchBtnRef:i,setSearchOpened:n,router:s,locale:a})]}),(0,c.jsxs)(te,{children:[(0,c.jsx)(Q.Col,{xs:16,md:6,lg:8,offset:{md:1},children:(0,c.jsxs)(e1,{children:[l&&(0,c.jsx)(ez,{popup:l,currentPath:s.asPath}),u&&(0,c.jsx)(ez,{popup:u,currentPath:s.asPath})]})}),(0,c.jsx)(Q.Col,{xs:16,md:7,lg:5,offset:{md:1},children:(0,c.jsx)(e2,{children:h&&h.map((e,t)=>(0,c.jsxs)(e3,{children:[e.title&&e.title.length>0&&(0,c.jsx)(e4,{children:e.title}),(0,c.jsxs)("ul",{children:[e.links&&e.links.length>0&&e.links.map((e,r)=>(0,c.jsx)("li",{children:(0,c.jsx)(v.Link,{thickLine:!0,page:e,color:s.asPath.startsWith(`/${a}
1645/${e.url}`)?"gold":"black"})},`linksMatrix_${t}_${r}`)),e.specialLink&&e.specialLinkPage&&(0,c.jsx)("li",{children:(0,c.jsx)(v.Link,{thickLine:!0,page:e.specialLinkPage,color:s.asPath.startsWith(`/${a}/${e.specialLinkPage.url}`)?"gold":"black",children:e.specialLink})})]})]},`LinksSection_${t}`))})})]}),(0,c.jsxs)(e5,{children:[f?.map((e,t)=>(0,c.jsxs)(e8,{children:[e.openingHours&&(0,c.jsx)(eM.Label,{serif:!0,children:e.openingHours}),e.url?(0,c.jsx)(v.Link,{page:e.url}):(0,c.jsx)("a",{href:`${e&&e.contact&&!e.contact.includes("@")?"tel:":"mailto:"}${e.contact}`,children:e.contact})]},`BottomSection_${t}`)),p&&(0,c.jsxs)(e7,{children:[(0,c.jsxs)("div",{children:[p.title&&(0,c.jsx)(eM.Label,{serif:!0,htmlFor:"Submenu_Newsletter_emailInput",children:p.title}),(0,c.jsx)("p",{children:p.description})]}),p.buttonText&&p.emailInput&&(0,c.jsx)(e9,{inline:!0,buttonText:p.buttonText,emailInput:p.emailInput,id:"Submenu_Newsletter_emailInput"})]})]})]})})})})};var tn=e.i(135581),ts=e.i(535414),ta=e.i(877253);e.i(388835);var to=e.i(442217),tl=e.i(257545),tu=e.i(501440),tc=e.i(595842),td=e.i(372438),th=e.i(822315),tf=e.i(542185);let tp=(e,t)=>{let r=e.allEvents.filter(e=>!e.production?.showInTourCalendar),i=new Map;if(Array.isArray(r)&&r.length>0){let e=r.sort((e,t)=>(0,tf.formatDate)(String(e.startAt)).isAfter((0,tf.formatDate)(String(t.startAt)))?1:(0,tf.formatDate)(String(e.startAt)).isBefore((0,tf.formatDate)(String(t.startAt)))?-1:0),n=e.reverse().findIndex(e=>!e.production?.showInNdplusCalendar),s=e.reverse().slice(0,e.length-n);for(let e of t?r:s){let t=(0,tf.formatDate)(String(e.startAt)).format("YYYY-MM-DD");if(i.has(t)){let r=i.get(t);r&&r.push(e)}else i.set(t,[e])}}return i},tg=({list:e,filterHeading:t,ticketsRef:r,textFeaturedProgramme:i,homepage:n=!1})=>{let s=(0,d.useRef)(null),a=e.allSeasons,[o,l]=(0,d.useState)(0),[u,h]=(0,d.useState)(tp(e,n));(0,d.useEffect)(()=>{h(new Map(tp(e,n)))},[e]);let f=()=>{setTimeout(()=>{let e=s.current.getBoundingClientRect().left;for(let[t,i]of r.entries())if(e<=i.current.getBoundingClientRect().right-1){l(t);break}},1e3)};return(0,c.jsxs)(tl.Wrapper,{ref:r,type:"extended",children:[(0,c.jsx)(tu.Filter,{data:u,seasons:a,heading:t,sliderRef:s,groupBy:"day",currentSlide:o}),(0,c.jsx)(tc.Slider,{ref:s,className:"searchProgrammeCarousel",nextCallback:f,prevCallback:f,children:function(e){let t=[],r="";for(let n of e.values())n.forEach((e,n)=>{(0,th.default)(e.startAt).isSame(r,"day"),t.push((0,c.jsx)(td.ExtendedProgrammeCarouselItemComponent,{item:e,textFeaturedProgramme:i},`ExtendedProgrammeItem_${n}`)),r=e.startAt});return t}(u)})]},String(Array.from(u)[u.size-1][1][0].id))};var tm=e.i(971936),ty=e.i(373814);let tv="programme",tb=y.default.form.withConfig({displayName:"SearchOverlay__StyledForm",componentId:"sc-b69634ef-0"})``,t_=(0,y.default)(eF).withConfig({displayName:"SearchOverlay__Wrapper",componentId:"sc-b69634ef-1"})` 1646 display: flex; 1647 justify-content: center; 1648 width: 100%; 1649 height: calc(100svh - var(--header-layout-offset, 64px)); 1650 position: fixed; 1651 top: var(--header-layout-offset, 64px); 1652 left: 0; 1653 z-index: 1; 1654 background: #fff; 1655 overflow: auto; 1656 padding: 48px 16px 0 16px; 1657 1658 ${w.mq.sm} { 1659 top: var(--header-layout-offset, 88px); 1660 height: calc(100svh - var(--header-layout-offset, 88px)); 1661 } 1662`,tE=(0,y.default)(ta.Button).withConfig({displayName:"SearchOverlay__CloseButton",componentId:"sc-b69634ef-2"})` 1663 position: absolute; 1664 right: 0; 1665 top: 0; 1666 font-size: 16px; 1667 color: ${e=>e.theme.color.gold}; 1668 font-family: var(--font-din-serif); 1669 1670 ${w.mq.md} { 1671 right: 32px; 1672 } 1673`,tS=y.default.div.withConfig({displayName:"SearchOverlay__Inner",componentId:"sc-b69634ef-3"})` 1674 width: 100%; 1675 1676 ${w.mq.md} { 1677 padding-left: 100px; 1678 padding-right: 142px; 1679 } 1680 1681 ${w.mq.lg} { 1682 padding-left: 130px; 1683 padding-right: 205px; 1684 } 1685`,tx=y.default.div.withConfig({displayName:"SearchOverlay__Results",componentId:"sc-b69634ef-4"})` 1686 overflow: auto; 1687 max-height: calc(100% - 48px - 107px); 1688 height: auto; 1689 color: ${({theme:e})=>e.color.black}; 1690 ${w.mq.sm} { 1691 max-height: calc(100% - 48px - 107px - 40px); 1692 } 1693 ${w.mq.md} { 1694 max-height: calc(100% - 48px - 107px - 66px); 1695 } 1696`,tT=y.default.div.withConfig({displayName:"SearchOverlay__ProgrammeWrapper",componentId:"sc-b69634ef-5"})` 1697 margin: 48px 0; 1698`,tw=(0,y.default)(v.Link).withConfig({displayName:"SearchOverlay__StyledLink",componentId:"sc-b69634ef-6"})` 1699 margin-bottom: 8px; 1700 font-size: 16px; 1701 font-weight: bold; 1702 max-width: 100%; 1703 1704 div { 1705 margin-right: ${({theme:e})=>e.gap.xs}; 1706 } 1707 1708 span { 1709 align-items: center; 1710 } 1711 1712 ${w.mq.lg} { 1713 font-size: 20px; 1714 margin-bottom: 16px; 1715 } 1716 1717 ${w.mq.xlg} { 1718 font-size: 24px; 1719 } 1720`,tA=y.default.ul.withConfig({displayName:"SearchOverlay__Tabs",componentId:"sc-b69634ef-7"})` 1721 display: flex; 1722 margin-top: ${({theme:e})=>e.gap.md}; 1723 overflow-y: hidden; 1724 overflow-x: auto; 1725 padding-bottom: ${({theme:e})=>e.gap.md}; 1726 li { 1727 margin-right: ${({theme:e})=>e.gap.sm}; 1728 flex-shrink: 0; 1729 } 1730 1731 ${w.mq.md} { 1732 margin-top: ${({theme:e})=>e.gap.lg}; 1733 padding-bottom: ${({theme:e})=>e.gap.lg2}; 1734 li { 1735 margin-right: ${({theme:e})=>e.gap.lg}; 1736 } 1737 } 1738`,tR=(0,y.default)(b.Icon).withConfig({displayName:"SearchOverlay__CategoryIcon",componentId:"sc-b69634ef-8"})` 1739 margin-right: ${({theme:e})=>e.gap.xxs}; 1740`,tI=y.default.button.withConfig({displayName:"SearchOverlay__TabButton",componentId:"sc-b69634ef-9"})` 1741 display: flex; 1742 align-items: center; 1743 font-family: var(--font-din-serif); 1744 color: ${({theme:e,active:t})=>t?e.color.gold:e.color.black}; 1745 position: relative; 1746 padding: 0; 1747 1748 &:after { 1749 position: absolute; 1750 content: ''; 1751 background: ${({theme:e})=>e.color.gold}; 1752 width: ${({active:e})=>
1752e?"100%":"0"}; 1753 left: 0; 1754 bottom: -12px; 1755 height: 1px; 1756 transition: all 0.25s ease; 1757 } 1758 1759 &:hover { 1760 &:after { 1761 width: 100%; 1762 } 1763 } 1764`,tk=y.default.span.withConfig({displayName:"SearchOverlay__CategoryCount",componentId:"sc-b69634ef-10"})` 1765 color: ${({theme:e})=>e.color.gold}; 1766 font-size: ${({theme:e})=>e.fz.xxs}; 1767 line-height: 2; 1768 margin-left: ${({theme:e})=>e.gap.xxs}; 1769`,tC=y.default.div.withConfig({displayName:"SearchOverlay__ResultItems",componentId:"sc-b69634ef-11"})` 1770 display: flex; 1771 flex-direction: column; 1772 align-items: flex-start; 1773`,tD=(0,y.default)(ty.Loader).withConfig({displayName:"SearchOverlay__StyledLoader",componentId:"sc-b69634ef-12"})` 1774 position: absolute; 1775`,tL=({opened:e,setOpened:t,searchBtnRef:r,searchClose:i})=>{let[n,s]=(0,d.useState)([]),[a,o]=(0,d.useState)(),[l,u]=(0,d.useState)(0),[h,f]=(0,d.useState)("all"),p=(0,d.useRef)(null),g=(0,d.useRef)(null),[m,y]=(0,d.useState)(!1),[v,b]=(0,d.useState)(!1),{mainMenu:_,filterAll:E,textProgramme:S,artistPage:x,productionPage:w,eprogrammePage:A,newsPage:I,productPage:k,magazineArticlePage:C,pressPage:D,locale:L}=(0,d.useContext)(T.AppContext),O=n?.reduce((e,t)=>e.add(t._source.contentType),new Set);O?.has("artist")&&O?.has("contact")&&O?.delete("contact");let P=O?Array.from(O):[],F=()=>{r&&r.current&&u(r.current?.getBoundingClientRect().x+Math.floor(r.current.offsetWidth/2))},N=(0,ts.debounce)(300,F);(0,d.useEffect)(()=>{p&&p.current&&p.current.focus(),F()},[e]),(0,d.useEffect)(()=>(window.addEventListener("resize",N),()=>window.removeEventListener("resize",N)),[]);let M=e=>{switch(e){case"news":return(0,c.jsx)(tR,{name:"news",height:"24",width:"24"});case"eshop":return(0,c.jsx)(tR,{name:"eshop",height:"24",width:"24"});case"page":return(0,c.jsx)(tR,{name:"online-exclusive-small-2",height:"24",width:"24"});case"production":return(0,c.jsx)(tR,{name:"inscenace",height:"24",width:"24"});case"magazineArticle":return(0,c.jsx)(tR,{name:"magazine",height:"24",width:"24"});case"press":return(0,c.jsx)(tR,{name:"press",height:"24",width:"24"});case"contact":case"artist":return(0,c.jsx)(tR,{name:"people",height:"24",width:"24"})}return(0,c.jsx)(c.Fragment,{})},j=e=>{let t,r=n.filter(t=>t._source.contentType===e).length;switch(e){case"news":t=(0,c.jsxs)(c.Fragment,{children:[M(e),_?.searchResultNews,(0,c.jsxs)(tk,{children:["(",r,")"]})]});break;case"press":t=(0,c.jsxs)(c.Fragment,{children:[M(e),_?.searchResultPressReleases,(0,c.jsxs)(tk,{children:["(",r,")"]})]});break;case"eshop":t=(0,c.jsxs)(c.Fragment,{children:[M(e),_?.searchResultEshop,(0,c.jsxs)(tk,{children:["(",r,")"]})]});break;case"page":t=(0,c.jsxs)(c.Fragment,{children:[M(e),_?.searchResultPage,(0,c.jsxs)(tk,{children:["(",r,")"]})]});break;case"production":t=(0,c.jsxs)(c.Fragment,{children:[M(e),_?.searchResultProduction,(0,c.jsxs)(tk,{children:["(",r,")"]})]});break;case"magazineArticle":t=(0,c.jsxs)(c.Fragment,{children:[M(e),_?.searchResultMagazine,(0,c.jsxs)(tk,{children:["(",r,")"]})]});break;case"contact":case"artist":t=(0,c.jsxs)(c.Fragment,{children:[M(e),_?.searchResultArtist,(0,c.jsxs)(tk,{children:["(",r,")"]})]})}return(0,c.jsx)("li",{children:(0,c.jsx)(tI,{role:"tab","aria-selected":h===e,onClick:()=>f(e),active:h===e,children:t})},e)},$=(e=[],t)=>{let r=e?.filter(e=>"eshop"!==e._source.contentType&&"eshop_programme"!==e._source.contentType)||[];return r=[...r,...e?.filter(e=>"eshop"===e._source.contentType||"eshop_programme"===e._source.contentType)||[]],(0,c.jsxs)(tC,{children:[_?.searchResultsCount&&t&&(0,c.jsx)(tm.Paragraph,{topMargin:t&&r?.length===0?"md":"0",bottomMargin:t?"md":"0",children:(0,c.jsxs)(c.Fragment,{children:[_.searchResultsCount," ",r?.length]})}),r?.map(e=>{let t=e._source.contentType,r=e._source.subContentType,i="page"===t,n="production"===t?w:"news"===t?I:"eshop_programme"===r?A:"eshop"===t?k:"magazineArticle"===t?C:"press"===t?D:x;return(0,c.jsxs)(tw,{page:i?{url:e._source.url}:n,params:i?{}:{slug:t.includes("news")||t.includes("press")||t.includes("eshop")?e._source.slug:t.includes("contact")&&e._source.profile?e._source.profile.slug+"-"+e._source.profile.id:e._source.slug+"-"+e._source.id},children:[M(e._source.contentType),t.includes("artist")&&!e._source.profile?`${e._source.firstName} ${e._source.name}`:t.includes("contact")&&e._source.profile?`${e._source.profile.firstName} ${e._source.profile.name}`:e._source.title]},e._id)})]})},U=!!P.find(e=>"production"===e),B=!!P.find(e=>"page"===e),V=!!P.find(e=>"news"===e),G=!!P.find(e=>"press"===e),q=!!P.find(e=>"eshop"===e),H=!!P.find(e=>"magazineArticle"===e),z=!!P.find(e=>"artist"===e),K=!!P.find(e=>"contact"===e);return(0,c.jsx)(tn.CSSTransition,{nodeRef:g,in:e,timeout:1e3,mountOnEnter:!0,unmountOnExit:!0,classNames:"slide-top",children:(0,c.jsxs)(t_,{ref:g,enabled:e,removeScrollBar:!1,"aria-modal":"true","aria-label":(0,R.getAccessibilityLabel)("search",L||"cs"),children:[(0,c.jsxs)(tS,{position:l,children:[(0,c.jsx)(eK.Formik,{initialValues:{phrase:""},onSubmit:()=>console.log("submit"),children:({handleSubmit:e})=>(0,c.jsx)(tb,{onSubmit:e,children:(0,c.jsx)(eK.Field,{type:"text",name:"text",component:to.SearchInput,label:"text",innerRef:p,setResults:s,setAllEvents:o,setLoa
1775ding:y,setHasText:b})})}),m&&(0,c.jsx)(tD,{}),n?.length>0&&(0,c.jsxs)(tA,{role:"tablist","aria-label":(0,R.getAccessibilityLabel)("search",L||"cs"),children:[(0,c.jsx)("li",{children:(0,c.jsx)(tI,{role:"tab","aria-selected":"all"===h,onClick:()=>f("all"),active:"all"===h,children:E})}),a&&a.allEvents?.length>0&&(0,c.jsx)("li",{children:(0,c.jsxs)(tI,{role:"tab","aria-selected":h===tv,onClick:()=>f(tv),active:h===tv,children:[(0,c.jsx)(tR,{name:"programmeSearch",height:"24",width:"24"}),S]})}),U&&j("production"),B&&j("page"),V&&j("news"),q&&j("eshop"),H&&j("magazineArticle"),G&&j("press"),z&&j("artist"),K&&j("contact")]}),(0,c.jsx)(tx,{children:(e=>{switch(h){case"all":return $(n,e);case tv:return(0,c.jsx)(tT,{children:(0,c.jsx)(tg,{list:a,textFeaturedProgramme:"Doprovodné programy"})});default:return $(n?.filter(e=>e._source.contentType===h),e)}})(v)})]}),i&&(0,c.jsx)(tE,{onClick:()=>{t(!1),s([]),b(!1)},icon:"close",simple:!0,children:i})]})})};var tO=e.i(775268),tP=e.i(341064),tF=e.i(728016);let tN=(e,t)=>{let r=e?.trim(),i=t?.trim();return r&&i?{promotion_id:r,promotion_name:i,creative_name:"announcement_bar_scrolling",creative_slot:"announcement_bar",index:1}:null};var tM=e.i(403437),tj=e.i(690586);let t$=y.default.div.withConfig({displayName:"AnnouncementBar__Wrapper",componentId:"sc-95908cfe-0"})` 1776 width: 100%; 1777 height: ${({$height:e})=>e}px; 1778 overflow: hidden; 1779 position: relative; 1780 z-index: 2; 1781 transition: height ${tj.ANNOUNCEMENT_BAR_TRANSITION}; 1782`,tU=y.default.div.withConfig({displayName:"AnnouncementBar__Inner",componentId:"sc-95908cfe-1"})` 1783 display: flex; 1784 align-items: center; 1785 justify-content: center; 1786 width: 100%; 1787 min-height: ${({$mobileMinHeight:e})=>e}px; 1788 position: relative; 1789 box-sizing: border-box; 1790 padding: 8px 44px 8px 16px; 1791 background: ${({theme:e})=>e.color.gold}; 1792 color: ${({theme:e})=>e.color.white}; 1793 border-bottom: 1px solid ${({theme:e})=>e.color.darkGold}; 1794 1795 ${w.mq.sm} { 1796 min-height: ${tj.ANNOUNCEMENT_BAR_DEFAULT_DESKTOP_HEIGHT}px; 1797 padding: 0 56px 0 24px; 1798 overflow: hidden; 1799 } 1800`,tB=y.default.div.withConfig({displayName:"AnnouncementBar__Content",componentId:"sc-95908cfe-2"})` 1801 display: flex; 1802 flex-direction: column; 1803 justify-content: center; 1804 align-items: center; 1805 gap: 2px; 1806 width: 100%; 1807 max-width: 100%; 1808 min-width: 0; 1809 text-align: center; 1810 1811 ${w.mq.sm} { 1812 flex-direction: row; 1813 align-items: center; 1814 gap: 8px; 1815 overflow: hidden; 1816 text-align: center; 1817 } 1818`,tV=y.default.div.withConfig({displayName:"AnnouncementBar__Message",componentId:"sc-95908cfe-3"})` 1819 display: flex; 1820 flex-direction: column; 1821 flex: 0 1 auto; 1822 align-items: center; 1823 justify-content: center; 1824 gap: 2px; 1825 width: 100%; 1826 min-width: 0; 1827 1828 ${w.mq.sm} { 1829 flex-direction: row; 1830 width: auto; 1831 max-width: 100%; 1832 gap: 8px; 1833 overflow: hidden; 1834 } 1835`,tG=(0,y.default)(tO.Tag).withConfig({displayName:"AnnouncementBar__AnnouncementLabel",componentId:"sc-95908cfe-4"})` 1836 flex-shrink: 0; 1837 margin-bottom: 6px; 1838 padding: 6px 14px; 1839 white-space: nowrap; 1840 color: ${({theme:e})=>e.color.white}; 1841 background: transparent; 1842 border: 1px solid ${({theme:e})=>e.color.white}; 1843 1844 ${w.mq.sm} { 1845 margin-bottom: 0; 1846 padding: 7px 16px; 1847 } 1848`,tq=y.default.p.withConfig({displayName:"AnnouncementBar__Text",componentId:"sc-95908cfe-5"})` 1849 flex: 0 1 auto; 1850 width: 100%; 1851 min-width: 0; 1852 max-width: 100%; 1853 margin: 0; 1854 font-size: 13px; 1855 line-height: 1.2; 1856 overflow-wrap: anywhere; 1857 text-align: center; 1858 white-space: normal; 1859 1860 ${w.mq.sm} { 1861 flex: 1 1 auto; 1862 width: auto; 1863 font-size: 14px; 1864 overflow: hidden; 1865 text-overflow: ellipsis; 1866 white-space: nowrap; 1867 } 1868`,tH=(0,y.default)(v.Link).withConfig({displayName:"AnnouncementBar__CTALink",componentId:"sc-95908cfe-6"})` 1869 flex-shrink: 0; 1870 color: ${({theme:e})=>e.color.white}; 1871 font-size: 13px; 1872 font-weight: 700; 1873 line-height: 1.2; 1874 text-align: center; 1875 text-decoration: underline; 1876 text-decoration-thickness: 1px; 1877 text-underline-offset: 0.18em; 1878 1879 ${w.mq.sm} { 1880 font-size: 14px; 1881 white-space: nowrap; 1882 } 1883 1884 @media not all and (pointer: coarse) { 1885 &:hover { 1886 color: ${({theme:e})=>e.color.black}; 1887 } 1888 } 1889 1890 &:focus-visible { 1891 outline: 2px solid ${({theme:e})=>e.color.black}; 1892 outline-offset: 2px; 1893 border-radius: 2px; 1894 }
1895`,tz=y.default.button.withConfig({displayName:"AnnouncementBar__CloseButton",componentId:"sc-95908cfe-7"})` 1896 display: inline-flex; 1897 justify-content: center; 1898 align-items: center; 1899 width: 32px; 1900 height: 32px; 1901 position: absolute; 1902 top: 8px; 1903 right: 8px; 1904 padding: 0; 1905 border: 0; 1906 background: transparent; 1907 color: ${({theme:e})=>e.color.white}; 1908 cursor: pointer; 1909 line-height: 0; 1910 1911 & > span { 1912 display: inline-flex; 1913 justify-content: center; 1914 align-items: center; 1915 width: 100%; 1916 height: 100%; 1917 line-height: 0; 1918 transform: rotate(0deg); 1919 transition: transform 180ms ease-in-out; 1920 } 1921 1922 @media not all and (pointer: coarse) { 1923 &:hover > span { 1924 transform: rotate(90deg); 1925 } 1926 } 1927 1928 ${w.mq.sm} { 1929 top: 0; 1930 bottom: 0; 1931 right: 12px; 1932 width: 40px; 1933 height: auto; 1934 margin: 0; 1935 transform: none; 1936 } 1937 1938 &:focus-visible { 1939 outline: 2px solid ${({theme:e})=>e.color.black}; 1940 outline-offset: 2px; 1941 border-radius: 999px; 1942 } 1943`,tK=({onHeightChange:e})=>{let t=(0,d.useContext)(T.AppContext),{locale:r,currentUrl:i,announcementBarEnabled:n,announcementBarLabel:s,announcementBarText:a,announcementBarLinkLabel:o,announcementBarLinkTarget:l}=t,[u,h]=(0,d.useState)({key:null,isDismissed:!1}),[f,p]=(0,d.useState)(0),g=(0,d.useRef)(null),m=(0,d.useRef)(null),y=`narodni-divadlo-announcement-bar-dismissed-${r||"cs"}`,v=(({announcementBarEnabled:e,announcementBarText:t})=>!!e&&!!t)({announcementBarEnabled:n,announcementBarText:a}),_=!!s?.trim(),E=(0,d.useMemo)(()=>(({announcementBarText:e,announcementBarLinkTarget:t})=>{if(!t)return null;let r=e?.trim();switch(t.__typename){case"PageRecord":case"ProductionRecord":case"NewsRecord":case"EshopProductRecord":return tN(t.id,t.title||r);case"EventRecord":return tN(t.id,t.displayTitle||t.production?.title||r);default:return null}})({announcementBarText:a,announcementBarLinkTarget:l}),[l,a]),S=(0,d.useMemo)(()=>(({locale:e,announcementBarEnabled:t,announcementBarLabel:r,announcementBarText:i,announcementBarLinkLabel:n,announcementBarLinkTarget:s})=>(({announcementBarEnabled:e,announcementBarText:t})=>!!e&&!!t)({announcementBarEnabled:t,announcementBarText:i})?JSON.stringify({locale:e,enabled:t,label:r||"",text:i||"",linkLabel:n||"",linkTarget:s?(e=>{switch(e.__typename){case"PageRecord":return JSON.stringify({__typename:e.__typename,id:e.id,url:e.url,title:e.title});case"EventRecord":return JSON.stringify({__typename:e.__typename,startAt:e.startAt,productionId:e.production?.id,productionSlug:e.production?.slug});case"ProductionRecord":case"EshopProductRecord":return JSON.stringify({__typename:e.__typename,id:e.id,slug:e.slug});case"NewsRecord":return JSON.stringify({__typename:e.__typename,slug:e.slug});default:return JSON.stringify(e)}})(s):null}):null)({locale:r,announcementBarEnabled:n,announcementBarLabel:s,announcementBarText:a,announcementBarLinkLabel:o,announcementBarLinkTarget:l}),[o,l,n,s,a,r]),x=l?(0,tP.getLinkParamsForObject)(l,t):null,w=!!o&&!!l&&!!x,A=(0,tj.getAnnouncementBarMobileHeight)({hasLabel:_,hasLink:w,text:a}),I=v&&S?`${y}:${S}`:null;(0,d.useEffect)(()=>{if(!v||!S||!I){(e=>{try{window.localStorage.removeItem(e)}catch{return}})(y),h({key:I,isDismissed:!1});return}h({key:I,isDismissed:(e=>{try{return window.localStorage.getItem(e)}catch{return null}})(y)===S})},[v,S,y,I]);let k=u.key===I,C=i||null,D=v&&k&&!u.isDismissed&&E&&I&&C?`${I}:${C}`:null;return((0,d.useEffect)(()=>{if(!v||!k||u.isDismissed)return void p(0);let e=g.current;if(!e)return;let t=()=>{p(e.scrollHeight)};if(t(),void 0===window.ResizeObserver)return window.addEventListener("resize",t),()=>{window.removeEventListener("resize",t)};let r=new window.ResizeObserver(()=>{t()});return r.observe(e),window.addEventListener("resize",t),()=>{r.disconnect(),window.removeEventListener("resize",t)}},[u.isDismissed,k,v]),(0,d.useEffect)(()=>{if(e){if(!v||!k||u.isDismissed)return void e(0);e(f)}},[u.isDismissed,k,f,e,v]),(0,d.useEffect)(()=>
1943{if(!D){m.current=null;return}m.current===D||E&&(m.current=D,(0,tM.pushPromotionEvent)("view_promotion",E))},[E,D]),v&&k&&!u.isDismissed)?(0,c.jsx)(t$,{$height:f,[tj.ANNOUNCEMENT_BAR_MARKER_ATTR]:"true",role:"region","aria-label":(0,R.getAccessibilityLabel)("announcement_bar",r),"aria-live":"polite",children:(0,c.jsxs)(tU,{ref:g,$mobileMinHeight:A,children:[(0,c.jsxs)(tB,{children:[_&&(0,c.jsx)(tG,{noSelfAlign:!0,children:(0,tF.nbsp)(s)}),(0,c.jsxs)(tV,{children:[(0,c.jsx)(tq,{children:(0,tF.nbsp)(a||"")}),w&&(0,c.jsx)(tH,{plain:!0,...x,onClick:()=>{E&&(0,tM.pushPromotionEvent)("select_promotion",E)},children:(0,tF.nbsp)(o||"")})]})]}),(0,c.jsx)(tz,{type:"button","aria-label":(0,R.getAccessibilityLabel)("close_announcement_bar",r),onClick:()=>{S&&((e,t)=>{try{window.localStorage.setItem(e,t)}catch{return}})(y,S),h({key:I,isDismissed:!0})},children:(0,c.jsx)("span",{"aria-hidden":"true",children:(0,c.jsx)(b.Icon,{name:"close",color:"white"})})})]})}):null};var tW=e.i(127906);function tY(){return(tY=Object.assign.bind()).apply(null,arguments)}let tQ=function(e){return d.createElement("svg",tY({xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 287.24 45.36"},e),d.createElement("path",{d:"M1118.21 18.707c-85.03 0-154.21 69.18-154.21 154.211 0 85.027 69.18 154.199 154.21 154.199s154.21-69.172 154.21-154.199c0-85.031-69.18-154.211-154.21-154.211m0 303.141c-82.12 0-148.929-66.813-148.929-148.93 0-82.121 66.809-148.93 148.929-148.93s148.93 66.809 148.93 148.93c0 82.117-66.81 148.93-148.93 148.93",style:{fill:"#231f20",fillOpacity:1,fillRule:"nonzero",stroke:"none"},transform:"matrix(.13333 0 0 -.13333 0 45.36)"}),d.createElement("path",{d:"M1060.71 96.285c8.32-3.742 15.4-12.062 17.48-17.062l-.84-.84c-.41 2.082-3.74 5.84-7.06 5.84 0-2.078-1.67-5-5-5-9.15 0-8.32 14.14-12.9 14.14-9.98 0-9.57-24.55-22.89-24.55-5.82 0-7.91 2.5-8.32 7.082-2.49-1.25-5.41-2.922-7.48-7.082l-.84.851c1.25 11.64 27.88 19.961 27.88 23.29 0 1.25-.84 1.671-2.08 1.671-4.58 0-17.89-7.91-23.3-7.91-4.58 0-7.91 2.488-7.91 6.238 0 2.082.43 4.16 2.09 5.41-.84.422-2.5.832-4.16.832-2.51 0-5.411-.41-7.489-2.082v.832c2.899 4.168 9.989 5 18.719 5 6.65 0 14.56-.41 22.05-.41 8.32 0 16.65 2.899 16.65 9.559 0 7.082-16.24 19.148-16.24 30.789 0 10.402 18.74 19.14 47.86 19.14 5.82 0 12.48-.418 19.14-1.238 3.33-4.172 11.65-5.84 11.65-7.5s-3.34-3.32-3.34-7.902c-8.73 0-45.35-6.25-45.35-16.649 0-7.058 3.34-17.468 7.08-21.218-3.74-2.493-10.82-7.063-15.4-11.23M1013.7 197.395c-9.16 5.41-12.49 10.82-12.49 15.812 0 3.75 1.66 8.328 6.25 8.328 2.08 0 2.91-.418 3.32-1.258 0 4.168-.83 8.739-3.32 9.989l.42.832c4.57-3.321 5.82-7.071 5.82-10.821 0-6.242-3.75-12.062-3.75-17.062 0-2.078.83-4.16 3.75-5.82M1073.19 207.379c-6.24 2.91-19.54 31.621-25.37 35.789-3.33-7.488-11.24-15.398-15.81-16.648l-.42 1.25c2.5.41 6.23 3.328 6.23 6.238-2.07 0-5.81 1.25-5.81 4.992 0 7.91 13.31 7.078 13.31 11.66 0 8.731-23.3 5.399-23.3 19.969 0 4.988 3.32 6.238 6.25 7.07-.43 2.489-2.09 5-6.25 6.66l.42.829c10.82-2.079 18.72-23.719 22.05-23.719.83 0 1.25 1.25 1.25 2.082 0 4.16-7.49 14.148-7.49 19.558 0 4.579 2.91 7.489 5.82 7.489 2.5 0 3.33-.418 4.57-2.5.42.84.84 2.922.84 4.582 0 2.5-.42 4.988-2.08 6.238l.84.422c3.32-2.5 3.74-8.32 3.74-15.402 0-5.821-.42-12.477-.42-18.297 0-10.411 5.83-16.653 9.99-20.813 3.75-3.738 10.4-16.23 14.98-19.551-2.5-2.918-3.34-7.5-3.34-17.898",style:{fill:"#231f20",fillOpacity:1,fillRule:"nonzero",stroke:"none"},transform:"matrix(.13333 0 0 -.13333 0 45.36)"}),d.createElement("path",{d:"M1024.93 107.934c-4.57 3.742-7.49 9.152-7.49 12.902 0 2.918 2.49 6.238 7.08 6.238-.84 2.91-5 6.66-9.16 6.66l.83 1.25c21.63-2.5 7.91-27.05 24.14-31.218-5.41.429-12.06.429-15.4 4.168M1054.46 278.949c1.26 5.41 4.59 7.903 7.09 7.903 2.9 0 4.57-2.082 4.57-5.821 2.08.418 6.65 4.578 6.65 7.489l.84-.418c0-10.813-20.39-12.481-20.39-26.211 0 7.07.42 12.89 1.24 17.058M1076.93 273.125c0-6.238 2.92-11.238 10.82-11.238 6.25 0 17.06 4.16 27.05 4.16 3.74 0 7.08-.832 9.98-2.082l.42-1.66c-2.08 1.25-4.58 1.66-7.49 1.66-9.98 0-23.31-7.07-31.21-7.07-8.32 0-11.24 4.992-11.24 16.23M1094.4 76.727c3.76 3.328 7.08 4.578 10 4.578 9.16 0 16.65-10.82 24.54-10.82 1.26 0 2.92.41 4.59 1.66-3.33-2.91-8.33-8.32-15.82-8.32-7.08 0-13.73 3.75-13.73 7.91 0 2.91 1.67 4.16 3.33 4.992-1.25.84-3.33 1.25-5.41 1.25-2.49 0-5.42-.832-6.66-2.922M1111.05 315.563l1.24.832c1.67-5.411 9.59-7.903 9.59-11.653 0-1.25-.83-2.488-2.92-4.16.4-2.488 3.74-3.328 6.65-3.328 3.33 0 6.25.84 6.25 2.5-1.25 1.668-2.08 2.91-2.08 4.16 0 4.988 7.91 8.738 8.74 15.399l2.08-.418c-1.67-6.243 1.66-11.653 1.66-14.981 0-2.492-1.25-4.16-4.16-4.992 0-3.328 4.58-6.25 8.31-6.25 1.68 0 2.92.422 3.75 1.672-.83 1.25-.83 2.078-.83 2.91 0 5.41 12.49 4.168 17.48 8.32l.84-1.66c-6.67-3.742-16.24-12.902-19.15-17.891-3.32 4.161-12.48 8.731-25.38 8.731-2.07 0-4.58 0-7.48-.41 0 7.91-2.08
194315.398-4.59 21.219",style:{fill:"#231f20",fillOpacity:1,fillRule:"nonzero",stroke:"none"},transform:"matrix(.13333 0 0 -.13333 0 45.36)"}),d.createElement("path",{d:"M1110.64 270.629c-.41-1.66-.82-2.922-1.24-4.992-1.25 1.66-2.08 3.332-2.08 5.82.83-.41 2.5-.828 3.32-.828M1101.9 169.098l-.42 2.082c9.57-7.91 28.72-12.481 28.72-22.883 0-5-3.34-7.078-6.24-7.078-2.08 0-2.51 1.66-2.51 5.41-1.24 0-1.66-2.91-3.32-2.91-1.25 0-2.08.418-2.08 2.5 0 3.32 3.74 4.16 3.74 6.648 0 5-14.56 7.91-17.89 16.231M1110.22 263.137c.41-1.25 1.67-3.332 2.5-4.571-.83 0-2.09-.421-2.5-.839M1135.61 219.449c0-11.238 12.06-17.48 12.06-22.89 0-2.079-1.25-4.571-6.24-6.239.42.828.84 1.25.84 2.078 0 4.161-9.17 9.993-9.17 18.719 0 2.5.43 5.41 2.51 8.332M1143.51 234.844c0-11.653 13.74-16.231 13.74-22.051 0-2.082-.83-4.582-5.41-7.07 0 7.898-10.41 12.058-10.41 21.629 0 2.082.84 4.582 2.08 7.492M1150.58 249.406c2.91-13.73 14.99-16.64 14.99-22.89 0-3.989-1.81-4.957-4.59-7.489 0 10.821-10.4 10.411-10.4 30.379M1208.42 140.391c-9.99-6.661-2.91-14.969-11.65-14.969-3.33 0-5.41 2.078-5.41 4.976 0 4.161 4.59 9.153 17.06 9.993M1224.65 139.555c17.07 0 26.22-10.821 26.22-17.879 0-3.762-2.08-6.25-6.66-6.25-9.98 0-6.65 13.726-19.56 24.129",style:{fill:"#231f20",fillOpacity:1,fillRule:"nonzero",stroke:"none"},transform:"matrix(.13333 0 0 -.13333 0 45.36)"}),d.createElement("path",{d:"M1210.92 215.285c14.56 8.32 17.07 18.313 17.07 25.801 0 8.082-3.97 10.82-8.74 10.82-2.5 0-5.41-1.25-7.9-3.332l-.84 1.672c3.33 7.059 8.32 9.981 13.32 9.981 8.65 0 14.14-10.5 14.14-17.891 0-11.981-7.77-23.379-21.22-29.961 20.81-13.32 29.54-28.301 29.54-45.359 0-13.489-9.88-24.961-26.62-24.961 3.33-6.239 4.57-12.899 4.57-19.149 0-11.648-5.83-21.218-15.81-21.218-3.75 0-9.16.847-14.99 7.078l-.82-1.25c8.73-9.149 12.49-17.891 12.49-25.801 0-7.899-4.16-14.559-10.83-19.547 2.08 7.066 2.91 12.887 2.91 17.887 0 24.14-20.8 27.05-39.11 76.152 0-26.633-20.81-31.211-20.81-42.859 0-5.41 11.23-8.321 19.15-10.813-1.25-5-2.5-14.148-2.5-19.57 4.99 1.672 11.23 2.91 16.64 2.91 2.91 0 5.42-.41 7.5-1.238l.82-2.082c-.82.41-2.9.82-4.98.82-2.09 0-4.17-.41-5.43-1.66 1.26-.41 2.09-2.07 2.09-4.149 0-3.34-2.91-5.422-6.25-5.422-4.57 0-9.14 3.34-12.48 3.34-2.49 0-3.73-1.668-3.73-5 0-6.66 6.65-18.308 6.65-25.789 0-3.34-1.25-5.84-5.41-6.66v-9.16h-1.67l-2.08 8.73c-4.57 0-5.82 3.333-5.82 7.91 0 6.66 4.58 20.391.84 20.391-4.58 0-7.08-17.89-11.24-22.469-1.67-2.081-4.58-2.91-7.07-2.91-3.33 0-5.83 2.078-5.83 6.649-2.9-.82-5.83-5.82-6.24-9.57l-.83.43c0 10.82 13.73 20.8 24.96 32.858 3.33 3.75 6.66 9.16 6.66 13.32 0 2.083-.84 3.75-2.08 4.571-10.4 10.41-38.28 2.082-38.28 19.153 0 18.718 32.04 28.707 32.04 40.367 0 14.972-33.7 22.461-49.52 39.929 9.99 0 19.14 2.5 21.64 4.161.84.421 1.25 1.261 1.25 1.671 0 .418-.41.829-1.25.829-4.16-6.661-59.5-4.989-77.4-11.649 4.17-5.828 7.08-14.148 7.08-21.641h-1.24c0 4.161-1.25 6.661-3.33 7.911-.43-.418-1.66-2.078-3.75-2.078-3.33 0-5.82 2.91-5.82 7.07 0 2.5.41 5 .41 7.078 0 1.66 0 4.16-2.91 4.16-5.83 0-12.9-13.32-22.051-13.32-5.829 0-9.149 2.5-9.149 7.492 0 1.25.399 2.078.828 2.906-4.578 0-6.66-.418-8.75-1.656l-.398 1.238c7.469 7.078 32.03 3.75 32.03 6.66 0 5.418-17.061 2.918-22.882 5.829-2.508 1.25-3.75 3.332-3.75 5.421 0 3.321 2.071 5.399 4.153 5.809-.832 1.672-4.571 3.75-9.551 3.75v.84c.82.41 2.07.82 3.32.82 6.66 0 16.641-7.898 28.29-14.558 1.25-.832 3.75-1.243 6.24-1.243 8.33 0 20.39 2.911 24.97 3.731 5.82.851 23.71 3.34 34.53 5 0 .832-.42 2.5-.42 8.332 0 7.898 6.25 23.301 21.65 23.301 4.99 0 10.82-1.25 13.72-5.41 3.33 1.238 5.83 4.57 7.08 9.98-5 2.078-9.98 5-9.98 11.648 0 2.5 2.08 5.411 4.98 5.411 2.09 0 3.33-1.661 3.33-3.332 0-1.239-.4-2.489-2.08-3.329.84-2.082 4.58-4.992 8.74-4.992 4.15 0 6.66 3.332 6.66 7.492 0 3.739-3.32 6.239-3.32 12.071 0 6.66-.43 10.398-5 10.398-3.74 0-6.24-4.578-9.56-4.578-3.34 0-7.5 1.668-7.5 9.578 0 8.32 6.65 11.641 18.72 11.641 22.06 0 30.38-12.481 30.38-22.461 0-29.547-24.96-48.68-24.96-66.168 0-20.379 17.46-25.379 26.2-34.949 22.47-25.383 26.22-54.512 48.27-54.512 7.91 0 12.07 5 12.07 12.91 0 4.16-1.24 9.149-4.16 14.559-19.15 2.09-32.88 14.152-32.88 34.113 0 17.898 11.65 28.719 28.29 36.629-27.86 19.129-37.45 38.687-37.45 53.668 0 13.73 8.75 21.64 17.91 21.64 7.49 0 14.97-4.167 19.54-17.48l-1.24-1.25c-3.33 3.332-7.07 5-10.4 5-6.66 0-12.48-5.828-12.48-15.398 0-10.821 7.48-26.211 29.12-43.692m-19.56-34.961c0-14.969 11.66-23.297 23.31-23.297 10.81 0 18.73 9.161 18.73 18.309 0 12.898-7.49 22.891-22.05 34.121-12.08-8.73-19.99-18.723-19.99-29.133m-41.6 91.133c0 5.828-2.5 9.578-5.82 9.578-2.51 0-4.17-1.668-4.17-5 0-1.25.41-2.91 1.25-4.578.41-.41.83 0 2.08 0-.83 1.668-1.25 2.918-1.25 4.16 0 2.078 1.25 3.328 2.5 3.328 2.07 0 4.15-2.91 4.15-7.488 0-3.75-2.08-7.902-3.73-7.902v-.828c2.49 0 4.99 2.91 4.99 8.73m-27.46 12.481c0-2.071 2.08-5.821 5.83-5.821 2.89 0 5.4 2.078 5.4 4.16 0 2.078-1.24 3.328-3.32 3.328-4.59 0-5.01-1.667-7.91-1.667m-16.64-.833c.82.833 1.66.833 2.08.833 2.08 0 0-6.653 2.49-6.653-.83 0-.41.832-.41 6.242 0 1.25-.84 2.078-2.08 2.078-1.26 0-2.08-.828-2.08-2.5",style:{fill:"#231f20",fillOpacity:1,fillRule:"nonzero",stroke:"none"},transform:"matrix(.13333 0 0 -.13333 0 45.36)"}),d.createElement("path",{d:"M1128.13 284.355c1.24 0 2.08-.828 2.08-2.078 0-1.242-.84-2.089-2.08
1943-2.089-1.27 0-2.08.847-2.08 2.089 0 1.25.81 2.078 2.08 2.078M67.434 93.7h-32.72v186.378h30.102l81.411-124.859v124.859h32.726V93.699h-30.109L67.434 218.57M249.883 92.129c-31.153 0-48.949 18.32-48.949 41.621 0 21.73 15.179 40.051 45.277 40.051h34.82v11.519c0 10.731-7.847 14.141-25.129 14.141-12.82 0-18.851-2.102-24.609-10.742l-24.34 18.332c11.777 15.699 26.957 20.937 47.641 20.937 34.297 0 57.59-10.988 57.59-44.238V93.7h-31.153v7.851c-5.5-6.024-14.918-9.422-31.148-9.422m31.148 56.019h-29.84c-13.871 0-20.679-4.71-20.679-13.089 0-7.848 6.539-14.141 22.781-14.141 20.41 0 27.738 2.102 27.738 20.16M378.148 93.7c-19.902 0-34.289 12.57-34.289 34.288v75.129h-13.351v24.352h13.351v39.261h31.149v-39.261h19.371v-24.352h-19.371v-72.769c0-5.758 2.09-7.848 7.07-7.848h12.301V93.7M415.84 280.078h31.148v-30.367H415.84Zm0-52.348h31.148V93.699H415.84ZM570.02 109.406c-7.59-8.121-20.418-17.281-41.879-17.281-21.469 0-34.301 9.16-41.891 17.281-10.469 11.52-14.918 22.508-14.918 51.039 0 28.282 4.449 39.27 14.918 50.789 7.59 8.121 20.422 16.75 41.891 16.75 21.461 0 34.289-8.629 41.879-16.75 10.472-11.519 15.179-22.507 15.179-50.789 0-28.531-4.707-39.519-15.179-51.039m-22.25 80.102c-3.668 4.976-11.258 8.379-19.629 8.379-8.379 0-15.969-3.403-19.641-8.379-4.711-6.543-6.02-11.25-6.02-29.063 0-18.058 1.309-22.769 6.02-29.308 3.672-4.981 11.262-8.641 19.641-8.641 8.371 0 15.961 3.66 19.629 8.641 4.71 6.539 6.281 11.25 6.281 29.051 0 18.07-1.571 22.777-6.281 29.32M672.629 227.992c21.73 0 46.601-15.972 46.601-46.601V93.699h-31.16v78.793c0 15.969-10.468 25.399-24.082 25.399-13.867 0-24.078-9.43-24.078-25.399V93.699h-31.148v132.723h31.148v-10.211c8.11 7.59 19.629 11.781 32.719 11.781M787.801 92.129c-31.153 0-48.949 18.32-48.949 41.621 0 21.73 15.179 40.051 45.277 40.051h34.82v11.519c0 10.731-7.847 14.141-25.129 14.141-12.82 0-18.851-2.102-24.609-10.742l-24.34 18.332c11.777 15.699 26.957 20.937 47.641 20.937 34.289 0 57.59-10.988 57.59-44.238V93.7h-31.153v7.851c-5.5-6.024-14.918-9.422-31.148-9.422m31.148 56.019h-29.84c-13.879 0-20.679-4.71-20.679-13.089 0-7.848 6.539-14.141 22.769-14.141 20.422 0 27.75 2.102 27.75 20.16M916.324 93.7c-20.679 0-36.117 8.898-36.117 33.769v152.609h31.148V129.559c0-4.711 2.61-6.801 7.59-6.801h11.52V93.699M1362.34 251.289V93.699h-32.72v157.59h-51.05v28.789h134.82v-28.789M1490.35 229.297c21.72 0 46.59-16.231 46.59-47.121v-88.48h-31.15v79.581c0 15.969-10.47 25.649-24.08 25.649-13.88 0-24.08-9.68-24.08-25.649V93.695h-31.15v186.383h31.15v-62.82c8.11 7.847 19.63 12.039 32.72 12.039M1591.65 148.148c1.05-17.8 13.09-27.23 29.32-27.23 9.68 0 20.16 4.461 29.05 13.359l22.52-18.589c-14.93-17.008-32.72-23.56-51.05-23.56-28.27 0-60.99 13.349-60.99 67.802 0 51.828 30.1 68.058 56.8 68.058 30.37 0 57.07-21.73 57.07-56.019v-23.821zm25.65 51.309c-14.13 0-24.6-8.898-25.91-25.66h51.57c-1.31 16.762-11.52 25.66-25.66 25.66M1736.4 92.129c-31.15 0-48.95 18.32-48.95 41.621 0 21.73 15.18 40.051 45.29 40.051h34.82v11.519c0 10.731-7.86 14.141-25.14 14.141-12.82 0-18.85-2.102-24.6-10.742l-24.35 18.332c11.78 15.699 26.97 20.937 47.64 20.937 34.3 0 57.59-10.988 57.59-44.238V93.7h-31.14v7.851c-5.5-6.024-14.93-9.422-31.16-9.422m31.16 56.019h-29.85c-13.87 0-20.68-4.71-20.68-13.089 0-7.848 6.54-14.141 22.78-14.141 20.42 0 27.75 2.102 27.75 20.16M1864.66 93.7c-19.89 0-34.29 12.57-34.29 34.288v75.129h-13.35v24.352h13.35v39.261h31.15v-39.261h19.37v-24.352h-19.37v-72.769c0-5.758 2.09-7.848 7.07-7.848h12.3V93.7M1965.44 227.992c11.26 0 20.68-3.672 31.16-11.262l-22.26-25.648c-7.59 5.231-11.78 6.809-18.06 6.809-12.04 0-23.56-7.34-23.56-24.61V93.699h-31.15v132.723h31.15v-10.211c8.12 7.59 19.64 11.781 32.72 11.781M2014.92 148.148c1.05-17.8 13.09-27.23 29.32-27.23 9.68 0 20.15 4.461 29.05 13.359l22.52-18.589c-14.92-17.008-32.73-23.56-51.05-23.56-28.27 0-60.99 13.349-60.99 67.802 0 51.828 30.1 68.058 56.81 68.058 30.36 0 57.06-21.73 57.06-56.019v-23.821zm25.66 51.309c-14.14 0-24.61-8.898-25.92-25.66h51.57c-1.31 16.762-11.52 25.66-25.65 25.66",style:{fill:"#231f20",fillOpacity:1,fillRule:"nonzero",stroke:"none"},transform:"matrix(.13333 0 0 -.13333 0 45.36)"}))},tX=0,tJ=y.default.header.withConfig({displayName:"DefaultHeader__Header",componentId:"sc-5fbc521b-0"})` 1944 width: 100%; 1945 position: fixed; 1946 top: 0; 1947 left: 0; 1948 z-index: 1000; 1949 pointer-events: none; 1950 1951 &::before { 1952 content: ''; 1953 width: 100%; 1954 height: var(${tj.HEADER_VISIBLE_OFFSET_VAR}, 64px); 1955 position: absolute; 1956 top: 0; 1957 left: 0; 1958 background: ${({theme:e,$dark:t})=>t?e.color.black:e.color.white}; 1959 transition: height ${tj.ANNOUNCEMENT_BAR_TRANSITION}; 1960 pointer-events: none; 1961 z-index: 0; 1962 } 1963 1964 & > * { 1965 pointer-events: auto; 1966 } 1967`,tZ=y.default.div.withConfig({displayName:"DefaultHeader__NavigationLayer",componentId:"sc-5fbc521b-1"})` 1968 width: 100%; 1969 position: fixed; 1970 top: var(${tj.ANNOUNCEMENT_BAR_HEIGHT_VAR}, 0px); 1971 left: 0; 1972 z-index: 1; 1973 transition: 1974 top ${tj.ANNOUNCEMENT_BAR_TRANSITION}, 1975 transform ease-in-out 300ms; 1976 transform: translateY(0); 1977`,t0=y.default.div.withConfig({displayName:"DefaultHeader__Navigation",componentId:"sc-5fbc521b-2"})` 1978 display: flex; 1979 align-items: center; 1980 justify-content: center; 1981 width: 100%; 1982 min-height: 64px; 1983 position: relative; 1984 z-index: 1; 1985 background: ${({theme:e,$dark:t})=>t?e.color.black:e.color.white}; 1986 1987 ${w.mq.sm} { 1988 min-height: 88px; 1989 } 1990`,t1=y.default.div.withConfig({displayName:"DefaultHeader__Inner",componentId:"sc-5fbc521b-3"})` 1991 display: flex; 1992 flex-direction: row; 1993 justify-content: space-between; 1994 align-items: center; 1995 width: 100%; 1996 height: 100%; 1997 margin: 0 auto; 1998 padding: 0 16px; 1999 2000 ${w.mq.sm} { 2001 justify-content: flex-start; 2002 padding: 0 24px; 2003 } 2004`,t2=y.default.div.withConfig({displayName:"DefaultHeader__Logo",componentId:"sc-5fbc521b-4"})` 2005 width: 178px; 2006 height: 27.7490494297px; 2007 flex-shrink: 0; 2008 align-self: center; 2009 2010 ${w.mq.sm} { 2011 width: 222px; 2012 height: 34.608365019px; 2013 } 2014 2015 ${w.mq.md} { 2016 width: 178px; 2017 height: 27.7490494297px; 2018 } 2019 2020 ${w.mq.lg} { 2021 width: 222px; 2022 height: 34.608365019px; 2023 } 2024 2025 a, 2026 svg { 2027 display: flex; 2028 width: 100%; 2029 height: 100%; 2030 align-self: initial; 2031 } 2032`,t3=({mainMenu:e,opened:t=!1,withLogo:r=!0})=>{let i=(0,d.useContext)(f.LocaleContext),{page:n,currentUrl:s}=(0,d.useContext)(T.AppContext),a=(0,d.useMemo)(()=>{let e,t,r;return e=s||`${window.location.pathname}${window.location.search}${window.location.hash}`,t={locale:i},(r=e.split("?")[1]?.split("#")[0])&&new URLSearchParams(r).forEach((e,r)=>{let i;Array.isArray(i=t[r])?i.push(e):"string"==typeof i?t[r]=[i,e]:t[r]=e}),{asPath:e,query:t}},[s,i]),o=(0,d.useRef)(null),[l,u]=(0,d.useState)(t),[h,p]=(0,d.useState)(!1),[g,m]=(0,d.useState)(!1),[y,b]=(0,d.useState)(0),_=(0,d.useRef)(!1),E=(0,d.useRef)(null),S=(0,d.useCallback)((e,t)=>{let r=o.current?.clientHeight||(0,tj.getDefaultNavigationHeight)(window.innerWidth),i="number"==typeof t?t:y,n="boolean"==typeof e?e:_.current;document.documentElement.style.setProperty(tj.ANNOUNCEMENT_BAR_HEIGHT_VAR,`${i}px`),document.documentElement.style.setProperty(tj.HEADER_LAYOUT_OFFSET_VAR,`${i+r}px`),document.documentElement.style.setProperty(tj.HEADER_VISIBLE_OFFSET_VAR,`${i+(n?0:r)}px`),document.documentElement.style.setProperty(tj.HEADER_NAVIGATION_HIDDEN_VAR,n?"1":"0")},[y]);return(0,d.useEffect)(()=>{S(void 0,y)},[y,S]),(0,d.useEffect)(()=>{let e=e=>{e!==_.current&&(_.current=e,m(e),S(e))},t=()=>{let{scrollY:t}=window;t<0?e(!1):t>tX?(e(!0),tX=t):(t<=tX-0||0===t)&&(e(!1),tX=t)};return t(),window.addEventListener("scroll",t,{passive:!0}),()=>{window.removeEventListener("scroll",t)}},[S]),(0,d.useEffect)(()=>{S();let e=()=>{S()},t=void 0!==window.ResizeObserver?new window.ResizeObserver(()=>{S()}):null;return o.current&&t?.observe(o.current),window.addEventListener("resize",e),()=>{t?.disconnect(),window.removeEventListener("resize",e),document.documentElement.style.removeProperty(tj.ANNOUNCEMENT_BAR_HEIGHT_VAR),document.documentElement.style.removeProperty(tj.HEADER_LAYOUT_OFFSET_VAR),document.documentElement.style.removeProperty(tj.HEADER_VISIBLE_OFFSET_VAR),document.documentElement.style.removeProperty(tj.HEADER_NAVIGATION_HIDDEN_VAR)}},[S]),(0,c.jsxs)(tJ,{$dark:!!n?.darkPage,children:[(0,c.jsx)(tK,{onHeightChange:b}),(0,c.jsx)(tZ,{ref:o,style:g?{transform:"translateY(-100%)"}:{},children:(0,c.jsx)(t0,{$dark:!!n?.darkPage,children:(0,c.jsxs)(t1,{
2032children:[r&&(0,c.jsx)(t2,{children:(0,c.jsx)(v.Link,{href:`/${i}`,noHover:!0,ariaLabel:(0,R.getAccessibilityLabel)("home",i),children:"en"===i?(0,c.jsx)(tQ,{}):(0,c.jsx)(tW.default,{})})}),(0,c.jsx)(W,{mainMenu:e,opened:l,setOpened:u,searchBtnRef:E,searchOpened:h,setSearchOpened:p,router:a,locale:i,dark:!!n?.darkPage})]})})}),(0,c.jsx)(tL,{opened:h,setOpened:p,searchBtnRef:E,searchClose:e?.searchClose}),(0,c.jsx)(ti,{opened:l,setOpened:u,mainMenu:e,searchBtnRef:E,setSearchOpened:p,router:a,locale:i})]})};var t4=e.i(705665),t5=e.i(535289);let t8=y.default.footer.withConfig({displayName:"styled__Wrapper",componentId:"sc-da9b61b2-0"})` 2033 width: 100%; 2034`,t6=y.default.div.withConfig({displayName:"styled__Partners",componentId:"sc-da9b61b2-1"})` 2035 padding: 56px 24px; 2036 color: #000; 2037 background: ${e=>e.theme.color.gold}; 2038 2039 ${w.mq.sm} { 2040 padding: 88px; 2041 } 2042`,t7=y.default.div.withConfig({displayName:"styled__Main",componentId:"sc-da9b61b2-2"})` 2043 padding: 56px 24px; 2044 color: #fff; 2045 background: ${e=>e.theme.color.darkgray}; 2046 2047 ${w.mq.sm} { 2048 padding: 88px; 2049 } 2050`,t9=y.default.div.withConfig({displayName:"styled__Contact",componentId:"sc-da9b61b2-3"})` 2051 display: flex; 2052 flex-direction: column; 2053`,re=y.default.ul.withConfig({displayName:"styled__MainLinks",componentId:"sc-da9b61b2-4"})` 2054 display: flex; 2055 flex-wrap: wrap; 2056 justify-content: space-between; 2057 padding: 40px; 2058 border: ${e=>`1px solid ${e.theme.color.lightgold}`}; 2059 /* i dont know, why this is not working: border: ${e=>`1px solid rgba(${e.theme.color.lightgold}, 0.5)`}; */ 2060 2061 ${w.mq.sm} { 2062 padding: 64px 88px; 2063 } 2064 2065 li { 2066 width: calc(50% - 15px); 2067 margin-bottom: ${e=>e.theme.gap.sm}; 2068 opacity: 0.6; 2069 2070 ${w.mq.sm} { 2071 width: 33.333%; 2072 } 2073 } 2074`,rt=y.default.div.withConfig({displayName:"styled__Newsletter",componentId:"sc-da9b61b2-5"})``,rr=y.default.div.withConfig({displayName:"styled__Legal",componentId:"sc-da9b61b2-6"})` 2075 display: flex; 2076 flex-direction: column-reverse; 2077 align-items: center; 2078 padding: 2.5rem 5.5rem; 2079 line-height: 1; 2080 2081 ${w.mq.md} { 2082 flex-direction: row; 2083 justify-content: space-between; 2084 } 2085`,ri=y.default.ul.withConfig({displayName:"styled__LegalLinks",componentId:"sc-da9b61b2-7"})` 2086 display: flex; 2087 flex-direction: column; 2088 align-items: center; 2089 margin-bottom: 2rem; 2090 2091 li + li { 2092 margin-top: 10px; 2093 } 2094 2095 ${w.mq.md} { 2096 flex-direction: row; 2097 margin-bottom: 0; 2098 li + li { 2099 margin-left: ${e=>e.theme.gap.md}; 2100 margin-top: 0; 2101 } 2102 } 2103`,rn=(0,y.default)(ta.Button).withConfig({displayName:"styled__PartnersButton",componentId:"sc-da9b61b2-8"})` 2104 margin-top: auto; 2105 color: #fff; 2106`,rs=y.default.p.withConfig({displayName:"styled__Text",componentId:"sc-da9b61b2-9"})` 2107 margin-bottom: 16px; 2108 font-family: var(--font-din-serif, serif); 2109 color: ${e=>e.theme.color.lightgold}; 2110`,ra=y.default.div.withConfig({displayName:"styled__Label",componentId:"sc-da9b61b2-10"})` 2111 margin-bottom: 8px; 2112`,ro=y.default.strong.withConfig({displayName:"styled__Value",componentId:"sc-da9b61b2-11"})` 2113 margin-bottom: 16px; 2114`;function rl(){return(rl=Object.assign.bind()).apply(null,arguments)}let ru=function(e){return d.createElement("svg",rl({xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 1200 800"},e),l||(l=d.createElement("path",{fill:"#005BBB",d:"M0 0h1200v800H0z"})),u||(u=d.createElement("path",{fill:"#FFD500",d:"M0 400h1200v400H0z"})))},rc=(0,y.default)(Q.Col).withConfig({displayName:"Footer__StyledCol",componentId:"sc-5c1c1937-0"})` 2115 flex-direction: column; 2116 margin-bottom: 54px; 2117 2118 ${w.mq.md} { 2119 margin-bottom: 0; 2120 padding-right: 16px; 2121 } 2122`,rd=(0,y.default)(b.Icon).withConfig({displayName:"Footer__LogoIcon",componentId:"sc-5c1c1937-1"})` 2123 width: 263px !important; 2124`,rh=(0,y.default)(t5.Image).withConfig({displayName:"Footer__CustomImage",componentId:"sc-5c1c1937-2"})``,rf=y.default.ul.withConfig({displayName:"Footer__List",componentId:"sc-5c1c1937-3"})` 2125 ${rh} { 2126 height: 57px; 2127 max-width: 100%; 2128 ${w.mq.lg} { 2129 max-width: 160px; 2130 } 2131 } 2132 2133 ${e=>"patrons"!==e.type&&y.css` 2134 li { 2135 margin-bottom: 48px; 2136 2137 &:last-child { 2138 margin-bottom: 0; 2139 } 2140 } 2141 `}; 2142 2143 ${e=>"patrons"===e.type&&y.css` 2144 display: flex; 2145 flex-direction: column; 2146 text-transform: uppercase; 2147 2148 li { 2149 margin-bottom: 48px; 2150 2151 &:last-child { 2152 margin-bottom: 0; 2153 } 2154 } 2155 2156 ${w.mq.md} { 2157 flex-direction: row; 2158 2159 li { 2160 margin-right: 64px; 2161 margin-bottom: 0; 2162 } 2163 } 2164 `}; 2165 2166 ${e=>"general"===e.type&&y.css` 2167 ${rh} { 2168 height: 60px; 2169 width: 100%; 2170 max-width: 250px; 2171 2172 ${w.mq.md} { 2173 height: 70px; 2174 } 2175 } 2176 `}; 2177`,rp=(0,y.default)(Q.Row).withConfig({displayName:"Footer__StyledRow",componentId:"sc-5c1c1937-4"})` 2178 ${w.mq.md} { 2179 margin-bottom: 64px; 2180 align-items: flex-start; 2181 } 2182`,rg=y.default.div.withConfig({displayName:"Footer__SocialsWrapper",componentId:"sc-5c1c1937-5"})` 2183 display: none;
2184 align-items: center; 2185 justify-content: flex-end; 2186 width: 100%; 2187 ${w.mq.md} { 2188 display: flex; 2189 } 2190`,rm=y.default.div.withConfig({displayName:"Footer__SocialsWrapperMobile",componentId:"sc-5c1c1937-6"})` 2191 display: flex; 2192 align-items: center; 2193 justify-content: flex-start; 2194 width: 100%; 2195 margin-bottom: 40px; 2196 ${w.mq.md} { 2197 display: none; 2198 } 2199`,ry=(0,y.default)(v.Link).withConfig({displayName:"Footer__SocialIcon",componentId:"sc-5c1c1937-7"})` 2200 margin-left: 16px; 2201 line-height: 1; 2202 &:first-of-type { 2203 margin-left: 0; 2204 } 2205`,rv=y.default.div.withConfig({displayName:"Footer__MadeByWrapper",componentId:"sc-5c1c1937-8"})` 2206 display: flex; 2207 align-items: center; 2208`,rb=y.default.div.withConfig({displayName:"Footer__MadeBy",componentId:"sc-5c1c1937-9"})` 2209 display: flex; 2210 flex-direction: column; 2211 align-items: center; 2212 gap: 0.5rem; 2213 2214 ${w.mq.md} { 2215 flex-direction: row; 2216 } 2217`,r_=(0,y.default)(v.Link).withConfig({displayName:"Footer__SymbioLink",componentId:"sc-5c1c1937-10"})` 2218 svg { 2219 fill: ${({theme:e,$dark:t})=>t?e.color.white:e.color.black}; 2220 } 2221 2222 ${w.mq.md} { 2223 margin-left: 16px; 2224 } 2225`,rE=y.default.li.withConfig({displayName:"Footer__LinkItem",componentId:"sc-5c1c1937-11"})` 2226 padding-right: 16px; 2227`,rS=(0,y.default)(v.Link).withConfig({displayName:"Footer__PatronsLink",componentId:"sc-5c1c1937-12"})` 2228 color: #000; 2229`,rx=y.default.section.withConfig({displayName:"Footer__UkraineWarning",componentId:"sc-5c1c1937-13"})` 2230 width: 100%; 2231 flex-shrink: 0; 2232 color: ${({theme:e,$dark:t})=>t?e.color.lightgold:e.color.black}; 2233 background: ${({theme:e,$dark:t})=>t?"transparent":e.color.white}; 2234 font-family: var(--font-din, sans-serif); 2235 font-size: 1rem; 2236 display: flex; 2237 justify-content: flex-end; 2238 z-index: 1; 2239 padding: 1rem; 2240 ${w.mq.sm} { 2241 padding: 1.5rem 72px 1.5rem 0; 2242 } 2243`,rT=y.default.a.withConfig({displayName:"Footer__UkraineLink",componentId:"sc-5c1c1937-14"})` 2244 display: flex; 2245 align-items: center; 2246 2247 &:hover { 2248 text-decoration: underline; 2249 } 2250`,rw=y.default.div.withConfig({displayName:"Footer__UkraineFlag",componentId:"sc-5c1c1937-15"})` 2251 width: 2.5rem; 2252 height: auto; 2253 display: grid; 2254 flex-shrink: 0; 2255 order: 2; 2256`,rA=y.default.p.withConfig({displayName:"Footer__UkraineText",componentId:"sc-5c1c1937-16"})` 2257 width: 100%; 2258 flex-grow: 1; 2259 order: 1; 2260 padding-left: 0; 2261 padding-right: 1rem; 2262`,rR=(e,t,r)=>!!Array.isArray(e)&&e.length>0&&(0,c.jsxs)(rc,{xs:"general"===r?12:"paymentMethods"===r||"production"===r||"patrons"===r?5:6,md:"patrons"===r?9:"general"===r?4:2.25,offset:{xs:2*("partners"===r||"media"===r),md:0},children:[(0,c.jsx)(t4.Heading,{size:"sm",tag:"h2",color:"white",marginBottom:"md",children:(0,tF.nbsp)(t)}),"general"===r?(0,c.jsx)(rf,{type:r,children:(0,c.jsx)("li",{children:(0,c.jsx)(v.Link,{href:e[0].url,target:"_blank",plain:!0,children:(0,c.jsx)(rh,{src:e[0].logo.url,alt:e[0].title})})})}):(0,c.jsx)(rf,{type:r,children:e.map((e,t)=>(0,c.jsx)("li",{children:(0,c.jsx)(rS,{plain:!0,href:e.url,target:"_blank",children:"patrons"===r?e.title:(0,c.jsx)(rh,{src:e.logo.url,alt:e.title})})},t))})]}),rI=()=>{let{locale:e}=(0,d.useContext)(T.AppContext),[t,r]=(0,d.useState)(!0),i=t=>t.map((t,r)=>{var i;let n,s;return t.link&&(0,c.jsx)(ry,{href:t.link,target:"_blank",rel:"noopener noreferrer",ariaLabel:(i=t.icon?.codename,n=(i||"").toLowerCase(),s=e??"cs",n.includes("facebook")?(0,R.getAccessibilityLabel)("social_facebook",s):n.includes("instagram")?(0,R.getAccessibilityLabel)("social_instagram",s):n.includes("youtube")?(0,R.getAccessibilityLabel)("social_youtube",s):n.includes("twitter")?(0,R.getAccessibilityLabel)("social_x",s):n.includes("linkedin")?(0,R.getAccessibilityLabel)("social_linkedin",s):n.includes("spotify")?(0,R.getAccessibilityLabel)("social_spotify",s):(0,R.getAccessibilityLabel)("social_link",s)),children:(0,c.jsx)(b.Icon,{width:"42",name:t.icon?.codename})},r)});return(0,c.jsx)(T.AppContext.Consumer,{children:({generalPartner:r,paymentMethods:n,partners:s,productionPartners:a,medialPartners:o,patrons:l,titleMainPartner:u,titlePartners:h,titlePatrons:f,titleMedialPartners:p,titleProductionPartners:g,titlePaymentMethods:m,allPartnersLabel:_,footerMenu:E,mainMenu:S,legalLinks:x,footerContactText:T,textMadeBy:w,partnersPage:I,socialNetwork:k,page:C})=>{let D;return(0,c.jsx)(y.ThemeProvider,{theme:(0,A.withAwesomeGridTheme)(A.innerGrid),children:(0,c.jsxs)(t8,{children:[t&&"cs"===e&&(0,c.jsx)(rx,{$dark:C?.darkPage||void 0,children:(0,c.jsxs)(rT,{href:"/cs/aktuality/narodni-divadlo-se-pripojuje-k-vyzve-na-podporu-ukrajiny",children:[(0,c.jsx)(rw,{children:(0,c.jsx)(ru,{})}),(0,c.jsx)(rA,{children:"Národnà divadlo se pÅipojuje k výzvÄ na podporu Ukrajiny"})]})}),(0,c.jsx)(t6,{children:(0,c.jsxs)(Q.Container,{children:[(0,c.jsxs)(rp,{children:[u&&rR(r,u,"general"),m&&rR(n,m,"paymentMethods"),h&&rR(s,h,"partners"),g&&rR(a,g,"production"),p&&rR(o,p,"media"),(0,c.jsx)(Q.Visible,{xs:!0,sm:!0,md:!0,children:f&&rR(l,f,"patrons")})]}),(0,c.jsxs)(Q.Row,{children:[_&&(0,c.jsx)(Q.Col,{sm:"4",align:"flex-end",justify:{xs:"center",sm:"flex-start"},children:(0,c.jsx)(rn,{page:I,type:"white",children:_})}),(0,c.jsx)(Q.Hidden,{xs:!0,sm:!0,md:!0,children:f&&rR(l,f,"patrons")})]})]})}),(0,c.jsx)(t7,{children:(0,c.jsxs)(Q.Container,{children:[(0,c.jsxs)(rp,{children:[(0,c.jsx)(Q.Col,{xs:3,children:(0,c.jsx)(rd,{name:"logo",color:"#fff"})}
2262),k&&(0,c.jsx)(Q.Col,{xs:9,offset:{xs:1},children:(0,c.jsx)(rg,{children:i(k)})})]}),(0,c.jsxs)(Q.Row,{children:[(0,c.jsxs)(rc,{xs:16,md:3,children:[S&&(0,c.jsx)(t9,{children:(D=[],S?.footer?.forEach((e,t)=>{0===t&&T&&D.push((0,c.jsx)(rs,{children:T},"contact")),"OurContactRecord"===e.__typename&&e.contact&&D.push((0,c.jsxs)(d.Fragment,{children:[(0,c.jsx)(ra,{children:e.openingHours}),(0,c.jsx)(ro,{children:(0,c.jsx)("a",{href:`${e.contact?.includes("@")?"mailto":"tel"}:${e.contact}`,children:e.contact})})]},t))}),D)}),k&&(0,c.jsx)(rm,{children:i(k)}),S&&(t=>{let r=t?.footer?.find(e=>"NewsletterRecord"===e.__typename);if(!r)return null;{let t=r?.newsletterFormButtonText||"Newsletter",i=r?.newsletterFormButtonText||(0,R.getAccessibilityLabel)("newsletter_link",e);return(0,c.jsxs)(rt,{children:[r.description&&(0,c.jsx)(rs,{children:(0,eN.default)(r.description,e$.parserOptions)}),(0,c.jsx)(ta.Button,{type:"gold",href:`/${e}/newsletter`,ariaLabel:i,children:t})]})}})(S)]}),(0,c.jsx)(Q.Col,{xs:16,sm:13,md:9,offset:{md:1},children:(0,c.jsx)(re,{children:E&&E[0].links?.map((e,t)=>"%other"!==e.__typename&&e.url&&e.title&&(0,c.jsx)(rE,{children:(0,c.jsx)(v.Link,{page:e,children:e.title})},t))})})]})]})}),(0,c.jsxs)(rr,{children:[(0,c.jsx)(rv,{children:(0,c.jsxs)(rb,{children:[w,(0,c.jsx)(r_,{href:"https://symbio.agency",plain:!0,target:"_blank",$dark:C?.darkPage||void 0,ariaLabel:(0,R.getAccessibilityLabel)("symbio_link",e),title:(0,R.getAccessibilityLabel)("symbio_link",e),children:(0,c.jsx)(b.Icon,{name:"symbio",width:"24",height:"24"})})]})}),(0,c.jsxs)(ri,{children:[(0,c.jsx)("li",{children:(0,c.jsx)(v.Link,{href:"/eventfeed",children:"RSS"})}),Array.isArray(x)&&x.map(e=>e.title&&(0,c.jsx)("li",{children:(0,c.jsx)(v.Link,{page:e,children:e.title})},e.id))]})]})]})})}})},rk=y.createGlobalStyle` 2263 :root { 2264 --announcement-bar-height: 0px; 2265 --header-layout-offset: 64px; 2266 --header-visible-offset: 64px; 2267 } 2268 2269 ${w.mq.sm} { 2270 :root { 2271 --announcement-bar-height: 0px; 2272 --header-layout-offset: 88px; 2273 --header-visible-offset: 88px; 2274 } 2275 } 2276`,rC=y.default.main.withConfig({displayName:"DefaultLayout__Content",componentId:"sc-9f9b17b-0"})` 2277 width: 100%; 2278 min-height: calc(100vh - var(--header-layout-offset, 64px)); 2279 padding: 16px 16px 80px; 2280 padding-top: var(--header-layout-offset, 64px); 2281 position: relative; 2282 overflow-x: hidden; 2283 transition: padding-top ${tj.ANNOUNCEMENT_BAR_TRANSITION}; 2284 2285 ${w.mq.sm} { 2286 min-height: calc(100vh - var(--header-layout-offset, 88px)); 2287 padding: 24px 24px 80px; 2288 padding-top: var(--header-layout-offset, 88px); 2289 } 2290`,rD=({children:e,mainMenu:t,hideFooter:r})=>(0,c.jsxs)(y.ThemeProvider,{theme:(0,A.withAwesomeGridTheme)(A.grid),children:[(0,c.jsx)(rk,{}),(0,c.jsx)(t3,{mainMenu:t}),(0,c.jsx)(rC,{children:e}),!r&&(0,c.jsx)(rI,{})]}),rL=y.default.div.withConfig({displayName:"IEQuote__Wrapper",componentId:"sc-162df04b-0"})` 2291 background: #ff0000; 2292 color: #fff; 2293 padding: 1rem 3.5rem 1rem 1rem; 2294 position: fixed; 2295 z-index: 99999; 2296 top: 0; 2297 left: 0; 2298 width: 100%; 2299 line-height: 1.5; 2300 display: none; 2301 2302 @media screen and (-ms-high-contrast: active), (-ms-high-contrast: none) { 2303 display: block; 2304 } 2305`,rO=y.default.div.withConfig({displayName:"IEQuote__IconWrapper",componentId:"sc-162df04b-1"})` 2306 position: absolute; 2307 top: 1rem; 2308 right: 1rem; 2309 height: 16px; 2310 width: 16px; 2311 & > div { 2312 height: 16px; 2313 } 2314`,rP=()=>{let[e,t]=(0,d.useState)(!0),{ieQuote:r}=(0,d.useContext)(T.AppContext);return e?(0,c.jsxs)(rL,{children:[r,(0,c.jsx)(rO,{children:(0,c.jsx)(b.Icon,{name:"close",onClick:()=>t(!1)})})]}):(0,c.jsx)(c.Fragment,{})};var rF=e.i(640398),rN=e.i(3303);let rM=()=>{let e=(0,eQ.usePathname)(),t=(0,eQ.useSearchParams)();return(0,d.useEffect)(()=>{let r,i;(0,tM.trackPage)((r=t?.toString(),i=e||"/",r?`${i}?${r}`:i))},[e,t]),(0,c.jsxs)(c.Fragment,{children:[(0,c.jsx)(rN.default,{id:"gtm-script",strategy:"afterInteractive",dangerouslySetInnerHTML:{__html:`
vendor: 424 bytes, lines 2314-2319
2314 2315 (function(w,d,s,l,i){w[l]=w[l]||[];w[l].push({'gtm.start': 2316 new Date().getTime(),event:'gtm.js'});var f=d.getElementsByTagName(s)[0], 2317 j=d.createElement(s),dl=l!='dataLayer'?'&l='+l:'';j.async=true;j.src= 2318 'https://www.googletagmanager.com/gtm.js?id='+i+dl;f.parentNode.insertBefore(j,f); 2319 })(window,document,'script','dataLayer','
2319GTM-KRM3STK
vendor: 20 bytes, lines 2319-2320
2319'); 2320
2320`}}),(0,c.jsx)("noscript",{dangerouslySetInnerHTML:{__html:`<!-- Google Tag Manager (noscript) --> 2321 <iframe src="https://www.googletagmanager.com/ns.html?id=GTM-KRM3STK" height="0" width="0" style="display:none;visibility:hidden"></iframe> 2322 <!-- End Google Tag Manager (noscript) -->`}})]})};var rj=e.i(315902),r$=e.i(178117),rU=e.i(618876),rB=e.i(895751),rV=e.i(4824),rG=e.i(685712),rq=e.i(235971),rH=e.i(74170),rz=e.i(83840),rK=e.i(346628);e.i(670776),e.i(396931);var rW=e.i(372907);function rY({isStaging:e,locale:t,page:r}){if(!e)return null;let i=(0,R.getAccessibilityLabel)("datocms_edit_page",t),n=r?.id?`99631/items/${r.id}/edit`:"141896/items/1556599/edit";return(0,c.jsx)("a",{href:`https://narodni-divadlo-cz.admin.datocms.com/editor/item_types/${n}`,target:"_blank",rel:"noopener noreferrer",style:{display:"block",position:"fixed",left:0,top:0,width:"50px",height:"50px",zIndex:10050,padding:"10px 20px 20px 10px",backgroundColor:"#000",color:"#fff",borderBottomRightRadius:"50px"},"aria-label":i,title:i,children:(0,c.jsx)("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 383.947 383.947","aria-hidden":"true",focusable:"false",children:(0,c.jsx)("g",{children:(0,c.jsx)("g",{children:(0,c.jsxs)("g",{fill:"#fff",children:[(0,c.jsx)("polygon",{points:"0,303.947 0,383.947 80,383.947 316.053,147.893 236.053,67.893"}),(0,c.jsx)("path",{d:"M377.707,56.053L327.893,6.24c-8.32-8.32-21.867-8.32-30.187,0l-39.04,39.04l80,80l39.04-39.04 C386.027,77.92,386.027,64.373,377.707,56.053z"})]})})})})})}e.s(["default",0,({children:e,hideFooter:t=!1,isSubnav:r=!1,mainMenu:i,pageProps:n,isStaging:s})=>{let[a,o]=(0,d.useState)(""),[l,u]=(0,d.useState)(0),y=n.locale||"cs",v=m({},!1);return(0,d.useEffect)(()=>{let e=document.documentElement,t=t=>{"Tab"===t.key&&e.setAttribute("data-keyboard-focus","true")},r=()=>{e.removeAttribute("data-keyboard-focus")};return document.addEventListener("keydown",t,!0),document.addEventListener("pointerdown",r,!0),()=>{document.removeEventListener("keydown",t,!0),document.removeEventListener("pointerdown",r,!0),e.removeAttribute("data-keyboard-focus")}},[]),th.default.extend(rj.default),th.default.extend(r$.default),th.default.extend(rU.default),th.default.extend(rz.default),th.default.extend(rB.default),th.default.extend(rV.default),th.default.extend(rG.default),th.default.extend(rq.default),th.default.extend(rH.default),th.default.extend(rK.default),th.default.updateLocale(y,{calendar:rW.CALENDAR_FORMATS[y]}),th.default.locale(y),(0,c.jsx)(T.AppContext.Provider,{value:function(e){let{typeEmail:t,required:r,...i}=e.webSetting||{};return{...i,...e,formErrors:{typeEmail:t,required:r}}}(n),children:(0,c.jsx)(h.ReactRelayContext.Provider,{value:{environment:v},children:(0,c.jsx)(f.LocaleContext.Provider,{value:y,children:(0,c.jsx)(p.SlugContext.Provider,{value:{slug2:a,changeSlug:o},children:(0,c.jsxs)(g.Provider,{value:{height:l,setHeight:u,isSubnav:r},children:[(0,c.jsx)(rF.GlobalStyle,{}),(0,c.jsx)(d.Suspense,{fallback:null,children:(0,c.jsx)(rM,{})}),(0,c.jsx)(rP,{}),(0,c.jsx)(rY,{isStaging:s,locale:y,page:n.page}),(0,c.jsx)(rD,{mainMenu:i,hideFooter:t,children:e})]})})})})})}],564928)},856082,e=>{"use strict";var t=e.i(843476),r=e.i(997053),i=e.i(94332);let n=r.default.section.withConfig({displayName:"Section__Wrapper",componentId:"sc-7bd76d1e-0"})` 2323 width: 100%; 2324 ${e=>e.withMargin&&`margin: ${e.theme.gap.lg2} 0`}; 2325 ${e=>e.withTopMargin&&`margin-top: ${e.theme.gap["string"==typeof e.withTopMargin?e.withTopMargin:"lg2"]}`}; 2326 ${e=>e.withBottomMargin&&`margin-bottom: ${e.theme.gap.lg2}`}; 2327 ${e=>e.ovxh&&"overflow-x: hidden"}; 2328 position: relative; 2329 2330 ${e=>"framedBlock"===e.variant&&r.css` 2331 padding: 80px 240px; 2332 @media (max-width: 1024px) { 2333 padding: 64px 120px; 2334 } 2335 @media (max-width: 640px) { 2336 padding: 40px 24px; 2337 } 2338 `} 2339 2340 ${i.mq.sm} { 2341 ${e=>e.withMargin&&`margin: ${e.theme.gap.md} 0`}; 2342 ${e=>e.withTopMargin&&`margin-top: ${e.theme.gap["string"==typeof e.withTopMargin?e.withTopMargin:"xl"]}`}; 2343 ${e=>e.withBottomMargin&&`margin-bottom: ${e.theme.gap.xl}`}; 2344 } 2345 2346 ${i.mq.lg} { 2347 ${e=>e.withMargin&&`margin: ${e.theme.gap.md} 0`}; 2348 ${e=>e.withTopMargin&&`margin-top: ${e.theme.gap["string"==typeof e.withTopMargin?e.withTopMargin:"xxl"]}`}; 2349 ${e=>e.withBottomMargin&&`margin-bottom: ${e.theme.gap.xxl}`}; 2350 } 2351`,s=(0,r.default)(n).withConfig({displayName:"Section__WrapperFull",componentId:"sc-7bd76d1e-1"})` 2352 margin-left: -16px; 2353 margin-right: -16px; 2354 width: calc(100% + 32px); 2355 ${i.mq.sm} { 2356 margin-left: -24px; 2357 margin-right: -24px; 2358 width: calc(100% + 48px); 2359 } 2360`;e.s(["Section",0,({children:e,aboutRef:r,...i})=>(0,t.jsx)(n,{ref:r,...i,children:e}),"SectionFull",0,({children:e,aboutRef:r,...i})=>(0,t.jsx)(s,{ref:r,...i,children:e})])},834775,(e,t,r)=>{"use strict";
2360t.exports=function(e){try{return!!e()}catch(e){return!0}}},730309,(e,t,r)=>{"use strict";t.exports=!e.r(834775)(function(){var e=(function(){}).bind();return"function"!=typeof e||e.hasOwnProperty("prototype")})},963296,(e,t,r)=>{"use strict";var i=e.r(730309),n=Function.prototype,s=n.call,a=i&&n.bind.bind(s,s);t.exports=i?a:function(e){return function(){return s.apply(e,arguments)}}},553338,(e,t,r)=>{"use strict";var i=e.r(963296),n=i({}.toString),s=i("".slice);t.exports=function(e){return s(n(e),8,-1)}},293479,(e,t,r)=>{"use strict";var i=e.r(963296),n=e.r(834775),s=e.r(553338),a=Object,o=i("".split);t.exports=n(function(){return!a("z").propertyIsEnumerable(0)})?function(e){return"String"===s(e)?o(e,""):a(e)}:a},744037,(e,t,r)=>{"use strict";t.exports=function(e){return null==e}},257081,(e,t,r)=>{"use strict";var i=e.r(744037),n=TypeError;t.exports=function(e){if(i(e))throw new n("Can't call method on "+e);return e}},185267,(e,t,r)=>{"use strict";var i=e.r(293479),n=e.r(257081);t.exports=function(e){return i(n(e))}},493046,(e,t,r)=>{"use strict";var i=function(e){return e&&e.Math===Math&&e};t.exports=i("object"==typeof globalThis&&globalThis)||i("object"==typeof window&&window)||i("object"==typeof self&&self)||i(e.g)||i("object"==typeof e.e&&e.e)||function(){return this}()||Function("return this")()},428665,(e,t,r)=>{"use strict";t.exports=!1},740310,(e,t,r)=>{"use strict";var i=e.r(493046),n=Object.defineProperty;t.exports=function(e,t){try{n(i,e,{value:t,configurable:!0,writable:!0})}catch(r){i[e]=t}return t}},672483,(e,t,r)=>{"use strict";var i=e.r(428665),n=e.r(493046),s=e.r(740310),a="__core-js_shared__",o=t.exports=n[a]||s(a,{});(o.versions||(o.versions=[])).push({version:"3.49.0",mode:i?"pure":"global",copyright:"© 2013â2025 Denis Pushkarev (zloirock.ru), 2025â2026 CoreJS Company (core-js.io). All rights reserved.",license:"https://github.com/zloirock/core-js/blob/v3.49.0/LICENSE",source:"https://github.com/zloirock/core-js"})},93095,(e,t,r)=>{"use strict";var i=e.r(672483);t.exports=function(e,t){return i[e]||(i[e]=t||{})}},287867,(e,t,r)=>{"use strict";var i=e.r(257081),n=Object;t.exports=function(e){return n(i(e))}},514421,(e,t,r)=>{"use strict";var i=e.r(963296),n=e.r(287867),s=i({}.hasOwnProperty);t.exports=Object.hasOwn||function(e,t){return s(n(e),t)}},286121,(e,t,r)=>{"use strict";var i=e.r(963296),n=0,s=Math.random(),a=i(1.1.toString);t.exports=function(e){return"Symbol("+(void 0===e?"":e)+")_"+a(++n+s,36)}},918258,(e,t,r)=>{"use strict";var i=e.r(493046).navigator,n=i&&i.userAgent;t.exports=n?String(n):""},539330,(e,t,r)=>{"use strict";var i,n,s=e.r(493046),a=e.r(918258),o=s.process,l=s.Deno,u=o&&o.versions||l&&l.version,c=u&&u.v8;c&&(n=(i=c.split("."))[0]>0&&i[0]<4?1:+(i[0]+i[1])),!n&&a&&(!(i=a.match(/Edge\/(\d+)/))||i[1]>=74)&&(i=a.match(/Chrome\/(\d+)/))&&(n=+i[1]),t.exports=n},713504,(e,t,r)=>{"use strict";var i=e.r(539330),n=e.r(834775),s=e.r(493046).String;t.exports=!!Object.getOwnPropertySymbols&&!n(function(){var e=Symbol("symbol detection");return!s(e)||!(Object(e)instanceof Symbol)||!Symbol.sham&&i&&i<41})},66446,(e,t,r)=>{"use strict";t.exports=e.r(713504)&&!Symbol.sham&&"symbol"==typeof Symbol.iterator},873663,(e,t,r)=>{"use strict";var i=e.r(493046),n=e.r(93095),s=e.r(514421),a=e.r(286121),o=e.r(713504),l=e.r(66446),u=i.Symbol,c=n("wks"),d=l?u.for||u:u&&u.withoutSetter||a;t.exports=function(e){return s(c,e)||(c[e]=o&&s(u,e)?u[e]:d("Symbol."+e)),c[e]}},853504,(e,t,r)=>{"use strict";var i="object"==typeof document&&document.all;t.exports=void 0===i&&void 0!==i?function(e){return"function"==typeof e||e===i}:function(e){return"function"==typeof e}},668864,(e,t,r)=>{"use strict";var i=e.r(853504);t.exports=function(e){return"object"==typeof e?null!==e:i(e)}},722768,(e,t,r)=>{"use strict";var i=e.r(668864),n=String,s=TypeError;t.exports=function(e){if(i(e))return e;throw new s(n(e)+" is not an object")}},226241,(e,t,r)=>{"use strict";t.exports=!e.r(834775)(function(){return 7!==Object.defineProperty({},1,{get:function(){return 7}})[1]})},463207,(e,t,r)=>{"use strict";var i=e.r(226241),n=e.r(834775);t.exports=i&&n(function(){return 42!==Object.defineProperty(function(){},"prototype",{value:42,writable:!1}).prototype})},881677,(e,t,r)=>{"use strict";var i=e.r(493046),n=e.r(668864),s=i.document,a=n(s)&&n(s.createElement);t.exports=function(e){return a?s.createElement(e):{}}},78095,(e,t,r)=>{"use strict";var i=e.r(226241),n=e.r(834775),s=e.r(881677);t.exports=!i&&!n(function(){return 7!==Object.defineProperty(s("div"),"a",{get:function(){return 7}}).a})},10493,(e,t,r)=>{"use strict";var i=e.r(730309),n=Function.prototype.call;t.exports=i?n.bind(n):function(){return n.apply(n,arguments)}},921064,(e,t,r)=>{"use strict";var i=e.r(493046),n=e.r(853504);t.exports=function(e,t){var r;return arguments.length<2?n(r=i[e])?r:void 0:i[e]&&i[e][t]}},650211,(e,t,r)=>{"use strict";
2360t.exports=e.r(963296)({}.isPrototypeOf)},850101,(e,t,r)=>{"use strict";var i=e.r(921064),n=e.r(853504),s=e.r(650211),a=e.r(66446),o=Object;t.exports=a?function(e){return"symbol"==typeof e}:function(e){var t=i("Symbol");return n(t)&&s(t.prototype,o(e))}},754770,(e,t,r)=>{"use strict";var i=String;t.exports=function(e){try{return i(e)}catch(e){return"Object"}}},287505,(e,t,r)=>{"use strict";var i=e.r(853504),n=e.r(754770),s=TypeError;t.exports=function(e){if(i(e))return e;throw new s(n(e)+" is not a function")}},532638,(e,t,r)=>{"use strict";var i=e.r(287505),n=e.r(744037);t.exports=function(e,t){var r=e[t];return n(r)?void 0:i(r)}},920053,(e,t,r)=>{"use strict";var i=e.r(10493),n=e.r(853504),s=e.r(668864),a=TypeError;t.exports=function(e,t){var r,o;if("string"===t&&n(r=e.toString)&&!s(o=i(r,e))||n(r=e.valueOf)&&!s(o=i(r,e))||"string"!==t&&n(r=e.toString)&&!s(o=i(r,e)))return o;throw new a("Can't convert object to primitive value")}},491717,(e,t,r)=>{"use strict";var i=e.r(10493),n=e.r(668864),s=e.r(850101),a=e.r(532638),o=e.r(920053),l=e.r(873663),u=TypeError,c=l("toPrimitive");t.exports=function(e,t){if(!n(e)||s(e))return e;var r,l=a(e,c);if(l){if(void 0===t&&(t="default"),!n(r=i(l,e,t))||s(r))return r;throw new u("Can't convert object to primitive value")}return void 0===t&&(t="number"),o(e,t)}},641845,(e,t,r)=>{"use strict";var i=e.r(491717),n=e.r(850101);t.exports=function(e){var t=i(e,"string");return n(t)?t:t+""}},696706,(e,t,r)=>{"use strict";var i=e.r(226241),n=e.r(78095),s=e.r(463207),a=e.r(722768),o=e.r(641845),l=TypeError,u=Object.defineProperty,c=Object.getOwnPropertyDescriptor,d="enumerable",h="configurable",f="writable";r.f=i?s?function(e,t,r){if(a(e),t=o(t),a(r),"function"==typeof e&&"prototype"===t&&"value"in r&&f in r&&!r[f]){var i=c(e,t);i&&i[f]&&(e[t]=r.value,r={configurable:h in r?r[h]:i[h],enumerable:d in r?r[d]:i[d],writable:!1})}return u(e,t,r)}:u:function(e,t,r){if(a(e),t=o(t),a(r),n)try{return u(e,t,r)}catch(e){}if("get"in r||"set"in r)throw new l("Accessors not supported");return"value"in r&&(e[t]=r.value),e}},116886,(e,t,r)=>{"use strict";var i=Math.ceil,n=Math.floor;t.exports=Math.trunc||function(e){var t=+e;return(t>0?n:i)(t)}},686969,(e,t,r)=>{"use strict";var i=e.r(116886);t.exports=function(e){var t=+e;return t!=t||0===t?0:i(t)}},35443,(e,t,r)=>{"use strict";var i=e.r(686969),n=Math.max,s=Math.min;t.exports=function(e,t){var r=i(e);return r<0?n(r+t,0):s(r,t)}},538049,(e,t,r)=>{"use strict";var i=e.r(686969),n=Math.min;t.exports=function(e){var t=i(e);return t>0?n(t,0x1fffffffffffff):0}},447961,(e,t,r)=>{"use strict";var i=e.r(538049);t.exports=function(e){return i(e.length)}},996793,(e,t,r)=>{"use strict";var i=e.r(185267),n=e.r(35443),s=e.r(447961),a=function(e){return function(t,r,a){var o,l=i(t),u=s(l);if(0===u)return!e&&-1;var c=n(a,u);if(e&&r!=r){for(;u>c;)if((o=l[c++])!=o)return!0}else for(;u>c;c++)if((e||c in l)&&l[c]===r)return e||c||0;return!e&&-1}};t.exports={includes:a(!0),indexOf:a(!1)}},132324,(e,t,r)=>{"use strict";t.exports={}},760323,(e,t,r)=>{"use strict";var i=e.r(963296),n=e.r(514421),s=e.r(185267),a=e.r(996793).indexOf,o=e.r(132324),l=i([].push);t.exports=function(e,t){var r,i=s(e),u=0,c=[];for(r in i)!n(o,r)&&n(i,r)&&l(c,r);for(;t.length>u;
vendor: 5,174 bytes, line 2360
2360)n(i,r=t[u++])&&(~a(c,r)||l(c,r));return c}},964586,(e,t,r)=>{"use strict";t.exports=["constructor","hasOwnProperty","isPrototypeOf","propertyIsEnumerable","toLocaleString","toString","valueOf"]},547150,(e,t,r)=>{"use strict";var i=e.r(760323),n=e.r(964586);t.exports=Object.keys||function(e){return i(e,n)}},778650,(e,t,r)=>{"use strict";var i=e.r(226241),n=e.r(463207),s=e.r(696706),a=e.r(722768),o=e.r(185267),l=e.r(547150);r.f=i&&!n?Object.defineProperties:function(e,t){a(e);for(var r,i=o(t),n=l(t),u=n.length,c=0;u>c;)s.f(e,r=n[c++],i[r]);return e}},905217,(e,t,r)=>{"use strict";t.exports=e.r(921064)("document","documentElement")},154029,(e,t,r)=>{"use strict";var i=e.r(93095),n=e.r(286121),s=i("keys");t.exports=function(e){return s[e]||(s[e]=n(e))}},547818,(e,t,r)=>{"use strict";var i,n=e.r(722768),s=e.r(778650),a=e.r(964586),o=e.r(132324),l=e.r(905217),u=e.r(881677),c=e.r(154029),d="prototype",h="script",f=c("IE_PROTO"),p=function(){},g=function(e){return"<"+h+">"+e+"</"+h+">"},m=function(e){e.write(g("")),e.close();var t=e.parentWindow.Object;return e=null,t},y=function(){var e,t=u("iframe");return t.style.display="none",l.appendChild(t),t.src=String("java"+h+":"),(e=t.contentWindow.document).open(),e.write(g("document.F=Object")),e.close(),e.F},v=function(){try{i=new ActiveXObject("htmlfile")}catch(e){}v="u">typeof document?document.domain&&i?m(i):y():m(i);for(var e=a.length;e--;)delete v[d][a[e]];return v()};o[f]=!0,t.exports=Object.create||function(e,t){var r;return null!==e?(p[d]=n(e),r=new p,p[d]=null,r[f]=e):r=v(),void 0===t?r:s.f(r,t)}},462714,(e,t,r)=>{"use strict";var i=e.r(873663),n=e.r(547818),s=e.r(696706).f,a=i("unscopables"),o=Array.prototype;void 0===o[a]&&s(o,a,{configurable:!0,value:n(null)}),t.exports=function(e){o[a][e]=!0}},543740,(e,t,r)=>{"use strict";t.exports={}},829297,(e,t,r)=>{"use strict";var i=e.r(493046),n=e.r(853504),s=i.WeakMap;t.exports=n(s)&&/native code/.test(String(s))},265957,(e,t,r)=>{"use strict";t.exports=function(e,t){return{enumerable:!(1&e),configurable:!(2&e),writable:!(4&e),value:t}}},598945,(e,t,r)=>{"use strict";var i=e.r(226241),n=e.r(696706),s=e.r(265957);t.exports=i?function(e,t,r){return n.f(e,t,s(1,r))}:function(e,t,r){return e[t]=r,e}},798884,(e,t,r)=>{"use strict";var i,n,s,a=e.r(829297),o=e.r(493046),l=e.r(668864),u=e.r(598945),c=e.r(514421),d=e.r(672483),h=e.r(154029),f=e.r(132324),p="Object already initialized",g=o.TypeError,m=o.WeakMap;if(a||d.state){var y=d.state||(d.state=new m);y.get=y.get,y.has=y.has,y.set=y.set,i=function(e,t){if(y.has(e))throw new g(p);return t.facade=e,y.set(e,t),t},n=function(e){return y.get(e)||{}},s=function(e){return y.has(e)}}else{var v=h("state");f[v]=!0,i=function(e,t){if(c(e,v))throw new g(p);return t.facade=e,u(e,v,t),t},n=function(e){return c(e,v)?e[v]:{}},s=function(e){return c(e,v)}}t.exports={set:i,get:n,has:s,enforce:function(e){return s(e)?n(e):i(e,{})},getterFor:function(e){return function(t){var r;if(!l(t)||(r=n(t)).type!==e)throw new g("Incompatible receiver, "+e+" required");return r}}}},393865,(e,t,r)=>{"use strict";var i={}.propertyIsEnumerable,n=Object.getOwnPropertyDescriptor;r.f=n&&!i.call({1:2},1)?function(e){var t=n(this,e);return!!t&&t.enumerable}:i},9385,(e,t,r)=>{"use strict";var i=e.r(226241),n=e.r(10493),s=e.r(393865),a=e.r(265957),o=e.r(185267),l=e.r(641845),u=e.r(514421),c=e.r(78095),d=Object.getOwnPropertyDescriptor;r.f=i?d:function(e,t){if(e=o(e),t=l(t),c)try{return d(e,t)}catch(e){}if(u(e,t))return a(!n(s.f,e,t),e[t])}},277742,(e,t,r)=>{"use strict";var i=e.r(226241),n=e.r(514421),s=Function.prototype,a=i&&Object.getOwnPropertyDescriptor,o=n(s,"name"),l=o&&(!i||i&&a(s,"name").configurable);t.exports={EXISTS:o,PROPER:o&&"something"===(function(){}).name,CONFIGURABLE:l}},991904,(e,t,r)=>{"use strict";var i=e.r(963296),n=e.r(853504),s=e.r(672483),a=i(Function.toString);n(s.inspectSource)||(s.inspectSource=function(e){return a(e)}),t.exports=s.inspectSource},686323,(e,t,r)=>{"use strict";var i=e.r(963296),n=e.r(834775),s=e.r(853504),a=e.r(514421),o=e.r(226241),l=e.r(277742).CONFIGURABLE,u=e.r(991904),c=e.r(798884),d=c.enforce,h=c.get,f=String,p=Object.defineProperty,g=i("".slice),m=i("".replace),y=i([].join),v=o&&!n(function(){return 8!==p(function(){},"length",{value:8}).length}),b=String(String).split("String"),_=t.exports=function(e,t,r){"Symbol("===g(f(t),0,7)&&(t="["+m(f(t),/^Symbol\(([^)]*)\).*$/,"$1")+"]"),r&&r.getter&&(t="get "+t),r&&r.setter&&(t="set "+t),(!a(e,"name")||l&&e.name!==t)&&(o?p(e,"name",{value:t,configurable:!0}):e.name=t),v&&r&&a(r,"arity")&&e.length!==r.arity&&p(e,"length",{value:r.arity});try{r&&a(r,"constructor")&&r.constructor?o&&p(e,"prototype",{writable:!1}):e.prototype&&(e.prototype=void 0)}catch(e){}var i=d(e);return a(i,"source")||(i.source=y(b,"string"==typeof t?t:"")),e};Function.prototype.toString=_(function(){return s(this)&&h(this).source||u(this)},"toString")},905001,(e,t,r)=>{"use strict";var i=e.r(853504),n=e.r(696706),s=e.r(686323),a=e.r(740310);t.exports=function(e,t,r,o){o||(o={});var l=o.enumerable,u=void 0!==o.name?o.name:t;if(i(r)&&s(r,u,o),o.global)l?e[t]=r:a(t,r);else{try{o.unsafe?e[t]&&(l=!0):delete e[t]}catch(e){}
2360l?e[t]=r:n.f(e,t,{value:r,enumerable:!1,configurable:!o.nonConfigurable,writable:!o.nonWritable})}return e}},960123,(e,t,r)=>{"use strict";var i=e.r(760323),n=e.r(964586).concat("length","prototype");r.f=Object.getOwnPropertyNames||function(e){return i(e,n)}},801133,(e,t,r)=>{"use strict";r.f=Object.getOwnPropertySymbols},230713,(e,t,r)=>{"use strict";var i=e.r(921064),n=e.r(963296),s=e.r(960123),a=e.r(801133),o=e.r(722768),l=n([].concat);t.exports=i("Reflect","ownKeys")||function(e){var t=s.f(o(e)),r=a.f;return r?l(t,r(e)):t}},154996,(e,t,r)=>{"use strict";var i=e.r(514421),n=e.r(230713),s=e.r(9385),a=e.r(696706);t.exports=function(e,t,r){for(var o=n(t),l=a.f,u=s.f,c=0;c<o.length;c++){var d=o[c];i(e,d)||r&&i(r,d)||l(e,d,u(t,d))}}},700117,(e,t,r)=>{"use strict";var i=e.r(834775),n=e.r(853504),s=/#|\.prototype\./,a=function(e,t){var r=l[o(e)];return r===c||r!==u&&(n(t)?i(t):!!t)},o=a.normalize=function(e){return String(e).replace(s,".").toLowerCase()},l=a.data={},u=a.NATIVE="N",c=a.POLYFILL="P";t.exports=a},12125,(e,t,r)=>{"use strict";var i=e.r(493046),n=e.r(9385).f,s=e.r(598945),a=e.r(905001),o=e.r(740310),l=e.r(154996),u=e.r(700117);t.exports=function(e,t){var r,c,d,h,f,p=e.target,g=e.global,m=e.stat;if(r=g?i:m?i[p]||o(p,{}):i[p]&&i[p].prototype)for(c in t){if(h=t[c],d=e.dontCallGetSet?(f=n(r,c))&&f.value:r[c],!u(g?c:p+(m?".":"#")+c,e.forced)&&void 0!==d){if(typeof h==typeof d)continue;l(h,d)}(e.sham||d&&d.sham)&&s(h,"sham",!0),a(r,c,h,e)}}},964525,(e,t,r)=>{"use strict";t.exports=!e.r(834775)(function(){function e(){}return e.prototype.constructor=null,Object.getPrototypeOf(new e)!==e.prototype})},293822,(e,t,r)=>{"use strict";var i=e.r(514421),n=e.r(853504),s=e.r(287867),a=e.r(154029),o=e.r(964525),l=a("IE_PROTO"),u=Object,c=u.prototype;t.exports=o?u.getPrototypeOf:function(e){var t=s(e);if(i(t,l))return t[l];var r=t.constructor;return n(r)&&t instanceof r?r.prototype:t instanceof u?c:null}},872675,(e,t,r)=>{"use strict";var i,n,s,a=e.r(834775),o=e.r(853504),l=e.r(668864),u=e.r(547818),c=e.r(293822),d=e.r(905001),h=e.r(873663),f=e.r(428665),p=h("iterator"),g=!1;[].keys&&("next"in(s=[].keys())?(n=c(c(s)))!==Object.prototype&&(i=n):g=!0),!l(i)||a(function(){var e={};return i[p].call(e)!==e})?i={}:f&&(i=u(i)),o(i[p])||d(i,p,function(){return this}),t.exports={IteratorPrototype:i,BUGGY_SAFARI_ITERATORS:g}},369899,(e,t,r)=>{"use strict";var i=e.r(696706).f,n=e.r(514421),s=e.r(873663)("toStringTag");t.exports=function(e,t,r){e&&!r&&(e=e.prototype),e&&!n(e,s)&&i(e,s,{configurable:!0,value:t})}},993927,(e,t,r)=>{"use strict";var i=e.r(872675).IteratorPrototype,n=e.r(547818),s=e.r(265957),a=e.r(369899),o=e.r(543740),l=function(){return this};t.exports=function(e,t,r,u){var c=t+" Iterator";return e.prototype=n(i,{next:s(+!u,r)}),a(e,c,!1,!0),o[c]=l,e}},415561,(e,t,r)=>{"use strict";var i=e.r(963296),n=e.r(287505);t.exports=function(e,t,r){try{return i(n(Object.getOwnPropertyDescriptor(e,t)[r]))}catch(e){}}},124942,(e,t,r)=>{"use strict";var i=e.r(668864);t.exports=function(e){return i(e)||null===e}},218714,(e,t,r)=>{"use strict";var i=e.r(124942),n=String,s=TypeError;t.exports=function(e){if(i(e))return e;throw new s("Can't set "+n(e)+" as a prototype")}},47946,(e,t,r)=>{"use strict";var i=e.r(415561),n=e.r(668864),s=e.r(257081),a=e.r(218714);
2360t.exports=Object.setPrototypeOf||("__proto__"in{}?function(){var e,t=!1,r={};try{(e=i(Object.prototype,"__proto__","set"))(r,[]),t=r instanceof Array}catch(e){}return function(r,i){return s(r),a(i),n(r)&&(t?e(r,i):r.__proto__=i),r}}():void 0)},411758,(e,t,r)=>{"use strict";var i=e.r(12125),n=e.r(10493),s=e.r(428665),a=e.r(277742),o=e.r(853504),l=e.r(993927),u=e.r(293822),c=e.r(47946),d=e.r(369899),h=e.r(598945),f=e.r(905001),p=e.r(873663),g=e.r(543740),m=e.r(872675),y=a.PROPER,v=a.CONFIGURABLE,b=m.IteratorPrototype,_=m.BUGGY_SAFARI_ITERATORS,E=p("iterator"),S="keys",x="values",T="entries",w=function(){return this};t.exports=function(e,t,r,a,p,m,A){l(r,t,a);var R,I,k,C=function(e){if(e===p&&F)return F;if(!_&&e&&e in O)return O[e];switch(e){case S:case x:case T:return function(){return new r(this,e)}}return function(){return new r(this)}},D=t+" Iterator",L=!1,O=e.prototype,P=O[E]||O["@@iterator"]||p&&O[p],F=!_&&P||C(p),N="Array"===t&&O.entries||P;if(N&&(R=u(N.call(new e)))!==Object.prototype&&R.next&&(!s&&u(R)!==b&&(c?c(R,b):o(R[E])||f(R,E,w)),d(R,D,!0,!0),s&&(g[D]=w)),y&&p===x&&P&&P.name!==x&&(!s&&v?h(O,"name",x):(L=!0,F=function(){return n(P,this)})),p)if(I={values:C(x),keys:m?F:C(S),entries:C(T)},A)for(k in I)!_&&!L&&k in O||f(O,k,I[k]);else i({target:t,proto:!0,forced:_||L},I);return(!s||A)&&O[E]!==F&&f(O,E,F,{name:p}),g[t]=F,I}},241702,(e,t,r)=>{"use strict";t.exports=function(e,t){return{value:e,done:t}}},475300,(e,t,r)=>{"use strict";var i=e.r(185267),n=e.r(462714),s=e.r(543740),a=e.r(798884),o=e.r(696706).f,l=e.r(411758),u=e.r(241702),c=e.r(428665),d=e.r(226241),h="Array Iterator",f=a.set,p=a.getterFor(h);t.exports=l(Array,"Array",function(e,t){f(this,{type:h,target:i(e),index:0,kind:t})},function(){var e=p(this),t=e.target,r=e.index++;if(!t||r>=t.length)return e.target=null,u(void 0,!0);switch(e.kind){case"keys":return u(r,!1);case"values":return u(t[r],!1)}return u([r,t[r]],!1)},"values");var g=s.Arguments=s.Array;if(n("keys"),n("values"),n("entries"),!c&&d&&"values"!==g.name)try{o(g,"name",{value:"values"})}catch(e){}},116363,(e,t,r)=>{"use strict";var i=e.r(873663)("toStringTag"),n={};n[i]="z",t.exports="[object z]"===String(n)},51756,(e,t,r)=>{"use strict";var i=e.r(116363),n=e.r(853504),s=e.r(553338),a=e.r(873663)("toStringTag"),o=Object,l="Arguments"===s(function(){return arguments}()),u=function(e,t){try{return e[t]}catch(e){}};t.exports=i?s:function(e){var t,r,i;return void 0===e?"Undefined":null===e?"Null":"string"==typeof(r=u(t=o(e),a))?r:l?s(t):"Object"===(i=s(t))&&n(t.callee)?"Arguments":i}},180194,(e,t,r)=>{"use strict";var i=e.r(116363),n=e.r(51756);t.exports=i?({}).toString:function(){return"[object "+n(this)+"]"}},745680,(e,t,r)=>{"use strict";var i=e.r(116363),n=e.r(905001),s=e.r(180194);i||n(Object.prototype,"toString",s,{unsafe:!0})},17708,(e,t,r)=>{"use strict";t.exports=e.r(963296)([].slice)},881004,(e,t,r)=>{"use strict";var i=e.r(553338),n=e.r(185267),s=e.r(960123).f,a=e.r(17708),o="object"==typeof window&&window&&Object.getOwnPropertyNames?Object.getOwnPropertyNames(window):[],l=function(e){try{return s(e)}catch(e){return a(o)}};t.exports.f=function(e){return o&&"Window"===i(e)?l(e):s(n(e))}},964470,(e,t,r)=>{"use strict";t.exports=e.r(834775)(function(){if("function"==typeof ArrayBuffer){var e=new ArrayBuffer(8);Object.isExtensible(e)&&Object.defineProperty(e,"a",{value:8})}})},845198,(e,t,r)=>{"use strict";var i=e.r(834775),n=e.r(668864),s=e.r(553338),a=e.r(964470),o=Object.isExtensible;t.exports=i(function(){o(1)})||a?function(e){return!!n(e)&&(!a||"ArrayBuffer"!==s(e))&&(!o||o(e))}:o},248421,(e,t,r)=>{"use strict";t.exports=!e.r(834775)(function(){return Object.isExtensible(Object.preventExtensions({}))})},840246,(e,t,r)=>{"use strict";var i=e.r(12125),n=e.r(963296),s=e.r(132324),a=e.r(668864),o=e.r(514421),l=e.r(696706).f,u=e.r(960123),c=e.r(881004),d=e.r(845198),h=e.r(286121),f=e.r(248421),p=!1,g=h("meta"),m=0,y=function(e){l(e,g,{value:{objectID:"O"+m++,weakData:{}}})},v=t.exports={enable:function(){v.enable=function(){},p=!0;var e=u.f,t=n([].splice),r={};r[g]=1,e(r).length&&(u.f=function(r){for(var i=e(r),n=0,s=i.length;n<s;n++)if(i[n]===g){t(i,n,1);break}return i},i({target:"Object",stat:!0,forced:!0},{getOwnPropertyNames:c.f}))},fastKey:function(e,t){if(!a(e))return"symbol"==typeof e?e:("string"==typeof e?"S":"P")+e;
vendor: 6,384 bytes, line 2360
2360if(!o(e,g)){if(!d(e))return"F";if(!t)return"E";y(e)}return e[g].objectID},getWeakData:function(e,t){if(!o(e,g)){if(!d(e))return!0;if(!t)return!1;y(e)}return e[g].weakData},onFreeze:function(e){return f&&p&&d(e)&&!o(e,g)&&y(e),e}};s[g]=!0},253849,(e,t,r)=>{"use strict";var i=e.r(553338),n=e.r(963296);t.exports=function(e){if("Function"===i(e))return n(e)}},381628,(e,t,r)=>{"use strict";var i=e.r(253849),n=e.r(287505),s=e.r(730309),a=i(i.bind);t.exports=function(e,t){return n(e),void 0===t?e:s?a(e,t):function(){return e.apply(t,arguments)}}},742762,(e,t,r)=>{"use strict";var i=e.r(873663),n=e.r(543740),s=i("iterator"),a=Array.prototype;t.exports=function(e){return void 0!==e&&(n.Array===e||a[s]===e)}},268125,(e,t,r)=>{"use strict";var i=e.r(51756),n=e.r(532638),s=e.r(744037),a=e.r(543740),o=e.r(873663)("iterator");t.exports=function(e){if(!s(e))return n(e,o)||n(e,"@@iterator")||a[i(e)]}},235153,(e,t,r)=>{"use strict";var i=e.r(10493),n=e.r(287505),s=e.r(722768),a=e.r(754770),o=e.r(268125),l=TypeError;t.exports=function(e,t){var r=arguments.length<2?o(e):t;if(n(r))return s(i(r,e));throw new l(a(e)+" is not iterable")}},485801,(e,t,r)=>{"use strict";var i=e.r(10493),n=e.r(722768),s=e.r(532638);t.exports=function(e,t,r){var a,o;n(e);try{if(!(a=s(e,"return"))){if("throw"===t)throw r;return r}a=i(a,e)}catch(e){o=!0,a=e}if("throw"===t)throw r;if(o)throw a;return n(a),r}},804201,(e,t,r)=>{"use strict";var i=e.r(381628),n=e.r(10493),s=e.r(722768),a=e.r(754770),o=e.r(742762),l=e.r(447961),u=e.r(650211),c=e.r(235153),d=e.r(268125),h=e.r(485801),f=TypeError,p=function(e,t){this.stopped=e,this.result=t},g=p.prototype;t.exports=function(e,t,r){var m,y,v,b,_,E,S,x=r&&r.that,T=!!(r&&r.AS_ENTRIES),w=!!(r&&r.IS_RECORD),A=!!(r&&r.IS_ITERATOR),R=!!(r&&r.INTERRUPTED),I=i(t,x),k=function(e){var t=m;return m=void 0,t&&h(t,"normal"),new p(!0,e)},C=function(e){return T?(s(e),R?I(e[0],e[1],k):I(e[0],e[1])):R?I(e,k):I(e)};if(w)m=e.iterator;else if(A)m=e;else{if(!(y=d(e)))throw new f(a(e)+" is not iterable");if(o(y)){for(v=0,b=l(e);b>v;v++)if((_=C(e[v]))&&u(g,_))return _;return new p(!1)}m=c(e,y)}for(E=w?e.next:m.next;!(S=n(E,m)).done;){var D=S.value;try{_=C(D)}catch(e){if(m)h(m,"throw",e);else throw e}if("object"==typeof _&&_&&u(g,_))return _}return new p(!1)}},87782,(e,t,r)=>{"use strict";var i=e.r(650211),n=TypeError;t.exports=function(e,t){if(i(t,e))return e;throw new n("Incorrect invocation")}},937913,(e,t,r)=>{"use strict";var i=e.r(873663)("iterator"),n=!1;try{var s=0,a={next:function(){return{done:!!s++}},return:function(){n=!0}};a[i]=function(){return this},Array.from(a,function(){throw 2})}catch(e){}t.exports=function(e,t){try{if(!t&&!n)return!1}catch(e){return!1}var r=!1;try{var s={};s[i]=function(){return{next:function(){return{done:r=!0}}}},e(s)}catch(e){}return r}},91038,(e,t,r)=>{"use strict";var i=e.r(853504),n=e.r(668864),s=e.r(47946);t.exports=function(e,t,r){var a,o;return s&&i(a=t.constructor)&&a!==r&&n(o=a.prototype)&&o!==r.prototype&&s(e,o),e}},974696,(e,t,r)=>{"use strict";var i=e.r(12125),n=e.r(493046),s=e.r(963296),a=e.r(700117),o=e.r(905001),l=e.r(840246),u=e.r(804201),c=e.r(87782),d=e.r(853504),h=e.r(744037),f=e.r(668864),p=e.r(834775),g=e.r(937913),m=e.r(369899),y=e.r(91038);t.exports=function(e,t,r){var v=-1!==e.indexOf("Map"),b=-1!==e.indexOf("Weak"),_=v?"set":"add",E=n[e],S=E&&E.prototype,x=E,T={},w=function(e){var t=s(S[e]);o(S,e,"add"===e?function(e){return t(this,0===e?0:e),this}:"delete"===e?function(e){return(!b||!!f(e))&&t(this,0===e?0:e)}:"get"===e?function(e){return b&&!f(e)?void 0:t(this,0===e?0:e)}:"has"===e?function(e){return(!b||!!f(e))&&t(this,0===e?0:e)}:function(e,r){return t(this,0===e?0:e,r),this})};if(a(e,!d(E)||!(b||S.forEach&&!p(function(){new E().entries().next()}))))x=r.getConstructor(t,e,v,_),l.enable();else if(a(e,!0)){var A=new x,R=A[_](b?{}:-0,1)!==A,I=p(function(){A.has(1)}),k=g(function(e){new E(e)}),C=!b&&p(function(){for(var e=new E,t=5;t--;)e[_](t,t);return!e.has(-0)});k||((x=t(function(e,t){c(e,S);var r=y(new E,e,x);return h(t)||u(t,r[_],{that:r,AS_ENTRIES:v}),r})).prototype=S,S.constructor=x),(I||C)&&(w("delete"),w("has"),v&&w("get")),(C||R)&&w(_),b&&S.clear&&delete S.clear}return T[e]=x,i({global:!0,constructor:!0,forced:x!==E},T),m(x,e),b||r.setStrong(x,e,v),x}},75529,(e,t,r)=>{"use strict";var i=e.r(686323),n=e.r(696706);t.exports=function(e,t,r){return r.get&&i(r.get,t,{getter:!0}),r.set&&i(r.set,t,{setter:!0}),n.f(e,t,r)}},475189,(e,t,r)=>{"use strict";var i=e.r(905001);t.exports=function(e,t,r){for(var n in t)i(e,n,t[n],r);return e}},509231,(e,t,r)=>{"use strict";var i=e.r(921064),n=e.r(75529),s=e.r(873663),a=e.r(226241),o=s("species");t.exports=function(e){var t=i(e);a&&t&&!t[o]&&n(t,o,{configurable:!0,get:function(){return this}})}},351905,(e,t,r)=>{"use strict";var i=e.r(547818),n=e.r(75529),s=e.r(475189),a=e.r(381628),o=e.r(87782),l=e.r(744037),u=e.r(804201),c=e.r(411758),d=e.r(241702),h=e.r(509231),f=e.r(226241),p=e.r(840246).fastKey,g=e.r(798884),m=g.set,y=g.getterFor;t.exports={getConstructor:function(e,t,r,c){var d=e(function(e,n){o(e,h),m(e,{type:t,index:i(null),first:null,last:null,size:0}),f||(e.size=0),l(n)||u(n,e[c],{that:e,AS_ENTRIES:r})}),h=d.prototype,g=y(t),v=function(e,t,r){var i,n,s=g(e),a=b(e,t);return a?a.value=r:(s.last=a={index:n=p(t,!0),key:t,value:r,previous:i=s.last,next:null,removed:!1},s.first||(s.first=a),i&&(i.next=a),f?s.size++:e.size++,"F"!==n&&(s.index[n]=a)),e},b=function(e,t){var r,i=g(e),n=p(t);if("F"!==n)return i.index[n];for(r=i.first;r;r=r.next)if(r.key===t)return r};return s(h,{clear:function(){for(var e=g(this),t=e.first;t;)t.removed=!0,t.previous&&(t.previous=t.previous.next=null),t=t.next;e.first=e.last=null,e.index=i(null),f?e.size=0:this.size=0},delete:function(e){var t=g(this),r=b(this,e);if(r){var i=r.next,n=r.previous;delete t.index[r.index],r.removed=!0,n&&(n.next=i),i&&(i.previous=n),t.first===r&&(t.first=i),t.last===r&&(t.last=n),f?t.size--:this.size--}return!!r},forEach:function(e){for(var t,r=g(this),i=a(e,arguments.length>1?arguments[1]:void 0);t=t?t.next:r.first;)for(i(t.value,t.key,this);t&&t.removed;)t=t.previous},has:function(e){return!!b(this,e)}}),s(h,r?{get:function(e){var t=b(this,e);return t&&t.value},set:function(e,t){return v(this,0===e?0:e,t)}}:{add:function(e){return v(this,e=0===e?0:e,e)}}),f&&n(h,"size",{configurable:!0,get:function(){return g(this).size}}
2360),d},setStrong:function(e,t,r){var i=t+" Iterator",n=y(t),s=y(i);c(e,t,function(e,t){m(this,{type:i,target:e,state:n(e),kind:t,last:null})},function(){for(var e=s(this),t=e.kind,r=e.last;r&&r.removed;)r=r.previous;return e.target&&(e.last=r=r?r.next:e.state.first)?"keys"===t?d(r.key,!1):"values"===t?d(r.value,!1):d([r.key,r.value],!1):(e.target=null,d(void 0,!0))},r?"entries":"values",!r,!0),h(t)}}},42593,(e,t,r)=>{"use strict";e.r(974696)("Set",function(e){return function(){return e(this,arguments.length?arguments[0]:void 0)}},e.r(351905))},15621,(e,t,r)=>{"use strict";e.r(42593)},684081,(e,t,r)=>{"use strict";var i=e.r(963296),n=Set.prototype;t.exports={Set:Set,add:i(n.add),has:i(n.has),remove:i(n.delete),proto:n}},647529,(e,t,r)=>{"use strict";var i=e.r(684081).has;t.exports=function(e){return i(e),e}},996357,(e,t,r)=>{"use strict";var i=e.r(10493);t.exports=function(e,t,r){for(var n,s,a=r?e:e.iterator,o=e.next;!(n=i(o,a)).done;)if(void 0!==(s=t(n.value)))return s}},399136,(e,t,r)=>{"use strict";var i=e.r(963296),n=e.r(996357),s=e.r(684081),a=s.Set,o=s.proto,l=i(o.forEach),u=i(o.keys),c=u(new a).next;t.exports=function(e,t,r){return r?n({iterator:u(e),next:c},t):l(e,t)}},722933,(e,t,r)=>{"use strict";var i=e.r(684081),n=e.r(399136),s=i.Set,a=i.add;t.exports=function(e){var t=new s;return n(e,function(e){a(t,e)}),t}},162308,(e,t,r)=>{"use strict";t.exports=e.r(415561)(e.r(684081).proto,"size","get")||function(e){return e.size}},778785,(e,t,r)=>{"use strict";t.exports=function(e){return{iterator:e,next:e.next,done:!1}}},384503,(e,t,r)=>{"use strict";var i=e.r(287505),n=e.r(722768),s=e.r(10493),a=e.r(686969),o=e.r(778785),l="Invalid size",u=RangeError,c=TypeError,d=Math.max,h=function(e,t){this.set=e,this.size=d(t,0),this.has=i(e.has),this.keys=i(e.keys)};h.prototype={getIterator:function(){return o(n(s(this.keys,this.set)))},includes:function(e){return s(this.has,this.set,e)}},t.exports=function(e){n(e);var t=+e.size;if(t!=t)throw new c(l);var r=a(t);if(r<0)throw new u(l);return new h(e,r)}},351393,(e,t,r)=>{"use strict";var i=e.r(647529),n=e.r(684081),s=e.r(722933),a=e.r(162308),o=e.r(384503),l=e.r(399136),u=e.r(996357),c=n.has,d=n.remove;t.exports=function(e){var t=i(this),r=o(e),n=s(t);return a(n)<=r.size?l(n,function(e){r.includes(e)&&d(n,e)}):u(r.getIterator(),function(e){c(n,e)&&d(n,e)}),n}},578514,(e,t,r)=>{"use strict";var i=e.r(921064),n=function(e){return{size:e,has:function(){return!1},keys:function(){return{next:function(){return{done:!0}}}}}},s=function(e){return{size:e,has:function(){return!0},keys:function(){throw Error("e")}}};t.exports=function(e,t){var r=i("Set");try{new r()[e](n(0));try{return new r()[e](n(-1)),!1}catch(i){if(!t)return!0;try{return new r()[e](s(-1/0)),!1}catch(i){var a=new r([1,2]);return t(a[e](s(1/0)))}}}catch(e){return!1}}},642606,(e,t,r)=>{"use strict";var i=e.r(12125),n=e.r(351393),s=e.r(834775);i({target:"Set",proto:!0,real:!0,forced:!e.r(578514)("difference",function(e){return 0===e.size})||s(function(){var e=new Set([1,2,3,4]);return 3!==e.difference({size:1,has:function(){return!0},keys:function(){var t=0;return{next:function(){var r=t++>1;return e.has(1)&&e.clear(),{done:r,value:2}}}}}).size})},{difference:n})},617008,(e,t,r)=>{"use strict";var i=e.r(647529),n=e.r(684081),s=e.r(162308),a=e.r(384503),o=e.r(399136),l=e.r(996357),u=n.Set,c=n.add,d=n.has;t.exports=function(e){var t=i(this),r=a(e),n=new u;return s(t)>r.size?l(r.getIterator(),function(e){d(t,e)&&c(n,e)}):o(t,function(e){r.includes(e)&&c(n,e)}),n}},575666,(e,t,r)=>{"use strict";var i=e.r(12125),n=e.r(834775),s=e.r(617008);i({target:"Set",proto:!0,real:!0,forced:!e.r(578514)("intersection",function(e){return 2===e.size&&e.has(1)&&e.has(2)})||n(function(){return"3,2"!==String(Array.from(new Set([1,2,3]).intersection(new Set([3,2]))))})},{intersection:s})},613260,(e,t,r)=>{"use strict";var i=e.r(647529),n=e.r(684081).has,s=e.r(162308),a=e.r(384503),o=e.r(399136),l=e.r(996357),u=e.r(485801);t.exports=function(e){var t=i(this),r=a(e);if(s(t)<=r.size)return!1!==o(t,function(e){if(r.includes(e))return!1},!0);var c=r.getIterator();return!1!==l(c,function(e){if(n(t,e))return u(c.iterator,"normal",!1)})}},321726,(e,t,r)=>{"use strict";var i=e.r(12125),n=e.r(613260);i({target:"Set",proto:!0,real:!0,forced:!e.r(578514)("isDisjointFrom",function(e){return!e})},{isDisjointFrom:n})},296334,(e,t,r)=>{"use strict";var i=e.r(647529),n=e.r(162308),s=e.r(399136),a=e.r(384503);t.exports=function(e){var t=i(this),r=a(e);return!(n(t)>r.size)&&!1!==s(t,function(e){if(!r.includes(e))return!1},!0)}},879518,(e,t,r)=>{"use strict";var i=e.r(12125),n=e.r(296334);i({target:"Set",proto:!0,real:!0,forced:!e.r(578514)("isSubsetOf",function(e){return e})},{isSubsetOf:n})},837196,(e,t,r)=>{"use strict";var i=e.r(647529),n=e.r(684081).has,s=e.r(162308),a=e.r(384503),o=e.r(996357
2360),l=e.r(485801);t.exports=function(e){var t=i(this),r=a(e);if(s(t)<r.size)return!1;var u=r.getIterator();return!1!==o(u,function(e){if(!n(t,e))return l(u.iterator,"normal",!1)})}},295616,(e,t,r)=>{"use strict";var i=e.r(12125),n=e.r(837196);i({target:"Set",proto:!0,real:!0,forced:!e.r(578514)("isSupersetOf",function(e){return!e})},{isSupersetOf:n})},615437,(e,t,r)=>{"use strict";var i=e.r(647529),n=e.r(684081),s=e.r(722933),a=e.r(384503),o=e.r(996357),l=n.add,u=n.has,c=n.remove;t.exports=function(e){var t=i(this),r=a(e).getIterator(),n=s(t);return o(r,function(e){u(t,e)?c(n,e):l(n,e)}),n}},174601,(e,t,r)=>{"use strict";t.exports=function(e){try{var t=new Set,r=t[e]({size:0,has:function(){return!0},keys:function(){return Object.defineProperty({},"next",{get:function(){return t.clear(),t.add(4),function(){return{done:!0}}}})}});return 1===r.size&&4===r.values().next().value}catch(e){return!1}}},303296,(e,t,r)=>{"use strict";var i=e.r(12125),n=e.r(615437),s=e.r(174601);i({target:"Set",proto:!0,real:!0,forced:!e.r(578514)("symmetricDifference")||!s("symmetricDifference")},{symmetricDifference:n})},539828,(e,t,r)=>{"use strict";var i=e.r(647529),n=e.r(684081).add,s=e.r(722933),a=e.r(384503),o=e.r(996357);t.exports=function(e){var t=i(this),r=a(e).getIterator(),l=s(t);return o(r,function(e){n(l,e)}),l}},549404,(e,t,r)=>{"use strict";var i=e.r(12125),n=e.r(539828),s=e.r(174601);i({target:"Set",proto:!0,real:!0,forced:!e.r(578514)("union")||!s("union")},{union:n})},955925,(e,t,r)=>{"use strict";var i=e.r(51756),n=String;t.exports=function(e){if("Symbol"===i(e))throw TypeError("Cannot convert a Symbol value to a string");return n(e)}},262479,(e,t,r)=>{"use strict";var i=e.r(963296),n=e.r(686969),s=e.r(955925),a=e.r(257081),o=i("".charAt),l=i("".charCodeAt),u=i("".slice),c=function(e){return function(t,r){var i,c,d=s(a(t)),h=n(r),f=d.length;return h<0||h>=f?e?"":void 0:(i=l(d,h))<55296||i>56319||h+1===f||(c=l(d,h+1))<56320||c>57343?e?o(d,h):i:e?u(d,h,h+2):(i-55296<<10)+(c-56320)+65536}};t.exports={codeAt:c(!1),charAt:c(!0)}},525169,(e,t,r)=>{"use strict";var i=e.r(262479).charAt,n=e.r(955925),s=e.r(798884),a=e.r(411758),o=e.r(241702),l="String Iterator",u=s.set,c=s.getterFor(l);a(String,"String",function(e){u(this,{type:l,string:n(e),index:0})},function(){var e,t=c(this),r=t.string,n=t.index;return n>=r.length?o(void 0,!0):(e=i(r,n),t.index+=e.length,o(e,!1))})},357044,(e,t,r)=>{"use strict";t.exports=e.r(493046)},719571,(e,t,r)=>{"use strict";e.r(475300),e.r(745680),e.r(15621),e.r(642606),e.r(575666),e.r(321726),e.r(879518),e.r(295616),e.r(303296),e.r(549404),e.r(525169),t.exports=e.r(357044).Set},750610,(e,t,r)=>{"use strict";t.exports={CSSRuleList:0,CSSStyleDeclaration:0,CSSValueList:0,ClientRectList:0,DOMRectList:0,DOMStringList:0,DOMTokenList:1,DataTransferItemList:0,FileList:0,HTMLAllCollection:0,HTMLCollection:0,HTMLFormElement:0,HTMLSelectElement:0,MediaList:0,MimeTypeArray:0,NamedNodeMap:0,NodeList:1,PaintRequestList:0,Plugin:0,PluginArray:0,SVGLengthList:0,SVGNumberList:0,SVGPathSegList:0,SVGPointList:0,SVGStringList:0,SVGTransformList:0,SourceBufferList:0,StyleSheetList:0,TextTrackCueList:0,TextTrackList:0,TouchList:0}},715424,(e,t,r)=>{"use strict";var i=e.r(881677)("span").classList,n=i&&i.constructor&&i.constructor.prototype;t.exports=n===Object.prototype?void 0:n},804474,(e,t,r)=>{"use strict";var i=e.r(493046),n=e.r(750610),s=e.r(715424),a=e.r(475300),o=e.r(598945),l=e.r(369899),u=e.r(873663)("iterator"),c=a.values,d=function(e,t){if(e){if(e[u]!==c)try{o(e,u,c)}catch(t){e[u]=c}if(l(e,t,!0),n[t]){for(var r in a)if(e[r]!==a[r])try{o(e,r,a[r])}catch(t){e[r]=a[r]}}}};for(var h in n)d(i[h]&&i[h].prototype,h);d(s,"DOMTokenList")},847214,(e,t,r)=>{"use strict";var i=e.r(719571);
2360e.r(804474),t.exports=i},428998,(e,t,r)=>{"use strict";e.r(642606)},600753,(e,t,r)=>{"use strict";e.r(575666)},39179,(e,t,r)=>{"use strict";e.r(321726)},219484,(e,t,r)=>{"use strict";e.r(879518)},123606,(e,t,r)=>{"use strict";e.r(295616)},632482,(e,t,r)=>{"use strict";e.r(303296)},738230,(e,t,r)=>{"use strict";e.r(549404)},171037,(e,t,r)=>{"use strict";var i=e.r(847214);e.r(428998),e.r(600753),e.r(39179),e.r(219484),e.r(123606),e.r(632482),e.r(738230),t.exports=i},808043,(e,t,r)=>{"use strict";var i=e.r(381628),n=e.r(722768),s=e.r(287867),a=e.r(804201);t.exports=function(e,t,r){return function(o){var l=s(o),u=arguments.length,c=u>1?arguments[1]:void 0,d=void 0!==c,h=d?i(c,u>2?arguments[2]:void 0):void 0,f=new e,p=0;return a(l,function(e){var i=d?h(e,p++):e;r?t(f,n(i)[0],i[1]):t(f,i)}),f}}},848831,(e,t,r)=>{"use strict";var i=e.r(12125),n=e.r(684081);i({target:"Set",stat:!0,forced:!0},{from:e.r(808043)(n.Set,n.add,!1)})},210145,(e,t,r)=>{"use strict";var i=e.r(722768);t.exports=function(e,t,r){return function(){for(var n=new e,s=arguments.length,a=0;a<s;a++){var o=arguments[a];r?t(n,i(o)[0],o[1]):t(n,o)}return n}}},724537,(e,t,r)=>{"use strict";var i=e.r(12125),n=e.r(684081);i({target:"Set",stat:!0,forced:!0},{of:e.r(210145)(n.Set,n.add,!1)})},485689,(e,t,r)=>{"use strict";var i=e.r(12125),n=e.r(647529),s=e.r(684081).add;i({target:"Set",proto:!0,real:!0,forced:!0},{addAll:function(){for(var e=n(this),t=0,r=arguments.length;t<r;t++)s(e,arguments[t]);return e}})},717622,(e,t,r)=>{"use strict";var i=e.r(12125),n=e.r(647529),s=e.r(684081).remove;i({target:"Set",proto:!0,real:!0,forced:!0},{deleteAll:function(){for(var e,t=n(this),r=!0,i=0,a=arguments.length;i<a;i++)e=s(t,arguments[i]),r=r&&e;return!!r}})},269677,(e,t,r)=>{"use strict";var i=e.r(12125),n=e.r(381628),s=e.r(647529),a=e.r(399136);i({target:"Set",proto:!0,real:!0,forced:!0},{every:function(e){var t=s(this),r=n(e,arguments.length>1?arguments[1]:void 0);return!1!==a(t,function(e){if(!r(e,e,t))return!1},!0)}})},320198,(e,t,r)=>{"use strict";var i=e.r(51756),n=e.r(514421),s=e.r(744037),a=e.r(873663),o=e.r(543740),l=a("iterator"),u=Object;t.exports=function(e){if(s(e))return!1;var t=u(e);return void 0!==t[l]||"@@iterator"in t||n(o,i(t))}},877629,(e,t,r)=>{"use strict";var i=e.r(921064),n=e.r(853504),s=e.r(320198),a=e.r(668864),o=i("Set");t.exports=function(e){return a(e)&&"number"==typeof e.size&&n(e.has)&&n(e.keys)?e:s(e)?new o(e):e}},448257,(e,t,r)=>{"use strict";var i=e.r(12125),n=e.r(10493),s=e.r(877629),a=e.r(351393);i({target:"Set",proto:!0,real:!0,forced:!0},{difference:function(e){return n(a,this,s(e))}})},109255,(e,t,r)=>{"use strict";var i=e.r(12125),n=e.r(381628),s=e.r(647529),a=e.r(684081),o=e.r(399136),l=a.Set,u=a.add;i({target:"Set",proto:!0,real:!0,forced:!0},{filter:function(e){var t=s(this),r=n(e,arguments.length>1?arguments[1]:void 0),i=new l;return o(t,function(e){r(e,e,t)&&u(i,e)}),i}})},333232,(e,t,r)=>{"use strict";var i=e.r(12125),n=e.r(381628),s=e.r(647529),a=e.r(399136);i({target:"Set",proto:!0,real:!0,forced:!0},{find:function(e){var t=s(this),r=n(e,arguments.length>1?arguments[1]:void 0),i=a(t,function(e){if(r(e,e,t))return{value:e}},!0);return i&&i.value}})},120941,(e,t,r)=>{"use strict";var i=e.r(12125),n=e.r(10493),s=e.r(877629),a=e.r(617008);i({target:"Set",proto:!0,real:!0,forced:!0},{intersection:function(e){return n(a,this,s(e))}})},439029,(e,t,r)=>{"use strict";var i=e.r(12125),n=e.r(10493),s=e.r(877629),a=e.r(613260);i({target:"Set",proto:!0,real:!0,forced:!0},{isDisjointFrom:function(e){return n(a,this,s(e))}})},280778,(e,t,r)=>{"use strict";var i=e.r(12125),n=e.r(10493),s=e.r(877629),a=e.r(296334);i({target:"Set",proto:!0,real:!0,forced:!0},{isSubsetOf:function(e){return n(a,this,s(e))}})},396049,(e,t,r)=>{"use strict";var i=e.r(12125),n=e.r(10493),s=e.r(877629),a=e.r(837196);i({target:"Set",proto:!0,real:!0,forced:!0},{isSupersetOf:function(e){return n(a,this,s(e))}})},796730,(e,t,r)=>{"use strict";var i=e.r(12125),n=e.r(963296),s=e.r(647529),a=e.r(399136),o=e.r(955925),l=n([].join),u=n([].push);i({target:"Set",proto:!0,real:!0,forced:!0},{join:function(e){var t=s(this),r=void 0===e?",":o(e),i=[];return a(t,function(e){u(i,e)}),l(i,r)}})},574925,(e,t,r)=>{"use strict";var i=e.r(12125),n=e.r(381628),s=e.r(647529),a=e.r(684081),o=e.r(399136),l=a.Set,u=a.add;i({target:"Set",proto:!0,real:!0,forced:!0},{map:function(e){var t=s(this),r=n(e,arguments.length>1?arguments[1]:void 0),i=new l;return o(t,function(e){u(i,r(e,e,t))}),i}})},781887,(e,t,r)=>{"use strict";var i=e.r(12125),n=e.r(287505),s=e.r(647529),a=e.r(399136),o=TypeError;i({target:"Set",proto:!0,real:!0,forced:!0},{reduce:function(e){var t=s(this),r=arguments.length<2,i=r?void 0:arguments[1];if(n(e),a(t,function(n){r?(r=!1,i=n):i=e(i,n,n,t)}),r)throw new o("Reduce of empty set with no initial value");return i}})},293613,(e,t,r)=>{"use strict";var i=e.r(12125),n=e.r(381628),s=e.r(647529),a=e.r(399136);i({target:"Set",proto:!0,real:!0,forced:!0},{some:function(e){var t=s(this),r=n(e,arguments.length>1?arguments[1]:void 0);return!0===a(t,function(e){if(r(e,e,t))return!0},!0)}})},104529,(e,t,r)=>{"use strict";var i=e.r(12125),n=e.r(10493),s=e.r(877629),a=e.r(615437);i({target:"Set",proto:!0,real:!0,forced:!0},{symmetricDifference:function(e){return n(a,this,s(e))}})},763123,(e,t,r)=>{"use strict";var i=e.r(12125),n=e.r(10493),s=e.r(877629),a=e.r(539828);i({target:"Set",proto:!0,real:!0,forced:!0},{union:function(e){return n(a,this,s(e))}})},160026,(e,t,r)=>{"use strict";var i=e.r(171037);e.r(848831),e.r(724537),e.r(485689),e.r(717622),e.r(269677),e.r(448257),e.r(109255),e.r(333232),e.r(120941),e.r(439029),e.r(280778),e.r(396049),e.r(796730),e.r(574925),e.r(781887),e.r(293613),e.r(104529),e.r(763123),t.exp
2360orts=i},238973,(e,t,r)=>{"use strict";t.exports=e.r(160026)},800883,123557,e=>{"use strict";var t=e.i(843476),r=e.i(271645),i=e.i(997053),n=e.i(4154),s=e.i(719631),a=e.i(63280),o=e.i(417734),l=e.i(94332),u=e.i(838478),c=e.i(535289),d=e.i(775268);let h=/(\r\n|\r|\n)/g;function f(e){return"string"!=typeof e?e:e.split(h).map(function(e,t){return e.match(h)?r.default.createElement("br",{key:t}):e})}e.s(["nl2br",0,f],123557);var p=e.i(728016);let g=i.default.div.withConfig({displayName:"ImageBox__Title",componentId:"sc-16807def-0"})` 2361 font-weight: bold; 2362 font-size: 24px; 2363 margin-bottom: 16px; 2364 line-height: 1; 2365 2366 ${l.mq.sm} { 2367 font-size: 32px; 2368 } 2369 2370 span { 2371 text-decoration: none; 2372 line-height: 1.5; 2373 padding-bottom: 3px; 2374 ${e=>`background-image: linear-gradient(${e.theme.color.gold}, ${e.theme.color.gold})`}; 2375 background-position: 0% 100%; 2376 background-repeat: no-repeat; 2377 background-size: 0% 2px; 2378 transition: background-size 0.3s; 2379 } 2380`,m=i.default.div.withConfig({displayName:"ImageBox__ImageWrapper",componentId:"sc-16807def-1"})` 2381 width: 166px; 2382 height: 264px; 2383 flex-shrink: 0; 2384 background-color: #fbfbfb; 2385 ${e=>e.mb&&"margin-bottom: 40px;"} 2386 2387 ${l.mq.sm} { 2388 width: 264px; 2389 height: 416px; 2390 } 2391`,y=i.default.div.withConfig({displayName:"ImageBox__Info",componentId:"sc-16807def-2"})` 2392 background-color: #fff; 2393 padding: 20px 32px; 2394 2395 ${l.mq.sm} { 2396 padding: 48px; 2397 } 2398`,v=i.default.div.withConfig({displayName:"ImageBox__InfoWrapper",componentId:"sc-16807def-3"})` 2399 position: relative; 2400 z-index: 2; 2401 width: 250px; 2402 margin-left: -72px; 2403 margin-top: 26px; 2404 ${l.mq.sm} { 2405 max-width: 320px; 2406 width: 100%; 2407 } 2408`,b=i.default.article.withConfig({displayName:"ImageBox__Wrapper",componentId:"sc-16807def-4"})` 2409 display: flex; 2410 flex-direction: row; 2411 flex-wrap: nowrap; 2412 justify-content: center; 2413 align-items: flex-start; 2414 2415 &:hover ${g} span { 2416 background-size: 100% 2px; 2417 } 2418`,_=i.default.div.withConfig({displayName:"ImageBox__Genre",componentId:"sc-16807def-5"})` 2419 margin-bottom: 16px; 2420 ${l.mq.sm} { 2421 margin-bottom: 20px; 2422 } 2423`,E=i.default.div.withConfig({displayName:"ImageBox__Name",componentId:"sc-16807def-6"})` 2424 margin-bottom: 16px; 2425 font-weight: bold; 2426 font-size: 16px; 2427 2428 ${l.mq.sm} { 2429 margin-bottom: 24px; 2430 font-size: 24px; 2431 } 2432`,S=(0,i.default)(n.Icon).withConfig({displayName:"ImageBox__StyledIcon",componentId:"sc-16807def-7"})` 2433 width: 16px; 2434 margin-right: 8px; 2435`,x=i.default.p.withConfig({displayName:"ImageBox__Subtitle",componentId:"sc-16807def-8"})` 2436 margin: 16px 0 24px; 2437`,T=i.default.div.withConfig({displayName:"ImageBox__Tags",componentId:"sc-16807def-9"})` 2438 display: flex; 2439 flex-direction: column; 2440 align-items: flex-end; 2441 padding-right: 48px; 2442`;e.s(["ImageBox",0,({genre:e,name:n,title:l,subtitle:h,venues:w,ensemble:A,image:R,alt:I,className:k,mb:C,tags:D,forceShowGenre:L=!1})=>{let O=(0,r.useContext)(i.ThemeContext)??u.theme,P=(A?.statute==="VlastnÃ"||L)&&e&&(0,s.resolveEnsembleStyle)(e,O.color);if(!(0,r.useContext)(o.AppContext).productionPage)throw Error("Neexistuje stranka detailu predstaveni");return(0,t.jsxs)(b,{className:k,children:[(0,t.jsx)(m,{mb:C,children:R&&(0,t.jsx)(c.Image,{src:R,width:264,height:416,fit:"crop",alt:I,layout:"cover",sizes:"(min-width: 640px) 264px, 166px"})}),(0,t.jsxs)(v,{children:[D&&D.length>0&&(0,t.jsx)(T,{children:D.slice(0,2).map(e=>e&&e.title&&(0,t.jsx)(d.Tag,{color:"black",marginBottom:!0,noSelfAlign:!0,children:e.title},String(e.id)))}),(0,t.jsxs)(y,{children:[(0,t.jsxs)(_,{children:[P&&(0,t.jsx)(S,{name:P.icon,color:P.color})," ",e,A?.statute!=="VlastnÃ"&&(0,t.jsxs)(t.Fragment,{children:[(0,t.jsx)("br",{}),(0,p.nbsp)(A?.title)]})]}),l&&(0,t.jsx)(g,{children:(0,t.jsx)("span",{children:(0,p.nbsp)(l)})}),n&&(0,t.jsx)(E,{children:(0,p.nbsp)(n)}),h&&(0,t.jsx)(x,{children:f((0,p.nbsp)(h))}),w&&(0,t.jsx)(a.Label,{serif:!0,children:(0,p.nbsp)(w)})]})]})]})}],800883)},573878,e=>{"use strict";var t=e.i(843476),r=e.i(271645),i=e.i(838478);let n=({children:e,...i})=>{let n=(()=>{let[e,t]=(0,r.useState)(!1);return(0,r.useEffect)(()=>{let e=window.requestAnimationFrame(()=>{t(!0)});return()=>{window.cancelAnimationFrame(e)}},[]),e})(),s=(e=>{let t=(({maxDeviceWidth:e,maxWidth:t,minDeviceWidth:r,minWidth:i})=>["number"==typeof i?`(min-width: ${i}px)`:null,"number"==typeof r?`(min-device-width: ${r}px)`:null,"number"==typeof t?`(max-width: ${t}px)`:null,"number"==typeof e?`(max-device-width: ${e}
2442px)`:null].filter(Boolean).join(" and "))(e),[i,n]=(0,r.useState)(!1);return(0,r.useEffect)(()=>{if(!t||"function"!=typeof window.matchMedia){let e=window.requestAnimationFrame(()=>{n(!0)});return()=>{window.cancelAnimationFrame(e)}}let e=window.matchMedia(t),r=()=>n(e.matches);return r(),"function"==typeof e.addEventListener?(e.addEventListener("change",r),()=>{e.removeEventListener("change",r)}):(e.addListener?.(r),()=>{e.removeListener?.(r)})},[t]),i})(i);return n&&s?(0,t.jsx)(t.Fragment,{children:e}):null};e.s(["Medium",0,({children:e})=>(0,t.jsx)(n,{minDeviceWidth:i.theme.bp.md,children:e}),"MediumL",0,({children:e})=>(0,t.jsx)(n,{minDeviceWidth:i.theme.bp.mdl,children:e}),"MediumLMax",0,({children:e})=>(0,t.jsx)(n,{maxDeviceWidth:i.theme.bp.mdl-1,children:e}),"MediumMax",0,({children:e})=>(0,t.jsx)(n,{maxDeviceWidth:i.theme.bp.md-1,children:e}),"MediumViewport",0,({children:e})=>(0,t.jsx)(n,{minWidth:i.theme.bp.md,children:e}),"Small",0,({children:e})=>(0,t.jsx)(n,{minDeviceWidth:i.theme.bp.sm,children:e}),"SmallMax",0,({children:e})=>(0,t.jsx)(n,{maxDeviceWidth:i.theme.bp.sm-1,children:e})])},345915,e=>{"use strict";let t,r=Number.isFinite||function(e){return"number"==typeof e&&isFinite(e)},i=Number.isSafeInteger||function(e){return"number"==typeof e&&Math.abs(e)<=n},n=Number.MAX_SAFE_INTEGER||0x1fffffffffffff,s=((y={}).NETWORK_ERROR="networkError",y.MEDIA_ERROR="mediaError",y.KEY_SYSTEM_ERROR="keySystemError",y.MUX_ERROR="muxError",y.OTHER_ERROR="otherError",y),a=((v={}).KEY_SYSTEM_NO_KEYS="keySystemNoKeys",v.KEY_SYSTEM_NO_ACCESS="keySystemNoAccess",v.KEY_SYSTEM_NO_SESSION="keySystemNoSession",v.KEY_SYSTEM_NO_CONFIGURED_LICENSE="keySystemNoConfiguredLicense",v.KEY_SYSTEM_LICENSE_REQUEST_FAILED="keySystemLicenseRequestFailed",v.KEY_SYSTEM_SERVER_CERTIFICATE_REQUEST_FAILED="keySystemServerCertificateRequestFailed",v.KEY_SYSTEM_SERVER_CERTIFICATE_UPDATE_FAILED="keySystemServerCertificateUpdateFailed",v.KEY_SYSTEM_SESSION_UPDATE_FAILED="keySystemSessionUpdateFailed",v.KEY_SYSTEM_STATUS_OUTPUT_RESTRICTED="keySystemStatusOutputRestricted",v.KEY_SYSTEM_STATUS_INTERNAL_ERROR="keySystemStatusInternalError",v.KEY_SYSTEM_DESTROY_MEDIA_KEYS_ERROR="keySystemDestroyMediaKeysError",v.KEY_SYSTEM_DESTROY_CLOSE_SESSION_ERROR="keySystemDestroyCloseSessionError",v.KEY_SYSTEM_DESTROY_REMOVE_SESSION_ERROR="keySystemDestroyRemoveSessionError",v.MANIFEST_LOAD_ERROR="manifestLoadError",v.MANIFEST_LOAD_TIMEOUT="manifestLoadTimeOut",v.MANIFEST_PARSING_ERROR="manifestParsingError",v.MANIFEST_INCOMPATIBLE_CODECS_ERROR="manifestIncompatibleCodecsError",v.LEVEL_EMPTY_ERROR="levelEmptyError",v.LEVEL_LOAD_ERROR="levelLoadError",v.LEVEL_LOAD_TIMEOUT="levelLoadTimeOut",v.LEVEL_PARSING_ERROR="levelParsingError",v.LEVEL_SWITCH_ERROR="levelSwitchError",v.AUDIO_TRACK_LOAD_ERROR="audioTrackLoadError",v.AUDIO_TRACK_LOAD_TIMEOUT="audioTrackLoadTimeOut",v.SUBTITLE_LOAD_ERROR="subtitleTrackLoadError",v.SUBTITLE_TRACK_LOAD_TIMEOUT="subtitleTrackLoadTimeOut",v.FRAG_LOAD_ERROR="fragLoadError",v.FRAG_LOAD_TIMEOUT="fragLoadTimeOut",v.FRAG_DECRYPT_ERROR="fragDecryptError",v.FRAG_PARSING_ERROR="fragParsingError",v.FRAG_GAP="fragGap",v.REMUX_ALLOC_ERROR="remuxAllocError",v.KEY_LOAD_ERROR="keyLoadError",v.KEY_LOAD_TIMEOUT="keyLoadTimeOut",v.BUFFER_ADD_CODEC_ERROR="bufferAddCodecError",v.BUFFER_INCOMPATIBLE_CODECS_ERROR="bufferIncompatibleCodecsError",v.BUFFER_APPEND_ERROR="bufferAppendError",v.BUFFER_APPENDING_ERROR="bufferAppendingError",v.BUFFER_STALLED_ERROR="bufferStalledError",v.BUFFER_FULL_ERROR="bufferFullError",v.BUFFER_SEEK_OVER_HOLE="bufferSeekOverHole",v.BUFFER_NUDGE_ON_STALL="bufferNudgeOnStall",v.ASSET_LIST_LOAD_ERROR="assetListLoadError",v.ASSET_LIST_LOAD_TIMEOUT="assetListLoadTimeout",v.ASSET_LIST_PARSING_ERROR="assetListParsingError",v.INTERSTITIAL_ASSET_ITEM_ERROR="interstitialAssetItemError",v.INTERNAL_EXCEPTION="internalException",v.INTERNAL_ABORTED="aborted",v.ATTACH_MEDIA_ERROR="attachMediaError",v.UNKNOWN="unknown",v),o=((b={}
vendor: 4,018 bytes, line 2442
2442).MEDIA_ATTACHING="hlsMediaAttaching",b.MEDIA_ATTACHED="hlsMediaAttached",b.MEDIA_DETACHING="hlsMediaDetaching",b.MEDIA_DETACHED="hlsMediaDetached",b.MEDIA_ENDED="hlsMediaEnded",b.STALL_RESOLVED="hlsStallResolved",b.BUFFER_RESET="hlsBufferReset",b.BUFFER_CODECS="hlsBufferCodecs",b.BUFFER_CREATED="hlsBufferCreated",b.BUFFER_APPENDING="hlsBufferAppending",b.BUFFER_APPENDED="hlsBufferAppended",b.BUFFER_EOS="hlsBufferEos",b.BUFFERED_TO_END="hlsBufferedToEnd",b.BUFFER_FLUSHING="hlsBufferFlushing",b.BUFFER_FLUSHED="hlsBufferFlushed",b.MANIFEST_LOADING="hlsManifestLoading",b.MANIFEST_LOADED="hlsManifestLoaded",b.MANIFEST_PARSED="hlsManifestParsed",b.LEVEL_SWITCHING="hlsLevelSwitching",b.LEVEL_SWITCHED="hlsLevelSwitched",b.LEVEL_LOADING="hlsLevelLoading",b.LEVEL_LOADED="hlsLevelLoaded",b.LEVEL_UPDATED="hlsLevelUpdated",b.LEVEL_PTS_UPDATED="hlsLevelPtsUpdated",b.LEVELS_UPDATED="hlsLevelsUpdated",b.AUDIO_TRACKS_UPDATED="hlsAudioTracksUpdated",b.AUDIO_TRACK_SWITCHING="hlsAudioTrackSwitching",b.AUDIO_TRACK_SWITCHED="hlsAudioTrackSwitched",b.AUDIO_TRACK_LOADING="hlsAudioTrackLoading",b.AUDIO_TRACK_LOADED="hlsAudioTrackLoaded",b.AUDIO_TRACK_UPDATED="hlsAudioTrackUpdated",b.SUBTITLE_TRACKS_UPDATED="hlsSubtitleTracksUpdated",b.SUBTITLE_TRACKS_CLEARED="hlsSubtitleTracksCleared",b.SUBTITLE_TRACK_SWITCH="hlsSubtitleTrackSwitch",b.SUBTITLE_TRACK_LOADING="hlsSubtitleTrackLoading",b.SUBTITLE_TRACK_LOADED="hlsSubtitleTrackLoaded",b.SUBTITLE_TRACK_UPDATED="hlsSubtitleTrackUpdated",b.SUBTITLE_FRAG_PROCESSED="hlsSubtitleFragProcessed",b.CUES_PARSED="hlsCuesParsed",b.NON_NATIVE_TEXT_TRACKS_FOUND="hlsNonNativeTextTracksFound",b.INIT_PTS_FOUND="hlsInitPtsFound",b.FRAG_LOADING="hlsFragLoading",b.FRAG_LOAD_EMERGENCY_ABORTED="hlsFragLoadEmergencyAborted",b.FRAG_LOADED="hlsFragLoaded",b.FRAG_DECRYPTED="hlsFragDecrypted",b.FRAG_PARSING_INIT_SEGMENT="hlsFragParsingInitSegment",b.FRAG_PARSING_USERDATA="hlsFragParsingUserdata",b.FRAG_PARSING_METADATA="hlsFragParsingMetadata",b.FRAG_PARSED="hlsFragParsed",b.FRAG_BUFFERED="hlsFragBuffered",b.FRAG_CHANGED="hlsFragChanged",b.FPS_DROP="hlsFpsDrop",b.FPS_DROP_LEVEL_CAPPING="hlsFpsDropLevelCapping",b.MAX_AUTO_LEVEL_UPDATED="hlsMaxAutoLevelUpdated",b.ERROR="hlsError",b.DESTROYING="hlsDestroying",b.KEY_LOADING="hlsKeyLoading",b.KEY_LOADED="hlsKeyLoaded",b.LIVE_BACK_BUFFER_REACHED="hlsLiveBackBufferReached",b.BACK_BUFFER_REACHED="hlsBackBufferReached",b.STEERING_MANIFEST_LOADED="hlsSteeringManifestLoaded",b.ASSET_LIST_LOADING="hlsAssetListLoading",b.ASSET_LIST_LOADED="hlsAssetListLoaded",b.INTERSTITIALS_UPDATED="hlsInterstitialsUpdated",b.INTERSTITIALS_BUFFERED_TO_BOUNDARY="hlsInterstitialsBufferedToBoundary",b.INTERSTITIAL_ASSET_PLAYER_CREATED="hlsInterstitialAssetPlayerCreated",b.INTERSTITIAL_STARTED="hlsInterstitialStarted",b.INTERSTITIAL_ASSET_STARTED="hlsInterstitialAssetStarted",b.INTERSTITIAL_ASSET_ENDED="hlsInterstitialAssetEnded",b.INTERSTITIAL_ASSET_ERROR="hlsInterstitialAssetError",b.INTERSTITIAL_ENDED="hlsInterstitialEnded",b.INTERSTITIALS_PRIMARY_RESUMED="hlsInterstitialsPrimaryResumed",b.PLAYOUT_LIMIT_REACHED="hlsPlayoutLimitReached",b.EVENT_CUE_ENTER="hlsEventCueEnter",b);var l,u,c,d,h,f,p,g,m,y,v,b,_,E,S="manifest",x="level",T="audioTrack",w="subtitleTrack",A="main",R="audio",I="subtitle";class k{constructor(e,t=0,r=0){this.halfLife=void 0,this.alpha_=void 0,this.estimate_=void 0,this.totalWeight_=void 0,this.halfLife=e,this.alpha_=e?Math.exp(Math.log(.5)/e):0,this.estimate_=t,this.totalWeight_=r}sample(e,t){let r=Math.pow(this.alpha_,e);this.estimate_=t*(1-r)+r*this.estimate_,this.totalWeight_+=e}getTotalWeight(){return this.totalWeight_}getEstimate(){if(this.alpha_){let e=1-Math.pow(this.alpha_,this.totalWeight_);if(e)return this.estimate_/e}return this.estimate_}}class C{constructor(e,t,r,i=100){this.defaultEstimate_=void 0,this.minWeight_=void 0,this.minDelayMs_=void 0,this.slow_=void 0,this.fast_=void 0,this.defaultTTFB_=void 0,this.ttfb_=void 0,this.defaultEstimate_=r,this.minWeight_=.001,this.minDelayMs_=50,this.slow_
2442=new k(e),this.fast_=new k(t),this.defaultTTFB_=i,this.ttfb_=new k(e)}update(e,t){let{slow_:r,fast_:i,ttfb_:n}=this;r.halfLife!==e&&(this.slow_=new k(e,r.getEstimate(),r.getTotalWeight())),i.halfLife!==t&&(this.fast_=new k(t,i.getEstimate(),i.getTotalWeight())),n.halfLife!==e&&(this.ttfb_=new k(e,n.getEstimate(),n.getTotalWeight()))}sample(e,t){let r=(e=Math.max(e,this.minDelayMs_))/1e3,i=8*t/r;this.fast_.sample(r,i),this.slow_.sample(r,i)}sampleTTFB(e){let t=Math.sqrt(2)*Math.exp(-Math.pow(e/1e3,2)/2);this.ttfb_.sample(t,Math.max(e,5))}canEstimate(){return this.fast_.getTotalWeight()>=this.minWeight_}getEstimate(){return this.canEstimate()?Math.min(this.fast_.getEstimate(),this.slow_.getEstimate()):this.defaultEstimate_}getEstimateTTFB(){return this.ttfb_.getTotalWeight()>=this.minWeight_?this.ttfb_.getEstimate():this.defaultTTFB_}get defaultEstimate(){return this.defaultEstimate_}destroy(){}}function D(){return(D=Object.assign.bind()).apply(null,arguments)}function L(e,t){var r=Object.keys(e);if(Object.getOwnPropertySymbols){var i=Object.getOwnPropertySymbols(e);t&&(i=i.filter(function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable})),r.push.apply(r,i)}return r}function O(e){for(var t=1;t<arguments.length;t++){var r=null!=arguments[t]?arguments[t]:{};t%2?L(Object(r),!0).forEach(function(t){var i,n;i=t,n=r[t],(i=function(e){var t=function(e,t){if("object"!=typeof e||!e)return e;var r=e[Symbol.toPrimitive];if(void 0!==r){var i=r.call(e,t);if("object"!=typeof i)return i;throw TypeError("@@toPrimitive must return a primitive value.")}return("string"===t?String:Number)(e)}(e,"string");return"symbol"==typeof t?t:t+""}(i))in e?Object.defineProperty(e,i,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[i]=n}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(r)):L(Object(r)).forEach(function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(r,t))})}return e}class P{constructor(e,t){this.trace=void 0,this.debug=void 0,this.log=void 0,this.warn=void 0,this.info=void 0,this.error=void 0;const r=`[${e}]:`;this.trace=F,this.debug=t.debug.bind(null,r),this.log=t.log.bind(null,r),this.warn=t.warn.bind(null,r),this.info=t.info.bind(null,r),this.error=t.error.bind(null,r)}}let F=function(){},N={trace:F,debug:F,log:F,warn:F,info:F,error:F};function M(){return D({},N)}function j(e,t,r){let i;return t[e]?t[e].bind(t):(i=self.console[e])?i.bind(self.console,`${r?"["+r+"] ":""}[${e}] >`):F}let $=M();function U(e=!0){if(!("u"<typeof self))return(e||!self.MediaSource)&&self.ManagedMediaSource||self.MediaSource||self.WebKitMediaSource}function B(e,t){let r=Object.keys(e),i=Object.keys(t),n=r.length,s=i.length;return!n||!s||n===s&&!r.some(e=>-1===i.indexOf(e))}function V(e,t=!1){let r,i;if("u">typeof TextDecoder){let r=new TextDecoder("utf-8").decode(e);if(t){let e=r.indexOf("\0");return -1!==e?r.substring(0,e):r}return r.replace(/\0/g,"")}let n=e.length,s="",a=0;for(;a<n&&(0!==(r=e[a++])||!t);)if(0!==r&&3!==r)switch(r>>4){case 0:case 1:case 2:case 3:case 4:case 5:case 6:case 7:s+=String.fromCharCode(r);break;case 12:case 13:s+=String.fromCharCode((31&r)<<6|63&(i=e[a++]));break;case 14:s+=String.fromCharCode((15&r)<<12|(63&(i=e[a++]))<<6|63&e[a++])}return s}function G(e){let t="";for(let r=0;r<e.length;r++){let i=e[r].toString(16);i.length<2&&(i="0"+i),t+=i}return t}function q(e){return Uint8Array.from(e.replace(/^0x/,"").replace(/([\da-fA-F]{2}) ?/g,"0x$1 ").replace(/ +$/,"").split(" ")).buffer}var H={exports:{}},z=_?H.exports:(_=1,l=/^(?=((?:[a-zA-Z0-9+\-.]+:)?))\1(?=((?:\/\/[^\/?#]*)?))\2(?=((?:(?:[^?#\/]*\/)*[^;?#\/]*)?))\3((?:;[^?#]*)?)(\?[^#]*)?(#[^]*)?$/,u=/^(?=([^\/?#]*))\1([^]*)$/,c=/(?:\/|^)\.(?=\/)/g,d=/(?:\/|^)\.\.\/(?!\.\.\/)[^\/]*(?=\/)/g,H.exports=h={buildAbsoluteURL:function(e,t,r){if(r=r||{},e=e.trim(),!(t=t.trim())){if(!r.alwaysNormalize)return e;var i=h.parseURL(e);if(!i)throw Error("Error trying to parse base URL.");return i.path=h.normalizePath(i.path),h.buildURLFromParts(i)}var n=h.parseURL(t);if(!n)throw Error("Error trying to parse relative URL.");if(n.scheme)return r.alwaysNormalize?(n.path=h.normalizePath(n.path),h.buildURLFromParts(n)):t;var s=h.parseURL(e);if(!s)throw Error("Error trying to parse base URL.");
vendor: 4,132 bytes, line 2442
2442if(!s.netLoc&&s.path&&"/"!==s.path[0]){var a=u.exec(s.path);s.netLoc=a[1],s.path=a[2]}s.netLoc&&!s.path&&(s.path="/");var o={scheme:s.scheme,netLoc:n.netLoc,path:null,params:n.params,query:n.query,fragment:n.fragment};if(!n.netLoc&&(o.netLoc=s.netLoc,"/"!==n.path[0]))if(n.path){var l=s.path,c=l.substring(0,l.lastIndexOf("/")+1)+n.path;o.path=h.normalizePath(c)}else o.path=s.path,!n.params&&(o.params=s.params,n.query||(o.query=s.query));return null===o.path&&(o.path=r.alwaysNormalize?h.normalizePath(n.path):n.path),h.buildURLFromParts(o)},parseURL:function(e){var t=l.exec(e);return t?{scheme:t[1]||"",netLoc:t[2]||"",path:t[3]||"",params:t[4]||"",query:t[5]||"",fragment:t[6]||""}:null},normalizePath:function(e){for(e=e.split("").reverse().join("").replace(c,"");e.length!==(e=e.replace(d,"")).length;);return e.split("").reverse().join("")},buildURLFromParts:function(e){return e.scheme+e.netLoc+e.path+e.params+e.query+e.fragment}},H.exports);class K{constructor(){this.aborted=!1,this.loaded=0,this.retry=0,this.total=0,this.chunkCount=0,this.bwEstimate=0,this.loading={start:0,first:0,end:0},this.parsing={start:0,end:0},this.buffering={start:0,first:0,end:0}}}var W="audio",Y="video",Q="audiovideo";class X{constructor(e){this._byteRange=null,this._url=null,this._stats=null,this._streams=null,this.base=void 0,this.relurl=void 0,"string"==typeof e&&(e={url:e}),this.base=e,function(e,t){let r=function e(t,r){let i=Object.getPrototypeOf(t);if(i){let t=Object.getOwnPropertyDescriptor(i,r);return t||e(i,r)}}(e,t);r&&(r.enumerable=!0,Object.defineProperty(e,t,r))}(this,"stats")}setByteRange(e,t){let r,i=e.split("@",2);r=1===i.length?(null==t?void 0:t.byteRangeEndOffset)||0:parseInt(i[1]),this._byteRange=[r,parseInt(i[0])+r]}get baseurl(){return this.base.url}get byteRange(){return null===this._byteRange?[]:this._byteRange}get byteRangeStartOffset(){return this.byteRange[0]}get byteRangeEndOffset(){return this.byteRange[1]}get elementaryStreams(){return null===this._streams&&(this._streams={[W]:null,[Y]:null,[Q]:null}),this._streams}set elementaryStreams(e){this._streams=e}get hasStats(){return null!==this._stats}get hasStreams(){return null!==this._streams}get stats(){return null===this._stats&&(this._stats=new K),this._stats}set stats(e){this._stats=e}get url(){return!this._url&&this.baseurl&&this.relurl&&(this._url=z.buildAbsoluteURL(this.baseurl,this.relurl,{alwaysNormalize:!0})),this._url||""}set url(e){this._url=e}clearElementaryStreamInfo(){let{elementaryStreams:e}=this;e[W]=null,e[Y]=null,e[Q]=null}}function J(e){return"initSegment"!==e.sn}class Z extends X{constructor(e,t){super(t),this._decryptdata=null,this._programDateTime=null,this._ref=null,this._bitrate=void 0,this.rawProgramDateTime=null,this.tagList=[],this.duration=0,this.sn=0,this.levelkeys=void 0,this.type=void 0,this.loader=null,this.keyLoader=null,this.level=-1,this.cc=0,this.startPTS=void 0,this.endPTS=void 0,this.startDTS=void 0,this.endDTS=void 0,this.start=0,this.playlistOffset=0,this.deltaPTS=void 0,this.maxStartPTS=void 0,this.minEndPTS=void 0,this.data=void 0,this.bitrateTest=!1,this.title=null,this.initSegment=null,this.endList=void 0,this.gap=void 0,this.urlId=0,this.type=e}get byteLength(){if(this.hasStats){let e=this.stats.total;if(e)return e}if(this.byteRange.length){let e=this.byteRange[0],t=this.byteRange[1];if(r(e)&&r(t))return t-e}return null}get bitrate(){return this.byteLength?8*this.byteLength/this.duration:this._bitrate?this._bitrate:null}set bitrate(e){this._bitrate=e}get decryptdata(){var e;let{levelkeys:t}=this;if(!t||t.NONE)return null;if(t.identity)this._decryptdata||(this._decryptdata=t.identity.getDecryptData(this.sn));else if(!(null!=(e=this._decryptdata)&&e.keyId)){let e=Object.keys(t);if(1===e.length){let r=this._decryptdata=t[e[0]]||null;r&&(this._decryptdata=r.getDecryptData(this.sn,t))}}return this._decryptdata}get end(){return this.start+this.duration}get endProgramDateTime(){if(null===this.programDateTime)return null;let e=r(this.duration)?this.duration:0;return this.programDateTime+1e3*e}get encrypted(){var e,t;if(null!=(e=this._decryptdata)&&e.encrypted)return!0;
2442if(this.levelkeys){let e=Object.keys(this.levelkeys),r=e.length;if(r>1||1===r&&null!=(t=this.levelkeys[e[0]])&&t.encrypted)return!0}return!1}get programDateTime(){return null===this._programDateTime&&this.rawProgramDateTime&&(this.programDateTime=Date.parse(this.rawProgramDateTime)),this._programDateTime}set programDateTime(e){if(!r(e)){this._programDateTime=this.rawProgramDateTime=null;return}this._programDateTime=e}get ref(){return J(this)?(this._ref||(this._ref={base:this.base,start:this.start,duration:this.duration,sn:this.sn,programDateTime:this.programDateTime}),this._ref):null}addStart(e){this.setStart(this.start+e)}setStart(e){this.start=e,this._ref&&(this._ref.start=e)}setDuration(e){this.duration=e,this._ref&&(this._ref.duration=e)}setKeyFormat(e){let t=this.levelkeys;if(t){var r;let i=t[e];i&&!(null!=(r=this._decryptdata)&&r.keyId)&&(this._decryptdata=i.getDecryptData(this.sn,t))}}abortRequests(){var e,t;null==(e=this.loader)||e.abort(),null==(t=this.keyLoader)||t.abort()}setElementaryStreamInfo(e,t,r,i,n,s=!1){let{elementaryStreams:a}=this,o=a[e];if(!o){a[e]={startPTS:t,endPTS:r,startDTS:i,endDTS:n,partial:s};return}o.startPTS=Math.min(o.startPTS,t),o.endPTS=Math.max(o.endPTS,r),o.startDTS=Math.min(o.startDTS,i),o.endDTS=Math.max(o.endDTS,n)}}class ee extends X{constructor(e,t,r,i,n){super(r),this.fragOffset=0,this.duration=0,this.gap=!1,this.independent=!1,this.relurl=void 0,this.fragment=void 0,this.index=void 0,this.duration=e.decimalFloatingPoint("DURATION"),this.gap=e.bool("GAP"),this.independent=e.bool("INDEPENDENT"),this.relurl=e.enumeratedString("URI"),this.fragment=t,this.index=i;const s=e.enumeratedString("BYTERANGE");s&&this.setByteRange(s,n),n&&(this.fragOffset=n.fragOffset+n.duration)}get start(){return this.fragment.start+this.fragOffset}get end(){return this.start+this.duration}get loaded(){let{elementaryStreams:e}=this;return!!(e.audio||e.video||e.audiovideo)}}let et=[].push,er={video:1,audio:2,id3:3,text:4};function ei(e){return String.fromCharCode.apply(null,e)}function en(e,t){let r=e[t]<<8|e[t+1];return r<0?65536+r:r}function es(e,t){let r=eo(e,t);return r<0?0x100000000+r:r}function ea(e,t){let r=es(e,t);return r*=0x100000000,r+=es(e,t+4)}function eo(e,t){return e[t]<<24|e[t+1]<<16|e[t+2]<<8|e[t+3]}function el(e,t){let r=[];if(!t.length)return r;let i=e.byteLength;for(let n=0;n<i;){let s=es(e,n),a=ei(e.subarray(n+4,n+8)),o=s>1?n+s:i;if(a===t[0])if(1===t.length)r.push(e.subarray(n+8,o));else{let i=el(e.subarray(n+8,o),t.slice(1));i.length&&et.apply(r,i)}n=o}return r}function eu(e){let t=[],r=el(e,["moov","trak"]);for(let e=0;e<r.length;e++){let i=r[e],n=el(i,["tkhd"])[0];if(n){let e=n[0],r=es(n,0===e?12:20),s=el(i,["mdia","mdhd"])[0];if(s){e=s[0];let n=es(s,0===e?12:20),a=el(i,["mdia","hdlr"])[0];if(a){let e=ei(a.subarray(8,12)),s={soun:W,vide:Y}[e],o=function(e){let t,r=e.subarray(8),i=r.subarray(86),n=ei(r.subarray(4,8)),s=n,a="enca"===n||"encv"===n;if(a){let e=el(r,[n])[0].subarray("enca"===n?28:78);el(e,["sinf"]).forEach(e=>{let t=el(e,["schm"])[0];if(t){let r=ei(t.subarray(4,8));if("cbcs"===r||"cenc"===r){let t=el(e,["frma"])[0];t&&(s=ei(t))}}})}let o=s;switch(s){case"avc1":case"avc2":case"avc3":case"avc4":{let e=el(i,["avcC"])[0];e&&e.length>3&&(s+="."+eh(e[1])+eh(e[2])+eh(e[3]),t=ec("avc1"===o?"dva1":"dvav",i));break}case"mp4a":{let e=el(r,[n])[0],t=el(e.subarray(28),["esds"])[0];if(t&&t.length>7){let e=4;if(3!==t[e++])break;e=ed(t,e)+2;let r=t[e++];if(128&r&&(e+=2),64&r&&(e+=t[e++]),4!==t[e++])break;e=ed(t,e);let i=t[e++];if(64===i)s+="."+eh(i);else break;if(e+=12,5!==t[e++])break;e=ed(t,e);let n=t[e++],a=(248&n)>>3;31===a&&(a+=1+((7&n)<<3)+((224&t[e])>>5)),s+="."+a}break}case"hvc1":case"hev1":{let e=el(i,["hvcC"])[0];if(e&&e.length>12){let t=e[1],r=["","A","B","C"][t>>6],i=es(e,2),n=e[12],a=e.subarray(6,12);s+="."+r+(31&t),s+="."+(function(e){let t=0;for(let r=0;r<32;r++)t|=(e>>r&1)<<31-r;return t>>>0})(i).toString(16).toUpperCase(),s+="."+((32&t)>>5?"H":"L")+n;let o="";for(let e=a.length;e--;){let t=a[e];(t||o)&&(o="."+t.toString(16).toUpperCase()+o)}s+=o}t=ec("hev1"==o?"dvhe":"dvh1",i);break}case"dvh1":case"dvhe":case"dvav":case"dva1":case"dav1":s=ec(s,i)||s;break;case"vp09":{let e=el(i,["vpcC"])[0];if(e&&e.length>6){let t=e[4],r=e[5],i=e[6]>>4&15;s+="."+ef(t)+"."+ef(r)+"."+ef(i)}break}case"av01":{let e=el(i,["av1C"])[0];if(e&&e.length>2){let r=e[1]>>>5,n=31&e[1],a=e[2]>>>7?"H":"M",o=(64&e[2])>>6,l=(32&e[2])>>5,u=(16&e[2])>>4,c=(8&e[2])>>3,d=(4&e[2])>>2,h=3&e[2];s+="."+r+"."+ef(n)+a+"."+ef(2===r&&o?l?12:10:o?10:8)+"."+u+"."+c+d+h+"."+ef(1)+"."+ef(1)+"."+ef(1)+".0",t=ec("dav1",i)}}}return{codec:s,encrypted:a,supplemental:t}}(el(i,["mdia","minf","stbl","stsd"])[0]);s?(t[r]={timescale:n,type:s,stsd:o},t[s]=O({timescale:n,id:r},o)):t[r]={timescale:n,type:e,stsd:o}}}}}
2442return el(e,["moov","mvex","trex"]).forEach(e=>{let r=t[es(e,4)];r&&(r.default={duration:es(e,12),flags:es(e,20)})}),t}function ec(e,t){let r=el(t,["dvvC"]),i=r.length?r[0]:el(t,["dvcC"])[0];if(i){let t=i[2]>>1&127,r=i[2]<<5&32|i[3]>>3&31;return e+"."+ef(t)+"."+ef(r)}}function ed(e,t){let r=t+5;for(;128&e[t++]&&t<r;);return t}function eh(e){return("0"+e.toString(16).toUpperCase()).slice(-2)}function ef(e){return(e<10?"0":"")+e}function ep(e,t){el(e,["moov","trak"]).forEach(e=>{let r=el(e,["mdia","minf","stbl","stsd"])[0];if(!r)return;let i=r.subarray(8),n=el(i,["enca"]),s=n.length>0;s||(n=el(i,["encv"])),n.forEach(e=>{el(s?e.subarray(28):e.subarray(78),["sinf"]).forEach(e=>{let r=eg(e);r&&t(r,s)})})})}function eg(e){let t=el(e,["schm"])[0];if(t){let r=ei(t.subarray(4,8));if("cbcs"===r||"cenc"===r){let t=el(e,["schi","tenc"])[0];if(t)return t}}}function em(e,t){let r=new Uint8Array(e.length+t.length);return r.set(e),r.set(t,e.length),r}function ey(e,t){let r=[],i=t.samples,n=t.timescale,s=t.id,a=!1;return el(i,["moof"]).map(o=>{let l=o.byteOffset-8;el(o,["traf"]).map(o=>{let u=el(o,["tfdt"]).map(e=>{let t=e[0],r=es(e,4);return 1===t&&(r*=0x100000000,r+=es(e,8)),r/n})[0];return void 0!==u&&(e=u),el(o,["tfhd"]).map(u=>{let c=es(u,4),d=0xffffff&es(u,0),h=0,f=0,p=8;c===s&&((1&d)!=0&&(p+=8),(2&d)!=0&&(p+=4),(8&d)!=0&&(h=es(u,p),p+=4),(16&d)!=0&&(f=es(u,p),p+=4),(32&d)!=0&&(p+=4),"video"===t.type&&(a=ev(t.codec)),el(o,["trun"]).map(s=>{let o=s[0],u=0xffffff&es(s,0),c=0,d=(256&u)!=0,p=0,g=(512&u)!=0,m=0,y=(1024&u)!=0,v=(2048&u)!=0,b=0,_=es(s,4),E=8;(1&u)!=0&&(c=es(s,E),E+=4),(4&u)!=0&&(E+=4);let S=c+l;for(let l=0;l<_;l++){if(d?(p=es(s,E),E+=4):p=h,g?(m=es(s,E),E+=4):m=f,y&&(E+=4),v&&(b=0===o?es(s,E):eo(s,E),E+=4),t.type===Y){let t=0;for(;t<m;){let s=es(i,S);S+=4,function(e,t){if(!e)return 6==(31&t);{let e=t>>1&63;return 39===e||40===e}}(a,i[S])&&eb(i.subarray(S,S+s),a?2:1,e+b/n,r),S+=s,t+=s+4}}e+=p/n}}))})})}),r}function ev(e){if(!e)return!1;let t=e.substring(0,4);return"hvc1"===t||"hev1"===t||"dvh1"===t||"dvhe"===t}function eb(e,t,r,i){let n,s=e_(e);n=0+t;let a=0,o=0,l=0;for(;n<s.length;){a=0;do{if(n>=s.length)break;a+=l=s[n++]}while(255===l)o=0;do{if(n>=s.length)break;o+=l=s[n++]}while(255===l)let e=s.length-n,t=n;if(o<e)n+=o;else if(o>e){$.error(`Malformed SEI payload. ${o} is too small, only ${e} bytes left to parse.`);break}if(4===a){if(181===s[t++]){let e=en(s,t);if(t+=2,49===e){let e=es(s,t);if(t+=4,0x47413934===e){let e=s[t++];if(3===e){let n=s[t++],o=31&n,l=64&n,u=l?2+3*o:0,c=new Uint8Array(u);if(l){c[0]=n;for(let e=1;e<u;e++)c[e]=s[t++]}i.push({type:e,payloadType:a,pts:r,bytes:c})}}}}}else if(5===a&&o>16){let e=[];for(let r=0;r<16;r++){let i=s[t++].toString(16);e.push(1==i.length?"0"+i:i),(3===r||5===r||7===r||9===r)&&e.push("-")}let n=o-16,l=new Uint8Array(n);for(let e=0;e<n;e++)l[e]=s[t++];i.push({payloadType:a,pts:r,uuid:e.join(""),userData:V(l),userDataBytes:l})}}}function e_(e){let t=e.byteLength,r=[],i=1;for(;i<t-2;)0===e[i]&&0===e[i+1]&&3===e[i+2]?(r.push(i+2),i+=2):i++;if(0===r.length)return e;let n=t-r.length,s=new Uint8Array(n),a=0;for(i=0;i<n;a++,i++)a===r[0]&&(a++,r.shift()),s[i]=e[a];return s}let eE={audio:{a3ds:1,"ac-3":.95,"ac-4":1,alac:.9,alaw:1,dra1:1,"dts+":1,"dts-":1,dtsc:1,dtse:1,dtsh:1,"ec-3":.9,enca:1,fLaC:.9,flac:.9,FLAC:.9,g719:1,g726:1,m4ae:1,mha1:1,mha2:1,mhm1:1,mhm2:1,mlpa:1,mp4a:1,"raw ":1,Opus:1,opus:1,samr:1,sawb:1,sawp:1,sevc:1,sqcp:1,ssmv:1,twos:1,ulaw:1},video:{avc1:1,avc2:1,avc3:1,avc4:1,avcp:1,av01:.8,dav1:.8,drac:1,dva1:1,dvav:1,dvh1:.7,dvhe:.7,encv:1,hev1:.75,hvc1:.75,mjp2:1,mp4v:1,mvc1:1,mvc2:1,mvc3:1,mvc4:1,resv:1,rv60:1,s263:1,svc1:1,svc2:1,"vc-1":1,vp08:1,vp09:.9},text:{stpp:1,wvtt:1}};function eS(e,t){let r=eE[t];return!!r&&!!r[e.slice(0,4)]}function ex(e,t,r=!0){return!e.split(",").some(e=>!eT(e,t,r))}function eT(e,t,r=!0){var i;let n=U(r);return null!=(i=null==n?void 0:n.isTypeSupported(ew(e,t)))&&i}function ew(e,t){return`${t}/mp4;codecs=${e}`}function eA(e){if(e){let t=e.substring(0,4);return eE.video[t]}return 2}function eR(e){let t=/\(Windows.+Firefox\//i.test(navigator.userAgent);return e.split(",").reduce((e,r)=>{let i=t&&ev(r)?9:eE.video[r];return i?(2*i+e)/(e?3:2):(eE.audio[r]+e)/(e?2:1)},0)}let eI={},ek=/flac|opus|mp4a\.40\.34/i;function eC(e,t=!0){return e.replace(ek,e=>(function(e,t=!0){if(eI[e])return eI[e];let r={flac:["flac","fLaC","FLAC"],opus:["opus","Opus"],"mp4a.40.34":["mp3"]}[e];for(let n=0;n<r.length;n++){var i;if(eT(r[n],"audio",t))return eI[e]=r[n],r[n];
2442if("mp3"===r[n]&&null!=(i=U(t))&&i.isTypeSupported("audio/mpeg"))return""}return e})(e.toLowerCase(),t))}function eD(e,t){if(e&&(e.length>4||-1!==["ac-3","ec-3","alac","fLaC","Opus"].indexOf(e))&&(eL(e,"audio")||eL(e,"video")))return e;if(t){let r=t.split(",");if(r.length>1){if(e){for(let t=r.length;t--;)if(r[t].substring(0,4)===e.substring(0,4))return r[t]}return r[0]}}return t||e}function eL(e,t){return eS(e,t)&&eT(e,t)}function eO(e){let t=U(e)||{isTypeSupported:()=>!1};return{mpeg:t.isTypeSupported("audio/mpeg"),mp3:t.isTypeSupported('audio/mp4; codecs="mp3"'),ac3:t.isTypeSupported('audio/mp4; codecs="ac-3"')}}function eP(e){return e.replace(/^.+codecs=["']?([^"']+).*$/,"$1")}let eF={supported:!1,smooth:!1,powerEfficient:!1},eN={supported:!0,configurations:[],decodingInfoResults:[{supported:!0,powerEfficient:!0,smooth:!0}]};function eM(e,t){return{supported:!1,configurations:t,decodingInfoResults:[eF],error:e}}function ej(e,t,r,i={}){var n,s,a,o,l,u;let c,d,h,f,p,g,m,y,v=e.videoCodec;if(!v&&!e.audioCodec||!r)return Promise.resolve(eN);let b=[],_=(c=null==(s=(n=e).videoCodec)?void 0:s.split(","),d=e$(n),h=n.width||640,f=n.height||480,p=n.frameRate||30,g=n.videoRange.toLowerCase(),c?c.map(e=>{let t={contentType:ew(function(e){if(e.startsWith("av01.")){let t=e.split("."),r=["0","111","01","01","01","0"];for(let e=t.length;e>4&&e<10;e++)t[e]=r[e-4];return t.join(".")}return e}(e),"video"),width:h,height:f,bitrate:d,framerate:p};return"sdr"!==g&&(t.transferFunction=g),t}):[]),E=_.length,S=(a=e,o=t,l=E>0,m=null==(u=a.audioCodec)?void 0:u.split(","),y=e$(a),m&&a.audioGroups?a.audioGroups.reduce((e,t)=>{var r;let i=t?null==(r=o.groups[t])?void 0:r.tracks:null;return i?i.reduce((e,r)=>{if(r.groupId===t){let t=parseFloat(r.channels||"");m.forEach(r=>{let i={contentType:ew(r,"audio"),bitrate:l?function(e,t){if(t<=1)return 1;let r=128e3;return"ec-3"===e?r=768e3:"ac-3"===e&&(r=64e4),Math.min(t/2,r)}(r,y):y};t&&(i.channels=""+t),e.push(i)})}return e},e):e},[]):[]),x=S.length;for(let e=E||+x||1;e--;){let t={type:"media-source"};if(E&&(t.video=_[e%E]),x){t.audio=S[e%x];let r=t.audio.bitrate;t.video&&r&&(t.video.bitrate-=r)}b.push(t)}if(v){let e=navigator.userAgent;if(v.split(",").some(e=>ev(e))&&/\(Windows.+Firefox\//i.test(navigator.userAgent))return Promise.resolve(eM(Error(`Overriding Windows Firefox HEVC MediaCapabilities result based on user-agent string: (${e})`),b))}return Promise.all(b.map(e=>{let t=function(e){let t="",{audio:r,video:i}=e;if(i){let e=eP(i.contentType);t+=`${e}_r${i.height}x${i.width}f${Math.ceil(i.framerate)}${i.transferFunction||"sd"}_${Math.ceil(i.bitrate/1e5)}`}if(r){let e=eP(r.contentType);t+=`${i?"_":""}${e}_c${r.channels}`}return t}(e);return i[t]||(i[t]=r.decodingInfo(e))})).then(e=>({supported:!e.some(e=>!e.supported),configurations:b,decodingInfoResults:e})).catch(e=>({supported:!1,configurations:b,decodingInfoResults:[],error:e}))}function e$(e){return 1e3*Math.ceil(Math.max(.9*e.bitrate,e.averageBitrate)/1e3)||1}let eU=["NONE","TYPE-0","TYPE-1",null],eB=["SDR","PQ","HLG"];function eV(e){let{canSkipUntil:t,canSkipDateRanges:r,age:i}=e;return t&&i<t/2?r?"v2":"YES":""}class eG{constructor(e,t,r){this.msn=void 0,this.part=void 0,this.skip=void 0,this.msn=e,this.part=t,this.skip=r}addDirectives(e){let t=new self.URL(e);return void 0!==this.msn&&t.searchParams.set("_HLS_msn",this.msn.toString()),void 0!==this.part&&t.searchParams.set("_HLS_part",this.part.toString()),this.skip&&t.searchParams.set("_HLS_skip",this.skip),t.href}}class eq{constructor(e){if(this._attrs=void 0,this.audioCodec=void 0,this.bitrate=void 0,this.codecSet=void 0,this.url=void 0,this.frameRate=void 0,this.height=void 0,this.id=void 0,this.name=void 0,this.supplemental=void 0,this.videoCodec=void 0,this.width=void 0,this.details=void 0,this.fragmentError=0,this.loadError=0,this.loaded=void 0,this.realBitrate=0,this.supportedPromise=void 0,this.supportedResult=void 0,this._avgBitrate=0,this._audioGroups=void 0,this._subtitleGroups=void 0,this._urlId=0,this.url=[e.url],this._attrs=[e.attrs],this.bitrate=e.bitrate,e.details&&(this.details=e.details),this.id=e.id||0,this.name=e.name,this.width=e.width||0,this.height=e.height||0,this.frameRate=e.attrs.optionalFloat("FRAME-RATE",0),this._avgBitrate=e.attrs.decimalInteger("AVERAGE-BANDWIDTH"),this.audioCodec=e.audioCodec,this.videoCodec=e.videoCodec,this.codecSet=[e.videoCodec,e.audioCodec].filter(e=>!!e).map(e=>e.substring(0,4)).join(","),"supplemental"in e){var t;this.supplemental=e.supplemental;const r=null==(t=e.supplemental)?void 0:t.videoCodec;r&&r!==e.videoCodec&&(this.codecSet+=`,${r.substring(0,4)}`)}this.addGroupId("audio",e.attrs.AUDIO),this.addGroupId("text",e.attrs.SUBTITLES)}get maxBitrate(){return Math.max(this.realBitrate,this.bitrate)}get averageBitrate(){return this._avgBitrate||this.realBitrate||this.bitrate}get attrs(){return this._attrs[0]}get codecs(){return this.attrs.CODECS||""}get pathwayId(){return this.attrs["PATHWAY-ID"]||"."}get videoRange(){return this.attrs["VIDEO-RANGE"]||"SDR"}get score(){return this.attrs.optionalFloat("SCORE",0)}get uri(){return this.url[0]||""}hasAudioGroup(e){return eH(this._audioGroups,e)}hasSubtitleGroup(e){return eH(this._subtitleGroups,e)}get audioGroups(){return this._audioGroups}get subtitleGroups(){return this._subtitleGroups}addGroupId(e,t){if(t){if("audio"===e){let e=this._audioGroups;e||(e=this._audioGroups=[]),-1===e.indexOf(t)&&e.push(t)}else if("text"===e){let e=this._subtitleGroups;e||(e=this._subtitleGroups=[]),-1===e.indexOf(t)&&e.push(t)}}}get urlId(){return 0}set urlId(e){}get audioGroupIds(){return this.audioGroups?[this.audioGroupId]:void 0}get textGroupIds(){return this.subtitleGroups?[this.textGroupId]:void 0}get audioGroupId(){var e;return null==(e=this.audioGroups)?void 0:e[0]}get textGroupId(){var e;return null==(e=this.subtitleGroups)?void 0:e[0]}addFallback(){}}function eH(e,t){return!!t&&!!e&&-1!==e.indexOf(t)}let ez=(e,t)=>{let r;return JSON.stringify(e,(r=new WeakSet,(e,i)=>{if(t&&(i=t(e,i)),"object"==typeof i&&null!==i){if(r.has(i))return;r.add(i)}return i}))};function eK(e,t){$.log(`[abr] start candidates with "${e}" ignored because ${t}`)}function eW(e){return e.reduce((e,t)=>
2442{let r=e.groups[t.groupId];r||(r=e.groups[t.groupId]={tracks:[],channels:{2:0},hasDefault:!1,hasAutoSelect:!1}),r.tracks.push(t);let i=t.channels||"2";return r.channels[i]=(r.channels[i]||0)+1,r.hasDefault=r.hasDefault||t.default,r.hasAutoSelect=r.hasAutoSelect||t.autoselect,r.hasDefault&&(e.hasDefaultAudio=!0),r.hasAutoSelect&&(e.hasAutoSelectAudio=!0),e},{hasDefaultAudio:!1,hasAutoSelectAudio:!1,groups:{}})}function eY(e){if(!e)return e;let{lang:t,assocLang:r,characteristics:i,channels:n,audioCodec:s}=e;return{lang:t,assocLang:r,characteristics:i,channels:n,audioCodec:s}}function eQ(e,t,r){if("attrs"in e){let r=t.indexOf(e);if(-1!==r)return r}for(let i=0;i<t.length;i++)if(eX(e,t[i],r))return i;return -1}function eX(e,t,r){let{groupId:i,name:n,lang:s,assocLang:a,default:o}=e,l=e.forced;return(void 0===i||t.groupId===i)&&(void 0===n||t.name===n)&&(void 0===s||function(e,t="--"){return e.length===t.length?e===t:e.startsWith(t)||t.startsWith(e)}(s,t.lang))&&(void 0===s||t.assocLang===a)&&(void 0===o||t.default===o)&&(void 0===l||t.forced===l)&&(!("characteristics"in e)||function(e,t=""){let r=e.split(","),i=t.split(",");return r.length===i.length&&!r.some(e=>-1===i.indexOf(e))}(e.characteristics||"",t.characteristics))&&(void 0===r||r(e,t))}function eJ(e,t){let{audioCodec:r,channels:i}=e;return(void 0===r||(t.audioCodec||"").substring(0,4)===r.substring(0,4))&&(void 0===i||i===(t.channels||"2"))}function eZ(e,t,r){for(let i=t;i>-1;i--)if(r(e[i]))return i;for(let i=t+1;i<e.length;i++)if(r(e[i]))return i;return -1}function e0(e,t){var r;return!!e&&e!==(null==(r=t.loadLevelObj)?void 0:r.uri)}let e1=function(e,t){let r=0,i=e.length-1,n=null,s=null;for(;r<=i;){let a=t(s=e[n=(r+i)/2|0]);if(a>0)r=n+1;else{if(!(a<0))return s;i=n-1}}return null};function e2(e,t,r=0,i=0,n=.005){let s=null;if(e){s=t[1+e.sn-t[0].sn]||null;let i=e.endDTS-r;i>0&&i<15e-7&&(r+=15e-7),s&&e.level!==s.level&&s.end<=e.end&&(s=t[2+e.sn-t[0].sn]||null)}else 0===r&&0===t[0].start&&(s=t[0]);if(s&&((!e||e.level===s.level)&&0===e3(r,i,s)||function(e,t,r){if(t&&0===t.start&&t.level<e.level&&(t.endPTS||0)>0){let i=t.tagList.reduce((e,t)=>("INF"===t[0]&&(e+=parseFloat(t[1])),e),r);return e.start<=i}return!1}(s,e,Math.min(n,i))))return s;let a=e1(t,e3.bind(null,r,i));return a&&(a!==e||!s)?a:s}function e3(e=0,t=0,r){if(r.start<=e&&r.start+r.duration>e)return 0;let i=Math.min(t,r.duration+(r.deltaPTS?r.deltaPTS:0));return r.start+r.duration-i<=e?1:r.start-i>e&&r.start?-1:0}function e4(e,t,r){if(e&&e.startCC<=t&&e.endCC>=t){let i,n=e.fragments,{fragmentHint:s}=e;return s&&(n=n.concat(s)),e1(n,e=>e.cc<t?1:e.cc>t?-1:(i=e,e.end<=r)?1:e.start>r?-1:0),i||null}return null}function e5(e){switch(e.details){case a.FRAG_LOAD_TIMEOUT:case a.KEY_LOAD_TIMEOUT:case a.LEVEL_LOAD_TIMEOUT:case a.MANIFEST_LOAD_TIMEOUT:return!0}return!1}function e8(e){return e.details.startsWith("key")}function e6(e){return e8(e)&&!!e.frag&&!e.frag.decryptdata}function e7(e,t){let r=e5(t);return e.default[`${r?"timeout":"error"}Retry`]}function e9(e,t){return Math.min(("linear"===e.backoff?1:Math.pow(2,t))*e.retryDelayMs,e.maxRetryDelayMs)}function te(e){return O(O({},e),{errorRetry:null,timeoutRetry:null})}function tt(e,t,r,i){var n;if(!e)return!1;let s=null==i?void 0:i.code,a=t<e.maxNumRetry&&(tr(n=s)||!!n&&(n<400||n>499)||!!r);return e.shouldRetry?e.shouldRetry(e,t,r,i,a):a}function tr(e){return 0===e&&!1===navigator.onLine}function ti(e){let t={action:0,flags:0};return e&&(t.resolved=!0),t}var tn="NOT_LOADED",ts="APPENDING",ta="PARTIAL";class to{constructor(e){this.activePartLists=Object.create(null),this.endListFragments=Object.create(null),this.fragments=Object.create(null),this.timeRanges=Object.create(null),this.bufferPadding=.2,this.hls=void 0,this.hasGaps=!1,this.hls=e,this._registerListeners()}_registerListeners(){let{hls:e}=this;e&&(e.on(o.MANIFEST_LOADING,this.onManifestLoading,this),e.on(o.BUFFER_APPENDED,this.onBufferAppended,this),e.on(o.FRAG_BUFFERED,this.onFragBuffered,this),e.on(o.FRAG_LOADED,this.onFragLoaded,this))}_unregisterListeners(){let{hls:e}=this;e&&(e.off(o.MANIFEST_LOADING,this.onManifestLoading,this),e.off(o.BUFFER_APPENDED,this.onBufferAppended,this),e.off(o.FRAG_BUFFERED,this.onFragBuffered,this),e.off(o.FRAG_LOADED,this.onFragLoaded,this))}destroy(){this._unregisterListeners(),this.hls=this.fragments=this.activePartLists=this.endListFragments=this.timeRanges=null}getAppendedFrag(e,t){let r=this.activePartLists[t];if(r)for(let t=r.length;t--;){let i=r[t];if(!i)break;if(i.start<=e&&e<=i.end&&i.loaded)return i}return this.getBufferedFrag(e,t)}getBufferedFrag(e,t){return this.getFragAtPos(e,t,!0)}getFragAtPos(e,t,r){let{fragments:i}=this,n=Object.keys(i);for(let s=n.length;s--;){let a=i[n[s]];if((null==a?void 0:a.body.type)===t&&(!r||a.buffered)){let t=a.body;if(t.start<=e&&e<=t.end)return t}}return null}detectEvictedFragments(e,t,r,i,n){this.timeRanges&&(this.timeRanges[e]=t);let s=(null==i?void 0:i.fragment.sn)||-1;
2442Object.keys(this.fragments).forEach(i=>{let a=this.fragments[i];if(!a||s>=a.body.sn)return;if(!a.buffered&&(!a.loaded||n)){a.body.type===r&&this.removeFragment(a.body);return}let o=a.range[e];if(o){if(0===o.time.length)return void this.removeFragment(a.body);o.time.some(e=>{let r=!this.isTimeBuffered(e.startPTS,e.endPTS,t);return r&&this.removeFragment(a.body),r})}})}detectPartialFragments(e){let t=this.timeRanges;if(!t||"initSegment"===e.frag.sn)return;let r=e.frag,i=tu(r),n=this.fragments[i];if(!n||n.buffered&&r.gap)return;let s=!r.relurl;Object.keys(t).forEach(i=>{let a=r.elementaryStreams[i];if(!a)return;let o=t[i],l=s||!0===a.partial;n.range[i]=this.getBufferedTimes(r,e.part,l,o)}),n.loaded=null,Object.keys(n.range).length?(this.bufferedEnd(n,r),tl(n)||this.removeParts(r.sn-1,r.type)):this.removeFragment(n.body)}bufferedEnd(e,t){e.buffered=!0,(e.body.endList=t.endList||e.body.endList)&&(this.endListFragments[e.body.type]=e)}removeParts(e,t){let r=this.activePartLists[t];r&&(this.activePartLists[t]=tc(r,t=>t.fragment.sn>=e))}fragBuffered(e,t){let r=tu(e),i=this.fragments[r];!i&&t&&(i=this.fragments[r]={body:e,appendedPTS:null,loaded:null,buffered:!1,range:Object.create(null)},e.gap&&(this.hasGaps=!0)),i&&(i.loaded=null,this.bufferedEnd(i,e))}getBufferedTimes(e,t,r,i){let n={time:[],partial:r},s=e.start,a=e.end,o=e.minEndPTS||a,l=e.maxStartPTS||s;for(let e=0;e<i.length;e++){let t=i.start(e)-this.bufferPadding,r=i.end(e)+this.bufferPadding;if(l>=t&&o<=r){n.time.push({startPTS:Math.max(s,i.start(e)),endPTS:Math.min(a,i.end(e))});break}if(s<r&&a>t){let t=Math.max(s,i.start(e)),r=Math.min(a,i.end(e));r>t&&(n.partial=!0,n.time.push({startPTS:t,endPTS:r}))}else if(a<=t)break}return n}getPartialFragment(e){let t,r,i,n=null,s=0,{bufferPadding:a,fragments:o}=this;return Object.keys(o).forEach(l=>{let u=o[l];u&&tl(u)&&(r=u.body.start-a,i=u.body.end+a,e>=r&&e<=i&&s<=(t=Math.min(e-r,i-e))&&(n=u.body,s=t))}),n}isEndListAppended(e){let t=this.endListFragments[e];return void 0!==t&&(t.buffered||tl(t))}getState(e){let t=tu(e),r=this.fragments[t];if(r)if(!r.buffered)return ts;else if(tl(r))return ta;else return"OK";return tn}isTimeBuffered(e,t,r){let i,n;for(let s=0;s<r.length;s++){if(i=r.start(s)-this.bufferPadding,n=r.end(s)+this.bufferPadding,e>=i&&t<=n)return!0;if(t<=i)break}return!1}onManifestLoading(){this.removeAllFragments()}onFragLoaded(e,t){if("initSegment"===t.frag.sn||t.frag.bitrateTest)return;let r=t.frag,i=t.part?null:t,n=tu(r);this.fragments[n]={body:r,appendedPTS:null,loaded:i,buffered:!1,range:Object.create(null)}}onBufferAppended(e,t){let{frag:r,part:i,timeRanges:n,type:s}=t;if("initSegment"===r.sn)return;let a=r.type;if(i){let e=this.activePartLists[a];e||(this.activePartLists[a]=e=[]),e.push(i)}this.timeRanges=n;let o=n[s];this.detectEvictedFragments(s,o,a,i)}onFragBuffered(e,t){this.detectPartialFragments(t)}hasFragment(e){let t=tu(e);return!!this.fragments[t]}hasFragments(e){let{fragments:t}=this,r=Object.keys(t);if(!e)return r.length>0;for(let i=r.length;i--;){let n=t[r[i]];if((null==n?void 0:n.body.type)===e)return!0}return!1}hasParts(e){var t;return!!(null!=(t=this.activePartLists[e])&&t.length)}removeFragmentsInRange(e,t,r,i,n){(!i||this.hasGaps)&&Object.keys(this.fragments).forEach(s=>{let a=this.fragments[s];if(!a)return;let o=a.body;o.type===r&&(!i||o.gap)&&o.start<t&&o.end>e&&(a.buffered||n)&&this.removeFragment(o)})}removeFragment(e){let t=tu(e);e.clearElementaryStreamInfo();let r=this.activePartLists[e.type];if(r){let t=e.sn;this.activePartLists[e.type]=tc(r,e=>e.fragment.sn!==t)}delete this.fragments[t],e.endList&&delete this.endListFragments[e.type]}removeAllFragments(){var e;this.fragments=Object.create(null),this.endListFragments=Object.create(null),this.activePartLists=Object.create(null),this.hasGaps=!1;let t=null==(e=this.hls)||null==(e=e.latestLevelDetails)?void 0:e.partList;t&&t.forEach(e=>e.clearElementaryStreamInfo())}}function tl(e){var t,r,i;return e.buffered&&!!(e.body.gap||null!=(t=e.range.video)&&t.partial||null!=(r=e.range.audio)&&r.partial||null!=(i=e.range.audiovideo)&&i.partial)}function tu(e){return`${e.type}_${e.level}_${e.sn}`}function tc(e,t){return e.filter(e=>{let r=t(e);return r||e.clearElementaryStreamInfo(),r})}class td{constructor(e,t,r){this.subtle=void 0,this.aesIV=void 0,this.aesMode=void 0,this.subtle=e,this.aesIV=t,this.aesMode=r}decrypt(e,t){switch(this.aesMode){case 0:return this.subtle.decrypt({
2442name:"AES-CBC",iv:this.aesIV},t,e);case 1:return this.subtle.decrypt({name:"AES-CTR",counter:this.aesIV,length:64},t,e);default:throw Error(`[AESCrypto] invalid aes mode ${this.aesMode}`)}}}class th{constructor(){this.rcon=[0,1,2,4,8,16,32,64,128,27,54],this.subMix=[new Uint32Array(256),new Uint32Array(256),new Uint32Array(256),new Uint32Array(256)],this.invSubMix=[new Uint32Array(256),new Uint32Array(256),new Uint32Array(256),new Uint32Array(256)],this.sBox=new Uint32Array(256),this.invSBox=new Uint32Array(256),this.key=new Uint32Array(0),this.ksRows=0,this.keySize=0,this.keySchedule=void 0,this.invKeySchedule=void 0,this.initTable()}uint8ArrayToUint32Array_(e){let t=new DataView(e),r=new Uint32Array(4);for(let e=0;e<4;e++)r[e]=t.getUint32(4*e);return r}initTable(){let e=this.sBox,t=this.invSBox,r=this.subMix,i=r[0],n=r[1],s=r[2],a=r[3],o=this.invSubMix,l=o[0],u=o[1],c=o[2],d=o[3],h=new Uint32Array(256),f=0,p=0,g=0;for(g=0;g<256;g++)g<128?h[g]=g<<1:h[g]=g<<1^283;for(g=0;g<256;g++){let r=p^p<<1^p<<2^p<<3^p<<4;r=r>>>8^255&r^99,e[f]=r,t[r]=f;let o=h[f],g=h[o],m=h[g],y=257*h[r]^0x1010100*r;i[f]=y<<24|y>>>8,n[f]=y<<16|y>>>16,s[f]=y<<8|y>>>24,a[f]=y,y=0x1010101*m^65537*g^257*o^0x1010100*f,l[r]=y<<24|y>>>8,u[r]=y<<16|y>>>16,c[r]=y<<8|y>>>24,d[r]=y,f?(f=o^h[h[h[m^o]]],p^=h[h[p]]):f=p=1}}expandKey(e){let t,r,i,n,s=this.uint8ArrayToUint32Array_(e),a=!0,o=0;for(;o<s.length&&a;)a=s[o]===this.key[o],o++;if(a)return;this.key=s;let l=this.keySize=s.length;if(4!==l&&6!==l&&8!==l)throw Error("Invalid aes key size="+l);let u=this.ksRows=(l+6+1)*4,c=this.keySchedule=new Uint32Array(u),d=this.invKeySchedule=new Uint32Array(u),h=this.sBox,f=this.rcon,p=this.invSubMix,g=p[0],m=p[1],y=p[2],v=p[3];for(t=0;t<u;t++){if(t<l){i=c[t]=s[t];continue}n=i,t%l==0?n=(h[(n=n<<8|n>>>24)>>>24]<<24|h[n>>>16&255]<<16|h[n>>>8&255]<<8|h[255&n])^f[t/l|0]<<24:l>6&&t%l==4&&(n=h[n>>>24]<<24|h[n>>>16&255]<<16|h[n>>>8&255]<<8|h[255&n]),c[t]=i=(c[t-l]^n)>>>0}for(r=0;r<u;r++)t=u-r,n=3&r?c[t]:c[t-4],r<4||t<=4?d[r]=n:d[r]=g[h[n>>>24]]^m[h[n>>>16&255]]^y[h[n>>>8&255]]^v[h[255&n]],d[r]=d[r]>>>0}networkToHostOrderSwap(e){return e<<24|(65280&e)<<8|(0xff0000&e)>>8|e>>>24}decrypt(e,t,r){let i,n,s,a,o,l,u,c,d,h,f,p,g,m,y=this.keySize+6,v=this.invKeySchedule,b=this.invSBox,_=this.invSubMix,E=_[0],S=_[1],x=_[2],T=_[3],w=this.uint8ArrayToUint32Array_(r),A=w[0],R=w[1],I=w[2],k=w[3],C=new Int32Array(e),D=new Int32Array(C.length),L=this.networkToHostOrderSwap;for(;t<C.length;){for(m=1,d=L(C[t]),h=L(C[t+1]),f=L(C[t+2]),p=L(C[t+3]),o=d^v[0],l=p^v[1],u=f^v[2],c=h^v[3],g=4;m<y;m++)i=E[o>>>24]^S[l>>16&255]^x[u>>8&255]^T[255&c]^v[g],n=E[l>>>24]^S[u>>16&255]^x[c>>8&255]^T[255&o]^v[g+1],s=E[u>>>24]^S[c>>16&255]^x[o>>8&255]^T[255&l]^v[g+2],a=E[c>>>24]^S[o>>16&255]^x[l>>8&255]^T[255&u]^v[g+3],o=i,l=n,u=s,c=a,g+=4;i=b[o>>>24]<<24^b[l>>16&255]<<16^b[u>>8&255]<<8^b[255&c]^v[g],n=b[l>>>24]<<24^b[u>>16&255]<<16^b[c>>8&255]<<8^b[255&o]^v[g+1],s=b[u>>>24]<<24^b[c>>16&255]<<16^b[o>>8&255]<<8^b[255&l]^v[g+2],a=b[c>>>24]<<24^b[o>>16&255]<<16^b[l>>8&255]<<8^b[255&u]^v[g+3],D[t]=L(i^A),D[t+1]=L(a^R),D[t+2]=L(s^I),D[t+3]=L(n^k),A=d,R=h,I=f,k=p,t+=4}return D.buffer}}class tf{constructor(e,t,r){this.subtle=void 0,this.key=void 0,this.aesMode=void 0,this.subtle=e,this.key=t,this.aesMode=r}expandKey(){let e=function(e){switch(e){case 0:return"AES-CBC";case 1:return"AES-CTR";default:throw Error(`[FastAESKey] invalid aes mode ${e}`)}}(this.aesMode);return this.subtle.importKey("raw",this.key,{name:e},!1,["encrypt","decrypt"])}}class tp{constructor(e,{removePKCS7Padding:t=!0}={}){if(this.logEnabled=!0,this.removePKCS7Padding=void 0,this.subtle=null,this.softwareDecrypter=null,this.key=null,this.fastAesKey=null,this.remainderData=null,this.currentIV=null,this.currentResult=null,this.useSoftware=void 0,this.enableSoftwareAES=void 0,this.enableSoftwareAES=e.enableSoftwareAES,this.removePKCS7Padding=t,t)try{const e=self.crypto;e&&(this.subtle=e.subtle||e.webkitSubtle)}catch(e){}this.useSoftware=!this.subtle}destroy(){this.subtle=null,this.softwareDecrypter=null,this.key=null,this.fastAesKey=null,this.remainderData=null,this.currentIV=null,this.currentResult=null}isSync(){return this.useSoftware}flush(){let{currentResult:e,remainderData:t}=this;if(!e||t)return this.reset(),null;let r=new Uint8Array(e);if(this.reset(),this.removePKCS7Padding){let e,t;return(t=(e=r.byteLength)&&new DataView(r.buffer).getUint8(e-1))?r.slice(0,e-t):r}return r}reset(){this.currentResult=null,this.currentIV=null,this.remainderData=null,this.softwareDecrypter&&(this.softwareDecrypter=null)}
2442decrypt(e,t,r,i){return this.useSoftware?new Promise((n,s)=>{let a=ArrayBuffer.isView(e)?e:new Uint8Array(e);this.softwareDecrypt(a,t,r,i);let o=this.flush();o?n(o.buffer):s(Error("[softwareDecrypt] Failed to decrypt data"))}):this.webCryptoDecrypt(new Uint8Array(e),t,r,i)}softwareDecrypt(e,t,r,i){let{currentIV:n,currentResult:s,remainderData:a}=this;if(0!==i||16!==t.byteLength)return $.warn("SoftwareDecrypt: can only handle AES-128-CBC"),null;this.logOnce("JS AES decrypt"),a&&(e=em(a,e),this.remainderData=null);let o=this.getValidChunk(e);if(!o.length)return null;n&&(r=n);let l=this.softwareDecrypter;return(l||(l=this.softwareDecrypter=new th),l.expandKey(t),this.currentResult=l.decrypt(o.buffer,0,r),this.currentIV=o.slice(-16).buffer,s)?s:null}webCryptoDecrypt(e,t,r,i){if(this.key!==t||!this.fastAesKey){if(!this.subtle)return Promise.resolve(this.onWebCryptoError(e,t,r,i));this.key=t,this.fastAesKey=new tf(this.subtle,t,i)}return this.fastAesKey.expandKey().then(t=>this.subtle?(this.logOnce("WebCrypto AES decrypt"),new td(this.subtle,new Uint8Array(r),i).decrypt(e.buffer,t)):Promise.reject(Error("web crypto not initialized"))).catch(n=>($.warn(`[decrypter]: WebCrypto Error, disable WebCrypto API, ${n.name}: ${n.message}`),this.onWebCryptoError(e,t,r,i)))}onWebCryptoError(e,t,r,i){let n=this.enableSoftwareAES;if(n){this.useSoftware=!0,this.logEnabled=!0,this.softwareDecrypt(e,t,r,i);let n=this.flush();if(n)return n.buffer}throw Error("WebCrypto"+(n?" and softwareDecrypt":"")+": failed to decrypt data")}getValidChunk(e){let t=e,r=e.length-e.length%16;return r!==e.length&&(t=e.slice(0,r),this.remainderData=e.slice(r)),t}logOnce(e){this.logEnabled&&($.log(`[decrypter]: ${e}`),this.logEnabled=!1)}}class tg{constructor(e){this.config=void 0,this.loader=null,this.partLoadTimeout=-1,this.config=e}destroy(){this.loader&&(this.loader.destroy(),this.loader=null)}abort(){this.loader&&this.loader.abort()}load(e,t){let r=e.url;if(!r)return Promise.reject(new tv({type:s.NETWORK_ERROR,details:a.FRAG_LOAD_ERROR,fatal:!1,frag:e,error:Error(`Fragment does not have a ${r?"part list":"url"}`),networkDetails:null}));this.abort();let i=this.config,n=i.fLoader,o=i.loader;return new Promise((l,u)=>{if(this.loader&&this.loader.destroy(),e.gap)if(e.tagList.some(e=>"GAP"===e[0]))return void u(ty(e));else e.gap=!1;let c=this.loader=n?new n(i):new o(i),d=tm(e);e.loader=c;let h=te(i.fragLoadPolicy.default),f={loadPolicy:h,timeout:h.maxLoadTimeMs,maxRetry:0,retryDelay:0,maxRetryDelay:0,highWaterMark:"initSegment"===e.sn?1/0:131072};e.stats=c.stats;let p={onSuccess:(t,r,i,n)=>{this.resetLoader(e,c);let s=t.data;i.resetIV&&e.decryptdata&&(e.decryptdata.iv=new Uint8Array(s.slice(0,16)),s=s.slice(16)),l({frag:e,part:null,payload:s,networkDetails:n})},onError:(t,i,n,o)=>{this.resetLoader(e,c),u(new tv({type:s.NETWORK_ERROR,details:a.FRAG_LOAD_ERROR,fatal:!1,frag:e,response:O({url:r,data:void 0},t),error:Error(`HTTP Error ${t.code} ${t.text}`),networkDetails:n,stats:o}))},onAbort:(t,r,i)=>{this.resetLoader(e,c),u(new tv({type:s.NETWORK_ERROR,details:a.INTERNAL_ABORTED,fatal:!1,frag:e,error:Error("Aborted"),networkDetails:i,stats:t}))},onTimeout:(t,r,i)=>{this.resetLoader(e,c),u(new tv({type:s.NETWORK_ERROR,details:a.FRAG_LOAD_TIMEOUT,fatal:!1,frag:e,error:Error(`Timeout after ${f.timeout}ms`),networkDetails:i,stats:t}))}};t&&(p.onProgress=(r,i,n,s)=>t({frag:e,part:null,payload:n,networkDetails:s})),c.load(d,f,p)})}loadPart(e,t,r){this.abort();let i=this.config,n=i.fLoader,o=i.loader;return new Promise((l,u)=>{if(this.loader&&this.loader.destroy(),e.gap||t.gap)return void u(ty(e,t));let c=this.loader=n?new n(i):new o(i),d=tm(e,t);e.loader=c;let h=te(i.fragLoadPolicy.default),f={loadPolicy:h,timeout:h.maxLoadTimeMs,maxRetry:0,retryDelay:0,maxRetryDelay:0,highWaterMark:131072};t.stats=c.stats,c.load(d,f,{onSuccess:(i,n,s,a)=>{this.resetLoader(e,c),this.updateStatsFromPart(e,t);let o={frag:e,part:t,payload:i.data,networkDetails:a};r(o),l(o)},onError:(r,i,n,o)=>{this.resetLoader(e,c),u(new tv({type:s.NETWORK_ERROR,details:a.FRAG_LOAD_ERROR,fatal:!1,frag:e,part:t,response:O({url:d.url,data:void 0},r),error:Error(`HTTP Error ${r.code} ${r.text}`),networkDetails:n,stats:o}))},onAbort:(r,i,n)=>{e.stats.aborted=t.stats.aborted,this.resetLoader(e,c),u(new tv({type:s.NETWORK_E
2442RROR,details:a.INTERNAL_ABORTED,fatal:!1,frag:e,part:t,error:Error("Aborted"),networkDetails:n,stats:r}))},onTimeout:(r,i,n)=>{this.resetLoader(e,c),u(new tv({type:s.NETWORK_ERROR,details:a.FRAG_LOAD_TIMEOUT,fatal:!1,frag:e,part:t,error:Error(`Timeout after ${f.timeout}ms`),networkDetails:n,stats:r}))}})})}updateStatsFromPart(e,t){let r=e.stats,i=t.stats,n=i.total;if(r.loaded+=i.loaded,n){let i=Math.round(e.duration/t.duration),s=Math.min(Math.round(r.loaded/n),i),a=(i-s)*Math.round(r.loaded/s);r.total=r.loaded+a}else r.total=Math.max(r.loaded,r.total);let s=r.loading,a=i.loading;s.start?s.first+=a.first-a.start:(s.start=a.start,s.first=a.first),s.end=a.end}resetLoader(e,t){e.loader=null,this.loader===t&&(self.clearTimeout(this.partLoadTimeout),this.loader=null),t.destroy()}}function tm(e,t=null){let i=t||e,n={frag:e,part:t,responseType:"arraybuffer",url:i.url,headers:{},rangeStart:0,rangeEnd:0},s=i.byteRangeStartOffset,a=i.byteRangeEndOffset;if(r(s)&&r(a)){var o,l;let t=s,r=a;if("initSegment"===e.sn&&("AES-128"===(l=null==(o=e.decryptdata)?void 0:o.method)||"AES-256"===l)){let e=a-s;e%16&&(r=a+(16-e%16)),0!==s&&(n.resetIV=!0,t=s-16)}n.rangeStart=t,n.rangeEnd=r}return n}function ty(e,t){let r=Error(`GAP ${e.gap?"tag":"attribute"} found`),i={type:s.MEDIA_ERROR,details:a.FRAG_GAP,fatal:!1,frag:e,error:r,networkDetails:null};return t&&(i.part=t),(t||e).stats.aborted=!0,new tv(i)}class tv extends Error{constructor(e){super(e.error.message),this.data=void 0,this.data=e}}class tb extends P{constructor(e,t){super(e,t),this._boundTick=void 0,this._tickTimer=null,this._tickInterval=null,this._tickCallCount=0,this._boundTick=this.tick.bind(this)}destroy(){this.onHandlerDestroying(),this.onHandlerDestroyed()}onHandlerDestroying(){this.clearNextTick(),this.clearInterval()}onHandlerDestroyed(){}hasInterval(){return!!this._tickInterval}hasNextTick(){return!!this._tickTimer}setInterval(e){return!this._tickInterval&&(this._tickCallCount=0,this._tickInterval=self.setInterval(this._boundTick,e),!0)}clearInterval(){return!!this._tickInterval&&(self.clearInterval(this._tickInterval),this._tickInterval=null,!0)}clearNextTick(){return!!this._tickTimer&&(self.clearTimeout(this._tickTimer),this._tickTimer=null,!0)}tick(){this._tickCallCount++,1===this._tickCallCount&&(this.doTick(),this._tickCallCount>1&&this.tickImmediate(),this._tickCallCount=0)}tickImmediate(){this.clearNextTick(),this._tickTimer=self.setTimeout(this._boundTick,0)}doTick(){}}class t_{constructor(e,t,r,i=0,n=-1,s=!1){this.level=void 0,this.sn=void 0,this.part=void 0,this.id=void 0,this.size=void 0,this.partial=void 0,this.transmuxing=tE(),this.buffering={audio:tE(),video:tE(),audiovideo:tE()},this.level=e,this.sn=t,this.id=r,this.size=i,this.part=n,this.partial=s}}function tE(){return{start:0,executeStart:0,executeEnd:0,end:0}}let tS={length:0,start:()=>0,end:()=>0};class tx{static isBuffered(e,t){if(e){let r=tx.getBuffered(e);for(let e=r.length;e--;)if(t>=r.start(e)&&t<=r.end(e))return!0}return!1}static bufferedRanges(e){if(e){let t=tx.getBuffered(e);return tx.timeRangesToArray(t)}return[]}static timeRangesToArray(e){let t=[];for(let r=0;r<e.length;r++)t.push({start:e.start(r),end:e.end(r)});return t}static bufferInfo(e,t,r){if(e){let i=tx.bufferedRanges(e);if(i.length)return tx.bufferedInfo(i,t,r)}return{len:0,start:t,end:t,bufferedIndex:-1}}static bufferedInfo(e,t,r){let i;t=Math.max(0,t),e.length>1&&e.sort((e,t)=>e.start-t.start||t.end-e.end);let n=-1,s=[];if(r)for(let i=0;i<e.length;i++){t>=e[i].start&&t<=e[i].end&&(n=i);let a=s.length;if(a){let t=s[a-1].end;e[i].start-t<r?e[i].end>t&&(s[a-1].end=e[i].end):s.push(e[i])}else s.push(e[i])}else s=e;let a=0,o=t,l=t;for(let e=0;e<s.length;e++){let u=s[e].start,c=s[e].end;if(-1===n&&t>=u&&t<=c&&(n=e),t+r>=u&&t<c)o=u,a=(l=c)-t;else if(t+r<u){i=u;break}}return{len:a,start:o||0,end:l||0,nextStart:i,buffered:e,bufferedIndex:n}}static getBuffered(e){try{return e.buffered||tS}catch(e){return $.log("failed to get media.buffered",e),tS}}}let tT=/\{\$([a-zA-Z0-9-_]+)\}/g;function tw(e,t){if(null!==e.variableList||e.hasVariableRefs){let r=e.variableList;return t.replace(tT,t=>{let i=t.substring(2,t.length-1),n=null==r?void 0:r[i];return void 0===n?(e.playlistParsingError||(e.playlistParsingError=Error(`Missing preceding EXT-X-DEFINE tag for Variable Reference: "${i}"`)),t):n})}return t}function tA(e,t,r){let i,n,s=e.variableList;if(s||(e.variableList=s={}),"QUERYPARAM"in t){i=t.QUERYPARAM;try{let e=new self.URL(r).searchParams;if(e.has(i))n=e.get(i);else throw Error(`"${i}" does not match any query parameter in URI: "${r}"`)}catch(t){e.playlistParsingError||(e.playlistParsingError=Error(`EXT-X-DEFINE QUERYPARAM: ${t.message}`))}}else i=t.NAME,n=t.VALUE;i in s?e.playlistParsingError||(e.playlistParsingError=Error(`EXT-X-DEFINE duplicate Variable Name declarations: "${i}"`)):s[i]=n||""}let tR=/^(\d+)x(\d+)$/,tI=/(.+?)=(".*?"|.*?)(?:,|$)/g;class tk{constructor(e,t){"string"==typeof e&&(e=tk.parseAttrList(e,t)),D(this,e)}get clientAttrs(){return Object.keys(this).filter(e=>"X-"===e.substring(0,2))}decimalInteger(e){let t=parseInt(this[e],10);return t>Number.MAX_SAFE_INTEGER?1/0:t}hexadecimalInteger(e){if(this[e]){let t=(this[e]||"0x").slice(2),r=new Uint8Array((t=(1&t.length?"0":"")+t).length/2);for(let e=0;e<t.length/2;e++)r[e]=parseInt(t.slice(2*e,2*e+2),16);return r}return null}hexadecimalIntegerAsNumber(e){let t=parseInt(this[e],16);return t>Number.MAX_SAFE_INTEGER?1/0:t}decimalFloatingPoint(e){return parseFloat(this[e])}optionalFloat(e,t){let r=this[e];return r?parseFloat(r):t}enumeratedString(e){return this[e]}enumeratedStringList(e,t){let r=this[e];return(r?r.split(/[ ,]+/):[]).reduce((e,t)=>
vendor: 4,193 bytes, line 2442
2442(e[t.toLowerCase()]=!0,e),t)}bool(e){return"YES"===this[e]}decimalResolution(e){let t=tR.exec(this[e]);if(null!==t)return{width:parseInt(t[1],10),height:parseInt(t[2],10)}}static parseAttrList(e,t){let r,i={};for(tI.lastIndex=0;null!==(r=tI.exec(e));){let n=r[1].trim(),s=r[2],a=0===s.indexOf('"')&&s.lastIndexOf('"')===s.length-1,o=!1;if(a)s=s.slice(1,-1);else switch(n){case"IV":case"SCTE35-CMD":case"SCTE35-IN":case"SCTE35-OUT":o=!0}if(t&&(a||o))s=tw(t,s);else if(!o&&!a)switch(n){case"CLOSED-CAPTIONS":if("NONE"===s)break;case"ALLOWED-CPC":case"CLASS":case"ASSOC-LANGUAGE":case"AUDIO":case"BYTERANGE":case"CHANNELS":case"CHARACTERISTICS":case"CODECS":case"DATA-ID":case"END-DATE":case"GROUP-ID":case"ID":case"IMPORT":case"INSTREAM-ID":case"KEYFORMAT":case"KEYFORMATVERSIONS":case"LANGUAGE":case"NAME":case"PATHWAY-ID":case"QUERYPARAM":case"RECENTLY-REMOVED-DATERANGES":case"SERVER-URI":case"STABLE-RENDITION-ID":case"STABLE-VARIANT-ID":case"START-DATE":case"SUBTITLES":case"SUPPLEMENTAL-CODECS":case"URI":case"VALUE":case"VIDEO":case"X-ASSET-LIST":case"X-ASSET-URI":$.warn(`${e}: attribute ${n} is missing quotes`)}i[n]=s}return i}}class tC{constructor(e,t,i=0){var n;if(this.attr=void 0,this.tagAnchor=void 0,this.tagOrder=void 0,this._startDate=void 0,this._endDate=void 0,this._dateAtEnd=void 0,this._cue=void 0,this._badValueForSameId=void 0,this.tagAnchor=(null==t?void 0:t.tagAnchor)||null,this.tagOrder=null!=(n=null==t?void 0:t.tagOrder)?n:i,t){const r=t.attr;for(const t in r)if(Object.prototype.hasOwnProperty.call(e,t)&&e[t]!==r[t]){$.warn(`DATERANGE tag attribute: "${t}" does not match for tags with ID: "${e.ID}"`),this._badValueForSameId=t;break}e=D(new tk({}),r,e)}if(this.attr=e,t?(this._startDate=t._startDate,this._cue=t._cue,this._endDate=t._endDate,this._dateAtEnd=t._dateAtEnd):this._startDate=new Date(e["START-DATE"]),"END-DATE"in this.attr){const e=(null==t?void 0:t.endDate)||new Date(this.attr["END-DATE"]);r(e.getTime())&&(this._endDate=e)}}get id(){return this.attr.ID}get class(){return this.attr.CLASS}get cue(){let e=this._cue;return void 0===e?this._cue=this.attr.enumeratedStringList(this.attr.CUE?"CUE":"X-CUE",{pre:!1,post:!1,once:!1}):e}get startTime(){let{tagAnchor:e}=this;return null===e||null===e.programDateTime?($.warn(`Expected tagAnchor Fragment with PDT set for DateRange "${this.id}": ${e}`),NaN):e.start+(this.startDate.getTime()-e.programDateTime)/1e3}get startDate(){return this._startDate}get endDate(){let e=this._endDate||this._dateAtEnd;if(e)return e;let t=this.duration;return null!==t?this._dateAtEnd=new Date(this._startDate.getTime()+1e3*t):null}get duration(){if("DURATION"in this.attr){let e=this.attr.decimalFloatingPoint("DURATION");if(r(e))return e}else if(this._endDate)return(this._endDate.getTime()-this._startDate.getTime())/1e3;return null}get plannedDuration(){return"PLANNED-DURATION"in this.attr?this.attr.decimalFloatingPoint("PLANNED-DURATION"):null}get endOnNext(){return this.attr.bool("END-ON-NEXT")}get isInterstitial(){return"com.apple.hls.interstitial"===this.class}get isValid(){return!!this.id&&!this._badValueForSameId&&r(this.startDate.getTime())&&(null===this.duration||this.duration>=0)&&(!this.endOnNext||!!this.class)&&(!this.attr.CUE||!this.cue.pre&&!this.cue.post||this.cue.pre!==this.cue.post)&&(!this.isInterstitial||"X-ASSET-URI"in this.attr||"X-ASSET-LIST"in this.attr)}}class tD{constructor(e){this.PTSKnown=!1,this.alignedSliding=!1,this.averagetargetduration=void 0,this.endCC=0,this.endSN=0,this.fragments=void 0,this.fragmentHint=void 0,this.partList=null,this.dateRanges=void 0,this.dateRangeTagCount=0,this.live=!0,this.requestScheduled=-1,this.ageHeader=0,this.advancedDateTime=void 0,this.updated=!0,this.advanced=!0,this.misses=0,this.startCC=0,this.startSN=0,this.startTimeOffset=null,this.targetduration=0,this.totalduration=0,this.type=null,this.url=void 0,this.m3u8="",this.version=null,this.canBlockReload=!1,this.canSkipUntil=0,this.canSkipDateRanges=!1,this.skippedSegments=0,this.recentlyRemovedDateranges=void 0,this.partHoldBack=0,this.holdBack=0,this.partTarget=0,this.preloadHint=void 0,this.renditionReports=void 0,this.tuneInGoal=0,this.deltaUpdateFailed=void 0,this.drift
2442StartTime=0,this.driftEndTime=0,this.driftStart=0,this.driftEnd=0,this.encryptedFragments=void 0,this.playlistParsingError=null,this.variableList=null,this.hasVariableRefs=!1,this.appliedTimelineOffset=void 0,this.fragments=[],this.encryptedFragments=[],this.dateRanges={},this.url=e}reloaded(e){if(!e){this.advanced=!0,this.updated=!0;return}let t=this.lastPartSn-e.lastPartSn,r=this.lastPartIndex-e.lastPartIndex;this.updated=this.endSN!==e.endSN||!!r||!!t||!this.live,this.advanced=this.endSN>e.endSN||t>0||0===t&&r>0,this.updated||this.advanced?this.misses=Math.floor(.6*e.misses):this.misses=e.misses+1}hasKey(e){return this.encryptedFragments.some(t=>{let r=t.decryptdata;return r||(t.setKeyFormat(e.keyFormat),r=t.decryptdata),!!r&&e.matches(r)})}get hasProgramDateTime(){return!!this.fragments.length&&r(this.fragments[this.fragments.length-1].programDateTime)}get levelTargetDuration(){return this.averagetargetduration||this.targetduration||10}get drift(){let e=this.driftEndTime-this.driftStartTime;return e>0?1e3*(this.driftEnd-this.driftStart)/e:1}get edge(){return this.partEnd||this.fragmentEnd}get partEnd(){var e;return null!=(e=this.partList)&&e.length?this.partList[this.partList.length-1].end:this.fragmentEnd}get fragmentEnd(){return this.fragments.length?this.fragments[this.fragments.length-1].end:0}get fragmentStart(){return this.fragments.length?this.fragments[0].start:0}get age(){return this.advancedDateTime?Math.max(Date.now()-this.advancedDateTime,0)/1e3:0}get lastPartIndex(){var e;return null!=(e=this.partList)&&e.length?this.partList[this.partList.length-1].index:-1}get maxPartIndex(){let e=this.partList;if(e){let t=this.lastPartIndex;if(-1!==t){for(let r=e.length;r--;)if(e[r].index>t)return e[r].index;return t}}return 0}get lastPartSn(){var e;return null!=(e=this.partList)&&e.length?this.partList[this.partList.length-1].fragment.sn:this.endSN}get expired(){if(this.live&&this.age&&this.misses<3){let e=this.partEnd-this.fragmentStart;return this.age>Math.max(e,this.totalduration)+this.levelTargetDuration}return!1}}function tL(e,t){return e.length===t.length&&!e.some((e,r)=>e!==t[r])}function tO(e,t){return!e&&!t||!!e&&!!t&&tL(e,t)}function tP(e){return"AES-128"===e||"AES-256"===e||"AES-256-CTR"===e}function tF(e){switch(e){case"AES-128":case"AES-256":return 0;case"AES-256-CTR":return 1;default:throw Error(`invalid full segment method ${e}`)}}function tN(e){return Uint8Array.from(atob(e),e=>e.charCodeAt(0))}function tM(e){return Uint8Array.from(unescape(encodeURIComponent(e)),e=>e.charCodeAt(0))}function tj(e){let t=function(e,t,r){let i=e[t];e[t]=e[r],e[r]=i};t(e,0,3),t(e,1,2),t(e,4,5),t(e,6,7)}function t$(e){let t=e.split(":"),r=null;if("data"===t[0]&&2===t.length){let e=t[1].split(";"),i=e[e.length-1].split(",");if(2===i.length){let t="base64"===i[0],n=i[1];if(t)e.splice(-1,1),r=tN(n);else{let e,t;e=tM(n).subarray(0,16),(t=new Uint8Array(16)).set(e,16-e.length),r=t}}}return r}let tU="u">typeof self?self:void 0;var tB="org.w3.clearkey",tV="com.apple.fps",tG="com.microsoft.playready",tq="com.widevine.alpha",tH="org.w3.clearkey",tz="com.apple.streamingkeydelivery",tK="com.microsoft.playready",tW="urn:uuid:edef8ba9-79d6-4ace-a3c8-27dcd51d21ed";function tY(e){switch(e){case tz:return tV;case tK:return tG;case tW:return tq;case tH:return tB}}function tQ(e){switch(e){case tV:return tz;case tG:return tK;case tq:return tW;case tB:return tH}}function tX(e){let{drmSystems:t,widevineLicenseUrl:r}=e,i=t?[tV,tq,tG,tB].filter(e=>!!t[e]):[];return!i[tq]&&r&&i.push(tq),i}let tJ=null!=tU&&null!=(f=tU.navigator)&&f.requestMediaKeySystemAccess?self.navigator.requestMediaKeySystemAccess.bind(self.navigator):null;function tZ(e){let t=new Uint16Array(e.buffer,e.byteOffset,e.byteLength/2),r=String.fromCharCode.apply(null,Array.from(t)),i=r.substring(r.indexOf("<"),r.length),n=new DOMParser().parseFromString(i,"text/xml").getElementsByTagName("KID")[0];if(n){let e=n.childNodes[0]?n.childNodes[0].nodeValue:n.getAttribute("VALUE");if(e){let t=tN(e).subarray(0,16);return tj(t),t}}return null}let t0={};class t1{static clearKeyUriToKeyIdMap(){t0={}}static setKeyIdForUri(e,t){t0[e]=t}static addKeyIdForUri(e){let t=Object.keys(t0).length%Number.MAX_SAFE_INTEGER,r=new
2442Uint8Array(16);return new DataView(r.buffer,12,4).setUint32(0,t),t0[e]=r,r}constructor(e,t,r,i=[1],n=null,s){this.uri=void 0,this.method=void 0,this.keyFormat=void 0,this.keyFormatVersions=void 0,this.encrypted=void 0,this.isCommonEncryption=void 0,this.iv=null,this.key=null,this.keyId=null,this.pssh=null,this.method=e,this.uri=t,this.keyFormat=r,this.keyFormatVersions=i,this.iv=n,this.encrypted=!!e&&"NONE"!==e,this.isCommonEncryption=this.encrypted&&!tP(e),null!=s&&s.startsWith("0x")&&(this.keyId=new Uint8Array(q(s)))}matches(e){return e.uri===this.uri&&e.method===this.method&&e.encrypted===this.encrypted&&e.keyFormat===this.keyFormat&&tL(e.keyFormatVersions,this.keyFormatVersions)&&tO(e.iv,this.iv)&&tO(e.keyId,this.keyId)}isSupported(){if(this.method){if(tP(this.method)||"NONE"===this.method)return!0;if("identity"===this.keyFormat)return"SAMPLE-AES"===this.method;switch(this.keyFormat){case tz:case tW:case tK:case tH:return -1!==["SAMPLE-AES","SAMPLE-AES-CENC","SAMPLE-AES-CTR"].indexOf(this.method)}}return!1}getDecryptData(e,t){var r,i;if(!this.encrypted||!this.uri)return null;if(tP(this.method)){let t=this.iv;return t||("number"!=typeof e&&($.warn(`missing IV for initialization segment with method="${this.method}" - compliance issue`),e=0),t=function(e){let t=new Uint8Array(16);for(let r=12;r<16;r++)t[r]=e>>8*(15-r)&255;return t}(e)),new t1(this.method,this.uri,"identity",this.keyFormatVersions,t)}if(this.keyId){let e=t0[this.uri];if(e&&!tL(this.keyId,e)&&t1.setKeyIdForUri(this.uri,this.keyId),this.pssh)return this}let n=t$(this.uri);if(n)switch(this.keyFormat){case tW:if(this.pssh=n,!this.keyId){let e=function(e){let t=[];if(e instanceof ArrayBuffer){let r=e.byteLength,i=0;for(;i+32<r;){let r=function(e){let t=e.getUint32(0),r=e.byteOffset,i=e.byteLength;if(i<t)return{offset:r,size:i};if(0x70737368!==e.getUint32(4))return{offset:r,size:t};let n=e.getUint32(8)>>>24;if(0!==n&&1!==n)return{offset:r,size:t};let s=e.buffer,a=G(new Uint8Array(s,r+12,16)),o=null,l=0;if(0===n)l=28;else{let n=e.getUint32(28);if(!n||i<32+16*n)return{offset:r,size:t};o=[];for(let e=0;e<n;e++)o.push(new Uint8Array(s,r+32+16*e,16));l=32+16*n}if(!l)return{offset:r,size:t};let u=e.getUint32(l);return t-32<u?{offset:r,size:t}:{version:n,systemId:a,kids:o,data:new Uint8Array(s,r+l+4,u),offset:r,size:t}}(new DataView(e,i));t.push(r),i+=r.size}}return t}(n.buffer);if(e.length){let t=e[0];this.keyId=null!=(r=t.kids)&&r.length?t.kids[0]:null}}this.keyId||(this.keyId=t2(t));break;case tK:{let e=new Uint8Array([154,4,240,121,152,64,66,134,171,146,230,91,224,136,95,149]);this.pssh=function(e,t){let r,i;if(16!==e.byteLength)throw RangeError("Invalid system id");r=new Uint8Array,i=new Uint8Array;let n=new Uint8Array(4);return t.byteLength>0&&new DataView(n.buffer).setUint32(0,t.byteLength,!1),function(e,...t){let r=t.length,i=8,n=r;for(;n--;)i+=t[n].byteLength;let s=new Uint8Array(i);for(s[0]=i>>24&255,s[1]=i>>16&255,s[2]=i>>8&255,s[3]=255&i,s.set(e,4),n=0,i=8;n<r;n++)s.set(t[n],i),i+=t[n].byteLength;return s}([112,115,115,104],new Uint8Array([0,0,0,0]),e,i,r,n,t)}(e,n),this.keyId=tZ(n);break}default:{let e=n.subarray(0,16);if(16!==e.length){let t=new Uint8Array(16);t.set(e,16-e.length),e=t}this.keyId=e}}if(!this.keyId||16!==this.keyId.byteLength){let e,r;!(e=(r=null==(i=t)?void 0:i[tW])?r.keyId:null)&&((e=t2(t))||(e=t0[this.uri])),e&&(this.keyId=e,t1.setKeyIdForUri(this.uri,e))}return this}}function t2(e){let t=null==e?void 0:e[tK];if(t){let e=t$(t.uri);if(e)return tZ(e)}return null}let t3=/#EXT-X-STREAM-INF:([^\r\n]*)(?:[\r\n](?:#[^\r\n]*)?)*([^\r\n]+)|#EXT-X-(SESSION-DATA|SESSION-KEY|DEFINE|CONTENT-STEERING|START):([^\r\n]*)[\r\n]+/g,t4=/#EXT-X-MEDIA:(.*)/g,t5=/^#EXT(?:INF|-X-TARGETDURATION):/m,t8=RegExp([/#EXTINF:\s*(\d*(?:\.\d+)?)(?:,(.*)\s+)?/.source,/(?!#) *(\S[^\r\n]*)/.source,/#.*/.source].join("|"),"g"),t6=new RegExp([/#EXT-X-(PROGRAM-DATE-TIME|BYTERANGE|DATERANGE|DEFINE|KEY|MAP|PART|PART-INF|PLAYLIST-TYPE|PRELOAD-HINT|RENDITION-REPORT|SERVER-CONTROL|SKIP|START):(.+)/.source,/#EXT-X-(BITRATE|DISCONTINUITY-SEQUENCE|MEDIA-SEQUENCE|TARGETDURATION|VERSION): *(\d+)/.source,/#EXT-X-(DISCONTINUITY|ENDLIST|GAP|INDEPENDENT-SEGMENTS)/.source,/(#)([^:]*):(.*)/.source,/(#)(.*)(?:.*)\r?\n?/.source].join("|"));class t7{static findGroup(e,t){for(let r=0;r<e.length;r++){let i=e[r];if(i.id===t)return i}}static resolve(e,t){return z.buildAbsoluteURL(t,e,{alwaysNormalize:!0})}static isMediaPlaylist(e){return t5.test(e)}static parseMasterPlaylist(e,t){var r;let i,n={contentSteering:null,levels:[],playlistParsingError:null,sessionData:null,sessionKeys:null,startTimeOffset:null,variableList:null,hasVariableRefs:tT.test(e)},s=[];if(t3.lastIndex=0,!e.startsWith("#EXTM3U"))return n.playlistParsingError=Error("no EXTM3U delimiter"),n;for(;null!=(i=t3.exec(e));)if(i[1]){let e=new tk(i[1],n),a=tw(n,i[2]),o={attrs:e,bitrate:e.decimalInteger("BANDWIDTH")||e.decimalInteger("AVERAGE-BANDWIDTH"),name:e.NAME,url:t7.resolve(a,t)},l=e.decimalResolution("RESOLUTION");l&&(o.width=l.width,o.height=l.height),rr(e.CODECS,o);let u=e["SUPPLEMENTAL-CODECS"];u&&(o.supplemental={},rr(u,o.supplemental)),null!=(r=o.unknownCodecs)&&r.length||s.push(o),n.levels.push(o)}else if(i[3]){let e=i[3],r=i[4];switch(e){case"SESSION-DATA":{let e=new tk(r,n),t=e["DATA-ID"];t&&(null===n.sessionData&&(n.sessionData={}),n.sessionData[t]=e);break}case"SESSION-KEY":{let e=re(r,t,n);e.encrypted&&e.isSupported()?(null===n.sessionKeys&&(n.sessionKeys=[]),n.sessionKeys.push(e)):$.
2442warn(`[Keys] Ignoring invalid EXT-X-SESSION-KEY tag: "${r}"`);break}case"DEFINE":{let e=new tk(r,n);tA(n,e,t)}break;case"CONTENT-STEERING":{let e=new tk(r,n);n.contentSteering={uri:t7.resolve(e["SERVER-URI"],t),pathwayId:e["PATHWAY-ID"]||"."};break}case"START":n.startTimeOffset=rt(r)}}let a=s.length>0&&s.length<n.levels.length;return n.levels=a?s:n.levels,0===n.levels.length&&(n.playlistParsingError=Error("no levels found in manifest")),n}static parseMasterPlaylistMedia(e,t,r){let i,n={},s=r.levels,a={AUDIO:s.map(e=>({id:e.attrs.AUDIO,audioCodec:e.audioCodec})),SUBTITLES:s.map(e=>({id:e.attrs.SUBTITLES,textCodec:e.textCodec})),"CLOSED-CAPTIONS":[]},o=0;for(t4.lastIndex=0;null!==(i=t4.exec(e));){let e=new tk(i[1],r),s=e.TYPE;if(s){let r=a[s],i=n[s]||[];n[s]=i;let l=e.LANGUAGE,u=e["ASSOC-LANGUAGE"],c=e.CHANNELS,d=e.CHARACTERISTICS,h=e["INSTREAM-ID"],f={attrs:e,bitrate:0,id:o++,groupId:e["GROUP-ID"]||"",name:e.NAME||l||"",type:s,default:e.bool("DEFAULT"),autoselect:e.bool("AUTOSELECT"),forced:e.bool("FORCED"),lang:l,url:e.URI?t7.resolve(e.URI,t):""};if(u&&(f.assocLang=u),c&&(f.channels=c),d&&(f.characteristics=d),h&&(f.instreamId=h),null!=r&&r.length){let e=t7.findGroup(r,f.groupId)||r[0];ri(f,e,"audioCodec"),ri(f,e,"textCodec")}i.push(f)}}return n}static parseLevelPlaylist(e,t,i,n,s,a){var o;let l,u,c,d,h={url:t},f=new tD(t),p=f.fragments,g=[],m=null,y=0,v=0,b=0,_=0,E=0,S=null,x=new Z(n,h),T=-1,w=!1,A=null;if(t8.lastIndex=0,f.m3u8=e,f.hasVariableRefs=tT.test(e),(null==(o=t8.exec(e))?void 0:o[0])!=="#EXTM3U")return f.playlistParsingError=Error("Missing format identifier #EXTM3U"),f;for(;null!==(l=t8.exec(e));){w&&(w=!1,(x=new Z(n,h)).playlistOffset=b,x.setStart(b),x.sn=y,x.cc=_,E&&(x.bitrate=E),x.level=i,m&&(x.initSegment=m,m.rawProgramDateTime&&(x.rawProgramDateTime=m.rawProgramDateTime,m.rawProgramDateTime=null),A&&(x.setByteRange(A),A=null)));let e=l[1];if(e){x.duration=parseFloat(e);let t=(" "+l[2]).slice(1);x.title=t||null,x.tagList.push(t?["INF",e,t]:["INF",e])}else if(l[3]){if(r(x.duration)){x.playlistOffset=b,x.setStart(b),c&&ra(x,c,f),x.sn=y,x.level=i,x.cc=_,p.push(x);let e=(" "+l[3]).slice(1);x.relurl=tw(f,e),rn(x,S,g),S=x,b+=x.duration,y++,v=0,w=!0}}else{if(!(l=l[0].match(t6))){$.warn("No matches on slow regex match for level playlist!");continue}for(u=1;u<l.length&&void 0===l[u];u++);let e=(" "+l[u]).slice(1),s=(" "+l[u+1]).slice(1),o=l[u+2]?(" "+l[u+2]).slice(1):null;switch(e){case"BYTERANGE":S?x.setByteRange(s,S):x.setByteRange(s);break;case"PROGRAM-DATE-TIME":x.rawProgramDateTime=s,x.tagList.push(["PROGRAM-DATE-TIME",s]),-1===T&&(T=p.length);break;case"PLAYLIST-TYPE":f.type&&ro(f,e,l),f.type=s.toUpperCase();break;case"MEDIA-SEQUENCE":0!==f.startSN?ro(f,e,l):p.length>0&&rl(f,e,l),y=f.startSN=parseInt(s);break;case"SKIP":{f.skippedSegments&&ro(f,e,l);let t=new tk(s,f),i=t.decimalInteger("SKIPPED-SEGMENTS");if(r(i)){f.skippedSegments+=i;for(let e=i;e--;)p.push(null);y+=i}let n=t.enumeratedString("RECENTLY-REMOVED-DATERANGES");n&&(f.recentlyRemovedDateranges=(f.recentlyRemovedDateranges||[]).concat(n.split(" ")));break}case"TARGETDURATION":0!==f.targetduration&&ro(f,e,l),f.targetduration=Math.max(parseInt(s),1);break;case"VERSION":null!==f.version&&ro(f,e,l),f.version=parseInt(s);break;case"INDEPENDENT-SEGMENTS":break;case"ENDLIST":f.live||ro(f,e,l),f.live=!1;break;case"#":(s||o)&&x.tagList.push(o?[s,o]:[s]);break;case"DISCONTINUITY":_++,x.tagList.push(["DIS"]);break;case"GAP":x.gap=!0,x.tagList.push([e]);break;case"BITRATE":x.tagList.push([e,s]),r(E=1e3*parseInt(s))?x.bitrate=E:E=0;break;case"DATERANGE":{let e=new tk(s,f),t=new tC(e,f.dateRanges[e.ID],f.dateRangeTagCount);f.dateRangeTagCount++,t.isValid||f.skippedSegments?f.dateRanges[t.id]=t:$.warn(`Ignoring invalid DATERANGE tag: "${s}"`),x.tagList.push(["EXT-X-DATERANGE",s]);break}case"DEFINE":{let e=new tk(s,f);"IMPORT"in e?function(e,t,r){let i=t.IMPORT;if(r&&i in r){let t=e.variableList;t||(e.variableList=t={}),t[i]=r[i]}else e.playlistParsingError||(e.playlistParsingError=Error(`EXT-X-DEFINE IMPORT attribute not found in Multivariant Playlist: "${i}"`))}(f,e,a):tA(f,e,t)}break;case"DISCONTINUITY-SEQUENCE":0!==f.startCC?ro(f,e,l):p.length>0&&rl(f,e,l),f.startCC=_=parseInt(s);break;case"KEY":{let e=re(s,t,f);
2442if(e.isSupported()){if("NONE"===e.method){c=void 0;break}c||(c={});let t=c[e.keyFormat];null!=t&&t.matches(e)||(t&&(c=D({},c)),c[e.keyFormat]=e)}else $.warn(`[Keys] Ignoring unsupported EXT-X-KEY tag: "${s}"`);break}case"START":f.startTimeOffset=rt(s);break;case"MAP":{let e=new tk(s,f);if(x.duration){let t=new Z(n,h);rs(t,e,i,c),m=t,x.initSegment=m,m.rawProgramDateTime&&!x.rawProgramDateTime&&(x.rawProgramDateTime=m.rawProgramDateTime)}else{let t=x.byteRangeEndOffset;if(t){let e=x.byteRangeStartOffset;A=`${t-e}@${e}`}else A=null;rs(x,e,i,c),m=x,w=!0}m.cc=_;break}case"SERVER-CONTROL":d&&ro(f,e,l),f.canBlockReload=(d=new tk(s)).bool("CAN-BLOCK-RELOAD"),f.canSkipUntil=d.optionalFloat("CAN-SKIP-UNTIL",0),f.canSkipDateRanges=f.canSkipUntil>0&&d.bool("CAN-SKIP-DATERANGES"),f.partHoldBack=d.optionalFloat("PART-HOLD-BACK",0),f.holdBack=d.optionalFloat("HOLD-BACK",0);break;case"PART-INF":f.partTarget&&ro(f,e,l),f.partTarget=new tk(s).decimalFloatingPoint("PART-TARGET");break;case"PART":{let e=f.partList;e||(e=f.partList=[]);let t=v>0?e[e.length-1]:void 0,r=v++,i=new ee(new tk(s,f),x,h,r,t);e.push(i),x.duration+=i.duration;break}case"PRELOAD-HINT":{let e=new tk(s,f);f.preloadHint=e;break}case"RENDITION-REPORT":{let e=new tk(s,f);f.renditionReports=f.renditionReports||[],f.renditionReports.push(e);break}default:$.warn(`line parsed but not handled: ${l}`)}}}S&&!S.relurl?(p.pop(),b-=S.duration,f.partList&&(f.fragmentHint=S)):f.partList&&(rn(x,S,g),x.cc=_,f.fragmentHint=x,c&&ra(x,c,f)),f.targetduration||(f.playlistParsingError=Error("Missing Target Duration"));let R=p.length,I=p[0],k=p[R-1];if((b+=f.skippedSegments*f.targetduration)>0&&R&&k){f.averagetargetduration=b/R;let e=k.sn;f.endSN="initSegment"!==e?e:0,f.live||(k.endList=!0),T>0&&(function(e,t){let r=e[t];for(let i=t;i--;){let t=e[i];if(!t)return;t.programDateTime=r.programDateTime-1e3*t.duration,r=t}}(p,T),I&&g.unshift(I))}return f.fragmentHint&&(b+=f.fragmentHint.duration),f.totalduration=b,g.length&&f.dateRangeTagCount&&I&&t9(g,f),f.endCC=_,f}}function t9(e,t){let r=e.length;if(!r)if(!t.hasProgramDateTime)return;else{let i=t.fragments[t.fragments.length-1];e.push(i),r++}let i=e[r-1],n=t.live?1/0:t.totalduration,s=Object.keys(t.dateRanges);for(let o=s.length;o--;){let l=t.dateRanges[s[o]],u=l.startDate.getTime();l.tagAnchor=i.ref;for(let i=r;i--;){var a;if((null==(a=e[i])?void 0:a.sn)<t.startSN)break;let r=function(e,t,r,i,n){let s=r[i];if(s){let o=s.programDateTime;if(t>=o||0===i){var a;if(t<=o+1e3*(((null==(a=r[i+1])?void 0:a.start)||n)-s.start)){let n=r[i].sn-e.startSN;if(n<0)return -1;let s=e.fragments;if(s.length>r.length){let a=(r[i+1]||s[s.length-1]).sn-e.startSN;for(let e=a;e>n;e--){let r=s[e].programDateTime;if(t>=r&&t<r+1e3*s[e].duration)return e}}return n}}}return -1}(t,u,e,i,n);if(-1!==r){l.tagAnchor=t.fragments[r].ref;break}}}}function re(e,t,r){var i,n;let s=new tk(e,r),a=null!=(i=s.METHOD)?i:"",o=s.URI,l=s.hexadecimalInteger("IV"),u=s.KEYFORMATVERSIONS,c=null!=(n=s.KEYFORMAT)?n:"identity";return o&&s.IV&&!l&&$.error(`Invalid IV: ${s.IV}`),new t1(a,o?t7.resolve(o,t):"",c,(u||"1").split("/").map(Number).filter(Number.isFinite),l,s.KEYID)}function rt(e){let t=new tk(e).decimalFloatingPoint("TIME-OFFSET");return r(t)?t:null}function rr(e,t){let r=(e||"").split(/[ ,]+/).filter(e=>e);["video","audio","text"].forEach(e=>{let i=r.filter(t=>eS(t,e));i.length&&(t[`${e}Codec`]=i.map(e=>e.split("/")[0]).join(","),r=r.filter(e=>-1===i.indexOf(e)))}),t.unknownCodecs=r}function ri(e,t,r){let i=t[r];i&&(e[r]=i)}function rn(e,t,r){e.rawProgramDateTime?r.push(e):null!=t&&t.programDateTime&&(e.programDateTime=t.endProgramDateTime)}function rs(e,t,r,i){e.relurl=t.URI,t.BYTERANGE&&e.setByteRange(t.BYTERANGE),e.level=r,e.sn="initSegment",i&&(e.levelkeys=i),e.initSegment=null}function ra(e,t,r){e.levelkeys=t;let{encryptedFragments:i}=r;(!i.length||i[i.length-1].levelkeys!==t)&&Object.keys(t).some(e=>t[e].isCommonEncryption)&&i.push(e)}function ro(e,t,r){e.playlistParsingError=Error(`#EXT-X-${t} must not appear more than once (${r[0]})`)}function rl(e,t,r){e.playlistParsingError=Error(`#EXT-X-${t} must appear before the first Media Segment (${r[0]})`)}function ru(e,t){let i=t.startPTS;if(r(i)){let r,n=0;t.sn>e.sn?(n=i-e.start,r=e):(n=e.start-i,r=t),r.duration!==n&&r.setDuration(n)}else t.sn>e.sn?e.cc===t.cc&&e.minEndPTS?t.setStart(e.start+(e.minEndPTS-e.start)):t.setStart(e.start+e.duration):t.setStart(Math.max(e.start-t.duration,0))}function rc(e,t,i,n,s,a,o){let l;n-i<=0&&(o.warn("Fragment should have a positive duration",t),n=i+t.duration,a=s+t.duration);let u=i,c=n,d=t.startPTS,h=t.endPTS;if(r(d)){let l=Math.abs(d-i);e&&l>e.totalduration?o.warn(`media timestamps and playlist times differ by ${l}s for level ${t.level} ${e.url}`):r(t.deltaPTS)?t.deltaPTS=Math.max(l,t.deltaPTS):t.deltaPTS=l,u=Math.max(i,d),i=Math.min(i,d),s=void 0!==t.startDTS?Math.min(s,t.startDTS):s,c=Math.min(n,h),n=Math.max(n,h),a=void 0!==t.endDTS?Math.max(a,t.endDTS):a}let f=i-t.start;0!==t.start&&t.setStart(i),t.setDuration(n-t.start),t.startPTS=i,t.maxStartPTS=u,t.startDTS=s,t.endPTS=n,t.minEndPTS=c,t.endDTS=a;let p=t.sn;if(!e||p<e.startSN||p>e.endSN)return 0;let g=p-e.startSN,m=e.fragments;for(m[g]=t,l=g;l>0;l--)ru(m[l],m[l-1]);for(l=g;l<m.length-1;l++)ru(m[l],m[l+1]);return e.fragmentHint&&ru(m[m.length-1],e.fragmentHint),e.PTSKnown=e.alignedSliding=!0,f}function rd(e,t,r,i,n){return Error(`${e} ${n.url} 2443Playlist starting @${t.startSN} 2444${t.m3u8} 2445 2446Playlist starting @${r.startSN} 2447${r.m3u8}`)}function rh(e,t,r=!0){let i=t.startSN+t.skippedSegments-e.startSN,n=e.fragments,s=i>=0,a=0;if(s&&i<n.length)a=n[i].start;else if(s&&t.startSN===e.endSN+1)a=e.fragmentEnd;else if(s&&r)a=e.fragmentStart+i*t.levelTargetDuration;else{if(t.skippedSegments||0!==t.fragmentStart)return;a=e.fragmentStart}rf(t,a)}function rf(e,t){if(t){let r=e.fragments;for(let i=e.skippedSegments;i<r.length;i++)r[i].addStart(t);e.fragmentHint&&e.fragmentHint.addStart(t)}}function rp(e,t=1/0){let r=1e3*e.targetduration;if(e.updated){let i=e.fragments;if(i.length&&4*r>t){let e=1e3*i[i.length-1].duration;e<r&&(r=e)}}else r/=2;return Math.round(r)}function rg(e,t,r){if(!e)return null;let i=e.fragments[t-e.startSN];
2447return i||(i=e.fragmentHint)&&i.sn===t?i:t<e.startSN&&r&&r.sn===t?r:null}function rm(e,t,r){return e?ry(e.partList,t,r):null}function ry(e,t,r){if(e)for(let i=e.length;i--;){let n=e[i];if(n.index===r&&n.fragment.sn===t)return n}return null}function rv(e){e.forEach((e,t)=>{var r;null==(r=e.details)||r.fragments.forEach(e=>{e.level=t,e.initSegment&&(e.initSegment.level=t)})})}function rb(e){return e.replace(/\?[^?]*$/,"")}function r_(e,t){for(let i=0,n=e.length;i<n;i++){var r;if((null==(r=e[i])?void 0:r.cc)===t)return e[i]}return null}function rE(e,t){let r=e.start+t;e.startPTS=r,e.setStart(r),e.endPTS=r+e.duration}function rS(e,t){let r=t.fragments;for(let t=0,i=r.length;t<i;t++)rE(r[t],e);t.fragmentHint&&rE(t.fragmentHint,e),t.alignedSliding=!0}function rx(e,t){if((!t||!(e.startCC<t.endCC)||!(e.endCC>t.startCC))&&1)return;let r=Math.min(t.endCC,e.endCC),i=r_(t.fragments,r),n=r_(e.fragments,r);i&&n&&($.log(`Aligning playlist at start of dicontinuity sequence ${r}`),rS(i.start-n.start,e))}function rT(e,t){let r,i;if(!e.hasProgramDateTime||!t.hasProgramDateTime)return;let n=e.fragments,s=t.fragments;if(!n.length||!s.length)return;let a=Math.min(t.endCC,e.endCC);t.startCC<a&&e.startCC<a&&(r=r_(s,a),i=r_(n,a)),r&&i||(i=r_(n,(r=s[Math.floor(s.length/2)]).cc)||n[Math.floor(n.length/2)]);let o=r.programDateTime,l=i.programDateTime;o&&l&&rS((l-o)/1e3-(i.start-r.start),e)}function rw(e,t,r){rA(e,t,r),e.addEventListener(t,r)}function rA(e,t,r){e.removeEventListener(t,r)}let rR=function(e){let t="",r=e.length;for(let i=0;i<r;i++)t+=`[${e.start(i).toFixed(3)}-${e.end(i).toFixed(3)}]`;return t},rI="STOPPED",rk="IDLE",rC="KEY_LOADING",rD="FRAG_LOADING",rL="FRAG_LOADING_WAITING_RETRY",rO="WAITING_TRACK",rP="PARSING",rF="PARSED",rN="ENDED",rM="ERROR",rj="WAITING_INIT_PTS",r$="WAITING_LEVEL";class rU extends tb{constructor(e,t,i,n,s){super(n,e.logger),this.hls=void 0,this.fragPrevious=null,this.fragCurrent=null,this.fragmentTracker=void 0,this.transmuxer=null,this._state=rI,this.playlistType=void 0,this.media=null,this.mediaBuffer=null,this.config=void 0,this.bitrateTest=!1,this.lastCurrentTime=0,this.nextLoadPosition=0,this.startPosition=0,this.startTimeOffset=null,this.retryDate=0,this.levels=null,this.fragmentLoader=void 0,this.keyLoader=void 0,this.levelLastLoaded=null,this.startFragRequested=!1,this.decrypter=void 0,this.initPTS=[],this.buffering=!0,this.loadingParts=!1,this.loopSn=void 0,this.onMediaSeeking=()=>{let{config:e,fragCurrent:t,media:i,mediaBuffer:n,state:s}=this,a=i?i.currentTime:0,o=tx.bufferInfo(n||i,a,e.maxBufferHole),l=!o.len;if(this.log(`Media seeking to ${r(a)?a.toFixed(3):a}, state: ${s}, ${l?"out of":"in"} buffer`),this.state===rN)this.resetLoadingState();else if(t){let r=e.maxFragLookUpTolerance,i=t.start-r,n=t.start+t.duration+r;if(l||n<o.start||i>o.end){let e=a>n;(a<i||e)&&(e&&t.loader&&(this.log(`Cancelling fragment load for seek (sn: ${t.sn})`),t.abortRequests(),this.resetLoadingState()),this.fragPrevious=null)}}if(i&&(this.fragmentTracker.removeFragmentsInRange(a,1/0,this.playlistType,!0),a>this.lastCurrentTime&&(this.lastCurrentTime=a),!this.loadingParts)){let e=Math.max(o.end,a),t=this.shouldLoadParts(this.getLevelDetails(),e);t&&(this.log(`LL-Part loading ON after seeking to ${a.toFixed(2)} with buffer @${e.toFixed(2)}`),this.loadingParts=t)}!this.hls.hasEnoughToStart&&(this.log(`Setting ${l?"startPosition":"nextLoadPosition"} to ${a} for seek without enough to start`),this.nextLoadPosition=a,l&&(this.startPosition=a)),l&&this.state===rk&&this.tickImmediate()},this.onMediaEnded=()=>{this.log("setting startPosition to 0 because media ended"),this.startPosition=this.lastCurrentTime=0},this.playlistType=s,this.hls=e,this.fragmentLoader=new tg(e.config),this.keyLoader=i,this.fragmentTracker=t,this.config=e.config,this.decrypter=new tp(e.config)}registerListeners(){let{hls:e}=this;e.on(o.MEDIA_ATTACHED,this.onMediaAttached,this),e.on(o.MEDIA_DETACHING,this.onMediaDetaching,this),e.on(o.MANIFEST_LOADING,this.onManifestLoading,this),e.on(o.MANIFEST_LOADED,this.onManifestLoaded,this),e.on(o.ERROR,this.onError,this)}unregisterListeners(){let{hls:e}=this;
2447e.off(o.MEDIA_ATTACHED,this.onMediaAttached,this),e.off(o.MEDIA_DETACHING,this.onMediaDetaching,this),e.off(o.MANIFEST_LOADING,this.onManifestLoading,this),e.off(o.MANIFEST_LOADED,this.onManifestLoaded,this),e.off(o.ERROR,this.onError,this)}doTick(){this.onTickEnd()}onTickEnd(){}startLoad(e){}stopLoad(){if(this.state===rI)return;this.fragmentLoader.abort(),this.keyLoader.abort(this.playlistType);let e=this.fragCurrent;null!=e&&e.loader&&(e.abortRequests(),this.fragmentTracker.removeFragment(e)),this.resetTransmuxer(),this.fragCurrent=null,this.fragPrevious=null,this.clearInterval(),this.clearNextTick(),this.state=rI}get startPositionValue(){let{nextLoadPosition:e,startPosition:t}=this;return -1===t&&e?e:t}get bufferingEnabled(){return this.buffering}pauseBuffering(){this.buffering=!1}resumeBuffering(){this.buffering=!0}get inFlightFrag(){return{frag:this.fragCurrent,state:this.state}}_streamEnded(e,t){if(t.live||!this.media)return!1;let r=e.end||0,i=this.config.timelineOffset||0;if(r<=i)return!1;let n=e.buffered;this.config.maxBufferHole&&n&&n.length>1&&(e=tx.bufferedInfo(n,e.start,0));let s=e.nextStart;if(s&&s>i&&s<t.edge||this.media.currentTime<e.start)return!1;let a=t.partList;if(null!=a&&a.length){let e=a[a.length-1];return tx.isBuffered(this.media,e.start+e.duration/2)}let o=t.fragments[t.fragments.length-1].type;return this.fragmentTracker.isEndListAppended(o)}getLevelDetails(){if(this.levels&&null!==this.levelLastLoaded)return this.levelLastLoaded.details}get timelineOffset(){let e=this.config.timelineOffset;if(e){var t;return(null==(t=this.getLevelDetails())?void 0:t.appliedTimelineOffset)||e}return 0}onMediaAttached(e,t){let r=this.media=this.mediaBuffer=t.media;rw(r,"seeking",this.onMediaSeeking),rw(r,"ended",this.onMediaEnded);let i=this.config;this.levels&&i.autoStartLoad&&this.state===rI&&this.startLoad(i.startPosition)}onMediaDetaching(e,t){let r=!!t.transferMedia,i=this.media;if(null!==i){if(i.ended&&(this.log("MSE detaching and video ended, reset startPosition"),this.startPosition=this.lastCurrentTime=0),rA(i,"seeking",this.onMediaSeeking),rA(i,"ended",this.onMediaEnded),this.keyLoader&&!r&&this.keyLoader.detach(),this.media=this.mediaBuffer=null,this.loopSn=void 0,r){this.resetLoadingState(),this.resetTransmuxer();return}this.loadingParts=!1,this.fragmentTracker.removeAllFragments(),this.stopLoad()}}onManifestLoading(){this.initPTS=[],this.levels=this.levelLastLoaded=this.fragCurrent=null,this.lastCurrentTime=this.startPosition=0,this.startFragRequested=!1}onError(e,t){}onManifestLoaded(e,t){this.startTimeOffset=t.startTimeOffset}onHandlerDestroying(){this.stopLoad(),this.transmuxer&&(this.transmuxer.destroy(),this.transmuxer=null),super.onHandlerDestroying(),this.hls=this.onMediaSeeking=this.onMediaEnded=null}onHandlerDestroyed(){this.state=rI,this.fragmentLoader&&this.fragmentLoader.destroy(),this.keyLoader&&this.keyLoader.destroy(),this.decrypter&&this.decrypter.destroy(),this.hls=this.log=this.warn=this.decrypter=this.keyLoader=this.fragmentLoader=this.fragmentTracker=null,super.onHandlerDestroyed()}loadFragment(e,t,r){this.startFragRequested=!0,this._loadFragForPlayback(e,t,r)}_loadFragForPlayback(e,t,r){let i=e=>{let t=e.frag;if(this.fragContextChanged(t)){this.warn(`${t.type} sn: ${t.sn}${e.part?" part: "+e.part.index:""} of ${this.fragInfo(t,!1,e.part)}) was dropped during download.`),this.fragmentTracker.removeFragment(t);return}t.stats.chunkCount++,this._handleFragmentLoadProgress(e)};this._doFragLoad(e,t,r,i).then(e=>{if(!e)return;let t=this.state,r=e.frag;if(this.fragContextChanged(r)){t!==rD&&(this.fragCurrent||t!==rP)||(this.fragmentTracker.removeFragment(r),this.state=rk);return}"payload"in e&&(this.log(`Loaded ${r.type} sn: ${r.sn} of ${this.playlistLabel()} ${r.level}`),this.hls.trigger(o.FRAG_LOADED,e)),this._handleFragmentLoadComplete(e)}).catch(t=>{this.state!==rI&&this.state!==rM&&(this.warn(`Frag error: ${(null==t?void 0:t.message)||t}`),this.resetFragmentLoading(e))})}clearTrackerIfNeeded(e){var t;let{fragmentTracker:r}=this;if(r.getState(e)===ts){let t=e.type,i=this.getFwdBufferInfo(this.mediaBuffer,t),n=Math.max(e.duration,i?i.len:this.config.maxBufferLength),s=this.backtrackFragment;(1==(s?e.sn-s.sn:0)||this.reduceMaxBufferLength(n,e.duration))&&r.removeFragment(e)}else(null==(t=this.mediaBuffer)?void 0:t.buffered.length)===0?r.removeAllFragments():r.hasParts(e.type)&&(r.detectPartialFragments({frag:e,part:null,stats:e.stats,id:e.type}),r.getState(e)===ta&&r.removeFragment(e))}checkLiveUpdate(e){if(e.updated&&!e.live){let t=e.fragments[e.fragments.length-1];this.fragmentTracker.detectPartialFragments({frag:t,part:null,stats:t.stats,id:t.type})}e.fragments[0]||(e.deltaUpdateFailed=!0)}waitForLive(e){let t=e.details;return(null==t?void 0:t.live)&&"EVENT"!==t.type&&(this.levelLastLoaded!==e||t.expired)}flushMainBuffer(e,t,r=null){e-t&&this.hls.trigger(o.BUFFER_FLUSHING,{startOffset:e,endOffset:t,type:r})}_loadInitSegment(e,t){this._doFragLoad(e,t).then(e=>{let t=null==e?void 0:e.frag;if(!t||this.fragContextChanged(t)||!this.levels)throw Error("init load aborted");return e}).then(e=>{let{hls:t}=this,{frag:r,payload:i}=e,n=r.decryptdata;if(i&&i.byteLength>0&&null!=n&&n.key&&n.iv&&tP(n.method)){let l=self.performance.now();
2447return this.decrypter.decrypt(new Uint8Array(i),n.key.buffer,n.iv.buffer,tF(n.method)).catch(e=>{throw t.trigger(o.ERROR,{type:s.MEDIA_ERROR,details:a.FRAG_DECRYPT_ERROR,fatal:!1,error:e,reason:e.message,frag:r}),e}).then(i=>{let n=self.performance.now();return t.trigger(o.FRAG_DECRYPTED,{frag:r,payload:i,stats:{tstart:l,tdecrypt:n}}),e.payload=i,this.completeInitSegmentLoad(e)})}return this.completeInitSegmentLoad(e)}).catch(t=>{this.state!==rI&&this.state!==rM&&(this.warn(t),this.resetFragmentLoading(e))})}completeInitSegmentLoad(e){let{levels:t}=this;if(!t)throw Error("init load aborted, missing levels");let r=e.frag.stats;this.state!==rI&&(this.state=rk),e.frag.data=new Uint8Array(e.payload),r.parsing.start=r.buffering.start=self.performance.now(),r.parsing.end=r.buffering.end=self.performance.now(),this.tick()}unhandledEncryptionError(e,t){var r,i;let n=e.tracks;if(n&&!t.encrypted&&(null!=(r=n.audio)&&r.encrypted||null!=(i=n.video)&&i.encrypted)&&(!this.config.emeEnabled||!this.keyLoader.emeController)){let e=this.media,r=Error(`Encrypted track with no key in ${this.fragInfo(t)} (media ${e?"attached mediaKeys: "+e.mediaKeys:"detached"})`);return this.warn(r.message),!!e&&!e.mediaKeys&&(this.hls.trigger(o.ERROR,{type:s.KEY_SYSTEM_ERROR,details:a.KEY_SYSTEM_NO_KEYS,fatal:!1,error:r,frag:t}),this.resetTransmuxer(),!0)}return!1}fragContextChanged(e){let{fragCurrent:t}=this;return!e||!t||e.sn!==t.sn||e.level!==t.level}fragBufferedComplete(e,t){let r=this.mediaBuffer?this.mediaBuffer:this.media;if(this.log(`Buffered ${e.type} sn: ${e.sn}${t?" part: "+t.index:""} of ${this.fragInfo(e,!1,t)} > buffer:${r?rR(tx.getBuffered(r)):"(detached)"})`),J(e)){var i;if(e.type!==I){let t=e.elementaryStreams;if(!Object.keys(t).some(e=>!!t[e])){this.state=rk;return}}let t=null==(i=this.levels)?void 0:i[e.level];null!=t&&t.fragmentError&&(this.log(`Resetting level fragment error count of ${t.fragmentError} on frag buffered`),t.fragmentError=0)}this.state=rk}_handleFragmentLoadComplete(e){let{transmuxer:t}=this;if(!t)return;let{frag:r,part:i,partsLoaded:n}=e,s=!n||0===n.length||n.some(e=>!e),a=new t_(r.level,r.sn,r.stats.chunkCount+1,0,i?i.index:-1,!s);t.flush(a)}_handleFragmentLoadProgress(e){}_doFragLoad(e,t,i=null,n){var s,a;let l;this.fragCurrent=e;let u=t.details;if(!this.levels||!u)throw Error(`frag load aborted, missing level${u?"":" detail"}s`);let c=null;if(e.encrypted&&!(null!=(s=e.decryptdata)&&s.key)){if(this.log(`Loading key for ${e.sn} of [${u.startSN}-${u.endSN}], ${this.playlistLabel()} ${e.level}`),this.state=rC,this.fragCurrent=e,c=this.keyLoader.load(e).then(e=>{if(!this.fragContextChanged(e.frag))return this.hls.trigger(o.KEY_LOADED,e),this.state===rC&&(this.state=rk),e}),this.hls.trigger(o.KEY_LOADING,{frag:e}),null===this.fragCurrent)return this.log("context changed in KEY_LOADING"),Promise.resolve(null)}else!e.encrypted&&(c=this.keyLoader.loadClear(e,u.encryptedFragments,this.startFragRequested))&&this.log("[eme] blocking frag load until media-keys acquired");let d=this.fragPrevious;if(J(e)&&(!d||e.sn!==d.sn)){let r=this.shouldLoadParts(t.details,e.end);r!==this.loadingParts&&(this.log(`LL-Part loading ${r?"ON":"OFF"} loading sn ${null==d?void 0:d.sn}->${e.sn}`),this.loadingParts=r)}if(i=Math.max(e.start,i||0),this.loadingParts&&J(e)){let r=u.partList;if(r&&n){i>u.fragmentEnd&&u.fragmentHint&&(e=u.fragmentHint);let s=this.getNextPart(r,e,i);if(s>-1){let a,l=r[s];return(e=this.fragCurrent=l.fragment,this.log(`Loading ${e.type} sn: ${e.sn} part: ${l.index} (${s}/${r.length-1}) of ${this.fragInfo(e,!1,l)}) cc: ${e.cc} [${u.startSN}-${u.endSN}], target: ${parseFloat(i.toFixed(3))}`),this.nextLoadPosition=l.start+l.duration,this.state=rD,a=c?c.then(r=>!r||this.fragContextChanged(r.frag)?null:this.doFragPartsLoad(e,l,t,n)).catch(e=>this.handleFragLoadError(e)):this.doFragPartsLoad(e,l,t,n).catch(e=>this.handleFragLoadError(e)),this.hls.trigger(o.FRAG_LOADING,{frag:e,part:l,targetBufferTime:i}),null===this.fragCurrent)?Promise.reject(Error("frag load aborted, context changed in FRAG_LOADING parts")):a}if(!e.url||this.loadedEndOfParts(r,i))return Promise.resolve(null)}}if(J(e)&&this.loadingParts)this.log(`LL-Part loading OFF after next part miss @${i.toFixed(2)} Check buffer at sn: ${e.sn} loaded parts: ${null==(a=u.partList)?void 0:a.filter(e=>e.loaded).map(e=>`[${e.start}-${e.end}]`)}`),this.loadingParts=!1;else if(!e.url)return Promise.resolve(null);this.log(`Loading ${e.type} sn: ${e.sn} of ${this.fragInfo(e,!1)}) cc: ${e.cc} ${"["+u.startSN+"-"+u.endSN+"]"}, target: ${parseFloat(i.toFixed(3))}`),r(e.sn)&&!this.bitrateTest&&(this.nextLoadPosition=e.start+e.duration),this.state=rD;let h=this.config.progressive&&e.type!==I;return(l=h&&c?c.then(t=>!t||this.fragContextChanged(t.frag)?null:this.fragmentLoader.load(e,n)).catch(e=>this.handleFragLoadError(e)):Promise.all([this.fragmentLoader.load(e,h?n:void 0),c]).then(([e])=>(!h&&n&&n(e),e)).catch(e=>this.handleFragLoadError(e)),this.hls.trigger(o.FRAG_LOADING,{frag:e,targetBufferTime:i}),null===this.fragCurrent)?Promise.reject(Error("frag load aborted, context changed in FRAG_LOADING")):l}doFragPartsLoad(e,t,r,i){return new Promise((n,s)=>{var a;let l=[],u=null==(a=r.details)?void 0:a.partList,c=t=>{this.fragmentLoader.loadPart(e,t,i).then(i=>{l[t.index]=i;let s=i.part;this.hls.trigger(o.FRAG_LOADED,i);let a=rm(r.details,e.sn,t.index+1)||ry(u,e.sn,t.index+1);if(!a)return n({frag:e,part:s,partsLoaded:l});c(a)}).catch(s)};c(t)})}handleFragLoadError(e){if("data"in e){let t=e.data;t.frag&&t.details===a.INTERNAL_ABORTED?this.handleFragLoadAborted(t.frag,t.part):t.frag&&t.type===s.KEY_SYSTEM_ERROR?(t.frag.abortRequests(),this.resetStartWhenNotLoaded(),this.resetFragmentLoading(t.frag)):this.hls.trigger(o.ERROR,t)}else this.hls.trigger(o.ERROR,{type:s.OTHER_ERROR,details:a.INTERNAL_EXCEPTION,err:e,error:e,fatal:!0});return null}_handleTransmuxerFlush(e){let t=this.getCurrentContext(e);if(!t||this.state!==rP){this.fragCurrent||this.state===rI||this.state===rM||(this.state=rk);return}let{frag:r,part:i,level:n}=t,s=self.performance.now();r.stats.parsing.end=s,i&&(i.stats.parsing.end=s);let a=this.getLevelDetails(),o=a&&r.sn>a.endSN||this.shouldLoadParts(a,r.end);o!==this.loadingParts&&(this.log(`LL-Part loading ${o?"ON":"OFF"} after parsing segment ending @${r.end.toFixed(2)}`),this.loadingParts=o),this.updateLevelTiming(r,i,n,e.partial)}shouldLoadParts(e,t){if(this.config.lowLatencyMode){if(!e)return this.loadingParts;if(e.partList){var r,i;let n=e.partList[0];if(n.fragment.type===I)return!1;if(t>=n.end+((null==(r=e.fragmentHint)?void 0:r.duration)||0)&&(this.hls.hasEnoughToStart?(null==(i=this.media)?void 0:i.currentTime)||this.lastCurrentTime:this.getLoadPosition())>n.start-n.fragment.duration)return!0}}return!1}getCurrentContext(e){let{levels:t,fragCurrent:r}=this,{level:i,sn:n,part:s}=e;if(!(null!=t&&t[i]))return this.warn(`Levels object was unset while buffering fragment ${n} of ${this.playlistLabel()} ${i}. The current chunk will not be buffered.`),null;let a=t[i],o=a.details,l=s>-1?rm(o,n,s):null,u=l?l.fragment:rg(o,n,r);return u?(r&&r!==u&&(u.stats=r.stats),{frag:u,part:l,level:a}):null}bufferFragmentData(e,t,r,i,n){if(this.state!==rP)return;let{data1:s,data2:a}=e,l=s;
2447if(a&&(l=em(s,a)),!l.length)return;let u=this.initPTS[t.cc],c=u?-u.baseTime/u.timescale:void 0,d={type:e.type,frag:t,part:r,chunkMeta:i,offset:c,parent:t.type,data:l};if(this.hls.trigger(o.BUFFER_APPENDING,d),e.dropped&&e.independent&&!r){if(n)return;this.flushBufferGap(t)}}flushBufferGap(e){let t=this.media;if(!t)return;if(!tx.isBuffered(t,t.currentTime))return void this.flushMainBuffer(0,e.start);let r=t.currentTime,i=tx.bufferInfo(t,r,0),n=e.duration,s=Math.min(2*this.config.maxFragLookUpTolerance,.25*n),a=Math.max(Math.min(e.start-s,i.end-s),r+s);e.start-a>s&&this.flushMainBuffer(a,e.start)}getFwdBufferInfo(e,t){var i;let n=this.getLoadPosition();if(!r(n))return null;let s=this.lastCurrentTime>n||null!=(i=this.media)&&i.paused?0:this.config.maxBufferHole;return this.getFwdBufferInfoAtPos(e,n,t,s)}getFwdBufferInfoAtPos(e,t,r,i){let n=tx.bufferInfo(e,t,i);if(0===n.len&&void 0!==n.nextStart){let s=this.fragmentTracker.getBufferedFrag(t,r);if(s&&(n.nextStart<=s.end||s.gap)){let r=Math.max(Math.min(n.nextStart,s.end)-t,i);return tx.bufferInfo(e,t,r)}}return n}getMaxBufferLength(e){let{config:t}=this;return Math.min(e?Math.max(8*t.maxBufferSize/e,t.maxBufferLength):t.maxBufferLength,t.maxMaxBufferLength)}exceedsMaxBuffer(e,t,r){let i=e.nextStart;if(i&&r.start>i){let i=e.buffered;if(i){let n=e.len,s=e.bufferedIndex;for(let e=i.length-1;e>s;e--)i[e].start<r.start&&(n+=i[e].end-i[e].start);return n>=t}}return!1}reduceMaxBufferLength(e,t){let r=this.config,i=Math.max(Math.min(e-t,r.maxBufferLength),t),n=Math.max(e-3*t,r.maxMaxBufferLength/2,i);return n>=i&&(r.maxMaxBufferLength=n,this.warn(`Reduce max buffer length to ${n}s`),!0)}getAppendedFrag(e,t=A){let r=this.fragmentTracker?this.fragmentTracker.getAppendedFrag(e,t):null;return r&&"fragment"in r?r.fragment:r}getNextFragment(e,t){let r=t.fragments,i=r.length;if(!i)return null;let{config:n}=this,s=t.fragmentStart,a=n.lowLatencyMode&&!!t.partList,o=null;if(t.live){let r=n.initialLiveManifestSize;if(i<r)return this.warn(`Not enough fragments to start playback (have: ${i}, need: ${r})`),null;if(!t.PTSKnown&&!this.startFragRequested&&-1===this.startPosition||e<s){var l;let r,i;a&&!this.loadingParts&&(this.log("LL-Part loading ON for initial live fragment"),this.loadingParts=!0),o=this.getInitialLiveFragment(t);let n=this.config.startPosition,u=this.hls.startPosition,c=this.hls.liveSyncPosition,d=(null==(l=o)?void 0:l.start)||0;-1!==u&&u>=s?(r=u,i=u===n?"config":"next load start"):null!==c?(r=c,i="live edge"):(r=e,i="buffer pos"),r<d&&(r=d,i="live frag start"),r<s&&(r=s,i="playlist start"),(this.startPosition!=r||this.nextLoadPosition!=r)&&(this.log(`Setting startPosition to ${r.toFixed(3)} ${-1===u?"":`(from ${n}) `}based on ${i}. live edge: ${c} live frag start: ${d.toFixed(3)} playlist start: ${s.toFixed(3)} buffer pos: ${e}`),this.startPosition=this.nextLoadPosition=r)}}else e<=s&&(o=r[0]);if(!o){let r=this.loadingParts?t.partEnd:t.fragmentEnd;o=this.getFragmentAtPosition(e,r,t)}let u=this.filterReplacedPrimary(o,t);if(!u&&o){let e=o.sn-t.startSN;u=this.filterReplacedPrimary(r[e+1]||null,t)}return this.mapToInitFragWhenRequired(u)}isLoopLoading(e,t){if(this.nextLoadPosition<=t)return!1;let r=this.fragmentTracker.getState(e);return"OK"===r||r===ta&&!!e.gap}getNextFragmentLoopLoading(e,t,r,i,n){let s=null;if(e.gap&&(s=this.getNextFragment(this.nextLoadPosition,t))&&!s.gap&&r.nextStart){let e=this.getFwdBufferInfoAtPos(this.mediaBuffer?this.mediaBuffer:this.media,r.nextStart,i,0);if(null!==e&&r.len+e.len>=n){let e=s.sn;return this.loopSn!==e&&(this.log(`buffer full after gaps in "${i}" playlist starting at sn: ${e}`),this.loopSn=e),null}}return this.loopSn=void 0,s}get primaryPrefetch(){if(rB(this.config)){var e;if(null==(e=this.hls.interstitialsManager)||null==(e=e.playingItem)?void 0:e.event)return!0}return!1}filterReplacedPrimary(e,t){if(!e)return e;if(rB(this.config)&&e.type!==I){let r=this.hls.interstitialsManager,i=null==r?void 0:r.bufferingItem;if(i){let r=i.event;if(r){if(r.appendInPlace||Math.abs(e.start-i.start)>1||0===i.start)return null}else if(e.end<=i.start&&(null==t?void 0:t.live)===!1||e.start>i.end&&i.nextEvent&&(i.nextEvent.appendInPlace||e.start-i.end>1))return null}let n=null==r?void 0:r.playerQueue;if(n)for(let t=n.length;t--;){let r=n[t].interstitial;if(r.appendInPlace&&e.start>=r.startTime&&e.end<=r.resumeTime)return null}}return e}mapToInitFragWhenRequired(e){return null==e||!e.initSegment||e.initSegment.data||this.bitrateTest?e:e.initSegment}getNextPart(e,t,r){let i=-1,n=!1,s=!0;for(let a=0,o=e.length;a<o;a++){let o=e[a];if(s=s&&!o.independent,i>-1&&r<o.start)break;let l=o.loaded;l?i=-1:(n||(o.independent||s)&&o.fragment===t)&&(o.fragment!==t&&this.warn(`Need buffer at ${r} but next unloaded part starts at ${o.start}`),i=a),n=l}return i}loadedEndOfParts(e,t){let r;for(let i=e.length;i--&&(r=e[i]).loaded;)if(t>r.start)return!0;return!1}getInitialLiveFragment(e){let t=e.fragments,i=this.fragPrevious,n=null;if(i){if(e.hasProgramDateTime&&(n=function(e,t,i){if(null===t||!Array.isArray(e)||!e.length||!r(t)||t<(e[0].programDateTime||0)||t>=(e[e.length-1].endProgramDateTime||0))return null;for(let r=0;r<e.length;++r){let n=e[r];if(function(e,t,r){let i=1e3*Math.min(t,r.duration+(r.deltaPTS?r.deltaPTS:0));return(r.endProgramDateTime||0)-i>e}(t,i,n))return n}return null}(t,i.endProgramDateTime,this.config.maxFragLookUpTolerance))&&this.log(`Live playlist, switching playlist, load frag with same PDT: ${i.programDateTime}`),!n){let r=i.sn+1;if(r>=e.startSN&&r<=e.endSN){let s=t[r-e.startSN];i.cc===s.cc&&(n=s,this.log(`Live playlist, switching playlist, load frag with next SN: ${n.sn}`))}!n&&(n=e4(e,i.cc,i.end))&&this.log(`Live playlist, switching playlist, load frag with same CC: ${n.sn}`)}}else{let t=this.hls.liveSyncPosition;null!==t&&(n=this.getFragmentAtPosition(t,this.bitrateTest?e.fragmentEnd:e.edge,e))}return n}getFragmentAtPosition(e,t,r){let i,{config:n}=this,{fragPrevious:s}=this,{fragments:a,endSN:o}=r,{fragmentHint:l}=r,{maxFragLookUpTolerance:u}=n,c=r.partList,d=!!(this.loadingParts&&null!=c&&c.length&&l);if(d&&!this.bitrateTest&&c[c.length-1].fragment.sn===l.sn&&(a=a.concat(l),o=l.sn),e<t){var h;let r=e<this.lastCurrentTime||e>t-u||null!=(h=this.media)&&h.paused||!this.startFragRequested?0:u;i=e2(s,a,e,r)}else i=a[a.length-1];if(i){let e=i.sn-r.startSN,t=this.fragmentTracker.getState(i);if(("OK"===t||t===ta&&i.gap)&&(s=i),s&&i.sn===s.sn&&(!d||c[0].fragment.sn>i.sn||!r.live)&&i.level===s.level){let t=a[e+1];i=i.sn<o&&"OK"!==this.fragmentTracker.getState(t)?t:null}}return i}alignPlaylists(e,t,i){let n=e.fragments.length;if(!n)return this.warn("No fragments in live playlist"),0;let s=e.fragmentStart,a=!t,o=e.alignedSliding&&r(s);if(a||!o&&!s){i&&(rx(e,i),e.alignedSliding||rT(e,i),e.alignedSliding||e.skippedSegments||rh(i,e,!1));let r=e.fragmentStart;return this.log(`Live playlist sliding: ${r.toFixed(2)} start-sn: ${t?t.startSN:"na"}->${e.startSN} fragments: ${n}`),r}return s}waitForCdnTuneIn(e){return e.live&&e.canBlockReload&&e.partTarget&&e.tuneInGoal>Math.max(e.partHoldBack,3*e.partTarget)}setStartPosition(e,t){let i=this.startPosition;i<t&&(i=-1);let n=this.timelineOffset;if(-1===i){let s=null!==this.startTimeOffset,a=s?this.startTimeOffset:e.startTimeOffset;null!==a&&r(a)?(i=t+a,a<0&&(i+=e.edge),i=Math.min(Math.max(t,i),t+e.totalduration),this.log(`Setting startPosition to ${i} for start time offset ${a} found in ${s?"multivariant":"media"} playlist`),this.startPosition=i):e.live?(i=this.hls.liveSyncPosition||t,this.log(`Setting startPosition to -1 to start at live edge ${i}`),this.startPosition=-1):(this.log("setting startPosition to 0 by default"),this.startPosition=i=0),this.lastCurrentTime=i+n}this.nextLoadPosition=i+n}getLoadPosition(){var e;let{media:t}=this,r=0;return null!=(e=this.hls)&&e.hasEnoughToStart&&t?r=t.currentTime:this.nextLoadPosition>=0&&(r=this.nextLoadPosition),r}handleFragLoadAborted(e,t){this.transmuxer&&e.type===this.playlistType&&J(e)&&e.stats.aborted&&(this.log(`Fragment ${e.sn}${t?" part "+t.index:""} of ${this.playlistLabel()} ${e.level} was aborted`),this.resetFragmentLoading(e))}resetFragmentLoading(e){this.fragCurrent&&(this.fragContextChanged(e)||this.state===rL)||(this.state=rk)}onFragmentOrKeyLoadError(e,t){var r,i,n;if(t.chunkMeta&&!t.frag){let e=this.getCurrentContext(t.chunkMeta);e&&(t.frag=e.frag)}let s=t.frag;if(!s||s.type!==e||!this.levels)return;if(this.fragContextChanged(s))return void this.warn(`Frag load error must match current frag to retry ${s.url} > ${null==(i=this.fragCurrent)?void 0:i.url}`);let o=t.details===a.FRAG_GAP;o&&this.fragmentTracker.fragBuffered(s,!0);let l=t.errorAction;if(!l){this.state=rM;return}let{action:u,flags:c,retryCount:d=0,retryConfig:h}=l,f=!!h,p=f&&5===u,g=f&&!l.resolved&&1===c,m=null==(r=this.hls.latestLevelDetails)?void 0:r.live;if(!p&&g&&J(s)&&!s.endList&&m&&!e6(t))this.resetFragmentErrors(e),this.treatAsGap(s),l.resolved=!0;else if((p||g)&&d<h.maxNumRetry){let r=tr(null==(n=t.response)?void 0:n.code),i=e9(h,d);if(this.resetStartWhenNotLoaded(),this.retryDate=self.performance.now()+i,this.state=rL,l.resolved=!0,r){this.log("Waiting for connection (offline)"),this.retryDate=1/0,t.reason="offline";return}this.warn(`Fragment ${s.sn} of ${e} ${s.level} errored with ${t.details}, retrying loading ${d+1}/${h.maxNumRetry} in ${i}ms`)}else if(h){if(this.resetFragmentErrors(e),!(d<h.maxNumRetry))return void this.warn(`${t.details} reached or exceeded max retry (${d})`);o||3===u||(l.resolved=!0)}else 2===u?this.state=r$:this.state=rM;this.tickImmediate()}checkRetryDate(){let e=self.performance.now(),t=this.retryDate,r=t===1/0;(!t||e>=t||r&&!tr(0))&&(r&&this.log("Connection restored (online)"),this.resetStartWhenNotLoaded(),this.state=rk)}reduceLengthAndFlushBuffer(e){if(this.state===rP||this.state===rF){let t=e.frag,r=e.parent,i=this.getFwdBufferInfo(this.mediaBuffer,r),n=i&&i.len>.5;n&&this.reduceMaxBufferLength(i.len,(null==t?void 0:t.duration)||10);let s=!n;return s&&this.warn(`Buffer full error while media.currentTime (${this.getLoadPosition()}) is not buffered, flush ${r} buffer`),t&&(this.fragmentTracker.removeFragment(t),this.nextLoadPosition=t.start),this.resetLoadingState(),s}return!1}resetFragmentErrors(e){e===R&&(this.fragCurrent=null),this.hls.hasEnoughToStart||(this.startFragRequested=!1),this.state!==rI&&(this.state=rk)}afterBufferFlushed(e,t,r){if(!e)return;let i=tx.getBuffered(e);this.fragmentTracker.detectEvictedFragments(t,i,r),this.state===rN&&this.resetLoadingState()}
2447resetLoadingState(){this.log("Reset loading state"),this.fragCurrent=null,this.fragPrevious=null,this.state!==rI&&(this.state=rk)}resetStartWhenNotLoaded(){if(!this.hls.hasEnoughToStart){this.startFragRequested=!1;let e=this.levelLastLoaded,t=e?e.details:null;null!=t&&t.live?(this.log("resetting startPosition for live start"),this.startPosition=-1,this.setStartPosition(t,t.fragmentStart),this.resetLoadingState()):this.nextLoadPosition=this.startPosition}}resetWhenMissingContext(e){this.log(`Loading context changed while buffering sn ${e.sn} of ${this.playlistLabel()} ${-1===e.level?"<removed>":e.level}. This chunk will not be buffered.`),this.removeUnbufferedFrags(),this.resetStartWhenNotLoaded(),this.resetLoadingState()}removeUnbufferedFrags(e=0){this.fragmentTracker.removeFragmentsInRange(e,1/0,this.playlistType,!1,!0)}updateLevelTiming(e,t,r,i){let n=r.details;if(!n)return void this.warn("level.details undefined");if(!Object.keys(e.elementaryStreams).reduce((t,s)=>{let a=e.elementaryStreams[s];if(a){let l=a.endPTS-a.startPTS;if(l<=0)return this.warn(`Could not parse fragment ${e.sn} ${s} duration reliably (${l})`),t||!1;let u=i?0:rc(n,e,a.startPTS,a.endPTS,a.startDTS,a.endDTS,this);return this.hls.trigger(o.LEVEL_PTS_UPDATED,{details:n,level:r,drift:u,type:s,frag:e,start:a.startPTS,end:a.endPTS}),!0}return t},!1)){var l;let t=(null==(l=this.transmuxer)?void 0:l.error)===null;if((0===r.fragmentError||t&&(r.fragmentError<2||e.endList))&&this.treatAsGap(e,r),t){let t=Error(`Found no media in fragment ${e.sn} of ${this.playlistLabel()} ${e.level} resetting transmuxer to fallback to playlist timing`);if(this.warn(t.message),this.hls.trigger(o.ERROR,{type:s.MEDIA_ERROR,details:a.FRAG_PARSING_ERROR,fatal:!1,error:t,frag:e,reason:`Found no media in msn ${e.sn} of ${this.playlistLabel()} "${r.url}"`}),!this.hls)return;this.resetTransmuxer()}}this.state=rF,this.log(`Parsed ${e.type} sn: ${e.sn}${t?" part: "+t.index:""} of ${this.fragInfo(e,!1,t)})`),this.hls.trigger(o.FRAG_PARSED,{frag:e,part:t})}playlistLabel(){return this.playlistType===A?"level":"track"}fragInfo(e,t=!0,r){var i,n;return`${this.playlistLabel()} ${e.level} (${r?"part":"frag"}:[${(null!=(i=t&&!r?e.startPTS:(r||e).start)?i:NaN).toFixed(3)}-${(null!=(n=t&&!r?e.endPTS:(r||e).end)?n:NaN).toFixed(3)}]${r&&"main"===e.type?"INDEPENDENT="+(r.independent?"YES":"NO"):""}`}treatAsGap(e,t){t&&t.fragmentError++,e.gap=!0,this.fragmentTracker.removeFragment(e),this.fragmentTracker.fragBuffered(e,!0)}resetTransmuxer(){var e;null==(e=this.transmuxer)||e.reset()}recoverWorkerError(e){"demuxerWorker"===e.event&&(this.fragmentTracker.removeAllFragments(),this.transmuxer&&(this.transmuxer.destroy(),this.transmuxer=null),this.resetStartWhenNotLoaded(),this.resetLoadingState())}set state(e){let t=this._state;t!==e&&(this._state=e,this.log(`${t}->${e}`))}get state(){return this._state}}function rB(e){return!!e.interstitialsController&&!1!==e.enableInterstitialPlayback}class rV{constructor(){this.chunks=[],this.dataLength=0}push(e){this.chunks.push(e),this.dataLength+=e.length}flush(){let e,{chunks:t,dataLength:r}=this;return t.length?(e=1===t.length?t[0]:function(e,t){let r=new Uint8Array(t),i=0;for(let t=0;t<e.length;t++){let n=e[t];r.set(n,i),i+=n.length}return r}(t,r),this.reset(),e):new Uint8Array(0)}reset(){this.chunks.length=0,this.dataLength=0}}var rG={exports:{}},rq=(E||(E=1,!function(e){var t=Object.prototype.hasOwnProperty,r="~";function i(){}function n(e,t,r){this.fn=e,this.context=t,this.once=r||!1}function s(e,t,i,s,a){if("function"!=typeof i)throw TypeError("The listener must be a function");var o=new n(i,s||e,a),l=r?r+t:t;return e._events[l]?e._events[l].fn?e._events[l]=[e._events[l],o]:e._events[l].push(o):(e._events[l]=o,e._eventsCount++),e}function a(e,t){0==--e._eventsCount?e._events=new i:delete e._events[t]}function o(){this._events=new i,this._eventsCount=0}Object.create&&(i.prototype=Object.create(null),new i().__proto__||(r=!1)),o.prototype.eventNames=function(){var e,i,n=[];if(0===this._eventsCount)return n;for(i in e=this._events)t.call(e,i)&&n.push(r?i.slice(1):i);return Object.getOwnPropertySymbols?n.concat(Object.getOwnPropertySymbols(e)):n},o.prototype.listeners=function(e){var t=r?r+e:e,i=this._events[t];if(!i)return[];if(i.fn)return[i.fn];for(var n=0,s=i.length,a=Array(s);n<s;n++)a[n]=i[n].fn;return a},o.prototype.listenerCount=function(e){var t=r?r+e:e,i=this._events[t];return i?i.fn?1:i.length:0},o.prototype.emit=function(e,t,i,n,s,a){var o=r?r+e:e;if(!this._events[o])return!1;var l,u,c=this._events[o],d=arguments.length;
2447if(c.fn){switch(c.once&&this.removeListener(e,c.fn,void 0,!0),d){case 1:return c.fn.call(c.context),!0;case 2:return c.fn.call(c.context,t),!0;case 3:return c.fn.call(c.context,t,i),!0;case 4:return c.fn.call(c.context,t,i,n),!0;case 5:return c.fn.call(c.context,t,i,n,s),!0;case 6:return c.fn.call(c.context,t,i,n,s,a),!0}for(u=1,l=Array(d-1);u<d;u++)l[u-1]=arguments[u];c.fn.apply(c.context,l)}else{var h,f=c.length;for(u=0;u<f;u++)switch(c[u].once&&this.removeListener(e,c[u].fn,void 0,!0),d){case 1:c[u].fn.call(c[u].context);break;case 2:c[u].fn.call(c[u].context,t);break;case 3:c[u].fn.call(c[u].context,t,i);break;case 4:c[u].fn.call(c[u].context,t,i,n);break;default:if(!l)for(h=1,l=Array(d-1);h<d;h++)l[h-1]=arguments[h];c[u].fn.apply(c[u].context,l)}}return!0},o.prototype.on=function(e,t,r){return s(this,e,t,r,!1)},o.prototype.once=function(e,t,r){return s(this,e,t,r,!0)},o.prototype.removeListener=function(e,t,i,n){var s=r?r+e:e;if(!this._events[s])return this;if(!t)return a(this,s),this;var o=this._events[s];if(o.fn)o.fn!==t||n&&!o.once||i&&o.context!==i||a(this,s);else{for(var l=0,u=[],c=o.length;l<c;l++)(o[l].fn!==t||n&&!o[l].once||i&&o[l].context!==i)&&u.push(o[l]);u.length?this._events[s]=1===u.length?u[0]:u:a(this,s)}return this},o.prototype.removeAllListeners=function(e){var t;return e?(t=r?r+e:e,this._events[t]&&a(this,t)):(this._events=new i,this._eventsCount=0),this},o.prototype.off=o.prototype.removeListener,o.prototype.addListener=o.prototype.on,o.prefixed=r,o.EventEmitter=o,e.exports=o}(rG)),(p=rG.exports)&&p.__esModule&&Object.prototype.hasOwnProperty.call(p,"default"))?p.default:p;let rH="1.6.16",rz={};function rK(e,t){return t+10<=e.length&&51===e[t]&&68===e[t+1]&&73===e[t+2]&&e[t+3]<255&&e[t+4]<255&&e[t+6]<128&&e[t+7]<128&&e[t+8]<128&&e[t+9]<128||!1}function rW(e,t){return t+10<=e.length&&73===e[t]&&68===e[t+1]&&51===e[t+2]&&e[t+3]<255&&e[t+4]<255&&e[t+6]<128&&e[t+7]<128&&e[t+8]<128&&e[t+9]<128||!1}function rY(e,t){return(127&e[t])<<21|(127&e[t+1])<<14|(127&e[t+2])<<7|127&e[t+3]}function rQ(e,t){let r=t,i=0;for(;rW(e,t);)i+=10,i+=rY(e,t+6),rK(e,t+10)&&(i+=10),t+=i;if(i>0)return e.subarray(r,r+i)}function rX(e,t){return 255===e[t]&&(246&e[t+1])==240}function rJ(e,t){return 1&e[t+1]?7:9}function rZ(e,t){return(3&e[t+3])<<11|e[t+4]<<3|(224&e[t+5])>>>5}function r0(e,t){return t+1<e.length&&rX(e,t)}function r1(e,t,r,i,n){if(!e.samplerate){let l=function(e,t,r,i){let n=t[r+2],l=n>>2&15;if(l>12){let t=Error(`invalid ADTS sampling index:${l}`);e.emit(o.ERROR,o.ERROR,{type:s.MEDIA_ERROR,details:a.FRAG_PARSING_ERROR,fatal:!0,error:t,reason:t.message});return}let u=(n>>6&3)+1,c=t[r+3]>>6&3|(1&n)<<2,d="mp4a.40."+u,h=[96e3,88200,64e3,48e3,44100,32e3,24e3,22050,16e3,12e3,11025,8e3,7350][l],f=l;(5===u||29===u)&&(f-=3);let p=[u<<3|(14&f)>>1,(1&f)<<7|c<<3];return $.log(`manifest codec:${i}, parsed codec:${d}, channels:${c}, rate:${h} (ADTS object type:${u} sampling index:${l})`),{config:p,samplerate:h,channelCount:c,codec:d,parsedCodec:d,manifestCodec:i}}(t,r,i,n);l&&D(e,l)}}function r2(e,t,r,i,n){let s,a=i+n*(9216e4/e.samplerate),o=function(e,t){let r=rJ(e,t);if(t+r<=e.length){let i=rZ(e,t)-r;if(i>0)return{headerLength:r,frameLength:i}}}(t,r);if(o){let{frameLength:i,headerLength:n}=o,l=n+i,u=Math.max(0,r+l-t.length);u?(s=new Uint8Array(l-n)).set(t.subarray(r+n,t.length),0):s=t.subarray(r+n,r+l);let c={unit:s,pts:a};return u||e.samples.push(c),{sample:c,length:l,missing:u}}let l=t.length-r;return(s=new Uint8Array(l)).set(t.subarray(r,t.length),0),{sample:{unit:s,pts:a},length:l,missing:-1}}function r3(e,t=0,r=1/0){var i,n,s,a,o,l;let u,c,d,h,f,p;return i=e,n=t,s=r,a=Uint8Array,u=(o=i)instanceof ArrayBuffer?o:o.buffer,c=1,"BYTES_PER_ELEMENT"in a&&(c=a.BYTES_PER_ELEMENT),h=((d=(l=i)&&l.buffer instanceof ArrayBuffer&&void 0!==l.byteLength&&void 0!==l.byteOffset?i.byteOffset:0)+i.byteLength)/c,p=Math.floor(Math.min((f=Math.floor(Math.max(0,Math.min((d+n)/c,h))))+Math.max(s,0),h)),new a(u,f,p-f)}function r4(e){let t=0,r=[];for(;rW(e,t);){let i=rY(e,t+6);e[t+5]>>6&1&&(t+=10);let n=(t+=10)+i;for(;t+10<n;){let i=function(e){let t=String.fromCharCode(e[0],e[1],e[2],e[3]),r=rY(e,4);return{type:t,size:r,data:e.subarray(10,10+r)}}(e.subarray(t)),n=function(e){if("PRIV"===e.type){if(e.size<2)return;
2447let t=V(e.data,!0),r=new Uint8Array(e.data.subarray(t.length+1));return{key:e.type,info:t,data:r.buffer}}if("W"===e.type[0]){if("WXXX"===e.type){if(e.size<2)return;let t=1,r=V(e.data.subarray(t),!0);t+=r.length+1;let i=V(e.data.subarray(t));return{key:e.type,info:r,data:i}}let t=V(e.data);return{key:e.type,info:"",data:t}}if("APIC"===e.type)return function(e){let t,r={key:e.type,description:"",data:"",mimeType:null,pictureType:null};if(e.size<2)return;if(3!==e.data[0])return void console.log("Ignore frame with unrecognized character encoding");let i=e.data.subarray(1).indexOf(0);if(-1===i)return;let n=V(r3(e.data,1,i)),s=e.data[2+i],a=e.data.subarray(3+i).indexOf(0);if(-1===a)return;let o=V(r3(e.data,3+i,a));if("-->"===n)t=V(r3(e.data,4+i+a));else{var l;t=(l=e.data.subarray(4+i+a))instanceof ArrayBuffer?l:0==l.byteOffset&&l.byteLength==l.buffer.byteLength?l.buffer:new Uint8Array(l).buffer}return r.mimeType=n,r.pictureType=s,r.description=o,r.data=t,r}(e);if(e.size<2)return;if("TXXX"===e.type){let t=1,r=V(e.data.subarray(t),!0);t+=r.length+1;let i=V(e.data.subarray(t));return{key:e.type,info:r,data:i}}let t=V(e.data.subarray(1));return{key:e.type,info:"",data:t}}(i);n&&r.push(n),t+=i.size+10}rK(e,t)&&(t+=10)}return r}function r5(e){return e&&"PRIV"===e.key&&"com.apple.streaming.transportStreamTimestamp"===e.info}function r8(e){let t=r4(e);for(let e=0;e<t.length;e++){let r=t[e];if(r5(r))return function(e){if(8===e.data.byteLength){let t=new Uint8Array(e.data),r=1&t[3],i=(t[4]<<23)+(t[5]<<15)+(t[6]<<7)+t[7];return i/=45,r&&(i+=47721858.84),Math.round(i)}}(r)}}let r6=((g={}).audioId3="org.id3",g.dateRange="com.apple.quicktime.HLS",g.emsg="https://aomedia.org/emsg/ID3",g.misbklv="urn:misb:KLV:bin:1910.1",g);function r7(e="",t=9e4){return{type:e,id:-1,pid:-1,inputTimeScale:t,sequenceNumber:-1,samples:[],dropped:0}}class r9{constructor(){this._audioTrack=void 0,this._id3Track=void 0,this.frameIndex=0,this.cachedData=null,this.basePTS=null,this.initPTS=null,this.lastPTS=null}resetInitSegment(e,t,r,i){this._id3Track={type:"id3",id:3,pid:-1,inputTimeScale:9e4,sequenceNumber:0,samples:[],dropped:0}}resetTimeStamp(e){this.initPTS=e,this.resetContiguity()}resetContiguity(){this.basePTS=null,this.lastPTS=null,this.frameIndex=0}canParse(e,t){return!1}appendFrame(e,t,r){}demux(e,t){let i;this.cachedData&&(e=em(this.cachedData,e),this.cachedData=null);let n=rQ(e,0),s=n?n.length:0,a=this._audioTrack,o=this._id3Track,l=n?r8(n):void 0,u=e.length;for((null===this.basePTS||0===this.frameIndex&&r(l))&&(this.basePTS=ie(l,t,this.initPTS),this.lastPTS=this.basePTS),null===this.lastPTS&&(this.lastPTS=this.basePTS),n&&n.length>0&&o.samples.push({pts:this.lastPTS,dts:this.lastPTS,data:n,type:r6.audioId3,duration:1/0});s<u;){if(this.canParse(e,s)){let t=this.appendFrame(a,e,s);t?(this.frameIndex++,this.lastPTS=t.sample.pts,s+=t.length,i=s):s=u}else{var c,d;rW(c=e,d=s)&&rY(c,d+6)+10<=c.length-d?(n=rQ(e,s),o.samples.push({pts:this.lastPTS,dts:this.lastPTS,data:n,type:r6.audioId3,duration:1/0}),s+=n.length,i=s):s++}if(s===u&&i!==u){let t=e.slice(i);this.cachedData?this.cachedData=em(this.cachedData,t):this.cachedData=t}}return{audioTrack:a,videoTrack:r7(),id3Track:o,textTrack:r7()}}demuxSampleAes(e,t,r){return Promise.reject(Error(`[${this}] This demuxer does not support Sample-AES decryption`))}flush(e){let t=this.cachedData;return t&&(this.cachedData=null,this.demux(t,0)),{audioTrack:this._audioTrack,videoTrack:r7(),id3Track:this._id3Track,textTrack:r7()}}destroy(){this.cachedData=null,this._audioTrack=this._id3Track=void 0}}let ie=(e,t,i)=>r(e)?90*e:9e4*t+(i?9e4*i.baseTime/i.timescale:0),it=null,ir=[32,64,96,128,160,192,224,256,288,320,352,384,416,448,32,48,56,64,80,96,112,128,160,192,224,256,320,384,32,40,48,56,64,80,96,112,128,160,192,224,256,320,32,48,56,64,80,96,112,128,144,160,176,192,224,256,8,16,24,32,40,48,56,64,80,96,112,128,144,160],ii=[44100,48e3,32e3,22050,24e3,16e3,11025,12e3,8e3],is=[[0,72,144,12],[0,0,0,0],[0,72,144,12],[0,144,144,12]],ia=[0,1,1,4];function io(e,t,r,i,n){if(r+24>t.length)return;let s=il(t,r);if(s&&r+s.frameLength<=t.length){let a=i+n*(9e4*s.samplesPerFrame/s.sampleRate),o={unit:t.subarray(r,r+s.frameLength),pts:a,dts:a};return e.config=[],e.channelCount=s.channelCount,e.samplerate=s.sampleRate,e.samples.push(o),{sample:o,length:s.frameLength,missing:0}}}function il(e,t){let r=e[t+1]>>3&3,i=e[t+1]>>1&3,n=e[t+2]>>4&15,s=e[t+2]>>2&3;if(1!==r&&0!==n&&15!==n&&3!==s){let a=e[t+2]>>1&1,o=e[t+3]>>6,l=1e3*ir[14*(3===r?3-i:3===i?3:4)+n-1],u=ii[3*(3===r?0:2===r?1:2)+s],c=is[r][i],d=ia[i],h=Math.floor(c*l/u+a)*d;if(null===it){let e=(navigator.userAgent||"").match(/Chrome\/(\d+)/i);it=e?parseInt(e[1]):0}return it&&it<=87&&2===i&&l>=224e3&&0===o&&(e[t+3]=128|e[t+3]),{sampleRate:u,channelCount:3===o?1:2,frameLength:h,samplesPerFrame:8*c*d}}}
2447function iu(e,t){return 255===e[t]&&(224&e[t+1])==224&&(6&e[t+1])!=0}function ic(e,t){return t+1<e.length&&iu(e,t)}function id(e,t){if(t+1<e.length&&iu(e,t)){let r=il(e,t),i=4;null!=r&&r.frameLength&&(i=r.frameLength);let n=t+i;return n===e.length||ic(e,n)}return!1}let ih=(e,t)=>{let r=0,i=5;t+=5;let n=new Uint32Array(1),s=new Uint32Array(1),a=new Uint8Array(1);for(;i>0;){a[0]=e[t];let o=Math.min(i,8),l=8-o;s[0]=0xff000000>>>24+l<<l,n[0]=(a[0]&s[0])>>l,r=r?r<<o|n[0]:n[0],t+=1,i-=o}return r};function ip(e,t,r,i,n){if(r+8>t.length||11!==t[r]||119!==t[r+1])return -1;let s=t[r+4]>>6;if(s>=3)return -1;let a=[48e3,44100,32e3][s],o=63&t[r+4],l=2*[64,69,96,64,70,96,80,87,120,80,88,120,96,104,144,96,105,144,112,121,168,112,122,168,128,139,192,128,140,192,160,174,240,160,175,240,192,208,288,192,209,288,224,243,336,224,244,336,256,278,384,256,279,384,320,348,480,320,349,480,384,417,576,384,418,576,448,487,672,448,488,672,512,557,768,512,558,768,640,696,960,640,697,960,768,835,1152,768,836,1152,896,975,1344,896,976,1344,1024,1114,1536,1024,1115,1536,1152,1253,1728,1152,1254,1728,1280,1393,1920,1280,1394,1920][3*o+s];if(r+l>t.length)return -1;let u=t[r+6]>>5,c=0;2===u?c+=2:(1&u&&1!==u&&(c+=2),4&u&&(c+=2));let d=(t[r+6]<<8|t[r+7])>>12-c&1,h=[2,1,2,3,3,4,4,5][u]+d,f=t[r+5]>>3,p=7&t[r+5],g=new Uint8Array([s<<6|f<<1|p>>2,(3&p)<<6|u<<3|d<<2|o>>4,o<<4&224]),m=t.subarray(r,r+l);return e.config=g,e.channelCount=h,e.samplerate=a,e.samples.push({unit:m,pts:i+1536/a*9e4*n}),l}let ig=/\/emsg[-/]ID3/i;function im(e,t){return r(e.presentationTime)?e.presentationTime/e.timeScale:t+e.presentationTimeDelta/e.timeScale}class iy{constructor(e,t,r){this.keyData=void 0,this.decrypter=void 0,this.keyData=r,this.decrypter=new tp(t,{removePKCS7Padding:!1})}decryptBuffer(e){return this.decrypter.decrypt(e,this.keyData.key.buffer,this.keyData.iv.buffer,0)}decryptAacSample(e,t,r){let i=e[t].unit;if(i.length<=16)return;let n=i.subarray(16,i.length-i.length%16),s=n.buffer.slice(n.byteOffset,n.byteOffset+n.length);this.decryptBuffer(s).then(n=>{let s=new Uint8Array(n);i.set(s,16),this.decrypter.isSync()||this.decryptAacSamples(e,t+1,r)}).catch(r)}decryptAacSamples(e,t,r){for(;;t++){if(t>=e.length)return void r();if(!(e[t].unit.length<32)&&(this.decryptAacSample(e,t,r),!this.decrypter.isSync()))return}}getAvcEncryptedData(e){let t=new Int8Array(16*Math.floor((e.length-48)/160)+16),r=0;for(let i=32;i<e.length-16;i+=160,r+=16)t.set(e.subarray(i,i+16),r);return t}getAvcDecryptedUnit(e,t){let r=new Uint8Array(t),i=0;for(let t=32;t<e.length-16;t+=160,i+=16)e.set(r.subarray(i,i+16),t);return e}decryptAvcSample(e,t,r,i,n){let s=e_(n.data),a=this.getAvcEncryptedData(s);this.decryptBuffer(a.buffer).then(a=>{n.data=this.getAvcDecryptedUnit(s,a),this.decrypter.isSync()||this.decryptAvcSamples(e,t,r+1,i)}).catch(i)}decryptAvcSamples(e,t,r,i){if(e instanceof Uint8Array)throw Error("Cannot decrypt samples of type Uint8Array");for(;;t++,r=0){if(t>=e.length)return void i();let n=e[t].units;for(;!(r>=n.length);r++){let s=n[r];if(!(s.data.length<=48)&&(1===s.type||5===s.type)&&(this.decryptAvcSample(e,t,r,i,s),!this.decrypter.isSync()))return}}}}class iv{constructor(){this.VideoSample=null}createVideoSample(e,t,r){return{key:e,frame:!1,pts:t,dts:r,units:[],length:0}}getLastNalUnit(e){var t;let r,i=this.VideoSample;if(i&&0!==i.units.length||(i=e[e.length-1]),null!=(t=i)&&t.units){let e=i.units;r=e[e.length-1]}return r}pushAccessUnit(e,t){if(e.units.length&&e.frame){if(void 0===e.pts){let r=t.samples,i=r.length;if(!i)return void t.dropped++;{let t=r[i-1];e.pts=t.pts,e.dts=t.dts}}t.samples.push(e)}}parseNALu(e,t,r){let i,n,s,a=t.byteLength,o=e.naluState||0,l=o,u=[],c=0,d=-1,h=0;for(-1===o&&(d=0,h=this.getNALuType(t,0),o=0,c=1);c<a;){if(i=t[c++],!o){o=+!i;continue}if(1===o){o=2*!i;continue}if(i)if(1===i){if(n=c-o-1,d>=0){let e={data:t.subarray(d,n),type:h};u.push(e)}else{let r=this.getLastNalUnit(e.samples);r&&(l&&c<=4-l&&r.state&&(r.data=r.data.subarray(0,r.data.byteLength-l)),n>0&&(r.data=em(r.data,t.subarray(0,n)),r.state=0))}c<a?(s=this.getNALuType(t,c),d=c,h=s,o=0):o=-1}else o=0;else o=3}if(d>=0&&o>=0){let e={data:t.subarray(d,a),type:h,state:o};u.push(e)}if(0===u.length){let r=this.getLastNalUnit(e.samples);r&&(r.data=em(r.data,t))}return e.naluState=o,u}}class ib{constructor(e){this.data=void 0,this.bytesAvailable=void 0,this.word=void 0,this.bitsAvailable=void 0,this.data=e,this.bytesAvailable=e.byteLength,this.word=0,this.bitsAvailable=0}loadWord(){let e=this.data,t=this.bytesAvailable,r=e.byteLength-t,i=new Uint8Array(4),n=Math.min(4,t);if(0===n)throw Error("no bytes available");i.set(e.subarray(r,r+n)),this.word=new DataView(i.buffer).getUint32(0),this.bitsAvailable=8*n,this.bytesAvailable-=n}skipBits(e){let t;e=Math.min(e,8*this.bytesAvailable+this.bitsAvailable),this.bitsAvailable>e||(e-=this.bitsAvailable,t=e>>3,e-=t<<3,this.bytesAvailable-=t,this.loadWord()),this.word<<=e,this.bitsAvailable-=e}readBits(e){let t=Math.min(this.bitsAvailable,e),r=this.word>>>32-t;if(e>32&&$.error("Cannot read more than 32 bits at a time"),this.bitsAvailable-=t,this.bitsAvailable>0)this.word<<=t;else if(this.bytesAvailable>0)this.loadWord();else throw Error("no bits available");return(t=e-t)>0&&this.bitsAvailable?r<<t|this.readBits(t):r}skipLZ(){let e;for(e=0;e<this.bitsAvailable;++e)if((this.word&0x80000000>>>e)!=0)return this.word<<=e,this.bitsAvailable-=e,e;return this.loadWord(),e+this.skipLZ()}skipUEG(){this.skipBits(1+this.skipLZ())}skipEG(){this.skipBits(1+this.skipLZ())}readUEG(){let e=this.skipLZ();return this.readBits(e+1)-1}readEG(){let e=this.readUEG();return 1&e?1+e>>>1:-1*(e>>>1)}readBoolean(){return 1===this.readBits(1)}readUByte(){return this.readBits(8)}readUShort(){return this.readBits(16)}readUInt(){return this.readBits(32)}}class i_ extends iv{parsePES(e,t,r,i){let n,s=this.parseNALu(e,r.data,i),a=this.VideoSample,o=!1;r.data=null,a&&s.length&&!e.audFound&&(this.pushAccessUnit(a,e),a=this.VideoSample=this.createVideoSample(!1,r.pts,r.dts)),s.forEac
2447h(i=>{var s,l,u,c,d;switch(i.type){case 1:{let t=!1;n=!0;let s=i.data;if(o&&s.length>4){let e=this.readSliceType(s);(2===e||4===e||7===e||9===e)&&(t=!0)}t&&null!=(u=a)&&u.frame&&!a.key&&(this.pushAccessUnit(a,e),a=this.VideoSample=null),a||(a=this.VideoSample=this.createVideoSample(!0,r.pts,r.dts)),a.frame=!0,a.key=t;break}case 5:n=!0,null!=(s=a)&&s.frame&&!a.key&&(this.pushAccessUnit(a,e),a=this.VideoSample=null),a||(a=this.VideoSample=this.createVideoSample(!0,r.pts,r.dts)),a.key=!0,a.frame=!0;break;case 6:n=!0,eb(i.data,1,r.pts,t.samples);break;case 7:{n=!0,o=!0;let t=i.data,r=this.readSPS(t);if(!e.sps||e.width!==r.width||e.height!==r.height||(null==(c=e.pixelRatio)?void 0:c[0])!==r.pixelRatio[0]||(null==(d=e.pixelRatio)?void 0:d[1])!==r.pixelRatio[1]){e.width=r.width,e.height=r.height,e.pixelRatio=r.pixelRatio,e.sps=[t];let i=t.subarray(1,4),n="avc1.";for(let e=0;e<3;e++){let t=i[e].toString(16);t.length<2&&(t="0"+t),n+=t}e.codec=n}break}case 8:n=!0,e.pps=[i.data];break;case 9:n=!0,e.audFound=!0,null!=(l=a)&&l.frame&&(this.pushAccessUnit(a,e),a=null),a||(a=this.VideoSample=this.createVideoSample(!1,r.pts,r.dts));break;case 12:n=!0;break;default:n=!1}a&&n&&a.units.push(i)}),i&&a&&(this.pushAccessUnit(a,e),this.VideoSample=null)}getNALuType(e,t){return 31&e[t]}readSliceType(e){let t=new ib(e);return t.readUByte(),t.readUEG(),t.readUEG()}skipScalingList(e,t){let r=8,i=8;for(let n=0;n<e;n++)0!==i&&(i=(r+t.readEG()+256)%256),r=0===i?r:i}readSPS(e){let t,r,i,n=new ib(e),s=0,a=0,o=0,l=0,u=n.readUByte.bind(n),c=n.readBits.bind(n),d=n.readUEG.bind(n),h=n.readBoolean.bind(n),f=n.skipBits.bind(n),p=n.skipEG.bind(n),g=n.skipUEG.bind(n),m=this.skipScalingList.bind(this);u();let y=u();if(c(5),f(3),u(),g(),100===y||110===y||122===y||244===y||44===y||83===y||86===y||118===y||128===y){let e=d();if(3===e&&f(1),g(),g(),f(1),h())for(i=0,r=3!==e?8:12;i<r;i++)h()&&m(i<6?16:64,n)}g();let v=d();if(0===v)d();else if(1===v)for(f(1),p(),p(),t=d(),i=0;i<t;i++)p();g(),f(1);let b=d(),_=d(),E=c(1);0===E&&f(1),f(1),h()&&(s=d(),a=d(),o=d(),l=d());let S=[1,1];if(h()&&h())switch(u()){case 1:S=[1,1];break;case 2:S=[12,11];break;case 3:S=[10,11];break;case 4:S=[16,11];break;case 5:S=[40,33];break;case 6:S=[24,11];break;case 7:S=[20,11];break;case 8:S=[32,11];break;case 9:S=[80,33];break;case 10:S=[18,11];break;case 11:S=[15,11];break;case 12:S=[64,33];break;case 13:S=[160,99];break;case 14:S=[4,3];break;case 15:S=[3,2];break;case 16:S=[2,1];break;case 255:S=[u()<<8|u(),u()<<8|u()]}return{width:Math.ceil((b+1)*16-2*s-2*a),height:(2-E)*(_+1)*16-(E?2:4)*(o+l),pixelRatio:S}}}class iE extends iv{constructor(...e){super(...e),this.initVPS=null}parsePES(e,t,r,i){let n,s=this.parseNALu(e,r.data,i),a=this.VideoSample,o=!1;r.data=null,a&&s.length&&!e.audFound&&(this.pushAccessUnit(a,e),a=this.VideoSample=this.createVideoSample(!1,r.pts,r.dts)),s.forEach(i=>{var s,l,u;switch(i.type){case 0:case 1:case 2:case 3:case 4:case 5:case 6:case 7:case 8:case 9:a||(a=this.VideoSample=this.createVideoSample(!1,r.pts,r.dts)),a.frame=!0,n=!0;break;case 16:case 17:case 18:case 21:n=!0,o&&null!=(u=a)&&u.frame&&!a.key&&(this.pushAccessUnit(a,e),a=this.VideoSample=null),a||(a=this.VideoSample=this.createVideoSample(!0,r.pts,r.dts)),a.key=!0,a.frame=!0;break;case 19:case 20:n=!0,null!=(s=a)&&s.frame&&!a.key&&(this.pushAccessUnit(a,e),a=this.VideoSample=null),a||(a=this.VideoSample=this.createVideoSample(!0,r.pts,r.dts)),a.key=!0,a.frame=!0;break;case 39:n=!0,eb(i.data,2,r.pts,t.samples);break;case 32:n=!0,e.vps||("object"!=typeof e.params&&(e.params={}),e.params=D(e.params,this.readVPS(i.data)),this.initVPS=i.data),e.vps=[i.data];break;case 33:if(n=!0,o=!0,void 0===e.vps||e.vps[0]===this.initVPS||void 0===e.sps||this.matchSPS(e.sps[0],i.data)||(this.initVPS=e.vps[0],e.sps=e.pps=void 0),!e.sps){let t=this.readSPS(i.data);for(let r in e.width=t.width,e.height=t.height,e.pixelRatio=t.pixelRatio,e.codec=t.codecString,e.sps=[],"object"!=typeof e.params&&(e.params={}),t.params)e.params[r]=t.params[r]}this.pushParameterSet(e.sps,i.data,e.vps),a||(a=this.VideoSample=this.createVideoSample(!0,r.pts,r.dts)),a.key=!0;break;case 34:if(n=!0,"object"==typeof e.params){if(!e.pps){e.pps=[];let t=this.readPPS(i.data);for(let r in t)e.params[r]=t[r]}this.pushParameterSet(e.pps,i.data,e.vps)}break;case 35:n=!0,e.audFound=!0,null!=(l=a)&&l.frame&&(this.pushAccessUnit(a,e),a=null),a||(a=this.VideoSample=this.createVideoSample(!1,r.pts,r.dts));break;default:n=!1}a&&n&&a.units.push(i)}),i&&a&&(this.pushAccessUnit(a,e),this.VideoSample=null)}pushParameterSet(e,t,r){(!r||r[0]!==this.initVPS)&&(r||e.length)||e.push(t)}getNALuType(e,t){return(126&e[t])>>>1}ebsp2rbsp(e){let t=new Uint8Array(e.byteLength),r=0;for(let i=0;i<e.byteLength;i++)(!(i>
2447=2)||3!==e[i]||0!==e[i-1]||0!==e[i-2])&&(t[r]=e[i],r++);return new Uint8Array(t.buffer,0,r)}pushAccessUnit(e,t){super.pushAccessUnit(e,t),this.initVPS&&(this.initVPS=null)}readVPS(e){let t=new ib(e);return t.readUByte(),t.readUByte(),t.readBits(4),t.skipBits(2),t.readBits(6),{numTemporalLayers:t.readBits(3)+1,temporalIdNested:t.readBoolean()}}readSPS(e){let t=new ib(this.ebsp2rbsp(e));t.readUByte(),t.readUByte(),t.readBits(4);let r=t.readBits(3);t.readBoolean();let i=t.readBits(2),n=t.readBoolean(),s=t.readBits(5),a=t.readUByte(),o=t.readUByte(),l=t.readUByte(),u=t.readUByte(),c=t.readUByte(),d=t.readUByte(),h=t.readUByte(),f=t.readUByte(),p=t.readUByte(),g=t.readUByte(),m=t.readUByte(),y=[],v=[];for(let e=0;e<r;e++)y.push(t.readBoolean()),v.push(t.readBoolean());if(r>0)for(let e=r;e<8;e++)t.readBits(2);for(let e=0;e<r;e++)y[e]&&(t.readUByte(),t.readUByte(),t.readUByte(),t.readUByte(),t.readUByte(),t.readUByte(),t.readUByte(),t.readUByte(),t.readUByte(),t.readUByte(),t.readUByte()),v[e]&&t.readUByte();t.readUEG();let b=t.readUEG();3==b&&t.skipBits(1);let _=t.readUEG(),E=t.readUEG(),S=t.readBoolean(),x=0,T=0,w=0,A=0;S&&(x+=t.readUEG(),T+=t.readUEG(),w+=t.readUEG(),A+=t.readUEG());let R=t.readUEG(),I=t.readUEG(),k=t.readUEG(),C=t.readBoolean();for(let e=C?0:r;e<=r;e++)t.skipUEG(),t.skipUEG(),t.skipUEG();if(t.skipUEG(),t.skipUEG(),t.skipUEG(),t.skipUEG(),t.skipUEG(),t.skipUEG(),t.readBoolean()&&t.readBoolean())for(let e=0;e<4;e++)for(let r=0;r<(3===e?2:6);r++)if(t.readBoolean()){let r=Math.min(64,1<<4+(e<<1));e>1&&t.readEG();for(let e=0;e<r;e++)t.readEG()}else t.readUEG();t.readBoolean(),t.readBoolean(),t.readBoolean()&&(t.readUByte(),t.skipUEG(),t.skipUEG(),t.readBoolean());let D=t.readUEG(),L=0;for(let e=0;e<D;e++){let r=!1;if(0!==e&&(r=t.readBoolean()),r){e===D&&t.readUEG(),t.readBoolean(),t.readUEG();let r=0;for(let e=0;e<=L;e++){let e=t.readBoolean(),i=!1;e||(i=t.readBoolean()),(e||i)&&r++}L=r}else{let e=t.readUEG(),r=t.readUEG();L=e+r;for(let r=0;r<e;r++)t.readUEG(),t.readBoolean();for(let e=0;e<r;e++)t.readUEG(),t.readBoolean()}}if(t.readBoolean()){let e=t.readUEG();for(let r=0;r<e;r++){for(let e=0;e<k+4;e++)t.readBits(1);t.readBits(1)}}let O=0,P=1,F=1,N=!0,M=1,j=0;t.readBoolean(),t.readBoolean();if(t.readBoolean()){if(t.readBoolean()){let e=t.readUByte();e>0&&e<16?(P=[1,12,10,16,40,24,20,32,80,18,15,64,160,4,3,2][e-1],F=[1,11,11,11,33,11,11,11,33,11,11,33,99,3,2,1][e-1]):255===e&&(P=t.readBits(16),F=t.readBits(16))}if(t.readBoolean()&&t.readBoolean(),t.readBoolean()&&(t.readBits(3),t.readBoolean(),t.readBoolean()&&(t.readUByte(),t.readUByte(),t.readUByte())),t.readBoolean()&&(t.readUEG(),t.readUEG()),t.readBoolean(),t.readBoolean(),t.readBoolean(),t.readBoolean()&&(t.skipUEG(),t.skipUEG(),t.skipUEG(),t.skipUEG()),t.readBoolean()&&(M=t.readBits(32),j=t.readBits(32),t.readBoolean()&&t.readUEG(),t.readBoolean())){let e=t.readBoolean(),i=t.readBoolean(),n=!1;(e||i)&&((n=t.readBoolean())&&(t.readUByte(),t.readBits(5),t.readBoolean(),t.readBits(5)),t.readBits(4),t.readBits(4),n&&t.readBits(4),t.readBits(5),t.readBits(5),t.readBits(5));for(let s=0;s<=r;s++){let r=(N=t.readBoolean())||t.readBoolean(),s=!1;r?t.readEG():s=t.readBoolean();let a=s?1:t.readUEG()+1;if(e)for(let e=0;e<a;e++)t.readUEG(),t.readUEG(),n&&(t.readUEG(),t.readUEG()),t.skipBits(1);if(i)for(let e=0;e<a;e++)t.readUEG(),t.readUEG(),n&&(t.readUEG(),t.readUEG()),t.skipBits(1)}}t.readBoolean()&&(t.readBoolean(),t.readBoolean(),t.readBoolean(),O=t.readUEG())}let $=_,U=E;if(S){let e=1,t=1;1===b?e=t=2:2==b&&(e=2),$=_-e*T-e*x,U=E-t*A-t*w}let B=i?["A","B","C"][i]:"",V=a<<24|o<<16|l<<8|u,G=0;for(let e=0;e<32;e++)G=(G|(V>>e&1)<<31-e)>>>0;let q=G.toString(16);return 1===s&&"2"===q&&(q="6"),{codecString:`hvc1.${B}${s}.${q}.${n?"H":"L"}${m}.B0`,params:{general_tier_flag:n,general_profile_idc:s,general_profile_space:i,general_profile_compatibility_flags:[a,o,l,u],general_constraint_indicator_flags:[c,d,h,f,p,g],general_level_idc:m,bit_depth:R+8,bit_depth_luma_minus8:R,bit_depth_chroma_minus8:I,min_spatial_segmentation_idc:O,chroma_format_idc:b,frame_rate:{fixed:N,fps:j/M}},width:$,height:U,pixelRatio:[P,F]}}readPPS(e){let t=new ib(this.ebsp2rbsp(e));t.readUByte(),t.readUByte(),t.skipUEG(),t.skipUEG(),t.skipBits(2),t.skipBits(3),t.skipBits(2),t.skipUEG(),t.skipUEG(),t.skipEG(),t.skipBits(2),t.readBoolean()&&t.skipUEG(),t.skipEG(),t.skipEG(),t.skipBits(4);let r=t.readBoolean(),i=t.readBoolean(),n=1;return i&&r?n=0:i?n=3:r&&(n=2),{parallelismType:n}}matchSPS(e,t){return String.fromCharCode.apply(null,e).substr(3)===String.fromCharCode.apply(null,t).substr(3)}}
2447class iS{constructor(e,t,r,i){this.logger=void 0,this.observer=void 0,this.config=void 0,this.typeSupported=void 0,this.sampleAes=null,this.pmtParsed=!1,this.audioCodec=void 0,this.videoCodec=void 0,this._pmtId=-1,this._videoTrack=void 0,this._audioTrack=void 0,this._id3Track=void 0,this._txtTrack=void 0,this.aacOverFlow=null,this.remainderData=null,this.videoParser=void 0,this.observer=e,this.config=t,this.typeSupported=r,this.logger=i,this.videoParser=null}static probe(e,t){let r=iS.syncOffset(e);return r>0&&t.warn(`MPEG2-TS detected but first sync word found @ offset ${r}`),-1!==r}static syncOffset(e){let t=e.length,r=Math.min(940,t-188)+1,i=0;for(;i<r;){let n=!1,s=-1,a=0;for(let o=i;o<t;o+=188)if(71===e[o]&&(t-o==188||71===e[o+188])){if(a++,-1===s&&0!==(s=o)&&(r=Math.min(s+18612,e.length-188)+1),n||(n=0===ix(e,o)),n&&a>1&&(0===s&&a>2||o+188>r))return s}else if(a)return -1;else break;i++}return -1}static createTrack(e,t){return{container:"video"===e||"audio"===e?"video/mp2t":void 0,type:e,id:er[e],pid:-1,inputTimeScale:9e4,sequenceNumber:0,samples:[],dropped:0,duration:"audio"===e?t:void 0}}resetInitSegment(e,t,r,i){this.pmtParsed=!1,this._pmtId=-1,this._videoTrack=iS.createTrack("video"),this._videoTrack.duration=i,this._audioTrack=iS.createTrack("audio",i),this._id3Track=iS.createTrack("id3"),this._txtTrack=iS.createTrack("text"),this._audioTrack.segmentCodec="aac",this.videoParser=null,this.aacOverFlow=null,this.remainderData=null,this.audioCodec=t,this.videoCodec=r}resetTimeStamp(){}resetContiguity(){let{_audioTrack:e,_videoTrack:t,_id3Track:r}=this;e&&(e.pesData=null),t&&(t.pesData=null),r&&(r.pesData=null),this.aacOverFlow=null,this.remainderData=null}demux(e,t,r=!1,i=!1){let n;r||(this.sampleAes=null);let s=this._videoTrack,a=this._audioTrack,o=this._id3Track,l=this._txtTrack,u=s.pid,c=s.pesData,d=a.pid,h=o.pid,f=a.pesData,p=o.pesData,g=null,m=this.pmtParsed,y=this._pmtId,v=e.length;if(this.remainderData&&(v=(e=em(this.remainderData,e)).length,this.remainderData=null),v<188&&!i)return this.remainderData=e,{audioTrack:a,videoTrack:s,id3Track:o,textTrack:l};let b=Math.max(0,iS.syncOffset(e));(v-=(v-b)%188)<e.byteLength&&!i&&(this.remainderData=new Uint8Array(e.buffer,v,e.buffer.byteLength-v));let _=0;for(let t=b;t<v;t+=188)if(71===e[t]){let i,v=!!(64&e[t+1]),_=ix(e,t);if((48&e[t+3])>>4>1){if((i=t+5+e[t+4])===t+188)continue}else i=t+4;switch(_){case u:v&&(c&&(n=iA(c,this.logger))&&(this.readyVideoParser(s.segmentCodec),null!==this.videoParser&&this.videoParser.parsePES(s,l,n,!1)),c={data:[],size:0}),c&&(c.data.push(e.subarray(i,t+188)),c.size+=t+188-i);break;case d:if(v){if(f&&(n=iA(f,this.logger)))switch(a.segmentCodec){case"aac":this.parseAACPES(a,n);break;case"mp3":this.parseMPEGPES(a,n);break;case"ac3":this.parseAC3PES(a,n)}f={data:[],size:0}}f&&(f.data.push(e.subarray(i,t+188)),f.size+=t+188-i);break;case h:v&&(p&&(n=iA(p,this.logger))&&this.parseID3PES(o,n),p={data:[],size:0}),p&&(p.data.push(e.subarray(i,t+188)),p.size+=t+188-i);break;case 0:var E,S;v&&(i+=e[i]+1),y=this._pmtId=(31&(E=e)[(S=i)+10])<<8|E[S+11];break;case y:{v&&(i+=e[i]+1);let n=function(e,t,r,i,n,s){let a={audioPid:-1,videoPid:-1,id3Pid:-1,segmentVideoCodec:"avc",segmentAudioCodec:"aac"},o=(15&e[t+1])<<8|e[t+2],l=t+3+o-4,u=(15&e[t+10])<<8|e[t+11];for(t+=12+u;t<l;){let o=ix(e,t),l=(15&e[t+3])<<8|e[t+4];switch(e[t]){case 207:if(!i){iw("ADTS AAC",s);break}case 15:-1===a.audioPid&&(a.audioPid=o);break;case 21:-1===a.id3Pid&&(a.id3Pid=o);break;case 219:if(!i){iw("H.264",s);break}case 27:-1===a.videoPid&&(a.videoPid=o);break;case 3:case 4:r.mpeg||r.mp3?-1===a.audioPid&&(a.audioPid=o,a.segmentAudioCodec="mp3"):s.log("MPEG audio found, not supported in this browser");break;case 193:if(!i){iw("AC-3",s);break}case 129:r.ac3?-1===a.audioPid&&(a.audioPid=o,a.segmentAudioCodec="ac3"):s.log("AC-3 audio found, not supported in this browser");break;case 6:if(-1===a.audioPid&&l>0){let i=t+5,n=l;for(;n>2;){106===e[i]&&(!0!==r.ac3?s.log("AC-3 audio found, not supported in this browser for now"):(a.audioPid=o,a.segmentAudioCodec="ac3"));let t=e[i+1]+2;i+=t,n-=t}}break;case 194:case 135:return iT(n,Error("Unsupported EC-3 in M2TS found"),void 0,s),a;case 36:-1===a.videoPid&&(a.videoPid=o,a.segmentVideoCodec="hevc",s.log("HEVC in M2TS found"))}t+=l+5}return a}
2447(e,i,this.typeSupported,r,this.observer,this.logger);(u=n.videoPid)>0&&(s.pid=u,s.segmentCodec=n.segmentVideoCodec),(d=n.audioPid)>0&&(a.pid=d,a.segmentCodec=n.segmentAudioCodec),(h=n.id3Pid)>0&&(o.pid=h),null===g||m||(this.logger.warn(`MPEG-TS PMT found at ${t} after unknown PID '${g}'. Backtracking to sync byte @${b} to parse all TS packets.`),g=null,t=b-188),m=this.pmtParsed=!0;break}case 17:case 8191:break;default:g=_}}else _++;_>0&&iT(this.observer,Error(`Found ${_} TS packet/s that do not start with 0x47`),void 0,this.logger),s.pesData=c,a.pesData=f,o.pesData=p;let x={audioTrack:a,videoTrack:s,id3Track:o,textTrack:l};return i&&this.extractRemainingSamples(x),x}flush(){let e,{remainderData:t}=this;return(this.remainderData=null,e=t?this.demux(t,-1,!1,!0):{videoTrack:this._videoTrack,audioTrack:this._audioTrack,id3Track:this._id3Track,textTrack:this._txtTrack},this.extractRemainingSamples(e),this.sampleAes)?this.decrypt(e,this.sampleAes):e}extractRemainingSamples(e){let t,{audioTrack:r,videoTrack:i,id3Track:n,textTrack:s}=e,a=i.pesData,o=r.pesData,l=n.pesData;if(a&&(t=iA(a,this.logger))?(this.readyVideoParser(i.segmentCodec),null!==this.videoParser&&(this.videoParser.parsePES(i,s,t,!0),i.pesData=null)):i.pesData=a,o&&(t=iA(o,this.logger))){switch(r.segmentCodec){case"aac":this.parseAACPES(r,t);break;case"mp3":this.parseMPEGPES(r,t);break;case"ac3":this.parseAC3PES(r,t)}r.pesData=null}else null!=o&&o.size&&this.logger.log("last AAC PES packet truncated,might overlap between fragments"),r.pesData=o;l&&(t=iA(l,this.logger))?(this.parseID3PES(n,t),n.pesData=null):n.pesData=l}demuxSampleAes(e,t,r){let i=this.demux(e,r,!0,!this.config.progressive),n=this.sampleAes=new iy(this.observer,this.config,t);return this.decrypt(i,n)}readyVideoParser(e){null===this.videoParser&&("avc"===e?this.videoParser=new i_:"hevc"===e&&(this.videoParser=new iE))}decrypt(e,t){return new Promise(r=>{let{audioTrack:i,videoTrack:n}=e;i.samples&&"aac"===i.segmentCodec?t.decryptAacSamples(i.samples,0,()=>{n.samples?t.decryptAvcSamples(n.samples,0,0,()=>{r(e)}):r(e)}):n.samples&&t.decryptAvcSamples(n.samples,0,0,()=>{r(e)})})}destroy(){this.observer&&this.observer.removeAllListeners(),this.config=this.logger=this.observer=null,this.aacOverFlow=this.videoParser=this.remainderData=this.sampleAes=null,this._videoTrack=this._audioTrack=this._id3Track=this._txtTrack=void 0}parseAACPES(e,t){let r,i,n,s,a=0,o=this.aacOverFlow,l=t.data;if(o){this.aacOverFlow=null;let t=o.missing,r=o.sample.unit.byteLength;-1===t?l=em(o.sample.unit,l):(o.sample.unit.set(l.subarray(0,t),r-t),e.samples.push(o.sample),a=o.missing)}for(r=a,i=l.length;r<i-1&&!r0(l,r);r++);if(r!==a){let e,t=r<i-1;if(e=t?`AAC PES did not start with ADTS header,offset:${r}`:"No ADTS header found in AAC PES",iT(this.observer,Error(e),t,this.logger),!t)return}if(r1(e,this.observer,l,r,this.audioCodec),void 0!==t.pts)n=t.pts;else{if(!o)return void this.logger.warn("[tsdemuxer]: AAC PES unknown PTS");let t=9216e4/e.samplerate;n=o.sample.pts+t}let u=0;for(;r<i;){if(s=r2(e,l,r,n,u),r+=s.length,s.missing){this.aacOverFlow=s;break}for(u++;r<i-1&&!r0(l,r);r++);}}parseMPEGPES(e,t){let r=t.data,i=r.length,n=0,s=0,a=t.pts;if(void 0===a)return void this.logger.warn("[tsdemuxer]: MPEG PES unknown PTS");for(;s<i;)if(ic(r,s)){let t=io(e,r,s,a,n);if(t)s+=t.length,n++;else break}else s++}parseAC3PES(e,t){{let r,i=t.data,n=t.pts;if(void 0===n)return void this.logger.warn("[tsdemuxer]: AC3 PES unknown PTS");let s=i.length,a=0,o=0;for(;o<s&&(r=ip(e,i,o,n,a++))>0;)o+=r}}parseID3PES(e,t){if(void 0===t.pts)return void this.logger.warn("[tsdemuxer]: ID3 PES unknown PTS");let r=D({},t,{type:this._videoTrack?r6.emsg:r6.audioId3,duration:1/0});e.samples.push(r)}}function ix(e,t){return((31&e[t+1])<<8)+e[t+2]}function iT(e,t,r,i){i.warn(`parsing error: ${t.message}`),e.emit(o.ERROR,o.ERROR,{type:s.MEDIA_ERROR,details:a.FRAG_PARSING_ERROR,fatal:!1,levelRetry:r,error:t,reason:t.message})}function iw(e,t){t.log(`${e} with AES-128-CBC encryption found in unencrypted stream`)}function iA(e,t){let r,i,n,s,a,o=0,l=e.data;if(!e||0===e.size)return null;for(;l[0].length<19&&l.length>1;)l[0]=em(l[0],l[1]),l.splice(1,1);if(1===((r=l[0])[0]<<16)+(r[1]<<8)+r[2]){if((i=(r[4]<<8)+r[5])&&i>e.size-6)return null;let u=r[7];192&u&&(s=(14&r[9])*0x20000000+(255&r[10])*4194304+(254&r[11])*16384+(255&r[12])*128+(254&r[13])/2,64&u?s-(a=(14&r[14])*0x20000000+(255&r[15])*4194304+(254&r[16])*16384+(255&r[17])*128+(254&r[18])/2)>54e5&&(t.warn(`${Math.round((s-a)/9e4)}s delta between PTS and DTS, align them`),s=a):a=s);let c=(n=r[8])+9;if(e.size<=c)return null;e.size-=c;let d=new Uint8Array(e.size);for(let e=0,t=l.length;e<t;e++){let t=(r=l[e]).byteLength;if(c)if(c>t){c-=t;continue}else r=r.subarray(c),t-=c,c=0;d.set(r,o),o+=t}return i&&(i-=n+3),{data:d,pts:s,dts:a,len:i}}return null}class iR{static getSilentFrame(e,t){if("mp4a.40.2"===e){if(1===t)return new Uint8Array([0,200,0,128,35,128]);if(2===t)return new Uint8Array([33,0,73,144,2,25,0,35,128]);if(3===t)return new Uint8Array([0,200,0,128,32,132,1,38,64,8,100,0,142]);else if(4===t)return new Uint8Array([0,200,0,128,32,132,1,38,64,8,100,0,128,44,128,8,2,56]);else if(5===t)return new Uint8Array([0,200,0,128,32,132,1,38,64,8,100,0,130,48,4,153,0,33,144,2,56]);else if(6===t)return new Uint8Array([0,200,0,128,32,132,1,38,64,8,100,0,130,48,4,153,0,33,144,2,0,178,0,32,8,224])}else{if(1===t)return new Uint8Array([1,64,34,128,163,78,230,128,186,8,0,0,0,28,6,241,193,10,90,90,90,90,90,90,90,90,90,90,90,90,90,90,90,90,90,90,90,90,90,90,90,90,90,90,90,90,90,90,90,90,90,90,90,90,90,90,90,90,94]);if(2===t)return new Uint8Array([1,64,34,128,163,94,230,128,186,8,0,0,0,0,149,0,6,241,161,10,90,90,90,90,90,90,90,90,90,90,90,90,90,90,90,90,90,90,90,90,90,90,90,90,90,90,90,90,90,90,90,90,90,90,90,90,90,90,94]);if(3===t)return new Uint8Array([1,64,34,128,163,94,230,128,186,8,0,0,0,0,149,0,6,241,161,10,90,90,90,90,90,90,90,90,90,90,90,90,90,90,90,90,90,90,90,90,90,90,90,90,90,90,90,90,90,90,90,90,90,90,90,90,90,90,94])}}}class iI{static init(){let e;for(e in iI.types={avc1:[],avcC:[],hvc1:[],hvcC:[],btrt:[],dinf:[],dref:[],esds:[],ftyp:[],hdlr:[],mdat:[],mdhd:[],mdia:[],mfhd:[],minf:[],moof:[],moov:[],mp4a:[],".mp3":[],dac3:[],"ac-3":[],mvex:[],mvhd:[],pasp:[],sdtp:[],stbl:[],stco:[],stsc:[],stsd:[],stsz:[],stts:[],tfdt:[],tfhd:[],traf:[],trak:[],trun:[],trex:[],tkhd:[],vmhd:[],smhd:[]},iI.types)iI.types.hasOwnProperty(e)&&(iI.types[e]=[e.charCodeAt(0),e.charCodeAt(1),e.charCodeAt(2),e.charCodeAt(3)]);iI.HDLR_TYPES={video:new Uint8Array([0,0,0,0,0,0,0,0,118,105,100,101,0,0,0,0,0,0,0,0,0,0,0,0,86,105,100,101,111,72,97,110,100,108,101,114,0]),audio:new Uint8Array([0,0,0,0,0,0,0,0,115,111,117,110,0,0,0,0,0,0,0,0,0,0,0,0,83,111,117,110,100,72,97,110,100,108,101,114,0])};let t=new Uint8Array([0,0,0,0,0,0,0,1,0,0,0,12,117,114,108,32,0,0,0,1]);iI.STTS=iI.STSC=iI.STCO=new Uint8Array([0,0,0,0,0,0,0,0]),iI.STSZ=new Uint8Array([0,0,0,0,0,0,0,0,0,0,0,0]),iI.VMHD=new Uint8Array([0,0,0,1,0,0,0,0,0,0,0,0]),iI.SMHD=new Uint8Array([0,0,0,0,0,0,0,0]),iI.STSD=new Uint8Array([0,0,0,0,0,0,0,1]);let r=new Uint8Array([105,115,111,109]),i=new Uint8Array([97,118,99,49]),n=new Uint8Array([0,0,0,1]);iI.FTYP=iI.box(iI.types.ftyp,r,n,r,i),iI.DINF=iI.box(iI.types.dinf,iI.box(iI.types.dref,t))}static box(e,...t){let r=8,i=t.length,n=i;for(;i--;)r+=t[i].byteLength;let s=new Uint8Array(r);for(s[0]=r>>24&255,s[1]=r>>16&255,s[2]=r>>8&255,s[3]=255&r,s.set(e,4),i=0,r=8;i<n;i++)s.set(t[i],r),r+=t[i].byteLength;return s}static hdlr(e){return iI.box(iI.types.hdlr,iI.HDLR_TYPES[e])}static mdat(e){return iI.box(iI.types.mdat,e)}static mdhd(e,t){let r=Math.floor((t*=e)/0x100000000),i=Math.floor(t%0x100000000);return iI.box(iI.types.mdhd,new Uint8Array([1,0,0,0,0,0,0,0,0,0,0,2,0,0,0,0,0,0,0,3,e>>24&255,e>>16&255,e>>8&255,255&e,r>>24,r>>16&255,r>>8&255,255&r,i>>24,i>>16&255,i>>8&255,255&i,85,196,0,0]))}static mdia(e){return iI.box(iI.types.mdia,iI.mdhd(e.timescale||0,e.duration||0),iI.hdlr(e.type),iI.minf(e))}static mfhd(e){return iI.box(iI.types.mfhd,new Uint8Array([0,0,0,0,e>>24,e>>16&255,e>>8&255,255&e]))}static minf(e){return"audio"===e.type?iI.box(iI.types.minf,iI.box(iI.types.smhd,iI.SMHD),iI.DINF,iI.stbl(e)):iI.box(iI.types.minf,iI.box(iI.types.vmhd,iI.VMHD),iI.DINF,iI.stbl(e))}static moof(e,t,r){return iI.box(iI.types.moof,iI.mfhd(e),iI.traf(r,t))}static moov(e){let t=e.length,r=[];for(;t--;)r[t]=iI.trak(e[t]);return iI.box.apply(null,[iI.types.moov,iI.mvhd(e[0].timescale||0,e[0].duration||0)].concat(r).concat(iI.mvex(e)))}static mvex(e){let t=e.length,r=[];for(;t--;)r[t]=iI.trex(e[t]);return iI.box.apply(null,[iI.types.mvex,...r])}static mvhd(e,t){let r=Math.floor((t*=e)/0x100000000),i=Math.floor(t%0x100000000),n=new Uint8Array([1,0,0,0,0,0,0,0,0,0,0,2,0,0,0,0,0,0,0,3,e>>24&255,e>>16&255,e>>8&255,255&e,r>>24,r>>16&255,r>>8&255,255&r,i>>24,i>>16&255,i>>8&255,255&i,0,1,0,0,1,0,0,0,0,0,0,0,0,0,0,0,0,1,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,1,0,0,0,0,0,0,0,0,0,0,0,0,0,0,64,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,255,255,255,255]);return iI.box(iI.types.mvhd,n)}static sdtp(e){let t,r,i=e.samples||[],n=new Uint8Array(4+i.length);for(t=0;t<i.length;t++)r=i[t].flags,n[t+4]=r.dependsOn<<4|r.isDependedOn<<2|r.hasRedundancy;return iI.box(iI.types.sdtp,n)}static stbl(e){return iI.box(iI.types.stbl,iI.stsd(e),iI.box(iI.types.stts,iI.STTS),iI.box(iI.types.stsc,iI.STSC),iI.box(iI.types.stsz,iI.STSZ),iI.box(iI.types.stco,iI.STCO))}static avc1(e){let t,r,i,n=[],s=[];for(t=0;t<e.sps.length;t++)i=(r=e.sps[t]).byteLength,n.push(i>
2447>>8&255),n.push(255&i),n=n.concat(Array.prototype.slice.call(r));for(t=0;t<e.pps.length;t++)i=(r=e.pps[t]).byteLength,s.push(i>>>8&255),s.push(255&i),s=s.concat(Array.prototype.slice.call(r));let a=iI.box(iI.types.avcC,new Uint8Array([1,n[3],n[4],n[5],255,224|e.sps.length].concat(n).concat([e.pps.length]).concat(s))),o=e.width,l=e.height,u=e.pixelRatio[0],c=e.pixelRatio[1];return iI.box(iI.types.avc1,new Uint8Array([0,0,0,0,0,0,0,1,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,o>>8&255,255&o,l>>8&255,255&l,0,72,0,0,0,72,0,0,0,0,0,0,0,1,18,100,97,105,108,121,109,111,116,105,111,110,47,104,108,115,46,106,115,0,0,0,0,0,0,0,0,0,0,0,0,0,0,24,17,17]),a,iI.box(iI.types.btrt,new Uint8Array([0,28,156,128,0,45,198,192,0,45,198,192])),iI.box(iI.types.pasp,new Uint8Array([u>>24,u>>16&255,u>>8&255,255&u,c>>24,c>>16&255,c>>8&255,255&c])))}static esds(e){return new Uint8Array([0,0,0,0,3,25,0,1,0,4,17,64,21,0,0,0,0,0,0,0,0,0,0,0,5,2,...e.config,6,1,2])}static audioStsd(e){let t=e.samplerate||0;return new Uint8Array([0,0,0,0,0,0,0,1,0,0,0,0,0,0,0,0,0,e.channelCount||0,0,16,0,0,0,0,t>>8&255,255&t,0,0])}static mp4a(e){return iI.box(iI.types.mp4a,iI.audioStsd(e),iI.box(iI.types.esds,iI.esds(e)))}static mp3(e){return iI.box(iI.types[".mp3"],iI.audioStsd(e))}static ac3(e){return iI.box(iI.types["ac-3"],iI.audioStsd(e),iI.box(iI.types.dac3,e.config))}static stsd(e){let{segmentCodec:t}=e;if("audio"===e.type){if("aac"===t)return iI.box(iI.types.stsd,iI.STSD,iI.mp4a(e));if("ac3"===t&&e.config)return iI.box(iI.types.stsd,iI.STSD,iI.ac3(e));if("mp3"===t&&"mp3"===e.codec)return iI.box(iI.types.stsd,iI.STSD,iI.mp3(e))}else if(e.pps&&e.sps){if("avc"===t)return iI.box(iI.types.stsd,iI.STSD,iI.avc1(e));if("hevc"===t&&e.vps)return iI.box(iI.types.stsd,iI.STSD,iI.hvc1(e))}else throw Error("video track missing pps or sps");throw Error(`unsupported ${e.type} segment codec (${t}/${e.codec})`)}static tkhd(e){let t=e.id,r=(e.duration||0)*(e.timescale||0),i=e.width||0,n=e.height||0,s=Math.floor(r/0x100000000),a=Math.floor(r%0x100000000);return iI.box(iI.types.tkhd,new Uint8Array([1,0,0,7,0,0,0,0,0,0,0,2,0,0,0,0,0,0,0,3,t>>24&255,t>>16&255,t>>8&255,255&t,0,0,0,0,s>>24,s>>16&255,s>>8&255,255&s,a>>24,a>>16&255,a>>8&255,255&a,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,1,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,1,0,0,0,0,0,0,0,0,0,0,0,0,0,0,64,0,0,0,i>>8&255,255&i,0,0,n>>8&255,255&n,0,0]))}static traf(e,t){let r=iI.sdtp(e),i=e.id,n=Math.floor(t/0x100000000),s=Math.floor(t%0x100000000);return iI.box(iI.types.traf,iI.box(iI.types.tfhd,new Uint8Array([0,0,0,0,i>>24,i>>16&255,i>>8&255,255&i])),iI.box(iI.types.tfdt,new Uint8Array([1,0,0,0,n>>24,n>>16&255,n>>8&255,255&n,s>>24,s>>16&255,s>>8&255,255&s])),iI.trun(e,r.length+16+20+8+16+8+8),r)}static trak(e){return e.duration=e.duration||0xffffffff,iI.box(iI.types.trak,iI.tkhd(e),iI.mdia(e))}static trex(e){let t=e.id;return iI.box(iI.types.trex,new Uint8Array([0,0,0,0,t>>24,t>>16&255,t>>8&255,255&t,0,0,0,1,0,0,0,0,0,0,0,0,0,1,0,1]))}static trun(e,t){let r,i,n,s,a,o,l=e.samples||[],u=l.length,c=12+16*u,d=new Uint8Array(c);for(t+=8+c,d.set([+("video"===e.type),0,15,1,u>>>24&255,u>>>16&255,u>>>8&255,255&u,t>>>24&255,t>>>16&255,t>>>8&255,255&t],0),r=0;r<u;r++)n=(i=l[r]).duration,s=i.size,a=i.flags,o=i.cts,d.set([n>>>24&255,n>>>16&255,n>>>8&255,255&n,s>>>24&255,s>>>16&255,s>>>8&255,255&s,a.isLeading<<2|a.dependsOn,a.isDependedOn<<6|a.hasRedundancy<<4|a.paddingValue<<1|a.isNonSync,61440&a.degradPrio,15&a.degradPrio,o>>>24&255,o>>>16&255,o>>>8&255,255&o],12+16*r);return iI.box(iI.types.trun,d)}static initSegment(e){iI.types||iI.init();let t=iI.moov(e);return em(iI.FTYP,t)}static hvc1(e){let t=e.params,r=[e.vps,e.sps,e.pps],i=new Uint8Array([1,t.general_profile_space<<6|32*!!t.general_tier_flag|t.general_profile_idc,t.general_profile_compatibility_flags[0],t.general_profile_compatibility_flags[1],t.general_profile_compatibility_flags[2],t.general_profile_compatibility_flags[3],t.general_constraint_indicator_flags[0],t.general_constraint_indicator_flags[1],t.general_constraint_indicator_flags[2],t.general_constraint_indicator_flags[3],t.general_constraint_indicator_flags[4],t.general_constraint_indicator_flags[5],t.general_level_idc,240|t.min_spatial_segmentation_idc>>8,255&t.min_spatial_segmentation_idc,252|t.parallelismType,252|t.chroma_format_idc,248|t.bit_depth_luma_minus8,248|t.bit_depth_chroma_minus8,0,parseInt(t.frame_rate.fps),3|t.temporal_id_nested<<2|t.num_temporal_layers<<3|64*!!t.frame_rate.fixed,r.length]),n=i.length;for(let e=0;e<r.length;e+=1){n+=3;for(let t=0;t<r[e].length;t+=1)n+=2+r[e][t].length}let s=new Uint8Array(n);s.set(i,0),n=i.length;let a=r.length-1;for(let e=0;e<r.length;e+=1){s.set(new Uint8Array([32+e|128*(e===a),0,r[e].length]),n),n+=3;for(let t=0;t<r[e].length;t+=1)s.set(new Uint8Array([r[e][t].length>>8,255&r[e][t].length]),n),n+=2,s.set(r[e][t],n),n+=r[e][t].length}let o=iI.box(iI.types.hvcC,s),l=e.width,u=e.height,c=e.pixelRatio[0],d=e.pixelRatio[1];return iI.box(iI.types.hvc1,new Uint8Array([0,0,0,0,0,0,0,1,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,l>>8&255,255&l,u>>8&255,255&u,0,72,0,0,0,72,0,0,0,0,0,0,0,1,18,100,97,105,108,121,109,111,116,105,111,110,47,104,108,115,46,106,115,0,0,0,0,0,0,0,0,0,0,0,0,0,0,24,17,17]),o,iI.box(iI.types.btrt,new Uint8Array([0,28,156,128,0,45,198,192,0,45,198,192])),iI.box(iI.types.pasp,new Uint8Array([c>>24,c>>16&255,c>>8&255,255&c,d>>24,d>>16&255,d>>8&255,255&d])))}}function ik(e,t,r=1,i=!1){let n=e*t*r;return i?Math.round(n):n}function iC(e,t=!1){return ik(e,1e3,11111111111111112e-21,t)}
2447function iD(e){let{baseTime:t,timescale:r,trackId:i}=e;return`${t/r} (${t}/${r}) trackId: ${i}`}iI.types=void 0,iI.HDLR_TYPES=void 0,iI.STTS=void 0,iI.STSC=void 0,iI.STCO=void 0,iI.STSZ=void 0,iI.VMHD=void 0,iI.SMHD=void 0,iI.STSD=void 0,iI.FTYP=void 0,iI.DINF=void 0;let iL=null,iO=null;function iP(e,t,r,i){return{duration:t,size:r,cts:i,flags:{isLeading:0,isDependedOn:0,hasRedundancy:0,degradPrio:0,dependsOn:e?2:1,isNonSync:+!e}}}class iF extends P{constructor(e,t,r,i){if(super("mp4-remuxer",i),this.observer=void 0,this.config=void 0,this.typeSupported=void 0,this.ISGenerated=!1,this._initPTS=null,this._initDTS=null,this.nextVideoTs=null,this.nextAudioTs=null,this.videoSampleDuration=null,this.isAudioContiguous=!1,this.isVideoContiguous=!1,this.videoTrackConfig=void 0,this.observer=e,this.config=t,this.typeSupported=r,this.ISGenerated=!1,null===iL){const e=(navigator.userAgent||"").match(/Chrome\/(\d+)/i);iL=e?parseInt(e[1]):0}if(null===iO){const e=navigator.userAgent.match(/Safari\/(\d+)/i);iO=e?parseInt(e[1]):0}}destroy(){this.config=this.videoTrackConfig=this._initPTS=this._initDTS=null}resetTimeStamp(e){let t=this._initPTS;t&&e&&e.trackId===t.trackId&&e.baseTime===t.baseTime&&e.timescale===t.timescale||this.log(`Reset initPTS: ${t?iD(t):t} > ${e?iD(e):e}`),this._initPTS=this._initDTS=e}resetNextTimestamp(){this.log("reset next timestamp"),this.isVideoContiguous=!1,this.isAudioContiguous=!1}resetInitSegment(){this.log("ISGenerated flag reset"),this.ISGenerated=!1,this.videoTrackConfig=void 0}getVideoStartPts(e){let t=!1,r=e[0].pts,i=e.reduce((e,i)=>{let n=i.pts,s=n-e;return(s<-0x100000000&&(t=!0,s=(n=iN(n,r))-e),s>0)?e:n},r);return t&&this.debug("PTS rollover detected"),i}remux(e,t,r,i,n,s,a,o){let l,u,c,d,h,f,p=n,g=n,m=e.pid>-1,y=t.pid>-1,v=t.samples.length,b=e.samples.length>0,_=a&&v>0||v>1;if((!m||b)&&(!y||_)||this.ISGenerated||a){let r;if(this.ISGenerated){var E,S,x,T;let e=this.videoTrackConfig;(e&&(t.width!==e.width||t.height!==e.height||(null==(E=t.pixelRatio)?void 0:E[0])!==(null==(S=e.pixelRatio)?void 0:S[0])||(null==(x=t.pixelRatio)?void 0:x[1])!==(null==(T=e.pixelRatio)?void 0:T[1]))||!e&&_||null===this.nextAudioTs&&b)&&this.resetInitSegment()}this.ISGenerated||(c=this.generateIS(e,t,n,s));let i=this.isVideoContiguous,a=-1;if(_&&(a=function(e){for(let t=0;t<e.length;t++)if(e[t].key)return t;return -1}(t.samples),!i&&this.config.forceKeyFrameOnDiscontinuity))if(f=!0,a>0){this.warn(`Dropped ${a} out of ${v} video samples due to a missing keyframe`);let e=this.getVideoStartPts(t.samples);t.samples=t.samples.slice(a),t.dropped+=a,g+=(t.samples[0].pts-e)/t.inputTimeScale,r=g}else -1===a&&(this.warn(`No keyframe found out of ${v} video samples`),f=!1);if(this.ISGenerated){if(b&&_){let r=this.getVideoStartPts(t.samples),i=(iN(e.samples[0].pts,r)-r)/t.inputTimeScale;p+=Math.max(0,i),g+=Math.max(0,-i)}if(b){if(e.samplerate||(this.warn("regenerate InitSegment as audio detected"),c=this.generateIS(e,t,n,s)),u=this.remuxAudio(e,p,this.isAudioContiguous,s,y||_||o===R?g:void 0),_){let r=u?u.endPTS-u.startPTS:0;t.inputTimeScale||(this.warn("regenerate InitSegment as video detected"),c=this.generateIS(e,t,n,s)),l=this.remuxVideo(t,g,i,r)}}else _&&(l=this.remuxVideo(t,g,i,0));l&&(l.firstKeyFrame=a,l.independent=-1!==a,l.firstKeyFramePTS=r)}}return this.ISGenerated&&this._initPTS&&this._initDTS&&(r.samples.length&&(h=iM(r,n,this._initPTS,this._initDTS)),i.samples.length&&(d=ij(i,n,this._initPTS))),{audio:u,video:l,initSegment:c,independent:f,text:d,id3:h}}computeInitPts(e,t,r,i){let n=Math.round(r*t),s=iN(e,n);if(s<n+t)for(this.log(`Adjusting PTS for rollover in timeline near ${(n-s)/t} ${i}`);s<n+t;)s+=0x200000000;return s-n}generateIS(e,t,r,i){let n,s,a,o=e.samples,l=t.samples,u=this.typeSupported,c={},d=this._initPTS,h=!d||i,f="audio/mp4",p=-1;if(h&&(n=s=1/0),e.config&&o.length){switch(e.timescale=e.samplerate,e.segmentCodec){case"mp3":u.mpeg?(f="audio/mpeg",e.codec=""):u.mp3&&(e.codec="mp3");break;case"ac3":e.codec="ac-3"}c.audio={id:"audio",container:f,codec:e.codec,initSegment:"mp3"===e.segmentCodec&&u.mpeg?new Uint8Array(0):iI.initSegment([e]),metadata:{channelCount:e.channelCount}},h&&(p=e.id,a=e.inputTimeScale,d&&a===d.timescale?h=!1:n=s=this.computeInitPts(o[0].pts,a,r,"audio"))}if(t.sps&&t.pps&&l.length){if(t.timescale=t.inputTimeScale,c.video={id:"main",container:"video/mp4",codec:t.codec,initSegment:iI.initSegment([t]),metadata:{width:t.width,height:t.height}},h)if(p=t.id,a=t.inputTimeScale,d&&a===d.timescale)h=!1;else{let e=this.getVideoStartPts(l),t=iN(l[0].dts,e),i=this.computeInitPts(t,a,r,"video"),o=this.computeInitPts(e,a,r,"video");s=Math.min(s,i),n=Math.min(n,o)}this.videoTrackConfig={width:t.width,height:t.height,pixelRatio:t.pixelRatio}}if(Object.keys(c).length)return this.ISGenerated=!0,h?(d&&this.warn(`Timestamps at playlist time: ${i?"":"~"}${r} ${n/a} != initPTS: ${d.baseTime/d.timescale} (${d.baseTime}/${d.timescale}) trackId: ${d.trackId}`),this.log(`Found initPTS at playlist time: ${r} offset: ${n/a} (${n}/${a}) trackId: ${p}`),this._initPTS={baseTime:n,timescale:a,trackId:p},this._initDTS={baseTime:s,timescale:a,trackId:p}):n=a=void 0,{tracks:c,initPTS:n,timescale:a,trackId:p}}remuxVideo(e,t,r,i){let n,l,u,c=e.inputTimeScale,d=e.samples,h=[],f=d.length,p=this._initPTS,g=p.baseTime*c/p.timescale,m=this.nextVideoTs,y=8,v=this.videoSampleDuration,b=1/0,_=-1/0,E=!1;if(!r||null===m){let e=g+t*c,i=d[0].pts-iN(d[0].dts,d[0].pts);iL&&null!==m&&15e3>Math.abs(e-i-(m+g))?r=!0:m=e-i-g}let S=m+g;for(let e=0;e<f;e++){let t=d[e];t.pts=iN(t.pts,S),t.dts=iN(t.dts,S),t.dts<d[e>0?e-1:e].dts&&(E=!0)}E&&d.sort(function(e,t){let r=e.dts-t.dts,i=e.pts-t.pts;return r||i}),n=d[0].dts;let x=(l=d[d.length-1].dts)-n,T=x?Math.round(x/(f-1)):v||e.inputTimeScale/30;if(r){let r=n-S,i=r>T,s=r<-1;if((i||s)&&(i?this.warn(`${(e.segmentCodec||"").toUpperCase()}: ${iC(r,!0)} ms (${r}dts) hole between fragments detected at ${t.toFixed(3)}`):this.warn(`${(e.segmentCodec||"").toUpperCase()}: ${iC(-r,!0)} ms (${r}dts) overlapping between fragments detected at ${t.toFixed(3)}`),!s||S>=d[0].pts||iL)){n=S;let e=d[0].pts-r;if(i)d[0].dts=n,d[0].pts=e;else{let t=!0;for(let i=0;i<d.length&&(!(d[i].dts>e)||!t);i++){let e=d[i].pts;if(d[i].dts-=r,d[i].pts-=r,i<d.length-1){let r=d[i+1].pts;t=r<=d[i].pts==r<=e}}}this.log(`Video: Initial PTS/DTS adjusted: ${iC(e,!0)}/${iC(n,!0)}, delta: ${iC(r,!0)} ms`)}}let w=0,A=0,R=n=Math.max(0,n);for(let e=0;e<f;e++){let t=d[e],r=t.units,i=r.length,n=0;for(let e=0;e<i;e++)n+=r[e].data.length;A+=n,w+=i,t.length=n,t.dts<R?(t.dts=R,R+=T/4|0||1):R=t.dts,b=Math.min(t.pts,b),_=Math.max(t.pts,_)}l=d[f-1].dts;let I=A+4*w+8;try{u=new Uint8Array(I)}catch(e){this.observer.emit(o.ERROR,o.ERROR,{type:s.MUX_ERROR,details:a.REMUX_ALLOC_ER
2447ROR,fatal:!1,error:e,bytes:I,reason:`fail allocating video mdat ${I}`});return}let k=new DataView(u.buffer);k.setUint32(0,I),u.set(iI.types.mdat,4);let C=!1,L=1/0,O=1/0,P=-1/0,F=-1/0;for(let e=0;e<f;e++){let t,r=d[e],n=r.units,s=0;for(let e=0,t=n.length;e<t;e++){let t=n[e],r=t.data,i=t.data.byteLength;k.setUint32(y,i),y+=4,u.set(r,y),y+=i,s+=4+i}if(e<f-1)v=d[e+1].dts-r.dts,t=d[e+1].pts-r.pts;else{let n=this.config,s=e>0?r.dts-d[e-1].dts:T;if(t=e>0?r.pts-d[e-1].pts:T,n.stretchShortVideoTrack&&null!==this.nextAudioTs){let e=Math.floor(n.maxBufferHole*c),t=(i?b+i*c:this.nextAudioTs+g)-r.pts;t>e?((v=t-s)<0?v=s:C=!0,this.log(`It is approximately ${t/90} ms to the next segment; using duration ${v/90} ms for the last video frame.`)):v=s}else v=s}let a=Math.round(r.pts-r.dts);L=Math.min(L,v),P=Math.max(P,v),O=Math.min(O,t),F=Math.max(F,t),h.push(iP(r.key,v,s,a))}if(h.length){if(iL){if(iL<70){let e=h[0].flags;e.dependsOn=2,e.isNonSync=0}}else if(iO&&F-O<P-L&&T/P<.025&&0===h[0].cts){this.warn("Found irregular gaps in sample duration. Using PTS instead of DTS to determine MP4 sample duration.");let e=n;for(let t=0,r=h.length;t<r;t++){let i=e+h[t].duration,n=e+h[t].cts;if(t<r-1){let e=i+h[t+1].cts;h[t].duration=e-n}else h[t].duration=t?h[t-1].duration:T;h[t].cts=0,e=i}}}let N=l+(v=C||!v?T:v);this.nextVideoTs=m=N-g,this.videoSampleDuration=v,this.isVideoContiguous=!0;let M={data1:iI.moof(e.sequenceNumber++,n,D(e,{samples:h})),data2:u,startPTS:(b-g)/c,endPTS:(_+v-g)/c,startDTS:(n-g)/c,endDTS:m/c,type:"video",hasAudio:!1,hasVideo:!0,nb:h.length,dropped:e.dropped};return e.samples=[],e.dropped=0,M}getSamplesPerFrame(e){switch(e.segmentCodec){case"mp3":return 1152;case"ac3":return 1536;default:return 1024}}remuxAudio(e,t,r,i,n){let l,u=e.inputTimeScale,c=e.samplerate?e.samplerate:u,d=u/c,h=this.getSamplesPerFrame(e),f=h*d,p=this._initPTS,g="mp3"===e.segmentCodec&&this.typeSupported.mpeg,m=[],y=void 0!==n,v=e.samples,b=8*!g,_=this.nextAudioTs||-1,E=p.baseTime*u/p.timescale,S=E+t*u;if(this.isAudioContiguous=r=r||v.length&&_>0&&(i&&9e3>Math.abs(S-(_+E))||Math.abs(iN(v[0].pts,S)-(_+E))<20*f),v.forEach(function(e){e.pts=iN(e.pts,S)}),!r||_<0){let e=v.length;if(e!==(v=v.filter(e=>e.pts>=0)).length&&this.warn(`Removed ${v.length-e} of ${e} samples (initPTS ${E} / ${u})`),!v.length)return;_=0===n?0:i&&!y?Math.max(0,S-E):v[0].pts-E}if("aac"===e.segmentCodec){let t=this.config.maxAudioFramesDrift;for(let r=0,i=_+E;r<v.length;r++){let n=v[r],s=n.pts,a=s-i,o=Math.abs(1e3*a/u);if(a<=-t*f&&y)0===r&&(this.warn(`Audio frame @ ${(s/u).toFixed(3)}s overlaps marker by ${Math.round(1e3*a/u)} ms.`),this.nextAudioTs=_=s-E,i=s);else if(a>=t*f&&o<1e4&&y){let t=Math.round(a/f);for(i=s-t*f;i<0&&t&&f;)t--,i+=f;0===r&&(this.nextAudioTs=_=i-E),this.warn(`Injecting ${t} audio frames @ ${((i-E)/u).toFixed(3)}s due to ${Math.round(1e3*a/u)} ms gap.`);for(let s=0;s<t;s++){let t=iR.getSilentFrame(e.parsedCodec||e.manifestCodec||e.codec,e.channelCount);t||(this.log("Unable to get silent frame for given audio codec; duplicating last frame instead."),t=n.unit.subarray()),v.splice(r,0,{unit:t,pts:i}),i+=f,r++}}n.pts=i,i+=f}}let x=null,T=null,w=0,A=v.length;for(;A--;)w+=v[A].unit.byteLength;for(let t=0,i=v.length;t<i;t++){let i=v[t],n=i.unit,u=i.pts;if(null!==T)m[t-1].duration=Math.round((u-T)/d);else{if(r&&"aac"===e.segmentCodec&&(u=_+E),x=u,!(w>0))return;w+=b;try{l=new Uint8Array(w)}catch(e){this.observer.emit(o.ERROR,o.ERROR,{type:s.MUX_ERROR,details:a.REMUX_ALLOC_ERROR,fatal:!1,error:e,bytes:w,reason:`fail allocating audio mdat ${w}`});return}g||(new DataView(l.buffer).setUint32(0,w),l.set(iI.types.mdat,4))}l.set(n,b);let c=n.byteLength;b+=c,m.push(iP(!0,h,c,0)),T=u}let R=m.length;if(!R)return;let I=m[m.length-1];_=T-E,this.nextAudioTs=_+d*I.duration;let k=g?new Uint8Array(0):iI.moof(e.sequenceNumber++,x/d,D({},e,{samples:m}));e.samples=[];let C=(x-E)/u,L=this.nextAudioTs/u,O={data1:k,data2:l,startPTS:C,endPTS:L,startDTS:C,endDTS:L,type:"audio",hasAudio:!0,hasVideo:!1,nb:R};return this.isAudioContiguous=!0,O}}function iN(e,t){let r;if(null===t)return e;for(r=t<e?-0x200000000:0x200000000;Math.abs(e-t)>0x100000000;)e+=r;return e}function iM(e,t,r,i){let n=e.samples.length;if(!n)return;let s=e.inputTimeScale;for(let a=0;a<n;a++){let n=e.samples[a];n.pts=iN(n.pts-r.baseTime*s/r.timescale,t*s)/s,n.dts=iN(n.dts-i.baseTime*s/i.timescale,t*s)/s}let a=e.samples;return e.samples=[],{samples:a}}function ij(e,t,r){let i=e.samples.length;if(!i)return;let n=e.inputTimeScale;for(let s=0;s<i;s++){let i=e.samples[s];i.pts=iN(i.pts-r.baseTime*n/r.timescale,t*n)/n}e.samples.sort((e,t)=>
2447e.pts-t.pts);let s=e.samples;return e.samples=[],{samples:s}}function i$(e,t,r=!1){return(null==e?void 0:e.start)!==void 0?(e.start+(r?e.duration:0))/e.timescale:t}function iU(e,t,r){let i=e.codec;return i&&i.length>4?i:t===W?"ec-3"===i||"ac-3"===i||"alac"===i?i:"fLaC"===i||"Opus"===i?eC(i,!1):(r.warn(`Unhandled audio codec "${i}" in mp4 MAP`),i||"mp4a"):(r.warn(`Unhandled video codec "${i}" in mp4 MAP`),i||"avc1")}try{t=self.performance.now.bind(self.performance)}catch(e){t=Date.now}let iB=[{demux:class{constructor(e,t){this.remainderData=null,this.timeOffset=0,this.config=void 0,this.videoTrack=void 0,this.audioTrack=void 0,this.id3Track=void 0,this.txtTrack=void 0,this.config=t}resetTimeStamp(){}resetInitSegment(e,t,r,i){let n=this.videoTrack=r7("video",1),s=this.audioTrack=r7("audio",1),a=this.txtTrack=r7("text",1);if(this.id3Track=r7("id3",1),this.timeOffset=0,!(null!=e&&e.byteLength))return;let o=eu(e);if(o.video){let{id:e,timescale:t,codec:r,supplemental:i}=o.video;n.id=e,n.timescale=a.timescale=t,n.codec=r,n.supplemental=i}if(o.audio){let{id:e,timescale:t,codec:r}=o.audio;s.id=e,s.timescale=t,s.codec=r}a.id=er.text,n.sampleDuration=0,n.duration=s.duration=i}resetContiguity(){this.remainderData=null}static probe(e){let t=e.byteLength;for(let r=0;r<t;){let i=es(e,r);if(i>8&&109===e[r+4]&&111===e[r+5]&&111===e[r+6]&&102===e[r+7])return!0;r=i>1?r+i:t}return!1}demux(e,t){this.timeOffset=t;let r=e,i=this.videoTrack,n=this.txtTrack;if(this.config.progressive){this.remainderData&&(r=em(this.remainderData,e));let t=function(e){let t={valid:null,remainder:null},r=el(e,["moof"]);if(r.length<2)return t.remainder=e,t;let i=r[r.length-1];return t.valid=e.slice(0,i.byteOffset-8),t.remainder=e.slice(i.byteOffset-8),t}(r);this.remainderData=t.remainder,i.samples=t.valid||new Uint8Array}else i.samples=r;let s=this.extractID3Track(i,t);return n.samples=ey(t,i),{videoTrack:i,audioTrack:this.audioTrack,id3Track:s,textTrack:this.txtTrack}}flush(){let e=this.timeOffset,t=this.videoTrack,r=this.txtTrack;t.samples=this.remainderData||new Uint8Array,this.remainderData=null;let i=this.extractID3Track(t,this.timeOffset);
2447return r.samples=ey(e,t),{videoTrack:t,audioTrack:r7(),id3Track:i,textTrack:r7()}}extractID3Track(e,t){let r=this.id3Track;return e.samples.length&&el(e.samples,["emsg"]).forEach(e=>{let n=function(e){let t=e[0],r="",n="",s=0,a=0,o=0,l=0,u=0,c=0;if(0===t){for(;"\0"!==ei(e.subarray(c,c+1));)r+=ei(e.subarray(c,c+1)),c+=1;for(r+=ei(e.subarray(c,c+1)),c+=1;"\0"!==ei(e.subarray(c,c+1));)n+=ei(e.subarray(c,c+1)),c+=1;n+=ei(e.subarray(c,c+1)),c+=1,s=es(e,12),a=es(e,16),l=es(e,20),u=es(e,24),c=28}else if(1===t){c+=4,s=es(e,c);let t=es(e,c+=4),a=es(e,c+=4);for(c+=4,i(o=0x100000000*t+a)||(o=Number.MAX_SAFE_INTEGER,$.warn("Presentation time exceeds safe integer limit and wrapped to max safe integer in parsing emsg box")),l=es(e,c),c+=4,u=es(e,c),c+=4;"\0"!==ei(e.subarray(c,c+1));)r+=ei(e.subarray(c,c+1)),c+=1;for(r+=ei(e.subarray(c,c+1)),c+=1;"\0"!==ei(e.subarray(c,c+1));)n+=ei(e.subarray(c,c+1)),c+=1;n+=ei(e.subarray(c,c+1)),c+=1}return{schemeIdUri:r,value:n,timeScale:s,presentationTime:o,presentationTimeDelta:a,eventDuration:l,id:u,payload:e.subarray(c,e.byteLength)}}(e);if(ig.test(n.schemeIdUri)){let e=im(n,t),i=0xffffffff===n.eventDuration?1/0:n.eventDuration/n.timeScale;i<=.001&&(i=1/0);let s=n.payload;r.samples.push({data:s,len:s.byteLength,dts:e,pts:e,type:r6.emsg,duration:i})}else if(this.config.enableEmsgKLVMetadata&&n.schemeIdUri.startsWith("urn:misb:KLV:bin:1910.1")){let e=im(n,t);r.samples.push({data:n.payload,len:n.payload.byteLength,dts:e,pts:e,type:r6.misbklv,duration:1/0})}}),r}demuxSampleAes(e,t,r){return Promise.reject(Error("The MP4 demuxer does not support SAMPLE-AES decryption"))}destroy(){this.config=null,this.remainderData=null,this.videoTrack=this.audioTrack=this.id3Track=this.txtTrack=void 0}}
2447,remux:class extends P{constructor(e,t,r,i){super("passthrough-remuxer",i),this.emitInitSegment=!1,this.audioCodec=void 0,this.videoCodec=void 0,this.initData=void 0,this.initPTS=null,this.initTracks=void 0,this.lastEndTime=null,this.isVideoContiguous=!1}destroy(){}resetTimeStamp(e){this.lastEndTime=null;let t=this.initPTS;t&&e&&t.baseTime===e.baseTime&&t.timescale===e.timescale||(this.initPTS=e)}resetNextTimestamp(){this.isVideoContiguous=!1,this.lastEndTime=null}resetInitSegment(e,t,r,i){this.audioCodec=t,this.videoCodec=r,this.generateInitSegment(e,i),this.emitInitSegment=!0}generateInitSegment(e,t){let{audioCodec:r,videoCodec:i}=this;if(!(null!=e&&e.byteLength)){this.initTracks=void 0,this.initData=void 0;return}let{audio:n,video:s}=this.initData=eu(e);if(t)!function(e,t){if(!e||!t)return;let r=t.keyId;r&&t.isCommonEncryption&&ep(e,(e,t)=>{let i=e.subarray(8,24);i.some(e=>0!==e)||($.log(`[eme] Patching keyId in 'enc${t?"a":"v"}>sinf>>tenc' box: ${G(i)} -> ${G(r)}`),e.set(r,8))})}(e,t);else{let e=n||s;null!=e&&e.encrypted&&this.warn(`Init segment with encrypted track with has no key ("${e.codec}")!`)}n&&(r=iU(n,W,this)),s&&(i=iU(s,Y,this));let a={};n&&s?a.audiovideo={container:"video/mp4",codec:r+","+i,supplemental:s.supplemental,encrypted:s.encrypted,initSegment:e,id:"main"}:n?a.audio={container:"audio/mp4",codec:r,encrypted:n.encrypted,initSegment:e,id:"audio"}:s?a.video={container:"video/mp4",codec:i,supplemental:s.supplemental,encrypted:s.encrypted,initSegment:e,id:"main"}:this.warn("initSegment does not contain moov or trak boxes."),this.initTracks=a}remux(e,t,i,n,s,a){var o,l;let{initPTS:u,lastEndTime:c}=this,d={audio:void 0,video:void 0,text:n,id3:i,initSegment:void 0};r(c)||(c=this.lastEndTime=s||0);let h=t.samples;if(!h.length)return d;let f={initPTS:void 0,timescale:void 0,trackId:void 0},p=this.initData;if(null!=(o=p)&&o.length||(this.generateInitSegment(h),p=this.initData),!(null!=(l=p)&&l.length))return this.warn("Failed to generate initSegment."),d;this.emitInitSegment&&(f.tracks=this.initTracks,this.emitInitSegment=!1);let g=function(e,t,i){let n={},s=el(e,["moof","traf"]);for(let e=0;e<s.length;e++){let a=s[e],o=el(a,["tfhd"])[0],l=es(o,4),u=t[l];if(!u)continue;n[l]||(n[l]={start:NaN,duration:0,sampleCount:0,timescale:u.timescale,type:u.type});let c=n[l],d=el(a,["tfdt"])[0];if(d){let e=d[0],t=es(d,4);1===e&&(0xffffffff===t?i.warn("[mp4-demuxer]: Ignoring assumed invalid signed 64-bit track fragment decode time"):(t*=0x100000000,t+=es(d,8))),r(t)&&(!r(c.start)||t<c.start)&&(c.start=t)}let h=u.default,f=es(o,0)|(null==h?void 0:h.flags),p=(null==h?void 0:h.duration)||0;8&f&&(p=2&f?es(o,12):es(o,8));let g=el(a,["trun"]),m=c.start||0,y=0,v=p;for(let e=0;e<g.length;e++){let t=g[e],r=es(t,4),i=c.sampleCount;c.sampleCount+=r;let n=1&t[3],s=4&t[3],a=1&t[2],o=2&t[2],l=4&t[2],u=8&t[2],d=8,h=r;for(n&&(d+=4),s&&r&&(1&t[d+1]||void 0!==c.keyFrameIndex||(c.keyFrameIndex=i),d+=4,a?(v=es(t,d),d+=4):v=p,o&&(d+=4),u&&(d+=4),m+=v,y+=v,h--);h--;)a?(v=es(t,d),d+=4):v=p,o&&(d+=4),l&&(1&t[d+1]||void 0!==c.keyFrameIndex||(c.keyFrameIndex=c.sampleCount-(h+1),c.keyFrameStart=m),d+=4),u&&(d+=4),m+=v,y+=v;!y&&p&&(y+=p*r)}c.duration+=y}if(!Object.keys(n).some(e=>n[e].duration)){let t=1/0,i=0,s=el(e,["sidx"]);for(let e=0;e<s.length;e++){let r=function(e){let t=[],r=e[0],i=8,n=es(e,8);i+=4;let s=0,a=0;0===r?(s=es(e,i),a=es(e,i+4),i+=8):(s=ea(e,i),a=ea(e,i+8),i+=16),i+=2;let o=e.length+a,l=en(e,i);i+=2;for(let r=0;r<l;r++){let r=i,s=es(e,r);r+=4;let a=0x7fffffff&s;if(1==(0x80000000&s)>>>31)return $.warn("SIDX has hierarchical references (not supported)"),null;let l=es(e,r);r+=4,t.push({referenceSize:a,subsegmentDuration:l,info:{duration:l/n,start:o,end:o+a-1}}),o+=a,r+=4,i=r}return{earliestPresentationTime:s,timescale:n,version:r,referencesCount:l,references:t}}(s[e]);if(null!=r&&r.references){t=Math.min(t,r.earliestPresentationTime/r.timescale);let e=r.references.reduce((e,t)=>e+t.info.duration||0,0);i=Math.max(i,e+r.earliestPresentationTime/r.timescale)}}i&&r(i)&&Object.keys(n).forEach(e=>{n[e].duration||(n[e].duration=i*n[e].timescale-n[e].start)})}return n}(h,p,this),m=p.audio?g[p.audio.id]:null,y=p.video?g[p.video.id]:null,v=i$(y,1/0),b=i$(m,1/0),_=i$(y,0,!0),E=i$(m,0,!0),S=s,x=0,T=m&&(!y||!u&&b<v||u&&u.trackId===p.audio.id),w=T?m:y;if(w){let e=w.timescale,t=w.start-s*e,r=T?p.audio.id:p.video.id;S=w.start/e,x=T?E-b:_-v,(a||!u)&&(function(e,t,r,i){if(null===e)return!0;let n=Math.max(i,1);return Math.abs(t-e.baseTime/e.timescale-r)>n}(u,S,s,x)||e!==u.timescale)&&(u&&this.warn(`Timestamps at playlist time: ${a?"":"~"}${s} ${t/e} != initPTS: ${u.baseTime/u.timescale} (${u.baseTime}/${u.timescale}) trackId: ${u.trackId}`),this.log(`Found initPTS at playlist time: ${s} offset: ${S-s} (${t}/${e}) trackId: ${r}`),u=null,f.initPTS=t,f.timescale=e,f.trackId=r)}else this.warn(`No audio or video samples found for initPTS at playlist time: ${s}`);u?(f.initPTS=u.baseTime,f.timescale=u.timescale,f.trackId=u.trackId):(f.timescale&&void 0!==f.trackId&&void 0!==f.initPTS||(this.warn("Could not set initPTS"),f.initPTS=S,f.timescale=1,f.trackId=-1),this.initPTS=u={baseTime:f.initPTS,timescale:f.timescale,trackId:f.trackId});let A=S-u.baseTime/u.timescale,R=A+x;x>0?this.lastEndTime=R:(this.warn("Duration parsed from mp4 should be greater than zero"),this.resetNextTimestamp());let I=!!p.audio,k=!!p.video,C="";I&&(C+="audio"),k&&(C+="video");let D={data1:h,startPTS:A,startDTS:A,endPTS:R,endDTS:R,type:C,hasAudio:I,hasVideo:k,nb:1,dropped:0,encrypted:!!p.audio&&p.audio.encrypted||!!p.video&&p.video.encrypted};d.audio=I&&!k?D:void 0,d.video=k?D:void 0;let L=null==y?void 0:y.sampleCount;if(L){let e=y.keyFrameIndex,t=-1!==e;D.nb=L,D.dropped=0===e||this.isVideoContiguous?0:t?e:L,D.independent=t,D.firstKeyFrame=e,t&&y.keyFrameStart&&(D.firstKeyFramePTS=(y.keyFrameStart-u.baseTime)/u.timescale),this.isVideoContiguous||(d.independent=t),this.isVideoContiguous||(this.isVideoContiguous=t),D.dropped&&this.warn(`fmp4 does not start with IDR: firstIDR ${e}/${L} dropped: ${D.dropped} start: ${D.firstKeyFramePTS||"NA"}`)}return d.initSegment=f,d.id3=iM(i,s,u,u),n.samples.length&&(d.text=ij(n,s,u)),d}}},{demux:iS,remux:iF},{demux:class extends r9{constructor(e,t){super(),this.observer=void 0,this.config=void 0,this.observer=e,this.config=t}
2447resetInitSegment(e,t,r,i){super.resetInitSegment(e,t,r,i),this._audioTrack={container:"audio/adts",type:"audio",id:2,pid:-1,sequenceNumber:0,segmentCodec:"aac",samples:[],manifestCodec:t,duration:i,inputTimeScale:9e4,dropped:0}}static probe(e,t){if(!e)return!1;let r=rQ(e,0),i=(null==r?void 0:r.length)||0;if(id(e,i))return!1;for(let r=e.length;i<r;i++)if(function(e,t){if(r0(e,t)){let r=rJ(e,t);if(t+r>=e.length)return!1;let i=rZ(e,t);if(i<=r)return!1;let n=t+i;return n===e.length||r0(e,n)}return!1}(e,i))return t.log("ADTS sync word found !"),!0;return!1}canParse(e,t){return t+5<e.length&&rX(e,t)&&rZ(e,t)<=e.length-t}appendFrame(e,t,r){r1(e,this.observer,t,r,e.manifestCodec);let i=r2(e,t,r,this.basePTS,this.frameIndex);if(i&&0===i.missing)return i}},remux:iF},{demux:class extends r9{resetInitSegment(e,t,r,i){super.resetInitSegment(e,t,r,i),this._audioTrack={container:"audio/mpeg",type:"audio",id:2,pid:-1,sequenceNumber:0,segmentCodec:"mp3",samples:[],manifestCodec:t,duration:i,inputTimeScale:9e4,dropped:0}}static probe(e){if(!e)return!1;let t=rQ(e,0),r=(null==t?void 0:t.length)||0;if(t&&11===e[r]&&119===e[r+1]&&void 0!==r8(t)&&16>=ih(e,r))return!1;for(let t=e.length;r<t;r++)if(id(e,r))return $.log("MPEG Audio sync word found !"),!0;return!1}canParse(e,t){return iu(e,t)&&4<=e.length-t}appendFrame(e,t,r){if(null!==this.basePTS)return io(e,t,r,this.basePTS,this.frameIndex)}},remux:iF}];iB.splice(2,0,{demux:class extends r9{constructor(e){super(),this.observer=void 0,this.observer=e}resetInitSegment(e,t,r,i){super.resetInitSegment(e,t,r,i),this._audioTrack={container:"audio/ac-3",type:"audio",id:2,pid:-1,sequenceNumber:0,segmentCodec:"ac3",samples:[],manifestCodec:t,duration:i,inputTimeScale:9e4,dropped:0}}canParse(e,t){return t+64<e.length}appendFrame(e,t,r){let i=ip(e,t,r,this.basePTS,this.frameIndex);if(-1!==i)return{sample:e.samples[e.samples.length-1],length:i,missing:0}}static probe(e){if(!e)return!1;let t=rQ(e,0);if(!t)return!1;let r=t.length;return!!(11===e[r]&&119===e[r+1]&&void 0!==r8(t)&&16>ih(e,r))}},remux:iF});class iV{constructor(e,t,r,i,n,s){this.asyncResult=!1,this.logger=void 0,this.observer=void 0,this.typeSupported=void 0,this.config=void 0,this.id=void 0,this.demuxer=void 0,this.remuxer=void 0,this.decrypter=void 0,this.probe=void 0,this.decryptionPromise=null,this.transmuxConfig=void 0,this.currentTransmuxState=void 0,this.observer=e,this.typeSupported=t,this.config=r,this.id=n,this.logger=s}configure(e){this.transmuxConfig=e,this.decrypter&&this.decrypter.reset()}push(e,r,i,n){var l,u;let c,d=i.transmuxing;d.executeStart=t();let h=new Uint8Array(e),{currentTransmuxState:f,transmuxConfig:p}=this;n&&(this.currentTransmuxState=n);let{contiguous:g,discontinuity:m,trackSwitch:y,accurateTimeOffset:v,timeOffset:b,initSegmentChange:_}=n||f,{audioCodec:E,videoCodec:S,defaultInitPts:x,duration:T,initSegmentData:w}=p,A=(l=h,u=r,c=null,l.byteLength>0&&(null==u?void 0:u.key)!=null&&null!==u.iv&&null!=u.method&&(c=u),c);if(A&&tP(A.method)){let e=this.getDecrypter(),r=tF(A.method);if(!e.isSync())return this.asyncResult=!0,this.decryptionPromise=e.webCryptoDecrypt(h,A.key.buffer,A.iv.buffer,r).then(e=>{let t=this.push(e,null,i);return this.decryptionPromise=null,t}),this.decryptionPromise;{let n=e.softwareDecrypt(h,A.key.buffer,A.iv.buffer,r);if(i.part>-1){let t=e.flush();n=t?t.buffer:t}if(!n)return d.executeEnd=t(),iG(i);h=new Uint8Array(n)}}let R=this.needsProbing(m,y);if(R){let e=this.configureTransmuxer(h);if(e)return this.logger.warn(`[transmuxer] ${e.message}`),this.observer.emit(o.ERROR,o.ERROR,{type:s.MEDIA_ERROR,details:a.FRAG_PARSING_ERROR,fatal:!1,error:e,reason:e.message}),d.executeEnd=t(),iG(i)}(m||y||_||R)&&this.resetInitSegment(w,E,S,T,r),(m||_||R)&&this.resetInitialTimestamp(x),g||this.resetContiguity();let I=this.transmux(h,A,b,v,i);this.asyncResult=iq(I);let k=this.currentTransmuxState;return k.contiguous=!0,k.discontinuity=!1,k.trackSwitch=!1,d.executeEnd=t(),I}flush(e){let r=e.transmuxing;r.executeStart=t();let{decrypter:i,currentTransmuxState:n,decryptionPromise:s}=this;if(s)return this.asyncResult=!0,s.then(()=>this.flush(e));let a=[],{timeOffset:o}=n;
2447if(i){let t=i.flush();t&&a.push(this.push(t.buffer,null,e))}let{demuxer:l,remuxer:u}=this;if(!l||!u){r.executeEnd=t();let i=[iG(e)];return this.asyncResult?Promise.resolve(i):i}let c=l.flush(o);return iq(c)?(this.asyncResult=!0,c.then(t=>(this.flushRemux(a,t,e),a))):(this.flushRemux(a,c,e),this.asyncResult)?Promise.resolve(a):a}flushRemux(e,r,i){let{audioTrack:n,videoTrack:s,id3Track:a,textTrack:o}=r,{accurateTimeOffset:l,timeOffset:u}=this.currentTransmuxState;this.logger.log(`[transmuxer.ts]: Flushed ${this.id} sn: ${i.sn}${i.part>-1?" part: "+i.part:""} of ${this.id===A?"level":"track"} ${i.level}`);let c=this.remuxer.remux(n,s,a,o,u,l,!0,this.id);e.push({remuxResult:c,chunkMeta:i}),i.transmuxing.executeEnd=t()}resetInitialTimestamp(e){let{demuxer:t,remuxer:r}=this;t&&r&&(t.resetTimeStamp(e),r.resetTimeStamp(e))}resetContiguity(){let{demuxer:e,remuxer:t}=this;e&&t&&(e.resetContiguity(),t.resetNextTimestamp())}resetInitSegment(e,t,r,i,n){let{demuxer:s,remuxer:a}=this;s&&a&&(s.resetInitSegment(e,t,r,i),a.resetInitSegment(e,t,r,n))}destroy(){this.demuxer&&(this.demuxer.destroy(),this.demuxer=void 0),this.remuxer&&(this.remuxer.destroy(),this.remuxer=void 0)}transmux(e,t,r,i,n){return t&&"SAMPLE-AES"===t.method?this.transmuxSampleAes(e,t,r,i,n):this.transmuxUnencrypted(e,r,i,n)}transmuxUnencrypted(e,t,r,i){let{audioTrack:n,videoTrack:s,id3Track:a,textTrack:o}=this.demuxer.demux(e,t,!1,!this.config.progressive);return{remuxResult:this.remuxer.remux(n,s,a,o,t,r,!1,this.id),chunkMeta:i}}transmuxSampleAes(e,t,r,i,n){return this.demuxer.demuxSampleAes(e,t,r).then(e=>({remuxResult:this.remuxer.remux(e.audioTrack,e.videoTrack,e.id3Track,e.textTrack,r,i,!1,this.id),chunkMeta:n}))}configureTransmuxer(e){let t,{config:r,observer:i,typeSupported:n}=this;for(let r=0,i=iB.length;r<i;r++){var s;if(null!=(s=iB[r].demux)&&s.probe(e,this.logger)){t=iB[r];break}}if(!t)return Error("Failed to find demuxer by probing fragment data");let a=this.demuxer,o=this.remuxer,l=t.remux,u=t.demux;o&&o instanceof l||(this.remuxer=new l(i,r,n,this.logger)),a&&a instanceof u||(this.demuxer=new u(i,r,n,this.logger),this.probe=u.probe)}needsProbing(e,t){return!this.demuxer||!this.remuxer||e||t}getDecrypter(){let e=this.decrypter;return e||(e=this.decrypter=new tp(this.config)),e}}let iG=e=>({remuxResult:{},chunkMeta:e});function iq(e){return"then"in e&&e.then instanceof Function}class iH{constructor(e,t,r,i,n){this.audioCodec=void 0,this.videoCodec=void 0,this.initSegmentData=void 0,this.duration=void 0,this.defaultInitPts=void 0,this.audioCodec=e,this.videoCodec=t,this.initSegmentData=r,this.duration=i,this.defaultInitPts=n||null}}class iz{constructor(e,t,r,i,n,s){this.discontinuity=void 0,this.contiguous=void 0,this.accurateTimeOffset=void 0,this.trackSwitch=void 0,this.timeOffset=void 0,this.initSegmentChange=void 0,this.discontinuity=e,this.contiguous=t,this.accurateTimeOffset=r,this.trackSwitch=i,this.timeOffset=n,this.initSegmentChange=s}}let iK=0;
2447class iW{constructor(e,t,r,i){this.error=null,this.hls=void 0,this.id=void 0,this.instanceNo=iK++,this.observer=void 0,this.frag=null,this.part=null,this.useWorker=void 0,this.workerContext=null,this.transmuxer=null,this.onTransmuxComplete=void 0,this.onFlush=void 0,this.onWorkerMessage=e=>{let t=e.data,r=this.hls;if(r&&null!=t&&t.event&&t.instanceNo===this.instanceNo)switch(t.event){case"init":{var i;let e=null==(i=this.workerContext)?void 0:i.objectURL;e&&self.URL.revokeObjectURL(e);break}case"transmuxComplete":this.handleTransmuxComplete(t.data);break;case"flush":this.onFlush(t.data);break;case"workerLog":r.logger[t.data.logType]&&r.logger[t.data.logType](t.data.message);break;default:t.data=t.data||{},t.data.frag=this.frag,t.data.part=this.part,t.data.id=this.id,r.trigger(t.event,t.data)}},this.onWorkerError=e=>{if(!this.hls)return;let t=Error(`${e.message} (${e.filename}:${e.lineno})`);this.hls.config.enableWorker=!1,this.hls.logger.warn(`Error in "${this.id}" Web Worker, fallback to inline`),this.hls.trigger(o.ERROR,{type:s.OTHER_ERROR,details:a.INTERNAL_EXCEPTION,fatal:!1,event:"demuxerWorker",error:t})};const n=e.config;this.hls=e,this.id=t,this.useWorker=!!n.enableWorker,this.onTransmuxComplete=r,this.onFlush=i;const l=(e,t)=>{(t=t||{}).frag=this.frag||void 0,e===o.ERROR&&(t.parent=this.id,t.part=this.part,this.error=t.error),this.hls.trigger(e,t)};this.observer=new rq,this.observer.on(o.FRAG_DECRYPTED,l),this.observer.on(o.ERROR,l);const u=eO(n.preferManagedMediaSource);if(this.useWorker&&"u">typeof Worker){const r=this.hls.logger;if(n.workerPath||"function"==typeof __HLS_WORKER_BUNDLE__){try{n.workerPath?(r.log(`loading Web Worker ${n.workerPath} for "${t}"`),this.workerContext=function(e){let t=rz[e];if(t)return t.clientCount++,t;let r=new self.URL(e,self.location.href).href,i={worker:new self.Worker(r),scriptURL:r,clientCount:1};return rz[e]=i,i}(n.workerPath)):(r.log(`injecting Web Worker for "${t}"`),this.workerContext=function(){let e=rz[rH];if(e)return e.clientCount++,e;let t=new self.Blob([`var exports={};var module={exports:exports};function define(f){f()};define.amd=true;(${__HLS_WORKER_BUNDLE__.toString()})(true);`],{type:"text/javascript"}),r=self.URL.createObjectURL(t),i={worker:new self.Worker(r),objectURL:r,clientCount:1};return rz[rH]=i,i}());const{worker:e}=this.workerContext;e.addEventListener("message",this.onWorkerMessage),e.addEventListener("error",this.onWorkerError),e.postMessage({instanceNo:this.instanceNo,cmd:"init",typeSupported:u,id:t,config:ez(n)})}catch(i){r.warn(`Error setting up "${t}" Web Worker, fallback to inline`,i),this.terminateWorker(),this.error=null,this.transmuxer=new iV(this.observer,u,n,"",t,e.logger)}return}}this.transmuxer=new iV(this.observer,u,n,"",t,e.logger)}reset(){if(this.frag=null,this.part=null,this.workerContext){let e=this.instanceNo;this.instanceNo=iK++;let t=this.hls.config,r=eO(t.preferManagedMediaSource);this.workerContext.worker.postMessage({instanceNo:this.instanceNo,cmd:"reset",resetNo:e,typeSupported:r,id:this.id,c
2447onfig:ez(t)})}}terminateWorker(){if(this.workerContext){let{worker:e}=this.workerContext;this.workerContext=null,e.removeEventListener("message",this.onWorkerMessage),e.removeEventListener("error",this.onWorkerError),function(e){let t=rz[e||rH];if(t&&1==t.clientCount--){let{worker:r,objectURL:i}=t;delete rz[e||rH],i&&self.URL.revokeObjectURL(i),r.terminate()}}(this.hls.config.workerPath)}}destroy(){if(this.workerContext)this.terminateWorker(),this.onWorkerMessage=this.onWorkerError=null;else{let e=this.transmuxer;e&&(e.destroy(),this.transmuxer=null)}let e=this.observer;e&&e.removeAllListeners(),this.frag=null,this.part=null,this.observer=null,this.hls=null}push(e,t,r,i,n,s,a,o,l,u){var c,d;l.transmuxing.start=self.performance.now();let{instanceNo:h,transmuxer:f}=this,p=s?s.start:n.start,g=n.decryptdata,m=this.frag,y=!(m&&n.cc===m.cc),v=!(m&&l.level===m.level),b=m?l.sn-m.sn:-1,_=this.part?l.part-this.part.index:-1,E=0===b&&l.id>1&&l.id===(null==m?void 0:m.stats.chunkCount),S=!v&&(1===b||0===b&&(1===_||E&&_<=0)),x=self.performance.now();(v||b||0===n.stats.parsing.start)&&(n.stats.parsing.start=x),s&&(_||!S)&&(s.stats.parsing.start=x);let T=!(m&&(null==(c=n.initSegment)?void 0:c.url)===(null==(d=m.initSegment)?void 0:d.url)),w=new iz(y,S,o,v,p,T);if(!S||y||T){this.hls.logger.log(`[transmuxer-interface]: Starting new transmux session for ${n.type} sn: ${l.sn}${l.part>-1?" part: "+l.part:""} ${this.id===A?"level":"track"}: ${l.level} id: ${l.id} 2448 discontinuity: ${y} 2449 trackSwitch: ${v} 2450 contiguous: ${S} 2451 accurateTimeOffset: ${o} 2452 timeOffset: ${p} 2453 initSegmentChange: ${T}`);let e=new iH(r,i,t,a,u);this.configureTransmuxer(e)}if(this.frag=n,this.part=s,this.workerContext)this.workerContext.worker.postMessage({instanceNo:h,cmd:"demux",data:e,decryptdata:g,chunkMeta:l,state:w},e instanceof ArrayBuffer?[e]:[]);else if(f){let t=f.push(e,g,l,w);iq(t)?t.then(e=>{this.handleTransmuxComplete(e)}).catch(e=>{this.transmuxerError(e,l,"transmuxer-interface push error")}):this.handleTransmuxComplete(t)}}flush(e){e.transmuxing.start=self.performance.now();let{instanceNo:t,transmuxer:r}=this;if(this.workerContext)this.workerContext.worker.postMessage({instanceNo:t,cmd:"flush",chunkMeta:e});else if(r){let t=r.flush(e);iq(t)?t.then(t=>{this.handleFlushResult(t,e)}).catch(t=>{this.transmuxerError(t,e,"transmuxer-interface flush error")}):this.handleFlushResult(t,e)}}transmuxerError(e,t,r){this.hls&&(this.error=e,this.hls.trigger(o.ERROR,{type:s.MEDIA_ERROR,details:a.FRAG_PARSING_ERROR,chunkMeta:t,frag:this.frag||void 0,part:this.part||void 0,fatal:!1,error:e,err:e,reason:r}))}handleFlushResult(e,t){e.forEach(e=>{this.handleTransmuxComplete(e)}),this.onFlush(t)}configureTransmuxer(e){let{instanceNo:t,transmuxer:r}=this;this.workerContext?this.workerContext.worker.postMessage({instanceNo:t,cmd:"configure",config:e}):r&&r.configure(e)}handleTransmuxComplete(e){e.chunkMeta.transmuxing.end=self.performance.now(),this.onTransmuxComplete(e)}}class iY extends P{constructor(e,t){super(t,e.logger),this.hls=void 0,this.canLoad=!1,this.timer=-1,this.hls=e}destroy(){this.clearTimer(),this.hls=this.log=this.warn=null}clearTimer(){-1!==this.timer&&(self.clearTimeout(this.timer),this.timer=-1)}startLoad(){this.canLoad=!0,this.loadPlaylist()}stopLoad(){this.canLoad=!1,this.clearTimer()}switchParams(e,t,r){let i=null==t?void 0:t.renditionReports;if(i){let n=-1;for(let r=0;r<i.length;r++){let s,a=i[r];try{s=new self.URL(a.URI,t.url).href}catch(e){this.warn(`Could not construct new URL for Rendition Report: ${e}`),s=a.URI||""}if(s===e){n=r;break}s===e.substring(0,s.length)&&(n=r)}if(-1!==n){let e=i[n],s=parseInt(e["LAST-MSN"])||t.lastPartSn,a=parseInt(e["LAST-PART"])||t.lastPartIndex;if(this.hls.config.lowLatencyMode){let e=Math.min(t.age-t.partTarget,t.targetduration);a>=0&&e>t.partTarget&&(a+=1)}return new eG(s,a>=0?a:void 0,r&&eV(r))}}}loadPlaylist(e){this.clearTimer()}loadingPlaylist(e,t){this.clearTimer()}shouldLoadPlaylist(e){return this.canLoad&&!!e&&!!e.url&&(!e.details||e.details.live)}getUrlWithDirectives(e,t){if(t)try{return t.addDirectives(e)}catch(e){this.warn(`Could not construct new URL with HLS Delivery Directives: ${e}`)}return e}playlistLoaded(e,t,i){let{details:n,stats:l}=t,u=self.performance.now(),c=l.loading.first?Math.max(0,u-l.loading.first):0;n.advancedDateTime=Date.now()-c;let d=this.hls.config.timelineOffset;
2453if(d!==n.appliedTimelineOffset){let e=Math.max(d||0,0);n.appliedTimelineOffset=e,n.fragments.forEach(t=>{t.setStart(t.playlistOffset+e)})}if(n.live||null!=i&&i.live){let d,f,p,g="levelInfo"in t?t.levelInfo:t.track;if(n.reloaded(i),i&&n.fragments.length>0){!function(e,t,i){let n;if(e===t)return;let s=null,a=e.fragments;for(let e=a.length-1;e>=0;e--){let t=a[e].initSegment;if(t){s=t;break}}e.fragmentHint&&delete e.fragmentHint.endPTS,function(e,t,r){let i=t.skippedSegments,n=Math.max(e.startSN,t.startSN)-t.startSN,s=+!!e.fragmentHint+(i?t.endSN:Math.min(e.endSN,t.endSN))-t.startSN,a=t.startSN-e.startSN,o=t.fragmentHint?t.fragments.concat(t.fragmentHint):t.fragments,l=e.fragmentHint?e.fragments.concat(e.fragmentHint):e.fragments;for(let d=n;d<=s;d++){let n=l[a+d],s=o[d];if(i&&!s&&n&&(s=t.fragments[d]=n),n&&s){var u,c;r(n,s,d,o);let i=n.relurl,a=s.relurl;if(i&&(u=i)!==(c=a)&&c&&rb(u)!==rb(c)){t.playlistParsingError=rd(`media sequence mismatch ${s.sn}:`,e,t,n,s);return}if(n.cc!==s.cc){t.playlistParsingError=rd(`discontinuity sequence mismatch (${n.cc}!=${s.cc})`,e,t,n,s);return}}}}(e,t,(e,i,a,o)=>{if((!t.startCC||t.skippedSegments)&&i.cc!==e.cc){let r=e.cc-i.cc;for(let e=a;e<o.length;e++)o[e].cc+=r;t.endCC=o[o.length-1].cc}r(e.startPTS)&&r(e.endPTS)&&(i.setStart(i.startPTS=e.startPTS),i.startDTS=e.startDTS,i.maxStartPTS=e.maxStartPTS,i.endPTS=e.endPTS,i.endDTS=e.endDTS,i.minEndPTS=e.minEndPTS,i.setDuration(e.endPTS-e.startPTS),i.duration&&(n=i),t.PTSKnown=t.alignedSliding=!0),e.hasStream
2453s&&(i.elementaryStreams=e.elementaryStreams),i.loader=e.loader,e.hasStats&&(i.stats=e.stats),e.initSegment&&(i.initSegment=e.initSegment,s=e.initSegment)});let o=t.fragments,l=t.fragmentHint?o.concat(t.fragmentHint):o;if(s&&l.forEach(e=>{var t;e&&(!e.initSegment||e.initSegment.relurl===(null==(t=s)?void 0:t.relurl))&&(e.initSegment=s)}),t.skippedSegments){if(t.deltaUpdateFailed=o.some(e=>!e),t.deltaUpdateFailed){i.warn("[level-helper] Previous playlist missing segments skipped in delta playlist");for(let e=t.skippedSegments;e--;)o.shift();t.startSN=o[0].sn}else{t.canSkipDateRanges&&(t.dateRanges=function(e,t,r){let{dateRanges:i,recentlyRemovedDateranges:n}=t,s=D({},e);n&&n.forEach(e=>{delete s[e]});let a=Object.keys(s).length;return a?(Object.keys(i).forEach(e=>{let t=s[e],n=new tC(i[e].attr,t);n.isValid?(s[e]=n,t||(n.tagOrder+=a)):r.warn(`Ignoring invalid Playlist Delta Update DATERANGE tag: "${ez(i[e].attr)}"`)}),s):i}(e.dateRanges,t,i));let r=e.fragments.filter(e=>e.rawProgramDateTime);if(e.hasProgramDateTime&&!t.hasProgramDateTime)for(let e=1;e<l.length;e++)null===l[e].programDateTime&&rn(l[e],l[e-1],r);t9(r,t)}t.endCC=o[o.length-1].cc}if(!t.startCC){var u;let r=rg(e,t.startSN-1);t.startCC=null!=(u=null==r?void 0:r.cc)?u:o[0].cc}(function(e,t,r){if(e&&t){let i=0;for(let n=0,s=e.length;n<=s;n++){let s=e[n],a=t[n+i];s&&a&&s.index===a.index&&s.fragment.sn===a.fragment.sn?r(s,a):i--}}})(e.partList,t.partList,(e,t)=>{t.elementaryStreams=e.elementaryStreams,t.stats=e.stats}),n?rc(t,n,n.startPTS,n.endPTS,n.startDTS,n.endDTS,i):rh(e,t),o.length&&(t.totalduration=t.edge-o[0].start),t.driftStartTime=e.driftStartTime,t.driftStart=e.driftStart;let c=t.advancedDateTime;if(t.advanced&&c){let e=t.edge;t.driftStart||(t.driftStartTime=c,t.driftStart=e),t.driftEndTime=c,t.driftEnd=e}else t.driftEndTime=e.driftEndTime,t.driftEnd=e.driftEnd,t.advancedDateTime=e.advancedDateTime;-1===t.requestScheduled&&(t.requestScheduled=e.requestScheduled)}(i,n,this);let e=n.playlistParsingError;if(e){this.warn(e);let r=this.hls;if(!r.config.ignorePlaylistParsingErrors){var h;let{networkDetails:i}=t;r.trigger(o.ERROR,{type:s.NETWORK_ERROR,details:a.LEVEL_PARSING_ERROR,fatal:!1,url:n.url,error:e,reason:e.message,level:t.level||void 0,parent:null==(h=n.fragments[0])?void 0:h.type,networkDetails:i,stats:l});return}n.playlistParsingError=null}}-1===n.requestScheduled&&(n.requestScheduled=l.loading.start);let m=this.hls.mainForwardBufferInfo,y=m?m.end-m.len:0,v=(n.edge-y)*1e3,b=rp(n,v);if(n.requestScheduled+b<u?n.requestScheduled=u:n.requestScheduled+=b,this.log(`live playlist ${e} ${n.advanced?"REFRESHED "+n.lastPartSn+"-"+n.lastPartIndex:n.updated?"UPDATED":"MISSED"}`),!this.canLoad||!n.live)return;if(n.canBlockReload&&n.endSN&&n.advanced){let e=this.hls.config.lowLatencyMode,r=n.lastPartSn,s=n.endSN,a=n.lastPartIndex,o=r===s;-1!==a?o?(f=s+1,p=e?0:a):(f=r,p=e?a+1:n.maxPartIndex):f=s+1;let l=n.age,c=l+n.ageHeader,h=Math.min(c-n.partTarget,1.5*n.targetduration);if(h>0){if(c>3*n.targetduration)this.log(`Playlist last advanced ${l.toFixed(2)}s ago. Omitting segment and part directives.`),f=void 0,p=void 0;else if(null!=i&&i.tuneInGoal&&c-n.partTarget>i.tuneInGoal)this.warn(`CDN Tune-in goal increased from: ${i.tuneInGoal} to: ${h} with playlist age: ${n.age}`),h=0;else{let e=Math.floor(h/n.targetduration);f+=e,void 0!==p&&(p+=Math.round(h%n.targetduration/n.partTarget)),this.log(`CDN Tune-in age: ${n.ageHeader}s last advanced ${l.toFixed(2)}s goal: ${h} skip sn ${e} to part ${p}`)}n.tuneInGoal=h}if(d=this.getDeliveryDirectives(n,t.deliveryDirectives,f,p),e||!o){n.requestScheduled=u,this.loadingPlaylist(g,d);return}}else(n.canBlockReload||n.canSkipUntil)&&(d=this.getDeliveryDirectives(n,t.deliveryDirectives,f,p));d&&void 0!==f&&n.canBlockReload&&(n.requestScheduled=l.loading.first+Math.max(b-2*c,b/2)),this.scheduleLoading(g,d,n)}else this.clearTimer()}scheduleLoading(e,t,r){let i=r||e.details;if(!i)return void this.loadingPlaylist(e,t);let n=self.performance.now(),s=i.requestScheduled;if(n>=s)return void this.loadingPlaylist(e,t);let a=s-n;this.log(`reload live playlist ${e.name||e.bitrate+"bps"} in ${Math.round(a)} ms`),this.clearTimer(),this.timer=self.setTimeout(()=>this.loadingPlaylist(e,t),a)}getDeliveryDirectives(e,t,r,i){let n=eV(e);return null!=t&&t.skip&&e.deltaUpdateFailed&&(r=t.msn,i=t.part,n=""),new eG(r,i,n)}checkRetry(e){let t=e.details,r=e5(e),i=e.errorAction,{action:n,retryCount:s=0,retryConfig:a}=i||{},o=!!i&&!!a&&(5===n||!i.resolved&&2===n);if(o){var l;if(s>=a.maxNumRetry)return!1;if(r&&null!=(l=e.context)&&l.deliveryDirectives)this.warn(`Retrying playlist loading ${s+1}/${a.maxNumRetry} after "${t}" without delivery-directives`),this.loadPlaylist();else{let e=e9(a,s);this.clearTimer(),this.timer=self.setTimeout(()=>this.loadPlaylist(),e),this.warn(`Retrying playlist loading ${s+1}/${a.maxNumRetry} after "${t}" in ${e}ms`)}e.levelRetry=!0,i.resolved=!0}return o}}function iQ(e,t){if(e.length!==t.length)return!1;for(let r=0;r<e.length;r++)if(!iX(e[r].attrs,t[r].attrs))return!1;return!0}function iX(e,t,r){let i=e["STABLE-RENDITION-ID"];return i&&!r?i===t["STABLE-RENDITION-ID"]:!(r||["LANGUAGE","NAME","CHARACTERISTICS","AUTOSELECT","DEFAULT","FORCED","ASSOC-LANGUAGE"]).some(r=>e[r]!==t[r])}function iJ(e,t){return t.label.toLowerCase()===e.name.toLowerCase()&&(!t.language||t.language.toLowerCase()===(e.lang||"").toLowerCase())}class iZ{constructor(e){this.tracks=void 0,this.queues={video:[],audio:[],audiovideo:[]},this.tracks=e}destroy(){this.tracks=this.queues=null}append(e,t,r){if(null===this.queues||null===this.tracks)return;let i=this.queues[t];i.push(e),1!==i.length||r||this.executeNext(t)}appendBlocker(e){return new Promise(t=>{this.append({label:"async-blocker",execute:t,onStart:()=>{},onComplete:()=>{},onError:()=>{}},e)})}prependBlocker(e){return new Promise(t=>{this.queues&&this.queues[e].unshift({label:"async-blocker-prepend",execute:t,onStart:()=>{},onComplete:()=>{},onError:()=>{}})})}removeBlockers(){null!==this.queues&&[this.queues.video,this.queues.audio,this.queues.audiovideo].forEac
2453h(e=>{var t;let r=null==(t=e[0])?void 0:t.label;("async-blocker"===r||"async-blocker-prepend"===r)&&(e[0].execute(),e.splice(0,1))})}unblockAudio(e){null===this.queues||this.queues.audio[0]===e&&this.shiftAndExecuteNext("audio")}executeNext(e){if(null===this.queues||null===this.tracks)return;let t=this.queues[e];if(t.length){let i=t[0];try{i.execute()}catch(n){var r;if(i.onError(n),null===this.queues||null===this.tracks)return;let t=null==(r=this.tracks[e])?void 0:r.buffer;null!=t&&t.updating||this.shiftAndExecuteNext(e)}}}shiftAndExecuteNext(e){null!==this.queues&&(this.queues[e].shift(),this.executeNext(e))}current(e){var t;return(null==(t=this.queues)?void 0:t[e][0])||null}toString(){let{queues:e,tracks:t}=this;return null===e||null===t?"<destroyed>":` 2454${this.list("video")} 2455${this.list("audio")} 2456${this.list("audiovideo")}}`}list(e){var t,r;return null!=(t=this.queues)&&t[e]||null!=(r=this.tracks)&&r[e]?`${e}: (${this.listSbInfo(e)}) ${this.listOps(e)}`:""}listSbInfo(e){var t;let r=null==(t=this.tracks)?void 0:t[e],i=null==r?void 0:r.buffer;return i?`SourceBuffer${i.updating?" updating":""}${r.ended?" ended":""}${r.ending?" ending":""}`:"none"}listOps(e){var t;return(null==(t=this.queues)?void 0:t[e].map(e=>e.label).join(", "))||""}}let i0=/(avc[1234]|hvc1|hev1|dvh[1e]|vp09|av01)(?:\.[^.,]+)+/,i1="HlsJsTrackRemovedError";class i2 extends Error{constructor(e){super(e),this.name=i1}}function i3(e){let t=e.querySelectorAll("source");[].slice.call(t).forEach(t=>{e.removeChild(t)})}function i4(e){return+("audio"===e)}class i5{constructor(e){this.hls=void 0,this.autoLevelCapping=void 0,this.firstLevel=void 0,this.media=void 0,this.restrictedLevels=void 0,this.timer=void 0,this.clientRect=void 0,this.streamController=void 0,this.hls=e,this.autoLevelCapping=1/0,this.firstLevel=-1,this.media=null,this.restrictedLevels=[],this.timer=void 0,this.clientRect=null,this.registerListeners()}setStreamController(e){this.streamController=e}destroy(){this.hls&&this.unregisterListener(),this.timer&&this.stopCapping(),this.media=null,this.clientRect=null,this.hls=this.streamController=null}registerListeners(){let{hls:e}=this;e.on(o.FPS_DROP_LEVEL_CAPPING,this.onFpsDropLevelCapping,this),e.on(o.MEDIA_ATTACHING,this.onMediaAttaching,this),e.on(o.MANIFEST_PARSED,this.onManifestParsed,this),e.on(o.LEVELS_UPDATED,this.onLevelsUpdated,this),e.on(o.BUFFER_CODECS,this.onBufferCodecs,this),e.on(o.MEDIA_DETACHING,this.onMediaDetaching,this)}unregisterListener(){let{hls:e}=this;e.off(o.FPS_DROP_LEVEL_CAPPING,this.onFpsDropLevelCapping,this),e.off(o.MEDIA_ATTACHING,this.onMediaAttaching,this),e.off(o.MANIFEST_PARSED,this.onManifestParsed,this),e.off(o.LEVELS_UPDATED,this.onLevelsUpdated,this),e.off(o.BUFFER_CODECS,this.onBufferCodecs,this),e.off(o.MEDIA_DETACHING,this.onMediaDetaching,this)}onFpsDropLevelCapping(e,t){let r=this.hls.levels[t.droppedLevel];this.isLevelAllowed(r)&&this.restrictedLevels.push({bitrate:r.bitrate,height:r.height,width:r.width})}onMediaAttaching(e,t){this.media=t.media instanceof HTMLVideoElement?t.media:null,this.clientRect=null,this.timer&&this.hls.levels.length&&this.detectPlayerSize()}onManifestParsed(e,t){let r=this.hls;this.restrictedLevels=[],this.firstLevel=t.firstLevel,r.config.capLevelToPlayerSize&&t.video&&this.startCapping()}onLevelsUpdated(e,t){this.timer&&r(this.autoLevelCapping)&&this.detectPlayerSize()}onBufferCodecs(e,t){this.hls.config.capLevelToPlayerSize&&t.video&&this.startCapping()}onMediaDetaching(){this.stopCapping(),this.media=null}detectPlayerSize(){if(this.media){if(this.mediaHeight<=0||this.mediaWidth<=0){this.clientRect=null;return}let e=this.hls.levels;if(e.length){let t=this.hls,r=this.getMaxLevel(e.length-1);r!==this.autoLevelCapping&&t.logger.log(`Setting autoLevelCapping to ${r}: ${e[r].height}p@${e[r].bitrate} for media ${this.mediaWidth}x${this.mediaHeight}`),t.autoLevelCapping=r,t.autoLevelEnabled&&t.autoLevelCapping>this.autoLevelCapping&&this.streamController&&this.streamController.nextLevelSwitch(),this.autoLevelCapping=t.autoLevelCapping}}}getMaxLevel(e){let t=this.hls.levels;if(!t.length)return -1;let r=t.filter((t,r)=>this.isLevelAllowed(t)&&r<=e);return this.clientRect=null,i5.getMaxLevelByMediaSize(r,this.mediaWidth,this.mediaHeight)}startCapping(){this.timer||(this.autoLevelCapping=1/0,self.clearInterval(this.timer),this.timer=self.setInterval(this.detectPlayerSize.bind(this),1e3),this.detectPlayerSize())}stopCapping(){this.restrictedLevels=[],this.firstLevel=-1,this.autoLevelCapping=1/0,this.timer&&(self.clearInterval(this.timer),this.timer=void 0)}getDimensions(){if(this.clientRect)return this.clientRect;let e=this.media,t={width:0,height:0};if(e){let r=e.getBoundingClientRect();t.width=r.width,t.height=r.height,t.width||t.height||(t.width=r.right-r.left||e.
2456width||0,t.height=r.bottom-r.top||e.height||0)}return this.clientRect=t,t}get mediaWidth(){return this.getDimensions().width*this.contentScaleFactor}get mediaHeight(){return this.getDimensions().height*this.contentScaleFactor}get contentScaleFactor(){let e=1;if(!this.hls.config.ignoreDevicePixelRatio)try{e=self.devicePixelRatio}catch(e){}return Math.min(e,this.hls.config.maxDevicePixelRatio)}isLevelAllowed(e){return!this.restrictedLevels.some(t=>e.bitrate===t.bitrate&&e.width===t.width&&e.height===t.height)}static getMaxLevelByMediaSize(e,t,r){if(!(null!=e&&e.length))return -1;let i=(e,t)=>!t||e.width!==t.width||e.height!==t.height,n=e.length-1,s=Math.max(t,r);for(let t=0;t<e.length;t+=1){let r=e[t];if((r.width>=s||r.height>=s)&&i(r,e[t+1])){n=t;break}}return n}}class i8{constructor(e,t){Array.isArray(e)&&(e=e.map(e=>e instanceof i8?e:new i8(e))),this.value=e,this.params=t}}function i6(e,t,r){return Error(`failed to serialize "${Array.isArray(e)?JSON.stringify(e):e instanceof Map?"Map{}":e instanceof Set?"Set{}":"object"==typeof e?JSON.stringify(e):String(e)}" as ${t}`,{cause:r})}class i7{constructor(e){this.description=e}}let i9="Bare Item";function ne(e){if(e<-0x38d7ea4c67fff||0x38d7ea4c67fff<e)throw i6(e,"Integer");return e.toString()}let nt=/[\x00-\x1f\x7f]+/;function nr(e){let t=e.description||e.toString().slice(7,-1);if(!1===/^([a-zA-Z*])([!#$%&'*+\-.^_`|~\w:/]*)$/.test(t))throw i6(t,"Token");return t}function ni(e){switch(typeof e){case"number":if(!r(e))throw i6(e,i9);if(Number.isInteger(e))return ne(e);let t=function e(t,r){if(t<0)return-e(-t,r);let i=Math.pow(10,r);if(!(Math.abs(t*i%1-.5)<Number.EPSILON))return Math.round(t*i)/i;{let e=Math.floor(t*i);return(e%2==0?e:e+1)/i}}(e,3);if(Math.floor(Math.abs(t)).toString().length>12)throw i6(e,"Decimal");let i=t.toString();return i.includes(".")?i:`${i}.0`;case"string":if(nt.test(e))throw i6(e,"String");return`"${e.replace(/\\/g,"\\\\").replace(/"/g,'\\"')}"`;case"symbol":return nr(e);case"boolean":if("boolean"!=typeof e)throw i6(e,"Boolean");return e?"?1":"?0";case"object":if(e instanceof Date)return`@${ne(e.getTime()/1e3)}`;if(e instanceof Uint8Array){if(!1===ArrayBuffer.isView(e))throw i6(e,"Byte Sequence");return`:${btoa(String.fromCharCode(...e))}:`}if(e instanceof i7)return nr(e);default:throw i6(e,i9)}}function nn(e){if(!1===/^[a-z*][a-z0-9\-_.*]*$/.test(e))throw i6(e,"Key");return e}function ns(e){return null==e?"":Object.entries(e).map(([e,t])=>!0===t?`;${nn(e)}`:`;${nn(e)}=${ni(t)}`).join("")}function na(e){return e instanceof i8?`${ni(e.value)}${ns(e.params)}`:ni(e)}function no(e,t){return function(e,t={whitespace:!0}){if("object"!=typeof e||null==e)throw i6(e,"Dict");let r=e instanceof Map?e.entries():Object.entries(e),i=(null==t?void 0:t.whitespace)?" ":"";return Array.from(r).map(([e,t])=>{t instanceof i8==!1&&(t=new i8(t));let r=nn(e);if(!0===t.value)r+=ns(t.params);else if(r+="=",Array.isArray(t.value)){var i;r+=(i=t,`(${i.value.map(na).join(" ")})${ns(i.params)}`)}else r+=na(t);return r}).join(`,${i}`)}(e,t)}let nl="CMCD-Object",nu="CMCD-Request",nc="CMCD-Session",nd="CMCD-Status",nh={br:nl,ab:nl,d:nl,ot:nl,tb:nl,tpb:nl,lb:nl,tab:nl,lab:nl,url:nl,pb:nu,bl:nu,tbl:nu,dl:nu,ltc:nu,mtp:nu,nor:nu,nrr:nu,rc:nu,sn:nu,sta:nu,su:nu,ttfb:nu,ttfbb:nu,ttlb:nu,cmsdd:nu,cmsds:nu,smrt:nu,df:nu,cs:nu,ts:nu,cid:nc,pr:nc,sf:nc,sid:nc,st:nc,v:nc,msd:nc,bs:nd,bsd:nd,cdn:nd,rtp:nd,bg:nd,pt:nd,ec:nd,e:nd},nf="event",np=e=>Math.round(e),ng=(e,t)=>Array.isArray(e)?e.map(e=>ng(e,t)):e instanceof i8&&"string"==typeof e.value?new i8(ng(e.value,t),e.params):(t.baseUrl&&(e=function(e,t){let r=new URL(e),i=new URL(t);if(r.origin!==i.origin)return e;let n=r.pathname.split("/").slice(1),s=i.pathname.split("/").slice(1,-1);for(;n[0]===s[0];)n.shift(),s.shift();for(;s.length;)s.shift(),n.unshift("..");return n.join("/")+r.search+r.hash}(e,t.baseUrl)),1===t.version?encodeURIComponent(e):e),nm=e=>100*np(e/100),ny={br:np,d:np,bl:nm,dl:nm,mtp:nm,nor:(e,t)=>{let r=e;return t.version>=2&&(e instanceof i8&&"string"==typeof e.value?r=new i8([e]):"string"==typeof e&&(r=[e])),ng(r,t)},rtp:nm,tb:np}
2456,nv="request",nb="response",n_=["ab","bg","bl","br","bs","bsd","cdn","cid","cs","df","ec","lab","lb","ltc","msd","mtp","pb","pr","pt","sf","sid","sn","st","sta","tab","tb","tbl","tpb","ts","v"],nE=["e"],nS=/^[a-zA-Z0-9-.]+-[a-zA-Z0-9-.]+$/;function nx(e){return nS.test(e)}let nT=["d","dl","nor","ot","rtp","su"],nw=["cmsdd","cmsds","rc","smrt","ttfb","ttfbb","ttlb","url"],nA=["bl","br","bs","cid","d","dl","mtp","nor","nrr","ot","pr","rtp","sf","sid","st","su","tb","v"];function nR(e){return nA.includes(e)||nx(e)}let nI={[nb]:function(e){return n_.includes(e)||nT.includes(e)||nw.includes(e)||nx(e)},[nf]:function(e){return n_.includes(e)||nE.includes(e)||nx(e)},[nv]:function(e){return n_.includes(e)||nT.includes(e)||nx(e)}};function nk(e,t={}){let i={};if(null==e||"object"!=typeof e)return i;let n=t.version||e.v||1,s=t.reportingMode||nv,a=1===n?nR:nI[s],o=Object.keys(e).filter(a),l=t.filter;"function"==typeof l&&(o=o.filter(l));let u=s===nb||s===nf;u&&!o.includes("ts")&&o.push("ts"),n>1&&!o.includes("v")&&o.push("v");let c=D({},ny,t.formatters),d={version:n,reportingMode:s,baseUrl:t.baseUrl};return o.sort().forEach(t=>{var s;let a=e[t],o=c[t];if("function"==typeof o&&(a=o(a,d)),"v"===t)if(1===n)return;else a=n;("pr"!=t||1!==a)&&(u&&"ts"===t&&!r(a)&&(a=Date.now()),("number"==typeof(s=a)?r(s):null!=s&&""!==s&&!1!==s)&&(["ot","sf","st","e","sta"].includes(t)&&"string"==typeof a&&(a=new i7(a)),i[t]=a))}),i}let nC=/CMCD=[^&#]+/;function nD(e,t,r,i){e&&Object.keys(t).forEach(n=>{let s=e.filter(e=>e.groupId===n).map(e=>{let s=D({},e);return s.details=void 0,s.attrs=new tk(s.attrs),s.url=s.attrs.URI=nL(e.url,e.attrs["STABLE-RENDITION-ID"],"PER-RENDITION-URIS",r),s.groupId=s.attrs["GROUP-ID"]=t[n],s.attrs["PATHWAY-ID"]=i,s});e.push(...s)})}function nL(e,t,r,i){let n,{HOST:s,PARAMS:a,[r]:o}=i;t&&(n=null==o?void 0:o[t])&&(e=n);let l=new self.URL(e);return s&&!n&&(l.host=s),a&&Object.keys(a).sort().forEach(e=>{e&&l.searchParams.set(e,a[e])}),l.href}class nO extends P{constructor(e){super("eme",e.logger),this.hls=void 0,this.config=void 0,this.media=null,this.mediaResolved=void 0,this.keyFormatPromise=null,this.keySystemAccessPromises={},this._requestLicenseFailureCount=0,this.mediaKeySessions=[],this.keyIdToKeySessionPromise={},this.mediaKeys=null,this.setMediaKeysQueue=nO.CDMCleanupPromise?[nO.CDMCleanupPromise]:[],this.bannedKeyIds={},this.onMediaEncrypted=e=>{let{initDataType:t,initData:r}=e,i=`"${e.type}" event: init data type: "${t}"`;if(this.debug(i),null!==r){if(!this.keyFormatPromise){let e=Object.keys(this.keySystemAccessPromises);e.length||(e=tX(this.config));let t=e.map(tQ).filter(e=>!!e);this.keyFormatPromise=this.getKeyFormatPromise(t)}this.keyFormatPromise.then(n=>{let s,a=tY(n);if("sinf"!==t||a!==tV)return void this.log(`Ignoring "${e.type}" event with init data type: "${t}" for selected key-system ${a}`);try{let e=ei(new Uint8Array(r)),t=tN(JSON.parse(e).sinf),i=eg(t);if(!i)throw Error("'schm' box missing or not cbcs/cenc with schi > tenc");s=new Uint8Array(i.subarray(8,24))}catch(e){this.warn(`${i} Failed to parse sinf: ${e}`);return}let o=G(s),{keyIdToKeySessionPromise:l,mediaKeySessions:u}=this,c=l[o];for(let e=0;e<u.length;e++){let i=u[e],n=i.decryptdata;if(!n.keyId)continue;let a=G(n.keyId);if(tL(s,n.keyId)||-1!==n.uri.replace(/-/g,"").indexOf(o)){if(!(c=l[a]))continue;if(n.pssh)break;delete l[a],n.pssh=new Uint8Array(r),n.keyId=s,(c=l[o]=c.then(()=>this.generateRequestWithPreferredKeySession(i,t,r,"encrypted-event-key-match"))).catch(e=>this.handleError(e));break}}c||this.handleError(Error(`Key ID ${o} not encountered in playlist. Key-system sessions ${u.length}.`))}).catch(e=>this.handleError(e))}},this.onWaitingForKey=e=>{this.log(`"${e.type}" event`)},this.hls=e,this.config=e.config,this.registerListeners()}destroy(){this.onDestroying(),this.onMediaDetached();let e=this.config;e.requestMediaKeySystemAccessFunc=null,e.licenseXhrSetup=e.licenseResponseCallback=void 0,e.drmSystems=e.drmSystemOptions={},this.hls=this.config=this.keyIdToKeySessionPromise=null,this.onMediaEncrypted=this.onWaitingForKey=null}
2456registerListeners(){this.hls.on(o.MEDIA_ATTACHED,this.onMediaAttached,this),this.hls.on(o.MEDIA_DETACHED,this.onMediaDetached,this),this.hls.on(o.MANIFEST_LOADING,this.onManifestLoading,this),this.hls.on(o.MANIFEST_LOADED,this.onManifestLoaded,this),this.hls.on(o.DESTROYING,this.onDestroying,this)}unregisterListeners(){this.hls.off(o.MEDIA_ATTACHED,this.onMediaAttached,this),this.hls.off(o.MEDIA_DETACHED,this.onMediaDetached,this),this.hls.off(o.MANIFEST_LOADING,this.onManifestLoading,this),this.hls.off(o.MANIFEST_LOADED,this.onManifestLoaded,this),this.hls.off(o.DESTROYING,this.onDestroying,this)}getLicenseServerUrl(e){let{drmSystems:t,widevineLicenseUrl:r}=this.config,i=null==t?void 0:t[e];return i?i.licenseUrl:e===tq&&r?r:void 0}getLicenseServerUrlOrThrow(e){let t=this.getLicenseServerUrl(e);if(void 0===t)throw Error(`no license server URL configured for key-system "${e}"`);return t}getServerCertificateUrl(e){let{drmSystems:t}=this.config,r=null==t?void 0:t[e];if(r)return r.serverCertificateUrl;this.log(`No Server Certificate in config.drmSystems["${e}"]`)}attemptKeySystemAccess(e){let t=this.hls.levels,r=(e,t,r)=>!!e&&r.indexOf(e)===t,i=t.map(e=>e.audioCodec).filter(r),n=t.map(e=>e.videoCodec).filter(r);return i.length+n.length===0&&n.push("avc1.42e01e"),new Promise((t,r)=>{let o=e=>{let l=e.shift();this.getMediaKeysPromise(l,i,n).then(e=>t({keySystem:l,mediaKeys:e})).catch(t=>{e.length?o(e):t instanceof nF?r(t):r(new nF({type:s.KEY_SYSTEM_ERROR,details:a.KEY_SYSTEM_NO_ACCESS,error:t,fatal:!0},t.message))})};o(e)})}requestMediaKeySystemAccess(e,t){let{requestMediaKeySystemAccessFunc:r}=this.config;if("function"!=typeof r){let e=`Configured requestMediaKeySystemAccess is not a function ${r}`;return null===tJ&&"http:"===self.location.protocol&&(e=`navigator.requestMediaKeySystemAccess is not available over insecure protocol ${location.protocol}`),Promise.reject(Error(e))}return r(e,t)}getMediaKeysPromise(e,t,r){var i;let n=function(e,t,r,i){var n,s,a,o;let l;switch(e){case tV:l=["cenc","sinf"];break;case tq:case tG:l=["cenc"];break;case tB:l=["cenc","keyids"];break;default:throw Error(`Unknown key-system: ${e}`)}return n=l,s=t,a=r,[{initDataTypes:n,persistentState:(o=i).persistentState||"optional",distinctiveIdentifier:o.distinctiveIdentifier||"optional",sessionTypes:o.sessionTypes||[o.sessionType||"temporary"],audioCapabilities:s.map(e=>({contentType:`audio/mp4; codecs=${e}`,robustness:o.audioRobustness||"",encryptionScheme:o.audioEncryptionScheme||null})),videoCapabilities:a.map(e=>({contentType:`video/mp4; codecs=${e}`,robustness:o.videoRobustness||"",encryptionScheme:o.videoEncryptionScheme||null}))}]}(e,t,r,this.config.drmSystemOptions||{}),s=this.keySystemAccessPromises[e],a=null==(i=s)?void 0:i.keySystemAccess;if(!a){this.log(`Requesting encrypted media "${e}" key-system access with config: ${ez(n)}`),a=this.requestMediaKeySystemAccess(e,n);let t=s=this.keySystemAccessPromises[e]={keySystemAccess:a};return a.catch(t=>{this.log(`Failed to obtain access to key-system "${e}": ${t}`)}),a.then(r=>{this.log(`Access for key-system "${r.keySystem}" obtained`);let i=this.fetchServerCertificate(e);this.log(`Create media-keys for "${e}"`);let n=t.mediaKeys=r.createMediaKeys().then(r=>(this.log(`Media-keys created for "${e}"`),t.hasMediaKeys=!0,i.then(t=>t?this.setMediaKeysServerCertificate(r,e,t):r)));return n.catch(t=>{this.error(`Failed to create media-keys for "${e}"}: ${t}`)}),n})}return a.then(()=>s.mediaKeys)}createMediaKeySessionContext({decryptdata:e,keySystem:t,mediaKeys:r}){this.log(`Creating key-system session "${t}" keyId: ${G(e.keyId||[])} keyUri: ${e.uri}`);let i=r.createSession(),n={decryptdata:e,keySystem:t,mediaKeys:r,mediaKeysSession:i,keyStatus:"status-pending"};return this.mediaKeySessions.push(n),n}renewKeySession(e){let t=e.decryptdata;if(t.pssh){let r=this.createMediaKeySessionContext(e),i=nP(t);this.keyIdToKeySessionPromise[i]=this.generateRequestWithPreferredKeySession(r,"cenc",t.pssh.buffer,"expired")}else this.warn("Could not renew expired session. Missing pssh initData.");this.removeSession(e)}updateKeySession(e,t){let r=e.mediaKeysSession;return this.log(`Updating key-session "${r.sessionId}" for keyId ${G(e.decryptdata.keyId||[])} 2457 } (data length: ${t.byteLength})`),r.update(t)}getSelectedKeySystemFormats(){return Object.keys(this.keySystemAccessPromises).map(e=>({keySystem:e,hasMediaKeys:this.keySystemAccessPromises[e].hasMediaKeys})).filter(({hasMediaKeys:e})=>!!e).map(({keySystem:e})=>tQ(e)).filter(e=>!!e)}getKeySystemAccess(e){return this.getKeySystemSelectionPromise(e).then(({keySystem:e,mediaKeys:t})=>this.attemptSetMediaKeys(e,t))}selectKeySystem(e){return new Promise((t,r)=>{this.getKeySystemSelectionPromise(e).then(({keySystem:e})=>{let i=tQ(e);i?t(i):r(Error(`Unable to find format for key-system "${e}"`))}).catch(r)})}selectKeySystemFormat(e){let t=Object.keys(e.levelkeys||{});return this.keyFormatPromise||(this.log(`Selecting key-system from fragment (sn: ${e.sn} ${e.type}: ${e.level}) key formats ${t.join(", ")}`),this.keyFormatPromise=this.getKeyFormatPromise(t)),this.keyFormatPromise}getKeyFormatPromise(e){let t=tX(this.config),r=e.map(tY).filter(e=>!!e&&-1!==t.indexOf(e));return this.selectKeySystem(r)}getKeyStatus(e){let{mediaKeySessions:t}=this;for(let n=0;n<t.length;n++){var r,i;let s=(r=e,i=t[n],r.keyId&&i.mediaKeysSession.keyStatuses.has(r.keyId)?i.mediaKeysSession.keyStatuses.get(r.keyId):r.matches(i.decryptdata)?i.keyStatus:void 0);if(s)return s}}loadKey(e){let t=e.keyInfo.decryptdata,r=nP(t),i=this.bannedKeyIds[r];if(i||"internal-error"===this.getKeyStatus(t)){let r=nN(i||"internal-error",t);return this.handleError(r,e.frag),Promise.reject(r)}let n=`(keyId: ${r} format: "${t.keyFormat}" method: ${t.method} uri: ${t.uri})`;this.log(`Starting session for key ${n}`);let s=this.keyIdToKeySessionPromise[r];if(!s){let i=this.getKeySystemForKeyPromise(t).then(({keySystem:r,mediaKeys:i})=>(this.throwIfDestroyed(),this.log(`Handle encrypted media sn: ${e.frag.sn} ${e.frag.type}: ${e.frag.level} using key ${n}`),this.attemptSetMediaKeys(r,i).then(()=>(this.throwIfDestroyed(),this.createMediaKeySessionContext({keySystem:r,mediaKeys:i,decryptdata:t}))))).then(e=>{let r=t.pssh?t.pssh.buffer:null;return this.generateRequestWithPreferredKeySession(e,"cenc",r,"playlist-key")});return i.catch(t=>this.handleError(t,e.frag)),this.keyIdToKeySessionPromise[r]=i,i}return s.catch(r=>{if(r instanceof nF){let i=O({},r.data);"internal-error"===this.getKeyStatus(t)&&(i.decryptdata=t);let n=new nF(i,r.message);this.handleError(n,e.frag)}}),s}throwIfDestroyed(e="Invalid state"){if(!this.hls)throw Error("invalid state")}handleError(e,t){if(this.hls)if(e instanceof nF){t&&(e.data.frag=t);let r=e.data.decryptdata;this.error(`${e.message}${r?` (${G(r.keyId||[])})`:""}`),this.hls.trigger(o.ERROR,e.data)}else this.error(e.message),this.hls.trigger(o.ERROR,{type:s.KEY_SYSTEM_ERROR,details:a.KEY_SYSTEM_NO_KEYS,error:e,fatal:!0})}
2457getKeySystemForKeyPromise(e){let t=nP(e),r=this.keyIdToKeySessionPromise[t];if(!r){let t=tY(e.keyFormat),r=t?[t]:tX(this.config);return this.attemptKeySystemAccess(r)}return r}getKeySystemSelectionPromise(e){if(e.length||(e=tX(this.config)),0===e.length)throw new nF({type:s.KEY_SYSTEM_ERROR,details:a.KEY_SYSTEM_NO_CONFIGURED_LICENSE,fatal:!0},`Missing key-system license configuration options ${ez({drmSystems:this.config.drmSystems})}`);return this.attemptKeySystemAccess(e)}attemptSetMediaKeys(e,t){if(this.mediaResolved=void 0,this.mediaKeys===t)return Promise.resolve();let r=this.setMediaKeysQueue.slice();this.log(`Setting media-keys for "${e}"`);let i=Promise.all(r).then(()=>this.media?this.media.setMediaKeys(t):new Promise((e,r)=>{this.mediaResolved=()=>{if(this.mediaResolved=void 0,!this.media)return r(Error("Attempted to set mediaKeys without media element attached"));this.mediaKeys=t,this.media.setMediaKeys(t).then(e).catch(r)}}));return this.mediaKeys=t,this.setMediaKeysQueue.push(i),i.then(()=>{this.log(`Media-keys set for "${e}"`),r.push(i),this.setMediaKeysQueue=this.setMediaKeysQueue.filter(e=>-1===r.indexOf(e))})}generateRequestWithPreferredKeySession(e,t,r,i){var n;let o=null==(n=this.config.drmSystems)||null==(n=n[e.keySystem])?void 0:n.generateRequest;if(o)try{let i=o.call(this.hls,t,r,e);if(!i)throw Error("Invalid response from configured generateRequest filter");t=i.initDataType,r=i.initData?i.initData:null,e.decryptdata.pssh=r?new Uint8Array(r):null}catch(e){if(this.warn(e.message),this.hls&&this.hls.config.debug)throw e}if(null===r)return this.log(`Skipping key-session request for "${i}" (no initData)`),Promise.resolve(e);let l=nP(e.decryptdata),u=e.decryptdata.uri;this.log(`Generating key-session request for "${i}" keyId: ${l} URI: ${u} (init data type: ${t} length: ${r.byteLength})`);let c=new rq,d=e._onmessage=t=>{let r=e.mediaKeysSession;if(!r)return void c.emit("error",Error("invalid state"));let{messageType:i,message:n}=t;this.log(`"${i}" message event for session "${r.sessionId}" message size: ${n.byteLength}`),"license-request"===i||"license-renewal"===i?this.renewLicense(e,n).catch(e=>{c.eventNames().length?c.emit("error",e):this.handleError(e)}):"license-release"===i?e.keySystem===tV&&this.updateKeySession(e,tM("acknowledged")).then(()=>this.removeSession(e)).catch(e=>this.handleError(e)):this.warn(`unhandled media key message type "${i}"`)},h=(e,t)=>{let r;t.keyStatus=e,e.startsWith("usable")?c.emit("resolved"):"internal-error"===e||"output-restricted"===e||"output-downscaled"===e?r=nN(e,t.decryptdata):"expired"===e?r=Error(`key expired (keyId: ${l})`):"released"===e?r=Error("key released"):"status-pending"===e||this.warn(`unhandled key status change "${e}" (keyId: ${l})`),r&&(c.eventNames().length?c.emit("error",r):this.handleError(r))},f=e._onkeystatuseschange=t=>{if(!e.mediaKeysSession)return void c.emit("error",Error("invalid state"));let r=this.getKeyStatuses(e);if(!Object.keys(r).some(e=>"status-pending"!==r[e]))return;if("expired"===r[l]){this.log(`Expired key ${ez(r)} in key-session "${e.mediaKeysSession.sessionId}"`),this.renewKeySession(e);return}let i=r[l];if(i)h(i,e);else{var n;e.keyStatusTimeouts||(e.keyStatusTimeouts={}),(n=e.keyStatusTimeouts)[l]||(n[l]=self.setTimeout(()=>{if(!e.mediaKeysSession||!this.mediaKeys)return;let t=this.getKeyStatus(e.decryptdata);if(t&&"status-pending"!==t)return this.log(`No status for keyId ${l} in key-session "${e.mediaKeysSession.sessionId}". Using session key-status ${t} from other session.`),h(t,e);this.log(`key status for ${l} in key-session "${e.mediaKeysSession.sessionId}" timed out after 1000ms`),h(i="internal-error",e)},1e3)),this.log(`No status for keyId ${l} (${ez(r)}).`)}};rw(e.mediaKeysSession,"message",d),rw(e.mediaKeysSession,"keystatuseschange",f);let p=new Promise((e,t)=>{c.on("error",t),c.on("resolved",e)});return e.mediaKeysSession.generateRequest(t,r).then(()=>{this.log(`Request generated for key-session "${e.mediaKeysSession.sessionId}" keyId: ${l} URI: ${u}`)}).catch(t=>{throw new nF({type:s.KEY_SYSTEM_ERROR,details:a.KEY_SYSTEM_NO_SESSION,error:t,decryptdata:e.decryptdata,fatal:!1},`Error generating key-session request: ${t}`)}).then(()=>p).catch(t=>(c.removeAllListeners(),this.removeSession(e).then(()=>{throw t}))).then(()=>(c.removeAllListeners(),e))}getKeyStatuses(e){let t={};
2457return e.mediaKeysSession.keyStatuses.forEach((r,i)=>{if("string"==typeof i&&"object"==typeof r){let e=i;i=r,r=e}let n="buffer"in i?new Uint8Array(i.buffer,i.byteOffset,i.byteLength):new Uint8Array(i);e.keySystem===tG&&16===n.length&&(t[G(n)]=r,tj(n));let s=G(n);"internal-error"===r&&(this.bannedKeyIds[s]=r),this.log(`key status change "${r}" for keyStatuses keyId: ${s} key-session "${e.mediaKeysSession.sessionId}"`),t[s]=r}),t}fetchServerCertificate(e){let t=this.config,r=new t.loader(t),i=this.getServerCertificateUrl(e);return i?(this.log(`Fetching server certificate for "${e}"`),new Promise((n,o)=>{let l={responseType:"arraybuffer",url:i},u=t.certLoadPolicy.default,c={loadPolicy:u,timeout:u.maxLoadTimeMs,maxRetry:0,retryDelay:0,maxRetryDelay:0};r.load(l,c,{onSuccess:(e,t,r,i)=>{n(e.data)},onError:(t,r,n,u)=>{o(new nF({type:s.KEY_SYSTEM_ERROR,details:a.KEY_SYSTEM_SERVER_CERTIFICATE_REQUEST_FAILED,fatal:!0,networkDetails:n,response:O({url:l.url,data:void 0},t)},`"${e}" certificate request failed (${i}). Status: ${t.code} (${t.text})`))},onTimeout:(t,r,n)=>{o(new nF({type:s.KEY_SYSTEM_ERROR,details:a.KEY_SYSTEM_SERVER_CERTIFICATE_REQUEST_FAILED,fatal:!0,networkDetails:n,response:{url:l.url,data:void 0}},`"${e}" certificate request timed out (${i})`))},onAbort:(e,t,r)=>{o(Error("aborted"))}})})):Promise.resolve()}setMediaKeysServerCertificate(e,t,r){return new Promise((i,n)=>{e.setServerCertificate(r).then(n=>{this.log(`setServerCertificate ${n?"success":"not supported by CDM"} (${r.byteLength}) on "${t}"`),i(e)}).catch(e=>{n(new nF({type:s.KEY_SYSTEM_ERROR,details:a.KEY_SYSTEM_SERVER_CERTIFICATE_UPDATE_FAILED,error:e,fatal:!0},e.message))})})}renewLicense(e,t){return this.requestLicense(e,new Uint8Array(t)).then(t=>this.updateKeySession(e,new Uint8Array(t)).catch(t=>{throw new nF({type:s.KEY_SYSTEM_ERROR,details:a.KEY_SYSTEM_SESSION_UPDATE_FAILED,decryptdata:e.decryptdata,error:t,fatal:!1},t.message)}))}unpackPlayReadyKeyMessage(e,t){let r=String.fromCharCode.apply(null,new Uint16Array(t.buffer));if(!r.includes("PlayReadyKeyMessage"))return e.setRequestHeader("Content-Type","text/xml; charset=utf-8"),t;let i=new DOMParser().parseFromString(r,"application/xml"),n=i.querySelectorAll("HttpHeader");if(n.length>0){let t;for(let r=0,i=n.length;r<i;r++){var s,a;let i=null==(s=(t=n[r]).querySelector("name"))?void 0:s.textContent,o=null==(a=t.querySelector("value"))?void 0:a.textContent;i&&o&&e.setRequestHeader(i,o)}}let o=i.querySelector("Challenge"),l=null==o?void 0:o.textContent;if(!l)throw Error("Cannot find <Challenge> in key message");return tM(atob(l))}setupLicenseXHR(e,t,r,i){let n=this.config.licenseXhrSetup;return n?Promise.resolve().then(()=>{if(!r.decryptdata)throw Error("Key removed");return n.call(this.hls,e,t,r,i)}).catch(s=>{if(!r.decryptdata)throw s;return e.open("POST",t,!0),n.call(this.hls,e,t,r,i)}).then(r=>(e.readyState||e.open("POST",t,!0),{xhr:e,licenseChallenge:r||i})):(e.open("POST",t,!0),Promise.resolve({xhr:e,licenseChallenge:i}))}requestLicense(e,t){let r=this.config.keyLoadPolicy.default;return new Promise((i,n)=>{let o=this.getLicenseServerUrlOrThrow(e.keySystem);this.log(`Sending license request to URL: ${o}`);let l=new XMLHttpRequest;l.responseType="arraybuffer",l.onreadystatechange=()=>{if(!this.hls||!e.mediaKeysSession)return n(Error("invalid state"));if(4===l.readyState)if(200===l.status){this._requestLicenseFailureCount=0;let t=l.response;this.log(`License received ${t instanceof ArrayBuffer?t.byteLength:t}`);let r=this.config.licenseResponseCallback;if(r)try{t=r.call(this.hls,l,o,e)}catch(e){this.error(e)}i(t)}else{let u=r.errorRetry,c=u?u.maxNumRetry:0;if(this._requestLicenseFailureCount++,this._requestLicenseFailureCount>c||l.status>=400&&l.status<500)n(new nF({type:s.KEY_SYSTEM_ERROR,details:a.KEY_SYSTEM_LICENSE_REQUEST_FAILED,decryptdata:e.decryptdata,fatal:!0,networkDetails:l,response:{url:o,data:void 0,code:l.status,text:l.statusText}},`License Request XHR failed (${o}). Status: ${l.status} (${l.statusText})`));else{let r=c-this._requestLicenseFailureCount+1;this.warn(`Retrying license request, ${r} attempts left`),this.requestLicense(e,t).then(i,n)}}},e.licenseXhr&&e.licenseXhr.readyState!==XMLHttpRequest.DONE&&e.licenseXhr.abort(),e.licenseXhr=l,this.setupLicenseXHR(l,o,e,t).then(({xhr:t,licenseChallenge:r})=>{e.keySystem==tG&&(r=this.unpackPlayReadyKeyMessage(t,r)),t.send(r)}).catch(n)})}onDestroying(){this.unregisterListeners(),this._clear()}onMediaAttached(e,t){if(!this.config.emeEnabled)return;let r=t.media;this.media=r,rw(r,"encrypted",this.onMediaEncrypted),rw(r,"waitingforkey",this.onWaitingForKey);let i=this.mediaResolved;i?i():this.mediaKeys=r.mediaKeys}onMediaDetached(){let e=this.media;e&&(rA(e,"encrypted",this.onMediaEncrypted),rA(e,"waitingforkey",this.onWaitingForKey),this.media=null,this.mediaKeys=null)}_clear(){var e;this._requestLicenseFailureCount=0,this.keyIdToKeySessionPromise={},this.bannedKeyIds={};let t=this.mediaResolved;if(t&&t(),!this.mediaKeys&&!this.mediaKeySessions.length)return;let r=this.media,i=this.mediaKeySessions.slice();this.mediaKeySessions=[],this.mediaKeys=null,t1.clearKeyUriToKeyIdMap();let n=i.length;nO.CDMCleanupPromise=Promise.all(i.map(e=>this.removeSession(e)).concat((null==r||null==(e=r.setMediaKeys(null))?void 0:e.catch(e=>
2457{this.log(`Could not clear media keys: ${e}`),this.hls&&this.hls.trigger(o.ERROR,{type:s.OTHER_ERROR,details:a.KEY_SYSTEM_DESTROY_MEDIA_KEYS_ERROR,fatal:!1,error:Error(`Could not clear media keys: ${e}`)})}))||Promise.resolve())).catch(e=>{this.log(`Could not close sessions and clear media keys: ${e}`),this.hls&&this.hls.trigger(o.ERROR,{type:s.OTHER_ERROR,details:a.KEY_SYSTEM_DESTROY_CLOSE_SESSION_ERROR,fatal:!1,error:Error(`Could not close sessions and clear media keys: ${e}`)})}).then(()=>{n&&this.log("finished closing key sessions and clearing media keys")})}onManifestLoading(){this._clear()}onManifestLoaded(e,{sessionKeys:t}){if(t&&this.config.emeEnabled&&!this.keyFormatPromise){let e=t.reduce((e,t)=>(-1===e.indexOf(t.keyFormat)&&e.push(t.keyFormat),e),[]);this.log(`Selecting key-system from session-keys ${e.join(", ")}`),this.keyFormatPromise=this.getKeyFormatPromise(e)}}removeSession(e){let{mediaKeysSession:t,licenseXhr:r,decryptdata:i}=e;if(t){var n;this.log(`Remove licenses and keys and close session "${t.sessionId}" keyId: ${G((null==i?void 0:i.keyId)||[])}`),e._onmessage&&(t.removeEventListener("message",e._onmessage),e._onmessage=void 0),e._onkeystatuseschange&&(t.removeEventListener("keystatuseschange",e._onkeystatuseschange),e._onkeystatuseschange=void 0),r&&r.readyState!==XMLHttpRequest.DONE&&r.abort(),e.mediaKeysSession=e.decryptdata=e.licenseXhr=void 0;let l=this.mediaKeySessions.indexOf(e);l>-1&&this.mediaKeySessions.splice(l,1);let{keyStatusTimeouts:u}=e;u&&Object.keys(u).forEach(e=>self.clearTimeout(u[e]));let{drmSystemOptions:c}=this.config;return(c&&("persistent-license"===c.sessionType||null!=(n=c.sessionTypes)&&n.some(e=>"persistent-license"===e))?new Promise((e,r)=>{self.setTimeout(()=>r(Error("MediaKeySession.remove() timeout")),8e3),t.remove().then(e).catch(r)}):Promise.resolve()).catch(e=>{this.log(`Could not remove session: ${e}`),this.hls&&this.hls.trigger(o.ERROR,{type:s.OTHER_ERROR,details:a.KEY_SYSTEM_DESTROY_REMOVE_SESSION_ERROR,fatal:!1,error:Error(`Could not remove session: ${e}`)})}).then(()=>t.close()).catch(e=>{this.log(`Could not close session: ${e}`),this.hls&&this.hls.trigger(o.ERROR,{type:s.OTHER_ERROR,details:a.KEY_SYSTEM_DESTROY_CLOSE_SESSION_ERROR,fatal:!1,error:Error(`Could not close session: ${e}`)})})}return Promise.resolve()}}function nP(e){if(!e)throw Error("Could not read keyId of undefined decryptdata");if(null===e.keyId)throw Error("keyId is null");return G(e.keyId)}nO.CDMCleanupPromise=void 0;class nF extends Error{constructor(e,t){super(t),this.data=void 0,e.error||(e.error=Error(t)),this.data=e,e.err=e.error}}function nN(e,t){let r="output-restricted"===e,i=r?a.KEY_SYSTEM_STATUS_OUTPUT_RESTRICTED:a.KEY_SYSTEM_STATUS_INTERNAL_ERROR;return new nF({type:s.KEY_SYSTEM_ERROR,details:i,fatal:!1,decryptdata:t},r?"HDCP level output restricted":`key status changed to "${e}"`)}function nM(e,t){let r;try{r=new Event("addtrack")}catch(e){(r=document.createEvent("Event")).initEvent("addtrack",!1,!1)}r.track=e,t.dispatchEvent(r)}function nj(e,t){let r=e.mode;if("disabled"===r&&(e.mode="hidden"),e.cues&&!e.cues.getCueById(t.id))try{if(e.addCue(t),!e.cues.getCueById(t.id))throw Error(`addCue is failed for: ${t}`)}catch(r){$.debug(`[texttrack-utils]: ${r}`);try{let r=new self.TextTrackCue(t.startTime,t.endTime,t.text);r.id=t.id,e.addCue(r)}catch(e){$.debug(`[texttrack-utils]: Legacy TextTrackCue fallback failed: ${e}`)}}"disabled"===r&&(e.mode=r)}function n$(e,t){let r=e.mode;if("disabled"===r&&(e.mode="hidden"),e.cues)for(let r=e.cues.length;r--;)t&&e.cues[r].removeEventListener("enter",t),e.removeCue(e.cues[r]);"disabled"===r&&(e.mode=r)}function nU(e,t,r,i){let n=e.mode;if("disabled"===n&&(e.mode="hidden"),e.cues&&e.cues.length>0){let n=function(e,t,r){let i=[],n=function(e,t){let r;if(t<=e[0].startTime)return 0;let i=e.length-1;if(t>e[i].endTime)return -1;let n=0,s=i;for(;n<=s;)if(t<e[r=Math.floor((s+n)/2)].startTime)s=r-1;else{if(!(t>e[r].startTime)||!(n<i))return r;n=r+1}return e[n].startTime-t<t-e[s].startTime?n:s}(e,t);if(n>-1)for(let s=n,a=e.length;s<a;s++){let n=e[s];if(n.startTime>=t&&n.endTime<=r)i.push(n);else if(n.startTime>r)break}return i}(e.cues,t,r);for(let t=0;t<n.length;t++)(!i||i(n[t]))&&e.removeCue(n[t])}"disabled"===n&&(e.mode=n)}function nB(e){let t=[];for(let r=0;r<e.length;r++){let i=e[r];("subtitles"===i.kind||"captions"===i.kind)&&i.label&&t.push(e[r])}return t}function nV(e){let t=5381,r=e.length;for(;r;)t=33*t^e.charCodeAt(--r);return(t>>>0).toString()}let nG=((m={})[m.Point=0]="Point",m[m.Range=1]="Range",m);class nq{constructor(e,t){this.base=void 0,this._duration=null,this._timelineStart=null,this.appendInPlaceDisabled=void 0,this.appendInPlaceStarted=void 0,this.dateRange=void 0,this.hasPlayed=!1,this.cumulativeDuration=0,this.resumeOffset=NaN,this.playoutLimit=NaN,this.restrictions={skip:!1,jump:!1},this.snapOptions={out:!1,in:!1},this.assetList=[],this.assetListLoader=void 0,this.assetListResponse=null,this.resumeAnchor=void 0,this.error=void 0,this.resetOnResume=void 0,this.base=t,this.dateRange=e,this.setDateRange(e)}setDateRange(e){this.dateRange=e,this.resumeOffset=e.attr.optionalFloat("X-RESUME-OFFSET",this.resumeOffset),this.playoutLimit=e.attr.optionalFloat("X-PLAYOUT-LIMIT",this.playoutLimit),this.restrictions=e.attr.enumeratedStringList("X-RESTRICT",this.restrictions),this.snapOptions=e.attr.enumeratedStringList("X-SNAP",this.snapOptions)}reset(){var e;this.appendInPlaceStarted=!1,null==(e=this.assetListLoader)||e.destroy(),this.assetListLoader=void 0,this.supplementsPrimary||(this.assetListResponse=null,this.assetList=[],this._duration=null)}isAssetPastPlayoutLimit(e){var t;if(e>0&&e>=this.assetList.length)return!0;let r=this.playoutLimit;return!(e<=0||isNaN(r))&&(0===r||((null==(t=this.assetList[e])?void 0:t.startOffset)||0)>r)}findAssetIndex(e){return this.assetList.indexOf(e)}get identifier(){return this.dateRange.id}get startDate(){return this.dateRange.startDate}get startTime(){let e=this.dateRange.startTime;if(this.snapOptions.out){let t=this.dateRange.tagAnchor;if(t)return nH(e,t)}return e}get startOffset(){return this.cue.pre?0:this.startTime}get startIsAligned(){if(0===this.startTime||this.snapOptions.out)return!0;let e=this.dateRange.tagAnchor;if(e){let t=this.dateRange.startTime,r=nH(t,e);return t-r<.1}return!1}get resumptionOffset(){let e=this.resumeOffset,t=r(e)?e:this.duration;return this.cumulativeDuration+t}get resumeTime(){let e=this.startOffset+this.resumptionOffset;if(this.snapOptions.in){let t=this.resumeAnchor;if(t)return nH(e,t)}return e}get appendInPlace(){return!!this.appendInPlaceStarted||!this.appendInPlaceDisabled&&!!(!this.cue.once&&!this.cue.pre&&this.startIsAligned&&(isNaN(this.playoutLimit)&&isNaN(this.resumeOffset)||this.resumeOffset&&this.duration&&.025>Math.abs(this.resumeOffset-this.duration)))}set appendInPlace(e){if(this.appendInPlaceStarted){this.resetOnResume=!e;return}this.appendInPlaceDisabled=!e}get timelineStart(){return null!==this._timelineStart?this._timelineStart:this.startTime}set timelineStart(e){this._timelineStart=e}get duration(){let e,t=this.playoutLimit;return e=null!==this._duration?this._duration:this.dateRange.duration?this.dateRange.duration:this.dateRange.plannedDuration||0,!isNaN(t)&&t<e&&(e=t),e}set duration(e){this._duration=e}get cue(){return this.dateRange.cue}get timelineOccupancy(){return"RANGE"===this.dateRange.attr["X-TIMELINE-OCCUPIES"]?nG.Range:nG.Point}get supplementsPrimary(){return"PRIMARY"===this.dateRange.attr["X-TIMELINE-STYLE"]}get contentMayVary(){return"NO"!==this.dateRange.attr["X-CONTENT-MAY-VARY"]}get assetUrl(){return this.dateRange.attr["X-ASSET-URI"]}get assetListUrl(){return this.dateRange.attr["X-ASSET-LIST"]}get baseUrl(){return this.base.url}get assetListLoaded(){return this.assetList.length>0||null!==this.assetListResponse}toString(){var e;return e=this,`["${e.identifier}" ${e.cue.pre?"<pre>":e.cue.post?"<post>":""}${e.timelineStart.toFixed(2)}-${e.resumeTime.toFixed(2)}]`}}function nH(e,t){return e-t.start<t.duration/2&&!(.025>Math.abs(e-(t.start+t.duration)))?t.start:t.start+t.duration}function nz(e,t,r){let i=new self.URL(e,r);return"data:"!==i.protocol&&i.searchParams.set("_HLS_primary_id",t),i}function nK(e,t){for(;null!=(r=e.assetList[++t])&&r.error;)var r;return t}function nW(e){let t=e.timelineStart,r=e.duration||0;return`["${e.identifier}" ${t.toFixed(2)}-${(t+r).toFixed(2)}]`}
2457class nY{constructor(e,t,r,i){this.hls=void 0,this.interstitial=void 0,this.assetItem=void 0,this.tracks=null,this.hasDetails=!1,this.mediaAttached=null,this._currentTime=void 0,this._bufferedEosTime=void 0,this.checkPlayout=()=>{this.reachedPlayout(this.currentTime)&&this.hls&&this.hls.trigger(o.PLAYOUT_LIMIT_REACHED,{})};const n=this.hls=new e(t);this.interstitial=r,this.assetItem=i;const s=()=>{this.hasDetails=!0};n.once(o.LEVEL_LOADED,s),n.once(o.AUDIO_TRACK_LOADED,s),n.once(o.SUBTITLE_TRACK_LOADED,s),n.on(o.MEDIA_ATTACHING,(e,{media:t})=>{this.removeMediaListeners(),this.mediaAttached=t,this.interstitial.playoutLimit&&(t.addEventListener("timeupdate",this.checkPlayout),this.appendInPlace&&n.on(o.BUFFER_APPENDED,()=>{let e=this.bufferedEnd;this.reachedPlayout(e)&&(this._bufferedEosTime=e,n.trigger(o.BUFFERED_TO_END,void 0))}))})}get appendInPlace(){return this.interstitial.appendInPlace}loadSource(){let e=this.hls;if(e)if(e.url)e.levels.length&&!e.started&&e.startLoad(-1,!0);else{let t=this.assetItem.uri;try{t=nz(t,e.config.primarySessionId||"").href}catch(e){}e.loadSource(t)}}bufferedInPlaceToEnd(e){var t;if(!this.appendInPlace)return!1;if(null!=(t=this.hls)&&t.bufferedToEnd)return!0;if(!e)return!1;let r=Math.min(this._bufferedEosTime||1/0,this.duration),i=this.timelineOffset,n=tx.bufferInfo(e,i,0);return this.getAssetTime(n.end)>=r-.02}reachedPlayout(e){let t=this.interstitial.playoutLimit;return this.startOffset+e>=t}get destroyed(){var e;return!(null!=(e=this.hls)&&e.userConfig)}get assetId(){return this.assetItem.identifier}get interstitialId(){return this.assetItem.parentIdentifier}get media(){var e;return(null==(e=this.hls)?void 0:e.media)||null}get bufferedEnd(){let e=this.media||this.mediaAttached;if(!e)return this._bufferedEosTime?this._bufferedEosTime:this.currentTime;let t=tx.bufferInfo(e,e.currentTime,.001);return this.getAssetTime(t.end)}get currentTime(){let e=this.media||this.mediaAttached;return e?this.getAssetTime(e.currentTime):this._currentTime||0}get duration(){let e=this.assetItem.duration;if(!e)return 0;let t=this.interstitial.playoutLimit;if(t){let r=t-this.startOffset;if(r>0&&r<e)return r}return e}get remaining(){let e=this.duration;return e?Math.max(0,e-this.currentTime):0}get startOffset(){return this.assetItem.startOffset}get timelineOffset(){var e;return(null==(e=this.hls)?void 0:e.config.timelineOffset)||0}set timelineOffset(e){let t=this.timelineOffset;if(e!==t&&Math.abs(e-t)>1/9e4&&this.hls){if(this.hasDetails)throw Error("Cannot set timelineOffset after playlists are loaded");this.hls.config.timelineOffset=e}}getAssetTime(e){return Math.min(Math.max(0,e-this.timelineOffset),this.duration)}removeMediaListeners(){let e=this.mediaAttached;e&&(this._currentTime=e.currentTime,this.bufferSnapShot(),e.removeEventListener("timeupdate",this.checkPlayout))}bufferSnapShot(){if(this.mediaAttached){var e;null!=(e=this.hls)&&e.bufferedToEnd&&(this._bufferedEosTime=this.bufferedEnd)}}destroy(){this.removeMediaListeners(),this.hls&&this.hls.destroy(),this.hls=null,this.tracks=this.mediaAttached=this.checkPlayout=null}attachMedia(e){var t;this.loadSource(),null==(t=this.hls)||t.attachMedia(e)}detachMedia(){var e;this.removeMediaListeners(),this.mediaAttached=null,null==(e=this.hls)||e.detachMedia()}resumeBuffering(){var e;null==(e=this.hls)||e.resumeBuffering()}pauseBuffering(){var e;null==(e=this.hls)||e.pauseBuffering()}transferMedia(){var e;return this.bufferSnapShot(),(null==(e=this.hls)?void 0:e.transferMedia())||null}resetDetails(){let e=this.hls;if(e&&this.hasDetails){e.stopLoad();let t=e=>delete e.details;e.levels.forEach(t),e.allAudioTracks.forEach(t),e.allSubtitleTracks.forEach(t),this.hasDetails=!1}}on(e,t,r){var i;null==(i=this.hls)||i.on(e,t)}once(e,t,r){var i;null==(i=this.hls)||i.once(e,t)}off(e,t,r){var i;null==(i=this.hls)||i.off(e,t)}toString(){var e;return`HlsAssetPlayer: ${nW(this.assetItem)} ${null==(e=this.hls)?void 0:e.sessionId} ${this.appendInPlace?"append-in-place":""}`}}class nQ extends P{constructor(e,t){super("interstitials-sched",t),this.onScheduleUpdate=void 0,this.eventMap={},this.events=null,this.items=null,this.durations={primary:0,playout:0,integrated:0},this.onScheduleUpdate=e}destroy(){this.reset(),this.onScheduleUpdate=null}reset(){this.eventMap={}
2457,this.setDurations(0,0,0),this.events&&this.events.forEach(e=>e.reset()),this.events=this.items=null}resetErrorsInRange(e,t){return this.events?this.events.reduce((r,i)=>e<=i.startOffset&&t>i.startOffset?(delete i.error,r+1):r,0):0}get duration(){let e=this.items;return e?e[e.length-1].end:0}get length(){return this.items?this.items.length:0}getEvent(e){return e&&this.eventMap[e]||null}hasEvent(e){return e in this.eventMap}findItemIndex(e,t){if(e.event)return this.findEventIndex(e.event.identifier);let r=-1;e.nextEvent?r=this.findEventIndex(e.nextEvent.identifier)-1:e.previousEvent&&(r=this.findEventIndex(e.previousEvent.identifier)+1);let i=this.items;if(i)for(i[r]||(void 0===t&&(t=e.start),r=this.findItemIndexAtTime(t));r>=0&&null!=(n=i[r])&&n.event;){var n;r--}return r}findItemIndexAtTime(e,t){let r=this.items;if(r)for(let i=0;i<r.length;i++){let n=r[i];if(t&&"primary"!==t&&(n=n[t]),e===n.start||e>n.start&&e<n.end)return i}return -1}findJumpRestrictedIndex(e,t){let r=this.items;if(r)for(let i=e;i<=t&&r[i];i++){let e=r[i].event;if(null!=e&&e.restrictions.jump&&!e.appendInPlace)return i}return -1}findEventIndex(e){let t=this.items;if(t)for(let i=t.length;i--;){var r;if((null==(r=t[i].event)?void 0:r.identifier)===e)return i}return -1}findAssetIndex(e,t){let r=e.assetList,i=r.length;if(i>1)for(let e=0;e<i;e++){let n=r[e];if(!n.error){let r=n.timelineStart;if(t===r||t>r&&(t<r+(n.duration||0)||e===i-1))return e}}return 0}get assetIdAtEnd(){var e;let t=null==(e=this.items)||null==(e=e[this.length-1])?void 0:e.event;if(t){let e=t.assetList,r=e[e.length-1];if(r)return r.identifier}return null}parseInterstitialDateRanges(e,t){let r=e.main.details,{dateRanges:i}=r,n=this.events,s=this.parseDateRanges(i,{url:r.url},t),a=Object.keys(i),o=n?n.filter(e=>!a.includes(e.identifier)):[];s.length&&s.sort((e,t)=>{let r=e.cue.pre,i=e.cue.post,n=t.cue.pre,s=t.cue.post;if(r&&!n)return -1;if(n&&!r||i&&!s)return 1;if(s&&!i)return -1;if(!r&&!n&&!i&&!s){let r=e.startTime,i=t.startTime;if(r!==i)return r-i}return e.dateRange.tagOrder-t.dateRange.tagOrder}),this.events=s,o.forEach(e=>{this.removeEvent(e)}),this.updateSchedule(e,o)}updateSchedule(e,t=[],r=!1){let i=this.events||[];
2457if(i.length||t.length||this.length<2){let n=this.items,s=this.parseSchedule(i,e);(r||t.length||(null==n?void 0:n.length)!==s.length||s.some((e,t)=>Math.abs(e.playout.start-n[t].playout.start)>.005||Math.abs(e.playout.end-n[t].playout.end)>.005))&&(this.items=s,this.onScheduleUpdate(t,n))}}parseDateRanges(e,t,r){let i=[],n=Object.keys(e);for(let s=0;s<n.length;s++){let a=n[s],o=e[a];if(o.isInterstitial){let e=this.eventMap[a];e?e.setDateRange(o):(e=new nq(o,t),this.eventMap[a]=e,!1===r&&(e.appendInPlace=r)),i.push(e)}}return i}parseSchedule(e,t){let r=[],i=t.main.details,n=i.live?1/0:i.edge,s=0;if((e=e.filter(e=>!e.error&&!(e.cue.once&&e.hasPlayed))).length){this.resolveOffsets(e,t);let i=0,o=0;if(e.forEach((t,a)=>{let l=t.cue.pre,u=t.cue.post,c=e[a-1]||null,d=t.appendInPlace,h=u?n:t.startOffset,f=t.duration,p=t.timelineOccupancy===nG.Range?f:0,g=t.resumptionOffset,m=(null==c?void 0:c.startTime)===h,y=h+t.cumulativeDuration,v=d?y+f:h+g;if(l||!u&&h<=0){let e=o;o+=p,t.timelineStart=y;let i=s;s+=f,r.push({event:t,start:y,end:v,playout:{start:i,end:s},integrated:{start:e,end:o}})}else{if(!(h<=n))return;if(!m){let n=h-i;if(n>.033){let l=i,u=o;o+=n;let c=s;s+=n;let d={previousEvent:e[a-1]||null,nextEvent:t,start:l,end:l+n,playout:{start:c,end:s},integrated:{start:u,end:o}};r.push(d)}else n>0&&c&&(c.cumulativeDuration+=n,r[r.length-1].end=h)}u&&(v=y),t.timelineStart=y;let l=o;o+=p;let d=s;s+=f,r.push({event:t,start:y,end:v,playout:{start:d,end:s},integrated:{start:l,end:o}})}let b=t.resumeTime;i=u||b>n?n:b}),i<n){var a;let e=i,t=o,l=n-i;o+=l;let u=s;s+=l,r.push({previousEvent:(null==(a=r[r.length-1])?void 0:a.event)||null,nextEvent:null,start:i,end:e+l,playout:{start:u,end:s},integrated:{start:t,end:o}})}this.setDurations(n,s,o)}else r.push({previousEvent:null,nextEvent:null,start:0,end:n,playout:{start:0,end:n},integrated:{start:0,end:n}}),this.setDurations(n,n,n);return r}setDurations(e,t,r){this.durations={primary:e,playout:t,integrated:r}}resolveOffsets(e,t){let i=t.main.details,n=i.live?1/0:i.edge,s=0,a=-1;e.forEach((o,l)=>{let u=o.cue.pre,c=o.cue.post,d=u?0:c?n:o.startTime;this.updateAssetDurations(o),a===d?o.cumulativeDuration=s:(s=0,a=d),!c&&o.snapOptions.in&&(o.resumeAnchor=e2(null,i.fragments,o.startOffset+o.resumptionOffset,0,0)||void 0),o.appendInPlace&&!o.appendInPlaceStarted&&(this.primaryCanResumeInPlaceAt(o,t)||(o.appendInPlace=!1)),!o.appendInPlace&&l+1<e.length&&e[l+1].startTime-e[l].resumeTime<.033&&(e[l+1].appendInPlace=!1,e[l+1].appendInPlace&&this.warn(`Could not change append strategy for abutting event ${o}`));let h=r(o.resumeOffset)?o.resumeOffset:o.duration;s+=h})}primaryCanResumeInPlaceAt(e,t){let r=e.resumeTime,i=e.startTime+e.resumptionOffset;return Math.abs(r-i)>.025?(this.log(`"${e.identifier}" resumption ${r} not aligned with estimated timeline end ${i}`),!1):!Object.keys(t).some(i=>{let n=t[i].details,s=n.edge;if(r>=s)return this.log(`"${e.identifier}" resumption ${r} past ${i} playlist end ${s}`),!1;let a=e2(null,n.fragments,r);if(!a)return this.log(`"${e.identifier}" resumption ${r} does not align with any fragments in ${i} playlist (${n.fragStart}-${n.fragmentEnd})`),!0;let o=.175*("audio"===i);return!(Math.abs(a.start-r)<.025+o||Math.abs(a.end-r)<.025+o)&&(this.log(`"${e.identifier}" resumption ${r} not aligned with ${i} fragment bounds (${a.start}-${a.end} sn: ${a.sn} cc: ${a.cc})`),!0)})}updateAssetDurations(e){if(!e.assetListLoaded)return;let t=e.timelineStart,r=0,i=!1,n=!1;for(let s=0;s<e.assetList.length;s++){let a=e.assetList[s],o=t+r;a.startOffset=r,a.timelineStart=o,i||(i=null===a.duration),n||(n=!!a.error),r+=a.error?0:a.duration||0}i&&!n?e.duration=Math.max(r,e.duration):e.duration=r}removeEvent(e){e.reset(),delete this.eventMap[e.identifier]}}function nX(e){return`[${e.event?'"'+e.event.identifier+'"':"primary"}: ${e.start.toFixed(2)}-${e.end.toFixed(2)}]`}class nJ{constructor(e){this.hls=void 0,this.hls=e}destroy(){this.hls=null}loadAssetList(e,t){let r,i=e.assetListUrl;try{r=nz(i,this.hls.sessionId,e.baseUrl)}catch(r){let t=this.assignAssetListError(e,a.ASSET_LIST_LOAD_ERROR,r,i);this.hls.trigger(o.ERROR,t);return}t&&"data:"!==r.protocol&&r.searchParams.set("_HLS_start_offset",""+t);let n=this.hls.config,s=new n.loader(n),l={responseType:"json",url:r.href},u=n.interstitialAssetListLoadPolicy.default,c={loadPolicy:u,timeout:u.maxLoadTimeMs,maxRetry:0,retryDelay:0,maxRetryDelay:0};return s.load(l,c,{onSuccess:(t,r,i,n)=>{let s=t.data;if(!Array.isArray(null==s?void 0:s.ASSETS)){let t=this.assignAssetListError(e,a.ASSET_LIST_PARSING_ERROR,Error("Invalid interstitial asset list"),i.url,r,n);this.hls.trigger(o.ERROR,t);return}e.assetListResponse=s,this.hls.trigger(o.ASSET_LIST_LOADED,{event:e,assetListResponse:s,networkDetails:n})},onError:(t,r,i,n)=>{let s=this.assignAssetListError(e,a.ASSET_LIST_LOAD_ERROR,Error(`Error loading X-ASSET-LIST: HTTP status ${t.code} ${t.text} (${r.url})`),r.url,n,i);this.hls.trigger(o.ERROR,s)},onTimeout:(t,r,i)=>{let n=this.assignAssetListError(e,a.ASSET_LIST_LOAD_TIMEOUT,Error(`Timeout loading X-ASSET-LIST (${r.url})`),r.url,t,i);this.hls.trigger(o.ERROR,n)}}),this.hls.trigger(o.ASSET_LIST_LOADING,{event:e}),s}assignAssetListError(e,t,r,i,n,a){return e.error=r,{type:s.NETWORK_E
vendor: 9,198 bytes, line 2457
2457RROR,details:t,fatal:!1,interstitial:e,url:i,error:r,networkDetails:a,stats:n}}}function nZ(e){var t;null==e||null==(t=e.play())||t.catch(()=>{})}function n0(e,t){return`[${e}] Advancing timeline position to ${t}`}class n1{constructor(e){this.buffered=void 0;const t=(t,r,i)=>{if((r>>>=0)>i-1)throw new DOMException(`Failed to execute '${t}' on 'TimeRanges': The index provided (${r}) is greater than the maximum bound (${i})`);return e[r][t]};this.buffered={get length(){return e.length},end:r=>t("end",r,e.length),start:r=>t("start",r,e.length)}}}let n2={42:225,92:233,94:237,95:243,96:250,123:231,124:247,125:209,126:241,127:9608,128:174,129:176,130:189,131:191,132:8482,133:162,134:163,135:9834,136:224,137:32,138:232,139:226,140:234,141:238,142:244,143:251,144:193,145:201,146:211,147:218,148:220,149:252,150:8216,151:161,152:42,153:8217,154:9473,155:169,156:8480,157:8226,158:8220,159:8221,160:192,161:194,162:199,163:200,164:202,165:203,166:235,167:206,168:207,169:239,170:212,171:217,172:249,173:219,174:171,175:187,176:195,177:227,178:205,179:204,180:236,181:210,182:242,183:213,184:245,185:123,186:125,187:92,188:94,189:95,190:124,191:8764,192:196,193:228,194:214,195:246,196:223,197:165,198:164,199:9475,200:197,201:229,202:216,203:248,204:9487,205:9491,206:9495,207:9499},n3=e=>String.fromCharCode(n2[e]||e),n4={17:1,18:3,21:5,22:7,23:9,16:11,19:12,20:14},n5={17:2,18:4,21:6,22:8,23:10,19:13,20:15},n8={25:1,26:3,29:5,30:7,31:9,24:11,27:12,28:14},n6={25:2,26:4,29:6,30:8,31:10,27:13,28:15},n7=["white","green","blue","cyan","red","yellow","magenta","black","transparent"];class n9{constructor(){this.time=null,this.verboseLevel=0}log(e,t){if(this.verboseLevel>=e){let r="function"==typeof t?t():t;$.log(`${this.time} [${e}] ${r}`)}}}let se=function(e){let t=[];for(let r=0;r<e.length;r++)t.push(e[r].toString(16));return t};class st{constructor(){this.foreground="white",this.underline=!1,this.italics=!1,this.background="black",this.flash=!1}reset(){this.foreground="white",this.underline=!1,this.italics=!1,this.background="black",this.flash=!1}setStyles(e){let t=["foreground","underline","italics","background","flash"];for(let r=0;r<t.length;r++){let i=t[r];e.hasOwnProperty(i)&&(this[i]=e[i])}}isDefault(){return"white"===this.foreground&&!this.underline&&!this.italics&&"black"===this.background&&!this.flash}equals(e){return this.foreground===e.foreground&&this.underline===e.underline&&this.italics===e.italics&&this.background===e.background&&this.flash===e.flash}copy(e){this.foreground=e.foreground,this.underline=e.underline,this.italics=e.italics,this.background=e.background,this.flash=e.flash}toString(){return"color="+this.foreground+", underline="+this.underline+", italics="+this.italics+", background="+this.background+", flash="+this.flash}}class sr{constructor(){this.uchar=" ",this.penState=new st}reset(){this.uchar=" ",this.penState.reset()}setChar(e,t){this.uchar=e,this.penState.copy(t)}setPenState(e){this.penState.copy(e)}equals(e){return this.uchar===e.uchar&&this.penState.equals(e.penState)}copy(e){this.uchar=e.uchar,this.penState.copy(e.penState)}isEmpty(){return" "===this.uchar&&this.penState.isDefault()}}class si{constructor(e){this.chars=[],this.pos=0,this.currPenState=new st,this.cueStartTime=null,this.logger=void 0;for(let e=0;e<100;e++)this.chars.push(new sr);this.logger=e}equals(e){for(let t=0;t<100;t++)if(!this.chars[t].equals(e.chars[t]))return!1;return!0}copy(e){for(let t=0;t<100;t++)this.chars[t].copy(e.chars[t])}isEmpty(){let e=!0;for(let t=0;t<100;t++)if(!this.chars[t].isEmpty()){e=!1;break}return e}setCursor(e){this.pos!==e&&(this.pos=e),this.pos<0?(this.logger.log(3,"Negative cursor position "+this.pos),this.pos=0):this.pos>100&&(this.logger.log(3,"Too large cursor position "+this.pos),this.pos=100)}moveCursor(e){let t=this.pos+e;if(e>1)for(let e=this.pos+1;e<t+1;e++)this.chars[e].setPenState(this.currPenState);this.setCursor(t)}backSpace(){this.moveCursor(-1),this.chars[this.pos].setChar(" ",this.currPenState)}insertChar(e){e>=144&&this.backSpace();let t=n3(e);this.pos>=100?this.logger.log(0,()=>"Cannot insert "+e.toString(16)+" ("+t+") at position "+this.pos+". Skipping it!"):(this.chars[this.pos].setChar(t,this.currPenState),this.moveCursor(1))}clearFromPos(e){let t;for(t=e;t<100;t++)this.chars[t].reset()}clear(){this.clearFromPos(0),this.pos=0,this.currPenState.reset()}clearToEndOfRow(){this.clearFromPos(this.pos)}getTextString(){let e=[],t=!0;for(let r=0;r<100;r++){let i=this.chars[r].uchar;" "!==i&&(t=!1),e.push(i)}return t?"":e.join("")}setPenStyles(e){this.currPenState.setStyles(e),this.chars[this.pos].setPenState(this.currPenState)}}class sn{constructor(e){this.rows=[],this.currRow=14,this.nrRollUpRows=null,this.lastOutputScreen=null,this.logger=void 0;for(let t=0;t<15;t++)this.rows.push(new si(e));this.logger=e}reset(){for(let e=0;e<15;e++)this.rows[e].clear();this.currRow=14}equals(e){let t=!0;for(let r=0;r<15;r++)if(!this.rows[r].equals(e.rows[r])){t=!1;break}return t}copy(e){for(let t=0;t<15;t++)this.rows[t].copy(e.rows[t])}isEmpty(){let e=!0;for(let t=0;t<15;t++)if(!this.rows[t].isEmpty()){e=!1;break}return e}backSpace(){this.rows[this.currRow].backSpace()}clearToEndOfRow(){this.rows[this.currRow].clearToEndOfRow()}insertChar(e){this.rows[this.currRow].insertChar(e)}setPen(e){this.rows[this.currRow].setPenStyles(e)}moveCursor(e){this.rows[this.currRow].moveCursor(e)}setCursor(e){this.logger.log(2,"setCursor: "+e),this.rows[this.currRow].setCursor(e)}setPAC(e){this.logger.log(2,()=>"pacData = "+ez(e));let t=e.row-1;if(this.nrRollUpRows&&t<this.nrRollUpRows-1&&(t=this.nrRollUpRows-1),this.nrRollUpRows&&this.currRow!==t){for(let e=0;e<15;e++)this.rows[e].clear();let e=this.currRow+1-this.nrRollUpRows,r=this.lastOutputScreen;if(r){let i=r.rows[e].cueStartTime,n=this.logger.time;if(null!==i&&null!==n&&i<n)for(let i=0;i<this.nrRollUpRows;i++)this.rows[t-this.nrRollUpRows+i+1].copy(r.rows[e+i])}}this.currRow=t;let r=this.rows[this.currRow];if(null!==e.indent){let t=Math.max(e.indent-1,0);r.setCursor(e.indent),e.color=r.chars[t].penState.foreground}let i={foreground:e.color,underline:e.underline,italics:e.italics,background:"black",flash:!1};this.setPen(i)}setBkgData(e){this.logger.log(2,()=>"bkgData = "+ez(e)),this.backSpace(),this.setPen(e),this.insertChar(32)}setRollUpRows(e){this.nrRollUpRows=e}rollUp(){if(null===this.nrRollUpRows)return void this.logger.log(3,"roll_up but nrRollUpRows not set yet");this.logger.log(1,()=>this.getDisplayText());let e=this.currRow+1-this.nrRollUpRows,t=this.rows.splice(e,1)[0];t.clear(),this.rows.splice(this.currRow,0,t),this.logger.log(2,"Rolling up")}getDisplayText(e){e=e||!1;let t=[],r="",i=-1;for(let r=0;r<15;r++){let n=this.rows[r].getTextString();n&&(i=r+1,e?t.push("Row "+i+": '"+n+"'"):t.push(n.trim()))}return t.length>0&&(r=e?"["+t.join(" | ")+"]":t.join("\n")),r}getTextAndFormat(){return this.rows}}class ss{constructor(e,t,r){this.chNr=void 0,this.outputFilter=void 0,this.mode=void 0,this.verbose=void 0,this.displayedMemory=void 0,this.nonDisplayedMemory=void 0,this.lastOutputScreen=void 0,this.currRollUpRow=void 0,this.writeScreen=void 0,this.cueStartTime=void 0,this.logger=void 0,this.chNr=e,this.outputFilter=t,this.mode=null,this.verbose=0,this.displayedMemory=new sn(r),this.nonDisplayedMemory=new sn(r),this.lastOutputScreen=new sn(r),this.currRollUpRow=this.displayedMemory.rows[14],this.writeScreen=this.displayedMemory,this.mode=null,this.cueStartTime=null,this.logger=r}reset(){this.mode=null,this.displayedMemory.reset(),this.nonDisplayedMemory.reset(),this.lastOutputScreen.reset(),this.outputFilter.reset(),this.currRollUpRow=this.displayedMemory.rows[14],this.writeScreen=this.displayedMemory,this.mode=null,this.cueStartTime=null}getHandler(){return this.outputFilter}setHandler(e){this.outputFilter=e}setPAC(e){this.writeScreen.setPAC(e)}setBkgData(e){this.writeScreen.setBkgData(e)}setMode(e){e!==this.mode&&(this.mode=e,this.logger.log(2,()=>"MODE="+e),"MODE_POP-ON"===this.mode?this.writeScreen=this.nonDisplayedMemory:(this.writeScreen=this.displayedMemory,this.writeScreen.reset()),"MODE_ROLL-UP"!==this.mode&&(this.displayedMemory.nrRollUpRows=null,this.nonDisplayedMemory.nrRollUpRows=null),this.mode=e)}insertChars(e){for(let t=0;t<e.length;t++)this.writeScreen.insertChar(e[t]);let t=this.writeScreen===this.displayedMemory?"DISP":"NON_DISP";this.logger.log(2,()=>t+": "+this.writeScreen.getDisplayText(!0)),("MODE_PAINT-ON"===this.mode||"MODE_ROLL-UP"===this.mode)&&(this.logger.log(1,()=>"DISPLAYED: "+this.displayedMemory.getDisplayText(!0)),this.outputDataUpdate())}ccRCL(){this.logger.log(2,"RCL - Resume Caption Loading"),this.setMode("MODE_POP-ON")}ccBS(){this.logger.log(2,"BS - BackSpace"),"MODE_TEXT"!==this.mode&&(this.writeScreen.backSpace(),this.writeScreen===this.displayedMemory&&this.outputDataUpdate())}ccAOF(){}ccAON(){}ccDER(){this.logger.log(2,"DER- Delete to End of Row"),this.writeScreen.clearToEndOfRow(),this.outputDataUpdate()}ccRU(e){this.logger.log(2,"RU("+e+") - Roll Up"),this.writeScreen=this.displayedMemory,this.setMode("MODE_ROLL-UP"),this.writeScreen.setRollUpRows(e)}ccFON(){this.logger.log(2,"FON - Flash On"),this.writeScreen.setPen({flash:!0})}
2457ccRDC(){this.logger.log(2,"RDC - Resume Direct Captioning"),this.setMode("MODE_PAINT-ON")}ccTR(){this.logger.log(2,"TR"),this.setMode("MODE_TEXT")}ccRTD(){this.logger.log(2,"RTD"),this.setMode("MODE_TEXT")}ccEDM(){this.logger.log(2,"EDM - Erase Displayed Memory"),this.displayedMemory.reset(),this.outputDataUpdate(!0)}ccCR(){this.logger.log(2,"CR - Carriage Return"),this.writeScreen.rollUp(),this.outputDataUpdate(!0)}ccENM(){this.logger.log(2,"ENM - Erase Non-displayed Memory"),this.nonDisplayedMemory.reset()}ccEOC(){if(this.logger.log(2,"EOC - End Of Caption"),"MODE_POP-ON"===this.mode){let e=this.displayedMemory;this.displayedMemory=this.nonDisplayedMemory,this.nonDisplayedMemory=e,this.writeScreen=this.nonDisplayedMemory,this.logger.log(1,()=>"DISP: "+this.displayedMemory.getDisplayText())}this.outputDataUpdate(!0)}ccTO(e){this.logger.log(2,"TO("+e+") - Tab Offset"),this.writeScreen.moveCursor(e)}ccMIDROW(e){let t={flash:!1};(t.underline=e%2==1,t.italics=e>=46,t.italics)?t.foreground="white":t.foreground=["white","green","blue","cyan","red","yellow","magenta"][Math.floor(e/2)-16],this.logger.log(2,"MIDROW: "+ez(t)),this.writeScreen.setPen(t)}outputDataUpdate(e=!1){let t=this.logger.time;null!==t&&this.outputFilter&&(null!==this.cueStartTime||this.displayedMemory.isEmpty()?this.displayedMemory.equals(this.lastOutputScreen)||(this.outputFilter.newCue(this.cueStartTime,t,this.lastOutputScreen),e&&this.outputFilter.dispatchCue&&this.outputFilter.dispatchCue(),this.cueStartTime=this.displayedMemory.isEmpty()?null:t):this.cueStartTime=t,this.lastOutputScreen.copy(this.displayedMemory))}cueSplitAtTime(e){this.outputFilter&&!this.displayedMemory.isEmpty()&&(this.outputFilter.newCue&&this.outputFilter.newCue(this.cueStartTime,e,this.displayedMemory),this.cueStartTime=e)}}class sa{constructor(e,t,r){this.channels=void 0,this.currentChannel=0,this.cmdHistory={a:null,b:null},this.logger=void 0;const i=this.logger=new n9;this.channels=[null,new ss(e,t,i),new ss(e+1,r,i)]}getHandler(e){return this.channels[e].getHandler()}setHandler(e,t){this.channels[e].setHandler(t)}addData(e,t){this.logger.time=e;for(let e=0;e<t.length;e+=2){var r,i,n,s,a,o,l,u;let c=127&t[e],d=127&t[e+1],h=!1,f=null;if(0===c&&0===d)continue;this.logger.log(3,()=>"["+se([t[e],t[e+1]])+"] -> ("+se([c,d])+")");let p=this.cmdHistory;if(c>=16&&c<=31){if(r=c,i=d,(n=p).a===r&&n.b===i){(s=p).a=null,s.b=null,this.logger.log(3,()=>"Repeated command ("+se([c,d])+") is dropped");continue}a=c,o=d,(l=this.cmdHistory).a=a,l.b=o,(h=this.parseCmd(c,d))||(h=this.parseMidrow(c,d)),h||(h=this.parsePAC(c,d)),h||(h=this.parseBackgroundAttributes(c,d))}else{(u=p).a=null,u.b=null}if(!h&&(f=this.parseChars(c,d))){let e=this.currentChannel;e&&e>0?this.channels[e].insertChars(f):this.logger.log(2,"No channel found yet. TEXT-MODE?")}h||f||this.logger.log(2,()=>"Couldn't parse cleaned data "+se([c,d])+" orig: "+se([t[e],t[e+1]]))}}parseCmd(e,t){if(!((20===e||28===e||21===e||29===e)&&t>=32&&t<=47||(23===e||31===e)&&t>=33&&t<=35))return!1;let r=20===e||21===e||23===e?1:2,i=this.channels[r];return 20===e||21===e||28===e||29===e?32===t?i.ccRCL():33===t?i.ccBS():34===t?i.ccAOF():35===t?i.ccAON():36===t?i.ccDER():37===t?i.ccRU(2):38===t?i.ccRU(3):39===t?i.ccRU(4):40===t?i.ccFON():41===t?i.ccRDC():42===t?i.ccTR():43===t?i.ccRTD():44===t?i.ccEDM():45===t?i.ccCR():46===t?i.ccENM():47===t&&i.ccEOC():i.ccTO(t-32),this.currentChannel=r,!0}parseMidrow(e,t){let r=0;if((17===e||25===e)&&t>=32&&t<=47){if((r=17===e?1:2)!==this.currentChannel)return this.logger.log(0,"Mismatch channel in midrow parsing"),!1;let i=this.channels[r];return!!i&&(i.ccMIDROW(t),this.logger.log(3,()=>"MIDROW ("+se([e,t])+")"),!0)}return!1}parsePAC(e,t){let r,i=(e>=17&&e<=23||e>=25&&e<=31)&&t>=64&&t<=127,n=(16===e||24===e)&&t>=64&&t<=95;if(!(i||n))return!1;let s=e<=23?1:2;r=t>=64&&t<=95?1===s?n4[e]:n8[e]:1===s?n5[e]:n6[e];let a=this.channels[s];return!!a&&(a.setPAC(this.interpretPAC(r,t)),this.currentChannel=s,!0)}interpretPAC(e,t){let r,i={color:null,italics:!1,indent:null,underline:!1,row:e};return i.underline=(1&(r=t>95?t-96:t-64))==1,r<=13?i.color=["white","green","blue","cyan","red","yellow","magenta","white"][Math.floor(r/2)]:r<=15?(i.italics=!0,i.color="white"):i.indent=4*Math.floor((r-16)/2),i}parseChars(e,t){let r,i=null,n=null;if(e>=25?(r=2,n=e-8):(r=1,n=e),n>=17&&n<=19){let e;e=17===n?t+80:18===n?t+112:t+144,this.logger.log(2,()=>"Special char '"+n3(e)+"' in channel "+r),i=[e]}else e>=32&&e<=127&&(i=0===t?[e]:[e,t]);return i&&this.logger.log(3,()=>"Char codes = "+se(i).join(",")),i}
2457parseBackgroundAttributes(e,t){if(!((16===e||24===e)&&t>=32&&t<=47||(23===e||31===e)&&t>=45&&t<=47))return!1;let r={};return 16===e||24===e?(r.background=n7[Math.floor((t-32)/2)],t%2==1&&(r.background=r.background+"_semi")):45===t?r.background="transparent":(r.foreground="black",47===t&&(r.underline=!0)),this.channels[e<=23?1:2].setBkgData(r),!0}reset(){var e;for(let e=0;e<Object.keys(this.channels).length;e++){let t=this.channels[e];t&&t.reset()}(e=this.cmdHistory).a=null,e.b=null}cueSplitAtTime(e){for(let t=0;t<this.channels.length;t++){let r=this.channels[t];r&&r.cueSplitAtTime(e)}}}var so=function(){if(null!=tU&&tU.VTTCue)return self.VTTCue;let e=["","lr","rl"],t=["start","middle","end","left","right"];function r(e,t){if("string"!=typeof t||!Array.isArray(e))return!1;let r=t.toLowerCase();return!!~e.indexOf(r)&&r}function i(e){let t=1;for(;t<arguments.length;t++){let r=arguments[t];for(let t in r)e[t]=r[t]}return e}function n(n,s,a){let o={enumerable:!0};this.hasBeenReset=!1;let l="",u=!1,c=n,d=s,h=a,f=null,p="",g=!0,m="auto",y="start",v=50,b="middle",_=50,E="middle";Object.defineProperty(this,"id",i({},o,{get:function(){return l},set:function(e){l=""+e}})),Object.defineProperty(this,"pauseOnExit",i({},o,{get:function(){return u},set:function(e){u=!!e}})),Object.defineProperty(this,"startTime",i({},o,{get:function(){return c},set:function(e){if("number"!=typeof e)throw TypeError("Start time must be set to a number.");c=e,this.hasBeenReset=!0}})),Object.defineProperty(this,"endTime",i({},o,{get:function(){return d},set:function(e){if("number"!=typeof e)throw TypeError("End time must be set to a number.");d=e,this.hasBeenReset=!0}})),Object.defineProperty(this,"text",i({},o,{get:function(){return h},set:function(e){h=""+e,this.hasBeenReset=!0}})),Object.defineProperty(this,"region",i({},o,{get:function(){return f},set:function(e){f=e,this.hasBeenReset=!0}})),Object.defineProperty(this,"vertical",i({},o,{get:function(){return p},set:function(t){let i=r(e,t);if(!1===i)throw SyntaxError("An invalid or illegal string was specified.");p=i,this.hasBeenReset=!0}})),Object.defineProperty(this,"snapToLines",i({},o,{get:function(){return g},set:function(e){g=!!e,this.hasBeenReset=!0}})),Object.defineProperty(this,"line",i({},o,{get:function(){return m},set:function(e){if("number"!=typeof e&&"auto"!==e)throw SyntaxError("An invalid number or illegal string was specified.");m=e,this.hasBeenReset=!0}})),Object.defineProperty(this,"lineAlign",i({},o,{get:function(){return y},set:function(e){let i=r(t,e);if(!i)throw SyntaxError("An invalid or illegal string was specified.");y=i,this.hasBeenReset=!0}})),Object.defineProperty(this,"position",i({},o,{get:function(){return v},set:function(e){if(e<0||e>100)throw Error("Position must be between 0 and 100.");v=e,this.hasBeenReset=!0}})),Object.defineProperty(this,"positionAlign",i({},o,{get:function(){return b},set:function(e){let i=r(t,e);if(!i)throw SyntaxError("An invalid or illegal string was specified.");b=i,this.hasBeenReset=!0}})),Object.defineProperty(this,"size",i({},o,{get:function(){return _},set:function(e){if(e<0||e>100)throw Error("Size must be between 0 and 100.");_=e,this.hasBeenReset=!0}})),Object.defineProperty(this,"align",i({},o,{get:function(){return E},set:function(e){let i=r(t,e);if(!i)throw SyntaxError("An invalid or illegal string was specified.");E=i,this.hasBeenReset=!0}})),this.displayState=void 0}return n.prototype.getCueAsHTML=function(){return self.WebVTT.convertCueToDOMTree(self,this.text)},n}();class sl{decode(e,t){if(!e)return"";if("string"!=typeof e)throw Error("Error - expected string data.");return decodeURIComponent(encodeURIComponent(e))}}function su(e){function t(e,t,r,i){return(0|e)*3600+(0|t)*60+(0|r)+parseFloat(i||0)}let r=e.match(/^(?:(\d+):)?(\d{2}):(\d{2})(\.\d+)?/);return r?parseFloat(r[2])>59?t(r[2],r[3],0,r[4]):t(r[1],r[2],r[3],r[4]):null}class sc{constructor(){this.values=Object.create(null)}set(e,t){this.get(e)||""===t||(this.values[e]=t)}get(e,t,r){return r?this.has(e)?this.values[e]:t[r]:this.has(e)?this.values[e]:t}has(e){return e in this.values}alt(e,t,r){for(let i=0;i<r.length;++i)if(t===r[i]){this.set(e,t);break}}integer(e,t){/^-?\d+$/.test(t)&&this.set(e,parseInt(t,10))}percent(e,t){if(/^([\d]{1,3})(\.[\d]*)?%$/.test(t)){let r=parseFloat(t);if(r>=0&&r<=100)return this.set(e,r),!0}return!1}}function sd(e,t,r,i){let n=i?e.split(i):[e];for(let e in n){if("string"!=typeof n[e])continue;let i=n[e].split(r);if(2===i.length)t(i[0],i[1])}}let sh=new so(0,0,""),sf="middle"===sh.align?"middle":"center";function sp(e){return e.replace(/<br(?: \/)?>/gi,"\n")}class sg{constructor(){this.state="INITIAL",this.buffer="",this.decoder=new sl,this.regionList=[],this.cue=null,this.oncue=void 0,this.onparsingerror=void 0,this.onflush=void 0}parse(e){let t=this;function r(){let e=t.buffer,r=0;for(e=sp(e);r<e.length&&"\r"!==e[r]&&"\n"!==e[r];)++r;let i=e.slice(0,r);return"\r"===e[r]&&++r,"\n"===e[r]&&++r,t.buffer=e.slice(r),i}e&&(t.buffer+=t.decoder.decode(e,{stream:!0}));try{let e="";if("INITIAL"===t.state){if(!/\r\n|\n/.test(t.buffer))return this;let i=(e=r()).match(/^()?WEBVTT([ \t].*)?$/);if(!(null!=i&&i[0]))throw Error("Malformed WebVTT signature.");t.state="HEADER"}let n=!1;for(;t.buffer&&/\r\n|\n/.test(t.buffer);)switch(n?n=!1:e=r(),t.state){case"HEADER":if(/:/.test(e)){var i;i=e,sd(i,function(e,t){},/:/)}else e||(t.state="ID");continue;case"NOTE":e||(t.state="ID");continue;case"ID":if(/^NOTE($|[ \t])/.test(e)){t.state="NOTE";break}if(!e)continue;if(t.cue=new so(0,0,""),t.state="CUE",-1===e.indexOf("-->")){t.cue.id=e;continue}case"CUE":if(!t.cue){t.state="BADCUE";continue}try{!function(e,t,r){var i;let n,s,a,o=e;function l(){let t=su(e);if(null===t)throw Error("Malformed timestamp: "+o);return e=e.replace(/^[^\sa-zA-Z-]+/,""),t}function u(){e=e.replace(/^\s+/,"")}if(u(),t.startTime=l(),u(),"-->"!==e.slice(0,3))throw Error("Malformed time stamp (time stamps must be separated by '-->'): "+o);e=e.slice(3),u(),t.endTime=l(),u(),i=e,n=new sc,sd(i,function(e,t){let i;switch(e){case"region":for(let i=r.length-1;i>=0;i--)if(r[i].id===t){n.set(e,r[i].region);break}break;case"vertical":n.alt(e,t,["rl","lr"]);break;case"line":i=t.split(","),n.integer(e,i[0]),n.percent(e,i[0])&&n.set("snapToLines",!1),n.alt(e,i[0],["auto"]),2===i.length&&n.alt("lineAlign",i[1],["start",sf,"end"]);break;case"position":i=t.split(","),n.percent(e,i[0]),2===i.length&&n.alt("positionAlign",i[1],["start",sf,"end","line-left","line-right","auto"]);break;case"size":n.percent(e,t);break;case"align":n.alt(e,t,["start",sf,"end","left","right"])}},/:/,/\s/),t.region=n.get("region",null),t.vertical=n.get("vertical",""),"auto"===(s=n.get("line","auto"))&&-1===sh.line&&(s=-1),t.line=s,t.lineAlign=n.get("lineAlign","start"),t.snapToLines=n.get("snapToLines",!0),t.size=n.get("size",100),t.align=n.get("align",sf),"auto"===(a=n.get("position","auto"))&&50===sh.position&&(a="start"===t.align||"left"===t.align?0:"end"===t.align||"right"===t.align?100:50),t.position=a}(e,t.cue,t.regionList)}catch(e){t.cue=null,t.state="BADCUE";continue}t.state="CUETEXT";continue;case"CUETEXT":{let r=-1!==e.indexOf("-->");if(!e||r&&(n=!0)){t.oncue&&t.cue&&t.oncue(t.cue),t.cue=null,t.state="ID";continue}if(null===t.cue)continue;t.cue.text&&(t.cue.text+="\n"),t.cue.text+=e}continue;case"BADCUE":e||(t.state="ID")}}catch(e){"CUETEXT"===t.state&&t.cue&&t.oncue&&t.oncue(t.cue),t.cue=null,t.state="INITIAL"===t.state?"BADWEBVTT":"BADCUE"}return this}flush(){try{if((this.cue||"HEADER"===this.state)&&(this.buffer+="\n\n",this.parse()),"INITIAL"===this.state||"BADWEBVTT"===this.state)throw Error("Malformed WebVTT signature.")}catch(e){this.onparsingerror&&this.onparsingerror(e)}return this.onflush&&this.onflush(),this}}let sm=/\r\n|\n\r|\n|\r/g,sy=function(e,t,r=0){return e.slice(r,r+t.length)===t},sv=function(e){let t=parseInt(e.slice(-3)),i=parseInt(e.slice(-6,-4)),n=parseInt(e.slice(-9,-7)),s=e.length>9?parseInt(e.substring(0,e.indexOf(":"))):0;if(!r(t)||!r(i)||!r(n)||!r(s))throw Error(`Malformed X-TIMESTAMP-MAP: Local:${e}`);return t+=1e3*i,t+=6e4*n,t+=36e5*s};
2457function sb(e,t,r){return nV(e.toString())+nV(t.toString())+nV(r)}let s_=function(e,t,r){let i=e[t],n=e[i.prevCC];if(!n||!n.new&&i.new){e.ccOffset=e.presentationOffset=i.start,i.new=!1;return}for(;null!=(s=n)&&s.new;){var s;e.ccOffset+=i.start-n.start,i.new=!1,n=e[(i=n).prevCC]}e.presentationOffset=r},sE="stpp.ttml.im1t",sS=/^(\d{2,}):(\d{2}):(\d{2}):(\d{2})\.?(\d+)?$/,sx=/^(\d*(?:\.\d*)?)(h|m|s|ms|f|t)$/,sT={left:"start",center:"center",right:"end",start:"start",end:"end"};function sw(e,t,r,i){let n=el(new Uint8Array(e),["mdat"]);if(0===n.length)return void i(Error("Could not parse IMSC1 mdat"));let s=n.map(e=>V(e)),a=function(e,t=1,r=!1){return ik(e,1,1/t,r)}(t.baseTime,t.timescale);try{s.forEach(e=>r(function(e,t){let r=new DOMParser().parseFromString(e,"text/xml").getElementsByTagName("tt")[0];if(!r)throw Error("Invalid ttml");let i={frameRate:30,subFrameRate:1,frameRateMultiplier:0,tickRate:0},n=Object.keys(i).reduce((e,t)=>(e[t]=r.getAttribute(`ttp:${t}`)||i[t],e),{}),s="preserve"!==r.getAttribute("xml:space"),a=sR(sA(r,"styling","style")),o=sR(sA(r,"layout","region")),l=sA(r,"body","[begin]");return[].map.call(l,e=>{var r,i,l;let u,c,d,h=function e(t,r){return[].slice.call(t.childNodes).reduce((t,i,n)=>{var s;return"br"===i.nodeName&&n?t+"\n":null!=(s=i.childNodes)&&s.length?e(i,r):r?t+i.textContent.trim().replace(/\s+/g," "):t+i.textContent},"")}(e,s);if(!h||!e.hasAttribute("begin"))return null;let f=sC(e.getAttribute("begin"),n),p=sC(e.getAttribute("dur"),n),g=sC(e.getAttribute("end"),n);if(null===f)throw sk(e);if(null===g){if(null===p)throw sk(e);g=f+p}let m=new so(f-t,g-t,h);m.id=sb(m.startTime,m.endTime,m.text);let y=(r=o[e.getAttribute("region")],i=a[e.getAttribute("style")],l=a,u="http://www.w3.org/ns/ttml#styling",c=null,(d=null!=r&&r.hasAttribute("style")?r.getAttribute("style"):null)&&l.hasOwnProperty(d)&&(c=l[d]),["displayAlign","textAlign","color","backgroundColor","fontSize","fontFamily"].reduce((e,t)=>{let n=sI(i,u,t)||sI(r,u,t)||sI(c,u,t);return n&&(e[t]=n),e},{})),{textAlign:v}=y;if(v){let e=sT[v];e&&(m.lineAlign=e),m.align=v}return D(m,y),m}).filter(e=>null!==e)}(e,a)))}catch(e){i(e)}}function sA(e,t,r){let i=e.getElementsByTagName(t)[0];return i?[].slice.call(i.querySelectorAll(r)):[]}function sR(e){return e.reduce((e,t)=>{let r=t.getAttribute("xml:id");return r&&(e[r]=t),e},{})}function sI(e,t,r){return e&&e.hasAttributeNS(t,r)?e.getAttributeNS(t,r):null}function sk(e){return Error(`Could not parse ttml timestamp ${e}`)}function sC(e,t){var r,i;let n,s;if(!e)return null;let a=su(e);return null===a&&(sS.test(e)?(r=e,i=t,s=(0|(n=sS.exec(r))[4])+(0|n[5])/i.subFrameRate,a=(0|n[1])*3600+(0|n[2])*60+(0|n[3])+s/i.frameRate):sx.test(e)&&(a=function(e,t){let r=sx.exec(e),i=Number(r[1]);switch(r[2]){case"h":return 3600*i;case"m":return 60*i;case"ms":return 1e3*i;case"f":return i/t.frameRate;case"t":return i/t.tickRate}return i}(e,t))),a}class sD{constructor(e,t){this.timelineController=void 0,this.cueRanges=[],this.trackName=void 0,this.startTime=null,this.endTime=null,this.screen=null,this.timelineController=e,this.trackName=t}dispatchCue(){null!==this.startTime&&(this.timelineController.addCues(this.trackName,this.startTime,this.endTime,this.screen,this.cueRanges),this.startTime=null)}newCue(e,t,r){(null===this.startTime||this.startTime>e)&&(this.startTime=e),this.endTime=t,this.screen=r,this.timelineController.createCaptionsTrack(this.trackName)}reset(){this.cueRanges=[],this.startTime=null}}function sL(e){return e.characteristics&&/transcribes-spoken-dialog/gi.test(e.characteristics)&&/describes-music-and-sound/gi.test(e.characteristics)?"captions":"subtitles"}function sO(e,t){return!!e&&e.kind===sL(t)&&iJ(t,e)}function sP(){return{ccOffset:0,presentationOffset:0,0:{start:0,prevCC:-1,new:!0}}}let sF=/\s/,sN={newCue(e,t,r,i){let n,s,a,o,l,u=[],c=self.VTTCue||self.TextTrackCue;for(let h=0;h<i.rows.length;h++)if(n=i.rows[h],a=!0,o=0,l="",!n.isEmpty()){var d;for(let e=0;e<n.chars.length;e++)sF.test(n.chars[e].uchar)&&a?o++:(l+=n.chars[e].uchar,a=!1);n.cueStartTime=t,t===r&&(r+=1e-4),o>=16?o--:o++;let i=sp(l.trim()),f=sb(t,r,i);null!=e&&null!=(d=e.cues)&&d.getCueById(f)||((s=new c(t,r,i)).id=f,s.line=h+1,s.align="left",s.position=10+Math.min(80,10*Math.floor(8*o/32)),u.push(s))}return e&&u.length&&(u.sort((e,t)=>
2457"auto"===e.line||"auto"===t.line?0:e.line>8&&t.line>8?t.line-e.line:e.line-t.line),u.forEach(t=>nj(e,t))),u}},sM=/(\d+)-(\d+)\/(\d+)/;class sj{constructor(e){this.fetchSetup=void 0,this.requestTimeout=void 0,this.request=null,this.response=null,this.controller=void 0,this.context=null,this.config=null,this.callbacks=null,this.stats=void 0,this.loader=null,this.fetchSetup=e.fetchSetup||s$,this.controller=new self.AbortController,this.stats=new K}destroy(){this.loader=this.callbacks=this.context=this.config=this.request=null,this.abortInternal(),this.response=null,this.fetchSetup=this.controller=this.stats=null}abortInternal(){this.controller&&!this.stats.loading.end&&(this.stats.aborted=!0,this.controller.abort())}abort(){var e;this.abortInternal(),null!=(e=this.callbacks)&&e.onAbort&&this.callbacks.onAbort(this.stats,this.context,this.response)}load(e,t,i){var n;let s,a=this.stats;if(a.loading.start)throw Error("Loader can only be used once.");a.loading.start=self.performance.now();let o=(n=e,s={method:"GET",mode:"cors",credentials:"same-origin",signal:this.controller.signal,headers:new self.Headers(D({},n.headers))},n.rangeEnd&&s.headers.set("Range","bytes="+n.rangeStart+"-"+String(n.rangeEnd-1)),s),l="arraybuffer"===e.responseType,u=l?"byteLength":"length",{maxTimeToFirstByteMs:c,maxLoadTimeMs:d}=t.loadPolicy;this.context=e,this.config=t,this.callbacks=i,this.request=this.fetchSetup(e,o),self.clearTimeout(this.requestTimeout),t.timeout=c&&r(c)?c:d,this.requestTimeout=self.setTimeout(()=>{this.callbacks&&(this.abortInternal(),this.callbacks.onTimeout(a,e,this.response))},t.timeout),(iq(this.request)?this.request.then(self.fetch):self.fetch(this.request)).then(i=>{var n;this.response=this.loader=i;let s=Math.max(self.performance.now(),a.loading.start);if(self.clearTimeout(this.requestTimeout),t.timeout=d,this.requestTimeout=self.setTimeout(()=>{this.callbacks&&(this.abortInternal(),this.callbacks.onTimeout(a,e,this.response))},d-(s-a.loading.start)),!i.ok){let{status:e,statusText:t}=i;throw new sU(t||"fetch, bad network response",e,i)}a.loading.first=s,a.total=function(e){let t=e.get("Content-Range");if(t){let e=function(e){let t=sM.exec(e);if(t)return parseInt(t[2])-parseInt(t[1])+1}(t);if(r(e))return e}let i=e.get("Content-Length");if(i)return parseInt(i)}(i.headers)||a.total;let o=null==(n=this.callbacks)?void 0:n.onProgress;return o&&r(t.highWaterMark)?this.loadProgressively(i,a,e,t.highWaterMark,o):l?i.arrayBuffer():"json"===e.responseType?i.json():i.text()}).then(i=>{var n,s;let o=this.response;if(!o)throw Error("loader destroyed");self.clearTimeout(this.requestTimeout),a.loading.end=Math.max(self.performance.now(),a.loading.first);let l=i[u];l&&(a.loaded=a.total=l);let c={url:o.url,data:i,code:o.status},d=null==(n=this.callbacks)?void 0:n.onProgress;d&&!r(t.highWaterMark)&&d(a,e,i,o),null==(s=this.callbacks)||s.onSuccess(c,a,e,o)}).catch(t=>{var r;if(self.clearTimeout(this.requestTimeout),a.aborted)return;let i=t&&t.code||0,n=t?t.message:null;null==(r=this.callbacks)||r.onError({code:i,text:n},e,t?t.details:null,a)})}getCacheAge(){let e=null;if(this.response){let t=this.response.headers.get("age");e=t?parseFloat(t):null}return e}getResponseHeader(e){return this.response?this.response.headers.get(e):null}loadProgressively(e,t,r,i=0,n){let s=new rV,a=e.body.getReader(),o=()=>a.read().then(a=>{if(a.done)return s.dataLength&&n(t,r,s.flush().buffer,e),Promise.resolve(new ArrayBuffer(0));let l=a.value,u=l.length;return t.loaded+=u,u<i||s.dataLength?(s.push(l),s.dataLength>=i&&n(t,r,s.flush().buffer,e)):n(t,r,l.buffer,e),o()}).catch(()=>Promise.reject());return o()}}function s$(e,t){return new self.Request(e.url,t)}class sU extends Error{constructor(e,t,r){super(e),this.code=void 0,this.details=void 0,this.code=t,this.details=r}}let sB=/^age:\s*[\d.]+\s*$/im;class sV{constructor(e){this.xhrSetup=void 0,this.requestTimeout=void 0,this.retryTimeout=void 0,this.retryDelay=void 0,this.config=null,this.callbacks=null,this.context=null,this.loader=null,this.stats=void 0,this.xhrSetup=e&&e.xhrSetup||null,this.stats=new K,this.retryDelay=0}destroy(){this.callbacks=null,this.abortInternal(),this.loader=null,this.config=null,this.context=null,this.xhrSetup=null}abortInternal(){let e=this.loader;self.clearTimeout(this.requestTimeout),self.clearTimeout(this.retryTimeout),e&&(e.onreadystatechange=null,e.onprogress=null,4!==e.readyState&&(this.stats.aborted=!0,e.abort()))}abort(){var e;this.abortInternal(),null!=(e=this.callbacks)&&e.onAbort&&this.callbacks.onAbort(this.stats,this.context,this.loader)}load(e,t,r){if(this.stats.loading.start)throw Error("Loader can only be used once.");this.stats.loading.start=self.performance.now(),this.context=e,this.config=t,this.callbacks=r,this.loadInternal()}loadInternal(){let{config:e,context:t}=this;if(!e||!t)return;let r=this.loader=new self.XMLHttpRequest,i=this.stats;i.loading.first=0,i.loaded=0,i.aborted=!1;let n=this.xhrSetup;n?Promise.resolve().then(()=>
2457{if(this.loader===r&&!this.stats.aborted)return n(r,t.url)}).catch(e=>{if(this.loader===r&&!this.stats.aborted)return r.open("GET",t.url,!0),n(r,t.url)}).then(()=>{this.loader!==r||this.stats.aborted||this.openAndSendXhr(r,t,e)}).catch(e=>{var n;null==(n=this.callbacks)||n.onError({code:r.status,text:e.message},t,r,i)}):this.openAndSendXhr(r,t,e)}openAndSendXhr(e,t,i){e.readyState||e.open("GET",t.url,!0);let n=t.headers,{maxTimeToFirstByteMs:s,maxLoadTimeMs:a}=i.loadPolicy;if(n)for(let t in n)e.setRequestHeader(t,n[t]);t.rangeEnd&&e.setRequestHeader("Range","bytes="+t.rangeStart+"-"+(t.rangeEnd-1)),e.onreadystatechange=this.readystatechange.bind(this),e.onprogress=this.loadprogress.bind(this),e.responseType=t.responseType,self.clearTimeout(this.requestTimeout),i.timeout=s&&r(s)?s:a,this.requestTimeout=self.setTimeout(this.loadtimeout.bind(this),i.timeout),e.send()}readystatechange(){let{context:e,loader:t,stats:r}=this;if(!e||!t)return;let i=t.readyState,n=this.config;if(!r.aborted&&i>=2&&(0===r.loading.first&&(r.loading.first=Math.max(self.performance.now(),r.loading.start),n.timeout!==n.loadPolicy.maxLoadTimeMs&&(self.clearTimeout(this.requestTimeout),n.timeout=n.loadPolicy.maxLoadTimeMs,this.requestTimeout=self.setTimeout(this.loadtimeout.bind(this),n.loadPolicy.maxLoadTimeMs-(r.loading.first-r.loading.start)))),4===i)){var s,a,o;self.clearTimeout(this.requestTimeout),t.onreadystatechange=null,t.onprogress=null;let i=t.status,l="text"===t.responseType?t.responseText:null;if(i>=200&&i<300){let n=null!=l?l:t.response;if(null!=n){r.loading.end=Math.max(self.performance.now(),r.loading.first),r.loaded=r.total="arraybuffer"===t.responseType?n.byteLength:n.length,r.bwEstimate=8e3*r.total/(r.loading.end-r.loading.first);let o=null==(s=this.callbacks)?void 0:s.onProgress;o&&o(r,e,n,t);let l={url:t.responseURL,data:n,code:i};null==(a=this.callbacks)||a.onSuccess(l,r,e,t);return}}let u=n.loadPolicy.errorRetry;tt(u,r.retry,!1,{url:e.url,data:void 0,code:i})?this.retry(u):($.error(`${i} while loading ${e.url}`),null==(o=this.callbacks)||o.onError({code:i,text:t.statusText},e,t,r))}}loadtimeout(){if(!this.config)return;let e=this.config.loadPolicy.timeoutRetry;if(tt(e,this.stats.retry,!0))this.retry(e);else{var t;$.warn(`timeout while loading ${null==(t=this.context)?void 0:t.url}`);let e=this.callbacks;e&&(this.abortInternal(),e.onTimeout(this.stats,this.context,this.loader))}}retry(e){let{context:t,stats:r}=this;this.retryDelay=e9(e,r.retry),r.retry++,$.warn(`${status?"HTTP Status "+status:"Timeout"} while loading ${null==t?void 0:t.url}, retrying ${r.retry}/${e.maxNumRetry} in ${this.retryDelay}ms`),this.abortInternal(),this.loader=null,self.clearTimeout(this.retryTimeout),this.retryTimeout=self.setTimeout(this.loadInternal.bind(this),this.retryDelay)}loadprogress(e){let t=this.stats;t.loaded=e.loaded,e.lengthComputable&&(t.total=e.total)}getCacheAge(){let e=null;if(this.loader&&sB.test(this.loader.getAllResponseHeaders())){let t=this.loader.getResponseHeader("age");e=t?parseFloat(t):null}return e}getResponseHeader(e){return this.loader&&RegExp(`^${e}:\\s*[\\d.]+\\s*$`,"im").test(this.loader.getAllResponseHeaders())?this.loader.getResponseHeader(e):null}}let sG=O(O({autoStartLoad:!0,startPosition:-1,defaultAudioCodec:void 0,debug:!1,capLevelOnFPSDrop:!1,capLevelToPlayerSize:!1,ignoreDevicePixelRatio:!1,maxDevicePixelRatio:1/0,preferManagedMediaSource:!0,initialLiveManifestSize:1,maxBufferLength:30,backBufferLength:1/0,frontBufferFlushThreshold:1/0,startOnSegmentBoundary:!1,maxBufferSize:6e7,maxFragLookUpTolerance:.25,maxBufferHole:.1,detectStallWithCurrentTimeMs:1250,highBufferWatchdogPeriod:2,nudgeOffset:.1,nudgeMaxRetry:3,nudgeOnVideoHole:!0,liveSyncMode:"edge",liveSyncDurationCount:3,liveSyncOnStallIncrease:1,liveMaxLatencyDurationCount:1/0,liveSyncDuration:void 0,liveMaxLatencyDuration:void 0,maxLiveSyncPlaybackRate:1,liveDurationInfinity:!1,liveBackBufferLength:null,maxMaxBufferLength:600,enableWorker:!0,workerPath:null,enableSoftwareAES:!0,startLevel:void 0,startFragPrefetch:!1,fpsDroppedMonitoringPeriod:5e3,fpsDroppedMonitoringThreshold:.2,appendErrorMaxRetry:3,ignorePlaylistParsingErrors:!1,loader:sV,fLoader:void 0,pLoader:void 0,xhrSetup:void 0,licenseXhrSetup:void 0,licenseResponseCallback:void 0,abrController:class extends P{constructor(e){super("abr",e.logger),this.hls=void 0,this.lastLevelLoadSec=0,this.lastLoadedFragLevel=-1,this.firstSelection=-1,this._nextAutoLevel=-1,this.nextAutoLevelKey="",this.audioTracksByGroup=null,this.co
2457decTiers=null,this.timer=-1,this.fragCurrent=null,this.partCurrent=null,this.bitrateTestDelay=0,this.rebufferNotice=-1,this.supportedCache={},this.bwEstimator=void 0,this._abandonRulesCheck=e=>{var t;let i,{fragCurrent:n,partCurrent:s,hls:a}=this,{autoLevelEnabled:l,media:u}=a;if(!n||!u)return;let c=performance.now(),d=s?s.stats:n.stats,h=s?s.duration:n.duration,f=c-d.loading.start,p=a.minAutoLevel,g=n.level,m=this._nextAutoLevel;if(d.aborted||d.loaded&&d.loaded===d.total||g<=p){this.clearTimer(),this._nextAutoLevel=-1;return}if(!l)return;let y=m>-1&&m!==g,v=!!e||y;if(!v&&(u.paused||!u.playbackRate||!u.readyState))return;let b=a.mainForwardBufferInfo;if(!v&&null===b)return;let _=this.bwEstimator.getEstimateTTFB(),E=Math.abs(u.playbackRate);if(f<=Math.max(_,h/(2*E)*1e3))return;let S=b?b.len/E:0,x=d.loading.first?d.loading.first-d.loading.start:-1,T=d.loaded&&x>-1,w=this.getBwEstimate(),A=a.levels,R=A[g],I=Math.max(d.loaded,Math.round(h*(n.bitrate||R.averageBitrate)/8)),k=T?f-x:f;k<1&&T&&(k=Math.min(f,8*d.loaded/w));let C=T?1e3*d.loaded/k:0,D=_/1e3,L=C?(I-d.loaded)/C:8*I/w+D;if(L<=S)return;let O=C?8*C:w,P=(null==(t=(null==e?void 0:e.details)||this.hls.latestLevelDetails)?void 0:t.live)===!0,F=this.hls.config.abrBandWidthUpFactor,N=1/0;for(i=g-1;i>p;i--){let e=A[i].maxBitrate,t=!A[i].details||P;if((N=this.getTimeToLoadFrag(D,O,h*e,t))<Math.min(S,h+D))break}if(N>=L||N>10*h)return;T?this.bwEstimator.sample(f-Math.min(_,x),d.loaded):this.bwEstimator.sampleTTFB(f);let M=A[i].maxBitrate;this.getBwEstimate()*F>M&&this.resetEstimator(M);let j=this.findBestLevel(M,p,i,0,S,1,1);j>-1&&(i=j),this.warn(`Fragment ${n.sn}${s?" part "+s.index:""} of level ${g} is loading too slowly; 2458 Fragment duration: ${n.duration.toFixed(3)} 2459 Time to underbuffer: ${S.toFixed(3)} s 2460 Estimated load time for current fragment: ${L.toFixed(3)} s 2461 Estimated load time for down switch fragment: ${N.toFixed(3)} s 2462 TTFB estimate: ${0|x} ms 2463 Current BW estimate: ${r(w)?0|w:"Unknown"} bps 2464 New BW estimate: ${0|this.getBwEstimate()} bps 2465 Switching to level ${i} @ ${0|M} bps`),a.nextLoadLevel=a.nextAutoLevel=i,this.clearTimer();let $=()=>{if(this.clearTimer(),this.fragCurrent===n&&this.hls.loadLevel===i&&i>0){let e=this.getStarvationDelay();if(this.warn(`Aborting inflight request ${i>0?"and switching down":""} 2466 Fragment duration: ${n.duration.toFixed(3)} s 2467 Time to underbuffer: ${e.toFixed(3)} s`),n.abortRequests(),this.fragCurrent=this.partCurrent=null,i>p){let t=this.findBestLevel(this.hls.levels[p].bitrate,p,i,0,e,1,1);-1===t&&(t=p),this.hls.nextLoadLevel=this.hls.nextAutoLevel=t,this.resetEstimator(this.hls.levels[t].bitrate)}}};y||L>2*N?$():this.timer=self.setInterval($,1e3*N),a.trigger(o.FRAG_LOAD_EMERGENCY_ABORTED,{frag:n,part:s,stats:d})},this.hls=e,this.bwEstimator=this.initEstimator(),this.registerListeners()}resetEstimator(e){e&&(this.log(`setting initial bwe to ${e}`),this.hls.config.abrEwmaDefaultEstimate=e),this.firstSelection=-1,this.bwEstimator=this.initEstimator()}initEstimator(){let e=this.hls.config;return new C(e.abrEwmaSlowVoD,e.abrEwmaFastVoD,e.abrEwmaDefaultEstimate)}registerListeners(){let{hls:e}=this;e.on(o.MANIFEST_LOADING,this.onManifestLoading,this),e.on(o.FRAG_LOADING,this.onFragLoading,this),e.on(o.FRAG_LOADED,this.onFragLoaded,this),e.on(o.FRAG_BUFFERED,this.onFragBuffered,this),e.on(o.LEVEL_SWITCHING,this.onLevelSwitching,this),e.on(o.LEVEL_LOADED,this.onLevelLoaded,this),e.on(o.LEVELS_UPDATED,this.onLevelsUpdated,this),e.on(o.MAX_AUTO_LEVEL_UPDATED,this.onMaxAutoLevelUpdated,this),e.on(o.ERROR,this.onError,this)}unregisterListeners(){let{hls:e}=this;e&&(e.off(o.MANIFEST_LOADING,this.onManifestLoading,this),e.off(o.FRAG_LOADING,this.onFragLoading,this),e.off(o.FRAG_LOADED,this.onFragLoaded,this),e.off(o.FRAG_BUFFERED,this.onFragBuffered,this),e.off(o.LEVEL_SWITCHING,this.onLevelSwitching,this),e.off(o.LEVEL_LOADED,this.onLevelLoaded,this),e.off(o.LEVELS_UPDATED,this.onLevelsUpdated,this),e.off(o.MAX_AUTO_LEVEL_UPDATED,this.onMaxAutoLevelUpdated,this),e.off(o.ERROR,this.onError,this))}destroy(){this.unregisterListeners(),this.clearTimer(),this.hls=this._abandonRulesCheck=this.supportedCache=null,this.fragCurrent=this.partCurrent=null}onManifestLoading(e,t){this.lastLoadedFragLevel=-1,this.firstSelection=-1,this.lastLevelLoadSec=0,this.supportedCache={},this.fragCurrent=this.partCurrent=null,this.onLevelsUpdated(),this.clearTimer()}onLevelsUpdated(){this.lastLoadedFragLevel>-1&&this.fragCurrent&&(this.lastLoadedFragLevel=this.fragCurrent.level),this._nextAutoLevel=-1,this.onMaxAutoLevelUpdated(),this.codecTiers=null,this.audioTracksByGroup=null}onMaxAutoLevelUpdated(){this.firstSelection=-1,this.nextAutoLevelKey=""}onFragLoading(e,t){let r=t.frag;if(!this.ignoreFragment(r)){if(!r.bitrateTest){var i;this.fragCurrent=r,this.partCurrent=null!=(i=t.part)?i:null}this.clearTimer(),this.timer=self.setInterval(this._abandonRulesCheck,100)}}onLevelSwitching(e,t){this.clearTimer()}onError(e,t){if(!t.fatal)switch(t.details){case a.BUFFER_ADD_CODEC_ERROR:case a.BUFFER_APPEND_ERROR:this.lastLoadedFragLevel=-1,this.firstSelection=-1;break;case a.FRAG_LOAD_TIMEOUT:{let e=t.frag,{fragCurrent:r,partCurrent:i}=this;if(e&&r&&e.sn===r.sn&&e.level===r.level){let t=performance.now(),r=i?i.stats:e.stats,n=t-r.loading.start,s=r.loading.first?r.loading.first-r.loading.start:-1;if(r.loaded&&s>-1){let e=this.bwEstimator.getEstimateTTFB();this.bwEstimator.sample(n-Math.min(e,s),r.loaded)}else this.bwEstimator.sampleTTFB(n)}}}}
vendor: 2,418 bytes, line 2467
2467getTimeToLoadFrag(e,t,r,i){let n=i?e+this.lastLevelLoadSec:0;return e+r/t+n}onLevelLoaded(e,t){let i=this.hls.config,{loading:n}=t.stats,s=n.end-n.first;r(s)&&(this.lastLevelLoadSec=s/1e3),t.details.live?this.bwEstimator.update(i.abrEwmaSlowLive,i.abrEwmaFastLive):this.bwEstimator.update(i.abrEwmaSlowVoD,i.abrEwmaFastVoD),this.timer>-1&&this._abandonRulesCheck(t.levelInfo)}onFragLoaded(e,{frag:t,part:r}){let i=r?r.stats:t.stats;if(t.type===A&&this.bwEstimator.sampleTTFB(i.loading.first-i.loading.start),!this.ignoreFragment(t)){if(this.clearTimer(),t.level===this._nextAutoLevel&&(this._nextAutoLevel=-1),this.firstSelection=-1,this.hls.config.abrMaxWithRealBitrate){let e=r?r.duration:t.duration,n=this.hls.levels[t.level],s=(n.loaded?n.loaded.bytes:0)+i.loaded,a=(n.loaded?n.loaded.duration:0)+e;n.loaded={bytes:s,duration:a},n.realBitrate=Math.round(8*s/a)}if(t.bitrateTest){let e={stats:i,frag:t,part:r,id:t.type};this.onFragBuffered(o.FRAG_BUFFERED,e),t.bitrateTest=!1}else this.lastLoadedFragLevel=t.level}}onFragBuffered(e,t){let{frag:r,part:i}=t,n=null!=i&&i.stats.loaded?i.stats:r.stats;if(n.aborted||this.ignoreFragment(r))return;let s=n.parsing.end-n.loading.start-Math.min(n.loading.first-n.loading.start,this.bwEstimator.getEstimateTTFB());this.bwEstimator.sample(s,n.loaded),n.bwEstimate=this.getBwEstimate(),r.bitrateTest?this.bitrateTestDelay=s/1e3:this.bitrateTestDelay=0}ignoreFragment(e){return e.type!==A||"initSegment"===e.sn}clearTimer(){this.timer>-1&&(self.clearInterval(this.timer),this.timer=-1)}get firstAutoLevel(){let{maxAutoLevel:e,minAutoLevel:t}=this.hls,r=this.getBwEstimate(),i=this.hls.config.maxStarvationDelay,n=this.findBestLevel(r,t,e,0,i,1,1);if(n>-1)return n;let s=this.hls.firstLevel,a=Math.min(Math.max(s,t),e);return this.warn(`Could not find best starting auto level. Defaulting to first in playlist ${s} clamped to ${a}`),a}get forcedAutoLevel(){return this.nextAutoLevelKey?-1:this._nextAutoLevel}get nextAutoLevel(){let e=this.forcedAutoLevel,t=this.bwEstimator.canEstimate(),r=this.lastLoadedFragLevel>-1;if(-1!==e&&(!t||!r||this.nextAutoLevelKey===this.getAutoLevelKey()))return e;let i=t&&r?this.getNextABRAutoLevel():this.firstAutoLevel;if(-1!==e){let t=this.hls.levels;if(t.length>Math.max(e,i)&&t[e].loadError<=t[i].loadError)return e}return this._nextAutoLevel=i,this.nextAutoLevelKey=this.getAutoLevelKey(),i}getAutoLevelKey(){return`${this.getBwEstimate()}
2467_${this.getStarvationDelay().toFixed(2)}`}getNextABRAutoLevel(){let{fragCurrent:e,partCurrent:t,hls:r}=this;if(r.levels.length<=1)return r.loadLevel;let{maxAutoLevel:i,config:n,minAutoLevel:s}=r,a=t?t.duration:e?e.duration:0,o=this.getBwEstimate(),l=this.getStarvationDelay(),u=n.abrBandWidthFactor,c=n.abrBandWidthUpFactor;if(l){let e=this.findBestLevel(o,s,i,l,0,u,c);if(e>=0)return this.rebufferNotice=-1,e}let d=a?Math.min(a,n.maxStarvationDelay):n.maxStarvationDelay;if(!l){let e=this.bitrateTestDelay;e&&(d=(a?Math.min(a,n.maxLoadingDelay):n.maxLoadingDelay)-e,this.info(`bitrate test took ${Math.round(1e3*e)}ms, set first fragment max fetchDuration to ${Math.round(1e3*d)} ms`),u=c=1)}let h=this.findBestLevel(o,s,i,l,d,u,c);if(this.rebufferNotice!==h&&(this.rebufferNotice=h,this.info(`${l?"rebuffering expected":"buffer is empty"}, optimal quality level ${h}`)),h>-1)return h;let f=r.levels[s],p=r.loadLevelObj;return p&&(null==f?void 0:f.bitrate)<p.bitrate?s:r.loadLevel}getStarvationDelay(){let e=this.hls,t=e.media;if(!t)return 1/0;let r=t&&0!==t.playbackRate?Math.abs(t.playbackRate):1,i=e.mainForwardBufferInfo;return(i?i.len:0)/r}getBwEstimate(){return this.bwEstimator.canEstimate()?this.bwEstimator.getEstimate():this.hls.config.abrEwmaDefaultEstimate}findBestLevel(e,t,i,n,s,a,o){var l,u;let c,d=n+s,h=this.lastLoadedFragLevel,f=-1===h?this.hls.firstLevel:h,{fragCurrent:p,partCurrent:g}=this,{levels:m,allAudioTracks:y,loadLevel:v,config:b}=this.hls;if(1===m.length)return 0;let _=m[f],E=!!(null!=(l=this.hls.latestLevelDetails)&&l.live),S=-1===v||-1===h,x="SDR",T=(null==_?void 0:_.frameRate)||0,{audioPreference:w,videoPreference:A}=b,R=this.audioTracksByGroup||(this.audioTracksByGroup=eW(y)),I=-1;if(S){if(-1!==this.firstSelection)return this.firstSelection;let n=function(e,t,i,n,s){let a=Object.keys(e),o=null==n?void 0:n.channels,l=null==n?void 0:n.audioCodec,u=null==s?void 0:s.videoCodec,c=o&&2===parseInt(o),d=!1,h=!1,f=1/0,p=1/0,g=1/0,m=1/0,y=0,v=[],{preferHDR:b,allowedVideoRanges:_}=function(e,t){let r=!1,i=[];if(e&&(r="SDR"!==e,i=[e]),t){let e="SDR"!==(i=t.allowedVideoRanges||eB.slice(0)).join("")&&!t.videoCodec;(r=void 0!==t.preferHDR?t.preferHDR:e&&function(){if("function"==typeof matchMedia){let e=matchMedia("(dynamic-range: high)"),t=matchMedia("bad query");if(e.media!==t.media)return!0===e.matches}return!1}())||(i=["SDR"])}return{preferHDR:r,allowedVideoRanges:i}}(t,s);for(let t=a.length;t--;){let r=e[a[t]];d||(d=r.channels[2]>0),f=Math.min(f,r.minHeight),p=Math.min(p,r.minFramerate),g=Math.min(g,r.minBitrate),_.filter(e=>r.videoRanges[e]>0).length>0&&(h=!0)}f=r(f)?f:0,p=r(p)?p:0;let E=Math.max(1080,f),S=Math.max(30,p);i=Math.max(g=r(g)?g:i,i),h||(t=void 0);let x=a.length>1;return{codecSet:a.reduce((t,r)=>{let n=e[r];if(r===t)return t;if(v=h?_.filter(e=>n.videoRanges[e]>0):[],x){if(n.minBitrate>i)return eK(r,`min bitrate of ${n.minBitrate} > current estimate of ${i}`),t;if(!n.hasDefaultAudio)return eK(r,"no renditions with default or auto-select sound found"),t;if(l&&r.indexOf(l.substring(0,4))%5!=0)return eK(r,`audio codec preference "${l}" not found`),t;if(o&&!c){if(!n.channels[o])return eK(r,`no renditions with ${o} channel sound found (channels options: ${Object.keys(n.channels)})`),t}else if((!l||c)&&d&&0===n.channels["2"])return eK(r,"no renditions with stereo sound found"),t;if(n.minHeight>E)return eK(r,`min resolution of ${n.minHeight} > maximum of ${E}`),t;if(n.minFramerate>S)return eK(r,`min framerate of ${n.minFramerate} > maximum of ${S}`),t;if(!v.some(e=>n.videoRanges[e]>0))return eK(r,`no variants with VIDEO-RANGE of ${ez(v)} found`),t;if(u&&r.indexOf(u.substring(0,4))%5!=0)return eK(r,`video codec preference "${u}" not found`),t;if(n.maxScore<y)return eK(r,`max score of ${n.maxScore} < selected max of ${y}`),t}return t&&(eR(r)>=eR(t)||n.fragmentError>e[t].fragmentError)?t:(m=n.minIndex,y=n.maxScore,r)},void 0),videoRanges:v,preferHDR:b,minFramerate:p,minBitrate:g,minIndex:m}}(this.codecTiers||(this.codecTiers=m.slice(t,i+1).reduce((e,t,r)=>{if(!t.codecSet)return e;let i=t.audioGroups,n=e[t.codecSet];n||(e[t.codecSet]=n={minBitrate:1/0,minHeight:1/0,minFramerate:1/0,minIndex:r,maxScore:0,videoRanges:{SDR:0},channels:{2:0},hasDefaultAudio:!i,fragmentError:0}
2467),n.minBitrate=Math.min(n.minBitrate,t.bitrate);let s=Math.min(t.height,t.width);return n.minHeight=Math.min(n.minHeight,s),n.minFramerate=Math.min(n.minFramerate,t.frameRate),n.minIndex=Math.min(n.minIndex,r),n.maxScore=Math.max(n.maxScore,t.score),n.fragmentError+=t.fragmentError,n.videoRanges[t.videoRange]=(n.videoRanges[t.videoRange]||0)+1,i&&i.forEach(e=>{if(!e)return;let t=R.groups[e];t&&(n.hasDefaultAudio=n.hasDefaultAudio||R.hasDefaultAudio?t.hasDefault:t.hasAutoSelect||!R.hasDefaultAudio&&!R.hasAutoSelectAudio,Object.keys(t.channels).forEach(e=>{n.channels[e]=(n.channels[e]||0)+t.channels[e]}))}),e},{})),x,e,w,A),{codecSet:s,videoRanges:a,minFramerate:o,minBitrate:l,minIndex:u,preferHDR:d}=n;I=u,c=s,x=d?a[a.length-1]:a[0],T=o,e=Math.max(e,l),this.log(`picked start tier ${ez(n)}`)}else c=null==_?void 0:_.codecSet,x=null==_?void 0:_.videoRange;let k=g?g.duration:p?p.duration:0,C=this.bwEstimator.getEstimateTTFB()/1e3,D=[];for(let l=i;l>=t;l--){let t,p=m[l],y=l>f;if(!p)continue;if(b.useMediaCapabilities&&!p.supportedResult&&!p.supportedPromise){let t=navigator.mediaCapabilities;"function"==typeof(null==t?void 0:t.decodingInfo)&&function(e,t,i,n,s,a){let o=e.videoCodec,l=e.audioCodec?e.audioGroups:null,u=null==a?void 0:a.audioCodec,c=null==a?void 0:a.channels,d=c?parseInt(c):u?1/0:2,h=null;if(null!=l&&l.length)try{h=1===l.length&&l[0]?t.groups[l[0]].channels:l.reduce((e,r)=>{if(r){let i=t.groups[r];if(!i)throw Error(`Audio track group ${r} not found`);Object.keys(i.channels).forEach(t=>{e[t]=(e[t]||0)+i.channels[t]})}return e},{2:0})}catch(e){return!0}return void 0!==o&&(o.split(",").some(e=>ev(e))||e.width>1920&&e.height>1088||e.height>1920&&e.width>1088||e.frameRate>Math.max(n,30)||"SDR"!==e.videoRange&&e.videoRange!==i||e.bitrate>Math.max(s,8e6))||!!h&&r(d)&&Object.keys(h).some(e=>parseInt(e)>d)}(p,R,x,T,e,w)?(p.supportedPromise=ej(p,R,t,this.supportedCache),p.supportedPromise.then(e=>{if(!this.hls)return;p.supportedResult=e;let t=this.hls.levels,r=t.indexOf(p);e.error?this.warn(`MediaCapabilities decodingInfo error: "${e.error}" for level ${r} ${ez(e)}`):e.supported?e.decodingInfoResults.some(e=>!1===e.smooth||!1===e.powerEfficient)&&this.log(`MediaCapabilities decodingInfo for level ${r} not smooth or powerEfficient: ${ez(e)}`):(this.warn(`Unsupported MediaCapabilities decodingInfo result for level ${r} ${ez(e)}`),r>-1&&t.length>1&&(this.log(`Removing unsupported level ${r}`),this.hls.removeLevel(r),-1===this.hls.loadLevel&&(this.hls.nextLoadLevel=0)))}).catch(e=>{this.warn(`Error handling MediaCapabilities decodingInfo: ${e}`)})):p.supportedResult=eN}if((c&&p.codecSet!==c||x&&p.videoRange!==x||y&&T>p.frameRate||!y&&T>0&&T<p.frameRate||null!=(u=p.supportedResult)&&null!=(u=u.decodingInfoResults)&&u.some(e=>!1===e.smooth))&&(!S||l!==I)){D.push(l);continue}let _=p.details,A=(g?null==_?void 0:_.partTarget:null==_?void 0:_.averagetargetduration)||k;t=y?o*e:a*e;let L=k&&n>=2*k&&0===s?p.averageBitrate:p.maxBitrate,O=this.getTimeToLoadFrag(C,t,L*A,void 0===_);if(t>=L&&(l===h||0===p.loadError&&0===p.fragmentError)&&(O<=C||!r(O)||E&&!this.bitrateTestDelay||O<d)){let e=this.forcedAutoLevel;return l!==v&&(-1===e||e!==v)&&(D.length&&this.trace(`Skipped level(s) ${D.join(",")} of ${i} max with CODECS and VIDEO-RANGE:"${m[D[0]].codecs}" ${m[D[0]].videoRange}; not compatible with "${c}" ${x}`),this.info(`switch candidate:${f}->${l} adjustedbw(${Math.round(t)})-bitrate=${Math.round(t-L)} ttfb:${C.toFixed(1)} avgDuration:${A.toFixed(1)} maxFetchDuration:${d.toFixed(1)} fetchDuration:${O.toFixed(1)} firstSelection:${S} codecSet:${p.codecSet} videoRange:${p.videoRange} hls.loadLevel:${v}`)),S&&(this.firstSelection=l),l}}return -1}set nextAutoLevel(e){let t=this.deriveNextAutoLevel(e);this._nextAutoLevel!==t&&(this.nextAutoLevelKey="",this._nextAutoLevel=t)}deriveNextAutoLevel(e){let{maxAutoLevel:t,minAutoLevel:r}=this.hls;return Math.min(Math.max(e,r),t)}},bufferController:class extends P{constructor(e,t){super("buffer-controller",e.logger),this.hls=void 0,this.fragmentTracker=void 0,this.details=null,this._objectUrl=null,this.operationQueue=null,this.bufferCodecEventsTotal=0,this.media=null,this.mediaSource=null,this.lastMpegAudioChunk=null,this.blockedAudioAppend=null,this.lastVideoAppendEnd=0,this.appendSource=void 0,this.transferData=void 0,this.overrides=void 0,this.appendErrors={audio:0,video:0,audiovideo:0},this.tracks={},this.sourceBuffers=[[null,null],[null,null]],this._onEndStreaming=e=>{var t;this.hls&&(null==(t=this.mediaSource)?void 0:t.readyState)==="open"&&this.hls.pauseBuffer
2467ing()},this._onStartStreaming=e=>{this.hls&&this.hls.resumeBuffering()},this._onMediaSourceOpen=e=>{let{media:t,mediaSource:r}=this;e&&this.log("Media source opened"),t&&r&&(r.removeEventListener("sourceopen",this._onMediaSourceOpen),t.removeEventListener("emptied",this._onMediaEmptied),this.updateDuration(),this.hls.trigger(o.MEDIA_ATTACHED,{media:t,mediaSource:r}),null!==this.mediaSource&&this.checkPendingTracks())},this._onMediaSourceClose=()=>{this.log("Media source closed")},this._onMediaSourceEnded=()=>{this.log("Media source ended")},this._onMediaEmptied=()=>{let{mediaSrc:e,_objectUrl:t}=this;e!==t&&this.error(`Media element src was set while attaching MediaSource (${t} > ${e})`)},this.hls=e,this.fragmentTracker=t,this.appendSource=function(e){return"u">typeof self&&e===self.ManagedMediaSource}(U(e.config.preferManagedMediaSource)),this.initTracks(),this.registerListeners()}hasSourceTypes(){return Object.keys(this.tracks).length>0}destroy(){this.unregisterListeners(),this.details=null,this.lastMpegAudioChunk=this.blockedAudioAppend=null,this.transferData=this.overrides=void 0,this.operationQueue&&(this.operationQueue.destroy(),this.operationQueue=null),this.hls=this.fragmentTracker=null,this._onMediaSourceOpen=this._onMediaSourceClose=null,this._onMediaSourceEnded=null,this._onStartStreaming=this._onEndStreaming=null}registerListeners(){let{hls:e}=this;e.on(o.MEDIA_ATTACHING,this.onMediaAttaching,this),e.on(o.MEDIA_DETACHING,this.onMediaDetaching,this),e.on(o.MANIFEST_LOADING,this.onManifestLoading,this),e.on(o.MANIFEST_PARSED,this.onManifestParsed,this),e.on(o.BUFFER_RESET,this.onBufferReset,this),e.on(o.BUFFER_APPENDING,this.onBufferAppending,this),e.on(o.BUFFER_CODECS,this.onBufferCodecs,this),e.on(o.BUFFER_EOS,this.onBufferEos,this),e.on(o.BUFFER_FLUSHING,this.onBufferFlushing,this),e.on(o.LEVEL_UPDATED,this.onLevelUpdated,this),e.on(o.FRAG_PARSED,this.onFragParsed,this),e.on(o.FRAG_CHANGED,this.onFragChanged,this),e.on(o.ERROR,this.onError,this)}unregisterListeners(){let{hls:e}=this;e.off(o.MEDIA_ATTACHING,this.onMediaAttaching,this),e.off(o.MEDIA_DETACHING,this.onMediaDetaching,this),e.off(o.MANIFEST_LOADING,this.onManifestLoading,this),e.off(o.MANIFEST_PARSED,this.onManifestParsed,this),e.off(o.BUFFER_RESET,this.onBufferReset,this),e.off(o.BUFFER_APPENDING,this.onBufferAppending,this),e.off(o.BUFFER_CODECS,this.onBufferCodecs,this),e.off(o.BUFFER_EOS,this.onBufferEos,this),e.off(o.BUFFER_FLUSHING,this.onBufferFlushing,this),e.off(o.LEVEL_UPDATED,this.onLevelUpdated,this),e.off(o.FRAG_PARSED,this.onFragParsed,this),e.off(o.FRAG_CHANGED,this.onFragChanged,this),e.off(o.ERROR,this.onError,this)}transferMedia(){let{media:e,mediaSource:t}=this;if(!e)return null;let r={};if(this.operationQueue){let e=this.isUpdating();e||this.operationQueue.removeBlockers();let t=this.isQueued();(e||t)&&this.warn(`Transfering MediaSource with${t?" operations in queue":""}${e?" updating SourceBuffer(s)":""} ${this.operationQueue}`),this.operationQueue.destroy()}let i=this.transferData;return!this.sourceBufferCount&&i&&i.mediaSource===t?D(r,i.tracks):this.sourceBuffers.forEach(e=>{let[t]=e;t&&(r[t]=D({},this.tracks[t]),this.removeBuffer(t)),e[0]=e[1]=null}),{media:e,mediaSource:t,tracks:r}}initTracks(){this.sourceBuffers=[[null,null],[null,null]],this.tracks={},this.resetQueue(),this.resetAppendErrors(),this.lastMpegAudioChunk=this.blockedAudioAppend=null,this.lastVideoAppendEnd=0}onManifestLoading(){this.bufferCodecEventsTotal=0,this.details=null}onManifestParsed(e,t){var r;let i=2;(!t.audio||t.video)&&t.altAudio||(i=1),this.bufferCodecEventsTotal=i,this.log(`${i} bufferCodec event(s) expected.`),null!=(r=this.transferData)&&r.mediaSource&&this.sourceBufferCount&&i&&this.bufferCreated()}onMediaAttaching(e,t){let r=this.media=t.media;this.transferData=this.overrides=void 0;let i=U(this.appendSource);if(i){let e=!!t.mediaSource;(e||t.overrides)&&(this.transferData=t,this.overrides=t.overrides);let a=this.mediaSource=t.mediaSource||new i;if(this.assignMediaSource(a),e)this._objectUrl=r.src,this.attachTransferred();else{let e=this._objectUrl=self.URL.createObjectURL(a);if(this.appendSource)try{var n,s;let t;r.removeAttribute("src");let i=self.ManagedMediaSource;r.disableRemotePlayback=r.disableRemotePlayback||i&&a instanceof i,i3(r),n=r,s=e,(t=self.document.createElement("source")).type="video/mp4",t.src=s,n.appendChild(t),r.load()}catch(t){r.src=e}else r.src=e}r.addEventListener("emptied",this._onMediaEmptied)}}assignMediaSource(e){var t,r;this.log(`${(null==(t=this.transferData)?void 0:t.mediaSource)===e?"transferred":"created"}
2467 media source: ${null==(r=e.constructor)?void 0:r.name}`),e.addEventListener("sourceopen",this._onMediaSourceOpen),e.addEventListener("sourceended",this._onMediaSourceEnded),e.addEventListener("sourceclose",this._onMediaSourceClose),this.appendSource&&(e.addEventListener("startstreaming",this._onStartStreaming),e.addEventListener("endstreaming",this._onEndStreaming))}attachTransferred(){let e=this.media,t=this.transferData;if(!t||!e)return;let r=this.tracks,i=t.tracks,n=i?Object.keys(i):null,s=n?n.length:0,a=()=>{Promise.resolve().then(()=>{this.media&&this.mediaSourceOpenOrEnded&&this._onMediaSourceOpen()})};if(i&&n&&s){if(!this.tracksReady){this.hls.config.startFragPrefetch=!0,this.log("attachTransferred: waiting for SourceBuffer track info");return}if(this.log(`attachTransferred: (bufferCodecEventsTotal ${this.bufferCodecEventsTotal}) 2468required tracks: ${ez(r,(e,t)=>"initSegment"===e?void 0:t)}; 2469transfer tracks: ${ez(i,(e,t)=>"initSegment"===e?void 0:t)}}`),!B(i,r)){t.mediaSource=null,t.tracks=void 0;let n=e.currentTime,s=this.details,a=Math.max(n,(null==s?void 0:s.fragments[0].start)||0);return a-n>1?void this.log(`attachTransferred: waiting for playback to reach new tracks start time ${n} -> ${a}`):(this.warn(`attachTransferred: resetting MediaSource for incompatible tracks ("${Object.keys(i)}"->"${Object.keys(r)}") start time: ${a} currentTime: ${n}`),this.onMediaDetaching(o.MEDIA_DETACHING,{}),this.onMediaAttaching(o.MEDIA_ATTACHING,t),void(e.currentTime=a))}this.transferData=void 0,n.forEach(e=>{let t=i[e];if(t){let r=t.buffer;if(r){let i=this.fragmentTracker,n=t.id;if(i.hasFragments(n)||i.hasParts(n)){let t=tx.getBuffered(r);i.detectEvictedFragments(e,t,n,null,!0)}let s=i4(e),a=[e,r];this.sourceBuffers[s]=a,r.updating&&this.operationQueue&&this.operationQueue.prependBlocker(e),this.trackSourceBuffer(e,t)}}}),a(),this.bufferCreated()}else this.log("attachTransferred: MediaSource w/o SourceBuffers"),a()}get mediaSourceOpenOrEnded(){var e;let t=null==(e=this.mediaSource)?void 0:e.readyState;return"open"===t||"ended"===t}onMediaDetaching(e,t){let r=!!t.transferMedia;this.transferData=this.overrides=void 0;let{media:i,mediaSource:n,_objectUrl:s}=this;if(n){if(this.log(`media source ${r?"transferring":"detaching"}`),r)this.sourceBuffers.forEach(([e])=>{e&&this.removeBuffer(e)}),this.resetQueue();else{if(this.mediaSourceOpenOrEnded){let e="open"===n.readyState;try{let t=n.sourceBuffers;for(let r=t.length;r--;)e&&t[r].abort(),n.removeSourceBuffer(t[r]);e&&n.endOfStream()}catch(e){this.warn(`onMediaDetaching: ${e.message} while calling endOfStream`)}}this.sourceBufferCount&&this.onBufferReset()}n.removeEventListener("sourceopen",this._onMediaSourceOpen),n.removeEventListener("sourceended",this._onMediaSourceEnded),n.removeEventListener("sourceclose",this._onMediaSourceClose),this.appendSource&&(n.removeEventListener("startstreaming",this._onStartStreaming),n.removeEventListener("endstreaming",this._onEndStreaming)),this.mediaSource=null,this._objectUrl=null}i&&(i.removeEventListener("emptied",this._onMediaEmptied),r||(s&&self.URL.revokeObjectURL(s),this.mediaSrc===s?(i.removeAttribute("src"),this.appendSource&&i3(i),i.load()):this.warn("media|source.src was changed by a third party - skip cleanup")),this.media=null),this.hls.trigger(o.MEDIA_DETACHED,t)}onBufferReset(){this.sourceBuffers.forEach(([e])=>{e&&this.resetBuffer(e)}),this.initTracks()}resetBuffer(e){var t,r;let i=null==(t=this.tracks[e])?void 0:t.buffer;if(this.removeBuffer(e),i)try{null!=(r=this.mediaSource)&&r.sourceBuffers.length&&this.mediaSource.removeSourceBuffer(i)}catch(t){this.warn(`onBufferReset ${e}`,t)}delete this.tracks[e]}removeBuffer(e){this.removeBufferListeners(e),this.sourceBuffers[i4(e)]=[null,null];let t=this.tracks[e];t&&(t.buffer=void 0)}resetQueue(){this.operationQueue&&this.operationQueue.destroy(),this.operationQueue=new iZ(this.tracks)}onBufferCodecs(e,t){var r;let i=this.tracks,n=Object.keys(t);this.log(`BUFFER_CODECS: "${n}" (current SB count ${this.sourceBufferCount})`);let s="audiovideo"in t&&(i.audio||i.video)||i.audiovideo&&("audio"in t||"video"in t),a=!s&&this.sourceBufferCount&&this.media&&n.some(e=>!i[e]);
2469s||a?this.warn(`Unsupported transition between "${Object.keys(i)}" and "${n}" SourceBuffers`):(n.forEach(e=>{var r,n;let{id:s,codec:a,levelCodec:o,container:l,metadata:u,supplemental:c}=t[e],d=i[e],h=null==(r=this.transferData)||null==(r=r.tracks)?void 0:r[e],f=null!=h&&h.buffer?h:d,p=(null==f?void 0:f.pendingCodec)||(null==f?void 0:f.codec),g=null==f?void 0:f.levelCodec;d||(d=i[e]={buffer:void 0,listeners:[],codec:a,supplemental:c,container:l,levelCodec:o,metadata:u,id:s});let m=eD(p,g),y=null==m?void 0:m.replace(i0,"$1"),v=eD(a,o),b=null==(n=v)?void 0:n.replace(i0,"$1");v&&m&&y!==b&&("audio"===e.slice(0,5)&&(v=eC(v,this.appendSource)),this.log(`switching codec ${p} to ${v}`),v!==(d.pendingCodec||d.codec)&&(d.pendingCodec=v),d.container=l,this.appendChangeType(e,l,v))}),(this.tracksReady||this.sourceBufferCount)&&(t.tracks=this.sourceBufferTracks),!this.sourceBufferCount&&(!(this.bufferCodecEventsTotal>1)||this.tracks.video||t.video||(null==(r=t.audio)?void 0:r.id)!=="main"||(this.log("Main audio-only"),this.bufferCodecEventsTotal=1),this.mediaSourceOpenOrEnded&&this.checkPendingTracks()))}get sourceBufferTracks(){return Object.keys(this.tracks).reduce((e,t)=>{let r=this.tracks[t];return e[t]={id:r.id,container:r.container,codec:r.codec,levelCodec:r.levelCodec},e},{})}appendChangeType(e,t,r){let i=`${t};codecs=${r}`,n={label:`change-type=${i}`,execute:()=>{let n=this.tracks[e];if(n){let s=n.buffer;null!=s&&s.changeType&&(this.log(`changing ${e} sourceBuffer type to ${i}`),s.changeType(i),n.codec=r,n.container=t)}this.shiftAndExecuteNext(e)},onStart:()=>{},onComplete:()=>{},onError:t=>{this.warn(`Failed to change ${e} SourceBuffer type`,t)}};this.append(n,e,this.isPending(this.tracks[e]))}blockAudio(e){var t;let r=e.start,i=r+.05*e.duration;if((null==(t=this.fragmentTracker.getAppendedFrag(r,A))?void 0:t.gap)===!0)return;let n={label:"block-audio",execute:()=>{var e;let t=this.tracks.video;(this.lastVideoAppendEnd>i||null!=t&&t.buffer&&tx.isBuffered(t.buffer,i)||(null==(e=this.fragmentTracker.getAppendedFrag(i,A))?void 0:e.gap)===!0)&&(this.blockedAudioAppend=null,this.shiftAndExecuteNext("audio"))},onStart:()=>{},onComplete:()=>{},onError:e=>{this.warn("Error executing block-audio operation",e)}};this.blockedAudioAppend={op:n,frag:e},this.append(n,"audio",!0)}unblockAudio(){let{blockedAudioAppend:e,operationQueue:t}=this;e&&t&&(this.blockedAudioAppend=null,t.unblockAudio(e.op))}onBufferAppending(e,t){let{tracks:i}=this,{data:n,type:l,parent:u,frag:c,part:d,chunkMeta:h,offset:f}=t,p=h.buffering[l],{sn:g,cc:m}=c,y=self.performance.now();p.start=y;let v=c.stats.buffering,b=d?d.stats.buffering:null;0===v.start&&(v.start=y),b&&0===b.start&&(b.start=y);let _=i.audio,E=!1;"audio"===l&&(null==_?void 0:_.container)==="audio/mpeg"&&(E=!this.lastMpegAudioChunk||1===h.id||this.lastMpegAudioChunk.sn!==h.sn,this.lastMpegAudioChunk=h);let S=i.video,x=null==S?void 0:S.buffer;if(x&&"initSegment"!==g){let e=d||c,t=this.blockedAudioAppend;if("audio"!==l||"main"===u||this.blockedAudioAppend||S.ending||S.ended){if("video"===l){let r=e.end;if(t){let e=t.frag.start;(r>e||r<this.lastVideoAppendEnd||tx.isBuffered(x,e))&&this.unblockAudio()}this.lastVideoAppendEnd=r}}else{let t=e.start+.05*e.duration,r=x.buffered,i=this.currentOp("video");(r.length||i)&&(i||tx.isBuffered(x,t)||!(this.lastVideoAppendEnd<t))||this.blockAudio(e)}}let T=(d||c).start,w={label:`append-${l}`,execute:()=>{var e;p.executeStart=self.performance.now();let t=null==(e=this.tracks[l])?void 0:e.buffer;t&&(E?this.updateTimestampOffset(t,T,.1,l,g,m):void 0!==f&&r(f)&&this.updateTimestampOffset(t,f,1e-6,l,g,m)),this.appendExecutor(n,l)},onStart:()=>{},onComplete:()=>{let e=self.performance.now();p.executeEnd=p.end=e,0===v.first&&(v.first=e),b&&0===b.first&&(b.first=e);let t={};this.sourceBuffers.forEach(([e,r])=>{e&&(t[e]=tx.getBuffered(r))}),this.appendErrors[l]=0,"audio"===l||"video"===l?this.appendErrors.audiovideo=0:(this.appendErrors.audio=0,this.appendErrors.video=0),this.hls.trigger(o.BUFFER_APPENDED,{type:l,frag:c,part:d,chunkMeta:h,parent:c.type,timeRanges:t})},onError:e=>{var t;let r={type:s.MEDIA_ERROR,parent:c.type,details:a.BUFFER_APPEND_ERROR,sourceBufferName:l,frag:c,part:d,chunkMeta:h,error:e,err:e,fatal:!1},i=null==(t=this.media)?void 0:t.error;if(e.code===DOMException.QUOTA_EXCEEDED_ERR||"QuotaExceededError"==e.name||"quota"in e)r.details=a.BUFFER_FULL_ERROR;else if(e.code===DOMException.INVALID_STATE_ERR&&this.mediaSourceOpenOrEnded&&!i)r.errorAction=ti(!0);else if(e.name===i1&&0===this.sourceBufferCount)r.errorAction=ti(!0);else{let e=++this.appendErrors[l];this.warn(`Failed ${e}/${this.hls.config.appendErrorMaxRetry} times to append segment in "${l}" sourceBuffer (${i||"no media error"}
2469)`),(e>=this.hls.config.appendErrorMaxRetry||i)&&(r.fatal=!0)}this.hls.trigger(o.ERROR,r)}};this.log(`queuing "${l}" append sn: ${g}${d?" p: "+d.index:""} of ${c.type===A?"level":"track"} ${c.level} cc: ${m}`),this.append(w,l,this.isPending(this.tracks[l]))}getFlushOp(e,t,r){return this.log(`queuing "${e}" remove ${t}-${r}`),{label:"remove",execute:()=>{this.removeExecutor(e,t,r)},onStart:()=>{},onComplete:()=>{this.hls.trigger(o.BUFFER_FLUSHED,{type:e})},onError:i=>{this.warn(`Failed to remove ${t}-${r} from "${e}" SourceBuffer`,i)}}}onBufferFlushing(e,t){let{type:r,startOffset:i,endOffset:n}=t;r?this.append(this.getFlushOp(r,i,n),r):this.sourceBuffers.forEach(([e])=>{e&&this.append(this.getFlushOp(e,i,n),e)})}onFragParsed(e,t){let{frag:r,part:i}=t,n=[],s=i?i.elementaryStreams:r.elementaryStreams;s[Q]?n.push("audiovideo"):(s[W]&&n.push("audio"),s[Y]&&n.push("video"));let a=()=>{let e=self.performance.now();r.stats.buffering.end=e,i&&(i.stats.buffering.end=e);let t=i?i.stats:r.stats;this.hls.trigger(o.FRAG_BUFFERED,{frag:r,part:i,stats:t,id:r.type})};0===n.length&&this.warn(`Fragments must have at least one ElementaryStreamType set. type: ${r.type} level: ${r.level} sn: ${r.sn}`),this.blockBuffers(a,n).catch(e=>{this.warn(`Fragment buffered callback ${e}`),this.stepOperationQueue(this.sourceBufferTypes)})}onFragChanged(e,t){this.trimBuffers()}get bufferedToEnd(){return this.sourceBufferCount>0&&!this.sourceBuffers.some(([e])=>{if(e){let t=this.tracks[e];if(t)return!t.ended||t.ending}return!1})}onBufferEos(e,t){var r;this.sourceBuffers.forEach(([e])=>{if(e){let r=this.tracks[e];(!t.type||t.type===e)&&(r.ending=!0,r.ended||(r.ended=!0,this.log(`${e} buffer reached EOS`)))}});let i=(null==(r=this.overrides)?void 0:r.endOfStream)!==!1;this.sourceBufferCount>0&&!this.sourceBuffers.some(([e])=>{var t;return e&&!(null!=(t=this.tracks[e])&&t.ended)})?i?(this.log("Queueing EOS"),this.blockUntilOpen(()=>{this.tracksEnded();let{mediaSource:e}=this;if(!e||"open"!==e.readyState){e&&this.log(`Could not call mediaSource.endOfStream(). mediaSource.readyState: ${e.readyState}`);return}this.log("Calling mediaSource.endOfStream()"),e.endOfStream(),this.hls.trigger(o.BUFFERED_TO_END,void 0)})):(this.tracksEnded(),this.hls.trigger(o.BUFFERED_TO_END,void 0)):"video"===t.type&&this.unblockAudio()}tracksEnded(){this.sourceBuffers.forEach(([e])=>{if(null!==e){let t=this.tracks[e];t&&(t.ending=!1)}})}onLevelUpdated(e,{details:t}){t.fragments.length&&(this.details=t,this.updateDuration())}updateDuration(){this.blockUntilOpen(()=>{let e=this.getDurationAndRange();e&&this.updateMediaSource(e)})}onError(e,t){if(t.details===a.BUFFER_APPEND_ERROR&&t.frag){var i;let e=null==(i=t.errorAction)?void 0:i.nextAutoLevel;r(e)&&e!==t.frag.level&&this.resetAppendErrors()}}resetAppendErrors(){this.appendErrors={audio:0,video:0,audiovideo:0}}trimBuffers(){let{hls:e,details:t,media:i}=this;if(!i||null===t||!this.sourceBufferCount)return;let n=e.config,s=i.currentTime,a=t.levelTargetDuration,o=t.live&&null!==n.liveBackBufferLength?n.liveBackBufferLength:n.backBufferLength;if(r(o)&&o>=0){let e=Math.max(o,a),t=Math.floor(s/a)*a-e;this.flushBackBuffer(s,a,t)}let l=n.frontBufferFlushThreshold;if(r(l)&&l>0){let e=Math.max(Math.max(n.maxBufferLength,l),a),t=Math.floor(s/a)*a+e;this.flushFrontBuffer(s,a,t)}}flushBackBuffer(e,t,r){this.sourceBuffers.forEach(([e,t])=>{if(t){let n=tx.getBuffered(t);if(n.length>0&&r>n.start(0)){var i;this.hls.trigger(o.BACK_BUFFER_REACHED,{bufferEnd:r});let t=this.tracks[e];if(null!=(i=this.details)&&i.live)this.hls.trigger(o.LIVE_BACK_BUFFER_REACHED,{bufferEnd:r});else if(null!=t&&t.ended)return void this.log(`Cannot flush ${e} back buffer while SourceBuffer is in ended state`);this.hls.trigger(o.BUFFER_FLUSHING,{startOffset:0,endOffset:r,type:e})}}})}flushFrontBuffer(e,t,r){this.sourceBuffers.forEach(([t,i])=>{if(i){let n=tx.getBuffered(i),s=n.length;if(s<2)return;let a=n.start(s-1),l=n.end(s-1);r>a||e>=a&&e<=l||this.hls.trigger(o.BUFFER_FLUSHING,{startOffset:a,endOffset:1/0,type:t})}})}getDurationAndRange(){var e;let{details:t,mediaSource:i}=this;if(!t||!this.media||(null==i?void 0:i.readyState)!=="open")return null;let n=t.edge;
2469if(t.live&&this.hls.config.liveDurationInfinity){if(t.fragments.length&&i.setLiveSeekableRange){let e=Math.max(0,t.fragmentStart),r=Math.max(e,n);return{duration:1/0,start:e,end:r}}return{duration:1/0}}let s=null==(e=this.overrides)?void 0:e.duration;if(s)return r(s)?{duration:s}:null;let a=this.media.duration;return n>(r(i.duration)?i.duration:0)&&n>a||!r(a)?{duration:n}:null}updateMediaSource({duration:e,start:t,end:i}){let n=this.mediaSource;this.media&&n&&"open"===n.readyState&&(n.duration!==e&&(r(e)&&this.log(`Updating MediaSource duration to ${e.toFixed(3)}`),n.duration=e),void 0!==t&&void 0!==i&&(this.log(`MediaSource duration is set to ${n.duration}. Setting seekable range to ${t}-${i}.`),n.setLiveSeekableRange(t,i)))}get tracksReady(){let e=this.pendingTrackCount;return e>0&&(e>=this.bufferCodecEventsTotal||this.isPending(this.tracks.audiovideo))}checkPendingTracks(){let{bufferCodecEventsTotal:e,pendingTrackCount:t,tracks:r}=this;if(this.log(`checkPendingTracks (pending: ${t} codec events expected: ${e}) ${ez(r)}`),this.tracksReady){var i;let e=null==(i=this.transferData)?void 0:i.tracks;e&&Object.keys(e).length?this.attachTransferred():this.createSourceBuffers()}}bufferCreated(){if(this.sourceBufferCount){let e={};this.sourceBuffers.forEach(([t,r])=>{if(t){let i=this.tracks[t];e[t]={buffer:r,container:i.container,codec:i.codec,supplemental:i.supplemental,levelCodec:i.levelCodec,id:i.id,metadata:i.metadata}}}),this.hls.trigger(o.BUFFER_CREATED,{tracks:e}),this.log(`SourceBuffers created. Running queue: ${this.operationQueue}`),this.sourceBuffers.forEach(([e])=>{this.executeNext(e)})}else{let e=Error("could not create source buffer for media codec(s)");this.hls.trigger(o.ERROR,{type:s.MEDIA_ERROR,details:a.BUFFER_INCOMPATIBLE_CODECS_ERROR,fatal:!0,error:e,reason:e.message})}}createSourceBuffers(){let{tracks:e,sourceBuffers:t,mediaSource:r}=this;if(!r)throw Error("createSourceBuffers called when mediaSource was null");for(let n in e){let l=e[n];if(this.isPending(l)){let e=this.getTrackCodec(l,n),u=`${l.container};codecs=${e}`;l.codec=e,this.log(`creating sourceBuffer(${u})${this.currentOp(n)?" Queued":""} ${ez(l)}`);try{let e=r.addSourceBuffer(u),i=i4(n),s=[n,e];t[i]=s,l.buffer=e}catch(e){var i;this.error(`error while trying to add sourceBuffer: ${e.message}`),this.shiftAndExecuteNext(n),null==(i=this.operationQueue)||i.removeBlockers(),delete this.tracks[n],this.hls.trigger(o.ERROR,{type:s.MEDIA_ERROR,details:a.BUFFER_ADD_CODEC_ERROR,fatal:!1,error:e,sourceBufferName:n,mimeType:u,parent:l.id});return}this.trackSourceBuffer(n,l)}}this.bufferCreated()}getTrackCodec(e,t){let r=e.supplemental,i=e.codec;r&&("video"===t||"audiovideo"===t)&&ex(r,"video")&&(i=function(e,t){let r=[];if(e){let t=e.split(",");for(let e=0;e<t.length;e++)eS(t[e],"video")||r.push(t[e])}return t&&r.push(t),r.join(",")}(i,r));let n=eD(i,e.levelCodec);return n?"audio"===t.slice(0,5)?eC(n,this.appendSource):n:""}trackSourceBuffer(e,t){let r=t.buffer;if(!r)return;let i=this.getTrackCodec(t,e);this.tracks[e]={buffer:r,codec:i,container:t.container,levelCodec:t.levelCodec,supplemental:t.supplemental,metadata:t.metadata,id:t.id,listeners:[]},this.removeBufferListeners(e),this.addBufferListener(e,"updatestart",this.onSBUpdateStart),this.addBufferListener(e,"updateend",this.onSBUpdateEnd),this.addBufferListener(e,"error",this.onSBUpdateError),this.appendSource&&this.addBufferListener(e,"bufferedchange",(e,t)=>{let r=t.removedRanges;null!=r&&r.length&&this.hls.trigger(o.BUFFER_FLUSHED,{type:e})})}get mediaSrc(){var e,t;let r=(null==(e=this.media)||null==(t=e.querySelector)?void 0:t.call(e,"source"))||this.media;return null==r?void 0:r.src}onSBUpdateStart(e){let t=this.currentOp(e);t&&t.onStart()}onSBUpdateEnd(e){var t;if((null==(t=this.mediaSource)?void 0:t.readyState)==="closed")return void this.resetBuffer(e);let r=this.currentOp(e);r&&(r.onComplete(),this.shiftAndExecuteNext(e))}onSBUpdateError(e,t){var r;let i=Error(`${e} SourceBuffer error. MediaSource readyState: ${null==(r=this.mediaSource)?void 0:r.readyState}`);this.error(`${i}`,t),this.hls.trigger(o.ERROR,{type:s.MEDIA_ERROR,details:a.BUFFER_APPENDING_ERROR,sourceBufferName:e,error:i,fatal:!1});let n=this.currentOp(e);n&&n.onError(i)}updateTimestampOffset(e,t,r,i,n,s){Math.abs(t-e.timestampOffset)>=r&&(this.log(`Updating ${i} SourceBuffer timestampOffset to ${t} (sn: ${n} cc: ${s})`),e.timestampOffset=t)}removeExecutor(e,t,i){let{media:n,mediaSource:s}=this,a=this.tracks[e],o=null==a?void 0:a.buffer;if(!n||!s||!o){this.warn(`Attempting to remove from the ${e} SourceBuffer, but it does not exist`),this.shiftAndExecuteNext(e);return}let l=r(n.duration)?n.duration:1/0,u=r(s.duration)?s.duration:1/0,c=Math.max(0,t),d=Math.min(i,l,u);d>c&&(!a.ending||a.ended)?(a.ended=!1,this.log(`Removing [${c},${d}] from the ${e} SourceBuffer`),o.remove(c,d)):this.shiftAndExecuteNext(e)}appendExecutor(e,t){let r=this.tracks[t],i=null==r?void 0:r.buffer;if(!i)throw new i2(`Attempting to append to the ${t} SourceBuffer, but it does not exist`);r.ending=!1,r.ended=!1,i.appendBuffer(e)}blockUntilOpen(e){if(this.isUpdating()||this.isQueued())this.blockBuffers(e).catch(e=>{this.warn(`SourceBuffer blocked callback ${e}
2469`),this.stepOperationQueue(this.sourceBufferTypes)});else try{e()}catch(e){this.warn(`Callback run without blocking ${this.operationQueue} ${e}`)}}isUpdating(){return this.sourceBuffers.some(([e,t])=>e&&t.updating)}isQueued(){return this.sourceBuffers.some(([e])=>e&&!!this.currentOp(e))}isPending(e){return!!e&&!e.buffer}blockBuffers(e,t=this.sourceBufferTypes){if(!t.length)return this.log("Blocking operation requested, but no SourceBuffers exist"),Promise.resolve().then(e);let{operationQueue:r}=this,i=t.map(e=>this.appendBlocker(e));return t.length>1&&this.blockedAudioAppend&&this.unblockAudio(),Promise.all(i).then(t=>{r===this.operationQueue&&(e(),this.stepOperationQueue(this.sourceBufferTypes))})}stepOperationQueue(e){e.forEach(e=>{var t;let r=null==(t=this.tracks[e])?void 0:t.buffer;r&&!r.updating&&this.shiftAndExecuteNext(e)})}append(e,t,r){this.operationQueue&&this.operationQueue.append(e,t,r)}appendBlocker(e){if(this.operationQueue)return this.operationQueue.appendBlocker(e)}currentOp(e){return this.operationQueue?this.operationQueue.current(e):null}executeNext(e){e&&this.operationQueue&&this.operationQueue.executeNext(e)}shiftAndExecuteNext(e){this.operationQueue&&this.operationQueue.shiftAndExecuteNext(e)}get pendingTrackCount(){return Object.keys(this.tracks).reduce((e,t)=>e+ +!!this.isPending(this.tracks[t]),0)}get sourceBufferCount(){return this.sourceBuffers.reduce((e,[t])=>e+ +!!t,0)}get sourceBufferTypes(){return this.sourceBuffers.map(([e])=>e).filter(e=>!!e)}addBufferListener(e,t,r){let i=this.tracks[e];if(!i)return;let n=i.buffer;if(!n)return;let s=r.bind(this,e);i.listeners.push({event:t,listener:s}),n.addEventListener(t,s)}removeBufferListeners(e){let t=this.tracks[e];if(!t)return;let r=t.buffer;r&&(t.listeners.forEach(e=>{r.removeEventListener(e.event,e.listener)}),t.listeners.length=0)}},capLevelController:i5,errorController:class extends P{constructor(e){super("error-controller",e.logger),this.hls=void 0,this.playlistError=0,this.hls=e,this.registerListeners()}registerListeners(){let e=this.hls;e.on(o.ERROR,this.onError,this),e.on(o.MANIFEST_LOADING,this.onManifestLoading,this),e.on(o.LEVEL_UPDATED,this.onLevelUpdated,this)}unregisterListeners(){let e=this.hls;e&&(e.off(o.ERROR,this.onError,this),e.off(o.ERROR,this.onErrorOut,this),e.off(o.MANIFEST_LOADING,this.onManifestLoading,this),e.off(o.LEVEL_UPDATED,this.onLevelUpdated,this))}destroy(){this.unregisterListeners(),this.hls=null}startLoad(e){}stopLoad(){this.playlistError=0}getVariantLevelIndex(e){return(null==e?void 0:e.type)===A?e.level:this.getVariantIndex()}getVariantIndex(){var e;let t=this.hls,r=t.currentLevel;return null!=(e=t.loadLevelObj)&&e.details||-1===r?t.loadLevel:r}variantHasKey(e,t){if(e){var r;if(null!=(r=e.details)&&r.hasKey(t))return!0;let i=e.audioGroups;if(i)return this.hls.allAudioTracks.filter(e=>i.indexOf(e.groupId)>=0).some(e=>{var r;return null==(r=e.details)?void 0:r.hasKey(t)})}return!1}onManifestLoading(){this.playlistError=0}onLevelUpdated(){this.playlistError=0}onError(e,t){var r,i,n;if(t.fatal)return;let o=this.hls,l=t.context;switch(t.details){case a.FRAG_LOAD_ERROR:case a.FRAG_LOAD_TIMEOUT:case a.KEY_LOAD_ERROR:case a.KEY_LOAD_TIMEOUT:t.errorAction=this.getFragRetryOrSwitchAction(t);return;case a.FRAG_PARSING_ERROR:if(null!=(r=t.frag)&&r.gap){t.errorAction=ti();return}case a.FRAG_GAP:case a.FRAG_DECRYPT_ERROR:t.errorAction=this.getFragRetryOrSwitchAction(t),t.errorAction.action=2;return;case a.LEVEL_EMPTY_ERROR:case a.LEVEL_PARSING_ERROR:{let e=t.parent===A?t.level:o.loadLevel;t.details===a.LEVEL_EMPTY_ERROR&&null!=(i=t.context)&&null!=(i=i.levelDetails)&&i.live?t.errorAction=this.getPlaylistRetryOrSwitchAction(t,e):(t.levelRetry=!1,t.errorAction=this.getLevelSwitchAction(t,e))}return;case a.LEVEL_LOAD_ERROR:case a.LEVEL_LOAD_TIMEOUT:"number"==typeof(null==l?void 0:l.level)&&(t.errorAction=this.getPlaylistRetryOrSwitchAction(t,l.level));return;case a.AUDIO_TRACK_LOAD_ERROR:case a.AUDIO_TRACK_LOAD_TIMEOUT:case a.SUBTITLE_LOAD_ERROR:case a.SUBTITLE_TRACK_LOAD_TIMEOUT:if(l){let e=o.loadLevelObj;e&&(l.type===T&&e.hasAudioGroup(l.groupId)||l.type===w&&e.hasSubtitleGroup(l.groupId))&&(t.errorAction=this.getPlaylistRetryOrSwitchAction(t,o.loadLevel),t.errorAction.action=2,t.errorAction.flags=1)}return;case a.KEY_SYSTEM_STATUS_OUTPUT_RESTRICTED:t.errorAction={action:2,flags:2};return;case a.KEY_SYSTEM_SESSION_UPDATE_FAILED:case a.KEY_SYSTEM_STATUS_INTERNAL_ERROR:case a.KEY_SYSTEM_NO_SESSION:t.errorAction={action:2,flags:4};return;
2469case a.BUFFER_ADD_CODEC_ERROR:case a.REMUX_ALLOC_ERROR:case a.BUFFER_APPEND_ERROR:t.errorAction||(t.errorAction=this.getLevelSwitchAction(t,null!=(n=t.level)?n:o.loadLevel));return;case a.INTERNAL_EXCEPTION:case a.BUFFER_APPENDING_ERROR:case a.BUFFER_FULL_ERROR:case a.LEVEL_SWITCH_ERROR:case a.BUFFER_STALLED_ERROR:case a.BUFFER_SEEK_OVER_HOLE:case a.BUFFER_NUDGE_ON_STALL:t.errorAction=ti();return}t.type===s.KEY_SYSTEM_ERROR&&(t.levelRetry=!1,t.errorAction=ti())}getPlaylistRetryOrSwitchAction(e,t){let r=e7(this.hls.config.playlistLoadPolicy,e),i=this.playlistError++;if(tt(r,i,e5(e),e.response))return{action:5,flags:0,retryConfig:r,retryCount:i};let n=this.getLevelSwitchAction(e,t);return r&&(n.retryConfig=r,n.retryCount=i),n}getFragRetryOrSwitchAction(e){let t=this.hls,r=this.getVariantLevelIndex(e.frag),i=t.levels[r],{fragLoadPolicy:n,keyLoadPolicy:s}=t.config,o=e7(e8(e)?s:n,e),l=t.levels.reduce((e,t)=>e+t.fragmentError,0);if(i&&(e.details!==a.FRAG_GAP&&i.fragmentError++,!e6(e))&&tt(o,l,e5(e),e.response))return{action:5,flags:0,retryConfig:o,retryCount:l};let u=this.getLevelSwitchAction(e,r);return o&&(u.retryConfig=o,u.retryCount=l),u}getLevelSwitchAction(e,t){let r=this.hls;null==t&&(t=r.loadLevel);let i=this.hls.levels[t];if(i){var n,s,o,l;let t=e.details;i.loadError++,t===a.BUFFER_APPEND_ERROR&&i.fragmentError++;let u=-1,{levels:c,loadLevel:d,minAutoLevel:h,maxAutoLevel:f}=r;r.autoLevelEnabled||r.config.preserveManualLevelOnError||(r.loadLevel=-1);let p=null==(n=e.frag)?void 0:n.type,g=(p===R&&t===a.FRAG_PARSING_ERROR||"audio"===e.sourceBufferName&&(t===a.BUFFER_ADD_CODEC_ERROR||t===a.BUFFER_APPEND_ERROR))&&c.some(({audioCodec:e})=>i.audioCodec!==e),m="video"===e.sourceBufferName&&(t===a.BUFFER_ADD_CODEC_ERROR||t===a.BUFFER_APPEND_ERROR)&&c.some(({codecSet:e,audioCodec:t})=>i.codecSet!==e&&i.audioCodec===t),{type:y,groupId:v}=null!=(s=e.context)?s:{};for(let r=c.length;r--;){let n=(r+d)%c.length;if(n!==d&&n>=h&&n<=f&&0===c[n].loadError){let r=c[n];if(t===a.FRAG_GAP&&p===A&&e.frag){let t=c[n].details;if(t){let r=e2(e.frag,t.fragments,e.frag.start);if(null!=r&&r.gap)continue}}else if(y===T&&r.hasAudioGroup(v)||y===w&&r.hasSubtitleGroup(v))continue;else if(p===R&&null!=(o=i.audioGroups)&&o.some(e=>r.hasAudioGroup(e))||p===I&&null!=(l=i.subtitleGroups)&&l.some(e=>r.hasSubtitleGroup(e))||g&&i.audioCodec===r.audioCodec||m&&i.codecSet===r.codecSet||!g&&i.codecSet!==r.codecSet)continue;u=n;break}}if(u>-1&&r.loadLevel!==u)return e.levelRetry=!0,this.playlistError=0,{action:2,flags:0,nextAutoLevel:u}}return{action:2,flags:1}}onErrorOut(e,t){var r;switch(null==(r=t.errorAction)?void 0:r.action){case 0:break;case 2:this.sendAlternateToPenaltyBox(t),t.errorAction.resolved||t.details===a.FRAG_GAP?/MediaSource readyState: ended/.test(t.error.message)&&(this.warn(`MediaSource ended after "${t.sourceBufferName}" sourceBuffer append error. Attempting to recover from media error.`),this.hls.recoverMediaError()):t.fatal=!0}if(t.fatal)return void this.hls.stopLoad()}sendAlternateToPenaltyBox(e){let t=this.hls,r=e.errorAction;if(!r)return;let{flags:i}=r,n=r.nextAutoLevel;switch(i){case 0:this.switchLevel(e,n);break;case 2:{let i=this.getVariantLevelIndex(e.frag),n=t.levels[i],s=null==n?void 0:n.attrs["HDCP-LEVEL"];if(r.hdcpLevel=s,"NONE"===s)this.warn("HDCP policy resticted output with HDCP-LEVEL=NONE");else if(s){t.maxHdcpLevel=eU[eU.indexOf(s)-1],r.resolved=!0,this.warn(`Restricting playback to HDCP-LEVEL of "${t.maxHdcpLevel}" or lower`);break}}case 4:{let t=e.decryptdata;if(t){let i=this.hls.levels,n=i.length;for(let r=n;r--;)if(this.variantHasKey(i[r],t)){var s,a;this.log(`Banned key found in level ${r} (${i[r].bitrate}bps) or audio group "${null==(s=i[r].audioGroups)?void 0:s.join(",")}" (${null==(a=e.frag)?void 0:a.type} fragment) ${G(t.keyId||[])}`),i[r].fragmentError++,i[r].loadError++,this.log(`Removing level ${r} with key error (${e.error})`),this.hls.removeLevel(r)}let o=e.frag;if(this.hls.levels.length<n)r.resolved=!0;else if(o&&o.type!==A){let e=o.decryptdata;e&&!t.matches(e)&&(r.resolved=!0)}}}}r.resolved||this.switchLevel(e,n)}switchLevel(e,t){if(void 0!==t&&e.errorAction&&(this.warn(`switching to level ${t} after ${e.details}`),this.hls.nextAutoLevel=t,e.errorAction.resolved=!0,this.hls.nextLoadLevel=this.hls.nextAutoLevel,e.details===a.BUFFER_ADD_CODEC_ERROR&&e.mimeType&&"audiovideo"!==e.sourceBufferName)){let t=eP(e.mimeType),r=this.hls.levels;for(let i=r.length;i--;)r[i][`${e.sourceBufferName}Codec`]===t&&(this.log(`Removing level ${i} for ${e.details} ("${t}" not supported)`),this.hls.removeLevel(i))}}},fpsController:class{constructor(e){this.hls=void 0,this.isVideoPlaybackQualityAvailable=!1,this.timer=void 0,this.media=null,this.lastTime=void 0,this.lastDroppedFrames=0,this.lastDecodedFrames=0,this.streamController=void 0,this.hls=e,this.registerListeners()}setStreamController(e){this.streamController=e}
vendor: 5,025 bytes, line 2469
2469registerListeners(){this.hls.on(o.MEDIA_ATTACHING,this.onMediaAttaching,this),this.hls.on(o.MEDIA_DETACHING,this.onMediaDetaching,this)}unregisterListeners(){this.hls.off(o.MEDIA_ATTACHING,this.onMediaAttaching,this),this.hls.off(o.MEDIA_DETACHING,this.onMediaDetaching,this)}destroy(){this.timer&&clearInterval(this.timer),this.unregisterListeners(),this.isVideoPlaybackQualityAvailable=!1,this.media=null}onMediaAttaching(e,t){let r=this.hls.config;if(r.capLevelOnFPSDrop){let e=t.media instanceof self.HTMLVideoElement?t.media:null;this.media=e,e&&"function"==typeof e.getVideoPlaybackQuality&&(this.isVideoPlaybackQualityAvailable=!0),self.clearInterval(this.timer),this.timer=self.setInterval(this.checkFPSInterval.bind(this),r.fpsDroppedMonitoringPeriod)}}onMediaDetaching(){this.media=null}checkFPS(e,t,r){let i=performance.now();if(t){if(this.lastTime){let e=i-this.lastTime,n=r-this.lastDroppedFrames,s=t-this.lastDecodedFrames,a=1e3*n/e,l=this.hls;if(l.trigger(o.FPS_DROP,{currentDropped:n,currentDecoded:s,totalDroppedFrames:r}),a>0&&n>l.config.fpsDroppedMonitoringThreshold*s){let e=l.currentLevel;l.logger.warn("drop FPS ratio greater than max allowed value for currentLevel: "+e),e>0&&(-1===l.autoLevelCapping||l.autoLevelCapping>=e)&&(e-=1,l.trigger(o.FPS_DROP_LEVEL_CAPPING,{level:e,droppedLevel:l.currentLevel}),l.autoLevelCapping=e,this.streamController.nextLevelSwitch())}}this.lastTime=i,this.lastDroppedFrames=r,this.lastDecodedFrames=t}}checkFPSInterval(){let e=this.media;if(e)if(this.isVideoPlaybackQualityAvailable){let t=e.getVideoPlaybackQuality();this.checkFPS(e,t.totalVideoFrames,t.droppedVideoFrames)}else this.checkFPS(e,e.webkitDecodedFrameCount,e.webkitDroppedFrameCount)}},stretchShortVideoTrack:!1,maxAudioFramesDrift:1,forceKeyFrameOnDiscontinuity:!0,abrEwmaFastLive:3,abrEwmaSlowLive:9,abrEwmaFastVoD:3,abrEwmaSlowVoD:9,abrEwmaDefaultEstimate:5e5,abrEwmaDefaultEstimateMax:5e6,abrBandWidthFactor:.95,abrBandWidthUpFactor:.7,abrMaxWithRealBitrate:!1,maxStarvationDelay:4,maxLoadingDelay:4,minAutoBitrate:0,emeEnabled:!1,widevineLicenseUrl:void 0,drmSystems:{},drmSystemOptions:{},requestMediaKeySystemAccessFunc:tJ,requireKeySystemAccessOnStart:!1,testBandwidth:!0,progressive:!1,lowLatencyMode:!0,cmcd:void 0,enableDateRangeMetadataCues:!0,enableEmsgMetadataCues:!0,enableEmsgKLVMetadata:!1,enableID3MetadataCues:!0,enableInterstitialPlayback:!0,interstitialAppendInPlace:!0,interstitialLiveLookAhead:10,useMediaCapabilities:!0,preserveManualLevelOnError:!1,certLoadPolicy:{default:{maxTimeToFirstByteMs:8e3,maxLoadTimeMs:2e4,timeoutRetry:null,errorRetry:null}},keyLoadPolicy:{default:{maxTimeToFirstByteMs:8e3,maxLoadTimeMs:2e4,timeoutRetry:{maxNumRetry:1,retryDelayMs:1e3,maxRetryDelayMs:2e4,backoff:"linear"},errorRetry:{maxNumRetry:8,retryDelayMs:1e3,maxRetryDelayMs:2e4,backoff:"linear"}}},manifestLoadPolicy:{default:{maxTimeToFirstByteMs:1/0,maxLoadTimeMs:2e4,timeoutRetry:{maxNumRetry:2,retryDelayMs:0,maxRetryDelayMs:0},errorRetry:{maxNumRetry:1,retryDelayMs:1e3,maxRetryDelayMs:8e3}}},playlistLoadPolicy:{default:{maxTimeToFirstByteMs:1e4,maxLoadTimeMs:2e4,timeoutRetry:{maxNumRetry:2,retryDelayMs:0,maxRetryDelayMs:0},errorRetry:{maxNumRetry:2,retryDelayMs:1e3,maxRetryDelayMs:8e3}}},fragLoadPolicy:{default:{maxTimeToFirstByteMs:1e4,maxLoadTimeMs:12e4,timeoutRetry:{maxNumRetry:4,retryDelayMs:0,maxRetryDelayMs:0},errorRetry:{maxNumRetry:6,retryDelayMs:1e3,maxRetryDelayMs:8e3}}},steeringManifestLoadPolicy:{default:{maxTimeToFirstByteMs:1e4,maxLoadTimeMs:2e4,timeoutRetry:{maxNumRetry:2,retryDelayMs:0,maxRetryDelayMs:0},errorRetry:{maxNumRetry:1,retryDelayMs:1e3,maxRetryDelayMs:8e3}}},interstitialAssetListLoadPolicy:{default:{maxTimeToFirstByteMs:1e4,maxLoadTimeMs:3e4,timeoutRetry:{maxNumRetry:0,retryDelayMs:0,maxRetryDelayMs:0},errorRetry:{maxNumRetry:0,retryDelayMs:1e3,maxRetryDelayMs:8e3}}},manifestLoadingTimeOut:1e4,manifestLoadingMaxRetry:1,manifestLoadingRetryDelay:1e3,manifestLoadingMaxRetryTimeout:64e3,levelLoadingTimeOut:1e4,levelLoadingMaxRetry:4,levelLoadingRetryDelay:1e3,levelLoadingMaxRetryTimeout:64e3,fragLoadingTimeOut:2e4,fragLoadingMaxRetry:6,fragLoadingRetryDelay:1e3,fragLoadingMaxRetryTimeout:64e3},{cueHandler:sN,enableWebVTT:!0,enableIMSC1:!0,enableCEA708Captions:!0,captionsTextTrack1Label:"English",captionsTextTrack1LanguageCode:"en",captionsTextTrack2Label:"Spanish",captionsTextTrack2LanguageCode:"es",captionsTextTrack3Label:"Unknown CC",captionsTextTrack3LanguageCode:"",captionsTextTrack4Label:"Unknown CC",captionsTextTrack4LanguageCode:"",renderTextTracksNatively:!0}),{},{subtitleStreamController:class extends rU{constructor(e,t,r){super(e,t,r,"subtitle-stream-controller",I),this.currentTrackId=-1,this.tracksBuffered=[],this.mainDetails=null,this.registerListeners()}onHandlerDestroying(){this.unregisterListeners(),super.onHandlerDestroying(),this.mainDetails=null}registerListeners(){super.registerListeners();let{hls:e}=this;e.on(o.LEVEL_LOADED,this.onLevelLoaded,this),e.on(o.SUBTITLE_TRACKS_UPDATED,this.onSubtitleTracksUp
2469dated,this),e.on(o.SUBTITLE_TRACK_SWITCH,this.onSubtitleTrackSwitch,this),e.on(o.SUBTITLE_TRACK_LOADED,this.onSubtitleTrackLoaded,this),e.on(o.SUBTITLE_FRAG_PROCESSED,this.onSubtitleFragProcessed,this),e.on(o.BUFFER_FLUSHING,this.onBufferFlushing,this)}unregisterListeners(){super.unregisterListeners();let{hls:e}=this;e.off(o.LEVEL_LOADED,this.onLevelLoaded,this),e.off(o.SUBTITLE_TRACKS_UPDATED,this.onSubtitleTracksUpdated,this),e.off(o.SUBTITLE_TRACK_SWITCH,this.onSubtitleTrackSwitch,this),e.off(o.SUBTITLE_TRACK_LOADED,this.onSubtitleTrackLoaded,this),e.off(o.SUBTITLE_FRAG_PROCESSED,this.onSubtitleFragProcessed,this),e.off(o.BUFFER_FLUSHING,this.onBufferFlushing,this)}startLoad(e,t){this.stopLoad(),this.state=rk,this.setInterval(500),this.nextLoadPosition=this.lastCurrentTime=e+this.timelineOffset,this.startPosition=t?-1:e,this.tick()}onManifestLoading(){super.onManifestLoading(),this.mainDetails=null}onMediaDetaching(e,t){this.tracksBuffered=[],super.onMediaDetaching(e,t)}onLevelLoaded(e,t){this.mainDetails=t.details}onSubtitleFragProcessed(e,t){let r,{frag:i,success:n}=t;if(this.fragContextChanged(i)||(J(i)&&(this.fragPrevious=i),this.state=rk),!n)return;let s=this.tracksBuffered[this.currentTrackId];if(!s)return;let a=i.start;for(let e=0;e<s.length;e++)if(a>=s[e].start&&a<=s[e].end){r=s[e];break}let o=i.start+i.duration;r?r.end=o:(r={start:a,end:o},s.push(r)),this.fragmentTracker.fragBuffered(i),this.fragBufferedComplete(i,null),this.media&&this.tick()}onBufferFlushing(e,t){let{startOffset:r,endOffset:i}=t;if(0===r&&i!==1/0){let e=i-1;if(e<=0)return;t.endOffsetSubtitles=Math.max(0,e),this.tracksBuffered.forEach(t=>{for(let r=0;r<t.length;){if(t[r].end<=e){t.shift();continue}if(t[r].start<e)t[r].start=e;else break;r++}}),this.fragmentTracker.removeFragmentsInRange(r,e,I)}}onError(e,t){let r=t.frag;(null==r?void 0:r.type)===I&&(t.details===a.FRAG_GAP&&this.fragmentTracker.fragBuffered(r,!0),this.fragCurrent&&this.fragCurrent.abortRequests(),this.state!==rI&&(this.state=rk))}onSubtitleTracksUpdated(e,{subtitleTracks:t}){if(this.levels&&iQ(this.levels,t)){this.levels=t.map(e=>new eq(e));return}this.tracksBuffered=[],this.levels=t.map(e=>{let t=new eq(e);return this.tracksBuffered[t.id]=[],t}),this.fragmentTracker.removeFragmentsInRange(0,1/0,I),this.fragPrevious=null,this.mediaBuffer=null}onSubtitleTrackSwitch(e,t){var r;if(this.currentTrackId=t.id,!(null!=(r=this.levels)&&r.length)||-1===this.currentTrackId)return void this.clearInterval();let i=this.levels[this.currentTrackId];null!=i&&i.details?this.mediaBuffer=this.mediaBufferTimeRanges:this.mediaBuffer=null,i&&this.state!==rI&&this.setInterval(500)}onSubtitleTrackLoaded(e,t){var r,i;let{currentTrackId:n,levels:s}=this,{details:a,id:l}=t;if(!s)return void this.warn(`Subtitle tracks were reset while loading level ${l}`);let u=s[l];if(l>=s.length||!u)return;this.log(`Subtitle track ${l} loaded [${a.startSN},${a.endSN}]${a.lastPartSn?`[part-${a.lastPartSn}-${a.lastPartIndex}]`:""},duration:${a.totalduration}`),this.mediaBuffer=this.mediaBufferTimeRanges;let c=0;if(a.live||null!=(r=u.details)&&r.live){if(a.deltaUpdateFailed)return;let e=this.mainDetails;if(!e){this.startFragRequested=!1;return}let t=e.fragments[0];u.details?0===(c=this.alignPlaylists(a,u.details,null==(i=this.levelLastLoaded)?void 0:i.details))&&t&&rf(a,c=t.start):a.hasProgramDateTime&&e.hasProgramDateTime?(rT(a,e),c=a.fragmentStart):t&&rf(a,c=t.start),e&&!this.startFragRequested&&this.setStartPosition(e,c)}u.details=a,this.levelLastLoaded=u,l===n&&(this.hls.trigger(o.SUBTITLE_TRACK_UPDATED,{details:a,id:l,groupId:t.groupId}),this.tick(),a.live&&!this.fragCurrent&&this.media&&this.state===rk&&(e2(null,a.fragments,this.media.currentTime,0)||(this.warn("Subtitle playlist not aligned with playback"),u.details=void 0)))}_handleFragmentLoadComplete(e){let{frag:t,payload:r}=e,i=t.decryptdata,n=this.hls;if(!this.fragContextChanged(t)&&r&&r.byteLength>0&&null!=i&&i.key&&i.iv&&tP(i.method)){let e=performance.now();this.decrypter.decrypt(new Uint8Array(r),i.key.buffer,i.iv.buffer,tF(i.method)).catch(e=>{throw n.trigger(o.ERROR,{type:s.MEDIA_ERROR,details:a.FRAG_DECRYPT_ERROR,fatal:!1,error:e,reason:e.message,frag:t}),e}).then(r=>{let i=performance.now();n.trigger(o.FRAG_DECRYPTED,{frag:t,payload:r,stats:{tstart:e,tdecrypt:i}})}).catch(e=>{this.warn(`${e.name}: ${e.message}`),this.state=rk})}}doTick(){if(!this.media){this.state=rk;return}if(this.state===rk){let{currentTrackId:e,levels:t}=this,r=null==t?void 0:t[e];if(!r||!t.length||!r.details||this.waitForLive(r))return;let{config:i}=this,n=this.getLoadPosition(),{end:s,len:a}=tx.bufferedInfo(this.tracksBuffered[this.currentTrackId]||[],n,i.maxBufferHole),o=r.details;if(a>this.hls.maxBufferLength+o.levelTargetDuration)return;let l=o.fragments,u=l.length,c=o.edge,d=null,h=this.fragPrevious;if(s<c){let e=i.maxFragLookUpTolerance;(d=e2(h,l,Math.max(l[0].start,s),s>c-e?0:e))||!h||!(h.start<l[0].start)||(d=l[0])}else d=l[u-1];if(!(d=this.filterReplacedPrimary(d,r.details)))return;let f=l[d.sn-o.startSN-1];if(f&&f.cc===d.cc&&this.fragmentTracker.getState(f)===tn&&(d=f),this.fragmentTracker.getState(d)===tn){let e=this.mapToInitFragWhenRequired(d);e&&this.loadFragment(e,r,s)}}}loadFragment(e,t,r){J(e)?super.loadFragment(e,t,r):this._loadInitSegment(e,t)}get mediaBufferTimeRanges(){return new n1(this.tracksBuffered[this.currentTrackId]||[])}},subtitleTrackController:class extends iY{constructor(e){super(e,"subtitle-track-controller"),this.media=null,this.tracks=[],this.groupIds=null,this.tracksInGroup=[],this.trackId=-1,this.currentTrack=null,this.selectDefaultTrack=!0,this.queuedDefaultTrack=-1,this.useTextTrackPolling=!1,this.subtitlePollingInterval=-1,this._subtitleDisplay=!0,this.asyncPollTrackChange=()=>this.pollTrackChange(0),this.onTextTracksChanged=()=>
vendor: 2,435 bytes, line 2469
2469{if(this.useTextTrackPolling||self.clearInterval(this.subtitlePollingInterval),!this.media||!this.hls.config.renderTextTracksNatively)return;let e=null,t=nB(this.media.textTracks);for(let r=0;r<t.length;r++)if("hidden"===t[r].mode)e=t[r];else if("showing"===t[r].mode){e=t[r];break}let r=this.findTrackForTextTrack(e);this.subtitleTrack!==r&&this.setSubtitleTrack(r)},this.registerListeners()}destroy(){this.unregisterListeners(),this.tracks.length=0,this.tracksInGroup.length=0,this.currentTrack=null,this.onTextTracksChanged=this.asyncPollTrackChange=null,super.destroy()}get subtitleDisplay(){return this._subtitleDisplay}set subtitleDisplay(e){this._subtitleDisplay=e,this.trackId>-1&&this.toggleTrackModes()}registerListeners(){let{hls:e}=this;e.on(o.MEDIA_ATTACHED,this.onMediaAttached,this),e.on(o.MEDIA_DETACHING,this.onMediaDetaching,this),e.on(o.MANIFEST_LOADING,this.onManifestLoading,this),e.on(o.MANIFEST_PARSED,this.onManifestParsed,this),e.on(o.LEVEL_LOADING,this.onLevelLoading,this),e.on(o.LEVEL_SWITCHING,this.onLevelSwitching,this),e.on(o.SUBTITLE_TRACK_LOADED,this.onSubtitleTrackLoaded,this),e.on(o.ERROR,this.onError,this)}unregisterListeners(){let{hls:e}=this;e.off(o.MEDIA_ATTACHED,this.onMediaAttached,this),e.off(o.MEDIA_DETACHING,this.onMediaDetaching,this),e.off(o.MANIFEST_LOADING,this.onManifestLoading,this),e.off(o.MANIFEST_PARSED,this.onManifestParsed,this),e.off(o.LEVEL_LOADING,this.onLevelLoading,this),e.off(o.LEVEL_SWITCHING,this.onLevelSwitching,this),e.off(o.SUBTITLE_TRACK_LOADED,this.onSubtitleTrackLoaded,this),e.off(o.ERROR,this.onError,this)}onMediaAttached(e,t){this.media=t.media,this.media&&(this.queuedDefaultTrack>-1&&(this.subtitleTrack=this.queuedDefaultTrack,this.queuedDefaultTrack=-1),this.useTextTrackPolling=!(this.media.textTracks&&"onchange"in this.media.textTracks),this.useTextTrackPolling?this.pollTrackChange(500):this.media.textTracks.addEventListener("change",this.asyncPollTrackChange))}pollTrackChange(e){self.clearInterval(this.subtitlePollingInterval),this.subtitlePollingInterval=self.setInterval(this.onTextTracksChanged,e)}onMediaDetaching(e,t){let r=this.media;if(!r)return;let i=!!t.transferMedia;self.clearInterval(this.subtitlePollingInterval),this.useTextTrackPolling||r.textTracks.removeEventListener("change",this.asyncPollTrackChange),this.trackId>-1&&(this.queuedDefaultTrack=this.trackId),this.subtitleTrack=-1,this.media=null,i||nB(r.textTracks).forEac
2469h(e=>{n$(e)})}onManifestLoading(){this.tracks=[],this.groupIds=null,this.tracksInGroup=[],this.trackId=-1,this.currentTrack=null,this.selectDefaultTrack=!0}onManifestParsed(e,t){this.tracks=t.subtitleTracks}onSubtitleTrackLoaded(e,t){let{id:r,groupId:i,details:n}=t,s=this.tracksInGroup[r];if(!s||s.groupId!==i)return void this.warn(`Subtitle track with id:${r} and group:${i} not found in active group ${null==s?void 0:s.groupId}`);let a=s.details;s.details=t.details,this.log(`Subtitle track ${r} "${s.name}" lang:${s.lang} group:${i} loaded [${n.startSN}-${n.endSN}]`),r===this.trackId&&this.playlistLoaded(r,t,a)}onLevelLoading(e,t){this.switchLevel(t.level)}onLevelSwitching(e,t){this.switchLevel(t.level)}switchLevel(e){let t=this.hls.levels[e];if(!t)return;let r=t.subtitleGroups||null,i=this.groupIds,n=this.currentTrack;if(!r||(null==i?void 0:i.length)!==(null==r?void 0:r.length)||null!=r&&r.some(e=>(null==i?void 0:i.indexOf(e))===-1)){this.groupIds=r,this.trackId=-1,this.currentTrack=null;let e=this.tracks.filter(e=>!r||-1!==r.indexOf(e.groupId));if(e.length)this.selectDefaultTrack&&!e.some(e=>e.default)&&(this.selectDefaultTrack=!1),e.forEach((e,t)=>{e.id=t});else if(!n&&!this.tracksInGroup.length)return;this.tracksInGroup=e;let t=this.hls.config.subtitlePreference;if(!n&&t){this.selectDefaultTrack=!1;let r=eQ(t,e);if(r>-1)n=e[r];else{let e=eQ(t,this.tracks);n=this.tracks[e]}}let i=this.findTrackId(n);-1===i&&n&&(i=this.findTrackId(null)),this.log(`Updating subtitle tracks, ${e.length} track(s) found in "${null==r?void 0:r.join(",")}" group-id`),this.hls.trigger(o.SUBTITLE_TRACKS_UPDATED,{subtitleTracks:e}),-1!==i&&-1===this.trackId&&this.setSubtitleTrack(i)}}findTrackId(e){let t=this.tracksInGroup,r=this.selectDefaultTrack;for(let i=0;i<t.length;i++){let n=t[i];if((!r||n.default)&&(r||e)&&(!e||eX(n,e)))return i}if(e){for(let r=0;r<t.length;r++){let i=t[r];if(iX(e.attrs,i.attrs,["LANGUAGE","ASSOC-LANGUAGE","CHARACTERISTICS"]))return r}for(let r=0;r<t.length;r++){let i=t[r];if(iX(e.attrs,i.attrs,["LANGUAGE"]))return r}}return -1}findTrackForTextTrack(e){if(e){let t=this.tracksInGroup;for(let r=0;r<t.length;r++)if(iJ(t[r],e))return r}return -1}onError(e,t){!t.fatal&&t.context&&(t.context.type!==w||t.context.id!==this.trackId||this.groupIds&&-1===this.groupIds.indexOf(t.context.groupId)||this.checkRetry(t))}get allSubtitleTracks(){return this.tracks}get subtitleTracks(){return this.tracksInGroup}get subtitleTrack(){return this.trackId}set subtitleTrack(e){this.selectDefaultTrack=!1,this.setSubtitleTrack(e)}setSubtitleOption(e){if(this.hls.config.subtitlePreference=e,e){if(-1===e.id)return this.setSubtitleTrack(-1),null;let t=this.allSubtitleTracks;if(this.selectDefaultTrack=!1,t.length){let r=this.currentTrack;if(r&&eX(e,r))return r;let i=eQ(e,this.tracksInGroup);if(i>-1){let e=this.tracksInGroup[i];return this.setSubtitleTrack(i),e}{if(r)return null;let i=eQ(e,t);if(i>-1)return t[i]}}}return null}loadPlaylist(e){super.loadPlaylist(),this.shouldLoadPlaylist(this.currentTrack)&&this.scheduleLoading(this.currentTrack,e)}loadingPlaylist(e,t){super.loadingPlaylist(e,t);let r=e.id,i=e.groupId,n=this.getUrlWithDirectives(e.url,t),s=e.details,a=null==s?void 0:s.age;this.log(`Loading subtitle ${r} "${e.name}" lang:${e.lang} group:${i}${(null==t?void 0:t.msn)!==void 0?" at sn "+t.msn+" part "+t.part:""}${a&&s.live?" age "+a.toFixed(1)+(s.type?" "+s.type:""):""} ${n}`),this.hls.trigger(o.SUBTITLE_TRACK_LOADING,{url:n,id:r,groupId:i,deliveryDirectives:t||null,track:e})}toggleTrackModes(){let e,{media:t}=this;if(!t)return;let r=nB(t.textTracks),i=this.currentTrack;if(i&&((e=r.filter(e=>iJ(i,e))[0])||this.warn(`Unable to find subtitle TextTrack with name "${i.name}" and language "${i.lang}"`)),[].slice.call(r).forEach(t=>{"disabled"!==t.mode&&t!==e&&(t.mode="disabled")}),e){let t=this.subtitleDisplay?"showing":"hidden";e.mode!==t&&(e.mode=t)}}setSubtitleTrack(e){let t=this.tracksInGroup;if(!this.media){this.queuedDefaultTrack=e;return}if(e<-1||e>=t.length||!r(e))return void this.warn(`Invalid subtitle track id: ${e}`);this.selectDefaultTrack=!1;let i=this.currentTrack,n=t[e]||null;if(this.trackId=e,this.currentTrack=n,this.toggleTrackModes(),!n)return void this.hls.trigger(o.SUBTITLE_TRACK_SWITCH,{id:e});let s=!!n.details&&!n.details.live;if(e===this.trackId&&n===i&&s)return;this.log(`Switching to subtitle-track ${e}`+(n?` "${n.name}" lang:${n.lang} group:${n.groupId}`:""));let{id:a,groupId:l="",name:u,type:c,url:d}=n;this.hls.trigger(o.SUBTITLE_TRACK_SWITCH,{id:a,groupId:l,name:u,type:c,url:d});let h=this.switchParams(n.url,null==i?void 0:i.details,n.details);this.loadPlaylist(h)}},timelineController:class{constructor(e){this.hls=void 0,this.media=null,this.config=void 0,this.enabled=!0,this.Cues=void 0,this.textTracks=[],this.tracks=[],this.initPTS=[],this.unparsedVttFrags=[],this.captionsTracks={},this.nonNativeCaptionsTracks={},this.cea608Parser1=void 0,this.cea608Parser2=void 0,this.lastCc=-1,this.lastSn=-1,this.lastPartIndex=-1,this.prevCC=-1,this.vttCCs=sP(),this.captionsProperties=void 0,this.hls=e,this.config=e.config,this.Cues=e.config.cueHandler,this.captionsProperties={textTrack1:{label:this.config.captionsTextTrack1Label,languageCode:this.config.captionsTextTrack1LanguageCode},textTrack2:{label:this.config.captionsTextTrack2Label,languageCode:this.config.captionsTextTrack2LanguageCode},textTrack3:{label:this.config.captionsTextTrack3Label,languageCode:this.config.captionsTextTrack3LanguageCode},textTrack4:{label:this.config.captionsTextTrack4Label,languageCode:this.config.captionsTextTrack4LanguageCode}}
vendor: 3,582 bytes, line 2469
2469,e.on(o.MEDIA_ATTACHING,this.onMediaAttaching,this),e.on(o.MEDIA_DETACHING,this.onMediaDetaching,this),e.on(o.MANIFEST_LOADING,this.onManifestLoading,this),e.on(o.MANIFEST_LOADED,this.onManifestLoaded,this),e.on(o.SUBTITLE_TRACKS_UPDATED,this.onSubtitleTracksUpdated,this),e.on(o.FRAG_LOADING,this.onFragLoading,this),e.on(o.FRAG_LOADED,this.onFragLoaded,this),e.on(o.FRAG_PARSING_USERDATA,this.onFragParsingUserdata,this),e.on(o.FRAG_DECRYPTED,this.onFragDecrypted,this),e.on(o.INIT_PTS_FOUND,this.onInitPtsFound,this),e.on(o.SUBTITLE_TRACKS_CLEARED,this.onSubtitleTracksCleared,this),e.on(o.BUFFER_FLUSHING,this.onBufferFlushing,this)}destroy(){let{hls:e}=this;e.off(o.MEDIA_ATTACHING,this.onMediaAttaching,this),e.off(o.MEDIA_DETACHING,this.onMediaDetaching,this),e.off(o.MANIFEST_LOADING,this.onManifestLoading,this),e.off(o.MANIFEST_LOADED,this.onManifestLoaded,this),e.off(o.SUBTITLE_TRACKS_UPDATED,this.onSubtitleTracksUpdated,this),e.off(o.FRAG_LOADING,this.onFragLoading,this),e.off(o.FRAG_LOADED,this.onFragLoaded,this),e.off(o.FRAG_PARSING_USERDATA,this.onFragParsingUserdata,this),e.off(o.FRAG_DECRYPTED,this.onFragDecrypted,this),e.off(o.INIT_PTS_FOUND,this.onInitPtsFound,this),e.off(o.SUBTITLE_TRACKS_CLEARED,this.onSubtitleTracksCleared,this),e.off(o.BUFFER_FLUSHING,this.onBufferFlushing,this),this.hls=this.config=this.media=null,this.cea608Parser1=this.cea608Parser2=void 0}initCea608Parsers(){let e=new sD(this,"textTrack1"),t=new sD(this,"textTrack2"),r=new sD(this,"textTrack3"),i=new sD(this,"textTrack4");this.cea608Parser1=new sa(1,e,t),this.cea608Parser2=new sa(3,r,i)}addCues(e,t,r,i,n){let s=!1;for(let e=n.length;e--;){var a,l;let i=n[e],o=(a=i[0],l=i[1],Math.min(l,r)-Math.max(a,t));if(o>=0&&(i[0]=Math.min(i[0],t),i[1]=Math.max(i[1],r),s=!0,o/(r-t)>.5))return}if(s||n.push([t,r]),this.config.renderTextTracksNatively){let n=this.captionsTracks[e];this.Cues.newCue(n,t,r,i)}else{let n=this.Cues.newCue(null,t,r,i);this.hls.trigger(o.CUES_PARSED,{type:"captions",cues:n,track:e})}}onInitPtsFound(e,{frag:t,id:r,initPTS:i,timescale:n,trackId:s}){let{unparsedVttFrags:a}=this;r===A&&(this.initPTS[t.cc]={baseTime:i,timescale:n,trackId:s}),a.length&&(this.unparsedVttFrags=[],a.forEach(e=>{this.initPTS[e.frag.cc]?this.onFragLoaded(o.FRAG_LOADED,e):this.hls.trigger(o.SUBTITLE_FRAG_PROCESSED,{success:!1,frag:e.frag,error:Error("Subtitle discontinuity domain does not match main")})}))}getExistingTrack(e,t){let{media:r}=this;if(r)for(let i=0;i<r.textTracks.length;i++){let n=r.textTracks[i];if(sO(n,{name:e,lang:t,characteristics:"transcribes-spoken-dialog,describes-music-and-sound"}))return n}return null}createCaptionsTrack(e){this.config.renderTextTracksNatively?this.createNativeTrack(e):this.createNonNativeTrack(e)}createNativeTrack(e){if(this.captionsTracks[e])return;let{captionsProperties:t,captionsTracks:r,media:i}=this,{label:n,languageCode:s}=t[e],a=this.getExistingTrack(n,s);if(a)r[e]=a,n$(r[e]),nM(r[e],i);else{let t=this.createTextTrack("captions",n,s);t&&(t[e]=!0,r[e]=t)}}createNonNativeTrack(e){if(this.nonNativeCaptionsTracks[e])return;let t=this.captionsProperties[e];if(!t)return;let r={_id:e,label:t.label,kind:"captions",default:!!t.media&&!!t.media.default,closedCaptions:t.media};this.nonNativeCaptionsTracks[e]=r,this.hls.trigger(o.NON_NATIVE_TEXT_TRACKS_FOUND,{tracks:[r]})}createTextTrack(e,t,r){let i=this.media;if(i)return i.addTextTrack(e,t,r)}onMediaAttaching(e,t){this.media=t.media,t.mediaSource||this._cleanTracks()}onMediaDetaching(e,t){let r=!!t.transferMedia;if(this.media=null,r)return;let{captionsTracks:i}=this;
2469Object.keys(i).forEach(e=>{n$(i[e]),delete i[e]}),this.nonNativeCaptionsTracks={}}onManifestLoading(){this.lastCc=-1,this.lastSn=-1,this.lastPartIndex=-1,this.prevCC=-1,this.vttCCs=sP(),this._cleanTracks(),this.tracks=[],this.captionsTracks={},this.nonNativeCaptionsTracks={},this.textTracks=[],this.unparsedVttFrags=[],this.initPTS=[],this.cea608Parser1&&this.cea608Parser2&&(this.cea608Parser1.reset(),this.cea608Parser2.reset())}_cleanTracks(){let{media:e}=this;if(!e)return;let t=e.textTracks;if(t)for(let e=0;e<t.length;e++)n$(t[e])}onSubtitleTracksUpdated(e,t){let r=t.subtitleTracks||[],i=r.some(e=>e.textCodec===sE);if(this.config.enableWebVTT||i&&this.config.enableIMSC1){if(iQ(this.tracks,r)){this.tracks=r;return}if(this.textTracks=[],this.tracks=r,this.config.renderTextTracksNatively){let e=this.media,t=e?nB(e.textTracks):null;if(this.tracks.forEach((e,r)=>{let i;if(t){let r=null;for(let i=0;i<t.length;i++)if(t[i]&&sO(t[i],e)){r=t[i],t[i]=null;break}r&&(i=r)}if(i)n$(i);else{let t=sL(e);(i=this.createTextTrack(t,e.name,e.lang))&&(i.mode="disabled")}i&&this.textTracks.push(i)}),null!=t&&t.length){let e=t.filter(e=>null!==e).map(e=>e.label);e.length&&this.hls.logger.warn(`Media element contains unused subtitle tracks: ${e.join(", ")}. Replace media element for each source to clear TextTracks and captions menu.`)}}else if(this.tracks.length){let e=this.tracks.map(e=>({label:e.name,kind:e.type.toLowerCase(),default:e.default,subtitleTrack:e}));this.hls.trigger(o.NON_NATIVE_TEXT_TRACKS_FOUND,{tracks:e})}}}onManifestLoaded(e,t){this.config.enableCEA708Captions&&t.captions&&t.captions.forEach(e=>{let t=/(?:CC|SERVICE)([1-4])/.exec(e.instreamId);if(!t)return;let r=`textTrack${t[1]}`,i=this.captionsProperties[r];i&&(i.label=e.name,e.lang&&(i.languageCode=e.lang),i.media=e)})}closedCaptionsForLevel(e){let t=this.hls.levels[e.level];return null==t?void 0:t.attrs["CLOSED-CAPTIONS"]}onFragLoading(e,t){if(this.enabled&&t.frag.type===A){var r,i;let{cea608Parser1:e,cea608Parser2:n,lastSn:s}=this,{cc:a,sn:o}=t.frag,l=null!=(r=null==(i=t.part)?void 0:i.index)?r:-1;e&&n&&(o!==s+1||o===s&&l!==this.lastPartIndex+1||a!==this.lastCc)&&(e.reset(),n.reset()),this.lastCc=a,this.lastSn=o,this.lastPartIndex=l}}onFragLoaded(e,t){let{frag:r,payload:i}=t;if(r.type===I)if(i.byteLength){let e=r.decryptdata,n="stats"in t;if(null==e||!e.encrypted||n){let e=this.tracks[r.level],n=this.vttCCs;n[r.cc]||(n[r.cc]={start:r.start,prevCC:this.prevCC,new:!0},this.prevCC=r.cc),e&&e.textCodec===sE?this._parseIMSC1(r,i):this._parseVTTs(t)}}else this.hls.trigger(o.SUBTITLE_FRAG_PROCESSED,{success:!1,frag:r,error:Error("Empty subtitle payload")})}_parseIMSC1(e,t){let r=this.hls;sw(t,this.initPTS[e.cc],t=>{this._appendCues(t,e.level),r.trigger(o.SUBTITLE_FRAG_PROCESSED,{success:!0,frag:e})},t=>{r.logger.log(`Failed to parse IMSC1: ${t}`),r.trigger(o.SUBTITLE_FRAG_PROCESSED,{success:!1,frag:e,error:t})})}_parseVTTs(e){var t,r,i,n,s,a,l,u;let c,d,h,f,p,g,m,y,v,{frag:b,payload:_}=e,{initPTS:E,unparsedVttFrags:S}=this,x=E.length-1;if(!E[b.cc]&&-1===x)return void S.push(e);let T=this.hls;r=null!=(t=b.initSegment)&&t.data?em(b.initSegment.data,new Uint8Array(_)).buffer:_,i=this.initPTS[b.cc],n=this.vttCCs,s=b.cc,a=b.start,l=e=>{this._appendCues(e,b.level),T.trigger(o.SUBTITLE_FRAG_PROCESSED,{success:!0,frag:b})},u=t=>{let r="Missing initPTS for VTT MPEGTS"===t.message;r?S.push(e):this._fallbackToIMSC1(b,_),T.logger.log(`Failed to parse VTT cue: ${t}`),r&&x>b.cc||T.trigger(o.SUBTITLE_FRAG_PROCESSED,{success:!1,frag:b,error:t})},d=new sg,h=V(new Uint8Array(r)).trim().replace(sm,"\n").split("\n"),f=[],p=i?function(e,t=1){return ik(e,9e4,1/t)}(i.baseTime,i.timescale):0,g="00:00.000",m=0,y=0,v=!0,d.oncue=function(e){let t=n[s],r=n.ccOffset,o=(m-p)/9e4;if(null!=t&&t.new&&(void 0!==y?r=n.ccOffset=t.start:s_(n,s,o)),o){if(!i){c=Error("Missing initPTS for VTT MPEGTS");return}r=o-n.presentationOffset}let l=e.endTime-e.startTime,u=iN((e.startTime+r-y)*9e4,9e4*a)/9e4;e.startTime=Math.max(u,0),e.endTime=Math.max(u+l,0);let d=e.text.trim();e.text=decodeURIComponent(encodeURIComponent(d)),e.id||(e.id=sb(e.startTime,e.endTime,d)),e.endTime>0&&f.push(e)},d.onparsingerror=function(e){c=e},d.onflush=function(){c?u(c):l(f)}
2469,h.forEach(e=>{if(v)if(sy(e,"X-TIMESTAMP-MAP=")){v=!1,e.slice(16).split(",").forEach(e=>{sy(e,"LOCAL:")?g=e.slice(6):sy(e,"MPEGTS:")&&(m=parseInt(e.slice(7)))});try{y=sv(g)/1e3}catch(e){c=e}return}else""===e&&(v=!1);d.parse(e+"\n")}),d.flush()}_fallbackToIMSC1(e,t){let r=this.tracks[e.level];r.textCodec||sw(t,this.initPTS[e.cc],()=>{r.textCodec=sE,this._parseIMSC1(e,t)},()=>{r.textCodec="wvtt"})}_appendCues(e,t){let r=this.hls;if(this.config.renderTextTracksNatively){let r=this.textTracks[t];if(!r||"disabled"===r.mode)return;e.forEach(e=>nj(r,e))}else{let i=this.tracks[t];if(!i)return;let n=i.default?"default":"subtitles"+t;r.trigger(o.CUES_PARSED,{type:"subtitles",cues:e,track:n})}}onFragDecrypted(e,t){let{frag:r}=t;r.type===I&&this.onFragLoaded(o.FRAG_LOADED,t)}onSubtitleTracksCleared(){this.tracks=[],this.captionsTracks={}}onFragParsingUserdata(e,t){if(!this.enabled||!this.config.enableCEA708Captions)return;let{frag:r,samples:i}=t;if(r.type!==A||"NONE"!==this.closedCaptionsForLevel(r))for(let e=0;e<i.length;e++){let t=i[e].bytes;if(t){this.cea608Parser1||this.initCea608Parsers();let r=this.extractCea608Data(t);this.cea608Parser1.addData(i[e].pts,r[0]),this.cea608Parser2.addData(i[e].pts,r[1])}}}onBufferFlushing(e,{startOffset:t,endOffset:r,endOffsetSubtitles:i,type:n}){let{media:s}=this;if(s&&!(s.currentTime<r)){if(!n||"video"===n){let{captionsTracks:e}=this;Object.keys(e).forEach(i=>nU(e[i],t,r))}if(this.config.renderTextTracksNatively&&0===t&&void 0!==i){let{textTracks:e}=this;Object.keys(e).forEach(r=>nU(e[r],t,i))}}}extractCea608Data(e){let t=[[],[]],r=31&e[0],i=2;for(let n=0;n<r;n++){let r=e[i++],n=127&e[i++],s=127&e[i++];if((0!==n||0!==s)&&(4&r)!=0){let e=3&r;(0===e||1===e)&&(t[e].push(n),t[e].push(s))}}return t}},audioStreamController:class extends rU{constructor(e,t,r){super(e,t,r,"audio-stream-controller",R),this.mainAnchor=null,this.mainFragLoading=null,this.audioOnly=!1,this.bufferedTrack=null,this.switchingTrack=null,this.trackId=-1,this.waitingData=null,this.mainDetails=null,this.flushing=!1,this.bufferFlushed=!1,this.cachedTrackLoadedData=null,this.registerListeners()}onHandlerDestroying(){this.unregisterListeners(),super.onHandlerDestroying(),this.resetItem()}resetItem(){this.mainDetails=this.mainAnchor=this.mainFragLoading=this.bufferedTrack=this.switchingTrack=this.waitingData=this.cachedTrackLoadedData=null}registerListeners(){super.registerListeners();let{hls:e}=this;e.on(o.LEVEL_LOADED,this.onLevelLoaded,this),e.on(o.AUDIO_TRACKS_UPDATED,this.onAudioTracksUpdated,this),e.on(o.AUDIO_TRACK_SWITCHING,this.onAudioTrackSwitching,this),e.on(o.AUDIO_TRACK_LOADED,this.onAudioTrackLoaded,this),e.on(o.BUFFER_RESET,this.onBufferReset,this),e.on(o.BUFFER_CREATED,this.onBufferCreated,this),e.on(o.BUFFER_FLUSHING,this.onBufferFlushing,this),e.on(o.BUFFER_FLUSHED,this.onBufferFlushed,this),e.on(o.INIT_PTS_FOUND,this.onInitPtsFound,this),e.on(o.FRAG_LOADING,this.onFragLoading,this),e.on(o.FRAG_BUFFERED,this.onFragBuffered,this)}unregisterListeners(){let{hls:e}=this;e&&(super.unregisterListeners(),e.off(o.LEVEL_LOADED,this.onLevelLoaded,this),e.off(o.AUDIO_TRACKS_UPDATED,this.onAudioTracksUpdated,this),e.off(o.AUDIO_TRACK_SWITCHING,this.onAudioTrackSwitching,this),e.off(o.AUDIO_TRACK_LOADED,this.onAudioTrackLoaded,this),e.off(o.BUFFER_RESET,this.onBufferReset,this),e.off(o.BUFFER_CREATED,this.onBufferCreated,this),e.off(o.BUFFER_FLUSHING,this.onBufferFlushing,this),e.off(o.BUFFER_FLUSHED,this.onBufferFlushed,this),e.off(o.INIT_PTS_FOUND,this.onInitPtsFound,this),e.off(o.FRAG_LOADING,this.onFragLoading,this),e.off(o.FRAG_BUFFERED,this.onFragBuffered,this))}onInitPtsFound(e,{frag:t,id:r,initPTS:i,timescale:n,trackId:s}){if(r===A){let e=t.cc,r=this.fragCurrent;if(this.initPTS[e]={baseTime:i,timescale:n,trackId:s},this.log(`InitPTS for cc: ${e} found from main: ${i/n} (${i}/${n}) trackId: ${s}`),this.mainAnchor=t,this.state===rj){let r=this.waitingData;(r||this.loadingParts)&&(!r||r.frag.cc===e)||this.syncWithAnchor(t,null==r?void 0:r.frag)}else!this.hls.hasEnoughToStart&&r&&r.cc!==e?(r.abortRequests(),this.syncWithAnchor(t,r)):this.state===rk&&this.tick()}}getLoadPosition(){return!this.startFragRequested&&this.nextLoadPosition>=0?this.nextLoadPosition:super.getLoadPosition()}syncWithAnchor(e,t){var r;let i=(null==(r=this.mainFragLoading)?void 0:r.frag)||null;if(t&&(null==i?void 0:i.cc)===t.cc)return;let n=(i||e).cc,s=e4(this.getLevelDetails(),n,this.getLoadPosition());s&&(this.log(`Syncing with main frag at ${s.start} cc ${s.cc}`),this.startFragRequested=!1,this.nextLoadPosition=s.start,this.resetLoadingState(),this.state===rk&&this.doTickIdle())}
2469startLoad(e,t){if(!this.levels){this.startPosition=e,this.state=rI;return}let r=this.lastCurrentTime;this.stopLoad(),this.setInterval(100),r>0&&-1===e?(this.log(`Override startPosition with lastCurrentTime @${r.toFixed(3)}`),e=r,this.state=rk):this.state=rO,this.nextLoadPosition=this.lastCurrentTime=e+this.timelineOffset,this.startPosition=t?-1:e,this.tick()}doTick(){switch(this.state){case rk:this.doTickIdle();break;case rO:{let{levels:e,trackId:t}=this,r=null==e?void 0:e[t],i=null==r?void 0:r.details;if(i&&!this.waitForLive(r)){if(this.waitForCdnTuneIn(i))break;this.state=rj}break}case rL:this.checkRetryDate();break;case rj:{let e=this.waitingData;if(e){let{frag:t,part:r,cache:i,complete:n}=e,s=this.mainAnchor;if(void 0!==this.initPTS[t.cc]){this.waitingData=null,this.state=rD;let e={frag:t,part:r,payload:i.flush().buffer,networkDetails:null};this._handleFragmentLoadProgress(e),n&&super._handleFragmentLoadComplete(e)}else s&&s.cc!==e.frag.cc&&this.syncWithAnchor(s,e.frag)}else this.state=rk}}this.onTickEnd()}resetLoadingState(){let e=this.waitingData;e&&(this.fragmentTracker.removeFragment(e.frag),this.waitingData=null),super.resetLoadingState()}onTickEnd(){let{media:e}=this;null!=e&&e.readyState&&(this.lastCurrentTime=e.currentTime)}doTickIdle(){var e;let{hls:t,levels:r,media:i,trackId:n}=this,s=t.config;if(!this.buffering||!i&&!this.primaryPrefetch&&(this.startFragRequested||!s.startFragPrefetch)||!(null!=r&&r[n]))return;let a=r[n],l=a.details;if(!l||this.waitForLive(a)||this.waitForCdnTuneIn(l)){this.state=rO,this.startFragRequested=!1;return}let u=this.mediaBuffer?this.mediaBuffer:this.media;this.bufferFlushed&&u&&(this.bufferFlushed=!1,this.afterBufferFlushed(u,W,R));let c=this.getFwdBufferInfo(u,R);if(null===c)return;if(!this.switchingTrack&&this._streamEnded(c,l)){t.trigger(o.BUFFER_EOS,{type:"audio"}),this.state=rN;return}let d=c.len,h=t.maxBufferLength,f=l.fragments,p=f[0].start,g=this.getLoadPosition(),m=this.flushing?g:c.end;if(this.switchingTrack&&i&&l.PTSKnown&&g<p&&(c.end>p||c.nextStart)&&(this.log("Alt audio track ahead of main track, seek to start of alt audio track"),i.currentTime=p+.05),d>=h&&!this.switchingTrack&&m<f[f.length-1].start)return;let y=this.getNextFragment(m,l);if(y&&this.isLoopLoading(y,m)&&(y=this.getNextFragmentLoopLoading(y,l,c,A,h)),!y){this.bufferFlushed=!0;return}if(this.exceedsMaxBuffer(c,h,y))return;let v=(null==(e=this.mainFragLoading)?void 0:e.frag)||null;if(!this.audioOnly&&this.startFragRequested&&v&&J(y)&&!y.endList&&(!l.live||!this.loadingParts&&m<this.hls.liveSyncPosition)&&("OK"===this.fragmentTracker.getState(v)&&(this.mainFragLoading=v=null),v&&J(v))){if(y.start>v.end){let e=this.fragmentTracker.getFragAtPos(m,A);e&&e.end>v.end&&(v=e,this.mainFragLoading={frag:e,targetBufferTime:null})}if(y.start>v.end)return}this.loadFragment(y,a,m)}onMediaDetaching(e,t){this.bufferFlushed=this.flushing=!1,super.onMediaDetaching(e,t)}onAudioTracksUpdated(e,{audioTracks:t}){this.resetTransmuxer(),this.levels=t.map(e=>new eq(e))}onAudioTrackSwitching(e,t){let r=!!t.url;this.trackId=t.id;let{fragCurrent:i}=this;i&&(i.abortRequests(),this.removeUnbufferedFrags(i.start)),this.resetLoadingState(),r?(this.switchingTrack=t,this.flushAudioIfNeeded(t),this.state!==rI&&(this.setInterval(100),this.state=rk,this.tick())):(this.resetTransmuxer(),this.switchingTrack=null,this.bufferedTrack=t,this.clearInterval())}onManifestLoading(){super.onManifestLoading(),this.bufferFlushed=this.flushing=this.audioOnly=!1,this.resetItem(),this.trackId=-1}onLevelLoaded(e,t){this.mainDetails=t.details;let r=this.cachedTrackLoadedData;r&&(this.cachedTrackLoadedData=null,this.onAudioTrackLoaded(o.AUDIO_TRACK_LOADED,r))}onAudioTrackLoaded(e,t){var r,i;let{levels:n}=this,{details:s,id:a,groupId:l,track:u}=t;if(!n)return void this.warn(`Audio tracks reset while loading track ${a} "${u.name}" of "${l}"`);let c=this.mainDetails;if(!c||s.endCC>c.endCC||c.expired){this.cachedTrackLoadedData=t,this.state!==rI&&(this.state=rO);return}this.cachedTrackLoadedData=null,this.log(`Audio track ${a} "${u.name}" of "${l}" loaded [${s.startSN},${s.endSN}]${s.lastPartSn?`[part-${s.lastPartSn}-${s.lastPartIndex}]`:""},duration:${s.totalduration}`);let d=n[a],h=0;if(s.live||null!=(r=d.details)&&r.live){if(this.checkLiveUpdate(s),s.deltaUpdateFailed)return;d.details&&(h=this.alignPlaylists(s,d.details,null==(i=this.levelLastLoaded)?void 0:i.details)),s.alignedSliding||(rx(s,c),s.alignedSliding||rT(s,c),h=s.fragmentStart)}d.details=s,this.levelLastLoaded=d,this.startFragRequested||this.setStartPosition(c,h),this.hls.trigger(o.AUDIO_TRACK_UPDATED,{details:s,id:a,groupId:t.groupId}),this.state!==rO||this.waitForCdnTuneIn(s)||(this.state=rk),this.tick()}_handleFragmentLoadProgress(e){var t;let r=e.frag,{part:i,payload:n}=e,{config:s,trackId:a,levels:o}=this;if(!o)return void this.warn(`Audio tracks were reset while fragment load was in progress. Fragment ${r.sn} of level ${r.level} will not be buffered`);let l=o[a];if(!l)return void this.warn("Audio track is undefined on fragment load progress");let u=l.details;if(!u){this.warn("Audio track details undefined on fragment load progress"),this.removeUnbufferedFrags(r.start);return}let c=s.defaultAudioCodec||l.audioCodec||"mp4a.40.2",d=this.transmuxer;
2469d||(d=this.transmuxer=new iW(this.hls,R,this._handleTransmuxComplete.bind(this),this._handleTransmuxerFlush.bind(this)));let h=this.initPTS[r.cc],f=null==(t=r.initSegment)?void 0:t.data;if(void 0!==h){let e=i?i.index:-1,t=new t_(r.level,r.sn,r.stats.chunkCount,n.byteLength,e,-1!==e);d.push(n,f,c,"",r,i,u.totalduration,!1,t,h)}else{this.log(`Unknown video PTS for cc ${r.cc}, waiting for video PTS before demuxing audio frag ${r.sn} of [${u.startSN} ,${u.endSN}],track ${a}`);let{cache:e}=this.waitingData=this.waitingData||{frag:r,part:i,cache:new rV,complete:!1};e.push(new Uint8Array(n)),this.state!==rI&&(this.state=rj)}}_handleFragmentLoadComplete(e){if(this.waitingData){this.waitingData.complete=!0;return}super._handleFragmentLoadComplete(e)}onBufferReset(){this.mediaBuffer=null}onBufferCreated(e,t){this.bufferFlushed=this.flushing=!1;let r=t.tracks.audio;r&&(this.mediaBuffer=r.buffer||null)}onFragLoading(e,t){!this.audioOnly&&t.frag.type===A&&J(t.frag)&&(this.mainFragLoading=t,this.state===rk&&this.tick())}onFragBuffered(e,t){let{frag:r,part:i}=t;if(r.type!==R){this.audioOnly||r.type!==A||r.elementaryStreams.video||r.elementaryStreams.audiovideo||(this.audioOnly=!0,this.mainFragLoading=null);return}if(this.fragContextChanged(r))return void this.warn(`Fragment ${r.sn}${i?" p: "+i.index:""} of level ${r.level} finished buffering, but was aborted. state: ${this.state}, audioSwitch: ${this.switchingTrack?this.switchingTrack.name:"false"}`);if(J(r)){this.fragPrevious=r;let e=this.switchingTrack;e&&(this.bufferedTrack=e,this.switchingTrack=null,this.hls.trigger(o.AUDIO_TRACK_SWITCHED,O({},e)))}this.fragBufferedComplete(r,i),this.media&&this.tick()}onError(e,t){var r;if(t.fatal){this.state=rM;return}switch(t.details){case a.FRAG_GAP:case a.FRAG_PARSING_ERROR:case a.FRAG_DECRYPT_ERROR:case a.FRAG_LOAD_ERROR:case a.FRAG_LOAD_TIMEOUT:case a.KEY_LOAD_ERROR:case a.KEY_LOAD_TIMEOUT:this.onFragmentOrKeyLoadError(R,t);break;case a.AUDIO_TRACK_LOAD_ERROR:case a.AUDIO_TRACK_LOAD_TIMEOUT:case a.LEVEL_PARSING_ERROR:t.levelRetry||this.state!==rO||(null==(r=t.context)?void 0:r.type)!==T||(this.state=rk);break;case a.BUFFER_ADD_CODEC_ERROR:case a.BUFFER_APPEND_ERROR:if("audio"!==t.parent)return;this.reduceLengthAndFlushBuffer(t)||this.resetLoadingState();break;case a.BUFFER_FULL_ERROR:if("audio"!==t.parent)return;this.reduceLengthAndFlushBuffer(t)&&(this.bufferedTrack=null,super.flushMainBuffer(0,1/0,"audio"));break;case a.INTERNAL_EXCEPTION:this.recoverWorkerError(t)}}onBufferFlushing(e,{type:t}){t!==Y&&(this.flushing=!0)}onBufferFlushed(e,{type:t}){if(t!==Y){this.flushing=!1,this.bufferFlushed=!0,this.state===rN&&(this.state=rk);let e=this.mediaBuffer||this.media;e&&(this.afterBufferFlushed(e,t,R),this.tick())}}_handleTransmuxComplete(e){var t;let r="audio",{hls:i}=this,{remuxResult:n,chunkMeta:s}=e,a=this.getCurrentContext(s);if(!a)return void this.resetWhenMissingContext(s);let{frag:l,part:u,level:c}=a,{details:d}=c,{audio:h,text:f,id3:p,initSegment:g}=n;if(this.fragContextChanged(l)||!d)return void this.fragmentTracker.removeFragment(l);if(this.state=rP,this.switchingTrack&&h&&this.completeAudioSwitch(this.switchingTrack),null!=g&&g.tracks){let e=l.initSegment||l;if(this.unhandledEncryptionError(g,l))return;this._bufferInitSegment(c,g.tracks,e,s),i.trigger(o.FRAG_PARSING_INIT_SEGMENT,{frag:e,id:r,tracks:g.tracks})}if(h){let{startPTS:e,endPTS:t,startDTS:r,endDTS:i}=h;u&&(u.elementaryStreams[W]={startPTS:e,endPTS:t,startDTS:r,endDTS:i}),l.setElementaryStreamInfo(W,e,t,r,i),this.bufferFragmentData(h,l,u,s)}if(null!=p&&null!=(t=p.samples)&&t.length){let e=D({id:r,frag:l,details:d},p);i.trigger(o.FRAG_PARSING_METADATA,e)}if(f){let e=D({id:r,frag:l,details:d},f);i.trigger(o.FRAG_PARSING_USERDATA,e)}}_bufferInitSegment(e,t,r,i){if(this.state!==rP||(t.video&&delete t.video,t.audiovideo&&delete t.audiovideo,!t.audio))return;let n=t.audio;n.id=R;let s=e.audioCodec;this.log(`Init audio buffer, container:${n.container}, codecs[level/parsed]=[${s}/${n.codec}]`),s&&1===s.split(",").length&&(n.levelCodec=s),this.hls.trigger(o.BUFFER_CODECS,t);let a=n.initSegment;if(null!=a&&a.byteLength){let e={type:"audio",frag:r,part:null,chunkMeta:i,parent:r.type,data:a};this.hls.trigger(o.BUFFER_APPENDING,e)}this.tickImmediate()}loadFragment(e,t,r){let i=this.fragmentTracker.getState(e);if(this.switchingTrack||i===tn||i===ta){var n;if(J(e))if(null!=(n=t.details)&&n.live&&!this.initPTS[e.cc]){this.log(`Waiting for video PTS in continuity counter ${e.cc} of live stream before loading audio fragment ${e.sn} of level ${this.trackId}`),this.state=rj;let r=this.mainDetails;r&&r.fragmentStart!==t.details.fragmentStart&&rT(t.details,r)}else super.loadFragment(e,t,r);else this._loadInitSegment(e,t)}else this.clearTrackerIfNeeded(e)}flushAudioIfNeeded(e){if(this.media&&this.bufferedTrack){let{name:t,lang:r,assocLang:i,characteristics:n,audioCodec:s,channels:a}=this.bufferedTrack;eX({name:t,lang:r,assocLang:i,characteristics:n,audioCodec:s,channels:a},e,eJ)||(e0(e.url,this.hls)?(this.log("Switching audio track : flushing all audio"),super.flushMainBuffer(0,1/0,"audio"),this.bufferedTrack=null):this.bufferedTrack=e)}}completeAudioSwitch(e){let{hls:t}=this;this.flushAudioIfNeeded(e),this.bufferedTrack=e,this.switchingTrack=null,t.trigger(o.AUDIO_TRACK_SWITCHED,O({},e))}},audioTrackController:class extends iY{constructor(e){super(e,"audio-track-controller"),this.tracks=[],this.groupIds=null,this.tracksInGroup=[],this.trackId=-1,this.currentTrack=null,this.selectDefaultTrack=!0,this.registerListeners()}registerListeners(){let{hls:e}=this;e.on(o.MANIFEST_LOADING,this.onManifestLoading,this),e.on(o.MANIFEST_PARSED,this.onManifestParsed,this),e.on(o.LEVEL_LOADING,this.onLevelLoading,this),e.on(o.LEVEL_SWITCHING,this.onLevelSwitching,this),e.on(o.AUDIO_TRACK_LOADED,this.onAudioTrackLoaded,this),e.on(o.ERROR,this.onError,this)}unregisterListeners(){let{hls:e}=this;e.off(o.MANIFEST_LOADING,this.onManifestLoading,this),e.off(o.MANIFEST_PARSED,this.onManifestParsed,this),e.off(o.LEVEL_LOADING,this.onLevelLoading,this),e.off(o.LEVEL_SWITCHING,this.onLevelSwitching,this),e.off(o.AUDIO_TRACK_LOADED,this.onAudioTrackLoaded,this),e.off(o.ERROR,this.onError,this)}destroy(){this.unregisterListeners(),this.tracks.length=0,this.tracksInGroup.length=0,this.currentTrack=null,super.destroy()}onManifestLoading(){this.tracks=[],this.tracksInGroup=[],this.groupIds=null,this.currentTrack=null,this.trackId=-1,this.selectDefaultTrack=!0}onManifestParsed(e,t){this.tracks=t.audioTracks||[]}onAudioTrackLoaded(e,t){let{id:r,groupId:i,details:n}=t,s=this.tracksInGroup[r];if(!s||s.groupId!==i)return void this.warn(`Audio track with id:${r} and group:${i} not found in active group ${null==s?void 0:s.groupId}`);let a=s.details;s.details=t.details,this.log(`Audio track ${r} "${s.name}" lang:${s.lang} group:${i} loaded [${n.startSN}-${n.endSN}]`),r===this.trackId&&this.playlistLoaded(r,t,a)}onLevelLoading(e,t){this.switchLevel(t.level)}onLevelSwitching(e,t){this.switchLevel(t.level)}switchLevel(e){let t=this.hls.levels[e];if(!t)return;let r=t.audioGroups||null,i=this.groupIds,n=this.currentTrack;if(!r||(null==i?void 0:i.length)!==(null==r?void 0:r.length)||null!=r&&r.s
2469ome(e=>(null==i?void 0:i.indexOf(e))===-1)){this.groupIds=r,this.trackId=-1,this.currentTrack=null;let e=this.tracks.filter(e=>!r||-1!==r.indexOf(e.groupId));if(e.length)this.selectDefaultTrack&&!e.some(e=>e.default)&&(this.selectDefaultTrack=!1),e.forEach((e,t)=>{e.id=t});else if(!n&&!this.tracksInGroup.length)return;this.tracksInGroup=e;let t=this.hls.config.audioPreference;if(!n&&t){let r=eQ(t,e,eJ);if(r>-1)n=e[r];else{let e=eQ(t,this.tracks);n=this.tracks[e]}}let i=this.findTrackId(n);-1===i&&n&&(i=this.findTrackId(null)),this.log(`Updating audio tracks, ${e.length} track(s) found in group(s): ${null==r?void 0:r.join(",")}`),this.hls.trigger(o.AUDIO_TRACKS_UPDATED,{audioTracks:e});let u=this.trackId;if(-1!==i&&-1===u)this.setAudioTrack(i);else if(e.length&&-1===u){var l;let t=Error(`No audio track selected for current audio group-ID(s): ${null==(l=this.groupIds)?void 0:l.join(",")} track count: ${e.length}`);this.warn(t.message),this.hls.trigger(o.ERROR,{type:s.MEDIA_ERROR,details:a.AUDIO_TRACK_LOAD_ERROR,fatal:!0,error:t})}}}onError(e,t){!t.fatal&&t.context&&(t.context.type!==T||t.context.id!==this.trackId||this.groupIds&&-1===this.groupIds.indexOf(t.context.groupId)||this.checkRetry(t))}get allAudioTracks(){return this.tracks}get audioTracks(){return this.tracksInGroup}get audioTrack(){return this.trackId}set audioTrack(e){this.selectDefaultTrack=!1,this.setAudioTrack(e)}setAudioOption(e){let t=this.hls;if(t.config.audioPreference=e,e){let n=this.allAudioTracks;
2469if(this.selectDefaultTrack=!1,n.length){let s=this.currentTrack;if(s&&eX(e,s,eJ))return s;let a=eQ(e,this.tracksInGroup,eJ);if(a>-1){let e=this.tracksInGroup[a];return this.setAudioTrack(a),e}if(s){var r,i;let s,a,o,l,u,c,d=t.loadLevel;-1===d&&(d=t.firstAutoLevel);let h=(r=t.levels,s=r[i=d],(a=r.reduce((e,t,r)=>{let i=t.uri;return(e[i]||(e[i]=[])).push(r),e},{})[s.uri]).length>1&&(i=Math.max.apply(Math,a)),o=s.videoRange,l=s.frameRate,u=s.codecSet.substring(0,4),(c=eZ(r,i,t=>{if(t.videoRange!==o||t.frameRate!==l||t.codecSet.substring(0,4)!==u)return!1;let r=t.audioGroups;return eQ(e,n.filter(e=>!r||-1!==r.indexOf(e.groupId)),eJ)>-1}))>-1?c:eZ(r,i,t=>{let r=t.audioGroups;return eQ(e,n.filter(e=>!r||-1!==r.indexOf(e.groupId)),eJ)>-1}));if(-1===h)return null;t.nextLoadLevel=h}if(e.channels||e.audioCodec){let t=eQ(e,n);if(t>-1)return n[t]}}}return null}setAudioTrack(e){let t=this.tracksInGroup;if(e<0||e>=t.length)return void this.warn(`Invalid audio track id: ${e}`);this.selectDefaultTrack=!1;let r=this.currentTrack,i=t[e],n=i.details&&!i.details.live;if(e===this.trackId&&i===r&&n||(this.log(`Switching to audio-track ${e} "${i.name}" lang:${i.lang} group:${i.groupId} channels:${i.channels}`),this.trackId=e,this.currentTrack=i,this.hls.trigger(o.AUDIO_TRACK_SWITCHING,O({},i)),n))return;let s=this.switchParams(i.url,null==r?void 0:r.details,i.details);this.loadPlaylist(s)}findTrackId(e){let t=this.tracksInGroup;for(let r=0;r<t.length;r++){let i=t[r];if((!this.selectDefaultTrack||i.default)&&(!e||eX(e,i,eJ)))return r}if(e){let{name:r,lang:i,assocLang:n,characteristics:s,audioCodec:a,channels:o}=e;for(let e=0;e<t.length;e++)if(eX({name:r,lang:i,assocLang:n,characteristics:s,audioCodec:a,channels:o},t[e],eJ))return e;for(let r=0;r<t.length;r++){let i=t[r];if(iX(e.attrs,i.attrs,["LANGUAGE","ASSOC-LANGUAGE","CHARACTERISTICS"]))return r}for(let r=0;r<t.length;r++){let i=t[r];if(iX(e.attrs,i.attrs,["LANGUAGE"]))return r}}return -1}loadPlaylist(e){super.loadPlaylist();let t=this.currentTrack;this.shouldLoadPlaylist(t)&&e0(t.url,this.hls)&&this.scheduleLoading(t,e)}loadingPlaylist(e,t){super.loadingPlaylist(e,t);let r=e.id,i=e.groupId,n=this.getUrlWithDirectives(e.url,t),s=e.details,a=null==s?void 0:s.age;this.log(`Loading audio-track ${r} "${e.name}" lang:${e.lang} group:${i}${(null==t?void 0:t.msn)!==void 0?" at sn "+t.msn+" part "+t.part:""}${a&&s.live?" age "+a.toFixed(1)+(s.type?" "+s.type:""):""} ${n}`),this.hls.trigger(o.AUDIO_TRACK_LOADING,{url:n,id:r,groupId:i,deliveryDirectives:t||null,track:e})}},emeController:nO,cmcdController:class{constructor(e){this.hls=void 0,this.config=void 0,this.media=void 0,this.sid=void 0,this.cid=void 0,this.useHeaders=!1,this.includeKeys=void 0,this.initialized=!1,this.starved=!1,this.buffering=!0,this.audioBuffer=void 0,this.videoBuffer=void 0,this.onWaiting=()=>{this.initialized&&(this.starved=!0),this.buffering=!0},this.onPlaying=()=>{this.initialized||(this.initialized=!0),this.buffering=!1},this.applyPlaylistData=e=>{try{this.apply(e,{ot:"m",su:!this.initialized})}catch(e){this.hls.logger.warn("Could not generate manifest CMCD data.",e)}},this.applyFragmentData=e=>{try{let{frag:t,part:r}=e,i=this.hls.levels[t.level],n=this.getObjectType(t),s={d:1e3*(r||t).duration,ot:n};("v"===n||"a"===n||"av"==n)&&(s.br=i.bitrate/1e3,s.tb=this.getTopBandwidth(n)/1e3,s.bl=this.getBufferLength(n));let a=r?this.getNextPart(r):this.getNextFrag(t);null!=a&&a.url&&a.url!==t.url&&(s.nor=a.url),this.apply(e,s)}catch(e){this.hls.logger.warn("Could not generate segment CMCD data.",e)}},this.hls=e;const t=this.config=e.config,{cmcd:r}=t;null!=r&&(t.pLoader=this.createPlaylistLoader(),t.fLoader=this.createFragmentLoader(),this.sid=r.sessionId||e.sessionId,this.cid=r.contentId,this.useHeaders=!0===r.useHeaders,this.includeKeys=r.includeKeys,this.registerListeners())}registerListeners(){let e=this.hls;e.on(o.MEDIA_ATTACHED,this.onMediaAttached,this),e.on(o.MEDIA_DETACHED,this.onMediaDetached,this),e.on(o.BUFFER_CREATED,this.onBufferCreated,this)}unregisterListeners(){let e=this.hls;e.off(o.MEDIA_ATTACHED,this.onMediaAttached,this),e.off(o.MEDIA_DETACHED,this.onMediaDetached,this),e.off(o.BUFFER_CREATED,this.onBufferCreated,this)}destroy(){this.unregisterListeners(),this.onMediaDetached(),this.hls=this.config=this.audioBuffer=this.videoBuffer=null,this.onWaiting=this.onPlaying=this.media=null}onMediaAttached(e,t){this.media=t.media,this.media.addEventListener("waiting",this.onWaiting),this.media.addEventListener("playing",this.onPlaying)}onMediaDetached(){this.media&&(this.media.removeEventListener("waiting",this.onWaiting),this.media.removeEventListener("playing",this.onPlaying),this.media=null)}onBufferCreated(e,t){var r,i;this.audioBuffer=null==(r=t.tracks.audio)?void 0:r.buffer,this.videoBuffer=null==(i=t.tracks.video)?void 0:i.buffer}createData(){var e;return{v:1,sf:"h",sid:this.sid,cid:this.cid,pr:null==(e=this.media)?void 0:e.playbackRate,mtp:this.hls.bandwidthEstimate/1e3}}apply(e,t={}){D(t,this.createData());let r="i"===t.ot||"v"===t.ot||"av"===t.ot;this.starved&&r&&(t.bs=!0,t.su=!0,this.starved=!1),null==t.su&&(t.su=this.buffering);let{includeKeys:i}=this;i&&(t=Object.keys(t).reduce((e,r)=>(i.includes(r)&&(e[r]=t[r]),e),{}));let n={baseUrl:e.url};if(this.useHeaders){var s;e.headers||(e.headers={}),s=e.headers,D(s,function(e,t={}){let r={};return e?Object.entries(function(e,t){let r={};if(!e)return r;let i=Object.keys(e),n=t?Object.keys(t).reduce((e,r)=>{var i;
2469return null==(i=t[r])||i.forEach(t=>e[t]=r),e},{}):{};return i.reduce((t,r)=>{var i;let s=nh[r]||n[r]||nu;return(null!=(i=t[s])?i:t[s]={})[r]=e[r],t},r)}(nk(e,t),null==t?void 0:t.customHeaderMap)).reduce((e,[t,r])=>{let i=no(r,{whitespace:!1});return i&&(e[t]=i),e},r):r}(t,n))}else e.url=function(e,t,r){let i=function(e,t={}){if(!e)return"";let r=function(e,t={}){return e?encodeURIComponent(function(e,t={}){return e?no(nk(e,t),{whitespace:!1}):""}(e,t)):""}(e,t);return`CMCD=${r}`}(t,r);if(!i)return e;if(nC.test(e))return e.replace(nC,i);let n=e.includes("?")?"&":"?";return`${e}${n}${i}`}(e.url,t,n)}getNextFrag(e){var t;let r=null==(t=this.hls.levels[e.level])?void 0:t.details;if(r){let t=e.sn-r.startSN;return r.fragments[t+1]}}getNextPart(e){var t;let{index:r,fragment:i}=e,n=null==(t=this.hls.levels[i.level])||null==(t=t.details)?void 0:t.partList;if(n){let{sn:e}=i;for(let t=n.length-1;t>=0;t--){let i=n[t];if(i.index===r&&i.fragment.sn===e)return n[t+1]}}}getObjectType(e){let{type:t}=e;return"subtitle"===t?"tt":"initSegment"===e.sn?"i":"audio"===t?"a":"main"===t?this.hls.audioTracks.length?"v":"av":void 0}getTopBandwidth(e){let t,r=0,i=this.hls;if("a"===e)t=i.audioTracks;else{let e=i.maxAutoLevel,r=e>-1?e+1:i.levels.length;t=i.levels.slice(0,r)}return t.forEach(e=>{e.bitrate>r&&(r=e.bitrate)}),r>0?r:NaN}getBufferLength(e){let t=this.media,r="a"===e?this.audioBuffer:this.videoBuffer;return r&&t?1e3*tx.bufferInfo(r,t.currentTime,this.config.maxBufferHole).len:NaN}createPlaylistLoader(){let{pLoader:e}=this.config,t=this.applyPlaylistData,r=e||this.config.loader;return class{constructor(e){this.loader=void 0,this.loader=new r(e)}get stats(){return this.loader.stats}get context(){return this.loader.context}destroy(){this.loader.destroy()}abort(){this.loader.abort()}load(e,r,i){t(e),this.loader.load(e,r,i)}}}createFragmentLoader(){let{fLoader:e}=this.config,t=this.applyFragmentData,r=e||this.config.loader;return class{constructor(e){this.loader=void 0,this.loader=new r(e)}get stats(){return this.loader.stats}get context(){return this.loader.context}destroy(){this.loader.destroy()}abort(){this.loader.abort()}load(e,r,i){t(e),this.loader.load(e,r,i)}}}},contentSteeringController:class extends P{constructor(e){super("content-steering",e.logger),this.hls=void 0,this.loader=null,this.uri=null,this.pathwayId=".",this._pathwayPriority=null,this.timeToLoad=300,this.reloadTimer=-1,this.updated=0,this.started=!1,this.enabled=!0,this.levels=null,this.audioTracks=null,this.subtitleTracks=null,this.penalizedPathways={},this.hls=e,this.registerListeners()}registerListeners(){let e=this.hls;e.on(o.MANIFEST_LOADING,this.onManifestLoading,this),e.on(o.MANIFEST_LOADED,this.onManifestLoaded,this),e.on(o.MANIFEST_PARSED,this.onManifestParsed,this),e.on(o.ERROR,this.onError,this)}unregisterListeners(){let e=this.hls;e&&(e.off(o.MANIFEST_LOADING,this.onManifestLoading,this),e.off(o.MANIFEST_LOADED,this.onManifestLoaded,this),e.off(o.MANIFEST_PARSED,this.onManifestParsed,this),e.off(o.ERROR,this.onError,this))}pathways(){return(this.levels||[]).reduce((e,t)=>(-1===e.indexOf(t.pathwayId)&&e.push(t.pathwayId),e),[])}get pathwayPriority(){return this._pathwayPriority}set pathwayPriority(e){this.updatePathwayPriority(e)}startLoad(){if(this.started=!0,this.clearTimeout(),this.enabled&&this.uri){if(this.updated){let e=1e3*this.timeToLoad-(performance.now()-this.updated);if(e>0)return void this.scheduleRefresh(this.uri,e)}this.loadSteeringManifest(this.uri)}}stopLoad(){this.started=!1,this.loader&&(this.loader.destroy(),this.loader=null),this.clearTimeout()}clearTimeout(){-1!==this.reloadTimer&&(self.clearTimeout(this.reloadTimer),this.reloadTimer=-1)}destroy(){this.unregisterListeners(),this.stopLoad(),this.hls=null,this.levels=this.audioTracks=this.subtitleTracks=null}removeLevel(e){let t=this.levels;t&&(this.levels=t.filter(t=>t!==e))}onManifestLoading(){this.stopLoad(),this.enabled=!0,this.timeToLoad=300,this.updated=0,this.uri=null,this.pathwayId=".",this.levels=this.audioTracks=this.subtitleTracks=null}onManifestLoaded(e,t){let{contentSteering:r}=t;null!==r&&(this.pathwayId=r.pathwayId,this.uri=r.uri,this.started&&this.startLoad())}onManifestParsed(e,t){this.audioTracks=t.audioTracks,this.subtitleTracks=t.subtitleTracks}onError(e,t){let{errorAction:r}=t;if((null==r?void 0:r.action)===2&&1===r.flags){let e=this.levels,i=this._pathwayPriority,n=this.pathwayId;if(t.context){let{groupId:r,pathwayId:i,type:s}=t.context;r&&e?n=this.getPathwayForGroupId(r,s,n):i&&(n=i)}n in this.penalizedPathways||(this.penalizedPathways[n]=performance.now()),!i&&e&&(i=this.pathways()),i&&i.length>1&&(this.updatePathwayPriority(i),r.resolved=this.pathwayId!==n),t.details!==a.BUFFER_APPEND_ERROR||t.fatal?r.resolved||this.warn(`Could not resolve ${t.details} ("${t.error.message}") with content-steering for Pathway: ${n} levels: ${e?e.length:e} priorities: ${ez(i)} penalized: ${ez(this.penalizedPathways)}`):r.resolved=!0}}filterParsedLevels(e){this.levels=e;let t=this.getLevelsForPathway(this.pathwayId);if(0===t.length){let r=e[0].pathwayId;this.log(`No levels found in Pathway ${this.pathwayId}. Setting initial Pathway to "${r}"`),t=this.getLevelsForPathway(r),this.pathwayId=r}return t.length!==e.length&&this.log(`Found ${t.length}/${e.length} levels in Pathway "${this.pathwayId}"`),t}getLevelsForPathway(e){return null===this.levels?[]:this.levels.filter(t=>e===t.pathwayId)}updatePathwayPriority(e){let t;this._pathwayPriority=e;let r=this.penalizedPathways,i=performance.now();
2469Object.keys(r).forEach(e=>{i-r[e]>3e5&&delete r[e]});for(let i=0;i<e.length;i++){let n=e[i];if(n in r)continue;if(n===this.pathwayId)return;let s=this.hls.nextLoadLevel,a=this.hls.levels[s];if((t=this.getLevelsForPathway(n)).length>0){this.log(`Setting Pathway to "${n}"`),this.pathwayId=n,rv(t),this.hls.trigger(o.LEVELS_UPDATED,{levels:t});let e=this.hls.levels[s];a&&e&&this.levels&&(e.attrs["STABLE-VARIANT-ID"]!==a.attrs["STABLE-VARIANT-ID"]&&e.bitrate!==a.bitrate&&this.log(`Unstable Pathways change from bitrate ${a.bitrate} to ${e.bitrate}`),this.hls.nextLoadLevel=s);break}}}getPathwayForGroupId(e,t,r){let i=this.getLevelsForPathway(r).concat(this.levels||[]);for(let r=0;r<i.length;r++)if(t===T&&i[r].hasAudioGroup(e)||t===w&&i[r].hasSubtitleGroup(e))return i[r].pathwayId;return r}clonePathways(e){let t=this.levels;if(!t)return;let r={},i={};e.forEach(e=>{let{ID:n,"BASE-ID":s,"URI-REPLACEMENT":a}=e;if(t.some(e=>e.pathwayId===n))return;let o=this.getLevelsForPathway(s).map(e=>{let t=new tk(e.attrs);t["PATHWAY-ID"]=n;let s=t.AUDIO&&`${t.AUDIO}_clone_${n}`,o=t.SUBTITLES&&`${t.SUBTITLES}_clone_${n}`;s&&(r[t.AUDIO]=s,t.AUDIO=s),o&&(i[t.SUBTITLES]=o,t.SUBTITLES=o);let l=nL(e.uri,t["STABLE-VARIANT-ID"],"PER-VARIANT-URIS",a),u=new eq({attrs:t,audioCodec:e.audioCodec,bitrate:e.bitrate,height:e.height,name:e.name,url:l,videoCodec:e.videoCodec,width:e.width});if(e.audioGroups)for(let t=1;t<e.audioGroups.length;t++)u.addGroupId("audio",`${e.audioGroups[t]}_clone_${n}`);if(e.subtitleGroups)for(let t=1;t<e.subtitleGroups.length;t++)u.addGroupId("text",`${e.subtitleGroups[t]}_clone_${n}`);return u});t.push(...o),nD(this.audioTracks,r,a,n),nD(this.subtitleTracks,i,a,n)})}loadSteeringManifest(e){let t,r=this.hls.config,i=r.loader;this.loader&&this.loader.destroy(),this.loader=new i(r);try{t=new self.URL(e)}catch(t){this.enabled=!1,this.log(`Failed to parse Steering Manifest URI: ${e}`);return}if("data:"!==t.protocol){let e=0|(this.hls.bandwidthEstimate||r.abrEwmaDefaultEstimate);t.searchParams.set("_HLS_pathway",this.pathwayId),t.searchParams.set("_HLS_throughput",""+e)}let n={responseType:"json",url:t.href},s=r.steeringManifestLoadPolicy.default,a=s.errorRetry||s.timeoutRetry||{},l={loadPolicy:s,timeout:s.maxLoadTimeMs,maxRetry:a.maxNumRetry||0,retryDelay:a.retryDelayMs||0,maxRetryDelay:a.maxRetryDelayMs||0};this.log(`Requesting steering manifest: ${t}`),this.loader.load(n,l,{onSuccess:(e,r,i,n)=>{this.log(`Loaded steering manifest: "${t}"`);let s=e.data;if((null==s?void 0:s.VERSION)!==1)return void this.log(`Steering VERSION ${s.VERSION} not supported!`);this.updated=performance.now(),this.timeToLoad=s.TTL;let{"RELOAD-URI":a,"PATHWAY-CLONES":l,"PATHWAY-PRIORITY":u}=s;if(a)try{this.uri=new self.URL(a,t).href}catch(e){this.enabled=!1,this.log(`Failed to parse Steering Manifest RELOAD-URI: ${a}`);return}this.scheduleRefresh(this.uri||i.url),l&&this.clonePathways(l);let c={steeringManifest:s,url:t.toString()};this.hls.trigger(o.STEERING_MANIFEST_LOADED,c),u&&this.updatePathwayPriority(u)},onError:(e,t,r,i)=>{if(this.log(`Error loading steering manifest: ${e.code} ${e.text} (${t.url})`),this.stopLoad(),410===e.code){this.enabled=!1,this.log(`Steering manifest ${t.url} no longer available`);return}let n=1e3*this.timeToLoad;if(429===e.code){let e=this.loader;if("function"==typeof(null==e?void 0:e.getResponseHeader)){let t=e.getResponseHeader("Retry-After");t&&(n=1e3*parseFloat(t))}this.log(`Steering manifest ${t.url} rate limited`);return}this.scheduleRefresh(this.uri||t.url,n)},onTimeout:(e,t,r)=>{this.log(`Timeout loading steering manifest (${t.url})`),this.scheduleRefresh(this.uri||t.url)}})}scheduleRefresh(e,t=1e3*this.timeToLoad){this.clearTimeout(),this.reloadTimer=self.setTimeout(()=>{var t;let r=null==(t=this.hls)?void 0:t.media;r&&!r.ended?this.loadSteeringManifest(e):this.scheduleRefresh(e,1e3*this.timeToLoad)},t)}},interstitialsController:class extends P{constructor(e,t){super("interstitials",e.logger),this.HlsPlayerClass=void 0,this.hls=void 0,this.assetListLoader=void 0,this.mediaSelection=null,this.altSelection=null,this.media=null,this.detachedData=null,this.requiredTracks=null,this.manager=null,this.playerQueue=[],this.bufferedPos=-1,this.timelinePos=-1,this.schedule=void 0,this.playingItem=null,this.bufferingItem=null,this.waitingItem=null,this.endedItem=null,this.playingAsset=null,this.endedAsset=null,this.bufferingAsset=null,this.shouldPlay=!1,this.onPlay=()=>{this.shouldPlay=!0},this.onPause=()=>{this.shouldPlay=!1}
2469,this.onSeeking=()=>{var e,t;let r=this.currentTime;if(void 0===r||this.playbackDisabled||!this.schedule)return;let i=r-this.timelinePos;if(Math.abs(i)<1/7056e5)return;let n=i<=-.01;-1!==this.timelinePos||this.effectivePlayingItem||this.checkStart(),this.timelinePos=r,this.bufferedPos=r;let s=this.playingItem;if(!s)return void this.checkBuffer();if(n&&this.schedule.resetErrorsInRange(r,r-i)&&this.updateSchedule(!0),this.checkBuffer(),n&&r<s.start||r>=s.end){let t=this.findItemIndex(s),i=this.schedule.findItemIndexAtTime(r);if(-1===i&&(i=t+(n?-1:1),this.log(`seeked ${n?"back ":""}to position not covered by schedule ${r} (resolving from ${t} to ${i})`)),!this.isInterstitial(s)&&null!=(e=this.media)&&e.paused&&(this.shouldPlay=!1),!n&&i>t){let e=this.schedule.findJumpRestrictedIndex(t+1,i);if(e>t)return void this.setSchedulePosition(e)}this.setSchedulePosition(i);return}let a=this.playingAsset;if(!a){if(this.playingLastItem&&this.isInterstitial(s)){let e=s.event.assetList[0];e&&(this.endedItem=this.playingItem,this.playingItem=null,this.setScheduleToAssetAtTime(r,e))}return}let o=a.timelineStart,l=a.duration||0;(n&&r<o||r>=o+l)&&(null!=(t=s.event)&&t.appendInPlace&&(this.clearAssetPlayers(s.event,s),this.flushFrontBuffer(r)),this.setScheduleToAssetAtTime(r,a))},this.onTimeupdate=()=>{let e=this.currentTime;if(void 0===e||this.playbackDisabled||(-1!==this.timelinePos||this.effectivePlayingItem||this.checkStart(),!(e>this.timelinePos)))return;this.timelinePos=e,e>this.bufferedPos&&this.checkBuffer();let t=this.playingItem;if(!t||this.playingLastItem)return;if(e>=t.end){this.timelinePos=t.end;let e=this.findItemIndex(t);this.setSchedulePosition(e+1)}let r=this.playingAsset;!r||e>=r.timelineStart+(r.duration||0)&&this.setScheduleToAssetAtTime(e,r)},this.onScheduleUpdate=(e,t)=>{let r=this.schedule;if(!r)return;let i=this.playingItem,n=r.events||[],s=r.items||[],a=r.durations,l=e.map(e=>e.identifier),u=!!(n.length||l.length);(u||t)&&this.log(`INTERSTITIALS_UPDATED (${n.length}): ${n} 2470Schedule: ${s.map(e=>nX(e))} pos: ${this.timelinePos}`),l.length&&this.log(`Removed events ${l}`);let c=null,d=null;i&&(c=this.updateItem(i,this.timelinePos),this.itemsMatch(i,c)?this.playingItem=c:this.waitingItem=this.endedItem=null),this.waitingItem=this.updateItem(this.waitingItem),this.endedItem=this.updateItem(this.endedItem);let h=this.bufferingItem;if(h&&(d=this.updateItem(h,this.bufferedPos),this.itemsMatch(h,d)?this.bufferingItem=d:h.event&&(this.bufferingItem=this.playingItem,this.clearInterstitial(h.event,null))),e.forEach(e=>{e.assetList.forEach(e=>{this.clearAssetPlayer(e.identifier,null)})}),this.playerQueue.forEach(e=>{if(e.interstitial.appendInPlace){let t=e.assetItem.timelineStart,r=e.timelineOffset-t;if(r)try{e.timelineOffset=t}catch(i){Math.abs(r)>.025&&this.warn(`${i} ("${e.assetId}" ${e.timelineOffset}->${t})`)}}}),u||t){if(this.hls.trigger(o.INTERSTITIALS_UPDATED,{events:n.slice(0),schedule:s.slice(0),durations:a,removedIds:l}),this.isInterstitial(i)&&l.includes(i.event.identifier)){this.warn(`Interstitial "${i.event.identifier}" removed while playing`),this.primaryFallback(i.event);return}i&&this.trimInPlace(c,i),h&&d!==c&&this.trimInPlace(d,h),this.checkBuffer()}},this.hls=e,this.HlsPlayerClass=t,this.assetListLoader=new nJ(e),this.schedule=new nQ(this.onScheduleUpdate,e.logger),this.registerListeners()}registerListeners(){let e=this.hls;e&&(e.on(o.MEDIA_ATTACHING,this.onMediaAttaching,this),e.on(o.MEDIA_ATTACHED,this.onMediaAttached,this),e.on(o.MEDIA_DETACHING,this.onMediaDetaching,this),e.on(o.MANIFEST_LOADING,this.onManifestLoading,this),e.on(o.LEVEL_UPDATED,this.onLevelUpdated,this),e.on(o.AUDIO_TRACK_SWITCHING,this.onAudioTrackSwitching,this),e.on(o.AUDIO_TRACK_UPDATED,this.onAudioTrackUpdated,this),e.on(o.SUBTITLE_TRACK_SWITCH,this.onSubtitleTrackSwitch,this),e.on(o.SUBTITLE_TRACK_UPDATED,this.onSubtitleTrackUpdated,this),e.on(o.EVENT_CUE_ENTER,this.onInterstitialCueEnter,this),e.on(o.ASSET_LIST_LOADED,this.onAssetListLoaded,this),e.on(o.BUFFER_APPENDED,this.onBufferAppended,this),e.on(o.BUFFER_FLUSHED,this.onBufferFlushed,this),e.on(o.BUFFERED_TO_END,this.onBufferedToEnd,this),e.on(o.MEDIA_ENDED,this.onMediaEnded,this),e.on(o.ERROR,this.onError,this),e.on(o.DESTROYING,this.onDestroying,this))}unregisterListeners(){let e=this.hls;
2470e&&(e.off(o.MEDIA_ATTACHING,this.onMediaAttaching,this),e.off(o.MEDIA_ATTACHED,this.onMediaAttached,this),e.off(o.MEDIA_DETACHING,this.onMediaDetaching,this),e.off(o.MANIFEST_LOADING,this.onManifestLoading,this),e.off(o.LEVEL_UPDATED,this.onLevelUpdated,this),e.off(o.AUDIO_TRACK_SWITCHING,this.onAudioTrackSwitching,this),e.off(o.AUDIO_TRACK_UPDATED,this.onAudioTrackUpdated,this),e.off(o.SUBTITLE_TRACK_SWITCH,this.onSubtitleTrackSwitch,this),e.off(o.SUBTITLE_TRACK_UPDATED,this.onSubtitleTrackUpdated,this),e.off(o.EVENT_CUE_ENTER,this.onInterstitialCueEnter,this),e.off(o.ASSET_LIST_LOADED,this.onAssetListLoaded,this),e.off(o.BUFFER_CODECS,this.onBufferCodecs,this),e.off(o.BUFFER_APPENDED,this.onBufferAppended,this),e.off(o.BUFFER_FLUSHED,this.onBufferFlushed,this),e.off(o.BUFFERED_TO_END,this.onBufferedToEnd,this),e.off(o.MEDIA_ENDED,this.onMediaEnded,this),e.off(o.ERROR,this.onError,this),e.off(o.DESTROYING,this.onDestroying,this))}startLoad(){this.resumeBuffering()}stopLoad(){this.pauseBuffering()}resumeBuffering(){var e;null==(e=this.getBufferingPlayer())||e.resumeBuffering()}pauseBuffering(){var e;null==(e=this.getBufferingPlayer())||e.pauseBuffering()}destroy(){this.unregisterListeners(),this.stopLoad(),this.assetListLoader&&this.assetListLoader.destroy(),this.emptyPlayerQueue(),this.clearScheduleState(),this.schedule&&this.schedule.destroy(),this.media=this.detachedData=this.mediaSelection=this.requiredTracks=this.altSelection=this.schedule=this.manager=null,this.hls=this.HlsPlayerClass=this.log=null,this.assetListLoader=null,this.onPlay=this.onPause=this.onSeeking=this.onTimeupdate=null,this.onScheduleUpdate=null}onDestroying(){let e=this.primaryMedia||this.media;e&&this.removeMediaListeners(e)}removeMediaListeners(e){rA(e,"play",this.onPlay),rA(e,"pause",this.onPause),rA(e,"seeking",this.onSeeking),rA(e,"timeupdate",this.onTimeupdate)}onMediaAttaching(e,t){let r=this.media=t.media;rw(r,"seeking",this.onSeeking),rw(r,"timeupdate",this.onTimeupdate),rw(r,"play",this.onPlay),rw(r,"pause",this.onPause)}onMediaAttached(e,t){let r=this.effectivePlayingItem,i=this.detachedData;if(this.detachedData=null,null===r)this.checkStart();else if(!i){this.clearScheduleState();let e=this.findItemIndex(r);this.setSchedulePosition(e)}}clearScheduleState(){this.log("clear schedule state"),this.playingItem=this.bufferingItem=this.waitingItem=this.endedItem=this.playingAsset=this.endedAsset=this.bufferingAsset=null}onMediaDetaching(e,t){let r=!!t.transferMedia,i=this.media;if(this.media=null,!r&&(i&&this.removeMediaListeners(i),this.detachedData)){let e=this.getBufferingPlayer();e&&(this.log(`Removing schedule state for detachedData and ${e}`),this.playingAsset=this.endedAsset=this.bufferingAsset=this.bufferingItem=this.waitingItem=this.detachedData=null,e.detachMedia()),this.shouldPlay=!1}}get interstitialsManager(){if(!this.hls)return null;if(this.manager)return this.manager;let e=this,t=t=>t?e.getAssetPlayer(t.identifier):t,r=(r,n,s,a,o)=>{if(r){let l=r[n].start,u=r.event;if(u){if("playout"===n||u.timelineOccupancy!==nG.Point){let e=t(s);(null==e?void 0:e.interstitial)===u&&(l+=e.assetItem.startOffset+e[o])}}else l+=("bufferedPos"===a?i():e[a])-r.start;return l}return 0},i=()=>{let t=e.bufferedPos;return t===Number.MAX_VALUE?n("primary"):Math.max(t,0)},n=t=>{var r,i;return null!=(r=e.primaryDetails)&&r.live?e.primaryDetails.edge:(null==(i=e.schedule)?void 0:i.durations[t])||0},s=(i,n)=>{var s,a;let o=e.effectivePlayingItem;if(null!=o&&null!=(s=o.event)&&s.restrictions.skip||!e.schedule)return;e.log(`seek to ${i} "${n}"`);let l=e.effectivePlayingItem,u=e.schedule.findItemIndexAtTime(i,n),c=null==(a=e.schedule.items)?void 0:a[u],d=e.getBufferingPlayer(),h=null==d?void 0:d.interstitial,f=null==h?void 0:h.appendInPlace,p=l&&e.itemsMatch(l,c);if(l&&(f||p)){let s=t(e.playingAsset),a=(null==s?void 0:s.media)||e.primaryMedia;if(a){let t="primary"===n?a.currentTime:r(l,n,e.playingAsset,"timelinePos","currentTime"),o=i-t,u=(f?t:a.currentTime)+o;if(u>=0&&(!s||f||u<=s.duration)){a.currentTime=u;return}}}if(c){let t=i;if("primary"!==n){let e=i-c[n].start;t=c.start+e}let r=!e.isInterstitial(c);if((!e.isInterstitial(l)||l.event.appendInPlace)&&(r||c.event.appendInPlace)){let r=e.media||(f?null==d?void 0:d.media:null);r&&(r.currentTime=t)}else if(l){let s=e.findItemIndex(l);if(u>s){let t=e.schedule.findJumpRestrictedIndex(s+1,u);if(t>s)return void e.setSchedulePosition(t)}let a=0;if(r)e.timelinePos=t,e.checkBuffer();else{let e=c.event.assetList,t=i-(c[n]||c).start;for(let r=e.length;r--;){let i=e[r];if(i.duration&&t>=i.startOffset&&t<i.startOffset+i.duration){a=r;break}}}e.setSchedulePosition(u,a)}}},a=()=>{let t=e.effectivePlayingItem;if(e.isInterstitial(t))return t;let r=e.bufferingItem||e.waitingItem;return e.isInterstitial(r)?r:null},o={get bufferedEnd(){let t=e.bufferingItem||e.waitingItem,i=e.bufferingItem;if(i&&i===t){var l;return r(i,"playout",e.bufferingAsset,"bufferedPos","bufferedEnd")-i.playout.start||(null==(l=e.bufferingAsset)?void 0:l.startOffset)||0}return 0},get currentTime(){let t=a(),i=e.effectivePlayingItem;if(i&&i===t)return r(i,"playout",e.effectivePlayingAsset,"timelinePos","currentTime")-i.playout.start;return 0},set currentTime(time){let t=a(),r=e.effectivePlayingItem;r&&r===t&&s(time+r.playout.start,"playout")},get duration(){let e=a();if(e)return e.playout.end-e.playout.start;return 0},get assetPlayers(){var u;let t=null==(u=a())?void 0:u.event.assetList;if(t)return t.map(t=>e.getAssetPlayer(t.identifier));return[]},get playingIndex(){var c;let t=null==(c=a())?void 0:c.event;if(t&&e.effectivePlayingAsset)return t.findAssetIndex(e.effectivePlayingAsset);return -1},get scheduleItem(){return a()}};return this.manager={get events(){var d;
2470return(null==(d=e.schedule)||null==(d=d.events)?void 0:d.slice(0))||[]},get schedule(){var h;return(null==(h=e.schedule)||null==(h=h.items)?void 0:h.slice(0))||[]},get interstitialPlayer(){if(a())return o;return null},get playerQueue(){return e.playerQueue.slice(0)},get bufferingAsset(){return e.bufferingAsset},get bufferingItem(){return e.bufferingItem||e.waitingItem},get bufferingIndex(){let t=e.bufferingItem||e.waitingItem;return e.findItemIndex(t)},get playingAsset(){return e.effectivePlayingAsset},get playingItem(){return e.effectivePlayingItem},get playingIndex(){let t=e.effectivePlayingItem;return e.findItemIndex(t)},primary:{get bufferedEnd(){return i()},get currentTime(){let t=e.timelinePos;return t>0?t:0},set currentTime(time){s(time,"primary")},get duration(){return n("primary")},get seekableStart(){var f;return(null==(f=e.primaryDetails)?void 0:f.fragmentStart)||0}},integrated:{get bufferedEnd(){return r(e.bufferingItem||e.waitingItem,"integrated",e.bufferingAsset,"bufferedPos","bufferedEnd")},get currentTime(){return r(e.effectivePlayingItem,"integrated",e.effectivePlayingAsset,"timelinePos","currentTime")},set currentTime(time){s(time,"integrated")},get duration(){return n("integrated")},get seekableStart(){var p;return((t,r)=>{var i,n;if(0!==t&&"primary"!==r&&null!=(i=e.schedule)&&i.length){let i=e.schedule.findItemIndexAtTime(t),s=null==(n=e.schedule.items)?void 0:n[i];if(s)return t+(s[r].start-s.start)}return t})((null==(p=e.primaryDetails)?void 0:p.fragmentStart)||0,"integrated")}},skip:()=>{let t=e.effectivePlayingItem,r=null==t?void 0:t.event;if(r&&!r.restrictions.skip){let i=e.findItemIndex(t);r.appendInPlace?s(t.playout.start+t.event.duration+.001,"playout"):e.advanceAfterAssetEnded(r,i,1/0)}}}}get effectivePlayingItem(){return this.waitingItem||this.playingItem||this.endedItem}get effectivePlayingAsset(){return this.playingAsset||this.endedAsset}get playingLastItem(){var e;let t=this.playingItem,r=null==(e=this.schedule)?void 0:e.items;return!!this.playbackStarted&&!!t&&!!r&&this.findItemIndex(t)===r.length-1}get playbackStarted(){return null!==this.effectivePlayingItem}get currentTime(){var e,t;if(null===this.mediaSelection)return;let i=this.waitingItem||this.playingItem;if(this.isInterstitial(i)&&!i.event.appendInPlace)return;let n=this.media;!n&&null!=(e=this.bufferingItem)&&null!=(e=e.event)&&e.appendInPlace&&(n=this.primaryMedia);let s=null==(t=n)?void 0:t.currentTime;if(void 0!==s&&r(s))return s}get primaryMedia(){var e;return this.media||(null==(e=this.detachedData)?void 0:e.media)||null}isInterstitial(e){return!!(null!=e&&e.event)}retreiveMediaSource(e,t){let r=this.getAssetPlayer(e);r&&this.transferMediaFromPlayer(r,t)}transferMediaFromPlayer(e,t){let r=e.interstitial.appendInPlace,i=e.media;if(r&&i===this.primaryMedia){if(this.bufferingAsset=null,(!t||this.isInterstitial(t)&&!t.event.appendInPlace)&&t&&i){this.detachedData={media:i};return}let r=e.transferMedia();this.log(`transfer MediaSource from ${e} ${ez(r)}`),this.detachedData=r}else t&&i&&(this.shouldPlay||(this.shouldPlay=!i.paused))}transferMediaTo(e,t){var r,i;let n;if(e.media===t)return;let s=null,a=this.hls,o=e!==a,l=o&&e.interstitial.appendInPlace,u=null==(r=this.detachedData)?void 0:r.mediaSource;if(a.media)l&&(s=a.transferMedia(),this.detachedData=s),n="Primary";else if(u){let e=this.getBufferingPlayer();e?(s=e.transferMedia(),n=`${e}`):n="detached MediaSource"}else n="detached media";if(!s){if(u)s=this.detachedData,this.log(`using detachedData: MediaSource ${ez(s)}`);else if(!this.detachedData||a.media===t){let e=this.playerQueue;e.length>1&&e.forEach(e=>{if(o&&e.interstitial.appendInPlace!==l){let t=e.interstitial;this.clearInterstitial(e.interstitial,null),t.appendInPlace=!1,t.appendInPlace&&this.warn(`Could not change append strategy for queued assets ${t}`)}}),this.hls.detachMedia(),this.detachedData={media:t}}}let c=s&&"mediaSource"in s&&(null==(i=s.mediaSource)?void 0:i.readyState)!=="closed",d=c&&s?s:t;this.log(`${c?"transfering MediaSource":"attaching media"} to ${o?e:"Primary"} from ${n} (media.currentTime: ${t.currentTime})`);let h=this.schedule;
2470if(d===s&&h){let t=o&&e.assetId===h.assetIdAtEnd;d.overrides={duration:h.duration,endOfStream:!o||t,cueRemoval:!o}}e.attachMedia(d)}onInterstitialCueEnter(){this.onTimeupdate()}checkStart(){let e=this.schedule,t=null==e?void 0:e.events;if(!t||this.playbackDisabled||!this.media)return;-1===this.bufferedPos&&(this.bufferedPos=0);let r=this.timelinePos,i=this.effectivePlayingItem;if(-1===r){let r=this.hls.startPosition;if(this.timelinePos=r,0===t.length)this.setSchedulePosition(0);else if(t[0].cue.pre){this.log(n0("checkStart (preroll)",r));let i=e.findEventIndex(t[0].identifier);this.setSchedulePosition(i)}else if(r>=0||!this.primaryLive){this.log(n0("checkStart",r));let t=this.timelinePos=r>0?r:0,i=e.findItemIndexAtTime(t);this.setSchedulePosition(i)}else 0===this.hls.liveSyncPosition?this.setSchedulePosition(0):this.log("[checkStart] waiting for live start")}else if(i&&!this.playingItem){this.log(n0("checkStart (playing item)",i.start));let t=e.findItemIndex(i);this.setSchedulePosition(t)}}advanceAssetBuffering(e,t){let r=e.event,i=r.findAssetIndex(t),n=nK(r,i);if(r.isAssetPastPlayoutLimit(n)){if(this.schedule){var s;let t=null==(s=this.schedule.items)?void 0:s[this.findItemIndex(e)+1];t&&this.bufferedToItem(t)}}else this.bufferedToEvent(e,n)}advanceAfterAssetEnded(e,t,r){let i=nK(e,r);if(e.isAssetPastPlayoutLimit(i)){if(this.schedule){let r=this.schedule.items;if(r){let i=t+1;if(i>=r.length)return void this.setSchedulePosition(-1);let n=e.resumeTime;this.timelinePos<n&&(this.log(n0("advanceAfterAssetEnded",n)),this.timelinePos=n,e.appendInPlace&&this.advanceInPlace(n),this.checkBuffer(this.bufferedPos<n)),this.setSchedulePosition(i)}}}else{if(e.appendInPlace){let t=e.assetList[i];t&&this.advanceInPlace(t.timelineStart)}this.setSchedulePosition(t,i)}}setScheduleToAssetAtTime(e,t){let r=this.schedule;if(!r)return;let i=t.parentIdentifier,n=r.getEvent(i);if(n){let t=r.findEventIndex(i),s=r.findAssetIndex(n,e);this.advanceAfterAssetEnded(n,t,s-1)}}setSchedulePosition(e,t){var r,i,n;let s=null==(r=this.schedule)?void 0:r.items;if(!s||this.playbackDisabled)return;let a=e>=0?s[e]:null;this.log(`setSchedulePosition ${e}, ${t} (${a?nX(a):a}) pos: ${this.timelinePos}`);let l=this.waitingItem||this.playingItem,u=this.playingLastItem;if(this.isInterstitial(l)){let r=l.event,c=this.playingAsset,d=null==c?void 0:c.identifier,h=d?this.getAssetPlayer(d):null;if(h&&d&&(!this.eventItemsMatch(l,a)||void 0!==t&&d!==r.assetList[t].identifier)){let t=r.findAssetIndex(c);if(this.log(`INTERSTITIAL_ASSET_ENDED ${t+1}/${r.assetList.length} ${nW(c)}`),this.endedAsset=c,this.playingAsset=null,this.hls.trigger(o.INTERSTITIAL_ASSET_ENDED,{asset:c,assetListIndex:t,event:r,schedule:s.slice(0),scheduleIndex:e,player:h}),l!==this.playingItem){this.itemsMatch(l,this.playingItem)&&!this.playingAsset&&this.advanceAfterAssetEnded(r,this.findItemIndex(this.playingItem),t);return}this.retreiveMediaSource(d,a),h.media&&!(null!=(i=this.detachedData)&&i.mediaSource)&&h.detachMedia()}if(!this.eventItemsMatch(l,a)&&(this.endedItem=l,this.playingItem=null,this.log(`INTERSTITIAL_ENDED ${r} ${nX(l)}`),r.hasPlayed=!0,this.hls.trigger(o.INTERSTITIAL_ENDED,{event:r,schedule:s.slice(0),scheduleIndex:e}),r.cue.once)){this.updateSchedule();let e=null==(n=this.schedule)?void 0:n.items;if(a&&e){let r=this.findItemIndex(a);this.advanceSchedule(r,e,t,l,u)}return}}this.advanceSchedule(e,s,t,l,u)}advanceSchedule(e,t,r,i,n){let s=this.schedule;if(!s)return;let a=t[e]||null,l=this.primaryMedia,u=this.playerQueue;if(u.length&&u.forEach(t=>{let r=t.interstitial,i=s.findEventIndex(r.identifier);(i<e||i>e+1)&&this.clearInterstitial(r,a)}),this.isInterstitial(a)){this.timelinePos=Math.min(Math.max(this.timelinePos,a.start),a.end);let n=a.event;if(void 0===r){r=s.findAssetIndex(n,this.timelinePos);let t=nK(n,r-1);if(n.isAssetPastPlayoutLimit(t)||n.appendInPlace&&this.timelinePos===a.end)return void this.advanceAfterAssetEnded(n,e,r);r=t}let u=this.waitingItem;this.assetsBuffered(a,l)||this.setBufferingItem(a);let c=this.preloadAssets(n,r);if(this.eventItemsMatch(a,u||i)||(this.waitingItem=a,this.log(`INTERSTITIAL_STARTED ${nX(a)} ${n.appendInPlace?"append in place":""}`),this.hls.trigger(o.INTERSTITIAL_STARTED,{event:n,schedule:t.slice(0),scheduleIndex:e})),!n.assetListLoaded)return void this.log(`Waiting for ASSET-LIST to complete loading ${n}`);if(n.assetListLoader&&(n.assetListLoader.destroy(),n.assetListLoader=void 0),!l)return void this.log(`Waiting for attachMedia to start Interstitial ${n}`);this.waitingItem=this.endedItem=null,this.playingItem=a;let d=n.assetList[r];if(!d)return void this.advanceAfterAssetEnded(n,e,r||0);if(c||(c=this.getAssetPlayer(d.identifier)),null===c||c.destroyed){let e=n.assetList.length;this.warn(`asset ${r+1}/${e} player destroyed ${n}
2470`),(c=this.createAssetPlayer(n,d,r)).loadSource()}if(!this.eventItemsMatch(a,this.bufferingItem)&&n.appendInPlace&&this.isAssetBuffered(d))return;this.startAssetPlayer(c,r,t,e,l),this.shouldPlay&&nZ(c.media)}else a?(this.resumePrimary(a,e,i),this.shouldPlay&&nZ(this.hls.media)):n&&this.isInterstitial(i)&&(this.endedItem=null,this.playingItem=i,i.event.appendInPlace||this.attachPrimary(s.durations.primary,null))}get playbackDisabled(){return!1===this.hls.config.enableInterstitialPlayback}get primaryDetails(){var e;return null==(e=this.mediaSelection)?void 0:e.main.details}get primaryLive(){var e;return!!(null!=(e=this.primaryDetails)&&e.live)}resumePrimary(e,t,r){var i,n;if(this.playingItem=e,this.playingAsset=this.endedAsset=null,this.waitingItem=this.endedItem=null,this.bufferedToItem(e),this.log(`resuming ${nX(e)}`),!(null!=(i=this.detachedData)&&i.mediaSource)){let r=this.timelinePos;(r<e.start||r>=e.end)&&(r=this.getPrimaryResumption(e,t),this.log(n0("resumePrimary",r)),this.timelinePos=r),this.attachPrimary(r,e)}if(!r)return;let s=null==(n=this.schedule)?void 0:n.items;s&&(this.log(`INTERSTITIALS_PRIMARY_RESUMED ${nX(e)}`),this.hls.trigger(o.INTERSTITIALS_PRIMARY_RESUMED,{schedule:s.slice(0),scheduleIndex:t}),this.checkBuffer())}getPrimaryResumption(e,t){let r=e.start;if(this.primaryLive){let e=this.primaryDetails;if(0===t)return this.hls.startPosition;if(e&&(r<e.fragmentStart||r>e.edge))return this.hls.liveSyncPosition||-1}return r}isAssetBuffered(e){let t=this.getAssetPlayer(e.identifier);return null!=t&&t.hls?t.hls.bufferedToEnd:tx.bufferInfo(this.primaryMedia,this.timelinePos,0).end+1>=e.timelineStart+(e.duration||0)}attachPrimary(e,t,r){t?this.setBufferingItem(t):this.bufferingItem=this.playingItem,this.bufferingAsset=null;let i=this.primaryMedia;if(!i)return;let n=this.hls;n.media?this.checkBuffer():(this.transferMediaTo(n,i),r&&this.startLoadingPrimaryAt(e,r)),r||(this.log(n0("attachPrimary",e)),this.timelinePos=e,this.startLoadingPrimaryAt(e,r))}
2470startLoadingPrimaryAt(e,t){var r;let i=this.hls;!i.loadingEnabled||!i.media||Math.abs(((null==(r=i.mainForwardBufferInfo)?void 0:r.start)||i.media.currentTime)-e)>.5?i.startLoad(e,t):i.bufferingEnabled||i.resumeBuffering()}onManifestLoading(){var e;this.stopLoad(),null==(e=this.schedule)||e.reset(),this.emptyPlayerQueue(),this.clearScheduleState(),this.shouldPlay=!1,this.bufferedPos=this.timelinePos=-1,this.mediaSelection=this.altSelection=this.manager=this.requiredTracks=null,this.hls.off(o.BUFFER_CODECS,this.onBufferCodecs,this),this.hls.on(o.BUFFER_CODECS,this.onBufferCodecs,this)}onLevelUpdated(e,t){if(-1===t.level||!this.schedule)return;let r=this.hls.levels[t.level];if(!r.details)return;let i=O(O({},this.mediaSelection||this.altSelection),{},{main:r});this.mediaSelection=i,this.schedule.parseInterstitialDateRanges(i,this.hls.config.interstitialAppendInPlace),!this.effectivePlayingItem&&this.schedule.items&&this.checkStart()}onAudioTrackUpdated(e,t){let r=this.hls.audioTracks[t.id],i=this.mediaSelection;if(!i){this.altSelection=O(O({},this.altSelection),{},{audio:r});return}let n=O(O({},i),{},{audio:r});this.mediaSelection=n}onSubtitleTrackUpdated(e,t){let r=this.hls.subtitleTracks[t.id],i=this.mediaSelection;if(!i){this.altSelection=O(O({},this.altSelection),{},{subtitles:r});return}let n=O(O({},i),{},{subtitles:r});this.mediaSelection=n}onAudioTrackSwitching(e,t){let r=eY(t);this.playerQueue.forEach(({hls:e})=>e&&(e.setAudioOption(t)||e.setAudioOption(r)))}onSubtitleTrackSwitch(e,t){let r=eY(t);this.playerQueue.forEach(({hls:e})=>e&&(e.setSubtitleOption(t)||-1!==t.id&&e.setSubtitleOption(r)))}onBufferCodecs(e,t){let r=t.tracks;r&&(this.requiredTracks=r)}onBufferAppended(e,t){this.checkBuffer()}onBufferFlushed(e,t){let r=this.playingItem;if(r&&!this.itemsMatch(r,this.bufferingItem)&&!this.isInterstitial(r)){let e=this.timelinePos;this.bufferedPos=e,this.checkBuffer()}}onBufferedToEnd(e){if(!this.schedule)return;let t=this.schedule.events;if(this.bufferedPos<Number.MAX_VALUE&&t){for(let e=0;e<t.length;e++){let i=t[e];if(i.cue.post){var r;let e=this.schedule.findEventIndex(i.identifier),t=null==(r=this.schedule.items)?void 0:r[e];this.isInterstitial(t)&&this.eventItemsMatch(t,this.bufferingItem)&&this.bufferedToItem(t,0);break}}this.bufferedPos=Number.MAX_VALUE}}onMediaEnded(e){let t=this.playingItem;if(!this.playingLastItem&&t){let e=this.findItemIndex(t);this.setSchedulePosition(e+1)}else this.shouldPlay=!1}updateItem(e,t){var r;let i=null==(r=this.schedule)?void 0:r.items;return e&&i&&i[this.findItemIndex(e,t)]||null}trimInPlace(e,t){if(this.isInterstitial(e)&&e.event.appendInPlace&&t.end-e.end>.25){e.event.assetList.forEach((t,r)=>{e.event.isAssetPastPlayoutLimit(r)&&this.clearAssetPlayer(t.identifier,null)});let r=e.end+.25,i=tx.bufferInfo(this.primaryMedia,r,0);(i.end>r||(i.nextStart||0)>r)&&(this.log(`trim buffered interstitial ${nX(e)} (was ${nX(t)})`),this.attachPrimary(r,null,!0),this.flushFrontBuffer(r))}}itemsMatch(e,t){return!!t&&(e===t||e.event&&t.event&&this.eventItemsMatch(e,t)||!e.event&&!t.event&&this.findItemIndex(e)===this.findItemIndex(t))}eventItemsMatch(e,t){var r;return!!t&&(e===t||e.event.identifier===(null==(r=t.event)?void 0:r.identifier))}findItemIndex(e,t){return e&&this.schedule?this.schedule.findItemIndex(e,t):-1}updateSchedule(e=!1){var t;let r=this.mediaSelection;r&&(null==(t=this.schedule)||t.updateSchedule(r,[],e))}checkBuffer(e){var t;let r=null==(t=this.schedule)?void 0:t.items;if(!r)return;let i=tx.bufferInfo(this.primaryMedia,this.timelinePos,0);e&&(this.bufferedPos=this.timelinePos),e||(e=i.len<1),this.updateBufferedPos(i.end,r,e)}updateBufferedPos(e,t,r){let i=this.schedule,n=this.bufferingItem;if(this.bufferedPos>e||!i)return;if(1===t.length&&this.itemsMatch(t[0],n)){this.bufferedPos=e;return}let s=this.playingItem,a=this.findItemIndex(s),o=i.findItemIndexAtTime(e);if(this.bufferedPos<e){var l;let r=this.findItemIndex(n),i=Math.min(r+1,t.length-1),s=t[i];if((-1===o&&n&&e>=n.end||null!=(l=s.event)&&l.appendInPlace&&e+.01>=s.start)&&(o=i),this.isInterstitial(n)){let e=n.event;if(i-a>1&&!1===e.appendInPlace||0===e.assetList.length&&e.assetListLoader)return}if(this.bufferedPos=e,o>r&&o>a)this.bufferedToItem(s);else{let t=this.primaryDetails;this.primaryLive&&t&&e>t.edge-t.targetduration&&s.start<t.edge+this.hls.config.interstitialLiveLookAhead&&this.isInterstitial(s)&&this.preloadAssets(s.event,0)}}else r&&s&&!this.itemsMatch(s,n)&&(o===a?this.bufferedToItem(s):o===a+1&&this.bufferedToItem(t[o]))}assetsBuffered(e,t){return 0!==e.event.assetList.length&&!e.event.assetList.some(e=>{let r=this.getAssetPlayer(e.identifier);return!(null!=r&&r.bufferedInPlaceToEnd(t))})}setBufferingItem(e){let t=this.bufferingItem,r=this.schedule;if(!this.itemsMatch(e,t)&&r){let{items:i,events:n}=r;if(!i||!n)return t;
2470let s=this.isInterstitial(e),a=this.getBufferingPlayer();this.bufferingItem=e,this.bufferedPos=Math.max(e.start,Math.min(e.end,this.timelinePos));let l=a?a.remaining:t?t.end-this.timelinePos:0;if(this.log(`INTERSTITIALS_BUFFERED_TO_BOUNDARY ${nX(e)}`+(t?` (${l.toFixed(2)} remaining)`:"")),!this.playbackDisabled)if(s){let t=r.findAssetIndex(e.event,this.bufferedPos);e.event.assetList.forEach((e,r)=>{let i=this.getAssetPlayer(e.identifier);i&&(r===t&&i.loadSource(),i.resumeBuffering())})}else this.hls.resumeBuffering(),this.playerQueue.forEach(e=>e.pauseBuffering());this.hls.trigger(o.INTERSTITIALS_BUFFERED_TO_BOUNDARY,{events:n.slice(0),schedule:i.slice(0),bufferingIndex:this.findItemIndex(e),playingIndex:this.findItemIndex(this.playingItem)})}else this.bufferingItem!==e&&(this.bufferingItem=e);return t}bufferedToItem(e,t=0){let r=this.setBufferingItem(e);if(!this.playbackDisabled){if(this.isInterstitial(e))this.bufferedToEvent(e,t);else if(null!==r){this.bufferingAsset=null;let t=this.detachedData;t&&t.mediaSource?this.attachPrimary(e.start,e,!0):this.preloadPrimary(e)}}}preloadPrimary(e){let t=this.findItemIndex(e),r=this.getPrimaryResumption(e,t);this.startLoadingPrimaryAt(r)}bufferedToEvent(e,t){let r=e.event,i=0===r.assetList.length&&!r.assetListLoader,n=r.cue.once;if(i||!n){let e=this.preloadAssets(r,t);if(null!=e&&e.interstitial.appendInPlace){let t=this.primaryMedia;t&&this.bufferAssetPlayer(e,t)}}}preloadAssets(e,t){let r=e.assetUrl,i=e.assetList.length,n=0===i&&!e.assetListLoader,s=e.cue.once;if(n){let n,s=e.timelineStart;if(e.appendInPlace){var a;let t=this.playingItem;this.isInterstitial(t)||(null==t||null==(a=t.nextEvent)?void 0:a.identifier)!==e.identifier||this.flushFrontBuffer(s+.25)}let o=0;if(!this.playingItem&&this.primaryLive&&-1===(o=this.hls.startPosition)&&(o=this.hls.liveSyncPosition||0),o&&!(e.cue.pre||e.cue.post)){let e=o-s;e>0&&(n=Math.round(1e3*e)/1e3)}if(this.log(`Load interstitial asset ${t+1}/${r?1:i} ${e}${n?` live-start: ${o} start-offset: ${n}`:""}`),r)return this.createAsset(e,0,0,s,e.duration,r);let l=this.assetListLoader.loadAssetList(e,n);l&&(e.assetListLoader=l)}else if(!s&&i){for(let r=t;r<i;r++){let t=e.assetList[r],i=this.getAssetPlayerQueueIndex(t.identifier);(-1===i||this.playerQueue[i].destroyed)&&!t.error&&this.createAssetPlayer(e,t,r)}let r=e.assetList[t];if(r){let e=this.getAssetPlayer(r.identifier);return e&&e.loadSource(),e}}return null}flushFrontBuffer(e){let t=this.requiredTracks;t&&(this.log(`Removing front buffer starting at ${e}`),Object.keys(t).forEach(t=>{this.hls.trigger(o.BUFFER_FLUSHING,{startOffset:e,endOffset:1/0,type:t})}))}getAssetPlayerQueueIndex(e){let t=this.playerQueue;for(let r=0;r<t.length;r++)if(e===t[r].assetId)return r;return -1}getAssetPlayer(e){let t=this.getAssetPlayerQueueIndex(e);return this.playerQueue[t]||null}getBufferingPlayer(){let{playerQueue:e,primaryMedia:t}=this;if(t){for(let r=0;r<e.length;r++)if(e[r].media===t)return e[r]}return null}createAsset(e,t,r,i,n,s){let a={parentIdentifier:e.identifier,identifier:`${e.identifier}-${t+1}-${nV(s)}`,duration:n,startOffset:r,timelineStart:i,uri:s};return this.createAssetPlayer(e,a,t)}createAssetPlayer(e,t,r){let i=this.hls,n=i.userConfig,l=n.videoPreference,u=i.loadLevelObj||i.levels[i.currentLevel];(l||u)&&(l=D({},l),u.videoCodec&&(l.videoCodec=u.videoCodec),u.videoRange&&(l.allowedVideoRanges=[u.videoRange]));let c=i.audioTracks[i.audioTrack],d=i.subtitleTracks[i.subtitleTrack],h=0;if(this.primaryLive||e.appendInPlace){let e=this.timelinePos-t.timelineStart;if(e>1){let r=t.duration;r&&e<r&&(h=e)}}let f=t.identifier,p=O(O({},n),{},{maxMaxBufferLength:Math.min(180,i.config.maxMaxBufferLength),autoStartLoad:!0,startFragPrefetch:!0,primarySessionId:i.sessionId,assetPlayerId:f,abrEwmaDefaultEstimate:i.bandwidthEstimate,interstitialsController:void 0,startPosition:h,liveDurationInfinity:!1,testBandwidth:!1,videoPreference:l,audioPreference:c||n.audioPreference,subtitlePreference:d||n.subtitlePreference});e.appendInPlace&&(e.appendInPlaceStarted=!0,t.timelineStart&&(p.timelineOffset=t.timelineStart));let g=p.cmcd;null!=g&&g.sessionId&&g.contentId&&(p.cmcd=D({},g,{contentId:nV(t.uri)})),this.getAssetPlayer(f)&&this.warn(`Duplicate date range identifier ${e} and asset ${f}`);let m=new nY(this.HlsPlayerClass,p,e,t);this.playerQueue.push(m),e.assetList[r]=t;let y=!0,v=i=>{if(i.live){var n;let t=Error(`Interstitials MUST be VOD assets ${e}`),i={fatal:!0,type:s.OTHER_ERROR,details:a.INTERSTITIAL_ASSET_ITEM_ER
2470ROR,error:t},o=(null==(n=this.schedule)?void 0:n.findEventIndex(e.identifier))||-1;this.handleAssetItemError(i,e,o,r,t.message);return}let o=i.edge-i.fragmentStart,l=t.duration;(y||null===l||o>l)&&(y=!1,this.log(`Interstitial asset "${f}" duration change ${l} > ${o}`),t.duration=o,this.updateSchedule())};m.on(o.LEVEL_UPDATED,(e,{details:t})=>v(t)),m.on(o.LEVEL_PTS_UPDATED,(e,{details:t})=>v(t)),m.on(o.EVENT_CUE_ENTER,()=>this.onInterstitialCueEnter());let b=(e,t)=>{let r=this.getAssetPlayer(f);if(r&&t.tracks){r.off(o.BUFFER_CODECS,b),r.tracks=t.tracks;let e=this.primaryMedia;this.bufferingAsset===r.assetItem&&e&&!r.media&&this.bufferAssetPlayer(r,e)}};m.on(o.BUFFER_CODECS,b);let _=()=>{var r;let i=this.getAssetPlayer(f);if(this.log(`buffered to end of asset ${i}`),!i||!this.schedule)return;let n=this.schedule.findEventIndex(e.identifier),s=null==(r=this.schedule.items)?void 0:r[n];this.isInterstitial(s)&&this.advanceAssetBuffering(s,t)};m.on(o.BUFFERED_TO_END,_);let E=t=>()=>{if(!this.getAssetPlayer(f)||!this.schedule)return;this.shouldPlay=!0;let r=this.schedule.findEventIndex(e.identifier);this.advanceAfterAssetEnded(e,r,t)};return m.once(o.MEDIA_ENDED,E(r)),m.once(o.PLAYOUT_LIMIT_REACHED,E(1/0)),m.on(o.ERROR,(t,i)=>{if(!this.schedule)return;let n=this.getAssetPlayer(f);i.details===a.BUFFER_STALLED_ERROR?null!=n&&n.appendInPlace?this.handleInPlaceStall(e):(this.onTimeupdate(),this.checkBuffer(!0)):this.handleAssetItemError(i,e,this.schedule.findEventIndex(e.identifier),r,`Asset player error ${i.error} ${e}`)}),m.on(o.DESTROYING,()=>{if(!this.getAssetPlayer(f)||!this.schedule)return;let t=Error(`Asset player destroyed unexpectedly ${f}`),i={fatal:!0,type:s.OTHER_ERROR,details:a.INTERSTITIAL_ASSET_ITEM_ERROR,error:t};this.handleAssetItemError(i,e,this.schedule.findEventIndex(e.identifier),r,t.message)}),this.log(`INTERSTITIAL_ASSET_PLAYER_CREATED ${nW(t)}`),this.hls.trigger(o.INTERSTITIAL_ASSET_PLAYER_CREATED,{asset:t,assetListIndex:r,event:e,player:m}),m}clearInterstitial(e,t){this.clearAssetPlayers(e,t),e.reset()}clearAssetPlayers(e,t){e.assetList.forEach(e=>{this.clearAssetPlayer(e.identifier,t)})}resetAssetPlayer(e){let t=this.getAssetPlayerQueueIndex(e);if(-1!==t){this.log(`reset asset player "${e}" after error`);let r=this.playerQueue[t];this.transferMediaFromPlayer(r,null),r.resetDetails()}}clearAssetPlayer(e,t){let r=this.getAssetPlayerQueueIndex(e);if(-1!==r){let e=this.playerQueue[r];this.log(`clear ${e} toSegment: ${t?nX(t):t}`),this.transferMediaFromPlayer(e,t),this.playerQueue.splice(r,1),e.destroy()}}emptyPlayerQueue(){let e;for(;e=this.playerQueue.pop();)e.destroy();this.playerQueue=[]}startAssetPlayer(e,t,r,i,n){let{interstitial:s,assetItem:a,assetId:l}=e,u=s.assetList.length,c=this.playingAsset;this.endedAsset=null,this.playingAsset=a,c&&c.identifier===l||(c&&(this.clearAssetPlayer(c.identifier,r[i]),delete c.error),this.log(`INTERSTITIAL_ASSET_STARTED ${t+1}/${u} ${nW(a)}`),this.hls.trigger(o.INTERSTITIAL_ASSET_STARTED,{asset:a,assetListIndex:t,event:s,schedule:r.slice(0),scheduleIndex:i,player:e})),this.bufferAssetPlayer(e,n)}bufferAssetPlayer(e,t){var r,i;if(!this.schedule)return;let{interstitial:n,assetItem:o}=e,l=this.schedule.findEventIndex(n.identifier),u=null==(r=this.schedule.items)?void 0:r[l];if(!u)return;e.loadSource(),this.setBufferingItem(u),this.bufferingAsset=o;let c=this.getBufferingPlayer();if(c===e)return;let d=n.appendInPlace;if(d&&(null==c?void 0:c.interstitial.appendInPlace)===!1)return;let h=(null==c?void 0:c.tracks)||(null==(i=this.detachedData)?void 0:i.tracks)||this.requiredTracks;if(d&&o!==this.playingAsset){if(!e.tracks)return void this.log(`Waiting for track info before buffering ${e}`);if(h&&!B(h,e.tracks)){let t=Error(`Asset ${nW(o)} SourceBuffer tracks ('${Object.keys(e.tracks)}') are not compatible with primary content tracks ('${Object.keys(h)}')`),r={fatal:!0,type:s.OTHER_ERROR,details:a.INTERSTITIAL_ASSET_ITEM_ERROR,error:t},i=n.findAssetIndex(o);this.handleAssetItemError(r,n,l,i,t.message);return}}this.transferMediaTo(e,t)}handleInPlaceStall(e){let t=this.schedule,r=this.primaryMedia;if(!t||!r)return;let i=r.currentTime,n=t.findAssetIndex(e,i),s=e.assetList[n];if(s){let a=this.getAssetPlayer(s.identifier);if(a){let o=a.currentTime||i-s.timelineStart,l=a.duration-o;if(this.warn(`Stalled at ${o} of ${o+l} in ${a} ${e} (media.currentTime: ${i})`),o&&(l/r.playbackRate<.5||a.bufferedInPlaceToEnd(r))&&a.hls){let r=t.findEventIndex(e.identifier);this.advanceAfterAssetEnded(e,r,n)}}}}advanceInPlace(e){let t=this.primaryMedia;t&&t.currentTime<e&&(t.currentTime=e)}handleAssetItemError(e,t,r,i,n){if(e.details===a.BUFFER_STALLED_ERROR)return;let s=t.assetList[i]||null;if(this.warn(`INTERSTITIAL_ASSET_ERROR ${s?nW(s):s} ${e.error}`),!this.schedule)return;let l=(null==s?void 0:s.identifier)||"",u=this.getAssetPlayerQueueIndex(l),c=this.playerQueue[u]||null,d=this.schedule.items,h=D({},e,{fatal:!1,errorAction:ti(!0),asset:s,assetListIndex:i,event:t,schedule:d,scheduleIndex:r,player:c});if(this.hls.trigger(o.INTERSTITIAL_ASSET_ERROR,h),!e.fatal)return;let f=this.playingAsset,p=this.bufferingAsset,g=Error(n);if(s&&(this.clearAssetPlayer(l,null),s.error=g),t.assetList.some(e=>!e.error))for(let e=i;e<t.assetList.length;e++)this.resetAssetPlayer(t.assetList[e].identifier);else t.error=g;this.updateSchedule(!0),t.error?this.primaryFallback(t):f&&f.identifier===l?this.advanceAfterAssetEnded(t,r,i):p&&p.identifier===l&&this.isInterstitial(this.bufferingItem)&&this.advanceAssetBuffering(this.bufferingItem,p)}primaryFallback(e){let t=e.timelineStart,r=this.effectivePlayingItem,i=this.timelinePos;if(r){this.log(`Fallback to primary from event "${e.identifier}" start: ${t} pos: ${i} playing: ${nX(r)} error: ${e.error}`),-1===i&&(i=this.hls.startPosition);let n=this.updateItem(r,i);this.itemsMatch(r,n)&&this.clearInterstitial(e,null),e.appendInPlace&&(this.attachPrimary(t,null),this.flushFrontBuffer(t))}else if(-1===i)return void this.checkStart();if(!this.schedule)return;let n=this.schedule.findItemIndexAtTime(i);this.setSchedulePosition(n)}onAssetListLoaded(e,t){var r,i,n;let s=t.event,a=s.identifier,o=t.assetListResponse.ASSETS;if(!(null!=(r=this.schedule)&&r.hasEvent(a)))return;let l=s.timelineStart,u=s.duration,c=0;o.forEach((e,t)=>{let r=parseFloat(e.DURATION);this.createAsset(s,t,c,l+c,r,e.URI),c+=r}),s.duration=c,this.log(`Loaded asset-list with duration: ${c} (was: ${u}) ${s}`);let d=this.waitingItem,h=(null==d?void 0:d.event.identifier)===a;this.updateSchedule();let f=null==(i=this.bufferingItem)?void 0:i.event;if(h){let e=this.schedule.findEventIndex(a),t=null==(n=this.schedule.items)?void 0:n[e];if(t){if(!this.playingItem&&this.timelinePos>t.end&&this.schedule.findItemIndexAtTime(this.timelinePos)!==e){s.error=Error(`Interstitial ${o.length?"no longer within playback range":"asset-list is empty"} ${this.timelinePos} ${s}`),this.log(s.error.message),this.updateSchedule(!0),this.primaryFallback(s);return}this.setBufferingItem(t)}this.setSchedulePosition(e)}else if((null==f?void 0:f.identifier)===a){let e=s.assetList[0];if(e){let t=this.getAssetPlayer(e.identifier);if(f.appendInPlace){let e=this.primaryMedia;t&&e&&this.bufferAssetPlayer(t,e)}else t&&t.loadSource()}}}onError(e,t){if(this.schedule)switch(t.details){case a.ASSET_LIST_PARSING_ERROR:case a.ASSET_LIST_LOAD_ERROR:case a.ASSET_LIST_LOAD_TIMEOUT:{let e=t.interstitial;e&&(this.updateSchedule(!0),this.primaryFallback(e));break}case a.BUFFER_STALLED_ERROR:{let e=this.endedItem||this.waitingItem||this.playingItem;if(this.isInterstitial(e)&&e.event.appendInPlace)return void this.handleInPlaceStall(e.event);this.log(`Primary player stall @${this.timelinePos} bufferedPos: ${this.bufferedPos}`),this.onTimeupdate(),this.checkBuffer(!0)}}}}});class sq extends tb{constructor(e,t){super("gap-controller",e.logger),this.hls=void 0,this.fragmentTracker=void 0,this.media=null,this.mediaSource=void 0,this.nudgeRetry=0,this.stallReported=!1,this.stalled=null,this.moved=!1,this.seeking=!1,this.buffered={},this.lastCurrentTime=0,this.ended=0,this.waiting=0,this.onMediaPlaying=()=>{this.ended=0,this.waiting=0},this.onMediaWaiting=()=>{var e;null!=(e=this.media)&&e.seeking||(this.waiting=self.performance.now(),this.tick())},this.onMediaEnded=()=>
2470{if(this.hls){var e;this.ended=(null==(e=this.media)?void 0:e.currentTime)||1,this.hls.trigger(o.MEDIA_ENDED,{stalled:!1})}},this.hls=e,this.fragmentTracker=t,this.registerListeners()}registerListeners(){let{hls:e}=this;e&&(e.on(o.MEDIA_ATTACHED,this.onMediaAttached,this),e.on(o.MEDIA_DETACHING,this.onMediaDetaching,this),e.on(o.BUFFER_APPENDED,this.onBufferAppended,this))}unregisterListeners(){let{hls:e}=this;e&&(e.off(o.MEDIA_ATTACHED,this.onMediaAttached,this),e.off(o.MEDIA_DETACHING,this.onMediaDetaching,this),e.off(o.BUFFER_APPENDED,this.onBufferAppended,this))}destroy(){super.destroy(),this.unregisterListeners(),this.media=this.hls=this.fragmentTracker=null,this.mediaSource=void 0}onMediaAttached(e,t){this.setInterval(100),this.mediaSource=t.mediaSource;let r=this.media=t.media;rw(r,"playing",this.onMediaPlaying),rw(r,"waiting",this.onMediaWaiting),rw(r,"ended",this.onMediaEnded)}onMediaDetaching(e,t){this.clearInterval();let{media:r}=this;r&&(rA(r,"playing",this.onMediaPlaying),rA(r,"waiting",this.onMediaWaiting),rA(r,"ended",this.onMediaEnded),this.media=null),this.mediaSource=void 0}onBufferAppended(e,t){this.buffered=t.timeRanges}get hasBuffered(){return Object.keys(this.buffered).length>0}tick(){var e;if(!(null!=(e=this.media)&&e.readyState)||!this.hasBuffered)return;let t=this.media.currentTime;this.poll(t,this.lastCurrentTime),this.lastCurrentTime=t}poll(e,t){var r,i,n;let s=null==(r=this.hls)?void 0:r.config;if(!s)return;let a=this.media;if(!a)return;let{seeking:l}=a,u=this.seeking&&!l,c=!this.seeking&&l,d=a.paused&&!l||a.ended||0===a.playbackRate;if(this.seeking=l,e!==t){t&&(this.ended=0),this.moved=!0,!l&&(this.nudgeRetry=0,s.nudgeOnVideoHole&&!d&&e>t&&this.nudgeOnVideoHole(e,t)),0===this.waiting&&this.stallResolved(e);return}if(c||u){u&&this.stallResolved(e);return}if(d){this.nudgeRetry=0,this.stallResolved(e),!this.ended&&a.ended&&this.hls&&(this.ended=e||1,this.hls.trigger(o.MEDIA_ENDED,{stalled:!1}));return}if(!tx.getBuffered(a).length){this.nudgeRetry=0;return}let h=tx.bufferInfo(a,e,0),f=h.nextStart||0,p=this.fragmentTracker;if(l&&p&&this.hls){let t=sH(this.hls.inFlightFragments,e),r=h.len>2,i=!f||t||f-e>2&&!p.getPartialFragment(e);if(r||i)return;this.moved=!1}let g=null==(i=this.hls)?void 0:i.latestLevelDetails;if(!this.moved&&null!==this.stalled&&p){if(!(h.len>0)&&!f)return;
2470let t=Math.max(f,h.start||0)-e,r=null!=g&&g.live?2*g.targetduration:2,i=sK(e,p);if(t>0&&(t<=r||i)){a.paused||this._trySkipBufferHole(i);return}}let m=s.detectStallWithCurrentTimeMs,y=self.performance.now(),v=this.waiting,b=this.stalled;if(null===b)if(v>0&&y-v<m)b=this.stalled=v;else{this.stalled=y;return}let _=y-b;if(!l&&(_>=m||v)&&this.hls){if((null==(n=this.mediaSource)?void 0:n.readyState)==="ended"&&!(null!=g&&g.live)&&1>Math.abs(e-((null==g?void 0:g.edge)||0))){if(this.ended)return;this.ended=e||1,this.hls.trigger(o.MEDIA_ENDED,{stalled:!0});return}if(this._reportStall(h),!this.media||!this.hls)return}let E=tx.bufferInfo(a,e,s.maxBufferHole);this._tryFixBufferStall(E,_,e)}stallResolved(e){let t=this.stalled;if(t&&this.hls&&(this.stalled=null,this.stallReported)){let r=self.performance.now()-t;this.log(`playback not stuck anymore @${e}, after ${Math.round(r)}ms`),this.stallReported=!1,this.waiting=0,this.hls.trigger(o.STALL_RESOLVED,{})}}nudgeOnVideoHole(e,t){var r;let i=this.buffered.video;if(this.hls&&this.media&&this.fragmentTracker&&null!=(r=this.buffered.audio)&&r.length&&i&&i.length>1&&e>i.end(0)){let r=tx.bufferedInfo(tx.timeRangesToArray(this.buffered.audio),e,0);if(r.len>1&&t>=r.start){let r=tx.timeRangesToArray(i),n=tx.bufferedInfo(r,t,0).bufferedIndex;if(n>-1&&n<r.length-1){let t=tx.bufferedInfo(r,e,0).bufferedIndex,i=r[n].end,l=r[n+1].start;if((-1===t||t>n)&&l-i<1&&e-i<2){let r=Error(`nudging playhead to flush pipeline after video hole. currentTime: ${e} hole: ${i} -> ${l} buffered index: ${t}`);this.warn(r.message),this.media.currentTime+=1e-6;let n=sK(e,this.fragmentTracker);n&&"fragment"in n?n=n.fragment:n||(n=void 0);let u=tx.bufferInfo(this.media,e,0);this.hls.trigger(o.ERROR,{type:s.MEDIA_ERROR,details:a.BUFFER_SEEK_OVER_HOLE,fatal:!1,error:r,reason:r.message,frag:n,buffer:u.len,bufferInfo:u})}}}}}_tryFixBufferStall(e,t,r){var i,n;let{fragmentTracker:s,media:a}=this,o=null==(i=this.hls)?void 0:i.config;if(!a||!s||!o)return;let l=null==(n=this.hls)?void 0:n.latestLevelDetails,u=sK(r,s);if((u||null!=l&&l.live&&r<l.fragmentStart)&&(this._trySkipBufferHole(u)||!this.media))return;let c=e.buffered,d=this.adjacentTraversal(e,r);(c&&c.length>1&&e.len>o.maxBufferHole||e.nextStart&&(e.nextStart-r<o.maxBufferHole||d))&&(t>1e3*o.highBufferWatchdogPeriod||this.waiting)&&(this.warn("Trying to nudge playhead over buffer-hole"),this._tryNudgeBuffer(e))}adjacentTraversal(e,t){let r=this.fragmentTracker,i=e.nextStart;if(r&&i){let e=r.getFragAtPos(t,A),n=r.getFragAtPos(i,A);if(e&&n)return n.sn-e.sn<2}return!1}_reportStall(e){let{hls:t,media:r,stallReported:i,stalled:n}=this;if(!i&&null!==n&&r&&t){this.stallReported=!0;let i=Error(`Playback stalling at @${r.currentTime} due to low buffer (${ez(e)})`);this.warn(i.message),t.trigger(o.ERROR,{type:s.MEDIA_ERROR,details:a.BUFFER_STALLED_ERROR,fatal:!1,error:i,buffer:e.len,bufferInfo:e,stalled:{start:n}})}}_trySkipBufferHole(e){var t,r;let{fragmentTracker:i,media:n}=this,l=null==(t=this.hls)?void 0:t.config;if(!n||!i||!l)return 0;let u=n.currentTime,c=tx.bufferInfo(n,u,0),d=u<c.start?c.start:c.nextStart;if(d&&this.hls){let t=c.len<=l.maxBufferHole,h=c.len>0&&c.len<1&&n.readyState<3,f=d-u;if(f>0&&(t||h)){if(f>l.maxBufferHole){let t=!1;if(0===u){let e=i.getAppendedFrag(0,A);e&&d<e.end&&(t=!0)}if(!t&&e){if(!(null!=(r=this.hls.loadLevelObj)&&r.details)||sH(this.hls.inFlightFragments,d))return 0;let t=!1,n=e.end;for(;n<d;){let e=sK(n,i);if(e)n+=e.duration;else{t=!0;break}}if(t)return 0}}let t=Math.max(d+.05,u+.1);if(this.warn(`skipping hole, adjusting currentTime from ${u} to ${t}`),this.moved=!0,n.currentTime=t,!(null!=e&&e.gap)){let r=Error(`fragment loaded with buffer holes, seeking from ${u} to ${t}`),i={type:s.MEDIA_ERROR,details:a.BUFFER_SEEK_OVER_HOLE,fatal:!1,error:r,reason:r.message,buffer:c.len,bufferInfo:c};e&&("fragment"in e?i.part=e:i.frag=e),this.hls.trigger(o.ERROR,i)}return t}}return 0}_tryNudgeBuffer(e){let{hls:t,media:r,nudgeRetry:i}=this,n=null==t?void 0:t.config;if(!r||!n)return 0;let l=r.currentTime;if(this.nudgeRetry++,i<n.nudgeMaxRetry){let u=l+(i+1)*n.nudgeOffset,c=Error(`Nudging 'currentTime' from ${l} to ${u}`);this.warn(c.message),r.currentTime=u,t.trigger(o.ERROR,{type:s.MEDIA_ERROR,details:a.BUFFER_NUDGE_ON_STALL,error:c,fatal:!1,buffer:e.len,bufferInfo:e})}else{let r=Error(`Playhead still not moving while enough data buffered @${l} after ${n.nudgeMaxRetry} nudges`);this.error(r.message),t.trigger(o.ERROR,{type:s.MEDIA_ERROR,details:a.BUFFER_STALLED_ERROR,error:r,fatal:!0,buffer:e.len,bufferInfo:e})}}}function sH(e,t){let r=sz(e.main);if(r&&r.start<=t)return r;let i=sz(e.audio);return i&&i.start<=t?i:null}function sz(e){if(!e)return null;switch(e.state){case rk:case rI:case rN:case rM:return null}return e.frag}function sK(e,t){return t.getAppendedFrag(e,A)||t.getPartialFragment(e)}function sW(){if("u">typeof self)return self.VTTCue||self.TextTrackCue}function sY(e,t,r,i,n){let s=new e(t,r,"");try{s.value=i,n&&(s.type=n)}catch(a){s=new e(t,r,ez(n?O({type:n},i):i))}return s}let sQ=(()=>{let e=sW();try{e&&new e(0,1/0,"")}catch(e){return Number.MAX_VALUE}return 1/0})();class sX{constructor(e){this.hls=void 0,this.id3Track=null,this.media=null,this.dateRangeCuesAppended={},this.removeCues=!0,this.assetCue=void 0,this.onEventCueEnter=()=>{this.hls&&this.hls.trigger(o.EVENT_CUE_ENTER,{})},this.hls=e,this._registerListeners()}destroy(){this._unregisterListeners(),this.id3Track=null,this.media=null,this.dateRangeCuesAppended={},this.hls=this.onEventCueEnter=null}_registerListeners(){let{hls:e}=this;
2470e&&(e.on(o.MEDIA_ATTACHING,this.onMediaAttaching,this),e.on(o.MEDIA_ATTACHED,this.onMediaAttached,this),e.on(o.MEDIA_DETACHING,this.onMediaDetaching,this),e.on(o.MANIFEST_LOADING,this.onManifestLoading,this),e.on(o.FRAG_PARSING_METADATA,this.onFragParsingMetadata,this),e.on(o.BUFFER_FLUSHING,this.onBufferFlushing,this),e.on(o.LEVEL_UPDATED,this.onLevelUpdated,this),e.on(o.LEVEL_PTS_UPDATED,this.onLevelPtsUpdated,this))}_unregisterListeners(){let{hls:e}=this;e&&(e.off(o.MEDIA_ATTACHING,this.onMediaAttaching,this),e.off(o.MEDIA_ATTACHED,this.onMediaAttached,this),e.off(o.MEDIA_DETACHING,this.onMediaDetaching,this),e.off(o.MANIFEST_LOADING,this.onManifestLoading,this),e.off(o.FRAG_PARSING_METADATA,this.onFragParsingMetadata,this),e.off(o.BUFFER_FLUSHING,this.onBufferFlushing,this),e.off(o.LEVEL_UPDATED,this.onLevelUpdated,this),e.off(o.LEVEL_PTS_UPDATED,this.onLevelPtsUpdated,this))}onMediaAttaching(e,t){var r;this.media=t.media,(null==(r=t.overrides)?void 0:r.cueRemoval)===!1&&(this.removeCues=!1)}onMediaAttached(){var e;let t=null==(e=this.hls)?void 0:e.latestLevelDetails;t&&this.updateDateRangeCues(t)}onMediaDetaching(e,t){this.media=null,t.transferMedia||(this.id3Track&&(this.removeCues&&n$(this.id3Track,this.onEventCueEnter),this.id3Track=null),this.dateRangeCuesAppended={})}onManifestLoading(){this.dateRangeCuesAppended={}}createTrack(e){let t=this.getID3Track(e.textTracks);return t.mode="hidden",t}getID3Track(e){if(this.media){for(let t=0;t<e.length;t++){let r=e[t];if("metadata"===r.kind&&"id3"===r.label)return nM(r,this.media),r}return this.media.addTextTrack("metadata","id3")}}onFragParsingMetadata(e,t){if(!this.media||!this.hls)return;let{enableEmsgMetadataCues:r,enableID3MetadataCues:i}=this.hls.config;if(!r&&!i)return;let{samples:n}=t;this.id3Track||(this.id3Track=this.createTrack(this.media));let s=sW();if(s)for(let e=0;e<n.length;e++){let t=n[e].type;if(t===r6.emsg&&!r||!i)continue;let a=r4(n[e].data),o=n[e].pts,l=o+n[e].duration;l>sQ&&(l=sQ),l-o<=0&&(l=o+.25);for(let e=0;e<a.length;e++){let r=a[e];if(!r5(r)){this.updateId3CueEnds(o,t);let e=sY(s,o,l,r,t);e&&this.id3Track.addCue(e)}}}}updateId3CueEnds(e,t){var r;let i=null==(r=this.id3Track)?void 0:r.cues;if(i)for(let r=i.length;r--;){let n=i[r];n.type===t&&n.startTime<e&&n.endTime===sQ&&(n.endTime=e)}}onBufferFlushing(e,{startOffset:t,endOffset:r,type:i}){let{id3Track:n,hls:s}=this;if(!s)return;let{config:{enableEmsgMetadataCues:a,enableID3MetadataCues:o}}=s;n&&(a||o)&&nU(n,t,r,"audio"===i?e=>e.type===r6.audioId3&&o:"video"===i?e=>e.type===r6.emsg&&a:e=>e.type===r6.audioId3&&o||e.type===r6.emsg&&a)}onLevelUpdated(e,{details:t}){this.updateDateRangeCues(t,!0)}onLevelPtsUpdated(e,t){Math.abs(t.drift)>.01&&this.updateDateRangeCues(t.details)}updateDateRangeCues(e,t){var i,n;if(!this.hls||!this.media)return;let{assetPlayerId:s,timelineOffset:a,enableDateRangeMetadataCues:o,interstitialsController:l}=this.hls.config;if(!o)return;let u=sW();if(s&&a&&!l){let{fragmentStart:t,fragmentEnd:r}=e,i=this.assetCue;i?(i.startTime=t,i.endTime=r):u&&(i=this.assetCue=sY(u,t,r,{assetPlayerId:this.hls.config.assetPlayerId},"hlsjs.interstitial.asset"))&&(i.id=s,this.id3Track||(this.id3Track=this.createTrack(this.media)),this.id3Track.addCue(i),i.addEventListener("enter",this.onEventCueEnter))}if(!e.hasProgramDateTime)return;let{id3Track:c}=this,{dateRanges:d}=e,h=Object.keys(d),f=this.dateRangeCuesAppended;if(c&&t)if(null!=(i=c.cues)&&i.length){let e=Object.keys(f).filter(e=>!h.includes(e));for(let t=e.length;t--;){let r=e[t],i=null==(n=f[r])?void 0:n.cues;
2470delete f[r],i&&Object.keys(i).forEach(e=>{let t=i[e];if(t){t.removeEventListener("enter",this.onEventCueEnter);try{c.removeCue(t)}catch(e){}}})}}else f=this.dateRangeCuesAppended={};let p=e.fragments[e.fragments.length-1];if(0!==h.length&&r(null==p?void 0:p.programDateTime)){this.id3Track||(this.id3Track=this.createTrack(this.media));for(let e=0;e<h.length;e++){let t=h[e],r=d[t],i=r.startTime,n=f[t],s=(null==n?void 0:n.cues)||{},a=(null==n?void 0:n.durationKnown)||!1,o=sQ,{duration:c,endDate:p}=r;if(p&&null!==c)o=i+c,a=!0;else if(r.endOnNext&&!a){let e=h.reduce((e,t)=>{if(t!==r.id){let i=d[t];if(i.class===r.class&&i.startDate>r.startDate&&(!e||r.startDate<e.startDate))return i}return e},null);e&&(o=e.startTime,a=!0)}let g=Object.keys(r.attr);for(let e=0;e<g.length;e++){let c=g[e];if("ID"===c||"CLASS"===c||"CUE"===c||"START-DATE"===c||"DURATION"===c||"END-DATE"===c||"END-ON-NEXT"===c)continue;let d=s[c];if(d)a&&!(null!=n&&n.durationKnown)?d.endTime=o:Math.abs(d.startTime-i)>.01&&(d.startTime=i,d.endTime=o);else if(u){let e=r.attr[c];("SCTE35-OUT"===c||"SCTE35-IN"===c||"SCTE35-CMD"===c)&&(e=q(e));let n=sY(u,i,o,{key:c,data:e},r6.dateRange);n&&(n.id=t,this.id3Track.addCue(n),s[c]=n,l&&("X-ASSET-LIST"===c||"X-ASSET-URL"===c)&&n.addEventListener("enter",this.onEventCueEnter))}}f[t]={cues:s,dateRange:r,durationKnown:a}}}}}class sJ{constructor(e){this.hls=void 0,this.config=void 0,this.media=null,this.currentTime=0,this.stallCount=0,this._latency=null,this._targetLatencyUpdated=!1,this.onTimeupdate=()=>{let{media:e}=this,t=this.levelDetails;if(!e||!t)return;this.currentTime=e.currentTime;let r=this.computeLatency();if(null===r)return;this._latency=r;let{lowLatencyMode:i,maxLiveSyncPlaybackRate:n}=this.config;if(!i||1===n||!t.live)return;let s=this.targetLatency;if(null===s)return;let a=r-s;if(a<Math.min(this.maxLatency,s+t.targetduration)&&a>.05&&this.forwardBufferLength>1){let t=Math.min(Math.min(2,Math.max(1,n)),Math.max(1,Math.round(2/(1+Math.exp(-.75*a-this.edgeStalled))*20)/20));this.changeMediaPlaybackRate(e,t)}else 1!==e.playbackRate&&0!==e.playbackRate&&this.changeMediaPlaybackRate(e,1)},this.hls=e,this.config=e.config,this.registerListeners()}get levelDetails(){var e;return(null==(e=this.hls)?void 0:e.latestLevelDetails)||null}get latency(){return this._latency||0}get maxLatency(){let{config:e}=this;if(void 0!==e.liveMaxLatencyDuration)return e.liveMaxLatencyDuration;let t=this.levelDetails;return t?e.liveMaxLatencyDurationCount*t.targetduration:0}get targetLatency(){let e=this.levelDetails;if(null===e||null===this.hls)return null;let{holdBack:t,partHoldBack:r,targetduration:i}=e,{liveSyncDuration:n,liveSyncDurationCount:s,lowLatencyMode:a}=this.config,o=this.hls.userConfig,l=a&&r||t;return(this._targetLatencyUpdated||o.liveSyncDuration||o.liveSyncDurationCount||0===l)&&(l=void 0!==n?n:s*i),l+Math.min(this.stallCount*this.config.liveSyncOnStallIncrease,i)}set targetLatency(e){this.stallCount=0,this.config.liveSyncDuration=e,this._targetLatencyUpdated=!0}get liveSyncPosition(){let e=this.estimateLiveEdge(),t=this.targetLatency;if(null===e||null===t)return null;let r=this.levelDetails;if(null===r)return null;let i=r.edge,n=e-t-this.edgeStalled;return Math.min(Math.max(i-r.totalduration,n),i-(this.config.lowLatencyMode&&r.partTarget||r.targetduration))}get drift(){let e=this.levelDetails;return null===e?1:e.drift}get edgeStalled(){let e=this.levelDetails;if(null===e)return 0;let t=3*(this.config.lowLatencyMode&&e.partTarget||e.targetduration);return Math.max(e.age-t,0)}get forwardBufferLength(){let{media:e}=this,t=this.levelDetails;if(!e||!t)return 0;let r=e.buffered.length;return(r?e.buffered.end(r-1):t.edge)-this.currentTime}destroy(){this.unregisterListeners(),this.onMediaDetaching(),this.hls=null}registerListeners(){let{hls:e}=this;e&&(e.on(o.MEDIA_ATTACHED,this.onMediaAttached,this),e.on(o.MEDIA_DETACHING,this.onMediaDetaching,this),e.on(o.MANIFEST_LOADING,this.onManifestLoading,this),e.on(o.LEVEL_UPDATED,this.onLevelUpdated,this),e.on(o.ERROR,this.onError,this))}unregisterListeners(){let{hls:e}=this;
2470e&&(e.off(o.MEDIA_ATTACHED,this.onMediaAttached,this),e.off(o.MEDIA_DETACHING,this.onMediaDetaching,this),e.off(o.MANIFEST_LOADING,this.onManifestLoading,this),e.off(o.LEVEL_UPDATED,this.onLevelUpdated,this),e.off(o.ERROR,this.onError,this))}onMediaAttached(e,t){this.media=t.media,this.media.addEventListener("timeupdate",this.onTimeupdate)}onMediaDetaching(){this.media&&(this.media.removeEventListener("timeupdate",this.onTimeupdate),this.media=null)}onManifestLoading(){this._latency=null,this.stallCount=0}onLevelUpdated(e,{details:t}){t.advanced&&this.onTimeupdate(),!t.live&&this.media&&this.media.removeEventListener("timeupdate",this.onTimeupdate)}onError(e,t){var r;t.details===a.BUFFER_STALLED_ERROR&&(this.stallCount++,this.hls&&null!=(r=this.levelDetails)&&r.live&&this.hls.logger.warn("[latency-controller]: Stall detected, adjusting target latency"))}changeMediaPlaybackRate(e,t){var r,i;e.playbackRate!==t&&(null==(r=this.hls)||r.logger.debug(`[latency-controller]: latency=${this.latency.toFixed(3)}, targetLatency=${null==(i=this.targetLatency)?void 0:i.toFixed(3)}, forwardBufferLength=${this.forwardBufferLength.toFixed(3)}: adjusting playback rate from ${e.playbackRate} to ${t}`),e.playbackRate=t)}estimateLiveEdge(){let e=this.levelDetails;return null===e?null:e.edge+e.age}computeLatency(){let e=this.estimateLiveEdge();return null===e?null:e-this.currentTime}}class sZ extends iY{constructor(e,t){super(e,"level-controller"),this._levels=[],this._firstLevel=-1,this._maxAutoLevel=-1,this._startLevel=void 0,this.currentLevel=null,this.currentLevelIndex=-1,this.manualLevelIndex=-1,this.steering=void 0,this.onParsedComplete=void 0,this.steering=t,this._registerListeners()}_registerListeners(){let{hls:e}=this;e.on(o.MANIFEST_LOADING,this.onManifestLoading,this),e.on(o.MANIFEST_LOADED,this.onManifestLoaded,this),e.on(o.LEVEL_LOADED,this.onLevelLoaded,this),e.on(o.LEVELS_UPDATED,this.onLevelsUpdated,this),e.on(o.FRAG_BUFFERED,this.onFragBuffered,this),e.on(o.ERROR,this.onError,this)}_unregisterListeners(){let{hls:e}=this;e.off(o.MANIFEST_LOADING,this.onManifestLoading,this),e.off(o.MANIFEST_LOADED,this.onManifestLoaded,this),e.off(o.LEVEL_LOADED,this.onLevelLoaded,this),e.off(o.LEVELS_UPDATED,this.onLevelsUpdated,this),e.off(o.FRAG_BUFFERED,this.onFragBuffered,this),e.off(o.ERROR,this.onError,this)}destroy(){this._unregisterListeners(),this.steering=null,this.resetLevels(),super.destroy()}stopLoad(){this._levels.forEach(e=>{e.loadError=0,e.fragmentError=0}),super.stopLoad()}resetLevels(){this._startLevel=void 0,this.manualLevelIndex=-1,this.currentLevelIndex=-1,this.currentLevel=null,this._levels=[],this._maxAutoLevel=-1}onManifestLoading(e,t){this.resetLevels()}onManifestLoaded(e,t){let r=this.hls.config.preferManagedMediaSource,i=[],n={},s={},a=!1,o=!1,l=!1;t.levels.forEach(e=>{let t=e.attrs,{audioCodec:u,videoCodec:c}=e;u&&(e.audioCodec=u=eC(u,r)||void 0),c&&(c=e.videoCodec=function(e){let t=e.split(",");for(let e=0;e<t.length;e++){let r=t[e].split(".");r.length>2&&"avc1"===r[0]&&(t[e]=`avc1.${parseInt(r[1]).toString(16)}${("000"+parseInt(r[2]).toString(16)).slice(-4)}`)}return t.join(",")}(c));let{width:d,height:h,unknownCodecs:f}=e,p=(null==f?void 0:f.length)||0;if(a||(a=!!(d&&h)),o||(o=!!c),l||(l=!!u),p||u&&!this.isAudioSupported(u)||c&&!this.isVideoSupported(c))return void this.log(`Some or all CODECS not supported "${t.CODECS}"`);let{CODECS:g,"FRAME-RATE":m,"HDCP-LEVEL":y,"PATHWAY-ID":v,RESOLUTION:b,"VIDEO-RANGE":_}=t,E=`${v||"."}-`,S=`${E}${e.bitrate}-${b}-${m}-${g}-${_}-${y}`;if(n[S])if(n[S].uri===e.url||e.attrs["PATHWAY-ID"])n[S].addGroupId("audio",t.AUDIO),n[S].addGroupId("text",t.SUBTITLES);else{let t=s[S]+=1;e.attrs["PATHWAY-ID"]=Array(t+1).join(".");let r=this.createLevel(e);n[S]=r,i.push(r)}else{let t=this.createLevel(e);n[S]=t,s[S]=1,i.push(t)}}),this.filterAndSortMediaOptions(i,t,a,o,l)}createLevel(e){let t=new eq(e),r=e.supplemental;if(null!=r&&r.videoCodec&&!this.isVideoSupported(r.videoCodec)){let e=Error(`SUPPLEMENTAL-CODECS not supported "${r.videoCodec}"`);this.log(e.message),t.supportedResult=eM(e,[])}return t}isAudioSupported(e){return ex(e,"audio",this.hls.config.preferManagedMediaSource)}isVideoSupported(e){return ex(e,"video",this.hls.config.preferManagedMediaSource)}filterAndSortMediaOptions(e,t,r,i,n){var l,u;let c=[],d=[],h=e,f=(null==(l=t.stats)?void 0:l.parsing)||{};if((r||i)&&n&&(h=h.filter(({videoCodec:e,videoRange:t,width:r,height:i})=>{var n;
2470return(!!e||!!(r&&i))&&!!(n=t)&&eB.indexOf(n)>-1})),0===h.length){Promise.resolve().then(()=>{if(this.hls){let e="no level with compatible codecs found in manifest",r=e;t.levels.length&&(r=`one or more CODECS in variant not supported: ${ez(t.levels.map(e=>e.attrs.CODECS).filter((e,t,r)=>r.indexOf(e)===t))}`,this.warn(r),e+=` (${r})`);let i=Error(e);this.hls.trigger(o.ERROR,{type:s.MEDIA_ERROR,details:a.MANIFEST_INCOMPATIBLE_CODECS_ERROR,fatal:!0,url:t.url,error:i,reason:r})}}),f.end=performance.now();return}t.audioTracks&&s0(c=t.audioTracks.filter(e=>!e.audioCodec||this.isAudioSupported(e.audioCodec))),t.subtitles&&s0(d=t.subtitles);let p=h.slice(0);h.sort((e,t)=>{if(e.attrs["HDCP-LEVEL"]!==t.attrs["HDCP-LEVEL"])return(e.attrs["HDCP-LEVEL"]||"")>(t.attrs["HDCP-LEVEL"]||"")?1:-1;if(r&&e.height!==t.height)return e.height-t.height;if(e.frameRate!==t.frameRate)return e.frameRate-t.frameRate;if(e.videoRange!==t.videoRange)return eB.indexOf(e.videoRange)-eB.indexOf(t.videoRange);if(e.videoCodec!==t.videoCodec){let r=eA(e.videoCodec),i=eA(t.videoCodec);if(r!==i)return i-r}if(e.uri===t.uri&&e.codecSet!==t.codecSet){let r=eR(e.codecSet),i=eR(t.codecSet);if(r!==i)return i-r}return e.averageBitrate!==t.averageBitrate?e.averageBitrate-t.averageBitrate:0});let g=p[0];if(this.steering&&(h=this.steering.filterParsedLevels(h)).length!==p.length){for(let e=0;e<p.length;e++)if(p[e].pathwayId===h[0].pathwayId){g=p[e];break}}this._levels=h;for(let e=0;e<h.length;e++)if(h[e]===g){this._firstLevel=e;let t=g.bitrate,r=this.hls.bandwidthEstimate;if(this.log(`manifest loaded, ${h.length} level(s) found, first bitrate: ${t}`),(null==(u=this.hls.userConfig)?void 0:u.abrEwmaDefaultEstimate)===void 0){let e=Math.min(t,this.hls.config.abrEwmaDefaultEstimateMax);e>r&&r===this.hls.abrEwmaDefaultEstimate&&(this.hls.bandwidthEstimate=e)}break}let m=n&&!i,y=this.hls.config,v=!!(y.audioStreamController&&y.audioTrackController),b={levels:h,audioTracks:c,subtitleTracks:d,sessionData:t.sessionData,sessionKeys:t.sessionKeys,firstLevel:this._firstLevel,stats:t.stats,audio:n,video:i,altAudio:v&&!m&&c.some(e=>!!e.url)};f.end=performance.now(),this.hls.trigger(o.MANIFEST_PARSED,b)}get levels(){return 0===this._levels.length?null:this._levels}get loadLevelObj(){return this.currentLevel}get level(){return this.currentLevelIndex}set level(e){let t=this._levels;if(0===t.length)return;if(e<0||e>=t.length){let r=Error("invalid level idx"),i=e<0;if(this.hls.trigger(o.ERROR,{type:s.OTHER_ERROR,details:a.LEVEL_SWITCH_ERROR,level:e,fatal:i,error:r,reason:r.message}),i)return;e=Math.min(e,t.length-1)}let r=this.currentLevelIndex,i=this.currentLevel,n=i?i.attrs["PATHWAY-ID"]:void 0,l=t[e],u=l.attrs["PATHWAY-ID"];if(this.currentLevelIndex=e,this.currentLevel=l,r===e&&i&&n===u)return;this.log(`Switching to level ${e} (${l.height?l.height+"p ":""}${l.videoRange?l.videoRange+" ":""}${l.codecSet?l.codecSet+" ":""}@${l.bitrate})${u?" with Pathway "+u:""} from level ${r}${n?" with Pathway "+n:""}`);let c={level:e,attrs:l.attrs,details:l.details,bitrate:l.bitrate,averageBitrate:l.averageBitrate,maxBitrate:l.maxBitrate,realBitrate:l.realBitrate,width:l.width,height:l.height,codecSet:l.codecSet,audioCodec:l.audioCodec,videoCodec:l.videoCodec,audioGroups:l.audioGroups,subtitleGroups:l.subtitleGroups,loaded:l.loaded,loadError:l.loadError,fragmentError:l.fragmentError,name:l.name,id:l.id,uri:l.uri,url:l.url,urlId:0,audioGroupIds:l.audioGroupIds,textGroupIds:l.textGroupIds};this.hls.trigger(o.LEVEL_SWITCHING,c);let d=l.details;if(!d||d.live){let e=this.switchParams(l.uri,null==i?void 0:i.details,d);this.loadPlaylist(e)}}get manualLevel(){return this.manualLevelIndex}set manualLevel(e){this.manualLevelIndex=e,void 0===this._startLevel&&(this._startLevel=e),-1!==e&&(this.level=e)}get firstLevel(){return this._firstLevel}set firstLevel(e){this._firstLevel=e}get startLevel(){if(void 0===this._startLevel){let e=this.hls.config.startLevel;return void 0!==e?e:this.hls.firstAutoLevel}return this._startLevel}set startLevel(e){this._startLevel=e}get pathways(){return this.steering?this.steering.pathways():[]}get pathwayPriority(){return this.steering?this.steering.pathwayPriority:null}set pathwayPriority(e){if(this.steering){let t=this.steering.pathways(),r=e.filter(e=>-1!==t.indexOf(e));if(e.length<1)return void this.warn(`pathwayPriority ${e} should contain at least one pathway from list: ${t}`);this.steering.pathwayPriority=r}}onError(e,t){!t.fatal&&t.context&&t.context.type===x&&t.context.level===this.level&&this.checkRetry(t)}onFragBuffered(e,{frag:t}){if(void 0!==t&&t.type===A){let e=t.elementaryStreams;if(!Object.keys(e).some(t=>!!e[t]))return;let r=this._levels[t.level];null!=r&&r.loadError&&(this.log(`Resetting level error count of ${r.loadError} on frag buffered`),r.loadError=0)}}onLevelLoaded(e,t){var r,i;let{level:n,details:s}=t,a=t.levelInfo;if(!a){this.warn(`Invalid level index ${n}`),null!=(i=t.deliveryDirectives)&&i.skip&&(s.deltaUpdateFailed=!0);return}if(a===this.currentLevel||t.withoutMultiVariant){0===a.fragmentError&&(a.loadError=0);let e=a.details;e===t.details&&e.advanced&&(e=void 0),this.playlistLoaded(n,t,e)}else null!=(r=t.deliveryDirectives)&&r.skip&&(s.deltaUpdateFailed=!0)}loadPlaylist(e){super.loadPlaylist(),this.shouldLoadPlaylist(this.currentLevel)&&this.scheduleLo
2470ading(this.currentLevel,e)}loadingPlaylist(e,t){super.loadingPlaylist(e,t);let r=this.getUrlWithDirectives(e.uri,t),i=this.currentLevelIndex,n=e.attrs["PATHWAY-ID"],s=e.details,a=null==s?void 0:s.age;this.log(`Loading level index ${i}${(null==t?void 0:t.msn)!==void 0?" at sn "+t.msn+" part "+t.part:""}${n?" Pathway "+n:""}${a&&s.live?" age "+a.toFixed(1)+(s.type?" "+s.type:""):""} ${r}`),this.hls.trigger(o.LEVEL_LOADING,{url:r,level:i,levelInfo:e,pathwayId:e.attrs["PATHWAY-ID"],id:0,deliveryDirectives:t||null})}get nextLoadLevel(){return -1!==this.manualLevelIndex?this.manualLevelIndex:this.hls.nextAutoLevel}set nextLoadLevel(e){this.level=e,-1===this.manualLevelIndex&&(this.hls.nextAutoLevel=e)}removeLevel(e){var t;if(1===this._levels.length)return;let r=this._levels.filter((t,r)=>r!==e||(this.steering&&this.steering.removeLevel(t),t===this.currentLevel&&(this.currentLevel=null,this.currentLevelIndex=-1,t.details&&t.details.fragments.forEach(e=>e.level=-1)),!1));rv(r),this._levels=r,this.currentLevelIndex>-1&&null!=(t=this.currentLevel)&&t.details&&(this.currentLevelIndex=this.currentLevel.details.fragments[0].level),this.manualLevelIndex>-1&&(this.manualLevelIndex=this.currentLevelIndex);let i=r.length-1;this._firstLevel=Math.min(this._firstLevel,i),this._startLevel&&(this._startLevel=Math.min(this._startLevel,i)),this.hls.trigger(o.LEVELS_UPDATED,{levels:r})}onLevelsUpdated(e,{levels:t}){this._levels=t}checkMaxAutoUpdated(){let{autoLevelCapping:e,maxAutoLevel:t,maxHdcpLevel:r}=this.hls;this._maxAutoLevel!==t&&(this._maxAutoLevel=t,this.hls.trigger(o.MAX_AUTO_LEVEL_UPDATED,{autoLevelCapping:e,levels:this.levels,maxAutoLevel:t,minAutoLevel:this.hls.minAutoLevel,maxHdcpLevel:r}))}}function s0(e){let t={};e.forEach(e=>{let r=e.groupId||"";e.id=t[r]=t[r]||0,t[r]++})}function s1(){return self.SourceBuffer||self.WebKitSourceBuffer}function s2(){if(!U())return!1;let e=s1();return!e||e.prototype&&"function"==typeof e.prototype.appendBuffer&&"function"==typeof e.prototype.remove}class s3 extends rU{constructor(e,t,i){super(e,t,i,"stream-controller",A),this.audioCodecSwap=!1,this.level=-1,this._forceStartLoad=!1,this._hasEnoughToStart=!1,this.altAudio=0,this.audioOnly=!1,this.fragPlaying=null,this.fragLastKbps=0,this.couldBacktrack=!1,this.backtrackFragment=null,this.audioCodecSwitch=!1,this.videoBuffer=null,this.onMediaPlaying=()=>{this.tick()},this.onMediaSeeked=()=>{let e=this.media,t=e?e.currentTime:null;if(null===t||!r(t)||(this.log(`Media seeked to ${t.toFixed(3)}`),!this.getBufferedFrag(t)))return;let i=this.getFwdBufferInfoAtPos(e,t,A,0);null===i||0===i.len?this.warn(`Main forward buffer length at ${t} on "seeked" event ${i?i.len:"empty"})`):this.tick()},this.registerListeners()}registerListeners(){super.registerListeners();let{hls:e}=this;e.on(o.MANIFEST_PARSED,this.onManifestParsed,this),e.on(o.LEVEL_LOADING,this.onLevelLoading,this),e.on(o.LEVEL_LOADED,this.onLevelLoaded,this),e.on(o.FRAG_LOAD_EMERGENCY_ABORTED,this.onFragLoadEmergencyAborted,this),e.on(o.AUDIO_TRACK_SWITCHING,this.onAudioTrackSwitching,this),e.on(o.AUDIO_TRACK_SWITCHED,this.onAudioTrackSwitched,this),e.on(o.BUFFER_CREATED,this.onBufferCreated,this),e.on(o.BUFFER_FLUSHED,this.onBufferFlushed,this),e.on(o.LEVELS_UPDATED,this.onLevelsUpdated,this),e.on(o.FRAG_BUFFERED,this.onFragBuffered,this)}unregisterListeners(){super.unregisterListeners();let{hls:e}=this;e.off(o.MANIFEST_PARSED,this.onManifestParsed,this),e.off(o.LEVEL_LOADED,this.onLevelLoaded,this),e.off(o.FRAG_LOAD_EMERGENCY_ABORTED,this.onFragLoadEmergencyAborted,this),e.off(o.AUDIO_TRACK_SWITCHING,this.onAudioTrackSwitching,this),e.off(o.AUDIO_TRACK_SWITCHED,this.onAudioTrackSwitched,this),e.off(o.BUFFER_CREATED,this.onBufferCreated,this),e.off(o.BUFFER_FLUSHED,this.onBufferFlushed,this),e.off(o.LEVELS_UPDATED,this.onLevelsUpdated,this),e.off(o.FRAG_BUFFERED,this.onFragBuffered,this)}onHandlerDestroying(){this.onMediaPlaying=this.onMediaSeeked=null,this.unregisterListeners(),super.onHandlerDestroying()}startLoad(e,t){if(this.levels){let{lastCurrentTime:r,hls:i}=this;if(this.stopLoad(),this.setInterval(100),this.level=-1,!this.startFragRequested){let e=i.startLevel;-1===e&&(i.config.testBandwidth&&this.levels.length>1?(e=0,this.bitrateTest=!0):e=i.firstAutoLevel),i.nextLoadLevel=e,this.level=i.loadLevel,this._hasEnoughToStart=!!t}r>0&&-1===e&&!t&&(this.log(`Override startPosition with lastCurrentTime @${r.toFixed(3)}`),e=r),this.state=rk,this.nextLoadPosition=this.lastCurrentTime=e+this.timelineOffset,this.startPosition=t?-1:e,this.tick()}else this._forceStartLoad=!0,this.state=rI}stopLoad(){this._forceStartLoad=!1,super.stopLoad()}doTick(){switch(this.state){case r$:{let{levels:e,level:t}=this,r=null==e?void 0:e[t],i=null==r?void 0:r.details;if(!i||i.live&&(this.levelLastLoaded!==r||this.waitForLive(r)))this.hls.nextLoadLevel!==this.level&&(this.state=rk);else{if(this.waitForCdnTuneIn(i))break;this.state=rk}break}case rL:this.checkRetryDate()}this.state===rk&&this.doTickIdle(),this.onTickEnd()}onTickEnd(){var e;super.onTickEnd(),null!=(e=this.media)&&e.readyState&&!1===this.media.seeking&&(this.lastCurrentTime=this.media.currentTime),this.checkFragmentChanged()}doTickIdle(){let{hls:e,levelLastLoaded:t,levels:r,media:i}=this;if(null===t||!i&&!this.primaryPrefetch&&(this.startFragRequested||!e.config.startFragPrefetch)||this.altAudio&&this.audioOnly)return;
2470let n=this.buffering?e.nextLoadLevel:e.loadLevel;if(!(null!=r&&r[n]))return;let s=r[n],a=this.getMainFwdBufferInfo();if(null===a)return;let l=this.getLevelDetails();if(l&&this._streamEnded(a,l)){let e={};2===this.altAudio&&(e.type="video"),this.hls.trigger(o.BUFFER_EOS,e),this.state=rN;return}if(!this.buffering)return;e.loadLevel!==n&&-1===e.manualLevel&&this.log(`Adapting to level ${n} from level ${this.level}`),this.level=e.nextLoadLevel=n;let u=s.details;if(!u||this.state===r$||this.waitForLive(s)){this.level=n,this.state=r$,this.startFragRequested=!1;return}let c=a.len,d=this.getMaxBufferLength(s.maxBitrate);if(c>=d)return;this.backtrackFragment&&this.backtrackFragment.start>a.end&&(this.backtrackFragment=null);let h=this.backtrackFragment?this.backtrackFragment.start:a.end,f=this.getNextFragment(h,u);if(this.couldBacktrack&&!this.fragPrevious&&f&&J(f)&&"OK"!==this.fragmentTracker.getState(f)){var p;let e=(null!=(p=this.backtrackFragment)?p:f).sn-u.startSN,t=u.fragments[e-1];t&&f.cc===t.cc&&(f=t,this.fragmentTracker.removeFragment(t))}else this.backtrackFragment&&a.len&&(this.backtrackFragment=null);if(f&&this.isLoopLoading(f,h)){if(!f.gap){let e=this.audioOnly&&!this.altAudio?W:Y,t=(e===Y?this.videoBuffer:this.mediaBuffer)||this.media;t&&this.afterBufferFlushed(t,e,A)}f=this.getNextFragmentLoopLoading(f,u,a,A,d)}!f||this.exceedsMaxBuffer(a,d,f)||(!f.initSegment||f.initSegment.data||this.bitrateTest||(f=f.initSegment),this.loadFragment(f,s,h))}loadFragment(e,t,r){let i=this.fragmentTracker.getState(e);i===tn||i===ta?J(e)?this.bitrateTest?(this.log(`Fragment ${e.sn} of level ${e.level} is being downloaded to test bitrate and will not be buffered`),this._loadBitrateTestFrag(e,t)):super.loadFragment(e,t,r):this._loadInitSegment(e,t):this.clearTrackerIfNeeded(e)}getBufferedFrag(e){return this.fragmentTracker.getBufferedFrag(e,A)}followingBufferedFrag(e){return e?this.getBufferedFrag(e.end+.5):null}immediateLevelSwitch(){if(this.abortCurrentFrag(),this.flushMainBuffer(0,1/0),0!==this.altAudio){var e;((null==(e=this.getLevelDetails())?void 0:e.fragmentStart)||0)>this.lastCurrentTime&&super.flushMainBuffer(0,1/0,"audio")}}nextLevelSwitch(){let{levels:e,media:t}=this;if(null!=t&&t.readyState){let r,i=this.getAppendedFrag(t.currentTime);i&&i.start>1&&this.flushMainBuffer(0,i.start-1);let n=this.getLevelDetails();if(null!=n&&n.live){let e=this.getMainFwdBufferInfo();if(!e||e.len<2*n.targetduration)return}if(!t.paused&&e){let t=e[this.hls.nextLoadLevel],i=this.fragLastKbps;r=i&&this.fragCurrent?this.fragCurrent.duration*t.maxBitrate/(1e3*i)+1:0}else r=0;let s=this.getBufferedFrag(t.currentTime+r);if(s){let e=this.followingBufferedFrag(s);if(e){this.abortCurrentFrag();let t=e.maxStartPTS?e.maxStartPTS:e.start,r=e.duration,i=Math.max(s.end,t+Math.min(Math.max(r-this.config.maxFragLookUpTolerance,r*(this.couldBacktrack?.5:.125)),r*(this.couldBacktrack?.75:.25)));this.flushMainBuffer(i,1/0)}}}}abortCurrentFrag(){let e=this.fragCurrent;switch(this.fragCurrent=null,this.backtrackFragment=null,e&&(e.abortRequests(),this.fragmentTracker.removeFragment(e)),this.state){case rC:case rD:case rL:case rP:case rF:this.state=rk}this.nextLoadPosition=this.getLoadPosition()}flushMainBuffer(e,t){super.flushMainBuffer(e,t,2===this.altAudio?"video":null)}onMediaAttached(e,t){super.onMediaAttached(e,t);let r=t.media;rw(r,"playing",this.onMediaPlaying),rw(r,"seeked",this.onMediaSeeked)}onMediaDetaching(e,t){let{media:r}=this;r&&(rA(r,"playing",this.onMediaPlaying),rA(r,"seeked",this.onMediaSeeked)),this.videoBuffer=null,this.fragPlaying=null,super.onMediaDetaching(e,t),t.transferMedia||(this._hasEnoughToStart=!1)}onManifestLoading(){super.onManifestLoading(),this.log("Trigger BUFFER_RESET"),this.hls.trigger(o.BUFFER_RESET,void 0),this.couldBacktrack=!1,this.fragLastKbps=0,this.fragPlaying=this.backtrackFragment=null,this.altAudio=0,this.audioOnly=!1}onManifestParsed(e,t){var r;let i,n=!1,s=!1;for(let e=0;e<t.levels.length;e++){let r=t.levels[e].audioCodec;r&&(n=n||-1!==r.indexOf("mp4a.40.2"),s=s||-1!==r.indexOf("mp4a.40.5"))}this.audioCodecSwitch=n&&s&&"function"!=typeof(null==(i=s1())||null==(r=i.prototype)?void 0:r.changeType),this.audioCodecSwitch&&this.log("Both AAC/HE-AAC audio found in levels; declaring level codec as HE-AAC"),this.levels=t.levels,this.startFragRequested=!1}onLevelLoading(e,t){let{levels:r}=this;if(!r||this.state!==rk)return;let i=t.levelInfo;(!i.details||i.details.live&&(this.levelLastLoaded!==i||i.details.expired)||this.waitForCdnTuneIn(i.details))&&(this.state=r$)}onLevelLoaded(e,t){var r,i;let{levels:n,startFragRequested:s}=this,a=t.level,l=t.details,u=l.totalduration;if(!n)return void this.warn(`Levels were reset while loading level ${a}`);this.log(`Level ${a} loaded [${l.startSN},${l.endSN}]${l.lastPartSn?`[part-${l.lastPartSn}-${l.lastPartIndex}]`:""}, cc [${l.startCC}, ${l.endCC}] duration:${u}`);let c=t.levelInfo,d=this.fragCurrent;d&&(this.state===rD||this.state===rL)&&d.level!==t.level&&d.loader&&this.abortCurrentFrag();let h=0;if(l.live||null!=(r=c.details)&&r.live){if(this.checkLiveUpdate(l),l.deltaUpdateFailed)return;h=this.alignPlaylists(l,c.details,null==(i=this.levelLastLoaded)?void 0:i.details)}if(c.details=l,this.levelLastLoaded=c,s||this.setStartPosition(l,h),this.hls.trigger(o.LEVEL_UPDATED,{details:l,level:a}),this.state===r$){if(this.waitForCdnTuneIn(l))return;this.state=rk}s&&l.live&&this.synchronizeToLiveEdge(l),this.tick()}
2470synchronizeToLiveEdge(e){let{config:t,media:r}=this;if(!r)return;let i=this.hls.liveSyncPosition,n=this.getLoadPosition(),s=e.fragmentStart,a=e.edge,o=n>=s-t.maxFragLookUpTolerance&&n<=a;if(null!==i&&r.duration>i&&(n<i||!o)){let s=void 0!==t.liveMaxLatencyDuration?t.liveMaxLatencyDuration:t.liveMaxLatencyDurationCount*e.targetduration;if((!o&&r.readyState<4||n<a-s)&&(this._hasEnoughToStart||(this.nextLoadPosition=i),r.readyState))if(this.warn(`Playback: ${n.toFixed(3)} is located too far from the end of live sliding playlist: ${a}, reset currentTime to : ${i.toFixed(3)}`),"buffered"===this.config.liveSyncMode){var l;let e=tx.bufferInfo(r,i,0);if(!(null!=(l=e.buffered)&&l.length)||e.start<=n){r.currentTime=i;return}let{nextStart:t}=tx.bufferedInfo(e.buffered,n,0);t&&(r.currentTime=t)}else r.currentTime=i}}_handleFragmentLoadProgress(e){var t;let r=e.frag,{part:i,payload:n}=e,{levels:s}=this;if(!s)return void this.warn(`Levels were reset while fragment load was in progress. Fragment ${r.sn} of level ${r.level} will not be buffered`);let a=s[r.level];if(!a)return void this.warn(`Level ${r.level} not found on progress`);let o=a.details;if(!o){this.warn(`Dropping fragment ${r.sn} of level ${r.level} after level details were reset`),this.fragmentTracker.removeFragment(r);return}let l=a.videoCodec,u=o.PTSKnown||!o.live,c=null==(t=r.initSegment)?void 0:t.data,d=this._getAudioCodec(a),h=this.transmuxer=this.transmuxer||new iW(this.hls,A,this._handleTransmuxComplete.bind(this),this._handleTransmuxerFlush.bind(this)),f=i?i.index:-1,p=new t_(r.level,r.sn,r.stats.chunkCount,n.byteLength,f,-1!==f),g=this.initPTS[r.cc];h.push(n,c,d,l,r,i,o.totalduration,u,p,g)}onAudioTrackSwitching(e,t){let r=this.hls,i=0!==this.altAudio;if(e0(t.url,r))this.altAudio=1;else{if(this.mediaBuffer!==this.media){this.log("Switching on main audio, use media.buffered to schedule main fragment loading"),this.mediaBuffer=this.media;let e=this.fragCurrent;e&&(this.log("Switching to main audio track, cancel main fragment load"),e.abortRequests(),this.fragmentTracker.removeFragment(e)),this.resetTransmuxer(),this.resetLoadingState()}else this.audioOnly&&this.resetTransmuxer();if(i){this.altAudio=0,this.fragmentTracker.removeAllFragments(),r.once(o.BUFFER_FLUSHED,()=>{this.hls&&this.hls.trigger(o.AUDIO_TRACK_SWITCHED,t)}),r.trigger(o.BUFFER_FLUSHING,{startOffset:0,endOffset:1/0,type:null});return}r.trigger(o.AUDIO_TRACK_SWITCHED,t)}}onAudioTrackSwitched(e,t){let r=e0(t.url,this.hls);if(r){let e=this.videoBuffer;e&&this.mediaBuffer!==e&&(this.log("Switching on alternate audio, use video.buffered to schedule main fragment loading"),this.mediaBuffer=e)}this.altAudio=2*!!r,this.tick()}onBufferCreated(e,t){let r,i,n=t.tracks,s=!1;for(let e in n){let t=n[e];if("main"===t.id){if(i=e,r=t,"video"===e){let t=n[e];t&&(this.videoBuffer=t.buffer)}}else s=!0}s&&r?(this.log(`Alternate track found, use ${i}.buffered to schedule main fragment loading`),this.mediaBuffer=r.buffer):this.mediaBuffer=this.media}onFragBuffered(e,t){let{frag:r,part:i}=t,n=r.type===A;if(n){if(this.fragContextChanged(r)){this.warn(`Fragment ${r.sn}${i?" p: "+i.index:""} of level ${r.level} finished buffering, but was aborted. state: ${this.state}`),this.state===rF&&(this.state=rk);return}let e=i?i.stats:r.stats;this.fragLastKbps=Math.round(8*e.total/(e.buffering.end-e.loading.first)),J(r)&&(this.fragPrevious=r),this.fragBufferedComplete(r,i)}let s=this.media;s&&(!this._hasEnoughToStart&&tx.getBuffered(s).length&&(this._hasEnoughToStart=!0,this.seekToStartPos()),n&&this.tick())}get hasEnoughToStart(){return this._hasEnoughToStart}onError(e,t){var r;if(t.fatal){this.state=rM;return}switch(t.details){case a.FRAG_GAP:case a.FRAG_PARSING_ERROR:case a.FRAG_DECRYPT_ERROR:case a.FRAG_LOAD_ERROR:case a.FRAG_LOAD_TIMEOUT:case a.KEY_LOAD_ERROR:case a.KEY_LOAD_TIMEOUT:this.onFragmentOrKeyLoadError(A,t);break;case a.LEVEL_LOAD_ERROR:case a.LEVEL_LOAD_TIMEOUT:case a.LEVEL_PARSING_ERROR:t.levelRetry||this.state!==r$||(null==(r=t.context)?void 0:r.type)!==x||(this.state=rk);break;case a.BUFFER_ADD_CODEC_ERROR:case a.BUFFER_APPEND_ERROR:if("main"!==t.parent)return;this.reduceLengthAndFlushBuffer(t)&&this.resetLoadingState();break;case a.BUFFER_FULL_ERROR:if("main"!==t.parent)return;this.reduceLengthAndFlushBuffer(t)&&(!this.config.interstitialsController&&this.config.assetPlayerId?this._hasEnoughToStart=!0:this.flushMainBuffer(0,1/0));break;
2470case a.INTERNAL_EXCEPTION:this.recoverWorkerError(t)}}onFragLoadEmergencyAborted(){this.state=rk,this._hasEnoughToStart||(this.startFragRequested=!1,this.nextLoadPosition=this.lastCurrentTime),this.tickImmediate()}onBufferFlushed(e,{type:t}){if(t!==W||!this.altAudio){let e=(t===Y?this.videoBuffer:this.mediaBuffer)||this.media;e&&(this.afterBufferFlushed(e,t,A),this.tick())}}onLevelsUpdated(e,t){this.level>-1&&this.fragCurrent&&(this.level=this.fragCurrent.level,-1===this.level&&this.resetWhenMissingContext(this.fragCurrent)),this.levels=t.levels}swapAudioCodec(){this.audioCodecSwap=!this.audioCodecSwap}seekToStartPos(){let{media:e}=this;if(!e)return;let t=e.currentTime,r=this.startPosition;if(r>=0&&t<r){if(e.seeking)return void this.log(`could not seek to ${r}, already seeking at ${t}`);let i=this.timelineOffset;i&&r&&(r+=i);let n=this.getLevelDetails(),s=tx.getBuffered(e),a=s.length?s.start(0):0,o=a-r,l=Math.max(this.config.maxBufferHole,this.config.maxFragLookUpTolerance);(this.config.startOnSegmentBoundary||o>0&&(o<l||this.loadingParts&&o<2*((null==n?void 0:n.partTarget)||0)))&&(this.log(`adjusting start position by ${o} to match buffer start`),r+=o,this.startPosition=r),t<r&&(this.log(`seek to target start position ${r} from current time ${t} buffer start ${a}`),e.currentTime=r)}}_getAudioCodec(e){let t=this.config.defaultAudioCodec||e.audioCodec;return this.audioCodecSwap&&t&&(this.log("Swapping audio codec"),t=-1!==t.indexOf("mp4a.40.5")?"mp4a.40.2":"mp4a.40.5"),t}_loadBitrateTestFrag(e,t){e.bitrateTest=!0,this._doFragLoad(e,t).then(e=>{let{hls:r}=this,i=null==e?void 0:e.frag;if(!i||this.fragContextChanged(i))return;t.fragmentError=0,this.state=rk,this.startFragRequested=!1,this.bitrateTest=!1;let n=i.stats;n.parsing.start=n.parsing.end=n.buffering.start=n.buffering.end=self.performance.now(),r.trigger(o.FRAG_LOADED,e),i.bitrateTest=!1}).catch(t=>{this.state!==rI&&this.state!==rM&&(this.warn(t),this.resetFragmentLoading(e))})}_handleTransmuxComplete(e){let t=this.playlistType,{hls:i}=this,{remuxResult:n,chunkMeta:s}=e,a=this.getCurrentContext(s);if(!a)return void this.resetWhenMissingContext(s);let{frag:l,part:u,level:c}=a,{video:d,text:h,id3:f,initSegment:p}=n,{details:g}=c,m=this.altAudio?void 0:n.audio;if(this.fragContextChanged(l))return void this.fragmentTracker.removeFragment(l);if(this.state=rP,p){let e=p.tracks;if(e){let r=l.initSegment||l;if(this.unhandledEncryptionError(p,l))return;this._bufferInitSegment(c,e,r,s),i.trigger(o.FRAG_PARSING_INIT_SEGMENT,{frag:r,id:t,tracks:e})}let n=p.initPTS,a=p.timescale,u=this.initPTS[l.cc];if(r(n)&&(!u||u.baseTime!==n||u.timescale!==a)){let e=p.trackId;this.initPTS[l.cc]={baseTime:n,timescale:a,trackId:e},i.trigger(o.INIT_PTS_FOUND,{frag:l,id:t,initPTS:n,timescale:a,trackId:e})}}if(d&&g){m&&"audiovideo"===d.type&&this.logMuxedErr(l);let e=g.fragments[l.sn-1-g.startSN],t=l.sn===g.startSN,r=!e||l.cc>e.cc;if(!1!==n.independent){let{startPTS:e,endPTS:i,startDTS:n,endDTS:a}=d;if(u)u.elementaryStreams[d.type]={startPTS:e,endPTS:i,startDTS:n,endDTS:a};else if(d.firstKeyFrame&&d.independent&&1===s.id&&!r&&(this.couldBacktrack=!0),d.dropped&&d.independent){let n=this.getMainFwdBufferInfo(),s=(n?n.end:this.getLoadPosition())+this.config.maxBufferHole,o=d.firstKeyFramePTS?d.firstKeyFramePTS:e;if(!t&&s<o-this.config.maxBufferHole&&!r)return void this.backtrack(l);r&&(l.gap=!0),l.setElementaryStreamInfo(d.type,l.start,i,l.start,a,!0)}else t&&e-(g.appliedTimelineOffset||0)>2&&(l.gap=!0);l.setElementaryStreamInfo(d.type,e,i,n,a),this.backtrackFragment&&(this.backtrackFragment=l),this.bufferFragmentData(d,l,u,s,t||r)}else{if(!t&&!r)return void this.backtrack(l);l.gap=!0}}if(m){let{startPTS:e,endPTS:t,startDTS:r,endDTS:i}=m;u&&(u.elementaryStreams[W]={startPTS:e,endPTS:t,startDTS:r,endDTS:i}),l.setElementaryStreamInfo(W,e,t,r,i),this.bufferFragmentData(m,l,u,s)}if(g&&null!=f&&f.samples.length){let e={id:t,frag:l,details:g,samples:f.samples};i.trigger(o.FRAG_PARSING_METADATA,e)}if(g&&h){let e={id:t,frag:l,details:g,samples:h.samples};i.trigger(o.FRAG_PARSING_USERDATA,e)}}logMuxedErr(e){this.warn(`${J(e)?"Media":"Init"} segment with muxed audiovideo where only video expected: ${e.url}`)}
2470_bufferInitSegment(e,t,r,i){if(this.state!==rP)return;this.audioOnly=!!t.audio&&!t.video,this.altAudio&&!this.audioOnly&&(delete t.audio,t.audiovideo&&this.logMuxedErr(r));let{audio:n,video:s,audiovideo:a}=t;if(n){let r=e.audioCodec,i=eD(n.codec,r);"mp4a"===i&&(i="mp4a.40.5");let s=navigator.userAgent.toLowerCase();if(this.audioCodecSwitch){i&&(i=-1!==i.indexOf("mp4a.40.5")?"mp4a.40.2":"mp4a.40.5");let e=n.metadata;e&&"channelCount"in e&&1!==(e.channelCount||1)&&-1===s.indexOf("firefox")&&(i="mp4a.40.5")}i&&-1!==i.indexOf("mp4a.40.5")&&-1!==s.indexOf("android")&&"audio/mpeg"!==n.container&&(i="mp4a.40.2",this.log(`Android: force audio codec to ${i}`)),r&&r!==i&&this.log(`Swapping manifest audio codec "${r}" for "${i}"`),n.levelCodec=i,n.id=A,this.log(`Init audio buffer, container:${n.container}, codecs[selected/level/parsed]=[${i||""}/${r||""}/${n.codec}]`),delete t.audiovideo}if(s){s.levelCodec=e.videoCodec,s.id=A;let r=s.codec;if((null==r?void 0:r.length)===4)switch(r){case"hvc1":case"hev1":s.codec="hvc1.1.6.L120.90";break;case"av01":s.codec="av01.0.04M.08";break;case"avc1":s.codec="avc1.42e01e"}this.log(`Init video buffer, container:${s.container}, codecs[level/parsed]=[${e.videoCodec||""}/${r}]${s.codec!==r?" parsed-corrected="+s.codec:""}${s.supplemental?" supplemental="+s.supplemental:""}`),delete t.audiovideo}a&&(this.log(`Init audiovideo buffer, container:${a.container}, codecs[level/parsed]=[${e.codecs}/${a.codec}]`),delete t.video,delete t.audio);let l=Object.keys(t);if(l.length){if(this.hls.trigger(o.BUFFER_CODECS,t),!this.hls)return;l.forEach(e=>{let n=t[e].initSegment;null!=n&&n.byteLength&&this.hls.trigger(o.BUFFER_APPENDING,{type:e,data:n,frag:r,part:null,chunkMeta:i,parent:r.type})})}this.tickImmediate()}getMainFwdBufferInfo(){let e=this.mediaBuffer&&2===this.altAudio?this.mediaBuffer:this.media;return this.getFwdBufferInfo(e,A)}get maxBufferLength(){let{levels:e,level:t}=this,r=null==e?void 0:e[t];return r?this.getMaxBufferLength(r.maxBitrate):this.config.maxBufferLength}backtrack(e){this.couldBacktrack=!0,this.backtrackFragment=e,this.resetTransmuxer(),this.flushBufferGap(e),this.fragmentTracker.removeFragment(e),this.fragPrevious=null,this.nextLoadPosition=e.start,this.state=rk}checkFragmentChanged(){let e=this.media,t=null;if(e&&e.readyState>1&&!1===e.seeking){let r=e.currentTime;if(tx.isBuffered(e,r)?t=this.getAppendedFrag(r):tx.isBuffered(e,r+.1)&&(t=this.getAppendedFrag(r+.1)),t){this.backtrackFragment=null;let e=this.fragPlaying,r=t.level;(!e||t.sn!==e.sn||e.level!==r)&&(this.fragPlaying=t,this.hls.trigger(o.FRAG_CHANGED,{frag:t}),e&&e.level===r||this.hls.trigger(o.LEVEL_SWITCHED,{level:r}))}}}get nextLevel(){let e=this.nextBufferedFrag;return e?e.level:-1}get currentFrag(){var e;if(this.fragPlaying)return this.fragPlaying;let t=(null==(e=this.media)?void 0:e.currentTime)||this.lastCurrentTime;return r(t)?this.getAppendedFrag(t):null}get currentProgramDateTime(){var e;let t=(null==(e=this.media)?void 0:e.currentTime)||this.lastCurrentTime;if(r(t)){let e=this.getLevelDetails(),r=this.currentFrag||(e?e2(null,e.fragments,t):null);if(r){let e=r.programDateTime;if(null!==e)return new Date(e+(t-r.start)*1e3)}}return null}get currentLevel(){let e=this.currentFrag;return e?e.level:-1}get nextBufferedFrag(){let e=this.currentFrag;return e?this.followingBufferedFrag(e):null}get forceStartLoad(){return this._forceStartLoad}}class s4 extends P{constructor(e,t){super("key-loader",t),this.config=void 0,this.keyIdToKeyInfo={},this.emeController=null,this.config=e}abort(e){for(let r in this.keyIdToKeyInfo){let i=this.keyIdToKeyInfo[r].loader;if(i){var t;if(e&&e!==(null==(t=i.context)?void 0:t.frag.type))return;i.abort()}}}detach(){for(let e in this.keyIdToKeyInfo){let t=this.keyIdToKeyInfo[e];(t.mediaKeySessionContext||t.decryptdata.isCommonEncryption)&&delete this.keyIdToKeyInfo[e]}}destroy(){for(let e in this.detach(),this.keyIdToKeyInfo){let t=this.keyIdToKeyInfo[e].loader;t&&t.destroy()}this.keyIdToKeyInfo={}}createKeyLoadError(e,t=a.KEY_LOAD_ERROR,r,i,n){return new tv({type:s.NETWORK_ERROR,details:t,fatal:!1,frag:e,response:n,error:r,networkDetails:i}
2470)}loadClear(e,t,r){if(this.emeController&&this.config.emeEnabled&&!this.emeController.getSelectedKeySystemFormats().length){if(t.length)for(let i=0,n=t.length;i<n;i++){let s=t[i];if(e.cc<=s.cc&&(!J(e)||!J(s)||e.sn<s.sn)||!r&&i==n-1)return this.emeController.selectKeySystemFormat(s).then(e=>{if(!this.emeController)return;s.setKeyFormat(e);let t=tY(e);if(t)return this.emeController.getKeySystemAccess([t])})}if(this.config.requireKeySystemAccessOnStart){let e=tX(this.config);if(e.length)return this.emeController.getKeySystemAccess(e)}}return null}load(e){return!e.decryptdata&&e.encrypted&&this.emeController&&this.config.emeEnabled?this.emeController.selectKeySystemFormat(e).then(t=>this.loadInternal(e,t)):this.loadInternal(e)}loadInternal(e,t){var r,i;t&&e.setKeyFormat(t);let n=e.decryptdata;if(!n){let r=Error(t?`Expected frag.decryptdata to be defined after setting format ${t}`:`Missing decryption data on fragment in onKeyLoading (emeEnabled with controller: ${this.emeController&&this.config.emeEnabled})`);return Promise.reject(this.createKeyLoadError(e,a.KEY_LOAD_ERROR,r))}let s=n.uri;if(!s)return Promise.reject(this.createKeyLoadError(e,a.KEY_LOAD_ERROR,Error(`Invalid key URI: "${s}"`)));let o=s5(n),l=this.keyIdToKeyInfo[o];if(null!=(r=l)&&r.decryptdata.key)return n.key=l.decryptdata.key,Promise.resolve({frag:e,keyInfo:l});if(this.emeController&&null!=(i=l)&&i.keyLoadPromise)switch(this.emeController.getKeyStatus(l.decryptdata)){case"usable":case"usable-in-future":return l.keyLoadPromise.then(t=>{let{keyInfo:r}=t;return n.key=r.decryptdata.key,{frag:e,keyInfo:r}})}switch(this.log(`${this.keyIdToKeyInfo[o]?"Rel":"L"}oading${n.keyId?" keyId: "+G(n.keyId):""} URI: ${n.uri} from ${e.type} ${e.level}`),l=this.keyIdToKeyInfo[o]={decryptdata:n,keyLoadPromise:null,loader:null,mediaKeySessionContext:null},n.method){case"SAMPLE-AES":case"SAMPLE-AES-CENC":case"SAMPLE-AES-CTR":if("identity"===n.keyFormat)return this.loadKeyHTTP(l,e);return this.loadKeyEME(l,e);case"AES-128":case"AES-256":case"AES-256-CTR":return this.loadKeyHTTP(l,e);default:return Promise.reject(this.createKeyLoadError(e,a.KEY_LOAD_ERROR,Error(`Key supplied with unsupported METHOD: "${n.method}"`)))}}loadKeyEME(e,t){let r={frag:t,keyInfo:e};if(this.emeController&&this.config.emeEnabled){var i,n;if(!e.decryptdata.keyId&&null!=(i=t.initSegment)&&i.data){let r,i=(n=t.initSegment.data,r=[],ep(n,e=>r.push(e.subarray(8,24))),r);if(i.length){let t=i[0];t.some(e=>0!==e)?(this.log(`Using keyId found in init segment ${G(t)}`),t1.setKeyIdForUri(e.decryptdata.uri,t)):(t=t1.addKeyIdForUri(e.decryptdata.uri),this.log(`Generating keyId to patch media ${G(t)}`)),e.decryptdata.keyId=t}}return e.decryptdata.keyId||J(t)?(e.keyLoadPromise=this.emeController.loadKey(r).then(t=>(e.mediaKeySessionContext=t,r))).catch(r=>{throw e.keyLoadPromise=null,"data"in r&&(r.data.frag=t),r}):Promise.resolve(r)}return Promise.resolve(r)}loadKeyHTTP(e,t){let r=this.config,i=new r.loader(r);return t.keyLoader=e.loader=i,e.keyLoadPromise=new Promise((n,s)=>{let o={keyInfo:e,frag:t,responseType:"arraybuffer",url:e.decryptdata.uri},l=r.keyLoadPolicy.default,u={loadPolicy:l,timeout:l.maxLoadTimeMs,maxRetry:0,retryDelay:0,maxRetryDelay:0};i.load(o,u,{onSuccess:(e,t,r,i)=>{let{frag:o,keyInfo:l}=r,u=s5(l.decryptdata);if(!o.decryptdata||l!==this.keyIdToKeyInfo[u])return s(this.createKeyLoadError(o,a.KEY_LOAD_ERROR,Error("after key load, decryptdata unset or changed"),i));l.decryptdata.key=o.decryptdata.key=new Uint8Array(e.data),o.keyLoader=null,l.loader=null,n({frag:o,keyInfo:l})},onError:(e,r,i,n)=>{this.resetLoader(r),s(this.createKeyLoadError(t,a.KEY_LOAD_ERROR,Error(`HTTP Error ${e.code} loading key ${e.text}`),i,O({url:o.url,data:void 0},e)))},onTimeout:(e,r,i)=>{this.resetLoader(r),s(this.createKeyLoadError(t,a.KEY_LOAD_TIMEOUT,Error("key loading timed out"),i))},onAbort:(e,r,i)=>{this.resetLoader(r),s(this.createKeyLoadError(t,a.INTERNAL_ABORTED,Error("key loading aborted"),i))}})})}resetLoader(e){let{frag:t,keyInfo:r,url:i}=e,n=r.loader;t.keyLoader===n&&(t.keyLoader=null,r.loader=null);let s=s5(r.decryptdata)||i;delete this.keyIdToKeyInfo[s],n&&n.destroy()}}function s5(e){if(e.keyFormat!==tz){let t=e.keyId;if(t)return G(t)}return e.uri}function s8(e){let{type:t}=e;switch(t){case T:return R;case w:return I;default:return A}}function s6(e,t){let r=e.url;return(void 0===r||0===r.indexOf("data:"))&&(r=t.url),r}class s7{constructor(e){this.hls=void 0,this.loaders=Object.create(null),this.variableList=null,this.onManifestLoaded=this.checkAutostartLoad,this.hls=e,this.registerListeners()}
2470startLoad(e){}stopLoad(){this.destroyInternalLoaders()}registerListeners(){let{hls:e}=this;e.on(o.MANIFEST_LOADING,this.onManifestLoading,this),e.on(o.LEVEL_LOADING,this.onLevelLoading,this),e.on(o.AUDIO_TRACK_LOADING,this.onAudioTrackLoading,this),e.on(o.SUBTITLE_TRACK_LOADING,this.onSubtitleTrackLoading,this),e.on(o.LEVELS_UPDATED,this.onLevelsUpdated,this)}unregisterListeners(){let{hls:e}=this;e.off(o.MANIFEST_LOADING,this.onManifestLoading,this),e.off(o.LEVEL_LOADING,this.onLevelLoading,this),e.off(o.AUDIO_TRACK_LOADING,this.onAudioTrackLoading,this),e.off(o.SUBTITLE_TRACK_LOADING,this.onSubtitleTrackLoading,this),e.off(o.LEVELS_UPDATED,this.onLevelsUpdated,this)}createInternalLoader(e){let t=this.hls.config,r=t.pLoader,i=t.loader,n=new(r||i)(t);return this.loaders[e.type]=n,n}getInternalLoader(e){return this.loaders[e.type]}resetInternalLoader(e){this.loaders[e]&&delete this.loaders[e]}destroyInternalLoaders(){for(let e in this.loaders){let t=this.loaders[e];t&&t.destroy(),this.resetInternalLoader(e)}}destroy(){this.variableList=null,this.unregisterListeners(),this.destroyInternalLoaders()}onManifestLoading(e,t){let{url:r}=t;this.variableList=null,this.load({id:null,level:0,responseType:"text",type:S,url:r,deliveryDirectives:null,levelOrTrack:null})}onLevelLoading(e,t){let{id:r,level:i,pathwayId:n,url:s,deliveryDirectives:a,levelInfo:o}=t;this.load({id:r,level:i,pathwayId:n,responseType:"text",type:x,url:s,deliveryDirectives:a,levelOrTrack:o})}onAudioTrackLoading(e,t){let{id:r,groupId:i,url:n,deliveryDirectives:s,track:a}=t;this.load({id:r,groupId:i,level:null,responseType:"text",type:T,url:n,deliveryDirectives:s,levelOrTrack:a})}onSubtitleTrackLoading(e,t){let{id:r,groupId:i,url:n,deliveryDirectives:s,track:a}=t;this.load({id:r,groupId:i,level:null,responseType:"text",type:w,url:n,deliveryDirectives:s,levelOrTrack:a})}onLevelsUpdated(e,t){let r=this.loaders[x];if(r){let e=r.context;e&&!t.levels.some(t=>t===e.levelOrTrack)&&(r.abort(),delete this.loaders[x])}}load(e){var t;let i,n=this.hls.config,s=this.getInternalLoader(e);if(s){let t=this.hls.logger,r=s.context;if(r&&r.levelOrTrack===e.levelOrTrack&&(r.url===e.url||r.deliveryDirectives&&!e.deliveryDirectives))return void(r.url===e.url?t.log(`[playlist-loader]: ignore ${e.url} ongoing request`):t.log(`[playlist-loader]: ignore ${e.url} in favor of ${r.url}`));t.log(`[playlist-loader]: aborting previous loader for type: ${e.type}`),s.abort()}if(i=e.type===S?n.manifestLoadPolicy.default:D({},n.playlistLoadPolicy.default,{timeoutRetry:null,errorRetry:null}),s=this.createInternalLoader(e),r(null==(t=e.deliveryDirectives)?void 0:t.part)){let t;if(e.type===x&&null!==e.level?t=this.hls.levels[e.level].details:e.type===T&&null!==e.id?t=this.hls.audioTracks[e.id].details:e.type===w&&null!==e.id&&(t=this.hls.subtitleTracks[e.id].details),t){let e=t.partTarget,r=t.targetduration;if(e&&r){let t=1e3*Math.max(3*e,.8*r);i=D({},i,{maxTimeToFirstByteMs:Math.min(t,i.maxTimeToFirstByteMs),maxLoadTimeMs:Math.min(t,i.maxTimeToFirstByteMs)})}}}let a=i.errorRetry||i.timeoutRetry||{},o={loadPolicy:i,timeout:i.maxLoadTimeMs,maxRetry:a.maxNumRetry||0,retryDelay:a.retryDelayMs||0,maxRetryDelay:a.maxRetryDelayMs||0};s.load(e,o,{onSuccess:(e,t,r,i)=>{let n=this.getInternalLoader(r);this.resetInternalLoader(r.type);let s=e.data;t.parsing.start=performance.now(),t7.isMediaPlaylist(s)||r.type!==S?this.handleTrackOrLevelPlaylist(e,t,r,i||null,n):this.handleMasterPlaylist(e,t,r,i)},onError:(e,t,r,i)=>{this.handleNetworkError(t,r,!1,e,i)},onTimeout:(e,t,r)=>{this.handleNetworkError(t,r,!0,void 0,e)}})}checkAutostartLoad(){if(!this.hls)return;let{config:{autoStartLoad:e,startPosition:t},forceStartLoad:r}=this.hls;(e||r)&&(this.hls.logger.log(`${e?"auto":"force"} startLoad with configured startPosition ${t}`),this.hls.startLoad(t))}handleMasterPlaylist(e,t,r,i){let n=this.hls,s=e.data,a=s6(e,r),l=t7.parseMasterPlaylist(s,a);if(l.playlistParsingError){t.parsing.end=performance.now(),this.handleManifestParsingError(e,r,l.playlistParsingError,i,t);return}let{contentSteering:u,levels:c,sessionData:d,sessionKeys:h,startTimeOffset:f,variableList:p}=l;
2470this.variableList=p,c.forEach(e=>{let{unknownCodecs:t}=e;if(t){let{preferManagedMediaSource:r}=this.hls.config,{audioCodec:i,videoCodec:n}=e;for(let s=t.length;s--;){let a=t[s];ex(a,"audio",r)?(e.audioCodec=i=i?`${i},${a}`:a,eE.audio[i.substring(0,4)]=2,t.splice(s,1)):ex(a,"video",r)&&(e.videoCodec=n=n?`${n},${a}`:a,eE.video[n.substring(0,4)]=2,t.splice(s,1))}}});let{AUDIO:g=[],SUBTITLES:m,"CLOSED-CAPTIONS":y}=t7.parseMasterPlaylistMedia(s,a,l);g.length&&(g.some(e=>!e.url)||!c[0].audioCodec||c[0].attrs.AUDIO||(this.hls.logger.log("[playlist-loader]: audio codec signaled in quality level, but no embedded audio track signaled, create one"),g.unshift({type:"main",name:"main",groupId:"main",default:!1,autoselect:!1,forced:!1,id:-1,attrs:new tk({}),bitrate:0,url:""}))),n.trigger(o.MANIFEST_LOADED,{levels:c,audioTracks:g,subtitles:m,captions:y,contentSteering:u,url:a,stats:t,networkDetails:i,sessionData:d,sessionKeys:h,startTimeOffset:f,variableList:p})}handleTrackOrLevelPlaylist(e,t,i,n,s){let a=this.hls,{id:l,level:u,type:c}=i,d=s6(e,i),h=r(u)?u:r(l)?l:0,f=s8(i),p=t7.parseLevelPlaylist(e.data,d,h,f,0,this.variableList);if(c===S){let e={attrs:new tk({}),bitrate:0,details:p,name:"",url:d};p.requestScheduled=t.loading.start+rp(p,0),a.trigger(o.MANIFEST_LOADED,{levels:[e],audioTracks:[],url:d,stats:t,networkDetails:n,sessionData:null,sessionKeys:null,contentSteering:null,startTimeOffset:null,variableList:null})}t.parsing.end=performance.now(),i.levelDetails=p,this.handlePlaylistLoaded(p,e,t,i,n,s)}handleManifestParsingError(e,t,r,i,n){this.hls.trigger(o.ERROR,{type:s.NETWORK_ERROR,details:a.MANIFEST_PARSING_ERROR,fatal:t.type===S,url:e.url,err:r,error:r,reason:r.message,response:e,context:t,networkDetails:i,stats:n})}handleNetworkError(e,t,r=!1,i,n){let l=`A network ${r?"timeout":"error"+(i?" (status "+i.code+")":"")} occurred while loading ${e.type}`;e.type===x?l+=`: ${e.level} id: ${e.id}`:(e.type===T||e.type===w)&&(l+=` id: ${e.id} group-id: "${e.groupId}"`);let u=Error(l);this.hls.logger.warn(`[playlist-loader]: ${l}`);let c=a.UNKNOWN,d=!1,h=this.getInternalLoader(e);switch(e.type){case S:c=r?a.MANIFEST_LOAD_TIMEOUT:a.MANIFEST_LOAD_ERROR,d=!0;break;case x:c=r?a.LEVEL_LOAD_TIMEOUT:a.LEVEL_LOAD_ERROR,d=!1;break;case T:c=r?a.AUDIO_TRACK_LOAD_TIMEOUT:a.AUDIO_TRACK_LOAD_ERROR,d=!1;break;case w:c=r?a.SUBTITLE_TRACK_LOAD_TIMEOUT:a.SUBTITLE_LOAD_ERROR,d=!1}h&&this.resetInternalLoader(e.type);let f={type:s.NETWORK_ERROR,details:c,fatal:d,url:e.url,loader:h,context:e,error:u,networkDetails:t,stats:n};i&&(f.response=O({url:(null==t?void 0:t.url)||e.url,data:void 0},i)),this.hls.trigger(o.ERROR,f)}handlePlaylistLoaded(e,t,r,i,n,l){let u=this.hls,{type:c,level:d,levelOrTrack:h,id:f,groupId:p,deliveryDirectives:g}=i,m=s6(t,i),y=s8(i),v="number"==typeof i.level&&y===A?d:void 0,b=e.playlistParsingError;if(b){if(this.hls.logger.warn(`${b} ${e.url}`),!u.config.ignorePlaylistParsingErrors)return void u.trigger(o.ERROR,{type:s.NETWORK_ERROR,details:a.LEVEL_PARSING_ERROR,fatal:!1,url:m,error:b,reason:b.message,response:t,context:i,level:v,parent:y,networkDetails:n,stats:r});e.playlistParsingError=null}if(!e.fragments.length){let l=e.playlistParsingError=Error("No Segments found in Playlist");u.trigger(o.ERROR,{type:s.NETWORK_ERROR,details:a.LEVEL_EMPTY_ERROR,fatal:!1,url:m,error:l,reason:l.message,response:t,context:i,level:v,parent:y,networkDetails:n,stats:r});return}switch(e.live&&l&&(l.getCacheAge&&(e.ageHeader=l.getCacheAge()||0),(!l.getCacheAge||isNaN(e.ageHeader))&&(e.ageHeader=0)),c){case S:case x:if(v)if(h){if(h!==u.levels[v]){let e=u.levels.indexOf(h);e>-1&&(v=e)}}else v=0;u.trigger(o.LEVEL_LOADED,{details:e,levelInfo:h||u.levels[0],level:v||0,id:f||0,stats:r,networkDetails:n,deliveryDirectives:g,withoutMultiVariant:c===S});break;case T:u.trigger(o.AUDIO_TRACK_LOADED,{details:e,track:h,id:f||0,groupId:p||"",stats:r,networkDetails:n,deliveryDirectives:g});break;case w:u.trigger(o.SUBTITLE_TRACK_LOADED,{details:e,track:h,id:f||0,groupId:p||"",stats:r,networkDetails:n,deliveryDirectives:g})}}}class s9{static get version(){return rH}static isMSESupported(){return s2()}static isSupported(){if(!s2())return!1;let e=U();
2470return"function"==typeof(null==e?void 0:e.isTypeSupported)&&(["avc1.42E01E,mp4a.40.2","av01.0.01M.08","vp09.00.50.08"].some(t=>e.isTypeSupported(ew(t,"video")))||["mp4a.40.2","fLaC"].some(t=>e.isTypeSupported(ew(t,"audio"))))}static getMediaSource(){return U()}static get Events(){return o}static get MetadataSchema(){return r6}static get ErrorTypes(){return s}static get ErrorDetails(){return a}static get DefaultConfig(){return s9.defaultConfig?s9.defaultConfig:sG}static set DefaultConfig(e){s9.defaultConfig=e}constructor(e={}){this.config=void 0,this.userConfig=void 0,this.logger=void 0,this.coreComponents=void 0,this.networkControllers=void 0,this._emitter=new rq,this._autoLevelCapping=-1,this._maxHdcpLevel=null,this.abrController=void 0,this.bufferController=void 0,this.capLevelController=void 0,this.latencyController=void 0,this.levelController=void 0,this.streamController=void 0,this.audioStreamController=void 0,this.subtititleStreamController=void 0,this.audioTrackController=void 0,this.subtitleTrackController=void 0,this.interstitialsController=void 0,this.gapController=void 0,this.emeController=void 0,this.cmcdController=void 0,this._media=null,this._url=null,this._sessionId=void 0,this.triggeringException=void 0,this.started=!1;const t=this.logger=function(e,t,r){let i=M();if("object"==typeof console&&!0===e||"object"==typeof e){let n=["debug","log","info","warn","error"];n.forEach(t=>{i[t]=j(t,e,r)});try{i.log(`Debug logs enabled for "${t}" in hls.js version 1.6.16`)}catch(e){return M()}n.forEach(t=>{$[t]=j(t,e)})}else D($,i);return i}(e.debug||!1,"Hls instance",e.assetPlayerId),r=this.config=function(e,t,r){if((t.liveSyncDurationCount||t.liveMaxLatencyDurationCount)&&(t.liveSyncDuration||t.liveMaxLatencyDuration))throw Error("Illegal hls.js config: don't mix up liveSyncDurationCount/liveMaxLatencyDurationCount and liveSyncDuration/liveMaxLatencyDuration");if(void 0!==t.liveMaxLatencyDurationCount&&(void 0===t.liveSyncDurationCount||t.liveMaxLatencyDurationCount<=t.liveSyncDurationCount))throw Error('Illegal hls.js config: "liveMaxLatencyDurationCount" must be greater than "liveSyncDurationCount"');if(void 0!==t.liveMaxLatencyDuration&&(void 0===t.liveSyncDuration||t.liveMaxLatencyDuration<=t.liveSyncDuration))throw Error('Illegal hls.js config: "liveMaxLatencyDuration" must be greater than "liveSyncDuration"');let i=function e(t){return t&&"object"==typeof t?Array.isArray(t)?t.map(e):Object.keys(t).reduce((r,i)=>(r[i]=e(t[i]),r),{}):t}(e),n=["TimeOut","MaxRetry","RetryDelay","MaxRetryTimeout"];return["manifest","level","frag"].forEach(e=>{let s=`${"level"===e?"playlist":e}LoadPolicy`,a=void 0===t[s],o=[];n.forEach(r=>{let n=`${e}Loading${r}`,l=t[n];if(void 0!==l&&a){o.push(n);let e=i[s].default;switch(t[s]={default:e},r){case"TimeOut":e.maxLoadTimeMs=l,e.maxTimeToFirstByteMs=l;break;case"MaxRetry":e.errorRetry.maxNumRetry=l,e.timeoutRetry.maxNumRetry=l;break;case"RetryDelay":e.errorRetry.retryDelayMs=l,e.timeoutRetry.retryDelayMs=l;break;case"MaxRetryTimeout":e.errorRetry.maxRetryDelayMs=l,e.timeoutRetry.maxRetryDelayMs=l}}}),o.length&&r.warn(`hls.js config: "${o.join('", "')}" setting(s) are deprecated, use "${s}": ${ez(t[s])}`)}),O(O({},i),t)}(s9.DefaultConfig,e,t);this.userConfig=e,r.progressive&&function(e,t){let r=e.loader;r!==sj&&r!==sV?(t.log("[config]: Custom loader detected, cannot enable progressive streaming"),e.progressive=!1):function(){if(self.fetch&&self.AbortController&&self.ReadableStream&&self.Request)try{return new self.ReadableStream({}),!0}catch(e){}return!1}()&&(e.loader=sj,e.progressive=!0,e.enableSoftwareAES=!0,t.log("[config]: Progressive streaming enabled, using FetchLoader"))}(r,t);const{abrController:i,bufferController:n,capLevelController:s,errorController:a,fpsController:l}=r,u=new a(this),c=this.abrController=new i(this),d=new to(this),h=r.interstitialsController,f=h?this.interstitialsController=new h(this,s9):null,p=this.bufferController=new n(this,d),g=this.capLevelController=new s(this),m=new l(this),y=new s7(this),v=r.contentSteeringController,b=v?new v(this):null,_=this.levelController=new sZ(this,b),E=new sX(this),S=new s4(this.config,this.logger),x=this.streamController=new s3(this,d,S),T=this.gapController=new sq(this,d);g.setStreamController(x),m.setStreamController(x);const w=[y,_,x];f&&w.splice(1,0,f),b&&w.splice(1,0,b),this.networkControllers=w;const A=[c,p,T,g,m,E,d];this.audioTrackController=this.createController(r.audioTrackController,w);const R=r.audioStreamController;R&&w.push(this.audioStreamController=new R(this,d,S)),this.subtitleTrackController=this.createController(r.subtitleTrackController,w);const I=r.subtitleStreamController;I&&w.push(this.subtititleStreamController=new I(this,d,S)),this.createController(r.timelineController,A),S.emeController=this.emeController=this.createController(r.emeController,A),this.cmcdController=this.createController(r.cmcdController,A),this.latencyController=this.createController(sJ,A),this.coreComponents=A,w.push(u);const k=u.onErrorOut;"function"==typeof k&&this.on(o.ERROR,k,u),this.on(o.MANIFEST_LOADED,y.onManifestLoaded,y)}createController(e,t){if(e){let r=new e(this);return t&&t.push(r),r}return null}on(e,t,r=this){this._emitter.on(e,t,r)}once(e,t,r=this){this._emitter.once(e,t,r)}removeAllListeners(e){this._emitter.removeAllListeners(e)}
2470off(e,t,r=this,i){this._emitter.off(e,t,r,i)}listeners(e){return this._emitter.listeners(e)}emit(e,t,r){return this._emitter.emit(e,t,r)}trigger(e,t){if(this.config.debug)return this.emit(e,e,t);try{return this.emit(e,e,t)}catch(t){if(this.logger.error("An internal error happened while handling event "+e+'. Error message: "'+t.message+'". Here is a stacktrace:',t),!this.triggeringException){this.triggeringException=!0;let r=e===o.ERROR;this.trigger(o.ERROR,{type:s.OTHER_ERROR,details:a.INTERNAL_EXCEPTION,fatal:r,event:e,error:t}),this.triggeringException=!1}}return!1}listenerCount(e){return this._emitter.listenerCount(e)}destroy(){this.logger.log("destroy"),this.trigger(o.DESTROYING,void 0),this.detachMedia(),this.removeAllListeners(),this._autoLevelCapping=-1,this._url=null,this.networkControllers.forEach(e=>e.destroy()),this.networkControllers.length=0,this.coreComponents.forEach(e=>e.destroy()),this.coreComponents.length=0;let e=this.config;e.xhrSetup=e.fetchSetup=void 0,this.userConfig=null}attachMedia(e){if(!e||"media"in e&&!e.media){let t=Error(`attachMedia failed: invalid argument (${e})`);this.trigger(o.ERROR,{type:s.OTHER_ERROR,details:a.ATTACH_MEDIA_ERROR,fatal:!0,error:t});return}this.logger.log("attachMedia"),this._media&&(this.logger.warn("media must be detached before attaching"),this.detachMedia());let t="media"in e,r=t?e.media:e,i=t?e:{media:r};this._media=r,this.trigger(o.MEDIA_ATTACHING,i)}detachMedia(){this.logger.log("detachMedia"),this.trigger(o.MEDIA_DETACHING,{}),this._media=null}transferMedia(){this._media=null;let e=this.bufferController.transferMedia();return this.trigger(o.MEDIA_DETACHING,{transferMedia:e}),e}loadSource(e){this.stopLoad();let t=this.media,r=this._url,i=this._url=z.buildAbsoluteURL(self.location.href,e,{alwaysNormalize:!0});this._autoLevelCapping=-1,this._maxHdcpLevel=null,this.logger.log(`loadSource:${i}`),t&&r&&(r!==i||this.bufferController.hasSourceTypes())&&(this.detachMedia(),this.attachMedia(t)),this.trigger(o.MANIFEST_LOADING,{url:e})}get url(){return this._url}get hasEnoughToStart(){return this.streamController.hasEnoughToStart}get startPosition(){return this.streamController.startPositionValue}startLoad(e=-1,t){this.logger.log(`startLoad(${e+(t?", <skip seek to start>":"")})`),this.started=!0,this.resumeBuffering();for(let r=0;r<this.networkControllers.length&&(this.networkControllers[r].startLoad(e,t),this.started&&this.networkControllers);r++);}stopLoad(){this.logger.log("stopLoad"),this.started=!1;for(let e=0;e<this.networkControllers.length&&(this.networkControllers[e].stopLoad(),!this.started&&this.networkControllers);e++);}get loadingEnabled(){return this.started}get bufferingEnabled(){return this.streamController.bufferingEnabled}resumeBuffering(){this.bufferingEnabled||(this.logger.log("resume buffering"),this.networkControllers.forEach(e=>{e.resumeBuffering&&e.resumeBuffering()}))}pauseBuffering(){this.bufferingEnabled&&(this.logger.log("pause buffering"),this.networkControllers.forEach(e=>{e.pauseBuffering&&e.pauseBuffering()}))}get inFlightFragments(){let e={[A]:this.streamController.inFlightFrag};return this.audioStreamController&&(e[R]=this.audioStreamController.inFlightFrag),this.subtititleStreamController&&(e[I]=this.subtititleStreamController.inFlightFrag),e}swapAudioCodec(){this.logger.log("swapAudioCodec"),this.streamController.swapAudioCodec()}recoverMediaError(){this.logger.log("recoverMediaError");let e=this._media,t=null==e?void 0:e.currentTime;this.detachMedia(),e&&(this.attachMedia(e),t&&this.startLoad(t))}removeLevel(e){this.levelController.removeLevel(e)}get sessionId(){let e=this._sessionId;return e||(e=this._sessionId=function(){try{return crypto.randomUUID()}catch(e){try{let e=URL.createObjectURL(new Blob),t=e.toString();return URL.revokeObjectURL(e),t.slice(t.lastIndexOf("/")+1)}catch(t){let e=new Date().getTime();return"xxxxxxxx-xxxx-4xxx-yxxx-xxxxxxxxxxxx".replace(/[xy]/g,t=>{let r=(e+16*Math.random())%16|0;return e=Math.floor(e/16),("x"==t?r:3&r|8).toString(16)})}}}()),e}get levels(){return this.levelController.levels||[]}get latestLevelDetails(){return this.streamController.getLevelDetails()||null}get loadLevelObj(){return this.levelController.loadLevelObj}get currentLevel(){return this.streamController.currentLevel}set currentLevel(e){this.logger.log(`set currentLevel:${e}`),this.levelController.manualLevel=e,this.streamController.immediateLevelSwitch()}get nextLevel(){return this.streamController.nextLevel}set nextLevel(e){this.logger.log(`set nextLevel:${e}`),this.levelController.manualLevel=e,this.streamController.nextLevelSwitch()}get loadLevel(){return this.levelController.level}set loadLevel(e){this.logger.log(`set loadLevel:${e}`),this.levelController.manualLevel=e}get nextLoadLevel(){return this.levelController.nextLoadLevel}set nextLoadLevel(e){this.levelController.nextLoadLevel=e}get firstLevel(){return Math.max(this.levelController.firstLevel,this.minAutoLevel)}set firstLevel(e){this.logger.log(`set firstLevel:${e}`),this.levelController.firstLevel=e}get startLevel(){let e=this.levelController.startLevel;return -1===e&&this.abrController.forcedAutoLevel>-1?this.abrController.forcedAutoLevel:e}set startLevel(e){this.logger.log(`set startLevel:${e}`),-1!==e&&(e=Math.max(e,this.minAutoLevel)),this.levelController.startLevel=e}get capLevelToPlayerSize(){return this.config.capLevelToPlayerSize}set capLevelToPlayerSize(e){let t=!!e;t!==this.config.capLevelToPlayerSize&&(t?this.capLevelController.startCapping():(this.capLevelController.stopCapping(),this.autoLevelCapping=-1,this.streamController.nextLevelSwitch()),this.config.capLevelToPlayerSize=t)}get autoLevelCapping(){return this._autoLevelCapping}get bandwidthEstimate(){let{bwEstimator:e}=this.abrController;return e?e.getEstimate():NaN}set bandwidthEstimate(e){this.abrController.resetEstimator(e)}get abrEwmaDefaultEstimate(){let{bwEstimator:e}=this.abrController;return e?e.defaultEstimate:NaN}get ttfbEstimate(){let{bwEstimator:e}=this.abrController;return e?e.getEstimateTTFB():NaN}set autoLevelCapping(e){this._autoLevelCapping!==e&&(this.logger.log(`set autoLevelCapping:${e}`),this._autoLevelCapping=e,this.levelController.checkMaxAutoUpdated())}get maxHdcpLevel(){return this._maxHdcpLevel}set maxHdcpLevel(e){eU.indexOf(e)>-1&&this._maxHdcpLevel!==e&&(this._maxHdcpLevel=e,this.levelController.checkMaxAutoUpdated())}get autoLevelEnabled(){return -1===this.levelController.manualLevel}get manualLevel(){return this.levelController.manualLevel}get minAutoLevel(){let{levels:e,config:{minAutoBitrate:t}}=this;if(!e)return 0;let r=e.length;for(let i=0;i<r;i++)if(e[i].maxBitrate>=t)return i;return 0}get maxAutoLevel(){let e,{levels:t,autoLevelCapping:r,maxHdcpLevel:i}=this;if(e=-1===r&&null!=t&&t.length?t.length-1:r,i)for(let r=e;r--;){let e=t[r].attrs["HDCP-LEVEL"];if(e&&e<=i)return r}return e}get firstAutoLevel(){return this.abrController.firstAutoLevel}get nextAutoLevel(){return this.abrController.nextAutoLevel}set nextAutoLevel(e){this.abrController.nextAutoLevel=e}get playingDate(){return this.streamController.currentProgramDateTime}get mainForwardBufferInfo(){return this.streamController.getMainFwdBufferInfo()}get maxBufferLength(){return this.streamController.maxBufferLength}setAudioOption(e){var t;return(null==(t=this.audioTrackController)?void 0:t.setAudioOption(e))||null}
2470setSubtitleOption(e){var t;return(null==(t=this.subtitleTrackController)?void 0:t.setSubtitleOption(e))||null}get allAudioTracks(){let e=this.audioTrackController;return e?e.allAudioTracks:[]}get audioTracks(){let e=this.audioTrackController;return e?e.audioTracks:[]}get audioTrack(){let e=this.audioTrackController;return e?e.audioTrack:-1}set audioTrack(e){let t=this.audioTrackController;t&&(t.audioTrack=e)}get allSubtitleTracks(){let e=this.subtitleTrackController;return e?e.allSubtitleTracks:[]}get subtitleTracks(){let e=this.subtitleTrackController;return e?e.subtitleTracks:[]}get subtitleTrack(){let e=this.subtitleTrackController;return e?e.subtitleTrack:-1}get media(){return this._media}set subtitleTrack(e){let t=this.subtitleTrackController;t&&(t.subtitleTrack=e)}get subtitleDisplay(){let e=this.subtitleTrackController;return!!e&&e.subtitleDisplay}set subtitleDisplay(e){let t=this.subtitleTrackController;t&&(t.subtitleDisplay=e)}get lowLatencyMode(){return this.config.lowLatencyMode}set lowLatencyMode(e){this.config.lowLatencyMode=e}get liveSyncPosition(){return this.latencyController.liveSyncPosition}get latency(){return this.latencyController.latency}get maxLatency(){return this.latencyController.maxLatency}get targetLatency(){return this.latencyController.targetLatency}set targetLatency(e){this.latencyController.targetLatency=e}get drift(){return this.latencyController.drift}get forceStartLoad(){return this.streamController.forceStartLoad}get pathways(){return this.levelController.pathways}get pathwayPriority(){return this.levelController.pathwayPriority}set pathwayPriority(e){this.levelController.pathwayPriority=e}get bufferedToEnd(){var e;return!!(null!=(e=this.bufferController)&&e.bufferedToEnd)}get interstitialsManager(){var e;return(null==(e=this.interstitialsController)?void 0:e.interstitialsManager)||null}getMediaDecodingInfo(e,t=this.allAudioTracks){return ej(e,eW(t),navigator.mediaCapabilities)}}s9.defaultConfig=void 0,e.s(["getHLSVideo",0,function(e,t,r=!1){if(e){let i=document.getElementById(t);if(i&&"video"==i.tagName.toLowerCase()){if(s9.isSupported()){this&&!r&&this.destroy();let t=new s9({autoStartLoad:"none"!==i.preload});if(t.loadSource(e),t.attachMedia(i),"none"===i.preload){let e=()=>{t.startLoad(),i.removeEventListener("play",e)};i.addEventListener("play",e)}return t}i.canPlayType("application/vnd.apple.mpegurl")&&(i.src=e)}}}],345915)},760207,e=>{"use strict";var t=e.i(843476),r=e.i(271645),i=e.i(997053),n=e.i(259087),s=e.i(607135),a=e.i(94332),o=e.i(535289);let l=i.default.div.withConfig({displayName:"RichText__Wrapper",componentId:"sc-9c7984-0"})` 2471 width: 100%; 2472 ${e=>!e.withoutBottomMargin&&"margin-bottom: 4rem;"}; 2473 ${e=>e.withTopMargin&&"margin-top: 4rem;"} 2474 ${e=>(e.simple||!e.withPhotos)&&"max-width: 50rem"}; 2475`,u=i.default.div.withConfig({displayName:"RichText__Box",componentId:"sc-9c7984-1"})` 2476 width: 100%; 2477 position: relative; 2478 ${e=>!e.simple&&i.css` 2479 padding: 3.5rem 2.5rem; 2480 margin: 0 auto; 2481 border: 1px solid ${e=>e.theme.color.gold}; 2482 2483 ${a.mq.sm} { 2484 padding: 5.5rem 7.5rem; 2485 } 2486 2487 ${a.mq.lg} { 2488 padding: 8.25rem 11rem; 2489 } 2490 `}; 2491`,c=(0,i.default)(o.Image).withConfig({displayName:"RichText__CustomImage",componentId:"sc-9c7984-2"})` 2492 height: auto; 2493 width: calc(${e=>e.customOrder%2==0?"32.56vw":"23.74vw"} + 4.5rem); 2494 max-width: ${e=>e.isWide?28:15.5}rem; 2495 ${e=>e.customOrder%2==0&&i.css` 2496 align-self: flex-end; 2497 transform: translate(calc(100% - 4.5rem), -2rem); 2498 `||e.customOrder%2!=0&&i.css` 2499 align-self: flex-start; 2500 transform: translate(calc(-100% + 4.5rem), -4.5rem); 2501 `}; 2502`,d=i.default.div.withConfig({displayName:"RichText__ImageWrapper",componentId:"sc-9c7984-3"})` 2503 display: flex; 2504 flex-direction: column; 2505 justify-content: space-between; 2506 width: 100%; 2507 height: 100%; 2508 position: absolute; 2509 top: 0; 2510 left: 0; 2511 pointer-events: none; 2512 2513 ${a.mq.smmax} { 2514 display: none; 2515 } 2516`,h=i.default.div.withConfig({displayName:"RichText__Content",componentId:"sc-9c7984-4"})` 2517 h1 { 2518 margin-bottom: ${e=>e.theme.gap.md}; 2519 font-size: ${e=>e.theme.fz.lg}; 2520 color: ${e=>e.theme.color.gold}; 2521 font-family: var(--font-din-serif, serif); 2522 font-weight: 700; 2523 } 2524`,f=(e,t)=>Math.floor(e/t*100)/100;e.s(["RichText",0,({content:e,images:i,simple:a,withTopMargin:o,withoutBottomMargin:p,extraElements:g,headingLevelQueue:m,...y})=>{let v=(0,r.useRef)(null),b=(0,r.useRef)(null),[_,E]=(0,r.useState)(0);(0,r.useEffect)(()=>{let e,t,r,n;e=0,t=0,v&&v.current&&(t=v.current.clientHeight),b&&b.current&&(e=b.current.clientHeight),r=0,n=e-t,i&&i.map(e=>{let t=f(e.width,e.height);(n-=t>1.3?448/t:248/t)>0&&r++}),E(r)},[i]);let S=m??(0,s.precomputeRichTextHeadingLevels)((0,s.extractHeadingLevels)(e),{hasH1:!0,lastLevel:1});return s.parserOptions.headingLevelQueue=[...S],(0,t.jsx)(l,{withTopMargin:o,withoutBottomMargin:p,simple:a,withPhotos:i&&i.length>0,...y,children:(0,t.jsxs)(u,{ref:b,simple:a,children:[(0,t.jsx)(h,{children:(0,n.default)(e,s.parserOptions)}),g,_>0&&(0,t.jsx)(d,{children:i?.map((e,r)=>{let i=f(e.width,e.height)>1.3;if(r<_)return(0,t.jsx)(c,{customOrder:r,src:e.url,width:i?448:248,fit:"max",isWide:i},r)})})]})})}])},208049,207340,e=>{"use strict";let t="[object global]"===({}).toString.call(e.g),r="u">typeof Bun,i="u">typeof Deno,n="function"==typeof WebSocketPair&&void 0!==caches?.default,s=t||r||i||n;function a(e,t){return 0===e.indexOf(t.toLowerCase())?e:`${t.toLowerCase()}${e.substr(0,1).toUpperCase()}${e.substr(1)}`}function o(e){return/^(https?:)?\/\/((((player|www)\.)?vimeo\.com)|((player\.)?[a-zA-Z0-9-]+\.(videoji\.(hk|cn)|vimeo\.work)))(?=$|\/)/.test(e)}function l(e){return/^https:\/\/player\.((vimeo\.com)|([a-zA-Z0-9-]+\.(videoji\.(hk|cn)|vimeo\.work)))\/video\/\d+/.test(e)}function u(){let e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{},t=e.id,r=e.url,i=t||r;if(!i)throw Error("An id or url must be passed, either in an options object or as a data-vimeo-id or data-vimeo-url attribute.");if(!isNaN(parseFloat(i))&&isFinite(i)&&Math.floor(i)==i)return`https://vimeo.com/${i}`;if(o(i))return i.replace("http:","https:");if(t)throw TypeError(`â${t}â is not a valid video id.`);throw TypeError(`â${i}â is not a vimeo.com url.`)}let c=function(e,t,r){let i=arguments.length>3&&void 0!==arguments[3]?arguments[3]:"addEventListener",n=arguments.length>4&&void 0!==arguments[4]?arguments[4]:"removeEventListener",s="string"==typeof t?[t]:t;
vendor: 5,257 bytes, line 2524
2524return s.forEach(t=>{e[i](t,r)}),{cancel:()=>s.forEach(t=>e[n](t,r))}};function d(e){let t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:document;if(!e||!t||"function"!=typeof t.querySelectorAll)return null;let r=t.querySelectorAll("iframe");for(let t=0;t<r.length;t++)if(r[t]&&r[t].contentWindow===e)return r[t];return null}let h=void 0!==Array.prototype.indexOf,f="u">typeof window&&void 0!==window.postMessage;if(!s&&(!h||!f))throw Error("Sorry, the Vimeo Player API is not available in this browser.");var p,g="u">typeof globalThis?globalThis:"u">typeof window?window:e.g;!function(e){if(!e.WeakMap){var t=Object.prototype.hasOwnProperty,r=Object.defineProperty&&function(){try{return 1===Object.defineProperty({},"x",{value:1}).x}catch(e){}}(),i=function(e,t,i){r?Object.defineProperty(e,t,{configurable:!0,writable:!0,value:i}):e[t]=i};e.WeakMap=function(){function e(){if(void 0===this)throw TypeError("Constructor WeakMap requires 'new'");if(i(this,"_id","_WeakMap_"+s()+"."+s()),arguments.length>0)throw TypeError("WeakMap iterable is not supported")}function r(e,r){if(!n(e)||!t.call(e,"_id"))throw TypeError(r+" method called on incompatible receiver "+typeof e)}function s(){return Math.random().toString().substring(2)}return i(e.prototype,"delete",function(e){if(r(this,"delete"),!n(e))return!1;var t=e[this._id];return!!t&&t[0]===e&&(delete e[this._id],!0)}),i(e.prototype,"get",function(e){if(r(this,"get"),n(e)){var t=e[this._id];if(t&&t[0]===e)return t[1]}}),i(e.prototype,"has",function(e){if(r(this,"has"),!n(e))return!1;var t=e[this._id];return!!t&&t[0]===e}),i(e.prototype,"set",function(e,t){if(r(this,"set"),!n(e))throw TypeError("Invalid value used as weak map key");var s=e[this._id];return s&&s[0]===e?s[1]=t:i(e,this._id,[e,t]),this}),i(e,"_polyfill",!0),e}()}function n(e){return Object(e)===e}}("u">typeof globalThis?globalThis:"u">typeof self?self:"u">typeof window?window:g);var m=(function(e){var t;t="Promise",g[t]=g[t]||function(){var e,t,r,i=Object.prototype.toString,n="u">typeof setImmediate?function(e){return setImmediate(e)}:setTimeout;try{Object.defineProperty({},"x",{}),e=function(e,t,r,i){return Object.defineProperty(e,t,{value:r,writable:!0,configurable:!1!==i})}}catch(t){e=function(e,t,r){return e[t]=r,e}}function s(e,i){r.add(e,i),t||(t=n(r.drain))}function a(e){var t,r=typeof e;return null!=e&&("object"==r||"function"==r)&&(t=e.then),"function"==typeof t&&t}function o(){for(var e=0;e<this.chain.length;e++)!function(e,t,r){var i,n;try{!1===t?r.reject(e.msg):(i=!0===t?e.msg:t.call(void 0,e.msg))===r.promise?r.reject(TypeError("Promise-chain cycle")):(n=a(i))?n.call(i,r.resolve,r.reject):r.resolve(i)}catch(e){r.reject(e)}}(this,1===this.state?this.chain[e].success:this.chain[e].failure,this.chain[e]);this.chain.length=0}function l(e){var t,r=this;if(!r.triggered){r.triggered=!0,r.def&&(r=r.def);try{(t=a(e))?s(function(){var i=new d(r);try{t.call(e,function(){l.apply(i,arguments)},function(){u.apply(i,arguments)})}catch(e){u.call(i,e)}}):(r.msg=e,r.state=1,r.chain.length>0&&s(o,r))}catch(e){u.call(new d(r),e)}}}function u(e){var t=this;!t.triggered&&(t.triggered=!0,t.def&&(t=t.def),t.msg=e,t.state=2,t.chain.length>0&&s(o,t))}function c(e,t,r,i){for(var n=0;n<t.length;n++)!function(n){e.resolve(t[n]).then(function(e){r(n,e)},i)}(n)}function d(e){this.def=e,this.triggered=!1}function h(e){this.promise=e,this.state=0,this.triggered=!1,this.chain=[],this.msg=void 0}function f(e){if("function"!=typeof e)throw TypeError("Not a function");if(0!==this.__NPO__)throw TypeError("Not a promise");this.__NPO__=1;var t=new h(this);this.then=function(e,r){var i={success:"function"!=typeof e||e,failure:"function"==typeof r&&r};return i.promise=new this.constructor(function(e,t){if("function"!=typeof e||"function"!=typeof t)throw TypeError("Not a function");i.resolve=e,i.reject=t}),t.chain.push(i),0!==t.state&&s(o,t),i.promise},this.catch=function(e){return this.then(void 0,e)};try{e.call(void 0,function(e){l.call(t,e)},function(e){u.call(t,e)})}catch(e){u.call(t,e)}}r=function(){var e,r,i;function n(e,t){this.fn=e,this.self=t,this.next=void 0}return{add:function(t,s){i=new n(t,s),r?r.next=i:e=i,r=i,i=void 0},drain:function(){var i=e;for(e=r=t=void 0;i;)i.fn.call(i.self),i=i.next}}}();var p=e({},"constructor",f,!1);return f.prototype=p,e(p,"__NPO__",0,!1),e(f,"resolve",function(e){return e&&"object"==typeof e&&1===e.__NPO__?e:new this(function(t,r){if("function"!=typeof t||"function"!=typeof r)throw TypeError("Not a function");t(e)})}),e(f,"reject",function(e){return new this(function(t,r){if("function"!=typeof t||"function"!=typeof r)throw TypeError("Not a function");r(e)})}),e(f,"all",function(e){var t=this;return"[object Array]"!=i.call(e)?t.reject(TypeError("Not an array")):0===e.length?t.resolve([]):new t(function(r,i){if("function"!=typeof r||"function"!=typeof i)throw TypeError("Not a function");var n=e.length,s=Array(n),a=0;c(t,e,function(e,t){s[e]=t,++a===n&&r(s)},i)})}),e(f,"race",function(e){var t=this;return"[object Array]"!=i.call(e)?t.reject(TypeError("Not an array")):new t(function(r,i){if("function"!=typeof r||"function"!=typeof i)throw TypeError("Not a function");c(t,e,function(e,t){r(t)},i)})}),f}(),e.exports&&(e.exports=g[t])}(p={exports:{}}
2524,p.exports),p.exports);let y=new WeakMap;function v(e,t,r){let i=y.get(e.element)||{};t in i||(i[t]=[]),i[t].push(r),y.set(e.element,i)}function b(e,t){return(y.get(e.element)||{})[t]||[]}function _(e,t,r){let i=y.get(e.element)||{};if(!i[t])return!0;if(!r)return i[t]=[],y.set(e.element,i),!0;let n=i[t].indexOf(r);return -1!==n&&i[t].splice(n,1),y.set(e.element,i),i[t]&&0===i[t].length}function E(e){if("string"==typeof e)try{e=JSON.parse(e)}catch(e){return console.warn(e),{}}return e}function S(e,t,r){if(!e.element.contentWindow||!e.element.contentWindow.postMessage)return;let i={method:t};void 0!==r&&(i.value=r);let n=parseFloat(navigator.userAgent.toLowerCase().replace(/^.*msie (\d+).*$/,"$1"));n>=8&&n<10&&(i=JSON.stringify(i)),e.element.contentWindow.postMessage(i,e.origin)}let x=["airplay","audio_tracks","audiotrack","autopause","autoplay","background","byline","cc","chapter_id","chapters","chromecast","color","colors","controls","disable_context_menu","dnt","end_time","fullscreen","height","id","initial_quality","interactive_params","keyboard","loop","maxheight","max_quality","maxwidth","min_quality","muted","play_button_position","playsinline","portrait","preload","progress_bar","quality","quality_selector","responsive","skipping_forward","speed","start_time","texttrack","thumbnail_id","title","transcript","transparent","unmute_button","url","vimeo_logo","volume","watch_full_video","width"];function T(e){let t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{};return x.reduce((t,r)=>{let i=e.getAttribute(`data-vimeo-${r}`);return(i||""===i)&&(t[r]=""===i?1:i),t},t)}function w(e,t){let{html:r}=e;if(!t)throw TypeError("An element must be provided");if(null!==t.getAttribute("data-vimeo-initialized"))return t.querySelector("iframe");let i=document.createElement("div");return i.innerHTML=r,t.appendChild(i.firstChild),t.setAttribute("data-vimeo-initialized","true"),t.querySelector("iframe")}function A(e){let t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{},r=arguments.length>2?arguments[2]:void 0;return new Promise((i,n)=>{if(!o(e))throw TypeError(`â${e}â is not a vimeo.com url.`);let s=function(e){let t=(e||"").match(/^(?:https?:)?(?:\/\/)?([^/?]+)/),r=(t&&t[1]||"").replace("player.","");for(let e of[".videoji.hk",".vimeo.work",".videoji.cn"])if(r.endsWith(e))return r;return"vimeo.com"}(e),a=`https://${s}/api/oembed.json?url=${encodeURIComponent(e)}`;for(let e in t)t.hasOwnProperty(e)&&(a+=`&${e}=${encodeURIComponent(t[e])}`);let l="XDomainRequest"in window?new XDomainRequest:new XMLHttpRequest;l.open("GET",a,!0),l.onload=function(){if(404===l.status)return void n(Error(`â${e}â was not found.`));if(403===l.status)return void n(Error(`â${e}â is not embeddable.`));try{let t=JSON.parse(l.responseText);if(403===t.domain_status_code){w(t,r),n(Error(`â${e}â is not embeddable.`));return}i(t)}catch(e){n(e)}},l.onerror=function(){let e=l.status?` (${l.status})`:"";n(Error(`There was an error fetching the embed code from Vimeo${e}.`))},l.send()})}let R={role:"viewer",autoPlayMuted:!0,allowedDrift:.3,maxAllowedDrift:1,minCheckInterval:.1,maxRateAdjustment:.2,maxTimeToCatchUp:1};class I extends EventTarget{logger;constructor(e,t){let r=arguments.length>2&&void 0!==arguments[2]?arguments[2]:{},i=arguments.length>3?arguments[3]:void 0;super(),this.logger=i,this.init(t,e,{...R,...r})}disconnect(){this.dispatchEvent(new Event("disconnect"))}async init(e,t,r){if(await this.waitForTOReadyState(e,"open"),"viewer"===r.role){await this.updatePlayer(e,t,r);let i=c(e,"change",()=>this.updatePlayer(e,t,r)),n=this.maintainPlaybackPosition(e,t,r);this.addEventListener("disconnect",()=>{n.cancel(),i.cancel()})}else{await this.updateTimingObject(e,t);let r=c(t,["seeked","play","pause","ratechange"],()=>this.updateTimingObject(e,t),"on","off");this.addEventListener("disconnect",()=>r.cancel())}}async updateTimingObject(e,t){let[r,i,n]=await Promise.all([t.getCurrentTime(),t.getPaused(),t.getPlaybackRate()]);e.update({position:r,velocity:i?0:n})}async updatePlayer(e,t,r){let{position:i,velocity:n}=e.query();"number"==typeof i&&t.setCurrentTime(i),"number"==typeof n&&(0===n?await t.getPaused()===!1&&t.pause():n>0&&(await t.getPaused()===!0&&(await t.play().catch(async e=>{"NotAllowedError"===e.name&&r.autoPlayMuted&&(await t.setMuted(!0),await t.play().catch(e=>console.error("Couldn't play the video from TimingSrcConnector. Error:",e)))}),this.updatePlayer(e,t,r)),await t.getPlaybackRate()!==n&&t.setPlaybackRate(n)))}maintainPlaybackPosition(e,t,r){let{allowedDrift:i,maxAllowedDrift:n,minCheckInterval:s,maxRateAdjustment:a,maxTimeToCatchUp:o}=r,l=async()=>
2524{if(0===e.query().velocity||await t.getPaused()===!0)return;let r=e.query().position-await t.getCurrentTime(),s=Math.abs(r);if(this.log(`Drift: ${r}`),s>n)await this.adjustSpeed(t,0),t.setCurrentTime(e.query().position),this.log("Resync by currentTime");else if(s>i){let e=s/o;await this.adjustSpeed(t,(e<a?(a-e)/2:a)*Math.sign(r)),this.log("Resync by playbackRate")}},u=setInterval(()=>l(),1e3*Math.min(o,Math.max(s,n)));return{cancel:()=>clearInterval(u)}}log(e){this.logger?.(`TimingSrcConnector: ${e}`)}speedAdjustment=0;adjustSpeed=async(e,t)=>{if(this.speedAdjustment===t)return;let r=await e.getPlaybackRate()-this.speedAdjustment+t;this.log(`New playbackRate: ${r}`),await e.setPlaybackRate(r),this.speedAdjustment=t};waitForTOReadyState(e,t){return new Promise(r=>{let i=()=>{e.readyState===t?r():e.addEventListener("readystatechange",i,{once:!0})};i()})}}let k=new WeakMap,C=new WeakMap,D={};class L{constructor(e){let t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{};if(window.jQuery&&e instanceof jQuery&&(e.length>1&&window.console&&console.warn&&console.warn("A jQuery object with multiple elements was passed, using the first element."),e=e[0]),"u">typeof document&&"string"==typeof e&&(e=document.getElementById(e)),!function(e){return!!(e&&1===e.nodeType&&"nodeName"in e&&e.ownerDocument&&e.ownerDocument.defaultView)}(e))throw TypeError("You must pass either a valid element or a valid id.");if("IFRAME"!==e.nodeName){const t=e.querySelector("iframe");t&&(e=t)}if("IFRAME"===e.nodeName&&!o(e.getAttribute("src")||""))throw Error("The player element passed isnât a Vimeo embed.");if(k.has(e))return k.get(e);this._window=e.ownerDocument.defaultView,this.element=e,this.origin="*";const r=new m((r,i)=>{if(this._onMessage=e=>{if(!o(e.origin)||this.element.contentWindow!==e.source)return;"*"===this.origin&&(this.origin=e.origin);let t=E(e.data);if(t&&"error"===t.event&&t.data&&"ready"===t.data.method){let e=Error(t.data.message);e.name=t.data.name,i(e);return}let n=t&&"ready"===t.event,s=t&&"ping"===t.method;if(n||s){this.element.setAttribute("data-ready","true"),r();return}!function(e,t){let r;t=E(t);let i=[];if(t.event)"error"===t.event&&b(e,t.data.method).forEach(r=>{let i=Error(t.data.message);i.name=t.data.name,r.reject(i),_(e,t.data.method,r)}),i=b(e,`event:${t.event}`),r=t.data;
2524else if(t.method){let n=function(e,t){let r=b(e,t);if(r.length<1)return!1;let i=r.shift();return _(e,t,i),i}(e,t.method);n&&(i.push(n),r=t.value)}i.forEach(t=>{try{if("function"==typeof t)return void t.call(e,r);t.resolve(r)}catch(e){}})}(this,t)},this._window.addEventListener("message",this._onMessage),"IFRAME"!==this.element.nodeName){let r=T(e,t);A(u(r),r,e).then(t=>{var r;let i,n=w(t,e);return this.element=n,this._originalElement=e,r=e,i=y.get(r),y.set(n,i),y.delete(r),k.set(this.element,this),t}).catch(i)}});if(C.set(this,r),k.set(this.element,this),"IFRAME"===this.element.nodeName&&S(this,"ping"),D.isEnabled){const e=()=>D.exit();this.fullscreenchangeHandler=()=>{D.isFullscreen?v(this,"event:exitFullscreen",e):_(this,"event:exitFullscreen",e),this.ready().then(()=>{S(this,"fullscreenchange",D.isFullscreen)})},D.on("fullscreenchange",this.fullscreenchangeHandler)}return this}static isVimeoUrl(e){return o(e)}callMethod(e){for(var t=arguments.length,r=Array(t>1?t-1:0),i=1;i<t;i++)r[i-1]=arguments[i];if(null==e)throw TypeError("You must pass a method name.");return new m((t,i)=>this.ready().then(()=>{v(this,e,{resolve:t,reject:i}),0===r.length?r={}:1===r.length&&(r=r[0]),S(this,e,r)}).catch(i))}get(e){return new m((t,r)=>(e=a(e,"get"),this.ready().then(()=>{v(this,e,{resolve:t,reject:r}),S(this,e)}).catch(r)))}set(e,t){return new m((r,i)=>{if(e=a(e,"set"),null==t)throw TypeError("There must be a value to set.");return this.ready().then(()=>{v(this,e,{resolve:r,reject:i}),S(this,e,t)}).catch(i)})}on(e,t){if(!e)throw TypeError("You must pass an event name.");if(!t)throw TypeError("You must pass a callback function.");if("function"!=typeof t)throw TypeError("The callback must be a function.");0===b(this,`event:${e}`).length&&this.callMethod("addEventListener",e).catch(()=>{}),v(this,`event:${e}`,t)}off(e,t){if(!e)throw TypeError("You must pass an event name.");if(t&&"function"!=typeof t)throw TypeError("The callback must be a function.");_(this,`event:${e}`,t)&&this.callMethod("removeEventListener",e).catch(e=>{})}loadVideo(e){return this.callMethod("loadVideo",e)}ready(){let e=C.get(this)||new m((e,t)=>{t(Error("Unknown player. Probably unloaded."))});return m.resolve(e)}addCuePoint(e){let t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{};return this.callMethod("addCuePoint",{time:e,data:t})}removeCuePoint(e){return this.callMethod("removeCuePoint",e)}enableTextTrack(e){let t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:null,r=!(arguments.length>2)||void 0===arguments[2]||arguments[2];if(!e)throw TypeError("You must pass a language.");return this.callMethod("enableTextTrack",{language:e,kind:t,showing:r})}disableTextTrack(){return this.callMethod("disableTextTrack")}selectAudioTrack(e,t){if(!e)throw TypeError("You must pass a language.");return this.callMethod("selectAudioTrack",{language:e,kind:t})}selectDefaultAudioTrack(){return this.callMethod("selectDefaultAudioTrack")}pause(){return this.callMethod("pause")}play(){return this.callMethod("play")}requestFullscreen(){return D.isEnabled?D.request(this.element):this.callMethod("requestFullscreen")}exitFullscreen(){return D.isEnabled?D.exit():this.callMethod("exitFullscreen")}getFullscreen(){return D.isEnabled?m.resolve(D.isFullscreen):this.get("fullscreen")}requestPictureInPicture(){return this.callMethod("requestPictureInPicture")}exitPictureInPicture(){return this.callMethod("exitPictureInPicture")}getPictureInPicture(){return this.get("pictureInPicture")}remotePlaybackPrompt(){return this.callMethod("remotePlaybackPrompt")}unload(){return this.callMethod("unload")}destroy(){return new m(e=>{if(C.delete(this),k.delete(this.element),this._originalElement&&(k.delete(this._originalElement),this._originalElement.removeAttribute("data-vimeo-initialized")),this.element&&"IFRAME"===this.element.nodeName&&this.element.parentNode&&(this.element.parentNode.parentNode&&this._originalElement&&this._originalElement!==this.element.parentNode?this.element.parentNode.parentNode.removeChild(this.element.parentNode):this.element.parentNode.removeChild(this.element)),this.element&&"DIV"===this.element.nodeName&&this.element.parentNode){this.element.removeAttribute("data-vimeo-initialized");let e=this.element.querySelector("iframe");e&&e.parentNode&&(e.parentNode.parentNode&&this._originalElement&&this._originalElement!==e.parentNode?e.parentNode.parentNode.removeChild(e.parentNode):e.parentNode.removeChild(e))}this._window.removeEventListener("message",this._onMessage),D.isEnabled&&D.off("fullscreenchange",this.fullscreenchangeHandler),e()})}getAutopause(){return this.get("autopause")}setAutopause(e){return this.set("autopause",e)}getBuffered(){return this.get("buffered")}getCameraProps(){return this.get("cameraProps")}setCameraProps(e){return this.set("cameraProps",e)}getChapters(){return this.get("chapters")}getCurrentChapter(){return this.get("currentChapter")}getColor(){return this.get("color")}getColors(){return m.all([this.get("colorOne"),this.get("colorTwo"),this.get("colorThree"),this.get("colorFour")])}setColor(e){return this.set("color",e)}setColors(e){if(!Array.isArray(e))return new m((e,t)=>t(TypeError("Argument must be an array.")));let t=new m(e=>e(null)),r=[e[0]?this.set("colorOne",e[0]):t,e[1]?this.set("colorTwo",e[1]):t,e[2]?this.set("colorThree",e[2]):t,e[3]?this.set("colorFour",e[3]):t];return m.all(r)}getCuePoints(){return this.get("cuePoints")}getCurrentTime(){return this.get("currentTime")}setCurrentTime(e){return this.set("currentTime",e)}
2524getDuration(){return this.get("duration")}getEnded(){return this.get("ended")}getLoop(){return this.get("loop")}setLoop(e){return this.set("loop",e)}setMuted(e){return this.set("muted",e)}getMuted(){return this.get("muted")}getPaused(){return this.get("paused")}getPlaybackRate(){return this.get("playbackRate")}setPlaybackRate(e){return this.set("playbackRate",e)}getPlayed(){return this.get("played")}getQualities(){return this.get("qualities")}getQuality(){return this.get("quality")}setQuality(e){return this.set("quality",e)}getRemotePlaybackAvailability(){return this.get("remotePlaybackAvailability")}getRemotePlaybackState(){return this.get("remotePlaybackState")}getSeekable(){return this.get("seekable")}getSeeking(){return this.get("seeking")}getTextTracks(){return this.get("textTracks")}getAudioTracks(){return this.get("audioTracks")}getEnabledAudioTrack(){return this.get("enabledAudioTrack")}getDefaultAudioTrack(){return this.get("defaultAudioTrack")}getVideoEmbedCode(){return this.get("videoEmbedCode")}getVideoId(){return this.get("videoId")}getVideoTitle(){return this.get("videoTitle")}getVideoWidth(){return this.get("videoWidth")}getVideoHeight(){return this.get("videoHeight")}getVideoUrl(){return this.get("videoUrl")}getVolume(){return this.get("volume")}setVolume(e){return this.set("volume",e)}async setTimingSrc(e,t){if(!e)throw TypeError("A Timing Object must be provided.");await this.ready();let r=new I(this,e,t);return S(this,"notifyTimingObjectConnect"),r.addEventListener("disconnect",()=>S(this,"notifyTimingObjectDisconnect")),r}}if(!s){let e,t,r;t={fullscreenchange:(e=function(){let e,t=[["requestFullscreen","exitFullscreen","fullscreenElement","fullscreenEnabled","fullscreenchange","fullscreenerror"],["webkitRequestFullscreen","webkitExitFullscreen","webkitFullscreenElement","webkitFullscreenEnabled","webkitfullscreenchange","webkitfullscreenerror"],["webkitRequestFullScreen","webkitCancelFullScreen","webkitCurrentFullScreenElement","webkitCancelFullScreen","webkitfullscreenchange","webkitfullscreenerror"],["mozRequestFullScreen","mozCancelFullScreen","mozFullScreenElement","mozFullScreenEnabled","mozfullscreenchange","mozfullscreenerror"],["msRequestFullscreen","msExitFullscreen","msFullscreenElement","msFullscreenEnabled","MSFullscreenChange","MSFullscreenError"]],r=0,i=t.length,n={};for(;r<i;r++)if((e=t[r])&&e[1]in document){for(r=0;r<e.length;r++)n[t[0][r]]=e[r];return n}return!1}()).fullscreenchange,fullscreenerror:e.fullscreenerror},Object.defineProperties(r={request:t=>new Promise((i,n)=>{let s=function(){r.off("fullscreenchange",s),i()};r.on("fullscreenchange",s);let a=(t=t||document.documentElement)[e.requestFullscreen]();a instanceof Promise&&a.then(s).catch(n)}),exit:()=>new Promise((t,i)=>{if(!r.isFullscreen)return void t();let n=function(){r.off("fullscreenchange",n),t()};r.on("fullscreenchange",n);let s=document[e.exitFullscreen]();s instanceof Promise&&s.then(n).catch(i)}),on(e,r){let i=t[e];i&&document.addEventListener(i,r)},off(e,r){let i=t[e];i&&document.removeEventListener(i,r)}},{isFullscreen:{get:()=>!!document[e.fullscreenElement]},element:{enumerable:!0,get:()=>document[e.fullscreenElement]},isEnabled:{enumerable:!0,get:()=>!!document[e.fullscreenEnabled]}}),D=r,function(){let e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:document,t=[].slice.call(e.querySelectorAll("[data-vimeo-id], [data-vimeo-url]")),r=e=>{"console"in window&&console.error&&console.error(`There was an error creating an embed: ${e}`)};t.forEach(e=>{try{if(null!==e.getAttribute("data-vimeo-defer"))return;let t=T(e),i=u(t);A(i,t,e).then(t=>w(t,e)).catch(r)}catch(e){r(e)}})}(),function(){let e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:document;window.VimeoPlayerResizeEmbeds_||(window.VimeoPlayerResizeEmbeds_=!0,window.addEventListener("message",t=>{if(!o(t.origin)||!t.data||"spacechange"!==t.data.event)return;let r=t.source?d(t.source,e):null;r&&(r.parentElement.style.paddingBottom=`${t.data.data[0].bottom}px`)}))}(),function(){let e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:document;window.VimeoSeoMetadataAppended||(window.VimeoSeoMetadataAppended=!0,window.addEventListener("message",t=>{if(!o(t.origin))return;let r=E(t.data);if(!r||"ready"!==r.event)return;let i=t.source?d(t.source,e):null;i&&l(i.src)&&new L(i).callMethod("appendVideoMetadata",window.location.href)}))}(),function(){let e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:document;if(window.VimeoCheckedUrlTimeParam)return;
2524window.VimeoCheckedUrlTimeParam=!0;let t=e=>{"console"in window&&console.error&&console.error(`There was an error getting video Id: ${e}`)};window.addEventListener("message",r=>{if(!o(r.origin))return;let i=E(r.data);if(!i||"ready"!==i.event)return;let n=r.source?d(r.source,e):null;if(n&&l(n.src)){let e=new L(n);e.getVideoId().then(t=>{let r=RegExp(`[?&]vimeo_t_${t}=([^&#]*)`).exec(window.location.href);if(r&&r[1]){let t=decodeURI(r[1]);e.setCurrentTime(t)}}).catch(t)}})}(),window.VimeoDRMEmbedsUpdated||(window.VimeoDRMEmbedsUpdated=!0,window.addEventListener("message",e=>{if(!o(e.origin))return;let t=E(e.data);if(!t||"drminitfailed"!==t.event)return;let r=e.source?d(e.source):null;if(!r)return;let i=r.getAttribute("allow")||"";if(!i.includes("encrypted-media")){r.setAttribute("allow",`${i}; encrypted-media`);let e=new URL(r.getAttribute("src"));e.searchParams.set("forcereload","drm"),r.setAttribute("src",e.toString());return}}))}e.s(["default",0,L],208049),e.s(["isVimeoUrl",0,function(e){return L.isVimeoUrl(e)}],207340)},445747,e=>{"use strict";var t=e.i(843476),r=e.i(997053),i=e.i(185005),n=e.i(705665),s=e.i(4154),a=e.i(259087),o=e.i(877253),l=e.i(94332),u=e.i(856082),c=e.i(607135);let d=(0,r.default)(s.Icon).withConfig({displayName:"Practical__StyledIcon",componentId:"sc-a69c2cec-0"})` 2525 width: 64px !important; 2526 2527 ${l.mq.lg} { 2528 width: 82px !important; 2529 } 2530`,h=r.default.div.withConfig({displayName:"Practical__Wrapper",componentId:"sc-a69c2cec-1"})` 2531 ${l.mq.lg} { 2532 width: calc(100% - 140px); 2533 padding-bottom: 69px; 2534 transform: translateX(70px); 2535 } 2536`,f=r.default.div.withConfig({displayName:"Practical__Box",componentId:"sc-a69c2cec-2"})` 2537 width: 100%; 2538 height: 100%; 2539 padding: 56px 56px 64px; 2540 border: 1px solid ${e=>e.theme.color.gold}; 2541 position: relative; 2542 2543 ${l.mq.lg} { 2544 padding: 80px 120px; 2545 } 2546 2547 ${({order:e})=>1===e&&r.css``||2===e&&r.css` 2548 margin-top: -1px; 2549 ${l.mq.lg} { 2550 margin-top: 0; 2551 transform: translate(-1px, 70px); 2552 } 2553 `||3===e&&r.css` 2554 margin-top: -2px; 2555 ${l.mq.lg} { 2556 margin-top: 0; 2557 transform: translate(70px, -1px); 2558 } 2559 `||4===e&&r.css` 2560 margin-top: -3px; 2561 ${l.mq.lg} { 2562 margin-top: 0; 2563 transform: translate(69px, 69px); 2564 } 2565 `}; 2566`,p=r.default.div.withConfig({displayName:"Practical__ImageWrapper",componentId:"sc-a69c2cec-3"})` 2567 display: flex; 2568 position: absolute; 2569 transform: translateY(-50%); 2570 top: 0; 2571 2572 ${e=>(1===e.order||3===e.order)&&r.css` 2573 right: 32px; 2574 `||(2===e.order||4===e.order)&&r.css` 2575 left: 32px; 2576 `} 2577 2578 svg { 2579 display: block; 2580 } 2581 2582 &:before { 2583 width: 100%; 2584 height: 100%; 2585 position: absolute; 2586 left: 0; 2587 top: 0; 2588 background: #fff; 2589 content: ''; 2590 2591 ${l.mq.md} { 2592 height: calc(100% + 40px); 2593 } 2594 } 2595 2596 ${l.mq.lg} { 2597 ${({order:e})=>1===e&&r.css` 2598 left: 0; 2599 top: 0; 2600 right: auto; 2601 transform: translate(-54px, 90px); 2602 `||2===e&&r.css` 2603 top: auto; 2604 bottom: 100%; 2605 left: 0; 2606 right: auto; 2607 transform: translate(120px, 20px); 2608 2609 &:before { 2610 width: calc(100% + 40px); 2611 height: 100%; 2612 } 2613 `||3===e&&r.css` 2614 top: 0; 2615 left: 0; 2616 right: auto; 2617 transform: translate(-50%, 76px); 2618 `||4===e&&r.css` 2619 top: 0; 2620 right: 0; 2621 left: auto; 2622 transform: translate(50%, 130px); 2623 `} 2624 } 2625`,g=r.default.div.withConfig({displayName:"Practical__ButtonWrapper",componentId:"sc-a69c2cec-4"})` 2626 display: flex; 2627 justify-content: center; 2628 margin-top: 100px; 2629`,m=(0,r.default)(n.Heading).withConfig({displayName:"Practical__StyledHeading",componentId:"sc-a69c2cec-5"})` 2630 position: relative; 2631 z-index: 1; 2632`;e.s(["Practical",0,({data:e,title:r,buttonText:s,buttonPage:l})=>e&&e.length>0?(0,t.jsx)(u.Section,{withBottomMargin:!0,children:(0,t.jsxs)(h,{children:[r&&(0,t.jsx)(n.Heading,{size:"xl",tag:"h2",marginBottom:"xl",textAlign:"center",children:r}),(0,t.jsxs)(i.Container,{children:[(0,t.jsx)(i.Row,{children:e.map((e,r)=>e?(0,t.jsx)(i.Col,{xs:16,lg:8,children:(0,t.jsxs)(f,{order:r+1,children:[(0,t.jsx)(m,{tag:"h3",size:"md",color:"gold",marginBottom:"sm",serif:!0,
2632children:e.title}),e.description&&(0,a.default)(e.description,c.parserOptions),(0,t.jsx)(p,{order:r+1,children:(0,t.jsx)(d,{name:e?.icon?.codename})})]})},"Practical_Col_"+r):null)}),s&&l&&(0,t.jsx)(g,{children:(0,t.jsx)(o.Button,{page:l,children:s})})]})]})}):null])},199005,e=>{"use strict";var t,r,i,n;let s=(i=[t={alias:null,args:null,kind:"ScalarField",name:"id",storageKey:null},r={alias:null,args:null,kind:"ScalarField",name:"title",storageKey:null}],{argumentDefinitions:[],kind:"Fragment",metadata:null,name:"ExtendedProgrammeCarouselItem_item",selections:[t,{alias:null,args:null,concreteType:"EventTypeRecord",kind:"LinkedField",name:"eventType",plural:!1,selections:i,storageKey:null},{alias:null,args:null,concreteType:"ProductionRecord",kind:"LinkedField",name:"production",plural:!1,selections:[t,r,{alias:null,args:null,kind:"ScalarField",name:"slug",storageKey:null},{alias:null,args:null,kind:"ScalarField",name:"groupbook",storageKey:null},{alias:null,args:null,concreteType:"EnsembleRecord",kind:"LinkedField",name:"ensemble",plural:!1,selections:[{alias:null,args:null,concreteType:"GenreRecord",kind:"LinkedField",name:"genre",plural:!1,selections:n=[{alias:null,args:null,kind:"ScalarField",name:"codename",storageKey:null}],storageKey:null},{alias:null,args:null,kind:"ScalarField",name:"shortTitle",storageKey:null},{alias:null,args:null,kind:"ScalarField",name:"statute",storageKey:null},r,{alias:null,args:null,kind:"ScalarField",name:"web",storageKey:null},{alias:null,args:null,kind:"ScalarField",name:"wherefrom",storageKey:null}],storageKey:null},{alias:null,args:null,concreteType:"GenreRecord",kind:"LinkedField",name:"genre",plural:!1,selections:i,storageKey:null},{alias:null,args:null,concreteType:"TagRecord",kind:"LinkedField",name:"tags",plural:!0,selections:[t,r,{alias:null,args:null,concreteType:"IconRecord",kind:"LinkedField",name:"icon",plural:!1,selections:n,storageKey:null}],storageKey:null},{alias:null,args:null,kind:"ScalarField",name:"showInNdplusCalendar",storageKey:null},{alias:null,args:null,kind:"ScalarField",name:"showInTourCalendar",storageKey:null},{alias:null,args:null,kind:"ScalarField",name:"showInMainCalendar",storageKey:null}],storageKey:null},{alias:null,args:null,kind:"ScalarField",name:"startAt",storageKey:null},{alias:null,args:null,concreteType:"TagRecord",kind:"LinkedField",name:"tags",plural:!0,selections:i,storageKey:null},{alias:null,args:null,concreteType:"VenueRecord",kind:"LinkedField",name:"venue",plural:!1,selections:[{alias:null,args:null,concreteType:"SceneRecord",kind:"LinkedField",name:"scene",plural:!1,selections:i,storageKey:null},r,{alias:null,args:null,kind:"ScalarField",name:"colosseumTitle",storageKey:null}],storageKey:null},{alias:null,args:null,kind:"ScalarField",name:"colosseumPrdid",storageKey:null},{alias:null,args:null,kind:"ScalarField",name:"isFree",storageKey:null},{alias:null,args:null,kind:"ScalarField",name:"isEntered",storageKey:null},{alias:null,args:null,kind:"ScalarField",name:"isCanceled",storageKey:null},{alias:null,args:null,kind:"ScalarField",name:"isChanged",storageKey:null},{alias:null,args:null,kind:"ScalarField",name:"isFreeWithTicket",storageKey:null},{alias:null,args:null,kind:"ScalarField",name:"saleSuspended",storageKey:null},{alias:null,args:null,kind:"ScalarField",name:"sellFrom",storageKey:null},{alias:null,args:null,kind:"ScalarField",name:"subscriptionSale",storageKey:null},{alias:null,args:null,kind:"ScalarField",name:"ticketsAvailable",storageKey:null},{alias:null,args:null,kind:"ScalarField",name:"capacity",storageKey:null},{alias:null,args:null,kind:"ScalarField",name:"ticketsUrl",storageKey:null},{alias:null,args:null,kind:"ScalarField",name:"prioritySaleInclusion",storageKey:null},{alias:null,args:null,concreteType:"ProductionRecord",kind:"LinkedField",name:"featuredProgrammeForProduction",plural:!1,selections:[r],storageKey:null}],type:"EventRecord",abstractKey:null});s.hash="efd7bf0f17c3081484ff16c3d8846eb4",e.s(["default",0,s])},145853,e=>{"use strict";var t,r;let i={argumentDefinitions:[{defaultValue:null,kind:"LocalArgument",name:"count"},{defaultValue:null,kind:"LocalArgument",name:"filter"},{defaultValue:null,kind:"LocalArgument",name:"locale"},{defaultValue:null,kind:"LocalArgument",name:"seasonsFilter"}],kind:"Fragment",metadata:null,name:"ExtendedProgrammeCarousel_list",selections:[{alias:null,args:[{kind:"V
2632ariable",name:"filter",variableName:"filter"},{kind:"Variable",name:"first",variableName:"count"},t={kind:"Variable",name:"locale",variableName:"locale"},{kind:"Literal",name:"orderBy",value:["startAt_ASC"]}],concreteType:"EventRecord",kind:"LinkedField",name:"allEvents",plural:!0,selections:[r={alias:null,args:null,kind:"ScalarField",name:"id",storageKey:null},{alias:null,args:null,kind:"ScalarField",name:"startAt",storageKey:null},{alias:null,args:null,concreteType:"ProductionRecord",kind:"LinkedField",name:"production",plural:!1,selections:[{alias:null,args:null,concreteType:"GenreRecord",kind:"LinkedField",name:"genre",plural:!1,selections:[r],storageKey:null}],storageKey:null},{args:null,kind:"FragmentSpread",name:"ExtendedProgrammeCarouselItem_item"}],storageKey:null},{alias:null,args:[{kind:"Variable",name:"filter",variableName:"seasonsFilter"},t,{kind:"Literal",name:"orderBy",value:["dateFrom_ASC"]}],concreteType:"SeasonRecord",kind:"LinkedField",name:"allSeasons",plural:!0,selections:[r,{alias:null,args:null,kind:"ScalarField",name:"dateFrom",storageKey:null},{alias:null,args:null,kind:"ScalarField",name:"dateTo",storageKey:null}],storageKey:null}],type:"Query",abstractKey:null};i.hash="1f8ff79797ed6ae11739b56ca66b920f",e.s(["default",0,i])},885791,715242,718371,e=>{"use strict";var t=e.i(843476),r=e.i(271645),i=e.i(257545),n=e.i(501440),s=e.i(595842),a=e.i(372438),o=e.i(384843),l=e.i(997053),u=e.i(775268),c=e.i(4154),d=e.i(705665),h=e.i(94332);l.default.div.withConfig({displayName:"styled__Wrapper",componentId:"sc-5393c458-0"})` 2633 position: relative; 2634 2635 ${e=>"hero"===e.type&&l.css` 2636 height: 608px; 2637 2638 .slick-slide { 2639 padding-right: 300px; 2640 box-sizing: border-box; 2641 } 2642 2643 .slick-slider { 2644 height: 100%; 2645 position: relative; 2646 } 2647 2648 .slick-dots { 2649 display: flex !important; 2650 flex-direction: column; 2651 justify-content: space-between; 2652 width: 300px; 2653 height: 100%; 2654 position: absolute; 2655 top: 0; 2656 right: 0; 2657 } 2658 `}; 2659`;let f=(0,l.default)(d.Heading).withConfig({displayName:"styled__StyledHeading",componentId:"sc-5393c458-1"})` 2660 letter-spacing: -0.5px; 2661 text-transform: capitalize; 2662 2663 span { 2664 text-decoration: none; 2665 line-height: 1.5; 2666 padding-bottom: 3px; 2667 ${e=>`background-image: linear-gradient(${e.theme.color.gold}, ${e.theme.color.gold})`}; 2668 background-position: 0% 100%; 2669 background-repeat: no-repeat; 2670 background-size: 0% 2px; 2671 transition: background-size 0.3s; 2672 } 2673`,p=l.default.div.withConfig({displayName:"styled__ProgrammeItemWrapper",componentId:"sc-5393c458-2"})` 2674 display: flex; 2675 // height: 100%; 2676 margin: 32px 16px 0; 2677 width: calc(100vw - 4rem); 2678 padding: ${e=>e.withoutPaddingBottom?"40px 40px 0":e.ndPlus?"40px 0":"40px 8px"}; 2679 position: relative; 2680 outline: none; 2681 border: 1px solid transparent; 2682 cursor: pointer; 2683 ${e=>`background-image: linear-gradient(${e.theme.color.gold}, ${e.theme.color.gold})`}; 2684 background-position: 0 100%; 2685 background-repeat: no-repeat; 2686 background-size: 0 1px; 2687 transition: background-size 0.3s; 2688 ${e=>e.withDetails&&` 2689 padding: 24px 24px 40px 24px; 2690 `}; 2691 ${e=>e.highlighted&&`border-color: ${e.theme.color.gold}`}; 2692 2693 ${e=>!e.disabled&&!e.highlighted&&l.css` 2694 &:hover { 2695 background-size: 100% 1px; 2696 } 2697 `}; 2698 2699 ${h.mq.sm} { 2700 width: auto; 2701 padding: ${e=>e.withoutPaddingBottom?"40px 40px 0":e.ndPlus?"40px 0":"40px"}; 2702 } 2703`;l.default.div.withConfig({displayName:"styled__Type",componentId:"sc-5393c458-3"})` 2704 display: flex; 2705 font-size: ${e=>e.theme.fz.xs}; 2706`,l.default.div.withConfig({displayName:"styled__Location",componentId:"sc-5393c458-4"})` 2707 display: flex; 2708 margin: 16px 0; 2709`;let g=l.default.p.withConfig({displayName:"styled__Tickets",componentId:"sc-5393c458-5"})` 2710 margin-top: 8px; 2711 font-size: ${e=>e.theme.fz.xxs}; 2712 color: ${e=>e.isSoldOut?e.theme.color.red:"inherit"};
2713`,m=l.default.div.withConfig({displayName:"styled__DayDivider",componentId:"sc-5393c458-6"})` 2714 height: 112px; 2715 border-left: 1px solid ${e=>e.theme.color.gold}; 2716 padding-left: 16px; 2717 position: absolute; 2718 left: -16px; 2719 top: -32px; 2720 font-family: var(--font-din-serif, serif); 2721 color: ${e=>e.theme.color.gold}; 2722 ${({disableCapitalize:e})=>!e&&"text-transform: capitalize;"} 2723 transform: translateX(-1px); 2724`;(0,l.default)(c.Icon).withConfig({displayName:"styled__StyledIcon",componentId:"sc-5393c458-7"})` 2725 width: 16px; 2726 margin-right: 8px; 2727`;let y=l.default.div.withConfig({displayName:"styled__DateTags",componentId:"sc-5393c458-8"})` 2728 display: flex; 2729 flex-direction: column; 2730 margin-top: 8px; 2731`,v=(0,l.default)(u.Tag).withConfig({displayName:"styled__StyledDateTag",componentId:"sc-5393c458-9"})` 2732 & + & { 2733 margin-top: 8px; 2734 } 2735`;l.default.span.withConfig({displayName:"styled__Time",componentId:"sc-5393c458-10"})` 2736 font-weight: bold; 2737 margin-right: ${e=>e.theme.gap.xxs}; 2738`;let b=l.default.div.withConfig({displayName:"styled__Flex",componentId:"sc-5393c458-11"})` 2739 display: flex; 2740 flex-direction: column; 2741 max-width: 216px; 2742 ${e=>e.withDetails&&` 2743 max-width: none; 2744 width: 280px; 2745 height: 100%; 2746 min-height: 320px; 2747 2748 ${f} { 2749 margin-bottom: 16px; 2750 } 2751 2752 ${y} { 2753 margin-bottom: 24px; 2754 } 2755 `}; 2756`;l.default.div.withConfig({displayName:"styled__Row",componentId:"sc-5393c458-12"})` 2757 display: block; 2758 white-space: nowrap; 2759`;let _=l.default.div.withConfig({displayName:"styled__ChooseTimeWrapper",componentId:"sc-5393c458-13"})` 2760 max-height: 10rem; 2761 margin-left: 1rem; 2762 ${e=>`border-left: solid 1px ${e.theme.color.gold};`} 2763 2764 ${h.mq.sm} { 2765 margin-left: 2rem; 2766 } 2767 2768 h3 { 2769 font-weight: normal; 2770 font-size: 0.75rem; 2771 margin: 0 0.5rem 1rem; 2772 2773 ${h.mq.sm} { 2774 margin-left: 1rem; 2775 } 2776 } 2777 2778 ul { 2779 columns: 2; 2780 max-height: 8rem; 2781 } 2782`,E=l.default.span.withConfig({displayName:"styled__EventTime",componentId:"sc-5393c458-14"})` 2783 font-size: 1rem; 2784 line-height: 1.5; 2785 font-weight: bold; 2786 cursor: pointer; 2787 padding: 0.25rem 1rem 0.25rem 0.5rem; 2788 2789 ${e=>e.disabled&&` 2790 color: ${e.theme.color.darkerGray}; 2791 `} 2792 2793 ${e=>!e.disabled&&e.highlighted&&` 2794 color: ${e.theme.color.white}; 2795 background-color: ${e.theme.color.gold}; 2796 `} 2797 2798 ${e=>!e.disabled&&`&:hover { 2799 color: ${e.theme.color.white}; 2800 background-color: ${e.theme.color.gold}; 2801 } 2802 `} 2803 2804 ${h.mq.sm} { 2805 padding: 0.25rem 1rem; 2806 } 2807`;e.s(["ChooseTimeWrapper",0,_,"DateTags",0,y,"DayDivider",0,m,"EventTime",0,E,"Flex",0,b,"ProgrammeItemWrapper",0,p,"StyledDateTag",0,v,"StyledHeading",0,f,"Tickets",0,g],715242);var S=e.i(491709),x=e.i(568549),T=e.i(417734),w=e.i(372907),A=e.i(63280),R=e.i(728016),I=e.i(408717),k=e.i(808592),C=e.i(312207),D=e.i(822315),L=e.i(542185);let O=(0,l.default)(A.Label).withConfig({displayName:"SimpleProgrammeCarouselItem__StyledLabel",componentId:"sc-a97d4e2b-0"})` 2808 display: inline-block; 2809 margin-top: 16px; 2810 cursor: pointer; 2811 ${h.mq.sm} { 2812 font-size: 14px; 2813 } 2814 2815 ${e=>l.css` 2816 background-image: linear-gradient(${e.theme.color.gold}, ${e.theme.color.gold}); 2817 background-position: 0 100%; 2818 background-repeat: no-repeat; 2819 background-size: 0 1px; 2820 transition: background-size 0.3s; 2821 `} 2822 2823 &:hover { 2824 background-size: 100% 1px; 2825 } 2826`,P=(0,l.default)(u.Tag).withConfig({displayName:"SimpleProgrammeCarouselItem__CustomTag",componentId:"sc-a97d4e2b-1"})` 2827 margin-bottom: 0; 2828 margin-top: 8px; 2829 padding: 4px 10px; 2830`,F=l.default.div.withConfig({displayName:"SimpleProgrammeCarouselItem__BuyButtonWrapper",componentId:"sc-a97d4e2b-2"})` 2831 margin: 0 16px; 2832 2833 button { 2834 padding: 13px 1rem; 2835 2836 ${h.mq.sm} { 2837 padding: 13px 2rem; 2838 } 2839 } 2840`,N=(0,l.default)(C.Link).withConfig({displayName:"SimpleProgrammeCarouselItem__CustomLink",componentId:"sc-a97d4e2b-3"})` 2841 position: relative; 2842 z-index: 50; 2843 2844 & > * { 2845 padding-bottom: 6px; 2846 } 2847`,M=({divider:e,onClick:i,withDetails:n,ndPlusRef:s,textFeaturedProgramme:a,textBookFeaturedProgramme:o,textBuyFeaturedProgramme:l,textChooseTime:u,...c})=>{let h=(0,r.useContext)(T.AppContext),{textFreeEntry:b,textBooked:A,textCanceled:C,textProgramChange:M,textSaleSuspended:j,textBookingNotStartedYet:$,textSubscriptionSale:U,textSubscriptionSaleUrl:B,textSubscriptionSaleLabel:V,textFree:G,textPriorityBookingStarted:q}=h,[H,z]=(0,r.useState)(c.isSingle?c.item:c.items.find(e=>e.id===c.selectedEvent)),K=(0,r.useMemo)(()=>c.isSingle?c.item:c.items.find(e=>e.isFreeWithTicket||e.isFree||!e.isCanceled&&Number(e.ticketsAvailable)>0)||c.items[0],[c.isSingle]),W=(0,D.default)(),Y=c.isSingle?!c.item.isFreeWithTicket&&!c.item.isFree&&(!!c.item.isCanceled||0===Number(c.item.ticketsAvailable)):!c.items.map(e=>
2847e.isFreeWithTicket).filter(Boolean).length&&!c.items.map(e=>e.isFree).filter(Boolean).length&&(c.items.map(e=>e.isCanceled).filter(Boolean).length>0||!c.items.map(e=>0!==Number(e.ticketsAvailable)).filter(Boolean).length),Q=e=>{if(!e)return"00:00";try{return(0,L.formatDate)(e).format("HH:mm")}catch(r){let t=String(e).match(/T(\d{2}:\d{2}):\d{2}/);return t?t[1]:"00:00"}},X=c.isSingle?(0,L.formatDate)(String(c.item.startAt)):(0,L.formatDate)(String(c.items[0].startAt)),J=(0,I.getPrioritySaleShift)(),Z=c.isSingle?c.item:c.items.find(e=>e.isFreeWithTicket||e.isFree||!e.isCanceled&&Number(e.ticketsAvailable)>0)||c.items[0],ee=(0,D.default)(String(Z.sellFrom||"2100-01-01")),et=J&&Z.prioritySaleInclusion?ee.subtract(J,"days"):ee,er=J>0&&Z.prioritySaleInclusion&&W.isSameOrAfter(et)&&W.isBefore(ee),ei=!!c.isSingle&&c.item.ndplusEvents.length>0,en=!!c.isSingle&&!!c.highlighted&&D.default.min(c?.item?.ndplusEvents?.map(e=>e?.startAt&&(0,D.default)(e?.startAt)).filter(Boolean))?.isAfter((0,D.default)()),es=!!c.isSingle&&!!c.highlighted&&c.item.ndplusEvents.map(e=>(0,k.isSellable)(e)).filter(Boolean).length>0,ea=!!ei&&!!c.isSingle&&c.item.ndplusEvents[0].isFreeWithTicket,eo=c.isSingle?Number(c.item.ticketsAvailable):H?Number(H?.ticketsAvailable):c.items.map(e=>Number(e.ticketsAvailable)).reduce((e,t)=>e+t,0),el=X&&X.isAfter((0,D.default)())&&(c.isSingle?!c.item.isFree&&!c.item.isCanceled&&!c.item.isEntered&&!c.item.isFreeWithTicket:c.items.map(e=>!e.isFree&&!e.isCanceled&&!e.isEntered&&!e.isFreeWithTicket).filter(Boolean).length>0),eu=c.isSingle?c.item.saleSuspended:0===c.items.map(e=>!e.saleSuspended).filter(Boolean).length,ec=c.isSingle?!!c?.item?.production?.groupbook:c.items.map(e=>e?.production?.groupbook).filter(Boolean).length>0,ed=(0,D.default)(String(H?.internetFrom||"1970-01-01")),eh=(0,D.default)(String(H?.internetTo||"2100-01-01")),ef=ed.isBefore(W)&&eh.isAfter(W)||!ec,ep=!0,eg=c.isSingle?(0,D.default)(String(c.item.internetFrom||"1970-01-01")):c.items.map(e=>(0,D.default)(String(e.internetFrom||"1970-01-01"))),em=c.isSingle?(0,D.default)(String(c.item.internetTo||"2100-01-01")):c.items.map(e=>(0,D.default)(String(e.internetTo||"2100-01-01")));return ec&&(!eg||(Array.isArray(eg)?eg.some(e=>e.isBefore(W)):eg.isBefore(W))||(ep=!1),!em||(Array.isArray(em)?em.some(e=>e.isAfter(W)):em.isAfter(W))||(ep=!1)),(0,r.useEffect)(()=>{c.selectedEvent&&z(c.items.find(e=>e.id===c.selectedEvent))},[c.selectedEvent]),(0,t.jsxs)("div",{children:[(0,t.jsxs)(p,{withDivider:!!e,withDetails:n,disabled:Y,onClick:e=>{!(e.target?.href||e.target?.parentElement?.href)&&(e.preventDefault(),i&&(c.isSingle?c.highlighted||i(c.item):H||i(c.items.find(e=>e.isFreeWithTicket||e.isFree||!e.isCanceled&&Number(e.ticketsAvailable)>0)||c.items[0])))},highlighted:c.highlighted,children:[e&&(0,t.jsx)(m,{children:e}),(0,t.jsxs)("div",{children:[X&&(0,t.jsx)(f,{tag:"h2",size:"sm",disabled:Y,children:(0,t.jsxs)("span",{children:[X.format("dddd D. M."),c.isSingle&&(0,t.jsx)("br",{}),c.isSingle&&Q(c.item.startAt)]})}),el&&ep&&(!eu&&et?.isSameOrBefore((0,D.default)())?(0,t.jsx)(g,{isSoldOut:0===eo,children:er?q:(0,S.resolveTicketsAmount)(eo,h,ec||!1)}):(0,t.jsx)(g,{children:eu?j:c.isSingle&&c.item.subscriptionSale?(0,t.jsxs)(t.Fragment,{children:[(0,t.jsx)(t.Fragment,{children:U}),B&&(0,t.jsxs)(t.Fragment,{children:[" ",(0,t.jsx)(N,{href:B,inverseHover:!0,children:V||B})]})]}):$})),ei&&a&&(0,t.jsx)(P,{color:"white",children:a}),K&&(0,t.jsx)("div",{children:(0,t.jsxs)(y,{children:[K.eventType&&String(K.eventType.id)!==w.EVENT_TYPE_REPEAT&&(0,t.jsx)(v,{color:"black",children:String(K.eventType.title)}),K.production?.genre?.id===w.GENRE_OPENAIR&&(0,t.jsx)(v,{color:"black",children:String(K.production.genre.title)}),C&&K.isCanceled&&(0,t.jsx)(v,{color:"black",children:C}),M&&K.isChanged&&(0,t.jsx)(v,{color:"white",children:M}),G&&K.isFree&&(0,t.jsx)(v,{color:"white",children:G}),b&&K.isFreeWithTicket&&(0,t.jsx)(v,{color:"white",children:b}),A&&K.isEntered&&(0,t.jsx)(v,{color:"white",children:A}),K.tags?.slice(0,3).map(e=>K?.eventType?.title!==e?.title&&(0,t.jsx)(v,{color:"white",children:String((0,R.nbsp)(e?.title))},`programme_carousel_${K.id}_tag_${e?.id}`))]})})]}),!c.isSingle&&(0,t.jsxs)(_,{children:[(0,t.jsx)(d.Heading,{size:"xs",tag:"h3",children:u}),(0,t.jsx)("ul",{children:c.items.map(e=>{let r=!e.isFreeWithTicket&&!e.isFree&&(!!e.isCanceled||0===Number(e.ticketsAvailable))||((0,D.default)(String(e.internetFrom||"1970-01-01")).isAfter(W)||(0,D.default)(String(e.internetTo||"2100-01-01")).isBefore(W))&&ec;return(0,t.jsx)("li",{children:(0,t.jsx)(E,{highlighted:H?.id===e.id,disabled:r,onClick:t=>{t.preventDefault(),t.stopPropagation(),i&&!r&&i(e)},children:Q(e.startAt)})}
2847,`SimpleProgrammeCarouselItem_Time_${e.id}`)})})]})]}),H&&ef&&(0,t.jsx)(F,{children:(0,t.jsx)(x.BuyButton,{event:H,showChooseButton:!1,withTime:!0})}),ei&&en&&o&&l&&!ea&&(0,t.jsx)(F,{children:(0,t.jsx)(O,{serif:!0,onClick:()=>window.scrollTo({top:window.scrollY+(s?.current?.getBoundingClientRect().y||0),behavior:"smooth"}),children:es?l:o})})]})};e.r(199005);var j=e.i(856082);let $=(0,l.default)(C.Link).withConfig({displayName:"SimpleBoxCarouselItem__CustomLink",componentId:"sc-fd4b642f-0"})` 2848 position: relative; 2849 z-index: 50; 2850 2851 & > * { 2852 padding-bottom: 6px; 2853 } 2854`,U=(0,l.default)(p).withConfig({displayName:"SimpleBoxCarouselItem__Wrapper",componentId:"sc-fd4b642f-1"})` 2855 min-height: 240px; 2856`,B=l.default.p.withConfig({displayName:"SimpleBoxCarouselItem__LinkWrapper",componentId:"sc-fd4b642f-2"})` 2857 margin-top: 8px; 2858 font-size: ${e=>e.theme.fz.xxs}; 2859`,V=({...e})=>{let{textUpcomingEventsHeading:i,textUpcomingEventsLink:n,upcomingEventsPage:s}=(0,r.useContext)(T.AppContext);return(0,t.jsx)("div",{children:(0,t.jsx)(U,{withDivider:!1,withDetails:!1,disabled:!1,highlighted:!0,children:(0,t.jsxs)("div",{children:[(0,t.jsx)(d.Heading,{tag:"h2",size:"sm",children:(0,t.jsx)("span",{children:i})}),(0,t.jsx)(B,{children:(0,t.jsx)($,{page:s,inverseHover:!0,children:n||""})})]})})})},G=(e,t,r)=>{setTimeout(()=>{if(!e.current)return;let i=e.current.getBoundingClientRect().left;for(let[e,n]of t.entries())if(n&&i<n.getBoundingClientRect().right-10){r(e);break}},600)};e.s(["SimpleProgrammeCarousel",0,({list:e,filterHeading:a,filterHeadingWithTime:o,chooseTimeHeading:l,selectedEvent:u,setSelectedEvent:c,ticketsRef:d,withDetails:h=!1,ndPlusRef:f,textFeaturedProgramme:p,textBookFeaturedProgramme:g,textBuyFeaturedProgramme:m,rightComponent:y,upcomingEventsCount:v})=>{let b=(0,r.useRef)(null),_=new Set,[E,S]=(0,r.useState)(0),x=[],w=!1,{textUpcomingEventsDivider:A}=(0,r.useContext)(T.AppContext),R=(0,D.default)(),I=new Map;if(Array.isArray(e.allEvents)&&e.allEvents.length>0)for(let t of e.allEvents){let r=(0,L.formatDate)(String(t.startAt)).format("YYYY-MM");e.allSeasons.forEach(e=>{(0,D.default)(String(e.dateFrom)).isBefore((0,D.default)(t.startAt))&&(0,D.default)(String(e.dateTo)).endOf("day").isAfter((0,D.default)(t.startAt))&&_.add(e)});let i=t?.production?.groupbook,n=!0,s=(0,D.default)(String(t.internetFrom||"1970-01-01")),a=(0,D.default)(String(t.internetTo||"2100-01-01"));if(i&&(s.isAfter(R)&&(n=!1),a.isBefore(R)&&(n=!1)),I.has(r)){let e=I.get(r);e&&n&&e.push(t)}else n&&I.set(r,[t])}function k(e,r){if(0===r.length)return;let i=e=>{c&&c(e)};w=r.length>1;let n={key:`ProgrammeItem_${String(r[0].id)}`,withDetails:h,ndPlusRef:f,textFeaturedProgramme:p,textBookFeaturedProgramme:g,textBuyFeaturedProgramme:m,textChooseTime:l};if(r.length>1){let s=r.map(e=>e?.production?.groupbook).filter(Boolean).length>0,a=!0,o=r.map(e=>(0,D.default)(String(e.internetFrom||"1970-01-01"))),l=r.map(e=>(0,D.default)(String(e.internetTo||"2100-01-01")));s&&(o.every(e=>e.isAfter(R))&&(a=!1),l.every(e=>e.isBefore(R))&&(a=!1)),a&&e.push((0,t.jsx)(M,{highlighted:!!u&&r.map(e=>e.id).includes(u.id),items:r,isSingle:!1,selectedEvent:u?.id,onClick:i,...n}))}else if(u?.id===r[0].id)e.push((0,t.jsx)(M,{highlighted:!0,item:u,isSingle:!0,...n}));else{let s=r[0],a=s?.production?.groupbook,o=!0,l=(0,D.default)(String(s.internetFrom||"1970-01-01")),u=(0,D.default)(String(s.internetTo||"2100-01-01"));a&&(l.isAfter(R)&&(o=!1),u.isBefore(R)&&(o=!1)),o&&e.push((0,t.jsx)(M,{highlighted:!1,item:s,isSingle:!0,onClick:i,...n}))}}let C=function(e){let r=[],n=[],s=0;for(let a of e.values()){let e=0,o=[],d=0;for(let r of a){let s=(0,L.formatDate)(String(r.startAt));if(0===e&&n.push((0,t.jsx)(i.DayDivider,{children:(0,t.jsx)("span",{children:s.format("MMMM YYYY")})},`DayDivider-${String(r.startAt)}-${e}`)),r?.production?.showEventsGrouped){let e=s.startOf("day").valueOf();e===d?o.push(r):(k(n,o),o=[r]),d=e}else r.id===u?.id?n.push((0,t.jsx)(M,{divider:void 0,isSingle:!0,item:u,highlighted:!0,onClick:e=>{c&&c(e)},withDetails:h,ndPlusRef:f,textFeaturedProgramme:p,textBookFeaturedProgramme:g,textBuyFeaturedProgramme:m,textChooseTime:l},`ProgrammeItem_${String(r.id)}`)):n.push((0,t.jsx)(M,{divider:void 0,isSingle:!0,item:r,highlighted:!1,onClick:e=>{c&&c(e)},withDetails:h,ndPlusRef:f,textFeaturedProgramme:p,textBookFeaturedProgramme:g,textBuyFeaturedProgramme:m,textChooseTime:l},`ProgrammeItem_${String(r.id)}`));e++}k(n,o),r.push((0,t.jsx)(i.ResultsGroup,{ref:e=>{x.push(e)},children:n},`ResultsGroup-${s}`)),n=[],s++}return v>
28590&&(n.push((0,t.jsx)(i.DayDivider,{noCapitalize:!0,children:(0,t.jsx)("span",{children:A})},"DayDivider-ue"),(0,t.jsx)(V,{},"UE_box")),r.push((0,t.jsx)(i.ResultsGroup,{ref:e=>{x.push(e)},children:n},`ResultsGroup-${s}`))),r}(I);return 0===C.length?(0,t.jsx)(t.Fragment,{}):(0,t.jsx)(j.Section,{withTopMargin:!0,id:"tickets",children:(0,t.jsxs)(i.Wrapper,{ref:d,type:"simple",children:[(0,t.jsx)(n.Filter,{data:I,seasons:Array.from(_),heading:w?o:a,sliderRef:b,groupBy:"month",currentSlide:E,updateCurrent:function(e){S(e)},targetRefs:x,rightComponent:y}),(0,t.jsx)(s.Slider,{marginToButtonsSmall:!0,ref:b,nextCallback:()=>G(b,x,S),prevCallback:()=>G(b,x,S),children:C})]})})},"handleFilterPosition",0,G],718371);var q=e.i(4824),H=e.i(895751);D.default.extend(H.default),D.default.extend(q.default),e.r(145853),e.s(["ExtendedProgrammeCarousel",0,({allEvents:e,allSeasons:l,list:u,filterHeading:c,ticketsRef:d,textFeaturedProgramme:h,homepage:f=!1,goldenTileTitle:p,goldenTileSubtitle:g,goldenTileLink:m,withGoldenTile:y=!1,textTicketValidation:v,onlineTicketPage:b})=>{var _;let E=(_={allEvents:e,allSeasons:l,list:u}).allEvents&&_.allSeasons?{allEvents:_.allEvents,allSeasons:_.allSeasons}:_.list&&"allEvents"in _.list&&"allSeasons"in _.list&&_.list.allEvents&&_.list.allSeasons?{allEvents:_.list.allEvents,allSeasons:_.list.allSeasons}:null,S=(0,r.useRef)(null),x=E?.allSeasons??[],T=E?.allEvents??[],w=(0,r.useContext)(o.LocaleContext),[A,I]=(0,r.useState)(0),k=[],C=new Map;if(Array.isArray(T)&&T.length>0){let e=[...T].sort((e,t)=>(0,L.formatDate)(String(e.startAt)).isAfter((0,L.formatDate)(String(t.startAt)))?1:(0,L.formatDate)(String(e.startAt)).isBefore((0,L.formatDate)(String(t.startAt)))?-1:0),t=e.reverse().findIndex(e=>!e.production?.showInNdplusCalendar),r=e.reverse().slice(0,e.length-t);for(let e of f?T:r){let t=(0,L.formatDate)(String(e.startAt)).format("YYYY-MM-DD");if(C.has(t)){let r=C.get(t);r&&r.push(e)}else C.set(t,[e])}}return(0,t.jsxs)(i.Wrapper,{ref:d,type:"extended",homepage:f,children:[(0,t.jsx)(n.Filter,{data:C,seasons:x,heading:c,sliderRef:S,groupBy:"day",currentSlide:A,updateCurrent:function(e){I(e)},targetRefs:k}),(0,t.jsx)(s.Slider,{ref:S,nextCallback:()=>G(S,k,I),prevCallback:()=>G(S,k,I),children:(0,t.jsxs)(t.Fragment,{children:[p&&m&&g&&y&&f&&(0,t.jsxs)(i.GoldenTileWrapper,{children:[(0,t.jsxs)(i.GoldenTile,{page:m,type:"gold",children:[String((0,R.nbsp)(p)),g?(0,t.jsxs)(t.Fragment,{children:[(0,t.jsx)("br",{}),(0,t.jsx)("span",{children:(0,R.nbsp)(g)})]}):""]}),b&&v&&(0,t.jsx)(i.TicketButton,{page:b,children:v})]},"SelectedEventsCarouselGoldenTile"),function(e){let r=[],n=[];for(let[s,o]of e.entries())o.forEach(e=>{n.push((0,t.jsx)(a.ExtendedProgrammeCarouselItemComponent,{item:e,textFeaturedProgramme:h},`ExtendedProgrammeItem_${e.id}`))}),r.push((0,t.jsxs)(i.DayEvents,{ref:e=>{k.push(e)},children:[(0,t.jsx)(i.DayDivider,{children:(0,t.jsx)("span",{children:(()=>{let e=D.default.tz(s,"YYYY-MM-DD","Europe/Prague"),t=(0,D.default)().tz("Europe/Prague");return e.isSame(t,"week")?e.format("dddd"):e.format("en"===w?"MM/DD":"D. M.")})()})}),n]},`DayEvents-${s}`)),n=[];return r}(C)]})})]})}],885791)},814204,e=>{"use strict";e.s(["capitalise",0,e=>e.charAt(0).toUpperCase()+e.substring(1)])},549536,275731,e=>{"use strict";var t=e.i(843476),r=e.i(271645),i=e.i(997053),n=e.i(535289),s=e.i(705665),a=e.i(971936),o=e.i(417734),l=e.i(94332),u=e.i(760207),c=e.i(312207),d=e.i(814204),h=e.i(372907),f=e.i(822315);function p(e){return(0,d.capitalise)((0,f.default)(e).format(h.MAGAZINE_DATE_FORMAT))}e.s(["formatMagazineDate",0,p],275731);let g=(0,i.default)(c.Link).withConfig({displayName:"MagazineArticleCard__Wrapper",componentId:"sc-5abe95f9-0"})` 2860 border-top: 1px solid ${({theme:e})=>e.color.lightgold}; 2861 border-bottom: 1px solid ${({theme:e})=>e.color.lightgold}; 2862 height: 100%; 2863 position: relative; 2864 display: block; 2865`,m=i.default.div.withConfig({displayName:"MagazineArticleCard__Content",componentId:"sc-5abe95f9-1"})` 2866 padding: ${({theme:e})=>e.gap.lg} 0 ${({theme:e})=>e.gap.lg2}; 2867`,y=i.default.p.withConfig({displayName:"MagazineArticleCard__HighlightedDate",componentId:"sc-5abe95f9-2"})` 2868 color: ${({theme:e})=>e.color.lightgold}; 2869 font-size: ${({theme:e})=>e.fz.sm}; 2870 font-family: var(--font-din-serif); 2871 font-weight: 700; 2872 margin-bottom: ${({theme:e})=>e.gap.xxs}; 2873`,v=(0,i.default)(y).withConfig({displayName:"MagazineArticleCard__HighlightedDateSmall",componentId:"sc-5abe95f9-3"})` 2874 font-size: ${({theme:e})=>e.fz.xs}; 2875 font-weight: normal; 2876 margin-bottom: 0; 2877`,b=(0,i.default)(a.Paragraph).withConfig({displayName:"MagazineArticleCard__StyledParagraph",componentId:"sc-5abe95f9-4"})` 2878 color: ${({theme:e})=>e.color.white}; 2879`,_=i.default.div.withConfig({displayName:"MagazineArticleCard__HeaderWrapper",componentId:"sc-5abe95f9-5"})` 2880 position: relative; 2881 ${({gradient:e})=>e&&i.css` 2882 &:after { 2883 position: absolute; 2884 content: ''; 2885 background: 2886 linear-gradient(360deg, rgba(0, 0, 0, 0.4) 0%, rgba(0, 0, 0, 0) 50%), 2887 radial-gradient(100% 100% at 59.5% 0%, rgba(0, 0, 0, 0) 61.49%, rgba(0, 0, 0, 0.64) 100%); 2888 left: 0; 2889 bottom: 0; 2890 right: 0; 2891 height: 100%; 2892 } 2893 `} 2894`,E=i.default.div.withConfig({displayName:"MagazineArticleCard__ArticleInfo",componentId:"sc-5abe95f9-6"})` 2895 position: absolute; 2896 left: ${({theme:e})=>e.gap.sm}; 2897 bottom: ${({theme:e})=>e.gap.xs}; 2898 color: ${({theme:e})=>e.color.white}; 2899 display: flex; 2900 z-index: 1; 2901 2902 p + p { 2903 margin-left: ${({theme:e})=>e.gap.xs}; 2904 padding-left: ${({theme:e})=>e.gap.xs}; 2905 position: relative; 2906 &:before { 2907 position: absolute; 2908 content: ''; 2909 left: 0; 2910 height: 100%; 2911 width: 1px; 2912 background: ${({theme:e})=>e.color.lightgold}; 2913 } 2914 } 2915`,S=(0,i.default)(E).withConfig({displayName:"MagazineArticleCard__MainArticleInfo",componentId:"sc-5abe95f9-7"})` 2916 position: relative; 2917 left: 0; 2918 bottom: 0; 2919 margin-top: ${({theme:e})=>e.gap.xxs}; 2920 margin-bottom: ${({theme:e})=>e.gap.sm}; 2921`,x=i.default.div.withConfig({displayName:"MagazineArticleCard__MainImageWrapper",componentId:"sc-5abe95f9-8"})` 2922 position: relative; 2923 height: 100%; 2924 min-height: 20rem; 2925 &:after { 2926 position: absolute; 2927 content: ''; 2928 top: 0; 2929 left: 0; 2930 width: 100%; 2931 height: 100%; 2932 background: 2933 linear-gradient(360deg, rgba(0, 0, 0, 0.4) 0%, rgba(0, 0, 0, 0) 50%), 2934 radial-gradient(100% 100% at 59.5% 0%, rgba(0, 0, 0, 0) 61.49%, rgba(0, 0, 0, 0.64) 100%); 2935 } 2936`,T=(0,i.default)(n.Image).withConfig({displayName:"MagazineArticleCard__StyledImage",componentId:"sc-5abe95f9-9"})` 2937 width: 100%; 2938`,w=i.default.div.withConfig({displayName:"MagazineArticleCard__MainContent",componentId:"sc-5abe95f9-10"})` 2939 position: absolute; 2940 bottom: 0; 2941 left: 9vw; 2942 right: 9vw; 2943 display: flex; 2944 align-items: center; 2945 height: 100%; 2946 2947 ${l.mq.sm} { 2948 bottom: 64px; 2949 left: 6.25vw; 2950 right: 6.25vw; 2951 justify-content: space-between; 2952 align-items: flex-end; 2953 } 2954`,A=i.default.div.withConfig({displayName:"MagazineArticleCard__MainContentInner",componentId:"sc-5abe95f9-11"})` 2955 ${l.mq.sm} { 2956 width: 60%; 2957 } 2958`,R=i.default.div.withConfig({displayName:"MagazineArticleCard__MainButtonWrapper",componentId:"sc-5abe95f9-12"})` 2959 display: none; 2960 ${l.mq.sm} { 2961 display: block; 2962 } 2963`,I=i.default.div.withConfig({displayName:"MagazineArticleCard__EditorialTopWrapper",componentId:"sc-5abe95f9-13"})` 2964 margin-bottom: ${({theme:e})=>e.gap.lg}; 2965 display: flex; 2966 align-items: center; 2967`,k=i.default.div.withConfig({displayName:"MagazineArticleCard__EditorialImageWrapper",componentId:"sc-5abe95f9-14"})` 2968 width: 144px; 2969 height: 144px; 2970`,C=i.default.div.withConfig({displayName:"MagazineArticleCard__EditorialTopContentWrapper",componentId:"sc-5abe95f9-15"})` 2971 margin-left: ${({theme:e})=>e.gap.lg}; 2972`,D=i.default.div.withConfig({displayName:"MagazineArticleCard__EditorialButtonWrapper",componentId:"sc-5abe95f9-16"})` 2973 margin: ${({theme:e})=>`${e.gap.md} 0 ${e.gap.lg}`}; 2974`,L=i.default.span.withConfig({displayName:"MagazineArticleCard__ButtonLabel",componentId:"sc-5abe95f9-17"})` 2975 display: inline-flex; 2976 justify-content: center;
2977 align-items: center; 2978 position: relative; 2979 padding: 13px 31px; 2980 color: ${({theme:e})=>e.color.white}; 2981 border: 1px solid ${({theme:e})=>e.color.gold}; 2982 font-family: var(--font-din-serif); 2983`;e.s(["MagazineArticleCard",0,({date:e,image:i,type:a,title:l,description:c,category:d,id:h,slug:f,perex:O})=>{let{magazineArticlePage:P,magazinePage:F,textRead:N,textGoToCurrentIssue:M,textContinueReading:j}=(0,r.useContext)(o.AppContext),$="issue"===a,U="article"===a,B="person"===a,V=(0,r.useCallback)(()=>(0,t.jsxs)(_,{gradient:U,children:[i&&(0,t.jsx)(T,{src:i.url,alt:l??i.alt??"",height:322,width:472,fit:"crop",crop:$?"top":void 0,sizes:"(min-width: 1440px) 21.875vw, (min-width: 1024px) 31.25vw, (min-width: 640px) 37.5vw, 75vw"}),U&&(0,t.jsxs)(E,{children:[d&&d.length>0&&(0,t.jsx)("p",{children:d.map(e=>e.title).join(", ")}),e&&(0,t.jsx)("p",{children:p(e)})]})]}),[]),G=(0,r.useCallback)(()=>(0,t.jsxs)(m,{children:[(0,t.jsx)(s.Heading,{size:"md",color:"white",tag:"h3",marginBottom:"xs",children:l}),$&&e&&(0,t.jsx)(y,{children:p(e)}),c&&(0,t.jsx)(b,{children:c}),M&&N&&($||U&&h&&f)&&(0,t.jsx)(L,{children:$?M:N})]}),[]),q=(0,r.useCallback)(()=>(0,t.jsx)(g,{page:P,params:{slug:`${f}-${h}`},noHover:!0,plain:!0,children:(0,t.jsxs)(t.Fragment,{children:[i&&(0,t.jsx)(x,{children:(0,t.jsx)(T,{src:i.url,alt:l??i.alt??"",height:1280,width:1818,fit:"crop",layout:"cover"})}),(0,t.jsxs)(w,{children:[(0,t.jsxs)(A,{children:[(0,t.jsx)(s.Heading,{size:"md",color:"white",tag:"h3",marginBottom:"xs",children:l}),(0,t.jsxs)(S,{children:[d&&d.length>0&&(0,t.jsx)("p",{children:d.map(e=>e.title).join(", ")}),e&&(0,t.jsx)("p",{children:p(e)})]}),c&&(0,t.jsx)(b,{children:c})]}),N&&(0,t.jsx)(R,{children:(0,t.jsx)(L,{children:N})})]})]})}),[]),H=(0,r.useCallback)(()=>(0,t.jsx)(g,{page:P,params:{slug:`${f}-${h}`},noHover:!0,plain:!0,children:(0,t.jsxs)(t.Fragment,{children:[(0,t.jsxs)(I,{children:[i&&(0,t.jsx)(k,{children:(0,t.jsx)(n.Image,{src:i.url,alt:l??i.alt??"",height:144,width:144,fit:"crop",focalPoint:i.focalPoint})}),(0,t.jsxs)(C,{children:[(0,t.jsx)(s.Heading,{size:"md",color:"white",tag:"h3",marginBottom:"xxs",children:l}),e&&(0,t.jsx)(v,{children:p(e)})]})]}),O&&(0,t.jsx)(u.RichText,{content:O,simple:!0,withoutBottomMargin:!0}),!B&&j&&h&&f&&(0,t.jsx)(D,{children:(0,t.jsx)(L,{children:j})})]})}),[]);return"main"===a?q():"editorial"===a||B?H():(0,t.jsxs)(g,{page:$?F:P,params:h&&f?{slug:`${f}-${h}`}:void 0,noHover:!0,plain:!0,children:[V(),G()]})}],549536)},54513,e=>{"use strict";var t,r,i=e.i(271645),n=Object.defineProperty,s=new Map,a=new WeakMap,o=0;i.Component,null!=(null!=(r="useInsertionEffect"in i?i.useInsertionEffect:void 0)?r:i.useLayoutEffect)||i.useEffect,e.s(["useInView",0,function({threshold:e,delay:r,trackVisibility:n,rootMargin:l,root:u,triggerOnce:c,skip:d,initialInView:h,fallbackInView:f,onChange:p}={}){var g;let[m,y]=i.useState(null),v=i.useRef(p),b=i.useRef(h),[_,E]=i.useState({inView:!!h,entry:void 0});v.current=p,i.useEffect(()=>{let i;if(void 0===b.current&&(b.current=h),!d&&m)return i=function(e,r,i={},n=t){if(void 0===window.IntersectionObserver&&void 0!==n){let t=e.getBoundingClientRect();return r(n,{isIntersecting:n,target:e,intersectionRatio:"number"==typeof i.threshold?i.threshold:0,time:0,boundingClientRect:t,intersectionRect:t,rootBounds:t}),()=>{}}let{id:l,observer:u,elements:c}=function(e){let t=Object.keys(e).sort().filter(t=>void 0!==e[t]).map(t=>{var r;return`${t}_${"root"===t?!(r=e.root)?"0":(a.has(r)||(o+=1,a.set(r,o.toString())),a.get(r)):e[t]}`}).toString(),r=s.get(t);if(!r){let i,n=new Map,a=new IntersectionObserver(t=>{t.forEach(t=>{var r;let s=t.isIntersecting&&i.some(e=>t.intersectionRatio>=e);e.trackVisibility&&void 0===t.isVisible&&(t.isVisible=s),[...null!=(r=n.get(t.target))?r:[]].forEach(e=>{e(s,t)})})},e);i=a.thresholds||(Array.isArray(e.threshold)?e.threshold:[e.threshold||0]),r={id:t,observer:a,elements:n},s.set(t,r)}return r}(i),d=c.get(e)||[];return c.has(e)||c.set(e,d),d.push(r),u.observe(e),function(){d.splice(d.indexOf(r),1),0===d.length&&(c.delete(e),u.unobserve(e)),0===c.size&&(u.disconnect(),s.delete(l))}}(m,(e,t)=>{let r=b.current;b.current=e,(void 0!==r||e)&&(E({inView:e,entry:t}),v.current&&v.current(e,t),t.isIntersecting&&c&&i&&(i(),i=void 0))},{root:u,rootMargin:l,threshold:e,trackVisibility:n,delay:r},f),()=>{i&&i()}},[Array.isArray(e)?e.toString():e,m,u,l,c,d,n,f,r]);let S=null==(g=_.entry)?void 0:g.target,x=i.useRef(void 0);m||!S||c||d||x.current===S||(x.current=S,E({inView:!!h,entry:void 0}),b.current=h);let T=[y,_.inView,_.entry];return T.ref=T[0],T.inView=T[1],T.entry=T[2],T}])}]);
Line numbers count LF bytes from the start of the resource, as the search results do. Vendor segments are library code the classifier recognised; they are stored but not indexed. Bytes are shown as Latin1 characters, one per byte.