Change homepage layout (#112)
* Change homepage layout * Fix translations
This commit is contained in:
7 files changed
+117
-98
No files matched your search
+11
-5
@@ -224,14 +224,20 @@
|
||||
"pages.main.subtitle": {
|
||||
"message": "Enable clients from Minecraft Bedrock Edition to join your Minecraft Java server"
|
||||
},
|
||||
"components.homepage_features.1": {
|
||||
"message": "Geyser is a program that allows Minecraft: Bedrock Edition clients to join Minecraft: Java Edition servers, allowing for true crossplay between both editions of the game. The ultimate goal of this project is to allow Minecraft: Bedrock Edition users to join Minecraft: Java Edition servers as seamlessly as possible."
|
||||
"components.homepage_features.1.line1": {
|
||||
"message": "Geyser is a program that allows Minecraft: Bedrock Edition clients to join Minecraft: Java Edition servers, allowing for true crossplay between both editions of the game."
|
||||
},
|
||||
"components.homepage_features.features.2": {
|
||||
"components.homepage_features.1.line2": {
|
||||
"message": "The ultimate goal of this project is to allow Minecraft: Bedrock Edition users to join Minecraft: Java Edition servers as seamlessly as possible."
|
||||
},
|
||||
"components.homepage_features.2": {
|
||||
"message": "Geyser acts as a translator which sits between the Bedrock client and the Java server. It takes data from the Bedrock client and translates it into a format the Java server understands and vice versa. Geyser works with any modern Minecraft version and can be installed either as a plugin or ran as a standalone program."
|
||||
},
|
||||
"components.homepage_features.features.3": {
|
||||
"message": "Geyser can be joined from Bedrock clients on Windows 10/11, iOS, Android, and even consoles. Geyser works with a wide array of hosting providers, but can also be used as its own standalone proxy to join any Minecraft server! If you are a server owner, you can install our Floodgate plugin which allows Xbox Live authenticated Bedrock users to join without a Java Edition account!"
|
||||
"components.homepage_features.3.line1": {
|
||||
"message": "Geyser can be joined from Bedrock clients on Windows 10/11, iOS, Android, and even consoles. Geyser works with a wide array of hosting providers, but can also be used as its own standalone proxy to join any Minecraft server!"
|
||||
},
|
||||
"components.homepage_features.3.line2": {
|
||||
"message": "If you are a server owner, you can install our Floodgate plugin which allows Xbox Live authenticated Bedrock users to join without a Java Edition account!"
|
||||
},
|
||||
"pages.download.title": {
|
||||
"message": "Download"
|
||||
|
||||
@@ -0,0 +1,25 @@
|
||||
import clsx from 'clsx';
|
||||
import { PropsWithChildren } from 'react';
|
||||
import styles from "./styles.module.scss";
|
||||
|
||||
interface HomepageFeatureProps {
|
||||
title: string;
|
||||
image?: string;
|
||||
flipped?: boolean;
|
||||
}
|
||||
|
||||
export const HomepageFeature: React.FC<PropsWithChildren<HomepageFeatureProps>> = ({ title, image, flipped, children }) => {
|
||||
return (
|
||||
<div className={clsx(styles.feature, { [styles.flipped]: flipped })}>
|
||||
<div className={clsx(styles.content, "text--left padding-horiz--md")}>
|
||||
<h3 className={styles.title}>{title}</h3>
|
||||
{children}
|
||||
</div>
|
||||
{image && (
|
||||
<div>
|
||||
<img src={image} alt={title} />
|
||||
</div>
|
||||
)}
|
||||
</div>
|
||||
);
|
||||
}
|
||||
@@ -0,0 +1,40 @@
|
||||
.feature {
|
||||
display: grid;
|
||||
grid-template-columns: 1fr 1fr;
|
||||
gap: 10px;
|
||||
}
|
||||
|
||||
.feature.flipped > *:first-child {
|
||||
order: 2;
|
||||
}
|
||||
|
||||
.feature.flipped > *:last-child {
|
||||
order: 1;
|
||||
}
|
||||
|
||||
.content {
|
||||
margin-top: auto;
|
||||
margin-bottom: auto;
|
||||
}
|
||||
|
||||
.title {
|
||||
font-size: 30px;
|
||||
}
|
||||
|
||||
@media (max-width: 768px) {
|
||||
.feature {
|
||||
grid-template-columns: 1fr;
|
||||
}
|
||||
|
||||
.feature > *:first-child {
|
||||
order: 2;
|
||||
}
|
||||
|
||||
.feature > *:last-child {
|
||||
order: 1;
|
||||
}
|
||||
|
||||
.title {
|
||||
margin-top: 15px;
|
||||
}
|
||||
}
|
||||
@@ -1,78 +0,0 @@
|
||||
import clsx from 'clsx';
|
||||
import Heading from '@theme/Heading';
|
||||
import styles from './styles.module.scss';
|
||||
import Crossplatform0Img from '@site/static/img/site/crossplatform_0.png';
|
||||
import Crossplatform1Img from '@site/static/img/site/crossplatform_1.png';
|
||||
import Crossplatform2Img from '@site/static/img/site/crossplatform_2.png';
|
||||
import Translate from '@docusaurus/Translate';
|
||||
|
||||
type FeatureItem = {
|
||||
title: string;
|
||||
image?: string;
|
||||
description: JSX.Element;
|
||||
index?: number;
|
||||
};
|
||||
|
||||
const FeatureList: FeatureItem[] = [
|
||||
{
|
||||
title: 'What is Geyser?',
|
||||
image: Crossplatform2Img,
|
||||
description: (
|
||||
<>
|
||||
<Translate id="components.homepage_features.1">Geyser is a program that allows Minecraft: Bedrock Edition clients to join Minecraft: Java Edition servers, allowing for true crossplay between both editions of the game. The ultimate goal of this project is to allow Minecraft: Bedrock Edition users to join Minecraft: Java Edition servers as seamlessly as possible.</Translate>
|
||||
</>
|
||||
),
|
||||
},
|
||||
{
|
||||
title: 'How does it work?',
|
||||
image: Crossplatform1Img,
|
||||
description: (
|
||||
<>
|
||||
<Translate id='components.homepage_features.features.2'>Geyser acts as a translator which sits between the Bedrock client and the Java server. It takes data from the Bedrock client and translates it into a format the Java server understands and vice versa. Geyser works with any modern Minecraft version and can be installed either as a plugin or ran as a standalone program.</Translate>
|
||||
</>
|
||||
),
|
||||
},
|
||||
{
|
||||
title: 'Join from anywhere',
|
||||
image: Crossplatform0Img,
|
||||
description: (
|
||||
<>
|
||||
<Translate id='components.homepage_features.features.3'>Geyser can be joined from Bedrock clients on Windows 10/11, iOS, Android, and even consoles. Geyser works with a wide array of hosting providers, but can also be used as its own standalone proxy to join any Minecraft server! If you are a server owner, you can install our Floodgate plugin which allows Xbox Live authenticated Bedrock users to join without a Java Edition account!</Translate>
|
||||
</>
|
||||
),
|
||||
},
|
||||
];
|
||||
|
||||
function Feature({ title, image, description, index }: FeatureItem) {
|
||||
const Content = () => (
|
||||
<div className="text--left padding-horiz--md">
|
||||
<Heading as="h3">{title}</Heading>
|
||||
<p>{description}</p>
|
||||
</div>
|
||||
);
|
||||
const Image = () => (
|
||||
image &&
|
||||
<div className="column text--left">
|
||||
<img src={image} alt={title} />
|
||||
</div>
|
||||
);
|
||||
return (
|
||||
<div className={clsx('column')}>
|
||||
{index % 2 === 0 ? <><Image /><Content /></> : <><Content /><Image /></>}
|
||||
</div>
|
||||
);
|
||||
}
|
||||
|
||||
export default function HomepageFeatures(): JSX.Element {
|
||||
return (
|
||||
<section className={styles.features}>
|
||||
<div className="container">
|
||||
<div className="row">
|
||||
{FeatureList.map((props, idx) => (
|
||||
<Feature key={idx} {...props} index={idx} />
|
||||
))}
|
||||
</div>
|
||||
</div>
|
||||
</section>
|
||||
);
|
||||
}
|
||||
@@ -1,11 +0,0 @@
|
||||
.features {
|
||||
display: flex;
|
||||
align-items: center;
|
||||
padding: 2rem 0;
|
||||
width: 100%;
|
||||
}
|
||||
|
||||
.featureSvg {
|
||||
height: 200px;
|
||||
width: 200px;
|
||||
}
|
||||
@@ -66,4 +66,11 @@
|
||||
display: flex;
|
||||
align-items: center;
|
||||
justify-content: center;
|
||||
}
|
||||
|
||||
.features {
|
||||
padding: 50px 0;
|
||||
display: flex;
|
||||
flex-direction: column;
|
||||
gap: 40px;
|
||||
}
|
||||
+34
-4
@@ -1,18 +1,21 @@
|
||||
import clsx from 'clsx';
|
||||
import Layout from '@theme/Layout';
|
||||
import HomepageFeatures from '@site/src/components/HomepageFeatures';
|
||||
import Crossplatform0Img from '@site/static/img/site/crossplatform_0.png';
|
||||
import Crossplatform1Img from '@site/static/img/site/crossplatform_1.png';
|
||||
import Crossplatform2Img from '@site/static/img/site/crossplatform_2.png';
|
||||
import Heading from '@theme/Heading';
|
||||
import HeroImage from '@site/static/img/site/geyser.png';
|
||||
|
||||
import styles from './index.module.scss';
|
||||
import Translate from '@docusaurus/Translate';
|
||||
import { HomepageFeature } from '../components/HomepageFeature';
|
||||
|
||||
function HomepageHeader() {
|
||||
return (
|
||||
<header className={clsx('hero hero--primary', styles.heroBanner)}>
|
||||
<div className={styles.heroContent}>
|
||||
<img src={HeroImage} alt="Geyser Logo" className={styles.heroImage}/>
|
||||
<img src={HeroImage} alt="Geyser Logo" className={styles.heroImageBackgroundBlur}/>
|
||||
<img src={HeroImage} alt="Geyser Logo" className={styles.heroImage} />
|
||||
<img src={HeroImage} alt="Geyser Logo" className={styles.heroImageBackgroundBlur} />
|
||||
<div className={styles.textSection}>
|
||||
<Heading as="h1" className="hero__title">
|
||||
<Translate id='pages.main.title'>Revolutionize Your Minecraft Server</Translate>
|
||||
@@ -33,8 +36,35 @@ export default function Home(): JSX.Element {
|
||||
description="Enable clients from Minecraft Bedrock Edition to join your Minecraft Java server."
|
||||
>
|
||||
<HomepageHeader />
|
||||
|
||||
<main>
|
||||
<HomepageFeatures />
|
||||
<div className={clsx(styles.features, "container")}>
|
||||
<HomepageFeature
|
||||
title="What is Geyser?"
|
||||
image={Crossplatform2Img}
|
||||
>
|
||||
<Translate id="components.homepage_features.1.line1">Geyser is a program that allows Minecraft: Bedrock Edition clients to join Minecraft: Java Edition servers, allowing for true crossplay between both editions of the game.</Translate>
|
||||
<br /><br />
|
||||
<Translate id="components.homepage_features.1.line2">The ultimate goal of this project is to allow Minecraft: Bedrock Edition users to join Minecraft: Java Edition servers as seamlessly as possible.</Translate>
|
||||
</HomepageFeature>
|
||||
|
||||
<HomepageFeature
|
||||
title="How does it work?"
|
||||
image={Crossplatform1Img}
|
||||
flipped
|
||||
>
|
||||
<Translate id="components.homepage_features.2">Geyser acts as a translator which sits between the Bedrock client and the Java server. It takes data from the Bedrock client and translates it into a format the Java server understands and vice versa. Geyser works with any modern Minecraft version and can be installed either as a plugin or ran as a standalone program.</Translate>
|
||||
</HomepageFeature>
|
||||
|
||||
<HomepageFeature
|
||||
title="Join from anywhere"
|
||||
image={Crossplatform0Img}
|
||||
>
|
||||
<Translate id="components.homepage_features.3.line1">Geyser can be joined from Bedrock clients on Windows 10/11, iOS, Android, and even consoles. Geyser works with a wide array of hosting providers, but can also be used as its own standalone proxy to join any Minecraft server!</Translate>
|
||||
<br /><br />
|
||||
<Translate id="components.homepage_features.3.line2">If you are a server owner, you can install our Floodgate plugin which allows Xbox Live authenticated Bedrock users to join without a Java Edition account!</Translate>
|
||||
</HomepageFeature>
|
||||
</div>
|
||||
</main>
|
||||
</Layout>
|
||||
);
|
||||
|
||||
Reference in new issue
Block a user