diff --git a/src/lib/components/index.ts b/src/lib/components/index.ts index 84a530f09..0542458bc 100644 --- a/src/lib/components/index.ts +++ b/src/lib/components/index.ts @@ -77,6 +77,7 @@ export { default as ImagePreview } from './imagePreview.svelte'; export { default as MfaChallengeFormList } from './mfaChallengeFormList.svelte'; export { default as BottomModalAlert } from './bottomModalAlert.svelte'; export { default as NewConsoleBanner } from './newConsoleBanner.svelte'; +export { default as NewConsoleModal } from './newConsoleModal.svelte'; export { default as Navbar } from './navbar.svelte'; export { default as Breadcrumbs } from './breadcrumbs.svelte'; export { default as Sidebar } from './sidebar.svelte'; diff --git a/src/lib/components/newConsoleModal.svelte b/src/lib/components/newConsoleModal.svelte new file mode 100644 index 000000000..cc34e7f03 --- /dev/null +++ b/src/lib/components/newConsoleModal.svelte @@ -0,0 +1,55 @@ + + + + + We rebuilt the Console from the ground up. It's faster, it's cleaner, and everything you're + working on comes with you. Nothing to migrate. + + + + + + + + diff --git a/src/routes/(console)/+layout.svelte b/src/routes/(console)/+layout.svelte index b5b2c612a..b1ef0c6bc 100644 --- a/src/routes/(console)/+layout.svelte +++ b/src/routes/(console)/+layout.svelte @@ -44,7 +44,7 @@ import { headerAlert } from '$lib/stores/headerAlert'; import { UsageRates } from '$lib/components/billing'; import { canSeeProjects } from '$lib/stores/roles'; - import { BottomModalAlert, NewConsoleBanner } from '$lib/components'; + import { BottomModalAlert, NewConsoleBanner, NewConsoleModal } from '$lib/components'; import { shouldShowNotification } from '$lib/helpers/notifications'; import { isSmallViewport } from '$lib/stores/viewport'; import { @@ -339,6 +339,16 @@ } }); + let showNewConsoleModal = false; + + onMount(() => { + // Never during onboarding: a first run is the worst moment to interrupt. + const isOnOnboarding = page.url.pathname.includes(base + '/onboarding'); + + showNewConsoleModal = + isCloud && !isOnOnboarding && shouldShowNotification('newConsoleModal'); + }); + $: (void $headerAlert, ($activeHeaderAlert = headerAlert.getExcluding('impersonation'))); @@ -375,3 +385,5 @@ {/if} + +