UNPKG

igniteui-webcomponents-charts

Version:

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

329 lines (324 loc) 13.1 kB
import { __extends } from "tslib"; import { TrendLineType_$type } from "igniteui-webcomponents-core"; import { CategorySeriesMarkerCollisionAvoidance_$type } from "./CategorySeriesMarkerCollisionAvoidance"; import { ConsolidatedItemHitTestBehavior_$type } from "./ConsolidatedItemHitTestBehavior"; import { ValueLayerValueMode_$type } from "./ValueLayerValueMode"; import { IgcCategorySeriesComponent } from "./igc-category-series-component"; import { getAllPropertyNames, toSpinal, ensureEnum, enumToString, brushToString, stringToBrush, toDoubleCollection, fromDoubleCollection, doubleCollectionToString, toPoint, fromPoint } from "igniteui-webcomponents-core"; /** * Represents the base class for all IgxDataChartComponent anchored category/value series. * * The `AnchoredCategorySeries` represents the base class for all IgxDataChartComponent anchored category/value series. */ export var IgcAnchoredCategorySeriesComponent = /** @class */ /*@__PURE__*/ (function (_super) { __extends(IgcAnchoredCategorySeriesComponent, _super); function IgcAnchoredCategorySeriesComponent() { return _super.call(this) || this; } Object.defineProperty(IgcAnchoredCategorySeriesComponent.prototype, "i", { /** * @hidden */ get: function () { return this._implementation; }, enumerable: false, configurable: true }); IgcAnchoredCategorySeriesComponent.prototype.connectedCallback = function () { if (_super.prototype["connectedCallback"]) { _super.prototype["connectedCallback"].call(this); } if (this.i.connectedCallback) { this.i.connectedCallback(); } if (!this._attached) { this._attached = true; this._flushQueuedAttributes(); } }; IgcAnchoredCategorySeriesComponent.prototype.disconnectedCallback = function () { if (_super.prototype["disconnectedCallback"]) { _super.prototype["disconnectedCallback"].call(this); } if (this.i.disconnectedCallback) { this.i.disconnectedCallback(); } if (this._attached) { this._attached = false; } }; Object.defineProperty(IgcAnchoredCategorySeriesComponent, "observedAttributes", { get: function () { if (IgcAnchoredCategorySeriesComponent._observedAttributesIgcAnchoredCategorySeriesComponent == null) { var names = getAllPropertyNames(IgcAnchoredCategorySeriesComponent); for (var i = 0; i < names.length; i++) { names[i] = toSpinal(names[i]); } IgcAnchoredCategorySeriesComponent._observedAttributesIgcAnchoredCategorySeriesComponent = names; } return IgcAnchoredCategorySeriesComponent._observedAttributesIgcAnchoredCategorySeriesComponent; }, enumerable: false, configurable: true }); Object.defineProperty(IgcAnchoredCategorySeriesComponent.prototype, "valueMemberPath", { /** * Gets or sets the value mapping property for the current series object. * * The `ValueMemberPath` property is used for the value mapping property of the current series object. */ get: function () { return this.i.aca; }, set: function (v) { this.i.aca = v; }, enumerable: false, configurable: true }); Object.defineProperty(IgcAnchoredCategorySeriesComponent.prototype, "highlightedValueMemberPath", { /** * Gets or sets the value mapping property for the current series object. */ get: function () { return this.i.ab2; }, set: function (v) { this.i.ab2 = v; }, enumerable: false, configurable: true }); Object.defineProperty(IgcAnchoredCategorySeriesComponent.prototype, "valueMemberAsLegendLabel", { /** * Gets or sets the label displayed before series value in the Data Legend. */ get: function () { return this.i.ab6; }, set: function (v) { this.i.ab6 = v; }, enumerable: false, configurable: true }); Object.defineProperty(IgcAnchoredCategorySeriesComponent.prototype, "valueMemberAsLegendUnit", { /** * Gets or sets the unit displayed after series value in the Data Legend. */ get: function () { return this.i.ab8; }, set: function (v) { this.i.ab8 = v; }, enumerable: false, configurable: true }); Object.defineProperty(IgcAnchoredCategorySeriesComponent.prototype, "trendLineType", { /** * Gets or sets the trend type for the current series object. * * The `TrendLineType` property is used for the current series object's trend type.' * * ```ts * series.trendLineType= "CubicFit"; * ``` */ get: function () { return this.i.trendLineType; }, set: function (v) { this.i.trendLineType = ensureEnum(TrendLineType_$type, v); this._a("trendLineType", enumToString(TrendLineType_$type, this.i.trendLineType)); }, enumerable: false, configurable: true }); Object.defineProperty(IgcAnchoredCategorySeriesComponent.prototype, "trendLineBrush", { /** * Gets or sets the brush to use to draw the trend line. * * The `TrendLineBrush` property is used to brush the trend line. * * ```ts * series.trendLineBrush="red"; * ``` */ get: function () { return brushToString(this.i.trendLineBrush); }, set: function (v) { this.i.trendLineBrush = stringToBrush(v); this._a("trendLineBrush", brushToString(this.i.trendLineBrush)); }, enumerable: false, configurable: true }); Object.defineProperty(IgcAnchoredCategorySeriesComponent.prototype, "actualTrendLineBrush", { /** * Gets the effective TrendLineBrush for this series. * * The `ActualTrendLineBrush` property is used to gets the effective `TrendLineBrush` for this series. */ get: function () { return brushToString(this.i.acx); }, set: function (v) { this.i.acx = stringToBrush(v); this._a("actualTrendLineBrush", brushToString(this.i.acx)); }, enumerable: false, configurable: true }); Object.defineProperty(IgcAnchoredCategorySeriesComponent.prototype, "trendLineThickness", { /** * Gets or sets the thickness of the current series object's trend line. * * The `TrendLineThickness` property is used for thickness of the current series object's trend line. * * ```ts * series.trendLineThickness= 2; * ``` */ get: function () { return this.i.trendLineThickness; }, set: function (v) { this.i.trendLineThickness = +v; this._a("trendLineThickness", this.i.trendLineThickness); }, enumerable: false, configurable: true }); Object.defineProperty(IgcAnchoredCategorySeriesComponent.prototype, "trendLineDashArray", { /** * Gets or sets a collection of double values that indicate the pattern of dashes and gaps that * is used to draw the trend line for the current series object. */ get: function () { return fromDoubleCollection(this.i.acy); }, set: function (v) { this.i.acy = toDoubleCollection(v); this._a("trendLineDashArray", doubleCollectionToString(this.i.acy)); }, enumerable: false, configurable: true }); Object.defineProperty(IgcAnchoredCategorySeriesComponent.prototype, "trendLinePeriod", { /** * Gets or sets the trend line period for the current series. * The typical, and initial, value for trend line period is 7. * * The `TrendLinePeriod` property is used for trend line period of the current series. * * ```ts * series.trendLinePeriod= 7; * ``` */ get: function () { return this.i.trendLinePeriod; }, set: function (v) { this.i.trendLinePeriod = +v; this._a("trendLinePeriod", this.i.trendLinePeriod); }, enumerable: false, configurable: true }); Object.defineProperty(IgcAnchoredCategorySeriesComponent.prototype, "markerCollisionAvoidance", { /** * The desired behavior for markers in this series which are placed too close together for the current view, resulting in a collision. * * The `MarkerCollisionAvoidance` property controls the technique the chart uses to avoid overlapping markers. */ get: function () { return this.i.abk; }, set: function (v) { this.i.abk = ensureEnum(CategorySeriesMarkerCollisionAvoidance_$type, v); this._a("markerCollisionAvoidance", enumToString(CategorySeriesMarkerCollisionAvoidance_$type, this.i.abk)); }, enumerable: false, configurable: true }); Object.defineProperty(IgcAnchoredCategorySeriesComponent.prototype, "consolidatedItemHitTestBehavior", { /** * Determines the item returned in hit-testing when the pointer is over an object which represents several consolidated items. * * The `ConsolidatedItemHitTestBehavior` property is used to determines returned item in hit-testing when the pointer is over an object which represents several consolidated items. */ get: function () { return this.i.abl; }, set: function (v) { this.i.abl = ensureEnum(ConsolidatedItemHitTestBehavior_$type, v); this._a("consolidatedItemHitTestBehavior", enumToString(ConsolidatedItemHitTestBehavior_$type, this.i.abl)); }, enumerable: false, configurable: true }); IgcAnchoredCategorySeriesComponent.prototype.getItemValue = function (item, memberPathName) { var iv = this.i.kz(item, memberPathName); return (iv); }; /** * Gets the value of a requested member path from the series. * @param memberPathName * The property name of a valid member path for the series */ IgcAnchoredCategorySeriesComponent.prototype.getMemberPathValue = function (memberPathName) { var iv = this.i.mo(memberPathName); return (iv); }; /** * Scrolls the series to display the item for the specified data item. * The series is scrolled by the minimum amount required to place the specified data item within * the central 80% of the visible axis. * @param item * The data item (item) to scroll to. * * The `ScrollIntoView` method is used to notifies the target axis or series that it should scroll the requested data item into view. * * ```ts * this.series.scrollIntoView(dataItem); * ``` */ IgcAnchoredCategorySeriesComponent.prototype.scrollIntoView = function (item) { var iv = this.i.gj(item); return (iv); }; /** * Gets the item that is the best match for the specified world coordinates. * @param world * The world coordinates to use. * * The `getItem` method is used to gets the item that is the best match for the specified world coordinates. * * ```ts * let item: number = this.series.getItem({x:.5,y:.5}); * ``` */ IgcAnchoredCategorySeriesComponent.prototype.getItem = function (world) { var iv = this.i.kw(toPoint(world)); return (iv); }; /** * Gets a numeric value from the numeric axis associated with this series that matches the desired * value mode. * @param mode * The type of value desired from the series numeric axis. */ IgcAnchoredCategorySeriesComponent.prototype.getSeriesValueType = function (mode) { var iv = this.i.aq(ensureEnum(ValueLayerValueMode_$type, mode)); return (iv); }; IgcAnchoredCategorySeriesComponent.prototype.getSeriesValueTypePosition = function (mode) { var iv = this.i.wz(ensureEnum(ValueLayerValueMode_$type, mode)); return fromPoint(iv); }; IgcAnchoredCategorySeriesComponent.prototype.getSeriesValueTypePositionFromValue = function (values) { var iv = this.i.w0(values); return fromPoint(iv); }; IgcAnchoredCategorySeriesComponent._observedAttributesIgcAnchoredCategorySeriesComponent = null; return IgcAnchoredCategorySeriesComponent; }(IgcCategorySeriesComponent));