Skip to content

Commit 79b586c

Browse files
committed
fix: minor fixes
1 parent 3a3e8d2 commit 79b586c

File tree

4 files changed

+21
-19
lines changed

4 files changed

+21
-19
lines changed

src/components/Drawer/Drawer.tsx

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -10,13 +10,13 @@ import {CopyLinkButton} from '../CopyLinkButton/CopyLinkButton';
1010

1111
import {useDrawerContext} from './DrawerContext';
1212

13+
import './Drawer.scss';
14+
1315
const DEFAULT_DRAWER_WIDTH_PERCENTS = 60;
1416
const DEFAULT_DRAWER_WIDTH = 600;
1517
const DRAWER_WIDTH_KEY = 'drawer-width';
1618
const b = cn('ydb-drawer');
1719

18-
import './Drawer.scss';
19-
2020
interface DrawerPaneContentWrapperProps {
2121
isVisible: boolean;
2222
onClose: () => void;

src/containers/Tenant/Diagnostics/TopQueries/RunningQueriesData.tsx

Lines changed: 10 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -65,17 +65,16 @@ export const RunningQueriesData = ({
6565

6666
const {tableSort, handleTableSort, backendSort} = useRunningQueriesSort();
6767

68-
const {currentData, data, isFetching, isLoading, error} =
69-
topQueriesApi.useGetRunningQueriesQuery(
70-
{
71-
database: tenantName,
72-
filters,
73-
sortOrder: backendSort,
74-
},
75-
{pollingInterval: autoRefreshInterval},
76-
);
77-
78-
const rows = data?.resultSets?.[0]?.result;
68+
const {currentData, isFetching, isLoading, error} = topQueriesApi.useGetRunningQueriesQuery(
69+
{
70+
database: tenantName,
71+
filters,
72+
sortOrder: backendSort,
73+
},
74+
{pollingInterval: autoRefreshInterval},
75+
);
76+
77+
const rows = currentData?.resultSets?.[0]?.result;
7978

8079
const isDrawerVisible = selectedRow !== undefined;
8180

src/containers/Tenant/Diagnostics/TopQueries/TopQueries.scss

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -18,8 +18,8 @@
1818
&_active {
1919
background-color: var(--g-color-base-selection);
2020

21-
&:hover {
22-
background: var(--g-color-base-selection-hover) !important;
21+
&:hover.kv-top-queries__row_active {
22+
background: var(--g-color-base-selection-hover);
2323
}
2424
}
2525
}

src/containers/Tenant/Diagnostics/TopQueries/TopQueries.tsx

Lines changed: 7 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -46,11 +46,14 @@ interface TopQueriesProps {
4646

4747
export const TopQueries = ({tenantName}: TopQueriesProps) => {
4848
const dispatch = useTypedDispatch();
49-
const [_queryMode = QueryModeIds.top, setQueryMode] = useQueryParam('queryMode', StringParam);
50-
const [_timeFrame = TimeFrameIds.hour, setTimeFrame] = useQueryParam('timeFrame', StringParam);
49+
const [rawQueryMode = QueryModeIds.top, setQueryMode] = useQueryParam('queryMode', StringParam);
50+
const [rawTimeFrame = TimeFrameIds.hour, setTimeFrame] = useQueryParam(
51+
'timeFrame',
52+
StringParam,
53+
);
5154

52-
const queryMode = queryModeSchema.parse(_queryMode);
53-
const timeFrame = timeFrameSchema.parse(_timeFrame);
55+
const queryMode = queryModeSchema.parse(rawQueryMode);
56+
const timeFrame = timeFrameSchema.parse(rawTimeFrame);
5457

5558
const isTopQueries = queryMode === QueryModeIds.top;
5659

0 commit comments

Comments
 (0)