@dhis2/analytics 21.0.0-alpha.3 → 21.0.0-alpha.4
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/build/cjs/__demo__/Filter.stories.js +2 -2
- package/build/cjs/__demo__/FixedPeriodSelect.stories.js +2 -2
- package/build/cjs/__demo__/OpenFileDialog.stories.js +1 -1
- package/build/cjs/__demo__/OrgUnitDimension.stories.js +2 -2
- package/build/cjs/__demo__/PivotTable.stories.js +2 -2
- package/build/cjs/api/analytics/AnalyticsBase.js +1 -1
- package/build/cjs/api/analytics/AnalyticsRequest.js +1 -1
- package/build/cjs/api/analytics/AnalyticsRequestBase.js +3 -3
- package/build/cjs/api/analytics/AnalyticsRequestPropertiesMixin.js +7 -7
- package/build/cjs/api/analytics/AnalyticsResponse.js +2 -2
- package/build/cjs/api/analytics/__tests__/AnalyticsAggregate.spec.js +1 -11
- package/build/cjs/api/analytics/__tests__/AnalyticsRequest.spec.js +9 -9
- package/build/cjs/api/analytics/__tests__/AnalyticsRequestBase.spec.js +4 -4
- package/build/cjs/api/analytics/utils.js +1 -1
- package/build/cjs/api/dimensions.js +37 -37
- package/build/cjs/api/organisationUnits.js +3 -3
- package/build/cjs/components/AboutAOUnit/AboutAOUnit.js +226 -0
- package/build/cjs/components/AboutAOUnit/styles/AboutAOUnit.style.js +13 -0
- package/build/cjs/components/DataDimension/DataTypesSelector.js +3 -3
- package/build/cjs/components/DataDimension/DetailSelector.js +2 -2
- package/build/cjs/components/DataDimension/GroupSelector.js +9 -9
- package/build/cjs/components/DataDimension/ItemSelector.js +19 -19
- package/build/cjs/components/DataDimension/MetricSelector.js +3 -3
- package/build/cjs/components/DataDimension/styles/DataTypesSelector.style.js +1 -1
- package/build/cjs/components/DataDimension/styles/DetailSelector.style.js +1 -1
- package/build/cjs/components/DataDimension/styles/GroupSelector.style.js +1 -1
- package/build/cjs/components/DataDimension/styles/MetricSelector.style.js +1 -1
- package/build/cjs/components/DimensionMenu.js +10 -10
- package/build/cjs/components/DimensionsPanel/DimensionsPanel.js +2 -2
- package/build/cjs/components/DimensionsPanel/List/DimensionItem.js +5 -5
- package/build/cjs/components/DimensionsPanel/List/DimensionLabel.js +2 -2
- package/build/cjs/components/DimensionsPanel/List/DimensionList.js +10 -10
- package/build/cjs/components/DimensionsPanel/List/styles/DimensionList.style.js +1 -1
- package/build/cjs/components/DimensionsPanel/styles/DimensionsPanel.style.js +1 -1
- package/build/cjs/components/DynamicDimension/DynamicDimension.js +4 -4
- package/build/cjs/components/DynamicDimension/ItemSelector.js +8 -8
- package/build/cjs/components/DynamicDimension/styles/DynamicDimension.style.js +1 -1
- package/build/cjs/components/FileMenu/DeleteDialog.js +2 -2
- package/build/cjs/components/FileMenu/FileMenu.js +5 -5
- package/build/cjs/components/FileMenu/FileMenu.styles.js +1 -1
- package/build/cjs/components/FileMenu/GetLinkDialog.js +1 -1
- package/build/cjs/components/FileMenu/RenameDialog.js +2 -2
- package/build/cjs/components/FileMenu/SaveAsDialog.js +2 -2
- package/build/cjs/components/FileMenu/__tests__/DeleteDialog.spec.js +1 -1
- package/build/cjs/components/FileMenu/__tests__/RenameDialog.spec.js +1 -1
- package/build/cjs/components/FileMenu/__tests__/SaveAsDialog.spec.js +1 -1
- package/build/cjs/components/FileMenu/utils.js +3 -3
- package/build/cjs/components/Filter/Filter.js +1 -1
- package/build/cjs/components/Filter/styles/Filter.style.js +1 -1
- package/build/cjs/components/LegendKey/LegendKey.js +9 -9
- package/build/cjs/components/LegendKey/styles/LegendKey.style.js +1 -1
- package/build/cjs/components/OpenFileDialog/CustomSelectOption.js +2 -2
- package/build/cjs/components/OpenFileDialog/OpenFileDialog.js +21 -21
- package/build/cjs/components/OpenFileDialog/OpenFileDialog.styles.js +1 -1
- package/build/cjs/components/OpenFileDialog/styles/CustomSelectOption.style.js +1 -1
- package/build/cjs/components/Options/VisualizationOptions.js +2 -2
- package/build/cjs/components/Options/styles/VisualizationOptions.style.js +10 -10
- package/build/cjs/components/OrgUnitDimension/OrgUnitDimension.js +23 -22
- package/build/cjs/components/OrgUnitDimension/styles/OrgUnitDimension.style.js +2 -2
- package/build/cjs/components/PeriodDimension/FixedPeriodFilter.js +5 -5
- package/build/cjs/components/PeriodDimension/FixedPeriodSelect.js +4 -4
- package/build/cjs/components/PeriodDimension/PeriodTransfer.js +11 -11
- package/build/cjs/components/PeriodDimension/RelativePeriodFilter.js +2 -2
- package/build/cjs/components/PeriodDimension/styles/FixedPeriodSelect.style.js +1 -1
- package/build/cjs/components/PeriodDimension/styles/PeriodFilter.style.js +1 -1
- package/build/cjs/components/PeriodDimension/utils/fixedPeriods.js +49 -49
- package/build/cjs/components/PivotTable/PivotTable.js +2 -2
- package/build/cjs/components/PivotTable/PivotTableCell.js +3 -3
- package/build/cjs/components/PivotTable/PivotTableColumnHeaderCell.js +2 -2
- package/build/cjs/components/PivotTable/PivotTableContainer.js +2 -2
- package/build/cjs/components/PivotTable/PivotTableEngineContext.js +2 -2
- package/build/cjs/components/PivotTable/PivotTableSortIcon.js +2 -2
- package/build/cjs/components/PivotTable/PivotTableTitleRow.js +4 -4
- package/build/cjs/components/PivotTable/PivotTableValueCell.js +2 -2
- package/build/cjs/components/PivotTable/styles/PivotTable.style.js +3 -3
- package/build/cjs/components/TransferOption.js +5 -5
- package/build/cjs/components/styles/DimensionSelector.style.js +1 -1
- package/build/cjs/components/styles/TransferOption.style.js +1 -1
- package/build/cjs/index.js +10 -2
- package/build/cjs/locales/en/translations.json +18 -2
- package/build/cjs/modules/axis.js +1 -1
- package/build/cjs/modules/layoutUiRules/rules.js +1 -1
- package/build/cjs/modules/list.js +25 -0
- package/build/cjs/modules/ouIdHelper/index.js +2 -2
- package/build/cjs/modules/pivotTable/PivotTableEngine.js +3 -3
- package/build/cjs/modules/pivotTable/measureText.js +1 -1
- package/build/cjs/modules/visTypes.js +1 -1
- package/build/cjs/visualizations/config/adapters/dhis_highcharts/addTrendLines.js +1 -1
- package/build/cjs/visualizations/config/adapters/dhis_highcharts/axis.js +2 -2
- package/build/cjs/visualizations/config/adapters/dhis_highcharts/getAxisTitle.js +1 -1
- package/build/cjs/visualizations/config/adapters/dhis_highcharts/index.js +2 -2
- package/build/cjs/visualizations/config/adapters/dhis_highcharts/legend.js +8 -19
- package/build/cjs/visualizations/config/adapters/dhis_highcharts/legendSet.js +1 -1
- package/build/cjs/visualizations/config/adapters/dhis_highcharts/plotOptions.js +1 -1
- package/build/cjs/visualizations/config/adapters/dhis_highcharts/subtitle/index.js +1 -1
- package/build/cjs/visualizations/config/adapters/dhis_highcharts/title/index.js +1 -1
- package/build/cjs/visualizations/config/adapters/dhis_highcharts/title/scatter.js +1 -1
- package/build/cjs/visualizations/config/adapters/dhis_highcharts/xAxis/index.js +1 -1
- package/build/cjs/visualizations/config/adapters/dhis_highcharts/yAxis/gauge.js +3 -3
- package/build/cjs/visualizations/config/adapters/dhis_highcharts/yAxis/index.js +2 -2
- package/build/cjs/visualizations/config/generators/dhis/singleValue.js +5 -5
- package/build/cjs/visualizations/config/index.js +3 -3
- package/build/cjs/visualizations/store/adapters/dhis_dhis/index.js +1 -1
- package/build/cjs/visualizations/store/adapters/dhis_highcharts/index.js +1 -1
- package/build/cjs/visualizations/store/adapters/dhis_highcharts/twoCategory.js +1 -1
- package/build/cjs/visualizations/store/index.js +2 -2
- package/build/cjs/visualizations/util/__tests__/getFilterText.spec.js +1 -1
- package/build/cjs/visualizations/util/axisId.js +1 -1
- package/build/cjs/visualizations/util/getFilterText.js +4 -12
- package/build/es/__demo__/OpenFileDialog.stories.js +1 -1
- package/build/es/api/analytics/AnalyticsBase.js +1 -1
- package/build/es/api/analytics/AnalyticsRequest.js +1 -1
- package/build/es/api/analytics/AnalyticsRequestBase.js +3 -3
- package/build/es/api/analytics/AnalyticsRequestPropertiesMixin.js +7 -7
- package/build/es/api/analytics/AnalyticsResponse.js +2 -2
- package/build/es/api/analytics/__tests__/AnalyticsAggregate.spec.js +1 -11
- package/build/es/api/analytics/__tests__/AnalyticsRequest.spec.js +9 -9
- package/build/es/api/analytics/__tests__/AnalyticsRequestBase.spec.js +4 -4
- package/build/es/api/analytics/utils.js +1 -1
- package/build/es/api/dimensions.js +39 -39
- package/build/es/api/organisationUnits.js +3 -3
- package/build/es/components/AboutAOUnit/AboutAOUnit.js +203 -0
- package/build/es/components/AboutAOUnit/styles/AboutAOUnit.style.js +4 -0
- package/build/es/components/DataDimension/DataTypesSelector.js +3 -3
- package/build/es/components/DataDimension/DetailSelector.js +2 -2
- package/build/es/components/DataDimension/GroupSelector.js +7 -7
- package/build/es/components/DataDimension/ItemSelector.js +17 -17
- package/build/es/components/DataDimension/MetricSelector.js +3 -3
- package/build/es/components/DataDimension/styles/DataTypesSelector.style.js +1 -1
- package/build/es/components/DataDimension/styles/DetailSelector.style.js +1 -1
- package/build/es/components/DataDimension/styles/GroupSelector.style.js +1 -1
- package/build/es/components/DataDimension/styles/MetricSelector.style.js +1 -1
- package/build/es/components/DimensionMenu.js +10 -10
- package/build/es/components/DimensionsPanel/List/DimensionItem.js +3 -3
- package/build/es/components/DimensionsPanel/List/DimensionList.js +8 -8
- package/build/es/components/DimensionsPanel/List/styles/DimensionList.style.js +1 -1
- package/build/es/components/DimensionsPanel/styles/DimensionsPanel.style.js +1 -1
- package/build/es/components/DynamicDimension/DynamicDimension.js +4 -4
- package/build/es/components/DynamicDimension/ItemSelector.js +6 -6
- package/build/es/components/DynamicDimension/styles/DynamicDimension.style.js +1 -1
- package/build/es/components/FileMenu/FileMenu.js +3 -3
- package/build/es/components/FileMenu/FileMenu.styles.js +1 -1
- package/build/es/components/FileMenu/GetLinkDialog.js +1 -1
- package/build/es/components/FileMenu/__tests__/DeleteDialog.spec.js +1 -1
- package/build/es/components/FileMenu/__tests__/RenameDialog.spec.js +1 -1
- package/build/es/components/FileMenu/__tests__/SaveAsDialog.spec.js +1 -1
- package/build/es/components/FileMenu/utils.js +3 -3
- package/build/es/components/Filter/Filter.js +1 -1
- package/build/es/components/Filter/styles/Filter.style.js +1 -1
- package/build/es/components/LegendKey/LegendKey.js +9 -9
- package/build/es/components/LegendKey/styles/LegendKey.style.js +1 -1
- package/build/es/components/OpenFileDialog/CustomSelectOption.js +2 -2
- package/build/es/components/OpenFileDialog/OpenFileDialog.js +19 -19
- package/build/es/components/OpenFileDialog/OpenFileDialog.styles.js +1 -1
- package/build/es/components/OpenFileDialog/styles/CustomSelectOption.style.js +1 -1
- package/build/es/components/Options/styles/VisualizationOptions.style.js +10 -10
- package/build/es/components/OrgUnitDimension/OrgUnitDimension.js +20 -20
- package/build/es/components/OrgUnitDimension/styles/OrgUnitDimension.style.js +2 -2
- package/build/es/components/PeriodDimension/FixedPeriodFilter.js +5 -5
- package/build/es/components/PeriodDimension/FixedPeriodSelect.js +8 -8
- package/build/es/components/PeriodDimension/PeriodTransfer.js +9 -9
- package/build/es/components/PeriodDimension/RelativePeriodFilter.js +2 -2
- package/build/es/components/PeriodDimension/styles/FixedPeriodSelect.style.js +1 -1
- package/build/es/components/PeriodDimension/styles/PeriodFilter.style.js +1 -1
- package/build/es/components/PeriodDimension/utils/fixedPeriods.js +49 -49
- package/build/es/components/PivotTable/PivotTableCell.js +3 -3
- package/build/es/components/PivotTable/PivotTableColumnHeaderCell.js +2 -2
- package/build/es/components/PivotTable/PivotTableContainer.js +2 -2
- package/build/es/components/PivotTable/PivotTableSortIcon.js +2 -2
- package/build/es/components/PivotTable/PivotTableTitleRow.js +2 -2
- package/build/es/components/PivotTable/styles/PivotTable.style.js +3 -3
- package/build/es/components/TransferOption.js +17 -17
- package/build/es/components/styles/DimensionSelector.style.js +1 -1
- package/build/es/components/styles/TransferOption.style.js +1 -1
- package/build/es/index.js +2 -1
- package/build/es/locales/en/translations.json +18 -2
- package/build/es/modules/axis.js +1 -1
- package/build/es/modules/layoutUiRules/rules.js +1 -1
- package/build/es/modules/list.js +13 -0
- package/build/es/modules/ouIdHelper/index.js +2 -2
- package/build/es/modules/pivotTable/PivotTableEngine.js +3 -3
- package/build/es/modules/pivotTable/measureText.js +1 -1
- package/build/es/modules/visTypes.js +1 -1
- package/build/es/visualizations/config/adapters/dhis_highcharts/addTrendLines.js +1 -1
- package/build/es/visualizations/config/adapters/dhis_highcharts/axis.js +2 -2
- package/build/es/visualizations/config/adapters/dhis_highcharts/getAxisTitle.js +1 -1
- package/build/es/visualizations/config/adapters/dhis_highcharts/legend.js +8 -19
- package/build/es/visualizations/config/adapters/dhis_highcharts/legendSet.js +1 -1
- package/build/es/visualizations/config/adapters/dhis_highcharts/plotOptions.js +1 -1
- package/build/es/visualizations/config/adapters/dhis_highcharts/subtitle/index.js +1 -1
- package/build/es/visualizations/config/adapters/dhis_highcharts/title/index.js +1 -1
- package/build/es/visualizations/config/adapters/dhis_highcharts/title/scatter.js +1 -1
- package/build/es/visualizations/config/adapters/dhis_highcharts/xAxis/index.js +1 -1
- package/build/es/visualizations/config/adapters/dhis_highcharts/yAxis/gauge.js +3 -3
- package/build/es/visualizations/config/adapters/dhis_highcharts/yAxis/index.js +2 -2
- package/build/es/visualizations/config/generators/dhis/singleValue.js +5 -5
- package/build/es/visualizations/config/index.js +3 -3
- package/build/es/visualizations/store/adapters/dhis_dhis/index.js +1 -1
- package/build/es/visualizations/store/adapters/dhis_highcharts/index.js +1 -1
- package/build/es/visualizations/store/adapters/dhis_highcharts/twoCategory.js +1 -1
- package/build/es/visualizations/store/index.js +2 -2
- package/build/es/visualizations/util/__tests__/getFilterText.spec.js +1 -1
- package/build/es/visualizations/util/axisId.js +1 -1
- package/build/es/visualizations/util/getFilterText.js +5 -13
- package/package.json +2 -2
- package/build/cjs/components/OrgUnitDimension/OrgUnitDimensionOld.js +0 -244
- package/build/es/components/OrgUnitDimension/OrgUnitDimensionOld.js +0 -220
|
@@ -38,14 +38,14 @@ const GroupsSelector = ({
|
|
|
38
38
|
fetchGroups();
|
|
39
39
|
}, [dataType]);
|
|
40
40
|
return /*#__PURE__*/React.createElement("div", {
|
|
41
|
-
className:
|
|
41
|
+
className: "jsx-".concat(styles.__hash) + " " + "container"
|
|
42
42
|
}, /*#__PURE__*/React.createElement(_JSXStyle, {
|
|
43
43
|
id: styles.__hash
|
|
44
44
|
}, styles), /*#__PURE__*/React.createElement("div", {
|
|
45
|
-
className:
|
|
45
|
+
className: "jsx-".concat(styles.__hash) + " " + "group-container"
|
|
46
46
|
}, /*#__PURE__*/React.createElement(SingleSelectField, {
|
|
47
47
|
label: (_dataTypes$dataType3 = dataTypes[dataType]) === null || _dataTypes$dataType3 === void 0 ? void 0 : _dataTypes$dataType3.getGroupLabel(),
|
|
48
|
-
dataTest:
|
|
48
|
+
dataTest: "".concat(dataTest, "-groups-select-field"),
|
|
49
49
|
selected: currentGroup || defaultGroup.id,
|
|
50
50
|
placeholder: !currentGroup && (_dataTypes$dataType4 = dataTypes[dataType]) !== null && _dataTypes$dataType4 !== void 0 && _dataTypes$dataType4.getPlaceholder ? dataTypes[dataType].getPlaceholder() : null,
|
|
51
51
|
onChange: ref => onGroupChange(ref.selected),
|
|
@@ -57,20 +57,20 @@ const GroupsSelector = ({
|
|
|
57
57
|
value: defaultGroup.id,
|
|
58
58
|
key: defaultGroup.id,
|
|
59
59
|
label: defaultGroup.getName(),
|
|
60
|
-
dataTest:
|
|
60
|
+
dataTest: "".concat(dataTest, "-groups-select-field-option-").concat(defaultGroup.id)
|
|
61
61
|
}) : null, !isLoading ? groups.map(item => /*#__PURE__*/React.createElement(SingleSelectOption, {
|
|
62
62
|
value: item.id,
|
|
63
63
|
key: item.id,
|
|
64
64
|
label: item.name,
|
|
65
|
-
dataTest:
|
|
65
|
+
dataTest: "".concat(dataTest, "-groups-select-field-option-").concat(item.id)
|
|
66
66
|
})) : null)), subGroupType === SUB_GROUP_DETAIL && /*#__PURE__*/React.createElement(DetailSelector, {
|
|
67
67
|
currentValue: currentSubGroup,
|
|
68
68
|
onChange: onSubGroupChange,
|
|
69
|
-
dataTest:
|
|
69
|
+
dataTest: "".concat(dataTest, "-sub-group-select-field")
|
|
70
70
|
}), subGroupType === SUB_GROUP_METRIC && /*#__PURE__*/React.createElement(MetricSelector, {
|
|
71
71
|
currentValue: currentSubGroup,
|
|
72
72
|
onChange: onSubGroupChange,
|
|
73
|
-
dataTest:
|
|
73
|
+
dataTest: "".concat(dataTest, "-sub-group-select-field")
|
|
74
74
|
}));
|
|
75
75
|
};
|
|
76
76
|
|
|
@@ -31,21 +31,21 @@ const LeftHeader = ({
|
|
|
31
31
|
displayNameProp,
|
|
32
32
|
dataTest
|
|
33
33
|
}) => /*#__PURE__*/React.createElement(React.Fragment, null, /*#__PURE__*/React.createElement("div", {
|
|
34
|
-
className:
|
|
34
|
+
className: "jsx-".concat(styles.__hash) + " " + "leftHeader"
|
|
35
35
|
}, /*#__PURE__*/React.createElement(InputField, {
|
|
36
36
|
value: searchTerm,
|
|
37
37
|
onChange: ({
|
|
38
38
|
value
|
|
39
39
|
}) => setSearchTerm(value),
|
|
40
40
|
placeholder: i18n.t('Search by data item name'),
|
|
41
|
-
dataTest:
|
|
41
|
+
dataTest: "".concat(dataTest, "-filter-input-field"),
|
|
42
42
|
dense: true,
|
|
43
43
|
initialFocus: true,
|
|
44
44
|
type: 'search'
|
|
45
45
|
}), /*#__PURE__*/React.createElement(DataTypeSelector, {
|
|
46
46
|
currentDataType: dataType,
|
|
47
47
|
onChange: setDataType,
|
|
48
|
-
dataTest:
|
|
48
|
+
dataTest: "".concat(dataTest, "-data-types-select-field")
|
|
49
49
|
}), dataTypes[dataType] && /*#__PURE__*/React.createElement(GroupSelector, {
|
|
50
50
|
dataType: dataType,
|
|
51
51
|
displayNameProp: displayNameProp,
|
|
@@ -72,7 +72,7 @@ LeftHeader.propTypes = {
|
|
|
72
72
|
};
|
|
73
73
|
|
|
74
74
|
const EmptySelection = () => /*#__PURE__*/React.createElement(React.Fragment, null, /*#__PURE__*/React.createElement("p", {
|
|
75
|
-
className:
|
|
75
|
+
className: "jsx-".concat(styles.__hash) + " " + "emptyList"
|
|
76
76
|
}, i18n.t('No items selected')), /*#__PURE__*/React.createElement(_JSXStyle, {
|
|
77
77
|
id: styles.__hash
|
|
78
78
|
}, styles));
|
|
@@ -80,13 +80,13 @@ const EmptySelection = () => /*#__PURE__*/React.createElement(React.Fragment, nu
|
|
|
80
80
|
const RightHeader = ({
|
|
81
81
|
infoText
|
|
82
82
|
}) => /*#__PURE__*/React.createElement(React.Fragment, null, /*#__PURE__*/React.createElement("p", {
|
|
83
|
-
className:
|
|
83
|
+
className: "jsx-".concat(styles.__hash) + " " + "rightHeader"
|
|
84
84
|
}, i18n.t('Selected Items')), infoText && /*#__PURE__*/React.createElement("div", {
|
|
85
|
-
className:
|
|
85
|
+
className: "jsx-".concat(styles.__hash) + " " + "info-container"
|
|
86
86
|
}, /*#__PURE__*/React.createElement("div", {
|
|
87
|
-
className:
|
|
87
|
+
className: "jsx-".concat(styles.__hash)
|
|
88
88
|
}, /*#__PURE__*/React.createElement(IconInfo16, null)), /*#__PURE__*/React.createElement("span", {
|
|
89
|
-
className:
|
|
89
|
+
className: "jsx-".concat(styles.__hash) + " " + "info-text"
|
|
90
90
|
}, infoText)), /*#__PURE__*/React.createElement(_JSXStyle, {
|
|
91
91
|
id: styles.__hash
|
|
92
92
|
}, styles));
|
|
@@ -177,7 +177,7 @@ const SourceEmptyPlaceholder = ({
|
|
|
177
177
|
|
|
178
178
|
return message && /*#__PURE__*/React.createElement(React.Fragment, null, /*#__PURE__*/React.createElement("p", {
|
|
179
179
|
"data-test": dataTest,
|
|
180
|
-
className:
|
|
180
|
+
className: "jsx-".concat(styles.__hash) + " " + "emptyList"
|
|
181
181
|
}, message), /*#__PURE__*/React.createElement(_JSXStyle, {
|
|
182
182
|
id: styles.__hash
|
|
183
183
|
}, styles));
|
|
@@ -241,16 +241,16 @@ const ItemSelector = ({
|
|
|
241
241
|
if (state.filter.subGroup && state.filter.subGroup !== ALL_ID) {
|
|
242
242
|
const metric = DATA_SETS_CONSTANTS.find(item => item.id === state.filter.subGroup);
|
|
243
243
|
newOptions.push({
|
|
244
|
-
label:
|
|
245
|
-
value:
|
|
244
|
+
label: "".concat(item.name, " - ").concat(metric.getName()),
|
|
245
|
+
value: "".concat(item.id, ".").concat(metric.id),
|
|
246
246
|
disabled: item.disabled,
|
|
247
247
|
type: item.dimensionItemType
|
|
248
248
|
});
|
|
249
249
|
} else {
|
|
250
250
|
DATA_SETS_CONSTANTS.forEach(metric => {
|
|
251
251
|
newOptions.push({
|
|
252
|
-
label:
|
|
253
|
-
value:
|
|
252
|
+
label: "".concat(item.name, " - ").concat(metric.getName()),
|
|
253
|
+
value: "".concat(item.id, ".").concat(metric.id),
|
|
254
254
|
disabled: item.disabled,
|
|
255
255
|
type: item.dimensionItemType
|
|
256
256
|
});
|
|
@@ -379,7 +379,7 @@ const ItemSelector = ({
|
|
|
379
379
|
options: state.options,
|
|
380
380
|
noItemsMessage: noItemsMessage,
|
|
381
381
|
dataType: state.filter.dataType,
|
|
382
|
-
dataTest:
|
|
382
|
+
dataTest: "".concat(dataTest, "-empty-source")
|
|
383
383
|
}),
|
|
384
384
|
onEndReached: onEndReached,
|
|
385
385
|
leftHeader: /*#__PURE__*/React.createElement(LeftHeader, {
|
|
@@ -406,7 +406,7 @@ const ItemSelector = ({
|
|
|
406
406
|
searchTerm: state.searchTerm,
|
|
407
407
|
setSearchTerm: setSearchTerm,
|
|
408
408
|
displayNameProp: displayNameProp,
|
|
409
|
-
dataTest:
|
|
409
|
+
dataTest: "".concat(dataTest, "-left-header")
|
|
410
410
|
}),
|
|
411
411
|
enableOrderChange: true,
|
|
412
412
|
height: TRANSFER_HEIGHT,
|
|
@@ -427,9 +427,9 @@ const ItemSelector = ({
|
|
|
427
427
|
tooltipText: state.filter.dataType === ALL_ID ? getTooltipText(getItemType(props.value
|
|
428
428
|
/* eslint-disable-line react/prop-types */
|
|
429
429
|
)) : undefined,
|
|
430
|
-
dataTest:
|
|
430
|
+
dataTest: "".concat(dataTest, "-transfer-option")
|
|
431
431
|
})),
|
|
432
|
-
dataTest:
|
|
432
|
+
dataTest: "".concat(dataTest, "-transfer")
|
|
433
433
|
});
|
|
434
434
|
};
|
|
435
435
|
|
|
@@ -12,7 +12,7 @@ export const MetricSelector = ({
|
|
|
12
12
|
dataTest
|
|
13
13
|
}) => {
|
|
14
14
|
return /*#__PURE__*/React.createElement("div", {
|
|
15
|
-
className:
|
|
15
|
+
className: "jsx-".concat(styles.__hash) + " " + "metric-container"
|
|
16
16
|
}, /*#__PURE__*/React.createElement(SingleSelectField, {
|
|
17
17
|
label: i18n.t('Metric type'),
|
|
18
18
|
selected: currentValue || ALL_ID,
|
|
@@ -23,12 +23,12 @@ export const MetricSelector = ({
|
|
|
23
23
|
value: ALL_ID,
|
|
24
24
|
key: ALL_ID,
|
|
25
25
|
label: i18n.t('All metrics'),
|
|
26
|
-
dataTest:
|
|
26
|
+
dataTest: "".concat(dataTest, "-option-").concat(ALL_ID)
|
|
27
27
|
}), DATA_SETS_CONSTANTS.map(option => /*#__PURE__*/React.createElement(SingleSelectOption, {
|
|
28
28
|
value: option.id,
|
|
29
29
|
key: option.id,
|
|
30
30
|
label: option.getName(),
|
|
31
|
-
dataTest:
|
|
31
|
+
dataTest: "".concat(dataTest, "-option-").concat(option.id)
|
|
32
32
|
}))), /*#__PURE__*/React.createElement(_JSXStyle, {
|
|
33
33
|
id: styles.__hash
|
|
34
34
|
}, styles));
|
|
@@ -1,4 +1,4 @@
|
|
|
1
1
|
import { spacers } from '@dhis2/ui';
|
|
2
|
-
const _defaultExport = [
|
|
2
|
+
const _defaultExport = [".container.jsx-3368926978{display:-webkit-box;display:-webkit-flex;display:-ms-flexbox;display:flex;-webkit-flex-flow:column;-ms-flex-flow:column;flex-flow:column;border-bottom:0;padding:".concat(spacers.dp12, " 0 0;}")];
|
|
3
3
|
_defaultExport.__hash = "3368926978";
|
|
4
4
|
export default _defaultExport;
|
|
@@ -1,4 +1,4 @@
|
|
|
1
1
|
import { spacers } from '@dhis2/ui';
|
|
2
|
-
const _defaultExport = [
|
|
2
|
+
const _defaultExport = [".detail-container.jsx-2733301753{display:-webkit-box;display:-webkit-flex;display:-ms-flexbox;display:flex;-webkit-flex-flow:column;-ms-flex-flow:column;flex-flow:column;padding-left:".concat(spacers.dp4, ";width:40%;}")];
|
|
3
3
|
_defaultExport.__hash = "2733301753";
|
|
4
4
|
export default _defaultExport;
|
|
@@ -1,4 +1,4 @@
|
|
|
1
1
|
import { spacers } from '@dhis2/ui';
|
|
2
|
-
const _defaultExport = [
|
|
2
|
+
const _defaultExport = [".container.jsx-2205421678{display:-webkit-box;display:-webkit-flex;display:-ms-flexbox;display:flex;min-height:53px;padding-left:".concat(spacers.dp16, ";margin-top:").concat(spacers.dp12, ";}"), ".group-container.jsx-2205421678{display:-webkit-box;display:-webkit-flex;display:-ms-flexbox;display:flex;-webkit-flex-direction:column;-ms-flex-direction:column;flex-direction:column;-webkit-box-flex:1;-webkit-flex-grow:1;-ms-flex-positive:1;flex-grow:1;}"];
|
|
3
3
|
_defaultExport.__hash = "2205421678";
|
|
4
4
|
export default _defaultExport;
|
|
@@ -1,4 +1,4 @@
|
|
|
1
1
|
import { spacers } from '@dhis2/ui';
|
|
2
|
-
const _defaultExport = [
|
|
2
|
+
const _defaultExport = [".metric-container.jsx-3752467532{display:-webkit-box;display:-webkit-flex;display:-ms-flexbox;display:flex;-webkit-flex-flow:column;-ms-flex-flow:column;flex-flow:column;padding-left:".concat(spacers.dp4, ";width:50%;}")];
|
|
3
3
|
_defaultExport.__hash = "3752467532";
|
|
4
4
|
export default _defaultExport;
|
|
@@ -49,7 +49,7 @@ const DimensionMenu = ({
|
|
|
49
49
|
key: "remove-menu-item",
|
|
50
50
|
onClick: onClick,
|
|
51
51
|
label: i18n.t('Remove'),
|
|
52
|
-
dataTest:
|
|
52
|
+
dataTest: "".concat(dataTest, "-item-remove-").concat(dimensionId)
|
|
53
53
|
}); // Assigned categories
|
|
54
54
|
|
|
55
55
|
|
|
@@ -58,8 +58,8 @@ const DimensionMenu = ({
|
|
|
58
58
|
if (!isAssignedCategoriesInLayout) {
|
|
59
59
|
menuItems.push( /*#__PURE__*/React.createElement(MenuItem, {
|
|
60
60
|
label: assignedCategoriesItemLabel,
|
|
61
|
-
key:
|
|
62
|
-
dataTest:
|
|
61
|
+
key: "assigned-categories-item-".concat(dimensionId),
|
|
62
|
+
dataTest: "".concat(dataTest, "-item-co-menu")
|
|
63
63
|
}, assignedCategoriesAvailableDestinations.map(destination => /*#__PURE__*/React.createElement(MenuItem, {
|
|
64
64
|
key: destination,
|
|
65
65
|
onClick: () => {
|
|
@@ -67,22 +67,22 @@ const DimensionMenu = ({
|
|
|
67
67
|
onClose();
|
|
68
68
|
},
|
|
69
69
|
label: getAxisItemLabel(getAxisNameByLayoutType(destination, getLayoutTypeByVisType(visType))),
|
|
70
|
-
dataTest:
|
|
70
|
+
dataTest: "".concat(dataTest, "-item-action-co-to-").concat(destination)
|
|
71
71
|
}))));
|
|
72
72
|
} else {
|
|
73
73
|
menuItems.push( /*#__PURE__*/React.createElement(MenuItem, {
|
|
74
|
-
key:
|
|
74
|
+
key: "assigned-categories-item-".concat(dimensionId),
|
|
75
75
|
onClick: () => {
|
|
76
76
|
assignedCategoriesItemHandler();
|
|
77
77
|
onClose();
|
|
78
78
|
},
|
|
79
79
|
label: assignedCategoriesItemLabel,
|
|
80
|
-
dataTest:
|
|
80
|
+
dataTest: "".concat(dataTest, "-item-remove-co")
|
|
81
81
|
}));
|
|
82
82
|
}
|
|
83
83
|
} else {
|
|
84
84
|
menuItems.push( /*#__PURE__*/React.createElement(Tooltip, {
|
|
85
|
-
key:
|
|
85
|
+
key: "assigned-categories-item-".concat(dimensionId),
|
|
86
86
|
content: getUnavailableLabel(visType),
|
|
87
87
|
"aria-label": "disabled",
|
|
88
88
|
classes: classes
|
|
@@ -90,7 +90,7 @@ const DimensionMenu = ({
|
|
|
90
90
|
disabled: true,
|
|
91
91
|
dense: true,
|
|
92
92
|
label: assignedCategoriesItemLabel,
|
|
93
|
-
dataTest:
|
|
93
|
+
dataTest: "".concat(dataTest, "-item-co-menu")
|
|
94
94
|
})));
|
|
95
95
|
}
|
|
96
96
|
} // divider
|
|
@@ -98,7 +98,7 @@ const DimensionMenu = ({
|
|
|
98
98
|
|
|
99
99
|
menuItems.length && menuItems.push(getDividerItem('assigned-categories-divider'));
|
|
100
100
|
menuItems.push(...applicableAxisIds.map(axisId => /*#__PURE__*/React.createElement(MenuItem, {
|
|
101
|
-
key:
|
|
101
|
+
key: "".concat(dimensionId, "-to-").concat(axisId),
|
|
102
102
|
onClick: () => {
|
|
103
103
|
axisItemHandler({
|
|
104
104
|
dimensionId,
|
|
@@ -110,7 +110,7 @@ const DimensionMenu = ({
|
|
|
110
110
|
onClose();
|
|
111
111
|
},
|
|
112
112
|
label: getAxisItemLabel(getAxisNameByLayoutType(axisId, getLayoutTypeByVisType(visType)), isDimensionInLayout),
|
|
113
|
-
dataTest:
|
|
113
|
+
dataTest: "".concat(dataTest, "-item-action-").concat(dimensionId, "-to-").concat(axisId)
|
|
114
114
|
}))); // remove item
|
|
115
115
|
|
|
116
116
|
if (isDimensionInLayout) {
|
|
@@ -88,20 +88,20 @@ class DimensionItem extends Component {
|
|
|
88
88
|
id: id,
|
|
89
89
|
isDeactivated: isDeactivated,
|
|
90
90
|
onClick: onClick,
|
|
91
|
-
dataTest:
|
|
91
|
+
dataTest: "".concat(dataTest, "-button-").concat(id)
|
|
92
92
|
}, /*#__PURE__*/React.createElement("div", {
|
|
93
93
|
style: styles.iconWrapper
|
|
94
94
|
}, Icon), /*#__PURE__*/React.createElement("div", {
|
|
95
95
|
style: styles.labelWrapper
|
|
96
96
|
}, Label, /*#__PURE__*/React.createElement(RecommendedIcon, {
|
|
97
97
|
isRecommended: isRecommended,
|
|
98
|
-
dataTest:
|
|
98
|
+
dataTest: "".concat(dataTest, "-recommended-icon")
|
|
99
99
|
})), isLocked && /*#__PURE__*/React.createElement("div", {
|
|
100
100
|
style: styles.iconWrapper
|
|
101
101
|
}, /*#__PURE__*/React.createElement(IconLock16, null))), onOptionsClick ? /*#__PURE__*/React.createElement("div", {
|
|
102
102
|
style: styles.optionsWrapper,
|
|
103
103
|
ref: optionsRef,
|
|
104
|
-
"data-test":
|
|
104
|
+
"data-test": "".concat(dataTest, "-menu-").concat(id)
|
|
105
105
|
}, this.state.mouseOver && !isDeactivated && !isLocked ? /*#__PURE__*/React.createElement(OptionsButton, {
|
|
106
106
|
style: styles.optionsButton,
|
|
107
107
|
onClick: this.onOptionsClick(id, optionsRef)
|
|
@@ -41,21 +41,21 @@ class DimensionList extends Component {
|
|
|
41
41
|
const fixedDimensions = this.getDimensionItemsByFilter(dimension => Object.values(getFixedDimensions()).some(fixedDim => fixedDim.id === dimension.id));
|
|
42
42
|
const nonPredefinedDimensions = this.getDimensionItemsByFilter(dimension => !Object.values(getPredefinedDimensions()).some(predefDim => predefDim.id === dimension.id));
|
|
43
43
|
return /*#__PURE__*/React.createElement("div", {
|
|
44
|
-
className:
|
|
44
|
+
className: "jsx-".concat(styles.__hash) + " " + "container"
|
|
45
45
|
}, /*#__PURE__*/React.createElement("div", {
|
|
46
|
-
className:
|
|
46
|
+
className: "jsx-".concat(styles.__hash) + " " + "wrapper"
|
|
47
47
|
}, fixedDimensions !== null && fixedDimensions !== void 0 && fixedDimensions.length ? /*#__PURE__*/React.createElement("div", {
|
|
48
|
-
className:
|
|
48
|
+
className: "jsx-".concat(styles.__hash) + " " + "section"
|
|
49
49
|
}, /*#__PURE__*/React.createElement("h3", {
|
|
50
|
-
className:
|
|
50
|
+
className: "jsx-".concat(styles.__hash) + " " + "header"
|
|
51
51
|
}, i18n.t('Main dimensions')), /*#__PURE__*/React.createElement("ul", {
|
|
52
|
-
className:
|
|
52
|
+
className: "jsx-".concat(styles.__hash) + " " + "list"
|
|
53
53
|
}, fixedDimensions)) : null, nonPredefinedDimensions !== null && nonPredefinedDimensions !== void 0 && nonPredefinedDimensions.length ? /*#__PURE__*/React.createElement("div", {
|
|
54
|
-
className:
|
|
54
|
+
className: "jsx-".concat(styles.__hash) + " " + "section"
|
|
55
55
|
}, /*#__PURE__*/React.createElement("h3", {
|
|
56
|
-
className:
|
|
56
|
+
className: "jsx-".concat(styles.__hash) + " " + "header"
|
|
57
57
|
}, i18n.t('Your dimensions')), /*#__PURE__*/React.createElement("ul", {
|
|
58
|
-
className:
|
|
58
|
+
className: "jsx-".concat(styles.__hash) + " " + "list"
|
|
59
59
|
}, nonPredefinedDimensions)) : null), /*#__PURE__*/React.createElement(_JSXStyle, {
|
|
60
60
|
id: styles.__hash
|
|
61
61
|
}, styles));
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { colors, spacers } from '@dhis2/ui';
|
|
2
|
-
const _defaultExport = [".container.jsx-2067921157{position:relative;-webkit-flex:1 1 0%;-ms-flex:1 1 0%;flex:1 1 0%;min-height:30vh;}", ".wrapper.jsx-2067921157{position:absolute;width:100%;height:100%;overflow:auto;margin-top:0;padding:0;}", ".list.jsx-2067921157{margin:0;padding:0;}",
|
|
2
|
+
const _defaultExport = [".container.jsx-2067921157{position:relative;-webkit-flex:1 1 0%;-ms-flex:1 1 0%;flex:1 1 0%;min-height:30vh;}", ".wrapper.jsx-2067921157{position:absolute;width:100%;height:100%;overflow:auto;margin-top:0;padding:0;}", ".list.jsx-2067921157{margin:0;padding:0;}", ".header.jsx-2067921157{text-transform:uppercase;font-size:11px;color:".concat(colors.grey700, ";margin:5px 0;-webkit-letter-spacing:0.3px;-moz-letter-spacing:0.3px;-ms-letter-spacing:0.3px;letter-spacing:0.3px;}"), ".section.jsx-2067921157:not(:last-child){margin-bottom:".concat(spacers.dp24, ";}")];
|
|
3
3
|
_defaultExport.__hash = "2067921157";
|
|
4
4
|
// Fix for vertical flex scrolling in Firefox/Safari:
|
|
5
5
|
// Wrap the list in a div with position:relative (and flex:1 instead of on the list)
|
|
@@ -53,7 +53,7 @@ export const DynamicDimension = ({
|
|
|
53
53
|
name: "dynamic-dimension-selection-type-selector",
|
|
54
54
|
dense: true
|
|
55
55
|
}, /*#__PURE__*/React.createElement("div", {
|
|
56
|
-
className:
|
|
56
|
+
className: "jsx-".concat(styles.__hash) + " " + "automatic"
|
|
57
57
|
}, /*#__PURE__*/React.createElement(Radio, {
|
|
58
58
|
key: 'AUTOMATIC',
|
|
59
59
|
label: i18n.t('Automatically include all items'),
|
|
@@ -62,11 +62,11 @@ export const DynamicDimension = ({
|
|
|
62
62
|
checked: allIsSelected,
|
|
63
63
|
dataTest: 'dynamic-dimension-selection-type-automatic'
|
|
64
64
|
}), /*#__PURE__*/React.createElement("p", {
|
|
65
|
-
className:
|
|
65
|
+
className: "jsx-".concat(styles.__hash) + " " + "help-text"
|
|
66
66
|
}, i18n.t('Select all {{- dimensionTitle}} items. With this option, new items added in the future will be automatically included.', {
|
|
67
67
|
dimensionTitle
|
|
68
68
|
}))), /*#__PURE__*/React.createElement("div", {
|
|
69
|
-
className:
|
|
69
|
+
className: "jsx-".concat(styles.__hash) + " " + "manual"
|
|
70
70
|
}, /*#__PURE__*/React.createElement(Radio, {
|
|
71
71
|
key: 'MANUAL',
|
|
72
72
|
label: i18n.t('Manually select items...'),
|
|
@@ -85,7 +85,7 @@ export const DynamicDimension = ({
|
|
|
85
85
|
onFetch: fetchItems,
|
|
86
86
|
onSelect: onSelectItems,
|
|
87
87
|
rightFooter: rightFooter,
|
|
88
|
-
dataTest:
|
|
88
|
+
dataTest: "".concat(dimensionTitle.replace(/\s+/g, '-').toLowerCase(), "-dimension")
|
|
89
89
|
}), /*#__PURE__*/React.createElement(_JSXStyle, {
|
|
90
90
|
id: styles.__hash
|
|
91
91
|
}, styles));
|
|
@@ -16,7 +16,7 @@ const LeftHeader = ({
|
|
|
16
16
|
filter,
|
|
17
17
|
setFilter
|
|
18
18
|
}) => /*#__PURE__*/React.createElement(React.Fragment, null, /*#__PURE__*/React.createElement("div", {
|
|
19
|
-
className:
|
|
19
|
+
className: "jsx-".concat(styles.__hash) + " " + "leftHeader"
|
|
20
20
|
}, /*#__PURE__*/React.createElement(InputField, {
|
|
21
21
|
value: filter,
|
|
22
22
|
onChange: ({
|
|
@@ -35,13 +35,13 @@ LeftHeader.propTypes = {
|
|
|
35
35
|
};
|
|
36
36
|
|
|
37
37
|
const EmptySelection = () => /*#__PURE__*/React.createElement(React.Fragment, null, /*#__PURE__*/React.createElement("p", {
|
|
38
|
-
className:
|
|
38
|
+
className: "jsx-".concat(styles.__hash) + " " + "emptyList"
|
|
39
39
|
}, i18n.t('No items selected')), /*#__PURE__*/React.createElement(_JSXStyle, {
|
|
40
40
|
id: styles.__hash
|
|
41
41
|
}, styles));
|
|
42
42
|
|
|
43
43
|
const RightHeader = () => /*#__PURE__*/React.createElement(React.Fragment, null, /*#__PURE__*/React.createElement("p", {
|
|
44
|
-
className:
|
|
44
|
+
className: "jsx-".concat(styles.__hash) + " " + "rightHeader"
|
|
45
45
|
}, i18n.t('Selected Items')), /*#__PURE__*/React.createElement(_JSXStyle, {
|
|
46
46
|
id: styles.__hash
|
|
47
47
|
}, styles));
|
|
@@ -63,7 +63,7 @@ const SourceEmptyPlaceholder = ({
|
|
|
63
63
|
}
|
|
64
64
|
|
|
65
65
|
return message && /*#__PURE__*/React.createElement(React.Fragment, null, /*#__PURE__*/React.createElement("p", {
|
|
66
|
-
className:
|
|
66
|
+
className: "jsx-".concat(styles.__hash) + " " + "emptyList"
|
|
67
67
|
}, message), /*#__PURE__*/React.createElement(_JSXStyle, {
|
|
68
68
|
id: styles.__hash
|
|
69
69
|
}, styles));
|
|
@@ -173,9 +173,9 @@ const ItemSelector = ({
|
|
|
173
173
|
rightFooter: rightFooter,
|
|
174
174
|
renderOption: props => /*#__PURE__*/React.createElement(TransferOption, _extends({}, props, {
|
|
175
175
|
icon: GenericIcon,
|
|
176
|
-
dataTest:
|
|
176
|
+
dataTest: "".concat(dataTest, "-transfer-option")
|
|
177
177
|
})),
|
|
178
|
-
dataTest:
|
|
178
|
+
dataTest: "".concat(dataTest, "-transfer")
|
|
179
179
|
});
|
|
180
180
|
};
|
|
181
181
|
|
|
@@ -1,4 +1,4 @@
|
|
|
1
1
|
import { spacers, colors } from '@dhis2/ui';
|
|
2
|
-
const _defaultExport = [
|
|
2
|
+
const _defaultExport = [".automatic.jsx-1315229031{margin-bottom:".concat(spacers.dp12, ";}"), ".manual.jsx-1315229031{margin-bottom:".concat(spacers.dp8, ";}"), ".help-text.jsx-1315229031{font-size:14px;padding-left:23px;color:".concat(colors.grey700, ";margin:0;}")];
|
|
3
3
|
_defaultExport.__hash = "1315229031";
|
|
4
4
|
export default _defaultExport;
|
|
@@ -127,16 +127,16 @@ export const FileMenu = ({
|
|
|
127
127
|
const iconInactiveColor = colors.grey500;
|
|
128
128
|
return /*#__PURE__*/React.createElement("div", {
|
|
129
129
|
onKeyDown: onKeyDown,
|
|
130
|
-
className:
|
|
130
|
+
className: "jsx-".concat(fileMenuStyles.__hash)
|
|
131
131
|
}, /*#__PURE__*/React.createElement(_JSXStyle, {
|
|
132
132
|
id: fileMenuStyles.__hash
|
|
133
133
|
}, fileMenuStyles), /*#__PURE__*/React.createElement("div", {
|
|
134
134
|
ref: buttonRef,
|
|
135
|
-
className:
|
|
135
|
+
className: "jsx-".concat(fileMenuStyles.__hash)
|
|
136
136
|
}, /*#__PURE__*/React.createElement("button", {
|
|
137
137
|
onClick: toggleMenu,
|
|
138
138
|
"data-test": "file-menu-toggle",
|
|
139
|
-
className:
|
|
139
|
+
className: "jsx-".concat(fileMenuStyles.__hash) + " " + "menu-toggle"
|
|
140
140
|
}, i18n.t('File'))), /*#__PURE__*/React.createElement(OpenFileDialog, {
|
|
141
141
|
open: currentDialog === 'open',
|
|
142
142
|
type: fileType,
|
|
@@ -1,3 +1,3 @@
|
|
|
1
1
|
import { colors } from '@dhis2/ui';
|
|
2
|
-
export const fileMenuStyles = [
|
|
2
|
+
export const fileMenuStyles = [".menu-toggle.jsx-632952601{display:-webkit-inline-box;display:-webkit-inline-flex;display:-ms-inline-flexbox;display:inline-flex;position:relative;-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;font-size:15px;font-weight:400;text-transform:none;padding:6px 8px;color:".concat(colors.grey900, ";min-width:64px;box-sizing:border-box;line-height:1.75;background:none;border:none;-webkit-transition:background-color 250ms cubic-bezier(0.4,0,0.2,1) 0ms;transition:background-color 250ms cubic-bezier(0.4,0,0.2,1) 0ms;cursor:pointer;}"), ".menu-toggle.jsx-632952601:hover.jsx-632952601:enabled{background-color:".concat(colors.grey300, ";opacity:0.8;}"), ".menu-toggle.jsx-632952601:disabled{color:".concat(colors.grey400, ";}"), ".menu-toggle.jsx-632952601:focus{outline:none;}"];
|
|
3
3
|
fileMenuStyles.__hash = "632952601";
|
|
@@ -13,7 +13,7 @@ export const GetLinkDialog = ({
|
|
|
13
13
|
baseUrl
|
|
14
14
|
} = useConfig(); // TODO simply use href from the visualization object?
|
|
15
15
|
|
|
16
|
-
const appUrl = new URL(
|
|
16
|
+
const appUrl = new URL("".concat(baseUrl, "/").concat(appPathFor(type, id)), "".concat(window.location.origin).concat(window.location.pathname));
|
|
17
17
|
return /*#__PURE__*/React.createElement(Modal, {
|
|
18
18
|
onClose: onClose
|
|
19
19
|
}, /*#__PURE__*/React.createElement(ModalContent, null, /*#__PURE__*/React.createElement("p", null, i18n.t('Open in this app')), /*#__PURE__*/React.createElement("a", {
|
|
@@ -27,7 +27,7 @@ describe('The FileMenu - DeleteDialog component', () => {
|
|
|
27
27
|
expect(getDeleteDialogComponent(props).find(Modal)).toHaveLength(1);
|
|
28
28
|
});
|
|
29
29
|
it('renders a ModalTitle containing the type prop', () => {
|
|
30
|
-
expect(getDeleteDialogComponent(props).find(ModalTitle).childAt(0).text()).toEqual(
|
|
30
|
+
expect(getDeleteDialogComponent(props).find(ModalTitle).childAt(0).text()).toEqual("Delete ".concat(props.type));
|
|
31
31
|
});
|
|
32
32
|
it('calls the onClose callback when the Cancel button is clicked', () => {
|
|
33
33
|
getDeleteDialogComponent(props).find(Button).first().simulate('click');
|
|
@@ -29,7 +29,7 @@ describe('The FileMenu - RenameDialog component', () => {
|
|
|
29
29
|
expect(getRenameDialogComponent(props).find(Modal)).toHaveLength(1);
|
|
30
30
|
});
|
|
31
31
|
it('renders a ModalTitle containing the type prop', () => {
|
|
32
|
-
expect(getRenameDialogComponent(props).find(ModalTitle).childAt(0).text()).toEqual(
|
|
32
|
+
expect(getRenameDialogComponent(props).find(ModalTitle).childAt(0).text()).toEqual("Rename ".concat(props.type));
|
|
33
33
|
});
|
|
34
34
|
it('renders a InputField for name', () => {
|
|
35
35
|
expect(getRenameDialogComponent(props).findWhere(n => n.prop('label') === 'Name')).toHaveLength(1);
|
|
@@ -32,7 +32,7 @@ describe('The FileMenu - SaveAsDialog component', () => {
|
|
|
32
32
|
expect(getSaveAsDialogComponent(props).find(Modal)).toHaveLength(1);
|
|
33
33
|
});
|
|
34
34
|
it('renders a ModalTitle containing the type prop', () => {
|
|
35
|
-
expect(getSaveAsDialogComponent(props).find(ModalTitle).childAt(0).text()).toEqual(
|
|
35
|
+
expect(getSaveAsDialogComponent(props).find(ModalTitle).childAt(0).text()).toEqual("Save ".concat(props.type, " as"));
|
|
36
36
|
});
|
|
37
37
|
it('renders a InputField for name with prefilled value from the object prop', () => {
|
|
38
38
|
const nameInputField = getSaveAsDialogComponent(props).findWhere(n => n.prop('label') === 'Name');
|
|
@@ -4,16 +4,16 @@ export const endpointFromFileType = fileType => {
|
|
|
4
4
|
case 'visualization':
|
|
5
5
|
case 'map':
|
|
6
6
|
default:
|
|
7
|
-
return
|
|
7
|
+
return "".concat(fileType, "s");
|
|
8
8
|
}
|
|
9
9
|
};
|
|
10
10
|
export const appPathFor = (fileType, id) => {
|
|
11
11
|
switch (fileType) {
|
|
12
12
|
case 'visualization':
|
|
13
|
-
return
|
|
13
|
+
return "dhis-web-data-visualizer/#/".concat(id);
|
|
14
14
|
|
|
15
15
|
case 'map':
|
|
16
|
-
return
|
|
16
|
+
return "dhis-web-maps/index.html?id=".concat(id);
|
|
17
17
|
|
|
18
18
|
default:
|
|
19
19
|
return;
|
|
@@ -12,7 +12,7 @@ const Filter = ({
|
|
|
12
12
|
type,
|
|
13
13
|
dataTest
|
|
14
14
|
}) => /*#__PURE__*/React.createElement("div", {
|
|
15
|
-
className:
|
|
15
|
+
className: "jsx-".concat(styles.__hash) + " " + "container"
|
|
16
16
|
}, /*#__PURE__*/React.createElement(InputField, {
|
|
17
17
|
placeholder: placeholder,
|
|
18
18
|
onChange: ref => ref.value.length ? onChange(ref.value) : onClear(),
|
|
@@ -1,4 +1,4 @@
|
|
|
1
1
|
import { spacers } from '@dhis2/ui';
|
|
2
|
-
const _defaultExport = [
|
|
2
|
+
const _defaultExport = [".container.jsx-2445670963{margin-bottom:".concat(spacers.dp16, ";}")];
|
|
3
3
|
_defaultExport.__hash = "2445670963";
|
|
4
4
|
export default _defaultExport;
|
|
@@ -9,26 +9,26 @@ const LegendKey = ({
|
|
|
9
9
|
}) => {
|
|
10
10
|
return legendSets.length ? /*#__PURE__*/React.createElement("div", {
|
|
11
11
|
"data-test": 'legend-key-container',
|
|
12
|
-
className:
|
|
12
|
+
className: "jsx-".concat(styles.__hash) + " " + "container"
|
|
13
13
|
}, legendSets.map((legendSet, index) => /*#__PURE__*/React.createElement("div", {
|
|
14
14
|
key: legendSet.id,
|
|
15
|
-
"data-test":
|
|
16
|
-
className:
|
|
15
|
+
"data-test": "legend-key-item-".concat(legendSet.id),
|
|
16
|
+
className: "jsx-".concat(styles.__hash) + " " + (cx('legendSet', {
|
|
17
17
|
divider: index > 0
|
|
18
18
|
}) || "")
|
|
19
19
|
}, legendSets.length > 1 && /*#__PURE__*/React.createElement("span", {
|
|
20
|
-
className:
|
|
20
|
+
className: "jsx-".concat(styles.__hash) + " " + "legendSetName"
|
|
21
21
|
}, legendSet.name), legendSet.legends.sort((a, b) => a.startValue - b.startValue).map(legend => /*#__PURE__*/React.createElement("div", {
|
|
22
22
|
key: legend.startValue,
|
|
23
23
|
style: {
|
|
24
|
-
borderLeft:
|
|
24
|
+
borderLeft: "6px ".concat(legend.color, " solid")
|
|
25
25
|
},
|
|
26
|
-
className:
|
|
26
|
+
className: "jsx-".concat(styles.__hash) + " " + "legend"
|
|
27
27
|
}, /*#__PURE__*/React.createElement("span", {
|
|
28
|
-
className:
|
|
28
|
+
className: "jsx-".concat(styles.__hash)
|
|
29
29
|
}, legend.name), /*#__PURE__*/React.createElement("span", {
|
|
30
|
-
className:
|
|
31
|
-
},
|
|
30
|
+
className: "jsx-".concat(styles.__hash) + " " + "values"
|
|
31
|
+
}, "".concat(legend.startValue, "-<").concat(legend.endValue)))))), /*#__PURE__*/React.createElement(_JSXStyle, {
|
|
32
32
|
id: styles.__hash
|
|
33
33
|
}, styles)) : null;
|
|
34
34
|
};
|
|
@@ -1,4 +1,4 @@
|
|
|
1
1
|
import { spacers, colors } from '@dhis2/ui';
|
|
2
|
-
const _defaultExport = [
|
|
2
|
+
const _defaultExport = [".container.jsx-3203773516{width:180px;background:".concat(colors.white, ";padding:").concat(spacers.dp8, ";border:1px solid ").concat(colors.grey400, ";}"), ".legendSet.jsx-3203773516{display:-webkit-box;display:-webkit-flex;display:-ms-flexbox;display:flex;-webkit-flex-direction:column;-ms-flex-direction:column;flex-direction:column;margin-left:".concat(spacers.dp4, ";}"), ".legendSetName.jsx-3203773516{display:inline-block;font-size:13px;color:".concat(colors.grey700, ";margin-bottom:2px;}"), ".legend.jsx-3203773516{display:-webkit-box;display:-webkit-flex;display:-ms-flexbox;display:flex;-webkit-flex-direction:column;-ms-flex-direction:column;flex-direction:column;-webkit-flex-wrap:wrap;-ms-flex-wrap:wrap;flex-wrap:wrap;padding:".concat(spacers.dp4, " 0 ").concat(spacers.dp4, " 6px;white-space:break-spaces;text-align:left;font-size:13px;}"), ".values.jsx-3203773516{color:".concat(colors.grey600, ";font-size:12px;padding-top:2px;}"), ".divider.jsx-3203773516{border-top:1px solid ".concat(colors.grey400, ";padding-top:").concat(spacers.dp8, ";margin-top:").concat(spacers.dp8, ";}")];
|
|
3
3
|
_defaultExport.__hash = "3203773516";
|
|
4
4
|
export default _defaultExport;
|