|
| 1 | +import {HelpPopover} from '@gravity-ui/components'; |
| 2 | +import {Button, Tabs} from '@gravity-ui/uikit'; |
| 3 | +import cn from 'bem-cn-lite'; |
| 4 | +import qs from 'qs'; |
1 | 5 | import React, {ReactNode, useEffect, useReducer} from 'react'; |
2 | 6 | import {useDispatch} from 'react-redux'; |
3 | 7 | import {useLocation} from 'react-router'; |
4 | 8 | import {Link} from 'react-router-dom'; |
5 | | -import qs from 'qs'; |
6 | | -import cn from 'bem-cn-lite'; |
7 | | - |
8 | | -import {Button, Tabs} from '@gravity-ui/uikit'; |
9 | | -import {HelpPopover} from '@gravity-ui/components'; |
10 | | - |
11 | | -import SplitPane from '../../../components/SplitPane'; |
12 | | -import CopyToClipboard from '../../../components/CopyToClipboard/CopyToClipboard'; |
| 9 | +import {ClipboardButton} from '../../../components/ClipboardButton'; |
| 10 | +import {Icon} from '../../../components/Icon'; |
13 | 11 | import InfoViewer from '../../../components/InfoViewer/InfoViewer'; |
14 | 12 | import { |
15 | 13 | CDCStreamOverview, |
16 | 14 | PersQueueGroupOverview, |
17 | 15 | } from '../../../components/InfoViewer/schemaOverview'; |
18 | | -import {Icon} from '../../../components/Icon'; |
19 | 16 | import {Loader} from '../../../components/Loader'; |
20 | | - |
| 17 | +import SplitPane from '../../../components/SplitPane'; |
| 18 | +import routes, {createHref} from '../../../routes'; |
| 19 | +import {setShowPreview} from '../../../store/reducers/schema/schema'; |
| 20 | +import { |
| 21 | + TENANT_PAGES_IDS, |
| 22 | + TENANT_QUERY_TABS_ID, |
| 23 | + TENANT_SUMMARY_TABS_IDS, |
| 24 | +} from '../../../store/reducers/tenant/constants'; |
| 25 | +import {setQueryTab, setSummaryTab, setTenantPage} from '../../../store/reducers/tenant/tenant'; |
21 | 26 | import { |
22 | 27 | EPathSubType, |
23 | 28 | EPathType, |
24 | 29 | TColumnDescription, |
25 | 30 | TColumnTableDescription, |
26 | 31 | } from '../../../types/api/schema'; |
27 | | -import routes, {createHref} from '../../../routes'; |
28 | | -import {formatDateTime} from '../../../utils/dataFormatters/dataFormatters'; |
29 | | -import {useTypedSelector} from '../../../utils/hooks'; |
30 | 32 | import { |
31 | 33 | DEFAULT_IS_TENANT_COMMON_INFO_COLLAPSED, |
32 | 34 | DEFAULT_SIZE_TENANT_SUMMARY_KEY, |
33 | 35 | } from '../../../utils/constants'; |
34 | | -import {setShowPreview} from '../../../store/reducers/schema/schema'; |
35 | | -import {setQueryTab, setSummaryTab, setTenantPage} from '../../../store/reducers/tenant/tenant'; |
36 | | -import { |
37 | | - TENANT_PAGES_IDS, |
38 | | - TENANT_QUERY_TABS_ID, |
39 | | - TENANT_SUMMARY_TABS_IDS, |
40 | | -} from '../../../store/reducers/tenant/constants'; |
41 | | - |
42 | | -import {SchemaTree} from '../Schema/SchemaTree/SchemaTree'; |
43 | | -import {SchemaViewer} from '../Schema/SchemaViewer/SchemaViewer'; |
| 36 | +import {formatDateTime} from '../../../utils/dataFormatters/dataFormatters'; |
| 37 | +import {useTypedSelector} from '../../../utils/hooks'; |
44 | 38 | import {Acl} from '../Acl/Acl'; |
45 | | -import {ExternalTableSummary} from '../Info/ExternalTable/ExternalTable'; |
| 39 | +import i18n from '../i18n'; |
46 | 40 | import {ExternalDataSourceSummary} from '../Info/ExternalDataSource/ExternalDataSource'; |
47 | | - |
| 41 | +import {ExternalTableSummary} from '../Info/ExternalTable/ExternalTable'; |
| 42 | +import {SchemaTree} from '../Schema/SchemaTree/SchemaTree'; |
| 43 | +import {SchemaViewer} from '../Schema/SchemaViewer/SchemaViewer'; |
48 | 44 | import {TenantTabsGroups, TENANT_INFO_TABS, TENANT_SCHEMA_TAB} from '../TenantPages'; |
49 | 45 | import { |
50 | 46 | PaneVisibilityActionTypes, |
51 | | - paneVisibilityToggleReducerCreator, |
52 | 47 | PaneVisibilityToggleButtons, |
| 48 | + paneVisibilityToggleReducerCreator, |
53 | 49 | } from '../utils/paneVisibilityToggleHelpers'; |
54 | 50 | import {isColumnEntityType, isExternalTable, isIndexTable, isTableType} from '../utils/schema'; |
55 | | - |
56 | | -import i18n from '../i18n'; |
57 | | - |
58 | 51 | import './ObjectSummary.scss'; |
59 | 52 |
|
60 | 53 | const b = cn('object-summary'); |
@@ -306,8 +299,9 @@ export function ObjectSummary({ |
306 | 299 | </Button> |
307 | 300 | )} |
308 | 301 | {currentSchemaPath && ( |
309 | | - <CopyToClipboard |
| 302 | + <ClipboardButton |
310 | 303 | text={currentSchemaPath} |
| 304 | + view="flat-secondary" |
311 | 305 | title={i18n('summary.copySchemaPath')} |
312 | 306 | /> |
313 | 307 | )} |
|
0 commit comments