diff --git a/app/components/auth/armchair.tsx b/app/components/auth/armchair.tsx deleted file mode 100644 index cc8ec78..0000000 --- a/app/components/auth/armchair.tsx +++ /dev/null @@ -1,43 +0,0 @@ -// SVG armchair drawn in the coordinate space of ; relies on its gradient/filter defs. -export function Armchair() { - return ( - - {/* Contact shadow */} - - - {/* Back legs */} - - - - {/* Backrest */} - - - - {/* Tufting */} - - {[[184, 210], [200, 206], [216, 210], [192, 230], [208, 230]].map(([cx, cy]) => ( - - ))} - - - - - - {/* Seat base */} - - {/* Seat cushion */} - - - - {/* Armrests */} - - - - - - {/* Front legs */} - - - - ); -} diff --git a/app/components/auth/showcase/armchair.tsx b/app/components/auth/showcase/armchair.tsx new file mode 100644 index 0000000..997cb70 --- /dev/null +++ b/app/components/auth/showcase/armchair.tsx @@ -0,0 +1,68 @@ +import { useId } from 'react'; + +// Gradient direction (x2, y2) and colour stops, spread evenly +const GRADIENTS = { + back: { x2: 1, y2: 1, stops: ['accent-400', 'accent-700', 'accent-900'] }, + backInner: { x2: 0, y2: 1, stops: ['primary', 'accent-800'] }, + cushion: { x2: 0, y2: 1, stops: ['accent-300', 'accent-600'] }, + base: { x2: 0, y2: 1, stops: ['accent-700', 'accent-900'] }, + armLeft: { x2: 1, y2: 0, stops: ['accent-800', 'accent-600'] }, + armRight: { x2: 1, y2: 0, stops: ['primary', 'accent-800'] }, + wood: { x2: 0, y2: 1, stops: ['wood-light', 'wood-dark'] }, +} as const; + +const TUFTS = [[184, 210], [200, 206], [216, 210], [192, 230], [208, 230]] as const; + +// An orange armchair, the stand-in 3D model in the login story. Its contact shadow sits at 86% of the height; +// the view box leaves room around it so the blur isn't clipped. +export function Armchair({ className }: { className?: string }) { + const id = useId(); + const fill = (name: keyof typeof GRADIENTS) => `url(#${id}${name})`; + + return ( + + ); +}