Skip to content

Commit

Permalink
Added Styles to override the default autofill style of browsers (#140)
Browse files Browse the repository at this point in the history
* Autofill Styling Fixes #137

* Removed unnecessary comments

* Removed webkit style - lint fixes
  • Loading branch information
Adnan-Sait authored Oct 4, 2022
1 parent baa1347 commit 018ea4d
Showing 1 changed file with 12 additions and 2 deletions.
14 changes: 12 additions & 2 deletions src/Components/Form/TextInput/TextInput.scss
Original file line number Diff line number Diff line change
Expand Up @@ -24,15 +24,25 @@
background-size: 100% 100%;
border: unset;
border-bottom: solid 1px $color-alternative;
transition: all 0.2s cubic-bezier(0.64, 0.09, 0.08, 1);
transition: all 0.2s cubic-bezier(0.64, 0.09, 0.08, 1), background 0s, color 0s;

&:focus {
background-position: 0 0;
border-bottom-color: $color-primary;
outline: none;
box-shadow: none;
}


&:-webkit-autofill {
/*
* 'background-clip' to make the background transparent.
* If a solid color is required use 'box-shadow'.
**/
background-clip: text !important;
-webkit-text-fill-color: $color-main-text;
caret-color: $color-main-text;
}

&::placeholder {
transition: all 0.2s cubic-bezier(0.64, 0.09, 0.08, 1);
}
Expand Down

0 comments on commit 018ea4d

Please sign in to comment.