fix: add missing each-block keys (svelte/require-each-key)
Fixed all 27 remaining instances across 19 files. Keys used: - Object ID fields where available (e.g. account_id_random, event_file_id) - index for logger lists with no reliable unique key - Property name for Object.entries() loops
This commit is contained in:
@@ -14,7 +14,7 @@
|
||||
|
||||
async function load_users() {
|
||||
loading = true;
|
||||
|
||||
|
||||
let for_obj_id: string | null = $ae_loc.account_id;
|
||||
let include_global = true;
|
||||
|
||||
@@ -48,7 +48,7 @@
|
||||
const username = prompt('Enter new username:');
|
||||
if (!username) return;
|
||||
const email = prompt('Enter email address:');
|
||||
|
||||
|
||||
// Link to account if scope is 'account' or 'all', otherwise create global user
|
||||
const account_id = qry_account_scope === 'global' ? undefined : $ae_loc.account_id;
|
||||
|
||||
@@ -87,12 +87,12 @@
|
||||
<div class="flex items-center justify-center px-4 bg-surface-300-600-token border-r border-surface-500/20">
|
||||
<Search size={18} class="opacity-50" />
|
||||
</div>
|
||||
<input
|
||||
<input
|
||||
class="bg-transparent border-0 ring-0 focus:ring-0 p-3 grow placeholder:opacity-50"
|
||||
type="search"
|
||||
bind:value={qry_str}
|
||||
placeholder="Search username or email..."
|
||||
onkeydown={(e) => e.key === 'Enter' && load_users()}
|
||||
type="search"
|
||||
bind:value={qry_str}
|
||||
placeholder="Search username or email..."
|
||||
onkeydown={(e) => e.key === 'Enter' && load_users()}
|
||||
/>
|
||||
<button class="variant-filled-primary font-bold px-10 py-3 hover:brightness-110 transition-all border-l border-surface-500/20 flex items-center justify-center min-w-[100px]" onclick={load_users} disabled={loading}>
|
||||
{#if loading}
|
||||
@@ -145,7 +145,7 @@
|
||||
</h3>
|
||||
|
||||
<div class="grid grid-cols-1 md:grid-cols-2 lg:grid-cols-3 gap-6">
|
||||
{#each user_li as user}
|
||||
{#each user_li as user (user.user_id_random)}
|
||||
<div class="card p-5 space-y-4 variant-soft-surface shadow-md border border-surface-500/10 hover:border-primary-500/30 transition-all group">
|
||||
<header class="flex justify-between items-start">
|
||||
<div class="flex items-center gap-3">
|
||||
@@ -174,7 +174,7 @@
|
||||
{/if}
|
||||
</div>
|
||||
</header>
|
||||
|
||||
|
||||
<div class="space-y-2">
|
||||
<div class="flex items-center gap-2 text-xs opacity-70 bg-black/5 p-2 rounded-lg">
|
||||
<Mail size={14} class="text-primary-500" />
|
||||
|
||||
Reference in New Issue
Block a user