You've already forked matrix-react-sdk
mirror of
https://github.com/matrix-org/matrix-react-sdk.git
synced 2025-11-08 21:42:24 +03:00
Allow base referral URL to be configurable
This commit is contained in:
@@ -92,6 +92,9 @@ module.exports = React.createClass({
|
||||
// True to show the 'labs' section of experimental features
|
||||
enableLabs: React.PropTypes.bool,
|
||||
|
||||
// The base URL to use in the referral link. Defaults to window.location.origin.
|
||||
referralBaseUrl: React.PropTypes.string,
|
||||
|
||||
// true if RightPanel is collapsed
|
||||
collapsedRhs: React.PropTypes.bool,
|
||||
},
|
||||
@@ -453,7 +456,7 @@ module.exports = React.createClass({
|
||||
console.warn('Team token not a string');
|
||||
return null;
|
||||
}
|
||||
const href = window.location.origin +
|
||||
const href = (this.props.referralBaseUrl || window.location.origin) +
|
||||
`/#/register?referrer=${this._me}&team_token=${teamToken}`;
|
||||
return (
|
||||
<div>
|
||||
|
||||
Reference in New Issue
Block a user