Rating Filter

Star rows for minimum-rating filtering in the familiar n-and-up pattern. Clicking the active row clears the selection.

Rating

Requires shadcn/ui initialized. Run npx shadcn@latest init if you haven't.

Import & use
import { FilterRating } from "@/components/beste/component/filter-rating";

<FilterRating
  label="Rating"
  defaultValue="4"
  onChange={(value) => console.log("minimum rating:", value)} // null when cleared
  options={[
    { label: "4 & up", value: "4" },
    { label: "3 & up", value: "3" },
  ]}
/>

More Filter components

View all Filter

Gender

Segmented Filter

filter-segmented

Single-select segmented control built on Tabs for mutually exclusive choices like gender or condition. Clicking the active segment clears the selection.

Size

Multiselect Filter

filter-multiselect

Dropdown with checkbox rows and a selection-count badge. Keeps many-option filters compact in toolbars where a checkbox list would not fit.

Fit

32
14
21

Radio Filter

filter-radio

Single-select radio list with optional result counts. Clicking the active option clears the selection, so the filter is always escapable.

Category

42
24
10
8
38
12

Tree Filter

filter-tree

Hierarchical checkbox tree for nested categories with expand/collapse rows. Checking a parent checks its whole subtree, and partially selected parents turn indeterminate.

Deals

Toggle Filter

filter-toggle

Switch rows for boolean product flags like on-sale or in-stock. Multi-select, works controlled or uncontrolled.

Price

to

Paired number inputs for open-ended ranges: either side can stay empty, so users can filter by only a minimum or only a maximum.