@contrail/data-grouping
Advanced tools
Comparing version 1.0.40 to 1.0.41
@@ -84,7 +84,8 @@ "use strict"; | ||
static buildChildDataGroups(data, parentGroup, groupingProperties, leafNodeDataCount, currentDepth, groupMultiSelectInSeparateFrame = false) { | ||
var _a, _b, _c, _d; | ||
var _a, _b, _c, _d, _e; | ||
const groupingProperty = groupingProperties[currentDepth]; | ||
const propertyTypeOptions = { | ||
isDate: ((_a = groupingProperty === null || groupingProperty === void 0 ? void 0 : groupingProperty.propertyDefinition) === null || _a === void 0 ? void 0 : _a.propertyType) === 'date', | ||
isNumber: !!((_b = groupingProperty === null || groupingProperty === void 0 ? void 0 : groupingProperty.propertyDefinition) === null || _b === void 0 ? void 0 : _b.numberFormat), | ||
isNumber: !!((_b = groupingProperty === null || groupingProperty === void 0 ? void 0 : groupingProperty.propertyDefinition) === null || _b === void 0 ? void 0 : _b.numberFormat) || | ||
((_c = groupingProperty === null || groupingProperty === void 0 ? void 0 : groupingProperty.propertyDefinition) === null || _c === void 0 ? void 0 : _c.propertyType) === 'sequence', | ||
}; | ||
@@ -96,3 +97,3 @@ const rootIndex = groupingProperty.typeRootSlug; | ||
const sort = groupingProperty.sort || types_1.TypePropertySortOrder.ASCENDING; | ||
const options = ((_d = (_c = groupingProperty.propertyDefinition) === null || _c === void 0 ? void 0 : _c.options) === null || _d === void 0 ? void 0 : _d.map((x) => x.value)) || null; | ||
const options = ((_e = (_d = groupingProperty.propertyDefinition) === null || _d === void 0 ? void 0 : _d.options) === null || _e === void 0 ? void 0 : _e.map((x) => x.value)) || null; | ||
let distinctValues = this.getDistinctValues(data, rootIndex, slugIndex, rootAltIndex, slugAltIndex, groupMultiSelectInSeparateFrame, { sortOrder: sort, options }, propertyTypeOptions); | ||
@@ -99,0 +100,0 @@ for (let val of distinctValues) { |
{ | ||
"name": "@contrail/data-grouping", | ||
"version": "1.0.40", | ||
"version": "1.0.41", | ||
"description": "Utilities and interfaces for grouping data into hierarchial data structures based on properties.", | ||
@@ -5,0 +5,0 @@ "main": "lib/index.js", |
14742
262