Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
10 changes: 8 additions & 2 deletions src/lib/components/promos/imagine.svelte
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
<script lang="ts">
import { NoToneMapping } from 'three';
import { Canvas } from '@threlte/core';
import ImagineSvg from './imagine.svg';
import ProductHuntSvg from './product-hunt.svg';
import ImaginationShader from './shader.svelte';
</script>

Expand All @@ -12,7 +12,11 @@
</Canvas>
</div>

<!--- Hidden logo
<img src={ImagineSvg} alt="Imagine" class="imagine-logo" />
-->

<img src={ProductHuntSvg} alt="Product Hunt" class="imagine-logo" />
</div>

<style>
Expand All @@ -22,17 +26,19 @@
position: relative;
background-color: #000000;
border: 0.795px solid var(--border-neutral-strong);
overflow: hidden;
}

.imagine-canvas {
position: absolute;
inset: 0;
}

.imagine-logo {
top: 50%;
left: 50%;
width: auto;
height: 24px;
height:40px;
position: absolute;
transform: translate(-50%, -50%);
}
Expand Down
12 changes: 12 additions & 0 deletions src/lib/components/promos/product-hunt.svg
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
14 changes: 7 additions & 7 deletions src/routes/(console)/bottomAlerts.ts
Original file line number Diff line number Diff line change
Expand Up @@ -7,22 +7,22 @@ import {
showBottomModalAlert
} from '$lib/stores/bottom-alerts';

const SHOW_IMAGINE_PROMO = false;
const SHOW_IMAGINE_PROMO = true;
import { ProfileMode, resolvedProfile } from '$lib/profiles/index.svelte';

const listOfPromotions: BottomModalAlertItem[] = [];

if (isCloud && SHOW_IMAGINE_PROMO) {
const imaginePromo: BottomModalAlertItem = {
id: 'modal:imagine.dev',
id: 'modal:imagine-ph-launch-studio',
backgroundComponent: Imagine,
title: 'Introducing Imagine',
message: 'the most complete AI builder to date',
title: 'Imagine is live on Product Hunt',
message: 'Ask questions, share feedback, and support the launch',
importance: 8,
scope: 'everywhere',
plan: 'free',
cta: {
text: 'Try it now',
text: 'Head to Product Hunt',
color: {
light: '#FFFFFF',
dark: '#000000'
Expand All @@ -35,7 +35,7 @@ if (isCloud && SHOW_IMAGINE_PROMO) {
light: '#333333',
dark: '#CCCCCC'
},
link: () => 'https://cloud.appwrite.io',
link: () => 'https://apwr.dev/imagine-ph-studio',
external: true,
hideOnClick: true
},
Expand All @@ -47,7 +47,7 @@ if (isCloud && SHOW_IMAGINE_PROMO) {

export function addBottomModalAlerts() {
// fast path: not the valid profile to show this!
if (resolvedProfile.id !== ProfileMode.CONSOLE) return;
if (resolvedProfile.id !== ProfileMode.STUDIO) return;

listOfPromotions.forEach((promotion) => showBottomModalAlert(promotion));

Expand Down
Loading