Merge remote-tracking branch 'origin/develop' into develop

This commit is contained in:
RiotTranslate 2017-06-08 13:48:45 +00:00
commit db4be25c41
13 changed files with 321 additions and 117 deletions

View file

@ -1,10 +1,128 @@
<link href="home/css/welcome.css" rel="stylesheet"> <style type="text/css">
<div style="display: none" class="mx_HomePage_container">
/* we deliberately inline style here to avoid flash-of-CSS problems, and to avoid
* voodoo where we have to set display: none by default
*/
.mx_HomePage_header h1 {
margin-left: 0px;
margin-bottom: 0px;
margin-top: 20px;
margin-right: 20px;
color: #454545;
}
.mx_HomePage_header h2 {
margin-left: 0px;
margin-top: 5px;
margin-bottom: 20px;
margin-right: 20px;
color: #454545;
}
.mx_HomePage_header h1 a {
color: #454545;
}
.mx_HomePage h3 {
margin-top: 30px;
}
.mx_HomePage_header {
border: 1px solid #76CFA6;
background-color: #eaf5f0;
border-radius: 5px;
align-items: center;
}
.mx_HomePage_col {
display: flex;
flex-direction: row;
}
.mx_HomePage_toprow {
flex-wrap: wrap;
}
.mx_HomePage_row {
flex: 1 1 0;
margin-right: 20px;
display: flex;
flex-direction: row;
flex-wrap: wrap;
}
.mx_HomePage_logo {
margin-top: 20px;
margin-left: 40px;
margin-right: 40px;
margin-bottom: 20px;
display: inline;
height: 100px;
}
.mx_HomePage_room {
cursor: pointer;
float: left;
text-decoration: none;
text-align: center;
padding-left: 10px;
padding-right: 10px;
width: 120px;
}
.mx_HomePage_toprow .mx_HomePage_room {
width: 64px;
}
.mx_HomePage_room .mx_HomePage_icon {
border-radius: 50%;
width: 64px;
height: 64px;
}
.mx_HomePage_room .mx_HomePage_name {
display: block;
}
.mx_HomePage_room .mx_HomePage_desc {
display: block;
font-size: 12px;
margin-top: 8px;
}
.mx_HomePage_comment {
display: flex;
align-items: center;
margin-left: 100px;
min-height: 64px;
}
.mx_HomePage_container h3::after,
.mx_HomePage_container h4::after {
content: ":";
}
.mx_HomePage_container {
display: block ! important;
margin: 20px;
}
.mx_HomePage_container h1,
.mx_HomePage_container h2,
.mx_HomePage_container h3,
.mx_HomePage_container h4 {
font-weight: 600;
}
</style>
<div class="mx_HomePage_container">
<div class="mx_HomePage_col mx_HomePage_header"> <div class="mx_HomePage_col mx_HomePage_header">
<a href="https://riot.im"><img src="home/images/logo.svg" class="mx_HomePage_logo"></a> <a href="https://riot.im"><img src="home/images/logo.svg" class="mx_HomePage_logo"></a>
<div> <div>
<h1>_t("Welcome to Riot.im")</h1> <h1>_t("Welcome to Riot.im")</h1>
<h2>_t("Decentralised, encrypted chat &amp; collaboration powered by") <a href="https://matrix.org"><img width="79" height="34" alt="[matrix]" style="padding-left: 1px;vertical-align: middle" src="home/images/matrix.svg"/></a></h2> <h2>_t("Decentralised, encrypted chat &amp; collaboration powered by [matrix]")</h2>
</div> </div>
</div> </div>
<div class="mx_HomePage_col mx_HomePage_toprow"> <div class="mx_HomePage_col mx_HomePage_toprow">

View file

@ -1,106 +0,0 @@
.mx_HomePage_header h1 {
margin-left: 0px;
margin-bottom: 0px;
margin-top: 20px;
margin-right: 20px;
}
.mx_HomePage_header h2 {
margin-left: 0px;
margin-top: 5px;
margin-bottom: 20px;
margin-right: 20px;
}
.mx_HomePage h3 {
margin-top: 30px;
}
.mx_HomePage_header {
border: 1px solid #76CFA6;
background-color: #eaf5f0;
border-radius: 5px;
color: #454545;
align-items: center;
}
.mx_HomePage_col {
display: flex;
flex-direction: row;
}
.mx_HomePage_toprow {
flex-wrap: wrap;
}
.mx_HomePage_row {
flex: 1 1 0;
margin-right: 20px;
display: flex;
flex-direction: row;
flex-wrap: wrap;
}
.mx_HomePage_logo {
margin-top: 20px;
margin-left: 40px;
margin-right: 40px;
margin-bottom: 20px;
display: inline;
height: 100px;
}
.mx_HomePage_room {
cursor: pointer;
float: left;
text-decoration: none;
text-align: center;
padding-left: 10px;
padding-right: 10px;
width: 120px;
}
.mx_HomePage_toprow .mx_HomePage_room {
width: 64px;
}
.mx_HomePage_room .mx_HomePage_icon {
border-radius: 50%;
width: 64px;
height: 64px;
}
.mx_HomePage_room .mx_HomePage_name {
display: block;
}
.mx_HomePage_room .mx_HomePage_desc {
display: block;
font-size: 12px;
margin-top: 8px;
}
.mx_HomePage_comment {
display: flex;
align-items: center;
margin-left: 100px;
min-height: 64px;
}
.mx_HomePage_container h3::after,
.mx_HomePage_container h4::after {
content: ":";
}
.mx_HomePage_container {
display: block ! important;
margin: 20px;
}
.mx_HomePage_container h1,
.mx_HomePage_container h2,
.mx_HomePage_container h3,
.mx_HomePage_container h4 {
font-weight: 600;
}

View file

@ -45,6 +45,14 @@ 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 target="_blank">Riot.im</a>');
s = s.replace(/\[matrix\]/, '<a href="https://matrix.org" target="_blank"><img width="79" height="34" alt="[matrix]" style="padding-left: 1px;vertical-align: middle" src="home/images/matrix.svg"/></a>');
return s;
},
componentWillMount: function() { componentWillMount: function() {
if (this.props.teamToken && this.props.teamServerUrl) { if (this.props.teamToken && this.props.teamServerUrl) {
this.setState({ this.setState({
@ -66,7 +74,7 @@ module.exports = React.createClass({
this.setState({ page: "Couldn't load home page" }); 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 }); this.setState({ page: body });
} }
); );

View file

@ -171,7 +171,7 @@
"OK": "OK", "OK": "OK",
"Login": "Anmeldung", "Login": "Anmeldung",
"Welcome to Riot.im": "Willkommen bei Riot.im", "Welcome to Riot.im": "Willkommen bei Riot.im",
"Decentralised, encrypted chat &amp; collaboration powered by": "Dezentralisierter, verschlüsselter Chat &amp; Zusammenarbeit unterstützt von", "Decentralised, encrypted chat &amp; collaboration powered by [matrix]": "Dezentralisierter, verschlüsselter Chat &amp; Zusammenarbeit unterstützt von [matrix]",
"Search the room directory": "Durchsuche Raum-Verzeichnis", "Search the room directory": "Durchsuche Raum-Verzeichnis",
"Chat with Riot Bot": "Chatte mit dem Riot-Bot", "Chat with Riot Bot": "Chatte mit dem Riot-Bot",
"Get started with some tips from Riot Bot!": "Beginne mit einigen Tipps vom Riot-Bot!", "Get started with some tips from Riot Bot!": "Beginne mit einigen Tipps vom Riot-Bot!",

View file

@ -163,7 +163,7 @@
"Welcome page": "Welcome page", "Welcome page": "Welcome page",
"With your current browser, the look and feel of the application may be completely incorrect, and some or all features may not function. If you want to try it anyway you can continue, but you are on your own in terms of any issues you may encounter!": "With your current browser, the look and feel of the application may be completely incorrect, and some or all features may not function. If you want to try it anyway you can continue, but you are on your own in terms of any issues you may encounter!", "With your current browser, the look and feel of the application may be completely incorrect, and some or all features may not function. If you want to try it anyway you can continue, but you are on your own in terms of any issues you may encounter!": "With your current browser, the look and feel of the application may be completely incorrect, and some or all features may not function. If you want to try it anyway you can continue, but you are on your own in terms of any issues you may encounter!",
"Welcome to Riot.im": "Welcome to Riot.im", "Welcome to Riot.im": "Welcome to Riot.im",
"Decentralised, encrypted chat &amp; collaboration powered by": "Decentralised, encrypted chat &amp; collaboration powered by", "Decentralised, encrypted chat &amp; collaboration powered by [matrix]": "Decentralised, encrypted chat &amp; collaboration powered by [matrix]",
"Search the room directory": "Search the room directory", "Search the room directory": "Search the room directory",
"Chat with Riot Bot": "Chat with Riot Bot", "Chat with Riot Bot": "Chat with Riot Bot",
"Get started with some tips from Riot Bot!": "Get started with some tips from Riot Bot!", "Get started with some tips from Riot Bot!": "Get started with some tips from Riot Bot!",

View file

@ -170,7 +170,7 @@
"With your current browser, the look and feel of the application may be completely incorrect, and some or all features may not function. If you want to try it anyway you can continue, but you are on your own in terms of any issues you may encounter!": "Еали ваш браузер не корректно отображает информацию и все или некоторые фукции отключены, вы можете и дальше этим браузеом пользоваться но но ваши проблемы останутся с вами!", "With your current browser, the look and feel of the application may be completely incorrect, and some or all features may not function. If you want to try it anyway you can continue, but you are on your own in terms of any issues you may encounter!": "Еали ваш браузер не корректно отображает информацию и все или некоторые фукции отключены, вы можете и дальше этим браузеом пользоваться но но ваши проблемы останутся с вами!",
"Login": "Войти", "Login": "Войти",
"Welcome to Riot.im": "Добро пожаловать на Riot.im", "Welcome to Riot.im": "Добро пожаловать на Riot.im",
"Decentralised, encrypted chat &amp; collaboration powered by": "Децентрализованное, шифрованное общение и сотрудничество на основе", "Decentralised, encrypted chat &amp; collaboration powered by [matrix]": "Децентрализованное, шифрованное общение и сотрудничество на основе [matrix]",
"Search the room directory": "Поиск по директории комнат", "Search the room directory": "Поиск по директории комнат",
"Chat with Riot Bot": "Пообщаться с Riot Bot" "Chat with Riot Bot": "Пообщаться с Riot Bot"
} }

View file

@ -195,5 +195,5 @@
"This will allow you to return to your account after signing out, and sign in on other devices.": "เพื่อคุณจะได้กลับมายังบัญชีเดิมของคุณได้ หลังจากออกจากระบบ แล้วกลับเข้าสู่ระบบในอุปกรณ์อื่น ๆ", "This will allow you to return to your account after signing out, and sign in on other devices.": "เพื่อคุณจะได้กลับมายังบัญชีเดิมของคุณได้ หลังจากออกจากระบบ แล้วกลับเข้าสู่ระบบในอุปกรณ์อื่น ๆ",
"Design and implementation of E2E in Matrix": "การออกแบบและใช้งาน E2E ใน Matrix", "Design and implementation of E2E in Matrix": "การออกแบบและใช้งาน E2E ใน Matrix",
"Discussion of the Identity Service API": "พูดคุยเกี่ยวกับ Identity Service API", "Discussion of the Identity Service API": "พูดคุยเกี่ยวกับ Identity Service API",
"Decentralised, encrypted chat &amp; collaboration powered by": "แชทและประสานงานบนระบบที่ทั้งเข้ารหัสได้และกระจายศูนย์กลาง โดยใช้เทคโนโลยีจาก" "Decentralised, encrypted chat &amp; collaboration powered by [matrix]": "แชทและประสานงานบนระบบที่ทั้งเข้ารหัสได้และกระจายศูนย์กลาง โดยใช้เทคโนโลยีจาก [matrix]"
} }

View file

@ -332,6 +332,24 @@ limitations under the License.
.mx_EventTile_content .markdown-body code { .mx_EventTile_content .markdown-body code {
background-color: #f8f8f8; background-color: #f8f8f8;
} }
.mx_EventTile_copyButton {
position: absolute;
display: inline-block;
visibility: hidden;
cursor: pointer;
top: 6px;
right: 6px;
width: 19px;
height: 19px;
background-image: url($copy-button-url);
}
.mx_EventTile_body pre {
position: relative;
}
.mx_EventTile_body pre:hover .mx_EventTile_copyButton
{
visibility: visible;
}
.mx_EventTile_content .markdown-body h1, .mx_EventTile_content .markdown-body h1,
.mx_EventTile_content .markdown-body h2, .mx_EventTile_content .markdown-body h2,

View file

@ -102,6 +102,7 @@ $event-redacted-img: url('../../img/redacted.jpg');
$event-timestamp-color: #acacac; $event-timestamp-color: #acacac;
$edit-button-url: "../../img/icon_context_message.svg"; $edit-button-url: "../../img/icon_context_message.svg";
$copy-button-url: "../../img/icon_copy_message.svg";
// e2e // e2e
$e2e-verified-color: #76cfa5; // N.B. *NOT* the same as $accent-color $e2e-verified-color: #76cfa5; // N.B. *NOT* the same as $accent-color
@ -114,4 +115,4 @@ $lightbox-fg-color: #ffffff;
$lightbox-border-color: #ffffff; $lightbox-border-color: #ffffff;
// unused? // unused?
$progressbar-color: #000; $progressbar-color: #000;

View file

@ -102,6 +102,7 @@ $event-redacted-img: url('../../img/redacted-dark.jpg');
$event-timestamp-color: #acacac; $event-timestamp-color: #acacac;
$edit-button-url: "../../img/icon_context_message_dark.svg"; $edit-button-url: "../../img/icon_context_message_dark.svg";
$copy-button-url: "../../img/icon_copy_message_dark.svg";
// e2e // e2e
$e2e-verified-color: #76cfa5; // N.B. *NOT* the same as $accent-color $e2e-verified-color: #76cfa5; // N.B. *NOT* the same as $accent-color

View file

@ -19,13 +19,14 @@ limitations under the License.
max-width: 960px; max-width: 960px;
width: 100%; width: 100%;
height: 100%; height: 100%;
overflow-y: hidden;
margin-left: auto; margin-left: auto;
margin-right: auto; margin-right: auto;
} }
.mx_HomePage iframe { .mx_HomePage iframe {
display: block;
width: 100%; width: 100%;
height: 90%; height: 100%;
border: 0px; border: 0px;
} }

View file

@ -0,0 +1,86 @@
<?xml version="1.0" encoding="UTF-8" standalone="no"?>
<svg
xmlns:dc="http://purl.org/dc/elements/1.1/"
xmlns:cc="http://creativecommons.org/ns#"
xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#"
xmlns:svg="http://www.w3.org/2000/svg"
xmlns="http://www.w3.org/2000/svg"
xmlns:sodipodi="http://sodipodi.sourceforge.net/DTD/sodipodi-0.dtd"
xmlns:inkscape="http://www.inkscape.org/namespaces/inkscape"
width="19px"
height="19px"
viewBox="0 0 19 19"
version="1.1"
id="svg3734"
sodipodi:docname="icon_copy_message.svg"
inkscape:version="0.92.1 r">
<metadata
id="metadata3738">
<rdf:RDF>
<cc:Work
rdf:about="">
<dc:format>image/svg+xml</dc:format>
<dc:type
rdf:resource="http://purl.org/dc/dcmitype/StillImage" />
<dc:title>ED5D3E59-2561-4AC1-9B43-82FBC51767FC</dc:title>
</cc:Work>
</rdf:RDF>
</metadata>
<sodipodi:namedview
pagecolor="#ffffff"
bordercolor="#666666"
borderopacity="1"
objecttolerance="10"
gridtolerance="10"
guidetolerance="10"
inkscape:pageopacity="0"
inkscape:pageshadow="2"
inkscape:window-width="1596"
inkscape:window-height="846"
id="namedview3736"
showgrid="false"
inkscape:zoom="12.421053"
inkscape:cx="3.4935767"
inkscape:cy="2.469644"
inkscape:window-x="0"
inkscape:window-y="0"
inkscape:window-maximized="1"
inkscape:current-layer="Symbols" />
<!-- Generator: sketchtool 39.1 (31720) - http://www.bohemiancoding.com/sketch -->
<title
id="title3722">ED5D3E59-2561-4AC1-9B43-82FBC51767FC</title>
<desc
id="desc3724">Created with sketchtool.</desc>
<defs
id="defs3726" />
<g
id="Symbols"
stroke="none"
stroke-width="1"
fill="none"
fill-rule="evenodd">
<path
d="M 9.5,19 C 14.746705,19 19,14.746705 19,9.5 19,4.2532949 14.746705,0 9.5,0 4.2532949,0 0,4.2532949 0,9.5 0,14.746705 4.2532949,19 9.5,19 Z"
id="Oval-69"
inkscape:connector-curvature="0"
style="fill:#ececec" />
<g
id="g4632"
transform="translate(-2.3841858e-7,-1)">
<rect
style="stroke:#9b9b9b;stroke-width:0.91585475;stroke-miterlimit:4;stroke-dasharray:none;stroke-opacity:1"
y="4.3017478"
x="4.6289611"
height="10.396504"
width="7.7420783"
id="rect3745-3" />
<rect
style="fill:#ececec;fill-opacity:1;stroke:#9b9b9b;stroke-width:0.91585475;stroke-miterlimit:4;stroke-dasharray:none;stroke-opacity:1"
y="6.3017478"
x="6.6289611"
height="10.396504"
width="7.7420783"
id="rect3745" />
</g>
</g>
</svg>

After

Width:  |  Height:  |  Size: 2.7 KiB

View file

@ -0,0 +1,77 @@
<?xml version="1.0" encoding="UTF-8" standalone="no"?>
<svg
xmlns:dc="http://purl.org/dc/elements/1.1/"
xmlns:cc="http://creativecommons.org/ns#"
xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#"
xmlns:svg="http://www.w3.org/2000/svg"
xmlns="http://www.w3.org/2000/svg"
xmlns:sodipodi="http://sodipodi.sourceforge.net/DTD/sodipodi-0.dtd"
xmlns:inkscape="http://www.inkscape.org/namespaces/inkscape"
width="19px"
height="19px"
viewBox="0 0 19 19"
version="1.1"
id="svg3734"
sodipodi:docname="icon_copy_message_dark.svg"
inkscape:version="0.92.1 r"
enable-background="new">
<metadata
id="metadata3738">
<rdf:RDF>
<cc:Work
rdf:about="">
<dc:format>image/svg+xml</dc:format>
<dc:type
rdf:resource="http://purl.org/dc/dcmitype/StillImage" />
<dc:title>ED5D3E59-2561-4AC1-9B43-82FBC51767FC</dc:title>
</cc:Work>
</rdf:RDF>
</metadata>
<sodipodi:namedview
pagecolor="#ffffff"
bordercolor="#666666"
borderopacity="1"
objecttolerance="10"
gridtolerance="10"
guidetolerance="10"
inkscape:pageopacity="0"
inkscape:pageshadow="2"
inkscape:window-width="1596"
inkscape:window-height="846"
id="namedview3736"
showgrid="false"
inkscape:zoom="12.421053"
inkscape:cx="3.4935767"
inkscape:cy="2.469644"
inkscape:window-x="0"
inkscape:window-y="0"
inkscape:window-maximized="1"
inkscape:current-layer="svg3734" />
<!-- Generator: sketchtool 39.1 (31720) - http://www.bohemiancoding.com/sketch -->
<title
id="title3722">ED5D3E59-2561-4AC1-9B43-82FBC51767FC</title>
<desc
id="desc3724">Created with sketchtool.</desc>
<defs
id="defs3726" />
<path
style="opacity:0.2;fill:#000000;fill-opacity:1;fill-rule:evenodd;stroke:none;stroke-width:1"
inkscape:connector-curvature="0"
id="Oval-69"
d="M 9.5,19 C 14.746705,19 19,14.746705 19,9.5 19,4.2532949 14.746705,0 9.5,0 4.2532949,0 0,4.2532949 0,9.5 0,14.746705 4.2532949,19 9.5,19 Z" />
<g
id="g4675"
style="stroke:#ffffff;stroke-opacity:1;opacity:0.6">
<path
id="rect3745-3"
d="M 4.6289062 3.3007812 L 4.6289062 13.699219 L 6.6289062 13.699219 L 6.6289062 5.3007812 L 12.371094 5.3007812 L 12.371094 3.3007812 L 4.6289062 3.3007812 z "
style="fill:none;fill-rule:evenodd;stroke:#ffffff;stroke-width:0.91585475;stroke-miterlimit:4;stroke-dasharray:none;stroke-opacity:1" />
<rect
id="rect3745-7"
width="7.7420783"
height="10.396504"
x="6.6289062"
y="5.3007812"
style="fill:none;fill-opacity:1;fill-rule:evenodd;stroke:#ffffff;stroke-width:0.91585475;stroke-miterlimit:4;stroke-dasharray:none;stroke-opacity:1" />
</g>
</svg>

After

Width:  |  Height:  |  Size: 2.7 KiB