Skip to content

Commit

Permalink
Merge pull request #21829 from nextcloud/bugfix/noid/fix-login-form-e…
Browse files Browse the repository at this point in the history
…rors

Fix login form erors
  • Loading branch information
rullzer authored Jul 15, 2020
2 parents 91df865 + d5b85e5 commit b327b4f
Show file tree
Hide file tree
Showing 11 changed files with 27 additions and 14 deletions.
2 changes: 1 addition & 1 deletion core/js/dist/install.js

Large diffs are not rendered by default.

2 changes: 1 addition & 1 deletion core/js/dist/install.js.map

Large diffs are not rendered by default.

2 changes: 1 addition & 1 deletion core/js/dist/login.js

Large diffs are not rendered by default.

2 changes: 1 addition & 1 deletion core/js/dist/login.js.map

Large diffs are not rendered by default.

2 changes: 1 addition & 1 deletion core/js/dist/main.js

Large diffs are not rendered by default.

2 changes: 1 addition & 1 deletion core/js/dist/main.js.map

Large diffs are not rendered by default.

2 changes: 1 addition & 1 deletion core/js/dist/maintenance.js

Large diffs are not rendered by default.

2 changes: 1 addition & 1 deletion core/js/dist/maintenance.js.map

Large diffs are not rendered by default.

2 changes: 1 addition & 1 deletion core/js/dist/recommendedapps.js

Large diffs are not rendered by default.

2 changes: 1 addition & 1 deletion core/js/dist/recommendedapps.js.map

Large diffs are not rendered by default.

21 changes: 17 additions & 4 deletions core/src/components/login/LoginForm.vue
Original file line number Diff line number Diff line change
Expand Up @@ -23,7 +23,7 @@
<form ref="loginForm"
method="post"
name="login"
:action="OC.generateUrl('login')"
:action="loginActionUrl"
@submit="submit">
<fieldset>
<div v-if="apacheAuthFailed"
Expand All @@ -47,7 +47,7 @@
class="hidden">
<img class="float-spinner"
alt=""
:src="OC.imagePath('core', 'loading-dark.gif')">
:src="loadingIcon">
<span id="messageText" />
<!-- the following div ensures that the spinner is always inside the #message div -->
<div style="clear: both;" />
Expand All @@ -65,7 +65,7 @@
:aria-label="t('core', 'Username or email')"
required
@change="updateUsername">
<label for="user" class="infield">{{ t('core', 'Username or email') }}</label>
<label for="user" class="infield">{{ t('core', 'Username or email') }}</label>
</p>

<p class="groupbottom"
Expand All @@ -82,7 +82,7 @@
<label for="password"
class="infield">{{ t('Password') }}</label>
<a href="#" class="toggle-password" @click.stop.prevent="togglePassword">
<img :src="OC.imagePath('core', 'actions/toggle.svg')">
<img :src="toggleIcon">
</a>
</p>

Expand Down Expand Up @@ -126,6 +126,10 @@
<script>
import jstz from 'jstimezonedetect'
import LoginButton from './LoginButton'
import {
generateUrl,
imagePath,
} from '@nextcloud/router'
export default {
name: 'LoginForm',
Expand Down Expand Up @@ -185,6 +189,15 @@ export default {
userDisabled() {
return this.errors.indexOf('userdisabled') !== -1
},
toggleIcon() {
return imagePath('core', 'actions/toggle.svg')
},
loadingIcon() {
return imagePath('core', 'loading-dark.gif')
},
loginActionUrl() {
return generateUrl('login')
},
},
mounted() {
if (this.username === '') {
Expand Down

0 comments on commit b327b4f

Please sign in to comment.