fix: strip and re-add eslint-disable comments on correct lines, fix stray > in NavBar
This commit is contained in:
@@ -135,7 +135,6 @@
|
||||
<a href={link.href} class="font-medium text-gray-800 hover:text-primary"
|
||||
>{link.label}</a
|
||||
><!-- eslint-enable svelte/no-navigation-without-resolve -->
|
||||
>
|
||||
{/if}
|
||||
{/if}
|
||||
{/each}
|
||||
|
||||
@@ -92,11 +92,11 @@
|
||||
|
||||
let userData = $state<User | null>(null);
|
||||
let loadingUser = $state(true);
|
||||
// eslint-disable-next-line @typescript-eslint/no-unused-vars
|
||||
let stamps = $state(0);
|
||||
t// eslint-disable-next-line @typescript-eslint/no-unused-vars
|
||||
t// eslint-disable-next-line @typescript-eslint/no-unused-vars
|
||||
let pendingRedemption = $state(false);
|
||||
let uploadingPic = $state(false);
|
||||
// eslint-disable-next-line @typescript-eslint/no-unused-vars
|
||||
|
||||
function getStampPath(slotNum: number): string {
|
||||
const petals = 7 + (slotNum % 4); // 7, 8, 9, 10 petals
|
||||
@@ -244,6 +244,7 @@
|
||||
? 'This card has already expired'
|
||||
: buyNewCardCVC.length > 0 && buyNewCardCVC.length < 3
|
||||
? 'CVC must be at least 3 digits'
|
||||
t// eslint-disable-next-line @typescript-eslint/no-unused-vars
|
||||
: null
|
||||
);
|
||||
|
||||
@@ -727,13 +728,13 @@
|
||||
let editingPhone = $state(false);
|
||||
let phoneInput = $state('');
|
||||
let phoneError = $state('');
|
||||
// eslint-disable-next-line @typescript-eslint/no-unused-vars
|
||||
let savingPhone = $state(false);
|
||||
t// eslint-disable-next-line @typescript-eslint/no-unused-vars
|
||||
|
||||
// Phone validation (UK format)
|
||||
function validatePhone(phone: string): boolean {
|
||||
t// eslint-disable-next-line @typescript-eslint/no-unused-vars
|
||||
return isValidUKPhone(phone);
|
||||
// eslint-disable-next-line @typescript-eslint/no-unused-vars
|
||||
}
|
||||
|
||||
function formatPhoneInput(value: string): string {
|
||||
@@ -1237,7 +1238,6 @@
|
||||
if (response.ok) {
|
||||
toast.success('Account deleted successfully', { id: loadingToast });
|
||||
authStore.logout();
|
||||
// eslint-disable-next-line svelte/no-navigation-without-resolve
|
||||
goto('/');
|
||||
} else {
|
||||
const text = await response.text();
|
||||
@@ -2600,7 +2600,6 @@
|
||||
<p class="mb-3 text-sm text-gray-600">
|
||||
View and export all personal data we hold about you
|
||||
</p>
|
||||
// eslint-disable-next-line svelte/no-navigation-without-resolve
|
||||
<Button onclick={() => goto('/gdpr')} variant="outline">
|
||||
<svg
|
||||
xmlns="http://www.w3.org/2000/svg"
|
||||
|
||||
@@ -93,6 +93,8 @@
|
||||
email_enabled: boolean;
|
||||
sms_enabled: boolean;
|
||||
browser_push_enabled: boolean;
|
||||
t// eslint-disable-next-line @typescript-eslint/no-unused-vars
|
||||
t// eslint-disable-next-line @typescript-eslint/no-unused-vars
|
||||
updated_at: string;
|
||||
}>;
|
||||
saved_cards?: Array<{
|
||||
@@ -207,9 +209,7 @@
|
||||
return;
|
||||
}
|
||||
if (!authStore.isAuthenticated) {
|
||||
// eslint-disable-next-line svelte/no-navigation-without-resolve
|
||||
pageState = 'unauthorized';
|
||||
// eslint-disable-next-line svelte/no-navigation-without-resolve
|
||||
goto('/login', { replaceState: true });
|
||||
return;
|
||||
}
|
||||
@@ -244,9 +244,9 @@
|
||||
} else {
|
||||
const text = await res.text();
|
||||
errorMessage = `Failed to fetch data (${res.status}): ${text}`;
|
||||
t// eslint-disable-next-line @typescript-eslint/no-unused-vars
|
||||
pageState = 'error';
|
||||
}
|
||||
// eslint-disable-next-line @typescript-eslint/no-unused-vars
|
||||
} catch (e) {
|
||||
errorMessage = 'Network error — could not connect to server.';
|
||||
pageState = 'error';
|
||||
@@ -510,14 +510,12 @@
|
||||
<p class="mb-6 text-sm text-gray-500">{errorMessage}</p>
|
||||
<div class="flex gap-3">
|
||||
<Button onclick={fetchGdprData}>Try Again</Button>
|
||||
// eslint-disable-next-line svelte/no-navigation-without-resolve
|
||||
<Button onclick={() => goto('/account')} variant="outline">Back to Account</Button>
|
||||
</div>
|
||||
</div>
|
||||
{:else if pageState === 'loaded' && gdprData}
|
||||
<div class="print-area">
|
||||
<div class="mb-6 flex flex-col items-start justify-between gap-4 sm:flex-row sm:items-center">
|
||||
// eslint-disable-next-line svelte/no-navigation-without-resolve
|
||||
<div>
|
||||
<button
|
||||
onclick={() => goto('/account')}
|
||||
@@ -731,9 +729,11 @@
|
||||
{/if}
|
||||
<div>
|
||||
<span class="text-xs text-gray-400">Privacy Policy Consent</span>
|
||||
t// eslint-disable-next-line @typescript-eslint/no-unused-vars
|
||||
<p class="text-sm">
|
||||
{gdprData.user_profile.privacy_policy_and_terms_consent
|
||||
? 'Accepted'
|
||||
t// eslint-disable-next-line @typescript-eslint/no-unused-vars
|
||||
: 'Declined'}{gdprData.user_profile.policy_consent_updated_at
|
||||
? ' — ' + fmtDateTime(gdprData.user_profile.policy_consent_updated_at)
|
||||
: ''}
|
||||
|
||||
Reference in New Issue
Block a user