feat(i18n): enhanced i18n support (#3761)
This commit is contained in:
1 parent
5a5c4f58af
commit
d14a8f0199
55 files changed
+319
-114
No files matched your search
+5
-4
@@ -1,4 +1,5 @@
|
||||
import { ButtonEnums } from '@ohif/ui';
|
||||
import i18n from 'i18next';
|
||||
|
||||
const RESPONSE = {
|
||||
NO_NEVER: -1,
|
||||
@@ -26,24 +27,24 @@ function promptBeginTracking({ servicesManager, extensionManager }, ctx, evt) {
|
||||
|
||||
function _askTrackMeasurements(uiViewportDialogService, viewportId) {
|
||||
return new Promise(function (resolve, reject) {
|
||||
const message = 'Track measurements for this series?';
|
||||
const message = i18n.t('MeasurementTable:Track measurements for this series?');
|
||||
const actions = [
|
||||
{
|
||||
id: 'prompt-begin-tracking-cancel',
|
||||
type: ButtonEnums.type.secondary,
|
||||
text: 'No',
|
||||
text: i18n.t('Common:No'),
|
||||
value: RESPONSE.CANCEL,
|
||||
},
|
||||
{
|
||||
id: 'prompt-begin-tracking-no-do-not-ask-again',
|
||||
type: ButtonEnums.type.secondary,
|
||||
text: 'No, do not ask again',
|
||||
text: i18n.t('MeasurementTable:No, do not ask again'),
|
||||
value: RESPONSE.NO_NEVER,
|
||||
},
|
||||
{
|
||||
id: 'prompt-begin-tracking-yes',
|
||||
type: ButtonEnums.type.primary,
|
||||
text: 'Yes',
|
||||
text: i18n.t('Common:Yes'),
|
||||
value: RESPONSE.SET_STUDY_AND_SERIES,
|
||||
},
|
||||
];
|
||||
|
||||
+6
-4
@@ -1,3 +1,5 @@
|
||||
import i18n from 'i18next';
|
||||
|
||||
const RESPONSE = {
|
||||
NO_NEVER: -1,
|
||||
CANCEL: 0,
|
||||
@@ -32,17 +34,17 @@ function promptTrackNewStudy({ servicesManager, extensionManager }, ctx, evt) {
|
||||
|
||||
function _askTrackMeasurements(UIViewportDialogService, viewportId) {
|
||||
return new Promise(function (resolve, reject) {
|
||||
const message = 'Track measurements for this series?';
|
||||
const message = i18n.t('MeasurementTable:Track measurements for this series?');
|
||||
const actions = [
|
||||
{ type: 'cancel', text: 'No', value: RESPONSE.CANCEL },
|
||||
{ type: 'cancel', text: i18n.t('MeasurementTable:No'), value: RESPONSE.CANCEL },
|
||||
{
|
||||
type: 'secondary',
|
||||
text: 'No, do not ask again for this series',
|
||||
text: i18n.t('MeasurementTable:No, do not ask again'),
|
||||
value: RESPONSE.NO_NOT_FOR_SERIES,
|
||||
},
|
||||
{
|
||||
type: 'primary',
|
||||
text: 'Yes',
|
||||
text: i18n.t('MeasurementTable:Yes'),
|
||||
value: RESPONSE.SET_STUDY_AND_SERIES,
|
||||
},
|
||||
];
|
||||
|
||||
Reference in new issue
Block a user