Skip to content

armgit / Cap

Public Imported from GitHub
0

Open source Loom alternative. Beautiful, shareable screen recordings.

improve: the tools pages (#741)

abhix4c8c7988f0f24
diff --git a/apps/web/app/(site)/tools/PageContent.tsx b/apps/web/app/(site)/tools/PageContent.tsx
index 25351f6b3..3cf2fa632 100644
--- a/apps/web/app/(site)/tools/PageContent.tsx
+++ b/apps/web/app/(site)/tools/PageContent.tsx
@@ -2,7 +2,9 @@
import { Button } from "@cap/ui";
import Link from "next/link";
+import {motion} from 'framer-motion'
import { useEffect } from "react";
+import LeftBlueHue from "@/components/pages/HomePage/LeftBlueHue";
interface ToolCategory {
title: string;
@@ -34,64 +36,39 @@ const toolCategories: ToolCategory[] = [
];
export function PageContent() {
- useEffect(() => {
- const animateClouds = () => {
- const cloud1 = document.getElementById("cloud-1");
- const cloud2 = document.getElementById("cloud-2");
- if (cloud1 && cloud2) {
- cloud1.animate(
- [
- { transform: "translateX(0) translateY(0)" },
- { transform: "translateX(-10px) translateY(5px)" },
- { transform: "translateX(10px) translateY(-5px)" },
- { transform: "translateX(0) translateY(0)" },
- ],
- {
- duration: 15000,
- iterations: Infinity,
- easing: "ease-in-out",
- }
- );
-
- cloud2.animate(
- [
- { transform: "translateX(0) translateY(0)" },
- { transform: "translateX(10px) translateY(-5px)" },
- { transform: "translateX(-10px) translateY(5px)" },
- { transform: "translateX(0) translateY(0)" },
- ],
- {
- duration: 18000,
- iterations: Infinity,
- easing: "ease-in-out",
- }
- );
- }
- };
-
- animateClouds();
- }, []);
return (
- <div className="py-20 md:py-28">
- <div className="wrapper">
- <div className="text-center mb-12">
- <h1 className="text-4xl font-medium tracking-tight text-gray-900 mb-4">
- Try our free tools
- </h1>
- <p className="text-xl text-gray-600 max-w-3xl mx-auto">
- Powerful browser-based utilities that run directly on your device.
- No uploads, no installations, maximum privacy.
- </p>
+ <>
+ <div
+ className="relative overflow-hidden pt-[100px] md:pt-[180px]"
+
+ >
+ <div className="relative z-10 px-5 w-full h-full flex flex-col justify-center">
+ <div className="mx-auto text-center wrapper wrapper-sm">
+ <h1 className="fade-in-down text-[2rem] leading-[2.5rem] md:text-[2.75rem] md:leading-[3.25rem] font-medium relative z-10 text-black mb-6">
+ Try our free tools
+ </h1>
+ <p className="mx-auto mb-10 max-w-2xl text-md sm:text-xl text-zinc-500 fade-in-down animate-delay-1">
+ Powerful browser-based utilities that run directly on your device. No uploads, no installations, maximum privacy.
+ </p>
+ </div>
+ <div className="flex flex-col justify-center items-center space-y-2 fade-in-up animate-delay-2 sm:flex-row sm:space-y-0 sm:space-x-4">
+
+ </div>
+
+
</div>
- <div className="grid grid-cols-1 gap-8 sm:grid-cols-2 lg:grid-cols-3">
- {toolCategories.map((category) => (
+
+ </div>
+ <div className="wrapper mx-auto">
+ <div className="grid grid-cols-1 gap-8 sm:grid-cols-2 lg:grid-cols-3 px-12 mt-16">
+ {toolCategories.map((category) => (
<Link
key={category.href}
href={category.href}
- className="group block p-8 border border-gray-200 rounded-xl hover:border-blue-500 hover:shadow-md transition-all"
+ className="group block p-8 border border-gray-200 bg-gray-1 rounded-xl hover:border-blue-500 hover:shadow-md transition-all"
>
<div className="flex flex-col items-center text-center">
<div className="flex-shrink-0 p-3 bg-blue-100 rounded-xl mb-5">
@@ -117,48 +94,30 @@ export function PageContent() {
</Link>
))}
</div>
-
<div
- className="mx-auto mt-16 mb-8 rounded-3xl overflow-hidden relative flex flex-col justify-center p-12"
- style={{
- minHeight: "300px",
- background:
- "linear-gradient(135deg, #4f46e5 0%, #3b82f6 50%, #0ea5e9 100%)",
- }}
+ className="mx-auto wrapper mt-16 mb-8 bg-white rounded-3xl overflow-hidden relative flex flex-col justify-center p-12"
+ style={{
+ minHeight: "300px",
+ backgroundImage: "url('/illustrations/ctabg.svg')",
+ backgroundSize: "cover",
+ backgroundRepeat: "no-repeat",
+ }}
+
>
- <div
- id="cloud-1"
- className="absolute top-0 -right-20 opacity-30 z-0 pointer-events-none transition-transform duration-700 ease-in-out"
- >
- <img
- className="max-w-[40vw] h-auto"
- src="/illustrations/cloud-1.png"
- alt="Footer Cloud One"
- />
- </div>
- <div
- id="cloud-2"
- className="absolute bottom-0 left-0 opacity-30 z-0 pointer-events-none transition-transform duration-700 ease-in-out"
- >
- <img
- className="max-w-[40vw] h-auto"
- src="/illustrations/cloud-2.png"
- alt="Footer Cloud Two"
- />
- </div>
- <div className="wrapper mx-auto h-full flex flex-col justify-center items-center relative z-10">
+
+ <div className=" mx-auto h-full flex flex-col justify-center items-center relative z-10">
<div className="text-center max-w-[800px] mx-auto mb-8">
- <h2 className="text-3xl md:text-4xl font-medium text-white mb-4 drop-shadow-md">
+ <h2 className="text-3xl md:text-4xl font-medium text-gray-12 mb-4 drop-shadow-md">
The open source Loom alternative
</h2>
- <p className="text-xl text-white/90 mb-6">
+ <p className="text-xl mb-6 text-gray-10">
Cap is lightweight, powerful, and cross-platform. Record and
share securely in seconds with custom S3 bucket support.
</p>
</div>
<div className="flex flex-col sm:flex-row items-center justify-center space-y-3 sm:space-y-0 sm:space-x-4">
<Button
- variant="white"
+ variant="gray"
href="/download"
size="lg"
className="w-full sm:w-auto transition-all duration-300 font-medium px-8 py-3"
@@ -169,6 +128,8 @@ export function PageContent() {
</div>
</div>
</div>
- </div>
+
+ </>
+
);
}
diff --git a/apps/web/components/tools/ToolsPageTemplate.tsx b/apps/web/components/tools/ToolsPageTemplate.tsx
index d010ceed4..4e069de51 100644
--- a/apps/web/components/tools/ToolsPageTemplate.tsx
+++ b/apps/web/components/tools/ToolsPageTemplate.tsx
@@ -119,7 +119,7 @@ export const ToolsPageTemplate = ({
return (
<>
{/* Compact Hero Section */}
- <div className="relative mt-[60px] overflow-hidden bg-gradient-to-b from-blue-50/50 to-white">
+ <div className="relative pt-[60px] md:pt-[120px] overflow-hidden ">
{/* Breadcrumbs */}
<div className="wrapper relative z-20 pt-4 px-5 text-center">
<div className="flex items-center justify-center text-sm">
@@ -144,57 +144,14 @@ export const ToolsPageTemplate = ({
</p>
</div>
</div>
-
- {/* Simplified Background Elements */}
- <div className="absolute inset-0 z-0 overflow-hidden opacity-50">
- <LeftBlueHue />
-
- {/* Reduced number of clouds for cleaner look */}
- <motion.img
- style={{ mixBlendMode: "plus-lighter" }}
- initial={{ right: 100, top: 30, rotate: 180 }}
- animate={{ x: "-30vw" }}
- transition={{
- duration: 300,
- repeat: Infinity,
- repeatType: "reverse",
- ease: "linear",
- }}
- className="absolute w-full max-w-[400px] z-[5] select-none opacity-30"
- src="/illustrations/bottomcloud.webp"
- alt="Background cloud"
- />
-
- <motion.img
- style={{ mixBlendMode: "screen" }}
- animate={{ x: [0, "50vw"] }}
- transition={{
- duration: 200,
- repeat: Infinity,
- repeatType: "reverse",
- }}
- className="absolute top-[20px] left-[-60px] max-w-[300px] select-none z-[5] pointer-events-none opacity-30"
- src="/illustrations/smallcloudthree.webp"
- alt="Background cloud"
- />
- </div>
-
- {/** Right Blue Hue */}
- <div
- className="w-[500px] h-[300px] bg-gradient-to-l rounded-full blur-[80px]
- absolute top-10 z-[0] right-0 from-[#A6D7FF] to-transparent opacity-40"
- />
- </div>
-
- {/* Tool Container - Now positioned for visibility above the fold */}
- <div className="wrapper py-10 bg-white relative z-10">
+ <div className="wrapper py-10 relative z-10">
<div className="mx-auto max-w-4xl bg-white rounded-2xl shadow-lg p-6 md:p-8 border border-gray-100">
{toolComponent}
</div>
</div>
{/* Main Content - Features & FAQ */}
- <div className="wrapper py-16 bg-gradient-to-b from-white to-gray-50 relative z-10">
+ <div className="wrapper py-16 relative z-10">
{/* Features Section */}
<div className="mb-20">
<div className="text-center max-w-[800px] mx-auto mb-12">
@@ -264,44 +221,26 @@ export const ToolsPageTemplate = ({
{/* Clean CTA Section */}
<div
- className="wrapper max-w-[900px] mx-auto rounded-2xl overflow-hidden relative flex flex-col justify-center p-8 md:p-10"
+ className="wrapper max-w-[900px] mx-auto rounded-2xl bg-white overflow-hidden relative flex flex-col justify-center p-8 md:p-10"
style={{
- background:
- "linear-gradient(135deg, #4f46e5 0%, #3b82f6 50%, #0ea5e9 100%)",
+ backgroundImage: "url('/illustrations/ctabg.svg')",
+ backgroundSize: "cover",
+ backgroundRepeat: "no-repeat",
}}
>
- <div
- id="cloud-4"
- className="absolute top-0 -right-20 opacity-20 z-0 pointer-events-none transition-transform duration-700 ease-in-out"
- >
- <img
- className="max-w-[30vw] h-auto"
- src="/illustrations/cloud-1.png"
- alt="Footer Cloud"
- />
- </div>
- <div
- id="cloud-5"
- className="absolute bottom-0 left-0 opacity-20 z-0 pointer-events-none transition-transform duration-700 ease-in-out"
- >
- <img
- className="max-w-[30vw] h-auto"
- src="/illustrations/cloud-2.png"
- alt="Footer Cloud"
- />
- </div>
+
<div className="wrapper mx-auto h-full flex flex-col justify-center items-center relative z-10">
<div className="text-center max-w-[700px] mx-auto mb-6">
- <h2 className="text-2xl md:text-3xl font-medium text-white mb-3 drop-shadow-md">
+ <h2 className="text-2xl md:text-3xl font-medium text-gray-12 mb-3 drop-shadow-md">
{content.cta.title}
</h2>
- <p className="text-lg text-white/90 mb-5">
+ <p className="text-lg text-gray-10 mb-5">
{content.cta.description}
</p>
</div>
<div className="flex flex-col sm:flex-row items-center justify-center space-y-3 sm:space-y-0 sm:space-x-4">
<Button
- variant="white"
+ variant="gray"
href="/download"
size="lg"
className="w-full sm:w-auto transition-all duration-200 font-medium px-8"
@@ -312,6 +251,10 @@ export const ToolsPageTemplate = ({
</div>
</div>
</div>
+ </div>
+
+ {/* Tool Container - Now positioned for visibility above the fold */}
+
<style jsx global>{`
@keyframes fade-in-down {