Update focus selector for input (#23851)

* Update index.md

* Add code formatting
This commit is contained in:
ninjahellokitty
2018-12-12 08:19:48 +08:00
committed by Manish Giri
parent cfb7bdabe7
commit 7b8fcea94e

View File

@ -62,6 +62,17 @@ In the below given example,only input type corresponding to first name will be s
<input type="submit" value="submit">
</form>
```
## Style input element with css
### :focus selector
The `:focus` selector is applied when the element accepts user inputs.
```css
input:focus {
background-color: #FFFF66;
}
```