Implemented a custom password strength component

ref #106
This commit is contained in:
2021-03-26 18:47:24 +01:00
parent bc36411993
commit 4956bb0e9c
2 changed files with 15 additions and 0 deletions

View File

@@ -0,0 +1,14 @@
<script>
import { getLocaleFromNavigator, _ } from "svelte-i18n";
import { passwordStrength } from "check-password-strength";
export let password_change;
$: strength = passwordStrength(password_change);
</script>
<div>
<ul>
{#if !strength.contains.includes('lowercase')}
<li>Must contain a lowercase letter</li>
{/if}
</ul>
</div>