Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Don't show password policy if password is just generated #9736

Merged
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -8,5 +8,6 @@ https://github.com/owncloud/web/pull/9634
https://github.com/owncloud/web/pull/9686
https://github.com/owncloud/web/pull/9688
https://github.com/owncloud/web/pull/9735
https://github.com/owncloud/web/pull/9736
https://github.com/owncloud/web/issues/9638
https://github.com/owncloud/web/issues/9657
Original file line number Diff line number Diff line change
Expand Up @@ -11,6 +11,7 @@
v-model="password"
:type="showPassword ? 'text' : 'password'"
ref="passwordInput"
@input="onPasswordEntered"
/>
<oc-button
v-if="password"
Expand Down Expand Up @@ -147,13 +148,15 @@ export default defineComponent({
emit('passwordGenerated', password.value)
}

const onPasswordEntered = () => {
passwordEntered.value = true
}

const focus = () => {
unref(passwordInput).focus()
}

watch(password, (value) => {
passwordEntered.value = true

if (!Object.keys(props.passwordPolicy).length) {
return
}
Expand All @@ -174,6 +177,7 @@ export default defineComponent({
copyPasswordIcon,
showPasswordPolicyInformation,
testedPasswordPolicy,
onPasswordEntered,
generatePassword,
getPasswordPolicyRuleMessage,
copyPasswordToClipboard
Expand Down