We use cookies to give you the best experience on our website. If you continue to browse, then you agree to our privacy policy and cookie policy. Image for the cookie policy date
Syncfusion Feedback

Trusted by the world’s leading companies

Syncfusion Trusted Companies

Overview

The JavaScript Range Selector is an interface for selecting a small range from a larger collection. It is commonly used in financial dashboards to filter a date range for data that needs to be visualized.


Data types

Plot any type of data in the range selector using different value types like numeric, date-time, and logarithmic.


Chart types

Plot data in the range selector with different chart types like line, area, and step line.


Lightweight

Skip the chart and show only the range for selecting data. This makes the range selector lightweight in mobile devices.


Scales

Major and minor scales display the range with different intervals and are placed at multiple levels of the range selector. A date-time scale can also be configured to be shown in major and minor scales.


Period selector

Select data using predefined periods in the range selector and use the date picker to select a custom range.


Binding selected data

Bind selected data from the range selector to any other data visualization control using built-in events.


Deferred scrolling

Allows you to defer the selected range to be updated until the user stops dragging the scrolling thumbs. This provides a smooth scrolling experience.


Range selection

The range selector control provides the following three ways to select a range:

  • Select a range through labels.
  • Drag the left and right thumbs.
  • Drag the selected range to maintain the same delta.

HTML5 JavaScript Range Selector selection


Customization

All the elements of the range selector are highly customizable with built-in APIs.

HTML5 JavaScript Range Selector labels

Labels

Customize the size, color, font family, font attribute, and alignment of the labels using built-in APIs.

HTML5 JavaScript Range Selector thumb

Thumbs

Customize the appearance of the left and right thumbs using built-in APIs.

HTML5 JavaScript Range Selector gridlines

Gridlines

Customize the color, stroke width, dash array, and visibility of the major and minor gridlines using built-in APIs.


Tooltip

Tooltips display the start and end values of a selected range, allowing users to easily select a required range.


RTL

The range selector supports right-to-left rendering and allows the series and scale direction to be displayed from the right to left. This improves the user experience and accessibility of RTL languages.


Touch and Browser support

The interactive range selector control also support touch interactions.

Touch illustration in HTML5 JavaScript Range Selector

Touch support

All the features in range selector will work on touch devices with zero configuration. Use the touch features such as tooltip and thumb drag without any customization.

Responsive illustration in HTML5 JavaScript Range Selector

Responsive

You can view the range selector on various devices. It is also possible to hide chart for particular screen sizes by making a very minimal change.

Cross browser illustration in HTML5 JavaScript Range Selector

Cross browser support

You can render range selector control in all the modern browsers.


JavaScript Range Selector Code Example

Easily get started with JavaScript Range Selector using a few simple lines of HTML and JS code example as demonstrated below. Also explore our JavaScript Range Selector Example that shows you how to render and configure the chart.

<!DOCTYPE html>
<html>
<head></head>
<body> 
    <div id="container">
     <div id="element"></div>
    </div>
</body>
</html>
import { RangeNavigator, AreaSeries, DateTime}  from "@syncfusion/ej2-charts";
RangeNavigator.Inject(AreaSeries, DateTime);
import { datasrc } from "./datasource.ts";

let range: RangeNavigator = new RangeNavigator({
  valueType: 'DateTime',
  value: [new Date('2017-09-01'), new Date('2018-02-01')],
  labelFormat: 'MMM-yy',
  series: [{
            dataSource: datasrc, xName: 'x', yName: 'y', type: 'Area', width: 2,
        }],
}, '#element');

Other supported frameworks

The Range Selector component is also available in Blazor, React, Angular, and Vue frameworks. Check out the different Range Selector platforms from the links below,



85+ JAVASCRIPT UI CONTROLS

Our Customers Love Us

Having an excellent set of tools and a great support team, Syncfusion reduces customers’ development time.
Here are some of their experiences.

Rated by users across the globe

Transform your applications today by downloading our free evaluation version
Download Free Trial No credit card required.

Awards

Greatness—it’s one thing to say you have it, but it means more when others recognize it. Syncfusion is proud to hold the following industry awards.

Up arrow icon