From 12896bd23eeba79884245c1c29fdc568cf21a7fa Mon Sep 17 00:00:00 2001 From: Christopher Speller Date: Mon, 14 Mar 2016 08:50:46 -0400 Subject: Converting to Webpack. Stage 1. --- webapp/components/team_signup_choose_auth.jsx | 140 ++++++++++++++++++++++++++ 1 file changed, 140 insertions(+) create mode 100644 webapp/components/team_signup_choose_auth.jsx (limited to 'webapp/components/team_signup_choose_auth.jsx') diff --git a/webapp/components/team_signup_choose_auth.jsx b/webapp/components/team_signup_choose_auth.jsx new file mode 100644 index 000000000..d26e8a9ac --- /dev/null +++ b/webapp/components/team_signup_choose_auth.jsx @@ -0,0 +1,140 @@ +// Copyright (c) 2015 Mattermost, Inc. All Rights Reserved. +// See License.txt for license information. + +import {FormattedMessage} from 'react-intl'; + +import React from 'react'; + +export default class ChooseAuthPage extends React.Component { + constructor(props) { + super(props); + this.state = {}; + } + render() { + var buttons = []; + if (global.window.mm_config.EnableSignUpWithGitLab === 'true') { + buttons.push( + + + + + + + ); + } + + if (global.window.mm_config.EnableSignUpWithGoogle === 'true') { + buttons.push( + { + e.preventDefault(); + this.props.updatePage('google'); + } + } + > + + + + + + ); + } + + if (global.window.mm_config.EnableLdap === 'true') { + buttons.push( + { + e.preventDefault(); + this.props.updatePage('ldap'); + } + } + > + + + + + + ); + } + + if (global.window.mm_config.EnableSignUpWithEmail === 'true') { + buttons.push( + + + + + + + ); + } + + if (buttons.length === 0) { + buttons = ( + + + + ); + } + + return ( +
+ {buttons} +
+ + + +
+
+ ); + } +} + +ChooseAuthPage.propTypes = { + updatePage: React.PropTypes.func +}; -- cgit v1.2.3-1-g7c22