Skip to content

Commit e5f5a2e

Browse files
committed
[#915] Change name of SocialAuthButton params
1 parent 156b2ad commit e5f5a2e

File tree

2 files changed

+11
-11
lines changed

2 files changed

+11
-11
lines changed

client/modules/User/components/SocialAuthButton.jsx

Lines changed: 7 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -42,11 +42,11 @@ const StyledButton = styled(Button)`
4242
width: ${remSize(300)};
4343
`;
4444

45-
function SocialAuthButton({ service, link, connected }) {
45+
function SocialAuthButton({ service, linkStyle, isConnected }) {
4646
const ServiceIcon = icons[service];
4747
let label;
48-
if (link) {
49-
label = connected ? linkLabels[service].connected : linkLabels[service].connect;
48+
if (linkStyle) {
49+
label = isConnected ? linkLabels[service].connected : linkLabels[service].connect;
5050
} else {
5151
label = labels[service];
5252
}
@@ -64,13 +64,13 @@ SocialAuthButton.services = services;
6464

6565
SocialAuthButton.propTypes = {
6666
service: PropTypes.oneOf(['github', 'google']).isRequired,
67-
link: PropTypes.bool,
68-
connected: PropTypes.bool
67+
linkStyle: PropTypes.bool,
68+
isConnected: PropTypes.bool
6969
};
7070

7171
SocialAuthButton.defaultProps = {
72-
link: false,
73-
connected: false
72+
linkStyle: false,
73+
isConnected: false
7474
};
7575

7676
export default SocialAuthButton;

client/modules/User/pages/AccountView.jsx

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -24,13 +24,13 @@ function SocialLoginPanel(props) {
2424
<div className="account__social-stack">
2525
<SocialAuthButton
2626
service={SocialAuthButton.services.github}
27-
link
28-
connected={!!user.github}
27+
linkStyle
28+
isConnected={!!user.github}
2929
/>
3030
<SocialAuthButton
3131
service={SocialAuthButton.services.google}
32-
link
33-
connected={!!user.google}
32+
linkStyle
33+
isConnected={!!user.google}
3434
/>
3535
</div>
3636
</React.Fragment>

0 commit comments

Comments
 (0)