Stat
Stat panel - single value display with optional sparkline.
Use for displaying key metrics at a glance.
<Stat title="CPU %" unit="percent" thresholds={{ 70: 'yellow', 90: 'red' }}> 100 - avg(rate(cpu_idle[$__rate_interval])) * 100</Stat>Example 2
Section titled “Example 2”// With percent change indicator<Stat title="Orders" showPercentChange percentChangeColorMode="inverted"> sum(orders_total)</Stat>| Prop | Type | Default | Description |
|---|---|---|---|
unit | Unit | - | Display unit |
decimals | number | - | Decimal places |
thresholds | ThresholdSpec | - | Threshold configuration |
baseColor | 'green' | 'transparent' | 'text' | string | green | Base threshold color |
colorMode | 'value' | 'background' | 'background_solid' | 'none' | - | Color mode for stat value |
graphMode | 'area' | 'line' | 'none' | - | Show sparkline graph |
textMode | 'value' | 'name' | 'value_and_name' | 'none' | 'auto' | - | Text display mode |
noValue | string | - | Value to show when no data |
overrides | OverrideConfig[] | - | Field overrides for series-specific styling |
transformations | Transformation[] | - | Data transformations |
justifyMode | BigValueJustifyMode | - | Text alignment within the panel |
showPercentChange | boolean | - | Show percent change from previous value |
percentChangeColorMode | PercentChangeColorMode | - | Color mode for percent change indicator |
wideLayout | boolean | - | Use wide layout (values side by side) |
orientation | VizOrientation | - | Visualization orientation |
reduceOptions | ReduceDataOptions | - | Data reduction options (advanced) |
Inherits from BasePanelProps