@@ -3,12 +3,7 @@ import React from 'react';
33import type { Store } from '@reduxjs/toolkit' ;
44import type { History } from 'history' ;
55
6- import type { GetLogsLink } from '../../utils/logs' ;
7- import type { GetMonitoringClusterLink , GetMonitoringLink } from '../../utils/monitoring' ;
8- import {
9- getMonitoringClusterLink as getMonitoringClusterLinkDefault ,
10- getMonitoringLink as getMonitoringLinkDefault ,
11- } from '../../utils/monitoring' ;
6+ import { uiFactory } from '../../uiFactory/uiFactory' ;
127import { App , AppSlots } from '../App' ;
138import type { YDBEmbeddedUISettings } from '../UserSettings/settings' ;
149
@@ -18,32 +13,21 @@ import {ExtendedTenant} from './ExtendedTenant/ExtendedTenant';
1813export interface AppWithClustersProps {
1914 store : Store ;
2015 history : History ;
21- getLogsLink ?: GetLogsLink ;
22- getMonitoringLink ?: GetMonitoringLink ;
23- getMonitoringClusterLink ?: GetMonitoringClusterLink ;
2416 userSettings ?: YDBEmbeddedUISettings ;
2517 children ?: React . ReactNode ;
2618}
2719
28- export function AppWithClusters ( {
29- store,
30- history,
31- getLogsLink,
32- getMonitoringLink = getMonitoringLinkDefault ,
33- getMonitoringClusterLink = getMonitoringClusterLinkDefault ,
34- userSettings,
35- children,
36- } : AppWithClustersProps ) {
20+ export function AppWithClusters ( { store, history, userSettings, children} : AppWithClustersProps ) {
3721 return (
3822 < App store = { store } history = { history } userSettings = { userSettings } >
3923 < AppSlots . ClusterSlot >
4024 { ( { component} ) => {
4125 return (
4226 < ExtendedCluster
4327 component = { component }
44- getLogsLink = { getLogsLink }
45- getMonitoringLink = { getMonitoringLink }
46- getMonitoringClusterLink = { getMonitoringClusterLink }
28+ getLogsLink = { uiFactory . getLogsLink }
29+ getMonitoringLink = { uiFactory . getMonitoringLink }
30+ getMonitoringClusterLink = { uiFactory . getMonitoringClusterLink }
4731 />
4832 ) ;
4933 } }
@@ -53,8 +37,8 @@ export function AppWithClusters({
5337 return (
5438 < ExtendedTenant
5539 component = { component }
56- getLogsLink = { getLogsLink }
57- getMonitoringLink = { getMonitoringLink }
40+ getLogsLink = { uiFactory . getLogsLink }
41+ getMonitoringLink = { uiFactory . getMonitoringLink }
5842 />
5943 ) ;
6044 } }
0 commit comments