UX: Hide external login column when account creation in progress (#12048)

This commit is contained in:
David Taylor 2021-02-11 16:26:29 +00:00 committed by GitHub
parent 5e1c8111d3
commit 49affb0542
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -87,13 +87,17 @@ export default Controller.extend(
return getURL(`/images/emoji/${emojiSet}/wave/${random}.png`);
},
@discourseComputed("userFields", "hasAtLeastOneLoginButton")
modalBodyClasses(userFields, hasAtLeastOneLoginButton) {
@discourseComputed(
"userFields",
"hasAtLeastOneLoginButton",
"hasAuthOptions"
)
modalBodyClasses(userFields, hasAtLeastOneLoginButton, hasAuthOptions) {
const classes = [];
if (userFields) {
classes.push("has-user-fields");
}
if (hasAtLeastOneLoginButton) {
if (hasAtLeastOneLoginButton && !hasAuthOptions) {
classes.push("has-alt-auth");
}
return classes.join(" ");