Open In App
Related Articles

Semantic-UI Sidebar Visible State

Improve Article
Save Article
Like Article

Semantic UI is a modern framework used in developing seamless designs for the website. It gives the user a lightweight experience with its components. It uses predefined CSS and jQuery to incorporate different frameworks.

Semantic UI Sidebar is used to place additional links so we can navigate to different positions of the web application with ease. The Sidebar element hides a part of the webpage under it to show the page.

Semantic UI Sidebar Visible State is used to make a sidebar visible on a webpage. We can load the sidebar on the webpage on the launch of the website.

Semantic UI Sidebar Visible State Class:

  • visible: Add this class to the sidebar and the sidebar will show on the webpage on page load.

Syntax:  Add the visible class to the sidebar element as follows:

<div class="ui sidebar visible ...">

Example: In the following example, we have the sidebar visible on page load.


<!DOCTYPE html>
    <meta charset="UTF-8" />
    <meta http-equiv="X-UA-Compatible" 
          content="IE=edge" />
    <meta name="viewport" 
          content="width=device-width, initial-scale=1.0" />
    <link href=
          rel="stylesheet" />
    <script src=
    <script src=
    <div class="ui container">
        <div class="ui sidebar visible inverted vertical menu">
            <a class="item">
                Data Structures
            <a class="item">
            <a class="item">
                Machine Learning
            <button class="ui button" onclick="openSidebar()">
              Close Sidebar</button>
        <div class="pusher">
                <div class="ui header green">
                    Semantic UI Sidebar Visible State
            <div class="ui segment">
                <h1>Welcome to GeeksforGeeks</h1>
                <p>Find the best programming tutorials here.</p>
                <button onclick="openSidebar()">Open Sidebar</button>
        const openSidebar = () => {


Semantic-UI Sidebar Visible State

Semantic-UI Sidebar Visible State


Last Updated : 24 Feb, 2022
Like Article
Save Article
Similar Reads
Related Tutorials