new CurveEdit( [node], context [, params])
UI Helper to enable term structure curve interaction by means of context menu options.
When the cq-time-series
attribute is set to true in the chart markup (see example below),
users can right-click data points on the curve to open a context menu:
If Launch Time Series is then selected, a time series chart for that instrument opens in a new tab.
Parameters:
Name | Type | Argument | Default | Description |
---|---|---|---|---|
node |
HTMLElement |
<optional> |
context.topNode | Automatically attaches to the top node of the context. Not currently used. |
context |
CIQ.UI.Context | The context for the chart. |
||
params |
object |
<optional> |
{pathToTimeSeries:"plugins/termstructure/sample-time-series-instant-chart.html"} | Provides the path to a template used by the launchTimeSeries method to load a time series chart. |
- Since:
-
7.4.0
Example
If a time series chart is available, set the cq-time-series
attribute to
true to enable time series–related options.
<cq-dialog>
<cq-curve-context cq-time-series="true">
<div stxtap="CurveEdit.launchTimeSeries()">Launch Time Series</div>
</cq-curve-context>
</cq-dialog>
Methods
-
<static> launchTimeSeries()
-
Opens a window and loads a time series chart for a selected term structure instrument.
- Since:
-
7.4.0