11import { Flex } from '@gravity-ui/uikit' ;
22
3- import { getPDiskPagePath } from '../../routes' ;
43import { valueIsDefined } from '../../utils' ;
54import { formatBytes } from '../../utils/bytesParsers' ;
65import { formatStorageValuesToGb } from '../../utils/dataFormatters/dataFormatters' ;
@@ -10,6 +9,7 @@ import {useIsUserAllowedToMakeChanges} from '../../utils/hooks/useIsUserAllowedT
109import type { InfoViewerItem } from '../InfoViewer' ;
1110import { InfoViewer } from '../InfoViewer/InfoViewer' ;
1211import { LinkWithIcon } from '../LinkWithIcon/LinkWithIcon' ;
12+ import { PDiskPageLink } from '../PDiskPageLink/PDiskPageLink' ;
1313import { ProgressViewer } from '../ProgressViewer/ProgressViewer' ;
1414import { StatusIcon } from '../StatusIcon/StatusIcon' ;
1515
@@ -149,7 +149,6 @@ function getPDiskInfo<T extends PreparedPDisk>({
149149 valueIsDefined ( nodeId ) ;
150150
151151 if ( shouldDisplayLinks ) {
152- const pDiskPagePath = getPDiskPagePath ( PDiskId , nodeId ) ;
153152 const pDiskInternalViewerPath = createPDiskDeveloperUILink ( {
154153 nodeId,
155154 pDiskId : PDiskId ,
@@ -159,13 +158,7 @@ function getPDiskInfo<T extends PreparedPDisk>({
159158 label : pDiskInfoKeyset ( 'links' ) ,
160159 value : (
161160 < Flex wrap = "wrap" gap = { 2 } >
162- { withPDiskPageLink && (
163- < LinkWithIcon
164- title = { pDiskInfoKeyset ( 'pdisk-page' ) }
165- url = { pDiskPagePath }
166- external = { false }
167- />
168- ) }
161+ { withPDiskPageLink && < PDiskPageLink pDiskId = { PDiskId } nodeId = { nodeId } /> }
169162 { isUserAllowedToMakeChanges && (
170163 < LinkWithIcon
171164 title = { pDiskInfoKeyset ( 'developer-ui' ) }
0 commit comments