igniteui-webcomponents-charts
Version:
Ignite UI Web Components charting components for building rich data visualizations using TypeScript APIs.
141 lines (140 loc) • 5.27 kB
JavaScript
import { __extends } from "tslib";
import { IgcBrushScaleComponent } from "./igc-brush-scale-component";
import { ValueBrushScale } from "./ValueBrushScale";
import { getAllPropertyNames, toSpinal, ensureBool } from "igniteui-webcomponents-core";
import { RegisterElementHelper } from "igniteui-webcomponents-core";
/**
* Represents a brush scale that uses value-based brush selection.
*/
export var IgcValueBrushScaleComponent = /** @class */ /*@__PURE__*/ (function (_super) {
__extends(IgcValueBrushScaleComponent, _super);
function IgcValueBrushScaleComponent() {
return _super.call(this) || this;
}
IgcValueBrushScaleComponent.prototype.createImplementation = function () {
return new ValueBrushScale();
};
Object.defineProperty(IgcValueBrushScaleComponent.prototype, "i", {
/**
* @hidden
*/
get: function () {
return this._implementation;
},
enumerable: false,
configurable: true
});
IgcValueBrushScaleComponent.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();
}
};
IgcValueBrushScaleComponent.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(IgcValueBrushScaleComponent, "observedAttributes", {
get: function () {
if (IgcValueBrushScaleComponent._observedAttributesIgcValueBrushScaleComponent == null) {
var names = getAllPropertyNames(IgcValueBrushScaleComponent);
for (var i = 0; i < names.length; i++) {
names[i] = toSpinal(names[i]);
}
IgcValueBrushScaleComponent._observedAttributesIgcValueBrushScaleComponent = names;
}
return IgcValueBrushScaleComponent._observedAttributesIgcValueBrushScaleComponent;
},
enumerable: false,
configurable: true
});
IgcValueBrushScaleComponent.register = function () {
if (!IgcValueBrushScaleComponent._isElementRegistered) {
IgcValueBrushScaleComponent._isElementRegistered = true;
RegisterElementHelper.registerElement(IgcValueBrushScaleComponent.htmlTagName, IgcValueBrushScaleComponent);
}
};
Object.defineProperty(IgcValueBrushScaleComponent.prototype, "minimumValue", {
/**
* Gets or sets the minimum value for this scale.
*/
get: function () {
return this.i.minimumValue;
},
set: function (v) {
this.i.minimumValue = +v;
this._a("minimumValue", this.i.minimumValue);
},
enumerable: false,
configurable: true
});
Object.defineProperty(IgcValueBrushScaleComponent.prototype, "maximumValue", {
/**
* Gets or sets the maximum value for this scale.
*/
get: function () {
return this.i.maximumValue;
},
set: function (v) {
this.i.maximumValue = +v;
this._a("maximumValue", this.i.maximumValue);
},
enumerable: false,
configurable: true
});
Object.defineProperty(IgcValueBrushScaleComponent.prototype, "isLogarithmic", {
/**
* Gets or sets whether the scale is logarithmic.
*/
get: function () {
return this.i.isLogarithmic;
},
set: function (v) {
this.i.isLogarithmic = ensureBool(v);
this._a("isLogarithmic", this.i.isLogarithmic);
},
enumerable: false,
configurable: true
});
Object.defineProperty(IgcValueBrushScaleComponent.prototype, "logarithmBase", {
/**
* Gets or sets the logarithm base for this scale.
*/
get: function () {
return this.i.logarithmBase;
},
set: function (v) {
this.i.logarithmBase = +v;
this._a("logarithmBase", this.i.logarithmBase);
},
enumerable: false,
configurable: true
});
Object.defineProperty(IgcValueBrushScaleComponent.prototype, "isReady", {
/**
* Checks if the value brush scale is ready for usage in the chart
*/
get: function () {
return this.i.isReady;
},
enumerable: false,
configurable: true
});
IgcValueBrushScaleComponent._observedAttributesIgcValueBrushScaleComponent = null;
IgcValueBrushScaleComponent.htmlTagName = "igc-value-brush-scale";
IgcValueBrushScaleComponent._isElementRegistered = false;
return IgcValueBrushScaleComponent;
}(IgcBrushScaleComponent));