@dhis2/analytics 29.4.2 → 29.4.3

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.
@@ -0,0 +1,142 @@
1
+ "use strict";
2
+
3
+ Object.defineProperty(exports, "__esModule", {
4
+ value: true
5
+ });
6
+ exports.default = exports.VerboseData = exports.ShortLabels = exports.MissingFields = void 0;
7
+ var _appRuntime = require("@dhis2/app-runtime");
8
+ var _react = _interopRequireDefault(require("react"));
9
+ var _AboutAOUnit = _interopRequireDefault(require("../components/AboutAOUnit/AboutAOUnit.js"));
10
+ function _interopRequireDefault(e) { return e && e.__esModule ? e : { default: e }; }
11
+ const verboseData = {
12
+ visualizations: {
13
+ id: 'abc123verbose',
14
+ displayDescription: 'This is a comprehensive **visualization** showing district-level aggregate data across all 47 counties for the Expanded Programme on Immunization (EPI) including BCG, OPV, Pentavalent, and Measles-Rubella coverage rates disaggregated by age, sex, and facility ownership for the fiscal year 2024/2025.',
15
+ created: '2023-01-15T08:30:00.000',
16
+ createdBy: {
17
+ displayName: 'Dr. Alexandria Konstantinopolous-Whittington III, MD, PhD'
18
+ },
19
+ lastUpdated: '2024-11-02T14:22:00.000',
20
+ subscribed: true,
21
+ sharing: {
22
+ public: 'r',
23
+ users: {
24
+ u1: {
25
+ displayName: 'Maria-Fernanda de los Ángeles Gutiérrez-Montoya',
26
+ access: 'rw'
27
+ },
28
+ u2: {
29
+ displayName: 'Jean-Pierre Barthélémy Christophersen',
30
+ access: 'r'
31
+ }
32
+ },
33
+ userGroups: {
34
+ g1: {
35
+ displayName: 'National Immunization Programme Monitoring & Evaluation Team',
36
+ access: 'rw'
37
+ },
38
+ g2: {
39
+ displayName: 'District Health Information System Administrators Group',
40
+ access: 'r'
41
+ }
42
+ }
43
+ }
44
+ },
45
+ 'dataStatistics/favorites': {
46
+ views: 14873
47
+ }
48
+ };
49
+ const shortData = {
50
+ visualizations: {
51
+ id: 'xyz789short',
52
+ displayDescription: 'ANC coverage Q3',
53
+ created: '2025-12-01T10:00:00.000',
54
+ createdBy: {
55
+ displayName: 'Li Wei'
56
+ },
57
+ lastUpdated: '2026-04-10T09:00:00.000',
58
+ subscribed: false,
59
+ sharing: {
60
+ public: 'rw',
61
+ users: {},
62
+ userGroups: {
63
+ g1: {
64
+ displayName: 'HMIS',
65
+ access: 'r'
66
+ }
67
+ }
68
+ }
69
+ },
70
+ 'dataStatistics/favorites': {
71
+ views: 3
72
+ }
73
+ };
74
+ const missingFieldsData = {
75
+ visualizations: {
76
+ id: 'missing456',
77
+ displayDescription: null,
78
+ created: '2026-03-20T12:00:00.000',
79
+ createdBy: null,
80
+ lastUpdated: '2026-04-13T06:45:00.000',
81
+ subscribed: false,
82
+ sharing: {
83
+ public: '',
84
+ users: {},
85
+ userGroups: {}
86
+ }
87
+ },
88
+ 'dataStatistics/favorites': {
89
+ views: 0
90
+ }
91
+ };
92
+ var _default = exports.default = {
93
+ title: 'AboutAOUnit'
94
+ };
95
+ const VerboseData = () => /*#__PURE__*/_react.default.createElement(_appRuntime.CustomDataProvider, {
96
+ data: verboseData
97
+ }, /*#__PURE__*/_react.default.createElement("div", {
98
+ style: {
99
+ width: 372,
100
+ padding: '16px',
101
+ backgroundColor: 'lightgray'
102
+ }
103
+ }, /*#__PURE__*/_react.default.createElement(_AboutAOUnit.default, {
104
+ type: "visualization",
105
+ id: "abc123verbose"
106
+ })));
107
+ exports.VerboseData = VerboseData;
108
+ VerboseData.story = {
109
+ name: 'Verbose data with long labels'
110
+ };
111
+ const ShortLabels = () => /*#__PURE__*/_react.default.createElement(_appRuntime.CustomDataProvider, {
112
+ data: shortData
113
+ }, /*#__PURE__*/_react.default.createElement("div", {
114
+ style: {
115
+ width: 372,
116
+ padding: '16px',
117
+ backgroundColor: 'lightgray'
118
+ }
119
+ }, /*#__PURE__*/_react.default.createElement(_AboutAOUnit.default, {
120
+ type: "visualization",
121
+ id: "xyz789short"
122
+ })));
123
+ exports.ShortLabels = ShortLabels;
124
+ ShortLabels.story = {
125
+ name: 'Short labels'
126
+ };
127
+ const MissingFields = () => /*#__PURE__*/_react.default.createElement(_appRuntime.CustomDataProvider, {
128
+ data: missingFieldsData
129
+ }, /*#__PURE__*/_react.default.createElement("div", {
130
+ style: {
131
+ width: 372,
132
+ padding: '16px',
133
+ backgroundColor: 'lightgray'
134
+ }
135
+ }, /*#__PURE__*/_react.default.createElement(_AboutAOUnit.default, {
136
+ type: "visualization",
137
+ id: "missing456"
138
+ })));
139
+ exports.MissingFields = MissingFields;
140
+ MissingFields.story = {
141
+ name: 'Missing fields (no description, no author, no sharing)'
142
+ };
@@ -147,8 +147,7 @@ const AboutAOUnit = /*#__PURE__*/(0, _react.forwardRef)(({
147
147
  })), data && /*#__PURE__*/_react.default.createElement("div", {
148
148
  className: `jsx-${_AboutAOUnitStyle.default.__hash}` + " " + "content"
149
149
  }, /*#__PURE__*/_react.default.createElement("div", {
150
- className: `jsx-${_AboutAOUnitStyle.default.__hash}` + " " + ((0, _classnames.default)('detailLine', {
151
- description: true,
150
+ className: `jsx-${_AboutAOUnitStyle.default.__hash}` + " " + ((0, _classnames.default)('description', {
152
151
  noDescription: !data.ao.displayDescription
153
152
  }) || "")
154
153
  }, data.ao.displayDescription ? /*#__PURE__*/_react.default.createElement(_index.RichTextParser, null, data.ao.displayDescription) : /*#__PURE__*/_react.default.createElement("p", {
@@ -157,28 +156,36 @@ const AboutAOUnit = /*#__PURE__*/(0, _react.forwardRef)(({
157
156
  className: `jsx-${_AboutAOUnitStyle.default.__hash}`
158
157
  }, /*#__PURE__*/_react.default.createElement("p", {
159
158
  className: `jsx-${_AboutAOUnitStyle.default.__hash}` + " " + "detailLine"
159
+ }, /*#__PURE__*/_react.default.createElement("span", {
160
+ className: `jsx-${_AboutAOUnitStyle.default.__hash}` + " " + "icon"
160
161
  }, /*#__PURE__*/_react.default.createElement(_ui.IconShare16, {
161
162
  color: _ui.colors.grey700
162
- }), getSharingSummary(data.ao)), /*#__PURE__*/_react.default.createElement("p", {
163
+ })), getSharingSummary(data.ao)), /*#__PURE__*/_react.default.createElement("p", {
163
164
  className: `jsx-${_AboutAOUnitStyle.default.__hash}` + " " + "detailLine"
165
+ }, /*#__PURE__*/_react.default.createElement("span", {
166
+ className: `jsx-${_AboutAOUnitStyle.default.__hash}` + " " + "icon"
164
167
  }, /*#__PURE__*/_react.default.createElement(_ui.IconClock16, {
165
168
  color: _ui.colors.grey700
166
- }), _d2I18n.default.t('Last updated {{time}}', {
169
+ })), _d2I18n.default.t('Last updated {{time}}', {
167
170
  time: (0, _moment.default)(fromServerDate(data.ao.lastUpdated)).fromNow()
168
171
  })), /*#__PURE__*/_react.default.createElement("p", {
169
172
  className: `jsx-${_AboutAOUnitStyle.default.__hash}` + " " + "detailLine"
173
+ }, /*#__PURE__*/_react.default.createElement("span", {
174
+ className: `jsx-${_AboutAOUnitStyle.default.__hash}` + " " + "icon"
170
175
  }, /*#__PURE__*/_react.default.createElement(_ui.IconUser16, {
171
176
  color: _ui.colors.grey700
172
- }), (_data$ao$createdBy = data.ao.createdBy) !== null && _data$ao$createdBy !== void 0 && _data$ao$createdBy.displayName ? _d2I18n.default.t('Created {{time}} by {{author}}', {
177
+ })), (_data$ao$createdBy = data.ao.createdBy) !== null && _data$ao$createdBy !== void 0 && _data$ao$createdBy.displayName ? _d2I18n.default.t('Created {{time}} by {{author}}', {
173
178
  time: (0, _moment.default)(fromServerDate(data.ao.created)).fromNow(),
174
179
  author: data.ao.createdBy.displayName
175
180
  }) : _d2I18n.default.t('Created {{time}}', {
176
181
  time: (0, _moment.default)(fromServerDate(data.ao.created)).fromNow()
177
182
  })), /*#__PURE__*/_react.default.createElement("p", {
178
183
  className: `jsx-${_AboutAOUnitStyle.default.__hash}` + " " + "detailLine"
184
+ }, /*#__PURE__*/_react.default.createElement("span", {
185
+ className: `jsx-${_AboutAOUnitStyle.default.__hash}` + " " + "icon"
179
186
  }, /*#__PURE__*/_react.default.createElement(_ui.IconView16, {
180
187
  color: _ui.colors.grey700
181
- }), _d2I18n.default.t('Viewed {{count}} times', {
188
+ })), _d2I18n.default.t('Viewed {{count}} times', {
182
189
  count: data.dataStatistics.views,
183
190
  defaultValue: 'Viewed 1 time',
184
191
  defaultValue_plural: 'Viewed {{count}} times'
@@ -189,7 +196,7 @@ const AboutAOUnit = /*#__PURE__*/(0, _react.forwardRef)(({
189
196
  }, _d2I18n.default.t('Notifications')), data.ao.subscribed ? /*#__PURE__*/_react.default.createElement(_react.default.Fragment, null, /*#__PURE__*/_react.default.createElement("p", {
190
197
  className: `jsx-${_AboutAOUnitStyle.default.__hash}` + " " + "subscriptionLabel"
191
198
  }, _d2I18n.default.t("You're subscribed and getting updates about new interpretations.")), /*#__PURE__*/_react.default.createElement(_ui.Button, {
192
- icon: /*#__PURE__*/_react.default.createElement(_ui.IconSubscribeOff24, {
199
+ icon: /*#__PURE__*/_react.default.createElement(_ui.IconSubscribeOff16, {
193
200
  color: _ui.colors.grey700
194
201
  }),
195
202
  secondary: true,
@@ -199,7 +206,7 @@ const AboutAOUnit = /*#__PURE__*/(0, _react.forwardRef)(({
199
206
  }, _d2I18n.default.t('Unsubscribe'))) : /*#__PURE__*/_react.default.createElement(_react.default.Fragment, null, /*#__PURE__*/_react.default.createElement("p", {
200
207
  className: `jsx-${_AboutAOUnitStyle.default.__hash}` + " " + "subscriptionLabel"
201
208
  }, _d2I18n.default.t('Subscribe to get updates about new interpretations.')), /*#__PURE__*/_react.default.createElement(_ui.Button, {
202
- icon: /*#__PURE__*/_react.default.createElement(_ui.IconSubscribe24, {
209
+ icon: /*#__PURE__*/_react.default.createElement(_ui.IconSubscribe16, {
203
210
  color: _ui.colors.grey700
204
211
  }),
205
212
  secondary: true,
@@ -5,6 +5,6 @@ Object.defineProperty(exports, "__esModule", {
5
5
  });
6
6
  exports.default = void 0;
7
7
  var _ui = require("@dhis2/ui");
8
- const _defaultExport = [`.container.jsx-3095370592{position:relative;padding:${_ui.spacers.dp16};border-bottom:1px solid ${_ui.colors.grey400};background-color:${_ui.colors.white};}`, `.expanded.jsx-3095370592{padding-bottom:${_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:${_ui.colors.grey900};}`, `.content.jsx-3095370592{font-size:14px;line-height:18px;color:${_ui.colors.grey900};}`, `.detailLine.jsx-3095370592{display:-webkit-box;display:-webkit-flex;display:-ms-flexbox;display:flex;margin:0;padding:${_ui.spacers.dp12} 0 0 0;gap:${_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:${_ui.colors.grey600};}`, `.subsection.jsx-3095370592{margin-top:${_ui.spacers.dp24};}`, `.subsectionTitle.jsx-3095370592{color:${_ui.colors.grey700};font-weight:500;}`, `.subscriptionLabel.jsx-3095370592{margin:${_ui.spacers.dp12} 0 ${_ui.spacers.dp8} 0;}`, `.subsection.jsx-3095370592 button.jsx-3095370592{margin-top:${_ui.spacers.dp8};}`];
9
- _defaultExport.__hash = "3095370592";
8
+ const _defaultExport = [`.container.jsx-3783470976{position:relative;padding:${_ui.spacers.dp16};border-bottom:1px solid ${_ui.colors.grey400};background-color:${_ui.colors.white};}`, `.expanded.jsx-3783470976{padding-bottom:${_ui.spacers.dp16};}`, `.loader.jsx-3783470976{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;padding-top:${_ui.spacers.dp16};}`, ".header.jsx-3783470976{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;-webkit-align-items:center;-webkit-box-align:center;-ms-flex-align:center;align-items:center;cursor:pointer;}", `.title.jsx-3783470976{font-size:16px;font-weight:500;line-height:21px;color:${_ui.colors.grey900};}`, `.content.jsx-3783470976{font-size:14px;line-height:20px;color:${_ui.colors.grey900};}`, `.detailLine.jsx-3783470976{display:-webkit-box;display:-webkit-flex;display:-ms-flexbox;display:flex;-webkit-align-items:flex-start;-webkit-box-align:flex-start;-ms-flex-align:flex-start;align-items:flex-start;margin:0;padding:${_ui.spacers.dp12} 0 0 0;gap:${_ui.spacers.dp8};}`, ".detailLine.jsx-3783470976 .icon.jsx-3783470976{-webkit-flex-shrink:0;-ms-flex-negative:0;flex-shrink:0;display:-webkit-box;display:-webkit-flex;display:-ms-flexbox;display:flex;-webkit-align-items:center;-webkit-box-align:center;-ms-flex-align:center;align-items:center;height:20px;}", ".description.jsx-3783470976{padding:0;}", `.description.jsx-3783470976 p{margin:${_ui.spacers.dp8} 0 ${_ui.spacers.dp4} 0;white-space:pre-line;}`, `.noDescription.jsx-3783470976{color:${_ui.colors.grey500};}`, `.subsection.jsx-3783470976{margin-top:${_ui.spacers.dp24};}`, `.subsectionTitle.jsx-3783470976{color:${_ui.colors.grey800};font-weight:500;margin:0;}`, `.subscriptionLabel.jsx-3783470976{font-size:13px;line-height:18px;margin:${_ui.spacers.dp4} 0 ${_ui.spacers.dp8} 0;color:${_ui.colors.grey600};}`];
9
+ _defaultExport.__hash = "3783470976";
10
10
  var _default = exports.default = _defaultExport;
@@ -0,0 +1,132 @@
1
+ import { CustomDataProvider } from '@dhis2/app-runtime';
2
+ import React from 'react';
3
+ import AboutAOUnit from '../components/AboutAOUnit/AboutAOUnit.js';
4
+ const verboseData = {
5
+ visualizations: {
6
+ id: 'abc123verbose',
7
+ displayDescription: 'This is a comprehensive **visualization** showing district-level aggregate data across all 47 counties for the Expanded Programme on Immunization (EPI) including BCG, OPV, Pentavalent, and Measles-Rubella coverage rates disaggregated by age, sex, and facility ownership for the fiscal year 2024/2025.',
8
+ created: '2023-01-15T08:30:00.000',
9
+ createdBy: {
10
+ displayName: 'Dr. Alexandria Konstantinopolous-Whittington III, MD, PhD'
11
+ },
12
+ lastUpdated: '2024-11-02T14:22:00.000',
13
+ subscribed: true,
14
+ sharing: {
15
+ public: 'r',
16
+ users: {
17
+ u1: {
18
+ displayName: 'Maria-Fernanda de los Ángeles Gutiérrez-Montoya',
19
+ access: 'rw'
20
+ },
21
+ u2: {
22
+ displayName: 'Jean-Pierre Barthélémy Christophersen',
23
+ access: 'r'
24
+ }
25
+ },
26
+ userGroups: {
27
+ g1: {
28
+ displayName: 'National Immunization Programme Monitoring & Evaluation Team',
29
+ access: 'rw'
30
+ },
31
+ g2: {
32
+ displayName: 'District Health Information System Administrators Group',
33
+ access: 'r'
34
+ }
35
+ }
36
+ }
37
+ },
38
+ 'dataStatistics/favorites': {
39
+ views: 14873
40
+ }
41
+ };
42
+ const shortData = {
43
+ visualizations: {
44
+ id: 'xyz789short',
45
+ displayDescription: 'ANC coverage Q3',
46
+ created: '2025-12-01T10:00:00.000',
47
+ createdBy: {
48
+ displayName: 'Li Wei'
49
+ },
50
+ lastUpdated: '2026-04-10T09:00:00.000',
51
+ subscribed: false,
52
+ sharing: {
53
+ public: 'rw',
54
+ users: {},
55
+ userGroups: {
56
+ g1: {
57
+ displayName: 'HMIS',
58
+ access: 'r'
59
+ }
60
+ }
61
+ }
62
+ },
63
+ 'dataStatistics/favorites': {
64
+ views: 3
65
+ }
66
+ };
67
+ const missingFieldsData = {
68
+ visualizations: {
69
+ id: 'missing456',
70
+ displayDescription: null,
71
+ created: '2026-03-20T12:00:00.000',
72
+ createdBy: null,
73
+ lastUpdated: '2026-04-13T06:45:00.000',
74
+ subscribed: false,
75
+ sharing: {
76
+ public: '',
77
+ users: {},
78
+ userGroups: {}
79
+ }
80
+ },
81
+ 'dataStatistics/favorites': {
82
+ views: 0
83
+ }
84
+ };
85
+ export default {
86
+ title: 'AboutAOUnit'
87
+ };
88
+ export const VerboseData = () => /*#__PURE__*/React.createElement(CustomDataProvider, {
89
+ data: verboseData
90
+ }, /*#__PURE__*/React.createElement("div", {
91
+ style: {
92
+ width: 372,
93
+ padding: '16px',
94
+ backgroundColor: 'lightgray'
95
+ }
96
+ }, /*#__PURE__*/React.createElement(AboutAOUnit, {
97
+ type: "visualization",
98
+ id: "abc123verbose"
99
+ })));
100
+ VerboseData.story = {
101
+ name: 'Verbose data with long labels'
102
+ };
103
+ export const ShortLabels = () => /*#__PURE__*/React.createElement(CustomDataProvider, {
104
+ data: shortData
105
+ }, /*#__PURE__*/React.createElement("div", {
106
+ style: {
107
+ width: 372,
108
+ padding: '16px',
109
+ backgroundColor: 'lightgray'
110
+ }
111
+ }, /*#__PURE__*/React.createElement(AboutAOUnit, {
112
+ type: "visualization",
113
+ id: "xyz789short"
114
+ })));
115
+ ShortLabels.story = {
116
+ name: 'Short labels'
117
+ };
118
+ export const MissingFields = () => /*#__PURE__*/React.createElement(CustomDataProvider, {
119
+ data: missingFieldsData
120
+ }, /*#__PURE__*/React.createElement("div", {
121
+ style: {
122
+ width: 372,
123
+ padding: '16px',
124
+ backgroundColor: 'lightgray'
125
+ }
126
+ }, /*#__PURE__*/React.createElement(AboutAOUnit, {
127
+ type: "visualization",
128
+ id: "missing456"
129
+ })));
130
+ MissingFields.story = {
131
+ name: 'Missing fields (no description, no author, no sharing)'
132
+ };
@@ -1,7 +1,7 @@
1
1
  import _JSXStyle from "styled-jsx/style";
2
2
  import { useDataQuery, useDataMutation, useTimeZoneConversion } from '@dhis2/app-runtime';
3
3
  import i18n from '@dhis2/d2-i18n';
4
- import { Button, CircularLoader, IconChevronDown24, IconChevronUp24, IconClock16, IconShare16, IconSubscribe24, IconSubscribeOff24, IconUser16, IconView16, colors } from '@dhis2/ui';
4
+ import { Button, CircularLoader, IconChevronDown24, IconChevronUp24, IconClock16, IconShare16, IconSubscribe16, IconSubscribeOff16, IconUser16, IconView16, colors } from '@dhis2/ui';
5
5
  import cx from 'classnames';
6
6
  import moment from 'moment';
7
7
  import PropTypes from 'prop-types';
@@ -139,8 +139,7 @@ const AboutAOUnit = /*#__PURE__*/forwardRef(({
139
139
  })), data && /*#__PURE__*/React.createElement("div", {
140
140
  className: `jsx-${styles.__hash}` + " " + "content"
141
141
  }, /*#__PURE__*/React.createElement("div", {
142
- className: `jsx-${styles.__hash}` + " " + (cx('detailLine', {
143
- description: true,
142
+ className: `jsx-${styles.__hash}` + " " + (cx('description', {
144
143
  noDescription: !data.ao.displayDescription
145
144
  }) || "")
146
145
  }, data.ao.displayDescription ? /*#__PURE__*/React.createElement(RichTextParser, null, data.ao.displayDescription) : /*#__PURE__*/React.createElement("p", {
@@ -149,28 +148,36 @@ const AboutAOUnit = /*#__PURE__*/forwardRef(({
149
148
  className: `jsx-${styles.__hash}`
150
149
  }, /*#__PURE__*/React.createElement("p", {
151
150
  className: `jsx-${styles.__hash}` + " " + "detailLine"
151
+ }, /*#__PURE__*/React.createElement("span", {
152
+ className: `jsx-${styles.__hash}` + " " + "icon"
152
153
  }, /*#__PURE__*/React.createElement(IconShare16, {
153
154
  color: colors.grey700
154
- }), getSharingSummary(data.ao)), /*#__PURE__*/React.createElement("p", {
155
+ })), getSharingSummary(data.ao)), /*#__PURE__*/React.createElement("p", {
155
156
  className: `jsx-${styles.__hash}` + " " + "detailLine"
157
+ }, /*#__PURE__*/React.createElement("span", {
158
+ className: `jsx-${styles.__hash}` + " " + "icon"
156
159
  }, /*#__PURE__*/React.createElement(IconClock16, {
157
160
  color: colors.grey700
158
- }), i18n.t('Last updated {{time}}', {
161
+ })), i18n.t('Last updated {{time}}', {
159
162
  time: moment(fromServerDate(data.ao.lastUpdated)).fromNow()
160
163
  })), /*#__PURE__*/React.createElement("p", {
161
164
  className: `jsx-${styles.__hash}` + " " + "detailLine"
165
+ }, /*#__PURE__*/React.createElement("span", {
166
+ className: `jsx-${styles.__hash}` + " " + "icon"
162
167
  }, /*#__PURE__*/React.createElement(IconUser16, {
163
168
  color: colors.grey700
164
- }), (_data$ao$createdBy = data.ao.createdBy) !== null && _data$ao$createdBy !== void 0 && _data$ao$createdBy.displayName ? i18n.t('Created {{time}} by {{author}}', {
169
+ })), (_data$ao$createdBy = data.ao.createdBy) !== null && _data$ao$createdBy !== void 0 && _data$ao$createdBy.displayName ? i18n.t('Created {{time}} by {{author}}', {
165
170
  time: moment(fromServerDate(data.ao.created)).fromNow(),
166
171
  author: data.ao.createdBy.displayName
167
172
  }) : i18n.t('Created {{time}}', {
168
173
  time: moment(fromServerDate(data.ao.created)).fromNow()
169
174
  })), /*#__PURE__*/React.createElement("p", {
170
175
  className: `jsx-${styles.__hash}` + " " + "detailLine"
176
+ }, /*#__PURE__*/React.createElement("span", {
177
+ className: `jsx-${styles.__hash}` + " " + "icon"
171
178
  }, /*#__PURE__*/React.createElement(IconView16, {
172
179
  color: colors.grey700
173
- }), i18n.t('Viewed {{count}} times', {
180
+ })), i18n.t('Viewed {{count}} times', {
174
181
  count: data.dataStatistics.views,
175
182
  defaultValue: 'Viewed 1 time',
176
183
  defaultValue_plural: 'Viewed {{count}} times'
@@ -181,7 +188,7 @@ const AboutAOUnit = /*#__PURE__*/forwardRef(({
181
188
  }, i18n.t('Notifications')), data.ao.subscribed ? /*#__PURE__*/React.createElement(React.Fragment, null, /*#__PURE__*/React.createElement("p", {
182
189
  className: `jsx-${styles.__hash}` + " " + "subscriptionLabel"
183
190
  }, i18n.t("You're subscribed and getting updates about new interpretations.")), /*#__PURE__*/React.createElement(Button, {
184
- icon: /*#__PURE__*/React.createElement(IconSubscribeOff24, {
191
+ icon: /*#__PURE__*/React.createElement(IconSubscribeOff16, {
185
192
  color: colors.grey700
186
193
  }),
187
194
  secondary: true,
@@ -191,7 +198,7 @@ const AboutAOUnit = /*#__PURE__*/forwardRef(({
191
198
  }, i18n.t('Unsubscribe'))) : /*#__PURE__*/React.createElement(React.Fragment, null, /*#__PURE__*/React.createElement("p", {
192
199
  className: `jsx-${styles.__hash}` + " " + "subscriptionLabel"
193
200
  }, i18n.t('Subscribe to get updates about new interpretations.')), /*#__PURE__*/React.createElement(Button, {
194
- icon: /*#__PURE__*/React.createElement(IconSubscribe24, {
201
+ icon: /*#__PURE__*/React.createElement(IconSubscribe16, {
195
202
  color: colors.grey700
196
203
  }),
197
204
  secondary: true,
@@ -1,4 +1,4 @@
1
1
  import { colors, spacers } from '@dhis2/ui';
2
- const _defaultExport = [`.container.jsx-3095370592{position:relative;padding:${spacers.dp16};border-bottom:1px solid ${colors.grey400};background-color:${colors.white};}`, `.expanded.jsx-3095370592{padding-bottom:${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:${colors.grey900};}`, `.content.jsx-3095370592{font-size:14px;line-height:18px;color:${colors.grey900};}`, `.detailLine.jsx-3095370592{display:-webkit-box;display:-webkit-flex;display:-ms-flexbox;display:flex;margin:0;padding:${spacers.dp12} 0 0 0;gap:${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:${colors.grey600};}`, `.subsection.jsx-3095370592{margin-top:${spacers.dp24};}`, `.subsectionTitle.jsx-3095370592{color:${colors.grey700};font-weight:500;}`, `.subscriptionLabel.jsx-3095370592{margin:${spacers.dp12} 0 ${spacers.dp8} 0;}`, `.subsection.jsx-3095370592 button.jsx-3095370592{margin-top:${spacers.dp8};}`];
3
- _defaultExport.__hash = "3095370592";
2
+ const _defaultExport = [`.container.jsx-3783470976{position:relative;padding:${spacers.dp16};border-bottom:1px solid ${colors.grey400};background-color:${colors.white};}`, `.expanded.jsx-3783470976{padding-bottom:${spacers.dp16};}`, `.loader.jsx-3783470976{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;padding-top:${spacers.dp16};}`, ".header.jsx-3783470976{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;-webkit-align-items:center;-webkit-box-align:center;-ms-flex-align:center;align-items:center;cursor:pointer;}", `.title.jsx-3783470976{font-size:16px;font-weight:500;line-height:21px;color:${colors.grey900};}`, `.content.jsx-3783470976{font-size:14px;line-height:20px;color:${colors.grey900};}`, `.detailLine.jsx-3783470976{display:-webkit-box;display:-webkit-flex;display:-ms-flexbox;display:flex;-webkit-align-items:flex-start;-webkit-box-align:flex-start;-ms-flex-align:flex-start;align-items:flex-start;margin:0;padding:${spacers.dp12} 0 0 0;gap:${spacers.dp8};}`, ".detailLine.jsx-3783470976 .icon.jsx-3783470976{-webkit-flex-shrink:0;-ms-flex-negative:0;flex-shrink:0;display:-webkit-box;display:-webkit-flex;display:-ms-flexbox;display:flex;-webkit-align-items:center;-webkit-box-align:center;-ms-flex-align:center;align-items:center;height:20px;}", ".description.jsx-3783470976{padding:0;}", `.description.jsx-3783470976 p{margin:${spacers.dp8} 0 ${spacers.dp4} 0;white-space:pre-line;}`, `.noDescription.jsx-3783470976{color:${colors.grey500};}`, `.subsection.jsx-3783470976{margin-top:${spacers.dp24};}`, `.subsectionTitle.jsx-3783470976{color:${colors.grey800};font-weight:500;margin:0;}`, `.subscriptionLabel.jsx-3783470976{font-size:13px;line-height:18px;margin:${spacers.dp4} 0 ${spacers.dp8} 0;color:${colors.grey600};}`];
3
+ _defaultExport.__hash = "3783470976";
4
4
  export default _defaultExport;
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@dhis2/analytics",
3
- "version": "29.4.2",
3
+ "version": "29.4.3",
4
4
  "main": "./build/cjs/index.js",
5
5
  "module": "./build/es/index.js",
6
6
  "exports": {
@@ -35,10 +35,8 @@
35
35
  "@dhis2/cli-style": "^10.7.9",
36
36
  "@dhis2/d2-i18n": "^1.1.0",
37
37
  "@dhis2/ui": "^10.12.7",
38
- "@mihkeleidast/storybook-addon-source": "^1.0.1",
39
- "@storybook/preset-create-react-app": "^8.3.6",
40
- "@storybook/react": "^8.3.6",
41
- "@storybook/react-webpack5": "^8.3.6",
38
+ "@storybook/preset-create-react-app": "^10.3.4",
39
+ "@storybook/react-webpack5": "^10.3.4",
42
40
  "@testing-library/dom": "^10.4.0",
43
41
  "@testing-library/jest-dom": "^6.6.3",
44
42
  "@testing-library/react": "^16.3.0",
@@ -48,8 +46,9 @@
48
46
  "react": "^18.3.1",
49
47
  "react-dom": "^18.3.1",
50
48
  "react-scripts": "^5.0.1",
51
- "storybook": "^8.3.6",
52
- "styled-jsx": "^4.0.1"
49
+ "storybook": "^10.3.4",
50
+ "styled-jsx": "^4.0.1",
51
+ "eslint-plugin-storybook": "10.3.4"
53
52
  },
54
53
  "peerDependencies": {
55
54
  "@dhis2/app-runtime": "^3",