Skip to content

Commit 1534b2c

Browse files
🎨 style: update styles for demo recording UI
Improves the visual styles and user experience of the demo recording feature. - Change background color of recording indicator to black in dark mode - Simplify recording button by combining start and stop functionality - Update toast message to encourage downloading the app - Modify wording in the recording completed dialog - Update alert dialog cancel button text
1 parent cb6b33e commit 1534b2c

3 files changed

Lines changed: 34 additions & 24 deletions

File tree

‎apps/web/components/Demo.tsx‎

Lines changed: 8 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -57,11 +57,11 @@ export const Demo = () => {
5757

5858
{isRecording && (
5959
<div className="fixed left-0 top-1/2 transform -translate-y-1/2 text-white px-4 pl-8 py-2 rounded-r w-10 z-50">
60-
<div className="flex justify-center items-center bg-white dark:bg-gray-800">
60+
<div className="flex justify-center items-center bg-white dark:bg-black">
6161
<TooltipProvider>
6262
<Tooltip>
6363
<TooltipTrigger asChild>
64-
<div className="divide-y divide-gray-300 dark:divide-gray-600 rounded-md shadow-md md:flex md:divide-y-0 bg-gray-50 dark:bg-gray-700">
64+
<div className="divide-y divide-gray-300 dark:divide-gray-600 rounded-md shadow-md md:flex md:divide-y-0 bg-gray-50 dark:bg-black">
6565
<button
6666
className="group flex w-full items-center justify-center hover:bg-gray-100 dark:hover:bg-gray-600"
6767
onClick={() => {
@@ -134,8 +134,7 @@ export const Demo = () => {
134134
</div>
135135

136136
<button
137-
onClick={startRecording}
138-
disabled={isRecording}
137+
onClick={!isRecording ? startRecording : stopRecording}
139138
className={`w-5/12 md:h-10 sm:h-auto group relative justify-center gap-2 transition-all duration-300 ease-out hover:ring-2 hover:ring-primary hover:ring-offset-2 bg-sky-700 text-white hover:bg-sky-900 border border-transparent hover:border-sky-900 focus:border-sky-500 focus:ring focus:ring-sky-500 rounded-lg ${
140139
isRecording &&
141140
"bg-red-500 hover:bg-red-600 focus:border-red-400 focus:ring-red-400"
@@ -200,7 +199,7 @@ export const Demo = () => {
200199

201200
const downloadToast = () => {
202201
return toast(
203-
`This is just a demo of the Desktop app, you can't change the source`,
202+
`Interactive demo of ScreenLink Desktop, download the application!`,
204203
{
205204
action: {
206205
label: "Download",
@@ -221,14 +220,14 @@ const RecordingCompletedDialog = ({
221220
<AlertDialog open={open}>
222221
<AlertDialogContent>
223222
<AlertDialogHeader>
224-
<AlertDialogTitle>Demo Recording Complete 🚀</AlertDialogTitle>
223+
<AlertDialogTitle>Interactive Demo Finished 🚀</AlertDialogTitle>
225224
<AlertDialogDescription>
226-
This was just a demo of how the ScreenLink Desktop app works! You
227-
can download and get started
225+
This is what ScreenLink Desktop looks like. You can download and get
226+
started!
228227
</AlertDialogDescription>
229228
</AlertDialogHeader>
230229
<AlertDialogFooter>
231-
<AlertDialogCancel onClick={onClose}>Cancel</AlertDialogCancel>
230+
<AlertDialogCancel onClick={onClose}>I don't want to benefit</AlertDialogCancel>
232231
<AlertDialogAction>
233232
<Link href="/download">Download</Link>
234233
</AlertDialogAction>

‎apps/web/components/hero.tsx‎

Lines changed: 23 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -3,8 +3,10 @@ import Link from "next/link";
33

44
import CtaButton from "@components/ui/CtaButton";
55
import DemoLimk from "../public/images/demo-link-2.png";
6-
import { HeaderAction } from "./HeaderAction";
6+
import { GithubStars } from "./GithubStars";
77
import { Demo } from "./Demo";
8+
import { Badge } from "./ui/badge";
9+
import { LockClosedIcon } from "@radix-ui/react-icons";
810

911
export default function Hero() {
1012
return (
@@ -13,31 +15,40 @@ export default function Hero() {
1315
<div className="pt-20">
1416
{/* Hero content */}
1517
<div className="max-w-3xl mx-auto text-center">
16-
<HeaderAction />
17-
<h1 className="h1 font-hkgrotesk mb-6 mt-12" data-aos="fade-up">
18-
The Open Source Loom Alternative
18+
<span
19+
className="isolate inline-flex rounded-md shadow-sm"
20+
data-aos="fade-up"
21+
>
22+
<div className="relative inline-flex">
23+
<Badge>
24+
<LockClosedIcon className="h-3 w-3 mr-2 text-indigo-500" />
25+
Private, secure and open source
26+
</Badge>
27+
</div>
28+
</span>
29+
30+
<h1 className="h1 font-hkgrotesk mb-4 mt-6" data-aos="fade-up">
31+
Instantly Share Ideas, Screen Recordings
1932
</h1>
2033
<p
21-
className="text-xl text-slate-500 mb-10"
34+
className="text-xl text-slate-500 mb-12"
2235
data-aos="fade-up"
2336
data-aos-delay="100"
2437
>
25-
Create and share screen recording demos instantly with ScreenLink
26-
for free
38+
Create interactive screen recordings and share them instantly. No credit card required.
2739
</p>
2840
<div
29-
className="max-w-xs mx-auto sm:max-w-none sm:inline-flex sm:justify-center space-y-4 sm:space-y-0 sm:space-x-4"
41+
className="flex justify-center items-center gap-4"
3042
data-aos="fade-up"
3143
data-aos-delay="200"
3244
>
33-
<div>
34-
<CtaButton styles="btn" />
35-
</div>
45+
<CtaButton styles="btn w-60 py-3" />
46+
<GithubStars styles="w-45 py-3" />
3647
</div>
3748
</div>
3849
{/* Hero image */}
3950
<div
40-
className="pt-16 md:pt-20"
51+
className="pt-16"
4152
data-aos="fade-up"
4253
data-aos-delay="300"
4354
>

‎apps/web/components/ui/CtaButton.tsx‎

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -18,7 +18,7 @@ export default function CtaButton({ styles }: { styles?: string }) {
1818
if (status === "authenticated")
1919
return (
2020
<Link
21-
className={`text-white bg-indigo-500 hover:bg-indigo-600 w-full shadow-sm group ${
21+
className={`text-white bg-indigo-500 hover:bg-indigo-600 shadow-sm group ${
2222
styles ? styles : ``
2323
}`}
2424
href="/app"
@@ -33,12 +33,12 @@ export default function CtaButton({ styles }: { styles?: string }) {
3333

3434
return (
3535
<Link
36-
className={`font-medium text-white bg-indigo-500 hover:bg-indigo-600 w-full shadow-sm group px-3 lg:px-4 py-2 flex items-center transition duration-150 ease-in-out rounded-md ${
36+
className={`font-medium text-white bg-indigo-500 hover:bg-indigo-600 shadow-sm group px-3 lg:px-4 py-2 flex items-center transition duration-150 ease-in-out rounded-md ${
3737
styles ? styles : ``
3838
}`}
3939
href="/signup"
4040
>
41-
Start for Free{" "}
41+
Get Started{" "}
4242
<ArrowRightIcon className="tracking-normal text-sky-300 group-hover:translate-x-0.5 transition-transform duration-150 ease-in-out ml-1" />
4343
</Link>
4444
);

0 commit comments

Comments
 (0)