Created
December 12, 2019 15:01
-
-
Save taddison/5fb5cde18c550fde838de46db44455ec to your computer and use it in GitHub Desktop.
React select with styled components
This file contains 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
import React from "react"; | |
import styled from "styled-components"; | |
const MinorSelect = styled.select` | |
appearance: none; | |
background-color: #edf2f7; | |
border: 0.0625rem solid grey; | |
border-radius: 0.5rem; | |
font-size: 1.5rem; | |
padding: 1rem; | |
border-radius: 0; | |
`; | |
export default function Minor() { | |
return ( | |
<div> | |
<MinorSelect> | |
<option>Option one</option> | |
<option>Option two</option> | |
<option>Option three</option> | |
</MinorSelect> | |
</div> | |
); | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment