Skip to content

Instantly share code, notes, and snippets.

@garima33
Last active November 19, 2019 10:46
Show Gist options
  • Select an option

  • Save garima33/70b7b683774d1167ba7b46e245ba10c6 to your computer and use it in GitHub Desktop.

Select an option

Save garima33/70b7b683774d1167ba7b46e245ba10c6 to your computer and use it in GitHub Desktop.
grid-demo-emotion
import styled, { css } from "react-emotion";
export const Flex = styled("div")`
display: flex;
flex-wrap: wrap;
// all the below styles can be customized using prop values
flex-direction: ${props => props.direction || "row"};
justify-content: ${props => props.justify || "space-between"};
font-family: ${props => props.font || "roboto"};
font-size: ${props => props.fontSize || "medium"};
background-color: ${props => props.color};
`;
export const DataWrapper = styled("div")`
width: 30%;
height: 30%;
margin: 1%;
padding: 0.5%;
background-color: white;
border-radius: 3%;
`;
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment