import type { ConvertibleUnit, FormatOptions, Unit } from '@dynatrace-sdk/units'; import type { HoneycombCustomTooltipConfig } from './honeycomb-internal.js'; import type { HoneycombLabelsDisplay, HoneycombTileShape } from './honeycomb.js'; import type { TruncationMode } from '../../../typography/text-ellipsis/TextEllipsis.js'; import type { ChartUnit } from '../../core/types/chart-unit.js'; import type { ColorPalette } from '../../core/types/color-palette.js'; import type { ColorRuleProps } from '../../core/types/color-rule.js'; import type { ColoredRange } from '../../core/types/colored-range.js'; import type { Formatter } from '../../core/types/formatter.js'; import { ChartToolbarConfig } from '../../core/types/toolbar.js'; import type { HoneycombLegendProps } from '../slots/HoneycombLegend.js'; /** * Honeycomb toolbar configuration * @public */ export type HoneycombChartToolbarConfiguration = Omit & { downloadCSV?: { enabled: boolean; }; }; /** * This is the information that should be returned to the consumer as exported config * @public */ export interface HoneycombConsumerExportedConfig extends Omit { toolbar?: Omit; } /** * Interface exposed to let consumer configure slots within Honeycomb * @public */ export interface HoneycombChartProperties { /** Honeycomb shape to be applied as configuration */ shape?: HoneycombTileShape; /** Honeycomb color scheme to be applied as configuration */ colorScheme?: ColorPalette | ColoredRange[] | { [key: string]: string; } | string[]; /** Honeycomb legend configuration */ legend?: HoneycombLegendProps; /** Honeycomb toolbar configuration */ toolbar?: HoneycombChartToolbarConfiguration; /** * Custom formatter for honeycomb's tiles values */ formatter?: Formatter | FormatOptions; /** * The custom unit for honeycomb's tiles values. */ unit?: ChartUnit; /** truncation mode to be used in legend and tooltip */ truncationMode?: TruncationMode; /** The min value configuration to display */ min?: number | 'data-min'; /** The max value configuration to display */ max?: number | 'data-max'; /** * Controls which label content is shown inside each honeycomb tile. * Takes precedence over `showLabels` when both are provided. * * @defaultValue 'none' */ labelsDisplay?: HoneycombLabelsDisplay; /** * Show/hide labels and values within the nodes. * * @deprecated Use `labelsDisplay` instead. Will be removed in a future major release. */ showLabels?: boolean; /** * Font size (in pixels) for tile labels, or `'auto'` to pick a size * per tile based on its height. * * @defaultValue 16 */ textSize?: number | 'auto'; colorRules?: ColorRuleProps[]; /** Tooltip configuration */ tooltip?: HoneycombCustomTooltipConfig; }