Skip to content

Commit 48b3075

Browse files
committed
Merge branch 'develop' of https://github.com/vector-im/riot-web into rxl881/appFixes
2 parents 3dc347f + 5db0137 commit 48b3075

47 files changed

Lines changed: 2304 additions & 341 deletions

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

‎CHANGELOG.md‎

Lines changed: 148 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,151 @@
1+
Changes in [0.12.0-rc.1](https://github.com/vector-im/riot-web/releases/tag/v0.12.0-rc.1) (2017-08-16)
2+
======================================================================================================
3+
[Full Changelog](https://github.com/vector-im/riot-web/compare/v0.11.4...v0.12.0-rc.1)
4+
5+
* Update from Weblate.
6+
[\#4797](https://github.com/vector-im/riot-web/pull/4797)
7+
* move focus-via-up/down cursors to LeftPanel
8+
[\#4777](https://github.com/vector-im/riot-web/pull/4777)
9+
* Remove userId property on RightPanel
10+
[\#4775](https://github.com/vector-im/riot-web/pull/4775)
11+
* Make member device info buttons fluid and stackable with flexbox
12+
[\#4776](https://github.com/vector-im/riot-web/pull/4776)
13+
* un-i18n Modal Analytics
14+
[\#4688](https://github.com/vector-im/riot-web/pull/4688)
15+
* Quote using innerText
16+
[\#4773](https://github.com/vector-im/riot-web/pull/4773)
17+
* Karma tweaks for riot-web
18+
[\#4765](https://github.com/vector-im/riot-web/pull/4765)
19+
* Fix typo with scripts/fetch-develop-deps.sh in Building From Source
20+
[\#4764](https://github.com/vector-im/riot-web/pull/4764)
21+
* Adjust CSS for optional avatars in pills
22+
[\#4757](https://github.com/vector-im/riot-web/pull/4757)
23+
* Fix crypto on develop
24+
[\#4754](https://github.com/vector-im/riot-web/pull/4754)
25+
* Fix signing key url in readme
26+
[\#4464](https://github.com/vector-im/riot-web/pull/4464)
27+
* update gitignore to allow .idea directory to exist in subdirs
28+
[\#4749](https://github.com/vector-im/riot-web/pull/4749)
29+
* tweak compact theme
30+
[\#4665](https://github.com/vector-im/riot-web/pull/4665)
31+
* Update draft-js from 0.10.1 to 0.11.0-alpha
32+
[\#4740](https://github.com/vector-im/riot-web/pull/4740)
33+
* electron support for mouse forward/back buttons in Windows
34+
[\#4739](https://github.com/vector-im/riot-web/pull/4739)
35+
* Update draft-js from 0.8.1 to 0.10.1
36+
[\#4730](https://github.com/vector-im/riot-web/pull/4730)
37+
* Make pills, emoji translucent when sending
38+
[\#4693](https://github.com/vector-im/riot-web/pull/4693)
39+
* Widget permissions styling and icon
40+
[\#4690](https://github.com/vector-im/riot-web/pull/4690)
41+
* CSS required for composer autoscroll
42+
[\#4682](https://github.com/vector-im/riot-web/pull/4682)
43+
* CSS for group edit UI
44+
[\#4608](https://github.com/vector-im/riot-web/pull/4608)
45+
* Fix a couple of minor errors in the room list
46+
[\#4671](https://github.com/vector-im/riot-web/pull/4671)
47+
* Styling for beta testing icon.
48+
[\#4584](https://github.com/vector-im/riot-web/pull/4584)
49+
* Increase the timeout for clearing indexeddbs
50+
[\#4650](https://github.com/vector-im/riot-web/pull/4650)
51+
* Make some adjustments to mx_UserPill and mx_RoomPill
52+
[\#4597](https://github.com/vector-im/riot-web/pull/4597)
53+
* Apply CSS to <pre> tags to distinguish them from each other
54+
[\#4639](https://github.com/vector-im/riot-web/pull/4639)
55+
* Use `catch` instead of `fail` to handle room tag error
56+
[\#4643](https://github.com/vector-im/riot-web/pull/4643)
57+
* CSS for decorated matrix.to links in the composer
58+
[\#4583](https://github.com/vector-im/riot-web/pull/4583)
59+
* Deflake the joining test
60+
[\#4579](https://github.com/vector-im/riot-web/pull/4579)
61+
* Bump react to 15.6 to fix build problems
62+
[\#4577](https://github.com/vector-im/riot-web/pull/4577)
63+
* Improve AppTile menu bar button styling.
64+
[\#4567](https://github.com/vector-im/riot-web/pull/4567)
65+
* Transform `async` functions to bluebird promises
66+
[\#4572](https://github.com/vector-im/riot-web/pull/4572)
67+
* use flushAllExpected in joining test
68+
[\#4570](https://github.com/vector-im/riot-web/pull/4570)
69+
* Switch riot-web to bluebird
70+
[\#4565](https://github.com/vector-im/riot-web/pull/4565)
71+
* loading tests: wait for login component
72+
[\#4564](https://github.com/vector-im/riot-web/pull/4564)
73+
* Remove CSS for the MessageComposerInputOld
74+
[\#4568](https://github.com/vector-im/riot-web/pull/4568)
75+
* Implement the focus_room_filter action
76+
[\#4560](https://github.com/vector-im/riot-web/pull/4560)
77+
* CSS for Rooms in Group View
78+
[\#4530](https://github.com/vector-im/riot-web/pull/4530)
79+
* more HomePage tweaks
80+
[\#4557](https://github.com/vector-im/riot-web/pull/4557)
81+
* Give HomePage an unmounted guard
82+
[\#4556](https://github.com/vector-im/riot-web/pull/4556)
83+
* Take RTE out of labs
84+
[\#4500](https://github.com/vector-im/riot-web/pull/4500)
85+
* CSS for Groups page
86+
[\#4468](https://github.com/vector-im/riot-web/pull/4468)
87+
* CSS for GroupView
88+
[\#4442](https://github.com/vector-im/riot-web/pull/4442)
89+
* remove unused class
90+
[\#4525](https://github.com/vector-im/riot-web/pull/4525)
91+
* Fix long words causing MessageComposer to widen
92+
[\#4466](https://github.com/vector-im/riot-web/pull/4466)
93+
* Add visual bell animation for RTE
94+
[\#4516](https://github.com/vector-im/riot-web/pull/4516)
95+
* Truncate auto-complete pills properly
96+
[\#4502](https://github.com/vector-im/riot-web/pull/4502)
97+
* Use chrome headless instead of phantomjs
98+
[\#4512](https://github.com/vector-im/riot-web/pull/4512)
99+
* Use external mock-request
100+
[\#4489](https://github.com/vector-im/riot-web/pull/4489)
101+
* fix Quote not closing contextual menu
102+
[\#4443](https://github.com/vector-im/riot-web/pull/4443)
103+
* Apply white-space: pre-wrap to mx_MEmoteBody
104+
[\#4470](https://github.com/vector-im/riot-web/pull/4470)
105+
* Add some style improvements to autocompletions
106+
[\#4456](https://github.com/vector-im/riot-web/pull/4456)
107+
* Styling for apps / widgets
108+
[\#4447](https://github.com/vector-im/riot-web/pull/4447)
109+
* Attempt to flush the rageshake logs on close
110+
[\#4400](https://github.com/vector-im/riot-web/pull/4400)
111+
* Update from Weblate.
112+
[\#4401](https://github.com/vector-im/riot-web/pull/4401)
113+
* improve update polling electron and provide a manual check for updates
114+
button
115+
[\#4176](https://github.com/vector-im/riot-web/pull/4176)
116+
* Fix load failure in firefox when indexedDB is disabled
117+
[\#4395](https://github.com/vector-im/riot-web/pull/4395)
118+
* Change missed 'Redact' to 'Remove' in ImageView.
119+
[\#4362](https://github.com/vector-im/riot-web/pull/4362)
120+
* explicit convert to nativeImage to stabilise trayIcon on Windows [Electron]
121+
[\#4355](https://github.com/vector-im/riot-web/pull/4355)
122+
* Use _tJsx for PasswordNagBar (because it has <u>)
123+
[\#4373](https://github.com/vector-im/riot-web/pull/4373)
124+
* Clean up some log outputs from the integ tests
125+
[\#4376](https://github.com/vector-im/riot-web/pull/4376)
126+
* CSS for redeisng of password warning
127+
[\#4367](https://github.com/vector-im/riot-web/pull/4367)
128+
* Give _t to PasswordNagBar, add CSS for UserSettings password warning
129+
[\#4366](https://github.com/vector-im/riot-web/pull/4366)
130+
* Update from Weblate.
131+
[\#4361](https://github.com/vector-im/riot-web/pull/4361)
132+
* Update from Weblate.
133+
[\#4360](https://github.com/vector-im/riot-web/pull/4360)
134+
* Test 'return-to-app' functionality
135+
[\#4352](https://github.com/vector-im/riot-web/pull/4352)
136+
* Update from Weblate.
137+
[\#4354](https://github.com/vector-im/riot-web/pull/4354)
138+
* onLoadCompleted is now onTokenLoginCompleted
139+
[\#4335](https://github.com/vector-im/riot-web/pull/4335)
140+
* Tweak tests to match updates to matrixchat
141+
[\#4325](https://github.com/vector-im/riot-web/pull/4325)
142+
* Update from Weblate.
143+
[\#4346](https://github.com/vector-im/riot-web/pull/4346)
144+
* change dispatcher forward_event signature
145+
[\#4337](https://github.com/vector-im/riot-web/pull/4337)
146+
* Add border on hover for code blocks
147+
[\#4259](https://github.com/vector-im/riot-web/pull/4259)
148+
1149
Changes in [0.11.4](https://github.com/vector-im/riot-web/releases/tag/v0.11.4) (2017-06-22)
2150
============================================================================================
3151
[Full Changelog](https://github.com/vector-im/riot-web/compare/v0.11.3...v0.11.4)

‎electron_app/package.json‎

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@
22
"name": "riot-web",
33
"productName": "Riot",
44
"main": "src/electron-main.js",
5-
"version": "0.11.4",
5+
"version": "0.12.0-rc.1",
66
"description": "A feature-rich client for Matrix.org",
77
"author": "Vector Creations Ltd.",
88
"dependencies": {

‎package.json‎

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@
22
"name": "riot-web",
33
"productName": "Riot",
44
"main": "electron_app/src/electron-main.js",
5-
"version": "0.11.4",
5+
"version": "0.12.0-rc.1",
66
"description": "A feature-rich client for Matrix.org",
77
"author": "Vector Creations Ltd.",
88
"repository": {
@@ -66,8 +66,8 @@
6666
"gfm.css": "^1.1.1",
6767
"highlight.js": "^9.0.0",
6868
"linkifyjs": "^2.1.3",
69-
"matrix-js-sdk": "0.7.13",
70-
"matrix-react-sdk": "0.9.7",
69+
"matrix-js-sdk": "0.8.0",
70+
"matrix-react-sdk": "0.10.0-rc.1",
7171
"modernizr": "^3.1.0",
7272
"pako": "^1.0.5",
7373
"react": "^15.6.0",

‎release.sh‎

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -11,7 +11,7 @@ cd `dirname $0`
1111

1212
for i in matrix-js-sdk matrix-react-sdk
1313
do
14-
depver=`cat package.json | jq -r .dependencies.\"$i\"`
14+
depver=`cat package.json | jq -r .dependencies[\"$i\"]`
1515
latestver=`npm show $i version`
1616
if [ "$depver" != "$latestver" ]
1717
then

‎scripts/copy-res.js‎

Lines changed: 7 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -9,24 +9,27 @@
99
// This could readily be automated, but it's nice to explicitly
1010
// control when we languages are available.
1111
const INCLUDE_LANGS = [
12+
{'value': 'da', 'label': 'Dansk'},
13+
{'value': 'de_DE', 'label': 'Deutsch'},
1214
{'value': 'en_EN', 'label': 'English'},
1315
{'value': 'en_US', 'label': 'English (US)'},
14-
{'value': 'da', 'label': 'Dansk'},
1516
{'value': 'el', 'label': 'Ελληνικά'},
1617
{'value': 'eo', 'label': 'Esperanto'},
17-
{'value': 'nl', 'label': 'Nederlands'},
18-
{'value': 'de_DE', 'label': 'Deutsch'},
18+
{'value': 'es', 'label': 'Español'},
19+
{'value': 'eu', 'label': 'Euskal'},
1920
{'value': 'fr', 'label': 'Français'},
2021
{'value': 'hu', 'label': 'Magyar'},
2122
{'value': 'ko', 'label': '한국어'},
23+
{'value': 'lv', 'label': 'Latviešu'},
2224
{'value': 'nb_NO', 'label': 'Norwegian Bokmål'},
25+
{'value': 'nl', 'label': 'Nederlands'},
2326
{'value': 'pl', 'label': 'Polski'},
2427
{'value': 'pt', 'label': 'Português'},
2528
{'value': 'pt_BR', 'label': 'Português do Brasil'},
2629
{'value': 'ru', 'label': 'Русский'},
2730
{'value': 'sv', 'label': 'Svenska'},
28-
{'value': 'es', 'label': 'Español'},
2931
{'value': 'th', 'label': 'ไทย'},
32+
{'value': 'te', 'label': 'తెలుగు'},
3033
{'value': 'tr', 'label': 'Türk'},
3134
{'value': 'zh_Hans', 'label': '简体中文'}, // simplified chinese
3235
{'value': 'zh_Hant', 'label': '繁體中文'}, // traditional chinese

‎src/components/structures/LeftPanel.js‎

Lines changed: 99 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -16,17 +16,16 @@ limitations under the License.
1616

1717
'use strict';
1818

19-
var React = require('react');
20-
var DragDropContext = require('react-dnd').DragDropContext;
21-
var HTML5Backend = require('react-dnd-html5-backend');
22-
var sdk = require('matrix-react-sdk')
23-
var dis = require('matrix-react-sdk/lib/dispatcher');
19+
import React from 'react';
20+
import { DragDropContext } from 'react-dnd';
21+
import HTML5Backend from 'react-dnd-html5-backend';
22+
import KeyCode from 'matrix-react-sdk/lib/KeyCode';
23+
import sdk from 'matrix-react-sdk';
24+
import dis from 'matrix-react-sdk/lib/dispatcher';
2425
import MatrixClientPeg from 'matrix-react-sdk/lib/MatrixClientPeg';
25-
26-
var VectorConferenceHandler = require('../../VectorConferenceHandler');
27-
var CallHandler = require("matrix-react-sdk/lib/CallHandler");
28-
26+
import CallHandler from 'matrix-react-sdk/lib/CallHandler';
2927
import AccessibleButton from 'matrix-react-sdk/lib/components/views/elements/AccessibleButton';
28+
import VectorConferenceHandler from '../../VectorConferenceHandler';
3029

3130
var LeftPanel = React.createClass({
3231
displayName: 'LeftPanel',
@@ -42,6 +41,10 @@ var LeftPanel = React.createClass({
4241
};
4342
},
4443

44+
componentWillMount: function() {
45+
this.focusedElement = null;
46+
},
47+
4548
componentDidMount: function() {
4649
this.dispatcherRef = dis.register(this.onAction);
4750
},
@@ -64,6 +67,91 @@ var LeftPanel = React.createClass({
6467
}
6568
},
6669

70+
_onFocus: function(ev) {
71+
this.focusedElement = ev.target;
72+
},
73+
74+
_onBlur: function(ev) {
75+
this.focusedElement = null;
76+
},
77+
78+
_onKeyDown: function(ev) {
79+
if (!this.focusedElement) return;
80+
let handled = false;
81+
82+
switch (ev.keyCode) {
83+
case KeyCode.UP:
84+
this._onMoveFocus(true);
85+
handled = true;
86+
break;
87+
case KeyCode.DOWN:
88+
this._onMoveFocus(false);
89+
handled = true;
90+
break;
91+
}
92+
93+
if (handled) {
94+
ev.stopPropagation();
95+
ev.preventDefault();
96+
}
97+
},
98+
99+
_onMoveFocus: function(up) {
100+
var element = this.focusedElement;
101+
102+
// unclear why this isn't needed
103+
// var descending = (up == this.focusDirection) ? this.focusDescending : !this.focusDescending;
104+
// this.focusDirection = up;
105+
106+
var descending = false; // are we currently descending or ascending through the DOM tree?
107+
var classes;
108+
109+
do {
110+
var child = up ? element.lastElementChild : element.firstElementChild;
111+
var sibling = up ? element.previousElementSibling : element.nextElementSibling;
112+
113+
if (descending) {
114+
if (child) {
115+
element = child;
116+
}
117+
else if (sibling) {
118+
element = sibling;
119+
}
120+
else {
121+
descending = false;
122+
element = element.parentElement;
123+
}
124+
}
125+
else {
126+
if (sibling) {
127+
element = sibling;
128+
descending = true;
129+
}
130+
else {
131+
element = element.parentElement;
132+
}
133+
}
134+
135+
if (element) {
136+
classes = element.classList;
137+
if (classes.contains("mx_LeftPanel")) { // we hit the top
138+
element = up ? element.lastElementChild : element.firstElementChild;
139+
descending = true;
140+
}
141+
}
142+
143+
} while(element && !(
144+
classes.contains("mx_RoomTile") ||
145+
classes.contains("mx_SearchBox_search") ||
146+
classes.contains("mx_RoomSubList_ellipsis")));
147+
148+
if (element) {
149+
element.focus();
150+
this.focusedElement = element;
151+
this.focusedDescending = descending;
152+
}
153+
},
154+
67155
_recheckCallElement: function(selectedRoomId) {
68156
// if we aren't viewing a room with an ongoing call, but there is an
69157
// active call, show the call element - we need to do this to make
@@ -126,7 +214,8 @@ var LeftPanel = React.createClass({
126214
}
127215

128216
return (
129-
<aside className={classes} style={{ opacity: this.props.opacity }}>
217+
<aside className={classes} style={{ opacity: this.props.opacity }}
218+
onKeyDown={ this._onKeyDown } onFocus={ this._onFocus } onBlur={ this._onBlur }>
130219
{ topBox }
131220
{ callPreview }
132221
<RoomList

‎src/components/structures/RightPanel.js‎

Lines changed: 5 additions & 13 deletions
Original file line numberDiff line numberDiff line change
@@ -31,7 +31,7 @@ module.exports = React.createClass({
3131
displayName: 'RightPanel',
3232

3333
propTypes: {
34-
userId: React.PropTypes.string, // if showing an orphaned MemberInfo page, this is set
34+
// TODO: This should not be a prop, it should be received from the RoomViewStore
3535
roomId: React.PropTypes.string, // if showing panels for a given room, this is set
3636
collapsed: React.PropTypes.bool, // currently unused property to request for a minimized view of the panel
3737
},
@@ -57,17 +57,9 @@ module.exports = React.createClass({
5757
},
5858

5959
getInitialState: function() {
60-
if (this.props.userId) {
61-
var member = new Matrix.RoomMember(null, this.props.userId);
62-
return {
63-
phase: this.Phase.MemberInfo,
64-
member: member,
65-
};
66-
} else {
67-
return {
68-
phase: this.Phase.MemberList
69-
};
70-
}
60+
return {
61+
phase: this.Phase.MemberList
62+
};
7163
},
7264

7365
onMemberListButtonClick: function() {
@@ -229,7 +221,7 @@ module.exports = React.createClass({
229221
}
230222
else if(this.state.phase == this.Phase.MemberInfo) {
231223
var MemberInfo = sdk.getComponent('rooms.MemberInfo');
232-
panel = <MemberInfo member={this.state.member} key={this.props.roomId || this.props.userId} />
224+
panel = <MemberInfo member={this.state.member} key={this.props.roomId || this.state.member.userId} />
233225
}
234226
else if (this.state.phase == this.Phase.NotificationPanel) {
235227
panel = <NotificationPanel />

0 commit comments

Comments
 (0)