1(self.webpackChunk_N_E=self.webpackChunk_N_E||[]).push([[7177],{13673:()=>{},59676:(e,t,a)=>{"use strict";a.d(t,{default:()=>s});var r=a(12115),l=a(20063);function s(){let e=(0,l.usePathname)();return(0,r.useEffect)(()=>{let t="/zh-Hans"===e||e.startsWith("/zh-Hans/");document.documentElement.lang=t?"zh-Hans":"en"},[e]),null}},63479:(e,t,a)=>{"use strict";a.d(t,{ThemeProvider:()=>s});var r=a(95155);a(12115);var l=a(5379);function s(e){let{children:t,...a}=e;return(0,r.jsx)(l.N,{...a,children:t})}},64269:(e,t,a)=>{"use strict";a.d(t,{cn:()=>s});var r=a(2821),l=a(75889);function s(){for(var e=arguments.length,t=Array(e),a=0;a<e;a++)t[a]=arguments[a];return(0,l.QP)((0,r.$)(t))}},72341:(e,t,a)=>{"use strict";a.d(t,{TopNav:()=>b});var r=a(95155),l=a(12115),s=a(52619),n=a.n(s),o=a(20063),c=a(9540),i=a(24033),d=a(86651),h=a(65229),u=a(72558),g=a(64269);function m(e){return e.replace(/\/+$/,"")||"/"}let f=(()=>{let e=new Map;for(let t of u.L)for(let a of(e.set(m("/".concat(t.id,"/")),t.id),t.calculators))a.live&&e.set(m(a.href),t.id);return e})(),x=u.L.flatMap(e=>e.calculators.filter(e=>e.live).map(t=>({name:t.name,href:t.href,categoryLabel:e.label})));function b(){let e=(0,o.usePathname)(),t=(0,o.useRouter)(),[a,s]=l.useState(!1),[h,u]=l.useState(!1),[b,p]=l.useState(""),y=l.useMemo(()=>{var t;return null!=(t=f.get(m(e)))?t:null},[e]);l.useEffect(()=>{s(!1),u(!1)},[e]),l.useEffect(()=>{if(!h)return;let e=document.documentElement,t=document.body,a=e.style.overflow,r=t.style.overflow;return e.style.overflow="hidden",t.style.overflow="hidden",()=>{e.style.overflow=a,t.style.overflow=r}},[h]),l.useEffect(()=>{function e(e){if("Escape"===e.key){if(h)return void u(!1);a&&s(!1)}}return document.addEventListener("keydown",e),()=>document.removeEventListener("keydown",e)},[h,a]);let N=l.useMemo(()=>{let e=b.trim().toLowerCase();return e?x.filter(t=>t.name.toLowerCase().includes(e)).slice(0,12):[]},[b]),C=l.useRef(null);function A(){p(""),u(!1)}l.useEffect(()=>{if(a)return document.addEventListener("mousedown",e),()=>document.removeEventListener("mousedown",e);function e(e){C.current&&!C.current.contains(e.target)&&s(!1)}},[a]);let L=null!==y;return(0,r.jsxs)(r.Fragment,{children:[(0,r.jsx)("nav",{ref:C,"aria-label":"Primary",className:"sticky top-0 z-40 h-14 border-b border-slate-200 bg-slate-50 dark:border-slate-800 dark:bg-slate-900",children:(0,r.jsxs)("div",{className:"mx-auto flex h-full max-w-7xl items-center gap-2 px-3 sm:px-6",children:[(0,r.jsx)("button",{type:"button",onClick:()=>u(!0),"aria-label":"Open navigation menu","aria-expanded":h,"aria-controls":"mobile-nav-drawer",className:"inline-flex size-11 items-center justify-center rounded-md text-slate-700 hover:bg-slate-100 dark:text-slate-300 dark:hover:bg-slate-800 md:hidden",children:(0,r.jsx)(c.A,{className:"size-5"})}),(0,r.jsx)(n(),{href:"/",className:"text-lg font-black tracking-tighter text-slate-900 hover:text-teal-700 dark:text-slate-100 dark:hover:text-teal-400",children:"InfantChart"}),(0,r.jsxs)("div",{className:"relative ml-4 hidden md:block",children:[(0,r.jsxs)("button",{type:"button","aria-haspopup":"menu","aria-expanded":a,"aria-controls":"topnav-megamenu",onClick:()=>s(e=>!e),className:(0,g.cn)("inline-flex h-10 items-center gap-1 rounded-md px-3 text-sm font-medium transition-colors",L?"bg-teal-50 text-teal-700 dark:bg-teal-950/30 dark:text-teal-400":"text-slate-700 hover:bg-slate-100 hover:text-slate-900 dark:text-slate-300 dark:hover:bg-slate-800 dark:hover:text-slate-100"),children:["Calculators",(0,r.jsx)(i.A,{className:(0,g.cn)("size-4 transition-transform",a&&"rotate-180")})]}),a&&(0,r.jsx)(v,{activeCategoryId:y,pathname:e,onSelect:()=>s(!1)})]}),(0,r.jsx)("div",{className:"flex-1"}),(0,r.jsxs)("form",{role:"search",onSubmit:function(e){e.preventDefault(),0!==N.length&&(t.push(N[0].href),A())},className:"relative hidden md:block",children:[(0,r.jsx)(k,{value:b,onChange:p,variant:"desktop"}),b.trim()&&(0,r.jsx)(w,{results:N,onPick:A})]}),(0,r.jsx)("button",{type:"button",onClick:()=>u(!0),"aria-label":"Open search",className:"inline-flex size-11 items-center justify-center rounded-md text-slate-700 hover:bg-slate-100 dar
1k:text-slate-300 dark:hover:bg-slate-800 md:hidden",children:(0,r.jsx)(d.A,{className:"size-5"})})]})}),(0,r.jsx)(j,{open:h,onClose:()=>u(!1),searchQuery:b,onSearchChange:p,searchResults:N,activeCategoryId:y,pathname:e,onResultClick:A})]})}let p=[{href:"/growth-calculator/",label:"Growth Dashboard",description:"All-in-one growth percentile dashboard."},{href:"/which-chart/",label:"Which Chart?",description:"Which growth chart should I use?"}];function v(e){let{activeCategoryId:t,pathname:a,onSelect:l}=e;return(0,r.jsxs)("div",{id:"topnav-megamenu",role:"menu",className:"fixed left-4 right-4 top-14 z-50 mt-1 max-h-[calc(100vh-5rem)] overflow-y-auto rounded-md border border-slate-200 bg-white p-6 shadow-lg dark:border-slate-700 dark:bg-slate-900 lg:left-1/2 lg:right-auto lg:w-[min(calc(100vw-3rem),56rem)] lg:-translate-x-1/2",children:[(0,r.jsxs)("section",{"aria-labelledby":"megamenu-start-here",className:"mb-6 border-b border-slate-200 pb-6 dark:border-slate-700",children:[(0,r.jsx)("h3",{id:"megamenu-start-here",className:"mb-2 text-xs font-semibold uppercase tracking-wider text-slate-500 dark:text-slate-400",children:"Start Here"}),(0,r.jsx)("ul",{className:"grid grid-cols-1 gap-1 sm:grid-cols-2",children:p.map(e=>{let t=a===e.href;return(0,r.jsx)("li",{children:(0,r.jsxs)(n(),{role:"menuitem",href:e.href,onClick:l,className:(0,g.cn)("block rounded-md px-3 py-2 text-sm hover:bg-teal-50 dark:hover:bg-teal-950/30",t?"bg-teal-50 text-teal-700 dark:bg-teal-950/30 dark:text-teal-400":"text-slate-700 hover:text-teal-700 dark:text-slate-200 dark:hover:text-teal-400"),children:[(0,r.jsx)("span",{className:"block font-semibold",children:e.label}),(0,r.jsx)("span",{className:"block text-xs text-muted-foreground",children:e.description})]})},e.href)})})]}),(0,r.jsx)("div",{className:"grid grid-cols-1 gap-x-8 gap-y-6 sm:grid-cols-2 lg:grid-cols-3",children:u.L.map(e=>{let a=e.id===t;return(0,r.jsxs)("section",{"aria-labelledby":"megamenu-".concat(e.id,"-heading"),children:[(0,r.jsx)("h3",{id:"megamenu-".concat(e.id,"-heading"),className:(0,g.cn)("mb-2 text-xs font-semibold uppercase tracking-wider",a?"text-teal-700 dark:text-teal-400":"text-slate-500 dark:text-slate-400"),children:e.label}),(0,r.jsxs)("ul",{className:"space-y-0.5",children:[e.calculators.filter(e=>e.live).map(e=>(0,r.jsx)("li",{children:(0,r.jsx)(n(),{role:"menuitem",href:e.href,onClick:l,className:"block rounded-md px-2 py-1.5 text-sm text-slate-700 hover:bg-teal-50 hover:text-teal-700 dark:text-slate-200 dark:hover:bg-teal-950/30 dark:hover:text-teal-400",children:e.name.replace(" Calculator","")})},e.href)),(0,r.jsx)("li",{children:(0,r.jsxs)(n(),{role:"menuitem",href:"/".concat(e.id,"/"),onClick:l,className:"block rounded-md px-2 py-1.5 text-sm font-medium text-teal-700 hover:bg-teal-50 dark:text-teal-400 dark:hover:bg-teal-950/30",children:["View all ",e.label," â"]})})]})]},e.id)})})]})}function k(e){let{value:t,onChange:a,variant:s}=e,n=l.useRef(null),o=()=>{var e;a(""),null==(e=n.current)||e.focus()};return(0,r.jsxs)("div",{className:"relative",children:[(0,r.jsx)(d.A,{className:"pointer-events-none absolute left-3 top-1/2 size-4 -translate-y-1/2 text-muted-foreground"}),(0,r.jsx)("input",{ref:n,type:"text","aria-label":"Search calculators",placeholder:"Search calculators...",value:t,onChange:e=>a(e.target.value),onKeyDown:e=>{"Escape"===e.key&&t&&(e.stopPropagation(),o())},className:(0,g.cn)("w-full rounded-md border border-slate-300 bg-background py-1.5 pl-9 pr-10 text-sm placeholder:text-muted-foreground focus:outline-none focus:ring-2 focus:ring-teal-600 dark:border-slate-700","desktop"===s?"min-w-[16rem]":"min-w-0")}),t&&(0,r.jsx)("button",{type:"button",onClick:o,"aria-label":"Clear search",className:"absolute right-1.5 top-1/2 inline-flex size-7 -translate-y-1/2 items-center justify-center rounded-md text-muted-foreground hover:bg-slate-100 dark:hover:bg-slate-800",children:(0,r.jsx)(h.A,{className:"size-4"})})]})}function w(e){let{results:t,onPick:a}=e;return(0,r.jsx)("div",{className:"absolute right-0 top-full z-50 mt-1 max-h-96 w-80 overflow-y-auto rounded-md border border-slate-200 bg-white py-1 shadow-lg dark:border-slate-700 dark:bg-slate-900",children:0===t.length?(0,r.jsx)("p",{className:"px-4 py-2 text-sm text-muted-foreground",children:"No matches"}):t.map(e=>(0,r.jsxs)(n(),{href:e.href,onClick:a,className:"block px-4 py-2 text-sm text-slate-700 hover:bg-teal-50 dark:text-slate-200 dark:hover:bg-teal-950/30",children:[(0,r.jsx)("span",{className:"block",children:e.name.replace(" Calculator","")}),(0,r.jsx)("span",{className:"block text-xs text-muted-foreground",children:e.categoryLabel})]},e.href))})}function j(e){let{open:t,onClose:a,searchQuery:s,onSearchChange:n,searchResults:o,activeCategoryId:c,pathname:i,onResultClick:d}=e,u=l.useRef(null),g=l.useRef(null);return(l.useEffect(()=>{var e;t&&(null==(e=u.current)||e.focus())},[t]),l.useEffect(()=>{if(t)return document.addEventListener("keydown",e),()=>document.removeEventListener("keydown",e);function e(e){if("Tab"!==e.key)return;let t=g.current;if(!t)return;let a=t.querySelectorAll('a[href], button:not([disabled]), input:not([disabled]), select:not([disabled]), textarea:not([disabled]), [tabindex]:not
1([tabindex="-1"])');if(0===a.length)return;let r=a[0],l=a[a.length-1],s=document.activeElement;e.shiftKey?s!==r&&t.contains(s)||(e.preventDefault(),l.focus()):s!==l&&t.contains(s)||(e.preventDefault(),r.focus())}},[t]),t)?(0,r.jsxs)("div",{className:"fixed inset-0 z-50 md:hidden",role:"dialog","aria-modal":"true","aria-label":"Site navigation",children:[(0,r.jsx)("button",{type:"button","aria-label":"Close navigation menu",onClick:a,className:"absolute inset-0 bg-slate-900/40 backdrop-blur-sm",tabIndex:-1}),(0,r.jsxs)("div",{ref:g,id:"mobile-nav-drawer",className:"absolute left-0 top-0 flex h-full w-full max-w-sm flex-col bg-background shadow-xl",children:[(0,r.jsxs)("div",{className:"flex h-14 items-center gap-2 border-b border-slate-200 px-3 dark:border-slate-800",children:[(0,r.jsx)("button",{ref:u,type:"button",onClick:a,"aria-label":"Close navigation menu",className:"inline-flex size-11 items-center justify-center rounded-md text-slate-700 hover:bg-slate-100 dark:text-slate-300 dark:hover:bg-slate-800",children:(0,r.jsx)(h.A,{className:"size-5"})}),(0,r.jsx)("span",{className:"text-lg font-black tracking-tighter text-slate-900 dark:text-slate-100",children:"InfantChart"})]}),(0,r.jsx)("div",{className:"px-3 py-3",children:(0,r.jsx)(k,{value:s,onChange:n,variant:"drawer"})}),(0,r.jsx)("div",{className:"flex-1 overflow-y-auto overscroll-contain px-3 pb-6",children:s.trim()?(0,r.jsx)(y,{results:o,onPick:d}):(0,r.jsx)(N,{activeCategoryId:c,pathname:i,onSelect:a})})]})]}):null}function y(e){let{results:t,onPick:a}=e;return 0===t.length?(0,r.jsx)("p",{className:"px-2 py-4 text-base text-muted-foreground",children:"No matches"}):(0,r.jsx)("ul",{className:"space-y-1",children:t.map(e=>(0,r.jsx)("li",{children:(0,r.jsxs)(n(),{href:e.href,onClick:a,className:"block rounded-md px-3 py-3 hover:bg-teal-50 dark:hover:bg-teal-950/30",children:[(0,r.jsx)("span",{className:"block text-base text-slate-700 dark:text-slate-200",children:e.name.replace(" Calculator","")}),(0,r.jsx)("span",{className:"block text-xs text-muted-foreground",children:e.categoryLabel})]})},e.href))})}function N(e){let{activeCategoryId:t,pathname:a,onSelect:s}=e,[o,c]=l.useState(t);return(0,r.jsxs)("div",{className:"space-y-1",children:[(0,r.jsxs)("section",{"aria-labelledby":"drawer-start-here",className:"mb-3 border-b border-slate-200 pb-3 dark:border-slate-800",children:[(0,r.jsx)("h2",{id:"drawer-start-here",className:"px-3 pb-2 pt-1 text-xs font-semibold uppercase tracking-wider text-slate-500 dark:text-slate-400",children:"Start Here"}),(0,r.jsx)("ul",{className:"space-y-0.5",children:p.map(e=>{let t=a===e.href;return(0,r.jsx)("li",{children:(0,r.jsxs)(n(),{href:e.href,onClick:s,className:(0,g.cn)("block rounded-md px-3 py-3 text-base hover:bg-teal-50 dark:hover:bg-teal-950/30",t?"bg-teal-50 text-teal-700 dark:bg-teal-950/30 dark:text-teal-400":"text-slate-700 dark:text-slate-200"),children:[(0,r.jsx)("span",{className:"block font-semibold",children:e.label}),(0,r.jsx)("span",{className:"block text-xs text-muted-foreground",children:e.description})]})},e.href)})})]}),u.L.map(e=>{let a=e.id===t,l=e.id===o,d="drawer-cat-".concat(e.id,"-list");return(0,r.jsxs)("section",{children:[(0,r.jsxs)("button",{type:"button",onClick:()=>c(l?null:e.id),"aria-expanded":l,"aria-controls":d,className:(0,g.cn)("flex w-full items-center justify-between rounded-md border-l-4 py-3 pl-2 pr-3 text-left text-sm font-semibold uppercase tracking-wider hover:bg-teal-50 dark:hover:bg-teal-950/30",a?"border-teal-600 text-teal-700 dark:text-teal-400":"border-transparent text-slate-600 hover:text-slate-900 dark:text-slate-400 dark:hover:text-slate-100"),children:[(0,r.jsx)("span",{children:e.label}),(0,r.jsx)(i.A,{className:(0,g.cn)("size-4 transition-transform",l&&"rotate-180")})]}),l&&(0,r.jsxs)("ul",{id:d,className:"space-y-0.5 pl-4 pt-1",children:[e.calculators.filter(e=>e.live).map(e=>(0,r.jsx)("li",{children:(0,r.jsx)(n(),{href:e.href,onClick:s,className:"block rounded-md px-3 py-3 text-base text-slate-700 hover:bg-teal-50 dark:text-slate-200 dark:hover:bg-teal-950/30",children:e.name.replace(" Calculator","")})},e.href)),(0,r.jsx)("li",{children:(0,r.jsxs)(n(),{href:"/".concat(e.id,"/"),onClick:s,className:"block rounded-md px-3 py-3 text-base font-medium text-teal-700 hover:bg-teal-50 dark:text-teal-400 dark:hover:bg-teal-950/30",children:["View all ",e.label," â"]})})]})]},e.id)})]})}},72558:(e,t,a)=>{"use strict";a.d(t,{L:()=>l});let r=(e,t)=>({name:e,href:t,live:!0}),l=[{id:"who-0-24",label:"WHO (0-24 Months)",calculators:[r("Weight-for-Age","/weight-for-age"),r("Length-for-Age","/length-for-age"),r("Head Circumference-for-Age","/head-circumference-for-age"),r("Weight-for-Length","/weight-for-length")]},{id:"who-0-5",label:"WHO (0-5 Years)",calculators:[r("Weight-for-Age (0-5)","/who-0-5-weight-for-age"),r("Head Circ-for-Age (0-5)","/who-0-5-head-circumference-for-age"),r("Stature-for-Age (2-5)","/who-2-5-stature-for-age"),r("Weight-for-Height (2-5)","/who-2-5-weight-for-height")]},{id:"who-5-19",label:"WHO (5-19 Years)",calculators:[r("Height-for-Age (5-19)","/who-5-19-height-for-age"),r("BMI-for-Age (5-19)","/who-5-19-bmi-for-age"),r("Weight-for-Age (5-10)","/who-5-19-weight-for-age")]},{id:"cdc-0-3",label:"CDC (0-36 Months)",calculators:[r("Weight-for-Age (CDC)","/cdc-weight-for-age"),r("Length-for-Age (CDC)","/cdc-length-for-age"),r("Head Circ-for-Age (CDC)","/cdc-head-circumference-for-age"),r("Weight-for-Length (CDC)","/cdc-weight-for-length")]},{id:"cdc-2-20",label:"CDC (2-20 Years)",calculators:[r("Weight-for-Age (2-20)","/cdc-2-20-weight-for-age"),r("Stature-for-Age (2-20)","/cdc-2-20-stature-for-age"),r("Weight-for-Stature (2-20)","/cdc-2-20-weight-for-stature"),r("Extended BMI-for-Age (2-20)","/cdc-extended-bmi")]},{id:"chinese",label:"Chinese National",calculators:[r("Weight-for-Age (0-18)","/chinese-weight-for-age"),r("Length-for-Age (0-3)","/chinese-length-for-age"),r("Stature-for-Age (3-18)","/chinese-stature-for-age"),r("Head Circ-for-Age (0-6)","/chinese-head-circumference-for-age"),r("Weight-for-Length","/chinese-weight-for-length"),r("Weight-for-Stature","/chinese-weight-for-stature")]},{id:"down-syndrome",label:"Down Syndrome / Zemel",calculators:[r("Weight-for-Age (0-36mo)","/ds-weight-for-age"),r("Length-for-Age (1-36mo)","/ds-length-for-age"),r("Head Circ-for-Age (1-36mo)","/ds-head-circumference-for-age"),r("Weight-for-Length","/ds-weight-for-length"),r("Height-for-Age (2-20yr)","/ds-height-for-age"),r("BMI-for-Age (2-20yr)","/ds-bmi-for-age")]},{id:"olsen",label:"Preterm / Olsen",calculators:[r("Weight-for-Gest. Age","/olsen-weight-for-age"),r("Length-for-Age","/olsen-length-for-age"),r("Head Circ-for-Age","/olsen-head-circumference-for-age")]},{id:"other",label:"Other Tools",calculators:[r("Growth Dashboard","/growth-calculator"),r("Height Predictor","/height-predictor"),r("Which Chart to Use?","/which-chart")]}
1,{id:"pregnancy-fertility",label:"Pregnancy & Fertility",calculators:[r("Ovulation Calculator","/ovulation-calculator"),r("Pregnancy Weight Gain Calculator","/pregnancy-weight-gain-calculator"),r("Pregnancy Calorie Calculator","/pregnancy-calorie-calculator")]}];l.reduce((e,t)=>e+t.calculators.length,0)},75606:(e,t,a)=>{Promise.resolve().then(a.t.bind(a,52619,23)),Promise.resolve().then(a.t.bind(a,41402,23)),Promise.resolve().then(a.t.bind(a,13673,23)),Promise.resolve().then(a.t.bind(a,86432,23)),Promise.resolve().then(a.bind(a,59676)),Promise.resolve().then(a.bind(a,63479)),Promise.resolve().then(a.bind(a,72341))}},e=>{e.O(0,[1439,2619,5720,5654,8441,1255,7358],()=>e(e.s=75606)),_N_E=e.O()}]);
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.