UNPKG

@pagamio/frontend-commons-lib

Version:

Pagamio library for Frontend reusable components like the form engine and table container

59 lines (58 loc) 2.32 kB
import type { QueryProps } from 'src/shared/types'; import type { ChartToolTipProps, DistributionChartTooltip, DistributionQueryProps, StatisticsQueryProps, TableColumn, TooltipField } from '../types'; interface BarChartProps<TData extends { id: string | number; }> { options?: any; title?: string; stacked?: boolean; chartDetails?: { columns?: any[]; data?: any[]; }; themeColor?: string; colors?: string[]; url?: string; query: QueryProps; seriesDataNameKey: string; seriesDataValueKey: string; xAxisDataValueKey: string; chartToolTip?: ChartToolTipProps; tooltipValueFormat: string; tooltipTitle?: string; tooltipUnit?: string; tooltipAdditionalFields?: (string | TooltipField)[]; currencyDisplaySymbol?: string; metricDetailData: { statisticsUrl?: string; title: string; topFiveChartTitle: string; bottomFiveChartTitle: string; itemStatisticsQuery: StatisticsQueryProps; yAxisDataNameKey: string; xAxisNameKey: string; xAxisLabel: string; yAxisLabel: string; valueMetricsQuery: StatisticsQueryProps; averageMetricsQuery: StatisticsQueryProps; distributionMetricsQuery: DistributionQueryProps; nameKey: string; valueKey: string; dataGridSearchKey: string; dataGridColumns: TableColumn<TData>[]; dataSearchInputPlaceHolder: string; chartToolTip?: ChartToolTipProps; detailsTableTitle?: string; distributionChartTooltip: DistributionChartTooltip; }; } declare const BarChart: <TData extends { id: string | number; }>({ query, options, title, stacked, url, xAxisDataValueKey, seriesDataNameKey, seriesDataValueKey, chartToolTip, tooltipValueFormat, tooltipTitle, tooltipUnit, tooltipAdditionalFields, currencyDisplaySymbol, metricDetailData, showDetailsModal, xAxisLabelRotate, xAxisLabelMaxLength, xAxisLabelFormatter, yAxisLabelFormatter, ...props }: BarChartProps<TData> & { showDetailsModal?: boolean; xAxisLabelRotate?: number; xAxisLabelMaxLength?: number; xAxisLabelFormatter?: (label: string) => string; yAxisLabelFormatter?: (value: number) => string; }) => import("react/jsx-runtime").JSX.Element; export default BarChart;