1!function(){try{var e="undefined"!=typeof window?window:"undefined"!=typeof global?global:"undefined"!=typeof globalThis?globalThis:"undefined"!=typeof self?self:{},n=(new e.Error).stack;n&&(e._posthogChunkIds=e._posthogChunkIds||{},e._posthogChunkIds[n]="01a0ebec-af43-7a12-a501-f206ba2c24a1")}catch(e){}}();(globalThis.TURBOPACK||(globalThis.TURBOPACK=[])).push(["object"==typeof document?document.currentScript:void 0,62342,e=>{"use strict";e.s(["default",0,{LOGIN:"/login",REGISTRATION:"/register",FORGOT_PASSWORD:"/forgot-password",RESET_PASSWORD:"/reset-password",INVITE_ACCEPT:"/invite/accept",EVENTS:"/dashboard/events",ATTRIBUTION:"/dashboard/attribution",JOURNEYS:"/dashboard/journeys",OVERVIEW:"/dashboard/overview",SITES:"/dashboard/sites",PIXEL_SETUP:"/dashboard/pixel-setup",PIXEL_SETUP_FACEBOOK_CALLBACK:"/dashboard/pixel-setup/facebook/callback",PIXEL_SETUP_TIKTOK_CALLBACK:"/dashboard/pixel-setup/tiktok/callback",SITE_EDIT:"/dashboard/site-edit",BLOCKING_RULES:"/dashboard/blocking-rules",BLOCKING_RULES_CREATE:"/dashboard/blocking-rules/create",BLOCKING_RULES_EDIT:"/dashboard/blocking-rules/edit",GET_STARTED:"/dashboard/get-started",SUBSCRIPTIONS:"/dashboard/subscriptions",PROFILE:"/dashboard/profile",TEAM:"/dashboard/team",ACCESS_RESTRICTED:"/dashboard/access-restricted",TRIGGER_SETUP:"/dashboard/trigger-setup",TRIGGER_SETUP_TRIGGER:"/dashboard/trigger-setup/trigger",TRIGGER_SETUP_PAGE_LOAD:"/dashboard/trigger-setup/page-load",TRIGGER_SETUP_PAGE_LOAD_MAP_PARAMS:"/dashboard/trigger-setup/page-load/map-params",TRIGGER_SETUP_POINT_AND_CLICK:"/dashboard/trigger-setup/point-and-click",TRIGGER_SETUP_SUCCESS:"/dashboard/trigger-setup/success",TRIGGER_SETUP_STRIPE:"/dashboard/trigger-setup/stripe",TRIGGER_SETUP_STRIPE_SETTINGS:"/dashboard/trigger-setup/stripe/settings",TRIGGER_SETUP_STRIPE_API_KEY:"/dashboard/trigger-setup/stripe/api-key",TRIGGER_SETUP_STRIPE_METHOD:"/dashboard/trigger-setup/stripe/method",TRIGGER_SETUP_STRIPE_INSTRUCTIONS:"/dashboard/trigger-setup/stripe/instructions",TRIGGER_SETUP_STRIPE_CONNECT:"/dashboard/trigger-setup/stripe/connect",TRIGGER_SETUP_STRIPE_COMPLETE:"/dashboard/trigger-setup/stripe/complete",INTEGRATIONS:"/dashboard/integrations",INTEGRATIONS_STRIPE:"/dashboard/integrations/stripe",INTEGRATIONS_CALENDLY:"/dashboard/integrations/calendly",UNSUBSCRIBE:"/unsubscribe",FACEBOOK_DELETION_STATUS:"/facebook-deletion-status",SITE_SETUP:"/site-setup",SITE_SETUP_FACEBOOK_CALLBACK:"/site-setup/facebook/callback",SITE_SETUP_TIKTOK_CALLBACK:"/site-setup/tiktok/callback",SITE_SETUP_NEW:"/site-setup?new=1"}])},618566,(e,t,r)=>{t.exports=e.r(976562)},478895,68385,409813,360819,310196,e=>{"use strict";let t=new class{setItem(e,t,r=864e5){let i=new Date().getTime()+r;localStorage.setItem(e,t),localStorage.setItem(`${e}_expiry`,i.toString())}getItem(e){let t=localStorage.getItem(e),r=localStorage.getItem(`${e}_expiry`);return t&&r?new Date().getTime()>parseInt(r,10)?(this.removeItem(e),null):t:null}removeItem(e){localStorage.removeItem(e),localStorage.removeItem(`${e}_expiry`)}clearWithPrefix(e){let t=[];for(let r=0;r<localStorage.length;r++){let i=localStorage.key(r);i&&i.startsWith(e)&&t.push(i)}t.forEach(e=>{localStorage.removeItem(e)})}};e.s(["STORAGE_KEYS",0,{SESSION_KEY:"pixelflow_session_key",PLATFORM:"pixelflow_platform",PLUGIN_SITE_EXTERNAL_ID:"pixelflow_plugin_site_external_id",WEBFLOW_SITE_ID:"pixelflow_webflow_site_id",SITE_SETUP_EXITED:"pixelflow_site_setup_exited",SITE_SETUP_FB_RETURN_SITE_ID:"pixelflow_site_setup_fb_return_site_id",SITE_SETUP_FB_OAUTH_ERROR:"pixelflow_site_setup_fb_oauth_error",PIXEL_SETUP_FB_OAUTH_ERROR:"pixelflow_pixel_setup_fb_oauth_error",SITE_SETUP_TIKTOK_RETURN_SITE_ID:"pixelflow_site_setup_tiktok_return_site_id",SITE_SETUP_OAUTH_RETURN_PLATFORM:"pixelflow_site_setup_oauth_return_platform",SITE_SETUP_TIKTOK_OAUTH_ERROR:"pixelflow_site_setup_tiktok_oauth_error",PIXEL_SETUP_TIKTOK_OAUTH_ERROR:"pixelflow_pixel_setup_tiktok_oauth_error"},"localStorageService",0,t],68385);class r{listeners=new Set;serialize(e){return JSON.stringify(e)}deserialize(e){return JSON.parse(e)}getData(){try{let e=this.getStorageKey(),r=this.getExpirationMs(),i=void 0!==r?t.getItem(e):localStorage.getItem(e);if(!i)return null;return this.deserialize(i)}catch(e){return console.error(`Error loading data from localStorage (${this.get
1StorageKey()}):`,e),null}}setData(e){try{let r=this.getStorageKey(),i=this.serialize(e),n=this.getExpirationMs();void 0!==n?t.setItem(r,i,n):localStorage.setItem(r,i),this.notifyListeners()}catch(e){console.error(`Error saving data to localStorage (${this.getStorageKey()}):`,e)}}clearData(){try{let e=this.getStorageKey(),r=this.getExpirationMs();void 0!==r?t.removeItem(e):localStorage.removeItem(e),this.notifyListeners()}catch(e){console.error(`Error clearing data from localStorage (${this.getStorageKey()}):`,e)}}subscribe(e){return this.listeners.add(e),()=>this.listeners.delete(e)}notifyListeners(){this.listeners.forEach(e=>e())}}e.s(["BaseLocalStorageService",0,r],409813);class i{static instance;static getInstance(){return i.instance||(i.instance=new i),i.instance}isTrialEndingPlanNudgeDismissed(e){return this.readDismissed(this.getTrialEndingPlanNudgeKey(e))}dismissTrialEndingPlanNudge(e){this.persistDismissed(this.getTrialEndingPlanNudgeKey(e))}clearTrialEndingPlanNudgeDismissed(e){this.clearDismissed(this.getTrialEndingPlanNudgeKey(e))}isTrialEndedModalDismissed(e){return this.readDismissed(this.getTrialEndedModalKey(e))}dismissTrialEndedModal(e){this.persistDismissed(this.getTrialEndedModalKey(e))}clearTrialEndedModalDismissed(e){this.clearDismissed(this.getTrialEndedModalKey(e))}isPauseReactivationModalDismissed(e){return this.readLocalDismissed(this.getPauseReactivationModalKey(e))}dismissPauseReactivationModal(e){this.persistLocalDismissed(this.getPauseReactivationModalKey(e))}clearPauseReactivationModalDismissed(e){this.clearLocalDismissed(this.getPauseReactivationModalKey(e))}getTrialEndingPlanNudgeKey(e){return`pixelflow.trialEndingPlanNudgeDismissed.${e}`}getTrialEndedModalKey(e){return`pixelflow.trialEndedModalDismissed.${e}`}getPauseReactivationModalKey(e){return`pixelflow.pauseReactivationModalDismissed.${e}`}readDismissed(e){try{return"1"===window.sessionStorage.getItem(e)}catch{return!1}}persistDismissed(e){try{window.sessionStorage.setItem(e,"1")}catch{}}clearDismissed(e){try{window.sessionStorage.removeItem(e)}catch{}}readLocalDismissed(e){try{return"1"===window.localStorage.getItem(e)}catch{return!1}}persistLocalDismissed(e){try{window.localStorage.setItem(e,"1")}catch{}}clearLocalDismissed(e){try{window.localStorage.removeItem(e)}catch{}}}let n=i.getInstance();e.s(["sessionModalStorageService",0,n],360819);let o={setCookie(e,t,r=7){let i=new Date;i.setTime(i.getTime()+24*r*36e5);let n=`expires=${i.toUTCString()}`;document.cookie=`${e}=${t};${n};path=/;SameSite=Lax`},removeCookie(e){document.cookie=`${e}=;expires=Thu, 01 Jan 1970 00:00:00 UTC;path=/;SameSite=Lax`}};e.s(["withCookies",0,o],310196);class s extends r{static instance;static getInstance(){return s.instance||(s.instance=new s),s.instance}getStorageKey(){return"user"}getExpirationMs(){}getCookieName(){return"user-data"}setCookie(e,t,r){o.setCookie.call(this,e,t,r)}removeCookie(e){o.removeCookie.call(this,e)}getCurrentUser(){return this.getData()}setCurrentUser(e){e?(this.setData(e),this.setCookie(this.getCookieName(),"true")):this.clearUser()}clearUser(){let e=this.getData();e?.id!=null&&(n.clearTrialEndingPlanNudgeDismissed(e.id),n.clearTrialEndedModalDismissed(e.id),n.clearPauseReactivationModalDismissed(e.id)),this.clearData(),this.removeCookie(this.getCookieName())}}let a=s.getInstance();e.s(["userService",0,a],478895)},991918,820783,e=>{"use strict";var t=e.i(271645),r=Object.defineProperty,i=(e,t)=>r(e,"name",{value:t,configurable:!0});function n(e,t){if("function"==typeof e)return e(t);null!=e&&(e.current=t)}function o(...e){return t=>{let r=!1,i=e.map(e=>{let i=n(e,t);return r||"function"!=typeof i||(r=!0),i});if(r)return()=>{for(let t=0;t<i.length;t++){let r=i[t];"function"==typeof r?r():n(e[t],null)}}}}function s(...e){return t.useCallback(o(...e),e)}i(n,"setRef"),i(o,"composeRefs"),i(s,"useComposedRefs"),e.s(["useComposedRefs",0,s],820783);var a=Object.defineProperty,l=(e,t)=>a(e,"name",{value:t,configurable:!0});function u(e){let r=t.forwardRef((r,i)=>{let{children:n,...o}=r,a=null,l=!1,u=[];
1h(n)&&"function"==typeof R&&(n=R(n._payload)),t.Children.forEach(n,e=>{if(g(e)){l=!0;let t="child"in e.props?e.props.child:e.props.children;h(t)&&"function"==typeof R&&(t=R(t._payload)),a=p(e,t),u.push(a?.props?.children)}else u.push(e)}),a?a=t.cloneElement(a,void 0,u):!l&&1===t.Children.count(n)&&t.isValidElement(n)&&(a=n);let c=a?E(a):void 0,d=s(i,c);if(!a){if(n||0===n)throw Error(l?I(e):T(e));return n}let f=m(o,a.props??{});return a.type!==t.Fragment&&(f.ref=i?d:c),t.cloneElement(a,f)});return r.displayName=`${e}.Slot`,r}l(u,"createSlot");var c=u("Slot"),d=Symbol.for("radix.slottable");function f(e){let t=l(e=>"child"in e?e.children(e.child):e.children,"Slottable");return t.displayName=`${e}.Slottable`,t.__radixId=d,t}l(f,"createSlottable");var p=l((e,r)=>{if("child"in e.props){let r=e.props.child;return t.isValidElement(r)?t.cloneElement(r,void 0,e.props.children(r.props.children)):null}return t.isValidElement(r)?r:null},"getSlottableElementFromSlottable");function m(e,t){let r={...t};for(let i in t){let n=e[i],o=t[i];/^on[A-Z]/.test(i)?n&&o?r[i]=(...e)=>{let t=o(...e);return n(...e),t}:n&&(r[i]=n):"style"===i?r[i]={...n,...o}:"className"===i&&(r[i]=[n,o].filter(Boolean).join(" "))}return{...e,...r}}function E(e){let t=Object.getOwnPropertyDescriptor(e.props,"ref")?.get,r=t&&"isReactWarning"in t&&t.isReactWarning;return r?e.ref:(r=(t=Object.getOwnPropertyDescriptor(e,"ref")?.get)&&"isReactWarning"in t&&t.isReactWarning)?e.props.ref:e.props.ref||e.ref}function g(e){return t.isValidElement(e)&&"function"==typeof e.type&&"__radixId"in e.type&&e.type.__radixId===d}l(m,"mergeProps"),l(E,"getElementRef"),l(g,"isSlottable");var S=Symbol.for("react.lazy");function h(e){return null!=e&&"object"==typeof e&&"$$typeof"in e&&e.$$typeof===S&&"_payload"in e&&_(e._payload)}function _(e){return"object"==typeof e&&null!==e&&"then"in e}l(h,"isLazyComponent"),l(_,"isPromiseLike");var T=l(e=>`${e} failed to slot onto its children. Expected a single React element child or \`Slottable\`.`,"createSlotError"),I=l(e=>`${e} failed to slot onto its \`Slottable\`. Expected \`Slottable\` to receive a single React element child.`,"createSlottableError"),R=t[" use ".trim().toString()];e.s(["Slot",0,c,"createSlot",0,u,"createSlottable",0,f],991918)},375494,e=>{"use strict";var t=e.i(155487);let r=t.useDispatch.withTypes(),i=t.useSelector.withTypes();e.s(["useAppDispatch",0,r,"useAppSelector",0,i])},456420,e=>{"use strict";var t=e.i(271645);let r=(...e)=>e.filter((e,t,r)=>!!e&&""!==e.trim()&&r.indexOf(e)===t).join(" ").trim(),i=e=>{let t=e.replace(/^([A-Z])|[\s-_]+(\w)/g,(e,t,r)=>r?r.toUpperCase():t.toLowerCase());return t.charAt(0).toUpperCase()+t.slice(1)};var n={xmlns:"http://www.w3.org/2000/svg",width:24,height:24,viewBox:"0 0 24 24",fill:"none",stroke:"currentColor",strokeWidth:2,strokeLinecap:"round",strokeLinejoin:"round"};let o=(0,t.createContext)({}),s=(0,t.forwardRef)(({color:e,size:i,strokeWidth:s,absoluteStrokeWidth:a,className:l="",children:u,iconNode:c,...d},f)=>{let{size:p=24,strokeWidth:m=2,absoluteStrokeWidth:E=!1,color:g="currentColor",className:S=""}=(0,t.useContext)(o)??{},h=a??E?24*Number(s??m)/Number(i??p):s??m;return(0,t.createElement)("svg",{ref:f,...n,width:i??p??n.width,height:i??p??n.height,stroke:e??g,strokeWidth:h,className:r("lucide",S,l),...!u&&!(e=>{for(let t in e)if(t.startsWith("aria-")||"role"===t||"title"===t)return!0;return!1})(d)&&{"aria-hidden":"true"},...d},[...c.map(([e,r])=>(0,t.createElement)(e,r)),...Array.isArray(u)?u:[u]])});e.s(["default",0,(e,n)=>{let o=(0,t.forwardRef)(({className:o,...a},l)=>(0,t.createElement)(s,{ref:l,iconNode:n,className:r(`lucide-${i(e).replace(/([a-z0-9])([A-Z])/g,"$1-$2").toLowerCase()}`,`lucide-${e}`,o),...a}));return o.displayName=i(e),o}],456420)},248425,e=>{"use strict";var t=e.i(271645),r=e.i(174080),i=e.i(991918),n=e.i(843476),o=Object.defineProperty,s=["a","button","div","form","h2","h3","img","input","label","li","nav","ol","p","select","span","svg","ul"].reduce((e,r)=>{let o=(0,i.createSlot)(`Primitive.${r}`),s=t.forwardRef((e,t)=>{let{asChild:i,...s}=e;return"u">typeof window&&(window[Symbol.for("radix-ui")]=!0),(0,n.jsx)(i?o:r,{...s,ref:t})});return s.displayName=`Primitive.${r}`,{...e,[r]:s}},{});function a(e,t){e&&r.flushSync(()=>
1e.dispatchEvent(t))}o(a,"name",{value:"dispatchDiscreteCustomEvent",configurable:!0}),e.s(["Primitive",0,s,"dispatchDiscreteCustomEvent",0,a])},981140,e=>{"use strict";var t=Object.defineProperty,r=(e,r)=>t(e,"name",{value:r,configurable:!0}),i=!!("u">typeof window&&window.document&&window.document.createElement);function n(e,t,{checkForDefaultPrevented:i=!0}={}){return r(function(r){if(e?.(r),!1===i||!r||!r.defaultPrevented)return t?.(r)},"handleEvent")}function o(e){if(!i)throw Error("Cannot access document outside of the DOM");return e?.ownerDocument??document}function s(e){return"IFRAME"===e.tagName}r(n,"composeEventHandlers"),r(function(e){if(!i)throw Error("Cannot access window outside of the DOM");return e?.ownerDocument?.defaultView??window},"getOwnerWindow"),r(o,"getOwnerDocument"),r(function e(t,r=!1){let{activeElement:i}=o(t);if(!i?.nodeName)return null;if(s(i)&&i.contentDocument)return e(i.contentDocument.body,r);if(r){let e=i.getAttribute("aria-activedescendant");if(e){let t=o(i).getElementById(e);if(t)return t}}return i},"getActiveElement"),r(s,"isFrame"),e.s(["composeEventHandlers",0,n])},30030,e=>{"use strict";var t=e.i(271645),r=e.i(843476),i=Object.defineProperty,n=(e,t)=>i(e,"name",{value:t,configurable:!0});function o(e,i=[]){let a=[];function l(i,o){let s=t.createContext(o);s.displayName=i+"Context";let l=a.length;a=[...a,o];let u=n(i=>{let{scope:n,children:o,...a}=i,u=n?.[e]?.[l]||s,c=t.useMemo(()=>a,Object.values(a));return(0,r.jsx)(u.Provider,{value:c,children:o})},"Provider");function c(r,n,a={}){let{optional:u=!1}=a,d=n?.[e]?.[l]||s,f=t.useContext(d);if(f)return f;if(void 0!==o)return o;if(!u)throw Error(`\`${r}\` must be used within \`${i}\``)}return u.displayName=i+"Provider",n(c,"useContext"),[u,c]}n(l,"createContext");let u=n(()=>{let r=a.map(e=>t.createContext(e));return n(function(i){let n=i?.[e]||r;return t.useMemo(()=>({[`__scope${e}`]:{...i,[e]:n}}),[i,n])},"useScope")},"createScope");return u.scopeName=e,[l,s(u,...i)]}function s(...e){let r=e[0];if(1===e.length)return r;let i=n(()=>{let i=e.map(e=>({useScope:e(),scopeName:e.scopeName}));return n(function(e){let n=i.reduce((t,{useScope:r,scopeName:i})=>{let n=r(e)[`__scope${i}`];return{...t,...n}},{});return t.useMemo(()=>({[`__scope${r.scopeName}`]:n}),[n])},"useComposedScopes")},"createScope");return i.scopeName=r.scopeName,i}n(function(e,i){let o=t.createContext(i);o.displayName=e+"Context";let s=n(e=>{let{children:i,...n}=e,s=t.useMemo(()=>n,Object.values(n));return(0,r.jsx)(o.Provider,{value:s,children:i})},"Provider");function a(r,n={}){let{optional:s=!1}=n,l=t.useContext(o);if(l)return l;if(void 0!==i)return i;if(!s)throw Error(`\`${r}\` must be used within \`${e}\``)}return s.displayName=e+"Provider",n(a,"useContext"),[s,a]},"createContext"),n(o,"createContextScope"),n(s,"composeContextScopes"),e.s(["createContextScope",0,o])},934620,e=>{"use strict";var t=e.i(271645),r=globalThis?.document?t.useLayoutEffect:()=>{};e.s(["useLayoutEffect",0,r])},610772,e=>{"use strict";var t=e.i(271645),r=e.i(934620),i=Object.defineProperty,n=t[" useId ".trim().toString()]||(()=>void 0),o=0;function s(e){let[i,s]=t.useState(n());return(0,r.useLayoutEffect)(()=>{e||s(e=>e??String(o++))},[e]),e||(i?`radix-${i}`:"")}i(s,"name",{value:"useId",configurable:!0}),e.s(["useId",0,s])},705844,e=>{"use strict";e.s(["IS_DEVELOPMENT",0,!1])},369340,e=>{"use strict";var t=e.i(271645),r=e.i(705844),i=e.i(934620),n=Object.defineProperty,o=t[" useEffectEvent ".trim().toString()],s=t[" useInsertionEffect ".trim().toString()];function a(e){if("function"==typeof o)return o(e);let r=t.useRef(()=>{throw Error("Cannot call an event handler while rendering.")});return"function"==typeof s?s(()=>{r.current=e}):(0,i.useLayoutEffect)(()=>{r.current=e}),t.useMemo(()=>(...e)=>r.current?.(...e),[])}n(a,"name",{value:"useEffectEvent",configurable:!0});var l=Object.defineProperty,u=(e,t)=>l(e,"name",{value:t,configurable:!0}),c=t[" useInsertionEffect ".trim().toString()]||i.useLayoutEffect;function d({prop:e,defaultProp:i,onChange:n=u(()=>{},"onChange"),caller:o}){let[s,a,l]=f({defaultProp:i,onChange:n}),c=void 0!==e,m=c?e:s;if(r.IS_DEVELOPMENT){let r=t.useRef(void 0!==e);t.useEffect(()=>{let e=r.current;if(e!==c){let t=c?"controlled":"uncontrolled";console.warn(`${o} is changing from ${e?"controlled":"uncontrolled"} to ${t}. Components should not switch from controlled to uncontrolled (or vice versa). Decide between using a controlled or uncontrolled value for the lifetime of the component.`)}r.current=c},[c,o])}return[m,t.useCallback(t=>{if(c){let r=p(t)?t(e):t;r!==e&&l.current?.(r)}else a(t)},[c,e,a,l])]}function f({defaultProp:e,onChange:r}){let[i,n]=t.useState(e),o=t.useRef(i),s=t.useRef(r);return c(()=>{s.current=r},[r]),t.useEffect(()=>{o.current!==i&&(s.current?.(i),o.current=i)},[i,o]),[i,n,s]}function p(e){return"function"==typeof e}u(d,"useControllableState"),u(f,"useUncontrolledState"),u(p,"isFunction");var m=Symbol("RADIX:SYNC_STATE");u(function(e,i,n,o){let{prop:s,defaultProp:l,onChange:u,caller:c}=i,d=void 0!==s,f=a(u);if(r.IS_DEVELOPMENT){let e=t.useRef(void 0!==s);t.useEffect(()=>{let t=e.current;if(t!==d){let e=d?"controlled":"uncontrolled";console.warn(`${c} is changing from ${t?"controlled":"uncontrolled"} to ${e}. Components should not switch from controlled to uncontrolled (or vice versa). Decide between using a controlled or uncontrolled value for the lifetime of the component.`)}e.current=d},[d,c])}let p=[{...n,state:l}];o&&p.push(o);let[E,g]=t.useReducer((t,r)=>{if(r.type===m)return{...t,state:r.state};let i=e(t,r);return d&&!Object.is(i.state,t.state)&&f(i.state),i},...p),S=E.state,h=t.useRef(S);t.useEffect(()=>{h.current!==S&&(h.current=S,d||f(S))},[S,h,d]);let _=t.useMemo(()=>void 0!==s?{...E,state:s}:E,[E,s]);return t.useEffect(()=>{d&&!Object.is(s,E.state)&&g({type:m,state:s})},[s,E.state,d]),[_,g]},"useControllableStateReducer"),e.s(["useControllableState",0,d],369340)},296626,e=>{"use strict";var t=e.i(271645),r=e.i(934620),i=Object.defineProperty,n=(e,t)=>i(e,"name",{value:t,configurable:!0});function o(e,r){return t.useReducer((e,t)=>
1r[e][t]??e,e)}n(o,"useStateMachine");var s=n(e=>{let{present:r,children:i}=e,n=a(r),o="function"==typeof i?i({present:n.isPresent}):t.Children.only(i),s=u(n.ref,d(o));return"function"==typeof i||n.isPresent?t.cloneElement(o,{ref:s}):null},"Presence");function a(e){let[i,s]=t.useState(),a=t.useRef(null),l=t.useRef(e),u=t.useRef("none"),d=t.useRef(void 0),[f,p]=o(e?"mounted":"unmounted",{mounted:{UNMOUNT:"unmounted",ANIMATION_OUT:"unmountSuspended"},unmountSuspended:{MOUNT:"mounted",ANIMATION_END:"unmounted"},unmounted:{MOUNT:"mounted"}});return t.useEffect(()=>{"mounted"===f?(u.current=d.current??c(a.current),d.current=void 0):u.current="none"},[f]),(0,r.useLayoutEffect)(()=>{let t=a.current,r=l.current;if(r!==e){let i=u.current,n=c(t);e?(d.current=n,p("MOUNT")):"none"===n||t?.display==="none"?p("UNMOUNT"):r&&i!==n?p("ANIMATION_OUT"):p("UNMOUNT"),l.current=e}},[e,p]),(0,r.useLayoutEffect)(()=>{if(i){let e,t=i.ownerDocument.defaultView??window,r=n(r=>{let n=c(a.current).includes(CSS.escape(r.animationName));if(r.target===i&&n&&(p("ANIMATION_END"),!l.current)){let r=i.style.animationFillMode;i.style.animationFillMode="forwards",e=t.setTimeout(()=>{"forwards"===i.style.animationFillMode&&(i.style.animationFillMode=r)})}},"handleAnimationEnd"),o=n(e=>{e.target===i&&(u.current=c(a.current))},"handleAnimationStart");return i.addEventListener("animationstart",o),i.addEventListener("animationcancel",r),i.addEventListener("animationend",r),()=>{t.clearTimeout(e),i.removeEventListener("animationstart",o),i.removeEventListener("animationcancel",r),i.removeEventListener("animationend",r)}}p("ANIMATION_END")},[i,p]),{isPresent:["mounted","unmountSuspended"].includes(f),ref:t.useCallback(e=>{if(e){let t=getComputedStyle(e);a.current=t,d.current=c(t)}else a.current=null;s(e)},[])}}function l(e,t){if("function"==typeof e)return e(t);null!=e&&(e.current=t)}function u(...e){let r=t.useRef(e);return r.current=e,t.useCallback(e=>{let t=r.current,i=!1,n=t.map(t=>{let r=l(t,e);return i||"function"!=typeof r||(i=!0),r});if(i)return()=>{for(let e=0;e<n.length;e++){let r=n[e];"function"==typeof r?r():l(t[e],null)}}},[])}function c(e){return e?.animationName||"none"}function d(e){let t=Object.getOwnPropertyDescriptor(e.props,"ref")?.get,r=t&&"isReactWarning"in t&&t.isReactWarning;return r?e.ref:(r=(t=Object.getOwnPropertyDescriptor(e,"ref")?.get)&&"isReactWarning"in t&&t.isReactWarning)?e.props.ref:e.props.ref||e.ref}n(a,"usePresence"),n(l,"setRef"),n(u,"useStableComposedRefs"),n(c,"getAnimationName"),n(d,"getElementRef"),e.s(["Presence",0,s])}]); 2 3//# chunkId=01a0ebec-af43-7a12-a501-f206ba2c24a1
Line numbers count LF bytes from the start of the resource, as the search results do. Vendor segments are library code the classifier recognised; they are stored but not indexed. Bytes are shown as Latin1 characters, one per byte.