ydb-embedded-ui 6.9.1 → 6.10.1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/components/NodeHostWrapper/NodeHostWrapper.scss +1 -1
- package/dist/components/{VirtualTable/VirtualTable.d.ts → PaginatedTable/PaginatedTable.d.ts} +3 -3
- package/dist/components/{VirtualTable/VirtualTable.js → PaginatedTable/PaginatedTable.js} +4 -4
- package/dist/components/{VirtualTable/VirtualTable.scss → PaginatedTable/PaginatedTable.scss} +11 -11
- package/dist/components/PaginatedTable/ResizeablePaginatedTable.d.ts +6 -0
- package/dist/components/{VirtualTable/ResizeableVirtualTable.js → PaginatedTable/ResizeablePaginatedTable.js} +3 -3
- package/dist/components/{VirtualTable → PaginatedTable}/i18n/index.js +1 -1
- package/dist/components/PaginatedTable/index.d.ts +4 -0
- package/dist/components/PaginatedTable/index.js +4 -0
- package/dist/components/{VirtualTable → PaginatedTable}/reducer.d.ts +3 -3
- package/dist/components/{VirtualTable → PaginatedTable}/reducer.js +1 -1
- package/dist/components/PaginatedTable/shared.js +2 -0
- package/dist/components/{VirtualTable → PaginatedTable}/types.d.ts +2 -2
- package/dist/components/TableWithControlsLayout/TableWithControlsLayout.scss +1 -1
- package/dist/components/VDisk/VDisk.js +19 -6
- package/dist/containers/App/App.d.ts +1 -1
- package/dist/containers/App/App.js +2 -2
- package/dist/containers/App/App.scss +1 -1
- package/dist/containers/AppWithClusters/AppWithClusters.js +1 -10
- package/dist/containers/AsideNavigation/Navigation.d.ts +1 -1
- package/dist/containers/Header/Header.js +5 -2
- package/dist/containers/Heatmap/Histogram/Histogram.js +3 -3
- package/dist/containers/Heatmap/util.js +2 -1
- package/dist/containers/Nodes/NodesWrapper.js +5 -5
- package/dist/containers/Nodes/{VirtualNodes.d.ts → PaginatedNodes.d.ts} +1 -1
- package/dist/containers/Nodes/{VirtualNodes.js → PaginatedNodes.js} +3 -3
- package/dist/containers/Nodes/getNodesColumns.d.ts +2 -2
- package/dist/containers/Storage/PDisk/PDisk.js +10 -2
- package/dist/containers/Storage/{VirtualStorage.d.ts → PaginatedStorage.d.ts} +2 -2
- package/dist/containers/Storage/{VirtualStorage.js → PaginatedStorage.js} +5 -5
- package/dist/containers/Storage/Storage.js +3 -12
- package/dist/containers/Storage/StorageGroups/{VirtualStorageGroups.d.ts → PaginatedStorageGroups.d.ts} +3 -3
- package/dist/containers/Storage/StorageGroups/{VirtualStorageGroups.js → PaginatedStorageGroups.js} +3 -3
- package/dist/containers/Storage/StorageGroups/getStorageGroupsColumns.d.ts +2 -2
- package/dist/containers/Storage/StorageNodes/{VirtualStorageNodes.d.ts → PaginatedStorageNodes.d.ts} +3 -3
- package/dist/containers/Storage/StorageNodes/{VirtualStorageNodes.js → PaginatedStorageNodes.js} +3 -3
- package/dist/containers/Storage/StorageWrapper.js +5 -5
- package/dist/containers/Tenant/Diagnostics/Diagnostics.scss +1 -1
- package/dist/containers/Tenant/Query/ExplainResult/ExplainResult.scss +1 -2
- package/dist/containers/Tenant/Query/Query.js +2 -8
- package/dist/containers/Tenant/Query/Query.scss +1 -1
- package/dist/containers/Tenant/Query/QueryEditor/QueryEditor.d.ts +2 -0
- package/dist/containers/Tenant/Query/QueryEditor/QueryEditor.js +23 -36
- package/dist/containers/Tenant/Query/QueryEditor/keybindings.d.ts +9 -0
- package/dist/containers/Tenant/Query/QueryEditor/keybindings.js +13 -0
- package/dist/containers/Tenant/Query/QueryEditorControls/QueryEditorControls.d.ts +1 -3
- package/dist/containers/Tenant/Query/QueryEditorControls/QueryEditorControls.js +3 -3
- package/dist/containers/Tenant/Query/SaveQuery/SaveQuery.d.ts +7 -6
- package/dist/containers/Tenant/Query/SaveQuery/SaveQuery.js +55 -47
- package/dist/containers/Tenant/Query/SaveQuery/SaveQuery.scss +2 -32
- package/dist/containers/Tenant/Query/SaveQuery/i18n/en.json +13 -0
- package/dist/containers/Tenant/Query/SaveQuery/i18n/index.d.ts +2 -0
- package/dist/containers/Tenant/Query/SaveQuery/i18n/index.js +4 -0
- package/dist/containers/Tenant/Query/SavedQueries/SavedQueries.d.ts +1 -4
- package/dist/containers/Tenant/Query/SavedQueries/SavedQueries.js +5 -3
- package/dist/containers/Tenant/Query/i18n/en.json +2 -1
- package/dist/containers/Tenant/Query/i18n/index.d.ts +1 -1
- package/dist/containers/Tenant/Query/utils/useSavedQueries.d.ts +2 -0
- package/dist/containers/Tenant/Query/utils/useSavedQueries.js +5 -0
- package/dist/containers/Tenant/Schema/SchemaTree/SchemaTree.js +6 -2
- package/dist/containers/Tenant/utils/schemaActions.d.ts +1 -1
- package/dist/containers/Tenant/utils/schemaActions.js +10 -4
- package/dist/containers/UserSettings/UserSettings.d.ts +1 -1
- package/dist/containers/UserSettings/UserSettings.js +1 -2
- package/dist/containers/UserSettings/i18n/en.json +9 -4
- package/dist/containers/UserSettings/i18n/index.d.ts +1 -1
- package/dist/containers/UserSettings/settings.d.ts +7 -2
- package/dist/containers/UserSettings/settings.js +38 -14
- package/dist/containers/Versions/NodesTreeTitle/NodesTreeTitle.scss +1 -2
- package/dist/lib.d.ts +1 -1
- package/dist/lib.js +1 -1
- package/dist/services/settings.d.ts +2 -0
- package/dist/services/settings.js +4 -2
- package/dist/store/configureStore.d.ts +4 -14
- package/dist/store/defaultStore.d.ts +2 -7
- package/dist/store/reducers/healthcheckInfo/healthcheckInfo.d.ts +20 -20
- package/dist/store/reducers/index.d.ts +3 -13
- package/dist/store/reducers/index.js +2 -2
- package/dist/store/reducers/node/selectors.d.ts +1 -1
- package/dist/store/reducers/nodesList.d.ts +1 -1
- package/dist/store/reducers/queryActions/queryActions.d.ts +34 -0
- package/dist/store/reducers/queryActions/queryActions.js +58 -0
- package/dist/store/reducers/queryActions/types.d.ts +5 -0
- package/dist/store/reducers/queryActions/types.js +1 -0
- package/dist/store/reducers/storage/storage.js +1 -1
- package/dist/store/reducers/tablets.d.ts +5 -5
- package/dist/store/reducers/tabletsFilters.d.ts +1 -1
- package/dist/store/reducers/tenants/selectors.d.ts +9 -9
- package/dist/store/reducers/topic.d.ts +15 -15
- package/dist/utils/constants.d.ts +3 -1
- package/dist/utils/constants.js +5 -2
- package/dist/utils/disks/prepareDisks.js +4 -2
- package/dist/utils/hooks/index.d.ts +0 -2
- package/dist/utils/hooks/index.js +0 -2
- package/package.json +1 -1
- package/dist/components/VirtualTable/ResizeableVirtualTable.d.ts +0 -6
- package/dist/components/VirtualTable/index.d.ts +0 -3
- package/dist/components/VirtualTable/index.js +0 -3
- package/dist/components/VirtualTable/shared.js +0 -2
- package/dist/containers/AppWithClusters/i18n/en.json +0 -4
- package/dist/containers/AppWithClusters/i18n/index.d.ts +0 -2
- package/dist/containers/AppWithClusters/i18n/index.js +0 -5
- package/dist/containers/AppWithClusters/i18n/ru.json +0 -4
- package/dist/store/reducers/saveQuery.d.ts +0 -12
- package/dist/store/reducers/saveQuery.js +0 -25
- package/dist/utils/hooks/useNodesRequestParams.d.ts +0 -15
- package/dist/utils/hooks/useNodesRequestParams.js +0 -23
- package/dist/utils/hooks/useStorageRequestParams.d.ts +0 -8
- package/dist/utils/hooks/useStorageRequestParams.js +0 -20
- /package/dist/components/{VirtualTable → PaginatedTable}/ResizeHandler.d.ts +0 -0
- /package/dist/components/{VirtualTable → PaginatedTable}/ResizeHandler.js +0 -0
- /package/dist/components/{VirtualTable → PaginatedTable}/TableChunk.d.ts +0 -0
- /package/dist/components/{VirtualTable → PaginatedTable}/TableChunk.js +0 -0
- /package/dist/components/{VirtualTable → PaginatedTable}/TableHead.d.ts +0 -0
- /package/dist/components/{VirtualTable → PaginatedTable}/TableHead.js +0 -0
- /package/dist/components/{VirtualTable → PaginatedTable}/TableRow.d.ts +0 -0
- /package/dist/components/{VirtualTable → PaginatedTable}/TableRow.js +0 -0
- /package/dist/components/{VirtualTable → PaginatedTable}/constants.d.ts +0 -0
- /package/dist/components/{VirtualTable → PaginatedTable}/constants.js +0 -0
- /package/dist/components/{VirtualTable → PaginatedTable}/i18n/en.json +0 -0
- /package/dist/components/{VirtualTable → PaginatedTable}/i18n/index.d.ts +0 -0
- /package/dist/components/{VirtualTable → PaginatedTable}/i18n/ru.json +0 -0
- /package/dist/components/{VirtualTable → PaginatedTable}/shared.d.ts +0 -0
- /package/dist/components/{VirtualTable → PaginatedTable}/types.js +0 -0
- /package/dist/components/{VirtualTable → PaginatedTable}/useIntersectionObserver.d.ts +0 -0
- /package/dist/components/{VirtualTable → PaginatedTable}/useIntersectionObserver.js +0 -0
- /package/dist/components/{VirtualTable → PaginatedTable}/utils.d.ts +0 -0
- /package/dist/components/{VirtualTable → PaginatedTable}/utils.js +0 -0
package/dist/components/{VirtualTable/VirtualTable.d.ts → PaginatedTable/PaginatedTable.d.ts}
RENAMED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import type { Column, FetchData, GetRowClassName, HandleTableColumnsResize, RenderControls, RenderEmptyDataMessage, RenderErrorMessage, SortParams } from './types';
|
|
2
|
-
import './
|
|
3
|
-
export interface
|
|
2
|
+
import './PaginatedTable.scss';
|
|
3
|
+
export interface PaginatedTableProps<T> {
|
|
4
4
|
limit: number;
|
|
5
5
|
fetchData: FetchData<T>;
|
|
6
6
|
columns: Column<T>[];
|
|
@@ -14,4 +14,4 @@ export interface VirtualTableProps<T> {
|
|
|
14
14
|
renderErrorMessage?: RenderErrorMessage;
|
|
15
15
|
dependencyArray?: unknown[];
|
|
16
16
|
}
|
|
17
|
-
export declare const
|
|
17
|
+
export declare const PaginatedTable: <T>({ limit, fetchData, columns, getRowClassName, rowHeight, parentContainer, initialSortParams, onColumnsResize, renderControls, renderEmptyDataMessage, renderErrorMessage, dependencyArray, }: PaginatedTableProps<T>) => import("react/jsx-runtime").JSX.Element;
|
|
@@ -8,14 +8,14 @@ import { TableHead } from './TableHead';
|
|
|
8
8
|
import { EmptyTableRow } from './TableRow';
|
|
9
9
|
import { DEFAULT_REQUEST_TIMEOUT, DEFAULT_TABLE_ROW_HEIGHT } from './constants';
|
|
10
10
|
import i18n from './i18n';
|
|
11
|
-
import {
|
|
11
|
+
import { createPaginatedTableReducer, initChunk, removeChunk, resetChunks, setChunkData, setChunkError, setChunkLoading, } from './reducer';
|
|
12
12
|
import { b } from './shared';
|
|
13
13
|
import { useIntersectionObserver } from './useIntersectionObserver';
|
|
14
|
-
import './
|
|
15
|
-
export const
|
|
14
|
+
import './PaginatedTable.scss';
|
|
15
|
+
export const PaginatedTable = ({ limit, fetchData, columns, getRowClassName, rowHeight = DEFAULT_TABLE_ROW_HEIGHT, parentContainer, initialSortParams, onColumnsResize, renderControls, renderEmptyDataMessage, renderErrorMessage, dependencyArray, }) => {
|
|
16
16
|
const inited = React.useRef(false);
|
|
17
17
|
const tableContainer = React.useRef(null);
|
|
18
|
-
const [state, dispatch] = React.useReducer(
|
|
18
|
+
const [state, dispatch] = React.useReducer(createPaginatedTableReducer(), {});
|
|
19
19
|
const [sortParams, setSortParams] = React.useState(initialSortParams);
|
|
20
20
|
const [totalEntities, setTotalEntities] = React.useState(limit);
|
|
21
21
|
const [foundEntities, setFoundEntities] = React.useState(0);
|
package/dist/components/{VirtualTable/VirtualTable.scss → PaginatedTable/PaginatedTable.scss}
RENAMED
|
@@ -1,13 +1,13 @@
|
|
|
1
1
|
@import '../../styles/mixins.scss';
|
|
2
2
|
|
|
3
|
-
.ydb-
|
|
3
|
+
.ydb-paginated-table {
|
|
4
4
|
$block: &;
|
|
5
|
-
$cell-border: 1px solid var(--
|
|
6
|
-
--
|
|
7
|
-
--
|
|
5
|
+
$cell-border: 1px solid var(--paginated-table-border-color);
|
|
6
|
+
--paginated-table-cell-vertical-padding: 5px;
|
|
7
|
+
--paginated-table-cell-horizontal-padding: 10px;
|
|
8
8
|
|
|
9
|
-
--
|
|
10
|
-
--
|
|
9
|
+
--paginated-table-border-color: var(--g-color-base-generic-hover);
|
|
10
|
+
--paginated-table-hover-color: var(--g-color-base-float-hover);
|
|
11
11
|
|
|
12
12
|
width: 100%;
|
|
13
13
|
@include body-2-typography();
|
|
@@ -27,7 +27,7 @@
|
|
|
27
27
|
|
|
28
28
|
&__row {
|
|
29
29
|
&:hover {
|
|
30
|
-
background: var(--
|
|
30
|
+
background: var(--paginated-table-hover-color);
|
|
31
31
|
}
|
|
32
32
|
|
|
33
33
|
&_empty {
|
|
@@ -75,8 +75,8 @@
|
|
|
75
75
|
|
|
76
76
|
width: 100%;
|
|
77
77
|
max-width: 100%;
|
|
78
|
-
padding: var(--
|
|
79
|
-
var(--
|
|
78
|
+
padding: var(--paginated-table-cell-vertical-padding)
|
|
79
|
+
var(--paginated-table-cell-horizontal-padding);
|
|
80
80
|
|
|
81
81
|
&_align {
|
|
82
82
|
&_left {
|
|
@@ -122,8 +122,8 @@
|
|
|
122
122
|
|
|
123
123
|
width: 100%;
|
|
124
124
|
max-width: 100%;
|
|
125
|
-
padding: var(--
|
|
126
|
-
var(--
|
|
125
|
+
padding: var(--paginated-table-cell-vertical-padding)
|
|
126
|
+
var(--paginated-table-cell-horizontal-padding);
|
|
127
127
|
|
|
128
128
|
vertical-align: middle;
|
|
129
129
|
white-space: nowrap;
|
|
@@ -0,0 +1,6 @@
|
|
|
1
|
+
import type { PaginatedTableProps } from './PaginatedTable';
|
|
2
|
+
interface ResizeablePaginatedTableProps<T> extends Omit<PaginatedTableProps<T>, 'onColumnsResize'> {
|
|
3
|
+
columnsWidthLSKey: string;
|
|
4
|
+
}
|
|
5
|
+
export declare function ResizeablePaginatedTable<T>({ columnsWidthLSKey, columns, ...props }: ResizeablePaginatedTableProps<T>): import("react/jsx-runtime").JSX.Element;
|
|
6
|
+
export {};
|
|
@@ -1,14 +1,14 @@
|
|
|
1
1
|
import { jsx as _jsx } from "react/jsx-runtime";
|
|
2
2
|
import { useTableResize } from '../../utils/hooks/useTableResize';
|
|
3
|
-
import {
|
|
3
|
+
import { PaginatedTable } from './PaginatedTable';
|
|
4
4
|
function updateColumnsWidth(columns, columnsWidthSetup) {
|
|
5
5
|
return columns.map((column) => {
|
|
6
6
|
var _a;
|
|
7
7
|
return { ...column, width: (_a = columnsWidthSetup[column.name]) !== null && _a !== void 0 ? _a : column.width };
|
|
8
8
|
});
|
|
9
9
|
}
|
|
10
|
-
export function
|
|
10
|
+
export function ResizeablePaginatedTable({ columnsWidthLSKey, columns, ...props }) {
|
|
11
11
|
const [tableColumnsWidth, setTableColumnsWidth] = useTableResize(columnsWidthLSKey);
|
|
12
12
|
const updatedColumns = updateColumnsWidth(columns, tableColumnsWidth);
|
|
13
|
-
return (_jsx(
|
|
13
|
+
return (_jsx(PaginatedTable, { columns: updatedColumns, onColumnsResize: setTableColumnsWidth, ...props }));
|
|
14
14
|
}
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import type { IResponseError } from '../../types/api/error';
|
|
2
2
|
import type { Chunk } from './types';
|
|
3
3
|
declare const SET_CHUNK_DATA = "infiniteTable/SET_CHUNK_DATA";
|
|
4
|
-
type
|
|
4
|
+
type PaginatedTableState<T> = Record<string, Chunk<T> | undefined>;
|
|
5
5
|
interface SetChunkDataAction<T> {
|
|
6
6
|
type: typeof SET_CHUNK_DATA;
|
|
7
7
|
data: {
|
|
@@ -38,6 +38,6 @@ export declare const removeChunk: (id: string) => {
|
|
|
38
38
|
export declare const resetChunks: () => {
|
|
39
39
|
readonly type: "infiniteTable/RESET_CHUNKS";
|
|
40
40
|
};
|
|
41
|
-
type
|
|
42
|
-
export declare const
|
|
41
|
+
type PaginatedTableAction<T> = SetChunkDataAction<T> | ReturnType<typeof setChunkError> | ReturnType<typeof initChunk> | ReturnType<typeof setChunkLoading> | ReturnType<typeof removeChunk> | ReturnType<typeof resetChunks>;
|
|
42
|
+
export declare const createPaginatedTableReducer: <T>() => React.Reducer<PaginatedTableState<T>, PaginatedTableAction<T>>;
|
|
43
43
|
export {};
|
|
@@ -40,7 +40,7 @@ export const resetChunks = () => {
|
|
|
40
40
|
};
|
|
41
41
|
};
|
|
42
42
|
// Reducer wrapped in additional function to pass generic type
|
|
43
|
-
export const
|
|
43
|
+
export const createPaginatedTableReducer = () => (state, action) => {
|
|
44
44
|
switch (action.type) {
|
|
45
45
|
case SET_CHUNK_DATA: {
|
|
46
46
|
const { id, data } = action.data;
|
|
@@ -33,12 +33,12 @@ export interface Column<T> {
|
|
|
33
33
|
resizeMinWidth?: number;
|
|
34
34
|
align: AlignType;
|
|
35
35
|
}
|
|
36
|
-
export interface
|
|
36
|
+
export interface PaginatedTableData<T> {
|
|
37
37
|
data: T[];
|
|
38
38
|
total: number;
|
|
39
39
|
found: number;
|
|
40
40
|
}
|
|
41
|
-
export type FetchData<T> = (limit: number, offset: number, sortParams?: SortParams) => Promise<
|
|
41
|
+
export type FetchData<T> = (limit: number, offset: number, sortParams?: SortParams) => Promise<PaginatedTableData<T>>;
|
|
42
42
|
export type OnError = (error?: IResponseError) => void;
|
|
43
43
|
interface ControlsParams {
|
|
44
44
|
totalEntities: number;
|
|
@@ -1,18 +1,21 @@
|
|
|
1
1
|
import { jsx as _jsx, jsxs as _jsxs } from "react/jsx-runtime";
|
|
2
2
|
import React from 'react';
|
|
3
3
|
import { STRUCTURE } from '../../containers/Node/NodePages';
|
|
4
|
-
import routes, { createHref } from '../../routes';
|
|
4
|
+
import routes, { createHref, getVDiskPagePath } from '../../routes';
|
|
5
|
+
import { valueIsDefined } from '../../utils';
|
|
5
6
|
import { cn } from '../../utils/cn';
|
|
7
|
+
import { USE_SEPARATE_DISKS_PAGES_KEY } from '../../utils/constants';
|
|
6
8
|
import { stringifyVdiskId } from '../../utils/dataFormatters/dataFormatters';
|
|
7
9
|
import { isFullVDiskData } from '../../utils/disks/helpers';
|
|
10
|
+
import { useSetting } from '../../utils/hooks';
|
|
8
11
|
import { DiskStateProgressBar } from '../DiskStateProgressBar/DiskStateProgressBar';
|
|
9
12
|
import { InternalLink } from '../InternalLink';
|
|
10
13
|
import { VDiskPopup } from '../VDiskPopup/VDiskPopup';
|
|
11
14
|
import './VDisk.scss';
|
|
12
15
|
const b = cn('ydb-vdisk-component');
|
|
13
16
|
export const VDisk = ({ data = {}, nodes, compact }) => {
|
|
14
|
-
var _a, _b;
|
|
15
17
|
const isFullData = isFullVDiskData(data);
|
|
18
|
+
const [useSeparateDisksPages] = useSetting(USE_SEPARATE_DISKS_PAGES_KEY);
|
|
16
19
|
const [isPopupVisible, setIsPopupVisible] = React.useState(false);
|
|
17
20
|
const anchor = React.useRef(null);
|
|
18
21
|
const showPopup = () => {
|
|
@@ -21,8 +24,18 @@ export const VDisk = ({ data = {}, nodes, compact }) => {
|
|
|
21
24
|
const hidePopup = () => {
|
|
22
25
|
setIsPopupVisible(false);
|
|
23
26
|
};
|
|
24
|
-
|
|
25
|
-
|
|
26
|
-
|
|
27
|
-
|
|
27
|
+
let vDiskPath;
|
|
28
|
+
if (useSeparateDisksPages &&
|
|
29
|
+
valueIsDefined(data.VDiskSlotId) &&
|
|
30
|
+
valueIsDefined(data.PDiskId) &&
|
|
31
|
+
valueIsDefined(data.NodeId)) {
|
|
32
|
+
vDiskPath = getVDiskPagePath(data.VDiskSlotId, data.PDiskId, data.NodeId);
|
|
33
|
+
}
|
|
34
|
+
else if (valueIsDefined(data.NodeId) && isFullData) {
|
|
35
|
+
vDiskPath = createHref(routes.node, { id: data.NodeId, activeTab: STRUCTURE }, {
|
|
36
|
+
pdiskId: data.PDiskId,
|
|
37
|
+
vdiskId: stringifyVdiskId(data.VDiskId),
|
|
38
|
+
});
|
|
39
|
+
}
|
|
40
|
+
return (_jsxs(React.Fragment, { children: [_jsx(VDiskPopup, { data: data, nodes: nodes, anchorRef: anchor, open: isPopupVisible }), _jsx("div", { className: b(), ref: anchor, onMouseEnter: showPopup, onMouseLeave: hidePopup, children: vDiskPath ? (_jsx(InternalLink, { to: vDiskPath, className: b('content'), children: _jsx(DiskStateProgressBar, { diskAllocatedPercent: data.AllocatedPercent, severity: data.Severity, compact: compact }) })) : (_jsx(DiskStateProgressBar, { diskAllocatedPercent: data.AllocatedPercent, severity: data.Severity, compact: compact })) })] }));
|
|
28
41
|
};
|
|
@@ -10,7 +10,7 @@ export interface AppProps {
|
|
|
10
10
|
userSettings?: YDBEmbeddedUISettings;
|
|
11
11
|
children?: React.ReactNode;
|
|
12
12
|
}
|
|
13
|
-
declare function App({ store, history, singleClusterMode, children, userSettings }: AppProps): import("react/jsx-runtime").JSX.Element;
|
|
13
|
+
declare function App({ store, history, singleClusterMode, children, userSettings, }: AppProps): import("react/jsx-runtime").JSX.Element;
|
|
14
14
|
declare const _default: import("react-redux").ConnectedComponent<typeof App, {
|
|
15
15
|
history: History;
|
|
16
16
|
userSettings?: YDBEmbeddedUISettings;
|
|
@@ -4,11 +4,11 @@ import { connect } from 'react-redux';
|
|
|
4
4
|
import { ErrorBoundary } from '../../components/ErrorBoundary/ErrorBoundary';
|
|
5
5
|
import { Navigation } from '../AsideNavigation/Navigation';
|
|
6
6
|
import ReduxTooltip from '../ReduxTooltip/ReduxTooltip';
|
|
7
|
-
import {
|
|
7
|
+
import { getUserSettings } from '../UserSettings/settings';
|
|
8
8
|
import ContentWrapper, { Content } from './Content';
|
|
9
9
|
import { Providers } from './Providers';
|
|
10
10
|
import './App.scss';
|
|
11
|
-
function App({ store, history, singleClusterMode, children, userSettings =
|
|
11
|
+
function App({ store, history, singleClusterMode, children, userSettings = getUserSettings({ singleClusterMode }), }) {
|
|
12
12
|
return (_jsxs(Providers, { store: store, history: history, children: [_jsx(Helmet, { defaultTitle: "YDB Monitoring", titleTemplate: "%s \u2014 YDB Monitoring" }), _jsx(ContentWrapper, { children: _jsx(Navigation, { userSettings: userSettings, children: _jsxs(ErrorBoundary, { children: [_jsx(Content, { singleClusterMode: singleClusterMode, children: children }), _jsx("div", { id: "fullscreen-root" })] }) }) }), _jsx(ReduxTooltip, {})] }));
|
|
13
13
|
}
|
|
14
14
|
function mapStateToProps(state) {
|
|
@@ -1,19 +1,10 @@
|
|
|
1
1
|
import { jsx as _jsx, jsxs as _jsxs } from "react/jsx-runtime";
|
|
2
|
-
import { USE_CLUSTER_BALANCER_AS_BACKEND_KEY } from '../../utils/constants';
|
|
3
2
|
import { getMonitoringClusterLink as getMonitoringClusterLinkDefault, getMonitoringLink as getMonitoringLinkDefault, } from '../../utils/monitoring';
|
|
4
3
|
import { App, AppSlots } from '../App';
|
|
5
|
-
import { settings } from '../UserSettings/settings';
|
|
6
4
|
import { ExtendedCluster } from './ExtendedCluster/ExtendedCluster';
|
|
7
5
|
import { ExtendedNode } from './ExtendedNode/ExtendedNode';
|
|
8
6
|
import { ExtendedTenant } from './ExtendedTenant/ExtendedTenant';
|
|
9
|
-
|
|
10
|
-
const defaultUserSettings = settings;
|
|
11
|
-
defaultUserSettings[2].sections[0].settings.push({
|
|
12
|
-
title: i18n('settings.useClusterBalancerAsBackend.title'),
|
|
13
|
-
description: i18n('settings.useClusterBalancerAsBackend.popover'),
|
|
14
|
-
settingKey: USE_CLUSTER_BALANCER_AS_BACKEND_KEY,
|
|
15
|
-
});
|
|
16
|
-
export function AppWithClusters({ store, history, getMonitoringLink = getMonitoringLinkDefault, getMonitoringClusterLink = getMonitoringClusterLinkDefault, userSettings = defaultUserSettings, children, }) {
|
|
7
|
+
export function AppWithClusters({ store, history, getMonitoringLink = getMonitoringLinkDefault, getMonitoringClusterLink = getMonitoringClusterLinkDefault, userSettings, children, }) {
|
|
17
8
|
return (_jsxs(App, { store: store, history: history, userSettings: userSettings, children: [_jsx(AppSlots.ClusterSlot, { children: ({ component }) => {
|
|
18
9
|
return (_jsx(ExtendedCluster, { component: component, getMonitoringLink: getMonitoringLink, getMonitoringClusterLink: getMonitoringClusterLink }));
|
|
19
10
|
} }), _jsx(AppSlots.NodeSlot, { children: ({ component }) => {
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import type { YDBEmbeddedUISettings } from '../UserSettings/settings';
|
|
2
2
|
interface NavigationProps {
|
|
3
|
-
userSettings
|
|
3
|
+
userSettings: YDBEmbeddedUISettings;
|
|
4
4
|
children: React.ReactNode;
|
|
5
5
|
}
|
|
6
6
|
export declare function Navigation({ children, userSettings }: NavigationProps): import("react/jsx-runtime").JSX.Element;
|
|
@@ -29,12 +29,15 @@ function Header({ mainPage }) {
|
|
|
29
29
|
const clusterName = get(clusterInfo, ['currentData', 'clusterData', 'Name'], queryParams.clusterName);
|
|
30
30
|
const breadcrumbItems = React.useMemo(() => {
|
|
31
31
|
const rawBreadcrumbs = [];
|
|
32
|
-
|
|
32
|
+
let options = pageBreadcrumbsOptions;
|
|
33
33
|
if (mainPage) {
|
|
34
34
|
rawBreadcrumbs.push(mainPage);
|
|
35
35
|
}
|
|
36
36
|
if (clusterName) {
|
|
37
|
-
options
|
|
37
|
+
options = {
|
|
38
|
+
...options,
|
|
39
|
+
clusterName,
|
|
40
|
+
};
|
|
38
41
|
}
|
|
39
42
|
const breadcrumbs = getBreadcrumbs(page, options, rawBreadcrumbs, queryParams);
|
|
40
43
|
return breadcrumbs.map((item) => {
|
|
@@ -42,10 +42,10 @@ export const Histogram = (props) => {
|
|
|
42
42
|
});
|
|
43
43
|
let maxCount = 0;
|
|
44
44
|
tablets.forEach((tablet) => {
|
|
45
|
-
var _a;
|
|
46
|
-
const value = currentMetric && Number(tablet.metrics[currentMetric]);
|
|
45
|
+
var _a, _b;
|
|
46
|
+
const value = currentMetric && Number((_a = tablet.metrics) === null || _a === void 0 ? void 0 : _a[currentMetric]);
|
|
47
47
|
const bucketIndex = Math.floor(value / step);
|
|
48
|
-
const nextCountValue = ((
|
|
48
|
+
const nextCountValue = ((_b = histogramRange[bucketIndex]) === null || _b === void 0 ? void 0 : _b.count) + 1;
|
|
49
49
|
if (nextCountValue > maxCount) {
|
|
50
50
|
maxCount = nextCountValue;
|
|
51
51
|
}
|
|
@@ -77,7 +77,8 @@ export const getCurrentMetricLimits = (metric, tablets) => {
|
|
|
77
77
|
const limits = new Set();
|
|
78
78
|
const limitedMetric = LIMITED_METRICS[metric] || {};
|
|
79
79
|
tablets.forEach((tablet) => {
|
|
80
|
-
|
|
80
|
+
var _a;
|
|
81
|
+
limits.add(Number((_a = tablet.metrics) === null || _a === void 0 ? void 0 : _a[metric]));
|
|
81
82
|
});
|
|
82
83
|
if (Number.isInteger(limitedMetric.min)) {
|
|
83
84
|
limits.add(limitedMetric.min);
|
|
@@ -1,12 +1,12 @@
|
|
|
1
1
|
import { jsx as _jsx } from "react/jsx-runtime";
|
|
2
|
-
import {
|
|
2
|
+
import { USE_PAGINATED_TABLES_KEY } from '../../utils/constants';
|
|
3
3
|
import { useSetting } from '../../utils/hooks';
|
|
4
4
|
import { Nodes } from './Nodes';
|
|
5
|
-
import {
|
|
5
|
+
import { PaginatedNodes } from './PaginatedNodes';
|
|
6
6
|
export const NodesWrapper = ({ parentContainer, ...props }) => {
|
|
7
|
-
const [
|
|
8
|
-
if (
|
|
9
|
-
return _jsx(
|
|
7
|
+
const [usePaginatedTables] = useSetting(USE_PAGINATED_TABLES_KEY);
|
|
8
|
+
if (usePaginatedTables) {
|
|
9
|
+
return _jsx(PaginatedNodes, { parentContainer: parentContainer, ...props });
|
|
10
10
|
}
|
|
11
11
|
return _jsx(Nodes, { ...props });
|
|
12
12
|
};
|
|
@@ -5,5 +5,5 @@ interface NodesProps {
|
|
|
5
5
|
parentContainer?: Element | null;
|
|
6
6
|
additionalNodesProps?: AdditionalNodesProps;
|
|
7
7
|
}
|
|
8
|
-
export declare const
|
|
8
|
+
export declare const PaginatedNodes: ({ path, parentContainer, additionalNodesProps }: NodesProps) => import("react/jsx-runtime").JSX.Element;
|
|
9
9
|
export {};
|
|
@@ -5,10 +5,10 @@ import { EntitiesCount } from '../../components/EntitiesCount';
|
|
|
5
5
|
import { AccessDenied } from '../../components/Errors/403';
|
|
6
6
|
import { ResponseError } from '../../components/Errors/ResponseError';
|
|
7
7
|
import { Illustration } from '../../components/Illustration';
|
|
8
|
+
import { ResizeablePaginatedTable } from '../../components/PaginatedTable';
|
|
8
9
|
import { ProblemFilter } from '../../components/ProblemFilter';
|
|
9
10
|
import { Search } from '../../components/Search';
|
|
10
11
|
import { UptimeFilter } from '../../components/UptimeFIlter';
|
|
11
|
-
import { ResizeableVirtualTable } from '../../components/VirtualTable/ResizeableVirtualTable';
|
|
12
12
|
import { ProblemFilterValues, changeFilter, selectProblemFilter, } from '../../store/reducers/settings/settings';
|
|
13
13
|
import { cn } from '../../utils/cn';
|
|
14
14
|
import { useTypedDispatch, useTypedSelector } from '../../utils/hooks';
|
|
@@ -18,7 +18,7 @@ import { NODES_COLUMNS_WIDTH_LS_KEY, getNodesColumns } from './getNodesColumns';
|
|
|
18
18
|
import i18n from './i18n';
|
|
19
19
|
import './Nodes.scss';
|
|
20
20
|
const b = cn('ydb-nodes');
|
|
21
|
-
export const
|
|
21
|
+
export const PaginatedNodes = ({ path, parentContainer, additionalNodesProps }) => {
|
|
22
22
|
var _a;
|
|
23
23
|
const [queryParams, setQueryParams] = useQueryParams({
|
|
24
24
|
uptimeFilter: StringParam,
|
|
@@ -77,5 +77,5 @@ export const VirtualNodes = ({ path, parentContainer, additionalNodesProps }) =>
|
|
|
77
77
|
const columns = rawColumns.map((column) => {
|
|
78
78
|
return { ...column, sortable: isSortableNodesProperty(column.name) };
|
|
79
79
|
});
|
|
80
|
-
return (_jsx(
|
|
80
|
+
return (_jsx(ResizeablePaginatedTable, { columnsWidthLSKey: NODES_COLUMNS_WIDTH_LS_KEY, parentContainer: parentContainer, columns: columns, fetchData: fetchData, limit: 50, renderControls: renderControls, renderErrorMessage: renderErrorMessage, renderEmptyDataMessage: renderEmptyDataMessage, dependencyArray: filters, getRowClassName: getRowClassName }));
|
|
81
81
|
};
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import type { Column as DataTableColumn } from '@gravity-ui/react-data-table';
|
|
2
|
-
import type { Column as
|
|
2
|
+
import type { Column as PaginatedTableColumn } from '../../components/PaginatedTable';
|
|
3
3
|
import type { NodesPreparedEntity } from '../../store/reducers/nodes/types';
|
|
4
4
|
import type { GetNodeRefFunc } from '../../types/additionalProps';
|
|
5
5
|
export declare const NODES_COLUMNS_WIDTH_LS_KEY = "nodesTableColumnsWidth";
|
|
@@ -7,7 +7,7 @@ interface GetNodesColumnsProps {
|
|
|
7
7
|
tabletsPath?: string;
|
|
8
8
|
getNodeRef?: GetNodeRefFunc;
|
|
9
9
|
}
|
|
10
|
-
type NodesColumn =
|
|
10
|
+
type NodesColumn = PaginatedTableColumn<NodesPreparedEntity> & DataTableColumn<NodesPreparedEntity>;
|
|
11
11
|
export declare function getNodesColumns({ tabletsPath, getNodeRef }: GetNodesColumnsProps): NodesColumn[];
|
|
12
12
|
export declare function getTopNodesByLoadColumns(getNodeRef?: GetNodeRefFunc): DataTableColumn<NodesPreparedEntity>[];
|
|
13
13
|
export declare function getTopNodesByCpuColumns(getNodeRef?: GetNodeRefFunc): DataTableColumn<NodesPreparedEntity>[];
|
|
@@ -4,14 +4,18 @@ import { DiskStateProgressBar } from '../../../components/DiskStateProgressBar/D
|
|
|
4
4
|
import { InternalLink } from '../../../components/InternalLink';
|
|
5
5
|
import { PDiskPopup } from '../../../components/PDiskPopup/PDiskPopup';
|
|
6
6
|
import { VDiskWithDonorsStack } from '../../../components/VDisk/VDiskWithDonorsStack';
|
|
7
|
-
import routes, { createHref } from '../../../routes';
|
|
7
|
+
import routes, { createHref, getPDiskPagePath } from '../../../routes';
|
|
8
|
+
import { valueIsDefined } from '../../../utils';
|
|
8
9
|
import { cn } from '../../../utils/cn';
|
|
10
|
+
import { USE_SEPARATE_DISKS_PAGES_KEY } from '../../../utils/constants';
|
|
9
11
|
import { stringifyVdiskId } from '../../../utils/dataFormatters/dataFormatters';
|
|
12
|
+
import { useSetting } from '../../../utils/hooks';
|
|
10
13
|
import { STRUCTURE } from '../../Node/NodePages';
|
|
11
14
|
import './PDisk.scss';
|
|
12
15
|
const b = cn('pdisk-storage');
|
|
13
16
|
export const PDisk = ({ nodeId, data = {}, vDisks }) => {
|
|
14
17
|
const [isPopupVisible, setIsPopupVisible] = React.useState(false);
|
|
18
|
+
const [useSeparateDisksPages] = useSetting(USE_SEPARATE_DISKS_PAGES_KEY);
|
|
15
19
|
const anchor = React.useRef(null);
|
|
16
20
|
const showPopup = () => {
|
|
17
21
|
setIsPopupVisible(true);
|
|
@@ -31,5 +35,9 @@ export const PDisk = ({ nodeId, data = {}, vDisks }) => {
|
|
|
31
35
|
}, children: _jsx(VDiskWithDonorsStack, { data: vdisk, compact: true, stackClassName: b('donors-stack') }) }, stringifyVdiskId(vdisk.VDiskId)));
|
|
32
36
|
}) }));
|
|
33
37
|
};
|
|
34
|
-
|
|
38
|
+
let pDiskPath = createHref(routes.node, { id: nodeId, activeTab: STRUCTURE }, { pdiskId: data.PDiskId || '' });
|
|
39
|
+
if (useSeparateDisksPages && valueIsDefined(data.PDiskId)) {
|
|
40
|
+
pDiskPath = getPDiskPagePath(data.PDiskId, nodeId);
|
|
41
|
+
}
|
|
42
|
+
return (_jsxs(React.Fragment, { children: [_jsx(PDiskPopup, { data: data, anchorRef: anchor, open: isPopupVisible }), _jsxs("div", { className: b(), ref: anchor, children: [renderVDisks(), _jsxs(InternalLink, { to: pDiskPath, className: b('content'), onMouseEnter: showPopup, onMouseLeave: hidePopup, children: [_jsx(DiskStateProgressBar, { diskAllocatedPercent: data.AllocatedPercent, severity: data.Severity }), _jsx("div", { className: b('media-type'), children: data.Type })] })] })] }));
|
|
35
43
|
};
|
|
@@ -1,9 +1,9 @@
|
|
|
1
1
|
import type { AdditionalNodesProps } from '../../types/additionalProps';
|
|
2
|
-
interface
|
|
2
|
+
interface PaginatedStorageProps {
|
|
3
3
|
tenant?: string;
|
|
4
4
|
nodeId?: string;
|
|
5
5
|
parentContainer?: Element | null;
|
|
6
6
|
additionalNodesProps?: AdditionalNodesProps;
|
|
7
7
|
}
|
|
8
|
-
export declare const
|
|
8
|
+
export declare const PaginatedStorage: ({ tenant, nodeId, parentContainer, additionalNodesProps, }: PaginatedStorageProps) => import("react/jsx-runtime").JSX.Element;
|
|
9
9
|
export {};
|
|
@@ -8,9 +8,9 @@ import { storageTypeSchema, visibleEntitiesSchema } from '../../store/reducers/s
|
|
|
8
8
|
import { useTypedSelector } from '../../utils/hooks';
|
|
9
9
|
import { NodesUptimeFilterValues, nodesUptimeFilterValuesSchema } from '../../utils/nodes';
|
|
10
10
|
import { StorageControls } from './StorageControls/StorageControls';
|
|
11
|
-
import {
|
|
12
|
-
import {
|
|
13
|
-
export const
|
|
11
|
+
import { PaginatedStorageGroups } from './StorageGroups/PaginatedStorageGroups';
|
|
12
|
+
import { PaginatedStorageNodes } from './StorageNodes/PaginatedStorageNodes';
|
|
13
|
+
export const PaginatedStorage = ({ tenant, nodeId, parentContainer, additionalNodesProps, }) => {
|
|
14
14
|
var _a;
|
|
15
15
|
const [queryParams, setQueryParams] = useQueryParams({
|
|
16
16
|
type: StringParam,
|
|
@@ -54,7 +54,7 @@ export const VirtualStorage = ({ tenant, nodeId, parentContainer, additionalNode
|
|
|
54
54
|
return _jsx(ResponseError, { error: error });
|
|
55
55
|
};
|
|
56
56
|
if (storageType === STORAGE_TYPES.nodes) {
|
|
57
|
-
return (_jsx(
|
|
57
|
+
return (_jsx(PaginatedStorageNodes, { searchValue: searchValue, visibleEntities: visibleEntities, nodesUptimeFilter: nodesUptimeFilter, tenant: tenant, additionalNodesProps: additionalNodesProps, onShowAll: handleShowAllNodes, parentContainer: parentContainer, renderControls: renderControls, renderErrorMessage: renderErrorMessage }));
|
|
58
58
|
}
|
|
59
|
-
return (_jsx(
|
|
59
|
+
return (_jsx(PaginatedStorageGroups, { searchValue: searchValue, visibleEntities: visibleEntities, tenant: tenant, nodeId: nodeId, nodesMap: nodesMap, onShowAll: handleShowAllGroups, parentContainer: parentContainer, renderControls: renderControls, renderErrorMessage: renderErrorMessage }));
|
|
60
60
|
};
|
|
@@ -10,7 +10,7 @@ import { filterGroups, filterNodes, getUsageFilterOptions, } from '../../store/r
|
|
|
10
10
|
import { storageApi } from '../../store/reducers/storage/storage';
|
|
11
11
|
import { storageTypeSchema, visibleEntitiesSchema } from '../../store/reducers/storage/types';
|
|
12
12
|
import { DEFAULT_TABLE_SETTINGS } from '../../utils/constants';
|
|
13
|
-
import { useAutoRefreshInterval,
|
|
13
|
+
import { useAutoRefreshInterval, useTableSort, useTypedSelector } from '../../utils/hooks';
|
|
14
14
|
import { NodesUptimeFilterValues, nodesUptimeFilterValuesSchema } from '../../utils/nodes';
|
|
15
15
|
import { StorageControls } from './StorageControls/StorageControls';
|
|
16
16
|
import { StorageGroups } from './StorageGroups/StorageGroups';
|
|
@@ -59,20 +59,11 @@ export const Storage = ({ additionalNodesProps, tenant, nodeId }) => {
|
|
|
59
59
|
// Do not display Nodes table for Node page (NodeId present)
|
|
60
60
|
const isNodePage = nodeId !== undefined;
|
|
61
61
|
const storageType = isNodePage ? STORAGE_TYPES.groups : type;
|
|
62
|
-
const
|
|
63
|
-
filter,
|
|
64
|
-
nodesUptimeFilter: uptimeFilter,
|
|
65
|
-
...nodesSortParams,
|
|
66
|
-
});
|
|
67
|
-
const storageRequestParams = useStorageRequestParams({
|
|
68
|
-
filter,
|
|
69
|
-
...groupsSortParams,
|
|
70
|
-
});
|
|
71
|
-
const nodesQuery = storageApi.useGetStorageNodesInfoQuery({ tenant, visibleEntities, ...nodesRequestParams }, {
|
|
62
|
+
const nodesQuery = storageApi.useGetStorageNodesInfoQuery({ tenant, visibleEntities }, {
|
|
72
63
|
skip: storageType !== STORAGE_TYPES.nodes,
|
|
73
64
|
pollingInterval: autoRefreshInterval,
|
|
74
65
|
});
|
|
75
|
-
const groupsQuery = storageApi.useGetStorageGroupsInfoQuery({ tenant, visibleEntities, nodeId
|
|
66
|
+
const groupsQuery = storageApi.useGetStorageGroupsInfoQuery({ tenant, visibleEntities, nodeId }, {
|
|
76
67
|
skip: storageType !== STORAGE_TYPES.groups,
|
|
77
68
|
pollingInterval: autoRefreshInterval,
|
|
78
69
|
});
|
|
@@ -1,7 +1,7 @@
|
|
|
1
|
-
import type { RenderControls, RenderErrorMessage } from '../../../components/
|
|
1
|
+
import type { RenderControls, RenderErrorMessage } from '../../../components/PaginatedTable';
|
|
2
2
|
import type { VisibleEntities } from '../../../store/reducers/storage/types';
|
|
3
3
|
import type { NodesMap } from '../../../types/store/nodesList';
|
|
4
|
-
interface
|
|
4
|
+
interface PaginatedStorageGroupsProps {
|
|
5
5
|
searchValue: string;
|
|
6
6
|
visibleEntities: VisibleEntities;
|
|
7
7
|
tenant?: string;
|
|
@@ -12,5 +12,5 @@ interface VirtualStorageGroupsProps {
|
|
|
12
12
|
renderControls: RenderControls;
|
|
13
13
|
renderErrorMessage: RenderErrorMessage;
|
|
14
14
|
}
|
|
15
|
-
export declare const
|
|
15
|
+
export declare const PaginatedStorageGroups: ({ searchValue, visibleEntities, tenant, nodeId, nodesMap, onShowAll, parentContainer, renderControls, renderErrorMessage, }: PaginatedStorageGroupsProps) => import("react/jsx-runtime").JSX.Element;
|
|
16
16
|
export {};
|
package/dist/containers/Storage/StorageGroups/{VirtualStorageGroups.js → PaginatedStorageGroups.js}
RENAMED
|
@@ -1,12 +1,12 @@
|
|
|
1
1
|
import { jsx as _jsx } from "react/jsx-runtime";
|
|
2
2
|
import React from 'react';
|
|
3
|
-
import {
|
|
3
|
+
import { ResizeablePaginatedTable } from '../../../components/PaginatedTable';
|
|
4
4
|
import { VISIBLE_ENTITIES } from '../../../store/reducers/storage/constants';
|
|
5
5
|
import { StorageGroupsEmptyDataMessage } from './StorageGroupsEmptyDataMessage';
|
|
6
6
|
import { getStorageGroups } from './getGroups';
|
|
7
7
|
import { STORAGE_GROUPS_COLUMNS_WIDTH_LS_KEY, getPreparedStorageGroupsColumns, } from './getStorageGroupsColumns';
|
|
8
8
|
import i18n from './i18n';
|
|
9
|
-
export const
|
|
9
|
+
export const PaginatedStorageGroups = ({ searchValue, visibleEntities, tenant, nodeId, nodesMap, onShowAll, parentContainer, renderControls, renderErrorMessage, }) => {
|
|
10
10
|
const filters = React.useMemo(() => {
|
|
11
11
|
return [searchValue, visibleEntities, tenant, nodeId];
|
|
12
12
|
}, [searchValue, visibleEntities, tenant, nodeId]);
|
|
@@ -31,5 +31,5 @@ export const VirtualStorageGroups = ({ searchValue, visibleEntities, tenant, nod
|
|
|
31
31
|
}
|
|
32
32
|
return i18n('empty.default');
|
|
33
33
|
};
|
|
34
|
-
return (_jsx(
|
|
34
|
+
return (_jsx(ResizeablePaginatedTable, { columnsWidthLSKey: STORAGE_GROUPS_COLUMNS_WIDTH_LS_KEY, parentContainer: parentContainer, columns: columns, fetchData: fetchData, limit: 50, renderControls: renderControls, renderErrorMessage: renderErrorMessage, renderEmptyDataMessage: renderEmptyDataMessage, dependencyArray: filters }));
|
|
35
35
|
};
|
|
@@ -1,11 +1,11 @@
|
|
|
1
1
|
import React from 'react';
|
|
2
2
|
import type { Column as DataTableColumn } from '@gravity-ui/react-data-table';
|
|
3
|
-
import type { Column as
|
|
3
|
+
import type { Column as PaginatedTableColumn } from '../../../components/PaginatedTable';
|
|
4
4
|
import type { PreparedStorageGroup, VisibleEntities } from '../../../store/reducers/storage/types';
|
|
5
5
|
import type { NodesMap } from '../../../types/store/nodesList';
|
|
6
6
|
import './StorageGroups.scss';
|
|
7
7
|
export declare const STORAGE_GROUPS_COLUMNS_WIDTH_LS_KEY = "storageGroupsColumnsWidth";
|
|
8
|
-
type StorageGroupsColumn =
|
|
8
|
+
type StorageGroupsColumn = PaginatedTableColumn<PreparedStorageGroup> & DataTableColumn<PreparedStorageGroup>;
|
|
9
9
|
export declare const GROUPS_COLUMNS_IDS: {
|
|
10
10
|
readonly PoolName: "PoolName";
|
|
11
11
|
readonly MediaType: "MediaType";
|