From 7b8fcea94ee2285cd40d16fbbb69d755051c81ed Mon Sep 17 00:00:00 2001 From: ninjahellokitty <8458817+ninjahellokitty@users.noreply.github.com> Date: Wed, 12 Dec 2018 08:19:48 +0800 Subject: [PATCH] Update focus selector for input (#23851) * Update index.md * Add code formatting --- guide/english/css/forms/index.md | 11 +++++++++++ 1 file changed, 11 insertions(+) diff --git a/guide/english/css/forms/index.md b/guide/english/css/forms/index.md index f6ef4c3947..eb74c3d706 100644 --- a/guide/english/css/forms/index.md +++ b/guide/english/css/forms/index.md @@ -62,6 +62,17 @@ In the below given example,only input type corresponding to first name will be s ``` +## Style input element with css + +### :focus selector +The `:focus` selector is applied when the element accepts user inputs. + +```css +input:focus { + background-color: #FFFF66; +} +``` +