Better error norifications
This commit is contained in:
@@ -2,7 +2,7 @@
|
||||
import type { GoogleSheet } from '$lib/google/sheets/types.ts';
|
||||
|
||||
// Props
|
||||
let { sheetsData = $bindable(), errors = $bindable(), loadRecentSheets, selectSheet, toggleSheetList } = $props<{
|
||||
let { sheetsData = $bindable(), loadRecentSheets, selectSheet, toggleSheetList } = $props<{
|
||||
sheetsData: {
|
||||
availableSheets: GoogleSheet[];
|
||||
selectedSheet: GoogleSheet | null;
|
||||
@@ -16,7 +16,6 @@
|
||||
loading: boolean;
|
||||
expandedSheetList: boolean;
|
||||
};
|
||||
errors: Record<string, string>;
|
||||
loadRecentSheets: () => Promise<void>;
|
||||
selectSheet: (sheet: GoogleSheet) => Promise<void>;
|
||||
toggleSheetList: () => void;
|
||||
@@ -257,9 +256,7 @@
|
||||
</div>
|
||||
{/if}
|
||||
|
||||
{#if errors.sheet}
|
||||
<p class="mt-2 text-sm text-red-600">{errors.sheet}</p>
|
||||
{/if}
|
||||
<!-- Error messages are now shown as toast notifications -->
|
||||
</div>
|
||||
|
||||
{#if sheetsData.selectedSheet && sheetsData.sheetData.length > 0}
|
||||
@@ -374,9 +371,7 @@
|
||||
</div>
|
||||
{/if}
|
||||
|
||||
{#if errors.sheetData}
|
||||
<p class="text-sm text-red-600">{errors.sheetData}</p>
|
||||
{/if}
|
||||
<!-- Error messages are now shown as toast notifications -->
|
||||
</div>
|
||||
|
||||
|
||||
|
||||
Reference in New Issue
Block a user