Skip to content

Commit 25ef83f

Browse files
committed
chore: fix translation issues
1 parent ee8945b commit 25ef83f

File tree

2 files changed

+6
-1
lines changed

2 files changed

+6
-1
lines changed

src/javascript/_common/localize.js

+5
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,5 @@
11
const moment = require('moment');
2+
const { urlLang } = require('./language');
23
require('moment/min/locales');
34
const template = require('./utility').template;
45

@@ -15,6 +16,10 @@ const Localize = (() => {
1516

1617
const index = text.replace(/[\s|.]/g, '_');
1718

19+
const lang = urlLang().toUpperCase();
20+
21+
localized_texts = texts_json[lang];
22+
1823
text = (localized_texts && localized_texts[index]) || text;
1924

2025
// only use template when explicitly required

src/javascript/app/pages/bottom/explanation_data.js

+1-1
Original file line numberDiff line numberDiff line change
@@ -198,7 +198,7 @@ export const contractExplanationData = {
198198
],
199199
},
200200
risefall: {
201-
title : 'Entry spot' ,
201+
title : localize('Entry spot') ,
202202
content: [
203203
localize('The <strong>start time</strong> is when the contract is processed by our servers and the <strong>entry spot</strong> is the <strong>next tick</strong> thereafter.'),
204204
localize('If you select a <strong>start time</strong> in the future, the <strong>start time</strong> is that which is selected and the <strong>entry spot</strong> is the price in effect at that time.'),

0 commit comments

Comments
 (0)