Download react-spring/docs/app/components/Cards/CardCarouselQuote.tsx from Devendra174/react-code-dataset: direct link, hf CLI and curl.
- Browser
- Download file 1.24 kB
-
https://huggingface.co/datasets/Devendra174/react-code-dataset/resolve/1e92f2d0b9e054abc23a53595fd89ad3e2b4a34e/react-spring/docs/app/components/Cards/CardCarouselQuote.tsx
- Command line
-
hf download hf://datasets/Devendra174/react-code-dataset@1e92f2d0b9e054abc23a53595fd89ad3e2b4a34e/react-spring/docs/app/components/Cards/CardCarouselQuote.tsx
-
curl -L -o CardCarouselQuote.tsx https://huggingface.co/datasets/Devendra174/react-code-dataset/resolve/1e92f2d0b9e054abc23a53595fd89ad3e2b4a34e/react-spring/docs/app/components/Cards/CardCarouselQuote.tsx
1.24 kB
| import { AspectRatio } from '../AspectRatio' | |
| import { Anchor } from '../Text/Anchor' | |
| import { Copy } from '../Text/Copy' | |
| import { Heading } from '../Text/Heading' | |
| import { | |
| externalLinkIcon, | |
| quoteAnchor, | |
| quoteCard, | |
| quoteImage, | |
| quoteeHandle, | |
| quoteeName, | |
| } from './CardCarouselQuote.css' | |
| export interface Quote { | |
| text: string | |
| name: string | |
| img: string | |
| handle: string | |
| tweetUrl: string | |
| job: string | |
| } | |
| export const CardCarouselQuote = ({ | |
| name, | |
| img, | |
| tweetUrl, | |
| handle, | |
| text, | |
| job, | |
| }: Quote) => { | |
| return ( | |
| <Anchor className={quoteAnchor} href={tweetUrl}> | |
| <figure className={quoteCard}> | |
| <div className={externalLinkIcon} /> | |
| <div className={quoteeHandle}> | |
| <AspectRatio className={quoteImage} width={1} height={1}> | |
| <img src={`/images/quotee/${img}`} alt={name} /> | |
| </AspectRatio> | |
| <Heading | |
| className={quoteeName} | |
| tag="figcaption" | |
| fontStyle="code" | |
| weight="default" | |
| > | |
| {handle} | |
| <br /> | |
| <span>{job}</span> | |
| </Heading> | |
| </div> | |
| <Copy tag="blockquote" fontStyle="XS"> | |
| {text} | |
| </Copy> | |
| </figure> | |
| </Anchor> | |
| ) | |
| } | |