Histogram

pro

Historgram draws a value distribution as bars and highlights whichever sub-range currently matches a paired range control.

$100 – $350

Installation

Add this component with the NateUI CLI.

npx nateui@latest add Histogram

Examples

Price Filter

API

Historgram is presentational — its bars have pointer-events: none and cannot be clicked or dragged directly. Pair it with an interactive range control such as Slider.Range (see Usage) so range updates from user input.

PropDescriptionTypeDefault
dataBars to render, one per bin. label is part of the shape but not currently rendered by the component.{ value: number; label: string }[]—
rangeCurrently highlighted sub-range; bars whose bin center falls inside it render in the active color.[number, number]—
minLower bound of the domain data spans.number—
maxUpper bound of the domain data spans.number—
classNameClass names applied to every bar. Overriding a bg-* utility recolors all bars uniformly and loses the active/inactive distinction; shape or spacing utilities like rounded-* and mx-* override safely.string—