TimelineHistogramBase

Base class for TimelineHistogram class.

Configs

213

Common

columnsGridBase
dataGridBase
emptyTextGridBase
endDateTimelineBase
featuresGridBase
keyMapGridBase
listenersEvents
maxDateTimelineBase
minDateTimelineBase
presetsTimelineViewPresets
rowHeightGridBase
startDateTimelineBase
storeGridBase
viewPresetTimelineViewPresets
visibleDateTimelineBase

Other

A Function which returns the tooltip text to display when hovering a bar. The following parameters are passed:

ParameterTypeDescription
contextObject

The tooltip context info

context.datumObject

The histogram bar being hovered info

context.tipTooltip

The tooltip instance

context.elementHTMLElement

The Element for which the Tooltip is monitoring mouse movement

context.activeTargetHTMLElement

The target element that triggered the show

context.eventEvent

The raw DOM event

context.recordModel

The record which value the hovered bar displays.

Returns: String -

Tooltip HTML content

dataModelField: String= histogramData

Record field from which the histogram data will be collected.

histogram = new TimelineHistogram({
    ...
    series : {
        s1 : {
            type : 'bar'
        }
    },
    dataModelField : 'foo',
    store : new Store({
        data : [
            {
                id   : 'r1',
                name : 'Record 1',
                foo  : [
                    { s1 : 200 },
                    { s1 : 150 },
                    { s1 : 175 },
                    { s1 : 175 }
                ]
            },
            {
                id   : 'r2',
                name : 'Record 2',
                foo  : [
                    { s1 : 100 },
                    { s1 : 150 },
                    { s1 : 175 },
                    { s1 : 175 }
                ]
            }
        ]
    })
});

Alternatively getRecordData function can be used to build a record's histogram data dynamically.

getBarClass: function

A Function which returns a CSS class name to add to a rectangle element. The following parameters are passed:

ParameterTypeDescription
seriesHistogramSeries

The series being rendered

domConfigDomConfig

The rectangle configuration object

datumObject

The datum being rendered

indexNumber

The index of the datum being rendered

renderDataHistogramRenderData

Current render data giving access to the record, row and cell being rendered.

Returns: String -

CSS classes of the rectangle element

getBarDOMConfig: function

A Function which if provided should return a DOM configuration object for a bar (a RECT element representing a single "bar"-type value). The function is passed a default prepared DOM configuration in an argument which then can be processed and returned.

new TimelineHistogram({
    series : {
        foo : {
            type  : 'bar',
            field : 'foo'
        }
    },
    // Let's add left & right margins to bars
    getBarDOMConfig(series, domConfig) {
        // margin size is 10% of the bar width
        const xMargin = 0.1 * domConfig.width;

        // adjust the bar x-coordinate
        domConfig.x += xMargin;
        // reduce the bar width respectively
        domConfig.width -= 2 * xMargin;

        // return the edited domConfig
        return domConfig;
    },
    ...
})

Please note that it's important to return a DOM configuration object. If the function doesn't do that the corresponding bar won't be displayed.

The function will be injected into the underlying Histogram component that is used under the hood to render charts. So this will refer to the Histogram instance, not this class instance. To access the view please use this.owner in the function:

new TimelineHistogram({
    getBarText(datum) {
        // "this" in the method refers core Histogram instance
        // get the view instance
        const timelineHistogram = this.owner;

        .....
    },
    ...
})

The following parameters are passed:

ParameterTypeDescription
seriesHistogramSeries

The series being rendered

domConfigDomConfig

The rectangle DOM configuration object

datumObject

The datum being rendered

indexNumber

The index of the datum being rendered

renderDataHistogramRenderData

Current render data giving access to the record, row and cell being rendered.

Returns: Object -

Resulting DOM configuration object. If no value returned the bar is not displayed.

getBarText: function

A Function which returns the text to render inside a bar.

new TimelineHistogram({
    series : {
        foo : {
            type  : 'bar',
            field : 'foo'
        }
    },
    getBarText(datum) {
        // display the value in the bar
        return datum.foo;
    },
    ...
})

Please note that the function will be injected into the underlying Histogram component that is used under the hood to render actual charts. So this will refer to the Histogram instance, not this class instance. To access the view please use this.owner in the function:

new TimelineHistogram({
    getBarText(datum) {
        // "this" in the method refers core Histogram instance
        // get the view instance
        const timelineHistogram = this.owner;

        .....
    },
    ...
})

The following parameters are passed:

ParameterTypeDescription
datumObject

The datum being rendered

indexNumber

The index of the datum being rendered

seriesHistogramSeries

The series (provided if histogram widget singleTextForAllBars is false)

renderDataHistogramRenderData

Current render data giving access to the record, row and cell being rendered.

Returns: String -

Text to render inside the bar

A Function which returns a DOM configuration object for text elements.

new TimelineHistogram({
    series : {
        foo : {
            type  : 'bar',
            field : 'foo'
        }
    },
    // display "foo" bar value as text
    getBarText(datum) {
        return datum.foo;
    },

    // Place text at the top of the "foo" bar
    getBarTextDOMConfig(domConfig, datum, index) {
        // to do that we calculate y-position in percents
        domConfig.y = `${100 * (1 - datum.foo / this.topValue)}%`;

        return domConfig;
    },
    ...
})

Please note that it's important to return a DOM configuration object. If the function doesn't do that the corresponding text element won't be displayed.

The function will be injected into the underlying Histogram component that is used under the hood to render actual charts. So this will refer to the Histogram instance, not this class instance. To access the view please use this.owner in the function:

new TimelineHistogram({
    getBarTextDOMConfig(domConfig) {
        // "this" in the method refers core Histogram instance
        // get the view instance
        const timelineHistogram = this.owner;

        .....

        return domConfig;
    },
    ...
})

The following parameters are passed:

ParameterTypeDescription
domConfigDomConfig

The TEXT element DOM configuration object

datumObject

The datum being rendered

indexNumber

The index of the datum being rendered

seriesHistogramSeries

The series (provided if histogram widget singleTextForAllBars is false)

renderDataHistogramRenderData

Current render data giving access to the record, row and cell being rendered.

Returns: Object -

The TEXT element DOM configuration object. If no value returned the text element is not displayed.

getOutlineClass: function

A Function which returns a CSS class name to add to a path element built for an outline type series. The following parameters are passed:

ParameterTypeDescription
seriesHistogramSeries

The series being rendered

dataObject[]

The series data

renderDataHistogramRenderData

Current render data giving access to the record, row and cell being rendered.

Returns: String -

CSS class name of the path element

A Function which if provided should return a DOM configuration object for a path element built for an outline type series. The function accepts a default prepared DOM configuration in an argument which then can be processed and returned.

The following parameters are passed to the function:

ParameterTypeDescription
seriesHistogramSeries

The series being rendered

domConfigDomConfig

The path element DOM configuration object

dataObject[]

The series data

Returns: Object -

Resulting DOM configuration object. If no value returned the path is not displayed.

getRecordData: function | String

A function, or name of a function which builds histogram data for the provided record.

See also dataModelField allowing to load histogram data from a record field.

ParameterTypeDescription
getRecordData.recordModel

Record to get histogram data for.

aggregationContextObject

Context object passed in case the data is being retrieved as a part of some parent record data collecting.

Returns: Object -

Histogram data.

When set to true (default) the component reacts on time axis changes (zooming or changing the displayed time span), clears the histogram data cache of the records and then refreshes the view.

An instance or a configuration object of the underlying Histogram component that is used under the hood to render actual charts. In case a configuration object is provided the built class is defined with histogramWidgetClass config.

The class used for building the histogram widget

series: Object<String, HistogramSeries>

Object enumerating data series for the histogram. The object keys are treated as the series identifiers and values are objects that must contain two properties:

  • type A String, either 'bar' or 'outline'
  • field A String, the name of the property to use from the data objects in the data option.
histogram = new TimelineHistogram({
    ...
    series : {
        s1 : {
            type  : 'bar',
            field : 's1'
        },
        s2 : {
            type  : 'outline',
            field : 's2'
        }
    },
    store : new Store({
        data : [
            {
                id            : 'r1',
                name          : 'Record 1',
                histogramData : [
                    { s1 : 200, s2 : 100 },
                    { s1 : 150, s2 : 50 },
                    { s1 : 175, s2 : 50 },
                    { s1 : 175, s2 : 75 }
                ]
            },
            {
                id            : 'r2',
                name          : 'Record 2',
                histogramData : [
                    { s1 : 100, s2 : 100 },
                    { s1 : 150, s2 : 125 },
                    { s1 : 175, s2 : 150 },
                    { s1 : 175, s2 : 75 }
                ]
            }
        ]
    })
});

Set to true if you want to display a tooltip when hovering an allocation bar. You can also pass a Tooltip#configs config object. Please use barTooltipTemplate function to customize the tooltip contents.

Set to true to display the bar tooltip when navigating the timeaxis cells using ScheduleContext feature. The tooltip is disabled by default when navigating to make the navigation easier.

columnWidget
defaultFocusContainer
drawerPanel
labelPositionContainer
renditionContainer
rtlRTL
spanWidget
stateSettingsGridState
transitionGridBase

Accessibility

ariaLabelWidget

Content

bbarPanel
defaultsContainer
footerPanel
headerPanel
itemsContainer
lazyItemsContainer
namedItemsContainer
stripsPanel
tbarPanel
textContentContainer
toolsPanel

CSS

bodyClsPanel
borderContainer
clsWidget
colorWidget
htmlClsWidget
itemClsContainer
styleWidget
uiPanel

Dates

timeResolutionTimelineDateMapper

DOM

adoptWidget
appendToWidget
contentWidget
datasetWidget
htmlWidget
idWidget
tagWidget

Float & align

alignWidget
anchorWidget
centeredWidget
draggableWidget
floatingWidget
xWidget
yWidget

Infinite scroll

bufferCoefTimelineScroll
bufferThresholdTimelineScroll
infiniteScrollTimelineScroll

Layout

alignSelfWidget
autoHeightGridBase
dockWidget
flexWidget
getRowHeightGridBase
heightWidget
hiddenWidget
hideWhenEmptyContainer
layoutContainer
layoutStyleContainer
marginWidget
maxHeightWidget
maxWidthWidget
minHeightGridBase
minWidthWidget
textAlignWidget
weightWidget
widthWidget

Masking

loadMaskLoadMaskable
loadMaskDefaultsLoadMaskable
loadMaskErrorLoadMaskable
syncMaskLoadMaskable

misc

tabBarItemsContainer

Misc

cellEllipsisGridBase
columnLinesGridBase
dataFieldWidget
defaultRegionTimelineBase
destroyStoreGridBase
disabledWidget
enableStickyGridBase
enableUndoRedoKeysGridElementEvents
hideFootersGridBase
hideHeadersGridBase
hideRowHoverTimelineBase
hoverClsGridElementEvents
iconPanel
localeClassLocalizable
localizableLocalizable
longPressTimeGridElementEvents
maskDefaultsGridBase
maskedWidget
ownerWidget
pluginsPluggable
readOnlyGridBase
refWidget
responsiveLevelsGridResponsive
rippleWidget
rowLinesGridBase
showDirtyGridBase
tabWidget
timeZoneTimelineBase
titlePanel
tooltipWidget

Record

recordContainer

Scheduled events

barMarginTimelineEventRendering
displayDateFormatTimelineViewPresets
enableRecurringEventsRecurringEvents
eventColorTimelineEventRendering
eventStyleTimelineEventRendering
fillTicksTimelineEventRendering
managedEventSizingTimelineEventRendering
snapTimelineDateMapper
tickSizeTimelineEventRendering

Scrolling

scrollableGridBase

Selection

selectionModeGridSelection

State

stateIdState

Time axis

autoAdjustTimeAxisTimelineBase
forceFitTimelineBase
partnerTimelineBase
stickyHeadersTimelineBase
suppressFitTimelineBase
timeAxisTimelineBase
weekStartDayTimelineBase
workingTimeTimelineBase

Tree

Zoom

maxZoomLevelTimelineZoomable
minZoomLevelTimelineZoomable
visibleZoomFactorTimelineZoomable
zoomOnMouseWheelTimelineZoomable

Properties

192

Common

columnsGridBase
dataGridBase
emptyTextGridBase
endDateTimelineBase
featuresGridFeatures
maxDateTimelineBase
minDateTimelineBase
presetsTimelineViewPresets
rowHeightGridBase
startDateTimelineBase
storeGridBase
subGridsGridSubGrids
viewPresetTimelineViewPresets
visibleDateTimelineBase

Class hierarchy

isTimelineHistogramBase: Boolean= truereadonly
Identifies an object as an instance of TimelineHistogramBase class, or subclass thereof.
isTimelineHistogramBase: Boolean= truereadonlystatic
Identifies an object as an instance of TimelineHistogramBase class, or subclass thereof.
isContainerContainer
isDelayableDelayable
isEventsEvents
isGridGrid
isGridBaseGridBase
isGridElementEventsGridElementEvents
isGridFeaturesGridFeatures
isGridResponsiveGridResponsive
isGridSelectionGridSelection
isGridStateGridState
isGridSubGridsGridSubGrids
isKeyMapKeyMap
isLoadMaskableLoadMaskable
isLocalizableLocalizable
isPanelPanel
isPluggablePluggable
isRecurringEventsRecurringEvents
isStateState
isTimelineBaseTimelineBase
isTimelineDateMapperTimelineDateMapper
isTimelineDomEventsTimelineDomEvents
isTimelineEventRenderingTimelineEventRendering
isTimelineScrollTimelineScroll
isTimelineStateTimelineState
isTimelineViewPresetsTimelineViewPresets
isTimelineZoomableTimelineZoomable
isToolableToolable
isWidgetWidget

Other

The underlying Histogram component that is used under the hood to render actual charts.

Set to true if you want to display a tooltip when hovering an allocation bar. You can also pass a Tooltip#configs config object. Please use barTooltipTemplate function to customize the tooltip contents.

$namestaticWidget
columnWidget
firstItemContainer
hasChangesContainer
isValidContainer
itemsContainer
labelPositionContainer
lastItemContainer
renditionContainer
rtlRTL
spanWidget
stateSettingsGridState
toolsPanel
transitionGridBase
typestaticWidget
valuesContainer

Accessibility

keyMapKeyMap

Content

bbarPanel
tbarPanel

CSS

clsWidget

Dates

timelineContextTimelineDomEvents
timeResolutionTimelineDateMapper
viewportCenterDateTimelineDateMapper
visibleDateRangeTimelineBase

DOM

appendToWidget
contentWidget
datasetWidget
elementWidget
htmlWidget
idWidget
styleWidget

Float & align

xWidget
yWidget

Infinite scroll

infiniteScrollTimelineScroll

Layout

alignSelfWidget
bodyHeightGridBase
flexWidget
footerHeightGridBase
headerHeightGridBase
heightWidget
layoutContainer
layoutStyleContainer
marginWidget
maxHeightWidget
maxWidthWidget
minHeightWidget
minWidthWidget
widthWidget

Lifecycle

configBase

Misc

cellEllipsisGridBase
cellInfoWidget
columnLinesGridBase
disabledWidget
enableUndoRedoKeysGridElementEvents
hideFootersGridBase
hideHeadersGridBase
hideRowHoverTimelineBase
hoveredCellGridElementEvents
localeHelperLocalizable
localeManagerLocalizable
longPressTimeGridElementEvents
pluginsPluggable
readOnlyGridBase
refWidget
responsiveLevelGridResponsive
rowLinesGridBase
tabWidget
timeZoneTimelineBase
titlePanel
tooltipWidget

Record

recordContainer

Rows

Scheduled events

barMarginTimelineEventRendering
displayDateFormatTimelineViewPresets
eventColorTimelineEventRendering
eventColorsstaticTimelineEventRendering
eventStyleTimelineEventRendering
eventStylesstaticTimelineEventRendering
fillTicksTimelineEventRendering
hasVisibleEventsTimelineBase
snapTimelineDateMapper
tickSizeTimelineEventRendering

Scrolling

scrollLeftTimelineScroll
scrollTopTimelineScroll
scrollXTimelineScroll
timelineScrollerTimelineScroll

Selection

selectedCellGridSelection
selectedCellsGridSelection
selectedRecordGridSelection
selectedRecordsGridSelection
selectedRowsGridSelection
selectionModeGridSelection

State

stateGridState

Time axis

forceFitTimelineBase
partnersTimelineBase
suppressFitTimelineBase
timeAxisTimelineBase
timeAxisColumnTimelineBase
timeAxisSubGridTimelineBase
timeAxisViewModelTimelineBase
workingTimeTimelineBase

Tree

Visibility

hiddenWidget
isVisibleWidget

Widget hierarchy

ownerWidget
parentWidget
widgetMapContainer

Zoom

maxZoomLevelTimelineZoomable
minZoomLevelTimelineZoomable
zoomLevelTimelineZoomable

Functions

166

Other

Clears the histogram data cache for the provided record (if provided). If the record is not provided clears the cache for all records.

ParameterTypeDescription
recordModel

Record to clear the cache for.

Returns entire histogram data cache if no record provided, or cached data for the provided record.

ParameterTypeDescription
recordModel

Record to get the cached data for.

Returns: Object -

The provided record cached data or all the records data cache as a Map keyed by records.

Retrieves the histogram data for the provided record.

The method first checks if there is cached data for the record and returns it if found. Otherwise it starts collecting data by calling getRecordData (if provided) or by reading it from dataModelField record field.

The method can be asynchronous depending on the provided getRecordData function. If the function returns a Promise then the method will return a wrapping Promise in turn that will resolve with the collected histogram data.

The method triggers histogramDataCacheSet event when a record data is ready.

ParameterTypeDescription
recordModel

Record to retrieve the histogram data for.

Returns: Object | Promise -

The histogram data for the provided record or a Promise that will provide the data when resolved.

Returns true if there is cached histogram data for the provided record.

ParameterTypeDescription
recordModel

Record to check the cache existence for.

Returns: Boolean -

True if there is a cache for provided record.

Schedules the component rows refresh on the next animation frame. However many time it is called in one event run, it will only be scheduled to run once.

Caches the provided histogram data for the given record.

ParameterTypeDescription
recordModel

Record to cache data for.

dataObject

Histogram data to cache.

addContainer
addPartnerTimelineBase
composeWidget
createOnFrameDelayable
disableWidget
enableWidget
focusWidget
formatDurationTimelineBase
getAtContainer
getWidgetByIdContainer
insertContainer
isPartneredWithTimelineBase
LstaticLocalizable
maskWidget
onEvents
preserveViewCenterTimelineBase
recomposeWidget
relayAllEvents
removeContainer
removeAllContainer
removePartnerTimelineBase
resetValuesContainer
setEndDateTimelineBase
setStartDateTimelineBase
setTimeSpanTimelineBase
setValuesContainer
shiftTimelineZoomable
shiftNextTimelineZoomable
shiftPreviousTimelineZoomable
triggerEvents
unEvents
unmaskWidget
zoomToFitTimelineZoomable

Configuration

applyDefaultsstaticBase

Data

getOccurrencesForRecurringEvents

Dates

getCoordinateFromDateTimelineDateMapper
getDateFromCoordinateTimelineDateMapper
getDateFromDomEventTimelineDateMapper
getDateFromXYTimelineDateMapper
getTimeSpanDistanceTimelineDateMapper

Events

Float & align

alignToWidget
setXYWidget
showByWidget
toFrontWidget

Getters

getCellGridBase

Lifecycle

createstaticWidget
destroystaticBase
initClassstaticWidget

Misc

addPluginsPluggable
attachTooltipstaticWidget
fromElementstaticWidget
fromSelectorstaticWidget
getByIdstaticWidget
getPluginPluggable
hasFeatureGridFeatures
hasPluginPluggable
highlightEventsTimelineBase
isOfTypeNamestaticBase
maskBodyGridBase
mixinstaticBase
optionalLstaticLocalizable
unhighlightEventsTimelineBase
unmaskBodyGridBase

Rendering

refreshRowGridBase
refreshRowsGridBase
renderRowsGridBase

Rows

getRowForGridBase

Scrolling

scrollHorizontallyToTimelineScroll
scrollToTimelineScroll
scrollToDateTimelineScroll
scrollToNowTimelineScroll
scrollToTopGridBase
scrollVerticallyToTimelineScroll
storeScrollGridBase

Selection

deselectAllGridSelection
deselectCellGridSelection
deselectCellsGridSelection
deselectRowGridSelection
deselectRowsGridSelection
isCellSelectedGridSelection
isSelectableGridSelection
isSelectedGridSelection
selectAllGridSelection
selectCellGridSelection
selectCellRangeGridSelection
selectCellsGridSelection
selectRangeGridSelection
selectRowGridSelection
selectRowsGridSelection

State

SubGrid

getSubGridGridSubGrids

Visibility

hideWidget
showWidget

Widget hierarchy

closestWidget
containsWidget
ownsWidget
queryWidget
queryAllWidget
upWidget

Zoom

zoomInTimelineZoomable
zoomInFullTimelineZoomable
zoomOutTimelineZoomable
zoomOutFullTimelineZoomable
zoomToTimelineZoomable
zoomToLevelTimelineZoomable
zoomToSpanTimelineZoomable

Events

64

Fires before the component stores a record's histogram data into the cache.

A listener can be used to transform the collected data dynamically before it's cached:

new TimelineHistogram({
    series : {
        foo : {
            type  : 'bar',
            field : 'f1'
        }
    },
    ...
    listeners : {
        beforeHistogramDataCacheSet(eventData) {
            // completely replace the data for a specific record
            if (eventData.record.id === 123) {
                eventData.data = [
                    { f1 : 10 },
                    { f1 : 20 },
                    { f1 : 30 },
                    { f1 : 40 },
                    { f1 : 50 },
                    { f1 : 60 }
                ];
            }
        }
    }
})
// Adding a listener using the "on" method
timelineHistogramBase.on('beforeHistogramDataCacheSet', ({ source, record, data }) => {

});
ParameterTypeDescription
sourceTimelineHistogram

The component instance

recordModel

Record the histogram data of which is ready.

dataObject

The record histogram data.

Fires before the component renders a row.

This event is recommended to use instead of generic beforeRenderRow event since the component bails out of rendering rows for which histogram data is not ready yet (happens in case of async data collecting). The generic beforeRenderRow is triggered in such cases too while this event is triggered only when the data is ready and the row is actually about to be rendered.

Use a listener to adjust histograms rendering dynamically for individual rows:

new TimelineHistogram({
    ...
    listeners : {
        beforeRenderHistogramRow({ record, histogramConfig }) {
            // display an extra line for some specific record
            if (record.id == 111) {
                histogramConfig.series.extraLine = {
                    type  : 'outline',
                    field : 'foo'
                };
            }
        }
    }
})
// Adding a listener using the "on" method
timelineHistogramBase.on('beforeRenderHistogramRow', ({ source, record, histogramConfig, histogramWidget }) => {

});
ParameterTypeDescription
sourceTimelineHistogram

The component instance

recordModel

Record the histogram data of which is ready.

histogramConfigHistogramConfig

Configuration object that will be applied to histogramWidget.

histogramWidgetHistogram

The underlying widget that is used to render a chart.

Fires before the component renders a histogram in a cell.

// Adding a listener using the "on" method
timelineHistogramBase.on('beforeRenderRecordHistogram', ({ source, record, histogramConfig, histogramWidget }) => {

});
ParameterTypeDescription
sourceTimelineHistogram

The component instance

recordModel

Record the histogram data of which is ready.

histogramConfigHistogramConfig

Configuration object that will be applied to histogramWidget.

histogramWidgetHistogram

The underlying widget that is used to render a chart.

Fires after the component retrieves a record's histogram data and stores it into the cache.

Unlike similar beforeHistogramDataCacheSet event this event is triggered after the data is put into the cache.

A listener can be used to transform the collected data dynamically:

new TimelineHistogram({
    series : {
        bar : {
            type : 'bar',
            field : 'bar'
        },
        halfOfBar : {
            type  : 'outline',
            field : 'half'
        }
    },
    ...
    listeners : {
        histogramDataCacheSet({ data }) {
            // add extra entries to collected data
            data.forEach(entry => {
                entry.half = entry.bar / 2;
            });
        }
    }
})
// Adding a listener using the "on" method
timelineHistogramBase.on('histogramDataCacheSet', ({ source, record, data }) => {

});
ParameterTypeDescription
sourceTimelineHistogram

The component instance

recordModel

Record the histogram data of which is ready.

dataObject

The record histogram data.

beforeAssignmentDeleteRecurringEvents
beforeEventDeleteRecurringEvents
beforePresetChangeTimelineViewPresets
catchAllEvents
cellClickGridElementEvents
cellContextMenuGridElementEvents
cellDblClickGridElementEvents
cellMouseEnterGridElementEvents
cellMouseLeaveGridElementEvents
cellMouseOutGridElementEvents
cellMouseOverGridElementEvents
dataChangeGridBase
dateRangeChangeTimelineBase
destroyEvents
dragSelectingGridSelection
expandPanel
focusInWidget
focusOutWidget
headerClickGridElementEvents
hideWidget
mouseOutGridElementEvents
mouseOverGridElementEvents
noZoomChangeTimelineZoomable
paintWidget
presetChangeTimelineViewPresets
readOnlyWidget
recomposeWidget
renderRowGridBase
renderRowsGridBase
resizeWidget
responsiveGridResponsive
rowMouseEnterGridElementEvents
rowMouseLeaveGridElementEvents
scrollGridBase
selectionChangeGridSelection
selectionModeChangeGridSelection
showWidget
tickSizeChangeTimelineEventRendering
timeAxisChangeTimelineBase
timeAxisHeaderClickTimelineDomEvents
timeAxisHeaderContextMenuTimelineDomEvents
timeAxisHeaderDblClickTimelineDomEvents
timelineContextChangeTimelineDomEvents

Event handlers

64

Called before the component stores a record's histogram data into the cache.

A listener can be used to transform the collected data dynamically before it's cached:

new TimelineHistogram({
    series : {
        foo : {
            type  : 'bar',
            field : 'f1'
        }
    },
    ...
    listeners : {
        beforeHistogramDataCacheSet(eventData) {
            // completely replace the data for a specific record
            if (eventData.record.id === 123) {
                eventData.data = [
                    { f1 : 10 },
                    { f1 : 20 },
                    { f1 : 30 },
                    { f1 : 40 },
                    { f1 : 50 },
                    { f1 : 60 }
                ];
            }
        }
    }
})
new TimelineHistogramBase({
    onBeforeHistogramDataCacheSet({ source, record, data }) {

    }
});
ParameterTypeDescription
sourceTimelineHistogram

The component instance

recordModel

Record the histogram data of which is ready.

dataObject

The record histogram data.

Called before the component renders a row.

This event is recommended to use instead of generic beforeRenderRow event since the component bails out of rendering rows for which histogram data is not ready yet (happens in case of async data collecting). The generic beforeRenderRow is called in such cases too while this event is called only when the data is ready and the row is actually about to be rendered.

Use a listener to adjust histograms rendering dynamically for individual rows:

new TimelineHistogram({
    ...
    listeners : {
        beforeRenderHistogramRow({ record, histogramConfig }) {
            // display an extra line for some specific record
            if (record.id == 111) {
                histogramConfig.series.extraLine = {
                    type  : 'outline',
                    field : 'foo'
                };
            }
        }
    }
})
new TimelineHistogramBase({
    onBeforeRenderHistogramRow({ source, record, histogramConfig, histogramWidget }) {

    }
});
ParameterTypeDescription
sourceTimelineHistogram

The component instance

recordModel

Record the histogram data of which is ready.

histogramConfigHistogramConfig

Configuration object that will be applied to histogramWidget.

histogramWidgetHistogram

The underlying widget that is used to render a chart.

Called before the component renders a histogram in a cell.

new TimelineHistogramBase({
    onBeforeRenderRecordHistogram({ source, record, histogramConfig, histogramWidget }) {

    }
});
ParameterTypeDescription
sourceTimelineHistogram

The component instance

recordModel

Record the histogram data of which is ready.

histogramConfigHistogramConfig

Configuration object that will be applied to histogramWidget.

histogramWidgetHistogram

The underlying widget that is used to render a chart.

Called after the component retrieves a record's histogram data and stores it into the cache.

Unlike similar beforeHistogramDataCacheSet event this event is called after the data is put into the cache.

A listener can be used to transform the collected data dynamically:

new TimelineHistogram({
    series : {
        bar : {
            type : 'bar',
            field : 'bar'
        },
        halfOfBar : {
            type  : 'outline',
            field : 'half'
        }
    },
    ...
    listeners : {
        histogramDataCacheSet({ data }) {
            // add extra entries to collected data
            data.forEach(entry => {
                entry.half = entry.bar / 2;
            });
        }
    }
})
new TimelineHistogramBase({
    onHistogramDataCacheSet({ source, record, data }) {

    }
});
ParameterTypeDescription
sourceTimelineHistogram

The component instance

recordModel

Record the histogram data of which is ready.

dataObject

The record histogram data.

onBeforeEventDeleteRecurringEvents
onBeforePresetChangeTimelineViewPresets
onCellClickGridElementEvents
onCellContextMenuGridElementEvents
onCellDblClickGridElementEvents
onCellMouseEnterGridElementEvents
onCellMouseLeaveGridElementEvents
onCellMouseOutGridElementEvents
onCellMouseOverGridElementEvents
onDataChangeGridBase
onDateRangeChangeTimelineBase
onDestroyEvents
onDragSelectingGridSelection
onFocusInWidget
onHeaderClickGridElementEvents
onHideWidget
onMouseOutGridElementEvents
onMouseOverGridElementEvents
onNoZoomChangeTimelineZoomable
onPaintWidget
onPresetChangeTimelineViewPresets
onRenderRowGridBase
onRenderRowsGridBase
onResizeWidget
onResponsiveGridResponsive
onRowMouseEnterGridElementEvents
onRowMouseLeaveGridElementEvents
onScrollGridBase
onSelectionChangeGridSelection
onShowWidget
onTickSizeChangeTimelineEventRendering
onTimeAxisChangeTimelineBase
onTimeAxisHeaderClickTimelineDomEvents
onTimeAxisHeaderDblClickTimelineDomEvents
onTimelineContextChangeTimelineDomEvents

Typedefs

19

Histogram renderer parameters.

ParameterTypeDescription
histogramDataObject

Histogram data

histogramConfigHistogramConfig

Configuration object for the histogram widget

cellElementHTMLElement | null

Cell element, for adding CSS classes, styling etc. Can be null in case of export

recordModel

Record for the row

columnTimeAxisColumn

Owning TimeAxisColumn column

gridTimelineHistogramBase

Owning TimelineHistogramBase instance

rowRow

Row object. Can be null in case of export. Use the row's API to manipulate CSS class names.

AlignSpecWidget
ChangePresetOptionsTimelineZoomable
ColorWidget
ColumnStateGridState
GridSelectionModeGridSelection
GridStateInfoGridState
ResponsiveLevelConfigGridResponsive
SubGridStateGridState
TimelineStateInfoTimelineState
VisibleDateTimelineBase

CSS variables

84