1import{a as c,j as e}from"./vendor-react-CIe7BBPp.js";import y from"./Levels-uvmXgaPU.js";import{P as i}from"./vendor-prop-types-DNxwfY3H.js";import Y from"./ChooseSubject-B0LbpzHF.js";import"./images-DsoEKV9h.js";const E=()=>{const[o,a]=c.useState(1);return e.jsxs(e.Fragment,{children:[o==1&&e.jsx("div",{className:"numberOFquestion",children:e.jsx("div",{className:"container",children:e.jsx("div",{className:"row",children:e.jsxs("div",{className:"col-md-12",children:[e.jsx("div",{className:"selectPicker",children:e.jsx("h1",{children:"Select number of questions"})}),e.jsx("div",{className:"numberPicker",children:e.jsx(j,{value:32,unit:"IN",increment:10,zeroPadded:!1})}),e.jsxs("div",{className:"buttonGroup",children:[e.jsx("button",{className:"btn back",onClick:()=>a(2),children:"Back"}),e.jsx("button",{className:"btn",onClick:()=>a(2),children:"Next"})]})]})})})}),o==2&&e.jsx(y,{setFormstate:a}),o==3&&e.jsx(Y,{setFormstate:a})]})},j=({id:o="spinner_01",value:a=32,unit:C="IN",increment:x=10,zeroPadded:b=!1})=>{const l=c.useRef(null),s=c.useMemo(()=>{const t=[];for(let n=10;n<=100;n+=x)t.push(n);return t},[x]),N=c.useMemo(()=>s.reduce((n,r)=>Math.abs(r-a)<Math.abs(n-a)?r:n,s[0]),[a,s]),[m,g]=c.useState(N),h=c.useMemo(()=>s.findIndex(t=>t===m),[s,m]),v=c.useMemo(()=>{const u=105-h*50,d=105,T=105-(s.length-1)*50;return Math.max(T,Math.min(d,u))},[h,s.length]),S=()=>s.map(t=>{const n=b?String(t).padStart(3,"0"):t;return e.jsx("li",{className:m===t?"highlighted":"",children:e.jsx("span",{children:n})},t)}),p=t=>{const n=Math.min(Math.max(h+t,0),s.length-1);g(s[n])},f=t=>{p(t==="up"?-1:1)},M=t=>{t.preventDefault(),p(t.deltaY>0?1:-1)},w=t=>{var n,r;l.current=((r=(n=t.touches)==null?void 0:n[0])==null?void 0:r.clientY)??null},k=t=>{var u,d;const n=(d=(u=t.changedTouches)==null?void 0:u[0])==null?void 0:d.clientY;if(l.current==null||typeof n!="number")return;const r=l.current-n;Math.abs(r)<20||(p(r>0?1:-1),l.current=null)};return e.jsxs("div",{id:o,className:"spinner rounded",onWheel:M,onTouchStart:w,onTouchEnd:k,children:[e.jsx("div",{className:"spinner_inner",children:e.jsx("ul",{style:{transform:`translateY(${v}px)`,transition:"transform 220ms ease"},children:S()})}),e.jsx("button",{type:"button",className:"tap_area value_up",onClick:()=>f("up"),children:e.jsx("div",{className:"arrow up"})}),e.jsx("button",{type:"button",className:"tap_area value_down",onClick:()=>f("down"),children:e.jsx("div",{className:"arrow down"})})]})};j.propTypes={id:i.string,value:i.number,unit:i.string,increment:i.number,zeroPadded:i.bool};export{E as default};
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.