-
Notifications
You must be signed in to change notification settings - Fork 4
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Showing
7 changed files
with
659 additions
and
45 deletions.
There are no files selected for viewing
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
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
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
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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,33 @@ | ||
import React from 'react' | ||
import { TextInput as GrommetTextInput } from 'grommet/components/TextInput' | ||
|
||
import { palette } from '../constants' | ||
import styled, { css } from 'styled-components' | ||
|
||
export const TextInput = styled(GrommetTextInput)<{ isValid?: boolean }>` | ||
border-radius: 20px; | ||
box-shadow: none; | ||
font-weight: 400; | ||
border: 1px solid #dfe1e5; | ||
color: #333437; | ||
transition: border-color 250ms, box-shadow 250ms; | ||
&:focus, | ||
&:hover { | ||
background-color: #fff; | ||
box-shadow: 0 1px 5px rgb(32 33 36 / 26%); | ||
border-color: rgba(223, 225, 229, 0); | ||
} | ||
${(props) => | ||
!props.isValid && | ||
css` | ||
border-color: ${palette.PinkRed}; | ||
&:hover, | ||
&:focus { | ||
border-color: ${palette.LightRed}; | ||
box-shadow: 0 1px 6px rgb(255 77 79 / 26%); | ||
} | ||
`} | ||
` |
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
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
Oops, something went wrong.