-
-
Notifications
You must be signed in to change notification settings - Fork 2k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
RTS Welcome Pages #3103
RTS Welcome Pages #3103
Conversation
… geektime techfest
Conflicts: src/component-index.js src/skins/vector/css/matrix-react-sdk/views/rooms/_RoomPreviewBar.scss
See matrix-org/riot-team-server#14
Conflicts: src/skins/vector/css/matrix-react-sdk/views/rooms/_RoomPreviewBar.scss
@@ -0,0 +1,39 @@ | |||
/* | |||
Copyright 2016 OpenMarket Ltd |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
2017 Vector Creations Ltd
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Done
|
||
'use strict'; | ||
|
||
var React = require("react"); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
It would be awesome if we used import when writing new stuff (although I realise this probably wasn't yours)
render: function() { | ||
return ( | ||
<div className="mx_HomePage"> | ||
<iframe src={`${this.props.teamServerUrl}/static/${this.props.teamToken}/welcome.html`} style={{width: '100%', border: 'none'}}/> |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Unless there's a backwards-compat reason for it being 'welcome', I'd suggest maybe 'home'html', or just blank and use the index page.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Also would be nice to have the CSS not inline (in fact it looks like this is actually in the scss files, so probably just hasn't been removed from here).
@@ -0,0 +1,31 @@ | |||
/* | |||
Copyright 2016 OpenMarket Ltd |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
copyright again
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Done
@@ -98,9 +112,21 @@ module.exports = React.createClass({ | |||
|
|||
render: function() { | |||
var TintableSvg = sdk.getComponent('elements.TintableSvg'); | |||
|
|||
var homeButton; | |||
if (window.localStorage.getItem('mx_team_token')) { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Might be nice if this loaded the team token at mount time & then used the state here, which wouldn't hit localstorage on every render (and makes render more a function of the state).
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Awesome, thanks for fixing those (especially since most of them were not your code in the first place!)
No probs :) |
This tracks the changes required to re-use the "hompages" concept as a way of displaying welcome pages for RTS team members.
Goes with matrix-org/matrix-react-sdk#666
TODO: