-
Notifications
You must be signed in to change notification settings - Fork 95
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Rename USE_TABLE_INDEX => LILAC_USE_TABLE_INDEX. Add LILAC_PROD_MODE. (…
…#1134) Renames USE_TABLE_INDEX to LILAC_USE_TABLE_INDEX, and then makes sure it's backwards compat. Add LILAC_PROD_MODE, which disables toast notification errors for the public demo, which makes it just look janky and broken. Also add embeddings to missing datasets.
- Loading branch information
Showing
7 changed files
with
74 additions
and
29 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
33 changes: 33 additions & 0 deletions
33
web/blueprint/src/lib/components/ErrorNotifications.svelte
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,33 @@ | ||
<script lang="ts"> | ||
import {apiErrors} from '$lib/queries/queryClient'; | ||
import {ToastNotification} from 'carbon-components-svelte'; | ||
import {queryServerStatus} from '$lib/queries/serverQueries'; | ||
import type {ApiError} from '$lilac'; | ||
import ApiErrorModal from './ApiErrorModal.svelte'; | ||
let showError: ApiError | undefined = undefined; | ||
$: serverStatus = queryServerStatus(); | ||
$: disableErrorNotifications = $serverStatus.data?.disable_error_notifications; | ||
</script> | ||
|
||
{#if !disableErrorNotifications} | ||
{#each $apiErrors as error} | ||
<ToastNotification | ||
lowContrast | ||
title={error.name || 'Error'} | ||
subtitle={error.body.message || error.message} | ||
on:close={() => { | ||
$apiErrors = $apiErrors.filter(e => e !== error); | ||
}} | ||
> | ||
<div slot="caption"> | ||
<button class="underline" on:click={() => (showError = error)}>Show error</button> | ||
</div> | ||
</ToastNotification> | ||
{/each} | ||
{#if showError} | ||
<ApiErrorModal error={showError} /> | ||
{/if} | ||
{/if} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters