diff --git a/src/components/AboutAOUnit/AboutAOUnit.js b/src/components/AboutAOUnit/AboutAOUnit.js
index cb4a65cb7..1e2d77ab1 100644
--- a/src/components/AboutAOUnit/AboutAOUnit.js
+++ b/src/components/AboutAOUnit/AboutAOUnit.js
@@ -3,6 +3,7 @@ import {
useDataMutation,
useTimeZoneConversion,
} from '@dhis2/app-runtime'
+import i18n from '@dhis2/d2-i18n'
import {
Button,
CircularLoader,
@@ -26,7 +27,6 @@ import React, {
forwardRef,
useImperativeHandle,
} from 'react'
-import i18n from '../../locales/index.js'
import { formatList } from '../../modules/list.js'
import { RichTextParser } from '../RichText/index.js'
import styles from './styles/AboutAOUnit.style.js'
diff --git a/src/components/AboutAOUnit/utils.js b/src/components/AboutAOUnit/utils.js
index 4cbaecb49..88bae014c 100644
--- a/src/components/AboutAOUnit/utils.js
+++ b/src/components/AboutAOUnit/utils.js
@@ -1,4 +1,4 @@
-import i18n from '../../locales/index.js'
+import i18n from '@dhis2/d2-i18n'
export const AO_TYPE_VISUALIZATION = 'visualization'
export const AO_TYPE_MAP = 'map'
diff --git a/src/components/CachedDataQueryProvider.js b/src/components/CachedDataQueryProvider.js
index d1b8f542f..e4a3786d0 100644
--- a/src/components/CachedDataQueryProvider.js
+++ b/src/components/CachedDataQueryProvider.js
@@ -1,8 +1,8 @@
import { useDataQuery } from '@dhis2/app-runtime'
+import i18n from '@dhis2/d2-i18n'
import { Layer, CenteredContent, CircularLoader, NoticeBox } from '@dhis2/ui'
import PropTypes from 'prop-types'
import React, { createContext, useContext } from 'react'
-import i18n from '../locales/index.js'
const CachedDataQueryCtx = createContext({})
diff --git a/src/components/DataDimension/Calculation/CalculationModal.js b/src/components/DataDimension/Calculation/CalculationModal.js
index 6fdcf8119..4590d4013 100644
--- a/src/components/DataDimension/Calculation/CalculationModal.js
+++ b/src/components/DataDimension/Calculation/CalculationModal.js
@@ -1,4 +1,5 @@
import { useAlert, useDataMutation, useDataQuery } from '@dhis2/app-runtime'
+import i18n from '@dhis2/d2-i18n'
import {
Button,
Modal,
@@ -17,7 +18,6 @@ import {
updateCalculationMutation,
validateExpressionMutation,
} from '../../../api/expression.js'
-import i18n from '../../../locales/index.js'
import {
parseExpressionToArray,
parseArrayToExpression,
diff --git a/src/components/DataDimension/Calculation/DataElementSelector.js b/src/components/DataDimension/Calculation/DataElementSelector.js
index 123fe20fd..06984b5d9 100644
--- a/src/components/DataDimension/Calculation/DataElementSelector.js
+++ b/src/components/DataDimension/Calculation/DataElementSelector.js
@@ -1,4 +1,5 @@
import { useDataEngine } from '@dhis2/app-runtime'
+import i18n from '@dhis2/d2-i18n'
import {
CircularLoader,
InputField,
@@ -12,7 +13,6 @@ import cx from 'classnames'
import PropTypes from 'prop-types'
import React, { useEffect, useRef, useState } from 'react'
import { apiFetchOptions, apiFetchGroups } from '../../../api/dimensions.js'
-import i18n from '../../../locales/index.js'
import {
TOTALS,
DETAIL,
diff --git a/src/components/DataDimension/Calculation/FormulaField.js b/src/components/DataDimension/Calculation/FormulaField.js
index 79cdcea82..388394deb 100644
--- a/src/components/DataDimension/Calculation/FormulaField.js
+++ b/src/components/DataDimension/Calculation/FormulaField.js
@@ -1,10 +1,10 @@
+import i18n from '@dhis2/d2-i18n'
import { Center, CircularLoader } from '@dhis2/ui'
import { useDroppable } from '@dnd-kit/core'
import { SortableContext } from '@dnd-kit/sortable'
import PropTypes from 'prop-types'
import React from 'react'
import FormulaIcon from '../../../assets/FormulaIcon.js'
-import i18n from '../../../locales/index.js'
import DropZone from './DropZone.js'
import FormulaItem from './FormulaItem.js'
import styles from './styles/FormulaField.style.js'
diff --git a/src/components/DataDimension/Calculation/MathOperatorSelector.js b/src/components/DataDimension/Calculation/MathOperatorSelector.js
index d87689f6a..0a6b694d0 100644
--- a/src/components/DataDimension/Calculation/MathOperatorSelector.js
+++ b/src/components/DataDimension/Calculation/MathOperatorSelector.js
@@ -1,6 +1,6 @@
+import i18n from '@dhis2/d2-i18n'
import PropTypes from 'prop-types'
import React from 'react'
-import i18n from '../../../locales/index.js'
import { getOperators } from '../../../modules/expressions.js'
import DraggableOperator from './Operator.js'
import styles from './styles/MathOperatorSelector.style.js'
diff --git a/src/components/DataDimension/DataTypeSelector.js b/src/components/DataDimension/DataTypeSelector.js
index 62d273097..617416187 100644
--- a/src/components/DataDimension/DataTypeSelector.js
+++ b/src/components/DataDimension/DataTypeSelector.js
@@ -1,7 +1,7 @@
+import i18n from '@dhis2/d2-i18n'
import { SingleSelectField, SingleSelectOption } from '@dhis2/ui'
import PropTypes from 'prop-types'
import React from 'react'
-import i18n from '../../locales/index.js'
import { DIMENSION_TYPE_ALL, dataTypeMap } from '../../modules/dataTypes.js'
import { getDisplayNameByVisType } from '../../modules/visTypes.js'
import { useDataDimensionContext } from './DataDimension.js'
diff --git a/src/components/DataDimension/DetailSelector.js b/src/components/DataDimension/DetailSelector.js
index 82e2b7df5..6904f6176 100644
--- a/src/components/DataDimension/DetailSelector.js
+++ b/src/components/DataDimension/DetailSelector.js
@@ -1,7 +1,7 @@
+import i18n from '@dhis2/d2-i18n'
import { SingleSelectField, SingleSelectOption } from '@dhis2/ui'
import PropTypes from 'prop-types'
import React from 'react'
-import i18n from '../../locales/index.js'
import { TOTALS, DETAIL } from '../../modules/dataTypes.js'
import styles from './styles/DetailSelector.style.js'
diff --git a/src/components/DataDimension/GroupSelector.js b/src/components/DataDimension/GroupSelector.js
index d20fd866c..f8df1f3e7 100644
--- a/src/components/DataDimension/GroupSelector.js
+++ b/src/components/DataDimension/GroupSelector.js
@@ -1,9 +1,9 @@
import { useDataEngine } from '@dhis2/app-runtime'
+import i18n from '@dhis2/d2-i18n'
import { SingleSelectField, SingleSelectOption } from '@dhis2/ui'
import PropTypes from 'prop-types'
import React, { useEffect, useState } from 'react'
import { apiFetchGroups } from '../../api/dimensions.js'
-import i18n from '../../locales/index.js'
import {
dataTypeMap as dataTypes,
SUB_GROUP_DETAIL,
diff --git a/src/components/DataDimension/ItemSelector.js b/src/components/DataDimension/ItemSelector.js
index 5c36b478a..fabcbcb45 100644
--- a/src/components/DataDimension/ItemSelector.js
+++ b/src/components/DataDimension/ItemSelector.js
@@ -1,9 +1,9 @@
import { useDataEngine } from '@dhis2/app-runtime'
+import i18n from '@dhis2/d2-i18n'
import { Transfer, InputField, IconInfo16, Button, IconAdd24 } from '@dhis2/ui'
import PropTypes from 'prop-types'
import React, { useState } from 'react'
import { apiFetchOptions } from '../../api/dimensions.js'
-import i18n from '../../locales/index.js'
import { DATA_SETS_CONSTANTS, REPORTING_RATE } from '../../modules/dataSets.js'
import {
DIMENSION_TYPE_ALL,
diff --git a/src/components/DataDimension/MetricSelector.js b/src/components/DataDimension/MetricSelector.js
index 9ffd746a3..9a2c0f259 100644
--- a/src/components/DataDimension/MetricSelector.js
+++ b/src/components/DataDimension/MetricSelector.js
@@ -1,7 +1,7 @@
+import i18n from '@dhis2/d2-i18n'
import { SingleSelectField, SingleSelectOption } from '@dhis2/ui'
import PropTypes from 'prop-types'
import React from 'react'
-import i18n from '../../locales/index.js'
import { DATA_SETS_CONSTANTS } from '../../modules/dataSets.js'
import { DIMENSION_TYPE_ALL } from '../../modules/dataTypes.js'
import styles from './styles/MetricSelector.style.js'
diff --git a/src/components/DimensionMenu.js b/src/components/DimensionMenu.js
index f416a9213..cac023d4a 100644
--- a/src/components/DimensionMenu.js
+++ b/src/components/DimensionMenu.js
@@ -1,7 +1,7 @@
+import i18n from '@dhis2/d2-i18n'
import { MenuDivider, FlyoutMenu, MenuItem, Tooltip } from '@dhis2/ui'
import PropTypes from 'prop-types'
import React from 'react'
-import i18n from '../locales/index.js'
import { getAxisNameByLayoutType } from '../modules/axis.js'
import { AXIS_ID_FILTERS } from '../modules/layout/axis.js'
import { getAvailableAxes } from '../modules/layoutUiRules/index.js'
diff --git a/src/components/DimensionsPanel/DimensionsPanel.js b/src/components/DimensionsPanel/DimensionsPanel.js
index e500761ae..90a1e3aae 100644
--- a/src/components/DimensionsPanel/DimensionsPanel.js
+++ b/src/components/DimensionsPanel/DimensionsPanel.js
@@ -1,6 +1,6 @@
+import i18n from '@dhis2/d2-i18n'
import PropTypes from 'prop-types'
import React, { Component } from 'react'
-import i18n from '../../locales/index.js'
import Filter from '../Filter/Filter.js'
import DimensionList from './List/DimensionList.js'
import { styles } from './styles/DimensionsPanel.style.js'
diff --git a/src/components/DimensionsPanel/List/DimensionList.js b/src/components/DimensionsPanel/List/DimensionList.js
index 16e623ef8..6c9982448 100644
--- a/src/components/DimensionsPanel/List/DimensionList.js
+++ b/src/components/DimensionsPanel/List/DimensionList.js
@@ -1,6 +1,6 @@
+import i18n from '@dhis2/d2-i18n'
import PropTypes from 'prop-types'
import React, { Component } from 'react'
-import i18n from '../../../locales/index.js'
import {
getPredefinedDimensions,
getFixedDimensions,
diff --git a/src/components/DimensionsPanel/List/RecommendedIcon.js b/src/components/DimensionsPanel/List/RecommendedIcon.js
index 12609d3a7..fd7f23e91 100644
--- a/src/components/DimensionsPanel/List/RecommendedIcon.js
+++ b/src/components/DimensionsPanel/List/RecommendedIcon.js
@@ -1,7 +1,7 @@
+import i18n from '@dhis2/d2-i18n'
import { Tooltip } from '@dhis2/ui'
import PropTypes from 'prop-types'
import React from 'react'
-import i18n from '../../../locales/index.js'
import { styles } from './styles/RecommendedIcon.style.js'
const RecommendedIcon = ({ isRecommended, dataTest }) =>
diff --git a/src/components/DynamicDimension/DynamicDimension.js b/src/components/DynamicDimension/DynamicDimension.js
index 5f757b97b..577479a1a 100644
--- a/src/components/DynamicDimension/DynamicDimension.js
+++ b/src/components/DynamicDimension/DynamicDimension.js
@@ -1,9 +1,9 @@
import { useDataEngine } from '@dhis2/app-runtime'
+import i18n from '@dhis2/d2-i18n'
import { Radio, Field } from '@dhis2/ui'
import PropTypes from 'prop-types'
import React from 'react'
import { apiFetchItemsByDimension } from '../../api/dimensions.js'
-import i18n from '../../locales/index.js'
import ItemSelector from './ItemSelector.js'
import styles from './styles/DynamicDimension.style.js'
diff --git a/src/components/DynamicDimension/ItemSelector.js b/src/components/DynamicDimension/ItemSelector.js
index 9c2cdd6d8..e168f9228 100644
--- a/src/components/DynamicDimension/ItemSelector.js
+++ b/src/components/DynamicDimension/ItemSelector.js
@@ -1,8 +1,8 @@
+import i18n from '@dhis2/d2-i18n'
import { Transfer, InputField } from '@dhis2/ui'
import PropTypes from 'prop-types'
import React, { useState, useEffect, useCallback } from 'react'
import GenericIcon from '../../assets/DimensionItemIcons/GenericIcon.js'
-import i18n from '../../locales/index.js'
import {
TRANSFER_HEIGHT,
TRANSFER_OPTIONS_WIDTH,
diff --git a/src/components/FileMenu/DeleteDialog.js b/src/components/FileMenu/DeleteDialog.js
index 2f7937f23..c3d473cd5 100644
--- a/src/components/FileMenu/DeleteDialog.js
+++ b/src/components/FileMenu/DeleteDialog.js
@@ -1,4 +1,5 @@
import { useDataMutation } from '@dhis2/app-runtime'
+import i18n from '@dhis2/d2-i18n'
import {
Modal,
ModalTitle,
@@ -9,7 +10,6 @@ import {
} from '@dhis2/ui'
import PropTypes from 'prop-types'
import React, { useMemo } from 'react'
-import i18n from '../../locales/index.js'
import {
supportedFileTypes,
endpointFromFileType,
diff --git a/src/components/FileMenu/FileMenu.js b/src/components/FileMenu/FileMenu.js
index f81a3145c..e5e0f29ed 100644
--- a/src/components/FileMenu/FileMenu.js
+++ b/src/components/FileMenu/FileMenu.js
@@ -1,3 +1,4 @@
+import i18n from '@dhis2/d2-i18n'
import {
IconAdd24,
IconLaunch24,
@@ -13,7 +14,6 @@ import {
} from '@dhis2/ui'
import PropTypes from 'prop-types'
import React, { useState } from 'react'
-import i18n from '../../locales/index.js'
import { OpenFileDialog } from '../OpenFileDialog/OpenFileDialog.js'
import {
HoverMenuListItem,
diff --git a/src/components/FileMenu/GetLinkDialog.js b/src/components/FileMenu/GetLinkDialog.js
index c1c1a0cf1..eb705cddc 100644
--- a/src/components/FileMenu/GetLinkDialog.js
+++ b/src/components/FileMenu/GetLinkDialog.js
@@ -1,4 +1,5 @@
import { useConfig } from '@dhis2/app-runtime'
+import i18n from '@dhis2/d2-i18n'
import {
Modal,
ModalContent,
@@ -9,7 +10,6 @@ import {
} from '@dhis2/ui'
import PropTypes from 'prop-types'
import React from 'react'
-import i18n from '../../locales/index.js'
import { styles } from './GetLinkDialog.styles.js'
import { supportedFileTypes, appPathFor } from './utils.js'
diff --git a/src/components/FileMenu/RenameDialog.js b/src/components/FileMenu/RenameDialog.js
index fe8f64328..ffc309f88 100644
--- a/src/components/FileMenu/RenameDialog.js
+++ b/src/components/FileMenu/RenameDialog.js
@@ -1,4 +1,5 @@
import { useDataMutation } from '@dhis2/app-runtime'
+import i18n from '@dhis2/d2-i18n'
import {
Modal,
ModalTitle,
@@ -11,7 +12,6 @@ import {
} from '@dhis2/ui'
import PropTypes from 'prop-types'
import React, { useMemo, useState } from 'react'
-import i18n from '../../locales/index.js'
import { modalStyles } from './FileMenu.styles.js'
import {
supportedFileTypes,
diff --git a/src/components/FileMenu/SaveAsDialog.js b/src/components/FileMenu/SaveAsDialog.js
index 26a7f2894..f73c24d97 100644
--- a/src/components/FileMenu/SaveAsDialog.js
+++ b/src/components/FileMenu/SaveAsDialog.js
@@ -1,3 +1,4 @@
+import i18n from '@dhis2/d2-i18n'
import {
Modal,
ModalTitle,
@@ -10,7 +11,6 @@ import {
} from '@dhis2/ui'
import PropTypes from 'prop-types'
import React, { useState } from 'react'
-import i18n from '../../locales/index.js'
import { modalStyles } from './FileMenu.styles.js'
import { supportedFileTypes, labelForFileType } from './utils.js'
diff --git a/src/components/FileMenu/utils.js b/src/components/FileMenu/utils.js
index ae95418cc..5f69b331e 100644
--- a/src/components/FileMenu/utils.js
+++ b/src/components/FileMenu/utils.js
@@ -1,4 +1,4 @@
-import i18n from '../../locales/index.js'
+import i18n from '@dhis2/d2-i18n'
export const FILE_TYPE_EVENT_REPORT = 'eventReport'
export const FILE_TYPE_VISUALIZATION = 'visualization'
diff --git a/src/components/Interpretations/InterpretationModal/Comment.js b/src/components/Interpretations/InterpretationModal/Comment.js
index 22e1c49fc..e1fef4fe1 100644
--- a/src/components/Interpretations/InterpretationModal/Comment.js
+++ b/src/components/Interpretations/InterpretationModal/Comment.js
@@ -1,7 +1,7 @@
+import i18n from '@dhis2/d2-i18n'
import { IconEdit16 } from '@dhis2/ui'
import PropTypes from 'prop-types'
import React, { useState } from 'react'
-import i18n from '../../../locales/index.js'
import {
Message,
MessageIconButton,
diff --git a/src/components/Interpretations/InterpretationModal/CommentAddForm.js b/src/components/Interpretations/InterpretationModal/CommentAddForm.js
index 605993e27..0b8f98498 100644
--- a/src/components/Interpretations/InterpretationModal/CommentAddForm.js
+++ b/src/components/Interpretations/InterpretationModal/CommentAddForm.js
@@ -1,8 +1,8 @@
import { useDataMutation } from '@dhis2/app-runtime'
+import i18n from '@dhis2/d2-i18n'
import { Button } from '@dhis2/ui'
import PropTypes from 'prop-types'
import React, { useRef, useState } from 'react'
-import i18n from '../../../locales/index.js'
import { RichTextEditor } from '../../RichText/index.js'
import {
MessageEditorContainer,
diff --git a/src/components/Interpretations/InterpretationModal/CommentDeleteButton.js b/src/components/Interpretations/InterpretationModal/CommentDeleteButton.js
index 76fa68df7..363733235 100644
--- a/src/components/Interpretations/InterpretationModal/CommentDeleteButton.js
+++ b/src/components/Interpretations/InterpretationModal/CommentDeleteButton.js
@@ -1,8 +1,8 @@
import { useDataMutation } from '@dhis2/app-runtime'
+import i18n from '@dhis2/d2-i18n'
import { IconDelete16, colors } from '@dhis2/ui'
import PropTypes from 'prop-types'
import React, { useState } from 'react'
-import i18n from '../../../locales/index.js'
import { MessageIconButton } from '../common/index.js'
const mutation = {
diff --git a/src/components/Interpretations/InterpretationModal/CommentUpdateForm.js b/src/components/Interpretations/InterpretationModal/CommentUpdateForm.js
index ac37d8bcc..dc90d2175 100644
--- a/src/components/Interpretations/InterpretationModal/CommentUpdateForm.js
+++ b/src/components/Interpretations/InterpretationModal/CommentUpdateForm.js
@@ -1,8 +1,8 @@
import { useDataMutation } from '@dhis2/app-runtime'
+import i18n from '@dhis2/d2-i18n'
import { Button, spacers, colors } from '@dhis2/ui'
import PropTypes from 'prop-types'
import React, { useState, useRef } from 'react'
-import i18n from '../../../locales/index.js'
import { RichTextEditor } from '../../RichText/index.js'
import { MessageEditorContainer, MessageButtonStrip } from '../common/index.js'
diff --git a/src/components/Interpretations/InterpretationModal/InterpretationModal.js b/src/components/Interpretations/InterpretationModal/InterpretationModal.js
index 6d2e7aaeb..425eb053c 100644
--- a/src/components/Interpretations/InterpretationModal/InterpretationModal.js
+++ b/src/components/Interpretations/InterpretationModal/InterpretationModal.js
@@ -1,4 +1,5 @@
import { useDataQuery } from '@dhis2/app-runtime'
+import i18n from '@dhis2/d2-i18n'
import {
Modal,
ModalActions,
@@ -15,7 +16,6 @@ import cx from 'classnames'
import PropTypes from 'prop-types'
import React, { useEffect, useState, useMemo } from 'react'
import css from 'styled-jsx/css'
-import i18n from '../../../locales/index.js'
import { InterpretationThread } from './InterpretationThread.js'
import { useModalContentWidth } from './useModalContentWidth.js'
diff --git a/src/components/Interpretations/InterpretationsUnit/InterpretationForm.js b/src/components/Interpretations/InterpretationsUnit/InterpretationForm.js
index 6084c8985..c6467a453 100644
--- a/src/components/Interpretations/InterpretationsUnit/InterpretationForm.js
+++ b/src/components/Interpretations/InterpretationsUnit/InterpretationForm.js
@@ -1,8 +1,8 @@
import { useDataMutation } from '@dhis2/app-runtime'
+import i18n from '@dhis2/d2-i18n'
import { Button, Input } from '@dhis2/ui'
import PropTypes from 'prop-types'
import React, { useRef, useState } from 'react'
-import i18n from '../../../locales/index.js'
import { RichTextEditor } from '../../RichText/index.js'
import { MessageEditorContainer, MessageButtonStrip } from '../common/index.js'
diff --git a/src/components/Interpretations/InterpretationsUnit/InterpretationsUnit.js b/src/components/Interpretations/InterpretationsUnit/InterpretationsUnit.js
index c8070033f..33311fceb 100644
--- a/src/components/Interpretations/InterpretationsUnit/InterpretationsUnit.js
+++ b/src/components/Interpretations/InterpretationsUnit/InterpretationsUnit.js
@@ -1,4 +1,5 @@
import { useDataQuery } from '@dhis2/app-runtime'
+import i18n from '@dhis2/d2-i18n'
import {
CircularLoader,
IconChevronDown24,
@@ -15,7 +16,6 @@ import React, {
useImperativeHandle,
forwardRef,
} from 'react'
-import i18n from '../../../locales/index.js'
import { InterpretationForm } from './InterpretationForm.js'
import { InterpretationList } from './InterpretationList.js'
diff --git a/src/components/Interpretations/common/Interpretation/Interpretation.js b/src/components/Interpretations/common/Interpretation/Interpretation.js
index e8380de4a..8167aa244 100644
--- a/src/components/Interpretations/common/Interpretation/Interpretation.js
+++ b/src/components/Interpretations/common/Interpretation/Interpretation.js
@@ -1,3 +1,4 @@
+import i18n from '@dhis2/d2-i18n'
import {
Button,
SharingDialog,
@@ -10,7 +11,6 @@ import {
} from '@dhis2/ui'
import PropTypes from 'prop-types'
import React, { useState } from 'react'
-import i18n from '../../../../locales/index.js'
import {
Message,
MessageStatsBar,
diff --git a/src/components/Interpretations/common/Interpretation/InterpretationDeleteButton.js b/src/components/Interpretations/common/Interpretation/InterpretationDeleteButton.js
index 573b18ce3..cae57b00b 100644
--- a/src/components/Interpretations/common/Interpretation/InterpretationDeleteButton.js
+++ b/src/components/Interpretations/common/Interpretation/InterpretationDeleteButton.js
@@ -1,8 +1,8 @@
import { useDataMutation } from '@dhis2/app-runtime'
+import i18n from '@dhis2/d2-i18n'
import { IconDelete16 } from '@dhis2/ui'
import PropTypes from 'prop-types'
import React from 'react'
-import i18n from '../../../../locales/index.js'
import { MessageIconButton } from '../index.js'
const mutation = {
diff --git a/src/components/Interpretations/common/Interpretation/InterpretationSharingLink.js b/src/components/Interpretations/common/Interpretation/InterpretationSharingLink.js
index d381df6de..f13f6a94a 100644
--- a/src/components/Interpretations/common/Interpretation/InterpretationSharingLink.js
+++ b/src/components/Interpretations/common/Interpretation/InterpretationSharingLink.js
@@ -1,7 +1,7 @@
+import i18n from '@dhis2/d2-i18n'
import { SharingDialog, colors, spacers } from '@dhis2/ui'
import PropTypes from 'prop-types'
import React, { useState } from 'react'
-import i18n from '../../../../locales/index.js'
const InterpretationSharingLink = ({ type, id }) => {
const [showSharingDialog, setShowSharingDialog] = useState(false)
diff --git a/src/components/Interpretations/common/Interpretation/InterpretationUpdateForm.js b/src/components/Interpretations/common/Interpretation/InterpretationUpdateForm.js
index 2ad945234..9891d7052 100644
--- a/src/components/Interpretations/common/Interpretation/InterpretationUpdateForm.js
+++ b/src/components/Interpretations/common/Interpretation/InterpretationUpdateForm.js
@@ -1,8 +1,8 @@
import { useDataMutation } from '@dhis2/app-runtime'
+import i18n from '@dhis2/d2-i18n'
import { Button, spacers, colors } from '@dhis2/ui'
import PropTypes from 'prop-types'
import React, { useState } from 'react'
-import i18n from '../../../../locales/index.js'
import { RichTextEditor } from '../../../RichText/index.js'
import {
MessageEditorContainer,
diff --git a/src/components/OfflineTooltip.js b/src/components/OfflineTooltip.js
index 74da2f006..85b548532 100644
--- a/src/components/OfflineTooltip.js
+++ b/src/components/OfflineTooltip.js
@@ -1,9 +1,9 @@
import { useDhis2ConnectionStatus } from '@dhis2/app-runtime'
+import i18n from '@dhis2/d2-i18n'
import { Tooltip } from '@dhis2/ui'
import cx from 'classnames'
import PropTypes from 'prop-types'
import React from 'react'
-import i18n from '../locales/index.js'
import { styles } from './styles/OfflineTooltip.style.js'
const OfflineTooltip = ({
diff --git a/src/components/OpenFileDialog/CreatedByFilter.js b/src/components/OpenFileDialog/CreatedByFilter.js
index ae43db1f3..b7bd74a43 100644
--- a/src/components/OpenFileDialog/CreatedByFilter.js
+++ b/src/components/OpenFileDialog/CreatedByFilter.js
@@ -1,7 +1,7 @@
+import i18n from '@dhis2/d2-i18n'
import { SingleSelect, SingleSelectOption } from '@dhis2/ui'
import PropTypes from 'prop-types'
import React from 'react'
-import i18n from '../../locales/index.js'
// TODO change the "Created by" prefix to "Creator" or something that does not require a context for the translators
diff --git a/src/components/OpenFileDialog/CustomSelectOption.js b/src/components/OpenFileDialog/CustomSelectOption.js
index d5dcd8fcb..9e7f7b0ef 100644
--- a/src/components/OpenFileDialog/CustomSelectOption.js
+++ b/src/components/OpenFileDialog/CustomSelectOption.js
@@ -1,8 +1,8 @@
+import i18n from '@dhis2/d2-i18n'
import { MenuDivider, Tooltip } from '@dhis2/ui'
import cx from 'classnames'
import PropTypes from 'prop-types'
import React from 'react'
-import i18n from '../../locales/index.js'
import styles from './styles/CustomSelectOption.style.js'
const CustomSelectOptionItem = ({
diff --git a/src/components/OpenFileDialog/NameFilter.js b/src/components/OpenFileDialog/NameFilter.js
index 0e05aed71..1b6f3b2e3 100644
--- a/src/components/OpenFileDialog/NameFilter.js
+++ b/src/components/OpenFileDialog/NameFilter.js
@@ -1,7 +1,7 @@
+import i18n from '@dhis2/d2-i18n'
import { Input } from '@dhis2/ui'
import PropTypes from 'prop-types'
import React from 'react'
-import i18n from '../../locales/index.js'
export const NameFilter = ({ dataTest, value, onChange }) => (
(
(
diff --git a/src/components/TranslationDialog/TranslationModal/LocalesSelect.js b/src/components/TranslationDialog/TranslationModal/LocalesSelect.js
index 2f8b20c09..57a00078b 100644
--- a/src/components/TranslationDialog/TranslationModal/LocalesSelect.js
+++ b/src/components/TranslationDialog/TranslationModal/LocalesSelect.js
@@ -1,8 +1,8 @@
import { useDataQuery } from '@dhis2/app-runtime'
+import i18n from '@dhis2/d2-i18n'
import { SingleSelect, SingleSelectOption } from '@dhis2/ui'
import PropTypes from 'prop-types'
import React from 'react'
-import i18n from '../../../locales/index.js'
const query = {
locales: {
diff --git a/src/components/TranslationDialog/TranslationModal/TranslationForm.js b/src/components/TranslationDialog/TranslationModal/TranslationForm.js
index 440fac847..1152acb33 100644
--- a/src/components/TranslationDialog/TranslationModal/TranslationForm.js
+++ b/src/components/TranslationDialog/TranslationModal/TranslationForm.js
@@ -1,4 +1,5 @@
import { useAlert, useDataMutation } from '@dhis2/app-runtime'
+import i18n from '@dhis2/d2-i18n'
import {
CenteredContent,
DataTable,
@@ -12,7 +13,6 @@ import {
} from '@dhis2/ui'
import PropTypes from 'prop-types'
import React, { useEffect, useRef, useState } from 'react'
-import i18n from '../../../locales/index.js'
import { LocalesSelect } from './LocalesSelect.js'
import { TranslationModalActions } from './TranslationModalActions.js'
diff --git a/src/components/TranslationDialog/TranslationModal/TranslationModal.js b/src/components/TranslationDialog/TranslationModal/TranslationModal.js
index 57d277a81..0e0e6f80a 100644
--- a/src/components/TranslationDialog/TranslationModal/TranslationModal.js
+++ b/src/components/TranslationDialog/TranslationModal/TranslationModal.js
@@ -1,3 +1,4 @@
+import i18n from '@dhis2/d2-i18n'
import {
CenteredContent,
CircularLoader,
@@ -7,7 +8,6 @@ import {
} from '@dhis2/ui'
import PropTypes from 'prop-types'
import React, { useEffect, useState } from 'react'
-import i18n from '../../../locales/index.js'
import { TranslationForm } from './TranslationForm.js'
import { TranslationModalActions } from './TranslationModalActions.js'
import { useTranslationsResults } from './useTranslationsResults.js'
diff --git a/src/components/TranslationDialog/TranslationModal/TranslationModalActions.js b/src/components/TranslationDialog/TranslationModal/TranslationModalActions.js
index d3a09a067..71d2cd582 100644
--- a/src/components/TranslationDialog/TranslationModal/TranslationModalActions.js
+++ b/src/components/TranslationDialog/TranslationModal/TranslationModalActions.js
@@ -1,8 +1,8 @@
import { useDhis2ConnectionStatus } from '@dhis2/app-runtime'
+import i18n from '@dhis2/d2-i18n'
import { Button, ButtonStrip, ModalActions } from '@dhis2/ui'
import PropTypes from 'prop-types'
import React from 'react'
-import i18n from '../../../locales/index.js'
import { OfflineTooltip } from '../../OfflineTooltip.js'
const SaveButton = ({ disabled, loading, onClick }) => (
diff --git a/src/components/TranslationDialog/TranslationModal/useTranslationsResults.js b/src/components/TranslationDialog/TranslationModal/useTranslationsResults.js
index 844cc62d3..bed37cf8e 100644
--- a/src/components/TranslationDialog/TranslationModal/useTranslationsResults.js
+++ b/src/components/TranslationDialog/TranslationModal/useTranslationsResults.js
@@ -1,6 +1,6 @@
import { useAlert, useDataQuery } from '@dhis2/app-runtime'
+import i18n from '@dhis2/d2-i18n'
import { useRef } from 'react'
-import i18n from '../../../locales/index.js'
export const useTranslationsResults = ({ resource }) => {
const translationsQueryRef = useRef({
diff --git a/src/components/UserMention/UserList.js b/src/components/UserMention/UserList.js
index 1b9af72fe..5aa04a844 100644
--- a/src/components/UserMention/UserList.js
+++ b/src/components/UserMention/UserList.js
@@ -1,7 +1,7 @@
+import i18n from '@dhis2/d2-i18n'
import { MenuItem } from '@dhis2/ui'
import PropTypes from 'prop-types'
import React from 'react'
-import i18n from '../../locales/index.js'
export const UserList = ({ users, selectedUserIndex, onUserClick, pager }) => {
return (
diff --git a/src/components/UserMention/UserMentionWrapper.js b/src/components/UserMention/UserMentionWrapper.js
index 9d9c085e4..4550d5513 100644
--- a/src/components/UserMention/UserMentionWrapper.js
+++ b/src/components/UserMention/UserMentionWrapper.js
@@ -1,3 +1,4 @@
+import i18n from '@dhis2/d2-i18n'
import {
CenteredContent,
CircularLoader,
@@ -10,7 +11,6 @@ import {
} from '@dhis2/ui'
import PropTypes from 'prop-types'
import React, { useState, useRef } from 'react'
-import i18n from '../../locales/index.js'
import {
resolvedHeaderStyle,
userMentionWrapperClasses,
diff --git a/src/modules/axis.js b/src/modules/axis.js
index 0b68cd3f1..505984154 100644
--- a/src/modules/axis.js
+++ b/src/modules/axis.js
@@ -1,4 +1,4 @@
-import i18n from '../locales/index.js'
+import i18n from '@dhis2/d2-i18n'
import {
AXIS_ID_COLUMNS,
AXIS_ID_ROWS,
diff --git a/src/modules/dataSets.js b/src/modules/dataSets.js
index bac99b305..25b86c44e 100644
--- a/src/modules/dataSets.js
+++ b/src/modules/dataSets.js
@@ -1,4 +1,4 @@
-import i18n from '../locales/index.js'
+import i18n from '@dhis2/d2-i18n'
export const REPORTING_RATE = 'REPORTING_RATE'
export const REPORTING_RATE_ON_TIME = 'REPORTING_RATE_ON_TIME'
diff --git a/src/modules/dataTypes.js b/src/modules/dataTypes.js
index 7a7664726..42bdb9063 100644
--- a/src/modules/dataTypes.js
+++ b/src/modules/dataTypes.js
@@ -1,4 +1,4 @@
-import i18n from '../locales/index.js'
+import i18n from '@dhis2/d2-i18n'
export const DIMENSION_TYPE_ALL = 'ALL'
export const DIMENSION_TYPE_INDICATOR = 'INDICATOR'
diff --git a/src/modules/expressions.js b/src/modules/expressions.js
index 99eba9dcf..8174e6e3b 100644
--- a/src/modules/expressions.js
+++ b/src/modules/expressions.js
@@ -1,4 +1,4 @@
-import i18n from '../locales/index.js'
+import i18n from '@dhis2/d2-i18n'
export const EXPRESSION_TYPE_NUMBER = 'EXPRESSION_TYPE_NUMBER'
export const EXPRESSION_TYPE_OPERATOR = 'EXPRESSION_TYPE_OPERATOR'
diff --git a/src/modules/fontStyle.js b/src/modules/fontStyle.js
index abf0a3d72..b5e1ac806 100644
--- a/src/modules/fontStyle.js
+++ b/src/modules/fontStyle.js
@@ -1,6 +1,6 @@
/*eslint no-unused-vars: ["error", { "ignoreRestSiblings": true }]*/
+import i18n from '@dhis2/d2-i18n'
import { colors } from '@dhis2/ui'
-import i18n from '../locales/index.js'
// Font styles
export const FONT_STYLE_VISUALIZATION_TITLE = 'visualizationTitle'
diff --git a/src/modules/getOuLevelAndGroupText.js b/src/modules/getOuLevelAndGroupText.js
index f92e612c2..3ce553f68 100644
--- a/src/modules/getOuLevelAndGroupText.js
+++ b/src/modules/getOuLevelAndGroupText.js
@@ -1,4 +1,4 @@
-import i18n from '../locales/index.js'
+import i18n from '@dhis2/d2-i18n'
import { dimensionGetItems } from './layout/dimensionGetItems.js'
import { dimensionIs } from './layout/dimensionIs.js'
import { ouIdHelper } from './ouIdHelper/index.js'
diff --git a/src/modules/list.js b/src/modules/list.js
index fb99cb333..5baf6e3b7 100644
--- a/src/modules/list.js
+++ b/src/modules/list.js
@@ -1,4 +1,4 @@
-import i18n from '../locales/index.js'
+import i18n from '@dhis2/d2-i18n'
export const formatList = (items) => {
// Wrap Intl.ListFormat in try/catch as DHIS2 locales are not always ISO 639 compliant
diff --git a/src/modules/outliers/index.js b/src/modules/outliers/index.js
index 1cda2d458..b723fffb2 100644
--- a/src/modules/outliers/index.js
+++ b/src/modules/outliers/index.js
@@ -1,6 +1,6 @@
+import i18n from '@dhis2/d2-i18n'
import isNumber from 'd2-utilizr/lib/isNumber'
import isNumeric from 'd2-utilizr/lib/isNumeric'
-import i18n from '../../locales/index.js'
import { getIQRHelper, IQR } from './iqr.js'
import { getModZScoreHelper, MODIFIED_Z_SCORE } from './modZScore.js'
import { getNormalizationHelper, Y_RESIDUALS_LINEAR } from './normalization.js'
diff --git a/src/modules/outliers/iqr.js b/src/modules/outliers/iqr.js
index 78c6983a6..519b11802 100644
--- a/src/modules/outliers/iqr.js
+++ b/src/modules/outliers/iqr.js
@@ -1,4 +1,4 @@
-import i18n from '../../locales/index.js'
+import i18n from '@dhis2/d2-i18n'
import { PROP_THRESHOLD_FACTOR } from './index.js'
export const IQR = 'IQR'
diff --git a/src/modules/outliers/modZScore.js b/src/modules/outliers/modZScore.js
index d28b8a34b..1a26fa919 100644
--- a/src/modules/outliers/modZScore.js
+++ b/src/modules/outliers/modZScore.js
@@ -1,5 +1,5 @@
+import i18n from '@dhis2/d2-i18n'
import isNumber from 'd2-utilizr/lib/isNumber'
-import i18n from '../../locales/index.js'
import { PROP_THRESHOLD_FACTOR } from './index.js'
export const MODIFIED_Z_SCORE = 'MODIFIED_Z_SCORE'
diff --git a/src/modules/outliers/zScore.js b/src/modules/outliers/zScore.js
index de1057722..65923bab8 100644
--- a/src/modules/outliers/zScore.js
+++ b/src/modules/outliers/zScore.js
@@ -1,5 +1,5 @@
+import i18n from '@dhis2/d2-i18n'
import { std, mean } from 'mathjs'
-import i18n from '../../locales/index.js'
import { PROP_THRESHOLD_FACTOR } from './index.js'
export const STANDARD_Z_SCORE = 'STANDARD_Z_SCORE'
diff --git a/src/modules/pivotTable/PivotTableEngine.js b/src/modules/pivotTable/PivotTableEngine.js
index a50d2737d..ad798e686 100644
--- a/src/modules/pivotTable/PivotTableEngine.js
+++ b/src/modules/pivotTable/PivotTableEngine.js
@@ -1,5 +1,5 @@
+import i18n from '@dhis2/d2-i18n'
import times from 'lodash/times'
-import i18n from '../../locales/index.js'
import {
DIMENSION_TYPE_DATA,
DIMENSION_TYPE_DATA_ELEMENT_GROUP_SET,
diff --git a/src/modules/predefinedDimensions.js b/src/modules/predefinedDimensions.js
index 330f35ad2..a3295fd93 100644
--- a/src/modules/predefinedDimensions.js
+++ b/src/modules/predefinedDimensions.js
@@ -1,10 +1,10 @@
+import i18n from '@dhis2/d2-i18n'
import {
IconClock16,
IconDimensionData16,
IconDimensionOrgUnit16,
} from '@dhis2/ui'
import AssignedCategoriesIcon from '../assets/AssignedCategoriesIcon.js'
-import i18n from '../locales/index.js'
export const DIMENSION_ID_DATA = 'dx'
export const DIMENSION_ID_PERIOD = 'pe'
diff --git a/src/modules/visTypes.js b/src/modules/visTypes.js
index bd7a9b37a..3626dfb76 100644
--- a/src/modules/visTypes.js
+++ b/src/modules/visTypes.js
@@ -1,3 +1,4 @@
+import i18n from '@dhis2/d2-i18n'
import {
IconVisualizationArea24,
IconVisualizationAreaStacked24,
@@ -17,7 +18,6 @@ import {
IconVisualizationScatter24,
IconVisualizationSingleValue24,
} from '@dhis2/ui'
-import i18n from '../locales/index.js'
export const VIS_TYPE_PIVOT_TABLE = 'PIVOT_TABLE'
export const VIS_TYPE_AREA = 'AREA'
export const VIS_TYPE_STACKED_AREA = 'STACKED_AREA'
diff --git a/src/visualizations/config/adapters/dhis_highcharts/addTrendLines.js b/src/visualizations/config/adapters/dhis_highcharts/addTrendLines.js
index 1ee8512f7..acd7b96c4 100644
--- a/src/visualizations/config/adapters/dhis_highcharts/addTrendLines.js
+++ b/src/visualizations/config/adapters/dhis_highcharts/addTrendLines.js
@@ -1,6 +1,6 @@
+import i18n from '@dhis2/d2-i18n'
import arrayContains from 'd2-utilizr/lib/arrayContains'
import { rgb } from 'd3-color'
-import i18n from '../../../../locales/index.js'
import {
VIS_TYPE_GAUGE,
VIS_TYPE_PIE,
diff --git a/src/visualizations/config/adapters/dhis_highcharts/legendSet.js b/src/visualizations/config/adapters/dhis_highcharts/legendSet.js
index 8e328c678..8c7c3c700 100644
--- a/src/visualizations/config/adapters/dhis_highcharts/legendSet.js
+++ b/src/visualizations/config/adapters/dhis_highcharts/legendSet.js
@@ -1,5 +1,5 @@
+import i18n from '@dhis2/d2-i18n'
import isNumeric from 'd2-utilizr/lib/isNumeric'
-import i18n from '../../../../locales/index.js'
import { getLegendByValueFromLegendSet } from '../../../../modules/legends.js'
const OUT_OF_BOUNDS_COLOR = '#CCCCCC'
diff --git a/src/visualizations/config/adapters/dhis_highcharts/plotOptions.js b/src/visualizations/config/adapters/dhis_highcharts/plotOptions.js
index e9e775096..4e9dd1576 100644
--- a/src/visualizations/config/adapters/dhis_highcharts/plotOptions.js
+++ b/src/visualizations/config/adapters/dhis_highcharts/plotOptions.js
@@ -1,4 +1,4 @@
-import i18n from '../../../../locales/index.js'
+import i18n from '@dhis2/d2-i18n'
import {
VIS_TYPE_COLUMN,
VIS_TYPE_SCATTER,
diff --git a/src/visualizations/config/adapters/dhis_highcharts/series/scatter.js b/src/visualizations/config/adapters/dhis_highcharts/series/scatter.js
index c99ae23f6..73e1deef8 100644
--- a/src/visualizations/config/adapters/dhis_highcharts/series/scatter.js
+++ b/src/visualizations/config/adapters/dhis_highcharts/series/scatter.js
@@ -1,4 +1,4 @@
-import i18n from '../../../../../locales/index.js'
+import i18n from '@dhis2/d2-i18n'
const DEFAULT_COLOR = '#a8bf24'
const OUTLIER_COLOR = 'red'
diff --git a/src/visualizations/config/adapters/dhis_highcharts/yAxis/gauge.js b/src/visualizations/config/adapters/dhis_highcharts/yAxis/gauge.js
index 3b4d6f71a..164e20ce5 100644
--- a/src/visualizations/config/adapters/dhis_highcharts/yAxis/gauge.js
+++ b/src/visualizations/config/adapters/dhis_highcharts/yAxis/gauge.js
@@ -1,7 +1,7 @@
+import i18n from '@dhis2/d2-i18n'
import arrayClean from 'd2-utilizr/lib/arrayClean'
import isNumber from 'd2-utilizr/lib/isNumber'
import objectClean from 'd2-utilizr/lib/objectClean'
-import i18n from '../../../../../locales/index.js'
import {
FONT_STYLE_OPTION_TEXT_COLOR,
FONT_STYLE_OPTION_FONT_SIZE,
diff --git a/src/visualizations/config/adapters/dhis_highcharts/yAxis/index.js b/src/visualizations/config/adapters/dhis_highcharts/yAxis/index.js
index d253acdff..efda0596c 100644
--- a/src/visualizations/config/adapters/dhis_highcharts/yAxis/index.js
+++ b/src/visualizations/config/adapters/dhis_highcharts/yAxis/index.js
@@ -1,6 +1,6 @@
+import i18n from '@dhis2/d2-i18n'
import arrayClean from 'd2-utilizr/lib/arrayClean'
import objectClean from 'd2-utilizr/lib/objectClean'
-import i18n from '../../../../../locales/index.js'
import {
FONT_STYLE_VERTICAL_AXIS_TITLE,
mergeFontStyleWithDefault,
diff --git a/src/visualizations/config/index.js b/src/visualizations/config/index.js
index 28ca603d9..b85ae0817 100644
--- a/src/visualizations/config/index.js
+++ b/src/visualizations/config/index.js
@@ -1,4 +1,4 @@
-import i18n from '../../locales/index.js'
+import i18n from '@dhis2/d2-i18n'
import { theme1 } from '../util/colors/index.js'
import adapters from './adapters/index.js'
import generators from './generators/index.js'