Files
grafana/packages/grafana-ui/src/components/PanelChrome/index.ts
Alexa V 0eeeeef08b PanelChrome: Refactor and refine items next to title (#60514)
Co-authored-by: Torkel Ödegaard <torkel@grafana.com>
Co-authored-by: Polina Boneva <13227501+polibb@users.noreply.github.com>
Co-authored-by: polinaboneva <polina.boneva@grafana.com>
2023-01-16 15:56:39 +00:00

46 lines
1.3 KiB
TypeScript

import React from 'react';
import { ErrorIndicator } from './ErrorIndicator';
import { LoadingIndicator } from './LoadingIndicator';
import { PanelChrome as PanelChromeComponent, PanelChromeProps } from './PanelChrome';
/**
* @internal
*/
export type { PanelChromeProps, PanelPadding } from './PanelChrome';
/**
* @internal
*/
export interface PanelChromeType extends React.FC<PanelChromeProps> {
LoadingIndicator: typeof LoadingIndicator;
ErrorIndicator: typeof ErrorIndicator;
}
/**
* @internal
*/
export const PanelChrome = PanelChromeComponent as PanelChromeType;
PanelChrome.LoadingIndicator = LoadingIndicator;
PanelChrome.ErrorIndicator = ErrorIndicator;
/**
* Exporting the components for extensibility and since it is a good practice
* according to the api-extractor.
*/
export {
LoadingIndicator as PanelChromeLoadingIndicator,
type LoadingIndicatorProps as PanelChromeLoadingIndicatorProps,
} from './LoadingIndicator';
export {
ErrorIndicator as PanelChromeErrorIndicator,
type ErrorIndicatorProps as PanelChromeErrorIndicatorProps,
} from './ErrorIndicator';
export { PanelDescription } from './PanelDescription';
export { usePanelContext, PanelContextProvider, type PanelContext, PanelContextRoot } from './PanelContext';
export * from './types';