fixed last of const-insigts components deprecations'
Signed-off-by: Simon <simme.jakobsson@gmail.com>
This commit is contained in:
@@ -30,7 +30,8 @@ import {
|
||||
MapLoadingToProps,
|
||||
} from '../../hooks';
|
||||
import { DefaultLoadingAction } from '../../utils/loading';
|
||||
import { Alert, AlertOptions, AlertStatus, Maybe } from '../../types';
|
||||
import { Alert, AlertOptions, AlertStatus } from '../../types';
|
||||
import { Maybe } from '@backstage/plugin-cost-insights-common';
|
||||
import {
|
||||
isStatusSnoozed,
|
||||
isStatusAccepted,
|
||||
|
||||
@@ -17,12 +17,12 @@
|
||||
import React from 'react';
|
||||
import classnames from 'classnames';
|
||||
import {
|
||||
ChangeStatistic,
|
||||
CurrencyType,
|
||||
Duration,
|
||||
EngineerThreshold,
|
||||
GrowthType,
|
||||
} from '../../types';
|
||||
import { ChangeStatistic } from '@backstage/plugin-cost-insights-common';
|
||||
import { rateOf } from '../../utils/currency';
|
||||
import { growthOf } from '../../utils/change';
|
||||
import { useCostGrowthStyles as useStyles } from '../../utils/styles';
|
||||
|
||||
@@ -15,7 +15,7 @@
|
||||
*/
|
||||
import React, { PropsWithChildren } from 'react';
|
||||
import { makeStyles } from '@material-ui/core';
|
||||
import { Group } from '../../types';
|
||||
import { Group } from '@backstage/plugin-cost-insights-common';
|
||||
import { CostInsightsTabs } from '../CostInsightsTabs';
|
||||
import { Header, Page } from '@backstage/core-components';
|
||||
|
||||
|
||||
+2
-1
@@ -18,7 +18,8 @@ import React from 'react';
|
||||
import { default as HappyFace } from '@material-ui/icons/SentimentSatisfiedAlt';
|
||||
import { renderInTestApp } from '@backstage/test-utils';
|
||||
import { CostInsightsNavigation } from './CostInsightsNavigation';
|
||||
import { Product, Icon } from '../../types';
|
||||
import { Icon } from '../../types';
|
||||
import { Product } from '@backstage/plugin-cost-insights-common';
|
||||
import { MockConfigProvider, MockScrollProvider } from '../../testUtils';
|
||||
import { getDefaultNavigationItems } from '../../utils/navigation';
|
||||
|
||||
|
||||
@@ -21,7 +21,8 @@ import userEvent from '@testing-library/user-event';
|
||||
import { PeriodSelect, getDefaultOptions } from './PeriodSelect';
|
||||
import { getDefaultPageFilters } from '../../utils/filters';
|
||||
import { MockBillingDateProvider } from '../../testUtils';
|
||||
import { Group, Duration } from '../../types';
|
||||
import { Duration } from '../../types';
|
||||
import { Group } from '@backstage/plugin-cost-insights-common';
|
||||
|
||||
const DefaultPageFilters = getDefaultPageFilters([{ id: 'tools' }] as Group[]);
|
||||
const lastCompleteBillingDate = '2020-05-01';
|
||||
|
||||
@@ -27,7 +27,7 @@ import {
|
||||
MockScrollProvider,
|
||||
MockLoadingProvider,
|
||||
} from '../../testUtils';
|
||||
import { Entity, Product } from '../../types';
|
||||
import { Entity, Product } from '@backstage/plugin-cost-insights-common';
|
||||
|
||||
// suppress recharts componentDidUpdate warnings
|
||||
jest.spyOn(console, 'warn').mockImplementation(() => {});
|
||||
|
||||
@@ -19,7 +19,8 @@ import { Box, Typography } from '@material-ui/core';
|
||||
import { default as Alert } from '@material-ui/lab/Alert';
|
||||
import { costInsightsApiRef } from '../../api';
|
||||
import { ProductInsightsCardList } from '../ProductInsightsCard/ProductInsightsCardList';
|
||||
import { Duration, Entity, Maybe, Product } from '../../types';
|
||||
import { Duration } from '../../types';
|
||||
import { Entity, Maybe, Product } from '@backstage/plugin-cost-insights-common';
|
||||
import { intervalsOf, DEFAULT_DURATION } from '../../utils/duration';
|
||||
import {
|
||||
DefaultLoadingAction,
|
||||
|
||||
+1
-1
@@ -18,7 +18,7 @@ import React from 'react';
|
||||
import { wrapInTestApp } from '@backstage/test-utils';
|
||||
import { ProductEntityDialog } from './ProductEntityDialog';
|
||||
import { render } from '@testing-library/react';
|
||||
import { Entity } from '../../types';
|
||||
import { Entity } from '@backstage/plugin-cost-insights-common';
|
||||
|
||||
const atomicEntity: Entity = {
|
||||
id: null,
|
||||
|
||||
@@ -18,7 +18,7 @@ import React, { useState } from 'react';
|
||||
import { Dialog, IconButton } from '@material-ui/core';
|
||||
import { default as CloseButton } from '@material-ui/icons/Close';
|
||||
import { useEntityDialogStyles as useStyles } from '../../utils/styles';
|
||||
import { Entity } from '../../types';
|
||||
import { Entity } from '@backstage/plugin-cost-insights-common';
|
||||
import {
|
||||
ProductEntityTable,
|
||||
ProductEntityTableOptions,
|
||||
|
||||
@@ -20,7 +20,11 @@ import { Typography } from '@material-ui/core';
|
||||
import { costFormatter, formatChange } from '../../utils/formatters';
|
||||
import { useEntityDialogStyles as useStyles } from '../../utils/styles';
|
||||
import { CostGrowthIndicator } from '../CostGrowth';
|
||||
import { BarChartOptions, ChangeStatistic, Entity } from '../../types';
|
||||
import { BarChartOptions } from '../../types';
|
||||
import {
|
||||
ChangeStatistic,
|
||||
Entity,
|
||||
} from '@backstage/plugin-cost-insights-common';
|
||||
import { Table, TableColumn } from '@backstage/core-components';
|
||||
|
||||
export type ProductEntityTableOptions = Partial<
|
||||
|
||||
+2
-1
@@ -28,7 +28,8 @@ import {
|
||||
MockScrollProvider,
|
||||
MockLoadingProvider,
|
||||
} from '../../testUtils';
|
||||
import { Duration, Entity, Product } from '../../types';
|
||||
import { Duration } from '../../types';
|
||||
import { Entity, Product } from '@backstage/plugin-cost-insights-common';
|
||||
|
||||
// suppress recharts componentDidUpdate warnings
|
||||
jest.spyOn(console, 'warn').mockImplementation(() => {});
|
||||
|
||||
@@ -28,7 +28,8 @@ import { PeriodSelect } from '../PeriodSelect';
|
||||
import { ProductInsightsChart } from './ProductInsightsChart';
|
||||
import { useProductInsightsCardStyles as useStyles } from '../../utils/styles';
|
||||
import { DefaultLoadingAction } from '../../utils/loading';
|
||||
import { Duration, Entity, Maybe, Product } from '../../types';
|
||||
import { Duration } from '../../types';
|
||||
import { Entity, Maybe, Product } from '@backstage/plugin-cost-insights-common';
|
||||
import {
|
||||
MapLoadingToProps,
|
||||
useLastCompleteBillingDate,
|
||||
|
||||
+2
-1
@@ -17,7 +17,8 @@
|
||||
import React from 'react';
|
||||
import { Box, CircularProgress, Collapse } from '@material-ui/core';
|
||||
import { ProductInsightsCard } from './ProductInsightsCard';
|
||||
import { Duration, Entity, Product } from '../../types';
|
||||
import { Duration } from '../../types';
|
||||
import { Entity, Product } from '@backstage/plugin-cost-insights-common';
|
||||
import { ProductState } from '../../utils/loading';
|
||||
|
||||
type ProductInsightsCardListProps = {
|
||||
|
||||
@@ -48,7 +48,8 @@ import {
|
||||
useProductInsightsChartStyles as useStyles,
|
||||
useBarChartLayoutStyles as useLayoutStyles,
|
||||
} from '../../utils/styles';
|
||||
import { Duration, Entity, Maybe } from '../../types';
|
||||
import { Duration } from '../../types';
|
||||
import { Entity, Maybe } from '@backstage/plugin-cost-insights-common';
|
||||
import { choose } from '../../utils/change';
|
||||
import { TooltipRenderer } from '../../types/Tooltip';
|
||||
|
||||
|
||||
+1
-2
@@ -23,10 +23,9 @@ import {
|
||||
Alert,
|
||||
DEFAULT_DATE_FORMAT,
|
||||
Duration,
|
||||
Entity,
|
||||
Product,
|
||||
ProjectGrowthData,
|
||||
} from '../../types';
|
||||
import { Entity, Product } from '@backstage/plugin-cost-insights-common';
|
||||
import { ProjectGrowthAlert } from '../../alerts';
|
||||
import { InfoCard } from '@backstage/core-components';
|
||||
|
||||
|
||||
@@ -15,7 +15,7 @@
|
||||
*/
|
||||
import React from 'react';
|
||||
import { MenuItem, Select } from '@material-ui/core';
|
||||
import { Maybe, Project } from '../../types';
|
||||
import { Maybe, Project } from '@backstage/plugin-cost-insights-common';
|
||||
import { useSelectStyles as useStyles } from '../../utils/styles';
|
||||
|
||||
type ProjectSelectProps = {
|
||||
|
||||
Reference in New Issue
Block a user