From 249a3b47dffc2541d23dcdcb9a42c3b95d0181bf Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Fredrik=20Adel=C3=B6w?= Date: Fri, 19 Aug 2022 15:37:12 +0200 Subject: [PATCH] cost-insights MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Signed-off-by: Fredrik Adelöw --- plugins/cost-insights/api-report.md | 261 +++++------------- .../src/alerts/ProjectGrowthAlert.tsx | 3 +- .../src/alerts/UnlabeledDataflowAlert.tsx | 3 +- .../cost-insights/src/api/CostInsightsApi.ts | 3 + .../src/components/BarChart/BarChart.tsx | 22 +- .../components/BarChart/BarChartLegend.tsx | 14 +- .../components/BarChart/BarChartTooltip.tsx | 15 +- .../BarChart/BarChartTooltipItem.tsx | 8 +- .../src/components/CostGrowth/CostGrowth.tsx | 6 +- .../CostGrowth/CostGrowthIndicator.tsx | 13 +- .../src/components/LegendItem/LegendItem.tsx | 12 +- plugins/cost-insights/src/example/client.ts | 1 + plugins/cost-insights/src/hooks/useConfig.tsx | 1 + .../cost-insights/src/hooks/useCurrency.tsx | 1 + plugins/cost-insights/src/index.ts | 5 + plugins/cost-insights/src/plugin.ts | 4 + .../cost-insights/src/testUtils/providers.tsx | 52 ++-- plugins/cost-insights/src/types/Alert.ts | 27 +- .../src/types/ChangeStatistic.ts | 3 + .../cost-insights/src/types/CurrencyType.ts | 1 + plugins/cost-insights/src/types/DateFormat.ts | 1 + plugins/cost-insights/src/types/Icon.ts | 2 + plugins/cost-insights/src/types/Loading.ts | 1 + plugins/cost-insights/src/types/Theme.ts | 11 +- plugins/cost-insights/src/types/index.ts | 11 + scripts/api-extractor.ts | 1 - 26 files changed, 222 insertions(+), 260 deletions(-) diff --git a/plugins/cost-insights/api-report.md b/plugins/cost-insights/api-report.md index 2a4cecc4eb..f4c8c9bd6f 100644 --- a/plugins/cost-insights/api-report.md +++ b/plugins/cost-insights/api-report.md @@ -25,8 +25,6 @@ import { SetStateAction } from 'react'; import { TooltipProps } from 'recharts'; import { TypographyProps } from '@material-ui/core'; -// Warning: (ae-missing-release-tag) "Alert" is exported by the package, but it is missing a release tag (@alpha, @beta, @public, or @internal) -// // @public export type Alert = { title: string | JSX.Element; @@ -43,8 +41,6 @@ export type Alert = { onDismissed?(options: AlertOptions): Promise; }; -// Warning: (ae-missing-release-tag) "AlertCost" is exported by the package, but it is missing a release tag (@alpha, @beta, @public, or @internal) -// // @public (undocumented) export interface AlertCost { // (undocumented) @@ -53,8 +49,6 @@ export interface AlertCost { id: string; } -// Warning: (ae-missing-release-tag) "AlertDismissFormData" is exported by the package, but it is missing a release tag (@alpha, @beta, @public, or @internal) -// // @public (undocumented) export interface AlertDismissFormData { // (undocumented) @@ -65,8 +59,6 @@ export interface AlertDismissFormData { reason: AlertDismissReason; } -// Warning: (ae-missing-release-tag) "AlertDismissOption" is exported by the package, but it is missing a release tag (@alpha, @beta, @public, or @internal) -// // @public (undocumented) export interface AlertDismissOption { // (undocumented) @@ -75,13 +67,9 @@ export interface AlertDismissOption { reason: string; } -// Warning: (ae-missing-release-tag) "AlertDismissOptions" is exported by the package, but it is missing a release tag (@alpha, @beta, @public, or @internal) -// // @public (undocumented) export const AlertDismissOptions: AlertDismissOption[]; -// Warning: (ae-missing-release-tag) "AlertDismissReason" is exported by the package, but it is missing a release tag (@alpha, @beta, @public, or @internal) -// // @public (undocumented) export enum AlertDismissReason { // (undocumented) @@ -98,8 +86,6 @@ export enum AlertDismissReason { Seasonal = 'seasonal', } -// Warning: (ae-missing-release-tag) "AlertForm" is exported by the package, but it is missing a release tag (@alpha, @beta, @public, or @internal) -// // @public (undocumented) export type AlertForm< A extends Alert = any, @@ -108,8 +94,6 @@ export type AlertForm< AlertFormProps & RefAttributes >; -// Warning: (ae-missing-release-tag) "AlertFormProps" is exported by the package, but it is missing a release tag (@alpha, @beta, @public, or @internal) -// // @public (undocumented) export type AlertFormProps = { alert: A; @@ -117,8 +101,6 @@ export type AlertFormProps = { disableSubmit: (isDisabled: boolean) => void; }; -// Warning: (ae-missing-release-tag) "AlertOptions" is exported by the package, but it is missing a release tag (@alpha, @beta, @public, or @internal) -// // @public (undocumented) export interface AlertOptions { // (undocumented) @@ -127,29 +109,21 @@ export interface AlertOptions { group: string; } -// Warning: (ae-missing-release-tag) "AlertSnoozeFormData" is exported by the package, but it is missing a release tag (@alpha, @beta, @public, or @internal) -// // @public export interface AlertSnoozeFormData { // (undocumented) intervals: string; } -// Warning: (ae-missing-release-tag) "AlertSnoozeOption" is exported by the package, but it is missing a release tag (@alpha, @beta, @public, or @internal) -// // @public (undocumented) export type AlertSnoozeOption = { label: string; duration: Duration; }; -// Warning: (ae-missing-release-tag) "AlertSnoozeOptions" is exported by the package, but it is missing a release tag (@alpha, @beta, @public, or @internal) -// // @public (undocumented) export const AlertSnoozeOptions: AlertSnoozeOption[]; -// Warning: (ae-missing-release-tag) "AlertStatus" is exported by the package, but it is missing a release tag (@alpha, @beta, @public, or @internal) -// // @public (undocumented) export enum AlertStatus { // (undocumented) @@ -160,36 +134,17 @@ export enum AlertStatus { Snoozed = 'snoozed', } -// Warning: (ae-missing-release-tag) "BarChart" is exported by the package, but it is missing a release tag (@alpha, @beta, @public, or @internal) -// // @public (undocumented) -export const BarChart: ({ - resources, - responsive, - displayAmount, - options, - tooltip, - onClick, - onMouseMove, -}: BarChartProps) => JSX.Element; +export const BarChart: (props: BarChartProps) => JSX.Element; -// Warning: (ae-missing-release-tag) "BarChartData" is exported by the package, but it is missing a release tag (@alpha, @beta, @public, or @internal) -// -// @public +// @public @deprecated (undocumented) export interface BarChartData extends BarChartOptions {} -// Warning: (ae-missing-release-tag) "BarChartLegend" is exported by the package, but it is missing a release tag (@alpha, @beta, @public, or @internal) -// // @public (undocumented) -export const BarChartLegend: ({ - costStart, - costEnd, - options, - children, -}: PropsWithChildren) => JSX.Element; +export const BarChartLegend: ( + props: PropsWithChildren, +) => JSX.Element; -// Warning: (ae-missing-release-tag) "BarChartLegendOptions" is exported by the package, but it is missing a release tag (@alpha, @beta, @public, or @internal) -// // @public (undocumented) export type BarChartLegendOptions = { previousName: string; @@ -199,8 +154,6 @@ export type BarChartLegendOptions = { hideMarker?: boolean; }; -// Warning: (ae-missing-release-tag) "BarChartLegendProps" is exported by the package, but it is missing a release tag (@alpha, @beta, @public, or @internal) -// // @public (undocumented) export type BarChartLegendProps = { costStart: number; @@ -208,8 +161,6 @@ export type BarChartLegendProps = { options?: Partial; }; -// Warning: (ae-missing-release-tag) "BarChartOptions" is exported by the package, but it is missing a release tag (@alpha, @beta, @public, or @internal) -// // @public (undocumented) export interface BarChartOptions { // (undocumented) @@ -222,8 +173,6 @@ export interface BarChartOptions { previousName: string; } -// Warning: (ae-missing-release-tag) "BarChartProps" is exported by the package, but it is missing a release tag (@alpha, @beta, @public, or @internal) -// // @public (undocumented) export type BarChartProps = { resources: ResourceData[]; @@ -235,34 +184,21 @@ export type BarChartProps = { onMouseMove?: RechartsFunction; }; -// Warning: (ae-missing-release-tag) "BarChartTooltip" is exported by the package, but it is missing a release tag (@alpha, @beta, @public, or @internal) -// // @public (undocumented) -export const BarChartTooltip: ({ - title, - content, - subtitle, - topRight, - actions, - children, -}: PropsWithChildren) => JSX.Element; +export const BarChartTooltip: ( + props: PropsWithChildren, +) => JSX.Element; -// Warning: (ae-missing-release-tag) "BarChartTooltipItem" is exported by the package, but it is missing a release tag (@alpha, @beta, @public, or @internal) -// // @public (undocumented) -export const BarChartTooltipItem: ({ - item, -}: BarChartTooltipItemProps) => JSX.Element; +export const BarChartTooltipItem: ( + props: BarChartTooltipItemProps, +) => JSX.Element; -// Warning: (ae-missing-release-tag) "BarChartTooltipItemProps" is exported by the package, but it is missing a release tag (@alpha, @beta, @public, or @internal) -// // @public (undocumented) export type BarChartTooltipItemProps = { item: TooltipItem; }; -// Warning: (ae-missing-release-tag) "BarChartTooltipProps" is exported by the package, but it is missing a release tag (@alpha, @beta, @public, or @internal) -// // @public (undocumented) export type BarChartTooltipProps = { title: string; @@ -272,13 +208,9 @@ export type BarChartTooltipProps = { actions?: ReactNode; }; -// Warning: (ae-missing-release-tag) "ChangeStatistic" is exported by the package, but it is missing a release tag (@alpha, @beta, @public, or @internal) -// // @public @deprecated (undocumented) export type ChangeStatistic = common.ChangeStatistic; -// Warning: (ae-missing-release-tag) "ChangeThreshold" is exported by the package, but it is missing a release tag (@alpha, @beta, @public, or @internal) -// // @public (undocumented) export enum ChangeThreshold { // (undocumented) @@ -295,28 +227,26 @@ export type ChartData = { [key: string]: number; }; -// Warning: (ae-missing-release-tag) "Cost" is exported by the package, but it is missing a release tag (@alpha, @beta, @public, or @internal) -// +// @public (undocumented) +export type ConfigContextProps = { + metrics: Metric[]; + products: Product[]; + icons: Icon[]; + engineerCost: number; + currencies: Currency[]; +}; + // @public @deprecated (undocumented) export type Cost = common.Cost; -// Warning: (ae-missing-release-tag) "CostGrowth" is exported by the package, but it is missing a release tag (@alpha, @beta, @public, or @internal) -// // @public (undocumented) -export const CostGrowth: ({ change, duration }: CostGrowthProps) => JSX.Element; +export const CostGrowth: (props: CostGrowthProps) => JSX.Element; -// Warning: (ae-missing-release-tag) "CostGrowthIndicator" is exported by the package, but it is missing a release tag (@alpha, @beta, @public, or @internal) -// // @public (undocumented) -export const CostGrowthIndicator: ({ - change, - formatter, - className, - ...props -}: CostGrowthIndicatorProps) => JSX.Element; +export const CostGrowthIndicator: ( + props: CostGrowthIndicatorProps, +) => JSX.Element; -// Warning: (ae-missing-release-tag) "CostGrowthIndicatorProps" is exported by the package, but it is missing a release tag (@alpha, @beta, @public, or @internal) -// // @public (undocumented) export type CostGrowthIndicatorProps = TypographyProps & { change: ChangeStatistic; @@ -328,16 +258,12 @@ export type CostGrowthIndicatorProps = TypographyProps & { ) => Maybe; }; -// Warning: (ae-missing-release-tag) "CostGrowthProps" is exported by the package, but it is missing a release tag (@alpha, @beta, @public, or @internal) -// // @public (undocumented) export type CostGrowthProps = { change: ChangeStatistic; duration: Duration; }; -// Warning: (ae-missing-release-tag) "CostInsightsApi" is exported by the package, but it is missing a release tag (@alpha, @beta, @public, or @internal) -// // @public (undocumented) export type CostInsightsApi = { getLastCompleteBillingDate(): Promise; @@ -350,36 +276,36 @@ export type CostInsightsApi = { getAlerts(group: string): Promise; }; -// Warning: (ae-missing-release-tag) "costInsightsApiRef" is exported by the package, but it is missing a release tag (@alpha, @beta, @public, or @internal) -// // @public (undocumented) export const costInsightsApiRef: ApiRef; -// Warning: (ae-missing-release-tag) "CostInsightsLabelDataflowInstructionsPage" is exported by the package, but it is missing a release tag (@alpha, @beta, @public, or @internal) -// // @public (undocumented) export const CostInsightsLabelDataflowInstructionsPage: () => JSX.Element; -// Warning: (ae-missing-release-tag) "CostInsightsPage" is exported by the package, but it is missing a release tag (@alpha, @beta, @public, or @internal) -// // @public (undocumented) export const CostInsightsPage: () => JSX.Element; -// Warning: (ae-forgotten-export) The symbol "CostInsightsPaletteAdditions" needs to be exported by the entry point index.d.ts -// Warning: (ae-missing-release-tag) "CostInsightsPalette" is exported by the package, but it is missing a release tag (@alpha, @beta, @public, or @internal) -// // @public (undocumented) export type CostInsightsPalette = BackstagePalette & CostInsightsPaletteAdditions; -// Warning: (ae-missing-release-tag) "CostInsightsPaletteOptions" is exported by the package, but it is missing a release tag (@alpha, @beta, @public, or @internal) -// +// @public (undocumented) +export type CostInsightsPaletteAdditions = { + blue: string; + lightBlue: string; + darkBlue: string; + magenta: string; + yellow: string; + tooltip: CostInsightsTooltipOptions; + navigationText: string; + alertBackground: string; + dataViz: string[]; +}; + // @public (undocumented) export type CostInsightsPaletteOptions = PaletteOptions & CostInsightsPaletteAdditions; -// Warning: (ae-missing-release-tag) "costInsightsPlugin" is exported by the package, but it is missing a release tag (@alpha, @beta, @public, or @internal) -// // @public (undocumented) const costInsightsPlugin: BackstagePlugin< { @@ -393,27 +319,27 @@ const costInsightsPlugin: BackstagePlugin< export { costInsightsPlugin }; export { costInsightsPlugin as plugin }; -// Warning: (ae-missing-release-tag) "CostInsightsProjectGrowthInstructionsPage" is exported by the package, but it is missing a release tag (@alpha, @beta, @public, or @internal) -// // @public (undocumented) export const CostInsightsProjectGrowthInstructionsPage: () => JSX.Element; -// Warning: (ae-missing-release-tag) "CostInsightsTheme" is exported by the package, but it is missing a release tag (@alpha, @beta, @public, or @internal) -// // @public (undocumented) export interface CostInsightsTheme extends BackstageTheme { // (undocumented) palette: CostInsightsPalette; } -// Warning: (ae-missing-release-tag) "CostInsightsThemeOptions" is exported by the package, but it is missing a release tag (@alpha, @beta, @public, or @internal) -// // @public (undocumented) export interface CostInsightsThemeOptions extends PaletteOptions { // (undocumented) palette: CostInsightsPaletteOptions; } +// @public (undocumented) +export type CostInsightsTooltipOptions = { + background: string; + color: string; +}; + // @public (undocumented) export interface Currency { // (undocumented) @@ -428,8 +354,12 @@ export interface Currency { unit: string; } -// Warning: (ae-missing-release-tag) "CurrencyType" is exported by the package, but it is missing a release tag (@alpha, @beta, @public, or @internal) -// +// @public (undocumented) +export type CurrencyContextProps = { + currency: Currency; + setCurrency: Dispatch>; +}; + // @public (undocumented) export enum CurrencyType { // (undocumented) @@ -442,8 +372,6 @@ export enum CurrencyType { USD = 'USD', } -// Warning: (ae-missing-release-tag) "DataKey" is exported by the package, but it is missing a release tag (@alpha, @beta, @public, or @internal) -// // @public (undocumented) export enum DataKey { // (undocumented) @@ -454,13 +382,9 @@ export enum DataKey { Previous = 'previous', } -// Warning: (ae-missing-release-tag) "DateAggregation" is exported by the package, but it is missing a release tag (@alpha, @beta, @public, or @internal) -// // @public @deprecated (undocumented) export type DateAggregation = common.DateAggregation; -// Warning: (ae-missing-release-tag) "DEFAULT_DATE_FORMAT" is exported by the package, but it is missing a release tag (@alpha, @beta, @public, or @internal) -// // @public (undocumented) export const DEFAULT_DATE_FORMAT = 'yyyy-LL-dd'; @@ -476,18 +400,12 @@ export enum Duration { P90D = 'P90D', } -// Warning: (ae-missing-release-tag) "EngineerThreshold" is exported by the package, but it is missing a release tag (@alpha, @beta, @public, or @internal) -// // @public (undocumented) export const EngineerThreshold = 0.5; -// Warning: (ae-missing-release-tag) "Entity" is exported by the package, but it is missing a release tag (@alpha, @beta, @public, or @internal) -// // @public @deprecated (undocumented) export type Entity = common.Entity; -// Warning: (ae-missing-release-tag) "ExampleCostInsightsClient" is exported by the package, but it is missing a release tag (@alpha, @beta, @public, or @internal) -// // @public (undocumented) export class ExampleCostInsightsClient implements CostInsightsApi { // (undocumented) @@ -508,13 +426,9 @@ export class ExampleCostInsightsClient implements CostInsightsApi { getUserGroups(userId: string): Promise; } -// Warning: (ae-missing-release-tag) "Group" is exported by the package, but it is missing a release tag (@alpha, @beta, @public, or @internal) -// // @public @deprecated (undocumented) export type Group = common.Group; -// Warning: (ae-missing-release-tag) "GrowthType" is exported by the package, but it is missing a release tag (@alpha, @beta, @public, or @internal) -// // @public (undocumented) export enum GrowthType { // (undocumented) @@ -525,16 +439,12 @@ export enum GrowthType { Savings = 1, } -// Warning: (ae-missing-release-tag) "Icon" is exported by the package, but it is missing a release tag (@alpha, @beta, @public, or @internal) -// // @public (undocumented) export type Icon = { kind: string; component: JSX.Element; }; -// Warning: (ae-missing-release-tag) "IconType" is exported by the package, but it is missing a release tag (@alpha, @beta, @public, or @internal) -// // @public (undocumented) export enum IconType { // (undocumented) @@ -551,18 +461,11 @@ export enum IconType { Storage = 'storage', } -// Warning: (ae-missing-release-tag) "LegendItem" is exported by the package, but it is missing a release tag (@alpha, @beta, @public, or @internal) -// // @public (undocumented) -export const LegendItem: ({ - title, - tooltipText, - markerColor, - children, -}: PropsWithChildren) => JSX.Element; +export const LegendItem: ( + props: PropsWithChildren, +) => JSX.Element; -// Warning: (ae-missing-release-tag) "LegendItemProps" is exported by the package, but it is missing a release tag (@alpha, @beta, @public, or @internal) -// // @public (undocumented) export type LegendItemProps = { title: string; @@ -570,43 +473,37 @@ export type LegendItemProps = { markerColor?: string; }; -// Warning: (ae-missing-release-tag) "Loading" is exported by the package, but it is missing a release tag (@alpha, @beta, @public, or @internal) -// // @public (undocumented) export type Loading = Record; -// Warning: (ae-missing-release-tag) "Maybe" is exported by the package, but it is missing a release tag (@alpha, @beta, @public, or @internal) -// // @public @deprecated (undocumented) export type Maybe = common.Maybe; -// Warning: (ae-missing-release-tag) "Metric" is exported by the package, but it is missing a release tag (@alpha, @beta, @public, or @internal) -// // @public @deprecated (undocumented) export type Metric = common.Metric; -// Warning: (ae-missing-release-tag) "MetricData" is exported by the package, but it is missing a release tag (@alpha, @beta, @public, or @internal) -// // @public @deprecated (undocumented) export type MetricData = common.MetricData; -// Warning: (ae-forgotten-export) The symbol "MockConfigProviderProps" needs to be exported by the entry point index.d.ts -// Warning: (ae-missing-release-tag) "MockConfigProvider" is exported by the package, but it is missing a release tag (@alpha, @beta, @public, or @internal) -// // @public (undocumented) -export const MockConfigProvider: ({ - children, - ...context -}: MockConfigProviderProps) => JSX.Element; +export const MockConfigProvider: ( + props: MockConfigProviderProps, +) => JSX.Element; -// Warning: (ae-forgotten-export) The symbol "MockCurrencyProviderProps" needs to be exported by the entry point index.d.ts -// Warning: (ae-missing-release-tag) "MockCurrencyProvider" is exported by the package, but it is missing a release tag (@alpha, @beta, @public, or @internal) -// // @public (undocumented) -export const MockCurrencyProvider: ({ - children, - ...context -}: MockCurrencyProviderProps) => JSX.Element; +export type MockConfigProviderProps = PropsWithChildren< + Partial +>; + +// @public (undocumented) +export const MockCurrencyProvider: ( + props: MockCurrencyProviderProps, +) => JSX.Element; + +// @public (undocumented) +export type MockCurrencyProviderProps = PropsWithChildren< + Partial +>; // @public (undocumented) export interface PageFilters { @@ -620,16 +517,12 @@ export interface PageFilters { project: Maybe_2; } -// Warning: (ae-missing-release-tag) "Product" is exported by the package, but it is missing a release tag (@alpha, @beta, @public, or @internal) -// // @public @deprecated (undocumented) export type Product = common.Product; // @public (undocumented) export type ProductFilters = Array; -// Warning: (ae-missing-release-tag) "ProductInsightsOptions" is exported by the package, but it is missing a release tag (@alpha, @beta, @public, or @internal) -// // @public (undocumented) export type ProductInsightsOptions = { product: string; @@ -646,13 +539,9 @@ export interface ProductPeriod { productType: string; } -// Warning: (ae-missing-release-tag) "Project" is exported by the package, but it is missing a release tag (@alpha, @beta, @public, or @internal) -// // @public @deprecated (undocumented) export type Project = common.Project; -// Warning: (ae-missing-release-tag) "ProjectGrowthAlert" is exported by the package, but it is missing a release tag (@alpha, @beta, @public, or @internal) -// // @public export class ProjectGrowthAlert implements Alert { constructor(data: ProjectGrowthData); @@ -668,8 +557,6 @@ export class ProjectGrowthAlert implements Alert { get url(): string; } -// Warning: (ae-missing-release-tag) "ProjectGrowthData" is exported by the package, but it is missing a release tag (@alpha, @beta, @public, or @internal) -// // @public (undocumented) export interface ProjectGrowthData { // (undocumented) @@ -686,8 +573,6 @@ export interface ProjectGrowthData { project: string; } -// Warning: (ae-missing-release-tag) "ResourceData" is exported by the package, but it is missing a release tag (@alpha, @beta, @public, or @internal) -// // @public (undocumented) export interface ResourceData { // (undocumented) @@ -698,8 +583,6 @@ export interface ResourceData { previous: number; } -// Warning: (ae-missing-release-tag) "TooltipItem" is exported by the package, but it is missing a release tag (@alpha, @beta, @public, or @internal) -// // @public (undocumented) export type TooltipItem = { fill: string; @@ -707,13 +590,9 @@ export type TooltipItem = { value: string; }; -// Warning: (ae-missing-release-tag) "Trendline" is exported by the package, but it is missing a release tag (@alpha, @beta, @public, or @internal) -// // @public @deprecated (undocumented) export type Trendline = common.Trendline; -// Warning: (ae-missing-release-tag) "UnlabeledDataflowAlert" is exported by the package, but it is missing a release tag (@alpha, @beta, @public, or @internal) -// // @public export class UnlabeledDataflowAlert implements Alert { constructor(data: UnlabeledDataflowData); @@ -731,8 +610,6 @@ export class UnlabeledDataflowAlert implements Alert { get url(): string; } -// Warning: (ae-missing-release-tag) "UnlabeledDataflowAlertProject" is exported by the package, but it is missing a release tag (@alpha, @beta, @public, or @internal) -// // @public (undocumented) export interface UnlabeledDataflowAlertProject { // (undocumented) @@ -743,8 +620,6 @@ export interface UnlabeledDataflowAlertProject { unlabeledCost: number; } -// Warning: (ae-missing-release-tag) "UnlabeledDataflowData" is exported by the package, but it is missing a release tag (@alpha, @beta, @public, or @internal) -// // @public (undocumented) export interface UnlabeledDataflowData { // (undocumented) diff --git a/plugins/cost-insights/src/alerts/ProjectGrowthAlert.tsx b/plugins/cost-insights/src/alerts/ProjectGrowthAlert.tsx index 6767477f67..f432a14ff8 100644 --- a/plugins/cost-insights/src/alerts/ProjectGrowthAlert.tsx +++ b/plugins/cost-insights/src/alerts/ProjectGrowthAlert.tsx @@ -22,8 +22,9 @@ import { Alert, ProjectGrowthData } from '../types'; * The alert below is an example of an Alert implementation; the CostInsightsApi permits returning * any implementation of the Alert type, so adopters can create their own. The CostInsightsApi * fetches alert data from the backend, then creates Alert classes with the data. + * + * @public */ - export class ProjectGrowthAlert implements Alert { data: ProjectGrowthData; diff --git a/plugins/cost-insights/src/alerts/UnlabeledDataflowAlert.tsx b/plugins/cost-insights/src/alerts/UnlabeledDataflowAlert.tsx index da96f7d1f8..b4ee3d559c 100644 --- a/plugins/cost-insights/src/alerts/UnlabeledDataflowAlert.tsx +++ b/plugins/cost-insights/src/alerts/UnlabeledDataflowAlert.tsx @@ -22,8 +22,9 @@ import { Alert, AlertStatus, UnlabeledDataflowData } from '../types'; * The alert below is an example of an Alert implementation; the CostInsightsApi permits returning * any implementation of the Alert type, so adopters can create their own. The CostInsightsApi * fetches alert data from the backend, then creates Alert classes with the data. + * + * @public */ - export class UnlabeledDataflowAlert implements Alert { data: UnlabeledDataflowData; status?: AlertStatus; diff --git a/plugins/cost-insights/src/api/CostInsightsApi.ts b/plugins/cost-insights/src/api/CostInsightsApi.ts index 558cb57c0e..3c97407f08 100644 --- a/plugins/cost-insights/src/api/CostInsightsApi.ts +++ b/plugins/cost-insights/src/api/CostInsightsApi.ts @@ -25,6 +25,7 @@ import { } from '../types'; import { createApiRef } from '@backstage/core-plugin-api'; +/** @public */ export type ProductInsightsOptions = { /** * The product from the cost-insights configuration in app-config.yaml @@ -47,6 +48,7 @@ export type ProductInsightsOptions = { project: Maybe; }; +/** @public */ export type CostInsightsApi = { /** * Get the most current date for which billing data is complete, in YYYY-MM-DD format. This helps @@ -146,6 +148,7 @@ export type CostInsightsApi = { getAlerts(group: string): Promise; }; +/** @public */ export const costInsightsApiRef = createApiRef({ id: 'plugin.costinsights.service', }); diff --git a/plugins/cost-insights/src/components/BarChart/BarChart.tsx b/plugins/cost-insights/src/components/BarChart/BarChart.tsx index 27ef69db7a..145819db08 100644 --- a/plugins/cost-insights/src/components/BarChart/BarChart.tsx +++ b/plugins/cost-insights/src/components/BarChart/BarChart.tsx @@ -61,6 +61,7 @@ export const defaultTooltip: ContentRenderer = ({ ); }; +/** @public */ export type BarChartProps = { resources: ResourceData[]; responsive?: boolean; @@ -71,15 +72,18 @@ export type BarChartProps = { onMouseMove?: RechartsFunction; }; -export const BarChart = ({ - resources, - responsive = true, - displayAmount = 6, - options = {}, - tooltip = defaultTooltip, - onClick, - onMouseMove, -}: BarChartProps) => { +/** @public */ +export const BarChart = (props: BarChartProps) => { + const { + resources, + responsive = true, + displayAmount = 6, + options = {}, + tooltip = defaultTooltip, + onClick, + onMouseMove, + } = props; + const theme = useTheme(); const styles = useBarChartStyles(theme); const [activeChart, setActiveChart] = useState(false); diff --git a/plugins/cost-insights/src/components/BarChart/BarChartLegend.tsx b/plugins/cost-insights/src/components/BarChart/BarChartLegend.tsx index e7afe5fa59..72c3120dd4 100644 --- a/plugins/cost-insights/src/components/BarChart/BarChartLegend.tsx +++ b/plugins/cost-insights/src/components/BarChart/BarChartLegend.tsx @@ -21,6 +21,7 @@ import { currencyFormatter } from '../../utils/formatters'; import { CostInsightsTheme } from '../../types'; import { useBarChartLayoutStyles as useStyles } from '../../utils/styles'; +/** @public */ export type BarChartLegendOptions = { previousName: string; previousFill: string; @@ -29,18 +30,19 @@ export type BarChartLegendOptions = { hideMarker?: boolean; }; +/** @public */ export type BarChartLegendProps = { costStart: number; costEnd: number; options?: Partial; }; -export const BarChartLegend = ({ - costStart, - costEnd, - options = {}, - children, -}: PropsWithChildren) => { +/** @public */ +export const BarChartLegend = ( + props: PropsWithChildren, +) => { + const { costStart, costEnd, options = {}, children } = props; + const theme = useTheme(); const classes = useStyles(); diff --git a/plugins/cost-insights/src/components/BarChart/BarChartTooltip.tsx b/plugins/cost-insights/src/components/BarChart/BarChartTooltip.tsx index 101f0cbb8c..0b522e5e09 100644 --- a/plugins/cost-insights/src/components/BarChart/BarChartTooltip.tsx +++ b/plugins/cost-insights/src/components/BarChart/BarChartTooltip.tsx @@ -19,6 +19,7 @@ import classnames from 'classnames'; import { Box, Divider, Typography } from '@material-ui/core'; import { useTooltipStyles as useStyles } from '../../utils/styles'; +/** @public */ export type BarChartTooltipProps = { title: string; content?: ReactNode | string; @@ -27,14 +28,12 @@ export type BarChartTooltipProps = { actions?: ReactNode; }; -export const BarChartTooltip = ({ - title, - content, - subtitle, - topRight, - actions, - children, -}: PropsWithChildren) => { +/** @public */ +export const BarChartTooltip = ( + props: PropsWithChildren, +) => { + const { title, content, subtitle, topRight, actions, children } = props; + const classes = useStyles(); const titleClassName = classnames(classes.truncate, { [classes.maxWidth]: topRight === undefined, diff --git a/plugins/cost-insights/src/components/BarChart/BarChartTooltipItem.tsx b/plugins/cost-insights/src/components/BarChart/BarChartTooltipItem.tsx index 758bc9ffa0..fc50ab979a 100644 --- a/plugins/cost-insights/src/components/BarChart/BarChartTooltipItem.tsx +++ b/plugins/cost-insights/src/components/BarChart/BarChartTooltipItem.tsx @@ -19,18 +19,24 @@ import { Box, Typography } from '@material-ui/core'; import LensIcon from '@material-ui/icons/Lens'; import { useTooltipStyles as useStyles } from '../../utils/styles'; +/** @public */ export type TooltipItem = { fill: string; label: string; value: string; }; +/** @public */ export type BarChartTooltipItemProps = { item: TooltipItem; }; -export const BarChartTooltipItem = ({ item }: BarChartTooltipItemProps) => { +/** @public */ +export const BarChartTooltipItem = (props: BarChartTooltipItemProps) => { + const { item } = props; + const classes = useStyles(); + return ( { +/** @public */ +export const CostGrowth = (props: CostGrowthProps) => { + const { change, duration } = props; + const styles = useStyles(); const { engineerCost } = useConfig(); const [currency] = useCurrency(); diff --git a/plugins/cost-insights/src/components/CostGrowth/CostGrowthIndicator.tsx b/plugins/cost-insights/src/components/CostGrowth/CostGrowthIndicator.tsx index e7746495d6..8993504c84 100644 --- a/plugins/cost-insights/src/components/CostGrowth/CostGrowthIndicator.tsx +++ b/plugins/cost-insights/src/components/CostGrowth/CostGrowthIndicator.tsx @@ -23,6 +23,7 @@ import { growthOf } from '../../utils/change'; import { ChangeStatistic, GrowthType, Maybe } from '../../types'; import { useCostGrowthStyles as useStyles } from '../../utils/styles'; +/** @public */ export type CostGrowthIndicatorProps = TypographyProps & { change: ChangeStatistic; formatter?: ( @@ -31,12 +32,10 @@ export type CostGrowthIndicatorProps = TypographyProps & { ) => Maybe; }; -export const CostGrowthIndicator = ({ - change, - formatter, - className, - ...props -}: CostGrowthIndicatorProps) => { +/** @public */ +export const CostGrowthIndicator = (props: CostGrowthIndicatorProps) => { + const { change, formatter, className, ...extraProps } = props; + const classes = useStyles(); const growth = growthOf(change); @@ -46,7 +45,7 @@ export const CostGrowthIndicator = ({ }); return ( - + {formatter ? formatter(change, { absolute: true }) : change.ratio} {growth === GrowthType.Excess && } {growth === GrowthType.Savings && } diff --git a/plugins/cost-insights/src/components/LegendItem/LegendItem.tsx b/plugins/cost-insights/src/components/LegendItem/LegendItem.tsx index 92dc706003..0b8a993b39 100644 --- a/plugins/cost-insights/src/components/LegendItem/LegendItem.tsx +++ b/plugins/cost-insights/src/components/LegendItem/LegendItem.tsx @@ -20,19 +20,19 @@ import LensIcon from '@material-ui/icons/Lens'; import HelpOutlineOutlinedIcon from '@material-ui/icons/HelpOutlineOutlined'; import { useCostGrowthLegendStyles } from '../../utils/styles'; +/** @public */ export type LegendItemProps = { title: string; tooltipText?: string; markerColor?: string; }; -export const LegendItem = ({ - title, - tooltipText, - markerColor, - children, -}: PropsWithChildren) => { +/** @public */ +export const LegendItem = (props: PropsWithChildren) => { + const { title, tooltipText, markerColor, children } = props; + const classes = useCostGrowthLegendStyles(); + return ( { return new Promise(resolve => setTimeout(resolve, 0, res)); diff --git a/plugins/cost-insights/src/hooks/useConfig.tsx b/plugins/cost-insights/src/hooks/useConfig.tsx index 236c142b3b..322e1e35f1 100644 --- a/plugins/cost-insights/src/hooks/useConfig.tsx +++ b/plugins/cost-insights/src/hooks/useConfig.tsx @@ -58,6 +58,7 @@ import { configApiRef, useApi } from '@backstage/core-plugin-api'; * rate: 3.5 */ +/** @public */ export type ConfigContextProps = { metrics: Metric[]; products: Product[]; diff --git a/plugins/cost-insights/src/hooks/useCurrency.tsx b/plugins/cost-insights/src/hooks/useCurrency.tsx index 13458ee432..32dc907578 100644 --- a/plugins/cost-insights/src/hooks/useCurrency.tsx +++ b/plugins/cost-insights/src/hooks/useCurrency.tsx @@ -23,6 +23,7 @@ import React, { import { Currency } from '../types'; import { useConfig } from './useConfig'; +/** @public */ export type CurrencyContextProps = { currency: Currency; setCurrency: Dispatch>; diff --git a/plugins/cost-insights/src/index.ts b/plugins/cost-insights/src/index.ts index b9a4bb83e0..2c46156005 100644 --- a/plugins/cost-insights/src/index.ts +++ b/plugins/cost-insights/src/index.ts @@ -38,8 +38,13 @@ export { LegendItem, } from './components'; export { MockConfigProvider, MockCurrencyProvider } from './testUtils'; +export type { + MockConfigProviderProps, + MockCurrencyProviderProps, +} from './testUtils'; export * from './api'; export * from './alerts'; +export type { ConfigContextProps, CurrencyContextProps } from './hooks'; export * from './types'; export type { diff --git a/plugins/cost-insights/src/plugin.ts b/plugins/cost-insights/src/plugin.ts index a422098e08..789d803438 100644 --- a/plugins/cost-insights/src/plugin.ts +++ b/plugins/cost-insights/src/plugin.ts @@ -32,6 +32,7 @@ export const unlabeledDataflowAlertRef = createRouteRef({ id: 'cost-insights:labeling-jobs', }); +/** @public */ export const costInsightsPlugin = createPlugin({ id: 'cost-insights', featureFlags: [{ name: 'cost-insights-currencies' }], @@ -42,6 +43,7 @@ export const costInsightsPlugin = createPlugin({ }, }); +/** @public */ export const CostInsightsPage = costInsightsPlugin.provide( createRoutableExtension({ name: 'CostInsightsPage', @@ -51,6 +53,7 @@ export const CostInsightsPage = costInsightsPlugin.provide( }), ); +/** @public */ export const CostInsightsProjectGrowthInstructionsPage = costInsightsPlugin.provide( createRoutableExtension({ @@ -63,6 +66,7 @@ export const CostInsightsProjectGrowthInstructionsPage = }), ); +/** @public */ export const CostInsightsLabelDataflowInstructionsPage = costInsightsPlugin.provide( createRoutableExtension({ diff --git a/plugins/cost-insights/src/testUtils/providers.tsx b/plugins/cost-insights/src/testUtils/providers.tsx index efcb15b5a3..8088fca3c6 100644 --- a/plugins/cost-insights/src/testUtils/providers.tsx +++ b/plugins/cost-insights/src/testUtils/providers.tsx @@ -27,12 +27,11 @@ import { import { ScrollContext, ScrollContextProps } from '../hooks/useScroll'; import { Group, Duration } from '../types'; -type PartialPropsWithChildren = PropsWithChildren>; - export const MockGroups: Group[] = [{ id: 'tech' }, { id: 'mock-group' }]; -export type MockFilterProviderProps = - PartialPropsWithChildren; +export type MockFilterProviderProps = PropsWithChildren< + Partial +>; export const MockFilterProvider = ({ children, @@ -56,8 +55,9 @@ export const MockFilterProvider = ({ ); }; -export type MockLoadingProviderProps = - PartialPropsWithChildren; +export type MockLoadingProviderProps = PropsWithChildren< + Partial +>; export const MockLoadingProvider = ({ children, @@ -75,13 +75,15 @@ export const MockLoadingProvider = ({ ); }; -export type MockConfigProviderProps = - PartialPropsWithChildren; +/** @public */ +export type MockConfigProviderProps = PropsWithChildren< + Partial +>; + +/** @public */ +export const MockConfigProvider = (props: MockConfigProviderProps) => { + const { children, ...context } = props; -export const MockConfigProvider = ({ - children, - ...context -}: MockConfigProviderProps) => { const defaultContext: ConfigContextProps = { metrics: [], products: [], @@ -89,6 +91,7 @@ export const MockConfigProvider = ({ engineerCost: 0, currencies: [], }; + return ( {children} @@ -96,13 +99,15 @@ export const MockConfigProvider = ({ ); }; -export type MockCurrencyProviderProps = - PartialPropsWithChildren; +/** @public */ +export type MockCurrencyProviderProps = PropsWithChildren< + Partial +>; + +/** @public */ +export const MockCurrencyProvider = (props: MockCurrencyProviderProps) => { + const { children, ...context } = props; -export const MockCurrencyProvider = ({ - children, - ...context -}: MockCurrencyProviderProps) => { const defaultContext: CurrencyContextProps = { currency: { kind: null, @@ -111,6 +116,7 @@ export const MockCurrencyProvider = ({ }, setCurrency: jest.fn(), }; + return ( {children} @@ -118,8 +124,9 @@ export const MockCurrencyProvider = ({ ); }; -export type MockBillingDateProviderProps = - PartialPropsWithChildren; +export type MockBillingDateProviderProps = PropsWithChildren< + Partial +>; export const MockBillingDateProvider = ({ children, @@ -149,8 +156,9 @@ export const MockScrollProvider = ({ children }: MockScrollProviderProps) => { ); }; -export type MockGroupsProviderProps = - PartialPropsWithChildren; +export type MockGroupsProviderProps = PropsWithChildren< + Partial +>; export const MockGroupsProvider = ({ children, diff --git a/plugins/cost-insights/src/types/Alert.ts b/plugins/cost-insights/src/types/Alert.ts index 483b9a654d..0b6773b3a8 100644 --- a/plugins/cost-insights/src/types/Alert.ts +++ b/plugins/cost-insights/src/types/Alert.ts @@ -31,8 +31,9 @@ import { Duration } from './Duration'; * React.forwardRef. See https://reactjs.org/docs/forwarding-refs * * Errors thrown within hooks will generate a snackbar error notification. + * + * @public */ - export type Alert = { title: string | JSX.Element; subtitle: string | JSX.Element; @@ -48,6 +49,7 @@ export type Alert = { onDismissed?(options: AlertOptions): Promise; }; +/** @public */ export type AlertForm< A extends Alert = any, Data = any, @@ -55,6 +57,7 @@ export type AlertForm< AlertFormProps & RefAttributes >; +/** @public */ export interface AlertOptions { data: T; group: string; @@ -69,11 +72,14 @@ export interface AlertOptions { * inclusive of the last day. * * https://en.wikipedia.org/wiki/ISO_8601#Repeating_intervals + * + * @public */ export interface AlertSnoozeFormData { intervals: string; } +/** @public */ export interface AlertDismissFormData { other: Maybe; reason: AlertDismissReason; @@ -81,23 +87,27 @@ export interface AlertDismissFormData { } // TODO: Convert enum to literal +/** @public */ export enum AlertStatus { Snoozed = 'snoozed', Accepted = 'accepted', Dismissed = 'dismissed', } +/** @public */ export type AlertFormProps = { alert: A; onSubmit: (data: FormData) => void; disableSubmit: (isDisabled: boolean) => void; }; +/** @public */ export interface AlertDismissOption { label: string; reason: string; } +/** @public */ export enum AlertDismissReason { Other = 'other', Resolved = 'resolved', @@ -107,6 +117,7 @@ export enum AlertDismissReason { NotApplicable = 'not-applicable', } +/** @public */ export const AlertDismissOptions: AlertDismissOption[] = [ { reason: AlertDismissReason.Resolved, @@ -134,11 +145,13 @@ export const AlertDismissOptions: AlertDismissOption[] = [ }, ]; +/** @public */ export type AlertSnoozeOption = { label: string; duration: Duration; }; +/** @public */ export const AlertSnoozeOptions: AlertSnoozeOption[] = [ { duration: Duration.P7D, @@ -154,17 +167,20 @@ export const AlertSnoozeOptions: AlertSnoozeOption[] = [ }, ]; +/** @public */ export interface AlertCost { id: string; aggregation: [number, number]; } +/** @public */ export interface ResourceData { previous: number; current: number; name: Maybe; } +/** @public */ export interface BarChartOptions { previousFill: string; currentFill: string; @@ -172,15 +188,20 @@ export interface BarChartOptions { currentName: string; } -/** deprecated use BarChartOptions instead */ +/** + * @public + * @deprecated use BarChartOptions instead + */ export interface BarChartData extends BarChartOptions {} +/** @public */ export enum DataKey { Previous = 'previous', Current = 'current', Name = 'name', } +/** @public */ export interface ProjectGrowthData { project: string; periodStart: string; @@ -190,6 +211,7 @@ export interface ProjectGrowthData { products: Array; } +/** @public */ export interface UnlabeledDataflowData { periodStart: string; periodEnd: string; @@ -198,6 +220,7 @@ export interface UnlabeledDataflowData { labeledCost: number; } +/** @public */ export interface UnlabeledDataflowAlertProject { id: string; unlabeledCost: number; diff --git a/plugins/cost-insights/src/types/ChangeStatistic.ts b/plugins/cost-insights/src/types/ChangeStatistic.ts index 8264b23c8d..ba022aacf3 100644 --- a/plugins/cost-insights/src/types/ChangeStatistic.ts +++ b/plugins/cost-insights/src/types/ChangeStatistic.ts @@ -14,13 +14,16 @@ * limitations under the License. */ +/** @public */ export const EngineerThreshold = 0.5; +/** @public */ export enum ChangeThreshold { upper = 0.05, lower = -0.05, } +/** @public */ export enum GrowthType { Negligible, Savings, diff --git a/plugins/cost-insights/src/types/CurrencyType.ts b/plugins/cost-insights/src/types/CurrencyType.ts index 0316e8f90e..b20c57393f 100644 --- a/plugins/cost-insights/src/types/CurrencyType.ts +++ b/plugins/cost-insights/src/types/CurrencyType.ts @@ -14,6 +14,7 @@ * limitations under the License. */ +/** @public */ export enum CurrencyType { USD = 'USD', CarbonOffsetTons = 'CARBON_OFFSET_TONS', diff --git a/plugins/cost-insights/src/types/DateFormat.ts b/plugins/cost-insights/src/types/DateFormat.ts index c5d9c83f6e..4ada898905 100644 --- a/plugins/cost-insights/src/types/DateFormat.ts +++ b/plugins/cost-insights/src/types/DateFormat.ts @@ -14,4 +14,5 @@ * limitations under the License. */ +/** @public */ export const DEFAULT_DATE_FORMAT = 'yyyy-LL-dd'; diff --git a/plugins/cost-insights/src/types/Icon.ts b/plugins/cost-insights/src/types/Icon.ts index 24312677c9..968abd18a6 100644 --- a/plugins/cost-insights/src/types/Icon.ts +++ b/plugins/cost-insights/src/types/Icon.ts @@ -14,11 +14,13 @@ * limitations under the License. */ +/** @public */ export type Icon = { kind: string; component: JSX.Element; }; +/** @public */ export enum IconType { Compute = 'compute', Data = 'data', diff --git a/plugins/cost-insights/src/types/Loading.ts b/plugins/cost-insights/src/types/Loading.ts index eddab2401e..36dc0159c5 100644 --- a/plugins/cost-insights/src/types/Loading.ts +++ b/plugins/cost-insights/src/types/Loading.ts @@ -14,4 +14,5 @@ * limitations under the License. */ +/** @public */ export type Loading = Record; diff --git a/plugins/cost-insights/src/types/Theme.ts b/plugins/cost-insights/src/types/Theme.ts index 943bf29a12..39b4428a9f 100644 --- a/plugins/cost-insights/src/types/Theme.ts +++ b/plugins/cost-insights/src/types/Theme.ts @@ -13,15 +13,18 @@ * See the License for the specific language governing permissions and * limitations under the License. */ + import { BackstagePalette, BackstageTheme } from '@backstage/theme'; import { PaletteOptions } from '@material-ui/core/styles/createPalette'; -type CostInsightsTooltipOptions = { +/** @public */ +export type CostInsightsTooltipOptions = { background: string; color: string; }; -type CostInsightsPaletteAdditions = { +/** @public */ +export type CostInsightsPaletteAdditions = { blue: string; lightBlue: string; darkBlue: string; @@ -33,16 +36,20 @@ type CostInsightsPaletteAdditions = { dataViz: string[]; }; +/** @public */ export type CostInsightsPalette = BackstagePalette & CostInsightsPaletteAdditions; +/** @public */ export type CostInsightsPaletteOptions = PaletteOptions & CostInsightsPaletteAdditions; +/** @public */ export interface CostInsightsThemeOptions extends PaletteOptions { palette: CostInsightsPaletteOptions; } +/** @public */ export interface CostInsightsTheme extends BackstageTheme { palette: CostInsightsPalette; } diff --git a/plugins/cost-insights/src/types/index.ts b/plugins/cost-insights/src/types/index.ts index b836914e73..750114d3ec 100644 --- a/plugins/cost-insights/src/types/index.ts +++ b/plugins/cost-insights/src/types/index.ts @@ -35,45 +35,56 @@ import * as common from '@backstage/plugin-cost-insights-common'; /** * @deprecated use the same type from `@backstage/plugin-cost-insights-common` instead + * @public */ export type ChangeStatistic = common.ChangeStatistic; /** * @deprecated use the same type from `@backstage/plugin-cost-insights-common` instead + * @public */ export type Cost = common.Cost; /** * @deprecated use the same type from `@backstage/plugin-cost-insights-common` instead + * @public */ export type DateAggregation = common.DateAggregation; /** * @deprecated use the same type from `@backstage/plugin-cost-insights-common` instead + * @public */ export type Entity = common.Entity; /** * @deprecated use the same type from `@backstage/plugin-cost-insights-common` instead + * @public */ export type Group = common.Group; /** * @deprecated use the same type from `@backstage/plugin-cost-insights-common` instead + * @public */ export type Maybe = common.Maybe; /** * @deprecated use the same type from `@backstage/plugin-cost-insights-common` instead + * @public */ export type Metric = common.Metric; /** * @deprecated use the same type from `@backstage/plugin-cost-insights-common` instead + * @public */ export type MetricData = common.MetricData; /** * @deprecated use the same type from `@backstage/plugin-cost-insights-common` instead + * @public */ export type Product = common.Product; /** * @deprecated use the same type from `@backstage/plugin-cost-insights-common` instead + * @public */ export type Project = common.Project; /** * @deprecated use the same type from `@backstage/plugin-cost-insights-common` instead + * @public */ export type Trendline = common.Trendline; diff --git a/scripts/api-extractor.ts b/scripts/api-extractor.ts index 3ba5af6c7b..8407f5350a 100644 --- a/scripts/api-extractor.ts +++ b/scripts/api-extractor.ts @@ -201,7 +201,6 @@ const ALLOW_WARNINGS = [ 'packages/core-components', 'plugins/catalog', 'plugins/catalog-import', - 'plugins/cost-insights', 'plugins/git-release-manager', 'plugins/github-pull-requests-board', 'plugins/jenkins',