igniteui-angular-charts
Version:
Ignite UI Angular charting components for building rich data visualizations for modern web apps.
130 lines (129 loc) • 6.4 kB
JavaScript
import { __extends } from "tslib";
import { Component, forwardRef, Input, ChangeDetectionStrategy } from '@angular/core';
import { IgxStrategyBasedIndicatorComponent } from "./igx-strategy-based-indicator-component";
import { IgxFinancialIndicatorComponent } from "./igx-financial-indicator-component";
import { IgxFinancialSeriesComponent } from "./igx-financial-series-component";
import { IgxSeriesComponent } from "./igx-series-component";
import { RateOfChangeAndMomentumIndicator } from "./RateOfChangeAndMomentumIndicator";
import * as i0 from "@angular/core";
/**
* Represents a IgxDataChartComponent Rate of Change and Momentum indicator series.
* Default required members: Close
*
* `RateOfChangeAndMomentumIndicator` class represents a Rate of Change and Momentum indicator series for the IgxDataChartComponent.
*
* ```html
* <igx-data-chart #chart
* [dataSource]="data">
* <igx-category-x-axis
* label="label"
* #xAxis
* >
* </igx-category-x-axis>
* <igx-numeric-y-axis
* minimumValue="0"
* #yAxis>
* </igx-numeric-y-axis>
* <igx-rate-of-change-and-momentum-indicator
* [xAxis]="xAxis"
* [yAxis]="yAxis"
* openMemberPath="open"
* highMemberPath="high"
* lowMemberPath="low"
* closeMemberPath="close"
* >
* </igx-rate-of-change-and-momentum-indicator>
* </igx-data-chart>
* ```
*
* ```ts
* let series = new IgxRateOfChangeAndMomentumIndicatorComponent();
* series.xAxis = this.xAxis;
* series.yAxis = this.yAxis;
* series.openMemberPath = "open";
* series.highMemberPath = "high";
* series.lowMemberPath = "low";
* series.closeMemberPath = "close";
* this.chart.series.add(series);
* ```
*/
var IgxRateOfChangeAndMomentumIndicatorComponent = /** @class */ /*@__PURE__*/ (function (_super) {
__extends(IgxRateOfChangeAndMomentumIndicatorComponent, _super);
function IgxRateOfChangeAndMomentumIndicatorComponent() {
return _super.call(this) || this;
}
IgxRateOfChangeAndMomentumIndicatorComponent.prototype.createImplementation = function () {
return new RateOfChangeAndMomentumIndicator();
};
Object.defineProperty(IgxRateOfChangeAndMomentumIndicatorComponent.prototype, "i", {
/**
* @hidden
*/
get: function () {
return this._implementation;
},
enumerable: false,
configurable: true
});
Object.defineProperty(IgxRateOfChangeAndMomentumIndicatorComponent.prototype, "period", {
/**
* Gets or sets the moving average period for the current AverageTrueRangeSeries object.
* The typical, and initial, value for AverageTrueRange periods is 14.
*
* You can use the `period` property for the current AverageTrueRangeSeries object.
*
* The typical, and initial, value for AverageTrueRange periods is 14.
*
* ```html
* <igx-data-chart #chart
* [dataSource]="data">
* <igx-category-x-axis
* label="label"
* #xAxis
* >
* </igx-category-x-axis>
* <igx-numeric-y-axis
* minimumValue="0"
* #yAxis>
* </igx-numeric-y-axis>
* <igx-rate-of-change-and-momentum-indicator
* [xAxis]="xAxis"
* [yAxis]="yAxis"
* openMemberPath="open"
* highMemberPath="high"
* lowMemberPath="low"
* closeMemberPath="close"
* period="30">
* </igx-rate-of-change-and-momentum-indicator>
* </igx-data-chart>
* ```
*
* ```ts
* this.series.period = 30;
* ```
*/
get: function () {
return this.i.acf;
},
set: function (v) {
this.i.acf = +v;
},
enumerable: false,
configurable: true
});
IgxRateOfChangeAndMomentumIndicatorComponent.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "12.2.17", ngImport: i0, type: IgxRateOfChangeAndMomentumIndicatorComponent, deps: [], target: i0.ɵɵFactoryTarget.Component });
IgxRateOfChangeAndMomentumIndicatorComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "12.0.0", version: "12.2.17", type: IgxRateOfChangeAndMomentumIndicatorComponent, selector: "igx-rate-of-change-and-momentum-indicator", inputs: { period: "period" }, providers: [{ provide: IgxStrategyBasedIndicatorComponent, useExisting: forwardRef(function () { return IgxRateOfChangeAndMomentumIndicatorComponent; }) }, { provide: IgxFinancialIndicatorComponent, useExisting: forwardRef(function () { return IgxRateOfChangeAndMomentumIndicatorComponent; }) }, { provide: IgxFinancialSeriesComponent, useExisting: forwardRef(function () { return IgxRateOfChangeAndMomentumIndicatorComponent; }) }, { provide: IgxSeriesComponent, useExisting: forwardRef(function () { return IgxRateOfChangeAndMomentumIndicatorComponent; }) }], usesInheritance: true, ngImport: i0, template: "", isInline: true, changeDetection: i0.ChangeDetectionStrategy.OnPush });
return IgxRateOfChangeAndMomentumIndicatorComponent;
}(IgxStrategyBasedIndicatorComponent));
export { IgxRateOfChangeAndMomentumIndicatorComponent };
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "12.2.17", ngImport: i0, type: IgxRateOfChangeAndMomentumIndicatorComponent, decorators: [{
type: Component,
args: [{
selector: 'igx-rate-of-change-and-momentum-indicator',
template: "",
providers: [{ provide: IgxStrategyBasedIndicatorComponent, useExisting: forwardRef(function () { return IgxRateOfChangeAndMomentumIndicatorComponent; }) }, { provide: IgxFinancialIndicatorComponent, useExisting: forwardRef(function () { return IgxRateOfChangeAndMomentumIndicatorComponent; }) }, { provide: IgxFinancialSeriesComponent, useExisting: forwardRef(function () { return IgxRateOfChangeAndMomentumIndicatorComponent; }) }, { provide: IgxSeriesComponent, useExisting: forwardRef(function () { return IgxRateOfChangeAndMomentumIndicatorComponent; }) }],
changeDetection: ChangeDetectionStrategy.OnPush
}]
}], ctorParameters: function () { return []; }, propDecorators: { period: [{
type: Input
}] } });