ag-grid-enterprise
Version:
AG Grid Enterprise Features
42 lines • 1.47 kB
JavaScript
;
var __values = (this && this.__values) || function(o) {
var s = typeof Symbol === "function" && Symbol.iterator, m = s && o[s], i = 0;
if (m) return m.call(o);
if (o && typeof o.length === "number") return {
next: function () {
if (o && i >= o.length) o = void 0;
return { value: o && o[i++], done: !o };
}
};
throw new TypeError(s ? "Object is not iterable." : "Symbol.iterator is not defined.");
};
Object.defineProperty(exports, "__esModule", { value: true });
exports.extendDomain = void 0;
function extendDomain(values, domain) {
var e_1, _a;
if (domain === void 0) { domain = [Infinity, -Infinity]; }
try {
for (var values_1 = __values(values), values_1_1 = values_1.next(); !values_1_1.done; values_1_1 = values_1.next()) {
var value = values_1_1.value;
if (typeof value !== 'number') {
continue;
}
if (value < domain[0]) {
domain[0] = value;
}
if (value > domain[1]) {
domain[1] = value;
}
}
}
catch (e_1_1) { e_1 = { error: e_1_1 }; }
finally {
try {
if (values_1_1 && !values_1_1.done && (_a = values_1.return)) _a.call(values_1);
}
finally { if (e_1) throw e_1.error; }
}
return domain;
}
exports.extendDomain = extendDomain;
//# sourceMappingURL=utilFunctions.js.map