Filter Bar

Pro

Horizontal filter row with a Filters button and count badge, toggle chips, and dropdown chips that open a sheet. Sheets show a live result count, and a Clear chip appears once a filter is on.

Preview

Installation

npx @lumioui/cli add pro/filter-bar

Usage

import { countActiveFilters, FilterBar } from "@/components/ui/filter-bar/filter-bar";
<FilterBar />

Also exported: countActiveFilters.

Examples

Job board

A job board's results with a Filters entry point.

Food delivery

A food-delivery home feed.

Holiday stays

Holiday-rental results for the Lake District.

API reference

Prop Type Default
filters* FilterDef[]

Chip definitions, in rail order.

—
value FilterValue

Controlled filter state.

—
defaultValue FilterValue

Uncontrolled initial state.

{}
onValueChange (value: FilterValue) => void

Fires with the whole new state on every change.

—
onFiltersPress () => void

Shows a leading "Filters" button (your full filter screen).

—
filtersCount number

Badge on the Filters button. Default: number of active chips.

—
showClear boolean

Show a trailing "Clear" chip when anything is on. Default true.

true
resultCount number

Live result count for the multi-select sheet button.

—
resultLabel (count: number) => string

Sheet button copy from the count. Default Show N results.

—
size "sm" | "md"

Chip height — sm 32, md 36 (default).

"md"
inset number

Horizontal padding of the rail (matches your screen gutter). Default 16.

16
className string —