File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change 11{
22 "name" : " @devtron-labs/devtron-fe-common-lib" ,
3- "version" : " 1.22.6-beta-1 " ,
3+ "version" : " 1.22.6-beta-3 " ,
44 "description" : " Supporting common component library" ,
55 "type" : " module" ,
66 "main" : " dist/index.js" ,
Original file line number Diff line number Diff line change @@ -59,6 +59,7 @@ const PageHeader = ({
5959 sidePanelConfig,
6060 tempAppWindowConfig,
6161 featureAskDevtronExpert,
62+ isSuperAdmin,
6263 } = useMainContext ( )
6364 const { showSwitchThemeLocationTippy, handleShowSwitchThemeLocationTippyChange } = useTheme ( )
6465
@@ -146,18 +147,21 @@ const PageHeader = ({
146147
147148 const renderLogoutHelpSection = ( ) => (
148149 < >
149- { featureAskDevtronExpert && sidePanelConfig . state === 'closed' && ! tempAppWindowConfig . open && (
150- < Tooltip content = "Ask Devtron AI" placement = "bottom" alwaysShowTippyOnHover delay = { [ 500 , null ] } >
151- < button
152- className = "enable-svg-animation--hover flex dc__no-background p-2 dc__outline-none-imp dc__no-border"
153- onClick = { onAskButtonClick }
154- type = "button"
155- aria-label = "Ask Devtron Expert"
156- >
157- < Icon name = "ic-devtron-ai" color = { null } size = { 28 } />
158- </ button >
159- </ Tooltip >
160- ) }
150+ { isSuperAdmin &&
151+ featureAskDevtronExpert &&
152+ sidePanelConfig . state === 'closed' &&
153+ ! tempAppWindowConfig . open && (
154+ < Tooltip content = "Ask Devtron AI" placement = "bottom" alwaysShowTippyOnHover delay = { [ 500 , null ] } >
155+ < button
156+ className = "enable-svg-animation--hover flex dc__no-background p-2 dc__outline-none-imp dc__no-border"
157+ onClick = { onAskButtonClick }
158+ type = "button"
159+ aria-label = "Ask Devtron Expert"
160+ >
161+ < Icon name = "ic-devtron-ai" color = { null } size = { 28 } />
162+ </ button >
163+ </ Tooltip >
164+ ) }
161165
162166 < HelpButton
163167 serverInfo = { currentServerInfo . serverInfo }
You can’t perform that action at this time.
0 commit comments