ui.DateSlider
A draggable target that ranges linearly between two dates. The date slider can be configured to display dates of various interval sizes, including day, 8-day, and year. The value of the slider is displayed as a label alongside it.
Usage | Returns |
---|
ui.DateSlider(start, end, value, period, onChange, disabled, style) | ui.DateSlider |
Argument | Type | Details |
---|
start | Date|Number|String, optional | The start date, as a UTC timestamp, date string, or ee.Date. Defaults to one week ago. |
end | Date|Number|String, optional | The end date, as a UTC timestamp, date string, or ee.Date. Defaults to today. |
value | Date|Number|String, optional | The initial value. The value is an array consisting of the start and end date for the selected date range, but for convenience, it can be set by specifying the start date alone. Defaults to yesterday. |
period | Number, optional | The interval size for values on the slider in days. Defaults to one. |
onChange | Function, optional | A callback to fire when the slider's state changes. The callback is passed an ee.DateRange representing the slider's current value and the slider widget. |
disabled | Boolean, optional | Whether the slider is disabled. Defaults to false. |
style | Object, optional | An object of allowed CSS styles with their values to be set for this widget. Defaults to an empty object. |
Except as otherwise noted, the content of this page is licensed under the Creative Commons Attribution 4.0 License, and code samples are licensed under the Apache 2.0 License. For details, see the Google Developers Site Policies. Java is a registered trademark of Oracle and/or its affiliates.
Last updated 2023-10-06 UTC.
[null,null,["Last updated 2023-10-06 UTC."],[[["The DateSlider widget provides a user interface for selecting a date range on a linear scale."],["It offers flexibility in displaying various date intervals, including day, 8-day, and year."],["Users can customize the start and end dates, initial value, interval size, and add event listeners for changes."],["The slider displays a label indicating the selected date range and supports both single date selection and range selection."],["Styling options are available to modify the appearance of the widget."]]],[]]