class
                DefaultSidebar
                        
                            extends Sidebar
                    
Default sidebar implementation.
- Properties
- background, clippedWidth, data, dividerColor, fontFamily, foregroundColor, hoverOverlayColor, opened, overlayColor, textSize, timeline, width
- Methods
- constructor, addMutationListener, beforeDraw, close, createAnimatableProperty, disconnectedCallback, drawContent, drawOverlay, drawUnderlay, open, removeMutationListener, reportMutation, toggle
Properties
- backgroundgetset
- Background style of the entire sidebar. - Type:
- 
                    FillStyle
 
- clippedWidthget
- While a sidebar animation is underway (transitioning from open to closed, or vice versa), this represents the current width instead of the target width. - Type:
- 
                    number
 
- datagetset
- Arbitrary data. For example an identifier of a backend system. - Type:
- 
                    any
 
- dividerColorgetset
- Color of the right border that separates the sidebar from the timeline content. - Type:
- 
                    string
- Default value:
- '#e3e3e3'
 
- fontFamilygetset
- Type:
- 
                    string
- Default value:
- 'Verdana, Geneva, sans-serif'
 
- foregroundColorgetset
- Type:
- 
                    string
- Default value:
- '#333333'
 
- hoverOverlayColorgetset
- Color overlayed on top of the hovered label. - Type:
- 
                    string
- Default value:
- 'rgba(170, 170, 170, 0.3)'
 
- openedget
- Returns whether the sidebar is currently opened. - Type:
- 
                    boolean
 
- overlayColorgetset
- Color used to cover the background. This covers also the borders so generally you want to add some level of transparency. - Type:
- 
                    string
- Default value:
- 'transparent'
 
- textSizegetset
- Type:
- 
                    number
- Default value:
- 10
 
- timelineget
- Timeline instance that this instance is bound to. - Type:
- 
                    Timeline
 
- widthgetset
- Pixel width of this sidebar. - Type:
- 
                    number
 
Methods
- constructor(timeline)
- Parameters:
- 
                            - 
                                        TimelinetimelineTimeline instance that this instance is bound to. 
 
- 
                                        
 
- addMutationListener(mutationListener)
- Adds a listener that is notified whenever one of the properties changes. - This method is used by the Timeline instance to detect when to redraw the Canvas. - Parameters:
- 
                                - 
                                            () => voidmutationListener
 
- 
                                            
- Return type:
- void
 
- beforeDraw(g)
- Gets called before any of the draw methods. - Parameters:
- 
                                - 
                                            Graphicsg
 
- 
                                            
- Return type:
- void
 
- close()
- Close the sidebar. - Return type:
- void
 
- createAnimatableProperty(value)
- Creates an animatable property. - Animatable properties apply easing over time between numeric value changes. - Parameters:
- 
                                - 
                                            numbervalue –
 
- 
                                            
- Return type:
- AnimatableProperty
 
- disconnectedCallback()
- Called when this drawable is removed from its Timeline - Return type:
- void
 
- drawContent(g)
- Draw regular content. - Parameters:
- 
                                - 
                                            Graphicsg
 
- 
                                            
- Return type:
- void
 
- drawOverlay(g)
- Gets called after regular content is drawn. Override this if you need a top layer. - Parameters:
- 
                                - 
                                            Graphicsg
 
- 
                                            
- Return type:
- void
 
- drawUnderlay(g)
- Gets called before regular content is drawn. Override this if you need a bottom layer. - Parameters:
- 
                                - 
                                            Graphicsg
 
- 
                                            
- Return type:
- void
 
- open()
- Open the sidebar. - Return type:
- void
 
- removeMutationListener(mutationListener)
- Remove a previously added mutation listener. - Parameters:
- 
                                - 
                                            () => voidmutationListener
 
- 
                                            
- Return type:
- void
 
- reportMutation()
- Mark this Drawable as dirty. This method is intended for use in subclasses and should be called in the implementation of set accessors. - Return type:
- void
 
- toggle()
- Close the sidebar if it is currently opened, else open it. - Return type:
- void