This repository has been archived by the owner on Aug 12, 2021. It is now read-only.
-
Notifications
You must be signed in to change notification settings - Fork 1
/
.eslintcache
1 lines (1 loc) · 11 KB
/
.eslintcache
1
[{"/home/krishnadevz/spacetravel/src/components/Footer.js":"1","/home/krishnadevz/spacetravel/src/components/Space.js":"2","/home/krishnadevz/spacetravel/src/components/Search.js":"3","/home/krishnadevz/spacetravel/src/components/Globe.js":"4","/home/krishnadevz/spacetravel/src/index.js":"5","/home/krishnadevz/spacetravel/src/reportWebVitals.js":"6","/home/krishnadevz/spacetravel/src/components/Navlinks.js":"7","/home/krishnadevz/spacetravel/src/components/NotFound.js":"8"},{"size":2288,"mtime":1610182444493,"results":"9","hashOfConfig":"10"},{"size":4470,"mtime":1610251300974,"results":"11","hashOfConfig":"10"},{"size":2348,"mtime":1610183146818,"results":"12","hashOfConfig":"10"},{"size":1446,"mtime":1610182643088,"results":"13","hashOfConfig":"10"},{"size":1158,"mtime":1610183397954,"results":"14","hashOfConfig":"10"},{"size":364,"mtime":1610087400332,"results":"15","hashOfConfig":"10"},{"size":844,"mtime":1610183028022,"results":"16","hashOfConfig":"10"},{"size":670,"mtime":1610183036290,"results":"17","hashOfConfig":"10"},{"filePath":"18","messages":"19","errorCount":0,"warningCount":0,"fixableErrorCount":0,"fixableWarningCount":0},"148gdy3",{"filePath":"20","messages":"21","errorCount":0,"warningCount":5,"fixableErrorCount":0,"fixableWarningCount":0,"source":"22"},{"filePath":"23","messages":"24","errorCount":0,"warningCount":4,"fixableErrorCount":0,"fixableWarningCount":0,"source":"25"},{"filePath":"26","messages":"27","errorCount":0,"warningCount":0,"fixableErrorCount":0,"fixableWarningCount":0},{"filePath":"28","messages":"29","errorCount":0,"warningCount":0,"fixableErrorCount":0,"fixableWarningCount":0,"usedDeprecatedRules":"30"},{"filePath":"31","messages":"32","errorCount":0,"warningCount":0,"fixableErrorCount":0,"fixableWarningCount":0},{"filePath":"33","messages":"34","errorCount":0,"warningCount":0,"fixableErrorCount":0,"fixableWarningCount":0},{"filePath":"35","messages":"36","errorCount":0,"warningCount":0,"fixableErrorCount":0,"fixableWarningCount":0},"/home/krishnadevz/spacetravel/src/components/Footer.js",[],"/home/krishnadevz/spacetravel/src/components/Space.js",["37","38","39","40","41"],"import React from \"react\";\nimport { BrowserRouter as Router, Link, Route, Switch } from \"react-router-dom\";\nimport { Container, Row, Col, Button, Accordion, Card } from \"react-bootstrap\";\nimport styles from \"./Space.module.css\";\nimport { useSpeechSynthesis } from \"react-speech-kit\";\nimport { useState, useEffect } from \"react\";\nimport ReactGlobe from \"react-globe\";\nimport Navbar from './Navlinks'\n\nfunction Space() {\n const [setValue] = useState(\"\");\n const { speak } = useSpeechSynthesis();\n const [spaceData, setSpaceData] = useState({ apod: null, randomAPOD: null });\n \n useEffect(() => {\n const fetchData = async () => {\n const getAPOD = await fetch(\n `https://api.nasa.gov/planetary/apod?api_key=hETQq0FPsZJnUP9C3sUEFtwmJH3edb4I5bghfWDM`\n );\n const getRandomAPOD = await fetch(\n `https://api.nasa.gov/planetary/apod?api_key=hETQq0FPsZJnUP9C3sUEFtwmJH3edb4I5bghfWDM&count=5`\n );\n \n setSpaceData({ apod: await getAPOD.json(), randomAPOD: await getRandomAPOD.json()});\n\n };\n\n fetchData();\n }, []);\n\n console.log('render', spaceData);\n\n if (!spaceData.apod) return <div />;\n\n return (\n <Container\n fluid={true}\n className={styles.space}\n >\n <ReactGlobe height=\"50vh\" width=\"100%\" />\n <div className={styles.spaceContainer}>\n <Navbar/>\n <h2>Astronomy Picture of the Day</h2>\n <Row className={styles.row_1}>\n <Col xs={12} sm={12} md={12} lg={6}>\n {spaceData.apod.media_type === \"image\" ? (\n <img src={spaceData.apod.url} alt={spaceData.apod.title} />\n ) : (\n <iframe\n title=\"space-video\"\n src={spaceData.apod.url}\n frameBorder=\"0\"\n gesture=\"media\"\n allow=\"encrypted-media\"\n allowFullScreen\n />\n )}\n </Col>\n <Col xs={12} sm={12} md={12} lg={6}>\n <h3>\n {spaceData.apod.title}\n <button\n className={styles.button}\n onClick={() => speak({ text: spaceData.apod.explanation })}\n >\n 🔊\n </button>\n </h3>\n <p>{spaceData.apod.date}</p>\n <p\n value={spaceData.apod.explanation}\n onChange={(event) => setValue(event.target.explanation)}\n >\n {spaceData.apod.explanation}\n </p>\n </Col>\n </Row>\n </div>\n \n <h2 className={styles.h2}>Random Astronomy Pictures</h2>\n <Accordion defaultActiveKey=\"0\" className={styles.accordionContainer}>\n \n {\n spaceData.randomAPOD.map( item => {\n return (\n <Card key={item.title}>\n <Card.Header className={styles.cardHeader}>\n <Accordion.Toggle className={styles.accordionLink} as={Button} variant=\"link\" eventKey={item.title}>\n {item.title}\n </Accordion.Toggle>\n </Card.Header>\n <Accordion.Collapse eventKey={item.title}>\n <Card.Body>\n <Row>\n <Col xs={12} sm={12} md={4}>\n {\n item.media_type === 'video'\n ? <iframe\n style={{\n position: \"absolute\",\n top: 0,\n left: 0,\n width: \"100%\",\n height: \"100%\"\n }}\n src={item.url}\n frameBorder=\"0\"\n />\n : <img src={item.url} alt={item.title} />\n }\n </Col>\n <Col xs={12} sm={12} md={8}>\n <p>Date: {item.date}</p>\n <div>{item.explanation}</div>\n { item.copyright ? <span>©{item.copyright}</span> : <span>--</span>}\n </Col>\n </Row>\n </Card.Body>\n </Accordion.Collapse>\n </Card>\n )\n })\n }\n </Accordion>\n \n </Container>\n );\n}\nexport default Space;","/home/krishnadevz/spacetravel/src/components/Search.js",["42","43","44","45"],"import React, { useState } from \"react\";\nimport Unsplash, { toJson } from \"unsplash-js\";\nimport ReactGlobe from \"react-globe\";\nimport styles from \"./Search.module.css\";\nimport {Row, Col, Container, Button, Form, FormControl, Nav} from 'react-bootstrap'\nimport Navbar from './Navlinks'\nimport {BrowserRouter as Router} from 'react-router-dom'\nimport ModalImage from \"react-modal-image-responsive\";\nimport {Download} from 'react-bootstrap-icons'\n\nfunction Search() {\n const [query, setQuery] = useState(\"\");\n const unsplash = new Unsplash({\n accessKey: \"Xhyev2ttVhtveYdQhiRjp4WT1Pe_69kQI4hWOUn81y8\",\n });\n const [pics, setPics] = useState([]);\n\n const searchPhotos = async (e) => {\n e.preventDefault();\n unsplash.search\n .photos(query, 1, 20)\n .then(toJson)\n .then((json) => {\n setPics(json.results);\n });\n };\n\n return (\n <div className={styles.bg}>\n <ReactGlobe height=\"50vh\" width=\"100%\" />\n <Container className={styles.searchContainer}>\n <Navbar/>\n <h1 className={styles.title}>Space Photo Search🛸</h1>\n <Form onSubmit={searchPhotos}>\n <FormControl type=\"text\" placeholder=\"Search\" className=\"mr-sm-2\" name=\"query\" value={query}\n onChange={(e) => setQuery(e.target.value)}/>\n <Button className={styles.searchBtn} type=\"submit\">Search🔍</Button>\n </Form>\n </Container>\n\n {/* card list className={styles.cardlist}*/}\n <Container className={styles.searchContainer}>\n \n {console.log('url pic', pics)}\n <Container className={styles.imgContainer}>\n {pics.map((pic) => (\n <div key={pic.id}>\n <ModalImage\n small={pic.urls.small}\n large={pic.urls.full}\n alt={pic.alt_description}\n hideDownload={true}\n hideZoom={true}\n className={styles.smallPic}\n variant=\"top\"\n title=\"Click to preview\"\n />\n <a href={pic.links.download + \"?force=true\"} rel=\"noopener noreferrer\" download>\n <Button className={styles.dlBtn}>Download Image <Download/></Button>\n </a>\n </div>\n ))}\n \n </Container> \n </Container>\n </div>\n );\n}\n\nexport default Search;\n","/home/krishnadevz/spacetravel/src/components/Globe.js",[],"/home/krishnadevz/spacetravel/src/index.js",[],["46","47"],"/home/krishnadevz/spacetravel/src/reportWebVitals.js",[],"/home/krishnadevz/spacetravel/src/components/Navlinks.js",[],"/home/krishnadevz/spacetravel/src/components/NotFound.js",[],{"ruleId":"48","severity":1,"message":"49","line":2,"column":27,"nodeType":"50","messageId":"51","endLine":2,"endColumn":33},{"ruleId":"48","severity":1,"message":"52","line":2,"column":35,"nodeType":"50","messageId":"51","endLine":2,"endColumn":39},{"ruleId":"48","severity":1,"message":"53","line":2,"column":41,"nodeType":"50","messageId":"51","endLine":2,"endColumn":46},{"ruleId":"48","severity":1,"message":"54","line":2,"column":48,"nodeType":"50","messageId":"51","endLine":2,"endColumn":54},{"ruleId":"55","severity":1,"message":"56","line":98,"column":29,"nodeType":"57","endLine":108,"endColumn":29},{"ruleId":"48","severity":1,"message":"58","line":5,"column":9,"nodeType":"50","messageId":"51","endLine":5,"endColumn":12},{"ruleId":"48","severity":1,"message":"59","line":5,"column":14,"nodeType":"50","messageId":"51","endLine":5,"endColumn":17},{"ruleId":"48","severity":1,"message":"60","line":5,"column":57,"nodeType":"50","messageId":"51","endLine":5,"endColumn":60},{"ruleId":"48","severity":1,"message":"49","line":7,"column":26,"nodeType":"50","messageId":"51","endLine":7,"endColumn":32},{"ruleId":"61","replacedBy":"62"},{"ruleId":"63","replacedBy":"64"},"no-unused-vars","'Router' is defined but never used.","Identifier","unusedVar","'Link' is defined but never used.","'Route' is defined but never used.","'Switch' is defined but never used.","jsx-a11y/iframe-has-title","<iframe> elements must have a unique title property.","JSXOpeningElement","'Row' is defined but never used.","'Col' is defined but never used.","'Nav' is defined but never used.","no-native-reassign",["65"],"no-negated-in-lhs",["66"],"no-global-assign","no-unsafe-negation"]