Semantic-UI Input Focus State
Semantic UI is a framework that is used to build a great user interface. It is an open-source framework that uses CSS and jQuery. It is the same as a bootstrap for use and has great different elements to use to make your website look more amazing.
Semantic-UI Input class is used to create a basic input User Interface. The Semantic-UI Input Focus State is used to display the focus on the input field i.e. it represents the user currently interacting with the form element.
Semantic-UI Input Focus State Used Class:
- focus: This class is used to display the focus on the input field.
Syntax:
<div class="ui input focus">
...
</div>
Example 1: In this example, we will describes the use of Semantic-UI Input Focus State.
HTML
<!DOCTYPE html>
< html >
< head >
< title >
Semantic-UI Input Focus State
</ title >
< link rel = "stylesheet"
href =
</ head >
< body >
< div class = "ui center aligned container" >
< h2 style = "color:green" >
GeeksforGeeks
</ h2 >
< h3 >Semantic-UI Input Focus State</ h3 >
< div class = "ui input focus" >
< input type = "text"
placeholder = "First Name" >
</ div >
< div class = "ui input" >
< input type = "text"
placeholder = "Last Name" >
</ div >
< br >< br >
< div class = "ui input" >
< input type = "text"
placeholder = "Email Id" >
</ div >
< div class = "ui input" >
< input type = "text"
placeholder = "Password" >
</ div >
</ div >
</ body >
</ html >
|
Output:
Semantic-UI Input Focus State
Example 2: In this example, we will describe the use of Semantic-UI Input Focus State.
HTML
<!DOCTYPE html>
< html >
< head >
< title >
Semantic-UI Input Focus State
</ title >
< link rel = "stylesheet"
href =
</ head >
< body >
< div class = "ui center aligned container" >
< h2 style = "color:green" >
GeeksforGeeks
</ h2 >
< h3 >Semantic-UI Input Focus State</ h3 >
< div class = "ui input icon focus" >
< input type = "text"
placeholder = "User name" >
< i class = "user icon" ></ i >
</ div >
< br >< br >
< div class = "ui icon input" >
< input type = "email"
placeholder = "Email Id" >
< i class = "search icon" ></ i >
</ div >
< br >< br >
< div class = "ui icon input" >
< input type = "password"
placeholder = "Password" >
< i class = "eye icon" ></ i >
</ div >
</ div >
</ body >
</ html >
|
Output:
Semantic-UI Input Focus State
Reference: https://semantic-ui.com/elements/input.html#focus
Last Updated :
08 Mar, 2022
Like Article
Save Article
Share your thoughts in the comments
Please Login to comment...