feat(homepage+tools): tools page card refinement and homepage fixes
This commit is contained in:
@@ -10,6 +10,7 @@ import {
|
||||
ShieldCheck
|
||||
} from 'lucide-react';
|
||||
import { AppItem, ToolItem, resolveLocalised } from '@/types';
|
||||
import { KineticText } from '@/components/magicui/kinetic-text';
|
||||
|
||||
interface AppHandoffSectionProps {
|
||||
app?: AppItem;
|
||||
@@ -76,12 +77,22 @@ export function AppHandoffSection({
|
||||
const appTagline = resolveLocalised(app.tagline, locale);
|
||||
|
||||
return (
|
||||
<section id="app-handoff" className="py-16 sm:py-24 bg-paper border-b border-rule relative">
|
||||
<div className="max-w-container mx-auto px-4 sm:px-6 lg:px-8 space-y-10">
|
||||
<section id="app-handoff" className="py-16 sm:py-24 bg-paper border-b border-rule relative overflow-hidden">
|
||||
{/* Studio Lighting Background Glow */}
|
||||
<div
|
||||
className="pointer-events-none absolute top-10 left-10 w-[500px] h-[350px] [background:radial-gradient(ellipse_at_center,color-mix(in_oklab,var(--color-accent)_12%,transparent)_0%,transparent_70%)]"
|
||||
aria-hidden="true"
|
||||
/>
|
||||
<div
|
||||
className="pointer-events-none absolute inset-0 opacity-20 studio-proof-grid"
|
||||
aria-hidden="true"
|
||||
/>
|
||||
|
||||
<div className="max-w-container mx-auto px-4 sm:px-6 lg:px-8 space-y-10 relative z-10">
|
||||
{/* Section Header */}
|
||||
<div className="max-w-2xl space-y-2 border-b border-rule pb-5">
|
||||
<h2 className="text-3xl sm:text-4xl font-display font-bold text-ink tracking-tight">
|
||||
Continue on mobile
|
||||
<KineticText>Continue on mobile</KineticText>
|
||||
</h2>
|
||||
<p className="text-sm sm:text-base text-ink-2 font-body text-pretty">
|
||||
Handoff this tool directly to your iOS or Android phone with 50 bonus credits.
|
||||
@@ -90,7 +101,7 @@ export function AppHandoffSection({
|
||||
|
||||
<div className="grid grid-cols-1 lg:grid-cols-12 gap-8 items-start">
|
||||
{/* Left Column: App Specifications & Store Buttons */}
|
||||
<div className="lg:col-span-7 studio-sheet p-6 sm:p-8 crop-marked space-y-6">
|
||||
<div className="lg:col-span-7 studio-sheet rounded-3xl p-6 sm:p-8 space-y-6">
|
||||
<div className="border-b border-rule pb-5 space-y-2">
|
||||
<span className="text-xs text-muted font-body">Dedicated companion client</span>
|
||||
<h3 className="text-2xl font-display font-bold text-ink">
|
||||
@@ -103,7 +114,7 @@ export function AppHandoffSection({
|
||||
|
||||
{/* Promo Voucher */}
|
||||
{showBonus && (
|
||||
<div className="p-4 bg-paper-2 border border-rule rounded-card flex flex-col sm:flex-row items-start sm:items-center justify-between gap-3">
|
||||
<div className="p-4 bg-paper-2 border border-rule rounded-2xl flex flex-col sm:flex-row items-start sm:items-center justify-between gap-3">
|
||||
<div className="space-y-0.5">
|
||||
<span className="text-xs font-body font-semibold text-ink">
|
||||
50 Free credits voucher code
|
||||
@@ -113,13 +124,13 @@ export function AppHandoffSection({
|
||||
</p>
|
||||
</div>
|
||||
<div className="flex items-center gap-2">
|
||||
<span className="font-body text-sm font-semibold text-accent px-2.5 py-1 bg-paper-hi border border-rule rounded">
|
||||
<span className="font-body text-sm font-semibold text-accent px-3 py-1 bg-paper-hi border border-rule rounded-full">
|
||||
{bonusCode}
|
||||
</span>
|
||||
<button
|
||||
type="button"
|
||||
onClick={copyPromo}
|
||||
className="btn-secondary text-xs px-2.5 py-1"
|
||||
className="btn-secondary text-xs px-3 py-1.5 rounded-full min-h-[36px]"
|
||||
aria-label="Copy voucher code"
|
||||
>
|
||||
{copiedPromo ? <Check className="w-3.5 h-3.5 text-accent" aria-hidden="true" /> : <Copy className="w-3.5 h-3.5 text-muted" aria-hidden="true" />}
|
||||
@@ -131,33 +142,33 @@ export function AppHandoffSection({
|
||||
{/* Official Store Buttons */}
|
||||
<div className="pt-2 space-y-3">
|
||||
<span className="text-xs text-muted font-body block">Direct store installation</span>
|
||||
<div className="flex flex-wrap gap-3">
|
||||
<div className="flex flex-col sm:flex-row flex-wrap gap-3">
|
||||
<a
|
||||
href={app.stores?.ios?.url || `/go/${tool?.slug || 'explore'}/${app.slug}`}
|
||||
target="_blank"
|
||||
rel="noopener noreferrer"
|
||||
className="btn-secondary"
|
||||
className="btn-secondary min-h-[48px] rounded-full justify-center w-full sm:w-auto"
|
||||
>
|
||||
<Smartphone className="w-4 h-4 text-accent" aria-hidden="true" />
|
||||
<span>Apple App Store</span>
|
||||
<ExternalLink className="w-3 h-3 text-muted ml-1" aria-hidden="true" />
|
||||
<ExternalLink className="w-3.5 h-3.5 text-muted ml-1" aria-hidden="true" />
|
||||
</a>
|
||||
|
||||
<a
|
||||
href={app.stores?.android?.url || `/go/${tool?.slug || 'explore'}/${app.slug}`}
|
||||
target="_blank"
|
||||
rel="noopener noreferrer"
|
||||
className="btn-secondary"
|
||||
className="btn-secondary min-h-[48px] rounded-full justify-center w-full sm:w-auto"
|
||||
>
|
||||
<Smartphone className="w-4 h-4 text-accent" aria-hidden="true" />
|
||||
<span>Google Play</span>
|
||||
<ExternalLink className="w-3 h-3 text-muted ml-1" aria-hidden="true" />
|
||||
<ExternalLink className="w-3.5 h-3.5 text-muted ml-1" aria-hidden="true" />
|
||||
</a>
|
||||
|
||||
<button
|
||||
type="button"
|
||||
onClick={copyLink}
|
||||
className="btn-secondary"
|
||||
className="btn-secondary min-h-[48px] rounded-full justify-center w-full sm:w-auto"
|
||||
aria-label="Copy direct deep link"
|
||||
>
|
||||
{copiedLink ? <Check className="w-4 h-4 text-accent" aria-hidden="true" /> : <Copy className="w-4 h-4 text-muted" aria-hidden="true" />}
|
||||
@@ -173,14 +184,14 @@ export function AppHandoffSection({
|
||||
|
||||
{/* Right Column: Clean QR Code Card */}
|
||||
{showQr && qrDataUrl && (
|
||||
<div className="lg:col-span-5 studio-sheet p-6 sm:p-8 crop-marked text-center flex flex-col items-center">
|
||||
<div className="lg:col-span-5 studio-sheet rounded-3xl p-6 sm:p-8 text-center flex flex-col items-center">
|
||||
<span className="text-xs text-muted font-body mb-4">Scan with phone camera</span>
|
||||
|
||||
<div className="p-3 bg-paper-hi border border-rule rounded-card inline-block shadow-sm">
|
||||
<div className="p-4 bg-paper-hi border border-rule rounded-2xl inline-block shadow-sm">
|
||||
<img
|
||||
src={qrDataUrl}
|
||||
alt="Scan QR code to install app"
|
||||
className="w-44 h-44 object-contain rounded"
|
||||
className="w-44 h-44 object-contain rounded-xl"
|
||||
/>
|
||||
</div>
|
||||
|
||||
|
||||
Reference in New Issue
Block a user