Rallly is an open-source scheduling and collaboration tool designed to make organizing events and meetings easier.
TypeScript i18nextnext-authnextjspostgresqlprismareact-emailt3-stacktailwindcsstrpcturborepotypescriptzod
💄 Show video conferencing in landing page demos (#3503)
Luke Vella8d1166a57b2a
diff --git a/apps/landing/public/locales/en/home.json b/apps/landing/public/locales/en/home.jsonindex 65ed99b10..32043911f 100644--- a/apps/landing/public/locales/en/home.json+++ b/apps/landing/public/locales/en/home.json@@ -112,12 +112,11 @@"goodfirmsQuote": "“Unique in its simplicity and requires minimum interaction time.”","headline": "Find the best time to meet","heroDemoAssistantsDescription": "Please mark every slot you could make this week. The candidate is flying in on Monday, so I'd like to confirm as early as I can.",- "heroDemoAssistantsLocation": "Meeting room 3 and Zoom","heroDemoAssistantsOrganizer": "Organized by Sofia Almeida",+ "heroDemoAssistantsRoom": "Meeting room 3","heroDemoAssistantsTitle": "Interview panel: Head of Finance","heroDemoClose": "Close","heroDemoCommitteeDescription": "Please mark every date you could attend. We need a majority of members present to be quorate, so do fill this in even if only one date works.",- "heroDemoCommitteeLocation": "Committee room and Teams","heroDemoCommitteeOrganizer": "Organized by Sofia Almeida","heroDemoCommitteeTitle": "Finance committee: Q1 meeting","heroDemoCreatePoll": "Create your own poll",@@ -126,10 +125,8 @@"heroDemoEasyDescription": "That's all it takes to respond to a poll.","heroDemoIfNeedBe": "If need be","heroDemoLegalDescription": "Please mark every slot counsel and your client could attend. These are half-day sessions. We will confirm once both sides have responded.",- "heroDemoLegalLocation": "Neutral venue and video link","heroDemoLegalOrganizer": "Organized by Sofia Almeida","heroDemoLegalTitle": "Mediation: scheduling conference",- "heroDemoLocation": "Riverside Community Center","heroDemoNo": "No","heroDemoOrganizer": "Organized by Sofia Almeida","heroDemoParticipants": "Participants",@@ -140,7 +137,6 @@"heroDemoSportsClubTitle": "Pre-season training sessions","heroDemoThatWasEasy": "That was easy!","heroDemoThesisDefenseDescription": "Please mark the slots you could chair or examine. Times are shown in your own time zone, so there is no need to convert anything.",- "heroDemoThesisDefenseLocation": "Examination room and Zoom","heroDemoThesisDefenseOrganizer": "Organized by Sofia Almeida","heroDemoThesisDefenseTitle": "Thesis defense: examiner availability","heroDemoTitle": "Q3 Board Meeting",diff --git a/apps/landing/src/components/home/hero-demo/demo-presets.ts b/apps/landing/src/components/home/hero-demo/demo-presets.tsindex 1acb41b80..f14b0adb2 100644--- a/apps/landing/src/components/home/hero-demo/demo-presets.ts+++ b/apps/landing/src/components/home/hero-demo/demo-presets.ts@@ -4,14 +4,23 @@ import type { DemoSpacing, DemoVote } from "./demo-data";// The demo renders one of these presets. The audience pages (/for/*) show a// poll that looks like one their reader would actually run, so the screenshot// argues the case before the copy does.+//+// A preset shows a location or a video call, never both, as most real polls+// do: showing both makes the hybrid case look like the norm.export type DemoPreset = {title: string;description: string;organizer: string;- location: string;spacing: DemoSpacing;participants: { name: string; votes: DemoVote[] }[];-};+} & (+ | { location: string; conferencing?: never }+ | { conferencing: DemoConferencingProvider; location?: never }+);++// Limited to the providers most visitors recognize at a glance, and to ones+// live in the app: Zoom stays out until its marketplace review clears.+export type DemoConferencingProvider = "meet" | "teams";export type DemoPresetName =| "default"@@ -60,9 +69,9 @@ export function getDemoPreset(ns: "home",defaultValue: "Organized by Sofia Almeida",}),- location: t("heroDemoAssistantsLocation", {+ location: t("heroDemoAssistantsRoom", {ns: "home",- defaultValue: "Meeting room 3 and Zoom",+ defaultValue: "Meeting room 3",}),spacing: "consecutive",participants: assistantsParticipants,@@ -84,10 +93,7 @@ export function getDemoPreset(ns: "home",defaultValue: "Organized by Sofia Almeida",}),- location: t("heroDemoCommitteeLocation", {- ns: "home",- defaultValue: "Committee room and Teams",- }),+ conferencing: "teams",spacing: "weekly",participants: committeeParticipants,};@@ -132,10 +138,7 @@ export function getDemoPreset(ns: "home",defaultValue: "Organized by Sofia Almeida",}),- location: t("heroDemoThesisDefenseLocation", {- ns: "home",- defaultValue: "Examination room and Zoom",- }),+ conferencing: "meet",spacing: "consecutive",participants: thesisDefenseParticipants,};@@ -156,10 +159,7 @@ export function getDemoPreset(ns: "home",defaultValue: "Organized by Sofia Almeida",}),- location: t("heroDemoLegalLocation", {- ns: "home",- defaultValue: "Neutral venue and video link",- }),+ conferencing: "teams",spacing: "weekly",participants: legalParticipants,};@@ -179,10 +179,7 @@ export function getDemoPreset(ns: "home",defaultValue: "Organized by Sofia Almeida",}),- location: t("heroDemoLocation", {- ns: "home",- defaultValue: "Riverside Community Center",- }),+ conferencing: "meet",spacing: "weekly",participants: defaultParticipants,};diff --git a/apps/landing/src/components/home/hero-demo/desktop-demo.tsx b/apps/landing/src/components/home/hero-demo/desktop-demo.tsxindex d16c7dad7..112e079e7 100644--- a/apps/landing/src/components/home/hero-demo/desktop-demo.tsx+++ b/apps/landing/src/components/home/hero-demo/desktop-demo.tsx@@ -9,14 +9,25 @@ import {UserIcon,} from "lucide-react";import * as React from "react";+import GoogleMeetIcon from "@/assets/google-meet.svg";+import MicrosoftTeamsIcon from "@/assets/microsoft-teams.svg";import { BrowserChrome } from "./browser-chrome";import type { DemoDay } from "./demo-data";import { formatDemoParts, getInitials } from "./demo-data";import { DemoWindow } from "./demo-frame";-import type { DemoPreset } from "./demo-presets";+import type { DemoConferencingProvider, DemoPreset } from "./demo-presets";import { VoteCount } from "./vote-count";import { VoteIcon } from "./vote-icon";+// Brand names, so they stay untranslated, matching the app.+const conferencingProviders: Record<+ DemoConferencingProvider,+ { label: string; Icon: React.ComponentType<React.SVGProps<SVGSVGElement>> }+> = {+ meet: { label: "Google Meet", Icon: GoogleMeetIcon },+ teams: { label: "Microsoft Teams", Icon: MicrosoftTeamsIcon },+};+export const DesktopDemo = ({locale,days,@@ -67,10 +78,17 @@ export const DesktopDemo = ({<UserIcon className="size-4 text-gray-400" />{preset.organizer}</div>- <div className="flex items-center gap-2">- <MapPinIcon className="size-4 text-gray-400" />- {preset.location}- </div>+ {preset.location ? (+ <div className="flex items-center gap-2">+ <MapPinIcon className="size-4 text-gray-400" />+ {preset.location}+ </div>+ ) : null}+ {preset.conferencing ? (+ <div className="flex items-center gap-2">+ <ConferencingProvider provider={preset.conferencing} />+ </div>+ ) : null}</div><div><div className="font-medium text-gray-900 text-sm">@@ -228,3 +246,17 @@ export const DesktopDemo = ({</DemoWindow>);};++function ConferencingProvider({+ provider,+}: {+ provider: DemoConferencingProvider;+}) {+ const { label, Icon } = conferencingProviders[provider];+ return (+ <>+ <Icon width={16} height={16} aria-hidden="true" />+ {label}+ </>+ );+}