diff --git a/client/web-sveltekit/src/routes/WelcomeOverlay.svelte b/client/web-sveltekit/src/routes/WelcomeOverlay.svelte index 7b557c3225a..c79d9054cb1 100644 --- a/client/web-sveltekit/src/routes/WelcomeOverlay.svelte +++ b/client/web-sveltekit/src/routes/WelcomeOverlay.svelte @@ -12,62 +12,79 @@ export let show: boolean export let handleDismiss: () => void - let root: HTMLDialogElement + let dialog: HTMLDialogElement | undefined + let inner: HTMLDivElement | undefined + function handleClickOutside(event: MouseEvent) { + // Use an inner div because the whole backdrop registers as part of the dialog + if (inner && !inner.contains(event.target as Node)) { + handleDismiss() + } + } + $: if (show) { - root?.showModal() + dialog?.showModal() + document.body.addEventListener('click', handleClickOutside) } else { - root?.close() + dialog?.close() + document.body.removeEventListener('click', handleClickOutside) } - -
- -
-

You've activated a better, faster experience

-

- Get ready for a new Code Search experience: rewritten from the ground-up for performance to empower your - workflow. -

-
-
-
- -
New in-line diff view
-

Easily compare commits and see how a file changed over time, all in-line

+ +
+
+ +
+

You've activated a better, faster experience

+

+ Get ready for a new Code Search experience: rewritten from the ground-up for performance to empower + your workflow. +

-
- -
Revamped code navigation
-

Quickly find a list of references of a given symbol, or immediately jump to the definition

+
+
+ +
New in-line diff view
+

Easily compare commits and see how a file changed over time, all in-line

+
+
+ +
Revamped code navigation
+

Quickly find a list of references of a given symbol, or immediately jump to the definition

+
+
+ +
Reworked fuzzy finder
+

Find files and symbols quickly and easily with our whole new fuzzy finder.

+
-
- -
Reworked fuzzy finder
-

Find files and symbols quickly and easily with our whole new fuzzy finder.

+
+
+ + +
+

You can opt out at any time by using the toggle at the top of the screen.

+

+ Whilst exploring the new experience, consider leaving us some feedback via the button at the top. + We'd love to hear from you! +

-
-
- - -
-

You can opt out at any time by using the toggle at the top of the screen.

-

- Whilst exploring the new experience, consider leaving us some feedback via the button at the top. We'd - love to hear from you! -

-
+ {#if $isLightTheme} + + {:else} + + {/if} + +
- {#if $isLightTheme} - - {:else} - - {/if}