Last active
March 30, 2022 13:46
-
-
Save alanbsmith/19c501265e7d32204532b2dba9af671e to your computer and use it in GitHub Desktop.
structuring-our-styled-components-an-example-block
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
// src/blocks/Card/index.js | |
import styled from 'styled-components'; | |
import Header from './Header'; | |
import Image from './Image'; | |
import Text from './Text'; | |
import Title from './Title'; | |
const Card = styled.div` | |
background: #ffffff; | |
border-radius: 2px; | |
margin: 5px 5px 10px; | |
padding: 5px; | |
position: relative; | |
box-shadow: 2px 2px 4px 0px #cfd8dc; | |
`; | |
Card.Header = Header; | |
Card.Image = Image; | |
Card.Text = Text; | |
Card.Title = Title; | |
export default Card; |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment