diff --git a/src/components/structures/CompatibilityPage.js b/src/components/structures/CompatibilityPage.js index 88b01cb2bb..ac5a24768a 100644 --- a/src/components/structures/CompatibilityPage.js +++ b/src/components/structures/CompatibilityPage.js @@ -17,7 +17,7 @@ limitations under the License. 'use strict'; var React = require('react'); -import { _t, _tJsx } from 'matrix-react-sdk/lib/languageHandler'; +import { _t } from 'matrix-react-sdk/lib/languageHandler'; module.exports = React.createClass({ displayName: 'CompatibilityPage', @@ -40,30 +40,24 @@ module.exports = React.createClass({ return (
-

{ _tJsx("Sorry, your browser is not able to run Riot.", /(.*?)<\/b>/, (sub) => {sub}) }

+

{ _t("Sorry, your browser is not able to run Riot.", {}, { 'b': (sub) => {sub} }) }

{ _t("Riot uses many advanced browser features, some of which are not available or experimental in your current browser.") }

- { _tJsx('Please install Chrome or Firefox for the best experience.', - [ - /(.*?)<\/a>/, - /(.*?)<\/a>/, - ], - [ - (sub) => {sub}, - (sub) => {sub}, - ] + { _t('Please install Chrome or Firefox for the best experience.', + {}, + { + 'chromeLink': (sub) => {sub}, + 'firefoxLink': (sub) => {sub}, + }, )} - { _tJsx('Safari and Opera work too.', - [ - /(.*?)<\/a>/, - /(.*?)<\/a>/, - ], - [ - (sub) => {sub}, - (sub) => {sub}, - ] + { _t('< safariLink>Safari and Opera work too.', + {}, + { + 'safariLink': (sub) => {sub}, + 'operaLink': (sub) => {sub}, + }, )}

diff --git a/src/components/views/globals/PasswordNagBar.js b/src/components/views/globals/PasswordNagBar.js index bf71fa2c2f..a04d48e0c5 100644 --- a/src/components/views/globals/PasswordNagBar.js +++ b/src/components/views/globals/PasswordNagBar.js @@ -20,7 +20,7 @@ import React from 'react'; import sdk from 'matrix-react-sdk'; import Modal from 'matrix-react-sdk/lib/Modal'; import dis from 'matrix-react-sdk/lib/dispatcher'; -import { _t, _tJsx } from 'matrix-react-sdk/lib/languageHandler'; +import { _t } from 'matrix-react-sdk/lib/languageHandler'; export default React.createClass({ onUpdateClicked: function() { @@ -49,10 +49,10 @@ export default React.createClass({ alt="Warning" />

- { _tJsx( + { _t( "To return to your account in future you need to set a password", - /(.*?)<\/u>/, - (sub) => { return { sub }; }, + {}, + { 'u': (sub) => { sub } }, ) }