PageSourceSearch

https://app.aceable.com/assets/index-LM0xLvHK.js

js aceable.com collected 2026-09-24 19:20:11 UTC 6,127 bytes, 2 lines download raw bytes

1import{G as e,a9 as k,D as l,e2 as T,T as v,V as h,U as u,e3 as L,cz as D,e4 as B,cH as $,Y as A,x as P,bN as z,z as y,cR as R,cS as M,cE as O,bw as G,a1 as H,aA as J,$ as V}from"./index-BuKyKLFj.js";import{g as F,S as Y}from"./clipboard-check-D-DExv1O.js";import{u as K}from"./useJourneyCardContinue-DPLy_Opf.js";import{R as U,C as q,B as W,S as X}from"./index-D5aNs80u.js";import{P as Q}from"./ProgressBar-NG9YwadF.js";import{u as Z}from"./useComponentLog-D6gfCGk9.js";import{C as j}from"./ChapterCircleProgress-DMxrx7J9.js";import"./useCurrentItemPointer-Wh1XTPlQ.js";import"./chevron-left-EiUkbVA9.js";import"./index-IOxWpgvR.js";import"./lock-Bwf2h30e.js";(function(){try{var t=typeof window<"u"?window:typeof global<"u"?global:typeof globalThis<"u"?globalThis:typeof self<"u"?self:{};t.SENTRY_RELEASE={id:"[email protected]"};var s=new t.Error().stack;s&&(t._sentryDebugIds=t._sentryDebugIds||{},t._sentryDebugIds[s]="6b11356c-af1d-4d15-91ef-6a6dec7c9392",t._sentryDebugIdIdentifier="sentry-dbid-6b11356c-af1d-4d15-91ef-6a6dec7c9392")}catch{}})();const ee="Continue",te=t=>{const s=t===1?"step":"steps";return`${String(t)} ${s} left before you can continue`},se=({stepList:t,onContinue:s})=>{const o=t.filter(i=>!i.isComplete).length,n=o>0;return e.jsx(k,{className:"min-w-50",disabled:n,"aria-disabled":n,onClick:s,"data-test":"checkCardContinueButton",children:n?te(o):ee})},ae=({step:t,isDeepLinkTarget:s=!1,onToggleComplete:o})=>{const n=l.useId(),[i,m]=l.useState(s),c=t.isComplete?"complete":"not-started",x=t.isComplete?"complete":"incomplete";return l.useEffect(()=>{s&&m(!0)},[s]),e.jsx(T,{isOpen:i,id:n,children:e.jsxs("div",{className:"scroll-mt-36 bg-background-primary border border-divider-line-light rounded-lg overflow-hidden","data-test":`checkCardStep-${t._id}`,"data-state":c,children:[e.jsx(v,{as:"h2",size:"small",children:e.jsxs("button",{onClick:()=>{m(g=>!g)},"aria-expanded":i,"aria-controls":i?n:void 0,"data-test":`checkCardStepToggle-${t._id}`,className:h("flex w-full items-center gap-3.5 px-6 py-4 text-left","bg-transparent border-none cursor-pointer","active:bg-background-tertiary","focus-visible:shadow-focus-dramatic focus-visible:outline-none"),children:[!i&&e.jsx("div",{className:"shrink-0 size-6 flex items-center justify-center",children:e.jsx(j,{state:c})}),e.jsxs("div",{className:"flex-1 min-w-0",children:[e.jsx(u,{as:"span",variant:"list-chapter-item",weight:"extrabold",className:h(t.isComplete&&"text-content-subtle!"),children:t.title}),e.jsx("span",{className:"sr-only",children:`, ${x}`})]}),e.jsx(L,{children:e.jsx(D,{width:16,height:16,className:"text-muted","aria-hidden":"true"})})]})}),e.jsxs(B,{className:"overflow-hidden",children:[e.jsx("div",{className:"px-6 pb-4",children:e.jsx($,{step:t})}),e.jsxs("div",{className:"flex items-center gap-3.5 px-6 py-4 border-t border-divider-line-light bg-background-secondary","data-test":`checkCardStepStatus-${t._id}`,"data-state":c,children:[e.jsx("div",{className:"shrink-0 size-6 flex items-center justify-center",children:e.jsx(j,{state:c})}),t.isComplete&&e.jsx(u,{as:"span",variant:"list-chapter-item",weight:"extrabold",className:"text-status-success-text!",children:"Completed"}),e.jsx(k,{variant:t.isComplete?"text-secondary":void 0,size:t.isComplete?"small":void 0,className:h("whitespace-nowrap",t.isComplete&&"ml-auto"),onClick:o,"data-test":`checkCardStepToggleComplete-${t._id}`,"aria-label":`${t.isComplete?"Mark incomplete":"Mark complete"}: ${t.title}`,children:t.isComplete?"Mark incomplete":"Mark complete"})]})]})]})})},xe=({footerSlot:t})=>{Z("CheckCardPage");const s=A(),o=P(),{levelId:n}=z(),i=y(R),m=!!M("rdng-2407-journey-cards-redesign-show"),c=K("check-card"),{mutate:x}=O(),g=y(G),d=l.useMemo(()=>i.find(a=>a.type==="CHECK"&&(a.data._id===n||a.data.key===n)),[i,n]),C=d?.data.cardData??null,r=C?.stepList??d?.data.stepList??[],N=C?.title??d?.data.title??"",f=!!(d&&(d.data.isLocked||d.data.isConcealed));l.useEffect(()=>{f&&s("/dash/index",{replace:!0})},[f,s]);const[S]=H(),p=S.get("step");l.useEffect(()=>{!p||r.length===0||document.querySelector(`[data-test="checkCardStep-${CSS.escape(p)}"]`)?.scrollIntoView({behavior:"smooth",block:"start"})},[p,r.length]);const b=F(r),w=()=>{o({type:V,payload:{currentState:"dash.index"}}),s("/dash/index")},E=a=>{const _=r.findIndex(I=>I._id===a._id);x({stepId:a._id,isComplete:!a.isComplete,stepName:a.title,stepNumber:_})};return f?null:e.jsxs("div",{className:"flex flex-col min-h-screen bg-background-primary","data-state":"ready",children:[e.jsx(U,{className:"bg-background-primary left-0",children:e.jsx(q,{className:"max-w-293!",children:e.jsx(W,{onClick:w})})}),e.jsx("main",{className:"mt-6 pb-[84px] flex justify-center px-6 py-6",children:e.jsxs("div",{className:"w-full max-w-[1000px] flex flex-col gap-4",children:[e.jsxs("div",{className:"flex items-center gap-2 text-content-soft",children:[e.jsx(Y,{width:16,height:16,"aria-hidden":"true"}),e.jsx(u,{as:"span",variant:"paragraph-xsmall",weight:"bold",className:"text-content-soft! uppercase",children:"To do"})]}),e.jsx(v,{as:"h1",size:"large","data-test":"checkCardTitle",children:N}),r.length>0&&e.jsxs(e.Fragment,{children:[e.jsxs("div",{className:h("sticky z-2 flex items-center gap-3 py-3.5 bg-background-primary border-b border-divider-line-light",X),"data-test":"checkCardProgress","data-count":b.completedCount,children:[e.jsx(Q,{size:"thin",percentage:b.percent,"aria-label":"Checklist progress"}),e.jsx(u,{as:"span",variant:"paragraph-small",weight:"bold",className:"text-content-subtle! whitespace-nowrap",children:b.label})]}),e.jsx("div",{className:"flex flex-col gap-3","data-test":"checkCardStepList",children:r.map(a=>e.jsx(ae,{step:a,isDeepLinkTarget:a._id===p,onToggleComplete:()=>{E(a)}},a._id))})]})]})}),e.jsx("footer",{className:"fixed bottom-0 left-0 w-full bg-background-secondary border-t border-divider-line-light px-6 py-4 flex items-center justify-center min-h-[84px] z-3",children:t??(m&&r.length>0?e.jsx(se,{stepList:r,onContinue:()=>void c()}):null)}),e.jsx(J,{isLoading:g,centered:!0})]})};export{xe as default};
2//# sourceMappingURL=index-LM0xLvHK.js.map

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.