diff --git a/package-lock.json b/package-lock.json index a05ed67da..6c3e33c16 100644 --- a/package-lock.json +++ b/package-lock.json @@ -9,6 +9,7 @@ "version": "0.0.1", "dependencies": { "@analytics/google-analytics": "^1.0.5", + "@analytics/google-tag-manager": "^0.5.3", "@appwrite.io/pink": "^0.0.4", "@aw-labs/appwrite-console": "npm:appwrite-shimon@^7.2.4", "@popperjs/core": "^2.11.6", @@ -114,6 +115,11 @@ "resolved": "https://registry.npmjs.org/@analytics/google-analytics/-/google-analytics-1.0.5.tgz", "integrity": "sha512-I/yfiCVQo8AeT72KPa6z571LJKDbLdm4ntDqOHiE2Xehw9UjKcXQWiKTHL1/nfOOiekfpLf/6rFS5P6dQ0vImw==" }, + "node_modules/@analytics/google-tag-manager": { + "version": "0.5.3", + "resolved": "https://registry.npmjs.org/@analytics/google-tag-manager/-/google-tag-manager-0.5.3.tgz", + "integrity": "sha512-hk9cQtccAA48y3yP7wZ7k0ugi7qqi4dGB/w8d+hXwnPbo52MNu07ZtclL94S4GCb2vfVPfUgGz8vpuYBUO1xZw==" + }, "node_modules/@analytics/localstorage-utils": { "version": "0.1.8", "resolved": "https://registry.npmjs.org/@analytics/localstorage-utils/-/localstorage-utils-0.1.8.tgz", diff --git a/package.json b/package.json index 3bccef3ca..f65f02b91 100644 --- a/package.json +++ b/package.json @@ -20,6 +20,7 @@ }, "dependencies": { "@analytics/google-analytics": "^1.0.5", + "@analytics/google-tag-manager": "^0.5.3", "@appwrite.io/pink": "^0.0.4", "@aw-labs/appwrite-console": "npm:appwrite-shimon@^7.2.4", "@popperjs/core": "^2.11.6", diff --git a/src/app.html b/src/app.html index 994a0b038..3a25d1151 100644 --- a/src/app.html +++ b/src/app.html @@ -43,6 +43,8 @@ + + %sveltekit.head% diff --git a/src/lib/actions/analytics.ts b/src/lib/actions/analytics.ts index c4324b970..66a018140 100644 --- a/src/lib/actions/analytics.ts +++ b/src/lib/actions/analytics.ts @@ -1,7 +1,8 @@ import { page } from '$app/stores'; import { user } from '$lib/stores/user'; -import { ENV, MODE, VARS } from '$lib/system'; +import { ENV, MODE, VARS, isCloud } from '$lib/system'; import googleAnalytics from '@analytics/google-analytics'; +import googleTagManager from '@analytics/google-tag-manager'; import { AppwriteException } from '@aw-labs/appwrite-console'; import Analytics from 'analytics'; import { get } from 'svelte/store'; @@ -11,7 +12,14 @@ const analytics = Analytics({ plugins: [ googleAnalytics({ measurementIds: [VARS.GOOGLE_ANALYTICS || 'G-R4YJ9JN8L4'] - }) + }), + ...(isCloud + ? [ + googleTagManager({ + containerId: [VARS.GOOGLE_TAG || 'GTM-P3T9TBV'] + }) + ] + : []) ] }); diff --git a/src/lib/images/login/cloud-bg-mobile.svg b/src/lib/images/login/cloud-bg-mobile.svg new file mode 100644 index 000000000..063ca2201 --- /dev/null +++ b/src/lib/images/login/cloud-bg-mobile.svg @@ -0,0 +1,626 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/src/lib/layout/notifications.svelte b/src/lib/layout/notifications.svelte index 202702799..b5ea496b5 100644 --- a/src/lib/layout/notifications.svelte +++ b/src/lib/layout/notifications.svelte @@ -26,4 +26,12 @@ right: 24px; z-index: 1000; } + + @media (max-width: 512px) { + section { + top: calc(var(--main-header-height) + 16px); + right: 16px; + left: 16px; + } + } diff --git a/src/lib/layout/unauthenticated.svelte b/src/lib/layout/unauthenticated.svelte index 677d2dd00..3f4ebff5f 100644 --- a/src/lib/layout/unauthenticated.svelte +++ b/src/lib/layout/unauthenticated.svelte @@ -5,6 +5,7 @@ import Cloud1 from '$lib/images/login/cloud-1.svg'; import Cloud2 from '$lib/images/login/cloud-2.svg'; import AppwriteCloudBg from '$lib/images/login/cloud-bg.svg'; + import AppwriteCloudBgMobile from '$lib/images/login/cloud-bg-mobile.svg'; import LoginDark from '$lib/images/login/login-dark-mode.svg'; import LoginLight from '$lib/images/login/login-light-mode.svg'; import { app } from '$lib/stores/app'; @@ -143,10 +144,9 @@
-
+ style:--url={`url(${AppwriteCloudBg})`} + style:--url-mobile={`url(${AppwriteCloudBgMobile})`}> +
{#if isCloud}
+ +