|
| 1 | +import { clsx } from "clsx" |
| 2 | + |
| 3 | +import { Button } from "@/app/conf/_design-system/button" |
| 4 | + |
| 5 | +import MetaLockup from "./logos/Meta.svg?svgr" |
| 6 | +import IBMWordmark from "./logos/IBM.svg?svgr" |
| 7 | +import AirBnBLockup from "./logos/AirBnB.svg?svgr" |
| 8 | +import IntuitWordmark from "./logos/Intuit.svg?svgr" |
| 9 | +import AWSLogo from "./logos/AWS.svg?svgr" |
| 10 | +import PayPalWordmark from "./logos/PayPal.svg?svgr" |
| 11 | +import NewYorkTimesWordmark from "./logos/NewYorkTimes.svg?svgr" |
| 12 | +import StarbucksWordmark from "./logos/Starbucks.svg?svgr" |
| 13 | +import ShopifyLockup from "./logos/Shopify.svg?svgr" |
| 14 | +import GitHubLockup from "./logos/GitHub.svg?svgr" |
| 15 | + |
| 16 | +import styles from "./style.module.css" |
| 17 | + |
| 18 | +const logos: LogoListItem[] = [ |
| 19 | + { |
| 20 | + href: "https://meta.com", |
| 21 | + alt: "Meta", |
| 22 | + component: MetaLockup, |
| 23 | + }, |
| 24 | + { |
| 25 | + href: "https://aws.amazon.com", |
| 26 | + alt: "AWS", |
| 27 | + component: props => ( |
| 28 | + <AWSLogo {...props} className={clsx(props.className, "w-[110px]")} /> |
| 29 | + ), |
| 30 | + }, |
| 31 | + |
| 32 | + // todo: Netflix? |
| 33 | + // { |
| 34 | + // href: "https://netflix.com", |
| 35 | + // alt: "Netflix", |
| 36 | + // component: NetflixWordmark, |
| 37 | + // }, |
| 38 | + { |
| 39 | + href: "https://airbnb.com", |
| 40 | + alt: "Airbnb", |
| 41 | + component: AirBnBLockup, |
| 42 | + }, |
| 43 | + { |
| 44 | + href: "https://intuit.com", |
| 45 | + alt: "Intuit", |
| 46 | + component: IntuitWordmark, |
| 47 | + }, |
| 48 | + |
| 49 | + { |
| 50 | + href: "https://ibm.com", |
| 51 | + alt: "IBM", |
| 52 | + component: props => ( |
| 53 | + <IBMWordmark {...props} className={clsx(props.className, "w-[140px]")} /> |
| 54 | + ), |
| 55 | + }, |
| 56 | + |
| 57 | + { |
| 58 | + href: "https://paypal.com", |
| 59 | + alt: "PayPal", |
| 60 | + component: PayPalWordmark, |
| 61 | + }, |
| 62 | + { |
| 63 | + href: "https://nytimes.com", |
| 64 | + alt: "New York Times", |
| 65 | + component: NewYorkTimesWordmark, |
| 66 | + }, |
| 67 | + { |
| 68 | + href: "https://starbucks.com", |
| 69 | + alt: "Starbucks", |
| 70 | + component: props => ( |
| 71 | + <StarbucksWordmark |
| 72 | + {...props} |
| 73 | + className={clsx(props.className, "w-[200px] -translate-x-1.5")} |
| 74 | + /> |
| 75 | + ), |
| 76 | + }, |
| 77 | + { |
| 78 | + href: "https://shopify.com", |
| 79 | + alt: "Shopify", |
| 80 | + component: ShopifyLockup, |
| 81 | + }, |
| 82 | + { |
| 83 | + href: "https://github.com", |
| 84 | + alt: "GitHub", |
| 85 | + component: GitHubLockup, |
| 86 | + }, |
| 87 | +] |
| 88 | + |
| 89 | +export function TrustedBy() { |
| 90 | + return ( |
| 91 | + <section className="gql-section gql-container bg-neu-0 py-8 lg:py-16 xl:py-24"> |
| 92 | + <div className="flex flex-wrap justify-between gap-6"> |
| 93 | + <h2 className="typography-h3 max-w-[474px] text-neu-800"> |
| 94 | + GraphQL is open source and trusted by the industry |
| 95 | + </h2> |
| 96 | + <p className="typography-body-md max-w-[624px] text-neu-700"> |
| 97 | + Facebook's mobile apps have been powered by GraphQL since 2012. A |
| 98 | + GraphQL spec was open-sourced in 2015. Now it is used by |
| 99 | + industry-leading companies worldwide and supported by the GraphQL |
| 100 | + Foundation, hosted since 2018 by the non-profit Linux Foundation. |
| 101 | + </p> |
| 102 | + </div> |
| 103 | + <div |
| 104 | + className={clsx( |
| 105 | + "mt-6 flex flex-wrap justify-center bg-neu-400 md:my-12 xl:my-16 xl:grid xl:grid-cols-5 xl:gap-px", |
| 106 | + styles.logos, |
| 107 | + )} |
| 108 | + > |
| 109 | + {logos.map(({ alt, href, component: Component }) => ( |
| 110 | + <a |
| 111 | + key={alt} |
| 112 | + href={href} |
| 113 | + target="_blank" |
| 114 | + rel="noreferrer" |
| 115 | + className="flex shrink-0 items-center justify-center bg-neu-0 p-4 hover:bg-neu-100 md:p-6 lg:p-8 xl:p-10" |
| 116 | + > |
| 117 | + <Component /> |
| 118 | + </a> |
| 119 | + ))} |
| 120 | + </div> |
| 121 | + |
| 122 | + <Button href="/users" className="mx-auto w-fit"> |
| 123 | + More GraphQL users |
| 124 | + </Button> |
| 125 | + </section> |
| 126 | + ) |
| 127 | +} |
| 128 | + |
| 129 | +interface LogoListItem { |
| 130 | + href: string |
| 131 | + alt: string |
| 132 | + component: React.FC<{ className?: string }> |
| 133 | +} |
0 commit comments