@holdyapp/sdk 1.5.0 → 1.6.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +1 -0
- package/dist/holdy.js +2 -2
- package/dist/holdy.js.map +4 -4
- package/dist/index.cjs +126 -3
- package/dist/index.cjs.map +4 -4
- package/dist/index.mjs +126 -3
- package/dist/index.mjs.map +4 -4
- package/dist/skeleton.d.ts +50 -0
- package/dist/skeleton.d.ts.map +1 -0
- package/dist/web.d.ts +8 -0
- package/dist/web.d.ts.map +1 -1
- package/dist/web.mjs +126 -3
- package/dist/web.mjs.map +4 -4
- package/package.json +1 -1
- package/src/skeleton.test.ts +60 -0
- package/src/skeleton.ts +173 -0
- package/src/web.ts +20 -1
package/README.md
CHANGED
|
@@ -32,6 +32,7 @@ O SDK web observa sozinho os sinais de fricção e emite eventos determinístico
|
|
|
32
32
|
| `$http_error` | `fetch`/XHR com status ≥ 400 ou sem resposta (cancelado não conta), ou a própria página abrindo com status ≥ 400 | `url` (sem query), `method`, `duration_ms`, `status` ou `failed`; `document: true` quando é a página |
|
|
33
33
|
|
|
34
34
|
Requisição pra URL da Holdy nunca vira `$http_error`; `ignoreUrls` acrescenta outras (prefixo).
|
|
35
|
+
| `$page_skeleton` | esqueleto da página, uma vez por (rota, estrutura) por aba: elementos interativos sem texto livre nem valor de input | `path`, `hash`, `count`, `elements` |
|
|
35
36
|
|
|
36
37
|
```ts
|
|
37
38
|
initHoldy({ apiKey, friction: false }) // desliga
|
package/dist/holdy.js
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
|
-
"use strict";var Holdy=(()=>{var N=Object.defineProperty;var ht=Object.getOwnPropertyDescriptor;var ft=Object.getOwnPropertyNames;var gt=Object.prototype.hasOwnProperty;var mt=(e,t)=>{for(var n in t)N(e,n,{get:t[n],enumerable:!0})},yt=(e,t,n,r)=>{if(t&&typeof t=="object"||typeof t=="function")for(let i of ft(t))!gt.call(e,i)&&i!==n&&N(e,i,{get:()=>t[i],enumerable:!(r=ht(t,i))||r.enumerable});return e};var vt=e=>yt(N({},"__esModule",{value:!0}),e);var pe={};mt(pe,{flush:()=>le,getInstance:()=>de,group:()=>se,identify:()=>ie,init:()=>re,page:()=>ae,reset:()=>ue,shutdown:()=>ce,track:()=>oe});var wt="https://holdy.chat/api/v1";var I=class{apiKey;baseUrl;flushAt;debug;source;queue=[];timer=null;flushing=null;retryAt=0;failures=0;warned=new Set;userId=null;anonymousId=null;accountKey=null;constructor(t,n){this.source=t,this.apiKey=n.apiKey,this.accountKey=n.accountKey??null,this.baseUrl=(n.baseUrl??wt).replace(/\/$/,""),this.flushAt=Math.max(1,n.flushAt??20),this.debug=n.debug??!1;let r=n.flushIntervalMs??5e3;r>0&&(this.timer=setInterval(()=>void this.flush(),r),typeof this.timer.unref=="function"&&this.timer.unref())}track(t,n,r){if(!t||typeof t!="string")return;let i=r?.userId??this.userId??void 0,l=r?.accountKey??this.accountKey??void 0,c=r?.occurredAt?new Date(r.occurredAt).toISOString():new Date().toISOString(),p={...this.environmentContext(),...r?.context??{}};l&&(p.account_external_id=l);let f={event:t,occurred_at:c,source:this.source,external_id:xt(),...i?{user_id:i}:{},...this.anonymousId?{anonymous_id:this.anonymousId}:{},properties:n??{},...Object.keys(p).length>0?{context:p}:{}};this.queue.push(f),this.trimQueue(),this.queue.length>=this.flushAt&&this.flush()}identify(t,n){!t||typeof t!="string"||(this.userId=t,this.track("$identify",n??{}))}group(t,n){!t||typeof t!="string"||(this.accountKey=t,this.track("$group",n??{}))}async flush(){return this.startFlush(!1)}async shutdown(){this.timer&&(clearInterval(this.timer),this.timer=null),await this.startFlush(!0)}startFlush(t){return this.flushing?this.flushing:this.queue.length===0||!t&&Date.now()<this.retryAt?Promise.resolve():(this.flushing=this.drain().finally(()=>{this.flushing=null}),this.flushing)}async drain(){for(;this.queue.length>0;){let t=this.queue.splice(0,500),n=await this.send(t);if(n.kind==="retry"){this.queue.unshift(...t),this.trimQueue(),this.scheduleRetry(n.afterMs);return}this.failures=0,this.retryAt=0}}scheduleRetry(t){if(this.failures+=1,t!==null){this.retryAt=Date.now()+t;return}let n=Math.min(6e4,1e3*2**(this.failures-1));this.retryAt=Date.now()+n+Math.floor(Math.random()*n*.2)}trimQueue(){this.queue.length>1e3&&this.queue.splice(0,this.queue.length-1e3)}async send(t){try{let n=await fetch(`${this.baseUrl}/events/bulk`,{method:"POST",headers:{Authorization:`Bearer ${this.apiKey}`,"Content-Type":"application/json"},body:JSON.stringify({events:t}),...this.source==="sdk_web"?{keepalive:!0}:{}});return n.ok?{kind:"sent"}:n.status===429?(this.log("rate limited \xB7 will retry after Retry-After"),{kind:"retry",afterMs:bt(n)}):n.status>=500?(this.log(`bulk failed ${n.status} \xB7 will retry with backoff`),{kind:"retry",afterMs:null}):n.status===401?(this.warnOnce("401","API key inv\xE1lida ou revogada \xB7 eventos descartados. Confira a chave em Configura\xE7\xF5es \u203A SDK."),{kind:"dropped"}):n.status===403?(this.warnOnce("403","Origem n\xE3o permitida ou chave sem escopo events:write \xB7 eventos descartados."),{kind:"dropped"}):(this.log(`bulk rejected ${n.status} \xB7 batch dropped`),{kind:"dropped"})}catch(n){return this.log(`bulk network error: ${n.message} \xB7 will retry with backoff`),{kind:"retry",afterMs:null}}}log(t){this.debug&&console.warn(`[holdy] ${t}`)}warnOnce(t,n){this.warned.has(t)||(this.warned.add(t),console.warn(`[holdy] ${n}`))}environmentContext(){return{}}get pending(){return this.queue.length}};function bt(e){let t=typeof e.headers?.get=="function"?e.headers.get("Retry-After"):null;if(!t)return null;let n=Number(t);return!Number.isFinite(n)||n<0?null:Math.min(6e4,n*1e3)}function xt(){let e=globalThis.crypto;if(typeof e?.randomUUID=="function")return e.randomUUID();let t=()=>Math.random().toString(36).slice(2,12);return`${Date.now().toString(36)}-${t()}-${t()}`}var H="__holdy_autocapture__";function G(e){if(typeof window>"u"||typeof history>"u")return()=>{};let t=window;if(t[H])return()=>{};t[H]=!0;let n=[],r=X(),i=null;function l(m){try{e.onNavigate(m)}catch{}}function c(){i&&clearTimeout(i),i=setTimeout(()=>{i=null;let m=X();m!==r&&(r=m,l("route_change"))},50)}l("initial_load");let p=history.pushState,f=history.replaceState;history.pushState=function(..._){let k=p.apply(this,_);return c(),k},history.replaceState=function(..._){let k=f.apply(this,_);return c(),k},n.push(()=>{history.pushState=p,history.replaceState=f});let b=()=>c();window.addEventListener("popstate",b),n.push(()=>window.removeEventListener("popstate",b));let x=()=>c();return window.addEventListener("hashchange",x),n.push(()=>window.removeEventListener("hashchange",x)),()=>{i&&clearTimeout(i);for(let m of n)m();t[H]=!1}}function X(){return typeof location>"u"?"/":`${location.pathname}${location.search}${location.hash}`}var q="__holdy_friction__",_t='button, a, input, select, textarea, summary, [role="button"], [role="link"], [role="menuitem"], [role="tab"]',Ct=new Set(["button","a","input","select","textarea","summary"]),Et=new Set(["input","select","textarea"]),$=class{constructor(t=3,n=1e3,r=30){this.threshold=t;this.windowMs=n;this.radiusPx=r}clicks=[];push(t,n,r){return this.clicks=this.clicks.filter(i=>r-i.t<=this.windowMs&&Math.hypot(i.x-t,i.y-n)<=this.radiusPx),this.clicks.push({x:t,y:n,t:r}),this.clicks.length>=this.threshold?(this.clicks=[],!0):!1}},K=class{constructor(t=6e4){this.windowMs=t}visits=[];push(t,n){if(this.visits=[...this.visits,{path:t,t:n}].filter(p=>n-p.t<=this.windowMs).slice(-4),this.visits.length<4)return null;let[r,i,l,c]=this.visits.map(p=>p.path);return r===l&&i===c&&r!==i?(this.visits=[],{from:r,to:i}):null}};function J(e){if(!e)return null;let t=e.closest?.(_t)??null;if(t)return t;let n=e.tagName.toLowerCase();if(Ct.has(n))return e;let r=e.getAttribute("role");return r==="button"||r==="link"||r==="menuitem"||r==="tab"?e:null}function kt(e){let t=J(e);if(!t)return!1;if(t.disabled===!0||t.getAttribute("disabled")!==null||t.getAttribute("aria-disabled")==="true")return!0;if(t.tagName.toLowerCase()==="a"){let r=t.getAttribute("href");if(!r||r==="#"||r.startsWith("javascript:"))return!0}return!1}function z(e){let t=J(e)??e;if(!t)return{};let n={element:t.tagName.toLowerCase()};t.id&&(n.element_id=t.id);let r=t.getAttribute("role");r&&(n.element_role=r);let l=(t.getAttribute("aria-label")??t.textContent??"").replace(/\s+/g," ").trim().slice(0,60);l&&(n.element_text=l);let c=t.getAttribute("name")??t.getAttribute("data-testid");return c&&(n.element_name=c),n}function P(e,t){try{let n=new URL(e,t);return`${n.origin}${n.pathname}`}catch{return e.split("?")[0].split("#")[0]}}function At(e){if(e instanceof Error)return e.message;if(typeof e=="string")return e;try{return JSON.stringify(e)}catch{return String(e)}}function St(e){return typeof e=="object"&&e!==null&&e.name==="AbortError"}function Lt(e,t){return t.some(n=>n.length>0&&e.startsWith(n))}function Y(e){let t=e.toLowerCase().split(".").filter(Boolean);return t.length<=2?t.join("."):t.slice(-2).join(".")}function Mt(e,t,n=[]){let r,i;try{r=new URL(e,t),i=new URL(t)}catch{return!0}if(r.protocol!=="http:"&&r.protocol!=="https:"||r.host===i.host||n.some(c=>c.length>0&&r.origin===c))return!0;let l=Y(r.hostname);return l.length>0&&l===Y(i.hostname)}function Tt(e){return e.aborted?null:!e.opaque&&(e.status===null||e.status>=400)?"http_error":e.durationMs>=e.slowMs?"slow_request":null}function Pt(e){try{let n=e?.getEntriesByType?.("navigation")?.[0]?.responseStatus;return typeof n=="number"&&n>0?n:null}catch{return null}}function Ot(e){return e.id||e.getAttribute("name")||e.getAttribute("data-testid")||P(e.getAttribute("action")??"",location.href).replace(location.origin,"")||"form"}function Rt(){return typeof location>"u"?"/":location.pathname||"/"}function Q(e){let t={onNavigate:()=>{},teardown:()=>{}};if(typeof window>"u"||typeof document>"u")return t;let n=window;if(n[q])return t;n[q]=!0;let r=(o,s)=>{try{e.onFriction({kind:o,properties:{path:Rt(),...s}})}catch{return}},i=[],l=new $(e.rageClicks,e.rageWindowMs,e.rageRadiusPx),c=new K(e.navLoopWindowMs),p=e.slowRequestMs??3e3,f=new Map,b=o=>{let s=o.target instanceof Element?o.target:null;kt(s)&&r("dead_click",z(s)),l.push(o.clientX,o.clientY,o.timeStamp||Date.now())&&r("rage_click",z(s))};document.addEventListener("click",b,!0),i.push(()=>document.removeEventListener("click",b,!0));let x=o=>{r("js_error",{message:String(o.message??"").slice(0,200),...o.filename?{source:P(o.filename,location.href)}:{},...o.lineno?{line:o.lineno}:{}})};window.addEventListener("error",x),i.push(()=>window.removeEventListener("error",x));let m=o=>{r("js_error",{message:At(o.reason).slice(0,200),unhandled_rejection:!0})};window.addEventListener("unhandledrejection",m),i.push(()=>window.removeEventListener("unhandledrejection",m));let _=(e.ignoreUrls??[]).map(o=>P(o,location.href)),k=(e.apiOrigins??[]).map(o=>{try{return new URL(o,location.href).origin}catch{return""}}),A=(o,s,u,a,d={})=>{let h=P(o,location.href);if(Lt(h,_)||!Mt(h,location.href,k))return;let g=performance.now()-u,E=Tt({status:a,durationMs:g,slowMs:p,...d});E&&r(E,{url:h,method:s,duration_ms:Math.round(g),...d.opaque?{}:a!==null?{status:a}:{failed:!0}})},S=window.fetch;if(typeof S=="function"){let o=async(s,u)=>{let a=performance.now(),d=typeof s=="string"?s:s instanceof URL?s.href:s.url,h=(u?.method??(s instanceof Request?s.method:"GET")).toUpperCase();try{let g=await S(s,u);return A(d,h,a,g.status,{opaque:g.type==="opaque"||g.type==="opaqueredirect"}),g}catch(g){throw A(d,h,a,null,{aborted:St(g)}),g}};window.fetch=o,i.push(()=>{window.fetch=S})}let v=typeof XMLHttpRequest=="function"?XMLHttpRequest.prototype:null;if(v){let o=v.open,s=v.send,u=new WeakMap;v.open=function(a,d,...h){return u.set(this,{method:String(a).toUpperCase(),url:String(d)}),o.apply(this,[a,d,...h])},v.send=function(a){let d=u.get(this);if(d){let h=performance.now(),g=!1;this.addEventListener("abort",()=>{g=!0}),this.addEventListener("loadend",()=>{A(d.url,d.method,h,this.status===0?null:this.status,{aborted:g})})}return s.call(this,a)},i.push(()=>{v.open=o,v.send=s})}let C=Pt(typeof performance>"u"?void 0:performance);C!==null&&C>=400&&r("http_error",{document:!0,status:C,url:P(location.href)});let L=o=>{let s=o.target;if(!s||!Et.has(s.tagName.toLowerCase()))return;let u=s.form;if(!u)return;let a=f.get(u)??{form:Ot(u),fields:new Set},d=s.name||s.id||s.tagName.toLowerCase();a.fields.add(d),f.set(u,a)};document.addEventListener("focusin",L,!0),i.push(()=>document.removeEventListener("focusin",L,!0));let M=o=>{o.target instanceof HTMLFormElement&&f.delete(o.target)};document.addEventListener("submit",M,!0),i.push(()=>document.removeEventListener("submit",M,!0));let T=()=>{for(let o of f.values())r("form_abandon",{form:o.form,fields_touched:o.fields.size});f.clear()};return window.addEventListener("pagehide",T),i.push(()=>window.removeEventListener("pagehide",T)),{onNavigate:o=>{T();let s=c.push(o,Date.now());s&&r("nav_loop",{from:s.from,to:s.to})},teardown:()=>{for(let o of i)o();f.clear(),n[q]=!1}}}var It=["utm_source","utm_medium","utm_campaign","utm_term","utm_content"],V="holdy_session",Z="holdy_attribution";function tt(e){try{let t=new URL(e);return`${t.origin}${t.pathname}`}catch{return null}}function Ut(e){let t={};try{let n=new URL(e).searchParams;for(let r of It){let i=n.get(r)?.trim();i&&(t[r]=i.toLowerCase().slice(0,120))}}catch{}return t}function Ft(e){if(!e)return{};let t=e.toLowerCase(),n=t.includes("edg/")?"Edge":t.includes("opr/")||t.includes("opera")?"Opera":t.includes("samsungbrowser")?"Samsung Internet":t.includes("firefox")||t.includes("fxios")?"Firefox":t.includes("chrome")||t.includes("crios")?"Chrome":t.includes("safari")?"Safari":void 0,r=t.includes("iphone")||t.includes("ipad")||t.includes("ipod")?"iOS":t.includes("android")?"Android":t.includes("windows")?"Windows":t.includes("mac os")||t.includes("macintosh")?"macOS":t.includes("cros")?"ChromeOS":t.includes("linux")?"Linux":void 0,i=t.includes("ipad")||t.includes("android")&&!t.includes("mobile")?"tablet":t.includes("mobi")||t.includes("iphone")||t.includes("ipod")?"mobile":"desktop";return{...n?{browser:n}:{},...r?{os:r}:{},device:i}}function et(e,t){try{return(e==="session"?sessionStorage:localStorage).getItem(t)}catch{return null}}function nt(e,t,n){try{(e==="session"?sessionStorage:localStorage).setItem(t,n)}catch{}}function Nt(){try{return crypto.randomUUID()}catch{return`hol-${Date.now().toString(36)}-${Math.random().toString(36).slice(2,10)}`}}function Ht(){let e=et("session",V);if(e)return e;let t=Nt();return nt("session",V,t),t}function qt(e,t,n){let r=et("session",Z);if(r)try{return JSON.parse(r)}catch{}let i={...Ut(e)},l=$t(t);if(l&&l!==n){let c=tt(t);c&&(i.referrer=c),i.referrer_host=l}return nt("session",Z,JSON.stringify(i)),i}function $t(e){try{return new URL(e).hostname.toLowerCase()||null}catch{return null}}function rt(){if(typeof window>"u"||typeof location>"u")return{};let e=location.href,t=typeof document<"u"?document.referrer:"",n=location.hostname.toLowerCase(),r=typeof navigator<"u"?navigator.userAgent:"",{browser:i,os:l,device:c}=Ft(r),p=tt(e);return{...p?{url:p}:{},path:location.pathname||"/",host:n,...i?{browser:i}:{},...l?{os:l}:{},...c?{device:c}:{},...typeof navigator<"u"&&navigator.language?{locale:navigator.language}:{},session_id:Ht(),...qt(e,t,n)}}function Kt(e){let t=2166136261;for(let n=0;n<e.length;n++)t^=e.charCodeAt(n),t=Math.imul(t,16777619)>>>0;return t>>>0}function Dt(e,t){return Kt(`${e}:${t}`)%100}function ot(e,t,n){return Dt(e,t)<n?"holdout":"change"}function it(e,t){let n=e.split(/[?#]/)[0].split("/").filter(Boolean),r=t.split(/[?#]/)[0].split("/").filter(Boolean);return n.length!==r.length?!1:n.every((i,l)=>i.startsWith(":")||i===r[l])}var Wt=300*1e3,Bt=60*1e3,jt=250,st="holdy_changes_seen",at="holdy_changes_dismissed",ut=8,Xt=`:host{all:initial}
|
|
1
|
+
"use strict";var Holdy=(()=>{var H=Object.defineProperty;var mt=Object.getOwnPropertyDescriptor;var yt=Object.getOwnPropertyNames;var wt=Object.prototype.hasOwnProperty;var vt=(e,t)=>{for(var n in t)H(e,n,{get:t[n],enumerable:!0})},bt=(e,t,n,r)=>{if(t&&typeof t=="object"||typeof t=="function")for(let o of yt(t))!wt.call(e,o)&&o!==n&&H(e,o,{get:()=>t[o],enumerable:!(r=mt(t,o))||r.enumerable});return e};var xt=e=>bt(H({},"__esModule",{value:!0}),e);var Se={};vt(Se,{flush:()=>be,getInstance:()=>ke,group:()=>ye,identify:()=>me,init:()=>fe,page:()=>we,reset:()=>ve,shutdown:()=>xe,track:()=>ge});var kt="https://holdy.chat/api/v1";var I=class{apiKey;baseUrl;flushAt;debug;source;queue=[];timer=null;flushing=null;retryAt=0;failures=0;warned=new Set;userId=null;anonymousId=null;accountKey=null;constructor(t,n){this.source=t,this.apiKey=n.apiKey,this.accountKey=n.accountKey??null,this.baseUrl=(n.baseUrl??kt).replace(/\/$/,""),this.flushAt=Math.max(1,n.flushAt??20),this.debug=n.debug??!1;let r=n.flushIntervalMs??5e3;r>0&&(this.timer=setInterval(()=>void this.flush(),r),typeof this.timer.unref=="function"&&this.timer.unref())}track(t,n,r){if(!t||typeof t!="string")return;let o=r?.userId??this.userId??void 0,a=r?.accountKey??this.accountKey??void 0,l=r?.occurredAt?new Date(r.occurredAt).toISOString():new Date().toISOString(),d={...this.environmentContext(),...r?.context??{}};a&&(d.account_external_id=a);let p={event:t,occurred_at:l,source:this.source,external_id:Et(),...o?{user_id:o}:{},...this.anonymousId?{anonymous_id:this.anonymousId}:{},properties:n??{},...Object.keys(d).length>0?{context:d}:{}};this.queue.push(p),this.trimQueue(),this.queue.length>=this.flushAt&&this.flush()}identify(t,n){!t||typeof t!="string"||(this.userId=t,this.track("$identify",n??{}))}group(t,n){!t||typeof t!="string"||(this.accountKey=t,this.track("$group",n??{}))}async flush(){return this.startFlush(!1)}async shutdown(){this.timer&&(clearInterval(this.timer),this.timer=null),await this.startFlush(!0)}startFlush(t){return this.flushing?this.flushing:this.queue.length===0||!t&&Date.now()<this.retryAt?Promise.resolve():(this.flushing=this.drain().finally(()=>{this.flushing=null}),this.flushing)}async drain(){for(;this.queue.length>0;){let t=this.queue.splice(0,500),n=await this.send(t);if(n.kind==="retry"){this.queue.unshift(...t),this.trimQueue(),this.scheduleRetry(n.afterMs);return}this.failures=0,this.retryAt=0}}scheduleRetry(t){if(this.failures+=1,t!==null){this.retryAt=Date.now()+t;return}let n=Math.min(6e4,1e3*2**(this.failures-1));this.retryAt=Date.now()+n+Math.floor(Math.random()*n*.2)}trimQueue(){this.queue.length>1e3&&this.queue.splice(0,this.queue.length-1e3)}async send(t){try{let n=await fetch(`${this.baseUrl}/events/bulk`,{method:"POST",headers:{Authorization:`Bearer ${this.apiKey}`,"Content-Type":"application/json"},body:JSON.stringify({events:t}),...this.source==="sdk_web"?{keepalive:!0}:{}});return n.ok?{kind:"sent"}:n.status===429?(this.log("rate limited \xB7 will retry after Retry-After"),{kind:"retry",afterMs:St(n)}):n.status>=500?(this.log(`bulk failed ${n.status} \xB7 will retry with backoff`),{kind:"retry",afterMs:null}):n.status===401?(this.warnOnce("401","API key inv\xE1lida ou revogada \xB7 eventos descartados. Confira a chave em Configura\xE7\xF5es \u203A SDK."),{kind:"dropped"}):n.status===403?(this.warnOnce("403","Origem n\xE3o permitida ou chave sem escopo events:write \xB7 eventos descartados."),{kind:"dropped"}):(this.log(`bulk rejected ${n.status} \xB7 batch dropped`),{kind:"dropped"})}catch(n){return this.log(`bulk network error: ${n.message} \xB7 will retry with backoff`),{kind:"retry",afterMs:null}}}log(t){this.debug&&console.warn(`[holdy] ${t}`)}warnOnce(t,n){this.warned.has(t)||(this.warned.add(t),console.warn(`[holdy] ${n}`))}environmentContext(){return{}}get pending(){return this.queue.length}};function St(e){let t=typeof e.headers?.get=="function"?e.headers.get("Retry-After"):null;if(!t)return null;let n=Number(t);return!Number.isFinite(n)||n<0?null:Math.min(6e4,n*1e3)}function Et(){let e=globalThis.crypto;if(typeof e?.randomUUID=="function")return e.randomUUID();let t=()=>Math.random().toString(36).slice(2,12);return`${Date.now().toString(36)}-${t()}-${t()}`}var q="__holdy_autocapture__";function Y(e){if(typeof window>"u"||typeof history>"u")return()=>{};let t=window;if(t[q])return()=>{};t[q]=!0;let n=[],r=G(),o=null;function a(m){try{e.onNavigate(m)}catch{}}function l(){o&&clearTimeout(o),o=setTimeout(()=>{o=null;let m=G();m!==r&&(r=m,a("route_change"))},50)}a("initial_load");let d=history.pushState,p=history.replaceState;history.pushState=function(...k){let _=d.apply(this,k);return l(),_},history.replaceState=function(...k){let _=p.apply(this,k);return l(),_},n.push(()=>{history.pushState=d,history.replaceState=p});let b=()=>l();window.addEventListener("popstate",b),n.push(()=>window.removeEventListener("popstate",b));let x=()=>l();return window.addEventListener("hashchange",x),n.push(()=>window.removeEventListener("hashchange",x)),()=>{o&&clearTimeout(o);for(let m of n)m();t[q]=!1}}function G(){return typeof location>"u"?"/":`${location.pathname}${location.search}${location.hash}`}var K="__holdy_friction__",_t='button, a, input, select, textarea, summary, [role="button"], [role="link"], [role="menuitem"], [role="tab"]',Ct=new Set(["button","a","input","select","textarea","summary"]),At=new Set(["input","select","textarea"]),$=class{constructor(t=3,n=1e3,r=30){this.threshold=t;this.windowMs=n;this.radiusPx=r}clicks=[];push(t,n,r){return this.clicks=this.clicks.filter(o=>r-o.t<=this.windowMs&&Math.hypot(o.x-t,o.y-n)<=this.radiusPx),this.clicks.push({x:t,y:n,t:r}),this.clicks.length>=this.threshold?(this.clicks=[],!0):!1}},D=class{constructor(t=6e4){this.windowMs=t}visits=[];push(t,n){if(this.visits=[...this.visits,{path:t,t:n}].filter(d=>n-d.t<=this.windowMs).slice(-4),this.visits.length<4)return null;let[r,o,a,l]=this.visits.map(d=>d.path);return r===a&&o===l&&r!==o?(this.visits=[],{from:r,to:o}):null}};function J(e){if(!e)return null;let t=e.closest?.(_t)??null;if(t)return t;let n=e.tagName.toLowerCase();if(Ct.has(n))return e;let r=e.getAttribute("role");return r==="button"||r==="link"||r==="menuitem"||r==="tab"?e:null}function Lt(e){let t=J(e);if(!t)return!1;if(t.disabled===!0||t.getAttribute("disabled")!==null||t.getAttribute("aria-disabled")==="true")return!0;if(t.tagName.toLowerCase()==="a"){let r=t.getAttribute("href");if(!r||r==="#"||r.startsWith("javascript:"))return!0}return!1}function V(e){let t=J(e)??e;if(!t)return{};let n={element:t.tagName.toLowerCase()};t.id&&(n.element_id=t.id);let r=t.getAttribute("role");r&&(n.element_role=r);let a=(t.getAttribute("aria-label")??t.textContent??"").replace(/\s+/g," ").trim().slice(0,60);a&&(n.element_text=a);let l=t.getAttribute("name")??t.getAttribute("data-testid");return l&&(n.element_name=l),n}function O(e,t){try{let n=new URL(e,t);return`${n.origin}${n.pathname}`}catch{return e.split("?")[0].split("#")[0]}}function Tt(e){if(e instanceof Error)return e.message;if(typeof e=="string")return e;try{return JSON.stringify(e)}catch{return String(e)}}function Mt(e){return typeof e=="object"&&e!==null&&e.name==="AbortError"}function Ot(e,t){return t.some(n=>n.length>0&&e.startsWith(n))}function z(e){let t=e.toLowerCase().split(".").filter(Boolean);return t.length<=2?t.join("."):t.slice(-2).join(".")}function Rt(e,t,n=[]){let r,o;try{r=new URL(e,t),o=new URL(t)}catch{return!0}if(r.protocol!=="http:"&&r.protocol!=="https:"||r.host===o.host||n.some(l=>l.length>0&&r.origin===l))return!0;let a=z(r.hostname);return a.length>0&&a===z(o.hostname)}function Nt(e){return e.aborted?null:!e.opaque&&(e.status===null||e.status>=400)?"http_error":e.durationMs>=e.slowMs?"slow_request":null}function Pt(e){try{let n=e?.getEntriesByType?.("navigation")?.[0]?.responseStatus;return typeof n=="number"&&n>0?n:null}catch{return null}}function It(e){return e.id||e.getAttribute("name")||e.getAttribute("data-testid")||O(e.getAttribute("action")??"",location.href).replace(location.origin,"")||"form"}function Ut(){return typeof location>"u"?"/":location.pathname||"/"}function Q(e){let t={onNavigate:()=>{},teardown:()=>{}};if(typeof window>"u"||typeof document>"u")return t;let n=window;if(n[K])return t;n[K]=!0;let r=(i,s)=>{try{e.onFriction({kind:i,properties:{path:Ut(),...s}})}catch{return}},o=[],a=new $(e.rageClicks,e.rageWindowMs,e.rageRadiusPx),l=new D(e.navLoopWindowMs),d=e.slowRequestMs??3e3,p=new Map,b=i=>{let s=i.target instanceof Element?i.target:null;Lt(s)&&r("dead_click",V(s)),a.push(i.clientX,i.clientY,i.timeStamp||Date.now())&&r("rage_click",V(s))};document.addEventListener("click",b,!0),o.push(()=>document.removeEventListener("click",b,!0));let x=i=>{r("js_error",{message:String(i.message??"").slice(0,200),...i.filename?{source:O(i.filename,location.href)}:{},...i.lineno?{line:i.lineno}:{}})};window.addEventListener("error",x),o.push(()=>window.removeEventListener("error",x));let m=i=>{r("js_error",{message:Tt(i.reason).slice(0,200),unhandled_rejection:!0})};window.addEventListener("unhandledrejection",m),o.push(()=>window.removeEventListener("unhandledrejection",m));let k=(e.ignoreUrls??[]).map(i=>O(i,location.href)),_=(e.apiOrigins??[]).map(i=>{try{return new URL(i,location.href).origin}catch{return""}}),C=(i,s,c,u,h={})=>{let f=O(i,location.href);if(Ot(f,k)||!Rt(f,location.href,_))return;let g=performance.now()-c,E=Nt({status:u,durationMs:g,slowMs:d,...h});E&&r(E,{url:f,method:s,duration_ms:Math.round(g),...h.opaque?{}:u!==null?{status:u}:{failed:!0}})},A=window.fetch;if(typeof A=="function"){let i=async(s,c)=>{let u=performance.now(),h=typeof s=="string"?s:s instanceof URL?s.href:s.url,f=(c?.method??(s instanceof Request?s.method:"GET")).toUpperCase();try{let g=await A(s,c);return C(h,f,u,g.status,{opaque:g.type==="opaque"||g.type==="opaqueredirect"}),g}catch(g){throw C(h,f,u,null,{aborted:Mt(g)}),g}};window.fetch=i,o.push(()=>{window.fetch=A})}let w=typeof XMLHttpRequest=="function"?XMLHttpRequest.prototype:null;if(w){let i=w.open,s=w.send,c=new WeakMap;w.open=function(u,h,...f){return c.set(this,{method:String(u).toUpperCase(),url:String(h)}),i.apply(this,[u,h,...f])},w.send=function(u){let h=c.get(this);if(h){let f=performance.now(),g=!1;this.addEventListener("abort",()=>{g=!0}),this.addEventListener("loadend",()=>{C(h.url,h.method,f,this.status===0?null:this.status,{aborted:g})})}return s.call(this,u)},o.push(()=>{w.open=i,w.send=s})}let S=Pt(typeof performance>"u"?void 0:performance);S!==null&&S>=400&&r("http_error",{document:!0,status:S,url:O(location.href)});let L=i=>{let s=i.target;if(!s||!At.has(s.tagName.toLowerCase()))return;let c=s.form;if(!c)return;let u=p.get(c)??{form:It(c),fields:new Set},h=s.name||s.id||s.tagName.toLowerCase();u.fields.add(h),p.set(c,u)};document.addEventListener("focusin",L,!0),o.push(()=>document.removeEventListener("focusin",L,!0));let T=i=>{i.target instanceof HTMLFormElement&&p.delete(i.target)};document.addEventListener("submit",T,!0),o.push(()=>document.removeEventListener("submit",T,!0));let M=()=>{for(let i of p.values())r("form_abandon",{form:i.form,fields_touched:i.fields.size});p.clear()};return window.addEventListener("pagehide",M),o.push(()=>window.removeEventListener("pagehide",M)),{onNavigate:i=>{M();let s=l.push(i,Date.now());s&&r("nav_loop",{from:s.from,to:s.to})},teardown:()=>{for(let i of o)i();p.clear(),n[K]=!1}}}var Ft='a[href], button, input, select, textarea, [role="button"], [role="link"], [role="tab"], [role="menuitem"], [role="checkbox"], [role="radio"], [role="switch"], [data-testid]';var Z="holdy_skeletons";function Ht(e){let t=2166136261;for(let n=0;n<e.length;n++)t^=e.charCodeAt(n),t=Math.imul(t,16777619)>>>0;return t.toString(16).padStart(8,"0")}function R(e,t,n){let r=e.getAttribute(t);return r&&r.replace(/\s+/g," ").trim().slice(0,n)||void 0}function qt(e){if(!e.getBoundingClientRect)return!0;let t=e.getBoundingClientRect();return t.width>0&&t.height>0}function Kt(e,t){let n=(r,o)=>o>0?Math.max(0,Math.min(100,Math.round(r/o*100))):0;return[n(e.x,t.width),n(e.y+t.scrollY,t.height),n(e.width,t.width),n(e.height,t.height)]}function $t(e,t){let n={t:e.tagName.toLowerCase()},r=R(e,"role",40);r&&(n.r=r);let o=R(e,"data-testid",80);o&&(n.id=o);let a=R(e,"name",80);a&&(n.n=a);let l=R(e,"aria-label",80);if(l&&(n.l=l),n.t==="input"||n.t==="button"){let d=R(e,"type",20);d&&(n.k=d.toLowerCase())}return t&&e.getBoundingClientRect&&(n.b=Kt(e.getBoundingClientRect(),t)),n}function Dt(e,t,n){let r=e.querySelectorAll(Ft),o=[];for(let d=0;d<r.length;d++){let p=r[d];p.tagName.toLowerCase()==="input"&&(p.getAttribute("type")??"").toLowerCase()==="hidden"||qt(p)&&o.push(p)}let a=o.slice(0,80).map(d=>$t(d,n)),l=a.map(({b:d,...p})=>p);return{path:t,hash:Ht(JSON.stringify(l)),count:o.length,elements:a}}function Wt(){try{let e=sessionStorage.getItem(Z),t=e?JSON.parse(e):[];return new Set(Array.isArray(t)?t.filter(n=>typeof n=="string"):[])}catch{return new Set}}function Bt(e){try{sessionStorage.setItem(Z,JSON.stringify([...e].slice(-200)))}catch{return}}function tt(e){if(typeof window>"u"||typeof document>"u")return{onNavigate:()=>{},teardown:()=>{}};let t=e.delayMs??1500,n=Wt(),r=null,o=a=>{if(r=null,location.pathname===a)try{let l={width:window.innerWidth,height:Math.max(document.documentElement.scrollHeight,window.innerHeight),scrollY:window.scrollY},d=Dt(document,a,l),p=`${a}:${d.hash}`;if(n.has(p))return;n.add(p),Bt(n),e.onSkeleton(d)}catch{return}};return{onNavigate:a=>{r&&clearTimeout(r),r=setTimeout(()=>o(a),t)},teardown:()=>{r&&clearTimeout(r),r=null}}}var Xt=["utm_source","utm_medium","utm_campaign","utm_term","utm_content"],et="holdy_session",nt="holdy_attribution";function rt(e){try{let t=new URL(e);return`${t.origin}${t.pathname}`}catch{return null}}function jt(e){let t={};try{let n=new URL(e).searchParams;for(let r of Xt){let o=n.get(r)?.trim();o&&(t[r]=o.toLowerCase().slice(0,120))}}catch{}return t}function Gt(e){if(!e)return{};let t=e.toLowerCase(),n=t.includes("edg/")?"Edge":t.includes("opr/")||t.includes("opera")?"Opera":t.includes("samsungbrowser")?"Samsung Internet":t.includes("firefox")||t.includes("fxios")?"Firefox":t.includes("chrome")||t.includes("crios")?"Chrome":t.includes("safari")?"Safari":void 0,r=t.includes("iphone")||t.includes("ipad")||t.includes("ipod")?"iOS":t.includes("android")?"Android":t.includes("windows")?"Windows":t.includes("mac os")||t.includes("macintosh")?"macOS":t.includes("cros")?"ChromeOS":t.includes("linux")?"Linux":void 0,o=t.includes("ipad")||t.includes("android")&&!t.includes("mobile")?"tablet":t.includes("mobi")||t.includes("iphone")||t.includes("ipod")?"mobile":"desktop";return{...n?{browser:n}:{},...r?{os:r}:{},device:o}}function ot(e,t){try{return(e==="session"?sessionStorage:localStorage).getItem(t)}catch{return null}}function it(e,t,n){try{(e==="session"?sessionStorage:localStorage).setItem(t,n)}catch{}}function Yt(){try{return crypto.randomUUID()}catch{return`hol-${Date.now().toString(36)}-${Math.random().toString(36).slice(2,10)}`}}function Vt(){let e=ot("session",et);if(e)return e;let t=Yt();return it("session",et,t),t}function zt(e,t,n){let r=ot("session",nt);if(r)try{return JSON.parse(r)}catch{}let o={...jt(e)},a=Jt(t);if(a&&a!==n){let l=rt(t);l&&(o.referrer=l),o.referrer_host=a}return it("session",nt,JSON.stringify(o)),o}function Jt(e){try{return new URL(e).hostname.toLowerCase()||null}catch{return null}}function st(){if(typeof window>"u"||typeof location>"u")return{};let e=location.href,t=typeof document<"u"?document.referrer:"",n=location.hostname.toLowerCase(),r=typeof navigator<"u"?navigator.userAgent:"",{browser:o,os:a,device:l}=Gt(r),d=rt(e);return{...d?{url:d}:{},path:location.pathname||"/",host:n,...o?{browser:o}:{},...a?{os:a}:{},...l?{device:l}:{},...typeof navigator<"u"&&navigator.language?{locale:navigator.language}:{},session_id:Vt(),...zt(e,t,n)}}function Qt(e){let t=2166136261;for(let n=0;n<e.length;n++)t^=e.charCodeAt(n),t=Math.imul(t,16777619)>>>0;return t>>>0}function Zt(e,t){return Qt(`${e}:${t}`)%100}function at(e,t,n){return Zt(e,t)<n?"holdout":"change"}function ut(e,t){let n=e.split(/[?#]/)[0].split("/").filter(Boolean),r=t.split(/[?#]/)[0].split("/").filter(Boolean);return n.length!==r.length?!1:n.every((o,a)=>o.startsWith(":")||o===r[a])}var te=300*1e3,ee=60*1e3,ne=250,lt="holdy_changes_seen",ct="holdy_changes_dismissed",dt=8,re=`:host{all:initial}
|
|
2
2
|
.tip{position:fixed;box-sizing:border-box;max-width:280px;padding:10px 12px;border-radius:8px;background:#111;color:#fff;font:13px/1.45 system-ui,-apple-system,sans-serif;box-shadow:0 8px 24px rgba(0,0,0,.18);pointer-events:auto;display:flex;gap:10px;align-items:flex-start}
|
|
3
3
|
.tip p{margin:0;flex:1}
|
|
4
4
|
.tip button{all:unset;cursor:pointer;opacity:.7;font-size:15px;line-height:1}
|
|
5
5
|
.tip button:hover,.tip button:focus-visible{opacity:1}
|
|
6
|
-
@media (prefers-color-scheme:dark){.tip{background:#fff;color:#111}}`;function
|
|
6
|
+
@media (prefers-color-scheme:dark){.tip{background:#fff;color:#111}}`;function v(e){return e.replace(/\s+/g," ").trim()}function oe(e){let t=e?.changes;return Array.isArray(t)?t.filter(se):[]}function ie(e){let t=e;return t?.kind==="page"?!0:(t?.kind==="selector"||t?.kind==="text")&&typeof t.value=="string"&&t.value.length>0}function se(e){let t=e;return typeof t?.id=="string"&&(t.kind==="copy"||t.kind==="guidance")&&typeof t.path=="string"&&ie(t.anchor)&&typeof t.content?.text=="string"&&typeof t.holdout_pct=="number"}function ae(e,t,n){return n?e.filter(r=>ut(r.path,t)).map(r=>({change:r,arm:at(r.id,n,r.holdout_pct)})):[]}function W(e){try{return e==="local"?window.localStorage:window.sessionStorage}catch{return}}function B(e,t){try{return new Set(JSON.parse(e?.getItem(t)??"[]"))}catch{return new Set}}function ht(e,t,n){try{let r=B(e,t);r.add(n),e?.setItem(t,JSON.stringify([...r].slice(-200)))}catch{return}}function ue(e){try{return document.querySelector(e)}catch{return null}}var le='button,a,[role="button"],label,summary,h1,h2,h3,h4,li,td,th,p,span,strong',ce=3e3;function de(e){let t=v(e),n=null,r=Number.POSITIVE_INFINITY,o=document.querySelectorAll(le),a=Math.min(o.length,ce);for(let l=0;l<a;l+=1){let d=o[l],p=d.textContent??"";p.length>=r||v(p)!==t||(n=d,r=p.length)}return n}function he(e){return e.kind==="page"?null:e.kind==="selector"?ue(e.value):de(e.value)}function pe(e,t){let n=document.createTreeWalker(e,NodeFilter.SHOW_TEXT);for(let r=n.nextNode();r;r=n.nextNode())if(t(v(r.textContent??"")))return r;return null}function pt(e){if(typeof window>"u"||typeof document>"u")return{onNavigate:()=>{},refresh:async()=>{},teardown:()=>{}};let t=[],n=0,r=null,o=null,a=null,l=new Map,d=new Map,p=i=>{e.debug&&console.warn(`[holdy] ${i}`)},b=(i,s)=>{let c=`${i.id}:${s}`,u=W("session");B(u,lt).has(c)||(ht(u,lt,c),e.track("$change_exposure",{change_id:i.id,arm:s,kind:i.kind}))},x=(i,s)=>{let c=s.expected_text?v(s.expected_text):null,u=v(s.content.text);return pe(i,h=>h.length>0&&(h===u||c===null||h===c))},m=(i,s)=>{let c=v(s.content.text),u=l.get(s.id);if(u&&u.node.isConnected&&v(u.node.textContent??"")===c)return!0;let h=x(i,s);if(!h)return!1;let f=h.textContent??"";return v(f)!==c&&(l.set(s.id,{node:h,original:f,next:s.content.text}),h.textContent=f.replace(f.trim(),s.content.text)),!0},k=i=>{let s=l.get(i);s&&(s.node.isConnected&&v(s.node.textContent??"")===v(s.next)&&(s.node.textContent=s.original),l.delete(i))},_=()=>{if(o)return o;if(!document.body)return null;a=document.createElement("holdy-changes"),a.setAttribute("data-holdy-root","1"),a.style.cssText="position:fixed;top:0;left:0;width:0;height:0;z-index:2147483647;pointer-events:none",o=a.attachShadow({mode:"closed"});let i=document.createElement("style");return i.textContent=re,o.appendChild(i),document.body.appendChild(a),o},C=(i,s)=>{if(d.has(s.id)||B(W("local"),ct).has(s.id))return!0;let c=_();if(!c)return!1;let u=document.createElement("div");u.className="tip",u.setAttribute("role","tooltip");let h=document.createElement("p");h.textContent=s.content.text;let f=document.createElement("button");f.type="button",f.setAttribute("aria-label","Fechar"),f.textContent="\xD7",u.append(h,f),u.style.top="-9999px",u.style.left="-9999px",c.appendChild(u);let g=()=>{u.remove(),window.removeEventListener("scroll",E,!0),window.removeEventListener("resize",E),d.delete(s.id)};function E(){if(!i){let j=u.getBoundingClientRect();u.style.top=`${Math.max(8,window.innerHeight-j.height-16)}px`,u.style.left=`${Math.max(8,window.innerWidth-j.width-16)}px`;return}if(!i.isConnected){g();return}let N=i.getBoundingClientRect(),P=u.getBoundingClientRect(),F=N.bottom+dt;F+P.height>window.innerHeight-8&&(F=N.top-P.height-dt);let gt=Math.min(Math.max(8,N.left+N.width/2-P.width/2),window.innerWidth-P.width-8);u.style.top=`${Math.max(8,F)}px`,u.style.left=`${Math.max(8,gt)}px`}return f.addEventListener("click",()=>{ht(W("local"),ct,s.id),e.track("$change_dismissed",{change_id:s.id,kind:s.kind}),g()}),d.set(s.id,g),requestAnimationFrame(E),window.addEventListener("scroll",E,!0),window.addEventListener("resize",E),!0},A=()=>{r=null;let i=ae(t,location.pathname,e.getAccountKey()),s=new Set(i.map(c=>c.change.id));for(let c of[...l.keys()])s.has(c)||k(c);for(let[c,u]of[...d])s.has(c)||u();for(let{change:c,arm:u}of i){let h=he(c.anchor);if(!(!h&&c.anchor.kind!=="page"))if(c.kind==="copy"){if(!h)continue;(u==="change"?m(h,c):x(h,c)!==null)&&b(c,u)}else(u==="holdout"||C(h,c))&&b(c,u)}},w=()=>{r===null&&(r=setTimeout(A,ne))},S=async()=>{n=Date.now();try{let i=await fetch(`${e.baseUrl}/runtime/changes`,{headers:{Authorization:`Bearer ${e.apiKey}`}});if(!i.ok){p(`changes ${i.status}`);return}t=oe(await i.json()),w()}catch(i){p(`changes network error: ${i.message}`)}},L=typeof MutationObserver<"u"?new MutationObserver(()=>{(t.length>0||l.size>0||d.size>0)&&w()}):null,T=()=>{document.body&&L?.observe(document.body,{childList:!0,subtree:!0,characterData:!0})};document.readyState==="loading"?document.addEventListener("DOMContentLoaded",T,{once:!0}):T();let M=setInterval(()=>void S(),te);return S(),{onNavigate:()=>{Date.now()-n>ee&&S(),w()},refresh:S,teardown:()=>{clearInterval(M),r!==null&&clearTimeout(r),L?.disconnect();for(let i of[...l.keys()])k(i);for(let i of[...d.values()])i();a?.remove(),a=null,o=null,t=[]}}}var X="holdy_anon_id",U=class extends I{teardownAutoCapture=null;friction=null;changes=null;skeleton=null;constructor(t){if(super("sdk_web",t),this.anonymousId=ft(),typeof window<"u"&&(window.addEventListener("pagehide",()=>void this.flush()),document.addEventListener("visibilitychange",()=>{document.visibilityState==="hidden"&&this.flush()})),t.friction!==!1){let n=typeof t.friction=="object"?t.friction:{};this.friction=Q({...n,ignoreUrls:[...n.ignoreUrls??[],this.baseUrl],onFriction:r=>this.track(`$${r.kind}`,r.properties)})}t.skeleton!==!1&&(this.skeleton=tt({onSkeleton:n=>this.track("$page_skeleton",{...n})})),t.autoCapture!==!1&&(this.teardownAutoCapture=Y({onNavigate:n=>{this.page(void 0,{navigation:n});let r=typeof location<"u"?location.pathname:"/";this.friction?.onNavigate(r),this.changes?.onNavigate(),this.skeleton?.onNavigate(r)}})),t.productChanges!==!1&&typeof window<"u"&&(this.changes=pt({baseUrl:this.baseUrl,apiKey:this.apiKey,getAccountKey:()=>this.accountKey,track:(n,r)=>this.track(n,r),debug:t.debug}))}page(t,n){this.track("$pageview",{...n??{},...t?{page_name:t}:{},...typeof document<"u"&&document.title?{title:document.title}:{}})}group(t,n){super.group(t,n),this.changes?.onNavigate()}reset(){this.userId=null,this.accountKey=null;try{localStorage.removeItem(X)}catch{}this.anonymousId=ft(),this.changes?.onNavigate()}async shutdown(){this.teardownAutoCapture?.(),this.teardownAutoCapture=null,this.friction?.teardown(),this.friction=null,this.changes?.teardown(),this.changes=null,this.skeleton?.teardown(),this.skeleton=null,await super.shutdown()}environmentContext(){return st()}};function ft(){try{let e=localStorage.getItem(X);if(e)return e;let t=crypto.randomUUID();return localStorage.setItem(X,t),t}catch{return crypto.randomUUID()}}var y=null;function fe(e){return y||(y=new U(e)),y}function ge(e,t){y?.track(e,t)}function me(e,t){y?.identify(e,t)}function ye(e,t){y?.group(e,t)}function we(e,t){y?.page(e,t)}function ve(){y?.reset()}async function be(){await y?.flush()}async function xe(){await y?.shutdown(),y=null}function ke(){return y}return xt(Se);})();
|
|
7
7
|
//# sourceMappingURL=holdy.js.map
|