-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy path.eslintcache
1 lines (1 loc) · 30.7 KB
/
.eslintcache
1
[{"/media/mubashir/Data 1/Xord-Work/web3-dapp/client-wallet/src/reportWebVitals.js":"1","/media/mubashir/Data 1/Xord-Work/web3-dapp/client-wallet/src/App.js":"2","/media/mubashir/Data 1/Xord-Work/web3-dapp/client-wallet/src/components/Form.js":"3","/media/mubashir/Data 1/Xord-Work/web3-dapp/client-wallet/src/index.js":"4","/media/mubashir/Data 1/Xord-Work/web3-dapp/client-wallet/src/components/Header.js":"5","/media/mubashir/Data 1/Xord-Work/web3-dapp/client-wallet/src/Step1.js":"6","/media/mubashir/Data 1/Xord-Work/web3-dapp/client-wallet/src/components/PrimaryButton.js":"7","/media/mubashir/Data 1/Xord-Work/web3-dapp/client-wallet/src/Step2.js":"8","/media/mubashir/Data 1/Xord-Work/web3-dapp/client-wallet/src/components/Input.js":"9","/media/mubashir/Data 1/Xord-Work/web3-dapp/client-wallet/src/components/MainContainer.js":"10","/media/mubashir/Data 1/Xord-Work/web3-dapp/client-wallet/src/DataContext.js":"11","/media/mubashir/Data 1/Xord-Work/web3-dapp/client-wallet/src/Result.js":"12","/media/mubashir/Data 1/Xord-Work/web3-dapp/client-wallet/src/components/AbiData.js":"13","/media/mubashir/Data 1/Xord-Work/web3-dapp/client-wallet/src/components/DropDown.js":"14"},{"size":362,"mtime":1609835989824,"results":"15","hashOfConfig":"16"},{"size":1423,"mtime":1610396597922,"results":"17","hashOfConfig":"16"},{"size":389,"mtime":1610360762331,"results":"18","hashOfConfig":"16"},{"size":586,"mtime":1610021725065,"results":"19","hashOfConfig":"16"},{"size":548,"mtime":1610006007142,"results":"20","hashOfConfig":"16"},{"size":2046,"mtime":1610718689740,"results":"21","hashOfConfig":"16"},{"size":550,"mtime":1610361718623,"results":"22","hashOfConfig":"16"},{"size":2879,"mtime":1611147673791,"results":"23","hashOfConfig":"16"},{"size":306,"mtime":1610023784149,"results":"24","hashOfConfig":"16"},{"size":564,"mtime":1610142927026,"results":"25","hashOfConfig":"16"},{"size":483,"mtime":1610021636969,"results":"26","hashOfConfig":"16"},{"size":8569,"mtime":1610957803357,"results":"27","hashOfConfig":"16"},{"size":4929,"mtime":1610194714469,"results":"28","hashOfConfig":"16"},{"size":7133,"mtime":1611237345336,"results":"29","hashOfConfig":"16"},{"filePath":"30","messages":"31","errorCount":0,"warningCount":0,"fixableErrorCount":0,"fixableWarningCount":0,"usedDeprecatedRules":"32"},"49ipc",{"filePath":"33","messages":"34","errorCount":0,"warningCount":4,"fixableErrorCount":0,"fixableWarningCount":0,"source":"35","usedDeprecatedRules":"36"},{"filePath":"37","messages":"38","errorCount":0,"warningCount":0,"fixableErrorCount":0,"fixableWarningCount":0,"usedDeprecatedRules":"39"},{"filePath":"40","messages":"41","errorCount":0,"warningCount":0,"fixableErrorCount":0,"fixableWarningCount":0,"usedDeprecatedRules":"42"},{"filePath":"43","messages":"44","errorCount":0,"warningCount":0,"fixableErrorCount":0,"fixableWarningCount":0,"usedDeprecatedRules":"42"},{"filePath":"45","messages":"46","errorCount":0,"warningCount":5,"fixableErrorCount":0,"fixableWarningCount":0,"source":"47","usedDeprecatedRules":"48"},{"filePath":"49","messages":"50","errorCount":0,"warningCount":0,"fixableErrorCount":0,"fixableWarningCount":0,"usedDeprecatedRules":"42"},{"filePath":"51","messages":"52","errorCount":0,"warningCount":1,"fixableErrorCount":0,"fixableWarningCount":0,"source":null},{"filePath":"53","messages":"54","errorCount":0,"warningCount":0,"fixableErrorCount":0,"fixableWarningCount":0,"usedDeprecatedRules":"55"},{"filePath":"56","messages":"57","errorCount":0,"warningCount":0,"fixableErrorCount":0,"fixableWarningCount":0,"usedDeprecatedRules":"48"},{"filePath":"58","messages":"59","errorCount":0,"warningCount":0,"fixableErrorCount":0,"fixableWarningCount":0,"usedDeprecatedRules":"60"},{"filePath":"61","messages":"62","errorCount":0,"warningCount":12,"fixableErrorCount":0,"fixableWarningCount":0,"source":"63","usedDeprecatedRules":"39"},{"filePath":"64","messages":"65","errorCount":0,"warningCount":0,"fixableErrorCount":0,"fixableWarningCount":0},{"filePath":"66","messages":"67","errorCount":0,"warningCount":4,"fixableErrorCount":0,"fixableWarningCount":0,"source":"68"},"/media/mubashir/Data 1/Xord-Work/web3-dapp/client-wallet/src/reportWebVitals.js",[],["69","70"],"/media/mubashir/Data 1/Xord-Work/web3-dapp/client-wallet/src/App.js",["71","72","73","74"],"import React, { useState, useEffect } from \"react\";\nimport { useForm } from \"react-hook-form\";\nimport { Header } from \"./components/Header\";\nimport { Step1 } from \"./Step1\";\nimport { Step2 } from \"./Step2\";\nimport { Result } from \"./Result\";\nimport { BrowserRouter as Router, Route, Switch } from \"react-router-dom\";\n//import Web3Modal from \"web3modal\";\nimport Web3 from \"web3\";\n\nfunction App() {\n //const [addr, setAddr] = useState(\"\");\n //const [balance, setBalance] = useState(\"0\");\n //const [amount, setAmount] = useState(0);\n //const [receiverAddr, setReceiever] = useState(\"\");\n //const [gasPrice, setGasPrice] = useState(0);\n\n //const onSubmitForm = (data) => {\n // console.log(data);\n // setReceiever(data.receiver);\n // setGasPrice(data.gasPrice);\n // setAmount(data.amount);\n\n //};\n\n //const loadBlockChainData = async () => {\n\n // let accountAddress = await web3.eth.getAccounts();\n // setAddr(accountAddress[0]);\n //};\n\n //const getBalance = async () => {\n // console.log(addr);\n // let bal = await web3.eth.getBalance(addr);\n // setBalance(web3.utils.fromWei(bal));\n //};\n\n return (\n <>\n <Header />\n <Router>\n <Switch>\n <Route exact path=\"/\" component={Step1} />\n <Route exact path=\"/step2\" component={Step2} />\n <Route exact path=\"/result\" component={Result} />\n </Switch>\n </Router>\n </>\n );\n}\n\nexport default App;\n",["75","76"],"/media/mubashir/Data 1/Xord-Work/web3-dapp/client-wallet/src/components/Form.js",[],["77","78"],"/media/mubashir/Data 1/Xord-Work/web3-dapp/client-wallet/src/index.js",[],["79","80"],"/media/mubashir/Data 1/Xord-Work/web3-dapp/client-wallet/src/components/Header.js",[],"/media/mubashir/Data 1/Xord-Work/web3-dapp/client-wallet/src/Step1.js",["81","82","83","84","85"],"import React, { useState, useEffect } from \"react\";\nimport { useForm } from \"react-hook-form\";\nimport { useHistory } from \"react-router-dom\";\nimport { MainContainer } from \"./components/MainContainer\";\nimport { Form } from \"./components/Form\";\nimport { Input } from \"./components/Input\";\nimport { PrimaryButton } from \"./components/PrimaryButton\";\n\nimport { InputLabel, Typography, MenuItem, Select } from \"@material-ui/core\";\nimport * as yup from \"yup\";\nimport { useData } from \"./DataContext\";\nimport { yupResolver } from \"@hookform/resolvers/yup\";\nconst schema = yup.object().shape({\n receiverAddress: yup\n .string()\n .matches(/^0x[a-fA-F0-9]{40}$/, \"Address should start with 0x\")\n .required(\"Receiver address is required to proceed with transaction\"),\n amount: yup\n .string()\n .matches(/^(?=.)([+-]?([0-9]*)(\\.([0-9]+))?)$/, \"It should be a number\")\n .required(\"Empty field not allowed\"),\n});\nexport const Step1 = () => {\n const { setValues, data } = useData();\n const { register, handleSubmit, errors } = useForm({\n defaultValues: {\n receiverAddress: data.receiverAddress,\n amount: data.amount,\n },\n mode: \"onBlur\",\n resolver: yupResolver(schema),\n });\n const history = useHistory();\n\n const onSubmit = (data) => {\n setValues(data);\n data[\"dropDownValue\"] = 0;\n history.push(\"/step2\");\n };\n return (\n <MainContainer>\n <Typography component=\"h2\" variant=\"h5\">\n Step 1\n </Typography>\n <Form onSubmit={handleSubmit(onSubmit)}>\n <Input\n ref={register}\n name=\"receiverAddress\"\n type=\"text\"\n label=\"Receiver Address\"\n error={!!errors.receiverAddress}\n helperText={errors?.receiverAddress?.message}\n />\n <Input\n ref={register}\n name=\"amount\"\n type=\"number\"\n label=\"Amount\"\n error={!!errors.amount}\n helperText={errors?.amount?.message}\n />\n\n <PrimaryButton>Next</PrimaryButton>\n </Form>\n </MainContainer>\n );\n};\n",["86","87"],"/media/mubashir/Data 1/Xord-Work/web3-dapp/client-wallet/src/components/PrimaryButton.js",[],"/media/mubashir/Data 1/Xord-Work/web3-dapp/client-wallet/src/Step2.js",["88"],"/media/mubashir/Data 1/Xord-Work/web3-dapp/client-wallet/src/components/Input.js",[],["89","90"],"/media/mubashir/Data 1/Xord-Work/web3-dapp/client-wallet/src/components/MainContainer.js",[],"/media/mubashir/Data 1/Xord-Work/web3-dapp/client-wallet/src/DataContext.js",[],["91","92"],"/media/mubashir/Data 1/Xord-Work/web3-dapp/client-wallet/src/Result.js",["93","94","95","96","97","98","99","100","101","102","103","104"],"import React, { useState, useEffect } from \"react\";\nimport { Link } from \"react-router-dom\";\nimport { useData } from \"./DataContext\";\nimport { ABI } from \"./components/AbiData\";\nimport { makeStyles } from \"@material-ui/core/styles\";\nimport Swal from \"sweetalert2\";\nimport { useHistory } from \"react-router-dom\";\nimport Web3 from \"web3\";\nimport {\n TableContainer,\n Paper,\n Table,\n TableHead,\n TableRow,\n TableCell,\n TableBody,\n CircularProgress,\n} from \"@material-ui/core\";\nimport { MainContainer } from \"./components/MainContainer\";\nimport Typography from \"@material-ui/core/Typography\";\nimport { PrimaryButton } from \"./components/PrimaryButton\";\nimport { DropDown } from \"./components/DropDown\";\nconst useStyles = makeStyles({\n root: {\n marginBottom: \"20px\",\n },\n table: {\n marginBottom: \"5px\",\n },\n});\n\nexport const Result = () => {\n let history = useHistory();\n const [addr, setAddr] = useState(\"\");\n const [balance, setBalance] = useState(\"0\");\n const [amount, setAmount] = useState(0);\n const styles = useStyles();\n\n const [gasPrice, setGasPrice] = useState(0);\n const [txProgress, setTxProgress] = useState(false);\n const [status, setStatus] = useState(true);\n\n let { setValues, data } = useData();\n useEffect(() => {\n if (data[\"amount\"] === undefined) {\n history.push(\"./\");\n }\n if (data[\"addr\"] !== \"\") {\n getBalance();\n }\n }, [addr, balance]);\n\n const getBalance = async () => {\n console.log(\"ADDRESS\", data[\"addr\"]);\n console.log(\"WEB##3\", data[\"web3\"]);\n\n try {\n let bal = await data[\"web3\"].eth.getBalance(data[\"addr\"]);\n setBalance(data[\"web3\"].utils.fromWei(bal));\n } catch (err) {\n console.log(\"ERROR\", err.message);\n if (data[\"web3\"] === undefined) {\n history.push(\"./\");\n }\n }\n };\n\n //const Transaction = async (addr, entries) => {\n // try {\n // let contractAddress = \"0x6c06c109b3585fe4D1EC4339dDD08514fb54B5D5\";\n // let contract = await new web3.eth.Contract(ABI, contractAddress, {\n // from: addr, // default from address\n // gasPrice: \"10000000000\",\n // });\n // console.log(contract);\n // let abiData = await contract.methods.transfer(\n // \"0x43D964B802c2Ce187653F6A01D6678E6cA0DC9Bb\",\n // web3.utils.toWei(\"2\")\n // );\n\n // console.log(abiData);\n\n // let txObject = {\n // from: addr,\n // to: contractAddress,\n // data: abiData,\n // };\n\n // try {\n // web3.eth\n // .sendTransaction(txObject)\n // .then((receipt) => {\n // console.log(receipt);\n // Swal.fire(\n // \"Transaction successfull!\",\n // `You've sent ${entries[1][1]} ETH to ${entries[0][1]}.`\n // );\n // Swal.update({\n // icon: \"success\",\n // });\n // })\n // .catch((err) => {\n // console.log(err.message);\n // console.log(err.message);\n // Swal.fire(\"Transaction Failed!\", `${err}`);\n // Swal.update({\n // icon: \"error\",\n // });\n // });\n // } catch (err) {\n // Swal.fire(\"Transaction Failed!\", `${err}`);\n // Swal.update({\n // icon: \"error\",\n // });\n // console.log(err);\n // }\n // } catch (err) {\n // console.log(err);\n // }\n // //});\n //};\n\n //const open = async (addr, toAddr, amount) => {\n // let contractAddress = \"0x6c06c109b3585fe4D1EC4339dDD08514fb54B5D5\";\n\n // let contract = await new web3.eth.Contract(ABI, contractAddress);\n // setTxProgress(true);\n // const tx = await contract.methods\n // .transfer(toAddr, web3.utils.toWei(amount, \"ether\"))\n // .send({ from: addr })\n // .on(\"transactionHash\", (hash) => {\n // console.log(hash);\n // })\n // .on(\"confirmation\", function (confirmationNumber, receipt) {\n // if (confirmationNumber === 2) {\n // console.log(receipt);\n // console.log(\"Confirmed\");\n // Swal.fire(\n // \"Transaction successfull!\",\n // `You've sent ${entries[1][1]} XIO to ${entries[0][1]}.`\n // );\n // Swal.update({\n // icon: \"success\",\n // });\n // setTxProgress(false);\n // }\n // })\n // .on(\"error\", (err) => {\n // console.log(\"Cancelled\");\n // Swal.fire(\"Transaction Failed!\", `${err.message}`);\n // Swal.update({\n // icon: \"error\",\n // });\n // });\n\n //const value = await (await temp)?.methods\n // .updateProposalStatus(id, status)\n // .send({ from: fromAccount })\n // .on(\"transactionHash\", (hash) => {\n // console.log(hash);\n // })\n // .on(\"confirmation\", function (confirmationNumber, receipt) {\n // if (confirmationNumber === 2) {\n // console.log(receipt);\n // console.log(\"Confirmed\");\n // }\n // })\n // .on(\"error\", () => {\n // console.log(\"Cancelled\");\n // setMetaMaskRejectError(true);\n // props.close();\n // });\n //};\n\n const opeEth = async (addr, toAdd, val) => {\n let toWei = data[\"web3\"].utils.toWei(val.toString());\n const transactionParameters = {\n gasPrice: data[\"web3\"].utils.toHex(\"10000000000\"),\n to: toAdd, // Required except during contract publications.\n from: addr, // must match user's active address.\n value: data[\"web3\"].utils.toHex(toWei), // Only required to send ether to the recipient from the initiating external account.\n chainId: 3,\n };\n\n console.log(\"value ----> \", transactionParameters.value);\n let web3 = data[\"web3\"];\n setTxProgress(true);\n window.ethereum = web3;\n const txHash = web3.eth\n .sendTransaction(transactionParameters)\n .then(async (err, txHash) => {\n console.log(\"HELLOOOO\", txHash);\n setTxProgress(false);\n await getBalance();\n Swal.fire(\n \"Transaction successfull!\",\n `You've sent ${entries[1][1]} ETH to ${entries[0][1]}.`\n );\n Swal.update({\n icon: \"success\",\n });\n })\n .catch((err) => {\n setTxProgress(false);\n console.log(\"ERRR\");\n });\n //const txHash = await window.ethereum.request({\n // method: \"eth_sendTransaction\",\n // params: [transactionParameters],\n //});\n\n //if (txHash) {\n // Swal.fire(\n // \"Transaction successfull!\",\n // `You've sent ${entries[1][1]} ETH to ${entries[0][1]}.`\n // );\n // Swal.update({\n // icon: \"success\",\n // });\n //} else {\n //}\n };\n\n var entries = Object.entries(data).filter((entry) => entry[0] !== \"files\");\n\n const onSubmit = async () => {\n try {\n entries = Object.entries(data).filter((entry) => entry[0] !== \"files\");\n console.log(entries);\n //await open(\n // data[\"addr\"],\n // data[\"receiverAddress\"],\n // entries[1][1].toString()\n //);\n await opeEth(data[\"addr\"], data[\"receiverAddress\"], entries[1][1]);\n } catch (err) {\n console.log(\"ERROR: \", err.message);\n }\n };\n\n const handleLink = () => {\n console.log(\"INSIDE HANDLE LINK\");\n data[\"dropDownValue\"] = 0;\n setValues(data);\n history.push(\"./\");\n };\n\n return (\n <MainContainer>\n <Typography component=\"h2\" variant=\"h5\">\n Pre-Transaction Details\n </Typography>\n <TableContainer className={styles.root} component={Paper}>\n <Table className={styles.table}>\n <TableHead>\n <TableRow>\n <TableCell>Field</TableCell>\n <TableCell align=\"left\">Value</TableCell>\n </TableRow>\n </TableHead>\n <TableBody>\n <TableRow>\n <TableCell>Your Wallet Address</TableCell>\n <TableCell>{data[\"addr\"]}</TableCell>\n </TableRow>\n <TableRow>\n <TableCell>Reciever Address</TableCell>\n <TableCell>{data[\"receiverAddress\"]}</TableCell>\n </TableRow>\n <TableRow>\n <TableCell>Amount</TableCell>\n <TableCell>{data[\"amount\"]}</TableCell>\n </TableRow>\n <TableRow>\n <TableCell>Your Current Balance</TableCell>\n <TableCell>{balance.toString()} ETH</TableCell>\n </TableRow>\n </TableBody>\n </Table>\n </TableContainer>\n {!txProgress ? (\n <>\n <PrimaryButton onClick={onSubmit}>Checkout</PrimaryButton>\n\n <Link onClick={handleLink}>Make another transaction</Link>\n </>\n ) : (\n <CircularProgress />\n )}\n </MainContainer>\n );\n};\n","/media/mubashir/Data 1/Xord-Work/web3-dapp/client-wallet/src/components/AbiData.js",[],"/media/mubashir/Data 1/Xord-Work/web3-dapp/client-wallet/src/components/DropDown.js",["105","106","107","108"],"import React, { useState, useEffect } from \"react\";\nimport { FormControl, InputLabel, Select, MenuItem } from \"@material-ui/core\";\nimport { PrimaryButton } from \"./PrimaryButton\";\nimport { makeStyles } from \"@material-ui/core/styles\";\nimport { useData } from \"../DataContext\";\nimport { useForm } from \"react-hook-form\";\nimport Web3 from \"web3\";\nimport Portis from \"@portis/web3\";\nimport metamasklogo from \"./METAMASK.png\";\nimport fortmaticLogo from \"./fortmatic.png\";\nimport portislogo from \"./PORTIS.png\";\nimport walletconnectlogo from \"./WALLETCONNECT.png\";\nimport Swal from \"sweetalert2\";\nimport coinbaselogo from \"./COINBASE.png\";\nimport WalletConnectProvider from \"@walletconnect/web3-provider\";\n\nimport Fortmatic from \"fortmatic\";\n\nconst useStyles = makeStyles((theme) => ({\n root: {\n width: \"100%\",\n marginTop: theme.spacing(1),\n },\n dropDown: {\n justifyContent: \"center\",\n },\n}));\n\nexport const DropDown = () => {\n const [status, setStatus] = useState(true);\n\n const [dropDownValue, setDropDownValue] = useState(\"\");\n const { setValues, data } = useData();\n useEffect(() => {\n if (dropDownValue !== \"\") {\n //getDropDownValue(data);\n setStatus(false);\n }\n }, [dropDownValue]);\n const { register } = useForm({\n defaultValues: {\n dropDownValue: data.dropDownValue,\n },\n mode: \"onBlur\",\n });\n\n const styles = useStyles();\n const handleChange = async (e) => {\n if (e.target.value === 0) {\n data[\"dropDownValue\"] = e.target.value;\n setValues(data);\n } else if (e.target.value === 1) {\n let web3 = new Web3(\n Web3.givenProvider ||\n \"https://ropsten.infura.io/v3/4d39325e4c914146b733ef5b792ab2a0\"\n );\n window.web3 = web3;\n try {\n await window.ethereum.enable();\n const account = await web3.eth.getAccounts();\n console.log(account[0]);\n console.log(\n \"BALANCE \",\n await web3.eth.getBalance(account[0].toString())\n );\n data[\"addr\"] = account[0];\n data[\"dropDownValue\"] = e.target.value;\n data[\"web3\"] = web3;\n setValues(data);\n } catch (err) {\n console.log(\"ERROR:HEHE\", err.message);\n if (err.message.includes(\" 'enable' of undefined\")) {\n Swal.fire(\n \"METAMASK ERROR!\",\n \"PLEASE INSTALL OR ENABLE METAMASK ON YOUR BROWSER\"\n );\n Swal.update({\n icon: \"error\",\n });\n data[\"dropDownValue\"] = 0;\n setValues(data);\n }\n }\n } else if (e.target.value === 2) {\n const provider = new WalletConnectProvider({\n infuraId: \"4d39325e4c914146b733ef5b792ab2a0\", // Required\n });\n try {\n await provider.enable();\n\n const web3 = new Web3(provider);\n\n const account = await web3.eth.getAccounts();\n\n console.log(\"WALLET CONNECT ACCOUNT\", account[0]);\n\n console.log(\n \"BALANCE \",\n await web3.eth.getBalance(account[0].toString())\n );\n data[\"addr\"] = account[0];\n data[\"dropDownValue\"] = e.target.value;\n data[\"web3\"] = web3;\n setValues(data);\n } catch (err) {\n console.log(err.message);\n }\n } else if (e.target.value === 3) {\n const portis = new Portis(\n \"44b187a3-c957-4ab6-9c74-64e7133a14d7\",\n \"ropsten\"\n );\n const web3 = new Web3(portis.provider);\n\n window.web3 = web3;\n //await window.ethereum.enable();\n const account = await web3.eth.getAccounts();\n console.log(account[0]);\n console.log(\"BALANCE \", await web3.eth.getBalance(account[0].toString()));\n data[\"addr\"] = account[0];\n data[\"dropDownValue\"] = e.target.value;\n data[\"web3\"] = web3;\n console.log(\"WEB##3\", data[\"web3\"]);\n\n setValues(data);\n } else if (e.target.value === 4) {\n let fm = new Fortmatic(\"pk_test_66779BFC53FD0766\", \"ropsten\", 3);\n try {\n let web3 = new Web3(await fm.getProvider());\n try {\n await web3.eth.getAccounts(async (err, accounts) => {\n if (err) console.log(\"ERROR: \", err);\n console.log(\"FORTMATIC \", accounts[0]);\n console.log(\n \"BALANCE \",\n await web3.eth.getBalance(accounts[0].toString())\n );\n data[\"addr\"] = accounts[0];\n data[\"dropDownValue\"] = e.target.value;\n data[\"web3\"] = web3;\n setValues(data);\n });\n } catch (err) {\n console.log(\"OOPS SOMETHING BAD HAPPENED\");\n }\n } catch (err) {\n console.log(err.message);\n }\n } else if (e.target.value === 5) {\n console.log(\"COINBASE\");\n let web3 = new Web3(\n Web3.givenProvider ||\n \"https://ropsten.infura.io/v3/4d39325e4c914146b733ef5b792ab2a0\"\n );\n\n try {\n let address = await web3.eth.getCoinbase();\n console.log(\"ADDRESS\", address);\n let balance = await web3.eth.getBalance(address);\n console.log(\"BALANCE\", balance);\n data[\"addr\"] = address;\n data[\"dropDownValue\"] = e.target.value;\n data[\"web3\"] = web3;\n setValues(data);\n } catch (err) {\n console.log(err.message);\n }\n }\n };\n\n const handleWallet = async (e) => {\n console.log(\"INSIDE\", e.target.value);\n };\n return (\n <>\n <FormControl className={styles.root}>\n <InputLabel className={styles.dropDown}>Connect Wallet</InputLabel>\n <Select\n className={styles.dropDown}\n name=\"dropDownValue\"\n ref={register}\n onChange={handleChange}\n defaultValue={0}\n >\n <MenuItem className={styles.dropDown} value={0}>\n <strong>Select a wallet</strong>\n </MenuItem>\n <MenuItem className={styles.dropDown} value={1}>\n <img\n src={metamasklogo}\n alt=\"logo\"\n width=\"30\"\n style={{ marginRight: \"5px\" }}\n />\n MetaMask\n </MenuItem>\n <MenuItem className={styles.dropDown} value={2}>\n <img\n src={walletconnectlogo}\n alt=\"logo\"\n style={{ marginRight: \"5px\" }}\n width=\"30\"\n />\n WalletConnect\n </MenuItem>\n <MenuItem className={styles.dropDown} value={3}>\n <img\n src={portislogo}\n alt=\"logo\"\n style={{ marginRight: \"5px\" }}\n width=\"30\"\n />\n Portis\n </MenuItem>\n <MenuItem className={styles.dropDown} value={4}>\n <img\n src={fortmaticLogo}\n alt=\"logo\"\n style={{ marginRight: \"5px\" }}\n width=\"30\"\n />\n Fortmatic\n </MenuItem>\n <MenuItem className={styles.dropDown} value={5}>\n <img\n src={coinbaselogo}\n alt=\"logo\"\n style={{ marginRight: \"5px\" }}\n width=\"30\"\n />\n Coinbase\n </MenuItem>\n </Select>\n </FormControl>\n </>\n );\n};\n",{"ruleId":"109","replacedBy":"110"},{"ruleId":"111","replacedBy":"112"},{"ruleId":"113","severity":1,"message":"114","line":1,"column":17,"nodeType":"115","messageId":"116","endLine":1,"endColumn":25},{"ruleId":"113","severity":1,"message":"117","line":1,"column":27,"nodeType":"115","messageId":"116","endLine":1,"endColumn":36},{"ruleId":"113","severity":1,"message":"118","line":2,"column":10,"nodeType":"115","messageId":"116","endLine":2,"endColumn":17},{"ruleId":"113","severity":1,"message":"119","line":9,"column":8,"nodeType":"115","messageId":"116","endLine":9,"endColumn":12},{"ruleId":"109","replacedBy":"120"},{"ruleId":"111","replacedBy":"121"},{"ruleId":"109","replacedBy":"122"},{"ruleId":"111","replacedBy":"123"},{"ruleId":"109","replacedBy":"124"},{"ruleId":"111","replacedBy":"125"},{"ruleId":"113","severity":1,"message":"114","line":1,"column":17,"nodeType":"115","messageId":"116","endLine":1,"endColumn":25},{"ruleId":"113","severity":1,"message":"117","line":1,"column":27,"nodeType":"115","messageId":"116","endLine":1,"endColumn":36},{"ruleId":"113","severity":1,"message":"126","line":9,"column":10,"nodeType":"115","messageId":"116","endLine":9,"endColumn":20},{"ruleId":"113","severity":1,"message":"127","line":9,"column":34,"nodeType":"115","messageId":"116","endLine":9,"endColumn":42},{"ruleId":"113","severity":1,"message":"128","line":9,"column":44,"nodeType":"115","messageId":"116","endLine":9,"endColumn":50},{"ruleId":"109","replacedBy":"129"},{"ruleId":"111","replacedBy":"130"},{"ruleId":"131","severity":1,"message":"132","line":31,"column":6,"nodeType":"133","endLine":31,"endColumn":12,"suggestions":"134"},{"ruleId":"109","replacedBy":"135"},{"ruleId":"111","replacedBy":"136"},{"ruleId":"109","replacedBy":"137"},{"ruleId":"111","replacedBy":"138"},{"ruleId":"113","severity":1,"message":"139","line":4,"column":10,"nodeType":"115","messageId":"116","endLine":4,"endColumn":13},{"ruleId":"113","severity":1,"message":"119","line":8,"column":8,"nodeType":"115","messageId":"116","endLine":8,"endColumn":12},{"ruleId":"113","severity":1,"message":"140","line":22,"column":10,"nodeType":"115","messageId":"116","endLine":22,"endColumn":18},{"ruleId":"113","severity":1,"message":"141","line":34,"column":16,"nodeType":"115","messageId":"116","endLine":34,"endColumn":23},{"ruleId":"113","severity":1,"message":"142","line":36,"column":10,"nodeType":"115","messageId":"116","endLine":36,"endColumn":16},{"ruleId":"113","severity":1,"message":"143","line":36,"column":18,"nodeType":"115","messageId":"116","endLine":36,"endColumn":27},{"ruleId":"113","severity":1,"message":"144","line":39,"column":10,"nodeType":"115","messageId":"116","endLine":39,"endColumn":18},{"ruleId":"113","severity":1,"message":"145","line":39,"column":20,"nodeType":"115","messageId":"116","endLine":39,"endColumn":31},{"ruleId":"113","severity":1,"message":"146","line":41,"column":10,"nodeType":"115","messageId":"116","endLine":41,"endColumn":16},{"ruleId":"113","severity":1,"message":"147","line":41,"column":18,"nodeType":"115","messageId":"116","endLine":41,"endColumn":27},{"ruleId":"131","severity":1,"message":"148","line":51,"column":6,"nodeType":"133","endLine":51,"endColumn":21,"suggestions":"149"},{"ruleId":"113","severity":1,"message":"150","line":189,"column":11,"nodeType":"115","messageId":"116","endLine":189,"endColumn":17},{"ruleId":"113","severity":1,"message":"151","line":3,"column":10,"nodeType":"115","messageId":"116","endLine":3,"endColumn":23},{"ruleId":"113","severity":1,"message":"146","line":30,"column":10,"nodeType":"115","messageId":"116","endLine":30,"endColumn":16},{"ruleId":"113","severity":1,"message":"152","line":32,"column":25,"nodeType":"115","messageId":"116","endLine":32,"endColumn":41},{"ruleId":"113","severity":1,"message":"153","line":171,"column":9,"nodeType":"115","messageId":"116","endLine":171,"endColumn":21},"no-native-reassign",["154"],"no-negated-in-lhs",["155"],"no-unused-vars","'useState' is defined but never used.","Identifier","unusedVar","'useEffect' is defined but never used.","'useForm' is defined but never used.","'Web3' is defined but never used.",["154"],["155"],["154"],["155"],["154"],["155"],"'InputLabel' is defined but never used.","'MenuItem' is defined but never used.","'Select' is defined but never used.",["154"],["155"],"react-hooks/exhaustive-deps","React Hook useEffect has a missing dependency: 'history'. Either include it or remove the dependency array.","ArrayExpression",["156"],["154"],["155"],["154"],["155"],"'ABI' is defined but never used.","'DropDown' is defined but never used.","'setAddr' is assigned a value but never used.","'amount' is assigned a value but never used.","'setAmount' is assigned a value but never used.","'gasPrice' is assigned a value but never used.","'setGasPrice' is assigned a value but never used.","'status' is assigned a value but never used.","'setStatus' is assigned a value but never used.","React Hook useEffect has missing dependencies: 'data', 'getBalance', and 'history'. Either include them or remove the dependency array.",["157"],"'txHash' is assigned a value but never used.","'PrimaryButton' is defined but never used.","'setDropDownValue' is assigned a value but never used.","'handleWallet' is assigned a value but never used.","no-global-assign","no-unsafe-negation",{"desc":"158","fix":"159"},{"desc":"160","fix":"161"},"Update the dependencies array to be: [data, history]",{"range":"162","text":"163"},"Update the dependencies array to be: [addr, balance, data, getBalance, history]",{"range":"164","text":"165"},[1139,1145],"[data, history]",[1387,1402],"[addr, balance, data, getBalance, history]"]