@grafana/ui package

A library containing the different design components of the Grafana ecosystem.

Classes

ClassDescription
BarGauge
BigValue
Cascader
ClickOutsideWrapper
ErrorBoundary
ErrorBoundaryAlert
Gauge
GraphThis is a react wrapper for the angular, flot based graph visualization. Rather than using this component, you should use the `<PanelRender …/> with timeseries panel configs.
GraphNG“Time as X” core component, expects ascending x
GraphSeriesToggler
JsonExplorerJsonExplorerJsonExplorer allows you to render JSON objects in HTML with a collapsible navigation.
JSONFormatter
List
ModalsProvider
Popover
PopoverController
RefreshPicker
SelectValueEditor
SetInterval
StatsPicker
StringArrayEditor
UnitPicker
UPlotConfigBuilder
VizRepeater

Enumerations

EnumerationDescription
BarGaugeDisplayMode
BigValueColorMode
BigValueGraphMode
BigValueJustifyMode
BigValueTextModeOptions for how the value & title are to be displayed
CompletionItemKind
EventsWithValidation
LegacyInputStatus
NodeGraphDataFrameFieldNames
SeriesVisibilityChangeBehavior

Functions

FunctionDescription
AlertingSettings({ alertmanagerDataSources, options, onOptionsChange, })
AsyncMultiSelect(props)
AsyncSelect(props)
BracesPlugin()
buildScaleKey(config)
calculateFontSize(text, width, height, lineHeight, maxSize)(BETA)
ClearPlugin()
ClipboardButton({ onClipboardCopy, onClipboardError, children, getText, …buttonProps })
ClipboardPlugin()
convertOldAngularValueMapping(panel)
Drawer({ children, inline, onClose, closeOnMaskClick, scrollableContent, title, subtitle, width, expandable, tabs, })
EmotionPerfTest()
EventsCanvas({ id, events, renderEventMarker, mapEventToXYCoords, config })
FadeTransition(props)
FileDropzone({ options, children, readAs, onLoad, fileListRenderer })
FileDropzoneDefaultChildren({ primaryText, secondaryText, })
FileListItem({ file: customFile, removeFile })
Form({ defaultValues, onSubmit, validateOnMount, validateFieldsOnMount, children, validateOn, maxWidth, …htmlProps })
getFieldTypeIcon(field)Get the icon for a given field type
getScrollbarWidth()
getTagColor(index)
getTagColorsFromName(name)Returns tag badge background and border colors based on hashed tag name.
getTextColorForBackground(color)
IndentationPlugin()
measureText(text, fontSize)(BETA)
Modal(props)
MultiSelect(props)
NewlinePlugin()
Portal(props)
preparePlotFrame(frames, dimFields, timeRange)
RadioButtonGroup({ options, value, onChange, onClick, disabled, disabledOptions, size, id, className, fullWidth, autoFocus, })
resetSelectStyles(theme)
RunnerPlugin({ handler })
Segment({ options, value, onChange, Component, className, allowCustomValue, allowEmptyValue, placeholder, disabled, inputMinWidth, inputPlaceholder, onExpandedChange, autofocus, …rest })
SegmentAsync({ value, onChange, loadOptions, reloadOptionsOnChange, Component, className, allowCustomValue, allowEmptyValue, disabled, placeholder, inputMinWidth, inputPlaceholder, autofocus, onExpandedChange, noOptionMessageHandler, …rest })
SegmentInput({ value: initialValue, onChange, Component, className, placeholder, inputPlaceholder, disabled, autofocus, onExpandedChange, …rest })
Select(props)
SelectionShortcutsPlugin()
sharedSingleStatMigrationHandler(panel)
sharedSingleStatPanelChangedHandler(panel, prevPluginId, prevOptions)
SlatePrism(optsParam, prismLanguages)A Slate plugin to highlight code syntax.
SlideOutTransition(props)
stylesFactory(stylesCreator)
SuggestionsPlugin({ onTypeahead, cleanText, onWillApplySuggestion, portalOrigin, })
TabbedContainer(props)
useStyles(getStyles)
useStyles2(getStyles)
useTheme()
useTheme2()
ValuePicker({ label, icon, options, onChange, variant, minWidth, size, isFullWidth, menuPlacement, })
VizLegend({ items, displayMode, sortBy: sortKey, seriesVisibilityChangeBehavior, sortDesc, onLabelClick, onToggleSort, placement, className, itemRenderer, readonly, })
withErrorBoundary(Component, errorBoundaryProps)HOC for wrapping a component in an error boundary.

Interfaces

InterfaceDescription
AsyncSelectProps
BadgeProps
CardContainerProps
CardProps
CascaderOption
CompletionItem
CompletionItemGroup
ConfirmModalProps
ContextMenuProps
CustomControlProps
DatePickerProps
DatePickerWithInputProps
DropzoneFile
ErrorBoundaryAlertPropsProps for the ErrorBoundaryAlert component
FieldArrayApi
FileDropzoneProps
FileListItemProps
GraphNGProps
GraphSeriesTogglerAPI
LoadingPlaceholderProps
MultiSelectCommonProps
PlotSelection
PluginSignatureBadgeProps
SelectableOptGroup
SelectAsyncProps
SelectBaseProps
SelectCommonProps
SelectContainerProps
SeriesTableProps
SeriesTableRowProps
SingleStatBaseOptions
SuggestionsState
TabConfig
TableSortByFieldState
Themeable
Themeable2
TimeRangePickerProps
Token
TypeaheadInput
TypeaheadOutput
ValidationEvents
ValidationRule
VizLayoutComponentType(BETA)
VizLayoutLegendProps(BETA)
VizLayoutProps(BETA)
VizLegendItem
VizRepeaterRenderValueProps

Namespaces

NamespaceDescription
commonOptionsBuilder
DOMUtil
Modal
RadioButtonGroup
ReactUtils
styleMixins
VizLegend

Variables

VariableDescription
Alert
Badge
Button
ButtonCascader
ButtonGroup
ButtonSelect
CallToActionCard
CardGeneric card component
CardContainer
CertificationKey
Checkbox
CodeEditor
CollapsableSection
Collapse
ColorPicker
colors
ConfirmButton
ConfirmModal
Container
ContextMenu
ControlledCollapse
Counter
CustomScrollbarWraps component into component from react-custom-scrollbars
DataLinkInput
DataLinksContextMenu
DataLinksInlineEditor
DataSourceHttpSettings
DatePicker
DatePickerWithInput
DateTimePicker
defaultIntervals
DeleteButton
DropdownIndicator
EmptySearchResult
ErrorWithStack
FeatureBadge
FeatureInfoBox
Field
FieldArray
fieldMatchersUI
FieldSet
FieldValidationMessage
FileUpload
FilterInput
FilterPill
FormattedValueDisplay
FullWidthButtonContainer
getAvailableIcons
getCardStyles
getFormStyles
getInputStyles
getLogRowStyles
getSelectStyles
getStandardFieldConfigsReturns collection of common field config properties definitions
getTheme
graphTickFormatter
graphTimeFormat
GraphWithLegend
hasValidationEvent
HorizontalGroup
Icon
IconButton
InfoBox
InlineField
InlineFieldRow
InlineFormLabel
InlineLabel
InlineSegmentGroup(BETA)
InlineSwitch
Input
InputControl
Label
LegacyForms
Legend
LinkButton
linkModelToContextMenuItemsDelays creating links until we need to open the ContextMenu
LoadingPlaceholder
LogLabels
LogMessageAnsi
LogRows
makeFragment
makeValue
Marker
mockTheme
mockThemeContext
ModalRoot
ModalsContext
ModalsController
ModalTabsHeader
NumberValueEditor
Pagination
PanelContextRoot
PlotLegend
PluginSignatureBadge
QueryField
RangeSliderRichHistoryQueriesTab uses this Range Component
regexValidation
SCHEMA
SelectContainer
selectOptionInTest
SeriesColorPicker
SeriesColorPickerPopover
SeriesColorPickerPopoverWithTheme
SeriesIcon
SeriesTable
SeriesTableRow
sharedInputStyle
Slider
SliderValueEditor
sortedColors
Spinner
StringValueEditor
Switch
Tab
TabContent
Table
TableInputCSV
TabsBar
Tag
TagList
TagsInput
TextArea
ThemeContext
TimeOfDayPicker
TimeRangeInput
TimeRangePicker
TimeSeries
TimeZonePicker
TLSAuthSettings
ToolbarButton
ToolbarButtonRow
Tooltip
UPLOT_AXIS_FONT_SIZE
validate
VerticalGroup
VizLayout(BETA)
VizTooltip
VizTooltipContainer
WeekStartPicker
WithContextMenu
withTheme
XYCanvasRenders absolutely positioned element on top of the uPlot’s plotting area (axes are not included!). Useful when you want to render some overlay with canvas-independent elements on top of the plot.

Type Aliases

Type AliasDescription
ActionMeta
AlertVariant
BadgeColor
ButtonProps
ButtonVariant
CodeEditorMonacoOptions
ControlComponent
FormAPI
FormatOptionLabelMeta
FormInputSize
IconButtonVariant
IconName
IconSize
IconType
InputActionMeta
Monaco
MonacoEditor
OnTagClick
PopoverContent
Renderable
RenderFunction
ScrollbarPosition
SelectOptions
SelectValue