mirror of
https://github.com/SchildiChat/element-web.git
synced 2024-10-01 01:26:12 -04:00
fix colour & hyperlink for home page header
This commit is contained in:
parent
0cbd5de1d3
commit
cabbd16dd3
@ -9,6 +9,7 @@
|
||||
margin-bottom: 0px;
|
||||
margin-top: 20px;
|
||||
margin-right: 20px;
|
||||
color: #454545;
|
||||
}
|
||||
|
||||
.mx_HomePage_header h2 {
|
||||
@ -16,6 +17,11 @@
|
||||
margin-top: 5px;
|
||||
margin-bottom: 20px;
|
||||
margin-right: 20px;
|
||||
color: #454545;
|
||||
}
|
||||
|
||||
.mx_HomePage_header h1 a {
|
||||
color: #454545;
|
||||
}
|
||||
|
||||
.mx_HomePage h3 {
|
||||
@ -26,7 +32,6 @@
|
||||
border: 1px solid #76CFA6;
|
||||
background-color: #eaf5f0;
|
||||
border-radius: 5px;
|
||||
color: #454545;
|
||||
align-items: center;
|
||||
}
|
||||
|
||||
|
@ -45,6 +45,13 @@ module.exports = React.createClass({
|
||||
};
|
||||
},
|
||||
|
||||
translate: function(s) {
|
||||
s = sanitizeHtml(_t(s));
|
||||
// ugly fix for https://github.com/vector-im/riot-web/issues/4243
|
||||
s = s.replace(/Riot\.im/, '<a href="https://riot.im">Riot.im</a>');
|
||||
return s;
|
||||
},
|
||||
|
||||
componentWillMount: function() {
|
||||
if (this.props.teamToken && this.props.teamServerUrl) {
|
||||
this.setState({
|
||||
@ -66,7 +73,7 @@ module.exports = React.createClass({
|
||||
this.setState({ page: "Couldn't load home page" });
|
||||
}
|
||||
|
||||
body = body.replace(/_t\(['"]([\s\S]*?)['"]\)/mg, (match, g1)=>{ return sanitizeHtml(_t(g1)) });
|
||||
body = body.replace(/_t\(['"]([\s\S]*?)['"]\)/mg, (match, g1)=>this.translate(g1));
|
||||
this.setState({ page: body });
|
||||
}
|
||||
);
|
||||
|
Loading…
Reference in New Issue
Block a user