PageSourceSearch

https://pcpc.gov.in/_next/static/chunks/pages/control-panel-41A3xB…/crime-statistics-9e666e459b9903f6.js

js pcpc.gov.in collected 2026-10-01 23:47:28 UTC 30,464 bytes, 1 lines download raw bytes

1(self.webpackChunk_N_E=self.webpackChunk_N_E||[]).push([[9118],{34750:function(e,t,a){(window.__NEXT_P=window.__NEXT_P||[]).push(["/control-panel-41A3xB/dashboard/crime-statistics",function(){return a(65558)}])},56771:function(e,t,a){"use strict";a.d(t,{w_:function(){return i}});var s=a(67294),n={color:void 0,size:void 0,className:void 0,style:void 0,attr:void 0},r=s.createContext&&s.createContext(n),o=function(){return(o=Object.assign||function(e){for(var t,a=1,s=arguments.length;a<s;a++)for(var n in t=arguments[a])Object.prototype.hasOwnProperty.call(t,n)&&(e[n]=t[n]);return e}).apply(this,arguments)},l=function(e,t){var a={};for(var s in e)Object.prototype.hasOwnProperty.call(e,s)&&0>t.indexOf(s)&&(a[s]=e[s]);if(null!=e&&"function"==typeof Object.getOwnPropertySymbols)for(var n=0,s=Object.getOwnPropertySymbols(e);n<s.length;n++)0>t.indexOf(s[n])&&Object.prototype.propertyIsEnumerable.call(e,s[n])&&(a[s[n]]=e[s[n]]);return a};function i(e){return function(t){return s.createElement(c,o({attr:o({},e.attr)},t),function e(t){return t&&t.map(function(t,a){return s.createElement(t.tag,o({key:a},t.attr),e(t.child))})}(e.child))}}function c(e){var t=function(t){var a,n=e.attr,r=e.size,i=e.title,c=l(e,["attr","size","title"]),d=r||t.size||"1em";return t.className&&(a=t.className),e.className&&(a=(a?a+" ":"")+e.className),s.createElement("svg",o({stroke:"currentColor",fill:"currentColor",strokeWidth:"0"},t.attr,n,c,{className:a,style:o(o({color:e.color||t.color},t.style),e.style),height:d,width:d,xmlns:"http://www.w3.org/2000/svg"}),i&&s.createElement("title",null,i),e.children)};return void 0!==r?s.createElement(r.Consumer,null,function(e){return t(e)}):t(n)}},65558:function(e,t,a){"use strict";a.r(t);var s=a(85893),n=a(67294),r=a(9008),o=a.n(r),l=a(669),i=a(35898);a(37677);var c=a(22920),d=a(40898),u=a(94050),p=a(64749),m=a(13246),h=a(41664),f=a.n(h);a(4641);var b=a(31190),g=a(38837),x=a(31955),y=a(22424);t.default=()=>{let[e,t]=(0,n.useState)(""),[a,r]=(0,n.useState)(""),[h,v]=(0,n.use
1State)(""),[w,N]=(0,n.useState)(null),[E,j]=(0,n.useState)(!1),[T,C]=(0,n.useState)(!1),[O,_]=(0,n.useState)(!1),[k,I]=(0,n.useState)([]),[L,S]=(0,n.useState)(""),[P,M]=(0,n.useState)(1),[R,z]=(0,n.useState)(0),[D,A]=(0,n.useState)(10),[B,F]=(0,n.useState)(!1),$=e=>{S(e),F(!0)},Z=()=>{S(""),F(!1)},[H,q]=(0,n.useState)(!1),[Q,W]=(0,n.useState)(""),[V,U]=(0,n.useState)(""),[X,G]=(0,n.useState)(""),[Y,K]=(0,n.useState)(""),[J,ee]=(0,n.useState)(""),[et,ea]=(0,n.useState)(null),[es,en]=(0,n.useState)(!1),[er,eo]=(0,n.useState)(!1),el=(e,t,a,s,n)=>{W(y.Z.sanitize(e)),U(y.Z.sanitize(t)),G(y.Z.sanitize(a)),K(y.Z.sanitize(s)),ee(y.Z.sanitize(n)),q(!0)},ei=e=>{en(!1);let t=e.target.files[0];if(t){if("application/pdf"===t.type)t.size<=5242880?ea(t):(en(!0),e.target.value="",ea(null));else{e.target.value="",ea(null),alert("Please select a PDF file.");return}}};(0,n.useEffect)(()=>{eb()},[P,D]);let ec=e=>{M(e)},ed=e=>{j(!1);let t=e.target.files[0];if(t){if("application/pdf"===t.type)t.size<=5242880?N(t):(j(!0),e.target.value="",N(null));else{e.target.value="",N(null),alert("Please select a PDF file.");return}}},eu=()=>{c.Am.success("new record created successfully!",{position:"top-right",autoClose:2e3,hideProgressBar:!1,closeOnClick:!0,pauseOnHover:!0,draggable:!1,progress:void 0})},ep=()=>{c.Am.success("Record Updated successfully!",{position:"top-right",autoClose:2e3,hideProgressBar:!1,closeOnClick:!0,pauseOnHover:!0,draggable:!1,progress:void 0})},em=()=>{c.Am.warn("oops something went wrong!",{position:"top-right",autoClose:3e3,hideProgressBar:!1,closeOnClick:!0,pauseOnHover:!0,draggable:!0,progress:void 0,theme:"dark"})},eh=()=>{c.Am.success("Record Deleted successfully!",{position:"top-right",autoClose:3e3,hideProgressBar:!1,closeOnClick:!0,pauseOnHover:!0,draggable:!0,progress:void 0,theme:"dark"})},ef=()=>{c.Am.warn("Fields are required!",{position:"top-right",autoClose:3e3,hideProgressBar:!1,closeOnClick:!0,pauseOnHover:!0,draggable:!0,progress:void 0,theme:"dark"})},eb=async()=>{try{let e=await fetch("".concat("https://api.pcpc.gov.in","/api/records-by-tag?tag=crime_statistics&page=").concat(P,"&limit=").concat(D),{method:"GET"}),t=await e.json();t.records?(I(t.records),z(t.totalPages)):em()}catch(e){em()}},eg=async e=>{Z();let t=x.Z.get("token");try{let a=await fetch("".concat("https://api.pcpc.gov.in","/api/delete-record?id=").concat(e),{method:"DELETE",headers:{Authorization:"Bearer ".concat(t)}}),s=await a.json();!0===s.success?(eh(),M(1),eb()):em()}catch(e){em()}},ex=async s=>{if(!e||!a||!w){ef();return}C(!0),_(!1),s.preventDefault();let n=x.Z.get("token"),o=new FormData;o.append("title",y.Z.sanitize(e)),o.append("titleInMarathi",y.Z.sanitize(a)),h&&o.append("date",y.Z.sanitize(h)),o.append("tag","crime_statistics"),o.append("pdf",w);try{let e=await fetch("".concat("https://api.pcpc.gov.in","/api/add-record"),{method:"POST",body:o,headers:{Authorization:"Bearer ".concat(n)}});(await e.json()).success?(eb(),C(!1),eu(),t(""),r(""),v(""),N(null)):(em(),C(!1)),_(!0)}catch(e){em(),C(!1),_(!0)}},ey=async e=>{if(!Q||!V){ef();return}e.preventDefault(),eo(!0);let t=x.Z.get("token"),a=new FormData;a.append("title",y.Z.sanitize(Q)),a.append("titleInMarathi",y.Z.sanitize(V)),X&&a.append("date",y.Z.sanitize(X)),et&&a.append("pdf",et);try{let e=await fetch("".concat("https://api.pcpc.gov.in","/api/update-record?recordId=").concat(J),{method:"POST",body:a,headers:{Authorization:"Bearer ".concat(t)}});(await e.json()).success?(eb(),eo(!1),ep(),W(""),U(""),G(""),N(null)):(em(),eo(!1)),q(!1)}catch(e){em(),eo(!1),q(!1)}};return(0,s.jsx)(g.Z,{children:(0,s.jsxs)(s.Fragment,{children:[(0,s.jsx)(o(),{children:(0,s.jsx)("title",{children:"Crime Statistics | Admin Dashboard"})}),(0,s.jsxs)("main",{className:"bg-gray-100",children:[(0,s.jsx)(l.Z,{}),(0,s.jsx)(c.Ix,{autoClose:2e3}),(0,s.jsxs)("div",{className:"flex flex-row",children:[(0,s.jsx)(i.Z,{}),(0,s.jsx)("div",{className:"hidden lg:block w-1/5"}),(0,s.jsxs)("div",{className:"w-full lg:w-4/5 mt-20 mx-5 bg-white shadow p-5",children:[(0,s.jsxs)("div",{className:"flex flex-row space-x-2 border-b pb-5",children:[(0,s.jsx)("button",{onClick:()=>_(!0),className:"bg-blue-500 text-white px-3 py-1 rounded-md hover:bg-blue-600",children:"Add Record"}),(0,s.jsx)("button",{onClick:()=>{v(""),t(""),r(""),N(null)},className:"bg-blue-500 text-white px-3 py-1 rounded-md hover:bg-blue-600",children:"Reset"}),(0,s.jsx)("button",{onClick:()=>{_(!1),v(""),t(""),r(""),N(null)},className:"bg-blue-500 text-white px-3 py-1 rounded-md hover:bg-blue-600",children:"Cancel"})]}),O&&(0,s.jsxs)("div",{className:"mt-5",children:[(0,s.jsxs)("div",{className:"flex flex-col mx-3 my-1 space-y-1 mb-5",children:[(0,s.jsx)("label",{htmlFor:"title",className:"mb-1 text-base text-gray-800",children:"* Title"}),(0,s.jsx)("input",{type:"text",id:"title",name:"title",className:"text-base border-b border-b-black px-3 py-2  outline-none focus:border-purple-700 w-full",placeholder:"Enter title",value:e,onCh
1ange:e=>t(e.target.value)})]}),(0,s.jsxs)("div",{className:"flex flex-col mx-3 my-1 space-y-1 mb-5",children:[(0,s.jsx)("label",{htmlFor:"titleInMarathi",className:"mb-1 text-base text-gray-800",children:"* Title in Marathi"}),(0,s.jsx)("input",{type:"text",id:"titleInMarathi",name:"titleInMarathi",className:"text-base border-b border-b-black px-3 py-2  outline-none focus:border-purple-700 w-full",placeholder:"Enter title in Marathi",value:a,onChange:e=>r(e.target.value)})]}),(0,s.jsxs)("div",{className:"flex flex-col mx-3 my-1 space-y-1 mb-5",children:[(0,s.jsx)("label",{htmlFor:"date",className:"mb-1 text-base text-gray-800",children:"Date"}),(0,s.jsx)("input",{type:"date",id:"date",name:"date",className:"text-base border-b border-b-black px-3 py-2  outline-none focus:border-purple-700 w-40",value:h,onChange:e=>v(e.target.value)})]}),(0,s.jsxs)("div",{className:"flex flex-col mx-3 my-1 space-y-1 mb-5",children:[(0,s.jsx)("label",{htmlFor:"file",className:"mb-1 text-base text-gray-800",children:"* File"}),(0,s.jsx)("input",{type:"file",id:"file",name:"pdf",accept:".pdf",className:"text-base border-b border-b-black px-3 py-2  outline-none focus:border-purple-700 w-60",placeholder:"Enter title",onChange:e=>ed(e)}),E&&(0,s.jsx)("p",{className:"text-red-600 text-sm",children:"File size exceeds the limit (5MB). Please choose a smaller file"})]}),(0,s.jsx)("div",{children:(0,s.jsx)("button",{onClick:ex,className:"bg-blue-500 text-white px-3 py-1 rounded-md hover:bg-blue-600",children:"Submit"})})]}),T&&(0,s.jsx)("div",{className:"flex justify-center items-center h-80",children:(0,s.jsx)(d.iT,{height:80,width:80,color:"#3B82F6",wrapperStyle:{},wrapperClass:"",visible:!0,ariaLabel:"oval-loading",secondaryColor:"#b5d1ff",strokeWidth:3,strokeWidthSecondary:3})}),(0,s.jsxs)("div",{className:"mb-52 w-full bg-white",children:[(0,s.jsx)("h1",{className:"font-semibold text-xl mt-10",children:"Crime Statistics Records"}),(0,s.jsxs)("div",{className:"flex flex-row mt-5 space-x-1",children:[(0,s.jsx)("div",{children:"Show"}),(0,s.jsxs)("select",{id:"locationSelect",name:"location",value:D,onChange:e=>{A(e.target.value),M(1)},className:"text-sm border px-1 py-1 h-7 rounded-md shadow-md  outline-none",children:[(0,s.jsx)("option",{value:"10",children:"10"}),(0,s.jsx)("option",{value:"25",children:"25"}),(0,s.jsx)("option",{value:"50",children:"50"}),(0,s.jsx)("option",{value:"100",children:"100"})]}),(0,s.jsx)("div",{children:"entries"})]}),(0,s.jsx)("div",{className:"overflow-x-auto max-w-full",children:(0,s.jsxs)("table",{className:"w-full min-w-[800px] mx-auto mt-5 text-left",children:[(0,s.jsxs)("tr",{className:"border flex flex-row justify-between bg-gray-100",children:[(0,s.jsx)("th",{className:"p-2 w-1/12 border-r",children:"Delete"}),(0,s.jsx)("th",{className:"p-2 w-1/12 border-r",children:"Edit"}),(0,s.jsx)("th",{className:"p-2 w-4/12 border-r",children:"Title"}),(0,s.jsx)("th",{className:"p-2 w-3/12 border-r",children:"Title in Marathi"}),(0,s.jsx)("th",{className:"p-2 w-2/12 border-r",children:"Date"}),(0,s.jsx)("th",{className:"p-2 w-1/12 border-r",children:"File"})]}),k.map(e=>{let{title:t,titleInMarathi:a,date:n,pdflink:r,_id:o}=e;return(0,s.jsxs)("tr",{className:"border flex flex-row justify-between",children:[(0,s.jsx)("td",{className:"p-1 w-1/12 border-r",children:(0,s.jsx)("button",{className:"bg-red-600 text-white p-3 rounded",onClick:()=>$(o),children:(0,s.jsx)(u.uaR,{})})}),(0,s.jsx)("td",{className:"p-1 w-1/12 border-r",children:(0,s.jsx)("button",{className:"bg-yellow-600 text-white p-3 rounded",onClick:()=>el(t,a,n,r,o),children:(0,s.jsx)(m.QML,{})})}),(0,s.jsx)("td",{className:"p-1 w-4/12 border-r",children:t}),(0,s.jsx)("td",{className:"p-1 w-3/12 border-r",children:a}),(0,s.jsx)("td",{className:"p-1 w-2/12 border-r",children:n}),(0,s.jsx)("td",{className:"p-1 w-1/12 border-r",children:(0,s.jsx)(f(),{href:r,target:"_blank",rel:"noopener noreferrer",children:(0,s.jsx)("button",{className:"bg-yellow-600 text-white p-3 rounded",children:(0,s.jsx)(p.Ljp,{})})})})]},o)})]})}),k.length>0&&(0,s.jsxs)("div",{className:"mt-4 flex  gap-2 items-center mx-auto",children:[(0,s.jsx)("button",{onClick:()=>ec(P-1),disabled:1===P,className:"px-4 py-1 bg-blue-500 text-white rounded disabled:bg-gray-300 hover:bg-blue-600 transition-colors",children:"Previous"}),(0,s.jsxs)("span",{className:"text-gray-700",children:["Page ",P," of ",R]}),(0,s.jsx)("button",{onClick:()=>ec(P+1),disabled:P===R,className:"px-4 py-1 bg-blue-500 text-white rounded disabled:bg-gray-300 hover:bg-blue-600 transition-colors",children:"Next"})]}),(0,s.jsx)(b.u,{open:B,onClose:Z,center:!0,children:(0,s.jsxs)("div",{className:"px-5 pt-5",children:[(0,s.jsx)("p",{children:"Are you sure to delete the record ?"}),(0,s.jsxs)("div",{className:"flex flex-row justify-between mt-5",children:[(0,s.jsx)("div",{children:(0,s.jsx)("button",{className:"px-3 py-1 bg-white border rounded",onClick:Z,children:"Cancel"})}),(0,s.jsx)("div",{children:(0,s.jsx)("button",{className:"px-3 py-1 bg-red-600 font-semibold text-white border rounded",onClick:()=>eg(L),children:"Delete"})})]})]})}),(0,s.jsx)(b.u,{open:H,onClose:()=>{q(!1)},center:!0,children:(0,s.jsxs)("div",{className:"pt-10 px-5 w-[500px]",children:[(0,s.jsxs)("div",{className:"flex flex-col mx-3 my-1 space-y-1 mb-5",children:[(0,s.jsx)("label",{htmlFor:"title",className:"mb-1 text-base text-gray-800",children:"* Title"}),(0,s.jsx)("input",{type:"text",id:"title",name:"title",className:"text-base border-b border-b-black px-3 py-2  outline-none focus:border-purple-700 w-full",placeholder:"Enter title",value:Q,onChange:e=>W(e.target.value)})]}),(0,s.jsxs)("div",{className:"flex flex-col mx-3 my-1 space-y-1 mb-5",children:[(0,s.jsx)("label",{htmlFor:"titleInMarathi",className:"mb-1 text-base text-gray-800",children:"* Title in Marathi"}),(0,s.jsx)("input",{type:"text",id:"titleInMarathi",name:"titleInMarathi",className:"text-base border-b border-b-black px-3 py-2  outline-none focus:border-purple-700 w-full",placeholder:"Enter title in Marathi",value:V,onChange:e=>U(e.target.value)})]}),(0,s.jsxs)("div",{className:"flex flex-col mx-3 my-1 space-y-1 mb-5",children:[(0,s.jsx)("label",{htmlFor:"date",className:"mb-1 text-base text-gray-800",children:"Date"}),(0,s.jsx)("input",{type:"date",id:"date",name:"date",className:"text-base border-b border-b-black px-3 py-2  outline-none focus:border-purple-700 w-40",value:X,onChange:e=>G(e.target.value)})]}),(0,s.jsxs)("div",{className:"flex flex-col mx-3 my-1 space-y-1 mb-5",children:[(0,s.jsx)("label",{htmlFor:"file",className:"mb-1 text-base text-gray-800",children:"New File (Optional)"}),(0,s.jsx)("input",{type:"file",id:"file",name:"pdf",accept:".pdf",className:"text-base border-b border-b-black px-3 py-2  outline-none focus:border-purple-700 w-60",placeholder:"Enter title",onCh
1ange:e=>ei(e)}),es&&(0,s.jsx)("p",{className:"text-red-600 text-sm",children:"File size exceeds the limit (5MB). Please choose a smaller file"})]}),(0,s.jsx)("div",{children:(0,s.jsxs)("button",{onClick:ey,className:"bg-blue-500 flex justify-center items-center  text-white px-3 py-1 rounded-md hover:bg-blue-600",children:["Update Record",er&&(0,s.jsx)("div",{className:"ml-2",children:(0,s.jsx)(d.iT,{height:25,width:25,color:"#ffffff",wrapperStyle:{},wrapperClass:"",visible:!0,ariaLabel:"oval-loading",secondaryColor:"#b5d1ff",strokeWidth:5,strokeWidthSecondary:5})})]})})]})})]})]})]})]})]})})}},22920:function(e,t,a){"use strict";a.d(t,{Ix:function(){return N},Am:function(){return I}});var s=a(67294),n=function(){for(var e,t,a=0,s="";a<arguments.length;)(e=arguments[a++])&&(t=function e(t){var a,s,n="";if("string"==typeof t||"number"==typeof t)n+=t;else if("object"==typeof t){if(Array.isArray(t))for(a=0;a<t.length;a++)t[a]&&(s=e(t[a]))&&(n&&(n+=" "),n+=s);else for(a in t)t[a]&&(n&&(n+=" "),n+=a)}return n}(e))&&(s&&(s+=" "),s+=t);return s};let r=e=>"number"==typeof e&&!isNaN(e),o=e=>"string"==typeof e,l=e=>"function"==typeof e,i=e=>o(e)||l(e)?e:null,c=e=>(0,s.isValidElement)(e)||o(e)||l(e)||r(e);function d(e){let{enter:t,exit:a,appendPosition:n=!1,collapse:r=!0,collapseDuration:o=300}=e;return function(e){let{children:l,position:i,preventExitTransition:c,done:d,nodeRef:u,isIn:p}=e,m=n?`${t}--${i}`:t,h=n?`${a}--${i}`:a,f=(0,s.useRef)(0);return(0,s.useLayoutEffect)(()=>{let e=u.current,t=m.split(" "),a=s=>{s.target===u.current&&(e.dispatchEvent(new Event("d")),e.removeEventListener("animationend",a),e.removeEventListener("animationcancel",a),0===f.current&&"animationcancel"!==s.type&&e.classList.remove(...t))};e.classList.add(...t),e.addEventListener("animationend",a),e.addEventListener("animationcancel",a)},[]),(0,s.useEffect)(()=>{let e=u.current,t=()=>{e.removeEventListener("animationend",t),r?function(e,t,a){void 0===a&&(a=300);let{scrollHeight:s,style:n}=e;requestAnimationFrame(()=>{n.minHeight="initial",n.height=s+"px",n.transition=`all ${a}ms`,requestAnimationFrame(()=>{n.height="0",n.padding="0",n.margin="0",setTimeout(t,a)})})}(e,d,o):d()};p||(c?t():(f.current=1,e.className+=` ${h}`,e.addEventListener("animationend",t)))},[p]),s.createElement(s.Fragment,null,l)}}function u(e,t){return null!=e?{content:e.content,containerId:e.props.containerId,id:e.props.toastId,theme:e.props.theme,type:e.props.type,data:e.props.data||{},isLoading:e.props.isLoading,icon:e.props.icon,status:t}:{}}let p={list:new Map,emitQueue:new Map,on(e,t){return this.list.has(e)||this.list.set(e,[]),this.list.get(e).push(t),this},off(e,t){if(t){let a=this.list.get(e).filter(e=>e!==t);return this.list.set(e,a),this}return this.list.delete(e),this},cancelEmit(e){let t=this.emitQueue.get(e);return t&&(t.forEach(clearTimeout),this.emitQueue.delete(e)),this},emit(e){this.list.has(e)&&this.list.get(e).forEach(t=>{let a=setTimeout(()=>{t(...[].slice.call(arguments,1))},0);this.emitQueue.has(e)||this.emitQueue.set(e,[]),this.emitQueue.get(e).push(a)})}},m=e=>{let{theme:t,type:a,...n}=e;return s.createElement("svg",{viewBox:"0 0 24 24",width:"100%",height:"100%",fill:"colored"===t?"currentColor":`var(--toastify-icon-color-${a})`,...n})},h={info:function(e){return s.createElement(m,{...e},s.createElement("path",{d:"M12 0a12 12 0 1012 12A12.013 12.013 0 0012 0zm.25 5a1.5 1.5 0 11-1.5 1.5 1.5 1.5 0 011.5-1.5zm2.25 13.5h-4a1 1 0 010-2h.75a.25.25 0 00.25-.25v-4.5a.25.25 0 00-.25-.25h-.75a1 1 0 010-2h1a2 2 0 012 2v4.75a.25.25 0 00.25.25h.75a1 1 0 110 2z"}))},warning:function(e){return s.createElement(m,{...e},s.createElement("path",{d:"M23.32 17.191L15.438 2.184C14.728.833 13.416 0 11.996 0c-1.42 0-2.733.833-3.443 2.184L.533 17.448a4.744 4.744 0 000 4.368C1.243 23.167 2.555 24 3.975 24h16.05C22.22 24 24 22.044 24 19.632c0-.904-.251-1.746-.68-2.44zm-9.622 1.46c0 1.033-.724 1.823-1.698 1.823s-1.698-.79-1.698-1.822v-.043c0-1.028.724-1.822 1.698-1.822s1.698.79 1.698 1.822v.043zm.039-12.285l-.84 8.06c-.057.581-.408.943-.897.943-.49 0-.84-.367-.896-.942l-.84-8.065c-.057-.624.25-1.095.779-1.095h1.91c.528.005.84.476.784 1.1z"}))},success:function(e){return s.createElement(m,{...e},s.createElement("path",{d:"M12 0a12 12 0 1012 12A12.014 12.014 0 0012 0zm6.927 8.2l-6.845 9.289a1.011 1.011 0 01-1.43.188l-4.888-3.908a1 1 0 111.25-1.562l4.076 3.261 6.227-8.451a1 1 0 111.61 1.183z"}))},error:function(e){return s.createElement(m,{...e},s.createElement("path",{d:"M11.983 0a12.206 12.206 0 00-8.51 3.653A11.8 11.8 0 000 12.207 11.779 11.779 0 0011.8 24h.214A12.111 12.111 0 0024 11.791 11.766 11.766 0 0011.983 0zM10.5 16.542a1.476 1.476 0 011.449-1.53h.027a1.527 1.527 0 011.523 1.47 1.475 1.475 0 01-1.449 1.53h-.027a1.529 1.529 0 01-1.523-1.47zM11 12.5v-6a1 1 0 012 0v6a1 1 0 11-2 0z"}))},spinner:function(){return s.createElement("div",{className:"Toastify__spinner"})}};function f(e){return e.targetTouches&&e.targetTouches.length>=1?e.targetTouches[0].clientX:e.clientX}function b(e){return e.targetTouches&&e.targetTouches.length>=1?e.targetTouches[0].clientY:e.clientY}function g(e){let{closeToast:t,theme:a,ariaLabel:n="close"}=e;return s.createElement("button",{className:`Toastify__close-button Toastify__close-button--${a}`,type:"button",onClick:e=>{e.stopPropagation(),t(e)},"aria-label":n},s.createElement("svg",{"aria-hidden":"true",viewBox:"0 0 14 16"},s.createElement("path",{fillRule:"evenodd",d:"M7.71 8.23l3.75 3.75-1.48 1.48-3.75-3.75-3.75 3.75L1 11.98l3.75-3.75L1 4.48 2.48 3l3.75 3.75L9.98 3l1.48 1.48-3.75 3.75z"})))}function x(e){let{delay:t,isRunning:a,closeToast:r,type:o="default",hide:i,className:c,style:d,controlledProgress:u,progress:p,rtl:m,isIn:h,theme:f}=e,b=i||u&&0===p,g={...d,animationDuration:`${t}ms`,animationPlayState:a?"running":"paused",opacity:b?0:1};u&&(g.transform=`scaleX(${p})`);let x=n("Toastify__progress-bar",u?"Toastify__progress-bar--controlled":"Toastify__progress-bar--animated",`Toastify__progress-bar-theme--${f}`,`Toastify__progress-bar--${o}`,{"Toastify__progress-bar--rtl":m}),y=l(c)?c({rtl:m,type:o,defaultClassName:x}):n(x,c);return s.createElement("div",{role:"progressbar","aria-hidden":b?"true":"false","aria-label":"notification timer",className:y,style:g,[u&&p>=1?"onTransitionEnd":"onAnimationEnd"]:u&&p<1?null:()=>{h&&r()}})}let y=e=>{let{isRunning:t,preventExitTransition:a,toastRef:r,eventHandlers:o}
1=function(e){let[t,a]=(0,s.useState)(!1),[n,r]=(0,s.useState)(!1),o=(0,s.useRef)(null),i=(0,s.useRef)({start:0,x:0,y:0,delta:0,removalDistance:0,canCloseOnClick:!0,canDrag:!1,boundingRect:null,didMove:!1}).current,c=(0,s.useRef)(e),{autoClose:d,pauseOnHover:u,closeToast:p,onClick:m,closeOnClick:h}=e;function g(t){if(e.draggable){"touchstart"===t.nativeEvent.type&&t.nativeEvent.preventDefault(),i.didMove=!1,document.addEventListener("mousemove",w),document.addEventListener("mouseup",N),document.addEventListener("touchmove",w),document.addEventListener("touchend",N);let a=o.current;i.canCloseOnClick=!0,i.canDrag=!0,i.boundingRect=a.getBoundingClientRect(),a.style.transition="",i.x=f(t.nativeEvent),i.y=b(t.nativeEvent),"x"===e.draggableDirection?(i.start=i.x,i.removalDistance=a.offsetWidth*(e.draggablePercent/100)):(i.start=i.y,i.removalDistance=a.offsetHeight*(80===e.draggablePercent?1.5*e.draggablePercent:e.draggablePercent/100))}}function x(t){if(i.boundingRect){let{top:a,bottom:s,left:n,right:r}=i.boundingRect;"touchend"!==t.nativeEvent.type&&e.pauseOnHover&&i.x>=n&&i.x<=r&&i.y>=a&&i.y<=s?v():y()}}function y(){a(!0)}function v(){a(!1)}function w(a){let s=o.current;i.canDrag&&s&&(i.didMove=!0,t&&v(),i.x=f(a),i.y=b(a),i.delta="x"===e.draggableDirection?i.x-i.start:i.y-i.start,i.start!==i.x&&(i.canCloseOnClick=!1),s.style.transform=`translate${e.draggableDirection}(${i.delta}px)`,s.style.opacity=""+(1-Math.abs(i.delta/i.removalDistance)))}function N(){document.removeEventListener("mousemove",w),document.removeEventListener("mouseup",N),document.removeEventListener("touchmove",w),document.removeEventListener("touchend",N);let t=o.current;if(i.canDrag&&i.didMove&&t){if(i.canDrag=!1,Math.abs(i.delta)>i.removalDistance)return r(!0),void e.closeToast();t.style.transition="transform 0.2s, opacity 0.2s",t.style.transform=`translate${e.draggableDirection}(0)`,t.style.opacity="1"}}(0,s.useEffect)(()=>{c.current=e}),(0,s.useEffect)(()=>(o.current&&o.current.addEventListener("d",y,{once:!0}),l(e.onOpen)&&e.onOpen((0,s.isValidElement)(e.children)&&e.children.props),()=>{let e=c.current;l(e.onClose)&&e.onClose((0,s.isValidElement)(e.children)&&e.children.props)}),[]),(0,s.useEffect)(()=>(e.pauseOnFocusLoss&&(document.hasFocus()||v(),window.addEventListener("focus",y),window.addEventListener("blur",v)),()=>{e.pauseOnFocusLoss&&(window.removeEventListener("focus",y),window.removeEventListener("blur",v))}),[e.pauseOnFocusLoss]);let E={onMouseDown:g,onTouchStart:g,onMouseUp:x,onTouchEnd:x};return d&&u&&(E.onMouseEnter=v,E.onMouseLeave=y),h&&(E.onClick=e=>{m&&m(e),i.canCloseOnClick&&p()}),{playToast:y,pauseToast:v,isRunning:t,preventExitTransition:n,toastRef:o,eventHandlers:E}}(e),{closeButton:i,children:c,autoClose:d,onClick:u,type:p,hideProgressBar:m,closeToast:h,transition:y,position:v,className:w,style:N,bodyClassName:E,bodyStyle:j,progressClassName:T,progressStyle:C,updateId:O,role:_,progress:k,rtl:I,toastId:L,deleteToast:S,isIn:P,isLoading:M,iconOut:R,closeOnClick:z,theme:D}=e,A=n("Toastify__toast",`Toastify__toast-theme--${D}`,`Toastify__toast--${p}`,{"Toastify__toast--rtl":I},{"Toastify__toast--close-on-click":z}),B=l(w)?w({rtl:I,position:v,type:p,defaultClassName:A}):n(A,w),F=!!k||!d,$={closeToast:h,type:p,theme:D},Z=null;return!1===i||(Z=l(i)?i($):(0,s.isValidElement)(i)?(0,s.cloneElement)(i,$):g($)),s.createElement(y,{isIn:P,done:S,position:v,preventExitTransition:a,nodeRef:r},s.createElement("div",{id:L,onClick:u,className:B,...o,style:N,ref:r},s.createElement("div",{...P&&{role:_},className:l(E)?E({type:p}):n("Toastify__toast-body",E),style:j},null!=R&&s.createElement("div",{className:n("Toastify__toast-icon",{"Toastify--animate-icon Toastify__zoom-enter":!M})},R),s.createElement("div",null,c)),Z,s.createElement(x,{...O&&!F?{key:`pb-${O}`}:{},rtl:I,theme:D,delay:d,isRunning:t,isIn:P,closeToast:h,hide:m,type:p,style:C,className:T,controlledProgress:F,progress:k||0})))}
1,v=function(e,t){return void 0===t&&(t=!1),{enter:`Toastify--animate Toastify__${e}-enter`,exit:`Toastify--animate Toastify__${e}-exit`,appendPosition:t}},w=d(v("bounce",!0)),N=(d(v("slide",!0)),d(v("zoom")),d(v("flip")),(0,s.forwardRef)((e,t)=>{let{getToastToRender:a,containerRef:d,isToastActive:m}=function(e){let[,t]=(0,s.useReducer)(e=>e+1,0),[a,n]=(0,s.useState)([]),d=(0,s.useRef)(null),m=(0,s.useRef)(new Map).current,f=e=>-1!==a.indexOf(e),b=(0,s.useRef)({toastKey:1,displayedToast:0,count:0,queue:[],props:e,containerId:null,isToastActive:f,getToast:e=>m.get(e)}).current;function g(e){let{containerId:t}=e,{limit:a}=b.props;!a||t&&b.containerId!==t||(b.count-=b.queue.length,b.queue=[])}function x(e){n(t=>null==e?[]:t.filter(t=>t!==e))}function y(){let{toastContent:e,toastProps:t,staleId:a}=b.queue.shift();w(e,t,a)}function v(e,a){var n,f;let{delay:g,staleId:v,...N}=a;if(!c(e)||!d.current||b.props.enableMultiContainer&&N.containerId!==b.props.containerId||m.has(N.toastId)&&null==N.updateId)return;let{toastId:E,updateId:j,data:T}=N,{props:C}=b,O=()=>x(E),_=null==j;_&&b.count++;let k={...C,style:C.toastStyle,key:b.toastKey++,...Object.fromEntries(Object.entries(N).filter(e=>
1{let[t,a]=e;return null!=a})),toastId:E,updateId:j,data:T,closeToast:O,isIn:!1,className:i(N.className||C.toastClassName),bodyClassName:i(N.bodyClassName||C.bodyClassName),progressClassName:i(N.progressClassName||C.progressClassName),autoClose:!N.isLoading&&(n=N.autoClose,f=C.autoClose,!1===n||r(n)&&n>0?n:f),deleteToast(){let e=u(m.get(E),"removed");m.delete(E),p.emit(4,e);let a=b.queue.length;if(b.count=null==E?b.count-b.displayedToast:b.count-1,b.count<0&&(b.count=0),a>0){let e=null==E?b.props.limit:1;if(1===a||1===e)b.displayedToast++,y();else{let t=e>a?a:e;b.displayedToast=t;for(let e=0;e<t;e++)y()}}else t()}};k.iconOut=function(e){let{theme:t,type:a,isLoading:n,icon:i}=e,c=null,d={theme:t,type:a};return!1===i||(l(i)?c=i(d):(0,s.isValidElement)(i)?c=(0,s.cloneElement)(i,d):o(i)||r(i)?c=i:n?c=h.spinner():a in h&&(c=h[a](d))),c}(k),l(N.onOpen)&&(k.onOpen=N.onOpen),l(N.onClose)&&(k.onClose=N.onClose),k.closeButton=C.closeButton,!1===N.closeButton||c(N.closeButton)?k.closeButton=N.closeButton:!0===N.closeButton&&(k.closeButton=!c(C.closeButton)||C.closeButton);let I=e;(0,s.isValidElement)(e)&&!o(e.type)?I=(0,s.cloneElement)(e,{closeToast:O,toastProps:k,data:T}):l(e)&&(I=e({closeToast:O,toastProps:k,data:T})),C.limit&&C.limit>0&&b.count>C.limit&&_?b.queue.push({toastContent:I,toastProps:k,staleId:v}):r(g)?setTimeout(()=>{w(I,k,v)},g):w(I,k,v)}function w(e,t,a){let{toastId:s}=t;a&&m.delete(a);let r={content:e,props:t};m.set(s,r),n(e=>[...e,s].filter(e=>e!==a)),p.emit(4,u(r,null==r.props.updateId?"added":"updated"))}return(0,s.useEffect)(()=>(b.containerId=e.containerId,p.cancelEmit(3).on(0,v).on(1,e=>d.current&&x(e)).on(5,g).emit(2,b),()=>{m.clear(),p.emit(3,b)}),[]),(0,s.useEffect)(()=>{b.props=e,b.isToastActive=f,b.displayedToast=a.length}),{getToastToRender:function(t){let a=new Map,s=Array.from(m.values());return e.newestOnTop&&s.reverse(),s.forEach(e=>{let{position:t}=e.props;a.has(t)||a.set(t,[]),a.get(t).push(e)}),Array.from(a,e=>t(e[0],e[1]))},containerRef:d,isToastActive:f}}(e),{className:f,style:b,rtl:g,containerId:x}=e;return(0,s.useEffect)(()=>{t&&(t.current=d.current)},[]),s.createElement("div",{ref:d,className:"Toastify",id:x},a((e,t)=>{let a=t.length?{...b}:{...b,pointerEvents:"none"};return s.createElement("div",{className:function(e){let t=n("Toastify__toast-container",`Toastify__toast-container--${e}`,{"Toastify__toast-container--rtl":g});return l(f)?f({position:e,rtl:g,defaultClassName:t}):n(t,i(f))}(e),style:a,key:`container-${e}`},t.map((e,a)=>{let{content:n,props:r}=e;return s.createElement(y,{...r,isIn:m(r.toastId),style:{...r.style,"--nth":a+1,"--len":t.length},key:`toast-${r.key}`},n)}))}))}));N.displayName="ToastContainer",N.defaultProps={position:"top-right",transition:w,autoClose:5e3,closeButton:g,pauseOnHover:!0,pauseOnFocusLoss:!0,closeOnClick:!0,draggable:!0,draggablePercent:80,draggableDirection:"x",role:"alert",theme:"light"};let E,j=new Map,T=[],C=1;function O(e,t){return j.size>0?p.emit(0,e,t):T.push({content:e,options:t}),t.toastId}function _(e,t){return{...t,type:t&&t.type||e,toastId:t&&(o(t.toastId)||r(t.toastId))?t.toastId:""+C++}}function k(e){return(t,a)=>O(t,_(e,a))}function I(e,t){return O(e,_("default",t))}I.loading=(e,t)=>
1O(e,_("default",{isLoading:!0,autoClose:!1,closeOnClick:!1,closeButton:!1,draggable:!1,...t})),I.promise=function(e,t,a){let s,{pending:n,error:r,success:i}=t;n&&(s=o(n)?I.loading(n,a):I.loading(n.render,{...a,...n}));let c={isLoading:null,autoClose:null,closeOnClick:null,closeButton:null,draggable:null},d=(e,t,n)=>{if(null==t)return void I.dismiss(s);let r={type:e,...c,...a,data:n},l=o(t)?{render:t}:t;return s?I.update(s,{...r,...l}):I(l.render,{...r,...l}),n},u=l(e)?e():e;return u.then(e=>d("success",i,e)).catch(e=>d("error",r,e)),u},I.success=k("success"),I.info=k("info"),I.error=k("error"),I.warning=k("warning"),I.warn=I.warning,I.dark=(e,t)=>O(e,_("default",{theme:"dark",...t})),I.dismiss=e=>{j.size>0?p.emit(1,e):T=T.filter(t=>null!=e&&t.options.toastId!==e)},I.clearWaitingQueue=function(e){return void 0===e&&(e={}),p.emit(5,e)},I.isActive=e=>{let t=!1;return j.forEach(a=>{a.isToastActive&&a.isToastActive(e)&&(t=!0)}),t},I.update=function(e,t){void 0===t&&(t={}),setTimeout(()=>{let a=function(e,t){let{containerId:a}=t,s=j.get(a||E);return s&&s.getToast(e)}(e,t);if(a){let{props:s,content:n}=a,r={delay:100,...s,...t,toastId:t.toastId||e,updateId:""+C++};r.toastId!==e&&(r.staleId=e);let o=r.render||n;delete r.render,O(o,r)}},0)},I.done=e=>{I.update(e,{progress:1})},I.onChange=e=>(p.on(4,e),()=>{p.off(4,e)}),I.POSITION={TOP_LEFT:"top-left",TOP_RIGHT:"top-right",TOP_CENTER:"top-center",BOTTOM_LEFT:"bottom-left",BOTTOM_RIGHT:"bottom-right",BOTTOM_CENTER:"bottom-center"},I.TYPE={INFO:"info",SUCCESS:"success",WARNING:"warning",ERROR:"error",DEFAULT:"default"},p.on(2,e=>{E=e.containerId||e,j.set(E,e),T.forEach(e=>{p.emit(0,e.content,e.options)}),T=[]}).on(3,e=>{j.delete(e.containerId||e),0===j.size&&p.off(0).off(1).off(5)})}},function(e){e.O(0,[4617,3874,5937,9814,1339,1190,3362,2888,9774,179],function(){return e(e.s=34750)}),_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.