File tree Expand file tree Collapse file tree 1 file changed +24
-0
lines changed
Expand file tree Collapse file tree 1 file changed +24
-0
lines changed Original file line number Diff line number Diff line change @@ -95,6 +95,14 @@ If you ejected the `navbar` component before version `0.128.0`, [update it](../c
9595 - ` error ` - Red background
9696 Default: ` info `
9797
98+ ---
99+
100+ - rbac
101+ - object
102+ - Map of teams to permission levels that determines who can see the banner.
103+ Controls the visibility of the banner based on the user's team membership.
104+ If specified, only users belonging to teams with at least ` read ` access will see the banner.
105+ For more information, see [ RBAC configuration] ( ./rbac.md ) .
98106{% /table %}
99107
100108## Configuration
@@ -126,6 +134,22 @@ banner:
126134 dismissible : true
127135 target : ' **'
128136` ` `
137+
138+ ### Role-based visibility
139+
140+ Control banner visibility based on team membership:
141+
142+ ` ` ` yaml {% title="redocly.yaml" %}
143+ banner :
144+ - content : " 🔒 Please log in to see all content!"
145+ color : warning
146+ rbac :
147+ anonymous : read
148+ authenticated : none
149+ ` ` `
150+
151+ In this example, the banner is only visible to unauthenticated visitors (` anonymous` team).
152+
129153Configure a banner in the front matter of a specific page :
130154` ` ` md {% title="example.md" %}
131155---
You can’t perform that action at this time.
0 commit comments