Reflex Logo

Intro

Gallery

Hosting

Components

New

Learn

Components

API Reference

Onboarding

Library

/

Graphing

/

Brush

The brush component allows us to view charts that have a large number of data points. So to view and analyze them efficiently, there is a slider down them that helps the viewer to select some data points that the viewer needs to be displayed.

rx.recharts.bar_chart(
    rx.recharts.bar(
        data_key="uv", stroke="#8884d8", fill="#8884d8"
    ),
    rx.recharts.bar(
        data_key="pv", stroke="#82ca9d", fill="#82ca9d"
    ),
    rx.recharts.brush(
        data_key="name", height=30, stroke="#8884d8"
    ),
    rx.recharts.x_axis(data_key="name"),
    rx.recharts.y_axis(),
    data=data,
)

A Brush component in Recharts.

PropTypeDescriptionValues
strokestr

Stroke color

data_keyUnion

The key of data displayed in the axis.

xint

The x-coordinate of brush.

yint

The y-coordinate of brush.

widthint

The width of brush.

heightint

The height of brush.

dataList

The data domain of brush, [min, max].

traveller_widthint

The width of each traveller.

gapint

The data with gap of refreshing chart. If the option is not set, the chart will be refreshed every time

start_indexint

The default start index of brush. If the option is not set, the start index will be 0.

end_indexint

The default end index of brush. If the option is not set, the end index will be 1.

Event Triggers

TriggerDescription
on_change

The on_change event handler is called when the value or checked state of the component changes.

← BarchartCartesianaxisgrid →

Did you find this useful?

HomeGalleryChangelogIntroductionHosting