You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Any icon can be used in Halstack Design System, so it is apt to the user to choose between one of the multiple options that are offered through internet but it is recommended to use the same library of icons along the application to keeping concistency.
Copy file name to clipboardExpand all lines: guidelines/components/sidenav/README.md
+75-54Lines changed: 75 additions & 54 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -2,48 +2,89 @@
2
2
3
3
The sidenav component is part of the layout of the application and it makes easier to divide the main screen into two different areas. The main area will have all the content and the sidenav as a secondary element as an index, including links to different resources on the web page.
4
4
5
-
## Appearance
6
5
7
-
This component looks like a container that is rendered in the left side of the application, different content can be placed within the container but the main aim of it is to serve as a guide with links to the subject treated in the main page.
8
-
A grey background defines the area which the sidenav occupies and there is an arrow that allows the user to hide or show the component on the screen. Anyway, there are able some configurations to have or not the arrow as a handler to control the visibility of the component, so in the case that the arrow won't be displayed, the component will be fixed in the screen.
6
+
## Usage
9
7
10
-
### Modes
11
-
12
-
Two different modes can be set in the element, according to the needs of the application and the relation between the main content and the sidenav.
13
-
The modes for the components are **overlay** and **push**.
14
-
15
-
The first mode, as the name is indicating, works as an overlay, leaving some content behind it on the occasion that will be displayed on the screen. That means that every time that the sidenav will be visible, some of the content of the main area remains covered by the layer.
16
-
If the selection is the push mode, this allows us to have boths content visible in the screen, not hiding information at any time but with the constraint that the main area has to manage the content because the overall space will reduce the width of the sidenav element.
8
+
- Use the sidenav element to improve the discoverability of the application, making the navigation links accessible to the users.
9
+
- Keep in mind the type of the devices that you are developing for, and handle the behavior in a way that doesn't block or reduce the available space of the main area in the application
10
+
- Try to follow and order for the sidenav content and make use of hierarchy to differentiate between a title and a link
17
11
18
-

19
12
20
-
## States
13
+
## Variants
21
14
22
-
States are simple, it is a component that doesn't require much logic and the behavior is basic.
23
-
It can be defined as two different modes: **default** and **static**.
15
+

24
16
25
-
With the default mode, the component will be visible in the first load of the application (only for desktop version) and the visibility of it can be handled by the user using the arrow to trigger the event.
17
+
_Example of the `overlay`and `push` sidenav variants_
26
18
27
-
The main difference in the static mode is that the arrow is removed from the component, so the user doesn't have the control to switch between views and the component will remain always visible.
19
+
Two different modes can be set in the element, according to the needs of the application and the relation between the main content and the sidenav.

95
121
96
-
## Responsive version for mobile and tablet
122
+
_Sidenav component example in mobile devices_
97
123
98
124
The responsive version of the component for mobile and tablet works a little bit different compared with the version for desktop. As the size of the screen in those devices is reduced, the default behavior in the first load of the page will be hidden in the sidenav component.
99
125
Taking this approach, as a first view of the page the user has all the content in the main area visible, and then he will need to interact with the component to make it visible and navigate to other resources.
100
126
101
-
Also, as an important point to mention, the only mode that works with responsive is the overlay, due to lack of space in the screen if the sidenav pushed the content of the main container.
127
+
Also, as an important point to mention, the only variant that works with responsive is the overlay, due to lack of space in the screen if the sidenav pushed the content of the main container.
102
128
103
129
Some properties regarding width vary, the details are indicated in the table below.
104
130
@@ -110,17 +136,12 @@ Some properties regarding width vary, the details are indicated in the table bel
- Use the sidenav element to improve the discoverability of the application, making the navigation links accessible to the users.
118
-
- Keep in mind the type of the devices that you are developing for, and handle the behavior in a way that doesn't block or reduce the available space of the main area in the application
119
-
- Try to follow and order for the sidenav content and make use of hierarchy to differentiate between a title and a link
0 commit comments