Add UTM info to all outgoing links to cloud

This commit is contained in:
ernstmul
2025-03-13 11:23:47 +01:00
parent dff4efd1a2
commit d39cb8c69e
17 changed files with 82 additions and 23 deletions

View File

@@ -3,6 +3,8 @@
import { IsLoggedIn } from '$lib/components';
import { GITHUB_REPO_LINK, GITHUB_STARS } from '$lib/constants';
import type { NavLink } from './MainNav.svelte';
import { PUBLIC_APPWRITE_DASHBOARD } from '$env/static/public';
import { getUtmSourceForLink } from '$lib/utils/utm';
export let open = false;
export let links: NavLink[];
@@ -17,7 +19,10 @@
<nav class="web-side-nav web-is-not-desktop" class:hidden={!open}>
<div class="web-side-nav-wrapper ps-4 pe-4">
<div class="flex items-center gap-2 px-4">
<a href="https://cloud.appwrite.io/register" class="web-button is-secondary flex-1">
<a
href={`${PUBLIC_APPWRITE_DASHBOARD}/register?${getUtmSourceForLink()}`}
class="web-button is-secondary flex-1"
>
Sign up
</a>
<IsLoggedIn classes="flex-1" />