PageSourceSearch

https://www.freecodecamp.org/component---src-templates-introductio…per-block-intro-tsx-6802d23e993e0c7e3d54.js

js freecodecamp.org collected 2026-09-24 07:55:41 UTC 55,307 bytes, 2 lines download raw bytes

1(self.webpackChunk_freecodecamp_client=self.webpackChunk_freecodecamp_client||[]).push([[1227],{8103:function(e,t,l){"use strict";var a=l(7378),n=l(61550),r=l(99198),c=l(43146);t.A=()=>{const{t:e}=(0,n.Bd)();return a.createElement(r.Pq,{variant:"note",label:e("misc.note")},a.createElement("p",{className:"archived-warning"},a.createElement(n.x6,{i18nKey:"learn.archive.content-not-updated"},a.createElement(c.N_,{to:"/learn"},"placeholder"))))}},25407:function(e,t,l){"use strict";l.r(t),l.d(t,{default:function(){return ht}});var a=l(98778),n=l(9553),r=l(36916),c=l(7378),s=l(69629),i=l(61550),o=l(22683),m=l(33961),d=l(9489),u=l(12923),h=l(99198),p=l(80765),g=l(15912),E=l(5890),k=l(80911),b=l(26499),C=l(87012),f=l(58598),v=l(87252),w=l(88427),N=l(66681);var y=l(75693),x=l(7572);const{clientLocale:S}=x;var B=function(e){let{superBlock:t}=e;const{t:l}=(0,i.Bd)();return function(e){return e===String(g.SB.RelationalDb)}(t)?c.createElement(c.Fragment,null,c.createElement(y.Y,null),"english"!=S&&c.createElement(h.Pq,{variant:"note",label:l("misc.note")},c.createElement("p",null,l("intro:misc-text.english-only")))):function(e){return e===String(g.SB.FoundationalCSharp)}(t)&&"english"!=S?c.createElement(h.Pq,{variant:"note",label:l("misc.note")},c.createElement("p",null,l("intro:misc-text.exam-english-only"))):null};function A(e,t){return(0,g.ct)({language:e}).includes(t)}var L=l(43146);const{clientLocale:R}=x;var D=function(e){let{superBlock:t}=e;const{t:l}=(0,i.Bd)();return A(R,t)?null:c.createElement("div",{style:{textAlign:"center"}},c.createElement(h.hK,{size:"m"}),c.createElement("p",{style:{marginBottom:0}},l("learn.help-translate")," "),c.createElement(L.N_,{external:!0,sameTab:!1,to:l("links:help-translate-link-url")},l("learn.help-translate-link")))},z=l(61608),F=l(85351);function T(e){return c.createElement("svg",Object.assign({"aria-hidden":"true",xmlns:"http://www.w3.org/2000/svg",width:"62",height:"55",viewBox:"0 0 62 42",fill:"none"},e),c.createElement("rect",{y:"17.2132",width:"61.5396",height:"7.69244",fill:"#d0d0d5"}),c.createElement("rect",{x:"12.8208",y:"0.973633",width:"8.54716",height:"41.0264",fill:"#d0d0d5"}),c.createElement("rect",{x:"39.3169",y:"0.973633",width:"8.54716",height:"41.0264",fill:"#d0d0d5"}),c.createElement("rect",{x:"4.14014",y:"5.84572",width:"8.77419",height:"31.2822",fill:"#d0d0d5"}),c.createElement("rect",{x:"47.0361",y:"5.84572",width:"8.77419",height:"31.2822",fill:"#d0d0d5"}))}T.displayName="DumbbellIcon";var M=T,$=l(44944),I=l(8103);const j=e=>{let{superBlock:t,superBlockNoteText:l,onCertificationDonationAlertClick:a,isDonating:n}=e;const{t:r}=(0,i.Bd)(),s=[g.SB.A2English,g.SB.B1English],o=[g.SB.A1Spanish,g.SB.A2Spanish,g.SB.A2Chinese,g.SB.A1Chinese,g.SB.FullStackDeveloperV9],m=s.includes(t),d=o.includes(t),u=!n&&(m||d);return l||u?c.createElement(c.Fragment,null,c.createElement(h.hK,{size:"m"}),c.createElement(h.Pq,{variant:"note",label:r("misc.note"),className:"super-block-intro-callout"},l&&c.createElement("p",null,l),u&&c.createElement(c.Fragment,null,c.createElement("p",null,m?r("donate.consider-donating"):c.createElement(i.x6,{i18nKey:"donate.consider-donating-2"},c.createElement(L.N_,{className:"inline",to:"/donate"},"placeholder"))),c.createElement("hr",null),c.createElement("p",{className:"btn-container"},c.createElement(L.N_,{className:"btn donate-button",key:"donate",sameTab:!1,to:"/donate",onClick:a},r("buttons.donate-now")))))):null};function P(e){let{superBlock:t,onCertificationDonationAlertClick:l,isDonating:a,hasNotstarted:n,nextChallengeSlug:r}=e;const{t:s}=(0,i.Bd)(),o=s(`intro:${t}`,{returnObjects:!0}),{title:m,intro:d,note:u}=o,p=Array.isArray(d)?d:"string"==typeof d?[d]:[""],E=e=>{let{fsd:l}=e;return c.createElement(c.Fragment,null,g.Ss.includes(t)&&c.createElement(I.A,null),c.createElement(h.hK,{size:"s"}),c.createElement(z._,{className:"cert-header-icon",superBlock:t}),c.createElement(h.hK,{size:"m"}),c.createElement("h1",{id:"content-start",className:"text-center big-heading"},m),c.createElement(h.hK,{size:"l"}),l&&c.createElement(h.mc,{fluid:!0,className:"full-width-container super-benefits-container"},c.createElement(h.mc,null,c.createElement(h.fI,null,c.createElement(h.fv,{xs:12,className:"super-block-benefits"},c.createElement("div",null,c.createElement($.A,null),c.createElement("div",{className:"benefit-text"},c.createElement("h3",null,s("misc.fsd-b-benefit-1-title")),c.createElement("p",null,s("misc.fsd-b-benefit-1-description")))),c.createElement("div",null,c.createElement(F.A,null),c.createElement("div",{className:"benefit-text"},c.createElement("h3",null,s("misc.fsd-b-benefit-2-title")),c.createElement("p",null,s("misc.fsd-b-benefit-2-description")))),c.createElement("div",null,c.createElement(M,null),c.createElement("div",{className:"benefit-text"},c.createElement("h3",null,s("misc.fsd-b-benefit-3-title")),c.createElement("p",null,s("misc.fsd-b-benefit-3-description")))))))),r&&!l&&c.createElement(L.N_,{className:"btn-cta-big btn-block signup-btn btn-cta intro-top-cta",to:r,"data-test-label":n?"start-learning":"continue-learning"},s(n?"misc.fsd-b-cta":"misc.continue-learning")),c.createElement(h.hK,{size:"l"}),p.map((e,t)=>c.createElement("p",{dangerouslySetInnerHTML:{__html:e},key:t}
1)))};return c.createElement(c.Fragment,null,c.createElement(E,{fsd:t===g.SB.FullStackDeveloperV9}),c.createElement(j,{superBlock:t,superBlockNoteText:u,onCertificationDonationAlertClick:l,isDonating:a}))}P.displayName="SuperBlockIntro";var V=P,_=l(90362),H=l(95186);var K=function(e){let{isCompleted:t}=e;return t?c.createElement(H.A,{hushScreenReaderText:!0}):c.createElement(_.A,{hushScreenReaderText:!0})},O=l(15212),q=l(63598),G=l(99703),J=l(43941),W=l(23622);let Q=function(e){return e.lecture="lecture",e.workshop="workshop",e.lab="lab",e.review="review",e.quiz="quiz",e.exam="exam",e.certProject="cert-project",e.warmup="warm-up",e.learn="learn",e.practice="practice",e}({}),Z=function(e){return e.ChallengeList="challenge-list",e.Link="link",e.ChallengeGrid="challenge-grid",e.DialogueGrid="dialogue-grid",e.LegacyChallengeList="legacy-challenge-list",e.LegacyChallengeGrid="legacy-challenge-grid",e.LegacyLink="legacy-link",e.ProjectList="project-list",e}({});var U=l(67332);const Y=e=>{let{isCompleted:t}=e;return t?c.createElement(H.A,
1null):c.createElement(_.A,null)},X=e=>{let{challenge:t,onChallengeClick:l}=e;return c.createElement(L.N_,{to:t.fields.slug,onClick:l},c.createElement("span",null,c.createElement(Y,{isCompleted:t.isCompleted})),t.title)},ee=e=>{let{challenge:t,onChallengeClick:l}=e;return c.createElement(L.N_,{to:t.fields.slug,onClick:l},t.title,c.createElement("span",{className:"map-project-checkmark"},c.createElement(Y,{isCompleted:t.isCompleted})))};function te(e){let{challenges:t,onChallengeClick:l}=e;return c.createElement("ul",{className:"map-challenges-ul"},t.map(e=>c.createElement("li",{className:"map-challenge-title map-challenge-wrap",id:e.dashedName,key:"map-challenge"+e.fields.slug},c.createElement(X,{challenge:e,onChallengeClick:l}))))}const le=e=>{let{challenge:t,isTask:l=!1,onChallengeClick:a}=e;const{t:n}=(0,i.Bd)();return c.createElement(L.N_,{to:t.fields.slug,onClick:a,className:"map-grid-item "+(t.isCompleted?"challenge-completed":"")},c.createElement("span",{className:"sr-only"},n(l?"aria.task":"aria.step")),c.createElement("span",null,t.stepNumber),c.createElement("span",{className:"sr-only"},t.isCompleted?n("icons.passed"):n("icons.not-passed")))},ae=e=>{let{challenges:t,blockTitle:l,onChallengeClick:a}=e;const{t:n}=(0,i.Bd)(),r=t.find(e=>!e.isCompleted),s=!!t.find(e=>e.isCompleted);return r?c.createElement("div",{className:"challenge-jump-link"},c.createElement(U.v,{size:"small",href:r.fields.slug,onClick:a},n(s?"buttons.resume-project":"buttons.start-project")," ",c.createElement("span",{className:"sr-only"},l))):null},ne=e=>{let{challenges:t,blockTitle:l,isProjectBlock:a,jumpLink:n,onChallengeClick:r}=e;const{t:s}=(0,i.Bd)();return c.createElement(c.Fragment,null,n&&c.createElement(ae,{challenges:t,blockTitle:l,onChallengeClick:r}),c.createElement("nav",{"aria-label":s("aria.steps-for",{blockTitle:l})},c.createElement("ul",{className:"map-challenges-ul map-challenges-grid"},t.map(e=>c.createElement("li",{className:"map-challenge-title "+(a?"map-project-wrap":e.challengeType===O.pr.dialogue?"map-dialogue-wrap":"map-challenge-wrap"),id:e.dashedName,key:`map-challenge ${e.fields.slug}`},a?c.createElement(ee,{challenge:e,onChallengeClick:r}):c.createElement(le,{challenge:e,onChallengeClick:r}))))))},re=e=>{let{challenges:t,blockTitle:l,jumpLink:a,onChallengeClick:n}=e;const{t:r}=(0,i.Bd)();return c.createElement(c.Fragment,null,a&&c.createElement(ae,{challenges:t,blockTitle:l,onChallengeClick:n}),c.createElement("nav",{"aria-label":r("aria.dialogues-and-tasks-for",{blockTitle:l})},c.createElement("ul",{className:"map-challenges-ul map-challenges-grid"},t.map(e=>c.createElement("li",{className:"map-challenge-title map-challenge-title-grid "+(e.challengeType===O.pr.dialogue?"map-dialogue-wrap":"map-challenge-wrap"),id:e.dashedName,key:`map-challenge ${e.fields.slug}`},e.challengeType===O.pr.dialogue?c.createElement(X,{challenge:e,onChallengeClick:n}):c.createElement(le,{challenge:e,isTask:!0,onChallengeClick:n}))))))};var ce=function(e){let{blockLabel:t}=e;const{t:l}=(0,i.Bd)();return c.createElement("div",{className:`block-label block-label-${t}`},l(`learn.block-type.${t}`))},se=l(49686),ie=l.n(se),oe=l(41542),me=l(86048),de=l(26649),ue=l(79480);function he(){return c.createElement(de.gc,{icon:ue.sjs,"aria-hidden":"true"})}he.displayName="Reset";var pe=he;var ge=function(e){let{intros:t}=e;return c.createElement("div",{className:"block-description"},t.map((e,t)=>c.createElement("p",{dangerouslySetInnerHTML:{__html:e},key:t})))};var Ee=function(e){let{blockDashed:t,blockTitle:l,blockLabel:a,completedCount:n,courseCompletionStatus:r,handleClick:s,isCompleted:o,isExpanded:m,percentageCompleted:d,blockIntroArr:u,accordion:p,blockUrl:g,onLinkClick:E,onResetClick:k,isResetDisabled:b}=e;const{t:C}=(0,i.Bd)(),f=()=>c.createElement(c.Fragment,null,c.createElement("span",{className:"block-header-button-text map-title"},p&&(g?c.createElement("span",{className:"aligner-dash"}):c.createElement(me.A,null)),c.createElement(K,{isCompleted:o}),!p&&a&&c.createElement(ce,{blockLabel:a}),c.createElement("span",null,l,c.createElement("span",{className:"sr-only"},", ",r)),p&&a&&c.createElement(ce,{blockLabel:a}
1),!p&&c.createElement(me.A,null)),!p&&!m&&!o&&n>0&&c.createElement("div",{"aria-hidden":"true",className:"progress-wrapper"},c.createElement("div",null,c.createElement(oe.z,{now:d})),c.createElement("span",null,`${d}%`)));return c.createElement(c.Fragment,null,c.createElement("div",{className:"block-header-wrapper"},c.createElement("h3",{className:"block-grid-title"},p&&g?c.createElement(L.N_,{className:"block-header",to:g,onClick:E},c.createElement(f,null)):c.createElement(h.$n,{"aria-expanded":m?"true":"false","aria-controls":`${t}-panel`,className:"block-header",onClick:s,"data-playwright-test-label":"block-header-button"},c.createElement(f,null))),k&&c.createElement("button",{className:"block-reset-button",onClick:k,"aria-label":C("learn.reset-progress-aria-block",{blockLabel:l}),type:"button",disabled:b},c.createElement(pe,null))),m&&!ie()(u)&&c.createElement(ge,{intros:u}))},ke=l(75365),be=l(70632);function Ce(e){let{blockTitle:t,blockDashedName:l,superBlock:a,onHide:n,onResetComplete:r,show:s}=e;const{t:o}=(0,i.Bd)(),[m,d]=(0,c.useState)(""),[u,p]=(0,c.useState)("idle"),g=(0,c.useRef)(!0);(0,c.useEffect)(()=>()=>{g.current=!1},[]);const E=o("learn.reset-progress-verify"),k=Array.isArray(l)?l:[l],b=()=>{n()};(0,c.useEffect)(()=>{if(s)return;const e=window.setTimeout(()=>{p("idle"),d("")},300);return()=>clearTimeout(e)},[s]);const C="in-flight"!==u,f="success"===u||"error"===u;return c.createElement(h.aF,{size:"large",onClose:()=>{"in-flight"!==u&&b()},variant:"danger",open:s},c.createElement(h.aF.Header,{showCloseButton:C,closeButtonClassNames:"close"},o("learn.reset-progress-heading",{label:t})),c.createElement(h.aF.Body,{alignment:"start",borderless:!0},c.createElement(h.hK,{size:"xs"}),"in-flight"===u&&c.createElement("div",{className:"reset-progress-container text-center"},c.createElement(be.A,null),c.createElement(h.hK,{size:"xs"}),c.createElement("p",null,o("learn.reset-progress-in-flight"))),"success"===u&&c.createElement(h.Fc,{variant:"success"},o("learn.reset-progress-success",{label:t})),"error"===u&&c.createElement(h.Fc,{variant:"danger"},o("learn.reset-progress-failure")),"idle"===u&&c.createElement(c.Fragment,null,c.createElement("p",null,o("learn.reset-progress-description",{label:t})),c.createElement("p",null,o("learn.reset-progress-warning")))),c.createElement(h.aF.Footer,null,f&&c.createElement(h.$n,{block:!0,size:"large",variant:"primary",onClick:b,type:"button"},o("learn.reset-progress-dismiss")),"idle"===u&&c.createElement(c.Fragment,null,c.createElement(h.$n,{block:!0,size:"large",variant:"primary",onClick:b,type:"button"},o("learn.reset-progress-nevermind")),c.createElement(h.hK,{size:"xs"}),c.createElement(h.gE,{controlId:"verify-reset-progress"},c.createElement(h.mq,{htmlFor:"verify-reset-progress-input"},o("settings.danger.verify-text",{verifyText:E})),c.createElement(h.hK,{size:"xs"}),c.createElement(h.MJ,{onChange:e=>{d(e.target.value)},value:m,id:"verify-reset-progress-input"})),c.createElement(h.hK,{size:"xs"}),c.createElement(h.$n,{block:!0,size:"large",variant:"danger",disabled:m!==E,onClick:()=>{(async()=>{p("in-flight");const e=Date.now();let t="success";try{var l;const{response:e,data:t}=await(0,ke.T7)({blockIds:k});if(!e.ok)throw new Error(`HTTP Error: ${e.status} ${e.statusText}`);r(null!==(l=t.removedChallengeIds)&&void 0!==l?l:[])}catch(n){console.error("Failed to reset module:",n),t="error"}const a=Date.now()-e;a<1e3&&await new Promise(e=>setTimeout(e,1e3-a)),g.current&&p(t)})()},type:"button"},o("learn.reset-progress-confirm")))))}Ce.displayName="ResetProgressModal";var fe=Ce;const{curriculumLocale:ve}=x;class we extends c.Component{constructor(e){super(e),this.state={showResetModal:!1},this.handleBlockClick=this.handleBlockClick.bind(this),this.handleChallengeClick=this.handleChallengeClick.bind(this),this.handleResetClick=this.handleResetClick.bind(this),this.handleResetConfirm=this.handleResetConfirm.bind(this),this.handleResetModalClose=this.handleResetModalClose.bind(this)}handleBlockClick=()=>{const{block:e,toggleBlock:t}=this.props;(0,G.R)("block-toggle"),t(e)};handleChallengeClick=()=>{const{block:e}=this.props,t=e.toLowerCase().replace(/\s+/g,"-").replace(/[^a-z0-9-]/g,"");window.history.pushState(null,"",`#${t}`)};handleResetClick=()=>{this.setState({showResetModal:!0})};handleResetConfirm=e=>{const{removeModuleChallenges:t}=this.props;t({removedChallengeIds:e})};handleResetModalClose=()=>{this.setState({showResetModal:!1})};render(){var e,t,l,a,n;const{block:r,blockLabel:s,completedChallengeIds:i,challenges:o,isExpanded:d,superBlock:u,t:p,accordion:E=!1,expandAll:k=!1}=this.props,b=k||d;let C=0,f=0;const v=o.map(e=>{const{id:t}=e,l=i.some(e=>e===t);return l&&C++,e.challengeType!==O.pr.dialogue&&f++,{...e,isCompleted:l,stepNumber:f}}),w=o.some(e=>(0,W.x)(e.challengeType,r)),N=A(ve,u),y=p(`intro:${u}.blocks.${r}.title`),x=p(`intro:${u}.blocks.${r}.intro`,{returnObjects:!0}),S=p("intro:misc-text.expand"),B=p("intro:misc-text.collapse"),R=C===o.length,D=Math.floor(C/o.length*100),z=(null===(e=o[0])||void 0===e?void 0:e.fields.slug)||"",F=null===(t=o[0])||void 0===t?void 0:t.blockLayout,T=F===Z.ChallengeGrid,M=!o.length,$=()=>
10===C?p("learn.not-started"):R?p("learn.completed"):`${D}% ${p("learn.completed")}`,I=c.createElement(m.Hg,{name:r},c.createElement("div",{className:"block "+(b?"open":"")},c.createElement("div",{className:"block-header"},c.createElement("h3",{className:"big-block-title"},y),s&&c.createElement(ce,{blockLabel:s}),!N&&c.createElement("div",{className:"block-cta-wrapper"},c.createElement(L.N_,{className:"block-title-translation-cta",to:p("links:help-translate-link-url")},p("misc.translation-pending")))),c.createElement("button",{"aria-expanded":b,className:"map-title",onClick:()=>{this.handleBlockClick()}},c.createElement(q.A,null),c.createElement("div",{className:"course-title"},`${b?B:S}`," ",c.createElement("span",{className:"sr-only"},y)),c.createElement("div",{className:"map-title-completed course-title"},c.createElement(K,{isCompleted:R}),c.createElement("span",{"aria-hidden":"true"},`${C}/${o.length}`),c.createElement("span",{className:"sr-only"},","," ",p("learn.challenges-completed",{completedCount:C,totalChallenges:o.length})))),b&&c.createElement(te,{challenges:v,onChallengeClick:this.handleChallengeClick}))),j=c.createElement(m.Hg,{name:r},c.createElement("div",{className:"block"},c.createElement("div",{className:"block-header"},c.createElement("h3",{className:"big-block-title"},y),s&&c.createElement(ce,{blockLabel:s}),!N&&c.createElement("div",{className:"block-cta-wrapper"},c.createElement(L.N_,{className:"block-title-translation-cta",to:p("links:help-translate-link-url")},p("misc.translation-pending")))),c.createElement(te,{challenges:v,onChallengeClick:this.handleChallengeClick}))),P=c.createElement(m.Hg,{name:r},c.createElement("div",{className:"block block-grid "+(b?"open":"")},c.createElement(Ee,{blockDashed:r,blockTitle:y,blockLabel:s,completedCount:C,courseCompletionStatus:$(),handleClick:this.handleBlockClick,isCompleted:R,isExpanded:b,percentageCompleted:D,accordion:E,blockIntroArr:E?void 0:x,isResetDisabled:0===C,onResetClick:this.handleResetClick}),b&&c.createElement(c.Fragment,null,!N&&c.createElement("div",{className:"tags-wrapper"},c.createElement(L.N_,{className:"cert-tag",to:p("links:help-translate-link-url")},p("misc.translation-pending"))),c.createElement("div",{id:`${r}-panel`},c.createElement(ne,{jumpLink:!E,challenges:v,isProjectBlock:w,blockTitle:y,onChallengeClick:this.handleChallengeClick}))))),V=c.createElement(m.Hg,{name:r},c.createElement("div",{className:"block block-grid "+(b?"open":"")},c.createElement(Ee,{blockDashed:r,blockTitle:y,blockLabel:s,completedCount:C,courseCompletionStatus:$(),handleClick:this.handleBlockClick,isCompleted:R,isExpanded:b,percentageCompleted:D,accordion:E,blockIntroArr:E?void 0:x,isResetDisabled:0===C,onResetClick:this.handleResetClick}),b&&c.createElement(c.Fragment,null,!N&&c.createElement("div",{className:"tags-wrapper"},c.createElement(L.N_,{className:"cert-tag",to:p("links:help-translate-link-url")},p("misc.translation-pending"))),c.createElement("div",{id:`${r}-panel`},c.createElement(re,{challenges:v,blockTitle:y,jumpLink:!E,onChallengeClick:this.handleChallengeClick}))))),_=c.createElement(m.Hg,{name:r},c.createElement("div",{className:"block block-grid grid-project-block"},c.createElement("div",{className:"tags-wrapper"},c.createElement("span",{className:"cert-tag","aria-hidden":"true"},p("misc.certification-project")),!N&&c.createElement(L.N_,{className:"cert-tag",to:p("links:help-translate-link-url")},p("misc.translation-pending")," ",c.createElement("span",{className:"sr-only"},y," ",p("misc.certification-project")))),c.createElement("div",{className:"title-wrapper map-title"},s&&c.createElement(ce,{blockLabel:s}),c.createElement("h3",{className:"block-grid-title"},c.createElement(L.N_,{className:"block-header",onClick:this.handleChallengeClick,to:z},c.createElement(K,{isCompleted:R}),y," ",c.createElement("span",{className:"sr-only"},R?`${p("misc.certification-project")}, ${p("learn.completed")}`:`${p("misc.certification-project")}, ${p("learn.not-completed")}`)))))),H=E?c.createElement(c.Fragment,null,c.createElement(m.Hg,{name:r},c.createElement("span",{className:"hide-scrollable-anchor"})),c.createElement("div",{className:"block block-grid block-grid-no-border challenge-grid-block "+(b?"open":"")},c.createElement(Ee,{blockDashed:r,blockTitle:y,blockLabel:s,completedCount:C,courseCompletionStatus:$(),handleClick:this.handleBlockClick,isCompleted:R,isExpanded:b,percentageCompleted:D,accordion:E,isResetDisabled:0===C,onResetClick:this.handleResetClick}),b&&c.createElement("div",{className:"accordion-block-expanded"},!N&&c.createElement("div",{className:"tags-wrapper"},c.createElement(L.N_,{className:"cert-tag",to:p("links:help-translate-link-url")},p("misc.translation-pending"))),c.createElement("div",{id:`${r}-panel`,className:T?"challenge-grid-block-panel":""},T?c.createElement(ne,{challenges:v,blockTitle:y,isProjectBlock:w,jumpLink:!1,onChallengeClick:this.handleChallengeClick}):c.createElement(te,{challenges:v,onChallengeClick:this.handleChallengeClick}))))):c.createElement(c.Fragment,null,c.createElement(m.Hg,{name:r},c.createElement("span",{className:"hide-scrollable-anchor"})),c.createElement("div",{className:"block block-grid challenge-grid-block "+(b?"open":"")},c.createElement(Ee,{blockDashed:r,blockTitle:y,blockLabel:s,completedCount:C,courseCompletionStatus:$(),handleClick:this.handleBlockClick,isCompleted:R,isExpanded:b,percentageCompleted:D,accordion:E,blockIntroArr:x,isResetDisabled:0===C,onResetClick:this.handleResetClick}),b&&c.createElement("div",{className:"accordion-block-expanded"},!N&&c.createElement("div",{className:"tags-wrapper"},c.createElement(L.N_,{className:"cert-tag",to:p("links:help-translate-link-url")},p("misc.translation-pending"))),c.createElement("div",{id:`${r}-panel`,className:T?"challenge-grid-block-panel":""},T?c.createElement(ne,{jumpLink:!0,challenges:v,blockTitle:y,isProjectBlock:w,onChallengeClick:this.handleChallengeClick}):c.createElement(te,{challenges:v,onChallengeClick:this.handleChallengeClick}))))),G=c.createElement(c.Fragment,null,c.createElement(m.Hg,{name:r},c.createElement("span",{className:"hide-scrollable-anchor"})),c.createElement(Ee,{blockDashed:r,blockTitle:y,blockLabel:s,completedCount:C,courseCompletionStatus:$(),handleClick:this.handleBlockClick,onLinkClick:this.handleChallengeClick,isCompleted:R,isExpanded:b,percentageCompleted:D,accordion:E,blockUrl:null!==(l=null==o||null===(a=o[0])||void 0===a||null===(n=a.fields)||void 0===n?void 0:n.slug)&&void 0!==l?l:"",isResetDisabled:0===C,onResetClick:this.handleResetClick})),J={[Z.ChallengeGrid]:H,[Z.ChallengeList]:H,[Z.Link]:E?G:H,[Z.ProjectList]:j,[Z.LegacyLink]:_,[Z.LegacyChallengeList]:I,[Z.LegacyChallengeGrid]:P,[Z.DialogueGrid]:V};return!M&&c.createElement(c.Fragment,null,J[F],!g.EQ.includes(u)&&c.createElement(h.hK,{size:"xs"}),c.createElement(fe,{blockTitle:y,blockDashedName:r,superBlock:u,show:this.state.showResetModal,onHide:this.handleResetModalClose,onResetComplete:this.handleResetConfirm}))}}we.displayName="Block";var Ne=(0,o.Ng)((e,t)=>{const l=(0,J.eh)(t.block);return(0,u.Mz)(l,v.hm,(e,t)=>({isExpanded:e,completedChallengeIds:t.map(e=>{let{id:t}=e;return t})}))(e)},e=>(0,d.zH)({toggleBlock:J.qj,removeModuleChallenges:f.xf},e))((0,i.CI)()(we)),ye=l(55992);const xe=e=>{var t,l;let{superBlock:a,fetchState:n,isSignedIn:r,user:s}=e;const{t:o}=(0,i.Bd)(),[m,d]=(0,c.useState)(!1),{currentCerts:u,legacyCerts:p}=(0,ye.u)(s),{username:g}=s,E=N.iy[a],k=w.Gb.find(e=>e.certSlug===E);if(!k)throw Error(`Certification ${E} not found`);const b=k.certSlug;(0,c.useEffect)(()=>{const{pending:e,complete:t}=n;t&&!e&&d(!0)},[n]);const C=null!==(t=null===(l=[...u,...p].find(e=>e.certSlug===N.iy[a]))||void 0===l?void 0:l.show)&&void 0!==t&&t,f=`/certification/${g}/${b}`,v=o(`certification.title.${E}`);return c.createElement("div",null,r&&c.createElement(h.$n,{block:!0,variant:"primary",href:C?f:`/settings#cert-${b}`},o(C&&m?"buttons.show-cert":"buttons.go-to-settings")," ",c.createElement("span",{className:"sr-only"},v)))};xe.displayName="CertChallenge";var Se=(0,o.Ng)(e=>(0,u.Mz)(v.SR,v.$k,(e,t)=>({fetchState:e,isSignedIn:t}))(e))((0,i.CI)()(xe));let Be=function(e){return e.Welcome="freecodecamp",e.Javascript="javascript",e.FrontendLibraries="frontend-libraries",e.BackendJavascript="backend-javascript",e.Career="career",e.RwdExam="responsive-web-design-certification-exam",e.JsExam="javascript-certification-exam",e.Fed="front-end-development-libraries",e.FedExam="front-end-development-libraries-certification-exam",e.PythonExam="python-certification-exam",e.RdbExam="relational-databases-certification-exam",e.Bed="back-end-development-and-apis",e.BedExam="back-end-development-and-apis-certification-exam",e.FsdExam="certified-full-stack-developer-exam",e.Html="html",e.Css="css",e.Python="python",e.RelationalDatabases="relational-databases",e}({}),Ae=function(e){return e.zhA1Welcome="zh-a1-chapter-welcome-to-a1-professional-chinese",e.zhA1PinYin="zh-a1-chapter-pinyin",e.zhA1Greetings="zh-a1-chapter-greetings-and-introductions",e.zhA1GreetingsLegacy="zh-a1-chapter-greeting-and-self-introduction",e.zhA1NumbersAndPersonalInformation="zh-a1-chapter-numbers-and-personal-information",e.zhA1Family="zh-a1-chapter-introducing-colleagues-and-family",e.zhA1Expressing="zh-a1-chapter-expressing-what-you-can-and-cant-do",e}({}),Le=function(e){return e.esA1Welcome="es-a1-chapter-welcome-to-a1-professional-spanish",e.esA1Fundamentals="es-a1-chapter-spanish-fundamentals",e.esA1Greetings="es-a1-chapter-greetings-and-introductions",e.esA1Details="es-a1-chapter-basic-personal-details",e.esA1Describing="es-a1-chapter-describing-company-and-people",e}({});var Re=l(28936),De=l(22994),ze=l(79262),Fe=l(94309);function Te(e){return c.createElement("svg",Object.assign({xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 576 512"}
1,e),c.createElement("path",{d:"M97.2 96.2c10.4-10.7 16-17.1 16-21.9 0-2.8-1.9-5.5-3.8-7.4A14.8 14.8 0 0 0 101 64.1c-8.5 0-20.9 8.8-35.8 25.7C23.7 137 2.5 182.8 3.4 250.3s17.5 117 54.1 161.9C76.2 435.9 90.6 448 100.9 448a13.6 13.6 0 0 0 8.4-3.8c1.9-2.8 3.8-5.6 3.8-8.4 0-5.6-3.9-12.2-13.2-20.6-44.5-42.3-67.3-97-67.5-165C32.3 188.8 54 137.8 97.2 96.2zM239.5 420.1c.6 .4 .9 .6 .9 .6zm93.8 .6 .2-.1C333.2 420.6 333.2 420.7 333.3 420.6zm3.1-158.2c-16.2-4.2 50.4-82.9-68.1-177.2 0 0 15.5 49.4-62.8 159.6-74.3 104.4 23.5 168.7 34 175.2-6.7-4.4-47.4-35.7 9.6-128.6 11-18.3 25.5-34.9 43.5-72.2 0 0 15.9 22.5 7.6 71.1C287.7 364 354 342.9 355 343.9c22.8 26.8-17.7 73.5-21.6 76.6 5.5-3.7 117.7-78 33-188.1C360.4 238.4 352.6 266.6 336.4 262.4zM510.9 89.7C496 72.8 483.5 64 475 64a14.8 14.8 0 0 0 -8.4 2.8c-1.9 1.9-3.8 4.7-3.8 7.4 0 4.8 5.6 11.3 16 21.9 43.2 41.6 65 92.6 64.8 154.1-.2 68-23 122.6-67.5 165-9.3 8.4-13.2 14.9-13.2 20.6 0 2.8 1.9 5.6 3.8 8.4A13.6 13.6 0 0 0 475.1 448c10.3 0 24.7-12.1 43.5-35.8 36.6-44.9 53.1-94.4 54.1-161.9S552.3 137 510.9 89.7z"}))}Te.displayName="FreeCodeCampIcon";var Me=Te;function $e(e){return c.createElement("svg",Object.assign({xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 384 512"},e),c.createElement("path",{d:"M0 32l34.9 395.8L191.5 480l157.6-52.2L384 32H0zm308.2 127.9H124.4l4.1 49.4h175.6l-13.6 148.4-97.9 27v.3h-1.1l-98.7-27.3-6-75.8h47.7L138 320l53.5 14.5 53.7-14.5 6-62.2H84.3L71.5 112.2h241.1l-4.4 47.7z"}))}$e.displayName="Html";var Ie=$e;function je(e){return c.createElement("svg",Object.assign({xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 384 512"},e),c.createElement("path",{d:"M0 32l34.9 395.8L192 480l157.1-52.2L384 32H0zm313.1 80l-4.8 47.3L193 208.6l-.3 .1h111.5l-12.8 146.6-98.2 28.7-98.8-29.2-6.4-73.9h48.9l3.2 38.3 52.6 13.3 54.7-15.4 3.7-61.6-166.3-.5v-.1l-.2 .1-3.6-46.3L193.1 162l6.5-2.7H76.7L70.9 112h242.2z"}))}je.displayName="Css";var Pe=je;function Ve(e){return c.createElement("svg",Object.assign({xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 448 512"},e),c.createElement("path",{d:"M224 508c-6.7 0-13.5-1.8-19.4-5.2l-61.7-36.5c-9.2-5.2-4.7-7-1.7-8 12.3-4.3 14.8-5.2 27.9-12.7 1.4-.8 3.2-.5 4.6 .4l47.4 28.1c1.7 1 4.1 1 5.7 0l184.7-106.6c1.7-1 2.8-3 2.8-5V149.3c0-2.1-1.1-4-2.9-5.1L226.8 37.7c-1.7-1-4-1-5.7 0L36.6 144.3c-1.8 1-2.9 3-2.9 5.1v213.1c0 2 1.1 4 2.9 4.9l50.6 29.2c27.5 13.7 44.3-2.4 44.3-18.7V167.5c0-3 2.4-5.3 5.4-5.3h23.4c2.9 0 5.4 2.3 5.4 5.3V378c0 36.6-20 57.6-54.7 57.6-10.7 0-19.1 0-42.5-11.6l-48.4-27.9C8.1 389.2 .7 376.3 .7 362.4V149.3c0-13.8 7.4-26.8 19.4-33.7L204.6 9c11.7-6.6 27.2-6.6 38.8 0l184.7 106.7c12 6.9 19.4 19.8 19.4 33.7v213.1c0 13.8-7.4 26.7-19.4 33.7L243.4 502.8c-5.9 3.4-12.6 5.2-19.4 5.2zm149.1-210.1c0-39.9-27-50.5-83.7-58-57.4-7.6-63.2-11.5-63.2-24.9 0-11.1 4.9-25.9 47.4-25.9 37.9 0 51.9 8.2 57.7 33.8 .5 2.4 2.7 4.2 5.2 4.2h24c1.5 0 2.9-.6 3.9-1.7s1.5-2.6 1.4-4.1c-3.7-44.1-33-64.6-92.2-64.6-52.7 0-84.1 22.2-84.1 59.5 0 40.4 31.3 51.6 81.8 56.6 60.5 5.9 65.2 14.8 65.2 26.7 0 20.6-16.6 29.4-55.5 29.4-48.9 0-59.6-12.3-63.2-36.6-.4-2.6-2.6-4.5-5.3-4.5h-23.9c-3 0-5.3 2.4-5.3 5.3 0 31.1 16.9 68.2 97.8 68.2 58.4-.1 92-23.2 92-63.4z"}))}Ve.displayName="NodeIcon";var _e=Ve,He=l(7061),Ke=l(94651);const Oe={[Be.Welcome]:Me,[Be.Html]:Ie,[Be.Css]:Pe,[Be.Javascript]:De.A,[Be.FrontendLibraries]:ze.A,[Be.RelationalDatabases]:Re.A,[Be.BackendJavascript]:_e,[Be.Python]:He.A,[Be.Career]:Ke.A,[Be.RwdExam]:Ke.A,[Be.JsExam]:Ke.A,[Be.Fed]:ze.A,[Be.FedExam]:Ke.A,[Be.PythonExam]:Ke.A,[Be.RdbExam]:Ke.A,[Be.Bed]:_e,[Be.BedExam]:Ke.A,[Be.FsdExam]:Ke.A,[Ae.zhA1Welcome]:ue.uQF,[Ae.zhA1PinYin]:ue.kwR,[Ae.zhA1Greetings]:ue.q9p,[Ae.zhA1GreetingsLegacy]:ue.q9p,[Ae.zhA1NumbersAndPersonalInformation]:ue.Lmx,[Ae.zhA1Family]:ue.Lmx,[Ae.zhA1Expressing]:ue.STm,[Le.esA1Welcome]:ue.uQF,[Le.esA1Fundamentals]:ue.kwR,[Le.esA1Greetings]:ue.q9p,[Le.esA1Details]:ue.Lmx,[Le.esA1Describing]:ue.URI};function qe(e){var t;const{chapter:l,...a}=e,n=null!==(t=Oe[l])&&void 0!==t?t:Fe.A;return"object"==typeof n?c.createElement(de.gc,{icon:n,size:"lg"}):c.createElement(n,a)}const{showUpcomingChanges:Ge}=x,Je=e=>{let{dashedName:t,children:l,isExpanded:a,comingSoon:n,totalSteps:r,completedSteps:s,superBlock:o,isLinkChapter:m,examSlug:d,blockDashedNames:u,onResetComplete:h}=e;const{t:p}=(0,i.Bd)(),[g,E]=(0,c.useState)(a),[k,b]=(0,c.useState)(!1);(0,c.useEffect)(()=>{E(a)},[a]);const C=`chapter-panel-${t}`,f=s===r&&r>0,v=p(`intro:${o}.chapters.${t}`),w=p(g?"intro:misc-text.collapse":"intro:misc-text.expand"),N=0===s,y=()=>E(e=>!e),x=!n&&!m?c.createElement("button",{className:"block-reset-button",onClick:e=>{e.stopPropagation(),b(!0)}
1,"aria-label":p("learn.reset-progress-aria-chapter",{chapterLabel:v}),type:"button",disabled:N},c.createElement(pe,null)):null,S=c.createElement("div",{className:"chapter-button-left"},c.createElement("span",{className:"checkmark-wrap chapter-checkmark-wrap"},c.createElement(K,{isCompleted:f})),c.createElement(qe,{className:"map-icon",chapter:t}),v,m&&d&&c.createElement(ce,{blockLabel:Q.exam})),B=c.createElement("div",{className:"chapter-button-right"},!n&&!m&&c.createElement("span",{className:"chapter-steps"},p("learn.steps-completed",{totalSteps:r,completedSteps:s})),c.createElement("span",{className:"dropdown-wrap"},!m&&c.createElement(me.A,null)));return m&&d?c.createElement("li",{className:"chapter"},c.createElement(L.N_,{className:"chapter-header-wrapper chapter-link","data-playwright-test-label":"chapter-button",to:d},S,B)):c.createElement("li",{className:"chapter"},c.createElement("div",{className:"chapter-header-wrapper"},c.createElement("button",{"aria-controls":C,"aria-expanded":g,className:"chapter-button chapter-button-main","data-playwright-test-label":"chapter-button",onClick:y,type:"button"},S),x,c.createElement("button",{"aria-controls":C,"aria-expanded":g,"aria-label":`${w} ${v}`,className:"chapter-button chapter-button-toggle","data-playwright-test-label":"chapter-button-toggle",onClick:y,type:"button"},B)),g&&c.createElement("ul",{className:"chapter-panel",id:C},l),c.createElement(fe,{blockTitle:v,blockDashedName:u,superBlock:o,show:k,onHide:()=>{b(!1)},onResetComplete:h}))},We=e=>{let{dashedName:t,children:l,isExpanded:a,totalSteps:n,completedSteps:r,superBlock:s,comingSoon:o,blockDashedNames:m,onResetComplete:d}=e;const{t:u}=(0,i.Bd)(),[h,p]=(0,c.useState)(a),[g,E]=(0,c.useState)(!1);(0,c.useEffect)(()=>{p(a)},[a]);const k=`module-panel-${t}`,b=0!==n&&r===n,C=u(`intro:${s}.modules.${t}`),f=u(h?"intro:misc-text.collapse":"intro:misc-text.expand"),{note:v,intro:w}=u(`intro:${s}.module-intros.${t}`,{returnObjects:!0}),N=!(o&&!Ge),y=0===r,x=()=>p(e=>!e),S=!o?c.createElement("button",{className:"block-reset-button",onClick:e=>{e.stopPropagation(),E(!0)},"aria-label":u("learn.reset-progress-aria-module",{moduleLabel:C}),type:"button",disabled:y},c.createElement(pe,null)):null;return c.createElement("li",null,c.createElement("div",{className:"module-header-wrapper"},c.createElement("button",{"aria-controls":k,"aria-expanded":h,className:"module-button module-button-main",onClick:x,type:"button"},c.createElement("div",{className:"module-button-left"},c.createElement("span",{className:"dropdown-wrap"},c.createElement(me.A,null)),c.createElement("span",{className:"checkmark-wrap"},c.createElement(K,{isCompleted:b})),C)),S,c.createElement("button",{"aria-controls":k,"aria-expanded":h,"aria-label":`${f} ${C}`,className:"module-button module-button-toggle","data-testid":"module-button-right",onClick:x,type:"button"},c.createElement("div",{className:"module-button-right"},!o&&!!n&&c.createElement("span",{className:"module-steps"},u("learn.steps-completed",{totalSteps:n,completedSteps:r}))))),h&&c.createElement("ul",{className:"module-panel",id:k},o&&c.createElement("div",{className:"module-intro"},v&&c.createElement("p",null,c.createElement("b",null,v)),(null==w?void 0:w.length)&&w.map(e=>c.createElement("p",{key:e},e))),N&&l),c.createElement(fe,{blockTitle:C,blockDashedName:m,superBlock:s,show:g,onHide:()=>{E(!1)},onResetComplete:d}))},Qe=e=>{let{superBlock:t,challenges:l,accordion:a,moduleType:n,expandAll:r}=e;if(null==l||!l.length)return null;const s=null!=n?n:l[0].blockLabel;return c.createElement("li",{className:"link-block"},c.createElement(Ne,{block:l[0].block,blockLabel:s||null,challenges:l,superBlock:t,accordion:a,expandAll:r}))},Ze=e=>{let{challenges:t,superBlock:l,structure:a,chosenBlock:n,completedChallengeIds:r,expandAll:s=!1}=e;const i=a,m=i.chapters.flatMap(e=>{let{modules:t}=e;return t}),d=(()=>{const e=new Map;return i.chapters.forEach(t=>{t.modules.forEach(l=>{l.blocks.forEach(l=>{e.set(l,t.dashedName)})})}),e})(),u=(()=>{const e=new Map;return m.forEach(t=>{t.blocks.forEach(l=>{e.set(l,t.dashedName)})}),e})(),h=(0,c.useMemo)(()=>i.chapters.map(e=>({name:e.dashedName,comingSoon:e.comingSoon,modules:e.modules.map(e=>{return{name:e.dashedName,comingSoon:e.comingSoon,moduleType:e.moduleType,blocks:(l=e.blocks,l.map(e=>{var l,a;const n=t.filter(t=>{let{block:l}=t;return l===e});return{name:e,blockLabel:null!==(l=null===(a=n[0])||void 0===a?void 0:a.blockLabel)&&void 0!==l?l:null,challenges:n}}))};var l})})),[t,i.chapters]),p=d.get(n),g=u.get(n),E=!0,k=(0,o.wA)(),b=e=>{k((0,f.xf)({removedChallengeIds:e}))};return c.createElement("ul",{className:"super-block-accordion"},h.map(e=>{var t,a;const n=[];
1if(e.modules.forEach(e=>{const{blocks:t}=e;t.forEach(e=>n.push(...e.challenges.map(e=>e.id)))}),s&&0===n.length)return null;const i=new Set(n),o=new Set(r.filter(e=>i.has(e))).size,[d]=e.modules,[u]=null!==(t=null==d?void 0:d.blocks)&&void 0!==t?t:[],k=1===e.modules.length&&1===(null==d?void 0:d.blocks.length)&&(null==u?void 0:u.blockLabel)===Q.exam&&1===u.challenges.length,C=k?null==u||null===(a=u.challenges[0])||void 0===a?void 0:a.fields.slug:void 0,f=e.modules.flatMap(e=>e.blocks.map(e=>e.name));return c.createElement(Je,{key:e.name,dashedName:e.name,isExpanded:s||p===e.name||1===h.length,comingSoon:e.comingSoon,totalSteps:n.length,completedSteps:o,superBlock:l,isLinkChapter:k,examSlug:C,blockDashedNames:f,onResetComplete:b},e.modules.map(e=>{if(e.comingSoon&&!Ge&&e.moduleType===Q.review)return null;var t;if((e=>{const t=m.find(t=>t.dashedName===e);return(null==t?void 0:t.moduleType)===Q.review||(null==t?void 0:t.moduleType)===Q.exam||(null==t?void 0:t.moduleType)===Q.quiz||(null==t?void 0:t.moduleType)===Q.certProject})(e.name))return c.createElement(Qe,{key:e.name,superBlock:l,moduleType:e.moduleType,challenges:null===(t=e.blocks[0])||void 0===t?void 0:t.challenges,accordion:E,expandAll:s});const a=[];if(e.blocks.forEach(e=>a.push(...e.challenges.map(e=>e.id))),s&&0===a.length)return null;const n=new Set(a),i=new Set(r.filter(e=>n.has(e))).size,o=e.blocks.map(e=>e.name);return c.createElement(We,{key:e.name,dashedName:e.name,isExpanded:s||g===e.name,totalSteps:a.length,completedSteps:i,superBlock:l,comingSoon:!!e.comingSoon,blockDashedNames:o,onResetComplete:b},e.blocks.map(e=>c.createElement("li",{key:e.name},c.createElement(Ne,{block:e.name,blockLabel:e.blockLabel,challenges:e.challenges,superBlock:l,accordion:E,expandAll:s}))))}))}))};var Ue=l(60317),Ye=l(5037),Xe=function(){return Ye.A.Date.now()},et=l(30095),tt=Math.max,lt=Math.min;var at=function(e,t,l){var a,n,r,c,s,i,o=0,m=!1,d=!1,u=!0;if("function"!=typeof e)throw new TypeError("Expected a function");function h(t){var l=a,r=n;return a=n=void 0,o=t,c=e.apply(r,l)}function p(e){var l=e-i;return void 0===i||l>=t||l<0||d&&e-o>=r}function g(){var e=Xe();if(p(e))return E(e);s=setTimeout(g,function(e){var l=t-(e-i);return d?lt(l,r-(e-o)):l}(e))}function E(e){return s=void 0,u&&a?h(e):(a=n=void 0,c)}function k(){var e=Xe(),l=p(e);if(a=arguments,n=this,i=e,l){if(void 0===s)return function(e){return o=e,s=setTimeout(g,t),m?h(e):c}(i);if(d)return clearTimeout(s),s=setTimeout(g,t),h(i)}return void 0===s&&(s=setTimeout(g,t)),c}return t=(0,et.A)(t)||0,(0,Ue.A)(l)&&(m=!!l.leading,r=(d="maxWait"in l)?tt((0,et.A)(l.maxWait)||0,t):r,u="trailing"in l?!!l.trailing:u),k.cancel=function(){void 0!==s&&clearTimeout(s),o=0,a=i=n=s=void 0},k.flush=function(){return void 0===s?c:E(Xe())},k},nt=l(31255),rt=l(42109);const ct=e=>{let{onSearch:t,resultCount:l,isSearching:a}=e;const{t:n}=(0,i.Bd)(),[r,s]=(0,c.useState)(""),o=(0,c.useMemo)(()=>at(t,300),[t]),m=a?l>0?n("learn.search.search-challenges-results",{resultCount:l,term:r}):n("learn.search.search-challenges-no-results",{term:r}):"";return c.createElement("form",{className:"super-block-search-form",onSubmit:e=>e.preventDefault(),role:"search","aria-label":n("learn.search.search-challenges-in-curriculum")},c.createElement("div",{className:"super-block-search-container"},c.createElement("span",{"aria-hidden":"true",className:"super-block-search-magnifier"},c.createElement(nt.A,null)),c.createElement(h.MJ,{id:"super-block-search-input",type:"search","aria-label":n("learn.search.search-challenges-in-curriculum"),value:r,onChange:e=>{const t=e.target.value;s(t),o(t.trim().toLowerCase())},placeholder:n("learn.search.search-challenges-in-curriculum")}),r&&c.createElement("button",{className:"super-block-search-reset-btn",onClick:()=>{o.cancel(),s(""),t("")},type:"button"},c.createElement(rt.A,null))),c.createElement("p",{"aria-live":"polite",className:"super-block-search-status"},m))};ct.displayName="SuperBlockSearch";var st=ct;const it=e=>{let{disabledBlocks:t,showCertification:l,superBlock:a,superBlockChallenges:n,user:r,expandAll:s=!1}=e;const i=(0,c.useMemo)(()=>Array.from(new Set(n.map(e=>{let{block:t}=e;return t}))).filter(e=>!t.includes(e)),[t,n]);return c.createElement("div",{className:"block-ui"},i.map(e=>{var t,l;const r=n.filter(t=>t.block===e),i=null!==(t=null===(l=r[0])||void 0===l?void 0:l.blockLabel)&&void 0!==t?t:null;return r.length?c.createElement(Ne,{key:e,block:e,blockLabel:i,challenges:r,superBlock:a,expandAll:s}):null}),l&&!!r&&c.createElement(Se,{superBlock:a,user:r}))},ot=e=>{let{completedChallengeIds:t,disabledBlocks:l,initialExpandedBlock:a,showCertification:n,structure:r,superBlock:s,superBlockChallenges:o,user:m}=e;const{t:d}=(0,i.Bd)(),[u,p]=(0,c.useState)(""),E=u.length>0,k=(0,c.useMemo)(()=>E?o.filter(e=>{const t=e.title.toLowerCase(),l=d(`intro:${s}.blocks.${e.block}.title`).toLowerCase();return t.includes(u)||l.includes(u)}):o,[E,u,o,s,d]);if(g.EQ.includes(s)){if(!r)return null;const e=()=>{var e;const t=N.iy[s],l=N.dK;return(null!==(e=t&&l[t])&&void 0!==e?e:[]).map(e=>{const t=d(`intro:${e}.title`),l=`/learn/${e}/`,a=N.iy[e],n=a?N.w8[a]:void 0,r=Boolean(n&&(null==m?void 0:m[n]));return c.createElement("li",{className:"chapter requirement",key:e}
1,c.createElement(L.N_,{className:"chapter-button","data-playwright-test-label":"requirement-button",to:l},c.createElement("div",{className:"chapter-button-left"},c.createElement("span",{className:"checkmark-wrap chapter-checkmark-wrap"},c.createElement(K,{isCompleted:r})),c.createElement(z._,{className:"map-icon",superBlock:e}),t)))})};return c.createElement(c.Fragment,null,c.createElement(h.fI,null,c.createElement(h.fv,{md:8,mdOffset:2,sm:10,smOffset:1,xs:12},c.createElement(st,{onSearch:p,resultCount:k.length,isSearching:E}))),g.ad.includes(s)&&c.createElement(c.Fragment,null,c.createElement("ul",{className:"super-block-accordion requirement-list"},e()),c.createElement(h.hK,{size:"m"}),c.createElement("h2",{className:"text-center big-subheading"},d("intro:misc-text.courses")),c.createElement(h.hK,{size:"m"})),c.createElement(Ze,{challenges:k,superBlock:s,structure:r,chosenBlock:a,completedChallengeIds:t,expandAll:E}))}return c.createElement(c.Fragment,null,c.createElement(h.fI,null,c.createElement(h.fv,{sm:10,smOffset:1,xs:12},c.createElement(st,{onSearch:p,resultCount:k.length,isSearching:E}))),c.createElement(it,{disabledBlocks:l,showCertification:n,superBlock:s,superBlockChallenges:k,user:m,expandAll:E}))};ot.displayName="SuperBlockMap";var mt=ot;const dt=()=>{const e=window.location.hash.replace("#","");e&&m.XG.scrollTo(e,{smooth:!0,duration:500,offset:-50})},ut=e=>{var t;const{t:l}=(0,i.Bd)();(0,c.useEffect)(()=>($(),e.tryToShowDonationModal(),dt(),window.addEventListener("hashchange",dt),()=>window.removeEventListener("hashchange",dt)),[]);const o=(0,p.Br)("disabled_blocks",[]),{data:{allChallengeNode:{nodes:m},allSuperBlockStructure:d},isSignedIn:u,currentChallengeId:f,signInLoading:v,user:y,pageContext:{superBlock:x},location:S}=e,A=(0,c.useMemo)(()=>m.map(e=>{let{challenge:t}=e;return t}),[m]),L=(0,c.useMemo)(()=>A.filter(e=>e.superBlock===x),[A,x]),R=(0,c.useMemo)(()=>{var e;return(null!==(e=null==y?void 0:y.completedChallenges)&&void 0!==e?e:[]).filter(e=>L.some(t=>t.id===e.id))},[L,null==y?void 0:y.completedChallenges]),z=r.Ay.t(`intro:${x}.title`),F=d.nodes.find(e=>e.superBlock===x),T=w.Gb.some(e=>N.iy[x]===e.certSlug),M=()=>{var e;if(S.state&&"object"==typeof S.state&&Object.prototype.hasOwnProperty.call(S.state,"breadcrumbBlockClick"))return S.state.breadcrumbBlockClick;if(S.hash){return S.hash.replace("#","").replace("/","")}if(u){const e=L.find(e=>e.id===f);if(e)return e.block;if(!(0,n.A)(R)){var t;const e=null===(t=(0,a.A)(R))||void 0===t?void 0:t.id,l=L.find(t=>{let{id:l}=t;return l===e});if(l)return l.block}}const l=null===(e=L[0])||void 0===e?void 0:e.block;return null!=l?l:""},$=()=>{const{resetExpansion:t,toggleBlock:l}=e;return t(),l(M())},I=M(),j=0===R.length,P=(0,c.useMemo)(()=>{var e,t;if(j)return(null===(e=L[0])||void 0===e?void 0:e.fields.slug)||null;const l=R.reduce((e,t)=>null!=t&&t.completedDate&&(null==e||!e.completedDate||t.completedDate>e.completedDate)?t:e,null);return(null===(t=(()=>{var e;if(null==l||!l.id)return null;const t=L.findIndex(e=>{let{id:t}=e;return t===(null==l?void 0:l.id)});return-1===t?null:null!==(e=L[t+1])&&void 0!==e?e:null})())||void 0===t?void 0:t.fields.slug)||null},[R,L,j]);return c.createElement(c.Fragment,null,c.createElement(s.A,null,c.createElement("title",null,z," | freeCodeCamp.org")),c.createElement(h.mc,null,c.createElement("main",null,c.createElement(h.fI,{className:"super-block-intro-page"},c.createElement(h.fv,{md:8,mdOffset:2,sm:10,smOffset:1,xs:12},c.createElement(h.hK,{size:"l"}),c.createElement(B,{superBlock:x}),c.createElement(V,{superBlock:x,onCertificationDonationAlertClick:()=>{(0,E.A)({event:"donation_related",action:"Certification Donation Alert Click"})},isDonating:null!==(t=null==y?void 0:y.isDonating)&&void 0!==t&&t,hasNotstarted:j,nextChallengeSlug:P}),c.createElement(D,{superBlock:x}),c.createElement(h.hK,{size:"l"}),c.createElement("h2",{className:"text-center big-subheading"},g.ad.includes(x)?l("intro:misc-text.requirements"):l("intro:misc-text.courses")),c.createElement(h.hK,{size:"m"}),c.createElement(mt,{completedChallengeIds:R.map(e=>e.id),disabledBlocks:o,initialExpandedBlock:I,showCertification:T,structure:F,superBlock:x,superBlockChallenges:L,user:y}),!u&&!v&&c.createElement(c.Fragment,null,c.createElement(h.hK,{size:"l"}),c.createElement(b.A,{block:!0},l("buttons.logged-out-cta-btn"))),c.createElement(h.hK,{size:"l"}),c.createElement("h3",{className:"text-center big-block-title",style:{whiteSpace:"pre-line"}},l("intro:misc-text.browse-other")),c.createElement(h.hK,{size:"m"}),c.createElement(C.A,null),c.createElement(h.hK,{size:"l"}))))),c.createElement(k.A,{location:e.location}))};ut.displayName="SuperBlockIntroductionPage";var ht=(0,o.Ng)(e=>(0,u.Mz)(v.vw,v.$k,v.Ci,v.SR,v.dt,(e,t,l,a,n)=>({currentChallengeId:e,isSignedIn:t,signInLoading:l,fetchState:a,user:n}))(e),e=>(0,d.zH)({tryToShowDonationModal:f.RE,resetExpansion:J.Zs,toggleBlock:e=>(0,J.qj)(e)},e))((0,i.CI)()((0,c.memo)(ut)))},31255:function(e,t,l){"use strict";var a=l(7378),n=l(61550);const r=()=>{const{t:e}=(0,n.Bd)();return a.createElement(a.Fragment,null,a.createElement("span",{className:"sr-only"},e("icons.magnifier")),a.createElement("svg",{className:"ais-SearchBox-submitIcon",height:"10",viewBox:"0 0 40 40",width:"10",xmlns:"http://www.w3.org/2000/svg"},a.createElement("path",{d:"M26.804 29.01c-2.832 2.34-6.465 3.746-10.426 3.746C7.333 32.756 0 25.424 0 16.378 0 7.333 7.333 0 16.378 0c9.046 0 16.378 7.333 16.378 16.378 0 3.96-1.406 7.594-3.746 10.426l10.534 10.534c.607.607.61 1.59-.004 2.202-.61.61-1.597.61-2.202.004L26.804 29.01zm-10.426.627c7.323 0 13.26-5.936 13.26-13.26 0-7.32-5.937-13.257-13.26-13.257C9.056 3.12 3.12 9.056 3.12 16.378c0 7.323 5.936 13.26 13.258 13.26z"})))};r.displayName="Magnifier",t.A=r},41542:function(e,t,l){"use strict";l.d(t,{z:function(){return n}});var a=l(7378);function n(e){let{now:t}=e;return a.createElement(a.Fragment,null,a.createElement("div",{className:"progress-bar-background"}),a.createElement("div",{className:"progress-bar-percent","data-testid":"fcc-progress-bar-percent",style:{width:`${t}%`}}))}},42109:function(e,t,l){"use strict";var a=l(7378),n=l(61550);const r=()=>{const{t:e}=(0,n.Bd)();return a.createElement(a.Fragment,null,a.createElement("span",{className:"sr-only"},e("icons.input-reset")),a.createElement("svg",{className:"ais-SearchBox-resetIcon",height:"10",viewBox:"0 0 20 20",width:"10",xmlns:"http://www.w3.org/2000/svg"},a.createElement("path",{d:"M8.114 10L.944 2.83 0 1.885 1.886 0l.943.943L10 8.113l7.17-7.17.944-.943L20 1.886l-.943.943-7.17 7.17 7.17 7.17.943.944L18.114 20l-.943-.943-7.17-7.17-7.17 7.17-.944.943L0 18.114l.943-.943L8.113 10z"})))};r.displayName="InputReset",t.A=r},44944:function(e,t,l){"use strict";var a=l(7378);function n(e){return a.createElement("svg",Object.assign({xmlns:"http://www.w3.org/2000/svg",width:"60",height:"60",viewBox:"0 0 60 60",fill:"none","aria-hidden":"true"},e),a.createElement("path",{d:"M18.1176 7.11765C18.1176 11.0486 14.9309 14.2353 10.9999 14.2353C7.06896 14.2353 3.88228 11.
10486 3.88228 7.11765C3.88228 3.18668 7.06896 0 10.9999 0C14.9309 0 18.1176 3.18668 18.1176 7.11765Z",fill:"black"}),a.createElement("path",{d:"M48.9999 14.2353C52.9309 14.2353 56.1176 11.0486 56.1176 7.11765C56.1176 3.18668 52.9309 0 48.9999 0C45.069 0 41.8823 3.18668 41.8823 7.11765C41.8823 11.0486 45.069 14.2353 48.9999 14.2353Z",fill:"black"}),a.createElement("path",{d:"M13 47H0V21.3531C-1.63171e-05 17.8904 2.69272 15.6097 5 14C6.94118 15.4503 8.44322 16 10.9999 16C13.5566 16 15.0588 15.2941 17 14C17.857 14.5978 18.615 14.9334 19.4511 15.814C19.1576 16.8238 19 17.8932 19 19C19 21.574 19.8523 24.0831 21.2851 26.1359C17.7193 28.6696 13 33.1608 13 38.6113V47Z",fill:"black"}),a.createElement("path",{d:"M40.5488 15.814C41.385 14.9334 42.143 14.5979 43 14C44.9412 15.4503 46.4433 16 49 16C51.5567 16 53.0588 15.2941 55 14C57.3073 15.6097 60 17.8904 60 21.3531V47H47V38.6113C47 33.1608 42.2807 28.6696 38.7149 26.1359C40.1477 24.0831 41 21.574 41 19C41 17.8932 40.8424 16.8238 40.5488 15.814Z",fill:"black"}),a.createElement("path",{d:"M39.5 19.1851C39.5 24.8102 35.3604 29 29.9999 29C24.6395 29 21 24.8102 21 19.1851C21 13.56 24.6395 10 29.9999 10C35.3604 10 39.5 13.56 39.5 19.1851Z",fill:"black"}),a.createElement("path",{d:"M15 39.5558C15 34.6007 19.3537 30.3034 22.5 28C25.1471 30.0753 26.5135 31 29.9999 31C33.4863 31 35.3529 29.8518 38 28C41.1463 30.3034 45 34.6007 45 39.5558C45 54.3705 45 60 45 60H15C15 60 15.0001 55.2965 15 39.5558Z",fill:"black"}))}n.displayName="CommunityIcon",t.A=n},49686:function(e,t,l){var a=l(69791),n=l(9850),r=l(14727),c=l(77482),s=l(67349),i=l(8009),o=l(24478),m=l(78270),d=Object.prototype.hasOwnProperty;e.exports=function(e){if(null==e)return!0;if(s(e)&&(c(e)||"string"==typeof e||"function"==typeof e.splice||i(e)||m(e)||r(e)))return!e.length;var t=n(e);if("[object Map]"==t||"[object Set]"==t)return!e.size;if(o(e))return!a(e).length;for(var l in e)if(d.call(e,l))return!1;return!0}},55992:function(e,t,l){"use strict";l.d(t,{u:function(){return n}});var a=l(66681);const n=e=>{const{isA2EnglishCert:t,isB1EnglishCert:l,isRespWebDesignCert:n,isRespWebDesignCertV9:r,is2018DataVisCert:c,isFrontEndLibsCert:s,isFrontEndLibsCertV9:i,isJavascriptCertV9:o,isJsAlgoDataStructCert:m,isApisMicroservicesCert:d,isInfosecQaCert:u,isPythonCertV9:h,isQaCertV7:p,isInfosecCertV7:g,isFrontEndCert:E,isBackEndCert:k,isDataVisCert:b,isFullStackCert:C,isSciCompPyCertV7:f,isDataAnalysisPyCertV7:v,isMachineLearningPyCertV7:w,isRelationalDatabaseCertV8:N,isRelationalDatabaseCertV9:y,isCollegeAlgebraPyCertV8:x,isFoundationalCSharpCertV8:S,isJsAlgoDataStructCertV8:B}=e;return{hasModernCert:t||l||r||o||i||S||h||y,hasLegacyCert:E||m||k||b||u||n||c||s||d||p||g||C||f||v||w||N||x||B,isFullStackCert:C,currentCerts:[{show:t,title:"A2 English for Developers Certification (Beta)",certSlug:a.Rs.A2English},{show:l,title:"B1 English for Developers Certification (Beta)",certSlug:a.Rs.B1English},{show:r,title:"Responsive Web Design Certification",certSlug:a.Rs.RespWebDesignV9},{show:o,title:"JavaScript Certification",certSlug:a.Rs.JsV9},{show:i,title:"Front End Developer Libraries Certification",certSlug:a.Rs.FrontEndDevLibsV9},{show:S,title:"Foundational C# with Microsoft Certification",certSlug:a.Rs.FoundationalCSharp},{show:h,title:"Python Certification",certSlug:a.Rs.PythonV9},{show:y,title:"Relational Database Certification",certSlug:a.Rs.RelationalDbV9}],legacyCerts:[{show:n,title:"Legacy Responsive Web Design V8 Certification",certSlug:a.Rs.RespWebDesign},{show:B,title:"Legacy JavaScript Algorithms and Data Structures V8 Certification",certSlug:a.Rs.JsAlgoDataStructNew},{show:s,title:"Front-End Development Libraries V8 Certification",certSlug:a.Rs.FrontEndDevLibs},{show:c,title:"Data Visualization V8 Certification",certSlug:a.Rs.DataVis},{show:N,title:"Relational Database V8 Certification",certSlug:a.Rs.RelationalDb},{show:d,title:"Back-End Development and APIs V8 Certification",certSlug:a.Rs.BackEndDevApis},{show:p,title:"Quality Assurance Certification",certSlug:a.Rs.QualityAssurance},{show:f,title:"Scientific Computing with Python Certification",certSlug:a.Rs.SciCompPy},{show:v,title:"Data Analysis with Python Certification",certSlug:a.Rs.DataAnalysisPy},{show:g,title:"Information Security Certification",certSlug:a.Rs.InfoSec},{show:w,title:"Machine Learning with Python Certification",certSlug:a.Rs.MachineLearningPy},{show:x,title:"College Algebra with Python Certification",certSlug:a.Rs.CollegeAlgebraPy},{show:E,title:"Front-End Certification",certSlug:a.Rs.LegacyFrontEnd},{show:m,title:"Legacy JavaScript Algorithms and Data Structures V7 Certification",certSlug:a.Rs.JsAlgoDataStruct},{show:k,title:"Back-End Certification",certSlug:a.Rs.LegacyBackEnd},{show:b,title:"Data Visualization Certification",certSlug:a.Rs.LegacyDataVis},{show:u,title:"Information Security and Quality Assurance Certification",certSlug:a.Rs.LegacyInfoSecQa},{show:C,title:"Full-Stack Certification",certSlug:a.Rs.LegacyFullStack}]}}},75693:function(e,t,l){"use strict";l.d(t,{Y:function(){return o}});var a=l(7378),n=l(61550),r=l(99198),c=l(80765);const s=()=>{const{t:e}=(0,n.Bd)();return a.createElement(r.Pq,{variant:"caution",label:e("misc.caution")},a.createElement("p",null,a.createElement(n.x6,{i18nKey:"intro:misc-text.course-maintenance"},a.createElement("a",{href:"https://www.freecodecamp.org/news/how-to-run-freecodecamps-relational-databases-curriculum-using-docker-vscode-and-coderoad",rel:"noreferrer",target:"_blank"},"placeholder"))),a.createElement(r.hK,{size:"xs"}
1),a.createElement("p",null,e("intro:misc-text.progress-wont-save")))},i=()=>{const{t:e}=(0,n.Bd)();return a.createElement(r.Pq,{variant:"caution",label:e("misc.caution")},a.createElement("p",null,a.createElement(n.x6,{i18nKey:"intro:misc-text.course-disabled"},a.createElement("a",{href:"https://www.freecodecamp.org/news/how-to-run-freecodecamps-relational-databases-curriculum-using-docker-vscode-and-coderoad",rel:"noreferrer",target:"_blank"},"placeholder"))),a.createElement(r.hK,{size:"xs"}),a.createElement("p",null,e("intro:misc-text.progress-wont-save")))};function o(){const e=(0,c.iT)("codeally_down");return(0,c.iT)("codeally_disabled").on?a.createElement(i,null):e.on?a.createElement(s,null):null}},85351:function(e,t,l){"use strict";var a=l(7378);function n(e){return a.createElement("svg",Object.assign({xmlns:"http://www.w3.org/2000/svg",width:"61",height:"60",viewBox:"0 0 61 60",fill:"none","aria-hidden":"true"},e),a.createElement("path",{d:"M10.1154 48.7552L10.1154 30.7553L28.1154 42.7553L47.1154 30.7553L47.1154 48.7552C47.1154 48.7552 39.854 59.7899 28.1154 59.7553C16.3769 59.7206 10.1154 48.7552 10.1154 48.7552Z",fill:"black"}),a.createElement("path",{d:"M53.0108 46.5927L60.0108 46.5927L57.1154 36.5926L57.1154 20.6612L28.1574 0.0826199L0.115235 20.6612L28.1154 38.7553L56.0108 21.3504L56.0108 36.5926L53.0108 46.5927Z",fill:"black"}))}n.displayName="CapIcon",t.A=n},86048:function(e,t,l){"use strict";var a=l(7378);function n(){return a.createElement("svg",{"aria-hidden":"true",xmlns:"http://www.w3.org/2000/svg",width:"10",height:"10",viewBox:"0 0 389 254",fill:"none",className:"dropdown-icon"},a.createElement("path",{d:"M194.5 0L388.5 254H307.5L194.5 99L78.5 254H0.5L194.5 0Z",style:{stroke:"var(--primary-color)",fill:"var(--primary-color)",strokeWidth:"1px"}}))}n.displayName="DropDown",t.A=n},90362:function(e,t,l){"use strict";var a=l(7378),n=l(61550);function r(e){const{t:t}=(0,n.Bd)(),{hushScreenReaderText:l=!1,...r}=e;return a.createElement(a.Fragment,null,!l&&a.createElement("span",{className:"sr-only"},t("icons.not-passed")),a.createElement("svg",Object.assign({"data-testid":"green-not-completed","aria-hidden":"true",height:"15",viewBox:"0 0 200 200",width:"15",xmlns:"http://www.w3.org/2000/svg"},r),a.createElement("g",null,a.createElement("title",null,t("icons.not-passed")),a.createElement("circle",{cx:"100",cy:"99",fill:"var(--primary-background)",r:"95",stroke:"var(--primary-color)",strokeDasharray:"null",strokeWidth:"10"}))))}r.displayName="GreenNotCompleted",t.A=r}}]);
2//# sourceMappingURL=component---src-templates-introduction-super-block-intro-tsx-6802d23e993e0c7e3d54.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.