diff options
author | rohan09-raj <[email protected]> | 2022-07-28 17:56:15 +0530 |
---|---|---|
committer | rohan09-raj <[email protected]> | 2022-07-28 17:56:15 +0530 |
commit | 49be4dfc3d478ad02876c9238c48c513edac1e7c (patch) | |
tree | b79c0bd1c2cb1582df0d03e88e4d03d097e9f0a0 /src | |
parent | ffefbc1c2a382597c6d9f90977f8c907e26fbe2e (diff) |
refactoring folder structure
Diffstat (limited to 'src')
35 files changed, 0 insertions, 692 deletions
diff --git a/src/App.js b/src/App.js deleted file mode 100644 index c39f14e..0000000 --- a/src/App.js +++ /dev/null @@ -1,12 +0,0 @@ -import React from 'react' -import Index from './routes' - -const App = () => { - return ( - <> - <Index /> - </> - ) -} - -export default App diff --git a/src/components/Card/Card.jsx b/src/components/Card/Card.jsx deleted file mode 100644 index 3d66067..0000000 --- a/src/components/Card/Card.jsx +++ /dev/null @@ -1,13 +0,0 @@ -import React from 'react' -import styles from './Card.module.css' - -const Card = ({ title, image }) => { - return ( - <div className={styles.card}> - <img className={styles.card__image} src={image} alt="" /> - <h2 className={styles.card__title}>{title}</h2> - </div> - ) -} - -export default Card diff --git a/src/components/Card/Card.module.css b/src/components/Card/Card.module.css deleted file mode 100644 index e351fd5..0000000 --- a/src/components/Card/Card.module.css +++ /dev/null @@ -1,26 +0,0 @@ -@import '../../styles/GlobalVariables.css'; - -.card { - height: 300px; - width: 300px; - display: flex; - flex-direction: column; - justify-content: center; - align-items: center; - border: 3px solid var(--color-black); - border-radius: 10px; - margin: 30px; - transition: 0.2s all; - cursor: pointer; - color: var(--color-black); - text-decoration-line: none; -} - -.card:active { - transform: scale(0.98); - box-shadow: 3px 2px 22px 1px var(--color-shadow); -} - -.card__title { - margin: 15px 0px; -} diff --git a/src/components/Card/CardScanner.jsx b/src/components/Card/CardScanner.jsx deleted file mode 100644 index 29caf39..0000000 --- a/src/components/Card/CardScanner.jsx +++ /dev/null @@ -1,16 +0,0 @@ -import React from 'react' -import styles from './CardScanner.module.css' -import SubmitButton from '../SubmitButton/SubmitButton' - -const CardScanner = ({ title, image }) => { - return ( - <> - <div className={styles.card}> - <img className={styles.card__image} src={image} alt="" /> - </div> - <SubmitButton /> - </> - ) -} - -export default CardScanner diff --git a/src/components/Card/CardScanner.module.css b/src/components/Card/CardScanner.module.css deleted file mode 100644 index af237e2..0000000 --- a/src/components/Card/CardScanner.module.css +++ /dev/null @@ -1,26 +0,0 @@ -@import '../../styles/GlobalVariables.css'; - -.card { - height: 300px; - width: 600px; - display: flex; - flex-direction: column; - justify-content: center; - align-items: center; - border: 3px solid var(--color-black); - border-radius: 10px; - margin: 30px; - transition: 0.2s all; - cursor: pointer; - color: var(--color-black); - text-decoration-line: none; -} - -.card:active { - transform: scale(0.98); - box-shadow: 3px 2px 22px 1px var(--color-shadow); -} - -.card__title { - margin: 15px 0px; -}
\ No newline at end of file diff --git a/src/components/Header/Header.jsx b/src/components/Header/Header.jsx deleted file mode 100644 index d90aafe..0000000 --- a/src/components/Header/Header.jsx +++ /dev/null @@ -1,13 +0,0 @@ -import React from 'react' -import styles from './Header.module.css' - -const Header = ({ subheading }) => { - return ( - <header className={styles.header}> - <h1 className={styles.header__heading}>AADHAAR</h1> - <h3 className={styles.header__subheading}>{subheading}</h3> - </header> - ) -} - -export default Header diff --git a/src/components/Header/Header.module.css b/src/components/Header/Header.module.css deleted file mode 100644 index 8e6084f..0000000 --- a/src/components/Header/Header.module.css +++ /dev/null @@ -1,20 +0,0 @@ -@import '../../styles/GlobalVariables.css'; - -.header { - font-family: 'Fredoka One', cursive; - display: flex; - flex-direction: column; - align-items: center; - margin: 20px; - padding: 20px; -} - -.header__heading { - font-size: var(--font-large); - font-weight: 400; -} - -.header__subheading { - font-size: var(--font-medium); - font-weight: 400; -} diff --git a/src/components/Input/Input.jsx b/src/components/Input/Input.jsx deleted file mode 100644 index ee79f3b..0000000 --- a/src/components/Input/Input.jsx +++ /dev/null @@ -1,22 +0,0 @@ -import React from 'react' -import styles from './Input.module.css' - -const Input = ({ label, id, value, type, name }) => { - return ( - <div className={styles.input}> - <div className={styles.input__container}> - <label htmlFor={id}>{label}</label> - <input - className={styles.input__field} - type={type} - id={id} - name={name} - value={value} - required - /> - </div> - </div> - ) -} - -export default Input diff --git a/src/components/Input/Input.module.css b/src/components/Input/Input.module.css deleted file mode 100644 index cafb5f1..0000000 --- a/src/components/Input/Input.module.css +++ /dev/null @@ -1,19 +0,0 @@ -.input { - display: flex; - justify-content: center; - font-family: 'Barlow'; - font-size: var(--font-medium-s); -} - -.input__container { - display: flex; - flex-direction: column; -} - -.input__field { - width: 300px; - margin: 10px 0px; - padding: 20px 10px; - border: 3px solid; - border-radius: 10px; -} diff --git a/src/components/LabelCard/LabelCard.jsx b/src/components/LabelCard/LabelCard.jsx deleted file mode 100644 index be02f01..0000000 --- a/src/components/LabelCard/LabelCard.jsx +++ /dev/null @@ -1,23 +0,0 @@ -import React from 'react' -import styles from './LabelCard.module.css' - -const LabelCard = ({ id, name, value, title, image }) => { - return ( - <div className={styles.labelcard}> - <label htmlFor={id} className={styles.card}> - <img className={styles.card__image} src={image} alt="" /> - <h4 className={styles.card__title}>{title}</h4> - </label> - <input - className={styles.labelcard__radio} - type="radio" - id={id} - name={name} - value={value} - required - /> - </div> - ) -} - -export default LabelCard diff --git a/src/components/LabelCard/LabelCard.module.css b/src/components/LabelCard/LabelCard.module.css deleted file mode 100644 index 8511596..0000000 --- a/src/components/LabelCard/LabelCard.module.css +++ /dev/null @@ -1,19 +0,0 @@ -.labelcard { - text-align: center; -} - -.card { - display: flex; - flex-direction: column; - align-items: center; - margin: 5px; -} - -.card__image { - border: 3px solid var(--color-black); - border-radius: 10px; -} - -.card__title { - margin: 5px 0px; -} diff --git a/src/components/RadioSelect/RadioSelect.jsx b/src/components/RadioSelect/RadioSelect.jsx deleted file mode 100644 index e69de29..0000000 --- a/src/components/RadioSelect/RadioSelect.jsx +++ /dev/null diff --git a/src/components/RadioSelect/RadioSelect.module.css b/src/components/RadioSelect/RadioSelect.module.css deleted file mode 100644 index e69de29..0000000 --- a/src/components/RadioSelect/RadioSelect.module.css +++ /dev/null diff --git a/src/components/SubmitButton/SubmitButton.jsx b/src/components/SubmitButton/SubmitButton.jsx deleted file mode 100644 index 567d923..0000000 --- a/src/components/SubmitButton/SubmitButton.jsx +++ /dev/null @@ -1,18 +0,0 @@ -import React from 'react' -import styles from './SubmitButton.module.css' - -const SubmitButton = ({ onClick }) => { - return ( - <> - <button onClick={onClick} className={styles.submit}> - <img - className={styles.submit__image} - src={`${process.env.PUBLIC_URL}/assets/images/white-check.svg`} - alt="" - /> - </button> - </> - ) -} - -export default SubmitButton diff --git a/src/components/SubmitButton/SubmitButton.module.css b/src/components/SubmitButton/SubmitButton.module.css deleted file mode 100644 index bb1b015..0000000 --- a/src/components/SubmitButton/SubmitButton.module.css +++ /dev/null @@ -1,20 +0,0 @@ -.submit { - position: absolute; - bottom: 100px; - right: 150px; - background: transparent; - border: none; - border-radius: 50%; - transition: 0.2s all; - cursor: pointer; -} - -.submit:active { - transform: scale(0.98); - box-shadow: 3px 2px 22px 1px var(--color-shadow); -} - -.submit__image { - height: 75px; - width: 75px; -} diff --git a/src/index.css b/src/index.css deleted file mode 100644 index c05147c..0000000 --- a/src/index.css +++ /dev/null @@ -1,19 +0,0 @@ -* { - margin: 0; - padding: 0; -} - -body { - font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", "Roboto", "Oxygen", - "Ubuntu", "Cantarell", "Fira Sans", "Droid Sans", "Helvetica Neue", - sans-serif; - -webkit-font-smoothing: antialiased; - -moz-osx-font-smoothing: grayscale; - height: 100%; - width: 100%; -} - -code { - font-family: source-code-pro, Menlo, Monaco, Consolas, "Courier New", - monospace; -} diff --git a/src/index.js b/src/index.js deleted file mode 100644 index 08cf3d2..0000000 --- a/src/index.js +++ /dev/null @@ -1,14 +0,0 @@ -import React from 'react' -import ReactDOM from 'react-dom/client' -import { BrowserRouter } from 'react-router-dom' -import './index.css' -import App from './App' - -const root = ReactDOM.createRoot(document.getElementById('root')) -root.render( - <React.StrictMode> - <BrowserRouter> - <App /> - </BrowserRouter> - </React.StrictMode> -) diff --git a/src/pages/Enrollment/Address/Address.jsx b/src/pages/Enrollment/Address/Address.jsx deleted file mode 100644 index 6a32bcf..0000000 --- a/src/pages/Enrollment/Address/Address.jsx +++ /dev/null @@ -1,47 +0,0 @@ -import React from 'react' -import Header from '../../../components/Header/Header' -import Input from '../../../components/Input/Input' -import SubmitButton from '../../../components/SubmitButton/SubmitButton' - -import styles from './Address.module.css' - -const Address = () => { - return ( - <> - <Header subheading="Enrollment" /> - <div className={styles.address}> - <div className={styles.address__container}> - <Input - id="houseNo" - label="House Number/ Apartment" - value="house" - type="text" - /> - <Input - id="locality" - label="Area / Locality" - value="locality" - type="text" - /> - <Input id="town" label="Village / Town" value="town" type="text" /> - <Input - id="postOffice" - label="Post Office" - value="postOffice" - type="text" - /> - </div> - <div className={styles.address__container}> - <Input id="street" label="Street / Road" value="street" type="text" /> - <Input id="landmark" label="Landmark" value="landmark" type="text" /> - <Input id="district" label="District" value="district" type="text" /> - <Input id="pincode" label="Pincode" value="pincode" type="text" /> - </div> - </div> - <Input id="state" label="State" value="state" type="text" /> - <SubmitButton /> - </> - ) -} - -export default Address diff --git a/src/pages/Enrollment/Address/Address.module.css b/src/pages/Enrollment/Address/Address.module.css deleted file mode 100644 index 60958ba..0000000 --- a/src/pages/Enrollment/Address/Address.module.css +++ /dev/null @@ -1,8 +0,0 @@ -.address { - display: flex; - justify-content: center; -} - -.address__container { - margin: 0px 20px; -} diff --git a/src/pages/Enrollment/DocumentScanner/DocumentScanner.jsx b/src/pages/Enrollment/DocumentScanner/DocumentScanner.jsx deleted file mode 100644 index 1ca2558..0000000 --- a/src/pages/Enrollment/DocumentScanner/DocumentScanner.jsx +++ /dev/null @@ -1,56 +0,0 @@ -import React from 'react' -import Header from '../../../components/Header/Header' -import CardScanner from '../../../components/Card/CardScanner' -import styles from './DocumentScanner.module.css' -import { Button, Grid, Typography } from '@mui/material' -import SubmitButton from '../../../components/SubmitButton/SubmitButton' - -const DocumentScanner = () => { - return ( - <> - <Header subheading="Enrollment" /> - <div className={styles.card__container}> - <CardScanner - image={`${process.env.PUBLIC_URL}/assets/images/document.svg`} - /> - </div> - <Grid container columnSpacing={10} justifyContent="center"> - <Grid item> - <Button - color="primary" - size="large" - type="submit" - variant="contained" - > - Scan - </Button> - </Grid> - <Grid item> - <Button - color="primary" - size="large" - type="submit" - variant="contained" - > - Reset - </Button> - </Grid> - </Grid> - <br></br> - <div> - <Grid container justifyContent="center"> - <Typography align="center"> - Please place your document on the scanner. - <br /> - Close the lid. - <br /> - Wait for prompt to remove your document - </Typography> - </Grid> - </div> - <SubmitButton /> - </> - ) -} - -export default DocumentScanner diff --git a/src/pages/Enrollment/DocumentScanner/DocumentScanner.module.css b/src/pages/Enrollment/DocumentScanner/DocumentScanner.module.css deleted file mode 100644 index ec59f61..0000000 --- a/src/pages/Enrollment/DocumentScanner/DocumentScanner.module.css +++ /dev/null @@ -1,5 +0,0 @@ -.card__container { - display: flex; - justify-content: center; - } -
\ No newline at end of file diff --git a/src/pages/Enrollment/Enrollment.jsx b/src/pages/Enrollment/Enrollment.jsx deleted file mode 100644 index b8bbc81..0000000 --- a/src/pages/Enrollment/Enrollment.jsx +++ /dev/null @@ -1,16 +0,0 @@ -import React from 'react' -import Header from '../../components/Header/Header' -import SubmitButton from '../../components/SubmitButton/SubmitButton' -import FormOne from './FormOne/FormOne' - -const Enrollment = () => { - return ( - <> - <Header subheading="Enrollment" /> - <FormOne /> - <SubmitButton /> - </> - ) -} - -export default Enrollment diff --git a/src/pages/Enrollment/Enrollment.module.css b/src/pages/Enrollment/Enrollment.module.css deleted file mode 100644 index e69de29..0000000 --- a/src/pages/Enrollment/Enrollment.module.css +++ /dev/null diff --git a/src/pages/Enrollment/FormOne/FormOne.jsx b/src/pages/Enrollment/FormOne/FormOne.jsx deleted file mode 100644 index 4ba274c..0000000 --- a/src/pages/Enrollment/FormOne/FormOne.jsx +++ /dev/null @@ -1,72 +0,0 @@ -import React from 'react' -import Input from '../../../components/Input/Input' -import LabelCard from '../../../components/LabelCard/LabelCard' -import styles from './FormOne.module.css' - -const FormOne = () => { - return ( - <div className={styles.formone}> - <div className={styles.formone__radio}> - <span className={styles.formone__resident}> - <input - type="radio" - id="indian" - name="resident" - value="Indian Resident" - required - /> - <label htmlFor="indian">Indian Resident</label> - </span> - <span className={styles.formone__resident}> - <input - type="radio" - id="indian" - name="resident" - value="Indian Resident" - required - /> - <label htmlFor="indian">Non-Residential Indian</label> - </span> - </div> - - <Input type="text" id="fullName" label="Full Name" value="Full Name" /> - - <div className={styles.formone__gender}> - <LabelCard - id="male" - name="gender" - title="Male" - image={`${process.env.PUBLIC_URL}/assets/images/male.svg`} - /> - <LabelCard - id="female" - name="gender" - value="female" - title="Female" - image={`${process.env.PUBLIC_URL}/assets/images/female.svg`} - /> - <LabelCard - id="trans" - name="gender" - value="trans" - title="Transgender" - image={`${process.env.PUBLIC_URL}/assets/images/trans.svg`} - /> - </div> - - <div className={styles.formone__dob}> - <label htmlFor="dob">Date of Birth</label> - <input - className={styles.formone__dob_input} - type="date" - id="dob" - name="dob" - value="Date of Birth" - required - /> - </div> - </div> - ) -} - -export default FormOne diff --git a/src/pages/Enrollment/FormOne/FormOne.module.css b/src/pages/Enrollment/FormOne/FormOne.module.css deleted file mode 100644 index 35d1e49..0000000 --- a/src/pages/Enrollment/FormOne/FormOne.module.css +++ /dev/null @@ -1,46 +0,0 @@ -.formone { - display: flex; - flex-direction: column; - align-items: center; - font-family: 'Barlow'; - font-size: var(--font-medium-s); -} - -.formone__radio { - display: flex; - align-items: center; -} - -.formone__resident { - display: flex; - align-items: center; - margin: 15px; -} - -.formone__resident input[type='radio'] { - width: 1.5rem; - height: 1.5rem; -} - -.formone__gender { - display: flex; -} - -.formone__dob { - display: flex; - flex-direction: column; -} - -.formone__dob input[type='date']::-webkit-calendar-picker-indicator { - width: 30px; - height: 30px; - margin: 0; -} - -.formone__dob_input { - width: 300px; - margin: 10px 0px; - padding: 11px 10px; - border: 3px solid; - border-radius: 10px; -} diff --git a/src/pages/Enrollment/FormTwo/FormTwo.jsx b/src/pages/Enrollment/FormTwo/FormTwo.jsx deleted file mode 100644 index 56bcd70..0000000 --- a/src/pages/Enrollment/FormTwo/FormTwo.jsx +++ /dev/null @@ -1,17 +0,0 @@ -import React from 'react' -import Input from '../../../components/Input/Input' -import Header from '../../../components/Header/Header' -import SubmitButton from '../../../components/SubmitButton/SubmitButton' - -const FormTwo = () => { - return ( - <div className="formtwo"> - <Header subheading="Enrollment" /> - <Input id="mobile" value="Mobile" label="Mobile" type="text" /> - <Input id="email" value="Email" label="Email" type="email" /> - <SubmitButton /> - </div> - ) -} - -export default FormTwo diff --git a/src/pages/Enrollment/FormTwo/FormTwo.module.css b/src/pages/Enrollment/FormTwo/FormTwo.module.css deleted file mode 100644 index 8b13789..0000000 --- a/src/pages/Enrollment/FormTwo/FormTwo.module.css +++ /dev/null @@ -1 +0,0 @@ - diff --git a/src/pages/Enrollment/PhotoCapture/PhotoCapture.jsx b/src/pages/Enrollment/PhotoCapture/PhotoCapture.jsx deleted file mode 100644 index 0b30848..0000000 --- a/src/pages/Enrollment/PhotoCapture/PhotoCapture.jsx +++ /dev/null @@ -1,52 +0,0 @@ -import React from 'react' -import Header from '../../../components/Header/Header' -import CardScanner from '../../../components/Card/CardScanner' -import styles from './PhotoCapture.module.css' -import { Button, Grid, Typography } from '@mui/material' - -const PhotoCapture = () => { - return ( - <> - <Header subheading="Enrollment" /> - <div className={styles.card__container}> - <CardScanner - image={`${process.env.PUBLIC_URL}/assets/images/capture.svg`} - /> - </div> - <Grid container columnSpacing={10} justifyContent="center"> - <Grid item> - <Button - color="primary" - size="large" - type="submit" - variant="contained" - > - Capture - </Button> - </Grid> - <Grid item> - <Button - color="primary" - size="large" - type="submit" - variant="contained" - > - Reset - </Button> - </Grid> - </Grid> - <br></br> - <div> - <Grid container justifyContent="center"> - <Typography align="center"> - Please look into the camera<br></br> - Click Capture to Capture the photo<br></br> - Click Reset the remove the captured photo - </Typography> - </Grid> - </div> - </> - ) -} - -export default PhotoCapture diff --git a/src/pages/Enrollment/PhotoCapture/PhotoCapture.module.css b/src/pages/Enrollment/PhotoCapture/PhotoCapture.module.css deleted file mode 100644 index ec59f61..0000000 --- a/src/pages/Enrollment/PhotoCapture/PhotoCapture.module.css +++ /dev/null @@ -1,5 +0,0 @@ -.card__container { - display: flex; - justify-content: center; - } -
\ No newline at end of file diff --git a/src/pages/Home/Home.jsx b/src/pages/Home/Home.jsx deleted file mode 100644 index b132f12..0000000 --- a/src/pages/Home/Home.jsx +++ /dev/null @@ -1,30 +0,0 @@ -import React from 'react' -import { Link } from 'react-router-dom' - -import Card from '../../components/Card/Card' -import Header from '../../components/Header/Header' -import styles from './Home.module.css' - -const Home = () => { - return ( - <> - <Header subheading="Mera Aadhaar Meri Pehchan" /> - <div className={styles.card__container}> - <Link to="/enrollment"> - <Card - title="Enrollment" - image={`${process.env.PUBLIC_URL}/assets/images/enrollment.svg`} - /> - </Link> - <Link to="/update"> - <Card - title="Update" - image={`${process.env.PUBLIC_URL}/assets/images/update.svg`} - /> - </Link> - </div> - </> - ) -} - -export default Home diff --git a/src/pages/Home/Home.module.css b/src/pages/Home/Home.module.css deleted file mode 100644 index de1cead..0000000 --- a/src/pages/Home/Home.module.css +++ /dev/null @@ -1,4 +0,0 @@ -.card__container { - display: flex; - justify-content: center; -} diff --git a/src/pages/Update/Update.jsx b/src/pages/Update/Update.jsx deleted file mode 100644 index 0b448cf..0000000 --- a/src/pages/Update/Update.jsx +++ /dev/null @@ -1,7 +0,0 @@ -import React from 'react' - -const Update = () => { - return <div>Update</div> -} - -export default Update diff --git a/src/pages/Update/Update.module.css b/src/pages/Update/Update.module.css deleted file mode 100644 index e69de29..0000000 --- a/src/pages/Update/Update.module.css +++ /dev/null diff --git a/src/routes/index.js b/src/routes/index.js deleted file mode 100644 index fc2aeea..0000000 --- a/src/routes/index.js +++ /dev/null @@ -1,38 +0,0 @@ -import React from 'react' -import { Route, Routes } from 'react-router-dom' - -import Home from '../pages/Home/Home' -import Enrollment from '../pages/Enrollment/Enrollment' -import Update from '../pages/Update/Update' -import PhotoCapture from '../pages/Enrollment/PhotoCapture/PhotoCapture' -import DocumentScanner from '../pages/Enrollment/DocumentScanner/DocumentScanner' -import FormTwo from '../pages/Enrollment/FormTwo/FormTwo' -import Address from '../pages/Enrollment/Address/Address' - -const Index = () => { - return ( - <Routes> - <Route exact path="/" element={<Home />} /> - <Route path="enrollment"> - <Route index element={<Enrollment />} /> - <Route path="form2"> - <Route index element={<FormTwo />} /> - </Route> - <Route path="address"> - <Route index element={<Address />} /> - </Route> - <Route path="photo"> - <Route index element={<PhotoCapture />} /> - </Route> - <Route path="documents"> - <Route index element={<DocumentScanner />} /> - </Route> - </Route> - <Route path="update"> - <Route index element={<Update />} /> - </Route> - </Routes> - ) -} - -export default Index diff --git a/src/styles/GlobalVariables.css b/src/styles/GlobalVariables.css deleted file mode 100644 index a1e3384..0000000 --- a/src/styles/GlobalVariables.css +++ /dev/null @@ -1,8 +0,0 @@ -:root { - --color-black: #000; - --color-shadow: rgba(0, 0, 0, 0.24); - - --font-large: 4rem; - --font-medium: 2rem; - --font-medium-s: 1.25rem; -} |