diff --git a/package.json b/package.json index 19b56dd..5915cdf 100644 --- a/package.json +++ b/package.json @@ -3,9 +3,11 @@ "version": "0.1.0", "private": true, "dependencies": { + "classnames": "^2.2.6", "react": "^16.9.0", "react-dom": "^16.9.0", - "react-scripts": "3.1.1" + "react-scripts": "3.1.1", + "styled-components": "^4.3.2" }, "scripts": { "start": "react-scripts start", @@ -27,5 +29,8 @@ "last 1 firefox version", "last 1 safari version" ] + }, + "devDependencies": { + "babel-plugin-macros": "^2.6.1" } } diff --git a/public/images/placeholder.png b/public/images/placeholder.png new file mode 100644 index 0000000..96e1121 Binary files /dev/null and b/public/images/placeholder.png differ diff --git a/public/index.html b/public/index.html index 80ffd85..40dc71d 100644 --- a/public/index.html +++ b/public/index.html @@ -9,18 +9,12 @@ name="description" content="Web site created using create-react-app" /> - - diff --git a/public/logo192.png b/public/logo192.png deleted file mode 100644 index fc44b0a..0000000 Binary files a/public/logo192.png and /dev/null differ diff --git a/public/logo512.png b/public/logo512.png deleted file mode 100644 index a4e47a6..0000000 Binary files a/public/logo512.png and /dev/null differ diff --git a/public/manifest.json b/public/manifest.json index e4c94e6..fa02500 100644 --- a/public/manifest.json +++ b/public/manifest.json @@ -6,17 +6,7 @@ "src": "favicon.ico", "sizes": "64x64 32x32 24x24 16x16", "type": "image/x-icon" - }, - { - "src": "logo192.png", - "type": "image/png", - "sizes": "192x192" - }, - { - "src": "logo512.png", - "type": "image/png", - "sizes": "512x512" - } + } ], "start_url": ".", "display": "standalone", diff --git a/src/App.css b/src/App.css deleted file mode 100644 index 61e4b72..0000000 --- a/src/App.css +++ /dev/null @@ -1,45 +0,0 @@ -/* color theme * -* - #96ffff - #52eeff - #17d8ff - #5cbcff - #a696ff - #e064e6 - #ff009f -*/ - - -.App { - text-align: center; -} - -.App-logo { - animation: App-logo-spin infinite 20s linear; - height: 40vmin; - pointer-events: none; -} - -.App-header { - background-color: #282c34; - min-height: 100vh; - display: flex; - flex-direction: column; - align-items: center; - justify-content: center; - font-size: calc(10px + 2vmin); - color: white; -} - -.App-link { - color: #61dafb; -} - -@keyframes App-logo-spin { - from { - transform: rotate(0deg); - } - to { - transform: rotate(360deg); - } -} diff --git a/src/App.js b/src/App.js index 31d8b33..f4fb7d4 100644 --- a/src/App.js +++ b/src/App.js @@ -1,19 +1,33 @@ import React from 'react'; +import styled from 'styled-components/macro'; +import BlogPostContent from './BlogPostContent'; +import { Header, Footer } from './components'; +import Blog from './containers/Blog'; -import BlogPostContent from './BlogPostContent' +const Grid = styled.div` + background: ivory; + font-size: 16px; + display: grid; + grid-template-columns: 140px 50px auto 50px 140px; + grid-template-areas: + "header header header header header" + ". main main main ." + "footer footer footer footer footer" +` -import { Header, Footer } from './components' -import Blog from './containers/Blog' +const Main = styled.div` + grid-area: main; +` function App() { return ( -
+
-
+
-
+
+ ); } diff --git a/src/components/Atoms/Avatar/index.js b/src/components/Atoms/Avatar/index.js index f133ce4..29247f5 100644 --- a/src/components/Atoms/Avatar/index.js +++ b/src/components/Atoms/Avatar/index.js @@ -1,12 +1,15 @@ import React from 'react'; import PropTypes from 'prop-types'; +import styled from 'styled-components/macro'; const Avatar = (props) => { const { image, altText } = props; - + const AvatarStyle = styled.img` + max-width: 250px; + ` return ( - {altText} + ); }; diff --git a/src/components/Atoms/Button/index.js b/src/components/Atoms/Button/index.js index dd5915a..32a01d4 100644 --- a/src/components/Atoms/Button/index.js +++ b/src/components/Atoms/Button/index.js @@ -1,23 +1,23 @@ -import React from 'react'; -import PropTypes from 'prop-types'; +import styled from 'styled-components/macro'; -const Button = (props) => { - const { children, ...other } = props; +export const Button = styled.button` + background: ${props => props.secondary ? "#fff" : "#5CBCFF"}; + background-image: ${props => props.secondary ? "none" : "linear-gradient(to bottom, #5CBCFF, #A696FF)"}; + border-radius: 4px; + color: ${props => props.secondary ? "#a696ff" : "#fff"}; + border: solid #A696FF 1px; + text-decoration: none; + display: inline-block; + cursor: pointer; + padding: 10px 15px; + &:hover { + background: #fff; + color: #A696FF; + text-decoration: none; + opacity: 0.5; + }`; - - return ( - - ); -}; - -Button.propTypes = { - children: PropTypes.node -}; - -Button.defaultProps = { - children: null -}; - -export default Button; +export const SuperLike = styled(Button)` + font-size: 25px; + font-weight: bold; +` \ No newline at end of file diff --git a/src/components/Atoms/Content/index.js b/src/components/Atoms/Content/index.js index b3133bc..cd18414 100644 --- a/src/components/Atoms/Content/index.js +++ b/src/components/Atoms/Content/index.js @@ -6,7 +6,7 @@ const Content = (props) => { return ( -
+
); }; diff --git a/src/components/Atoms/ContentList/index.js b/src/components/Atoms/ContentList/index.js index 4bb757e..962eba5 100644 --- a/src/components/Atoms/ContentList/index.js +++ b/src/components/Atoms/ContentList/index.js @@ -4,11 +4,11 @@ import PropTypes from 'prop-types'; const ContentList = (props) => { const { listElements } = props; return ( -
    +
      { Object.keys(listElements).map((key, index) => { return ( -
    • +
    • {key}: {listElements[key]}
    • ) diff --git a/src/components/Atoms/TextField/index.js b/src/components/Atoms/TextField/index.js index 36cde7a..c0fd91c 100644 --- a/src/components/Atoms/TextField/index.js +++ b/src/components/Atoms/TextField/index.js @@ -1,11 +1,8 @@ -import React from 'react'; - -const TextField = (props) => { - const { ...other } = props; - - return ( -