1!function(){try{var e="undefined"!=typeof window?window:"undefined"!=typeof global?global:"undefined"!=typeof globalThis?globalThis:"undefined"!=typeof self?self:{};e.SENTRY_RELEASE={id:"a91c9d7d448087ad24daa8e772956123242ac00b"};var t=(new e.Error).stack;t&&(e._sentryDebugIds=e._sentryDebugIds||{},e._sentryDebugIds[t]="640dc578-794a-4ab6-86a1-b70be0b3c494",e._sentryDebugIdIdentifier="sentry-dbid-640dc578-794a-4ab6-86a1-b70be0b3c494")}catch(e){}}(),(this.__LOADABLE_LOADED_CHUNKS__=this.__LOADABLE_LOADED_CHUNKS__||[]).push([[2334],{12102(e,t,n){n.d(t,{NF:()=>u,Q8:()=>i,oB:()=>h,oF:()=>c});var r=n(73021),a=n(16288),o=n.n(a),s=n(37783);const l={OUTRO_MIX:"OUTRO"},i=e=>new Set(e.map(e=>{var t;return null!==(t=e.trackIndex)&&void 0!==t?t:0})).size>1,c=e=>e.reduce((e,t)=>{var n,r;const a=null!==(n=t.trackIndex)&&void 0!==n?n:0;return e[a]=(null!==(r=e[a])&&void 0!==r?r:0)+1,e},{}),u=e=>e&&l[e.toUpperCase()]||e,d=["DRUMS","PERCS","HATS","CLAPS","BASS","MIDS","LEADS","FX","VOCALS","PADS","RISER","IMPACT"],p=e=>{const t={};((null===e||void 0===e?void 0:e.samples)||[]).forEach(e=>{t[String(e.id)]=e});let n=0;return Object.values((null===e||void 0===e?void 0:e.score)||{}).forEach(e=>{Array.isArray(e)?e.forEach(e=>{const r=t[String(e)];r&&(n=Math.max(n,r.length))}):Object.entries(e||{}).forEach(e=>{let[r,a]=e;const o=t[String(a)];o&&(n=Math.max(n,parseInt(r,10)+o.length))})}),n||16},S=new Map,h=function(e){let t=!(arguments.length>1&&void 0!==arguments[1])||arguments[1];const[n,a]=(0,r.useState)(null),[l,i]=(0,r.useState)(!1);return(0,r.useEffect)(()=>{if(!e||!t)return a(null),void i(!1);const n=S.get(e);if(n)return a(n),void i(!1);i(!0),a(null);let r,l=!1;const c=Date.now(),u=()=>{const e=Date.now()-c;e>=s.jF?i(!1):r=setTimeout(h,(0,s.le)(e))},h=()=>{o().get("/api/v1/public/tracks/".concat(encodeURIComponent(e),"/structure"),{timeout:s.js}).then(t=>{var n,r,o,s;if(l)return;const c=null===(n=t.data)||void 0===n?void 0:n.data;if(null===c||void 0===c||null===(r=c.packs)||void 0===r||!r.length)return void u();const h=c.packs.map(e=>({name:String(e.part||""),bars:p(e),trackIndex:Number(e.track_index)||0})),v=h.reduce((e,t)=>e+t.bars,0),m=[];let g=0;c.packs.forEach((e,t)=>{m.push(...((e,t,n)=>{const r={};((null===e||void 0===e?void 0:e.samples)||[]).forEach(e=>{r[String(e.id)]=e});const a=[],o=(e,o)=>{const s=r[String(e)];null!==s&&void 0!==s&&s.instrument&&a.push({instrument:s.instrument,sampleId:Number(e),startBar:n+o,bars:s.length||1,partIndex:t})};return Object.values((null===e||void 0===e?void 0:e.score)||{}).forEach(e=>{Array.isArray(e)?e.forEach(e=>o(e,0)):Object.entries(e||{}).forEach(e=>{let[t,n]=e;return o(n,parseInt(t,10))})}),a})(e,t,g)),g+=h[t].bars});const f=new Set;c.packs.forEach(e=>(e.samples||[]).forEach(e=>(null===e||void 0===e?void 0:e.instrument)&&f.add(e.instrument)));const b=[...d.filter(e=>f.has(e)),...[...f].filter(e=>!d.includes(e))],D={parts:h,totalBars:v,bpm:(null===(o=c.packs[0])||void 0===o?void 0:o.bpm)||0,genre:String((null===(s=c.packs[0])||void 0===s?void 0:s.genre)||""),instruments:b,blocks:m};S.set(e,D),a(D),i(!1)}).catch(()=>{l||u()})};return h(),()=>{l=!0,r&&clearTimeout(r)}},[e,t]),{structure:n,pending:l}}},41377(e,t,n){n.d(t,{$:()=>r});const r=e=>!(null===e||void 0===e||!e.key)},47652(e,t,n){n.d(t,{wQ:()=>h,a3:()=>u,VL:()=>i});var r=n(73021),a=n(62771),o=n.n(a);const s=5,l={jingle:45,loop:300},i=e=>{var t;return null!==(t=l[null!==e&&void 0!==e?e:""])&&void 0!==t?t:1500},c=function(e,t){let n=arguments.length>2&&void 0!==arguments[2]?arguments[2]:s;return Math.min(t,Math.max(n,e))},u=e=>{const t=Math.round(e),n=Math.floor(t/60),r=t%60;return"".concat(String(n).padStart(2,"0"),":").concat(String(r).padStart(2,"0"))};var d=n(55529);const p=()=>(0,d.jsx)("svg",{width:"24",height:"24",viewBox:"0 0 24 24",fill:"none","aria-hidden":"true",children:(0,d.jsx)("path",{d:"M17 12H7",stroke:"currentColor",strokeWidth:"1.5",strokeLinecap:"round",strokeLinejoin:"round"})});p.displayName="src/components/DurationStepper/StepMinusIcon";const S=()=>(0,d.jsx)("svg",{width:"24",height:"24",viewBox:"0 0 24 24",fill:"none","aria-hidden":"true",children:(0,d.jsx)("path",{d:"M12 6V18M18 12H6",stroke:"currentColor",strokeWidth:"1.5",strokeLinecap:"round",strokeLinejoin:"round"})});S.displayName="src/components/DurationStepper/StepPlusIcon";function h(e){let{value:t,onChange:n,max:a,min:l=s,changed:i,locked:h,onLockedClick:v,className:m}=e;const[g,f]=(0,r.useState)(null),b=(0,r.useRef)(null),D=()=>{b.current&&(clearTimeout(b.current),b.current=null)};(0,r.useEffect)(()=>D,[]);const A=(0,r.useRef)(t);A.current=t;const E=e=>{const t=c(A.current+e,a,l);t!==A.current?(A.current=t,n(t)):D()},L=e=>{D(),E(e);let t=350;const n=()=>{E(e),t=Math.max(45,.85*t),b.current=setTimeout(n,t)};b.current=setTimeout(n,t)},_=()=>{null!==g&&(n(c((e=>{if(e.includes(":")){const[t,n]=e.split(":");return 60*(parseInt(t,10)||0)+Math.min(59,parseInt(n,10)||0)}return parseInt(e,10)||0})(g),a,l)),f(null))},k=null!==g?g:u(t),M=!h&&t>=a,x=!h&&t<=l;return(0,d.jsxs)("div",{className:o()("duration-stepper",{"duration-stepper--locked":h},m),children:[(0,d.jsx)("button",{type:"button",className:"duration-stepper__step",disabled:x,onPointerDown:h?v:()=>L(-1),onPointerUp:D,onPointerLeave:D,onPointerCancel:D,"aria-label":"Decrease duration",children:(0,d.jsx)(p,{})}),(0,d.jsx)("input",{className:o()("duration-stepper__value",{"duration-stepper__value--changed":i}),value:k,inputMode:"numeric",maxLength:5,readOnly:h,"aria-label":"Track duration",onMouseDown:h?e=>{e.preventDefault(),null===v||void 0===v||v()}:void 0,onFocus:h?void 0:()=>f(u(t)),onChange:e=>f((e=>e.replace(/[^\d:]/g,"").slice(0,5))(e.target.value)),onBlur:_,onKeyDown:e=>{"Enter"===e.key&&(_(),e.currentTarget.blur())}}),(0,d.jsx)("button",{type:"button",className:"duration-stepper__step duration-stepper__step--up",disabled:M,onPointerDown:h?v:()=>L(1),onPointerUp:D,onPointerLeave:D,onPointerCancel:D,"aria-label":"Increase duration",children:(0,d.jsx)(S,{})})]})}h.displayName="src/components/DurationStepper/DurationStepper"},65863(e,t,n){e.exports=n.p+"static/media/delete.7efe8112.svg"},69292(e,t,n){n.d(t,{TJ:()=>u,Ql:()=>d,XZ:()=>p,Vk:()=>m,tg:()=>v,Kw:()=>i,bM:()=>c,RZ:()=>h,bE:()=>S});const r=n.p+"static/media/drums.e85d05f9.svg",a=n.p+"static/media/lead.a4c8d53d.svg",o=n.p+"static/media/bass.3cbb5aec.svg",s=n.p+"static/media/FX.17a0d113.svg",l=n.p+"static/media/vocals.7eaa1c4f.svg",i={DRUMS:"DRUMS",PERCS:"DRUMS",HATS:"DRUMS",CLAPS:"DRUMS",BASS:"BASS",MIDS:"LEADS",LEADS:"LEADS",PADS:"LEADS",VOCALS:"VOCALS",FX:"FX",RISER:"FX",IMPACT:"FX"},c=["DRUMS","BASS","LEADS","VOCALS","FX"],u=["DRUMS","BASS","LEADS","FX"],d=4,p=1,S=function(e){return e>0?88*e+(e-1)*(arguments.length>1&&void 0!==arguments[1]?arguments[1]:d):0},h=function(){let e=arguments.length>1&&void 0!==arguments[1]?arguments[1]:e=>i[e],t=arguments.length>2&&void 0!==arguments[2]?arguments[2]:[];const n=new Set((arguments.length>
10&&void 0!==arguments[0]?arguments[0]:[]).map(e).filter(Boolean)),r=new Set(t);return c.filter(e=>u.includes(e)||n.has(e)||r.has(e))},v={DRUMS:"Drums",BASS:"Bass",LEADS:"Lead",VOCALS:"Vocals",FX:"FX"},m={DRUMS:r,BASS:o,LEADS:a,FX:s,VOCALS:l}},99753(e,t,n){n.d(t,{L:()=>d});var r=n(73021),a=n(26306),o=n(73442),s=n(40929),l=n(36026),i=n(81102),c=n(55529);function u(e){let{onVerify:t,onCancel:n}=e;const r=(0,a.useDispatch)();return(0,c.jsx)("div",{className:"turnstile-challenge",children:(0,c.jsxs)("div",{className:"turnstile-challenge__box",children:[(0,c.jsx)(o.X,{fullWidth:!0,onVerify:e=>{r((0,i.K)(e)),s.I.setItem(l.aY,e),t(e)},onError:e=>{console.log(e)}}),n&&(0,c.jsx)("button",{type:"button",className:"turnstile-challenge__cancel",onClick:n,children:"Cancel"})]})})}u.displayName="src/components/TurnstileChallenge/TurnstileChallenge";const d=()=>{const[e,t]=(0,r.useState)(null);return{request:(0,r.useCallback)(e=>t({run:e}),[]),challenge:e?(0,c.jsx)(u,{onVerify:n=>{t(null),e.run(n)},onCancel:()=>t(null)}):null}}}}]); 2//# sourceMappingURL=2334.e71a9eab.chunk.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.