userflow.js-self-hosted 0.1.1011597 → 0.1.1011632

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/hash.txt CHANGED
@@ -1 +1 @@
1
- daab92443baed8c1798ae9f4c954255c0fa8e0d1
1
+ 1bb47edf388757908b269923814987c323ff7dd4
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "userflow.js-self-hosted",
3
- "version": "0.1.1011597",
3
+ "version": "0.1.1011632",
4
4
  "description": "Self-hosted version of Userflow.js",
5
5
  "main": "userflow.js"
6
6
  }
package/userflow.js CHANGED
@@ -1,7 +1,7 @@
1
1
  const __vite__mapDeps=(i,m=__vite__mapDeps,d=(m.f||(m.f=["ResourceCenterApp.js","vendor.react.js","vendor.absinthe.socket.js","vendor.jumpn.utils-composite.js","vendor.babel-runtime.js","vendor.jumpn.utils-array.js","vendor.flow-static-land.js","vendor.core-js.js","vendor.jumpn.utils-graphql.js","vendor.zen-observable.js","vendor.object-assign.js","client-context.js","vendor.i18next.js","vendor.react-i18next.js","vendor.babel.runtime.js","flow-host.styl.js","use-selector-element-monitoring.js","flow-condition-types.js","vendor.date-fns.js","roots.js","stylesheets.js","vendor.fortawesome.pro-regular-svg-icons.js","vendor.fortawesome.pro-solid-svg-icons.js","vendor.obj-str.js","Frame.js","vendor.react-dom.js","vendor.scheduler.js","use-window-resize.js","logomark.js","ChecklistUI.js","FlowChrome.js","use-element-rect.js","vendor.bignumber.js.js","index.js","BannerApp.js","vendor.phoenix.js","vendor.uuid.js","implicit-tracking.js","DebuggerUI.js","vendor.fortawesome.react-fontawesome.js","vendor.fortawesome.fontawesome-svg-core.js","vendor.memoize-one.js","vendor.numeral.js","vendor.react-day-picker.js","vendor.lodash.js","vendor.isomorphic-fetch.js","vendor.whatwg-fetch.js","vendor.apollo.client.js","vendor.ts-invariant.js","vendor.wry.equality.js","vendor.graphql.js","vendor.optimism.js","vendor.wry.trie.js","vendor.wry.context.js","vendor.fast-json-stable-stringify.js","ui.js"])))=>i.map(i=>d[i]);
2
2
  import"./vendor.core-js.js";import"./vendor.absinthe.socket.js";import{S as j}from"./vendor.phoenix.js";import{v as p}from"./vendor.uuid.js";import"./vendor.jumpn.utils-composite.js";import"./vendor.babel-runtime.js";import"./vendor.jumpn.utils-array.js";import"./vendor.flow-static-land.js";import"./vendor.jumpn.utils-graphql.js";import"./vendor.zen-observable.js";(function(){try{var t=typeof window<"u"?window:typeof global<"u"?global:typeof self<"u"?self:{},e=new Error().stack;e&&(t._sentryDebugIds=t._sentryDebugIds||{},t._sentryDebugIds[e]="09bc9f5f-47a6-4109-b7f0-af4bb18bf647",t._sentryDebugIdIdentifier="sentry-dbid-09bc9f5f-47a6-4109-b7f0-af4bb18bf647")}catch{}})();const Y="modulepreload",z=function(t){return new URL("./",import.meta.url).toString()+t},v={},g=function(e,s,i){let n=Promise.resolve();if(s&&s.length>0){document.getElementsByTagName("link");const a=document.querySelector("meta[property=csp-nonce]"),h=a?.nonce||a?.getAttribute("nonce");n=Promise.allSettled(s.map(c=>{if(c=z(c),c in v)return;v[c]=!0;const l=c.endsWith(".css"),T=l?'[rel="stylesheet"]':"";if(document.querySelector(`link[href="${c}"]${T}`))return;const E=document.createElement("link");if(E.rel=l?"stylesheet":Y,l||(E.as="script"),E.crossOrigin="",E.href=c,h&&E.setAttribute("nonce",h),document.head.appendChild(E),l)return new Promise((K,F)=>{E.addEventListener("load",K),E.addEventListener("error",()=>F(new Error(`Unable to preload CSS for ${c}`)))})}))}function r(a){const h=new Event("vite:preloadError",{cancelable:!0});if(h.payload=a,window.dispatchEvent(h),!h.defaultPrevented)throw a}return n.then(a=>{for(const h of a||[])h.status==="rejected"&&r(h.reason);return e().catch(r)})};class u extends Error{constructor(e,s,i){super(e),Object.setPrototypeOf(this,u.prototype),this.name="UserflowError",this.code=s,this.humanMessage=i}}class B{constructor(e){this.type=e,this.testState={}}formatKey(e){return`userflow:${e}`}isSupported(){if(typeof window>"u")return!1;try{return window[this.type]!=null}catch{return!1}}getItem(e){return e=this.formatKey(e),this.isSupported()?window[this.type].getItem(e):null}setItem(e,s){e=this.formatKey(e);{if(!this.isSupported())return;window[this.type].setItem(e,s)}}removeItem(e){return e=this.formatKey(e),this.isSupported()?window[this.type].removeItem(e):void 0}clear(){return this.isSupported()?window[this.type].clear():void 0}}const I=new B("localStorage"),f=new B("sessionStorage");function at(t){window.location.href=t}function x(){return window.location.href}function N(t){window.postMessage(t,window.origin)}function G(t){const e=i=>{if(i.source!==window||i.origin!==window.origin)return;const n=i.data;!n||typeof n!="object"||typeof n.kind!="string"||!n.kind.startsWith("userflow:")||t(n)===!0&&s()};window.addEventListener("message",e);const s=()=>window.removeEventListener("message",e);return s}function J(t){return new Promise(e=>{G(s=>{const i=t(s);return i?(e(i),!0):!1})})}const A=new Set;let O=!1;function X(t){return Q(),A.add(t),()=>{H(t)}}function H(t){A.delete(t)}function w(){A.forEach(t=>t())}function Q(){if(O)return;O=!0;const{history:t}=window,e=s=>{const i=t[s];t[s]=(...n)=>{const r=i.apply(t,n);return w(),r}};window.__userflowStatePatched?(window.addEventListener("userflow:pushstate",()=>{w()}),window.addEventListener("userflow:replacestate",()=>{w()})):(e("pushState"),e("replaceState")),window.addEventListener("popstate",()=>{w()})}class Z{destroy(){this.unregisterOnMessage&&this.unregisterOnMessage()}postBuilderMessage(e){N({kind:"userflow:crxSendProxyMessage",direction:"targetToBuilder",message:e})}onBuilderMessage(e){return this.unregisterOnMessage=G(e),!1}async captureScreenshot(e,s,i,n){return N({kind:"userflow:crxScreenshot",x:e,y:s,width:i,height:n,devicePixelRatio:window.devicePixelRatio}),(await J(a=>a.kind==="userflow:crxScreenshotResult"?a:null)).imageDataUrl}}var C=(t=>(t.ACTION="ACTION",t.LAUNCHER_DEACTIVATED="LAUNCHER_DEACTIVATED",t.REPLACED="REPLACED",t.SNOOZED="SNOOZED",t.TOOLTIP_TARGET_MISSING="TOOLTIP_TARGET_MISSING",t.USERFLOWJS="USERFLOWJS",t.USER_CLOSED="USER_CLOSED",t))(C||{}),m=(t=>(t.ACTION="ACTION",t.DRAFT="DRAFT",t.LINK="LINK",t.LAUNCHER_SEEN="LAUNCHER_SEEN",t.RESOURCE_CENTER="RESOURCE_CENTER",t.USERFLOWJS="USERFLOWJS",t))(m||{}),q=(t=>(t.LIKE="LIKE",t.DISLIKE="DISLIKE",t))(q||{}),S=(t=>(t.STRING="STRING",t.BOOLEAN="BOOLEAN",t.NUMBER="NUMBER",t.DATETIME="DATETIME",t.LIST="LIST",t.RANDOM_AB="RANDOM_AB",t.RANDOM_NUMBER="RANDOM_NUMBER",t.CHECKLIST_TASK="CHECKLIST_TASK",t.FLOW="FLOW",t.FLOW_SESSION="FLOW_SESSION",t.FLOW_STEP="FLOW_STEP",t.FLOW_VERSION="FLOW_VERSION",t))(S||{}),k=(t=>(t.FLOW="FLOW",t.BANNER="BANNER",t.EMBED="EMBED",t.CHECKLIST="CHECKLIST",t.LAUNCHER="LAUNCHER",t.RESOURCE_CENTER="RESOURCE_CENTER",t))(k||{}),ee=(t=>(t.ALWAYS_TRUE="ALWAYS_TRUE",t.ATTRIBUTE="ATTRIBUTE",t.CHECKLIST_TASK_CLICKED="CHECKLIST_TASK_CLICKED",t.CLAUSE="CLAUSE",t.ELEMENT="ELEMENT",t.EVENT="EVENT",t.FILLED_IN_INPUT="FILLED_IN_INPUT",t.FLOW="FLOW",t.INPUT_VALUE="INPUT_VALUE",t.PAGE="PAGE",t.SEGMENT="SEGMENT",t.TIME="TIME",t))(ee||{}),te=(t=>(t.AUTO="AUTO",t.MANUAL="MANUAL",t))(te||{}),se=(t=>(t.INPUT="INPUT",t))(se||{}),ie=(t=>(t.ABSOLUTE_EQ="ABSOLUTE_EQ",t.ABSOLUTE_GT="ABSOLUTE_GT",t.ABSOLUTE_LT="ABSOLUTE_LT",t.AND="AND",t.BETWEEN="BETWEEN",t.CONTAINS="CONTAINS",t.EMPTY="EMPTY",t.ENDS_WITH="ENDS_WITH",t.EQ="EQ",t.EXCLUDES_ALL="EXCLUDES_ALL",t.EXCLUDES_ANY="EXCLUDES_ANY",t.FALSE="FALSE",t.GT="GT",t.GTE="GTE",t.INCLUDES_ALL="INCLUDES_ALL",t.INCLUDES_ANY="INCLUDES_ANY",t.LT="LT",t.LTE="LTE",t.NE="NE",t.NOT_CONTAINS="NOT_CONTAINS",t.NOT_EMPTY="NOT_EMPTY",t.NOT_REGEX="NOT_REGEX",t.OR="OR",t.REGEX="REGEX",t.RELATIVE_EQ="RELATIVE_EQ",t.RELATIVE_GT="RELATIVE_GT",t.RELATIVE_LT="RELATIVE_LT",t.STARTS_WITH="STARTS_WITH",t.TRUE="TRUE",t.URL="URL",t))(ie||{}),ne=(t=>(t.CLICK="CLICK",t.DISABLED="DISABLED",t.MOUSEDOWN="MOUSEDOWN",t.NOT_CLICK="NOT_CLICK",t.NOT_DISABLED="NOT_DISABLED",t.NOT_PRESENT="NOT_PRESENT",t.PRESENT="PRESENT",t))(ne||{}),re=(t=>(t.END_USER="END_USER",t.GROUP="GROUP",t))(re||{}),oe=(t=>(t.BETWEEN="BETWEEN",t.EQ="EQ",t.GTE="GTE",t.LTE="LTE",t))(oe||{}),ae=(t=>(t.ANY="ANY",t.RELATIVE_BETWEEN="RELATIVE_BETWEEN",t.RELATIVE_GT="RELATIVE_GT",t.RELATIVE_LT="RELATIVE_LT",t))(ae||{}),ce=(t=>(t.CURRENT_USER="CURRENT_USER",t.CURRENT_USER_CURRENT_GROUP="CURRENT_USER_CURRENT_GROUP",t.CURRENT_GROUP="CURRENT_GROUP",t))(ce||{}),le=(t=>(t.ASSET="ASSET",t.CARTOON="CARTOON",t.NONE="NONE",t.URL="URL",t))(le||{}),ue=(t=>(t.INSIDE="INSIDE",t.OUTSIDE="OUTSIDE",t))(ue||{}),he=(t=>(t.TOP_LEFT="TOP_LEFT",t.TOP_CENTER="TOP_CENTER",t.TOP_RIGHT="TOP_RIGHT",t.BOTTOM_RIGHT="BOTTOM_RIGHT",t.BOTTOM_CENTER="BOTTOM_CENTER",t.BOTTOM_LEFT="BOTTOM_LEFT",t.CENTER="CENTER",t))(he||{}),de=(t=>(t.GOOGLE="GOOGLE",t.STANDARD="STANDARD",t))(de||{}),fe=(t=>(t.DISMISS_FIRST_MENU_AFTER="DISMISS_FIRST_MENU_AFTER",t.DISMISS="DISMISS",t))(fe||{}),Ee=(t=>(t.DISMISS="DISMISS",t.NONE="NONE",t))(Ee||{}),Se=(t=>(t.TOP="TOP",t.BOTTOM="BOTTOM",t))(Se||{}),Te=(t=>(t.DEFAULT="DEFAULT",t.PLAINTEXT="PLAINTEXT",t.CUSTOM="CUSTOM",t))(Te||{}),ge=(t=>(t.CHECKLIST_OVERRIDE="CHECKLIST_OVERRIDE",t.RESOURCE_CENTER_ONLY="RESOURCE_CENTER_ONLY",t.NONE="NONE",t))(ge||{}),Ie=(t=>(t.BUBBLE="BUBBLE",t.END="END",t.ERROR="ERROR",t.FLAG="FLAG",t))(Ie||{}),we=(t=>(t.MANUAL="MANUAL",t.NONE="NONE",t.SYNTHETIC="SYNTHETIC",t))(we||{}),Ce=(t=>(t.BUBBLE="BUBBLE",t.HIDDEN="HIDDEN",t.MODAL="MODAL",t.TOOLTIP="TOOLTIP",t))(Ce||{}),ke=(t=>(t.ABOVE="ABOVE",t.BELOW="BELOW",t.LEFT="LEFT",t.RIGHT="RIGHT",t))(ke||{}),me=(t=>(t.CLOSE_FLOW="CLOSE_FLOW",t.EVAL_JS="EVAL_JS",t.GO_TO_STEP="GO_TO_STEP",t.NAVIGATE="NAVIGATE",t.SET_ATTRIBUTE="SET_ATTRIBUTE",t.SNOOZE="SNOOZE",t.START_FLOW="START_FLOW",t))(me||{}),pe=(t=>(t.NEW_TAB="NEW_TAB",t.SAME_TAB="SAME_TAB",t))(pe||{}),Ue=(t=>(t.SET="SET",t.SET_DATETIME="SET_DATETIME",t.SET_DATETIME_ONCE="SET_DATETIME_ONCE",t.SET_ONCE="SET_ONCE",t.ADD="ADD",t.SUBTRACT="SUBTRACT",t.APPEND="APPEND",t.PREPEND="PREPEND",t.REMOVE="REMOVE",t.UNSET="UNSET",t))(Ue||{}),Le=(t=>(t.MULTILINE_TEXT="MULTILINE_TEXT",t.MULTIPLE_CHOICE="MULTIPLE_CHOICE",t.NPS="NPS",t.SCALE="SCALE",t.STARS="STARS",t.TEXT="TEXT",t))(Le||{}),_=(t=>(t.ACTION="ACTION",t.ANNOUNCEMENTS="ANNOUNCEMENTS",t.ASSISTANT="ASSISTANT",t.CHECKLIST="CHECKLIST",t.CONTACT="CONTACT",t.DIVIDER="DIVIDER",t.FLOWS="FLOWS",t.KNOWLEDGE_BASE="KNOWLEDGE_BASE",t.MESSAGE="MESSAGE",t.SUBPAGE="SUBPAGE",t))(_||{}),Ne=(t=>(t.CRISP="CRISP",t.CUSTOM="CUSTOM",t.FRESHCHAT="FRESHCHAT",t.HELPSCOUT="HELPSCOUT",t.HUBSPOT="HUBSPOT",t.INTERCOM="INTERCOM",t.ZENDESK="ZENDESK",t.ZENDESK_MESSENGER="ZENDESK_MESSENGER",t))(Ne||{}),_e=(t=>(t.BUTTON="BUTTON",t.INPUT="INPUT",t))(_e||{}),Ae=(t=>(t.EMAIL="EMAIL",t.PHONE="PHONE",t.CHAT="CHAT",t))(Ae||{}),Re=(t=>(t.SILENT="SILENT",t.BADGE="BADGE",t.POPOUT="POPOUT",t.MODAL="MODAL",t.TOAST="TOAST",t))(Re||{}),ve=(t=>(t.LAUNCHER_CLICK="LAUNCHER_CLICK",t.LAUNCHER_HOVER="LAUNCHER_HOVER",t.TARGET_CLICK="TARGET_CLICK",t.TARGET_HOVER="TARGET_HOVER",t.LAUNCHER_TARGET_CLICK="LAUNCHER_TARGET_CLICK",t.LAUNCHER_TARGET_HOVER="LAUNCHER_TARGET_HOVER",t))(ve||{}),W=(t=>(t.ACTIVATE="ACTIVATE",t.DEACTIVATE="DEACTIVATE",t.NEVER="NEVER",t))(W||{}),Oe=(t=>(t.AUTO="AUTO",t.TOP="TOP",t.RIGHT="RIGHT",t.BOTTOM="BOTTOM",t.LEFT="LEFT",t))(Oe||{}),be=(t=>(t.START="START",t.CENTER="CENTER",t.END="END",t))(be||{}),ye=(t=>(t.PERCENT="PERCENT",t.PX="PX",t))(ye||{}),De=(t=>(t.BEACON="BEACON",t.BUTTON="BUTTON",t.HIDDEN="HIDDEN",t.ICON="ICON",t))(De||{}),Me=(t=>(t.LAUNCHER="LAUNCHER",t.TARGET="TARGET",t))(Me||{}),Pe=(t=>(t.BODY_FIRST="BODY_FIRST",t.BODY_LAST="BODY_LAST",t.ELEMENT_FIRST="ELEMENT_FIRST",t.ELEMENT_LAST="ELEMENT_LAST",t.ELEMENT_BEFORE="ELEMENT_BEFORE",t.ELEMENT_AFTER="ELEMENT_AFTER",t))(Pe||{}),Be=(t=>(t.BODY_FIRST="BODY_FIRST",t.BODY_LAST="BODY_LAST",t.ELEMENT_FIRST="ELEMENT_FIRST",t.ELEMENT_LAST="ELEMENT_LAST",t.ELEMENT_BEFORE="ELEMENT_BEFORE",t.ELEMENT_AFTER="ELEMENT_AFTER",t))(Be||{}),xe=(t=>(t.ALWAYS="ALWAYS",t.MULTIPLE="MULTIPLE",t.NEVER="NEVER",t.ONCE="ONCE",t.ONCE_PER_GROUP="ONCE_PER_GROUP",t))(xe||{}),Ge=(t=>(t.NONE="NONE",t.PENDING_SCHEDULE="PENDING_SCHEDULE",t.SCHEDULED="SCHEDULED",t.FIRED="FIRED",t))(Ge||{}),He=(t=>(t.NONE="NONE",t.LIKE="LIKE",t.SCALE="SCALE",t))(He||{});function We(){return{customInputs:[],customNavigate:null,urlFilter:null,linkUrlDecorator:null,customScrollIntoView:null,scrollPadding:null,inferenceAttributeNames:["data-for","data-id","data-testid","data-test-id","for","id","name","placeholder","role"],inferenceAttributeFilters:{id:[t=>!t.match(/\d$/)],"data-id":[t=>!t.match(/\d$/)]},inferenceClassNameFilters:[t=>!t.startsWith("css-")],baseZIndex:1234500,evalJsDisabled:!1}}const d=We();function b(t){return Array.isArray(t)||(t=t?[t]:[]),t=t.map(e=>typeof e=="string"?new RegExp(e):e),t}function ct(t,e){return t.every(s=>typeof s=="function"?s(e):s instanceof RegExp?s.test(e):!0)}function Ve(){let t=x();if(d.urlFilter){if(t=d.urlFilter(t),typeof t!="string")throw new u("Userflow.js: URL filter returned non-string value. Please check your userflow.setUrlFilter() implementation.");try{new URL(t)}catch(e){throw new u(`Userflow.js: URL filter returned an invalid URL. Please check your userflow.setUrlFilter() implementation.
3
3
  Returned URL: `+t+`
4
- Error message: `+e.message)}}return t}let V="";try{V=localStorage.getItem("debug")||""}catch{}const $=V.split(",").some(t=>t==="*"||t.startsWith("userflow:*")),o=R("log");o.group=R("group");o.groupCollapsed=R("groupCollapsed");o.groupEnd=function(){$&&console.groupEnd()};let U;function R(t){return function(e,...s){if($){const i=performance.now(),n=U?Math.round(i-U):0;U=i,console[t](`%cuserflow %c${e} %c+${n}ms`,"color:#1a57e6;","","color:#1a57e6;",...s)}}}const $e=()=>g(()=>import("./ResourceCenterApp.js").then(t=>t.R),__vite__mapDeps([0,1,2,3,4,5,6,7,8,9,10,11,12,13,14,15,16,17,18,19,20,21,22,23,24,25,26,27,28,29,30,31,32,33]));function Ke(t){const s=t.version.checklist.tasks.length;return Math.max(0,s-t.taskCompletions.length)}class y{constructor(e){this.observers=new Set,this._value=e}get value(){return this._value}update(e){if(e!==this._value){this._value=e;for(const s of this.observers)s()}}observe(e){return this.observers.add(e),()=>this.observers.delete(e)}}const D=["page:before-change","page:change","turbo:before-cache","turbo:load","turbo:visit","turbolinks:before-cache","turbolinks:load","turbolinks:visit"],Fe=()=>g(()=>import("./BannerApp.js"),__vite__mapDeps([34,1,2,3,4,5,6,7,8,9,10,11,12,13,14,23,20,21,22,17,18,19,16,15,25,26,24,31,27,35,36])),L="1011597",je=import.meta.url,M=50,Ye=5*60*1e3,P="userflowClientState";class ze{constructor(){this.clientToken=null,this.externalId=null,this.signature=null,this.groupId=null,this.groupSignature=null,this._socketStatus="disconnected",this.socket=null,this.channel=null,this.logrocketAppId=null,this.debounceInactiveDisconnectTimeout=void 0,this.inBatch=!1,this.endBatchTimeout=void 0,this.pushRateLimitMinute=0,this.pushRateLimitMinuteExpires=0,this.clientClock=1,this.serverClock=1,this.flowSession=null,this.flowSessionClock=0,this.checklistSession=null,this.checklistExpanded=!1,this.checklistExpandPending=!1,this.checklistSessionClock=0,this.bannerSession=null,this.resourceCenterSession=null,this.resourceCenterOpen=!1,this.resourceCenterLauncherHidden=!1,this.launcherSessions=[],this.activeLauncherFlowId=null,this.notifications=[],this.embedSessions=[],this.notificationIdCounter=0,this.sessionStorageState=null,this.clientContext=null,this.flushUrlChangeTimeout=void 0,this.onFirstIdentifyRun=!1,this.onFirstIdentifyTimeout=void 0,this.firstIdentifyCallback=null,this.ui=null,this.debuggerUI=null,this.unackedTasks=new Set,this.clientConditions=new Map,this.trackers=new Map,this.conditionWaitTimers=new Map,this.listeners=new Map,this.targetEnv=null,this.idempotencyKeysSeen=new Set,this.testUserIdentified=!1,this.cspIssueReported=!1,this.uiDisabled=!1,this.audio=null,this.audioReady=!1,this.pageTrackingDisabled=!1,this.refCounter=1,this.implicitTrackingQueue=[],this.onBuilderMessage=e=>(this.handleBuilderMessage(e),!1),this.handleBuilderMessage=async e=>{o(`builder ${e.kind} message received`,e);const s="idempotencyKey"in e&&typeof e.idempotencyKey=="string"?e.idempotencyKey:null;if(s&&this.idempotencyKeysSeen.has(s))return;const i=()=>{s&&this.idempotencyKeysSeen.add(s)};switch(e.kind){case"userflow:selectElement":{i(),this.getTargetEnv().postBuilderMessage({kind:"userflow:selectElementAck",idempotencyKey:e.idempotencyKey}),this.setSessionStorageState(n=>({...n,isTargetTab:!0,activeApp:"elementSelection",elementSelection:{mode:"select",elementType:e.elementType}}));return}case"userflow:selectElementCancel":{this.setSessionStorageState(n=>({...n,activeApp:null,elementSelection:null}));return}case"userflow:startFlowWithToken":{i(),this.getTargetEnv().postBuilderMessage({kind:"userflow:startFlowWithTokenAck",idempotencyKey:e.idempotencyKey}),this.setSessionStorageState(n=>({...n,isTargetTab:!0,activeApp:null,testStartConditionToken:void 0})),f.setItem("previewFlowId",e.flowId),e.testUser?this.identifyTestUser(e.testUser):this.resetTestUser(),e.testStartCondition?this.setSessionStorageState(n=>({...n,activeApp:"startConditionTesting",testStartConditionToken:e.token})):this.onceIdentified(()=>{if(this.startFlowWithToken(e.token),e.isResourceCenter){const n=()=>{const r=this.resourceCenterSession;r&&r.draftMode&&r.flow.id===e.flowId&&(this.openResourceCenter(),this.off("resourceCenterChanged",n))};this.on("resourceCenterChanged",n),n()}});return}case"userflow:testTracker":{i(),this.getTargetEnv().postBuilderMessage({kind:"userflow:testTrackerAck",idempotencyKey:e.idempotencyKey}),this.setSessionStorageState(n=>({...n,isTargetTab:!0})),e.testUser?this.identifyTestUser(e.testUser):this.resetTestUser(),this.setSessionStorageState(n=>({...n,activeApp:"trackerTesting",trackerTesting:{trackerName:e.trackerName,token:e.token,events:0}}));return}case"userflow:testTrackerCancel":{this.setSessionStorageState(n=>({...n,activeApp:null,trackerTesting:null}));return}}},this.onUrlChange=()=>{this.externalId&&(window.clearTimeout(this.flushUrlChangeTimeout),this.flushUrlChangeTimeout=window.setTimeout(()=>this.flushUrlChange(),M))},this.onUserActivity=()=>this.ensureConnected(),this.remountIfNecessary=()=>{!this.ui?.container||document.contains(this.ui.container)||(o("remounting UI because container was missing"),this.remount())},o("constructor, build="+L),X(this.onUrlChange),this.setTargetEnv(new Z),this.checkTestUserAtBoot(),this.toggleUI(),this.checkDebuggerSession();for(const e of D)document.addEventListener(e,this.remountIfNecessary)}get socketStatus(){return this._socketStatus}destroy(){o("destroy"),this.reset(),H(this.onUrlChange),this.destroyTargetEnv();for(const e of D)document.removeEventListener(e,this.remountIfNecessary)}setTargetEnv(e){this.destroyTargetEnv(),this.targetEnv=e,e.onBuilderMessage(this.onBuilderMessage)}destroyTargetEnv(){this.targetEnv&&(this.targetEnv.destroy(),this.targetEnv=null)}getTargetEnv(){if(!this.targetEnv)throw new u("Userflow.js: Cannot call getTargetEnv when protocol is not set");return this.targetEnv}setSessionStorageState(e){const s=e(this.getSessionStorageState());f.setItem(P,JSON.stringify(s)),this.sessionStorageState=s,this.toggleUI()}getSessionStorageState(){let e=this.sessionStorageState;if(!e){const s=f.getItem(P);if(s)try{e=JSON.parse(s)}catch(i){console.error("Userflow.js: Parse ElementSelectionState error:",i)}e||(e={testUser:null,activeApp:null,elementSelection:null,trackerTesting:null}),this.sessionStorageState=e}return e}checkTestUserAtBoot(){const e=this.getSessionStorageState().testUser;e&&(o("checkTestUserAtBoot identifying test user"),this.identifyTestUser(e))}async identifyTestUser(e){this.setSessionStorageState(n=>({...n,testUser:e})),this.reset(),this.init(e.clientToken),this.testUserIdentified=!0,this.externalId=e.id;const s=[this.identify(e.id,{name:e.name,email:e.email,signed_up_at:{set_once:new Date().toISOString(),data_type:"datetime"}},{signature:e.signature})],{group:i}=e;i&&(this.groupId=i.id,s.push(this.group(i.id,{name:i.name},{signature:i.signature}))),await Promise.all(s)}resetTestUser(){this.setSessionStorageState(e=>({...e,testUser:null}))}init(e){if(o("init",e),!e)throw new u("userflow.init() was called but missing Userflow.js Token");if(this.clientToken!==e){if(this.testUserIdentified){o("init() ignoring new token since a test user has been identified");return}this.clientToken&&(o("init() resetting due to new client token"),this.reset()),this.clientToken=e,this.emit("private:initialised")}}ensureInit(){if(!this.clientToken)throw new u("You must call userflow.init() first")}ensureIdentified(){if(this.ensureInit(),!this.externalId)throw new u("You must call userflow.identify() first");return this.externalId}ensureGroup(){if(this.ensureIdentified(),!this.groupId)throw new u("You must call userflow.group() first");return this.groupId}ensureConnected(){if(!this.clientToken||!this.externalId||(this.debounceInactiveDisconnect(),this.socket))return;this._socketStatus="connecting",o("connecting to socket");let e=d.serverEndpoint||"e.userflow.com";new URL(je).hostname==="js.getuserflow.com"&&e==="e.userflow.com"&&(e="e.getuserflow.com");const s="wss://"+e+"/end-users/"+this.clientToken+"/socket";this.socket=new j(s,{reconnectAfterMs:i=>[100,500,1e3,5e3][i-1]||1e4,timeout:20*1e3}),this.socket.connect(),this.socket.onOpen(()=>{o("socket opened")}),this.socket.onClose(()=>{this.emit("private:disconnect")}),this.socket.onError(i=>{console.log("Userflow.js socket error",i),this.reportCspIssue()}),this.channel=this.socket.channel(`end_users:${this.externalId}`,()=>this.makeChannelJoinPayload()),this.channel.join().receive("ok",i=>{this.logrocketAppId=i.logrocketAppId,this.featureFlags=new Set(i.featureFlags),o("channel joined"),this._socketStatus!=="connected"&&(this._socketStatus="connected"),this.flushImplicitTrackingQueue(),this.featureFlagEnabled("cff_implicit_events")===!0&&this.startImplicitTracking()}).receive("error",i=>{["company_closed","invalid_client_token","invalid_user_external_id","incorrect_user_signature","rate_limit_exceeded","user_signature_required"].includes(i.code)?(console.error(`Userflow.js resetting due to: [${i.code}] ${i.message}`),this.reset(),this.clientToken=null):i.code==="invalid_protocol_version"?(console.error(`Userflow.js destroying due to: [${i.code}] ${i.message}`),this.destroy()):console.log("Userflow.js channel join error",i)}),this.channel.on("server_message",i=>this.handleServerMessage(i)),this.channel.on("server_error",i=>{console.log(`Userflow.js server error (${i.code}): ${i.message}`+(i.details&&i.details.length>0?`
4
+ Error message: `+e.message)}}return t}let V="";try{V=localStorage.getItem("debug")||""}catch{}const $=V.split(",").some(t=>t==="*"||t.startsWith("userflow:*")),o=R("log");o.group=R("group");o.groupCollapsed=R("groupCollapsed");o.groupEnd=function(){$&&console.groupEnd()};let U;function R(t){return function(e,...s){if($){const i=performance.now(),n=U?Math.round(i-U):0;U=i,console[t](`%cuserflow %c${e} %c+${n}ms`,"color:#1a57e6;","","color:#1a57e6;",...s)}}}const $e=()=>g(()=>import("./ResourceCenterApp.js").then(t=>t.R),__vite__mapDeps([0,1,2,3,4,5,6,7,8,9,10,11,12,13,14,15,16,17,18,19,20,21,22,23,24,25,26,27,28,29,30,31,32,33]));function Ke(t){const s=t.version.checklist.tasks.length;return Math.max(0,s-t.taskCompletions.length)}class y{constructor(e){this.observers=new Set,this._value=e}get value(){return this._value}update(e){if(e!==this._value){this._value=e;for(const s of this.observers)s()}}observe(e){return this.observers.add(e),()=>this.observers.delete(e)}}const D=["page:before-change","page:change","turbo:before-cache","turbo:load","turbo:visit","turbolinks:before-cache","turbolinks:load","turbolinks:visit"],Fe=()=>g(()=>import("./BannerApp.js"),__vite__mapDeps([34,1,2,3,4,5,6,7,8,9,10,11,12,13,14,23,20,21,22,17,18,19,16,15,25,26,24,31,27,35,36])),L="1011632",je=import.meta.url,M=50,Ye=5*60*1e3,P="userflowClientState";class ze{constructor(){this.clientToken=null,this.externalId=null,this.signature=null,this.groupId=null,this.groupSignature=null,this._socketStatus="disconnected",this.socket=null,this.channel=null,this.logrocketAppId=null,this.debounceInactiveDisconnectTimeout=void 0,this.inBatch=!1,this.endBatchTimeout=void 0,this.pushRateLimitMinute=0,this.pushRateLimitMinuteExpires=0,this.clientClock=1,this.serverClock=1,this.flowSession=null,this.flowSessionClock=0,this.checklistSession=null,this.checklistExpanded=!1,this.checklistExpandPending=!1,this.checklistSessionClock=0,this.bannerSession=null,this.resourceCenterSession=null,this.resourceCenterOpen=!1,this.resourceCenterLauncherHidden=!1,this.launcherSessions=[],this.activeLauncherFlowId=null,this.notifications=[],this.embedSessions=[],this.notificationIdCounter=0,this.sessionStorageState=null,this.clientContext=null,this.flushUrlChangeTimeout=void 0,this.onFirstIdentifyRun=!1,this.onFirstIdentifyTimeout=void 0,this.firstIdentifyCallback=null,this.ui=null,this.debuggerUI=null,this.unackedTasks=new Set,this.clientConditions=new Map,this.trackers=new Map,this.conditionWaitTimers=new Map,this.listeners=new Map,this.targetEnv=null,this.idempotencyKeysSeen=new Set,this.testUserIdentified=!1,this.cspIssueReported=!1,this.uiDisabled=!1,this.audio=null,this.audioReady=!1,this.pageTrackingDisabled=!1,this.refCounter=1,this.implicitTrackingQueue=[],this.onBuilderMessage=e=>(this.handleBuilderMessage(e),!1),this.handleBuilderMessage=async e=>{o(`builder ${e.kind} message received`,e);const s="idempotencyKey"in e&&typeof e.idempotencyKey=="string"?e.idempotencyKey:null;if(s&&this.idempotencyKeysSeen.has(s))return;const i=()=>{s&&this.idempotencyKeysSeen.add(s)};switch(e.kind){case"userflow:selectElement":{i(),this.getTargetEnv().postBuilderMessage({kind:"userflow:selectElementAck",idempotencyKey:e.idempotencyKey}),this.setSessionStorageState(n=>({...n,isTargetTab:!0,activeApp:"elementSelection",elementSelection:{mode:"select",elementType:e.elementType}}));return}case"userflow:selectElementCancel":{this.setSessionStorageState(n=>({...n,activeApp:null,elementSelection:null}));return}case"userflow:startFlowWithToken":{i(),this.getTargetEnv().postBuilderMessage({kind:"userflow:startFlowWithTokenAck",idempotencyKey:e.idempotencyKey}),this.setSessionStorageState(n=>({...n,isTargetTab:!0,activeApp:null,testStartConditionToken:void 0})),f.setItem("previewFlowId",e.flowId),e.testUser?this.identifyTestUser(e.testUser):this.resetTestUser(),e.testStartCondition?this.setSessionStorageState(n=>({...n,activeApp:"startConditionTesting",testStartConditionToken:e.token})):this.onceIdentified(()=>{if(this.startFlowWithToken(e.token),e.isResourceCenter){const n=()=>{const r=this.resourceCenterSession;r&&r.draftMode&&r.flow.id===e.flowId&&(this.openResourceCenter(),this.off("resourceCenterChanged",n))};this.on("resourceCenterChanged",n),n()}});return}case"userflow:testTracker":{i(),this.getTargetEnv().postBuilderMessage({kind:"userflow:testTrackerAck",idempotencyKey:e.idempotencyKey}),this.setSessionStorageState(n=>({...n,isTargetTab:!0})),e.testUser?this.identifyTestUser(e.testUser):this.resetTestUser(),this.setSessionStorageState(n=>({...n,activeApp:"trackerTesting",trackerTesting:{trackerName:e.trackerName,token:e.token,events:0}}));return}case"userflow:testTrackerCancel":{this.setSessionStorageState(n=>({...n,activeApp:null,trackerTesting:null}));return}}},this.onUrlChange=()=>{this.externalId&&(window.clearTimeout(this.flushUrlChangeTimeout),this.flushUrlChangeTimeout=window.setTimeout(()=>this.flushUrlChange(),M))},this.onUserActivity=()=>this.ensureConnected(),this.remountIfNecessary=()=>{!this.ui?.container||document.contains(this.ui.container)||(o("remounting UI because container was missing"),this.remount())},o("constructor, build="+L),X(this.onUrlChange),this.setTargetEnv(new Z),this.checkTestUserAtBoot(),this.toggleUI(),this.checkDebuggerSession();for(const e of D)document.addEventListener(e,this.remountIfNecessary)}get socketStatus(){return this._socketStatus}destroy(){o("destroy"),this.reset(),H(this.onUrlChange),this.destroyTargetEnv();for(const e of D)document.removeEventListener(e,this.remountIfNecessary)}setTargetEnv(e){this.destroyTargetEnv(),this.targetEnv=e,e.onBuilderMessage(this.onBuilderMessage)}destroyTargetEnv(){this.targetEnv&&(this.targetEnv.destroy(),this.targetEnv=null)}getTargetEnv(){if(!this.targetEnv)throw new u("Userflow.js: Cannot call getTargetEnv when protocol is not set");return this.targetEnv}setSessionStorageState(e){const s=e(this.getSessionStorageState());f.setItem(P,JSON.stringify(s)),this.sessionStorageState=s,this.toggleUI()}getSessionStorageState(){let e=this.sessionStorageState;if(!e){const s=f.getItem(P);if(s)try{e=JSON.parse(s)}catch(i){console.error("Userflow.js: Parse ElementSelectionState error:",i)}e||(e={testUser:null,activeApp:null,elementSelection:null,trackerTesting:null}),this.sessionStorageState=e}return e}checkTestUserAtBoot(){const e=this.getSessionStorageState().testUser;e&&(o("checkTestUserAtBoot identifying test user"),this.identifyTestUser(e))}async identifyTestUser(e){this.setSessionStorageState(n=>({...n,testUser:e})),this.reset(),this.init(e.clientToken),this.testUserIdentified=!0,this.externalId=e.id;const s=[this.identify(e.id,{name:e.name,email:e.email,signed_up_at:{set_once:new Date().toISOString(),data_type:"datetime"}},{signature:e.signature})],{group:i}=e;i&&(this.groupId=i.id,s.push(this.group(i.id,{name:i.name},{signature:i.signature}))),await Promise.all(s)}resetTestUser(){this.setSessionStorageState(e=>({...e,testUser:null}))}init(e){if(o("init",e),!e)throw new u("userflow.init() was called but missing Userflow.js Token");if(this.clientToken!==e){if(this.testUserIdentified){o("init() ignoring new token since a test user has been identified");return}this.clientToken&&(o("init() resetting due to new client token"),this.reset()),this.clientToken=e,this.emit("private:initialised")}}ensureInit(){if(!this.clientToken)throw new u("You must call userflow.init() first")}ensureIdentified(){if(this.ensureInit(),!this.externalId)throw new u("You must call userflow.identify() first");return this.externalId}ensureGroup(){if(this.ensureIdentified(),!this.groupId)throw new u("You must call userflow.group() first");return this.groupId}ensureConnected(){if(!this.clientToken||!this.externalId||(this.debounceInactiveDisconnect(),this.socket))return;this._socketStatus="connecting",o("connecting to socket");let e=d.serverEndpoint||"e.userflow.com";new URL(je).hostname==="js.getuserflow.com"&&e==="e.userflow.com"&&(e="e.getuserflow.com");const s="wss://"+e+"/end-users/"+this.clientToken+"/socket";this.socket=new j(s,{reconnectAfterMs:i=>[100,500,1e3,5e3][i-1]||1e4,timeout:20*1e3}),this.socket.connect(),this.socket.onOpen(()=>{o("socket opened")}),this.socket.onClose(()=>{this.emit("private:disconnect")}),this.socket.onError(i=>{console.log("Userflow.js socket error",i),this.reportCspIssue()}),this.channel=this.socket.channel(`end_users:${this.externalId}`,()=>this.makeChannelJoinPayload()),this.channel.join().receive("ok",i=>{this.logrocketAppId=i.logrocketAppId,this.featureFlags=new Set(i.featureFlags),o("channel joined"),this._socketStatus!=="connected"&&(this._socketStatus="connected"),this.flushImplicitTrackingQueue(),this.featureFlagEnabled("cff_implicit_events")===!0&&this.startImplicitTracking()}).receive("error",i=>{["company_closed","invalid_client_token","invalid_user_external_id","incorrect_user_signature","rate_limit_exceeded","user_signature_required"].includes(i.code)?(console.error(`Userflow.js resetting due to: [${i.code}] ${i.message}`),this.reset(),this.clientToken=null):i.code==="invalid_protocol_version"?(console.error(`Userflow.js destroying due to: [${i.code}] ${i.message}`),this.destroy()):console.log("Userflow.js channel join error",i)}),this.channel.on("server_message",i=>this.handleServerMessage(i)),this.channel.on("server_error",i=>{console.log(`Userflow.js server error (${i.code}): ${i.message}`+(i.details&&i.details.length>0?`
5
5
  Details:
6
6
  `+i.details.map(n=>(n.path?`${n.path}: `:"")+n.message):""))}),this.channel.onClose(()=>{this.flushImplicitTrackingQueue(),this.implicitTracking?.stop()})}async startImplicitTracking(){await g(()=>import("./implicit-tracking.js"),__vite__mapDeps([37,19,2,3,4,5,6,7,8,9,36,35])).then(e=>this.implicitTracking=new e.ImplicitTracking(this)).catch(e=>o(`Implicit tracking failed to load ${e}`)),this.implicitTracking.start()}flushImplicitTrackingQueue(){this.featureFlagEnabled("cff_implicit_events")===!0&&this.implicitTrackingQueue.forEach(e=>{this.trackRawEvent({name:"page_viewed",attributes:e})}),this.implicitTrackingQueue=[]}makeChannelJoinPayload(){const e=this.buildClientContext();this.clientContext=e;const s={protocolVersion:2,userflowClientBuild:L,signature:this.signature,groupExternalId:this.groupId,groupSignature:this.groupSignature,flowSessionId:this.flowSession?.id||null,checklistSessionId:this.checklistSession?.id||null,bannerSessionId:this.bannerSession?.id||null,resourceCenterSessionId:this.resourceCenterSession?.id||null,launchers:this.launcherSessions.map(i=>({flowId:i.flow.id})),trackers:Array.from(this.trackers.values()).map(i=>({flowId:i.tracker.flowId})),hasDraftSession:this.hasDraftSession(),clientConditions:Array.from(this.clientConditions.values()).map(i=>({conditionId:i.condition.id,isTrue:i.isTrue})),previewFlowId:f.getItem("previewFlowId"),clientContext:e};return o("channel join payload",s),s}disconnect(){window.clearTimeout(this.debounceInactiveDisconnectTimeout),this.socket&&this.socket.disconnect(),this._socketStatus="disconnected",this.socket=null,this.channel=null}debounceInactiveDisconnect(){window.clearTimeout(this.debounceInactiveDisconnectTimeout),this.debounceInactiveDisconnectTimeout=window.setTimeout(()=>{if(this.hasDraftSession()||this.assistantMessageInProgress){this.debounceInactiveDisconnect();return}o("disconnecting from socket due to inactivity"),this.disconnect()},Ye)}hasDraftSession(){return!!this.flowSession?.draftMode||!!this.checklistSession?.draftMode||!!this.bannerSession?.draftMode||!!this.resourceCenterSession?.draftMode||this.launcherSessions.some(e=>e.draftMode)}async send(e,{batch:s,endBatch:i,handlesRejection:n}={}){return(!this.inBatch||!["ToggleClientCondition","UpdateClientContext"].includes(e.kind))&&this.checkPushRateLimit(),this.ensureConnected(),s&&!this.inBatch&&(this.inBatch=!0,this.sendRaw({kind:"BeginBatch"})),this.inBatch&&(window.clearTimeout(this.endBatchTimeout),i?this.endBatch():this.endBatchTimeout=window.setTimeout(()=>{this.endBatch()},M)),this.sendRaw(e,{handlesRejection:n})}async sendRaw(e,{handlesRejection:s}={}){return new Promise((i,n)=>{if(!this.channel){const c=`Userflow.js: send() should not be called if channel is not set. Message kind=${e.kind}`;if(s)throw Error(c);console.log(c,`
7
7
  Client message:`,e);return}o(`push ${e.kind} message`,e);const r=this.clientClock,a=()=>{this.serverClock=r,this.channel?.off("phx_error",h)},h=this.channel.on("phx_error",c=>{a();const l=`Userflow.js send ${e.kind} got phx_error`;this._socketStatus==="connected"&&console.log(l,`
@@ -1,2 +1,2 @@
1
- import{h as Vn,m as Hr}from"./vendor.jumpn.utils-composite.js";import{r as Ur,e as Gr,g as Vr}from"./vendor.jumpn.utils-graphql.js";import{O as Jr}from"./vendor.zen-observable.js";import{r as Br,a as Jn,b as Wr}from"./vendor.jumpn.utils-array.js";(function(){try{var n=typeof window<"u"?window:typeof global<"u"?global:typeof self<"u"?self:{},e=new Error().stack;e&&(n._sentryDebugIds=n._sentryDebugIds||{},n._sentryDebugIds[e]="e6ddadd4-ad4b-4c6f-9757-81fdeb433357",n._sentryDebugIdIdentifier="sentry-dbid-e6ddadd4-ad4b-4c6f-9757-81fdeb433357")}catch{}})();var Qr=typeof window<"u"?window:typeof global<"u"?global:typeof self<"u"?self:{};Qr.SENTRY_RELEASE={id:"9f830256c28c02dd1f248d44d926ce597d497532"};var Ku=typeof globalThis<"u"?globalThis:typeof window<"u"?window:typeof global<"u"?global:typeof self<"u"?self:{};function ee(n){return n&&n.__esModule&&Object.prototype.hasOwnProperty.call(n,"default")?n.default:n}var Bn={exports:{}},Kr=Bn.exports=typeof window<"u"&&window.Math==Math?window:typeof self<"u"&&self.Math==Math?self:Function("return this")();typeof __g=="number"&&(__g=Kr);var j=Bn.exports,Wn={exports:{}},zr=Wn.exports={version:"2.6.0"};typeof __e=="number"&&(__e=zr);var Re=Wn.exports,H={},M=function(n){return typeof n=="object"?n!==null:typeof n=="function"},Xr=M,qe=function(n){if(!Xr(n))throw TypeError(n+" is not an object!");return n},Me=function(n){try{return!!n()}catch{return!0}},U=!Me(function(){return Object.defineProperty({},"a",{get:function(){return 7}}).a!=7}),de,nn;function Qn(){if(nn)return de;nn=1;var n=M,e=j.document,r=n(e)&&n(e.createElement);return de=function(t){return r?e.createElement(t):{}},de}var Yr=!U&&!Me(function(){return Object.defineProperty(Qn()("div"),"a",{get:function(){return 7}}).a!=7}),W=M,Zr=function(n,e){if(!W(n))return n;var r,t;if(e&&typeof(r=n.toString)=="function"&&!W(t=r.call(n))||typeof(r=n.valueOf)=="function"&&!W(t=r.call(n))||!e&&typeof(r=n.toString)=="function"&&!W(t=r.call(n)))return t;throw TypeError("Can't convert object to primitive value")},rn=qe,kr=Yr,et=Zr,nt=Object.defineProperty;H.f=U?Object.defineProperty:function(e,r,t){if(rn(e),r=et(r,!0),rn(t),kr)try{return nt(e,r,t)}catch{}if("get"in t||"set"in t)throw TypeError("Accessors not supported!");return"value"in t&&(e[r]=t.value),e};var Kn=function(n,e){return{enumerable:!(n&1),configurable:!(n&2),writable:!(n&4),value:e}},rt=H,tt=Kn,L=U?function(n,e,r){return rt.f(n,e,tt(1,r))}:function(n,e,r){return n[e]=r,n},zn={exports:{}},it={}.hasOwnProperty,ne=function(n,e){return it.call(n,e)},at=0,ut=Math.random(),Le=function(n){return"Symbol(".concat(n===void 0?"":n,")_",(++at+ut).toString(36))},ot=j,Q=L,tn=ne,fe=Le("src"),Ne="toString",De=Function[Ne],st=(""+De).split(Ne);Re.inspectSource=function(n){return De.call(n)};(zn.exports=function(n,e,r,t){var a=typeof r=="function";a&&(tn(r,"name")||Q(r,"name",e)),n[e]!==r&&(a&&(tn(r,fe)||Q(r,fe,n[e]?""+n[e]:st.join(String(e)))),n===ot?n[e]=r:t?n[e]?n[e]=r:Q(n,e,r):(delete n[e],Q(n,e,r)))})(Function.prototype,Ne,function(){return typeof this=="function"&&this[fe]||De.call(this)});var Fe=zn.exports,Xn=function(n){if(typeof n!="function")throw TypeError(n+" is not a function!");return n},ct=Xn,Yn=function(n,e,r){if(ct(n),e===void 0)return n;switch(r){case 1:return function(t){return n.call(e,t)};case 2:return function(t,a){return n.call(e,t,a)};case 3:return function(t,a,u){return n.call(e,t,a,u)}}return function(){return n.apply(e,arguments)}},q=j,Z=Re,dt=L,ft=Fe,an=Yn,ve="prototype",h=function(n,e,r){var t=n&h.F,a=n&h.G,u=n&h.S,o=n&h.P,s=n&h.B,d=a?q:u?q[e]||(q[e]={}):(q[e]||{})[ve],f=a?Z:Z[e]||(Z[e]={}),l=f[ve]||(f[ve]={}),c,b,v,R;a&&(r=e);for(c in r)b=!t&&d&&d[c]!==void 0,v=(b?d:r)[c],R=s&&b?an(v,q):o&&typeof v=="function"?an(Function.call,v):v,d&&ft(d,c,v,n&h.U),f[c]!=v&&dt(f,c,R),o&&l[c]!=v&&(l[c]=v)};q.core=Z;h.F=1;h.G=2;h.S=4;h.P=8;h.B=16;h.W=32;h.U=64;h.R=128;var I=h,vt={}.toString,He=function(n){return vt.call(n).slice(8,-1)},lt=He,Zn=Object("z").propertyIsEnumerable(0)?Object:function(n){return lt(n)=="String"?n.split(""):Object(n)},Ue=function(n){if(n==null)throw TypeError("Can't call method on "+n);return n},ht=Ue,kn=function(n){return Object(ht(n))},bt=Math.ceil,pt=Math.floor,er=function(n){return isNaN(n=+n)?0:(n>0?pt:bt)(n)},yt=er,_t=Math.min,nr=function(n){return n>0?_t(yt(n),9007199254740991):0},gt=He,Ot=Array.isArray||function(e){return gt(e)=="Array"},rr={exports:{}},tr={exports:{}},$t=Re,un=j,on="__core-js_shared__",sn=un[on]||(un[on]={});(tr.exports=function(n,e){return sn[n]||(sn[n]=e!==void 0?e:{})})("versions",[]).push({version:$t.version,mode:"global",copyright:"© 2018 Denis Pushkarev (zloirock.ru)"});var ir=tr.exports,Ie=ir("wks"),mt=Le,Te=j.Symbol,cn=typeof Te=="function",Et=rr.exports=function(n){return Ie[n]||(Ie[n]=cn&&Te[n]||(cn?Te:mt)("Symbol."+n))};Et.store=Ie;var T=rr.exports,Ct=M,dn=Ot,St=T("species"),At=function(n){var e;return dn(n)&&(e=n.constructor,typeof e=="function"&&(e===Array||dn(e.prototype))&&(e=void 0),Ct(e)&&(e=e[St],e===null&&(e=void 0))),e===void 0?Array:e},It=At,Tt=function(n,e){return new(It(n))(e)},wt=Yn,jt=Zn,Pt=kn,xt=nr,Rt=Tt,Ge=function(n,e){var r=n==1,t=n==2,a=n==3,u=n==4,o=n==6,s=n==5||o,d=e||Rt;return function(f,l,c){for(var b=Pt(f),v=jt(b),R=wt(l,c,3),N=xt(v.length),p=0,A=r?d(f,N):t?d(f,0):void 0,_,g;N>p;p++)if((s||p in v)&&(_=v[p],g=R(_,p,b),n)){if(r)A[p]=g;else if(g)switch(n){case 3:return!0;case 5:return _;case 6:return p;case 2:A.push(_)}else if(u)return!1}return o?-1:a||u?u:A}},le,fn;function re(){if(fn)return le;fn=1;var n=T("unscopables"),e=Array.prototype;return e[n]==null&&L(e,n,{}),le=function(r){e[n][r]=!0},le}var he=I,qt=Ge(6),we="findIndex",ar=!0;we in[]&&Array(1)[we](function(){ar=!1});he(he.P+he.F*ar,"Array",{findIndex:function(e){return qt(this,e,arguments.length>1?arguments[1]:void 0)}});re()(we);var be=I,Mt=Ge(5),je="find",ur=!0;je in[]&&Array(1)[je](function(){ur=!1});be(be.P+be.F*ur,"Array",{find:function(e){return Mt(this,e,arguments.length>1?arguments[1]:void 0)}});re()(je);var Lt=H.f,vn=Function.prototype,Nt=/^\s*function ([^ (]*)/,ln="name";ln in vn||U&&Lt(vn,ln,{configurable:!0,get:function(){try{return(""+this).match(Nt)[1]}catch{return""}}});var Dt=function(n,e){return{value:e,done:!!n}},Ve={},Ft=Zn,Ht=Ue,Je=function(n){return Ft(Ht(n))},Ut=er,Gt=Math.max,Vt=Math.min,Jt=function(n,e){return n=Ut(n),n<0?Gt(n+e,0):Vt(n,e)},Bt=Je,Wt=nr,Qt=Jt,Be=function(n){return function(e,r,t){var a=Bt(e),u=Wt(a.length),o=Qt(t,u),s;if(n&&r!=r){for(;u>o;)if(s=a[o++],s!=s)return!0}else for(;u>o;o++)if((n||o in a)&&a[o]===r)return n||o||0;return!n&&-1}},hn=ir("keys"),Kt=Le,We=function(n){return hn[n]||(hn[n]=Kt(n))},bn=ne,zt=Je,Xt=Be(!1),Yt=We("IE_PROTO"),Zt=function(n,e){var r=zt(n),t=0,a=[],u;for(u in r)u!=Yt&&bn(r,u)&&a.push(u);for(;e.length>t;)bn(r,u=e[t++])&&(~Xt(a,u)||a.push(u));return a},or="constructor,hasOwnProperty,isPrototypeOf,propertyIsEnumerable,toLocaleString,toString,valueOf".split(","),kt=Zt,ei=or,sr=Object.keys||function(e){return kt(e,ei)},ni=H,ri=qe,ti=sr,ii=U?Object.defineProperties:function(e,r){ri(e);for(var t=ti(r),a=t.length,u=0,o;a>u;)ni.f(e,o=t[u++],r[o]);return e},pe,pn;function ai(){if(pn)return pe;pn=1;var n=j.document;return pe=n&&n.documentElement,pe}var ui=qe,oi=ii,yn=or,si=We("IE_PROTO"),ye=function(){},Pe="prototype",k=function(){var n=Qn()("iframe"),e=yn.length,r="<",t=">",a;for(n.style.display="none",ai().appendChild(n),n.src="javascript:",a=n.contentWindow.document,a.open(),a.write(r+"script"+t+"document.F=Object"+r+"/script"+t),a.close(),k=a.F;e--;)delete k[Pe][yn[e]];return k()},ci=Object.create||function(e,r){var t;return e!==null?(ye[Pe]=ui(e),t=new ye,ye[Pe]=null,t[si]=e):t=k(),r===void 0?t:oi(t,r)},di=H.f,fi=ne,_n=T("toStringTag"),cr=function(n,e,r){n&&!fi(n=r?n:n.prototype,_n)&&di(n,_n,{configurable:!0,value:e})},vi=ci,li=Kn,hi=cr,dr={};L(dr,T("iterator"),function(){return this});var bi=function(n,e,r){n.prototype=vi(dr,{next:li(1,r)}),hi(n,e+" Iterator")},pi=ne,yi=kn,gn=We("IE_PROTO"),_i=Object.prototype,gi=Object.getPrototypeOf||function(n){return n=yi(n),pi(n,gn)?n[gn]:typeof n.constructor=="function"&&n instanceof n.constructor?n.constructor.prototype:n instanceof Object?_i:null},_e=I,Oi=Fe,On=L,$n=Ve,$i=bi,mi=cr,Ei=gi,D=T("iterator"),ge=!([].keys&&"next"in[].keys()),Ci="@@iterator",mn="keys",K="values",En=function(){return this},Si=function(n,e,r,t,a,u,o){$i(r,e,t);var s=function(g){if(!ge&&g in c)return c[g];switch(g){case mn:return function(){return new r(this,g)};case K:return function(){return new r(this,g)}}return function(){return new r(this,g)}},d=e+" Iterator",f=a==K,l=!1,c=n.prototype,b=c[D]||c[Ci]||a&&c[a],v=b||s(a),R=a?f?s("entries"):v:void 0,N=e=="Array"&&c.entries||b,p,A,_;if(N&&(_=Ei(N.call(new n)),_!==Object.prototype&&_.next&&(mi(_,d,!0),typeof _[D]!="function"&&On(_,D,En))),f&&b&&b.name!==K&&(l=!0,v=function(){return b.call(this)}),(ge||l||!c[D])&&On(c,D,v),$n[e]=v,$n[d]=En,a)if(p={values:f?v:s(K),keys:u?v:s(mn),entries:R},o)for(A in p)A in c||Oi(c,A,p[A]);else _e(_e.P+_e.F*(ge||l),e,p);return p},Qe=re(),z=Dt,Cn=Ve,Ai=Je,Ii=Si(Array,"Array",function(n,e){this._t=Ai(n),this._i=0,this._k=e},function(){var n=this._t,e=this._k,r=this._i++;return!n||r>=n.length?(this._t=void 0,z(1)):e=="keys"?z(0,r):e=="values"?z(0,n[r]):z(0,[r,n[r]])},"values");Cn.Arguments=Cn.Array;Qe("keys");Qe("values");Qe("entries");var Sn=Ii,Ti=sr,wi=Fe,ji=j,An=L,fr=Ve,vr=T,In=vr("iterator"),Tn=vr("toStringTag"),wn=fr.Array,jn={CSSRuleList:!0,CSSStyleDeclaration:!1,CSSValueList:!1,ClientRectList:!1,DOMRectList:!1,DOMStringList:!1,DOMTokenList:!0,DataTransferItemList:!1,FileList:!1,HTMLAllCollection:!1,HTMLCollection:!1,HTMLFormElement:!1,HTMLSelectElement:!1,MediaList:!0,MimeTypeArray:!1,NamedNodeMap:!1,NodeList:!0,PaintRequestList:!1,Plugin:!1,PluginArray:!1,SVGLengthList:!1,SVGNumberList:!1,SVGPathSegList:!1,SVGPointList:!1,SVGStringList:!1,SVGTransformList:!1,SourceBufferList:!1,StyleSheetList:!0,TextTrackCueList:!1,TextTrackList:!1,TouchList:!1};for(var Pn=Ti(jn),Oe=0;Oe<Pn.length;Oe++){var X=Pn[Oe],Pi=jn[X],xn=ji[X],w=xn&&xn.prototype,Y;if(w&&(w[In]||An(w,In,wn),w[Tn]||An(w,Tn,X),fr[X]=wn,Pi))for(Y in Sn)w[Y]||wi(w,Y,Sn[Y],!0)}var xi=Me,lr=function(n,e){return!!n&&xi(function(){e?n.call(null,function(){},1):n.call(null)})},$e=I,Ri=Ge(0),qi=lr([].forEach,!0);$e($e.P+$e.F*!qi,"Array",{forEach:function(e){return Ri(this,e,arguments[1])}});function Mi(n){if(Array.isArray(n)){for(var e=0,r=new Array(n.length);e<n.length;e++)r[e]=n[e];return r}}var Li=Mi;function Ni(n){if(Symbol.iterator in Object(n)||Object.prototype.toString.call(n)==="[object Arguments]")return Array.from(n)}var Di=Ni;function Fi(){throw new TypeError("Invalid attempt to spread non-iterable instance")}var Hi=Fi,Ui=Li,Gi=Di,Vi=Hi;function Ji(n){return Ui(n)||Gi(n)||Vi()}var Bi=Ji;const F=ee(Bi);var Rn=I,Wi=Be(!0);Rn(Rn.P,"Array",{includes:function(e){return Wi(this,e,arguments.length>1?arguments[1]:void 0)}});re()("includes");var Qi=M,Ki=He,zi=T("match"),Xi=function(n){var e;return Qi(n)&&((e=n[zi])!==void 0?!!e:Ki(n)=="RegExp")},Yi=Xi,Zi=Ue,ki=function(n,e,r){if(Yi(e))throw TypeError("String#"+r+" doesn't accept regex!");return String(Zi(n))},me,qn;function ea(){if(qn)return me;qn=1;var n=T("match");return me=function(e){var r=/./;try{"/./"[e](r)}catch{try{return r[n]=!1,!"/./"[e](r)}catch{}}return!0},me}var Ee=I,na=ki,Mn="includes";Ee(Ee.P+Ee.F*ea()(Mn),"String",{includes:function(e){return!!~na(this,e,Mn).indexOf(e,arguments.length>1?arguments[1]:void 0)}});function ra(n,e,r){return e in n?Object.defineProperty(n,e,{value:r,enumerable:!0,configurable:!0,writable:!0}):n[e]=r,n}var ta=ra,ia=ta;function aa(n){for(var e=1;e<arguments.length;e++){var r=arguments[e]!=null?arguments[e]:{},t=Object.keys(r);typeof Object.getOwnPropertySymbols=="function"&&(t=t.concat(Object.getOwnPropertySymbols(r).filter(function(a){return Object.getOwnPropertyDescriptor(r,a).enumerable}))),t.forEach(function(a){ia(n,a,r[a])})}return n}var ua=aa;const O=ee(ua);function oa(n,e){if(n==null)return{};var r={},t=Object.keys(n),a,u;for(u=0;u<t.length;u++)a=t[u],!(e.indexOf(a)>=0)&&(r[a]=n[a]);return r}var sa=oa,ca=sa;function da(n,e){if(n==null)return{};var r=ca(n,e),t,a;if(Object.getOwnPropertySymbols){var u=Object.getOwnPropertySymbols(n);for(a=0;a<u.length;a++)t=u[a],!(e.indexOf(t)>=0)&&Object.prototype.propertyIsEnumerable.call(n,t)&&(r[t]=n[t])}return r}var fa=da;const te=ee(fa);var Ce=I,va=Be(!1),xe=[].indexOf,Ln=!!xe&&1/[1].indexOf(1,-0)<0;Ce(Ce.P+Ce.F*(Ln||!lr(xe)),"Array",{indexOf:function(e){return Ln?xe.apply(this,arguments)||0:va(this,e,arguments[1])}});var Se,Nn;function la(){return Nn||(Nn=1,Se=function(n,e,r){var t=r===void 0;switch(e.length){case 0:return t?n():n.call(r);case 1:return t?n(e[0]):n.call(r,e[0]);case 2:return t?n(e[0],e[1]):n.call(r,e[0],e[1]);case 3:return t?n(e[0],e[1],e[2]):n.call(r,e[0],e[1],e[2]);case 4:return t?n(e[0],e[1],e[2],e[3]):n.call(r,e[0],e[1],e[2],e[3])}return n.apply(r,e)}),Se}var Ae,Dn;function ha(){if(Dn)return Ae;Dn=1;var n=Xn,e=M,r=la(),t=[].slice,a={},u=function(o,s,d){if(!(s in a)){for(var f=[],l=0;l<s;l++)f[l]="a["+l+"]";a[s]=Function("F,a","return new F("+f.join(",")+")")}return a[s](o,d)};return Ae=Function.bind||function(s){var d=n(this),f=t.call(arguments,1),l=function(){var c=f.concat(t.call(arguments));return this instanceof l?u(d,c.length,c):r(d,c,s)};return e(d.prototype)&&(l.prototype=d.prototype),l},Ae}var Fn=I;Fn(Fn.P,"Function",{bind:ha()});function ba(n,e){if(n!==e)throw new TypeError("Cannot instantiate an arrow function")}var pa=ba;const i=ee(pa);var ya=void 0,Ke=function(e){var r=e.activeObservers,t=e.canceledObservers,a=te(e,["activeObservers","canceledObservers"]);return i(this,ya),O({},a,{isActive:!1,activeObservers:[],canceledObservers:F(r).concat(F(t))})}.bind(void 0),ze=void 0,_a=function(e,r){var t=this;return i(this,ze),function(a){return i(this,t),a[e]&&a[e](r)}.bind(this)}.bind(void 0),ga=function(e){var r=e.name;return i(this,ze),"on".concat(r)}.bind(void 0),Xe=function(e,r){return i(this,ze),e.forEach(_a(ga(r),r.payload))}.bind(void 0),Oa=void 0,hr=function(e,r){return i(this,Oa),Xe(e.canceledObservers,r),e}.bind(void 0),G={abort:"Abort",cancel:"Cancel",error:"Error",result:"Result",start:"Start"},V=void 0,$a=function(e){return i(this,V),{payload:e,name:G.start}}.bind(void 0),ma=function(e){return i(this,V),{payload:e,name:G.result}}.bind(void 0),ie=function(e){return i(this,V),{payload:e,name:G.error}}.bind(void 0),Ea=function(){return i(this,V),{name:G.cancel,payload:void 0}}.bind(void 0),Ca=function(e){return i(this,V),{payload:e,name:G.abort}}.bind(void 0),br=void 0,Sa=function(e){return i(this,br),O({},e,{canceledObservers:[]})}.bind(void 0),J=function(e){return i(this,br),e.canceledObservers.length>0?Sa(hr(e,Ea())):e}.bind(void 0),Aa=void 0,pr=function(e,r,t){return i(this,Aa),e.findIndex(Vn([r],t))}.bind(void 0),Ia=void 0,Ye=function(e){var r=this;return i(this,Ia),function(t){return i(this,r),Br(pr(t,"request",e.request),[e],t)}.bind(this)}.bind(void 0),Ta=void 0,B=function(e){var r=this;return i(this,Ta),function(t){return i(this,r),Jn(pr(t,"request",e.request),1,t)}.bind(this)}.bind(void 0),wa=void 0,E=function(e,r){return i(this,wa),e.notifiers=r(e.notifiers),e}.bind(void 0),ja=void 0,C=function(e,r){return i(this,ja),E(e,Ye(r)),r}.bind(void 0),$={canceled:"canceled",canceling:"canceling",pending:"pending",sent:"sent",sending:"sending"},yr=void 0,Pa=function(e){var r=e.activeObservers,t=e.canceledObservers;return i(this,yr),F(r).concat(F(t))}.bind(void 0),_r=function(e,r){return i(this,yr),Xe(Pa(e),r),e}.bind(void 0),xa=void 0,Ze=function(e,r,t){return i(this,xa),E(e,B(_r(r,Ca(t))))}.bind(void 0),Ra=void 0,ae=function(e,r,t){return i(this,Ra),e.find(Vn([r],t))}.bind(void 0),qa=void 0,ue=function(e,r){return i(this,qa),Xe(e.activeObservers,r),e}.bind(void 0),Ma=void 0,gr=function(e,r){return i(this,Ma),ue(e,ma(r))}.bind(void 0),La=void 0,Or=function(e){return i(this,La),ue(e,$a(e))}.bind(void 0),Na=void 0,$r=function(e){return i(this,Na),J(O({},e,{isActive:!0,requestStatus:$.pending,subscriptionId:void 0}))}.bind(void 0),Da=void 0,mr=function(e,r){return i(this,Da),e.receive("ok",r.onSucceed).receive("error",r.onError).receive("timeout",r.onTimeout)}.bind(void 0),ke=void 0,Fa=function(e,r){var t=this;return i(this,ke),function(a){var u=this;return i(this,t),function(){i(this,u);var o=ae(e.notifiers,"request",r);if(o){for(var s=arguments.length,d=new Array(s),f=0;f<s;f++)d[f]=arguments[f];a.apply(void 0,[e,o].concat(d))}}.bind(this)}.bind(this)}.bind(void 0),Ha=function(e,r,t){return i(this,ke),Hr(Fa(e,r),t)}.bind(void 0),Er=function(e,r,t,a){return i(this,ke),mr(e.channel.push(a.name,a.payload),Ha(e,r,t)),e}.bind(void 0),Cr={doc:"doc",unsubscribe:"unsubscribe"},Sr=void 0,Ua=function(e){return i(this,Sr),{payload:e,name:Cr.unsubscribe}}.bind(void 0),Ga=function(e){return i(this,Sr),{payload:e,name:Cr.doc}}.bind(void 0),P=void 0,Va=function(e,r,t){var a=r.request;return i(this,P),Er(e,a,t,Ga(Ur(a)))}.bind(void 0),Ja=function(e,r){return i(this,P),C(e,O({},r,{requestStatus:$.sending}))}.bind(void 0),Ar=function(e){return i(this,P),new Error("request: ".concat(e))}.bind(void 0),Ba=function(e,r){return i(this,P),ue(r,ie(Ar("timeout")))}.bind(void 0),Ir=function(e,r,t){return i(this,P),Ze(e,r,Ar(t))}.bind(void 0),Wa=function(e){return i(this,P),{onError:Ir,onSucceed:e,onTimeout:Ba}}.bind(void 0),Tr=function(e,r,t){return i(this,P),Va(e,Ja(e,r),Wa(t))}.bind(void 0),y=void 0,Qa=function(e,r){return i(this,y),E(e,B(J(r)))}.bind(void 0),Ka=function(e,r){return i(this,y),jr(e,C(e,$r(r)))}.bind(void 0),Hn=function(e){return i(this,y),new Error("unsubscribe: ".concat(e))}.bind(void 0),za={onError:function(e,r,t){return i(this,y),Ze(e,r,Hn(t))}.bind(void 0),onTimeout:function(e,r){return i(this,y),hr(r,ie(Hn("timeout")))}.bind(void 0),onSucceed:function(e,r){i(this,y),r.isActive?Ka(e,r):Qa(e,r)}.bind(void 0)},Xa=function(e,r){var t=r.request,a=r.subscriptionId;return i(this,y),Er(e,t,za,Ua({subscriptionId:a}))}.bind(void 0),wr=function(e,r){return i(this,y),Xa(e,C(e,O({},r,{requestStatus:$.canceling})))}.bind(void 0),Ya=function(e,r,t){var a=t.subscriptionId;i(this,y);var u=C(e,O({},r,{subscriptionId:a,requestStatus:$.sent}));u.isActive?Or(u):wr(e,u)}.bind(void 0),Za=function(e,r,t){i(this,y),t.errors?Ir(e,r,Gr(t.errors)):Ya(e,r,t)}.bind(void 0),jr=function(e,r){return i(this,y),Tr(e,r,Za)}.bind(void 0),ka=function(e,r){var t=r.payload;i(this,y);var a=ae(e.notifiers,"subscriptionId",t.subscriptionId);a&&gr(a,t.result)}.bind(void 0),eu="subscription:data",nu=function(e){return i(this,y),e.event===eu}.bind(void 0),S=void 0,ru=function(e,r){return i(this,S),E(e,Ye(J(Ke(r))))}.bind(void 0),tu=function(e,r){return i(this,S),r.requestStatus===$.sending?ru(e,r):e}.bind(void 0),Pr=function(e,r){return i(this,S),E(e,B(J(Ke(r))))}.bind(void 0),iu=function(e,r){return i(this,S),r.requestStatus===$.pending?Pr(e,r):tu(e,r)}.bind(void 0),au=function(e,r){return i(this,S),r.requestStatus===$.sent?wr(e,r):e}.bind(void 0),uu=function(e,r){return i(this,S),au(e,C(e,Ke(r)))}.bind(void 0),ou=function(e,r){return i(this,S),r.requestStatus===$.pending?Pr(e,r):uu(e,r)}.bind(void 0),su=function(e,r){return i(this,S),r.operationType==="subscription"?ou(e,r):iu(e,r)}.bind(void 0),cu=function(e,r){return i(this,S),r.isActive?su(e,r):e}.bind(void 0),oe=void 0,du=function(e,r){return i(this,oe),C(e,O({},r,{requestStatus:$.sent}))}.bind(void 0),fu=function(e,r,t){return i(this,oe),E(e,B(gr(du(e,r),t)))}.bind(void 0),vu=function(e,r){return i(this,oe),Tr(e,Or(r),fu)}.bind(void 0),xr=function(e,r){i(this,oe),r.operationType==="subscription"?jr(e,r):vu(e,r)}.bind(void 0),se=void 0,lu=function(e){return i(this,se),new Error("channel join: ".concat(e))}.bind(void 0),Un=function(e,r){var t=this;return i(this,se),e.notifiers.forEach(function(a){return i(this,t),ue(a,ie(lu(r)))}.bind(this))}.bind(void 0),hu=function(e){var r=this;return i(this,se),{onError:function(a){return i(this,r),Un(e,a)}.bind(this),onSucceed:function(){var a=this;return i(this,r),e.notifiers.forEach(function(u){return i(this,a),xr(e,u)}.bind(this))}.bind(this),onTimeout:function(){return i(this,r),Un(e,"timeout")}.bind(this)}}.bind(void 0),Rr=function(e){return i(this,se),mr(e.channel.join(),hu(e)),e.channelJoinCreated=!0,e}.bind(void 0),m=void 0,bu=function(e){var r=this;return i(this,m),function(t){i(this,r),nu(t)&&ka(e,t)}.bind(this)}.bind(void 0),qr=function(){return i(this,m),new Error("connection: close")}.bind(void 0),Mr=function(e){return i(this,m),_r(e,ie(qr()))}.bind(void 0),pu=function(e,r){return i(this,m),E(e,B(Mr(r)))}.bind(void 0),yu=function(e,r){i(this,m),r.operationType==="mutation"?Ze(e,r,qr()):C(e,$r(Mr(r)))}.bind(void 0),_u=function(e){var r=this;return i(this,m),function(t){i(this,r),t.isActive?yu(e,t):pu(e,t)}.bind(this)}.bind(void 0),gu=function(e){var r=this;return i(this,m),function(){return i(this,r),e.notifiers.forEach(_u(e))}.bind(this)}.bind(void 0),Ou=function(e){return i(this,m),!e.channelJoinCreated&&e.notifiers.length>0}.bind(void 0),$u=function(e){var r=this;return i(this,m),function(){i(this,r),Ou(e)&&Rr(e)}.bind(this)}.bind(void 0),mu="__absinthe__:control";(function(e){i(this,m);var r={phoenixSocket:e,channel:e.channel(mu),channelJoinCreated:!1,notifiers:[]};return e.onOpen($u(r)),e.onClose(gu(r)),e.onMessage(bu(r)),r}).bind(void 0);var Eu=void 0,Cu=function(e,r){var t=e.activeObservers,a=te(e,["activeObservers"]);return i(this,Eu),O({},a,{activeObservers:F(t).concat([r]),isActive:!0})}.bind(void 0),Su=void 0,Au=function(e,r,t){return i(this,Su),C(e,Cu(r,t))}.bind(void 0),Lr=void 0,Iu=function(e,r){return i(this,Lr),{operationType:r,request:e,activeObservers:[],canceledObservers:[],isActive:!0,requestStatus:$.pending,subscriptionId:void 0}}.bind(void 0),Tu=function(e){return i(this,Lr),Iu(e,Vr(e.operation))}.bind(void 0),wu=void 0,ju=function(e){return i(this,wu),e.isActive?e:O({},e,{isActive:!0})}.bind(void 0),x=void 0,Pu=function(e){i(this,x),e.phoenixSocket.isConnected()?Rr(e):e.phoenixSocket.connect()}.bind(void 0),xu=function(e,r){i(this,x);var t=Tu(r);return E(e,Wr([t])),e.channelJoinCreated?xr(e,t):Pu(e),t}.bind(void 0),Gn=function(e,r){return i(this,x),C(e,ju(r))}.bind(void 0),Ru=function(e,r){return i(this,x),r.requestStatus===$.sending?Gn(e,J(r)):Gn(e,r)}.bind(void 0),qu=function(e,r){return i(this,x),r.isActive?r:Ru(e,r)}.bind(void 0),Mu=function(e,r){i(this,x);var t=ae(e.notifiers,"request",r);return t&&qu(e,t)}.bind(void 0);(function(e,r){return i(this,x),Mu(e,r)||xu(e,r)}).bind(void 0);var ce=void 0,Lu=function(e,r,t,a){var u=this,o=r.request;return i(this,ce),function(){i(this,u);var s=ae(e.notifiers,"request",o);a(e,s,s?t:void 0)}.bind(this)}.bind(void 0),Nu=function(e,r){var t=this,a=e.operationType;return i(this,ce),function(u){i(this,t),r.next(u),a!=="subscription"&&r.complete()}.bind(this)}.bind(void 0),Du=function(e,r,t){return i(this,ce),O({},r,{onAbort:t.error.bind(t),onResult:Nu(e,t)})}.bind(void 0);(function(e,r){var t=this,a=arguments.length>2&&arguments[2]!==void 0?arguments[2]:{},u=a.unsubscribe,o=te(a,["unsubscribe"]);return i(this,ce),new Jr(function(s){i(this,t);var d=Du(r,o,s);return Au(e,r,d),u&&Lu(e,r,d,u)}.bind(this))}).bind(void 0);var Nr=void 0,Fu=function(e,r){return i(this,Nr),Jn(e.indexOf(r),1,e)}.bind(void 0),Hu=function(e,r){var t=e.activeObservers,a=te(e,["activeObservers"]);return i(this,Nr),O({},a,{activeObservers:Fu(t,r)})}.bind(void 0),Dr=void 0,Uu=function(e,r){if(i(this,Dr),e.activeObservers.includes(r))return e;throw new Error("Observer is not attached to notifier")}.bind(void 0),Gu=function(e,r,t){return i(this,Dr),E(e,Ye(Hu(Uu(r,t),t)))}.bind(void 0),Fr=void 0,Vu=function(e,r,t){return i(this,Fr),r.activeObservers.length===1?cu(e,r):Gu(e,r,t)}.bind(void 0);(function(e,r,t){return i(this,Fr),r.isActive?Vu(e,r,t):e}).bind(void 0);export{Ku as c,ee as g};
1
+ import{h as Vn,m as Hr}from"./vendor.jumpn.utils-composite.js";import{r as Ur,e as Gr,g as Vr}from"./vendor.jumpn.utils-graphql.js";import{O as Jr}from"./vendor.zen-observable.js";import{r as Br,a as Jn,b as Wr}from"./vendor.jumpn.utils-array.js";(function(){try{var n=typeof window<"u"?window:typeof global<"u"?global:typeof self<"u"?self:{},e=new Error().stack;e&&(n._sentryDebugIds=n._sentryDebugIds||{},n._sentryDebugIds[e]="24bd7f79-0faf-463b-bc83-215370606281",n._sentryDebugIdIdentifier="sentry-dbid-24bd7f79-0faf-463b-bc83-215370606281")}catch{}})();var Qr=typeof window<"u"?window:typeof global<"u"?global:typeof self<"u"?self:{};Qr.SENTRY_RELEASE={id:"3c73c5939f5225144de71b1dbc691b2afedc69e6"};var Ku=typeof globalThis<"u"?globalThis:typeof window<"u"?window:typeof global<"u"?global:typeof self<"u"?self:{};function ee(n){return n&&n.__esModule&&Object.prototype.hasOwnProperty.call(n,"default")?n.default:n}var Bn={exports:{}},Kr=Bn.exports=typeof window<"u"&&window.Math==Math?window:typeof self<"u"&&self.Math==Math?self:Function("return this")();typeof __g=="number"&&(__g=Kr);var j=Bn.exports,Wn={exports:{}},zr=Wn.exports={version:"2.6.0"};typeof __e=="number"&&(__e=zr);var Re=Wn.exports,H={},M=function(n){return typeof n=="object"?n!==null:typeof n=="function"},Xr=M,qe=function(n){if(!Xr(n))throw TypeError(n+" is not an object!");return n},Me=function(n){try{return!!n()}catch{return!0}},U=!Me(function(){return Object.defineProperty({},"a",{get:function(){return 7}}).a!=7}),de,nn;function Qn(){if(nn)return de;nn=1;var n=M,e=j.document,r=n(e)&&n(e.createElement);return de=function(t){return r?e.createElement(t):{}},de}var Yr=!U&&!Me(function(){return Object.defineProperty(Qn()("div"),"a",{get:function(){return 7}}).a!=7}),W=M,Zr=function(n,e){if(!W(n))return n;var r,t;if(e&&typeof(r=n.toString)=="function"&&!W(t=r.call(n))||typeof(r=n.valueOf)=="function"&&!W(t=r.call(n))||!e&&typeof(r=n.toString)=="function"&&!W(t=r.call(n)))return t;throw TypeError("Can't convert object to primitive value")},rn=qe,kr=Yr,et=Zr,nt=Object.defineProperty;H.f=U?Object.defineProperty:function(e,r,t){if(rn(e),r=et(r,!0),rn(t),kr)try{return nt(e,r,t)}catch{}if("get"in t||"set"in t)throw TypeError("Accessors not supported!");return"value"in t&&(e[r]=t.value),e};var Kn=function(n,e){return{enumerable:!(n&1),configurable:!(n&2),writable:!(n&4),value:e}},rt=H,tt=Kn,L=U?function(n,e,r){return rt.f(n,e,tt(1,r))}:function(n,e,r){return n[e]=r,n},zn={exports:{}},it={}.hasOwnProperty,ne=function(n,e){return it.call(n,e)},at=0,ut=Math.random(),Le=function(n){return"Symbol(".concat(n===void 0?"":n,")_",(++at+ut).toString(36))},ot=j,Q=L,tn=ne,fe=Le("src"),Ne="toString",De=Function[Ne],st=(""+De).split(Ne);Re.inspectSource=function(n){return De.call(n)};(zn.exports=function(n,e,r,t){var a=typeof r=="function";a&&(tn(r,"name")||Q(r,"name",e)),n[e]!==r&&(a&&(tn(r,fe)||Q(r,fe,n[e]?""+n[e]:st.join(String(e)))),n===ot?n[e]=r:t?n[e]?n[e]=r:Q(n,e,r):(delete n[e],Q(n,e,r)))})(Function.prototype,Ne,function(){return typeof this=="function"&&this[fe]||De.call(this)});var Fe=zn.exports,Xn=function(n){if(typeof n!="function")throw TypeError(n+" is not a function!");return n},ct=Xn,Yn=function(n,e,r){if(ct(n),e===void 0)return n;switch(r){case 1:return function(t){return n.call(e,t)};case 2:return function(t,a){return n.call(e,t,a)};case 3:return function(t,a,u){return n.call(e,t,a,u)}}return function(){return n.apply(e,arguments)}},q=j,Z=Re,dt=L,ft=Fe,an=Yn,ve="prototype",h=function(n,e,r){var t=n&h.F,a=n&h.G,u=n&h.S,o=n&h.P,s=n&h.B,d=a?q:u?q[e]||(q[e]={}):(q[e]||{})[ve],f=a?Z:Z[e]||(Z[e]={}),l=f[ve]||(f[ve]={}),c,b,v,R;a&&(r=e);for(c in r)b=!t&&d&&d[c]!==void 0,v=(b?d:r)[c],R=s&&b?an(v,q):o&&typeof v=="function"?an(Function.call,v):v,d&&ft(d,c,v,n&h.U),f[c]!=v&&dt(f,c,R),o&&l[c]!=v&&(l[c]=v)};q.core=Z;h.F=1;h.G=2;h.S=4;h.P=8;h.B=16;h.W=32;h.U=64;h.R=128;var I=h,vt={}.toString,He=function(n){return vt.call(n).slice(8,-1)},lt=He,Zn=Object("z").propertyIsEnumerable(0)?Object:function(n){return lt(n)=="String"?n.split(""):Object(n)},Ue=function(n){if(n==null)throw TypeError("Can't call method on "+n);return n},ht=Ue,kn=function(n){return Object(ht(n))},bt=Math.ceil,pt=Math.floor,er=function(n){return isNaN(n=+n)?0:(n>0?pt:bt)(n)},yt=er,_t=Math.min,nr=function(n){return n>0?_t(yt(n),9007199254740991):0},gt=He,Ot=Array.isArray||function(e){return gt(e)=="Array"},rr={exports:{}},tr={exports:{}},$t=Re,un=j,on="__core-js_shared__",sn=un[on]||(un[on]={});(tr.exports=function(n,e){return sn[n]||(sn[n]=e!==void 0?e:{})})("versions",[]).push({version:$t.version,mode:"global",copyright:"© 2018 Denis Pushkarev (zloirock.ru)"});var ir=tr.exports,Ie=ir("wks"),mt=Le,Te=j.Symbol,cn=typeof Te=="function",Et=rr.exports=function(n){return Ie[n]||(Ie[n]=cn&&Te[n]||(cn?Te:mt)("Symbol."+n))};Et.store=Ie;var T=rr.exports,Ct=M,dn=Ot,St=T("species"),At=function(n){var e;return dn(n)&&(e=n.constructor,typeof e=="function"&&(e===Array||dn(e.prototype))&&(e=void 0),Ct(e)&&(e=e[St],e===null&&(e=void 0))),e===void 0?Array:e},It=At,Tt=function(n,e){return new(It(n))(e)},wt=Yn,jt=Zn,Pt=kn,xt=nr,Rt=Tt,Ge=function(n,e){var r=n==1,t=n==2,a=n==3,u=n==4,o=n==6,s=n==5||o,d=e||Rt;return function(f,l,c){for(var b=Pt(f),v=jt(b),R=wt(l,c,3),N=xt(v.length),p=0,A=r?d(f,N):t?d(f,0):void 0,_,g;N>p;p++)if((s||p in v)&&(_=v[p],g=R(_,p,b),n)){if(r)A[p]=g;else if(g)switch(n){case 3:return!0;case 5:return _;case 6:return p;case 2:A.push(_)}else if(u)return!1}return o?-1:a||u?u:A}},le,fn;function re(){if(fn)return le;fn=1;var n=T("unscopables"),e=Array.prototype;return e[n]==null&&L(e,n,{}),le=function(r){e[n][r]=!0},le}var he=I,qt=Ge(6),we="findIndex",ar=!0;we in[]&&Array(1)[we](function(){ar=!1});he(he.P+he.F*ar,"Array",{findIndex:function(e){return qt(this,e,arguments.length>1?arguments[1]:void 0)}});re()(we);var be=I,Mt=Ge(5),je="find",ur=!0;je in[]&&Array(1)[je](function(){ur=!1});be(be.P+be.F*ur,"Array",{find:function(e){return Mt(this,e,arguments.length>1?arguments[1]:void 0)}});re()(je);var Lt=H.f,vn=Function.prototype,Nt=/^\s*function ([^ (]*)/,ln="name";ln in vn||U&&Lt(vn,ln,{configurable:!0,get:function(){try{return(""+this).match(Nt)[1]}catch{return""}}});var Dt=function(n,e){return{value:e,done:!!n}},Ve={},Ft=Zn,Ht=Ue,Je=function(n){return Ft(Ht(n))},Ut=er,Gt=Math.max,Vt=Math.min,Jt=function(n,e){return n=Ut(n),n<0?Gt(n+e,0):Vt(n,e)},Bt=Je,Wt=nr,Qt=Jt,Be=function(n){return function(e,r,t){var a=Bt(e),u=Wt(a.length),o=Qt(t,u),s;if(n&&r!=r){for(;u>o;)if(s=a[o++],s!=s)return!0}else for(;u>o;o++)if((n||o in a)&&a[o]===r)return n||o||0;return!n&&-1}},hn=ir("keys"),Kt=Le,We=function(n){return hn[n]||(hn[n]=Kt(n))},bn=ne,zt=Je,Xt=Be(!1),Yt=We("IE_PROTO"),Zt=function(n,e){var r=zt(n),t=0,a=[],u;for(u in r)u!=Yt&&bn(r,u)&&a.push(u);for(;e.length>t;)bn(r,u=e[t++])&&(~Xt(a,u)||a.push(u));return a},or="constructor,hasOwnProperty,isPrototypeOf,propertyIsEnumerable,toLocaleString,toString,valueOf".split(","),kt=Zt,ei=or,sr=Object.keys||function(e){return kt(e,ei)},ni=H,ri=qe,ti=sr,ii=U?Object.defineProperties:function(e,r){ri(e);for(var t=ti(r),a=t.length,u=0,o;a>u;)ni.f(e,o=t[u++],r[o]);return e},pe,pn;function ai(){if(pn)return pe;pn=1;var n=j.document;return pe=n&&n.documentElement,pe}var ui=qe,oi=ii,yn=or,si=We("IE_PROTO"),ye=function(){},Pe="prototype",k=function(){var n=Qn()("iframe"),e=yn.length,r="<",t=">",a;for(n.style.display="none",ai().appendChild(n),n.src="javascript:",a=n.contentWindow.document,a.open(),a.write(r+"script"+t+"document.F=Object"+r+"/script"+t),a.close(),k=a.F;e--;)delete k[Pe][yn[e]];return k()},ci=Object.create||function(e,r){var t;return e!==null?(ye[Pe]=ui(e),t=new ye,ye[Pe]=null,t[si]=e):t=k(),r===void 0?t:oi(t,r)},di=H.f,fi=ne,_n=T("toStringTag"),cr=function(n,e,r){n&&!fi(n=r?n:n.prototype,_n)&&di(n,_n,{configurable:!0,value:e})},vi=ci,li=Kn,hi=cr,dr={};L(dr,T("iterator"),function(){return this});var bi=function(n,e,r){n.prototype=vi(dr,{next:li(1,r)}),hi(n,e+" Iterator")},pi=ne,yi=kn,gn=We("IE_PROTO"),_i=Object.prototype,gi=Object.getPrototypeOf||function(n){return n=yi(n),pi(n,gn)?n[gn]:typeof n.constructor=="function"&&n instanceof n.constructor?n.constructor.prototype:n instanceof Object?_i:null},_e=I,Oi=Fe,On=L,$n=Ve,$i=bi,mi=cr,Ei=gi,D=T("iterator"),ge=!([].keys&&"next"in[].keys()),Ci="@@iterator",mn="keys",K="values",En=function(){return this},Si=function(n,e,r,t,a,u,o){$i(r,e,t);var s=function(g){if(!ge&&g in c)return c[g];switch(g){case mn:return function(){return new r(this,g)};case K:return function(){return new r(this,g)}}return function(){return new r(this,g)}},d=e+" Iterator",f=a==K,l=!1,c=n.prototype,b=c[D]||c[Ci]||a&&c[a],v=b||s(a),R=a?f?s("entries"):v:void 0,N=e=="Array"&&c.entries||b,p,A,_;if(N&&(_=Ei(N.call(new n)),_!==Object.prototype&&_.next&&(mi(_,d,!0),typeof _[D]!="function"&&On(_,D,En))),f&&b&&b.name!==K&&(l=!0,v=function(){return b.call(this)}),(ge||l||!c[D])&&On(c,D,v),$n[e]=v,$n[d]=En,a)if(p={values:f?v:s(K),keys:u?v:s(mn),entries:R},o)for(A in p)A in c||Oi(c,A,p[A]);else _e(_e.P+_e.F*(ge||l),e,p);return p},Qe=re(),z=Dt,Cn=Ve,Ai=Je,Ii=Si(Array,"Array",function(n,e){this._t=Ai(n),this._i=0,this._k=e},function(){var n=this._t,e=this._k,r=this._i++;return!n||r>=n.length?(this._t=void 0,z(1)):e=="keys"?z(0,r):e=="values"?z(0,n[r]):z(0,[r,n[r]])},"values");Cn.Arguments=Cn.Array;Qe("keys");Qe("values");Qe("entries");var Sn=Ii,Ti=sr,wi=Fe,ji=j,An=L,fr=Ve,vr=T,In=vr("iterator"),Tn=vr("toStringTag"),wn=fr.Array,jn={CSSRuleList:!0,CSSStyleDeclaration:!1,CSSValueList:!1,ClientRectList:!1,DOMRectList:!1,DOMStringList:!1,DOMTokenList:!0,DataTransferItemList:!1,FileList:!1,HTMLAllCollection:!1,HTMLCollection:!1,HTMLFormElement:!1,HTMLSelectElement:!1,MediaList:!0,MimeTypeArray:!1,NamedNodeMap:!1,NodeList:!0,PaintRequestList:!1,Plugin:!1,PluginArray:!1,SVGLengthList:!1,SVGNumberList:!1,SVGPathSegList:!1,SVGPointList:!1,SVGStringList:!1,SVGTransformList:!1,SourceBufferList:!1,StyleSheetList:!0,TextTrackCueList:!1,TextTrackList:!1,TouchList:!1};for(var Pn=Ti(jn),Oe=0;Oe<Pn.length;Oe++){var X=Pn[Oe],Pi=jn[X],xn=ji[X],w=xn&&xn.prototype,Y;if(w&&(w[In]||An(w,In,wn),w[Tn]||An(w,Tn,X),fr[X]=wn,Pi))for(Y in Sn)w[Y]||wi(w,Y,Sn[Y],!0)}var xi=Me,lr=function(n,e){return!!n&&xi(function(){e?n.call(null,function(){},1):n.call(null)})},$e=I,Ri=Ge(0),qi=lr([].forEach,!0);$e($e.P+$e.F*!qi,"Array",{forEach:function(e){return Ri(this,e,arguments[1])}});function Mi(n){if(Array.isArray(n)){for(var e=0,r=new Array(n.length);e<n.length;e++)r[e]=n[e];return r}}var Li=Mi;function Ni(n){if(Symbol.iterator in Object(n)||Object.prototype.toString.call(n)==="[object Arguments]")return Array.from(n)}var Di=Ni;function Fi(){throw new TypeError("Invalid attempt to spread non-iterable instance")}var Hi=Fi,Ui=Li,Gi=Di,Vi=Hi;function Ji(n){return Ui(n)||Gi(n)||Vi()}var Bi=Ji;const F=ee(Bi);var Rn=I,Wi=Be(!0);Rn(Rn.P,"Array",{includes:function(e){return Wi(this,e,arguments.length>1?arguments[1]:void 0)}});re()("includes");var Qi=M,Ki=He,zi=T("match"),Xi=function(n){var e;return Qi(n)&&((e=n[zi])!==void 0?!!e:Ki(n)=="RegExp")},Yi=Xi,Zi=Ue,ki=function(n,e,r){if(Yi(e))throw TypeError("String#"+r+" doesn't accept regex!");return String(Zi(n))},me,qn;function ea(){if(qn)return me;qn=1;var n=T("match");return me=function(e){var r=/./;try{"/./"[e](r)}catch{try{return r[n]=!1,!"/./"[e](r)}catch{}}return!0},me}var Ee=I,na=ki,Mn="includes";Ee(Ee.P+Ee.F*ea()(Mn),"String",{includes:function(e){return!!~na(this,e,Mn).indexOf(e,arguments.length>1?arguments[1]:void 0)}});function ra(n,e,r){return e in n?Object.defineProperty(n,e,{value:r,enumerable:!0,configurable:!0,writable:!0}):n[e]=r,n}var ta=ra,ia=ta;function aa(n){for(var e=1;e<arguments.length;e++){var r=arguments[e]!=null?arguments[e]:{},t=Object.keys(r);typeof Object.getOwnPropertySymbols=="function"&&(t=t.concat(Object.getOwnPropertySymbols(r).filter(function(a){return Object.getOwnPropertyDescriptor(r,a).enumerable}))),t.forEach(function(a){ia(n,a,r[a])})}return n}var ua=aa;const O=ee(ua);function oa(n,e){if(n==null)return{};var r={},t=Object.keys(n),a,u;for(u=0;u<t.length;u++)a=t[u],!(e.indexOf(a)>=0)&&(r[a]=n[a]);return r}var sa=oa,ca=sa;function da(n,e){if(n==null)return{};var r=ca(n,e),t,a;if(Object.getOwnPropertySymbols){var u=Object.getOwnPropertySymbols(n);for(a=0;a<u.length;a++)t=u[a],!(e.indexOf(t)>=0)&&Object.prototype.propertyIsEnumerable.call(n,t)&&(r[t]=n[t])}return r}var fa=da;const te=ee(fa);var Ce=I,va=Be(!1),xe=[].indexOf,Ln=!!xe&&1/[1].indexOf(1,-0)<0;Ce(Ce.P+Ce.F*(Ln||!lr(xe)),"Array",{indexOf:function(e){return Ln?xe.apply(this,arguments)||0:va(this,e,arguments[1])}});var Se,Nn;function la(){return Nn||(Nn=1,Se=function(n,e,r){var t=r===void 0;switch(e.length){case 0:return t?n():n.call(r);case 1:return t?n(e[0]):n.call(r,e[0]);case 2:return t?n(e[0],e[1]):n.call(r,e[0],e[1]);case 3:return t?n(e[0],e[1],e[2]):n.call(r,e[0],e[1],e[2]);case 4:return t?n(e[0],e[1],e[2],e[3]):n.call(r,e[0],e[1],e[2],e[3])}return n.apply(r,e)}),Se}var Ae,Dn;function ha(){if(Dn)return Ae;Dn=1;var n=Xn,e=M,r=la(),t=[].slice,a={},u=function(o,s,d){if(!(s in a)){for(var f=[],l=0;l<s;l++)f[l]="a["+l+"]";a[s]=Function("F,a","return new F("+f.join(",")+")")}return a[s](o,d)};return Ae=Function.bind||function(s){var d=n(this),f=t.call(arguments,1),l=function(){var c=f.concat(t.call(arguments));return this instanceof l?u(d,c.length,c):r(d,c,s)};return e(d.prototype)&&(l.prototype=d.prototype),l},Ae}var Fn=I;Fn(Fn.P,"Function",{bind:ha()});function ba(n,e){if(n!==e)throw new TypeError("Cannot instantiate an arrow function")}var pa=ba;const i=ee(pa);var ya=void 0,Ke=function(e){var r=e.activeObservers,t=e.canceledObservers,a=te(e,["activeObservers","canceledObservers"]);return i(this,ya),O({},a,{isActive:!1,activeObservers:[],canceledObservers:F(r).concat(F(t))})}.bind(void 0),ze=void 0,_a=function(e,r){var t=this;return i(this,ze),function(a){return i(this,t),a[e]&&a[e](r)}.bind(this)}.bind(void 0),ga=function(e){var r=e.name;return i(this,ze),"on".concat(r)}.bind(void 0),Xe=function(e,r){return i(this,ze),e.forEach(_a(ga(r),r.payload))}.bind(void 0),Oa=void 0,hr=function(e,r){return i(this,Oa),Xe(e.canceledObservers,r),e}.bind(void 0),G={abort:"Abort",cancel:"Cancel",error:"Error",result:"Result",start:"Start"},V=void 0,$a=function(e){return i(this,V),{payload:e,name:G.start}}.bind(void 0),ma=function(e){return i(this,V),{payload:e,name:G.result}}.bind(void 0),ie=function(e){return i(this,V),{payload:e,name:G.error}}.bind(void 0),Ea=function(){return i(this,V),{name:G.cancel,payload:void 0}}.bind(void 0),Ca=function(e){return i(this,V),{payload:e,name:G.abort}}.bind(void 0),br=void 0,Sa=function(e){return i(this,br),O({},e,{canceledObservers:[]})}.bind(void 0),J=function(e){return i(this,br),e.canceledObservers.length>0?Sa(hr(e,Ea())):e}.bind(void 0),Aa=void 0,pr=function(e,r,t){return i(this,Aa),e.findIndex(Vn([r],t))}.bind(void 0),Ia=void 0,Ye=function(e){var r=this;return i(this,Ia),function(t){return i(this,r),Br(pr(t,"request",e.request),[e],t)}.bind(this)}.bind(void 0),Ta=void 0,B=function(e){var r=this;return i(this,Ta),function(t){return i(this,r),Jn(pr(t,"request",e.request),1,t)}.bind(this)}.bind(void 0),wa=void 0,E=function(e,r){return i(this,wa),e.notifiers=r(e.notifiers),e}.bind(void 0),ja=void 0,C=function(e,r){return i(this,ja),E(e,Ye(r)),r}.bind(void 0),$={canceled:"canceled",canceling:"canceling",pending:"pending",sent:"sent",sending:"sending"},yr=void 0,Pa=function(e){var r=e.activeObservers,t=e.canceledObservers;return i(this,yr),F(r).concat(F(t))}.bind(void 0),_r=function(e,r){return i(this,yr),Xe(Pa(e),r),e}.bind(void 0),xa=void 0,Ze=function(e,r,t){return i(this,xa),E(e,B(_r(r,Ca(t))))}.bind(void 0),Ra=void 0,ae=function(e,r,t){return i(this,Ra),e.find(Vn([r],t))}.bind(void 0),qa=void 0,ue=function(e,r){return i(this,qa),Xe(e.activeObservers,r),e}.bind(void 0),Ma=void 0,gr=function(e,r){return i(this,Ma),ue(e,ma(r))}.bind(void 0),La=void 0,Or=function(e){return i(this,La),ue(e,$a(e))}.bind(void 0),Na=void 0,$r=function(e){return i(this,Na),J(O({},e,{isActive:!0,requestStatus:$.pending,subscriptionId:void 0}))}.bind(void 0),Da=void 0,mr=function(e,r){return i(this,Da),e.receive("ok",r.onSucceed).receive("error",r.onError).receive("timeout",r.onTimeout)}.bind(void 0),ke=void 0,Fa=function(e,r){var t=this;return i(this,ke),function(a){var u=this;return i(this,t),function(){i(this,u);var o=ae(e.notifiers,"request",r);if(o){for(var s=arguments.length,d=new Array(s),f=0;f<s;f++)d[f]=arguments[f];a.apply(void 0,[e,o].concat(d))}}.bind(this)}.bind(this)}.bind(void 0),Ha=function(e,r,t){return i(this,ke),Hr(Fa(e,r),t)}.bind(void 0),Er=function(e,r,t,a){return i(this,ke),mr(e.channel.push(a.name,a.payload),Ha(e,r,t)),e}.bind(void 0),Cr={doc:"doc",unsubscribe:"unsubscribe"},Sr=void 0,Ua=function(e){return i(this,Sr),{payload:e,name:Cr.unsubscribe}}.bind(void 0),Ga=function(e){return i(this,Sr),{payload:e,name:Cr.doc}}.bind(void 0),P=void 0,Va=function(e,r,t){var a=r.request;return i(this,P),Er(e,a,t,Ga(Ur(a)))}.bind(void 0),Ja=function(e,r){return i(this,P),C(e,O({},r,{requestStatus:$.sending}))}.bind(void 0),Ar=function(e){return i(this,P),new Error("request: ".concat(e))}.bind(void 0),Ba=function(e,r){return i(this,P),ue(r,ie(Ar("timeout")))}.bind(void 0),Ir=function(e,r,t){return i(this,P),Ze(e,r,Ar(t))}.bind(void 0),Wa=function(e){return i(this,P),{onError:Ir,onSucceed:e,onTimeout:Ba}}.bind(void 0),Tr=function(e,r,t){return i(this,P),Va(e,Ja(e,r),Wa(t))}.bind(void 0),y=void 0,Qa=function(e,r){return i(this,y),E(e,B(J(r)))}.bind(void 0),Ka=function(e,r){return i(this,y),jr(e,C(e,$r(r)))}.bind(void 0),Hn=function(e){return i(this,y),new Error("unsubscribe: ".concat(e))}.bind(void 0),za={onError:function(e,r,t){return i(this,y),Ze(e,r,Hn(t))}.bind(void 0),onTimeout:function(e,r){return i(this,y),hr(r,ie(Hn("timeout")))}.bind(void 0),onSucceed:function(e,r){i(this,y),r.isActive?Ka(e,r):Qa(e,r)}.bind(void 0)},Xa=function(e,r){var t=r.request,a=r.subscriptionId;return i(this,y),Er(e,t,za,Ua({subscriptionId:a}))}.bind(void 0),wr=function(e,r){return i(this,y),Xa(e,C(e,O({},r,{requestStatus:$.canceling})))}.bind(void 0),Ya=function(e,r,t){var a=t.subscriptionId;i(this,y);var u=C(e,O({},r,{subscriptionId:a,requestStatus:$.sent}));u.isActive?Or(u):wr(e,u)}.bind(void 0),Za=function(e,r,t){i(this,y),t.errors?Ir(e,r,Gr(t.errors)):Ya(e,r,t)}.bind(void 0),jr=function(e,r){return i(this,y),Tr(e,r,Za)}.bind(void 0),ka=function(e,r){var t=r.payload;i(this,y);var a=ae(e.notifiers,"subscriptionId",t.subscriptionId);a&&gr(a,t.result)}.bind(void 0),eu="subscription:data",nu=function(e){return i(this,y),e.event===eu}.bind(void 0),S=void 0,ru=function(e,r){return i(this,S),E(e,Ye(J(Ke(r))))}.bind(void 0),tu=function(e,r){return i(this,S),r.requestStatus===$.sending?ru(e,r):e}.bind(void 0),Pr=function(e,r){return i(this,S),E(e,B(J(Ke(r))))}.bind(void 0),iu=function(e,r){return i(this,S),r.requestStatus===$.pending?Pr(e,r):tu(e,r)}.bind(void 0),au=function(e,r){return i(this,S),r.requestStatus===$.sent?wr(e,r):e}.bind(void 0),uu=function(e,r){return i(this,S),au(e,C(e,Ke(r)))}.bind(void 0),ou=function(e,r){return i(this,S),r.requestStatus===$.pending?Pr(e,r):uu(e,r)}.bind(void 0),su=function(e,r){return i(this,S),r.operationType==="subscription"?ou(e,r):iu(e,r)}.bind(void 0),cu=function(e,r){return i(this,S),r.isActive?su(e,r):e}.bind(void 0),oe=void 0,du=function(e,r){return i(this,oe),C(e,O({},r,{requestStatus:$.sent}))}.bind(void 0),fu=function(e,r,t){return i(this,oe),E(e,B(gr(du(e,r),t)))}.bind(void 0),vu=function(e,r){return i(this,oe),Tr(e,Or(r),fu)}.bind(void 0),xr=function(e,r){i(this,oe),r.operationType==="subscription"?jr(e,r):vu(e,r)}.bind(void 0),se=void 0,lu=function(e){return i(this,se),new Error("channel join: ".concat(e))}.bind(void 0),Un=function(e,r){var t=this;return i(this,se),e.notifiers.forEach(function(a){return i(this,t),ue(a,ie(lu(r)))}.bind(this))}.bind(void 0),hu=function(e){var r=this;return i(this,se),{onError:function(a){return i(this,r),Un(e,a)}.bind(this),onSucceed:function(){var a=this;return i(this,r),e.notifiers.forEach(function(u){return i(this,a),xr(e,u)}.bind(this))}.bind(this),onTimeout:function(){return i(this,r),Un(e,"timeout")}.bind(this)}}.bind(void 0),Rr=function(e){return i(this,se),mr(e.channel.join(),hu(e)),e.channelJoinCreated=!0,e}.bind(void 0),m=void 0,bu=function(e){var r=this;return i(this,m),function(t){i(this,r),nu(t)&&ka(e,t)}.bind(this)}.bind(void 0),qr=function(){return i(this,m),new Error("connection: close")}.bind(void 0),Mr=function(e){return i(this,m),_r(e,ie(qr()))}.bind(void 0),pu=function(e,r){return i(this,m),E(e,B(Mr(r)))}.bind(void 0),yu=function(e,r){i(this,m),r.operationType==="mutation"?Ze(e,r,qr()):C(e,$r(Mr(r)))}.bind(void 0),_u=function(e){var r=this;return i(this,m),function(t){i(this,r),t.isActive?yu(e,t):pu(e,t)}.bind(this)}.bind(void 0),gu=function(e){var r=this;return i(this,m),function(){return i(this,r),e.notifiers.forEach(_u(e))}.bind(this)}.bind(void 0),Ou=function(e){return i(this,m),!e.channelJoinCreated&&e.notifiers.length>0}.bind(void 0),$u=function(e){var r=this;return i(this,m),function(){i(this,r),Ou(e)&&Rr(e)}.bind(this)}.bind(void 0),mu="__absinthe__:control";(function(e){i(this,m);var r={phoenixSocket:e,channel:e.channel(mu),channelJoinCreated:!1,notifiers:[]};return e.onOpen($u(r)),e.onClose(gu(r)),e.onMessage(bu(r)),r}).bind(void 0);var Eu=void 0,Cu=function(e,r){var t=e.activeObservers,a=te(e,["activeObservers"]);return i(this,Eu),O({},a,{activeObservers:F(t).concat([r]),isActive:!0})}.bind(void 0),Su=void 0,Au=function(e,r,t){return i(this,Su),C(e,Cu(r,t))}.bind(void 0),Lr=void 0,Iu=function(e,r){return i(this,Lr),{operationType:r,request:e,activeObservers:[],canceledObservers:[],isActive:!0,requestStatus:$.pending,subscriptionId:void 0}}.bind(void 0),Tu=function(e){return i(this,Lr),Iu(e,Vr(e.operation))}.bind(void 0),wu=void 0,ju=function(e){return i(this,wu),e.isActive?e:O({},e,{isActive:!0})}.bind(void 0),x=void 0,Pu=function(e){i(this,x),e.phoenixSocket.isConnected()?Rr(e):e.phoenixSocket.connect()}.bind(void 0),xu=function(e,r){i(this,x);var t=Tu(r);return E(e,Wr([t])),e.channelJoinCreated?xr(e,t):Pu(e),t}.bind(void 0),Gn=function(e,r){return i(this,x),C(e,ju(r))}.bind(void 0),Ru=function(e,r){return i(this,x),r.requestStatus===$.sending?Gn(e,J(r)):Gn(e,r)}.bind(void 0),qu=function(e,r){return i(this,x),r.isActive?r:Ru(e,r)}.bind(void 0),Mu=function(e,r){i(this,x);var t=ae(e.notifiers,"request",r);return t&&qu(e,t)}.bind(void 0);(function(e,r){return i(this,x),Mu(e,r)||xu(e,r)}).bind(void 0);var ce=void 0,Lu=function(e,r,t,a){var u=this,o=r.request;return i(this,ce),function(){i(this,u);var s=ae(e.notifiers,"request",o);a(e,s,s?t:void 0)}.bind(this)}.bind(void 0),Nu=function(e,r){var t=this,a=e.operationType;return i(this,ce),function(u){i(this,t),r.next(u),a!=="subscription"&&r.complete()}.bind(this)}.bind(void 0),Du=function(e,r,t){return i(this,ce),O({},r,{onAbort:t.error.bind(t),onResult:Nu(e,t)})}.bind(void 0);(function(e,r){var t=this,a=arguments.length>2&&arguments[2]!==void 0?arguments[2]:{},u=a.unsubscribe,o=te(a,["unsubscribe"]);return i(this,ce),new Jr(function(s){i(this,t);var d=Du(r,o,s);return Au(e,r,d),u&&Lu(e,r,d,u)}.bind(this))}).bind(void 0);var Nr=void 0,Fu=function(e,r){return i(this,Nr),Jn(e.indexOf(r),1,e)}.bind(void 0),Hu=function(e,r){var t=e.activeObservers,a=te(e,["activeObservers"]);return i(this,Nr),O({},a,{activeObservers:Fu(t,r)})}.bind(void 0),Dr=void 0,Uu=function(e,r){if(i(this,Dr),e.activeObservers.includes(r))return e;throw new Error("Observer is not attached to notifier")}.bind(void 0),Gu=function(e,r,t){return i(this,Dr),E(e,Ye(Hu(Uu(r,t),t)))}.bind(void 0),Fr=void 0,Vu=function(e,r,t){return i(this,Fr),r.activeObservers.length===1?cu(e,r):Gu(e,r,t)}.bind(void 0);(function(e,r,t){return i(this,Fr),r.isActive?Vu(e,r,t):e}).bind(void 0);export{Ku as c,ee as g};
2
2
  //# sourceMappingURL=vendor.absinthe.socket.js.map