discard create-react-class, no point using it here. use React.FC
Signed-off-by: Michael Telatynski <7t3chguy@gmail.com>
This commit is contained in:
parent
06e7a48aaf
commit
da9f1d1fa3
3 changed files with 57 additions and 68 deletions
|
@ -16,44 +16,39 @@ limitations under the License.
|
|||
*/
|
||||
|
||||
import React from "react";
|
||||
import createReactClass from 'create-react-class';
|
||||
import { _t } from 'matrix-react-sdk/lib/languageHandler';
|
||||
|
||||
/**
|
||||
* This is identical to `CustomServerDialog` except for replacing "this app"
|
||||
* with "Riot".
|
||||
*/
|
||||
module.exports = createReactClass({
|
||||
displayName: 'VectorCustomServerDialog',
|
||||
statics: {
|
||||
replaces: 'CustomServerDialog',
|
||||
},
|
||||
|
||||
render: function() {
|
||||
return (
|
||||
<div className="mx_ErrorDialog">
|
||||
<div className="mx_Dialog_title">
|
||||
{ _t('Custom Server Options') }
|
||||
</div>
|
||||
<div className="mx_Dialog_content">
|
||||
<p>{_t(
|
||||
"You can use the custom server options to sign into other " +
|
||||
"Matrix servers by specifying a different homeserver URL. This " +
|
||||
"allows you to use Riot with an existing Matrix account on a " +
|
||||
"different homeserver.",
|
||||
)}</p>
|
||||
<p>{_t(
|
||||
"You can also set a custom identity server, but you won't be " +
|
||||
"able to invite users by email address, or be invited by email " +
|
||||
"address yourself.",
|
||||
)}</p>
|
||||
</div>
|
||||
<div className="mx_Dialog_buttons">
|
||||
<button onClick={this.props.onFinished} autoFocus={true}>
|
||||
{ _t('Dismiss') }
|
||||
</button>
|
||||
</div>
|
||||
module.exports = () => {
|
||||
return (
|
||||
<div className="mx_ErrorDialog">
|
||||
<div className="mx_Dialog_title">
|
||||
{ _t('Custom Server Options') }
|
||||
</div>
|
||||
);
|
||||
},
|
||||
});
|
||||
<div className="mx_Dialog_content">
|
||||
<p>{_t(
|
||||
"You can use the custom server options to sign into other " +
|
||||
"Matrix servers by specifying a different homeserver URL. This " +
|
||||
"allows you to use Riot with an existing Matrix account on a " +
|
||||
"different homeserver.",
|
||||
)}</p>
|
||||
<p>{_t(
|
||||
"You can also set a custom identity server, but you won't be " +
|
||||
"able to invite users by email address, or be invited by email " +
|
||||
"address yourself.",
|
||||
)}</p>
|
||||
</div>
|
||||
<div className="mx_Dialog_buttons">
|
||||
<button onClick={this.props.onFinished} autoFocus={true}>
|
||||
{ _t('Dismiss') }
|
||||
</button>
|
||||
</div>
|
||||
</div>
|
||||
);
|
||||
};
|
||||
module.exports.statics = {
|
||||
replaces: 'CustomServerDialog',
|
||||
};
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue