IconLogoMark
IconUiExpandCollapseDown

Release NotesIconUiExpandCollapseDown

ComponentsIconUiExpandCollapseDown

AvatarsIconUiExpandCollapseDown
ButtonsIconUiExpandCollapseDown
Data VisualizationIconUiExpandCollapseDown
DialogsIconUiExpandCollapseDown
FormsIconUiExpandCollapseDown
IconsIconUiExpandCollapseDown
NotificationsIconUiExpandCollapseDown
ThemesIconUiExpandCollapseDown
TypeIconUiExpandCollapseDown

GuidelinesIconUiExpandCollapseDown

PatternsIconUiExpandCollapseDown

WordsIconUiExpandCollapseDown

ResourcesIconUiExpandCollapseDown

Histogram

/

Design

Represent data by frequency distribution in a bar graph.

Use histograms to provide representation for multiple values of data distributed by frequency in a logical order.

Behavior

Selection

The histogram allows single or multi selection when clicking or tapping on individual items. When selected, the entire item, including the bar and text, turns blue.

View Modes

Histograms can be viewed in the collapsed, expanded, and preview view modes for data cards.

Collapsed

When displayed in the collapsed view mode, the histogram omits labels and percentages and acts as a mini-preview.

  • Mobile: When tapping the mini-histogram, the view mode should switch to preview in order to make selection easier for the user. The selected item within the histogram should be selected and displayed before switching to preview mode.
  • Web: When hovering or focusing on a histogram item, tooltips are displayed which include the label value of that item. On click, the histogram item should be selected.

Expanded

When displayed in the expanded view mode, the histogram list always displays all items included in the list.

Preview

In the preview view mode, the full histogram is always displayed.

Usage

Module System

Histograms are part of the module system, and should only be used within data cards. Histograms should be used to filter content using multiple data set options.

Don't use histograms outside of data cards.

Don'tuse histograms outside of data cards.

Do use histograms within the module system.

Douse histograms within the module system.

Microcopy

Labels

Label values are required when using histograms. However, in dense data sets, overlapping text becomes a larger risk. We recommend limiting character length, sometimes omitting or combining labels based on the density of the histogram used.

Web

  • For 2-4 items, limit labels to 10 characters each.
  • For 5-9 items, limit labels to four characters each.
  • For 10 or more items, limit labels to three characters each.
  • For more than 12 items, omit at least every other label.
  • For more than 15 items, omit at least every other label, and always show the most positive, most negative, and zero value labels.

Mobile

  • For 2-4 items, limit labels to seven characters each.
  • For 5-9 items, limit labels to four characters each.
  • For 10 or more items, limit labels to three characters each.
  • For more than 12 items, omit at least every other label.
  • For more than 15 items, omit at least every other label, and always show the most positive, most negative, and zero value labels.

Don't use verbose labels in histogram items.

Don'tuse verbose labels in histogram items.

Do use concise, logical labels in histogram items.

Douse concise, logical labels in histogram items.

Don't sacrifice readability to include labels.

Don'tsacrifice readability to include labels.

Do  intentionally hide or combine labels.

Do intentionally hide or combine labels.

Accessibility

Use descriptions when labels aren’t enough

Sometimes the item label alone isn’t enough to aptly convey its meaning. For example, a histogram for “Ball Carriers” might have labels that include the players’ numbers, but omit the name to save space. By adding players’ full names as descriptions, we can provide that extra information via ARIA attributes for screen readers and tooltips.

Don't use tooltips to provide unnecessary information or directions.

Don'tuse tooltips to provide unnecessary information or directions.

Do use tooltips to display a concise description when labels could be misunderstood.

Douse tooltips to display a concise description when labels could be misunderstood.

Don't omit histogram item context in collapsed view mode.

Don'tomit histogram item context in collapsed view mode.

Do include relevant item information, like clip count in parenthesis after the label, in a tooltip.

Doinclude relevant item information, like clip count in parenthesis after the label, in a tooltip.

Keyboard Navigation

Tab navigation is fully supported by default in histograms. Users can press enter to toggle the selection of an item. Sequential tab order will be maintained for individual items in both the mini-histogram and larger histograms.

Clip Count

When the histogram is collapsed into it’s mini-state, all label and clip count information is removed. Use a tooltip to include all of the relevant item information. When selected, include the clip count after any additional information.

Don't omit histogram item context in collapsed view mode.

Don'tomit histogram item context in collapsed view mode.

Do include any relevant item information to the histogram item in a tooltip.

Doinclude any relevant item information to the histogram item in a tooltip.

Don't remove important information.

Don'tremove important information.

Do include clip count in a tooltip to keep it accessible to the user.

Doinclude clip count in a tooltip to keep it accessible to the user.

Audit Results

See our full accessibility audit for more information about these results.

PlatformVisualInteractiveAutomatedDetails
ReactIconConfirmation PassIconConfirmation PassIconConfirmation Pass
React NativeIconWarning WarningIconCritical ViolationsIconWarning N/A
  • IconWarningAnimation is not disabled if user sets reduced motion preference. (AAA)
  • IconWarningAt least one variation of this component does not meet the 44px touch target standard. (AAA)
  • IconCriticalThe accessibilityState property needs to be used to show selection state.

Related

Data Card

Card Group

Data Visualizations

Module System

Accessibility

Platform Support

The histogram is available for React and React Native.