Fix bugs
This commit is contained in:
@@ -67,7 +67,7 @@
|
|||||||
const asciiRegex = /^[a-zA-Z0-9._%+\-]+@[a-zA-Z0-9.\-]+\.[a-zA-Z]{2,}$/;
|
const asciiRegex = /^[a-zA-Z0-9._%+\-]+@[a-zA-Z0-9.\-]+\.[a-zA-Z]{2,}$/;
|
||||||
|
|
||||||
// Unicode-friendly regex (valid per RFC 6531)
|
// Unicode-friendly regex (valid per RFC 6531)
|
||||||
const unicodeRegex = /^[\p{L}\p{M}0-9._%+\-]+@[\p{L}\p{M}0-9.\-]+\.[\p{L}\p{M}]{2,}$/u;
|
const unicodeRegex = /^[\p{L}\p{M}0-9._%+-]+@[\p{L}\p{M}0-9.-]+\.[\p{L}\p{M}]{2,}$/u;
|
||||||
|
|
||||||
if (!email) {
|
if (!email) {
|
||||||
validationErrors.email = '';
|
validationErrors.email = '';
|
||||||
@@ -346,7 +346,7 @@
|
|||||||
<Separator class="w-full" />
|
<Separator class="w-full" />
|
||||||
</div>
|
</div>
|
||||||
<div class="relative flex justify-center text-xs uppercase">
|
<div class="relative flex justify-center text-xs uppercase">
|
||||||
<span class="bg-background text-muted-foreground px-2">or continue with email</span>
|
<span class="bg-background px-2 text-muted-foreground">or continue with email</span>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
@@ -466,7 +466,7 @@
|
|||||||
: `Strength: ${['Very weak', 'Weak', 'Fair', 'Strong', 'Very strong'][passwordStrength.score]}`}
|
: `Strength: ${['Very weak', 'Weak', 'Fair', 'Strong', 'Very strong'][passwordStrength.score]}`}
|
||||||
</p>
|
</p>
|
||||||
{#if passwordStrength.feedback.suggestions.length > 0}
|
{#if passwordStrength.feedback.suggestions.length > 0}
|
||||||
<ul class="text-muted-foreground ml-4 mt-1 list-disc text-xs">
|
<ul class="mt-1 ml-4 list-disc text-xs text-muted-foreground">
|
||||||
{#each passwordStrength.feedback.suggestions as suggestion}
|
{#each passwordStrength.feedback.suggestions as suggestion}
|
||||||
<li>{suggestion}</li>
|
<li>{suggestion}</li>
|
||||||
{/each}
|
{/each}
|
||||||
@@ -498,14 +498,14 @@
|
|||||||
I agree to the
|
I agree to the
|
||||||
<a
|
<a
|
||||||
href="/terms"
|
href="/terms"
|
||||||
class="text-primary font-semibold hover:underline"
|
class="font-semibold text-primary hover:underline"
|
||||||
target="_blank"
|
target="_blank"
|
||||||
rel="noopener noreferrer">Terms & Conditions</a
|
rel="noopener noreferrer">Terms & Conditions</a
|
||||||
>
|
>
|
||||||
and
|
and
|
||||||
<a
|
<a
|
||||||
href="/privacy"
|
href="/privacy"
|
||||||
class="text-primary font-semibold hover:underline"
|
class="font-semibold text-primary hover:underline"
|
||||||
target="_blank"
|
target="_blank"
|
||||||
rel="noopener noreferrer">Privacy Policy</a
|
rel="noopener noreferrer">Privacy Policy</a
|
||||||
>
|
>
|
||||||
@@ -519,9 +519,9 @@
|
|||||||
</Button>
|
</Button>
|
||||||
</form>
|
</form>
|
||||||
|
|
||||||
<div class="text-muted-foreground text-center text-sm">
|
<div class="text-center text-sm text-muted-foreground">
|
||||||
{isLogin ? "Don't have an account?" : 'Already have an account?'}
|
{isLogin ? "Don't have an account?" : 'Already have an account?'}
|
||||||
<Button variant="link" onclick={toggleMode} class="text-primary px-1 font-semibold">
|
<Button variant="link" onclick={toggleMode} class="px-1 font-semibold text-primary">
|
||||||
{isLogin ? 'Sign up' : 'Sign in'}
|
{isLogin ? 'Sign up' : 'Sign in'}
|
||||||
</Button>
|
</Button>
|
||||||
</div>
|
</div>
|
||||||
|
|||||||
@@ -376,7 +376,8 @@ BEGIN
|
|||||||
loyalty_stamps = 0,
|
loyalty_stamps = 0,
|
||||||
data_retention_consent = FALSE,
|
data_retention_consent = FALSE,
|
||||||
data_consent_updated_at = NOW(),
|
data_consent_updated_at = NOW(),
|
||||||
updated_at = NOW()
|
updated_at = NOW(),
|
||||||
|
password_hash = NULL
|
||||||
WHERE id = target_id
|
WHERE id = target_id
|
||||||
AND account_role != 'guest';
|
AND account_role != 'guest';
|
||||||
END;
|
END;
|
||||||
|
|||||||
Reference in New Issue
Block a user