Merge pull request #44 from matrix-org/kegan/vector-references
Remove all references to 'Vector'
This commit is contained in:
commit
aceb85130e
11 changed files with 128 additions and 54 deletions
18
reskindex.js
18
reskindex.js
|
@ -45,22 +45,4 @@ for (var i = 0; i < files.length; ++i) {
|
||||||
strm.uncork();
|
strm.uncork();
|
||||||
}
|
}
|
||||||
|
|
||||||
// Temporary Vector transition
|
|
||||||
var vectorViewsPath = path.join('src', 'skins', 'vector', 'views');
|
|
||||||
if (fs.existsSync(vectorViewsPath)) {
|
|
||||||
strm.write('\n');
|
|
||||||
strm.write('// Old, unported Vector views:\n');
|
|
||||||
var files = glob.sync('**/*.js', {cwd: vectorViewsPath});
|
|
||||||
for (var i = 0; i < files.length; ++i) {
|
|
||||||
var file = files[i].replace('.js', '');
|
|
||||||
|
|
||||||
var moduleName = (file.replace(/\//g, '.'));
|
|
||||||
|
|
||||||
strm.write("module.exports.components['"+moduleName+"'] = require('./skins/vector/views/"+file+"');");
|
|
||||||
strm.write('\n');
|
|
||||||
strm.uncork();
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
strm.end();
|
strm.end();
|
||||||
|
|
||||||
|
|
|
@ -42,6 +42,9 @@ module.exports.components['views.elements.ProgressBar'] = require('./components/
|
||||||
module.exports.components['views.elements.UserSelector'] = require('./components/views/elements/UserSelector');
|
module.exports.components['views.elements.UserSelector'] = require('./components/views/elements/UserSelector');
|
||||||
module.exports.components['views.login.CaptchaForm'] = require('./components/views/login/CaptchaForm');
|
module.exports.components['views.login.CaptchaForm'] = require('./components/views/login/CaptchaForm');
|
||||||
module.exports.components['views.login.CasLogin'] = require('./components/views/login/CasLogin');
|
module.exports.components['views.login.CasLogin'] = require('./components/views/login/CasLogin');
|
||||||
|
module.exports.components['views.login.CustomServerDialog'] = require('./components/views/login/CustomServerDialog');
|
||||||
|
module.exports.components['views.login.LoginFooter'] = require('./components/views/login/LoginFooter');
|
||||||
|
module.exports.components['views.login.LoginHeader'] = require('./components/views/login/LoginHeader');
|
||||||
module.exports.components['views.login.PasswordLogin'] = require('./components/views/login/PasswordLogin');
|
module.exports.components['views.login.PasswordLogin'] = require('./components/views/login/PasswordLogin');
|
||||||
module.exports.components['views.login.RegistrationForm'] = require('./components/views/login/RegistrationForm');
|
module.exports.components['views.login.RegistrationForm'] = require('./components/views/login/RegistrationForm');
|
||||||
module.exports.components['views.login.ServerConfig'] = require('./components/views/login/ServerConfig');
|
module.exports.components['views.login.ServerConfig'] = require('./components/views/login/ServerConfig');
|
||||||
|
|
|
@ -44,7 +44,7 @@ var INITIAL_SIZE = 20;
|
||||||
module.exports = React.createClass({
|
module.exports = React.createClass({
|
||||||
displayName: 'RoomView',
|
displayName: 'RoomView',
|
||||||
propTypes: {
|
propTypes: {
|
||||||
ConferenceHandler: React.PropTypes.any // VectorConferenceHandler
|
ConferenceHandler: React.PropTypes.any
|
||||||
},
|
},
|
||||||
|
|
||||||
getInitialState: function() {
|
getInitialState: function() {
|
||||||
|
|
|
@ -151,7 +151,7 @@ module.exports = React.createClass({displayName: 'Login',
|
||||||
return (
|
return (
|
||||||
<div>
|
<div>
|
||||||
Sorry, this homeserver is using a login which is not
|
Sorry, this homeserver is using a login which is not
|
||||||
recognised by Vector ({step})
|
recognised ({step})
|
||||||
</div>
|
</div>
|
||||||
);
|
);
|
||||||
}
|
}
|
||||||
|
@ -159,14 +159,14 @@ module.exports = React.createClass({displayName: 'Login',
|
||||||
|
|
||||||
render: function() {
|
render: function() {
|
||||||
var Loader = sdk.getComponent("elements.Spinner");
|
var Loader = sdk.getComponent("elements.Spinner");
|
||||||
|
var LoginHeader = sdk.getComponent("login.LoginHeader");
|
||||||
|
var LoginFooter = sdk.getComponent("login.LoginFooter");
|
||||||
var loader = this.state.busy ? <div className="mx_Login_loader"><Loader /></div> : null;
|
var loader = this.state.busy ? <div className="mx_Login_loader"><Loader /></div> : null;
|
||||||
|
|
||||||
return (
|
return (
|
||||||
<div className="mx_Login">
|
<div className="mx_Login">
|
||||||
<div className="mx_Login_box">
|
<div className="mx_Login_box">
|
||||||
<div className="mx_Login_logo">
|
<LoginHeader />
|
||||||
<img src="img/logo.png" width="249" height="78" alt="vector"/>
|
|
||||||
</div>
|
|
||||||
<div>
|
<div>
|
||||||
<h2>Sign in</h2>
|
<h2>Sign in</h2>
|
||||||
{ this.componentForStep(this._getCurrentFlowStep()) }
|
{ this.componentForStep(this._getCurrentFlowStep()) }
|
||||||
|
@ -185,12 +185,7 @@ module.exports = React.createClass({displayName: 'Login',
|
||||||
Create a new account
|
Create a new account
|
||||||
</a>
|
</a>
|
||||||
<br/>
|
<br/>
|
||||||
<div className="mx_Login_links">
|
<LoginFooter />
|
||||||
<a href="https://medium.com/@Vector">blog</a> ·
|
|
||||||
<a href="https://twitter.com/@VectorCo">twitter</a> ·
|
|
||||||
<a href="https://github.com/vector-im/vector-web">github</a> ·
|
|
||||||
<a href="https://matrix.org">powered by Matrix</a>
|
|
||||||
</div>
|
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
|
|
|
@ -58,12 +58,11 @@ module.exports = React.createClass({
|
||||||
render: function() {
|
render: function() {
|
||||||
var ChangeDisplayName = sdk.getComponent('settings.ChangeDisplayName');
|
var ChangeDisplayName = sdk.getComponent('settings.ChangeDisplayName');
|
||||||
var ChangeAvatar = sdk.getComponent('settings.ChangeAvatar');
|
var ChangeAvatar = sdk.getComponent('settings.ChangeAvatar');
|
||||||
|
var LoginHeader = sdk.getComponent('login.LoginHeader');
|
||||||
return (
|
return (
|
||||||
<div className="mx_Login">
|
<div className="mx_Login">
|
||||||
<div className="mx_Login_box">
|
<div className="mx_Login_box">
|
||||||
<div className="mx_Login_logo">
|
<LoginHeader />
|
||||||
<img src="img/logo.png" width="249" height="78" alt="vector"/>
|
|
||||||
</div>
|
|
||||||
<div className="mx_Login_profile">
|
<div className="mx_Login_profile">
|
||||||
Set a display name:
|
Set a display name:
|
||||||
<ChangeDisplayName />
|
<ChangeDisplayName />
|
||||||
|
|
|
@ -234,12 +234,11 @@ module.exports = React.createClass({
|
||||||
},
|
},
|
||||||
|
|
||||||
render: function() {
|
render: function() {
|
||||||
|
var LoginHeader = sdk.getComponent('login.LoginHeader');
|
||||||
return (
|
return (
|
||||||
<div className="mx_Login">
|
<div className="mx_Login">
|
||||||
<div className="mx_Login_box">
|
<div className="mx_Login_box">
|
||||||
<div className="mx_Login_logo">
|
<LoginHeader />
|
||||||
<img src="img/logo.png" width="249" height="78" alt="vector"/>
|
|
||||||
</div>
|
|
||||||
{this._getRegisterContentJsx()}
|
{this._getRegisterContentJsx()}
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
|
|
50
src/components/views/login/CustomServerDialog.js
Normal file
50
src/components/views/login/CustomServerDialog.js
Normal file
|
@ -0,0 +1,50 @@
|
||||||
|
/*
|
||||||
|
Copyright 2015 OpenMarket Ltd
|
||||||
|
|
||||||
|
Licensed under the Apache License, Version 2.0 (the "License");
|
||||||
|
you may not use this file except in compliance with the License.
|
||||||
|
You may obtain a copy of the License at
|
||||||
|
|
||||||
|
http://www.apache.org/licenses/LICENSE-2.0
|
||||||
|
|
||||||
|
Unless required by applicable law or agreed to in writing, software
|
||||||
|
distributed under the License is distributed on an "AS IS" BASIS,
|
||||||
|
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
||||||
|
See the License for the specific language governing permissions and
|
||||||
|
limitations under the License.
|
||||||
|
*/
|
||||||
|
|
||||||
|
var React = require("react");
|
||||||
|
|
||||||
|
module.exports = React.createClass({
|
||||||
|
displayName: 'CustomServerDialog',
|
||||||
|
|
||||||
|
render: function() {
|
||||||
|
return (
|
||||||
|
<div className="mx_ErrorDialog">
|
||||||
|
<div className="mx_ErrorDialogTitle">
|
||||||
|
Custom Server Options
|
||||||
|
</div>
|
||||||
|
<div className="mx_Dialog_content">
|
||||||
|
<span>
|
||||||
|
You can use the custom server options to log into other Matrix
|
||||||
|
servers by specifying a different Home server URL.
|
||||||
|
<br/>
|
||||||
|
This allows you to use this app with an existing Matrix account on
|
||||||
|
a different Home server.
|
||||||
|
<br/>
|
||||||
|
<br/>
|
||||||
|
You can also set a custom Identity server but this will affect
|
||||||
|
people's ability to find you if you use a server in a group other
|
||||||
|
than the main Matrix.org group.
|
||||||
|
</span>
|
||||||
|
</div>
|
||||||
|
<div className="mx_Dialog_buttons">
|
||||||
|
<button onClick={this.props.onFinished} autoFocus={true}>
|
||||||
|
Dismiss
|
||||||
|
</button>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
);
|
||||||
|
}
|
||||||
|
});
|
31
src/components/views/login/LoginFooter.js
Normal file
31
src/components/views/login/LoginFooter.js
Normal file
|
@ -0,0 +1,31 @@
|
||||||
|
/*
|
||||||
|
Copyright 2015 OpenMarket Ltd
|
||||||
|
|
||||||
|
Licensed under the Apache License, Version 2.0 (the "License");
|
||||||
|
you may not use this file except in compliance with the License.
|
||||||
|
You may obtain a copy of the License at
|
||||||
|
|
||||||
|
http://www.apache.org/licenses/LICENSE-2.0
|
||||||
|
|
||||||
|
Unless required by applicable law or agreed to in writing, software
|
||||||
|
distributed under the License is distributed on an "AS IS" BASIS,
|
||||||
|
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
||||||
|
See the License for the specific language governing permissions and
|
||||||
|
limitations under the License.
|
||||||
|
*/
|
||||||
|
|
||||||
|
'use strict';
|
||||||
|
|
||||||
|
var React = require('react');
|
||||||
|
|
||||||
|
module.exports = React.createClass({
|
||||||
|
displayName: 'LoginFooter',
|
||||||
|
|
||||||
|
render: function() {
|
||||||
|
return (
|
||||||
|
<div className="mx_Login_links">
|
||||||
|
<a href="https://matrix.org">powered by Matrix</a>
|
||||||
|
</div>
|
||||||
|
);
|
||||||
|
}
|
||||||
|
});
|
31
src/components/views/login/LoginHeader.js
Normal file
31
src/components/views/login/LoginHeader.js
Normal file
|
@ -0,0 +1,31 @@
|
||||||
|
/*
|
||||||
|
Copyright 2015 OpenMarket Ltd
|
||||||
|
|
||||||
|
Licensed under the Apache License, Version 2.0 (the "License");
|
||||||
|
you may not use this file except in compliance with the License.
|
||||||
|
You may obtain a copy of the License at
|
||||||
|
|
||||||
|
http://www.apache.org/licenses/LICENSE-2.0
|
||||||
|
|
||||||
|
Unless required by applicable law or agreed to in writing, software
|
||||||
|
distributed under the License is distributed on an "AS IS" BASIS,
|
||||||
|
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
||||||
|
See the License for the specific language governing permissions and
|
||||||
|
limitations under the License.
|
||||||
|
*/
|
||||||
|
|
||||||
|
'use strict';
|
||||||
|
|
||||||
|
var React = require('react');
|
||||||
|
|
||||||
|
module.exports = React.createClass({
|
||||||
|
displayName: 'LoginHeader',
|
||||||
|
|
||||||
|
render: function() {
|
||||||
|
return (
|
||||||
|
<div className="mx_Login_logo">
|
||||||
|
Matrix
|
||||||
|
</div>
|
||||||
|
);
|
||||||
|
}
|
||||||
|
});
|
|
@ -93,24 +93,8 @@ module.exports = React.createClass({
|
||||||
},
|
},
|
||||||
|
|
||||||
showHelpPopup: function() {
|
showHelpPopup: function() {
|
||||||
var ErrorDialog = sdk.getComponent('dialogs.ErrorDialog');
|
var CustomServerDialog = sdk.getComponent('login.CustomServerDialog');
|
||||||
Modal.createDialog(ErrorDialog, {
|
Modal.createDialog(CustomServerDialog);
|
||||||
title: 'Custom Server Options',
|
|
||||||
description: <span>
|
|
||||||
You can use the custom server options to log into other Matrix
|
|
||||||
servers by specifying a different Home server URL.
|
|
||||||
<br/>
|
|
||||||
This allows you to use Vector with an existing Matrix account on
|
|
||||||
a different Home server.
|
|
||||||
<br/>
|
|
||||||
<br/>
|
|
||||||
You can also set a custom Identity server but this will affect
|
|
||||||
people's ability to find you if you use a server in a group other
|
|
||||||
than the main Matrix.org group.
|
|
||||||
</span>,
|
|
||||||
button: "Dismiss",
|
|
||||||
focus: true
|
|
||||||
});
|
|
||||||
},
|
},
|
||||||
|
|
||||||
render: function() {
|
render: function() {
|
||||||
|
|
|
@ -29,7 +29,7 @@ module.exports = React.createClass({
|
||||||
displayName: 'RoomList',
|
displayName: 'RoomList',
|
||||||
|
|
||||||
propTypes: {
|
propTypes: {
|
||||||
ConferenceHandler: React.PropTypes.any, // e.g. VectorConferenceHandler
|
ConferenceHandler: React.PropTypes.any,
|
||||||
collapsed: React.PropTypes.bool,
|
collapsed: React.PropTypes.bool,
|
||||||
currentRoom: React.PropTypes.string
|
currentRoom: React.PropTypes.string
|
||||||
},
|
},
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue