CustomChartContext
Index
Constructors
new CustomChartContext(chartContextProps: CustomChartContextProps ) : CustomChartContext
Constructor to only accept context props as payload
Function Parameters
chartContextProps:::
- chartContextProps: CustomChartContextProps
Returns
Defined in : link:https://github.com/thoughtspot/ts-chart-sdk/blob/f477c20/src/main/custom-chart-context.ts#L394
--
Properties
containerEl
containerEl: | HTMLElement # null
Methods
axisMenuCustomActionPreProcessor
axisMenuCustomActionPreProcessor(eventPayload: ) :
Function to store the axis menu custom action callback mapped with action id
Function Parameters
eventPayload:::
- eventPayload:
Event payload bound to the type of the event
Returns
Defined in : link:https://github.com/thoughtspot/ts-chart-sdk/blob/f477c20/src/main/custom-chart-context.ts#L583
--
contextMenuCustomActionPreProcessor
contextMenuCustomActionPreProcessor(eventPayload: ) :
Function to store the context menu custom action callback mapped with action id
Function Parameters
eventPayload:::
- eventPayload:
Event payload bound to the type of the event
Returns
Defined in : link:https://github.com/thoughtspot/ts-chart-sdk/blob/f477c20/src/main/custom-chart-context.ts#L504
--
destroy
destroy() : void
Destroy the chart context object and stop listening to the parent post message events
Returns
void
Defined in : link:https://github.com/thoughtspot/ts-chart-sdk/blob/f477c20/src/main/custom-chart-context.ts#L479
--
emitEvent
emitEvent(eventType: T , eventPayload: ) : Promise< any >
Function to emit Chart to TS Events to the TS application.
Function Parameters
eventType:::
- eventType: T
Type of the event
eventPayload:::
- eventPayload:
Event payload bound to the type of the event
Returns
Promise< any >
Defined in : link:https://github.com/thoughtspot/ts-chart-sdk/blob/f477c20/src/main/custom-chart-context.ts#L664
--
getAppConfig
getAppConfig() : AppConfig
Getter for the chart model object
Returns
Defined in : link:https://github.com/thoughtspot/ts-chart-sdk/blob/f477c20/src/main/custom-chart-context.ts#L496
--
getChartModel
getChartModel() : ChartModel
Getter for the chart model object
Returns
Defined in : link:https://github.com/thoughtspot/ts-chart-sdk/blob/f477c20/src/main/custom-chart-context.ts#L489
--
initialize
initialize() : Promise< void >
Function to expose and wait on the initialize promise object. This will resolve immediately if the chart context is already initialized by TS App.
Returns
Promise< void >
Defined in : link:https://github.com/thoughtspot/ts-chart-sdk/blob/f477c20/src/main/custom-chart-context.ts#L415
--
off
off(eventType: T ) : void
Removes specific event listeners on the chart context.
Function Parameters
eventType:::
- eventType: T
Returns
void
Defined in : link:https://github.com/thoughtspot/ts-chart-sdk/blob/f477c20/src/main/custom-chart-context.ts#L446
--
on
on(eventType: T , callbackFn: ) : void
Add event listeners on the chart context with the required callback.
Function Parameters
eventType:::
- eventType: T
callbackFn:::
- callbackFn:
Returns
void
Defined in : link:https://github.com/thoughtspot/ts-chart-sdk/blob/f477c20/src/main/custom-chart-context.ts#L428
--