Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

add user logos #1

Merged
merged 6 commits into from
Nov 7, 2023
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
27 changes: 27 additions & 0 deletions src/components/Hero/Hero.module.scss
Original file line number Diff line number Diff line change
@@ -0,0 +1,27 @@
.backdrop {
padding: 4rem 0;
text-align: center;
position: relative;
overflow: hidden;
background-image: linear-gradient(-45deg, #173647, lighten(#173647, 5%));
color: white;
}

.title {
font-size: 4rem;
font-weight: 300;
}

@media screen and (max-width: 996px) {
.backdrop {
padding: 2rem;
}

.title {
font-size: 3rem;
}
}




17 changes: 17 additions & 0 deletions src/components/Hero/Hero.tsx
Original file line number Diff line number Diff line change
@@ -0,0 +1,17 @@
import React, {FC} from 'react';
import clsx from "clsx";
import styles from './Hero.module.scss'

export const Hero: FC = () => {
return (
<header className={clsx(styles.backdrop)}>
<div className="container">
<h1 className={clsx(styles.title)}>
<strong>Cucumber </strong>
lets you write<br/>
automated tests in plain language
</h1>
</div>
</header>
);
}
1 change: 1 addition & 0 deletions src/components/Hero/index.ts
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
export * from './Hero'
7 changes: 7 additions & 0 deletions src/components/Intro/Intro.module.scss
Original file line number Diff line number Diff line change
@@ -0,0 +1,7 @@
.introRow {
align-items: center;
}

.featureFile {
margin-bottom: 0;
}
30 changes: 30 additions & 0 deletions src/components/Intro/Intro.tsx
Original file line number Diff line number Diff line change
@@ -0,0 +1,30 @@
import React, {FC} from 'react';
import clsx from "clsx";
import Link from "@docusaurus/Link";
import CodeBlock from "@theme/CodeBlock";
import {feature} from "./feature";
import styles from './Intro.module.scss'

export const Intro: FC = () => {
return <div className={clsx('row', styles.introRow)}>
<div className="col col--6">
<p>Cucumber is a tool for running automated acceptance tests, written in plain language.
Because they're written in plain language, they can be read by anyone on your team.
Because they can be read by anyone, they help improve communication, collaboration and
trust on your team.</p>
<Link
className="button button--primary button--lg"
to="https://cucumber.io/docs/installation">
Get Started
</Link>
</div>
<div className="col col--6">
<CodeBlock
className={styles.featureFile}
language="gherkin"
showLineNumbers>
{feature}
</CodeBlock>
</div>
</div>
}
10 changes: 10 additions & 0 deletions src/components/Intro/feature.ts
Original file line number Diff line number Diff line change
@@ -0,0 +1,10 @@
export const feature = `@tag
Feature: Eating too many cucumbers may not be good for you

Eating too much of anything may not be good for you

Scenario: Eating a few is no problem
Given Alice is hungry
When she eats 3 cucumbers
Then she will be full
`
1 change: 1 addition & 0 deletions src/components/Intro/index.ts
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
export * from './Intro'
31 changes: 31 additions & 0 deletions src/components/UsedBy/UsedBy.module.scss
Original file line number Diff line number Diff line change
@@ -0,0 +1,31 @@
.strapLine {
text-align: center;
}

.logosList {
list-style: none;
display: flex;
align-content: center;
align-items: center;
justify-content: center;
gap: 24px;
max-width: 100%;
overflow-x: hidden;
color: var(--ifm-font-color-base);

img {
max-width: 120px;
max-height: 50px;
filter: #{"grayscale()"};
opacity: 0.5;

[data-theme='dark'] & {
filter: #{"grayscale() invert()"}
}

@media all and (max-width: 600px) {
max-width: 80px;
max-height: 30px;
}
}
}
24 changes: 24 additions & 0 deletions src/components/UsedBy/UsedBy.tsx
Original file line number Diff line number Diff line change
@@ -0,0 +1,24 @@
import React, {FC} from 'react';
import styles from './UsedBy.module.scss';

const LOGOS = [
['Brightcove', 'brightcove.svg'],
['EXL', 'exl.png'],
['FinanceIt', 'financeit.svg'],
['Pendo', 'pendo.svg'],
['SproutSocial', 'sproutsocial.svg'],
['Trivago', 'trivago.svg'],
]

export const UsedBy: FC = () => {
return <>
<p className={styles.strapLine}>Loved by teams everywhere</p>
<ul className={styles.logosList}>
{LOGOS.map(([alt, filename]) => (
<li>
<img alt={alt} src={'/img/users/' + filename}/>
</li>
))}
</ul>
</>
}
1 change: 1 addition & 0 deletions src/components/UsedBy/index.ts
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
export * from './UsedBy'
8 changes: 4 additions & 4 deletions src/css/custom.scss
Original file line number Diff line number Diff line change
Expand Up @@ -31,17 +31,17 @@
}

.flavour--ruby {
background-image: url('/img/flavour-ruby.svg')
background-image: url('/img/flavours/ruby.svg')
}

.flavour--jvm {
background-image: url('/img/flavour-jvm.svg')
background-image: url('/img/flavours/jvm.svg')
}

.flavour--js {
background-image: url('/img/flavour-js.svg')
background-image: url('/img/flavours/js.svg')
}

.flavour--go {
background-image: url('/img/flavour-go.svg')
background-image: url('/img/flavours/go.svg')
}
36 changes: 0 additions & 36 deletions src/pages/index.module.scss
Original file line number Diff line number Diff line change
@@ -1,36 +0,0 @@
.heroBanner {
padding: 4rem 0;
text-align: center;
position: relative;
overflow: hidden;
background-image: linear-gradient(-45deg, #173647, lighten(#173647, 5%));
color: white;
}

.heroTitle {
font-size: 4rem;
font-weight: 300;
}

@media screen and (max-width: 996px) {
.heroBanner {
padding: 2rem;
}

.heroTitle {
font-size: 3rem;
}
}

.introRow {
align-items: center;
}

.introCtas {
display: flex;
align-items: center;
}

.introFeature {
margin-bottom: 0;
}
64 changes: 8 additions & 56 deletions src/pages/index.tsx
Original file line number Diff line number Diff line change
@@ -1,67 +1,19 @@
import React from 'react';
import clsx from 'clsx';
import Link from '@docusaurus/Link';
import useDocusaurusContext from '@docusaurus/useDocusaurusContext';
import Layout from '@theme/Layout';
import CodeBlock from '@theme/CodeBlock';

import styles from './index.module.scss';

const feature = `@tag
Feature: Eating too many cucumbers may not be good for you

Eating too much of anything may not be good for you

Scenario: Eating a few is no problem
Given Alice is hungry
When she eats 3 cucumbers
Then she will be full
`

function HomepageHeader() {
return (
<header className={clsx(styles.heroBanner)}>
<div className="container">
<h1 className={clsx(styles.heroTitle)}>
<strong>Cucumber </strong>
lets you write<br/>
automated tests in plain language
</h1>
</div>
</header>
);
}
import {Hero} from "@site/src/components/Hero";
import {Intro} from "@site/src/components/Intro";
import {UsedBy} from "@site/src/components/UsedBy";

export default function Home() {
const {siteConfig} = useDocusaurusContext();
return (
<Layout>
<HomepageHeader/>
<Hero/>
<main>
<div className="container padding-vert--lg">
<div className={clsx('row', styles.introRow)}>
<div className="col col--6">
<p>Cucumber is a tool for running automated acceptance tests, written in plain language.
Because they're written in plain language, they can be read by anyone on your team.
Because they can be read by anyone, they help improve communication, collaboration and
trust on your team.</p>
<div className={styles.introCtas}>
<Link
className="button button--primary button--lg"
to="https://cucumber.io/docs/installation">
Get Started
</Link>
</div>
</div>
<div className="col col--6">
<CodeBlock
className={styles.introFeature}
language="gherkin"
showLineNumbers>
{feature}
</CodeBlock>
</div>
</div>
<Intro/>
</div>
<div className="container padding-vert--lg">
<UsedBy/>
</div>
</main>
</Layout>
Expand Down
File renamed without changes
File renamed without changes
File renamed without changes
File renamed without changes
3 changes: 3 additions & 0 deletions static/img/users/brightcove.svg
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added static/img/users/exl.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
9 changes: 9 additions & 0 deletions static/img/users/financeit.svg
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
5 changes: 5 additions & 0 deletions static/img/users/pendo.svg
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
8 changes: 8 additions & 0 deletions static/img/users/sproutsocial.svg
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading