@flarehr/apollo-super-selection 3.37.55638 → 3.40.56412

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (22) hide show
  1. package/dist/lib/apollo-super-selection/apollo-super-selection.esm.js +1 -1
  2. package/dist/lib/apollo-super-selection/{p-63a41400.entry.js → p-6e6d6abf.entry.js} +4 -4
  3. package/dist/lib/apollo-super-selection/{p-26a1d90e.system.entry.js → p-7f4be2c5.system.entry.js} +1 -1
  4. package/dist/lib/apollo-super-selection/p-d82b00ed.system.js +1 -1
  5. package/dist/lib/cjs/apollo-super-selection.cjs.js +1 -1
  6. package/dist/lib/cjs/fl-button_46.cjs.entry.js +13 -12
  7. package/dist/lib/cjs/loader.cjs.js +1 -1
  8. package/dist/lib/collection/components/super-selection-app/funds/constants.js +1 -0
  9. package/dist/lib/collection/components/super-selection-app/funds/promoted-fund/services/promoted-fund-join-iframe-builder.js +5 -7
  10. package/dist/lib/collection/components/super-selection-app/super-choice-page/super-choice-item.js +18 -1
  11. package/dist/lib/collection/components/super-selection-app/super-choice-page/super-choice-page.js +6 -4
  12. package/dist/lib/esm/apollo-super-selection.js +1 -1
  13. package/dist/lib/esm/fl-button_46.entry.js +13 -12
  14. package/dist/lib/esm/loader.js +1 -1
  15. package/dist/lib/esm-es5/apollo-super-selection.js +1 -1
  16. package/dist/lib/esm-es5/fl-button_46.entry.js +1 -1
  17. package/dist/lib/esm-es5/loader.js +1 -1
  18. package/dist/lib/types/components/super-selection-app/funds/constants.d.ts +1 -0
  19. package/dist/lib/types/components/super-selection-app/funds/promoted-fund/services/promoted-fund-join-iframe-builder.d.ts +0 -1
  20. package/dist/lib/types/components/super-selection-app/super-choice-page/super-choice-item.d.ts +1 -0
  21. package/dist/lib/types/components.d.ts +2 -0
  22. package/package.json +1 -1
@@ -1,14 +1,14 @@
1
- import{r as t,h as e,c as n,g as i,f as r,H as o,a as s,d as a,e as c,s as u}from"./p-082669d9.js";import{f as l,m as f,S as d,a as h,i as p,d as m,b as v,c as b,g,Q as w}from"./p-df9ce4b7.js";import{g as y,O as x,j as k,k as S,a as C}from"./p-342cee5a.js";import{A as _}from"./p-61734b66.js";function A(){}function q(t,e,n=Number.POSITIVE_INFINITY){return"function"==typeof e?i=>i.pipe(q(((n,i)=>l(t(n,i)).pipe(f(((t,r)=>e(n,t,i,r))))),n)):("number"==typeof e&&(n=e),e=>e.lift(new B(t,n)))}class B{constructor(t,e=Number.POSITIVE_INFINITY){this.project=t,this.concurrent=e}call(t,e){return e.subscribe(new j(t,this.project,this.concurrent))}}class j extends d{constructor(t,e,n=Number.POSITIVE_INFINITY){super(t),this.project=e,this.concurrent=n,this.hasCompleted=!1,this.buffer=[],this.active=0,this.index=0}_next(t){this.active<this.concurrent?this._tryNext(t):this.buffer.push(t)}_tryNext(t){let e;const n=this.index++;try{e=this.project(t,n)}catch(t){return void this.destination.error(t)}this.active++,this._innerSub(e)}_innerSub(t){const e=new h(this),n=this.destination;n.add(e);const i=p(t,e);i!==e&&n.add(i)}_complete(){this.hasCompleted=!0,0===this.active&&0===this.buffer.length&&this.destination.complete(),this.unsubscribe()}notifyNext(t){this.destination.next(t)}notifyComplete(){const t=this.buffer;this.active--,t.length>0?this._next(t.shift()):0===this.active&&this.hasCompleted&&this.destination.complete()}}function E(t,e,n,i){return k(n)&&(i=n,n=void 0),i?E(t,e,n).pipe(f((t=>y(t)?i(...t):i(t)))):new x((i=>{I(t,e,(function(t){i.next(arguments.length>1?Array.prototype.slice.call(arguments):t)}),i,n)}))}function I(t,e,n,i,r){let o;if(function(t){return t&&"function"==typeof t.addEventListener&&"function"==typeof t.removeEventListener}(t)){const i=t;t.addEventListener(e,n,r),o=()=>i.removeEventListener(e,n,r)}else if(function(t){return t&&"function"==typeof t.on&&"function"==typeof t.off}(t)){const i=t;t.on(e,n),o=()=>i.off(e,n)}else if(function(t){return t&&"function"==typeof t.addListener&&"function"==typeof t.removeListener}(t)){const i=t;t.addListener(e,n),o=()=>i.removeListener(e,n)}else{if(!t||!t.length)throw new TypeError("Invalid event target");for(let o=0,s=t.length;o<s;o++)I(t[o],e,n,i,r)}i.add(o)}class F{constructor(t,e){this.dueTime=t,this.scheduler=e}call(t,e){return e.subscribe(new P(t,this.dueTime,this.scheduler))}}class P extends C{constructor(t,e,n){super(t),this.dueTime=e,this.scheduler=n,this.debouncedSubscription=null,this.lastValue=null,this.hasValue=!1}_next(t){this.clearDebounce(),this.lastValue=t,this.hasValue=!0,this.add(this.debouncedSubscription=this.scheduler.schedule(R,this.dueTime,this))}_complete(){this.debouncedNext(),this.destination.complete()}debouncedNext(){if(this.clearDebounce(),this.hasValue){const{lastValue:t}=this;this.lastValue=null,this.hasValue=!1,this.destination.next(t)}}clearDebounce(){const t=this.debouncedSubscription;null!==t&&(this.remove(t),t.unsubscribe(),this.debouncedSubscription=null)}}function R(t){t.debouncedNext()}function M(t,e,n){return function(i){return i.lift(new T(t,e,n))}}class T{constructor(t,e,n){this.nextOrObserver=t,this.error=e,this.complete=n}call(t,e){return e.subscribe(new N(t,this.nextOrObserver,this.error,this.complete))}}class N extends C{constructor(t,e,n,i){super(t),this._tapNext=A,this._tapError=A,this._tapComplete=A,this._tapError=n||A,this._tapComplete=i||A,k(e)?(this._context=this,this._tapNext=e):e&&(this._context=e,this._tapNext=e.next||A,this._tapError=e.error||A,this._tapComplete=e.complete||A)}_next(t){try{this._tapNext.call(this._context,t)}catch(t){return void this.destination.error(t)}this.destination.next(t)}_error(t){try{this._tapError.call(this._context,t)}catch(t){return void this.destination.error(t)}this.destination.error(t)}_complete(){try{this._tapComplete.call(this._context)}catch(t){return void this.destination.error(t)}return this.destination.complete()}}var D=function(t){return"Some"===t._tag},O=function(t){return"None"===t._tag},U={_tag:"None"},L=function(t){return{_tag:"Some",value:t}};function z(t){return null==t?U:L(t)}class H{constructor(t){this.factory=t,this._value=U}get value(){if(D(this._value))return this._value.value;const t=this.factory();return this._value=L(t),t}}function V(t){_.injectProps(t,["history","location"])}const Q=new RegExp(["(\\\\.)","(?:\\:(\\w+)(?:\\(((?:\\\\.|[^\\\\()])+)\\))?|\\(((?:\\\\.|[^\\\\()])+)\\))([+*?])?"].join("|"),"g"),W=t=>t.replace(/([.+*?=^!:${}()[\]|/\\])/g,"\\$1"),$=t=>t.replace(/([=!:$/()])/g,"\\$1"),Y=t=>t&&t.sensitive?"":"i",X=(t,e,n)=>{for(var i=(n=n||{}).strict,r=!1!==n.end,o=W(n.delimiter||"/"),s=n.delimiters||"./",a=[].concat(n.endsWith||[]).map(W).concat("$").join("|"),c="",u=!1,l=0;l<t.length;l++){var f=t[l];if("string"==typeof f)c+=W(f),u=l===t.length-1&&s.indexOf(f[f.length-1])>-1;else{var d=W(f.prefix||""),h=f.repeat?"(?:"+f.pattern+")(?:"+d+"(?:"+f.pattern+"))*":f.pattern;e&&e.push(f),c+=f.optional?f.partial?d+"("+h+")?":"(?:"+d+"("+h+"))?":d+"("+h+")"}}return r?(i||(c+="(?:"+o+")?"),c+="$"===a?"$":"(?="+a+")"):(i||(c+="(?:"+o+"(?="+a+"))?"),u||(c+="(?="+o+"|"+a+")")),new RegExp("^"+c,Y(n))},J=(t,e,n)=>t instanceof RegExp?((t,e)=>{if(!e)return t;var n=t.source.match(/\((?!\?)/g);if(n)for(var i=0;i<n.length;i++)e.push({name:i,prefix:null,delimiter:null,optional:!1,repeat:!1,partial:!1,pattern:null});return t})(t,e):Array.isArray(t)?((t,e,n)=>{for(var i=[],r=0;r<t.length;r++)i.push(J(t[r],e,n).source);return new RegExp("(?:"+i.join("|")+")",Y(n))})(t,e,n):((t,e,n)=>X(((t,e)=>{for(var n,i=[],r=0,o=0,s="",a=e&&e.delimiter||"/",c=e&&e.delimiters||"./",u=!1;null!==(n=Q.exec(t));){var l=n[0],f=n[1],d=n.index;if(s+=t.slice(o,d),o=d+l.length,f)s+=f[1],u=!0;else{var h="",p=t[o],m=n[2],v=n[3],b=n[4],g=n[5];if(!u&&s.length){var w=s.length-1;c.indexOf(s[w])>-1&&(h=s[w],s=s.slice(0,w))}s&&(i.push(s),s="",u=!1);var y=h||a,x=v||b;i.push({name:m||r++,prefix:h,delimiter:y,optional:"?"===g||"*"===g,repeat:"+"===g||"*"===g,partial:""!==h&&void 0!==p&&p!==h,pattern:x?$(x):"[^"+W(y)+"]+?"})}}return(s||o<t.length)&&i.push(s+t.substr(o)),i})(t,n),e,n))(t,e,n),G=(t,e)=>new RegExp("^"+e+"(\\/|\\?|#|$)","i").test(t),K=(t,e)=>G(t,e)?t.substr(e.length):t,Z=t=>"/"===t.charAt(t.length-1)?t.slice(0,-1):t,tt=t=>"/"===t.charAt(0)?t:"/"+t,et=t=>"/"===t.charAt(0)?t.substr(1):t,nt=t=>{const{pathname:e,search:n,hash:i}=t;let r=e||"/";return n&&"?"!==n&&(r+="?"===n.charAt(0)?n:"?"+n),i&&"#"!==i&&(r+="#"===i.charAt(0)?i:"#"+i),r},it=t=>"/"===t.charAt(0),rt=t=>Math.random().toString(36).substr(2,t),ot=(t,e)=>{for(let n=e,i=n+1,r=t.length;i<r;n+=1,i+=1)t[n]=t[i];t.pop()},st=(t,e)=>{if(t===e)return!0;if(null==t||null==e)return!1;if(Array.isArray(t))return Array.isArray(e)&&t.length===e.length&&t.every(((t,n)=>st(t,e[n])));const n=typeof t;if(n!==typeof e)return!1;if("object"===n){const n=t.valueOf(),i=e.valueOf();if(n!==t||i!==e)return st(n,i);const r=Object.keys(t),o=Object.keys(e);return r.length===o.length&&r.every((n=>st(t[n],e[n])))}return!1},at=(t,e,n,i)=>{let r;"string"==typeof t?(r=(t=>{let e=t||"/",n="",i="";const r=e.indexOf("#");-1!==r&&(i=e.substr(r),e=e.substr(0,r));const o=e.indexOf("?");return-1!==o&&(n=e.substr(o),e=e.substr(0,o)),{pathname:e,search:"?"===n?"":n,hash:"#"===i?"":i,query:{},key:""}})(t),void 0!==e&&(r.state=e)):(r=Object.assign({pathname:""},t),r.search&&"?"!==r.search.charAt(0)&&(r.search="?"+r.search),r.hash&&"#"!==r.hash.charAt(0)&&(r.hash="#"+r.hash),void 0!==e&&void 0===r.state&&(r.state=e));try{r.pathname=decodeURI(r.pathname)}catch(t){throw t instanceof URIError?new URIError('Pathname "'+r.pathname+'" could not be decoded. This is likely caused by an invalid percent-encoding.'):t}var o;return r.key=n,i?r.pathname?"/"!==r.pathname.charAt(0)&&(r.pathname=((t,e="")=>{let n,i=e&&e.split("/")||[],r=0;const o=t&&t.split("/")||[],s=t&&it(t),a=e&&it(e),c=s||a;if(t&&it(t)?i=o:o.length&&(i.pop(),i=i.concat(o)),!i.length)return"/";if(i.length){const t=i[i.length-1];n="."===t||".."===t||""===t}else n=!1;for(let t=i.length;t>=0;t--){const e=i[t];"."===e?ot(i,t):".."===e?(ot(i,t),r++):r&&(ot(i,t),r--)}if(!c)for(;r--;r)i.unshift("..");!c||""===i[0]||i[0]&&it(i[0])||i.unshift("");let u=i.join("/");return n&&"/"!==u.substr(-1)&&(u+="/"),u})(r.pathname,i.pathname)):r.pathname=i.pathname:r.pathname||(r.pathname="/"),r.query=(o=r.search||"")?(/^[?#]/.test(o)?o.slice(1):o).split("&").reduce(((t,e)=>{let[n,i]=e.split("=");return t[n]=i?decodeURIComponent(i.replace(/\+/g," ")):"",t}),{}):{},r};let ct=0;const ut={},lt=(t,e={})=>{"string"==typeof e&&(e={path:e});const{path:n="/",exact:i=!1,strict:r=!1}=e,{re:o,keys:s}=((t,e)=>{const n=`${e.end}${e.strict}`,i=ut[n]||(ut[n]={}),r=JSON.stringify(t);if(i[r])return i[r];const o=[],s={re:J(t,o,e),keys:o};return ct<1e4&&(i[r]=s,ct+=1),s})(n,{end:i,strict:r}),a=o.exec(t);if(!a)return null;const[c,...u]=a,l=t===c;return i&&!l?null:{path:n,url:"/"===n&&""===c?"/":c,isExact:l,params:s.reduce(((t,e,n)=>(t[e.name]=u[n],t)),{})}},ft=class{constructor(e){t(this,e),this.isBlockElement=!1,this.disabled=!1,this.variant="primary"}render(){return e("button",{class:{"btn position-relative px-3 py-2":!0,"is-primary":"primary"===this.variant,"is-secondary":"secondary"===this.variant,"btn-block":this.isBlockElement,disabled:this.disabled},style:{"pointer-events":this.disabled?"none":"auto"},disabled:this.disabled},e("span",{class:"label"},e("slot",null)))}};ft.style=":host button,:host button:focus,:host button:active,:host button.focus,:host button.active{-webkit-box-shadow:none;box-shadow:none;border-radius:var(--fl-rounding-button) !important}:host button.disabled,:host button:disabled{opacity:1 !important;cursor:not-allowed !important;color:var(--fl-color-disabled)}:host button .label{font-weight:600 !important}:host button.is-primary{color:var(--fl-color-primary-text);background-color:var(--fl-color-primary);border:none}:host button.is-primary.disabled,:host button.is-primary:disabled{background-color:var(--fl-color-primary-disabled)}:host button.is-primary:hover:not(.disabled),:host button.is-primary:hover:not(:disabled){background-color:var(--fl-color-primary-hover)}:host button.is-primary:active:not(.disabled),:host button.is-primary:active:not(:disabled){background-color:var(--fl-color-primary-focus)}:host button.is-secondary{color:var(--fl-color-secondary-text);background-color:var(--fl-color-secondary)}:host button.is-secondary.disabled,:host button.is-secondary:disabled{background-color:var(--fl-color-secondary-disabled)}:host button.is-secondary:hover:not(.disabled),:host button.is-secondary:hover:not(:disabled){background-color:var(--fl-color-secondary-hover)}:host button.is-secondary:active:not(.disabled),:host button.is-secondary:active:not(:disabled){background-color:var(--fl-color-secondary-focus)}:host button.is-block{display:block}:host button:disabled,:host button.disabled{pointer-events:none}";var dt={compareTwoStrings:ht,findBestMatch:function(t,e){if(!function(t,e){return"string"==typeof t&&!!Array.isArray(e)&&!!e.length&&!e.find((t=>"string"!=typeof t))}(t,e))throw new Error("Bad arguments: First argument should be a string, second should be an array of strings");const n=[];let i=0;for(let r=0;r<e.length;r++){const o=e[r],s=ht(t,o);n.push({target:o,rating:s}),s>n[i].rating&&(i=r)}return{ratings:n,bestMatch:n[i],bestMatchIndex:i}}};function ht(t,e){if(t=t.replace(/\s+/g,""),e=e.replace(/\s+/g,""),!t.length&&!e.length)return 1;if(!t.length||!e.length)return 0;if(t===e)return 1;if(1===t.length&&1===e.length)return 0;if(t.length<2||e.length<2)return 0;let n=new Map;for(let e=0;e<t.length-1;e++){const i=t.substring(e,e+2),r=n.has(i)?n.get(i)+1:1;n.set(i,r)}let i=0;for(let t=0;t<e.length-1;t++){const r=e.substring(t,t+2),o=n.has(r)?n.get(r):0;o>0&&(n.set(r,o-1),i++)}return 2*i/(t.length+e.length-2)}const pt=class{constructor(i){t(this,i),this.valueChanged=n(this,"valueChanged",7),this.required=!1,this.disabled=!1,this.isMouseOver=!1,this.inputValue="",this.isDropdownVisible=!1,this.filteredOptions=[],this.renderFilteredResults=()=>0===this.filteredOptions.length?e("span",{class:"dropdown-item disabled"},"No items match your search"):this.filteredOptions.map(((t,n)=>e("span",{class:{"dropdown-item text-wrap":!0,selected:this.isOptionSelected(t),active:this.highlightedOptionIndex===n},onClick:()=>{this.toggleDropdown(!1),this.selectOption(t)}},e("span",null,t.label)))),this.filterResults=t=>{this.filteredOptions=this.sortOptionsByRelevancy(this._options.filter((e=>e.label.toLowerCase().includes(t.toLowerCase()))),t),this.highlightedOptionIndex=void 0},this.selectOption=t=>{this.selectedOption=t,this.inputValue=t.label,this.valueChanged.emit(t)},this.isOptionSelected=t=>{var e;return(null===(e=this.selectedOption)||void 0===e?void 0:e.label)===t.label},this.toggleDropdown=t=>{this.isDropdownVisible=t},this.resetInput=()=>{var t,e;this.inputValue=null!==(e=null===(t=this.selectedOption)||void 0===t?void 0:t.label)&&void 0!==e?e:"",this.filteredOptions=this._options},this.processKeyboardNavigation=t=>{switch(t.key){case"ArrowDown":return this.toggleDropdown(!0),this.highlightNextItem(),!0;case"ArrowUp":return this.highlightPreviousItem(),!0;case"Enter":return void 0!==this.highlightedOptionIndex&&(this.toggleDropdown(!1),this.selectOption(this.filteredOptions[this.highlightedOptionIndex])),!0;case"Escape":return this.inputElement.blur(),!0}return!1},this.highlightPreviousItem=()=>{0!==this.filteredOptions.length&&(this.highlightedOptionIndex=void 0===this.highlightedOptionIndex?0:Math.max(this.highlightedOptionIndex-1,0))},this.highlightNextItem=()=>{0!==this.filteredOptions.length&&(this.highlightedOptionIndex=void 0===this.highlightedOptionIndex?0:Math.min(this.highlightedOptionIndex+1,this.filteredOptions.length-1))}}get _options(){if(void 0===this.options)throw new Error("Can't render <fl-dropdown /> component with no options");return this.options}componentWillLoad(){var t,e;this.filteredOptions=this._options,this.selectedOption=this._options.find((t=>t.value===this.value)),this.inputValue=null!==(e=null===(t=this.selectedOption)||void 0===t?void 0:t.label)&&void 0!==e?e:""}handleFocus(){this.toggleDropdown(!0)}handleBlur(){this.isMouseOver||(this.toggleDropdown(!1),this.resetInput())}handleKeyDown(t){this.processKeyboardNavigation(t)&&t.preventDefault()}onOptionsChanged(){this.filteredOptions=this._options}onValueChanged(){var t,e;this.selectedOption=this._options.find((t=>t.value===this.value)),this.inputValue=null!==(e=null===(t=this.selectedOption)||void 0===t?void 0:t.label)&&void 0!==e?e:""}render(){var t;return[e("div",{class:"dropdown"},e("input",{type:"text",class:"form-control custom-select",placeholder:this.placeholder,required:this.required,disabled:this.disabled,value:this.inputValue,onInput:t=>{const e=t.target.value;this.inputValue=e,this.filterResults(e),this.toggleDropdown(!0)},ref:t=>this.inputElement=t}),e("div",{class:{"invalid-feedback":!0,"d-none":this.isDropdownVisible}},null!==(t=this.requiredValidationMessage)&&void 0!==t?t:"Required."),e("div",{class:{"dropdown-menu shadow mt-0 w-100 overflow-auto":!0,show:this.isDropdownVisible},onMouseEnter:()=>this.isMouseOver=!0,onMouseLeave:()=>this.isMouseOver=!1},this.renderFilteredResults()))]}sortOptionsByRelevancy(t,e){return t.map((t=>Object.assign(Object.assign({},t),{relevancyScore:dt.compareTwoStrings(t.label.toLowerCase(),e.toLowerCase())}))).sort(((t,e)=>e.relevancyScore-t.relevancyScore)).map((t=>({label:t.label,value:t.value})))}static get watchers(){return{options:["onOptionsChanged"],value:["onValueChanged"]}}};pt.style="fl-dropdown .dropdown-menu{max-height:min(20rem, 50vh)}fl-dropdown .dropdown-menu .dropdown-item{cursor:pointer}fl-dropdown .dropdown-menu .dropdown-item.selected{background-color:rgba(253, 189, 0, 0.5)}";const mt=class{constructor(i){t(this,i),this.valueChanged=n(this,"valueChanged",7),this.required=!1,this.disabled=!1,this.minSearchStringLength=3,this.isMouseOver=!1,this.searchState="pristine",this.inputValue="",this.isDropdownVisible=!1,this.filteredOptions=[],this.shouldExecuteSearch=t=>{var e;return this.isDropdownVisible&&(null==t?void 0:t.length)>=this.minSearchStringLength&&(null===(e=this.selectedOption)||void 0===e?void 0:e.label)!==t},this.onBeginSearch=t=>{this.inputValue=t,this.searchState="in progress"},this.onCompleteSearch=t=>{this.filteredOptions=t,this.highlightedOptionIndex=void 0,this.searchState="done"},this.renderFilteredResults=()=>"pristine"===this.searchState?e("span",{class:"dropdown-item disabled"},"Start typing to find the results"):"in progress"===this.searchState?e("div",{class:"d-flex justify-content-end align-items-center pr-4"},e("span",{class:"dropdown-item disabled"},"Searching..."),e("i",{class:"dot-falling"})):0===this.filteredOptions.length?e("span",{class:"dropdown-item disabled"},"No items match your search"):this.filteredOptions.map(((t,n)=>e("span",{class:{"dropdown-item text-wrap":!0,selected:this.isOptionSelected(t),active:this.highlightedOptionIndex===n},onClick:()=>{this.toggleDropdown(!1),this.selectOption(t)}},t.label))),this.resetInput=()=>{var t,e;this.inputValue=null!==(e=null===(t=this.selectedOption)||void 0===t?void 0:t.label)&&void 0!==e?e:""},this.toggleDropdown=t=>{this.isDropdownVisible=t},this.processKeyboardNavigation=t=>{switch(t.key){case"ArrowDown":return this.toggleDropdown(!0),this.highlightNextItem(),!0;case"ArrowUp":return this.highlightPreviousItem(),!0;case"Enter":return void 0!==this.highlightedOptionIndex&&(this.toggleDropdown(!1),this.selectOption(this.filteredOptions[this.highlightedOptionIndex])),!0;case"Escape":return this.inputElement.blur(),!0}return!1},this.highlightPreviousItem=()=>{0!==this.filteredOptions.length&&(this.highlightedOptionIndex=void 0===this.highlightedOptionIndex?0:Math.max(this.highlightedOptionIndex-1,0))},this.highlightNextItem=()=>{0!==this.filteredOptions.length&&(this.highlightedOptionIndex=void 0===this.highlightedOptionIndex?0:Math.min(this.highlightedOptionIndex+1,this.filteredOptions.length-1))},this.selectOption=t=>{this.selectedOption=t,this.inputValue=t.label,this.valueChanged.emit(t)},this.isOptionSelected=t=>{var e;return(null===(e=this.selectedOption)||void 0===e?void 0:e.label)===t.label}}componentWillLoad(){this.selectedOption=this.value}componentDidLoad(){this.searchResultsSubscription=E(this.inputElement,"keyup").pipe(function(t,e=S){return n=>n.lift(new F(t,e))}(500),f((()=>this.inputElement.value)),m(),v(this.shouldExecuteSearch),M(this.onBeginSearch),q(this._searchFunction),M(this.onCompleteSearch)).subscribe()}componentDidUnload(){this.searchResultsSubscription.unsubscribe()}handleFocus(){this.toggleDropdown(!0)}handleBlur(){this.isMouseOver||(this.toggleDropdown(!1),this.highlightedOptionIndex=void 0,this.resetInput())}handleKeyDown(t){this.processKeyboardNavigation(t)&&t.preventDefault()}render(){var t;return[e("div",{class:"dropdown"},e("input",{type:"text",class:"form-control",placeholder:this.placeholder,required:this.required,disabled:this.disabled,value:this.inputValue,ref:t=>this.inputElement=t}),e("div",{class:{"invalid-feedback":!0,"d-none":this.isDropdownVisible}},null!==(t=this.requiredValidationMessage)&&void 0!==t?t:"Required."),e("div",{class:{"dropdown-menu shadow mt-0 w-100 overflow-auto":!0,show:this.isDropdownVisible},onMouseEnter:()=>this.isMouseOver=!0,onMouseLeave:()=>this.isMouseOver=!1},this.renderFilteredResults()))]}get _searchFunction(){if(void 0===this.searchFunction)throw new Error("Can't render <fl-dropdown-async/> component with no searchFunction");return this.searchFunction}};mt.style="fl-dropdown .dropdown-menu{max-height:min(20rem, 50vh)}fl-dropdown .dropdown-menu .dropdown-item{cursor:pointer}fl-dropdown .dropdown-menu .dropdown-item.selected{background-color:rgba(253, 189, 0, 0.5)}";const vt=class{constructor(e){t(this,e),this.theme="default"}render(){return e("span",{class:{"dots-container d-inline-flex justify-content-center":!0}},e("span",{class:{"dot-flashing":!0,"theme-default":"default"===this.theme,"theme-dark":"dark"===this.theme}}))}};var bt;vt.style='fl-loading-indicator .dots-container{width:36px}fl-loading-indicator .dot-flashing.theme-default{position:relative;width:8px;height:8px;border-radius:4px;background-color:#66efc5;color:#9880ff;-webkit-animation:dot-flashing-default 2s infinite linear;animation:dot-flashing-default 2s infinite linear;-webkit-animation-delay:0.5s;animation-delay:0.5s}@-webkit-keyframes dot-flashing-default{0%{background-color:#66efc5}25%{background-color:#12aa7c}50%,100%{background-color:#66efc5}}@keyframes dot-flashing-default{0%{background-color:#66efc5}25%{background-color:#12aa7c}50%,100%{background-color:#66efc5}}fl-loading-indicator .dot-flashing.theme-default::before,fl-loading-indicator .dot-flashing.theme-default::after{content:"";display:inline-block;position:absolute;top:0}fl-loading-indicator .dot-flashing.theme-default::before{left:-12px;width:8px;height:8px;border-radius:4px;background-color:#66efc5;color:#9880ff;-webkit-animation:dot-flashing-default 2s infinite linear;animation:dot-flashing-default 2s infinite linear;-webkit-animation-delay:0s;animation-delay:0s}@keyframes dot-flashing-default{0%{background-color:#66efc5}25%{background-color:#12aa7c}50%,100%{background-color:#66efc5}}fl-loading-indicator .dot-flashing.theme-default::after{left:12px;width:8px;height:8px;border-radius:4px;background-color:#66efc5;color:#9880ff;-webkit-animation:dot-flashing-default 2s infinite linear;animation:dot-flashing-default 2s infinite linear;-webkit-animation-delay:1s;animation-delay:1s}@keyframes dot-flashing-default{0%{background-color:#66efc5}25%{background-color:#12aa7c}50%,100%{background-color:#66efc5}}fl-loading-indicator .dot-flashing.theme-dark{position:relative;width:8px;height:8px;border-radius:4px;background-color:#a7a7a7;color:#9880ff;-webkit-animation:dot-flashing-dark 2s infinite linear;animation:dot-flashing-dark 2s infinite linear;-webkit-animation-delay:0.5s;animation-delay:0.5s}@-webkit-keyframes dot-flashing-dark{0%{background-color:#a7a7a7}25%{background-color:#5b5a5a}50%,100%{background-color:#a7a7a7}}@keyframes dot-flashing-dark{0%{background-color:#a7a7a7}25%{background-color:#5b5a5a}50%,100%{background-color:#a7a7a7}}fl-loading-indicator .dot-flashing.theme-dark::before,fl-loading-indicator .dot-flashing.theme-dark::after{content:"";display:inline-block;position:absolute;top:0}fl-loading-indicator .dot-flashing.theme-dark::before{left:-12px;width:8px;height:8px;border-radius:4px;background-color:#a7a7a7;color:#9880ff;-webkit-animation:dot-flashing-dark 2s infinite linear;animation:dot-flashing-dark 2s infinite linear;-webkit-animation-delay:0s;animation-delay:0s}@keyframes dot-flashing-dark{0%{background-color:#a7a7a7}25%{background-color:#5b5a5a}50%,100%{background-color:#a7a7a7}}fl-loading-indicator .dot-flashing.theme-dark::after{left:12px;width:8px;height:8px;border-radius:4px;background-color:#a7a7a7;color:#9880ff;-webkit-animation:dot-flashing-dark 2s infinite linear;animation:dot-flashing-dark 2s infinite linear;-webkit-animation-delay:1s;animation-delay:1s}@keyframes dot-flashing-dark{0%{background-color:#a7a7a7}25%{background-color:#5b5a5a}50%,100%{background-color:#a7a7a7}}',function(t){t[t.Available=0]="Available",t[t.Pending=1]="Pending",t[t.Error=2]="Error"}(bt||(bt={}));const gt=class{constructor(e){t(this,e),this.isBlockElement=!1,this.isRounded=!1,this.disabled=!1,this.variant="primary",this.promiseFn=()=>Promise.resolve(),this.state=bt.Available}render(){return this.state===bt.Pending?this.renderLoadingButton():this.renderActiveButton()}renderActiveButton(){return e("fl-button",{disabled:this.disabled,onClick:()=>this.clicked(),isBlockElement:this.isBlockElement,variant:this.variant},e("div",null,e("slot",null)))}renderLoadingButton(){return e("fl-button",{disabled:!0,onClick:()=>this.clicked(),isBlockElement:this.isBlockElement,class:"position-relative",variant:this.variant},e("fl-loading-indicator",{class:"position-absolute",theme:"dark"}),e("div",{class:"invisible"},e("slot",null)))}async clicked(){this.state=bt.Pending;try{await this.promiseFn(),this.state=bt.Available}catch(t){throw this.state=bt.Error,t}}};function wt(t,e){void 0===e&&(e="*"),t.sender="flare",window.parent.postMessage(t,e)}gt.style="fl-promise-button fl-loading-indicator{left:50%;top:50%;-webkit-transform:translate(-50%, -50%);transform:translate(-50%, -50%)}";const yt=function(){wt({type:"appReady"})},xt=function(t,e){wt({type:"contentResized",height:t,width:e})},kt=function(t){wt({type:"pageNavigated",url:t})},St=function(){wt({type:"complete"})},Ct=function(){wt({type:"submitSuccess"})},_t=t=>!("isConnected"in t)||t.isConnected,At=(()=>{let t;return(...e)=>{t&&clearTimeout(t),t=setTimeout((()=>{t=0,(t=>{for(let e of t.keys())t.set(e,t.get(e).filter(_t))})(...e)}),2e3)}})(),qt=(t,e)=>{const n=((t,e=((t,e)=>t!==e))=>{let n=new Map(Object.entries(null!=t?t:{}));const i={dispose:[],get:[],set:[],reset:[]},r=()=>{n=new Map(Object.entries(null!=t?t:{})),i.reset.forEach((t=>t()))},o=t=>(i.get.forEach((e=>e(t))),n.get(t)),s=(t,r)=>{const o=n.get(t);e(r,o,t)&&(n.set(t,r),i.set.forEach((e=>e(t,r,o))))},a="undefined"==typeof Proxy?{}:new Proxy(t,{get:(t,e)=>o(e),ownKeys:()=>Array.from(n.keys()),getOwnPropertyDescriptor:()=>({enumerable:!0,configurable:!0}),has:(t,e)=>n.has(e),set:(t,e,n)=>(s(e,n),!0)}),c=(t,e)=>(i[t].push(e),()=>{((t,e)=>{const n=t.indexOf(e);n>=0&&(t[n]=t[t.length-1],t.length--)})(i[t],e)});return{state:a,get:o,set:s,on:c,onChange:(e,n)=>{const i=c("set",((t,i)=>{t===e&&n(i)})),r=c("reset",(()=>n(t[e])));return()=>{i(),r()}},use:(...t)=>t.forEach((t=>{t.set&&c("set",t.set),t.get&&c("get",t.get),t.reset&&c("reset",t.reset)})),dispose:()=>{i.dispose.forEach((t=>t())),r()},reset:r}})(t,e);return(({on:t})=>{const e=new Map;"function"==typeof i&&(t("dispose",(()=>{e.clear()})),t("get",(t=>{const n=i();n&&((t,e,n)=>{const i=t.get(e);i?i.includes(n)||i.push(n):t.set(e,[n])})(e,t,n)})),t("set",(t=>{const n=e.get(t);n&&e.set(t,n.filter(r)),At(e)})),t("reset",(()=>{e.forEach((t=>t.forEach(r))),At(e)})))})(n),n};function Bt(t,e,n){return t(n={path:e,exports:{},require:function(){return function(){throw new Error("Dynamic requires are not currently supported by @rollup/plugin-commonjs")}()}},n.exports),n.exports}var jt=Bt((function(t,e){function n(t){return t}function i(t){return function(){return t}}function r(){throw new Error("Called `absurd` function which should be uncallable")}Object.defineProperty(e,"__esModule",{value:!0}),e.bindTo_=e.bind_=e.hole=e.pipe=e.untupled=e.tupled=e.absurd=e.decrement=e.increment=e.tuple=e.flow=e.flip=e.constVoid=e.constUndefined=e.constNull=e.constFalse=e.constTrue=e.constant=e.not=e.unsafeCoerce=e.identity=void 0,e.identity=n,e.unsafeCoerce=n,e.not=function(t){return function(e){return!t(e)}},e.constant=i,e.constTrue=i(!0),e.constFalse=i(!1),e.constNull=i(null),e.constUndefined=i(void 0),e.constVoid=e.constUndefined,e.flip=function(t){return function(e,n){return t(n,e)}},e.flow=function(t,e,n,i,r,o,s,a,c){switch(arguments.length){case 1:return t;case 2:return function(){return e(t.apply(this,arguments))};case 3:return function(){return n(e(t.apply(this,arguments)))};case 4:return function(){return i(n(e(t.apply(this,arguments))))};case 5:return function(){return r(i(n(e(t.apply(this,arguments)))))};case 6:return function(){return o(r(i(n(e(t.apply(this,arguments))))))};case 7:return function(){return s(o(r(i(n(e(t.apply(this,arguments)))))))};case 8:return function(){return a(s(o(r(i(n(e(t.apply(this,arguments))))))))};case 9:return function(){return c(a(s(o(r(i(n(e(t.apply(this,arguments)))))))))}}},e.tuple=function(){for(var t=[],e=0;e<arguments.length;e++)t[e]=arguments[e];return t},e.increment=function(t){return t+1},e.decrement=function(t){return t-1},e.absurd=r,e.tupled=function(t){return function(e){return t.apply(void 0,e)}},e.untupled=function(t){return function(){for(var e=[],n=0;n<arguments.length;n++)e[n]=arguments[n];return t(e)}},e.pipe=function(t,e,n,i,r,o,s,a,c,u,l,f,d,h,p,m,v,b,g,w){switch(arguments.length){case 1:return t;case 2:return e(t);case 3:return n(e(t));case 4:return i(n(e(t)));case 5:return r(i(n(e(t))));case 6:return o(r(i(n(e(t)))));case 7:return s(o(r(i(n(e(t))))));case 8:return a(s(o(r(i(n(e(t)))))));case 9:return c(a(s(o(r(i(n(e(t))))))));case 10:return u(c(a(s(o(r(i(n(e(t)))))))));case 11:return l(u(c(a(s(o(r(i(n(e(t))))))))));case 12:return f(l(u(c(a(s(o(r(i(n(e(t)))))))))));case 13:return d(f(l(u(c(a(s(o(r(i(n(e(t))))))))))));case 14:return h(d(f(l(u(c(a(s(o(r(i(n(e(t)))))))))))));case 15:return p(h(d(f(l(u(c(a(s(o(r(i(n(e(t))))))))))))));case 16:return m(p(h(d(f(l(u(c(a(s(o(r(i(n(e(t)))))))))))))));case 17:return v(m(p(h(d(f(l(u(c(a(s(o(r(i(n(e(t))))))))))))))));case 18:return b(v(m(p(h(d(f(l(u(c(a(s(o(r(i(n(e(t)))))))))))))))));case 19:return g(b(v(m(p(h(d(f(l(u(c(a(s(o(r(i(n(e(t))))))))))))))))));case 20:return w(g(b(v(m(p(h(d(f(l(u(c(a(s(o(r(i(n(e(t)))))))))))))))))))}},e.hole=r,e.bind_=function(t,e,n){var i;return Object.assign({},t,((i={})[e]=n,i))},e.bindTo_=function(t){return function(e){var n;return(n={})[t]=e,n}}})),Et=Bt((function(t,e){function n(t){return null==t?e.none:e.some(t)}function i(t){return"Right"===t._tag?e.none:e.some(t.left)}function r(t){return"Left"===t._tag?e.none:e.some(t.right)}function o(t){return function(i){return e.isNone(i)?e.none:n(t(i.value))}}Object.defineProperty(e,"__esModule",{value:!0}),e.getApplySemigroup=e.getOrd=e.getEq=e.getShow=e.URI=e.wilt=e.wither=e.sequence=e.traverse=e.partitionMap=e.partition=e.filterMap=e.filter=e.separate=e.compact=e.reduceRight=e.foldMap=e.reduce=e.duplicate=e.extend=e.throwError=e.zero=e.alt=e.altW=e.flatten=e.chainFirst=e.chain=e.of=e.apSecond=e.apFirst=e.ap=e.map=e.chainNullableK=e.mapNullable=e.fromNullableK=e.getOrElse=e.getOrElseW=e.toUndefined=e.toNullable=e.fold=e.fromEither=e.getRight=e.getLeft=e.tryCatch=e.fromPredicate=e.fromNullable=e.some=e.none=e.isNone=e.isSome=void 0,e.sequenceArray=e.traverseArray=e.traverseArrayWithIndex=e.apS=e.bind=e.bindTo=e.Do=e.getRefinement=e.exists=e.elem=e.option=e.MonadThrow=e.Witherable=e.Traversable=e.Filterable=e.Compactable=e.Extend=e.Alternative=e.Alt=e.Foldable=e.Monad=e.Applicative=e.Functor=e.getMonoid=e.getLastMonoid=e.getFirstMonoid=e.getApplyMonoid=void 0,e.isSome=function(t){return"Some"===t._tag},e.isNone=function(t){return"None"===t._tag},e.none={_tag:"None"},e.some=function(t){return{_tag:"Some",value:t}},e.fromNullable=n,e.fromPredicate=function(t){return function(n){return t(n)?e.some(n):e.none}},e.tryCatch=function(t){try{return e.some(t())}catch(t){return e.none}},e.getLeft=i,e.getRight=r,e.fromEither=r,e.fold=function(t,n){return function(i){return e.isNone(i)?t():n(i.value)}},e.toNullable=function(t){return e.isNone(t)?null:t.value},e.toUndefined=function(t){return e.isNone(t)?void 0:t.value},e.getOrElseW=function(t){return function(n){return e.isNone(n)?t():n.value}},e.getOrElse=e.getOrElseW,e.fromNullableK=function(t){return function(){for(var e=[],i=0;i<arguments.length;i++)e[i]=arguments[i];return n(t.apply(void 0,e))}},e.mapNullable=o,e.chainNullableK=o;var s=function(t,n){return jt.pipe(t,e.map(n))},a=function(t,n){return jt.pipe(t,e.ap(n))},c=function(t,n){return jt.pipe(t,e.chain(n))},u=function(t,n,i){return jt.pipe(t,e.reduce(n,i))},l=function(t){var n=e.foldMap(t);return function(t,e){return jt.pipe(t,n(e))}},f=function(t,n,i){return jt.pipe(t,e.reduceRight(n,i))},d=function(t){var n=e.traverse(t);return function(t,e){return jt.pipe(t,n(e))}},h=function(t,n){return jt.pipe(t,e.alt(n))},p=function(t,n){return jt.pipe(t,e.filter(n))},m=function(t,n){return jt.pipe(t,e.filterMap(n))},v=function(t,n){return jt.pipe(t,e.extend(n))},b=function(t,n){return jt.pipe(t,e.partition(n))},g=function(t,n){return jt.pipe(t,e.partitionMap(n))},w=function(t){var n=e.wither(t);return function(t,e){return jt.pipe(t,n(e))}},y=function(t){var n=e.wilt(t);return function(t,e){return jt.pipe(t,n(e))}};e.map=function(t){return function(n){return e.isNone(n)?e.none:e.some(t(n.value))}},e.ap=function(t){return function(n){return e.isNone(n)||e.isNone(t)?e.none:e.some(n.value(t.value))}},e.apFirst=function(t){return jt.flow(e.map((function(t){return function(){return t}})),e.ap(t))},e.apSecond=function(t){return jt.flow(e.map((function(){return function(t){return t}})),e.ap(t))},e.of=e.some,e.chain=function(t){return function(n){return e.isNone(n)?e.none:t(n.value)}},e.chainFirst=function(t){return e.chain((function(n){return jt.pipe(t(n),e.map((function(){return n})))}))},e.flatten=e.chain(jt.identity),e.altW=function(t){return function(n){return e.isNone(n)?t():n}},e.alt=e.altW,e.zero=function(){return e.none},e.throwError=function(){return e.none},e.extend=function(t){return function(n){return e.isNone(n)?e.none:e.some(t(n))}},e.duplicate=e.extend(jt.identity),e.reduce=function(t,n){return function(i){return e.isNone(i)?t:n(t,i.value)}},e.foldMap=function(t){return function(n){return function(i){return e.isNone(i)?t.empty:n(i.value)}}},e.reduceRight=function(t,n){return function(i){return e.isNone(i)?t:n(i.value,t)}},e.compact=e.flatten;var x={left:e.none,right:e.none};function k(t){return{equals:function(n,i){return n===i||(e.isNone(n)?e.isNone(i):!e.isNone(i)&&t.equals(n.value,i.value))}}}function S(t){return{concat:function(n,i){return e.isSome(n)&&e.isSome(i)?e.some(t.concat(n.value,i.value)):e.none}}}e.separate=function(t){var n=jt.pipe(t,e.map((function(t){return{left:i(t),right:r(t)}})));return e.isNone(n)?x:n.value},e.filter=function(t){return function(n){return e.isNone(n)?e.none:t(n.value)?n:e.none}},e.filterMap=function(t){return function(n){return e.isNone(n)?e.none:t(n.value)}},e.partition=function(t){return function(e){return{left:p(e,(function(e){return!t(e)})),right:p(e,t)}}},e.partitionMap=function(t){return jt.flow(e.map(t),e.separate)},e.traverse=function(t){return function(n){return function(i){return e.isNone(i)?t.of(e.none):t.map(n(i.value),e.some)}}},e.sequence=function(t){return function(n){return e.isNone(n)?t.of(e.none):t.map(n.value,e.some)}},e.wither=function(t){return function(n){return function(i){return e.isNone(i)?t.of(e.none):n(i.value)}}},e.wilt=function(t){return function(n){return function(o){return e.isNone(o)?t.of({left:e.none,right:e.none}):t.map(n(o.value),(function(t){return{left:i(t),right:r(t)}}))}}},e.URI="Option",e.getShow=function(t){return{show:function(n){return e.isNone(n)?"none":"some("+t.show(n.value)+")"}}},e.getEq=k,e.getOrd=function(t){return{equals:k(t).equals,compare:function(n,i){return n===i?0:e.isSome(n)?e.isSome(i)?t.compare(n.value,i.value):1:-1}}},e.getApplySemigroup=S,e.getApplyMonoid=function(t){return{concat:S(t).concat,empty:e.some(t.empty)}},e.getFirstMonoid=function(){return{concat:function(t,n){return e.isNone(t)?n:t},empty:e.none}},e.getLastMonoid=function(){return{concat:function(t,n){return e.isNone(n)?t:n},empty:e.none}},e.getMonoid=function(t){return{concat:function(n,i){return e.isNone(n)?i:e.isNone(i)?n:e.some(t.concat(n.value,i.value))},empty:e.none}},e.Functor={URI:e.URI,map:s},e.Applicative={URI:e.URI,map:s,ap:a,of:e.of},e.Monad={URI:e.URI,map:s,ap:a,of:e.of,chain:c},e.Foldable={URI:e.URI,reduce:u,foldMap:l,reduceRight:f},e.Alt={URI:e.URI,map:s,alt:h},e.Alternative={URI:e.URI,map:s,ap:a,of:e.of,alt:h,zero:e.zero},e.Extend={URI:e.URI,map:s,extend:v},e.Compactable={URI:e.URI,compact:e.compact,separate:e.separate},e.Filterable={URI:e.URI,map:s,compact:e.compact,separate:e.separate,filter:p,filterMap:m,partition:b,partitionMap:g},e.Traversable={URI:e.URI,map:s,reduce:u,foldMap:l,reduceRight:f,traverse:d,sequence:e.sequence},e.Witherable={URI:e.URI,map:s,reduce:u,foldMap:l,reduceRight:f,traverse:d,sequence:e.sequence,compact:e.compact,separate:e.separate,filter:p,filterMap:m,partition:b,partitionMap:g,wither:w,wilt:y},e.MonadThrow={URI:e.URI,map:s,ap:a,of:e.of,chain:c,throwError:e.throwError},e.option={URI:e.URI,map:s,of:e.of,ap:a,chain:c,reduce:u,foldMap:l,reduceRight:f,traverse:d,sequence:e.sequence,zero:e.zero,alt:h,extend:v,compact:e.compact,separate:e.separate,filter:p,filterMap:m,partition:b,partitionMap:g,wither:w,wilt:y,throwError:e.throwError},e.elem=function(t){return function(n,i){return!e.isNone(i)&&t.equals(n,i.value)}},e.exists=function(t){return function(n){return!e.isNone(n)&&t(n.value)}},e.getRefinement=function(t){return function(n){return e.isSome(t(n))}},e.Do=e.of({}),e.bindTo=function(t){return e.map(jt.bindTo_(t))},e.bind=function(t,n){return e.chain((function(i){return jt.pipe(n(i),e.map((function(e){return jt.bind_(i,t,e)})))}))},e.apS=function(t,n){return jt.flow(e.map((function(e){return function(n){return jt.bind_(e,t,n)}})),e.ap(n))},e.traverseArrayWithIndex=function(t){return function(n){for(var i=[],r=0;r<n.length;r++){var o=t(r,n[r]);if(e.isNone(o))return e.none;i.push(o.value)}return e.some(i)}},e.traverseArray=function(t){return e.traverseArrayWithIndex((function(e,n){return t(n)}))},e.sequenceArray=e.traverseArray(jt.identity)}));function It(t){this.message=t}(It.prototype=new Error).name="InvalidCharacterError";var Ft="undefined"!=typeof window&&window.atob&&window.atob.bind(window)||function(t){var e=String(t).replace(/=+$/,"");if(e.length%4==1)throw new It("'atob' failed: The string to be decoded is not correctly encoded.");for(var n,i,r=0,o=0,s="";i=e.charAt(o++);~i&&(n=r%4?64*n+i:i,r++%4)?s+=String.fromCharCode(255&n>>(-2*r&6)):0)i="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/=".indexOf(i);return s};function Pt(t){var e=t.replace(/-/g,"+").replace(/_/g,"/");switch(e.length%4){case 0:break;case 2:e+="==";break;case 3:e+="=";break;default:throw"Illegal base64url string!"}try{return function(t){return decodeURIComponent(Ft(t).replace(/(.)/g,(function(t,e){var n=e.charCodeAt(0).toString(16).toUpperCase();return n.length<2&&(n="0"+n),"%"+n})))}(e)}catch(t){return Ft(e)}}function Rt(t){this.message=t}(Rt.prototype=new Error).name="InvalidTokenError";var Mt=function(){return(Mt=Object.assign||function(t){for(var e,n=1,i=arguments.length;n<i;n++)for(var r in e=arguments[n])Object.prototype.hasOwnProperty.call(e,r)&&(t[r]=e[r]);return t}).apply(this,arguments)},Tt=function(){for(var t=0,e=0,n=arguments.length;e<n;e++)t+=arguments[e].length;var i=Array(t),r=0;for(e=0;e<n;e++)for(var o=arguments[e],s=0,a=o.length;s<a;s++,r++)i[r]=o[s];return i},Nt=function(t,e,n){if(void 0===n&&(n=!1),!t||!e||"object"!=typeof t||"object"!=typeof e)return t;var i=Mt({},t);for(var r in e)e.hasOwnProperty(r)&&(i[r]=e[r]instanceof Array&&t[r]instanceof Array?n?Tt(t[r],e[r]):e[r]:"object"==typeof e[r]&&"object"==typeof t[r]?Nt(t[r],e[r],n):e[r]);return i},Dt=function(){for(var t=0,e=0,n=arguments.length;e<n;e++)t+=arguments[e].length;var i=Array(t),r=0;for(e=0;e<n;e++)for(var o=arguments[e],s=0,a=o.length;s<a;s++,r++)i[r]=o[s];return i},Ot={defaults:{},errorType:null,polyfills:{fetch:null,FormData:null,URLSearchParams:null,performance:null,PerformanceObserver:null,AbortController:null},polyfill:function(t,e){for(var n=void 0===e?{}:e,i=n.doThrow,r=void 0===i||i,o=n.instance,s=void 0!==o&&o,a=[],c=2;c<arguments.length;c++)a[c-2]=arguments[c];var u=this.polyfills[t]||("undefined"!=typeof self?self[t]:null)||("undefined"!=typeof global?global[t]:null);if(r&&!u)throw new Error(t+" is not defined");return s&&u?new(u.bind.apply(u,Dt([void 0],a))):u}},Ut=function(t,e,n,i){if(!t.getEntriesByName)return!1;var r=t.getEntriesByName(e);return!!(r&&r.length>0)&&(n(r.reverse()[0]),i.clearMeasures&&i.clearMeasures(e),Lt.callbacks.delete(e),Lt.callbacks.size<1&&(Lt.observer.disconnect(),i.clearResourceTimings&&i.clearResourceTimings()),!0)},Lt={callbacks:new Map,observer:null,observe:function(t,e){if(t&&e){var n=Ot.polyfill("performance",{doThrow:!1});(function(t,e){return!Lt.observer&&t&&e&&(Lt.observer=new e((function(e){Lt.callbacks.forEach((function(n,i){Ut(e,i,n,t)}))})),t.clearResourceTimings&&t.clearResourceTimings()),Lt.observer})(n,Ot.polyfill("PerformanceObserver",{doThrow:!1}))&&(Ut(n,t,e,n)||(Lt.callbacks.size<1&&Lt.observer.observe({entryTypes:["resource","measure"]}),Lt.callbacks.set(t,e)))}}},zt=function(t){this.error=t},Ht=function(){return(Ht=Object.assign||function(t){for(var e,n=1,i=arguments.length;n<i;n++)for(var r in e=arguments[n])Object.prototype.hasOwnProperty.call(e,r)&&(t[r]=e[r]);return t}).apply(this,arguments)},Vt=function(){for(var t=0,e=0,n=arguments.length;e<n;e++)t+=arguments[e].length;var i=Array(t),r=0;for(e=0;e<n;e++)for(var o=arguments[e],s=0,a=o.length;s<a;s++,r++)i[r]=o[s];return i},Qt=function(){function t(t,e,n,i,r,o){void 0===n&&(n=new Map),void 0===i&&(i=[]),void 0===r&&(r=[]),void 0===o&&(o=[]),this._url=t,this._options=e,this._catchers=n,this._resolvers=i,this._middlewares=r,this._deferredChain=o}return t.factory=function(e,n){return void 0===e&&(e=""),void 0===n&&(n={}),new t(e,n)},t.prototype.selfFactory=function(e){var n=void 0===e?{}:e,i=n.url,r=n.options,o=n.catchers,s=void 0===o?this._catchers:o,a=n.resolvers,c=void 0===a?this._resolvers:a,u=n.middlewares,l=void 0===u?this._middlewares:u,f=n.deferredChain,d=void 0===f?this._deferredChain:f;return new t(void 0===i?this._url:i,Ht({},void 0===r?this._options:r),new Map(s),Vt(c),Vt(l),Vt(d))},t.prototype.defaults=function(t,e){return void 0===e&&(e=!1),Ot.defaults=e?Nt(Ot.defaults,t):t,this},t.prototype.errorType=function(t){return Ot.errorType=t,this},t.prototype.polyfills=function(t){return Ot.polyfills=Ht(Ht({},Ot.polyfills),t),this},t.prototype.url=function(t,e){if(void 0===e&&(e=!1),e)return this.selfFactory({url:t});var n=this._url.split("?");return this.selfFactory({url:n.length>1?n[0]+t+"?"+n[1]:this._url+t})},t.prototype.options=function(t,e){return void 0===e&&(e=!0),this.selfFactory({options:e?Nt(this._options,t):t})},t.prototype.query=function(t,e){return void 0===e&&(e=!1),this.selfFactory({url:Wt(this._url,t,e)})},t.prototype.headers=function(t){return this.selfFactory({options:Nt(this._options,{headers:t||{}})})},t.prototype.accept=function(t){return this.headers({Accept:t})},t.prototype.content=function(t){var e;return this.headers(((e={})["Content-Type"]=t,e))},t.prototype.auth=function(t){return this.headers({Authorization:t})},t.prototype.catcher=function(t,e){var n=new Map(this._catchers);return n.set(t,e),this.selfFactory({catchers:n})},t.prototype.signal=function(t){return this.selfFactory({options:Ht(Ht({},this._options),{signal:t.signal})})},t.prototype.resolve=function(t,e){return void 0===e&&(e=!1),this.selfFactory({resolvers:e?[t]:Vt(this._resolvers,[t])})},t.prototype.defer=function(t,e){return void 0===e&&(e=!1),this.selfFactory({deferredChain:e?[t]:Vt(this._deferredChain,[t])})},t.prototype.middlewares=function(t,e){return void 0===e&&(e=!1),this.selfFactory({middlewares:e?t:Vt(this._middlewares,t)})},t.prototype.method=function(t,e,n){void 0===e&&(e={}),void 0===n&&(n=null);var i=this._options.headers,r=n?"object"!=typeof n||i&&!Object.entries(i).every((function(t){var e=t[1];return t[0].toLowerCase()!=="Content-Type".toLowerCase()||e.startsWith("application/json")}))?this.body(n):this.json(n):this;return function(t){var e=t._url,n=t._resolvers,i=t._middlewares,r=t._options,o=new Map(t._catchers),s=Nt(Ot.defaults,r),a=Ot.polyfill("AbortController",{doThrow:!1,instance:!0});!s.signal&&a&&(s.signal=a.signal);var c={ref:null,clear:function(){c.ref&&(clearTimeout(c.ref),c.ref=null)}},u=function(t){return function(e){return 0===t.length?e:1===t.length?t[0](e):t.reduceRight((function(n,i,r){return i(r===t.length-2?n(e):n)}))}}(i)(Ot.polyfill("fetch"))(e,s),l=u.catch((function(t){throw new zt(t)})).then((function(t){return c.clear(),t.ok?t:t[Ot.errorType||"text"]().then((function(e){var n=new Error(e);throw n[Ot.errorType||"text"]=e,n.status=t.status,n.response=t,n}))})),f=function(e){return function(n){return(e?l.then((function(t){return t&&t[e]()})).then((function(t){return n?n(t):t})):l.then((function(t){return n?n(t):t}))).catch((function(e){c.clear();var n=e instanceof zt?e.error:e;if(e instanceof zt&&o.has("__fromFetch"))return o.get("__fromFetch")(n,t);if(o.has(n.status))return o.get(n.status)(n,t);if(o.has(n.name))return o.get(n.name)(n,t);throw n}))}},d={res:f(null),json:f("json"),blob:f("blob"),formData:f("formData"),arrayBuffer:f("arrayBuffer"),text:f("text"),perfs:function(t){return u.then((function(e){return Lt.observe(e.url,t)})),d},setTimeout:function(t,e){return void 0===e&&(e=a),c.clear(),c.ref=setTimeout((function(){return e.abort()}),t),d},controller:function(){return[a,d]},error:function(t,e){return o.set(t,e),d},badRequest:function(t){return d.error(400,t)},unauthorized:function(t){return d.error(401,t)},forbidden:function(t){return d.error(403,t)},notFound:function(t){return d.error(404,t)},timeout:function(t){return d.error(408,t)},internalError:function(t){return d.error(500,t)},fetchError:function(t){return d.error("__fromFetch",t)},onAbort:function(t){return d.error("AbortError",t)}};return n.reduce((function(e,n){return n(e,t)}),d)}((r=r.options(Ht(Ht({},e),{method:t})))._deferredChain.reduce((function(t,e){return e(t,t._url,t._options)}),r))},t.prototype.get=function(t){return this.method("GET",t)},t.prototype.delete=function(t){return this.method("DELETE",t)},t.prototype.put=function(t,e){return this.method("PUT",e,t)},t.prototype.post=function(t,e){return this.method("POST",e,t)},t.prototype.patch=function(t,e){return this.method("PATCH",e,t)},t.prototype.head=function(t){return this.method("HEAD",t)},t.prototype.opts=function(t){return this.method("OPTIONS",t)},t.prototype.replay=function(t){return this.method(this._options.method,t)},t.prototype.body=function(t){return this.selfFactory({options:Ht(Ht({},this._options),{body:t})})},t.prototype.json=function(t){var e,n=null===(e=Object.entries(this._options.headers||{}).find((function(t){var e=t[1];return t[0].toLowerCase()==="Content-Type".toLowerCase()&&e.startsWith("application/json")})))||void 0===e?void 0:e[1];return this.content(n||"application/json").body(JSON.stringify(t))},t.prototype.formData=function(t,e){return void 0===e&&(e=!1),this.body($t(t,e))},t.prototype.formUrl=function(t){return this.body("string"==typeof t?t:(e=t,Object.keys(e).map((function(t){var n=e[t];return n instanceof Array?n.map((function(e){return Yt(t,e)})).join("&"):Yt(t,n)})).join("&"))).content("application/x-www-form-urlencoded");var e},t}(),Wt=function(t,e,n){var i;if("string"==typeof e)i=e;else{var r=Ot.polyfill("URLSearchParams",{instance:!0});for(var o in e)if(e[o]instanceof Array)for(var s=0,a=e[o];s<a.length;s++)r.append(o,a[s]);else r.append(o,e[o]);i=r.toString()}var c=t.split("?");return n||c.length<2?c[0]+"?"+i:t+"&"+i};function $t(t,e,n,i){return void 0===e&&(e=!1),void 0===n&&(n=Ot.polyfill("FormData",{instance:!0})),void 0===i&&(i=[]),Object.entries(t).forEach((function(t){var r=t[0],o=t[1],s=i.reduce((function(t,e){return t?t+"["+e+"]":e}),null);if(s=s?s+"["+r+"]":r,o instanceof Array)for(var a=0,c=o;a<c.length;a++)n.append(s+"[]",c[a]);else!e||"object"!=typeof o||e instanceof Array&&e.includes(r)?n.append(s,o):null!==o&&$t(o,e,n,Vt(i,[r]))})),n}function Yt(t,e){return encodeURIComponent(t)+"="+encodeURIComponent("object"==typeof e?JSON.stringify(e):""+e)}var Xt=Qt.factory;function Jt(){const t=Zt.jwt,e=Zt.profileId,n=Zt.accountIdOrDefault,i=Zt.partnerIdOrDefault;return Xt(Zt.apiBaseUrl).headers({Authorization:"Bearer "+t,"X-PROFILE-ID":e,"X-PARTNER-ID":i,"X-ACCOUNT-ID":n})}Xt.default=Qt.factory;const Gt=new class{async getAustralianFundsAsync(t){return Jt().url("super-choice/australian-funds?"+this.toQueryString(t)).get().notFound((()=>{throw new Error("Failed to fetch the list of australian super funds.")})).json()}async getAppStateAsync(){return Jt().url("client-app-state").get().notFound((()=>{throw new Error("Failed to fetch application configuration.")})).json()}toQueryString(t){switch(t.type){case"partialMatch":return`search=${t.searchString}&maxRecordCount=${t.maxRecordCount}`;case"usiMatch":return"usi="+t.usi}}},Kt={apiBaseUrl:Et.none,appBaseUrl:Et.none,profileId:Et.none,jwt:Et.none,superBuyer:Et.none,promotedFunds:Et.none,accountConfiguration:Et.none,hasSuccessPageBeenAcknowledged:!1,hasSuperSelectionBeenSubmitted:!1},Zt=new class{constructor(){const{state:t,onChange:e}=qt(Kt);this._state=t,this._onChange=e,e("jwt",(t=>{this._state.profileId=jt.pipe(t,Et.chain((t=>Et.fromNullable(function(t,e){if("string"!=typeof t)throw new Rt("Invalid token specified");var n=!0===(e=e||{}).header?0:1;try{return JSON.parse(Pt(t.split(".")[n]))}catch(t){throw new Rt("Invalid token specified: "+t.message)}}(t).sub))))}))}get state(){return this._state}get onChange(){return this._onChange}get superBuyer(){if(Et.isNone(this._state.superBuyer))throw Error("User information is not set");return this._state.superBuyer.value}get apiBaseUrl(){if(Et.isNone(this._state.apiBaseUrl))throw Error("API base URL is not set");return this._state.apiBaseUrl.value}get appBaseUrl(){if(Et.isNone(this._state.appBaseUrl))throw Error("App base URL is not set");return this._state.appBaseUrl.value}get promotedFunds(){if(Et.isNone(this._state.promotedFunds))throw Error("Promoted Funds is not set");return this._state.promotedFunds.value}get profileId(){if(Et.isNone(this._state.profileId))throw Error("Failed to get Profile ID from JWT");return this._state.profileId.value}get defaultFundUsi(){return jt.pipe(this._state.accountConfiguration,Et.map((t=>Et.fromNullable(t.defaultFundUsi))),Et.flatten)}get accountIdOrDefault(){return jt.pipe(this._state.accountConfiguration,Et.map((t=>t.accountId)),Et.getOrElse((()=>"")))}get partnerIdOrDefault(){return jt.pipe(this._state.superBuyer,Et.map((t=>t.partnerId)),Et.getOrElse((()=>"")))}get jwt(){if(Et.isNone(this._state.jwt))throw Error("No authentication information was found");return this._state.jwt.value}get showSmsfNotSupported(){return jt.pipe(this._state.superBuyer,Et.map((t=>t.showSmsfNotSupported)),Et.getOrElse((()=>!1)))}completeSuperSelectionFlow(){this._state.hasSuccessPageBeenAcknowledged=!0}markSuperSelectionAsSubmitted(){this._state.hasSuperSelectionBeenSubmitted=!0}async loadAppStateAsync(){const t=await Gt.getAppStateAsync();this._state.accountConfiguration=Et.fromNullable(t.accountConfiguration),this._state.superBuyer=Et.fromNullable(t.superBuyer),this._state.promotedFunds=Et.fromNullable(t.promotedFunds)}},te=new class{navigateInternally(t,e){const n=`${this.appBaseUrl}${this.toRouteWithLeadingSlash(e)}`;kt(n),t.push(n)}toExternalUrl(t){const e=new URL(t);return e.searchParams.append("_extnav","true"),e.href}get appBaseUrl(){return Zt.appBaseUrl.replace(/\/$/,"")}toRouteWithLeadingSlash(t){return t.length>0&&"/"===t[0]?t:"/"+t}};var ee;!function(t){t.ChoicePage="/",t.SlateJoin="/slate/join/",t.SlateStandardChoice="/slate/standard-choice/",t.QSuperOptIn="/qsuper/insurance/opt-in/",t.QSuperQuestion1="/qsuper/insurance/question1/",t.QSuperQuestion2="/qsuper/insurance/question2/",t.QSuperQuestion3="/qsuper/insurance/question3/",t.QSuperQuestion4="/qsuper/insurance/question4/",t.QSuperQuestion5="/qsuper/insurance/question5/",t.QSuperQuestion6="/qsuper/insurance/question6/",t.QSuperQuestion7="/qsuper/insurance/question7/",t.QSuperQuestion8="/qsuper/insurance/question8/",t.QSuperConsent="/qsuper/consent/",t.QSuperJoin="/qsuper/join/",t.PromotedFundJoin="/promoted-fund/join",t.PromotedFundStandardChoice="/promoted-fund/standard-choice/",t.MyOwnFund="/super-choice/my-own-fund/",t.SelfManagedFund="/super-choice/smsf/",t.DefaultFund="/super-choice/default/",t.Success="/success/"}(ee||(ee={}));const ne=[e("stencil-route",{exact:!0,url:ee.ChoicePage,component:"sss-super-choice-page"}),e("stencil-route",{url:ee.SlateJoin,component:"sss-slate-join-page"}),e("stencil-route",{url:ee.SlateStandardChoice,component:"sss-slate-standard-choice-page"}),e("stencil-route",{url:ee.QSuperOptIn,component:"sss-qsuper-insurance-opt-in"}),e("stencil-route",{url:ee.PromotedFundJoin,component:"sss-promoted-fund-join-page"}),e("stencil-route",{url:ee.PromotedFundStandardChoice,component:"sss-promoted-fund-standard-choice-page"}),e("stencil-route",{url:ee.QSuperQuestion1,component:"sss-qsuper-question-1"}),e("stencil-route",{url:ee.QSuperQuestion2,component:"sss-qsuper-question-2"}),e("stencil-route",{url:ee.QSuperQuestion3,component:"sss-qsuper-question-3"}),e("stencil-route",{url:ee.QSuperQuestion4,component:"sss-qsuper-question-4"}),e("stencil-route",{url:ee.QSuperQuestion5,component:"sss-qsuper-question-5"}),e("stencil-route",{url:ee.QSuperQuestion6,component:"sss-qsuper-question-6"}),e("stencil-route",{url:ee.QSuperQuestion7,component:"sss-qsuper-question-7"}),e("stencil-route",{url:ee.QSuperQuestion8,component:"sss-qsuper-question-8"}),e("stencil-route",{url:ee.QSuperConsent,component:"sss-qsuper-consent"}),e("stencil-route",{url:ee.QSuperJoin,component:"sss-qsuper-join"}),e("stencil-route",{url:ee.MyOwnFund,component:"sss-my-own-fund"}),e("stencil-route",{url:ee.SelfManagedFund,component:"sss-self-managed-fund"}),e("stencil-route",{url:ee.DefaultFund,component:"sss-default-fund"}),e("stencil-route",{url:ee.Success,component:"sss-success"})];var ie;!function(t){t.MyOwnFund="My Own Fund",t.DefaultFund="Default Fund",t.SelfManagedFund="Self Managed Fund"}(ie||(ie={}));const re={continueAllowed:!1,nextRoute:"/",myOwnFundForm:{fundUsi:U,memberNumber:U,standardChoiceFormSignature:U},defaultFundForm:{standardChoiceFormSignature:""},selfManagedFundForm:{fundName:"",fundAbn:"",fundEsa:"",addressLine1:"",addressLine2:"",state:"",postcode:"",city:"",bankAccountName:"",bsb:"",bankAccountNumber:"",standardChoiceFormSignature:""},currentCustomFundType:ie.MyOwnFund,customFunds:[{label:ie.MyOwnFund,value:ee.MyOwnFund},{label:ie.DefaultFund,value:ee.DefaultFund},{label:ie.SelfManagedFund,value:ee.SelfManagedFund}]},{state:oe}=qt(re),se=oe.customFunds,ae=class{constructor(e){t(this,e),this.currentCustomFund=se[0],this.fundOptionsList=se}componentWillLoad(){let t="";window.location.pathname.includes(ee.MyOwnFund)&&(t=ee.MyOwnFund),window.location.pathname.includes(ee.DefaultFund)&&(t=ee.DefaultFund),window.location.pathname.includes(ee.SelfManagedFund)&&(t=ee.SelfManagedFund),this.currentCustomFund=se.find((e=>e.value===t))||se[0],te.navigateInternally(this.history,t)}render(){return e("div",{class:"container"},e("div",{class:"row justify-content-center"},e("div",{class:"col col-sm-10 col-md-7"},e("p",{class:"font-weight-bold text-center"},"Choose your Super"),e("div",{class:"mb-4"},e("select",{class:"form-control",required:!0,onChange:t=>{this.handleChange(t.target.value.trim())}},this.fundOptionsList.map((t=>e("option",{value:t.value,selected:this.currentCustomFund.value===t.value},t.label))))),e("slot",null))))}handleChange(t){const e=se.find((e=>e.value===t))||{value:ee.MyOwnFund};te.navigateInternally(this.history,e.value)}static get assetsDirs(){return["assets"]}};V(ae);const ce=new class{searchFundsAsync(t,e){return Gt.getAustralianFundsAsync({type:"partialMatch",searchString:t,maxRecordCount:e})}async getFundByUsiAsync(t){const e=await Gt.getAustralianFundsAsync({type:"usiMatch",usi:t});return 1===e.length?Et.some(e[0]):Et.none}};class ue{static get Instance(){return this.instance||(this.instance=new this)}async PostAnalyticsEventAsync(t){return Jt().url("analytics-events").post(t).res()}}class le{constructor(){this.eventTrackingApi=ue.Instance}static get Instance(){return this.instance||(this.instance=new this)}async TrackFinancialProductViewedAsync(t){return this.trackEventAsync({FinancialProductViewed:t})}async TrackSuperFundPdsViewedAsync(t){return this.trackEventAsync({SuperFundPdsViewed:t})}async TrackFinancialProductAcceptedAsync(t){return this.trackEventAsync({FinancialProductAccepted:t})}async TrackFinancialProductRejectedAsync(t){return this.trackEventAsync({FinancialProductRejected:t})}async TrackSuperFundPrivacyConfirmationAcceptedAsync(t){return this.trackEventAsync({SuperFundPrivacyConfirmationAccepted:t})}async TrackPromotedSuperFundDetailViewedAsync(t){return this.trackEventAsync({SuperFundDetailViewed:{PromotedFund:t}})}async TrackMyOwnSuperFundDetailViewedAsync(t){return this.trackEventAsync({SuperFundDetailViewed:{MyOwnFund:t}})}async TrackSmsfSuperFundDetailViewedAsync(t){return this.trackEventAsync({SuperFundDetailViewed:{Smsf:t}})}async TrackDefaultSuperFundDetailViewedAsync(t){return this.trackEventAsync({SuperFundDetailViewed:{DefaultFund:t}})}async TrackSuperFundPanelViewedAsync(t){return this.trackEventAsync({SuperFundPanelViewed:t})}async trackEventAsync(t){try{await this.eventTrackingApi.PostAnalyticsEventAsync({event:t})}catch(t){return}}}const fe={items:[]},de=new class{constructor(){const{state:t}=qt(fe);this._state=t}get state(){return this._state}closeCurrent(){const t=[...this._state.items];t.shift(),this._state.items=t}clearNotifications(){this._state.items=[]}showErrorNotification(t,e){this.pushNotification(t,null!=e?e:0,"danger")}showInfoNotification(t,e){this.pushNotification(t,null!=e?e:0,"info")}showWarningNotification(t,e){this.pushNotification(t,null!=e?e:0,"warning")}showSuccessNotification(t,e){this.pushNotification(t,null!=e?e:0,"success")}pushNotification(t,e,n){const i=[...this._state.items];i.push({details:t,type:n,priority:e}),this._state.items=i.sort(((t,e)=>e.priority-t.priority))}},he=new class{async submitDefaultFundChoiceAsync(t){return Jt().url("super-choice/default").post(t).badRequest((()=>{throw new Error("Failed to process default fund join request")})).text()}async submitCustomFundChoiceAsync(t){return Jt().url("super-choice/custom-fund").post(t).badRequest((()=>{throw new Error("Failed to process custom fund join request")})).text()}async submitSelfManagedFundChoiceAsync(t){return Jt().url("super-choice/smsf").post(t).badRequest((()=>{throw new Error("Failed to process SMSF choice request")})).text()}},pe=class{constructor(e){t(this,e),this.defaultFundProductName="Loading fund...",this.eventTrackingService=le.Instance}async componentWillLoad(){const t=Zt.defaultFundUsi;if(Et.isNone(t))return;this.isDefaultFundExists=!0;const e=await ce.getFundByUsiAsync(t.value);if(Et.isNone(e))return this.isInvalidDefaultFund=!0,void de.showErrorNotification({title:"Something is not right",description:`Couldn't find information about the configured default fund (USI ${t.value})`});this.defaultFund=e.value,this.defaultFundProductName=e.value.productName}componentDidLoad(){return this.eventTrackingService.TrackDefaultSuperFundDetailViewedAsync({fundUsi:this.defaultFund.usi,fundName:this.defaultFund.productName,promotedFundsShown:Zt.promotedFunds})}render(){return e(o,{class:"d-flex flex-fill"},e("sss-custom-fund",{class:"flex-fill"},e("form",{noValidate:!0,onSubmit:t=>t.preventDefault(),class:{"was-validated":"validated"===this.formState},ref:t=>this.formElement=t},this.isDefaultFundExists?e((t=>[e("div",{class:"card p-4"},e("p",{class:"font-weight-bold"},"Default Fund"),e("p",{class:"mb-4 small"},"Almost there... all you have to do now is review the fund below, complete and sign the super choice form and save. Your application to join the fund is subject to Trustee approval."),e("p",{class:"font-weight-bold mt-3"},"Default Fund Name"),e("p",null,t.defaultFundName)),e("sss-standard-choice-form",{onStandardChoiceFormSignatureUpdated:t=>{oe.defaultFundForm=Object.assign(Object.assign({},oe.defaultFundForm),t.detail)}})]),{defaultFundName:this.defaultFundProductName}):e((()=>e("div",{class:"card p-4"},e("p",{class:"font-weight-bold"},"No Default Fund"),e("p",{class:"mb-4 small"},"It looks like your employer has not yet defined a default fund. Please contact them if you wish to choose your company's default fund."))),null)),e("div",{class:"mt-4"},e("sss-notifications-section",null)),e("div",{class:"d-flex mt-4"},e("div",{class:"flex-grow-1 w-50"},e("div",{class:"mr-2"},e("fl-button",{onClick:()=>te.navigateInternally(this.history,ee.ChoicePage),isBlockElement:!0,variant:"secondary"},e("span",null,"Back")))),e("div",{class:"flex-grow-1 w-50"},this.isDefaultFundExists&&e("div",{class:"ml-2"},e("fl-promise-button",{isBlockElement:!0,disabled:this.isInvalidDefaultFund,promiseFn:()=>this.handleSubmitForm()},e("span",null,"Save and continue")))))))}async handleSubmitForm(){this.isInvalidDefaultFund||(this.formState="validated",this.formElement.checkValidity()&&(await he.submitDefaultFundChoiceAsync(oe.defaultFundForm),Zt.markSuperSelectionAsSubmitted(),te.navigateInternally(this.history,ee.Success)))}},me=class{constructor(e){t(this,e)}render(){return e("div",{class:"container mb-sm-0"},e("div",{class:"row justify-content-center pt-3 mt-3 mb-3 border-top"},e("div",{class:"text-decoration-none"},e("p",{class:"mt-3 small text-center mb-1 text-muted"},"Powered by Flare HR"))),e("div",{class:"row justify-content-center pb-sm-0 px-3 px-sm-0 text-center"},e("p",{class:"text-muted small"},"This page contains factual information only and does not take into account your particular objectives, financial circumstances or needs. If you have questions or need help making a decision about your super fund, you should speak to a licensed financial advice provider. You should consider the relevant super fund's PDS and TMD (if applicable) in deciding whether to apply to join the super fund. Each of the advertised fund's PDS and TMD (if applicable) can be found in their advertisements above. If you are considering joining another fund you can find the PDS and TMD on the fund's website. Your employer and Flare HR do not endorse or accept responsibility for any financial product advice or services provided by the promoters or trustees of the advertised superannuation funds. Flare HR do not endorse or accept responsibility for any of their content shown about any of the advertised superannuation funds as they are merely passing on the content as provided without any changes. Flare HR do not express any opinion or make any recommendation about any of the advertised funds.")),e("div",{class:"row justify-content-end my-1 px-3 px-sm-0"},this.appVersionBadge()))}appVersionBadge(){return e("small",{style:{opacity:"0.5"},class:"text-muted"},"Powered by Flare, v","3.37.55638")}};me.style="html{scroll-behavior:smooth}img.fluid-fit{-o-object-fit:cover;object-fit:cover}.ss-footer-logo{max-width:7rem}";const ve=class{constructor(e){t(this,e)}render(){return e(o,{class:"d-flex flex-column justify-content-center align-items-center flex-grow-1"},e("h5",null,"Loading your superannuation step"),e("fl-loading-indicator",null))}},be=class{constructor(e){t(this,e),this.isNotAllInformationProvidedMessageVisible=!1,this.eventTrackingService=le.Instance}componentDidLoad(){return this.eventTrackingService.TrackMyOwnSuperFundDetailViewedAsync({promotedFundsShown:Zt.promotedFunds})}render(){return e(o,{class:"d-flex flex-fill"},e("sss-custom-fund",{class:"flex-fill"},e("form",{noValidate:!0,onSubmit:t=>t.preventDefault(),class:{"was-validated":"validated"===this.formState},ref:t=>this.formElement=t},e("div",{class:"card p-4"},e("p",{class:"font-weight-bold"},"Fund details"),e("p",{class:"text-warning mb-4 small"},"Make sure you are already a member of the fund before completing this step."),e("sss-my-own-fund-inputs",{myOwnFundForm:oe.myOwnFundForm,onFormChanged:t=>{oe.myOwnFundForm=Object.assign(Object.assign({},oe.myOwnFundForm),t.detail),this.isNotAllInformationProvidedMessageVisible=!1}})),e("sss-standard-choice-form",{onStandardChoiceFormSignatureUpdated:t=>{oe.myOwnFundForm=Object.assign(Object.assign({},oe.myOwnFundForm),{standardChoiceFormSignature:z(t.detail.standardChoiceFormSignature)})}})),e("div",{class:"mt-4"},e("sss-notifications-section",null)),this.isNotAllInformationProvidedMessageVisible&&e("div",{class:"mt-4 alert alert-danger",role:"alert"},"All fields are required to complete submission. Make sure you have selected a fund."),e("div",{class:"d-flex mt-4"},e("div",{class:"flex-grow-1 w-50"},e("div",{class:"mr-2"},e("fl-button",{onClick:()=>te.navigateInternally(this.history,ee.ChoicePage),isBlockElement:!0,variant:"secondary"},e("span",null,"Back")))),e("div",{class:"flex-grow-1 w-50"},e("div",{class:"ml-2"},e("fl-promise-button",{isBlockElement:!0,promiseFn:()=>this.handleSubmitForm()},e("span",null,"Save and continue")))))))}async handleSubmitForm(){if(this.formState="validated",!this.formElement.checkValidity())return;if(!(D(oe.myOwnFundForm.fundUsi)&&D(oe.myOwnFundForm.memberNumber)&&D(oe.myOwnFundForm.standardChoiceFormSignature)))return void(this.isNotAllInformationProvidedMessageVisible=!0);const t={fundUsi:this.getOrError(oe.myOwnFundForm.fundUsi),memberNumber:this.getOrError(oe.myOwnFundForm.memberNumber),standardChoiceFormSignature:this.getOrError(oe.myOwnFundForm.standardChoiceFormSignature)};await he.submitCustomFundChoiceAsync(t),Zt.markSuperSelectionAsSubmitted(),te.navigateInternally(this.history,ee.Success)}getOrError(t){return jt.pipe(t,(e=()=>{throw new Error("Option value is none.")},function(t){return O(t)?e():t.value}));var e}static get assetsDirs(){return["assets"]}};V(be);const ge=class{constructor(e){t(this,e),this.formChanged=n(this,"formChanged",7),this.MIN_SEARCH_STRING_LENGTH=3,this.MAX_RECORD_COUNT=10,this.searchFundsAsync=async t=>(await ce.searchFundsAsync(t,this.MAX_RECORD_COUNT)).sort(((t,e)=>t.productName.localeCompare(e.productName))).map((t=>({label:`${t.productName} (${t.usi})`,value:t.usi})))}render(){return e("div",null,e("div",{class:""},e("label",{class:"mb-2 font-weight-bold"},"Superannuation Fund Name"),e("fl-dropdown-async",{searchFunction:this.searchFundsAsync,minSearchStringLength:this.MIN_SEARCH_STRING_LENGTH,required:!0,requiredValidationMessage:"Select a fund",placeholder:`Search by name or USI (type at least ${this.MIN_SEARCH_STRING_LENGTH} characters)`,value:this.selectedOption,onValueChanged:t=>{this.selectedOption=t.detail,this.updateFundUsi(t.detail.value.toString())}}),e("div",{class:"invalid-feedback"},"Select a fund"),D(this.myOwnFundForm.fundUsi)&&e("div",null,e("label",{class:"mb-2 mt-3 font-weight-bold"},"Superannuation Fund USI"),e("p",{class:"mb-0"},this.myOwnFundForm.fundUsi.value),e("p",{class:"small mt-1"},"Please ensure this is the correct fund USI as some funds have similar names"))),e("div",{class:"mt-4"},e("label",{class:"mb-2 font-weight-bold"},"Member Number"),e("input",{placeholder:"Enter your member number",type:"text",class:"form-control",required:!0,pattern:"[A-Za-z0-9]{4,16}",name:"memberNumber",id:"memberNumber",value:(t=oe.myOwnFundForm.memberNumber,O(t)?void 0:t.value),onChange:t=>this.updateMemberNumber(t.target.value.trim())}),e("div",{class:"invalid-feedback"},"Enter a valid member number (only numbers and / or letters)")));var t}updateFundUsi(t){this.formChanged.emit({fundUsi:L(t)})}updateMemberNumber(t){this.formChanged.emit({memberNumber:L(t)})}},we=class{constructor(e){t(this,e)}disconnectedCallback(){de.clearNotifications()}render(){const{items:t}=de.state;return t.length<=0?e(o,null):e("div",{class:"alert alert-"+t[0].type,role:"alert"},e("div",{class:"d-flex"},e("p",{class:"mb-0 flex-grow-1"},e("strong",null,t[0].details.title)),e("button",{onClick:this.handleClose,type:"button",class:"close pb-1","aria-label":"Close"},e("span",{"aria-hidden":"true"},"×"))),e("p",{class:"mb-0 mt-1"},t[0].details.description))}handleClose(){de.closeCurrent()}},{state:ye}=qt({fundId:"",memberNumber:"",usi:"",standardChoiceFormSignature:""}),xe=new class{constructor(){this.hostIsLocalSuperSelection=()=>"http://localhost:7100"==window.location.origin,this.hostIsDeployed=()=>window.location.origin.endsWith("partner.flarehr.com"),this.environmentDiscriminator=()=>this.hostIsLocalSuperSelection()?"autodev-partner":window.location.hostname.toLowerCase().split(".")[0],this.promotedFundJoinAppUrl=()=>`https://${this.environmentDiscriminator()}.flarehr.com/promoted-fund-join/embed/v1.0/web`}build(t,e){if(!(null==t?void 0:t.contentDocument))return;const n=(this.hostIsLocalSuperSelection()||this.hostIsDeployed()?window.location.origin+"/super-selection/embed/v1.0/app":"https://autodev-partner.flarehr.com/super-selection/embed/v1.0/app")+"/promoted-fund-redirect.html",i=Object.assign(Object.assign({},this.getMemberData()),{partnerId:Zt.partnerIdOrDefault,accountId:Zt.accountIdOrDefault,fundId:ye.fundId,successRedirectUrl:n,cancelRedirectUrl:n,authToken:Zt.jwt}),r=n=>{const{data:i}=n;if(i)if("promoted-fund-redirect"!==i.sender){if("promoted-fund-join"===i.sender)switch(i.type){case"contentResized":t.height=i.height>0?i.height:t.height,t.width=i.width>0?i.width:t.width;break;case"pageNavigated":window.scroll(t.offsetLeft,t.offsetTop),kt(window.location.href)}}else switch(window.removeEventListener("message",r),i.type){case"success":if(i.memberNumber){ye.memberNumber=i.memberNumber,ye.usi=i.usi,te.navigateInternally(e,ee.PromotedFundStandardChoice);break}default:te.navigateInternally(e,ee.ChoicePage)}};window.addEventListener("message",r);const o=t.contentDocument;o.open();const s=o.createElement("form");let a;for(a in s.method="POST",s.target="_self",s.action=this.promotedFundJoinAppUrl(),i){const t=i[a];if(void 0!==t){const e=document.createElement("input");e.type="hidden",e.name=a,e.value=t,s.append(e)}}o.appendChild(s),o.close(),s.submit()}getMemberData(){var t,e;const n=Zt.superBuyer;return{title:n.userProfile.title,firstName:n.userProfile.firstName,middleName:n.userProfile.middleName,lastName:n.userProfile.lastName,dateOfBirth:n.userProfile.dateOfBirth,gender:n.userProfile.gender,email:n.userProfile.email,mobilePhone:n.userProfile.mobilePhone,taxFileNumber:null!==(t=n.tfn)&&void 0!==t?t:"",addressLine1:n.userProfile.address.addressLine1,addressLine2:null!==(e=n.userProfile.address.addressLine2)&&void 0!==e?e:"",city:n.userProfile.address.city,state:n.userProfile.address.state,postCode:n.userProfile.address.postcode}}},ke=class{constructor(e){t(this,e)}componentDidLoad(){xe.build(this.iframeElement,this.history)}render(){return e(o,{class:"d-flex flex-fill"},e("iframe",{width:"100%",height:window.innerHeight,style:{border:"none"},ref:t=>this.iframeElement=t}))}},Se=new class{async submitChoiceAsync(t){return Jt().url("super-choice/promoted-fund").post(t).badRequest((()=>{throw new Error("Failed to process Promoted Fund choice request")})).text()}},Ce=class{constructor(e){t(this,e)}render(){return e(o,{class:"d-flex flex-fill"},e("div",{class:"container"},e("div",{class:"row justify-content-center"},e("div",{class:"col col-sm-10 col-md-7"},e("div",null,e("div",null,"You're almost done, simply sign the Standard Choice Form below to finalise your superannuation choice."),e("form",{noValidate:!0,onSubmit:t=>t.preventDefault(),class:{"was-validated":"validated"===this.formState},ref:t=>this.formElement=t},e("sss-standard-choice-form",{onStandardChoiceFormSignatureUpdated:t=>{ye.standardChoiceFormSignature=t.detail.standardChoiceFormSignature}})),e("div",{class:"d-flex mt-4"},e("div",{class:"flex-grow-1 w-50"},e("div",{class:"ml-2"},e("fl-promise-button",{isBlockElement:!0,promiseFn:()=>this.handleSubmitForm()},e("span",null,"Save and continue"))))))))))}async handleSubmitForm(){this.formState="validated",this.formElement.checkValidity()&&(await Se.submitChoiceAsync(Object.assign(Object.assign({},ye),{shownFunds:Zt.promotedFunds})),Zt.markSuperSelectionAsSubmitted(),te.navigateInternally(this.history,ee.Success))}},_e="60905115063001",Ae="https://qsuper.qld.gov.au/calculators-and-forms/publications/product-disclosure-statements",qe="https://slate.co/pds/?utm_source=flare&utm_medium=superselection",Be="https://www.australianretirementtrust.com.au/library/media/pdfs/pds/super-savings-product-disclosure-statement-and-membership-form.pdf",je="https://aware.com.au/member/forms-and-resources/pds",Ee=[{dtoPropName:"qSuper",id:"qsuper"},{dtoPropName:"slate",id:"slate"},{dtoPropName:"australianRetirementTrust",id:"australian-retirement-trust"},{dtoPropName:"aware",id:"aware"}],Ie=class{constructor(e){t(this,e),this.eventTrackingService=le.Instance}render(){return e("div",{class:"d-flex align-items-center justify-content-center"},e("p",{class:"confirm-title font-weight-bold text-center"},"You are now applying for a"," ",e("a",{target:"_blank",href:te.toExternalUrl("https://qsuper.qld.gov.au/-/media/pdfs/qsuper-public/publications/pds1.pdf")},"QSuper Accumulation Account"),". Read the"," ",e("a",{target:"_blank",onClick:()=>this.pdsViewedAsync(),href:te.toExternalUrl("https://qsuper.qld.gov.au/-/media/pdfs/qsuper-public/publications/pds11.pdf")},"PDS")," ","here."))}pdsViewedAsync(){return this.eventTrackingService.TrackSuperFundPdsViewedAsync({fundUsi:_e,fundName:"QSuper",pageName:"Insurance Opt In"})}static get assetsDirs(){return["assets"]}};var Fe,Pe;Ie.style="",function(t){t[t.InsuranceConfirm=0]="InsuranceConfirm",t[t.InsuranceQuestions=1]="InsuranceQuestions",t[t.AccumulationAccount=2]="AccumulationAccount",t[t.ConfirmSelection=3]="ConfirmSelection"}(Fe||(Fe={})),function(t){t[t.question1=0]="question1",t[t.question2=1]="question2",t[t.question3=2]="question3",t[t.question4=3]="question4",t[t.question5=4]="question5",t[t.question6=5]="question6",t[t.question7=6]="question7",t[t.question8=7]="question8"}(Pe||(Pe={}));const Re={currentQSuperInsuranceQuestion:Pe.question1,currentQSuperFormPage:Fe.InsuranceConfirm,qSuperFormValid:!1,nextRoute:"/",continueAllowed:!1,qSuperOptInPageCheckbox:!1,qSuperJoinPageCheckbox:!1,qSuperInsuranceQuestions:{question1:{answered:!1},question2:{answered:!1},question3:{answered:!1},question4:{answered:!1},question5:{answered:!1},question6:{answered:!1},question7:{answered:!1},question8:{answered:!1}},qSuperQuestionnaire:{reviewedApplication:!1,acceptedDeclaration:!1,readDutyOfDisclosure:!1,insuranceChosen:!1},standardChoiceFormSignature:""},{state:Me,reset:Te}=qt(Re),Ne=Te;function De(){var t,e,n,i;const r=window.location.pathname.split(Zt.appBaseUrl)[1],o={[ee.QSuperOptIn]:ee.QSuperQuestion1,[ee.QSuperQuestion1]:Me.qSuperInsuranceQuestions.question1.answered?!0===(null===(t=Me.qSuperQuestionnaire.questions)||void 0===t?void 0:t.question1)?ee.QSuperQuestion4:ee.QSuperQuestion2:ee.QSuperQuestion1,[ee.QSuperQuestion2]:Me.qSuperInsuranceQuestions.question2.answered?!0===(null===(e=Me.qSuperQuestionnaire.questions)||void 0===e?void 0:e.question2)?ee.QSuperQuestion4:ee.QSuperQuestion3:ee.QSuperQuestion2,[ee.QSuperQuestion3]:Me.qSuperInsuranceQuestions.question3.answered?ee.QSuperQuestion4:ee.QSuperQuestion3,[ee.QSuperQuestion4]:Me.qSuperInsuranceQuestions.question4.answered?ee.QSuperQuestion5:ee.QSuperQuestion4,[ee.QSuperQuestion5]:Me.qSuperInsuranceQuestions.question5.answered?ee.QSuperQuestion6:ee.QSuperQuestion5,[ee.QSuperQuestion6]:Me.qSuperInsuranceQuestions.question6.answered?ee.QSuperQuestion7:ee.QSuperQuestion6,[ee.QSuperQuestion7]:Me.qSuperInsuranceQuestions.question7.answered?ee.QSuperQuestion8:ee.QSuperQuestion7,[ee.QSuperQuestion8]:Me.qSuperInsuranceQuestions.question8.answered?ee.QSuperConsent:ee.QSuperQuestion8,[ee.QSuperConsent]:Me.qSuperQuestionnaire.readDutyOfDisclosure&&Me.qSuperQuestionnaire.reviewedApplication?ee.QSuperJoin:ee.QSuperConsent,[ee.QSuperJoin]:Me.qSuperJoinPageCheckbox?ee.Success:ee.QSuperJoin};return r===ee.QSuperQuestion5?Me.qSuperInsuranceQuestions.question1.answered&&Me.qSuperInsuranceQuestions.question2.answered&&Me.qSuperInsuranceQuestions.question3.answered&&Me.qSuperInsuranceQuestions.question4.answered&&Me.qSuperInsuranceQuestions.question5.answered&&(!0===(null===(n=Me.qSuperQuestionnaire.questions)||void 0===n?void 0:n.question3)||!0===(null===(i=Me.qSuperQuestionnaire.questions)||void 0===i?void 0:i.question5))?ee.QSuperQuestion6:ee.QSuperConsent:r===ee.QSuperOptIn?Me.qSuperOptInPageCheckbox?Me.qSuperQuestionnaire.insuranceChosen?ee.QSuperQuestion1:ee.QSuperConsent:r:o[r]}const Oe=class{constructor(e){t(this,e),this.eventTrackingService=le.Instance}async componentDidLoad(){window.scroll(0,0),Me.currentQSuperFormPage=Fe.AccumulationAccount}render(){return e("sss-qsuper-layout",null,e("div",{class:"d-flex align-items-center justify-content-center"},e("p",{class:"confirm-title font-weight-bold text-center"},"Your QSuper Accumulation Account")),e("div",{class:"p-3 d-flex mt-4 checkbox-container"},e("p",null,"Just finally, we need you to confirm that you understand the declarations below and the product you've applied for by ticking the box below.",e("br",null),e("br",null),"This form and all products are issued by the QSuper Board (ABN 32 125 059 006 AFSL 489650) as trustee for QSuper (ABN 60 905 115 063).",e("br",null),e("br",null),"I have read and agree to the terms and conditions in the QSuper"," ",e("a",{target:"_blank",onClick:()=>this.pdsViewedAsync(),href:te.toExternalUrl("https://qsuper.qld.gov.au/-/media/pdfs/qsuper-public/publications/pds11.pdf")},"Product Disclosure Statement for Accumulation and Income Accounts"),", QSuper's"," ",e("a",{target:"_blank",href:te.toExternalUrl("https://qsuper.qld.gov.au/-/media/pdfs/qsuper-public/publications/fs15.pdf")},"Your Privacy factsheet"),", and the"," ",e("a",{target:"_blank",href:te.toExternalUrl("https://qsuper.qld.gov.au/-/media/pdfs/qsuper-public/publications/qiib09.pdf")},"Financial Services Guide"),".",e("br",null),e("br",null),"I understand that any insurance cover I might have as a result of this application, commences when the first contribution is received into my account. Once I am a member I can cancel, or, subject to eligibility conditions, vary, my cover at any time. Premiums are deducted in accordance with the PDS.",e("br",null),e("br",null),"I also agree to be bound by the Trust Deed and the governing rules of QSuper in relation to the operation of my Accumulation account.",e("br",null),e("br",null),"I confirm that the information I have given is true and correct.",e("br",null),e("br",null),"I confirm that I am the person identified as the applicant in this form.",e("br",null),e("br",null),"I consent to the QSuper Board paying Simple Financial Choices Pty Ltd, a wholly owned subsidiary of Flare, a fee of $300 on receipt of the first contribution into my account, for the provision of technology services.",e("br",null),e("br",null),"I understand that I will be placed into the default investment option QSuper Lifetime.",e("br",null),e("br",null),"I understand that my Tax File Number will be provided to QSuper. NB - if you have your Tax File Number available, this will help speed up the processing of this application and we may be able to Find your Super.",e("br",null),e("br",null),"I have read and accept the"," ",e("a",{target:"_blank",href:te.toExternalUrl("https://qsuper.qld.gov.au/misc/tfn")},"Privacy and Contact Information Statement"))),e("div",null,e("label",{class:"d-flex mt-3 p-3 checkbox-container",htmlFor:"ackAllCheckBox"},e("div",{class:"w-auto px-2 fl-checkbox-container"},e("input",{id:"ackAllCheckBox",class:"confirm-checkbox-item",type:"checkbox",onChange:()=>this.handleCheckboxToggle()})),e("div",{class:"pl-3"},e("p",{class:"confirm-item-text mb-0 mt-1"},"I acknowledge all of the above. ",e("i",null,"(required)"))))))}handleCheckboxToggle(){Me.qSuperQuestionnaire.readDutyOfDisclosure=!Me.qSuperQuestionnaire.readDutyOfDisclosure,Me.qSuperQuestionnaire.reviewedApplication=!Me.qSuperQuestionnaire.reviewedApplication,Me.continueAllowed=!Me.continueAllowed,Me.nextRoute=De()}pdsViewedAsync(){return this.eventTrackingService.TrackSuperFundPdsViewedAsync({fundUsi:_e,fundName:"QSuper",pageName:"Accumulation Page"})}};function Ue(){const t=window.location.pathname.split(Zt.appBaseUrl)[1];Me.continueAllowed={[ee.QSuperOptIn]:Me.qSuperOptInPageCheckbox,[ee.QSuperJoin]:Me.qSuperJoinPageCheckbox&&Me.standardChoiceFormSignature}[t]}function Le(){Ne(),Me.qSuperQuestionnaire=Object.assign(Object.assign({},Me.qSuperQuestionnaire),{acceptedDeclaration:!1,insuranceChosen:!1,readDutyOfDisclosure:!1,reviewedApplication:!1}),Me.qSuperInsuranceQuestions={question1:{answered:!1},question2:{answered:!1},question3:{answered:!1},question4:{answered:!1},question5:{answered:!1},question6:{answered:!1},question7:{answered:!1},question8:{answered:!1}}}Oe.style="html{scroll-behavior:smooth}img.fluid-fit{-o-object-fit:cover;object-fit:cover}.choice-container{margin-top:0 !important;margin-bottom:0 !important}.confirm-title{font-size:20px;margin-bottom:0}.confirm-text{font-size:14px}.edit-toggle{cursor:pointer}.form-value-text{overflow-wrap:anywhere}.confirm-checkbox-item{-webkit-transform:scale(1.7);transform:scale(1.7)}.checkbox-container{border-radius:4px;background-color:#f5f4f2}.confirm-item-text{font-size:13px}.button-holder{min-width:8rem}.confirm-form-view-only-holder *{font-size:14px}";const ze=class{constructor(e){t(this,e),this.insuranceChosen=!1,this.eventTrackingService=le.Instance,this.isEligibleForInsurance=!1}componentDidLoad(){return this.eventTrackingService.TrackFinancialProductViewedAsync({fundUsi:_e,fundName:"QSuper",financialProduct:"QSuper Insurance"})}componentWillLoad(){Le(),this.ensureInsuranceEligibility()}render(){return e(o,{class:"d-flex flex-fill"},e("sss-qsuper-layout",{class:"d-flex flex-fill"},e("sss-qsuper-confirm-header",null),e("div",{class:"mt-4 p-3 checkbox-container"},e("p",null,"As part of becoming a QSuper member, you will receive death cover and total and permanent disability cover when you become eligible. ",e("br",null),e("br",null),"You will receive this cover when: ",e("br",null),e("br",null),"You are 25 years or older; ",e("br",null),"and You have had at least $6,000 in your accumulation account; ",e("br",null),"and At that time, we have received money into your account within the previous 13 months ",e("br",null),e("br",null),"Please see the Accumulation Account Insurance Guide, available on the QSuper website, for further information ",e("br",null),e("br",null),"Do you want this insurance cover?"),e("div",{class:"d-flex justify-content-between mt-4"},e("div",{class:"button-holder flex-grow-1 mr-2"},e("fl-button",{disabled:!this.isEligibleForInsurance,isBlockElement:!0,variant:this.insuranceChosen?"primary":"secondary",onClick:()=>this.handleInsuranceToggle(!0)},"Yes")),e("div",{class:"button-holder flex-grow-1 ml-2"},e("fl-button",{disabled:!this.isEligibleForInsurance,isBlockElement:!0,variant:this.insuranceChosen?"secondary":"primary",onClick:()=>this.handleInsuranceToggle(!1)},"No")))),e("div",null,e("label",{class:"d-flex mt-3 p-3 checkbox-container",htmlFor:"ackCheckBox"},e("div",{class:"w-auto px-2 fl-checkbox-container"},e("input",{id:"ackCheckBox",class:"confirm-checkbox-item",type:"checkbox",onChange:()=>this.handleCheckboxToggle()})),e("div",{class:"pl-3"},e("p",{class:"confirm-item-text mb-0"},"I acknowledge that my personal information will be shared with QSuper as part of their application process."))))))}ensureInsuranceEligibility(){Zt.superBuyer.userProfile.yearsOfAge<14||(Zt.superBuyer.userProfile.yearsOfAge<16?this.showIneligibleNotification("You may still apply for QSuper, however people under the age of 16 are not able to apply for insurance."):this.isEligibleForInsurance=!0)}showIneligibleNotification(t){de.showInfoNotification({title:"Unable to apply for Insurance",description:t})}handleInsuranceToggle(t){Me.qSuperQuestionnaire.insuranceChosen=t&&this.isEligibleForInsurance,this.insuranceChosen=Me.qSuperQuestionnaire.insuranceChosen,Me.nextRoute=De()}handleCheckboxToggle(){Me.qSuperOptInPageCheckbox=!Me.qSuperOptInPageCheckbox,Ue(),Me.nextRoute=De()}};ze.style="html{scroll-behavior:smooth}img.fluid-fit{-o-object-fit:cover;object-fit:cover}.choice-container{margin-top:0 !important;margin-bottom:0 !important}.confirm-title{font-size:20px;margin-bottom:0}.confirm-text{font-size:14px}.edit-toggle{cursor:pointer}.form-value-text{overflow-wrap:anywhere}.confirm-checkbox-item{-webkit-transform:scale(1.7);transform:scale(1.7)}.checkbox-container{border-radius:4px;background-color:#f5f4f2}.confirm-item-text{font-size:13px}.button-holder{min-width:8rem}.confirm-form-view-only-holder *{font-size:14px}";const He=class{constructor(e){t(this,e)}render(){return e(o,{class:"d-flex flex-fill"},e("sss-qsuper-layout",{class:"d-flex flex-fill"},e("sss-qsuper-confirm-header",null),e("div",{class:"p-3 mt-4 checkbox-container"},e("slot",null),e("sss-qsuper-question-yes-no-buttons",null))))}};He.style="html{scroll-behavior:smooth}img.fluid-fit{-o-object-fit:cover;object-fit:cover}.choice-container{margin-top:0 !important;margin-bottom:0 !important}.confirm-title{font-size:20px;margin-bottom:0}.confirm-text{font-size:14px}.edit-toggle{cursor:pointer}.form-value-text{overflow-wrap:anywhere}.confirm-checkbox-item{-webkit-transform:scale(1.7);transform:scale(1.7)}.checkbox-container{border-radius:4px;background-color:#f5f4f2}.confirm-item-text{font-size:13px}.button-holder{min-width:8rem}.confirm-form-view-only-holder *{font-size:14px}";const Ve=class{constructor(e){t(this,e),this.eventTrackingService=le.Instance}render(){return e("sss-qsuper-layout",null,e("img",{class:"ss-choice-logo mx-auto",alt:"Simple Financial Choices Pty Ltd",src:s("assets/logo-qsuper.png")}),e("div",{class:"row"},e("div",{class:"col text-center"},e("p",{class:"confirm-title font-weight-bold mb-0"},"You have chosen to join QSuper"))),e("div",{class:"my-3 card p-3"},e("p",{class:"confirm-text"},"We are almost there... All you have to do now is sign the super choice form. We'll prefill it for you. Make sure the info is correct. Your application to join the fund is subject to Trustee approval."),e("p",{class:"confirm-text mb-0"},"You've chosen to stay with your existing fund. Review the details below and click continue to confirm your choice")),e("div",{class:"card p-3"},e("p",{class:"text-center"},"100 years strong"),e("p",{class:"text-center"},"One of Australia's largest funds"),e("p",{class:"text-center mb-0"},"Awarded SuperRatings highest performance rating")),e("div",{class:"mt-3"},e("p",{class:"text-center confirm-text"},"Your application to join the fund is subject to Trustee approval.")),e("div",null,e("label",{class:"d-flex mt-4 p-3 checkbox-container",htmlFor:"confirmCheckBox"},e("div",{class:"w-auto px-2 py-2 fl-checkbox-container"},e("input",{id:"confirmCheckBox",class:"confirm-checkbox-item",type:"checkbox",onChange:()=>this.handleCheckboxToggle()})),e("div",{class:"pl-3"},e("p",{class:"confirm-item-text mb-0 mt-1"},"I've read and understood the"," ",e("a",{target:"_blank",onClick:()=>this.pdsViewedAsync(),href:te.toExternalUrl("https://qsuper.qld.gov.au/calculators-and-forms/publications/product-disclosure-statements/")},"PDS")," ","and confirm all information I have provided is true and correct. I understand that my information will be sent to the trustee of this fund to process my request to join and I consent to my TFN, as currently held on the Flare HR Platform, being given to the trustee in order to open and administer my account.")))),e("sss-standard-choice-form",{onStandardChoiceFormSignatureUpdated:t=>{Me.standardChoiceFormSignature=t.detail.standardChoiceFormSignature,Ue()}}))}handleCheckboxToggle(){Me.qSuperJoinPageCheckbox=!Me.qSuperJoinPageCheckbox,Ue(),Me.nextRoute=De()}pdsViewedAsync(){return this.eventTrackingService.TrackSuperFundPdsViewedAsync({fundUsi:_e,fundName:"QSuper",pageName:"Confirm Page"})}};Ve.style="html{scroll-behavior:smooth}img.fluid-fit{-o-object-fit:cover;object-fit:cover}.checkbox-container{border-radius:4px;background-color:#f5f4f2}.confirm-checkbox-item{-webkit-transform:scale(1.7);transform:scale(1.7)}.simple-choices-text{color:#489882}.choice-card{background:#ffffff;-webkit-box-shadow:0 1px 4px rgba(0, 0, 0, 0.25);box-shadow:0 1px 4px rgba(0, 0, 0, 0.25);border-radius:3px}.choice-card.ss-picked-fund{border:2px solid var(--fl-color-primary)}.card.ss-picked-fund{border:2px solid var(--fl-color-primary)}.ss-choice-logo{width:auto;max-height:70px;-o-object-fit:contain;object-fit:contain}img{width:100%;display:block}.choice-component{width:100%;position:relative}.flexible{-ms-flex-positive:1;flex-grow:1}.fund-item{margin-top:1rem}.promoted-picked-block{background-color:var(--fl-color-primary);border-bottom-right-radius:3px;left:0;top:0}@media (min-width: 992px){.bottom-half-fund-tile{height:220px}}";const Qe=new class{async submitQSuperChoiceAsync(t){return Jt().url("super-choice/qsuper").post(t).badRequest((()=>{throw new Error("Failed to process QSuper join request")})).text()}},We=class{constructor(e){t(this,e),this.isEligible=!1,this.canContinue=()=>this.isEligible&&Me.continueAllowed,this.ensureEligibility=()=>{Zt.superBuyer.userProfile.yearsOfAge<14?this.showIneligibleNotification("People under the age of 14 are not able to open accounts."):Zt.superBuyer.userProfile.yearsOfAge>70?this.showIneligibleNotification("People over the age of 70 are not able to open accounts."):this.isEligible=!0},this.showIneligibleNotification=t=>{de.showInfoNotification({title:"Unable to apply for QSuper",description:t})}}async componentWillLoad(){this.ensureEligibility(),Me.nextRoute=De()}render(){return e("div",{class:"container"},e("div",{class:"row justify-content-center"},e("div",{class:"col col-sm-10 col-md-7"},e("slot",null),e("div",{class:"mt-4"},e("sss-notifications-section",null)),e("div",{class:"d-flex mt-4"},e("div",{class:"flex-grow-1 w-50"},e("div",{class:"mr-2"},e("fl-button",{onClick:()=>te.navigateInternally(this.history,ee.ChoicePage),isBlockElement:!0,variant:"secondary"},e("span",null,"Back")))),e("div",{class:"flex-grow-1 w-50"},e("div",{class:"ml-2"},e("fl-promise-button",{isBlockElement:!0,disabled:!this.canContinue(),promiseFn:()=>this.tryAsync()},e("span",null,"Continue"))))))))}async tryAsync(){try{if(!this.canContinue())return;await async function(){if(Me.continueAllowed)if(Me.continueAllowed=!1,Me.currentQSuperFormPage===Fe.InsuranceConfirm&&Me.qSuperQuestionnaire.insuranceChosen)Me.currentQSuperFormPage=Fe.InsuranceQuestions;else if(Me.currentQSuperFormPage!==Fe.InsuranceConfirm||Me.qSuperQuestionnaire.insuranceChosen)if(Me.currentQSuperFormPage!==Fe.InsuranceQuestions){if(Me.currentQSuperFormPage===Fe.AccumulationAccount)return Me.qSuperFormValid=!1,void(Me.currentQSuperFormPage=Fe.ConfirmSelection);if(Me.currentQSuperFormPage===Fe.ConfirmSelection){Me.qSuperQuestionnaire.acceptedDeclaration=!0;const t={questionnaire:Me.qSuperQuestionnaire,standardChoiceFormSignature:Me.standardChoiceFormSignature,shownFunds:Zt.promotedFunds};await Qe.submitQSuperChoiceAsync(t),Zt.markSuperSelectionAsSubmitted()}}else Me.currentQSuperFormPage=Fe.AccumulationAccount;else Me.currentQSuperFormPage=Fe.AccumulationAccount}(),te.navigateInternally(this.history,Me.nextRoute)}catch(t){de.showErrorNotification({title:"Couldn't process your request",description:"We had an issue processing your request to join QSuper. Please try again shortly."}),Me.continueAllowed=!0}}static get assetsDirs(){return["assets"]}};V(We);const $e=class{constructor(e){t(this,e)}render(){return e(o,{class:"d-flex flex-fill"},e("sss-qsuper-insurance-questions",null,e("p",{class:"font-weight-bold"},"Question 1"),e("p",{class:" mb-0"},"Are you currently a registered or enrolled nurse or assistant in nursing who is qualified and currently practicing, or working in the retail sector, or food and beverage service?")))}},Ye=class{constructor(e){t(this,e)}render(){return e(o,{class:"d-flex flex-fill"},e("sss-qsuper-insurance-questions",null,e("p",{class:"font-weight-bold"},"Question 2"),e("p",{class:" mb-0"},"Are you currently a qualified tradesperson currently working within your area of expertise (e.g. hairdresser, chef, plumber, electrician, plasterer, carpenter or concreter), or a skilled worker with light manual duties (e.g. jeweller, building inspector, laboratory technician, foreman or office equipment technician)?")))}},Xe=class{constructor(e){t(this,e)}render(){return e(o,{class:"d-flex flex-fill"},e("sss-qsuper-insurance-questions",null,e("p",{class:"font-weight-bold"},"Question 3"),e("p",{class:" mb-0"},"Are you currently a police officer, firefighter, paramedic, or other emergency or protective services worker, including security guard or corrections officer, or a professional sportsperson, or working in a manual occupation which does not require trade specific qualifications and may be subject to accident or environment hazards (e.g. earthmover, driver, cleaner, labourer, factory worker or agricultural worker)?")))}},Je=class{constructor(e){t(this,e)}render(){return e(o,{class:"d-flex flex-fill"},e("sss-qsuper-insurance-questions",null,e("p",{class:"font-weight-bold"},"Question 4"),e("p",{class:" mb-0"},"Are the usual work activities of your job considered office based or school teaching ( meaning you spend at least 80% of your work time doing clerical, call centre, administrative or other office or classroom based activities), or are you a medical practitioner, lawyer or engineer who spends at least 80% of your work hours in an office or clinical environment?")))}},Ge=class{constructor(e){t(this,e)}render(){return e(o,{class:"d-flex flex-fill"},e("sss-qsuper-insurance-questions",null,e("p",{class:"font-weight-bold"},"Question 5"),e("p",{class:" mb-0"},"Do you currently perform, or intend to work in a job within the next three months that includes, any of the following risky activities: handling firearms (other than as a police officer, correctional officer or licensed security guard), dangerous chemicals or explosives, or offshore work – oil and gas platforms, ships at sea, or being underground (in construction and mining environments) or underwater for more than 20% of total at work time, or working at heights over 20 metres in any environment requiring hard hat and harness for safety by law, or crop dusting, aerial mustering or any low level flying activity (defined as below 150 metres or 500 feet), or flying more than 200 hours per annum as a passenger other than on a commercial airline, or as a pilot (fixed wing or helicopter)?")))}},Ke=class{constructor(e){t(this,e)}render(){return e(o,{class:"d-flex flex-fill"},e("sss-qsuper-insurance-questions",null,e("p",{class:"font-weight-bold"},"Question 6"),e("p",{class:" mb-0"},"Are you earning more than $120,000 a year, (before tax and employer paid superannuation), from your job?")))}},Ze=class{constructor(e){t(this,e)}render(){return e(o,{class:"d-flex flex-fill"},e("sss-qsuper-insurance-questions",null,e("p",{class:"font-weight-bold"},"Question 7"),e("p",{class:" mb-0"},"Do you have a university qualification which you are using/is required in your current role?")))}},tn=class{constructor(e){t(this,e)}render(){return e(o,{class:"d-flex flex-fill"},e("sss-qsuper-insurance-questions",null,e("p",{class:"font-weight-bold"},"Question 8"),e("p",{class:" mb-0"},"Do you have a senior/executive level management role in your company (your direct reports would be mid-level managers or skilled specialists in a sedentary setting), or is your role considered professional (e.g. doctor, solicitor, accountant – requiring membership of a professional or government body to practice in your occupation)?")))}},en=class{constructor(e){t(this,e)}render(){return e("div",{class:"d-flex mt-4"},e("div",{class:"flex-grow-1 w-50"},e("div",{class:"mr-2"},e("fl-button",{onClick:()=>this.handleQuestionClick(!0),isBlockElement:!0,variant:"secondary"},e("span",null,"Yes")))),e("div",{class:"flex-grow-1 w-50"},e("div",{class:"ml-2"},e("fl-promise-button",{isBlockElement:!0,variant:"secondary",onClick:()=>this.handleQuestionClick(!1)},e("span",null,"No")))))}handleQuestionClick(t){const e=window.location.pathname.split(Zt.appBaseUrl+"/qsuper/insurance/")[1].replace(/\/+$/,"");void 0===Me.qSuperQuestionnaire.questions&&(Me.qSuperQuestionnaire.questions={question1:!1,question2:!1,question3:!1,question4:!1,question5:!1,question6:!1,question7:!1,question8:!1}),Me.qSuperQuestionnaire.questions[e]=t,Me.qSuperInsuranceQuestions[e].answered=!0,Me.nextRoute=De(),te.navigateInternally(this.history,Me.nextRoute)}};V(en);const nn=class{constructor(e){t(this,e)}render(){return e(o,{class:"bg-white rounded-sm picked-box-border p-3"},e("div",{class:"d-flex"},e("div",{class:"flex-grow-1 font-weight-bold"},this.fundType),e("div",{class:"px-3 py-2 text-white picked-block position-absolute"},"You picked")),e("div",null,this.fundName))}};nn.style="html{scroll-behavior:smooth}img.fluid-fit{-o-object-fit:cover;object-fit:cover}.picked-block{background-color:var(--fl-color-primary);border-top-right-radius:3px;right:0;top:0}.picked-box-border{border:2px solid var(--fl-color-primary)}";const rn=class{constructor(e){t(this,e),this.showSmsfNotSupported=!1,this.eventTrackingService=le.Instance,this.success=()=>{Zt.markSuperSelectionAsSubmitted(),te.navigateInternally(this.history,ee.Success)}}componentDidLoad(){return this.eventTrackingService.TrackSmsfSuperFundDetailViewedAsync({promotedFundsShown:Zt.promotedFunds})}render(){return e(o,{class:"d-flex flex-fill"},e("sss-custom-fund",{class:"flex-fill"},e("form",{noValidate:!0,onSubmit:t=>t.preventDefault(),class:{"was-validated":"validated"===this.formState},ref:t=>this.formElement=t},e("div",{class:"card p-4"},e("p",{class:"font-weight-bold"},"Fund details"),e("p",{class:"text-warning mb-4 small"},"Make sure you are already a member of the fund before completing this step."),e("sss-self-managed-fund-inputs",{fundForm:oe.selfManagedFundForm,onFormChanged:t=>{oe.selfManagedFundForm=Object.assign(Object.assign({},oe.selfManagedFundForm),t.detail)}})),e("sss-standard-choice-form",{onStandardChoiceFormSignatureUpdated:t=>{oe.selfManagedFundForm=Object.assign(Object.assign({},oe.selfManagedFundForm),t.detail)}}),this.showSmsfNotSupported&&e("sss-smsf-not-supported-dialog",{ref:t=>this.notSupportedDialog=t,onContinue:this.success})),e("div",{class:"mt-4"},e("sss-notifications-section",null)),e("div",{class:"d-flex mt-4"},e("div",{class:"flex-grow-1 w-50"},e("div",{class:"mr-2"},e("fl-button",{onClick:()=>te.navigateInternally(this.history,ee.ChoicePage),isBlockElement:!0,variant:"secondary"},e("span",null,"Back")))),e("div",{class:"flex-grow-1 w-50"},e("div",{class:"ml-2"},e("fl-promise-button",{isBlockElement:!0,promiseFn:()=>this.handleSubmitForm()},e("span",null,"Save and continue")))))))}componentDidRender(){var t;this.showSmsfNotSupported&&(null===(t=this.notSupportedDialog)||void 0===t||t.scrollIntoView())}async handleSubmitForm(){if(this.formState="validated",this.formElement.checkValidity()){const t={smsfChoice:{abn:oe.selfManagedFundForm.fundAbn,fundName:oe.selfManagedFundForm.fundName,fundAddress:{addressLine1:oe.selfManagedFundForm.addressLine1,addressLine2:oe.selfManagedFundForm.addressLine2,city:oe.selfManagedFundForm.city,state:oe.selfManagedFundForm.state,postcode:oe.selfManagedFundForm.postcode},bsb:oe.selfManagedFundForm.bsb,bankAccountName:oe.selfManagedFundForm.bankAccountName,bankAccountNumber:oe.selfManagedFundForm.bankAccountNumber,electronicServiceAddress:oe.selfManagedFundForm.fundEsa},standardChoiceFormSignature:oe.selfManagedFundForm.standardChoiceFormSignature};await he.submitSelfManagedFundChoiceAsync(t),Zt.showSmsfNotSupported?this.showSmsfNotSupported=!0:this.success()}}};V(rn);const on={"01":"Australia and New Zealand Banking Group","03":"Westpac Banking Corporation",73:"Westpac Banking Corporation","06":"Commonwealth Bank of Australia",76:"Commonwealth Bank of Australia","08":"National Australia Bank",78:"National Australia Bank","09":"Reserve Bank of Australia",10:"BankSA (division of Westpac Bank)",11:"St George Bank (division of Westpac Bank)",33:"St George Bank (division of Westpac Bank)",12:"Bank of Queensland",14:"Rabobank",15:"Town & Country Bank",18:"Macquarie Bank",19:"Bank of Melbourne (division of Westpac Bank)",55:"Bank of Melbourne (division of Westpac Bank)",21:"JP Morgan Chase Bank",22:"BNP Paribas",23:"Bank of America",24:"Citibank & Citibank NA",510:"Citibank & Citibank NA",25:"BNP Paribas Securities",26:"Bankers Trust Australia (division of Westpac Bank)",29:"MUFG Bank",30:"Bankwest (division of Commonwealth Bank)",31:"Bank Australia",325:"Beyond Bank",34:"HSBC Bank Australia",985:"HSBC Bank Australia",35:"Bank of China",980:"Bank of China",40:"Commonwealth Bank of Australia",41:"Deutsche Bank",42:"Commonwealth Bank of Australia",52:"Commonwealth Bank of Australia",45:"OCBC Bank",46:"Advance Bank (division of Westpac Bank)",47:"Challenge Bank (division of Westpac Bank)",48:"Suncorp-Metway",664:"Suncorp-Metway",512:"Community First Credit Union",514:"RACQ Bank",517:"Volt Bank",533:"Bananacoast Community Credit Union",57:"Australian Settlements",61:"Adelaide Bank (division of Bendigo and Adelaide Bank)",611:"Endeavour Mutual Bank",823:"Endeavour Mutual Bank",630:"Greater Bank",637:"Greater Bank",632:"B&E",633:"Bendigo Bank",634:"Uniting Financial Services",638:"Heritage Bank",880:"Heritage Bank",639:"Home Building Society (division of Bank of Queensland)",640:"Hume Bank",641:"IMB",647:"IMB",642:"Australian Military Bank",645:"Auswide Bank",656:"Auswide Bank",646:"Maitland Mutual Building Society",650:"Newcastle Permanent Building Society",653:"Pioneer Permanent Building Society (division of Bank of Queensland)",654:"Queensland Country Credit Union",655:"The Rock",659:"G&C Mutual Bank",676:"Gateway Bank",70:"Indue",721:"Holiday Coast Credit Union",722:"Southern Cross Credit Union",723:"Bank of Heritage Isle",724:"MOVE",728:"Summerland Credit Union",777:"Police & Nurse",80:"Cuscal",670:"Cuscal",812:"Teachers Mutual Bank",813:"Capricornian",814:"Credit Union Australia",815:"Police Bank",817:"Warwick Credit Union",818:"Bank of Communications",819:"Industrial & Commercial Bank of China",824:"Sutherland Credit Union",825:"Big Sky Building Society",833:"Defence Bank",882:"Unity Bank",888:"China Construction Bank",90:"Australia Post",911:"Sumitomo Mitsui Banking Corporation",913:"State Street Bank & Trust Company",917:"Arab Bank Australia",918:"Mizuho Bank",922:"United Overseas Bank",923:"ING Bank",936:"ING Bank",931:"Mega International Commercial Bank",932:"Regional Australia Bank",939:"AMP Bank",941:"Delphi Bank (division of Bendigo and Adelaide Bank)",942:"Bank of Sydney",943:"Taiwan Business Bank",944:"Members Equity Bank",946:"UBS AG",951:"BOQ Specialist",969:"Tyro Payments"},sn=class{constructor(e){t(this,e),this.formChanged=n(this,"formChanged",7),this.currentBank=U,this.stateOptions=[{value:"NSW",label:"NSW"},{value:"QLD",label:"QLD"},{value:"ACT",label:"ACT"},{value:"VIC",label:"VIC"},{value:"TAS",label:"TAS"},{value:"WA",label:"WA"},{value:"SA",label:"SA"},{value:"NT",label:"NT"}],this.bsbRegex=new RegExp(/^[0-9]{3}[0-9]{3}$/),this.bankAccountNumberRegex=new RegExp(/^[0-9]{2,10}$/)}render(){return e("div",null,e("div",{class:"mt-4"},e("label",{class:"mb-2 font-weight-bold"},"Fund name *"),e("input",{placeholder:"Enter your fund name",type:"text",class:"form-control",required:!0,minlength:"2",name:"fundName",id:"fundName",value:oe.selfManagedFundForm.fundName,onChange:t=>this.updateFormField("fundName",t.target.value.trim())}),e("div",{class:"invalid-feedback"},"Enter a valid fund name")),e("div",{class:"mt-4"},e("label",{class:"mb-2 font-weight-bold"},"Fund ABN *"),e("input",{placeholder:"Enter your fund ABN",type:"text",class:"form-control",required:!0,minlength:"2",name:"fundAbn",id:"fundAbn",value:oe.selfManagedFundForm.fundAbn,onChange:t=>this.updateFormField("fundAbn",t.target.value.trim())}),e("div",{class:"invalid-feedback"},"Enter a valid fund ABN")),e("div",{class:"mt-4"},e("label",{class:"mb-2 font-weight-bold"},"Electronic service address alias (ESA) *"),e("input",{placeholder:"Enter your ESA",type:"text",class:"form-control",required:!0,minlength:"2",name:"fundEsa",id:"fundEsa",value:oe.selfManagedFundForm.fundEsa,onChange:t=>this.updateFormField("fundEsa",t.target.value.trim())}),e("div",{class:"invalid-feedback"},"Enter a valid fund ESA")),e("div",{class:"mt-4"},e("label",{class:"mb-2 font-weight-bold"},"Address line 1 *"),e("input",{placeholder:"Enter your address",type:"text",class:"form-control",required:!0,minlength:"2",name:"addressLine1",id:"addressLine1",value:oe.selfManagedFundForm.addressLine1,onChange:t=>this.updateFormField("addressLine1",t.target.value.trim())}),e("div",{class:"invalid-feedback"},"Enter a valid address")),e("div",{class:"mt-4"},e("label",{class:"mb-2 font-weight-bold"},"Address line 2 (optional)"),e("input",{placeholder:"Enter your address",type:"text",class:"form-control",name:"addressLine2",id:"addressLine2",value:oe.selfManagedFundForm.addressLine2,onChange:t=>this.updateFormField("addressLine2",t.target.value.trim())}),e("div",{class:"invalid-feedback"},"Enter a valid address")),e("div",{class:"mt-4"},e("label",{class:"mb-2 font-weight-bold"},"City/suburb *"),e("input",{placeholder:"Enter your city",type:"text",class:"form-control",name:"city",required:!0,id:"city",value:oe.selfManagedFundForm.city,onChange:t=>this.updateFormField("city",t.target.value.trim())}),e("div",{class:"invalid-feedback"},"Enter a valid city/suburb *")),e("div",{class:"mt-3"},e("label",{class:"mb-2 font-weight-bold"},"State *"),e("select",{class:"form-control",name:"state",required:!0,id:"state",onChange:t=>{this.updateFormField("state",t.target.value.trim())}},e("option",{disabled:!0,selected:!this.fundForm.state,value:""},"Select a state"),this.stateOptions.map((t=>e("option",{value:t.value,selected:this.fundForm.state===t.value},t.label)))),e("div",{class:"invalid-feedback"},"Select a state")),e("div",{class:"mt-4"},e("label",{class:"mb-2 font-weight-bold"},"Post code *"),e("input",{placeholder:"Enter your post code",type:"text",required:!0,class:"form-control",name:"postcode",minlength:"4",maxlength:"4",pattern:"[0-9]{4}",id:"postcode",value:oe.selfManagedFundForm.postcode,onChange:t=>this.updateFormField("postcode",t.target.value.trim())}),e("div",{class:"invalid-feedback"},"Enter a valid post code")),e("div",null,e("i",{class:"fas fa-check-circle"})),e("div",{class:"mt-4"},e("label",{class:"mb-2 font-weight-bold"},"BSB *"),e("input",{placeholder:"Enter your BSB",type:"text",required:!0,class:"form-control",name:"bsb",id:"bsb",minlength:"6",maxlength:"7",onKeyUp:t=>this.updateCurrentBank(t),pattern:this.bsbRegex.source,value:oe.selfManagedFundForm.bsb}),D(this.currentBank)&&e("p",{class:"mt-3"},e("strong",null,"Bank name"),e("br",null),e("span",{class:"ml-2"},this.currentBank.value)),e("div",{class:"invalid-feedback"},"Enter a valid BSB")),e("div",{class:"mt-4"},e("label",{class:"mb-2 font-weight-bold"},"Bank account name *"),e("input",{placeholder:"Enter your bank account name",type:"text",required:!0,class:"form-control",name:"bankAccountName",minlength:"2",id:"bankAccountName",value:oe.selfManagedFundForm.bankAccountName,onChange:t=>this.updateFormField("bankAccountName",t.target.value.trim())}),e("div",{class:"invalid-feedback"},"Enter a valid bank account name")),e("div",{class:"mt-4"},e("label",{class:"mb-2 font-weight-bold"},"Bank account number *"),e("input",{placeholder:"Enter your bank account number",type:"text",required:!0,class:"form-control",name:"bankAccountNumber",id:"bankAccountNumber",minlength:"2",maxlength:"11",pattern:this.bankAccountNumberRegex.source,value:oe.selfManagedFundForm.bankAccountNumber,onKeyUp:t=>this.updateCurrentBankAccountNumber(t),onChange:t=>this.updateFormField("bankAccountNumber",t.target.value.trim())}),e("div",{class:"invalid-feedback"},"Enter a valid bank account number")))}updateFormField(t,e){this.formChanged.emit({[t]:e})}filterDigits(t){return t.replace(/[^0-9]/g,"")}updateCurrentBank(t){const e=this.filterDigits(t.target.value),n=e.substring(0,2),i=e.substring(0,3),r=on[n],o=on[i];r&&(this.currentBank=L(r)),o&&(this.currentBank=L(o)),""===e&&(this.currentBank=U),this.updateFormField("bsb",e)}updateCurrentBankAccountNumber(t){const e=this.filterDigits(t.target.value);this.updateFormField("bankAccountNumber",e)}};var an;!function(t){t[t.Unauthorized=0]="Unauthorized",t[t.Authenticated=1]="Authenticated",t[t.Error=2]="Error"}(an||(an={}));class cn{}let un=class extends g{constructor(){super({authenticationState:an.Unauthorized,jwt:U,reactNativeInterop:U,iframeInterop:U,appConfiguration:U})}};un=function(t,e,n,i){var r,o=arguments.length,s=o<3?e:null===i?i=Object.getOwnPropertyDescriptor(e,n):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(t,e,n,i);else for(var a=t.length-1;a>=0;a--)(r=t[a])&&(s=(o<3?r(s):o>3?r(e,n,s):r(e,n))||s);return o>3&&s&&Object.defineProperty(e,n,s),s}([b({name:"sss-session",resettable:!0})],un);const ln=new un,fn=new class extends w{constructor(t){super(t),this.store=t}isReactNativeInteropEnabled(){return D(this.getValue().reactNativeInterop)}isIframeInteropEnabled(){return D(this.getValue().iframeInterop)}getIframeInteropMode(){const t=this.getValue().iframeInterop;if(O(t))throw Error("Failed to get iframe interop information: no data in store");if(!this.isIframeInteropEnabled())throw Error("Failed to get iframe interop information: iframe mode is disabled");return t.value}}(ln),{state:dn}=qt({slateFundForm:{memberNumber:"",standardChoiceFormSignature:"",shownFunds:[]}}),hn=new class{constructor(){this.hostIsLocalSuperSelection=()=>"http://localhost:7100"==window.location.origin,this.hostIsDeployed=()=>window.location.origin.endsWith("partner.flarehr.com"),this.skipConsolidation=()=>fn.isReactNativeInteropEnabled()?"true":"false",this.environmentDiscriminator=()=>{const t=window.location.hostname.toLowerCase().split(".")[0];switch(t){case"autodev-partner":case"test-partner":case"partner":case"sandbox-partner":return t.replace("partner","");default:return"autodev-"}},this.slateJoinAppUrl=()=>`https://${this.environmentDiscriminator()}join.slatesuper.com.au/confirm`}build(t,e){if(!(null==t?void 0:t.contentDocument))return;const n=(this.hostIsLocalSuperSelection()||this.hostIsDeployed()?window.location.origin+"/super-selection/embed/v1.0/app":"https://autodev-partner.flarehr.com/super-selection/embed/v1.0/app")+"/slate-redirect.html",i=Object.assign(Object.assign({},this.getSlateJoinMemberData()),{successRedirectUrl:n,cancelRedirectUrl:n,skipConsolidation:this.skipConsolidation(),skipInsurance:"true"});this.includeJwt()&&(i.authToken=Zt.jwt);const r=n=>{const{data:i,origin:o}=n;if(i)if("slate-redirect"!==i.sender){if("flare"===i.sender&&o.endsWith("join.slatesuper.com.au"))switch(i.type){case"contentResized":t.height=i.height>0?i.height:t.height,t.width=i.width>0?i.width:t.width}}else switch(window.removeEventListener("message",r),i.type){case"success":if(i.memberNumber){dn.slateFundForm.memberNumber=i.memberNumber,te.navigateInternally(e,ee.SlateStandardChoice);break}default:te.navigateInternally(e,ee.ChoicePage)}};window.addEventListener("message",r);const o=t.contentDocument;o.open();const s=o.createElement("form");let a;for(a in s.method="POST",s.target="_self",s.action=this.slateJoinAppUrl(),i){const t=i[a];if(void 0!==t){const e=document.createElement("input");e.type="hidden",e.name=a,e.value=t,s.append(e)}}o.appendChild(s),o.close(),s.submit()}getSlateJoinMemberData(){var t,e;const n=Zt.superBuyer;return{firstName:n.userProfile.firstName,middleName:n.userProfile.middleName,lastName:n.userProfile.lastName,dateOfBirth:n.userProfile.dateOfBirth,gender:(t=>{switch(t){case"Male":return"Male";case"Female":return"Female";case"Intersex":return"Intersex/Indeterminate";default:return"Unknown"}})(n.userProfile.gender),email:n.userProfile.email,mobilePhone:n.userProfile.mobilePhone,taxFileNumber:null!==(t=n.tfn)&&void 0!==t?t:"",addressLine1:n.userProfile.address.addressLine1,addressLine2:null!==(e=n.userProfile.address.addressLine2)&&void 0!==e?e:"",city:n.userProfile.address.city,state:n.userProfile.address.state,postCode:n.userProfile.address.postcode}}includeJwt(){return!this.slateJoinAppUrl().match(/autodev|sandbox/)}},pn=class{constructor(e){t(this,e)}componentDidLoad(){hn.build(this.iframeElement,this.history)}render(){return e(o,{class:"d-flex flex-fill"},e("iframe",{width:"100%",height:window.innerHeight,style:{border:"none"},ref:t=>this.iframeElement=t}))}},mn=new class{async submitSlateChoiceAsync(t){return Jt().url("super-choice/slate").post(t).badRequest((()=>{throw new Error("Failed to process Slate join request")})).text()}},vn=class{constructor(e){t(this,e)}render(){return e(o,{class:"d-flex flex-fill"},e("div",{class:"container"},e("div",{class:"row justify-content-center"},e("div",{class:"col col-sm-10 col-md-7"},e("sss-slatesuper-header",null),e("div",null,e("form",{noValidate:!0,onSubmit:t=>t.preventDefault(),class:{"was-validated":"validated"===this.formState},ref:t=>this.formElement=t},e("sss-standard-choice-form",{onStandardChoiceFormSignatureUpdated:t=>{dn.slateFundForm=Object.assign(Object.assign({},dn.slateFundForm),t.detail)}})),e("div",{class:"d-flex mt-4"},e("div",{class:"flex-grow-1 w-50"},e("div",{class:"mr-2"},e("stencil-route-link",{url:"/"},e("fl-button",{isBlockElement:!0,variant:"secondary"},e("span",null,"Back"))))),e("div",{class:"flex-grow-1 w-50"},e("div",{class:"ml-2"},e("fl-promise-button",{isBlockElement:!0,promiseFn:()=>this.handleSubmitForm()},e("span",null,"Save and continue"))))))))))}async handleSubmitForm(){this.formState="validated",this.formElement.checkValidity()&&(await mn.submitSlateChoiceAsync(Object.assign(Object.assign({},dn.slateFundForm),{shownFunds:Zt.promotedFunds})),Zt.markSuperSelectionAsSubmitted(),te.navigateInternally(this.history,ee.Success))}},bn=class{constructor(e){t(this,e)}render(){return e("div",{class:"d-flex"},e("div",null,e("img",{class:"ss-choice-logo img-thumbnail",alt:"Simple Financial Choices Pty Ltd",src:s("assets/logo-slate.png")})),e("div",{class:"d-flex flex-column ml-3 align-items-left"},e("p",{class:"confirm-title font-weight-bold mb-0"},"You’re almost there!"),e("p",{class:"confirm-text mb-0"},"To proceed type your name below which authorises the signing of the Standard Choice form confirming your super selection.")))}static get assetsDirs(){return["assets"]}};bn.style="";const gn=class{constructor(e){t(this,e),this.continue=n(this,"continue",7),this.standardChoiceFormUrl="/super-selection/embed/v1.0/app/assets/Superannuation_Standard_Choice_Form.pdf",this.handleContinue=()=>{this.continue.emit()}}render(){return e(o,null,e("div",{class:"overlay"}),e("div",{class:"dialog"},e("div",{class:"card p-4 mt-4 bg-light text-center"},e("div",{style:{"text-align":"center"}},e("svg",{xmlns:"http://www.w3.org/2000/svg",width:"32",height:"32",fill:"orange",viewBox:"0 0 16 16"},e("path",{d:"M8.982 1.566a1.13 1.13 0 0 0-1.96 0L.165 13.233c-.457.778.091 1.767.98 1.767h13.713c.889 0 1.438-.99.98-1.767L8.982 1.566zM8 5c.535 0 .954.462.9.995l-.35 3.507a.552.552 0 0 1-1.1 0L7.1 5.995A.905.905 0 0 1 8 5zm.002 6a1 1 0 1 1 0 2 1 1 0 0 1 0-2z"}))),e("p",{class:"small mt-4 mb-0"},"You’ve selected a self-managed super fund (SMSF). Currently, SMSF information can’t be sent via this form. You’ll need to provide your employer with a"," ",e("a",{target:"_blank",href:this.standardChoiceFormUrl},"standard choice form")," ","for your SMSF details."),e("div",{class:"d-flex mt-4"},e("div",{class:"w-25"}),e("div",{class:"w-50"},e("fl-button",{onClick:this.handleContinue,isBlockElement:!0,variant:"primary"},e("span",null,"Continue")))))))}};gn.style="html{scroll-behavior:smooth}img.fluid-fit{-o-object-fit:cover;object-fit:cover}.overlay{position:absolute;top:0;left:0;z-index:100;background-color:#fff;opacity:0.7;width:100%;height:100%}.dialog{z-index:101;position:relative}";const wn=class{constructor(e){t(this,e),this.standardChoiceFormSignatureUpdated=n(this,"standardChoiceFormSignatureUpdated",7),this.standardChoiceFormUrl="/super-selection/embed/v1.0/app/assets/Superannuation_Standard_Choice_Form.pdf",this.standardChoiceFormSignature=""}render(){return e("div",{class:"card p-4 mt-4 bg-light"},e("h4",{class:"small font-weight-bold"},"Superannuation Standard Choice Form"),e("p",{class:"small mt-2"},"The superannuation"," ",e("a",{target:"_blank",href:this.standardChoiceFormUrl},"standard choice form")," ","informs your employer of your choice of fund."),e("h4",{class:"small font-weight-bold"},"Type your full name below (required)"),e("input",{placeholder:"Type your full name",type:"text",class:"form-control",required:!0,minlength:"2",name:"standardChoiceFormSignature",id:"standardChoiceFormSignature",value:this.standardChoiceFormSignature,onKeyUp:t=>this.updateFormField(t.target.value.trim())}),e("div",{class:"invalid-feedback"},"Type your full name"),e("p",{class:"small mt-3 mb-0"},"Your authorisation is required for signing this form. Applying your full name in the text field above is the same as applying your written signature and is legally binding."))}updateFormField(t){this.standardChoiceFormSignatureUpdated.emit({standardChoiceFormSignature:t})}},yn=class{constructor(e){t(this,e)}render(){return e(o,{class:"d-flex flex-fill"},e("div",{class:"container mt-5"},e("div",{class:"row justify-content-center"},e("div",{class:"col col-sm-9 col-md-6"},e("div",{class:"bg-light rounded p-4"},e("div",{class:"d-flex justify-content-center"},e("div",null,e("svg",{width:"3em",height:"3em",viewBox:"0 0 16 16",class:"bi bi-check-circle-fill text-success",fill:"currentColor",xmlns:"http://www.w3.org/2000/svg"},e("path",{"fill-rule":"evenodd",d:"M16 8A8 8 0 1 1 0 8a8 8 0 0 1 16 0zm-3.97-3.03a.75.75 0 0 0-1.08.022L7.477 9.417 5.384 7.323a.75.75 0 0 0-1.06 1.06L6.97 11.03a.75.75 0 0 0 1.079-.02l3.992-4.99a.75.75 0 0 0-.01-1.05z"})))),e("div",{class:"d-flex justify-content-center"},e("p",{class:"mt-3 confirm-title text-center font-weight-bold px-5"},"Successfully updated superannuation details")),e("div",{class:"mt-2 text-center"},e("p",{class:"confirm-text mb-0"},"Your superannuation details have been updated successfully."),e("br",null),e("p",{class:"confirm-text mb-0"},"To continue with your onboarding, press ",e("strong",null,"Continue")," below."))),e("div",{class:"flex-grow-1 mt-4"},e("fl-promise-button",{isBlockElement:!0,onClick:this.handleContinueButtonClick},e("span",null,"Continue")))))))}handleContinueButtonClick(t){Zt.completeSuperSelectionFlow()}},xn=class{constructor(e){t(this,e),this.joinFundClicked=n(this,"joinFundClicked",7),this.eventTrackingService=le.Instance}render(){return e(o,{class:{"d-flex p-3 fund-item":!0,"ss-picked-fund":this.isSelected}},e("div",{class:"card-body py-0 px-0 px-xl-3"},this.isSelected&&e("div",{class:"px-3 py-2 text-white promoted-picked-block position-absolute"},"You picked"),e("div",{class:"d-flex flex-fill flex-column align-items-center"},e("div",{class:"d-flex justify-content-end w-100"},e("div",{class:"text-muted small border rounded-sm px-1 mt-n2 mr-n2 mb-1"},"Advertised")),e("img",{class:"ss-choice-logo",alt:this.name,src:s("assets/"+this.logo)}),e("p",{class:"font-weight-bold text-center mt-3 mb-0"},this.name),this.subText&&e("span",{class:"text-muted small text-center font-italic"},this.subText),e("div",{class:"mt-3"},JSON.parse(this.features).map((t=>e("p",{class:"text-center"},t.value)))))),e("div",{class:"text-center bottom-half-fund-tile"},e("div",{class:"p-3"},e("fl-button",{class:"uuid-button-continue",isBlockElement:!0,onClick:()=>this.handleFundClick()},"Choose this fund")),e("div",{class:"mb-2"},e("a",{target:"_blank",href:this.pdsLink,onClick:()=>this.pdsViewedAsync()},"View the PDS")),this.disclaimer,e("div",{class:"small text-muted"},this.abnInfo)))}handleFundClick(){return this.joinFundClicked.emit()}pdsViewedAsync(){return this.eventTrackingService.TrackSuperFundPdsViewedAsync({fundUsi:this.usi,fundName:this.name,pageName:"Panel Fund Page"})}static get assetsDirs(){return["assets"]}};xn.style="html{scroll-behavior:smooth}img.fluid-fit{-o-object-fit:cover;object-fit:cover}.checkbox-container{border-radius:4px;background-color:#f5f4f2}.confirm-checkbox-item{-webkit-transform:scale(1.7);transform:scale(1.7)}.simple-choices-text{color:#489882}.choice-card{background:#ffffff;-webkit-box-shadow:0 1px 4px rgba(0, 0, 0, 0.25);box-shadow:0 1px 4px rgba(0, 0, 0, 0.25);border-radius:3px}.choice-card.ss-picked-fund{border:2px solid var(--fl-color-primary)}.card.ss-picked-fund{border:2px solid var(--fl-color-primary)}.ss-choice-logo{width:auto;max-height:70px;-o-object-fit:contain;object-fit:contain}img{width:100%;display:block}.choice-component{width:100%;position:relative}.flexible{-ms-flex-positive:1;flex-grow:1}.fund-item{margin-top:1rem}.promoted-picked-block{background-color:var(--fl-color-primary);border-bottom-right-radius:3px;left:0;top:0}@media (min-width: 992px){.bottom-half-fund-tile{height:220px}}";const kn=new class{async GetChosenFundAsync(){var t,e;const n=null===(t=Zt.superBuyer.superChoice)||void 0===t?void 0:t.choiceDetails;if(!n)return U;if("promoted"in n){const t=Ee.find((t=>t.dtoPropName in n.promoted)),i=null!==(e=null==t?void 0:t.id)&&void 0!==e?e:"";return L({isPromoted:!0,promotedId:i})}if("smsf"in n)return L({isPromoted:!1,name:n.smsf.fundName,type:"Self Managed Fund"});if("myOwnFund"in n){const t=n.myOwnFund.usi,e=await this.getFundByUsiAsync(t);return L({isPromoted:!1,name:D(e)?e.value.productName:t,type:"My Own Fund"})}if("default"in n){const t=n.default.usi,e=await this.getFundByUsiAsync(t);return L({isPromoted:!1,name:D(e)?e.value.productName:t,type:"Default Fund"})}return U}getFundByUsiAsync(t){return ce.getFundByUsiAsync(t)}},Sn=class{constructor(e){t(this,e),this.promotedFunds=this.getPromotedFunds(),this.chosenFund=U,this.eventTrackingService=le.Instance,this.isPromotedFundSelected=t=>D(this.chosenFund)&&this.chosenFund.value.isPromoted&&this.chosenFund.value.promotedId===t}componentDidLoad(){yt();const t=this.promotedFunds.map((t=>t.fundId));this.eventTrackingService.TrackSuperFundPanelViewedAsync({promotedFundsShown:t})}async componentWillLoad(){Le(),this.chosenFund=await kn.GetChosenFundAsync()}render(){return e(o,null,e("div",{class:"container mt-0 mb-0"},e("div",{class:"row justify-content-center"},e("div",{class:"col"},e("h3",{class:"mt-3 font-weight-bold text-center mb-4"},"Choose your Super"))),e("div",{class:"row justify-content-center"},e("div",{class:"col"},e("p",{class:"text-center font-weight-bold"},"The choice of superannuation fund is an important personal financial decision. It is open to you to continue with your existing fund, or alternatively, you can select from one of the funds below or choose another fund. Flare HR is not licensed to advise you in relation to this decision and you may wish to return to this page at a later stage."),e("p",{class:"text-center"},"The content on this page and on the following pages relating to each super fund is provided by the trustee or promoter of the super fund. The super funds presented have not been selected by your employer and neither your employer or Flare HR are making any recommendation or opinion."),e("p",{class:"text-center"},"There are many super funds out there and you should consider the relevant product disclosure statement and choose one that is right for you. If you are unsure, obtain your own advice. You can choose your super fund later, if you need time to obtain advice."))),e("div",{class:"row"},e("div",{class:"col"},e("sss-notifications-section",null))),e("div",{class:"row justify-content-center mt-4"},e("div",{class:"col col-sm-10 col-md-8 col-xl-7"},e("div",{class:"row"},e("div",{class:"col"},e("div",{class:"d-flex flex-fill"},D(this.chosenFund)&&!this.chosenFund.value.isPromoted&&e("sss-selected-super-choice-section",{fundType:this.chosenFund.value.type,fundName:this.chosenFund.value.name,class:"flex-fill position-relative"})))),e("div",{class:"row mt-3 justify-content-center"},this.getPromotedFunds().map((t=>e("div",{class:"col-12 col-lg-6 d-flex"},e("sss-super-choice-item",{class:"card mb-3 mb-lg-0 mx-0 flex-grow-1",logo:t.logo,isSelected:this.isPromotedFundSelected(t.fundId),usi:t.usi,name:t.name,subText:t.subText,pdsLink:te.toExternalUrl(t.pdsLink),features:JSON.stringify(t.features),disclaimer:t.disclaimer,abnInfo:t.abnInfo,onJoinFundClicked:async()=>this.handleJoinSuperClickAsync(t)}))))),e("div",{class:"row mt-3 px-3"},e("div",{class:"col p-4 border rounded bg-light"},e("div",{class:"row"},e("div",{class:"col"},e("h5",{class:"font-weight-bold"},"Choose another super fund"),e("p",{class:"mb-1"},"Select this option if you'd like to use your current account with another super fund."),e("ul",{class:"ml-n3"},e("li",null,"If you are unsure of your current super fund details, you can find out at"," ",e("a",{target:"_blank",href:te.toExternalUrl("https://my.gov.au")},"my.gov.au")),e("li",{class:"mt-1"},"A full list of super funds can be viewed at"," ",e("a",{target:"_blank",href:te.toExternalUrl("https://www.apra.gov.au/register-of-superannuation-institutions")},"www.apra.gov.au/register-of-superannuation-institutions"))))),e("div",{class:"row"},e("div",{class:"col"},e("stencil-route-link",{url:ee.MyOwnFund},e("fl-button",{isBlockElement:!0,variant:"primary",class:"d-lg-none"},"Choose another fund"),e("div",{class:"mt-n3 d-none d-lg-flex justify-content-end align-items-end"},e("fl-button",{variant:"primary"},"Choose another fund"))))))))),e("div",{class:"row justify-content-center mt-5"},e("div",{class:"col"},e("p",{class:"text-center"},"You should be aware that, if you do choose one of these advertised funds, Flare HR and its associated entities will normally receive a fee for you doing so.")))))}allFunds(){return[{fundId:"slate",usi:"32367272075001",name:"Slate Super",logo:"logo-slate.png",route:ee.SlateJoin,pdsLink:qe,features:[{order:1,value:"A lifestage investment strategy that evolves with you"},{order:2,value:"Advanced mobile app with retirement forecast and smart features"},{order:3,value:"Member advocates at Slate to assist with your account"}],disclaimer:e("p",{class:"small text-muted"},"You should consider the"," ",e("a",{target:"_blank",href:te.toExternalUrl(qe),onClick:()=>this.pdsViewedAsync("Slate Super","32367272075001")},"Product Disclosure Statement")," ","and"," ",e("a",{target:"_blank",href:te.toExternalUrl("https://slate.co/forms-and-documents/target-market-determination/")},"Target Market Determination")," ","before deciding to invest in or apply to become a member of the fund."),abnInfo:"Diversa Trustees Limited ABN: 49 006 421 638"},{fundId:"qsuper",usi:_e,name:"QSuper",logo:"logo-qsuper-square.png",route:ee.QSuperOptIn,pdsLink:Ae,features:[{order:1,value:"100 years strong"},{order:2,value:"One of Australia's largest funds"},{order:3,value:"Awarded SuperRatings highest performance rating"}],disclaimer:e("p",{class:"small text-muted"},"You should consider the"," ",e("a",{target:"_blank",href:te.toExternalUrl(Ae),onClick:()=>this.pdsViewedAsync("QSuper",_e)},"Product Disclosure Statement")," ","before deciding to invest in or apply to become a member of this fund."),abnInfo:"QSuper Board ABN: 32 125 059 006"},{fundId:"australian-retirement-trust",name:"Australian Retirement Trust",subText:"QSuper is now part of Australian Retirement Trust. If you have an existing QSuper account, you will continue to hold that account by selecting this option.",logo:"logo-art.svg",route:ee.PromotedFundJoin,pdsLink:Be,features:[{order:1,value:"$200 billion in retirement savings"},{order:2,value:"2+ million members"},{order:3,value:"A focus on delivering strong, long‑term returns"}],disclaimer:e("p",{class:"small text-muted"},"You should consider the"," ",e("a",{target:"_blank",href:te.toExternalUrl(Be),onClick:()=>this.pdsViewedAsync("Australian Retirement Trust")},"Product Disclosure Statement")," ","before deciding to invest in or apply to become a member of this fund."),abnInfo:"Australian Retirement Trust ABN: 60 905 115 063"},{fundId:"aware",name:"Aware Super",logo:"logo-aware.svg",route:ee.PromotedFundJoin,pdsLink:je,features:[{order:1,value:"Lorem ipsum dolor sit amet"},{order:2,value:"Lorem ipsum dolor sit amet"},{order:3,value:"Lorem ipsum dolor sit amet"}],disclaimer:e("p",{class:"small text-muted"},"You should consider the"," ",e("a",{target:"_blank",href:te.toExternalUrl(je),onClick:()=>this.pdsViewedAsync("Aware Super")},"Product Disclosure Statement")," ","before deciding to invest in or apply to become a member of this fund."),abnInfo:"Aware Super Pty Ltd ABN: 53 226 460 365"}]}getPromotedFunds(){const t=[];return Zt.promotedFunds.forEach((e=>{const n=this.allFunds().find((t=>e==t.fundId));void 0!==n&&t.push(n)})),t}async handleJoinSuperClickAsync(t){const e=Zt.promotedFunds;return"slate"===t.fundId?await this.eventTrackingService.TrackPromotedSuperFundDetailViewedAsync({fundUsi:"32367272075001",fundName:"Slate Super",promotedFundId:"slate",promotedFundsShown:e}):"qsuper"===t.fundId?await this.eventTrackingService.TrackPromotedSuperFundDetailViewedAsync({fundUsi:_e,fundName:"QSuper",promotedFundId:"qsuper",promotedFundsShown:e}):"australian-retirement-trust"===t.fundId?(await this.eventTrackingService.TrackPromotedSuperFundDetailViewedAsync({fundName:"Australian Retirement Trust",promotedFundId:"australian-retirement-trust",promotedFundsShown:e}),ye.fundId=t.fundId):"aware"===t.fundId&&(await this.eventTrackingService.TrackPromotedSuperFundDetailViewedAsync({fundName:"Aware Super",promotedFundId:"aware",promotedFundsShown:e}),ye.fundId=t.fundId),te.navigateInternally(this.history,t.route)}pdsViewedAsync(t,e){return this.eventTrackingService.TrackSuperFundPdsViewedAsync({fundUsi:e,fundName:t,pageName:"Panel Fund Page"})}static get assetsDirs(){return["assets"]}};Sn.style="html{scroll-behavior:smooth}img.fluid-fit{-o-object-fit:cover;object-fit:cover}.checkbox-container{border-radius:4px;background-color:#f5f4f2}.confirm-checkbox-item{-webkit-transform:scale(1.7);transform:scale(1.7)}.simple-choices-text{color:#489882}.choice-card{background:#ffffff;-webkit-box-shadow:0 1px 4px rgba(0, 0, 0, 0.25);box-shadow:0 1px 4px rgba(0, 0, 0, 0.25);border-radius:3px}.choice-card.ss-picked-fund{border:2px solid var(--fl-color-primary)}.card.ss-picked-fund{border:2px solid var(--fl-color-primary)}.ss-choice-logo{width:auto;max-height:70px;-o-object-fit:contain;object-fit:contain}img{width:100%;display:block}.choice-component{width:100%;position:relative}.flexible{-ms-flex-positive:1;flex-grow:1}.fund-item{margin-top:1rem}.promoted-picked-block{background-color:var(--fl-color-primary);border-bottom-right-radius:3px;left:0;top:0}@media (min-width: 992px){.bottom-half-fund-tile{height:220px}}";const Cn=class{constructor(e){t(this,e),this.group=null,this.match=null,this.componentProps={},this.exact=!1,this.scrollOnNextRender=!1,this.previousMatch=null}computeMatch(t){const e=null!=this.group||null!=this.el.parentElement&&"stencil-route-switch"===this.el.parentElement.tagName.toLowerCase();if(t&&!e)return this.previousMatch=this.match,this.match=lt(t.pathname,{path:this.url,exact:this.exact,strict:!0})}async loadCompleted(){let t={};var e,n;this.history&&this.history.location.hash?t={scrollToId:this.history.location.hash.substr(1)}:this.scrollTopOffset&&(t={scrollTopOffset:this.scrollTopOffset}),"function"==typeof this.componentUpdated?this.componentUpdated(t):!this.match||(n=this.previousMatch,null==(e=this.match)&&null==n||null!=n&&e&&n&&e.path===n.path&&e.url===n.url&&st(e.params,n.params))||!this.routeViewsUpdated||this.routeViewsUpdated(t)}async componentDidUpdate(){await this.loadCompleted()}async componentDidLoad(){await this.loadCompleted()}render(){if(!this.match||!this.history)return null;const t=Object.assign({},this.componentProps,{history:this.history,match:this.match});return this.routeRender?this.routeRender(Object.assign({},t,{component:this.component})):this.component?e(this.component,Object.assign({},t)):void 0}get el(){return a(this)}static get watchers(){return{location:["computeMatch"]}}};_.injectProps(Cn,["location","history","historyType","routeViewsUpdated"]),Cn.style="stencil-route.inactive{display:none}";const _n=(t,e,n)=>n(t.confirm(e)),An=(t,e)=>{const n=t[e],i="__storage_test__";try{return n.setItem(i,i),n.removeItem(i),!0}catch(t){return t instanceof DOMException&&(22===t.code||1014===t.code||"QuotaExceededError"===t.name||"NS_ERROR_DOM_QUOTA_REACHED"===t.name)&&0!==n.length}},qn=class{constructor(e){t(this,e),this.unsubscribe=()=>{},this.activeClass="link-active",this.exact=!1,this.strict=!0,this.custom="a",this.match=null}componentWillLoad(){this.computeMatch()}computeMatch(){this.location&&(this.match=lt(this.location.pathname,{path:this.urlMatch||this.url,exact:this.exact,strict:this.strict}))}handleClick(t){var e,n,i;if(!((e=t).metaKey||e.altKey||e.ctrlKey||e.shiftKey)&&this.history&&this.url&&this.root)return t.preventDefault(),this.history.push((i=this.root,"/"==(n=this.url).charAt(0)&&"/"==i.charAt(i.length-1)?i.slice(0,i.length-1)+n:i+n))}render(){let t={class:{[this.activeClass]:null!==this.match},onClick:this.handleClick.bind(this)};return this.anchorClass&&(t.class[this.anchorClass]=!0),"a"===this.custom&&(t=Object.assign({},t,{href:this.url,title:this.anchorTitle,role:this.anchorRole,tabindex:this.anchorTabIndex,"aria-haspopup":this.ariaHaspopup,id:this.anchorId,"aria-posinset":this.ariaPosinset,"aria-setsize":this.ariaSetsize,"aria-label":this.ariaLabel})),e(this.custom,Object.assign({},t),e("slot",null))}get el(){return a(this)}static get watchers(){return{location:["computeMatch"]}}};_.injectProps(qn,["history","location","root"]);const Bn=t=>"STENCIL-ROUTE"===t.tagName,jn=class{constructor(e){t(this,e),this.group=((1e17*Math.random()).toString().match(/.{4}/g)||[]).join("-"),this.subscribers=[],this.queue=c(this,"queue")}componentWillLoad(){null!=this.location&&this.regenerateSubscribers(this.location)}async regenerateSubscribers(t){if(null==t)return;let e=-1;if(this.subscribers=Array.prototype.slice.call(this.el.children).filter(Bn).map(((n,i)=>{const r=lt(t.pathname,{path:n.url,exact:n.exact,strict:!0});return r&&-1===e&&(e=i),{el:n,match:r}})),-1===e)return;if(this.activeIndex===e)return void(this.subscribers[e].el.match=this.subscribers[e].match);this.activeIndex=e;const n=this.subscribers[this.activeIndex];this.scrollTopOffset&&(n.el.scrollTopOffset=this.scrollTopOffset),n.el.group=this.group,n.el.match=n.match,n.el.componentUpdated=t=>{this.queue.write((()=>{this.subscribers.forEach(((t,e)=>{if(t.el.componentUpdated=void 0,e===this.activeIndex)return t.el.style.display="";this.scrollTopOffset&&(t.el.scrollTopOffset=this.scrollTopOffset),t.el.group=this.group,t.el.match=null,t.el.style.display="none"}))})),this.routeViewsUpdated&&this.routeViewsUpdated(Object.assign({scrollTopOffset:this.scrollTopOffset},t))}}render(){return e("slot",null)}get el(){return a(this)}static get watchers(){return{location:["regenerateSubscribers"]}}};_.injectProps(jn,["location","routeViewsUpdated"]);const En=(t,...e)=>{t||console.warn(...e)},In=()=>{let t,e=[];return{setPrompt:e=>(En(null==t,"A history supports only one prompt at a time"),t=e,()=>{t===e&&(t=null)}),confirmTransitionTo:(e,n,i,r)=>{if(null!=t){const o="function"==typeof t?t(e,n):t;"string"==typeof o?"function"==typeof i?i(o,r):(En(!1,"A history needs a getUserConfirmation function in order to use a prompt message"),r(!0)):r(!1!==o)}else r(!0)},appendListener:t=>{let n=!0;const i=(...e)=>{n&&t(...e)};return e.push(i),()=>{n=!1,e=e.filter((t=>t!==i))}},notifyListeners:(...t)=>{e.forEach((e=>e(...t)))}}},Fn=(t,e="scrollPositions")=>{let n=new Map;const i=(e,i)=>{if(n.set(e,i),An(t,"sessionStorage")){const e=[];n.forEach(((t,n)=>{e.push([n,t])})),t.sessionStorage.setItem("scrollPositions",JSON.stringify(e))}};if(An(t,"sessionStorage")){const i=t.sessionStorage.getItem(e);n=i?new Map(JSON.parse(i)):n}return"scrollRestoration"in t.history&&(history.scrollRestoration="manual"),{set:i,get:t=>n.get(t),has:t=>n.has(t),capture:e=>{i(e,[t.scrollX,t.scrollY])}}},Pn={hashbang:{encodePath:t=>"!"===t.charAt(0)?t:"!/"+et(t),decodePath:t=>"!"===t.charAt(0)?t.substr(1):t},noslash:{encodePath:et,decodePath:tt},slash:{encodePath:tt,decodePath:tt}},Rn=(t,e)=>{const n=0==t.pathname.indexOf(e)?"/"+t.pathname.slice(e.length):t.pathname;return Object.assign({},t,{pathname:n})},Mn={browser:(t,e={})=>{let n=!1;const i=t.history,r=t.location,o=t.navigator,s=(t=>{const e=t.navigator.userAgent;return(-1===e.indexOf("Android 2.")&&-1===e.indexOf("Android 4.0")||-1===e.indexOf("Mobile Safari")||-1!==e.indexOf("Chrome")||-1!==e.indexOf("Windows Phone"))&&t.history&&"pushState"in t.history})(t),a=!(-1===o.userAgent.indexOf("Trident")),c=Fn(t),u=null!=e.forceRefresh&&e.forceRefresh,l=null!=e.getUserConfirmation?e.getUserConfirmation:_n,f=null!=e.keyLength?e.keyLength:6,d=e.basename?Z(tt(e.basename)):"",h=()=>{try{return t.history.state||{}}catch(t){return{}}},p=t=>{t=t||{};const{key:e,state:n}=t,{pathname:i,search:o,hash:s}=r;let a=i+o+s;return En(!d||G(a,d),'You are attempting to use a basename on a page whose URL path does not begin with the basename. Expected path "'+a+'" to begin with "'+d+'".'),d&&(a=K(a,d)),at(a,n,e||rt(f))},m=In(),v=t=>{c.capture(B.location.key),Object.assign(B,t),B.location.scrollPosition=c.get(B.location.key),B.length=i.length,m.notifyListeners(B.location,B.action)},b=t=>{((t,e)=>void 0===e.state&&-1===t.userAgent.indexOf("CriOS"))(o,t)||w(p(t.state))},g=()=>{w(p(h()))},w=t=>{if(n)n=!1,v();else{const e="POP";m.confirmTransitionTo(t,e,l,(n=>{n?v({action:e,location:t}):y(t)}))}},y=t=>{let e=k.indexOf(B.location.key),i=k.indexOf(t.key);-1===e&&(e=0),-1===i&&(i=0);const r=e-i;r&&(n=!0,A(r))},x=p(h());let k=[x.key],S=0,C=!1;const _=t=>d+nt(t),A=t=>{i.go(t)},q=e=>{S+=e,1===S?(t.addEventListener("popstate",b),a&&t.addEventListener("hashchange",g)):0===S&&(t.removeEventListener("popstate",b),a&&t.removeEventListener("hashchange",g))},B={length:i.length,action:"POP",location:x,createHref:_,push:(t,e)=>{En(!("object"==typeof t&&void 0!==t.state&&void 0!==e),"You should avoid providing a 2nd state argument to push when the 1st argument is a location-like object that already has state; it is ignored");const n="PUSH",o=at(t,e,rt(f),B.location);m.confirmTransitionTo(o,n,l,(t=>{if(!t)return;const e=_(o),{key:a,state:c}=o;if(s)if(i.pushState({key:a,state:c},"",e),u)r.href=e;else{const t=k.indexOf(B.location.key),e=k.slice(0,-1===t?0:t+1);e.push(o.key),k=e,v({action:n,location:o})}else En(void 0===c,"Browser history cannot push state in browsers that do not support HTML5 history"),r.href=e}))},replace:(t,e)=>{En(!("object"==typeof t&&void 0!==t.state&&void 0!==e),"You should avoid providing a 2nd state argument to replace when the 1st argument is a location-like object that already has state; it is ignored");const n="REPLACE",o=at(t,e,rt(f),B.location);m.confirmTransitionTo(o,n,l,(t=>{if(!t)return;const e=_(o),{key:a,state:c}=o;if(s)if(i.replaceState({key:a,state:c},"",e),u)r.replace(e);else{const t=k.indexOf(B.location.key);-1!==t&&(k[t]=o.key),v({action:n,location:o})}else En(void 0===c,"Browser history cannot replace state in browsers that do not support HTML5 history"),r.replace(e)}))},go:A,goBack:()=>A(-1),goForward:()=>A(1),block:(t="")=>{const e=m.setPrompt(t);return C||(q(1),C=!0),()=>(C&&(C=!1,q(-1)),e())},listen:t=>{const e=m.appendListener(t);return q(1),()=>{q(-1),e()}},win:t};return B},hash:(t,e={})=>{let n=!1,i=null,r=0,o=!1;const s=t.location,a=t.history,c=-1===t.navigator.userAgent.indexOf("Firefox"),u=null!=e.keyLength?e.keyLength:6,{getUserConfirmation:l=_n,hashType:f="slash"}=e,d=e.basename?Z(tt(e.basename)):"",{encodePath:h,decodePath:p}=Pn[f],m=()=>{const t=s.href,e=t.indexOf("#");return-1===e?"":t.substring(e+1)},v=t=>{const e=s.href.indexOf("#");s.replace(s.href.slice(0,e>=0?e:0)+"#"+t)},b=()=>{let t=p(m());return En(!d||G(t,d),'You are attempting to use a basename on a page whose URL path does not begin with the basename. Expected path "'+t+'" to begin with "'+d+'".'),d&&(t=K(t,d)),at(t,void 0,rt(u))},g=In(),w=t=>{Object.assign(j,t),j.length=a.length,g.notifyListeners(j.location,j.action)},y=()=>{const t=m(),e=h(t);if(t!==e)v(e);else{const t=b(),e=j.location;if(!n&&(r=e).pathname===(o=t).pathname&&r.search===o.search&&r.hash===o.hash&&r.key===o.key&&st(r.state,o.state))return;if(i===nt(t))return;i=null,x(t)}var r,o},x=t=>{if(n)n=!1,w();else{const e="POP";g.confirmTransitionTo(t,e,l,(n=>{n?w({action:e,location:t}):k(t)}))}},k=t=>{let e=A.lastIndexOf(nt(j.location)),i=A.lastIndexOf(nt(t));-1===e&&(e=0),-1===i&&(i=0);const r=e-i;r&&(n=!0,q(r))},S=m(),C=h(S);S!==C&&v(C);const _=b();let A=[nt(_)];const q=t=>{En(c,"Hash history go(n) causes a full page reload in this browser"),a.go(t)},B=(t,e)=>{r+=e,1===r?t.addEventListener("hashchange",y):0===r&&t.removeEventListener("hashchange",y)},j={length:a.length,action:"POP",location:_,createHref:t=>"#"+h(d+nt(t)),push:(t,e)=>{En(void 0===e,"Hash history cannot push state; it is ignored");const n="PUSH",r=at(t,void 0,rt(u),j.location);g.confirmTransitionTo(r,n,l,(t=>{if(!t)return;const e=nt(r),o=h(d+e);if(m()!==o){i=e,(t=>{s.hash=t})(o);const t=A.lastIndexOf(nt(j.location)),a=A.slice(0,-1===t?0:t+1);a.push(e),A=a,w({action:n,location:r})}else En(!1,"Hash history cannot PUSH the same path; a new entry will not be added to the history stack"),w()}))},replace:(t,e)=>{En(void 0===e,"Hash history cannot replace state; it is ignored");const n="REPLACE",r=at(t,void 0,rt(u),j.location);g.confirmTransitionTo(r,n,l,(t=>{if(!t)return;const e=nt(r),o=h(d+e);m()!==o&&(i=e,v(o));const s=A.indexOf(nt(j.location));-1!==s&&(A[s]=e),w({action:n,location:r})}))},go:q,goBack:()=>q(-1),goForward:()=>q(1),block:(e="")=>{const n=g.setPrompt(e);return o||(B(t,1),o=!0),()=>(o&&(o=!1,B(t,-1)),n())},listen:e=>{const n=g.appendListener(e);return B(t,1),()=>{B(t,-1),n()}},win:t};return j}},Tn=class{constructor(e){t(this,e),this.root="/",this.historyType="browser",this.titleSuffix="",this.routeViewsUpdated=(t={})=>{if(this.history&&t.scrollToId&&"browser"===this.historyType){const e=this.history.win.document.getElementById(t.scrollToId);if(e)return e.scrollIntoView()}this.scrollTo(t.scrollTopOffset||this.scrollTopOffset)},this.isServer=c(this,"isServer"),this.queue=c(this,"queue")}componentWillLoad(){this.history=Mn[this.historyType](this.el.ownerDocument.defaultView),this.history.listen((t=>{t=Rn(t,this.root),this.location=t})),this.location=Rn(this.history.location,this.root)}scrollTo(t){const e=this.history;if(null!=t&&!this.isServer&&e)return"POP"===e.action&&Array.isArray(e.location.scrollPosition)?this.queue.write((()=>{e&&e.location&&Array.isArray(e.location.scrollPosition)&&e.win.scrollTo(e.location.scrollPosition[0],e.location.scrollPosition[1])})):this.queue.write((()=>{e.win.scrollTo(0,t)}))}render(){if(this.location&&this.history)return e(_.Provider,{state:{historyType:this.historyType,location:this.location,titleSuffix:this.titleSuffix,root:this.root,history:this.history,routeViewsUpdated:this.routeViewsUpdated}},e("slot",null))}get el(){return a(this)}},Nn=class{constructor(e){t(this,e),this.stepSubmitSuccess=n(this,"step-completion",7),this.successPageAcknowledged=n(this,"successPageAcknowledged",5),this.initialised=n(this,"initialised",7),this.isAppInitialised=!1}async componentWillLoad(){const t=Et.fromNullable(this.accessToken);if(Et.isNone(t))throw Error("jwt property is missing.");Zt.state.jwt=t;const e=Et.fromNullable(this.backendUrl);if(Et.isNone(e))throw Error("apiBaseUrl property is missing.");Zt.state.apiBaseUrl=Et.some(e.value.replace(/\/$/,"")+"/");const n=Et.fromNullable(this.appBaseUrl);if(Et.isNone(n))throw Error("appBaseUrl property is missing.");Zt.state.appBaseUrl=Et.some(n.value.replace(/\/$/,"")),Zt.onChange("hasSuccessPageBeenAcknowledged",(()=>this.successPageAcknowledged.emit())),Zt.onChange("hasSuperSelectionBeenSubmitted",(t=>{t&&(this.stepSubmitSuccess.emit(),Zt.state.hasSuperSelectionBeenSubmitted=!1)}))}async componentDidLoad(){Le(),await Zt.loadAppStateAsync(),this.isAppInitialised=!0,this.initialised.emit({accountIdOrDefault:Zt.accountIdOrDefault,partnerIdOrDefault:Zt.partnerIdOrDefault,profileId:Zt.profileId})}authTokenChanged(t){Zt.state.jwt=Et.fromNullable(t)}onRouteChange(){null===window||void 0===window||window.scroll(0,0)}render(){return e(o,{class:"d-flex justify-content-center flex-grow-1"},e("div",{class:"d-flex flex-column justify-content-between"},this.renderAppContent()))}routerBaseUrl(){var t;return(null===(t=this.appBaseUrl)||void 0===t?void 0:t.replace(/\/$/,""))+"/"}renderAppContent(){return e("stencil-router",{root:this.routerBaseUrl()},e("stencil-route-switch",{scrollTopOffset:0},e("div",{class:"d-flex flex-column"},e("div",{class:"d-flex justify-content-center"},this.isAppInitialised?ne:e("fl-loading-indicator",{class:"mt-5"})),e("div",{class:"d-flex justify-content-center"},e("sss-footer-section",null)))))}static get watchers(){return{accessToken:["authTokenChanged"],location:["onRouteChange"]}}};V(Nn),Nn.style="html{scroll-behavior:smooth}img.fluid-fit{-o-object-fit:cover;object-fit:cover}stencil-route{display:-ms-flexbox;display:flex;-ms-flex:1 1 auto;flex:1 1 auto}stencil-route:empty{display:none}";var Dn,On=[],Un="ResizeObserver loop completed with undelivered notifications.";!function(t){t.BORDER_BOX="border-box",t.CONTENT_BOX="content-box",t.DEVICE_PIXEL_CONTENT_BOX="device-pixel-content-box"}(Dn||(Dn={}));var Ln,zn=function(t){return Object.freeze(t)},Hn=function(t,e){this.inlineSize=t,this.blockSize=e,zn(this)},Vn=function(){function t(t,e,n,i){return this.x=t,this.y=e,this.width=n,this.height=i,this.top=this.y,this.left=this.x,this.bottom=this.top+this.height,this.right=this.left+this.width,zn(this)}return t.prototype.toJSON=function(){var t=this;return{x:t.x,y:t.y,top:t.top,right:t.right,bottom:t.bottom,left:t.left,width:t.width,height:t.height}},t.fromRect=function(e){return new t(e.x,e.y,e.width,e.height)},t}(),Qn=function(t){return t instanceof SVGElement&&"getBBox"in t},Wn=function(t){if(Qn(t)){var e=t.getBBox();return!e.width&&!e.height}return!(t.offsetWidth||t.offsetHeight||t.getClientRects().length)},$n=function(t){var e,n,i=null===(n=null===(e=t)||void 0===e?void 0:e.ownerDocument)||void 0===n?void 0:n.defaultView;return!!(i&&t instanceof i.Element)},Yn="undefined"!=typeof window?window:{},Xn=new WeakMap,Jn=/auto|scroll/,Gn=/^tb|vertical/,Kn=/msie|trident/i.test(Yn.navigator&&Yn.navigator.userAgent),Zn=function(t){return parseFloat(t||"0")},ti=function(t,e,n){return void 0===t&&(t=0),void 0===e&&(e=0),void 0===n&&(n=!1),new Hn((n?e:t)||0,(n?t:e)||0)},ei=zn({devicePixelContentBoxSize:ti(),borderBoxSize:ti(),contentBoxSize:ti(),contentRect:new Vn(0,0,0,0)}),ni=function(t,e){if(void 0===e&&(e=!1),Xn.has(t)&&!e)return Xn.get(t);if(Wn(t))return Xn.set(t,ei),ei;var n=getComputedStyle(t),i=Qn(t)&&t.ownerSVGElement&&t.getBBox(),r=!Kn&&"border-box"===n.boxSizing,o=Gn.test(n.writingMode||""),s=!i&&Jn.test(n.overflowY||""),a=!i&&Jn.test(n.overflowX||""),c=i?0:Zn(n.paddingTop),u=i?0:Zn(n.paddingRight),l=i?0:Zn(n.paddingBottom),f=i?0:Zn(n.paddingLeft),d=i?0:Zn(n.borderTopWidth),h=i?0:Zn(n.borderRightWidth),p=i?0:Zn(n.borderBottomWidth),m=f+u,v=c+l,b=(i?0:Zn(n.borderLeftWidth))+h,g=d+p,w=a?t.offsetHeight-g-t.clientHeight:0,y=s?t.offsetWidth-b-t.clientWidth:0,x=r?m+b:0,k=r?v+g:0,S=i?i.width:Zn(n.width)-x-y,C=i?i.height:Zn(n.height)-k-w,_=S+m+y+b,A=C+v+w+g,q=zn({devicePixelContentBoxSize:ti(Math.round(S*devicePixelRatio),Math.round(C*devicePixelRatio),o),borderBoxSize:ti(_,A,o),contentBoxSize:ti(S,C,o),contentRect:new Vn(f,c,S,C)});return Xn.set(t,q),q},ii=function(t,e,n){var i=ni(t,n),r=i.borderBoxSize,o=i.contentBoxSize,s=i.devicePixelContentBoxSize;switch(e){case Dn.DEVICE_PIXEL_CONTENT_BOX:return s;case Dn.BORDER_BOX:return r;default:return o}},ri=function(t){var e=ni(t);this.target=t,this.contentRect=e.contentRect,this.borderBoxSize=zn([e.borderBoxSize]),this.contentBoxSize=zn([e.contentBoxSize]),this.devicePixelContentBoxSize=zn([e.devicePixelContentBoxSize])},oi=function(t){if(Wn(t))return 1/0;for(var e=0,n=t.parentNode;n;)e+=1,n=n.parentNode;return e},si=function(){var t=1/0,e=[];On.forEach((function(n){if(0!==n.activeTargets.length){var i=[];n.activeTargets.forEach((function(e){var n=new ri(e.target),r=oi(e.target);i.push(n),e.lastReportedSize=ii(e.target,e.observedBox),r<t&&(t=r)})),e.push((function(){n.callback.call(n.observer,i,n.observer)})),n.activeTargets.splice(0,n.activeTargets.length)}}));for(var n=0,i=e;n<i.length;n++)(0,i[n])();return t},ai=function(t){On.forEach((function(e){e.activeTargets.splice(0,e.activeTargets.length),e.skippedTargets.splice(0,e.skippedTargets.length),e.observationTargets.forEach((function(n){n.isActive()&&(oi(n.target)>t?e.activeTargets.push(n):e.skippedTargets.push(n))}))}))},ci=[],ui=0,li={attributes:!0,characterData:!0,childList:!0,subtree:!0},fi=["resize","load","transitionend","animationend","animationstart","animationiteration","keyup","keydown","mouseup","mousedown","mouseover","mouseout","blur","focus"],di=function(t){return void 0===t&&(t=0),Date.now()+t},hi=!1,pi=new(function(){function t(){var t=this;this.stopped=!0,this.listener=function(){return t.schedule()}}return t.prototype.run=function(t){var e=this;if(void 0===t&&(t=250),!hi){hi=!0;var n,i=di(t);n=function(){var n=!1;try{n=function(){var t,e=0;for(ai(e);On.some((function(t){return t.activeTargets.length>0}));)e=si(),ai(e);return On.some((function(t){return t.skippedTargets.length>0}))&&("function"==typeof ErrorEvent?t=new ErrorEvent("error",{message:Un}):((t=document.createEvent("Event")).initEvent("error",!1,!1),t.message=Un),window.dispatchEvent(t)),e>0}()}finally{if(hi=!1,t=i-di(),!ui)return;n?e.run(1e3):t>0?e.run(t):e.start()}},function(t){if(!Ln){var e=0,n=document.createTextNode("");new MutationObserver((function(){return ci.splice(0).forEach((function(t){return t()}))})).observe(n,{characterData:!0}),Ln=function(){n.textContent=""+(e?e--:e++)}}ci.push(t),Ln()}((function(){requestAnimationFrame(n)}))}},t.prototype.schedule=function(){this.stop(),this.run()},t.prototype.observe=function(){var t=this,e=function(){return t.observer&&t.observer.observe(document.body,li)};document.body?e():Yn.addEventListener("DOMContentLoaded",e)},t.prototype.start=function(){var t=this;this.stopped&&(this.stopped=!1,this.observer=new MutationObserver(this.listener),this.observe(),fi.forEach((function(e){return Yn.addEventListener(e,t.listener,!0)})))},t.prototype.stop=function(){var t=this;this.stopped||(this.observer&&this.observer.disconnect(),fi.forEach((function(e){return Yn.removeEventListener(e,t.listener,!0)})),this.stopped=!0)},t}()),mi=function(t){!ui&&t>0&&pi.start(),!(ui+=t)&&pi.stop()},vi=function(){function t(t,e){this.target=t,this.observedBox=e||Dn.CONTENT_BOX,this.lastReportedSize={inlineSize:0,blockSize:0}}return t.prototype.isActive=function(){var t,e=ii(this.target,this.observedBox,!0);return Qn(t=this.target)||function(t){switch(t.tagName){case"INPUT":if("image"!==t.type)break;case"VIDEO":case"AUDIO":case"EMBED":case"OBJECT":case"CANVAS":case"IFRAME":case"IMG":return!0}return!1}(t)||"inline"!==getComputedStyle(t).display||(this.lastReportedSize=e),this.lastReportedSize.inlineSize!==e.inlineSize||this.lastReportedSize.blockSize!==e.blockSize},t}(),bi=function(t,e){this.activeTargets=[],this.skippedTargets=[],this.observationTargets=[],this.observer=t,this.callback=e},gi=new WeakMap,wi=function(t,e){for(var n=0;n<t.length;n+=1)if(t[n].target===e)return n;return-1},yi=function(){function t(){}return t.connect=function(t,e){var n=new bi(t,e);gi.set(t,n)},t.observe=function(t,e,n){var i=gi.get(t),r=0===i.observationTargets.length;wi(i.observationTargets,e)<0&&(r&&On.push(i),i.observationTargets.push(new vi(e,n&&n.box)),mi(1),pi.schedule())},t.unobserve=function(t,e){var n=gi.get(t),i=wi(n.observationTargets,e);i>=0&&(1===n.observationTargets.length&&On.splice(On.indexOf(n),1),n.observationTargets.splice(i,1),mi(-1))},t.disconnect=function(t){var e=this,n=gi.get(t);n.observationTargets.slice().forEach((function(n){return e.unobserve(t,n.target)})),n.activeTargets.splice(0,n.activeTargets.length)},t}(),xi=function(){function t(t){if(0===arguments.length)throw new TypeError("Failed to construct 'ResizeObserver': 1 argument required, but only 0 present.");if("function"!=typeof t)throw new TypeError("Failed to construct 'ResizeObserver': The callback provided as parameter 1 is not a function.");yi.connect(this,t)}return t.prototype.observe=function(t,e){if(0===arguments.length)throw new TypeError("Failed to execute 'observe' on 'ResizeObserver': 1 argument required, but only 0 present.");if(!$n(t))throw new TypeError("Failed to execute 'observe' on 'ResizeObserver': parameter 1 is not of type 'Element");yi.observe(this,t,e)},t.prototype.unobserve=function(t){if(0===arguments.length)throw new TypeError("Failed to execute 'unobserve' on 'ResizeObserver': 1 argument required, but only 0 present.");if(!$n(t))throw new TypeError("Failed to execute 'unobserve' on 'ResizeObserver': parameter 1 is not of type 'Element");yi.unobserve(this,t)},t.prototype.disconnect=function(){yi.disconnect(this)},t.toString=function(){return"function ResizeObserver () { [polyfill code] }"},t}();const ki=new class{constructor(){this._appRootUrl=new H((()=>this.resolveRootUrl())),this.getAppRootUrl=()=>this._appRootUrl.value,this.getAppHostUrl=()=>`${window.location.origin}${this.getAppRootUrl()}`.replace(/\/$/,"")}async loadConfigurationAsync(){const t=await Xt(this.getAppRootUrl()+"config.json").get().json();ln.update({appConfiguration:Et.fromNullable(t)})}resolveRootUrl(){const t=Et.fromNullable(window.location.pathname.match(/^\/super-selection\/embed\/v1.0\/app/));if(Et.isNone(t))throw Error("Unsupported host URL");return t.value[0]+"/"}};function Si(){return"undefined"!=typeof globalThis&&globalThis?globalThis:"undefined"!=typeof self&&self?self:"undefined"!=typeof window&&window?window:"undefined"!=typeof global&&global?global:null}function Ci(t){var e=Object.create;if(e)return e(t);if(null==t)return{};var n=typeof t;if("object"!==n&&"function"!==n)throw new TypeError("Object prototype may only be an Object:"+t);function i(){}return i.prototype=t,new i}var _i,Ai,qi=function(t,e){return(qi=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(t,e){t.__proto__=e}||function(t,e){for(var n in e)e.hasOwnProperty(n)&&(t[n]=e[n])})(t,e)},Bi=Si()||{};Ai=function(t,e){function n(){this.constructor=t}qi(t,e),t.prototype=null===e?Ci(e):(n.prototype=e.prototype,new n)},(_i=Bi).__assign||(_i.__assign=Object.assign||function(t){for(var e,n=1,i=arguments.length;n<i;n++)for(var r in e=arguments[n])Object.prototype.hasOwnProperty.call(e,r)&&(t[r]=e[r]);return t}),_i.__extends||(_i.__extends=Ai),__assign||(__assign=Bi.__assign),__extends||(__extends=Bi.__extends);var ji=Si;function Ei(t){var e=ji();return e&&e[t]?e[t]:"window"===t&&Ii()?window:null}function Ii(){return Boolean("object"==typeof window&&window)}function Fi(){return Ii()?window:Ei("window")}function Pi(){return Boolean("object"==typeof document&&document)}function Ri(){return Pi()?document:Ei("document")}function Mi(){return Boolean("object"==typeof navigator&&navigator)?navigator:Ei("navigator")}function Ti(){return"object"==typeof location&&location?location:Ei("location")}function Ni(){return Ei("performance")}function Di(){return Boolean("object"==typeof JSON&&JSON||null!==Ei("JSON"))}function Oi(){return Di()?JSON||Ei("JSON"):null}var Ui=null,Li=!1,zi=123456789,Hi=987654321;function Vi(t){t<0&&(t>>>=0),zi=123456789+t&4294967295,Hi=987654321-t&4294967295,Li=!0}function Qi(){Vi(4294967296*Math.random()^(new Date).getTime())}function Wi(t,e){return typeof t===e}function $i(t){return Wi(t,"undefined")||void 0===t}function Yi(t){return $i(t)||null===t}function Xi(t,e){return t&&Object.prototype.hasOwnProperty.call(t,e)}function Ji(t){return Wi(t,"object")}function Gi(t){return Wi(t,"function")}function Ki(t,e,n,i){void 0===i&&(i=!1);var r=!1;if(!Yi(t))try{Yi(t.addEventListener)?Yi(t.attachEvent)||(t.attachEvent("on"+e,n),r=!0):(t.addEventListener(e,n,i),r=!0)}catch(t){}return r}function Zi(t,e,n,i){if(void 0===i&&(i=!1),!Yi(t))try{Yi(t.removeEventListener)?Yi(t.detachEvent)||t.detachEvent("on"+e,n):t.removeEventListener(e,n,i)}catch(t){}}function tr(t,e){if(t&&Ji(t))for(var n in t)Xi(t,n)&&e.call(t,n,t[n])}var er,nr=function(){function t(){}return t.isDate=function(t){return"[object Date]"===Object.prototype.toString.call(t)},t.isArray=function(t){return"[object Array]"===Object.prototype.toString.call(t)},t.isError=function(t){return"[object Error]"===Object.prototype.toString.call(t)},t.isString=function(t){return Wi(t,"string")},t.isNumber=function(t){return Wi(t,"number")},t.isBoolean=function(t){return Wi(t,"boolean")},t.disableCookies=function(){t._canUseCookies=!1},t.newGuid=function(){return"xxxxxxxx-xxxx-4xxx-yxxx-xxxxxxxxxxxx".replace(ir,(function(e){var n=0|t.randomValue(15);return("x"===e?n:3&n|8).toString(16)}))},t.toISOString=function(e){if(t.isDate(e)){var n=function(t){var e=String(t);return 1===e.length&&(e="0"+e),e};return e.getUTCFullYear()+"-"+n(e.getUTCMonth()+1)+"-"+n(e.getUTCDate())+"T"+n(e.getUTCHours())+":"+n(e.getUTCMinutes())+":"+n(e.getUTCSeconds())+"."+String((e.getUTCMilliseconds()/1e3).toFixed(3)).slice(2,5)+"Z"}},t.arrForEach=function(t,e,n){for(var i=t.length,r=0;r<i;r++)r in t&&e.call(n||t,t[r],r,t)},t.arrIndexOf=function(t,e,n){for(var i=t.length,r=n||0,o=Math.max(r>=0?r:i-Math.abs(r),0);o<i;o++)if(o in t&&t[o]===e)return o;return-1},t.arrMap=function(t,e,n){for(var i=t.length,r=n||t,o=new Array(i),s=0;s<i;s++)s in t&&(o[s]=e.call(r,t[s],t));return o},t.arrReduce=function(t,e,n){var i,r=t.length,o=0;if(arguments.length>=3)i=arguments[2];else{for(;o<r&&!(o in t);)o++;i=t[o++]}for(;o<r;)o in t&&(i=e(i,t[o],o,t)),o++;return i},t.strTrim=function(e){return t.isString(e)?e.replace(/^\s+|\s+$/g,""):e},t.objKeys=function(t){var e=!{toString:null}.propertyIsEnumerable("toString");if(!(Gi(t)||Ji(t)&&null!==t))throw new TypeError("objKeys called on non-object");var n=[];for(var i in t)Xi(t,i)&&n.push(i);if(e)for(var r=["toString","toLocaleString","valueOf","hasOwnProperty","isPrototypeOf","propertyIsEnumerable","constructor"],o=r.length,s=0;s<o;s++)Xi(t,r[s])&&n.push(r[s]);return n},t.objDefineAccessors=function(t,e,n,i){var r=Object.defineProperty;if(r)try{var o={enumerable:!0,configurable:!0};return n&&(o.get=n),i&&(o.set=i),r(t,e,o),!0}catch(t){}return!1},t.addEventHandler=function(t,e){var n=!1,i=Fi();i&&(n=Ki(i,t,e),n=Ki(i.body,t,e)||n);var r=Ri();return r&&(n=rr.Attach(r,t,e)||n),n},t.dateNow=function(){var t=Date;return t.now?t.now():(new t).getTime()},t.perfNow=function(){var e=Ni();return e&&e.now?e.now():t.dateNow()},t.newId=function(e){void 0===e&&(e=22);for(var n=t.random32()>>>0,i=0,r="";r.length<e;)i++,r+="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/".charAt(63&n),n>>>=6,5===i&&(n=(t.random32()<<2&4294967295|3&n)>>>0,i=0);return r},t.isIE=function(){if(null===Ui){var t=((Mi()||{}).userAgent||"").toLowerCase();Ui=-1!==t.indexOf("msie")||-1!==t.indexOf("trident/")}return Ui},t.randomValue=function(e){return e>0?Math.floor(t.random32()/4294967295*(e+1))>>>0:0},t.random32=function(e){var n,i=Ei("crypto")||Ei("msCrypto");return i&&i.getRandomValues?n=4294967295&i.getRandomValues(new Uint32Array(1))[0]:t.isIE()?(Li||Qi(),n=4294967295&t.mwcRandom32()):n=Math.floor(4294967296*Math.random()|0),e||(n>>>=0),n},t.mwcRandomSeed=function(t){t?Vi(t):Qi()},t.mwcRandom32=function(t){var e=((Hi=36969*(65535&Hi)+(Hi>>16)&4294967295)<<16)+(65535&(zi=18e3*(65535&zi)+(zi>>16)&4294967295))>>>0&4294967295|0;return t||(e>>>=0),e},t.generateW3CId=function(){for(var e,n=["0","1","2","3","4","5","6","7","8","9","a","b","c","d","e","f"],i="",r=0;r<4;r++)i+=n[15&(e=t.random32())]+n[e>>4&15]+n[e>>8&15]+n[e>>12&15]+n[e>>16&15]+n[e>>20&15]+n[e>>24&15]+n[e>>28&15];var o=n[8+(3&t.random32())|0];return i.substr(0,8)+i.substr(9,4)+"4"+i.substr(13,3)+o+i.substr(16,3)+i.substr(19,12)},t.isTypeof=Wi,t.isUndefined=$i,t.isNullOrUndefined=Yi,t.hasOwnProperty=Xi,t.isFunction=Gi,t.isObject=Ji,t.objCreate=Ci,t}(),ir=/[xy]/g,rr=function(){function t(){}return t.Attach=Ki,t.AttachEvent=Ki,t.Detach=Zi,t.DetachEvent=Zi,t}();!function(t){t[t.CRITICAL=1]="CRITICAL",t[t.WARNING=2]="WARNING"}(er||(er={}));var or=Object.getPrototypeOf,sr=0;
1
+ import{r as t,h as e,c as n,g as i,f as r,H as o,a as s,d as a,e as c,s as u}from"./p-082669d9.js";import{f as l,m as f,S as d,a as h,i as p,d as m,b as v,c as b,g,Q as w}from"./p-df9ce4b7.js";import{g as y,O as x,j as k,k as S,a as C}from"./p-342cee5a.js";import{A as _}from"./p-61734b66.js";function A(){}function q(t,e,n=Number.POSITIVE_INFINITY){return"function"==typeof e?i=>i.pipe(q(((n,i)=>l(t(n,i)).pipe(f(((t,r)=>e(n,t,i,r))))),n)):("number"==typeof e&&(n=e),e=>e.lift(new B(t,n)))}class B{constructor(t,e=Number.POSITIVE_INFINITY){this.project=t,this.concurrent=e}call(t,e){return e.subscribe(new j(t,this.project,this.concurrent))}}class j extends d{constructor(t,e,n=Number.POSITIVE_INFINITY){super(t),this.project=e,this.concurrent=n,this.hasCompleted=!1,this.buffer=[],this.active=0,this.index=0}_next(t){this.active<this.concurrent?this._tryNext(t):this.buffer.push(t)}_tryNext(t){let e;const n=this.index++;try{e=this.project(t,n)}catch(t){return void this.destination.error(t)}this.active++,this._innerSub(e)}_innerSub(t){const e=new h(this),n=this.destination;n.add(e);const i=p(t,e);i!==e&&n.add(i)}_complete(){this.hasCompleted=!0,0===this.active&&0===this.buffer.length&&this.destination.complete(),this.unsubscribe()}notifyNext(t){this.destination.next(t)}notifyComplete(){const t=this.buffer;this.active--,t.length>0?this._next(t.shift()):0===this.active&&this.hasCompleted&&this.destination.complete()}}function E(t,e,n,i){return k(n)&&(i=n,n=void 0),i?E(t,e,n).pipe(f((t=>y(t)?i(...t):i(t)))):new x((i=>{I(t,e,(function(t){i.next(arguments.length>1?Array.prototype.slice.call(arguments):t)}),i,n)}))}function I(t,e,n,i,r){let o;if(function(t){return t&&"function"==typeof t.addEventListener&&"function"==typeof t.removeEventListener}(t)){const i=t;t.addEventListener(e,n,r),o=()=>i.removeEventListener(e,n,r)}else if(function(t){return t&&"function"==typeof t.on&&"function"==typeof t.off}(t)){const i=t;t.on(e,n),o=()=>i.off(e,n)}else if(function(t){return t&&"function"==typeof t.addListener&&"function"==typeof t.removeListener}(t)){const i=t;t.addListener(e,n),o=()=>i.removeListener(e,n)}else{if(!t||!t.length)throw new TypeError("Invalid event target");for(let o=0,s=t.length;o<s;o++)I(t[o],e,n,i,r)}i.add(o)}class F{constructor(t,e){this.dueTime=t,this.scheduler=e}call(t,e){return e.subscribe(new P(t,this.dueTime,this.scheduler))}}class P extends C{constructor(t,e,n){super(t),this.dueTime=e,this.scheduler=n,this.debouncedSubscription=null,this.lastValue=null,this.hasValue=!1}_next(t){this.clearDebounce(),this.lastValue=t,this.hasValue=!0,this.add(this.debouncedSubscription=this.scheduler.schedule(T,this.dueTime,this))}_complete(){this.debouncedNext(),this.destination.complete()}debouncedNext(){if(this.clearDebounce(),this.hasValue){const{lastValue:t}=this;this.lastValue=null,this.hasValue=!1,this.destination.next(t)}}clearDebounce(){const t=this.debouncedSubscription;null!==t&&(this.remove(t),t.unsubscribe(),this.debouncedSubscription=null)}}function T(t){t.debouncedNext()}function M(t,e,n){return function(i){return i.lift(new R(t,e,n))}}class R{constructor(t,e,n){this.nextOrObserver=t,this.error=e,this.complete=n}call(t,e){return e.subscribe(new N(t,this.nextOrObserver,this.error,this.complete))}}class N extends C{constructor(t,e,n,i){super(t),this._tapNext=A,this._tapError=A,this._tapComplete=A,this._tapError=n||A,this._tapComplete=i||A,k(e)?(this._context=this,this._tapNext=e):e&&(this._context=e,this._tapNext=e.next||A,this._tapError=e.error||A,this._tapComplete=e.complete||A)}_next(t){try{this._tapNext.call(this._context,t)}catch(t){return void this.destination.error(t)}this.destination.next(t)}_error(t){try{this._tapError.call(this._context,t)}catch(t){return void this.destination.error(t)}this.destination.error(t)}_complete(){try{this._tapComplete.call(this._context)}catch(t){return void this.destination.error(t)}return this.destination.complete()}}var D=function(t){return"Some"===t._tag},O=function(t){return"None"===t._tag},U={_tag:"None"},L=function(t){return{_tag:"Some",value:t}};function z(t){return null==t?U:L(t)}class V{constructor(t){this.factory=t,this._value=U}get value(){if(D(this._value))return this._value.value;const t=this.factory();return this._value=L(t),t}}function H(t){_.injectProps(t,["history","location"])}const Q=new RegExp(["(\\\\.)","(?:\\:(\\w+)(?:\\(((?:\\\\.|[^\\\\()])+)\\))?|\\(((?:\\\\.|[^\\\\()])+)\\))([+*?])?"].join("|"),"g"),W=t=>t.replace(/([.+*?=^!:${}()[\]|/\\])/g,"\\$1"),$=t=>t.replace(/([=!:$/()])/g,"\\$1"),Y=t=>t&&t.sensitive?"":"i",X=(t,e,n)=>{for(var i=(n=n||{}).strict,r=!1!==n.end,o=W(n.delimiter||"/"),s=n.delimiters||"./",a=[].concat(n.endsWith||[]).map(W).concat("$").join("|"),c="",u=!1,l=0;l<t.length;l++){var f=t[l];if("string"==typeof f)c+=W(f),u=l===t.length-1&&s.indexOf(f[f.length-1])>-1;else{var d=W(f.prefix||""),h=f.repeat?"(?:"+f.pattern+")(?:"+d+"(?:"+f.pattern+"))*":f.pattern;e&&e.push(f),c+=f.optional?f.partial?d+"("+h+")?":"(?:"+d+"("+h+"))?":d+"("+h+")"}}return r?(i||(c+="(?:"+o+")?"),c+="$"===a?"$":"(?="+a+")"):(i||(c+="(?:"+o+"(?="+a+"))?"),u||(c+="(?="+o+"|"+a+")")),new RegExp("^"+c,Y(n))},J=(t,e,n)=>t instanceof RegExp?((t,e)=>{if(!e)return t;var n=t.source.match(/\((?!\?)/g);if(n)for(var i=0;i<n.length;i++)e.push({name:i,prefix:null,delimiter:null,optional:!1,repeat:!1,partial:!1,pattern:null});return t})(t,e):Array.isArray(t)?((t,e,n)=>{for(var i=[],r=0;r<t.length;r++)i.push(J(t[r],e,n).source);return new RegExp("(?:"+i.join("|")+")",Y(n))})(t,e,n):((t,e,n)=>X(((t,e)=>{for(var n,i=[],r=0,o=0,s="",a=e&&e.delimiter||"/",c=e&&e.delimiters||"./",u=!1;null!==(n=Q.exec(t));){var l=n[0],f=n[1],d=n.index;if(s+=t.slice(o,d),o=d+l.length,f)s+=f[1],u=!0;else{var h="",p=t[o],m=n[2],v=n[3],b=n[4],g=n[5];if(!u&&s.length){var w=s.length-1;c.indexOf(s[w])>-1&&(h=s[w],s=s.slice(0,w))}s&&(i.push(s),s="",u=!1);var y=h||a,x=v||b;i.push({name:m||r++,prefix:h,delimiter:y,optional:"?"===g||"*"===g,repeat:"+"===g||"*"===g,partial:""!==h&&void 0!==p&&p!==h,pattern:x?$(x):"[^"+W(y)+"]+?"})}}return(s||o<t.length)&&i.push(s+t.substr(o)),i})(t,n),e,n))(t,e,n),G=(t,e)=>new RegExp("^"+e+"(\\/|\\?|#|$)","i").test(t),K=(t,e)=>G(t,e)?t.substr(e.length):t,Z=t=>"/"===t.charAt(t.length-1)?t.slice(0,-1):t,tt=t=>"/"===t.charAt(0)?t:"/"+t,et=t=>"/"===t.charAt(0)?t.substr(1):t,nt=t=>{const{pathname:e,search:n,hash:i}=t;let r=e||"/";return n&&"?"!==n&&(r+="?"===n.charAt(0)?n:"?"+n),i&&"#"!==i&&(r+="#"===i.charAt(0)?i:"#"+i),r},it=t=>"/"===t.charAt(0),rt=t=>Math.random().toString(36).substr(2,t),ot=(t,e)=>{for(let n=e,i=n+1,r=t.length;i<r;n+=1,i+=1)t[n]=t[i];t.pop()},st=(t,e)=>{if(t===e)return!0;if(null==t||null==e)return!1;if(Array.isArray(t))return Array.isArray(e)&&t.length===e.length&&t.every(((t,n)=>st(t,e[n])));const n=typeof t;if(n!==typeof e)return!1;if("object"===n){const n=t.valueOf(),i=e.valueOf();if(n!==t||i!==e)return st(n,i);const r=Object.keys(t),o=Object.keys(e);return r.length===o.length&&r.every((n=>st(t[n],e[n])))}return!1},at=(t,e,n,i)=>{let r;"string"==typeof t?(r=(t=>{let e=t||"/",n="",i="";const r=e.indexOf("#");-1!==r&&(i=e.substr(r),e=e.substr(0,r));const o=e.indexOf("?");return-1!==o&&(n=e.substr(o),e=e.substr(0,o)),{pathname:e,search:"?"===n?"":n,hash:"#"===i?"":i,query:{},key:""}})(t),void 0!==e&&(r.state=e)):(r=Object.assign({pathname:""},t),r.search&&"?"!==r.search.charAt(0)&&(r.search="?"+r.search),r.hash&&"#"!==r.hash.charAt(0)&&(r.hash="#"+r.hash),void 0!==e&&void 0===r.state&&(r.state=e));try{r.pathname=decodeURI(r.pathname)}catch(t){throw t instanceof URIError?new URIError('Pathname "'+r.pathname+'" could not be decoded. This is likely caused by an invalid percent-encoding.'):t}var o;return r.key=n,i?r.pathname?"/"!==r.pathname.charAt(0)&&(r.pathname=((t,e="")=>{let n,i=e&&e.split("/")||[],r=0;const o=t&&t.split("/")||[],s=t&&it(t),a=e&&it(e),c=s||a;if(t&&it(t)?i=o:o.length&&(i.pop(),i=i.concat(o)),!i.length)return"/";if(i.length){const t=i[i.length-1];n="."===t||".."===t||""===t}else n=!1;for(let t=i.length;t>=0;t--){const e=i[t];"."===e?ot(i,t):".."===e?(ot(i,t),r++):r&&(ot(i,t),r--)}if(!c)for(;r--;r)i.unshift("..");!c||""===i[0]||i[0]&&it(i[0])||i.unshift("");let u=i.join("/");return n&&"/"!==u.substr(-1)&&(u+="/"),u})(r.pathname,i.pathname)):r.pathname=i.pathname:r.pathname||(r.pathname="/"),r.query=(o=r.search||"")?(/^[?#]/.test(o)?o.slice(1):o).split("&").reduce(((t,e)=>{let[n,i]=e.split("=");return t[n]=i?decodeURIComponent(i.replace(/\+/g," ")):"",t}),{}):{},r};let ct=0;const ut={},lt=(t,e={})=>{"string"==typeof e&&(e={path:e});const{path:n="/",exact:i=!1,strict:r=!1}=e,{re:o,keys:s}=((t,e)=>{const n=`${e.end}${e.strict}`,i=ut[n]||(ut[n]={}),r=JSON.stringify(t);if(i[r])return i[r];const o=[],s={re:J(t,o,e),keys:o};return ct<1e4&&(i[r]=s,ct+=1),s})(n,{end:i,strict:r}),a=o.exec(t);if(!a)return null;const[c,...u]=a,l=t===c;return i&&!l?null:{path:n,url:"/"===n&&""===c?"/":c,isExact:l,params:s.reduce(((t,e,n)=>(t[e.name]=u[n],t)),{})}},ft=class{constructor(e){t(this,e),this.isBlockElement=!1,this.disabled=!1,this.variant="primary"}render(){return e("button",{class:{"btn position-relative px-3 py-2":!0,"is-primary":"primary"===this.variant,"is-secondary":"secondary"===this.variant,"btn-block":this.isBlockElement,disabled:this.disabled},style:{"pointer-events":this.disabled?"none":"auto"},disabled:this.disabled},e("span",{class:"label"},e("slot",null)))}};ft.style=":host button,:host button:focus,:host button:active,:host button.focus,:host button.active{-webkit-box-shadow:none;box-shadow:none;border-radius:var(--fl-rounding-button) !important}:host button.disabled,:host button:disabled{opacity:1 !important;cursor:not-allowed !important;color:var(--fl-color-disabled)}:host button .label{font-weight:600 !important}:host button.is-primary{color:var(--fl-color-primary-text);background-color:var(--fl-color-primary);border:none}:host button.is-primary.disabled,:host button.is-primary:disabled{background-color:var(--fl-color-primary-disabled)}:host button.is-primary:hover:not(.disabled),:host button.is-primary:hover:not(:disabled){background-color:var(--fl-color-primary-hover)}:host button.is-primary:active:not(.disabled),:host button.is-primary:active:not(:disabled){background-color:var(--fl-color-primary-focus)}:host button.is-secondary{color:var(--fl-color-secondary-text);background-color:var(--fl-color-secondary)}:host button.is-secondary.disabled,:host button.is-secondary:disabled{background-color:var(--fl-color-secondary-disabled)}:host button.is-secondary:hover:not(.disabled),:host button.is-secondary:hover:not(:disabled){background-color:var(--fl-color-secondary-hover)}:host button.is-secondary:active:not(.disabled),:host button.is-secondary:active:not(:disabled){background-color:var(--fl-color-secondary-focus)}:host button.is-block{display:block}:host button:disabled,:host button.disabled{pointer-events:none}";var dt={compareTwoStrings:ht,findBestMatch:function(t,e){if(!function(t,e){return"string"==typeof t&&!!Array.isArray(e)&&!!e.length&&!e.find((t=>"string"!=typeof t))}(t,e))throw new Error("Bad arguments: First argument should be a string, second should be an array of strings");const n=[];let i=0;for(let r=0;r<e.length;r++){const o=e[r],s=ht(t,o);n.push({target:o,rating:s}),s>n[i].rating&&(i=r)}return{ratings:n,bestMatch:n[i],bestMatchIndex:i}}};function ht(t,e){if(t=t.replace(/\s+/g,""),e=e.replace(/\s+/g,""),!t.length&&!e.length)return 1;if(!t.length||!e.length)return 0;if(t===e)return 1;if(1===t.length&&1===e.length)return 0;if(t.length<2||e.length<2)return 0;let n=new Map;for(let e=0;e<t.length-1;e++){const i=t.substring(e,e+2),r=n.has(i)?n.get(i)+1:1;n.set(i,r)}let i=0;for(let t=0;t<e.length-1;t++){const r=e.substring(t,t+2),o=n.has(r)?n.get(r):0;o>0&&(n.set(r,o-1),i++)}return 2*i/(t.length+e.length-2)}const pt=class{constructor(i){t(this,i),this.valueChanged=n(this,"valueChanged",7),this.required=!1,this.disabled=!1,this.isMouseOver=!1,this.inputValue="",this.isDropdownVisible=!1,this.filteredOptions=[],this.renderFilteredResults=()=>0===this.filteredOptions.length?e("span",{class:"dropdown-item disabled"},"No items match your search"):this.filteredOptions.map(((t,n)=>e("span",{class:{"dropdown-item text-wrap":!0,selected:this.isOptionSelected(t),active:this.highlightedOptionIndex===n},onClick:()=>{this.toggleDropdown(!1),this.selectOption(t)}},e("span",null,t.label)))),this.filterResults=t=>{this.filteredOptions=this.sortOptionsByRelevancy(this._options.filter((e=>e.label.toLowerCase().includes(t.toLowerCase()))),t),this.highlightedOptionIndex=void 0},this.selectOption=t=>{this.selectedOption=t,this.inputValue=t.label,this.valueChanged.emit(t)},this.isOptionSelected=t=>{var e;return(null===(e=this.selectedOption)||void 0===e?void 0:e.label)===t.label},this.toggleDropdown=t=>{this.isDropdownVisible=t},this.resetInput=()=>{var t,e;this.inputValue=null!==(e=null===(t=this.selectedOption)||void 0===t?void 0:t.label)&&void 0!==e?e:"",this.filteredOptions=this._options},this.processKeyboardNavigation=t=>{switch(t.key){case"ArrowDown":return this.toggleDropdown(!0),this.highlightNextItem(),!0;case"ArrowUp":return this.highlightPreviousItem(),!0;case"Enter":return void 0!==this.highlightedOptionIndex&&(this.toggleDropdown(!1),this.selectOption(this.filteredOptions[this.highlightedOptionIndex])),!0;case"Escape":return this.inputElement.blur(),!0}return!1},this.highlightPreviousItem=()=>{0!==this.filteredOptions.length&&(this.highlightedOptionIndex=void 0===this.highlightedOptionIndex?0:Math.max(this.highlightedOptionIndex-1,0))},this.highlightNextItem=()=>{0!==this.filteredOptions.length&&(this.highlightedOptionIndex=void 0===this.highlightedOptionIndex?0:Math.min(this.highlightedOptionIndex+1,this.filteredOptions.length-1))}}get _options(){if(void 0===this.options)throw new Error("Can't render <fl-dropdown /> component with no options");return this.options}componentWillLoad(){var t,e;this.filteredOptions=this._options,this.selectedOption=this._options.find((t=>t.value===this.value)),this.inputValue=null!==(e=null===(t=this.selectedOption)||void 0===t?void 0:t.label)&&void 0!==e?e:""}handleFocus(){this.toggleDropdown(!0)}handleBlur(){this.isMouseOver||(this.toggleDropdown(!1),this.resetInput())}handleKeyDown(t){this.processKeyboardNavigation(t)&&t.preventDefault()}onOptionsChanged(){this.filteredOptions=this._options}onValueChanged(){var t,e;this.selectedOption=this._options.find((t=>t.value===this.value)),this.inputValue=null!==(e=null===(t=this.selectedOption)||void 0===t?void 0:t.label)&&void 0!==e?e:""}render(){var t;return[e("div",{class:"dropdown"},e("input",{type:"text",class:"form-control custom-select",placeholder:this.placeholder,required:this.required,disabled:this.disabled,value:this.inputValue,onInput:t=>{const e=t.target.value;this.inputValue=e,this.filterResults(e),this.toggleDropdown(!0)},ref:t=>this.inputElement=t}),e("div",{class:{"invalid-feedback":!0,"d-none":this.isDropdownVisible}},null!==(t=this.requiredValidationMessage)&&void 0!==t?t:"Required."),e("div",{class:{"dropdown-menu shadow mt-0 w-100 overflow-auto":!0,show:this.isDropdownVisible},onMouseEnter:()=>this.isMouseOver=!0,onMouseLeave:()=>this.isMouseOver=!1},this.renderFilteredResults()))]}sortOptionsByRelevancy(t,e){return t.map((t=>Object.assign(Object.assign({},t),{relevancyScore:dt.compareTwoStrings(t.label.toLowerCase(),e.toLowerCase())}))).sort(((t,e)=>e.relevancyScore-t.relevancyScore)).map((t=>({label:t.label,value:t.value})))}static get watchers(){return{options:["onOptionsChanged"],value:["onValueChanged"]}}};pt.style="fl-dropdown .dropdown-menu{max-height:min(20rem, 50vh)}fl-dropdown .dropdown-menu .dropdown-item{cursor:pointer}fl-dropdown .dropdown-menu .dropdown-item.selected{background-color:rgba(253, 189, 0, 0.5)}";const mt=class{constructor(i){t(this,i),this.valueChanged=n(this,"valueChanged",7),this.required=!1,this.disabled=!1,this.minSearchStringLength=3,this.isMouseOver=!1,this.searchState="pristine",this.inputValue="",this.isDropdownVisible=!1,this.filteredOptions=[],this.shouldExecuteSearch=t=>{var e;return this.isDropdownVisible&&(null==t?void 0:t.length)>=this.minSearchStringLength&&(null===(e=this.selectedOption)||void 0===e?void 0:e.label)!==t},this.onBeginSearch=t=>{this.inputValue=t,this.searchState="in progress"},this.onCompleteSearch=t=>{this.filteredOptions=t,this.highlightedOptionIndex=void 0,this.searchState="done"},this.renderFilteredResults=()=>"pristine"===this.searchState?e("span",{class:"dropdown-item disabled"},"Start typing to find the results"):"in progress"===this.searchState?e("div",{class:"d-flex justify-content-end align-items-center pr-4"},e("span",{class:"dropdown-item disabled"},"Searching..."),e("i",{class:"dot-falling"})):0===this.filteredOptions.length?e("span",{class:"dropdown-item disabled"},"No items match your search"):this.filteredOptions.map(((t,n)=>e("span",{class:{"dropdown-item text-wrap":!0,selected:this.isOptionSelected(t),active:this.highlightedOptionIndex===n},onClick:()=>{this.toggleDropdown(!1),this.selectOption(t)}},t.label))),this.resetInput=()=>{var t,e;this.inputValue=null!==(e=null===(t=this.selectedOption)||void 0===t?void 0:t.label)&&void 0!==e?e:""},this.toggleDropdown=t=>{this.isDropdownVisible=t},this.processKeyboardNavigation=t=>{switch(t.key){case"ArrowDown":return this.toggleDropdown(!0),this.highlightNextItem(),!0;case"ArrowUp":return this.highlightPreviousItem(),!0;case"Enter":return void 0!==this.highlightedOptionIndex&&(this.toggleDropdown(!1),this.selectOption(this.filteredOptions[this.highlightedOptionIndex])),!0;case"Escape":return this.inputElement.blur(),!0}return!1},this.highlightPreviousItem=()=>{0!==this.filteredOptions.length&&(this.highlightedOptionIndex=void 0===this.highlightedOptionIndex?0:Math.max(this.highlightedOptionIndex-1,0))},this.highlightNextItem=()=>{0!==this.filteredOptions.length&&(this.highlightedOptionIndex=void 0===this.highlightedOptionIndex?0:Math.min(this.highlightedOptionIndex+1,this.filteredOptions.length-1))},this.selectOption=t=>{this.selectedOption=t,this.inputValue=t.label,this.valueChanged.emit(t)},this.isOptionSelected=t=>{var e;return(null===(e=this.selectedOption)||void 0===e?void 0:e.label)===t.label}}componentWillLoad(){this.selectedOption=this.value}componentDidLoad(){this.searchResultsSubscription=E(this.inputElement,"keyup").pipe(function(t,e=S){return n=>n.lift(new F(t,e))}(500),f((()=>this.inputElement.value)),m(),v(this.shouldExecuteSearch),M(this.onBeginSearch),q(this._searchFunction),M(this.onCompleteSearch)).subscribe()}componentDidUnload(){this.searchResultsSubscription.unsubscribe()}handleFocus(){this.toggleDropdown(!0)}handleBlur(){this.isMouseOver||(this.toggleDropdown(!1),this.highlightedOptionIndex=void 0,this.resetInput())}handleKeyDown(t){this.processKeyboardNavigation(t)&&t.preventDefault()}render(){var t;return[e("div",{class:"dropdown"},e("input",{type:"text",class:"form-control",placeholder:this.placeholder,required:this.required,disabled:this.disabled,value:this.inputValue,ref:t=>this.inputElement=t}),e("div",{class:{"invalid-feedback":!0,"d-none":this.isDropdownVisible}},null!==(t=this.requiredValidationMessage)&&void 0!==t?t:"Required."),e("div",{class:{"dropdown-menu shadow mt-0 w-100 overflow-auto":!0,show:this.isDropdownVisible},onMouseEnter:()=>this.isMouseOver=!0,onMouseLeave:()=>this.isMouseOver=!1},this.renderFilteredResults()))]}get _searchFunction(){if(void 0===this.searchFunction)throw new Error("Can't render <fl-dropdown-async/> component with no searchFunction");return this.searchFunction}};mt.style="fl-dropdown .dropdown-menu{max-height:min(20rem, 50vh)}fl-dropdown .dropdown-menu .dropdown-item{cursor:pointer}fl-dropdown .dropdown-menu .dropdown-item.selected{background-color:rgba(253, 189, 0, 0.5)}";const vt=class{constructor(e){t(this,e),this.theme="default"}render(){return e("span",{class:{"dots-container d-inline-flex justify-content-center":!0}},e("span",{class:{"dot-flashing":!0,"theme-default":"default"===this.theme,"theme-dark":"dark"===this.theme}}))}};var bt;vt.style='fl-loading-indicator .dots-container{width:36px}fl-loading-indicator .dot-flashing.theme-default{position:relative;width:8px;height:8px;border-radius:4px;background-color:#66efc5;color:#9880ff;-webkit-animation:dot-flashing-default 2s infinite linear;animation:dot-flashing-default 2s infinite linear;-webkit-animation-delay:0.5s;animation-delay:0.5s}@-webkit-keyframes dot-flashing-default{0%{background-color:#66efc5}25%{background-color:#12aa7c}50%,100%{background-color:#66efc5}}@keyframes dot-flashing-default{0%{background-color:#66efc5}25%{background-color:#12aa7c}50%,100%{background-color:#66efc5}}fl-loading-indicator .dot-flashing.theme-default::before,fl-loading-indicator .dot-flashing.theme-default::after{content:"";display:inline-block;position:absolute;top:0}fl-loading-indicator .dot-flashing.theme-default::before{left:-12px;width:8px;height:8px;border-radius:4px;background-color:#66efc5;color:#9880ff;-webkit-animation:dot-flashing-default 2s infinite linear;animation:dot-flashing-default 2s infinite linear;-webkit-animation-delay:0s;animation-delay:0s}@keyframes dot-flashing-default{0%{background-color:#66efc5}25%{background-color:#12aa7c}50%,100%{background-color:#66efc5}}fl-loading-indicator .dot-flashing.theme-default::after{left:12px;width:8px;height:8px;border-radius:4px;background-color:#66efc5;color:#9880ff;-webkit-animation:dot-flashing-default 2s infinite linear;animation:dot-flashing-default 2s infinite linear;-webkit-animation-delay:1s;animation-delay:1s}@keyframes dot-flashing-default{0%{background-color:#66efc5}25%{background-color:#12aa7c}50%,100%{background-color:#66efc5}}fl-loading-indicator .dot-flashing.theme-dark{position:relative;width:8px;height:8px;border-radius:4px;background-color:#a7a7a7;color:#9880ff;-webkit-animation:dot-flashing-dark 2s infinite linear;animation:dot-flashing-dark 2s infinite linear;-webkit-animation-delay:0.5s;animation-delay:0.5s}@-webkit-keyframes dot-flashing-dark{0%{background-color:#a7a7a7}25%{background-color:#5b5a5a}50%,100%{background-color:#a7a7a7}}@keyframes dot-flashing-dark{0%{background-color:#a7a7a7}25%{background-color:#5b5a5a}50%,100%{background-color:#a7a7a7}}fl-loading-indicator .dot-flashing.theme-dark::before,fl-loading-indicator .dot-flashing.theme-dark::after{content:"";display:inline-block;position:absolute;top:0}fl-loading-indicator .dot-flashing.theme-dark::before{left:-12px;width:8px;height:8px;border-radius:4px;background-color:#a7a7a7;color:#9880ff;-webkit-animation:dot-flashing-dark 2s infinite linear;animation:dot-flashing-dark 2s infinite linear;-webkit-animation-delay:0s;animation-delay:0s}@keyframes dot-flashing-dark{0%{background-color:#a7a7a7}25%{background-color:#5b5a5a}50%,100%{background-color:#a7a7a7}}fl-loading-indicator .dot-flashing.theme-dark::after{left:12px;width:8px;height:8px;border-radius:4px;background-color:#a7a7a7;color:#9880ff;-webkit-animation:dot-flashing-dark 2s infinite linear;animation:dot-flashing-dark 2s infinite linear;-webkit-animation-delay:1s;animation-delay:1s}@keyframes dot-flashing-dark{0%{background-color:#a7a7a7}25%{background-color:#5b5a5a}50%,100%{background-color:#a7a7a7}}',function(t){t[t.Available=0]="Available",t[t.Pending=1]="Pending",t[t.Error=2]="Error"}(bt||(bt={}));const gt=class{constructor(e){t(this,e),this.isBlockElement=!1,this.isRounded=!1,this.disabled=!1,this.variant="primary",this.promiseFn=()=>Promise.resolve(),this.state=bt.Available}render(){return this.state===bt.Pending?this.renderLoadingButton():this.renderActiveButton()}renderActiveButton(){return e("fl-button",{disabled:this.disabled,onClick:()=>this.clicked(),isBlockElement:this.isBlockElement,variant:this.variant},e("div",null,e("slot",null)))}renderLoadingButton(){return e("fl-button",{disabled:!0,onClick:()=>this.clicked(),isBlockElement:this.isBlockElement,class:"position-relative",variant:this.variant},e("fl-loading-indicator",{class:"position-absolute",theme:"dark"}),e("div",{class:"invisible"},e("slot",null)))}async clicked(){this.state=bt.Pending;try{await this.promiseFn(),this.state=bt.Available}catch(t){throw this.state=bt.Error,t}}};function wt(t,e){void 0===e&&(e="*"),t.sender="flare",window.parent.postMessage(t,e)}gt.style="fl-promise-button fl-loading-indicator{left:50%;top:50%;-webkit-transform:translate(-50%, -50%);transform:translate(-50%, -50%)}";const yt=function(){wt({type:"appReady"})},xt=function(t,e){wt({type:"contentResized",height:t,width:e})},kt=function(t){wt({type:"pageNavigated",url:t})},St=function(){wt({type:"complete"})},Ct=function(){wt({type:"submitSuccess"})},_t=t=>!("isConnected"in t)||t.isConnected,At=(()=>{let t;return(...e)=>{t&&clearTimeout(t),t=setTimeout((()=>{t=0,(t=>{for(let e of t.keys())t.set(e,t.get(e).filter(_t))})(...e)}),2e3)}})(),qt=(t,e)=>{const n=((t,e=((t,e)=>t!==e))=>{let n=new Map(Object.entries(null!=t?t:{}));const i={dispose:[],get:[],set:[],reset:[]},r=()=>{n=new Map(Object.entries(null!=t?t:{})),i.reset.forEach((t=>t()))},o=t=>(i.get.forEach((e=>e(t))),n.get(t)),s=(t,r)=>{const o=n.get(t);e(r,o,t)&&(n.set(t,r),i.set.forEach((e=>e(t,r,o))))},a="undefined"==typeof Proxy?{}:new Proxy(t,{get:(t,e)=>o(e),ownKeys:()=>Array.from(n.keys()),getOwnPropertyDescriptor:()=>({enumerable:!0,configurable:!0}),has:(t,e)=>n.has(e),set:(t,e,n)=>(s(e,n),!0)}),c=(t,e)=>(i[t].push(e),()=>{((t,e)=>{const n=t.indexOf(e);n>=0&&(t[n]=t[t.length-1],t.length--)})(i[t],e)});return{state:a,get:o,set:s,on:c,onChange:(e,n)=>{const i=c("set",((t,i)=>{t===e&&n(i)})),r=c("reset",(()=>n(t[e])));return()=>{i(),r()}},use:(...t)=>t.forEach((t=>{t.set&&c("set",t.set),t.get&&c("get",t.get),t.reset&&c("reset",t.reset)})),dispose:()=>{i.dispose.forEach((t=>t())),r()},reset:r}})(t,e);return(({on:t})=>{const e=new Map;"function"==typeof i&&(t("dispose",(()=>{e.clear()})),t("get",(t=>{const n=i();n&&((t,e,n)=>{const i=t.get(e);i?i.includes(n)||i.push(n):t.set(e,[n])})(e,t,n)})),t("set",(t=>{const n=e.get(t);n&&e.set(t,n.filter(r)),At(e)})),t("reset",(()=>{e.forEach((t=>t.forEach(r))),At(e)})))})(n),n};function Bt(t,e,n){return t(n={path:e,exports:{},require:function(){return function(){throw new Error("Dynamic requires are not currently supported by @rollup/plugin-commonjs")}()}},n.exports),n.exports}var jt=Bt((function(t,e){function n(t){return t}function i(t){return function(){return t}}function r(){throw new Error("Called `absurd` function which should be uncallable")}Object.defineProperty(e,"__esModule",{value:!0}),e.bindTo_=e.bind_=e.hole=e.pipe=e.untupled=e.tupled=e.absurd=e.decrement=e.increment=e.tuple=e.flow=e.flip=e.constVoid=e.constUndefined=e.constNull=e.constFalse=e.constTrue=e.constant=e.not=e.unsafeCoerce=e.identity=void 0,e.identity=n,e.unsafeCoerce=n,e.not=function(t){return function(e){return!t(e)}},e.constant=i,e.constTrue=i(!0),e.constFalse=i(!1),e.constNull=i(null),e.constUndefined=i(void 0),e.constVoid=e.constUndefined,e.flip=function(t){return function(e,n){return t(n,e)}},e.flow=function(t,e,n,i,r,o,s,a,c){switch(arguments.length){case 1:return t;case 2:return function(){return e(t.apply(this,arguments))};case 3:return function(){return n(e(t.apply(this,arguments)))};case 4:return function(){return i(n(e(t.apply(this,arguments))))};case 5:return function(){return r(i(n(e(t.apply(this,arguments)))))};case 6:return function(){return o(r(i(n(e(t.apply(this,arguments))))))};case 7:return function(){return s(o(r(i(n(e(t.apply(this,arguments)))))))};case 8:return function(){return a(s(o(r(i(n(e(t.apply(this,arguments))))))))};case 9:return function(){return c(a(s(o(r(i(n(e(t.apply(this,arguments)))))))))}}},e.tuple=function(){for(var t=[],e=0;e<arguments.length;e++)t[e]=arguments[e];return t},e.increment=function(t){return t+1},e.decrement=function(t){return t-1},e.absurd=r,e.tupled=function(t){return function(e){return t.apply(void 0,e)}},e.untupled=function(t){return function(){for(var e=[],n=0;n<arguments.length;n++)e[n]=arguments[n];return t(e)}},e.pipe=function(t,e,n,i,r,o,s,a,c,u,l,f,d,h,p,m,v,b,g,w){switch(arguments.length){case 1:return t;case 2:return e(t);case 3:return n(e(t));case 4:return i(n(e(t)));case 5:return r(i(n(e(t))));case 6:return o(r(i(n(e(t)))));case 7:return s(o(r(i(n(e(t))))));case 8:return a(s(o(r(i(n(e(t)))))));case 9:return c(a(s(o(r(i(n(e(t))))))));case 10:return u(c(a(s(o(r(i(n(e(t)))))))));case 11:return l(u(c(a(s(o(r(i(n(e(t))))))))));case 12:return f(l(u(c(a(s(o(r(i(n(e(t)))))))))));case 13:return d(f(l(u(c(a(s(o(r(i(n(e(t))))))))))));case 14:return h(d(f(l(u(c(a(s(o(r(i(n(e(t)))))))))))));case 15:return p(h(d(f(l(u(c(a(s(o(r(i(n(e(t))))))))))))));case 16:return m(p(h(d(f(l(u(c(a(s(o(r(i(n(e(t)))))))))))))));case 17:return v(m(p(h(d(f(l(u(c(a(s(o(r(i(n(e(t))))))))))))))));case 18:return b(v(m(p(h(d(f(l(u(c(a(s(o(r(i(n(e(t)))))))))))))))));case 19:return g(b(v(m(p(h(d(f(l(u(c(a(s(o(r(i(n(e(t))))))))))))))))));case 20:return w(g(b(v(m(p(h(d(f(l(u(c(a(s(o(r(i(n(e(t)))))))))))))))))))}},e.hole=r,e.bind_=function(t,e,n){var i;return Object.assign({},t,((i={})[e]=n,i))},e.bindTo_=function(t){return function(e){var n;return(n={})[t]=e,n}}})),Et=Bt((function(t,e){function n(t){return null==t?e.none:e.some(t)}function i(t){return"Right"===t._tag?e.none:e.some(t.left)}function r(t){return"Left"===t._tag?e.none:e.some(t.right)}function o(t){return function(i){return e.isNone(i)?e.none:n(t(i.value))}}Object.defineProperty(e,"__esModule",{value:!0}),e.getApplySemigroup=e.getOrd=e.getEq=e.getShow=e.URI=e.wilt=e.wither=e.sequence=e.traverse=e.partitionMap=e.partition=e.filterMap=e.filter=e.separate=e.compact=e.reduceRight=e.foldMap=e.reduce=e.duplicate=e.extend=e.throwError=e.zero=e.alt=e.altW=e.flatten=e.chainFirst=e.chain=e.of=e.apSecond=e.apFirst=e.ap=e.map=e.chainNullableK=e.mapNullable=e.fromNullableK=e.getOrElse=e.getOrElseW=e.toUndefined=e.toNullable=e.fold=e.fromEither=e.getRight=e.getLeft=e.tryCatch=e.fromPredicate=e.fromNullable=e.some=e.none=e.isNone=e.isSome=void 0,e.sequenceArray=e.traverseArray=e.traverseArrayWithIndex=e.apS=e.bind=e.bindTo=e.Do=e.getRefinement=e.exists=e.elem=e.option=e.MonadThrow=e.Witherable=e.Traversable=e.Filterable=e.Compactable=e.Extend=e.Alternative=e.Alt=e.Foldable=e.Monad=e.Applicative=e.Functor=e.getMonoid=e.getLastMonoid=e.getFirstMonoid=e.getApplyMonoid=void 0,e.isSome=function(t){return"Some"===t._tag},e.isNone=function(t){return"None"===t._tag},e.none={_tag:"None"},e.some=function(t){return{_tag:"Some",value:t}},e.fromNullable=n,e.fromPredicate=function(t){return function(n){return t(n)?e.some(n):e.none}},e.tryCatch=function(t){try{return e.some(t())}catch(t){return e.none}},e.getLeft=i,e.getRight=r,e.fromEither=r,e.fold=function(t,n){return function(i){return e.isNone(i)?t():n(i.value)}},e.toNullable=function(t){return e.isNone(t)?null:t.value},e.toUndefined=function(t){return e.isNone(t)?void 0:t.value},e.getOrElseW=function(t){return function(n){return e.isNone(n)?t():n.value}},e.getOrElse=e.getOrElseW,e.fromNullableK=function(t){return function(){for(var e=[],i=0;i<arguments.length;i++)e[i]=arguments[i];return n(t.apply(void 0,e))}},e.mapNullable=o,e.chainNullableK=o;var s=function(t,n){return jt.pipe(t,e.map(n))},a=function(t,n){return jt.pipe(t,e.ap(n))},c=function(t,n){return jt.pipe(t,e.chain(n))},u=function(t,n,i){return jt.pipe(t,e.reduce(n,i))},l=function(t){var n=e.foldMap(t);return function(t,e){return jt.pipe(t,n(e))}},f=function(t,n,i){return jt.pipe(t,e.reduceRight(n,i))},d=function(t){var n=e.traverse(t);return function(t,e){return jt.pipe(t,n(e))}},h=function(t,n){return jt.pipe(t,e.alt(n))},p=function(t,n){return jt.pipe(t,e.filter(n))},m=function(t,n){return jt.pipe(t,e.filterMap(n))},v=function(t,n){return jt.pipe(t,e.extend(n))},b=function(t,n){return jt.pipe(t,e.partition(n))},g=function(t,n){return jt.pipe(t,e.partitionMap(n))},w=function(t){var n=e.wither(t);return function(t,e){return jt.pipe(t,n(e))}},y=function(t){var n=e.wilt(t);return function(t,e){return jt.pipe(t,n(e))}};e.map=function(t){return function(n){return e.isNone(n)?e.none:e.some(t(n.value))}},e.ap=function(t){return function(n){return e.isNone(n)||e.isNone(t)?e.none:e.some(n.value(t.value))}},e.apFirst=function(t){return jt.flow(e.map((function(t){return function(){return t}})),e.ap(t))},e.apSecond=function(t){return jt.flow(e.map((function(){return function(t){return t}})),e.ap(t))},e.of=e.some,e.chain=function(t){return function(n){return e.isNone(n)?e.none:t(n.value)}},e.chainFirst=function(t){return e.chain((function(n){return jt.pipe(t(n),e.map((function(){return n})))}))},e.flatten=e.chain(jt.identity),e.altW=function(t){return function(n){return e.isNone(n)?t():n}},e.alt=e.altW,e.zero=function(){return e.none},e.throwError=function(){return e.none},e.extend=function(t){return function(n){return e.isNone(n)?e.none:e.some(t(n))}},e.duplicate=e.extend(jt.identity),e.reduce=function(t,n){return function(i){return e.isNone(i)?t:n(t,i.value)}},e.foldMap=function(t){return function(n){return function(i){return e.isNone(i)?t.empty:n(i.value)}}},e.reduceRight=function(t,n){return function(i){return e.isNone(i)?t:n(i.value,t)}},e.compact=e.flatten;var x={left:e.none,right:e.none};function k(t){return{equals:function(n,i){return n===i||(e.isNone(n)?e.isNone(i):!e.isNone(i)&&t.equals(n.value,i.value))}}}function S(t){return{concat:function(n,i){return e.isSome(n)&&e.isSome(i)?e.some(t.concat(n.value,i.value)):e.none}}}e.separate=function(t){var n=jt.pipe(t,e.map((function(t){return{left:i(t),right:r(t)}})));return e.isNone(n)?x:n.value},e.filter=function(t){return function(n){return e.isNone(n)?e.none:t(n.value)?n:e.none}},e.filterMap=function(t){return function(n){return e.isNone(n)?e.none:t(n.value)}},e.partition=function(t){return function(e){return{left:p(e,(function(e){return!t(e)})),right:p(e,t)}}},e.partitionMap=function(t){return jt.flow(e.map(t),e.separate)},e.traverse=function(t){return function(n){return function(i){return e.isNone(i)?t.of(e.none):t.map(n(i.value),e.some)}}},e.sequence=function(t){return function(n){return e.isNone(n)?t.of(e.none):t.map(n.value,e.some)}},e.wither=function(t){return function(n){return function(i){return e.isNone(i)?t.of(e.none):n(i.value)}}},e.wilt=function(t){return function(n){return function(o){return e.isNone(o)?t.of({left:e.none,right:e.none}):t.map(n(o.value),(function(t){return{left:i(t),right:r(t)}}))}}},e.URI="Option",e.getShow=function(t){return{show:function(n){return e.isNone(n)?"none":"some("+t.show(n.value)+")"}}},e.getEq=k,e.getOrd=function(t){return{equals:k(t).equals,compare:function(n,i){return n===i?0:e.isSome(n)?e.isSome(i)?t.compare(n.value,i.value):1:-1}}},e.getApplySemigroup=S,e.getApplyMonoid=function(t){return{concat:S(t).concat,empty:e.some(t.empty)}},e.getFirstMonoid=function(){return{concat:function(t,n){return e.isNone(t)?n:t},empty:e.none}},e.getLastMonoid=function(){return{concat:function(t,n){return e.isNone(n)?t:n},empty:e.none}},e.getMonoid=function(t){return{concat:function(n,i){return e.isNone(n)?i:e.isNone(i)?n:e.some(t.concat(n.value,i.value))},empty:e.none}},e.Functor={URI:e.URI,map:s},e.Applicative={URI:e.URI,map:s,ap:a,of:e.of},e.Monad={URI:e.URI,map:s,ap:a,of:e.of,chain:c},e.Foldable={URI:e.URI,reduce:u,foldMap:l,reduceRight:f},e.Alt={URI:e.URI,map:s,alt:h},e.Alternative={URI:e.URI,map:s,ap:a,of:e.of,alt:h,zero:e.zero},e.Extend={URI:e.URI,map:s,extend:v},e.Compactable={URI:e.URI,compact:e.compact,separate:e.separate},e.Filterable={URI:e.URI,map:s,compact:e.compact,separate:e.separate,filter:p,filterMap:m,partition:b,partitionMap:g},e.Traversable={URI:e.URI,map:s,reduce:u,foldMap:l,reduceRight:f,traverse:d,sequence:e.sequence},e.Witherable={URI:e.URI,map:s,reduce:u,foldMap:l,reduceRight:f,traverse:d,sequence:e.sequence,compact:e.compact,separate:e.separate,filter:p,filterMap:m,partition:b,partitionMap:g,wither:w,wilt:y},e.MonadThrow={URI:e.URI,map:s,ap:a,of:e.of,chain:c,throwError:e.throwError},e.option={URI:e.URI,map:s,of:e.of,ap:a,chain:c,reduce:u,foldMap:l,reduceRight:f,traverse:d,sequence:e.sequence,zero:e.zero,alt:h,extend:v,compact:e.compact,separate:e.separate,filter:p,filterMap:m,partition:b,partitionMap:g,wither:w,wilt:y,throwError:e.throwError},e.elem=function(t){return function(n,i){return!e.isNone(i)&&t.equals(n,i.value)}},e.exists=function(t){return function(n){return!e.isNone(n)&&t(n.value)}},e.getRefinement=function(t){return function(n){return e.isSome(t(n))}},e.Do=e.of({}),e.bindTo=function(t){return e.map(jt.bindTo_(t))},e.bind=function(t,n){return e.chain((function(i){return jt.pipe(n(i),e.map((function(e){return jt.bind_(i,t,e)})))}))},e.apS=function(t,n){return jt.flow(e.map((function(e){return function(n){return jt.bind_(e,t,n)}})),e.ap(n))},e.traverseArrayWithIndex=function(t){return function(n){for(var i=[],r=0;r<n.length;r++){var o=t(r,n[r]);if(e.isNone(o))return e.none;i.push(o.value)}return e.some(i)}},e.traverseArray=function(t){return e.traverseArrayWithIndex((function(e,n){return t(n)}))},e.sequenceArray=e.traverseArray(jt.identity)}));function It(t){this.message=t}(It.prototype=new Error).name="InvalidCharacterError";var Ft="undefined"!=typeof window&&window.atob&&window.atob.bind(window)||function(t){var e=String(t).replace(/=+$/,"");if(e.length%4==1)throw new It("'atob' failed: The string to be decoded is not correctly encoded.");for(var n,i,r=0,o=0,s="";i=e.charAt(o++);~i&&(n=r%4?64*n+i:i,r++%4)?s+=String.fromCharCode(255&n>>(-2*r&6)):0)i="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/=".indexOf(i);return s};function Pt(t){var e=t.replace(/-/g,"+").replace(/_/g,"/");switch(e.length%4){case 0:break;case 2:e+="==";break;case 3:e+="=";break;default:throw"Illegal base64url string!"}try{return function(t){return decodeURIComponent(Ft(t).replace(/(.)/g,(function(t,e){var n=e.charCodeAt(0).toString(16).toUpperCase();return n.length<2&&(n="0"+n),"%"+n})))}(e)}catch(t){return Ft(e)}}function Tt(t){this.message=t}(Tt.prototype=new Error).name="InvalidTokenError";var Mt=function(){return(Mt=Object.assign||function(t){for(var e,n=1,i=arguments.length;n<i;n++)for(var r in e=arguments[n])Object.prototype.hasOwnProperty.call(e,r)&&(t[r]=e[r]);return t}).apply(this,arguments)},Rt=function(){for(var t=0,e=0,n=arguments.length;e<n;e++)t+=arguments[e].length;var i=Array(t),r=0;for(e=0;e<n;e++)for(var o=arguments[e],s=0,a=o.length;s<a;s++,r++)i[r]=o[s];return i},Nt=function(t,e,n){if(void 0===n&&(n=!1),!t||!e||"object"!=typeof t||"object"!=typeof e)return t;var i=Mt({},t);for(var r in e)e.hasOwnProperty(r)&&(i[r]=e[r]instanceof Array&&t[r]instanceof Array?n?Rt(t[r],e[r]):e[r]:"object"==typeof e[r]&&"object"==typeof t[r]?Nt(t[r],e[r],n):e[r]);return i},Dt=function(){for(var t=0,e=0,n=arguments.length;e<n;e++)t+=arguments[e].length;var i=Array(t),r=0;for(e=0;e<n;e++)for(var o=arguments[e],s=0,a=o.length;s<a;s++,r++)i[r]=o[s];return i},Ot={defaults:{},errorType:null,polyfills:{fetch:null,FormData:null,URLSearchParams:null,performance:null,PerformanceObserver:null,AbortController:null},polyfill:function(t,e){for(var n=void 0===e?{}:e,i=n.doThrow,r=void 0===i||i,o=n.instance,s=void 0!==o&&o,a=[],c=2;c<arguments.length;c++)a[c-2]=arguments[c];var u=this.polyfills[t]||("undefined"!=typeof self?self[t]:null)||("undefined"!=typeof global?global[t]:null);if(r&&!u)throw new Error(t+" is not defined");return s&&u?new(u.bind.apply(u,Dt([void 0],a))):u}},Ut=function(t,e,n,i){if(!t.getEntriesByName)return!1;var r=t.getEntriesByName(e);return!!(r&&r.length>0)&&(n(r.reverse()[0]),i.clearMeasures&&i.clearMeasures(e),Lt.callbacks.delete(e),Lt.callbacks.size<1&&(Lt.observer.disconnect(),i.clearResourceTimings&&i.clearResourceTimings()),!0)},Lt={callbacks:new Map,observer:null,observe:function(t,e){if(t&&e){var n=Ot.polyfill("performance",{doThrow:!1});(function(t,e){return!Lt.observer&&t&&e&&(Lt.observer=new e((function(e){Lt.callbacks.forEach((function(n,i){Ut(e,i,n,t)}))})),t.clearResourceTimings&&t.clearResourceTimings()),Lt.observer})(n,Ot.polyfill("PerformanceObserver",{doThrow:!1}))&&(Ut(n,t,e,n)||(Lt.callbacks.size<1&&Lt.observer.observe({entryTypes:["resource","measure"]}),Lt.callbacks.set(t,e)))}}},zt=function(t){this.error=t},Vt=function(){return(Vt=Object.assign||function(t){for(var e,n=1,i=arguments.length;n<i;n++)for(var r in e=arguments[n])Object.prototype.hasOwnProperty.call(e,r)&&(t[r]=e[r]);return t}).apply(this,arguments)},Ht=function(){for(var t=0,e=0,n=arguments.length;e<n;e++)t+=arguments[e].length;var i=Array(t),r=0;for(e=0;e<n;e++)for(var o=arguments[e],s=0,a=o.length;s<a;s++,r++)i[r]=o[s];return i},Qt=function(){function t(t,e,n,i,r,o){void 0===n&&(n=new Map),void 0===i&&(i=[]),void 0===r&&(r=[]),void 0===o&&(o=[]),this._url=t,this._options=e,this._catchers=n,this._resolvers=i,this._middlewares=r,this._deferredChain=o}return t.factory=function(e,n){return void 0===e&&(e=""),void 0===n&&(n={}),new t(e,n)},t.prototype.selfFactory=function(e){var n=void 0===e?{}:e,i=n.url,r=n.options,o=n.catchers,s=void 0===o?this._catchers:o,a=n.resolvers,c=void 0===a?this._resolvers:a,u=n.middlewares,l=void 0===u?this._middlewares:u,f=n.deferredChain,d=void 0===f?this._deferredChain:f;return new t(void 0===i?this._url:i,Vt({},void 0===r?this._options:r),new Map(s),Ht(c),Ht(l),Ht(d))},t.prototype.defaults=function(t,e){return void 0===e&&(e=!1),Ot.defaults=e?Nt(Ot.defaults,t):t,this},t.prototype.errorType=function(t){return Ot.errorType=t,this},t.prototype.polyfills=function(t){return Ot.polyfills=Vt(Vt({},Ot.polyfills),t),this},t.prototype.url=function(t,e){if(void 0===e&&(e=!1),e)return this.selfFactory({url:t});var n=this._url.split("?");return this.selfFactory({url:n.length>1?n[0]+t+"?"+n[1]:this._url+t})},t.prototype.options=function(t,e){return void 0===e&&(e=!0),this.selfFactory({options:e?Nt(this._options,t):t})},t.prototype.query=function(t,e){return void 0===e&&(e=!1),this.selfFactory({url:Wt(this._url,t,e)})},t.prototype.headers=function(t){return this.selfFactory({options:Nt(this._options,{headers:t||{}})})},t.prototype.accept=function(t){return this.headers({Accept:t})},t.prototype.content=function(t){var e;return this.headers(((e={})["Content-Type"]=t,e))},t.prototype.auth=function(t){return this.headers({Authorization:t})},t.prototype.catcher=function(t,e){var n=new Map(this._catchers);return n.set(t,e),this.selfFactory({catchers:n})},t.prototype.signal=function(t){return this.selfFactory({options:Vt(Vt({},this._options),{signal:t.signal})})},t.prototype.resolve=function(t,e){return void 0===e&&(e=!1),this.selfFactory({resolvers:e?[t]:Ht(this._resolvers,[t])})},t.prototype.defer=function(t,e){return void 0===e&&(e=!1),this.selfFactory({deferredChain:e?[t]:Ht(this._deferredChain,[t])})},t.prototype.middlewares=function(t,e){return void 0===e&&(e=!1),this.selfFactory({middlewares:e?t:Ht(this._middlewares,t)})},t.prototype.method=function(t,e,n){void 0===e&&(e={}),void 0===n&&(n=null);var i=this._options.headers,r=n?"object"!=typeof n||i&&!Object.entries(i).every((function(t){var e=t[1];return t[0].toLowerCase()!=="Content-Type".toLowerCase()||e.startsWith("application/json")}))?this.body(n):this.json(n):this;return function(t){var e=t._url,n=t._resolvers,i=t._middlewares,r=t._options,o=new Map(t._catchers),s=Nt(Ot.defaults,r),a=Ot.polyfill("AbortController",{doThrow:!1,instance:!0});!s.signal&&a&&(s.signal=a.signal);var c={ref:null,clear:function(){c.ref&&(clearTimeout(c.ref),c.ref=null)}},u=function(t){return function(e){return 0===t.length?e:1===t.length?t[0](e):t.reduceRight((function(n,i,r){return i(r===t.length-2?n(e):n)}))}}(i)(Ot.polyfill("fetch"))(e,s),l=u.catch((function(t){throw new zt(t)})).then((function(t){return c.clear(),t.ok?t:t[Ot.errorType||"text"]().then((function(e){var n=new Error(e);throw n[Ot.errorType||"text"]=e,n.status=t.status,n.response=t,n}))})),f=function(e){return function(n){return(e?l.then((function(t){return t&&t[e]()})).then((function(t){return n?n(t):t})):l.then((function(t){return n?n(t):t}))).catch((function(e){c.clear();var n=e instanceof zt?e.error:e;if(e instanceof zt&&o.has("__fromFetch"))return o.get("__fromFetch")(n,t);if(o.has(n.status))return o.get(n.status)(n,t);if(o.has(n.name))return o.get(n.name)(n,t);throw n}))}},d={res:f(null),json:f("json"),blob:f("blob"),formData:f("formData"),arrayBuffer:f("arrayBuffer"),text:f("text"),perfs:function(t){return u.then((function(e){return Lt.observe(e.url,t)})),d},setTimeout:function(t,e){return void 0===e&&(e=a),c.clear(),c.ref=setTimeout((function(){return e.abort()}),t),d},controller:function(){return[a,d]},error:function(t,e){return o.set(t,e),d},badRequest:function(t){return d.error(400,t)},unauthorized:function(t){return d.error(401,t)},forbidden:function(t){return d.error(403,t)},notFound:function(t){return d.error(404,t)},timeout:function(t){return d.error(408,t)},internalError:function(t){return d.error(500,t)},fetchError:function(t){return d.error("__fromFetch",t)},onAbort:function(t){return d.error("AbortError",t)}};return n.reduce((function(e,n){return n(e,t)}),d)}((r=r.options(Vt(Vt({},e),{method:t})))._deferredChain.reduce((function(t,e){return e(t,t._url,t._options)}),r))},t.prototype.get=function(t){return this.method("GET",t)},t.prototype.delete=function(t){return this.method("DELETE",t)},t.prototype.put=function(t,e){return this.method("PUT",e,t)},t.prototype.post=function(t,e){return this.method("POST",e,t)},t.prototype.patch=function(t,e){return this.method("PATCH",e,t)},t.prototype.head=function(t){return this.method("HEAD",t)},t.prototype.opts=function(t){return this.method("OPTIONS",t)},t.prototype.replay=function(t){return this.method(this._options.method,t)},t.prototype.body=function(t){return this.selfFactory({options:Vt(Vt({},this._options),{body:t})})},t.prototype.json=function(t){var e,n=null===(e=Object.entries(this._options.headers||{}).find((function(t){var e=t[1];return t[0].toLowerCase()==="Content-Type".toLowerCase()&&e.startsWith("application/json")})))||void 0===e?void 0:e[1];return this.content(n||"application/json").body(JSON.stringify(t))},t.prototype.formData=function(t,e){return void 0===e&&(e=!1),this.body($t(t,e))},t.prototype.formUrl=function(t){return this.body("string"==typeof t?t:(e=t,Object.keys(e).map((function(t){var n=e[t];return n instanceof Array?n.map((function(e){return Yt(t,e)})).join("&"):Yt(t,n)})).join("&"))).content("application/x-www-form-urlencoded");var e},t}(),Wt=function(t,e,n){var i;if("string"==typeof e)i=e;else{var r=Ot.polyfill("URLSearchParams",{instance:!0});for(var o in e)if(e[o]instanceof Array)for(var s=0,a=e[o];s<a.length;s++)r.append(o,a[s]);else r.append(o,e[o]);i=r.toString()}var c=t.split("?");return n||c.length<2?c[0]+"?"+i:t+"&"+i};function $t(t,e,n,i){return void 0===e&&(e=!1),void 0===n&&(n=Ot.polyfill("FormData",{instance:!0})),void 0===i&&(i=[]),Object.entries(t).forEach((function(t){var r=t[0],o=t[1],s=i.reduce((function(t,e){return t?t+"["+e+"]":e}),null);if(s=s?s+"["+r+"]":r,o instanceof Array)for(var a=0,c=o;a<c.length;a++)n.append(s+"[]",c[a]);else!e||"object"!=typeof o||e instanceof Array&&e.includes(r)?n.append(s,o):null!==o&&$t(o,e,n,Ht(i,[r]))})),n}function Yt(t,e){return encodeURIComponent(t)+"="+encodeURIComponent("object"==typeof e?JSON.stringify(e):""+e)}var Xt=Qt.factory;function Jt(){const t=Zt.jwt,e=Zt.profileId,n=Zt.accountIdOrDefault,i=Zt.partnerIdOrDefault;return Xt(Zt.apiBaseUrl).headers({Authorization:"Bearer "+t,"X-PROFILE-ID":e,"X-PARTNER-ID":i,"X-ACCOUNT-ID":n})}Xt.default=Qt.factory;const Gt=new class{async getAustralianFundsAsync(t){return Jt().url("super-choice/australian-funds?"+this.toQueryString(t)).get().notFound((()=>{throw new Error("Failed to fetch the list of australian super funds.")})).json()}async getAppStateAsync(){return Jt().url("client-app-state").get().notFound((()=>{throw new Error("Failed to fetch application configuration.")})).json()}toQueryString(t){switch(t.type){case"partialMatch":return`search=${t.searchString}&maxRecordCount=${t.maxRecordCount}`;case"usiMatch":return"usi="+t.usi}}},Kt={apiBaseUrl:Et.none,appBaseUrl:Et.none,profileId:Et.none,jwt:Et.none,superBuyer:Et.none,promotedFunds:Et.none,accountConfiguration:Et.none,hasSuccessPageBeenAcknowledged:!1,hasSuperSelectionBeenSubmitted:!1},Zt=new class{constructor(){const{state:t,onChange:e}=qt(Kt);this._state=t,this._onChange=e,e("jwt",(t=>{this._state.profileId=jt.pipe(t,Et.chain((t=>Et.fromNullable(function(t,e){if("string"!=typeof t)throw new Tt("Invalid token specified");var n=!0===(e=e||{}).header?0:1;try{return JSON.parse(Pt(t.split(".")[n]))}catch(t){throw new Tt("Invalid token specified: "+t.message)}}(t).sub))))}))}get state(){return this._state}get onChange(){return this._onChange}get superBuyer(){if(Et.isNone(this._state.superBuyer))throw Error("User information is not set");return this._state.superBuyer.value}get apiBaseUrl(){if(Et.isNone(this._state.apiBaseUrl))throw Error("API base URL is not set");return this._state.apiBaseUrl.value}get appBaseUrl(){if(Et.isNone(this._state.appBaseUrl))throw Error("App base URL is not set");return this._state.appBaseUrl.value}get promotedFunds(){if(Et.isNone(this._state.promotedFunds))throw Error("Promoted Funds is not set");return this._state.promotedFunds.value}get profileId(){if(Et.isNone(this._state.profileId))throw Error("Failed to get Profile ID from JWT");return this._state.profileId.value}get defaultFundUsi(){return jt.pipe(this._state.accountConfiguration,Et.map((t=>Et.fromNullable(t.defaultFundUsi))),Et.flatten)}get accountIdOrDefault(){return jt.pipe(this._state.accountConfiguration,Et.map((t=>t.accountId)),Et.getOrElse((()=>"")))}get partnerIdOrDefault(){return jt.pipe(this._state.superBuyer,Et.map((t=>t.partnerId)),Et.getOrElse((()=>"")))}get jwt(){if(Et.isNone(this._state.jwt))throw Error("No authentication information was found");return this._state.jwt.value}get showSmsfNotSupported(){return jt.pipe(this._state.superBuyer,Et.map((t=>t.showSmsfNotSupported)),Et.getOrElse((()=>!1)))}completeSuperSelectionFlow(){this._state.hasSuccessPageBeenAcknowledged=!0}markSuperSelectionAsSubmitted(){this._state.hasSuperSelectionBeenSubmitted=!0}async loadAppStateAsync(){const t=await Gt.getAppStateAsync();this._state.accountConfiguration=Et.fromNullable(t.accountConfiguration),this._state.superBuyer=Et.fromNullable(t.superBuyer),this._state.promotedFunds=Et.fromNullable(t.promotedFunds)}},te=new class{navigateInternally(t,e){const n=`${this.appBaseUrl}${this.toRouteWithLeadingSlash(e)}`;kt(n),t.push(n)}toExternalUrl(t){const e=new URL(t);return e.searchParams.append("_extnav","true"),e.href}get appBaseUrl(){return Zt.appBaseUrl.replace(/\/$/,"")}toRouteWithLeadingSlash(t){return t.length>0&&"/"===t[0]?t:"/"+t}};var ee;!function(t){t.ChoicePage="/",t.SlateJoin="/slate/join/",t.SlateStandardChoice="/slate/standard-choice/",t.QSuperOptIn="/qsuper/insurance/opt-in/",t.QSuperQuestion1="/qsuper/insurance/question1/",t.QSuperQuestion2="/qsuper/insurance/question2/",t.QSuperQuestion3="/qsuper/insurance/question3/",t.QSuperQuestion4="/qsuper/insurance/question4/",t.QSuperQuestion5="/qsuper/insurance/question5/",t.QSuperQuestion6="/qsuper/insurance/question6/",t.QSuperQuestion7="/qsuper/insurance/question7/",t.QSuperQuestion8="/qsuper/insurance/question8/",t.QSuperConsent="/qsuper/consent/",t.QSuperJoin="/qsuper/join/",t.PromotedFundJoin="/promoted-fund/join",t.PromotedFundStandardChoice="/promoted-fund/standard-choice/",t.MyOwnFund="/super-choice/my-own-fund/",t.SelfManagedFund="/super-choice/smsf/",t.DefaultFund="/super-choice/default/",t.Success="/success/"}(ee||(ee={}));const ne=[e("stencil-route",{exact:!0,url:ee.ChoicePage,component:"sss-super-choice-page"}),e("stencil-route",{url:ee.SlateJoin,component:"sss-slate-join-page"}),e("stencil-route",{url:ee.SlateStandardChoice,component:"sss-slate-standard-choice-page"}),e("stencil-route",{url:ee.QSuperOptIn,component:"sss-qsuper-insurance-opt-in"}),e("stencil-route",{url:ee.PromotedFundJoin,component:"sss-promoted-fund-join-page"}),e("stencil-route",{url:ee.PromotedFundStandardChoice,component:"sss-promoted-fund-standard-choice-page"}),e("stencil-route",{url:ee.QSuperQuestion1,component:"sss-qsuper-question-1"}),e("stencil-route",{url:ee.QSuperQuestion2,component:"sss-qsuper-question-2"}),e("stencil-route",{url:ee.QSuperQuestion3,component:"sss-qsuper-question-3"}),e("stencil-route",{url:ee.QSuperQuestion4,component:"sss-qsuper-question-4"}),e("stencil-route",{url:ee.QSuperQuestion5,component:"sss-qsuper-question-5"}),e("stencil-route",{url:ee.QSuperQuestion6,component:"sss-qsuper-question-6"}),e("stencil-route",{url:ee.QSuperQuestion7,component:"sss-qsuper-question-7"}),e("stencil-route",{url:ee.QSuperQuestion8,component:"sss-qsuper-question-8"}),e("stencil-route",{url:ee.QSuperConsent,component:"sss-qsuper-consent"}),e("stencil-route",{url:ee.QSuperJoin,component:"sss-qsuper-join"}),e("stencil-route",{url:ee.MyOwnFund,component:"sss-my-own-fund"}),e("stencil-route",{url:ee.SelfManagedFund,component:"sss-self-managed-fund"}),e("stencil-route",{url:ee.DefaultFund,component:"sss-default-fund"}),e("stencil-route",{url:ee.Success,component:"sss-success"})];var ie;!function(t){t.MyOwnFund="My Own Fund",t.DefaultFund="Default Fund",t.SelfManagedFund="Self Managed Fund"}(ie||(ie={}));const re={continueAllowed:!1,nextRoute:"/",myOwnFundForm:{fundUsi:U,memberNumber:U,standardChoiceFormSignature:U},defaultFundForm:{standardChoiceFormSignature:""},selfManagedFundForm:{fundName:"",fundAbn:"",fundEsa:"",addressLine1:"",addressLine2:"",state:"",postcode:"",city:"",bankAccountName:"",bsb:"",bankAccountNumber:"",standardChoiceFormSignature:""},currentCustomFundType:ie.MyOwnFund,customFunds:[{label:ie.MyOwnFund,value:ee.MyOwnFund},{label:ie.DefaultFund,value:ee.DefaultFund},{label:ie.SelfManagedFund,value:ee.SelfManagedFund}]},{state:oe}=qt(re),se=oe.customFunds,ae=class{constructor(e){t(this,e),this.currentCustomFund=se[0],this.fundOptionsList=se}componentWillLoad(){let t="";window.location.pathname.includes(ee.MyOwnFund)&&(t=ee.MyOwnFund),window.location.pathname.includes(ee.DefaultFund)&&(t=ee.DefaultFund),window.location.pathname.includes(ee.SelfManagedFund)&&(t=ee.SelfManagedFund),this.currentCustomFund=se.find((e=>e.value===t))||se[0],te.navigateInternally(this.history,t)}render(){return e("div",{class:"container"},e("div",{class:"row justify-content-center"},e("div",{class:"col col-sm-10 col-md-7"},e("p",{class:"font-weight-bold text-center"},"Choose your Super"),e("div",{class:"mb-4"},e("select",{class:"form-control",required:!0,onChange:t=>{this.handleChange(t.target.value.trim())}},this.fundOptionsList.map((t=>e("option",{value:t.value,selected:this.currentCustomFund.value===t.value},t.label))))),e("slot",null))))}handleChange(t){const e=se.find((e=>e.value===t))||{value:ee.MyOwnFund};te.navigateInternally(this.history,e.value)}static get assetsDirs(){return["assets"]}};H(ae);const ce=new class{searchFundsAsync(t,e){return Gt.getAustralianFundsAsync({type:"partialMatch",searchString:t,maxRecordCount:e})}async getFundByUsiAsync(t){const e=await Gt.getAustralianFundsAsync({type:"usiMatch",usi:t});return 1===e.length?Et.some(e[0]):Et.none}};class ue{static get Instance(){return this.instance||(this.instance=new this)}async PostAnalyticsEventAsync(t){return Jt().url("analytics-events").post(t).res()}}class le{constructor(){this.eventTrackingApi=ue.Instance}static get Instance(){return this.instance||(this.instance=new this)}async TrackFinancialProductViewedAsync(t){return this.trackEventAsync({FinancialProductViewed:t})}async TrackSuperFundPdsViewedAsync(t){return this.trackEventAsync({SuperFundPdsViewed:t})}async TrackFinancialProductAcceptedAsync(t){return this.trackEventAsync({FinancialProductAccepted:t})}async TrackFinancialProductRejectedAsync(t){return this.trackEventAsync({FinancialProductRejected:t})}async TrackSuperFundPrivacyConfirmationAcceptedAsync(t){return this.trackEventAsync({SuperFundPrivacyConfirmationAccepted:t})}async TrackPromotedSuperFundDetailViewedAsync(t){return this.trackEventAsync({SuperFundDetailViewed:{PromotedFund:t}})}async TrackMyOwnSuperFundDetailViewedAsync(t){return this.trackEventAsync({SuperFundDetailViewed:{MyOwnFund:t}})}async TrackSmsfSuperFundDetailViewedAsync(t){return this.trackEventAsync({SuperFundDetailViewed:{Smsf:t}})}async TrackDefaultSuperFundDetailViewedAsync(t){return this.trackEventAsync({SuperFundDetailViewed:{DefaultFund:t}})}async TrackSuperFundPanelViewedAsync(t){return this.trackEventAsync({SuperFundPanelViewed:t})}async trackEventAsync(t){try{await this.eventTrackingApi.PostAnalyticsEventAsync({event:t})}catch(t){return}}}const fe={items:[]},de=new class{constructor(){const{state:t}=qt(fe);this._state=t}get state(){return this._state}closeCurrent(){const t=[...this._state.items];t.shift(),this._state.items=t}clearNotifications(){this._state.items=[]}showErrorNotification(t,e){this.pushNotification(t,null!=e?e:0,"danger")}showInfoNotification(t,e){this.pushNotification(t,null!=e?e:0,"info")}showWarningNotification(t,e){this.pushNotification(t,null!=e?e:0,"warning")}showSuccessNotification(t,e){this.pushNotification(t,null!=e?e:0,"success")}pushNotification(t,e,n){const i=[...this._state.items];i.push({details:t,type:n,priority:e}),this._state.items=i.sort(((t,e)=>e.priority-t.priority))}},he=new class{async submitDefaultFundChoiceAsync(t){return Jt().url("super-choice/default").post(t).badRequest((()=>{throw new Error("Failed to process default fund join request")})).text()}async submitCustomFundChoiceAsync(t){return Jt().url("super-choice/custom-fund").post(t).badRequest((()=>{throw new Error("Failed to process custom fund join request")})).text()}async submitSelfManagedFundChoiceAsync(t){return Jt().url("super-choice/smsf").post(t).badRequest((()=>{throw new Error("Failed to process SMSF choice request")})).text()}},pe=class{constructor(e){t(this,e),this.defaultFundProductName="Loading fund...",this.eventTrackingService=le.Instance}async componentWillLoad(){const t=Zt.defaultFundUsi;if(Et.isNone(t))return;this.isDefaultFundExists=!0;const e=await ce.getFundByUsiAsync(t.value);if(Et.isNone(e))return this.isInvalidDefaultFund=!0,void de.showErrorNotification({title:"Something is not right",description:`Couldn't find information about the configured default fund (USI ${t.value})`});this.defaultFund=e.value,this.defaultFundProductName=e.value.productName}componentDidLoad(){return this.eventTrackingService.TrackDefaultSuperFundDetailViewedAsync({fundUsi:this.defaultFund.usi,fundName:this.defaultFund.productName,promotedFundsShown:Zt.promotedFunds})}render(){return e(o,{class:"d-flex flex-fill"},e("sss-custom-fund",{class:"flex-fill"},e("form",{noValidate:!0,onSubmit:t=>t.preventDefault(),class:{"was-validated":"validated"===this.formState},ref:t=>this.formElement=t},this.isDefaultFundExists?e((t=>[e("div",{class:"card p-4"},e("p",{class:"font-weight-bold"},"Default Fund"),e("p",{class:"mb-4 small"},"Almost there... all you have to do now is review the fund below, complete and sign the super choice form and save. Your application to join the fund is subject to Trustee approval."),e("p",{class:"font-weight-bold mt-3"},"Default Fund Name"),e("p",null,t.defaultFundName)),e("sss-standard-choice-form",{onStandardChoiceFormSignatureUpdated:t=>{oe.defaultFundForm=Object.assign(Object.assign({},oe.defaultFundForm),t.detail)}})]),{defaultFundName:this.defaultFundProductName}):e((()=>e("div",{class:"card p-4"},e("p",{class:"font-weight-bold"},"No Default Fund"),e("p",{class:"mb-4 small"},"It looks like your employer has not yet defined a default fund. Please contact them if you wish to choose your company's default fund."))),null)),e("div",{class:"mt-4"},e("sss-notifications-section",null)),e("div",{class:"d-flex mt-4"},e("div",{class:"flex-grow-1 w-50"},e("div",{class:"mr-2"},e("fl-button",{onClick:()=>te.navigateInternally(this.history,ee.ChoicePage),isBlockElement:!0,variant:"secondary"},e("span",null,"Back")))),e("div",{class:"flex-grow-1 w-50"},this.isDefaultFundExists&&e("div",{class:"ml-2"},e("fl-promise-button",{isBlockElement:!0,disabled:this.isInvalidDefaultFund,promiseFn:()=>this.handleSubmitForm()},e("span",null,"Save and continue")))))))}async handleSubmitForm(){this.isInvalidDefaultFund||(this.formState="validated",this.formElement.checkValidity()&&(await he.submitDefaultFundChoiceAsync(oe.defaultFundForm),Zt.markSuperSelectionAsSubmitted(),te.navigateInternally(this.history,ee.Success)))}},me=class{constructor(e){t(this,e)}render(){return e("div",{class:"container mb-sm-0"},e("div",{class:"row justify-content-center pt-3 mt-3 mb-3 border-top"},e("div",{class:"text-decoration-none"},e("p",{class:"mt-3 small text-center mb-1 text-muted"},"Powered by Flare HR"))),e("div",{class:"row justify-content-center pb-sm-0 px-3 px-sm-0 text-center"},e("p",{class:"text-muted small"},"This page contains factual information only and does not take into account your particular objectives, financial circumstances or needs. If you have questions or need help making a decision about your super fund, you should speak to a licensed financial advice provider. You should consider the relevant super fund's PDS and TMD (if applicable) in deciding whether to apply to join the super fund. Each of the advertised fund's PDS and TMD (if applicable) can be found in their advertisements above. If you are considering joining another fund you can find the PDS and TMD on the fund's website. Your employer and Flare HR do not endorse or accept responsibility for any financial product advice or services provided by the promoters or trustees of the advertised superannuation funds. Flare HR do not endorse or accept responsibility for any of their content shown about any of the advertised superannuation funds as they are merely passing on the content as provided without any changes. Flare HR do not express any opinion or make any recommendation about any of the advertised funds.")),e("div",{class:"row justify-content-end my-1 px-3 px-sm-0"},this.appVersionBadge()))}appVersionBadge(){return e("small",{style:{opacity:"0.5"},class:"text-muted"},"Powered by Flare, v","3.40.56412")}};me.style="html{scroll-behavior:smooth}img.fluid-fit{-o-object-fit:cover;object-fit:cover}.ss-footer-logo{max-width:7rem}";const ve=class{constructor(e){t(this,e)}render(){return e(o,{class:"d-flex flex-column justify-content-center align-items-center flex-grow-1"},e("h5",null,"Loading your superannuation step"),e("fl-loading-indicator",null))}},be=class{constructor(e){t(this,e),this.isNotAllInformationProvidedMessageVisible=!1,this.eventTrackingService=le.Instance}componentDidLoad(){return this.eventTrackingService.TrackMyOwnSuperFundDetailViewedAsync({promotedFundsShown:Zt.promotedFunds})}render(){return e(o,{class:"d-flex flex-fill"},e("sss-custom-fund",{class:"flex-fill"},e("form",{noValidate:!0,onSubmit:t=>t.preventDefault(),class:{"was-validated":"validated"===this.formState},ref:t=>this.formElement=t},e("div",{class:"card p-4"},e("p",{class:"font-weight-bold"},"Fund details"),e("p",{class:"text-warning mb-4 small"},"Make sure you are already a member of the fund before completing this step."),e("sss-my-own-fund-inputs",{myOwnFundForm:oe.myOwnFundForm,onFormChanged:t=>{oe.myOwnFundForm=Object.assign(Object.assign({},oe.myOwnFundForm),t.detail),this.isNotAllInformationProvidedMessageVisible=!1}})),e("sss-standard-choice-form",{onStandardChoiceFormSignatureUpdated:t=>{oe.myOwnFundForm=Object.assign(Object.assign({},oe.myOwnFundForm),{standardChoiceFormSignature:z(t.detail.standardChoiceFormSignature)})}})),e("div",{class:"mt-4"},e("sss-notifications-section",null)),this.isNotAllInformationProvidedMessageVisible&&e("div",{class:"mt-4 alert alert-danger",role:"alert"},"All fields are required to complete submission. Make sure you have selected a fund."),e("div",{class:"d-flex mt-4"},e("div",{class:"flex-grow-1 w-50"},e("div",{class:"mr-2"},e("fl-button",{onClick:()=>te.navigateInternally(this.history,ee.ChoicePage),isBlockElement:!0,variant:"secondary"},e("span",null,"Back")))),e("div",{class:"flex-grow-1 w-50"},e("div",{class:"ml-2"},e("fl-promise-button",{isBlockElement:!0,promiseFn:()=>this.handleSubmitForm()},e("span",null,"Save and continue")))))))}async handleSubmitForm(){if(this.formState="validated",!this.formElement.checkValidity())return;if(!(D(oe.myOwnFundForm.fundUsi)&&D(oe.myOwnFundForm.memberNumber)&&D(oe.myOwnFundForm.standardChoiceFormSignature)))return void(this.isNotAllInformationProvidedMessageVisible=!0);const t={fundUsi:this.getOrError(oe.myOwnFundForm.fundUsi),memberNumber:this.getOrError(oe.myOwnFundForm.memberNumber),standardChoiceFormSignature:this.getOrError(oe.myOwnFundForm.standardChoiceFormSignature)};await he.submitCustomFundChoiceAsync(t),Zt.markSuperSelectionAsSubmitted(),te.navigateInternally(this.history,ee.Success)}getOrError(t){return jt.pipe(t,(e=()=>{throw new Error("Option value is none.")},function(t){return O(t)?e():t.value}));var e}static get assetsDirs(){return["assets"]}};H(be);const ge=class{constructor(e){t(this,e),this.formChanged=n(this,"formChanged",7),this.MIN_SEARCH_STRING_LENGTH=3,this.MAX_RECORD_COUNT=10,this.searchFundsAsync=async t=>(await ce.searchFundsAsync(t,this.MAX_RECORD_COUNT)).sort(((t,e)=>t.productName.localeCompare(e.productName))).map((t=>({label:`${t.productName} (${t.usi})`,value:t.usi})))}render(){return e("div",null,e("div",{class:""},e("label",{class:"mb-2 font-weight-bold"},"Superannuation Fund Name"),e("fl-dropdown-async",{searchFunction:this.searchFundsAsync,minSearchStringLength:this.MIN_SEARCH_STRING_LENGTH,required:!0,requiredValidationMessage:"Select a fund",placeholder:`Search by name or USI (type at least ${this.MIN_SEARCH_STRING_LENGTH} characters)`,value:this.selectedOption,onValueChanged:t=>{this.selectedOption=t.detail,this.updateFundUsi(t.detail.value.toString())}}),e("div",{class:"invalid-feedback"},"Select a fund"),D(this.myOwnFundForm.fundUsi)&&e("div",null,e("label",{class:"mb-2 mt-3 font-weight-bold"},"Superannuation Fund USI"),e("p",{class:"mb-0"},this.myOwnFundForm.fundUsi.value),e("p",{class:"small mt-1"},"Please ensure this is the correct fund USI as some funds have similar names"))),e("div",{class:"mt-4"},e("label",{class:"mb-2 font-weight-bold"},"Member Number"),e("input",{placeholder:"Enter your member number",type:"text",class:"form-control",required:!0,pattern:"[A-Za-z0-9]{4,16}",name:"memberNumber",id:"memberNumber",value:(t=oe.myOwnFundForm.memberNumber,O(t)?void 0:t.value),onChange:t=>this.updateMemberNumber(t.target.value.trim())}),e("div",{class:"invalid-feedback"},"Enter a valid member number (only numbers and / or letters)")));var t}updateFundUsi(t){this.formChanged.emit({fundUsi:L(t)})}updateMemberNumber(t){this.formChanged.emit({memberNumber:L(t)})}},we=class{constructor(e){t(this,e)}disconnectedCallback(){de.clearNotifications()}render(){const{items:t}=de.state;return t.length<=0?e(o,null):e("div",{class:"alert alert-"+t[0].type,role:"alert"},e("div",{class:"d-flex"},e("p",{class:"mb-0 flex-grow-1"},e("strong",null,t[0].details.title)),e("button",{onClick:this.handleClose,type:"button",class:"close pb-1","aria-label":"Close"},e("span",{"aria-hidden":"true"},"×"))),e("p",{class:"mb-0 mt-1"},t[0].details.description))}handleClose(){de.closeCurrent()}},{state:ye}=qt({fundId:"",memberNumber:"",usi:"",standardChoiceFormSignature:""}),xe=new class{constructor(){this.hostIsLocalSuperSelection=()=>"http://localhost:7100"==window.location.origin,this.environmentDiscriminator=()=>this.hostIsLocalSuperSelection()?"autodev-partner":window.location.hostname.toLowerCase().split(".")[0],this.promotedFundJoinAppUrl=()=>`https://${this.environmentDiscriminator()}.flarehr.com/promoted-fund-join/embed/v1.0/web`}build(t,e){if(!(null==t?void 0:t.contentDocument))return;const n=Object.assign(Object.assign({},this.getMemberData()),{partnerId:Zt.partnerIdOrDefault,accountId:Zt.accountIdOrDefault,fundId:ye.fundId,authToken:Zt.jwt}),i=n=>{const{data:r}=n;if(r)if("promoted-fund-redirect"!==r.sender){if("promoted-fund-join"===r.sender)switch(r.type){case"contentResized":t.height=r.height>0?r.height:t.height,t.width=r.width>0?r.width:t.width;break;case"pageNavigated":window.scroll(t.offsetLeft,t.offsetTop),kt(window.location.href)}}else switch(window.removeEventListener("message",i),r.type){case"cancel":te.navigateInternally(e,ee.ChoicePage);break;case"success":if(r.memberNumber){ye.memberNumber=r.memberNumber,ye.usi=r.usi,te.navigateInternally(e,ee.PromotedFundStandardChoice);break}default:te.navigateInternally(e,ee.ChoicePage)}};window.addEventListener("message",i);const r=t.contentDocument;r.open();const o=r.createElement("form");let s;for(s in o.method="POST",o.target="_self",o.action=this.promotedFundJoinAppUrl(),n){const t=n[s];if(void 0!==t){const e=document.createElement("input");e.type="hidden",e.name=s,e.value=t,o.append(e)}}r.appendChild(o),r.close(),o.submit()}getMemberData(){var t,e;const n=Zt.superBuyer;return{title:n.userProfile.title,firstName:n.userProfile.firstName,middleName:n.userProfile.middleName,lastName:n.userProfile.lastName,dateOfBirth:n.userProfile.dateOfBirth,gender:n.userProfile.gender,email:n.userProfile.email,mobilePhone:n.userProfile.mobilePhone,taxFileNumber:null!==(t=n.tfn)&&void 0!==t?t:"",addressLine1:n.userProfile.address.addressLine1,addressLine2:null!==(e=n.userProfile.address.addressLine2)&&void 0!==e?e:"",city:n.userProfile.address.city,state:n.userProfile.address.state,postCode:n.userProfile.address.postcode}}},ke=class{constructor(e){t(this,e)}componentDidLoad(){xe.build(this.iframeElement,this.history)}render(){return e(o,{class:"d-flex flex-fill"},e("iframe",{width:"100%",height:window.innerHeight,style:{border:"none"},ref:t=>this.iframeElement=t}))}},Se=new class{async submitChoiceAsync(t){return Jt().url("super-choice/promoted-fund").post(t).badRequest((()=>{throw new Error("Failed to process Promoted Fund choice request")})).text()}},Ce=class{constructor(e){t(this,e)}render(){return e(o,{class:"d-flex flex-fill"},e("div",{class:"container"},e("div",{class:"row justify-content-center"},e("div",{class:"col col-sm-10 col-md-7"},e("div",null,e("div",null,"You're almost done, simply sign the Standard Choice Form below to finalise your superannuation choice."),e("form",{noValidate:!0,onSubmit:t=>t.preventDefault(),class:{"was-validated":"validated"===this.formState},ref:t=>this.formElement=t},e("sss-standard-choice-form",{onStandardChoiceFormSignatureUpdated:t=>{ye.standardChoiceFormSignature=t.detail.standardChoiceFormSignature}})),e("div",{class:"d-flex mt-4"},e("div",{class:"flex-grow-1 w-50"},e("div",{class:"ml-2"},e("fl-promise-button",{isBlockElement:!0,promiseFn:()=>this.handleSubmitForm()},e("span",null,"Save and continue"))))))))))}async handleSubmitForm(){this.formState="validated",this.formElement.checkValidity()&&(await Se.submitChoiceAsync(Object.assign(Object.assign({},ye),{shownFunds:Zt.promotedFunds})),Zt.markSuperSelectionAsSubmitted(),te.navigateInternally(this.history,ee.Success))}},_e="60905115063001",Ae="https://qsuper.qld.gov.au/calculators-and-forms/publications/product-disclosure-statements",qe="https://slate.co/pds/?utm_source=flare&utm_medium=superselection",Be="https://www.australianretirementtrust.com.au/library/media/pdfs/pds/super-savings-product-disclosure-statement-and-membership-form.pdf",je="https://aware.com.au/member/forms-and-resources/pds",Ee=[{dtoPropName:"qSuper",id:"qsuper"},{dtoPropName:"slate",id:"slate"},{dtoPropName:"australianRetirementTrust",id:"australian-retirement-trust"},{dtoPropName:"aware",id:"aware"}],Ie=class{constructor(e){t(this,e),this.eventTrackingService=le.Instance}render(){return e("div",{class:"d-flex align-items-center justify-content-center"},e("p",{class:"confirm-title font-weight-bold text-center"},"You are now applying for a"," ",e("a",{target:"_blank",href:te.toExternalUrl("https://qsuper.qld.gov.au/-/media/pdfs/qsuper-public/publications/pds1.pdf")},"QSuper Accumulation Account"),". Read the"," ",e("a",{target:"_blank",onClick:()=>this.pdsViewedAsync(),href:te.toExternalUrl("https://qsuper.qld.gov.au/-/media/pdfs/qsuper-public/publications/pds11.pdf")},"PDS")," ","here."))}pdsViewedAsync(){return this.eventTrackingService.TrackSuperFundPdsViewedAsync({fundUsi:_e,fundName:"QSuper",pageName:"Insurance Opt In"})}static get assetsDirs(){return["assets"]}};var Fe,Pe;Ie.style="",function(t){t[t.InsuranceConfirm=0]="InsuranceConfirm",t[t.InsuranceQuestions=1]="InsuranceQuestions",t[t.AccumulationAccount=2]="AccumulationAccount",t[t.ConfirmSelection=3]="ConfirmSelection"}(Fe||(Fe={})),function(t){t[t.question1=0]="question1",t[t.question2=1]="question2",t[t.question3=2]="question3",t[t.question4=3]="question4",t[t.question5=4]="question5",t[t.question6=5]="question6",t[t.question7=6]="question7",t[t.question8=7]="question8"}(Pe||(Pe={}));const Te={currentQSuperInsuranceQuestion:Pe.question1,currentQSuperFormPage:Fe.InsuranceConfirm,qSuperFormValid:!1,nextRoute:"/",continueAllowed:!1,qSuperOptInPageCheckbox:!1,qSuperJoinPageCheckbox:!1,qSuperInsuranceQuestions:{question1:{answered:!1},question2:{answered:!1},question3:{answered:!1},question4:{answered:!1},question5:{answered:!1},question6:{answered:!1},question7:{answered:!1},question8:{answered:!1}},qSuperQuestionnaire:{reviewedApplication:!1,acceptedDeclaration:!1,readDutyOfDisclosure:!1,insuranceChosen:!1},standardChoiceFormSignature:""},{state:Me,reset:Re}=qt(Te),Ne=Re;function De(){var t,e,n,i;const r=window.location.pathname.split(Zt.appBaseUrl)[1],o={[ee.QSuperOptIn]:ee.QSuperQuestion1,[ee.QSuperQuestion1]:Me.qSuperInsuranceQuestions.question1.answered?!0===(null===(t=Me.qSuperQuestionnaire.questions)||void 0===t?void 0:t.question1)?ee.QSuperQuestion4:ee.QSuperQuestion2:ee.QSuperQuestion1,[ee.QSuperQuestion2]:Me.qSuperInsuranceQuestions.question2.answered?!0===(null===(e=Me.qSuperQuestionnaire.questions)||void 0===e?void 0:e.question2)?ee.QSuperQuestion4:ee.QSuperQuestion3:ee.QSuperQuestion2,[ee.QSuperQuestion3]:Me.qSuperInsuranceQuestions.question3.answered?ee.QSuperQuestion4:ee.QSuperQuestion3,[ee.QSuperQuestion4]:Me.qSuperInsuranceQuestions.question4.answered?ee.QSuperQuestion5:ee.QSuperQuestion4,[ee.QSuperQuestion5]:Me.qSuperInsuranceQuestions.question5.answered?ee.QSuperQuestion6:ee.QSuperQuestion5,[ee.QSuperQuestion6]:Me.qSuperInsuranceQuestions.question6.answered?ee.QSuperQuestion7:ee.QSuperQuestion6,[ee.QSuperQuestion7]:Me.qSuperInsuranceQuestions.question7.answered?ee.QSuperQuestion8:ee.QSuperQuestion7,[ee.QSuperQuestion8]:Me.qSuperInsuranceQuestions.question8.answered?ee.QSuperConsent:ee.QSuperQuestion8,[ee.QSuperConsent]:Me.qSuperQuestionnaire.readDutyOfDisclosure&&Me.qSuperQuestionnaire.reviewedApplication?ee.QSuperJoin:ee.QSuperConsent,[ee.QSuperJoin]:Me.qSuperJoinPageCheckbox?ee.Success:ee.QSuperJoin};return r===ee.QSuperQuestion5?Me.qSuperInsuranceQuestions.question1.answered&&Me.qSuperInsuranceQuestions.question2.answered&&Me.qSuperInsuranceQuestions.question3.answered&&Me.qSuperInsuranceQuestions.question4.answered&&Me.qSuperInsuranceQuestions.question5.answered&&(!0===(null===(n=Me.qSuperQuestionnaire.questions)||void 0===n?void 0:n.question3)||!0===(null===(i=Me.qSuperQuestionnaire.questions)||void 0===i?void 0:i.question5))?ee.QSuperQuestion6:ee.QSuperConsent:r===ee.QSuperOptIn?Me.qSuperOptInPageCheckbox?Me.qSuperQuestionnaire.insuranceChosen?ee.QSuperQuestion1:ee.QSuperConsent:r:o[r]}const Oe=class{constructor(e){t(this,e),this.eventTrackingService=le.Instance}async componentDidLoad(){window.scroll(0,0),Me.currentQSuperFormPage=Fe.AccumulationAccount}render(){return e("sss-qsuper-layout",null,e("div",{class:"d-flex align-items-center justify-content-center"},e("p",{class:"confirm-title font-weight-bold text-center"},"Your QSuper Accumulation Account")),e("div",{class:"p-3 d-flex mt-4 checkbox-container"},e("p",null,"Just finally, we need you to confirm that you understand the declarations below and the product you've applied for by ticking the box below.",e("br",null),e("br",null),"This form and all products are issued by the QSuper Board (ABN 32 125 059 006 AFSL 489650) as trustee for QSuper (ABN 60 905 115 063).",e("br",null),e("br",null),"I have read and agree to the terms and conditions in the QSuper"," ",e("a",{target:"_blank",onClick:()=>this.pdsViewedAsync(),href:te.toExternalUrl("https://qsuper.qld.gov.au/-/media/pdfs/qsuper-public/publications/pds11.pdf")},"Product Disclosure Statement for Accumulation and Income Accounts"),", QSuper's"," ",e("a",{target:"_blank",href:te.toExternalUrl("https://qsuper.qld.gov.au/-/media/pdfs/qsuper-public/publications/fs15.pdf")},"Your Privacy factsheet"),", and the"," ",e("a",{target:"_blank",href:te.toExternalUrl("https://qsuper.qld.gov.au/-/media/pdfs/qsuper-public/publications/qiib09.pdf")},"Financial Services Guide"),".",e("br",null),e("br",null),"I understand that any insurance cover I might have as a result of this application, commences when the first contribution is received into my account. Once I am a member I can cancel, or, subject to eligibility conditions, vary, my cover at any time. Premiums are deducted in accordance with the PDS.",e("br",null),e("br",null),"I also agree to be bound by the Trust Deed and the governing rules of QSuper in relation to the operation of my Accumulation account.",e("br",null),e("br",null),"I confirm that the information I have given is true and correct.",e("br",null),e("br",null),"I confirm that I am the person identified as the applicant in this form.",e("br",null),e("br",null),"I consent to the QSuper Board paying Simple Financial Choices Pty Ltd, a wholly owned subsidiary of Flare, a fee of $300 on receipt of the first contribution into my account, for the provision of technology services.",e("br",null),e("br",null),"I understand that I will be placed into the default investment option QSuper Lifetime.",e("br",null),e("br",null),"I understand that my Tax File Number will be provided to QSuper. NB - if you have your Tax File Number available, this will help speed up the processing of this application and we may be able to Find your Super.",e("br",null),e("br",null),"I have read and accept the"," ",e("a",{target:"_blank",href:te.toExternalUrl("https://qsuper.qld.gov.au/misc/tfn")},"Privacy and Contact Information Statement"))),e("div",null,e("label",{class:"d-flex mt-3 p-3 checkbox-container",htmlFor:"ackAllCheckBox"},e("div",{class:"w-auto px-2 fl-checkbox-container"},e("input",{id:"ackAllCheckBox",class:"confirm-checkbox-item",type:"checkbox",onChange:()=>this.handleCheckboxToggle()})),e("div",{class:"pl-3"},e("p",{class:"confirm-item-text mb-0 mt-1"},"I acknowledge all of the above. ",e("i",null,"(required)"))))))}handleCheckboxToggle(){Me.qSuperQuestionnaire.readDutyOfDisclosure=!Me.qSuperQuestionnaire.readDutyOfDisclosure,Me.qSuperQuestionnaire.reviewedApplication=!Me.qSuperQuestionnaire.reviewedApplication,Me.continueAllowed=!Me.continueAllowed,Me.nextRoute=De()}pdsViewedAsync(){return this.eventTrackingService.TrackSuperFundPdsViewedAsync({fundUsi:_e,fundName:"QSuper",pageName:"Accumulation Page"})}};function Ue(){const t=window.location.pathname.split(Zt.appBaseUrl)[1];Me.continueAllowed={[ee.QSuperOptIn]:Me.qSuperOptInPageCheckbox,[ee.QSuperJoin]:Me.qSuperJoinPageCheckbox&&Me.standardChoiceFormSignature}[t]}function Le(){Ne(),Me.qSuperQuestionnaire=Object.assign(Object.assign({},Me.qSuperQuestionnaire),{acceptedDeclaration:!1,insuranceChosen:!1,readDutyOfDisclosure:!1,reviewedApplication:!1}),Me.qSuperInsuranceQuestions={question1:{answered:!1},question2:{answered:!1},question3:{answered:!1},question4:{answered:!1},question5:{answered:!1},question6:{answered:!1},question7:{answered:!1},question8:{answered:!1}}}Oe.style="html{scroll-behavior:smooth}img.fluid-fit{-o-object-fit:cover;object-fit:cover}.choice-container{margin-top:0 !important;margin-bottom:0 !important}.confirm-title{font-size:20px;margin-bottom:0}.confirm-text{font-size:14px}.edit-toggle{cursor:pointer}.form-value-text{overflow-wrap:anywhere}.confirm-checkbox-item{-webkit-transform:scale(1.7);transform:scale(1.7)}.checkbox-container{border-radius:4px;background-color:#f5f4f2}.confirm-item-text{font-size:13px}.button-holder{min-width:8rem}.confirm-form-view-only-holder *{font-size:14px}";const ze=class{constructor(e){t(this,e),this.insuranceChosen=!1,this.eventTrackingService=le.Instance,this.isEligibleForInsurance=!1}componentDidLoad(){return this.eventTrackingService.TrackFinancialProductViewedAsync({fundUsi:_e,fundName:"QSuper",financialProduct:"QSuper Insurance"})}componentWillLoad(){Le(),this.ensureInsuranceEligibility()}render(){return e(o,{class:"d-flex flex-fill"},e("sss-qsuper-layout",{class:"d-flex flex-fill"},e("sss-qsuper-confirm-header",null),e("div",{class:"mt-4 p-3 checkbox-container"},e("p",null,"As part of becoming a QSuper member, you will receive death cover and total and permanent disability cover when you become eligible. ",e("br",null),e("br",null),"You will receive this cover when: ",e("br",null),e("br",null),"You are 25 years or older; ",e("br",null),"and You have had at least $6,000 in your accumulation account; ",e("br",null),"and At that time, we have received money into your account within the previous 13 months ",e("br",null),e("br",null),"Please see the Accumulation Account Insurance Guide, available on the QSuper website, for further information ",e("br",null),e("br",null),"Do you want this insurance cover?"),e("div",{class:"d-flex justify-content-between mt-4"},e("div",{class:"button-holder flex-grow-1 mr-2"},e("fl-button",{disabled:!this.isEligibleForInsurance,isBlockElement:!0,variant:this.insuranceChosen?"primary":"secondary",onClick:()=>this.handleInsuranceToggle(!0)},"Yes")),e("div",{class:"button-holder flex-grow-1 ml-2"},e("fl-button",{disabled:!this.isEligibleForInsurance,isBlockElement:!0,variant:this.insuranceChosen?"secondary":"primary",onClick:()=>this.handleInsuranceToggle(!1)},"No")))),e("div",null,e("label",{class:"d-flex mt-3 p-3 checkbox-container",htmlFor:"ackCheckBox"},e("div",{class:"w-auto px-2 fl-checkbox-container"},e("input",{id:"ackCheckBox",class:"confirm-checkbox-item",type:"checkbox",onChange:()=>this.handleCheckboxToggle()})),e("div",{class:"pl-3"},e("p",{class:"confirm-item-text mb-0"},"I acknowledge that my personal information will be shared with QSuper as part of their application process."))))))}ensureInsuranceEligibility(){Zt.superBuyer.userProfile.yearsOfAge<14||(Zt.superBuyer.userProfile.yearsOfAge<16?this.showIneligibleNotification("You may still apply for QSuper, however people under the age of 16 are not able to apply for insurance."):this.isEligibleForInsurance=!0)}showIneligibleNotification(t){de.showInfoNotification({title:"Unable to apply for Insurance",description:t})}handleInsuranceToggle(t){Me.qSuperQuestionnaire.insuranceChosen=t&&this.isEligibleForInsurance,this.insuranceChosen=Me.qSuperQuestionnaire.insuranceChosen,Me.nextRoute=De()}handleCheckboxToggle(){Me.qSuperOptInPageCheckbox=!Me.qSuperOptInPageCheckbox,Ue(),Me.nextRoute=De()}};ze.style="html{scroll-behavior:smooth}img.fluid-fit{-o-object-fit:cover;object-fit:cover}.choice-container{margin-top:0 !important;margin-bottom:0 !important}.confirm-title{font-size:20px;margin-bottom:0}.confirm-text{font-size:14px}.edit-toggle{cursor:pointer}.form-value-text{overflow-wrap:anywhere}.confirm-checkbox-item{-webkit-transform:scale(1.7);transform:scale(1.7)}.checkbox-container{border-radius:4px;background-color:#f5f4f2}.confirm-item-text{font-size:13px}.button-holder{min-width:8rem}.confirm-form-view-only-holder *{font-size:14px}";const Ve=class{constructor(e){t(this,e)}render(){return e(o,{class:"d-flex flex-fill"},e("sss-qsuper-layout",{class:"d-flex flex-fill"},e("sss-qsuper-confirm-header",null),e("div",{class:"p-3 mt-4 checkbox-container"},e("slot",null),e("sss-qsuper-question-yes-no-buttons",null))))}};Ve.style="html{scroll-behavior:smooth}img.fluid-fit{-o-object-fit:cover;object-fit:cover}.choice-container{margin-top:0 !important;margin-bottom:0 !important}.confirm-title{font-size:20px;margin-bottom:0}.confirm-text{font-size:14px}.edit-toggle{cursor:pointer}.form-value-text{overflow-wrap:anywhere}.confirm-checkbox-item{-webkit-transform:scale(1.7);transform:scale(1.7)}.checkbox-container{border-radius:4px;background-color:#f5f4f2}.confirm-item-text{font-size:13px}.button-holder{min-width:8rem}.confirm-form-view-only-holder *{font-size:14px}";const He=class{constructor(e){t(this,e),this.eventTrackingService=le.Instance}render(){return e("sss-qsuper-layout",null,e("img",{class:"ss-choice-logo mx-auto",alt:"Simple Financial Choices Pty Ltd",src:s("assets/logo-qsuper.png")}),e("div",{class:"row"},e("div",{class:"col text-center"},e("p",{class:"confirm-title font-weight-bold mb-0"},"You have chosen to join QSuper"))),e("div",{class:"my-3 card p-3"},e("p",{class:"confirm-text"},"We are almost there... All you have to do now is sign the super choice form. We'll prefill it for you. Make sure the info is correct. Your application to join the fund is subject to Trustee approval."),e("p",{class:"confirm-text mb-0"},"You've chosen to stay with your existing fund. Review the details below and click continue to confirm your choice")),e("div",{class:"card p-3"},e("p",{class:"text-center"},"100 years strong"),e("p",{class:"text-center"},"One of Australia's largest funds"),e("p",{class:"text-center mb-0"},"Awarded SuperRatings highest performance rating")),e("div",{class:"mt-3"},e("p",{class:"text-center confirm-text"},"Your application to join the fund is subject to Trustee approval.")),e("div",null,e("label",{class:"d-flex mt-4 p-3 checkbox-container",htmlFor:"confirmCheckBox"},e("div",{class:"w-auto px-2 py-2 fl-checkbox-container"},e("input",{id:"confirmCheckBox",class:"confirm-checkbox-item",type:"checkbox",onChange:()=>this.handleCheckboxToggle()})),e("div",{class:"pl-3"},e("p",{class:"confirm-item-text mb-0 mt-1"},"I've read and understood the"," ",e("a",{target:"_blank",onClick:()=>this.pdsViewedAsync(),href:te.toExternalUrl("https://qsuper.qld.gov.au/calculators-and-forms/publications/product-disclosure-statements/")},"PDS")," ","and confirm all information I have provided is true and correct. I understand that my information will be sent to the trustee of this fund to process my request to join and I consent to my TFN, as currently held on the Flare HR Platform, being given to the trustee in order to open and administer my account.")))),e("sss-standard-choice-form",{onStandardChoiceFormSignatureUpdated:t=>{Me.standardChoiceFormSignature=t.detail.standardChoiceFormSignature,Ue()}}))}handleCheckboxToggle(){Me.qSuperJoinPageCheckbox=!Me.qSuperJoinPageCheckbox,Ue(),Me.nextRoute=De()}pdsViewedAsync(){return this.eventTrackingService.TrackSuperFundPdsViewedAsync({fundUsi:_e,fundName:"QSuper",pageName:"Confirm Page"})}};He.style="html{scroll-behavior:smooth}img.fluid-fit{-o-object-fit:cover;object-fit:cover}.checkbox-container{border-radius:4px;background-color:#f5f4f2}.confirm-checkbox-item{-webkit-transform:scale(1.7);transform:scale(1.7)}.simple-choices-text{color:#489882}.choice-card{background:#ffffff;-webkit-box-shadow:0 1px 4px rgba(0, 0, 0, 0.25);box-shadow:0 1px 4px rgba(0, 0, 0, 0.25);border-radius:3px}.choice-card.ss-picked-fund{border:2px solid var(--fl-color-primary)}.card.ss-picked-fund{border:2px solid var(--fl-color-primary)}.ss-choice-logo{width:auto;max-height:70px;-o-object-fit:contain;object-fit:contain}img{width:100%;display:block}.choice-component{width:100%;position:relative}.flexible{-ms-flex-positive:1;flex-grow:1}.fund-item{margin-top:1rem}.promoted-picked-block{background-color:var(--fl-color-primary);border-bottom-right-radius:3px;left:0;top:0}@media (min-width: 992px){.bottom-half-fund-tile{height:220px}}";const Qe=new class{async submitQSuperChoiceAsync(t){return Jt().url("super-choice/qsuper").post(t).badRequest((()=>{throw new Error("Failed to process QSuper join request")})).text()}},We=class{constructor(e){t(this,e),this.isEligible=!1,this.canContinue=()=>this.isEligible&&Me.continueAllowed,this.ensureEligibility=()=>{Zt.superBuyer.userProfile.yearsOfAge<14?this.showIneligibleNotification("People under the age of 14 are not able to open accounts."):Zt.superBuyer.userProfile.yearsOfAge>70?this.showIneligibleNotification("People over the age of 70 are not able to open accounts."):this.isEligible=!0},this.showIneligibleNotification=t=>{de.showInfoNotification({title:"Unable to apply for QSuper",description:t})}}async componentWillLoad(){this.ensureEligibility(),Me.nextRoute=De()}render(){return e("div",{class:"container"},e("div",{class:"row justify-content-center"},e("div",{class:"col col-sm-10 col-md-7"},e("slot",null),e("div",{class:"mt-4"},e("sss-notifications-section",null)),e("div",{class:"d-flex mt-4"},e("div",{class:"flex-grow-1 w-50"},e("div",{class:"mr-2"},e("fl-button",{onClick:()=>te.navigateInternally(this.history,ee.ChoicePage),isBlockElement:!0,variant:"secondary"},e("span",null,"Back")))),e("div",{class:"flex-grow-1 w-50"},e("div",{class:"ml-2"},e("fl-promise-button",{isBlockElement:!0,disabled:!this.canContinue(),promiseFn:()=>this.tryAsync()},e("span",null,"Continue"))))))))}async tryAsync(){try{if(!this.canContinue())return;await async function(){if(Me.continueAllowed)if(Me.continueAllowed=!1,Me.currentQSuperFormPage===Fe.InsuranceConfirm&&Me.qSuperQuestionnaire.insuranceChosen)Me.currentQSuperFormPage=Fe.InsuranceQuestions;else if(Me.currentQSuperFormPage!==Fe.InsuranceConfirm||Me.qSuperQuestionnaire.insuranceChosen)if(Me.currentQSuperFormPage!==Fe.InsuranceQuestions){if(Me.currentQSuperFormPage===Fe.AccumulationAccount)return Me.qSuperFormValid=!1,void(Me.currentQSuperFormPage=Fe.ConfirmSelection);if(Me.currentQSuperFormPage===Fe.ConfirmSelection){Me.qSuperQuestionnaire.acceptedDeclaration=!0;const t={questionnaire:Me.qSuperQuestionnaire,standardChoiceFormSignature:Me.standardChoiceFormSignature,shownFunds:Zt.promotedFunds};await Qe.submitQSuperChoiceAsync(t),Zt.markSuperSelectionAsSubmitted()}}else Me.currentQSuperFormPage=Fe.AccumulationAccount;else Me.currentQSuperFormPage=Fe.AccumulationAccount}(),te.navigateInternally(this.history,Me.nextRoute)}catch(t){de.showErrorNotification({title:"Couldn't process your request",description:"We had an issue processing your request to join QSuper. Please try again shortly."}),Me.continueAllowed=!0}}static get assetsDirs(){return["assets"]}};H(We);const $e=class{constructor(e){t(this,e)}render(){return e(o,{class:"d-flex flex-fill"},e("sss-qsuper-insurance-questions",null,e("p",{class:"font-weight-bold"},"Question 1"),e("p",{class:" mb-0"},"Are you currently a registered or enrolled nurse or assistant in nursing who is qualified and currently practicing, or working in the retail sector, or food and beverage service?")))}},Ye=class{constructor(e){t(this,e)}render(){return e(o,{class:"d-flex flex-fill"},e("sss-qsuper-insurance-questions",null,e("p",{class:"font-weight-bold"},"Question 2"),e("p",{class:" mb-0"},"Are you currently a qualified tradesperson currently working within your area of expertise (e.g. hairdresser, chef, plumber, electrician, plasterer, carpenter or concreter), or a skilled worker with light manual duties (e.g. jeweller, building inspector, laboratory technician, foreman or office equipment technician)?")))}},Xe=class{constructor(e){t(this,e)}render(){return e(o,{class:"d-flex flex-fill"},e("sss-qsuper-insurance-questions",null,e("p",{class:"font-weight-bold"},"Question 3"),e("p",{class:" mb-0"},"Are you currently a police officer, firefighter, paramedic, or other emergency or protective services worker, including security guard or corrections officer, or a professional sportsperson, or working in a manual occupation which does not require trade specific qualifications and may be subject to accident or environment hazards (e.g. earthmover, driver, cleaner, labourer, factory worker or agricultural worker)?")))}},Je=class{constructor(e){t(this,e)}render(){return e(o,{class:"d-flex flex-fill"},e("sss-qsuper-insurance-questions",null,e("p",{class:"font-weight-bold"},"Question 4"),e("p",{class:" mb-0"},"Are the usual work activities of your job considered office based or school teaching ( meaning you spend at least 80% of your work time doing clerical, call centre, administrative or other office or classroom based activities), or are you a medical practitioner, lawyer or engineer who spends at least 80% of your work hours in an office or clinical environment?")))}},Ge=class{constructor(e){t(this,e)}render(){return e(o,{class:"d-flex flex-fill"},e("sss-qsuper-insurance-questions",null,e("p",{class:"font-weight-bold"},"Question 5"),e("p",{class:" mb-0"},"Do you currently perform, or intend to work in a job within the next three months that includes, any of the following risky activities: handling firearms (other than as a police officer, correctional officer or licensed security guard), dangerous chemicals or explosives, or offshore work – oil and gas platforms, ships at sea, or being underground (in construction and mining environments) or underwater for more than 20% of total at work time, or working at heights over 20 metres in any environment requiring hard hat and harness for safety by law, or crop dusting, aerial mustering or any low level flying activity (defined as below 150 metres or 500 feet), or flying more than 200 hours per annum as a passenger other than on a commercial airline, or as a pilot (fixed wing or helicopter)?")))}},Ke=class{constructor(e){t(this,e)}render(){return e(o,{class:"d-flex flex-fill"},e("sss-qsuper-insurance-questions",null,e("p",{class:"font-weight-bold"},"Question 6"),e("p",{class:" mb-0"},"Are you earning more than $120,000 a year, (before tax and employer paid superannuation), from your job?")))}},Ze=class{constructor(e){t(this,e)}render(){return e(o,{class:"d-flex flex-fill"},e("sss-qsuper-insurance-questions",null,e("p",{class:"font-weight-bold"},"Question 7"),e("p",{class:" mb-0"},"Do you have a university qualification which you are using/is required in your current role?")))}},tn=class{constructor(e){t(this,e)}render(){return e(o,{class:"d-flex flex-fill"},e("sss-qsuper-insurance-questions",null,e("p",{class:"font-weight-bold"},"Question 8"),e("p",{class:" mb-0"},"Do you have a senior/executive level management role in your company (your direct reports would be mid-level managers or skilled specialists in a sedentary setting), or is your role considered professional (e.g. doctor, solicitor, accountant – requiring membership of a professional or government body to practice in your occupation)?")))}},en=class{constructor(e){t(this,e)}render(){return e("div",{class:"d-flex mt-4"},e("div",{class:"flex-grow-1 w-50"},e("div",{class:"mr-2"},e("fl-button",{onClick:()=>this.handleQuestionClick(!0),isBlockElement:!0,variant:"secondary"},e("span",null,"Yes")))),e("div",{class:"flex-grow-1 w-50"},e("div",{class:"ml-2"},e("fl-promise-button",{isBlockElement:!0,variant:"secondary",onClick:()=>this.handleQuestionClick(!1)},e("span",null,"No")))))}handleQuestionClick(t){const e=window.location.pathname.split(Zt.appBaseUrl+"/qsuper/insurance/")[1].replace(/\/+$/,"");void 0===Me.qSuperQuestionnaire.questions&&(Me.qSuperQuestionnaire.questions={question1:!1,question2:!1,question3:!1,question4:!1,question5:!1,question6:!1,question7:!1,question8:!1}),Me.qSuperQuestionnaire.questions[e]=t,Me.qSuperInsuranceQuestions[e].answered=!0,Me.nextRoute=De(),te.navigateInternally(this.history,Me.nextRoute)}};H(en);const nn=class{constructor(e){t(this,e)}render(){return e(o,{class:"bg-white rounded-sm picked-box-border p-3"},e("div",{class:"d-flex"},e("div",{class:"flex-grow-1 font-weight-bold"},this.fundType),e("div",{class:"px-3 py-2 text-white picked-block position-absolute"},"You picked")),e("div",null,this.fundName))}};nn.style="html{scroll-behavior:smooth}img.fluid-fit{-o-object-fit:cover;object-fit:cover}.picked-block{background-color:var(--fl-color-primary);border-top-right-radius:3px;right:0;top:0}.picked-box-border{border:2px solid var(--fl-color-primary)}";const rn=class{constructor(e){t(this,e),this.showSmsfNotSupported=!1,this.eventTrackingService=le.Instance,this.success=()=>{Zt.markSuperSelectionAsSubmitted(),te.navigateInternally(this.history,ee.Success)}}componentDidLoad(){return this.eventTrackingService.TrackSmsfSuperFundDetailViewedAsync({promotedFundsShown:Zt.promotedFunds})}render(){return e(o,{class:"d-flex flex-fill"},e("sss-custom-fund",{class:"flex-fill"},e("form",{noValidate:!0,onSubmit:t=>t.preventDefault(),class:{"was-validated":"validated"===this.formState},ref:t=>this.formElement=t},e("div",{class:"card p-4"},e("p",{class:"font-weight-bold"},"Fund details"),e("p",{class:"text-warning mb-4 small"},"Make sure you are already a member of the fund before completing this step."),e("sss-self-managed-fund-inputs",{fundForm:oe.selfManagedFundForm,onFormChanged:t=>{oe.selfManagedFundForm=Object.assign(Object.assign({},oe.selfManagedFundForm),t.detail)}})),e("sss-standard-choice-form",{onStandardChoiceFormSignatureUpdated:t=>{oe.selfManagedFundForm=Object.assign(Object.assign({},oe.selfManagedFundForm),t.detail)}}),this.showSmsfNotSupported&&e("sss-smsf-not-supported-dialog",{ref:t=>this.notSupportedDialog=t,onContinue:this.success})),e("div",{class:"mt-4"},e("sss-notifications-section",null)),e("div",{class:"d-flex mt-4"},e("div",{class:"flex-grow-1 w-50"},e("div",{class:"mr-2"},e("fl-button",{onClick:()=>te.navigateInternally(this.history,ee.ChoicePage),isBlockElement:!0,variant:"secondary"},e("span",null,"Back")))),e("div",{class:"flex-grow-1 w-50"},e("div",{class:"ml-2"},e("fl-promise-button",{isBlockElement:!0,promiseFn:()=>this.handleSubmitForm()},e("span",null,"Save and continue")))))))}componentDidRender(){var t;this.showSmsfNotSupported&&(null===(t=this.notSupportedDialog)||void 0===t||t.scrollIntoView())}async handleSubmitForm(){if(this.formState="validated",this.formElement.checkValidity()){const t={smsfChoice:{abn:oe.selfManagedFundForm.fundAbn,fundName:oe.selfManagedFundForm.fundName,fundAddress:{addressLine1:oe.selfManagedFundForm.addressLine1,addressLine2:oe.selfManagedFundForm.addressLine2,city:oe.selfManagedFundForm.city,state:oe.selfManagedFundForm.state,postcode:oe.selfManagedFundForm.postcode},bsb:oe.selfManagedFundForm.bsb,bankAccountName:oe.selfManagedFundForm.bankAccountName,bankAccountNumber:oe.selfManagedFundForm.bankAccountNumber,electronicServiceAddress:oe.selfManagedFundForm.fundEsa},standardChoiceFormSignature:oe.selfManagedFundForm.standardChoiceFormSignature};await he.submitSelfManagedFundChoiceAsync(t),Zt.showSmsfNotSupported?this.showSmsfNotSupported=!0:this.success()}}};H(rn);const on={"01":"Australia and New Zealand Banking Group","03":"Westpac Banking Corporation",73:"Westpac Banking Corporation","06":"Commonwealth Bank of Australia",76:"Commonwealth Bank of Australia","08":"National Australia Bank",78:"National Australia Bank","09":"Reserve Bank of Australia",10:"BankSA (division of Westpac Bank)",11:"St George Bank (division of Westpac Bank)",33:"St George Bank (division of Westpac Bank)",12:"Bank of Queensland",14:"Rabobank",15:"Town & Country Bank",18:"Macquarie Bank",19:"Bank of Melbourne (division of Westpac Bank)",55:"Bank of Melbourne (division of Westpac Bank)",21:"JP Morgan Chase Bank",22:"BNP Paribas",23:"Bank of America",24:"Citibank & Citibank NA",510:"Citibank & Citibank NA",25:"BNP Paribas Securities",26:"Bankers Trust Australia (division of Westpac Bank)",29:"MUFG Bank",30:"Bankwest (division of Commonwealth Bank)",31:"Bank Australia",325:"Beyond Bank",34:"HSBC Bank Australia",985:"HSBC Bank Australia",35:"Bank of China",980:"Bank of China",40:"Commonwealth Bank of Australia",41:"Deutsche Bank",42:"Commonwealth Bank of Australia",52:"Commonwealth Bank of Australia",45:"OCBC Bank",46:"Advance Bank (division of Westpac Bank)",47:"Challenge Bank (division of Westpac Bank)",48:"Suncorp-Metway",664:"Suncorp-Metway",512:"Community First Credit Union",514:"RACQ Bank",517:"Volt Bank",533:"Bananacoast Community Credit Union",57:"Australian Settlements",61:"Adelaide Bank (division of Bendigo and Adelaide Bank)",611:"Endeavour Mutual Bank",823:"Endeavour Mutual Bank",630:"Greater Bank",637:"Greater Bank",632:"B&E",633:"Bendigo Bank",634:"Uniting Financial Services",638:"Heritage Bank",880:"Heritage Bank",639:"Home Building Society (division of Bank of Queensland)",640:"Hume Bank",641:"IMB",647:"IMB",642:"Australian Military Bank",645:"Auswide Bank",656:"Auswide Bank",646:"Maitland Mutual Building Society",650:"Newcastle Permanent Building Society",653:"Pioneer Permanent Building Society (division of Bank of Queensland)",654:"Queensland Country Credit Union",655:"The Rock",659:"G&C Mutual Bank",676:"Gateway Bank",70:"Indue",721:"Holiday Coast Credit Union",722:"Southern Cross Credit Union",723:"Bank of Heritage Isle",724:"MOVE",728:"Summerland Credit Union",777:"Police & Nurse",80:"Cuscal",670:"Cuscal",812:"Teachers Mutual Bank",813:"Capricornian",814:"Credit Union Australia",815:"Police Bank",817:"Warwick Credit Union",818:"Bank of Communications",819:"Industrial & Commercial Bank of China",824:"Sutherland Credit Union",825:"Big Sky Building Society",833:"Defence Bank",882:"Unity Bank",888:"China Construction Bank",90:"Australia Post",911:"Sumitomo Mitsui Banking Corporation",913:"State Street Bank & Trust Company",917:"Arab Bank Australia",918:"Mizuho Bank",922:"United Overseas Bank",923:"ING Bank",936:"ING Bank",931:"Mega International Commercial Bank",932:"Regional Australia Bank",939:"AMP Bank",941:"Delphi Bank (division of Bendigo and Adelaide Bank)",942:"Bank of Sydney",943:"Taiwan Business Bank",944:"Members Equity Bank",946:"UBS AG",951:"BOQ Specialist",969:"Tyro Payments"},sn=class{constructor(e){t(this,e),this.formChanged=n(this,"formChanged",7),this.currentBank=U,this.stateOptions=[{value:"NSW",label:"NSW"},{value:"QLD",label:"QLD"},{value:"ACT",label:"ACT"},{value:"VIC",label:"VIC"},{value:"TAS",label:"TAS"},{value:"WA",label:"WA"},{value:"SA",label:"SA"},{value:"NT",label:"NT"}],this.bsbRegex=new RegExp(/^[0-9]{3}[0-9]{3}$/),this.bankAccountNumberRegex=new RegExp(/^[0-9]{2,10}$/)}render(){return e("div",null,e("div",{class:"mt-4"},e("label",{class:"mb-2 font-weight-bold"},"Fund name *"),e("input",{placeholder:"Enter your fund name",type:"text",class:"form-control",required:!0,minlength:"2",name:"fundName",id:"fundName",value:oe.selfManagedFundForm.fundName,onChange:t=>this.updateFormField("fundName",t.target.value.trim())}),e("div",{class:"invalid-feedback"},"Enter a valid fund name")),e("div",{class:"mt-4"},e("label",{class:"mb-2 font-weight-bold"},"Fund ABN *"),e("input",{placeholder:"Enter your fund ABN",type:"text",class:"form-control",required:!0,minlength:"2",name:"fundAbn",id:"fundAbn",value:oe.selfManagedFundForm.fundAbn,onChange:t=>this.updateFormField("fundAbn",t.target.value.trim())}),e("div",{class:"invalid-feedback"},"Enter a valid fund ABN")),e("div",{class:"mt-4"},e("label",{class:"mb-2 font-weight-bold"},"Electronic service address alias (ESA) *"),e("input",{placeholder:"Enter your ESA",type:"text",class:"form-control",required:!0,minlength:"2",name:"fundEsa",id:"fundEsa",value:oe.selfManagedFundForm.fundEsa,onChange:t=>this.updateFormField("fundEsa",t.target.value.trim())}),e("div",{class:"invalid-feedback"},"Enter a valid fund ESA")),e("div",{class:"mt-4"},e("label",{class:"mb-2 font-weight-bold"},"Address line 1 *"),e("input",{placeholder:"Enter your address",type:"text",class:"form-control",required:!0,minlength:"2",name:"addressLine1",id:"addressLine1",value:oe.selfManagedFundForm.addressLine1,onChange:t=>this.updateFormField("addressLine1",t.target.value.trim())}),e("div",{class:"invalid-feedback"},"Enter a valid address")),e("div",{class:"mt-4"},e("label",{class:"mb-2 font-weight-bold"},"Address line 2 (optional)"),e("input",{placeholder:"Enter your address",type:"text",class:"form-control",name:"addressLine2",id:"addressLine2",value:oe.selfManagedFundForm.addressLine2,onChange:t=>this.updateFormField("addressLine2",t.target.value.trim())}),e("div",{class:"invalid-feedback"},"Enter a valid address")),e("div",{class:"mt-4"},e("label",{class:"mb-2 font-weight-bold"},"City/suburb *"),e("input",{placeholder:"Enter your city",type:"text",class:"form-control",name:"city",required:!0,id:"city",value:oe.selfManagedFundForm.city,onChange:t=>this.updateFormField("city",t.target.value.trim())}),e("div",{class:"invalid-feedback"},"Enter a valid city/suburb *")),e("div",{class:"mt-3"},e("label",{class:"mb-2 font-weight-bold"},"State *"),e("select",{class:"form-control",name:"state",required:!0,id:"state",onChange:t=>{this.updateFormField("state",t.target.value.trim())}},e("option",{disabled:!0,selected:!this.fundForm.state,value:""},"Select a state"),this.stateOptions.map((t=>e("option",{value:t.value,selected:this.fundForm.state===t.value},t.label)))),e("div",{class:"invalid-feedback"},"Select a state")),e("div",{class:"mt-4"},e("label",{class:"mb-2 font-weight-bold"},"Post code *"),e("input",{placeholder:"Enter your post code",type:"text",required:!0,class:"form-control",name:"postcode",minlength:"4",maxlength:"4",pattern:"[0-9]{4}",id:"postcode",value:oe.selfManagedFundForm.postcode,onChange:t=>this.updateFormField("postcode",t.target.value.trim())}),e("div",{class:"invalid-feedback"},"Enter a valid post code")),e("div",null,e("i",{class:"fas fa-check-circle"})),e("div",{class:"mt-4"},e("label",{class:"mb-2 font-weight-bold"},"BSB *"),e("input",{placeholder:"Enter your BSB",type:"text",required:!0,class:"form-control",name:"bsb",id:"bsb",minlength:"6",maxlength:"7",onKeyUp:t=>this.updateCurrentBank(t),pattern:this.bsbRegex.source,value:oe.selfManagedFundForm.bsb}),D(this.currentBank)&&e("p",{class:"mt-3"},e("strong",null,"Bank name"),e("br",null),e("span",{class:"ml-2"},this.currentBank.value)),e("div",{class:"invalid-feedback"},"Enter a valid BSB")),e("div",{class:"mt-4"},e("label",{class:"mb-2 font-weight-bold"},"Bank account name *"),e("input",{placeholder:"Enter your bank account name",type:"text",required:!0,class:"form-control",name:"bankAccountName",minlength:"2",id:"bankAccountName",value:oe.selfManagedFundForm.bankAccountName,onChange:t=>this.updateFormField("bankAccountName",t.target.value.trim())}),e("div",{class:"invalid-feedback"},"Enter a valid bank account name")),e("div",{class:"mt-4"},e("label",{class:"mb-2 font-weight-bold"},"Bank account number *"),e("input",{placeholder:"Enter your bank account number",type:"text",required:!0,class:"form-control",name:"bankAccountNumber",id:"bankAccountNumber",minlength:"2",maxlength:"11",pattern:this.bankAccountNumberRegex.source,value:oe.selfManagedFundForm.bankAccountNumber,onKeyUp:t=>this.updateCurrentBankAccountNumber(t),onChange:t=>this.updateFormField("bankAccountNumber",t.target.value.trim())}),e("div",{class:"invalid-feedback"},"Enter a valid bank account number")))}updateFormField(t,e){this.formChanged.emit({[t]:e})}filterDigits(t){return t.replace(/[^0-9]/g,"")}updateCurrentBank(t){const e=this.filterDigits(t.target.value),n=e.substring(0,2),i=e.substring(0,3),r=on[n],o=on[i];r&&(this.currentBank=L(r)),o&&(this.currentBank=L(o)),""===e&&(this.currentBank=U),this.updateFormField("bsb",e)}updateCurrentBankAccountNumber(t){const e=this.filterDigits(t.target.value);this.updateFormField("bankAccountNumber",e)}};var an;!function(t){t[t.Unauthorized=0]="Unauthorized",t[t.Authenticated=1]="Authenticated",t[t.Error=2]="Error"}(an||(an={}));class cn{}let un=class extends g{constructor(){super({authenticationState:an.Unauthorized,jwt:U,reactNativeInterop:U,iframeInterop:U,appConfiguration:U})}};un=function(t,e,n,i){var r,o=arguments.length,s=o<3?e:null===i?i=Object.getOwnPropertyDescriptor(e,n):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(t,e,n,i);else for(var a=t.length-1;a>=0;a--)(r=t[a])&&(s=(o<3?r(s):o>3?r(e,n,s):r(e,n))||s);return o>3&&s&&Object.defineProperty(e,n,s),s}([b({name:"sss-session",resettable:!0})],un);const ln=new un,fn=new class extends w{constructor(t){super(t),this.store=t}isReactNativeInteropEnabled(){return D(this.getValue().reactNativeInterop)}isIframeInteropEnabled(){return D(this.getValue().iframeInterop)}getIframeInteropMode(){const t=this.getValue().iframeInterop;if(O(t))throw Error("Failed to get iframe interop information: no data in store");if(!this.isIframeInteropEnabled())throw Error("Failed to get iframe interop information: iframe mode is disabled");return t.value}}(ln),{state:dn}=qt({slateFundForm:{memberNumber:"",standardChoiceFormSignature:"",shownFunds:[]}}),hn=new class{constructor(){this.hostIsLocalSuperSelection=()=>"http://localhost:7100"==window.location.origin,this.hostIsDeployed=()=>window.location.origin.endsWith("partner.flarehr.com"),this.skipConsolidation=()=>fn.isReactNativeInteropEnabled()?"true":"false",this.environmentDiscriminator=()=>{const t=window.location.hostname.toLowerCase().split(".")[0];switch(t){case"autodev-partner":case"test-partner":case"partner":case"sandbox-partner":return t.replace("partner","");default:return"autodev-"}},this.slateJoinAppUrl=()=>`https://${this.environmentDiscriminator()}join.slatesuper.com.au/confirm`}build(t,e){if(!(null==t?void 0:t.contentDocument))return;const n=(this.hostIsLocalSuperSelection()||this.hostIsDeployed()?window.location.origin+"/super-selection/embed/v1.0/app":"https://autodev-partner.flarehr.com/super-selection/embed/v1.0/app")+"/slate-redirect.html",i=Object.assign(Object.assign({},this.getSlateJoinMemberData()),{successRedirectUrl:n,cancelRedirectUrl:n,skipConsolidation:this.skipConsolidation(),skipInsurance:"true"});this.includeJwt()&&(i.authToken=Zt.jwt);const r=n=>{const{data:i,origin:o}=n;if(i)if("slate-redirect"!==i.sender){if("flare"===i.sender&&o.endsWith("join.slatesuper.com.au"))switch(i.type){case"contentResized":t.height=i.height>0?i.height:t.height,t.width=i.width>0?i.width:t.width}}else switch(window.removeEventListener("message",r),i.type){case"success":if(i.memberNumber){dn.slateFundForm.memberNumber=i.memberNumber,te.navigateInternally(e,ee.SlateStandardChoice);break}default:te.navigateInternally(e,ee.ChoicePage)}};window.addEventListener("message",r);const o=t.contentDocument;o.open();const s=o.createElement("form");let a;for(a in s.method="POST",s.target="_self",s.action=this.slateJoinAppUrl(),i){const t=i[a];if(void 0!==t){const e=document.createElement("input");e.type="hidden",e.name=a,e.value=t,s.append(e)}}o.appendChild(s),o.close(),s.submit()}getSlateJoinMemberData(){var t,e;const n=Zt.superBuyer;return{firstName:n.userProfile.firstName,middleName:n.userProfile.middleName,lastName:n.userProfile.lastName,dateOfBirth:n.userProfile.dateOfBirth,gender:(t=>{switch(t){case"Male":return"Male";case"Female":return"Female";case"Intersex":return"Intersex/Indeterminate";default:return"Unknown"}})(n.userProfile.gender),email:n.userProfile.email,mobilePhone:n.userProfile.mobilePhone,taxFileNumber:null!==(t=n.tfn)&&void 0!==t?t:"",addressLine1:n.userProfile.address.addressLine1,addressLine2:null!==(e=n.userProfile.address.addressLine2)&&void 0!==e?e:"",city:n.userProfile.address.city,state:n.userProfile.address.state,postCode:n.userProfile.address.postcode}}includeJwt(){return!this.slateJoinAppUrl().match(/autodev|sandbox/)}},pn=class{constructor(e){t(this,e)}componentDidLoad(){hn.build(this.iframeElement,this.history)}render(){return e(o,{class:"d-flex flex-fill"},e("iframe",{width:"100%",height:window.innerHeight,style:{border:"none"},ref:t=>this.iframeElement=t}))}},mn=new class{async submitSlateChoiceAsync(t){return Jt().url("super-choice/slate").post(t).badRequest((()=>{throw new Error("Failed to process Slate join request")})).text()}},vn=class{constructor(e){t(this,e)}render(){return e(o,{class:"d-flex flex-fill"},e("div",{class:"container"},e("div",{class:"row justify-content-center"},e("div",{class:"col col-sm-10 col-md-7"},e("sss-slatesuper-header",null),e("div",null,e("form",{noValidate:!0,onSubmit:t=>t.preventDefault(),class:{"was-validated":"validated"===this.formState},ref:t=>this.formElement=t},e("sss-standard-choice-form",{onStandardChoiceFormSignatureUpdated:t=>{dn.slateFundForm=Object.assign(Object.assign({},dn.slateFundForm),t.detail)}})),e("div",{class:"d-flex mt-4"},e("div",{class:"flex-grow-1 w-50"},e("div",{class:"mr-2"},e("stencil-route-link",{url:"/"},e("fl-button",{isBlockElement:!0,variant:"secondary"},e("span",null,"Back"))))),e("div",{class:"flex-grow-1 w-50"},e("div",{class:"ml-2"},e("fl-promise-button",{isBlockElement:!0,promiseFn:()=>this.handleSubmitForm()},e("span",null,"Save and continue"))))))))))}async handleSubmitForm(){this.formState="validated",this.formElement.checkValidity()&&(await mn.submitSlateChoiceAsync(Object.assign(Object.assign({},dn.slateFundForm),{shownFunds:Zt.promotedFunds})),Zt.markSuperSelectionAsSubmitted(),te.navigateInternally(this.history,ee.Success))}},bn=class{constructor(e){t(this,e)}render(){return e("div",{class:"d-flex"},e("div",null,e("img",{class:"ss-choice-logo img-thumbnail",alt:"Simple Financial Choices Pty Ltd",src:s("assets/logo-slate.png")})),e("div",{class:"d-flex flex-column ml-3 align-items-left"},e("p",{class:"confirm-title font-weight-bold mb-0"},"You’re almost there!"),e("p",{class:"confirm-text mb-0"},"To proceed type your name below which authorises the signing of the Standard Choice form confirming your super selection.")))}static get assetsDirs(){return["assets"]}};bn.style="";const gn=class{constructor(e){t(this,e),this.continue=n(this,"continue",7),this.standardChoiceFormUrl="/super-selection/embed/v1.0/app/assets/Superannuation_Standard_Choice_Form.pdf",this.handleContinue=()=>{this.continue.emit()}}render(){return e(o,null,e("div",{class:"overlay"}),e("div",{class:"dialog"},e("div",{class:"card p-4 mt-4 bg-light text-center"},e("div",{style:{"text-align":"center"}},e("svg",{xmlns:"http://www.w3.org/2000/svg",width:"32",height:"32",fill:"orange",viewBox:"0 0 16 16"},e("path",{d:"M8.982 1.566a1.13 1.13 0 0 0-1.96 0L.165 13.233c-.457.778.091 1.767.98 1.767h13.713c.889 0 1.438-.99.98-1.767L8.982 1.566zM8 5c.535 0 .954.462.9.995l-.35 3.507a.552.552 0 0 1-1.1 0L7.1 5.995A.905.905 0 0 1 8 5zm.002 6a1 1 0 1 1 0 2 1 1 0 0 1 0-2z"}))),e("p",{class:"small mt-4 mb-0"},"You’ve selected a self-managed super fund (SMSF). Currently, SMSF information can’t be sent via this form. You’ll need to provide your employer with a"," ",e("a",{target:"_blank",href:this.standardChoiceFormUrl},"standard choice form")," ","for your SMSF details."),e("div",{class:"d-flex mt-4"},e("div",{class:"w-25"}),e("div",{class:"w-50"},e("fl-button",{onClick:this.handleContinue,isBlockElement:!0,variant:"primary"},e("span",null,"Continue")))))))}};gn.style="html{scroll-behavior:smooth}img.fluid-fit{-o-object-fit:cover;object-fit:cover}.overlay{position:absolute;top:0;left:0;z-index:100;background-color:#fff;opacity:0.7;width:100%;height:100%}.dialog{z-index:101;position:relative}";const wn=class{constructor(e){t(this,e),this.standardChoiceFormSignatureUpdated=n(this,"standardChoiceFormSignatureUpdated",7),this.standardChoiceFormUrl="/super-selection/embed/v1.0/app/assets/Superannuation_Standard_Choice_Form.pdf",this.standardChoiceFormSignature=""}render(){return e("div",{class:"card p-4 mt-4 bg-light"},e("h4",{class:"small font-weight-bold"},"Superannuation Standard Choice Form"),e("p",{class:"small mt-2"},"The superannuation"," ",e("a",{target:"_blank",href:this.standardChoiceFormUrl},"standard choice form")," ","informs your employer of your choice of fund."),e("h4",{class:"small font-weight-bold"},"Type your full name below (required)"),e("input",{placeholder:"Type your full name",type:"text",class:"form-control",required:!0,minlength:"2",name:"standardChoiceFormSignature",id:"standardChoiceFormSignature",value:this.standardChoiceFormSignature,onKeyUp:t=>this.updateFormField(t.target.value.trim())}),e("div",{class:"invalid-feedback"},"Type your full name"),e("p",{class:"small mt-3 mb-0"},"Your authorisation is required for signing this form. Applying your full name in the text field above is the same as applying your written signature and is legally binding."))}updateFormField(t){this.standardChoiceFormSignatureUpdated.emit({standardChoiceFormSignature:t})}},yn=class{constructor(e){t(this,e)}render(){return e(o,{class:"d-flex flex-fill"},e("div",{class:"container mt-5"},e("div",{class:"row justify-content-center"},e("div",{class:"col col-sm-9 col-md-6"},e("div",{class:"bg-light rounded p-4"},e("div",{class:"d-flex justify-content-center"},e("div",null,e("svg",{width:"3em",height:"3em",viewBox:"0 0 16 16",class:"bi bi-check-circle-fill text-success",fill:"currentColor",xmlns:"http://www.w3.org/2000/svg"},e("path",{"fill-rule":"evenodd",d:"M16 8A8 8 0 1 1 0 8a8 8 0 0 1 16 0zm-3.97-3.03a.75.75 0 0 0-1.08.022L7.477 9.417 5.384 7.323a.75.75 0 0 0-1.06 1.06L6.97 11.03a.75.75 0 0 0 1.079-.02l3.992-4.99a.75.75 0 0 0-.01-1.05z"})))),e("div",{class:"d-flex justify-content-center"},e("p",{class:"mt-3 confirm-title text-center font-weight-bold px-5"},"Successfully updated superannuation details")),e("div",{class:"mt-2 text-center"},e("p",{class:"confirm-text mb-0"},"Your superannuation details have been updated successfully."),e("br",null),e("p",{class:"confirm-text mb-0"},"To continue with your onboarding, press ",e("strong",null,"Continue")," below."))),e("div",{class:"flex-grow-1 mt-4"},e("fl-promise-button",{isBlockElement:!0,onClick:this.handleContinueButtonClick},e("span",null,"Continue")))))))}handleContinueButtonClick(t){Zt.completeSuperSelectionFlow()}},xn=class{constructor(e){t(this,e),this.joinFundClicked=n(this,"joinFundClicked",7),this.eventTrackingService=le.Instance}render(){return e(o,{class:{"d-flex p-3 fund-item":!0,"ss-picked-fund":this.isSelected}},e("div",{class:"card-body py-0 px-0 px-xl-3"},this.isSelected&&e("div",{class:"px-3 py-2 text-white promoted-picked-block position-absolute"},"You picked"),e("div",{class:"d-flex flex-fill flex-column align-items-center"},e("div",{class:"d-flex justify-content-end w-100"},e("div",{class:"text-muted small border rounded-sm px-1 mt-n2 mr-n2 mb-1"},"Advertised")),e("img",{class:"ss-choice-logo",alt:this.name,src:s("assets/"+this.logo)}),e("p",{class:"font-weight-bold text-center mt-3 mb-0"},this.name),this.subText&&e("span",{class:"text-muted small text-center font-italic"},this.subText),e("div",{class:"mt-3"},JSON.parse(this.features).map((t=>e("p",{class:"text-center"},t.value)))))),e("div",{class:"text-center bottom-half-fund-tile"},e("div",{class:"p-3"},e("fl-button",{class:"uuid-button-continue",isBlockElement:!0,onClick:()=>this.handleFundClick()},"Choose this fund")),e("div",{class:"mb-2"},e("a",{target:"_blank",href:this.pdsLink,onClick:()=>this.pdsViewedAsync()},this.pdsLinkText?this.pdsLinkText:"View the PDS")),this.disclaimer,e("div",{class:"small text-muted"},this.abnInfo)))}handleFundClick(){return this.joinFundClicked.emit()}pdsViewedAsync(){return this.eventTrackingService.TrackSuperFundPdsViewedAsync({fundUsi:this.usi,fundName:this.name,pageName:"Panel Fund Page"})}static get assetsDirs(){return["assets"]}};xn.style="html{scroll-behavior:smooth}img.fluid-fit{-o-object-fit:cover;object-fit:cover}.checkbox-container{border-radius:4px;background-color:#f5f4f2}.confirm-checkbox-item{-webkit-transform:scale(1.7);transform:scale(1.7)}.simple-choices-text{color:#489882}.choice-card{background:#ffffff;-webkit-box-shadow:0 1px 4px rgba(0, 0, 0, 0.25);box-shadow:0 1px 4px rgba(0, 0, 0, 0.25);border-radius:3px}.choice-card.ss-picked-fund{border:2px solid var(--fl-color-primary)}.card.ss-picked-fund{border:2px solid var(--fl-color-primary)}.ss-choice-logo{width:auto;max-height:70px;-o-object-fit:contain;object-fit:contain}img{width:100%;display:block}.choice-component{width:100%;position:relative}.flexible{-ms-flex-positive:1;flex-grow:1}.fund-item{margin-top:1rem}.promoted-picked-block{background-color:var(--fl-color-primary);border-bottom-right-radius:3px;left:0;top:0}@media (min-width: 992px){.bottom-half-fund-tile{height:220px}}";const kn=new class{async GetChosenFundAsync(){var t,e;const n=null===(t=Zt.superBuyer.superChoice)||void 0===t?void 0:t.choiceDetails;if(!n)return U;if("promoted"in n){const t=Ee.find((t=>t.dtoPropName in n.promoted)),i=null!==(e=null==t?void 0:t.id)&&void 0!==e?e:"";return L({isPromoted:!0,promotedId:i})}if("smsf"in n)return L({isPromoted:!1,name:n.smsf.fundName,type:"Self Managed Fund"});if("myOwnFund"in n){const t=n.myOwnFund.usi,e=await this.getFundByUsiAsync(t);return L({isPromoted:!1,name:D(e)?e.value.productName:t,type:"My Own Fund"})}if("default"in n){const t=n.default.usi,e=await this.getFundByUsiAsync(t);return L({isPromoted:!1,name:D(e)?e.value.productName:t,type:"Default Fund"})}return U}getFundByUsiAsync(t){return ce.getFundByUsiAsync(t)}},Sn=class{constructor(e){t(this,e),this.promotedFunds=this.getPromotedFunds(),this.chosenFund=U,this.eventTrackingService=le.Instance,this.isPromotedFundSelected=t=>D(this.chosenFund)&&this.chosenFund.value.isPromoted&&this.chosenFund.value.promotedId===t}componentDidLoad(){yt();const t=this.promotedFunds.map((t=>t.fundId));this.eventTrackingService.TrackSuperFundPanelViewedAsync({promotedFundsShown:t})}async componentWillLoad(){Le(),this.chosenFund=await kn.GetChosenFundAsync()}render(){return e(o,null,e("div",{class:"container mt-0 mb-0"},e("div",{class:"row justify-content-center"},e("div",{class:"col"},e("h3",{class:"mt-3 font-weight-bold text-center mb-4"},"Choose your Super"))),e("div",{class:"row justify-content-center"},e("div",{class:"col"},e("p",{class:"text-center font-weight-bold"},"The choice of superannuation fund is an important personal financial decision. It is open to you to continue with your existing fund, or alternatively, you can select from one of the funds below or choose another fund. Flare HR is not licensed to advise you in relation to this decision and you may wish to return to this page at a later stage."),e("p",{class:"text-center"},"The content on this page and on the following pages relating to each super fund is provided by the trustee or promoter of the super fund. The super funds presented have not been selected by your employer and neither your employer or Flare HR are making any recommendation or opinion."),e("p",{class:"text-center"},"There are many super funds out there and you should consider the relevant product disclosure statement and choose one that is right for you. If you are unsure, obtain your own advice. You can choose your super fund later, if you need time to obtain advice."))),e("div",{class:"row"},e("div",{class:"col"},e("sss-notifications-section",null))),e("div",{class:"row justify-content-center mt-4"},e("div",{class:"col col-sm-10 col-md-8 col-xl-7"},e("div",{class:"row"},e("div",{class:"col"},e("div",{class:"d-flex flex-fill"},D(this.chosenFund)&&!this.chosenFund.value.isPromoted&&e("sss-selected-super-choice-section",{fundType:this.chosenFund.value.type,fundName:this.chosenFund.value.name,class:"flex-fill position-relative"})))),e("div",{class:"row mt-3 justify-content-center"},this.getPromotedFunds().map((t=>e("div",{class:"col-12 col-lg-6 d-flex"},e("sss-super-choice-item",{class:"card mb-3 mb-lg-0 mx-0 flex-grow-1",logo:t.logo,isSelected:this.isPromotedFundSelected(t.fundId),usi:t.usi,name:t.name,subText:t.subText,pdsLinkText:t.pdsLinkText,pdsLink:te.toExternalUrl(t.pdsLink),features:JSON.stringify(t.features),disclaimer:t.disclaimer,abnInfo:t.abnInfo,onJoinFundClicked:async()=>this.handleJoinSuperClickAsync(t)}))))),e("div",{class:"row mt-3 px-3"},e("div",{class:"col p-4 border rounded bg-light"},e("div",{class:"row"},e("div",{class:"col"},e("h5",{class:"font-weight-bold"},"Choose another super fund"),e("p",{class:"mb-1"},"Select this option if you'd like to use your current account with another super fund."),e("ul",{class:"ml-n3"},e("li",null,"If you are unsure of your current super fund details, you can find out at"," ",e("a",{target:"_blank",href:te.toExternalUrl("https://my.gov.au")},"my.gov.au")),e("li",{class:"mt-1"},"A full list of super funds can be viewed at"," ",e("a",{target:"_blank",href:te.toExternalUrl("https://www.apra.gov.au/register-of-superannuation-institutions")},"www.apra.gov.au/register-of-superannuation-institutions"))))),e("div",{class:"row"},e("div",{class:"col"},e("stencil-route-link",{url:ee.MyOwnFund},e("fl-button",{isBlockElement:!0,variant:"primary",class:"d-lg-none"},"Choose another fund"),e("div",{class:"mt-n3 d-none d-lg-flex justify-content-end align-items-end"},e("fl-button",{variant:"primary"},"Choose another fund"))))))))),e("div",{class:"row justify-content-center mt-5"},e("div",{class:"col"},e("p",{class:"text-center"},"You should be aware that, if you do choose one of these advertised funds, Flare HR and its associated entities will normally receive a fee for you doing so.")))))}allFunds(){return[{fundId:"slate",usi:"32367272075001",name:"Slate Super",logo:"logo-slate.png",route:ee.SlateJoin,pdsLink:qe,features:[{order:1,value:"A lifestage investment strategy that evolves with you"},{order:2,value:"Advanced mobile app with retirement forecast and smart features"},{order:3,value:"Member advocates at Slate to assist with your account"}],disclaimer:e("p",{class:"small text-muted"},"You should consider the"," ",e("a",{target:"_blank",href:te.toExternalUrl(qe),onClick:()=>this.pdsViewedAsync("Slate Super","32367272075001")},"Product Disclosure Statement")," ","and"," ",e("a",{target:"_blank",href:te.toExternalUrl("https://slate.co/forms-and-documents/target-market-determination/")},"Target Market Determination")," ","before deciding to invest in or apply to become a member of the fund."),abnInfo:"Diversa Trustees Limited ABN: 49 006 421 638"},{fundId:"qsuper",usi:_e,name:"QSuper",logo:"logo-qsuper-square.png",route:ee.QSuperOptIn,pdsLink:Ae,features:[{order:1,value:"100 years strong"},{order:2,value:"One of Australia's largest funds"},{order:3,value:"Awarded SuperRatings highest performance rating"}],disclaimer:e("p",{class:"small text-muted"},"You should consider the"," ",e("a",{target:"_blank",href:te.toExternalUrl(Ae),onClick:()=>this.pdsViewedAsync("QSuper",_e)},"Product Disclosure Statement")," ","before deciding to invest in or apply to become a member of this fund."),abnInfo:"QSuper Board ABN: 32 125 059 006"},{fundId:"australian-retirement-trust",name:"Australian Retirement Trust",subText:"QSuper is now part of Australian Retirement Trust. If you have an existing QSuper account, you will continue to hold that account by selecting this option.",logo:"logo-art.svg",route:ee.PromotedFundJoin,pdsLink:Be,features:[{order:1,value:"$200 billion in retirement savings"},{order:2,value:"2+ million members"},{order:3,value:"A focus on delivering strong, long‑term returns"}],disclaimer:e("p",{class:"small text-muted"},"You should consider the"," ",e("a",{target:"_blank",href:te.toExternalUrl(Be),onClick:()=>this.pdsViewedAsync("Australian Retirement Trust")},"Product Disclosure Statement")," ","before deciding to invest in or apply to become a member of this fund."),abnInfo:"Australian Retirement Trust ABN: 60 905 115 063"},{fundId:"aware",name:"Aware Super",subText:"An industry fund for all",logo:"logo-aware.svg",route:ee.PromotedFundJoin,pdsLinkText:"View the PDS and TMD",pdsLink:je,features:[{order:1,value:"Acting on climate change"},{order:2,value:"All profits go to members"},{order:3,value:"One of Australia’s largest funds"}],disclaimer:e("p",{class:"small text-muted"},"You should consider the"," ",e("a",{target:"_blank",href:te.toExternalUrl(je),onClick:()=>this.pdsViewedAsync("Aware Super")},"Product Disclosure Statement")," ","before deciding to invest in or apply to become a member of this fund."),abnInfo:"Aware Super Pty Ltd ABN: 53 226 460 365"}]}getPromotedFunds(){const t=[];return Zt.promotedFunds.forEach((e=>{const n=this.allFunds().find((t=>e==t.fundId));void 0!==n&&t.push(n)})),t}async handleJoinSuperClickAsync(t){const e=Zt.promotedFunds;return"slate"===t.fundId?await this.eventTrackingService.TrackPromotedSuperFundDetailViewedAsync({fundUsi:"32367272075001",fundName:"Slate Super",promotedFundId:"slate",promotedFundsShown:e}):"qsuper"===t.fundId?await this.eventTrackingService.TrackPromotedSuperFundDetailViewedAsync({fundUsi:_e,fundName:"QSuper",promotedFundId:"qsuper",promotedFundsShown:e}):"australian-retirement-trust"===t.fundId?(await this.eventTrackingService.TrackPromotedSuperFundDetailViewedAsync({fundName:"Australian Retirement Trust",promotedFundId:"australian-retirement-trust",promotedFundsShown:e}),ye.fundId=t.fundId):"aware"===t.fundId&&(await this.eventTrackingService.TrackPromotedSuperFundDetailViewedAsync({fundName:"Aware Super",promotedFundId:"aware",promotedFundsShown:e}),ye.fundId=t.fundId),te.navigateInternally(this.history,t.route)}pdsViewedAsync(t,e){return this.eventTrackingService.TrackSuperFundPdsViewedAsync({fundUsi:e,fundName:t,pageName:"Panel Fund Page"})}static get assetsDirs(){return["assets"]}};Sn.style="html{scroll-behavior:smooth}img.fluid-fit{-o-object-fit:cover;object-fit:cover}.checkbox-container{border-radius:4px;background-color:#f5f4f2}.confirm-checkbox-item{-webkit-transform:scale(1.7);transform:scale(1.7)}.simple-choices-text{color:#489882}.choice-card{background:#ffffff;-webkit-box-shadow:0 1px 4px rgba(0, 0, 0, 0.25);box-shadow:0 1px 4px rgba(0, 0, 0, 0.25);border-radius:3px}.choice-card.ss-picked-fund{border:2px solid var(--fl-color-primary)}.card.ss-picked-fund{border:2px solid var(--fl-color-primary)}.ss-choice-logo{width:auto;max-height:70px;-o-object-fit:contain;object-fit:contain}img{width:100%;display:block}.choice-component{width:100%;position:relative}.flexible{-ms-flex-positive:1;flex-grow:1}.fund-item{margin-top:1rem}.promoted-picked-block{background-color:var(--fl-color-primary);border-bottom-right-radius:3px;left:0;top:0}@media (min-width: 992px){.bottom-half-fund-tile{height:220px}}";const Cn=class{constructor(e){t(this,e),this.group=null,this.match=null,this.componentProps={},this.exact=!1,this.scrollOnNextRender=!1,this.previousMatch=null}computeMatch(t){const e=null!=this.group||null!=this.el.parentElement&&"stencil-route-switch"===this.el.parentElement.tagName.toLowerCase();if(t&&!e)return this.previousMatch=this.match,this.match=lt(t.pathname,{path:this.url,exact:this.exact,strict:!0})}async loadCompleted(){let t={};var e,n;this.history&&this.history.location.hash?t={scrollToId:this.history.location.hash.substr(1)}:this.scrollTopOffset&&(t={scrollTopOffset:this.scrollTopOffset}),"function"==typeof this.componentUpdated?this.componentUpdated(t):!this.match||(n=this.previousMatch,null==(e=this.match)&&null==n||null!=n&&e&&n&&e.path===n.path&&e.url===n.url&&st(e.params,n.params))||!this.routeViewsUpdated||this.routeViewsUpdated(t)}async componentDidUpdate(){await this.loadCompleted()}async componentDidLoad(){await this.loadCompleted()}render(){if(!this.match||!this.history)return null;const t=Object.assign({},this.componentProps,{history:this.history,match:this.match});return this.routeRender?this.routeRender(Object.assign({},t,{component:this.component})):this.component?e(this.component,Object.assign({},t)):void 0}get el(){return a(this)}static get watchers(){return{location:["computeMatch"]}}};_.injectProps(Cn,["location","history","historyType","routeViewsUpdated"]),Cn.style="stencil-route.inactive{display:none}";const _n=(t,e,n)=>n(t.confirm(e)),An=(t,e)=>{const n=t[e],i="__storage_test__";try{return n.setItem(i,i),n.removeItem(i),!0}catch(t){return t instanceof DOMException&&(22===t.code||1014===t.code||"QuotaExceededError"===t.name||"NS_ERROR_DOM_QUOTA_REACHED"===t.name)&&0!==n.length}},qn=class{constructor(e){t(this,e),this.unsubscribe=()=>{},this.activeClass="link-active",this.exact=!1,this.strict=!0,this.custom="a",this.match=null}componentWillLoad(){this.computeMatch()}computeMatch(){this.location&&(this.match=lt(this.location.pathname,{path:this.urlMatch||this.url,exact:this.exact,strict:this.strict}))}handleClick(t){var e,n,i;if(!((e=t).metaKey||e.altKey||e.ctrlKey||e.shiftKey)&&this.history&&this.url&&this.root)return t.preventDefault(),this.history.push((i=this.root,"/"==(n=this.url).charAt(0)&&"/"==i.charAt(i.length-1)?i.slice(0,i.length-1)+n:i+n))}render(){let t={class:{[this.activeClass]:null!==this.match},onClick:this.handleClick.bind(this)};return this.anchorClass&&(t.class[this.anchorClass]=!0),"a"===this.custom&&(t=Object.assign({},t,{href:this.url,title:this.anchorTitle,role:this.anchorRole,tabindex:this.anchorTabIndex,"aria-haspopup":this.ariaHaspopup,id:this.anchorId,"aria-posinset":this.ariaPosinset,"aria-setsize":this.ariaSetsize,"aria-label":this.ariaLabel})),e(this.custom,Object.assign({},t),e("slot",null))}get el(){return a(this)}static get watchers(){return{location:["computeMatch"]}}};_.injectProps(qn,["history","location","root"]);const Bn=t=>"STENCIL-ROUTE"===t.tagName,jn=class{constructor(e){t(this,e),this.group=((1e17*Math.random()).toString().match(/.{4}/g)||[]).join("-"),this.subscribers=[],this.queue=c(this,"queue")}componentWillLoad(){null!=this.location&&this.regenerateSubscribers(this.location)}async regenerateSubscribers(t){if(null==t)return;let e=-1;if(this.subscribers=Array.prototype.slice.call(this.el.children).filter(Bn).map(((n,i)=>{const r=lt(t.pathname,{path:n.url,exact:n.exact,strict:!0});return r&&-1===e&&(e=i),{el:n,match:r}})),-1===e)return;if(this.activeIndex===e)return void(this.subscribers[e].el.match=this.subscribers[e].match);this.activeIndex=e;const n=this.subscribers[this.activeIndex];this.scrollTopOffset&&(n.el.scrollTopOffset=this.scrollTopOffset),n.el.group=this.group,n.el.match=n.match,n.el.componentUpdated=t=>{this.queue.write((()=>{this.subscribers.forEach(((t,e)=>{if(t.el.componentUpdated=void 0,e===this.activeIndex)return t.el.style.display="";this.scrollTopOffset&&(t.el.scrollTopOffset=this.scrollTopOffset),t.el.group=this.group,t.el.match=null,t.el.style.display="none"}))})),this.routeViewsUpdated&&this.routeViewsUpdated(Object.assign({scrollTopOffset:this.scrollTopOffset},t))}}render(){return e("slot",null)}get el(){return a(this)}static get watchers(){return{location:["regenerateSubscribers"]}}};_.injectProps(jn,["location","routeViewsUpdated"]);const En=(t,...e)=>{t||console.warn(...e)},In=()=>{let t,e=[];return{setPrompt:e=>(En(null==t,"A history supports only one prompt at a time"),t=e,()=>{t===e&&(t=null)}),confirmTransitionTo:(e,n,i,r)=>{if(null!=t){const o="function"==typeof t?t(e,n):t;"string"==typeof o?"function"==typeof i?i(o,r):(En(!1,"A history needs a getUserConfirmation function in order to use a prompt message"),r(!0)):r(!1!==o)}else r(!0)},appendListener:t=>{let n=!0;const i=(...e)=>{n&&t(...e)};return e.push(i),()=>{n=!1,e=e.filter((t=>t!==i))}},notifyListeners:(...t)=>{e.forEach((e=>e(...t)))}}},Fn=(t,e="scrollPositions")=>{let n=new Map;const i=(e,i)=>{if(n.set(e,i),An(t,"sessionStorage")){const e=[];n.forEach(((t,n)=>{e.push([n,t])})),t.sessionStorage.setItem("scrollPositions",JSON.stringify(e))}};if(An(t,"sessionStorage")){const i=t.sessionStorage.getItem(e);n=i?new Map(JSON.parse(i)):n}return"scrollRestoration"in t.history&&(history.scrollRestoration="manual"),{set:i,get:t=>n.get(t),has:t=>n.has(t),capture:e=>{i(e,[t.scrollX,t.scrollY])}}},Pn={hashbang:{encodePath:t=>"!"===t.charAt(0)?t:"!/"+et(t),decodePath:t=>"!"===t.charAt(0)?t.substr(1):t},noslash:{encodePath:et,decodePath:tt},slash:{encodePath:tt,decodePath:tt}},Tn=(t,e)=>{const n=0==t.pathname.indexOf(e)?"/"+t.pathname.slice(e.length):t.pathname;return Object.assign({},t,{pathname:n})},Mn={browser:(t,e={})=>{let n=!1;const i=t.history,r=t.location,o=t.navigator,s=(t=>{const e=t.navigator.userAgent;return(-1===e.indexOf("Android 2.")&&-1===e.indexOf("Android 4.0")||-1===e.indexOf("Mobile Safari")||-1!==e.indexOf("Chrome")||-1!==e.indexOf("Windows Phone"))&&t.history&&"pushState"in t.history})(t),a=!(-1===o.userAgent.indexOf("Trident")),c=Fn(t),u=null!=e.forceRefresh&&e.forceRefresh,l=null!=e.getUserConfirmation?e.getUserConfirmation:_n,f=null!=e.keyLength?e.keyLength:6,d=e.basename?Z(tt(e.basename)):"",h=()=>{try{return t.history.state||{}}catch(t){return{}}},p=t=>{t=t||{};const{key:e,state:n}=t,{pathname:i,search:o,hash:s}=r;let a=i+o+s;return En(!d||G(a,d),'You are attempting to use a basename on a page whose URL path does not begin with the basename. Expected path "'+a+'" to begin with "'+d+'".'),d&&(a=K(a,d)),at(a,n,e||rt(f))},m=In(),v=t=>{c.capture(B.location.key),Object.assign(B,t),B.location.scrollPosition=c.get(B.location.key),B.length=i.length,m.notifyListeners(B.location,B.action)},b=t=>{((t,e)=>void 0===e.state&&-1===t.userAgent.indexOf("CriOS"))(o,t)||w(p(t.state))},g=()=>{w(p(h()))},w=t=>{if(n)n=!1,v();else{const e="POP";m.confirmTransitionTo(t,e,l,(n=>{n?v({action:e,location:t}):y(t)}))}},y=t=>{let e=k.indexOf(B.location.key),i=k.indexOf(t.key);-1===e&&(e=0),-1===i&&(i=0);const r=e-i;r&&(n=!0,A(r))},x=p(h());let k=[x.key],S=0,C=!1;const _=t=>d+nt(t),A=t=>{i.go(t)},q=e=>{S+=e,1===S?(t.addEventListener("popstate",b),a&&t.addEventListener("hashchange",g)):0===S&&(t.removeEventListener("popstate",b),a&&t.removeEventListener("hashchange",g))},B={length:i.length,action:"POP",location:x,createHref:_,push:(t,e)=>{En(!("object"==typeof t&&void 0!==t.state&&void 0!==e),"You should avoid providing a 2nd state argument to push when the 1st argument is a location-like object that already has state; it is ignored");const n="PUSH",o=at(t,e,rt(f),B.location);m.confirmTransitionTo(o,n,l,(t=>{if(!t)return;const e=_(o),{key:a,state:c}=o;if(s)if(i.pushState({key:a,state:c},"",e),u)r.href=e;else{const t=k.indexOf(B.location.key),e=k.slice(0,-1===t?0:t+1);e.push(o.key),k=e,v({action:n,location:o})}else En(void 0===c,"Browser history cannot push state in browsers that do not support HTML5 history"),r.href=e}))},replace:(t,e)=>{En(!("object"==typeof t&&void 0!==t.state&&void 0!==e),"You should avoid providing a 2nd state argument to replace when the 1st argument is a location-like object that already has state; it is ignored");const n="REPLACE",o=at(t,e,rt(f),B.location);m.confirmTransitionTo(o,n,l,(t=>{if(!t)return;const e=_(o),{key:a,state:c}=o;if(s)if(i.replaceState({key:a,state:c},"",e),u)r.replace(e);else{const t=k.indexOf(B.location.key);-1!==t&&(k[t]=o.key),v({action:n,location:o})}else En(void 0===c,"Browser history cannot replace state in browsers that do not support HTML5 history"),r.replace(e)}))},go:A,goBack:()=>A(-1),goForward:()=>A(1),block:(t="")=>{const e=m.setPrompt(t);return C||(q(1),C=!0),()=>(C&&(C=!1,q(-1)),e())},listen:t=>{const e=m.appendListener(t);return q(1),()=>{q(-1),e()}},win:t};return B},hash:(t,e={})=>{let n=!1,i=null,r=0,o=!1;const s=t.location,a=t.history,c=-1===t.navigator.userAgent.indexOf("Firefox"),u=null!=e.keyLength?e.keyLength:6,{getUserConfirmation:l=_n,hashType:f="slash"}=e,d=e.basename?Z(tt(e.basename)):"",{encodePath:h,decodePath:p}=Pn[f],m=()=>{const t=s.href,e=t.indexOf("#");return-1===e?"":t.substring(e+1)},v=t=>{const e=s.href.indexOf("#");s.replace(s.href.slice(0,e>=0?e:0)+"#"+t)},b=()=>{let t=p(m());return En(!d||G(t,d),'You are attempting to use a basename on a page whose URL path does not begin with the basename. Expected path "'+t+'" to begin with "'+d+'".'),d&&(t=K(t,d)),at(t,void 0,rt(u))},g=In(),w=t=>{Object.assign(j,t),j.length=a.length,g.notifyListeners(j.location,j.action)},y=()=>{const t=m(),e=h(t);if(t!==e)v(e);else{const t=b(),e=j.location;if(!n&&(r=e).pathname===(o=t).pathname&&r.search===o.search&&r.hash===o.hash&&r.key===o.key&&st(r.state,o.state))return;if(i===nt(t))return;i=null,x(t)}var r,o},x=t=>{if(n)n=!1,w();else{const e="POP";g.confirmTransitionTo(t,e,l,(n=>{n?w({action:e,location:t}):k(t)}))}},k=t=>{let e=A.lastIndexOf(nt(j.location)),i=A.lastIndexOf(nt(t));-1===e&&(e=0),-1===i&&(i=0);const r=e-i;r&&(n=!0,q(r))},S=m(),C=h(S);S!==C&&v(C);const _=b();let A=[nt(_)];const q=t=>{En(c,"Hash history go(n) causes a full page reload in this browser"),a.go(t)},B=(t,e)=>{r+=e,1===r?t.addEventListener("hashchange",y):0===r&&t.removeEventListener("hashchange",y)},j={length:a.length,action:"POP",location:_,createHref:t=>"#"+h(d+nt(t)),push:(t,e)=>{En(void 0===e,"Hash history cannot push state; it is ignored");const n="PUSH",r=at(t,void 0,rt(u),j.location);g.confirmTransitionTo(r,n,l,(t=>{if(!t)return;const e=nt(r),o=h(d+e);if(m()!==o){i=e,(t=>{s.hash=t})(o);const t=A.lastIndexOf(nt(j.location)),a=A.slice(0,-1===t?0:t+1);a.push(e),A=a,w({action:n,location:r})}else En(!1,"Hash history cannot PUSH the same path; a new entry will not be added to the history stack"),w()}))},replace:(t,e)=>{En(void 0===e,"Hash history cannot replace state; it is ignored");const n="REPLACE",r=at(t,void 0,rt(u),j.location);g.confirmTransitionTo(r,n,l,(t=>{if(!t)return;const e=nt(r),o=h(d+e);m()!==o&&(i=e,v(o));const s=A.indexOf(nt(j.location));-1!==s&&(A[s]=e),w({action:n,location:r})}))},go:q,goBack:()=>q(-1),goForward:()=>q(1),block:(e="")=>{const n=g.setPrompt(e);return o||(B(t,1),o=!0),()=>(o&&(o=!1,B(t,-1)),n())},listen:e=>{const n=g.appendListener(e);return B(t,1),()=>{B(t,-1),n()}},win:t};return j}},Rn=class{constructor(e){t(this,e),this.root="/",this.historyType="browser",this.titleSuffix="",this.routeViewsUpdated=(t={})=>{if(this.history&&t.scrollToId&&"browser"===this.historyType){const e=this.history.win.document.getElementById(t.scrollToId);if(e)return e.scrollIntoView()}this.scrollTo(t.scrollTopOffset||this.scrollTopOffset)},this.isServer=c(this,"isServer"),this.queue=c(this,"queue")}componentWillLoad(){this.history=Mn[this.historyType](this.el.ownerDocument.defaultView),this.history.listen((t=>{t=Tn(t,this.root),this.location=t})),this.location=Tn(this.history.location,this.root)}scrollTo(t){const e=this.history;if(null!=t&&!this.isServer&&e)return"POP"===e.action&&Array.isArray(e.location.scrollPosition)?this.queue.write((()=>{e&&e.location&&Array.isArray(e.location.scrollPosition)&&e.win.scrollTo(e.location.scrollPosition[0],e.location.scrollPosition[1])})):this.queue.write((()=>{e.win.scrollTo(0,t)}))}render(){if(this.location&&this.history)return e(_.Provider,{state:{historyType:this.historyType,location:this.location,titleSuffix:this.titleSuffix,root:this.root,history:this.history,routeViewsUpdated:this.routeViewsUpdated}},e("slot",null))}get el(){return a(this)}},Nn=class{constructor(e){t(this,e),this.stepSubmitSuccess=n(this,"step-completion",7),this.successPageAcknowledged=n(this,"successPageAcknowledged",5),this.initialised=n(this,"initialised",7),this.isAppInitialised=!1}async componentWillLoad(){const t=Et.fromNullable(this.accessToken);if(Et.isNone(t))throw Error("jwt property is missing.");Zt.state.jwt=t;const e=Et.fromNullable(this.backendUrl);if(Et.isNone(e))throw Error("apiBaseUrl property is missing.");Zt.state.apiBaseUrl=Et.some(e.value.replace(/\/$/,"")+"/");const n=Et.fromNullable(this.appBaseUrl);if(Et.isNone(n))throw Error("appBaseUrl property is missing.");Zt.state.appBaseUrl=Et.some(n.value.replace(/\/$/,"")),Zt.onChange("hasSuccessPageBeenAcknowledged",(()=>this.successPageAcknowledged.emit())),Zt.onChange("hasSuperSelectionBeenSubmitted",(t=>{t&&(this.stepSubmitSuccess.emit(),Zt.state.hasSuperSelectionBeenSubmitted=!1)}))}async componentDidLoad(){Le(),await Zt.loadAppStateAsync(),this.isAppInitialised=!0,this.initialised.emit({accountIdOrDefault:Zt.accountIdOrDefault,partnerIdOrDefault:Zt.partnerIdOrDefault,profileId:Zt.profileId})}authTokenChanged(t){Zt.state.jwt=Et.fromNullable(t)}onRouteChange(){null===window||void 0===window||window.scroll(0,0)}render(){return e(o,{class:"d-flex justify-content-center flex-grow-1"},e("div",{class:"d-flex flex-column justify-content-between"},this.renderAppContent()))}routerBaseUrl(){var t;return(null===(t=this.appBaseUrl)||void 0===t?void 0:t.replace(/\/$/,""))+"/"}renderAppContent(){return e("stencil-router",{root:this.routerBaseUrl()},e("stencil-route-switch",{scrollTopOffset:0},e("div",{class:"d-flex flex-column"},e("div",{class:"d-flex justify-content-center"},this.isAppInitialised?ne:e("fl-loading-indicator",{class:"mt-5"})),e("div",{class:"d-flex justify-content-center"},e("sss-footer-section",null)))))}static get watchers(){return{accessToken:["authTokenChanged"],location:["onRouteChange"]}}};H(Nn),Nn.style="html{scroll-behavior:smooth}img.fluid-fit{-o-object-fit:cover;object-fit:cover}stencil-route{display:-ms-flexbox;display:flex;-ms-flex:1 1 auto;flex:1 1 auto}stencil-route:empty{display:none}";var Dn,On=[],Un="ResizeObserver loop completed with undelivered notifications.";!function(t){t.BORDER_BOX="border-box",t.CONTENT_BOX="content-box",t.DEVICE_PIXEL_CONTENT_BOX="device-pixel-content-box"}(Dn||(Dn={}));var Ln,zn=function(t){return Object.freeze(t)},Vn=function(t,e){this.inlineSize=t,this.blockSize=e,zn(this)},Hn=function(){function t(t,e,n,i){return this.x=t,this.y=e,this.width=n,this.height=i,this.top=this.y,this.left=this.x,this.bottom=this.top+this.height,this.right=this.left+this.width,zn(this)}return t.prototype.toJSON=function(){var t=this;return{x:t.x,y:t.y,top:t.top,right:t.right,bottom:t.bottom,left:t.left,width:t.width,height:t.height}},t.fromRect=function(e){return new t(e.x,e.y,e.width,e.height)},t}(),Qn=function(t){return t instanceof SVGElement&&"getBBox"in t},Wn=function(t){if(Qn(t)){var e=t.getBBox();return!e.width&&!e.height}return!(t.offsetWidth||t.offsetHeight||t.getClientRects().length)},$n=function(t){var e,n,i=null===(n=null===(e=t)||void 0===e?void 0:e.ownerDocument)||void 0===n?void 0:n.defaultView;return!!(i&&t instanceof i.Element)},Yn="undefined"!=typeof window?window:{},Xn=new WeakMap,Jn=/auto|scroll/,Gn=/^tb|vertical/,Kn=/msie|trident/i.test(Yn.navigator&&Yn.navigator.userAgent),Zn=function(t){return parseFloat(t||"0")},ti=function(t,e,n){return void 0===t&&(t=0),void 0===e&&(e=0),void 0===n&&(n=!1),new Vn((n?e:t)||0,(n?t:e)||0)},ei=zn({devicePixelContentBoxSize:ti(),borderBoxSize:ti(),contentBoxSize:ti(),contentRect:new Hn(0,0,0,0)}),ni=function(t,e){if(void 0===e&&(e=!1),Xn.has(t)&&!e)return Xn.get(t);if(Wn(t))return Xn.set(t,ei),ei;var n=getComputedStyle(t),i=Qn(t)&&t.ownerSVGElement&&t.getBBox(),r=!Kn&&"border-box"===n.boxSizing,o=Gn.test(n.writingMode||""),s=!i&&Jn.test(n.overflowY||""),a=!i&&Jn.test(n.overflowX||""),c=i?0:Zn(n.paddingTop),u=i?0:Zn(n.paddingRight),l=i?0:Zn(n.paddingBottom),f=i?0:Zn(n.paddingLeft),d=i?0:Zn(n.borderTopWidth),h=i?0:Zn(n.borderRightWidth),p=i?0:Zn(n.borderBottomWidth),m=f+u,v=c+l,b=(i?0:Zn(n.borderLeftWidth))+h,g=d+p,w=a?t.offsetHeight-g-t.clientHeight:0,y=s?t.offsetWidth-b-t.clientWidth:0,x=r?m+b:0,k=r?v+g:0,S=i?i.width:Zn(n.width)-x-y,C=i?i.height:Zn(n.height)-k-w,_=S+m+y+b,A=C+v+w+g,q=zn({devicePixelContentBoxSize:ti(Math.round(S*devicePixelRatio),Math.round(C*devicePixelRatio),o),borderBoxSize:ti(_,A,o),contentBoxSize:ti(S,C,o),contentRect:new Hn(f,c,S,C)});return Xn.set(t,q),q},ii=function(t,e,n){var i=ni(t,n),r=i.borderBoxSize,o=i.contentBoxSize,s=i.devicePixelContentBoxSize;switch(e){case Dn.DEVICE_PIXEL_CONTENT_BOX:return s;case Dn.BORDER_BOX:return r;default:return o}},ri=function(t){var e=ni(t);this.target=t,this.contentRect=e.contentRect,this.borderBoxSize=zn([e.borderBoxSize]),this.contentBoxSize=zn([e.contentBoxSize]),this.devicePixelContentBoxSize=zn([e.devicePixelContentBoxSize])},oi=function(t){if(Wn(t))return 1/0;for(var e=0,n=t.parentNode;n;)e+=1,n=n.parentNode;return e},si=function(){var t=1/0,e=[];On.forEach((function(n){if(0!==n.activeTargets.length){var i=[];n.activeTargets.forEach((function(e){var n=new ri(e.target),r=oi(e.target);i.push(n),e.lastReportedSize=ii(e.target,e.observedBox),r<t&&(t=r)})),e.push((function(){n.callback.call(n.observer,i,n.observer)})),n.activeTargets.splice(0,n.activeTargets.length)}}));for(var n=0,i=e;n<i.length;n++)(0,i[n])();return t},ai=function(t){On.forEach((function(e){e.activeTargets.splice(0,e.activeTargets.length),e.skippedTargets.splice(0,e.skippedTargets.length),e.observationTargets.forEach((function(n){n.isActive()&&(oi(n.target)>t?e.activeTargets.push(n):e.skippedTargets.push(n))}))}))},ci=[],ui=0,li={attributes:!0,characterData:!0,childList:!0,subtree:!0},fi=["resize","load","transitionend","animationend","animationstart","animationiteration","keyup","keydown","mouseup","mousedown","mouseover","mouseout","blur","focus"],di=function(t){return void 0===t&&(t=0),Date.now()+t},hi=!1,pi=new(function(){function t(){var t=this;this.stopped=!0,this.listener=function(){return t.schedule()}}return t.prototype.run=function(t){var e=this;if(void 0===t&&(t=250),!hi){hi=!0;var n,i=di(t);n=function(){var n=!1;try{n=function(){var t,e=0;for(ai(e);On.some((function(t){return t.activeTargets.length>0}));)e=si(),ai(e);return On.some((function(t){return t.skippedTargets.length>0}))&&("function"==typeof ErrorEvent?t=new ErrorEvent("error",{message:Un}):((t=document.createEvent("Event")).initEvent("error",!1,!1),t.message=Un),window.dispatchEvent(t)),e>0}()}finally{if(hi=!1,t=i-di(),!ui)return;n?e.run(1e3):t>0?e.run(t):e.start()}},function(t){if(!Ln){var e=0,n=document.createTextNode("");new MutationObserver((function(){return ci.splice(0).forEach((function(t){return t()}))})).observe(n,{characterData:!0}),Ln=function(){n.textContent=""+(e?e--:e++)}}ci.push(t),Ln()}((function(){requestAnimationFrame(n)}))}},t.prototype.schedule=function(){this.stop(),this.run()},t.prototype.observe=function(){var t=this,e=function(){return t.observer&&t.observer.observe(document.body,li)};document.body?e():Yn.addEventListener("DOMContentLoaded",e)},t.prototype.start=function(){var t=this;this.stopped&&(this.stopped=!1,this.observer=new MutationObserver(this.listener),this.observe(),fi.forEach((function(e){return Yn.addEventListener(e,t.listener,!0)})))},t.prototype.stop=function(){var t=this;this.stopped||(this.observer&&this.observer.disconnect(),fi.forEach((function(e){return Yn.removeEventListener(e,t.listener,!0)})),this.stopped=!0)},t}()),mi=function(t){!ui&&t>0&&pi.start(),!(ui+=t)&&pi.stop()},vi=function(){function t(t,e){this.target=t,this.observedBox=e||Dn.CONTENT_BOX,this.lastReportedSize={inlineSize:0,blockSize:0}}return t.prototype.isActive=function(){var t,e=ii(this.target,this.observedBox,!0);return Qn(t=this.target)||function(t){switch(t.tagName){case"INPUT":if("image"!==t.type)break;case"VIDEO":case"AUDIO":case"EMBED":case"OBJECT":case"CANVAS":case"IFRAME":case"IMG":return!0}return!1}(t)||"inline"!==getComputedStyle(t).display||(this.lastReportedSize=e),this.lastReportedSize.inlineSize!==e.inlineSize||this.lastReportedSize.blockSize!==e.blockSize},t}(),bi=function(t,e){this.activeTargets=[],this.skippedTargets=[],this.observationTargets=[],this.observer=t,this.callback=e},gi=new WeakMap,wi=function(t,e){for(var n=0;n<t.length;n+=1)if(t[n].target===e)return n;return-1},yi=function(){function t(){}return t.connect=function(t,e){var n=new bi(t,e);gi.set(t,n)},t.observe=function(t,e,n){var i=gi.get(t),r=0===i.observationTargets.length;wi(i.observationTargets,e)<0&&(r&&On.push(i),i.observationTargets.push(new vi(e,n&&n.box)),mi(1),pi.schedule())},t.unobserve=function(t,e){var n=gi.get(t),i=wi(n.observationTargets,e);i>=0&&(1===n.observationTargets.length&&On.splice(On.indexOf(n),1),n.observationTargets.splice(i,1),mi(-1))},t.disconnect=function(t){var e=this,n=gi.get(t);n.observationTargets.slice().forEach((function(n){return e.unobserve(t,n.target)})),n.activeTargets.splice(0,n.activeTargets.length)},t}(),xi=function(){function t(t){if(0===arguments.length)throw new TypeError("Failed to construct 'ResizeObserver': 1 argument required, but only 0 present.");if("function"!=typeof t)throw new TypeError("Failed to construct 'ResizeObserver': The callback provided as parameter 1 is not a function.");yi.connect(this,t)}return t.prototype.observe=function(t,e){if(0===arguments.length)throw new TypeError("Failed to execute 'observe' on 'ResizeObserver': 1 argument required, but only 0 present.");if(!$n(t))throw new TypeError("Failed to execute 'observe' on 'ResizeObserver': parameter 1 is not of type 'Element");yi.observe(this,t,e)},t.prototype.unobserve=function(t){if(0===arguments.length)throw new TypeError("Failed to execute 'unobserve' on 'ResizeObserver': 1 argument required, but only 0 present.");if(!$n(t))throw new TypeError("Failed to execute 'unobserve' on 'ResizeObserver': parameter 1 is not of type 'Element");yi.unobserve(this,t)},t.prototype.disconnect=function(){yi.disconnect(this)},t.toString=function(){return"function ResizeObserver () { [polyfill code] }"},t}();const ki=new class{constructor(){this._appRootUrl=new V((()=>this.resolveRootUrl())),this.getAppRootUrl=()=>this._appRootUrl.value,this.getAppHostUrl=()=>`${window.location.origin}${this.getAppRootUrl()}`.replace(/\/$/,"")}async loadConfigurationAsync(){const t=await Xt(this.getAppRootUrl()+"config.json").get().json();ln.update({appConfiguration:Et.fromNullable(t)})}resolveRootUrl(){const t=Et.fromNullable(window.location.pathname.match(/^\/super-selection\/embed\/v1.0\/app/));if(Et.isNone(t))throw Error("Unsupported host URL");return t.value[0]+"/"}};function Si(){return"undefined"!=typeof globalThis&&globalThis?globalThis:"undefined"!=typeof self&&self?self:"undefined"!=typeof window&&window?window:"undefined"!=typeof global&&global?global:null}function Ci(t){var e=Object.create;if(e)return e(t);if(null==t)return{};var n=typeof t;if("object"!==n&&"function"!==n)throw new TypeError("Object prototype may only be an Object:"+t);function i(){}return i.prototype=t,new i}var _i,Ai,qi=function(t,e){return(qi=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(t,e){t.__proto__=e}||function(t,e){for(var n in e)e.hasOwnProperty(n)&&(t[n]=e[n])})(t,e)},Bi=Si()||{};Ai=function(t,e){function n(){this.constructor=t}qi(t,e),t.prototype=null===e?Ci(e):(n.prototype=e.prototype,new n)},(_i=Bi).__assign||(_i.__assign=Object.assign||function(t){for(var e,n=1,i=arguments.length;n<i;n++)for(var r in e=arguments[n])Object.prototype.hasOwnProperty.call(e,r)&&(t[r]=e[r]);return t}),_i.__extends||(_i.__extends=Ai),__assign||(__assign=Bi.__assign),__extends||(__extends=Bi.__extends);var ji=Si;function Ei(t){var e=ji();return e&&e[t]?e[t]:"window"===t&&Ii()?window:null}function Ii(){return Boolean("object"==typeof window&&window)}function Fi(){return Ii()?window:Ei("window")}function Pi(){return Boolean("object"==typeof document&&document)}function Ti(){return Pi()?document:Ei("document")}function Mi(){return Boolean("object"==typeof navigator&&navigator)?navigator:Ei("navigator")}function Ri(){return"object"==typeof location&&location?location:Ei("location")}function Ni(){return Ei("performance")}function Di(){return Boolean("object"==typeof JSON&&JSON||null!==Ei("JSON"))}function Oi(){return Di()?JSON||Ei("JSON"):null}var Ui=null,Li=!1,zi=123456789,Vi=987654321;function Hi(t){t<0&&(t>>>=0),zi=123456789+t&4294967295,Vi=987654321-t&4294967295,Li=!0}function Qi(){Hi(4294967296*Math.random()^(new Date).getTime())}function Wi(t,e){return typeof t===e}function $i(t){return Wi(t,"undefined")||void 0===t}function Yi(t){return $i(t)||null===t}function Xi(t,e){return t&&Object.prototype.hasOwnProperty.call(t,e)}function Ji(t){return Wi(t,"object")}function Gi(t){return Wi(t,"function")}function Ki(t,e,n,i){void 0===i&&(i=!1);var r=!1;if(!Yi(t))try{Yi(t.addEventListener)?Yi(t.attachEvent)||(t.attachEvent("on"+e,n),r=!0):(t.addEventListener(e,n,i),r=!0)}catch(t){}return r}function Zi(t,e,n,i){if(void 0===i&&(i=!1),!Yi(t))try{Yi(t.removeEventListener)?Yi(t.detachEvent)||t.detachEvent("on"+e,n):t.removeEventListener(e,n,i)}catch(t){}}function tr(t,e){if(t&&Ji(t))for(var n in t)Xi(t,n)&&e.call(t,n,t[n])}var er,nr=function(){function t(){}return t.isDate=function(t){return"[object Date]"===Object.prototype.toString.call(t)},t.isArray=function(t){return"[object Array]"===Object.prototype.toString.call(t)},t.isError=function(t){return"[object Error]"===Object.prototype.toString.call(t)},t.isString=function(t){return Wi(t,"string")},t.isNumber=function(t){return Wi(t,"number")},t.isBoolean=function(t){return Wi(t,"boolean")},t.disableCookies=function(){t._canUseCookies=!1},t.newGuid=function(){return"xxxxxxxx-xxxx-4xxx-yxxx-xxxxxxxxxxxx".replace(ir,(function(e){var n=0|t.randomValue(15);return("x"===e?n:3&n|8).toString(16)}))},t.toISOString=function(e){if(t.isDate(e)){var n=function(t){var e=String(t);return 1===e.length&&(e="0"+e),e};return e.getUTCFullYear()+"-"+n(e.getUTCMonth()+1)+"-"+n(e.getUTCDate())+"T"+n(e.getUTCHours())+":"+n(e.getUTCMinutes())+":"+n(e.getUTCSeconds())+"."+String((e.getUTCMilliseconds()/1e3).toFixed(3)).slice(2,5)+"Z"}},t.arrForEach=function(t,e,n){for(var i=t.length,r=0;r<i;r++)r in t&&e.call(n||t,t[r],r,t)},t.arrIndexOf=function(t,e,n){for(var i=t.length,r=n||0,o=Math.max(r>=0?r:i-Math.abs(r),0);o<i;o++)if(o in t&&t[o]===e)return o;return-1},t.arrMap=function(t,e,n){for(var i=t.length,r=n||t,o=new Array(i),s=0;s<i;s++)s in t&&(o[s]=e.call(r,t[s],t));return o},t.arrReduce=function(t,e,n){var i,r=t.length,o=0;if(arguments.length>=3)i=arguments[2];else{for(;o<r&&!(o in t);)o++;i=t[o++]}for(;o<r;)o in t&&(i=e(i,t[o],o,t)),o++;return i},t.strTrim=function(e){return t.isString(e)?e.replace(/^\s+|\s+$/g,""):e},t.objKeys=function(t){var e=!{toString:null}.propertyIsEnumerable("toString");if(!(Gi(t)||Ji(t)&&null!==t))throw new TypeError("objKeys called on non-object");var n=[];for(var i in t)Xi(t,i)&&n.push(i);if(e)for(var r=["toString","toLocaleString","valueOf","hasOwnProperty","isPrototypeOf","propertyIsEnumerable","constructor"],o=r.length,s=0;s<o;s++)Xi(t,r[s])&&n.push(r[s]);return n},t.objDefineAccessors=function(t,e,n,i){var r=Object.defineProperty;if(r)try{var o={enumerable:!0,configurable:!0};return n&&(o.get=n),i&&(o.set=i),r(t,e,o),!0}catch(t){}return!1},t.addEventHandler=function(t,e){var n=!1,i=Fi();i&&(n=Ki(i,t,e),n=Ki(i.body,t,e)||n);var r=Ti();return r&&(n=rr.Attach(r,t,e)||n),n},t.dateNow=function(){var t=Date;return t.now?t.now():(new t).getTime()},t.perfNow=function(){var e=Ni();return e&&e.now?e.now():t.dateNow()},t.newId=function(e){void 0===e&&(e=22);for(var n=t.random32()>>>0,i=0,r="";r.length<e;)i++,r+="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/".charAt(63&n),n>>>=6,5===i&&(n=(t.random32()<<2&4294967295|3&n)>>>0,i=0);return r},t.isIE=function(){if(null===Ui){var t=((Mi()||{}).userAgent||"").toLowerCase();Ui=-1!==t.indexOf("msie")||-1!==t.indexOf("trident/")}return Ui},t.randomValue=function(e){return e>0?Math.floor(t.random32()/4294967295*(e+1))>>>0:0},t.random32=function(e){var n,i=Ei("crypto")||Ei("msCrypto");return i&&i.getRandomValues?n=4294967295&i.getRandomValues(new Uint32Array(1))[0]:t.isIE()?(Li||Qi(),n=4294967295&t.mwcRandom32()):n=Math.floor(4294967296*Math.random()|0),e||(n>>>=0),n},t.mwcRandomSeed=function(t){t?Hi(t):Qi()},t.mwcRandom32=function(t){var e=((Vi=36969*(65535&Vi)+(Vi>>16)&4294967295)<<16)+(65535&(zi=18e3*(65535&zi)+(zi>>16)&4294967295))>>>0&4294967295|0;return t||(e>>>=0),e},t.generateW3CId=function(){for(var e,n=["0","1","2","3","4","5","6","7","8","9","a","b","c","d","e","f"],i="",r=0;r<4;r++)i+=n[15&(e=t.random32())]+n[e>>4&15]+n[e>>8&15]+n[e>>12&15]+n[e>>16&15]+n[e>>20&15]+n[e>>24&15]+n[e>>28&15];var o=n[8+(3&t.random32())|0];return i.substr(0,8)+i.substr(9,4)+"4"+i.substr(13,3)+o+i.substr(16,3)+i.substr(19,12)},t.isTypeof=Wi,t.isUndefined=$i,t.isNullOrUndefined=Yi,t.hasOwnProperty=Xi,t.isFunction=Gi,t.isObject=Ji,t.objCreate=Ci,t}(),ir=/[xy]/g,rr=function(){function t(){}return t.Attach=Ki,t.AttachEvent=Ki,t.Detach=Zi,t.DetachEvent=Zi,t}();!function(t){t[t.CRITICAL=1]="CRITICAL",t[t.WARNING=2]="WARNING"}(er||(er={}));var or=Object.getPrototypeOf,sr=0;
2
2
  /*!
3
3
  * Microsoft Dynamic Proto Utility, 1.1.0
4
4
  * Copyright (c) Microsoft and contributors. All rights reserved.
5
- */function ar(t,e){return t&&Object.prototype.hasOwnProperty.call(t,e)}function cr(t){return"function"==typeof t}function ur(t){return t&&(t===Object.prototype||t===Array.prototype)}function lr(t){return ur(t)||t===Function.prototype}function fr(t){if(t){if(or)return or(t);var e=t.__proto__||t.prototype||t.constructor;if(e)return e}return null}function dr(t,e,n){return"constructor"!==e&&cr(t[e])&&(n||ar(t,e))}function hr(t){throw new TypeError("DynamicProto: "+t)}function pr(t,e){for(var n=t.length-1;n>=0;n--)if(t[n]===e)return!0;return!1}function mr(t,e,n,i){var r=null;if(t&&ar(n,"_dynClass")){var o=t._dynInstFuncs||{};if((r=(o[n._dynClass]||{})[e])||hr("Missing ["+e+"] function"),!r._dynInstChk&&!1!==o._dynInstChk){for(var s=!ar(t,e),a=fr(t),c=[];s&&a&&!lr(a)&&!pr(c,a);){var u=a[e];if(u){s=u===i;break}c.push(a),a=fr(a)}try{s&&(t[e]=r),r._dynInstChk=1}catch(t){o._dynInstChk=!1}}}return r}function vr(t,e,n){var i=e[t];return i===n&&(i=fr(e)[t]),cr(i)||hr("["+t+"] is not a function"),i}function br(t,e){return ar(t,"prototype")?t.name||e||"_unknown_":((t||{}).constructor||{}).name||e||"_unknown_"}function gr(t,e,n,i){ar(t,"prototype")||hr("theClass is an invalid class definition.");var r=t.prototype;(function(t,e){for(var n=fr(e);n&&!lr(n);){if(n===t)return!0;n=fr(n)}return!1})(r,e)||hr("["+br(t)+"] is not in class hierarchy of ["+br(e)+"]");var o=null;ar(r,"_dynClass")?o=r._dynClass:(o="_dynCls$"+br(t,"_")+"$"+sr,sr++,r._dynClass=o);var s=gr._dfOpts,a=!!s.useBaseInst;a&&i&&void 0!==i.useBaseInst&&(a=!!i.useBaseInst);var c=function(t){var e={};for(var n in t)!e[n]&&dr(t,n,!1)&&(e[n]=t[n]);return e}(e);n(e,function(t,e,n,i){function r(t,e,n){var r=e[s];if(r._isDynProxy&&i){var o=t._dynInstFuncs||{};!1!==o._dynInstChk&&(r=(o[e._dynClass]||{})[n]||r)}return function(){return r.apply(t,arguments)}}var o={};for(var s in n)o[s]=r(e,n,s);for(var a=fr(t),c=[];a&&!lr(a)&&!pr(c,a);){for(var s in a)!o[s]&&dr(a,s,!or)&&(o[s]=r(e,a,s));c.push(a),a=fr(a)}return o}(r,e,c,a));var u=!!or&&!!s.setInstFuncs;u&&i&&(u=!!i.setInstFuncs),function(t,e,n,i,r){function o(t,e){var n=function(){return(mr(this,e,t,n)||vr(e,t,n)).apply(this,arguments)};return n._isDynProxy=1,n}if(!ur(t)){var s=n._dynInstFuncs=n._dynInstFuncs||{},a=s[e]=s[e]||{};for(var c in!1!==s._dynInstChk&&(s._dynInstChk=!!r),n)dr(n,c,!1)&&n[c]!==i[c]&&(a[c]=n[c],delete n[c],(!ar(t,c)||t[c]&&!t[c]._isDynProxy)&&(t[c]=o(t,c)))}}(r,o,e,c,!1!==u)}function wr(t){return t?'"'+t.replace(/\"/g,"")+'"':""}gr._dfOpts={setInstFuncs:!0,useBaseInst:!0};var yr=function(){function t(t,e,n,i){void 0===n&&(n=!1);var r=this;r.messageId=t,r.message=(n?"AI: ":"AI (Internal): ")+t;var o="";Di()&&(o=Oi().stringify(i));var s=(e?" message:"+wr(e):"")+(i?" props:"+wr(o):"");r.message+=s}return t.dataType="MessageData",t}(),xr=function(){function t(e){this.identifier="DiagnosticLogger",this.queue=[];var n=0,i={};gr(t,this,(function(t){var r=nr.isNullOrUndefined,o=nr.isUndefined,s=nr.isFunction;function a(t,n){var i=e[t];return r(i)?n:i}r(e)&&(e={}),t.consoleLoggingLevel=function(){return a("loggingLevelConsole",0)},t.telemetryLoggingLevel=function(){return a("loggingLevelTelemetry",1)},t.maxInternalMessageLimit=function(){return a("maxMessageLimit",25)},t.enableDebugExceptions=function(){return a("enableDebugExceptions",!1)},t.throwInternal=function(e,n,r,s,a){void 0===a&&(a=!1);var c=new yr(n,r,a,s);if(t.enableDebugExceptions())throw c;if(!o(c)&&c&&!o(c.message)){if(a){var u=+c.messageId;!i[u]&&t.consoleLoggingLevel()>=er.WARNING&&(t.warnToConsole(c.message),i[u]=!0)}else t.consoleLoggingLevel()>=er.WARNING&&t.warnToConsole(c.message);t.logInternalMessage(e,c)}},t.warnToConsole=function(t){var e="undefined"!=typeof console?console:Ei("console");if(e){var n="log";e.warn&&(n="warn"),s(e[n])&&e[n](t)}},t.resetInternalMessageCount=function(){n=0,i={}},t.logInternalMessage=function(e,r){if(!(n>=t.maxInternalMessageLimit())){var o=!0,s="AITR_"+r.messageId;if(i[s]?o=!1:i[s]=!0,o&&(e<=t.telemetryLoggingLevel()&&(t.queue.push(r),n++),n===t.maxInternalMessageLimit())){var a="Internal events throttle limit per PageView reached for this app.",c=new yr(23,a,!1);t.queue.push(c),t.warnToConsole(a)}}}}))}return t.prototype.enableDebugExceptions=function(){return!1},t.prototype.consoleLoggingLevel=function(){return 0},t.prototype.telemetryLoggingLevel=function(){return 1},t.prototype.maxInternalMessageLimit=function(){return 25},t.prototype.throwInternal=function(){},t.prototype.warnToConsole=function(){},t.prototype.resetInternalMessageCount=function(){},t.prototype.logInternalMessage=function(){},t}(),kr=function(){function t(e,n,i){var r,o=this,s=!1;o.start=nr.dateNow(),o.name=e,o.isAsync=i,o.isChildEvt=function(){return!1},nr.isFunction(n)&&(s=nr.objDefineAccessors(o,"payload",(function(){return!r&&nr.isFunction(n)&&(r=n(),n=null),r}))),o.getCtx=function(e){return e?e===t.ParentContextKey||e===t.ChildrenContextKey?o[e]:(o.ctx||{})[e]:null},o.setCtx=function(e,n){e&&(e===t.ParentContextKey?(o[e]||(o.isChildEvt=function(){return!0}),o[e]=n):e===t.ChildrenContextKey?o[e]=n:(o.ctx=o.ctx||{})[e]=n)},o.complete=function(){var e=0,i=o.getCtx(t.ChildrenContextKey);if(nr.isArray(i))for(var r=0;r<i.length;r++){var a=i[r];a&&(e+=a.time)}o.time=nr.dateNow()-o.start,o.exTime=o.time-e,o.complete=function(){},!s&&nr.isFunction(n)&&(o.payload=n())}}return t.ParentContextKey="parent",t.ChildrenContextKey="childEvts",t}(),Sr=function(){function t(e){this.ctx={},gr(t,this,(function(t){t.create=function(t,e,n){return new kr(t,e,n)},t.fire=function(t){t&&(t.complete(),e&&e.perfEvent(t))},t.setCtx=function(e,n){e&&((t.ctx=t.ctx||{})[e]=n)},t.getCtx=function(e){return(t.ctx||{})[e]}}))}return t.prototype.create=function(){return null},t.prototype.fire=function(){},t.prototype.setCtx=function(){},t.prototype.getCtx=function(){},t}();function Cr(t,e,n,i,r){if(t){var o=t;if(o&&nr.isFunction(o.getPerfMgr)&&(o=o.getPerfMgr()),o){var s=void 0,a=o.getCtx("CoreUtils.doPerf");try{if(s=o.create(e(),i,r)){if(a&&s.setCtx&&(s.setCtx(kr.ParentContextKey,a),a.getCtx&&a.setCtx)){var c=a.getCtx(kr.ChildrenContextKey);c||a.setCtx(kr.ChildrenContextKey,c=[]),c.push(s)}return o.setCtx("CoreUtils.doPerf",s),n(s)}}catch(t){s&&s.setCtx&&s.setCtx("exception",t)}finally{s&&o.fire(s),o.setCtx("CoreUtils.doPerf",a)}}}return n()}var _r=nr.isFunction,Ar=function(t,e){var n=this,i=null,r=_r(t.processTelemetry),o=_r(t.setNextPlugin);n._hasRun=!1,n.getPlugin=function(){return t},n.getNext=function(){return i},n.setNext=function(t){i=t},n.processTelemetry=function(s,a){a||(a=e);var c=t?t.identifier:"TelemetryPluginChain";Cr(a?a.core():null,(function(){return c+":processTelemetry"}),(function(){if(t&&r){n._hasRun=!0;try{a.setNext(i),o&&t.setNextPlugin(i),i&&(i._hasRun=!1),t.processTelemetry(s,a)}catch(n){var e=i&&i._hasRun;i&&e||a.diagLog().throwInternal(er.CRITICAL,73,"Plugin ["+t.identifier+"] failed during processTelemetry - "+n),i&&!e&&i.processTelemetry(s,a)}}else i&&(n._hasRun=!0,i.processTelemetry(s,a))}),(function(){return{item:s}}),!s.sync)}},qr=nr.isNullOrUndefined;function Br(t,e){var n=[];if(t&&t.length>0)for(var i=null,r=0;r<t.length;r++){var o=t[r];if(o&&nr.isFunction(o.processTelemetry)){var s=new Ar(o,e);n.push(s),i&&i.setNext(s),i=s}}return n.length>0?n[0]:null}var jr=function t(e,n,i,r){var o=this,s=null;null!==r&&(e&&nr.isFunction(e.getPlugin)?s=function(t,e,n){var i=[],r=!n;if(t)for(;t;){var o=t.getPlugin();(r||o===n)&&(r=!0,i.push(o)),t=t.getNext()}return r||i.push(n),Br(i,e)}(e,o,r||e.getPlugin()):r?s=function(t,e,n){var i=t,r=!1;return n&&t&&(i=[],nr.arrForEach(t,(function(t){(r||t===n)&&(r=!0,i.push(t))}))),n&&!r&&(i||(i=[]),i.push(n)),Br(i,e)}(e,o,r):nr.isUndefined(r)&&(s=Br(e,o))),o.core=function(){return i},o.diagLog=function(){var t=(i||{}).logger;return t||(t=new xr(n||{})),t},o.getCfg=function(){return n},o.getExtCfg=function(t,e){var i;if(void 0===e&&(e={}),n){var r=n.extensionConfig;r&&t&&(i=r[t])}return i||e},o.getConfig=function(t,e,i){var r;void 0===i&&(i=!1);var s=o.getExtCfg(t,null);return s&&!qr(s[e])?r=s[e]:n&&!qr(n[e])&&(r=n[e]),qr(r)?i:r},o.hasNext=function(){return null!=s},o.getNext=function(){return s},o.setNext=function(t){s=t},o.processNext=function(t){var e=s;e&&(s=e.getNext(),e.processTelemetry(t,o))},o.createNew=function(e,r){return void 0===e&&(e=null),new t(e||s,n,i,r)}},Er=nr.isFunction,Ir=function(){function t(){var t=this,e=!1,n=null,i=null;t.core=null,t.diagLog=function(e){return t._getTelCtx(e).diagLog()},t.isInitialized=function(){return e},t.setInitialized=function(t){e=t},t.setNextPlugin=function(t){i=t},t.processNext=function(t,e){e?e.processNext(t):i&&Er(i.processTelemetry)&&i.processTelemetry(t,null)},t._getTelCtx=function(e){void 0===e&&(e=null);var r=e;r||(r=(n||new jr(null,{},t.core)).createNew(null,i&&i.getPlugin?i.getPlugin:i));return r},t._baseTelInit=function(r,o,s,a){r&&(r.extensionConfig=r.extensionConfig||[]),!a&&o&&(a=o.getProcessTelContext().getNext());var c=i;i&&i.getPlugin&&(c=i.getPlugin()),t.core=o,n=new jr(a,r,o,c),e=!0}}return t.prototype.initialize=function(t,e,n,i){this._baseTelInit(t,e,n,i)},t}(),Fr=nr.isFunction;function Pr(t,e){for(var n=[],i=null,r=t.getNext();r;){var o=r.getPlugin();o&&(i&&Fr(i.setNextPlugin)&&Fr(o.processTelemetry)&&i.setNextPlugin(o),Fr(o.isInitialized)&&o.isInitialized()||n.push(o),i=o,r=r.getNext())}nr.arrForEach(n,(function(n){n.initialize(t.getCfg(),t.core(),e,t.getNext())}))}function Rr(t){return t.sort((function(t,e){var n=0,i=Fr(e.processTelemetry);return Fr(t.processTelemetry)?n=i?t.priority-e.priority:1:i&&(n=-1),n}))}var Mr=nr.objDefineAccessors,Tr=function(t){function e(){var n=t.call(this)||this;n.identifier="ChannelControllerPlugin",n.priority=500;var i,r=nr.arrForEach;function o(t){t&&t.length>0&&(function(t){r(t,(function(t){if(t.priority<500)throw Error("Channel has invalid priority"+t.identifier)}))}(t=t.sort((function(t,e){return t.priority-e.priority}))),i.push(t))}return gr(e,n,(function(t,e){t.setNextPlugin=function(){},t.processTelemetry=function(t,e){i&&r(i,(function(i){i.length>0&&n._getTelCtx(e).createNew(i).processNext(t)}))},t.getChannelControls=function(){return i},t.initialize=function(n,s,a){t.isInitialized()||(e.initialize(n,s,a),n.isCookieUseDisabled&&nr.disableCookies(),function(t,e){if(i=[],t&&r(t,(function(t){return o(t)})),e){var n=[];r(e,(function(t){t.priority>500&&n.push(t)})),o(n)}}((n||{}).channels,a),r(i,(function(t){return Pr(new jr(t,n,s),a)})))}})),n}return __extends(e,t),e.prototype.processTelemetry=function(){},e.prototype.getChannelControls=function(){return null},e.prototype.initialize=function(){},e._staticInit=(Mr(e.prototype,"ChannelControls",e.prototype.getChannelControls),void Mr(e.prototype,"channelQueue",e.prototype.getChannelControls)),e}(Ir),Nr=nr.arrForEach,Dr=nr.isNullOrUndefined,Or=function(){function t(){var e,n,i,r,o=!1;gr(t,this,(function(t){t._extensions=new Array,n=new Tr,t.logger=nr.objCreate({throwInternal:function(){},warnToConsole:function(){},resetInternalMessageCount:function(){}}),e=[],t.isInitialized=function(){return o},t.initialize=function(e,r,s,a){if(t.isInitialized())throw Error("Core should not be initialized more than once");if(!e||Dr(e.instrumentationKey))throw Error("Please provide instrumentation key");i=a,t._notificationManager=a,t.config=e||{},e.extensions=Dr(e.extensions)?[]:e.extensions,(e.extensionConfig=Dr(e.extensionConfig)?{}:e.extensionConfig).NotificationManager=a,s&&(t.logger=s);var c=[];c.push.apply(c,r.concat(e.extensions)),c=Rr(c);var u=[],l={};if(Nr(c,(function(t){if(Dr(t)||Dr(t.initialize))throw Error("Extensions must provide callback to initialize");var e=t.priority,i=t.identifier;t&&e&&(Dr(l[e])?l[e]=i:s.warnToConsole("Two extensions have same priority #"+e+" - "+l[e]+", "+i)),(!e||e<n.priority)&&u.push(t)})),c.push(n),u.push(n),c=Rr(c),t._extensions=c,Pr(new jr([n],e,t),c),Pr(new jr(u,e,t),c),t._extensions=u,0===t.getTransmissionControls().length)throw new Error("No channels available");o=!0,t.releaseQueue()},t.getTransmissionControls=function(){return n.getChannelControls()},t.track=function(n){n.iKey||(n.iKey=t.config.instrumentationKey),n.time||(n.time=nr.toISOString(new Date)),Dr(n.ver)&&(n.ver="4.0"),t.isInitialized()?t.getProcessTelContext().processNext(n):e.push(n)},t.getProcessTelContext=function(){var e=t._extensions,i=e;return e&&0!==e.length||(i=[n]),new jr(i,t.config,t)},t.getNotifyMgr=function(){return i||(i=nr.objCreate({addNotificationListener:function(){},removeNotificationListener:function(){},eventsSent:function(){},eventsDiscarded:function(){},eventsSendRequest:function(){}}),t._notificationManager=i),i},t.getPerfMgr=function(){return r||t.config&&t.config.enablePerfMgr&&(r=new Sr(t.getNotifyMgr())),r},t.setPerfMgr=function(t){r=t},t.eventCnt=function(){return e.length},t.releaseQueue=function(){e.length>0&&(Nr(e,(function(e){t.getProcessTelContext().processNext(e)})),e=[])}}))}return t.prototype.initialize=function(){},t.prototype.getTransmissionControls=function(){return null},t.prototype.track=function(){},t.prototype.getProcessTelContext=function(){return null},t.prototype.getNotifyMgr=function(){return null},t.prototype.getPerfMgr=function(){return null},t.prototype.setPerfMgr=function(){},t.prototype.eventCnt=function(){return 0},t.prototype.releaseQueue=function(){},t}(),Ur=function(){function t(e){this.listeners=[];var n=nr.arrForEach,i=!!(e||{}).perfEvtsSendAll;gr(t,this,(function(t){t.addNotificationListener=function(e){t.listeners.push(e)},t.removeNotificationListener=function(e){for(var n=nr.arrIndexOf(t.listeners,e);n>-1;)t.listeners.splice(n,1),n=nr.arrIndexOf(t.listeners,e)},t.eventsSent=function(e){n(t.listeners,(function(t){t&&t.eventsSent&&setTimeout((function(){return t.eventsSent(e)}),0)}))},t.eventsDiscarded=function(e,i){n(t.listeners,(function(t){t&&t.eventsDiscarded&&setTimeout((function(){return t.eventsDiscarded(e,i)}),0)}))},t.eventsSendRequest=function(e,i){n(t.listeners,(function(t){if(t&&t.eventsSendRequest)if(i)setTimeout((function(){return t.eventsSendRequest(e,i)}),0);else try{t.eventsSendRequest(e,i)}catch(t){}}))},t.perfEvent=function(e){e&&(!i&&e.isChildEvt()||n(t.listeners,(function(t){if(t&&t.perfEvent)if(e.isAsync)setTimeout((function(){return t.perfEvent(e)}),0);else try{t.perfEvent(e)}catch(t){}})))}}))}return t.prototype.addNotificationListener=function(){},t.prototype.removeNotificationListener=function(){},t.prototype.eventsSent=function(){},t.prototype.eventsDiscarded=function(){},t.prototype.eventsSendRequest=function(){},t}(),Lr=function(t){function e(){var n=t.call(this)||this;return gr(e,n,(function(t,e){function n(e){var n=t.getNotifyMgr();n&&n.eventsDiscarded([e],2)}t.initialize=function(t,n,i,r){e.initialize(t,n,i||new xr(t),r||new Ur(t))},t.track=function(i){Cr(t.getPerfMgr(),(function(){return"AppInsightsCore:track"}),(function(){if(null===i)throw n(i),Error("Invalid telemetry item");!function(t){if(nr.isNullOrUndefined(t.name))throw n(t),Error("telemetry name required")}(i),e.track(i)}),(function(){return{item:i}}),!i.sync)},t.addNotificationListener=function(e){var n=t.getNotifyMgr();n&&n.addNotificationListener(e)},t.removeNotificationListener=function(e){var n=t.getNotifyMgr();n&&n.removeNotificationListener(e)},t.pollInternalLogs=function(e){var n=t.config.diagnosticLogInterval;return n&&n>0||(n=1e4),setInterval((function(){var n=t.logger?t.logger.queue:[];nr.arrForEach(n,(function(n){var i={name:e||"InternalMessageId: "+n.messageId,iKey:t.config.instrumentationKey,time:nr.toISOString(new Date),baseType:yr.dataType,baseData:{message:n.message}};t.track(i)})),n.length=0}),n)}})),n}return __extends(e,t),e.prototype.initialize=function(){},e.prototype.track=function(){},e.prototype.addNotificationListener=function(){},e.prototype.removeNotificationListener=function(){},e.prototype.pollInternalLogs=function(){return 0},e}(Or),zr=["req","rsp","hkErr","fnErr"];function Hr(t,e){if(t)for(var n=0;n<t.length&&!e(t[n],n);n++);}function Vr(t,e,n,i,r){r>=0&&r<=2&&Hr(t,(function(t,o){var s=t.cbks,a=s[zr[r]];if(a){e.ctx=function(){return i[o]=i[o]||{}};try{a.apply(e.inst,n)}catch(t){var c=e.err;try{var u=s[zr[2]];u&&(e.err=t,u.apply(e.inst,n))}catch(t){}finally{e.err=c}}}}))}var Qr,Wr,$r,Yr=Object.getPrototypeOf;function Xr(t,e,n){var i=null;return t&&(nr.hasOwnProperty(t,e)?i=t:n&&(i=Xr(function(t){if(t){if(Yr)return Yr(t);var e=t.__proto__||t.prototype||t.constructor;if(e)return e}return null}(t),e,!1))),i}function Jr(t,e,n,i){if(void 0===i&&(i=!0),t&&e&&n){var r=Xr(t,e,i);if(r){var o=r[e];if("function"==typeof o){var s=o._aiHooks;if(!s){var a=(u=s={i:0,n:e,f:o,h:[]},function(){var t=this,e=arguments,n=u.h,i={name:u.n,inst:t,ctx:null,set:a},r=[],o=s([i],e);function s(t,e){return Hr(e,(function(e){t.push(e)})),t}function a(t,n){(e=s([],e))[t]=n,o=s([i],e)}Vr(n,i,o,r,0);var c=u.f;try{i.rslt=c.apply(t,e)}catch(t){throw i.err=t,Vr(n,i,o,r,3),t}return Vr(n,i,o,r,1),i.rslt});a._aiHooks=s,r[e]=a}var c={id:s.i,cbks:n,rm:function(){var t=this.id;Hr(s.h,(function(e,n){if(e.id===t)return s.h.splice(n,1),1}))}};return s.i++,s.h.push(c),c}}}var u;return null}!function(t){t[t.LocalStorage=0]="LocalStorage",t[t.SessionStorage=1]="SessionStorage"}(Qr||(Qr={})),function(t){t[t.Default=0]="Default",t[t.Required=1]="Required",t[t.Array=2]="Array",t[t.Hidden=4]="Hidden"}(Wr||(Wr={})),function(t){t[t.AI=0]="AI",t[t.AI_AND_W3C=1]="AI_AND_W3C",t[t.W3C=2]="W3C"}($r||($r={}));var Gr,Kr=function(){function t(){}return t.requestContextHeader="Request-Context",t.requestContextTargetKey="appId",t.requestContextAppIdFormat="appId=cid-v1:",t.requestIdHeader="Request-Id",t.traceParentHeader="traceparent",t.sdkContextHeader="Sdk-Context",t.sdkContextHeaderAppIdRequest="appId",t.requestContextHeaderLowerCase="request-context",t}(),Zr=function(){function t(){}return t.sanitizeKeyAndAddUniqueness=function(e,n,i){var r=n.length,o=t.sanitizeKey(e,n);if(o.length!==r){for(var s=0,a=o;void 0!==i[a];)s++,a=o.substring(0,t.MAX_NAME_LENGTH-3)+t.padNumber(s);o=a}return o},t.sanitizeKey=function(e,n){var i;return n&&(n=t.trim(n.toString())).length>t.MAX_NAME_LENGTH&&(i=n.substring(0,t.MAX_NAME_LENGTH),e.throwInternal(er.WARNING,57,"name is too long. It has been truncated to "+t.MAX_NAME_LENGTH+" characters.",{name:n},!0)),i||n},t.sanitizeString=function(e,n,i){var r;return void 0===i&&(i=t.MAX_STRING_LENGTH),n&&(i=i||t.MAX_STRING_LENGTH,(n=t.trim(n)).toString().length>i&&(r=n.toString().substring(0,i),e.throwInternal(er.WARNING,61,"string value is too long. It has been truncated to "+i+" characters.",{value:n},!0))),r||n},t.sanitizeUrl=function(e,n){return t.sanitizeInput(e,n,t.MAX_URL_LENGTH,66)},t.sanitizeMessage=function(e,n){var i;return n&&n.length>t.MAX_MESSAGE_LENGTH&&(i=n.substring(0,t.MAX_MESSAGE_LENGTH),e.throwInternal(er.WARNING,56,"message is too long, it has been truncated to "+t.MAX_MESSAGE_LENGTH+" characters.",{message:n},!0)),i||n},t.sanitizeException=function(e,n){var i;return n&&n.length>t.MAX_EXCEPTION_LENGTH&&(i=n.substring(0,t.MAX_EXCEPTION_LENGTH),e.throwInternal(er.WARNING,52,"exception is too long, it has been truncated to "+t.MAX_EXCEPTION_LENGTH+" characters.",{exception:n},!0)),i||n},t.sanitizeProperties=function(e,n){if(n){var i={};tr(n,(function(n,r){if(nr.isObject(r)&&Di())try{r=Oi().stringify(r)}catch(t){e.throwInternal(er.WARNING,49,"custom property is not valid",{exception:t},!0)}r=t.sanitizeString(e,r,t.MAX_PROPERTY_LENGTH),n=t.sanitizeKeyAndAddUniqueness(e,n,i),i[n]=r})),n=i}return n},t.sanitizeMeasurements=function(e,n){if(n){var i={};tr(n,(function(n,r){n=t.sanitizeKeyAndAddUniqueness(e,n,i),i[n]=r})),n=i}return n},t.sanitizeId=function(e,n){return n?t.sanitizeInput(e,n,t.MAX_ID_LENGTH,69).toString():n},t.sanitizeInput=function(e,n,i,r){var o;return n&&(n=t.trim(n)).length>i&&(o=n.substring(0,i),e.throwInternal(er.WARNING,r,"input is too long, it has been truncated to "+i+" characters.",{data:n},!0)),o||n},t.padNumber=function(t){var e="00"+t;return e.substr(e.length-3)},t.trim=function(t){return nr.isString(t)?t.replace(/^\s+|\s+$/g,""):t},t.MAX_NAME_LENGTH=150,t.MAX_ID_LENGTH=128,t.MAX_PROPERTY_LENGTH=8192,t.MAX_STRING_LENGTH=1024,t.MAX_URL_LENGTH=2048,t.MAX_MESSAGE_LENGTH=32768,t.MAX_EXCEPTION_LENGTH=32768,t}(),to=Mi(),eo=nr.isString,no=null,io=function(){function t(){}return t.createDomEvent=function(t){var e=null;if(nr.isFunction(Event))e=new Event(t);else{var n=Ri();n&&n.createEvent&&(e=n.createEvent("Event")).initEvent(t,!0,!0)}return e},t.disableStorage=function(){t._canUseLocalStorage=!1,t._canUseSessionStorage=!1},t._getLocalStorageObject=function(){return t.canUseLocalStorage()?t._getVerifiedStorageObject(Qr.LocalStorage):null},t._getVerifiedStorageObject=function(t){var e,n,i=null;try{if(nr.isNullOrUndefined(ji()))return null;n=new Date,(i=Ei(t===Qr.LocalStorage?"localStorage":"sessionStorage")).setItem(n.toString(),n.toString()),e=i.getItem(n.toString())!==n.toString(),i.removeItem(n.toString()),e&&(i=null)}catch(t){i=null}return i},t.isInternalApplicationInsightsEndpoint=function(e){return-1!==t._internalEndpoints.indexOf(e.toLowerCase())},t.canUseLocalStorage=function(){return void 0===t._canUseLocalStorage&&(t._canUseLocalStorage=!!t._getVerifiedStorageObject(Qr.LocalStorage)),t._canUseLocalStorage},t.getStorage=function(e,n){var i=t._getLocalStorageObject();if(null!==i)try{return i.getItem(n)}catch(n){t._canUseLocalStorage=!1,e.throwInternal(er.WARNING,1,"Browser failed read of local storage. "+t.getExceptionName(n),{exception:t.dump(n)})}return null},t.setStorage=function(e,n,i){var r=t._getLocalStorageObject();if(null!==r)try{return r.setItem(n,i),!0}catch(n){t._canUseLocalStorage=!1,e.throwInternal(er.WARNING,3,"Browser failed write to local storage. "+t.getExceptionName(n),{exception:t.dump(n)})}return!1},t.removeStorage=function(e,n){var i=t._getLocalStorageObject();if(null!==i)try{return i.removeItem(n),!0}catch(n){t._canUseLocalStorage=!1,e.throwInternal(er.WARNING,5,"Browser failed removal of local storage item. "+t.getExceptionName(n),{exception:t.dump(n)})}return!1},t._getSessionStorageObject=function(){return t.canUseSessionStorage()?t._getVerifiedStorageObject(Qr.SessionStorage):null},t.canUseSessionStorage=function(){return void 0===t._canUseSessionStorage&&(t._canUseSessionStorage=!!t._getVerifiedStorageObject(Qr.SessionStorage)),t._canUseSessionStorage},t.getSessionStorageKeys=function(){var e=[];return t.canUseSessionStorage()&&tr(Ei("sessionStorage"),(function(t){e.push(t)})),e},t.getSessionStorage=function(e,n){var i=t._getSessionStorageObject();if(null!==i)try{return i.getItem(n)}catch(n){t._canUseSessionStorage=!1,e.throwInternal(er.WARNING,2,"Browser failed read of session storage. "+t.getExceptionName(n),{exception:t.dump(n)})}return null},t.setSessionStorage=function(e,n,i){var r=t._getSessionStorageObject();if(null!==r)try{return r.setItem(n,i),!0}catch(n){t._canUseSessionStorage=!1,e.throwInternal(er.WARNING,4,"Browser failed write to session storage. "+t.getExceptionName(n),{exception:t.dump(n)})}return!1},t.removeSessionStorage=function(e,n){var i=t._getSessionStorageObject();if(null!==i)try{return i.removeItem(n),!0}catch(n){t._canUseSessionStorage=!1,e.throwInternal(er.WARNING,6,"Browser failed removal of session storage item. "+t.getExceptionName(n),{exception:t.dump(n)})}return!1},t.disableCookies=function(){nr.disableCookies()},t.canUseCookies=function(e){if(void 0===nr._canUseCookies){nr._canUseCookies=!1;try{nr._canUseCookies=void 0!==t.document.cookie}catch(n){e.throwInternal(er.WARNING,68,"Cannot access document.cookie - "+t.getExceptionName(n),{exception:t.dump(n)})}}return nr._canUseCookies},t.disallowsSameSiteNone=function(t){return!!eo(t)&&(-1!==t.indexOf("CPU iPhone OS 12")||-1!==t.indexOf("iPad; CPU OS 12")||-1!==t.indexOf("Macintosh; Intel Mac OS X 10_14")&&-1!==t.indexOf("Version/")&&-1!==t.indexOf("Safari")||-1!==t.indexOf("Macintosh; Intel Mac OS X 10_14")&&"AppleWebKit/605.1.15 (KHTML, like Gecko)"===(e=t).substring((i=(n=e.length)-"AppleWebKit/605.1.15 (KHTML, like Gecko)".length)>=0?i:0,n)||-1!==t.indexOf("Chrome/5")||-1!==t.indexOf("Chrome/6")||-1!==t.indexOf("UnrealEngine")&&-1===t.indexOf("Chrome")||-1!==t.indexOf("UCBrowser/12")||-1!==t.indexOf("UCBrowser/11"));var e,n,i},t.setCookie=function(e,n,i,r){if(t.canUseCookies(e)){var o="",s="";r&&(o=";domain="+r);var a=Ti();a&&"https:"===a.protocol&&(s=";secure",null===no&&(no=t.disallowsSameSiteNone((Mi()||{}).userAgent)),no||(i+=";SameSite=None")),t.document.cookie=n+"="+i+o+";path=/"+s}},t.stringToBoolOrDefault=function(t,e){return void 0===e&&(e=!1),null==t?e:"true"===t.toString().toLowerCase()},t.getCookie=function(e,n){if(t.canUseCookies(e)){var i="";if(n&&n.length)for(var r=n+"=",o=t.document.cookie.split(";"),s=0;s<o.length;s++){var a=o[s];if((a=t.trim(a))&&0===a.indexOf(r)){i=a.substring(r.length,o[s].length);break}}return i}},t.deleteCookie=function(e,n){t.canUseCookies(e)&&(t.document.cookie=n+"=;path=/;expires=Thu, 01 Jan 1970 00:00:01 GMT;")},t.random32=function(){return nr.random32(!0)},t.getIEVersion=function(t){void 0===t&&(t=null);var e=t?t.toLowerCase():to?(to.userAgent||"").toLowerCase():"";if(-1!==e.indexOf("msie"))return parseInt(e.split("msie")[1]);if(e.indexOf("trident/")){var n=parseInt(e.split("trident/")[1]);if(n)return n+4}return null},t.msToTimeSpan=function(t){(isNaN(t)||t<0)&&(t=0);var e=""+(t=Math.round(t))%1e3,n=""+Math.floor(t/1e3)%60,i=""+Math.floor(t/6e4)%60,r=""+Math.floor(t/36e5)%24,o=Math.floor(t/864e5);return(o>0?o+".":"")+(r=r.length<2?"0"+r:r)+":"+(i=i.length<2?"0"+i:i)+":"+(n=n.length<2?"0"+n:n)+"."+(1===e.length?"00"+e:2===e.length?"0"+e:e)},t.isCrossOriginError=function(t,e,n,i,r){return("Script error."===t||"Script error"===t)&&!r},t.dump=function(t){var e=Object.prototype.toString.call(t),n="";return"[object Error]"===e?n="{ stack: '"+t.stack+"', message: '"+t.message+"', name: '"+t.name+"'":Di()&&(n=Oi().stringify(t)),e+n},t.getExceptionName=function(t){return"[object Error]"===Object.prototype.toString.call(t)?t.name:""},t.addEventHandler=function(t,e){return rr.Attach(Fi(),t,e)},t.IsBeaconApiSupported=function(){return"sendBeacon"in to&&to.sendBeacon},t.getExtension=function(t,e){for(var n=null,i=0;!n&&i<t.length;)t[i]&&t[i].identifier===e&&(n=t[i]),i++;return n},t.document=Ri()||{},t._canUseLocalStorage=void 0,t._canUseSessionStorage=void 0,t._internalEndpoints=["https://dc.services.visualstudio.com/v2/track","https://breeze.aimon.applicationinsights.io/v2/track","https://dc-int.services.visualstudio.com/v2/track"],t.NotSpecified="not_specified",t.trim=nr.strTrim,t.newId=nr.newId,t.generateW3CId=nr.generateW3CId,t.isArray=nr.isArray,t.isError=nr.isError,t.isDate=nr.isDate,t.toISOStringForIE8=nr.toISOString,t}(),ro=function(){function t(){}return t.parseUrl=function(e){var n=t._htmlAnchorIdx,i=t._htmlAnchorElement,r=i[n];return t.document.createElement?i[n]||(r=i[n]=t.document.createElement("a")):r={host:t.parseHost(e,!0)},r.href=e,++n>=i.length&&(n=0),t._htmlAnchorIdx=n,r},t.getAbsoluteUrl=function(e){var n,i=t.parseUrl(e);return i&&(n=i.href),n},t.getPathName=function(e){var n,i=t.parseUrl(e);return i&&(n=i.pathname),n},t.getCompleteUrl=function(t,e){return t?t.toUpperCase()+" "+e:e},t.parseHost=function(e,n){var i=t.parseFullHost(e,n);if(i){var r=i.match(/(www[0-9]?\.)?(.[^/:]+)(\:[\d]+)?/i);if(null!=r&&r.length>3&&eo(r[2])&&r[2].length>0)return r[2]+(r[3]||"")}return i},t.parseFullHost=function(t,e){var n=null;if(t){var i=t.match(/(\w*):\/\/(.[^/:]+)(\:[\d]+)?/i);if(null!=i&&i.length>2&&eo(i[2])&&i[2].length>0&&(n=i[2]||"",e&&i.length>2)){var r=(i[1]||"").toLowerCase(),o=i[3]||"";("http"===r&&":80"===o||"https"===r&&":443"===o)&&(o=""),n+=o}}return n},t.document=Ri()||{},t._htmlAnchorIdx=0,t._htmlAnchorElement=[null,null,null,null,null],t}(),oo=function(){function t(){}return t.canIncludeCorrelationHeader=function(t,e,n){if(!e||t&&t.disableCorrelationHeaders)return!1;if(t&&t.correlationHeaderExcludePatterns)for(var i=0;i<t.correlationHeaderExcludePatterns.length;i++)if(t.correlationHeaderExcludePatterns[i].test(e))return!1;var r=ro.parseUrl(e).host.toLowerCase();if(!r||-1===r.indexOf(":443")&&-1===r.indexOf(":80")||(r=(ro.parseFullHost(e,!0)||"").toLowerCase()),!(t&&t.enableCorsCorrelation||r===n))return!1;var o,s=t&&t.correlationHeaderDomains;if(s&&(nr.arrForEach(s,(function(t){var e=new RegExp(t.toLowerCase().replace(/\./g,".").replace(/\*/g,".*"));o=o||e.test(r)})),!o))return!1;var a=t&&t.correlationHeaderExcludedDomains;if(!a||0===a.length)return!0;for(i=0;i<a.length;i++)if(new RegExp(a[i].toLowerCase().replace(/\./g,".").replace(/\*/g,".*")).test(r))return!1;return r&&r.length>0},t.getCorrelationContext=function(e){if(e){var n=t.getCorrelationContextValue(e,Kr.requestContextTargetKey);if(n&&n!==t.correlationIdPrefix)return n}},t.getCorrelationContextValue=function(t,e){if(t)for(var n=t.split(","),i=0;i<n.length;++i){var r=n[i].split("=");if(2===r.length&&r[0]===e)return r[1]}},t.correlationIdPrefix="cid-v1:",t}(),so=function(){function t(){}return t.ParseDependencyPath=function(t,e,n,i){var r,o=i,s=i;if(e&&e.length>0){var a=ro.parseUrl(e);if(r=a.host,!o)if(null!=a.pathname){var c=0===a.pathname.length?"/":a.pathname;"/"!==c.charAt(0)&&(c="/"+c),s=a.pathname,o=Zr.sanitizeString(t,n?n+" "+c:c)}else o=Zr.sanitizeString(t,e)}else r=i,o=i;return{target:r,name:o,data:s}},t}(),ao=function(){function t(){}return t.Now=function(){var t=Ni();if(t&&t.now&&t.timing){var e=t.now()+t.timing.navigationStart;if(e>0)return e}return(new Date).getTime()},t.GetDuration=function(t,e){var n=null;return 0===t||0===e||nr.isNullOrUndefined(t)||nr.isNullOrUndefined(e)||(n=e-t),n},t}(),co="Microsoft_ApplicationInsights_BypassAjaxInstrumentation",uo=function(){function t(){}return t.parse=function(e){if(!e)return{};var n=e.split(t._FIELDS_SEPARATOR),i=nr.arrReduce(n,(function(e,n){var i=n.split(t._FIELD_KEY_VALUE_SEPARATOR);return 2===i.length&&(e[i[0].toLowerCase()]=i[1]),e}),{});return nr.objKeys(i).length>0&&(i.endpointsuffix&&(i.ingestionendpoint=i.ingestionendpoint||"https://"+(i.location?i.location+".":"")+"dc."+i.endpointsuffix),i.ingestionendpoint=i.ingestionendpoint||"https://dc.services.visualstudio.com"),i},t._FIELDS_SEPARATOR=";",t._FIELD_KEY_VALUE_SEPARATOR="=",t}(),lo=function(t){function e(){return t.call(this)||this}return __extends(e,t),e}((function(){})),fo=function(t){function e(e,n,i){var r=t.call(this)||this;return r.name=Zr.sanitizeString(e,i)||io.NotSpecified,r.data=n,r.time=nr.toISOString(new Date),r.aiDataContract={time:Wr.Required,iKey:Wr.Required,name:Wr.Required,sampleRate:function(){return 100===r.sampleRate?Wr.Hidden:Wr.Required},tags:Wr.Required,data:Wr.Required},r}return __extends(e,t),e}((function(){this.ver=1,this.sampleRate=100,this.tags={}})),ho=function(){},po=function(t){function e(){var e=t.call(this)||this;return e.ver=2,e.properties={},e.measurements={},e}return __extends(e,t),e}(ho),mo=function(t){function e(e,n,i,r){var o=t.call(this)||this;return o.aiDataContract={ver:Wr.Required,name:Wr.Required,properties:Wr.Default,measurements:Wr.Default},o.name=Zr.sanitizeString(e,n)||io.NotSpecified,o.properties=Zr.sanitizeProperties(e,i),o.measurements=Zr.sanitizeMeasurements(e,r),o}return __extends(e,t),e.envelopeType="Microsoft.ApplicationInsights.{0}.Event",e.dataType="EventData",e}(po),vo=function(t){function e(e,n,i,r,o,s){var a,c=t.call(this)||this;return c.aiDataContract={ver:Wr.Required,exceptions:Wr.Required,severityLevel:Wr.Default,properties:Wr.Default,measurements:Wr.Default},"ver"in(a=n)&&"exceptions"in a&&"properties"in a?(c.exceptions=n.exceptions,c.properties=n.properties,c.measurements=n.measurements,n.severityLevel&&(c.severityLevel=n.severityLevel),n.id&&(c.id=n.id),n.problemGroup&&(c.problemGroup=n.problemGroup),c.ver=2,nr.isNullOrUndefined(n.isManual)||(c.isManual=n.isManual)):(c.exceptions=[new bo(e,n)],c.properties=Zr.sanitizeProperties(e,i)||{},c.measurements=Zr.sanitizeMeasurements(e,r),o&&(c.severityLevel=o),s&&(c.id=s)),c}return __extends(e,t),e.CreateFromInterface=function(t,n,i,r){var o=n.exceptions&&nr.arrMap(n.exceptions,(function(e){return bo.CreateFromInterface(t,e)}));return new e(t,__assign({},n,{exceptions:o}),i,r)},e.prototype.toInterface=function(){var t=this,e=t.exceptions,n=t.properties,i=t.measurements,r=t.severityLevel,o=t.problemGroup,s=t.id,a=t.isManual;return{ver:"4.0",exceptions:e instanceof Array&&nr.arrMap(e,(function(t){return t.toInterface()}))||void 0,severityLevel:r,properties:n,measurements:i,problemGroup:o,id:s,isManual:a}},e.CreateSimpleException=function(t,e,n,i,r){return{exceptions:[{hasFullStack:!0,message:t,stack:r,typeName:e}]}},e.envelopeType="Microsoft.ApplicationInsights.{0}.Exception",e.dataType="ExceptionData",e}(function(t){function e(){var e=t.call(this)||this;return e.ver=2,e.exceptions=[],e.properties={},e.measurements={},e}return __extends(e,t),e}(ho)),bo=function(t){function e(n,i){var r,o=t.call(this)||this;if(o.aiDataContract={id:Wr.Default,outerId:Wr.Default,typeName:Wr.Required,message:Wr.Required,hasFullStack:Wr.Default,stack:Wr.Default,parsedStack:Wr.Array},"hasFullStack"in(r=i)&&"typeName"in r)o.typeName=i.typeName,o.message=i.message,o.stack=i.stack,o.parsedStack=i.parsedStack,o.hasFullStack=i.hasFullStack;else{var s=i;io.isError(s)||(s=s.error||s.evt||s),o.typeName=Zr.sanitizeString(n,function(t){var e="";if(t&&!(e=t.typeName||t.name||""))try{var n=/function (.{1,})\(/.exec(t.constructor.toString());e=n&&n.length>1?n[1]:""}catch(t){}return e}(s))||io.NotSpecified,o.message=Zr.sanitizeMessage(n,i.message)||io.NotSpecified;var a=i.stack;o.parsedStack=e.parseStack(a),o.stack=Zr.sanitizeException(n,a),o.hasFullStack=io.isArray(o.parsedStack)&&o.parsedStack.length>0}return o}return __extends(e,t),e.prototype.toInterface=function(){var t=this.parsedStack instanceof Array&&nr.arrMap(this.parsedStack,(function(t){return t.toInterface()}));return{id:this.id,outerId:this.outerId,typeName:this.typeName,message:this.message,hasFullStack:this.hasFullStack,stack:this.stack,parsedStack:t||void 0}},e.CreateFromInterface=function(t,n){var i=n.parsedStack instanceof Array&&nr.arrMap(n.parsedStack,(function(t){return go.CreateFromInterface(t)}))||n.parsedStack;return new e(t,__assign({},n,{parsedStack:i}))},e.parseStack=function(t){var e;if(nr.isString(t)){var n=t.split("\n");e=[];for(var i=0,r=0,o=0;o<=n.length;o++)if(go.regex.test(n[o])){var s=new go(n[o],i++);r+=s.sizeInBytes,e.push(s)}if(r>32768)for(var a=0,c=e.length-1,u=0,l=a,f=c;a<c;){if((u+=e[a].sizeInBytes+e[c].sizeInBytes)>32768){e.splice(l,f-l+1);break}l=a,f=c,a++,c--}}return e},e}((function(){this.hasFullStack=!0,this.parsedStack=[]})),go=function(t){function e(n,i){var r=t.call(this)||this;if(r.sizeInBytes=0,r.aiDataContract={level:Wr.Required,method:Wr.Required,assembly:Wr.Default,fileName:Wr.Default,line:Wr.Default},"string"==typeof n){var o=n;r.level=i,r.method="<no_method>",r.assembly=io.trim(o),r.fileName="",r.line=0;var s=o.match(e.regex);s&&s.length>=5&&(r.method=io.trim(s[2])||r.method,r.fileName=io.trim(s[4]),r.line=parseInt(s[5])||0)}else r.level=n.level,r.method=n.method,r.assembly=n.assembly,r.fileName=n.fileName,r.line=n.line,r.sizeInBytes=0;return r.sizeInBytes+=r.method.length,r.sizeInBytes+=r.fileName.length,r.sizeInBytes+=r.assembly.length,r.sizeInBytes+=e.baseSize,r.sizeInBytes+=r.level.toString().length,r.sizeInBytes+=r.line.toString().length,r}return __extends(e,t),e.CreateFromInterface=function(t){return new e(t,null)},e.prototype.toInterface=function(){return{level:this.level,method:this.method,assembly:this.assembly,fileName:this.fileName,line:this.line}},e.regex=/^([\s]+at)?(.*?)(\@|\s\(|\s)([^\(\@\n]+):([0-9]+):([0-9]+)(\)?)$/,e.baseSize=58,e}((function(){})),wo=function(t){function e(){var e=t.call(this)||this;return e.ver=2,e.metrics=[],e.properties={},e.measurements={},e}return __extends(e,t),e}(ho);!function(t){t[t.Measurement=0]="Measurement",t[t.Aggregation=1]="Aggregation"}(Gr||(Gr={}));var yo,xo=function(t){function e(){var e=null!==t&&t.apply(this,arguments)||this;return e.aiDataContract={name:Wr.Required,kind:Wr.Default,value:Wr.Required,count:Wr.Default,min:Wr.Default,max:Wr.Default,stdDev:Wr.Default},e}return __extends(e,t),e}((function(){this.kind=Gr.Measurement})),ko=function(t){function e(e,n,i,r,o,s,a,c){var u=t.call(this)||this;u.aiDataContract={ver:Wr.Required,metrics:Wr.Required,properties:Wr.Default};var l=new xo;return l.count=r>0?r:void 0,l.max=isNaN(s)||null===s?void 0:s,l.min=isNaN(o)||null===o?void 0:o,l.name=Zr.sanitizeString(e,n)||io.NotSpecified,l.value=i,u.metrics=[l],u.properties=Zr.sanitizeProperties(e,a),u.measurements=Zr.sanitizeMeasurements(e,c),u}return __extends(e,t),e.envelopeType="Microsoft.ApplicationInsights.{0}.Metric",e.dataType="MetricData",e}(wo),So=function(t){function e(){var e=t.call(this)||this;return e.ver=2,e.properties={},e.measurements={},e}return __extends(e,t),e}(po),Co=function(t){function e(e,n,i,r,o,s,a){var c=t.call(this)||this;return c.aiDataContract={ver:Wr.Required,name:Wr.Default,url:Wr.Default,duration:Wr.Default,properties:Wr.Default,measurements:Wr.Default,id:Wr.Default},c.id=Zr.sanitizeId(e,a),c.url=Zr.sanitizeUrl(e,i),c.name=Zr.sanitizeString(e,n)||io.NotSpecified,isNaN(r)||(c.duration=io.msToTimeSpan(r)),c.properties=Zr.sanitizeProperties(e,o),c.measurements=Zr.sanitizeMeasurements(e,s),c}return __extends(e,t),e.envelopeType="Microsoft.ApplicationInsights.{0}.Pageview",e.dataType="PageviewData",e}(So),_o=function(t){function e(e,n,i,r,o,s,a,c,u,l,f,d){void 0===u&&(u="Ajax");var h=t.call(this)||this;h.aiDataContract={id:Wr.Required,ver:Wr.Required,name:Wr.Default,resultCode:Wr.Default,duration:Wr.Default,success:Wr.Default,data:Wr.Default,target:Wr.Default,type:Wr.Default,properties:Wr.Default,measurements:Wr.Default,kind:Wr.Default,value:Wr.Default,count:Wr.Default,min:Wr.Default,max:Wr.Default,stdDev:Wr.Default,dependencyKind:Wr.Default,dependencySource:Wr.Default,commandName:Wr.Default,dependencyTypeName:Wr.Default},h.id=n,h.duration=io.msToTimeSpan(o),h.success=s,h.resultCode=a+"",h.type=Zr.sanitizeString(e,u);var p=so.ParseDependencyPath(e,i,c,r);return h.data=Zr.sanitizeUrl(e,r)||p.data,h.target=Zr.sanitizeString(e,p.target),l&&(h.target=h.target+" | "+l),h.name=Zr.sanitizeString(e,p.name),h.properties=Zr.sanitizeProperties(e,f),h.measurements=Zr.sanitizeMeasurements(e,d),h}return __extends(e,t),e.envelopeType="Microsoft.ApplicationInsights.{0}.RemoteDependency",e.dataType="RemoteDependencyData",e}(function(t){function e(){var e=t.call(this)||this;return e.ver=2,e.success=!0,e.properties={},e.measurements={},e}return __extends(e,t),e}(ho)),Ao=function(t){function e(e,n,i,r,o){var s=t.call(this)||this;return s.aiDataContract={ver:Wr.Required,message:Wr.Required,severityLevel:Wr.Default,properties:Wr.Default},s.message=Zr.sanitizeMessage(e,n=n||io.NotSpecified),s.properties=Zr.sanitizeProperties(e,r),s.measurements=Zr.sanitizeMeasurements(e,o),i&&(s.severityLevel=i),s}return __extends(e,t),e.envelopeType="Microsoft.ApplicationInsights.{0}.Message",e.dataType="MessageData",e}(function(t){function e(){var e=t.call(this)||this;return e.ver=2,e.properties={},e.measurements={},e}return __extends(e,t),e}(ho)),qo=function(t){function e(e,n,i,r,o,s,a){var c=t.call(this)||this;return c.aiDataContract={ver:Wr.Required,name:Wr.Default,url:Wr.Default,duration:Wr.Default,perfTotal:Wr.Default,networkConnect:Wr.Default,sentRequest:Wr.Default,receivedResponse:Wr.Default,domProcessing:Wr.Default,properties:Wr.Default,measurements:Wr.Default},c.url=Zr.sanitizeUrl(e,i),c.name=Zr.sanitizeString(e,n)||io.NotSpecified,c.properties=Zr.sanitizeProperties(e,o),c.measurements=Zr.sanitizeMeasurements(e,s),a&&(c.domProcessing=a.domProcessing,c.duration=a.duration,c.networkConnect=a.networkConnect,c.perfTotal=a.perfTotal,c.receivedResponse=a.receivedResponse,c.sentRequest=a.sentRequest),c}return __extends(e,t),e.envelopeType="Microsoft.ApplicationInsights.{0}.PageviewPerformance",e.dataType="PageviewPerformanceData",e}(function(t){function e(){var e=t.call(this)||this;return e.ver=2,e.properties={},e.measurements={},e}return __extends(e,t),e}(So)),Bo=function(t){function e(e,n){var i=t.call(this)||this;return i.aiDataContract={baseType:Wr.Required,baseData:Wr.Required},i.baseType=e,i.baseData=n,i}return __extends(e,t),e}(lo);!function(t){t[t.Verbose=0]="Verbose",t[t.Information=1]="Information",t[t.Warning=2]="Warning",t[t.Error=3]="Error",t[t.Critical=4]="Critical"}(yo||(yo={}));var jo=function(){this.applicationVersion="ai.application.ver",this.applicationBuild="ai.application.build",this.applicationTypeId="ai.application.typeId",this.applicationId="ai.application.applicationId",this.applicationLayer="ai.application.layer",this.deviceId="ai.device.id",this.deviceIp="ai.device.ip",this.deviceLanguage="ai.device.language",this.deviceLocale="ai.device.locale",this.deviceModel="ai.device.model",this.deviceFriendlyName="ai.device.friendlyName",this.deviceNetwork="ai.device.network",this.deviceNetworkName="ai.device.networkName",this.deviceOEMName="ai.device.oemName",this.deviceOS="ai.device.os",this.deviceOSVersion="ai.device.osVersion",this.deviceRoleInstance="ai.device.roleInstance",this.deviceRoleName="ai.device.roleName",this.deviceScreenResolution="ai.device.screenResolution",this.deviceType="ai.device.type",this.deviceMachineName="ai.device.machineName",this.deviceVMName="ai.device.vmName",this.deviceBrowser="ai.device.browser",this.deviceBrowserVersion="ai.device.browserVersion",this.locationIp="ai.location.ip",this.locationCountry="ai.location.country",this.locationProvince="ai.location.province",this.locationCity="ai.location.city",this.operationId="ai.operation.id",this.operationName="ai.operation.name",this.operationParentId="ai.operation.parentId",this.operationRootId="ai.operation.rootId",this.operationSyntheticSource="ai.operation.syntheticSource",this.operationCorrelationVector="ai.operation.correlationVector",this.sessionId="ai.session.id",this.sessionIsFirst="ai.session.isFirst",this.sessionIsNew="ai.session.isNew",this.userAccountAcquisitionDate="ai.user.accountAcquisitionDate",this.userAccountId="ai.user.accountId",this.userAgent="ai.user.userAgent",this.userId="ai.user.id",this.userStoreRegion="ai.user.storeRegion",this.userAuthUserId="ai.user.authUserId",this.userAnonymousUserAcquisitionDate="ai.user.anonUserAcquisitionDate",this.userAuthenticatedUserAcquisitionDate="ai.user.authUserAcquisitionDate",this.cloudName="ai.cloud.name",this.cloudRole="ai.cloud.role",this.cloudRoleVer="ai.cloud.roleVer",this.cloudRoleInstance="ai.cloud.roleInstance",this.cloudEnvironment="ai.cloud.environment",this.cloudLocation="ai.cloud.location",this.cloudDeploymentUnit="ai.cloud.deploymentUnit",this.internalNodeName="ai.internal.nodeName",this.internalSdkVersion="ai.internal.sdkVersion",this.internalAgentVersion="ai.internal.agentVersion",this.internalSnippet="ai.internal.snippet",this.internalSdkSrc="ai.internal.sdkSrc"},Eo=function(){function t(){}return t.create=function(t,e,n,i,r,o){if(n=Zr.sanitizeString(i,n)||io.NotSpecified,nr.isNullOrUndefined(t)||nr.isNullOrUndefined(e)||nr.isNullOrUndefined(n))throw Error("Input doesn't contain all required fields");var s={name:n,time:nr.toISOString(new Date),iKey:"",ext:o||{},tags:[],data:{},baseType:e,baseData:t};return nr.isNullOrUndefined(r)||tr(r,(function(t,e){s.data[t]=e})),s},t}(),Io=function(){function t(){}return t.UserExt="user",t.DeviceExt="device",t.TraceExt="trace",t.WebExt="web",t.AppExt="app",t.OSExt="os",t.SessionExt="ses",t.SDKExt="sdk",t}(),Fo=new jo,Po=function t(e,n,i,r){gr(t,this,(function(t){var o,s=nr.arrForEach,a=nr.isNullOrUndefined,c=null,u=[],l=!1;function f(){i&&s(i.getTransmissionControls(),(function(t){s(t,(function(t){return t.flush(!0)}))}))}i&&(o=i.logger),t.trackPageView=function(t,i){var d=t.name;if(a(d)||"string"!=typeof d){var h=Ri();d=t.name=h&&h.title||""}var p=t.uri;if(a(p)||"string"!=typeof p){var m=Ti();p=t.uri=m&&m.href||""}if(!r.isPerformanceTimingSupported())return e.sendPageViewInternal(t,i),f(),void o.throwInternal(er.WARNING,25,"trackPageView: navigation timing API used for calculation of page duration is not supported in this browser. This page view will be collected without duration and timing info.");var v,b,g=!1,w=r.getPerformanceTiming().navigationStart;w>0&&(v=ao.GetDuration(w,+new Date),r.shouldCollectDuration(v)||(v=void 0)),a(i)||a(i.duration)||(b=i.duration),!n&&isNaN(b)||(isNaN(b)&&(i||(i={}),i.duration=v),e.sendPageViewInternal(t,i),f(),g=!0),i||(i={}),u.push((function(){var n=!1;try{if(r.isPerformanceTimingDataReady()){n=!0;var s={name:d,uri:p};r.populatePageViewPerformanceEvent(s),s.isValid||g?(g||(i.duration=s.durationMs,e.sendPageViewInternal(t,i)),l||(e.sendPageViewPerformanceInternal(s,i),l=!0)):(i.duration=v,e.sendPageViewInternal(t,i))}else w>0&&ao.GetDuration(w,+new Date)>6e4&&(n=!0,g||(i.duration=6e4,e.sendPageViewInternal(t,i)))}catch(t){o.throwInternal(er.CRITICAL,38,"trackPageView failed on page load calculation: "+io.getExceptionName(t),{exception:io.dump(t)})}return n})),c||(c=setInterval((function(){var t=u.slice(0),e=!1;u=[],s(t,(function(t){t()?e=!0:u.push(t)})),0===u.length&&(clearInterval(c),c=null),e&&f()}),100))}}))},Ro=function(){function t(t,e){this.prevPageVisitDataKeyName="prevPageVisitData",this.pageVisitTimeTrackingHandler=e,this._logger=t}return t.prototype.trackPreviousPageVisit=function(t,e){try{var n=this.restartPageVisitTimer(t,e);n&&this.pageVisitTimeTrackingHandler(n.pageName,n.pageUrl,n.pageVisitTime)}catch(t){this._logger.warnToConsole("Auto track page visit time failed, metric will not be collected: "+io.dump(t))}},t.prototype.restartPageVisitTimer=function(t,e){try{var n=this.stopPageVisitTimer();return this.startPageVisitTimer(t,e),n}catch(t){return this._logger.warnToConsole("Call to restart failed: "+io.dump(t)),null}},t.prototype.startPageVisitTimer=function(t,e){try{if(io.canUseSessionStorage()){if(null!=io.getSessionStorage(this._logger,this.prevPageVisitDataKeyName))throw new Error("Cannot call startPageVisit consecutively without first calling stopPageVisit");var n=new Mo(t,e),i=Oi().stringify(n);io.setSessionStorage(this._logger,this.prevPageVisitDataKeyName,i)}}catch(t){this._logger.warnToConsole("Call to start failed: "+io.dump(t))}},t.prototype.stopPageVisitTimer=function(){try{if(io.canUseSessionStorage()){var t=nr.dateNow(),e=io.getSessionStorage(this._logger,this.prevPageVisitDataKeyName);if(e&&Di()){var n=Oi().parse(e);return n.pageVisitTime=t-n.pageVisitStartTime,io.removeSessionStorage(this._logger,this.prevPageVisitDataKeyName),n}return null}return null}catch(t){return this._logger.warnToConsole("Stop page visit timer failed: "+io.dump(t)),null}},t}(),Mo=function(t,e){this.pageVisitStartTime=nr.dateNow(),this.pageName=t,this.pageUrl=e},To=function(){function t(t){this.MAX_DURATION_ALLOWED=36e5,t&&(this._logger=t.logger)}return t.prototype.populatePageViewPerformanceEvent=function(t){t.isValid=!1;var e=this.getPerformanceNavigationTiming(),n=this.getPerformanceTiming();if(e||n){if(e)var i=e.duration,r=ao.GetDuration(e.startTime,e.connectEnd),o=ao.GetDuration(e.requestStart,e.responseStart),s=ao.GetDuration(e.responseStart,e.responseEnd),a=ao.GetDuration(e.responseEnd,e.loadEventEnd);else i=ao.GetDuration(n.navigationStart,n.loadEventEnd),r=ao.GetDuration(n.navigationStart,n.connectEnd),o=ao.GetDuration(n.requestStart,n.responseStart),s=ao.GetDuration(n.responseStart,n.responseEnd),a=ao.GetDuration(n.responseEnd,n.loadEventEnd);0===i?this._logger.throwInternal(er.WARNING,10,"error calculating page view performance.",{total:i,network:r,request:o,response:s,dom:a}):this.shouldCollectDuration(i,r,o,s,a)?i<Math.floor(r)+Math.floor(o)+Math.floor(s)+Math.floor(a)?this._logger.throwInternal(er.WARNING,8,"client performance math error.",{total:i,network:r,request:o,response:s,dom:a}):(t.durationMs=i,t.perfTotal=t.duration=io.msToTimeSpan(i),t.networkConnect=io.msToTimeSpan(r),t.sentRequest=io.msToTimeSpan(o),t.receivedResponse=io.msToTimeSpan(s),t.domProcessing=io.msToTimeSpan(a),t.isValid=!0):this._logger.throwInternal(er.WARNING,45,"Invalid page load duration value. Browser perf data won't be sent.",{total:i,network:r,request:o,response:s,dom:a})}},t.prototype.getPerformanceTiming=function(){return this.isPerformanceTimingSupported()?Ni().timing:null},t.prototype.getPerformanceNavigationTiming=function(){return this.isPerformanceNavigationTimingSupported()?Ni().getEntriesByType("navigation")[0]:null},t.prototype.isPerformanceNavigationTimingSupported=function(){var t=Ni();return t&&t.getEntriesByType&&t.getEntriesByType("navigation").length>0},t.prototype.isPerformanceTimingSupported=function(){var t=Ni();return t&&t.timing},t.prototype.isPerformanceTimingDataReady=function(){var t=Ni(),e=t?t.timing:0;return e&&e.domainLookupStart>0&&e.navigationStart>0&&e.responseStart>0&&e.requestStart>0&&e.loadEventEnd>0&&e.responseEnd>0&&e.connectEnd>0&&e.domLoading>0},t.prototype.shouldCollectDuration=function(){for(var t=[],e=0;e<arguments.length;e++)t[e]=arguments[e];var n=Mi()||{},i=["googlebot","adsbot-google","apis-google","mediapartners-google"],r=n.userAgent,o=!1;if(r)for(var s=0;s<i.length;s++)o=o||-1!==r.toLowerCase().indexOf(i[s]);if(o)return!1;for(s=0;s<t.length;s++)if(t[s]<0||t[s]>=this.MAX_DURATION_ALLOWED)return!1;return!0},t}();function No(t,e){t&&t.dispatchEvent&&e&&t.dispatchEvent(e)}var Do=function(t){function e(){var e=t.call(this)||this;e.identifier="ApplicationInsightsAnalytics",e.priority=180,e.autoRoutePVDelay=500,e._trackAjaxAttempts=0;var n=Ti();return e._prevUri=n&&n.href||"",e}return __extends(e,t),e.getDefaultConfig=function(t){return t||(t={}),t.sessionRenewalMs=18e5,t.sessionExpirationMs=864e5,t.disableExceptionTracking=io.stringToBoolOrDefault(t.disableExceptionTracking),t.autoTrackPageVisitTime=io.stringToBoolOrDefault(t.autoTrackPageVisitTime),t.overridePageViewDuration=io.stringToBoolOrDefault(t.overridePageViewDuration),t.enableUnhandledPromiseRejectionTracking=io.stringToBoolOrDefault(t.enableUnhandledPromiseRejectionTracking),(isNaN(t.samplingPercentage)||t.samplingPercentage<=0||t.samplingPercentage>=100)&&(t.samplingPercentage=100),t.isCookieUseDisabled=io.stringToBoolOrDefault(t.isCookieUseDisabled),t.isStorageUseDisabled=io.stringToBoolOrDefault(t.isStorageUseDisabled),t.isBrowserLinkTrackingEnabled=io.stringToBoolOrDefault(t.isBrowserLinkTrackingEnabled),t.enableAutoRouteTracking=io.stringToBoolOrDefault(t.enableAutoRouteTracking),t.namePrefix=t.namePrefix||"",t},e.prototype.processTelemetry=function(t,e){var n=this;Cr(this.core,(function(){return n.identifier+":processTelemetry"}),(function(){var i=!1,r=n._telemetryInitializers.length;e=n._getTelCtx(e);for(var o=0;o<r;++o){var s=n._telemetryInitializers[o];if(s)try{if(!1===s.apply(null,[t])){i=!0;break}}catch(t){e.diagLog().throwInternal(er.CRITICAL,64,"One of telemetry initializers failed, telemetry item will not be sent: "+io.getExceptionName(t),{exception:io.dump(t)},!0)}}i||n.processNext(t,e)}),(function(){return{item:t}}),!t.sync)},e.prototype.trackEvent=function(t,e){try{var n=Eo.create(t,mo.dataType,mo.envelopeType,this.diagLog(),e);this.core.track(n)}catch(t){this.diagLog().throwInternal(er.WARNING,39,"trackTrace failed, trace will not be collected: "+io.getExceptionName(t),{exception:io.dump(t)})}},e.prototype.startTrackEvent=function(t){try{this._eventTracking.start(t)}catch(t){this.diagLog().throwInternal(er.CRITICAL,29,"startTrackEvent failed, event will not be collected: "+io.getExceptionName(t),{exception:io.dump(t)})}},e.prototype.stopTrackEvent=function(t,e){try{this._eventTracking.stop(t,void 0,e)}catch(t){this.diagLog().throwInternal(er.CRITICAL,30,"stopTrackEvent failed, event will not be collected: "+io.getExceptionName(t),{exception:io.dump(t)})}},e.prototype.trackTrace=function(t,e){try{var n=Eo.create(t,Ao.dataType,Ao.envelopeType,this.diagLog(),e);this.core.track(n)}catch(t){this.diagLog().throwInternal(er.WARNING,39,"trackTrace failed, trace will not be collected: "+io.getExceptionName(t),{exception:io.dump(t)})}},e.prototype.trackMetric=function(t,e){try{var n=Eo.create(t,ko.dataType,ko.envelopeType,this.diagLog(),e);this.core.track(n)}catch(t){this.diagLog().throwInternal(er.CRITICAL,36,"trackMetric failed, metric will not be collected: "+io.getExceptionName(t),{exception:io.dump(t)})}},e.prototype.trackPageView=function(t,e){try{var n=t||{};this._pageViewManager.trackPageView(n,__assign({},n.properties,n.measurements,e)),this.config.autoTrackPageVisitTime&&this._pageVisitTimeManager.trackPreviousPageVisit(n.name,n.uri)}catch(t){this.diagLog().throwInternal(er.CRITICAL,37,"trackPageView failed, page view will not be collected: "+io.getExceptionName(t),{exception:io.dump(t)})}},e.prototype.sendPageViewInternal=function(t,e,n){var i=Ri();i&&(t.refUri=void 0===t.refUri?i.referrer:t.refUri);var r=Eo.create(t,Co.dataType,Co.envelopeType,this.diagLog(),e,n);this.core.track(r),this._trackAjaxAttempts=0},e.prototype.sendPageViewPerformanceInternal=function(t,e,n){var i=Eo.create(t,qo.dataType,qo.envelopeType,this.diagLog(),e,n);this.core.track(i)},e.prototype.trackPageViewPerformance=function(t,e){try{this._pageViewPerformanceManager.populatePageViewPerformanceEvent(t),this.sendPageViewPerformanceInternal(t,e)}catch(t){this.diagLog().throwInternal(er.CRITICAL,37,"trackPageViewPerformance failed, page view will not be collected: "+io.getExceptionName(t),{exception:io.dump(t)})}},e.prototype.startTrackPage=function(t){try{if("string"!=typeof t){var e=Ri();t=e&&e.title||""}this._pageTracking.start(t)}catch(t){this.diagLog().throwInternal(er.CRITICAL,31,"startTrackPage failed, page view may not be collected: "+io.getExceptionName(t),{exception:io.dump(t)})}},e.prototype.stopTrackPage=function(t,e,n,i){try{if("string"!=typeof t){var r=Ri();t=r&&r.title||""}if("string"!=typeof e){var o=Ti();e=o&&o.href||""}this._pageTracking.stop(t,e,n,i),this.config.autoTrackPageVisitTime&&this._pageVisitTimeManager.trackPreviousPageVisit(t,e)}catch(t){this.diagLog().throwInternal(er.CRITICAL,32,"stopTrackPage failed, page view will not be collected: "+io.getExceptionName(t),{exception:io.dump(t)})}},e.prototype.sendExceptionInternal=function(t,e,n){var i=new vo(this.diagLog(),t.exception||new Error(io.NotSpecified),t.properties,t.measurements,t.severityLevel,t.id).toInterface(),r=Eo.create(i,vo.dataType,vo.envelopeType,this.diagLog(),e,n);this.core.track(r)},e.prototype.trackException=function(t,e){try{this.sendExceptionInternal(t,e)}catch(t){this.diagLog().throwInternal(er.CRITICAL,35,"trackException failed, exception will not be collected: "+io.getExceptionName(t),{exception:io.dump(t)})}},e.prototype._onerror=function(t){try{var e={url:t&&t.url||(Ri()||{}).URL,lineNumber:t.lineNumber,columnNumber:t.columnNumber,message:t.message};if(io.isCrossOriginError(t.message,t.url,t.lineNumber,t.columnNumber,t.error))this._sendCORSException(e.url);else{if(!io.isError(t.error)){var n="window.onerror@"+e.url+":"+t.lineNumber+":"+(t.columnNumber||0);t.error=new Error(t.message),t.error.stack=n}this.trackException({exception:t.error,severityLevel:yo.Error},e)}}catch(e){var i=t.error?t.error.name+", "+t.error.message:"null";this.diagLog().throwInternal(er.CRITICAL,11,"_onError threw exception while logging error, error will not be collected: "+io.getExceptionName(e),{exception:io.dump(e),errorString:i})}},e.prototype.addTelemetryInitializer=function(t){this._telemetryInitializers.push(t)},e.prototype.initialize=function(n,i,r,o){var s=this;if(!this.isInitialized()){if(nr.isNullOrUndefined(i))throw Error("Error initializing");t.prototype.initialize.call(this,n,i,r,o),this.setInitialized(!1);var a=this._getTelCtx(),c=this.identifier;this._globalconfig={instrumentationKey:n.instrumentationKey,endpointUrl:n.endpointUrl||"https://dc.services.visualstudio.com/v2/track"},this.config=a.getExtCfg(c);var u=e.getDefaultConfig();void 0!==u&&(tr(u,(function(t,e){s.config[t]=a.getConfig(c,t,e)})),this._globalconfig&&tr(u,(function(t,e){void 0===s._globalconfig[t]&&(s._globalconfig[t]=e)}))),this.config.isCookieUseDisabled&&io.disableCookies(),this.config.isStorageUseDisabled&&io.disableStorage();var l={instrumentationKey:function(){return n.instrumentationKey},accountId:function(){return s.config.accountId||n.accountId},sessionRenewalMs:function(){return s.config.sessionRenewalMs||n.sessionRenewalMs},sessionExpirationMs:function(){return s.config.sessionExpirationMs||n.sessionExpirationMs},sampleRate:function(){return s.config.samplingPercentage||n.samplingPercentage},cookieDomain:function(){return s.config.cookieDomain||n.cookieDomain},sdkExtension:function(){return s.config.sdkExtension||n.sdkExtension},isBrowserLinkTrackingEnabled:function(){return s.config.isBrowserLinkTrackingEnabled||n.isBrowserLinkTrackingEnabled},appId:function(){return s.config.appId||n.appId}};this._pageViewPerformanceManager=new To(this.core),this._pageViewManager=new Po(this,this.config.overridePageViewDuration,this.core,this._pageViewPerformanceManager),this._pageVisitTimeManager=new Ro(this.diagLog(),(function(t,e,n){return s.trackPageVisitTime(t,e,n)})),this._telemetryInitializers=this._telemetryInitializers||[],this._addDefaultTelemetryInitializers(l),this._eventTracking=new Oo(this.diagLog(),"trackEvent"),this._eventTracking.action=function(t,e,n,i){i||(i={}),i.duration=n.toString(),s.trackEvent({name:t,properties:i})},this._pageTracking=new Oo(this.diagLog(),"trackPageView"),this._pageTracking.action=function(t,e,n,i,r){nr.isNullOrUndefined(i)&&(i={}),i.duration=n.toString(),s.sendPageViewInternal({name:t,uri:e,properties:i,measurements:r},i)};var f,d=Fi(),h=Boolean("object"==typeof history&&history)?history:Ei("history"),p=Ti(),m=this;if(!1===this.config.disableExceptionTracking&&!this.config.autoExceptionInstrumented&&d){var v=d.onerror;d.onerror=function(t,e,n,i,r){var o=v&&v(t,e,n,i,r);return!0!==o&&m._onerror({message:t,url:e,lineNumber:n,columnNumber:i,error:r}),o},this.config.autoExceptionInstrumented=!0}if(!1===this.config.disableExceptionTracking&&!0===this.config.enableUnhandledPromiseRejectionTracking&&!this.config.autoUnhandledPromiseInstrumented&&d){var b=d.onunhandledrejection;d.onunhandledrejection=function(t){var e=b&&b.call(d,t);return!0!==e&&m._onerror({message:t.reason.toString(),error:t.reason instanceof Error?t.reason:new Error(t.reason.toString()),url:p?p.href:"",lineNumber:0,columnNumber:0}),e},this.config.autoUnhandledPromiseInstrumented=!0}if(!0===this.config.enableAutoRouteTracking&&h&&nr.isFunction(h.pushState)&&nr.isFunction(h.replaceState)&&d&&"undefined"!=typeof Event){var g=this;nr.arrForEach(r,(function(t){"AppInsightsPropertiesPlugin"===t.identifier&&(s._properties=t)})),h.pushState=(f=h.pushState,function(){var t=f.apply(this,arguments);return No(d,io.createDomEvent(g.config.namePrefix+"pushState")),No(d,io.createDomEvent(g.config.namePrefix+"locationchange")),t}),h.replaceState=function(t){return function(){var e=t.apply(this,arguments);return No(d,io.createDomEvent(g.config.namePrefix+"replaceState")),No(d,io.createDomEvent(g.config.namePrefix+"locationchange")),e}}(h.replaceState),d.addEventListener&&(d.addEventListener(g.config.namePrefix+"popstate",(function(){No(d,io.createDomEvent(g.config.namePrefix+"locationchange"))})),d.addEventListener(g.config.namePrefix+"locationchange",(function(){g._properties&&g._properties.context&&g._properties.context.telemetryTrace&&(g._properties.context.telemetryTrace.traceID=io.generateW3CId(),g._properties.context.telemetryTrace.name=p&&p.pathname||"_unknown_"),s._currUri?(s._prevUri=s._currUri,s._currUri=p&&p.href||""):s._currUri=p&&p.href||"",setTimeout(function(t){g.trackPageView({refUri:t,properties:{duration:0}})}.bind(s,s._prevUri),g.autoRoutePVDelay)})))}this.setInitialized(!0)}},e.prototype.trackPageVisitTime=function(t,e,n){this.trackMetric({name:"PageVisitTime",average:n,max:n,min:n,sampleCount:1},{PageName:t,PageUrl:e})},e.prototype._addDefaultTelemetryInitializers=function(t){if(!t.isBrowserLinkTrackingEnabled()){var e=["/browserLinkSignalR/","/__browserLink/"];this._addTelemetryInitializer((function(t){if(t.baseType===_o.dataType){var n=t.baseData;if(n)for(var i=0;i<e.length;i++)if(n.target&&n.target.indexOf(e[i])>=0)return!1}return!0}))}},e.prototype._addTelemetryInitializer=function(t){this._telemetryInitializers.push(t)},e.prototype._sendCORSException=function(t){var e=Eo.create({message:"Script error: The browser's same-origin policy prevents us from getting the details of this exception. Consider using the 'crossorigin' attribute.",url:t,lineNumber:0,columnNumber:0,error:void 0},vo.dataType,vo.envelopeType,this.diagLog(),{url:t});this.core.track(e)},e.Version="2.5.10",e}(Ir),Oo=function(){function t(t,e){this._name=e,this._events={},this._logger=t}return t.prototype.start=function(t){void 0!==this._events[t]&&this._logger.throwInternal(er.WARNING,62,"start was called more than once for this event without calling stop.",{name:this._name,key:t},!0),this._events[t]=+new Date},t.prototype.stop=function(t,e,n,i){var r=this._events[t];if(isNaN(r))this._logger.throwInternal(er.WARNING,63,"stop was called without a corresponding start.",{name:this._name,key:t},!0);else{var o=+new Date,s=ao.GetDuration(r,o);this.action(t,e,s,n,i)}delete this._events[t],this._events[t]=void 0},t}(),Uo=function t(e){var n=[];gr(t,this,(function(t){t.enqueue=function(t){n.push(t)},t.count=function(){return n.length},t.clear=function(){n.length=0},t.getItems=function(){return n.slice(0)},t.batchPayloads=function(t){return t&&t.length>0?e.emitLineDelimitedJson()?t.join("\n"):"["+t.join(",")+"]":null},t.markAsSent=function(){t.clear()},t.clearSent=function(){}}))},Lo=function(){function t(e,n){var i,r=!1;gr(t,this,(function(o){var s=u(t.BUFFER_KEY),a=u(t.SENT_BUFFER_KEY);function c(t,e){var n=[];return nr.arrForEach(e,(function(e){nr.isFunction(e)||-1!==nr.arrIndexOf(t,e)||n.push(e)})),n}function u(t){var i=t;try{i=n.namePrefix&&n.namePrefix()?n.namePrefix()+"_"+i:i;var r=io.getSessionStorage(e,i);if(r){var o=Oi().parse(r);if(nr.isString(o)&&(o=Oi().parse(o)),o&&io.isArray(o))return o}}catch(t){e.throwInternal(er.CRITICAL,42," storage key: "+i+", "+io.getExceptionName(t),{exception:io.dump(t)})}return[]}function l(t,i){var r=t;try{r=n.namePrefix&&n.namePrefix()?n.namePrefix()+"_"+r:r;var o=JSON.stringify(i);io.setSessionStorage(e,r,o)}catch(t){io.setSessionStorage(e,r,JSON.stringify([])),e.throwInternal(er.WARNING,41," storage key: "+r+", "+io.getExceptionName(t)+". Buffer cleared",{exception:io.dump(t)})}}(i=s.concat(a)).length>t.MAX_BUFFER_SIZE&&(i.length=t.MAX_BUFFER_SIZE),l(t.SENT_BUFFER_KEY,[]),l(t.BUFFER_KEY,i),o.enqueue=function(n){i.length>=t.MAX_BUFFER_SIZE?r||(e.throwInternal(er.WARNING,67,"Maximum buffer size reached: "+i.length,!0),r=!0):(i.push(n),l(t.BUFFER_KEY,i))},o.count=function(){return i.length},o.clear=function(){i=[],l(t.BUFFER_KEY,[]),l(t.SENT_BUFFER_KEY,[]),r=!1},o.getItems=function(){return i.slice(0)},o.batchPayloads=function(t){return t&&t.length>0?n.emitLineDelimitedJson()?t.join("\n"):"["+t.join(",")+"]":null},o.markAsSent=function(n){i=c(n,i),l(t.BUFFER_KEY,i);var r=u(t.SENT_BUFFER_KEY);r instanceof Array&&n instanceof Array&&((r=r.concat(n)).length>t.MAX_BUFFER_SIZE&&(e.throwInternal(er.CRITICAL,67,"Sent buffer reached its maximum size: "+r.length,!0),r.length=t.MAX_BUFFER_SIZE),l(t.SENT_BUFFER_KEY,r))},o.clearSent=function(e){var n=u(t.SENT_BUFFER_KEY);n=c(e,n),l(t.SENT_BUFFER_KEY,n)}}))}return t.BUFFER_KEY="AI_buffer",t.SENT_BUFFER_KEY="AI_sentBuffer",t.MAX_BUFFER_SIZE=2e3,t}(),zo=nr.isNullOrUndefined;function Ho(t,e,n){return t&&n?(t[e]=n,t[e]):null}var Vo=function(){function t(){}return t.extractPropsAndMeasurements=function(t,e,n){zo(t)||tr(t,(function(t,i){nr.isNumber(i)?n[t]=i:nr.isString(i)?e[t]=i:Di()&&(e[t]=Oi().stringify(i))}))},t.createEnvelope=function(e,n,i,r){var o=new fo(e,r,n);Ho(o,"sampleRate",i.sampleRate),(i.baseData||{}).startTime&&(o.time=nr.toISOString(i.baseData.startTime)),o.iKey=i.iKey;var s=i.iKey.replace(/-/g,"");return o.name=o.name.replace("{0}",s),t.extractPartAExtensions(i,o),i.tags=i.tags||[],o},t.extractPartAExtensions=function(e,n){var i=n.tags=n.tags||{},r=e.ext=e.ext||{},o=e.tags=e.tags||[],s=r.user;s&&(Ho(i,Fo.userAuthUserId,s.authId),Ho(i,Fo.userId,s.id||s.localId));var a=r.app;a&&Ho(i,Fo.sessionId,a.sesId);var c=r.device;c&&(Ho(i,Fo.deviceId,c.id||c.localId),Ho(i,Fo.deviceType,c.deviceClass),Ho(i,Fo.deviceIp,c.ip),Ho(i,Fo.deviceModel,c.model),Ho(i,Fo.deviceType,c.deviceType));var u=e.ext.web;if(u){Ho(i,Fo.deviceLanguage,u.browserLang),Ho(i,Fo.deviceBrowserVersion,u.browserVer),Ho(i,Fo.deviceBrowser,u.browser);var l=n.data=n.data||{},f=l.baseData=l.baseData||{},d=f.properties=f.properties||{};Ho(d,"domain",u.domain),Ho(d,"isManual",u.isManual?"true":null),Ho(d,"screenRes",u.screenRes),Ho(d,"userConsent",u.userConsent?"true":null)}var h=r.os;h&&Ho(i,Fo.deviceOS,h.name);var p=r.trace;p&&(Ho(i,Fo.operationParentId,p.parentID),Ho(i,Fo.operationName,p.name),Ho(i,Fo.operationId,p.traceID));for(var m={},v=o.length-1;v>=0;v--)tr(o[v],(function(t,e){m[t]=e})),o.splice(v,1);tr(o,(function(t,e){m[t]=e})),n.tags=__assign({},i,m),n.tags[Fo.internalSdkVersion]||(n.tags[Fo.internalSdkVersion]="javascript:"+t.Version)},t.prototype.Init=function(t,e){this._logger=t,zo(e.baseData)&&this._logger.throwInternal(er.CRITICAL,46,"telemetryItem.baseData cannot be null.")},t.Version="2.5.10",t}(),Qo=function(t){function e(){return null!==t&&t.apply(this,arguments)||this}return __extends(e,t),e.prototype.Create=function(e,n){t.prototype.Init.call(this,e,n);var i=n.baseData.measurements||{},r=n.baseData.properties||{};Vo.extractPropsAndMeasurements(n.data,r,i);var o=n.baseData;if(zo(o))return e.warnToConsole("Invalid input for dependency data"),null;var s=new _o(e,o.id,o.target,o.name,o.duration,o.success,o.responseCode,o.properties&&o.properties["http.method"]?o.properties["http.method"]:"GET",o.type,o.correlationContext,r,i),a=new Bo(_o.dataType,s);return Vo.createEnvelope(e,_o.envelopeType,n,a)},e.DependencyEnvelopeCreator=new e,e}(Vo),Wo=function(t){function e(){return null!==t&&t.apply(this,arguments)||this}return __extends(e,t),e.prototype.Create=function(e,n){t.prototype.Init.call(this,e,n);var i={},r={};n.baseType!==mo.dataType&&(i.baseTypeSource=n.baseType),n.baseType===mo.dataType?(i=n.baseData.properties||{},r=n.baseData.measurements||{}):n.baseData&&Vo.extractPropsAndMeasurements(n.baseData,i,r),Vo.extractPropsAndMeasurements(n.data,i,r);var o=new mo(e,n.baseData.name,i,r),s=new Bo(mo.dataType,o);return Vo.createEnvelope(e,mo.envelopeType,n,s)},e.EventEnvelopeCreator=new e,e}(Vo),$o=function(t){function e(){return null!==t&&t.apply(this,arguments)||this}return __extends(e,t),e.prototype.Create=function(e,n){t.prototype.Init.call(this,e,n);var i=n.baseData.measurements||{},r=n.baseData.properties||{};Vo.extractPropsAndMeasurements(n.data,r,i);var o=vo.CreateFromInterface(e,n.baseData,r,i),s=new Bo(vo.dataType,o);return Vo.createEnvelope(e,vo.envelopeType,n,s)},e.ExceptionEnvelopeCreator=new e,e}(Vo),Yo=function(t){function e(){return null!==t&&t.apply(this,arguments)||this}return __extends(e,t),e.prototype.Create=function(e,n){t.prototype.Init.call(this,e,n);var i=n.baseData,r=i.properties||{},o=i.measurements||{};Vo.extractPropsAndMeasurements(n.data,r,o);var s=new ko(e,i.name,i.average,i.sampleCount,i.min,i.max,r,o),a=new Bo(ko.dataType,s);return Vo.createEnvelope(e,ko.envelopeType,n,a)},e.MetricEnvelopeCreator=new e,e}(Vo),Xo=function(t){function e(){return null!==t&&t.apply(this,arguments)||this}return __extends(e,t),e.prototype.Create=function(e,n){t.prototype.Init.call(this,e,n);var i,r=n.baseData;zo(r)||zo(r.properties)||zo(r.properties.duration)?zo(n.data)||zo(n.data.duration)||(i=n.data.duration,delete n.data.duration):(i=r.properties.duration,delete r.properties.duration);var o,s=n.baseData;((n.ext||{}).trace||{}).traceID&&(o=n.ext.trace.traceID);var a=s.id||o,c=s.name,u=s.uri,l=s.properties||{},f=s.measurements||{};zo(s.refUri)||(l.refUri=s.refUri),zo(s.pageType)||(l.pageType=s.pageType),zo(s.isLoggedIn)||(l.isLoggedIn=s.isLoggedIn.toString()),zo(s.properties)||tr(s.properties,(function(t,e){l[t]=e})),Vo.extractPropsAndMeasurements(n.data,l,f);var d=new Co(e,c,u,i,l,f,a),h=new Bo(Co.dataType,d);return Vo.createEnvelope(e,Co.envelopeType,n,h)},e.PageViewEnvelopeCreator=new e,e}(Vo),Jo=function(t){function e(){return null!==t&&t.apply(this,arguments)||this}return __extends(e,t),e.prototype.Create=function(e,n){t.prototype.Init.call(this,e,n);var i=n.baseData,r=i.name,o=i.uri||i.url,s=i.properties||{},a=i.measurements||{};Vo.extractPropsAndMeasurements(n.data,s,a);var c=new qo(e,r,o,void 0,s,a,i),u=new Bo(qo.dataType,c);return Vo.createEnvelope(e,qo.envelopeType,n,u)},e.PageViewPerformanceEnvelopeCreator=new e,e}(Vo),Go=function(t){function e(){return null!==t&&t.apply(this,arguments)||this}return __extends(e,t),e.prototype.Create=function(e,n){t.prototype.Init.call(this,e,n);var i=n.baseData.message,r=n.baseData.severityLevel,o=n.baseData.properties||{},s=n.baseData.measurements||{};Vo.extractPropsAndMeasurements(n.data,o,s);var a=new Ao(e,i,r,o,s),c=new Bo(Ao.dataType,a);return Vo.createEnvelope(e,Ao.envelopeType,n,c)},e.TraceEnvelopeCreator=new e,e}(Vo),Ko=function t(e){gr(t,this,(function(t){function n(t,o){var s={};if(!t)return e.throwInternal(er.CRITICAL,48,"cannot serialize object because it is null or undefined",{name:o},!0),s;if(t.__aiCircularRefCheck)return e.throwInternal(er.WARNING,50,"Circular reference detected while serializing object",{name:o},!0),s;if(!t.aiDataContract){if("measurements"===o)s=r(t,"number",o);else if("properties"===o)s=r(t,"string",o);else if("tags"===o)s=r(t,"string",o);else if(io.isArray(t))s=i(t,o);else{e.throwInternal(er.WARNING,49,"Attempting to serialize an object which does not implement ISerializable",{name:o},!0);try{Oi().stringify(t),s=t}catch(t){e.throwInternal(er.CRITICAL,48,t&&nr.isFunction(t.toString)?t.toString():"Error serializing object",null,!0)}}return s}return t.__aiCircularRefCheck=!0,tr(t.aiDataContract,(function(r,a){var c=nr.isFunction(a)?a()&Wr.Required:a&Wr.Required,u=nr.isFunction(a)?a()&Wr.Hidden:a&Wr.Hidden,l=a&Wr.Array,f=void 0!==t[r],d=nr.isObject(t[r])&&null!==t[r];if(!c||f||l){if(!u){var h;void 0!==(h=d?l?i(t[r],r):n(t[r],r):t[r])&&(s[r]=h)}}else e.throwInternal(er.CRITICAL,24,"Missing required field specification. The field is required but not present on source",{field:r,name:o})})),delete t.__aiCircularRefCheck,s}function i(t,i){var r;if(t)if(io.isArray(t)){r=[];for(var o=0;o<t.length;o++){var s=n(t[o],i+"["+o+"]");r.push(s)}}else e.throwInternal(er.CRITICAL,54,"This field was specified as an array in the contract but the item is not an array.\r\n",{name:i},!0);return r}function r(t,n,i){var r;return t&&(r={},tr(t,(function(t,o){if("string"===n)r[t]=void 0===o?"undefined":null===o?"null":o.toString?o.toString():"invalid field: toString() is not defined.";else if("number"===n)if(void 0===o)r[t]="undefined";else if(null===o)r[t]="null";else{var s=parseFloat(o);r[t]=isNaN(s)?"NaN":s}else r[t]="invalid field: "+i+" is of unknown type.",e.throwInternal(er.CRITICAL,r[t],null,!0)}))),r}t.serialize=function(t){var i=n(t,"root");try{return Oi().stringify(i)}catch(t){e.throwInternal(er.CRITICAL,48,t&&nr.isFunction(t.toString)?t.toString():"Error serializing object",null,!0)}}}))},Zo=function(){function t(){var e=Fi(),n=Ri(),i=!1,r=!0;gr(t,this,(function(t){try{if(e&&rr.Attach(e,"online",s)&&(rr.Attach(e,"offline",a),i=!0),n){var o=n.body||n;nr.isUndefined(o.ononline)||(o.ononline=s,o.onoffline=a,i=!0)}}catch(t){i=!1}function s(){r=!0}function a(){r=!1}t.isListening=i,t.isOnline=function(){var t=!0,e=Mi();return i?t=r:e&&!nr.isNullOrUndefined(e.onLine)&&(t=e.onLine),t},t.isOffline=function(){return!t.isOnline()}}))}return t.Offline=new t,t}().Offline,ts=function(){function t(){}return t.prototype.getHashCodeScore=function(e){return this.getHashCode(e)/t.INT_MAX_VALUE*100},t.prototype.getHashCode=function(e){if(""===e)return 0;for(;e.length<t.MIN_INPUT_LENGTH;)e=e.concat(e);for(var n=5381,i=0;i<e.length;++i)n=(n<<5)+n+e.charCodeAt(i),n&=n;return Math.abs(n)},t.INT_MAX_VALUE=2147483647,t.MIN_INPUT_LENGTH=8,t}(),es=function(){function t(){this.hashCodeGeneragor=new ts,this.keys=new jo}return t.prototype.getSamplingScore=function(t){return t.tags&&t.tags[this.keys.userId]?this.hashCodeGeneragor.getHashCodeScore(t.tags[this.keys.userId]):t.ext&&t.ext.user&&t.ext.user.id?this.hashCodeGeneragor.getHashCodeScore(t.ext.user.id):t.tags&&t.tags[this.keys.operationId]?this.hashCodeGeneragor.getHashCodeScore(t.tags[this.keys.operationId]):t.ext&&t.ext.telemetryTrace&&t.ext.telemetryTrace.traceID?this.hashCodeGeneragor.getHashCodeScore(t.ext.telemetryTrace.traceID):100*Math.random()},t}(),ns=function(){function t(t,e){this.INT_MAX_VALUE=2147483647,this._logger=nr.isNullOrUndefined(e)?new xr:e,(t>100||t<0)&&(this._logger.throwInternal(er.WARNING,58,"Sampling rate is out of range (0..100). Sampling will be disabled, you may be sending too much data which may affect your AI service level.",{samplingRate:t},!0),this.sampleRate=100),this.sampleRate=t,this.samplingScoreGenerator=new es}return t.prototype.isSampledIn=function(t){var e=this.sampleRate;return null==e||e>=100||t.baseType===ko.dataType||this.samplingScoreGenerator.getSamplingScore(t)<e},t}();
5
+ */function ar(t,e){return t&&Object.prototype.hasOwnProperty.call(t,e)}function cr(t){return"function"==typeof t}function ur(t){return t&&(t===Object.prototype||t===Array.prototype)}function lr(t){return ur(t)||t===Function.prototype}function fr(t){if(t){if(or)return or(t);var e=t.__proto__||t.prototype||t.constructor;if(e)return e}return null}function dr(t,e,n){return"constructor"!==e&&cr(t[e])&&(n||ar(t,e))}function hr(t){throw new TypeError("DynamicProto: "+t)}function pr(t,e){for(var n=t.length-1;n>=0;n--)if(t[n]===e)return!0;return!1}function mr(t,e,n,i){var r=null;if(t&&ar(n,"_dynClass")){var o=t._dynInstFuncs||{};if((r=(o[n._dynClass]||{})[e])||hr("Missing ["+e+"] function"),!r._dynInstChk&&!1!==o._dynInstChk){for(var s=!ar(t,e),a=fr(t),c=[];s&&a&&!lr(a)&&!pr(c,a);){var u=a[e];if(u){s=u===i;break}c.push(a),a=fr(a)}try{s&&(t[e]=r),r._dynInstChk=1}catch(t){o._dynInstChk=!1}}}return r}function vr(t,e,n){var i=e[t];return i===n&&(i=fr(e)[t]),cr(i)||hr("["+t+"] is not a function"),i}function br(t,e){return ar(t,"prototype")?t.name||e||"_unknown_":((t||{}).constructor||{}).name||e||"_unknown_"}function gr(t,e,n,i){ar(t,"prototype")||hr("theClass is an invalid class definition.");var r=t.prototype;(function(t,e){for(var n=fr(e);n&&!lr(n);){if(n===t)return!0;n=fr(n)}return!1})(r,e)||hr("["+br(t)+"] is not in class hierarchy of ["+br(e)+"]");var o=null;ar(r,"_dynClass")?o=r._dynClass:(o="_dynCls$"+br(t,"_")+"$"+sr,sr++,r._dynClass=o);var s=gr._dfOpts,a=!!s.useBaseInst;a&&i&&void 0!==i.useBaseInst&&(a=!!i.useBaseInst);var c=function(t){var e={};for(var n in t)!e[n]&&dr(t,n,!1)&&(e[n]=t[n]);return e}(e);n(e,function(t,e,n,i){function r(t,e,n){var r=e[s];if(r._isDynProxy&&i){var o=t._dynInstFuncs||{};!1!==o._dynInstChk&&(r=(o[e._dynClass]||{})[n]||r)}return function(){return r.apply(t,arguments)}}var o={};for(var s in n)o[s]=r(e,n,s);for(var a=fr(t),c=[];a&&!lr(a)&&!pr(c,a);){for(var s in a)!o[s]&&dr(a,s,!or)&&(o[s]=r(e,a,s));c.push(a),a=fr(a)}return o}(r,e,c,a));var u=!!or&&!!s.setInstFuncs;u&&i&&(u=!!i.setInstFuncs),function(t,e,n,i,r){function o(t,e){var n=function(){return(mr(this,e,t,n)||vr(e,t,n)).apply(this,arguments)};return n._isDynProxy=1,n}if(!ur(t)){var s=n._dynInstFuncs=n._dynInstFuncs||{},a=s[e]=s[e]||{};for(var c in!1!==s._dynInstChk&&(s._dynInstChk=!!r),n)dr(n,c,!1)&&n[c]!==i[c]&&(a[c]=n[c],delete n[c],(!ar(t,c)||t[c]&&!t[c]._isDynProxy)&&(t[c]=o(t,c)))}}(r,o,e,c,!1!==u)}function wr(t){return t?'"'+t.replace(/\"/g,"")+'"':""}gr._dfOpts={setInstFuncs:!0,useBaseInst:!0};var yr=function(){function t(t,e,n,i){void 0===n&&(n=!1);var r=this;r.messageId=t,r.message=(n?"AI: ":"AI (Internal): ")+t;var o="";Di()&&(o=Oi().stringify(i));var s=(e?" message:"+wr(e):"")+(i?" props:"+wr(o):"");r.message+=s}return t.dataType="MessageData",t}(),xr=function(){function t(e){this.identifier="DiagnosticLogger",this.queue=[];var n=0,i={};gr(t,this,(function(t){var r=nr.isNullOrUndefined,o=nr.isUndefined,s=nr.isFunction;function a(t,n){var i=e[t];return r(i)?n:i}r(e)&&(e={}),t.consoleLoggingLevel=function(){return a("loggingLevelConsole",0)},t.telemetryLoggingLevel=function(){return a("loggingLevelTelemetry",1)},t.maxInternalMessageLimit=function(){return a("maxMessageLimit",25)},t.enableDebugExceptions=function(){return a("enableDebugExceptions",!1)},t.throwInternal=function(e,n,r,s,a){void 0===a&&(a=!1);var c=new yr(n,r,a,s);if(t.enableDebugExceptions())throw c;if(!o(c)&&c&&!o(c.message)){if(a){var u=+c.messageId;!i[u]&&t.consoleLoggingLevel()>=er.WARNING&&(t.warnToConsole(c.message),i[u]=!0)}else t.consoleLoggingLevel()>=er.WARNING&&t.warnToConsole(c.message);t.logInternalMessage(e,c)}},t.warnToConsole=function(t){var e="undefined"!=typeof console?console:Ei("console");if(e){var n="log";e.warn&&(n="warn"),s(e[n])&&e[n](t)}},t.resetInternalMessageCount=function(){n=0,i={}},t.logInternalMessage=function(e,r){if(!(n>=t.maxInternalMessageLimit())){var o=!0,s="AITR_"+r.messageId;if(i[s]?o=!1:i[s]=!0,o&&(e<=t.telemetryLoggingLevel()&&(t.queue.push(r),n++),n===t.maxInternalMessageLimit())){var a="Internal events throttle limit per PageView reached for this app.",c=new yr(23,a,!1);t.queue.push(c),t.warnToConsole(a)}}}}))}return t.prototype.enableDebugExceptions=function(){return!1},t.prototype.consoleLoggingLevel=function(){return 0},t.prototype.telemetryLoggingLevel=function(){return 1},t.prototype.maxInternalMessageLimit=function(){return 25},t.prototype.throwInternal=function(){},t.prototype.warnToConsole=function(){},t.prototype.resetInternalMessageCount=function(){},t.prototype.logInternalMessage=function(){},t}(),kr=function(){function t(e,n,i){var r,o=this,s=!1;o.start=nr.dateNow(),o.name=e,o.isAsync=i,o.isChildEvt=function(){return!1},nr.isFunction(n)&&(s=nr.objDefineAccessors(o,"payload",(function(){return!r&&nr.isFunction(n)&&(r=n(),n=null),r}))),o.getCtx=function(e){return e?e===t.ParentContextKey||e===t.ChildrenContextKey?o[e]:(o.ctx||{})[e]:null},o.setCtx=function(e,n){e&&(e===t.ParentContextKey?(o[e]||(o.isChildEvt=function(){return!0}),o[e]=n):e===t.ChildrenContextKey?o[e]=n:(o.ctx=o.ctx||{})[e]=n)},o.complete=function(){var e=0,i=o.getCtx(t.ChildrenContextKey);if(nr.isArray(i))for(var r=0;r<i.length;r++){var a=i[r];a&&(e+=a.time)}o.time=nr.dateNow()-o.start,o.exTime=o.time-e,o.complete=function(){},!s&&nr.isFunction(n)&&(o.payload=n())}}return t.ParentContextKey="parent",t.ChildrenContextKey="childEvts",t}(),Sr=function(){function t(e){this.ctx={},gr(t,this,(function(t){t.create=function(t,e,n){return new kr(t,e,n)},t.fire=function(t){t&&(t.complete(),e&&e.perfEvent(t))},t.setCtx=function(e,n){e&&((t.ctx=t.ctx||{})[e]=n)},t.getCtx=function(e){return(t.ctx||{})[e]}}))}return t.prototype.create=function(){return null},t.prototype.fire=function(){},t.prototype.setCtx=function(){},t.prototype.getCtx=function(){},t}();function Cr(t,e,n,i,r){if(t){var o=t;if(o&&nr.isFunction(o.getPerfMgr)&&(o=o.getPerfMgr()),o){var s=void 0,a=o.getCtx("CoreUtils.doPerf");try{if(s=o.create(e(),i,r)){if(a&&s.setCtx&&(s.setCtx(kr.ParentContextKey,a),a.getCtx&&a.setCtx)){var c=a.getCtx(kr.ChildrenContextKey);c||a.setCtx(kr.ChildrenContextKey,c=[]),c.push(s)}return o.setCtx("CoreUtils.doPerf",s),n(s)}}catch(t){s&&s.setCtx&&s.setCtx("exception",t)}finally{s&&o.fire(s),o.setCtx("CoreUtils.doPerf",a)}}}return n()}var _r=nr.isFunction,Ar=function(t,e){var n=this,i=null,r=_r(t.processTelemetry),o=_r(t.setNextPlugin);n._hasRun=!1,n.getPlugin=function(){return t},n.getNext=function(){return i},n.setNext=function(t){i=t},n.processTelemetry=function(s,a){a||(a=e);var c=t?t.identifier:"TelemetryPluginChain";Cr(a?a.core():null,(function(){return c+":processTelemetry"}),(function(){if(t&&r){n._hasRun=!0;try{a.setNext(i),o&&t.setNextPlugin(i),i&&(i._hasRun=!1),t.processTelemetry(s,a)}catch(n){var e=i&&i._hasRun;i&&e||a.diagLog().throwInternal(er.CRITICAL,73,"Plugin ["+t.identifier+"] failed during processTelemetry - "+n),i&&!e&&i.processTelemetry(s,a)}}else i&&(n._hasRun=!0,i.processTelemetry(s,a))}),(function(){return{item:s}}),!s.sync)}},qr=nr.isNullOrUndefined;function Br(t,e){var n=[];if(t&&t.length>0)for(var i=null,r=0;r<t.length;r++){var o=t[r];if(o&&nr.isFunction(o.processTelemetry)){var s=new Ar(o,e);n.push(s),i&&i.setNext(s),i=s}}return n.length>0?n[0]:null}var jr=function t(e,n,i,r){var o=this,s=null;null!==r&&(e&&nr.isFunction(e.getPlugin)?s=function(t,e,n){var i=[],r=!n;if(t)for(;t;){var o=t.getPlugin();(r||o===n)&&(r=!0,i.push(o)),t=t.getNext()}return r||i.push(n),Br(i,e)}(e,o,r||e.getPlugin()):r?s=function(t,e,n){var i=t,r=!1;return n&&t&&(i=[],nr.arrForEach(t,(function(t){(r||t===n)&&(r=!0,i.push(t))}))),n&&!r&&(i||(i=[]),i.push(n)),Br(i,e)}(e,o,r):nr.isUndefined(r)&&(s=Br(e,o))),o.core=function(){return i},o.diagLog=function(){var t=(i||{}).logger;return t||(t=new xr(n||{})),t},o.getCfg=function(){return n},o.getExtCfg=function(t,e){var i;if(void 0===e&&(e={}),n){var r=n.extensionConfig;r&&t&&(i=r[t])}return i||e},o.getConfig=function(t,e,i){var r;void 0===i&&(i=!1);var s=o.getExtCfg(t,null);return s&&!qr(s[e])?r=s[e]:n&&!qr(n[e])&&(r=n[e]),qr(r)?i:r},o.hasNext=function(){return null!=s},o.getNext=function(){return s},o.setNext=function(t){s=t},o.processNext=function(t){var e=s;e&&(s=e.getNext(),e.processTelemetry(t,o))},o.createNew=function(e,r){return void 0===e&&(e=null),new t(e||s,n,i,r)}},Er=nr.isFunction,Ir=function(){function t(){var t=this,e=!1,n=null,i=null;t.core=null,t.diagLog=function(e){return t._getTelCtx(e).diagLog()},t.isInitialized=function(){return e},t.setInitialized=function(t){e=t},t.setNextPlugin=function(t){i=t},t.processNext=function(t,e){e?e.processNext(t):i&&Er(i.processTelemetry)&&i.processTelemetry(t,null)},t._getTelCtx=function(e){void 0===e&&(e=null);var r=e;r||(r=(n||new jr(null,{},t.core)).createNew(null,i&&i.getPlugin?i.getPlugin:i));return r},t._baseTelInit=function(r,o,s,a){r&&(r.extensionConfig=r.extensionConfig||[]),!a&&o&&(a=o.getProcessTelContext().getNext());var c=i;i&&i.getPlugin&&(c=i.getPlugin()),t.core=o,n=new jr(a,r,o,c),e=!0}}return t.prototype.initialize=function(t,e,n,i){this._baseTelInit(t,e,n,i)},t}(),Fr=nr.isFunction;function Pr(t,e){for(var n=[],i=null,r=t.getNext();r;){var o=r.getPlugin();o&&(i&&Fr(i.setNextPlugin)&&Fr(o.processTelemetry)&&i.setNextPlugin(o),Fr(o.isInitialized)&&o.isInitialized()||n.push(o),i=o,r=r.getNext())}nr.arrForEach(n,(function(n){n.initialize(t.getCfg(),t.core(),e,t.getNext())}))}function Tr(t){return t.sort((function(t,e){var n=0,i=Fr(e.processTelemetry);return Fr(t.processTelemetry)?n=i?t.priority-e.priority:1:i&&(n=-1),n}))}var Mr=nr.objDefineAccessors,Rr=function(t){function e(){var n=t.call(this)||this;n.identifier="ChannelControllerPlugin",n.priority=500;var i,r=nr.arrForEach;function o(t){t&&t.length>0&&(function(t){r(t,(function(t){if(t.priority<500)throw Error("Channel has invalid priority"+t.identifier)}))}(t=t.sort((function(t,e){return t.priority-e.priority}))),i.push(t))}return gr(e,n,(function(t,e){t.setNextPlugin=function(){},t.processTelemetry=function(t,e){i&&r(i,(function(i){i.length>0&&n._getTelCtx(e).createNew(i).processNext(t)}))},t.getChannelControls=function(){return i},t.initialize=function(n,s,a){t.isInitialized()||(e.initialize(n,s,a),n.isCookieUseDisabled&&nr.disableCookies(),function(t,e){if(i=[],t&&r(t,(function(t){return o(t)})),e){var n=[];r(e,(function(t){t.priority>500&&n.push(t)})),o(n)}}((n||{}).channels,a),r(i,(function(t){return Pr(new jr(t,n,s),a)})))}})),n}return __extends(e,t),e.prototype.processTelemetry=function(){},e.prototype.getChannelControls=function(){return null},e.prototype.initialize=function(){},e._staticInit=(Mr(e.prototype,"ChannelControls",e.prototype.getChannelControls),void Mr(e.prototype,"channelQueue",e.prototype.getChannelControls)),e}(Ir),Nr=nr.arrForEach,Dr=nr.isNullOrUndefined,Or=function(){function t(){var e,n,i,r,o=!1;gr(t,this,(function(t){t._extensions=new Array,n=new Rr,t.logger=nr.objCreate({throwInternal:function(){},warnToConsole:function(){},resetInternalMessageCount:function(){}}),e=[],t.isInitialized=function(){return o},t.initialize=function(e,r,s,a){if(t.isInitialized())throw Error("Core should not be initialized more than once");if(!e||Dr(e.instrumentationKey))throw Error("Please provide instrumentation key");i=a,t._notificationManager=a,t.config=e||{},e.extensions=Dr(e.extensions)?[]:e.extensions,(e.extensionConfig=Dr(e.extensionConfig)?{}:e.extensionConfig).NotificationManager=a,s&&(t.logger=s);var c=[];c.push.apply(c,r.concat(e.extensions)),c=Tr(c);var u=[],l={};if(Nr(c,(function(t){if(Dr(t)||Dr(t.initialize))throw Error("Extensions must provide callback to initialize");var e=t.priority,i=t.identifier;t&&e&&(Dr(l[e])?l[e]=i:s.warnToConsole("Two extensions have same priority #"+e+" - "+l[e]+", "+i)),(!e||e<n.priority)&&u.push(t)})),c.push(n),u.push(n),c=Tr(c),t._extensions=c,Pr(new jr([n],e,t),c),Pr(new jr(u,e,t),c),t._extensions=u,0===t.getTransmissionControls().length)throw new Error("No channels available");o=!0,t.releaseQueue()},t.getTransmissionControls=function(){return n.getChannelControls()},t.track=function(n){n.iKey||(n.iKey=t.config.instrumentationKey),n.time||(n.time=nr.toISOString(new Date)),Dr(n.ver)&&(n.ver="4.0"),t.isInitialized()?t.getProcessTelContext().processNext(n):e.push(n)},t.getProcessTelContext=function(){var e=t._extensions,i=e;return e&&0!==e.length||(i=[n]),new jr(i,t.config,t)},t.getNotifyMgr=function(){return i||(i=nr.objCreate({addNotificationListener:function(){},removeNotificationListener:function(){},eventsSent:function(){},eventsDiscarded:function(){},eventsSendRequest:function(){}}),t._notificationManager=i),i},t.getPerfMgr=function(){return r||t.config&&t.config.enablePerfMgr&&(r=new Sr(t.getNotifyMgr())),r},t.setPerfMgr=function(t){r=t},t.eventCnt=function(){return e.length},t.releaseQueue=function(){e.length>0&&(Nr(e,(function(e){t.getProcessTelContext().processNext(e)})),e=[])}}))}return t.prototype.initialize=function(){},t.prototype.getTransmissionControls=function(){return null},t.prototype.track=function(){},t.prototype.getProcessTelContext=function(){return null},t.prototype.getNotifyMgr=function(){return null},t.prototype.getPerfMgr=function(){return null},t.prototype.setPerfMgr=function(){},t.prototype.eventCnt=function(){return 0},t.prototype.releaseQueue=function(){},t}(),Ur=function(){function t(e){this.listeners=[];var n=nr.arrForEach,i=!!(e||{}).perfEvtsSendAll;gr(t,this,(function(t){t.addNotificationListener=function(e){t.listeners.push(e)},t.removeNotificationListener=function(e){for(var n=nr.arrIndexOf(t.listeners,e);n>-1;)t.listeners.splice(n,1),n=nr.arrIndexOf(t.listeners,e)},t.eventsSent=function(e){n(t.listeners,(function(t){t&&t.eventsSent&&setTimeout((function(){return t.eventsSent(e)}),0)}))},t.eventsDiscarded=function(e,i){n(t.listeners,(function(t){t&&t.eventsDiscarded&&setTimeout((function(){return t.eventsDiscarded(e,i)}),0)}))},t.eventsSendRequest=function(e,i){n(t.listeners,(function(t){if(t&&t.eventsSendRequest)if(i)setTimeout((function(){return t.eventsSendRequest(e,i)}),0);else try{t.eventsSendRequest(e,i)}catch(t){}}))},t.perfEvent=function(e){e&&(!i&&e.isChildEvt()||n(t.listeners,(function(t){if(t&&t.perfEvent)if(e.isAsync)setTimeout((function(){return t.perfEvent(e)}),0);else try{t.perfEvent(e)}catch(t){}})))}}))}return t.prototype.addNotificationListener=function(){},t.prototype.removeNotificationListener=function(){},t.prototype.eventsSent=function(){},t.prototype.eventsDiscarded=function(){},t.prototype.eventsSendRequest=function(){},t}(),Lr=function(t){function e(){var n=t.call(this)||this;return gr(e,n,(function(t,e){function n(e){var n=t.getNotifyMgr();n&&n.eventsDiscarded([e],2)}t.initialize=function(t,n,i,r){e.initialize(t,n,i||new xr(t),r||new Ur(t))},t.track=function(i){Cr(t.getPerfMgr(),(function(){return"AppInsightsCore:track"}),(function(){if(null===i)throw n(i),Error("Invalid telemetry item");!function(t){if(nr.isNullOrUndefined(t.name))throw n(t),Error("telemetry name required")}(i),e.track(i)}),(function(){return{item:i}}),!i.sync)},t.addNotificationListener=function(e){var n=t.getNotifyMgr();n&&n.addNotificationListener(e)},t.removeNotificationListener=function(e){var n=t.getNotifyMgr();n&&n.removeNotificationListener(e)},t.pollInternalLogs=function(e){var n=t.config.diagnosticLogInterval;return n&&n>0||(n=1e4),setInterval((function(){var n=t.logger?t.logger.queue:[];nr.arrForEach(n,(function(n){var i={name:e||"InternalMessageId: "+n.messageId,iKey:t.config.instrumentationKey,time:nr.toISOString(new Date),baseType:yr.dataType,baseData:{message:n.message}};t.track(i)})),n.length=0}),n)}})),n}return __extends(e,t),e.prototype.initialize=function(){},e.prototype.track=function(){},e.prototype.addNotificationListener=function(){},e.prototype.removeNotificationListener=function(){},e.prototype.pollInternalLogs=function(){return 0},e}(Or),zr=["req","rsp","hkErr","fnErr"];function Vr(t,e){if(t)for(var n=0;n<t.length&&!e(t[n],n);n++);}function Hr(t,e,n,i,r){r>=0&&r<=2&&Vr(t,(function(t,o){var s=t.cbks,a=s[zr[r]];if(a){e.ctx=function(){return i[o]=i[o]||{}};try{a.apply(e.inst,n)}catch(t){var c=e.err;try{var u=s[zr[2]];u&&(e.err=t,u.apply(e.inst,n))}catch(t){}finally{e.err=c}}}}))}var Qr,Wr,$r,Yr=Object.getPrototypeOf;function Xr(t,e,n){var i=null;return t&&(nr.hasOwnProperty(t,e)?i=t:n&&(i=Xr(function(t){if(t){if(Yr)return Yr(t);var e=t.__proto__||t.prototype||t.constructor;if(e)return e}return null}(t),e,!1))),i}function Jr(t,e,n,i){if(void 0===i&&(i=!0),t&&e&&n){var r=Xr(t,e,i);if(r){var o=r[e];if("function"==typeof o){var s=o._aiHooks;if(!s){var a=(u=s={i:0,n:e,f:o,h:[]},function(){var t=this,e=arguments,n=u.h,i={name:u.n,inst:t,ctx:null,set:a},r=[],o=s([i],e);function s(t,e){return Vr(e,(function(e){t.push(e)})),t}function a(t,n){(e=s([],e))[t]=n,o=s([i],e)}Hr(n,i,o,r,0);var c=u.f;try{i.rslt=c.apply(t,e)}catch(t){throw i.err=t,Hr(n,i,o,r,3),t}return Hr(n,i,o,r,1),i.rslt});a._aiHooks=s,r[e]=a}var c={id:s.i,cbks:n,rm:function(){var t=this.id;Vr(s.h,(function(e,n){if(e.id===t)return s.h.splice(n,1),1}))}};return s.i++,s.h.push(c),c}}}var u;return null}!function(t){t[t.LocalStorage=0]="LocalStorage",t[t.SessionStorage=1]="SessionStorage"}(Qr||(Qr={})),function(t){t[t.Default=0]="Default",t[t.Required=1]="Required",t[t.Array=2]="Array",t[t.Hidden=4]="Hidden"}(Wr||(Wr={})),function(t){t[t.AI=0]="AI",t[t.AI_AND_W3C=1]="AI_AND_W3C",t[t.W3C=2]="W3C"}($r||($r={}));var Gr,Kr=function(){function t(){}return t.requestContextHeader="Request-Context",t.requestContextTargetKey="appId",t.requestContextAppIdFormat="appId=cid-v1:",t.requestIdHeader="Request-Id",t.traceParentHeader="traceparent",t.sdkContextHeader="Sdk-Context",t.sdkContextHeaderAppIdRequest="appId",t.requestContextHeaderLowerCase="request-context",t}(),Zr=function(){function t(){}return t.sanitizeKeyAndAddUniqueness=function(e,n,i){var r=n.length,o=t.sanitizeKey(e,n);if(o.length!==r){for(var s=0,a=o;void 0!==i[a];)s++,a=o.substring(0,t.MAX_NAME_LENGTH-3)+t.padNumber(s);o=a}return o},t.sanitizeKey=function(e,n){var i;return n&&(n=t.trim(n.toString())).length>t.MAX_NAME_LENGTH&&(i=n.substring(0,t.MAX_NAME_LENGTH),e.throwInternal(er.WARNING,57,"name is too long. It has been truncated to "+t.MAX_NAME_LENGTH+" characters.",{name:n},!0)),i||n},t.sanitizeString=function(e,n,i){var r;return void 0===i&&(i=t.MAX_STRING_LENGTH),n&&(i=i||t.MAX_STRING_LENGTH,(n=t.trim(n)).toString().length>i&&(r=n.toString().substring(0,i),e.throwInternal(er.WARNING,61,"string value is too long. It has been truncated to "+i+" characters.",{value:n},!0))),r||n},t.sanitizeUrl=function(e,n){return t.sanitizeInput(e,n,t.MAX_URL_LENGTH,66)},t.sanitizeMessage=function(e,n){var i;return n&&n.length>t.MAX_MESSAGE_LENGTH&&(i=n.substring(0,t.MAX_MESSAGE_LENGTH),e.throwInternal(er.WARNING,56,"message is too long, it has been truncated to "+t.MAX_MESSAGE_LENGTH+" characters.",{message:n},!0)),i||n},t.sanitizeException=function(e,n){var i;return n&&n.length>t.MAX_EXCEPTION_LENGTH&&(i=n.substring(0,t.MAX_EXCEPTION_LENGTH),e.throwInternal(er.WARNING,52,"exception is too long, it has been truncated to "+t.MAX_EXCEPTION_LENGTH+" characters.",{exception:n},!0)),i||n},t.sanitizeProperties=function(e,n){if(n){var i={};tr(n,(function(n,r){if(nr.isObject(r)&&Di())try{r=Oi().stringify(r)}catch(t){e.throwInternal(er.WARNING,49,"custom property is not valid",{exception:t},!0)}r=t.sanitizeString(e,r,t.MAX_PROPERTY_LENGTH),n=t.sanitizeKeyAndAddUniqueness(e,n,i),i[n]=r})),n=i}return n},t.sanitizeMeasurements=function(e,n){if(n){var i={};tr(n,(function(n,r){n=t.sanitizeKeyAndAddUniqueness(e,n,i),i[n]=r})),n=i}return n},t.sanitizeId=function(e,n){return n?t.sanitizeInput(e,n,t.MAX_ID_LENGTH,69).toString():n},t.sanitizeInput=function(e,n,i,r){var o;return n&&(n=t.trim(n)).length>i&&(o=n.substring(0,i),e.throwInternal(er.WARNING,r,"input is too long, it has been truncated to "+i+" characters.",{data:n},!0)),o||n},t.padNumber=function(t){var e="00"+t;return e.substr(e.length-3)},t.trim=function(t){return nr.isString(t)?t.replace(/^\s+|\s+$/g,""):t},t.MAX_NAME_LENGTH=150,t.MAX_ID_LENGTH=128,t.MAX_PROPERTY_LENGTH=8192,t.MAX_STRING_LENGTH=1024,t.MAX_URL_LENGTH=2048,t.MAX_MESSAGE_LENGTH=32768,t.MAX_EXCEPTION_LENGTH=32768,t}(),to=Mi(),eo=nr.isString,no=null,io=function(){function t(){}return t.createDomEvent=function(t){var e=null;if(nr.isFunction(Event))e=new Event(t);else{var n=Ti();n&&n.createEvent&&(e=n.createEvent("Event")).initEvent(t,!0,!0)}return e},t.disableStorage=function(){t._canUseLocalStorage=!1,t._canUseSessionStorage=!1},t._getLocalStorageObject=function(){return t.canUseLocalStorage()?t._getVerifiedStorageObject(Qr.LocalStorage):null},t._getVerifiedStorageObject=function(t){var e,n,i=null;try{if(nr.isNullOrUndefined(ji()))return null;n=new Date,(i=Ei(t===Qr.LocalStorage?"localStorage":"sessionStorage")).setItem(n.toString(),n.toString()),e=i.getItem(n.toString())!==n.toString(),i.removeItem(n.toString()),e&&(i=null)}catch(t){i=null}return i},t.isInternalApplicationInsightsEndpoint=function(e){return-1!==t._internalEndpoints.indexOf(e.toLowerCase())},t.canUseLocalStorage=function(){return void 0===t._canUseLocalStorage&&(t._canUseLocalStorage=!!t._getVerifiedStorageObject(Qr.LocalStorage)),t._canUseLocalStorage},t.getStorage=function(e,n){var i=t._getLocalStorageObject();if(null!==i)try{return i.getItem(n)}catch(n){t._canUseLocalStorage=!1,e.throwInternal(er.WARNING,1,"Browser failed read of local storage. "+t.getExceptionName(n),{exception:t.dump(n)})}return null},t.setStorage=function(e,n,i){var r=t._getLocalStorageObject();if(null!==r)try{return r.setItem(n,i),!0}catch(n){t._canUseLocalStorage=!1,e.throwInternal(er.WARNING,3,"Browser failed write to local storage. "+t.getExceptionName(n),{exception:t.dump(n)})}return!1},t.removeStorage=function(e,n){var i=t._getLocalStorageObject();if(null!==i)try{return i.removeItem(n),!0}catch(n){t._canUseLocalStorage=!1,e.throwInternal(er.WARNING,5,"Browser failed removal of local storage item. "+t.getExceptionName(n),{exception:t.dump(n)})}return!1},t._getSessionStorageObject=function(){return t.canUseSessionStorage()?t._getVerifiedStorageObject(Qr.SessionStorage):null},t.canUseSessionStorage=function(){return void 0===t._canUseSessionStorage&&(t._canUseSessionStorage=!!t._getVerifiedStorageObject(Qr.SessionStorage)),t._canUseSessionStorage},t.getSessionStorageKeys=function(){var e=[];return t.canUseSessionStorage()&&tr(Ei("sessionStorage"),(function(t){e.push(t)})),e},t.getSessionStorage=function(e,n){var i=t._getSessionStorageObject();if(null!==i)try{return i.getItem(n)}catch(n){t._canUseSessionStorage=!1,e.throwInternal(er.WARNING,2,"Browser failed read of session storage. "+t.getExceptionName(n),{exception:t.dump(n)})}return null},t.setSessionStorage=function(e,n,i){var r=t._getSessionStorageObject();if(null!==r)try{return r.setItem(n,i),!0}catch(n){t._canUseSessionStorage=!1,e.throwInternal(er.WARNING,4,"Browser failed write to session storage. "+t.getExceptionName(n),{exception:t.dump(n)})}return!1},t.removeSessionStorage=function(e,n){var i=t._getSessionStorageObject();if(null!==i)try{return i.removeItem(n),!0}catch(n){t._canUseSessionStorage=!1,e.throwInternal(er.WARNING,6,"Browser failed removal of session storage item. "+t.getExceptionName(n),{exception:t.dump(n)})}return!1},t.disableCookies=function(){nr.disableCookies()},t.canUseCookies=function(e){if(void 0===nr._canUseCookies){nr._canUseCookies=!1;try{nr._canUseCookies=void 0!==t.document.cookie}catch(n){e.throwInternal(er.WARNING,68,"Cannot access document.cookie - "+t.getExceptionName(n),{exception:t.dump(n)})}}return nr._canUseCookies},t.disallowsSameSiteNone=function(t){return!!eo(t)&&(-1!==t.indexOf("CPU iPhone OS 12")||-1!==t.indexOf("iPad; CPU OS 12")||-1!==t.indexOf("Macintosh; Intel Mac OS X 10_14")&&-1!==t.indexOf("Version/")&&-1!==t.indexOf("Safari")||-1!==t.indexOf("Macintosh; Intel Mac OS X 10_14")&&"AppleWebKit/605.1.15 (KHTML, like Gecko)"===(e=t).substring((i=(n=e.length)-"AppleWebKit/605.1.15 (KHTML, like Gecko)".length)>=0?i:0,n)||-1!==t.indexOf("Chrome/5")||-1!==t.indexOf("Chrome/6")||-1!==t.indexOf("UnrealEngine")&&-1===t.indexOf("Chrome")||-1!==t.indexOf("UCBrowser/12")||-1!==t.indexOf("UCBrowser/11"));var e,n,i},t.setCookie=function(e,n,i,r){if(t.canUseCookies(e)){var o="",s="";r&&(o=";domain="+r);var a=Ri();a&&"https:"===a.protocol&&(s=";secure",null===no&&(no=t.disallowsSameSiteNone((Mi()||{}).userAgent)),no||(i+=";SameSite=None")),t.document.cookie=n+"="+i+o+";path=/"+s}},t.stringToBoolOrDefault=function(t,e){return void 0===e&&(e=!1),null==t?e:"true"===t.toString().toLowerCase()},t.getCookie=function(e,n){if(t.canUseCookies(e)){var i="";if(n&&n.length)for(var r=n+"=",o=t.document.cookie.split(";"),s=0;s<o.length;s++){var a=o[s];if((a=t.trim(a))&&0===a.indexOf(r)){i=a.substring(r.length,o[s].length);break}}return i}},t.deleteCookie=function(e,n){t.canUseCookies(e)&&(t.document.cookie=n+"=;path=/;expires=Thu, 01 Jan 1970 00:00:01 GMT;")},t.random32=function(){return nr.random32(!0)},t.getIEVersion=function(t){void 0===t&&(t=null);var e=t?t.toLowerCase():to?(to.userAgent||"").toLowerCase():"";if(-1!==e.indexOf("msie"))return parseInt(e.split("msie")[1]);if(e.indexOf("trident/")){var n=parseInt(e.split("trident/")[1]);if(n)return n+4}return null},t.msToTimeSpan=function(t){(isNaN(t)||t<0)&&(t=0);var e=""+(t=Math.round(t))%1e3,n=""+Math.floor(t/1e3)%60,i=""+Math.floor(t/6e4)%60,r=""+Math.floor(t/36e5)%24,o=Math.floor(t/864e5);return(o>0?o+".":"")+(r=r.length<2?"0"+r:r)+":"+(i=i.length<2?"0"+i:i)+":"+(n=n.length<2?"0"+n:n)+"."+(1===e.length?"00"+e:2===e.length?"0"+e:e)},t.isCrossOriginError=function(t,e,n,i,r){return("Script error."===t||"Script error"===t)&&!r},t.dump=function(t){var e=Object.prototype.toString.call(t),n="";return"[object Error]"===e?n="{ stack: '"+t.stack+"', message: '"+t.message+"', name: '"+t.name+"'":Di()&&(n=Oi().stringify(t)),e+n},t.getExceptionName=function(t){return"[object Error]"===Object.prototype.toString.call(t)?t.name:""},t.addEventHandler=function(t,e){return rr.Attach(Fi(),t,e)},t.IsBeaconApiSupported=function(){return"sendBeacon"in to&&to.sendBeacon},t.getExtension=function(t,e){for(var n=null,i=0;!n&&i<t.length;)t[i]&&t[i].identifier===e&&(n=t[i]),i++;return n},t.document=Ti()||{},t._canUseLocalStorage=void 0,t._canUseSessionStorage=void 0,t._internalEndpoints=["https://dc.services.visualstudio.com/v2/track","https://breeze.aimon.applicationinsights.io/v2/track","https://dc-int.services.visualstudio.com/v2/track"],t.NotSpecified="not_specified",t.trim=nr.strTrim,t.newId=nr.newId,t.generateW3CId=nr.generateW3CId,t.isArray=nr.isArray,t.isError=nr.isError,t.isDate=nr.isDate,t.toISOStringForIE8=nr.toISOString,t}(),ro=function(){function t(){}return t.parseUrl=function(e){var n=t._htmlAnchorIdx,i=t._htmlAnchorElement,r=i[n];return t.document.createElement?i[n]||(r=i[n]=t.document.createElement("a")):r={host:t.parseHost(e,!0)},r.href=e,++n>=i.length&&(n=0),t._htmlAnchorIdx=n,r},t.getAbsoluteUrl=function(e){var n,i=t.parseUrl(e);return i&&(n=i.href),n},t.getPathName=function(e){var n,i=t.parseUrl(e);return i&&(n=i.pathname),n},t.getCompleteUrl=function(t,e){return t?t.toUpperCase()+" "+e:e},t.parseHost=function(e,n){var i=t.parseFullHost(e,n);if(i){var r=i.match(/(www[0-9]?\.)?(.[^/:]+)(\:[\d]+)?/i);if(null!=r&&r.length>3&&eo(r[2])&&r[2].length>0)return r[2]+(r[3]||"")}return i},t.parseFullHost=function(t,e){var n=null;if(t){var i=t.match(/(\w*):\/\/(.[^/:]+)(\:[\d]+)?/i);if(null!=i&&i.length>2&&eo(i[2])&&i[2].length>0&&(n=i[2]||"",e&&i.length>2)){var r=(i[1]||"").toLowerCase(),o=i[3]||"";("http"===r&&":80"===o||"https"===r&&":443"===o)&&(o=""),n+=o}}return n},t.document=Ti()||{},t._htmlAnchorIdx=0,t._htmlAnchorElement=[null,null,null,null,null],t}(),oo=function(){function t(){}return t.canIncludeCorrelationHeader=function(t,e,n){if(!e||t&&t.disableCorrelationHeaders)return!1;if(t&&t.correlationHeaderExcludePatterns)for(var i=0;i<t.correlationHeaderExcludePatterns.length;i++)if(t.correlationHeaderExcludePatterns[i].test(e))return!1;var r=ro.parseUrl(e).host.toLowerCase();if(!r||-1===r.indexOf(":443")&&-1===r.indexOf(":80")||(r=(ro.parseFullHost(e,!0)||"").toLowerCase()),!(t&&t.enableCorsCorrelation||r===n))return!1;var o,s=t&&t.correlationHeaderDomains;if(s&&(nr.arrForEach(s,(function(t){var e=new RegExp(t.toLowerCase().replace(/\./g,".").replace(/\*/g,".*"));o=o||e.test(r)})),!o))return!1;var a=t&&t.correlationHeaderExcludedDomains;if(!a||0===a.length)return!0;for(i=0;i<a.length;i++)if(new RegExp(a[i].toLowerCase().replace(/\./g,".").replace(/\*/g,".*")).test(r))return!1;return r&&r.length>0},t.getCorrelationContext=function(e){if(e){var n=t.getCorrelationContextValue(e,Kr.requestContextTargetKey);if(n&&n!==t.correlationIdPrefix)return n}},t.getCorrelationContextValue=function(t,e){if(t)for(var n=t.split(","),i=0;i<n.length;++i){var r=n[i].split("=");if(2===r.length&&r[0]===e)return r[1]}},t.correlationIdPrefix="cid-v1:",t}(),so=function(){function t(){}return t.ParseDependencyPath=function(t,e,n,i){var r,o=i,s=i;if(e&&e.length>0){var a=ro.parseUrl(e);if(r=a.host,!o)if(null!=a.pathname){var c=0===a.pathname.length?"/":a.pathname;"/"!==c.charAt(0)&&(c="/"+c),s=a.pathname,o=Zr.sanitizeString(t,n?n+" "+c:c)}else o=Zr.sanitizeString(t,e)}else r=i,o=i;return{target:r,name:o,data:s}},t}(),ao=function(){function t(){}return t.Now=function(){var t=Ni();if(t&&t.now&&t.timing){var e=t.now()+t.timing.navigationStart;if(e>0)return e}return(new Date).getTime()},t.GetDuration=function(t,e){var n=null;return 0===t||0===e||nr.isNullOrUndefined(t)||nr.isNullOrUndefined(e)||(n=e-t),n},t}(),co="Microsoft_ApplicationInsights_BypassAjaxInstrumentation",uo=function(){function t(){}return t.parse=function(e){if(!e)return{};var n=e.split(t._FIELDS_SEPARATOR),i=nr.arrReduce(n,(function(e,n){var i=n.split(t._FIELD_KEY_VALUE_SEPARATOR);return 2===i.length&&(e[i[0].toLowerCase()]=i[1]),e}),{});return nr.objKeys(i).length>0&&(i.endpointsuffix&&(i.ingestionendpoint=i.ingestionendpoint||"https://"+(i.location?i.location+".":"")+"dc."+i.endpointsuffix),i.ingestionendpoint=i.ingestionendpoint||"https://dc.services.visualstudio.com"),i},t._FIELDS_SEPARATOR=";",t._FIELD_KEY_VALUE_SEPARATOR="=",t}(),lo=function(t){function e(){return t.call(this)||this}return __extends(e,t),e}((function(){})),fo=function(t){function e(e,n,i){var r=t.call(this)||this;return r.name=Zr.sanitizeString(e,i)||io.NotSpecified,r.data=n,r.time=nr.toISOString(new Date),r.aiDataContract={time:Wr.Required,iKey:Wr.Required,name:Wr.Required,sampleRate:function(){return 100===r.sampleRate?Wr.Hidden:Wr.Required},tags:Wr.Required,data:Wr.Required},r}return __extends(e,t),e}((function(){this.ver=1,this.sampleRate=100,this.tags={}})),ho=function(){},po=function(t){function e(){var e=t.call(this)||this;return e.ver=2,e.properties={},e.measurements={},e}return __extends(e,t),e}(ho),mo=function(t){function e(e,n,i,r){var o=t.call(this)||this;return o.aiDataContract={ver:Wr.Required,name:Wr.Required,properties:Wr.Default,measurements:Wr.Default},o.name=Zr.sanitizeString(e,n)||io.NotSpecified,o.properties=Zr.sanitizeProperties(e,i),o.measurements=Zr.sanitizeMeasurements(e,r),o}return __extends(e,t),e.envelopeType="Microsoft.ApplicationInsights.{0}.Event",e.dataType="EventData",e}(po),vo=function(t){function e(e,n,i,r,o,s){var a,c=t.call(this)||this;return c.aiDataContract={ver:Wr.Required,exceptions:Wr.Required,severityLevel:Wr.Default,properties:Wr.Default,measurements:Wr.Default},"ver"in(a=n)&&"exceptions"in a&&"properties"in a?(c.exceptions=n.exceptions,c.properties=n.properties,c.measurements=n.measurements,n.severityLevel&&(c.severityLevel=n.severityLevel),n.id&&(c.id=n.id),n.problemGroup&&(c.problemGroup=n.problemGroup),c.ver=2,nr.isNullOrUndefined(n.isManual)||(c.isManual=n.isManual)):(c.exceptions=[new bo(e,n)],c.properties=Zr.sanitizeProperties(e,i)||{},c.measurements=Zr.sanitizeMeasurements(e,r),o&&(c.severityLevel=o),s&&(c.id=s)),c}return __extends(e,t),e.CreateFromInterface=function(t,n,i,r){var o=n.exceptions&&nr.arrMap(n.exceptions,(function(e){return bo.CreateFromInterface(t,e)}));return new e(t,__assign({},n,{exceptions:o}),i,r)},e.prototype.toInterface=function(){var t=this,e=t.exceptions,n=t.properties,i=t.measurements,r=t.severityLevel,o=t.problemGroup,s=t.id,a=t.isManual;return{ver:"4.0",exceptions:e instanceof Array&&nr.arrMap(e,(function(t){return t.toInterface()}))||void 0,severityLevel:r,properties:n,measurements:i,problemGroup:o,id:s,isManual:a}},e.CreateSimpleException=function(t,e,n,i,r){return{exceptions:[{hasFullStack:!0,message:t,stack:r,typeName:e}]}},e.envelopeType="Microsoft.ApplicationInsights.{0}.Exception",e.dataType="ExceptionData",e}(function(t){function e(){var e=t.call(this)||this;return e.ver=2,e.exceptions=[],e.properties={},e.measurements={},e}return __extends(e,t),e}(ho)),bo=function(t){function e(n,i){var r,o=t.call(this)||this;if(o.aiDataContract={id:Wr.Default,outerId:Wr.Default,typeName:Wr.Required,message:Wr.Required,hasFullStack:Wr.Default,stack:Wr.Default,parsedStack:Wr.Array},"hasFullStack"in(r=i)&&"typeName"in r)o.typeName=i.typeName,o.message=i.message,o.stack=i.stack,o.parsedStack=i.parsedStack,o.hasFullStack=i.hasFullStack;else{var s=i;io.isError(s)||(s=s.error||s.evt||s),o.typeName=Zr.sanitizeString(n,function(t){var e="";if(t&&!(e=t.typeName||t.name||""))try{var n=/function (.{1,})\(/.exec(t.constructor.toString());e=n&&n.length>1?n[1]:""}catch(t){}return e}(s))||io.NotSpecified,o.message=Zr.sanitizeMessage(n,i.message)||io.NotSpecified;var a=i.stack;o.parsedStack=e.parseStack(a),o.stack=Zr.sanitizeException(n,a),o.hasFullStack=io.isArray(o.parsedStack)&&o.parsedStack.length>0}return o}return __extends(e,t),e.prototype.toInterface=function(){var t=this.parsedStack instanceof Array&&nr.arrMap(this.parsedStack,(function(t){return t.toInterface()}));return{id:this.id,outerId:this.outerId,typeName:this.typeName,message:this.message,hasFullStack:this.hasFullStack,stack:this.stack,parsedStack:t||void 0}},e.CreateFromInterface=function(t,n){var i=n.parsedStack instanceof Array&&nr.arrMap(n.parsedStack,(function(t){return go.CreateFromInterface(t)}))||n.parsedStack;return new e(t,__assign({},n,{parsedStack:i}))},e.parseStack=function(t){var e;if(nr.isString(t)){var n=t.split("\n");e=[];for(var i=0,r=0,o=0;o<=n.length;o++)if(go.regex.test(n[o])){var s=new go(n[o],i++);r+=s.sizeInBytes,e.push(s)}if(r>32768)for(var a=0,c=e.length-1,u=0,l=a,f=c;a<c;){if((u+=e[a].sizeInBytes+e[c].sizeInBytes)>32768){e.splice(l,f-l+1);break}l=a,f=c,a++,c--}}return e},e}((function(){this.hasFullStack=!0,this.parsedStack=[]})),go=function(t){function e(n,i){var r=t.call(this)||this;if(r.sizeInBytes=0,r.aiDataContract={level:Wr.Required,method:Wr.Required,assembly:Wr.Default,fileName:Wr.Default,line:Wr.Default},"string"==typeof n){var o=n;r.level=i,r.method="<no_method>",r.assembly=io.trim(o),r.fileName="",r.line=0;var s=o.match(e.regex);s&&s.length>=5&&(r.method=io.trim(s[2])||r.method,r.fileName=io.trim(s[4]),r.line=parseInt(s[5])||0)}else r.level=n.level,r.method=n.method,r.assembly=n.assembly,r.fileName=n.fileName,r.line=n.line,r.sizeInBytes=0;return r.sizeInBytes+=r.method.length,r.sizeInBytes+=r.fileName.length,r.sizeInBytes+=r.assembly.length,r.sizeInBytes+=e.baseSize,r.sizeInBytes+=r.level.toString().length,r.sizeInBytes+=r.line.toString().length,r}return __extends(e,t),e.CreateFromInterface=function(t){return new e(t,null)},e.prototype.toInterface=function(){return{level:this.level,method:this.method,assembly:this.assembly,fileName:this.fileName,line:this.line}},e.regex=/^([\s]+at)?(.*?)(\@|\s\(|\s)([^\(\@\n]+):([0-9]+):([0-9]+)(\)?)$/,e.baseSize=58,e}((function(){})),wo=function(t){function e(){var e=t.call(this)||this;return e.ver=2,e.metrics=[],e.properties={},e.measurements={},e}return __extends(e,t),e}(ho);!function(t){t[t.Measurement=0]="Measurement",t[t.Aggregation=1]="Aggregation"}(Gr||(Gr={}));var yo,xo=function(t){function e(){var e=null!==t&&t.apply(this,arguments)||this;return e.aiDataContract={name:Wr.Required,kind:Wr.Default,value:Wr.Required,count:Wr.Default,min:Wr.Default,max:Wr.Default,stdDev:Wr.Default},e}return __extends(e,t),e}((function(){this.kind=Gr.Measurement})),ko=function(t){function e(e,n,i,r,o,s,a,c){var u=t.call(this)||this;u.aiDataContract={ver:Wr.Required,metrics:Wr.Required,properties:Wr.Default};var l=new xo;return l.count=r>0?r:void 0,l.max=isNaN(s)||null===s?void 0:s,l.min=isNaN(o)||null===o?void 0:o,l.name=Zr.sanitizeString(e,n)||io.NotSpecified,l.value=i,u.metrics=[l],u.properties=Zr.sanitizeProperties(e,a),u.measurements=Zr.sanitizeMeasurements(e,c),u}return __extends(e,t),e.envelopeType="Microsoft.ApplicationInsights.{0}.Metric",e.dataType="MetricData",e}(wo),So=function(t){function e(){var e=t.call(this)||this;return e.ver=2,e.properties={},e.measurements={},e}return __extends(e,t),e}(po),Co=function(t){function e(e,n,i,r,o,s,a){var c=t.call(this)||this;return c.aiDataContract={ver:Wr.Required,name:Wr.Default,url:Wr.Default,duration:Wr.Default,properties:Wr.Default,measurements:Wr.Default,id:Wr.Default},c.id=Zr.sanitizeId(e,a),c.url=Zr.sanitizeUrl(e,i),c.name=Zr.sanitizeString(e,n)||io.NotSpecified,isNaN(r)||(c.duration=io.msToTimeSpan(r)),c.properties=Zr.sanitizeProperties(e,o),c.measurements=Zr.sanitizeMeasurements(e,s),c}return __extends(e,t),e.envelopeType="Microsoft.ApplicationInsights.{0}.Pageview",e.dataType="PageviewData",e}(So),_o=function(t){function e(e,n,i,r,o,s,a,c,u,l,f,d){void 0===u&&(u="Ajax");var h=t.call(this)||this;h.aiDataContract={id:Wr.Required,ver:Wr.Required,name:Wr.Default,resultCode:Wr.Default,duration:Wr.Default,success:Wr.Default,data:Wr.Default,target:Wr.Default,type:Wr.Default,properties:Wr.Default,measurements:Wr.Default,kind:Wr.Default,value:Wr.Default,count:Wr.Default,min:Wr.Default,max:Wr.Default,stdDev:Wr.Default,dependencyKind:Wr.Default,dependencySource:Wr.Default,commandName:Wr.Default,dependencyTypeName:Wr.Default},h.id=n,h.duration=io.msToTimeSpan(o),h.success=s,h.resultCode=a+"",h.type=Zr.sanitizeString(e,u);var p=so.ParseDependencyPath(e,i,c,r);return h.data=Zr.sanitizeUrl(e,r)||p.data,h.target=Zr.sanitizeString(e,p.target),l&&(h.target=h.target+" | "+l),h.name=Zr.sanitizeString(e,p.name),h.properties=Zr.sanitizeProperties(e,f),h.measurements=Zr.sanitizeMeasurements(e,d),h}return __extends(e,t),e.envelopeType="Microsoft.ApplicationInsights.{0}.RemoteDependency",e.dataType="RemoteDependencyData",e}(function(t){function e(){var e=t.call(this)||this;return e.ver=2,e.success=!0,e.properties={},e.measurements={},e}return __extends(e,t),e}(ho)),Ao=function(t){function e(e,n,i,r,o){var s=t.call(this)||this;return s.aiDataContract={ver:Wr.Required,message:Wr.Required,severityLevel:Wr.Default,properties:Wr.Default},s.message=Zr.sanitizeMessage(e,n=n||io.NotSpecified),s.properties=Zr.sanitizeProperties(e,r),s.measurements=Zr.sanitizeMeasurements(e,o),i&&(s.severityLevel=i),s}return __extends(e,t),e.envelopeType="Microsoft.ApplicationInsights.{0}.Message",e.dataType="MessageData",e}(function(t){function e(){var e=t.call(this)||this;return e.ver=2,e.properties={},e.measurements={},e}return __extends(e,t),e}(ho)),qo=function(t){function e(e,n,i,r,o,s,a){var c=t.call(this)||this;return c.aiDataContract={ver:Wr.Required,name:Wr.Default,url:Wr.Default,duration:Wr.Default,perfTotal:Wr.Default,networkConnect:Wr.Default,sentRequest:Wr.Default,receivedResponse:Wr.Default,domProcessing:Wr.Default,properties:Wr.Default,measurements:Wr.Default},c.url=Zr.sanitizeUrl(e,i),c.name=Zr.sanitizeString(e,n)||io.NotSpecified,c.properties=Zr.sanitizeProperties(e,o),c.measurements=Zr.sanitizeMeasurements(e,s),a&&(c.domProcessing=a.domProcessing,c.duration=a.duration,c.networkConnect=a.networkConnect,c.perfTotal=a.perfTotal,c.receivedResponse=a.receivedResponse,c.sentRequest=a.sentRequest),c}return __extends(e,t),e.envelopeType="Microsoft.ApplicationInsights.{0}.PageviewPerformance",e.dataType="PageviewPerformanceData",e}(function(t){function e(){var e=t.call(this)||this;return e.ver=2,e.properties={},e.measurements={},e}return __extends(e,t),e}(So)),Bo=function(t){function e(e,n){var i=t.call(this)||this;return i.aiDataContract={baseType:Wr.Required,baseData:Wr.Required},i.baseType=e,i.baseData=n,i}return __extends(e,t),e}(lo);!function(t){t[t.Verbose=0]="Verbose",t[t.Information=1]="Information",t[t.Warning=2]="Warning",t[t.Error=3]="Error",t[t.Critical=4]="Critical"}(yo||(yo={}));var jo=function(){this.applicationVersion="ai.application.ver",this.applicationBuild="ai.application.build",this.applicationTypeId="ai.application.typeId",this.applicationId="ai.application.applicationId",this.applicationLayer="ai.application.layer",this.deviceId="ai.device.id",this.deviceIp="ai.device.ip",this.deviceLanguage="ai.device.language",this.deviceLocale="ai.device.locale",this.deviceModel="ai.device.model",this.deviceFriendlyName="ai.device.friendlyName",this.deviceNetwork="ai.device.network",this.deviceNetworkName="ai.device.networkName",this.deviceOEMName="ai.device.oemName",this.deviceOS="ai.device.os",this.deviceOSVersion="ai.device.osVersion",this.deviceRoleInstance="ai.device.roleInstance",this.deviceRoleName="ai.device.roleName",this.deviceScreenResolution="ai.device.screenResolution",this.deviceType="ai.device.type",this.deviceMachineName="ai.device.machineName",this.deviceVMName="ai.device.vmName",this.deviceBrowser="ai.device.browser",this.deviceBrowserVersion="ai.device.browserVersion",this.locationIp="ai.location.ip",this.locationCountry="ai.location.country",this.locationProvince="ai.location.province",this.locationCity="ai.location.city",this.operationId="ai.operation.id",this.operationName="ai.operation.name",this.operationParentId="ai.operation.parentId",this.operationRootId="ai.operation.rootId",this.operationSyntheticSource="ai.operation.syntheticSource",this.operationCorrelationVector="ai.operation.correlationVector",this.sessionId="ai.session.id",this.sessionIsFirst="ai.session.isFirst",this.sessionIsNew="ai.session.isNew",this.userAccountAcquisitionDate="ai.user.accountAcquisitionDate",this.userAccountId="ai.user.accountId",this.userAgent="ai.user.userAgent",this.userId="ai.user.id",this.userStoreRegion="ai.user.storeRegion",this.userAuthUserId="ai.user.authUserId",this.userAnonymousUserAcquisitionDate="ai.user.anonUserAcquisitionDate",this.userAuthenticatedUserAcquisitionDate="ai.user.authUserAcquisitionDate",this.cloudName="ai.cloud.name",this.cloudRole="ai.cloud.role",this.cloudRoleVer="ai.cloud.roleVer",this.cloudRoleInstance="ai.cloud.roleInstance",this.cloudEnvironment="ai.cloud.environment",this.cloudLocation="ai.cloud.location",this.cloudDeploymentUnit="ai.cloud.deploymentUnit",this.internalNodeName="ai.internal.nodeName",this.internalSdkVersion="ai.internal.sdkVersion",this.internalAgentVersion="ai.internal.agentVersion",this.internalSnippet="ai.internal.snippet",this.internalSdkSrc="ai.internal.sdkSrc"},Eo=function(){function t(){}return t.create=function(t,e,n,i,r,o){if(n=Zr.sanitizeString(i,n)||io.NotSpecified,nr.isNullOrUndefined(t)||nr.isNullOrUndefined(e)||nr.isNullOrUndefined(n))throw Error("Input doesn't contain all required fields");var s={name:n,time:nr.toISOString(new Date),iKey:"",ext:o||{},tags:[],data:{},baseType:e,baseData:t};return nr.isNullOrUndefined(r)||tr(r,(function(t,e){s.data[t]=e})),s},t}(),Io=function(){function t(){}return t.UserExt="user",t.DeviceExt="device",t.TraceExt="trace",t.WebExt="web",t.AppExt="app",t.OSExt="os",t.SessionExt="ses",t.SDKExt="sdk",t}(),Fo=new jo,Po=function t(e,n,i,r){gr(t,this,(function(t){var o,s=nr.arrForEach,a=nr.isNullOrUndefined,c=null,u=[],l=!1;function f(){i&&s(i.getTransmissionControls(),(function(t){s(t,(function(t){return t.flush(!0)}))}))}i&&(o=i.logger),t.trackPageView=function(t,i){var d=t.name;if(a(d)||"string"!=typeof d){var h=Ti();d=t.name=h&&h.title||""}var p=t.uri;if(a(p)||"string"!=typeof p){var m=Ri();p=t.uri=m&&m.href||""}if(!r.isPerformanceTimingSupported())return e.sendPageViewInternal(t,i),f(),void o.throwInternal(er.WARNING,25,"trackPageView: navigation timing API used for calculation of page duration is not supported in this browser. This page view will be collected without duration and timing info.");var v,b,g=!1,w=r.getPerformanceTiming().navigationStart;w>0&&(v=ao.GetDuration(w,+new Date),r.shouldCollectDuration(v)||(v=void 0)),a(i)||a(i.duration)||(b=i.duration),!n&&isNaN(b)||(isNaN(b)&&(i||(i={}),i.duration=v),e.sendPageViewInternal(t,i),f(),g=!0),i||(i={}),u.push((function(){var n=!1;try{if(r.isPerformanceTimingDataReady()){n=!0;var s={name:d,uri:p};r.populatePageViewPerformanceEvent(s),s.isValid||g?(g||(i.duration=s.durationMs,e.sendPageViewInternal(t,i)),l||(e.sendPageViewPerformanceInternal(s,i),l=!0)):(i.duration=v,e.sendPageViewInternal(t,i))}else w>0&&ao.GetDuration(w,+new Date)>6e4&&(n=!0,g||(i.duration=6e4,e.sendPageViewInternal(t,i)))}catch(t){o.throwInternal(er.CRITICAL,38,"trackPageView failed on page load calculation: "+io.getExceptionName(t),{exception:io.dump(t)})}return n})),c||(c=setInterval((function(){var t=u.slice(0),e=!1;u=[],s(t,(function(t){t()?e=!0:u.push(t)})),0===u.length&&(clearInterval(c),c=null),e&&f()}),100))}}))},To=function(){function t(t,e){this.prevPageVisitDataKeyName="prevPageVisitData",this.pageVisitTimeTrackingHandler=e,this._logger=t}return t.prototype.trackPreviousPageVisit=function(t,e){try{var n=this.restartPageVisitTimer(t,e);n&&this.pageVisitTimeTrackingHandler(n.pageName,n.pageUrl,n.pageVisitTime)}catch(t){this._logger.warnToConsole("Auto track page visit time failed, metric will not be collected: "+io.dump(t))}},t.prototype.restartPageVisitTimer=function(t,e){try{var n=this.stopPageVisitTimer();return this.startPageVisitTimer(t,e),n}catch(t){return this._logger.warnToConsole("Call to restart failed: "+io.dump(t)),null}},t.prototype.startPageVisitTimer=function(t,e){try{if(io.canUseSessionStorage()){if(null!=io.getSessionStorage(this._logger,this.prevPageVisitDataKeyName))throw new Error("Cannot call startPageVisit consecutively without first calling stopPageVisit");var n=new Mo(t,e),i=Oi().stringify(n);io.setSessionStorage(this._logger,this.prevPageVisitDataKeyName,i)}}catch(t){this._logger.warnToConsole("Call to start failed: "+io.dump(t))}},t.prototype.stopPageVisitTimer=function(){try{if(io.canUseSessionStorage()){var t=nr.dateNow(),e=io.getSessionStorage(this._logger,this.prevPageVisitDataKeyName);if(e&&Di()){var n=Oi().parse(e);return n.pageVisitTime=t-n.pageVisitStartTime,io.removeSessionStorage(this._logger,this.prevPageVisitDataKeyName),n}return null}return null}catch(t){return this._logger.warnToConsole("Stop page visit timer failed: "+io.dump(t)),null}},t}(),Mo=function(t,e){this.pageVisitStartTime=nr.dateNow(),this.pageName=t,this.pageUrl=e},Ro=function(){function t(t){this.MAX_DURATION_ALLOWED=36e5,t&&(this._logger=t.logger)}return t.prototype.populatePageViewPerformanceEvent=function(t){t.isValid=!1;var e=this.getPerformanceNavigationTiming(),n=this.getPerformanceTiming();if(e||n){if(e)var i=e.duration,r=ao.GetDuration(e.startTime,e.connectEnd),o=ao.GetDuration(e.requestStart,e.responseStart),s=ao.GetDuration(e.responseStart,e.responseEnd),a=ao.GetDuration(e.responseEnd,e.loadEventEnd);else i=ao.GetDuration(n.navigationStart,n.loadEventEnd),r=ao.GetDuration(n.navigationStart,n.connectEnd),o=ao.GetDuration(n.requestStart,n.responseStart),s=ao.GetDuration(n.responseStart,n.responseEnd),a=ao.GetDuration(n.responseEnd,n.loadEventEnd);0===i?this._logger.throwInternal(er.WARNING,10,"error calculating page view performance.",{total:i,network:r,request:o,response:s,dom:a}):this.shouldCollectDuration(i,r,o,s,a)?i<Math.floor(r)+Math.floor(o)+Math.floor(s)+Math.floor(a)?this._logger.throwInternal(er.WARNING,8,"client performance math error.",{total:i,network:r,request:o,response:s,dom:a}):(t.durationMs=i,t.perfTotal=t.duration=io.msToTimeSpan(i),t.networkConnect=io.msToTimeSpan(r),t.sentRequest=io.msToTimeSpan(o),t.receivedResponse=io.msToTimeSpan(s),t.domProcessing=io.msToTimeSpan(a),t.isValid=!0):this._logger.throwInternal(er.WARNING,45,"Invalid page load duration value. Browser perf data won't be sent.",{total:i,network:r,request:o,response:s,dom:a})}},t.prototype.getPerformanceTiming=function(){return this.isPerformanceTimingSupported()?Ni().timing:null},t.prototype.getPerformanceNavigationTiming=function(){return this.isPerformanceNavigationTimingSupported()?Ni().getEntriesByType("navigation")[0]:null},t.prototype.isPerformanceNavigationTimingSupported=function(){var t=Ni();return t&&t.getEntriesByType&&t.getEntriesByType("navigation").length>0},t.prototype.isPerformanceTimingSupported=function(){var t=Ni();return t&&t.timing},t.prototype.isPerformanceTimingDataReady=function(){var t=Ni(),e=t?t.timing:0;return e&&e.domainLookupStart>0&&e.navigationStart>0&&e.responseStart>0&&e.requestStart>0&&e.loadEventEnd>0&&e.responseEnd>0&&e.connectEnd>0&&e.domLoading>0},t.prototype.shouldCollectDuration=function(){for(var t=[],e=0;e<arguments.length;e++)t[e]=arguments[e];var n=Mi()||{},i=["googlebot","adsbot-google","apis-google","mediapartners-google"],r=n.userAgent,o=!1;if(r)for(var s=0;s<i.length;s++)o=o||-1!==r.toLowerCase().indexOf(i[s]);if(o)return!1;for(s=0;s<t.length;s++)if(t[s]<0||t[s]>=this.MAX_DURATION_ALLOWED)return!1;return!0},t}();function No(t,e){t&&t.dispatchEvent&&e&&t.dispatchEvent(e)}var Do=function(t){function e(){var e=t.call(this)||this;e.identifier="ApplicationInsightsAnalytics",e.priority=180,e.autoRoutePVDelay=500,e._trackAjaxAttempts=0;var n=Ri();return e._prevUri=n&&n.href||"",e}return __extends(e,t),e.getDefaultConfig=function(t){return t||(t={}),t.sessionRenewalMs=18e5,t.sessionExpirationMs=864e5,t.disableExceptionTracking=io.stringToBoolOrDefault(t.disableExceptionTracking),t.autoTrackPageVisitTime=io.stringToBoolOrDefault(t.autoTrackPageVisitTime),t.overridePageViewDuration=io.stringToBoolOrDefault(t.overridePageViewDuration),t.enableUnhandledPromiseRejectionTracking=io.stringToBoolOrDefault(t.enableUnhandledPromiseRejectionTracking),(isNaN(t.samplingPercentage)||t.samplingPercentage<=0||t.samplingPercentage>=100)&&(t.samplingPercentage=100),t.isCookieUseDisabled=io.stringToBoolOrDefault(t.isCookieUseDisabled),t.isStorageUseDisabled=io.stringToBoolOrDefault(t.isStorageUseDisabled),t.isBrowserLinkTrackingEnabled=io.stringToBoolOrDefault(t.isBrowserLinkTrackingEnabled),t.enableAutoRouteTracking=io.stringToBoolOrDefault(t.enableAutoRouteTracking),t.namePrefix=t.namePrefix||"",t},e.prototype.processTelemetry=function(t,e){var n=this;Cr(this.core,(function(){return n.identifier+":processTelemetry"}),(function(){var i=!1,r=n._telemetryInitializers.length;e=n._getTelCtx(e);for(var o=0;o<r;++o){var s=n._telemetryInitializers[o];if(s)try{if(!1===s.apply(null,[t])){i=!0;break}}catch(t){e.diagLog().throwInternal(er.CRITICAL,64,"One of telemetry initializers failed, telemetry item will not be sent: "+io.getExceptionName(t),{exception:io.dump(t)},!0)}}i||n.processNext(t,e)}),(function(){return{item:t}}),!t.sync)},e.prototype.trackEvent=function(t,e){try{var n=Eo.create(t,mo.dataType,mo.envelopeType,this.diagLog(),e);this.core.track(n)}catch(t){this.diagLog().throwInternal(er.WARNING,39,"trackTrace failed, trace will not be collected: "+io.getExceptionName(t),{exception:io.dump(t)})}},e.prototype.startTrackEvent=function(t){try{this._eventTracking.start(t)}catch(t){this.diagLog().throwInternal(er.CRITICAL,29,"startTrackEvent failed, event will not be collected: "+io.getExceptionName(t),{exception:io.dump(t)})}},e.prototype.stopTrackEvent=function(t,e){try{this._eventTracking.stop(t,void 0,e)}catch(t){this.diagLog().throwInternal(er.CRITICAL,30,"stopTrackEvent failed, event will not be collected: "+io.getExceptionName(t),{exception:io.dump(t)})}},e.prototype.trackTrace=function(t,e){try{var n=Eo.create(t,Ao.dataType,Ao.envelopeType,this.diagLog(),e);this.core.track(n)}catch(t){this.diagLog().throwInternal(er.WARNING,39,"trackTrace failed, trace will not be collected: "+io.getExceptionName(t),{exception:io.dump(t)})}},e.prototype.trackMetric=function(t,e){try{var n=Eo.create(t,ko.dataType,ko.envelopeType,this.diagLog(),e);this.core.track(n)}catch(t){this.diagLog().throwInternal(er.CRITICAL,36,"trackMetric failed, metric will not be collected: "+io.getExceptionName(t),{exception:io.dump(t)})}},e.prototype.trackPageView=function(t,e){try{var n=t||{};this._pageViewManager.trackPageView(n,__assign({},n.properties,n.measurements,e)),this.config.autoTrackPageVisitTime&&this._pageVisitTimeManager.trackPreviousPageVisit(n.name,n.uri)}catch(t){this.diagLog().throwInternal(er.CRITICAL,37,"trackPageView failed, page view will not be collected: "+io.getExceptionName(t),{exception:io.dump(t)})}},e.prototype.sendPageViewInternal=function(t,e,n){var i=Ti();i&&(t.refUri=void 0===t.refUri?i.referrer:t.refUri);var r=Eo.create(t,Co.dataType,Co.envelopeType,this.diagLog(),e,n);this.core.track(r),this._trackAjaxAttempts=0},e.prototype.sendPageViewPerformanceInternal=function(t,e,n){var i=Eo.create(t,qo.dataType,qo.envelopeType,this.diagLog(),e,n);this.core.track(i)},e.prototype.trackPageViewPerformance=function(t,e){try{this._pageViewPerformanceManager.populatePageViewPerformanceEvent(t),this.sendPageViewPerformanceInternal(t,e)}catch(t){this.diagLog().throwInternal(er.CRITICAL,37,"trackPageViewPerformance failed, page view will not be collected: "+io.getExceptionName(t),{exception:io.dump(t)})}},e.prototype.startTrackPage=function(t){try{if("string"!=typeof t){var e=Ti();t=e&&e.title||""}this._pageTracking.start(t)}catch(t){this.diagLog().throwInternal(er.CRITICAL,31,"startTrackPage failed, page view may not be collected: "+io.getExceptionName(t),{exception:io.dump(t)})}},e.prototype.stopTrackPage=function(t,e,n,i){try{if("string"!=typeof t){var r=Ti();t=r&&r.title||""}if("string"!=typeof e){var o=Ri();e=o&&o.href||""}this._pageTracking.stop(t,e,n,i),this.config.autoTrackPageVisitTime&&this._pageVisitTimeManager.trackPreviousPageVisit(t,e)}catch(t){this.diagLog().throwInternal(er.CRITICAL,32,"stopTrackPage failed, page view will not be collected: "+io.getExceptionName(t),{exception:io.dump(t)})}},e.prototype.sendExceptionInternal=function(t,e,n){var i=new vo(this.diagLog(),t.exception||new Error(io.NotSpecified),t.properties,t.measurements,t.severityLevel,t.id).toInterface(),r=Eo.create(i,vo.dataType,vo.envelopeType,this.diagLog(),e,n);this.core.track(r)},e.prototype.trackException=function(t,e){try{this.sendExceptionInternal(t,e)}catch(t){this.diagLog().throwInternal(er.CRITICAL,35,"trackException failed, exception will not be collected: "+io.getExceptionName(t),{exception:io.dump(t)})}},e.prototype._onerror=function(t){try{var e={url:t&&t.url||(Ti()||{}).URL,lineNumber:t.lineNumber,columnNumber:t.columnNumber,message:t.message};if(io.isCrossOriginError(t.message,t.url,t.lineNumber,t.columnNumber,t.error))this._sendCORSException(e.url);else{if(!io.isError(t.error)){var n="window.onerror@"+e.url+":"+t.lineNumber+":"+(t.columnNumber||0);t.error=new Error(t.message),t.error.stack=n}this.trackException({exception:t.error,severityLevel:yo.Error},e)}}catch(e){var i=t.error?t.error.name+", "+t.error.message:"null";this.diagLog().throwInternal(er.CRITICAL,11,"_onError threw exception while logging error, error will not be collected: "+io.getExceptionName(e),{exception:io.dump(e),errorString:i})}},e.prototype.addTelemetryInitializer=function(t){this._telemetryInitializers.push(t)},e.prototype.initialize=function(n,i,r,o){var s=this;if(!this.isInitialized()){if(nr.isNullOrUndefined(i))throw Error("Error initializing");t.prototype.initialize.call(this,n,i,r,o),this.setInitialized(!1);var a=this._getTelCtx(),c=this.identifier;this._globalconfig={instrumentationKey:n.instrumentationKey,endpointUrl:n.endpointUrl||"https://dc.services.visualstudio.com/v2/track"},this.config=a.getExtCfg(c);var u=e.getDefaultConfig();void 0!==u&&(tr(u,(function(t,e){s.config[t]=a.getConfig(c,t,e)})),this._globalconfig&&tr(u,(function(t,e){void 0===s._globalconfig[t]&&(s._globalconfig[t]=e)}))),this.config.isCookieUseDisabled&&io.disableCookies(),this.config.isStorageUseDisabled&&io.disableStorage();var l={instrumentationKey:function(){return n.instrumentationKey},accountId:function(){return s.config.accountId||n.accountId},sessionRenewalMs:function(){return s.config.sessionRenewalMs||n.sessionRenewalMs},sessionExpirationMs:function(){return s.config.sessionExpirationMs||n.sessionExpirationMs},sampleRate:function(){return s.config.samplingPercentage||n.samplingPercentage},cookieDomain:function(){return s.config.cookieDomain||n.cookieDomain},sdkExtension:function(){return s.config.sdkExtension||n.sdkExtension},isBrowserLinkTrackingEnabled:function(){return s.config.isBrowserLinkTrackingEnabled||n.isBrowserLinkTrackingEnabled},appId:function(){return s.config.appId||n.appId}};this._pageViewPerformanceManager=new Ro(this.core),this._pageViewManager=new Po(this,this.config.overridePageViewDuration,this.core,this._pageViewPerformanceManager),this._pageVisitTimeManager=new To(this.diagLog(),(function(t,e,n){return s.trackPageVisitTime(t,e,n)})),this._telemetryInitializers=this._telemetryInitializers||[],this._addDefaultTelemetryInitializers(l),this._eventTracking=new Oo(this.diagLog(),"trackEvent"),this._eventTracking.action=function(t,e,n,i){i||(i={}),i.duration=n.toString(),s.trackEvent({name:t,properties:i})},this._pageTracking=new Oo(this.diagLog(),"trackPageView"),this._pageTracking.action=function(t,e,n,i,r){nr.isNullOrUndefined(i)&&(i={}),i.duration=n.toString(),s.sendPageViewInternal({name:t,uri:e,properties:i,measurements:r},i)};var f,d=Fi(),h=Boolean("object"==typeof history&&history)?history:Ei("history"),p=Ri(),m=this;if(!1===this.config.disableExceptionTracking&&!this.config.autoExceptionInstrumented&&d){var v=d.onerror;d.onerror=function(t,e,n,i,r){var o=v&&v(t,e,n,i,r);return!0!==o&&m._onerror({message:t,url:e,lineNumber:n,columnNumber:i,error:r}),o},this.config.autoExceptionInstrumented=!0}if(!1===this.config.disableExceptionTracking&&!0===this.config.enableUnhandledPromiseRejectionTracking&&!this.config.autoUnhandledPromiseInstrumented&&d){var b=d.onunhandledrejection;d.onunhandledrejection=function(t){var e=b&&b.call(d,t);return!0!==e&&m._onerror({message:t.reason.toString(),error:t.reason instanceof Error?t.reason:new Error(t.reason.toString()),url:p?p.href:"",lineNumber:0,columnNumber:0}),e},this.config.autoUnhandledPromiseInstrumented=!0}if(!0===this.config.enableAutoRouteTracking&&h&&nr.isFunction(h.pushState)&&nr.isFunction(h.replaceState)&&d&&"undefined"!=typeof Event){var g=this;nr.arrForEach(r,(function(t){"AppInsightsPropertiesPlugin"===t.identifier&&(s._properties=t)})),h.pushState=(f=h.pushState,function(){var t=f.apply(this,arguments);return No(d,io.createDomEvent(g.config.namePrefix+"pushState")),No(d,io.createDomEvent(g.config.namePrefix+"locationchange")),t}),h.replaceState=function(t){return function(){var e=t.apply(this,arguments);return No(d,io.createDomEvent(g.config.namePrefix+"replaceState")),No(d,io.createDomEvent(g.config.namePrefix+"locationchange")),e}}(h.replaceState),d.addEventListener&&(d.addEventListener(g.config.namePrefix+"popstate",(function(){No(d,io.createDomEvent(g.config.namePrefix+"locationchange"))})),d.addEventListener(g.config.namePrefix+"locationchange",(function(){g._properties&&g._properties.context&&g._properties.context.telemetryTrace&&(g._properties.context.telemetryTrace.traceID=io.generateW3CId(),g._properties.context.telemetryTrace.name=p&&p.pathname||"_unknown_"),s._currUri?(s._prevUri=s._currUri,s._currUri=p&&p.href||""):s._currUri=p&&p.href||"",setTimeout(function(t){g.trackPageView({refUri:t,properties:{duration:0}})}.bind(s,s._prevUri),g.autoRoutePVDelay)})))}this.setInitialized(!0)}},e.prototype.trackPageVisitTime=function(t,e,n){this.trackMetric({name:"PageVisitTime",average:n,max:n,min:n,sampleCount:1},{PageName:t,PageUrl:e})},e.prototype._addDefaultTelemetryInitializers=function(t){if(!t.isBrowserLinkTrackingEnabled()){var e=["/browserLinkSignalR/","/__browserLink/"];this._addTelemetryInitializer((function(t){if(t.baseType===_o.dataType){var n=t.baseData;if(n)for(var i=0;i<e.length;i++)if(n.target&&n.target.indexOf(e[i])>=0)return!1}return!0}))}},e.prototype._addTelemetryInitializer=function(t){this._telemetryInitializers.push(t)},e.prototype._sendCORSException=function(t){var e=Eo.create({message:"Script error: The browser's same-origin policy prevents us from getting the details of this exception. Consider using the 'crossorigin' attribute.",url:t,lineNumber:0,columnNumber:0,error:void 0},vo.dataType,vo.envelopeType,this.diagLog(),{url:t});this.core.track(e)},e.Version="2.5.10",e}(Ir),Oo=function(){function t(t,e){this._name=e,this._events={},this._logger=t}return t.prototype.start=function(t){void 0!==this._events[t]&&this._logger.throwInternal(er.WARNING,62,"start was called more than once for this event without calling stop.",{name:this._name,key:t},!0),this._events[t]=+new Date},t.prototype.stop=function(t,e,n,i){var r=this._events[t];if(isNaN(r))this._logger.throwInternal(er.WARNING,63,"stop was called without a corresponding start.",{name:this._name,key:t},!0);else{var o=+new Date,s=ao.GetDuration(r,o);this.action(t,e,s,n,i)}delete this._events[t],this._events[t]=void 0},t}(),Uo=function t(e){var n=[];gr(t,this,(function(t){t.enqueue=function(t){n.push(t)},t.count=function(){return n.length},t.clear=function(){n.length=0},t.getItems=function(){return n.slice(0)},t.batchPayloads=function(t){return t&&t.length>0?e.emitLineDelimitedJson()?t.join("\n"):"["+t.join(",")+"]":null},t.markAsSent=function(){t.clear()},t.clearSent=function(){}}))},Lo=function(){function t(e,n){var i,r=!1;gr(t,this,(function(o){var s=u(t.BUFFER_KEY),a=u(t.SENT_BUFFER_KEY);function c(t,e){var n=[];return nr.arrForEach(e,(function(e){nr.isFunction(e)||-1!==nr.arrIndexOf(t,e)||n.push(e)})),n}function u(t){var i=t;try{i=n.namePrefix&&n.namePrefix()?n.namePrefix()+"_"+i:i;var r=io.getSessionStorage(e,i);if(r){var o=Oi().parse(r);if(nr.isString(o)&&(o=Oi().parse(o)),o&&io.isArray(o))return o}}catch(t){e.throwInternal(er.CRITICAL,42," storage key: "+i+", "+io.getExceptionName(t),{exception:io.dump(t)})}return[]}function l(t,i){var r=t;try{r=n.namePrefix&&n.namePrefix()?n.namePrefix()+"_"+r:r;var o=JSON.stringify(i);io.setSessionStorage(e,r,o)}catch(t){io.setSessionStorage(e,r,JSON.stringify([])),e.throwInternal(er.WARNING,41," storage key: "+r+", "+io.getExceptionName(t)+". Buffer cleared",{exception:io.dump(t)})}}(i=s.concat(a)).length>t.MAX_BUFFER_SIZE&&(i.length=t.MAX_BUFFER_SIZE),l(t.SENT_BUFFER_KEY,[]),l(t.BUFFER_KEY,i),o.enqueue=function(n){i.length>=t.MAX_BUFFER_SIZE?r||(e.throwInternal(er.WARNING,67,"Maximum buffer size reached: "+i.length,!0),r=!0):(i.push(n),l(t.BUFFER_KEY,i))},o.count=function(){return i.length},o.clear=function(){i=[],l(t.BUFFER_KEY,[]),l(t.SENT_BUFFER_KEY,[]),r=!1},o.getItems=function(){return i.slice(0)},o.batchPayloads=function(t){return t&&t.length>0?n.emitLineDelimitedJson()?t.join("\n"):"["+t.join(",")+"]":null},o.markAsSent=function(n){i=c(n,i),l(t.BUFFER_KEY,i);var r=u(t.SENT_BUFFER_KEY);r instanceof Array&&n instanceof Array&&((r=r.concat(n)).length>t.MAX_BUFFER_SIZE&&(e.throwInternal(er.CRITICAL,67,"Sent buffer reached its maximum size: "+r.length,!0),r.length=t.MAX_BUFFER_SIZE),l(t.SENT_BUFFER_KEY,r))},o.clearSent=function(e){var n=u(t.SENT_BUFFER_KEY);n=c(e,n),l(t.SENT_BUFFER_KEY,n)}}))}return t.BUFFER_KEY="AI_buffer",t.SENT_BUFFER_KEY="AI_sentBuffer",t.MAX_BUFFER_SIZE=2e3,t}(),zo=nr.isNullOrUndefined;function Vo(t,e,n){return t&&n?(t[e]=n,t[e]):null}var Ho=function(){function t(){}return t.extractPropsAndMeasurements=function(t,e,n){zo(t)||tr(t,(function(t,i){nr.isNumber(i)?n[t]=i:nr.isString(i)?e[t]=i:Di()&&(e[t]=Oi().stringify(i))}))},t.createEnvelope=function(e,n,i,r){var o=new fo(e,r,n);Vo(o,"sampleRate",i.sampleRate),(i.baseData||{}).startTime&&(o.time=nr.toISOString(i.baseData.startTime)),o.iKey=i.iKey;var s=i.iKey.replace(/-/g,"");return o.name=o.name.replace("{0}",s),t.extractPartAExtensions(i,o),i.tags=i.tags||[],o},t.extractPartAExtensions=function(e,n){var i=n.tags=n.tags||{},r=e.ext=e.ext||{},o=e.tags=e.tags||[],s=r.user;s&&(Vo(i,Fo.userAuthUserId,s.authId),Vo(i,Fo.userId,s.id||s.localId));var a=r.app;a&&Vo(i,Fo.sessionId,a.sesId);var c=r.device;c&&(Vo(i,Fo.deviceId,c.id||c.localId),Vo(i,Fo.deviceType,c.deviceClass),Vo(i,Fo.deviceIp,c.ip),Vo(i,Fo.deviceModel,c.model),Vo(i,Fo.deviceType,c.deviceType));var u=e.ext.web;if(u){Vo(i,Fo.deviceLanguage,u.browserLang),Vo(i,Fo.deviceBrowserVersion,u.browserVer),Vo(i,Fo.deviceBrowser,u.browser);var l=n.data=n.data||{},f=l.baseData=l.baseData||{},d=f.properties=f.properties||{};Vo(d,"domain",u.domain),Vo(d,"isManual",u.isManual?"true":null),Vo(d,"screenRes",u.screenRes),Vo(d,"userConsent",u.userConsent?"true":null)}var h=r.os;h&&Vo(i,Fo.deviceOS,h.name);var p=r.trace;p&&(Vo(i,Fo.operationParentId,p.parentID),Vo(i,Fo.operationName,p.name),Vo(i,Fo.operationId,p.traceID));for(var m={},v=o.length-1;v>=0;v--)tr(o[v],(function(t,e){m[t]=e})),o.splice(v,1);tr(o,(function(t,e){m[t]=e})),n.tags=__assign({},i,m),n.tags[Fo.internalSdkVersion]||(n.tags[Fo.internalSdkVersion]="javascript:"+t.Version)},t.prototype.Init=function(t,e){this._logger=t,zo(e.baseData)&&this._logger.throwInternal(er.CRITICAL,46,"telemetryItem.baseData cannot be null.")},t.Version="2.5.10",t}(),Qo=function(t){function e(){return null!==t&&t.apply(this,arguments)||this}return __extends(e,t),e.prototype.Create=function(e,n){t.prototype.Init.call(this,e,n);var i=n.baseData.measurements||{},r=n.baseData.properties||{};Ho.extractPropsAndMeasurements(n.data,r,i);var o=n.baseData;if(zo(o))return e.warnToConsole("Invalid input for dependency data"),null;var s=new _o(e,o.id,o.target,o.name,o.duration,o.success,o.responseCode,o.properties&&o.properties["http.method"]?o.properties["http.method"]:"GET",o.type,o.correlationContext,r,i),a=new Bo(_o.dataType,s);return Ho.createEnvelope(e,_o.envelopeType,n,a)},e.DependencyEnvelopeCreator=new e,e}(Ho),Wo=function(t){function e(){return null!==t&&t.apply(this,arguments)||this}return __extends(e,t),e.prototype.Create=function(e,n){t.prototype.Init.call(this,e,n);var i={},r={};n.baseType!==mo.dataType&&(i.baseTypeSource=n.baseType),n.baseType===mo.dataType?(i=n.baseData.properties||{},r=n.baseData.measurements||{}):n.baseData&&Ho.extractPropsAndMeasurements(n.baseData,i,r),Ho.extractPropsAndMeasurements(n.data,i,r);var o=new mo(e,n.baseData.name,i,r),s=new Bo(mo.dataType,o);return Ho.createEnvelope(e,mo.envelopeType,n,s)},e.EventEnvelopeCreator=new e,e}(Ho),$o=function(t){function e(){return null!==t&&t.apply(this,arguments)||this}return __extends(e,t),e.prototype.Create=function(e,n){t.prototype.Init.call(this,e,n);var i=n.baseData.measurements||{},r=n.baseData.properties||{};Ho.extractPropsAndMeasurements(n.data,r,i);var o=vo.CreateFromInterface(e,n.baseData,r,i),s=new Bo(vo.dataType,o);return Ho.createEnvelope(e,vo.envelopeType,n,s)},e.ExceptionEnvelopeCreator=new e,e}(Ho),Yo=function(t){function e(){return null!==t&&t.apply(this,arguments)||this}return __extends(e,t),e.prototype.Create=function(e,n){t.prototype.Init.call(this,e,n);var i=n.baseData,r=i.properties||{},o=i.measurements||{};Ho.extractPropsAndMeasurements(n.data,r,o);var s=new ko(e,i.name,i.average,i.sampleCount,i.min,i.max,r,o),a=new Bo(ko.dataType,s);return Ho.createEnvelope(e,ko.envelopeType,n,a)},e.MetricEnvelopeCreator=new e,e}(Ho),Xo=function(t){function e(){return null!==t&&t.apply(this,arguments)||this}return __extends(e,t),e.prototype.Create=function(e,n){t.prototype.Init.call(this,e,n);var i,r=n.baseData;zo(r)||zo(r.properties)||zo(r.properties.duration)?zo(n.data)||zo(n.data.duration)||(i=n.data.duration,delete n.data.duration):(i=r.properties.duration,delete r.properties.duration);var o,s=n.baseData;((n.ext||{}).trace||{}).traceID&&(o=n.ext.trace.traceID);var a=s.id||o,c=s.name,u=s.uri,l=s.properties||{},f=s.measurements||{};zo(s.refUri)||(l.refUri=s.refUri),zo(s.pageType)||(l.pageType=s.pageType),zo(s.isLoggedIn)||(l.isLoggedIn=s.isLoggedIn.toString()),zo(s.properties)||tr(s.properties,(function(t,e){l[t]=e})),Ho.extractPropsAndMeasurements(n.data,l,f);var d=new Co(e,c,u,i,l,f,a),h=new Bo(Co.dataType,d);return Ho.createEnvelope(e,Co.envelopeType,n,h)},e.PageViewEnvelopeCreator=new e,e}(Ho),Jo=function(t){function e(){return null!==t&&t.apply(this,arguments)||this}return __extends(e,t),e.prototype.Create=function(e,n){t.prototype.Init.call(this,e,n);var i=n.baseData,r=i.name,o=i.uri||i.url,s=i.properties||{},a=i.measurements||{};Ho.extractPropsAndMeasurements(n.data,s,a);var c=new qo(e,r,o,void 0,s,a,i),u=new Bo(qo.dataType,c);return Ho.createEnvelope(e,qo.envelopeType,n,u)},e.PageViewPerformanceEnvelopeCreator=new e,e}(Ho),Go=function(t){function e(){return null!==t&&t.apply(this,arguments)||this}return __extends(e,t),e.prototype.Create=function(e,n){t.prototype.Init.call(this,e,n);var i=n.baseData.message,r=n.baseData.severityLevel,o=n.baseData.properties||{},s=n.baseData.measurements||{};Ho.extractPropsAndMeasurements(n.data,o,s);var a=new Ao(e,i,r,o,s),c=new Bo(Ao.dataType,a);return Ho.createEnvelope(e,Ao.envelopeType,n,c)},e.TraceEnvelopeCreator=new e,e}(Ho),Ko=function t(e){gr(t,this,(function(t){function n(t,o){var s={};if(!t)return e.throwInternal(er.CRITICAL,48,"cannot serialize object because it is null or undefined",{name:o},!0),s;if(t.__aiCircularRefCheck)return e.throwInternal(er.WARNING,50,"Circular reference detected while serializing object",{name:o},!0),s;if(!t.aiDataContract){if("measurements"===o)s=r(t,"number",o);else if("properties"===o)s=r(t,"string",o);else if("tags"===o)s=r(t,"string",o);else if(io.isArray(t))s=i(t,o);else{e.throwInternal(er.WARNING,49,"Attempting to serialize an object which does not implement ISerializable",{name:o},!0);try{Oi().stringify(t),s=t}catch(t){e.throwInternal(er.CRITICAL,48,t&&nr.isFunction(t.toString)?t.toString():"Error serializing object",null,!0)}}return s}return t.__aiCircularRefCheck=!0,tr(t.aiDataContract,(function(r,a){var c=nr.isFunction(a)?a()&Wr.Required:a&Wr.Required,u=nr.isFunction(a)?a()&Wr.Hidden:a&Wr.Hidden,l=a&Wr.Array,f=void 0!==t[r],d=nr.isObject(t[r])&&null!==t[r];if(!c||f||l){if(!u){var h;void 0!==(h=d?l?i(t[r],r):n(t[r],r):t[r])&&(s[r]=h)}}else e.throwInternal(er.CRITICAL,24,"Missing required field specification. The field is required but not present on source",{field:r,name:o})})),delete t.__aiCircularRefCheck,s}function i(t,i){var r;if(t)if(io.isArray(t)){r=[];for(var o=0;o<t.length;o++){var s=n(t[o],i+"["+o+"]");r.push(s)}}else e.throwInternal(er.CRITICAL,54,"This field was specified as an array in the contract but the item is not an array.\r\n",{name:i},!0);return r}function r(t,n,i){var r;return t&&(r={},tr(t,(function(t,o){if("string"===n)r[t]=void 0===o?"undefined":null===o?"null":o.toString?o.toString():"invalid field: toString() is not defined.";else if("number"===n)if(void 0===o)r[t]="undefined";else if(null===o)r[t]="null";else{var s=parseFloat(o);r[t]=isNaN(s)?"NaN":s}else r[t]="invalid field: "+i+" is of unknown type.",e.throwInternal(er.CRITICAL,r[t],null,!0)}))),r}t.serialize=function(t){var i=n(t,"root");try{return Oi().stringify(i)}catch(t){e.throwInternal(er.CRITICAL,48,t&&nr.isFunction(t.toString)?t.toString():"Error serializing object",null,!0)}}}))},Zo=function(){function t(){var e=Fi(),n=Ti(),i=!1,r=!0;gr(t,this,(function(t){try{if(e&&rr.Attach(e,"online",s)&&(rr.Attach(e,"offline",a),i=!0),n){var o=n.body||n;nr.isUndefined(o.ononline)||(o.ononline=s,o.onoffline=a,i=!0)}}catch(t){i=!1}function s(){r=!0}function a(){r=!1}t.isListening=i,t.isOnline=function(){var t=!0,e=Mi();return i?t=r:e&&!nr.isNullOrUndefined(e.onLine)&&(t=e.onLine),t},t.isOffline=function(){return!t.isOnline()}}))}return t.Offline=new t,t}().Offline,ts=function(){function t(){}return t.prototype.getHashCodeScore=function(e){return this.getHashCode(e)/t.INT_MAX_VALUE*100},t.prototype.getHashCode=function(e){if(""===e)return 0;for(;e.length<t.MIN_INPUT_LENGTH;)e=e.concat(e);for(var n=5381,i=0;i<e.length;++i)n=(n<<5)+n+e.charCodeAt(i),n&=n;return Math.abs(n)},t.INT_MAX_VALUE=2147483647,t.MIN_INPUT_LENGTH=8,t}(),es=function(){function t(){this.hashCodeGeneragor=new ts,this.keys=new jo}return t.prototype.getSamplingScore=function(t){return t.tags&&t.tags[this.keys.userId]?this.hashCodeGeneragor.getHashCodeScore(t.tags[this.keys.userId]):t.ext&&t.ext.user&&t.ext.user.id?this.hashCodeGeneragor.getHashCodeScore(t.ext.user.id):t.tags&&t.tags[this.keys.operationId]?this.hashCodeGeneragor.getHashCodeScore(t.tags[this.keys.operationId]):t.ext&&t.ext.telemetryTrace&&t.ext.telemetryTrace.traceID?this.hashCodeGeneragor.getHashCodeScore(t.ext.telemetryTrace.traceID):100*Math.random()},t}(),ns=function(){function t(t,e){this.INT_MAX_VALUE=2147483647,this._logger=nr.isNullOrUndefined(e)?new xr:e,(t>100||t<0)&&(this._logger.throwInternal(er.WARNING,58,"Sampling rate is out of range (0..100). Sampling will be disabled, you may be sending too much data which may affect your AI service level.",{samplingRate:t},!0),this.sampleRate=100),this.sampleRate=t,this.samplingScoreGenerator=new es}return t.prototype.isSampledIn=function(t){var e=this.sampleRate;return null==e||e>=100||t.baseType===ko.dataType||this.samplingScoreGenerator.getSamplingScore(t)<e},t}();
6
6
  /*!
7
7
  * Application Insights JavaScript SDK - Channel, 2.5.10
8
8
  * Copyright (c) Microsoft and contributors. All rights reserved.
9
9
  */
10
- function is(t){try{return t.responseText}catch(t){}return null}var rs=function(t){function e(){var n,i,r,o,s=t.call(this)||this;return s.priority=1001,s.identifier="AppInsightsChannelPlugin",s._XMLHttpRequestSupported=!1,gr(e,s,(function(t,a){function c(){throw new Error("Method not implemented.")}function u(e){var n=t._senderConfig.endpointUrl(),i=t._buffer.batchPayloads(e),r=new Blob([i],{type:"text/plain;charset=UTF-8"});Mi().sendBeacon(n,r)?(t._buffer.markAsSent(e),t._onSuccess(e,e.length)):(l(e,!0),t.diagLog().throwInternal(er.WARNING,40,". Failed to send telemetry with Beacon API, retried with xhrSender."))}function l(e,n){var i=new XMLHttpRequest,r=t._senderConfig.endpointUrl();try{i[co]=!0}catch(t){}i.open("POST",r,n),i.setRequestHeader("Content-type","application/json"),io.isInternalApplicationInsightsEndpoint(r)&&i.setRequestHeader(Kr.sdkContextHeader,Kr.sdkContextHeaderAppIdRequest),i.onreadystatechange=function(){return t._xhrReadyStateChange(i,e,e.length)},i.onerror=function(n){return t._onError(e,m(i),n)};var o=t._buffer.batchPayloads(e);i.send(o),t._buffer.markAsSent(e)}function f(e){try{if(e&&""!==e){var n=Oi().parse(e);if(n&&n.itemsReceived&&n.itemsReceived>=n.itemsAccepted&&n.itemsReceived-n.itemsAccepted===n.errors.length)return n}}catch(n){t.diagLog().throwInternal(er.CRITICAL,43,"Cannot parse the response. "+io.getExceptionName(n),{response:e})}return null}function d(e,r){if(void 0===r&&(r=1),e&&0!==e.length){t._buffer.clearSent(e),n++;for(var o=0,s=e;o<s.length;o++)t._buffer.enqueue(s[o]);!function(t){var e;if(n<=1)e=10;else{var r=(Math.pow(2,n)-1)/2,o=Math.floor(Math.random()*r*10)+1;e=Math.max(Math.min(o*=t,3600),10)}var s=nr.dateNow()+1e3*e;i=s}(r),h()}}function h(){if(!r){var e=i?Math.max(0,i-nr.dateNow()):0,n=Math.max(t._senderConfig.maxBatchInterval(),e);r=setTimeout((function(){t.triggerSend(!0,null,1)}),n)}}function p(t){return 408===t||429===t||500===t||503===t}function m(t,e){return t?"XMLHttpRequest,Status:"+t.status+",Response:"+is(t)||t.response||"":e}function v(e){var n=Fi(),i=new XDomainRequest;i.onload=function(){return t._xdrOnLoad(i,e)},i.onerror=function(n){return t._onError(e,b(i),n)};var r=n&&n.location&&n.location.protocol||"";if(0!==t._senderConfig.endpointUrl().lastIndexOf(r,0))return t.diagLog().throwInternal(er.WARNING,40,". Cannot send XDomain request. The endpoint URL protocol doesn't match the hosting page protocol."),void t._buffer.clear();var o=t._senderConfig.endpointUrl().replace(/^(https?:)/,"");i.open("POST",o);var s=t._buffer.batchPayloads(e);i.send(s),t._buffer.markAsSent(e)}function b(t,e){return t?"XDomainRequest,Response:"+is(t)||"":e}t.pause=c,t.resume=c,t.flush=function(){try{t.triggerSend(!0,null,1)}catch(e){t.diagLog().throwInternal(er.CRITICAL,22,"flush failed, telemetry will not be collected: "+io.getExceptionName(e),{exception:io.dump(e)})}},t.onunloadFlush=function(){if(!1!==t._senderConfig.onunloadDisableBeacon()&&!1!==t._senderConfig.isBeaconApiDisabled()||!io.IsBeaconApiSupported())t.flush();else try{t.triggerSend(!0,u,2)}catch(e){t.diagLog().throwInternal(er.CRITICAL,20,"failed to flush with beacon sender on page unload, telemetry will not be collected: "+io.getExceptionName(e),{exception:io.dump(e)})}},t.teardown=c,t.initialize=function(r,s,c,f){a.initialize(r,s,c,f);var d=t._getTelCtx(),h=t.identifier;o=new Ko(s.logger),n=0,i=null,t._sender=null;var p=e._getDefaultAppInsightsChannelConfig();if(t._senderConfig=e._getEmptyAppInsightsChannelConfig(),tr(p,(function(e,n){t._senderConfig[e]=function(){return d.getConfig(h,e,n())}})),t._buffer=t._senderConfig.enableSessionStorageBuffer()&&io.canUseSessionStorage()?new Lo(t.diagLog(),t._senderConfig):new Uo(t._senderConfig),t._sample=new ns(t._senderConfig.samplingPercentage(),t.diagLog()),function(t){return!(nr.isNullOrUndefined(t.disableInstrumentaionKeyValidation)||!t.disableInstrumentaionKeyValidation)||new RegExp("^[0-9a-f]{8}-[0-9a-f]{4}-[0-9a-f]{4}-[0-9a-f]{4}-[0-9a-f]{12}$").test(t.instrumentationKey)}(r)||t.diagLog().throwInternal(er.CRITICAL,100,"Invalid Instrumentation key "+r.instrumentationKey),!t._senderConfig.isBeaconApiDisabled()&&io.IsBeaconApiSupported())t._sender=u;else if(void 0!==typeof XMLHttpRequest){var m=Ei("XMLHttpRequest");m&&("withCredentials"in new m?(t._sender=l,t._XMLHttpRequestSupported=!0):void 0!==typeof XDomainRequest&&(t._sender=v))}},t.processTelemetry=function(n,i){i=t._getTelCtx(i);try{if(t._senderConfig.disableTelemetry())return;if(!n)return void i.diagLog().throwInternal(er.CRITICAL,7,"Cannot send empty telemetry");if(n.baseData&&!n.baseType)return void i.diagLog().throwInternal(er.CRITICAL,70,"Cannot send telemetry without baseData and baseType");if(n.baseType||(n.baseType="EventData"),!t._sender)return void i.diagLog().throwInternal(er.CRITICAL,28,"Sender was not initialized");if(!t._sample.isSampledIn(n))return void i.diagLog().throwInternal(er.WARNING,33,"Telemetry item was sampled out and not sent",{SampleRate:t._sample.sampleRate});n.sampleRate=t._sample.sampleRate;var r=e.constructEnvelope(n,t._senderConfig.instrumentationKey(),i.diagLog());if(!r)return void i.diagLog().throwInternal(er.CRITICAL,47,"Unable to create an AppInsights envelope");var s=!1;if(n.tags&&n.tags.ProcessLegacy&&(nr.arrForEach(n.tags.ProcessLegacy,(function(t){try{t&&!1===t(r)&&(s=!0,i.diagLog().warnToConsole("Telemetry processor check returns false"))}catch(t){i.diagLog().throwInternal(er.CRITICAL,64,"One of telemetry initializers failed, telemetry item will not be sent: "+io.getExceptionName(t),{exception:io.dump(t)},!0)}})),delete n.tags.ProcessLegacy),s)return;var a=o.serialize(r),c=t._buffer.getItems(),u=t._buffer.batchPayloads(c);u&&u.length+a.length>t._senderConfig.maxBatchSizeInBytes()&&t.triggerSend(!0,null,10),t._buffer.enqueue(a),h()}catch(t){i.diagLog().throwInternal(er.WARNING,12,"Failed adding telemetry to the sender's buffer, some telemetry will be lost: "+io.getExceptionName(t),{exception:io.dump(t)})}t.processNext(n,i)},t._xhrReadyStateChange=function(e,i,r){if(4===e.readyState){var o=null;t._appId||(o=f(is(e)||e.response))&&o.appId&&(t._appId=o.appId),(e.status<200||e.status>=300)&&0!==e.status?!t._senderConfig.isRetryDisabled()&&p(e.status)?(d(i),t.diagLog().throwInternal(er.WARNING,40,". Response code "+e.status+". Will retry to send "+i.length+" items.")):t._onError(i,m(e)):Zo.isOffline()?t._senderConfig.isRetryDisabled()||(d(i,10),t.diagLog().throwInternal(er.WARNING,40,". Offline - Response Code: "+e.status+". Offline status: "+Zo.isOffline()+". Will retry to send "+i.length+" items.")):206===e.status?(o||(o=f(is(e)||e.response)),o&&!t._senderConfig.isRetryDisabled()?t._onPartialSuccess(i,o):t._onError(i,m(e))):(n=0,t._onSuccess(i,r))}},t.triggerSend=function(e,n,o){void 0===e&&(e=!0);try{if(t._senderConfig.disableTelemetry())t._buffer.clear();else if(t._buffer.count()>0){var a=t._buffer.getItems();!function(e,n){var i,r=t.core[i="getNotifyMgr"]?t.core[i]():t.core._notificationManager;if(r&&r.eventsSendRequest)try{r.eventsSendRequest(e,n)}catch(e){t.diagLog().throwInternal(er.CRITICAL,74,"send request notification failed: "+io.getExceptionName(e),{exception:io.dump(e)})}}(o||0,e),n?n.call(s,a,e):t._sender(a,e)}clearTimeout(r),r=null,i=null}catch(e){var c=io.getIEVersion();(!c||c>9)&&t.diagLog().throwInternal(er.CRITICAL,40,"Telemetry transmission failed, some telemetry will be lost: "+io.getExceptionName(e),{exception:io.dump(e)})}},t._onError=function(e,n){t.diagLog().throwInternal(er.WARNING,26,"Failed to send telemetry.",{message:n}),t._buffer.clearSent(e)},t._onPartialSuccess=function(e,n){for(var i=[],r=[],o=0,s=n.errors.reverse();o<s.length;o++){var a=s[o],c=e.splice(a.index,1)[0];p(a.statusCode)?r.push(c):i.push(c)}e.length>0&&t._onSuccess(e,n.itemsAccepted),i.length>0&&t._onError(i,m(null,["partial success",n.itemsAccepted,"of",n.itemsReceived].join(" "))),r.length>0&&(d(r),t.diagLog().throwInternal(er.WARNING,40,"Partial success. Delivered: "+e.length+", Failed: "+i.length+". Will retry to send "+r.length+" our of "+n.itemsReceived+" items"))},t._onSuccess=function(e){t._buffer.clearSent(e)},t._xdrOnLoad=function(e,i){var r=is(e);if(!e||r+""!="200"&&""!==r){var o=f(r);o&&o.itemsReceived&&o.itemsReceived>o.itemsAccepted&&!t._senderConfig.isRetryDisabled()?t._onPartialSuccess(i,o):t._onError(i,b(e))}else n=0,t._onSuccess(i,0)}})),s}return __extends(e,t),e.constructEnvelope=function(t,e,n){var i;switch((i=e===t.iKey||nr.isNullOrUndefined(e)?t:__assign({},t,{iKey:e})).baseType){case mo.dataType:return Wo.EventEnvelopeCreator.Create(n,i);case Ao.dataType:return Go.TraceEnvelopeCreator.Create(n,i);case Co.dataType:return Xo.PageViewEnvelopeCreator.Create(n,i);case qo.dataType:return Jo.PageViewPerformanceEnvelopeCreator.Create(n,i);case vo.dataType:return $o.ExceptionEnvelopeCreator.Create(n,i);case ko.dataType:return Yo.MetricEnvelopeCreator.Create(n,i);case _o.dataType:return Qo.DependencyEnvelopeCreator.Create(n,i);default:return Wo.EventEnvelopeCreator.Create(n,i)}},e._getDefaultAppInsightsChannelConfig=function(){return{endpointUrl:function(){return"https://dc.services.visualstudio.com/v2/track"},emitLineDelimitedJson:function(){return!1},maxBatchInterval:function(){return 15e3},maxBatchSizeInBytes:function(){return 102400},disableTelemetry:function(){return!1},enableSessionStorageBuffer:function(){return!0},isRetryDisabled:function(){return!1},isBeaconApiDisabled:function(){return!0},onunloadDisableBeacon:function(){return!1},instrumentationKey:function(){},namePrefix:function(){},samplingPercentage:function(){return 100}}},e._getEmptyAppInsightsChannelConfig=function(){return{endpointUrl:void 0,emitLineDelimitedJson:void 0,maxBatchInterval:void 0,maxBatchSizeInBytes:void 0,disableTelemetry:void 0,enableSessionStorageBuffer:void 0,isRetryDisabled:void 0,isBeaconApiDisabled:void 0,onunloadDisableBeacon:void 0,instrumentationKey:void 0,namePrefix:void 0,samplingPercentage:void 0}},e}(Ir),os=function(){},ss=function(){function t(e,n){var i=this;this._logger=nr.isNullOrUndefined(n)?new xr:n,e||(e={}),"function"!=typeof e.sessionExpirationMs&&(e.sessionExpirationMs=function(){return t.acquisitionSpan}),"function"!=typeof e.sessionRenewalMs&&(e.sessionRenewalMs=function(){return t.renewalSpan}),this.config=e,this._storageNamePrefix=function(){return i.config.namePrefix&&i.config.namePrefix()?t.cookieNameConst+i.config.namePrefix():t.cookieNameConst},this.automaticSession=new os}return t.prototype.update=function(){this.automaticSession.id||this.initializeAutomaticSession();var e=(new Date).getTime(),n=0!==this.config.sessionExpirationMs()&&e-this.automaticSession.acquisitionDate>this.config.sessionExpirationMs(),i=0!==this.config.sessionExpirationMs()&&e-this.automaticSession.renewalDate>this.config.sessionRenewalMs();n||i?this.renew():(!this.cookieUpdatedTimestamp||e-this.cookieUpdatedTimestamp>t.cookieUpdateInterval)&&(this.automaticSession.renewalDate=e,this.setCookie(this.automaticSession.id,this.automaticSession.acquisitionDate,this.automaticSession.renewalDate))},t.prototype.backup=function(){this.setStorage(this.automaticSession.id,this.automaticSession.acquisitionDate,this.automaticSession.renewalDate)},t.prototype.initializeAutomaticSession=function(){var t=io.getCookie(this._logger,this._storageNamePrefix());if(t&&"function"==typeof t.split)this.initializeAutomaticSessionWithData(t);else{var e=io.getStorage(this._logger,this._storageNamePrefix());e&&this.initializeAutomaticSessionWithData(e)}this.automaticSession.id||this.renew()},t.prototype.initializeAutomaticSessionWithData=function(t){var e=t.split("|");e.length>0&&(this.automaticSession.id=e[0]);try{e.length>1&&(this.automaticSession.acquisitionDate=+new Date(+e[1]),this.automaticSession.acquisitionDate=this.automaticSession.acquisitionDate>0?this.automaticSession.acquisitionDate:0),e.length>2&&(this.automaticSession.renewalDate=+new Date(+e[2]),this.automaticSession.renewalDate=this.automaticSession.renewalDate>0?this.automaticSession.renewalDate:0)}catch(t){this._logger.throwInternal(er.CRITICAL,9,"Error parsing ai_session cookie, session will be reset: "+io.getExceptionName(t),{exception:io.dump(t)})}0===this.automaticSession.renewalDate&&this._logger.throwInternal(er.WARNING,27,"AI session renewal date is 0, session will be reset.")},t.prototype.renew=function(){var t=(new Date).getTime();this.automaticSession.id=io.newId(this.config&&this.config.idLength?this.config.idLength():22),this.automaticSession.acquisitionDate=t,this.automaticSession.renewalDate=t,this.setCookie(this.automaticSession.id,this.automaticSession.acquisitionDate,this.automaticSession.renewalDate),io.canUseLocalStorage()||this._logger.throwInternal(er.WARNING,0,"Browser does not support local storage. Session durations will be inaccurate.")},t.prototype.setCookie=function(t,e,n){var i=e+this.config.sessionExpirationMs(),r=n+this.config.sessionRenewalMs(),o=new Date,s=[t,e,n];o.setTime(i<r?i:r);var a=this.config.cookieDomain?this.config.cookieDomain():null,c=0===this.config.sessionExpirationMs()?"0":o.toUTCString();io.setCookie(this._logger,this._storageNamePrefix(),s.join("|")+";expires="+c,a),this.cookieUpdatedTimestamp=(new Date).getTime()},t.prototype.setStorage=function(t,e,n){io.setStorage(this._logger,this._storageNamePrefix(),[t,e,n].join("|"))},t.acquisitionSpan=864e5,t.renewalSpan=18e5,t.cookieUpdateInterval=6e4,t.cookieNameConst="ai_session",t}(),as=function(){},cs=function(){this.id="browser",this.deviceClass="Browser"},us=function(t){this.sdkVersion=(t.sdkExtension&&t.sdkExtension()?t.sdkExtension()+"_":"")+"javascript:2.5.10"},ls=function(){function t(e,n){this.isNewUser=!1,this._logger=n;var i=io.getCookie(this._logger,t.userCookieName);if(i){this.isNewUser=!1;var r=i.split(t.cookieSeparator);r.length>0&&(this.id=r[0])}if(this.config=e,!this.id){this.id=nr.newId(e&&e.idLength?e.idLength():22);var o=new Date,s=nr.toISOString(o);this.accountAcquisitionDate=s,this.isNewUser=!0,o.setTime(o.getTime()+31536e6);var a=[this.id,s],c=this.config.cookieDomain?this.config.cookieDomain():void 0;io.setCookie(this._logger,t.userCookieName,a.join(t.cookieSeparator)+";expires="+o.toUTCString(),c);var u=e.namePrefix&&e.namePrefix()?e.namePrefix()+"ai_session":"ai_session";io.removeStorage(this._logger,u)}this.accountId=e.accountId?e.accountId():void 0;var l=io.getCookie(this._logger,t.authUserCookieName);if(l){var f=(l=decodeURI(l)).split(t.cookieSeparator);f[0]&&(this.authenticatedId=f[0]),f.length>1&&f[1]&&(this.accountId=f[1])}}return t.prototype.setAuthenticatedUserContext=function(e,n,i){if(void 0===i&&(i=!1),!this.validateUserInput(e)||n&&!this.validateUserInput(n))this._logger.throwInternal(er.WARNING,60,"Setting auth user context failed. User auth/account id should be of type string, and not contain commas, semi-colons, equal signs, spaces, or vertical-bars.",!0);else{this.authenticatedId=e;var r=this.authenticatedId;n&&(this.accountId=n,r=[this.authenticatedId,this.accountId].join(t.cookieSeparator)),i&&io.setCookie(this._logger,t.authUserCookieName,encodeURI(r),this.config.cookieDomain())}},t.prototype.clearAuthenticatedUserContext=function(){this.authenticatedId=null,this.accountId=null,io.deleteCookie(this._logger,t.authUserCookieName)},t.prototype.validateUserInput=function(t){return!("string"!=typeof t||!t||t.match(/,|;|=| |\|/))},t.cookieSeparator="|",t.userCookieName="ai_user",t.authUserCookieName="ai_authUser",t}(),fs=function(){},ds=function(t,e,n,i){this.traceID=t||io.generateW3CId(),this.parentID=e,this.name=n;var r=Ti();!n&&r&&r.pathname&&(this.name=r.pathname),this.name=Zr.sanitizeString(i,this.name)},hs=function(){function t(t,e){var n=this;n.application=new as,n.internal=new us(e),Ii()&&(n.sessionManager=new ss(e,t),n.device=new cs,n.location=new fs,n.user=new ls(e,t),n.telemetryTrace=new ds(void 0,void 0,void 0,t),n.session=new os),n.appId=function(){return null}}return t.prototype.applySessionContext=function(t){var e=this.session,n=this.sessionManager,i=e||n&&n.automaticSession;i&&nr.isString(i.id)&&(t.ext.app.sesId=i.id),e&&(t.ext.app.sesId=nr.isString(e.id)?e.id:n.automaticSession.id)},t.prototype.applyOperatingSystemContxt=function(t){var e=this.os;e&&e.name&&(t.ext.os=e)},t.prototype.applyApplicationContext=function(t){var e=this.application;e&&(nr.isString(e.ver)&&(t.tags[Fo.applicationVersion]=e.ver),nr.isString(e.build)&&(t.tags[Fo.applicationBuild]=e.build))},t.prototype.applyDeviceContext=function(t){var e=this.device;e&&(nr.isString(e.id)&&(t.ext.device.localId=e.id),nr.isString(e.ip)&&(t.ext.device.ip=e.ip),nr.isString(e.model)&&(t.ext.device.model=e.model),nr.isString(e.deviceClass)&&(t.ext.device.deviceClass=e.deviceClass))},t.prototype.applyInternalContext=function(t){var e=this.internal;e&&(nr.isString(e.agentVersion)&&(t.tags[Fo.internalAgentVersion]=e.agentVersion),nr.isString(e.sdkVersion)&&(t.tags[Fo.internalSdkVersion]=e.sdkVersion),t.baseType!==yr.dataType&&t.baseType!==Co.dataType||(nr.isString(e.snippetVer)&&(t.tags[Fo.internalSnippet]=e.snippetVer),nr.isString(e.sdkSrc)&&(t.tags[Fo.internalSdkSrc]=e.sdkSrc)))},t.prototype.applyLocationContext=function(t){var e=this.location;e&&nr.isString(e.ip)&&(t.tags[Fo.locationIp]=e.ip)},t.prototype.applyOperationContext=function(t){var e=this.telemetryTrace;if(e){var n=t.ext.trace||{traceID:void 0,parentID:void 0};nr.isString(e.traceID)&&(n.traceID=e.traceID),nr.isString(e.name)&&(n.name=e.name),nr.isString(e.parentID)&&(n.parentID=e.parentID),t.ext.trace=n}},t.prototype.applyWebContext=function(t){var e=this.web;e&&(t.ext.web=t.ext.web||{},t.ext.web=e)},t.prototype.applyUserContext=function(t){var e=this.user;e&&(t.tags||(t.tags=[]),nr.isString(e.accountId)&&(t.tags[Fo.userAccountId]=e.accountId),nr.isString(e.id)&&(t.ext.user.id=e.id),nr.isString(e.authenticatedId)&&(t.ext.user.authId=e.authenticatedId))},t.prototype.cleanUp=function(t){t.ext[Io.DeviceExt]&&0===nr.objKeys(t.ext[Io.DeviceExt]).length&&delete t.ext[Io.DeviceExt],t.ext[Io.UserExt]&&0===nr.objKeys(t.ext[Io.UserExt]).length&&delete t.ext[Io.UserExt],t.ext[Io.WebExt]&&0===nr.objKeys(t.ext[Io.WebExt]).length&&delete t.ext[Io.WebExt],t.ext[Io.OSExt]&&0===nr.objKeys(t.ext[Io.OSExt]).length&&delete t.ext[Io.OSExt],t.ext[Io.AppExt]&&0===nr.objKeys(t.ext[Io.AppExt]).length&&delete t.ext[Io.AppExt],t.ext[Io.TraceExt]&&0===nr.objKeys(t.ext[Io.TraceExt]).length&&delete t.ext[Io.TraceExt]},t}(),ps=function(t){function e(){var e=null!==t&&t.apply(this,arguments)||this;return e.priority=110,e.identifier="AppInsightsPropertiesPlugin",e}return __extends(e,t),e.getDefaultConfig=function(){return{instrumentationKey:function(){},accountId:function(){return null},sessionRenewalMs:function(){return 18e5},samplingPercentage:function(){return 100},sessionExpirationMs:function(){return 864e5},cookieDomain:function(){return null},sdkExtension:function(){return null},isBrowserLinkTrackingEnabled:function(){return!1},appId:function(){return null},namePrefix:function(){},idLength:function(){return 22}}},e.prototype.initialize=function(n,i,r,o){var s=this;t.prototype.initialize.call(this,n,i,r,o);var a=this._getTelCtx(),c=this.identifier,u=e.getDefaultConfig();this._extensionConfig=this._extensionConfig||e.getDefaultConfig(),tr(u,(function(t,e){s._extensionConfig[t]=function(){return a.getConfig(c,t,e())}})),this.context=new hs(i.logger,this._extensionConfig),this._breezeChannel=io.getExtension(r,"AppInsightsChannelPlugin"),this.context.appId=function(){return s._breezeChannel?s._breezeChannel._appId:null}},e.prototype.processTelemetry=function(t,e){if(nr.isNullOrUndefined(t));else{if(e=this._getTelCtx(e),t.name===Co.envelopeType&&e.diagLog().resetInternalMessageCount(),this.context.session&&"string"!=typeof this.context.session.id&&this.context.sessionManager.update(),this._processTelemetryInternal(t,e),this.context&&this.context.user&&this.context.user.isNewUser){this.context.user.isNewUser=!1;var n=new yr(72,(Mi()||{}).userAgent||"");e.diagLog().logInternalMessage(er.CRITICAL,n)}this.processNext(t,e)}},e.prototype._processTelemetryInternal=function(t,e){t.tags||(t.tags=[]),t.ext||(t.ext={});var n=t.ext;n[Io.DeviceExt]=n[Io.DeviceExt]||{},n[Io.WebExt]=n[Io.WebExt]||{},n[Io.UserExt]=n[Io.UserExt]||{},n[Io.OSExt]=n[Io.OSExt]||{},n[Io.AppExt]=n[Io.AppExt]||{},n[Io.TraceExt]=n[Io.TraceExt]||{};var i=this.context;i.applySessionContext(t,e),i.applyApplicationContext(t,e),i.applyDeviceContext(t,e),i.applyOperationContext(t,e),i.applyUserContext(t,e),i.applyOperatingSystemContxt(t,e),i.applyWebContext(t,e),i.applyLocationContext(t,e),i.applyInternalContext(t,e),i.cleanUp(t,e)},e}(Ir),ms=nr.objKeys,vs=nr.arrForEach;function bs(t,e,n){var i=0,r=t[e],o=t[n];return r&&o&&(i=ao.GetDuration(r,o)),i}function gs(t,e,n,i,r){var o=0,s=bs(n,i,r);return s&&(o=ws(t,e,io.msToTimeSpan(s))),o}function ws(t,e,n){var i=0;return t&&e&&n&&((t.ajaxPerf=t.ajaxPerf||{})[e]=n,i=1),i}var ys=function(){var t=this;t.openDone=!1,t.setRequestHeaderDone=!1,t.sendDone=!1,t.abortDone=!1,t.stateChangeAttached=!1},xs=function t(e,n,i){var r=this,o=i;r.perfMark=null,r.completed=!1,r.requestHeadersSize=null,r.requestHeaders=null,r.responseReceivingDuration=null,r.callbackDuration=null,r.ajaxTotalDuration=null,r.aborted=0,r.pageUrl=null,r.requestUrl=null,r.requestSize=0,r.method=null,r.status=null,r.requestSentTime=null,r.responseStartedTime=null,r.responseFinishedTime=null,r.callbackFinishedTime=null,r.endTime=null,r.xhrMonitoringState=new ys,r.clientFailure=0,r.traceID=e,r.spanID=n,gr(t,r,(function(t){t.getAbsoluteUrl=function(){return t.requestUrl?ro.getAbsoluteUrl(t.requestUrl):null},t.getPathName=function(){return t.requestUrl?Zr.sanitizeUrl(o,ro.getCompleteUrl(t.method,t.requestUrl)):null},t.CreateTrackItem=function(e,n,i){if(t.ajaxTotalDuration=Math.round(1e3*ao.GetDuration(t.requestSentTime,t.responseFinishedTime))/1e3,t.ajaxTotalDuration<0)return null;var r,o=((r={id:"|"+t.traceID+"."+t.spanID,target:t.getAbsoluteUrl(),name:t.getPathName(),type:e,duration:t.ajaxTotalDuration,success:+t.status>=200&&+t.status<400,responseCode:+t.status,method:t.method}).properties={HttpMethod:t.method},r);if(function(t,e){var n=t.perfTiming,i=e.properties||{},r=0,o=nr.isString,s="redirect",a="startTime",c="connectEnd",u="requestStart",l="responseEnd",f=s+"Start",d=s="End";if(n){r|=gs(i,s,n,f,d),r|=gs(i,"domainLookup",n,"domainLookupStart","domainLookupEnd"),r|=gs(i,"connect",n,"connectStart",c),r|=gs(i,"request",n,u,"requestEnd"),r|=gs(i,"response",n,"responseStart",l),r|=gs(i,"networkConnect",n,a,c),r|=gs(i,"sentRequest",n,u,l);var h=n.duration;h||(h=bs(n,a,l)||0),r|=ws(i,"duration",h),r|=ws(i,"perfTotal",h);var p=n.serverTiming;if(p){var m={};vs(p,(function(t,e){var n=function(t){var e=t,n=/([^\w\d_$])/g;return n.test(t)&&(e=t.replace(n,"_")),e}(t.name||""+e),i=m[n]||{};tr(t,(function(t,e){("name"!==t&&o(e)||nr.isNumber(e))&&(i[t]&&(e=i[t]+";"+e),!e&&o(e)||(i[t]=e))})),m[n]=i})),r|=ws(i,"serverTiming",m)}r|=ws(i,"transferSize",n.transferSize),r|=ws(i,"encodedBodySize",n.encodedBodySize),r|=ws(i,"decodedBodySize",n.decodedBodySize)}else t.perfMark&&(r|=ws(i,"missing",t.perfAttempts));r&&(e.properties=i)}(t,o),n&&ms(t.requestHeaders).length>0&&(o.properties=o.properties||{},o.properties.requestHeaders=t.requestHeaders),i){var s=i();if(s){var a=s.correlationContext;if(a&&(o.correlationContext=a),s.headerMap&&ms(s.headerMap).length>0&&(o.properties=o.properties||{},o.properties.responseHeaders=s.headerMap),t.status>=400){var c=s.type;o.properties=o.properties||{},""!==c&&"text"!==c||(o.properties.responseText=s.responseText?s.statusText+" - "+s.responseText:s.statusText),"json"===c&&(o.properties.responseText=s.response?s.statusText+" - "+JSON.stringify(s.response):s.statusText)}}}return o}}))},ks=function(){function t(e,n){var i=this;i.traceFlag=t.DEFAULT_TRACE_FLAG,i.version=t.DEFAULT_VERSION,i.traceId=e&&t.isValidTraceId(e)?e:io.generateW3CId(),i.spanId=n&&t.isValidSpanId(n)?n:io.generateW3CId().substr(0,16)}return t.isValidTraceId=function(t){return t.match(/^[0-9a-f]{32}$/)&&"00000000000000000000000000000000"!==t},t.isValidSpanId=function(t){return t.match(/^[0-9a-f]{16}$/)&&"0000000000000000"!==t},t.prototype.toString=function(){var t=this;return t.version+"-"+t.traceId+"-"+t.spanId+"-"+t.traceFlag},t.DEFAULT_TRACE_FLAG="01",t.DEFAULT_VERSION="00",t}(),Ss=nr.isNullOrUndefined,Cs=nr.arrForEach,_s=0;function As(t){var e="";try{Ss(t)||Ss(t.ajaxData)||Ss(t.ajaxData.requestUrl)||(e+="(url: '"+t.ajaxData.requestUrl+"')")}catch(t){}return e}function qs(t,e,n,i,r){t.diagLog().throwInternal(er.CRITICAL,e,n,i,r)}function Bs(t,e,n,i,r){t.diagLog().throwInternal(er.WARNING,e,n,i,r)}function js(t,e,n){return function(i){qs(t,e,n,{ajaxDiagnosticsMessage:As(i.inst),exception:io.dump(i.err)})}}function Es(t,e){return t&&e?t.indexOf(e):-1}var Is,Fs=function(t){function e(){var n=t.call(this)||this;n.identifier=e.identifier,n.priority=120;var i,r,o,s,a=Ti(),c=!1,u=!1,l=a&&a.host&&a.host.toLowerCase(),f=e.getEmptyConfig(),d=!1,h=0,p=!1,m=0,v=!1,b=[],g={};return gr(e,n,(function(t,n){function a(t,e,n){b.push(function(t,e,n){return t?Jr(t.prototype,e,n,!1):null}(t,e,n))}function w(t,e,n){var i=!1,r=((nr.isString(e)?e:(e||{}).url||"")||"").toLowerCase(),o=Es(r,"?"),s=Es(r,"#");return(-1===o||-1!==s&&s<o)&&(o=s),-1!==o&&(r=r.substring(0,o)),Ss(t)?Ss(e)||(i="object"==typeof e&&!0===e[co]||!!n&&!0===n[co]):i=!0===t[co]||!0===r[co],i?g[r]||(g[r]=1):g[r]&&(i=!0),i}function y(t,e){var n=!0,i=u;return Ss(t)||(n=!0===e||!Ss(t.ajaxData)),i&&n}function x(t){try{var e=t.responseType;if(""===e||"text"===e)return t.responseText}catch(t){}return null}function k(e){try{var n=e.getAllResponseHeaders();if(null!==n&&-1!==Es(n.toLowerCase(),Kr.requestContextHeaderLowerCase)){var i=e.getResponseHeader(Kr.requestContextHeader);return oo.getCorrelationContext(i)}}catch(n){Bs(t,18,"Failed to get Request-Context correlation header as it may be not included in the response or not accessible.",{ajaxDiagnosticsMessage:As(e),exception:io.dump(n)})}}function S(t,e){if(e.requestUrl&&s&&p){var n=Ni();if(n&&nr.isFunction(n.mark)){_s++;var i=s+t+"#"+_s;n.mark(i);var r=n.getEntriesByName(i);r&&1===r.length&&(e.perfMark=r[0])}}}function C(t,e,n,i){var r=e.perfMark,o=Ni(),s=f.maxAjaxPerfLookupAttempts,a=f.ajaxPerfLookupDelay,c=e.requestUrl,u=0;!function l(){try{if(o&&r){u++;for(var f=null,d=o.getEntries(),h=d.length-1;h>=0;h--){var p=d[h];if(p){if("resource"===p.entryType)p.initiatorType!==t||-1===Es(p.name,c)&&-1===Es(c,p.name)||(f=p);else if("mark"===p.entryType&&p.name===r.name){e.perfTiming=f;break}if(p.startTime<r.startTime-1e3)break}}}!r||e.perfTiming||u>=s||!1===e.async?(r&&nr.isFunction(o.clearMarks)&&o.clearMarks(r.name),e.perfAttempts=u,n()):setTimeout(l,a)}catch(t){i(t)}}()}function _(e){var n="";try{Ss(e)||(n+="string"==typeof e?"(url: '"+e+"')":"(url: '"+e.url+"')")}catch(e){qs(t,15,"Failed to grab failed fetch diagnostics message",{exception:io.dump(e)})}return n}function A(e,n,i,r,o){function s(e,n,r){var o=r||{};o.fetchDiagnosticsMessage=_(i),n&&(o.exception=io.dump(n)),Bs(t,e,"Failed to calculate the duration of the fetch call, monitoring data for this fetch call won't be sent.",o)}r&&(r.responseFinishedTime=ao.Now(),r.status=n,C("fetch",r,(function(){var e=r.CreateTrackItem("Fetch",d,o);e?t.trackDependencyDataInternal(e):s(14,null,{requestSentTime:r.requestSentTime,responseFinishedTime:r.responseFinishedTime})}),(function(t){s(18,t,null)})))}function q(e){if(e&&e.headers)try{var n=e.headers.get(Kr.requestContextHeader);return oo.getCorrelationContext(n)}catch(n){Bs(t,18,"Failed to get Request-Context correlation header as it may be not included in the response or not accessible.",{fetchDiagnosticsMessage:_(e),exception:io.dump(n)})}}t.initialize=function(l,h,g,_){if(!t.isInitialized()){n.initialize(l,h,g,_);var B=t._getTelCtx();tr(e.getDefaultConfig(),(function(t,n){f[t]=B.getConfig(e.identifier,t,n)}));var j=f.distributedTracingMode;if(d=f.enableRequestHeaderTracking,m=f.maxAjaxCallsPerView,v=f.enableResponseHeaderTracking,o=j===$r.AI||j===$r.AI_AND_W3C,r=j===$r.AI_AND_W3C||j===$r.W3C,p=f.enableAjaxPerfTracking){var E=l.instrumentationKey||"unkwn";s=E.length>5?"ai.ajxmn."+E.substring(E.length-5)+".":"ai.ajxmn."+E+"."}if(!1===f.disableAjaxTracking&&function(t){var e=!1;if("undefined"!=typeof XMLHttpRequest&&!Ss(XMLHttpRequest)){var n=XMLHttpRequest.prototype;e=!(Ss(n)||Ss(n.open)||Ss(n.send)||Ss(n.abort))}var i=io.getIEVersion();if(i&&i<9&&(e=!1),e)try{(new XMLHttpRequest).ajaxData={};var r=XMLHttpRequest.prototype.open;XMLHttpRequest.prototype.open=r}catch(n){e=!1,qs(t,15,"Failed to enable XMLHttpRequest monitoring, extension is not supported",{exception:io.dump(n)})}return e}(t)&&!u&&(a(XMLHttpRequest,"open",{req:function(e,n,r,o){var s=e.inst,a=s.ajaxData;w(s,r)||!y(s,!0)||a&&a.xhrMonitoringState.openDone||function(e,n,r,o){var s=i&&i.telemetryTrace&&i.telemetryTrace.traceID||io.generateW3CId(),a=io.generateW3CId().substr(0,16),c=new xs(s,a,t.diagLog());c.method=n,c.requestUrl=r,c.xhrMonitoringState.openDone=!0,c.requestHeaders={},c.async=o,e.ajaxData=c,function(e){e.ajaxData.xhrMonitoringState.stateChangeAttached=rr.Attach(e,"readystatechange",(function(){try{e&&4===e.readyState&&y(e)&&function(e){var n=e.ajaxData;function i(n,i){var r=i||{};r.ajaxDiagnosticsMessage=As(e),n&&(r.exception=io.dump(n)),Bs(t,14,"Failed to calculate the duration of the ajax call, monitoring data for this ajax call won't be sent.",r)}n.responseFinishedTime=ao.Now(),n.status=e.status,C("xmlhttprequest",n,(function(){try{var r=n.CreateTrackItem("Ajax",d,(function(){var t={statusText:e.statusText,headerMap:null,correlationContext:k(e),type:e.responseType,responseText:x(e),response:e.response};if(v){var n=e.getAllResponseHeaders();if(n){var i=nr.strTrim(n).split(/[\r\n]+/),r={};Cs(i,(function(t){var e=t.split(": "),n=e.shift(),i=e.join(": ");r[n]=i})),t.headerMap=r}}return t}));r?t.trackDependencyDataInternal(r):i(null,{requestSentTime:n.requestSentTime,responseFinishedTime:n.responseFinishedTime})}finally{try{e.ajaxData=null}catch(t){}}}),(function(t){i(t,null)}))}(e)}catch(i){var n=io.dump(i);n&&-1!==Es(n.toLowerCase(),"c00c023f")||qs(t,16,"Failed to monitor XMLHttpRequest 'readystatechange' event handler, monitoring data for this ajax call may be incorrect.",{ajaxDiagnosticsMessage:As(e),exception:n})}}))}(e)}(s,n,r,o)},hkErr:js(t,15,"Failed to monitor XMLHttpRequest.open, monitoring data for this ajax call may be incorrect.")}),a(XMLHttpRequest,"send",{req:function(e){var n=e.inst,i=n.ajaxData;y(n)&&!i.xhrMonitoringState.sendDone&&(S("xhr",i),i.requestSentTime=ao.Now(),n=t.includeCorrelationHeaders(i,void 0,void 0,n),i.xhrMonitoringState.sendDone=!0)},hkErr:js(t,17,"Failed to monitor XMLHttpRequest, monitoring data for this ajax call may be incorrect.")}),a(XMLHttpRequest,"abort",{req:function(t){var e=t.inst,n=e.ajaxData;y(e)&&!n.xhrMonitoringState.abortDone&&(n.aborted=1,n.xhrMonitoringState.abortDone=!0)},hkErr:js(t,13,"Failed to monitor XMLHttpRequest.abort, monitoring data for this ajax call may be incorrect.")}),d&&a(XMLHttpRequest,"setRequestHeader",{req:function(t,e,n){var i=t.inst;y(i)&&(i.ajaxData.requestHeaders[e]=n)},hkErr:js(t,71,"Failed to monitor XMLHttpRequest.setRequestHeader, monitoring data for this ajax call may be incorrect.")}),u=!0),function(){var e,n=!(e=ji())||Ss(e.Request)||Ss(e.Request.prototype)||Ss(e.fetch)?null:e.fetch;if(n){var r=ji(),o=n.polyfill;!1===f.disableFetchTracking?(b.push(Jr(r,"fetch",{req:function(e,n,r){var s;if(c&&!w(null,n,r)&&(!o||!u)){var a=e.ctx();s=function(e,n){var r=i&&i.telemetryTrace&&i.telemetryTrace.traceID||io.generateW3CId(),o=io.generateW3CId().substr(0,16),s=new xs(r,o,t.diagLog());s.requestSentTime=ao.Now(),s.requestUrl=e instanceof Request?e?e.url:"":e;var a="GET";n&&n.method?a=n.method:e&&e instanceof Request&&(a=e.method),s.method=a;var c={};return d&&new Headers((n?n.headers:0)||e instanceof Request&&e.headers||{}).forEach((function(t,e){c[e]=t})),s.requestHeaders=c,S("fetch",s),s}(n,r);var l=t.includeCorrelationHeaders(s,n,r);l!==r&&e.set(1,l),a.data=s}},rsp:function(t,e){var n=t.ctx().data;n&&(t.rslt=t.rslt.then((function(t){return A(0,(t||{}).status,t,n,(function(){var e={statusText:t.statusText,headerMap:null,correlationContext:q(t)};if(v){var n={};t.headers.forEach((function(t,e){n[e]=t})),e.headerMap=n}return e})),t})).catch((function(t){throw A(0,0,e,n,null),t})))},hkErr:js(t,15,"Failed to monitor Window.fetch, monitoring data for this fetch call may be incorrect.")})),c=!0):o&&b.push(Jr(r,"fetch",{req:function(t,e,n){w(null,e,n)}})),o&&(r.fetch.polyfill=o)}}(),g.length>0&&g){for(var I=void 0,F=0;!I&&F<g.length;)g[F]&&"AppInsightsPropertiesPlugin"===g[F].identifier&&(I=g[F]),F++;I&&(i=I.context)}}},t.teardown=function(){Cs(b,(function(t){t.rm()})),b=[],c=!1,u=!1,t.setInitialized(!1)},t.trackDependencyData=function(e,n){t.trackDependencyDataInternal(e,n)},t.includeCorrelationHeaders=function(e,n,s,a){var c=t._currentWindowHost||l;if(n){if(oo.canIncludeCorrelationHeader(f,e.getAbsoluteUrl(),c)&&(s||(s={}),s.headers=new Headers(s.headers||n instanceof Request&&n.headers||{}),o&&(s.headers.set(Kr.requestIdHeader,h="|"+e.traceID+"."+e.spanID),d&&(e.requestHeaders[Kr.requestIdHeader]=h)),(p=f.appId||i&&i.appId())&&(s.headers.set(Kr.requestContextHeader,Kr.requestContextAppIdFormat+p),d&&(e.requestHeaders[Kr.requestContextHeader]=Kr.requestContextAppIdFormat+p)),r)){var u=new ks(e.traceID,e.spanID);s.headers.set(Kr.traceParentHeader,u.toString()),d&&(e.requestHeaders[Kr.traceParentHeader]=u.toString())}return s}if(a){var h,p;if(oo.canIncludeCorrelationHeader(f,e.getAbsoluteUrl(),c))o&&(a.setRequestHeader(Kr.requestIdHeader,h="|"+e.traceID+"."+e.spanID),d&&(e.requestHeaders[Kr.requestIdHeader]=h)),(p=f.appId||i&&i.appId())&&(a.setRequestHeader(Kr.requestContextHeader,Kr.requestContextAppIdFormat+p),d&&(e.requestHeaders[Kr.requestContextHeader]=Kr.requestContextAppIdFormat+p)),r&&(u=new ks(e.traceID,e.spanID),a.setRequestHeader(Kr.traceParentHeader,u.toString()),d&&(e.requestHeaders[Kr.traceParentHeader]=u.toString()));return a}},t.trackDependencyDataInternal=function(e,n,i){if(-1===m||h<m){f.distributedTracingMode!==$r.W3C&&f.distributedTracingMode!==$r.AI_AND_W3C||"string"!=typeof e.id||"."===e.id[e.id.length-1]||(e.id+="."),nr.isNullOrUndefined(e.startTime)&&(e.startTime=new Date);var r=Eo.create(e,_o.dataType,_o.envelopeType,t.diagLog(),n,i);t.core.track(r)}else h===m&&qs(t,55,"Maximum ajax per page view limit reached, ajax monitoring is paused until the next trackPageView(). In order to increase the limit set the maxAjaxCallsPerView configuration parameter.",!0);++h}})),n}return __extends(e,t),e.getDefaultConfig=function(){return{maxAjaxCallsPerView:500,disableAjaxTracking:!1,disableFetchTracking:!0,disableCorrelationHeaders:!1,distributedTracingMode:$r.AI,correlationHeaderExcludedDomains:["*.blob.core.windows.net","*.blob.core.chinacloudapi.cn","*.blob.core.cloudapi.de","*.blob.core.usgovcloudapi.net"],correlationHeaderDomains:void 0,appId:void 0,enableCorsCorrelation:!1,enableRequestHeaderTracking:!1,enableResponseHeaderTracking:!1,enableAjaxErrorStatusText:!1,enableAjaxPerfTracking:!1,maxAjaxPerfLookupAttempts:3,ajaxPerfLookupDelay:25}},e.getEmptyConfig=function(){var t=this.getDefaultConfig();return tr(t,(function(e){t[e]=void 0})),t},e.prototype.processTelemetry=function(t,e){this.processNext(t,e)},e.identifier="AjaxDependencyPlugin",e}(Ir),Ps=function(){function t(t){var e=this;e._snippetVersion=""+(t.sv||t.version||""),t.queue=t.queue||[],t.version=t.version||2;var n=t.config||{};if(n.connectionString){var i=uo.parse(n.connectionString),r=i.ingestionendpoint;n.endpointUrl=r?r+"/v2/track":n.endpointUrl,n.instrumentationKey=i.instrumentationkey||n.instrumentationKey}e.appInsights=new Do,e.properties=new ps,e.dependencies=new Fs,e.core=new Lr,e.snippet=t,e.config=n,e.getSKUDefaults()}return t.prototype.trackEvent=function(t,e){this.appInsights.trackEvent(t,e)},t.prototype.trackPageView=function(t){this.appInsights.trackPageView(t||{})},t.prototype.trackPageViewPerformance=function(t){this.appInsights.trackPageViewPerformance(t||{})},t.prototype.trackException=function(t){!t.exception&&t.error&&(t.exception=t.error),this.appInsights.trackException(t)},t.prototype._onerror=function(t){this.appInsights._onerror(t)},t.prototype.trackTrace=function(t,e){this.appInsights.trackTrace(t,e)},t.prototype.trackMetric=function(t,e){this.appInsights.trackMetric(t,e)},t.prototype.startTrackPage=function(t){this.appInsights.startTrackPage(t)},t.prototype.stopTrackPage=function(t,e,n,i){this.appInsights.stopTrackPage(t,e,n,i)},t.prototype.startTrackEvent=function(t){this.appInsights.startTrackEvent(t)},t.prototype.stopTrackEvent=function(t,e,n){this.appInsights.stopTrackEvent(t,e,n)},t.prototype.addTelemetryInitializer=function(t){return this.appInsights.addTelemetryInitializer(t)},t.prototype.setAuthenticatedUserContext=function(t,e,n){void 0===n&&(n=!1),this.properties.context.user.setAuthenticatedUserContext(t,e,n)},t.prototype.clearAuthenticatedUserContext=function(){this.properties.context.user.clearAuthenticatedUserContext()},t.prototype.trackDependencyData=function(t){this.dependencies.trackDependencyData(t)},t.prototype.flush=function(t){var e=this;void 0===t&&(t=!0),Cr(this.core,(function(){return"AISKU.flush"}),(function(){nr.arrForEach(e.core.getTransmissionControls(),(function(e){nr.arrForEach(e,(function(e){e.flush(t)}))}))}),null,t)},t.prototype.onunloadFlush=function(t){void 0===t&&(t=!0),nr.arrForEach(this.core.getTransmissionControls(),(function(e){nr.arrForEach(e,(function(e){e.onunloadFlush?e.onunloadFlush():e.flush(t)}))}))},t.prototype.loadAppInsights=function(t,e,n){var i=this;void 0===t&&(t=!1);var r=this;if(t&&r.config.extensions&&r.config.extensions.length>0)throw new Error("Extensions not allowed in legacy mode");return Cr(r.core,(function(){return"AISKU.loadAppInsights"}),(function(){var o=[],s=new rs;o.push(s),o.push(r.properties),o.push(r.dependencies),o.push(r.appInsights),r.core.initialize(r.config,o,e,n),r.context=r.properties.context,Is&&r.context&&(r.context.internal.sdkSrc=Is),function(e){if(e){var n="";nr.isNullOrUndefined(r._snippetVersion)||(n+=r._snippetVersion),t&&(n+=".lg"),r.context&&r.context.internal&&(r.context.internal.snippetVer=n||"-"),tr(r,(function(t,n){nr.isString(t)&&!nr.isFunction(n)&&"_"!==t.substring(0,1)&&(e[t]=n)}))}}(r.snippet),r.emptyQueue(),r.pollInternalLogs(),r.addHousekeepingBeforeUnload(i)})),r},t.prototype.updateSnippetDefinitions=function(t){tr(this,(function(e,n){nr.isString(e)&&(t[e]=n)}))},t.prototype.emptyQueue=function(){var t=this;try{if(io.isArray(t.snippet.queue)){for(var e=t.snippet.queue.length,n=0;n<e;n++)(0,t.snippet.queue[n])();t.snippet.queue=void 0,delete t.snippet.queue}}catch(t){t&&nr.isFunction(t.toString)&&t.toString()}},t.prototype.pollInternalLogs=function(){this.core.pollInternalLogs()},t.prototype.addHousekeepingBeforeUnload=function(t){if(Ii()||Pi()){var e=function(){t.onunloadFlush(!1);var e=t.appInsights.core._extensions.AppInsightsPropertiesPlugin;e&&e.context&&e.context._sessionManager&&e.context._sessionManager.backup()};if(!t.appInsights.config.disableFlushOnBeforeUnload){var n=nr.addEventHandler("beforeunload",e);(n=nr.addEventHandler("pagehide",e)||n)||(i=Mi())&&i.product&&"ReactNative"===i.product||t.appInsights.core.logger.throwInternal(er.CRITICAL,19,"Could not add handler for beforeunload and pagehide")}t.appInsights.config.disableFlushOnUnload||nr.addEventHandler("pagehide",e)}var i},t.prototype.getSKUDefaults=function(){var t=this;t.config.diagnosticLogInterval=t.config.diagnosticLogInterval&&t.config.diagnosticLogInterval>0?t.config.diagnosticLogInterval:1e4},t}();
10
+ function is(t){try{return t.responseText}catch(t){}return null}var rs=function(t){function e(){var n,i,r,o,s=t.call(this)||this;return s.priority=1001,s.identifier="AppInsightsChannelPlugin",s._XMLHttpRequestSupported=!1,gr(e,s,(function(t,a){function c(){throw new Error("Method not implemented.")}function u(e){var n=t._senderConfig.endpointUrl(),i=t._buffer.batchPayloads(e),r=new Blob([i],{type:"text/plain;charset=UTF-8"});Mi().sendBeacon(n,r)?(t._buffer.markAsSent(e),t._onSuccess(e,e.length)):(l(e,!0),t.diagLog().throwInternal(er.WARNING,40,". Failed to send telemetry with Beacon API, retried with xhrSender."))}function l(e,n){var i=new XMLHttpRequest,r=t._senderConfig.endpointUrl();try{i[co]=!0}catch(t){}i.open("POST",r,n),i.setRequestHeader("Content-type","application/json"),io.isInternalApplicationInsightsEndpoint(r)&&i.setRequestHeader(Kr.sdkContextHeader,Kr.sdkContextHeaderAppIdRequest),i.onreadystatechange=function(){return t._xhrReadyStateChange(i,e,e.length)},i.onerror=function(n){return t._onError(e,m(i),n)};var o=t._buffer.batchPayloads(e);i.send(o),t._buffer.markAsSent(e)}function f(e){try{if(e&&""!==e){var n=Oi().parse(e);if(n&&n.itemsReceived&&n.itemsReceived>=n.itemsAccepted&&n.itemsReceived-n.itemsAccepted===n.errors.length)return n}}catch(n){t.diagLog().throwInternal(er.CRITICAL,43,"Cannot parse the response. "+io.getExceptionName(n),{response:e})}return null}function d(e,r){if(void 0===r&&(r=1),e&&0!==e.length){t._buffer.clearSent(e),n++;for(var o=0,s=e;o<s.length;o++)t._buffer.enqueue(s[o]);!function(t){var e;if(n<=1)e=10;else{var r=(Math.pow(2,n)-1)/2,o=Math.floor(Math.random()*r*10)+1;e=Math.max(Math.min(o*=t,3600),10)}var s=nr.dateNow()+1e3*e;i=s}(r),h()}}function h(){if(!r){var e=i?Math.max(0,i-nr.dateNow()):0,n=Math.max(t._senderConfig.maxBatchInterval(),e);r=setTimeout((function(){t.triggerSend(!0,null,1)}),n)}}function p(t){return 408===t||429===t||500===t||503===t}function m(t,e){return t?"XMLHttpRequest,Status:"+t.status+",Response:"+is(t)||t.response||"":e}function v(e){var n=Fi(),i=new XDomainRequest;i.onload=function(){return t._xdrOnLoad(i,e)},i.onerror=function(n){return t._onError(e,b(i),n)};var r=n&&n.location&&n.location.protocol||"";if(0!==t._senderConfig.endpointUrl().lastIndexOf(r,0))return t.diagLog().throwInternal(er.WARNING,40,". Cannot send XDomain request. The endpoint URL protocol doesn't match the hosting page protocol."),void t._buffer.clear();var o=t._senderConfig.endpointUrl().replace(/^(https?:)/,"");i.open("POST",o);var s=t._buffer.batchPayloads(e);i.send(s),t._buffer.markAsSent(e)}function b(t,e){return t?"XDomainRequest,Response:"+is(t)||"":e}t.pause=c,t.resume=c,t.flush=function(){try{t.triggerSend(!0,null,1)}catch(e){t.diagLog().throwInternal(er.CRITICAL,22,"flush failed, telemetry will not be collected: "+io.getExceptionName(e),{exception:io.dump(e)})}},t.onunloadFlush=function(){if(!1!==t._senderConfig.onunloadDisableBeacon()&&!1!==t._senderConfig.isBeaconApiDisabled()||!io.IsBeaconApiSupported())t.flush();else try{t.triggerSend(!0,u,2)}catch(e){t.diagLog().throwInternal(er.CRITICAL,20,"failed to flush with beacon sender on page unload, telemetry will not be collected: "+io.getExceptionName(e),{exception:io.dump(e)})}},t.teardown=c,t.initialize=function(r,s,c,f){a.initialize(r,s,c,f);var d=t._getTelCtx(),h=t.identifier;o=new Ko(s.logger),n=0,i=null,t._sender=null;var p=e._getDefaultAppInsightsChannelConfig();if(t._senderConfig=e._getEmptyAppInsightsChannelConfig(),tr(p,(function(e,n){t._senderConfig[e]=function(){return d.getConfig(h,e,n())}})),t._buffer=t._senderConfig.enableSessionStorageBuffer()&&io.canUseSessionStorage()?new Lo(t.diagLog(),t._senderConfig):new Uo(t._senderConfig),t._sample=new ns(t._senderConfig.samplingPercentage(),t.diagLog()),function(t){return!(nr.isNullOrUndefined(t.disableInstrumentaionKeyValidation)||!t.disableInstrumentaionKeyValidation)||new RegExp("^[0-9a-f]{8}-[0-9a-f]{4}-[0-9a-f]{4}-[0-9a-f]{4}-[0-9a-f]{12}$").test(t.instrumentationKey)}(r)||t.diagLog().throwInternal(er.CRITICAL,100,"Invalid Instrumentation key "+r.instrumentationKey),!t._senderConfig.isBeaconApiDisabled()&&io.IsBeaconApiSupported())t._sender=u;else if(void 0!==typeof XMLHttpRequest){var m=Ei("XMLHttpRequest");m&&("withCredentials"in new m?(t._sender=l,t._XMLHttpRequestSupported=!0):void 0!==typeof XDomainRequest&&(t._sender=v))}},t.processTelemetry=function(n,i){i=t._getTelCtx(i);try{if(t._senderConfig.disableTelemetry())return;if(!n)return void i.diagLog().throwInternal(er.CRITICAL,7,"Cannot send empty telemetry");if(n.baseData&&!n.baseType)return void i.diagLog().throwInternal(er.CRITICAL,70,"Cannot send telemetry without baseData and baseType");if(n.baseType||(n.baseType="EventData"),!t._sender)return void i.diagLog().throwInternal(er.CRITICAL,28,"Sender was not initialized");if(!t._sample.isSampledIn(n))return void i.diagLog().throwInternal(er.WARNING,33,"Telemetry item was sampled out and not sent",{SampleRate:t._sample.sampleRate});n.sampleRate=t._sample.sampleRate;var r=e.constructEnvelope(n,t._senderConfig.instrumentationKey(),i.diagLog());if(!r)return void i.diagLog().throwInternal(er.CRITICAL,47,"Unable to create an AppInsights envelope");var s=!1;if(n.tags&&n.tags.ProcessLegacy&&(nr.arrForEach(n.tags.ProcessLegacy,(function(t){try{t&&!1===t(r)&&(s=!0,i.diagLog().warnToConsole("Telemetry processor check returns false"))}catch(t){i.diagLog().throwInternal(er.CRITICAL,64,"One of telemetry initializers failed, telemetry item will not be sent: "+io.getExceptionName(t),{exception:io.dump(t)},!0)}})),delete n.tags.ProcessLegacy),s)return;var a=o.serialize(r),c=t._buffer.getItems(),u=t._buffer.batchPayloads(c);u&&u.length+a.length>t._senderConfig.maxBatchSizeInBytes()&&t.triggerSend(!0,null,10),t._buffer.enqueue(a),h()}catch(t){i.diagLog().throwInternal(er.WARNING,12,"Failed adding telemetry to the sender's buffer, some telemetry will be lost: "+io.getExceptionName(t),{exception:io.dump(t)})}t.processNext(n,i)},t._xhrReadyStateChange=function(e,i,r){if(4===e.readyState){var o=null;t._appId||(o=f(is(e)||e.response))&&o.appId&&(t._appId=o.appId),(e.status<200||e.status>=300)&&0!==e.status?!t._senderConfig.isRetryDisabled()&&p(e.status)?(d(i),t.diagLog().throwInternal(er.WARNING,40,". Response code "+e.status+". Will retry to send "+i.length+" items.")):t._onError(i,m(e)):Zo.isOffline()?t._senderConfig.isRetryDisabled()||(d(i,10),t.diagLog().throwInternal(er.WARNING,40,". Offline - Response Code: "+e.status+". Offline status: "+Zo.isOffline()+". Will retry to send "+i.length+" items.")):206===e.status?(o||(o=f(is(e)||e.response)),o&&!t._senderConfig.isRetryDisabled()?t._onPartialSuccess(i,o):t._onError(i,m(e))):(n=0,t._onSuccess(i,r))}},t.triggerSend=function(e,n,o){void 0===e&&(e=!0);try{if(t._senderConfig.disableTelemetry())t._buffer.clear();else if(t._buffer.count()>0){var a=t._buffer.getItems();!function(e,n){var i,r=t.core[i="getNotifyMgr"]?t.core[i]():t.core._notificationManager;if(r&&r.eventsSendRequest)try{r.eventsSendRequest(e,n)}catch(e){t.diagLog().throwInternal(er.CRITICAL,74,"send request notification failed: "+io.getExceptionName(e),{exception:io.dump(e)})}}(o||0,e),n?n.call(s,a,e):t._sender(a,e)}clearTimeout(r),r=null,i=null}catch(e){var c=io.getIEVersion();(!c||c>9)&&t.diagLog().throwInternal(er.CRITICAL,40,"Telemetry transmission failed, some telemetry will be lost: "+io.getExceptionName(e),{exception:io.dump(e)})}},t._onError=function(e,n){t.diagLog().throwInternal(er.WARNING,26,"Failed to send telemetry.",{message:n}),t._buffer.clearSent(e)},t._onPartialSuccess=function(e,n){for(var i=[],r=[],o=0,s=n.errors.reverse();o<s.length;o++){var a=s[o],c=e.splice(a.index,1)[0];p(a.statusCode)?r.push(c):i.push(c)}e.length>0&&t._onSuccess(e,n.itemsAccepted),i.length>0&&t._onError(i,m(null,["partial success",n.itemsAccepted,"of",n.itemsReceived].join(" "))),r.length>0&&(d(r),t.diagLog().throwInternal(er.WARNING,40,"Partial success. Delivered: "+e.length+", Failed: "+i.length+". Will retry to send "+r.length+" our of "+n.itemsReceived+" items"))},t._onSuccess=function(e){t._buffer.clearSent(e)},t._xdrOnLoad=function(e,i){var r=is(e);if(!e||r+""!="200"&&""!==r){var o=f(r);o&&o.itemsReceived&&o.itemsReceived>o.itemsAccepted&&!t._senderConfig.isRetryDisabled()?t._onPartialSuccess(i,o):t._onError(i,b(e))}else n=0,t._onSuccess(i,0)}})),s}return __extends(e,t),e.constructEnvelope=function(t,e,n){var i;switch((i=e===t.iKey||nr.isNullOrUndefined(e)?t:__assign({},t,{iKey:e})).baseType){case mo.dataType:return Wo.EventEnvelopeCreator.Create(n,i);case Ao.dataType:return Go.TraceEnvelopeCreator.Create(n,i);case Co.dataType:return Xo.PageViewEnvelopeCreator.Create(n,i);case qo.dataType:return Jo.PageViewPerformanceEnvelopeCreator.Create(n,i);case vo.dataType:return $o.ExceptionEnvelopeCreator.Create(n,i);case ko.dataType:return Yo.MetricEnvelopeCreator.Create(n,i);case _o.dataType:return Qo.DependencyEnvelopeCreator.Create(n,i);default:return Wo.EventEnvelopeCreator.Create(n,i)}},e._getDefaultAppInsightsChannelConfig=function(){return{endpointUrl:function(){return"https://dc.services.visualstudio.com/v2/track"},emitLineDelimitedJson:function(){return!1},maxBatchInterval:function(){return 15e3},maxBatchSizeInBytes:function(){return 102400},disableTelemetry:function(){return!1},enableSessionStorageBuffer:function(){return!0},isRetryDisabled:function(){return!1},isBeaconApiDisabled:function(){return!0},onunloadDisableBeacon:function(){return!1},instrumentationKey:function(){},namePrefix:function(){},samplingPercentage:function(){return 100}}},e._getEmptyAppInsightsChannelConfig=function(){return{endpointUrl:void 0,emitLineDelimitedJson:void 0,maxBatchInterval:void 0,maxBatchSizeInBytes:void 0,disableTelemetry:void 0,enableSessionStorageBuffer:void 0,isRetryDisabled:void 0,isBeaconApiDisabled:void 0,onunloadDisableBeacon:void 0,instrumentationKey:void 0,namePrefix:void 0,samplingPercentage:void 0}},e}(Ir),os=function(){},ss=function(){function t(e,n){var i=this;this._logger=nr.isNullOrUndefined(n)?new xr:n,e||(e={}),"function"!=typeof e.sessionExpirationMs&&(e.sessionExpirationMs=function(){return t.acquisitionSpan}),"function"!=typeof e.sessionRenewalMs&&(e.sessionRenewalMs=function(){return t.renewalSpan}),this.config=e,this._storageNamePrefix=function(){return i.config.namePrefix&&i.config.namePrefix()?t.cookieNameConst+i.config.namePrefix():t.cookieNameConst},this.automaticSession=new os}return t.prototype.update=function(){this.automaticSession.id||this.initializeAutomaticSession();var e=(new Date).getTime(),n=0!==this.config.sessionExpirationMs()&&e-this.automaticSession.acquisitionDate>this.config.sessionExpirationMs(),i=0!==this.config.sessionExpirationMs()&&e-this.automaticSession.renewalDate>this.config.sessionRenewalMs();n||i?this.renew():(!this.cookieUpdatedTimestamp||e-this.cookieUpdatedTimestamp>t.cookieUpdateInterval)&&(this.automaticSession.renewalDate=e,this.setCookie(this.automaticSession.id,this.automaticSession.acquisitionDate,this.automaticSession.renewalDate))},t.prototype.backup=function(){this.setStorage(this.automaticSession.id,this.automaticSession.acquisitionDate,this.automaticSession.renewalDate)},t.prototype.initializeAutomaticSession=function(){var t=io.getCookie(this._logger,this._storageNamePrefix());if(t&&"function"==typeof t.split)this.initializeAutomaticSessionWithData(t);else{var e=io.getStorage(this._logger,this._storageNamePrefix());e&&this.initializeAutomaticSessionWithData(e)}this.automaticSession.id||this.renew()},t.prototype.initializeAutomaticSessionWithData=function(t){var e=t.split("|");e.length>0&&(this.automaticSession.id=e[0]);try{e.length>1&&(this.automaticSession.acquisitionDate=+new Date(+e[1]),this.automaticSession.acquisitionDate=this.automaticSession.acquisitionDate>0?this.automaticSession.acquisitionDate:0),e.length>2&&(this.automaticSession.renewalDate=+new Date(+e[2]),this.automaticSession.renewalDate=this.automaticSession.renewalDate>0?this.automaticSession.renewalDate:0)}catch(t){this._logger.throwInternal(er.CRITICAL,9,"Error parsing ai_session cookie, session will be reset: "+io.getExceptionName(t),{exception:io.dump(t)})}0===this.automaticSession.renewalDate&&this._logger.throwInternal(er.WARNING,27,"AI session renewal date is 0, session will be reset.")},t.prototype.renew=function(){var t=(new Date).getTime();this.automaticSession.id=io.newId(this.config&&this.config.idLength?this.config.idLength():22),this.automaticSession.acquisitionDate=t,this.automaticSession.renewalDate=t,this.setCookie(this.automaticSession.id,this.automaticSession.acquisitionDate,this.automaticSession.renewalDate),io.canUseLocalStorage()||this._logger.throwInternal(er.WARNING,0,"Browser does not support local storage. Session durations will be inaccurate.")},t.prototype.setCookie=function(t,e,n){var i=e+this.config.sessionExpirationMs(),r=n+this.config.sessionRenewalMs(),o=new Date,s=[t,e,n];o.setTime(i<r?i:r);var a=this.config.cookieDomain?this.config.cookieDomain():null,c=0===this.config.sessionExpirationMs()?"0":o.toUTCString();io.setCookie(this._logger,this._storageNamePrefix(),s.join("|")+";expires="+c,a),this.cookieUpdatedTimestamp=(new Date).getTime()},t.prototype.setStorage=function(t,e,n){io.setStorage(this._logger,this._storageNamePrefix(),[t,e,n].join("|"))},t.acquisitionSpan=864e5,t.renewalSpan=18e5,t.cookieUpdateInterval=6e4,t.cookieNameConst="ai_session",t}(),as=function(){},cs=function(){this.id="browser",this.deviceClass="Browser"},us=function(t){this.sdkVersion=(t.sdkExtension&&t.sdkExtension()?t.sdkExtension()+"_":"")+"javascript:2.5.10"},ls=function(){function t(e,n){this.isNewUser=!1,this._logger=n;var i=io.getCookie(this._logger,t.userCookieName);if(i){this.isNewUser=!1;var r=i.split(t.cookieSeparator);r.length>0&&(this.id=r[0])}if(this.config=e,!this.id){this.id=nr.newId(e&&e.idLength?e.idLength():22);var o=new Date,s=nr.toISOString(o);this.accountAcquisitionDate=s,this.isNewUser=!0,o.setTime(o.getTime()+31536e6);var a=[this.id,s],c=this.config.cookieDomain?this.config.cookieDomain():void 0;io.setCookie(this._logger,t.userCookieName,a.join(t.cookieSeparator)+";expires="+o.toUTCString(),c);var u=e.namePrefix&&e.namePrefix()?e.namePrefix()+"ai_session":"ai_session";io.removeStorage(this._logger,u)}this.accountId=e.accountId?e.accountId():void 0;var l=io.getCookie(this._logger,t.authUserCookieName);if(l){var f=(l=decodeURI(l)).split(t.cookieSeparator);f[0]&&(this.authenticatedId=f[0]),f.length>1&&f[1]&&(this.accountId=f[1])}}return t.prototype.setAuthenticatedUserContext=function(e,n,i){if(void 0===i&&(i=!1),!this.validateUserInput(e)||n&&!this.validateUserInput(n))this._logger.throwInternal(er.WARNING,60,"Setting auth user context failed. User auth/account id should be of type string, and not contain commas, semi-colons, equal signs, spaces, or vertical-bars.",!0);else{this.authenticatedId=e;var r=this.authenticatedId;n&&(this.accountId=n,r=[this.authenticatedId,this.accountId].join(t.cookieSeparator)),i&&io.setCookie(this._logger,t.authUserCookieName,encodeURI(r),this.config.cookieDomain())}},t.prototype.clearAuthenticatedUserContext=function(){this.authenticatedId=null,this.accountId=null,io.deleteCookie(this._logger,t.authUserCookieName)},t.prototype.validateUserInput=function(t){return!("string"!=typeof t||!t||t.match(/,|;|=| |\|/))},t.cookieSeparator="|",t.userCookieName="ai_user",t.authUserCookieName="ai_authUser",t}(),fs=function(){},ds=function(t,e,n,i){this.traceID=t||io.generateW3CId(),this.parentID=e,this.name=n;var r=Ri();!n&&r&&r.pathname&&(this.name=r.pathname),this.name=Zr.sanitizeString(i,this.name)},hs=function(){function t(t,e){var n=this;n.application=new as,n.internal=new us(e),Ii()&&(n.sessionManager=new ss(e,t),n.device=new cs,n.location=new fs,n.user=new ls(e,t),n.telemetryTrace=new ds(void 0,void 0,void 0,t),n.session=new os),n.appId=function(){return null}}return t.prototype.applySessionContext=function(t){var e=this.session,n=this.sessionManager,i=e||n&&n.automaticSession;i&&nr.isString(i.id)&&(t.ext.app.sesId=i.id),e&&(t.ext.app.sesId=nr.isString(e.id)?e.id:n.automaticSession.id)},t.prototype.applyOperatingSystemContxt=function(t){var e=this.os;e&&e.name&&(t.ext.os=e)},t.prototype.applyApplicationContext=function(t){var e=this.application;e&&(nr.isString(e.ver)&&(t.tags[Fo.applicationVersion]=e.ver),nr.isString(e.build)&&(t.tags[Fo.applicationBuild]=e.build))},t.prototype.applyDeviceContext=function(t){var e=this.device;e&&(nr.isString(e.id)&&(t.ext.device.localId=e.id),nr.isString(e.ip)&&(t.ext.device.ip=e.ip),nr.isString(e.model)&&(t.ext.device.model=e.model),nr.isString(e.deviceClass)&&(t.ext.device.deviceClass=e.deviceClass))},t.prototype.applyInternalContext=function(t){var e=this.internal;e&&(nr.isString(e.agentVersion)&&(t.tags[Fo.internalAgentVersion]=e.agentVersion),nr.isString(e.sdkVersion)&&(t.tags[Fo.internalSdkVersion]=e.sdkVersion),t.baseType!==yr.dataType&&t.baseType!==Co.dataType||(nr.isString(e.snippetVer)&&(t.tags[Fo.internalSnippet]=e.snippetVer),nr.isString(e.sdkSrc)&&(t.tags[Fo.internalSdkSrc]=e.sdkSrc)))},t.prototype.applyLocationContext=function(t){var e=this.location;e&&nr.isString(e.ip)&&(t.tags[Fo.locationIp]=e.ip)},t.prototype.applyOperationContext=function(t){var e=this.telemetryTrace;if(e){var n=t.ext.trace||{traceID:void 0,parentID:void 0};nr.isString(e.traceID)&&(n.traceID=e.traceID),nr.isString(e.name)&&(n.name=e.name),nr.isString(e.parentID)&&(n.parentID=e.parentID),t.ext.trace=n}},t.prototype.applyWebContext=function(t){var e=this.web;e&&(t.ext.web=t.ext.web||{},t.ext.web=e)},t.prototype.applyUserContext=function(t){var e=this.user;e&&(t.tags||(t.tags=[]),nr.isString(e.accountId)&&(t.tags[Fo.userAccountId]=e.accountId),nr.isString(e.id)&&(t.ext.user.id=e.id),nr.isString(e.authenticatedId)&&(t.ext.user.authId=e.authenticatedId))},t.prototype.cleanUp=function(t){t.ext[Io.DeviceExt]&&0===nr.objKeys(t.ext[Io.DeviceExt]).length&&delete t.ext[Io.DeviceExt],t.ext[Io.UserExt]&&0===nr.objKeys(t.ext[Io.UserExt]).length&&delete t.ext[Io.UserExt],t.ext[Io.WebExt]&&0===nr.objKeys(t.ext[Io.WebExt]).length&&delete t.ext[Io.WebExt],t.ext[Io.OSExt]&&0===nr.objKeys(t.ext[Io.OSExt]).length&&delete t.ext[Io.OSExt],t.ext[Io.AppExt]&&0===nr.objKeys(t.ext[Io.AppExt]).length&&delete t.ext[Io.AppExt],t.ext[Io.TraceExt]&&0===nr.objKeys(t.ext[Io.TraceExt]).length&&delete t.ext[Io.TraceExt]},t}(),ps=function(t){function e(){var e=null!==t&&t.apply(this,arguments)||this;return e.priority=110,e.identifier="AppInsightsPropertiesPlugin",e}return __extends(e,t),e.getDefaultConfig=function(){return{instrumentationKey:function(){},accountId:function(){return null},sessionRenewalMs:function(){return 18e5},samplingPercentage:function(){return 100},sessionExpirationMs:function(){return 864e5},cookieDomain:function(){return null},sdkExtension:function(){return null},isBrowserLinkTrackingEnabled:function(){return!1},appId:function(){return null},namePrefix:function(){},idLength:function(){return 22}}},e.prototype.initialize=function(n,i,r,o){var s=this;t.prototype.initialize.call(this,n,i,r,o);var a=this._getTelCtx(),c=this.identifier,u=e.getDefaultConfig();this._extensionConfig=this._extensionConfig||e.getDefaultConfig(),tr(u,(function(t,e){s._extensionConfig[t]=function(){return a.getConfig(c,t,e())}})),this.context=new hs(i.logger,this._extensionConfig),this._breezeChannel=io.getExtension(r,"AppInsightsChannelPlugin"),this.context.appId=function(){return s._breezeChannel?s._breezeChannel._appId:null}},e.prototype.processTelemetry=function(t,e){if(nr.isNullOrUndefined(t));else{if(e=this._getTelCtx(e),t.name===Co.envelopeType&&e.diagLog().resetInternalMessageCount(),this.context.session&&"string"!=typeof this.context.session.id&&this.context.sessionManager.update(),this._processTelemetryInternal(t,e),this.context&&this.context.user&&this.context.user.isNewUser){this.context.user.isNewUser=!1;var n=new yr(72,(Mi()||{}).userAgent||"");e.diagLog().logInternalMessage(er.CRITICAL,n)}this.processNext(t,e)}},e.prototype._processTelemetryInternal=function(t,e){t.tags||(t.tags=[]),t.ext||(t.ext={});var n=t.ext;n[Io.DeviceExt]=n[Io.DeviceExt]||{},n[Io.WebExt]=n[Io.WebExt]||{},n[Io.UserExt]=n[Io.UserExt]||{},n[Io.OSExt]=n[Io.OSExt]||{},n[Io.AppExt]=n[Io.AppExt]||{},n[Io.TraceExt]=n[Io.TraceExt]||{};var i=this.context;i.applySessionContext(t,e),i.applyApplicationContext(t,e),i.applyDeviceContext(t,e),i.applyOperationContext(t,e),i.applyUserContext(t,e),i.applyOperatingSystemContxt(t,e),i.applyWebContext(t,e),i.applyLocationContext(t,e),i.applyInternalContext(t,e),i.cleanUp(t,e)},e}(Ir),ms=nr.objKeys,vs=nr.arrForEach;function bs(t,e,n){var i=0,r=t[e],o=t[n];return r&&o&&(i=ao.GetDuration(r,o)),i}function gs(t,e,n,i,r){var o=0,s=bs(n,i,r);return s&&(o=ws(t,e,io.msToTimeSpan(s))),o}function ws(t,e,n){var i=0;return t&&e&&n&&((t.ajaxPerf=t.ajaxPerf||{})[e]=n,i=1),i}var ys=function(){var t=this;t.openDone=!1,t.setRequestHeaderDone=!1,t.sendDone=!1,t.abortDone=!1,t.stateChangeAttached=!1},xs=function t(e,n,i){var r=this,o=i;r.perfMark=null,r.completed=!1,r.requestHeadersSize=null,r.requestHeaders=null,r.responseReceivingDuration=null,r.callbackDuration=null,r.ajaxTotalDuration=null,r.aborted=0,r.pageUrl=null,r.requestUrl=null,r.requestSize=0,r.method=null,r.status=null,r.requestSentTime=null,r.responseStartedTime=null,r.responseFinishedTime=null,r.callbackFinishedTime=null,r.endTime=null,r.xhrMonitoringState=new ys,r.clientFailure=0,r.traceID=e,r.spanID=n,gr(t,r,(function(t){t.getAbsoluteUrl=function(){return t.requestUrl?ro.getAbsoluteUrl(t.requestUrl):null},t.getPathName=function(){return t.requestUrl?Zr.sanitizeUrl(o,ro.getCompleteUrl(t.method,t.requestUrl)):null},t.CreateTrackItem=function(e,n,i){if(t.ajaxTotalDuration=Math.round(1e3*ao.GetDuration(t.requestSentTime,t.responseFinishedTime))/1e3,t.ajaxTotalDuration<0)return null;var r,o=((r={id:"|"+t.traceID+"."+t.spanID,target:t.getAbsoluteUrl(),name:t.getPathName(),type:e,duration:t.ajaxTotalDuration,success:+t.status>=200&&+t.status<400,responseCode:+t.status,method:t.method}).properties={HttpMethod:t.method},r);if(function(t,e){var n=t.perfTiming,i=e.properties||{},r=0,o=nr.isString,s="redirect",a="startTime",c="connectEnd",u="requestStart",l="responseEnd",f=s+"Start",d=s="End";if(n){r|=gs(i,s,n,f,d),r|=gs(i,"domainLookup",n,"domainLookupStart","domainLookupEnd"),r|=gs(i,"connect",n,"connectStart",c),r|=gs(i,"request",n,u,"requestEnd"),r|=gs(i,"response",n,"responseStart",l),r|=gs(i,"networkConnect",n,a,c),r|=gs(i,"sentRequest",n,u,l);var h=n.duration;h||(h=bs(n,a,l)||0),r|=ws(i,"duration",h),r|=ws(i,"perfTotal",h);var p=n.serverTiming;if(p){var m={};vs(p,(function(t,e){var n=function(t){var e=t,n=/([^\w\d_$])/g;return n.test(t)&&(e=t.replace(n,"_")),e}(t.name||""+e),i=m[n]||{};tr(t,(function(t,e){("name"!==t&&o(e)||nr.isNumber(e))&&(i[t]&&(e=i[t]+";"+e),!e&&o(e)||(i[t]=e))})),m[n]=i})),r|=ws(i,"serverTiming",m)}r|=ws(i,"transferSize",n.transferSize),r|=ws(i,"encodedBodySize",n.encodedBodySize),r|=ws(i,"decodedBodySize",n.decodedBodySize)}else t.perfMark&&(r|=ws(i,"missing",t.perfAttempts));r&&(e.properties=i)}(t,o),n&&ms(t.requestHeaders).length>0&&(o.properties=o.properties||{},o.properties.requestHeaders=t.requestHeaders),i){var s=i();if(s){var a=s.correlationContext;if(a&&(o.correlationContext=a),s.headerMap&&ms(s.headerMap).length>0&&(o.properties=o.properties||{},o.properties.responseHeaders=s.headerMap),t.status>=400){var c=s.type;o.properties=o.properties||{},""!==c&&"text"!==c||(o.properties.responseText=s.responseText?s.statusText+" - "+s.responseText:s.statusText),"json"===c&&(o.properties.responseText=s.response?s.statusText+" - "+JSON.stringify(s.response):s.statusText)}}}return o}}))},ks=function(){function t(e,n){var i=this;i.traceFlag=t.DEFAULT_TRACE_FLAG,i.version=t.DEFAULT_VERSION,i.traceId=e&&t.isValidTraceId(e)?e:io.generateW3CId(),i.spanId=n&&t.isValidSpanId(n)?n:io.generateW3CId().substr(0,16)}return t.isValidTraceId=function(t){return t.match(/^[0-9a-f]{32}$/)&&"00000000000000000000000000000000"!==t},t.isValidSpanId=function(t){return t.match(/^[0-9a-f]{16}$/)&&"0000000000000000"!==t},t.prototype.toString=function(){var t=this;return t.version+"-"+t.traceId+"-"+t.spanId+"-"+t.traceFlag},t.DEFAULT_TRACE_FLAG="01",t.DEFAULT_VERSION="00",t}(),Ss=nr.isNullOrUndefined,Cs=nr.arrForEach,_s=0;function As(t){var e="";try{Ss(t)||Ss(t.ajaxData)||Ss(t.ajaxData.requestUrl)||(e+="(url: '"+t.ajaxData.requestUrl+"')")}catch(t){}return e}function qs(t,e,n,i,r){t.diagLog().throwInternal(er.CRITICAL,e,n,i,r)}function Bs(t,e,n,i,r){t.diagLog().throwInternal(er.WARNING,e,n,i,r)}function js(t,e,n){return function(i){qs(t,e,n,{ajaxDiagnosticsMessage:As(i.inst),exception:io.dump(i.err)})}}function Es(t,e){return t&&e?t.indexOf(e):-1}var Is,Fs=function(t){function e(){var n=t.call(this)||this;n.identifier=e.identifier,n.priority=120;var i,r,o,s,a=Ri(),c=!1,u=!1,l=a&&a.host&&a.host.toLowerCase(),f=e.getEmptyConfig(),d=!1,h=0,p=!1,m=0,v=!1,b=[],g={};return gr(e,n,(function(t,n){function a(t,e,n){b.push(function(t,e,n){return t?Jr(t.prototype,e,n,!1):null}(t,e,n))}function w(t,e,n){var i=!1,r=((nr.isString(e)?e:(e||{}).url||"")||"").toLowerCase(),o=Es(r,"?"),s=Es(r,"#");return(-1===o||-1!==s&&s<o)&&(o=s),-1!==o&&(r=r.substring(0,o)),Ss(t)?Ss(e)||(i="object"==typeof e&&!0===e[co]||!!n&&!0===n[co]):i=!0===t[co]||!0===r[co],i?g[r]||(g[r]=1):g[r]&&(i=!0),i}function y(t,e){var n=!0,i=u;return Ss(t)||(n=!0===e||!Ss(t.ajaxData)),i&&n}function x(t){try{var e=t.responseType;if(""===e||"text"===e)return t.responseText}catch(t){}return null}function k(e){try{var n=e.getAllResponseHeaders();if(null!==n&&-1!==Es(n.toLowerCase(),Kr.requestContextHeaderLowerCase)){var i=e.getResponseHeader(Kr.requestContextHeader);return oo.getCorrelationContext(i)}}catch(n){Bs(t,18,"Failed to get Request-Context correlation header as it may be not included in the response or not accessible.",{ajaxDiagnosticsMessage:As(e),exception:io.dump(n)})}}function S(t,e){if(e.requestUrl&&s&&p){var n=Ni();if(n&&nr.isFunction(n.mark)){_s++;var i=s+t+"#"+_s;n.mark(i);var r=n.getEntriesByName(i);r&&1===r.length&&(e.perfMark=r[0])}}}function C(t,e,n,i){var r=e.perfMark,o=Ni(),s=f.maxAjaxPerfLookupAttempts,a=f.ajaxPerfLookupDelay,c=e.requestUrl,u=0;!function l(){try{if(o&&r){u++;for(var f=null,d=o.getEntries(),h=d.length-1;h>=0;h--){var p=d[h];if(p){if("resource"===p.entryType)p.initiatorType!==t||-1===Es(p.name,c)&&-1===Es(c,p.name)||(f=p);else if("mark"===p.entryType&&p.name===r.name){e.perfTiming=f;break}if(p.startTime<r.startTime-1e3)break}}}!r||e.perfTiming||u>=s||!1===e.async?(r&&nr.isFunction(o.clearMarks)&&o.clearMarks(r.name),e.perfAttempts=u,n()):setTimeout(l,a)}catch(t){i(t)}}()}function _(e){var n="";try{Ss(e)||(n+="string"==typeof e?"(url: '"+e+"')":"(url: '"+e.url+"')")}catch(e){qs(t,15,"Failed to grab failed fetch diagnostics message",{exception:io.dump(e)})}return n}function A(e,n,i,r,o){function s(e,n,r){var o=r||{};o.fetchDiagnosticsMessage=_(i),n&&(o.exception=io.dump(n)),Bs(t,e,"Failed to calculate the duration of the fetch call, monitoring data for this fetch call won't be sent.",o)}r&&(r.responseFinishedTime=ao.Now(),r.status=n,C("fetch",r,(function(){var e=r.CreateTrackItem("Fetch",d,o);e?t.trackDependencyDataInternal(e):s(14,null,{requestSentTime:r.requestSentTime,responseFinishedTime:r.responseFinishedTime})}),(function(t){s(18,t,null)})))}function q(e){if(e&&e.headers)try{var n=e.headers.get(Kr.requestContextHeader);return oo.getCorrelationContext(n)}catch(n){Bs(t,18,"Failed to get Request-Context correlation header as it may be not included in the response or not accessible.",{fetchDiagnosticsMessage:_(e),exception:io.dump(n)})}}t.initialize=function(l,h,g,_){if(!t.isInitialized()){n.initialize(l,h,g,_);var B=t._getTelCtx();tr(e.getDefaultConfig(),(function(t,n){f[t]=B.getConfig(e.identifier,t,n)}));var j=f.distributedTracingMode;if(d=f.enableRequestHeaderTracking,m=f.maxAjaxCallsPerView,v=f.enableResponseHeaderTracking,o=j===$r.AI||j===$r.AI_AND_W3C,r=j===$r.AI_AND_W3C||j===$r.W3C,p=f.enableAjaxPerfTracking){var E=l.instrumentationKey||"unkwn";s=E.length>5?"ai.ajxmn."+E.substring(E.length-5)+".":"ai.ajxmn."+E+"."}if(!1===f.disableAjaxTracking&&function(t){var e=!1;if("undefined"!=typeof XMLHttpRequest&&!Ss(XMLHttpRequest)){var n=XMLHttpRequest.prototype;e=!(Ss(n)||Ss(n.open)||Ss(n.send)||Ss(n.abort))}var i=io.getIEVersion();if(i&&i<9&&(e=!1),e)try{(new XMLHttpRequest).ajaxData={};var r=XMLHttpRequest.prototype.open;XMLHttpRequest.prototype.open=r}catch(n){e=!1,qs(t,15,"Failed to enable XMLHttpRequest monitoring, extension is not supported",{exception:io.dump(n)})}return e}(t)&&!u&&(a(XMLHttpRequest,"open",{req:function(e,n,r,o){var s=e.inst,a=s.ajaxData;w(s,r)||!y(s,!0)||a&&a.xhrMonitoringState.openDone||function(e,n,r,o){var s=i&&i.telemetryTrace&&i.telemetryTrace.traceID||io.generateW3CId(),a=io.generateW3CId().substr(0,16),c=new xs(s,a,t.diagLog());c.method=n,c.requestUrl=r,c.xhrMonitoringState.openDone=!0,c.requestHeaders={},c.async=o,e.ajaxData=c,function(e){e.ajaxData.xhrMonitoringState.stateChangeAttached=rr.Attach(e,"readystatechange",(function(){try{e&&4===e.readyState&&y(e)&&function(e){var n=e.ajaxData;function i(n,i){var r=i||{};r.ajaxDiagnosticsMessage=As(e),n&&(r.exception=io.dump(n)),Bs(t,14,"Failed to calculate the duration of the ajax call, monitoring data for this ajax call won't be sent.",r)}n.responseFinishedTime=ao.Now(),n.status=e.status,C("xmlhttprequest",n,(function(){try{var r=n.CreateTrackItem("Ajax",d,(function(){var t={statusText:e.statusText,headerMap:null,correlationContext:k(e),type:e.responseType,responseText:x(e),response:e.response};if(v){var n=e.getAllResponseHeaders();if(n){var i=nr.strTrim(n).split(/[\r\n]+/),r={};Cs(i,(function(t){var e=t.split(": "),n=e.shift(),i=e.join(": ");r[n]=i})),t.headerMap=r}}return t}));r?t.trackDependencyDataInternal(r):i(null,{requestSentTime:n.requestSentTime,responseFinishedTime:n.responseFinishedTime})}finally{try{e.ajaxData=null}catch(t){}}}),(function(t){i(t,null)}))}(e)}catch(i){var n=io.dump(i);n&&-1!==Es(n.toLowerCase(),"c00c023f")||qs(t,16,"Failed to monitor XMLHttpRequest 'readystatechange' event handler, monitoring data for this ajax call may be incorrect.",{ajaxDiagnosticsMessage:As(e),exception:n})}}))}(e)}(s,n,r,o)},hkErr:js(t,15,"Failed to monitor XMLHttpRequest.open, monitoring data for this ajax call may be incorrect.")}),a(XMLHttpRequest,"send",{req:function(e){var n=e.inst,i=n.ajaxData;y(n)&&!i.xhrMonitoringState.sendDone&&(S("xhr",i),i.requestSentTime=ao.Now(),n=t.includeCorrelationHeaders(i,void 0,void 0,n),i.xhrMonitoringState.sendDone=!0)},hkErr:js(t,17,"Failed to monitor XMLHttpRequest, monitoring data for this ajax call may be incorrect.")}),a(XMLHttpRequest,"abort",{req:function(t){var e=t.inst,n=e.ajaxData;y(e)&&!n.xhrMonitoringState.abortDone&&(n.aborted=1,n.xhrMonitoringState.abortDone=!0)},hkErr:js(t,13,"Failed to monitor XMLHttpRequest.abort, monitoring data for this ajax call may be incorrect.")}),d&&a(XMLHttpRequest,"setRequestHeader",{req:function(t,e,n){var i=t.inst;y(i)&&(i.ajaxData.requestHeaders[e]=n)},hkErr:js(t,71,"Failed to monitor XMLHttpRequest.setRequestHeader, monitoring data for this ajax call may be incorrect.")}),u=!0),function(){var e,n=!(e=ji())||Ss(e.Request)||Ss(e.Request.prototype)||Ss(e.fetch)?null:e.fetch;if(n){var r=ji(),o=n.polyfill;!1===f.disableFetchTracking?(b.push(Jr(r,"fetch",{req:function(e,n,r){var s;if(c&&!w(null,n,r)&&(!o||!u)){var a=e.ctx();s=function(e,n){var r=i&&i.telemetryTrace&&i.telemetryTrace.traceID||io.generateW3CId(),o=io.generateW3CId().substr(0,16),s=new xs(r,o,t.diagLog());s.requestSentTime=ao.Now(),s.requestUrl=e instanceof Request?e?e.url:"":e;var a="GET";n&&n.method?a=n.method:e&&e instanceof Request&&(a=e.method),s.method=a;var c={};return d&&new Headers((n?n.headers:0)||e instanceof Request&&e.headers||{}).forEach((function(t,e){c[e]=t})),s.requestHeaders=c,S("fetch",s),s}(n,r);var l=t.includeCorrelationHeaders(s,n,r);l!==r&&e.set(1,l),a.data=s}},rsp:function(t,e){var n=t.ctx().data;n&&(t.rslt=t.rslt.then((function(t){return A(0,(t||{}).status,t,n,(function(){var e={statusText:t.statusText,headerMap:null,correlationContext:q(t)};if(v){var n={};t.headers.forEach((function(t,e){n[e]=t})),e.headerMap=n}return e})),t})).catch((function(t){throw A(0,0,e,n,null),t})))},hkErr:js(t,15,"Failed to monitor Window.fetch, monitoring data for this fetch call may be incorrect.")})),c=!0):o&&b.push(Jr(r,"fetch",{req:function(t,e,n){w(null,e,n)}})),o&&(r.fetch.polyfill=o)}}(),g.length>0&&g){for(var I=void 0,F=0;!I&&F<g.length;)g[F]&&"AppInsightsPropertiesPlugin"===g[F].identifier&&(I=g[F]),F++;I&&(i=I.context)}}},t.teardown=function(){Cs(b,(function(t){t.rm()})),b=[],c=!1,u=!1,t.setInitialized(!1)},t.trackDependencyData=function(e,n){t.trackDependencyDataInternal(e,n)},t.includeCorrelationHeaders=function(e,n,s,a){var c=t._currentWindowHost||l;if(n){if(oo.canIncludeCorrelationHeader(f,e.getAbsoluteUrl(),c)&&(s||(s={}),s.headers=new Headers(s.headers||n instanceof Request&&n.headers||{}),o&&(s.headers.set(Kr.requestIdHeader,h="|"+e.traceID+"."+e.spanID),d&&(e.requestHeaders[Kr.requestIdHeader]=h)),(p=f.appId||i&&i.appId())&&(s.headers.set(Kr.requestContextHeader,Kr.requestContextAppIdFormat+p),d&&(e.requestHeaders[Kr.requestContextHeader]=Kr.requestContextAppIdFormat+p)),r)){var u=new ks(e.traceID,e.spanID);s.headers.set(Kr.traceParentHeader,u.toString()),d&&(e.requestHeaders[Kr.traceParentHeader]=u.toString())}return s}if(a){var h,p;if(oo.canIncludeCorrelationHeader(f,e.getAbsoluteUrl(),c))o&&(a.setRequestHeader(Kr.requestIdHeader,h="|"+e.traceID+"."+e.spanID),d&&(e.requestHeaders[Kr.requestIdHeader]=h)),(p=f.appId||i&&i.appId())&&(a.setRequestHeader(Kr.requestContextHeader,Kr.requestContextAppIdFormat+p),d&&(e.requestHeaders[Kr.requestContextHeader]=Kr.requestContextAppIdFormat+p)),r&&(u=new ks(e.traceID,e.spanID),a.setRequestHeader(Kr.traceParentHeader,u.toString()),d&&(e.requestHeaders[Kr.traceParentHeader]=u.toString()));return a}},t.trackDependencyDataInternal=function(e,n,i){if(-1===m||h<m){f.distributedTracingMode!==$r.W3C&&f.distributedTracingMode!==$r.AI_AND_W3C||"string"!=typeof e.id||"."===e.id[e.id.length-1]||(e.id+="."),nr.isNullOrUndefined(e.startTime)&&(e.startTime=new Date);var r=Eo.create(e,_o.dataType,_o.envelopeType,t.diagLog(),n,i);t.core.track(r)}else h===m&&qs(t,55,"Maximum ajax per page view limit reached, ajax monitoring is paused until the next trackPageView(). In order to increase the limit set the maxAjaxCallsPerView configuration parameter.",!0);++h}})),n}return __extends(e,t),e.getDefaultConfig=function(){return{maxAjaxCallsPerView:500,disableAjaxTracking:!1,disableFetchTracking:!0,disableCorrelationHeaders:!1,distributedTracingMode:$r.AI,correlationHeaderExcludedDomains:["*.blob.core.windows.net","*.blob.core.chinacloudapi.cn","*.blob.core.cloudapi.de","*.blob.core.usgovcloudapi.net"],correlationHeaderDomains:void 0,appId:void 0,enableCorsCorrelation:!1,enableRequestHeaderTracking:!1,enableResponseHeaderTracking:!1,enableAjaxErrorStatusText:!1,enableAjaxPerfTracking:!1,maxAjaxPerfLookupAttempts:3,ajaxPerfLookupDelay:25}},e.getEmptyConfig=function(){var t=this.getDefaultConfig();return tr(t,(function(e){t[e]=void 0})),t},e.prototype.processTelemetry=function(t,e){this.processNext(t,e)},e.identifier="AjaxDependencyPlugin",e}(Ir),Ps=function(){function t(t){var e=this;e._snippetVersion=""+(t.sv||t.version||""),t.queue=t.queue||[],t.version=t.version||2;var n=t.config||{};if(n.connectionString){var i=uo.parse(n.connectionString),r=i.ingestionendpoint;n.endpointUrl=r?r+"/v2/track":n.endpointUrl,n.instrumentationKey=i.instrumentationkey||n.instrumentationKey}e.appInsights=new Do,e.properties=new ps,e.dependencies=new Fs,e.core=new Lr,e.snippet=t,e.config=n,e.getSKUDefaults()}return t.prototype.trackEvent=function(t,e){this.appInsights.trackEvent(t,e)},t.prototype.trackPageView=function(t){this.appInsights.trackPageView(t||{})},t.prototype.trackPageViewPerformance=function(t){this.appInsights.trackPageViewPerformance(t||{})},t.prototype.trackException=function(t){!t.exception&&t.error&&(t.exception=t.error),this.appInsights.trackException(t)},t.prototype._onerror=function(t){this.appInsights._onerror(t)},t.prototype.trackTrace=function(t,e){this.appInsights.trackTrace(t,e)},t.prototype.trackMetric=function(t,e){this.appInsights.trackMetric(t,e)},t.prototype.startTrackPage=function(t){this.appInsights.startTrackPage(t)},t.prototype.stopTrackPage=function(t,e,n,i){this.appInsights.stopTrackPage(t,e,n,i)},t.prototype.startTrackEvent=function(t){this.appInsights.startTrackEvent(t)},t.prototype.stopTrackEvent=function(t,e,n){this.appInsights.stopTrackEvent(t,e,n)},t.prototype.addTelemetryInitializer=function(t){return this.appInsights.addTelemetryInitializer(t)},t.prototype.setAuthenticatedUserContext=function(t,e,n){void 0===n&&(n=!1),this.properties.context.user.setAuthenticatedUserContext(t,e,n)},t.prototype.clearAuthenticatedUserContext=function(){this.properties.context.user.clearAuthenticatedUserContext()},t.prototype.trackDependencyData=function(t){this.dependencies.trackDependencyData(t)},t.prototype.flush=function(t){var e=this;void 0===t&&(t=!0),Cr(this.core,(function(){return"AISKU.flush"}),(function(){nr.arrForEach(e.core.getTransmissionControls(),(function(e){nr.arrForEach(e,(function(e){e.flush(t)}))}))}),null,t)},t.prototype.onunloadFlush=function(t){void 0===t&&(t=!0),nr.arrForEach(this.core.getTransmissionControls(),(function(e){nr.arrForEach(e,(function(e){e.onunloadFlush?e.onunloadFlush():e.flush(t)}))}))},t.prototype.loadAppInsights=function(t,e,n){var i=this;void 0===t&&(t=!1);var r=this;if(t&&r.config.extensions&&r.config.extensions.length>0)throw new Error("Extensions not allowed in legacy mode");return Cr(r.core,(function(){return"AISKU.loadAppInsights"}),(function(){var o=[],s=new rs;o.push(s),o.push(r.properties),o.push(r.dependencies),o.push(r.appInsights),r.core.initialize(r.config,o,e,n),r.context=r.properties.context,Is&&r.context&&(r.context.internal.sdkSrc=Is),function(e){if(e){var n="";nr.isNullOrUndefined(r._snippetVersion)||(n+=r._snippetVersion),t&&(n+=".lg"),r.context&&r.context.internal&&(r.context.internal.snippetVer=n||"-"),tr(r,(function(t,n){nr.isString(t)&&!nr.isFunction(n)&&"_"!==t.substring(0,1)&&(e[t]=n)}))}}(r.snippet),r.emptyQueue(),r.pollInternalLogs(),r.addHousekeepingBeforeUnload(i)})),r},t.prototype.updateSnippetDefinitions=function(t){tr(this,(function(e,n){nr.isString(e)&&(t[e]=n)}))},t.prototype.emptyQueue=function(){var t=this;try{if(io.isArray(t.snippet.queue)){for(var e=t.snippet.queue.length,n=0;n<e;n++)(0,t.snippet.queue[n])();t.snippet.queue=void 0,delete t.snippet.queue}}catch(t){t&&nr.isFunction(t.toString)&&t.toString()}},t.prototype.pollInternalLogs=function(){this.core.pollInternalLogs()},t.prototype.addHousekeepingBeforeUnload=function(t){if(Ii()||Pi()){var e=function(){t.onunloadFlush(!1);var e=t.appInsights.core._extensions.AppInsightsPropertiesPlugin;e&&e.context&&e.context._sessionManager&&e.context._sessionManager.backup()};if(!t.appInsights.config.disableFlushOnBeforeUnload){var n=nr.addEventHandler("beforeunload",e);(n=nr.addEventHandler("pagehide",e)||n)||(i=Mi())&&i.product&&"ReactNative"===i.product||t.appInsights.core.logger.throwInternal(er.CRITICAL,19,"Could not add handler for beforeunload and pagehide")}t.appInsights.config.disableFlushOnUnload||nr.addEventHandler("pagehide",e)}var i},t.prototype.getSKUDefaults=function(){var t=this;t.config.diagnosticLogInterval=t.config.diagnosticLogInterval&&t.config.diagnosticLogInterval>0?t.config.diagnosticLogInterval:1e4},t}();
11
11
  /*!
12
12
  * Application Insights JavaScript SDK - Web, 2.5.10
13
13
  * Copyright (c) Microsoft and contributors. All rights reserved.
14
- */!function(){var t=null,e=["://js.monitor.azure.com/","://az416426.vo.msecnd.net/"];try{var n=(document||{}).currentScript;n&&(t=n.src)}catch(t){}if(t)try{var i=t.toLowerCase();if(i)for(var r="",o=0;o<e.length;o++)if(-1!==i.indexOf(e[o])){r="cdn"+(o+1),-1===i.indexOf("/scripts/")&&(-1!==i.indexOf("/next/")?r+="-next":-1!==i.indexOf("/beta/")&&(r+="-beta")),Is=r+"";break}}catch(t){}}();const Rs=new class extends w{constructor(t){super(t),this.store=t,this.appConfiguration$=this.select((t=>t.appConfiguration))}get configuration(){const t=this.getValue().appConfiguration;if(O(t))throw Error("App configuration is not yet loaded");return t.value}}(ln),Ms=new class{constructor(){this.appInsights=new H((()=>new Ps({config:{instrumentationKey:Rs.configuration.AppInsightsKey,enableAutoRouteTracking:!0,autoTrackPageVisitTime:!0,maxBatchInterval:1e3,enableUnhandledPromiseRejectionTracking:!0}})))}init(){this.appInsights.value.loadAppInsights(),u((t=>this.appInsightsErrorHandler(t)))}getAppInsights(){return this.appInsights.value}addCustomProperties(t){this.appInsights.value.addTelemetryInitializer((e=>{e.data=e.data?e.data:{};for(const[n,i]of Object.entries(t))e.data[n]=i}))}appInsightsErrorHandler(t){this.appInsights.value.trackException({error:t,severityLevel:yo.Error}),(t=>{console.error(t)})(t)}},Ts=new class extends w{constructor(t){super(t),this.store=t,this.sessionState$=this.select((t=>t.authenticationState)),this.jwt$=this.select((t=>t.jwt))}get sessionState(){return this.getValue().authenticationState}get isUnauthorized(){return this.getValue().authenticationState===an.Unauthorized||this.getValue().authenticationState===an.Error}get isAuthorized(){return this.getValue().authenticationState===an.Authenticated}}(ln),Ns=new class{constructor(){this.authCodeQueryParameter="code"}authorizationCodeIsPresent(t){const e=this.getAuthorizationCodeFromRoute(t);return Et.isSome(e)}initFromRoute(t){const e=this.getAuthorizationCodeFromRoute(t);if(Et.isNone(e))throw ln.update({authenticationState:an.Error}),Error(`"${this.authCodeQueryParameter}" URL query parameter missing`);this.authCodeExchangeAsync(e.value)}async authCodeExchangeAsync(t){const e=new URLSearchParams([["grant_type","authorization_code"],["client_id","apollo-super-selection-app"],["code",t],["redirect_uri",""+ki.getAppHostUrl()]]),n=await Xt(Rs.configuration.OidcAuthority+"/connect/token").headers({"Content-Type":"application/x-www-form-urlencoded"}).post(e.toString()).badRequest((()=>{throw ln.update({authenticationState:an.Error}),new Error("Failed to authenticate.")})).json();ln.update({jwt:Et.fromNullable(n.access_token),authenticationState:an.Authenticated}),window.gtag&&window.gtag("event","oidc_sign_in",{}),window.history.replaceState(null,"",ki.getAppRootUrl())}getAuthorizationCodeFromRoute(t){const e=new URLSearchParams(t);return Et.fromNullable(e.get(this.authCodeQueryParameter))}};class Ds{static completeSuperSelectionStep(){const{successRedirectionUrl:t}=fn.getIframeInteropMode();Et.isSome(t)?window.top.location.href=t.value:St()}static initFromRoute(t){const e=new URLSearchParams(t),n=Et.fromNullable(e.get("success-redirection-url")),i={successRedirectionUrl:Et.none};if(Et.isSome(n))try{const t=new URL(n.value);i.successRedirectionUrl=Et.some(t.toString())}catch(t){throw Error(`"${n.value}" is not a valid URL`)}return i}}class Os{static init(){if(void 0===window.ReactNativeWebView)throw Error("React Native WebView messaging is not enabled. Please, refer to https://github.com/react-native-webview/react-native-webview/blob/master/docs/Guide.md#the-windowreactnativewebviewpostmessage-method-and-onmessage-prop");return new cn}static completeSuperSelectionStep(){this.postRNMessage()}static postRNMessage(){Os.getRnInterop().postMessage(JSON.stringify({stepStatus:"completed"}))}}Os.getRnInterop=()=>window.ReactNativeWebView;const Us=new class{constructor(){this.interopModeQueryParameter="interop-mode"}completeSuperSelectionStep(){if(fn.isIframeInteropEnabled())Ds.completeSuperSelectionStep();else{if(!fn.isReactNativeInteropEnabled())throw Error("Unknown interop mode");Os.completeSuperSelectionStep()}}init(t){const e=z(new URLSearchParams(t).get(this.interopModeQueryParameter));D(e)&&"react-native"===e.value?ln.update({reactNativeInterop:L(Os.init())}):ln.update({iframeInterop:L(Ds.initFromRoute(t))})}};const Ls=class{constructor(e){t(this,e),this.areStylesLoaded=!1}async componentWillLoad(){await async function(){await ki.loadConfigurationAsync(),Ms.init(),function(){if(!window.location.pathname.endsWith("/")){const t=window.location.pathname+"/"+window.location.search+window.location.hash;history.pushState(history.state,"",t)}}(),(Ts.isUnauthorized||Ns.authorizationCodeIsPresent(window.location.search))&&(Us.init(window.location.search),Ns.initFromRoute(window.location.search))}(),Ts.sessionState$.subscribe((t=>this.sessionState=t)),Ts.jwt$.subscribe((t=>this.jwt=t)),Rs.appConfiguration$.subscribe((t=>this.appConfiguration=t))}render(){return Et.isNone(this.appConfiguration)?e("sss-loading-page",null):e(o,{class:"d-flex flex-fill flex-column justify-content-between"},this.fetchStyles(),this.areStylesLoaded&&this.renderAppContent())}fetchStyles(){return[e("link",{rel:"stylesheet",href:"https://npm-cdn.flarehr.com/@flarehr/beacon@dev/dist/beacon/beacon.css",media:"all",onLoad:()=>this.areStylesLoaded=!0})]}renderAppContent(){return e("stencil-router",{root:ki.getAppRootUrl(),class:"sss-app-container"},e("stencil-route-switch",{scrollTopOffset:0},e("stencil-route",{ref:t=>this.observeContentResize(t),url:"/",routeRender:this.renderProtectedRoute((t=>e("super-selection-app",Object.assign({accessToken:Et.toUndefined(this.jwt),backendUrl:Rs.configuration.ApiBaseUrl,appBaseUrl:this.getAppBaseUrl(),onSuccessPageAcknowledged:this.handleSuccessPageAcknowledged,"onStep-completion":this.handleStepSubmitSuccess,onInitialised:this.handleAppInitialised},t))))})))}getAppBaseUrl(){return window.location.pathname.split("app")[0]+"app/"}handleSuccessPageAcknowledged(){Us.completeSuperSelectionStep()}handleStepSubmitSuccess(){Ct()}handleAppInitialised(t){Ms.addCustomProperties({"X-ACCOUNT-ID":t.detail.accountIdOrDefault,"X-PARTNER-ID":t.detail.partnerIdOrDefault,"X-PROFILE-ID":t.detail.profileId}),Ms.getAppInsights().trackPageView();const e=document.getElementById("sss-external-loading-page-container");e&&document.body.removeChild(e)}observeContentResize(t){new(window.ResizeObserver||xi)((()=>{xt(t.offsetHeight,-1)})).observe(t)}renderProtectedRoute(t){switch(this.sessionState){case an.Authenticated:return t;case an.Unauthorized:return()=>e("sss-loading-page",null);case an.Error:return()=>e("h1",null,"Authentication Error")}}};Ls.style="html{scroll-behavior:smooth}img.fluid-fit{-o-object-fit:cover;object-fit:cover}.sss-app-container{--fl-color-primary:#00aa65;--fl-color-primary-light:#66d7a9;--fl-color-primary-dark:#00aa65;--fl-color-primary-disabled:#66d7a9;--fl-color-primary-hover:#00aa65;--fl-color-primary-focus:#00aa65;--fl-color-primary-text:white;--fl-color-secondary:#e5e5e5;--fl-color-secondary-hover:#b3b3b3;--fl-color-secondary-focus:#b3b3b3}@media screen and (-webkit-min-device-pixel-ratio: 0){select,textarea,input{font-size:16px}}";export{ft as fl_button,pt as fl_dropdown,mt as fl_dropdown_async,vt as fl_loading_indicator,gt as fl_promise_button,ae as sss_custom_fund,pe as sss_default_fund,me as sss_footer_section,ve as sss_loading_page,be as sss_my_own_fund,ge as sss_my_own_fund_inputs,we as sss_notifications_section,ke as sss_promoted_fund_join_page,Ce as sss_promoted_fund_standard_choice_page,Ie as sss_qsuper_confirm_header,Oe as sss_qsuper_consent,ze as sss_qsuper_insurance_opt_in,He as sss_qsuper_insurance_questions,Ve as sss_qsuper_join,We as sss_qsuper_layout,$e as sss_qsuper_question_1,Ye as sss_qsuper_question_2,Xe as sss_qsuper_question_3,Je as sss_qsuper_question_4,Ge as sss_qsuper_question_5,Ke as sss_qsuper_question_6,Ze as sss_qsuper_question_7,tn as sss_qsuper_question_8,en as sss_qsuper_question_yes_no_buttons,nn as sss_selected_super_choice_section,rn as sss_self_managed_fund,sn as sss_self_managed_fund_inputs,pn as sss_slate_join_page,vn as sss_slate_standard_choice_page,bn as sss_slatesuper_header,gn as sss_smsf_not_supported_dialog,wn as sss_standard_choice_form,yn as sss_success,xn as sss_super_choice_item,Sn as sss_super_choice_page,Cn as stencil_route,qn as stencil_route_link,jn as stencil_route_switch,Tn as stencil_router,Nn as super_selection_app,Ls as super_selection_app_host}
14
+ */!function(){var t=null,e=["://js.monitor.azure.com/","://az416426.vo.msecnd.net/"];try{var n=(document||{}).currentScript;n&&(t=n.src)}catch(t){}if(t)try{var i=t.toLowerCase();if(i)for(var r="",o=0;o<e.length;o++)if(-1!==i.indexOf(e[o])){r="cdn"+(o+1),-1===i.indexOf("/scripts/")&&(-1!==i.indexOf("/next/")?r+="-next":-1!==i.indexOf("/beta/")&&(r+="-beta")),Is=r+"";break}}catch(t){}}();const Ts=new class extends w{constructor(t){super(t),this.store=t,this.appConfiguration$=this.select((t=>t.appConfiguration))}get configuration(){const t=this.getValue().appConfiguration;if(O(t))throw Error("App configuration is not yet loaded");return t.value}}(ln),Ms=new class{constructor(){this.appInsights=new V((()=>new Ps({config:{instrumentationKey:Ts.configuration.AppInsightsKey,enableAutoRouteTracking:!0,autoTrackPageVisitTime:!0,maxBatchInterval:1e3,enableUnhandledPromiseRejectionTracking:!0}})))}init(){this.appInsights.value.loadAppInsights(),u((t=>this.appInsightsErrorHandler(t)))}getAppInsights(){return this.appInsights.value}addCustomProperties(t){this.appInsights.value.addTelemetryInitializer((e=>{e.data=e.data?e.data:{};for(const[n,i]of Object.entries(t))e.data[n]=i}))}appInsightsErrorHandler(t){this.appInsights.value.trackException({error:t,severityLevel:yo.Error}),(t=>{console.error(t)})(t)}},Rs=new class extends w{constructor(t){super(t),this.store=t,this.sessionState$=this.select((t=>t.authenticationState)),this.jwt$=this.select((t=>t.jwt))}get sessionState(){return this.getValue().authenticationState}get isUnauthorized(){return this.getValue().authenticationState===an.Unauthorized||this.getValue().authenticationState===an.Error}get isAuthorized(){return this.getValue().authenticationState===an.Authenticated}}(ln),Ns=new class{constructor(){this.authCodeQueryParameter="code"}authorizationCodeIsPresent(t){const e=this.getAuthorizationCodeFromRoute(t);return Et.isSome(e)}initFromRoute(t){const e=this.getAuthorizationCodeFromRoute(t);if(Et.isNone(e))throw ln.update({authenticationState:an.Error}),Error(`"${this.authCodeQueryParameter}" URL query parameter missing`);this.authCodeExchangeAsync(e.value)}async authCodeExchangeAsync(t){const e=new URLSearchParams([["grant_type","authorization_code"],["client_id","apollo-super-selection-app"],["code",t],["redirect_uri",""+ki.getAppHostUrl()]]),n=await Xt(Ts.configuration.OidcAuthority+"/connect/token").headers({"Content-Type":"application/x-www-form-urlencoded"}).post(e.toString()).badRequest((()=>{throw ln.update({authenticationState:an.Error}),new Error("Failed to authenticate.")})).json();ln.update({jwt:Et.fromNullable(n.access_token),authenticationState:an.Authenticated}),window.gtag&&window.gtag("event","oidc_sign_in",{}),window.history.replaceState(null,"",ki.getAppRootUrl())}getAuthorizationCodeFromRoute(t){const e=new URLSearchParams(t);return Et.fromNullable(e.get(this.authCodeQueryParameter))}};class Ds{static completeSuperSelectionStep(){const{successRedirectionUrl:t}=fn.getIframeInteropMode();Et.isSome(t)?window.top.location.href=t.value:St()}static initFromRoute(t){const e=new URLSearchParams(t),n=Et.fromNullable(e.get("success-redirection-url")),i={successRedirectionUrl:Et.none};if(Et.isSome(n))try{const t=new URL(n.value);i.successRedirectionUrl=Et.some(t.toString())}catch(t){throw Error(`"${n.value}" is not a valid URL`)}return i}}class Os{static init(){if(void 0===window.ReactNativeWebView)throw Error("React Native WebView messaging is not enabled. Please, refer to https://github.com/react-native-webview/react-native-webview/blob/master/docs/Guide.md#the-windowreactnativewebviewpostmessage-method-and-onmessage-prop");return new cn}static completeSuperSelectionStep(){this.postRNMessage()}static postRNMessage(){Os.getRnInterop().postMessage(JSON.stringify({stepStatus:"completed"}))}}Os.getRnInterop=()=>window.ReactNativeWebView;const Us=new class{constructor(){this.interopModeQueryParameter="interop-mode"}completeSuperSelectionStep(){if(fn.isIframeInteropEnabled())Ds.completeSuperSelectionStep();else{if(!fn.isReactNativeInteropEnabled())throw Error("Unknown interop mode");Os.completeSuperSelectionStep()}}init(t){const e=z(new URLSearchParams(t).get(this.interopModeQueryParameter));D(e)&&"react-native"===e.value?ln.update({reactNativeInterop:L(Os.init())}):ln.update({iframeInterop:L(Ds.initFromRoute(t))})}};const Ls=class{constructor(e){t(this,e),this.areStylesLoaded=!1}async componentWillLoad(){await async function(){await ki.loadConfigurationAsync(),Ms.init(),function(){if(!window.location.pathname.endsWith("/")){const t=window.location.pathname+"/"+window.location.search+window.location.hash;history.pushState(history.state,"",t)}}(),(Rs.isUnauthorized||Ns.authorizationCodeIsPresent(window.location.search))&&(Us.init(window.location.search),Ns.initFromRoute(window.location.search))}(),Rs.sessionState$.subscribe((t=>this.sessionState=t)),Rs.jwt$.subscribe((t=>this.jwt=t)),Ts.appConfiguration$.subscribe((t=>this.appConfiguration=t))}render(){return Et.isNone(this.appConfiguration)?e("sss-loading-page",null):e(o,{class:"d-flex flex-fill flex-column justify-content-between"},this.fetchStyles(),this.areStylesLoaded&&this.renderAppContent())}fetchStyles(){return[e("link",{rel:"stylesheet",href:"https://npm-cdn.flarehr.com/@flarehr/beacon@dev/dist/beacon/beacon.css",media:"all",onLoad:()=>this.areStylesLoaded=!0})]}renderAppContent(){return e("stencil-router",{root:ki.getAppRootUrl(),class:"sss-app-container"},e("stencil-route-switch",{scrollTopOffset:0},e("stencil-route",{ref:t=>this.observeContentResize(t),url:"/",routeRender:this.renderProtectedRoute((t=>e("super-selection-app",Object.assign({accessToken:Et.toUndefined(this.jwt),backendUrl:Ts.configuration.ApiBaseUrl,appBaseUrl:this.getAppBaseUrl(),onSuccessPageAcknowledged:this.handleSuccessPageAcknowledged,"onStep-completion":this.handleStepSubmitSuccess,onInitialised:this.handleAppInitialised},t))))})))}getAppBaseUrl(){return window.location.pathname.split("app")[0]+"app/"}handleSuccessPageAcknowledged(){Us.completeSuperSelectionStep()}handleStepSubmitSuccess(){Ct()}handleAppInitialised(t){Ms.addCustomProperties({"X-ACCOUNT-ID":t.detail.accountIdOrDefault,"X-PARTNER-ID":t.detail.partnerIdOrDefault,"X-PROFILE-ID":t.detail.profileId}),Ms.getAppInsights().trackPageView();const e=document.getElementById("sss-external-loading-page-container");e&&document.body.removeChild(e)}observeContentResize(t){new(window.ResizeObserver||xi)((()=>{xt(t.offsetHeight,-1)})).observe(t)}renderProtectedRoute(t){switch(this.sessionState){case an.Authenticated:return t;case an.Unauthorized:return()=>e("sss-loading-page",null);case an.Error:return()=>e("h1",null,"Authentication Error")}}};Ls.style="html{scroll-behavior:smooth}img.fluid-fit{-o-object-fit:cover;object-fit:cover}.sss-app-container{--fl-color-primary:#00aa65;--fl-color-primary-light:#66d7a9;--fl-color-primary-dark:#00aa65;--fl-color-primary-disabled:#66d7a9;--fl-color-primary-hover:#00aa65;--fl-color-primary-focus:#00aa65;--fl-color-primary-text:white;--fl-color-secondary:#e5e5e5;--fl-color-secondary-hover:#b3b3b3;--fl-color-secondary-focus:#b3b3b3}@media screen and (-webkit-min-device-pixel-ratio: 0){select,textarea,input{font-size:16px}}";export{ft as fl_button,pt as fl_dropdown,mt as fl_dropdown_async,vt as fl_loading_indicator,gt as fl_promise_button,ae as sss_custom_fund,pe as sss_default_fund,me as sss_footer_section,ve as sss_loading_page,be as sss_my_own_fund,ge as sss_my_own_fund_inputs,we as sss_notifications_section,ke as sss_promoted_fund_join_page,Ce as sss_promoted_fund_standard_choice_page,Ie as sss_qsuper_confirm_header,Oe as sss_qsuper_consent,ze as sss_qsuper_insurance_opt_in,Ve as sss_qsuper_insurance_questions,He as sss_qsuper_join,We as sss_qsuper_layout,$e as sss_qsuper_question_1,Ye as sss_qsuper_question_2,Xe as sss_qsuper_question_3,Je as sss_qsuper_question_4,Ge as sss_qsuper_question_5,Ke as sss_qsuper_question_6,Ze as sss_qsuper_question_7,tn as sss_qsuper_question_8,en as sss_qsuper_question_yes_no_buttons,nn as sss_selected_super_choice_section,rn as sss_self_managed_fund,sn as sss_self_managed_fund_inputs,pn as sss_slate_join_page,vn as sss_slate_standard_choice_page,bn as sss_slatesuper_header,gn as sss_smsf_not_supported_dialog,wn as sss_standard_choice_form,yn as sss_success,xn as sss_super_choice_item,Sn as sss_super_choice_page,Cn as stencil_route,qn as stencil_route_link,jn as stencil_route_switch,Rn as stencil_router,Nn as super_selection_app,Ls as super_selection_app_host}