-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathmutiny2.js
5 lines (5 loc) · 76.1 KB
/
mutiny2.js
1
2
3
4
5
!function(e){function t(t){for(var n,o,i=t[0],a=t[1],s=0,c=[];s<i.length;s++)o=i[s],Object.prototype.hasOwnProperty.call(r,o)&&r[o]&&c.push(r[o][0]),r[o]=0;for(n in a)Object.prototype.hasOwnProperty.call(a,n)&&(e[n]=a[n]);for(u&&u(t);c.length;)c.shift()()}var n={},r={5:0};function o(t){if(n[t])return n[t].exports;var r=n[t]={i:t,l:!1,exports:{}};return e[t].call(r.exports,r,r.exports,o),r.l=!0,r.exports}o.e=function(e){var t=[],n=r[e];if(0!==n)if(n)t.push(n[2]);else{var i=new Promise((function(t,o){n=r[e]=[t,o]}));t.push(n[2]=i);var a,s=document.createElement("script");s.charset="utf-8",s.timeout=120,o.nc&&s.setAttribute("nonce",o.nc),s.src=function(e){return o.p+"mutiny-client/"+e+".4.4.1.js"}(e);var u=new Error;a=function(t){s.onerror=s.onload=null,clearTimeout(c);var n=r[e];if(0!==n){if(n){var o=t&&("load"===t.type?"missing":t.type),i=t&&t.target&&t.target.src;u.message="Loading chunk "+e+" failed.\n("+o+": "+i+")",u.name="ChunkLoadError",u.type=o,u.request=i,n[1](u)}r[e]=void 0}};var c=setTimeout((function(){a({type:"timeout",target:s})}),12e4);s.onerror=s.onload=a,document.head.appendChild(s)}return Promise.all(t)},o.m=e,o.c=n,o.d=function(e,t,n){o.o(e,t)||Object.defineProperty(e,t,{enumerable:!0,get:n})},o.r=function(e){"undefined"!=typeof Symbol&&Symbol.toStringTag&&Object.defineProperty(e,Symbol.toStringTag,{value:"Module"}),Object.defineProperty(e,"__esModule",{value:!0})},o.t=function(e,t){if(1&t&&(e=o(e)),8&t)return e;if(4&t&&"object"==typeof e&&e&&e.__esModule)return e;var n=Object.create(null);if(o.r(n),Object.defineProperty(n,"default",{enumerable:!0,value:e}),2&t&&"string"!=typeof e)for(var r in e)o.d(n,r,function(t){return e[t]}.bind(null,r));return n},o.n=function(e){var t=e&&e.__esModule?function(){return e.default}:function(){return e};return o.d(t,"a",t),t},o.o=function(e,t){return Object.prototype.hasOwnProperty.call(e,t)},o.p="https://client.mutinycdn.com/",o.oe=function(e){throw console.error(e),e};var i=window.mutinyWpJsonp=window.mutinyWpJsonp||[],a=i.push.bind(i);i.push=t,i=i.slice();for(var s=0;s<i.length;s++)t(i[s]);var u=a;o(o.s=24)}([function(e,t,n){"use strict";var r,o,i,a,s,u,c,l,d,f,h,p,g,m,v,y,b,w,S,O,_,j,E,k,T,C,N,L,q,M,x;n.d(t,"v",(function(){return r})),n.d(t,"r",(function(){return o})),n.d(t,"h",(function(){return i})),n.d(t,"n",(function(){return a})),n.d(t,"C",(function(){return s})),n.d(t,"u",(function(){return u})),n.d(t,"g",(function(){return c})),n.d(t,"p",(function(){return l})),n.d(t,"o",(function(){return d})),n.d(t,"d",(function(){return f})),n.d(t,"c",(function(){return h})),n.d(t,"y",(function(){return p})),n.d(t,"w",(function(){return g})),n.d(t,"k",(function(){return m})),n.d(t,"x",(function(){return v})),n.d(t,"t",(function(){return y})),n.d(t,"l",(function(){return b})),n.d(t,"i",(function(){return S})),n.d(t,"m",(function(){return O})),n.d(t,"A",(function(){return _})),n.d(t,"B",(function(){return j})),n.d(t,"q",(function(){return E})),n.d(t,"f",(function(){return k})),n.d(t,"z",(function(){return T})),n.d(t,"j",(function(){return C})),n.d(t,"e",(function(){return N})),n.d(t,"s",(function(){return L})),n.d(t,"b",(function(){return q})),n.d(t,"a",(function(){return M})),function(e){e.Editor="editor",e.Preview="preview",e.Live="live"}(r||(r={})),function(e){e.LiveOverrideMode="LiveOverrideMode",e.Live="Live",e.LocalDebug="LocalDebug"}(o||(o={})),function(e){e.StateChange="mutiny:state-change",e.ImpressionCacheUpdate="mutiny:impression-cache:update",e.AssetViewerLoaded="mutiny:asset-viewer:loaded",e.AssetViewerOpened="mutiny:asset-viewer:opened",e.WindowExperienceImpression="mutiny:experience-impression"}(i||(i={})),function(e){e.Mutiny="mutiny",e.Window="window",e.Segment="segment",e.Amplitude="amplitude",e.Cookie="cookie",e.Drawbridge="drawbridge",e.GoogleAnalytics="google_analytics",e.GoogleAnalytics4="google_analytics_4",e.Marketo="marketo",e.Hubspot="hubspot"}(a||(a={})),function(e){e.Marketo="marketo",e.Hubspot="hubspot"}(s||(s={})),function(e){e.Personalized="personalized",e.Control="control"}(u||(u={})),function(e){e.Data="data",e.Conversion="conversion"}(c||(c={})),function(e){e.Increment="increment",e.Timing="timing",e.Event="event"}(l||(l={})),function(e){e.Change="change",e.Click="click",e.Submit="submit",e.PageView="page_view",e.Calendly="calendly",e.Drift="drift",e.Hubspot="hubspot"}(d||(d={})),function(e){e.Equal="equal",e.NotEqual="not_equal",e.UrlEqual="url_equal",e.UrlNotEqual="url_not_equal",e.GreaterThan="greater_than",e.GreaterThanOrEqual="greater_than_or_equal",e.LessThan="less_than",e.LessThanOrEqual="less_than_or_equal",e.Includes="includes",e.NotIncludes="not_includes",e.StartsWith="starts_with",e.EndsWith="ends_with",e.MatchesRegex="matches_regex",e.UrlHostEqual="url_host_equal",e.UrlHostNotEqual="url_host_not_equal",e.UrlPathEqual="url_path_equal",e.UrlPathNotEqual="url_path_not_equal"}(f||(f={})),function(e){e.Count="_count"}(h||(h={})),function(e){e.FAB="fab",e.Modal="modal",e.TopBar="top_bar",e.ExitIntentModal="exit_intent_modal",e.ContentPlaylist="content_playlist"}(p||(p={})),function(e){e.MultipleChoice="multiple_choice",e.Form="form"}(g||(g={})),function(e){e.QuestionnaireClicked="questionnaire_clicked",e.QuestionnaireDismissed="questionnaire_dismissed",e.QuestionnaireAnswered="questionnaire_answered",e.QuestionnaireFormSubmitted="questionnaire_form_submitted",e.QuestionnaireCtaClicked="questionnaire_cta_clicked",e.ContentPlaylistAssetViewed="content_playlist_asset_viewed",e.ContentPlaylistAssetConsumed="content_playlist_asset_consumed"}(m||(m={})),function(e){e.Questionnaire="questionnaire",e.Control="control"}(v||(v={})),function(e){e.Data="data",e.Link="link",e.Dismiss="dismiss",e.Input="input"}(y||(y={})),function(e){e.Text="text",e.Email="email"}(b||(b={})),function(e){e.Modal="modal",e.Page="page"}(w||(w={})),function(e){e.Redirect="redirect",e.Render="render",e.Questionnaire="questionnaire"}(S||(S={})),function(e){e.Before="before",e.After="after",e.FirstChild="first_child",e.LastChild="last_child"}(O||(O={})),function(e){e.OneOff="one_off",e.Batch="batch"}(_||(_={})),function(e){e.Mouseout="mouseout",e.TimeOnPage="time_on_page",e.Scroll="scroll"}(j||(j={})),function(e){e.Compact="compact",e.Icon="icon",e.Hero="hero",e.None="none"}(E||(E={})),function(e){e.Top="top",e.Bottom="bottom"}(k||(k={})),function(e){e.Light="light",e.Dark="dark"}(T||(T={})),function(e){e.Colfax="colfax",e.Futura="furtura",e.SystemDefault="system_default"}(C||(C={})),function(e){e.SameTab="same_tab",e.NewTab="new_tab"}(N||(N={})),function(e){e.Back="back",e.Forward="forward"}(L||(L={})),function(e){e.Default="default",e.AssetViewer="asset_viewer"}(q||(q={})),function(e){e.Primary="primary",e.Secondary="secondary",e.Tertiary="tertiary",e.Transparent="transparent",e.TransparentSecondary="transparent_secondary",e.Translucent="translucent"}(M||(M={})),function(e){e.Modal="modal",e.Banner="banner",e.Sidepop="sidepop",e.Brand="brand"}(x||(x={}))},function(e,t,n){"use strict";n.d(t,"a",(function(){return a})),n.d(t,"c",(function(){return s})),n.d(t,"b",(function(){return u})),n.d(t,"g",(function(){return f})),n.d(t,"e",(function(){return h})),n.d(t,"f",(function(){return p})),n.d(t,"d",(function(){return g}));var r=n(6),o=n(10),i=n(3);const a="mutiny.user.session_number",s="mutiny.user.token",u="mutiny.user.session",{getCookie:c,setCookie:l,isCookieSet:d}=r.a,f=(e,t,n=!1)=>{if(Object(i.d)()&&!i.a.includes(e))return;if(n||!d(e)){const n=new Date;n.setTime(n.getTime()+943488e5),l(e,t,n)}Object(o.a)().setItem(e,t)},h=e=>{const t=c(e);if(t)return t;const n=Object(o.a)().getItem(e);return n&&f(e,n),n},p=(e,t,n)=>{if(Object(i.d)()&&!i.a.includes(e))return;const o=new Date;o.setTime(o.getTime()+n);try{return r.a.setCookie(e,t,o),!0}catch(e){return!1}},g=e=>c(e)},function(e,t,n){"use strict";var r=n(10);const o=0,i=1,a=2,s=3,u=4;t.a=class{constructor(e){this.prefix=e,this.logger()}debug(...e){this.logger().then(t=>{this.logLevel()>u&&t.extend("debug")(...e)})}log(...e){this.logger().then(t=>{this.logLevel()>s&&t.extend("log")(...e)})}info(...e){this.logger().then(t=>{this.logLevel()>a&&t.extend("info")(...e)})}warn(...e){this.logger().then(t=>{this.logLevel()>i&&t.extend("warn")(...e)})}error(...e){this.logger().then(t=>{this.logLevel()>o&&t.extend("error")(...e)})}logger(){return this._logger?Promise.resolve(this._logger):n.e(8).then(n.t.bind(null,25,7)).then(e=>e.default).then(e=>this._logger=e("mutiny:"+this.prefix))}logLevel(){const e=Object(r.a)().getItem("debugLevel");return e?Number(e):4}}},function(e,t,n){"use strict";n.d(t,"a",(function(){return o})),n.d(t,"d",(function(){return i})),n.d(t,"f",(function(){return s})),n.d(t,"e",(function(){return u})),n.d(t,"b",(function(){return c})),n.d(t,"c",(function(){return l}));var r=n(6);const o=["mutiny.defaultOptOut","mutiny.optOut","mutiny.optIn"];function i(){const e=e=>Boolean(r.a.getCookie(e));return e("mutiny.optOut")||e("mutiny.defaultOptOut")&&!e("mutiny.optIn")}const a=(()=>{const e=new Date;return e.setTime(e.getTime()+943488e5),e})();function s(){return r.a.setCookie("mutiny.optIn","",a),r.a.setCookie("mutiny.optOut","true",a)}function u(){return r.a.setCookie("mutiny.optOut","",a),r.a.setCookie("mutiny.optIn","true",a)}function c(){return r.a.setCookie("mutiny.defaultOptOut","true",a)}function l(){if(i())return!0;const e=void 0!==navigator.doNotTrack?navigator.doNotTrack:void 0!==window.doNotTrack?window.doNotTrack:void 0!==navigator.msDoNotTrack?navigator.msDoNotTrack:null;return 0!==Number.parseInt(null!=e?e:"",10)&&"no"!==e&&(1===Number.parseInt(null!=e?e:"",10)||"yes"===e)}},function(e,t,n){"use strict";n.d(t,"e",(function(){return c})),n.d(t,"i",(function(){return l})),n.d(t,"g",(function(){return d})),n.d(t,"d",(function(){return f})),n.d(t,"f",(function(){return h})),n.d(t,"j",(function(){return p})),n.d(t,"h",(function(){return g})),n.d(t,"c",(function(){return m})),n.d(t,"a",(function(){return v})),n.d(t,"b",(function(){return y}));var r=n(8),o=n(17),i=n(13),a=n(0),s=n(7),u=n(9);function c(e,t){return e.replace(/\/$/,"")===t.replace(/\/$/,"")}function l(e){try{return decodeURIComponent(e.replace(/\+/g,"%20"))}catch(t){if(t instanceof URIError)return e;throw t}}const d=e=>{if("string"!=typeof e||0===e.length)return{hash:"",hostname:"",pathname:"",url_host:"",url_path:""};const t=Object(s.a)("a");return t.href=e.startsWith("http")?e:"https://"+e,{hash:t.hash,hostname:t.hostname,pathname:t.pathname,url_host:t.hostname,url_path:t.pathname}};function f(e,t){const n=e.toLowerCase(),r=(o=n,o.slice(Math.max(0,o.lastIndexOf(".",o.lastIndexOf(".")-1)+1))).toLowerCase();var o;const i="www."+r,a=t.toLowerCase();return n===i||n===r?a===i||a===r:n===a}function h(e,t){const n=t.hostname.toLowerCase(),a=t.pathname.toLowerCase();if(function(e){const t=e;return void 0!==t.url_condition&&null!==t.url_condition}(e))return Object(o.b)(e.url_condition,new i.a({url:t.toString(),url_host:n,url_path:a}));if(function(e){const t=e;return void 0!==t.url_host&&null!==t.url_host&&void 0!==t.url_path&&null!==t.url_path}(e)){const t=e.url_host.toLowerCase(),r=e.url_path.toLowerCase(),o=f(n,t),i=c(r,a);return o&&i}return r.b.notify("Invalid URL object",e),!1}const p=(e,t)=>Boolean(h(d(e),d(t)));function g(e){return e.replace("?","").split("&").reduce((e,t)=>{const[n,r]=t.split("="),o=n.split(".");return o.reduce((e,t,n)=>function(e,t){return"__proto__"===t||function(e,t){try{return t in e}catch(e){return!1}}(e,t)&&!(Object.hasOwnProperty.call(e,t)&&Object.propertyIsEnumerable.call(e,t))}(e,t)?{}:(n===o.length-1?e[t]="string"==typeof r?l(r):r||"":e[t]=e[t]||{},e[t]),e),e},{})}function m(e,t){const n=function(e){if(e===a.v.Editor||e===a.v.Preview){const e=g(window.location.search).url,t=Object(s.a)("a");return t.href=e||window.location.href,t}return window.location}(t);return e.filter(e=>h(e,n))}function v(e,t,n){const r=`${t}=${n}`;return e.includes(t+"=")?e.replace(new RegExp(t+"=[^&]*"),r):e.includes("?")?`${e}&${r}`:`${e}?${r}`}function y(e,t){return Object(u.d)(t).reduce((e,[t,n])=>null!=n?v(e,t,n):e,e)}},function(e,t,n){"use strict";n.d(t,"c",(function(){return r})),n.d(t,"e",(function(){return o})),n.d(t,"b",(function(){return i})),n.d(t,"a",(function(){return a})),n.d(t,"d",(function(){return u}));const r=e=>e,o=(e,t)=>{const n=new Set;return e.filter(e=>{const r=t(e);return!n.has(r)&&(n.add(r),!0)})};function i(e,t=r){for(const n of e)if(t(n))return!0;return!1}function a(e,t=r){for(const n of e)if(!t(n))return!1;return!0}function s(e,t,n){return n.indexOf(e)===t}function u(e){return e.filter(s)}},function(e,t,n){"use strict";n.d(t,"a",(function(){return r}));class r{static getCookie(e){var t;const n=("; "+document.cookie).split(`; ${e}=`);if(n.length>1)return null===(t=n.pop())||void 0===t?void 0:t.split(";").shift()}static setCookie(e,t,n){r.setTopLevelDomainCookie(e,t,window.location.hostname,n)}static isCookieSet(e){return void 0!==r.getCookie(e)}static tryCookieWrite(e,t){return document.cookie=`${e}=${t}`,r.isCookieSet(e)}static setTopLevelDomainCookie(e,t,n,o){const i=n.split(".");let a=2;for(;a<=i.length;){const n=i.slice(-a).join("."),s=`${t}; expires=${o.toUTCString()}; path=/; domain=.${n}`;if(r.tryCookieWrite(e,s))return;a+=1}}}},function(e,t,n){"use strict";n.d(t,"a",(function(){return i}));const r=document.createElement;document.createElement=Object.getPrototypeOf(document).createElement,n(23);const o=document.createElement,i=function(...e){return o.call(document,...e)};document.createElement=r},function(e,t,n){"use strict";n.d(t,"a",(function(){return f})),n.d(t,"c",(function(){return h})),n.d(t,"d",(function(){return p}));var r=n(20),o=n.n(r),i=n(18),a=n.n(i),s=n(21),u=n.n(s),c=n(2);const l=o()({apiKey:"caaf0e94c00c5dc6e1a1f1738570878d",autoCaptureSessions:!1,autoNotify:!1,consoleBreadcrumbsEnabled:!1,logger:null});l.metaData={mutinyClient:{version:u.a}},t.b=l;const d=new c.a("error-handler"),f=e=>l.metaData=a()(l.metaData,e);function h(e){try{return e()}catch(e){throw d.error("Error thrown:",e),l.notify(e),e}}const p=e=>(...t)=>h(()=>e(...t))},function(e,t,n){"use strict";n.d(t,"b",(function(){return a})),n.d(t,"d",(function(){return s})),n.d(t,"e",(function(){return u})),n.d(t,"c",(function(){return l})),n.d(t,"a",(function(){return d}));var r=n(2),o=function(e,t,n,r){return new(n||(n=Promise))((function(o,i){function a(e){try{u(r.next(e))}catch(e){i(e)}}function s(e){try{u(r.throw(e))}catch(e){i(e)}}function u(e){var t;e.done?o(e.value):(t=e.value,t instanceof n?t:new n((function(e){e(t)}))).then(a,s)}u((r=r.apply(e,t||[])).next())}))};const i=new WeakMap,a=(e,t)=>o(void 0,void 0,void 0,(function*(){var n,a;if(e[t])return e[t];const s=null===(n=i.get(e))||void 0===n?void 0:n.pendingProperties.get(t);if(s)return s;const u=((e,t)=>o(void 0,void 0,void 0,(function*(){return new Promise(n=>{const o=new r.a("on-set-"+t);let a,s=!1;Object.defineProperty(e,t,{configurable:!0,get:()=>a,set:r=>{var u;a=r,s||(o.log("Set",t),null===(u=i.get(e))||void 0===u||u.pendingProperties.delete(t),s=!0,n(a))}})})})))(e,t);return i.has(e)?null===(a=i.get(e))||void 0===a||a.pendingProperties.set(t,u):i.set(e,{pendingProperties:new Map([[t,u]])}),u}));function s(e){return Object.keys(e).reduce((t,n)=>(t.push([n,e[n]]),t),[])}function u(e){return Object.keys(e).reduce((t,n)=>(t.push(e[n]),t),[])}function c(e){return null!=e&&e.constructor!==Object}function l(e,t){if(null==e||e.constructor===Object&&0===Object.keys(e).length)return null;if(!t||!e||c(e))return e;if(e&&t in e&&c(e[t]))return e[t];const[n,...r]=t.split(".");return l(e[n],r.join("."))}function d(e){return Object.id(e)}(()=>{if(void 0===Object.id){let e=0;Object.id=t=>(void 0===t.__uniqueid&&Object.defineProperty(t,"__uniqueid",{value:++e,enumerable:!1,writable:!1}),t.__uniqueid)}})()},function(e,t,n){"use strict";n.d(t,"a",(function(){return a}));var r=n(3);class o{constructor(){this.data={}}getItem(e){return this.data.hasOwnProperty(e)?this.data[e]:null}setItem(e,t){this.data[e]=t}removeItem(e){delete this.data[e]}}let i;function a(){return i||(i=!Object(r.d)()&&function(){try{return localStorage.setItem("test","test"),"test"!==localStorage.getItem("test")?!1:(localStorage.removeItem("test"),!0)}catch(e){return!1}}()?localStorage:new o,i)}},function(e,t,n){"use strict";var r;n.d(t,"a",(function(){return r})),function(e){e[e.Conversion=0]="Conversion",e[e.Time=1]="Time",e[e.Questionnaire=2]="Questionnaire",e[e.QuestionnaireResponse=3]="QuestionnaireResponse",e[e.Event=4]="Event",e[e.ExperienceImpression=5]="ExperienceImpression",e[e.Metric=6]="Metric",e[e.VisitorIdentification=7]="VisitorIdentification"}(r||(r={}))},function(e,t,n){"use strict";function r(){var e,t;return(null===(e=document.querySelectorAll("script")[0])||void 0===e?void 0:e.nonce)||(null===(t=document.querySelectorAll("style")[0])||void 0===t?void 0:t.nonce)||""}n.d(t,"a",(function(){return r}))},function(e,t,n){"use strict";n.d(t,"a",(function(){return o}));var r=n(9);class o{constructor(e){this.data=e}get(e){return Object(r.c)(this.data,e)}}},function(e,t,n){"use strict";n.d(t,"b",(function(){return a})),n.d(t,"a",(function(){return s})),n.d(t,"c",(function(){return c}));var r=n(22),o=n(1),i=n(3);const a="_mv",s="_ms";let u;class c{constructor(e=new URLSearchParams(window.location.search)){this.queryParams=e}static get instance(){return null!=u?u:u=new this}getIsNewVisitor(){const e=Object(o.e)(o.c)||Object(o.e)("_immortal|mutiny.user.token");return!(this.queryParams.has(a)||e&&"null"!==e)}getVisitorToken(){const e=Object(o.e)(o.c)||Object(o.e)("_immortal|mutiny.user.token"),t=this.queryParams.get(a)||e||Object(r.a)();return this.getIsNewVisitor()&&!Object(i.c)()&&Object(o.g)(o.c,t),t}setVisitorToken(e){Object(i.c)()||Object(o.g)(o.c,e)}getIsNewSession(){const e=Object(o.d)(o.b);return!(this.queryParams.has(s)||e&&"null"!==e)}getSessionToken(){const e=Object(o.d)(o.b),t=this.queryParams.get(s)||e||Object(r.a)();return this.getIsNewSession()&&!Object(i.c)()&&Object(o.f)(o.b,t,18e5),t}setSessionToken(e){Object(i.c)()||Object(o.f)(o.b,e,18e5)}}},function(e,t,n){"use strict";n.d(t,"a",(function(){return c})),n.d(t,"b",(function(){return l})),n.d(t,"c",(function(){return f}));var r=n(0),o=n(11);var i,a,s=function(e,t,n,r){return new(n||(n=Promise))((function(o,i){function a(e){try{u(r.next(e))}catch(e){i(e)}}function s(e){try{u(r.throw(e))}catch(e){i(e)}}function u(e){var t;e.done?o(e.value):(t=e.value,t instanceof n?t:new n((function(e){e(t)}))).then(a,s)}u((r=r.apply(e,t||[])).next())}))};!function(e){e.MutinyHiderDuration="client.rum.hider.time",e.MutinyHiderLatency="client.rum.hider-start.time",e.FirstContentfulPaint="client.rum.fcp.time",e.LargestContentfulPaint="client.rum.lcp.time"}(i||(i={})),function(e){e.MutinyHiderAttached="mutiny-hider-attached",e.MutinyHiderRemoved="mutiny-hider-removed",e.MutinyHiderTime="mutiny-hider-time"}(a||(a={}));const u=function(){const e=new Set,t=new Array;return{emit(n){t.push(n),window.setTimeout(()=>{for(const t of e)t(n)})},listen:n=>(e.add(n),window.setTimeout(()=>{for(const e of t)n(e)}),()=>e.delete(n)),clear(){t.length=0,e.clear()}}}(),c=()=>{u.emit(window.performance.mark(a.MutinyHiderAttached))},l=()=>{u.emit(window.performance.mark(a.MutinyHiderRemoved))},d=()=>s(void 0,void 0,void 0,(function*(){return yield new Promise(e=>{const t=u.listen(n=>{n.name===a.MutinyHiderAttached&&(e(n),t())})}),yield new Promise(e=>{const t=u.listen(n=>{n.name===a.MutinyHiderRemoved&&(e(n),t())})}),window.performance.measure(a.MutinyHiderTime,a.MutinyHiderAttached,a.MutinyHiderRemoved)}));function f(e){d().then(({startTime:t,duration:n})=>{e.track(o.a.Metric,{value:n,metricKey:"client.rum.hider.time",metricType:r.p.Timing}),e.track(o.a.Metric,{value:t,metricKey:"client.rum.hider-latency.time",metricType:r.p.Timing})}),n.e(13).then(n.bind(null,111)).then(({onFCP:t,onLCP:n})=>{t(t=>e.track(o.a.Metric,{value:t.value,metricKey:"client.rum.fcp.time",metricType:r.p.Timing})),n(t=>e.track(o.a.Metric,{value:t.value,metricKey:"client.rum.lcp.time",metricType:r.p.Timing}))})}},function(e,t,n){"use strict";n.d(t,"a",(function(){return r})),n.d(t,"c",(function(){return o})),n.d(t,"d",(function(){return i})),n.d(t,"e",(function(){return a})),n.d(t,"b",(function(){return s}));const r=new RegExp(/{{\s*([\w.]+)\s*}}/,"g");function o(e,t){return e.replace(r,(e,n)=>{const r=t.get(n);return null===r?"":r.toString()})}function i(e,t){return Array.isArray(e)?e.map(e=>i(e,t)):"string"==typeof e?o(e,t):"object"!=typeof e||void 0===e||null==e?e:Object.keys(e).reduce((n,r)=>(n[r]=i(e[r],t),n),{})}function a(e){const[t,n]=e.split("[].",2);return{nestedPath:n||null,topLevelPath:t}}function s(e){var t;let n=0;if(0===e.length)return n;for(let r=0;r<e.length;r++){n=(n<<5)-n+(null!==(t=e.codePointAt(r))&&void 0!==t?t:0),n&=n}return n}},function(e,t,n){"use strict";n.d(t,"a",(function(){return l})),n.d(t,"b",(function(){return p}));var r=n(8),o=n(13),i=n(0),a=n(5),s=n(9),u=n(16),c=n(4);function l(e,t,n){switch(n){case i.d.Equal:return e===t;case i.d.NotEqual:return e!==t;case i.d.NotIncludes:return!e||!e.includes(t);case i.d.UrlNotEqual:return!e||!Object(c.j)(e,t);case i.d.UrlHostNotEqual:return!e||!Object(c.d)(e,t);case i.d.UrlPathNotEqual:return!e||!Object(c.e)(e,t);default:if(null==e)return!1;switch(n){case i.d.UrlEqual:return Object(c.j)(e,t);case i.d.GreaterThan:return e>t;case i.d.GreaterThanOrEqual:return e>=t;case i.d.LessThan:return e<t;case i.d.LessThanOrEqual:return e<=t;case i.d.Includes:return e&&e.includes(t);case i.d.StartsWith:return e&&e.startsWith(t);case i.d.EndsWith:return e&&e.endsWith(t);case i.d.MatchesRegex:return e&&Boolean(new RegExp(t).test(e));case i.d.UrlHostEqual:return e&&Object(c.d)(e,t);case i.d.UrlPathEqual:return e&&Object(c.e)(e,t)}}}function d(e,t){if(!e||0===Object.keys(e).length)return!0;const n=t(e),r=e.or&&e.or.length>0,o=e.and&&e.and.length>0;if(r&&o){const r=Object(a.b)(e.or,e=>d(e,t)),o=Object(a.a)(e.and,e=>d(e,t));return"and"===e.priority?n&&o||r:(n||r)&&o}return r?n||Object(a.b)(e.or,e=>d(e,t)):o?n&&Object(a.a)(e.and,e=>d(e,t)):n}function f(e,t){const n=e.attribute.includes("query.")&&e.value?Object(c.i)(e.value):e.value,{topLevelPath:d,nestedPath:f}=Object(u.e)(e.attribute);let g=t.get(d);return f?(g=g||[],Array.isArray(g)?function(e,t,n,r,u,c){const d=(u?function(e,t){return e.filter(e=>p(t,new o.a(e)))}(e,u):e).map(e=>Object(s.c)(e,t)),f=e=>l(e,n,r);switch(r){case i.d.Equal:case i.d.UrlEqual:return null==n&&0===d.length||h(d,a.b,f,c);case i.d.GreaterThan:case i.d.GreaterThanOrEqual:case i.d.LessThan:case i.d.LessThanOrEqual:return h(d,a.b,f,c);case i.d.NotEqual:case i.d.UrlNotEqual:return(null!=n||0!==d.length)&&h(d,a.a,f,c);case i.d.Includes:return d.length>0&&h(d,a.b,f,c);case i.d.NotIncludes:return 0===d.length||h(d,a.a,f,c);default:return!1}}(g,f,n,e.comparator,e.filter,e.aggregation):(r.b.notify("Invalid array condition on ",g),!1)):l(g,n,e.comparator)}function h(e,t,n,o){return o?d(o,({attribute:t,value:o,comparator:a})=>l(function(e,t){switch(t){case i.c.Count:return e.length;default:return r.b.notify("Unrecognized aggregation attribute",t),null}}(e.filter(n),t),o,a)):t(e,n)}function p(e,t){return d(e,e=>f(e,t))}},function(e,t,n){"use strict";var r=function(e){return function(e){return!!e&&"object"==typeof e}(e)&&!function(e){var t=Object.prototype.toString.call(e);return"[object RegExp]"===t||"[object Date]"===t||function(e){return e.$$typeof===o}(e)}(e)};var o="function"==typeof Symbol&&Symbol.for?Symbol.for("react.element"):60103;function i(e,t){return!1!==t.clone&&t.isMergeableObject(e)?l((n=e,Array.isArray(n)?[]:{}),e,t):e;var n}function a(e,t,n){return e.concat(t).map((function(e){return i(e,n)}))}function s(e){return Object.keys(e).concat(function(e){return Object.getOwnPropertySymbols?Object.getOwnPropertySymbols(e).filter((function(t){return e.propertyIsEnumerable(t)})):[]}(e))}function u(e,t){try{return t in e}catch(e){return!1}}function c(e,t,n){var r={};return n.isMergeableObject(e)&&s(e).forEach((function(t){r[t]=i(e[t],n)})),s(t).forEach((function(o){(function(e,t){return u(e,t)&&!(Object.hasOwnProperty.call(e,t)&&Object.propertyIsEnumerable.call(e,t))})(e,o)||(u(e,o)&&n.isMergeableObject(t[o])?r[o]=function(e,t){if(!t.customMerge)return l;var n=t.customMerge(e);return"function"==typeof n?n:l}(o,n)(e[o],t[o],n):r[o]=i(t[o],n))})),r}function l(e,t,n){(n=n||{}).arrayMerge=n.arrayMerge||a,n.isMergeableObject=n.isMergeableObject||r,n.cloneUnlessOtherwiseSpecified=i;var o=Array.isArray(t);return o===Array.isArray(e)?o?n.arrayMerge(e,t,n):c(e,t,n):i(t,n)}l.all=function(e,t){if(!Array.isArray(e))throw new Error("first argument should be an array");return e.reduce((function(e,n){return l(e,n,t)}),{})};var d=l;e.exports=d},function(e,t,n){"use strict";n.d(t,"a",(function(){return r}));const r=()=>{window.mutiny=window.mutiny||{},window.mutiny.attached=!0}},function(e,t,n){e.exports=function(){function e(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function t(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function n(){return K((Math.random()*re<<0).toString(ne),te)}function r(){return"c"+(new Date).getTime().toString(ne)+K((ee=ee<re?ee:0,++ee-1).toString(ne),te)+Z()+(n()+n())}function o(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function i(){if(!et(nt(),this[Ye])){var e={status:this.status,request:this[Ze]+" "+this[Ye]};this.status>=400?tt.leaveBreadcrumb("XMLHttpRequest failed",e,Qe):tt.leaveBreadcrumb("XMLHttpRequest succeeded",e,Qe)}}function a(){et(nt(),this[Ye])||tt.leaveBreadcrumb("XMLHttpRequest error",{request:this[Ze]+" "+this[Ye]},Qe)}function s(e){return"[Throws: "+(e?e.message:"?")+"]"}function u(e,t){try{return e[t]}catch(e){return s(e)}}function c(e){var t=[],n=0;return function e(r,o){function i(){return o>Ct&&n>Tt}if(n++,void 0===o&&(o=0),o>kt)return Nt;if(i())return Nt;if(null===r||"object"!=typeof r)return r;if(function(e,t){for(var n=0,r=e.length;n<r;n++)if(e[n]===t)return!0;return!1}(t,r))return"[Circular]";if(t.push(r),"function"==typeof r.toJSON)try{n--;var a=e(r.toJSON(),o);return t.pop(),a}catch(e){return s(e)}if(function(e){return"[object Array]"===Object.prototype.toString.call(e)}(r)){for(var c=[],l=0,d=r.length;l<d;l++){if(i()){c.push(Nt);break}c.push(e(r[l],o+1))}return t.pop(),c}var f={};try{for(var h in r)if(Object.prototype.hasOwnProperty.call(r,h)){if(i()){f[h]=Nt;break}f[h]=e(u(r,h),o+1)}}catch(e){}return t.pop(),f}(e)}var l=function(e,t,n){for(var r=n,o=0,i=e.length;o<i;o++)r=t(r,e[o],o,e);return r},d=!{toString:null}.propertyIsEnumerable("toString"),f=["toString","toLocaleString","valueOf","hasOwnProperty","isPrototypeOf","propertyIsEnumerable","constructor"],h=function(e){return e<10?"0"+e:e},p=function(e,t){return l(e,(function(e,n,r,o){return e.concat(t(n,r,o))}),[])},g=l,m=function(e,t){return l(e,(function(e,n,r,o){return t(n,r,o)?e.concat(n):e}),[])},v=function(e,t){return l(e,(function(e,n,r,o){return!0===e||n===t}),!1)},y=function(e){var t=[],n=void 0;for(n in e)Object.prototype.hasOwnProperty.call(e,n)&&t.push(n);if(!d)return t;for(var r=0,o=f.length;r<o;r++)Object.prototype.hasOwnProperty.call(e,f[r])&&t.push(f[r]);return t},b=function(e){return"[object Array]"===Object.prototype.toString.call(e)},w=function(){var e=new Date;return e.getUTCFullYear()+"-"+h(e.getUTCMonth()+1)+"-"+h(e.getUTCDate())+"T"+h(e.getUTCHours())+":"+h(e.getUTCMinutes())+":"+h(e.getUTCSeconds())+"."+(e.getUTCMilliseconds()/1e3).toFixed(3).slice(2,5)+"Z"},S=w,O=function(){function t(){var n=arguments.length>0&&void 0!==arguments[0]?arguments[0]:"[anonymous]",r=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{},o=arguments.length>2&&void 0!==arguments[2]?arguments[2]:"manual",i=arguments.length>3&&void 0!==arguments[3]?arguments[3]:S();e(this,t),this.type=o,this.name=n,this.metaData=r,this.timestamp=i}return t.prototype.toJSON=function(){return{type:this.type,name:this.name,timestamp:this.timestamp,metaData:this.metaData}},t}(),_={},j=v;_.positiveIntIfDefined=function(e){return j(["undefined","number"],typeof e)&&parseInt(""+e,10)===e&&e>0},_.stringWithLength=function(e){return"string"==typeof e&&!!e.length};var E={},k=m,T=g,C=y,N=b,L=v,q=_.positiveIntIfDefined,M=_.stringWithLength;E.schema={apiKey:{defaultValue:function(){return null},message:"is required",validate:M},appVersion:{defaultValue:function(){return null},message:"should be a string",validate:function(e){return null===e||M(e)}},autoNotify:{defaultValue:function(){return!0},message:"should be true|false",validate:function(e){return!0===e||!1===e}},beforeSend:{defaultValue:function(){return[]},message:"should be a function or array of functions",validate:function(e){return"function"==typeof e||N(e)&&k(e,(function(e){return"function"==typeof e})).length===e.length}},endpoints:{defaultValue:function(){return{notify:"https://notify.bugsnag.com",sessions:"https://sessions.bugsnag.com"}},message:"should be an object containing endpoint URLs { notify, sessions }. sessions is optional if autoCaptureSessions=false",validate:function(e,t){return e&&"object"==typeof e&&M(e.notify)&&(!1===t.autoCaptureSessions||M(e.sessions))&&0===k(C(e),(function(e){return!L(["notify","sessions"],e)})).length}},autoCaptureSessions:{defaultValue:function(e,t){return void 0===t.endpoints||!!t.endpoints&&!!t.endpoints.sessions},message:"should be true|false",validate:function(e){return!0===e||!1===e}},notifyReleaseStages:{defaultValue:function(){return null},message:"should be an array of strings",validate:function(e){return null===e||N(e)&&k(e,(function(e){return"string"==typeof e})).length===e.length}},releaseStage:{defaultValue:function(){return"production"},message:"should be a string",validate:function(e){return"string"==typeof e&&e.length}},maxBreadcrumbs:{defaultValue:function(){return 20},message:"should be a number ≤40",validate:function(e){return 0===e||q(e)&&(void 0===e||e<=40)}},autoBreadcrumbs:{defaultValue:function(){return!0},message:"should be true|false",validate:function(e){return"boolean"==typeof e}},user:{defaultValue:function(){return null},message:"(object) user should be an object",validate:function(e){return"object"==typeof e}},metaData:{defaultValue:function(){return null},message:"should be an object",validate:function(e){return"object"==typeof e}},logger:{defaultValue:function(){},message:"should be null or an object with methods { debug, info, warn, error }",validate:function(e){return!e||e&&T(["debug","info","warn","error"],(function(t,n){return t&&"function"==typeof e[n]}),!0)}}},E.mergeDefaults=function(e,t){if(!e||!t)throw new Error("opts and schema objects are required");return T(C(t),(function(n,r){return n[r]=void 0!==e[r]?e[r]:t[r].defaultValue(e[r],e),n}),{})},E.validate=function(e,t){if(!e||!t)throw new Error("opts and schema objects are required");var n=T(C(t),(function(n,r){return t[r].validate(e[r],e)?n:n.concat({key:r,message:t[r].message,value:e[r]})}),[]);return{valid:!n.length,errors:n}};var x=function(e){return e.app&&"string"==typeof e.app.releaseStage?e.app.releaseStage:e.config.releaseStage},P=function(e){return!(!e||!e.stack&&!e.stacktrace&&!e["opera#sourceloc"]||"string"!=typeof(e.stack||e.stacktrace||e["opera#sourceloc"])||e.stack===e.name+": "+e.message)},A={};!function(e,t){"use strict";"object"==typeof A?A=t():e.StackFrame=t()}(this,(function(){"use strict";function e(e){return!isNaN(parseFloat(e))&&isFinite(e)}function t(e){return e.charAt(0).toUpperCase()+e.substring(1)}function n(e){return function(){return this[e]}}function r(e){if(e instanceof Object)for(var n=0;n<s.length;n++)e.hasOwnProperty(s[n])&&void 0!==e[s[n]]&&this["set"+t(s[n])](e[s[n]])}var o=["isConstructor","isEval","isNative","isToplevel"],i=["columnNumber","lineNumber"],a=["fileName","functionName","source"],s=o.concat(i,a,["args"]);r.prototype={getArgs:function(){return this.args},setArgs:function(e){if("[object Array]"!==Object.prototype.toString.call(e))throw new TypeError("Args must be an Array");this.args=e},getEvalOrigin:function(){return this.evalOrigin},setEvalOrigin:function(e){if(e instanceof r)this.evalOrigin=e;else{if(!(e instanceof Object))throw new TypeError("Eval Origin must be an Object or StackFrame");this.evalOrigin=new r(e)}},toString:function(){return(this.getFunctionName()||"{anonymous}")+"("+(this.getArgs()||[]).join(",")+")"+(this.getFileName()?"@"+this.getFileName():"")+(e(this.getLineNumber())?":"+this.getLineNumber():"")+(e(this.getColumnNumber())?":"+this.getColumnNumber():"")}};for(var u=0;u<o.length;u++)r.prototype["get"+t(o[u])]=n(o[u]),r.prototype["set"+t(o[u])]=function(e){return function(t){this[e]=Boolean(t)}}(o[u]);for(var c=0;c<i.length;c++)r.prototype["get"+t(i[c])]=n(i[c]),r.prototype["set"+t(i[c])]=function(t){return function(n){if(!e(n))throw new TypeError(t+" must be a Number");this[t]=Number(n)}}(i[c]);for(var l=0;l<a.length;l++)r.prototype["get"+t(a[l])]=n(a[l]),r.prototype["set"+t(a[l])]=function(e){return function(t){this[e]=String(t)}}(a[l]);return r}));var D={};!function(e,t){"use strict";"object"==typeof D?D=t(A):e.ErrorStackParser=t(e.StackFrame)}(this,(function(e){"use strict";var t=/(^|@)\S+\:\d+/,n=/^\s*at .*(\S+\:\d+|\(native\))/m,r=/^(eval@)?(\[native code\])?$/;return{parse:function(e){if(void 0!==e.stacktrace||void 0!==e["opera#sourceloc"])return this.parseOpera(e);if(e.stack&&e.stack.match(n))return this.parseV8OrIE(e);if(e.stack)return this.parseFFOrSafari(e);throw new Error("Cannot parse given Error object")},extractLocation:function(e){if(-1===e.indexOf(":"))return[e];var t=/(.+?)(?:\:(\d+))?(?:\:(\d+))?$/.exec(e.replace(/[\(\)]/g,""));return[t[1],t[2]||void 0,t[3]||void 0]},parseV8OrIE:function(t){return t.stack.split("\n").filter((function(e){return!!e.match(n)}),this).map((function(t){t.indexOf("(eval ")>-1&&(t=t.replace(/eval code/g,"eval").replace(/(\(eval at [^\()]*)|(\)\,.*$)/g,""));var n=t.replace(/^\s+/,"").replace(/\(eval code/g,"(").split(/\s+/).slice(1),r=this.extractLocation(n.pop()),o=n.join(" ")||void 0,i=["eval","<anonymous>"].indexOf(r[0])>-1?void 0:r[0];return new e({functionName:o,fileName:i,lineNumber:r[1],columnNumber:r[2],source:t})}),this)},parseFFOrSafari:function(t){return t.stack.split("\n").filter((function(e){return!e.match(r)}),this).map((function(t){if(t.indexOf(" > eval")>-1&&(t=t.replace(/ line (\d+)(?: > eval line \d+)* > eval\:\d+\:\d+/g,":$1")),-1===t.indexOf("@")&&-1===t.indexOf(":"))return new e({functionName:t});var n=/((.*".+"[^@]*)?[^@]*)(?:@)/,r=t.match(n),o=r&&r[1]?r[1]:void 0,i=this.extractLocation(t.replace(n,""));return new e({functionName:o,fileName:i[0],lineNumber:i[1],columnNumber:i[2],source:t})}),this)},parseOpera:function(e){return!e.stacktrace||e.message.indexOf("\n")>-1&&e.message.split("\n").length>e.stacktrace.split("\n").length?this.parseOpera9(e):e.stack?this.parseOpera11(e):this.parseOpera10(e)},parseOpera9:function(t){for(var n=/Line (\d+).*script (?:in )?(\S+)/i,r=t.message.split("\n"),o=[],i=2,a=r.length;i<a;i+=2){var s=n.exec(r[i]);s&&o.push(new e({fileName:s[2],lineNumber:s[1],source:r[i]}))}return o},parseOpera10:function(t){for(var n=/Line (\d+).*script (?:in )?(\S+)(?:: In function (\S+))?$/i,r=t.stacktrace.split("\n"),o=[],i=0,a=r.length;i<a;i+=2){var s=n.exec(r[i]);s&&o.push(new e({functionName:s[3]||void 0,fileName:s[2],lineNumber:s[1],source:r[i]}))}return o},parseOpera11:function(n){return n.stack.split("\n").filter((function(e){return!!e.match(t)&&!e.match(/^Error created at/)}),this).map((function(t){var n,r=t.split("@"),o=this.extractLocation(r.pop()),i=r.shift()||"",a=i.replace(/<anonymous function(: (\w+))?>/,"$2").replace(/\([^\)]*\)/g,"")||void 0;i.match(/\(([^\)]*)\)/)&&(n=i.replace(/^[^\(]+\(([^\)]*)\)$/,"$1"));var s=void 0===n||"[arguments not available]"===n?void 0:n.split(",");return new e({functionName:a,args:s,fileName:o[0],lineNumber:o[1],columnNumber:o[2],source:t})}),this)}}}));var R={};!function(e,t){"use strict";"object"==typeof R?R=t(A):e.StackGenerator=t(e.StackFrame)}(this,(function(e){return{backtrace:function(t){var n=[],r=10;"object"==typeof t&&"number"==typeof t.maxStackSize&&(r=t.maxStackSize);for(var o=arguments.callee;o&&n.length<r&&o.arguments;){for(var i=new Array(o.arguments.length),a=0;a<i.length;++a)i[a]=o.arguments[a];/function(?:\s+([\w$]+))+\s*\(/.test(o.toString())?n.push(new e({functionName:RegExp.$1||void 0,args:i})):n.push(new e({args:i}));try{o=o.caller}catch(e){break}}return n}}}));var I=Object.assign||function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(e[r]=n[r])}return e},B=g,U=m,H=function(){function e(n,r){var o=arguments.length>2&&void 0!==arguments[2]?arguments[2]:[],i=arguments.length>3&&void 0!==arguments[3]?arguments[3]:F();t(this,e),this.__isBugsnagReport=!0,this._ignored=!1,this._handledState=i,this.app=void 0,this.apiKey=void 0,this.breadcrumbs=[],this.context=void 0,this.device=void 0,this.errorClass=z(n,"[no error class]"),this.errorMessage=z(r,"[no error message]"),this.groupingHash=void 0,this.metaData={},this.request=void 0,this.severity=this._handledState.severity,this.stacktrace=B(o,(function(e,t){var n=$(t);try{return"{}"===JSON.stringify(n)?e:e.concat(n)}catch(t){return e}}),[]),this.user=void 0,this.session=void 0}return e.prototype.ignore=function(){this._ignored=!0},e.prototype.isIgnored=function(){return this._ignored},e.prototype.updateMetaData=function(e){var t;if(!e)return this;var n=void 0;return null===(arguments.length<=1?void 0:arguments[1])?this.removeMetaData(e):null===(arguments.length<=2?void 0:arguments[2])?this.removeMetaData(e,arguments.length<=1?void 0:arguments[1],arguments.length<=2?void 0:arguments[2]):("object"==typeof(arguments.length<=1?void 0:arguments[1])&&(n=arguments.length<=1?void 0:arguments[1]),"string"==typeof(arguments.length<=1?void 0:arguments[1])&&((t={})[arguments.length<=1?void 0:arguments[1]]=arguments.length<=2?void 0:arguments[2],n=t),n?(this.metaData[e]||(this.metaData[e]={}),this.metaData[e]=I({},this.metaData[e],n),this):this)},e.prototype.removeMetaData=function(e,t){return"string"!=typeof e?this:t?this.metaData[e]?(delete this.metaData[e][t],this):this:(delete this.metaData[e],this)},e.prototype.toJSON=function(){return{payloadVersion:"4",exceptions:[{errorClass:this.errorClass,message:this.errorMessage,stacktrace:this.stacktrace,type:"browserjs"}],severity:this.severity,unhandled:this._handledState.unhandled,severityReason:this._handledState.severityReason,app:this.app,device:this.device,breadcrumbs:this.breadcrumbs,context:this.context,user:this.user,metaData:this.metaData,groupingHash:this.groupingHash,request:this.request,session:this.session}},e}(),$=function(e){var t={file:e.fileName,method:V(e.functionName),lineNumber:e.lineNumber,columnNumber:e.columnNumber,code:void 0,inProject:void 0};return t.lineNumber>-1&&!t.file&&!t.method&&(t.file="global code"),t},V=function(e){return/^global code$/i.test(e)?"global code":e},F=function(){return{unhandled:!1,severity:"warning",severityReason:{type:"handledException"}}},z=function(e,t){return"string"==typeof e&&e?e:t};H.getStacktrace=function(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:0,n=arguments.length>2&&void 0!==arguments[2]?arguments[2]:0;return P(e)?D.parse(e).slice(t):U(R.backtrace(),(function(e){return-1===(e.functionName||"").indexOf("StackGenerator$$")})).slice(1+n)},H.ensureReport=function(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:0,n=arguments.length>2&&void 0!==arguments[2]?arguments[2]:0;if(e.__isBugsnagReport)return e;try{var r=H.getStacktrace(e,t,1+n);return new H(e.name,e.message,r)}catch(t){return new H(e.name,e.message,[])}};var W=H,K=function(e,t){var n="000000000"+e;return n.substr(n.length-t)},X="object"==typeof window?window:self,G=0;for(var J in X)Object.hasOwnProperty.call(X,J)&&G++;var Q=navigator.mimeTypes?navigator.mimeTypes.length:0,Y=K((Q+navigator.userAgent.length).toString(36)+G.toString(36),4),Z=function(){return Y},ee=0,te=4,ne=36,re=Math.pow(ne,te);r.fingerprint=Z;var oe=r,ie=w,ae=function(){function e(){(function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")})(this,e),this.id=oe(),this.startedAt=ie(),this._handled=0,this._unhandled=0}return e.prototype.toJSON=function(){return{id:this.id,startedAt:this.startedAt,events:{handled:this._handled,unhandled:this._unhandled}}},e.prototype.trackError=function(e){this[e._handledState.unhandled?"_unhandled":"_handled"]+=1},e}(),se=function(e){switch(Object.prototype.toString.call(e)){case"[object Error]":case"[object Exception]":case"[object DOMException]":return!0;default:return e instanceof Error}},ue=Object.assign||function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(e[r]=n[r])}return e},ce=p,le=g,de=v,fe=b,he=function(){},pe=function(){function e(t){var n=arguments.length>1&&void 0!==arguments[1]?arguments[1]:E.schema,r=arguments.length>2&&void 0!==arguments[2]?arguments[2]:null;if(o(this,e),!(t&&t.name&&t.version&&t.url))throw new Error("`notifier` argument is required");this.notifier=t,this.configSchema=n,this._configured=!1,this._transport={sendSession:he,sendReport:he},this._logger={debug:he,info:he,warn:he,error:he},this.plugins=[],this.session=r,this.beforeSession=[],this.breadcrumbs=[],this.app={},this.context=void 0,this.device=void 0,this.metaData=void 0,this.request=void 0,this.user={},this.BugsnagReport=W,this.BugsnagBreadcrumb=O,this.BugsnagSession=ae}return e.prototype.configure=function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{};this.config=E.mergeDefaults(ue({},this.config,e),this.configSchema);var t=E.validate(this.config,this.configSchema);if(1==!t.valid)throw new Error(ve(t.errors));return"function"==typeof this.config.beforeSend&&(this.config.beforeSend=[this.config.beforeSend]),null!==this.config.appVersion&&(this.app.version=this.config.appVersion),this.config.metaData&&(this.metaData=this.config.metaData),this.config.user&&(this.user=this.config.user),this.config.logger&&this.logger(this.config.logger),this._configured=!0,this._logger.debug("Loaded!"),this},e.prototype.use=function(e){return this.plugins.push(e),e.init(this)},e.prototype.transport=function(e){return this._transport=e,this},e.prototype.logger=function(e,t){return this._logger=e,this},e.prototype.sessionDelegate=function(e){return this._sessionDelegate=e,this},e.prototype.startSession=function(){return this._sessionDelegate?this._sessionDelegate.startSession(this):(this._logger.warn("No session implementation is installed"),this)},e.prototype.leaveBreadcrumb=function(e,t,n,r){if(!this._configured)throw new Error("client not configured");if(n="string"==typeof n?n:void 0,r="string"==typeof r?r:void 0,t="object"==typeof t&&null!==t?t:void 0,"string"==typeof(e=e||void 0)||t){var o=new O(e,t,n,r);return this.breadcrumbs.push(o),this.breadcrumbs.length>this.config.maxBreadcrumbs&&(this.breadcrumbs=this.breadcrumbs.slice(this.breadcrumbs.length-this.config.maxBreadcrumbs)),this}},e.prototype.notify=function(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{};if(!this._configured)throw new Error("client not configured");var n=x(this),r=ge(e,t,this._logger),o=r.err,i=r.errorFramesToSkip,a=r._opts;if(a&&(t=a),!o){var s=ye("nothing");this._logger.warn("Usage error. "+s),o=new Error("Bugsnag usage error. "+s)}"object"==typeof t&&null!==t||(t={});var u=W.ensureReport(o,i,1);if(u.app=ue({releaseStage:n},u.app,this.app),u.context=u.context||t.context||this.context||void 0,u.device=ue({},u.device,this.device,t.device),u.request=ue({},u.request,this.request,t.request),u.user=ue({},u.user,this.user,t.user),u.metaData=ue({},u.metaData,this.metaData,t.metaData),u.breadcrumbs=this.breadcrumbs.slice(0),this.session&&(this.session.trackError(u),u.session=this.session),void 0!==t.severity&&(u.severity=t.severity,u._handledState.severityReason={type:"userSpecifiedSeverity"}),fe(this.config.notifyReleaseStages)&&!de(this.config.notifyReleaseStages,n))return this._logger.warn("Report not sent due to releaseStage/notifyReleaseStages configuration"),!1;var c=u.severity,l=[].concat(t.beforeSend).concat(this.config.beforeSend);return le(l,(function(e,t){return!0===e||"function"==typeof t&&!1===t(u)||!!u.isIgnored()}),!1)?(this._logger.debug("Report not sent due to beforeSend callback"),!1):(this.config.autoBreadcrumbs&&this.leaveBreadcrumb(u.errorClass,{errorClass:u.errorClass,errorMessage:u.errorMessage,severity:u.severity},"error"),c!==u.severity&&(u._handledState.severityReason={type:"userCallbackSetSeverity"}),this._transport.sendReport(this._logger,this.config,{apiKey:u.apiKey||this.config.apiKey,notifier:this.notifier,events:[u]}),!0)},e}(),ge=function(e,t,n){var r=void 0,o=0,i=void 0;switch(typeof e){case"string":if("string"==typeof t){var a=ye("string/string");n.warn("Usage error. "+a),r=new Error("Bugsnag usage error. "+a),i={metaData:{notifier:{notifyArgs:[e,t]}}}}else r=new Error(String(e)),o+=2;break;case"number":case"boolean":r=new Error(String(e));break;case"function":var s=ye("function");n.warn("Usage error. "+s),r=new Error("Bugsnag usage error. "+s);break;case"object":if(null!==e&&(se(e)||e.__isBugsnagReport))r=e;else if(null!==e&&me(e))(r=new Error(e.message||e.errorMessage)).name=e.name||e.errorClass,o+=2;else{var u=ye("unsupported object");n.warn("Usage error. "+u),r=new Error("Bugsnag usage error. "+u)}}return{err:r,errorFramesToSkip:o,_opts:i}},me=function(e){return!("string"!=typeof e.name&&"string"!=typeof e.errorClass||"string"!=typeof e.message&&"string"!=typeof e.errorMessage)},ve=function(e){return"Bugsnag configuration error\n"+ce(e,(function(e){return'"'+e.key+'" '+e.message+" \n got "+be(e.value)})).join("\n\n")},ye=function(e){return"notify() expected error/opts parameters, got "+e},be=function(e){return"object"==typeof e?JSON.stringify(e):String(e)},we=pe,Se=_.positiveIntIfDefined,Oe={init:function(e){var t=0;e.config.beforeSend.push((function(n){if(t>=e.config.maxEvents)return n.ignore();t++})),e.refresh=function(){t=0}},configSchema:{maxEvents:{defaultValue:function(){return 10},message:"should be a positive integer ≤100",validate:function(e){return Se(e)&&e<100}}}},_e=Object.assign||function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(e[r]=n[r])}return e},je=E.schema,Ee=p,ke={releaseStage:{defaultValue:function(){return/^localhost(:\d+)?$/.test(window.location.host)?"development":"production"},message:"should be set",validate:_.stringWithLength},collectUserIp:{defaultValue:function(){return!0},message:"should be true|false",validate:function(e){return!0===e||!1===e}},logger:_e({},je.logger,{defaultValue:function(){return"undefined"!=typeof console&&"function"==typeof console.debug?Te():void 0}})},Te=function(){var e={},t=console.log;return Ee(["debug","info","warn","error"],(function(n){var r=console[n];e[n]="function"==typeof r?r.bind(console,"[bugsnag]"):t.bind(console,"[bugsnag]")})),e},Ce={},Ne=p,Le=g,qe=m;Ce.init=function(e){Ne(Me,(function(t){var n=console[t];console[t]=function(){for(var r=arguments.length,o=Array(r),i=0;i<r;i++)o[i]=arguments[i];e.leaveBreadcrumb("Console output",Le(o,(function(e,t,n){var r=String(t);if("[object Object]"===r)try{r=JSON.stringify(t)}catch(e){}return e["["+n+"]"]=r,e}),{severity:0===t.indexOf("group")?"log":t}),"log"),n.apply(console,o)},console[t]._restore=function(){console[t]=n}}))},Ce.configSchema={consoleBreadcrumbsEnabled:{defaultValue:function(){},validate:function(e){return!0===e||!1===e||void 0===e},message:"should be true|false"}};var Me=qe(["log","debug","info","warn","error"],(function(e){return"undefined"!=typeof console&&"function"==typeof console[e]})),xe={init:function(e){e.config.beforeSend.unshift((function(e){e.context||(e.context=window.location.pathname)}))}},Pe=Object.assign||function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(e[r]=n[r])}return e},Ae=w,De={init:function(e){e.config.beforeSend.unshift((function(e){e.device=Pe({time:Ae(),locale:navigator.browserLanguage||navigator.systemLanguage||navigator.userLanguage||navigator.language,userAgent:navigator.userAgent},e.device)})),e.beforeSession.push((function(e){e.device={userAgent:navigator.userAgent}}))}},Re={},Ie=g,Be=/^.*<script.*?>/,Ue=/<\/script>.*$/,He=(Re={init:function(e){var t="",n=!1,r=function(){return document.documentElement.outerHTML},o=window.location.href;t=r(),document.onreadystatechange=function(){"interactive"===document.readyState&&(t=r(),n=!0)},e.config.beforeSend.unshift((function(e){var i=e.stacktrace[0];if(!i||!i.file||!i.lineNumber)return i;if(i.file.replace(/#.*$/,"")!==o.replace(/#.*$/,""))return i;n&&t||(t=r());var a=["\x3c!-- DOC START --\x3e"].concat(t.split("\n")),s=He(a,i.lineNumber-1),u=s.script,c=s.start,l=Ie(u,(function(e,t,n){return Math.abs(c+n+1-i.lineNumber)>10||(e[""+(c+n+1)]=t),e}),{});i.code=l,e.updateMetaData("script",{content:u.join("\n")})}))}}).extractScriptContent=function(e,t){for(var n=t;n<e.length&&!Ue.test(e[n]);)n++;for(var r=n;n>0&&!Be.test(e[n]);)n--;var o=n,i=e.slice(o,r+1);return i[0]=i[0].replace(Be,""),i[i.length-1]=i[i.length-1].replace(Ue,""),{script:i,start:o}},$e={init:function(e){"addEventListener"in window&&window.addEventListener("click",(function(t){var n=void 0,r=void 0;try{n=Ve(t.target),r=function e(t){var n=[t.tagName];if(t.id&&n.push("#"+t.id),t.className&&t.className.length&&n.push("."+t.className.split(" ").join(".")),!document.querySelectorAll||!Array.prototype.indexOf)return n.join("");try{if(1===document.querySelectorAll(n.join("")).length)return n.join("")}catch(e){return n.join("")}if(t.parentNode.childNodes.length>1){var r=Array.prototype.indexOf.call(t.parentNode.childNodes,t)+1;n.push(":nth-child("+r+")")}return 1===document.querySelectorAll(n.join("")).length?n.join(""):t.parentNode?e(t.parentNode)+" > "+n.join(""):n.join("")}(t.target)}catch(t){n="[hidden]",r="[hidden]",e._logger.error("Cross domain error when tracking click event. See docs: https://tinyurl.com/y94fq5zm")}e.leaveBreadcrumb("UI click",{targetText:n,targetSelector:r},"user")}),!0)},configSchema:{interactionBreadcrumbsEnabled:{defaultValue:function(){},validate:function(e){return!0===e||!1===e||void 0===e},message:"should be true|false"}}},Ve=function(e){var t=e.textContent||e.innerText||"";return t||"submit"!==e.type&&"button"!==e.type||(t=e.value),function(e,t){return e&&e.length<=t?e:e.slice(0,t-"(...)".length)+"(...)"}(t=t.replace(/^\s+|\s+$/g,""),140)},Fe=Object.assign||function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(e[r]=n[r])}return e},ze={init:function(e){e.config.collectUserIp||e.config.beforeSend.push((function(e){e.user=Fe({id:"[NOT COLLECTED]"},e.user),e.request=Fe({clientIp:"[NOT COLLECTED]"},e.request)}))}},We={init:function(e){if("addEventListener"in window){var t=function(t){return function(){return e.leaveBreadcrumb(t,{},"navigation")}};window.addEventListener("pagehide",t("Page hidden"),!0),window.addEventListener("pageshow",t("Page shown"),!0),window.addEventListener("load",t("Page loaded"),!0),window.document.addEventListener("DOMContentLoaded",t("DOMContentLoaded"),!0),window.addEventListener("load",(function(){return window.addEventListener("popstate",t("Navigated back"),!0)})),window.addEventListener("hashchange",(function(t){var n=t.oldURL?{from:Ke(t.oldURL),to:Ke(t.newURL),state:Ge()}:{to:Ke(window.location.href)};e.leaveBreadcrumb("Hash changed",n,"navigation")}),!0),window.history.replaceState&&Xe(e,window.history,"replaceState"),window.history.pushState&&Xe(e,window.history,"pushState"),e.leaveBreadcrumb("Bugsnag loaded",{},"navigation")}},configSchema:{navigationBreadcrumbsEnabled:{defaultValue:function(){},validate:function(e){return!0===e||!1===e||void 0===e},message:"should be true|false"}}},Ke=function(e){var t=document.createElement("A");return t.href=e,""+t.pathname+t.search+t.hash},Xe=function(e,t,n){var r=t[n];t[n]=function(o,i,a){e.leaveBreadcrumb("History "+n,function(e,t,n){var r=Ke(window.location.href);return{title:t,state:e,prevState:Ge(),to:n||r,from:r}}(o,i,a),"navigation"),"function"==typeof e.refresh&&e.refresh(),e.session&&e.startSession(),r.apply(t,[o,i].concat(void 0!==a?a:[]))},t[n]._restore=function(){t[n]=r}},Ge=function(){try{return window.history.state}catch(e){}},Je={},Qe="request",Ye="BS~~U",Ze="BS~~M",et=v,tt=void 0,nt=function(){return[tt.config.endpoints.notify,tt.config.endpoints.sessions]};Je.init=function(e){tt=e,rt(),ot()},Je.configSchema={networkBreadcrumbsEnabled:{defaultValue:function(){},validate:function(e){return!0===e||!1===e||void 0===e},message:"should be true|false"}};var rt=function(){if("addEventListener"in window.XMLHttpRequest.prototype){var e=window.XMLHttpRequest.prototype.open;window.XMLHttpRequest.prototype.open=function(t,n){this[Ye]=n,this[Ze]=t,this["BS~~S"]&&(this.removeEventListener("load",i),this.removeEventListener("error",a)),this.addEventListener("load",i),this.addEventListener("error",a),this["BS~~S"]=!0,e.apply(this,arguments)}}},ot=function(){if("fetch"in window){var e=window.fetch;window.fetch=function(){for(var t=arguments.length,n=Array(t),r=0;r<t;r++)n[r]=arguments[r];var o=n[0],i=n[1],a="GET";return i&&i.method&&(a=i.method),new Promise((function(t,r){e.apply(void 0,n).then((function(e){it(e,a,o),t(e)})).catch((function(e){at(a,o),r(e)}))}))}}},it=function(e,t,n){var r={status:e.status,request:t+" "+n};e.status>=400?tt.leaveBreadcrumb("fetch() failed",r,Qe):tt.leaveBreadcrumb("fetch() succeeded",r,Qe)},at=function(e,t){tt.leaveBreadcrumb("fetch() error",{request:e+" "+t},Qe)},st=Object.assign||function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(e[r]=n[r])}return e},ut={init:function(e){e.config.beforeSend.unshift((function(e){e.request&&e.request.url||(e.request=st({},e.request,{url:window.location.href}))}))}},ct=Object.assign||function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(e[r]=n[r])}return e},lt=p,dt=b,ft=v,ht={init:function(e){return e.sessionDelegate(pt)}},pt={startSession:function(e){var t=e;t.session=new e.BugsnagSession,lt(t.beforeSession,(function(e){return e(t)}));var n=x(t);return dt(t.config.notifyReleaseStages)&&!ft(t.config.notifyReleaseStages,n)?(t._logger.warn("Session not sent due to releaseStage/notifyReleaseStages configuration"),t):t.config.endpoints.sessions?(t._transport.sendSession(t._logger,t.config,{notifier:t.notifier,device:t.device,app:ct({releaseStage:n},t.app),sessions:[{id:t.session.id,startedAt:t.session.startedAt,user:t.user}]}),t):(t._logger.warn("Session not sent due to missing endpoints.sessions configuration"),t)}},gt={},mt=Object.assign||function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(e[r]=n[r])}return e},vt=p,yt=(gt={init:function(e){e.config.beforeSend.push((function(e){e.stacktrace=vt(e.stacktrace,(function(e){return mt({},e,{file:yt(e.file)})}))}))}})._strip=function(e){return"string"==typeof e?e.replace(/\?.*$/,"").replace(/#.*$/,""):e},bt={},wt=g;bt.init=function(e){var t=function(t){var n=t.reason,r=!1;t.detail&&t.detail.reason&&(n=t.detail.reason,r=!0);var o={severity:"error",unhandled:!0,severityReason:{type:"unhandledPromiseRejection"}},i=void 0;n&&P(n)?(i=new e.BugsnagReport(n.name,n.message,D.parse(n),o),r&&(i.stacktrace=wt(i.stacktrace,Ot(n),[]))):(i=new e.BugsnagReport(n&&n.name?n.name:"UnhandledRejection",n&&n.message?n.message:'Rejection reason was not an Error. See "Promise" tab for more detail.',[],o)).updateMetaData("promise","rejection reason",St(n)),e.notify(i)};"addEventListener"in window?window.addEventListener("unhandledrejection",t):window.onunhandledrejection=function(e,n){t({detail:{reason:e,promise:n}})}};var St=function(e){return null==e?"undefined (or null)":se(e)?((t={})[Object.prototype.toString.call(e)]={name:e.name,message:e.message,code:e.code,stack:e.stack},t):e;var t},Ot=function(e){return function(t,n){return n.file===e.toString()?t:(n.method&&(n.method=n.method.replace(/^\s+/,"")),t.concat(n))}},_t={init:function(e){var t=window.onerror;window.onerror=function(n,r,o,i,a){if(0===o&&/Script error\.?/.test(n))e._logger.warn("Ignoring cross-domain or eval script error. See docs: https://tinyurl.com/y94fq5zm");else{var s={severity:"error",unhandled:!0,severityReason:{type:"unhandledException"}},u=void 0;if(a)a.name&&a.message?u=new e.BugsnagReport(a.name,a.message,jt(e.BugsnagReport.getStacktrace(a),r,o,i),s):(u=new e.BugsnagReport("window.onerror",String(a),jt(e.BugsnagReport.getStacktrace(a,1),r,o,i),s)).updateMetaData("window onerror",{error:a});else if("object"!=typeof n||null===n||r||o||i||a)(u=new e.BugsnagReport("window.onerror",String(n),jt(e.BugsnagReport.getStacktrace(a,1),r,o,i),s)).updateMetaData("window onerror",{event:n});else{var c=n.type?"Event: "+n.type:"window.onerror",l=n.message||n.detail||"";(u=new e.BugsnagReport(c,l,e.BugsnagReport.getStacktrace(new Error,1).slice(1),s)).updateMetaData("window onerror",{event:n})}e.notify(u),"function"==typeof t&&t(n,r,o,i,a)}}}},jt=function(e,t,n,r){var o=e[0];return o?(o.fileName||o.setFileName(t),o.lineNumber||o.setLineNumber(n),o.columnNumber||(void 0!==r?o.setColumnNumber(r):window.event&&window.event.errorCharacter&&o.setColumnNumber(window.event&&window.event.errorCharacter)),e):e},Et=function(e,t,n){return JSON.stringify(c(e),t,n)},kt=20,Tt=25e3,Ct=8,Nt="...",Lt=function(e){var t=Et(e);if(t.length>1e6&&(delete e.events[0].metaData,e.events[0].metaData={notifier:"WARNING!\nSerialized payload was "+t.length/1e6+"MB (limit = 1MB)\nmetaData was removed"},(t=Et(e)).length>1e6))throw new Error("payload exceeded 1MB limit");return t},qt={},Mt=w;qt={sendReport:function(e,t,n){var r=arguments.length>3&&void 0!==arguments[3]?arguments[3]:function(){},o=Pt(t,"notify","4.0"),i=new window.XDomainRequest;i.onload=function(){r(null,i.responseText)},i.open("POST",o),setTimeout((function(){try{i.send(Lt(n))}catch(t){e.error(t)}}),0)},sendSession:function(e,t,n){var r=arguments.length>3&&void 0!==arguments[3]?arguments[3]:function(){},o=Pt(t,"sessions","1.0"),i=new window.XDomainRequest;i.onload=function(){r(null,i.responseText)},i.open("POST",o),setTimeout((function(){try{i.send(Et(n))}catch(t){e.error(t)}}),0)}};var xt,Pt=function(e,t,n){return At(e.endpoints[t],window.location.protocol)+"?apiKey="+encodeURIComponent(e.apiKey)+"&payloadVersion="+n+"&sentAt="+encodeURIComponent(Mt())},At=qt._matchPageProtocol=function(e,t){return"http:"===t?e.replace(/^https:/,"http:"):e},Dt=w,Rt={sendReport:function(e,t,n){var r=arguments.length>3&&void 0!==arguments[3]?arguments[3]:function(){};try{var o=t.endpoints.notify,i=new window.XMLHttpRequest;i.onreadystatechange=function(){i.readyState===window.XMLHttpRequest.DONE&&r(null,i.responseText)},i.open("POST",o),i.setRequestHeader("Content-Type","application/json"),i.setRequestHeader("Bugsnag-Api-Key",n.apiKey||t.apiKey),i.setRequestHeader("Bugsnag-Payload-Version","4.0"),i.setRequestHeader("Bugsnag-Sent-At",Dt()),i.send(Lt(n))}catch(t){e.error(t)}},sendSession:function(e,t,n){var r=arguments.length>3&&void 0!==arguments[3]?arguments[3]:function(){};try{var o=t.endpoints.sessions,i=new window.XMLHttpRequest;i.onreadystatechange=function(){i.readyState===window.XMLHttpRequest.DONE&&r(null,i.responseText)},i.open("POST",o),i.setRequestHeader("Content-Type","application/json"),i.setRequestHeader("Bugsnag-Api-Key",t.apiKey),i.setRequestHeader("Bugsnag-Payload-Version","1.0"),i.setRequestHeader("Bugsnag-Sent-At",Dt()),i.send(Et(n))}catch(t){e.error(t)}}},It=Object.assign||function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(e[r]=n[r])}return e},Bt=p,Ut=g,Ht=It({},E.schema,ke),$t=[_t,bt,De,xe,ut,Oe,Ce,Je,We,$e,Re,ht,ze,gt];xt=function(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:[];"string"==typeof e&&(e={apiKey:e});var n=[];e.sessionTrackingEnabled&&(n.push("deprecated option sessionTrackingEnabled is now called autoCaptureSessions"),e.autoCaptureSessions=e.sessionTrackingEnabled),!e.endpoint&&!e.sessionEndpoint||e.endpoints||(n.push("deprecated options endpoint/sessionEndpoint are now configured in the endpoints object"),e.endpoints={notify:e.endpoint,sessions:e.sessionEndpoint}),e.endpoints&&e.endpoints.notify&&!e.endpoints.sessions&&n.push("notify endpoint is set but sessions endpoint is not. No sessions will be sent.");var r=Ut([].concat($t).concat(t),(function(e,t){return t.configSchema?It({},e,t.configSchema):e}),Ht),o=new we({name:"Bugsnag JavaScript",version:"4.7.3",url:"https://github.com/bugsnag/bugsnag-js"},r);return o.transport(window.XDomainRequest?qt:Rt),o.configure(e),Bt(n,(function(e){return o._logger.warn(e)})),o.use(De),o.use(xe),o.use(ut),o.use(Re),o.use(Oe),o.use(ht),o.use(ze),o.use(gt),!1!==o.config.autoNotify&&(o.use(_t),o.use(bt)),Vt(o.config,"navigationBreadcrumbsEnabled")&&o.use(We),Vt(o.config,"interactionBreadcrumbsEnabled")&&o.use($e),Vt(o.config,"networkBreadcrumbsEnabled")&&o.use(Je),Vt(o.config,"consoleBreadcrumbsEnabled",!1)&&o.use(Ce),Bt(t,(function(e){return o.use(e)})),o.config.autoCaptureSessions?o.startSession():o};var Vt=function(e,t){var n=!(arguments.length>2&&void 0!==arguments[2])||arguments[2];return"boolean"==typeof e[t]?e[t]:e.autoBreadcrumbs&&(n||!/^dev(elopment)?$/.test(e.releaseStage))};return xt.Bugsnag={Client:we,Report:W,Session:ae,Breadcrumb:O},xt.default=xt,xt}()},function(e,t){e.exports="4.4.1"},function(e,t,n){"use strict";var r={randomUUID:"undefined"!=typeof crypto&&crypto.randomUUID&&crypto.randomUUID.bind(crypto)};let o;const i=new Uint8Array(16);function a(){if(!o&&(o="undefined"!=typeof crypto&&crypto.getRandomValues&&crypto.getRandomValues.bind(crypto),!o))throw new Error("crypto.getRandomValues() not supported. See https://github.com/uuidjs/uuid#getrandomvalues-not-supported");return o(i)}const s=[];for(let e=0;e<256;++e)s.push((e+256).toString(16).slice(1));function u(e,t=0){return(s[e[t+0]]+s[e[t+1]]+s[e[t+2]]+s[e[t+3]]+"-"+s[e[t+4]]+s[e[t+5]]+"-"+s[e[t+6]]+s[e[t+7]]+"-"+s[e[t+8]]+s[e[t+9]]+"-"+s[e[t+10]]+s[e[t+11]]+s[e[t+12]]+s[e[t+13]]+s[e[t+14]]+s[e[t+15]]).toLowerCase()}t.a=function(e,t,n){if(r.randomUUID&&!t&&!e)return r.randomUUID();const o=(e=e||{}).random||(e.rng||a)();if(o[6]=15&o[6]|64,o[8]=63&o[8]|128,t){n=n||0;for(let e=0;e<16;++e)t[n+e]=o[e];return t}return u(o)}},function(e,t){
/*! (c) Andrea Giammarchi @webreflection ISC */
!function(){"use strict";var e=function(e,t){var n=function(e){for(var t=0,n=e.length;t<n;t++)r(e[t])},r=function(e){var t=e.target,n=e.attributeName,r=e.oldValue;t.attributeChangedCallback(n,r,t.getAttribute(n))};return function(o,i){var a=o.constructor.observedAttributes;return a&&e(i).then((function(){new t(n).observe(o,{attributes:!0,attributeOldValue:!0,attributeFilter:a});for(var e=0,i=a.length;e<i;e++)o.hasAttribute(a[e])&&r({target:o,attributeName:a[e],oldValue:null})})),o}};function t(e,t){(null==t||t>e.length)&&(t=e.length);for(var n=0,r=new Array(t);n<t;n++)r[n]=e[n];return r}function n(e,n){var r="undefined"!=typeof Symbol&&e[Symbol.iterator]||e["@@iterator"];if(!r){if(Array.isArray(e)||(r=function(e,n){if(e){if("string"==typeof e)return t(e,n);var r=Object.prototype.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)?t(e,n):void 0}}(e))||n&&e&&"number"==typeof e.length){r&&(e=r);var o=0,i=function(){};return{s:i,n:function(){return o>=e.length?{done:!0}:{done:!1,value:e[o++]}},e:function(e){throw e},f:i}}throw new TypeError("Invalid attempt to iterate non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}var a,s=!0,u=!1;return{s:function(){r=r.call(e)},n:function(){var e=r.next();return s=e.done,e},e:function(e){u=!0,a=e},f:function(){try{s||null==r.return||r.return()}finally{if(u)throw a}}}}
/*! (c) Andrea Giammarchi - ISC */var r="querySelectorAll",o="querySelectorAll",i=self,a=i.document,s=i.Element,u=i.MutationObserver,c=i.Set,l=i.WeakMap,d=function(e){return o in e},f=[].filter,h=function(e){var t=new l,i=function(n,r){var o;if(r)for(var i,a=function(e){return e.matches||e.webkitMatchesSelector||e.msMatchesSelector}(n),s=0,u=p.length;s<u;s++)a.call(n,i=p[s])&&(t.has(n)||t.set(n,new c),(o=t.get(n)).has(i)||(o.add(i),e.handle(n,r,i)));else t.has(n)&&(o=t.get(n),t.delete(n),o.forEach((function(t){e.handle(n,r,t)})))},h=function(e){for(var t=!(arguments.length>1&&void 0!==arguments[1])||arguments[1],n=0,r=e.length;n<r;n++)i(e[n],t)},p=e.query,g=e.root||a,m=function(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:document,o=arguments.length>2&&void 0!==arguments[2]?arguments[2]:MutationObserver,i=arguments.length>3&&void 0!==arguments[3]?arguments[3]:["*"],a=function t(o,i,a,s,u,c){var l,d=n(o);try{for(d.s();!(l=d.n()).done;){var f=l.value;(c||r in f)&&(u?a.has(f)||(a.add(f),s.delete(f),e(f,u)):s.has(f)||(s.add(f),a.delete(f),e(f,u)),c||t(f[r](i),i,a,s,u,!0))}}catch(e){d.e(e)}finally{d.f()}},s=new o((function(e){if(i.length){var t,r=i.join(","),o=new Set,s=new Set,u=n(e);try{for(u.s();!(t=u.n()).done;){var c=t.value,l=c.addedNodes,d=c.removedNodes;a(d,r,o,s,!1,!1),a(l,r,o,s,!0,!1)}}catch(e){u.e(e)}finally{u.f()}}})),u=s.observe;return(s.observe=function(e){return u.call(s,e,{subtree:!0,childList:!0})})(t),s}(i,g,u,p),v=s.prototype.attachShadow;return v&&(s.prototype.attachShadow=function(e){var t=v.call(this,e);return m.observe(t),t}),p.length&&h(g[o](p)),{drop:function(e){for(var n=0,r=e.length;n<r;n++)t.delete(e[n])},flush:function(){for(var e=m.takeRecords(),t=0,n=e.length;t<n;t++)h(f.call(e[t].removedNodes,d),!1),h(f.call(e[t].addedNodes,d),!0)},observer:m,parse:h}},p=self,g=p.document,m=p.Map,v=p.MutationObserver,y=p.Object,b=p.Set,w=p.WeakMap,S=p.Element,O=p.HTMLElement,_=p.Node,j=p.Error,E=p.TypeError,k=p.Reflect,T=y.defineProperty,C=y.keys,N=y.getOwnPropertyNames,L=y.setPrototypeOf,q=!self.customElements,M=function(e){for(var t=C(e),n=[],r=t.length,o=0;o<r;o++)n[o]=e[t[o]],delete e[t[o]];return function(){for(var o=0;o<r;o++)e[t[o]]=n[o]}};if(q){var x=function(){var e=this.constructor;if(!A.has(e))throw new E("Illegal constructor");var t=A.get(e);if(H)return V(H,t);var n=P.call(g,t);return V(L(n,e.prototype),t)},P=g.createElement,A=new m,D=new m,R=new m,I=new m,B=[],U=h({query:B,handle:function(e,t,n){var r=R.get(n);if(t&&!r.isPrototypeOf(e)){var o=M(e);H=L(e,r);try{new r.constructor}finally{H=null,o()}}var i="".concat(t?"":"dis","connectedCallback");i in r&&e[i]()}}).parse,H=null,$=function(e){if(!D.has(e)){var t,n=new Promise((function(e){t=e}));D.set(e,{$:n,_:t})}return D.get(e).$},V=e($,v);T(self,"customElements",{configurable:!0,value:{define:function(e,t){if(I.has(e))throw new j('the name "'.concat(e,'" has already been used with this registry'));A.set(t,e),R.set(e,t.prototype),I.set(e,t),B.push(e),$(e).then((function(){U(g.querySelectorAll(e))})),D.get(e)._(t)},get:function(e){return I.get(e)},whenDefined:$}}),T(x.prototype=O.prototype,"constructor",{value:x}),T(self,"HTMLElement",{configurable:!0,value:x}),T(g,"createElement",{configurable:!0,value:function(e,t){var n=t&&t.is,r=n?I.get(n):I.get(e);return r?new r:P.call(g,e)}}),"isConnected"in _.prototype||T(_.prototype,"isConnected",{configurable:!0,get:function(){return!(this.ownerDocument.compareDocumentPosition(this)&this.DOCUMENT_POSITION_DISCONNECTED)}})}else if(q=!self.customElements.get("extends-li"))try{var F=function e(){return self.Reflect.construct(HTMLLIElement,[],e)};F.prototype=HTMLLIElement.prototype;var z="extends-li";self.customElements.define("extends-li",F,{extends:"li"}),q=g.createElement("li",{is:z}).outerHTML.indexOf(z)<0;var W=self.customElements,K=W.get,X=W.whenDefined;T(self.customElements,"whenDefined",{configurable:!0,value:function(e){var t=this;return X.call(this,e).then((function(n){return n||K.call(t,e)}))}})}catch(e){}if(q){var G=function(e){var t=ne.get(e);de(t.querySelectorAll(this),e.isConnected)},J=self.customElements,Q=g.createElement,Y=J.define,Z=J.get,ee=J.upgrade,te=(k||{construct:function(e){return e.call(this)}}).construct,ne=new w,re=new b,oe=new m,ie=new m,ae=new m,se=new m,ue=[],ce=[],le=function(e){return se.get(e)||Z.call(J,e)},de=h({query:ce,handle:function(e,t,n){var r=ae.get(n);if(t&&!r.isPrototypeOf(e)){var o=M(e);me=L(e,r);try{new r.constructor}finally{me=null,o()}}var i="".concat(t?"":"dis","connectedCallback");i in r&&e[i]()}}).parse,fe=h({query:ue,handle:function(e,t){ne.has(e)&&(t?re.add(e):re.delete(e),ce.length&&G.call(ce,e))}}).parse,he=S.prototype.attachShadow;he&&(S.prototype.attachShadow=function(e){var t=he.call(this,e);return ne.set(this,t),t});var pe=function(e){if(!ie.has(e)){var t,n=new Promise((function(e){t=e}));ie.set(e,{$:n,_:t})}return ie.get(e).$},ge=e(pe,v),me=null;N(self).filter((function(e){return/^HTML.*Element$/.test(e)})).forEach((function(e){var t=self[e];function n(){var e=this.constructor;if(!oe.has(e))throw new E("Illegal constructor");var n=oe.get(e),r=n.is,o=n.tag;if(r){if(me)return ge(me,r);var i=Q.call(g,o);return i.setAttribute("is",r),ge(L(i,e.prototype),r)}return te.call(this,t,[],e)}T(n.prototype=t.prototype,"constructor",{value:n}),T(self,e,{value:n})})),T(g,"createElement",{configurable:!0,value:function(e,t){var n=t&&t.is;if(n){var r=se.get(n);if(r&&oe.get(r).tag===e)return new r}var o=Q.call(g,e);return n&&o.setAttribute("is",n),o}}),T(J,"get",{configurable:!0,value:le}),T(J,"whenDefined",{configurable:!0,value:pe}),T(J,"upgrade",{configurable:!0,value:function(e){var t=e.getAttribute("is");if(t){var n=se.get(t);if(n)return void ge(L(e,n.prototype),t)}ee.call(J,e)}}),T(J,"define",{configurable:!0,value:function(e,t,n){if(le(e))throw new j("'".concat(e,"' has already been defined as a custom element"));var r,o=n&&n.extends;oe.set(t,o?{is:e,tag:o}:{is:"",tag:e}),o?(r="".concat(o,'[is="').concat(e,'"]'),ae.set(r,t.prototype),se.set(e,t),ce.push(r)):(Y.apply(J,arguments),ue.push(r=e)),pe(e).then((function(){o?(de(g.querySelectorAll(r)),re.forEach(G,[r])):fe(g.querySelectorAll(r))})),ie.get(e)._(t)}})}}()},function(e,t,n){"use strict";n.r(t),n.d(t,"default",(function(){return j}));var r=n(2);var o=()=>{var e;const t=new r.a("should-bail-early");return window.location.search.includes("mutiny=false")?(t.info("Query param is mutiny=false"),!0):!(!window.location.search.includes("page_id=")||!window.location.search.includes("preview=true"))||!!(null===(e=window.mutiny)||void 0===e?void 0:e.attached)&&(t.info("Mutiny is already attached"),!0)},i=n(12),a=n(0),s=n(7),u=n(4);var c=n(19),l=function(e,t,n,r){return new(n||(n=Promise))((function(o,i){function a(e){try{u(r.next(e))}catch(e){i(e)}}function s(e){try{u(r.throw(e))}catch(e){i(e)}}function u(e){var t;e.done?o(e.value):(t=e.value,t instanceof n?t:new n((function(e){e(t)}))).then(a,s)}u((r=r.apply(e,t||[])).next())}))};class d{constructor(e,t,n,o,i,a){this.apiToken=e,this.companyToken=t,this.userToken=n,this.sessionToken=o,this.preview=i,this.campaignAccountToken=a,this.logger=new r.a("user-data-client"),this.responseCache=new Map}fetch(e){return l(this,void 0,void 0,(function*(){if(this.logger.info("Fetching user data","async="+e),this.responseCache.has(e))return this.responseCache.get(e);const t=this.fetchHelper(e);return this.responseCache.set(e,t),t}))}fetchHelper(e){return l(this,void 0,void 0,(function*(){try{const t=yield fetch(this.getUrl(e),{referrer:""});if(t.ok){this.logger.info("User data loaded successfully","async="+e);const n=yield t.json();return{headers:t.headers,status:t.status,ok:!0,json:n}}this.logger.info("User data failed","async="+e);return{headers:t.headers,status:t.status,ok:!1,json:{}}}catch(t){throw this.logger.info("Fetch failure","async="+e,t),t}}))}getUrl(e){const t=[window.MUTINY_USER_DATA_URL||"https://user-data.mutinycdn.com","personalize/user_data",this.companyToken+".json"].join("/"),n=new URLSearchParams;return n.set("async",e.toString()),n.set("session_token",this.sessionToken),n.set("token",this.apiToken),n.set("visitor_token",this.userToken),this.campaignAccountToken&&n.set("m_token",this.campaignAccountToken),this.preview!==a.v.Editor&&this.preview!==a.v.Preview||n.set("preview","true"),`${t}?${n.toString()}`}}var f=n(14),h=n(3),p=n(8),g=n(15);var m=class{constructor(e,t=document.documentElement,n="html:not([data-mutiny-loaded])",o="data-mutiny-loaded"){this.selectors=e,this.documentElement=t,this.hiderSelector=n,this.mutinyLoadedAttribute=o,this.logger=new r.a("hide-elements"),this.cssStyle=(()=>{const e=document.querySelector("#mutiny-styles")||Object(s.a)("style");return e.id="mutiny-styles",e.nonce=Object(i.a)(),e})(),this.mutationObserver=new MutationObserver(e=>{e.some(({removedNodes:e})=>Array.from(e).includes(this.cssStyle))&&document.head.append(this.cssStyle)})}attachHider(){const e=Array.from(new Set(this.selectors)).map(e=>`${this.hiderSelector} ${e}`);e.length>0&&(this.cssStyle.append(document.createTextNode(e.join(", ")+" { opacity: 0 !important; }")),document.head.append(this.cssStyle),Object(g.a)(),this.timer=window.setInterval(()=>this.removeHider(!1,"hider timed out"),3e3),this.mutationObserver.observe(document.head,{subtree:!0,childList:!0}))}removeHider(e,t){this.mutationObserver.disconnect(),this.isAttached&&(this.logger.info((null==t?void 0:t.length)?"Removing hider because "+t:"Removing hider"),window.clearInterval(this.timer),window.requestAnimationFrame(()=>{this.documentElement.setAttribute(this.mutinyLoadedAttribute,e.toString())}),Object(g.b)())}get isAttached(){return!this.documentElement.getAttribute(this.mutinyLoadedAttribute)}},v=function(e,t,n,r){return new(n||(n=Promise))((function(o,i){function a(e){try{u(r.next(e))}catch(e){i(e)}}function s(e){try{u(r.throw(e))}catch(e){i(e)}}function u(e){var t;e.done?o(e.value):(t=e.value,t instanceof n?t:new n((function(e){e(t)}))).then(a,s)}u((r=r.apply(e,t||[])).next())}))};const y=new r.a("hide-elements");function b(e){return v(this,void 0,void 0,(function*(){if(window.__mutiny_client_data)return y.info("Found pre generated client data! Skipping client data request..."),window.__mutiny_client_data;let t=`https://client-registry.mutinycdn.com/personalize/client_data/${e.company_token}.json`;e.preview==a.v.Preview&&(t=`https://assets.mutinyhq.com/personalize/client_data/${e.company_token}.json?preview=true`);return(yield fetch(t)).json()}))}var w=Object(p.d)((function({selectors:e,config:t}){return v(this,void 0,void 0,(function*(){Object(c.a)(),y.info("Hiding only selectors on page...");const r=Object(u.c)(e,t.preview).flatMap(e=>e.selectors),o=new m(r);o.attachHider(),y.info("Finished hiding selectors on this page...");const i=new URLSearchParams(window.location.search),a=t.campaign_query_param_keys.map(e=>{var t;return null!==(t=i.get(e))&&void 0!==t?t:void 0}).find(e=>!!e),s=new d(t.api_key,t.company_token,f.c.instance.getVisitorToken(),f.c.instance.getSessionToken(),t.preview,a);Object(h.d)()||s.fetch(!1).then(e=>y.debug("Sync UserData response",e)),y.info("Downloading initializeMutiny function...");const[l,p]=yield Promise.all([b(t),Promise.all([n.e(7),n.e(6)]).then(n.bind(null,115)).then(e=>e.initializeMutiny)]);y.info("Finished downloading initializeMutiny function..."),yield p({config:t,dom_events:l.dom_events,audience_segments:l.audience_segments,stylesheets:l.component_stylesheets,questionnaires:[],url_data_sources:[],referral_config:null},o,s)}))}));var S=function(e,t,n,r){return new(n||(n=Promise))((function(o,i){function a(e){try{u(r.next(e))}catch(e){i(e)}}function s(e){try{u(r.throw(e))}catch(e){i(e)}}function u(e){var t;e.done?o(e.value):(t=e.value,t instanceof n?t:new n((function(e){e(t)}))).then(a,s)}u((r=r.apply(e,t||[])).next())}))};n.nc=Object(i.a)();const O=new r.a("index-slim");function _({disableDebugModes:e}){return e?a.r.Live:window.location.search.includes("mutiny_version_override=")?a.r.LiveOverrideMode:function(){const e="true"===window.localStorage.getItem("mutiny.client.local_debug"),t=new URLSearchParams(window.location.search).has("local_debug");return e||t}()?a.r.LocalDebug:a.r.Live}function j(e){return S(this,void 0,void 0,(function*(){if(o())return void O.info("Exiting early");const t=_(e);switch(t){case a.r.LiveOverrideMode:return function(e){const t=new r.a("override-version");try{const n=Object(u.h)(window.location.search).mutiny_version_override;if(n){t.info("Found version override, loading client v"+n);const r=`https://client.mutinycdn.com/mutiny-client/${n}.js`,o=Object(s.a)("script");return o.id="mutiny_version_override",window.__initializeMutiny=void 0,window.__initializeMutinySlim=void 0,Object.defineProperty(window,"__initializeMutiny",{set(t){t(Object.assign(Object.assign({},e),{disableDebugModes:!0}))}}),o.src=r,void document.head.append(o)}t.error("Couldn't parse mutiny_version_override from url")}catch(e){console.error(e)}}(e);case a.r.LocalDebug:return;case a.r.Live:return w(e);default:O.error("Unsupported mode "+t)}}))}window.__initializeMutiny=j,window.__initializeMutinySlim=j}]);
__initializeMutinySlim({"config":{"blacklisted_query_params":{"tve":[]},"track_calendly":false,"track_drift":false,"track_hubspot":false,"tracking_mode":"batch","write_to_segment":true,"api_key":"ee5c5599f1e56fc3","blocked_ips":[],"campaign_query_param_keys":["mt"],"client_iteration":1,"company_slug":"coursera","company_token":"b038efcc6b3aa65f","exposed_user_data_attributes":[],"integrations":["mutiny","window"],"preview":null,"published_at":"2023-07-19T11:41:06.955-07:00","tracked_domains":null,"whitelisted_domains":[]},"selectors":[]})