@dhis2/analytics 24.10.4 → 24.10.6
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/CHANGELOG.md +14 -0
- package/build/cjs/components/AboutAOUnit/AboutAOUnit.js +1 -0
- package/build/cjs/components/AboutAOUnit/styles/AboutAOUnit.style.js +2 -2
- package/build/cjs/visualizations/config/adapters/dhis_highcharts/chart.js +1 -1
- package/build/cjs/visualizations/config/generators/highcharts/index.js +6 -4
- package/build/es/components/AboutAOUnit/AboutAOUnit.js +1 -0
- package/build/es/components/AboutAOUnit/styles/AboutAOUnit.style.js +2 -2
- package/build/es/visualizations/config/adapters/dhis_highcharts/chart.js +1 -1
- package/build/es/visualizations/config/generators/highcharts/index.js +6 -4
- package/package.json +2 -2
package/CHANGELOG.md
CHANGED
|
@@ -1,3 +1,17 @@
|
|
|
1
|
+
## [24.10.6](https://github.com/dhis2/analytics/compare/v24.10.5...v24.10.6) (2024-04-19)
|
|
2
|
+
|
|
3
|
+
|
|
4
|
+
### Bug Fixes
|
|
5
|
+
|
|
6
|
+
* **aboutAOUnit:** newlines missing in AO description ([#1656](https://github.com/dhis2/analytics/issues/1656)) ([8fe3a14](https://github.com/dhis2/analytics/commit/8fe3a14ec256f6eb2990fffcc092b1eea8911885)), closes [#1655](https://github.com/dhis2/analytics/issues/1655)
|
|
7
|
+
|
|
8
|
+
## [24.10.5](https://github.com/dhis2/analytics/compare/v24.10.4...v24.10.5) (2024-04-03)
|
|
9
|
+
|
|
10
|
+
|
|
11
|
+
### Bug Fixes
|
|
12
|
+
|
|
13
|
+
* avoid crash in DV with some chart types (DHIS2-15882) [24.x] ([#1651](https://github.com/dhis2/analytics/issues/1651)) ([68907d2](https://github.com/dhis2/analytics/commit/68907d2ef4dc1e200eeaa03c2b092229a68b9a99)), closes [#1582](https://github.com/dhis2/analytics/issues/1582)
|
|
14
|
+
|
|
1
15
|
## [24.10.4](https://github.com/dhis2/analytics/compare/v24.10.3...v24.10.4) (2024-04-02)
|
|
2
16
|
|
|
3
17
|
|
|
@@ -184,6 +184,7 @@ const AboutAOUnit = /*#__PURE__*/(0, _react.forwardRef)((_ref3, ref) => {
|
|
|
184
184
|
className: "jsx-".concat(_AboutAOUnitStyle.default.__hash) + " " + "content"
|
|
185
185
|
}, /*#__PURE__*/_react.default.createElement("p", {
|
|
186
186
|
className: "jsx-".concat(_AboutAOUnitStyle.default.__hash) + " " + ((0, _classnames.default)('detailLine', {
|
|
187
|
+
description: true,
|
|
187
188
|
noDescription: !data.ao.displayDescription
|
|
188
189
|
}) || "")
|
|
189
190
|
}, data.ao.displayDescription ? /*#__PURE__*/_react.default.createElement(_d2UiRichText.Parser, null, data.ao.displayDescription) : _d2I18n.default.t('No description')), /*#__PURE__*/_react.default.createElement("div", {
|
|
@@ -7,7 +7,7 @@ exports.default = void 0;
|
|
|
7
7
|
|
|
8
8
|
var _ui = require("@dhis2/ui");
|
|
9
9
|
|
|
10
|
-
const _defaultExport = [".container.jsx-
|
|
11
|
-
_defaultExport.__hash = "
|
|
10
|
+
const _defaultExport = [".container.jsx-3095370592{position:relative;padding:".concat(_ui.spacers.dp16, ";border-bottom:1px solid ").concat(_ui.colors.grey400, ";background-color:").concat(_ui.colors.white, ";}"), ".expanded.jsx-3095370592{padding-bottom:".concat(_ui.spacers.dp32, ";}"), ".loader.jsx-3095370592{display:-webkit-box;display:-webkit-flex;display:-ms-flexbox;display:flex;-webkit-box-pack:center;-webkit-justify-content:center;-ms-flex-pack:center;justify-content:center;}", ".header.jsx-3095370592{display:-webkit-box;display:-webkit-flex;display:-ms-flexbox;display:flex;-webkit-box-pack:justify;-webkit-justify-content:space-between;-ms-flex-pack:justify;justify-content:space-between;cursor:pointer;}", ".title.jsx-3095370592{font-size:16px;font-weight:500;line-height:21px;color:".concat(_ui.colors.grey900, ";}"), ".content.jsx-3095370592{font-size:14px;line-height:18px;color:".concat(_ui.colors.grey900, ";}"), ".detailLine.jsx-3095370592{display:-webkit-box;display:-webkit-flex;display:-ms-flexbox;display:flex;margin:0;padding:".concat(_ui.spacers.dp12, " 0 0 0;gap:").concat(_ui.spacers.dp8, ";}"), ".detailLine.jsx-3095370592 svg.jsx-3095370592{-webkit-flex-shrink:0;-ms-flex-negative:0;flex-shrink:0;}", ".description.jsx-3095370592{white-space:pre-line;}", ".noDescription.jsx-3095370592{color:".concat(_ui.colors.grey600, ";}"), ".subsection.jsx-3095370592{margin-top:".concat(_ui.spacers.dp24, ";}"), ".subsectionTitle.jsx-3095370592{color:".concat(_ui.colors.grey700, ";font-weight:500;}"), ".subscriptionLabel.jsx-3095370592{margin:".concat(_ui.spacers.dp12, " 0 ").concat(_ui.spacers.dp8, " 0;}"), ".subsection.jsx-3095370592 button.jsx-3095370592{margin-top:".concat(_ui.spacers.dp8, ";}")];
|
|
11
|
+
_defaultExport.__hash = "3095370592";
|
|
12
12
|
var _default = _defaultExport;
|
|
13
13
|
exports.default = _default;
|
|
@@ -29,7 +29,7 @@ const getEvents = () => ({
|
|
|
29
29
|
this.legend.allItems.forEach(item => {
|
|
30
30
|
if (item.legendSymbol) {
|
|
31
31
|
item.legendSymbol.attr({
|
|
32
|
-
translateY: -(item.legendItem.getBBox().height * 0.75 / 4) + item.legendSymbol.r / 2
|
|
32
|
+
translateY: -(item.legendItem.label.getBBox().height * 0.75 / 4) + item.legendSymbol.r / 2
|
|
33
33
|
});
|
|
34
34
|
}
|
|
35
35
|
});
|
|
@@ -35,6 +35,8 @@ function drawLegendSymbolWrap() {
|
|
|
35
35
|
_highcharts.default.wrap(_highcharts.default.seriesTypes.column.prototype, 'drawLegendSymbol', function (proceed, legend, item) {
|
|
36
36
|
var _this$options$legendS, _this$options$legendS2;
|
|
37
37
|
|
|
38
|
+
const legendItem = item.legendItem;
|
|
39
|
+
|
|
38
40
|
if ((_this$options$legendS = this.options.legendSet) !== null && _this$options$legendS !== void 0 && (_this$options$legendS2 = _this$options$legendS.legends) !== null && _this$options$legendS2 !== void 0 && _this$options$legendS2.length) {
|
|
39
41
|
const ys = legend.baseline - legend.symbolHeight + 1,
|
|
40
42
|
// y start
|
|
@@ -45,18 +47,18 @@ function drawLegendSymbolWrap() {
|
|
|
45
47
|
const legends = this.options.legendSet.legends.sort((a, b) => a.startValue - b.startValue);
|
|
46
48
|
this.chart.renderer.path(['M', x, ys, 'A', 1, 1, 0, 0, 0, x, ye, 'V', ys]).attr({
|
|
47
49
|
fill: legends[legends.length >= 5 ? 1 : 0].color
|
|
48
|
-
}).add(
|
|
50
|
+
}).add(legendItem.group);
|
|
49
51
|
this.chart.renderer.path(['M', x, ye, 'A', 1, 1, 0, 0, 0, x, ys, 'V', ye]).attr({
|
|
50
52
|
fill: legends[legends.length >= 5 ? legends.length - 2 : legends.length - 1].color
|
|
51
|
-
}).add(
|
|
53
|
+
}).add(legendItem.group);
|
|
52
54
|
} else {
|
|
53
55
|
var options = legend.options,
|
|
54
56
|
symbolHeight = legend.symbolHeight,
|
|
55
57
|
square = options.squareSymbol,
|
|
56
58
|
symbolWidth = square ? symbolHeight : legend.symbolWidth;
|
|
57
|
-
|
|
59
|
+
legendItem.symbol = this.chart.renderer.rect(square ? (legend.symbolWidth - symbolHeight) / 2 : 0, legend.baseline - symbolHeight + 1, symbolWidth, symbolHeight, pick(legend.options.symbolRadius, symbolHeight / 2)).addClass('highcharts-point').attr({
|
|
58
60
|
zIndex: 3
|
|
59
|
-
}).add(
|
|
61
|
+
}).add(legendItem.group);
|
|
60
62
|
}
|
|
61
63
|
});
|
|
62
64
|
}
|
|
@@ -159,6 +159,7 @@ const AboutAOUnit = /*#__PURE__*/forwardRef((_ref3, ref) => {
|
|
|
159
159
|
className: "jsx-".concat(styles.__hash) + " " + "content"
|
|
160
160
|
}, /*#__PURE__*/React.createElement("p", {
|
|
161
161
|
className: "jsx-".concat(styles.__hash) + " " + (cx('detailLine', {
|
|
162
|
+
description: true,
|
|
162
163
|
noDescription: !data.ao.displayDescription
|
|
163
164
|
}) || "")
|
|
164
165
|
}, data.ao.displayDescription ? /*#__PURE__*/React.createElement(RichTextParser, null, data.ao.displayDescription) : i18n.t('No description')), /*#__PURE__*/React.createElement("div", {
|
|
@@ -1,4 +1,4 @@
|
|
|
1
1
|
import { colors, spacers } from '@dhis2/ui';
|
|
2
|
-
const _defaultExport = [".container.jsx-
|
|
3
|
-
_defaultExport.__hash = "
|
|
2
|
+
const _defaultExport = [".container.jsx-3095370592{position:relative;padding:".concat(spacers.dp16, ";border-bottom:1px solid ").concat(colors.grey400, ";background-color:").concat(colors.white, ";}"), ".expanded.jsx-3095370592{padding-bottom:".concat(spacers.dp32, ";}"), ".loader.jsx-3095370592{display:-webkit-box;display:-webkit-flex;display:-ms-flexbox;display:flex;-webkit-box-pack:center;-webkit-justify-content:center;-ms-flex-pack:center;justify-content:center;}", ".header.jsx-3095370592{display:-webkit-box;display:-webkit-flex;display:-ms-flexbox;display:flex;-webkit-box-pack:justify;-webkit-justify-content:space-between;-ms-flex-pack:justify;justify-content:space-between;cursor:pointer;}", ".title.jsx-3095370592{font-size:16px;font-weight:500;line-height:21px;color:".concat(colors.grey900, ";}"), ".content.jsx-3095370592{font-size:14px;line-height:18px;color:".concat(colors.grey900, ";}"), ".detailLine.jsx-3095370592{display:-webkit-box;display:-webkit-flex;display:-ms-flexbox;display:flex;margin:0;padding:".concat(spacers.dp12, " 0 0 0;gap:").concat(spacers.dp8, ";}"), ".detailLine.jsx-3095370592 svg.jsx-3095370592{-webkit-flex-shrink:0;-ms-flex-negative:0;flex-shrink:0;}", ".description.jsx-3095370592{white-space:pre-line;}", ".noDescription.jsx-3095370592{color:".concat(colors.grey600, ";}"), ".subsection.jsx-3095370592{margin-top:".concat(spacers.dp24, ";}"), ".subsectionTitle.jsx-3095370592{color:".concat(colors.grey700, ";font-weight:500;}"), ".subscriptionLabel.jsx-3095370592{margin:".concat(spacers.dp12, " 0 ").concat(spacers.dp8, " 0;}"), ".subsection.jsx-3095370592 button.jsx-3095370592{margin-top:".concat(spacers.dp8, ";}")];
|
|
3
|
+
_defaultExport.__hash = "3095370592";
|
|
4
4
|
export default _defaultExport;
|
|
@@ -19,7 +19,7 @@ const getEvents = () => ({
|
|
|
19
19
|
this.legend.allItems.forEach(item => {
|
|
20
20
|
if (item.legendSymbol) {
|
|
21
21
|
item.legendSymbol.attr({
|
|
22
|
-
translateY: -(item.legendItem.getBBox().height * 0.75 / 4) + item.legendSymbol.r / 2
|
|
22
|
+
translateY: -(item.legendItem.label.getBBox().height * 0.75 / 4) + item.legendSymbol.r / 2
|
|
23
23
|
});
|
|
24
24
|
}
|
|
25
25
|
});
|
|
@@ -18,6 +18,8 @@ function drawLegendSymbolWrap() {
|
|
|
18
18
|
H.wrap(H.seriesTypes.column.prototype, 'drawLegendSymbol', function (proceed, legend, item) {
|
|
19
19
|
var _this$options$legendS, _this$options$legendS2;
|
|
20
20
|
|
|
21
|
+
const legendItem = item.legendItem;
|
|
22
|
+
|
|
21
23
|
if ((_this$options$legendS = this.options.legendSet) !== null && _this$options$legendS !== void 0 && (_this$options$legendS2 = _this$options$legendS.legends) !== null && _this$options$legendS2 !== void 0 && _this$options$legendS2.length) {
|
|
22
24
|
const ys = legend.baseline - legend.symbolHeight + 1,
|
|
23
25
|
// y start
|
|
@@ -28,18 +30,18 @@ function drawLegendSymbolWrap() {
|
|
|
28
30
|
const legends = this.options.legendSet.legends.sort((a, b) => a.startValue - b.startValue);
|
|
29
31
|
this.chart.renderer.path(['M', x, ys, 'A', 1, 1, 0, 0, 0, x, ye, 'V', ys]).attr({
|
|
30
32
|
fill: legends[legends.length >= 5 ? 1 : 0].color
|
|
31
|
-
}).add(
|
|
33
|
+
}).add(legendItem.group);
|
|
32
34
|
this.chart.renderer.path(['M', x, ye, 'A', 1, 1, 0, 0, 0, x, ys, 'V', ye]).attr({
|
|
33
35
|
fill: legends[legends.length >= 5 ? legends.length - 2 : legends.length - 1].color
|
|
34
|
-
}).add(
|
|
36
|
+
}).add(legendItem.group);
|
|
35
37
|
} else {
|
|
36
38
|
var options = legend.options,
|
|
37
39
|
symbolHeight = legend.symbolHeight,
|
|
38
40
|
square = options.squareSymbol,
|
|
39
41
|
symbolWidth = square ? symbolHeight : legend.symbolWidth;
|
|
40
|
-
|
|
42
|
+
legendItem.symbol = this.chart.renderer.rect(square ? (legend.symbolWidth - symbolHeight) / 2 : 0, legend.baseline - symbolHeight + 1, symbolWidth, symbolHeight, pick(legend.options.symbolRadius, symbolHeight / 2)).addClass('highcharts-point').attr({
|
|
41
43
|
zIndex: 3
|
|
42
|
-
}).add(
|
|
44
|
+
}).add(legendItem.group);
|
|
43
45
|
}
|
|
44
46
|
});
|
|
45
47
|
}
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@dhis2/analytics",
|
|
3
|
-
"version": "24.10.
|
|
3
|
+
"version": "24.10.6",
|
|
4
4
|
"main": "./build/cjs/index.js",
|
|
5
5
|
"module": "./build/es/index.js",
|
|
6
6
|
"exports": {
|
|
@@ -63,7 +63,7 @@
|
|
|
63
63
|
"classnames": "^2.3.1",
|
|
64
64
|
"d2-utilizr": "^0.2.16",
|
|
65
65
|
"d3-color": "^1.2.3",
|
|
66
|
-
"highcharts": "^10.
|
|
66
|
+
"highcharts": "^10.3.3",
|
|
67
67
|
"lodash": "^4.17.21",
|
|
68
68
|
"mathjs": "^9.4.2",
|
|
69
69
|
"react-beautiful-dnd": "^10.1.1",
|