UNPKG

igniteui-react-charts

Version:

Ignite UI React charting components for building rich data visualizations using TypeScript APIs.

177 lines (175 loc) 5.38 kB
import { IgrSeries } from "./igr-series"; import { fromPoint, toPoint, ensureBool } from "igniteui-react-core"; /** * Represents event arguments for chart's SeriesAdded and SeriesRemoved events * * The `DomainChartSeriesPointerEventArgs` class provide events for chart's SeriesAdded and SeriesRemoved. * * `SeriesPointerDown` get fired when the pointer is press down over a Series. * * ```ts * <IgrFinancialChart * yAxisInterval={200} * yAxisMinorInterval={50} * yAxisMajorStroke="Black" * yAxisMinorStroke="Gray" > * </IgrFinancialChart> * ``` * * ```ts * this.chart.seriesPointerDown = this.chart_seriesPointerDown(); * ``` * * ```ts * <IgrFinancialChart * width="100%" * height="400px" * chartType="Candle" * zoomSliderType="Candle" * volumeType="Column" * indicatorTypes="ForceIndex" * overlayTypes ="PriceChannel" * dataSource={this.data} * seriesPointerDown = {this.onseriesPointerDown} /> * ``` * * ```ts * public void onseriesPointerDown =(s: IgrDomainChart <IIgrDomainChartProps>, e: DomainChartSeriesPointerEventArgs)=> * { * * } * ``` */ var IgrDomainChartSeriesPointerEventArgs = /** @class */ /*@__PURE__*/ (function () { function IgrDomainChartSeriesPointerEventArgs() { this.mounted = false; } Object.defineProperty(IgrDomainChartSeriesPointerEventArgs.prototype, "nativeElement", { get: function () { return this._implementation.nativeElement; }, enumerable: false, configurable: true }); Object.defineProperty(IgrDomainChartSeriesPointerEventArgs.prototype, "i", { /** * @hidden */ get: function () { return this._implementation; }, enumerable: false, configurable: true }); IgrDomainChartSeriesPointerEventArgs.prototype.onImplementationCreated = function () { }; IgrDomainChartSeriesPointerEventArgs.prototype._provideImplementation = function (i) { this._implementation = i; this._implementation.externalObject = this; this.onImplementationCreated(); if (this._initializeAdapters) { this._initializeAdapters(); } }; Object.defineProperty(IgrDomainChartSeriesPointerEventArgs.prototype, "series", { /** * Gets the series hit by the pointer. * * Use the `Series` property to get the series. * * ```ts * var series= args.series; * ``` */ get: function () { var r = this.i.series; if (r == null) { return null; } if (!r.externalObject) { var e = IgrSeries._createFromInternal(r); if (e) { e._implementation = r; } r.externalObject = e; } return r.externalObject; }, set: function (v) { v == null ? this.i.series = null : this.i.series = v.i; }, enumerable: false, configurable: true }); Object.defineProperty(IgrDomainChartSeriesPointerEventArgs.prototype, "item", { /** * Gets the item hit by the pointer. * * Use the `Item` property to get the items. * * <https://www.infragistics.com/help/wpf/infragisticswpf.controls.charts.xamdatachart~infragistics.controls.charts.domainchartseriespointereventargs~item> * * ```ts * var Chartitem = args.item; * ``` */ get: function () { return this.i.item; }, set: function (v) { this.i.item = v; }, enumerable: false, configurable: true }); Object.defineProperty(IgrDomainChartSeriesPointerEventArgs.prototype, "plotAreaPosition", { /** * Gets the pointer position relative to the plot area. */ get: function () { return fromPoint(this.i.plotAreaPosition); }, set: function (v) { this.i.plotAreaPosition = toPoint(v); }, enumerable: false, configurable: true }); Object.defineProperty(IgrDomainChartSeriesPointerEventArgs.prototype, "chartPosition", { /** * Gets the mouse position relative to the chart. */ get: function () { return fromPoint(this.i.chartPosition); }, enumerable: false, configurable: true }); Object.defineProperty(IgrDomainChartSeriesPointerEventArgs.prototype, "worldPosition", { /** */ get: function () { return fromPoint(this.i.worldPosition); }, set: function (v) { this.i.worldPosition = toPoint(v); }, enumerable: false, configurable: true }); Object.defineProperty(IgrDomainChartSeriesPointerEventArgs.prototype, "cancelSelection", { /** * Gets or sets whether to cancel series selection. */ get: function () { return this.i.cancelSelection; }, set: function (v) { this.i.cancelSelection = ensureBool(v); }, enumerable: false, configurable: true }); return IgrDomainChartSeriesPointerEventArgs; }()); export { IgrDomainChartSeriesPointerEventArgs };