Role: Frontend Developer
Tech Stack: React, GSAP, Tailwind CSS
A modern, animated landing page for a premium coffee brand, aimed at creating a luxurious user experience and high conversion rates. The project focused on showcasing the brand's artisanal coffee roasting process while maintaining exceptional performance and user engagement.
The brand needed a site that felt premium yet loaded quickly, with subtle animations to improve storytelling without compromising performance. Key challenges included:
Animation System:
Performance Optimizations:
User Experience:
The project successfully achieved its goals with significant improvements:
Performance Metrics:
Business Impact:
Technical Achievements:
🔗 Live Site • GitHub Repo
1"use client";23import { Highlight, themes } from "prism-react-renderer";4import { useState } from "react";56interface CodeBlockProps {7 code: string;8 language: string;9 showLineNumbers?: boolean;10 filename?: string;11}1213export const CodeBlock = ({14 code,15 language,16 showLineNumbers = true,17 filename,18}: CodeBlockProps) => {19const [copied, setCopied] = useState(false);2021const handleCopy = async () => {22 await navigator.clipboard.writeText(code);23 setCopied(true);24 setTimeout(() => setCopied(false), 2000);25};2627return (28 <div className="relative group py-4 md:py-8">29 {filename && (30 <div className="px-4 py-1.5 text-xs text-gray-400 border-b border-gray-700 bg-gray-800/50 rounded-t-lg">31 {filename}32 </div>33 )}34 <button35 onClick={handleCopy}36 className="absolute right-2 top-2 px-2 py-1 text-xs rounded bg-gray-700 text-gray-300 hover:bg-gray-600 transition-colors opacity-0 group-hover:opacity-100 z-10"37 >38 {copied ? "Copied!" : "Copy"}39 </button>40 <Highlight theme={themes.nightOwl} code={code.trim()} language={language}>41 {({ className, style, tokens, getLineProps, getTokenProps }) => (42 <pre43 className={`${className} p-4 overflow-x-auto font-mono text-sm `}44 style={{45 ...style,46 fontFamily:47 "Geist Mono, ui-monospace, SFMono-Regular, Menlo, Monaco, Consolas, monospace",48 marginTop: 0,49 }}50 >51 {tokens.map((line, i) => (52 <div key={i} {...getLineProps({ line })} className="table-row">53 {showLineNumbers && (54 <span className="table-cell text-right pr-4 select-none text-gray-500">55 {i + 1}56 </span>57 )}58 <span className="table-cell">59 {line.map((token, key) => (60 <span key={key} {...getTokenProps({ token })} />61 ))}62 </span>63 </div>64 ))}65 </pre>66 )}67 </Highlight>68 </div>69);70};