The Calendar component for Retool Apps
A content area to display calendar events.
Calendar uses the FullCalendar library.
Properties
All properties for this object with supported data types or values. You can write JavaScript almost anywhere in Retool to manipulate or read property values.
changeSet
Edited values for each row.
Type | array |
Format | Custom data |
Array values | object |
Mutability | Read-only |
colorByIndex
A list of colors for each item, by index.
Type | array |
Array values | string |
Mutability | Read-only |
data
The data.
Type | string | number | boolean | object | array | ||||||
Format | Custom data | ||||||
Mutability |
|
dayMaxEvents
The maximum number of events to display, per day, when viewType
is month
. If not set, events stack to the height of the cell.
Type | number | ||||
Mutability |
|
displayAllDaySlot
Whether to display the all-day event slot.
Type | boolean | ||||
Mutability |
|
displayEventTime
Whether to display event times.
Type | boolean | ||||
Mutability |
|
displayTimeZone
The time zone (UTC offset) that applies to the display value. Uses the time zone reported by the browser if set to local
.
Type | string | ||||
Mutability |
|
eventMaxStack
The maximum number of events to display in a stack.
Type | number | ||||
Mutability |
|
firstDayOfWeek
The first day of the week, by index, with Sunday as 0
.
Type | string | ||||||||||||||||
Mutability |
| ||||||||||||||||
Allowed Values |
|
groupIdByIndex
A list of group IDs for each item, by index.
Type | array |
Array values | number |
Mutability | Read-only |
hidden
Whether this object is hidden from view.
Type | boolean | ||||||
Format | True/False | ||||||
Mutability |
| ||||||
Default |
|
Examples
true
id
The unique identifier (name).
Type | string | ||||
Format | Plain Text | ||||
Mutability |
| ||||
Default |
|
Examples
query1
button1
isHiddenOnDesktop
Whether to show or hide this object in the desktop layout.
Type | boolean | ||||
Format | True/False | ||||
Mutability |
| ||||
Default |
|
Examples
true
isHiddenOnMobile
Whether to show or hide this object in the mobile layout.
Type | boolean | ||||
Format | True/False | ||||
Mutability |
| ||||
Default |
|
Examples
true
itemMode
The configuration mode for options.
Type | string | |||||||||
Mutability |
| |||||||||
Allowed Values |
| |||||||||
Default |
|
Examples
"dynamic"
listType
The date range to display in list view.
Type | string | ||||||||||
Mutability | Read-only | ||||||||||
Allowed Values |
|
maintainSpaceWhenHidden
Whether to take up space on the canvas if hidden
is true
.
Type | boolean | ||||
Format | True/False | ||||
Mutability |
| ||||
Default |
|
Examples
true
margin
The amount of margin to render outside.
Type | string | |||||||||
Format | Plain Text | |||||||||
Mutability |
| |||||||||
Allowed Values |
| |||||||||
Default |
|
Examples
4px 8px
showInEditor
Whether the component remains visible in the editor if hidden
is true
.
Type | boolean | ||||
Format | True/False | ||||
Mutability |
| ||||
Default |
|
Examples
true
style
Custom style options.
Type | object | ||||
Mutability |
|
view
The view.
Type | string | ||||||||||||
Mutability | Read-only | ||||||||||||
Allowed Values |
|
viewType
The type of view to display.
Type | string | ||||||||
Mutability |
| ||||||||
Allowed Values |
|
Methods
JavaScript API methods for this object. You can write JavaScript almost anywhere in Retool and use methods to manipulate data and property values.
calendar.scrollIntoView()
Scrolls the canvas or parent container so that the selected component appears in the visible area.
calendar.scrollIntoView(options)
Parameters
Object Properties
behavior
The scroll behavior.
Type | string | ||||||
Allowed Values |
|
block
The scroll position relative to the component.
Type | string | ||||||||||
Allowed Values |
|
Examples
Scroll the minimum amount to immediately bring calendar
into view.
calendar.scrollIntoView({behavior: 'auto', block: 'nearest'});
calendar.setHidden()
Set the hidden
value to toggle whether the component is visible. Defaults to true
without a parameter.
calendar.setHidden(hidden)
Parameters
Examples
true
Examples
Hide calendar
.
calendar.setHidden(true);
Unhide calendar
.
calendar.setHidden(false);
Events
Events triggered by user interactions. You can configure event handlers in the IDE to trigger queries or other actions in response to events.
Event | Description |
---|---|
Change Event | An event is changed. |
Click Event | An event is clicked or pressed. |
Create Event | An event is created. |
Remove Event | An event is removed. |