diff --git a/src/lib/actions/analytics.ts b/src/lib/actions/analytics.ts index 31e6dd708..1f4722965 100644 --- a/src/lib/actions/analytics.ts +++ b/src/lib/actions/analytics.ts @@ -429,5 +429,6 @@ export enum Submit { RecordUpdate = 'submit_dns_record_update', RecordDelete = 'submit_dns_record_delete', SearchClear = 'submit_clear_search', - FrameworkDetect = 'submit_framework_detect' + FrameworkDetect = 'submit_framework_detect', + TestimonialView = 'testimonial_view' } diff --git a/src/lib/data/testimonials.ts b/src/lib/data/testimonials.ts new file mode 100644 index 000000000..3a4181ead --- /dev/null +++ b/src/lib/data/testimonials.ts @@ -0,0 +1,58 @@ +import DevKind from '$lib/images/testimonials/hassan.png'; +import LangX from '$lib/images/testimonials/xue.webp'; +import KCollect from '$lib/images/testimonials/ryan-oconner-testimonial.png'; +import Phil from '$lib/images/testimonials/phil.jpg'; + +export interface Testimonial { + id: string; + logo: string; + headline: string; + blurb: string; + name: string; + title: string; + avatar: string; +} + +export const testimonials: Testimonial[] = [ + { + id: 'hassan-devkind', + logo: DevKind, + headline: 'DevKind reduced development time by 60% and lowered server costs by 40%', + blurb: 'A special thanks to Appwrite for providing robust features and seamless functionality.', + name: 'Hassan Ahmed', + title: 'Engineer at DevKind', + avatar: DevKind + }, + { + id: 'xue-langx', + logo: LangX, + headline: 'LangX handled millions of requests using Appwrite', + blurb: 'With its comprehensive suite of services, Appwrite emerged as an ideal choice for my needs.', + name: 'Xue', + title: 'Founder at LangX', + avatar: LangX + }, + { + id: 'ryan-kcollect', + logo: KCollect, + headline: 'K-Collect reduced infrastructure costs by 700%', + blurb: 'A major impact that Appwrite made was the amount of time and stress saved.', + name: "Ryan O'Connor", + title: 'Founder at K-Collect', + avatar: KCollect + }, + { + id: 'phil-majikkids', + logo: Phil, + headline: 'Just like a Swiss Army Knife - choose and use the tools you need', + blurb: 'Just like a Swiss Army Knife you can choose and use the tools that you need with Appwrite.', + name: 'Phil McCluskey', + title: 'App Manager, Majik Kids', + avatar: Phil + } +]; + +export function getRandomTestimonial(): Testimonial { + const randomIndex = Math.floor(Math.random() * testimonials.length); + return testimonials[randomIndex]; +} diff --git a/src/lib/images/testimonials/hassan.png b/src/lib/images/testimonials/hassan.png new file mode 100644 index 000000000..5c0e3e45b Binary files /dev/null and b/src/lib/images/testimonials/hassan.png differ diff --git a/src/lib/images/testimonials/phil.jpg b/src/lib/images/testimonials/phil.jpg new file mode 100644 index 000000000..b358163e0 Binary files /dev/null and b/src/lib/images/testimonials/phil.jpg differ diff --git a/src/lib/images/testimonials/ryan-oconner-testimonial.png b/src/lib/images/testimonials/ryan-oconner-testimonial.png new file mode 100644 index 000000000..417592184 Binary files /dev/null and b/src/lib/images/testimonials/ryan-oconner-testimonial.png differ diff --git a/src/lib/images/testimonials/xue.webp b/src/lib/images/testimonials/xue.webp new file mode 100644 index 000000000..4f7fe1ce5 Binary files /dev/null and b/src/lib/images/testimonials/xue.webp differ diff --git a/src/lib/layout/unauthenticated.svelte b/src/lib/layout/unauthenticated.svelte index b5fe495ea..bccb4de76 100644 --- a/src/lib/layout/unauthenticated.svelte +++ b/src/lib/layout/unauthenticated.svelte @@ -109,7 +109,7 @@ {#if currentReview?.image} {:else} diff --git a/src/routes/(public)/(guest)/register/+page.svelte b/src/routes/(public)/(guest)/register/+page.svelte index 6dcd39cc2..a1ca85c02 100644 --- a/src/routes/(public)/(guest)/register/+page.svelte +++ b/src/routes/(public)/(guest)/register/+page.svelte @@ -20,12 +20,35 @@ import { redirectTo } from '$routes/store'; import { checkPricingRefAndRedirect } from '$lib/helpers/pricingRedirect'; import { Layout, Link, Typography } from '@appwrite.io/pink-svelte'; + import { getRandomTestimonial } from '$lib/data/testimonials'; export let data; let name: string, mail: string, pass: string, disabled: boolean; let terms = false; + const randomTestimonial = getRandomTestimonial(); + const testimonialCampaign = { + $id: 'testimonial-signup', + template: 'review', + title: randomTestimonial.headline, + description: 'Join thousands of developers building amazing apps with Appwrite', + reviews: [ + { + name: randomTestimonial.name, + image: randomTestimonial.avatar, + description: randomTestimonial.title, + review: randomTestimonial.blurb + } + ] + }; + + trackEvent(Submit.TestimonialView, { + testimonial_id: randomTestimonial.id, + testimonial_name: randomTestimonial.name, + testimonial_company: randomTestimonial.title + }); + async function register() { try { disabled = true; @@ -43,7 +66,9 @@ trackEvent(Submit.AccountCreate, { campaign_name: data?.couponData?.code, email: mail, - name: name + name: name, + testimonial_id: randomTestimonial.id, + testimonial_name: randomTestimonial.name }); if (data?.couponData?.code) { @@ -94,7 +119,7 @@ Sign up - Appwrite - + Sign up