mirror of
https://github.com/wassname/talk.git
synced 2026-07-04 14:49:20 +08:00
22 lines
615 B
JavaScript
22 lines
615 B
JavaScript
import React from 'react';
|
|
import PropTypes from 'prop-types';
|
|
import { Button } from 'plugin-api/beta/client/components/ui';
|
|
import { t } from 'plugin-api/beta/client/services';
|
|
|
|
const SignInButton = ({ currentUser, showSignInDialog }) => (
|
|
<div className="talk-stream-auth-sign-in-button">
|
|
{!currentUser ? (
|
|
<Button id="coralSignInButton" onClick={showSignInDialog} full>
|
|
{t('talk-plugin-auth.login.sign_in_to_comment')}
|
|
</Button>
|
|
) : null}
|
|
</div>
|
|
);
|
|
|
|
SignInButton.propTypes = {
|
|
currentUser: PropTypes.object,
|
|
showSignInDialog: PropTypes.func,
|
|
};
|
|
|
|
export default SignInButton;
|