import{j as t}from"./jsx-runtime-C5WNSv3b.js";import{r as u}from"./index-CqIc3cxq.js";import{g as p,f}from"./chunk-EPOLDU6W-BCLmut3y.js";import{T as b,j as g,k as x}from"./tooltip-Tlsyx2YO.js";import{u as h}from"./root-loader-BOzEMapJ.js";const l="/mark-onboarding-complete";function D(o){const s=h(),e=p(),r=f(),i=e.some(c=>{const d=c.formData?.get("featureId");return c.formAction===l&&d===o}),n=s.preferences?.onboardingComplete?.includes(o)??!1,a=!ENV.EPICSHOP_DEPLOYED&&!n&&!i,m=u.useCallback(()=>{a&&r.submit({featureId:o},{method:"POST",action:l})},[a,o,r]);return[a,m]}function k({children:o="!",tooltip:s,className:e="",size:r="md"}){const n=`flex ${r==="sm"?"h-4 w-4 text-xs":"h-6 w-6 text-sm"} animate-badge-bounce items-center justify-center rounded-full bg-yellow-500 font-bold text-black shadow-lg`;return s?t.jsxs(b,{children:[t.jsx(g,{asChild:!0,children:t.jsx("span",{className:`absolute -top-1 -right-1 z-10 cursor-pointer ${n} ${e}`,tabIndex:0,children:o})}),t.jsx(x,{side:"bottom",sideOffset:8,collisionPadding:16,avoidCollisions:!0,children:s})]}):t.jsx("span",{className:`absolute -top-1 -right-1 z-10 ${n} ${e}`,children:o})}export{k as O,D as u};
//# sourceMappingURL=onboarding-indicator-B-XR90_G.js.map
