@dhis2/analytics 22.0.0-alpha.3 → 23.0.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/CHANGELOG.md +3009 -0
- package/build/cjs/__demo__/OpenFileDialog.stories.js +39 -6
- package/build/cjs/__fixtures__/fixtures.js +1 -0
- package/build/cjs/__fixtures__/json/api/analytics/enrollments.json +206 -0
- package/build/cjs/api/analytics/Analytics.js +6 -0
- package/build/cjs/api/analytics/AnalyticsEnrollments.js +48 -0
- package/build/cjs/api/analytics/__tests__/AnalyticsEnrollments.spec.js +50 -0
- package/build/cjs/api/analytics/__tests__/__snapshots__/AnalyticsEnrollments.spec.js.snap +3 -0
- package/build/cjs/components/CachedDataQueryProvider.js +4 -10
- package/build/cjs/components/FileMenu/FileMenu.js +6 -0
- package/build/cjs/components/OpenFileDialog/CustomSelectOption.js +18 -4
- package/build/cjs/components/OpenFileDialog/FileList.js +5 -5
- package/build/cjs/components/OpenFileDialog/OpenFileDialog.js +26 -21
- package/build/cjs/components/OpenFileDialog/OpenFileDialog.styles.js +2 -2
- package/build/cjs/components/OpenFileDialog/VisTypeFilter.js +17 -16
- package/build/cjs/components/OpenFileDialog/utils.js +33 -74
- package/build/cjs/index.js +16 -4
- package/build/cjs/locales/ar/translations.json +9 -0
- package/build/cjs/locales/ar_EG/translations.json +9 -0
- package/build/cjs/locales/ar_IQ/translations.json +9 -0
- package/build/cjs/locales/ckb/translations.json +9 -0
- package/build/cjs/locales/cs/translations.json +9 -0
- package/build/cjs/locales/da/translations.json +9 -0
- package/build/cjs/locales/en/translations.json +3 -21
- package/build/cjs/locales/es/translations.json +9 -0
- package/build/cjs/locales/fr/translations.json +9 -0
- package/build/cjs/locales/id/translations.json +9 -0
- package/build/cjs/locales/km/translations.json +9 -0
- package/build/cjs/locales/lo/translations.json +9 -0
- package/build/cjs/locales/my/translations.json +9 -0
- package/build/cjs/locales/nb/translations.json +9 -0
- package/build/cjs/locales/nl/translations.json +9 -0
- package/build/cjs/locales/prs/translations.json +9 -0
- package/build/cjs/locales/ps/translations.json +9 -0
- package/build/cjs/locales/pt/translations.json +9 -0
- package/build/cjs/locales/pt_BR/translations.json +9 -0
- package/build/cjs/locales/ru/translations.json +9 -0
- package/build/cjs/locales/sv/translations.json +9 -0
- package/build/cjs/locales/tet/translations.json +9 -0
- package/build/cjs/locales/tg/translations.json +9 -0
- package/build/cjs/locales/uk/translations.json +9 -0
- package/build/cjs/locales/ur/translations.json +9 -0
- package/build/cjs/locales/uz/translations.json +9 -0
- package/build/cjs/locales/uz_Latn/translations.json +9 -0
- package/build/cjs/locales/vi/translations.json +9 -0
- package/build/cjs/locales/zh/translations.json +10 -1
- package/build/cjs/locales/zh_CN/translations.json +9 -0
- package/build/cjs/modules/layoutUiRules/rules.js +5 -1
- package/build/cjs/modules/visTypes.js +14 -21
- package/build/es/__demo__/OpenFileDialog.stories.js +38 -6
- package/build/es/__fixtures__/fixtures.js +1 -0
- package/build/es/__fixtures__/json/api/analytics/enrollments.json +206 -0
- package/build/es/api/analytics/Analytics.js +5 -0
- package/build/es/api/analytics/AnalyticsEnrollments.js +38 -0
- package/build/es/api/analytics/__tests__/AnalyticsEnrollments.spec.js +40 -0
- package/build/es/api/analytics/__tests__/__snapshots__/AnalyticsEnrollments.spec.js.snap +3 -0
- package/build/es/components/CachedDataQueryProvider.js +4 -10
- package/build/es/components/FileMenu/FileMenu.js +6 -0
- package/build/es/components/OpenFileDialog/CustomSelectOption.js +17 -4
- package/build/es/components/OpenFileDialog/FileList.js +5 -5
- package/build/es/components/OpenFileDialog/OpenFileDialog.js +27 -23
- package/build/es/components/OpenFileDialog/OpenFileDialog.styles.js +2 -2
- package/build/es/components/OpenFileDialog/VisTypeFilter.js +18 -14
- package/build/es/components/OpenFileDialog/utils.js +32 -71
- package/build/es/index.js +1 -1
- package/build/es/locales/ar/translations.json +9 -0
- package/build/es/locales/ar_EG/translations.json +9 -0
- package/build/es/locales/ar_IQ/translations.json +9 -0
- package/build/es/locales/ckb/translations.json +9 -0
- package/build/es/locales/cs/translations.json +9 -0
- package/build/es/locales/da/translations.json +9 -0
- package/build/es/locales/en/translations.json +3 -21
- package/build/es/locales/es/translations.json +9 -0
- package/build/es/locales/fr/translations.json +9 -0
- package/build/es/locales/id/translations.json +9 -0
- package/build/es/locales/km/translations.json +9 -0
- package/build/es/locales/lo/translations.json +9 -0
- package/build/es/locales/my/translations.json +9 -0
- package/build/es/locales/nb/translations.json +9 -0
- package/build/es/locales/nl/translations.json +9 -0
- package/build/es/locales/prs/translations.json +9 -0
- package/build/es/locales/ps/translations.json +9 -0
- package/build/es/locales/pt/translations.json +9 -0
- package/build/es/locales/pt_BR/translations.json +9 -0
- package/build/es/locales/ru/translations.json +9 -0
- package/build/es/locales/sv/translations.json +9 -0
- package/build/es/locales/tet/translations.json +9 -0
- package/build/es/locales/tg/translations.json +9 -0
- package/build/es/locales/uk/translations.json +9 -0
- package/build/es/locales/ur/translations.json +9 -0
- package/build/es/locales/uz/translations.json +9 -0
- package/build/es/locales/uz_Latn/translations.json +9 -0
- package/build/es/locales/vi/translations.json +9 -0
- package/build/es/locales/zh/translations.json +10 -1
- package/build/es/locales/zh_CN/translations.json +9 -0
- package/build/es/modules/layoutUiRules/rules.js +6 -2
- package/build/es/modules/visTypes.js +10 -19
- package/package.json +2 -2
- package/build/cjs/components/OpenFileDialog/styles/FileList.style.js +0 -10
- package/build/cjs/visualizations/package-lock.json +0 -1788
- package/build/es/components/OpenFileDialog/styles/FileList.style.js +0 -3
- package/build/es/visualizations/package-lock.json +0 -1788
|
@@ -19,6 +19,8 @@ var _propTypes = _interopRequireDefault(require("prop-types"));
|
|
|
19
19
|
|
|
20
20
|
var _react = _interopRequireWildcard(require("react"));
|
|
21
21
|
|
|
22
|
+
var _visTypes = require("../../modules/visTypes.js");
|
|
23
|
+
|
|
22
24
|
var _CreatedByFilter = require("./CreatedByFilter.js");
|
|
23
25
|
|
|
24
26
|
var _FileList = require("./FileList.js");
|
|
@@ -68,6 +70,8 @@ const getQuery = type => ({
|
|
|
68
70
|
const OpenFileDialog = ({
|
|
69
71
|
type,
|
|
70
72
|
open,
|
|
73
|
+
filterVisTypes,
|
|
74
|
+
defaultFilterVisType,
|
|
71
75
|
onClose,
|
|
72
76
|
onFileSelect,
|
|
73
77
|
onNew,
|
|
@@ -77,7 +81,7 @@ const OpenFileDialog = ({
|
|
|
77
81
|
const defaultFilters = {
|
|
78
82
|
searchTerm: '',
|
|
79
83
|
createdBy: _CreatedByFilter.CREATED_BY_ALL,
|
|
80
|
-
visType:
|
|
84
|
+
visType: defaultFilterVisType
|
|
81
85
|
};
|
|
82
86
|
const [{
|
|
83
87
|
sortField,
|
|
@@ -108,26 +112,23 @@ const OpenFileDialog = ({
|
|
|
108
112
|
break;
|
|
109
113
|
}
|
|
110
114
|
|
|
111
|
-
|
|
112
|
-
|
|
113
|
-
|
|
115
|
+
if (filters.visType) {
|
|
116
|
+
switch (filters.visType) {
|
|
117
|
+
case _visTypes.VIS_TYPE_GROUP_ALL:
|
|
118
|
+
break;
|
|
114
119
|
|
|
115
|
-
|
|
116
|
-
|
|
117
|
-
|
|
120
|
+
case _visTypes.VIS_TYPE_GROUP_CHARTS:
|
|
121
|
+
queryFilters.push('type:!eq:PIVOT_TABLE');
|
|
122
|
+
break;
|
|
118
123
|
|
|
119
|
-
|
|
120
|
-
|
|
121
|
-
|
|
124
|
+
default:
|
|
125
|
+
queryFilters.push("type:eq:".concat(filters.visType));
|
|
126
|
+
break;
|
|
127
|
+
}
|
|
122
128
|
}
|
|
123
129
|
|
|
124
130
|
if (filters.searchTerm) {
|
|
125
131
|
queryFilters.push("name:ilike:".concat(filters.searchTerm));
|
|
126
|
-
} // for ER 2.38 only show line list ER types
|
|
127
|
-
|
|
128
|
-
|
|
129
|
-
if (type === _utils.AO_TYPE_EVENT_REPORT || type === _utils.AO_TYPE_EVENT_VISUALIZATION) {
|
|
130
|
-
queryFilters.push('dataType:eq:EVENTS');
|
|
131
132
|
}
|
|
132
133
|
|
|
133
134
|
return queryFilters;
|
|
@@ -153,7 +154,8 @@ const OpenFileDialog = ({
|
|
|
153
154
|
refetch({
|
|
154
155
|
page,
|
|
155
156
|
sortField,
|
|
156
|
-
sortDirection
|
|
157
|
+
sortDirection,
|
|
158
|
+
filters: formatFilters()
|
|
157
159
|
});
|
|
158
160
|
}
|
|
159
161
|
}, [open, page, sortField, sortDirection]);
|
|
@@ -183,7 +185,7 @@ const OpenFileDialog = ({
|
|
|
183
185
|
width: '110px'
|
|
184
186
|
}];
|
|
185
187
|
|
|
186
|
-
if (
|
|
188
|
+
if (filterVisTypes !== null && filterVisTypes !== void 0 && filterVisTypes.length) {
|
|
187
189
|
headers.splice(1, 0, {
|
|
188
190
|
field: 'type',
|
|
189
191
|
label: _d2I18n.default.t('Type'),
|
|
@@ -216,9 +218,10 @@ const OpenFileDialog = ({
|
|
|
216
218
|
searchTerm: value
|
|
217
219
|
}), 200));
|
|
218
220
|
}
|
|
219
|
-
})),
|
|
221
|
+
})), (filterVisTypes === null || filterVisTypes === void 0 ? void 0 : filterVisTypes.length) && /*#__PURE__*/_react.default.createElement("div", {
|
|
220
222
|
className: "jsx-".concat(_OpenFileDialogStyles.styles.__hash) + " " + "type-field-container"
|
|
221
223
|
}, /*#__PURE__*/_react.default.createElement(_VisTypeFilter.VisTypeFilter, {
|
|
224
|
+
visTypes: filterVisTypes,
|
|
222
225
|
selected: filters.visType,
|
|
223
226
|
onChange: value => setFilters({ ...filters,
|
|
224
227
|
visType: value
|
|
@@ -287,9 +290,9 @@ const OpenFileDialog = ({
|
|
|
287
290
|
onClose();
|
|
288
291
|
}
|
|
289
292
|
}, (0, _utils.getTranslatedString)(type, 'newButtonLabel'))))))))), (data === null || data === void 0 ? void 0 : data.files[_utils.AOTypeMap[type].apiEndpoint].length) > 0 && /*#__PURE__*/_react.default.createElement(_FileList.FileList, {
|
|
290
|
-
type: type,
|
|
291
293
|
data: data.files[_utils.AOTypeMap[type].apiEndpoint],
|
|
292
|
-
onSelect: onFileSelect
|
|
294
|
+
onSelect: onFileSelect,
|
|
295
|
+
showVisTypeColumn: Boolean(filterVisTypes === null || filterVisTypes === void 0 ? void 0 : filterVisTypes.length)
|
|
293
296
|
}))), (data === null || data === void 0 ? void 0 : data.files[_utils.AOTypeMap[type].apiEndpoint].length) > 0 && /*#__PURE__*/_react.default.createElement(_ui.DataTableToolbar, {
|
|
294
297
|
position: "bottom"
|
|
295
298
|
}, /*#__PURE__*/_react.default.createElement("div", {
|
|
@@ -310,7 +313,9 @@ OpenFileDialog.propTypes = {
|
|
|
310
313
|
type: _propTypes.default.oneOf(Object.keys(_utils.AOTypeMap)).isRequired,
|
|
311
314
|
onClose: _propTypes.default.func.isRequired,
|
|
312
315
|
onFileSelect: _propTypes.default.func.isRequired,
|
|
313
|
-
onNew: _propTypes.default.func.isRequired
|
|
316
|
+
onNew: _propTypes.default.func.isRequired,
|
|
317
|
+
defaultFilterVisType: _propTypes.default.string,
|
|
318
|
+
filterVisTypes: _propTypes.default.array
|
|
314
319
|
};
|
|
315
320
|
var _default = OpenFileDialog;
|
|
316
321
|
exports.default = _default;
|
|
@@ -7,6 +7,6 @@ exports.styles = void 0;
|
|
|
7
7
|
|
|
8
8
|
var _ui = require("@dhis2/ui");
|
|
9
9
|
|
|
10
|
-
const styles = [".data-table-body.jsx-
|
|
10
|
+
const styles = [".data-table-body.jsx-1047699013{min-height:465px;}", ".pagination-controls.jsx-1047699013{width:100%;display:-webkit-box;display:-webkit-flex;display:-ms-flexbox;display:flex;-webkit-box-pack:end;-webkit-justify-content:flex-end;-ms-flex-pack:end;justify-content:flex-end;}", ".search-and-filter-bar.jsx-1047699013{display:-webkit-box;display:-webkit-flex;display:-ms-flexbox;display:flex;gap:".concat(_ui.spacers.dp4, ";-webkit-align-items:center;-webkit-box-align:center;-ms-flex-align:center;align-items:center;margin-bottom:").concat(_ui.spacers.dp8, ";}"), ".search-field-container.jsx-1047699013{min-width:220px;}", ".type-field-container.jsx-1047699013,.created-by-field-container.jsx-1047699013{min-width:180px;}", ".info-cell.jsx-1047699013{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;-webkit-box-pack:center;-webkit-justify-content:center;-ms-flex-pack:center;justify-content:center;margin:".concat(_ui.spacers.dp32, " 0;}"), ".info-container.jsx-1047699013{max-width:400px;display:-webkit-box;display:-webkit-flex;display:-ms-flexbox;display:flex;-webkit-flex-direction:column;-ms-flex-direction:column;flex-direction:column;-webkit-align-items:center;-webkit-box-align:center;-ms-flex-align:center;align-items:center;-webkit-box-pack:center;-webkit-justify-content:center;-ms-flex-pack:center;justify-content:center;}", ".info-text.jsx-1047699013{text-align:center;font-size:14px;line-height:19px;color:".concat(_ui.colors.grey700, ";}"), ".info-button.jsx-1047699013{margin-top:".concat(_ui.spacers.dp12, ";}")];
|
|
11
11
|
exports.styles = styles;
|
|
12
|
-
styles.__hash = "
|
|
12
|
+
styles.__hash = "1047699013";
|
|
@@ -3,7 +3,7 @@
|
|
|
3
3
|
Object.defineProperty(exports, "__esModule", {
|
|
4
4
|
value: true
|
|
5
5
|
});
|
|
6
|
-
exports.default = exports.VisTypeFilter =
|
|
6
|
+
exports.default = exports.VisTypeFilter = void 0;
|
|
7
7
|
|
|
8
8
|
var _d2I18n = _interopRequireDefault(require("@dhis2/d2-i18n"));
|
|
9
9
|
|
|
@@ -21,12 +21,8 @@ var _CustomSelectOption = require("./CustomSelectOption.js");
|
|
|
21
21
|
|
|
22
22
|
function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; }
|
|
23
23
|
|
|
24
|
-
const VIS_TYPE_ALL = 'all';
|
|
25
|
-
exports.VIS_TYPE_ALL = VIS_TYPE_ALL;
|
|
26
|
-
const VIS_TYPE_CHARTS = 'charts';
|
|
27
|
-
exports.VIS_TYPE_CHARTS = VIS_TYPE_CHARTS;
|
|
28
|
-
|
|
29
24
|
const VisTypeFilter = ({
|
|
25
|
+
visTypes,
|
|
30
26
|
selected,
|
|
31
27
|
onChange
|
|
32
28
|
}) => /*#__PURE__*/_react.default.createElement(_ui.SingleSelect, {
|
|
@@ -37,26 +33,31 @@ const VisTypeFilter = ({
|
|
|
37
33
|
prefix: _d2I18n.default.t('Type'),
|
|
38
34
|
dense: true,
|
|
39
35
|
maxHeight: "400px"
|
|
40
|
-
},
|
|
41
|
-
|
|
42
|
-
|
|
43
|
-
|
|
44
|
-
|
|
45
|
-
value: VIS_TYPE_CHARTS
|
|
46
|
-
}), /*#__PURE__*/_react.default.createElement(_ui.Divider, null), Object.entries(_visTypes.visTypeDisplayNames).map(([type, label]) => /*#__PURE__*/_react.default.createElement(_CustomSelectOption.CustomSelectOption, {
|
|
36
|
+
}, visTypes === null || visTypes === void 0 ? void 0 : visTypes.map(({
|
|
37
|
+
type,
|
|
38
|
+
disabled,
|
|
39
|
+
insertDivider
|
|
40
|
+
}) => /*#__PURE__*/_react.default.createElement(_CustomSelectOption.CustomSelectOption, {
|
|
47
41
|
key: type,
|
|
48
|
-
|
|
42
|
+
disabled: disabled,
|
|
43
|
+
label: (0, _visTypes.getDisplayNameByVisType)(type),
|
|
44
|
+
insertDivider: insertDivider,
|
|
49
45
|
value: type,
|
|
50
|
-
icon: /*#__PURE__*/_react.default.createElement(_VisTypeIcon.VisTypeIcon, {
|
|
46
|
+
icon: _visTypes.visTypeIcons[type] ? /*#__PURE__*/_react.default.createElement(_VisTypeIcon.VisTypeIcon, {
|
|
51
47
|
type: type,
|
|
52
48
|
useSmall: true,
|
|
53
49
|
color: _ui.colors.grey600
|
|
54
|
-
})
|
|
50
|
+
}) : undefined
|
|
55
51
|
})));
|
|
56
52
|
|
|
57
53
|
exports.VisTypeFilter = VisTypeFilter;
|
|
58
54
|
VisTypeFilter.propTypes = {
|
|
59
55
|
selected: _propTypes.default.string,
|
|
56
|
+
visTypes: _propTypes.default.arrayOf(_propTypes.default.shape({
|
|
57
|
+
disabled: _propTypes.default.bool,
|
|
58
|
+
insertDivider: _propTypes.default.bool,
|
|
59
|
+
type: _propTypes.default.string
|
|
60
|
+
})),
|
|
60
61
|
onChange: _propTypes.default.func
|
|
61
62
|
};
|
|
62
63
|
var _default = VisTypeFilter;
|
|
@@ -3,7 +3,7 @@
|
|
|
3
3
|
Object.defineProperty(exports, "__esModule", {
|
|
4
4
|
value: true
|
|
5
5
|
});
|
|
6
|
-
exports.getTranslatedString = exports.AOTypeMap = exports.AO_TYPE_EVENT_VISUALIZATION = exports.
|
|
6
|
+
exports.getTranslatedString = exports.AOTypeMap = exports.AO_TYPE_EVENT_VISUALIZATION = exports.AO_TYPE_MAP = exports.AO_TYPE_VISUALIZATION = void 0;
|
|
7
7
|
|
|
8
8
|
var _d2I18n = _interopRequireDefault(require("@dhis2/d2-i18n"));
|
|
9
9
|
|
|
@@ -13,10 +13,6 @@ const AO_TYPE_VISUALIZATION = 'visualization';
|
|
|
13
13
|
exports.AO_TYPE_VISUALIZATION = AO_TYPE_VISUALIZATION;
|
|
14
14
|
const AO_TYPE_MAP = 'map';
|
|
15
15
|
exports.AO_TYPE_MAP = AO_TYPE_MAP;
|
|
16
|
-
const AO_TYPE_EVENT_CHART = 'eventChart';
|
|
17
|
-
exports.AO_TYPE_EVENT_CHART = AO_TYPE_EVENT_CHART;
|
|
18
|
-
const AO_TYPE_EVENT_REPORT = 'eventReport';
|
|
19
|
-
exports.AO_TYPE_EVENT_REPORT = AO_TYPE_EVENT_REPORT;
|
|
20
16
|
const AO_TYPE_EVENT_VISUALIZATION = 'eventVisualization';
|
|
21
17
|
exports.AO_TYPE_EVENT_VISUALIZATION = AO_TYPE_EVENT_VISUALIZATION;
|
|
22
18
|
const AOTypeMap = {
|
|
@@ -26,20 +22,14 @@ const AOTypeMap = {
|
|
|
26
22
|
[AO_TYPE_MAP]: {
|
|
27
23
|
apiEndpoint: 'maps'
|
|
28
24
|
},
|
|
29
|
-
[AO_TYPE_EVENT_CHART]: {
|
|
30
|
-
apiEndpoint: 'eventCharts'
|
|
31
|
-
},
|
|
32
|
-
[AO_TYPE_EVENT_REPORT]: {
|
|
33
|
-
apiEndpoint: 'eventReports'
|
|
34
|
-
},
|
|
35
25
|
[AO_TYPE_EVENT_VISUALIZATION]: {
|
|
36
26
|
apiEndpoint: 'eventVisualizations'
|
|
37
27
|
}
|
|
38
28
|
};
|
|
39
29
|
exports.AOTypeMap = AOTypeMap;
|
|
40
|
-
|
|
41
|
-
const
|
|
42
|
-
|
|
30
|
+
const NO_TYPE = 'NO_TYPE';
|
|
31
|
+
const texts = {
|
|
32
|
+
[NO_TYPE]: {
|
|
43
33
|
modalTitle: _d2I18n.default.t('Open'),
|
|
44
34
|
loadingText: _d2I18n.default.t('Loading'),
|
|
45
35
|
errorTitle: _d2I18n.default.t("Couldn't load items"),
|
|
@@ -47,67 +37,36 @@ const getTranslatedString = (type, key) => {
|
|
|
47
37
|
noDataText: _d2I18n.default.t('No items found. Create a new to get started.'),
|
|
48
38
|
noFilteredDataText: _d2I18n.default.t("No items found. Try adjusting your search or filter options to find what you're looking for."),
|
|
49
39
|
newButtonLabel: _d2I18n.default.t('Create new')
|
|
50
|
-
}
|
|
51
|
-
|
|
52
|
-
|
|
53
|
-
|
|
54
|
-
|
|
55
|
-
|
|
56
|
-
|
|
57
|
-
|
|
58
|
-
|
|
59
|
-
|
|
60
|
-
|
|
61
|
-
|
|
62
|
-
|
|
63
|
-
|
|
64
|
-
|
|
65
|
-
|
|
66
|
-
|
|
67
|
-
|
|
68
|
-
|
|
69
|
-
|
|
70
|
-
|
|
71
|
-
|
|
72
|
-
|
|
73
|
-
|
|
74
|
-
|
|
75
|
-
|
|
76
|
-
|
|
77
|
-
};
|
|
78
|
-
break;
|
|
79
|
-
}
|
|
80
|
-
|
|
81
|
-
case 'eventReport':
|
|
82
|
-
{
|
|
83
|
-
texts = {
|
|
84
|
-
modalTitle: _d2I18n.default.t('Open an event report'),
|
|
85
|
-
loadingText: _d2I18n.default.t('Loading event reports'),
|
|
86
|
-
errorTitle: _d2I18n.default.t("Couldn't load event reports"),
|
|
87
|
-
errorText: _d2I18n.default.t('There was a problem loading event reports. Try again or contact your system administrator.'),
|
|
88
|
-
noDataText: _d2I18n.default.t('No event reports found. Click New event report to get started.'),
|
|
89
|
-
noFilteredDataText: _d2I18n.default.t("No event reports found. Try adjusting your search or filter options to find what you're looking for."),
|
|
90
|
-
newButtonLabel: _d2I18n.default.t('New event report')
|
|
91
|
-
};
|
|
92
|
-
break;
|
|
93
|
-
}
|
|
94
|
-
|
|
95
|
-
case 'eventVisualization':
|
|
96
|
-
{
|
|
97
|
-
texts = {
|
|
98
|
-
modalTitle: _d2I18n.default.t('Open an event visualization'),
|
|
99
|
-
loadingText: _d2I18n.default.t('Loading event visualizations'),
|
|
100
|
-
errorTitle: _d2I18n.default.t("Couldn't load event visualizations"),
|
|
101
|
-
errorText: _d2I18n.default.t('There was a problem loading event visualizations. Try again or contact your system administrator.'),
|
|
102
|
-
noDataText: _d2I18n.default.t('No event visualizations found. Click New event visualization to get started.'),
|
|
103
|
-
noFilteredDataText: _d2I18n.default.t("No event visualizations found. Try adjusting your search or filter options to find what you're looking for."),
|
|
104
|
-
newButtonLabel: _d2I18n.default.t('New event visualization')
|
|
105
|
-
};
|
|
106
|
-
break;
|
|
107
|
-
}
|
|
40
|
+
},
|
|
41
|
+
[AO_TYPE_VISUALIZATION]: {
|
|
42
|
+
modalTitle: _d2I18n.default.t('Open a visualization'),
|
|
43
|
+
loadingText: _d2I18n.default.t('Loading visualizations'),
|
|
44
|
+
errorTitle: _d2I18n.default.t("Couldn't load visualizations"),
|
|
45
|
+
errorText: _d2I18n.default.t('There was a problem loading visualizations. Try again or contact your system administrator.'),
|
|
46
|
+
noDataText: _d2I18n.default.t('No visualizations found. Click New visualization to get started.'),
|
|
47
|
+
noFilteredDataText: _d2I18n.default.t("No visualizations found. Try adjusting your search or filter options to find what you're looking for."),
|
|
48
|
+
newButtonLabel: _d2I18n.default.t('New visualization')
|
|
49
|
+
},
|
|
50
|
+
[AO_TYPE_MAP]: {
|
|
51
|
+
modalTitle: _d2I18n.default.t('Open a map'),
|
|
52
|
+
loadingText: _d2I18n.default.t('Loading maps'),
|
|
53
|
+
errorTitle: _d2I18n.default.t("Couldn't load maps"),
|
|
54
|
+
errorText: _d2I18n.default.t('There was a problem loading maps. Try again or contact your system administrator.'),
|
|
55
|
+
noDataText: _d2I18n.default.t('No maps found. Click New map to get started.'),
|
|
56
|
+
noFilteredDataText: _d2I18n.default.t("No maps found. Try adjusting your search or filter options to find what you're looking for."),
|
|
57
|
+
newButtonLabel: _d2I18n.default.t('New map')
|
|
58
|
+
},
|
|
59
|
+
[AO_TYPE_EVENT_VISUALIZATION]: {
|
|
60
|
+
modalTitle: _d2I18n.default.t('Open an event visualization'),
|
|
61
|
+
loadingText: _d2I18n.default.t('Loading event visualizations'),
|
|
62
|
+
errorTitle: _d2I18n.default.t("Couldn't load event visualizations"),
|
|
63
|
+
errorText: _d2I18n.default.t('There was a problem loading event visualizations. Try again or contact your system administrator.'),
|
|
64
|
+
noDataText: _d2I18n.default.t('No event visualizations found. Click New event visualization to get started.'),
|
|
65
|
+
noFilteredDataText: _d2I18n.default.t("No event visualizations found. Try adjusting your search or filter options to find what you're looking for."),
|
|
66
|
+
newButtonLabel: _d2I18n.default.t('New event visualization')
|
|
108
67
|
}
|
|
109
|
-
|
|
110
|
-
return texts[key];
|
|
111
68
|
};
|
|
112
69
|
|
|
70
|
+
const getTranslatedString = (type, key) => (texts[type] || texts[NO_TYPE])[key];
|
|
71
|
+
|
|
113
72
|
exports.getTranslatedString = getTranslatedString;
|
package/build/cjs/index.js
CHANGED
|
@@ -537,6 +537,18 @@ Object.defineProperty(exports, "getLayoutTypeByVisType", {
|
|
|
537
537
|
return _visTypeToLayoutType.getLayoutTypeByVisType;
|
|
538
538
|
}
|
|
539
539
|
});
|
|
540
|
+
Object.defineProperty(exports, "VIS_TYPE_GROUP_ALL", {
|
|
541
|
+
enumerable: true,
|
|
542
|
+
get: function () {
|
|
543
|
+
return _visTypes.VIS_TYPE_GROUP_ALL;
|
|
544
|
+
}
|
|
545
|
+
});
|
|
546
|
+
Object.defineProperty(exports, "VIS_TYPE_GROUP_CHARTS", {
|
|
547
|
+
enumerable: true,
|
|
548
|
+
get: function () {
|
|
549
|
+
return _visTypes.VIS_TYPE_GROUP_CHARTS;
|
|
550
|
+
}
|
|
551
|
+
});
|
|
540
552
|
Object.defineProperty(exports, "VIS_TYPE_COLUMN", {
|
|
541
553
|
enumerable: true,
|
|
542
554
|
get: function () {
|
|
@@ -633,16 +645,16 @@ Object.defineProperty(exports, "VIS_TYPE_SCATTER", {
|
|
|
633
645
|
return _visTypes.VIS_TYPE_SCATTER;
|
|
634
646
|
}
|
|
635
647
|
});
|
|
636
|
-
Object.defineProperty(exports, "
|
|
648
|
+
Object.defineProperty(exports, "VIS_TYPE_LINE_LIST", {
|
|
637
649
|
enumerable: true,
|
|
638
650
|
get: function () {
|
|
639
|
-
return _visTypes.
|
|
651
|
+
return _visTypes.VIS_TYPE_LINE_LIST;
|
|
640
652
|
}
|
|
641
653
|
});
|
|
642
|
-
Object.defineProperty(exports, "
|
|
654
|
+
Object.defineProperty(exports, "visTypeDisplayNames", {
|
|
643
655
|
enumerable: true,
|
|
644
656
|
get: function () {
|
|
645
|
-
return _visTypes.
|
|
657
|
+
return _visTypes.visTypeDisplayNames;
|
|
646
658
|
}
|
|
647
659
|
});
|
|
648
660
|
Object.defineProperty(exports, "visTypeIcons", {
|
|
@@ -20,6 +20,8 @@
|
|
|
20
20
|
"Unsubscribe": "",
|
|
21
21
|
"Subscribe to get updates about new interpretations.": "",
|
|
22
22
|
"Subscribe": "",
|
|
23
|
+
"This app could not retrieve required data.": "",
|
|
24
|
+
"Network error": "",
|
|
23
25
|
"Data Type": "نوع البيانات",
|
|
24
26
|
"All types": "جميع الأنواع",
|
|
25
27
|
"Totals only": "",
|
|
@@ -119,6 +121,13 @@
|
|
|
119
121
|
"No event reports found. Click New event report to get started.": "",
|
|
120
122
|
"No event reports found. Try adjusting your search or filter options to find what you're looking for.": "",
|
|
121
123
|
"New event report": "",
|
|
124
|
+
"Open an event visualization": "",
|
|
125
|
+
"Loading event visualizations": "",
|
|
126
|
+
"Couldn't load event visualizations": "",
|
|
127
|
+
"There was a problem loading event visualizations. Try again or contact your system administrator.": "",
|
|
128
|
+
"No event visualizations found. Click New event visualization to get started.": "",
|
|
129
|
+
"No event visualizations found. Try adjusting your search or filter options to find what you're looking for.": "",
|
|
130
|
+
"New event visualization": "",
|
|
122
131
|
"Options": "الخيارات",
|
|
123
132
|
"Hide": "إخفاء",
|
|
124
133
|
"Update": "تحديث",
|
|
@@ -20,6 +20,8 @@
|
|
|
20
20
|
"Unsubscribe": "",
|
|
21
21
|
"Subscribe to get updates about new interpretations.": "",
|
|
22
22
|
"Subscribe": "",
|
|
23
|
+
"This app could not retrieve required data.": "",
|
|
24
|
+
"Network error": "",
|
|
23
25
|
"Data Type": "",
|
|
24
26
|
"All types": "",
|
|
25
27
|
"Totals only": "",
|
|
@@ -119,6 +121,13 @@
|
|
|
119
121
|
"No event reports found. Click New event report to get started.": "",
|
|
120
122
|
"No event reports found. Try adjusting your search or filter options to find what you're looking for.": "",
|
|
121
123
|
"New event report": "",
|
|
124
|
+
"Open an event visualization": "",
|
|
125
|
+
"Loading event visualizations": "",
|
|
126
|
+
"Couldn't load event visualizations": "",
|
|
127
|
+
"There was a problem loading event visualizations. Try again or contact your system administrator.": "",
|
|
128
|
+
"No event visualizations found. Click New event visualization to get started.": "",
|
|
129
|
+
"No event visualizations found. Try adjusting your search or filter options to find what you're looking for.": "",
|
|
130
|
+
"New event visualization": "",
|
|
122
131
|
"Options": "",
|
|
123
132
|
"Hide": "",
|
|
124
133
|
"Update": "",
|
|
@@ -20,6 +20,8 @@
|
|
|
20
20
|
"Unsubscribe": "",
|
|
21
21
|
"Subscribe to get updates about new interpretations.": "",
|
|
22
22
|
"Subscribe": "",
|
|
23
|
+
"This app could not retrieve required data.": "",
|
|
24
|
+
"Network error": "",
|
|
23
25
|
"Data Type": "",
|
|
24
26
|
"All types": "",
|
|
25
27
|
"Totals only": "",
|
|
@@ -119,6 +121,13 @@
|
|
|
119
121
|
"No event reports found. Click New event report to get started.": "",
|
|
120
122
|
"No event reports found. Try adjusting your search or filter options to find what you're looking for.": "",
|
|
121
123
|
"New event report": "",
|
|
124
|
+
"Open an event visualization": "",
|
|
125
|
+
"Loading event visualizations": "",
|
|
126
|
+
"Couldn't load event visualizations": "",
|
|
127
|
+
"There was a problem loading event visualizations. Try again or contact your system administrator.": "",
|
|
128
|
+
"No event visualizations found. Click New event visualization to get started.": "",
|
|
129
|
+
"No event visualizations found. Try adjusting your search or filter options to find what you're looking for.": "",
|
|
130
|
+
"New event visualization": "",
|
|
122
131
|
"Options": "الخيارات",
|
|
123
132
|
"Hide": "إخفاء",
|
|
124
133
|
"Update": "تحديث",
|
|
@@ -16,6 +16,8 @@
|
|
|
16
16
|
"Unsubscribe": "",
|
|
17
17
|
"Subscribe to get updates about new interpretations.": "",
|
|
18
18
|
"Subscribe": "",
|
|
19
|
+
"This app could not retrieve required data.": "",
|
|
20
|
+
"Network error": "",
|
|
19
21
|
"Data Type": "",
|
|
20
22
|
"All types": "",
|
|
21
23
|
"Totals only": "",
|
|
@@ -115,6 +117,13 @@
|
|
|
115
117
|
"No event reports found. Click New event report to get started.": "",
|
|
116
118
|
"No event reports found. Try adjusting your search or filter options to find what you're looking for.": "",
|
|
117
119
|
"New event report": "",
|
|
120
|
+
"Open an event visualization": "",
|
|
121
|
+
"Loading event visualizations": "",
|
|
122
|
+
"Couldn't load event visualizations": "",
|
|
123
|
+
"There was a problem loading event visualizations. Try again or contact your system administrator.": "",
|
|
124
|
+
"No event visualizations found. Click New event visualization to get started.": "",
|
|
125
|
+
"No event visualizations found. Try adjusting your search or filter options to find what you're looking for.": "",
|
|
126
|
+
"New event visualization": "",
|
|
118
127
|
"Options": "",
|
|
119
128
|
"Hide": "شاردنەوە",
|
|
120
129
|
"Update": "نوێ کردنەوە",
|
|
@@ -18,6 +18,8 @@
|
|
|
18
18
|
"Unsubscribe": "Odhlásit odběr",
|
|
19
19
|
"Subscribe to get updates about new interpretations.": "Přihlaste se k odběru novinek o nových interpretacích.",
|
|
20
20
|
"Subscribe": "Odebírat",
|
|
21
|
+
"This app could not retrieve required data.": "",
|
|
22
|
+
"Network error": "",
|
|
21
23
|
"Data Type": "Typ dat",
|
|
22
24
|
"All types": "Všechny typy",
|
|
23
25
|
"Totals only": "Pouze součty",
|
|
@@ -117,6 +119,13 @@
|
|
|
117
119
|
"No event reports found. Click New event report to get started.": "Nebyly nalezeny žádné zprávy o událostech. Začněte kliknutím na Nový přehled událostí.",
|
|
118
120
|
"No event reports found. Try adjusting your search or filter options to find what you're looking for.": "Nebyly nalezeny žádné zprávy o událostech. Zkuste upravit možnosti vyhledávání nebo filtrování, abyste našli to, co hledáte.",
|
|
119
121
|
"New event report": "Nová zpráva o události",
|
|
122
|
+
"Open an event visualization": "",
|
|
123
|
+
"Loading event visualizations": "",
|
|
124
|
+
"Couldn't load event visualizations": "",
|
|
125
|
+
"There was a problem loading event visualizations. Try again or contact your system administrator.": "",
|
|
126
|
+
"No event visualizations found. Click New event visualization to get started.": "",
|
|
127
|
+
"No event visualizations found. Try adjusting your search or filter options to find what you're looking for.": "",
|
|
128
|
+
"New event visualization": "",
|
|
120
129
|
"Options": "Možnosti",
|
|
121
130
|
"Hide": "Skrýt",
|
|
122
131
|
"Update": "Aktualizovat",
|
|
@@ -16,6 +16,8 @@
|
|
|
16
16
|
"Unsubscribe": "",
|
|
17
17
|
"Subscribe to get updates about new interpretations.": "",
|
|
18
18
|
"Subscribe": "",
|
|
19
|
+
"This app could not retrieve required data.": "",
|
|
20
|
+
"Network error": "",
|
|
19
21
|
"Data Type": "",
|
|
20
22
|
"All types": "",
|
|
21
23
|
"Totals only": "",
|
|
@@ -115,6 +117,13 @@
|
|
|
115
117
|
"No event reports found. Click New event report to get started.": "",
|
|
116
118
|
"No event reports found. Try adjusting your search or filter options to find what you're looking for.": "",
|
|
117
119
|
"New event report": "",
|
|
120
|
+
"Open an event visualization": "",
|
|
121
|
+
"Loading event visualizations": "",
|
|
122
|
+
"Couldn't load event visualizations": "",
|
|
123
|
+
"There was a problem loading event visualizations. Try again or contact your system administrator.": "",
|
|
124
|
+
"No event visualizations found. Click New event visualization to get started.": "",
|
|
125
|
+
"No event visualizations found. Try adjusting your search or filter options to find what you're looking for.": "",
|
|
126
|
+
"New event visualization": "",
|
|
118
127
|
"Options": "",
|
|
119
128
|
"Hide": "",
|
|
120
129
|
"Update": "Update",
|
|
@@ -83,13 +83,13 @@
|
|
|
83
83
|
"Anyone": "Anyone",
|
|
84
84
|
"Only you": "Only you",
|
|
85
85
|
"Others": "Others",
|
|
86
|
+
"Not supported by this app yet": "Not supported by this app yet",
|
|
86
87
|
"Filter by name": "Filter by name",
|
|
87
88
|
"Created": "Created",
|
|
88
89
|
"Last updated": "Last updated",
|
|
89
90
|
"Type": "Type",
|
|
90
91
|
"Clear filters": "Clear filters",
|
|
91
92
|
"{{firstItemIndex}}-{{lastItemIndex}} of {{totalNumberOfItems}}": "{{firstItemIndex}}-{{lastItemIndex}} of {{totalNumberOfItems}}",
|
|
92
|
-
"All charts": "All charts",
|
|
93
93
|
"Open": "Open",
|
|
94
94
|
"Couldn't load items": "Couldn't load items",
|
|
95
95
|
"There was a problem loading items. Try again or contact your system administrator.": "There was a problem loading items. Try again or contact your system administrator.",
|
|
@@ -110,13 +110,6 @@
|
|
|
110
110
|
"No maps found. Click New map to get started.": "No maps found. Click New map to get started.",
|
|
111
111
|
"No maps found. Try adjusting your search or filter options to find what you're looking for.": "No maps found. Try adjusting your search or filter options to find what you're looking for.",
|
|
112
112
|
"New map": "New map",
|
|
113
|
-
"Open an event report": "Open an event report",
|
|
114
|
-
"Loading event reports": "Loading event reports",
|
|
115
|
-
"Couldn't load event reports": "Couldn't load event reports",
|
|
116
|
-
"There was a problem loading event reports. Try again or contact your system administrator.": "There was a problem loading event reports. Try again or contact your system administrator.",
|
|
117
|
-
"No event reports found. Click New event report to get started.": "No event reports found. Click New event report to get started.",
|
|
118
|
-
"No event reports found. Try adjusting your search or filter options to find what you're looking for.": "No event reports found. Try adjusting your search or filter options to find what you're looking for.",
|
|
119
|
-
"New event report": "New event report",
|
|
120
113
|
"Open an event visualization": "Open an event visualization",
|
|
121
114
|
"Loading event visualizations": "Loading event visualizations",
|
|
122
115
|
"Couldn't load event visualizations": "Couldn't load event visualizations",
|
|
@@ -318,19 +311,8 @@
|
|
|
318
311
|
"Year over year (column)": "Year over year (column)",
|
|
319
312
|
"Single value": "Single value",
|
|
320
313
|
"Scatter": "Scatter",
|
|
321
|
-
"
|
|
322
|
-
"
|
|
323
|
-
"Compare parts of a whole against related elements vertically. Recommend data or org. unit as series.": "Compare parts of a whole against related elements vertically. Recommend data or org. unit as series.",
|
|
324
|
-
"Compare sizes of related elements horizontally. Recommend period as filter.": "Compare sizes of related elements horizontally. Recommend period as filter.",
|
|
325
|
-
"Compare parts of a whole against related elements horizontally. Recommend data or org. unit as series.": "Compare parts of a whole against related elements horizontally. Recommend data or org. unit as series.",
|
|
326
|
-
"Track or compare changes over time. Recommend period as category.": "Track or compare changes over time. Recommend period as category.",
|
|
327
|
-
"Track or compare parts of a whole over time. Recommend data as series and period as category.": "Track or compare parts of a whole over time. Recommend data as series and period as category.",
|
|
328
|
-
"Compare parts of a whole at a single point in time. Recommend period as filter.": "Compare parts of a whole at a single point in time. Recommend period as filter.",
|
|
329
|
-
"Compare several items against multiple variables.": "Compare several items against multiple variables.",
|
|
330
|
-
"Compare a percentage indicator against a 100% scale. Recommend period as filter.": "Compare a percentage indicator against a 100% scale. Recommend period as filter.",
|
|
331
|
-
"Compare changes over time between multiple time periods.": "Compare changes over time between multiple time periods.",
|
|
332
|
-
"Display a single value. Recommend relative period to show latest data.": "Display a single value. Recommend relative period to show latest data.",
|
|
333
|
-
"View the relationship between two data items at a place or time. Recommended for finding outliers.": "View the relationship between two data items at a place or time. Recommended for finding outliers.",
|
|
314
|
+
"Line list": "Line list",
|
|
315
|
+
"All charts": "All charts",
|
|
334
316
|
"{{seriesName}} (trend)": "{{seriesName}} (trend)",
|
|
335
317
|
"Trend": "Trend",
|
|
336
318
|
"No legend for this series": "No legend for this series",
|
|
@@ -16,6 +16,8 @@
|
|
|
16
16
|
"Unsubscribe": "",
|
|
17
17
|
"Subscribe to get updates about new interpretations.": "",
|
|
18
18
|
"Subscribe": "",
|
|
19
|
+
"This app could not retrieve required data.": "",
|
|
20
|
+
"Network error": "",
|
|
19
21
|
"Data Type": "Tipo de datos",
|
|
20
22
|
"All types": "Todos los tipos",
|
|
21
23
|
"Totals only": "",
|
|
@@ -115,6 +117,13 @@
|
|
|
115
117
|
"No event reports found. Click New event report to get started.": "",
|
|
116
118
|
"No event reports found. Try adjusting your search or filter options to find what you're looking for.": "",
|
|
117
119
|
"New event report": "",
|
|
120
|
+
"Open an event visualization": "",
|
|
121
|
+
"Loading event visualizations": "",
|
|
122
|
+
"Couldn't load event visualizations": "",
|
|
123
|
+
"There was a problem loading event visualizations. Try again or contact your system administrator.": "",
|
|
124
|
+
"No event visualizations found. Click New event visualization to get started.": "",
|
|
125
|
+
"No event visualizations found. Try adjusting your search or filter options to find what you're looking for.": "",
|
|
126
|
+
"New event visualization": "",
|
|
118
127
|
"Options": "Opciones",
|
|
119
128
|
"Hide": "Ocultar",
|
|
120
129
|
"Update": "Actualizar",
|
|
@@ -16,6 +16,8 @@
|
|
|
16
16
|
"Unsubscribe": "",
|
|
17
17
|
"Subscribe to get updates about new interpretations.": "",
|
|
18
18
|
"Subscribe": "",
|
|
19
|
+
"This app could not retrieve required data.": "",
|
|
20
|
+
"Network error": "",
|
|
19
21
|
"Data Type": "Type de données",
|
|
20
22
|
"All types": "Tous les types",
|
|
21
23
|
"Totals only": "Totaux uniquement",
|
|
@@ -115,6 +117,13 @@
|
|
|
115
117
|
"No event reports found. Click New event report to get started.": "",
|
|
116
118
|
"No event reports found. Try adjusting your search or filter options to find what you're looking for.": "",
|
|
117
119
|
"New event report": "",
|
|
120
|
+
"Open an event visualization": "",
|
|
121
|
+
"Loading event visualizations": "",
|
|
122
|
+
"Couldn't load event visualizations": "",
|
|
123
|
+
"There was a problem loading event visualizations. Try again or contact your system administrator.": "",
|
|
124
|
+
"No event visualizations found. Click New event visualization to get started.": "",
|
|
125
|
+
"No event visualizations found. Try adjusting your search or filter options to find what you're looking for.": "",
|
|
126
|
+
"New event visualization": "",
|
|
118
127
|
"Options": "Options",
|
|
119
128
|
"Hide": "Masquer",
|
|
120
129
|
"Update": "Mettre à jour",
|
|
@@ -15,6 +15,8 @@
|
|
|
15
15
|
"Unsubscribe": "",
|
|
16
16
|
"Subscribe to get updates about new interpretations.": "",
|
|
17
17
|
"Subscribe": "",
|
|
18
|
+
"This app could not retrieve required data.": "",
|
|
19
|
+
"Network error": "",
|
|
18
20
|
"Data Type": "Tipe Data",
|
|
19
21
|
"All types": "Semua jenis",
|
|
20
22
|
"Totals only": "Total saja",
|
|
@@ -114,6 +116,13 @@
|
|
|
114
116
|
"No event reports found. Click New event report to get started.": "",
|
|
115
117
|
"No event reports found. Try adjusting your search or filter options to find what you're looking for.": "",
|
|
116
118
|
"New event report": "",
|
|
119
|
+
"Open an event visualization": "",
|
|
120
|
+
"Loading event visualizations": "",
|
|
121
|
+
"Couldn't load event visualizations": "",
|
|
122
|
+
"There was a problem loading event visualizations. Try again or contact your system administrator.": "",
|
|
123
|
+
"No event visualizations found. Click New event visualization to get started.": "",
|
|
124
|
+
"No event visualizations found. Try adjusting your search or filter options to find what you're looking for.": "",
|
|
125
|
+
"New event visualization": "",
|
|
117
126
|
"Options": "Opsi",
|
|
118
127
|
"Hide": "Sembunyikan",
|
|
119
128
|
"Update": "Perbarui",
|