cx 25.5.1 → 25.6.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/charts.js +40 -21
- package/dist/manifest.js +771 -771
- package/dist/ui.js +0 -15
- package/dist/widgets.js +34 -25
- package/package.json +1 -1
- package/src/charts/LineGraph.js +1 -1
- package/src/charts/axis/NumericAxis.d.ts +46 -46
- package/src/charts/helpers/PointReducer.d.ts +9 -0
- package/src/charts/helpers/PointReducer.js +36 -22
- package/src/data/AugmentedViewBase.js +77 -77
- package/src/data/ExposedRecordView.js +75 -75
- package/src/data/ExposedValueView.js +73 -73
- package/src/data/Ref.d.ts +24 -24
- package/src/data/Ref.spec.js +79 -79
- package/src/data/StoreRef.spec.js +24 -24
- package/src/data/StructuredDataAccessor.d.ts +7 -7
- package/src/data/SubscribableView.js +54 -54
- package/src/ui/Container.js +154 -154
- package/src/ui/DataProxy.js +31 -45
- package/src/ui/DetachedScope.js +98 -98
- package/src/ui/Instance.d.ts +72 -72
- package/src/ui/Instance.js +623 -623
- package/src/ui/IsolatedScope.js +30 -30
- package/src/ui/Repeater.js +109 -109
- package/src/ui/Rescope.js +35 -35
- package/src/ui/Restate.js +167 -167
- package/src/ui/Widget.js +184 -184
- package/src/ui/adapter/ArrayAdapter.js +152 -152
- package/src/ui/adapter/TreeAdapter.js +101 -101
- package/src/ui/createFunctionalComponent.d.ts +1 -1
- package/src/ui/index.d.ts +42 -42
- package/src/ui/layout/exploreChildren.d.ts +12 -12
- package/src/ui/layout/exploreChildren.js +27 -27
- package/src/util/debounce.js +18 -18
- package/src/util/validatedDebounce.js +19 -19
- package/src/widgets/Button.js +118 -118
- package/src/widgets/List.js +594 -594
- package/src/widgets/form/Calendar.d.ts +86 -86
- package/src/widgets/form/Checkbox.js +5 -2
- package/src/widgets/form/MonthField.d.ts +5 -0
- package/src/widgets/form/MonthField.js +1 -0
- package/src/widgets/form/MonthPicker.d.ts +13 -0
- package/src/widgets/form/MonthPicker.js +25 -21
- package/src/widgets/grid/Grid.js +3421 -3421
- package/src/widgets/nav/Route.js +102 -102
package/dist/charts.js
CHANGED
|
@@ -3395,7 +3395,7 @@ var LineGraph = /*#__PURE__*/ (function (_Widget) {
|
|
|
3395
3395
|
if (context.pointReducer && isArray(data.data)) {
|
|
3396
3396
|
data.data.forEach(function (p, index) {
|
|
3397
3397
|
if (data.area && _this2.y0Field)
|
|
3398
|
-
context.pointReducer(p[_this2.xField], p[_this2.y0Field], data.name, p, data, index);
|
|
3398
|
+
context.pointReducer(p[_this2.xField], p[_this2.y0Field], data.name, p, data.data, index);
|
|
3399
3399
|
context.pointReducer(p[_this2.xField], p[_this2.yField], data.name, p, data.data, index);
|
|
3400
3400
|
});
|
|
3401
3401
|
}
|
|
@@ -5517,29 +5517,48 @@ var PointReducer = /*#__PURE__*/ (function (_PureContainer) {
|
|
|
5517
5517
|
}
|
|
5518
5518
|
_inheritsLoose(PointReducer, _PureContainer);
|
|
5519
5519
|
var _proto = PointReducer.prototype;
|
|
5520
|
-
_proto.
|
|
5520
|
+
_proto.declareData = function declareData() {
|
|
5521
|
+
var _PureContainer$protot;
|
|
5522
|
+
(_PureContainer$protot = _PureContainer.prototype.declareData).call.apply(
|
|
5523
|
+
_PureContainer$protot,
|
|
5524
|
+
[this].concat(Array.prototype.slice.call(arguments), [
|
|
5525
|
+
{
|
|
5526
|
+
filterParams: {
|
|
5527
|
+
structured: true,
|
|
5528
|
+
},
|
|
5529
|
+
},
|
|
5530
|
+
]),
|
|
5531
|
+
);
|
|
5532
|
+
};
|
|
5533
|
+
_proto.prepareData = function prepareData(context, instance) {
|
|
5521
5534
|
var _this = this;
|
|
5522
|
-
|
|
5523
|
-
instance.
|
|
5524
|
-
if (!instance.pointReducer) {
|
|
5525
|
-
var onMap = this.onMap && instance.getCallback("onMap");
|
|
5535
|
+
_PureContainer.prototype.prepareData.call(this, context, instance);
|
|
5536
|
+
instance.resetAccumulator = function () {
|
|
5526
5537
|
var accumulator = {};
|
|
5527
|
-
|
|
5528
|
-
accumulator
|
|
5529
|
-
|
|
5530
|
-
}
|
|
5531
|
-
|
|
5532
|
-
|
|
5533
|
-
instance.
|
|
5534
|
-
|
|
5535
|
-
|
|
5536
|
-
|
|
5537
|
-
};
|
|
5538
|
-
instance.write = function () {
|
|
5539
|
-
if (_this.onReduce) instance.invoke("onReduce", accumulator, instance);
|
|
5540
|
-
};
|
|
5541
|
-
}
|
|
5538
|
+
if (_this.onInitAccumulator) {
|
|
5539
|
+
instance.invoke("onInitAccumulator", accumulator, instance);
|
|
5540
|
+
instance.accumulator = accumulator;
|
|
5541
|
+
}
|
|
5542
|
+
};
|
|
5543
|
+
if (this.onCreatePointFilter)
|
|
5544
|
+
instance.pointFilter = instance.invoke("onCreatePointFilter", instance.data.filterParams, instance);
|
|
5545
|
+
};
|
|
5546
|
+
_proto.explore = function explore(context, instance) {
|
|
5547
|
+
var _this2 = this;
|
|
5542
5548
|
instance.resetAccumulator();
|
|
5549
|
+
var parentPointReducer = context.pointReducer;
|
|
5550
|
+
instance.parentPointTracker = parentPointReducer;
|
|
5551
|
+
var pointFilter = instance.pointFilter;
|
|
5552
|
+
var accumulator = instance.accumulator;
|
|
5553
|
+
var onMap = this.onMap && instance.getCallback("onMap");
|
|
5554
|
+
instance.pointReducer = function (x, y, name, data, array, index) {
|
|
5555
|
+
if (!pointFilter || pointFilter(x, y, name, data, array, index))
|
|
5556
|
+
onMap(accumulator, x, y, name, data, array, index);
|
|
5557
|
+
if (parentPointReducer) parentPointReducer(x, y, name, data, array, index);
|
|
5558
|
+
};
|
|
5559
|
+
instance.write = function () {
|
|
5560
|
+
if (_this2.onReduce) instance.invoke("onReduce", accumulator, instance);
|
|
5561
|
+
};
|
|
5543
5562
|
context.push("pointReducer", instance.pointReducer);
|
|
5544
5563
|
_PureContainer.prototype.explore.call(this, context, instance);
|
|
5545
5564
|
};
|