Linux ip-172-26-7-228 5.4.0-1103-aws #111~18.04.1-Ubuntu SMP Tue May 23 20:04:10 UTC 2023 x86_64
Your IP : 3.15.214.244
{"version":3,"file":"static/js/35.c90d5434.chunk.js","mappings":"sLAIA,MAUA,EAVgBA,KAEZC,EAAAA,EAAAA,KAACC,EAAAA,EAAI,CACHC,WACEF,EAAAA,EAAAA,KAACG,EAAAA,EAAe,CAACC,MAAO,CAAEC,SAAU,GAAIC,MAAO,SAAWC,MAAI,MCgBtE,EArBeC,IAAmC,IAAlC,KAAEC,EAAI,QAAEC,EAAO,UAAEC,GAAWH,EAC1C,OACER,EAAAA,EAAAA,KAAA,OAAAY,SACGD,GACCX,EAAAA,EAAAA,KAAA,OAAKa,UAAU,SAAST,MAAO,CAAEU,WAAY,IAAKF,UAChDZ,EAAAA,EAAAA,KAACD,EAAO,OAGVC,EAAAA,EAAAA,KAAA,OAAAY,UACEZ,EAAAA,EAAAA,KAAA,SACEe,KAAK,SACLF,UAAU,SACVG,MAAOP,EACPC,QAASA,OAIX,C,sLCbV,MA2KA,GAAeO,EAAAA,EAAAA,KALUC,IAChB,CACLC,QAASD,EAAME,YAAYD,WAG/B,EA3KeE,IACb,IAAIC,GAAWC,EAAAA,EAAAA,MACXC,GAAWC,EAAAA,EAAAA,MACf,MAAM,SAAEC,IAAaC,EAAAA,EAAAA,OAEdC,EAAMC,IAAWC,EAAAA,EAAAA,UAAS,OAC1BC,EAAUC,IAAeF,EAAAA,EAAAA,UAAS,KAClCG,EAAUC,IAAeJ,EAAAA,EAAAA,UAAS,KAClCK,EAAUC,IAAeN,EAAAA,EAAAA,UAAS,KAClCO,EAAcC,IAAmBR,EAAAA,EAAAA,WAAS,IAEjDS,EAAAA,EAAAA,YAAU,KAGR,SAASC,IACMC,KAAKC,WAAWA,WACtBC,UAAUC,IAAI,QACvB,CAEA,SAASC,IACP,IAAIC,EAASL,KAAKC,WAAWA,WACX,IAAdD,KAAKzB,OACP8B,EAAOH,UAAUI,OAAO,QAE5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sE,SAAU,WAAYC,MAAO,MAAOC,IAAK,OAClDlE,QAASA,KACPsC,SAASe,eAAe,YAAYhD,KAAO,OAC3CuB,GAAgB,EAAK,EACrB1B,UAEFZ,EAAAA,EAAAA,KAAA,KAAGa,UAAU,2BAInBb,EAAAA,EAAAA,KAAC8E,EAAAA,EAAM,CACLrE,KAAK,QACLC,QAAU6D,GA3FRQ,WACZR,EAAES,iBACF,IAAIC,EAAU,CACZlD,SAAUA,EACVmD,KAAMjD,EACNE,SAAUA,IAEZgD,EAAAA,EAAAA,GAAU7D,EAAUE,EAAUyD,EAAQ,EAoFZG,CAAMb,GACtB5D,UAAWU,EAAMF,kBAKrB,G","sources":["Components/Spinner.js","Components/Button.js","Pages/Login/Login.js"],"sourcesContent":["import React from \"react\";\nimport { LoadingOutlined } from \"@ant-design/icons\";\nimport { Spin } from \"antd\";\n\nconst Spinner = () => {\n return (\n <Spin\n indicator={\n <LoadingOutlined style={{ fontSize: 30, color: \"white\" }} spin />\n }\n />\n );\n};\n\nexport default Spinner;\n","import React from \"react\";\nimport Spinner from \"./Spinner\";\n\nconst Button = ({ text, onClick, isLoading }) => {\n return (\n <div>\n {isLoading ? (\n <div className=\"button\" style={{ paddingTop: 10 }}>\n <Spinner />\n </div>\n ) : (\n <div>\n <input\n type=\"submit\"\n className=\"button\"\n value={text}\n onClick={onClick}\n />\n </div>\n )}\n </div>\n );\n};\n\nexport default Button;\n","import React, { useEffect, useState } from \"react\";\nimport { useDispatch, connect } from \"react-redux\";\nimport { useNavigate, useLocation } from \"react-router-dom\";\nimport { loginUser } from \"../../Actions/Login/Login\";\nimport Logo_098 from \"../../Components/assets/logo/098_logo.jpg\";\nimport Button from \"../../Components/Button\";\n\nconst Login = (props) => {\n let dispatch = useDispatch();\n let navigate = useNavigate();\n const { pathname } = useLocation();\n\n const [logo, setLogo] = useState(null);\n const [collcode, setCollCode] = useState(\"\");\n const [userName, setUserName] = useState(\"\");\n const [password, setPassword] = useState(\"\");\n const [passwordOpen, setPasswordOpen] = useState(false);\n\n useEffect(() => {\n const inputs = document.querySelectorAll(\".input\");\n\n function addcl() {\n let parent = this.parentNode.parentNode;\n parent.classList.add(\"focus\");\n }\n\n function remcl() {\n let parent = this.parentNode.parentNode;\n if (this.value == \"\") {\n parent.classList.remove(\"focus\");\n }\n }\n\n inputs.forEach((input) => {\n input.addEventListener(\"focus\", addcl);\n input.addEventListener(\"blur\", remcl);\n });\n setUrl();\n }, []);\n\n const setUrl = () => {\n console.log(pathname, \"pathname\");\n let univcode = \"\";\n if (pathname === \"/demo\") {\n univcode = \"098\";\n setLogo(Logo_098);\n localStorage.setItem(\"logo\", Logo_098);\n } else if (pathname === \"/jssstu\") {\n univcode = \"052\";\n } else if (pathname === \"/dypatil\") {\n univcode = \"051\";\n } else if (pathname === \"/sjbit\") {\n univcode = \"055\";\n }\n localStorage.setItem(\"univcode\", univcode);\n localStorage.setItem(\"rootpath\", pathname);\n let title = localStorage.getItem(\"rootpath\").split(\"/\");\n localStorage.setItem(\"db\", title[1]);\n\n document.getElementById(\"titlebar\").innerHTML = title[1];\n };\n\n const changeHandler = (value, name) => {\n if (name == \"collcode\") {\n setCollCode(value);\n } else if (name == \"userName\") {\n setUserName(value);\n } else if (name == \"password\") {\n setPassword(value);\n }\n };\n\n const Login = async (e) => {\n e.preventDefault();\n let userObj = {\n collcode: collcode,\n user: userName,\n password: password,\n };\n loginUser(dispatch, navigate, userObj);\n };\n\n return (\n <div>\n <div className=\"container\">\n <div className=\"login-content container\">\n <form>\n <img src={logo} />\n <h2 className=\"title\">Welcome</h2>\n <div className=\"input-div one\">\n <div className=\"i\">\n <i className=\"fas fa-city\"></i>\n </div>\n <div className=\"div\">\n <h5>College Code</h5>\n <input\n type=\"text\"\n className=\"input\"\n name=\"collcode\"\n maxLength={5}\n value={collcode}\n onChange={(e) => changeHandler(e.target.value, e.target.name)}\n />\n </div>\n </div>\n <div className=\"input-div one\">\n <div className=\"i\">\n <i className=\"fas fa-user\"></i>\n </div>\n <div className=\"div\">\n <h5>Username</h5>\n <input\n type=\"text\"\n className=\"input\"\n name=\"userName\"\n value={userName}\n maxLength={50}\n onChange={(e) => changeHandler(e.target.value, e.target.name)}\n />\n </div>\n </div>\n <div className=\"input-div pass\">\n <div className=\"i\">\n <i className=\"fas fa-lock\"></i>\n </div>\n <div className=\"div\">\n <h5>Password</h5>\n <input\n type=\"password\"\n id=\"password\"\n className=\"input\"\n name=\"password\"\n value={password}\n maxLength={32}\n onChange={(e) => changeHandler(e.target.value, e.target.name)}\n />\n </div>\n {passwordOpen ? (\n <div\n className=\"i\"\n style={{ position: \"absolute\", right: \"5px\", top: \"5px\" }}\n onClick={() => {\n document.getElementById(\"password\").type = \"password\";\n setPasswordOpen(false);\n }}\n >\n <i class=\"fas fa-eye\"></i>\n </div>\n ) : (\n <div\n className=\"i\"\n style={{ position: \"absolute\", right: \"5px\", top: \"5px\" }}\n onClick={() => {\n document.getElementById(\"password\").type = \"text\";\n setPasswordOpen(true);\n }}\n >\n <i className=\"fas fa-eye-slash\"></i>\n </div>\n )}\n </div>\n <Button\n text=\"Login\"\n onClick={(e) => Login(e)}\n isLoading={props.loading}\n />\n </form>\n </div>\n </div>\n </div>\n );\n};\n\nconst mapStateToProps = (state) => {\n return {\n loading: state.AuthReducer.loading,\n };\n};\nexport default connect(mapStateToProps)(Login);\n"],"names":["Spinner","_jsx","Spin","indicator","LoadingOutlined","style","fontSize","color","spin","_ref","text","onClick","isLoading","children","className","paddingTop","type","value","connect","state","loading","AuthReducer","props","dispatch","useDispatch","navigate","useNavigate","pathname","useLocation","logo","setLogo","useState","collcode","setCollCode","userName","setUserName","password","setPassword","passwordOpen","setPasswordOpen","useEffect","addcl","this","parentNode","classList","add","remcl","parent","remove","document","querySelectorAll","forEach","input","addEventListener","setUrl","console","log","univcode","Logo_098","localStorage","setItem","title","getItem","split","getElementById","innerHTML","changeHandler","name","_jsxs","src","maxLength","onChange","e","target","id","position","right","top","class","Button","async","preventDefault","userObj","user","loginUser","Login"],"sourceRoot":""}
|