@@ -8,20 +8,24 @@ import { AutoRefresh } from 'uiSrc/components'
88import { RiPopover , RiTooltip } from 'uiSrc/components/base'
99import { Nullable } from 'uiSrc/utils'
1010import { sendEventTelemetry , TelemetryEvent } from 'uiSrc/telemetry'
11- import { FlexItem , Row } from 'uiSrc/components/base/layout/flex'
11+ import {
12+ Col ,
13+ FlexGroup ,
14+ FlexItem ,
15+ Row ,
16+ } from 'uiSrc/components/base/layout/flex'
1217import { Spacer } from 'uiSrc/components/base/layout/spacer'
1318import { EraserIcon , SettingsIcon } from 'uiSrc/components/base/icons'
1419import {
1520 DestructiveButton ,
1621 IconButton ,
1722 SecondaryButton ,
1823} from 'uiSrc/components/base/forms/buttons'
19- import { Text } from 'uiSrc/components/base/text'
24+ import { Text , Title } from 'uiSrc/components/base/text'
2025import { RiIcon } from 'uiSrc/components/base/icons/RiIcon'
2126
2227import SlowLogConfig from '../SlowLogConfig'
23- import styles from './styles.module.scss'
24- import { StyledInfoIcon } from './Actions.styles'
28+ import { StyledDatabaseName , StyledInfoIcon } from './Actions.styles'
2529
2630export interface Props {
2731 width : number
@@ -99,37 +103,32 @@ const Actions = (props: Props) => {
99103 }
100104
101105 const ToolTipContent = (
102- < div className = { styles . popoverContainer } >
103- < RiIcon
104- type = "ToastDangerIcon"
105- color = "attention600"
106- className = { styles . warningIcon }
107- />
108- < div >
109- < Text size = "m" component = "div" >
110- < h4 className = { styles . popoverTitle } >
111- < b > Clear Slow Log?</ b >
112- </ h4 >
113- < Text size = "xs" color = "subdued" >
106+ < FlexGroup direction = "column" gap = "l" >
107+ < Col gap = "m" >
108+ < Title size = "S" color = "primary" >
109+ Clear Slow Log?
110+ </ Title >
111+ < Col >
112+ < Text size = "m" color = "primary" >
114113 Slow Log will be cleared for
115- < span className = { styles . popoverDBName } > { name } </ span >
116- < br />
114+ < StyledDatabaseName > { name } </ StyledDatabaseName >
115+ </ Text >
116+ < Text size = "xs" color = "secondary" >
117117 NOTE: This is server configuration
118118 </ Text >
119- </ Text >
120- < div className = { styles . popoverFooter } >
121- < DestructiveButton
122- size = "small"
123- icon = { EraserIcon }
124- onClick = { ( ) => handleClearClick ( ) }
125- className = { styles . popoverDeleteBtn }
126- data-testid = "reset-confirm-btn"
127- >
128- Clear
129- </ DestructiveButton >
130- </ div >
131- </ div >
132- </ div >
119+ </ Col >
120+ </ Col >
121+ < Row justify = "end" >
122+ < DestructiveButton
123+ size = "small"
124+ icon = { EraserIcon }
125+ onClick = { ( ) => handleClearClick ( ) }
126+ data-testid = "reset-confirm-btn"
127+ >
128+ Clear
129+ </ DestructiveButton >
130+ </ Row >
131+ </ FlexGroup >
133132 )
134133
135134 return (
@@ -140,7 +139,6 @@ const Actions = (props: Props) => {
140139 loading = { loading }
141140 displayText = { width > HIDE_REFRESH_LABEL_WIDTH }
142141 lastRefreshTime = { lastRefreshTime }
143- containerClassName = { styles . refreshContainer }
144142 onRefresh = { ( ) => onRefresh ( ) }
145143 onEnableAutoRefresh = { handleEnableAutoRefresh }
146144 onChangeAutoRefreshRate = { handleChangeAutoRefreshRate }
@@ -184,11 +182,7 @@ const Actions = (props: Props) => {
184182 closePopover = { closePopoverClear }
185183 panelPaddingSize = "m"
186184 button = {
187- < RiTooltip
188- position = "left"
189- content = "Clear Slow Log"
190- anchorClassName = { styles . icon }
191- >
185+ < RiTooltip position = "left" content = "Clear Slow Log" >
192186 < IconButton
193187 icon = { EraserIcon }
194188 aria-label = "Clear Slow Log"
0 commit comments